123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794 |
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./init-CzXBwfa2.js","./VAutocomplete-14RBtvAN.js","./VAutocomplete-C7GsKXCI.css","./index-AOcxwHT9.js","./index-B8R6cH3l.css","./index-fM-yRA8C.js","./index-T0FVgtn_.css","./VColorPicker-OJXTdtLi.js","./VSlider-Bmvc6aBM.js","./VSlider-CCLK5IcE.css","./VColorPicker-C5SaCPIG.css","./VItem-BK4QWvWk.js","./VItem-Dc6sXDLO.css","./TextEllipsis-Csvrxmtg.js","./TextEllipsis-CiyJs6he.css","./init-L6M_wKfy.css","./index-BH2u6Mtr.js","./index-BLbEZ0ov.css","./index-iVKLIIPr.js","./index-DygTP69T.js","./index-DVn-lV_d.css","./index-CRFMH-eq.js","./index-ShAoptWN.js","./index-DGgDsdLN.js","./index-AqzXok66.css","./index-Cz6Ec37f.js","./index-Djasm6Rq.css","./index-D1XXAW7v.js","./index-BH4GkfoQ.css","./index-Bk1fV-OO.js","./index-C01L9dzC.css","./index-CWQ67CZx.js","./index-DGIlKyM9.js","./index-zOzy80IM.js","./index-IqHIF4Ia.css","./index-DQl_2X1i.js","./hooks-Bm-hi6ta.js","./index-InhgaAuK.css","./index-DhMIQvXp.js","./index-ByQCJWio.css","./index-CZjiVl8-.js","./index-D_JgiZwh.css","./index-Cho1JviK.js","./index-nJNJkaz0.js","./index-CuMwt_m8.css","./index-q238DTSs.js","./hooks-B2wby68t.js","./index-B2_I0Nan.css","./index-BqOFji3O.js","./index-Cus1j3uJ.css","./index-C6Jlbm68.js","./index-Ih-hcyhV.css","./index-CmrbCn_y.js","./index-zgJSgbIM.js","./print-BUiXb7dt.js","./index-BP7v9n-Z.js","./index-DzKCDU2b.css","./index-C-IrQJDk.js","./index-B4IIMmzb.js","./hooks-oYkL7aVN.js","./index-x667nqpe.css","./index-DlZg7BZu.js","./index-DQ8ioBU-.css","./index-BC6zIT-j.js","./index-DOVFRcUT.css","./index-D-b_Xqbw.js","./index-n0gERvBg.js","./index-BP-b09cf.css","./index-tfq16h0w.js","./index-BTYP6yHp.js","./index-S-BSxkx-.css","./index-RAYsk0uq.js","./index-CL_f6Mbr.js"])))=>i.map(i=>d[i]);
- var $0=Object.defineProperty;var H0=(t,e,l)=>e in t?$0(t,e,{enumerable:!0,configurable:!0,writable:!0,value:l}):t[e]=l;var Pm=(t,e,l)=>H0(t,typeof e!="symbol"?e+"":e,l);(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const u of document.querySelectorAll('link[rel="modulepreload"]'))n(u);new MutationObserver(u=>{for(const c of u)if(c.type==="childList")for(const y of c.addedNodes)y.tagName==="LINK"&&y.rel==="modulepreload"&&n(y)}).observe(document,{childList:!0,subtree:!0});function l(u){const c={};return u.integrity&&(c.integrity=u.integrity),u.referrerPolicy&&(c.referrerPolicy=u.referrerPolicy),u.crossOrigin==="use-credentials"?c.credentials="include":u.crossOrigin==="anonymous"?c.credentials="omit":c.credentials="same-origin",c}function n(u){if(u.ep)return;u.ep=!0;const c=l(u);fetch(u.href,c)}})();const scriptRel="modulepreload",assetsURL=function(t,e){return new URL(t,e).href},seen={},__vitePreload=function(e,l,n){let u=Promise.resolve();if(l&&l.length>0){const y=document.getElementsByTagName("link"),b=document.querySelector("meta[property=csp-nonce]"),m=b?.nonce||b?.getAttribute("nonce");u=Promise.allSettled(l.map(O=>{if(O=assetsURL(O,n),O in seen)return;seen[O]=!0;const N=O.endsWith(".css"),L=N?'[rel="stylesheet"]':"";if(!!n)for(let J=y.length-1;J>=0;J--){const fe=y[J];if(fe.href===O&&(!N||fe.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${O}"]${L}`))return;const q=document.createElement("link");if(q.rel=N?"stylesheet":scriptRel,N||(q.as="script"),q.crossOrigin="",q.href=O,m&&q.setAttribute("nonce",m),document.head.appendChild(q),N)return new Promise((J,fe)=>{q.addEventListener("load",J),q.addEventListener("error",()=>fe(new Error(`Unable to preload CSS for ${O}`)))})}))}function c(y){const b=new Event("vite:preloadError",{cancelable:!0});if(b.payload=y,window.dispatchEvent(b),!b.defaultPrevented)throw y}return u.then(y=>{for(const b of y||[])b.status==="rejected"&&c(b.reason);return e().catch(c)})};/**
- * @vue/shared v3.5.6
- * (c) 2018-present Yuxi (Evan) You and Vue contributors
- * @license MIT
- **//*! #__NO_SIDE_EFFECTS__ */function makeMap(t){const e=Object.create(null);for(const l of t.split(","))e[l]=1;return l=>l in e}const EMPTY_OBJ={},EMPTY_ARR=[],NOOP=()=>{},NO=()=>!1,isOn$1=t=>t.charCodeAt(0)===111&&t.charCodeAt(1)===110&&(t.charCodeAt(2)>122||t.charCodeAt(2)<97),isModelListener=t=>t.startsWith("onUpdate:"),extend$1=Object.assign,remove=(t,e)=>{const l=t.indexOf(e);l>-1&&t.splice(l,1)},hasOwnProperty$3=Object.prototype.hasOwnProperty,hasOwn=(t,e)=>hasOwnProperty$3.call(t,e),isArray$3=Array.isArray,isMap=t=>toTypeString(t)==="[object Map]",isSet=t=>toTypeString(t)==="[object Set]",isDate$1=t=>toTypeString(t)==="[object Date]",isRegExp$1=t=>toTypeString(t)==="[object RegExp]",isFunction$2=t=>typeof t=="function",isString$2=t=>typeof t=="string",isSymbol=t=>typeof t=="symbol",isObject$2=t=>t!==null&&typeof t=="object",isPromise$2=t=>(isObject$2(t)||isFunction$2(t))&&isFunction$2(t.then)&&isFunction$2(t.catch),objectToString=Object.prototype.toString,toTypeString=t=>objectToString.call(t),toRawType=t=>toTypeString(t).slice(8,-1),isPlainObject$3=t=>toTypeString(t)==="[object Object]",isIntegerKey=t=>isString$2(t)&&t!=="NaN"&&t[0]!=="-"&&""+parseInt(t,10)===t,isReservedProp=makeMap(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),cacheStringFunction=t=>{const e=Object.create(null);return l=>e[l]||(e[l]=t(l))},camelizeRE=/-(\w)/g,camelize=cacheStringFunction(t=>t.replace(camelizeRE,(e,l)=>l?l.toUpperCase():"")),hyphenateRE=/\B([A-Z])/g,hyphenate=cacheStringFunction(t=>t.replace(hyphenateRE,"-$1").toLowerCase()),capitalize=cacheStringFunction(t=>t.charAt(0).toUpperCase()+t.slice(1)),toHandlerKey=cacheStringFunction(t=>t?`on${capitalize(t)}`:""),hasChanged=(t,e)=>!Object.is(t,e),invokeArrayFns=(t,...e)=>{for(let l=0;l<t.length;l++)t[l](...e)},def=(t,e,l,n=!1)=>{Object.defineProperty(t,e,{configurable:!0,enumerable:!1,writable:n,value:l})},looseToNumber=t=>{const e=parseFloat(t);return isNaN(e)?t:e},toNumber=t=>{const e=isString$2(t)?Number(t):NaN;return isNaN(e)?t:e};let _globalThis;const getGlobalThis=()=>_globalThis||(_globalThis=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}),GLOBALS_ALLOWED="Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol",isGloballyAllowed=makeMap(GLOBALS_ALLOWED);function normalizeStyle(t){if(isArray$3(t)){const e={};for(let l=0;l<t.length;l++){const n=t[l],u=isString$2(n)?parseStringStyle(n):normalizeStyle(n);if(u)for(const c in u)e[c]=u[c]}return e}else if(isString$2(t)||isObject$2(t))return t}const listDelimiterRE=/;(?![^(]*\))/g,propertyDelimiterRE=/:([^]+)/,styleCommentRE=/\/\*[^]*?\*\//g;function parseStringStyle(t){const e={};return t.replace(styleCommentRE,"").split(listDelimiterRE).forEach(l=>{if(l){const n=l.split(propertyDelimiterRE);n.length>1&&(e[n[0].trim()]=n[1].trim())}}),e}function normalizeClass(t){let e="";if(isString$2(t))e=t;else if(isArray$3(t))for(let l=0;l<t.length;l++){const n=normalizeClass(t[l]);n&&(e+=n+" ")}else if(isObject$2(t))for(const l in t)t[l]&&(e+=l+" ");return e.trim()}function normalizeProps(t){if(!t)return null;let{class:e,style:l}=t;return e&&!isString$2(e)&&(t.class=normalizeClass(e)),l&&(t.style=normalizeStyle(l)),t}const specialBooleanAttrs="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",isSpecialBooleanAttr=makeMap(specialBooleanAttrs);function includeBooleanAttr(t){return!!t||t===""}function looseCompareArrays(t,e){if(t.length!==e.length)return!1;let l=!0;for(let n=0;l&&n<t.length;n++)l=looseEqual(t[n],e[n]);return l}function looseEqual(t,e){if(t===e)return!0;let l=isDate$1(t),n=isDate$1(e);if(l||n)return l&&n?t.getTime()===e.getTime():!1;if(l=isSymbol(t),n=isSymbol(e),l||n)return t===e;if(l=isArray$3(t),n=isArray$3(e),l||n)return l&&n?looseCompareArrays(t,e):!1;if(l=isObject$2(t),n=isObject$2(e),l||n){if(!l||!n)return!1;const u=Object.keys(t).length,c=Object.keys(e).length;if(u!==c)return!1;for(const y in t){const b=t.hasOwnProperty(y),m=e.hasOwnProperty(y);if(b&&!m||!b&&m||!looseEqual(t[y],e[y]))return!1}}return String(t)===String(e)}function looseIndexOf(t,e){return t.findIndex(l=>looseEqual(l,e))}const isRef$1=t=>!!(t&&t.__v_isRef===!0),toDisplayString=t=>isString$2(t)?t:t==null?"":isArray$3(t)||isObject$2(t)&&(t.toString===objectToString||!isFunction$2(t.toString))?isRef$1(t)?toDisplayString(t.value):JSON.stringify(t,replacer,2):String(t),replacer=(t,e)=>isRef$1(e)?replacer(t,e.value):isMap(e)?{[`Map(${e.size})`]:[...e.entries()].reduce((l,[n,u],c)=>(l[stringifySymbol(n,c)+" =>"]=u,l),{})}:isSet(e)?{[`Set(${e.size})`]:[...e.values()].map(l=>stringifySymbol(l))}:isSymbol(e)?stringifySymbol(e):isObject$2(e)&&!isArray$3(e)&&!isPlainObject$3(e)?String(e):e,stringifySymbol=(t,e="")=>{var l;return isSymbol(t)?`Symbol(${(l=t.description)!=null?l:e})`:t};/**
- * @vue/reactivity v3.5.6
- * (c) 2018-present Yuxi (Evan) You and Vue contributors
- * @license MIT
- **/let activeEffectScope;class EffectScope{constructor(e=!1){this.detached=e,this._active=!0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=activeEffectScope,!e&&activeEffectScope&&(this.index=(activeEffectScope.scopes||(activeEffectScope.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let e,l;if(this.scopes)for(e=0,l=this.scopes.length;e<l;e++)this.scopes[e].pause();for(e=0,l=this.effects.length;e<l;e++)this.effects[e].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let e,l;if(this.scopes)for(e=0,l=this.scopes.length;e<l;e++)this.scopes[e].resume();for(e=0,l=this.effects.length;e<l;e++)this.effects[e].resume()}}run(e){if(this._active){const l=activeEffectScope;try{return activeEffectScope=this,e()}finally{activeEffectScope=l}}}on(){activeEffectScope=this}off(){activeEffectScope=this.parent}stop(e){if(this._active){let l,n;for(l=0,n=this.effects.length;l<n;l++)this.effects[l].stop();for(l=0,n=this.cleanups.length;l<n;l++)this.cleanups[l]();if(this.scopes)for(l=0,n=this.scopes.length;l<n;l++)this.scopes[l].stop(!0);if(!this.detached&&this.parent&&!e){const u=this.parent.scopes.pop();u&&u!==this&&(this.parent.scopes[this.index]=u,u.index=this.index)}this.parent=void 0,this._active=!1}}}function effectScope(t){return new EffectScope(t)}function getCurrentScope(){return activeEffectScope}function onScopeDispose(t,e=!1){activeEffectScope&&activeEffectScope.cleanups.push(t)}let activeSub;const pausedQueueEffects=new WeakSet;class ReactiveEffect{constructor(e){this.fn=e,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,activeEffectScope&&activeEffectScope.active&&activeEffectScope.effects.push(this)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,pausedQueueEffects.has(this)&&(pausedQueueEffects.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||batch(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,cleanupEffect(this),prepareDeps(this);const e=activeSub,l=shouldTrack;activeSub=this,shouldTrack=!0;try{return this.fn()}finally{cleanupDeps(this),activeSub=e,shouldTrack=l,this.flags&=-3}}stop(){if(this.flags&1){for(let e=this.deps;e;e=e.nextDep)removeSub(e);this.deps=this.depsTail=void 0,cleanupEffect(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?pausedQueueEffects.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){isDirty(this)&&this.run()}get dirty(){return isDirty(this)}}let batchDepth=0,batchedSub;function batch(t){t.flags|=8,t.next=batchedSub,batchedSub=t}function startBatch(){batchDepth++}function endBatch(){if(--batchDepth>0)return;let t;for(;batchedSub;){let e=batchedSub;for(batchedSub=void 0;e;){const l=e.next;if(e.next=void 0,e.flags&=-9,e.flags&1)try{e.trigger()}catch(n){t||(t=n)}e=l}}if(t)throw t}function prepareDeps(t){for(let e=t.deps;e;e=e.nextDep)e.version=-1,e.prevActiveLink=e.dep.activeLink,e.dep.activeLink=e}function cleanupDeps(t){let e,l=t.depsTail,n=l;for(;n;){const u=n.prevDep;n.version===-1?(n===l&&(l=u),removeSub(n),removeDep(n)):e=n,n.dep.activeLink=n.prevActiveLink,n.prevActiveLink=void 0,n=u}t.deps=e,t.depsTail=l}function isDirty(t){for(let e=t.deps;e;e=e.nextDep)if(e.dep.version!==e.version||e.dep.computed&&(refreshComputed(e.dep.computed)||e.dep.version!==e.version))return!0;return!!t._dirty}function refreshComputed(t){if(t.flags&4&&!(t.flags&16)||(t.flags&=-17,t.globalVersion===globalVersion))return;t.globalVersion=globalVersion;const e=t.dep;if(t.flags|=2,e.version>0&&!t.isSSR&&t.deps&&!isDirty(t)){t.flags&=-3;return}const l=activeSub,n=shouldTrack;activeSub=t,shouldTrack=!0;try{prepareDeps(t);const u=t.fn(t._value);(e.version===0||hasChanged(u,t._value))&&(t._value=u,e.version++)}catch(u){throw e.version++,u}finally{activeSub=l,shouldTrack=n,cleanupDeps(t),t.flags&=-3}}function removeSub(t){const{dep:e,prevSub:l,nextSub:n}=t;if(l&&(l.nextSub=n,t.prevSub=void 0),n&&(n.prevSub=l,t.nextSub=void 0),e.subs===t&&(e.subs=l),!e.subs&&e.computed){e.computed.flags&=-5;for(let u=e.computed.deps;u;u=u.nextDep)removeSub(u)}}function removeDep(t){const{prevDep:e,nextDep:l}=t;e&&(e.nextDep=l,t.prevDep=void 0),l&&(l.prevDep=e,t.nextDep=void 0)}function effect(t,e){t.effect instanceof ReactiveEffect&&(t=t.effect.fn);const l=new ReactiveEffect(t);e&&extend$1(l,e);try{l.run()}catch(u){throw l.stop(),u}const n=l.run.bind(l);return n.effect=l,n}function stop(t){t.effect.stop()}let shouldTrack=!0;const trackStack=[];function pauseTracking(){trackStack.push(shouldTrack),shouldTrack=!1}function resetTracking(){const t=trackStack.pop();shouldTrack=t===void 0?!0:t}function cleanupEffect(t){const{cleanup:e}=t;if(t.cleanup=void 0,e){const l=activeSub;activeSub=void 0;try{e()}finally{activeSub=l}}}let globalVersion=0;class Link{constructor(e,l){this.sub=e,this.dep=l,this.version=l.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class Dep{constructor(e){this.computed=e,this.version=0,this.activeLink=void 0,this.subs=void 0}track(e){if(!activeSub||!shouldTrack||activeSub===this.computed)return;let l=this.activeLink;if(l===void 0||l.sub!==activeSub)l=this.activeLink=new Link(activeSub,this),activeSub.deps?(l.prevDep=activeSub.depsTail,activeSub.depsTail.nextDep=l,activeSub.depsTail=l):activeSub.deps=activeSub.depsTail=l,activeSub.flags&4&&addSub(l);else if(l.version===-1&&(l.version=this.version,l.nextDep)){const n=l.nextDep;n.prevDep=l.prevDep,l.prevDep&&(l.prevDep.nextDep=n),l.prevDep=activeSub.depsTail,l.nextDep=void 0,activeSub.depsTail.nextDep=l,activeSub.depsTail=l,activeSub.deps===l&&(activeSub.deps=n)}return l}trigger(e){this.version++,globalVersion++,this.notify(e)}notify(e){startBatch();try{for(let l=this.subs;l;l=l.prevSub)l.sub.notify()&&l.sub.dep.notify()}finally{endBatch()}}}function addSub(t){const e=t.dep.computed;if(e&&!t.dep.subs){e.flags|=20;for(let n=e.deps;n;n=n.nextDep)addSub(n)}const l=t.dep.subs;l!==t&&(t.prevSub=l,l&&(l.nextSub=t)),t.dep.subs=t}const targetMap=new WeakMap,ITERATE_KEY=Symbol(""),MAP_KEY_ITERATE_KEY=Symbol(""),ARRAY_ITERATE_KEY=Symbol("");function track(t,e,l){if(shouldTrack&&activeSub){let n=targetMap.get(t);n||targetMap.set(t,n=new Map);let u=n.get(l);u||n.set(l,u=new Dep),u.track()}}function trigger(t,e,l,n,u,c){const y=targetMap.get(t);if(!y){globalVersion++;return}const b=m=>{m&&m.trigger()};if(startBatch(),e==="clear")y.forEach(b);else{const m=isArray$3(t),O=m&&isIntegerKey(l);if(m&&l==="length"){const N=Number(n);y.forEach((L,G)=>{(G==="length"||G===ARRAY_ITERATE_KEY||!isSymbol(G)&&G>=N)&&b(L)})}else switch(l!==void 0&&b(y.get(l)),O&&b(y.get(ARRAY_ITERATE_KEY)),e){case"add":m?O&&b(y.get("length")):(b(y.get(ITERATE_KEY)),isMap(t)&&b(y.get(MAP_KEY_ITERATE_KEY)));break;case"delete":m||(b(y.get(ITERATE_KEY)),isMap(t)&&b(y.get(MAP_KEY_ITERATE_KEY)));break;case"set":isMap(t)&&b(y.get(ITERATE_KEY));break}}endBatch()}function getDepFromReactive(t,e){var l;return(l=targetMap.get(t))==null?void 0:l.get(e)}function reactiveReadArray(t){const e=toRaw(t);return e===t?e:(track(e,"iterate",ARRAY_ITERATE_KEY),isShallow(t)?e:e.map(toReactive))}function shallowReadArray(t){return track(t=toRaw(t),"iterate",ARRAY_ITERATE_KEY),t}const arrayInstrumentations={__proto__:null,[Symbol.iterator](){return iterator(this,Symbol.iterator,toReactive)},concat(...t){return reactiveReadArray(this).concat(...t.map(e=>isArray$3(e)?reactiveReadArray(e):e))},entries(){return iterator(this,"entries",t=>(t[1]=toReactive(t[1]),t))},every(t,e){return apply(this,"every",t,e,void 0,arguments)},filter(t,e){return apply(this,"filter",t,e,l=>l.map(toReactive),arguments)},find(t,e){return apply(this,"find",t,e,toReactive,arguments)},findIndex(t,e){return apply(this,"findIndex",t,e,void 0,arguments)},findLast(t,e){return apply(this,"findLast",t,e,toReactive,arguments)},findLastIndex(t,e){return apply(this,"findLastIndex",t,e,void 0,arguments)},forEach(t,e){return apply(this,"forEach",t,e,void 0,arguments)},includes(...t){return searchProxy(this,"includes",t)},indexOf(...t){return searchProxy(this,"indexOf",t)},join(t){return reactiveReadArray(this).join(t)},lastIndexOf(...t){return searchProxy(this,"lastIndexOf",t)},map(t,e){return apply(this,"map",t,e,void 0,arguments)},pop(){return noTracking(this,"pop")},push(...t){return noTracking(this,"push",t)},reduce(t,...e){return reduce(this,"reduce",t,e)},reduceRight(t,...e){return reduce(this,"reduceRight",t,e)},shift(){return noTracking(this,"shift")},some(t,e){return apply(this,"some",t,e,void 0,arguments)},splice(...t){return noTracking(this,"splice",t)},toReversed(){return reactiveReadArray(this).toReversed()},toSorted(t){return reactiveReadArray(this).toSorted(t)},toSpliced(...t){return reactiveReadArray(this).toSpliced(...t)},unshift(...t){return noTracking(this,"unshift",t)},values(){return iterator(this,"values",toReactive)}};function iterator(t,e,l){const n=shallowReadArray(t),u=n[e]();return n!==t&&!isShallow(t)&&(u._next=u.next,u.next=()=>{const c=u._next();return c.value&&(c.value=l(c.value)),c}),u}const arrayProto=Array.prototype;function apply(t,e,l,n,u,c){const y=shallowReadArray(t),b=y!==t&&!isShallow(t),m=y[e];if(m!==arrayProto[e]){const L=m.apply(t,c);return b?toReactive(L):L}let O=l;y!==t&&(b?O=function(L,G){return l.call(this,toReactive(L),G,t)}:l.length>2&&(O=function(L,G){return l.call(this,L,G,t)}));const N=m.call(y,O,n);return b&&u?u(N):N}function reduce(t,e,l,n){const u=shallowReadArray(t);let c=l;return u!==t&&(isShallow(t)?l.length>3&&(c=function(y,b,m){return l.call(this,y,b,m,t)}):c=function(y,b,m){return l.call(this,y,toReactive(b),m,t)}),u[e](c,...n)}function searchProxy(t,e,l){const n=toRaw(t);track(n,"iterate",ARRAY_ITERATE_KEY);const u=n[e](...l);return(u===-1||u===!1)&&isProxy(l[0])?(l[0]=toRaw(l[0]),n[e](...l)):u}function noTracking(t,e,l=[]){pauseTracking(),startBatch();const n=toRaw(t)[e].apply(t,l);return endBatch(),resetTracking(),n}const isNonTrackableKeys=makeMap("__proto__,__v_isRef,__isVue"),builtInSymbols=new Set(Object.getOwnPropertyNames(Symbol).filter(t=>t!=="arguments"&&t!=="caller").map(t=>Symbol[t]).filter(isSymbol));function hasOwnProperty$2(t){isSymbol(t)||(t=String(t));const e=toRaw(this);return track(e,"has",t),e.hasOwnProperty(t)}class BaseReactiveHandler{constructor(e=!1,l=!1){this._isReadonly=e,this._isShallow=l}get(e,l,n){const u=this._isReadonly,c=this._isShallow;if(l==="__v_isReactive")return!u;if(l==="__v_isReadonly")return u;if(l==="__v_isShallow")return c;if(l==="__v_raw")return n===(u?c?shallowReadonlyMap:readonlyMap:c?shallowReactiveMap:reactiveMap).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;const y=isArray$3(e);if(!u){let m;if(y&&(m=arrayInstrumentations[l]))return m;if(l==="hasOwnProperty")return hasOwnProperty$2}const b=Reflect.get(e,l,isRef(e)?e:n);return(isSymbol(l)?builtInSymbols.has(l):isNonTrackableKeys(l))||(u||track(e,"get",l),c)?b:isRef(b)?y&&isIntegerKey(l)?b:b.value:isObject$2(b)?u?readonly(b):reactive(b):b}}class MutableReactiveHandler extends BaseReactiveHandler{constructor(e=!1){super(!1,e)}set(e,l,n,u){let c=e[l];if(!this._isShallow){const m=isReadonly(c);if(!isShallow(n)&&!isReadonly(n)&&(c=toRaw(c),n=toRaw(n)),!isArray$3(e)&&isRef(c)&&!isRef(n))return m?!1:(c.value=n,!0)}const y=isArray$3(e)&&isIntegerKey(l)?Number(l)<e.length:hasOwn(e,l),b=Reflect.set(e,l,n,isRef(e)?e:u);return e===toRaw(u)&&(y?hasChanged(n,c)&&trigger(e,"set",l,n):trigger(e,"add",l,n)),b}deleteProperty(e,l){const n=hasOwn(e,l);e[l];const u=Reflect.deleteProperty(e,l);return u&&n&&trigger(e,"delete",l,void 0),u}has(e,l){const n=Reflect.has(e,l);return(!isSymbol(l)||!builtInSymbols.has(l))&&track(e,"has",l),n}ownKeys(e){return track(e,"iterate",isArray$3(e)?"length":ITERATE_KEY),Reflect.ownKeys(e)}}class ReadonlyReactiveHandler extends BaseReactiveHandler{constructor(e=!1){super(!0,e)}set(e,l){return!0}deleteProperty(e,l){return!0}}const mutableHandlers=new MutableReactiveHandler,readonlyHandlers=new ReadonlyReactiveHandler,shallowReactiveHandlers=new MutableReactiveHandler(!0),shallowReadonlyHandlers=new ReadonlyReactiveHandler(!0),toShallow=t=>t,getProto=t=>Reflect.getPrototypeOf(t);function get(t,e,l=!1,n=!1){t=t.__v_raw;const u=toRaw(t),c=toRaw(e);l||(hasChanged(e,c)&&track(u,"get",e),track(u,"get",c));const{has:y}=getProto(u),b=n?toShallow:l?toReadonly:toReactive;if(y.call(u,e))return b(t.get(e));if(y.call(u,c))return b(t.get(c));t!==u&&t.get(e)}function has$1(t,e=!1){const l=this.__v_raw,n=toRaw(l),u=toRaw(t);return e||(hasChanged(t,u)&&track(n,"has",t),track(n,"has",u)),t===u?l.has(t):l.has(t)||l.has(u)}function size(t,e=!1){return t=t.__v_raw,!e&&track(toRaw(t),"iterate",ITERATE_KEY),Reflect.get(t,"size",t)}function add$2(t,e=!1){!e&&!isShallow(t)&&!isReadonly(t)&&(t=toRaw(t));const l=toRaw(this);return getProto(l).has.call(l,t)||(l.add(t),trigger(l,"add",t,t)),this}function set(t,e,l=!1){!l&&!isShallow(e)&&!isReadonly(e)&&(e=toRaw(e));const n=toRaw(this),{has:u,get:c}=getProto(n);let y=u.call(n,t);y||(t=toRaw(t),y=u.call(n,t));const b=c.call(n,t);return n.set(t,e),y?hasChanged(e,b)&&trigger(n,"set",t,e):trigger(n,"add",t,e),this}function deleteEntry(t){const e=toRaw(this),{has:l,get:n}=getProto(e);let u=l.call(e,t);u||(t=toRaw(t),u=l.call(e,t)),n&&n.call(e,t);const c=e.delete(t);return u&&trigger(e,"delete",t,void 0),c}function clear(){const t=toRaw(this),e=t.size!==0,l=t.clear();return e&&trigger(t,"clear",void 0,void 0),l}function createForEach(t,e){return function(n,u){const c=this,y=c.__v_raw,b=toRaw(y),m=e?toShallow:t?toReadonly:toReactive;return!t&&track(b,"iterate",ITERATE_KEY),y.forEach((O,N)=>n.call(u,m(O),m(N),c))}}function createIterableMethod(t,e,l){return function(...n){const u=this.__v_raw,c=toRaw(u),y=isMap(c),b=t==="entries"||t===Symbol.iterator&&y,m=t==="keys"&&y,O=u[t](...n),N=l?toShallow:e?toReadonly:toReactive;return!e&&track(c,"iterate",m?MAP_KEY_ITERATE_KEY:ITERATE_KEY),{next(){const{value:L,done:G}=O.next();return G?{value:L,done:G}:{value:b?[N(L[0]),N(L[1])]:N(L),done:G}},[Symbol.iterator](){return this}}}}function createReadonlyMethod(t){return function(...e){return t==="delete"?!1:t==="clear"?void 0:this}}function createInstrumentations(){const t={get(c){return get(this,c)},get size(){return size(this)},has:has$1,add:add$2,set,delete:deleteEntry,clear,forEach:createForEach(!1,!1)},e={get(c){return get(this,c,!1,!0)},get size(){return size(this)},has:has$1,add(c){return add$2.call(this,c,!0)},set(c,y){return set.call(this,c,y,!0)},delete:deleteEntry,clear,forEach:createForEach(!1,!0)},l={get(c){return get(this,c,!0)},get size(){return size(this,!0)},has(c){return has$1.call(this,c,!0)},add:createReadonlyMethod("add"),set:createReadonlyMethod("set"),delete:createReadonlyMethod("delete"),clear:createReadonlyMethod("clear"),forEach:createForEach(!0,!1)},n={get(c){return get(this,c,!0,!0)},get size(){return size(this,!0)},has(c){return has$1.call(this,c,!0)},add:createReadonlyMethod("add"),set:createReadonlyMethod("set"),delete:createReadonlyMethod("delete"),clear:createReadonlyMethod("clear"),forEach:createForEach(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(c=>{t[c]=createIterableMethod(c,!1,!1),l[c]=createIterableMethod(c,!0,!1),e[c]=createIterableMethod(c,!1,!0),n[c]=createIterableMethod(c,!0,!0)}),[t,l,e,n]}const[mutableInstrumentations,readonlyInstrumentations,shallowInstrumentations,shallowReadonlyInstrumentations]=createInstrumentations();function createInstrumentationGetter(t,e){const l=e?t?shallowReadonlyInstrumentations:shallowInstrumentations:t?readonlyInstrumentations:mutableInstrumentations;return(n,u,c)=>u==="__v_isReactive"?!t:u==="__v_isReadonly"?t:u==="__v_raw"?n:Reflect.get(hasOwn(l,u)&&u in n?l:n,u,c)}const mutableCollectionHandlers={get:createInstrumentationGetter(!1,!1)},shallowCollectionHandlers={get:createInstrumentationGetter(!1,!0)},readonlyCollectionHandlers={get:createInstrumentationGetter(!0,!1)},shallowReadonlyCollectionHandlers={get:createInstrumentationGetter(!0,!0)},reactiveMap=new WeakMap,shallowReactiveMap=new WeakMap,readonlyMap=new WeakMap,shallowReadonlyMap=new WeakMap;function targetTypeMap(t){switch(t){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function getTargetType(t){return t.__v_skip||!Object.isExtensible(t)?0:targetTypeMap(toRawType(t))}function reactive(t){return isReadonly(t)?t:createReactiveObject(t,!1,mutableHandlers,mutableCollectionHandlers,reactiveMap)}function shallowReactive(t){return createReactiveObject(t,!1,shallowReactiveHandlers,shallowCollectionHandlers,shallowReactiveMap)}function readonly(t){return createReactiveObject(t,!0,readonlyHandlers,readonlyCollectionHandlers,readonlyMap)}function shallowReadonly(t){return createReactiveObject(t,!0,shallowReadonlyHandlers,shallowReadonlyCollectionHandlers,shallowReadonlyMap)}function createReactiveObject(t,e,l,n,u){if(!isObject$2(t)||t.__v_raw&&!(e&&t.__v_isReactive))return t;const c=u.get(t);if(c)return c;const y=getTargetType(t);if(y===0)return t;const b=new Proxy(t,y===2?n:l);return u.set(t,b),b}function isReactive(t){return isReadonly(t)?isReactive(t.__v_raw):!!(t&&t.__v_isReactive)}function isReadonly(t){return!!(t&&t.__v_isReadonly)}function isShallow(t){return!!(t&&t.__v_isShallow)}function isProxy(t){return t?!!t.__v_raw:!1}function toRaw(t){const e=t&&t.__v_raw;return e?toRaw(e):t}function markRaw(t){return!hasOwn(t,"__v_skip")&&Object.isExtensible(t)&&def(t,"__v_skip",!0),t}const toReactive=t=>isObject$2(t)?reactive(t):t,toReadonly=t=>isObject$2(t)?readonly(t):t;function isRef(t){return t?t.__v_isRef===!0:!1}function ref(t){return createRef(t,!1)}function shallowRef(t){return createRef(t,!0)}function createRef(t,e){return isRef(t)?t:new RefImpl(t,e)}class RefImpl{constructor(e,l){this.dep=new Dep,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=l?e:toRaw(e),this._value=l?e:toReactive(e),this.__v_isShallow=l}get value(){return this.dep.track(),this._value}set value(e){const l=this._rawValue,n=this.__v_isShallow||isShallow(e)||isReadonly(e);e=n?e:toRaw(e),hasChanged(e,l)&&(this._rawValue=e,this._value=n?e:toReactive(e),this.dep.trigger())}}function triggerRef(t){t.dep.trigger()}function unref(t){return isRef(t)?t.value:t}function toValue(t){return isFunction$2(t)?t():unref(t)}const shallowUnwrapHandlers={get:(t,e,l)=>e==="__v_raw"?t:unref(Reflect.get(t,e,l)),set:(t,e,l,n)=>{const u=t[e];return isRef(u)&&!isRef(l)?(u.value=l,!0):Reflect.set(t,e,l,n)}};function proxyRefs(t){return isReactive(t)?t:new Proxy(t,shallowUnwrapHandlers)}class CustomRefImpl{constructor(e){this.__v_isRef=!0,this._value=void 0;const l=this.dep=new Dep,{get:n,set:u}=e(l.track.bind(l),l.trigger.bind(l));this._get=n,this._set=u}get value(){return this._value=this._get()}set value(e){this._set(e)}}function customRef(t){return new CustomRefImpl(t)}function toRefs(t){const e=isArray$3(t)?new Array(t.length):{};for(const l in t)e[l]=propertyToRef(t,l);return e}class ObjectRefImpl{constructor(e,l,n){this._object=e,this._key=l,this._defaultValue=n,this.__v_isRef=!0,this._value=void 0}get value(){const e=this._object[this._key];return this._value=e===void 0?this._defaultValue:e}set value(e){this._object[this._key]=e}get dep(){return getDepFromReactive(toRaw(this._object),this._key)}}class GetterRefImpl{constructor(e){this._getter=e,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}}function toRef(t,e,l){return isRef(t)?t:isFunction$2(t)?new GetterRefImpl(t):isObject$2(t)&&arguments.length>1?propertyToRef(t,e,l):ref(t)}function propertyToRef(t,e,l){const n=t[e];return isRef(n)?n:new ObjectRefImpl(t,e,l)}class ComputedRefImpl{constructor(e,l,n){this.fn=e,this.setter=l,this._value=void 0,this.dep=new Dep(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=globalVersion-1,this.effect=this,this.__v_isReadonly=!l,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&activeSub!==this)return batch(this),!0}get value(){const e=this.dep.track();return refreshComputed(this),e&&(e.version=this.dep.version),this._value}set value(e){this.setter&&this.setter(e)}}function computed$1(t,e,l=!1){let n,u;return isFunction$2(t)?n=t:(n=t.get,u=t.set),new ComputedRefImpl(n,u,l)}const TrackOpTypes={GET:"get",HAS:"has",ITERATE:"iterate"},TriggerOpTypes={SET:"set",ADD:"add",DELETE:"delete",CLEAR:"clear"},INITIAL_WATCHER_VALUE={},cleanupMap=new WeakMap;let activeWatcher;function getCurrentWatcher(){return activeWatcher}function onWatcherCleanup(t,e=!1,l=activeWatcher){if(l){let n=cleanupMap.get(l);n||cleanupMap.set(l,n=[]),n.push(t)}}function watch$1(t,e,l=EMPTY_OBJ){const{immediate:n,deep:u,once:c,scheduler:y,augmentJob:b,call:m}=l,O=Ve=>u?Ve:isShallow(Ve)||u===!1||u===0?traverse(Ve,1):traverse(Ve);let N,L,G,q,J=!1,fe=!1;if(isRef(t)?(L=()=>t.value,J=isShallow(t)):isReactive(t)?(L=()=>O(t),J=!0):isArray$3(t)?(fe=!0,J=t.some(Ve=>isReactive(Ve)||isShallow(Ve)),L=()=>t.map(Ve=>{if(isRef(Ve))return Ve.value;if(isReactive(Ve))return O(Ve);if(isFunction$2(Ve))return m?m(Ve,2):Ve()})):isFunction$2(t)?e?L=m?()=>m(t,2):t:L=()=>{if(G){pauseTracking();try{G()}finally{resetTracking()}}const Ve=activeWatcher;activeWatcher=N;try{return m?m(t,3,[q]):t(q)}finally{activeWatcher=Ve}}:L=NOOP,e&&u){const Ve=L,rt=u===!0?1/0:u;L=()=>traverse(Ve(),rt)}const ve=getCurrentScope(),ne=()=>{N.stop(),ve&&remove(ve.effects,N)};if(c&&e){const Ve=e;e=(...rt)=>{Ve(...rt),ne()}}let Ue=fe?new Array(t.length).fill(INITIAL_WATCHER_VALUE):INITIAL_WATCHER_VALUE;const De=Ve=>{if(!(!(N.flags&1)||!N.dirty&&!Ve))if(e){const rt=N.run();if(u||J||(fe?rt.some((Ae,Te)=>hasChanged(Ae,Ue[Te])):hasChanged(rt,Ue))){G&&G();const Ae=activeWatcher;activeWatcher=N;try{const Te=[rt,Ue===INITIAL_WATCHER_VALUE?void 0:fe&&Ue[0]===INITIAL_WATCHER_VALUE?[]:Ue,q];m?m(e,3,Te):e(...Te),Ue=rt}finally{activeWatcher=Ae}}}else N.run()};return b&&b(De),N=new ReactiveEffect(L),N.scheduler=y?()=>y(De,!1):De,q=Ve=>onWatcherCleanup(Ve,!1,N),G=N.onStop=()=>{const Ve=cleanupMap.get(N);if(Ve){if(m)m(Ve,4);else for(const rt of Ve)rt();cleanupMap.delete(N)}},e?n?De(!0):Ue=N.run():y?y(De.bind(null,!0),!0):N.run(),ne.pause=N.pause.bind(N),ne.resume=N.resume.bind(N),ne.stop=ne,ne}function traverse(t,e=1/0,l){if(e<=0||!isObject$2(t)||t.__v_skip||(l=l||new Set,l.has(t)))return t;if(l.add(t),e--,isRef(t))traverse(t.value,e,l);else if(isArray$3(t))for(let n=0;n<t.length;n++)traverse(t[n],e,l);else if(isSet(t)||isMap(t))t.forEach(n=>{traverse(n,e,l)});else if(isPlainObject$3(t)){for(const n in t)traverse(t[n],e,l);for(const n of Object.getOwnPropertySymbols(t))Object.prototype.propertyIsEnumerable.call(t,n)&&traverse(t[n],e,l)}return t}/**
- * @vue/runtime-core v3.5.6
- * (c) 2018-present Yuxi (Evan) You and Vue contributors
- * @license MIT
- **/const stack$1=[];function pushWarningContext(t){stack$1.push(t)}function popWarningContext(){stack$1.pop()}let isWarning=!1;function warn$1(t,...e){if(isWarning)return;isWarning=!0,pauseTracking();const l=stack$1.length?stack$1[stack$1.length-1].component:null,n=l&&l.appContext.config.warnHandler,u=getComponentTrace();if(n)callWithErrorHandling(n,l,11,[t+e.map(c=>{var y,b;return(b=(y=c.toString)==null?void 0:y.call(c))!=null?b:JSON.stringify(c)}).join(""),l&&l.proxy,u.map(({vnode:c})=>`at <${formatComponentName(l,c.type)}>`).join(`
- `),u]);else{const c=[`[Vue warn]: ${t}`,...e];u.length&&c.push(`
- `,...formatTrace(u)),console.warn(...c)}resetTracking(),isWarning=!1}function getComponentTrace(){let t=stack$1[stack$1.length-1];if(!t)return[];const e=[];for(;t;){const l=e[0];l&&l.vnode===t?l.recurseCount++:e.push({vnode:t,recurseCount:0});const n=t.component&&t.component.parent;t=n&&n.vnode}return e}function formatTrace(t){const e=[];return t.forEach((l,n)=>{e.push(...n===0?[]:[`
- `],...formatTraceEntry(l))}),e}function formatTraceEntry({vnode:t,recurseCount:e}){const l=e>0?`... (${e} recursive calls)`:"",n=t.component?t.component.parent==null:!1,u=` at <${formatComponentName(t.component,t.type,n)}`,c=">"+l;return t.props?[u,...formatProps(t.props),c]:[u+c]}function formatProps(t){const e=[],l=Object.keys(t);return l.slice(0,3).forEach(n=>{e.push(...formatProp(n,t[n]))}),l.length>3&&e.push(" ..."),e}function formatProp(t,e,l){return isString$2(e)?(e=JSON.stringify(e),l?e:[`${t}=${e}`]):typeof e=="number"||typeof e=="boolean"||e==null?l?e:[`${t}=${e}`]:isRef(e)?(e=formatProp(t,toRaw(e.value),!0),l?e:[`${t}=Ref<`,e,">"]):isFunction$2(e)?[`${t}=fn${e.name?`<${e.name}>`:""}`]:(e=toRaw(e),l?e:[`${t}=`,e])}function assertNumber(t,e){}const ErrorCodes={SETUP_FUNCTION:0,0:"SETUP_FUNCTION",RENDER_FUNCTION:1,1:"RENDER_FUNCTION",NATIVE_EVENT_HANDLER:5,5:"NATIVE_EVENT_HANDLER",COMPONENT_EVENT_HANDLER:6,6:"COMPONENT_EVENT_HANDLER",VNODE_HOOK:7,7:"VNODE_HOOK",DIRECTIVE_HOOK:8,8:"DIRECTIVE_HOOK",TRANSITION_HOOK:9,9:"TRANSITION_HOOK",APP_ERROR_HANDLER:10,10:"APP_ERROR_HANDLER",APP_WARN_HANDLER:11,11:"APP_WARN_HANDLER",FUNCTION_REF:12,12:"FUNCTION_REF",ASYNC_COMPONENT_LOADER:13,13:"ASYNC_COMPONENT_LOADER",SCHEDULER:14,14:"SCHEDULER",COMPONENT_UPDATE:15,15:"COMPONENT_UPDATE",APP_UNMOUNT_CLEANUP:16,16:"APP_UNMOUNT_CLEANUP"},ErrorTypeStrings$1={sp:"serverPrefetch hook",bc:"beforeCreate hook",c:"created hook",bm:"beforeMount hook",m:"mounted hook",bu:"beforeUpdate hook",u:"updated",bum:"beforeUnmount hook",um:"unmounted hook",a:"activated hook",da:"deactivated hook",ec:"errorCaptured hook",rtc:"renderTracked hook",rtg:"renderTriggered hook",0:"setup function",1:"render function",2:"watcher getter",3:"watcher callback",4:"watcher cleanup function",5:"native event handler",6:"component event handler",7:"vnode hook",8:"directive hook",9:"transition hook",10:"app errorHandler",11:"app warnHandler",12:"ref function",13:"async component loader",14:"scheduler flush",15:"component update",16:"app unmount cleanup function"};function callWithErrorHandling(t,e,l,n){try{return n?t(...n):t()}catch(u){handleError(u,e,l)}}function callWithAsyncErrorHandling(t,e,l,n){if(isFunction$2(t)){const u=callWithErrorHandling(t,e,l,n);return u&&isPromise$2(u)&&u.catch(c=>{handleError(c,e,l)}),u}if(isArray$3(t)){const u=[];for(let c=0;c<t.length;c++)u.push(callWithAsyncErrorHandling(t[c],e,l,n));return u}}function handleError(t,e,l,n=!0){const u=e?e.vnode:null,{errorHandler:c,throwUnhandledErrorInProduction:y}=e&&e.appContext.config||EMPTY_OBJ;if(e){let b=e.parent;const m=e.proxy,O=`https://vuejs.org/error-reference/#runtime-${l}`;for(;b;){const N=b.ec;if(N){for(let L=0;L<N.length;L++)if(N[L](t,m,O)===!1)return}b=b.parent}if(c){pauseTracking(),callWithErrorHandling(c,null,10,[t,m,O]),resetTracking();return}}logError(t,l,u,n,y)}function logError(t,e,l,n=!0,u=!1){if(u)throw t;console.error(t)}let isFlushing=!1,isFlushPending=!1;const queue=[];let flushIndex=0;const pendingPostFlushCbs=[];let activePostFlushCbs=null,postFlushIndex=0;const resolvedPromise=Promise.resolve();let currentFlushPromise=null;function nextTick(t){const e=currentFlushPromise||resolvedPromise;return t?e.then(this?t.bind(this):t):e}function findInsertionIndex(t){let e=isFlushing?flushIndex+1:0,l=queue.length;for(;e<l;){const n=e+l>>>1,u=queue[n],c=getId(u);c<t||c===t&&u.flags&2?e=n+1:l=n}return e}function queueJob(t){if(!(t.flags&1)){const e=getId(t),l=queue[queue.length-1];!l||!(t.flags&2)&&e>=getId(l)?queue.push(t):queue.splice(findInsertionIndex(e),0,t),t.flags|=1,queueFlush()}}function queueFlush(){!isFlushing&&!isFlushPending&&(isFlushPending=!0,currentFlushPromise=resolvedPromise.then(flushJobs))}function queuePostFlushCb(t){isArray$3(t)?pendingPostFlushCbs.push(...t):activePostFlushCbs&&t.id===-1?activePostFlushCbs.splice(postFlushIndex+1,0,t):t.flags&1||(pendingPostFlushCbs.push(t),t.flags|=1),queueFlush()}function flushPreFlushCbs(t,e,l=isFlushing?flushIndex+1:0){for(;l<queue.length;l++){const n=queue[l];if(n&&n.flags&2){if(t&&n.id!==t.uid)continue;queue.splice(l,1),l--,n.flags&4&&(n.flags&=-2),n(),n.flags&=-2}}}function flushPostFlushCbs(t){if(pendingPostFlushCbs.length){const e=[...new Set(pendingPostFlushCbs)].sort((l,n)=>getId(l)-getId(n));if(pendingPostFlushCbs.length=0,activePostFlushCbs){activePostFlushCbs.push(...e);return}for(activePostFlushCbs=e,postFlushIndex=0;postFlushIndex<activePostFlushCbs.length;postFlushIndex++){const l=activePostFlushCbs[postFlushIndex];l.flags&4&&(l.flags&=-2),l.flags&8||l(),l.flags&=-2}activePostFlushCbs=null,postFlushIndex=0}}const getId=t=>t.id==null?t.flags&2?-1:1/0:t.id;function flushJobs(t){isFlushPending=!1,isFlushing=!0;try{for(flushIndex=0;flushIndex<queue.length;flushIndex++){const e=queue[flushIndex];e&&!(e.flags&8)&&(e.flags&4&&(e.flags&=-2),callWithErrorHandling(e,e.i,e.i?15:14),e.flags&=-2)}}finally{for(;flushIndex<queue.length;flushIndex++){const e=queue[flushIndex];e&&(e.flags&=-2)}flushIndex=0,queue.length=0,flushPostFlushCbs(),isFlushing=!1,currentFlushPromise=null,(queue.length||pendingPostFlushCbs.length)&&flushJobs()}}let devtools$1,buffer$2=[];function setDevtoolsHook$1(t,e){var l,n;devtools$1=t,devtools$1?(devtools$1.enabled=!0,buffer$2.forEach(({event:u,args:c})=>devtools$1.emit(u,...c)),buffer$2=[]):typeof window<"u"&&window.HTMLElement&&!((n=(l=window.navigator)==null?void 0:l.userAgent)!=null&&n.includes("jsdom"))?((e.__VUE_DEVTOOLS_HOOK_REPLAY__=e.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push(c=>{setDevtoolsHook$1(c,e)}),setTimeout(()=>{devtools$1||(e.__VUE_DEVTOOLS_HOOK_REPLAY__=null,buffer$2=[])},3e3)):buffer$2=[]}let currentRenderingInstance=null,currentScopeId=null;function setCurrentRenderingInstance(t){const e=currentRenderingInstance;return currentRenderingInstance=t,currentScopeId=t&&t.type.__scopeId||null,e}function pushScopeId(t){currentScopeId=t}function popScopeId(){currentScopeId=null}const withScopeId=t=>withCtx;function withCtx(t,e=currentRenderingInstance,l){if(!e||t._n)return t;const n=(...u)=>{n._d&&setBlockTracking(-1);const c=setCurrentRenderingInstance(e);let y;try{y=t(...u)}finally{setCurrentRenderingInstance(c),n._d&&setBlockTracking(1)}return y};return n._n=!0,n._c=!0,n._d=!0,n}function withDirectives(t,e){if(currentRenderingInstance===null)return t;const l=getComponentPublicInstance(currentRenderingInstance),n=t.dirs||(t.dirs=[]);for(let u=0;u<e.length;u++){let[c,y,b,m=EMPTY_OBJ]=e[u];c&&(isFunction$2(c)&&(c={mounted:c,updated:c}),c.deep&&traverse(y),n.push({dir:c,instance:l,value:y,oldValue:void 0,arg:b,modifiers:m}))}return t}function invokeDirectiveHook(t,e,l,n){const u=t.dirs,c=e&&e.dirs;for(let y=0;y<u.length;y++){const b=u[y];c&&(b.oldValue=c[y].value);let m=b.dir[n];m&&(pauseTracking(),callWithAsyncErrorHandling(m,l,8,[t.el,b,t,e]),resetTracking())}}const TeleportEndKey=Symbol("_vte"),isTeleport=t=>t.__isTeleport,isTeleportDisabled=t=>t&&(t.disabled||t.disabled===""),isTeleportDeferred=t=>t&&(t.defer||t.defer===""),isTargetSVG=t=>typeof SVGElement<"u"&&t instanceof SVGElement,isTargetMathML=t=>typeof MathMLElement=="function"&&t instanceof MathMLElement,resolveTarget=(t,e)=>{const l=t&&t.to;return isString$2(l)?e?e(l):null:l},TeleportImpl={name:"Teleport",__isTeleport:!0,process(t,e,l,n,u,c,y,b,m,O){const{mc:N,pc:L,pbc:G,o:{insert:q,querySelector:J,createText:fe,createComment:ve}}=O,ne=isTeleportDisabled(e.props);let{shapeFlag:Ue,children:De,dynamicChildren:Ve}=e;if(t==null){const rt=e.el=fe(""),Ae=e.anchor=fe("");q(rt,l,n),q(Ae,l,n);const Te=(ie,ue)=>{Ue&16&&(u&&u.isCE&&(u.ce._teleportTarget=ie),N(De,ie,ue,u,c,y,b,m))},Xe=()=>{const ie=e.target=resolveTarget(e.props,J),ue=prepareAnchor(ie,e,fe,q);ie&&(y!=="svg"&&isTargetSVG(ie)?y="svg":y!=="mathml"&&isTargetMathML(ie)&&(y="mathml"),ne||(Te(ie,ue),updateCssVars(e)))};ne&&(Te(l,Ae),updateCssVars(e)),isTeleportDeferred(e.props)?queuePostRenderEffect(Xe,c):Xe()}else{e.el=t.el,e.targetStart=t.targetStart;const rt=e.anchor=t.anchor,Ae=e.target=t.target,Te=e.targetAnchor=t.targetAnchor,Xe=isTeleportDisabled(t.props),ie=Xe?l:Ae,ue=Xe?rt:Te;if(y==="svg"||isTargetSVG(Ae)?y="svg":(y==="mathml"||isTargetMathML(Ae))&&(y="mathml"),Ve?(G(t.dynamicChildren,Ve,ie,u,c,y,b),traverseStaticChildren(t,e,!0)):m||L(t,e,ie,ue,u,c,y,b,!1),ne)Xe?e.props&&t.props&&e.props.to!==t.props.to&&(e.props.to=t.props.to):moveTeleport(e,l,rt,O,1);else if((e.props&&e.props.to)!==(t.props&&t.props.to)){const pt=e.target=resolveTarget(e.props,J);pt&&moveTeleport(e,pt,null,O,0)}else Xe&&moveTeleport(e,Ae,Te,O,1);updateCssVars(e)}},remove(t,e,l,{um:n,o:{remove:u}},c){const{shapeFlag:y,children:b,anchor:m,targetStart:O,targetAnchor:N,target:L,props:G}=t;if(L&&(u(O),u(N)),c&&u(m),y&16){const q=c||!isTeleportDisabled(G);for(let J=0;J<b.length;J++){const fe=b[J];n(fe,e,l,q,!!fe.dynamicChildren)}}},move:moveTeleport,hydrate:hydrateTeleport};function moveTeleport(t,e,l,{o:{insert:n},m:u},c=2){c===0&&n(t.targetAnchor,e,l);const{el:y,anchor:b,shapeFlag:m,children:O,props:N}=t,L=c===2;if(L&&n(y,e,l),(!L||isTeleportDisabled(N))&&m&16)for(let G=0;G<O.length;G++)u(O[G],e,l,2);L&&n(b,e,l)}function hydrateTeleport(t,e,l,n,u,c,{o:{nextSibling:y,parentNode:b,querySelector:m,insert:O,createText:N}},L){const G=e.target=resolveTarget(e.props,m);if(G){const q=G._lpa||G.firstChild;if(e.shapeFlag&16)if(isTeleportDisabled(e.props))e.anchor=L(y(t),e,b(t),l,n,u,c),e.targetStart=q,e.targetAnchor=q&&y(q);else{e.anchor=y(t);let J=q;for(;J;){if(J&&J.nodeType===8){if(J.data==="teleport start anchor")e.targetStart=J;else if(J.data==="teleport anchor"){e.targetAnchor=J,G._lpa=e.targetAnchor&&y(e.targetAnchor);break}}J=y(J)}e.targetAnchor||prepareAnchor(G,e,N,O),L(q&&y(q),e,G,l,n,u,c)}updateCssVars(e)}return e.anchor&&y(e.anchor)}const Teleport=TeleportImpl;function updateCssVars(t){const e=t.ctx;if(e&&e.ut){let l=t.targetStart;for(;l&&l!==t.targetAnchor;)l.nodeType===1&&l.setAttribute("data-v-owner",e.uid),l=l.nextSibling;e.ut()}}function prepareAnchor(t,e,l,n){const u=e.targetStart=l(""),c=e.targetAnchor=l("");return u[TeleportEndKey]=c,t&&(n(u,t),n(c,t)),c}const leaveCbKey=Symbol("_leaveCb"),enterCbKey$1=Symbol("_enterCb");function useTransitionState(){const t={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return onMounted(()=>{t.isMounted=!0}),onBeforeUnmount(()=>{t.isUnmounting=!0}),t}const TransitionHookValidator=[Function,Array],BaseTransitionPropsValidators={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:TransitionHookValidator,onEnter:TransitionHookValidator,onAfterEnter:TransitionHookValidator,onEnterCancelled:TransitionHookValidator,onBeforeLeave:TransitionHookValidator,onLeave:TransitionHookValidator,onAfterLeave:TransitionHookValidator,onLeaveCancelled:TransitionHookValidator,onBeforeAppear:TransitionHookValidator,onAppear:TransitionHookValidator,onAfterAppear:TransitionHookValidator,onAppearCancelled:TransitionHookValidator},recursiveGetSubtree=t=>{const e=t.subTree;return e.component?recursiveGetSubtree(e.component):e},BaseTransitionImpl={name:"BaseTransition",props:BaseTransitionPropsValidators,setup(t,{slots:e}){const l=getCurrentInstance$1(),n=useTransitionState();return()=>{const u=e.default&&getTransitionRawChildren(e.default(),!0);if(!u||!u.length)return;const c=findNonCommentChild(u),y=toRaw(t),{mode:b}=y;if(n.isLeaving)return emptyPlaceholder(c);const m=getInnerChild$1(c);if(!m)return emptyPlaceholder(c);let O=resolveTransitionHooks(m,y,n,l,G=>O=G);m.type!==Comment&&setTransitionHooks(m,O);const N=l.subTree,L=N&&getInnerChild$1(N);if(L&&L.type!==Comment&&!isSameVNodeType(m,L)&&recursiveGetSubtree(l).type!==Comment){const G=resolveTransitionHooks(L,y,n,l);if(setTransitionHooks(L,G),b==="out-in"&&m.type!==Comment)return n.isLeaving=!0,G.afterLeave=()=>{n.isLeaving=!1,l.job.flags&8||l.update(),delete G.afterLeave},emptyPlaceholder(c);b==="in-out"&&m.type!==Comment&&(G.delayLeave=(q,J,fe)=>{const ve=getLeavingNodesForType(n,L);ve[String(L.key)]=L,q[leaveCbKey]=()=>{J(),q[leaveCbKey]=void 0,delete O.delayedLeave},O.delayedLeave=fe})}return c}}};function findNonCommentChild(t){let e=t[0];if(t.length>1){for(const l of t)if(l.type!==Comment){e=l;break}}return e}const BaseTransition=BaseTransitionImpl;function getLeavingNodesForType(t,e){const{leavingVNodes:l}=t;let n=l.get(e.type);return n||(n=Object.create(null),l.set(e.type,n)),n}function resolveTransitionHooks(t,e,l,n,u){const{appear:c,mode:y,persisted:b=!1,onBeforeEnter:m,onEnter:O,onAfterEnter:N,onEnterCancelled:L,onBeforeLeave:G,onLeave:q,onAfterLeave:J,onLeaveCancelled:fe,onBeforeAppear:ve,onAppear:ne,onAfterAppear:Ue,onAppearCancelled:De}=e,Ve=String(t.key),rt=getLeavingNodesForType(l,t),Ae=(ie,ue)=>{ie&&callWithAsyncErrorHandling(ie,n,9,ue)},Te=(ie,ue)=>{const pt=ue[1];Ae(ie,ue),isArray$3(ie)?ie.every(mt=>mt.length<=1)&&pt():ie.length<=1&&pt()},Xe={mode:y,persisted:b,beforeEnter(ie){let ue=m;if(!l.isMounted)if(c)ue=ve||m;else return;ie[leaveCbKey]&&ie[leaveCbKey](!0);const pt=rt[Ve];pt&&isSameVNodeType(t,pt)&&pt.el[leaveCbKey]&&pt.el[leaveCbKey](),Ae(ue,[ie])},enter(ie){let ue=O,pt=N,mt=L;if(!l.isMounted)if(c)ue=ne||O,pt=Ue||N,mt=De||L;else return;let Tt=!1;const kt=ie[enterCbKey$1]=It=>{Tt||(Tt=!0,It?Ae(mt,[ie]):Ae(pt,[ie]),Xe.delayedLeave&&Xe.delayedLeave(),ie[enterCbKey$1]=void 0)};ue?Te(ue,[ie,kt]):kt()},leave(ie,ue){const pt=String(t.key);if(ie[enterCbKey$1]&&ie[enterCbKey$1](!0),l.isUnmounting)return ue();Ae(G,[ie]);let mt=!1;const Tt=ie[leaveCbKey]=kt=>{mt||(mt=!0,ue(),kt?Ae(fe,[ie]):Ae(J,[ie]),ie[leaveCbKey]=void 0,rt[pt]===t&&delete rt[pt])};rt[pt]=t,q?Te(q,[ie,Tt]):Tt()},clone(ie){const ue=resolveTransitionHooks(ie,e,l,n,u);return u&&u(ue),ue}};return Xe}function emptyPlaceholder(t){if(isKeepAlive(t))return t=cloneVNode(t),t.children=null,t}function getInnerChild$1(t){if(!isKeepAlive(t))return isTeleport(t.type)&&t.children?findNonCommentChild(t.children):t;const{shapeFlag:e,children:l}=t;if(l){if(e&16)return l[0];if(e&32&&isFunction$2(l.default))return l.default()}}function setTransitionHooks(t,e){t.shapeFlag&6&&t.component?(t.transition=e,setTransitionHooks(t.component.subTree,e)):t.shapeFlag&128?(t.ssContent.transition=e.clone(t.ssContent),t.ssFallback.transition=e.clone(t.ssFallback)):t.transition=e}function getTransitionRawChildren(t,e=!1,l){let n=[],u=0;for(let c=0;c<t.length;c++){let y=t[c];const b=l==null?y.key:String(l)+String(y.key!=null?y.key:c);y.type===Fragment?(y.patchFlag&128&&u++,n=n.concat(getTransitionRawChildren(y.children,e,b))):(e||y.type!==Comment)&&n.push(b!=null?cloneVNode(y,{key:b}):y)}if(u>1)for(let c=0;c<n.length;c++)n[c].patchFlag=-2;return n}/*! #__NO_SIDE_EFFECTS__ */function defineComponent$1(t,e){return isFunction$2(t)?extend$1({name:t.name},e,{setup:t}):t}function useId(){const t=getCurrentInstance$1();if(t)return(t.appContext.config.idPrefix||"v")+"-"+t.ids[0]+t.ids[1]++}function markAsyncBoundary(t){t.ids=[t.ids[0]+t.ids[2]+++"-",0,0]}function useTemplateRef(t){const e=getCurrentInstance$1(),l=shallowRef(null);if(e){const u=e.refs===EMPTY_OBJ?e.refs={}:e.refs;Object.defineProperty(u,t,{enumerable:!0,get:()=>l.value,set:c=>l.value=c})}return l}function setRef(t,e,l,n,u=!1){if(isArray$3(t)){t.forEach((J,fe)=>setRef(J,e&&(isArray$3(e)?e[fe]:e),l,n,u));return}if(isAsyncWrapper(n)&&!u)return;const c=n.shapeFlag&4?getComponentPublicInstance(n.component):n.el,y=u?null:c,{i:b,r:m}=t,O=e&&e.r,N=b.refs===EMPTY_OBJ?b.refs={}:b.refs,L=b.setupState,G=toRaw(L),q=L===EMPTY_OBJ?()=>!1:J=>hasOwn(G,J);if(O!=null&&O!==m&&(isString$2(O)?(N[O]=null,q(O)&&(L[O]=null)):isRef(O)&&(O.value=null)),isFunction$2(m))callWithErrorHandling(m,b,12,[y,N]);else{const J=isString$2(m),fe=isRef(m);if(J||fe){const ve=()=>{if(t.f){const ne=J?q(m)?L[m]:N[m]:m.value;u?isArray$3(ne)&&remove(ne,c):isArray$3(ne)?ne.includes(c)||ne.push(c):J?(N[m]=[c],q(m)&&(L[m]=N[m])):(m.value=[c],t.k&&(N[t.k]=m.value))}else J?(N[m]=y,q(m)&&(L[m]=y)):fe&&(m.value=y,t.k&&(N[t.k]=y))};y?(ve.id=-1,queuePostRenderEffect(ve,l)):ve()}}}let hasLoggedMismatchError=!1;const logMismatchError=()=>{hasLoggedMismatchError||(console.error("Hydration completed but contains mismatches."),hasLoggedMismatchError=!0)},isSVGContainer=t=>t.namespaceURI.includes("svg")&&t.tagName!=="foreignObject",isMathMLContainer=t=>t.namespaceURI.includes("MathML"),getContainerType=t=>{if(t.nodeType===1){if(isSVGContainer(t))return"svg";if(isMathMLContainer(t))return"mathml"}},isComment=t=>t.nodeType===8;function createHydrationFunctions(t){const{mt:e,p:l,o:{patchProp:n,createText:u,nextSibling:c,parentNode:y,remove:b,insert:m,createComment:O}}=t,N=(De,Ve)=>{if(!Ve.hasChildNodes()){l(null,De,Ve),flushPostFlushCbs(),Ve._vnode=De;return}L(Ve.firstChild,De,null,null,null),flushPostFlushCbs(),Ve._vnode=De},L=(De,Ve,rt,Ae,Te,Xe=!1)=>{Xe=Xe||!!Ve.dynamicChildren;const ie=isComment(De)&&De.data==="[",ue=()=>fe(De,Ve,rt,Ae,Te,ie),{type:pt,ref:mt,shapeFlag:Tt,patchFlag:kt}=Ve;let It=De.nodeType;Ve.el=De,kt===-2&&(Xe=!1,Ve.dynamicChildren=null);let nn=null;switch(pt){case Text:It!==3?Ve.children===""?(m(Ve.el=u(""),y(De),De),nn=De):nn=ue():(De.data!==Ve.children&&(logMismatchError(),De.data=Ve.children),nn=c(De));break;case Comment:Ue(De)?(nn=c(De),ne(Ve.el=De.content.firstChild,De,rt)):It!==8||ie?nn=ue():nn=c(De);break;case Static:if(ie&&(De=c(De),It=De.nodeType),It===1||It===3){nn=De;const tn=!Ve.children.length;for(let pn=0;pn<Ve.staticCount;pn++)tn&&(Ve.children+=nn.nodeType===1?nn.outerHTML:nn.data),pn===Ve.staticCount-1&&(Ve.anchor=nn),nn=c(nn);return ie?c(nn):nn}else ue();break;case Fragment:ie?nn=J(De,Ve,rt,Ae,Te,Xe):nn=ue();break;default:if(Tt&1)(It!==1||Ve.type.toLowerCase()!==De.tagName.toLowerCase())&&!Ue(De)?nn=ue():nn=G(De,Ve,rt,Ae,Te,Xe);else if(Tt&6){Ve.slotScopeIds=Te;const tn=y(De);if(ie?nn=ve(De):isComment(De)&&De.data==="teleport start"?nn=ve(De,De.data,"teleport end"):nn=c(De),e(Ve,tn,null,rt,Ae,getContainerType(tn),Xe),isAsyncWrapper(Ve)){let pn;ie?(pn=createVNode(Fragment),pn.anchor=nn?nn.previousSibling:tn.lastChild):pn=De.nodeType===3?createTextVNode(""):createVNode("div"),pn.el=De,Ve.component.subTree=pn}}else Tt&64?It!==8?nn=ue():nn=Ve.type.hydrate(De,Ve,rt,Ae,Te,Xe,t,q):Tt&128&&(nn=Ve.type.hydrate(De,Ve,rt,Ae,getContainerType(y(De)),Te,Xe,t,L))}return mt!=null&&setRef(mt,null,Ae,Ve),nn},G=(De,Ve,rt,Ae,Te,Xe)=>{Xe=Xe||!!Ve.dynamicChildren;const{type:ie,props:ue,patchFlag:pt,shapeFlag:mt,dirs:Tt,transition:kt}=Ve,It=ie==="input"||ie==="option";if(It||pt!==-1){Tt&&invokeDirectiveHook(Ve,null,rt,"created");let nn=!1;if(Ue(De)){nn=needTransition(Ae,kt)&&rt&&rt.vnode.props&&rt.vnode.props.appear;const pn=De.content.firstChild;nn&&kt.beforeEnter(pn),ne(pn,De,rt),Ve.el=De=pn}if(mt&16&&!(ue&&(ue.innerHTML||ue.textContent))){let pn=q(De.firstChild,Ve,De,rt,Ae,Te,Xe);for(;pn;){isMismatchAllowed(De,1)||logMismatchError();const _n=pn;pn=pn.nextSibling,b(_n)}}else if(mt&8){let pn=Ve.children;pn[0]===`
- `&&(De.tagName==="PRE"||De.tagName==="TEXTAREA")&&(pn=pn.slice(1)),De.textContent!==pn&&(isMismatchAllowed(De,0)||logMismatchError(),De.textContent=Ve.children)}if(ue){if(It||!Xe||pt&48){const pn=De.tagName.includes("-");for(const _n in ue)(It&&(_n.endsWith("value")||_n==="indeterminate")||isOn$1(_n)&&!isReservedProp(_n)||_n[0]==="."||pn)&&n(De,_n,null,ue[_n],void 0,rt)}else if(ue.onClick)n(De,"onClick",null,ue.onClick,void 0,rt);else if(pt&4&&isReactive(ue.style))for(const pn in ue.style)ue.style[pn]}let tn;(tn=ue&&ue.onVnodeBeforeMount)&&invokeVNodeHook(tn,rt,Ve),Tt&&invokeDirectiveHook(Ve,null,rt,"beforeMount"),((tn=ue&&ue.onVnodeMounted)||Tt||nn)&&queueEffectWithSuspense(()=>{tn&&invokeVNodeHook(tn,rt,Ve),nn&&kt.enter(De),Tt&&invokeDirectiveHook(Ve,null,rt,"mounted")},Ae)}return De.nextSibling},q=(De,Ve,rt,Ae,Te,Xe,ie)=>{ie=ie||!!Ve.dynamicChildren;const ue=Ve.children,pt=ue.length;for(let mt=0;mt<pt;mt++){const Tt=ie?ue[mt]:ue[mt]=normalizeVNode(ue[mt]),kt=Tt.type===Text;De?(kt&&!ie&&mt+1<pt&&normalizeVNode(ue[mt+1]).type===Text&&(m(u(De.data.slice(Tt.children.length)),rt,c(De)),De.data=Tt.children),De=L(De,Tt,Ae,Te,Xe,ie)):kt&&!Tt.children?m(Tt.el=u(""),rt):(isMismatchAllowed(rt,1)||logMismatchError(),l(null,Tt,rt,null,Ae,Te,getContainerType(rt),Xe))}return De},J=(De,Ve,rt,Ae,Te,Xe)=>{const{slotScopeIds:ie}=Ve;ie&&(Te=Te?Te.concat(ie):ie);const ue=y(De),pt=q(c(De),Ve,ue,rt,Ae,Te,Xe);return pt&&isComment(pt)&&pt.data==="]"?c(Ve.anchor=pt):(logMismatchError(),m(Ve.anchor=O("]"),ue,pt),pt)},fe=(De,Ve,rt,Ae,Te,Xe)=>{if(isMismatchAllowed(De.parentElement,1)||logMismatchError(),Ve.el=null,Xe){const pt=ve(De);for(;;){const mt=c(De);if(mt&&mt!==pt)b(mt);else break}}const ie=c(De),ue=y(De);return b(De),l(null,Ve,ue,ie,rt,Ae,getContainerType(ue),Te),ie},ve=(De,Ve="[",rt="]")=>{let Ae=0;for(;De;)if(De=c(De),De&&isComment(De)&&(De.data===Ve&&Ae++,De.data===rt)){if(Ae===0)return c(De);Ae--}return De},ne=(De,Ve,rt)=>{const Ae=Ve.parentNode;Ae&&Ae.replaceChild(De,Ve);let Te=rt;for(;Te;)Te.vnode.el===Ve&&(Te.vnode.el=Te.subTree.el=De),Te=Te.parent},Ue=De=>De.nodeType===1&&De.tagName==="TEMPLATE";return[N,L]}const allowMismatchAttr="data-allow-mismatch",MismatchTypeString={0:"text",1:"children",2:"class",3:"style",4:"attribute"};function isMismatchAllowed(t,e){if(e===0||e===1)for(;t&&!t.hasAttribute(allowMismatchAttr);)t=t.parentElement;const l=t&&t.getAttribute(allowMismatchAttr);if(l==null)return!1;if(l==="")return!0;{const n=l.split(",");return e===0&&n.includes("children")?!0:l.split(",").includes(MismatchTypeString[e])}}const hydrateOnIdle=(t=1e4)=>e=>{const l=requestIdleCallback(e,{timeout:t});return()=>cancelIdleCallback(l)},hydrateOnVisible=t=>(e,l)=>{const n=new IntersectionObserver(u=>{for(const c of u)if(c.isIntersecting){n.disconnect(),e();break}},t);return l(u=>n.observe(u)),()=>n.disconnect()},hydrateOnMediaQuery=t=>e=>{if(t){const l=matchMedia(t);if(l.matches)e();else return l.addEventListener("change",e,{once:!0}),()=>l.removeEventListener("change",e)}},hydrateOnInteraction=(t=[])=>(e,l)=>{isString$2(t)&&(t=[t]);let n=!1;const u=y=>{n||(n=!0,c(),e(),y.target.dispatchEvent(new y.constructor(y.type,y)))},c=()=>{l(y=>{for(const b of t)y.removeEventListener(b,u)})};return l(y=>{for(const b of t)y.addEventListener(b,u,{once:!0})}),c};function forEachElement(t,e){if(isComment(t)&&t.data==="["){let l=1,n=t.nextSibling;for(;n;){if(n.nodeType===1)e(n);else if(isComment(n))if(n.data==="]"){if(--l===0)break}else n.data==="["&&l++;n=n.nextSibling}}else e(t)}const isAsyncWrapper=t=>!!t.type.__asyncLoader;/*! #__NO_SIDE_EFFECTS__ */function defineAsyncComponent(t){isFunction$2(t)&&(t={loader:t});const{loader:e,loadingComponent:l,errorComponent:n,delay:u=200,hydrate:c,timeout:y,suspensible:b=!0,onError:m}=t;let O=null,N,L=0;const G=()=>(L++,O=null,q()),q=()=>{let J;return O||(J=O=e().catch(fe=>{if(fe=fe instanceof Error?fe:new Error(String(fe)),m)return new Promise((ve,ne)=>{m(fe,()=>ve(G()),()=>ne(fe),L+1)});throw fe}).then(fe=>J!==O&&O?O:(fe&&(fe.__esModule||fe[Symbol.toStringTag]==="Module")&&(fe=fe.default),N=fe,fe)))};return defineComponent$1({name:"AsyncComponentWrapper",__asyncLoader:q,__asyncHydrate(J,fe,ve){const ne=c?()=>{const Ue=c(ve,De=>forEachElement(J,De));Ue&&(fe.bum||(fe.bum=[])).push(Ue)}:ve;N?ne():q().then(()=>!fe.isUnmounted&&ne())},get __asyncResolved(){return N},setup(){const J=currentInstance;if(markAsyncBoundary(J),N)return()=>createInnerComp(N,J);const fe=De=>{O=null,handleError(De,J,13,!n)};if(b&&J.suspense||isInSSRComponentSetup)return q().then(De=>()=>createInnerComp(De,J)).catch(De=>(fe(De),()=>n?createVNode(n,{error:De}):null));const ve=ref(!1),ne=ref(),Ue=ref(!!u);return u&&setTimeout(()=>{Ue.value=!1},u),y!=null&&setTimeout(()=>{if(!ve.value&&!ne.value){const De=new Error(`Async component timed out after ${y}ms.`);fe(De),ne.value=De}},y),q().then(()=>{ve.value=!0,J.parent&&isKeepAlive(J.parent.vnode)&&J.parent.update()}).catch(De=>{fe(De),ne.value=De}),()=>{if(ve.value&&N)return createInnerComp(N,J);if(ne.value&&n)return createVNode(n,{error:ne.value});if(l&&!Ue.value)return createVNode(l)}}})}function createInnerComp(t,e){const{ref:l,props:n,children:u,ce:c}=e.vnode,y=createVNode(t,n,u);return y.ref=l,y.ce=c,delete e.vnode.ce,y}const isKeepAlive=t=>t.type.__isKeepAlive,KeepAliveImpl={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(t,{slots:e}){const l=getCurrentInstance$1(),n=l.ctx;if(!n.renderer)return()=>{const Ue=e.default&&e.default();return Ue&&Ue.length===1?Ue[0]:Ue};const u=new Map,c=new Set;let y=null;const b=l.suspense,{renderer:{p:m,m:O,um:N,o:{createElement:L}}}=n,G=L("div");n.activate=(Ue,De,Ve,rt,Ae)=>{const Te=Ue.component;O(Ue,De,Ve,0,b),m(Te.vnode,Ue,De,Ve,Te,b,rt,Ue.slotScopeIds,Ae),queuePostRenderEffect(()=>{Te.isDeactivated=!1,Te.a&&invokeArrayFns(Te.a);const Xe=Ue.props&&Ue.props.onVnodeMounted;Xe&&invokeVNodeHook(Xe,Te.parent,Ue)},b)},n.deactivate=Ue=>{const De=Ue.component;invalidateMount(De.m),invalidateMount(De.a),O(Ue,G,null,1,b),queuePostRenderEffect(()=>{De.da&&invokeArrayFns(De.da);const Ve=Ue.props&&Ue.props.onVnodeUnmounted;Ve&&invokeVNodeHook(Ve,De.parent,Ue),De.isDeactivated=!0},b)};function q(Ue){resetShapeFlag(Ue),N(Ue,l,b,!0)}function J(Ue){u.forEach((De,Ve)=>{const rt=getComponentName(De.type);rt&&!Ue(rt)&&fe(Ve)})}function fe(Ue){const De=u.get(Ue);De&&(!y||!isSameVNodeType(De,y))?q(De):y&&resetShapeFlag(y),u.delete(Ue),c.delete(Ue)}watch(()=>[t.include,t.exclude],([Ue,De])=>{Ue&&J(Ve=>matches(Ue,Ve)),De&&J(Ve=>!matches(De,Ve))},{flush:"post",deep:!0});let ve=null;const ne=()=>{ve!=null&&(isSuspense(l.subTree.type)?queuePostRenderEffect(()=>{u.set(ve,getInnerChild(l.subTree))},l.subTree.suspense):u.set(ve,getInnerChild(l.subTree)))};return onMounted(ne),onUpdated(ne),onBeforeUnmount(()=>{u.forEach(Ue=>{const{subTree:De,suspense:Ve}=l,rt=getInnerChild(De);if(Ue.type===rt.type&&Ue.key===rt.key){resetShapeFlag(rt);const Ae=rt.component.da;Ae&&queuePostRenderEffect(Ae,Ve);return}q(Ue)})}),()=>{if(ve=null,!e.default)return y=null;const Ue=e.default(),De=Ue[0];if(Ue.length>1)return y=null,Ue;if(!isVNode(De)||!(De.shapeFlag&4)&&!(De.shapeFlag&128))return y=null,De;let Ve=getInnerChild(De);if(Ve.type===Comment)return y=null,Ve;const rt=Ve.type,Ae=getComponentName(isAsyncWrapper(Ve)?Ve.type.__asyncResolved||{}:rt),{include:Te,exclude:Xe,max:ie}=t;if(Te&&(!Ae||!matches(Te,Ae))||Xe&&Ae&&matches(Xe,Ae))return Ve.shapeFlag&=-257,y=Ve,De;const ue=Ve.key==null?rt:Ve.key,pt=u.get(ue);return Ve.el&&(Ve=cloneVNode(Ve),De.shapeFlag&128&&(De.ssContent=Ve)),ve=ue,pt?(Ve.el=pt.el,Ve.component=pt.component,Ve.transition&&setTransitionHooks(Ve,Ve.transition),Ve.shapeFlag|=512,c.delete(ue),c.add(ue)):(c.add(ue),ie&&c.size>parseInt(ie,10)&&fe(c.values().next().value)),Ve.shapeFlag|=256,y=Ve,isSuspense(De.type)?De:Ve}}},KeepAlive=KeepAliveImpl;function matches(t,e){return isArray$3(t)?t.some(l=>matches(l,e)):isString$2(t)?t.split(",").includes(e):isRegExp$1(t)?(t.lastIndex=0,t.test(e)):!1}function onActivated(t,e){registerKeepAliveHook(t,"a",e)}function onDeactivated(t,e){registerKeepAliveHook(t,"da",e)}function registerKeepAliveHook(t,e,l=currentInstance){const n=t.__wdc||(t.__wdc=()=>{let u=l;for(;u;){if(u.isDeactivated)return;u=u.parent}return t()});if(injectHook(e,n,l),l){let u=l.parent;for(;u&&u.parent;)isKeepAlive(u.parent.vnode)&&injectToKeepAliveRoot(n,e,l,u),u=u.parent}}function injectToKeepAliveRoot(t,e,l,n){const u=injectHook(e,t,n,!0);onUnmounted(()=>{remove(n[e],u)},l)}function resetShapeFlag(t){t.shapeFlag&=-257,t.shapeFlag&=-513}function getInnerChild(t){return t.shapeFlag&128?t.ssContent:t}function injectHook(t,e,l=currentInstance,n=!1){if(l){const u=l[t]||(l[t]=[]),c=e.__weh||(e.__weh=(...y)=>{pauseTracking();const b=setCurrentInstance(l),m=callWithAsyncErrorHandling(e,l,t,y);return b(),resetTracking(),m});return n?u.unshift(c):u.push(c),c}}const createHook=t=>(e,l=currentInstance)=>{(!isInSSRComponentSetup||t==="sp")&&injectHook(t,(...n)=>e(...n),l)},onBeforeMount=createHook("bm"),onMounted=createHook("m"),onBeforeUpdate=createHook("bu"),onUpdated=createHook("u"),onBeforeUnmount=createHook("bum"),onUnmounted=createHook("um"),onServerPrefetch=createHook("sp"),onRenderTriggered=createHook("rtg"),onRenderTracked=createHook("rtc");function onErrorCaptured(t,e=currentInstance){injectHook("ec",t,e)}const COMPONENTS="components",DIRECTIVES="directives";function resolveComponent(t,e){return resolveAsset(COMPONENTS,t,!0,e)||t}const NULL_DYNAMIC_COMPONENT=Symbol.for("v-ndc");function resolveDynamicComponent(t){return isString$2(t)?resolveAsset(COMPONENTS,t,!1)||t:t||NULL_DYNAMIC_COMPONENT}function resolveDirective(t){return resolveAsset(DIRECTIVES,t)}function resolveAsset(t,e,l=!0,n=!1){const u=currentRenderingInstance||currentInstance;if(u){const c=u.type;if(t===COMPONENTS){const b=getComponentName(c,!1);if(b&&(b===e||b===camelize(e)||b===capitalize(camelize(e))))return c}const y=resolve(u[t]||c[t],e)||resolve(u.appContext[t],e);return!y&&n?c:y}}function resolve(t,e){return t&&(t[e]||t[camelize(e)]||t[capitalize(camelize(e))])}function renderList(t,e,l,n){let u;const c=l&&l[n],y=isArray$3(t);if(y||isString$2(t)){const b=y&&isReactive(t);let m=!1;b&&(m=!isShallow(t),t=shallowReadArray(t)),u=new Array(t.length);for(let O=0,N=t.length;O<N;O++)u[O]=e(m?toReactive(t[O]):t[O],O,void 0,c&&c[O])}else if(typeof t=="number"){u=new Array(t);for(let b=0;b<t;b++)u[b]=e(b+1,b,void 0,c&&c[b])}else if(isObject$2(t))if(t[Symbol.iterator])u=Array.from(t,(b,m)=>e(b,m,void 0,c&&c[m]));else{const b=Object.keys(t);u=new Array(b.length);for(let m=0,O=b.length;m<O;m++){const N=b[m];u[m]=e(t[N],N,m,c&&c[m])}}else u=[];return l&&(l[n]=u),u}function createSlots(t,e){for(let l=0;l<e.length;l++){const n=e[l];if(isArray$3(n))for(let u=0;u<n.length;u++)t[n[u].name]=n[u].fn;else n&&(t[n.name]=n.key?(...u)=>{const c=n.fn(...u);return c&&(c.key=n.key),c}:n.fn)}return t}function renderSlot(t,e,l={},n,u){if(currentRenderingInstance.ce||currentRenderingInstance.parent&&isAsyncWrapper(currentRenderingInstance.parent)&¤tRenderingInstance.parent.ce)return e!=="default"&&(l.name=e),openBlock(),createBlock(Fragment,null,[createVNode("slot",l,n&&n())],64);let c=t[e];c&&c._c&&(c._d=!1),openBlock();const y=c&&ensureValidVNode$1(c(l)),b=createBlock(Fragment,{key:(l.key||y&&y.key||`_${e}`)+(!y&&n?"_fb":"")},y||(n?n():[]),y&&t._===1?64:-2);return!u&&b.scopeId&&(b.slotScopeIds=[b.scopeId+"-s"]),c&&c._c&&(c._d=!0),b}function ensureValidVNode$1(t){return t.some(e=>isVNode(e)?!(e.type===Comment||e.type===Fragment&&!ensureValidVNode$1(e.children)):!0)?t:null}function toHandlers(t,e){const l={};for(const n in t)l[e&&/[A-Z]/.test(n)?`on:${n}`:toHandlerKey(n)]=t[n];return l}const getPublicInstance=t=>t?isStatefulComponent(t)?getComponentPublicInstance(t):getPublicInstance(t.parent):null,publicPropertiesMap=extend$1(Object.create(null),{$:t=>t,$el:t=>t.vnode.el,$data:t=>t.data,$props:t=>t.props,$attrs:t=>t.attrs,$slots:t=>t.slots,$refs:t=>t.refs,$parent:t=>getPublicInstance(t.parent),$root:t=>getPublicInstance(t.root),$host:t=>t.ce,$emit:t=>t.emit,$options:t=>resolveMergedOptions(t),$forceUpdate:t=>t.f||(t.f=()=>{queueJob(t.update)}),$nextTick:t=>t.n||(t.n=nextTick.bind(t.proxy)),$watch:t=>instanceWatch.bind(t)}),hasSetupBinding=(t,e)=>t!==EMPTY_OBJ&&!t.__isScriptSetup&&hasOwn(t,e),PublicInstanceProxyHandlers={get({_:t},e){if(e==="__v_skip")return!0;const{ctx:l,setupState:n,data:u,props:c,accessCache:y,type:b,appContext:m}=t;let O;if(e[0]!=="$"){const q=y[e];if(q!==void 0)switch(q){case 1:return n[e];case 2:return u[e];case 4:return l[e];case 3:return c[e]}else{if(hasSetupBinding(n,e))return y[e]=1,n[e];if(u!==EMPTY_OBJ&&hasOwn(u,e))return y[e]=2,u[e];if((O=t.propsOptions[0])&&hasOwn(O,e))return y[e]=3,c[e];if(l!==EMPTY_OBJ&&hasOwn(l,e))return y[e]=4,l[e];shouldCacheAccess&&(y[e]=0)}}const N=publicPropertiesMap[e];let L,G;if(N)return e==="$attrs"&&track(t.attrs,"get",""),N(t);if((L=b.__cssModules)&&(L=L[e]))return L;if(l!==EMPTY_OBJ&&hasOwn(l,e))return y[e]=4,l[e];if(G=m.config.globalProperties,hasOwn(G,e))return G[e]},set({_:t},e,l){const{data:n,setupState:u,ctx:c}=t;return hasSetupBinding(u,e)?(u[e]=l,!0):n!==EMPTY_OBJ&&hasOwn(n,e)?(n[e]=l,!0):hasOwn(t.props,e)||e[0]==="$"&&e.slice(1)in t?!1:(c[e]=l,!0)},has({_:{data:t,setupState:e,accessCache:l,ctx:n,appContext:u,propsOptions:c}},y){let b;return!!l[y]||t!==EMPTY_OBJ&&hasOwn(t,y)||hasSetupBinding(e,y)||(b=c[0])&&hasOwn(b,y)||hasOwn(n,y)||hasOwn(publicPropertiesMap,y)||hasOwn(u.config.globalProperties,y)},defineProperty(t,e,l){return l.get!=null?t._.accessCache[e]=0:hasOwn(l,"value")&&this.set(t,e,l.value,null),Reflect.defineProperty(t,e,l)}},RuntimeCompiledPublicInstanceProxyHandlers=extend$1({},PublicInstanceProxyHandlers,{get(t,e){if(e!==Symbol.unscopables)return PublicInstanceProxyHandlers.get(t,e,t)},has(t,e){return e[0]!=="_"&&!isGloballyAllowed(e)}});function defineProps(){return null}function defineEmits(){return null}function defineExpose(t){}function defineOptions(t){}function defineSlots(){return null}function defineModel(){}function withDefaults(t,e){return null}function useSlots(){return getContext().slots}function useAttrs(){return getContext().attrs}function getContext(){const t=getCurrentInstance$1();return t.setupContext||(t.setupContext=createSetupContext(t))}function normalizePropsOrEmits(t){return isArray$3(t)?t.reduce((e,l)=>(e[l]=null,e),{}):t}function mergeDefaults(t,e){const l=normalizePropsOrEmits(t);for(const n in e){if(n.startsWith("__skip"))continue;let u=l[n];u?isArray$3(u)||isFunction$2(u)?u=l[n]={type:u,default:e[n]}:u.default=e[n]:u===null&&(u=l[n]={default:e[n]}),u&&e[`__skip_${n}`]&&(u.skipFactory=!0)}return l}function mergeModels(t,e){return!t||!e?t||e:isArray$3(t)&&isArray$3(e)?t.concat(e):extend$1({},normalizePropsOrEmits(t),normalizePropsOrEmits(e))}function createPropsRestProxy(t,e){const l={};for(const n in t)e.includes(n)||Object.defineProperty(l,n,{enumerable:!0,get:()=>t[n]});return l}function withAsyncContext(t){const e=getCurrentInstance$1();let l=t();return unsetCurrentInstance(),isPromise$2(l)&&(l=l.catch(n=>{throw setCurrentInstance(e),n})),[l,()=>setCurrentInstance(e)]}let shouldCacheAccess=!0;function applyOptions(t){const e=resolveMergedOptions(t),l=t.proxy,n=t.ctx;shouldCacheAccess=!1,e.beforeCreate&&callHook$1(e.beforeCreate,t,"bc");const{data:u,computed:c,methods:y,watch:b,provide:m,inject:O,created:N,beforeMount:L,mounted:G,beforeUpdate:q,updated:J,activated:fe,deactivated:ve,beforeDestroy:ne,beforeUnmount:Ue,destroyed:De,unmounted:Ve,render:rt,renderTracked:Ae,renderTriggered:Te,errorCaptured:Xe,serverPrefetch:ie,expose:ue,inheritAttrs:pt,components:mt,directives:Tt,filters:kt}=e;if(O&&resolveInjections(O,n,null),y)for(const tn in y){const pn=y[tn];isFunction$2(pn)&&(n[tn]=pn.bind(l))}if(u){const tn=u.call(l,l);isObject$2(tn)&&(t.data=reactive(tn))}if(shouldCacheAccess=!0,c)for(const tn in c){const pn=c[tn],_n=isFunction$2(pn)?pn.bind(l,l):isFunction$2(pn.get)?pn.get.bind(l,l):NOOP,Dn=!isFunction$2(pn)&&isFunction$2(pn.set)?pn.set.bind(l):NOOP,an=computed({get:_n,set:Dn});Object.defineProperty(n,tn,{enumerable:!0,configurable:!0,get:()=>an.value,set:Rn=>an.value=Rn})}if(b)for(const tn in b)createWatcher(b[tn],n,l,tn);if(m){const tn=isFunction$2(m)?m.call(l):m;Reflect.ownKeys(tn).forEach(pn=>{provide(pn,tn[pn])})}N&&callHook$1(N,t,"c");function nn(tn,pn){isArray$3(pn)?pn.forEach(_n=>tn(_n.bind(l))):pn&&tn(pn.bind(l))}if(nn(onBeforeMount,L),nn(onMounted,G),nn(onBeforeUpdate,q),nn(onUpdated,J),nn(onActivated,fe),nn(onDeactivated,ve),nn(onErrorCaptured,Xe),nn(onRenderTracked,Ae),nn(onRenderTriggered,Te),nn(onBeforeUnmount,Ue),nn(onUnmounted,Ve),nn(onServerPrefetch,ie),isArray$3(ue))if(ue.length){const tn=t.exposed||(t.exposed={});ue.forEach(pn=>{Object.defineProperty(tn,pn,{get:()=>l[pn],set:_n=>l[pn]=_n})})}else t.exposed||(t.exposed={});rt&&t.render===NOOP&&(t.render=rt),pt!=null&&(t.inheritAttrs=pt),mt&&(t.components=mt),Tt&&(t.directives=Tt),ie&&markAsyncBoundary(t)}function resolveInjections(t,e,l=NOOP){isArray$3(t)&&(t=normalizeInject(t));for(const n in t){const u=t[n];let c;isObject$2(u)?"default"in u?c=inject$1(u.from||n,u.default,!0):c=inject$1(u.from||n):c=inject$1(u),isRef(c)?Object.defineProperty(e,n,{enumerable:!0,configurable:!0,get:()=>c.value,set:y=>c.value=y}):e[n]=c}}function callHook$1(t,e,l){callWithAsyncErrorHandling(isArray$3(t)?t.map(n=>n.bind(e.proxy)):t.bind(e.proxy),e,l)}function createWatcher(t,e,l,n){let u=n.includes(".")?createPathGetter(l,n):()=>l[n];if(isString$2(t)){const c=e[t];isFunction$2(c)&&watch(u,c)}else if(isFunction$2(t))watch(u,t.bind(l));else if(isObject$2(t))if(isArray$3(t))t.forEach(c=>createWatcher(c,e,l,n));else{const c=isFunction$2(t.handler)?t.handler.bind(l):e[t.handler];isFunction$2(c)&&watch(u,c,t)}}function resolveMergedOptions(t){const e=t.type,{mixins:l,extends:n}=e,{mixins:u,optionsCache:c,config:{optionMergeStrategies:y}}=t.appContext,b=c.get(e);let m;return b?m=b:!u.length&&!l&&!n?m=e:(m={},u.length&&u.forEach(O=>mergeOptions(m,O,y,!0)),mergeOptions(m,e,y)),isObject$2(e)&&c.set(e,m),m}function mergeOptions(t,e,l,n=!1){const{mixins:u,extends:c}=e;c&&mergeOptions(t,c,l,!0),u&&u.forEach(y=>mergeOptions(t,y,l,!0));for(const y in e)if(!(n&&y==="expose")){const b=internalOptionMergeStrats[y]||l&&l[y];t[y]=b?b(t[y],e[y]):e[y]}return t}const internalOptionMergeStrats={data:mergeDataFn,props:mergeEmitsOrPropsOptions,emits:mergeEmitsOrPropsOptions,methods:mergeObjectOptions,computed:mergeObjectOptions,beforeCreate:mergeAsArray,created:mergeAsArray,beforeMount:mergeAsArray,mounted:mergeAsArray,beforeUpdate:mergeAsArray,updated:mergeAsArray,beforeDestroy:mergeAsArray,beforeUnmount:mergeAsArray,destroyed:mergeAsArray,unmounted:mergeAsArray,activated:mergeAsArray,deactivated:mergeAsArray,errorCaptured:mergeAsArray,serverPrefetch:mergeAsArray,components:mergeObjectOptions,directives:mergeObjectOptions,watch:mergeWatchOptions,provide:mergeDataFn,inject:mergeInject};function mergeDataFn(t,e){return e?t?function(){return extend$1(isFunction$2(t)?t.call(this,this):t,isFunction$2(e)?e.call(this,this):e)}:e:t}function mergeInject(t,e){return mergeObjectOptions(normalizeInject(t),normalizeInject(e))}function normalizeInject(t){if(isArray$3(t)){const e={};for(let l=0;l<t.length;l++)e[t[l]]=t[l];return e}return t}function mergeAsArray(t,e){return t?[...new Set([].concat(t,e))]:e}function mergeObjectOptions(t,e){return t?extend$1(Object.create(null),t,e):e}function mergeEmitsOrPropsOptions(t,e){return t?isArray$3(t)&&isArray$3(e)?[...new Set([...t,...e])]:extend$1(Object.create(null),normalizePropsOrEmits(t),normalizePropsOrEmits(e??{})):e}function mergeWatchOptions(t,e){if(!t)return e;if(!e)return t;const l=extend$1(Object.create(null),t);for(const n in e)l[n]=mergeAsArray(t[n],e[n]);return l}function createAppContext(){return{app:null,config:{isNativeTag:NO,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let uid$1=0;function createAppAPI(t,e){return function(n,u=null){isFunction$2(n)||(n=extend$1({},n)),u!=null&&!isObject$2(u)&&(u=null);const c=createAppContext(),y=new WeakSet,b=[];let m=!1;const O=c.app={_uid:uid$1++,_component:n,_props:u,_container:null,_context:c,_instance:null,version:version$4,get config(){return c.config},set config(N){},use(N,...L){return y.has(N)||(N&&isFunction$2(N.install)?(y.add(N),N.install(O,...L)):isFunction$2(N)&&(y.add(N),N(O,...L))),O},mixin(N){return c.mixins.includes(N)||c.mixins.push(N),O},component(N,L){return L?(c.components[N]=L,O):c.components[N]},directive(N,L){return L?(c.directives[N]=L,O):c.directives[N]},mount(N,L,G){if(!m){const q=O._ceVNode||createVNode(n,u);return q.appContext=c,G===!0?G="svg":G===!1&&(G=void 0),L&&e?e(q,N):t(q,N,G),m=!0,O._container=N,N.__vue_app__=O,getComponentPublicInstance(q.component)}},onUnmount(N){b.push(N)},unmount(){m&&(callWithAsyncErrorHandling(b,O._instance,16),t(null,O._container),delete O._container.__vue_app__)},provide(N,L){return c.provides[N]=L,O},runWithContext(N){const L=currentApp;currentApp=O;try{return N()}finally{currentApp=L}}};return O}}let currentApp=null;function provide(t,e){if(currentInstance){let l=currentInstance.provides;const n=currentInstance.parent&¤tInstance.parent.provides;n===l&&(l=currentInstance.provides=Object.create(n)),l[t]=e}}function inject$1(t,e,l=!1){const n=currentInstance||currentRenderingInstance;if(n||currentApp){const u=currentApp?currentApp._context.provides:n?n.parent==null?n.vnode.appContext&&n.vnode.appContext.provides:n.parent.provides:void 0;if(u&&t in u)return u[t];if(arguments.length>1)return l&&isFunction$2(e)?e.call(n&&n.proxy):e}}function hasInjectionContext(){return!!(currentInstance||currentRenderingInstance||currentApp)}const internalObjectProto={},createInternalObject=()=>Object.create(internalObjectProto),isInternalObject=t=>Object.getPrototypeOf(t)===internalObjectProto;function initProps(t,e,l,n=!1){const u={},c=createInternalObject();t.propsDefaults=Object.create(null),setFullProps(t,e,u,c);for(const y in t.propsOptions[0])y in u||(u[y]=void 0);l?t.props=n?u:shallowReactive(u):t.type.props?t.props=u:t.props=c,t.attrs=c}function updateProps(t,e,l,n){const{props:u,attrs:c,vnode:{patchFlag:y}}=t,b=toRaw(u),[m]=t.propsOptions;let O=!1;if((n||y>0)&&!(y&16)){if(y&8){const N=t.vnode.dynamicProps;for(let L=0;L<N.length;L++){let G=N[L];if(isEmitListener(t.emitsOptions,G))continue;const q=e[G];if(m)if(hasOwn(c,G))q!==c[G]&&(c[G]=q,O=!0);else{const J=camelize(G);u[J]=resolvePropValue(m,b,J,q,t,!1)}else q!==c[G]&&(c[G]=q,O=!0)}}}else{setFullProps(t,e,u,c)&&(O=!0);let N;for(const L in b)(!e||!hasOwn(e,L)&&((N=hyphenate(L))===L||!hasOwn(e,N)))&&(m?l&&(l[L]!==void 0||l[N]!==void 0)&&(u[L]=resolvePropValue(m,b,L,void 0,t,!0)):delete u[L]);if(c!==b)for(const L in c)(!e||!hasOwn(e,L))&&(delete c[L],O=!0)}O&&trigger(t.attrs,"set","")}function setFullProps(t,e,l,n){const[u,c]=t.propsOptions;let y=!1,b;if(e)for(let m in e){if(isReservedProp(m))continue;const O=e[m];let N;u&&hasOwn(u,N=camelize(m))?!c||!c.includes(N)?l[N]=O:(b||(b={}))[N]=O:isEmitListener(t.emitsOptions,m)||(!(m in n)||O!==n[m])&&(n[m]=O,y=!0)}if(c){const m=toRaw(l),O=b||EMPTY_OBJ;for(let N=0;N<c.length;N++){const L=c[N];l[L]=resolvePropValue(u,m,L,O[L],t,!hasOwn(O,L))}}return y}function resolvePropValue(t,e,l,n,u,c){const y=t[l];if(y!=null){const b=hasOwn(y,"default");if(b&&n===void 0){const m=y.default;if(y.type!==Function&&!y.skipFactory&&isFunction$2(m)){const{propsDefaults:O}=u;if(l in O)n=O[l];else{const N=setCurrentInstance(u);n=O[l]=m.call(null,e),N()}}else n=m;u.ce&&u.ce._setProp(l,n)}y[0]&&(c&&!b?n=!1:y[1]&&(n===""||n===hyphenate(l))&&(n=!0))}return n}const mixinPropsCache=new WeakMap;function normalizePropsOptions(t,e,l=!1){const n=l?mixinPropsCache:e.propsCache,u=n.get(t);if(u)return u;const c=t.props,y={},b=[];let m=!1;if(!isFunction$2(t)){const N=L=>{m=!0;const[G,q]=normalizePropsOptions(L,e,!0);extend$1(y,G),q&&b.push(...q)};!l&&e.mixins.length&&e.mixins.forEach(N),t.extends&&N(t.extends),t.mixins&&t.mixins.forEach(N)}if(!c&&!m)return isObject$2(t)&&n.set(t,EMPTY_ARR),EMPTY_ARR;if(isArray$3(c))for(let N=0;N<c.length;N++){const L=camelize(c[N]);validatePropName(L)&&(y[L]=EMPTY_OBJ)}else if(c)for(const N in c){const L=camelize(N);if(validatePropName(L)){const G=c[N],q=y[L]=isArray$3(G)||isFunction$2(G)?{type:G}:extend$1({},G),J=q.type;let fe=!1,ve=!0;if(isArray$3(J))for(let ne=0;ne<J.length;++ne){const Ue=J[ne],De=isFunction$2(Ue)&&Ue.name;if(De==="Boolean"){fe=!0;break}else De==="String"&&(ve=!1)}else fe=isFunction$2(J)&&J.name==="Boolean";q[0]=fe,q[1]=ve,(fe||hasOwn(q,"default"))&&b.push(L)}}const O=[y,b];return isObject$2(t)&&n.set(t,O),O}function validatePropName(t){return t[0]!=="$"&&!isReservedProp(t)}const isInternalKey=t=>t[0]==="_"||t==="$stable",normalizeSlotValue=t=>isArray$3(t)?t.map(normalizeVNode):[normalizeVNode(t)],normalizeSlot=(t,e,l)=>{if(e._n)return e;const n=withCtx((...u)=>normalizeSlotValue(e(...u)),l);return n._c=!1,n},normalizeObjectSlots=(t,e,l)=>{const n=t._ctx;for(const u in t){if(isInternalKey(u))continue;const c=t[u];if(isFunction$2(c))e[u]=normalizeSlot(u,c,n);else if(c!=null){const y=normalizeSlotValue(c);e[u]=()=>y}}},normalizeVNodeSlots=(t,e)=>{const l=normalizeSlotValue(e);t.slots.default=()=>l},assignSlots=(t,e,l)=>{for(const n in e)(l||n!=="_")&&(t[n]=e[n])},initSlots=(t,e,l)=>{const n=t.slots=createInternalObject();if(t.vnode.shapeFlag&32){const u=e._;u?(assignSlots(n,e,l),l&&def(n,"_",u,!0)):normalizeObjectSlots(e,n)}else e&&normalizeVNodeSlots(t,e)},updateSlots=(t,e,l)=>{const{vnode:n,slots:u}=t;let c=!0,y=EMPTY_OBJ;if(n.shapeFlag&32){const b=e._;b?l&&b===1?c=!1:assignSlots(u,e,l):(c=!e.$stable,normalizeObjectSlots(e,u)),y=e}else e&&(normalizeVNodeSlots(t,e),y={default:1});if(c)for(const b in u)!isInternalKey(b)&&y[b]==null&&delete u[b]},queuePostRenderEffect=queueEffectWithSuspense;function createRenderer(t){return baseCreateRenderer(t)}function createHydrationRenderer(t){return baseCreateRenderer(t,createHydrationFunctions)}function baseCreateRenderer(t,e){const l=getGlobalThis();l.__VUE__=!0;const{insert:n,remove:u,patchProp:c,createElement:y,createText:b,createComment:m,setText:O,setElementText:N,parentNode:L,nextSibling:G,setScopeId:q=NOOP,insertStaticContent:J}=t,fe=(Vn,Yn,Vr,xi=null,Si=null,qn=null,ia=void 0,Wi=null,ha=!!Yn.dynamicChildren)=>{if(Vn===Yn)return;Vn&&!isSameVNodeType(Vn,Yn)&&(xi=$n(Vn),Rn(Vn,Si,qn,!0),Vn=null),Yn.patchFlag===-2&&(ha=!1,Yn.dynamicChildren=null);const{type:ai,ref:Ia,shapeFlag:fi}=Yn;switch(ai){case Text:ve(Vn,Yn,Vr,xi);break;case Comment:ne(Vn,Yn,Vr,xi);break;case Static:Vn==null&&Ue(Yn,Vr,xi,ia);break;case Fragment:mt(Vn,Yn,Vr,xi,Si,qn,ia,Wi,ha);break;default:fi&1?rt(Vn,Yn,Vr,xi,Si,qn,ia,Wi,ha):fi&6?Tt(Vn,Yn,Vr,xi,Si,qn,ia,Wi,ha):(fi&64||fi&128)&&ai.process(Vn,Yn,Vr,xi,Si,qn,ia,Wi,ha,gn)}Ia!=null&&Si&&setRef(Ia,Vn&&Vn.ref,qn,Yn||Vn,!Yn)},ve=(Vn,Yn,Vr,xi)=>{if(Vn==null)n(Yn.el=b(Yn.children),Vr,xi);else{const Si=Yn.el=Vn.el;Yn.children!==Vn.children&&O(Si,Yn.children)}},ne=(Vn,Yn,Vr,xi)=>{Vn==null?n(Yn.el=m(Yn.children||""),Vr,xi):Yn.el=Vn.el},Ue=(Vn,Yn,Vr,xi)=>{[Vn.el,Vn.anchor]=J(Vn.children,Yn,Vr,xi,Vn.el,Vn.anchor)},De=({el:Vn,anchor:Yn},Vr,xi)=>{let Si;for(;Vn&&Vn!==Yn;)Si=G(Vn),n(Vn,Vr,xi),Vn=Si;n(Yn,Vr,xi)},Ve=({el:Vn,anchor:Yn})=>{let Vr;for(;Vn&&Vn!==Yn;)Vr=G(Vn),u(Vn),Vn=Vr;u(Yn)},rt=(Vn,Yn,Vr,xi,Si,qn,ia,Wi,ha)=>{Yn.type==="svg"?ia="svg":Yn.type==="math"&&(ia="mathml"),Vn==null?Ae(Yn,Vr,xi,Si,qn,ia,Wi,ha):ie(Vn,Yn,Si,qn,ia,Wi,ha)},Ae=(Vn,Yn,Vr,xi,Si,qn,ia,Wi)=>{let ha,ai;const{props:Ia,shapeFlag:fi,transition:An,dirs:sa}=Vn;if(ha=Vn.el=y(Vn.type,qn,Ia&&Ia.is,Ia),fi&8?N(ha,Vn.children):fi&16&&Xe(Vn.children,ha,null,xi,Si,resolveChildrenNamespace(Vn,qn),ia,Wi),sa&&invokeDirectiveHook(Vn,null,xi,"created"),Te(ha,Vn,Vn.scopeId,ia,xi),Ia){for(const fn in Ia)fn!=="value"&&!isReservedProp(fn)&&c(ha,fn,null,Ia[fn],qn,xi);"value"in Ia&&c(ha,"value",null,Ia.value,qn),(ai=Ia.onVnodeBeforeMount)&&invokeVNodeHook(ai,xi,Vn)}sa&&invokeDirectiveHook(Vn,null,xi,"beforeMount");const Nn=needTransition(Si,An);Nn&&An.beforeEnter(ha),n(ha,Yn,Vr),((ai=Ia&&Ia.onVnodeMounted)||Nn||sa)&&queuePostRenderEffect(()=>{ai&&invokeVNodeHook(ai,xi,Vn),Nn&&An.enter(ha),sa&&invokeDirectiveHook(Vn,null,xi,"mounted")},Si)},Te=(Vn,Yn,Vr,xi,Si)=>{if(Vr&&q(Vn,Vr),xi)for(let qn=0;qn<xi.length;qn++)q(Vn,xi[qn]);if(Si){let qn=Si.subTree;if(Yn===qn||isSuspense(qn.type)&&(qn.ssContent===Yn||qn.ssFallback===Yn)){const ia=Si.vnode;Te(Vn,ia,ia.scopeId,ia.slotScopeIds,Si.parent)}}},Xe=(Vn,Yn,Vr,xi,Si,qn,ia,Wi,ha=0)=>{for(let ai=ha;ai<Vn.length;ai++){const Ia=Vn[ai]=Wi?cloneIfMounted(Vn[ai]):normalizeVNode(Vn[ai]);fe(null,Ia,Yn,Vr,xi,Si,qn,ia,Wi)}},ie=(Vn,Yn,Vr,xi,Si,qn,ia)=>{const Wi=Yn.el=Vn.el;let{patchFlag:ha,dynamicChildren:ai,dirs:Ia}=Yn;ha|=Vn.patchFlag&16;const fi=Vn.props||EMPTY_OBJ,An=Yn.props||EMPTY_OBJ;let sa;if(Vr&&toggleRecurse(Vr,!1),(sa=An.onVnodeBeforeUpdate)&&invokeVNodeHook(sa,Vr,Yn,Vn),Ia&&invokeDirectiveHook(Yn,Vn,Vr,"beforeUpdate"),Vr&&toggleRecurse(Vr,!0),(fi.innerHTML&&An.innerHTML==null||fi.textContent&&An.textContent==null)&&N(Wi,""),ai?ue(Vn.dynamicChildren,ai,Wi,Vr,xi,resolveChildrenNamespace(Yn,Si),qn):ia||pn(Vn,Yn,Wi,null,Vr,xi,resolveChildrenNamespace(Yn,Si),qn,!1),ha>0){if(ha&16)pt(Wi,fi,An,Vr,Si);else if(ha&2&&fi.class!==An.class&&c(Wi,"class",null,An.class,Si),ha&4&&c(Wi,"style",fi.style,An.style,Si),ha&8){const Nn=Yn.dynamicProps;for(let fn=0;fn<Nn.length;fn++){const un=Nn[fn],Ln=fi[un],hr=An[un];(hr!==Ln||un==="value")&&c(Wi,un,Ln,hr,Si,Vr)}}ha&1&&Vn.children!==Yn.children&&N(Wi,Yn.children)}else!ia&&ai==null&&pt(Wi,fi,An,Vr,Si);((sa=An.onVnodeUpdated)||Ia)&&queuePostRenderEffect(()=>{sa&&invokeVNodeHook(sa,Vr,Yn,Vn),Ia&&invokeDirectiveHook(Yn,Vn,Vr,"updated")},xi)},ue=(Vn,Yn,Vr,xi,Si,qn,ia)=>{for(let Wi=0;Wi<Yn.length;Wi++){const ha=Vn[Wi],ai=Yn[Wi],Ia=ha.el&&(ha.type===Fragment||!isSameVNodeType(ha,ai)||ha.shapeFlag&70)?L(ha.el):Vr;fe(ha,ai,Ia,null,xi,Si,qn,ia,!0)}},pt=(Vn,Yn,Vr,xi,Si)=>{if(Yn!==Vr){if(Yn!==EMPTY_OBJ)for(const qn in Yn)!isReservedProp(qn)&&!(qn in Vr)&&c(Vn,qn,Yn[qn],null,Si,xi);for(const qn in Vr){if(isReservedProp(qn))continue;const ia=Vr[qn],Wi=Yn[qn];ia!==Wi&&qn!=="value"&&c(Vn,qn,Wi,ia,Si,xi)}"value"in Vr&&c(Vn,"value",Yn.value,Vr.value,Si)}},mt=(Vn,Yn,Vr,xi,Si,qn,ia,Wi,ha)=>{const ai=Yn.el=Vn?Vn.el:b(""),Ia=Yn.anchor=Vn?Vn.anchor:b("");let{patchFlag:fi,dynamicChildren:An,slotScopeIds:sa}=Yn;sa&&(Wi=Wi?Wi.concat(sa):sa),Vn==null?(n(ai,Vr,xi),n(Ia,Vr,xi),Xe(Yn.children||[],Vr,Ia,Si,qn,ia,Wi,ha)):fi>0&&fi&64&&An&&Vn.dynamicChildren?(ue(Vn.dynamicChildren,An,Vr,Si,qn,ia,Wi),(Yn.key!=null||Si&&Yn===Si.subTree)&&traverseStaticChildren(Vn,Yn,!0)):pn(Vn,Yn,Vr,Ia,Si,qn,ia,Wi,ha)},Tt=(Vn,Yn,Vr,xi,Si,qn,ia,Wi,ha)=>{Yn.slotScopeIds=Wi,Vn==null?Yn.shapeFlag&512?Si.ctx.activate(Yn,Vr,xi,ia,ha):kt(Yn,Vr,xi,Si,qn,ia,ha):It(Vn,Yn,ha)},kt=(Vn,Yn,Vr,xi,Si,qn,ia)=>{const Wi=Vn.component=createComponentInstance(Vn,xi,Si);if(isKeepAlive(Vn)&&(Wi.ctx.renderer=gn),setupComponent(Wi,!1,ia),Wi.asyncDep){if(Si&&Si.registerDep(Wi,nn,ia),!Vn.el){const ha=Wi.subTree=createVNode(Comment);ne(null,ha,Yn,Vr)}}else nn(Wi,Vn,Yn,Vr,Si,qn,ia)},It=(Vn,Yn,Vr)=>{const xi=Yn.component=Vn.component;if(shouldUpdateComponent(Vn,Yn,Vr))if(xi.asyncDep&&!xi.asyncResolved){tn(xi,Yn,Vr);return}else xi.next=Yn,xi.update();else Yn.el=Vn.el,xi.vnode=Yn},nn=(Vn,Yn,Vr,xi,Si,qn,ia)=>{const Wi=()=>{if(Vn.isMounted){let{next:fi,bu:An,u:sa,parent:Nn,vnode:fn}=Vn;{const bi=locateNonHydratedAsyncRoot(Vn);if(bi){fi&&(fi.el=fn.el,tn(Vn,fi,ia)),bi.asyncDep.then(()=>{Vn.isUnmounted||Wi()});return}}let un=fi,Ln;toggleRecurse(Vn,!1),fi?(fi.el=fn.el,tn(Vn,fi,ia)):fi=fn,An&&invokeArrayFns(An),(Ln=fi.props&&fi.props.onVnodeBeforeUpdate)&&invokeVNodeHook(Ln,Nn,fi,fn),toggleRecurse(Vn,!0);const hr=renderComponentRoot(Vn),hi=Vn.subTree;Vn.subTree=hr,fe(hi,hr,L(hi.el),$n(hi),Vn,Si,qn),fi.el=hr.el,un===null&&updateHOCHostEl(Vn,hr.el),sa&&queuePostRenderEffect(sa,Si),(Ln=fi.props&&fi.props.onVnodeUpdated)&&queuePostRenderEffect(()=>invokeVNodeHook(Ln,Nn,fi,fn),Si)}else{let fi;const{el:An,props:sa}=Yn,{bm:Nn,m:fn,parent:un,root:Ln,type:hr}=Vn,hi=isAsyncWrapper(Yn);if(toggleRecurse(Vn,!1),Nn&&invokeArrayFns(Nn),!hi&&(fi=sa&&sa.onVnodeBeforeMount)&&invokeVNodeHook(fi,un,Yn),toggleRecurse(Vn,!0),An&&Kn){const bi=()=>{Vn.subTree=renderComponentRoot(Vn),Kn(An,Vn.subTree,Vn,Si,null)};hi&&hr.__asyncHydrate?hr.__asyncHydrate(An,Vn,bi):bi()}else{Ln.ce&&Ln.ce._injectChildStyle(hr);const bi=Vn.subTree=renderComponentRoot(Vn);fe(null,bi,Vr,xi,Vn,Si,qn),Yn.el=bi.el}if(fn&&queuePostRenderEffect(fn,Si),!hi&&(fi=sa&&sa.onVnodeMounted)){const bi=Yn;queuePostRenderEffect(()=>invokeVNodeHook(fi,un,bi),Si)}(Yn.shapeFlag&256||un&&isAsyncWrapper(un.vnode)&&un.vnode.shapeFlag&256)&&Vn.a&&queuePostRenderEffect(Vn.a,Si),Vn.isMounted=!0,Yn=Vr=xi=null}};Vn.scope.on();const ha=Vn.effect=new ReactiveEffect(Wi);Vn.scope.off();const ai=Vn.update=ha.run.bind(ha),Ia=Vn.job=ha.runIfDirty.bind(ha);Ia.i=Vn,Ia.id=Vn.uid,ha.scheduler=()=>queueJob(Ia),toggleRecurse(Vn,!0),ai()},tn=(Vn,Yn,Vr)=>{Yn.component=Vn;const xi=Vn.vnode.props;Vn.vnode=Yn,Vn.next=null,updateProps(Vn,Yn.props,xi,Vr),updateSlots(Vn,Yn.children,Vr),pauseTracking(),flushPreFlushCbs(Vn),resetTracking()},pn=(Vn,Yn,Vr,xi,Si,qn,ia,Wi,ha=!1)=>{const ai=Vn&&Vn.children,Ia=Vn?Vn.shapeFlag:0,fi=Yn.children,{patchFlag:An,shapeFlag:sa}=Yn;if(An>0){if(An&128){Dn(ai,fi,Vr,xi,Si,qn,ia,Wi,ha);return}else if(An&256){_n(ai,fi,Vr,xi,Si,qn,ia,Wi,ha);return}}sa&8?(Ia&16&&xn(ai,Si,qn),fi!==ai&&N(Vr,fi)):Ia&16?sa&16?Dn(ai,fi,Vr,xi,Si,qn,ia,Wi,ha):xn(ai,Si,qn,!0):(Ia&8&&N(Vr,""),sa&16&&Xe(fi,Vr,xi,Si,qn,ia,Wi,ha))},_n=(Vn,Yn,Vr,xi,Si,qn,ia,Wi,ha)=>{Vn=Vn||EMPTY_ARR,Yn=Yn||EMPTY_ARR;const ai=Vn.length,Ia=Yn.length,fi=Math.min(ai,Ia);let An;for(An=0;An<fi;An++){const sa=Yn[An]=ha?cloneIfMounted(Yn[An]):normalizeVNode(Yn[An]);fe(Vn[An],sa,Vr,null,Si,qn,ia,Wi,ha)}ai>Ia?xn(Vn,Si,qn,!0,!1,fi):Xe(Yn,Vr,xi,Si,qn,ia,Wi,ha,fi)},Dn=(Vn,Yn,Vr,xi,Si,qn,ia,Wi,ha)=>{let ai=0;const Ia=Yn.length;let fi=Vn.length-1,An=Ia-1;for(;ai<=fi&&ai<=An;){const sa=Vn[ai],Nn=Yn[ai]=ha?cloneIfMounted(Yn[ai]):normalizeVNode(Yn[ai]);if(isSameVNodeType(sa,Nn))fe(sa,Nn,Vr,null,Si,qn,ia,Wi,ha);else break;ai++}for(;ai<=fi&&ai<=An;){const sa=Vn[fi],Nn=Yn[An]=ha?cloneIfMounted(Yn[An]):normalizeVNode(Yn[An]);if(isSameVNodeType(sa,Nn))fe(sa,Nn,Vr,null,Si,qn,ia,Wi,ha);else break;fi--,An--}if(ai>fi){if(ai<=An){const sa=An+1,Nn=sa<Ia?Yn[sa].el:xi;for(;ai<=An;)fe(null,Yn[ai]=ha?cloneIfMounted(Yn[ai]):normalizeVNode(Yn[ai]),Vr,Nn,Si,qn,ia,Wi,ha),ai++}}else if(ai>An)for(;ai<=fi;)Rn(Vn[ai],Si,qn,!0),ai++;else{const sa=ai,Nn=ai,fn=new Map;for(ai=Nn;ai<=An;ai++){const Pi=Yn[ai]=ha?cloneIfMounted(Yn[ai]):normalizeVNode(Yn[ai]);Pi.key!=null&&fn.set(Pi.key,ai)}let un,Ln=0;const hr=An-Nn+1;let hi=!1,bi=0;const Ra=new Array(hr);for(ai=0;ai<hr;ai++)Ra[ai]=0;for(ai=sa;ai<=fi;ai++){const Pi=Vn[ai];if(Ln>=hr){Rn(Pi,Si,qn,!0);continue}let oi;if(Pi.key!=null)oi=fn.get(Pi.key);else for(un=Nn;un<=An;un++)if(Ra[un-Nn]===0&&isSameVNodeType(Pi,Yn[un])){oi=un;break}oi===void 0?Rn(Pi,Si,qn,!0):(Ra[oi-Nn]=ai+1,oi>=bi?bi=oi:hi=!0,fe(Pi,Yn[oi],Vr,null,Si,qn,ia,Wi,ha),Ln++)}const so=hi?getSequence(Ra):EMPTY_ARR;for(un=so.length-1,ai=hr-1;ai>=0;ai--){const Pi=Nn+ai,oi=Yn[Pi],Ni=Pi+1<Ia?Yn[Pi+1].el:xi;Ra[ai]===0?fe(null,oi,Vr,Ni,Si,qn,ia,Wi,ha):hi&&(un<0||ai!==so[un]?an(oi,Vr,Ni,2):un--)}}},an=(Vn,Yn,Vr,xi,Si=null)=>{const{el:qn,type:ia,transition:Wi,children:ha,shapeFlag:ai}=Vn;if(ai&6){an(Vn.component.subTree,Yn,Vr,xi);return}if(ai&128){Vn.suspense.move(Yn,Vr,xi);return}if(ai&64){ia.move(Vn,Yn,Vr,gn);return}if(ia===Fragment){n(qn,Yn,Vr);for(let fi=0;fi<ha.length;fi++)an(ha[fi],Yn,Vr,xi);n(Vn.anchor,Yn,Vr);return}if(ia===Static){De(Vn,Yn,Vr);return}if(xi!==2&&ai&1&&Wi)if(xi===0)Wi.beforeEnter(qn),n(qn,Yn,Vr),queuePostRenderEffect(()=>Wi.enter(qn),Si);else{const{leave:fi,delayLeave:An,afterLeave:sa}=Wi,Nn=()=>n(qn,Yn,Vr),fn=()=>{fi(qn,()=>{Nn(),sa&&sa()})};An?An(qn,Nn,fn):fn()}else n(qn,Yn,Vr)},Rn=(Vn,Yn,Vr,xi=!1,Si=!1)=>{const{type:qn,props:ia,ref:Wi,children:ha,dynamicChildren:ai,shapeFlag:Ia,patchFlag:fi,dirs:An,cacheIndex:sa}=Vn;if(fi===-2&&(Si=!1),Wi!=null&&setRef(Wi,null,Vr,Vn,!0),sa!=null&&(Yn.renderCache[sa]=void 0),Ia&256){Yn.ctx.deactivate(Vn);return}const Nn=Ia&1&&An,fn=!isAsyncWrapper(Vn);let un;if(fn&&(un=ia&&ia.onVnodeBeforeUnmount)&&invokeVNodeHook(un,Yn,Vn),Ia&6)hn(Vn.component,Vr,xi);else{if(Ia&128){Vn.suspense.unmount(Vr,xi);return}Nn&&invokeDirectiveHook(Vn,null,Yn,"beforeUnmount"),Ia&64?Vn.type.remove(Vn,Yn,Vr,gn,xi):ai&&!ai.hasOnce&&(qn!==Fragment||fi>0&&fi&64)?xn(ai,Yn,Vr,!1,!0):(qn===Fragment&&fi&384||!Si&&Ia&16)&&xn(ha,Yn,Vr),xi&&Lt(Vn)}(fn&&(un=ia&&ia.onVnodeUnmounted)||Nn)&&queuePostRenderEffect(()=>{un&&invokeVNodeHook(un,Yn,Vn),Nn&&invokeDirectiveHook(Vn,null,Yn,"unmounted")},Vr)},Lt=Vn=>{const{type:Yn,el:Vr,anchor:xi,transition:Si}=Vn;if(Yn===Fragment){wn(Vr,xi);return}if(Yn===Static){Ve(Vn);return}const qn=()=>{u(Vr),Si&&!Si.persisted&&Si.afterLeave&&Si.afterLeave()};if(Vn.shapeFlag&1&&Si&&!Si.persisted){const{leave:ia,delayLeave:Wi}=Si,ha=()=>ia(Vr,qn);Wi?Wi(Vn.el,qn,ha):ha()}else qn()},wn=(Vn,Yn)=>{let Vr;for(;Vn!==Yn;)Vr=G(Vn),u(Vn),Vn=Vr;u(Yn)},hn=(Vn,Yn,Vr)=>{const{bum:xi,scope:Si,job:qn,subTree:ia,um:Wi,m:ha,a:ai}=Vn;invalidateMount(ha),invalidateMount(ai),xi&&invokeArrayFns(xi),Si.stop(),qn&&(qn.flags|=8,Rn(ia,Vn,Yn,Vr)),Wi&&queuePostRenderEffect(Wi,Yn),queuePostRenderEffect(()=>{Vn.isUnmounted=!0},Yn),Yn&&Yn.pendingBranch&&!Yn.isUnmounted&&Vn.asyncDep&&!Vn.asyncResolved&&Vn.suspenseId===Yn.pendingId&&(Yn.deps--,Yn.deps===0&&Yn.resolve())},xn=(Vn,Yn,Vr,xi=!1,Si=!1,qn=0)=>{for(let ia=qn;ia<Vn.length;ia++)Rn(Vn[ia],Yn,Vr,xi,Si)},$n=Vn=>{if(Vn.shapeFlag&6)return $n(Vn.component.subTree);if(Vn.shapeFlag&128)return Vn.suspense.next();const Yn=G(Vn.anchor||Vn.el),Vr=Yn&&Yn[TeleportEndKey];return Vr?G(Vr):Yn};let Xr=!1;const ti=(Vn,Yn,Vr)=>{Vn==null?Yn._vnode&&Rn(Yn._vnode,null,null,!0):fe(Yn._vnode||null,Vn,Yn,null,null,null,Vr),Yn._vnode=Vn,Xr||(Xr=!0,flushPreFlushCbs(),flushPostFlushCbs(),Xr=!1)},gn={p:fe,um:Rn,m:an,r:Lt,mt:kt,mc:Xe,pc:pn,pbc:ue,n:$n,o:t};let Xn,Kn;return e&&([Xn,Kn]=e(gn)),{render:ti,hydrate:Xn,createApp:createAppAPI(ti,Xn)}}function resolveChildrenNamespace({type:t,props:e},l){return l==="svg"&&t==="foreignObject"||l==="mathml"&&t==="annotation-xml"&&e&&e.encoding&&e.encoding.includes("html")?void 0:l}function toggleRecurse({effect:t,job:e},l){l?(t.flags|=32,e.flags|=4):(t.flags&=-33,e.flags&=-5)}function needTransition(t,e){return(!t||t&&!t.pendingBranch)&&e&&!e.persisted}function traverseStaticChildren(t,e,l=!1){const n=t.children,u=e.children;if(isArray$3(n)&&isArray$3(u))for(let c=0;c<n.length;c++){const y=n[c];let b=u[c];b.shapeFlag&1&&!b.dynamicChildren&&((b.patchFlag<=0||b.patchFlag===32)&&(b=u[c]=cloneIfMounted(u[c]),b.el=y.el),!l&&b.patchFlag!==-2&&traverseStaticChildren(y,b)),b.type===Text&&(b.el=y.el)}}function getSequence(t){const e=t.slice(),l=[0];let n,u,c,y,b;const m=t.length;for(n=0;n<m;n++){const O=t[n];if(O!==0){if(u=l[l.length-1],t[u]<O){e[n]=u,l.push(n);continue}for(c=0,y=l.length-1;c<y;)b=c+y>>1,t[l[b]]<O?c=b+1:y=b;O<t[l[c]]&&(c>0&&(e[n]=l[c-1]),l[c]=n)}}for(c=l.length,y=l[c-1];c-- >0;)l[c]=y,y=e[y];return l}function locateNonHydratedAsyncRoot(t){const e=t.subTree.component;if(e)return e.asyncDep&&!e.asyncResolved?e:locateNonHydratedAsyncRoot(e)}function invalidateMount(t){if(t)for(let e=0;e<t.length;e++)t[e].flags|=8}const ssrContextKey=Symbol.for("v-scx"),useSSRContext=()=>inject$1(ssrContextKey);function watchEffect(t,e){return doWatch(t,null,e)}function watchPostEffect(t,e){return doWatch(t,null,{flush:"post"})}function watchSyncEffect(t,e){return doWatch(t,null,{flush:"sync"})}function watch(t,e,l){return doWatch(t,e,l)}function doWatch(t,e,l=EMPTY_OBJ){const{immediate:n,deep:u,flush:c,once:y}=l,b=extend$1({},l);let m;if(isInSSRComponentSetup)if(c==="sync"){const G=useSSRContext();m=G.__watcherHandles||(G.__watcherHandles=[])}else if(!e||n)b.once=!0;else{const G=()=>{};return G.stop=NOOP,G.resume=NOOP,G.pause=NOOP,G}const O=currentInstance;b.call=(G,q,J)=>callWithAsyncErrorHandling(G,O,q,J);let N=!1;c==="post"?b.scheduler=G=>{queuePostRenderEffect(G,O&&O.suspense)}:c!=="sync"&&(N=!0,b.scheduler=(G,q)=>{q?G():queueJob(G)}),b.augmentJob=G=>{e&&(G.flags|=4),N&&(G.flags|=2,O&&(G.id=O.uid,G.i=O))};const L=watch$1(t,e,b);return m&&m.push(L),L}function instanceWatch(t,e,l){const n=this.proxy,u=isString$2(t)?t.includes(".")?createPathGetter(n,t):()=>n[t]:t.bind(n,n);let c;isFunction$2(e)?c=e:(c=e.handler,l=e);const y=setCurrentInstance(this),b=doWatch(u,c.bind(n),l);return y(),b}function createPathGetter(t,e){const l=e.split(".");return()=>{let n=t;for(let u=0;u<l.length&&n;u++)n=n[l[u]];return n}}function useModel(t,e,l=EMPTY_OBJ){const n=getCurrentInstance$1(),u=camelize(e),c=hyphenate(e),y=getModelModifiers(t,e),b=customRef((m,O)=>{let N,L=EMPTY_OBJ,G;return watchSyncEffect(()=>{const q=t[e];hasChanged(N,q)&&(N=q,O())}),{get(){return m(),l.get?l.get(N):N},set(q){const J=l.set?l.set(q):q;if(!hasChanged(J,N)&&!(L!==EMPTY_OBJ&&hasChanged(q,L)))return;const fe=n.vnode.props;fe&&(e in fe||u in fe||c in fe)&&(`onUpdate:${e}`in fe||`onUpdate:${u}`in fe||`onUpdate:${c}`in fe)||(N=q,O()),n.emit(`update:${e}`,J),hasChanged(q,J)&&hasChanged(q,L)&&!hasChanged(J,G)&&O(),L=q,G=J}}});return b[Symbol.iterator]=()=>{let m=0;return{next(){return m<2?{value:m++?y||EMPTY_OBJ:b,done:!1}:{done:!0}}}},b}const getModelModifiers=(t,e)=>e==="modelValue"||e==="model-value"?t.modelModifiers:t[`${e}Modifiers`]||t[`${camelize(e)}Modifiers`]||t[`${hyphenate(e)}Modifiers`];function emit(t,e,...l){if(t.isUnmounted)return;const n=t.vnode.props||EMPTY_OBJ;let u=l;const c=e.startsWith("update:"),y=c&&getModelModifiers(n,e.slice(7));y&&(y.trim&&(u=l.map(N=>isString$2(N)?N.trim():N)),y.number&&(u=l.map(looseToNumber)));let b,m=n[b=toHandlerKey(e)]||n[b=toHandlerKey(camelize(e))];!m&&c&&(m=n[b=toHandlerKey(hyphenate(e))]),m&&callWithAsyncErrorHandling(m,t,6,u);const O=n[b+"Once"];if(O){if(!t.emitted)t.emitted={};else if(t.emitted[b])return;t.emitted[b]=!0,callWithAsyncErrorHandling(O,t,6,u)}}function normalizeEmitsOptions(t,e,l=!1){const n=e.emitsCache,u=n.get(t);if(u!==void 0)return u;const c=t.emits;let y={},b=!1;if(!isFunction$2(t)){const m=O=>{const N=normalizeEmitsOptions(O,e,!0);N&&(b=!0,extend$1(y,N))};!l&&e.mixins.length&&e.mixins.forEach(m),t.extends&&m(t.extends),t.mixins&&t.mixins.forEach(m)}return!c&&!b?(isObject$2(t)&&n.set(t,null),null):(isArray$3(c)?c.forEach(m=>y[m]=null):extend$1(y,c),isObject$2(t)&&n.set(t,y),y)}function isEmitListener(t,e){return!t||!isOn$1(e)?!1:(e=e.slice(2).replace(/Once$/,""),hasOwn(t,e[0].toLowerCase()+e.slice(1))||hasOwn(t,hyphenate(e))||hasOwn(t,e))}function markAttrsAccessed(){}function renderComponentRoot(t){const{type:e,vnode:l,proxy:n,withProxy:u,propsOptions:[c],slots:y,attrs:b,emit:m,render:O,renderCache:N,props:L,data:G,setupState:q,ctx:J,inheritAttrs:fe}=t,ve=setCurrentRenderingInstance(t);let ne,Ue;try{if(l.shapeFlag&4){const Ve=u||n,rt=Ve;ne=normalizeVNode(O.call(rt,Ve,N,L,q,G,J)),Ue=b}else{const Ve=e;ne=normalizeVNode(Ve.length>1?Ve(L,{attrs:b,slots:y,emit:m}):Ve(L,null)),Ue=e.props?b:getFunctionalFallthrough(b)}}catch(Ve){blockStack.length=0,handleError(Ve,t,1),ne=createVNode(Comment)}let De=ne;if(Ue&&fe!==!1){const Ve=Object.keys(Ue),{shapeFlag:rt}=De;Ve.length&&rt&7&&(c&&Ve.some(isModelListener)&&(Ue=filterModelListeners(Ue,c)),De=cloneVNode(De,Ue,!1,!0))}return l.dirs&&(De=cloneVNode(De,null,!1,!0),De.dirs=De.dirs?De.dirs.concat(l.dirs):l.dirs),l.transition&&setTransitionHooks(De,l.transition),ne=De,setCurrentRenderingInstance(ve),ne}function filterSingleRoot(t,e=!0){let l;for(let n=0;n<t.length;n++){const u=t[n];if(isVNode(u)){if(u.type!==Comment||u.children==="v-if"){if(l)return;l=u}}else return}return l}const getFunctionalFallthrough=t=>{let e;for(const l in t)(l==="class"||l==="style"||isOn$1(l))&&((e||(e={}))[l]=t[l]);return e},filterModelListeners=(t,e)=>{const l={};for(const n in t)(!isModelListener(n)||!(n.slice(9)in e))&&(l[n]=t[n]);return l};function shouldUpdateComponent(t,e,l){const{props:n,children:u,component:c}=t,{props:y,children:b,patchFlag:m}=e,O=c.emitsOptions;if(e.dirs||e.transition)return!0;if(l&&m>=0){if(m&1024)return!0;if(m&16)return n?hasPropsChanged(n,y,O):!!y;if(m&8){const N=e.dynamicProps;for(let L=0;L<N.length;L++){const G=N[L];if(y[G]!==n[G]&&!isEmitListener(O,G))return!0}}}else return(u||b)&&(!b||!b.$stable)?!0:n===y?!1:n?y?hasPropsChanged(n,y,O):!0:!!y;return!1}function hasPropsChanged(t,e,l){const n=Object.keys(e);if(n.length!==Object.keys(t).length)return!0;for(let u=0;u<n.length;u++){const c=n[u];if(e[c]!==t[c]&&!isEmitListener(l,c))return!0}return!1}function updateHOCHostEl({vnode:t,parent:e},l){for(;e;){const n=e.subTree;if(n.suspense&&n.suspense.activeBranch===t&&(n.el=t.el),n===t)(t=e.vnode).el=l,e=e.parent;else break}}const isSuspense=t=>t.__isSuspense;let suspenseId=0;const SuspenseImpl={name:"Suspense",__isSuspense:!0,process(t,e,l,n,u,c,y,b,m,O){if(t==null)mountSuspense(e,l,n,u,c,y,b,m,O);else{if(c&&c.deps>0&&!t.suspense.isInFallback){e.suspense=t.suspense,e.suspense.vnode=e,e.el=t.el;return}patchSuspense(t,e,l,n,u,y,b,m,O)}},hydrate:hydrateSuspense,normalize:normalizeSuspenseChildren},Suspense=SuspenseImpl;function triggerEvent(t,e){const l=t.props&&t.props[e];isFunction$2(l)&&l()}function mountSuspense(t,e,l,n,u,c,y,b,m){const{p:O,o:{createElement:N}}=m,L=N("div"),G=t.suspense=createSuspenseBoundary(t,u,n,e,L,l,c,y,b,m);O(null,G.pendingBranch=t.ssContent,L,null,n,G,c,y),G.deps>0?(triggerEvent(t,"onPending"),triggerEvent(t,"onFallback"),O(null,t.ssFallback,e,l,n,null,c,y),setActiveBranch(G,t.ssFallback)):G.resolve(!1,!0)}function patchSuspense(t,e,l,n,u,c,y,b,{p:m,um:O,o:{createElement:N}}){const L=e.suspense=t.suspense;L.vnode=e,e.el=t.el;const G=e.ssContent,q=e.ssFallback,{activeBranch:J,pendingBranch:fe,isInFallback:ve,isHydrating:ne}=L;if(fe)L.pendingBranch=G,isSameVNodeType(G,fe)?(m(fe,G,L.hiddenContainer,null,u,L,c,y,b),L.deps<=0?L.resolve():ve&&(ne||(m(J,q,l,n,u,null,c,y,b),setActiveBranch(L,q)))):(L.pendingId=suspenseId++,ne?(L.isHydrating=!1,L.activeBranch=fe):O(fe,u,L),L.deps=0,L.effects.length=0,L.hiddenContainer=N("div"),ve?(m(null,G,L.hiddenContainer,null,u,L,c,y,b),L.deps<=0?L.resolve():(m(J,q,l,n,u,null,c,y,b),setActiveBranch(L,q))):J&&isSameVNodeType(G,J)?(m(J,G,l,n,u,L,c,y,b),L.resolve(!0)):(m(null,G,L.hiddenContainer,null,u,L,c,y,b),L.deps<=0&&L.resolve()));else if(J&&isSameVNodeType(G,J))m(J,G,l,n,u,L,c,y,b),setActiveBranch(L,G);else if(triggerEvent(e,"onPending"),L.pendingBranch=G,G.shapeFlag&512?L.pendingId=G.component.suspenseId:L.pendingId=suspenseId++,m(null,G,L.hiddenContainer,null,u,L,c,y,b),L.deps<=0)L.resolve();else{const{timeout:Ue,pendingId:De}=L;Ue>0?setTimeout(()=>{L.pendingId===De&&L.fallback(q)},Ue):Ue===0&&L.fallback(q)}}function createSuspenseBoundary(t,e,l,n,u,c,y,b,m,O,N=!1){const{p:L,m:G,um:q,n:J,o:{parentNode:fe,remove:ve}}=O;let ne;const Ue=isVNodeSuspensible(t);Ue&&e&&e.pendingBranch&&(ne=e.pendingId,e.deps++);const De=t.props?toNumber(t.props.timeout):void 0,Ve=c,rt={vnode:t,parent:e,parentComponent:l,namespace:y,container:n,hiddenContainer:u,deps:0,pendingId:suspenseId++,timeout:typeof De=="number"?De:-1,activeBranch:null,pendingBranch:null,isInFallback:!N,isHydrating:N,isUnmounted:!1,effects:[],resolve(Ae=!1,Te=!1){const{vnode:Xe,activeBranch:ie,pendingBranch:ue,pendingId:pt,effects:mt,parentComponent:Tt,container:kt}=rt;let It=!1;rt.isHydrating?rt.isHydrating=!1:Ae||(It=ie&&ue.transition&&ue.transition.mode==="out-in",It&&(ie.transition.afterLeave=()=>{pt===rt.pendingId&&(G(ue,kt,c===Ve?J(ie):c,0),queuePostFlushCb(mt))}),ie&&(fe(ie.el)===kt&&(c=J(ie)),q(ie,Tt,rt,!0)),It||G(ue,kt,c,0)),setActiveBranch(rt,ue),rt.pendingBranch=null,rt.isInFallback=!1;let nn=rt.parent,tn=!1;for(;nn;){if(nn.pendingBranch){nn.effects.push(...mt),tn=!0;break}nn=nn.parent}!tn&&!It&&queuePostFlushCb(mt),rt.effects=[],Ue&&e&&e.pendingBranch&&ne===e.pendingId&&(e.deps--,e.deps===0&&!Te&&e.resolve()),triggerEvent(Xe,"onResolve")},fallback(Ae){if(!rt.pendingBranch)return;const{vnode:Te,activeBranch:Xe,parentComponent:ie,container:ue,namespace:pt}=rt;triggerEvent(Te,"onFallback");const mt=J(Xe),Tt=()=>{rt.isInFallback&&(L(null,Ae,ue,mt,ie,null,pt,b,m),setActiveBranch(rt,Ae))},kt=Ae.transition&&Ae.transition.mode==="out-in";kt&&(Xe.transition.afterLeave=Tt),rt.isInFallback=!0,q(Xe,ie,null,!0),kt||Tt()},move(Ae,Te,Xe){rt.activeBranch&&G(rt.activeBranch,Ae,Te,Xe),rt.container=Ae},next(){return rt.activeBranch&&J(rt.activeBranch)},registerDep(Ae,Te,Xe){const ie=!!rt.pendingBranch;ie&&rt.deps++;const ue=Ae.vnode.el;Ae.asyncDep.catch(pt=>{handleError(pt,Ae,0)}).then(pt=>{if(Ae.isUnmounted||rt.isUnmounted||rt.pendingId!==Ae.suspenseId)return;Ae.asyncResolved=!0;const{vnode:mt}=Ae;handleSetupResult(Ae,pt,!1),ue&&(mt.el=ue);const Tt=!ue&&Ae.subTree.el;Te(Ae,mt,fe(ue||Ae.subTree.el),ue?null:J(Ae.subTree),rt,y,Xe),Tt&&ve(Tt),updateHOCHostEl(Ae,mt.el),ie&&--rt.deps===0&&rt.resolve()})},unmount(Ae,Te){rt.isUnmounted=!0,rt.activeBranch&&q(rt.activeBranch,l,Ae,Te),rt.pendingBranch&&q(rt.pendingBranch,l,Ae,Te)}};return rt}function hydrateSuspense(t,e,l,n,u,c,y,b,m){const O=e.suspense=createSuspenseBoundary(e,n,l,t.parentNode,document.createElement("div"),null,u,c,y,b,!0),N=m(t,O.pendingBranch=e.ssContent,l,O,c,y);return O.deps===0&&O.resolve(!1,!0),N}function normalizeSuspenseChildren(t){const{shapeFlag:e,children:l}=t,n=e&32;t.ssContent=normalizeSuspenseSlot(n?l.default:l),t.ssFallback=n?normalizeSuspenseSlot(l.fallback):createVNode(Comment)}function normalizeSuspenseSlot(t){let e;if(isFunction$2(t)){const l=isBlockTreeEnabled&&t._c;l&&(t._d=!1,openBlock()),t=t(),l&&(t._d=!0,e=currentBlock,closeBlock())}return isArray$3(t)&&(t=filterSingleRoot(t)),t=normalizeVNode(t),e&&!t.dynamicChildren&&(t.dynamicChildren=e.filter(l=>l!==t)),t}function queueEffectWithSuspense(t,e){e&&e.pendingBranch?isArray$3(t)?e.effects.push(...t):e.effects.push(t):queuePostFlushCb(t)}function setActiveBranch(t,e){t.activeBranch=e;const{vnode:l,parentComponent:n}=t;let u=e.el;for(;!u&&e.component;)e=e.component.subTree,u=e.el;l.el=u,n&&n.subTree===l&&(n.vnode.el=u,updateHOCHostEl(n,u))}function isVNodeSuspensible(t){const e=t.props&&t.props.suspensible;return e!=null&&e!==!1}const Fragment=Symbol.for("v-fgt"),Text=Symbol.for("v-txt"),Comment=Symbol.for("v-cmt"),Static=Symbol.for("v-stc"),blockStack=[];let currentBlock=null;function openBlock(t=!1){blockStack.push(currentBlock=t?null:[])}function closeBlock(){blockStack.pop(),currentBlock=blockStack[blockStack.length-1]||null}let isBlockTreeEnabled=1;function setBlockTracking(t){isBlockTreeEnabled+=t,t<0&¤tBlock&&(currentBlock.hasOnce=!0)}function setupBlock(t){return t.dynamicChildren=isBlockTreeEnabled>0?currentBlock||EMPTY_ARR:null,closeBlock(),isBlockTreeEnabled>0&¤tBlock&¤tBlock.push(t),t}function createElementBlock(t,e,l,n,u,c){return setupBlock(createBaseVNode(t,e,l,n,u,c,!0))}function createBlock(t,e,l,n,u){return setupBlock(createVNode(t,e,l,n,u,!0))}function isVNode(t){return t?t.__v_isVNode===!0:!1}function isSameVNodeType(t,e){return t.type===e.type&&t.key===e.key}function transformVNodeArgs(t){}const normalizeKey=({key:t})=>t??null,normalizeRef=({ref:t,ref_key:e,ref_for:l})=>(typeof t=="number"&&(t=""+t),t!=null?isString$2(t)||isRef(t)||isFunction$2(t)?{i:currentRenderingInstance,r:t,k:e,f:!!l}:t:null);function createBaseVNode(t,e=null,l=null,n=0,u=null,c=t===Fragment?0:1,y=!1,b=!1){const m={__v_isVNode:!0,__v_skip:!0,type:t,props:e,key:e&&normalizeKey(e),ref:e&&normalizeRef(e),scopeId:currentScopeId,slotScopeIds:null,children:l,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:c,patchFlag:n,dynamicProps:u,dynamicChildren:null,appContext:null,ctx:currentRenderingInstance};return b?(normalizeChildren(m,l),c&128&&t.normalize(m)):l&&(m.shapeFlag|=isString$2(l)?8:16),isBlockTreeEnabled>0&&!y&¤tBlock&&(m.patchFlag>0||c&6)&&m.patchFlag!==32&¤tBlock.push(m),m}const createVNode=_createVNode;function _createVNode(t,e=null,l=null,n=0,u=null,c=!1){if((!t||t===NULL_DYNAMIC_COMPONENT)&&(t=Comment),isVNode(t)){const b=cloneVNode(t,e,!0);return l&&normalizeChildren(b,l),isBlockTreeEnabled>0&&!c&¤tBlock&&(b.shapeFlag&6?currentBlock[currentBlock.indexOf(t)]=b:currentBlock.push(b)),b.patchFlag=-2,b}if(isClassComponent(t)&&(t=t.__vccOpts),e){e=guardReactiveProps(e);let{class:b,style:m}=e;b&&!isString$2(b)&&(e.class=normalizeClass(b)),isObject$2(m)&&(isProxy(m)&&!isArray$3(m)&&(m=extend$1({},m)),e.style=normalizeStyle(m))}const y=isString$2(t)?1:isSuspense(t)?128:isTeleport(t)?64:isObject$2(t)?4:isFunction$2(t)?2:0;return createBaseVNode(t,e,l,n,u,y,c,!0)}function guardReactiveProps(t){return t?isProxy(t)||isInternalObject(t)?extend$1({},t):t:null}function cloneVNode(t,e,l=!1,n=!1){const{props:u,ref:c,patchFlag:y,children:b,transition:m}=t,O=e?mergeProps(u||{},e):u,N={__v_isVNode:!0,__v_skip:!0,type:t.type,props:O,key:O&&normalizeKey(O),ref:e&&e.ref?l&&c?isArray$3(c)?c.concat(normalizeRef(e)):[c,normalizeRef(e)]:normalizeRef(e):c,scopeId:t.scopeId,slotScopeIds:t.slotScopeIds,children:b,target:t.target,targetStart:t.targetStart,targetAnchor:t.targetAnchor,staticCount:t.staticCount,shapeFlag:t.shapeFlag,patchFlag:e&&t.type!==Fragment?y===-1?16:y|16:y,dynamicProps:t.dynamicProps,dynamicChildren:t.dynamicChildren,appContext:t.appContext,dirs:t.dirs,transition:m,component:t.component,suspense:t.suspense,ssContent:t.ssContent&&cloneVNode(t.ssContent),ssFallback:t.ssFallback&&cloneVNode(t.ssFallback),el:t.el,anchor:t.anchor,ctx:t.ctx,ce:t.ce};return m&&n&&setTransitionHooks(N,m.clone(N)),N}function createTextVNode(t=" ",e=0){return createVNode(Text,null,t,e)}function createStaticVNode(t,e){const l=createVNode(Static,null,t);return l.staticCount=e,l}function createCommentVNode(t="",e=!1){return e?(openBlock(),createBlock(Comment,null,t)):createVNode(Comment,null,t)}function normalizeVNode(t){return t==null||typeof t=="boolean"?createVNode(Comment):isArray$3(t)?createVNode(Fragment,null,t.slice()):typeof t=="object"?cloneIfMounted(t):createVNode(Text,null,String(t))}function cloneIfMounted(t){return t.el===null&&t.patchFlag!==-1||t.memo?t:cloneVNode(t)}function normalizeChildren(t,e){let l=0;const{shapeFlag:n}=t;if(e==null)e=null;else if(isArray$3(e))l=16;else if(typeof e=="object")if(n&65){const u=e.default;u&&(u._c&&(u._d=!1),normalizeChildren(t,u()),u._c&&(u._d=!0));return}else{l=32;const u=e._;!u&&!isInternalObject(e)?e._ctx=currentRenderingInstance:u===3&¤tRenderingInstance&&(currentRenderingInstance.slots._===1?e._=1:(e._=2,t.patchFlag|=1024))}else isFunction$2(e)?(e={default:e,_ctx:currentRenderingInstance},l=32):(e=String(e),n&64?(l=16,e=[createTextVNode(e)]):l=8);t.children=e,t.shapeFlag|=l}function mergeProps(...t){const e={};for(let l=0;l<t.length;l++){const n=t[l];for(const u in n)if(u==="class")e.class!==n.class&&(e.class=normalizeClass([e.class,n.class]));else if(u==="style")e.style=normalizeStyle([e.style,n.style]);else if(isOn$1(u)){const c=e[u],y=n[u];y&&c!==y&&!(isArray$3(c)&&c.includes(y))&&(e[u]=c?[].concat(c,y):y)}else u!==""&&(e[u]=n[u])}return e}function invokeVNodeHook(t,e,l,n=null){callWithAsyncErrorHandling(t,e,7,[l,n])}const emptyAppContext=createAppContext();let uid=0;function createComponentInstance(t,e,l){const n=t.type,u=(e?e.appContext:t.appContext)||emptyAppContext,c={uid:uid++,vnode:t,type:n,parent:e,appContext:u,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new EffectScope(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:e?e.provides:Object.create(u.provides),ids:e?e.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:normalizePropsOptions(n,u),emitsOptions:normalizeEmitsOptions(n,u),emit:null,emitted:null,propsDefaults:EMPTY_OBJ,inheritAttrs:n.inheritAttrs,ctx:EMPTY_OBJ,data:EMPTY_OBJ,props:EMPTY_OBJ,attrs:EMPTY_OBJ,slots:EMPTY_OBJ,refs:EMPTY_OBJ,setupState:EMPTY_OBJ,setupContext:null,suspense:l,suspenseId:l?l.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return c.ctx={_:c},c.root=e?e.root:c,c.emit=emit.bind(null,c),t.ce&&t.ce(c),c}let currentInstance=null;const getCurrentInstance$1=()=>currentInstance||currentRenderingInstance;let internalSetCurrentInstance,setInSSRSetupState;{const t=getGlobalThis(),e=(l,n)=>{let u;return(u=t[l])||(u=t[l]=[]),u.push(n),c=>{u.length>1?u.forEach(y=>y(c)):u[0](c)}};internalSetCurrentInstance=e("__VUE_INSTANCE_SETTERS__",l=>currentInstance=l),setInSSRSetupState=e("__VUE_SSR_SETTERS__",l=>isInSSRComponentSetup=l)}const setCurrentInstance=t=>{const e=currentInstance;return internalSetCurrentInstance(t),t.scope.on(),()=>{t.scope.off(),internalSetCurrentInstance(e)}},unsetCurrentInstance=()=>{currentInstance&¤tInstance.scope.off(),internalSetCurrentInstance(null)};function isStatefulComponent(t){return t.vnode.shapeFlag&4}let isInSSRComponentSetup=!1;function setupComponent(t,e=!1,l=!1){e&&setInSSRSetupState(e);const{props:n,children:u}=t.vnode,c=isStatefulComponent(t);initProps(t,n,c,e),initSlots(t,u,l);const y=c?setupStatefulComponent(t,e):void 0;return e&&setInSSRSetupState(!1),y}function setupStatefulComponent(t,e){const l=t.type;t.accessCache=Object.create(null),t.proxy=new Proxy(t.ctx,PublicInstanceProxyHandlers);const{setup:n}=l;if(n){const u=t.setupContext=n.length>1?createSetupContext(t):null,c=setCurrentInstance(t);pauseTracking();const y=callWithErrorHandling(n,t,0,[t.props,u]);if(resetTracking(),c(),isPromise$2(y)){if(isAsyncWrapper(t)||markAsyncBoundary(t),y.then(unsetCurrentInstance,unsetCurrentInstance),e)return y.then(b=>{handleSetupResult(t,b,e)}).catch(b=>{handleError(b,t,0)});t.asyncDep=y}else handleSetupResult(t,y,e)}else finishComponentSetup(t,e)}function handleSetupResult(t,e,l){isFunction$2(e)?t.type.__ssrInlineRender?t.ssrRender=e:t.render=e:isObject$2(e)&&(t.setupState=proxyRefs(e)),finishComponentSetup(t,l)}let compile,installWithProxy;function registerRuntimeCompiler(t){compile=t,installWithProxy=e=>{e.render._rc&&(e.withProxy=new Proxy(e.ctx,RuntimeCompiledPublicInstanceProxyHandlers))}}const isRuntimeOnly=()=>!compile;function finishComponentSetup(t,e,l){const n=t.type;if(!t.render){if(!e&&compile&&!n.render){const u=n.template||resolveMergedOptions(t).template;if(u){const{isCustomElement:c,compilerOptions:y}=t.appContext.config,{delimiters:b,compilerOptions:m}=n,O=extend$1(extend$1({isCustomElement:c,delimiters:b},y),m);n.render=compile(u,O)}}t.render=n.render||NOOP,installWithProxy&&installWithProxy(t)}{const u=setCurrentInstance(t);pauseTracking();try{applyOptions(t)}finally{resetTracking(),u()}}}const attrsProxyHandlers={get(t,e){return track(t,"get",""),t[e]}};function createSetupContext(t){const e=l=>{t.exposed=l||{}};return{attrs:new Proxy(t.attrs,attrsProxyHandlers),slots:t.slots,emit:t.emit,expose:e}}function getComponentPublicInstance(t){return t.exposed?t.exposeProxy||(t.exposeProxy=new Proxy(proxyRefs(markRaw(t.exposed)),{get(e,l){if(l in e)return e[l];if(l in publicPropertiesMap)return publicPropertiesMap[l](t)},has(e,l){return l in e||l in publicPropertiesMap}})):t.proxy}const classifyRE=/(?:^|[-_])(\w)/g,classify=t=>t.replace(classifyRE,e=>e.toUpperCase()).replace(/[-_]/g,"");function getComponentName(t,e=!0){return isFunction$2(t)?t.displayName||t.name:t.name||e&&t.__name}function formatComponentName(t,e,l=!1){let n=getComponentName(e);if(!n&&e.__file){const u=e.__file.match(/([^/\\]+)\.\w+$/);u&&(n=u[1])}if(!n&&t&&t.parent){const u=c=>{for(const y in c)if(c[y]===e)return y};n=u(t.components||t.parent.type.components)||u(t.appContext.components)}return n?classify(n):l?"App":"Anonymous"}function isClassComponent(t){return isFunction$2(t)&&"__vccOpts"in t}const computed=(t,e)=>computed$1(t,e,isInSSRComponentSetup);function h(t,e,l){const n=arguments.length;return n===2?isObject$2(e)&&!isArray$3(e)?isVNode(e)?createVNode(t,null,[e]):createVNode(t,e):createVNode(t,null,e):(n>3?l=Array.prototype.slice.call(arguments,2):n===3&&isVNode(l)&&(l=[l]),createVNode(t,e,l))}function initCustomFormatter(){}function withMemo(t,e,l,n){const u=l[n];if(u&&isMemoSame(u,t))return u;const c=e();return c.memo=t.slice(),c.cacheIndex=n,l[n]=c}function isMemoSame(t,e){const l=t.memo;if(l.length!=e.length)return!1;for(let n=0;n<l.length;n++)if(hasChanged(l[n],e[n]))return!1;return isBlockTreeEnabled>0&¤tBlock&¤tBlock.push(t),!0}const version$4="3.5.6",warn=NOOP,ErrorTypeStrings=ErrorTypeStrings$1,devtools=devtools$1,setDevtoolsHook=setDevtoolsHook$1,_ssrUtils={createComponentInstance,setupComponent,renderComponentRoot,setCurrentRenderingInstance,isVNode,normalizeVNode,getComponentPublicInstance,ensureValidVNode:ensureValidVNode$1,pushWarningContext,popWarningContext},ssrUtils=_ssrUtils,resolveFilter=null,compatUtils=null,DeprecationTypes=null;/**
- * @vue/runtime-dom v3.5.6
- * (c) 2018-present Yuxi (Evan) You and Vue contributors
- * @license MIT
- **/let policy;const tt=typeof window<"u"&&window.trustedTypes;if(tt)try{policy=tt.createPolicy("vue",{createHTML:t=>t})}catch{}const unsafeToTrustedHTML=policy?t=>policy.createHTML(t):t=>t,svgNS="http://www.w3.org/2000/svg",mathmlNS="http://www.w3.org/1998/Math/MathML",doc=typeof document<"u"?document:null,templateContainer=doc&&doc.createElement("template"),nodeOps={insert:(t,e,l)=>{e.insertBefore(t,l||null)},remove:t=>{const e=t.parentNode;e&&e.removeChild(t)},createElement:(t,e,l,n)=>{const u=e==="svg"?doc.createElementNS(svgNS,t):e==="mathml"?doc.createElementNS(mathmlNS,t):l?doc.createElement(t,{is:l}):doc.createElement(t);return t==="select"&&n&&n.multiple!=null&&u.setAttribute("multiple",n.multiple),u},createText:t=>doc.createTextNode(t),createComment:t=>doc.createComment(t),setText:(t,e)=>{t.nodeValue=e},setElementText:(t,e)=>{t.textContent=e},parentNode:t=>t.parentNode,nextSibling:t=>t.nextSibling,querySelector:t=>doc.querySelector(t),setScopeId(t,e){t.setAttribute(e,"")},insertStaticContent(t,e,l,n,u,c){const y=l?l.previousSibling:e.lastChild;if(u&&(u===c||u.nextSibling))for(;e.insertBefore(u.cloneNode(!0),l),!(u===c||!(u=u.nextSibling)););else{templateContainer.innerHTML=unsafeToTrustedHTML(n==="svg"?`<svg>${t}</svg>`:n==="mathml"?`<math>${t}</math>`:t);const b=templateContainer.content;if(n==="svg"||n==="mathml"){const m=b.firstChild;for(;m.firstChild;)b.appendChild(m.firstChild);b.removeChild(m)}e.insertBefore(b,l)}return[y?y.nextSibling:e.firstChild,l?l.previousSibling:e.lastChild]}},TRANSITION="transition",ANIMATION="animation",vtcKey=Symbol("_vtc"),DOMTransitionPropsValidators={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},TransitionPropsValidators=extend$1({},BaseTransitionPropsValidators,DOMTransitionPropsValidators),decorate$1=t=>(t.displayName="Transition",t.props=TransitionPropsValidators,t),Transition=decorate$1((t,{slots:e})=>h(BaseTransition,resolveTransitionProps(t),e)),callHook=(t,e=[])=>{isArray$3(t)?t.forEach(l=>l(...e)):t&&t(...e)},hasExplicitCallback=t=>t?isArray$3(t)?t.some(e=>e.length>1):t.length>1:!1;function resolveTransitionProps(t){const e={};for(const mt in t)mt in DOMTransitionPropsValidators||(e[mt]=t[mt]);if(t.css===!1)return e;const{name:l="v",type:n,duration:u,enterFromClass:c=`${l}-enter-from`,enterActiveClass:y=`${l}-enter-active`,enterToClass:b=`${l}-enter-to`,appearFromClass:m=c,appearActiveClass:O=y,appearToClass:N=b,leaveFromClass:L=`${l}-leave-from`,leaveActiveClass:G=`${l}-leave-active`,leaveToClass:q=`${l}-leave-to`}=t,J=normalizeDuration(u),fe=J&&J[0],ve=J&&J[1],{onBeforeEnter:ne,onEnter:Ue,onEnterCancelled:De,onLeave:Ve,onLeaveCancelled:rt,onBeforeAppear:Ae=ne,onAppear:Te=Ue,onAppearCancelled:Xe=De}=e,ie=(mt,Tt,kt)=>{removeTransitionClass(mt,Tt?N:b),removeTransitionClass(mt,Tt?O:y),kt&&kt()},ue=(mt,Tt)=>{mt._isLeaving=!1,removeTransitionClass(mt,L),removeTransitionClass(mt,q),removeTransitionClass(mt,G),Tt&&Tt()},pt=mt=>(Tt,kt)=>{const It=mt?Te:Ue,nn=()=>ie(Tt,mt,kt);callHook(It,[Tt,nn]),nextFrame(()=>{removeTransitionClass(Tt,mt?m:c),addTransitionClass(Tt,mt?N:b),hasExplicitCallback(It)||whenTransitionEnds(Tt,n,fe,nn)})};return extend$1(e,{onBeforeEnter(mt){callHook(ne,[mt]),addTransitionClass(mt,c),addTransitionClass(mt,y)},onBeforeAppear(mt){callHook(Ae,[mt]),addTransitionClass(mt,m),addTransitionClass(mt,O)},onEnter:pt(!1),onAppear:pt(!0),onLeave(mt,Tt){mt._isLeaving=!0;const kt=()=>ue(mt,Tt);addTransitionClass(mt,L),addTransitionClass(mt,G),forceReflow(),nextFrame(()=>{mt._isLeaving&&(removeTransitionClass(mt,L),addTransitionClass(mt,q),hasExplicitCallback(Ve)||whenTransitionEnds(mt,n,ve,kt))}),callHook(Ve,[mt,kt])},onEnterCancelled(mt){ie(mt,!1),callHook(De,[mt])},onAppearCancelled(mt){ie(mt,!0),callHook(Xe,[mt])},onLeaveCancelled(mt){ue(mt),callHook(rt,[mt])}})}function normalizeDuration(t){if(t==null)return null;if(isObject$2(t))return[NumberOf(t.enter),NumberOf(t.leave)];{const e=NumberOf(t);return[e,e]}}function NumberOf(t){return toNumber(t)}function addTransitionClass(t,e){e.split(/\s+/).forEach(l=>l&&t.classList.add(l)),(t[vtcKey]||(t[vtcKey]=new Set)).add(e)}function removeTransitionClass(t,e){e.split(/\s+/).forEach(n=>n&&t.classList.remove(n));const l=t[vtcKey];l&&(l.delete(e),l.size||(t[vtcKey]=void 0))}function nextFrame(t){requestAnimationFrame(()=>{requestAnimationFrame(t)})}let endId=0;function whenTransitionEnds(t,e,l,n){const u=t._endId=++endId,c=()=>{u===t._endId&&n()};if(l)return setTimeout(c,l);const{type:y,timeout:b,propCount:m}=getTransitionInfo(t,e);if(!y)return n();const O=y+"end";let N=0;const L=()=>{t.removeEventListener(O,G),c()},G=q=>{q.target===t&&++N>=m&&L()};setTimeout(()=>{N<m&&L()},b+1),t.addEventListener(O,G)}function getTransitionInfo(t,e){const l=window.getComputedStyle(t),n=J=>(l[J]||"").split(", "),u=n(`${TRANSITION}Delay`),c=n(`${TRANSITION}Duration`),y=getTimeout(u,c),b=n(`${ANIMATION}Delay`),m=n(`${ANIMATION}Duration`),O=getTimeout(b,m);let N=null,L=0,G=0;e===TRANSITION?y>0&&(N=TRANSITION,L=y,G=c.length):e===ANIMATION?O>0&&(N=ANIMATION,L=O,G=m.length):(L=Math.max(y,O),N=L>0?y>O?TRANSITION:ANIMATION:null,G=N?N===TRANSITION?c.length:m.length:0);const q=N===TRANSITION&&/\b(transform|all)(,|$)/.test(n(`${TRANSITION}Property`).toString());return{type:N,timeout:L,propCount:G,hasTransform:q}}function getTimeout(t,e){for(;t.length<e.length;)t=t.concat(t);return Math.max(...e.map((l,n)=>toMs(l)+toMs(t[n])))}function toMs(t){return t==="auto"?0:Number(t.slice(0,-1).replace(",","."))*1e3}function forceReflow(){return document.body.offsetHeight}function patchClass(t,e,l){const n=t[vtcKey];n&&(e=(e?[e,...n]:[...n]).join(" ")),e==null?t.removeAttribute("class"):l?t.setAttribute("class",e):t.className=e}const vShowOriginalDisplay=Symbol("_vod"),vShowHidden=Symbol("_vsh"),vShow={beforeMount(t,{value:e},{transition:l}){t[vShowOriginalDisplay]=t.style.display==="none"?"":t.style.display,l&&e?l.beforeEnter(t):setDisplay(t,e)},mounted(t,{value:e},{transition:l}){l&&e&&l.enter(t)},updated(t,{value:e,oldValue:l},{transition:n}){!e!=!l&&(n?e?(n.beforeEnter(t),setDisplay(t,!0),n.enter(t)):n.leave(t,()=>{setDisplay(t,!1)}):setDisplay(t,e))},beforeUnmount(t,{value:e}){setDisplay(t,e)}};function setDisplay(t,e){t.style.display=e?t[vShowOriginalDisplay]:"none",t[vShowHidden]=!e}function initVShowForSSR(){vShow.getSSRProps=({value:t})=>{if(!t)return{style:{display:"none"}}}}const CSS_VAR_TEXT=Symbol("");function useCssVars(t){const e=getCurrentInstance$1();if(!e)return;const l=e.ut=(u=t(e.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${e.uid}"]`)).forEach(c=>setVarsOnNode(c,u))},n=()=>{const u=t(e.proxy);e.ce?setVarsOnNode(e.ce,u):setVarsOnVNode(e.subTree,u),l(u)};onBeforeMount(()=>{watchPostEffect(n)}),onMounted(()=>{const u=new MutationObserver(n);u.observe(e.subTree.el.parentNode,{childList:!0}),onUnmounted(()=>u.disconnect())})}function setVarsOnVNode(t,e){if(t.shapeFlag&128){const l=t.suspense;t=l.activeBranch,l.pendingBranch&&!l.isHydrating&&l.effects.push(()=>{setVarsOnVNode(l.activeBranch,e)})}for(;t.component;)t=t.component.subTree;if(t.shapeFlag&1&&t.el)setVarsOnNode(t.el,e);else if(t.type===Fragment)t.children.forEach(l=>setVarsOnVNode(l,e));else if(t.type===Static){let{el:l,anchor:n}=t;for(;l&&(setVarsOnNode(l,e),l!==n);)l=l.nextSibling}}function setVarsOnNode(t,e){if(t.nodeType===1){const l=t.style;let n="";for(const u in e)l.setProperty(`--${u}`,e[u]),n+=`--${u}: ${e[u]};`;l[CSS_VAR_TEXT]=n}}const displayRE=/(^|;)\s*display\s*:/;function patchStyle(t,e,l){const n=t.style,u=isString$2(l);let c=!1;if(l&&!u){if(e)if(isString$2(e))for(const y of e.split(";")){const b=y.slice(0,y.indexOf(":")).trim();l[b]==null&&setStyle(n,b,"")}else for(const y in e)l[y]==null&&setStyle(n,y,"");for(const y in l)y==="display"&&(c=!0),setStyle(n,y,l[y])}else if(u){if(e!==l){const y=n[CSS_VAR_TEXT];y&&(l+=";"+y),n.cssText=l,c=displayRE.test(l)}}else e&&t.removeAttribute("style");vShowOriginalDisplay in t&&(t[vShowOriginalDisplay]=c?n.display:"",t[vShowHidden]&&(n.display="none"))}const importantRE=/\s*!important$/;function setStyle(t,e,l){if(isArray$3(l))l.forEach(n=>setStyle(t,e,n));else if(l==null&&(l=""),e.startsWith("--"))t.setProperty(e,l);else{const n=autoPrefix(t,e);importantRE.test(l)?t.setProperty(hyphenate(n),l.replace(importantRE,""),"important"):t[n]=l}}const prefixes=["Webkit","Moz","ms"],prefixCache={};function autoPrefix(t,e){const l=prefixCache[e];if(l)return l;let n=camelize(e);if(n!=="filter"&&n in t)return prefixCache[e]=n;n=capitalize(n);for(let u=0;u<prefixes.length;u++){const c=prefixes[u]+n;if(c in t)return prefixCache[e]=c}return e}const xlinkNS="http://www.w3.org/1999/xlink";function patchAttr(t,e,l,n,u,c=isSpecialBooleanAttr(e)){n&&e.startsWith("xlink:")?l==null?t.removeAttributeNS(xlinkNS,e.slice(6,e.length)):t.setAttributeNS(xlinkNS,e,l):l==null||c&&!includeBooleanAttr(l)?t.removeAttribute(e):t.setAttribute(e,c?"":isSymbol(l)?String(l):l)}function patchDOMProp(t,e,l,n){if(e==="innerHTML"||e==="textContent"){l!=null&&(t[e]=e==="innerHTML"?unsafeToTrustedHTML(l):l);return}const u=t.tagName;if(e==="value"&&u!=="PROGRESS"&&!u.includes("-")){const y=u==="OPTION"?t.getAttribute("value")||"":t.value,b=l==null?t.type==="checkbox"?"on":"":String(l);(y!==b||!("_value"in t))&&(t.value=b),l==null&&t.removeAttribute(e),t._value=l;return}let c=!1;if(l===""||l==null){const y=typeof t[e];y==="boolean"?l=includeBooleanAttr(l):l==null&&y==="string"?(l="",c=!0):y==="number"&&(l=0,c=!0)}try{t[e]=l}catch{}c&&t.removeAttribute(e)}function addEventListener(t,e,l,n){t.addEventListener(e,l,n)}function removeEventListener(t,e,l,n){t.removeEventListener(e,l,n)}const veiKey=Symbol("_vei");function patchEvent(t,e,l,n,u=null){const c=t[veiKey]||(t[veiKey]={}),y=c[e];if(n&&y)y.value=n;else{const[b,m]=parseName(e);if(n){const O=c[e]=createInvoker(n,u);addEventListener(t,b,O,m)}else y&&(removeEventListener(t,b,y,m),c[e]=void 0)}}const optionsModifierRE=/(?:Once|Passive|Capture)$/;function parseName(t){let e;if(optionsModifierRE.test(t)){e={};let n;for(;n=t.match(optionsModifierRE);)t=t.slice(0,t.length-n[0].length),e[n[0].toLowerCase()]=!0}return[t[2]===":"?t.slice(3):hyphenate(t.slice(2)),e]}let cachedNow=0;const p$2=Promise.resolve(),getNow=()=>cachedNow||(p$2.then(()=>cachedNow=0),cachedNow=Date.now());function createInvoker(t,e){const l=n=>{if(!n._vts)n._vts=Date.now();else if(n._vts<=l.attached)return;callWithAsyncErrorHandling(patchStopImmediatePropagation(n,l.value),e,5,[n])};return l.value=t,l.attached=getNow(),l}function patchStopImmediatePropagation(t,e){if(isArray$3(e)){const l=t.stopImmediatePropagation;return t.stopImmediatePropagation=()=>{l.call(t),t._stopped=!0},e.map(n=>u=>!u._stopped&&n&&n(u))}else return e}const isNativeOn=t=>t.charCodeAt(0)===111&&t.charCodeAt(1)===110&&t.charCodeAt(2)>96&&t.charCodeAt(2)<123,patchProp=(t,e,l,n,u,c)=>{const y=u==="svg";e==="class"?patchClass(t,n,y):e==="style"?patchStyle(t,l,n):isOn$1(e)?isModelListener(e)||patchEvent(t,e,l,n,c):(e[0]==="."?(e=e.slice(1),!0):e[0]==="^"?(e=e.slice(1),!1):shouldSetAsProp(t,e,n,y))?(patchDOMProp(t,e,n),!t.tagName.includes("-")&&(e==="value"||e==="checked"||e==="selected")&&patchAttr(t,e,n,y,c,e!=="value")):(e==="true-value"?t._trueValue=n:e==="false-value"&&(t._falseValue=n),patchAttr(t,e,n,y))};function shouldSetAsProp(t,e,l,n){if(n)return!!(e==="innerHTML"||e==="textContent"||e in t&&isNativeOn(e)&&isFunction$2(l));if(e==="spellcheck"||e==="draggable"||e==="translate"||e==="form"||e==="list"&&t.tagName==="INPUT"||e==="type"&&t.tagName==="TEXTAREA")return!1;if(e==="width"||e==="height"){const u=t.tagName;if(u==="IMG"||u==="VIDEO"||u==="CANVAS"||u==="SOURCE")return!1}return isNativeOn(e)&&isString$2(l)?!1:!!(e in t||t._isVueCE&&(/[A-Z]/.test(e)||!isString$2(l)))}const REMOVAL={};/*! #__NO_SIDE_EFFECTS__ */function defineCustomElement(t,e,l){const n=defineComponent$1(t,e);isPlainObject$3(n)&&extend$1(n,e);class u extends VueElement{constructor(y){super(n,y,l)}}return u.def=n,u}/*! #__NO_SIDE_EFFECTS__ */const defineSSRCustomElement=(t,e)=>defineCustomElement(t,e,createSSRApp),BaseClass=typeof HTMLElement<"u"?HTMLElement:class{};class VueElement extends BaseClass{constructor(e,l={},n=createApp){super(),this._def=e,this._props=l,this._createApp=n,this._isVueCE=!0,this._instance=null,this._app=null,this._nonce=this._def.nonce,this._connected=!1,this._resolved=!1,this._numberProps=null,this._styleChildren=new WeakSet,this._ob=null,this.shadowRoot&&n!==createApp?this._root=this.shadowRoot:e.shadowRoot!==!1?(this.attachShadow({mode:"open"}),this._root=this.shadowRoot):this._root=this,this._def.__asyncLoader||this._resolveProps(this._def)}connectedCallback(){if(!this.isConnected)return;this.shadowRoot||this._parseSlots(),this._connected=!0;let e=this;for(;e=e&&(e.parentNode||e.host);)if(e instanceof VueElement){this._parent=e;break}this._instance||(this._resolved?(this._setParent(),this._update()):e&&e._pendingResolve?this._pendingResolve=e._pendingResolve.then(()=>{this._pendingResolve=void 0,this._resolveDef()}):this._resolveDef())}_setParent(e=this._parent){e&&(this._instance.parent=e._instance,this._instance.provides=e._instance.provides)}disconnectedCallback(){this._connected=!1,nextTick(()=>{this._connected||(this._ob&&(this._ob.disconnect(),this._ob=null),this._app&&this._app.unmount(),this._instance&&(this._instance.ce=void 0),this._app=this._instance=null)})}_resolveDef(){if(this._pendingResolve)return;for(let n=0;n<this.attributes.length;n++)this._setAttr(this.attributes[n].name);this._ob=new MutationObserver(n=>{for(const u of n)this._setAttr(u.attributeName)}),this._ob.observe(this,{attributes:!0});const e=(n,u=!1)=>{this._resolved=!0,this._pendingResolve=void 0;const{props:c,styles:y}=n;let b;if(c&&!isArray$3(c))for(const m in c){const O=c[m];(O===Number||O&&O.type===Number)&&(m in this._props&&(this._props[m]=toNumber(this._props[m])),(b||(b=Object.create(null)))[camelize(m)]=!0)}this._numberProps=b,u&&this._resolveProps(n),this.shadowRoot&&this._applyStyles(y),this._mount(n)},l=this._def.__asyncLoader;l?this._pendingResolve=l().then(n=>e(this._def=n,!0)):e(this._def)}_mount(e){this._app=this._createApp(e),e.configureApp&&e.configureApp(this._app),this._app._ceVNode=this._createVNode(),this._app.mount(this._root);const l=this._instance&&this._instance.exposed;if(l)for(const n in l)hasOwn(this,n)||Object.defineProperty(this,n,{get:()=>unref(l[n])})}_resolveProps(e){const{props:l}=e,n=isArray$3(l)?l:Object.keys(l||{});for(const u of Object.keys(this))u[0]!=="_"&&n.includes(u)&&this._setProp(u,this[u]);for(const u of n.map(camelize))Object.defineProperty(this,u,{get(){return this._getProp(u)},set(c){this._setProp(u,c,!0,!0)}})}_setAttr(e){if(e.startsWith("data-v-"))return;const l=this.hasAttribute(e);let n=l?this.getAttribute(e):REMOVAL;const u=camelize(e);l&&this._numberProps&&this._numberProps[u]&&(n=toNumber(n)),this._setProp(u,n,!1,!0)}_getProp(e){return this._props[e]}_setProp(e,l,n=!0,u=!1){l!==this._props[e]&&(l===REMOVAL?delete this._props[e]:(this._props[e]=l,e==="key"&&this._app&&(this._app._ceVNode.key=l)),u&&this._instance&&this._update(),n&&(l===!0?this.setAttribute(hyphenate(e),""):typeof l=="string"||typeof l=="number"?this.setAttribute(hyphenate(e),l+""):l||this.removeAttribute(hyphenate(e))))}_update(){render$1(this._createVNode(),this._root)}_createVNode(){const e={};this.shadowRoot||(e.onVnodeMounted=e.onVnodeUpdated=this._renderSlots.bind(this));const l=createVNode(this._def,extend$1(e,this._props));return this._instance||(l.ce=n=>{this._instance=n,n.ce=this,n.isCE=!0;const u=(c,y)=>{this.dispatchEvent(new CustomEvent(c,isPlainObject$3(y[0])?extend$1({detail:y},y[0]):{detail:y}))};n.emit=(c,...y)=>{u(c,y),hyphenate(c)!==c&&u(hyphenate(c),y)},this._setParent()}),l}_applyStyles(e,l){if(!e)return;if(l){if(l===this._def||this._styleChildren.has(l))return;this._styleChildren.add(l)}const n=this._nonce;for(let u=e.length-1;u>=0;u--){const c=document.createElement("style");n&&c.setAttribute("nonce",n),c.textContent=e[u],this.shadowRoot.prepend(c)}}_parseSlots(){const e=this._slots={};let l;for(;l=this.firstChild;){const n=l.nodeType===1&&l.getAttribute("slot")||"default";(e[n]||(e[n]=[])).push(l),this.removeChild(l)}}_renderSlots(){const e=(this._teleportTarget||this).querySelectorAll("slot"),l=this._instance.type.__scopeId;for(let n=0;n<e.length;n++){const u=e[n],c=u.getAttribute("name")||"default",y=this._slots[c],b=u.parentNode;if(y)for(const m of y){if(l&&m.nodeType===1){const O=l+"-s",N=document.createTreeWalker(m,1);m.setAttribute(O,"");let L;for(;L=N.nextNode();)L.setAttribute(O,"")}b.insertBefore(m,u)}else for(;u.firstChild;)b.insertBefore(u.firstChild,u);b.removeChild(u)}}_injectChildStyle(e){this._applyStyles(e.styles,e)}_removeChildStyle(e){}}function useHost(t){const e=getCurrentInstance$1(),l=e&&e.ce;return l||null}function useShadowRoot(){const t=useHost();return t&&t.shadowRoot}function useCssModule(t="$style"){{const e=getCurrentInstance$1();if(!e)return EMPTY_OBJ;const l=e.type.__cssModules;if(!l)return EMPTY_OBJ;const n=l[t];return n||EMPTY_OBJ}}const positionMap=new WeakMap,newPositionMap=new WeakMap,moveCbKey=Symbol("_moveCb"),enterCbKey=Symbol("_enterCb"),decorate=t=>(delete t.props.mode,t),TransitionGroupImpl=decorate({name:"TransitionGroup",props:extend$1({},TransitionPropsValidators,{tag:String,moveClass:String}),setup(t,{slots:e}){const l=getCurrentInstance$1(),n=useTransitionState();let u,c;return onUpdated(()=>{if(!u.length)return;const y=t.moveClass||`${t.name||"v"}-move`;if(!hasCSSTransform(u[0].el,l.vnode.el,y))return;u.forEach(callPendingCbs),u.forEach(recordPosition);const b=u.filter(applyTranslation);forceReflow(),b.forEach(m=>{const O=m.el,N=O.style;addTransitionClass(O,y),N.transform=N.webkitTransform=N.transitionDuration="";const L=O[moveCbKey]=G=>{G&&G.target!==O||(!G||/transform$/.test(G.propertyName))&&(O.removeEventListener("transitionend",L),O[moveCbKey]=null,removeTransitionClass(O,y))};O.addEventListener("transitionend",L)})}),()=>{const y=toRaw(t),b=resolveTransitionProps(y);let m=y.tag||Fragment;if(u=[],c)for(let O=0;O<c.length;O++){const N=c[O];N.el&&N.el instanceof Element&&(u.push(N),setTransitionHooks(N,resolveTransitionHooks(N,b,n,l)),positionMap.set(N,N.el.getBoundingClientRect()))}c=e.default?getTransitionRawChildren(e.default()):[];for(let O=0;O<c.length;O++){const N=c[O];N.key!=null&&setTransitionHooks(N,resolveTransitionHooks(N,b,n,l))}return createVNode(m,null,c)}}}),TransitionGroup=TransitionGroupImpl;function callPendingCbs(t){const e=t.el;e[moveCbKey]&&e[moveCbKey](),e[enterCbKey]&&e[enterCbKey]()}function recordPosition(t){newPositionMap.set(t,t.el.getBoundingClientRect())}function applyTranslation(t){const e=positionMap.get(t),l=newPositionMap.get(t),n=e.left-l.left,u=e.top-l.top;if(n||u){const c=t.el.style;return c.transform=c.webkitTransform=`translate(${n}px,${u}px)`,c.transitionDuration="0s",t}}function hasCSSTransform(t,e,l){const n=t.cloneNode(),u=t[vtcKey];u&&u.forEach(b=>{b.split(/\s+/).forEach(m=>m&&n.classList.remove(m))}),l.split(/\s+/).forEach(b=>b&&n.classList.add(b)),n.style.display="none";const c=e.nodeType===1?e:e.parentNode;c.appendChild(n);const{hasTransform:y}=getTransitionInfo(n);return c.removeChild(n),y}const getModelAssigner=t=>{const e=t.props["onUpdate:modelValue"]||!1;return isArray$3(e)?l=>invokeArrayFns(e,l):e};function onCompositionStart(t){t.target.composing=!0}function onCompositionEnd(t){const e=t.target;e.composing&&(e.composing=!1,e.dispatchEvent(new Event("input")))}const assignKey=Symbol("_assign"),vModelText={created(t,{modifiers:{lazy:e,trim:l,number:n}},u){t[assignKey]=getModelAssigner(u);const c=n||u.props&&u.props.type==="number";addEventListener(t,e?"change":"input",y=>{if(y.target.composing)return;let b=t.value;l&&(b=b.trim()),c&&(b=looseToNumber(b)),t[assignKey](b)}),l&&addEventListener(t,"change",()=>{t.value=t.value.trim()}),e||(addEventListener(t,"compositionstart",onCompositionStart),addEventListener(t,"compositionend",onCompositionEnd),addEventListener(t,"change",onCompositionEnd))},mounted(t,{value:e}){t.value=e??""},beforeUpdate(t,{value:e,oldValue:l,modifiers:{lazy:n,trim:u,number:c}},y){if(t[assignKey]=getModelAssigner(y),t.composing)return;const b=(c||t.type==="number")&&!/^0\d/.test(t.value)?looseToNumber(t.value):t.value,m=e??"";b!==m&&(document.activeElement===t&&t.type!=="range"&&(n&&e===l||u&&t.value.trim()===m)||(t.value=m))}},vModelCheckbox={deep:!0,created(t,e,l){t[assignKey]=getModelAssigner(l),addEventListener(t,"change",()=>{const n=t._modelValue,u=getValue(t),c=t.checked,y=t[assignKey];if(isArray$3(n)){const b=looseIndexOf(n,u),m=b!==-1;if(c&&!m)y(n.concat(u));else if(!c&&m){const O=[...n];O.splice(b,1),y(O)}}else if(isSet(n)){const b=new Set(n);c?b.add(u):b.delete(u),y(b)}else y(getCheckboxValue(t,c))})},mounted:setChecked,beforeUpdate(t,e,l){t[assignKey]=getModelAssigner(l),setChecked(t,e,l)}};function setChecked(t,{value:e,oldValue:l},n){t._modelValue=e;let u;isArray$3(e)?u=looseIndexOf(e,n.props.value)>-1:isSet(e)?u=e.has(n.props.value):u=looseEqual(e,getCheckboxValue(t,!0)),t.checked!==u&&(t.checked=u)}const vModelRadio={created(t,{value:e},l){t.checked=looseEqual(e,l.props.value),t[assignKey]=getModelAssigner(l),addEventListener(t,"change",()=>{t[assignKey](getValue(t))})},beforeUpdate(t,{value:e,oldValue:l},n){t[assignKey]=getModelAssigner(n),e!==l&&(t.checked=looseEqual(e,n.props.value))}},vModelSelect={deep:!0,created(t,{value:e,modifiers:{number:l}},n){const u=isSet(e);addEventListener(t,"change",()=>{const c=Array.prototype.filter.call(t.options,y=>y.selected).map(y=>l?looseToNumber(getValue(y)):getValue(y));t[assignKey](t.multiple?u?new Set(c):c:c[0]),t._assigning=!0,nextTick(()=>{t._assigning=!1})}),t[assignKey]=getModelAssigner(n)},mounted(t,{value:e,modifiers:{number:l}}){setSelected(t,e)},beforeUpdate(t,e,l){t[assignKey]=getModelAssigner(l)},updated(t,{value:e,modifiers:{number:l}}){t._assigning||setSelected(t,e)}};function setSelected(t,e,l){const n=t.multiple,u=isArray$3(e);if(!(n&&!u&&!isSet(e))){for(let c=0,y=t.options.length;c<y;c++){const b=t.options[c],m=getValue(b);if(n)if(u){const O=typeof m;O==="string"||O==="number"?b.selected=e.some(N=>String(N)===String(m)):b.selected=looseIndexOf(e,m)>-1}else b.selected=e.has(m);else if(looseEqual(getValue(b),e)){t.selectedIndex!==c&&(t.selectedIndex=c);return}}!n&&t.selectedIndex!==-1&&(t.selectedIndex=-1)}}function getValue(t){return"_value"in t?t._value:t.value}function getCheckboxValue(t,e){const l=e?"_trueValue":"_falseValue";return l in t?t[l]:e}const vModelDynamic={created(t,e,l){callModelHook(t,e,l,null,"created")},mounted(t,e,l){callModelHook(t,e,l,null,"mounted")},beforeUpdate(t,e,l,n){callModelHook(t,e,l,n,"beforeUpdate")},updated(t,e,l,n){callModelHook(t,e,l,n,"updated")}};function resolveDynamicModel(t,e){switch(t){case"SELECT":return vModelSelect;case"TEXTAREA":return vModelText;default:switch(e){case"checkbox":return vModelCheckbox;case"radio":return vModelRadio;default:return vModelText}}}function callModelHook(t,e,l,n,u){const y=resolveDynamicModel(t.tagName,l.props&&l.props.type)[u];y&&y(t,e,l,n)}function initVModelForSSR(){vModelText.getSSRProps=({value:t})=>({value:t}),vModelRadio.getSSRProps=({value:t},e)=>{if(e.props&&looseEqual(e.props.value,t))return{checked:!0}},vModelCheckbox.getSSRProps=({value:t},e)=>{if(isArray$3(t)){if(e.props&&looseIndexOf(t,e.props.value)>-1)return{checked:!0}}else if(isSet(t)){if(e.props&&t.has(e.props.value))return{checked:!0}}else if(t)return{checked:!0}},vModelDynamic.getSSRProps=(t,e)=>{if(typeof e.type!="string")return;const l=resolveDynamicModel(e.type.toUpperCase(),e.props&&e.props.type);if(l.getSSRProps)return l.getSSRProps(t,e)}}const systemModifiers=["ctrl","shift","alt","meta"],modifierGuards={stop:t=>t.stopPropagation(),prevent:t=>t.preventDefault(),self:t=>t.target!==t.currentTarget,ctrl:t=>!t.ctrlKey,shift:t=>!t.shiftKey,alt:t=>!t.altKey,meta:t=>!t.metaKey,left:t=>"button"in t&&t.button!==0,middle:t=>"button"in t&&t.button!==1,right:t=>"button"in t&&t.button!==2,exact:(t,e)=>systemModifiers.some(l=>t[`${l}Key`]&&!e.includes(l))},withModifiers=(t,e)=>{const l=t._withMods||(t._withMods={}),n=e.join(".");return l[n]||(l[n]=(u,...c)=>{for(let y=0;y<e.length;y++){const b=modifierGuards[e[y]];if(b&&b(u,e))return}return t(u,...c)})},keyNames={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},withKeys=(t,e)=>{const l=t._withKeys||(t._withKeys={}),n=e.join(".");return l[n]||(l[n]=u=>{if(!("key"in u))return;const c=hyphenate(u.key);if(e.some(y=>y===c||keyNames[y]===c))return t(u)})},rendererOptions=extend$1({patchProp},nodeOps);let renderer,enabledHydration=!1;function ensureRenderer(){return renderer||(renderer=createRenderer(rendererOptions))}function ensureHydrationRenderer(){return renderer=enabledHydration?renderer:createHydrationRenderer(rendererOptions),enabledHydration=!0,renderer}const render$1=(...t)=>{ensureRenderer().render(...t)},hydrate=(...t)=>{ensureHydrationRenderer().hydrate(...t)},createApp=(...t)=>{const e=ensureRenderer().createApp(...t),{mount:l}=e;return e.mount=n=>{const u=normalizeContainer(n);if(!u)return;const c=e._component;!isFunction$2(c)&&!c.render&&!c.template&&(c.template=u.innerHTML),u.nodeType===1&&(u.textContent="");const y=l(u,!1,resolveRootNamespace(u));return u instanceof Element&&(u.removeAttribute("v-cloak"),u.setAttribute("data-v-app","")),y},e},createSSRApp=(...t)=>{const e=ensureHydrationRenderer().createApp(...t),{mount:l}=e;return e.mount=n=>{const u=normalizeContainer(n);if(u)return l(u,!0,resolveRootNamespace(u))},e};function resolveRootNamespace(t){if(t instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&t instanceof MathMLElement)return"mathml"}function normalizeContainer(t){return isString$2(t)?document.querySelector(t):t}let ssrDirectiveInitialized=!1;const initDirectivesForSSR=()=>{ssrDirectiveInitialized||(ssrDirectiveInitialized=!0,initVModelForSSR(),initVShowForSSR())};var commonjsGlobal$1=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function getDefaultExportFromCjs(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function commonjsRequire(t){throw new Error('Could not dynamically require "'+t+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}let PubSub$1=class{constructor(){this.events={}}on(e,l){let n=this;n.events.hasOwnProperty(e)||(n.events[e]=[]),n.events[e].push(l)}emit(e,...l){this.events.hasOwnProperty(e)&&this.events[e].map(n=>n(...l))}off(e,l){if(this.events[e])if(l===void 0)this.events[e]=[];else{const n=this.events[e].indexOf(l);this.events[e].splice(n,1)}}};class Store{constructor(e){let l=this;l.actions={},l.mutations={},l.state=e.state,l.status="resting",l.events=new PubSub$1,e.hasOwnProperty("actions")&&(l.actions=e.actions),e.hasOwnProperty("mutations")&&(l.mutations=e.mutations)}dispatch(e,l){let n=this;return typeof n.actions[e]=="function"&&(console.groupCollapsed(`ACTION: ${e}`),n.status="action",n.actions[e](n,l),console.groupEnd(),!0)}commit(e,l){let n=this;if(typeof n.mutations[e]!="function")return console.log(`Mutation "${e}" doesn't exist`),!1;n.status="mutation";let u=n.mutations[e](n.state,l);return n.state=Object.assign(n.state,u),!0}}const options={state:{MxFun:null,Mxassembly:null,isCreateDrawObj:!1},actions:{},mutations:{}};for(let t in options.state){const e=t.charAt(0).toUpperCase()+t.slice(1);options.mutations["set"+e]=(l,n)=>{l[t]=n}}const store=new Store(options);function mxfun(){(function t(e,l,n){function u(b,m){if(!l[b]){if(!e[b]){var O=typeof commonjsRequire=="function"&&commonjsRequire;if(!m&&O)return O(b,!0);if(c)return c(b,!0);var N=new Error("Cannot find module '"+b+"'");throw N.code="MODULE_NOT_FOUND",N}var L=l[b]={exports:{}};e[b][0].call(L.exports,function(G){return u(e[b][1][G]||G)},L,L.exports,t,e,l,n)}return l[b].exports}for(var c=typeof commonjsRequire=="function"&&commonjsRequire,y=0;y<n.length;y++)u(n[y]);return u})({1:[function(t,e,l){var n={};(0,t("./lib/utils/common").assign)(n,t("./lib/deflate"),t("./lib/inflate"),t("./lib/zlib/constants")),e.exports=n},{"./lib/deflate":2,"./lib/inflate":3,"./lib/utils/common":4,"./lib/zlib/constants":7}],2:[function(t,e,l){var n=t("./zlib/deflate"),u=t("./utils/common"),c=t("./utils/strings"),y=t("./zlib/messages"),b=t("./zlib/zstream"),m=Object.prototype.toString,O=0,N=-1,L=0,G=8;function q(fe){if(!(this instanceof q))return new q(fe);this.options=u.assign({level:N,method:G,chunkSize:16384,windowBits:15,memLevel:8,strategy:L,to:""},fe||{});var ve=this.options;ve.raw&&0<ve.windowBits?ve.windowBits=-ve.windowBits:ve.gzip&&0<ve.windowBits&&ve.windowBits<16&&(ve.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new b,this.strm.avail_out=0;var ne=n.deflateInit2(this.strm,ve.level,ve.method,ve.windowBits,ve.memLevel,ve.strategy);if(ne!==O)throw new Error(y[ne]);if(ve.header&&n.deflateSetHeader(this.strm,ve.header),ve.dictionary){var Ue;if(Ue=typeof ve.dictionary=="string"?c.string2buf(ve.dictionary):m.call(ve.dictionary)==="[object ArrayBuffer]"?new Uint8Array(ve.dictionary):ve.dictionary,(ne=n.deflateSetDictionary(this.strm,Ue))!==O)throw new Error(y[ne]);this._dict_set=!0}}function J(fe,ve){var ne=new q(ve);if(ne.push(fe,!0),ne.err)throw ne.msg||y[ne.err];return ne.result}q.prototype.push=function(fe,ve){var ne,Ue,De=this.strm,Ve=this.options.chunkSize;if(this.ended)return!1;Ue=ve===~~ve?ve:ve===!0?4:0,typeof fe=="string"?De.input=c.string2buf(fe):m.call(fe)==="[object ArrayBuffer]"?De.input=new Uint8Array(fe):De.input=fe,De.next_in=0,De.avail_in=De.input.length;do{if(De.avail_out===0&&(De.output=new u.Buf8(Ve),De.next_out=0,De.avail_out=Ve),(ne=n.deflate(De,Ue))!==1&&ne!==O)return this.onEnd(ne),!(this.ended=!0);De.avail_out!==0&&(De.avail_in!==0||Ue!==4&&Ue!==2)||(this.options.to==="string"?this.onData(c.buf2binstring(u.shrinkBuf(De.output,De.next_out))):this.onData(u.shrinkBuf(De.output,De.next_out)))}while((0<De.avail_in||De.avail_out===0)&&ne!==1);return Ue===4?(ne=n.deflateEnd(this.strm),this.onEnd(ne),this.ended=!0,ne===O):Ue!==2||(this.onEnd(O),!(De.avail_out=0))},q.prototype.onData=function(fe){this.chunks.push(fe)},q.prototype.onEnd=function(fe){fe===O&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=u.flattenChunks(this.chunks)),this.chunks=[],this.err=fe,this.msg=this.strm.msg},l.Deflate=q,l.deflate=J,l.deflateRaw=function(fe,ve){return(ve=ve||{}).raw=!0,J(fe,ve)},l.gzip=function(fe,ve){return(ve=ve||{}).gzip=!0,J(fe,ve)}},{"./utils/common":4,"./utils/strings":5,"./zlib/deflate":9,"./zlib/messages":14,"./zlib/zstream":16}],3:[function(t,e,l){var n=t("./zlib/inflate"),u=t("./utils/common"),c=t("./utils/strings"),y=t("./zlib/constants"),b=t("./zlib/messages"),m=t("./zlib/zstream"),O=t("./zlib/gzheader"),N=Object.prototype.toString;function L(q){if(!(this instanceof L))return new L(q);this.options=u.assign({chunkSize:16384,windowBits:0,to:""},q||{});var J=this.options;J.raw&&0<=J.windowBits&&J.windowBits<16&&(J.windowBits=-J.windowBits,J.windowBits===0&&(J.windowBits=-15)),!(0<=J.windowBits&&J.windowBits<16)||q&&q.windowBits||(J.windowBits+=32),15<J.windowBits&&J.windowBits<48&&!(15&J.windowBits)&&(J.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new m,this.strm.avail_out=0;var fe=n.inflateInit2(this.strm,J.windowBits);if(fe!==y.Z_OK)throw new Error(b[fe]);if(this.header=new O,n.inflateGetHeader(this.strm,this.header),J.dictionary&&(typeof J.dictionary=="string"?J.dictionary=c.string2buf(J.dictionary):N.call(J.dictionary)==="[object ArrayBuffer]"&&(J.dictionary=new Uint8Array(J.dictionary)),J.raw&&(fe=n.inflateSetDictionary(this.strm,J.dictionary))!==y.Z_OK))throw new Error(b[fe])}function G(q,J){var fe=new L(J);if(fe.push(q,!0),fe.err)throw fe.msg||b[fe.err];return fe.result}L.prototype.push=function(q,J){var fe,ve,ne,Ue,De,Ve=this.strm,rt=this.options.chunkSize,Ae=this.options.dictionary,Te=!1;if(this.ended)return!1;ve=J===~~J?J:J===!0?y.Z_FINISH:y.Z_NO_FLUSH,typeof q=="string"?Ve.input=c.binstring2buf(q):N.call(q)==="[object ArrayBuffer]"?Ve.input=new Uint8Array(q):Ve.input=q,Ve.next_in=0,Ve.avail_in=Ve.input.length;do{if(Ve.avail_out===0&&(Ve.output=new u.Buf8(rt),Ve.next_out=0,Ve.avail_out=rt),(fe=n.inflate(Ve,y.Z_NO_FLUSH))===y.Z_NEED_DICT&&Ae&&(fe=n.inflateSetDictionary(this.strm,Ae)),fe===y.Z_BUF_ERROR&&Te===!0&&(fe=y.Z_OK,Te=!1),fe!==y.Z_STREAM_END&&fe!==y.Z_OK)return this.onEnd(fe),!(this.ended=!0);Ve.next_out&&(Ve.avail_out!==0&&fe!==y.Z_STREAM_END&&(Ve.avail_in!==0||ve!==y.Z_FINISH&&ve!==y.Z_SYNC_FLUSH)||(this.options.to==="string"?(ne=c.utf8border(Ve.output,Ve.next_out),Ue=Ve.next_out-ne,De=c.buf2string(Ve.output,ne),Ve.next_out=Ue,Ve.avail_out=rt-Ue,Ue&&u.arraySet(Ve.output,Ve.output,ne,Ue,0),this.onData(De)):this.onData(u.shrinkBuf(Ve.output,Ve.next_out)))),Ve.avail_in===0&&Ve.avail_out===0&&(Te=!0)}while((0<Ve.avail_in||Ve.avail_out===0)&&fe!==y.Z_STREAM_END);return fe===y.Z_STREAM_END&&(ve=y.Z_FINISH),ve===y.Z_FINISH?(fe=n.inflateEnd(this.strm),this.onEnd(fe),this.ended=!0,fe===y.Z_OK):ve!==y.Z_SYNC_FLUSH||(this.onEnd(y.Z_OK),!(Ve.avail_out=0))},L.prototype.onData=function(q){this.chunks.push(q)},L.prototype.onEnd=function(q){q===y.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=u.flattenChunks(this.chunks)),this.chunks=[],this.err=q,this.msg=this.strm.msg},l.Inflate=L,l.inflate=G,l.inflateRaw=function(q,J){return(J=J||{}).raw=!0,G(q,J)},l.ungzip=G},{"./utils/common":4,"./utils/strings":5,"./zlib/constants":7,"./zlib/gzheader":10,"./zlib/inflate":12,"./zlib/messages":14,"./zlib/zstream":16}],4:[function(t,e,l){var n=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";l.assign=function(y){for(var b,m,O=Array.prototype.slice.call(arguments,1);O.length;){var N=O.shift();if(N){if(typeof N!="object")throw new TypeError(N+"must be non-object");for(var L in N)b=N,m=L,Object.prototype.hasOwnProperty.call(b,m)&&(y[L]=N[L])}}return y},l.shrinkBuf=function(y,b){return y.length===b?y:y.subarray?y.subarray(0,b):(y.length=b,y)};var u={arraySet:function(y,b,m,O,N){if(b.subarray&&y.subarray)y.set(b.subarray(m,m+O),N);else for(var L=0;L<O;L++)y[N+L]=b[m+L]},flattenChunks:function(y){var b,m,O,N,L,G;for(b=O=0,m=y.length;b<m;b++)O+=y[b].length;for(G=new Uint8Array(O),b=N=0,m=y.length;b<m;b++)L=y[b],G.set(L,N),N+=L.length;return G}},c={arraySet:function(y,b,m,O,N){for(var L=0;L<O;L++)y[N+L]=b[m+L]},flattenChunks:function(y){return[].concat.apply([],y)}};l.setTyped=function(y){y?(l.Buf8=Uint8Array,l.Buf16=Uint16Array,l.Buf32=Int32Array,l.assign(l,u)):(l.Buf8=Array,l.Buf16=Array,l.Buf32=Array,l.assign(l,c))},l.setTyped(n)},{}],5:[function(t,e,l){var n=t("./common"),u=!0,c=!0;try{String.fromCharCode.apply(null,[0])}catch{u=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{c=!1}for(var y=new n.Buf8(256),b=0;b<256;b++)y[b]=252<=b?6:248<=b?5:240<=b?4:224<=b?3:192<=b?2:1;function m(O,N){if(N<65534&&(O.subarray&&c||!O.subarray&&u))return String.fromCharCode.apply(null,n.shrinkBuf(O,N));for(var L="",G=0;G<N;G++)L+=String.fromCharCode(O[G]);return L}y[254]=y[254]=1,l.string2buf=function(O){var N,L,G,q,J,fe=O.length,ve=0;for(q=0;q<fe;q++)(64512&(L=O.charCodeAt(q)))==55296&&q+1<fe&&(64512&(G=O.charCodeAt(q+1)))==56320&&(L=65536+(L-55296<<10)+(G-56320),q++),ve+=L<128?1:L<2048?2:L<65536?3:4;for(N=new n.Buf8(ve),q=J=0;J<ve;q++)(64512&(L=O.charCodeAt(q)))==55296&&q+1<fe&&(64512&(G=O.charCodeAt(q+1)))==56320&&(L=65536+(L-55296<<10)+(G-56320),q++),L<128?N[J++]=L:(L<2048?N[J++]=192|L>>>6:(L<65536?N[J++]=224|L>>>12:(N[J++]=240|L>>>18,N[J++]=128|L>>>12&63),N[J++]=128|L>>>6&63),N[J++]=128|63&L);return N},l.buf2binstring=function(O){return m(O,O.length)},l.binstring2buf=function(O){for(var N=new n.Buf8(O.length),L=0,G=N.length;L<G;L++)N[L]=O.charCodeAt(L);return N},l.buf2string=function(O,N){var L,G,q,J,fe=N||O.length,ve=new Array(2*fe);for(L=G=0;L<fe;)if((q=O[L++])<128)ve[G++]=q;else if(4<(J=y[q]))ve[G++]=65533,L+=J-1;else{for(q&=J===2?31:J===3?15:7;1<J&&L<fe;)q=q<<6|63&O[L++],J--;1<J?ve[G++]=65533:q<65536?ve[G++]=q:(q-=65536,ve[G++]=55296|q>>10&1023,ve[G++]=56320|1023&q)}return m(ve,G)},l.utf8border=function(O,N){var L;for((N=N||O.length)>O.length&&(N=O.length),L=N-1;0<=L&&(192&O[L])==128;)L--;return!(L<0)&&L!==0&&L+y[O[L]]>N?L:N}},{"./common":4}],6:[function(t,e,l){e.exports=function(n,u,c,y){for(var b=65535&n|0,m=n>>>16&65535|0,O=0;c!==0;){for(c-=O=2e3<c?2e3:c;m=m+(b=b+u[y++]|0)|0,--O;);b%=65521,m%=65521}return b|m<<16|0}},{}],7:[function(t,e,l){e.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],8:[function(t,e,l){var n=function(){for(var u,c=[],y=0;y<256;y++){u=y;for(var b=0;b<8;b++)u=1&u?3988292384^u>>>1:u>>>1;c[y]=u}return c}();e.exports=function(u,c,y,b){var m=n,O=b+y;u^=-1;for(var N=b;N<O;N++)u=u>>>8^m[255&(u^c[N])];return-1^u}},{}],9:[function(t,e,l){var n,u=t("../utils/common"),c=t("./trees"),y=t("./adler32"),b=t("./crc32"),m=t("./messages"),O=0,N=0,L=-2,G=2,q=8,J=286,fe=30,ve=19,ne=2*J+1,Ue=15,De=3,Ve=258,rt=Ve+De+1,Ae=42,Te=113;function Xe(Lt,wn){return Lt.msg=m[wn],wn}function ie(Lt){return(Lt<<1)-(4<Lt?9:0)}function ue(Lt){for(var wn=Lt.length;0<=--wn;)Lt[wn]=0}function pt(Lt){var wn=Lt.state,hn=wn.pending;hn>Lt.avail_out&&(hn=Lt.avail_out),hn!==0&&(u.arraySet(Lt.output,wn.pending_buf,wn.pending_out,hn,Lt.next_out),Lt.next_out+=hn,wn.pending_out+=hn,Lt.total_out+=hn,Lt.avail_out-=hn,wn.pending-=hn,wn.pending===0&&(wn.pending_out=0))}function mt(Lt,wn){c._tr_flush_block(Lt,0<=Lt.block_start?Lt.block_start:-1,Lt.strstart-Lt.block_start,wn),Lt.block_start=Lt.strstart,pt(Lt.strm)}function Tt(Lt,wn){Lt.pending_buf[Lt.pending++]=wn}function kt(Lt,wn){Lt.pending_buf[Lt.pending++]=wn>>>8&255,Lt.pending_buf[Lt.pending++]=255&wn}function It(Lt,wn){var hn,xn,$n=Lt.max_chain_length,Xr=Lt.strstart,ti=Lt.prev_length,gn=Lt.nice_match,Xn=Lt.strstart>Lt.w_size-rt?Lt.strstart-(Lt.w_size-rt):0,Kn=Lt.window,Vn=Lt.w_mask,Yn=Lt.prev,Vr=Lt.strstart+Ve,xi=Kn[Xr+ti-1],Si=Kn[Xr+ti];Lt.prev_length>=Lt.good_match&&($n>>=2),gn>Lt.lookahead&&(gn=Lt.lookahead);do if(Kn[(hn=wn)+ti]===Si&&Kn[hn+ti-1]===xi&&Kn[hn]===Kn[Xr]&&Kn[++hn]===Kn[Xr+1]){Xr+=2,hn++;do;while(Kn[++Xr]===Kn[++hn]&&Kn[++Xr]===Kn[++hn]&&Kn[++Xr]===Kn[++hn]&&Kn[++Xr]===Kn[++hn]&&Kn[++Xr]===Kn[++hn]&&Kn[++Xr]===Kn[++hn]&&Kn[++Xr]===Kn[++hn]&&Kn[++Xr]===Kn[++hn]&&Xr<Vr);if(xn=Ve-(Vr-Xr),Xr=Vr-Ve,ti<xn){if(Lt.match_start=wn,gn<=(ti=xn))break;xi=Kn[Xr+ti-1],Si=Kn[Xr+ti]}}while((wn=Yn[wn&Vn])>Xn&&--$n!=0);return ti<=Lt.lookahead?ti:Lt.lookahead}function nn(Lt){var wn,hn,xn,$n,Xr,ti,gn,Xn,Kn,Vn,Yn=Lt.w_size;do{if($n=Lt.window_size-Lt.lookahead-Lt.strstart,Lt.strstart>=Yn+(Yn-rt)){for(u.arraySet(Lt.window,Lt.window,Yn,Yn,0),Lt.match_start-=Yn,Lt.strstart-=Yn,Lt.block_start-=Yn,wn=hn=Lt.hash_size;xn=Lt.head[--wn],Lt.head[wn]=Yn<=xn?xn-Yn:0,--hn;);for(wn=hn=Yn;xn=Lt.prev[--wn],Lt.prev[wn]=Yn<=xn?xn-Yn:0,--hn;);$n+=Yn}if(Lt.strm.avail_in===0)break;if(ti=Lt.strm,gn=Lt.window,Xn=Lt.strstart+Lt.lookahead,Vn=void 0,(Kn=$n)<(Vn=ti.avail_in)&&(Vn=Kn),hn=Vn===0?0:(ti.avail_in-=Vn,u.arraySet(gn,ti.input,ti.next_in,Vn,Xn),ti.state.wrap===1?ti.adler=y(ti.adler,gn,Vn,Xn):ti.state.wrap===2&&(ti.adler=b(ti.adler,gn,Vn,Xn)),ti.next_in+=Vn,ti.total_in+=Vn,Vn),Lt.lookahead+=hn,Lt.lookahead+Lt.insert>=De)for(Xr=Lt.strstart-Lt.insert,Lt.ins_h=Lt.window[Xr],Lt.ins_h=(Lt.ins_h<<Lt.hash_shift^Lt.window[Xr+1])&Lt.hash_mask;Lt.insert&&(Lt.ins_h=(Lt.ins_h<<Lt.hash_shift^Lt.window[Xr+De-1])&Lt.hash_mask,Lt.prev[Xr&Lt.w_mask]=Lt.head[Lt.ins_h],Lt.head[Lt.ins_h]=Xr,Xr++,Lt.insert--,!(Lt.lookahead+Lt.insert<De)););}while(Lt.lookahead<rt&&Lt.strm.avail_in!==0)}function tn(Lt,wn){for(var hn,xn;;){if(Lt.lookahead<rt){if(nn(Lt),Lt.lookahead<rt&&wn===O)return 1;if(Lt.lookahead===0)break}if(hn=0,Lt.lookahead>=De&&(Lt.ins_h=(Lt.ins_h<<Lt.hash_shift^Lt.window[Lt.strstart+De-1])&Lt.hash_mask,hn=Lt.prev[Lt.strstart&Lt.w_mask]=Lt.head[Lt.ins_h],Lt.head[Lt.ins_h]=Lt.strstart),hn!==0&&Lt.strstart-hn<=Lt.w_size-rt&&(Lt.match_length=It(Lt,hn)),Lt.match_length>=De)if(xn=c._tr_tally(Lt,Lt.strstart-Lt.match_start,Lt.match_length-De),Lt.lookahead-=Lt.match_length,Lt.match_length<=Lt.max_lazy_match&&Lt.lookahead>=De){for(Lt.match_length--;Lt.strstart++,Lt.ins_h=(Lt.ins_h<<Lt.hash_shift^Lt.window[Lt.strstart+De-1])&Lt.hash_mask,hn=Lt.prev[Lt.strstart&Lt.w_mask]=Lt.head[Lt.ins_h],Lt.head[Lt.ins_h]=Lt.strstart,--Lt.match_length!=0;);Lt.strstart++}else Lt.strstart+=Lt.match_length,Lt.match_length=0,Lt.ins_h=Lt.window[Lt.strstart],Lt.ins_h=(Lt.ins_h<<Lt.hash_shift^Lt.window[Lt.strstart+1])&Lt.hash_mask;else xn=c._tr_tally(Lt,0,Lt.window[Lt.strstart]),Lt.lookahead--,Lt.strstart++;if(xn&&(mt(Lt,!1),Lt.strm.avail_out===0))return 1}return Lt.insert=Lt.strstart<De-1?Lt.strstart:De-1,wn===4?(mt(Lt,!0),Lt.strm.avail_out===0?3:4):Lt.last_lit&&(mt(Lt,!1),Lt.strm.avail_out===0)?1:2}function pn(Lt,wn){for(var hn,xn,$n;;){if(Lt.lookahead<rt){if(nn(Lt),Lt.lookahead<rt&&wn===O)return 1;if(Lt.lookahead===0)break}if(hn=0,Lt.lookahead>=De&&(Lt.ins_h=(Lt.ins_h<<Lt.hash_shift^Lt.window[Lt.strstart+De-1])&Lt.hash_mask,hn=Lt.prev[Lt.strstart&Lt.w_mask]=Lt.head[Lt.ins_h],Lt.head[Lt.ins_h]=Lt.strstart),Lt.prev_length=Lt.match_length,Lt.prev_match=Lt.match_start,Lt.match_length=De-1,hn!==0&&Lt.prev_length<Lt.max_lazy_match&&Lt.strstart-hn<=Lt.w_size-rt&&(Lt.match_length=It(Lt,hn),Lt.match_length<=5&&(Lt.strategy===1||Lt.match_length===De&&4096<Lt.strstart-Lt.match_start)&&(Lt.match_length=De-1)),Lt.prev_length>=De&&Lt.match_length<=Lt.prev_length){for($n=Lt.strstart+Lt.lookahead-De,xn=c._tr_tally(Lt,Lt.strstart-1-Lt.prev_match,Lt.prev_length-De),Lt.lookahead-=Lt.prev_length-1,Lt.prev_length-=2;++Lt.strstart<=$n&&(Lt.ins_h=(Lt.ins_h<<Lt.hash_shift^Lt.window[Lt.strstart+De-1])&Lt.hash_mask,hn=Lt.prev[Lt.strstart&Lt.w_mask]=Lt.head[Lt.ins_h],Lt.head[Lt.ins_h]=Lt.strstart),--Lt.prev_length!=0;);if(Lt.match_available=0,Lt.match_length=De-1,Lt.strstart++,xn&&(mt(Lt,!1),Lt.strm.avail_out===0))return 1}else if(Lt.match_available){if((xn=c._tr_tally(Lt,0,Lt.window[Lt.strstart-1]))&&mt(Lt,!1),Lt.strstart++,Lt.lookahead--,Lt.strm.avail_out===0)return 1}else Lt.match_available=1,Lt.strstart++,Lt.lookahead--}return Lt.match_available&&(xn=c._tr_tally(Lt,0,Lt.window[Lt.strstart-1]),Lt.match_available=0),Lt.insert=Lt.strstart<De-1?Lt.strstart:De-1,wn===4?(mt(Lt,!0),Lt.strm.avail_out===0?3:4):Lt.last_lit&&(mt(Lt,!1),Lt.strm.avail_out===0)?1:2}function _n(Lt,wn,hn,xn,$n){this.good_length=Lt,this.max_lazy=wn,this.nice_length=hn,this.max_chain=xn,this.func=$n}function Dn(Lt){var wn;return Lt&&Lt.state?(Lt.total_in=Lt.total_out=0,Lt.data_type=G,(wn=Lt.state).pending=0,wn.pending_out=0,wn.wrap<0&&(wn.wrap=-wn.wrap),wn.status=wn.wrap?Ae:Te,Lt.adler=wn.wrap===2?0:1,wn.last_flush=O,c._tr_init(wn),N):Xe(Lt,L)}function an(Lt){var wn,hn=Dn(Lt);return hn===N&&((wn=Lt.state).window_size=2*wn.w_size,ue(wn.head),wn.max_lazy_match=n[wn.level].max_lazy,wn.good_match=n[wn.level].good_length,wn.nice_match=n[wn.level].nice_length,wn.max_chain_length=n[wn.level].max_chain,wn.strstart=0,wn.block_start=0,wn.lookahead=0,wn.insert=0,wn.match_length=wn.prev_length=De-1,wn.match_available=0,wn.ins_h=0),hn}function Rn(Lt,wn,hn,xn,$n,Xr){if(!Lt)return L;var ti=1;if(wn===-1&&(wn=6),xn<0?(ti=0,xn=-xn):15<xn&&(ti=2,xn-=16),$n<1||9<$n||hn!==q||xn<8||15<xn||wn<0||9<wn||Xr<0||4<Xr)return Xe(Lt,L);xn===8&&(xn=9);var gn=new function(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=q,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new u.Buf16(2*ne),this.dyn_dtree=new u.Buf16(2*(2*fe+1)),this.bl_tree=new u.Buf16(2*(2*ve+1)),ue(this.dyn_ltree),ue(this.dyn_dtree),ue(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new u.Buf16(Ue+1),this.heap=new u.Buf16(2*J+1),ue(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new u.Buf16(2*J+1),ue(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0};return(Lt.state=gn).strm=Lt,gn.wrap=ti,gn.gzhead=null,gn.w_bits=xn,gn.w_size=1<<gn.w_bits,gn.w_mask=gn.w_size-1,gn.hash_bits=$n+7,gn.hash_size=1<<gn.hash_bits,gn.hash_mask=gn.hash_size-1,gn.hash_shift=~~((gn.hash_bits+De-1)/De),gn.window=new u.Buf8(2*gn.w_size),gn.head=new u.Buf16(gn.hash_size),gn.prev=new u.Buf16(gn.w_size),gn.lit_bufsize=1<<$n+6,gn.pending_buf_size=4*gn.lit_bufsize,gn.pending_buf=new u.Buf8(gn.pending_buf_size),gn.d_buf=+gn.lit_bufsize,gn.l_buf=3*gn.lit_bufsize,gn.level=wn,gn.strategy=Xr,gn.method=hn,an(Lt)}n=[new _n(0,0,0,0,function(Lt,wn){var hn=65535;for(hn>Lt.pending_buf_size-5&&(hn=Lt.pending_buf_size-5);;){if(Lt.lookahead<=1){if(nn(Lt),Lt.lookahead===0&&wn===O)return 1;if(Lt.lookahead===0)break}Lt.strstart+=Lt.lookahead,Lt.lookahead=0;var xn=Lt.block_start+hn;if((Lt.strstart===0||Lt.strstart>=xn)&&(Lt.lookahead=Lt.strstart-xn,Lt.strstart=xn,mt(Lt,!1),Lt.strm.avail_out===0)||Lt.strstart-Lt.block_start>=Lt.w_size-rt&&(mt(Lt,!1),Lt.strm.avail_out===0))return 1}return Lt.insert=0,wn===4?(mt(Lt,!0),Lt.strm.avail_out===0?3:4):(Lt.strstart>Lt.block_start&&(mt(Lt,!1),Lt.strm.avail_out),1)}),new _n(4,4,8,4,tn),new _n(4,5,16,8,tn),new _n(4,6,32,32,tn),new _n(4,4,16,16,pn),new _n(8,16,32,32,pn),new _n(8,16,128,128,pn),new _n(8,32,128,256,pn),new _n(32,128,258,1024,pn),new _n(32,258,258,4096,pn)],l.deflateInit=function(Lt,wn){return Rn(Lt,wn,q,15,8,0)},l.deflateInit2=Rn,l.deflateReset=an,l.deflateResetKeep=Dn,l.deflateSetHeader=function(Lt,wn){return Lt&&Lt.state&&Lt.state.wrap===2?(Lt.state.gzhead=wn,N):L},l.deflate=function(Lt,wn){var hn,xn,$n,Xr;if(!Lt||!Lt.state||5<wn||wn<0)return Lt?Xe(Lt,L):L;if(xn=Lt.state,!Lt.output||!Lt.input&&Lt.avail_in!==0||xn.status===666&&wn!==4)return Xe(Lt,Lt.avail_out===0?-5:L);if(xn.strm=Lt,hn=xn.last_flush,xn.last_flush=wn,xn.status===Ae)if(xn.wrap===2)Lt.adler=0,Tt(xn,31),Tt(xn,139),Tt(xn,8),xn.gzhead?(Tt(xn,(xn.gzhead.text?1:0)+(xn.gzhead.hcrc?2:0)+(xn.gzhead.extra?4:0)+(xn.gzhead.name?8:0)+(xn.gzhead.comment?16:0)),Tt(xn,255&xn.gzhead.time),Tt(xn,xn.gzhead.time>>8&255),Tt(xn,xn.gzhead.time>>16&255),Tt(xn,xn.gzhead.time>>24&255),Tt(xn,xn.level===9?2:2<=xn.strategy||xn.level<2?4:0),Tt(xn,255&xn.gzhead.os),xn.gzhead.extra&&xn.gzhead.extra.length&&(Tt(xn,255&xn.gzhead.extra.length),Tt(xn,xn.gzhead.extra.length>>8&255)),xn.gzhead.hcrc&&(Lt.adler=b(Lt.adler,xn.pending_buf,xn.pending,0)),xn.gzindex=0,xn.status=69):(Tt(xn,0),Tt(xn,0),Tt(xn,0),Tt(xn,0),Tt(xn,0),Tt(xn,xn.level===9?2:2<=xn.strategy||xn.level<2?4:0),Tt(xn,3),xn.status=Te);else{var ti=q+(xn.w_bits-8<<4)<<8;ti|=(2<=xn.strategy||xn.level<2?0:xn.level<6?1:xn.level===6?2:3)<<6,xn.strstart!==0&&(ti|=32),ti+=31-ti%31,xn.status=Te,kt(xn,ti),xn.strstart!==0&&(kt(xn,Lt.adler>>>16),kt(xn,65535&Lt.adler)),Lt.adler=1}if(xn.status===69)if(xn.gzhead.extra){for($n=xn.pending;xn.gzindex<(65535&xn.gzhead.extra.length)&&(xn.pending!==xn.pending_buf_size||(xn.gzhead.hcrc&&xn.pending>$n&&(Lt.adler=b(Lt.adler,xn.pending_buf,xn.pending-$n,$n)),pt(Lt),$n=xn.pending,xn.pending!==xn.pending_buf_size));)Tt(xn,255&xn.gzhead.extra[xn.gzindex]),xn.gzindex++;xn.gzhead.hcrc&&xn.pending>$n&&(Lt.adler=b(Lt.adler,xn.pending_buf,xn.pending-$n,$n)),xn.gzindex===xn.gzhead.extra.length&&(xn.gzindex=0,xn.status=73)}else xn.status=73;if(xn.status===73)if(xn.gzhead.name){$n=xn.pending;do{if(xn.pending===xn.pending_buf_size&&(xn.gzhead.hcrc&&xn.pending>$n&&(Lt.adler=b(Lt.adler,xn.pending_buf,xn.pending-$n,$n)),pt(Lt),$n=xn.pending,xn.pending===xn.pending_buf_size)){Xr=1;break}Xr=xn.gzindex<xn.gzhead.name.length?255&xn.gzhead.name.charCodeAt(xn.gzindex++):0,Tt(xn,Xr)}while(Xr!==0);xn.gzhead.hcrc&&xn.pending>$n&&(Lt.adler=b(Lt.adler,xn.pending_buf,xn.pending-$n,$n)),Xr===0&&(xn.gzindex=0,xn.status=91)}else xn.status=91;if(xn.status===91)if(xn.gzhead.comment){$n=xn.pending;do{if(xn.pending===xn.pending_buf_size&&(xn.gzhead.hcrc&&xn.pending>$n&&(Lt.adler=b(Lt.adler,xn.pending_buf,xn.pending-$n,$n)),pt(Lt),$n=xn.pending,xn.pending===xn.pending_buf_size)){Xr=1;break}Xr=xn.gzindex<xn.gzhead.comment.length?255&xn.gzhead.comment.charCodeAt(xn.gzindex++):0,Tt(xn,Xr)}while(Xr!==0);xn.gzhead.hcrc&&xn.pending>$n&&(Lt.adler=b(Lt.adler,xn.pending_buf,xn.pending-$n,$n)),Xr===0&&(xn.status=103)}else xn.status=103;if(xn.status===103&&(xn.gzhead.hcrc?(xn.pending+2>xn.pending_buf_size&&pt(Lt),xn.pending+2<=xn.pending_buf_size&&(Tt(xn,255&Lt.adler),Tt(xn,Lt.adler>>8&255),Lt.adler=0,xn.status=Te)):xn.status=Te),xn.pending!==0){if(pt(Lt),Lt.avail_out===0)return xn.last_flush=-1,N}else if(Lt.avail_in===0&&ie(wn)<=ie(hn)&&wn!==4)return Xe(Lt,-5);if(xn.status===666&&Lt.avail_in!==0)return Xe(Lt,-5);if(Lt.avail_in!==0||xn.lookahead!==0||wn!==O&&xn.status!==666){var gn=xn.strategy===2?function(Xn,Kn){for(var Vn;;){if(Xn.lookahead===0&&(nn(Xn),Xn.lookahead===0)){if(Kn===O)return 1;break}if(Xn.match_length=0,Vn=c._tr_tally(Xn,0,Xn.window[Xn.strstart]),Xn.lookahead--,Xn.strstart++,Vn&&(mt(Xn,!1),Xn.strm.avail_out===0))return 1}return Xn.insert=0,Kn===4?(mt(Xn,!0),Xn.strm.avail_out===0?3:4):Xn.last_lit&&(mt(Xn,!1),Xn.strm.avail_out===0)?1:2}(xn,wn):xn.strategy===3?function(Xn,Kn){for(var Vn,Yn,Vr,xi,Si=Xn.window;;){if(Xn.lookahead<=Ve){if(nn(Xn),Xn.lookahead<=Ve&&Kn===O)return 1;if(Xn.lookahead===0)break}if(Xn.match_length=0,Xn.lookahead>=De&&0<Xn.strstart&&(Yn=Si[Vr=Xn.strstart-1])===Si[++Vr]&&Yn===Si[++Vr]&&Yn===Si[++Vr]){xi=Xn.strstart+Ve;do;while(Yn===Si[++Vr]&&Yn===Si[++Vr]&&Yn===Si[++Vr]&&Yn===Si[++Vr]&&Yn===Si[++Vr]&&Yn===Si[++Vr]&&Yn===Si[++Vr]&&Yn===Si[++Vr]&&Vr<xi);Xn.match_length=Ve-(xi-Vr),Xn.match_length>Xn.lookahead&&(Xn.match_length=Xn.lookahead)}if(Xn.match_length>=De?(Vn=c._tr_tally(Xn,1,Xn.match_length-De),Xn.lookahead-=Xn.match_length,Xn.strstart+=Xn.match_length,Xn.match_length=0):(Vn=c._tr_tally(Xn,0,Xn.window[Xn.strstart]),Xn.lookahead--,Xn.strstart++),Vn&&(mt(Xn,!1),Xn.strm.avail_out===0))return 1}return Xn.insert=0,Kn===4?(mt(Xn,!0),Xn.strm.avail_out===0?3:4):Xn.last_lit&&(mt(Xn,!1),Xn.strm.avail_out===0)?1:2}(xn,wn):n[xn.level].func(xn,wn);if(gn!==3&&gn!==4||(xn.status=666),gn===1||gn===3)return Lt.avail_out===0&&(xn.last_flush=-1),N;if(gn===2&&(wn===1?c._tr_align(xn):wn!==5&&(c._tr_stored_block(xn,0,0,!1),wn===3&&(ue(xn.head),xn.lookahead===0&&(xn.strstart=0,xn.block_start=0,xn.insert=0))),pt(Lt),Lt.avail_out===0))return xn.last_flush=-1,N}return wn!==4?N:xn.wrap<=0?1:(xn.wrap===2?(Tt(xn,255&Lt.adler),Tt(xn,Lt.adler>>8&255),Tt(xn,Lt.adler>>16&255),Tt(xn,Lt.adler>>24&255),Tt(xn,255&Lt.total_in),Tt(xn,Lt.total_in>>8&255),Tt(xn,Lt.total_in>>16&255),Tt(xn,Lt.total_in>>24&255)):(kt(xn,Lt.adler>>>16),kt(xn,65535&Lt.adler)),pt(Lt),0<xn.wrap&&(xn.wrap=-xn.wrap),xn.pending!==0?N:1)},l.deflateEnd=function(Lt){var wn;return Lt&&Lt.state?(wn=Lt.state.status)!==Ae&&wn!==69&&wn!==73&&wn!==91&&wn!==103&&wn!==Te&&wn!==666?Xe(Lt,L):(Lt.state=null,wn===Te?Xe(Lt,-3):N):L},l.deflateSetDictionary=function(Lt,wn){var hn,xn,$n,Xr,ti,gn,Xn,Kn,Vn=wn.length;if(!Lt||!Lt.state||(Xr=(hn=Lt.state).wrap)===2||Xr===1&&hn.status!==Ae||hn.lookahead)return L;for(Xr===1&&(Lt.adler=y(Lt.adler,wn,Vn,0)),hn.wrap=0,Vn>=hn.w_size&&(Xr===0&&(ue(hn.head),hn.strstart=0,hn.block_start=0,hn.insert=0),Kn=new u.Buf8(hn.w_size),u.arraySet(Kn,wn,Vn-hn.w_size,hn.w_size,0),wn=Kn,Vn=hn.w_size),ti=Lt.avail_in,gn=Lt.next_in,Xn=Lt.input,Lt.avail_in=Vn,Lt.next_in=0,Lt.input=wn,nn(hn);hn.lookahead>=De;){for(xn=hn.strstart,$n=hn.lookahead-(De-1);hn.ins_h=(hn.ins_h<<hn.hash_shift^hn.window[xn+De-1])&hn.hash_mask,hn.prev[xn&hn.w_mask]=hn.head[hn.ins_h],hn.head[hn.ins_h]=xn,xn++,--$n;);hn.strstart=xn,hn.lookahead=De-1,nn(hn)}return hn.strstart+=hn.lookahead,hn.block_start=hn.strstart,hn.insert=hn.lookahead,hn.lookahead=0,hn.match_length=hn.prev_length=De-1,hn.match_available=0,Lt.next_in=gn,Lt.input=Xn,Lt.avail_in=ti,hn.wrap=Xr,N},l.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":4,"./adler32":6,"./crc32":8,"./messages":14,"./trees":15}],10:[function(t,e,l){e.exports=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}},{}],11:[function(t,e,l){e.exports=function(n,u){var c,y,b,m,O,N,L,G,q,J,fe,ve,ne,Ue,De,Ve,rt,Ae,Te,Xe,ie,ue,pt,mt,Tt;c=n.state,y=n.next_in,mt=n.input,b=y+(n.avail_in-5),m=n.next_out,Tt=n.output,O=m-(u-n.avail_out),N=m+(n.avail_out-257),L=c.dmax,G=c.wsize,q=c.whave,J=c.wnext,fe=c.window,ve=c.hold,ne=c.bits,Ue=c.lencode,De=c.distcode,Ve=(1<<c.lenbits)-1,rt=(1<<c.distbits)-1;e:do{ne<15&&(ve+=mt[y++]<<ne,ne+=8,ve+=mt[y++]<<ne,ne+=8),Ae=Ue[ve&Ve];t:for(;;){if(ve>>>=Te=Ae>>>24,ne-=Te,(Te=Ae>>>16&255)==0)Tt[m++]=65535&Ae;else{if(!(16&Te)){if(!(64&Te)){Ae=Ue[(65535&Ae)+(ve&(1<<Te)-1)];continue t}if(32&Te){c.mode=12;break e}n.msg="invalid literal/length code",c.mode=30;break e}Xe=65535&Ae,(Te&=15)&&(ne<Te&&(ve+=mt[y++]<<ne,ne+=8),Xe+=ve&(1<<Te)-1,ve>>>=Te,ne-=Te),ne<15&&(ve+=mt[y++]<<ne,ne+=8,ve+=mt[y++]<<ne,ne+=8),Ae=De[ve&rt];n:for(;;){if(ve>>>=Te=Ae>>>24,ne-=Te,!(16&(Te=Ae>>>16&255))){if(!(64&Te)){Ae=De[(65535&Ae)+(ve&(1<<Te)-1)];continue n}n.msg="invalid distance code",c.mode=30;break e}if(ie=65535&Ae,ne<(Te&=15)&&(ve+=mt[y++]<<ne,(ne+=8)<Te&&(ve+=mt[y++]<<ne,ne+=8)),L<(ie+=ve&(1<<Te)-1)){n.msg="invalid distance too far back",c.mode=30;break e}if(ve>>>=Te,ne-=Te,(Te=m-O)<ie){if(q<(Te=ie-Te)&&c.sane){n.msg="invalid distance too far back",c.mode=30;break e}if(pt=fe,(ue=0)===J){if(ue+=G-Te,Te<Xe){for(Xe-=Te;Tt[m++]=fe[ue++],--Te;);ue=m-ie,pt=Tt}}else if(J<Te){if(ue+=G+J-Te,(Te-=J)<Xe){for(Xe-=Te;Tt[m++]=fe[ue++],--Te;);if(ue=0,J<Xe){for(Xe-=Te=J;Tt[m++]=fe[ue++],--Te;);ue=m-ie,pt=Tt}}}else if(ue+=J-Te,Te<Xe){for(Xe-=Te;Tt[m++]=fe[ue++],--Te;);ue=m-ie,pt=Tt}for(;2<Xe;)Tt[m++]=pt[ue++],Tt[m++]=pt[ue++],Tt[m++]=pt[ue++],Xe-=3;Xe&&(Tt[m++]=pt[ue++],1<Xe&&(Tt[m++]=pt[ue++]))}else{for(ue=m-ie;Tt[m++]=Tt[ue++],Tt[m++]=Tt[ue++],Tt[m++]=Tt[ue++],2<(Xe-=3););Xe&&(Tt[m++]=Tt[ue++],1<Xe&&(Tt[m++]=Tt[ue++]))}break}}break}}while(y<b&&m<N);y-=Xe=ne>>3,ve&=(1<<(ne-=Xe<<3))-1,n.next_in=y,n.next_out=m,n.avail_in=y<b?b-y+5:5-(y-b),n.avail_out=m<N?N-m+257:257-(m-N),c.hold=ve,c.bits=ne}},{}],12:[function(t,e,l){var n=t("../utils/common"),u=t("./adler32"),c=t("./crc32"),y=t("./inffast"),b=t("./inftrees"),m=0,O=-2,N=1,L=852,G=592;function q(Xe){return(Xe>>>24&255)+(Xe>>>8&65280)+((65280&Xe)<<8)+((255&Xe)<<24)}function J(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new n.Buf16(320),this.work=new n.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function fe(Xe){var ie;return Xe&&Xe.state?(ie=Xe.state,Xe.total_in=Xe.total_out=ie.total=0,Xe.msg="",ie.wrap&&(Xe.adler=1&ie.wrap),ie.mode=N,ie.last=0,ie.havedict=0,ie.dmax=32768,ie.head=null,ie.hold=0,ie.bits=0,ie.lencode=ie.lendyn=new n.Buf32(L),ie.distcode=ie.distdyn=new n.Buf32(G),ie.sane=1,ie.back=-1,m):O}function ve(Xe){var ie;return Xe&&Xe.state?((ie=Xe.state).wsize=0,ie.whave=0,ie.wnext=0,fe(Xe)):O}function ne(Xe,ie){var ue,pt;return Xe&&Xe.state?(pt=Xe.state,ie<0?(ue=0,ie=-ie):(ue=1+(ie>>4),ie<48&&(ie&=15)),ie&&(ie<8||15<ie)?O:(pt.window!==null&&pt.wbits!==ie&&(pt.window=null),pt.wrap=ue,pt.wbits=ie,ve(Xe))):O}function Ue(Xe,ie){var ue,pt;return Xe?(pt=new J,(Xe.state=pt).window=null,(ue=ne(Xe,ie))!==m&&(Xe.state=null),ue):O}var De,Ve,rt=!0;function Ae(Xe){if(rt){var ie;for(De=new n.Buf32(512),Ve=new n.Buf32(32),ie=0;ie<144;)Xe.lens[ie++]=8;for(;ie<256;)Xe.lens[ie++]=9;for(;ie<280;)Xe.lens[ie++]=7;for(;ie<288;)Xe.lens[ie++]=8;for(b(1,Xe.lens,0,288,De,0,Xe.work,{bits:9}),ie=0;ie<32;)Xe.lens[ie++]=5;b(2,Xe.lens,0,32,Ve,0,Xe.work,{bits:5}),rt=!1}Xe.lencode=De,Xe.lenbits=9,Xe.distcode=Ve,Xe.distbits=5}function Te(Xe,ie,ue,pt){var mt,Tt=Xe.state;return Tt.window===null&&(Tt.wsize=1<<Tt.wbits,Tt.wnext=0,Tt.whave=0,Tt.window=new n.Buf8(Tt.wsize)),pt>=Tt.wsize?(n.arraySet(Tt.window,ie,ue-Tt.wsize,Tt.wsize,0),Tt.wnext=0,Tt.whave=Tt.wsize):(pt<(mt=Tt.wsize-Tt.wnext)&&(mt=pt),n.arraySet(Tt.window,ie,ue-pt,mt,Tt.wnext),(pt-=mt)?(n.arraySet(Tt.window,ie,ue-pt,pt,0),Tt.wnext=pt,Tt.whave=Tt.wsize):(Tt.wnext+=mt,Tt.wnext===Tt.wsize&&(Tt.wnext=0),Tt.whave<Tt.wsize&&(Tt.whave+=mt))),0}l.inflateReset=ve,l.inflateReset2=ne,l.inflateResetKeep=fe,l.inflateInit=function(Xe){return Ue(Xe,15)},l.inflateInit2=Ue,l.inflate=function(Xe,ie){var ue,pt,mt,Tt,kt,It,nn,tn,pn,_n,Dn,an,Rn,Lt,wn,hn,xn,$n,Xr,ti,gn,Xn,Kn,Vn,Yn=0,Vr=new n.Buf8(4),xi=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!Xe||!Xe.state||!Xe.output||!Xe.input&&Xe.avail_in!==0)return O;(ue=Xe.state).mode===12&&(ue.mode=13),kt=Xe.next_out,mt=Xe.output,nn=Xe.avail_out,Tt=Xe.next_in,pt=Xe.input,It=Xe.avail_in,tn=ue.hold,pn=ue.bits,_n=It,Dn=nn,Xn=m;e:for(;;)switch(ue.mode){case N:if(ue.wrap===0){ue.mode=13;break}for(;pn<16;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}if(2&ue.wrap&&tn===35615){Vr[ue.check=0]=255&tn,Vr[1]=tn>>>8&255,ue.check=c(ue.check,Vr,2,0),pn=tn=0,ue.mode=2;break}if(ue.flags=0,ue.head&&(ue.head.done=!1),!(1&ue.wrap)||(((255&tn)<<8)+(tn>>8))%31){Xe.msg="incorrect header check",ue.mode=30;break}if((15&tn)!=8){Xe.msg="unknown compression method",ue.mode=30;break}if(pn-=4,gn=8+(15&(tn>>>=4)),ue.wbits===0)ue.wbits=gn;else if(gn>ue.wbits){Xe.msg="invalid window size",ue.mode=30;break}ue.dmax=1<<gn,Xe.adler=ue.check=1,ue.mode=512&tn?10:12,pn=tn=0;break;case 2:for(;pn<16;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}if(ue.flags=tn,(255&ue.flags)!=8){Xe.msg="unknown compression method",ue.mode=30;break}if(57344&ue.flags){Xe.msg="unknown header flags set",ue.mode=30;break}ue.head&&(ue.head.text=tn>>8&1),512&ue.flags&&(Vr[0]=255&tn,Vr[1]=tn>>>8&255,ue.check=c(ue.check,Vr,2,0)),pn=tn=0,ue.mode=3;case 3:for(;pn<32;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}ue.head&&(ue.head.time=tn),512&ue.flags&&(Vr[0]=255&tn,Vr[1]=tn>>>8&255,Vr[2]=tn>>>16&255,Vr[3]=tn>>>24&255,ue.check=c(ue.check,Vr,4,0)),pn=tn=0,ue.mode=4;case 4:for(;pn<16;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}ue.head&&(ue.head.xflags=255&tn,ue.head.os=tn>>8),512&ue.flags&&(Vr[0]=255&tn,Vr[1]=tn>>>8&255,ue.check=c(ue.check,Vr,2,0)),pn=tn=0,ue.mode=5;case 5:if(1024&ue.flags){for(;pn<16;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}ue.length=tn,ue.head&&(ue.head.extra_len=tn),512&ue.flags&&(Vr[0]=255&tn,Vr[1]=tn>>>8&255,ue.check=c(ue.check,Vr,2,0)),pn=tn=0}else ue.head&&(ue.head.extra=null);ue.mode=6;case 6:if(1024&ue.flags&&(It<(an=ue.length)&&(an=It),an&&(ue.head&&(gn=ue.head.extra_len-ue.length,ue.head.extra||(ue.head.extra=new Array(ue.head.extra_len)),n.arraySet(ue.head.extra,pt,Tt,an,gn)),512&ue.flags&&(ue.check=c(ue.check,pt,an,Tt)),It-=an,Tt+=an,ue.length-=an),ue.length))break e;ue.length=0,ue.mode=7;case 7:if(2048&ue.flags){if(It===0)break e;for(an=0;gn=pt[Tt+an++],ue.head&&gn&&ue.length<65536&&(ue.head.name+=String.fromCharCode(gn)),gn&&an<It;);if(512&ue.flags&&(ue.check=c(ue.check,pt,an,Tt)),It-=an,Tt+=an,gn)break e}else ue.head&&(ue.head.name=null);ue.length=0,ue.mode=8;case 8:if(4096&ue.flags){if(It===0)break e;for(an=0;gn=pt[Tt+an++],ue.head&&gn&&ue.length<65536&&(ue.head.comment+=String.fromCharCode(gn)),gn&&an<It;);if(512&ue.flags&&(ue.check=c(ue.check,pt,an,Tt)),It-=an,Tt+=an,gn)break e}else ue.head&&(ue.head.comment=null);ue.mode=9;case 9:if(512&ue.flags){for(;pn<16;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}if(tn!==(65535&ue.check)){Xe.msg="header crc mismatch",ue.mode=30;break}pn=tn=0}ue.head&&(ue.head.hcrc=ue.flags>>9&1,ue.head.done=!0),Xe.adler=ue.check=0,ue.mode=12;break;case 10:for(;pn<32;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}Xe.adler=ue.check=q(tn),pn=tn=0,ue.mode=11;case 11:if(ue.havedict===0)return Xe.next_out=kt,Xe.avail_out=nn,Xe.next_in=Tt,Xe.avail_in=It,ue.hold=tn,ue.bits=pn,2;Xe.adler=ue.check=1,ue.mode=12;case 12:if(ie===5||ie===6)break e;case 13:if(ue.last){tn>>>=7&pn,pn-=7&pn,ue.mode=27;break}for(;pn<3;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}switch(ue.last=1&tn,--pn,3&(tn>>>=1)){case 0:ue.mode=14;break;case 1:if(Ae(ue),ue.mode=20,ie!==6)break;tn>>>=2,pn-=2;break e;case 2:ue.mode=17;break;case 3:Xe.msg="invalid block type",ue.mode=30}tn>>>=2,pn-=2;break;case 14:for(tn>>>=7&pn,pn-=7&pn;pn<32;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}if((65535&tn)!=(tn>>>16^65535)){Xe.msg="invalid stored block lengths",ue.mode=30;break}if(ue.length=65535&tn,pn=tn=0,ue.mode=15,ie===6)break e;case 15:ue.mode=16;case 16:if(an=ue.length){if(It<an&&(an=It),nn<an&&(an=nn),an===0)break e;n.arraySet(mt,pt,Tt,an,kt),It-=an,Tt+=an,nn-=an,kt+=an,ue.length-=an;break}ue.mode=12;break;case 17:for(;pn<14;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}if(ue.nlen=257+(31&tn),tn>>>=5,pn-=5,ue.ndist=1+(31&tn),tn>>>=5,pn-=5,ue.ncode=4+(15&tn),tn>>>=4,pn-=4,286<ue.nlen||30<ue.ndist){Xe.msg="too many length or distance symbols",ue.mode=30;break}ue.have=0,ue.mode=18;case 18:for(;ue.have<ue.ncode;){for(;pn<3;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}ue.lens[xi[ue.have++]]=7&tn,tn>>>=3,pn-=3}for(;ue.have<19;)ue.lens[xi[ue.have++]]=0;if(ue.lencode=ue.lendyn,ue.lenbits=7,Kn={bits:ue.lenbits},Xn=b(0,ue.lens,0,19,ue.lencode,0,ue.work,Kn),ue.lenbits=Kn.bits,Xn){Xe.msg="invalid code lengths set",ue.mode=30;break}ue.have=0,ue.mode=19;case 19:for(;ue.have<ue.nlen+ue.ndist;){for(;hn=(Yn=ue.lencode[tn&(1<<ue.lenbits)-1])>>>16&255,xn=65535&Yn,!((wn=Yn>>>24)<=pn);){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}if(xn<16)tn>>>=wn,pn-=wn,ue.lens[ue.have++]=xn;else{if(xn===16){for(Vn=wn+2;pn<Vn;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}if(tn>>>=wn,pn-=wn,ue.have===0){Xe.msg="invalid bit length repeat",ue.mode=30;break}gn=ue.lens[ue.have-1],an=3+(3&tn),tn>>>=2,pn-=2}else if(xn===17){for(Vn=wn+3;pn<Vn;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}pn-=wn,gn=0,an=3+(7&(tn>>>=wn)),tn>>>=3,pn-=3}else{for(Vn=wn+7;pn<Vn;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}pn-=wn,gn=0,an=11+(127&(tn>>>=wn)),tn>>>=7,pn-=7}if(ue.have+an>ue.nlen+ue.ndist){Xe.msg="invalid bit length repeat",ue.mode=30;break}for(;an--;)ue.lens[ue.have++]=gn}}if(ue.mode===30)break;if(ue.lens[256]===0){Xe.msg="invalid code -- missing end-of-block",ue.mode=30;break}if(ue.lenbits=9,Kn={bits:ue.lenbits},Xn=b(1,ue.lens,0,ue.nlen,ue.lencode,0,ue.work,Kn),ue.lenbits=Kn.bits,Xn){Xe.msg="invalid literal/lengths set",ue.mode=30;break}if(ue.distbits=6,ue.distcode=ue.distdyn,Kn={bits:ue.distbits},Xn=b(2,ue.lens,ue.nlen,ue.ndist,ue.distcode,0,ue.work,Kn),ue.distbits=Kn.bits,Xn){Xe.msg="invalid distances set",ue.mode=30;break}if(ue.mode=20,ie===6)break e;case 20:ue.mode=21;case 21:if(6<=It&&258<=nn){Xe.next_out=kt,Xe.avail_out=nn,Xe.next_in=Tt,Xe.avail_in=It,ue.hold=tn,ue.bits=pn,y(Xe,Dn),kt=Xe.next_out,mt=Xe.output,nn=Xe.avail_out,Tt=Xe.next_in,pt=Xe.input,It=Xe.avail_in,tn=ue.hold,pn=ue.bits,ue.mode===12&&(ue.back=-1);break}for(ue.back=0;hn=(Yn=ue.lencode[tn&(1<<ue.lenbits)-1])>>>16&255,xn=65535&Yn,!((wn=Yn>>>24)<=pn);){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}if(hn&&!(240&hn)){for($n=wn,Xr=hn,ti=xn;hn=(Yn=ue.lencode[ti+((tn&(1<<$n+Xr)-1)>>$n)])>>>16&255,xn=65535&Yn,!($n+(wn=Yn>>>24)<=pn);){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}tn>>>=$n,pn-=$n,ue.back+=$n}if(tn>>>=wn,pn-=wn,ue.back+=wn,ue.length=xn,hn===0){ue.mode=26;break}if(32&hn){ue.back=-1,ue.mode=12;break}if(64&hn){Xe.msg="invalid literal/length code",ue.mode=30;break}ue.extra=15&hn,ue.mode=22;case 22:if(ue.extra){for(Vn=ue.extra;pn<Vn;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}ue.length+=tn&(1<<ue.extra)-1,tn>>>=ue.extra,pn-=ue.extra,ue.back+=ue.extra}ue.was=ue.length,ue.mode=23;case 23:for(;hn=(Yn=ue.distcode[tn&(1<<ue.distbits)-1])>>>16&255,xn=65535&Yn,!((wn=Yn>>>24)<=pn);){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}if(!(240&hn)){for($n=wn,Xr=hn,ti=xn;hn=(Yn=ue.distcode[ti+((tn&(1<<$n+Xr)-1)>>$n)])>>>16&255,xn=65535&Yn,!($n+(wn=Yn>>>24)<=pn);){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}tn>>>=$n,pn-=$n,ue.back+=$n}if(tn>>>=wn,pn-=wn,ue.back+=wn,64&hn){Xe.msg="invalid distance code",ue.mode=30;break}ue.offset=xn,ue.extra=15&hn,ue.mode=24;case 24:if(ue.extra){for(Vn=ue.extra;pn<Vn;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}ue.offset+=tn&(1<<ue.extra)-1,tn>>>=ue.extra,pn-=ue.extra,ue.back+=ue.extra}if(ue.offset>ue.dmax){Xe.msg="invalid distance too far back",ue.mode=30;break}ue.mode=25;case 25:if(nn===0)break e;if(an=Dn-nn,ue.offset>an){if((an=ue.offset-an)>ue.whave&&ue.sane){Xe.msg="invalid distance too far back",ue.mode=30;break}Rn=an>ue.wnext?(an-=ue.wnext,ue.wsize-an):ue.wnext-an,an>ue.length&&(an=ue.length),Lt=ue.window}else Lt=mt,Rn=kt-ue.offset,an=ue.length;for(nn<an&&(an=nn),nn-=an,ue.length-=an;mt[kt++]=Lt[Rn++],--an;);ue.length===0&&(ue.mode=21);break;case 26:if(nn===0)break e;mt[kt++]=ue.length,nn--,ue.mode=21;break;case 27:if(ue.wrap){for(;pn<32;){if(It===0)break e;It--,tn|=pt[Tt++]<<pn,pn+=8}if(Dn-=nn,Xe.total_out+=Dn,ue.total+=Dn,Dn&&(Xe.adler=ue.check=(ue.flags?c:u)(ue.check,mt,Dn,kt-Dn)),Dn=nn,(ue.flags?tn:q(tn))!==ue.check){Xe.msg="incorrect data check",ue.mode=30;break}pn=tn=0}ue.mode=28;case 28:if(ue.wrap&&ue.flags){for(;pn<32;){if(It===0)break e;It--,tn+=pt[Tt++]<<pn,pn+=8}if(tn!==(4294967295&ue.total)){Xe.msg="incorrect length check",ue.mode=30;break}pn=tn=0}ue.mode=29;case 29:Xn=1;break e;case 30:Xn=-3;break e;case 31:return-4;default:return O}return Xe.next_out=kt,Xe.avail_out=nn,Xe.next_in=Tt,Xe.avail_in=It,ue.hold=tn,ue.bits=pn,(ue.wsize||Dn!==Xe.avail_out&&ue.mode<30&&(ue.mode<27||ie!==4))&&Te(Xe,Xe.output,Xe.next_out,Dn-Xe.avail_out)?(ue.mode=31,-4):(_n-=Xe.avail_in,Dn-=Xe.avail_out,Xe.total_in+=_n,Xe.total_out+=Dn,ue.total+=Dn,ue.wrap&&Dn&&(Xe.adler=ue.check=(ue.flags?c:u)(ue.check,mt,Dn,Xe.next_out-Dn)),Xe.data_type=ue.bits+(ue.last?64:0)+(ue.mode===12?128:0)+(ue.mode===20||ue.mode===15?256:0),(_n==0&&Dn===0||ie===4)&&Xn===m&&(Xn=-5),Xn)},l.inflateEnd=function(Xe){if(!Xe||!Xe.state)return O;var ie=Xe.state;return ie.window&&(ie.window=null),Xe.state=null,m},l.inflateGetHeader=function(Xe,ie){var ue;return Xe&&Xe.state&&2&(ue=Xe.state).wrap?((ue.head=ie).done=!1,m):O},l.inflateSetDictionary=function(Xe,ie){var ue,pt=ie.length;return!Xe||!Xe.state||(ue=Xe.state).wrap!==0&&ue.mode!==11?O:ue.mode===11&&u(1,ie,pt,0)!==ue.check?-3:Te(Xe,ie,pt,pt)?(ue.mode=31,-4):(ue.havedict=1,m)},l.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":4,"./adler32":6,"./crc32":8,"./inffast":11,"./inftrees":13}],13:[function(t,e,l){var n=t("../utils/common"),u=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],c=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],y=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],b=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];e.exports=function(m,O,N,L,G,q,J,fe){var ve,ne,Ue,De,Ve,rt,Ae,Te,Xe,ie=fe.bits,ue=0,pt=0,mt=0,Tt=0,kt=0,It=0,nn=0,tn=0,pn=0,_n=0,Dn=null,an=0,Rn=new n.Buf16(16),Lt=new n.Buf16(16),wn=null,hn=0;for(ue=0;ue<=15;ue++)Rn[ue]=0;for(pt=0;pt<L;pt++)Rn[O[N+pt]]++;for(kt=ie,Tt=15;1<=Tt&&Rn[Tt]===0;Tt--);if(Tt<kt&&(kt=Tt),Tt===0)return G[q++]=20971520,G[q++]=20971520,fe.bits=1,0;for(mt=1;mt<Tt&&Rn[mt]===0;mt++);for(kt<mt&&(kt=mt),ue=tn=1;ue<=15;ue++)if(tn<<=1,(tn-=Rn[ue])<0)return-1;if(0<tn&&(m===0||Tt!==1))return-1;for(Lt[1]=0,ue=1;ue<15;ue++)Lt[ue+1]=Lt[ue]+Rn[ue];for(pt=0;pt<L;pt++)O[N+pt]!==0&&(J[Lt[O[N+pt]]++]=pt);if(rt=m===0?(Dn=wn=J,19):m===1?(Dn=u,an-=257,wn=c,hn-=257,256):(Dn=y,wn=b,-1),ue=mt,Ve=q,nn=pt=_n=0,Ue=-1,De=(pn=1<<(It=kt))-1,m===1&&852<pn||m===2&&592<pn)return 1;for(;;){for(Ae=ue-nn,Xe=J[pt]<rt?(Te=0,J[pt]):J[pt]>rt?(Te=wn[hn+J[pt]],Dn[an+J[pt]]):(Te=96,0),ve=1<<ue-nn,mt=ne=1<<It;G[Ve+(_n>>nn)+(ne-=ve)]=Ae<<24|Te<<16|Xe|0,ne!==0;);for(ve=1<<ue-1;_n&ve;)ve>>=1;if(ve!==0?(_n&=ve-1,_n+=ve):_n=0,pt++,--Rn[ue]==0){if(ue===Tt)break;ue=O[N+J[pt]]}if(kt<ue&&(_n&De)!==Ue){for(nn===0&&(nn=kt),Ve+=mt,tn=1<<(It=ue-nn);It+nn<Tt&&!((tn-=Rn[It+nn])<=0);)It++,tn<<=1;if(pn+=1<<It,m===1&&852<pn||m===2&&592<pn)return 1;G[Ue=_n&De]=kt<<24|It<<16|Ve-q|0}}return _n!==0&&(G[Ve+_n]=ue-nn<<24|64<<16|0),fe.bits=kt,0}},{"../utils/common":4}],14:[function(t,e,l){e.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],15:[function(t,e,l){var n=t("../utils/common");function u(hn){for(var xn=hn.length;0<=--xn;)hn[xn]=0}var c=256,y=286,b=30,m=15,O=16,N=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],L=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],G=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],q=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],J=new Array(576);u(J);var fe=new Array(60);u(fe);var ve=new Array(512);u(ve);var ne=new Array(256);u(ne);var Ue=new Array(29);u(Ue);var De,Ve,rt,Ae=new Array(b);function Te(hn,xn,$n,Xr,ti){this.static_tree=hn,this.extra_bits=xn,this.extra_base=$n,this.elems=Xr,this.max_length=ti,this.has_stree=hn&&hn.length}function Xe(hn,xn){this.dyn_tree=hn,this.max_code=0,this.stat_desc=xn}function ie(hn){return hn<256?ve[hn]:ve[256+(hn>>>7)]}function ue(hn,xn){hn.pending_buf[hn.pending++]=255&xn,hn.pending_buf[hn.pending++]=xn>>>8&255}function pt(hn,xn,$n){hn.bi_valid>O-$n?(hn.bi_buf|=xn<<hn.bi_valid&65535,ue(hn,hn.bi_buf),hn.bi_buf=xn>>O-hn.bi_valid,hn.bi_valid+=$n-O):(hn.bi_buf|=xn<<hn.bi_valid&65535,hn.bi_valid+=$n)}function mt(hn,xn,$n){pt(hn,$n[2*xn],$n[2*xn+1])}function Tt(hn,xn){for(var $n=0;$n|=1&hn,hn>>>=1,$n<<=1,0<--xn;);return $n>>>1}function kt(hn,xn,$n){var Xr,ti,gn=new Array(m+1),Xn=0;for(Xr=1;Xr<=m;Xr++)gn[Xr]=Xn=Xn+$n[Xr-1]<<1;for(ti=0;ti<=xn;ti++){var Kn=hn[2*ti+1];Kn!==0&&(hn[2*ti]=Tt(gn[Kn]++,Kn))}}function It(hn){var xn;for(xn=0;xn<y;xn++)hn.dyn_ltree[2*xn]=0;for(xn=0;xn<b;xn++)hn.dyn_dtree[2*xn]=0;for(xn=0;xn<19;xn++)hn.bl_tree[2*xn]=0;hn.dyn_ltree[512]=1,hn.opt_len=hn.static_len=0,hn.last_lit=hn.matches=0}function nn(hn){8<hn.bi_valid?ue(hn,hn.bi_buf):0<hn.bi_valid&&(hn.pending_buf[hn.pending++]=hn.bi_buf),hn.bi_buf=0,hn.bi_valid=0}function tn(hn,xn,$n,Xr){var ti=2*xn,gn=2*$n;return hn[ti]<hn[gn]||hn[ti]===hn[gn]&&Xr[xn]<=Xr[$n]}function pn(hn,xn,$n){for(var Xr=hn.heap[$n],ti=$n<<1;ti<=hn.heap_len&&(ti<hn.heap_len&&tn(xn,hn.heap[ti+1],hn.heap[ti],hn.depth)&&ti++,!tn(xn,Xr,hn.heap[ti],hn.depth));)hn.heap[$n]=hn.heap[ti],$n=ti,ti<<=1;hn.heap[$n]=Xr}function _n(hn,xn,$n){var Xr,ti,gn,Xn,Kn=0;if(hn.last_lit!==0)for(;Xr=hn.pending_buf[hn.d_buf+2*Kn]<<8|hn.pending_buf[hn.d_buf+2*Kn+1],ti=hn.pending_buf[hn.l_buf+Kn],Kn++,Xr===0?mt(hn,ti,xn):(mt(hn,(gn=ne[ti])+c+1,xn),(Xn=N[gn])!==0&&pt(hn,ti-=Ue[gn],Xn),mt(hn,gn=ie(--Xr),$n),(Xn=L[gn])!==0&&pt(hn,Xr-=Ae[gn],Xn)),Kn<hn.last_lit;);mt(hn,256,xn)}function Dn(hn,xn){var $n,Xr,ti,gn=xn.dyn_tree,Xn=xn.stat_desc.static_tree,Kn=xn.stat_desc.has_stree,Vn=xn.stat_desc.elems,Yn=-1;for(hn.heap_len=0,hn.heap_max=573,$n=0;$n<Vn;$n++)gn[2*$n]!==0?(hn.heap[++hn.heap_len]=Yn=$n,hn.depth[$n]=0):gn[2*$n+1]=0;for(;hn.heap_len<2;)gn[2*(ti=hn.heap[++hn.heap_len]=Yn<2?++Yn:0)]=1,hn.depth[ti]=0,hn.opt_len--,Kn&&(hn.static_len-=Xn[2*ti+1]);for(xn.max_code=Yn,$n=hn.heap_len>>1;1<=$n;$n--)pn(hn,gn,$n);for(ti=Vn;$n=hn.heap[1],hn.heap[1]=hn.heap[hn.heap_len--],pn(hn,gn,1),Xr=hn.heap[1],hn.heap[--hn.heap_max]=$n,hn.heap[--hn.heap_max]=Xr,gn[2*ti]=gn[2*$n]+gn[2*Xr],hn.depth[ti]=(hn.depth[$n]>=hn.depth[Xr]?hn.depth[$n]:hn.depth[Xr])+1,gn[2*$n+1]=gn[2*Xr+1]=ti,hn.heap[1]=ti++,pn(hn,gn,1),2<=hn.heap_len;);hn.heap[--hn.heap_max]=hn.heap[1],function(Vr,xi){var Si,qn,ia,Wi,ha,ai,Ia=xi.dyn_tree,fi=xi.max_code,An=xi.stat_desc.static_tree,sa=xi.stat_desc.has_stree,Nn=xi.stat_desc.extra_bits,fn=xi.stat_desc.extra_base,un=xi.stat_desc.max_length,Ln=0;for(Wi=0;Wi<=m;Wi++)Vr.bl_count[Wi]=0;for(Ia[2*Vr.heap[Vr.heap_max]+1]=0,Si=Vr.heap_max+1;Si<573;Si++)un<(Wi=Ia[2*Ia[2*(qn=Vr.heap[Si])+1]+1]+1)&&(Wi=un,Ln++),Ia[2*qn+1]=Wi,fi<qn||(Vr.bl_count[Wi]++,ha=0,fn<=qn&&(ha=Nn[qn-fn]),ai=Ia[2*qn],Vr.opt_len+=ai*(Wi+ha),sa&&(Vr.static_len+=ai*(An[2*qn+1]+ha)));if(Ln!==0){do{for(Wi=un-1;Vr.bl_count[Wi]===0;)Wi--;Vr.bl_count[Wi]--,Vr.bl_count[Wi+1]+=2,Vr.bl_count[un]--,Ln-=2}while(0<Ln);for(Wi=un;Wi!==0;Wi--)for(qn=Vr.bl_count[Wi];qn!==0;)fi<(ia=Vr.heap[--Si])||(Ia[2*ia+1]!==Wi&&(Vr.opt_len+=(Wi-Ia[2*ia+1])*Ia[2*ia],Ia[2*ia+1]=Wi),qn--)}}(hn,xn),kt(gn,Yn,hn.bl_count)}function an(hn,xn,$n){var Xr,ti,gn=-1,Xn=xn[1],Kn=0,Vn=7,Yn=4;for(Xn===0&&(Vn=138,Yn=3),xn[2*($n+1)+1]=65535,Xr=0;Xr<=$n;Xr++)ti=Xn,Xn=xn[2*(Xr+1)+1],++Kn<Vn&&ti===Xn||(Kn<Yn?hn.bl_tree[2*ti]+=Kn:ti!==0?(ti!==gn&&hn.bl_tree[2*ti]++,hn.bl_tree[32]++):Kn<=10?hn.bl_tree[34]++:hn.bl_tree[36]++,gn=ti,Yn=(Kn=0)===Xn?(Vn=138,3):ti===Xn?(Vn=6,3):(Vn=7,4))}function Rn(hn,xn,$n){var Xr,ti,gn=-1,Xn=xn[1],Kn=0,Vn=7,Yn=4;for(Xn===0&&(Vn=138,Yn=3),Xr=0;Xr<=$n;Xr++)if(ti=Xn,Xn=xn[2*(Xr+1)+1],!(++Kn<Vn&&ti===Xn)){if(Kn<Yn)for(;mt(hn,ti,hn.bl_tree),--Kn!=0;);else ti!==0?(ti!==gn&&(mt(hn,ti,hn.bl_tree),Kn--),mt(hn,16,hn.bl_tree),pt(hn,Kn-3,2)):Kn<=10?(mt(hn,17,hn.bl_tree),pt(hn,Kn-3,3)):(mt(hn,18,hn.bl_tree),pt(hn,Kn-11,7));gn=ti,Yn=(Kn=0)===Xn?(Vn=138,3):ti===Xn?(Vn=6,3):(Vn=7,4)}}u(Ae);var Lt=!1;function wn(hn,xn,$n,Xr){var ti,gn,Xn;pt(hn,0+(Xr?1:0),3),gn=xn,Xn=$n,nn(ti=hn),ue(ti,Xn),ue(ti,~Xn),n.arraySet(ti.pending_buf,ti.window,gn,Xn,ti.pending),ti.pending+=Xn}l._tr_init=function(hn){Lt||(function(){var xn,$n,Xr,ti,gn,Xn=new Array(m+1);for(ti=Xr=0;ti<28;ti++)for(Ue[ti]=Xr,xn=0;xn<1<<N[ti];xn++)ne[Xr++]=ti;for(ne[Xr-1]=ti,ti=gn=0;ti<16;ti++)for(Ae[ti]=gn,xn=0;xn<1<<L[ti];xn++)ve[gn++]=ti;for(gn>>=7;ti<b;ti++)for(Ae[ti]=gn<<7,xn=0;xn<1<<L[ti]-7;xn++)ve[256+gn++]=ti;for($n=0;$n<=m;$n++)Xn[$n]=0;for(xn=0;xn<=143;)J[2*xn+1]=8,xn++,Xn[8]++;for(;xn<=255;)J[2*xn+1]=9,xn++,Xn[9]++;for(;xn<=279;)J[2*xn+1]=7,xn++,Xn[7]++;for(;xn<=287;)J[2*xn+1]=8,xn++,Xn[8]++;for(kt(J,287,Xn),xn=0;xn<b;xn++)fe[2*xn+1]=5,fe[2*xn]=Tt(xn,5);De=new Te(J,N,257,y,m),Ve=new Te(fe,L,0,b,m),rt=new Te(new Array(0),G,0,19,7)}(),Lt=!0),hn.l_desc=new Xe(hn.dyn_ltree,De),hn.d_desc=new Xe(hn.dyn_dtree,Ve),hn.bl_desc=new Xe(hn.bl_tree,rt),hn.bi_buf=0,hn.bi_valid=0,It(hn)},l._tr_stored_block=wn,l._tr_flush_block=function(hn,xn,$n,Xr){var ti,gn,Xn=0;0<hn.level?(hn.strm.data_type===2&&(hn.strm.data_type=function(Kn){var Vn,Yn=4093624447;for(Vn=0;Vn<=31;Vn++,Yn>>>=1)if(1&Yn&&Kn.dyn_ltree[2*Vn]!==0)return 0;if(Kn.dyn_ltree[18]!==0||Kn.dyn_ltree[20]!==0||Kn.dyn_ltree[26]!==0)return 1;for(Vn=32;Vn<c;Vn++)if(Kn.dyn_ltree[2*Vn]!==0)return 1;return 0}(hn)),Dn(hn,hn.l_desc),Dn(hn,hn.d_desc),Xn=function(Kn){var Vn;for(an(Kn,Kn.dyn_ltree,Kn.l_desc.max_code),an(Kn,Kn.dyn_dtree,Kn.d_desc.max_code),Dn(Kn,Kn.bl_desc),Vn=18;3<=Vn&&Kn.bl_tree[2*q[Vn]+1]===0;Vn--);return Kn.opt_len+=3*(Vn+1)+5+5+4,Vn}(hn),ti=hn.opt_len+3+7>>>3,(gn=hn.static_len+3+7>>>3)<=ti&&(ti=gn)):ti=gn=$n+5,$n+4<=ti&&xn!==-1?wn(hn,xn,$n,Xr):hn.strategy===4||gn===ti?(pt(hn,2+(Xr?1:0),3),_n(hn,J,fe)):(pt(hn,4+(Xr?1:0),3),function(Kn,Vn,Yn,Vr){var xi;for(pt(Kn,Vn-257,5),pt(Kn,Yn-1,5),pt(Kn,Vr-4,4),xi=0;xi<Vr;xi++)pt(Kn,Kn.bl_tree[2*q[xi]+1],3);Rn(Kn,Kn.dyn_ltree,Vn-1),Rn(Kn,Kn.dyn_dtree,Yn-1)}(hn,hn.l_desc.max_code+1,hn.d_desc.max_code+1,Xn+1),_n(hn,hn.dyn_ltree,hn.dyn_dtree)),It(hn),Xr&&nn(hn)},l._tr_tally=function(hn,xn,$n){return hn.pending_buf[hn.d_buf+2*hn.last_lit]=xn>>>8&255,hn.pending_buf[hn.d_buf+2*hn.last_lit+1]=255&xn,hn.pending_buf[hn.l_buf+hn.last_lit]=255&$n,hn.last_lit++,xn===0?hn.dyn_ltree[2*$n]++:(hn.matches++,xn--,hn.dyn_ltree[2*(ne[$n]+c+1)]++,hn.dyn_dtree[2*ie(xn)]++),hn.last_lit===hn.lit_bufsize-1},l._tr_align=function(hn){var xn;pt(hn,2,3),mt(hn,256,J),(xn=hn).bi_valid===16?(ue(xn,xn.bi_buf),xn.bi_buf=0,xn.bi_valid=0):8<=xn.bi_valid&&(xn.pending_buf[xn.pending++]=255&xn.bi_buf,xn.bi_buf>>=8,xn.bi_valid-=8)}},{"../utils/common":4}],16:[function(t,e,l){e.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},{}],17:[function(t,e,l){var n=t("three");n.OrbitControls=function(u,c){var y,b,m,O,N;c===void 0&&console.warn('THREE.OrbitControls: The second parameter "domElement" is now mandatory.'),c===document&&console.error('THREE.OrbitControls: "document" should not be used as the target "domElement". Please use "renderer.domElement" instead.'),this.object=u,this.domElement=c,this.enabled=!0,this.target=new n.Vector3,this.minDistance=0,this.maxDistance=1/0,this.minZoom=0,this.maxZoom=1/0,this.minPolarAngle=0,this.maxPolarAngle=Math.PI,this.minAzimuthAngle=-1/0,this.maxAzimuthAngle=1/0,this.enableDamping=!1,this.dampingFactor=.05,this.enableZoom=!0,this.zoomSpeed=1,this.enableRotate=!0,this.rotateSpeed=1,this.enablePan=!0,this.panSpeed=1,this.screenSpacePanning=!1,this.keyPanSpeed=7,this.autoRotate=!1,this.autoRotateSpeed=2,this.enableKeys=!0,this.keys={LEFT:37,UP:38,RIGHT:39,BOTTOM:40},this.mouseButtons={LEFT:n.MOUSE.ROTATE,MIDDLE:n.MOUSE.DOLLY,RIGHT:n.MOUSE.PAN},this.touches={ONE:n.TOUCH.ROTATE,TWO:n.TOUCH.DOLLY_PAN},this.target0=this.target.clone(),this.position0=this.object.position.clone(),this.zoom0=this.object.zoom,this.getPolarAngle=function(){return Ue.phi},this.getAzimuthalAngle=function(){return Ue.theta},this.saveState=function(){L.target0.copy(L.target),L.position0.copy(L.object.position),L.zoom0=L.object.zoom},this.resetStatusValue=function(){ve=fe.NONE},this.reset=function(){L.target.copy(L.target0),L.object.position.copy(L.position0),L.object.zoom=L.zoom0,L.object.updateProjectionMatrix(),L.dispatchEvent(G),L.update(),ve=fe.NONE},this.update=(y=new n.Vector3,b=new n.Quaternion().setFromUnitVectors(u.up,new n.Vector3(0,1,0)),m=b.clone().inverse(),O=new n.Vector3,N=new n.Quaternion,function(){var fi=L.object.position;return y.copy(fi).sub(L.target),y.applyQuaternion(b),Ue.setFromVector3(y),L.autoRotate&&ve===fe.NONE&&tn(2*Math.PI/60/60*L.autoRotateSpeed),L.enableDamping?(Ue.theta+=De.theta*L.dampingFactor,Ue.phi+=De.phi*L.dampingFactor):(Ue.theta+=De.theta,Ue.phi+=De.phi),Ue.theta=Math.max(L.minAzimuthAngle,Math.min(L.maxAzimuthAngle,Ue.theta)),Ue.phi=Math.max(L.minPolarAngle,Math.min(L.maxPolarAngle,Ue.phi)),Ue.makeSafe(),Ue.radius*=Ve,Ue.radius=Math.max(L.minDistance,Math.min(L.maxDistance,Ue.radius)),L.enableDamping===!0?L.target.addScaledVector(rt,L.dampingFactor):L.target.add(rt),y.setFromSpherical(Ue),y.applyQuaternion(m),fi.copy(L.target).add(y),L.object.lookAt(L.target),L.enableDamping===!0?(De.theta*=1-L.dampingFactor,De.phi*=1-L.dampingFactor,rt.multiplyScalar(1-L.dampingFactor)):(De.set(0,0,0),rt.set(0,0,0)),Ve=1,!(!(Ae||O.distanceToSquared(L.object.position)>ne||8*(1-N.dot(L.object.quaternion))>ne)||(L.dispatchEvent(G),O.copy(L.object.position),N.copy(L.object.quaternion),Ae=!1))}),this.dispose=function(){L.domElement.removeEventListener("contextmenu",Ia,!1),L.domElement.removeEventListener("mousedown",Yn,!1),L.domElement.removeEventListener("wheel",Si,!1),L.domElement.removeEventListener("touchstart",Wi,!1),L.domElement.removeEventListener("touchend",ai,!1),L.domElement.removeEventListener("touchmove",ha,!1),document.removeEventListener("mousemove",Vr,!1),document.removeEventListener("mouseup",xi,!1),L.domElement.removeEventListener("keydown",qn,!1)};var L=this,G={type:"change"},q={type:"start"},J={type:"end"},fe={NONE:-1,ROTATE:0,DOLLY:1,PAN:2,TOUCH_ROTATE:3,TOUCH_PAN:4,TOUCH_DOLLY_PAN:5,TOUCH_DOLLY_ROTATE:6},ve=fe.NONE,ne=1e-6,Ue=new n.Spherical,De=new n.Spherical,Ve=1,rt=new n.Vector3,Ae=!1,Te=new n.Vector2,Xe=new n.Vector2,ie=new n.Vector2,ue=new n.Vector2,pt=new n.Vector2,mt=new n.Vector2,Tt=new n.Vector2,kt=new n.Vector2,It=new n.Vector2;function nn(){return Math.pow(.95,L.zoomSpeed)}function tn(fi){De.theta-=fi}function pn(fi){De.phi-=fi}var _n,Dn,an,Rn=(_n=new n.Vector3,function(fi,An){_n.setFromMatrixColumn(An,0),_n.multiplyScalar(-fi),rt.add(_n)}),Lt=(Dn=new n.Vector3,function(fi,An){L.screenSpacePanning===!0?Dn.setFromMatrixColumn(An,1):(Dn.setFromMatrixColumn(An,0),Dn.crossVectors(L.object.up,Dn)),Dn.multiplyScalar(fi),rt.add(Dn)}),wn=(an=new n.Vector3,function(fi,An){var sa=L.domElement;if(L.object.isPerspectiveCamera){var Nn=L.object.position;an.copy(Nn).sub(L.target);var fn=an.length();fn*=Math.tan(L.object.fov/2*Math.PI/180),Rn(2*fi*fn/sa.clientHeight,L.object.matrix),Lt(2*An*fn/sa.clientHeight,L.object.matrix)}else L.object.isOrthographicCamera?(Rn(fi*(L.object.right-L.object.left)/L.object.zoom/sa.clientWidth,L.object.matrix),Lt(An*(L.object.top-L.object.bottom)/L.object.zoom/sa.clientHeight,L.object.matrix)):(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - pan disabled."),L.enablePan=!1)});function hn(fi){L.object.isPerspectiveCamera?Ve/=fi:L.object.isOrthographicCamera?(L.object.zoom=Math.max(L.minZoom,Math.min(L.maxZoom,L.object.zoom*fi)),L.object.updateProjectionMatrix(),Ae=!0):(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled."),L.enableZoom=!1)}function xn(fi){Te.set(fi.clientX,fi.clientY)}function $n(fi){ue.set(fi.clientX,fi.clientY)}function Xr(fi){if(fi.touches.length==1)Te.set(fi.touches[0].pageX,fi.touches[0].pageY);else{var An=.5*(fi.touches[0].pageX+fi.touches[1].pageX),sa=.5*(fi.touches[0].pageY+fi.touches[1].pageY);Te.set(An,sa)}}function ti(fi){if(fi.touches.length==1)ue.set(fi.touches[0].pageX,fi.touches[0].pageY);else{var An=.5*(fi.touches[0].pageX+fi.touches[1].pageX),sa=.5*(fi.touches[0].pageY+fi.touches[1].pageY);ue.set(An,sa)}}function gn(fi){var An=fi.touches[0].pageX-fi.touches[1].pageX,sa=fi.touches[0].pageY-fi.touches[1].pageY,Nn=Math.sqrt(An*An+sa*sa);Tt.set(0,Nn)}function Xn(fi){if(fi.touches.length==1)Xe.set(fi.touches[0].pageX,fi.touches[0].pageY);else{var An=.5*(fi.touches[0].pageX+fi.touches[1].pageX),sa=.5*(fi.touches[0].pageY+fi.touches[1].pageY);Xe.set(An,sa)}ie.subVectors(Xe,Te).multiplyScalar(L.rotateSpeed);var Nn=L.domElement;tn(2*Math.PI*ie.x/Nn.clientHeight),pn(2*Math.PI*ie.y/Nn.clientHeight),Te.copy(Xe)}function Kn(fi){if(fi.touches.length==1)pt.set(fi.touches[0].pageX,fi.touches[0].pageY);else{var An=.5*(fi.touches[0].pageX+fi.touches[1].pageX),sa=.5*(fi.touches[0].pageY+fi.touches[1].pageY);pt.set(An,sa)}mt.subVectors(pt,ue).multiplyScalar(L.panSpeed),wn(mt.x,mt.y),ue.copy(pt)}function Vn(fi){var An=fi.touches[0].pageX-fi.touches[1].pageX,sa=fi.touches[0].pageY-fi.touches[1].pageY,Nn=Math.sqrt(An*An+sa*sa);kt.set(0,Nn),It.set(0,Math.pow(kt.y/Tt.y,L.zoomSpeed)),hn(It.y),Tt.copy(kt)}function Yn(fi){if(L.enabled!==!1){switch(fi.preventDefault(),L.domElement.focus?L.domElement.focus():window.focus(),fi.button){case 0:switch(L.mouseButtons.LEFT){case n.MOUSE.ROTATE:if(fi.ctrlKey||fi.metaKey||fi.shiftKey){if(L.enablePan===!1)return;$n(fi),ve=fe.PAN}else{if(L.enableRotate===!1)return;xn(fi),ve=fe.ROTATE}break;case n.MOUSE.PAN:if(fi.ctrlKey||fi.metaKey||fi.shiftKey){if(L.enableRotate===!1)return;xn(fi),ve=fe.ROTATE}else{if(L.enablePan===!1)return;$n(fi),ve=fe.PAN}break;default:ve=fe.NONE}break;case 1:switch(L.mouseButtons.MIDDLE){case n.MOUSE.DOLLY:if(L.enableZoom===!1)return;An=fi,Tt.set(An.clientX,An.clientY),ve=fe.DOLLY;break;case n.MOUSE.PAN:if(L.enablePan===!1)return;$n(fi),ve=fe.PAN;break;default:ve=fe.NONE}break;case 2:switch(L.mouseButtons.RIGHT){case n.MOUSE.ROTATE:if(L.enableRotate===!1)return;xn(fi),ve=fe.ROTATE;break;case n.MOUSE.PAN:if(L.enablePan===!1)return;$n(fi),ve=fe.PAN;break;default:ve=fe.NONE}}var An;ve!==fe.NONE&&(document.addEventListener("mousemove",Vr,!1),document.addEventListener("mouseup",xi,!1),L.dispatchEvent(q))}}function Vr(fi){var An;if(L.enabled!==!1)switch(fi.preventDefault(),ve){case fe.ROTATE:if(L.enableRotate===!1)return;(function(sa){Xe.set(sa.clientX,sa.clientY),ie.subVectors(Xe,Te).multiplyScalar(L.rotateSpeed);var Nn=L.domElement;tn(2*Math.PI*ie.x/Nn.clientHeight),pn(2*Math.PI*ie.y/Nn.clientHeight),Te.copy(Xe),L.update()})(fi);break;case fe.DOLLY:if(L.enableZoom===!1)return;(function(sa){var Nn;kt.set(sa.clientX,sa.clientY),It.subVectors(kt,Tt),0<It.y?hn(nn()):It.y<0&&(Nn=nn(),L.object.isPerspectiveCamera?Ve*=Nn:L.object.isOrthographicCamera?(L.object.zoom=Math.max(L.minZoom,Math.min(L.maxZoom,L.object.zoom/Nn)),L.object.updateProjectionMatrix(),Ae=!0):(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled."),L.enableZoom=!1)),Tt.copy(kt),L.update()})(fi);break;case fe.PAN:if(L.enablePan===!1)return;An=fi,pt.set(An.clientX,An.clientY),mt.subVectors(pt,ue).multiplyScalar(L.panSpeed),wn(mt.x,mt.y),ue.copy(pt),L.update()}}function xi(fi){L.enabled!==!1&&(document.removeEventListener("mousemove",Vr,!1),document.removeEventListener("mouseup",xi,!1),L.dispatchEvent(J),ve=fe.NONE)}function Si(fi){L.enabled===!1||L.enableZoom===!1||ve!==fe.NONE&&ve!==fe.ROTATE||(fi.preventDefault(),fi.stopPropagation(),L.dispatchEvent(q),function(An){An.deltaY<0?function(sa,Nn){if(L.object.isPerspectiveCamera)Ni*=sa;else if(L.object.isOrthographicCamera){var fn=L.domElement.clientWidth,un=L.domElement.clientHeight,Ln=(L.object.near+L.object.far)/(L.object.near-L.object.far),hr=Nn.offsetX,hi=Nn.offsetY,bi=new n.Vector3(hr/fn*2-1,-hi/un*2+1,Ln);bi.applyMatrix4(L.object.projectionMatrixInverse);var Ra=new n.Vector3(-1,-1,Ln),so=new n.Vector3(1,1,Ln);Ra.applyMatrix4(L.object.projectionMatrixInverse),so.applyMatrix4(L.object.projectionMatrixInverse);var Pi=Math.max(L.minZoom,Math.min(L.maxZoom,1/sa)),oi=new n.Matrix4;oi.makeTranslation(-bi.x,-bi.y,0);var Ni=new n.Matrix4().scale(new n.Vector3(1/Pi,1/Pi,1/Pi)),za=new n.Matrix4;za.makeTranslation(bi.x,bi.y,0);var ki=new n.Matrix4().multiply(za).multiply(Ni).multiply(oi);Ra.applyMatrix4(ki),so.applyMatrix4(ki),L.object.left=Ra.x,L.object.right=so.x,L.object.top=so.y,L.object.bottom=Ra.y,L.object.zoom=1,L.object.updateProjectionMatrix(),Ae=!0}else console.warn("WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled."),L.enableZoom=!1}(nn(),An):0<An.deltaY&&function(sa,Nn){if(L.object.isPerspectiveCamera)Ni/=sa;else if(L.object.isOrthographicCamera){var fn=L.domElement.clientWidth,un=L.domElement.clientHeight,Ln=(L.object.near+L.object.far)/(L.object.near-L.object.far),hr=Nn.offsetX,hi=Nn.offsetY,bi=new n.Vector3(hr/fn*2-1,-hi/un*2+1,Ln);bi.applyMatrix4(L.object.projectionMatrixInverse);var Ra=new n.Vector3(-1,-1,Ln),so=new n.Vector3(1,1,Ln);Ra.applyMatrix4(L.object.projectionMatrixInverse),so.applyMatrix4(L.object.projectionMatrixInverse);var Pi=Math.max(L.minZoom,Math.min(L.maxZoom,sa)),oi=new n.Matrix4;oi.makeTranslation(-bi.x,-bi.y,0);var Ni=new n.Matrix4().scale(new n.Vector3(1/Pi,1/Pi,1/Pi)),za=new n.Matrix4;za.makeTranslation(bi.x,bi.y,0);var ki=new n.Matrix4().multiply(za).multiply(Ni).multiply(oi);Ra.applyMatrix4(ki),so.applyMatrix4(ki),L.object.left=Ra.x,L.object.right=so.x,L.object.top=so.y,L.object.bottom=Ra.y,L.object.zoom=1,L.object.updateProjectionMatrix(),Ae=!0}else console.warn("WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled."),L.enableZoom=!1}(nn(),An),L.update()}(fi),L.dispatchEvent(J))}function qn(fi){L.enabled!==!1&&L.enableKeys!==!1&&L.enablePan!==!1&&function(An){var sa=!1;switch(An.keyCode){case L.keys.UP:wn(0,L.keyPanSpeed),sa=!0;break;case L.keys.BOTTOM:wn(0,-L.keyPanSpeed),sa=!0;break;case L.keys.LEFT:wn(L.keyPanSpeed,0),sa=!0;break;case L.keys.RIGHT:wn(-L.keyPanSpeed,0),sa=!0}sa&&(An.preventDefault(),L.update())}(fi)}function ia(fi){switch(fi.touches.length){case 1:switch(L.touches.ONE){case n.TOUCH.ROTATE:if(L.enableRotate===!1)return;Xr(fi),ve=fe.TOUCH_ROTATE;break;case n.TOUCH.PAN:if(L.enablePan===!1)return;ti(fi),ve=fe.TOUCH_PAN;break;default:ve=fe.NONE}break;case 2:switch(L.touches.TWO){case n.TOUCH.DOLLY_PAN:if(L.enableZoom===!1&&L.enablePan===!1)return;sa=fi,L.enableZoom&&gn(sa),L.enablePan&&ti(sa),ve=fe.TOUCH_DOLLY_PAN;break;case n.TOUCH.DOLLY_ROTATE:if(L.enableZoom===!1&&L.enableRotate===!1)return;An=fi,L.enableZoom&&gn(An),L.enableRotate&&Xr(An),ve=fe.TOUCH_DOLLY_ROTATE;break;default:ve=fe.NONE}break;default:ve=fe.NONE}var An,sa}function Wi(fi){L.enabled!==!1&&(fi.preventDefault(),ia(fi),ve!==fe.NONE&&L.dispatchEvent(q))}function ha(fi){var An,sa;if(L.enabled!==!1)switch(fi.preventDefault(),fi.stopPropagation(),ve){case fe.TOUCH_ROTATE:if(L.enableRotate===!1)return;Xn(fi),L.update();break;case fe.TOUCH_PAN:if(L.enablePan===!1)return;Kn(fi),L.update();break;case fe.TOUCH_DOLLY_PAN:if(L.enableZoom===!1&&L.enablePan===!1)return;sa=fi,L.enableZoom&&Vn(sa),L.enablePan&&Kn(sa),L.update();break;case fe.TOUCH_DOLLY_ROTATE:if(L.enableZoom===!1&&L.enableRotate===!1)return;An=fi,L.enableZoom&&Vn(An),L.enableRotate&&Xn(An),L.update();break;default:ia(fi)}}function ai(fi){L.enabled!==!1&&(L.dispatchEvent(J),ve=fe.NONE)}function Ia(fi){L.enabled!==!1&&fi.preventDefault()}L.domElement.addEventListener("contextmenu",Ia,!1),L.domElement.addEventListener("mousedown",Yn,!1),L.domElement.addEventListener("wheel",Si,!1),L.domElement.addEventListener("touchstart",Wi,!1),L.domElement.addEventListener("touchend",ai,!1),L.domElement.addEventListener("touchmove",ha,!1),L.domElement.addEventListener("keydown",qn,!1),L.domElement.tabIndex===-1&&(L.domElement.tabIndex=0),this.update()},n.OrbitControls.prototype=Object.create(n.EventDispatcher.prototype),n.OrbitControls.prototype.constructor=n.OrbitControls,n.MapControls=function(u,c){n.OrbitControls.call(this,u,c),this.mouseButtons.LEFT=n.MOUSE.PAN,this.mouseButtons.RIGHT=n.MOUSE.ROTATE,this.touches.ONE=n.TOUCH.PAN,this.touches.TWO=n.TOUCH.DOLLY_ROTATE},n.MapControls.prototype=Object.create(n.EventDispatcher.prototype),n.MapControls.prototype.constructor=n.MapControls,l!==void 0&&(e!==void 0&&e.exports&&(l=e.exports={OrbitControls:n.OrbitControls,MapControls:n.MapControls}),l.OrbitControls=n.OrbitControls,l.MapControls=n.MapControls)},{three:19}],18:[function(t,e,l){(function(){var n,u,c,y=t!==void 0,b=this.THREE||y&&t("three");if(!b)throw new Error("MeshLine requires three.js");function m(){this.positions=[],this.previous=[],this.next=[],this.side=[],this.width=[],this.indices_array=[],this.uvs=[],this.counters=[],this.geometry=new b.BufferGeometry,this.widthCallback=null,this.matrixWorld=new b.Matrix4}function O(L,G,q,J,fe){var ve;if(L=L.subarray||L.slice?L:L.buffer,q=q.subarray||q.slice?q:q.buffer,L=G?L.subarray?L.subarray(G,fe&&G+fe):L.slice(G,fe&&G+fe):L,q.set)q.set(L,J);else for(ve=0;ve<L.length;ve++)q[ve+J]=L[ve];return q}function N(L){b.ShaderMaterial.call(this,{uniforms:Object.assign({},b.UniformsLib.fog,{lineWidth:{value:1},map:{value:null},useMap:{value:0},alphaMap:{value:null},useAlphaMap:{value:0},color:{value:new b.Color(16777215)},opacity:{value:1},resolution:{value:new b.Vector2(1,1)},sizeAttenuation:{value:1},near:{value:1},far:{value:1},dashArray:{value:0},dashOffset:{value:0},dashRatio:{value:.5},useDash:{value:0},visibility:{value:1},alphaTest:{value:0},repeat:{value:new b.Vector2(1,1)}}),vertexShader:b.ShaderChunk.meshline_vert,fragmentShader:b.ShaderChunk.meshline_frag}),this.type="MeshLineMaterial",Object.defineProperties(this,{lineWidth:{enumerable:!0,get:function(){return this.uniforms.lineWidth.value},set:function(G){this.uniforms.lineWidth.value=G}},map:{enumerable:!0,get:function(){return this.uniforms.map.value},set:function(G){this.uniforms.map.value=G}},useMap:{enumerable:!0,get:function(){return this.uniforms.useMap.value},set:function(G){this.uniforms.useMap.value=G}},alphaMap:{enumerable:!0,get:function(){return this.uniforms.alphaMap.value},set:function(G){this.uniforms.alphaMap.value=G}},useAlphaMap:{enumerable:!0,get:function(){return this.uniforms.useAlphaMap.value},set:function(G){this.uniforms.useAlphaMap.value=G}},color:{enumerable:!0,get:function(){return this.uniforms.color.value},set:function(G){this.uniforms.color.value=G}},opacity:{enumerable:!0,get:function(){return this.uniforms.opacity.value},set:function(G){this.uniforms.opacity.value=G}},resolution:{enumerable:!0,get:function(){return this.uniforms.resolution.value},set:function(G){this.uniforms.resolution.value.copy(G)}},sizeAttenuation:{enumerable:!0,get:function(){return this.uniforms.sizeAttenuation.value},set:function(G){this.uniforms.sizeAttenuation.value=G}},near:{enumerable:!0,get:function(){return this.uniforms.near.value},set:function(G){this.uniforms.near.value=G}},far:{enumerable:!0,get:function(){return this.uniforms.far.value},set:function(G){this.uniforms.far.value=G}},dashArray:{enumerable:!0,get:function(){return this.uniforms.dashArray.value},set:function(G){this.uniforms.dashArray.value=G,this.useDash=G!==0?1:0}},dashOffset:{enumerable:!0,get:function(){return this.uniforms.dashOffset.value},set:function(G){this.uniforms.dashOffset.value=G}},dashRatio:{enumerable:!0,get:function(){return this.uniforms.dashRatio.value},set:function(G){this.uniforms.dashRatio.value=G}},useDash:{enumerable:!0,get:function(){return this.uniforms.useDash.value},set:function(G){this.uniforms.useDash.value=G}},visibility:{enumerable:!0,get:function(){return this.uniforms.visibility.value},set:function(G){this.uniforms.visibility.value=G}},alphaTest:{enumerable:!0,get:function(){return this.uniforms.alphaTest.value},set:function(G){this.uniforms.alphaTest.value=G}},repeat:{enumerable:!0,get:function(){return this.uniforms.repeat.value},set:function(G){this.uniforms.repeat.value.copy(G)}}}),this.setValues(L)}m.prototype.setMatrixWorld=function(L){this.matrixWorld=L},m.prototype.setGeometry=function(L,G){if(this.widthCallback=G,this.positions=[],this.counters=[],L instanceof b.Geometry)for(var q=0;q<L.vertices.length;q++){var J=L.vertices[q];G=q/L.vertices.length,this.positions.push(J.x,J.y,J.z),this.positions.push(J.x,J.y,J.z),this.counters.push(G),this.counters.push(G)}if(b.BufferGeometry,L instanceof Float32Array||L instanceof Array)for(q=0;q<L.length;q+=3)G=q/L.length,this.positions.push(L[q],L[q+1],L[q+2]),this.positions.push(L[q],L[q+1],L[q+2]),this.counters.push(G),this.counters.push(G);this.process()},m.prototype.raycast=(n=new b.Matrix4,u=new b.Ray,c=new b.Sphere,function(L,G){var q=L.linePrecision,J=q*q,fe=this.geometry;if(fe.boundingSphere===null&&fe.computeBoundingSphere(),c.copy(fe.boundingSphere),c.applyMatrix4(this.matrixWorld),L.ray.intersectSphere(c)!==!1){n.getInverse(this.matrixWorld),u.copy(L.ray).applyMatrix4(n);var ve=new b.Vector3,ne=new b.Vector3,Ue=new b.Vector3,De=new b.Vector3,Ve=this instanceof b.LineSegments?2:1;if(fe instanceof b.BufferGeometry){var rt=fe.index,Ae=fe.attributes;if(rt!==null)for(var Te=rt.array,Xe=Ae.position.array,ie=0,ue=Te.length-1;ie<ue;ie+=Ve){var pt=Te[ie],mt=Te[ie+1];ve.fromArray(Xe,3*pt),ne.fromArray(Xe,3*mt),J<u.distanceSqToSegment(ve,ne,De,Ue)||(De.applyMatrix4(this.matrixWorld),(It=L.ray.origin.distanceTo(De))<L.near||It>L.far||G.push({distance:It,point:Ue.clone().applyMatrix4(this.matrixWorld),index:ie,face:null,faceIndex:null,object:this}))}else for(ie=0,ue=(Xe=Ae.position.array).length/3-1;ie<ue;ie+=Ve)ve.fromArray(Xe,3*ie),ne.fromArray(Xe,3*ie+3),J<u.distanceSqToSegment(ve,ne,De,Ue)||(De.applyMatrix4(this.matrixWorld),(It=L.ray.origin.distanceTo(De))<L.near||It>L.far||G.push({distance:It,point:Ue.clone().applyMatrix4(this.matrixWorld),index:ie,face:null,faceIndex:null,object:this}))}else if(fe instanceof b.Geometry){var Tt=fe.vertices,kt=Tt.length;for(ie=0;ie<kt-1;ie+=Ve){var It;J<u.distanceSqToSegment(Tt[ie],Tt[ie+1],De,Ue)||(De.applyMatrix4(this.matrixWorld),(It=L.ray.origin.distanceTo(De))<L.near||It>L.far||G.push({distance:It,point:Ue.clone().applyMatrix4(this.matrixWorld),index:ie,face:null,faceIndex:null,object:this}))}}}}),m.prototype.compareV3=function(L,G){var q=6*L,J=6*G;return this.positions[q]===this.positions[J]&&this.positions[1+q]===this.positions[1+J]&&this.positions[2+q]===this.positions[2+J]},m.prototype.copyV3=function(L){var G=6*L;return[this.positions[G],this.positions[1+G],this.positions[2+G]]},m.prototype.process=function(){var L,G,q=this.positions.length/6;this.previous=[],this.next=[],this.side=[],this.width=[],this.indices_array=[],this.uvs=[];for(var J=0;J<q;J++)this.side.push(1),this.side.push(-1);for(J=0;J<q;J++)L=this.widthCallback?this.widthCallback(J/(q-1)):1,this.width.push(L),this.width.push(L);for(J=0;J<q;J++)this.uvs.push(J/(q-1),0),this.uvs.push(J/(q-1),1);for(G=this.compareV3(0,q-1)?this.copyV3(q-2):this.copyV3(0),this.previous.push(G[0],G[1],G[2]),this.previous.push(G[0],G[1],G[2]),J=0;J<q-1;J++)G=this.copyV3(J),this.previous.push(G[0],G[1],G[2]),this.previous.push(G[0],G[1],G[2]);for(J=1;J<q;J++)G=this.copyV3(J),this.next.push(G[0],G[1],G[2]),this.next.push(G[0],G[1],G[2]);for(G=this.compareV3(q-1,0)?this.copyV3(1):this.copyV3(q-1),this.next.push(G[0],G[1],G[2]),this.next.push(G[0],G[1],G[2]),J=0;J<q-1;J++){var fe=2*J;this.indices_array.push(fe,1+fe,2+fe),this.indices_array.push(2+fe,1+fe,3+fe)}this.attributes?(this.attributes.position.copyArray(new Float32Array(this.positions)),this.attributes.position.needsUpdate=!0,this.attributes.previous.copyArray(new Float32Array(this.previous)),this.attributes.previous.needsUpdate=!0,this.attributes.next.copyArray(new Float32Array(this.next)),this.attributes.next.needsUpdate=!0,this.attributes.side.copyArray(new Float32Array(this.side)),this.attributes.side.needsUpdate=!0,this.attributes.width.copyArray(new Float32Array(this.width)),this.attributes.width.needsUpdate=!0,this.attributes.uv.copyArray(new Float32Array(this.uvs)),this.attributes.uv.needsUpdate=!0,this.attributes.index.copyArray(new Uint16Array(this.indices_array)),this.attributes.index.needsUpdate=!0):this.attributes={position:new b.BufferAttribute(new Float32Array(this.positions),3),previous:new b.BufferAttribute(new Float32Array(this.previous),3),next:new b.BufferAttribute(new Float32Array(this.next),3),side:new b.BufferAttribute(new Float32Array(this.side),1),width:new b.BufferAttribute(new Float32Array(this.width),1),uv:new b.BufferAttribute(new Float32Array(this.uvs),2),index:new b.BufferAttribute(new Uint16Array(this.indices_array),1),counters:new b.BufferAttribute(new Float32Array(this.counters),1)},this.geometry.setAttribute("position",this.attributes.position),this.geometry.setAttribute("previous",this.attributes.previous),this.geometry.setAttribute("next",this.attributes.next),this.geometry.setAttribute("side",this.attributes.side),this.geometry.setAttribute("width",this.attributes.width),this.geometry.setAttribute("uv",this.attributes.uv),this.geometry.setAttribute("counters",this.attributes.counters),this.geometry.setIndex(this.attributes.index)},m.prototype.advance=function(L){var G=this.attributes.position.array,q=this.attributes.previous.array,J=this.attributes.next.array,fe=G.length;O(G,0,q,0,fe),O(G,6,G,0,fe-6),G[fe-6]=L.x,G[fe-5]=L.y,G[fe-4]=L.z,G[fe-3]=L.x,G[fe-2]=L.y,G[fe-1]=L.z,O(G,6,J,0,fe-6),J[fe-6]=L.x,J[fe-5]=L.y,J[fe-4]=L.z,J[fe-3]=L.x,J[fe-2]=L.y,J[fe-1]=L.z,this.attributes.position.needsUpdate=!0,this.attributes.previous.needsUpdate=!0,this.attributes.next.needsUpdate=!0},b.ShaderChunk.meshline_vert=["",b.ShaderChunk.logdepthbuf_pars_vertex,b.ShaderChunk.fog_pars_vertex,"","attribute vec3 previous;","attribute vec3 next;","attribute float side;","attribute float width;","attribute float counters;","","uniform vec2 resolution;","uniform float lineWidth;","uniform vec3 color;","uniform float opacity;","uniform float sizeAttenuation;","","varying vec2 vUV;","varying vec4 vColor;","varying float vCounters;","","vec2 fix( vec4 i, float aspect ) {",""," vec2 res = i.xy / i.w;"," res.x *= aspect;"," vCounters = counters;"," return res;","","}","","void main() {",""," float aspect = resolution.x / resolution.y;",""," vColor = vec4( color, opacity );"," vUV = uv;",""," mat4 m = projectionMatrix * modelViewMatrix;"," vec4 finalPosition = m * vec4( position, 1.0 );"," vec4 prevPos = m * vec4( previous, 1.0 );"," vec4 nextPos = m * vec4( next, 1.0 );",""," vec2 currentP = fix( finalPosition, aspect );"," vec2 prevP = fix( prevPos, aspect );"," vec2 nextP = fix( nextPos, aspect );",""," float w = lineWidth * width;",""," vec2 dir;"," if( nextP == currentP ) dir = normalize( currentP - prevP );"," else if( prevP == currentP ) dir = normalize( nextP - currentP );"," else {"," vec2 dir1 = normalize( currentP - prevP );"," vec2 dir2 = normalize( nextP - currentP );"," dir = normalize( dir1 + dir2 );",""," vec2 perp = vec2( -dir1.y, dir1.x );"," vec2 miter = vec2( -dir.y, dir.x );"," //w = clamp( w / dot( miter, perp ), 0., 4. * lineWidth * width );",""," }",""," //vec2 normal = ( cross( vec3( dir, 0. ), vec3( 0., 0., 1. ) ) ).xy;"," vec4 normal = vec4( -dir.y, dir.x, 0., 1. );"," normal.xy *= .5 * w;"," normal *= projectionMatrix;"," if( sizeAttenuation == 0. ) {"," normal.xy *= finalPosition.w;"," normal.xy /= ( vec4( resolution, 0., 1. ) * projectionMatrix ).xy;"," }",""," finalPosition.xy += normal.xy * side;",""," gl_Position = finalPosition;","",b.ShaderChunk.logdepthbuf_vertex,b.ShaderChunk.fog_vertex&&" vec4 mvPosition = modelViewMatrix * vec4( position, 1.0 );",b.ShaderChunk.fog_vertex,"}"].join(`
- `),b.ShaderChunk.meshline_frag=["",b.ShaderChunk.fog_pars_fragment,b.ShaderChunk.logdepthbuf_pars_fragment,"","uniform sampler2D map;","uniform sampler2D alphaMap;","uniform float useMap;","uniform float useAlphaMap;","uniform float useDash;","uniform float dashArray;","uniform float dashOffset;","uniform float dashRatio;","uniform float visibility;","uniform float alphaTest;","uniform vec2 repeat;","","varying vec2 vUV;","varying vec4 vColor;","varying float vCounters;","","void main() {","",b.ShaderChunk.logdepthbuf_fragment,""," vec4 c = vColor;"," if( useMap == 1. ) c *= texture2D( map, vUV * repeat );"," if( useAlphaMap == 1. ) c.a *= texture2D( alphaMap, vUV * repeat ).a;"," if( c.a < alphaTest ) discard;"," if( useDash == 1. ){"," c.a *= ceil(mod(vCounters + dashOffset, dashArray) - (dashArray * dashRatio));"," }"," gl_FragColor = c;"," gl_FragColor.a *= step(vCounters, visibility);","",b.ShaderChunk.fog_fragment,"}"].join(`
- `),((N.prototype=Object.create(b.ShaderMaterial.prototype)).constructor=N).prototype.isMeshLineMaterial=!0,N.prototype.copy=function(L){return b.ShaderMaterial.prototype.copy.call(this,L),this.lineWidth=L.lineWidth,this.map=L.map,this.useMap=L.useMap,this.alphaMap=L.alphaMap,this.useAlphaMap=L.useAlphaMap,this.color.copy(L.color),this.opacity=L.opacity,this.resolution.copy(L.resolution),this.sizeAttenuation=L.sizeAttenuation,this.near=L.near,this.far=L.far,this.dashArray.copy(L.dashArray),this.dashOffset.copy(L.dashOffset),this.dashRatio.copy(L.dashRatio),this.useDash=L.useDash,this.visibility=L.visibility,this.alphaTest=L.alphaTest,this.repeat.copy(L.repeat),this},l!==void 0?(e!==void 0&&e.exports&&(l=e.exports={MeshLine:m,MeshLineMaterial:N}),l.MeshLine=m,l.MeshLineMaterial=N):(this.MeshLine=m,this.MeshLineMaterial=N)}).call(this)},{three:19}],19:[function(t,e,l){var n,u;n=this,u=function(c){Number.EPSILON===void 0&&(Number.EPSILON=Math.pow(2,-52)),Number.isInteger===void 0&&(Number.isInteger=function(f){return typeof f=="number"&&isFinite(f)&&Math.floor(f)===f}),Math.sign===void 0&&(Math.sign=function(f){return f<0?-1:0<f?1:+f}),"name"in Function.prototype==0&&Object.defineProperty(Function.prototype,"name",{get:function(){return this.toString().match(/^\s*function\s*([^\(\s]*)/)[1]}}),Object.assign===void 0&&(Object.assign=function(f){if(f==null)throw new TypeError("Cannot convert undefined or null to object");for(var E=Object(f),W=1;W<arguments.length;W++){var ge=arguments[W];if(ge!=null)for(var ct in ge)Object.prototype.hasOwnProperty.call(ge,ct)&&(E[ct]=ge[ct])}return E});var y=0,b=1,m=2,O=1,N=2,L=3,G=0,q=1,J=2,fe=0,ve=0,ne=1,Ue=2,De=3,Ve=4,rt=5,Ae=100,Te=101,Xe=102,ie=103,ue=104,pt=200,mt=201,Tt=202,kt=203,It=204,nn=205,tn=206,pn=207,_n=208,Dn=209,an=210,Rn=0,Lt=1,wn=2,hn=3,xn=4,$n=5,Xr=6,ti=7,gn=0,Xn=1,Kn=2,Vn=0,Yn=1,Vr=2,xi=3,Si=4,qn=5,ia=301,Wi=302,ha=303,ai=304,Ia=305,fi=306,An=307,sa=1e3,Nn=1001,fn=1002,un=1003,Ln=1004,hr=1005,hi=1006,bi=1007,Ra=1008,so=1009,Pi=1010,oi=1011,Ni=1012,za=1013,ki=1014,Aa=1015,Ja=1016,yo=1017,ls=1018,xo=1019,_o=1020,Ao=1021,il=1022,zr=1023,zn=1024,Un=1025,Gr=zr,ni=1026,Ei=1027,$t=1028,ta=1029,Hi=1030,Ai=1031,Ea=1032,wo=1033,to=33776,zo=33777,Po=33778,Lo=33779,Wo=35840,ma=35841,$s=35842,ao=35843,Ps=36196,qo=37808,wl=37809,yu=37810,po=37811,Zs=37812,Es=37813,Xl=37814,xl=37815,jo=37816,ju=37817,Pl=37818,tl=37819,zl=37820,Is=37821,al=2300,Mn=2301,Ur=2400,Gn=2401,Qr=2402,qi=3e3,ga=3001,no=3007,mo=3002,Go=3003,Uo=3004,Ns=3005,jl=3006,Bl=3200,Jl=3201,mu=0,Ol=1,bu=7680,Bu=519,hl=35044,vu=35048;function Ku(){}Object.assign(Ku.prototype,{addEventListener:function(f,E){this._listeners===void 0&&(this._listeners={});var W=this._listeners;W[f]===void 0&&(W[f]=[]),W[f].indexOf(E)===-1&&W[f].push(E)},hasEventListener:function(f,E){if(this._listeners===void 0)return!1;var W=this._listeners;return W[f]!==void 0&&W[f].indexOf(E)!==-1},removeEventListener:function(f,E){if(this._listeners!==void 0){var W=this._listeners[f];if(W!==void 0){var ge=W.indexOf(E);ge!==-1&&W.splice(ge,1)}}},dispatchEvent:function(f){if(this._listeners!==void 0){var E=this._listeners[f.type];if(E!==void 0){f.target=this;for(var W=E.slice(0),ge=0,ct=W.length;ge<ct;ge++)W[ge].call(this,f)}}}});for(var Ul=[],ad=0;ad<256;ad++)Ul[ad]=(ad<16?"0":"")+ad.toString(16);var jc,js={DEG2RAD:Math.PI/180,RAD2DEG:180/Math.PI,generateUUID:function(){var f=4294967295*Math.random()|0,E=4294967295*Math.random()|0,W=4294967295*Math.random()|0,ge=4294967295*Math.random()|0;return(Ul[255&f]+Ul[f>>8&255]+Ul[f>>16&255]+Ul[f>>24&255]+"-"+Ul[255&E]+Ul[E>>8&255]+"-"+Ul[E>>16&15|64]+Ul[E>>24&255]+"-"+Ul[63&W|128]+Ul[W>>8&255]+"-"+Ul[W>>16&255]+Ul[W>>24&255]+Ul[255&ge]+Ul[ge>>8&255]+Ul[ge>>16&255]+Ul[ge>>24&255]).toUpperCase()},clamp:function(f,E,W){return Math.max(E,Math.min(W,f))},euclideanModulo:function(f,E){return(f%E+E)%E},mapLinear:function(f,E,W,ge,ct){return ge+(f-E)*(ct-ge)/(W-E)},lerp:function(f,E,W){return(1-W)*f+W*E},smoothstep:function(f,E,W){return f<=E?0:W<=f?1:(f=(f-E)/(W-E))*f*(3-2*f)},smootherstep:function(f,E,W){return f<=E?0:W<=f?1:(f=(f-E)/(W-E))*f*f*(f*(6*f-15)+10)},randInt:function(f,E){return f+Math.floor(Math.random()*(E-f+1))},randFloat:function(f,E){return f+Math.random()*(E-f)},randFloatSpread:function(f){return f*(.5-Math.random())},degToRad:function(f){return f*js.DEG2RAD},radToDeg:function(f){return f*js.RAD2DEG},isPowerOfTwo:function(f){return(f&f-1)==0&&f!==0},ceilPowerOfTwo:function(f){return Math.pow(2,Math.ceil(Math.log(f)/Math.LN2))},floorPowerOfTwo:function(f){return Math.pow(2,Math.floor(Math.log(f)/Math.LN2))},setQuaternionFromProperEuler:function(f,E,W,ge,ct){var gt=Math.cos,St=Math.sin,Pt=gt(W/2),sn=St(W/2),ln=gt((E+ge)/2),Sn=St((E+ge)/2),En=gt((E-ge)/2),On=St((E-ge)/2),mn=gt((ge-E)/2),Hn=St((ge-E)/2);ct==="XYX"?f.set(Pt*Sn,sn*En,sn*On,Pt*ln):ct==="YZY"?f.set(sn*On,Pt*Sn,sn*En,Pt*ln):ct==="ZXZ"?f.set(sn*En,sn*On,Pt*Sn,Pt*ln):ct==="XZX"?f.set(Pt*Sn,sn*Hn,sn*mn,Pt*ln):ct==="YXY"?f.set(sn*mn,Pt*Sn,sn*Hn,Pt*ln):ct==="ZYZ"?f.set(sn*Hn,sn*mn,Pt*Sn,Pt*ln):console.warn("THREE.MathUtils: .setQuaternionFromProperEuler() encountered an unknown order.")}};function co(f,E){this.x=f||0,this.y=E||0}function Vl(){this.elements=[1,0,0,0,1,0,0,0,1],0<arguments.length&&console.error("THREE.Matrix3: the constructor no longer reads arguments. use .set() instead.")}Object.defineProperties(co.prototype,{width:{get:function(){return this.x},set:function(f){this.x=f}},height:{get:function(){return this.y},set:function(f){this.y=f}}}),Object.assign(co.prototype,{isVector2:!0,set:function(f,E){return this.x=f,this.y=E,this},setScalar:function(f){return this.x=f,this.y=f,this},setX:function(f){return this.x=f,this},setY:function(f){return this.y=f,this},setComponent:function(f,E){switch(f){case 0:this.x=E;break;case 1:this.y=E;break;default:throw new Error("index is out of range: "+f)}return this},getComponent:function(f){switch(f){case 0:return this.x;case 1:return this.y;default:throw new Error("index is out of range: "+f)}},clone:function(){return new this.constructor(this.x,this.y)},copy:function(f){return this.x=f.x,this.y=f.y,this},add:function(f,E){return E!==void 0?(console.warn("THREE.Vector2: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(f,E)):(this.x+=f.x,this.y+=f.y,this)},addScalar:function(f){return this.x+=f,this.y+=f,this},addVectors:function(f,E){return this.x=f.x+E.x,this.y=f.y+E.y,this},addScaledVector:function(f,E){return this.x+=f.x*E,this.y+=f.y*E,this},sub:function(f,E){return E!==void 0?(console.warn("THREE.Vector2: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(f,E)):(this.x-=f.x,this.y-=f.y,this)},subScalar:function(f){return this.x-=f,this.y-=f,this},subVectors:function(f,E){return this.x=f.x-E.x,this.y=f.y-E.y,this},multiply:function(f){return this.x*=f.x,this.y*=f.y,this},multiplyScalar:function(f){return this.x*=f,this.y*=f,this},divide:function(f){return this.x/=f.x,this.y/=f.y,this},divideScalar:function(f){return this.multiplyScalar(1/f)},applyMatrix3:function(f){var E=this.x,W=this.y,ge=f.elements;return this.x=ge[0]*E+ge[3]*W+ge[6],this.y=ge[1]*E+ge[4]*W+ge[7],this},min:function(f){return this.x=Math.min(this.x,f.x),this.y=Math.min(this.y,f.y),this},max:function(f){return this.x=Math.max(this.x,f.x),this.y=Math.max(this.y,f.y),this},clamp:function(f,E){return this.x=Math.max(f.x,Math.min(E.x,this.x)),this.y=Math.max(f.y,Math.min(E.y,this.y)),this},clampScalar:function(f,E){return this.x=Math.max(f,Math.min(E,this.x)),this.y=Math.max(f,Math.min(E,this.y)),this},clampLength:function(f,E){var W=this.length();return this.divideScalar(W||1).multiplyScalar(Math.max(f,Math.min(E,W)))},floor:function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this},ceil:function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this},round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this},roundToZero:function(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this},negate:function(){return this.x=-this.x,this.y=-this.y,this},dot:function(f){return this.x*f.x+this.y*f.y},cross:function(f){return this.x*f.y-this.y*f.x},lengthSq:function(){return this.x*this.x+this.y*this.y},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},manhattanLength:function(){return Math.abs(this.x)+Math.abs(this.y)},normalize:function(){return this.divideScalar(this.length()||1)},angle:function(){var f=Math.atan2(this.y,this.x);return f<0&&(f+=2*Math.PI),f},distanceTo:function(f){return Math.sqrt(this.distanceToSquared(f))},distanceToSquared:function(f){var E=this.x-f.x,W=this.y-f.y;return E*E+W*W},manhattanDistanceTo:function(f){return Math.abs(this.x-f.x)+Math.abs(this.y-f.y)},setLength:function(f){return this.normalize().multiplyScalar(f)},lerp:function(f,E){return this.x+=(f.x-this.x)*E,this.y+=(f.y-this.y)*E,this},lerpVectors:function(f,E,W){return this.subVectors(E,f).multiplyScalar(W).add(f)},equals:function(f){return f.x===this.x&&f.y===this.y},fromArray:function(f,E){return E===void 0&&(E=0),this.x=f[E],this.y=f[E+1],this},toArray:function(f,E){return f===void 0&&(f=[]),E===void 0&&(E=0),f[E]=this.x,f[E+1]=this.y,f},fromBufferAttribute:function(f,E,W){return W!==void 0&&console.warn("THREE.Vector2: offset has been removed from .fromBufferAttribute()."),this.x=f.getX(E),this.y=f.getY(E),this},rotateAround:function(f,E){var W=Math.cos(E),ge=Math.sin(E),ct=this.x-f.x,gt=this.y-f.y;return this.x=ct*W-gt*ge+f.x,this.y=ct*ge+gt*W+f.y,this}}),Object.assign(Vl.prototype,{isMatrix3:!0,set:function(f,E,W,ge,ct,gt,St,Pt,sn){var ln=this.elements;return ln[0]=f,ln[1]=ge,ln[2]=St,ln[3]=E,ln[4]=ct,ln[5]=Pt,ln[6]=W,ln[7]=gt,ln[8]=sn,this},identity:function(){return this.set(1,0,0,0,1,0,0,0,1),this},clone:function(){return new this.constructor().fromArray(this.elements)},copy:function(f){var E=this.elements,W=f.elements;return E[0]=W[0],E[1]=W[1],E[2]=W[2],E[3]=W[3],E[4]=W[4],E[5]=W[5],E[6]=W[6],E[7]=W[7],E[8]=W[8],this},setFromMatrix4:function(f){var E=f.elements;return this.set(E[0],E[4],E[8],E[1],E[5],E[9],E[2],E[6],E[10]),this},multiply:function(f){return this.multiplyMatrices(this,f)},premultiply:function(f){return this.multiplyMatrices(f,this)},multiplyMatrices:function(f,E){var W=f.elements,ge=E.elements,ct=this.elements,gt=W[0],St=W[3],Pt=W[6],sn=W[1],ln=W[4],Sn=W[7],En=W[2],On=W[5],mn=W[8],Hn=ge[0],mr=ge[3],_r=ge[6],gi=ge[1],Ci=ge[4],$i=ge[7],da=ge[2],ji=ge[5],Sa=ge[8];return ct[0]=gt*Hn+St*gi+Pt*da,ct[3]=gt*mr+St*Ci+Pt*ji,ct[6]=gt*_r+St*$i+Pt*Sa,ct[1]=sn*Hn+ln*gi+Sn*da,ct[4]=sn*mr+ln*Ci+Sn*ji,ct[7]=sn*_r+ln*$i+Sn*Sa,ct[2]=En*Hn+On*gi+mn*da,ct[5]=En*mr+On*Ci+mn*ji,ct[8]=En*_r+On*$i+mn*Sa,this},multiplyScalar:function(f){var E=this.elements;return E[0]*=f,E[3]*=f,E[6]*=f,E[1]*=f,E[4]*=f,E[7]*=f,E[2]*=f,E[5]*=f,E[8]*=f,this},determinant:function(){var f=this.elements,E=f[0],W=f[1],ge=f[2],ct=f[3],gt=f[4],St=f[5],Pt=f[6],sn=f[7],ln=f[8];return E*gt*ln-E*St*sn-W*ct*ln+W*St*Pt+ge*ct*sn-ge*gt*Pt},getInverse:function(f,E){f&&f.isMatrix4&&console.error("THREE.Matrix3: .getInverse() no longer takes a Matrix4 argument.");var W=f.elements,ge=this.elements,ct=W[0],gt=W[1],St=W[2],Pt=W[3],sn=W[4],ln=W[5],Sn=W[6],En=W[7],On=W[8],mn=On*sn-ln*En,Hn=ln*Sn-On*Pt,mr=En*Pt-sn*Sn,_r=ct*mn+gt*Hn+St*mr;if(_r==0){var gi="THREE.Matrix3: .getInverse() can't invert matrix, determinant is 0";if(E===!0)throw new Error(gi);return console.warn(gi),this.identity()}var Ci=1/_r;return ge[0]=mn*Ci,ge[1]=(St*En-On*gt)*Ci,ge[2]=(ln*gt-St*sn)*Ci,ge[3]=Hn*Ci,ge[4]=(On*ct-St*Sn)*Ci,ge[5]=(St*Pt-ln*ct)*Ci,ge[6]=mr*Ci,ge[7]=(gt*Sn-En*ct)*Ci,ge[8]=(sn*ct-gt*Pt)*Ci,this},transpose:function(){var f,E=this.elements;return f=E[1],E[1]=E[3],E[3]=f,f=E[2],E[2]=E[6],E[6]=f,f=E[5],E[5]=E[7],E[7]=f,this},getNormalMatrix:function(f){return this.setFromMatrix4(f).getInverse(this).transpose()},transposeIntoArray:function(f){var E=this.elements;return f[0]=E[0],f[1]=E[3],f[2]=E[6],f[3]=E[1],f[4]=E[4],f[5]=E[7],f[6]=E[2],f[7]=E[5],f[8]=E[8],this},setUvTransform:function(f,E,W,ge,ct,gt,St){var Pt=Math.cos(ct),sn=Math.sin(ct);this.set(W*Pt,W*sn,-W*(Pt*gt+sn*St)+gt+f,-ge*sn,ge*Pt,-ge*(-sn*gt+Pt*St)+St+E,0,0,1)},scale:function(f,E){var W=this.elements;return W[0]*=f,W[3]*=f,W[6]*=f,W[1]*=E,W[4]*=E,W[7]*=E,this},rotate:function(f){var E=Math.cos(f),W=Math.sin(f),ge=this.elements,ct=ge[0],gt=ge[3],St=ge[6],Pt=ge[1],sn=ge[4],ln=ge[7];return ge[0]=E*ct+W*Pt,ge[3]=E*gt+W*sn,ge[6]=E*St+W*ln,ge[1]=-W*ct+E*Pt,ge[4]=-W*gt+E*sn,ge[7]=-W*St+E*ln,this},translate:function(f,E){var W=this.elements;return W[0]+=f*W[2],W[3]+=f*W[5],W[6]+=f*W[8],W[1]+=E*W[2],W[4]+=E*W[5],W[7]+=E*W[8],this},equals:function(f){for(var E=this.elements,W=f.elements,ge=0;ge<9;ge++)if(E[ge]!==W[ge])return!1;return!0},fromArray:function(f,E){E===void 0&&(E=0);for(var W=0;W<9;W++)this.elements[W]=f[W+E];return this},toArray:function(f,E){f===void 0&&(f=[]),E===void 0&&(E=0);var W=this.elements;return f[E]=W[0],f[E+1]=W[1],f[E+2]=W[2],f[E+3]=W[3],f[E+4]=W[4],f[E+5]=W[5],f[E+6]=W[6],f[E+7]=W[7],f[E+8]=W[8],f}});var Gc={getDataURL:function(f){var E;if(typeof HTMLCanvasElement>"u")return f.src;if(f instanceof HTMLCanvasElement)E=f;else{jc===void 0&&(jc=document.createElementNS("http://www.w3.org/1999/xhtml","canvas")),jc.width=f.width,jc.height=f.height;var W=jc.getContext("2d");f instanceof ImageData?W.putImageData(f,0,0):W.drawImage(f,0,0,f.width,f.height),E=jc}return 2048<E.width||2048<E.height?E.toDataURL("image/jpeg",.6):E.toDataURL("image/png")}},yd=0;function Ql(f,E,W,ge,ct,gt,St,Pt,sn,ln){Object.defineProperty(this,"id",{value:yd++}),this.uuid=js.generateUUID(),this.name="",this.image=f!==void 0?f:Ql.DEFAULT_IMAGE,this.mipmaps=[],this.mapping=E!==void 0?E:Ql.DEFAULT_MAPPING,this.wrapS=W!==void 0?W:Nn,this.wrapT=ge!==void 0?ge:Nn,this.magFilter=ct!==void 0?ct:hi,this.minFilter=gt!==void 0?gt:Ra,this.anisotropy=sn!==void 0?sn:1,this.format=St!==void 0?St:zr,this.internalFormat=null,this.type=Pt!==void 0?Pt:so,this.offset=new co(0,0),this.repeat=new co(1,1),this.center=new co(0,0),this.rotation=0,this.matrixAutoUpdate=!0,this.matrix=new Vl,this.generateMipmaps=!0,this.premultiplyAlpha=!1,this.flipY=!0,this.unpackAlignment=4,this.encoding=ln!==void 0?ln:qi,this.version=0,this.onUpdate=null}function Ll(f,E,W,ge){this.x=f||0,this.y=E||0,this.z=W||0,this.w=ge!==void 0?ge:1}function Au(f,E,W){this.width=f,this.height=E,this.scissor=new Ll(0,0,f,E),this.scissorTest=!1,this.viewport=new Ll(0,0,f,E),W=W||{},this.texture=new Ql(void 0,W.mapping,W.wrapS,W.wrapT,W.magFilter,W.minFilter,W.format,W.type,W.anisotropy,W.encoding),this.texture.image={},this.texture.image.width=f,this.texture.image.height=E,this.texture.generateMipmaps=W.generateMipmaps!==void 0&&W.generateMipmaps,this.texture.minFilter=W.minFilter!==void 0?W.minFilter:hi,this.depthBuffer=W.depthBuffer===void 0||W.depthBuffer,this.stencilBuffer=W.stencilBuffer===void 0||W.stencilBuffer,this.depthTexture=W.depthTexture!==void 0?W.depthTexture:null}function jd(f,E,W){Au.call(this,f,E,W),this.samples=4}function Wu(f,E,W,ge){this._x=f||0,this._y=E||0,this._z=W||0,this._w=ge!==void 0?ge:1}Ql.DEFAULT_IMAGE=void 0,Ql.DEFAULT_MAPPING=300,Ql.prototype=Object.assign(Object.create(Ku.prototype),{constructor:Ql,isTexture:!0,updateMatrix:function(){this.matrix.setUvTransform(this.offset.x,this.offset.y,this.repeat.x,this.repeat.y,this.rotation,this.center.x,this.center.y)},clone:function(){return new this.constructor().copy(this)},copy:function(f){return this.name=f.name,this.image=f.image,this.mipmaps=f.mipmaps.slice(0),this.mapping=f.mapping,this.wrapS=f.wrapS,this.wrapT=f.wrapT,this.magFilter=f.magFilter,this.minFilter=f.minFilter,this.anisotropy=f.anisotropy,this.format=f.format,this.internalFormat=f.internalFormat,this.type=f.type,this.offset.copy(f.offset),this.repeat.copy(f.repeat),this.center.copy(f.center),this.rotation=f.rotation,this.matrixAutoUpdate=f.matrixAutoUpdate,this.matrix.copy(f.matrix),this.generateMipmaps=f.generateMipmaps,this.premultiplyAlpha=f.premultiplyAlpha,this.flipY=f.flipY,this.unpackAlignment=f.unpackAlignment,this.encoding=f.encoding,this},toJSON:function(f){var E=f===void 0||typeof f=="string";if(!E&&f.textures[this.uuid]!==void 0)return f.textures[this.uuid];var W={metadata:{version:4.5,type:"Texture",generator:"Texture.toJSON"},uuid:this.uuid,name:this.name,mapping:this.mapping,repeat:[this.repeat.x,this.repeat.y],offset:[this.offset.x,this.offset.y],center:[this.center.x,this.center.y],rotation:this.rotation,wrap:[this.wrapS,this.wrapT],format:this.format,type:this.type,encoding:this.encoding,minFilter:this.minFilter,magFilter:this.magFilter,anisotropy:this.anisotropy,flipY:this.flipY,premultiplyAlpha:this.premultiplyAlpha,unpackAlignment:this.unpackAlignment};if(this.image!==void 0){var ge=this.image;if(ge.uuid===void 0&&(ge.uuid=js.generateUUID()),!E&&f.images[ge.uuid]===void 0){var ct;if(Array.isArray(ge)){ct=[];for(var gt=0,St=ge.length;gt<St;gt++)ct.push(Gc.getDataURL(ge[gt]))}else ct=Gc.getDataURL(ge);f.images[ge.uuid]={uuid:ge.uuid,url:ct}}W.image=ge.uuid}return E||(f.textures[this.uuid]=W),W},dispose:function(){this.dispatchEvent({type:"dispose"})},transformUv:function(f){if(this.mapping!==300)return f;if(f.applyMatrix3(this.matrix),f.x<0||1<f.x)switch(this.wrapS){case sa:f.x=f.x-Math.floor(f.x);break;case Nn:f.x=f.x<0?0:1;break;case fn:Math.abs(Math.floor(f.x)%2)===1?f.x=Math.ceil(f.x)-f.x:f.x=f.x-Math.floor(f.x)}if(f.y<0||1<f.y)switch(this.wrapT){case sa:f.y=f.y-Math.floor(f.y);break;case Nn:f.y=f.y<0?0:1;break;case fn:Math.abs(Math.floor(f.y)%2)===1?f.y=Math.ceil(f.y)-f.y:f.y=f.y-Math.floor(f.y)}return this.flipY&&(f.y=1-f.y),f}}),Object.defineProperty(Ql.prototype,"needsUpdate",{set:function(f){f===!0&&this.version++}}),Object.defineProperties(Ll.prototype,{width:{get:function(){return this.z},set:function(f){this.z=f}},height:{get:function(){return this.w},set:function(f){this.w=f}}}),Object.assign(Ll.prototype,{isVector4:!0,set:function(f,E,W,ge){return this.x=f,this.y=E,this.z=W,this.w=ge,this},setScalar:function(f){return this.x=f,this.y=f,this.z=f,this.w=f,this},setX:function(f){return this.x=f,this},setY:function(f){return this.y=f,this},setZ:function(f){return this.z=f,this},setW:function(f){return this.w=f,this},setComponent:function(f,E){switch(f){case 0:this.x=E;break;case 1:this.y=E;break;case 2:this.z=E;break;case 3:this.w=E;break;default:throw new Error("index is out of range: "+f)}return this},getComponent:function(f){switch(f){case 0:return this.x;case 1:return this.y;case 2:return this.z;case 3:return this.w;default:throw new Error("index is out of range: "+f)}},clone:function(){return new this.constructor(this.x,this.y,this.z,this.w)},copy:function(f){return this.x=f.x,this.y=f.y,this.z=f.z,this.w=f.w!==void 0?f.w:1,this},add:function(f,E){return E!==void 0?(console.warn("THREE.Vector4: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(f,E)):(this.x+=f.x,this.y+=f.y,this.z+=f.z,this.w+=f.w,this)},addScalar:function(f){return this.x+=f,this.y+=f,this.z+=f,this.w+=f,this},addVectors:function(f,E){return this.x=f.x+E.x,this.y=f.y+E.y,this.z=f.z+E.z,this.w=f.w+E.w,this},addScaledVector:function(f,E){return this.x+=f.x*E,this.y+=f.y*E,this.z+=f.z*E,this.w+=f.w*E,this},sub:function(f,E){return E!==void 0?(console.warn("THREE.Vector4: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(f,E)):(this.x-=f.x,this.y-=f.y,this.z-=f.z,this.w-=f.w,this)},subScalar:function(f){return this.x-=f,this.y-=f,this.z-=f,this.w-=f,this},subVectors:function(f,E){return this.x=f.x-E.x,this.y=f.y-E.y,this.z=f.z-E.z,this.w=f.w-E.w,this},multiplyScalar:function(f){return this.x*=f,this.y*=f,this.z*=f,this.w*=f,this},applyMatrix4:function(f){var E=this.x,W=this.y,ge=this.z,ct=this.w,gt=f.elements;return this.x=gt[0]*E+gt[4]*W+gt[8]*ge+gt[12]*ct,this.y=gt[1]*E+gt[5]*W+gt[9]*ge+gt[13]*ct,this.z=gt[2]*E+gt[6]*W+gt[10]*ge+gt[14]*ct,this.w=gt[3]*E+gt[7]*W+gt[11]*ge+gt[15]*ct,this},divideScalar:function(f){return this.multiplyScalar(1/f)},setAxisAngleFromQuaternion:function(f){this.w=2*Math.acos(f.w);var E=Math.sqrt(1-f.w*f.w);return E<1e-4?(this.x=1,this.y=0,this.z=0):(this.x=f.x/E,this.y=f.y/E,this.z=f.z/E),this},setAxisAngleFromRotationMatrix:function(f){var E,W,ge,ct,gt=f.elements,St=gt[0],Pt=gt[4],sn=gt[8],ln=gt[1],Sn=gt[5],En=gt[9],On=gt[2],mn=gt[6],Hn=gt[10];if(Math.abs(Pt-ln)<.01&&Math.abs(sn-On)<.01&&Math.abs(En-mn)<.01){if(Math.abs(Pt+ln)<.1&&Math.abs(sn+On)<.1&&Math.abs(En+mn)<.1&&Math.abs(St+Sn+Hn-3)<.1)return this.set(1,0,0,0),this;E=Math.PI;var mr=(St+1)/2,_r=(Sn+1)/2,gi=(Hn+1)/2,Ci=(Pt+ln)/4,$i=(sn+On)/4,da=(En+mn)/4;return _r<mr&&gi<mr?ct=mr<.01?(W=0,ge=.707106781):(ge=Ci/(W=Math.sqrt(mr)),$i/W):gi<_r?ct=_r<.01?(ge=0,W=.707106781):(W=Ci/(ge=Math.sqrt(_r)),da/ge):gi<.01?(ge=W=.707106781,ct=0):(W=$i/(ct=Math.sqrt(gi)),ge=da/ct),this.set(W,ge,ct,E),this}var ji=Math.sqrt((mn-En)*(mn-En)+(sn-On)*(sn-On)+(ln-Pt)*(ln-Pt));return Math.abs(ji)<.001&&(ji=1),this.x=(mn-En)/ji,this.y=(sn-On)/ji,this.z=(ln-Pt)/ji,this.w=Math.acos((St+Sn+Hn-1)/2),this},min:function(f){return this.x=Math.min(this.x,f.x),this.y=Math.min(this.y,f.y),this.z=Math.min(this.z,f.z),this.w=Math.min(this.w,f.w),this},max:function(f){return this.x=Math.max(this.x,f.x),this.y=Math.max(this.y,f.y),this.z=Math.max(this.z,f.z),this.w=Math.max(this.w,f.w),this},clamp:function(f,E){return this.x=Math.max(f.x,Math.min(E.x,this.x)),this.y=Math.max(f.y,Math.min(E.y,this.y)),this.z=Math.max(f.z,Math.min(E.z,this.z)),this.w=Math.max(f.w,Math.min(E.w,this.w)),this},clampScalar:function(f,E){return this.x=Math.max(f,Math.min(E,this.x)),this.y=Math.max(f,Math.min(E,this.y)),this.z=Math.max(f,Math.min(E,this.z)),this.w=Math.max(f,Math.min(E,this.w)),this},clampLength:function(f,E){var W=this.length();return this.divideScalar(W||1).multiplyScalar(Math.max(f,Math.min(E,W)))},floor:function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this.w=Math.floor(this.w),this},ceil:function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this.w=Math.ceil(this.w),this},round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this.w=Math.round(this.w),this},roundToZero:function(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this.z=this.z<0?Math.ceil(this.z):Math.floor(this.z),this.w=this.w<0?Math.ceil(this.w):Math.floor(this.w),this},negate:function(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this.w=-this.w,this},dot:function(f){return this.x*f.x+this.y*f.y+this.z*f.z+this.w*f.w},lengthSq:function(){return this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w)},manhattanLength:function(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)+Math.abs(this.w)},normalize:function(){return this.divideScalar(this.length()||1)},setLength:function(f){return this.normalize().multiplyScalar(f)},lerp:function(f,E){return this.x+=(f.x-this.x)*E,this.y+=(f.y-this.y)*E,this.z+=(f.z-this.z)*E,this.w+=(f.w-this.w)*E,this},lerpVectors:function(f,E,W){return this.subVectors(E,f).multiplyScalar(W).add(f)},equals:function(f){return f.x===this.x&&f.y===this.y&&f.z===this.z&&f.w===this.w},fromArray:function(f,E){return E===void 0&&(E=0),this.x=f[E],this.y=f[E+1],this.z=f[E+2],this.w=f[E+3],this},toArray:function(f,E){return f===void 0&&(f=[]),E===void 0&&(E=0),f[E]=this.x,f[E+1]=this.y,f[E+2]=this.z,f[E+3]=this.w,f},fromBufferAttribute:function(f,E,W){return W!==void 0&&console.warn("THREE.Vector4: offset has been removed from .fromBufferAttribute()."),this.x=f.getX(E),this.y=f.getY(E),this.z=f.getZ(E),this.w=f.getW(E),this}}),Au.prototype=Object.assign(Object.create(Ku.prototype),{constructor:Au,isWebGLRenderTarget:!0,setSize:function(f,E){this.width===f&&this.height===E||(this.width=f,this.height=E,this.texture.image.width=f,this.texture.image.height=E,this.dispose()),this.viewport.set(0,0,f,E),this.scissor.set(0,0,f,E)},clone:function(){return new this.constructor().copy(this)},copy:function(f){return this.width=f.width,this.height=f.height,this.viewport.copy(f.viewport),this.texture=f.texture.clone(),this.depthBuffer=f.depthBuffer,this.stencilBuffer=f.stencilBuffer,this.depthTexture=f.depthTexture,this},dispose:function(){this.dispatchEvent({type:"dispose"})}}),jd.prototype=Object.assign(Object.create(Au.prototype),{constructor:jd,isWebGLMultisampleRenderTarget:!0,copy:function(f){return Au.prototype.copy.call(this,f),this.samples=f.samples,this}}),Object.assign(Wu,{slerp:function(f,E,W,ge){return W.copy(f).slerp(E,ge)},slerpFlat:function(f,E,W,ge,ct,gt,St){var Pt=W[ge+0],sn=W[ge+1],ln=W[ge+2],Sn=W[ge+3],En=ct[gt+0],On=ct[gt+1],mn=ct[gt+2],Hn=ct[gt+3];if(Sn!==Hn||Pt!==En||sn!==On||ln!==mn){var mr=1-St,_r=Pt*En+sn*On+ln*mn+Sn*Hn,gi=0<=_r?1:-1,Ci=1-_r*_r;if(Ci>Number.EPSILON){var $i=Math.sqrt(Ci),da=Math.atan2($i,_r*gi);mr=Math.sin(mr*da)/$i,St=Math.sin(St*da)/$i}var ji=St*gi;if(Pt=Pt*mr+En*ji,sn=sn*mr+On*ji,ln=ln*mr+mn*ji,Sn=Sn*mr+Hn*ji,mr===1-St){var Sa=1/Math.sqrt(Pt*Pt+sn*sn+ln*ln+Sn*Sn);Pt*=Sa,sn*=Sa,ln*=Sa,Sn*=Sa}}f[E]=Pt,f[E+1]=sn,f[E+2]=ln,f[E+3]=Sn}}),Object.defineProperties(Wu.prototype,{x:{get:function(){return this._x},set:function(f){this._x=f,this._onChangeCallback()}},y:{get:function(){return this._y},set:function(f){this._y=f,this._onChangeCallback()}},z:{get:function(){return this._z},set:function(f){this._z=f,this._onChangeCallback()}},w:{get:function(){return this._w},set:function(f){this._w=f,this._onChangeCallback()}}}),Object.assign(Wu.prototype,{isQuaternion:!0,set:function(f,E,W,ge){return this._x=f,this._y=E,this._z=W,this._w=ge,this._onChangeCallback(),this},clone:function(){return new this.constructor(this._x,this._y,this._z,this._w)},copy:function(f){return this._x=f.x,this._y=f.y,this._z=f.z,this._w=f.w,this._onChangeCallback(),this},setFromEuler:function(f,E){if(!f||!f.isEuler)throw new Error("THREE.Quaternion: .setFromEuler() now expects an Euler rotation rather than a Vector3 and order.");var W=f._x,ge=f._y,ct=f._z,gt=f.order,St=Math.cos,Pt=Math.sin,sn=St(W/2),ln=St(ge/2),Sn=St(ct/2),En=Pt(W/2),On=Pt(ge/2),mn=Pt(ct/2);return gt==="XYZ"?(this._x=En*ln*Sn+sn*On*mn,this._y=sn*On*Sn-En*ln*mn,this._z=sn*ln*mn+En*On*Sn,this._w=sn*ln*Sn-En*On*mn):gt==="YXZ"?(this._x=En*ln*Sn+sn*On*mn,this._y=sn*On*Sn-En*ln*mn,this._z=sn*ln*mn-En*On*Sn,this._w=sn*ln*Sn+En*On*mn):gt==="ZXY"?(this._x=En*ln*Sn-sn*On*mn,this._y=sn*On*Sn+En*ln*mn,this._z=sn*ln*mn+En*On*Sn,this._w=sn*ln*Sn-En*On*mn):gt==="ZYX"?(this._x=En*ln*Sn-sn*On*mn,this._y=sn*On*Sn+En*ln*mn,this._z=sn*ln*mn-En*On*Sn,this._w=sn*ln*Sn+En*On*mn):gt==="YZX"?(this._x=En*ln*Sn+sn*On*mn,this._y=sn*On*Sn+En*ln*mn,this._z=sn*ln*mn-En*On*Sn,this._w=sn*ln*Sn-En*On*mn):gt==="XZY"&&(this._x=En*ln*Sn-sn*On*mn,this._y=sn*On*Sn-En*ln*mn,this._z=sn*ln*mn+En*On*Sn,this._w=sn*ln*Sn+En*On*mn),E!==!1&&this._onChangeCallback(),this},setFromAxisAngle:function(f,E){var W=E/2,ge=Math.sin(W);return this._x=f.x*ge,this._y=f.y*ge,this._z=f.z*ge,this._w=Math.cos(W),this._onChangeCallback(),this},setFromRotationMatrix:function(f){var E,W=f.elements,ge=W[0],ct=W[4],gt=W[8],St=W[1],Pt=W[5],sn=W[9],ln=W[2],Sn=W[6],En=W[10],On=ge+Pt+En;return 0<On?(E=.5/Math.sqrt(On+1),this._w=.25/E,this._x=(Sn-sn)*E,this._y=(gt-ln)*E,this._z=(St-ct)*E):Pt<ge&&En<ge?(E=2*Math.sqrt(1+ge-Pt-En),this._w=(Sn-sn)/E,this._x=.25*E,this._y=(ct+St)/E,this._z=(gt+ln)/E):En<Pt?(E=2*Math.sqrt(1+Pt-ge-En),this._w=(gt-ln)/E,this._x=(ct+St)/E,this._y=.25*E,this._z=(sn+Sn)/E):(E=2*Math.sqrt(1+En-ge-Pt),this._w=(St-ct)/E,this._x=(gt+ln)/E,this._y=(sn+Sn)/E,this._z=.25*E),this._onChangeCallback(),this},setFromUnitVectors:function(f,E){var W=f.dot(E)+1;return W<1e-6?(W=0,Math.abs(f.x)>Math.abs(f.z)?(this._x=-f.y,this._y=f.x,this._z=0):(this._x=0,this._y=-f.z,this._z=f.y)):(this._x=f.y*E.z-f.z*E.y,this._y=f.z*E.x-f.x*E.z,this._z=f.x*E.y-f.y*E.x),this._w=W,this.normalize()},angleTo:function(f){return 2*Math.acos(Math.abs(js.clamp(this.dot(f),-1,1)))},rotateTowards:function(f,E){var W=this.angleTo(f);if(W===0)return this;var ge=Math.min(1,E/W);return this.slerp(f,ge),this},inverse:function(){return this.conjugate()},conjugate:function(){return this._x*=-1,this._y*=-1,this._z*=-1,this._onChangeCallback(),this},dot:function(f){return this._x*f._x+this._y*f._y+this._z*f._z+this._w*f._w},lengthSq:function(){return this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w},length:function(){return Math.sqrt(this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w)},normalize:function(){var f=this.length();return f===0?(this._x=0,this._y=0,this._z=0,this._w=1):(f=1/f,this._x=this._x*f,this._y=this._y*f,this._z=this._z*f,this._w=this._w*f),this._onChangeCallback(),this},multiply:function(f,E){return E!==void 0?(console.warn("THREE.Quaternion: .multiply() now only accepts one argument. Use .multiplyQuaternions( a, b ) instead."),this.multiplyQuaternions(f,E)):this.multiplyQuaternions(this,f)},premultiply:function(f){return this.multiplyQuaternions(f,this)},multiplyQuaternions:function(f,E){var W=f._x,ge=f._y,ct=f._z,gt=f._w,St=E._x,Pt=E._y,sn=E._z,ln=E._w;return this._x=W*ln+gt*St+ge*sn-ct*Pt,this._y=ge*ln+gt*Pt+ct*St-W*sn,this._z=ct*ln+gt*sn+W*Pt-ge*St,this._w=gt*ln-W*St-ge*Pt-ct*sn,this._onChangeCallback(),this},slerp:function(f,E){if(E===0)return this;if(E===1)return this.copy(f);var W=this._x,ge=this._y,ct=this._z,gt=this._w,St=gt*f._w+W*f._x+ge*f._y+ct*f._z;if(St<0?(this._w=-f._w,this._x=-f._x,this._y=-f._y,this._z=-f._z,St=-St):this.copy(f),1<=St)return this._w=gt,this._x=W,this._y=ge,this._z=ct,this;var Pt=1-St*St;if(Pt<=Number.EPSILON){var sn=1-E;return this._w=sn*gt+E*this._w,this._x=sn*W+E*this._x,this._y=sn*ge+E*this._y,this._z=sn*ct+E*this._z,this.normalize(),this._onChangeCallback(),this}var ln=Math.sqrt(Pt),Sn=Math.atan2(ln,St),En=Math.sin((1-E)*Sn)/ln,On=Math.sin(E*Sn)/ln;return this._w=gt*En+this._w*On,this._x=W*En+this._x*On,this._y=ge*En+this._y*On,this._z=ct*En+this._z*On,this._onChangeCallback(),this},equals:function(f){return f._x===this._x&&f._y===this._y&&f._z===this._z&&f._w===this._w},fromArray:function(f,E){return E===void 0&&(E=0),this._x=f[E],this._y=f[E+1],this._z=f[E+2],this._w=f[E+3],this._onChangeCallback(),this},toArray:function(f,E){return f===void 0&&(f=[]),E===void 0&&(E=0),f[E]=this._x,f[E+1]=this._y,f[E+2]=this._z,f[E+3]=this._w,f},_onChange:function(f){return this._onChangeCallback=f,this},_onChangeCallback:function(){}});var ud=new yi,Xc=new Wu;function yi(f,E,W){this.x=f||0,this.y=E||0,this.z=W||0}Object.assign(yi.prototype,{isVector3:!0,set:function(f,E,W){return this.x=f,this.y=E,this.z=W,this},setScalar:function(f){return this.x=f,this.y=f,this.z=f,this},setX:function(f){return this.x=f,this},setY:function(f){return this.y=f,this},setZ:function(f){return this.z=f,this},setComponent:function(f,E){switch(f){case 0:this.x=E;break;case 1:this.y=E;break;case 2:this.z=E;break;default:throw new Error("index is out of range: "+f)}return this},getComponent:function(f){switch(f){case 0:return this.x;case 1:return this.y;case 2:return this.z;default:throw new Error("index is out of range: "+f)}},clone:function(){return new this.constructor(this.x,this.y,this.z)},copy:function(f){return this.x=f.x,this.y=f.y,this.z=f.z,this},add:function(f,E){return E!==void 0?(console.warn("THREE.Vector3: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(f,E)):(this.x+=f.x,this.y+=f.y,this.z+=f.z,this)},addScalar:function(f){return this.x+=f,this.y+=f,this.z+=f,this},addVectors:function(f,E){return this.x=f.x+E.x,this.y=f.y+E.y,this.z=f.z+E.z,this},addScaledVector:function(f,E){return this.x+=f.x*E,this.y+=f.y*E,this.z+=f.z*E,this},sub:function(f,E){return E!==void 0?(console.warn("THREE.Vector3: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(f,E)):(this.x-=f.x,this.y-=f.y,this.z-=f.z,this)},subScalar:function(f){return this.x-=f,this.y-=f,this.z-=f,this},subVectors:function(f,E){return this.x=f.x-E.x,this.y=f.y-E.y,this.z=f.z-E.z,this},multiply:function(f,E){return E!==void 0?(console.warn("THREE.Vector3: .multiply() now only accepts one argument. Use .multiplyVectors( a, b ) instead."),this.multiplyVectors(f,E)):(this.x*=f.x,this.y*=f.y,this.z*=f.z,this)},multiplyScalar:function(f){return this.x*=f,this.y*=f,this.z*=f,this},multiplyVectors:function(f,E){return this.x=f.x*E.x,this.y=f.y*E.y,this.z=f.z*E.z,this},applyEuler:function(f){return f&&f.isEuler||console.error("THREE.Vector3: .applyEuler() now expects an Euler rotation rather than a Vector3 and order."),this.applyQuaternion(Xc.setFromEuler(f))},applyAxisAngle:function(f,E){return this.applyQuaternion(Xc.setFromAxisAngle(f,E))},applyMatrix3:function(f){var E=this.x,W=this.y,ge=this.z,ct=f.elements;return this.x=ct[0]*E+ct[3]*W+ct[6]*ge,this.y=ct[1]*E+ct[4]*W+ct[7]*ge,this.z=ct[2]*E+ct[5]*W+ct[8]*ge,this},applyNormalMatrix:function(f){return this.applyMatrix3(f).normalize()},applyMatrix4:function(f){var E=this.x,W=this.y,ge=this.z,ct=f.elements,gt=1/(ct[3]*E+ct[7]*W+ct[11]*ge+ct[15]);return this.x=(ct[0]*E+ct[4]*W+ct[8]*ge+ct[12])*gt,this.y=(ct[1]*E+ct[5]*W+ct[9]*ge+ct[13])*gt,this.z=(ct[2]*E+ct[6]*W+ct[10]*ge+ct[14])*gt,this},applyQuaternion:function(f){var E=this.x,W=this.y,ge=this.z,ct=f.x,gt=f.y,St=f.z,Pt=f.w,sn=Pt*E+gt*ge-St*W,ln=Pt*W+St*E-ct*ge,Sn=Pt*ge+ct*W-gt*E,En=-ct*E-gt*W-St*ge;return this.x=sn*Pt+En*-ct+ln*-St-Sn*-gt,this.y=ln*Pt+En*-gt+Sn*-ct-sn*-St,this.z=Sn*Pt+En*-St+sn*-gt-ln*-ct,this},project:function(f){return this.applyMatrix4(f.matrixWorldInverse).applyMatrix4(f.projectionMatrix)},unproject:function(f){return this.applyMatrix4(f.projectionMatrixInverse).applyMatrix4(f.matrixWorld)},transformDirection:function(f){var E=this.x,W=this.y,ge=this.z,ct=f.elements;return this.x=ct[0]*E+ct[4]*W+ct[8]*ge,this.y=ct[1]*E+ct[5]*W+ct[9]*ge,this.z=ct[2]*E+ct[6]*W+ct[10]*ge,this.normalize()},divide:function(f){return this.x/=f.x,this.y/=f.y,this.z/=f.z,this},divideScalar:function(f){return this.multiplyScalar(1/f)},min:function(f){return this.x=Math.min(this.x,f.x),this.y=Math.min(this.y,f.y),this.z=Math.min(this.z,f.z),this},max:function(f){return this.x=Math.max(this.x,f.x),this.y=Math.max(this.y,f.y),this.z=Math.max(this.z,f.z),this},clamp:function(f,E){return this.x=Math.max(f.x,Math.min(E.x,this.x)),this.y=Math.max(f.y,Math.min(E.y,this.y)),this.z=Math.max(f.z,Math.min(E.z,this.z)),this},clampScalar:function(f,E){return this.x=Math.max(f,Math.min(E,this.x)),this.y=Math.max(f,Math.min(E,this.y)),this.z=Math.max(f,Math.min(E,this.z)),this},clampLength:function(f,E){var W=this.length();return this.divideScalar(W||1).multiplyScalar(Math.max(f,Math.min(E,W)))},floor:function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this},ceil:function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this},round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this},roundToZero:function(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this.z=this.z<0?Math.ceil(this.z):Math.floor(this.z),this},negate:function(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this},dot:function(f){return this.x*f.x+this.y*f.y+this.z*f.z},lengthSq:function(){return this.x*this.x+this.y*this.y+this.z*this.z},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z)},manhattanLength:function(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)},normalize:function(){return this.divideScalar(this.length()||1)},setLength:function(f){return this.normalize().multiplyScalar(f)},lerp:function(f,E){return this.x+=(f.x-this.x)*E,this.y+=(f.y-this.y)*E,this.z+=(f.z-this.z)*E,this},lerpVectors:function(f,E,W){return this.subVectors(E,f).multiplyScalar(W).add(f)},cross:function(f,E){return E!==void 0?(console.warn("THREE.Vector3: .cross() now only accepts one argument. Use .crossVectors( a, b ) instead."),this.crossVectors(f,E)):this.crossVectors(this,f)},crossVectors:function(f,E){var W=f.x,ge=f.y,ct=f.z,gt=E.x,St=E.y,Pt=E.z;return this.x=ge*Pt-ct*St,this.y=ct*gt-W*Pt,this.z=W*St-ge*gt,this},projectOnVector:function(f){var E=f.lengthSq();if(E===0)return this.set(0,0,0);var W=f.dot(this)/E;return this.copy(f).multiplyScalar(W)},projectOnPlane:function(f){return ud.copy(this).projectOnVector(f),this.sub(ud)},reflect:function(f){return this.sub(ud.copy(f).multiplyScalar(2*this.dot(f)))},angleTo:function(f){var E=Math.sqrt(this.lengthSq()*f.lengthSq());if(E===0)return Math.PI/2;var W=this.dot(f)/E;return Math.acos(js.clamp(W,-1,1))},distanceTo:function(f){return Math.sqrt(this.distanceToSquared(f))},distanceToSquared:function(f){var E=this.x-f.x,W=this.y-f.y,ge=this.z-f.z;return E*E+W*W+ge*ge},manhattanDistanceTo:function(f){return Math.abs(this.x-f.x)+Math.abs(this.y-f.y)+Math.abs(this.z-f.z)},setFromSpherical:function(f){return this.setFromSphericalCoords(f.radius,f.phi,f.theta)},setFromSphericalCoords:function(f,E,W){var ge=Math.sin(E)*f;return this.x=ge*Math.sin(W),this.y=Math.cos(E)*f,this.z=ge*Math.cos(W),this},setFromCylindrical:function(f){return this.setFromCylindricalCoords(f.radius,f.theta,f.y)},setFromCylindricalCoords:function(f,E,W){return this.x=f*Math.sin(E),this.y=W,this.z=f*Math.cos(E),this},setFromMatrixPosition:function(f){var E=f.elements;return this.x=E[12],this.y=E[13],this.z=E[14],this},setFromMatrixScale:function(f){var E=this.setFromMatrixColumn(f,0).length(),W=this.setFromMatrixColumn(f,1).length(),ge=this.setFromMatrixColumn(f,2).length();return this.x=E,this.y=W,this.z=ge,this},setFromMatrixColumn:function(f,E){return this.fromArray(f.elements,4*E)},setFromMatrix3Column:function(f,E){return this.fromArray(f.elements,3*E)},equals:function(f){return f.x===this.x&&f.y===this.y&&f.z===this.z},fromArray:function(f,E){return E===void 0&&(E=0),this.x=f[E],this.y=f[E+1],this.z=f[E+2],this},toArray:function(f,E){return f===void 0&&(f=[]),E===void 0&&(E=0),f[E]=this.x,f[E+1]=this.y,f[E+2]=this.z,f},fromBufferAttribute:function(f,E,W){return W!==void 0&&console.warn("THREE.Vector3: offset has been removed from .fromBufferAttribute()."),this.x=f.getX(E),this.y=f.getY(E),this.z=f.getZ(E),this}});var mc=new yi,Su=new Vo,Yh=new yi(0,0,0),ka=new yi(1,1,1),pl=new yi,Il=new yi,Ss=new yi;function Vo(){this.elements=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],0<arguments.length&&console.error("THREE.Matrix4: the constructor no longer reads arguments. use .set() instead.")}Object.assign(Vo.prototype,{isMatrix4:!0,set:function(f,E,W,ge,ct,gt,St,Pt,sn,ln,Sn,En,On,mn,Hn,mr){var _r=this.elements;return _r[0]=f,_r[4]=E,_r[8]=W,_r[12]=ge,_r[1]=ct,_r[5]=gt,_r[9]=St,_r[13]=Pt,_r[2]=sn,_r[6]=ln,_r[10]=Sn,_r[14]=En,_r[3]=On,_r[7]=mn,_r[11]=Hn,_r[15]=mr,this},identity:function(){return this.set(1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1),this},clone:function(){return new Vo().fromArray(this.elements)},copy:function(f){var E=this.elements,W=f.elements;return E[0]=W[0],E[1]=W[1],E[2]=W[2],E[3]=W[3],E[4]=W[4],E[5]=W[5],E[6]=W[6],E[7]=W[7],E[8]=W[8],E[9]=W[9],E[10]=W[10],E[11]=W[11],E[12]=W[12],E[13]=W[13],E[14]=W[14],E[15]=W[15],this},copyPosition:function(f){var E=this.elements,W=f.elements;return E[12]=W[12],E[13]=W[13],E[14]=W[14],this},extractBasis:function(f,E,W){return f.setFromMatrixColumn(this,0),E.setFromMatrixColumn(this,1),W.setFromMatrixColumn(this,2),this},makeBasis:function(f,E,W){return this.set(f.x,E.x,W.x,0,f.y,E.y,W.y,0,f.z,E.z,W.z,0,0,0,0,1),this},extractRotation:function(f){var E=this.elements,W=f.elements,ge=1/mc.setFromMatrixColumn(f,0).length(),ct=1/mc.setFromMatrixColumn(f,1).length(),gt=1/mc.setFromMatrixColumn(f,2).length();return E[0]=W[0]*ge,E[1]=W[1]*ge,E[2]=W[2]*ge,E[3]=0,E[4]=W[4]*ct,E[5]=W[5]*ct,E[6]=W[6]*ct,E[7]=0,E[8]=W[8]*gt,E[9]=W[9]*gt,E[10]=W[10]*gt,E[11]=0,E[12]=0,E[13]=0,E[14]=0,E[15]=1,this},makeRotationFromEuler:function(f){f&&f.isEuler||console.error("THREE.Matrix4: .makeRotationFromEuler() now expects a Euler rotation rather than a Vector3 and order.");var E=this.elements,W=f.x,ge=f.y,ct=f.z,gt=Math.cos(W),St=Math.sin(W),Pt=Math.cos(ge),sn=Math.sin(ge),ln=Math.cos(ct),Sn=Math.sin(ct);if(f.order==="XYZ"){var En=gt*ln,On=gt*Sn,mn=St*ln,Hn=St*Sn;E[0]=Pt*ln,E[4]=-Pt*Sn,E[8]=sn,E[1]=On+mn*sn,E[5]=En-Hn*sn,E[9]=-St*Pt,E[2]=Hn-En*sn,E[6]=mn+On*sn,E[10]=gt*Pt}else if(f.order==="YXZ"){var mr=Pt*ln,_r=Pt*Sn,gi=sn*ln,Ci=sn*Sn;E[0]=mr+Ci*St,E[4]=gi*St-_r,E[8]=gt*sn,E[1]=gt*Sn,E[5]=gt*ln,E[9]=-St,E[2]=_r*St-gi,E[6]=Ci+mr*St,E[10]=gt*Pt}else if(f.order==="ZXY")mr=Pt*ln,_r=Pt*Sn,gi=sn*ln,Ci=sn*Sn,E[0]=mr-Ci*St,E[4]=-gt*Sn,E[8]=gi+_r*St,E[1]=_r+gi*St,E[5]=gt*ln,E[9]=Ci-mr*St,E[2]=-gt*sn,E[6]=St,E[10]=gt*Pt;else if(f.order==="ZYX")En=gt*ln,On=gt*Sn,mn=St*ln,Hn=St*Sn,E[0]=Pt*ln,E[4]=mn*sn-On,E[8]=En*sn+Hn,E[1]=Pt*Sn,E[5]=Hn*sn+En,E[9]=On*sn-mn,E[2]=-sn,E[6]=St*Pt,E[10]=gt*Pt;else if(f.order==="YZX"){var $i=gt*Pt,da=gt*sn,ji=St*Pt,Sa=St*sn;E[0]=Pt*ln,E[4]=Sa-$i*Sn,E[8]=ji*Sn+da,E[1]=Sn,E[5]=gt*ln,E[9]=-St*ln,E[2]=-sn*ln,E[6]=da*Sn+ji,E[10]=$i-Sa*Sn}else f.order==="XZY"&&($i=gt*Pt,da=gt*sn,ji=St*Pt,Sa=St*sn,E[0]=Pt*ln,E[4]=-Sn,E[8]=sn*ln,E[1]=$i*Sn+Sa,E[5]=gt*ln,E[9]=da*Sn-ji,E[2]=ji*Sn-da,E[6]=St*ln,E[10]=Sa*Sn+$i);return E[3]=0,E[7]=0,E[11]=0,E[12]=0,E[13]=0,E[14]=0,E[15]=1,this},makeRotationFromQuaternion:function(f){return this.compose(Yh,f,ka)},lookAt:function(f,E,W){var ge=this.elements;return Ss.subVectors(f,E),Ss.lengthSq()===0&&(Ss.z=1),Ss.normalize(),pl.crossVectors(W,Ss),pl.lengthSq()===0&&(Math.abs(W.z)===1?Ss.x+=1e-4:Ss.z+=1e-4,Ss.normalize(),pl.crossVectors(W,Ss)),pl.normalize(),Il.crossVectors(Ss,pl),ge[0]=pl.x,ge[4]=Il.x,ge[8]=Ss.x,ge[1]=pl.y,ge[5]=Il.y,ge[9]=Ss.y,ge[2]=pl.z,ge[6]=Il.z,ge[10]=Ss.z,this},multiply:function(f,E){return E!==void 0?(console.warn("THREE.Matrix4: .multiply() now only accepts one argument. Use .multiplyMatrices( a, b ) instead."),this.multiplyMatrices(f,E)):this.multiplyMatrices(this,f)},premultiply:function(f){return this.multiplyMatrices(f,this)},multiplyMatrices:function(f,E){var W=f.elements,ge=E.elements,ct=this.elements,gt=W[0],St=W[4],Pt=W[8],sn=W[12],ln=W[1],Sn=W[5],En=W[9],On=W[13],mn=W[2],Hn=W[6],mr=W[10],_r=W[14],gi=W[3],Ci=W[7],$i=W[11],da=W[15],ji=ge[0],Sa=ge[4],ea=ge[8],Ba=ge[12],Ya=ge[1],ro=ge[5],$a=ge[9],go=ge[13],ko=ge[2],Qa=ge[6],Ha=ge[10],fs=ge[14],os=ge[3],Ks=ge[7],Xs=ge[11],zs=ge[15];return ct[0]=gt*ji+St*Ya+Pt*ko+sn*os,ct[4]=gt*Sa+St*ro+Pt*Qa+sn*Ks,ct[8]=gt*ea+St*$a+Pt*Ha+sn*Xs,ct[12]=gt*Ba+St*go+Pt*fs+sn*zs,ct[1]=ln*ji+Sn*Ya+En*ko+On*os,ct[5]=ln*Sa+Sn*ro+En*Qa+On*Ks,ct[9]=ln*ea+Sn*$a+En*Ha+On*Xs,ct[13]=ln*Ba+Sn*go+En*fs+On*zs,ct[2]=mn*ji+Hn*Ya+mr*ko+_r*os,ct[6]=mn*Sa+Hn*ro+mr*Qa+_r*Ks,ct[10]=mn*ea+Hn*$a+mr*Ha+_r*Xs,ct[14]=mn*Ba+Hn*go+mr*fs+_r*zs,ct[3]=gi*ji+Ci*Ya+$i*ko+da*os,ct[7]=gi*Sa+Ci*ro+$i*Qa+da*Ks,ct[11]=gi*ea+Ci*$a+$i*Ha+da*Xs,ct[15]=gi*Ba+Ci*go+$i*fs+da*zs,this},multiplyScalar:function(f){var E=this.elements;return E[0]*=f,E[4]*=f,E[8]*=f,E[12]*=f,E[1]*=f,E[5]*=f,E[9]*=f,E[13]*=f,E[2]*=f,E[6]*=f,E[10]*=f,E[14]*=f,E[3]*=f,E[7]*=f,E[11]*=f,E[15]*=f,this},determinant:function(){var f=this.elements,E=f[0],W=f[4],ge=f[8],ct=f[12],gt=f[1],St=f[5],Pt=f[9],sn=f[13],ln=f[2],Sn=f[6],En=f[10],On=f[14];return f[3]*(ct*Pt*Sn-ge*sn*Sn-ct*St*En+W*sn*En+ge*St*On-W*Pt*On)+f[7]*(E*Pt*On-E*sn*En+ct*gt*En-ge*gt*On+ge*sn*ln-ct*Pt*ln)+f[11]*(E*sn*Sn-E*St*On-ct*gt*Sn+W*gt*On+ct*St*ln-W*sn*ln)+f[15]*(-ge*St*ln-E*Pt*Sn+E*St*En+ge*gt*Sn-W*gt*En+W*Pt*ln)},transpose:function(){var f,E=this.elements;return f=E[1],E[1]=E[4],E[4]=f,f=E[2],E[2]=E[8],E[8]=f,f=E[6],E[6]=E[9],E[9]=f,f=E[3],E[3]=E[12],E[12]=f,f=E[7],E[7]=E[13],E[13]=f,f=E[11],E[11]=E[14],E[14]=f,this},setPosition:function(f,E,W){var ge=this.elements;return f.isVector3?(ge[12]=f.x,ge[13]=f.y,ge[14]=f.z):(ge[12]=f,ge[13]=E,ge[14]=W),this},getInverse:function(f,E){var W=this.elements,ge=f.elements,ct=ge[0],gt=ge[1],St=ge[2],Pt=ge[3],sn=ge[4],ln=ge[5],Sn=ge[6],En=ge[7],On=ge[8],mn=ge[9],Hn=ge[10],mr=ge[11],_r=ge[12],gi=ge[13],Ci=ge[14],$i=ge[15],da=mn*Ci*En-gi*Hn*En+gi*Sn*mr-ln*Ci*mr-mn*Sn*$i+ln*Hn*$i,ji=_r*Hn*En-On*Ci*En-_r*Sn*mr+sn*Ci*mr+On*Sn*$i-sn*Hn*$i,Sa=On*gi*En-_r*mn*En+_r*ln*mr-sn*gi*mr-On*ln*$i+sn*mn*$i,ea=_r*mn*Sn-On*gi*Sn-_r*ln*Hn+sn*gi*Hn+On*ln*Ci-sn*mn*Ci,Ba=ct*da+gt*ji+St*Sa+Pt*ea;if(Ba==0){var Ya="THREE.Matrix4: .getInverse() can't invert matrix, determinant is 0";if(E===!0)throw new Error(Ya);return console.warn(Ya),this.identity()}var ro=1/Ba;return W[0]=da*ro,W[1]=(gi*Hn*Pt-mn*Ci*Pt-gi*St*mr+gt*Ci*mr+mn*St*$i-gt*Hn*$i)*ro,W[2]=(ln*Ci*Pt-gi*Sn*Pt+gi*St*En-gt*Ci*En-ln*St*$i+gt*Sn*$i)*ro,W[3]=(mn*Sn*Pt-ln*Hn*Pt-mn*St*En+gt*Hn*En+ln*St*mr-gt*Sn*mr)*ro,W[4]=ji*ro,W[5]=(On*Ci*Pt-_r*Hn*Pt+_r*St*mr-ct*Ci*mr-On*St*$i+ct*Hn*$i)*ro,W[6]=(_r*Sn*Pt-sn*Ci*Pt-_r*St*En+ct*Ci*En+sn*St*$i-ct*Sn*$i)*ro,W[7]=(sn*Hn*Pt-On*Sn*Pt+On*St*En-ct*Hn*En-sn*St*mr+ct*Sn*mr)*ro,W[8]=Sa*ro,W[9]=(_r*mn*Pt-On*gi*Pt-_r*gt*mr+ct*gi*mr+On*gt*$i-ct*mn*$i)*ro,W[10]=(sn*gi*Pt-_r*ln*Pt+_r*gt*En-ct*gi*En-sn*gt*$i+ct*ln*$i)*ro,W[11]=(On*ln*Pt-sn*mn*Pt-On*gt*En+ct*mn*En+sn*gt*mr-ct*ln*mr)*ro,W[12]=ea*ro,W[13]=(On*gi*St-_r*mn*St+_r*gt*Hn-ct*gi*Hn-On*gt*Ci+ct*mn*Ci)*ro,W[14]=(_r*ln*St-sn*gi*St-_r*gt*Sn+ct*gi*Sn+sn*gt*Ci-ct*ln*Ci)*ro,W[15]=(sn*mn*St-On*ln*St+On*gt*Sn-ct*mn*Sn-sn*gt*Hn+ct*ln*Hn)*ro,this},scale:function(f){var E=this.elements,W=f.x,ge=f.y,ct=f.z;return E[0]*=W,E[4]*=ge,E[8]*=ct,E[1]*=W,E[5]*=ge,E[9]*=ct,E[2]*=W,E[6]*=ge,E[10]*=ct,E[3]*=W,E[7]*=ge,E[11]*=ct,this},getMaxScaleOnAxis:function(){var f=this.elements,E=f[0]*f[0]+f[1]*f[1]+f[2]*f[2],W=f[4]*f[4]+f[5]*f[5]+f[6]*f[6],ge=f[8]*f[8]+f[9]*f[9]+f[10]*f[10];return Math.sqrt(Math.max(E,W,ge))},makeTranslation:function(f,E,W){return this.set(1,0,0,f,0,1,0,E,0,0,1,W,0,0,0,1),this},makeRotationX:function(f){var E=Math.cos(f),W=Math.sin(f);return this.set(1,0,0,0,0,E,-W,0,0,W,E,0,0,0,0,1),this},makeRotationY:function(f){var E=Math.cos(f),W=Math.sin(f);return this.set(E,0,W,0,0,1,0,0,-W,0,E,0,0,0,0,1),this},makeRotationZ:function(f){var E=Math.cos(f),W=Math.sin(f);return this.set(E,-W,0,0,W,E,0,0,0,0,1,0,0,0,0,1),this},makeRotationAxis:function(f,E){var W=Math.cos(E),ge=Math.sin(E),ct=1-W,gt=f.x,St=f.y,Pt=f.z,sn=ct*gt,ln=ct*St;return this.set(sn*gt+W,sn*St-ge*Pt,sn*Pt+ge*St,0,sn*St+ge*Pt,ln*St+W,ln*Pt-ge*gt,0,sn*Pt-ge*St,ln*Pt+ge*gt,ct*Pt*Pt+W,0,0,0,0,1),this},makeScale:function(f,E,W){return this.set(f,0,0,0,0,E,0,0,0,0,W,0,0,0,0,1),this},makeShear:function(f,E,W){return this.set(1,E,W,0,f,1,W,0,f,E,1,0,0,0,0,1),this},compose:function(f,E,W){var ge=this.elements,ct=E._x,gt=E._y,St=E._z,Pt=E._w,sn=ct+ct,ln=gt+gt,Sn=St+St,En=ct*sn,On=ct*ln,mn=ct*Sn,Hn=gt*ln,mr=gt*Sn,_r=St*Sn,gi=Pt*sn,Ci=Pt*ln,$i=Pt*Sn,da=W.x,ji=W.y,Sa=W.z;return ge[0]=(1-(Hn+_r))*da,ge[1]=(On+$i)*da,ge[2]=(mn-Ci)*da,ge[3]=0,ge[4]=(On-$i)*ji,ge[5]=(1-(En+_r))*ji,ge[6]=(mr+gi)*ji,ge[7]=0,ge[8]=(mn+Ci)*Sa,ge[9]=(mr-gi)*Sa,ge[10]=(1-(En+Hn))*Sa,ge[11]=0,ge[12]=f.x,ge[13]=f.y,ge[14]=f.z,ge[15]=1,this},decompose:function(f,E,W){var ge=this.elements,ct=mc.set(ge[0],ge[1],ge[2]).length(),gt=mc.set(ge[4],ge[5],ge[6]).length(),St=mc.set(ge[8],ge[9],ge[10]).length();this.determinant()<0&&(ct=-ct),f.x=ge[12],f.y=ge[13],f.z=ge[14],Su.copy(this);var Pt=1/ct,sn=1/gt,ln=1/St;return Su.elements[0]*=Pt,Su.elements[1]*=Pt,Su.elements[2]*=Pt,Su.elements[4]*=sn,Su.elements[5]*=sn,Su.elements[6]*=sn,Su.elements[8]*=ln,Su.elements[9]*=ln,Su.elements[10]*=ln,E.setFromRotationMatrix(Su),W.x=ct,W.y=gt,W.z=St,this},makePerspective:function(f,E,W,ge,ct,gt){gt===void 0&&console.warn("THREE.Matrix4: .makePerspective() has been redefined and has a new signature. Please check the docs.");var St=this.elements,Pt=2*ct/(E-f),sn=2*ct/(W-ge),ln=(E+f)/(E-f),Sn=(W+ge)/(W-ge),En=-(gt+ct)/(gt-ct),On=-2*gt*ct/(gt-ct);return St[0]=Pt,St[4]=0,St[8]=ln,St[12]=0,St[1]=0,St[5]=sn,St[9]=Sn,St[13]=0,St[2]=0,St[6]=0,St[10]=En,St[14]=On,St[3]=0,St[7]=0,St[11]=-1,St[15]=0,this},makeOrthographic:function(f,E,W,ge,ct,gt){var St=this.elements,Pt=1/(E-f),sn=1/(W-ge),ln=1/(gt-ct),Sn=(E+f)*Pt,En=(W+ge)*sn,On=(gt+ct)*ln;return St[0]=2*Pt,St[4]=0,St[8]=0,St[12]=-Sn,St[1]=0,St[5]=2*sn,St[9]=0,St[13]=-En,St[2]=0,St[6]=0,St[10]=-2*ln,St[14]=-On,St[3]=0,St[7]=0,St[11]=0,St[15]=1,this},equals:function(f){for(var E=this.elements,W=f.elements,ge=0;ge<16;ge++)if(E[ge]!==W[ge])return!1;return!0},fromArray:function(f,E){E===void 0&&(E=0);for(var W=0;W<16;W++)this.elements[W]=f[W+E];return this},toArray:function(f,E){f===void 0&&(f=[]),E===void 0&&(E=0);var W=this.elements;return f[E]=W[0],f[E+1]=W[1],f[E+2]=W[2],f[E+3]=W[3],f[E+4]=W[4],f[E+5]=W[5],f[E+6]=W[6],f[E+7]=W[7],f[E+8]=W[8],f[E+9]=W[9],f[E+10]=W[10],f[E+11]=W[11],f[E+12]=W[12],f[E+13]=W[13],f[E+14]=W[14],f[E+15]=W[15],f}});var iu=new Vo,Tu=new Wu;function wt(f,E,W,ge){this._x=f||0,this._y=E||0,this._z=W||0,this._order=ge||wt.DefaultOrder}function qt(){this.mask=1}wt.RotationOrders=["XYZ","YZX","ZXY","XZY","YXZ","ZYX"],wt.DefaultOrder="XYZ",Object.defineProperties(wt.prototype,{x:{get:function(){return this._x},set:function(f){this._x=f,this._onChangeCallback()}},y:{get:function(){return this._y},set:function(f){this._y=f,this._onChangeCallback()}},z:{get:function(){return this._z},set:function(f){this._z=f,this._onChangeCallback()}},order:{get:function(){return this._order},set:function(f){this._order=f,this._onChangeCallback()}}}),Object.assign(wt.prototype,{isEuler:!0,set:function(f,E,W,ge){return this._x=f,this._y=E,this._z=W,this._order=ge||this._order,this._onChangeCallback(),this},clone:function(){return new this.constructor(this._x,this._y,this._z,this._order)},copy:function(f){return this._x=f._x,this._y=f._y,this._z=f._z,this._order=f._order,this._onChangeCallback(),this},setFromRotationMatrix:function(f,E,W){var ge=js.clamp,ct=f.elements,gt=ct[0],St=ct[4],Pt=ct[8],sn=ct[1],ln=ct[5],Sn=ct[9],En=ct[2],On=ct[6],mn=ct[10];return(E=E||this._order)==="XYZ"?(this._y=Math.asin(ge(Pt,-1,1)),Math.abs(Pt)<.9999999?(this._x=Math.atan2(-Sn,mn),this._z=Math.atan2(-St,gt)):(this._x=Math.atan2(On,ln),this._z=0)):E==="YXZ"?(this._x=Math.asin(-ge(Sn,-1,1)),Math.abs(Sn)<.9999999?(this._y=Math.atan2(Pt,mn),this._z=Math.atan2(sn,ln)):(this._y=Math.atan2(-En,gt),this._z=0)):E==="ZXY"?(this._x=Math.asin(ge(On,-1,1)),Math.abs(On)<.9999999?(this._y=Math.atan2(-En,mn),this._z=Math.atan2(-St,ln)):(this._y=0,this._z=Math.atan2(sn,gt))):E==="ZYX"?(this._y=Math.asin(-ge(En,-1,1)),Math.abs(En)<.9999999?(this._x=Math.atan2(On,mn),this._z=Math.atan2(sn,gt)):(this._x=0,this._z=Math.atan2(-St,ln))):E==="YZX"?(this._z=Math.asin(ge(sn,-1,1)),Math.abs(sn)<.9999999?(this._x=Math.atan2(-Sn,ln),this._y=Math.atan2(-En,gt)):(this._x=0,this._y=Math.atan2(Pt,mn))):E==="XZY"?(this._z=Math.asin(-ge(St,-1,1)),Math.abs(St)<.9999999?(this._x=Math.atan2(On,ln),this._y=Math.atan2(Pt,gt)):(this._x=Math.atan2(-Sn,mn),this._y=0)):console.warn("THREE.Euler: .setFromRotationMatrix() given unsupported order: "+E),this._order=E,W!==!1&&this._onChangeCallback(),this},setFromQuaternion:function(f,E,W){return iu.makeRotationFromQuaternion(f),this.setFromRotationMatrix(iu,E,W)},setFromVector3:function(f,E){return this.set(f.x,f.y,f.z,E||this._order)},reorder:function(f){return Tu.setFromEuler(this),this.setFromQuaternion(Tu,f)},equals:function(f){return f._x===this._x&&f._y===this._y&&f._z===this._z&&f._order===this._order},fromArray:function(f){return this._x=f[0],this._y=f[1],this._z=f[2],f[3]!==void 0&&(this._order=f[3]),this._onChangeCallback(),this},toArray:function(f,E){return f===void 0&&(f=[]),E===void 0&&(E=0),f[E]=this._x,f[E+1]=this._y,f[E+2]=this._z,f[E+3]=this._order,f},toVector3:function(f){return f?f.set(this._x,this._y,this._z):new yi(this._x,this._y,this._z)},_onChange:function(f){return this._onChangeCallback=f,this},_onChangeCallback:function(){}}),Object.assign(qt.prototype,{set:function(f){this.mask=1<<f|0},enable:function(f){this.mask|=1<<f|0},enableAll:function(){this.mask=-1},toggle:function(f){this.mask^=1<<f|0},disable:function(f){this.mask&=~(1<<f|0)},disableAll:function(){this.mask=0},test:function(f){return(this.mask&f.mask)!=0}});var Cn=0,Pn=new yi,Qe=new Wu,yt=new Vo,Rt=new yi,jt=new yi,dn=new yi,yn=new Wu,In=new yi(1,0,0),vr=new yi(0,1,0),Jn=new yi(0,0,1),li={type:"added"},xa={type:"removed"};function Ri(){Object.defineProperty(this,"id",{value:Cn++}),this.uuid=js.generateUUID(),this.name="",this.type="Object3D",this.parent=null,this.children=[],this.up=Ri.DefaultUp.clone();var f=new yi,E=new wt,W=new Wu,ge=new yi(1,1,1);E._onChange(function(){W.setFromEuler(E,!1)}),W._onChange(function(){E.setFromQuaternion(W,void 0,!1)}),Object.defineProperties(this,{position:{configurable:!0,enumerable:!0,value:f},rotation:{configurable:!0,enumerable:!0,value:E},quaternion:{configurable:!0,enumerable:!0,value:W},scale:{configurable:!0,enumerable:!0,value:ge},modelViewMatrix:{value:new Vo},normalMatrix:{value:new Vl}}),this.matrix=new Vo,this.matrixWorld=new Vo,this.matrixAutoUpdate=Ri.DefaultMatrixAutoUpdate,this.matrixWorldNeedsUpdate=!1,this.layers=new qt,this.visible=!0,this.castShadow=!1,this.receiveShadow=!1,this.frustumCulled=!0,this.renderOrder=0,this.userData={}}function fa(){Ri.call(this),this.type="Scene",this.background=null,this.environment=null,this.fog=null,this.overrideMaterial=null,this.autoUpdate=!0,typeof __THREE_DEVTOOLS__<"u"&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe",{detail:this}))}Ri.DefaultUp=new yi(0,1,0),Ri.DefaultMatrixAutoUpdate=!0,Ri.prototype=Object.assign(Object.create(Ku.prototype),{constructor:Ri,isObject3D:!0,onBeforeRender:function(){},onAfterRender:function(){},applyMatrix4:function(f){this.matrixAutoUpdate&&this.updateMatrix(),this.matrix.premultiply(f),this.matrix.decompose(this.position,this.quaternion,this.scale)},applyQuaternion:function(f){return this.quaternion.premultiply(f),this},setRotationFromAxisAngle:function(f,E){this.quaternion.setFromAxisAngle(f,E)},setRotationFromEuler:function(f){this.quaternion.setFromEuler(f,!0)},setRotationFromMatrix:function(f){this.quaternion.setFromRotationMatrix(f)},setRotationFromQuaternion:function(f){this.quaternion.copy(f)},rotateOnAxis:function(f,E){return Qe.setFromAxisAngle(f,E),this.quaternion.multiply(Qe),this},rotateOnWorldAxis:function(f,E){return Qe.setFromAxisAngle(f,E),this.quaternion.premultiply(Qe),this},rotateX:function(f){return this.rotateOnAxis(In,f)},rotateY:function(f){return this.rotateOnAxis(vr,f)},rotateZ:function(f){return this.rotateOnAxis(Jn,f)},translateOnAxis:function(f,E){return Pn.copy(f).applyQuaternion(this.quaternion),this.position.add(Pn.multiplyScalar(E)),this},translateX:function(f){return this.translateOnAxis(In,f)},translateY:function(f){return this.translateOnAxis(vr,f)},translateZ:function(f){return this.translateOnAxis(Jn,f)},localToWorld:function(f){return f.applyMatrix4(this.matrixWorld)},worldToLocal:function(f){return f.applyMatrix4(yt.getInverse(this.matrixWorld))},lookAt:function(f,E,W){f.isVector3?Rt.copy(f):Rt.set(f,E,W);var ge=this.parent;this.updateWorldMatrix(!0,!1),jt.setFromMatrixPosition(this.matrixWorld),this.isCamera||this.isLight?yt.lookAt(jt,Rt,this.up):yt.lookAt(Rt,jt,this.up),this.quaternion.setFromRotationMatrix(yt),ge&&(yt.extractRotation(ge.matrixWorld),Qe.setFromRotationMatrix(yt),this.quaternion.premultiply(Qe.inverse()))},add:function(f){if(1<arguments.length){for(var E=0;E<arguments.length;E++)this.add(arguments[E]);return this}return f===this?console.error("THREE.Object3D.add: object can't be added as a child of itself.",f):f&&f.isObject3D?(f.parent!==null&&f.parent.remove(f),(f.parent=this).children.push(f),f.dispatchEvent(li)):console.error("THREE.Object3D.add: object not an instance of THREE.Object3D.",f),this},remove:function(f){if(1<arguments.length){for(var E=0;E<arguments.length;E++)this.remove(arguments[E]);return this}var W=this.children.indexOf(f);return W!==-1&&(f.parent=null,this.children.splice(W,1),f.dispatchEvent(xa)),this},attach:function(f){return this.updateWorldMatrix(!0,!1),yt.getInverse(this.matrixWorld),f.parent!==null&&(f.parent.updateWorldMatrix(!0,!1),yt.multiply(f.parent.matrixWorld)),f.applyMatrix4(yt),f.updateWorldMatrix(!1,!1),this.add(f),this},getObjectById:function(f){return this.getObjectByProperty("id",f)},getObjectByName:function(f){return this.getObjectByProperty("name",f)},getObjectByProperty:function(f,E){if(this[f]===E)return this;for(var W=0,ge=this.children.length;W<ge;W++){var ct=this.children[W].getObjectByProperty(f,E);if(ct!==void 0)return ct}},getWorldPosition:function(f){return f===void 0&&(console.warn("THREE.Object3D: .getWorldPosition() target is now required"),f=new yi),this.updateMatrixWorld(!0),f.setFromMatrixPosition(this.matrixWorld)},getWorldQuaternion:function(f){return f===void 0&&(console.warn("THREE.Object3D: .getWorldQuaternion() target is now required"),f=new Wu),this.updateMatrixWorld(!0),this.matrixWorld.decompose(jt,f,dn),f},getWorldScale:function(f){return f===void 0&&(console.warn("THREE.Object3D: .getWorldScale() target is now required"),f=new yi),this.updateMatrixWorld(!0),this.matrixWorld.decompose(jt,yn,f),f},getWorldDirection:function(f){f===void 0&&(console.warn("THREE.Object3D: .getWorldDirection() target is now required"),f=new yi),this.updateMatrixWorld(!0);var E=this.matrixWorld.elements;return f.set(E[8],E[9],E[10]).normalize()},raycast:function(){},traverse:function(f){f(this);for(var E=this.children,W=0,ge=E.length;W<ge;W++)E[W].traverse(f)},traverseVisible:function(f){if(this.visible!==!1){f(this);for(var E=this.children,W=0,ge=E.length;W<ge;W++)E[W].traverseVisible(f)}},traverseAncestors:function(f){var E=this.parent;E!==null&&(f(E),E.traverseAncestors(f))},updateMatrix:function(){this.matrix.compose(this.position,this.quaternion,this.scale),this.matrixWorldNeedsUpdate=!0},updateMatrixWorld:function(f){this.matrixAutoUpdate&&this.updateMatrix(),(this.matrixWorldNeedsUpdate||f)&&(this.parent===null?this.matrixWorld.copy(this.matrix):this.matrixWorld.multiplyMatrices(this.parent.matrixWorld,this.matrix),f=!(this.matrixWorldNeedsUpdate=!1));for(var E=this.children,W=0,ge=E.length;W<ge;W++)E[W].updateMatrixWorld(f)},updateWorldMatrix:function(f,E){var W=this.parent;if(f===!0&&W!==null&&W.updateWorldMatrix(!0,!1),this.matrixAutoUpdate&&this.updateMatrix(),this.parent===null?this.matrixWorld.copy(this.matrix):this.matrixWorld.multiplyMatrices(this.parent.matrixWorld,this.matrix),E===!0)for(var ge=this.children,ct=0,gt=ge.length;ct<gt;ct++)ge[ct].updateWorldMatrix(!1,!0)},toJSON:function(f){var E=f===void 0||typeof f=="string",W={};E&&(f={geometries:{},materials:{},textures:{},images:{},shapes:{}},W.metadata={version:4.5,type:"Object",generator:"Object3D.toJSON"});var ge={};function ct(_r,gi){return _r[gi.uuid]===void 0&&(_r[gi.uuid]=gi.toJSON(f)),gi.uuid}if(ge.uuid=this.uuid,ge.type=this.type,this.name!==""&&(ge.name=this.name),this.castShadow===!0&&(ge.castShadow=!0),this.receiveShadow===!0&&(ge.receiveShadow=!0),this.visible===!1&&(ge.visible=!1),this.frustumCulled===!1&&(ge.frustumCulled=!1),this.renderOrder!==0&&(ge.renderOrder=this.renderOrder),JSON.stringify(this.userData)!=="{}"&&(ge.userData=this.userData),ge.layers=this.layers.mask,ge.matrix=this.matrix.toArray(),this.matrixAutoUpdate===!1&&(ge.matrixAutoUpdate=!1),this.isInstancedMesh&&(ge.type="InstancedMesh",ge.count=this.count,ge.instanceMatrix=this.instanceMatrix.toJSON()),this.isMesh||this.isLine||this.isPoints){ge.geometry=ct(f.geometries,this.geometry);var gt=this.geometry.parameters;if(gt!==void 0&>.shapes!==void 0){var St=gt.shapes;if(Array.isArray(St))for(var Pt=0,sn=St.length;Pt<sn;Pt++){var ln=St[Pt];ct(f.shapes,ln)}else ct(f.shapes,St)}}if(this.material!==void 0)if(Array.isArray(this.material)){var Sn=[];for(Pt=0,sn=this.material.length;Pt<sn;Pt++)Sn.push(ct(f.materials,this.material[Pt]));ge.material=Sn}else ge.material=ct(f.materials,this.material);if(0<this.children.length)for(ge.children=[],Pt=0;Pt<this.children.length;Pt++)ge.children.push(this.children[Pt].toJSON(f).object);if(E){var En=mr(f.geometries),On=mr(f.materials),mn=mr(f.textures),Hn=mr(f.images);St=mr(f.shapes),0<En.length&&(W.geometries=En),0<On.length&&(W.materials=On),0<mn.length&&(W.textures=mn),0<Hn.length&&(W.images=Hn),0<St.length&&(W.shapes=St)}return W.object=ge,W;function mr(_r){var gi=[];for(var Ci in _r){var $i=_r[Ci];delete $i.metadata,gi.push($i)}return gi}},clone:function(f){return new this.constructor().copy(this,f)},copy:function(f,E){if(E===void 0&&(E=!0),this.name=f.name,this.up.copy(f.up),this.position.copy(f.position),this.quaternion.copy(f.quaternion),this.scale.copy(f.scale),this.matrix.copy(f.matrix),this.matrixWorld.copy(f.matrixWorld),this.matrixAutoUpdate=f.matrixAutoUpdate,this.matrixWorldNeedsUpdate=f.matrixWorldNeedsUpdate,this.layers.mask=f.layers.mask,this.visible=f.visible,this.castShadow=f.castShadow,this.receiveShadow=f.receiveShadow,this.frustumCulled=f.frustumCulled,this.renderOrder=f.renderOrder,this.userData=JSON.parse(JSON.stringify(f.userData)),E===!0)for(var W=0;W<f.children.length;W++){var ge=f.children[W];this.add(ge.clone())}return this}}),fa.prototype=Object.assign(Object.create(Ri.prototype),{constructor:fa,isScene:!0,copy:function(f,E){return Ri.prototype.copy.call(this,f,E),f.background!==null&&(this.background=f.background.clone()),f.environment!==null&&(this.environment=f.environment.clone()),f.fog!==null&&(this.fog=f.fog.clone()),f.overrideMaterial!==null&&(this.overrideMaterial=f.overrideMaterial.clone()),this.autoUpdate=f.autoUpdate,this.matrixAutoUpdate=f.matrixAutoUpdate,this},toJSON:function(f){var E=Ri.prototype.toJSON.call(this,f);return this.background!==null&&(E.object.background=this.background.toJSON(f)),this.environment!==null&&(E.object.environment=this.environment.toJSON(f)),this.fog!==null&&(E.object.fog=this.fog.toJSON()),E},dispose:function(){this.dispatchEvent({type:"dispose"})}});var oo=[new yi,new yi,new yi,new yi,new yi,new yi,new yi,new yi],ts=new yi,bl=new Xu,nl=new yi,Fs=new yi,eu=new yi,Gs=new yi,As=new yi,yl=new yi,Lc=new yi,vl=new yi,du=new yi,ac=new yi;function Xu(f,E){this.min=f!==void 0?f:new yi(1/0,1/0,1/0),this.max=E!==void 0?E:new yi(-1/0,-1/0,-1/0)}function Ju(f,E,W,ge,ct){var gt,St;for(gt=0,St=f.length-3;gt<=St;gt+=3){ac.fromArray(f,gt);var Pt=ct.x*Math.abs(ac.x)+ct.y*Math.abs(ac.y)+ct.z*Math.abs(ac.z),sn=E.dot(ac),ln=W.dot(ac),Sn=ge.dot(ac);if(Math.max(-Math.max(sn,ln,Sn),Math.min(sn,ln,Sn))>Pt)return!1}return!0}Object.assign(Xu.prototype,{isBox3:!0,set:function(f,E){return this.min.copy(f),this.max.copy(E),this},setFromArray:function(f){for(var E=1/0,W=1/0,ge=1/0,ct=-1/0,gt=-1/0,St=-1/0,Pt=0,sn=f.length;Pt<sn;Pt+=3){var ln=f[Pt],Sn=f[Pt+1],En=f[Pt+2];ln<E&&(E=ln),Sn<W&&(W=Sn),En<ge&&(ge=En),ct<ln&&(ct=ln),gt<Sn&&(gt=Sn),St<En&&(St=En)}return this.min.set(E,W,ge),this.max.set(ct,gt,St),this},setFromBufferAttribute:function(f){for(var E=1/0,W=1/0,ge=1/0,ct=-1/0,gt=-1/0,St=-1/0,Pt=0,sn=f.count;Pt<sn;Pt++){var ln=f.getX(Pt),Sn=f.getY(Pt),En=f.getZ(Pt);ln<E&&(E=ln),Sn<W&&(W=Sn),En<ge&&(ge=En),ct<ln&&(ct=ln),gt<Sn&&(gt=Sn),St<En&&(St=En)}return this.min.set(E,W,ge),this.max.set(ct,gt,St),this},setFromPoints:function(f){this.makeEmpty();for(var E=0,W=f.length;E<W;E++)this.expandByPoint(f[E]);return this},setFromCenterAndSize:function(f,E){var W=ts.copy(E).multiplyScalar(.5);return this.min.copy(f).sub(W),this.max.copy(f).add(W),this},setFromObject:function(f){return this.makeEmpty(),this.expandByObject(f)},clone:function(){return new this.constructor().copy(this)},copy:function(f){return this.min.copy(f.min),this.max.copy(f.max),this},makeEmpty:function(){return this.min.x=this.min.y=this.min.z=1/0,this.max.x=this.max.y=this.max.z=-1/0,this},isEmpty:function(){return this.max.x<this.min.x||this.max.y<this.min.y||this.max.z<this.min.z},getCenter:function(f){return f===void 0&&(console.warn("THREE.Box3: .getCenter() target is now required"),f=new yi),this.isEmpty()?f.set(0,0,0):f.addVectors(this.min,this.max).multiplyScalar(.5)},getSize:function(f){return f===void 0&&(console.warn("THREE.Box3: .getSize() target is now required"),f=new yi),this.isEmpty()?f.set(0,0,0):f.subVectors(this.max,this.min)},expandByPoint:function(f){return this.min.min(f),this.max.max(f),this},expandByVector:function(f){return this.min.sub(f),this.max.add(f),this},expandByScalar:function(f){return this.min.addScalar(-f),this.max.addScalar(f),this},expandByObject:function(f){f.updateWorldMatrix(!1,!1);var E=f.geometry;E!==void 0&&(E.boundingBox===null&&E.computeBoundingBox(),bl.copy(E.boundingBox),bl.applyMatrix4(f.matrixWorld),this.expandByPoint(bl.min),this.expandByPoint(bl.max));for(var W=f.children,ge=0,ct=W.length;ge<ct;ge++)this.expandByObject(W[ge]);return this},containsPoint:function(f){return!(f.x<this.min.x||f.x>this.max.x||f.y<this.min.y||f.y>this.max.y||f.z<this.min.z||f.z>this.max.z)},containsBox:function(f){return this.min.x<=f.min.x&&f.max.x<=this.max.x&&this.min.y<=f.min.y&&f.max.y<=this.max.y&&this.min.z<=f.min.z&&f.max.z<=this.max.z},getParameter:function(f,E){return E===void 0&&(console.warn("THREE.Box3: .getParameter() target is now required"),E=new yi),E.set((f.x-this.min.x)/(this.max.x-this.min.x),(f.y-this.min.y)/(this.max.y-this.min.y),(f.z-this.min.z)/(this.max.z-this.min.z))},intersectsBox:function(f){return!(f.max.x<this.min.x||f.min.x>this.max.x||f.max.y<this.min.y||f.min.y>this.max.y||f.max.z<this.min.z||f.min.z>this.max.z)},intersectsSphere:function(f){return this.clampPoint(f.center,ts),ts.distanceToSquared(f.center)<=f.radius*f.radius},intersectsPlane:function(f){var E,W;return W=0<f.normal.x?(E=f.normal.x*this.min.x,f.normal.x*this.max.x):(E=f.normal.x*this.max.x,f.normal.x*this.min.x),0<f.normal.y?(E+=f.normal.y*this.min.y,W+=f.normal.y*this.max.y):(E+=f.normal.y*this.max.y,W+=f.normal.y*this.min.y),0<f.normal.z?(E+=f.normal.z*this.min.z,W+=f.normal.z*this.max.z):(E+=f.normal.z*this.max.z,W+=f.normal.z*this.min.z),E<=-f.constant&&W>=-f.constant},intersectsTriangle:function(f){if(this.isEmpty())return!1;this.getCenter(Lc),vl.subVectors(this.max,Lc),nl.subVectors(f.a,Lc),Fs.subVectors(f.b,Lc),eu.subVectors(f.c,Lc),Gs.subVectors(Fs,nl),As.subVectors(eu,Fs),yl.subVectors(nl,eu);var E=[0,-Gs.z,Gs.y,0,-As.z,As.y,0,-yl.z,yl.y,Gs.z,0,-Gs.x,As.z,0,-As.x,yl.z,0,-yl.x,-Gs.y,Gs.x,0,-As.y,As.x,0,-yl.y,yl.x,0];return!!Ju(E,nl,Fs,eu,vl)&&!!Ju(E=[1,0,0,0,1,0,0,0,1],nl,Fs,eu,vl)&&(du.crossVectors(Gs,As),Ju(E=[du.x,du.y,du.z],nl,Fs,eu,vl))},clampPoint:function(f,E){return E===void 0&&(console.warn("THREE.Box3: .clampPoint() target is now required"),E=new yi),E.copy(f).clamp(this.min,this.max)},distanceToPoint:function(f){return ts.copy(f).clamp(this.min,this.max).sub(f).length()},getBoundingSphere:function(f){return f===void 0&&console.error("THREE.Box3: .getBoundingSphere() target is now required"),this.getCenter(f.center),f.radius=.5*this.getSize(ts).length(),f},intersect:function(f){return this.min.max(f.min),this.max.min(f.max),this.isEmpty()&&this.makeEmpty(),this},union:function(f){return this.min.min(f.min),this.max.max(f.max),this},applyMatrix4:function(f){return this.isEmpty()||(oo[0].set(this.min.x,this.min.y,this.min.z).applyMatrix4(f),oo[1].set(this.min.x,this.min.y,this.max.z).applyMatrix4(f),oo[2].set(this.min.x,this.max.y,this.min.z).applyMatrix4(f),oo[3].set(this.min.x,this.max.y,this.max.z).applyMatrix4(f),oo[4].set(this.max.x,this.min.y,this.min.z).applyMatrix4(f),oo[5].set(this.max.x,this.min.y,this.max.z).applyMatrix4(f),oo[6].set(this.max.x,this.max.y,this.min.z).applyMatrix4(f),oo[7].set(this.max.x,this.max.y,this.max.z).applyMatrix4(f),this.setFromPoints(oo)),this},translate:function(f){return this.min.add(f),this.max.add(f),this},equals:function(f){return f.min.equals(this.min)&&f.max.equals(this.max)}});var Vu=new Xu;function Nl(f,E){this.center=f!==void 0?f:new yi,this.radius=E!==void 0?E:0}Object.assign(Nl.prototype,{set:function(f,E){return this.center.copy(f),this.radius=E,this},setFromPoints:function(f,E){var W=this.center;E!==void 0?W.copy(E):Vu.setFromPoints(f).getCenter(W);for(var ge=0,ct=0,gt=f.length;ct<gt;ct++)ge=Math.max(ge,W.distanceToSquared(f[ct]));return this.radius=Math.sqrt(ge),this},clone:function(){return new this.constructor().copy(this)},copy:function(f){return this.center.copy(f.center),this.radius=f.radius,this},empty:function(){return this.radius<=0},containsPoint:function(f){return f.distanceToSquared(this.center)<=this.radius*this.radius},distanceToPoint:function(f){return f.distanceTo(this.center)-this.radius},intersectsSphere:function(f){var E=this.radius+f.radius;return f.center.distanceToSquared(this.center)<=E*E},intersectsBox:function(f){return f.intersectsSphere(this)},intersectsPlane:function(f){return Math.abs(f.distanceToPoint(this.center))<=this.radius},clampPoint:function(f,E){var W=this.center.distanceToSquared(f);return E===void 0&&(console.warn("THREE.Sphere: .clampPoint() target is now required"),E=new yi),E.copy(f),W>this.radius*this.radius&&(E.sub(this.center).normalize(),E.multiplyScalar(this.radius).add(this.center)),E},getBoundingBox:function(f){return f===void 0&&(console.warn("THREE.Sphere: .getBoundingBox() target is now required"),f=new Xu),f.set(this.center,this.center),f.expandByScalar(this.radius),f},applyMatrix4:function(f){return this.center.applyMatrix4(f),this.radius=this.radius*f.getMaxScaleOnAxis(),this},translate:function(f){return this.center.add(f),this},equals:function(f){return f.center.equals(this.center)&&f.radius===this.radius}});var $l=new yi,hu=new yi,Qu=new yi,Gu=new yi,Bs=new yi,su=new yi,ku=new yi;function Hl(f,E){this.origin=f!==void 0?f:new yi,this.direction=E!==void 0?E:new yi(0,0,-1)}Object.assign(Hl.prototype,{set:function(f,E){return this.origin.copy(f),this.direction.copy(E),this},clone:function(){return new this.constructor().copy(this)},copy:function(f){return this.origin.copy(f.origin),this.direction.copy(f.direction),this},at:function(f,E){return E===void 0&&(console.warn("THREE.Ray: .at() target is now required"),E=new yi),E.copy(this.direction).multiplyScalar(f).add(this.origin)},lookAt:function(f){return this.direction.copy(f).sub(this.origin).normalize(),this},recast:function(f){return this.origin.copy(this.at(f,$l)),this},closestPointToPoint:function(f,E){E===void 0&&(console.warn("THREE.Ray: .closestPointToPoint() target is now required"),E=new yi),E.subVectors(f,this.origin);var W=E.dot(this.direction);return W<0?E.copy(this.origin):E.copy(this.direction).multiplyScalar(W).add(this.origin)},distanceToPoint:function(f){return Math.sqrt(this.distanceSqToPoint(f))},distanceSqToPoint:function(f){var E=$l.subVectors(f,this.origin).dot(this.direction);return E<0?this.origin.distanceToSquared(f):($l.copy(this.direction).multiplyScalar(E).add(this.origin),$l.distanceToSquared(f))},distanceSqToSegment:function(f,E,W,ge){hu.copy(f).add(E).multiplyScalar(.5),Qu.copy(E).sub(f).normalize(),Gu.copy(this.origin).sub(hu);var ct,gt,St,Pt,sn=.5*f.distanceTo(E),ln=-this.direction.dot(Qu),Sn=Gu.dot(this.direction),En=-Gu.dot(Qu),On=Gu.lengthSq(),mn=Math.abs(1-ln*ln);if(0<mn)if(gt=ln*Sn-En,Pt=sn*mn,0<=(ct=ln*En-Sn))if(-Pt<=gt)if(gt<=Pt){var Hn=1/mn;St=(ct*=Hn)*(ct+ln*(gt*=Hn)+2*Sn)+gt*(ln*ct+gt+2*En)+On}else gt=sn,St=-(ct=Math.max(0,-(ln*gt+Sn)))*ct+gt*(gt+2*En)+On;else gt=-sn,St=-(ct=Math.max(0,-(ln*gt+Sn)))*ct+gt*(gt+2*En)+On;else St=gt<=-Pt?-(ct=Math.max(0,-(-ln*sn+Sn)))*ct+(gt=0<ct?-sn:Math.min(Math.max(-sn,-En),sn))*(gt+2*En)+On:gt<=Pt?(ct=0,(gt=Math.min(Math.max(-sn,-En),sn))*(gt+2*En)+On):-(ct=Math.max(0,-(ln*sn+Sn)))*ct+(gt=0<ct?sn:Math.min(Math.max(-sn,-En),sn))*(gt+2*En)+On;else gt=0<ln?-sn:sn,St=-(ct=Math.max(0,-(ln*gt+Sn)))*ct+gt*(gt+2*En)+On;return W&&W.copy(this.direction).multiplyScalar(ct).add(this.origin),ge&&ge.copy(Qu).multiplyScalar(gt).add(hu),St},intersectSphere:function(f,E){$l.subVectors(f.center,this.origin);var W=$l.dot(this.direction),ge=$l.dot($l)-W*W,ct=f.radius*f.radius;if(ct<ge)return null;var gt=Math.sqrt(ct-ge),St=W-gt,Pt=W+gt;return St<0&&Pt<0?null:St<0?this.at(Pt,E):this.at(St,E)},intersectsSphere:function(f){return this.distanceSqToPoint(f.center)<=f.radius*f.radius},distanceToPlane:function(f){var E=f.normal.dot(this.direction);if(E===0)return f.distanceToPoint(this.origin)===0?0:null;var W=-(this.origin.dot(f.normal)+f.constant)/E;return 0<=W?W:null},intersectPlane:function(f,E){var W=this.distanceToPlane(f);return W===null?null:this.at(W,E)},intersectsPlane:function(f){var E=f.distanceToPoint(this.origin);return E===0||f.normal.dot(this.direction)*E<0},intersectBox:function(f,E){var W,ge,ct,gt,St,Pt,sn=1/this.direction.x,ln=1/this.direction.y,Sn=1/this.direction.z,En=this.origin;return ge=0<=sn?(W=(f.min.x-En.x)*sn,(f.max.x-En.x)*sn):(W=(f.max.x-En.x)*sn,(f.min.x-En.x)*sn),(gt=0<=ln?(ct=(f.min.y-En.y)*ln,(f.max.y-En.y)*ln):(ct=(f.max.y-En.y)*ln,(f.min.y-En.y)*ln))<W||ge<ct?null:((W<ct||W!=W)&&(W=ct),(gt<ge||ge!=ge)&&(ge=gt),(Pt=0<=Sn?(St=(f.min.z-En.z)*Sn,(f.max.z-En.z)*Sn):(St=(f.max.z-En.z)*Sn,(f.min.z-En.z)*Sn))<W||ge<St?null:((W<St||W!=W)&&(W=St),(Pt<ge||ge!=ge)&&(ge=Pt),ge<0?null:this.at(0<=W?W:ge,E)))},intersectsBox:function(f){return this.intersectBox(f,$l)!==null},intersectTriangle:function(f,E,W,ge,ct){Bs.subVectors(E,f),su.subVectors(W,f),ku.crossVectors(Bs,su);var gt,St=this.direction.dot(ku);if(0<St){if(ge)return null;gt=1}else{if(!(St<0))return null;gt=-1,St=-St}Gu.subVectors(this.origin,f);var Pt=gt*this.direction.dot(su.crossVectors(Gu,su));if(Pt<0)return null;var sn=gt*this.direction.dot(Bs.cross(Gu));if(sn<0||St<Pt+sn)return null;var ln=-gt*Gu.dot(ku);return ln<0?null:this.at(ln/St,ct)},applyMatrix4:function(f){return this.origin.applyMatrix4(f),this.direction.transformDirection(f),this},equals:function(f){return f.origin.equals(this.origin)&&f.direction.equals(this.direction)}});var Uc=new yi,Wl=new yi,cd=new Vl;function wu(f,E){this.normal=f!==void 0?f:new yi(1,0,0),this.constant=E!==void 0?E:0}Object.assign(wu.prototype,{isPlane:!0,set:function(f,E){return this.normal.copy(f),this.constant=E,this},setComponents:function(f,E,W,ge){return this.normal.set(f,E,W),this.constant=ge,this},setFromNormalAndCoplanarPoint:function(f,E){return this.normal.copy(f),this.constant=-E.dot(this.normal),this},setFromCoplanarPoints:function(f,E,W){var ge=Uc.subVectors(W,E).cross(Wl.subVectors(f,E)).normalize();return this.setFromNormalAndCoplanarPoint(ge,f),this},clone:function(){return new this.constructor().copy(this)},copy:function(f){return this.normal.copy(f.normal),this.constant=f.constant,this},normalize:function(){var f=1/this.normal.length();return this.normal.multiplyScalar(f),this.constant*=f,this},negate:function(){return this.constant*=-1,this.normal.negate(),this},distanceToPoint:function(f){return this.normal.dot(f)+this.constant},distanceToSphere:function(f){return this.distanceToPoint(f.center)-f.radius},projectPoint:function(f,E){return E===void 0&&(console.warn("THREE.Plane: .projectPoint() target is now required"),E=new yi),E.copy(this.normal).multiplyScalar(-this.distanceToPoint(f)).add(f)},intersectLine:function(f,E){E===void 0&&(console.warn("THREE.Plane: .intersectLine() target is now required"),E=new yi);var W=f.delta(Uc),ge=this.normal.dot(W);if(ge===0)return this.distanceToPoint(f.start)===0?E.copy(f.start):void 0;var ct=-(f.start.dot(this.normal)+this.constant)/ge;return ct<0||1<ct?void 0:E.copy(W).multiplyScalar(ct).add(f.start)},intersectsLine:function(f){var E=this.distanceToPoint(f.start),W=this.distanceToPoint(f.end);return E<0&&0<W||W<0&&0<E},intersectsBox:function(f){return f.intersectsPlane(this)},intersectsSphere:function(f){return f.intersectsPlane(this)},coplanarPoint:function(f){return f===void 0&&(console.warn("THREE.Plane: .coplanarPoint() target is now required"),f=new yi),f.copy(this.normal).multiplyScalar(-this.constant)},applyMatrix4:function(f,E){var W=E||cd.getNormalMatrix(f),ge=this.coplanarPoint(Uc).applyMatrix4(f),ct=this.normal.applyMatrix3(W).normalize();return this.constant=-ge.dot(ct),this},translate:function(f){return this.constant-=f.dot(this.normal),this},equals:function(f){return f.normal.equals(this.normal)&&f.constant===this.constant}});var oc=new yi,gc=new yi,dd=new yi,Jc=new yi,sc=new yi,qc=new yi,vd=new yi,Pu=new yi,ol=new yi,od=new yi;function qu(f,E,W){this.a=f!==void 0?f:new yi,this.b=E!==void 0?E:new yi,this.c=W!==void 0?W:new yi}Object.assign(qu,{getNormal:function(f,E,W,ge){ge===void 0&&(console.warn("THREE.Triangle: .getNormal() target is now required"),ge=new yi),ge.subVectors(W,E),oc.subVectors(f,E),ge.cross(oc);var ct=ge.lengthSq();return 0<ct?ge.multiplyScalar(1/Math.sqrt(ct)):ge.set(0,0,0)},getBarycoord:function(f,E,W,ge,ct){oc.subVectors(ge,E),gc.subVectors(W,E),dd.subVectors(f,E);var gt=oc.dot(oc),St=oc.dot(gc),Pt=oc.dot(dd),sn=gc.dot(gc),ln=gc.dot(dd),Sn=gt*sn-St*St;if(ct===void 0&&(console.warn("THREE.Triangle: .getBarycoord() target is now required"),ct=new yi),Sn==0)return ct.set(-2,-1,-1);var En=1/Sn,On=(sn*Pt-St*ln)*En,mn=(gt*ln-St*Pt)*En;return ct.set(1-On-mn,mn,On)},containsPoint:function(f,E,W,ge){return qu.getBarycoord(f,E,W,ge,Jc),0<=Jc.x&&0<=Jc.y&&Jc.x+Jc.y<=1},getUV:function(f,E,W,ge,ct,gt,St,Pt){return this.getBarycoord(f,E,W,ge,Jc),Pt.set(0,0),Pt.addScaledVector(ct,Jc.x),Pt.addScaledVector(gt,Jc.y),Pt.addScaledVector(St,Jc.z),Pt},isFrontFacing:function(f,E,W,ge){return oc.subVectors(W,E),gc.subVectors(f,E),oc.cross(gc).dot(ge)<0}}),Object.assign(qu.prototype,{set:function(f,E,W){return this.a.copy(f),this.b.copy(E),this.c.copy(W),this},setFromPointsAndIndices:function(f,E,W,ge){return this.a.copy(f[E]),this.b.copy(f[W]),this.c.copy(f[ge]),this},clone:function(){return new this.constructor().copy(this)},copy:function(f){return this.a.copy(f.a),this.b.copy(f.b),this.c.copy(f.c),this},getArea:function(){return oc.subVectors(this.c,this.b),gc.subVectors(this.a,this.b),.5*oc.cross(gc).length()},getMidpoint:function(f){return f===void 0&&(console.warn("THREE.Triangle: .getMidpoint() target is now required"),f=new yi),f.addVectors(this.a,this.b).add(this.c).multiplyScalar(1/3)},getNormal:function(f){return qu.getNormal(this.a,this.b,this.c,f)},getPlane:function(f){return f===void 0&&(console.warn("THREE.Triangle: .getPlane() target is now required"),f=new wu),f.setFromCoplanarPoints(this.a,this.b,this.c)},getBarycoord:function(f,E){return qu.getBarycoord(f,this.a,this.b,this.c,E)},getUV:function(f,E,W,ge,ct){return qu.getUV(f,this.a,this.b,this.c,E,W,ge,ct)},containsPoint:function(f){return qu.containsPoint(f,this.a,this.b,this.c)},isFrontFacing:function(f){return qu.isFrontFacing(this.a,this.b,this.c,f)},intersectsBox:function(f){return f.intersectsTriangle(this)},closestPointToPoint:function(f,E){E===void 0&&(console.warn("THREE.Triangle: .closestPointToPoint() target is now required"),E=new yi);var W,ge,ct=this.a,gt=this.b,St=this.c;sc.subVectors(gt,ct),qc.subVectors(St,ct),Pu.subVectors(f,ct);var Pt=sc.dot(Pu),sn=qc.dot(Pu);if(Pt<=0&&sn<=0)return E.copy(ct);ol.subVectors(f,gt);var ln=sc.dot(ol),Sn=qc.dot(ol);if(0<=ln&&Sn<=ln)return E.copy(gt);var En=Pt*Sn-ln*sn;if(En<=0&&0<=Pt&&ln<=0)return W=Pt/(Pt-ln),E.copy(ct).addScaledVector(sc,W);od.subVectors(f,St);var On=sc.dot(od),mn=qc.dot(od);if(0<=mn&&On<=mn)return E.copy(St);var Hn=On*sn-Pt*mn;if(Hn<=0&&0<=sn&&mn<=0)return ge=sn/(sn-mn),E.copy(ct).addScaledVector(qc,ge);var mr=ln*mn-On*Sn;if(mr<=0&&0<=Sn-ln&&0<=On-mn)return vd.subVectors(St,gt),ge=(Sn-ln)/(Sn-ln+(On-mn)),E.copy(gt).addScaledVector(vd,ge);var _r=1/(mr+Hn+En);return W=Hn*_r,ge=En*_r,E.copy(ct).addScaledVector(sc,W).addScaledVector(qc,ge)},equals:function(f){return f.a.equals(this.a)&&f.b.equals(this.b)&&f.c.equals(this.c)}});var ah={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074},Mi={h:0,s:0,l:0},wa={h:0,s:0,l:0};function la(f,E,W){return E===void 0&&W===void 0?this.set(f):this.setRGB(f,E,W)}function Wa(f,E,W){return W<0&&(W+=1),1<W&&--W,W<1/6?f+6*(E-f)*W:W<.5?E:W<2/3?f+6*(E-f)*(2/3-W):f}function lo(f){return f<.04045?.0773993808*f:Math.pow(.9478672986*f+.0521327014,2.4)}function Jo(f){return f<.0031308?12.92*f:1.055*Math.pow(f,.41666)-.055}function Xo(f,E,W,ge,ct,gt){this.a=f,this.b=E,this.c=W,this.normal=ge&&ge.isVector3?ge:new yi,this.vertexNormals=Array.isArray(ge)?ge:[],this.color=ct&&ct.isColor?ct:new la,this.vertexColors=Array.isArray(ct)?ct:[],this.materialIndex=gt!==void 0?gt:0}Object.assign(la.prototype,{isColor:!0,r:1,g:1,b:1,set:function(f){return f&&f.isColor?this.copy(f):typeof f=="number"?this.setHex(f):typeof f=="string"&&this.setStyle(f),this},setScalar:function(f){return this.r=f,this.g=f,this.b=f,this},setHex:function(f){return f=Math.floor(f),this.r=(f>>16&255)/255,this.g=(f>>8&255)/255,this.b=(255&f)/255,this},setRGB:function(f,E,W){return this.r=f,this.g=E,this.b=W,this},setHSL:function(f,E,W){if(f=js.euclideanModulo(f,1),E=js.clamp(E,0,1),W=js.clamp(W,0,1),E===0)this.r=this.g=this.b=W;else{var ge=W<=.5?W*(1+E):W+E-W*E,ct=2*W-ge;this.r=Wa(ct,ge,f+1/3),this.g=Wa(ct,ge,f),this.b=Wa(ct,ge,f-1/3)}return this},setStyle:function(f){function E(En){En!==void 0&&parseFloat(En)<1&&console.warn("THREE.Color: Alpha component of "+f+" will be ignored.")}var W;if(W=/^((?:rgb|hsl)a?)\(\s*([^\)]*)\)/.exec(f)){var ge,ct=W[1],gt=W[2];switch(ct){case"rgb":case"rgba":if(ge=/^(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(gt))return this.r=Math.min(255,parseInt(ge[1],10))/255,this.g=Math.min(255,parseInt(ge[2],10))/255,this.b=Math.min(255,parseInt(ge[3],10))/255,E(ge[5]),this;if(ge=/^(\d+)\%\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(gt))return this.r=Math.min(100,parseInt(ge[1],10))/100,this.g=Math.min(100,parseInt(ge[2],10))/100,this.b=Math.min(100,parseInt(ge[3],10))/100,E(ge[5]),this;break;case"hsl":case"hsla":if(ge=/^([0-9]*\.?[0-9]+)\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(gt)){var St=parseFloat(ge[1])/360,Pt=parseInt(ge[2],10)/100,sn=parseInt(ge[3],10)/100;return E(ge[5]),this.setHSL(St,Pt,sn)}}}else if(W=/^\#([A-Fa-f0-9]+)$/.exec(f)){var ln=W[1],Sn=ln.length;if(Sn===3)return this.r=parseInt(ln.charAt(0)+ln.charAt(0),16)/255,this.g=parseInt(ln.charAt(1)+ln.charAt(1),16)/255,this.b=parseInt(ln.charAt(2)+ln.charAt(2),16)/255,this;if(Sn===6)return this.r=parseInt(ln.charAt(0)+ln.charAt(1),16)/255,this.g=parseInt(ln.charAt(2)+ln.charAt(3),16)/255,this.b=parseInt(ln.charAt(4)+ln.charAt(5),16)/255,this}return f&&0<f.length?this.setColorName(f):this},setColorName:function(f){var E=ah[f];return E!==void 0?this.setHex(E):console.warn("THREE.Color: Unknown color "+f),this},clone:function(){return new this.constructor(this.r,this.g,this.b)},copy:function(f){return this.r=f.r,this.g=f.g,this.b=f.b,this},copyGammaToLinear:function(f,E){return E===void 0&&(E=2),this.r=Math.pow(f.r,E),this.g=Math.pow(f.g,E),this.b=Math.pow(f.b,E),this},copyLinearToGamma:function(f,E){E===void 0&&(E=2);var W=0<E?1/E:1;return this.r=Math.pow(f.r,W),this.g=Math.pow(f.g,W),this.b=Math.pow(f.b,W),this},convertGammaToLinear:function(f){return this.copyGammaToLinear(this,f),this},convertLinearToGamma:function(f){return this.copyLinearToGamma(this,f),this},copySRGBToLinear:function(f){return this.r=lo(f.r),this.g=lo(f.g),this.b=lo(f.b),this},copyLinearToSRGB:function(f){return this.r=Jo(f.r),this.g=Jo(f.g),this.b=Jo(f.b),this},convertSRGBToLinear:function(){return this.copySRGBToLinear(this),this},convertLinearToSRGB:function(){return this.copyLinearToSRGB(this),this},getHex:function(){return 255*this.r<<16^255*this.g<<8^255*this.b<<0},getHexString:function(){return("000000"+this.getHex().toString(16)).slice(-6)},getHSL:function(f){f===void 0&&(console.warn("THREE.Color: .getHSL() target is now required"),f={h:0,s:0,l:0});var E,W,ge=this.r,ct=this.g,gt=this.b,St=Math.max(ge,ct,gt),Pt=Math.min(ge,ct,gt),sn=(Pt+St)/2;if(Pt===St)W=E=0;else{var ln=St-Pt;switch(W=sn<=.5?ln/(St+Pt):ln/(2-St-Pt),St){case ge:E=(ct-gt)/ln+(ct<gt?6:0);break;case ct:E=(gt-ge)/ln+2;break;case gt:E=(ge-ct)/ln+4}E/=6}return f.h=E,f.s=W,f.l=sn,f},getStyle:function(){return"rgb("+(255*this.r|0)+","+(255*this.g|0)+","+(255*this.b|0)+")"},offsetHSL:function(f,E,W){return this.getHSL(Mi),Mi.h+=f,Mi.s+=E,Mi.l+=W,this.setHSL(Mi.h,Mi.s,Mi.l),this},add:function(f){return this.r+=f.r,this.g+=f.g,this.b+=f.b,this},addColors:function(f,E){return this.r=f.r+E.r,this.g=f.g+E.g,this.b=f.b+E.b,this},addScalar:function(f){return this.r+=f,this.g+=f,this.b+=f,this},sub:function(f){return this.r=Math.max(0,this.r-f.r),this.g=Math.max(0,this.g-f.g),this.b=Math.max(0,this.b-f.b),this},multiply:function(f){return this.r*=f.r,this.g*=f.g,this.b*=f.b,this},multiplyScalar:function(f){return this.r*=f,this.g*=f,this.b*=f,this},lerp:function(f,E){return this.r+=(f.r-this.r)*E,this.g+=(f.g-this.g)*E,this.b+=(f.b-this.b)*E,this},lerpHSL:function(f,E){this.getHSL(Mi),f.getHSL(wa);var W=js.lerp(Mi.h,wa.h,E),ge=js.lerp(Mi.s,wa.s,E),ct=js.lerp(Mi.l,wa.l,E);return this.setHSL(W,ge,ct),this},equals:function(f){return f.r===this.r&&f.g===this.g&&f.b===this.b},fromArray:function(f,E){return E===void 0&&(E=0),this.r=f[E],this.g=f[E+1],this.b=f[E+2],this},toArray:function(f,E){return f===void 0&&(f=[]),E===void 0&&(E=0),f[E]=this.r,f[E+1]=this.g,f[E+2]=this.b,f},toJSON:function(){return this.getHex()}}),la.NAMES=ah,Object.assign(Xo.prototype,{clone:function(){return new this.constructor().copy(this)},copy:function(f){this.a=f.a,this.b=f.b,this.c=f.c,this.normal.copy(f.normal),this.color.copy(f.color),this.materialIndex=f.materialIndex;for(var E=0,W=f.vertexNormals.length;E<W;E++)this.vertexNormals[E]=f.vertexNormals[E].clone();for(E=0,W=f.vertexColors.length;E<W;E++)this.vertexColors[E]=f.vertexColors[E].clone();return this}});var ei=0;function ii(){Object.defineProperty(this,"id",{value:ei++}),this.uuid=js.generateUUID(),this.name="",this.type="Material",this.fog=!0,this.blending=ne,this.side=G,this.flatShading=!1,this.vertexTangents=!1,this.vertexColors=fe,this.opacity=1,this.transparent=!1,this.blendSrc=It,this.blendDst=nn,this.blendEquation=Ae,this.blendSrcAlpha=null,this.blendDstAlpha=null,this.blendEquationAlpha=null,this.depthFunc=hn,this.depthTest=!0,this.depthWrite=!0,this.stencilWriteMask=255,this.stencilFunc=Bu,this.stencilRef=0,this.stencilFuncMask=255,this.stencilFail=bu,this.stencilZFail=bu,this.stencilZPass=bu,this.stencilWrite=!1,this.clippingPlanes=null,this.clipIntersection=!1,this.clipShadows=!1,this.shadowSide=null,this.colorWrite=!0,this.precision=null,this.polygonOffset=!1,this.polygonOffsetFactor=0,this.polygonOffsetUnits=0,this.dithering=!1,this.alphaTest=0,this.premultipliedAlpha=!1,this.visible=!0,this.toneMapped=!0,this.userData={},this.version=0}function Ma(f){ii.call(this),this.type="MeshBasicMaterial",this.color=new la(16777215),this.map=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.specularMap=null,this.alphaMap=null,this.envMap=null,this.combine=gn,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.skinning=!1,this.morphTargets=!1,this.setValues(f)}ii.prototype=Object.assign(Object.create(Ku.prototype),{constructor:ii,isMaterial:!0,onBeforeCompile:function(){},setValues:function(f){if(f!==void 0)for(var E in f){var W=f[E];if(W!==void 0)if(E!=="shading"){var ge=this[E];ge!==void 0?ge&&ge.isColor?ge.set(W):ge&&ge.isVector3&&W&&W.isVector3?ge.copy(W):this[E]=W:console.warn("THREE."+this.type+": '"+E+"' is not a property of this material.")}else console.warn("THREE."+this.type+": .shading has been removed. Use the boolean .flatShading instead."),this.flatShading=W===1;else console.warn("THREE.Material: '"+E+"' parameter is undefined.")}},toJSON:function(f){var E=f===void 0||typeof f=="string";E&&(f={textures:{},images:{}});var W={metadata:{version:4.5,type:"Material",generator:"Material.toJSON"}};function ge(St){var Pt=[];for(var sn in St){var ln=St[sn];delete ln.metadata,Pt.push(ln)}return Pt}if(W.uuid=this.uuid,W.type=this.type,this.name!==""&&(W.name=this.name),this.color&&this.color.isColor&&(W.color=this.color.getHex()),this.roughness!==void 0&&(W.roughness=this.roughness),this.metalness!==void 0&&(W.metalness=this.metalness),this.sheen&&this.sheen.isColor&&(W.sheen=this.sheen.getHex()),this.emissive&&this.emissive.isColor&&(W.emissive=this.emissive.getHex()),this.emissiveIntensity&&this.emissiveIntensity!==1&&(W.emissiveIntensity=this.emissiveIntensity),this.specular&&this.specular.isColor&&(W.specular=this.specular.getHex()),this.shininess!==void 0&&(W.shininess=this.shininess),this.clearcoat!==void 0&&(W.clearcoat=this.clearcoat),this.clearcoatRoughness!==void 0&&(W.clearcoatRoughness=this.clearcoatRoughness),this.clearcoatNormalMap&&this.clearcoatNormalMap.isTexture&&(W.clearcoatNormalMap=this.clearcoatNormalMap.toJSON(f).uuid,W.clearcoatNormalScale=this.clearcoatNormalScale.toArray()),this.map&&this.map.isTexture&&(W.map=this.map.toJSON(f).uuid),this.matcap&&this.matcap.isTexture&&(W.matcap=this.matcap.toJSON(f).uuid),this.alphaMap&&this.alphaMap.isTexture&&(W.alphaMap=this.alphaMap.toJSON(f).uuid),this.lightMap&&this.lightMap.isTexture&&(W.lightMap=this.lightMap.toJSON(f).uuid),this.aoMap&&this.aoMap.isTexture&&(W.aoMap=this.aoMap.toJSON(f).uuid,W.aoMapIntensity=this.aoMapIntensity),this.bumpMap&&this.bumpMap.isTexture&&(W.bumpMap=this.bumpMap.toJSON(f).uuid,W.bumpScale=this.bumpScale),this.normalMap&&this.normalMap.isTexture&&(W.normalMap=this.normalMap.toJSON(f).uuid,W.normalMapType=this.normalMapType,W.normalScale=this.normalScale.toArray()),this.displacementMap&&this.displacementMap.isTexture&&(W.displacementMap=this.displacementMap.toJSON(f).uuid,W.displacementScale=this.displacementScale,W.displacementBias=this.displacementBias),this.roughnessMap&&this.roughnessMap.isTexture&&(W.roughnessMap=this.roughnessMap.toJSON(f).uuid),this.metalnessMap&&this.metalnessMap.isTexture&&(W.metalnessMap=this.metalnessMap.toJSON(f).uuid),this.emissiveMap&&this.emissiveMap.isTexture&&(W.emissiveMap=this.emissiveMap.toJSON(f).uuid),this.specularMap&&this.specularMap.isTexture&&(W.specularMap=this.specularMap.toJSON(f).uuid),this.envMap&&this.envMap.isTexture&&(W.envMap=this.envMap.toJSON(f).uuid,W.reflectivity=this.reflectivity,W.refractionRatio=this.refractionRatio,this.combine!==void 0&&(W.combine=this.combine),this.envMapIntensity!==void 0&&(W.envMapIntensity=this.envMapIntensity)),this.gradientMap&&this.gradientMap.isTexture&&(W.gradientMap=this.gradientMap.toJSON(f).uuid),this.size!==void 0&&(W.size=this.size),this.sizeAttenuation!==void 0&&(W.sizeAttenuation=this.sizeAttenuation),this.blending!==ne&&(W.blending=this.blending),this.flatShading===!0&&(W.flatShading=this.flatShading),this.side!==G&&(W.side=this.side),this.vertexColors!==fe&&(W.vertexColors=this.vertexColors),this.opacity<1&&(W.opacity=this.opacity),this.transparent===!0&&(W.transparent=this.transparent),W.depthFunc=this.depthFunc,W.depthTest=this.depthTest,W.depthWrite=this.depthWrite,W.stencilWrite=this.stencilWrite,W.stencilWriteMask=this.stencilWriteMask,W.stencilFunc=this.stencilFunc,W.stencilRef=this.stencilRef,W.stencilFuncMask=this.stencilFuncMask,W.stencilFail=this.stencilFail,W.stencilZFail=this.stencilZFail,W.stencilZPass=this.stencilZPass,this.rotation&&this.rotation!==0&&(W.rotation=this.rotation),this.polygonOffset===!0&&(W.polygonOffset=!0),this.polygonOffsetFactor!==0&&(W.polygonOffsetFactor=this.polygonOffsetFactor),this.polygonOffsetUnits!==0&&(W.polygonOffsetUnits=this.polygonOffsetUnits),this.linewidth&&this.linewidth!==1&&(W.linewidth=this.linewidth),this.dashSize!==void 0&&(W.dashSize=this.dashSize),this.gapSize!==void 0&&(W.gapSize=this.gapSize),this.scale!==void 0&&(W.scale=this.scale),this.dithering===!0&&(W.dithering=!0),0<this.alphaTest&&(W.alphaTest=this.alphaTest),this.premultipliedAlpha===!0&&(W.premultipliedAlpha=this.premultipliedAlpha),this.wireframe===!0&&(W.wireframe=this.wireframe),1<this.wireframeLinewidth&&(W.wireframeLinewidth=this.wireframeLinewidth),this.wireframeLinecap!=="round"&&(W.wireframeLinecap=this.wireframeLinecap),this.wireframeLinejoin!=="round"&&(W.wireframeLinejoin=this.wireframeLinejoin),this.morphTargets===!0&&(W.morphTargets=!0),this.morphNormals===!0&&(W.morphNormals=!0),this.skinning===!0&&(W.skinning=!0),this.visible===!1&&(W.visible=!1),this.toneMapped===!1&&(W.toneMapped=!1),JSON.stringify(this.userData)!=="{}"&&(W.userData=this.userData),E){var ct=ge(f.textures),gt=ge(f.images);0<ct.length&&(W.textures=ct),0<gt.length&&(W.images=gt)}return W},clone:function(){return new this.constructor().copy(this)},copy:function(f){this.name=f.name,this.fog=f.fog,this.blending=f.blending,this.side=f.side,this.flatShading=f.flatShading,this.vertexTangents=f.vertexTangents,this.vertexColors=f.vertexColors,this.opacity=f.opacity,this.transparent=f.transparent,this.blendSrc=f.blendSrc,this.blendDst=f.blendDst,this.blendEquation=f.blendEquation,this.blendSrcAlpha=f.blendSrcAlpha,this.blendDstAlpha=f.blendDstAlpha,this.blendEquationAlpha=f.blendEquationAlpha,this.depthFunc=f.depthFunc,this.depthTest=f.depthTest,this.depthWrite=f.depthWrite,this.stencilWriteMask=f.stencilWriteMask,this.stencilFunc=f.stencilFunc,this.stencilRef=f.stencilRef,this.stencilFuncMask=f.stencilFuncMask,this.stencilFail=f.stencilFail,this.stencilZFail=f.stencilZFail,this.stencilZPass=f.stencilZPass,this.stencilWrite=f.stencilWrite;var E=f.clippingPlanes,W=null;if(E!==null){var ge=E.length;W=new Array(ge);for(var ct=0;ct!==ge;++ct)W[ct]=E[ct].clone()}return this.clippingPlanes=W,this.clipIntersection=f.clipIntersection,this.clipShadows=f.clipShadows,this.shadowSide=f.shadowSide,this.colorWrite=f.colorWrite,this.precision=f.precision,this.polygonOffset=f.polygonOffset,this.polygonOffsetFactor=f.polygonOffsetFactor,this.polygonOffsetUnits=f.polygonOffsetUnits,this.dithering=f.dithering,this.alphaTest=f.alphaTest,this.premultipliedAlpha=f.premultipliedAlpha,this.visible=f.visible,this.toneMapped=f.toneMapped,this.userData=JSON.parse(JSON.stringify(f.userData)),this},dispose:function(){this.dispatchEvent({type:"dispose"})}}),Object.defineProperty(ii.prototype,"needsUpdate",{set:function(f){f===!0&&this.version++}}),((Ma.prototype=Object.create(ii.prototype)).constructor=Ma).prototype.isMeshBasicMaterial=!0,Ma.prototype.copy=function(f){return ii.prototype.copy.call(this,f),this.color.copy(f.color),this.map=f.map,this.lightMap=f.lightMap,this.lightMapIntensity=f.lightMapIntensity,this.aoMap=f.aoMap,this.aoMapIntensity=f.aoMapIntensity,this.specularMap=f.specularMap,this.alphaMap=f.alphaMap,this.envMap=f.envMap,this.combine=f.combine,this.reflectivity=f.reflectivity,this.refractionRatio=f.refractionRatio,this.wireframe=f.wireframe,this.wireframeLinewidth=f.wireframeLinewidth,this.wireframeLinecap=f.wireframeLinecap,this.wireframeLinejoin=f.wireframeLinejoin,this.skinning=f.skinning,this.morphTargets=f.morphTargets,this};var pa=new yi;function ca(f,E,W){if(Array.isArray(f))throw new TypeError("THREE.BufferAttribute: array should be a Typed Array.");this.name="",this.array=f,this.itemSize=E,this.count=f!==void 0?f.length/E:0,this.normalized=W===!0,this.usage=hl,this.updateRange={offset:0,count:-1},this.version=0}function uo(f,E,W){ca.call(this,new Int8Array(f),E,W)}function ya(f,E,W){ca.call(this,new Uint8Array(f),E,W)}function Oo(f,E,W){ca.call(this,new Uint8ClampedArray(f),E,W)}function Io(f,E,W){ca.call(this,new Int16Array(f),E,W)}function Ws(f,E,W){ca.call(this,new Uint16Array(f),E,W)}function gr(f,E,W){ca.call(this,new Int32Array(f),E,W)}function ws(f,E,W){ca.call(this,new Uint32Array(f),E,W)}function io(f,E,W){ca.call(this,new Float32Array(f),E,W)}function Fo(f,E,W){ca.call(this,new Float64Array(f),E,W)}function vs(){this.vertices=[],this.normals=[],this.colors=[],this.uvs=[],this.uvs2=[],this.groups=[],this.morphTargets={},this.skinWeights=[],this.skinIndices=[],this.boundingBox=null,this.boundingSphere=null,this.verticesNeedUpdate=!1,this.normalsNeedUpdate=!1,this.colorsNeedUpdate=!1,this.uvsNeedUpdate=!1,this.groupsNeedUpdate=!1}function Gl(f){if(f.length===0)return-1/0;for(var E=f[0],W=1,ge=f.length;W<ge;++W)f[W]>E&&(E=f[W]);return E}Object.defineProperty(ca.prototype,"needsUpdate",{set:function(f){f===!0&&this.version++}}),Object.assign(ca.prototype,{isBufferAttribute:!0,onUploadCallback:function(){},setUsage:function(f){return this.usage=f,this},copy:function(f){return this.name=f.name,this.array=new f.array.constructor(f.array),this.itemSize=f.itemSize,this.count=f.count,this.normalized=f.normalized,this.usage=f.usage,this},copyAt:function(f,E,W){f*=this.itemSize,W*=E.itemSize;for(var ge=0,ct=this.itemSize;ge<ct;ge++)this.array[f+ge]=E.array[W+ge];return this},copyArray:function(f){return this.array.set(f),this},copyColorsArray:function(f){for(var E=this.array,W=0,ge=0,ct=f.length;ge<ct;ge++){var gt=f[ge];gt===void 0&&(console.warn("THREE.BufferAttribute.copyColorsArray(): color is undefined",ge),gt=new la),E[W++]=gt.r,E[W++]=gt.g,E[W++]=gt.b}return this},copyVector2sArray:function(f){for(var E=this.array,W=0,ge=0,ct=f.length;ge<ct;ge++){var gt=f[ge];gt===void 0&&(console.warn("THREE.BufferAttribute.copyVector2sArray(): vector is undefined",ge),gt=new co),E[W++]=gt.x,E[W++]=gt.y}return this},copyVector3sArray:function(f){for(var E=this.array,W=0,ge=0,ct=f.length;ge<ct;ge++){var gt=f[ge];gt===void 0&&(console.warn("THREE.BufferAttribute.copyVector3sArray(): vector is undefined",ge),gt=new yi),E[W++]=gt.x,E[W++]=gt.y,E[W++]=gt.z}return this},copyVector4sArray:function(f){for(var E=this.array,W=0,ge=0,ct=f.length;ge<ct;ge++){var gt=f[ge];gt===void 0&&(console.warn("THREE.BufferAttribute.copyVector4sArray(): vector is undefined",ge),gt=new Ll),E[W++]=gt.x,E[W++]=gt.y,E[W++]=gt.z,E[W++]=gt.w}return this},applyMatrix3:function(f){for(var E=0,W=this.count;E<W;E++)pa.x=this.getX(E),pa.y=this.getY(E),pa.z=this.getZ(E),pa.applyMatrix3(f),this.setXYZ(E,pa.x,pa.y,pa.z);return this},applyMatrix4:function(f){for(var E=0,W=this.count;E<W;E++)pa.x=this.getX(E),pa.y=this.getY(E),pa.z=this.getZ(E),pa.applyMatrix4(f),this.setXYZ(E,pa.x,pa.y,pa.z);return this},applyNormalMatrix:function(f){for(var E=0,W=this.count;E<W;E++)pa.x=this.getX(E),pa.y=this.getY(E),pa.z=this.getZ(E),pa.applyNormalMatrix(f),this.setXYZ(E,pa.x,pa.y,pa.z);return this},transformDirection:function(f){for(var E=0,W=this.count;E<W;E++)pa.x=this.getX(E),pa.y=this.getY(E),pa.z=this.getZ(E),pa.transformDirection(f),this.setXYZ(E,pa.x,pa.y,pa.z);return this},set:function(f,E){return E===void 0&&(E=0),this.array.set(f,E),this},getX:function(f){return this.array[f*this.itemSize]},setX:function(f,E){return this.array[f*this.itemSize]=E,this},getY:function(f){return this.array[f*this.itemSize+1]},setY:function(f,E){return this.array[f*this.itemSize+1]=E,this},getZ:function(f){return this.itemSize<3?0:this.array[f*this.itemSize+2]},setZ:function(f,E){return this.array[f*this.itemSize+2]=E,this},getW:function(f){return this.array[f*this.itemSize+3]},setW:function(f,E){return this.array[f*this.itemSize+3]=E,this},setXY:function(f,E,W){return f*=this.itemSize,this.array[f+0]=E,this.array[f+1]=W,this},setXYZ:function(f,E,W,ge){return f*=this.itemSize,this.array[f+0]=E,this.array[f+1]=W,this.array[f+2]=ge,this},setXYZW:function(f,E,W,ge,ct){return f*=this.itemSize,this.array[f+0]=E,this.array[f+1]=W,this.array[f+2]=ge,this.array[f+3]=ct,this},onUpload:function(f){return this.onUploadCallback=f,this},clone:function(){return new this.constructor(this.array,this.itemSize).copy(this)},toJSON:function(){return{itemSize:this.itemSize,type:this.array.constructor.name,array:Array.prototype.slice.call(this.array),normalized:this.normalized}}}),(uo.prototype=Object.create(ca.prototype)).constructor=uo,(ya.prototype=Object.create(ca.prototype)).constructor=ya,(Oo.prototype=Object.create(ca.prototype)).constructor=Oo,(Io.prototype=Object.create(ca.prototype)).constructor=Io,(Ws.prototype=Object.create(ca.prototype)).constructor=Ws,(gr.prototype=Object.create(ca.prototype)).constructor=gr,(ws.prototype=Object.create(ca.prototype)).constructor=ws,(io.prototype=Object.create(ca.prototype)).constructor=io,(Fo.prototype=Object.create(ca.prototype)).constructor=Fo,Object.assign(vs.prototype,{computeGroups:function(f){for(var E,W=[],ge=void 0,ct=f.faces,gt=0;gt<ct.length;gt++){var St=ct[gt];St.materialIndex!==ge&&(ge=St.materialIndex,E!==void 0&&(E.count=3*gt-E.start,W.push(E)),E={start:3*gt,materialIndex:ge})}E!==void 0&&(E.count=3*gt-E.start,W.push(E)),this.groups=W},fromGeometry:function(f){var E,W=f.faces,ge=f.vertices,ct=f.faceVertexUvs,gt=ct[0]&&0<ct[0].length,St=ct[1]&&0<ct[1].length,Pt=f.morphTargets,sn=Pt.length;if(0<sn){E=[];for(var ln=0;ln<sn;ln++)E[ln]={name:Pt[ln].name,data:[]};this.morphTargets.position=E}var Sn,En=f.morphNormals,On=En.length;if(0<On){for(Sn=[],ln=0;ln<On;ln++)Sn[ln]={name:En[ln].name,data:[]};this.morphTargets.normal=Sn}var mn=f.skinIndices,Hn=f.skinWeights,mr=mn.length===ge.length,_r=Hn.length===ge.length;for(0<ge.length&&W.length===0&&console.error("THREE.DirectGeometry: Faceless geometries are not supported."),ln=0;ln<W.length;ln++){var gi=W[ln];this.vertices.push(ge[gi.a],ge[gi.b],ge[gi.c]);var Ci=gi.vertexNormals;if(Ci.length===3)this.normals.push(Ci[0],Ci[1],Ci[2]);else{var $i=gi.normal;this.normals.push($i,$i,$i)}var da,ji=gi.vertexColors;if(ji.length===3)this.colors.push(ji[0],ji[1],ji[2]);else{var Sa=gi.color;this.colors.push(Sa,Sa,Sa)}gt===!0&&((da=ct[0][ln])!==void 0?this.uvs.push(da[0],da[1],da[2]):(console.warn("THREE.DirectGeometry.fromGeometry(): Undefined vertexUv ",ln),this.uvs.push(new co,new co,new co))),St===!0&&((da=ct[1][ln])!==void 0?this.uvs2.push(da[0],da[1],da[2]):(console.warn("THREE.DirectGeometry.fromGeometry(): Undefined vertexUv2 ",ln),this.uvs2.push(new co,new co,new co)));for(var ea=0;ea<sn;ea++){var Ba=Pt[ea].vertices;E[ea].data.push(Ba[gi.a],Ba[gi.b],Ba[gi.c])}for(ea=0;ea<On;ea++){var Ya=En[ea].vertexNormals[ln];Sn[ea].data.push(Ya.a,Ya.b,Ya.c)}mr&&this.skinIndices.push(mn[gi.a],mn[gi.b],mn[gi.c]),_r&&this.skinWeights.push(Hn[gi.a],Hn[gi.b],Hn[gi.c])}return this.computeGroups(f),this.verticesNeedUpdate=f.verticesNeedUpdate,this.normalsNeedUpdate=f.normalsNeedUpdate,this.colorsNeedUpdate=f.colorsNeedUpdate,this.uvsNeedUpdate=f.uvsNeedUpdate,this.groupsNeedUpdate=f.groupsNeedUpdate,f.boundingSphere!==null&&(this.boundingSphere=f.boundingSphere.clone()),f.boundingBox!==null&&(this.boundingBox=f.boundingBox.clone()),this}});var Mu=2147483647,gu=new Vo,Nu=new Ri,lc=new yi,Du=new Xu,Zh=new Xu,uc=new yi;function Ds(){Object.defineProperty(this,"id",{value:Mu+=2}),this.uuid=js.generateUUID(),this.name="",this.type="BufferGeometry",this.index=null,this.attributes={},this.morphAttributes={},this.morphTargetsRelative=!1,this.groups=[],this.boundingBox=null,this.boundingSphere=null,this.drawRange={start:0,count:1/0},this.userData={}}Ds.prototype=Object.assign(Object.create(Ku.prototype),{constructor:Ds,isBufferGeometry:!0,getIndex:function(){return this.index},setIndex:function(f){Array.isArray(f)?this.index=new(65535<Gl(f)?ws:Ws)(f,1):this.index=f},getAttribute:function(f){return this.attributes[f]},setAttribute:function(f,E){return this.attributes[f]=E,this},deleteAttribute:function(f){return delete this.attributes[f],this},addGroup:function(f,E,W){this.groups.push({start:f,count:E,materialIndex:W!==void 0?W:0})},clearGroups:function(){this.groups=[]},setDrawRange:function(f,E){this.drawRange.start=f,this.drawRange.count=E},applyMatrix4:function(f){var E=this.attributes.position;E!==void 0&&(E.applyMatrix4(f),E.needsUpdate=!0);var W=this.attributes.normal;if(W!==void 0){var ge=new Vl().getNormalMatrix(f);W.applyNormalMatrix(ge),W.needsUpdate=!0}var ct=this.attributes.tangent;return ct!==void 0&&(ct.transformDirection(f),ct.needsUpdate=!0),this.boundingBox!==null&&this.computeBoundingBox(),this.boundingSphere!==null&&this.computeBoundingSphere(),this},rotateX:function(f){return gu.makeRotationX(f),this.applyMatrix4(gu),this},rotateY:function(f){return gu.makeRotationY(f),this.applyMatrix4(gu),this},rotateZ:function(f){return gu.makeRotationZ(f),this.applyMatrix4(gu),this},translate:function(f,E,W){return gu.makeTranslation(f,E,W),this.applyMatrix4(gu),this},scale:function(f,E,W){return gu.makeScale(f,E,W),this.applyMatrix4(gu),this},lookAt:function(f){return Nu.lookAt(f),Nu.updateMatrix(),this.applyMatrix4(Nu.matrix),this},center:function(){return this.computeBoundingBox(),this.boundingBox.getCenter(lc).negate(),this.translate(lc.x,lc.y,lc.z),this},setFromObject:function(f){var E=f.geometry;if(f.isPoints||f.isLine){var W=new io(3*E.vertices.length,3),ge=new io(3*E.colors.length,3);if(this.setAttribute("position",W.copyVector3sArray(E.vertices)),this.setAttribute("color",ge.copyColorsArray(E.colors)),E.lineDistances&&E.lineDistances.length===E.vertices.length){var ct=new io(E.lineDistances.length,1);this.setAttribute("lineDistance",ct.copyArray(E.lineDistances))}E.boundingSphere!==null&&(this.boundingSphere=E.boundingSphere.clone()),E.boundingBox!==null&&(this.boundingBox=E.boundingBox.clone())}else f.isMesh&&E&&E.isGeometry&&this.fromGeometry(E);return this},setFromPoints:function(f){for(var E=[],W=0,ge=f.length;W<ge;W++){var ct=f[W];E.push(ct.x,ct.y,ct.z||0)}return this.setAttribute("position",new io(E,3)),this},updateFromObject:function(f){var E,W=f.geometry;if(f.isMesh){var ge=W.__directGeometry;if(W.elementsNeedUpdate===!0&&(ge=void 0,W.elementsNeedUpdate=!1),ge===void 0)return this.fromGeometry(W);ge.verticesNeedUpdate=W.verticesNeedUpdate,ge.normalsNeedUpdate=W.normalsNeedUpdate,ge.colorsNeedUpdate=W.colorsNeedUpdate,ge.uvsNeedUpdate=W.uvsNeedUpdate,ge.groupsNeedUpdate=W.groupsNeedUpdate,W.verticesNeedUpdate=!1,W.normalsNeedUpdate=!1,W.colorsNeedUpdate=!1,W.uvsNeedUpdate=!1,W.groupsNeedUpdate=!1,W=ge}return W.verticesNeedUpdate===!0&&((E=this.attributes.position)!==void 0&&(E.copyVector3sArray(W.vertices),E.needsUpdate=!0),W.verticesNeedUpdate=!1),W.normalsNeedUpdate===!0&&((E=this.attributes.normal)!==void 0&&(E.copyVector3sArray(W.normals),E.needsUpdate=!0),W.normalsNeedUpdate=!1),W.colorsNeedUpdate===!0&&((E=this.attributes.color)!==void 0&&(E.copyColorsArray(W.colors),E.needsUpdate=!0),W.colorsNeedUpdate=!1),W.uvsNeedUpdate&&((E=this.attributes.uv)!==void 0&&(E.copyVector2sArray(W.uvs),E.needsUpdate=!0),W.uvsNeedUpdate=!1),W.lineDistancesNeedUpdate&&((E=this.attributes.lineDistance)!==void 0&&(E.copyArray(W.lineDistances),E.needsUpdate=!0),W.lineDistancesNeedUpdate=!1),W.groupsNeedUpdate&&(W.computeGroups(f.geometry),this.groups=W.groups,W.groupsNeedUpdate=!1),this},fromGeometry:function(f){return f.__directGeometry=new vs().fromGeometry(f),this.fromDirectGeometry(f.__directGeometry)},fromDirectGeometry:function(f){var E=new Float32Array(3*f.vertices.length);if(this.setAttribute("position",new ca(E,3).copyVector3sArray(f.vertices)),0<f.normals.length){var W=new Float32Array(3*f.normals.length);this.setAttribute("normal",new ca(W,3).copyVector3sArray(f.normals))}if(0<f.colors.length){var ge=new Float32Array(3*f.colors.length);this.setAttribute("color",new ca(ge,3).copyColorsArray(f.colors))}if(0<f.uvs.length){var ct=new Float32Array(2*f.uvs.length);this.setAttribute("uv",new ca(ct,2).copyVector2sArray(f.uvs))}if(0<f.uvs2.length){var gt=new Float32Array(2*f.uvs2.length);this.setAttribute("uv2",new ca(gt,2).copyVector2sArray(f.uvs2))}for(var St in this.groups=f.groups,f.morphTargets){for(var Pt=[],sn=f.morphTargets[St],ln=0,Sn=sn.length;ln<Sn;ln++){var En=sn[ln],On=new io(3*En.data.length,3);On.name=En.name,Pt.push(On.copyVector3sArray(En.data))}this.morphAttributes[St]=Pt}if(0<f.skinIndices.length){var mn=new io(4*f.skinIndices.length,4);this.setAttribute("skinIndex",mn.copyVector4sArray(f.skinIndices))}if(0<f.skinWeights.length){var Hn=new io(4*f.skinWeights.length,4);this.setAttribute("skinWeight",Hn.copyVector4sArray(f.skinWeights))}return f.boundingSphere!==null&&(this.boundingSphere=f.boundingSphere.clone()),f.boundingBox!==null&&(this.boundingBox=f.boundingBox.clone()),this},computeBoundingBox:function(){this.boundingBox===null&&(this.boundingBox=new Xu);var f=this.attributes.position,E=this.morphAttributes.position;if(f!==void 0){if(this.boundingBox.setFromBufferAttribute(f),E)for(var W=0,ge=E.length;W<ge;W++){var ct=E[W];Du.setFromBufferAttribute(ct),this.morphTargetsRelative?(uc.addVectors(this.boundingBox.min,Du.min),this.boundingBox.expandByPoint(uc),uc.addVectors(this.boundingBox.max,Du.max),this.boundingBox.expandByPoint(uc)):(this.boundingBox.expandByPoint(Du.min),this.boundingBox.expandByPoint(Du.max))}}else this.boundingBox.makeEmpty();(isNaN(this.boundingBox.min.x)||isNaN(this.boundingBox.min.y)||isNaN(this.boundingBox.min.z))&&console.error('THREE.BufferGeometry.computeBoundingBox: Computed min/max have NaN values. The "position" attribute is likely to have NaN values.',this)},computeBoundingSphere:function(){this.boundingSphere===null&&(this.boundingSphere=new Nl);var f=this.attributes.position,E=this.morphAttributes.position;if(f){var W=this.boundingSphere.center;if(Du.setFromBufferAttribute(f),E)for(var ge=0,ct=E.length;ge<ct;ge++){var gt=E[ge];Zh.setFromBufferAttribute(gt),this.morphTargetsRelative?(uc.addVectors(Du.min,Zh.min),Du.expandByPoint(uc),uc.addVectors(Du.max,Zh.max),Du.expandByPoint(uc)):(Du.expandByPoint(Zh.min),Du.expandByPoint(Zh.max))}Du.getCenter(W);var St=0;for(ge=0,ct=f.count;ge<ct;ge++)uc.fromBufferAttribute(f,ge),St=Math.max(St,W.distanceToSquared(uc));if(E)for(ge=0,ct=E.length;ge<ct;ge++){gt=E[ge];for(var Pt=this.morphTargetsRelative,sn=0,ln=gt.count;sn<ln;sn++)uc.fromBufferAttribute(gt,sn),Pt&&(lc.fromBufferAttribute(f,sn),uc.add(lc)),St=Math.max(St,W.distanceToSquared(uc))}this.boundingSphere.radius=Math.sqrt(St),isNaN(this.boundingSphere.radius)&&console.error('THREE.BufferGeometry.computeBoundingSphere(): Computed radius is NaN. The "position" attribute is likely to have NaN values.',this)}},computeFaceNormals:function(){},computeVertexNormals:function(){var f=this.index,E=this.attributes;if(E.position){var W=E.position.array;if(E.normal===void 0)this.setAttribute("normal",new ca(new Float32Array(W.length),3));else for(var ge=E.normal.array,ct=0,gt=ge.length;ct<gt;ct++)ge[ct]=0;var St,Pt,sn,ln=E.normal.array,Sn=new yi,En=new yi,On=new yi,mn=new yi,Hn=new yi;if(f){var mr=f.array;for(ct=0,gt=f.count;ct<gt;ct+=3)St=3*mr[ct+0],Pt=3*mr[ct+1],sn=3*mr[ct+2],Sn.fromArray(W,St),En.fromArray(W,Pt),On.fromArray(W,sn),mn.subVectors(On,En),Hn.subVectors(Sn,En),mn.cross(Hn),ln[St]+=mn.x,ln[1+St]+=mn.y,ln[2+St]+=mn.z,ln[Pt]+=mn.x,ln[1+Pt]+=mn.y,ln[2+Pt]+=mn.z,ln[sn]+=mn.x,ln[1+sn]+=mn.y,ln[2+sn]+=mn.z}else for(ct=0,gt=W.length;ct<gt;ct+=9)Sn.fromArray(W,ct),En.fromArray(W,ct+3),On.fromArray(W,ct+6),mn.subVectors(On,En),Hn.subVectors(Sn,En),mn.cross(Hn),ln[ct]=mn.x,ln[ct+1]=mn.y,ln[ct+2]=mn.z,ln[ct+3]=mn.x,ln[ct+4]=mn.y,ln[ct+5]=mn.z,ln[ct+6]=mn.x,ln[ct+7]=mn.y,ln[ct+8]=mn.z;this.normalizeNormals(),E.normal.needsUpdate=!0}},merge:function(f,E){if(f&&f.isBufferGeometry){E===void 0&&(E=0,console.warn("THREE.BufferGeometry.merge(): Overwriting original geometry, starting at offset=0. Use BufferGeometryUtils.mergeBufferGeometries() for lossless merge."));var W=this.attributes;for(var ge in W)if(f.attributes[ge]!==void 0)for(var ct=W[ge].array,gt=f.attributes[ge],St=gt.array,Pt=gt.itemSize*E,sn=Math.min(St.length,ct.length-Pt),ln=0,Sn=Pt;ln<sn;ln++,Sn++)ct[Sn]=St[ln];return this}console.error("THREE.BufferGeometry.merge(): geometry not an instance of THREE.BufferGeometry.",f)},normalizeNormals:function(){for(var f=this.attributes.normal,E=0,W=f.count;E<W;E++)uc.x=f.getX(E),uc.y=f.getY(E),uc.z=f.getZ(E),uc.normalize(),f.setXYZ(E,uc.x,uc.y,uc.z)},toNonIndexed:function(){function f(Hn,mr){for(var _r=Hn.array,gi=Hn.itemSize,Ci=new _r.constructor(mr.length*gi),$i=0,da=0,ji=0,Sa=mr.length;ji<Sa;ji++){$i=mr[ji]*gi;for(var ea=0;ea<gi;ea++)Ci[da++]=_r[$i++]}return new ca(Ci,gi)}if(this.index===null)return console.warn("THREE.BufferGeometry.toNonIndexed(): Geometry is already non-indexed."),this;var E=new Ds,W=this.index.array,ge=this.attributes;for(var ct in ge){var gt=f(ge[ct],W);E.setAttribute(ct,gt)}var St=this.morphAttributes;for(ct in St){for(var Pt=[],sn=St[ct],ln=0,Sn=sn.length;ln<Sn;ln++)gt=f(sn[ln],W),Pt.push(gt);E.morphAttributes[ct]=Pt}E.morphTargetsRelative=this.morphTargetsRelative;for(var En=this.groups,On=(ln=0,En.length);ln<On;ln++){var mn=En[ln];E.addGroup(mn.start,mn.count,mn.materialIndex)}return E},toJSON:function(){var f={metadata:{version:4.5,type:"BufferGeometry",generator:"BufferGeometry.toJSON"}};if(f.uuid=this.uuid,f.type=this.type,this.name!==""&&(f.name=this.name),0<Object.keys(this.userData).length&&(f.userData=this.userData),this.parameters!==void 0){var E=this.parameters;for(var W in E)E[W]!==void 0&&(f[W]=E[W]);return f}f.data={attributes:{}};var ge=this.index;ge!==null&&(f.data.index={type:ge.array.constructor.name,array:Array.prototype.slice.call(ge.array)});var ct=this.attributes;for(var W in ct){var gt=(On=ct[W]).toJSON();On.name!==""&&(gt.name=On.name),f.data.attributes[W]=gt}var St={},Pt=!1;for(var W in this.morphAttributes){for(var sn=this.morphAttributes[W],ln=[],Sn=0,En=sn.length;Sn<En;Sn++){var On;gt=(On=sn[Sn]).toJSON(),On.name!==""&&(gt.name=On.name),ln.push(gt)}0<ln.length&&(St[W]=ln,Pt=!0)}Pt&&(f.data.morphAttributes=St,f.data.morphTargetsRelative=this.morphTargetsRelative);var mn=this.groups;0<mn.length&&(f.data.groups=JSON.parse(JSON.stringify(mn)));var Hn=this.boundingSphere;return Hn!==null&&(f.data.boundingSphere={center:Hn.center.toArray(),radius:Hn.radius}),f},clone:function(){return new Ds().copy(this)},copy:function(f){var E,W,ge;this.index=null,this.attributes={},this.morphAttributes={},this.groups=[],this.boundingBox=null,this.boundingSphere=null,this.name=f.name;var ct=f.index;ct!==null&&this.setIndex(ct.clone());var gt=f.attributes;for(E in gt){var St=gt[E];this.setAttribute(E,St.clone())}var Pt=f.morphAttributes;for(E in Pt){var sn=[],ln=Pt[E];for(W=0,ge=ln.length;W<ge;W++)sn.push(ln[W].clone());this.morphAttributes[E]=sn}this.morphTargetsRelative=f.morphTargetsRelative;var Sn=f.groups;for(W=0,ge=Sn.length;W<ge;W++){var En=Sn[W];this.addGroup(En.start,En.count,En.materialIndex)}var On=f.boundingBox;On!==null&&(this.boundingBox=On.clone());var mn=f.boundingSphere;return mn!==null&&(this.boundingSphere=mn.clone()),this.drawRange.start=f.drawRange.start,this.drawRange.count=f.drawRange.count,this.userData=f.userData,this},dispose:function(){this.dispatchEvent({type:"dispose"})}});var Op=new Vo,Kh=new Hl,up=new Nl,Fc=new yi,fh=new yi,Rd=new yi,hd=new yi,ef=new yi,Cf=new yi,_d=new yi,oh=new yi,tf=new yi,Lp=new co,Ah=new co,cp=new co,yc=new yi,Cc=new yi;function lu(f,E){Ri.call(this),this.type="Mesh",this.geometry=f!==void 0?f:new Ds,this.material=E!==void 0?E:new Ma,this.updateMorphTargets()}function Od(f,E,W,ge,ct,gt,St,Pt){if((E.side===q?ge.intersectTriangle(St,gt,ct,!0,Pt):ge.intersectTriangle(ct,gt,St,E.side!==J,Pt))===null)return null;Cc.copy(Pt),Cc.applyMatrix4(f.matrixWorld);var sn=W.ray.origin.distanceTo(Cc);return sn<W.near||sn>W.far?null:{distance:sn,point:Cc.clone(),object:f}}function nf(f,E,W,ge,ct,gt,St,Pt,sn,ln,Sn,En){Fc.fromBufferAttribute(ct,ln),fh.fromBufferAttribute(ct,Sn),Rd.fromBufferAttribute(ct,En);var On=f.morphTargetInfluences;if(E.morphTargets&>&&On){_d.set(0,0,0),oh.set(0,0,0),tf.set(0,0,0);for(var mn=0,Hn=gt.length;mn<Hn;mn++){var mr=On[mn],_r=gt[mn];mr!==0&&(hd.fromBufferAttribute(_r,ln),ef.fromBufferAttribute(_r,Sn),Cf.fromBufferAttribute(_r,En),St?(_d.addScaledVector(hd,mr),oh.addScaledVector(ef,mr),tf.addScaledVector(Cf,mr)):(_d.addScaledVector(hd.sub(Fc),mr),oh.addScaledVector(ef.sub(fh),mr),tf.addScaledVector(Cf.sub(Rd),mr)))}Fc.add(_d),fh.add(oh),Rd.add(tf)}var gi=Od(f,E,W,ge,Fc,fh,Rd,yc);if(gi){Pt&&(Lp.fromBufferAttribute(Pt,ln),Ah.fromBufferAttribute(Pt,Sn),cp.fromBufferAttribute(Pt,En),gi.uv=qu.getUV(yc,Fc,fh,Rd,Lp,Ah,cp,new co)),sn&&(Lp.fromBufferAttribute(sn,ln),Ah.fromBufferAttribute(sn,Sn),cp.fromBufferAttribute(sn,En),gi.uv2=qu.getUV(yc,Fc,fh,Rd,Lp,Ah,cp,new co));var Ci=new Xo(ln,Sn,En);qu.getNormal(Fc,fh,Rd,Ci.normal),gi.face=Ci}return gi}lu.prototype=Object.assign(Object.create(Ri.prototype),{constructor:lu,isMesh:!0,copy:function(f){return Ri.prototype.copy.call(this,f),f.morphTargetInfluences!==void 0&&(this.morphTargetInfluences=f.morphTargetInfluences.slice()),f.morphTargetDictionary!==void 0&&(this.morphTargetDictionary=Object.assign({},f.morphTargetDictionary)),this},updateMorphTargets:function(){var f,E,W,ge=this.geometry;if(ge.isBufferGeometry){var ct=ge.morphAttributes,gt=Object.keys(ct);if(0<gt.length){var St=ct[gt[0]];if(St!==void 0)for(this.morphTargetInfluences=[],this.morphTargetDictionary={},f=0,E=St.length;f<E;f++)W=St[f].name||String(f),this.morphTargetInfluences.push(0),this.morphTargetDictionary[W]=f}}else{var Pt=ge.morphTargets;Pt!==void 0&&0<Pt.length&&console.error("THREE.Mesh.updateMorphTargets() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.")}},raycast:function(f,E){var W,ge=this.geometry,ct=this.material,gt=this.matrixWorld;if(ct!==void 0&&(ge.boundingSphere===null&&ge.computeBoundingSphere(),up.copy(ge.boundingSphere),up.applyMatrix4(gt),f.ray.intersectsSphere(up)!==!1&&(Op.getInverse(gt),Kh.copy(f.ray).applyMatrix4(Op),ge.boundingBox===null||Kh.intersectsBox(ge.boundingBox)!==!1))){if(ge.isBufferGeometry){var St,Pt,sn,ln,Sn,En,On,mn,Hn,mr=ge.index,_r=ge.attributes.position,gi=ge.morphAttributes.position,Ci=ge.morphTargetsRelative,$i=ge.attributes.uv,da=ge.attributes.uv2,ji=ge.groups,Sa=ge.drawRange;if(mr!==null)if(Array.isArray(ct))for(ln=0,En=ji.length;ln<En;ln++)for(Hn=ct[(mn=ji[ln]).materialIndex],Sn=Math.max(mn.start,Sa.start),On=Math.min(mn.start+mn.count,Sa.start+Sa.count);Sn<On;Sn+=3)St=mr.getX(Sn),Pt=mr.getX(Sn+1),sn=mr.getX(Sn+2),(W=nf(this,Hn,f,Kh,_r,gi,Ci,$i,da,St,Pt,sn))&&(W.faceIndex=Math.floor(Sn/3),W.face.materialIndex=mn.materialIndex,E.push(W));else for(ln=Math.max(0,Sa.start),En=Math.min(mr.count,Sa.start+Sa.count);ln<En;ln+=3)St=mr.getX(ln),Pt=mr.getX(ln+1),sn=mr.getX(ln+2),(W=nf(this,ct,f,Kh,_r,gi,Ci,$i,da,St,Pt,sn))&&(W.faceIndex=Math.floor(ln/3),E.push(W));else if(_r!==void 0)if(Array.isArray(ct))for(ln=0,En=ji.length;ln<En;ln++)for(Hn=ct[(mn=ji[ln]).materialIndex],Sn=Math.max(mn.start,Sa.start),On=Math.min(mn.start+mn.count,Sa.start+Sa.count);Sn<On;Sn+=3)(W=nf(this,Hn,f,Kh,_r,gi,Ci,$i,da,St=Sn,Pt=Sn+1,sn=Sn+2))&&(W.faceIndex=Math.floor(Sn/3),W.face.materialIndex=mn.materialIndex,E.push(W));else for(ln=Math.max(0,Sa.start),En=Math.min(_r.count,Sa.start+Sa.count);ln<En;ln+=3)(W=nf(this,ct,f,Kh,_r,gi,Ci,$i,da,St=ln,Pt=ln+1,sn=ln+2))&&(W.faceIndex=Math.floor(ln/3),E.push(W))}else if(ge.isGeometry){var ea,Ba,Ya,ro,$a=Array.isArray(ct),go=ge.vertices,ko=ge.faces,Qa=ge.faceVertexUvs[0];0<Qa.length&&(ro=Qa);for(var Ha=0,fs=ko.length;Ha<fs;Ha++){var os=ko[Ha],Ks=$a?ct[os.materialIndex]:ct;if(Ks!==void 0&&(ea=go[os.a],Ba=go[os.b],Ya=go[os.c],W=Od(this,Ks,f,Kh,ea,Ba,Ya,yc))){if(ro&&ro[Ha]){var Xs=ro[Ha];Lp.copy(Xs[0]),Ah.copy(Xs[1]),cp.copy(Xs[2]),W.uv=qu.getUV(yc,ea,Ba,Ya,Lp,Ah,cp,new co)}W.face=os,W.faceIndex=Ha,E.push(W)}}}}},clone:function(){return new this.constructor(this.geometry,this.material).copy(this)}});var Wf=0,Sc=new Vo,Sf=new Ri,vc=new yi;function ul(){Object.defineProperty(this,"id",{value:Wf+=2}),this.uuid=js.generateUUID(),this.name="",this.type="Geometry",this.vertices=[],this.colors=[],this.faces=[],this.faceVertexUvs=[[]],this.morphTargets=[],this.morphNormals=[],this.skinWeights=[],this.skinIndices=[],this.lineDistances=[],this.boundingBox=null,this.boundingSphere=null,this.elementsNeedUpdate=!1,this.verticesNeedUpdate=!1,this.uvsNeedUpdate=!1,this.normalsNeedUpdate=!1,this.colorsNeedUpdate=!1,this.lineDistancesNeedUpdate=!1,this.groupsNeedUpdate=!1}ul.prototype=Object.assign(Object.create(Ku.prototype),{constructor:ul,isGeometry:!0,applyMatrix4:function(f){for(var E=new Vl().getNormalMatrix(f),W=0,ge=this.vertices.length;W<ge;W++)this.vertices[W].applyMatrix4(f);for(W=0,ge=this.faces.length;W<ge;W++){var ct=this.faces[W];ct.normal.applyMatrix3(E).normalize();for(var gt=0,St=ct.vertexNormals.length;gt<St;gt++)ct.vertexNormals[gt].applyMatrix3(E).normalize()}return this.boundingBox!==null&&this.computeBoundingBox(),this.boundingSphere!==null&&this.computeBoundingSphere(),this.verticesNeedUpdate=!0,this.normalsNeedUpdate=!0,this},rotateX:function(f){return Sc.makeRotationX(f),this.applyMatrix4(Sc),this},rotateY:function(f){return Sc.makeRotationY(f),this.applyMatrix4(Sc),this},rotateZ:function(f){return Sc.makeRotationZ(f),this.applyMatrix4(Sc),this},translate:function(f,E,W){return Sc.makeTranslation(f,E,W),this.applyMatrix4(Sc),this},scale:function(f,E,W){return Sc.makeScale(f,E,W),this.applyMatrix4(Sc),this},lookAt:function(f){return Sf.lookAt(f),Sf.updateMatrix(),this.applyMatrix4(Sf.matrix),this},fromBufferGeometry:function(f){var E=this,W=f.index!==null?f.index.array:void 0,ge=f.attributes;if(ge.position===void 0)return console.error("THREE.Geometry.fromBufferGeometry(): Position attribute required for conversion."),this;var ct=ge.position.array,gt=ge.normal!==void 0?ge.normal.array:void 0,St=ge.color!==void 0?ge.color.array:void 0,Pt=ge.uv!==void 0?ge.uv.array:void 0,sn=ge.uv2!==void 0?ge.uv2.array:void 0;sn!==void 0&&(this.faceVertexUvs[1]=[]);for(var ln=0;ln<ct.length;ln+=3)E.vertices.push(new yi().fromArray(ct,ln)),St!==void 0&&E.colors.push(new la().fromArray(St,ln));function Sn(_r,gi,Ci,$i){var da=St===void 0?[]:[E.colors[_r].clone(),E.colors[gi].clone(),E.colors[Ci].clone()],ji=new Xo(_r,gi,Ci,gt===void 0?[]:[new yi().fromArray(gt,3*_r),new yi().fromArray(gt,3*gi),new yi().fromArray(gt,3*Ci)],da,$i);E.faces.push(ji),Pt!==void 0&&E.faceVertexUvs[0].push([new co().fromArray(Pt,2*_r),new co().fromArray(Pt,2*gi),new co().fromArray(Pt,2*Ci)]),sn!==void 0&&E.faceVertexUvs[1].push([new co().fromArray(sn,2*_r),new co().fromArray(sn,2*gi),new co().fromArray(sn,2*Ci)])}var En=f.groups;if(0<En.length)for(ln=0;ln<En.length;ln++)for(var On=En[ln],mn=On.start,Hn=mn,mr=mn+On.count;Hn<mr;Hn+=3)W!==void 0?Sn(W[Hn],W[Hn+1],W[Hn+2],On.materialIndex):Sn(Hn,Hn+1,Hn+2,On.materialIndex);else if(W!==void 0)for(ln=0;ln<W.length;ln+=3)Sn(W[ln],W[ln+1],W[ln+2]);else for(ln=0;ln<ct.length/3;ln+=3)Sn(ln,ln+1,ln+2);return this.computeFaceNormals(),f.boundingBox!==null&&(this.boundingBox=f.boundingBox.clone()),f.boundingSphere!==null&&(this.boundingSphere=f.boundingSphere.clone()),this},center:function(){return this.computeBoundingBox(),this.boundingBox.getCenter(vc).negate(),this.translate(vc.x,vc.y,vc.z),this},normalize:function(){this.computeBoundingSphere();var f=this.boundingSphere.center,E=this.boundingSphere.radius,W=E===0?1:1/E,ge=new Vo;return ge.set(W,0,0,-W*f.x,0,W,0,-W*f.y,0,0,W,-W*f.z,0,0,0,1),this.applyMatrix4(ge),this},computeFaceNormals:function(){for(var f=new yi,E=new yi,W=0,ge=this.faces.length;W<ge;W++){var ct=this.faces[W],gt=this.vertices[ct.a],St=this.vertices[ct.b],Pt=this.vertices[ct.c];f.subVectors(Pt,St),E.subVectors(gt,St),f.cross(E),f.normalize(),ct.normal.copy(f)}},computeVertexNormals:function(f){var E,W,ge,ct,gt,St;for(f===void 0&&(f=!0),St=new Array(this.vertices.length),E=0,W=this.vertices.length;E<W;E++)St[E]=new yi;if(f){var Pt,sn,ln,Sn=new yi,En=new yi;for(ge=0,ct=this.faces.length;ge<ct;ge++)gt=this.faces[ge],Pt=this.vertices[gt.a],sn=this.vertices[gt.b],ln=this.vertices[gt.c],Sn.subVectors(ln,sn),En.subVectors(Pt,sn),Sn.cross(En),St[gt.a].add(Sn),St[gt.b].add(Sn),St[gt.c].add(Sn)}else for(this.computeFaceNormals(),ge=0,ct=this.faces.length;ge<ct;ge++)St[(gt=this.faces[ge]).a].add(gt.normal),St[gt.b].add(gt.normal),St[gt.c].add(gt.normal);for(E=0,W=this.vertices.length;E<W;E++)St[E].normalize();for(ge=0,ct=this.faces.length;ge<ct;ge++){var On=(gt=this.faces[ge]).vertexNormals;On.length===3?(On[0].copy(St[gt.a]),On[1].copy(St[gt.b]),On[2].copy(St[gt.c])):(On[0]=St[gt.a].clone(),On[1]=St[gt.b].clone(),On[2]=St[gt.c].clone())}0<this.faces.length&&(this.normalsNeedUpdate=!0)},computeFlatVertexNormals:function(){var f,E,W;for(this.computeFaceNormals(),f=0,E=this.faces.length;f<E;f++){var ge=(W=this.faces[f]).vertexNormals;ge.length===3?(ge[0].copy(W.normal),ge[1].copy(W.normal),ge[2].copy(W.normal)):(ge[0]=W.normal.clone(),ge[1]=W.normal.clone(),ge[2]=W.normal.clone())}0<this.faces.length&&(this.normalsNeedUpdate=!0)},computeMorphNormals:function(){var f,E,W,ge,ct;for(W=0,ge=this.faces.length;W<ge;W++)for((ct=this.faces[W]).__originalFaceNormal?ct.__originalFaceNormal.copy(ct.normal):ct.__originalFaceNormal=ct.normal.clone(),ct.__originalVertexNormals||(ct.__originalVertexNormals=[]),f=0,E=ct.vertexNormals.length;f<E;f++)ct.__originalVertexNormals[f]?ct.__originalVertexNormals[f].copy(ct.vertexNormals[f]):ct.__originalVertexNormals[f]=ct.vertexNormals[f].clone();var gt=new ul;for(gt.faces=this.faces,f=0,E=this.morphTargets.length;f<E;f++){if(!this.morphNormals[f]){this.morphNormals[f]={},this.morphNormals[f].faceNormals=[],this.morphNormals[f].vertexNormals=[];var St=this.morphNormals[f].faceNormals,Pt=this.morphNormals[f].vertexNormals;for(W=0,ge=this.faces.length;W<ge;W++)sn=new yi,ln={a:new yi,b:new yi,c:new yi},St.push(sn),Pt.push(ln)}var sn,ln,Sn=this.morphNormals[f];for(gt.vertices=this.morphTargets[f].vertices,gt.computeFaceNormals(),gt.computeVertexNormals(),W=0,ge=this.faces.length;W<ge;W++)ct=this.faces[W],sn=Sn.faceNormals[W],ln=Sn.vertexNormals[W],sn.copy(ct.normal),ln.a.copy(ct.vertexNormals[0]),ln.b.copy(ct.vertexNormals[1]),ln.c.copy(ct.vertexNormals[2])}for(W=0,ge=this.faces.length;W<ge;W++)(ct=this.faces[W]).normal=ct.__originalFaceNormal,ct.vertexNormals=ct.__originalVertexNormals},computeBoundingBox:function(){this.boundingBox===null&&(this.boundingBox=new Xu),this.boundingBox.setFromPoints(this.vertices)},computeBoundingSphere:function(){this.boundingSphere===null&&(this.boundingSphere=new Nl),this.boundingSphere.setFromPoints(this.vertices)},merge:function(f,E,W){if(f&&f.isGeometry){var ge,ct=this.vertices.length,gt=this.vertices,St=f.vertices,Pt=this.faces,sn=f.faces,ln=this.colors,Sn=f.colors;W===void 0&&(W=0),E!==void 0&&(ge=new Vl().getNormalMatrix(E));for(var En=0,On=St.length;En<On;En++){var mn=St[En].clone();E!==void 0&&mn.applyMatrix4(E),gt.push(mn)}for(En=0,On=Sn.length;En<On;En++)ln.push(Sn[En].clone());for(En=0,On=sn.length;En<On;En++){var Hn,mr,_r,gi=sn[En],Ci=gi.vertexNormals,$i=gi.vertexColors;(Hn=new Xo(gi.a+ct,gi.b+ct,gi.c+ct)).normal.copy(gi.normal),ge!==void 0&&Hn.normal.applyMatrix3(ge).normalize();for(var da=0,ji=Ci.length;da<ji;da++)mr=Ci[da].clone(),ge!==void 0&&mr.applyMatrix3(ge).normalize(),Hn.vertexNormals.push(mr);for(Hn.color.copy(gi.color),da=0,ji=$i.length;da<ji;da++)_r=$i[da],Hn.vertexColors.push(_r.clone());Hn.materialIndex=gi.materialIndex+W,Pt.push(Hn)}for(En=0,On=f.faceVertexUvs.length;En<On;En++){var Sa=f.faceVertexUvs[En];for(this.faceVertexUvs[En]===void 0&&(this.faceVertexUvs[En]=[]),da=0,ji=Sa.length;da<ji;da++){for(var ea=Sa[da],Ba=[],Ya=0,ro=ea.length;Ya<ro;Ya++)Ba.push(ea[Ya].clone());this.faceVertexUvs[En].push(Ba)}}}else console.error("THREE.Geometry.merge(): geometry not an instance of THREE.Geometry.",f)},mergeMesh:function(f){f&&f.isMesh?(f.matrixAutoUpdate&&f.updateMatrix(),this.merge(f.geometry,f.matrix)):console.error("THREE.Geometry.mergeMesh(): mesh not an instance of THREE.Mesh.",f)},mergeVertices:function(){var f,E,W,ge,ct,gt,St,Pt,sn={},ln=[],Sn=[],En=Math.pow(10,4);for(W=0,ge=this.vertices.length;W<ge;W++)f=this.vertices[W],sn[E=Math.round(f.x*En)+"_"+Math.round(f.y*En)+"_"+Math.round(f.z*En)]===void 0?(sn[E]=W,ln.push(this.vertices[W]),Sn[W]=ln.length-1):Sn[W]=Sn[sn[E]];var On=[];for(W=0,ge=this.faces.length;W<ge;W++){(ct=this.faces[W]).a=Sn[ct.a],ct.b=Sn[ct.b],ct.c=Sn[ct.c],gt=[ct.a,ct.b,ct.c];for(var mn=0;mn<3;mn++)if(gt[mn]===gt[(mn+1)%3]){On.push(W);break}}for(W=On.length-1;0<=W;W--){var Hn=On[W];for(this.faces.splice(Hn,1),St=0,Pt=this.faceVertexUvs.length;St<Pt;St++)this.faceVertexUvs[St].splice(Hn,1)}var mr=this.vertices.length-ln.length;return this.vertices=ln,mr},setFromPoints:function(f){this.vertices=[];for(var E=0,W=f.length;E<W;E++){var ge=f[E];this.vertices.push(new yi(ge.x,ge.y,ge.z||0))}return this},sortFacesByMaterialIndex:function(){for(var f=this.faces,E=f.length,W=0;W<E;W++)f[W]._id=W;f.sort(function(sn,ln){return sn.materialIndex-ln.materialIndex});var ge,ct,gt=this.faceVertexUvs[0],St=this.faceVertexUvs[1];for(gt&>.length===E&&(ge=[]),St&&St.length===E&&(ct=[]),W=0;W<E;W++){var Pt=f[W]._id;ge&&ge.push(gt[Pt]),ct&&ct.push(St[Pt])}ge&&(this.faceVertexUvs[0]=ge),ct&&(this.faceVertexUvs[1]=ct)},toJSON:function(){var f={metadata:{version:4.5,type:"Geometry",generator:"Geometry.toJSON"}};if(f.uuid=this.uuid,f.type=this.type,this.name!==""&&(f.name=this.name),this.parameters!==void 0){var E=this.parameters;for(var W in E)E[W]!==void 0&&(f[W]=E[W]);return f}for(var ge=[],ct=0;ct<this.vertices.length;ct++){var gt=this.vertices[ct];ge.push(gt.x,gt.y,gt.z)}var St=[],Pt=[],sn={},ln=[],Sn={},En=[],On={};for(ct=0;ct<this.faces.length;ct++){var mn=this.faces[ct],Hn=this.faceVertexUvs[0][ct]!==void 0,mr=0<mn.normal.length(),_r=0<mn.vertexNormals.length,gi=mn.color.r!==1||mn.color.g!==1||mn.color.b!==1,Ci=0<mn.vertexColors.length,$i=0;if($i=ea($i=ea($i=ea($i=ea($i=ea($i=ea($i=ea($i=ea($i,0,0),1,!0),2,!1),3,Hn),4,mr),5,_r),6,gi),7,Ci),St.push($i),St.push(mn.a,mn.b,mn.c),St.push(mn.materialIndex),Hn){var da=this.faceVertexUvs[0][ct];St.push(ro(da[0]),ro(da[1]),ro(da[2]))}if(mr&&St.push(Ba(mn.normal)),_r){var ji=mn.vertexNormals;St.push(Ba(ji[0]),Ba(ji[1]),Ba(ji[2]))}if(gi&&St.push(Ya(mn.color)),Ci){var Sa=mn.vertexColors;St.push(Ya(Sa[0]),Ya(Sa[1]),Ya(Sa[2]))}}function ea($a,go,ko){return ko?$a|1<<go:$a&~(1<<go)}function Ba($a){var go=$a.x.toString()+$a.y.toString()+$a.z.toString();return sn[go]!==void 0||(sn[go]=Pt.length/3,Pt.push($a.x,$a.y,$a.z)),sn[go]}function Ya($a){var go=$a.r.toString()+$a.g.toString()+$a.b.toString();return Sn[go]!==void 0||(Sn[go]=ln.length,ln.push($a.getHex())),Sn[go]}function ro($a){var go=$a.x.toString()+$a.y.toString();return On[go]!==void 0||(On[go]=En.length/2,En.push($a.x,$a.y)),On[go]}return f.data={},f.data.vertices=ge,f.data.normals=Pt,0<ln.length&&(f.data.colors=ln),0<En.length&&(f.data.uvs=[En]),f.data.faces=St,f},clone:function(){return new ul().copy(this)},copy:function(f){var E,W,ge,ct,gt,St;this.vertices=[],this.colors=[],this.faces=[],this.faceVertexUvs=[[]],this.morphTargets=[],this.morphNormals=[],this.skinWeights=[],this.skinIndices=[],this.lineDistances=[],this.boundingBox=null,this.boundingSphere=null,this.name=f.name;var Pt=f.vertices;for(E=0,W=Pt.length;E<W;E++)this.vertices.push(Pt[E].clone());var sn=f.colors;for(E=0,W=sn.length;E<W;E++)this.colors.push(sn[E].clone());var ln=f.faces;for(E=0,W=ln.length;E<W;E++)this.faces.push(ln[E].clone());for(E=0,W=f.faceVertexUvs.length;E<W;E++){var Sn=f.faceVertexUvs[E];for(this.faceVertexUvs[E]===void 0&&(this.faceVertexUvs[E]=[]),ge=0,ct=Sn.length;ge<ct;ge++){var En=Sn[ge],On=[];for(gt=0,St=En.length;gt<St;gt++){var mn=En[gt];On.push(mn.clone())}this.faceVertexUvs[E].push(On)}}var Hn=f.morphTargets;for(E=0,W=Hn.length;E<W;E++){var mr={};if(mr.name=Hn[E].name,Hn[E].vertices!==void 0)for(mr.vertices=[],ge=0,ct=Hn[E].vertices.length;ge<ct;ge++)mr.vertices.push(Hn[E].vertices[ge].clone());if(Hn[E].normals!==void 0)for(mr.normals=[],ge=0,ct=Hn[E].normals.length;ge<ct;ge++)mr.normals.push(Hn[E].normals[ge].clone());this.morphTargets.push(mr)}var _r=f.morphNormals;for(E=0,W=_r.length;E<W;E++){var gi={};if(_r[E].vertexNormals!==void 0)for(gi.vertexNormals=[],ge=0,ct=_r[E].vertexNormals.length;ge<ct;ge++){var Ci=_r[E].vertexNormals[ge],$i={};$i.a=Ci.a.clone(),$i.b=Ci.b.clone(),$i.c=Ci.c.clone(),gi.vertexNormals.push($i)}if(_r[E].faceNormals!==void 0)for(gi.faceNormals=[],ge=0,ct=_r[E].faceNormals.length;ge<ct;ge++)gi.faceNormals.push(_r[E].faceNormals[ge].clone());this.morphNormals.push(gi)}var da=f.skinWeights;for(E=0,W=da.length;E<W;E++)this.skinWeights.push(da[E].clone());var ji=f.skinIndices;for(E=0,W=ji.length;E<W;E++)this.skinIndices.push(ji[E].clone());var Sa=f.lineDistances;for(E=0,W=Sa.length;E<W;E++)this.lineDistances.push(Sa[E]);var ea=f.boundingBox;ea!==null&&(this.boundingBox=ea.clone());var Ba=f.boundingSphere;return Ba!==null&&(this.boundingSphere=Ba.clone()),this.elementsNeedUpdate=f.elementsNeedUpdate,this.verticesNeedUpdate=f.verticesNeedUpdate,this.uvsNeedUpdate=f.uvsNeedUpdate,this.normalsNeedUpdate=f.normalsNeedUpdate,this.colorsNeedUpdate=f.colorsNeedUpdate,this.lineDistancesNeedUpdate=f.lineDistancesNeedUpdate,this.groupsNeedUpdate=f.groupsNeedUpdate,this},dispose:function(){this.dispatchEvent({type:"dispose"})}});var dp=function(f){function E(W,ge,ct,gt,St,Pt){f.call(this),this.type="BoxGeometry",this.parameters={width:W,height:ge,depth:ct,widthSegments:gt,heightSegments:St,depthSegments:Pt},this.fromBufferGeometry(new Zo(W,ge,ct,gt,St,Pt)),this.mergeVertices()}return f&&(E.__proto__=f),(E.prototype=Object.create(f&&f.prototype)).constructor=E}(ul),Zo=function(f){function E(W,ge,ct,gt,St,Pt){f.call(this),this.type="BoxBufferGeometry",this.parameters={width:W,height:ge,depth:ct,widthSegments:gt,heightSegments:St,depthSegments:Pt};var sn=this;W=W||1,ge=ge||1,ct=ct||1,gt=Math.floor(gt)||1,St=Math.floor(St)||1;var ln=[],Sn=[],En=[],On=[],mn=0,Hn=0;function mr(_r,gi,Ci,$i,da,ji,Sa,ea,Ba,Ya,ro){var $a,go,ko=ji/Ba,Qa=Sa/Ya,Ha=ji/2,fs=Sa/2,os=ea/2,Ks=Ba+1,Xs=Ya+1,zs=0,gl=0,Os=new yi;for(go=0;go<Xs;go++){var Ii=go*Qa-fs;for($a=0;$a<Ks;$a++){var va=$a*ko-Ha;Os[_r]=va*$i,Os[gi]=Ii*da,Os[Ci]=os,Sn.push(Os.x,Os.y,Os.z),Os[_r]=0,Os[gi]=0,Os[Ci]=0<ea?1:-1,En.push(Os.x,Os.y,Os.z),On.push($a/Ba),On.push(1-go/Ya),zs+=1}}for(go=0;go<Ya;go++)for($a=0;$a<Ba;$a++){var Bo=mn+$a+Ks*go,Co=mn+$a+Ks*(go+1),Cl=mn+($a+1)+Ks*(go+1),Us=mn+($a+1)+Ks*go;ln.push(Bo,Co,Us),ln.push(Co,Cl,Us),gl+=6}sn.addGroup(Hn,gl,ro),Hn+=gl,mn+=zs}mr("z","y","x",-1,-1,ct,ge,W,Pt=Math.floor(Pt)||1,St,0),mr("z","y","x",1,-1,ct,ge,-W,Pt,St,1),mr("x","z","y",1,1,W,ct,ge,gt,Pt,2),mr("x","z","y",1,-1,W,ct,-ge,gt,Pt,3),mr("x","y","z",1,-1,W,ge,ct,gt,St,4),mr("x","y","z",-1,-1,W,ge,-ct,gt,St,5),this.setIndex(ln),this.setAttribute("position",new io(Sn,3)),this.setAttribute("normal",new io(En,3)),this.setAttribute("uv",new io(On,2))}return f&&(E.__proto__=f),(E.prototype=Object.create(f&&f.prototype)).constructor=E}(Ds);function Xh(f){var E={};for(var W in f)for(var ge in E[W]={},f[W]){var ct=f[W][ge];ct&&(ct.isColor||ct.isMatrix3||ct.isMatrix4||ct.isVector2||ct.isVector3||ct.isVector4||ct.isTexture)?E[W][ge]=ct.clone():Array.isArray(ct)?E[W][ge]=ct.slice():E[W][ge]=ct}return E}function kc(f){for(var E={},W=0;W<f.length;W++){var ge=Xh(f[W]);for(var ct in ge)E[ct]=ge[ct]}return E}var Fp={clone:Xh,merge:kc},kh=`void main() {
- gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );
- }`,Tf=`void main() {
- gl_FragColor = vec4( 1.0, 0.0, 0.0, 1.0 );
- }`;function Ld(f){ii.call(this),this.type="ShaderMaterial",this.defines={},this.uniforms={},this.vertexShader=kh,this.fragmentShader=Tf,this.linewidth=1,this.wireframe=!1,this.wireframeLinewidth=1,this.fog=!1,this.lights=!1,this.clipping=!1,this.skinning=!1,this.morphTargets=!1,this.morphNormals=!1,this.extensions={derivatives:!1,fragDepth:!1,drawBuffers:!1,shaderTextureLOD:!1},this.defaultAttributeValues={color:[1,1,1],uv:[0,0],uv2:[0,0]},this.index0AttributeName=void 0,this.uniformsNeedUpdate=!1,f!==void 0&&(f.attributes!==void 0&&console.error("THREE.ShaderMaterial: attributes should now be defined in THREE.BufferGeometry instead."),this.setValues(f))}function Gd(){Ri.call(this),this.type="Camera",this.matrixWorldInverse=new Vo,this.projectionMatrix=new Vo,this.projectionMatrixInverse=new Vo}function cc(f,E,W,ge){Gd.call(this),this.type="PerspectiveCamera",this.fov=f!==void 0?f:50,this.zoom=1,this.near=W!==void 0?W:.1,this.far=ge!==void 0?ge:2e3,this.focus=10,this.aspect=E!==void 0?E:1,this.view=null,this.filmGauge=35,this.filmOffset=0,this.updateProjectionMatrix()}function Jh(f,E,W,ge){Ri.call(this),this.type="CubeCamera";var ct=new cc(90,1,f,E);ct.up.set(0,-1,0),ct.lookAt(new yi(1,0,0)),this.add(ct);var gt=new cc(90,1,f,E);gt.up.set(0,-1,0),gt.lookAt(new yi(-1,0,0)),this.add(gt);var St=new cc(90,1,f,E);St.up.set(0,0,1),St.lookAt(new yi(0,1,0)),this.add(St);var Pt=new cc(90,1,f,E);Pt.up.set(0,0,-1),Pt.lookAt(new yi(0,-1,0)),this.add(Pt);var sn=new cc(90,1,f,E);sn.up.set(0,-1,0),sn.lookAt(new yi(0,0,1)),this.add(sn);var ln=new cc(90,1,f,E);ln.up.set(0,-1,0),ln.lookAt(new yi(0,0,-1)),this.add(ln),ge=ge||{format:il,magFilter:hi,minFilter:hi},this.renderTarget=new hp(W,ge),this.renderTarget.texture.name="CubeCamera",this.update=function(Sn,En){this.parent===null&&this.updateMatrixWorld();var On=Sn.getRenderTarget(),mn=this.renderTarget,Hn=mn.texture.generateMipmaps;mn.texture.generateMipmaps=!1,Sn.setRenderTarget(mn,0),Sn.render(En,ct),Sn.setRenderTarget(mn,1),Sn.render(En,gt),Sn.setRenderTarget(mn,2),Sn.render(En,St),Sn.setRenderTarget(mn,3),Sn.render(En,Pt),Sn.setRenderTarget(mn,4),Sn.render(En,sn),mn.texture.generateMipmaps=Hn,Sn.setRenderTarget(mn,5),Sn.render(En,ln),Sn.setRenderTarget(On)},this.clear=function(Sn,En,On,mn){for(var Hn=Sn.getRenderTarget(),mr=this.renderTarget,_r=0;_r<6;_r++)Sn.setRenderTarget(mr,_r),Sn.clear(En,On,mn);Sn.setRenderTarget(Hn)}}function hp(f,E,W){Number.isInteger(E)&&(console.warn("THREE.WebGLCubeRenderTarget: constructor signature is now WebGLCubeRenderTarget( size, options )"),E=W),Au.call(this,f,f,E)}function pp(f,E,W,ge,ct,gt,St,Pt,sn,ln,Sn,En){Ql.call(this,null,gt,St,Pt,sn,ln,ge,ct,Sn,En),this.image={data:f||null,width:E||1,height:W||1},this.magFilter=sn!==void 0?sn:un,this.minFilter=ln!==void 0?ln:un,this.generateMipmaps=!1,this.flipY=!1,this.unpackAlignment=1,this.needsUpdate=!0}((Ld.prototype=Object.create(ii.prototype)).constructor=Ld).prototype.isShaderMaterial=!0,Ld.prototype.copy=function(f){return ii.prototype.copy.call(this,f),this.fragmentShader=f.fragmentShader,this.vertexShader=f.vertexShader,this.uniforms=Xh(f.uniforms),this.defines=Object.assign({},f.defines),this.wireframe=f.wireframe,this.wireframeLinewidth=f.wireframeLinewidth,this.lights=f.lights,this.clipping=f.clipping,this.skinning=f.skinning,this.morphTargets=f.morphTargets,this.morphNormals=f.morphNormals,this.extensions=f.extensions,this},Ld.prototype.toJSON=function(f){var E=ii.prototype.toJSON.call(this,f);for(var W in E.uniforms={},this.uniforms){var ge=this.uniforms[W].value;ge&&ge.isTexture?E.uniforms[W]={type:"t",value:ge.toJSON(f).uuid}:ge&&ge.isColor?E.uniforms[W]={type:"c",value:ge.getHex()}:ge&&ge.isVector2?E.uniforms[W]={type:"v2",value:ge.toArray()}:ge&&ge.isVector3?E.uniforms[W]={type:"v3",value:ge.toArray()}:ge&&ge.isVector4?E.uniforms[W]={type:"v4",value:ge.toArray()}:ge&&ge.isMatrix3?E.uniforms[W]={type:"m3",value:ge.toArray()}:ge&&ge.isMatrix4?E.uniforms[W]={type:"m4",value:ge.toArray()}:E.uniforms[W]={value:ge}}0<Object.keys(this.defines).length&&(E.defines=this.defines),E.vertexShader=this.vertexShader,E.fragmentShader=this.fragmentShader;var ct={};for(var gt in this.extensions)this.extensions[gt]===!0&&(ct[gt]=!0);return 0<Object.keys(ct).length&&(E.extensions=ct),E},Gd.prototype=Object.assign(Object.create(Ri.prototype),{constructor:Gd,isCamera:!0,copy:function(f,E){return Ri.prototype.copy.call(this,f,E),this.matrixWorldInverse.copy(f.matrixWorldInverse),this.projectionMatrix.copy(f.projectionMatrix),this.projectionMatrixInverse.copy(f.projectionMatrixInverse),this},getWorldDirection:function(f){f===void 0&&(console.warn("THREE.Camera: .getWorldDirection() target is now required"),f=new yi),this.updateMatrixWorld(!0);var E=this.matrixWorld.elements;return f.set(-E[8],-E[9],-E[10]).normalize()},updateMatrixWorld:function(f){Ri.prototype.updateMatrixWorld.call(this,f),this.matrixWorldInverse.getInverse(this.matrixWorld)},updateWorldMatrix:function(f,E){Ri.prototype.updateWorldMatrix.call(this,f,E),this.matrixWorldInverse.getInverse(this.matrixWorld)},clone:function(){return new this.constructor().copy(this)}}),cc.prototype=Object.assign(Object.create(Gd.prototype),{constructor:cc,isPerspectiveCamera:!0,copy:function(f,E){return Gd.prototype.copy.call(this,f,E),this.fov=f.fov,this.zoom=f.zoom,this.near=f.near,this.far=f.far,this.focus=f.focus,this.aspect=f.aspect,this.view=f.view===null?null:Object.assign({},f.view),this.filmGauge=f.filmGauge,this.filmOffset=f.filmOffset,this},setFocalLength:function(f){var E=.5*this.getFilmHeight()/f;this.fov=2*js.RAD2DEG*Math.atan(E),this.updateProjectionMatrix()},getFocalLength:function(){var f=Math.tan(.5*js.DEG2RAD*this.fov);return .5*this.getFilmHeight()/f},getEffectiveFOV:function(){return 2*js.RAD2DEG*Math.atan(Math.tan(.5*js.DEG2RAD*this.fov)/this.zoom)},getFilmWidth:function(){return this.filmGauge*Math.min(this.aspect,1)},getFilmHeight:function(){return this.filmGauge/Math.max(this.aspect,1)},setViewOffset:function(f,E,W,ge,ct,gt){this.aspect=f/E,this.view===null&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=f,this.view.fullHeight=E,this.view.offsetX=W,this.view.offsetY=ge,this.view.width=ct,this.view.height=gt,this.updateProjectionMatrix()},clearViewOffset:function(){this.view!==null&&(this.view.enabled=!1),this.updateProjectionMatrix()},updateProjectionMatrix:function(){var f=this.near,E=f*Math.tan(.5*js.DEG2RAD*this.fov)/this.zoom,W=2*E,ge=this.aspect*W,ct=-.5*ge,gt=this.view;if(this.view!==null&&this.view.enabled){var St=gt.fullWidth,Pt=gt.fullHeight;ct+=gt.offsetX*ge/St,E-=gt.offsetY*W/Pt,ge*=gt.width/St,W*=gt.height/Pt}var sn=this.filmOffset;sn!==0&&(ct+=f*sn/this.getFilmWidth()),this.projectionMatrix.makePerspective(ct,ct+ge,E,E-W,f,this.far),this.projectionMatrixInverse.getInverse(this.projectionMatrix)},toJSON:function(f){var E=Ri.prototype.toJSON.call(this,f);return E.object.fov=this.fov,E.object.zoom=this.zoom,E.object.near=this.near,E.object.far=this.far,E.object.focus=this.focus,E.object.aspect=this.aspect,this.view!==null&&(E.object.view=Object.assign({},this.view)),E.object.filmGauge=this.filmGauge,E.object.filmOffset=this.filmOffset,E}}),(Jh.prototype=Object.create(Ri.prototype)).constructor=Jh,((hp.prototype=Object.create(Au.prototype)).constructor=hp).prototype.isWebGLCubeRenderTarget=!0,hp.prototype.fromEquirectangularTexture=function(f,E){this.texture.type=E.type,this.texture.format=E.format,this.texture.encoding=E.encoding;var W=new fa,ge={uniforms:{tEquirect:{value:null}},vertexShader:["varying vec3 vWorldDirection;","vec3 transformDirection( in vec3 dir, in mat4 matrix ) {"," return normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );","}","void main() {"," vWorldDirection = transformDirection( position, modelMatrix );"," #include <begin_vertex>"," #include <project_vertex>","}"].join(`
- `),fragmentShader:["uniform sampler2D tEquirect;","varying vec3 vWorldDirection;","#define RECIPROCAL_PI 0.31830988618","#define RECIPROCAL_PI2 0.15915494","void main() {"," vec3 direction = normalize( vWorldDirection );"," vec2 sampleUV;"," sampleUV.y = asin( clamp( direction.y, - 1.0, 1.0 ) ) * RECIPROCAL_PI + 0.5;"," sampleUV.x = atan( direction.z, direction.x ) * RECIPROCAL_PI2 + 0.5;"," gl_FragColor = texture2D( tEquirect, sampleUV );","}"].join(`
- `)},ct=new Ld({type:"CubemapFromEquirect",uniforms:Xh(ge.uniforms),vertexShader:ge.vertexShader,fragmentShader:ge.fragmentShader,side:q,blending:ve});ct.uniforms.tEquirect.value=E;var gt=new lu(new Zo(5,5,5),ct);W.add(gt);var St=new Jh(1,10,1);return St.renderTarget=this,St.renderTarget.texture.name="CubeCameraTexture",St.update(f,W),gt.geometry.dispose(),gt.material.dispose(),this},((pp.prototype=Object.create(Ql.prototype)).constructor=pp).prototype.isDataTexture=!0;var Ph=new Nl,mh=new yi;function Ih(f,E,W,ge,ct,gt){this.planes=[f!==void 0?f:new wu,E!==void 0?E:new wu,W!==void 0?W:new wu,ge!==void 0?ge:new wu,ct!==void 0?ct:new wu,gt!==void 0?gt:new wu]}Object.assign(Ih.prototype,{set:function(f,E,W,ge,ct,gt){var St=this.planes;return St[0].copy(f),St[1].copy(E),St[2].copy(W),St[3].copy(ge),St[4].copy(ct),St[5].copy(gt),this},clone:function(){return new this.constructor().copy(this)},copy:function(f){for(var E=this.planes,W=0;W<6;W++)E[W].copy(f.planes[W]);return this},setFromProjectionMatrix:function(f){var E=this.planes,W=f.elements,ge=W[0],ct=W[1],gt=W[2],St=W[3],Pt=W[4],sn=W[5],ln=W[6],Sn=W[7],En=W[8],On=W[9],mn=W[10],Hn=W[11],mr=W[12],_r=W[13],gi=W[14],Ci=W[15];return E[0].setComponents(St-ge,Sn-Pt,Hn-En,Ci-mr).normalize(),E[1].setComponents(St+ge,Sn+Pt,Hn+En,Ci+mr).normalize(),E[2].setComponents(St+ct,Sn+sn,Hn+On,Ci+_r).normalize(),E[3].setComponents(St-ct,Sn-sn,Hn-On,Ci-_r).normalize(),E[4].setComponents(St-gt,Sn-ln,Hn-mn,Ci-gi).normalize(),E[5].setComponents(St+gt,Sn+ln,Hn+mn,Ci+gi).normalize(),this},intersectsObject:function(f){var E=f.geometry;return E.boundingSphere===null&&E.computeBoundingSphere(),Ph.copy(E.boundingSphere).applyMatrix4(f.matrixWorld),this.intersectsSphere(Ph)},intersectsSprite:function(f){return Ph.center.set(0,0,0),Ph.radius=.7071067811865476,Ph.applyMatrix4(f.matrixWorld),this.intersectsSphere(Ph)},intersectsSphere:function(f){for(var E=this.planes,W=f.center,ge=-f.radius,ct=0;ct<6;ct++)if(E[ct].distanceToPoint(W)<ge)return!1;return!0},intersectsBox:function(f){for(var E=this.planes,W=0;W<6;W++){var ge=E[W];if(mh.x=0<ge.normal.x?f.max.x:f.min.x,mh.y=0<ge.normal.y?f.max.y:f.min.y,mh.z=0<ge.normal.z?f.max.z:f.min.z,ge.distanceToPoint(mh)<0)return!1}return!0},containsPoint:function(f){for(var E=this.planes,W=0;W<6;W++)if(E[W].distanceToPoint(f)<0)return!1;return!0}});var Ts={common:{diffuse:{value:new la(15658734)},opacity:{value:1},map:{value:null},uvTransform:{value:new Vl},uv2Transform:{value:new Vl},alphaMap:{value:null}},specularmap:{specularMap:{value:null}},envmap:{envMap:{value:null},flipEnvMap:{value:-1},reflectivity:{value:1},refractionRatio:{value:.98},maxMipLevel:{value:0}},aomap:{aoMap:{value:null},aoMapIntensity:{value:1}},lightmap:{lightMap:{value:null},lightMapIntensity:{value:1}},emissivemap:{emissiveMap:{value:null}},bumpmap:{bumpMap:{value:null},bumpScale:{value:1}},normalmap:{normalMap:{value:null},normalScale:{value:new co(1,1)}},displacementmap:{displacementMap:{value:null},displacementScale:{value:1},displacementBias:{value:0}},roughnessmap:{roughnessMap:{value:null}},metalnessmap:{metalnessMap:{value:null}},gradientmap:{gradientMap:{value:null}},fog:{fogDensity:{value:25e-5},fogNear:{value:1},fogFar:{value:2e3},fogColor:{value:new la(16777215)}},lights:{ambientLightColor:{value:[]},lightProbe:{value:[]},directionalLights:{value:[],properties:{direction:{},color:{},shadow:{},shadowBias:{},shadowRadius:{},shadowMapSize:{}}},directionalShadowMap:{value:[]},directionalShadowMatrix:{value:[]},spotLights:{value:[],properties:{color:{},position:{},direction:{},distance:{},coneCos:{},penumbraCos:{},decay:{},shadow:{},shadowBias:{},shadowRadius:{},shadowMapSize:{}}},spotShadowMap:{value:[]},spotShadowMatrix:{value:[]},pointLights:{value:[],properties:{color:{},position:{},decay:{},distance:{},shadow:{},shadowBias:{},shadowRadius:{},shadowMapSize:{},shadowCameraNear:{},shadowCameraFar:{}}},pointShadowMap:{value:[]},pointShadowMatrix:{value:[]},hemisphereLights:{value:[],properties:{direction:{},skyColor:{},groundColor:{}}},rectAreaLights:{value:[],properties:{color:{},position:{},width:{},height:{}}}},points:{diffuse:{value:new la(15658734)},opacity:{value:1},size:{value:1},scale:{value:1},map:{value:null},alphaMap:{value:null},uvTransform:{value:new Vl}},sprite:{diffuse:{value:new la(15658734)},opacity:{value:1},center:{value:new co(.5,.5)},rotation:{value:0},map:{value:null},alphaMap:{value:null},uvTransform:{value:new Vl}}};function qf(){var f=null,E=!1,W=null;function ge(ct,gt){E!==!1&&(W(ct,gt),f.requestAnimationFrame(ge))}return{start:function(){E!==!0&&W!==null&&(f.requestAnimationFrame(ge),E=!0)},stop:function(){E=!1},setAnimationLoop:function(ct){W=ct},setContext:function(ct){f=ct}}}function Bp(f,E,W,ge){ul.call(this),this.type="PlaneGeometry",this.parameters={width:f,height:E,widthSegments:W,heightSegments:ge},this.fromBufferGeometry(new Qh(f,E,W,ge)),this.mergeVertices()}function Qh(f,E,W,ge){Ds.call(this),this.type="PlaneBufferGeometry",this.parameters={width:f,height:E,widthSegments:W,heightSegments:ge};var ct,gt,St=(f=f||1)/2,Pt=(E=E||1)/2,sn=Math.floor(W)||1,ln=Math.floor(ge)||1,Sn=sn+1,En=ln+1,On=f/sn,mn=E/ln,Hn=[],mr=[],_r=[],gi=[];for(gt=0;gt<En;gt++){var Ci=gt*mn-Pt;for(ct=0;ct<Sn;ct++){var $i=ct*On-St;mr.push($i,-Ci,0),_r.push(0,0,1),gi.push(ct/sn),gi.push(1-gt/ln)}}for(gt=0;gt<ln;gt++)for(ct=0;ct<sn;ct++){var da=ct+Sn*gt,ji=ct+Sn*(gt+1),Sa=ct+1+Sn*(gt+1),ea=ct+1+Sn*gt;Hn.push(da,ji,ea),Hn.push(ji,Sa,ea)}this.setIndex(Hn),this.setAttribute("position",new io(mr,3)),this.setAttribute("normal",new io(_r,3)),this.setAttribute("uv",new io(gi,2))}(Bp.prototype=Object.create(ul.prototype)).constructor=Bp,(Qh.prototype=Object.create(Ds.prototype)).constructor=Qh;var ql={alphamap_fragment:`#ifdef USE_ALPHAMAP
- diffuseColor.a *= texture2D( alphaMap, vUv ).g;
- #endif`,alphamap_pars_fragment:`#ifdef USE_ALPHAMAP
- uniform sampler2D alphaMap;
- #endif`,alphatest_fragment:`#ifdef ALPHATEST
- if ( diffuseColor.a < ALPHATEST ) discard;
- #endif`,aomap_fragment:`#ifdef USE_AOMAP
- float ambientOcclusion = ( texture2D( aoMap, vUv2 ).r - 1.0 ) * aoMapIntensity + 1.0;
- reflectedLight.indirectDiffuse *= ambientOcclusion;
- #if defined( USE_ENVMAP ) && defined( STANDARD )
- float dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );
- reflectedLight.indirectSpecular *= computeSpecularOcclusion( dotNV, ambientOcclusion, material.specularRoughness );
- #endif
- #endif`,aomap_pars_fragment:`#ifdef USE_AOMAP
- uniform sampler2D aoMap;
- uniform float aoMapIntensity;
- #endif`,begin_vertex:"vec3 transformed = vec3( position );",beginnormal_vertex:`vec3 objectNormal = vec3( normal );
- #ifdef USE_TANGENT
- vec3 objectTangent = vec3( tangent.xyz );
- #endif`,bsdfs:`vec2 integrateSpecularBRDF( const in float dotNV, const in float roughness ) {
- const vec4 c0 = vec4( - 1, - 0.0275, - 0.572, 0.022 );
- const vec4 c1 = vec4( 1, 0.0425, 1.04, - 0.04 );
- vec4 r = roughness * c0 + c1;
- float a004 = min( r.x * r.x, exp2( - 9.28 * dotNV ) ) * r.x + r.y;
- return vec2( -1.04, 1.04 ) * a004 + r.zw;
- }
- float punctualLightIntensityToIrradianceFactor( const in float lightDistance, const in float cutoffDistance, const in float decayExponent ) {
- #if defined ( PHYSICALLY_CORRECT_LIGHTS )
- float distanceFalloff = 1.0 / max( pow( lightDistance, decayExponent ), 0.01 );
- if( cutoffDistance > 0.0 ) {
- distanceFalloff *= pow2( saturate( 1.0 - pow4( lightDistance / cutoffDistance ) ) );
- }
- return distanceFalloff;
- #else
- if( cutoffDistance > 0.0 && decayExponent > 0.0 ) {
- return pow( saturate( -lightDistance / cutoffDistance + 1.0 ), decayExponent );
- }
- return 1.0;
- #endif
- }
- vec3 BRDF_Diffuse_Lambert( const in vec3 diffuseColor ) {
- return RECIPROCAL_PI * diffuseColor;
- }
- vec3 F_Schlick( const in vec3 specularColor, const in float dotLH ) {
- float fresnel = exp2( ( -5.55473 * dotLH - 6.98316 ) * dotLH );
- return ( 1.0 - specularColor ) * fresnel + specularColor;
- }
- vec3 F_Schlick_RoughnessDependent( const in vec3 F0, const in float dotNV, const in float roughness ) {
- float fresnel = exp2( ( -5.55473 * dotNV - 6.98316 ) * dotNV );
- vec3 Fr = max( vec3( 1.0 - roughness ), F0 ) - F0;
- return Fr * fresnel + F0;
- }
- float G_GGX_Smith( const in float alpha, const in float dotNL, const in float dotNV ) {
- float a2 = pow2( alpha );
- float gl = dotNL + sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNL ) );
- float gv = dotNV + sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNV ) );
- return 1.0 / ( gl * gv );
- }
- float G_GGX_SmithCorrelated( const in float alpha, const in float dotNL, const in float dotNV ) {
- float a2 = pow2( alpha );
- float gv = dotNL * sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNV ) );
- float gl = dotNV * sqrt( a2 + ( 1.0 - a2 ) * pow2( dotNL ) );
- return 0.5 / max( gv + gl, EPSILON );
- }
- float D_GGX( const in float alpha, const in float dotNH ) {
- float a2 = pow2( alpha );
- float denom = pow2( dotNH ) * ( a2 - 1.0 ) + 1.0;
- return RECIPROCAL_PI * a2 / pow2( denom );
- }
- vec3 BRDF_Specular_GGX( const in IncidentLight incidentLight, const in vec3 viewDir, const in vec3 normal, const in vec3 specularColor, const in float roughness ) {
- float alpha = pow2( roughness );
- vec3 halfDir = normalize( incidentLight.direction + viewDir );
- float dotNL = saturate( dot( normal, incidentLight.direction ) );
- float dotNV = saturate( dot( normal, viewDir ) );
- float dotNH = saturate( dot( normal, halfDir ) );
- float dotLH = saturate( dot( incidentLight.direction, halfDir ) );
- vec3 F = F_Schlick( specularColor, dotLH );
- float G = G_GGX_SmithCorrelated( alpha, dotNL, dotNV );
- float D = D_GGX( alpha, dotNH );
- return F * ( G * D );
- }
- vec2 LTC_Uv( const in vec3 N, const in vec3 V, const in float roughness ) {
- const float LUT_SIZE = 64.0;
- const float LUT_SCALE = ( LUT_SIZE - 1.0 ) / LUT_SIZE;
- const float LUT_BIAS = 0.5 / LUT_SIZE;
- float dotNV = saturate( dot( N, V ) );
- vec2 uv = vec2( roughness, sqrt( 1.0 - dotNV ) );
- uv = uv * LUT_SCALE + LUT_BIAS;
- return uv;
- }
- float LTC_ClippedSphereFormFactor( const in vec3 f ) {
- float l = length( f );
- return max( ( l * l + f.z ) / ( l + 1.0 ), 0.0 );
- }
- vec3 LTC_EdgeVectorFormFactor( const in vec3 v1, const in vec3 v2 ) {
- float x = dot( v1, v2 );
- float y = abs( x );
- float a = 0.8543985 + ( 0.4965155 + 0.0145206 * y ) * y;
- float b = 3.4175940 + ( 4.1616724 + y ) * y;
- float v = a / b;
- float theta_sintheta = ( x > 0.0 ) ? v : 0.5 * inversesqrt( max( 1.0 - x * x, 1e-7 ) ) - v;
- return cross( v1, v2 ) * theta_sintheta;
- }
- vec3 LTC_Evaluate( const in vec3 N, const in vec3 V, const in vec3 P, const in mat3 mInv, const in vec3 rectCoords[ 4 ] ) {
- vec3 v1 = rectCoords[ 1 ] - rectCoords[ 0 ];
- vec3 v2 = rectCoords[ 3 ] - rectCoords[ 0 ];
- vec3 lightNormal = cross( v1, v2 );
- if( dot( lightNormal, P - rectCoords[ 0 ] ) < 0.0 ) return vec3( 0.0 );
- vec3 T1, T2;
- T1 = normalize( V - N * dot( V, N ) );
- T2 = - cross( N, T1 );
- mat3 mat = mInv * transposeMat3( mat3( T1, T2, N ) );
- vec3 coords[ 4 ];
- coords[ 0 ] = mat * ( rectCoords[ 0 ] - P );
- coords[ 1 ] = mat * ( rectCoords[ 1 ] - P );
- coords[ 2 ] = mat * ( rectCoords[ 2 ] - P );
- coords[ 3 ] = mat * ( rectCoords[ 3 ] - P );
- coords[ 0 ] = normalize( coords[ 0 ] );
- coords[ 1 ] = normalize( coords[ 1 ] );
- coords[ 2 ] = normalize( coords[ 2 ] );
- coords[ 3 ] = normalize( coords[ 3 ] );
- vec3 vectorFormFactor = vec3( 0.0 );
- vectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 0 ], coords[ 1 ] );
- vectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 1 ], coords[ 2 ] );
- vectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 2 ], coords[ 3 ] );
- vectorFormFactor += LTC_EdgeVectorFormFactor( coords[ 3 ], coords[ 0 ] );
- float result = LTC_ClippedSphereFormFactor( vectorFormFactor );
- return vec3( result );
- }
- vec3 BRDF_Specular_GGX_Environment( const in vec3 viewDir, const in vec3 normal, const in vec3 specularColor, const in float roughness ) {
- float dotNV = saturate( dot( normal, viewDir ) );
- vec2 brdf = integrateSpecularBRDF( dotNV, roughness );
- return specularColor * brdf.x + brdf.y;
- }
- void BRDF_Specular_Multiscattering_Environment( const in GeometricContext geometry, const in vec3 specularColor, const in float roughness, inout vec3 singleScatter, inout vec3 multiScatter ) {
- float dotNV = saturate( dot( geometry.normal, geometry.viewDir ) );
- vec3 F = F_Schlick_RoughnessDependent( specularColor, dotNV, roughness );
- vec2 brdf = integrateSpecularBRDF( dotNV, roughness );
- vec3 FssEss = F * brdf.x + brdf.y;
- float Ess = brdf.x + brdf.y;
- float Ems = 1.0 - Ess;
- vec3 Favg = specularColor + ( 1.0 - specularColor ) * 0.047619; vec3 Fms = FssEss * Favg / ( 1.0 - Ems * Favg );
- singleScatter += FssEss;
- multiScatter += Fms * Ems;
- }
- float G_BlinnPhong_Implicit( ) {
- return 0.25;
- }
- float D_BlinnPhong( const in float shininess, const in float dotNH ) {
- return RECIPROCAL_PI * ( shininess * 0.5 + 1.0 ) * pow( dotNH, shininess );
- }
- vec3 BRDF_Specular_BlinnPhong( const in IncidentLight incidentLight, const in GeometricContext geometry, const in vec3 specularColor, const in float shininess ) {
- vec3 halfDir = normalize( incidentLight.direction + geometry.viewDir );
- float dotNH = saturate( dot( geometry.normal, halfDir ) );
- float dotLH = saturate( dot( incidentLight.direction, halfDir ) );
- vec3 F = F_Schlick( specularColor, dotLH );
- float G = G_BlinnPhong_Implicit( );
- float D = D_BlinnPhong( shininess, dotNH );
- return F * ( G * D );
- }
- float GGXRoughnessToBlinnExponent( const in float ggxRoughness ) {
- return ( 2.0 / pow2( ggxRoughness + 0.0001 ) - 2.0 );
- }
- float BlinnExponentToGGXRoughness( const in float blinnExponent ) {
- return sqrt( 2.0 / ( blinnExponent + 2.0 ) );
- }
- #if defined( USE_SHEEN )
- float D_Charlie(float roughness, float NoH) {
- float invAlpha = 1.0 / roughness;
- float cos2h = NoH * NoH;
- float sin2h = max(1.0 - cos2h, 0.0078125); return (2.0 + invAlpha) * pow(sin2h, invAlpha * 0.5) / (2.0 * PI);
- }
- float V_Neubelt(float NoV, float NoL) {
- return saturate(1.0 / (4.0 * (NoL + NoV - NoL * NoV)));
- }
- vec3 BRDF_Specular_Sheen( const in float roughness, const in vec3 L, const in GeometricContext geometry, vec3 specularColor ) {
- vec3 N = geometry.normal;
- vec3 V = geometry.viewDir;
- vec3 H = normalize( V + L );
- float dotNH = saturate( dot( N, H ) );
- return specularColor * D_Charlie( roughness, dotNH ) * V_Neubelt( dot(N, V), dot(N, L) );
- }
- #endif`,bumpmap_pars_fragment:`#ifdef USE_BUMPMAP
- uniform sampler2D bumpMap;
- uniform float bumpScale;
- vec2 dHdxy_fwd() {
- vec2 dSTdx = dFdx( vUv );
- vec2 dSTdy = dFdy( vUv );
- float Hll = bumpScale * texture2D( bumpMap, vUv ).x;
- float dBx = bumpScale * texture2D( bumpMap, vUv + dSTdx ).x - Hll;
- float dBy = bumpScale * texture2D( bumpMap, vUv + dSTdy ).x - Hll;
- return vec2( dBx, dBy );
- }
- vec3 perturbNormalArb( vec3 surf_pos, vec3 surf_norm, vec2 dHdxy ) {
- vec3 vSigmaX = vec3( dFdx( surf_pos.x ), dFdx( surf_pos.y ), dFdx( surf_pos.z ) );
- vec3 vSigmaY = vec3( dFdy( surf_pos.x ), dFdy( surf_pos.y ), dFdy( surf_pos.z ) );
- vec3 vN = surf_norm;
- vec3 R1 = cross( vSigmaY, vN );
- vec3 R2 = cross( vN, vSigmaX );
- float fDet = dot( vSigmaX, R1 );
- fDet *= ( float( gl_FrontFacing ) * 2.0 - 1.0 );
- vec3 vGrad = sign( fDet ) * ( dHdxy.x * R1 + dHdxy.y * R2 );
- return normalize( abs( fDet ) * surf_norm - vGrad );
- }
- #endif`,clipping_planes_fragment:`#if NUM_CLIPPING_PLANES > 0
- vec4 plane;
- #pragma unroll_loop
- for ( int i = 0; i < UNION_CLIPPING_PLANES; i ++ ) {
- plane = clippingPlanes[ i ];
- if ( dot( vViewPosition, plane.xyz ) > plane.w ) discard;
- }
- #if UNION_CLIPPING_PLANES < NUM_CLIPPING_PLANES
- bool clipped = true;
- #pragma unroll_loop
- for ( int i = UNION_CLIPPING_PLANES; i < NUM_CLIPPING_PLANES; i ++ ) {
- plane = clippingPlanes[ i ];
- clipped = ( dot( vViewPosition, plane.xyz ) > plane.w ) && clipped;
- }
- if ( clipped ) discard;
- #endif
- #endif`,clipping_planes_pars_fragment:`#if NUM_CLIPPING_PLANES > 0
- #if ! defined( STANDARD ) && ! defined( PHONG ) && ! defined( MATCAP )
- varying vec3 vViewPosition;
- #endif
- uniform vec4 clippingPlanes[ NUM_CLIPPING_PLANES ];
- #endif`,clipping_planes_pars_vertex:`#if NUM_CLIPPING_PLANES > 0 && ! defined( STANDARD ) && ! defined( PHONG ) && ! defined( MATCAP )
- varying vec3 vViewPosition;
- #endif`,clipping_planes_vertex:`#if NUM_CLIPPING_PLANES > 0 && ! defined( STANDARD ) && ! defined( PHONG ) && ! defined( MATCAP )
- vViewPosition = - mvPosition.xyz;
- #endif`,color_fragment:`#ifdef USE_COLOR
- diffuseColor.rgb *= vColor;
- #endif`,color_pars_fragment:`#ifdef USE_COLOR
- varying vec3 vColor;
- #endif`,color_pars_vertex:`#ifdef USE_COLOR
- varying vec3 vColor;
- #endif`,color_vertex:`#ifdef USE_COLOR
- vColor.xyz = color.xyz;
- #endif`,common:`#define PI 3.14159265359
- #define PI2 6.28318530718
- #define PI_HALF 1.5707963267949
- #define RECIPROCAL_PI 0.31830988618
- #define RECIPROCAL_PI2 0.15915494
- #define LOG2 1.442695
- #define EPSILON 1e-6
- #ifndef saturate
- #define saturate(a) clamp( a, 0.0, 1.0 )
- #endif
- #define whiteComplement(a) ( 1.0 - saturate( a ) )
- float pow2( const in float x ) { return x*x; }
- float pow3( const in float x ) { return x*x*x; }
- float pow4( const in float x ) { float x2 = x*x; return x2*x2; }
- float average( const in vec3 color ) { return dot( color, vec3( 0.3333 ) ); }
- highp float rand( const in vec2 uv ) {
- const highp float a = 12.9898, b = 78.233, c = 43758.5453;
- highp float dt = dot( uv.xy, vec2( a,b ) ), sn = mod( dt, PI );
- return fract(sin(sn) * c);
- }
- #ifdef HIGH_PRECISION
- float precisionSafeLength( vec3 v ) { return length( v ); }
- #else
- float max3( vec3 v ) { return max( max( v.x, v.y ), v.z ); }
- float precisionSafeLength( vec3 v ) {
- float maxComponent = max3( abs( v ) );
- return length( v / maxComponent ) * maxComponent;
- }
- #endif
- struct IncidentLight {
- vec3 color;
- vec3 direction;
- bool visible;
- };
- struct ReflectedLight {
- vec3 directDiffuse;
- vec3 directSpecular;
- vec3 indirectDiffuse;
- vec3 indirectSpecular;
- };
- struct GeometricContext {
- vec3 position;
- vec3 normal;
- vec3 viewDir;
- #ifdef CLEARCOAT
- vec3 clearcoatNormal;
- #endif
- };
- vec3 transformDirection( in vec3 dir, in mat4 matrix ) {
- return normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );
- }
- vec3 inverseTransformDirection( in vec3 dir, in mat4 matrix ) {
- return normalize( ( vec4( dir, 0.0 ) * matrix ).xyz );
- }
- vec3 projectOnPlane(in vec3 point, in vec3 pointOnPlane, in vec3 planeNormal ) {
- float distance = dot( planeNormal, point - pointOnPlane );
- return - distance * planeNormal + point;
- }
- float sideOfPlane( in vec3 point, in vec3 pointOnPlane, in vec3 planeNormal ) {
- return sign( dot( point - pointOnPlane, planeNormal ) );
- }
- vec3 linePlaneIntersect( in vec3 pointOnLine, in vec3 lineDirection, in vec3 pointOnPlane, in vec3 planeNormal ) {
- return lineDirection * ( dot( planeNormal, pointOnPlane - pointOnLine ) / dot( planeNormal, lineDirection ) ) + pointOnLine;
- }
- mat3 transposeMat3( const in mat3 m ) {
- mat3 tmp;
- tmp[ 0 ] = vec3( m[ 0 ].x, m[ 1 ].x, m[ 2 ].x );
- tmp[ 1 ] = vec3( m[ 0 ].y, m[ 1 ].y, m[ 2 ].y );
- tmp[ 2 ] = vec3( m[ 0 ].z, m[ 1 ].z, m[ 2 ].z );
- return tmp;
- }
- float linearToRelativeLuminance( const in vec3 color ) {
- vec3 weights = vec3( 0.2126, 0.7152, 0.0722 );
- return dot( weights, color.rgb );
- }
- bool isPerspectiveMatrix( mat4 m ) {
- return m[ 2 ][ 3 ] == - 1.0;
- }`,cube_uv_reflection_fragment:`#ifdef ENVMAP_TYPE_CUBE_UV
- #define cubeUV_maxMipLevel 8.0
- #define cubeUV_minMipLevel 4.0
- #define cubeUV_maxTileSize 256.0
- #define cubeUV_minTileSize 16.0
- float getFace(vec3 direction) {
- vec3 absDirection = abs(direction);
- float face = -1.0;
- if (absDirection.x > absDirection.z) {
- if (absDirection.x > absDirection.y)
- face = direction.x > 0.0 ? 0.0 : 3.0;
- else
- face = direction.y > 0.0 ? 1.0 : 4.0;
- } else {
- if (absDirection.z > absDirection.y)
- face = direction.z > 0.0 ? 2.0 : 5.0;
- else
- face = direction.y > 0.0 ? 1.0 : 4.0;
- }
- return face;
- }
- vec2 getUV(vec3 direction, float face) {
- vec2 uv;
- if (face == 0.0) {
- uv = vec2(-direction.z, direction.y) / abs(direction.x);
- } else if (face == 1.0) {
- uv = vec2(direction.x, -direction.z) / abs(direction.y);
- } else if (face == 2.0) {
- uv = direction.xy / abs(direction.z);
- } else if (face == 3.0) {
- uv = vec2(direction.z, direction.y) / abs(direction.x);
- } else if (face == 4.0) {
- uv = direction.xz / abs(direction.y);
- } else {
- uv = vec2(-direction.x, direction.y) / abs(direction.z);
- }
- return 0.5 * (uv + 1.0);
- }
- vec3 bilinearCubeUV(sampler2D envMap, vec3 direction, float mipInt) {
- float face = getFace(direction);
- float filterInt = max(cubeUV_minMipLevel - mipInt, 0.0);
- mipInt = max(mipInt, cubeUV_minMipLevel);
- float faceSize = exp2(mipInt);
- float texelSize = 1.0 / (3.0 * cubeUV_maxTileSize);
- vec2 uv = getUV(direction, face) * (faceSize - 1.0);
- vec2 f = fract(uv);
- uv += 0.5 - f;
- if (face > 2.0) {
- uv.y += faceSize;
- face -= 3.0;
- }
- uv.x += face * faceSize;
- if(mipInt < cubeUV_maxMipLevel){
- uv.y += 2.0 * cubeUV_maxTileSize;
- }
- uv.y += filterInt * 2.0 * cubeUV_minTileSize;
- uv.x += 3.0 * max(0.0, cubeUV_maxTileSize - 2.0 * faceSize);
- uv *= texelSize;
- vec3 tl = envMapTexelToLinear(texture2D(envMap, uv)).rgb;
- uv.x += texelSize;
- vec3 tr = envMapTexelToLinear(texture2D(envMap, uv)).rgb;
- uv.y += texelSize;
- vec3 br = envMapTexelToLinear(texture2D(envMap, uv)).rgb;
- uv.x -= texelSize;
- vec3 bl = envMapTexelToLinear(texture2D(envMap, uv)).rgb;
- vec3 tm = mix(tl, tr, f.x);
- vec3 bm = mix(bl, br, f.x);
- return mix(tm, bm, f.y);
- }
- #define r0 1.0
- #define v0 0.339
- #define m0 -2.0
- #define r1 0.8
- #define v1 0.276
- #define m1 -1.0
- #define r4 0.4
- #define v4 0.046
- #define m4 2.0
- #define r5 0.305
- #define v5 0.016
- #define m5 3.0
- #define r6 0.21
- #define v6 0.0038
- #define m6 4.0
- float roughnessToMip(float roughness) {
- float mip = 0.0;
- if (roughness >= r1) {
- mip = (r0 - roughness) * (m1 - m0) / (r0 - r1) + m0;
- } else if (roughness >= r4) {
- mip = (r1 - roughness) * (m4 - m1) / (r1 - r4) + m1;
- } else if (roughness >= r5) {
- mip = (r4 - roughness) * (m5 - m4) / (r4 - r5) + m4;
- } else if (roughness >= r6) {
- mip = (r5 - roughness) * (m6 - m5) / (r5 - r6) + m5;
- } else {
- mip = -2.0 * log2(1.16 * roughness); }
- return mip;
- }
- vec4 textureCubeUV(sampler2D envMap, vec3 sampleDir, float roughness) {
- float mip = clamp(roughnessToMip(roughness), m0, cubeUV_maxMipLevel);
- float mipF = fract(mip);
- float mipInt = floor(mip);
- vec3 color0 = bilinearCubeUV(envMap, sampleDir, mipInt);
- if (mipF == 0.0) {
- return vec4(color0, 1.0);
- } else {
- vec3 color1 = bilinearCubeUV(envMap, sampleDir, mipInt + 1.0);
- return vec4(mix(color0, color1, mipF), 1.0);
- }
- }
- #endif`,defaultnormal_vertex:`vec3 transformedNormal = objectNormal;
- #ifdef USE_INSTANCING
- transformedNormal = mat3( instanceMatrix ) * transformedNormal;
- #endif
- transformedNormal = normalMatrix * transformedNormal;
- #ifdef FLIP_SIDED
- transformedNormal = - transformedNormal;
- #endif
- #ifdef USE_TANGENT
- vec3 transformedTangent = ( modelViewMatrix * vec4( objectTangent, 0.0 ) ).xyz;
- #ifdef FLIP_SIDED
- transformedTangent = - transformedTangent;
- #endif
- #endif`,displacementmap_pars_vertex:`#ifdef USE_DISPLACEMENTMAP
- uniform sampler2D displacementMap;
- uniform float displacementScale;
- uniform float displacementBias;
- #endif`,displacementmap_vertex:`#ifdef USE_DISPLACEMENTMAP
- transformed += normalize( objectNormal ) * ( texture2D( displacementMap, vUv ).x * displacementScale + displacementBias );
- #endif`,emissivemap_fragment:`#ifdef USE_EMISSIVEMAP
- vec4 emissiveColor = texture2D( emissiveMap, vUv );
- emissiveColor.rgb = emissiveMapTexelToLinear( emissiveColor ).rgb;
- totalEmissiveRadiance *= emissiveColor.rgb;
- #endif`,emissivemap_pars_fragment:`#ifdef USE_EMISSIVEMAP
- uniform sampler2D emissiveMap;
- #endif`,encodings_fragment:"gl_FragColor = linearToOutputTexel( gl_FragColor );",encodings_pars_fragment:`
- vec4 LinearToLinear( in vec4 value ) {
- return value;
- }
- vec4 GammaToLinear( in vec4 value, in float gammaFactor ) {
- return vec4( pow( value.rgb, vec3( gammaFactor ) ), value.a );
- }
- vec4 LinearToGamma( in vec4 value, in float gammaFactor ) {
- return vec4( pow( value.rgb, vec3( 1.0 / gammaFactor ) ), value.a );
- }
- vec4 sRGBToLinear( in vec4 value ) {
- return vec4( mix( pow( value.rgb * 0.9478672986 + vec3( 0.0521327014 ), vec3( 2.4 ) ), value.rgb * 0.0773993808, vec3( lessThanEqual( value.rgb, vec3( 0.04045 ) ) ) ), value.a );
- }
- vec4 LinearTosRGB( in vec4 value ) {
- return vec4( mix( pow( value.rgb, vec3( 0.41666 ) ) * 1.055 - vec3( 0.055 ), value.rgb * 12.92, vec3( lessThanEqual( value.rgb, vec3( 0.0031308 ) ) ) ), value.a );
- }
- vec4 RGBEToLinear( in vec4 value ) {
- return vec4( value.rgb * exp2( value.a * 255.0 - 128.0 ), 1.0 );
- }
- vec4 LinearToRGBE( in vec4 value ) {
- float maxComponent = max( max( value.r, value.g ), value.b );
- float fExp = clamp( ceil( log2( maxComponent ) ), -128.0, 127.0 );
- return vec4( value.rgb / exp2( fExp ), ( fExp + 128.0 ) / 255.0 );
- }
- vec4 RGBMToLinear( in vec4 value, in float maxRange ) {
- return vec4( value.rgb * value.a * maxRange, 1.0 );
- }
- vec4 LinearToRGBM( in vec4 value, in float maxRange ) {
- float maxRGB = max( value.r, max( value.g, value.b ) );
- float M = clamp( maxRGB / maxRange, 0.0, 1.0 );
- M = ceil( M * 255.0 ) / 255.0;
- return vec4( value.rgb / ( M * maxRange ), M );
- }
- vec4 RGBDToLinear( in vec4 value, in float maxRange ) {
- return vec4( value.rgb * ( ( maxRange / 255.0 ) / value.a ), 1.0 );
- }
- vec4 LinearToRGBD( in vec4 value, in float maxRange ) {
- float maxRGB = max( value.r, max( value.g, value.b ) );
- float D = max( maxRange / maxRGB, 1.0 );
- D = clamp( floor( D ) / 255.0, 0.0, 1.0 );
- return vec4( value.rgb * ( D * ( 255.0 / maxRange ) ), D );
- }
- const mat3 cLogLuvM = mat3( 0.2209, 0.3390, 0.4184, 0.1138, 0.6780, 0.7319, 0.0102, 0.1130, 0.2969 );
- vec4 LinearToLogLuv( in vec4 value ) {
- vec3 Xp_Y_XYZp = cLogLuvM * value.rgb;
- Xp_Y_XYZp = max( Xp_Y_XYZp, vec3( 1e-6, 1e-6, 1e-6 ) );
- vec4 vResult;
- vResult.xy = Xp_Y_XYZp.xy / Xp_Y_XYZp.z;
- float Le = 2.0 * log2(Xp_Y_XYZp.y) + 127.0;
- vResult.w = fract( Le );
- vResult.z = ( Le - ( floor( vResult.w * 255.0 ) ) / 255.0 ) / 255.0;
- return vResult;
- }
- const mat3 cLogLuvInverseM = mat3( 6.0014, -2.7008, -1.7996, -1.3320, 3.1029, -5.7721, 0.3008, -1.0882, 5.6268 );
- vec4 LogLuvToLinear( in vec4 value ) {
- float Le = value.z * 255.0 + value.w;
- vec3 Xp_Y_XYZp;
- Xp_Y_XYZp.y = exp2( ( Le - 127.0 ) / 2.0 );
- Xp_Y_XYZp.z = Xp_Y_XYZp.y / value.y;
- Xp_Y_XYZp.x = value.x * Xp_Y_XYZp.z;
- vec3 vRGB = cLogLuvInverseM * Xp_Y_XYZp.rgb;
- return vec4( max( vRGB, 0.0 ), 1.0 );
- }`,envmap_fragment:`#ifdef USE_ENVMAP
- #ifdef ENV_WORLDPOS
- vec3 cameraToFrag;
-
- if ( isOrthographic ) {
- cameraToFrag = normalize( vec3( - viewMatrix[ 0 ][ 2 ], - viewMatrix[ 1 ][ 2 ], - viewMatrix[ 2 ][ 2 ] ) );
- } else {
- cameraToFrag = normalize( vWorldPosition - cameraPosition );
- }
- vec3 worldNormal = inverseTransformDirection( normal, viewMatrix );
- #ifdef ENVMAP_MODE_REFLECTION
- vec3 reflectVec = reflect( cameraToFrag, worldNormal );
- #else
- vec3 reflectVec = refract( cameraToFrag, worldNormal, refractionRatio );
- #endif
- #else
- vec3 reflectVec = vReflect;
- #endif
- #ifdef ENVMAP_TYPE_CUBE
- vec4 envColor = textureCube( envMap, vec3( flipEnvMap * reflectVec.x, reflectVec.yz ) );
- #elif defined( ENVMAP_TYPE_CUBE_UV )
- vec4 envColor = textureCubeUV( envMap, reflectVec, 0.0 );
- #elif defined( ENVMAP_TYPE_EQUIREC )
- vec2 sampleUV;
- reflectVec = normalize( reflectVec );
- sampleUV.y = asin( clamp( reflectVec.y, - 1.0, 1.0 ) ) * RECIPROCAL_PI + 0.5;
- sampleUV.x = atan( reflectVec.z, reflectVec.x ) * RECIPROCAL_PI2 + 0.5;
- vec4 envColor = texture2D( envMap, sampleUV );
- #elif defined( ENVMAP_TYPE_SPHERE )
- reflectVec = normalize( reflectVec );
- vec3 reflectView = normalize( ( viewMatrix * vec4( reflectVec, 0.0 ) ).xyz + vec3( 0.0, 0.0, 1.0 ) );
- vec4 envColor = texture2D( envMap, reflectView.xy * 0.5 + 0.5 );
- #else
- vec4 envColor = vec4( 0.0 );
- #endif
- #ifndef ENVMAP_TYPE_CUBE_UV
- envColor = envMapTexelToLinear( envColor );
- #endif
- #ifdef ENVMAP_BLENDING_MULTIPLY
- outgoingLight = mix( outgoingLight, outgoingLight * envColor.xyz, specularStrength * reflectivity );
- #elif defined( ENVMAP_BLENDING_MIX )
- outgoingLight = mix( outgoingLight, envColor.xyz, specularStrength * reflectivity );
- #elif defined( ENVMAP_BLENDING_ADD )
- outgoingLight += envColor.xyz * specularStrength * reflectivity;
- #endif
- #endif`,envmap_common_pars_fragment:`#ifdef USE_ENVMAP
- uniform float envMapIntensity;
- uniform float flipEnvMap;
- uniform int maxMipLevel;
- #ifdef ENVMAP_TYPE_CUBE
- uniform samplerCube envMap;
- #else
- uniform sampler2D envMap;
- #endif
-
- #endif`,envmap_pars_fragment:`#ifdef USE_ENVMAP
- uniform float reflectivity;
- #if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) || defined( PHONG )
- #define ENV_WORLDPOS
- #endif
- #ifdef ENV_WORLDPOS
- varying vec3 vWorldPosition;
- uniform float refractionRatio;
- #else
- varying vec3 vReflect;
- #endif
- #endif`,envmap_pars_vertex:`#ifdef USE_ENVMAP
- #if defined( USE_BUMPMAP ) || defined( USE_NORMALMAP ) ||defined( PHONG )
- #define ENV_WORLDPOS
- #endif
- #ifdef ENV_WORLDPOS
-
- varying vec3 vWorldPosition;
- #else
- varying vec3 vReflect;
- uniform float refractionRatio;
- #endif
- #endif`,envmap_physical_pars_fragment:`#if defined( USE_ENVMAP )
- #ifdef ENVMAP_MODE_REFRACTION
- uniform float refractionRatio;
- #endif
- vec3 getLightProbeIndirectIrradiance( const in GeometricContext geometry, const in int maxMIPLevel ) {
- vec3 worldNormal = inverseTransformDirection( geometry.normal, viewMatrix );
- #ifdef ENVMAP_TYPE_CUBE
- vec3 queryVec = vec3( flipEnvMap * worldNormal.x, worldNormal.yz );
- #ifdef TEXTURE_LOD_EXT
- vec4 envMapColor = textureCubeLodEXT( envMap, queryVec, float( maxMIPLevel ) );
- #else
- vec4 envMapColor = textureCube( envMap, queryVec, float( maxMIPLevel ) );
- #endif
- envMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;
- #elif defined( ENVMAP_TYPE_CUBE_UV )
- vec4 envMapColor = textureCubeUV( envMap, worldNormal, 1.0 );
- #else
- vec4 envMapColor = vec4( 0.0 );
- #endif
- return PI * envMapColor.rgb * envMapIntensity;
- }
- float getSpecularMIPLevel( const in float roughness, const in int maxMIPLevel ) {
- float maxMIPLevelScalar = float( maxMIPLevel );
- float sigma = PI * roughness * roughness / ( 1.0 + roughness );
- float desiredMIPLevel = maxMIPLevelScalar + log2( sigma );
- return clamp( desiredMIPLevel, 0.0, maxMIPLevelScalar );
- }
- vec3 getLightProbeIndirectRadiance( const in vec3 viewDir, const in vec3 normal, const in float roughness, const in int maxMIPLevel ) {
- #ifdef ENVMAP_MODE_REFLECTION
- vec3 reflectVec = reflect( -viewDir, normal );
- reflectVec = normalize( mix( reflectVec, normal, roughness * roughness) );
- #else
- vec3 reflectVec = refract( -viewDir, normal, refractionRatio );
- #endif
- reflectVec = inverseTransformDirection( reflectVec, viewMatrix );
- float specularMIPLevel = getSpecularMIPLevel( roughness, maxMIPLevel );
- #ifdef ENVMAP_TYPE_CUBE
- vec3 queryReflectVec = vec3( flipEnvMap * reflectVec.x, reflectVec.yz );
- #ifdef TEXTURE_LOD_EXT
- vec4 envMapColor = textureCubeLodEXT( envMap, queryReflectVec, specularMIPLevel );
- #else
- vec4 envMapColor = textureCube( envMap, queryReflectVec, specularMIPLevel );
- #endif
- envMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;
- #elif defined( ENVMAP_TYPE_CUBE_UV )
- vec4 envMapColor = textureCubeUV( envMap, reflectVec, roughness );
- #elif defined( ENVMAP_TYPE_EQUIREC )
- vec2 sampleUV;
- sampleUV.y = asin( clamp( reflectVec.y, - 1.0, 1.0 ) ) * RECIPROCAL_PI + 0.5;
- sampleUV.x = atan( reflectVec.z, reflectVec.x ) * RECIPROCAL_PI2 + 0.5;
- #ifdef TEXTURE_LOD_EXT
- vec4 envMapColor = texture2DLodEXT( envMap, sampleUV, specularMIPLevel );
- #else
- vec4 envMapColor = texture2D( envMap, sampleUV, specularMIPLevel );
- #endif
- envMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;
- #elif defined( ENVMAP_TYPE_SPHERE )
- vec3 reflectView = normalize( ( viewMatrix * vec4( reflectVec, 0.0 ) ).xyz + vec3( 0.0,0.0,1.0 ) );
- #ifdef TEXTURE_LOD_EXT
- vec4 envMapColor = texture2DLodEXT( envMap, reflectView.xy * 0.5 + 0.5, specularMIPLevel );
- #else
- vec4 envMapColor = texture2D( envMap, reflectView.xy * 0.5 + 0.5, specularMIPLevel );
- #endif
- envMapColor.rgb = envMapTexelToLinear( envMapColor ).rgb;
- #endif
- return envMapColor.rgb * envMapIntensity;
- }
- #endif`,envmap_vertex:`#ifdef USE_ENVMAP
- #ifdef ENV_WORLDPOS
- vWorldPosition = worldPosition.xyz;
- #else
- vec3 cameraToVertex;
- if ( isOrthographic ) {
- cameraToVertex = normalize( vec3( - viewMatrix[ 0 ][ 2 ], - viewMatrix[ 1 ][ 2 ], - viewMatrix[ 2 ][ 2 ] ) );
- } else {
- cameraToVertex = normalize( worldPosition.xyz - cameraPosition );
- }
- vec3 worldNormal = inverseTransformDirection( transformedNormal, viewMatrix );
- #ifdef ENVMAP_MODE_REFLECTION
- vReflect = reflect( cameraToVertex, worldNormal );
- #else
- vReflect = refract( cameraToVertex, worldNormal, refractionRatio );
- #endif
- #endif
- #endif`,fog_vertex:`#ifdef USE_FOG
- fogDepth = -mvPosition.z;
- #endif`,fog_pars_vertex:`#ifdef USE_FOG
- varying float fogDepth;
- #endif`,fog_fragment:`#ifdef USE_FOG
- #ifdef FOG_EXP2
- float fogFactor = 1.0 - exp( - fogDensity * fogDensity * fogDepth * fogDepth );
- #else
- float fogFactor = smoothstep( fogNear, fogFar, fogDepth );
- #endif
- gl_FragColor.rgb = mix( gl_FragColor.rgb, fogColor, fogFactor );
- #endif`,fog_pars_fragment:`#ifdef USE_FOG
- uniform vec3 fogColor;
- varying float fogDepth;
- #ifdef FOG_EXP2
- uniform float fogDensity;
- #else
- uniform float fogNear;
- uniform float fogFar;
- #endif
- #endif`,gradientmap_pars_fragment:`#ifdef USE_GRADIENTMAP
- uniform sampler2D gradientMap;
- #endif
- vec3 getGradientIrradiance( vec3 normal, vec3 lightDirection ) {
- float dotNL = dot( normal, lightDirection );
- vec2 coord = vec2( dotNL * 0.5 + 0.5, 0.0 );
- #ifdef USE_GRADIENTMAP
- return texture2D( gradientMap, coord ).rgb;
- #else
- return ( coord.x < 0.7 ) ? vec3( 0.7 ) : vec3( 1.0 );
- #endif
- }`,lightmap_fragment:`#ifdef USE_LIGHTMAP
- vec4 lightMapTexel= texture2D( lightMap, vUv2 );
- reflectedLight.indirectDiffuse += PI * lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;
- #endif`,lightmap_pars_fragment:`#ifdef USE_LIGHTMAP
- uniform sampler2D lightMap;
- uniform float lightMapIntensity;
- #endif`,lights_lambert_vertex:`vec3 diffuse = vec3( 1.0 );
- GeometricContext geometry;
- geometry.position = mvPosition.xyz;
- geometry.normal = normalize( transformedNormal );
- geometry.viewDir = ( isOrthographic ) ? vec3( 0, 0, 1 ) : normalize( -mvPosition.xyz );
- GeometricContext backGeometry;
- backGeometry.position = geometry.position;
- backGeometry.normal = -geometry.normal;
- backGeometry.viewDir = geometry.viewDir;
- vLightFront = vec3( 0.0 );
- vIndirectFront = vec3( 0.0 );
- #ifdef DOUBLE_SIDED
- vLightBack = vec3( 0.0 );
- vIndirectBack = vec3( 0.0 );
- #endif
- IncidentLight directLight;
- float dotNL;
- vec3 directLightColor_Diffuse;
- #if NUM_POINT_LIGHTS > 0
- #pragma unroll_loop
- for ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {
- getPointDirectLightIrradiance( pointLights[ i ], geometry, directLight );
- dotNL = dot( geometry.normal, directLight.direction );
- directLightColor_Diffuse = PI * directLight.color;
- vLightFront += saturate( dotNL ) * directLightColor_Diffuse;
- #ifdef DOUBLE_SIDED
- vLightBack += saturate( -dotNL ) * directLightColor_Diffuse;
- #endif
- }
- #endif
- #if NUM_SPOT_LIGHTS > 0
- #pragma unroll_loop
- for ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {
- getSpotDirectLightIrradiance( spotLights[ i ], geometry, directLight );
- dotNL = dot( geometry.normal, directLight.direction );
- directLightColor_Diffuse = PI * directLight.color;
- vLightFront += saturate( dotNL ) * directLightColor_Diffuse;
- #ifdef DOUBLE_SIDED
- vLightBack += saturate( -dotNL ) * directLightColor_Diffuse;
- #endif
- }
- #endif
- #if NUM_DIR_LIGHTS > 0
- #pragma unroll_loop
- for ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {
- getDirectionalDirectLightIrradiance( directionalLights[ i ], geometry, directLight );
- dotNL = dot( geometry.normal, directLight.direction );
- directLightColor_Diffuse = PI * directLight.color;
- vLightFront += saturate( dotNL ) * directLightColor_Diffuse;
- #ifdef DOUBLE_SIDED
- vLightBack += saturate( -dotNL ) * directLightColor_Diffuse;
- #endif
- }
- #endif
- #if NUM_HEMI_LIGHTS > 0
- #pragma unroll_loop
- for ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {
- vIndirectFront += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry );
- #ifdef DOUBLE_SIDED
- vIndirectBack += getHemisphereLightIrradiance( hemisphereLights[ i ], backGeometry );
- #endif
- }
- #endif`,lights_pars_begin:`uniform bool receiveShadow;
- uniform vec3 ambientLightColor;
- uniform vec3 lightProbe[ 9 ];
- vec3 shGetIrradianceAt( in vec3 normal, in vec3 shCoefficients[ 9 ] ) {
- float x = normal.x, y = normal.y, z = normal.z;
- vec3 result = shCoefficients[ 0 ] * 0.886227;
- result += shCoefficients[ 1 ] * 2.0 * 0.511664 * y;
- result += shCoefficients[ 2 ] * 2.0 * 0.511664 * z;
- result += shCoefficients[ 3 ] * 2.0 * 0.511664 * x;
- result += shCoefficients[ 4 ] * 2.0 * 0.429043 * x * y;
- result += shCoefficients[ 5 ] * 2.0 * 0.429043 * y * z;
- result += shCoefficients[ 6 ] * ( 0.743125 * z * z - 0.247708 );
- result += shCoefficients[ 7 ] * 2.0 * 0.429043 * x * z;
- result += shCoefficients[ 8 ] * 0.429043 * ( x * x - y * y );
- return result;
- }
- vec3 getLightProbeIrradiance( const in vec3 lightProbe[ 9 ], const in GeometricContext geometry ) {
- vec3 worldNormal = inverseTransformDirection( geometry.normal, viewMatrix );
- vec3 irradiance = shGetIrradianceAt( worldNormal, lightProbe );
- return irradiance;
- }
- vec3 getAmbientLightIrradiance( const in vec3 ambientLightColor ) {
- vec3 irradiance = ambientLightColor;
- #ifndef PHYSICALLY_CORRECT_LIGHTS
- irradiance *= PI;
- #endif
- return irradiance;
- }
- #if NUM_DIR_LIGHTS > 0
- struct DirectionalLight {
- vec3 direction;
- vec3 color;
- int shadow;
- float shadowBias;
- float shadowRadius;
- vec2 shadowMapSize;
- };
- uniform DirectionalLight directionalLights[ NUM_DIR_LIGHTS ];
- void getDirectionalDirectLightIrradiance( const in DirectionalLight directionalLight, const in GeometricContext geometry, out IncidentLight directLight ) {
- directLight.color = directionalLight.color;
- directLight.direction = directionalLight.direction;
- directLight.visible = true;
- }
- #endif
- #if NUM_POINT_LIGHTS > 0
- struct PointLight {
- vec3 position;
- vec3 color;
- float distance;
- float decay;
- int shadow;
- float shadowBias;
- float shadowRadius;
- vec2 shadowMapSize;
- float shadowCameraNear;
- float shadowCameraFar;
- };
- uniform PointLight pointLights[ NUM_POINT_LIGHTS ];
- void getPointDirectLightIrradiance( const in PointLight pointLight, const in GeometricContext geometry, out IncidentLight directLight ) {
- vec3 lVector = pointLight.position - geometry.position;
- directLight.direction = normalize( lVector );
- float lightDistance = length( lVector );
- directLight.color = pointLight.color;
- directLight.color *= punctualLightIntensityToIrradianceFactor( lightDistance, pointLight.distance, pointLight.decay );
- directLight.visible = ( directLight.color != vec3( 0.0 ) );
- }
- #endif
- #if NUM_SPOT_LIGHTS > 0
- struct SpotLight {
- vec3 position;
- vec3 direction;
- vec3 color;
- float distance;
- float decay;
- float coneCos;
- float penumbraCos;
- int shadow;
- float shadowBias;
- float shadowRadius;
- vec2 shadowMapSize;
- };
- uniform SpotLight spotLights[ NUM_SPOT_LIGHTS ];
- void getSpotDirectLightIrradiance( const in SpotLight spotLight, const in GeometricContext geometry, out IncidentLight directLight ) {
- vec3 lVector = spotLight.position - geometry.position;
- directLight.direction = normalize( lVector );
- float lightDistance = length( lVector );
- float angleCos = dot( directLight.direction, spotLight.direction );
- if ( angleCos > spotLight.coneCos ) {
- float spotEffect = smoothstep( spotLight.coneCos, spotLight.penumbraCos, angleCos );
- directLight.color = spotLight.color;
- directLight.color *= spotEffect * punctualLightIntensityToIrradianceFactor( lightDistance, spotLight.distance, spotLight.decay );
- directLight.visible = true;
- } else {
- directLight.color = vec3( 0.0 );
- directLight.visible = false;
- }
- }
- #endif
- #if NUM_RECT_AREA_LIGHTS > 0
- struct RectAreaLight {
- vec3 color;
- vec3 position;
- vec3 halfWidth;
- vec3 halfHeight;
- };
- uniform sampler2D ltc_1; uniform sampler2D ltc_2;
- uniform RectAreaLight rectAreaLights[ NUM_RECT_AREA_LIGHTS ];
- #endif
- #if NUM_HEMI_LIGHTS > 0
- struct HemisphereLight {
- vec3 direction;
- vec3 skyColor;
- vec3 groundColor;
- };
- uniform HemisphereLight hemisphereLights[ NUM_HEMI_LIGHTS ];
- vec3 getHemisphereLightIrradiance( const in HemisphereLight hemiLight, const in GeometricContext geometry ) {
- float dotNL = dot( geometry.normal, hemiLight.direction );
- float hemiDiffuseWeight = 0.5 * dotNL + 0.5;
- vec3 irradiance = mix( hemiLight.groundColor, hemiLight.skyColor, hemiDiffuseWeight );
- #ifndef PHYSICALLY_CORRECT_LIGHTS
- irradiance *= PI;
- #endif
- return irradiance;
- }
- #endif`,lights_toon_fragment:`ToonMaterial material;
- material.diffuseColor = diffuseColor.rgb;
- material.specularColor = specular;
- material.specularShininess = shininess;
- material.specularStrength = specularStrength;`,lights_toon_pars_fragment:`varying vec3 vViewPosition;
- #ifndef FLAT_SHADED
- varying vec3 vNormal;
- #endif
- struct ToonMaterial {
- vec3 diffuseColor;
- vec3 specularColor;
- float specularShininess;
- float specularStrength;
- };
- void RE_Direct_Toon( const in IncidentLight directLight, const in GeometricContext geometry, const in ToonMaterial material, inout ReflectedLight reflectedLight ) {
- vec3 irradiance = getGradientIrradiance( geometry.normal, directLight.direction ) * directLight.color;
- #ifndef PHYSICALLY_CORRECT_LIGHTS
- irradiance *= PI;
- #endif
- reflectedLight.directDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );
- reflectedLight.directSpecular += irradiance * BRDF_Specular_BlinnPhong( directLight, geometry, material.specularColor, material.specularShininess ) * material.specularStrength;
- }
- void RE_IndirectDiffuse_Toon( const in vec3 irradiance, const in GeometricContext geometry, const in ToonMaterial material, inout ReflectedLight reflectedLight ) {
- reflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );
- }
- #define RE_Direct RE_Direct_Toon
- #define RE_IndirectDiffuse RE_IndirectDiffuse_Toon
- #define Material_LightProbeLOD( material ) (0)`,lights_phong_fragment:`BlinnPhongMaterial material;
- material.diffuseColor = diffuseColor.rgb;
- material.specularColor = specular;
- material.specularShininess = shininess;
- material.specularStrength = specularStrength;`,lights_phong_pars_fragment:`varying vec3 vViewPosition;
- #ifndef FLAT_SHADED
- varying vec3 vNormal;
- #endif
- struct BlinnPhongMaterial {
- vec3 diffuseColor;
- vec3 specularColor;
- float specularShininess;
- float specularStrength;
- };
- void RE_Direct_BlinnPhong( const in IncidentLight directLight, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {
- float dotNL = saturate( dot( geometry.normal, directLight.direction ) );
- vec3 irradiance = dotNL * directLight.color;
- #ifndef PHYSICALLY_CORRECT_LIGHTS
- irradiance *= PI;
- #endif
- reflectedLight.directDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );
- reflectedLight.directSpecular += irradiance * BRDF_Specular_BlinnPhong( directLight, geometry, material.specularColor, material.specularShininess ) * material.specularStrength;
- }
- void RE_IndirectDiffuse_BlinnPhong( const in vec3 irradiance, const in GeometricContext geometry, const in BlinnPhongMaterial material, inout ReflectedLight reflectedLight ) {
- reflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );
- }
- #define RE_Direct RE_Direct_BlinnPhong
- #define RE_IndirectDiffuse RE_IndirectDiffuse_BlinnPhong
- #define Material_LightProbeLOD( material ) (0)`,lights_physical_fragment:`PhysicalMaterial material;
- material.diffuseColor = diffuseColor.rgb * ( 1.0 - metalnessFactor );
- vec3 dxy = max( abs( dFdx( geometryNormal ) ), abs( dFdy( geometryNormal ) ) );
- float geometryRoughness = max( max( dxy.x, dxy.y ), dxy.z );
- material.specularRoughness = max( roughnessFactor, 0.0525 );material.specularRoughness += geometryRoughness;
- material.specularRoughness = min( material.specularRoughness, 1.0 );
- #ifdef REFLECTIVITY
- material.specularColor = mix( vec3( MAXIMUM_SPECULAR_COEFFICIENT * pow2( reflectivity ) ), diffuseColor.rgb, metalnessFactor );
- #else
- material.specularColor = mix( vec3( DEFAULT_SPECULAR_COEFFICIENT ), diffuseColor.rgb, metalnessFactor );
- #endif
- #ifdef CLEARCOAT
- material.clearcoat = saturate( clearcoat ); material.clearcoatRoughness = max( clearcoatRoughness, 0.0525 );
- material.clearcoatRoughness += geometryRoughness;
- material.clearcoatRoughness = min( material.clearcoatRoughness, 1.0 );
- #endif
- #ifdef USE_SHEEN
- material.sheenColor = sheen;
- #endif`,lights_physical_pars_fragment:`struct PhysicalMaterial {
- vec3 diffuseColor;
- float specularRoughness;
- vec3 specularColor;
- #ifdef CLEARCOAT
- float clearcoat;
- float clearcoatRoughness;
- #endif
- #ifdef USE_SHEEN
- vec3 sheenColor;
- #endif
- };
- #define MAXIMUM_SPECULAR_COEFFICIENT 0.16
- #define DEFAULT_SPECULAR_COEFFICIENT 0.04
- float clearcoatDHRApprox( const in float roughness, const in float dotNL ) {
- return DEFAULT_SPECULAR_COEFFICIENT + ( 1.0 - DEFAULT_SPECULAR_COEFFICIENT ) * ( pow( 1.0 - dotNL, 5.0 ) * pow( 1.0 - roughness, 2.0 ) );
- }
- #if NUM_RECT_AREA_LIGHTS > 0
- void RE_Direct_RectArea_Physical( const in RectAreaLight rectAreaLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {
- vec3 normal = geometry.normal;
- vec3 viewDir = geometry.viewDir;
- vec3 position = geometry.position;
- vec3 lightPos = rectAreaLight.position;
- vec3 halfWidth = rectAreaLight.halfWidth;
- vec3 halfHeight = rectAreaLight.halfHeight;
- vec3 lightColor = rectAreaLight.color;
- float roughness = material.specularRoughness;
- vec3 rectCoords[ 4 ];
- rectCoords[ 0 ] = lightPos + halfWidth - halfHeight; rectCoords[ 1 ] = lightPos - halfWidth - halfHeight;
- rectCoords[ 2 ] = lightPos - halfWidth + halfHeight;
- rectCoords[ 3 ] = lightPos + halfWidth + halfHeight;
- vec2 uv = LTC_Uv( normal, viewDir, roughness );
- vec4 t1 = texture2D( ltc_1, uv );
- vec4 t2 = texture2D( ltc_2, uv );
- mat3 mInv = mat3(
- vec3( t1.x, 0, t1.y ),
- vec3( 0, 1, 0 ),
- vec3( t1.z, 0, t1.w )
- );
- vec3 fresnel = ( material.specularColor * t2.x + ( vec3( 1.0 ) - material.specularColor ) * t2.y );
- reflectedLight.directSpecular += lightColor * fresnel * LTC_Evaluate( normal, viewDir, position, mInv, rectCoords );
- reflectedLight.directDiffuse += lightColor * material.diffuseColor * LTC_Evaluate( normal, viewDir, position, mat3( 1.0 ), rectCoords );
- }
- #endif
- void RE_Direct_Physical( const in IncidentLight directLight, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {
- float dotNL = saturate( dot( geometry.normal, directLight.direction ) );
- vec3 irradiance = dotNL * directLight.color;
- #ifndef PHYSICALLY_CORRECT_LIGHTS
- irradiance *= PI;
- #endif
- #ifdef CLEARCOAT
- float ccDotNL = saturate( dot( geometry.clearcoatNormal, directLight.direction ) );
- vec3 ccIrradiance = ccDotNL * directLight.color;
- #ifndef PHYSICALLY_CORRECT_LIGHTS
- ccIrradiance *= PI;
- #endif
- float clearcoatDHR = material.clearcoat * clearcoatDHRApprox( material.clearcoatRoughness, ccDotNL );
- reflectedLight.directSpecular += ccIrradiance * material.clearcoat * BRDF_Specular_GGX( directLight, geometry.viewDir, geometry.clearcoatNormal, vec3( DEFAULT_SPECULAR_COEFFICIENT ), material.clearcoatRoughness );
- #else
- float clearcoatDHR = 0.0;
- #endif
- #ifdef USE_SHEEN
- reflectedLight.directSpecular += ( 1.0 - clearcoatDHR ) * irradiance * BRDF_Specular_Sheen(
- material.specularRoughness,
- directLight.direction,
- geometry,
- material.sheenColor
- );
- #else
- reflectedLight.directSpecular += ( 1.0 - clearcoatDHR ) * irradiance * BRDF_Specular_GGX( directLight, geometry.viewDir, geometry.normal, material.specularColor, material.specularRoughness);
- #endif
- reflectedLight.directDiffuse += ( 1.0 - clearcoatDHR ) * irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );
- }
- void RE_IndirectDiffuse_Physical( const in vec3 irradiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight ) {
- reflectedLight.indirectDiffuse += irradiance * BRDF_Diffuse_Lambert( material.diffuseColor );
- }
- void RE_IndirectSpecular_Physical( const in vec3 radiance, const in vec3 irradiance, const in vec3 clearcoatRadiance, const in GeometricContext geometry, const in PhysicalMaterial material, inout ReflectedLight reflectedLight) {
- #ifdef CLEARCOAT
- float ccDotNV = saturate( dot( geometry.clearcoatNormal, geometry.viewDir ) );
- reflectedLight.indirectSpecular += clearcoatRadiance * material.clearcoat * BRDF_Specular_GGX_Environment( geometry.viewDir, geometry.clearcoatNormal, vec3( DEFAULT_SPECULAR_COEFFICIENT ), material.clearcoatRoughness );
- float ccDotNL = ccDotNV;
- float clearcoatDHR = material.clearcoat * clearcoatDHRApprox( material.clearcoatRoughness, ccDotNL );
- #else
- float clearcoatDHR = 0.0;
- #endif
- float clearcoatInv = 1.0 - clearcoatDHR;
- vec3 singleScattering = vec3( 0.0 );
- vec3 multiScattering = vec3( 0.0 );
- vec3 cosineWeightedIrradiance = irradiance * RECIPROCAL_PI;
- BRDF_Specular_Multiscattering_Environment( geometry, material.specularColor, material.specularRoughness, singleScattering, multiScattering );
- vec3 diffuse = material.diffuseColor * ( 1.0 - ( singleScattering + multiScattering ) );
- reflectedLight.indirectSpecular += clearcoatInv * radiance * singleScattering;
- reflectedLight.indirectSpecular += multiScattering * cosineWeightedIrradiance;
- reflectedLight.indirectDiffuse += diffuse * cosineWeightedIrradiance;
- }
- #define RE_Direct RE_Direct_Physical
- #define RE_Direct_RectArea RE_Direct_RectArea_Physical
- #define RE_IndirectDiffuse RE_IndirectDiffuse_Physical
- #define RE_IndirectSpecular RE_IndirectSpecular_Physical
- float computeSpecularOcclusion( const in float dotNV, const in float ambientOcclusion, const in float roughness ) {
- return saturate( pow( dotNV + ambientOcclusion, exp2( - 16.0 * roughness - 1.0 ) ) - 1.0 + ambientOcclusion );
- }`,lights_fragment_begin:`
- GeometricContext geometry;
- geometry.position = - vViewPosition;
- geometry.normal = normal;
- geometry.viewDir = ( isOrthographic ) ? vec3( 0, 0, 1 ) : normalize( vViewPosition );
- #ifdef CLEARCOAT
- geometry.clearcoatNormal = clearcoatNormal;
- #endif
- IncidentLight directLight;
- #if ( NUM_POINT_LIGHTS > 0 ) && defined( RE_Direct )
- PointLight pointLight;
- #pragma unroll_loop
- for ( int i = 0; i < NUM_POINT_LIGHTS; i ++ ) {
- pointLight = pointLights[ i ];
- getPointDirectLightIrradiance( pointLight, geometry, directLight );
- #if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_POINT_LIGHT_SHADOWS )
- directLight.color *= all( bvec3( pointLight.shadow, directLight.visible, receiveShadow ) ) ? getPointShadow( pointShadowMap[ i ], pointLight.shadowMapSize, pointLight.shadowBias, pointLight.shadowRadius, vPointShadowCoord[ i ], pointLight.shadowCameraNear, pointLight.shadowCameraFar ) : 1.0;
- #endif
- RE_Direct( directLight, geometry, material, reflectedLight );
- }
- #endif
- #if ( NUM_SPOT_LIGHTS > 0 ) && defined( RE_Direct )
- SpotLight spotLight;
- #pragma unroll_loop
- for ( int i = 0; i < NUM_SPOT_LIGHTS; i ++ ) {
- spotLight = spotLights[ i ];
- getSpotDirectLightIrradiance( spotLight, geometry, directLight );
- #if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_SPOT_LIGHT_SHADOWS )
- directLight.color *= all( bvec3( spotLight.shadow, directLight.visible, receiveShadow ) ) ? getShadow( spotShadowMap[ i ], spotLight.shadowMapSize, spotLight.shadowBias, spotLight.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;
- #endif
- RE_Direct( directLight, geometry, material, reflectedLight );
- }
- #endif
- #if ( NUM_DIR_LIGHTS > 0 ) && defined( RE_Direct )
- DirectionalLight directionalLight;
- #pragma unroll_loop
- for ( int i = 0; i < NUM_DIR_LIGHTS; i ++ ) {
- directionalLight = directionalLights[ i ];
- getDirectionalDirectLightIrradiance( directionalLight, geometry, directLight );
- #if defined( USE_SHADOWMAP ) && ( UNROLLED_LOOP_INDEX < NUM_DIR_LIGHT_SHADOWS )
- directLight.color *= all( bvec3( directionalLight.shadow, directLight.visible, receiveShadow ) ) ? getShadow( directionalShadowMap[ i ], directionalLight.shadowMapSize, directionalLight.shadowBias, directionalLight.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;
- #endif
- RE_Direct( directLight, geometry, material, reflectedLight );
- }
- #endif
- #if ( NUM_RECT_AREA_LIGHTS > 0 ) && defined( RE_Direct_RectArea )
- RectAreaLight rectAreaLight;
- #pragma unroll_loop
- for ( int i = 0; i < NUM_RECT_AREA_LIGHTS; i ++ ) {
- rectAreaLight = rectAreaLights[ i ];
- RE_Direct_RectArea( rectAreaLight, geometry, material, reflectedLight );
- }
- #endif
- #if defined( RE_IndirectDiffuse )
- vec3 iblIrradiance = vec3( 0.0 );
- vec3 irradiance = getAmbientLightIrradiance( ambientLightColor );
- irradiance += getLightProbeIrradiance( lightProbe, geometry );
- #if ( NUM_HEMI_LIGHTS > 0 )
- #pragma unroll_loop
- for ( int i = 0; i < NUM_HEMI_LIGHTS; i ++ ) {
- irradiance += getHemisphereLightIrradiance( hemisphereLights[ i ], geometry );
- }
- #endif
- #endif
- #if defined( RE_IndirectSpecular )
- vec3 radiance = vec3( 0.0 );
- vec3 clearcoatRadiance = vec3( 0.0 );
- #endif`,lights_fragment_maps:`#if defined( RE_IndirectDiffuse )
- #ifdef USE_LIGHTMAP
- vec4 lightMapTexel= texture2D( lightMap, vUv2 );
- vec3 lightMapIrradiance = lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;
- #ifndef PHYSICALLY_CORRECT_LIGHTS
- lightMapIrradiance *= PI;
- #endif
- irradiance += lightMapIrradiance;
- #endif
- #if defined( USE_ENVMAP ) && defined( STANDARD ) && defined( ENVMAP_TYPE_CUBE_UV )
- iblIrradiance += getLightProbeIndirectIrradiance( geometry, maxMipLevel );
- #endif
- #endif
- #if defined( USE_ENVMAP ) && defined( RE_IndirectSpecular )
- radiance += getLightProbeIndirectRadiance( geometry.viewDir, geometry.normal, material.specularRoughness, maxMipLevel );
- #ifdef CLEARCOAT
- clearcoatRadiance += getLightProbeIndirectRadiance( geometry.viewDir, geometry.clearcoatNormal, material.clearcoatRoughness, maxMipLevel );
- #endif
- #endif`,lights_fragment_end:`#if defined( RE_IndirectDiffuse )
- RE_IndirectDiffuse( irradiance, geometry, material, reflectedLight );
- #endif
- #if defined( RE_IndirectSpecular )
- RE_IndirectSpecular( radiance, iblIrradiance, clearcoatRadiance, geometry, material, reflectedLight );
- #endif`,logdepthbuf_fragment:`#if defined( USE_LOGDEPTHBUF ) && defined( USE_LOGDEPTHBUF_EXT )
- gl_FragDepthEXT = vIsPerspective == 0.0 ? gl_FragCoord.z : log2( vFragDepth ) * logDepthBufFC * 0.5;
- #endif`,logdepthbuf_pars_fragment:`#if defined( USE_LOGDEPTHBUF ) && defined( USE_LOGDEPTHBUF_EXT )
- uniform float logDepthBufFC;
- varying float vFragDepth;
- varying float vIsPerspective;
- #endif`,logdepthbuf_pars_vertex:`#ifdef USE_LOGDEPTHBUF
- #ifdef USE_LOGDEPTHBUF_EXT
- varying float vFragDepth;
- varying float vIsPerspective;
- #else
- uniform float logDepthBufFC;
- #endif
- #endif`,logdepthbuf_vertex:`#ifdef USE_LOGDEPTHBUF
- #ifdef USE_LOGDEPTHBUF_EXT
- vFragDepth = 1.0 + gl_Position.w;
- vIsPerspective = float( isPerspectiveMatrix( projectionMatrix ) );
- #else
- if ( isPerspectiveMatrix( projectionMatrix ) ) {
- gl_Position.z = log2( max( EPSILON, gl_Position.w + 1.0 ) ) * logDepthBufFC - 1.0;
- gl_Position.z *= gl_Position.w;
- }
- #endif
- #endif`,map_fragment:`#ifdef USE_MAP
- vec4 texelColor = texture2D( map, vUv );
- texelColor = mapTexelToLinear( texelColor );
- diffuseColor *= texelColor;
- #endif`,map_pars_fragment:`#ifdef USE_MAP
- uniform sampler2D map;
- #endif`,map_particle_fragment:`#if defined( USE_MAP ) || defined( USE_ALPHAMAP )
- vec2 uv = ( uvTransform * vec3( gl_PointCoord.x, 1.0 - gl_PointCoord.y, 1 ) ).xy;
- #endif
- #ifdef USE_MAP
- vec4 mapTexel = texture2D( map, uv );
- diffuseColor *= mapTexelToLinear( mapTexel );
- #endif
- #ifdef USE_ALPHAMAP
- diffuseColor.a *= texture2D( alphaMap, uv ).g;
- #endif`,map_particle_pars_fragment:`#if defined( USE_MAP ) || defined( USE_ALPHAMAP )
- uniform mat3 uvTransform;
- #endif
- #ifdef USE_MAP
- uniform sampler2D map;
- #endif
- #ifdef USE_ALPHAMAP
- uniform sampler2D alphaMap;
- #endif`,metalnessmap_fragment:`float metalnessFactor = metalness;
- #ifdef USE_METALNESSMAP
- vec4 texelMetalness = texture2D( metalnessMap, vUv );
- metalnessFactor *= texelMetalness.b;
- #endif`,metalnessmap_pars_fragment:`#ifdef USE_METALNESSMAP
- uniform sampler2D metalnessMap;
- #endif`,morphnormal_vertex:`#ifdef USE_MORPHNORMALS
- objectNormal *= morphTargetBaseInfluence;
- objectNormal += morphNormal0 * morphTargetInfluences[ 0 ];
- objectNormal += morphNormal1 * morphTargetInfluences[ 1 ];
- objectNormal += morphNormal2 * morphTargetInfluences[ 2 ];
- objectNormal += morphNormal3 * morphTargetInfluences[ 3 ];
- #endif`,morphtarget_pars_vertex:`#ifdef USE_MORPHTARGETS
- uniform float morphTargetBaseInfluence;
- #ifndef USE_MORPHNORMALS
- uniform float morphTargetInfluences[ 8 ];
- #else
- uniform float morphTargetInfluences[ 4 ];
- #endif
- #endif`,morphtarget_vertex:`#ifdef USE_MORPHTARGETS
- transformed *= morphTargetBaseInfluence;
- transformed += morphTarget0 * morphTargetInfluences[ 0 ];
- transformed += morphTarget1 * morphTargetInfluences[ 1 ];
- transformed += morphTarget2 * morphTargetInfluences[ 2 ];
- transformed += morphTarget3 * morphTargetInfluences[ 3 ];
- #ifndef USE_MORPHNORMALS
- transformed += morphTarget4 * morphTargetInfluences[ 4 ];
- transformed += morphTarget5 * morphTargetInfluences[ 5 ];
- transformed += morphTarget6 * morphTargetInfluences[ 6 ];
- transformed += morphTarget7 * morphTargetInfluences[ 7 ];
- #endif
- #endif`,normal_fragment_begin:`#ifdef FLAT_SHADED
- vec3 fdx = vec3( dFdx( vViewPosition.x ), dFdx( vViewPosition.y ), dFdx( vViewPosition.z ) );
- vec3 fdy = vec3( dFdy( vViewPosition.x ), dFdy( vViewPosition.y ), dFdy( vViewPosition.z ) );
- vec3 normal = normalize( cross( fdx, fdy ) );
- #else
- vec3 normal = normalize( vNormal );
- #ifdef DOUBLE_SIDED
- normal = normal * ( float( gl_FrontFacing ) * 2.0 - 1.0 );
- #endif
- #ifdef USE_TANGENT
- vec3 tangent = normalize( vTangent );
- vec3 bitangent = normalize( vBitangent );
- #ifdef DOUBLE_SIDED
- tangent = tangent * ( float( gl_FrontFacing ) * 2.0 - 1.0 );
- bitangent = bitangent * ( float( gl_FrontFacing ) * 2.0 - 1.0 );
- #endif
- #if defined( TANGENTSPACE_NORMALMAP ) || defined( USE_CLEARCOAT_NORMALMAP )
- mat3 vTBN = mat3( tangent, bitangent, normal );
- #endif
- #endif
- #endif
- vec3 geometryNormal = normal;`,normal_fragment_maps:`#ifdef OBJECTSPACE_NORMALMAP
- normal = texture2D( normalMap, vUv ).xyz * 2.0 - 1.0;
- #ifdef FLIP_SIDED
- normal = - normal;
- #endif
- #ifdef DOUBLE_SIDED
- normal = normal * ( float( gl_FrontFacing ) * 2.0 - 1.0 );
- #endif
- normal = normalize( normalMatrix * normal );
- #elif defined( TANGENTSPACE_NORMALMAP )
- vec3 mapN = texture2D( normalMap, vUv ).xyz * 2.0 - 1.0;
- mapN.xy *= normalScale;
- #ifdef USE_TANGENT
- normal = normalize( vTBN * mapN );
- #else
- normal = perturbNormal2Arb( -vViewPosition, normal, mapN );
- #endif
- #elif defined( USE_BUMPMAP )
- normal = perturbNormalArb( -vViewPosition, normal, dHdxy_fwd() );
- #endif`,normalmap_pars_fragment:`#ifdef USE_NORMALMAP
- uniform sampler2D normalMap;
- uniform vec2 normalScale;
- #endif
- #ifdef OBJECTSPACE_NORMALMAP
- uniform mat3 normalMatrix;
- #endif
- #if ! defined ( USE_TANGENT ) && ( defined ( TANGENTSPACE_NORMALMAP ) || defined ( USE_CLEARCOAT_NORMALMAP ) )
- vec3 perturbNormal2Arb( vec3 eye_pos, vec3 surf_norm, vec3 mapN ) {
- vec3 q0 = vec3( dFdx( eye_pos.x ), dFdx( eye_pos.y ), dFdx( eye_pos.z ) );
- vec3 q1 = vec3( dFdy( eye_pos.x ), dFdy( eye_pos.y ), dFdy( eye_pos.z ) );
- vec2 st0 = dFdx( vUv.st );
- vec2 st1 = dFdy( vUv.st );
- float scale = sign( st1.t * st0.s - st0.t * st1.s );
- vec3 S = normalize( ( q0 * st1.t - q1 * st0.t ) * scale );
- vec3 T = normalize( ( - q0 * st1.s + q1 * st0.s ) * scale );
- vec3 N = normalize( surf_norm );
- mat3 tsn = mat3( S, T, N );
- mapN.xy *= ( float( gl_FrontFacing ) * 2.0 - 1.0 );
- return normalize( tsn * mapN );
- }
- #endif`,clearcoat_normal_fragment_begin:`#ifdef CLEARCOAT
- vec3 clearcoatNormal = geometryNormal;
- #endif`,clearcoat_normal_fragment_maps:`#ifdef USE_CLEARCOAT_NORMALMAP
- vec3 clearcoatMapN = texture2D( clearcoatNormalMap, vUv ).xyz * 2.0 - 1.0;
- clearcoatMapN.xy *= clearcoatNormalScale;
- #ifdef USE_TANGENT
- clearcoatNormal = normalize( vTBN * clearcoatMapN );
- #else
- clearcoatNormal = perturbNormal2Arb( - vViewPosition, clearcoatNormal, clearcoatMapN );
- #endif
- #endif`,clearcoat_normalmap_pars_fragment:`#ifdef USE_CLEARCOAT_NORMALMAP
- uniform sampler2D clearcoatNormalMap;
- uniform vec2 clearcoatNormalScale;
- #endif`,packing:`vec3 packNormalToRGB( const in vec3 normal ) {
- return normalize( normal ) * 0.5 + 0.5;
- }
- vec3 unpackRGBToNormal( const in vec3 rgb ) {
- return 2.0 * rgb.xyz - 1.0;
- }
- const float PackUpscale = 256. / 255.;const float UnpackDownscale = 255. / 256.;
- const vec3 PackFactors = vec3( 256. * 256. * 256., 256. * 256., 256. );
- const vec4 UnpackFactors = UnpackDownscale / vec4( PackFactors, 1. );
- const float ShiftRight8 = 1. / 256.;
- vec4 packDepthToRGBA( const in float v ) {
- vec4 r = vec4( fract( v * PackFactors ), v );
- r.yzw -= r.xyz * ShiftRight8; return r * PackUpscale;
- }
- float unpackRGBAToDepth( const in vec4 v ) {
- return dot( v, UnpackFactors );
- }
- vec4 pack2HalfToRGBA( vec2 v ) {
- vec4 r = vec4( v.x, fract( v.x * 255.0 ), v.y, fract( v.y * 255.0 ));
- return vec4( r.x - r.y / 255.0, r.y, r.z - r.w / 255.0, r.w);
- }
- vec2 unpackRGBATo2Half( vec4 v ) {
- return vec2( v.x + ( v.y / 255.0 ), v.z + ( v.w / 255.0 ) );
- }
- float viewZToOrthographicDepth( const in float viewZ, const in float near, const in float far ) {
- return ( viewZ + near ) / ( near - far );
- }
- float orthographicDepthToViewZ( const in float linearClipZ, const in float near, const in float far ) {
- return linearClipZ * ( near - far ) - near;
- }
- float viewZToPerspectiveDepth( const in float viewZ, const in float near, const in float far ) {
- return (( near + viewZ ) * far ) / (( far - near ) * viewZ );
- }
- float perspectiveDepthToViewZ( const in float invClipZ, const in float near, const in float far ) {
- return ( near * far ) / ( ( far - near ) * invClipZ - far );
- }`,premultiplied_alpha_fragment:`#ifdef PREMULTIPLIED_ALPHA
- gl_FragColor.rgb *= gl_FragColor.a;
- #endif`,project_vertex:`vec4 mvPosition = vec4( transformed, 1.0 );
- #ifdef USE_INSTANCING
- mvPosition = instanceMatrix * mvPosition;
- #endif
- mvPosition = modelViewMatrix * mvPosition;
- gl_Position = projectionMatrix * mvPosition;`,dithering_fragment:`#ifdef DITHERING
- gl_FragColor.rgb = dithering( gl_FragColor.rgb );
- #endif`,dithering_pars_fragment:`#ifdef DITHERING
- vec3 dithering( vec3 color ) {
- float grid_position = rand( gl_FragCoord.xy );
- vec3 dither_shift_RGB = vec3( 0.25 / 255.0, -0.25 / 255.0, 0.25 / 255.0 );
- dither_shift_RGB = mix( 2.0 * dither_shift_RGB, -2.0 * dither_shift_RGB, grid_position );
- return color + dither_shift_RGB;
- }
- #endif`,roughnessmap_fragment:`float roughnessFactor = roughness;
- #ifdef USE_ROUGHNESSMAP
- vec4 texelRoughness = texture2D( roughnessMap, vUv );
- roughnessFactor *= texelRoughness.g;
- #endif`,roughnessmap_pars_fragment:`#ifdef USE_ROUGHNESSMAP
- uniform sampler2D roughnessMap;
- #endif`,shadowmap_pars_fragment:`#ifdef USE_SHADOWMAP
- #if NUM_DIR_LIGHT_SHADOWS > 0
- uniform sampler2D directionalShadowMap[ NUM_DIR_LIGHT_SHADOWS ];
- varying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHT_SHADOWS ];
- #endif
- #if NUM_SPOT_LIGHT_SHADOWS > 0
- uniform sampler2D spotShadowMap[ NUM_SPOT_LIGHT_SHADOWS ];
- varying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHT_SHADOWS ];
- #endif
- #if NUM_POINT_LIGHT_SHADOWS > 0
- uniform sampler2D pointShadowMap[ NUM_POINT_LIGHT_SHADOWS ];
- varying vec4 vPointShadowCoord[ NUM_POINT_LIGHT_SHADOWS ];
- #endif
- float texture2DCompare( sampler2D depths, vec2 uv, float compare ) {
- return step( compare, unpackRGBAToDepth( texture2D( depths, uv ) ) );
- }
- vec2 texture2DDistribution( sampler2D shadow, vec2 uv ) {
- return unpackRGBATo2Half( texture2D( shadow, uv ) );
- }
- float VSMShadow (sampler2D shadow, vec2 uv, float compare ){
- float occlusion = 1.0;
- vec2 distribution = texture2DDistribution( shadow, uv );
- float hard_shadow = step( compare , distribution.x );
- if (hard_shadow != 1.0 ) {
- float distance = compare - distribution.x ;
- float variance = max( 0.00000, distribution.y * distribution.y );
- float softness_probability = variance / (variance + distance * distance ); softness_probability = clamp( ( softness_probability - 0.3 ) / ( 0.95 - 0.3 ), 0.0, 1.0 ); occlusion = clamp( max( hard_shadow, softness_probability ), 0.0, 1.0 );
- }
- return occlusion;
- }
- float getShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord ) {
- float shadow = 1.0;
- shadowCoord.xyz /= shadowCoord.w;
- shadowCoord.z += shadowBias;
- bvec4 inFrustumVec = bvec4 ( shadowCoord.x >= 0.0, shadowCoord.x <= 1.0, shadowCoord.y >= 0.0, shadowCoord.y <= 1.0 );
- bool inFrustum = all( inFrustumVec );
- bvec2 frustumTestVec = bvec2( inFrustum, shadowCoord.z <= 1.0 );
- bool frustumTest = all( frustumTestVec );
- if ( frustumTest ) {
- #if defined( SHADOWMAP_TYPE_PCF )
- vec2 texelSize = vec2( 1.0 ) / shadowMapSize;
- float dx0 = - texelSize.x * shadowRadius;
- float dy0 = - texelSize.y * shadowRadius;
- float dx1 = + texelSize.x * shadowRadius;
- float dy1 = + texelSize.y * shadowRadius;
- float dx2 = dx0 / 2.0;
- float dy2 = dy0 / 2.0;
- float dx3 = dx1 / 2.0;
- float dy3 = dy1 / 2.0;
- shadow = (
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy0 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy0 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy0 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, dy2 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy2 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, dy2 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, 0.0 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, 0.0 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, 0.0 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, 0.0 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( dx2, dy3 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy3 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( dx3, dy3 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( dx0, dy1 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( 0.0, dy1 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, shadowCoord.xy + vec2( dx1, dy1 ), shadowCoord.z )
- ) * ( 1.0 / 17.0 );
- #elif defined( SHADOWMAP_TYPE_PCF_SOFT )
- vec2 texelSize = vec2( 1.0 ) / shadowMapSize;
- float dx = texelSize.x;
- float dy = texelSize.y;
- vec2 uv = shadowCoord.xy;
- vec2 f = fract( uv * shadowMapSize + 0.5 );
- uv -= f * texelSize;
- shadow = (
- texture2DCompare( shadowMap, uv, shadowCoord.z ) +
- texture2DCompare( shadowMap, uv + vec2( dx, 0.0 ), shadowCoord.z ) +
- texture2DCompare( shadowMap, uv + vec2( 0.0, dy ), shadowCoord.z ) +
- texture2DCompare( shadowMap, uv + texelSize, shadowCoord.z ) +
- mix( texture2DCompare( shadowMap, uv + vec2( -dx, 0.0 ), shadowCoord.z ),
- texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, 0.0 ), shadowCoord.z ),
- f.x ) +
- mix( texture2DCompare( shadowMap, uv + vec2( -dx, dy ), shadowCoord.z ),
- texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, dy ), shadowCoord.z ),
- f.x ) +
- mix( texture2DCompare( shadowMap, uv + vec2( 0.0, -dy ), shadowCoord.z ),
- texture2DCompare( shadowMap, uv + vec2( 0.0, 2.0 * dy ), shadowCoord.z ),
- f.y ) +
- mix( texture2DCompare( shadowMap, uv + vec2( dx, -dy ), shadowCoord.z ),
- texture2DCompare( shadowMap, uv + vec2( dx, 2.0 * dy ), shadowCoord.z ),
- f.y ) +
- mix( mix( texture2DCompare( shadowMap, uv + vec2( -dx, -dy ), shadowCoord.z ),
- texture2DCompare( shadowMap, uv + vec2( 2.0 * dx, -dy ), shadowCoord.z ),
- f.x ),
- mix( texture2DCompare( shadowMap, uv + vec2( -dx, 2.0 * dy ), shadowCoord.z ),
- texture2DCompare( shadowMap, uv + + vec2( 2.0 * dx, 2.0 * dy ), shadowCoord.z ),
- f.x ),
- f.y )
- ) * ( 1.0 / 9.0 );
- #elif defined( SHADOWMAP_TYPE_VSM )
- shadow = VSMShadow( shadowMap, shadowCoord.xy, shadowCoord.z );
- #else
- shadow = texture2DCompare( shadowMap, shadowCoord.xy, shadowCoord.z );
- #endif
- }
- return shadow;
- }
- vec2 cubeToUV( vec3 v, float texelSizeY ) {
- vec3 absV = abs( v );
- float scaleToCube = 1.0 / max( absV.x, max( absV.y, absV.z ) );
- absV *= scaleToCube;
- v *= scaleToCube * ( 1.0 - 2.0 * texelSizeY );
- vec2 planar = v.xy;
- float almostATexel = 1.5 * texelSizeY;
- float almostOne = 1.0 - almostATexel;
- if ( absV.z >= almostOne ) {
- if ( v.z > 0.0 )
- planar.x = 4.0 - v.x;
- } else if ( absV.x >= almostOne ) {
- float signX = sign( v.x );
- planar.x = v.z * signX + 2.0 * signX;
- } else if ( absV.y >= almostOne ) {
- float signY = sign( v.y );
- planar.x = v.x + 2.0 * signY + 2.0;
- planar.y = v.z * signY - 2.0;
- }
- return vec2( 0.125, 0.25 ) * planar + vec2( 0.375, 0.75 );
- }
- float getPointShadow( sampler2D shadowMap, vec2 shadowMapSize, float shadowBias, float shadowRadius, vec4 shadowCoord, float shadowCameraNear, float shadowCameraFar ) {
- vec2 texelSize = vec2( 1.0 ) / ( shadowMapSize * vec2( 4.0, 2.0 ) );
- vec3 lightToPosition = shadowCoord.xyz;
- float dp = ( length( lightToPosition ) - shadowCameraNear ) / ( shadowCameraFar - shadowCameraNear ); dp += shadowBias;
- vec3 bd3D = normalize( lightToPosition );
- #if defined( SHADOWMAP_TYPE_PCF ) || defined( SHADOWMAP_TYPE_PCF_SOFT ) || defined( SHADOWMAP_TYPE_VSM )
- vec2 offset = vec2( - 1, 1 ) * shadowRadius * texelSize.y;
- return (
- texture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyy, texelSize.y ), dp ) +
- texture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyy, texelSize.y ), dp ) +
- texture2DCompare( shadowMap, cubeToUV( bd3D + offset.xyx, texelSize.y ), dp ) +
- texture2DCompare( shadowMap, cubeToUV( bd3D + offset.yyx, texelSize.y ), dp ) +
- texture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp ) +
- texture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxy, texelSize.y ), dp ) +
- texture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxy, texelSize.y ), dp ) +
- texture2DCompare( shadowMap, cubeToUV( bd3D + offset.xxx, texelSize.y ), dp ) +
- texture2DCompare( shadowMap, cubeToUV( bd3D + offset.yxx, texelSize.y ), dp )
- ) * ( 1.0 / 9.0 );
- #else
- return texture2DCompare( shadowMap, cubeToUV( bd3D, texelSize.y ), dp );
- #endif
- }
- #endif`,shadowmap_pars_vertex:`#ifdef USE_SHADOWMAP
- #if NUM_DIR_LIGHT_SHADOWS > 0
- uniform mat4 directionalShadowMatrix[ NUM_DIR_LIGHT_SHADOWS ];
- varying vec4 vDirectionalShadowCoord[ NUM_DIR_LIGHT_SHADOWS ];
- #endif
- #if NUM_SPOT_LIGHT_SHADOWS > 0
- uniform mat4 spotShadowMatrix[ NUM_SPOT_LIGHT_SHADOWS ];
- varying vec4 vSpotShadowCoord[ NUM_SPOT_LIGHT_SHADOWS ];
- #endif
- #if NUM_POINT_LIGHT_SHADOWS > 0
- uniform mat4 pointShadowMatrix[ NUM_POINT_LIGHT_SHADOWS ];
- varying vec4 vPointShadowCoord[ NUM_POINT_LIGHT_SHADOWS ];
- #endif
- #endif`,shadowmap_vertex:`#ifdef USE_SHADOWMAP
- #if NUM_DIR_LIGHT_SHADOWS > 0
- #pragma unroll_loop
- for ( int i = 0; i < NUM_DIR_LIGHT_SHADOWS; i ++ ) {
- vDirectionalShadowCoord[ i ] = directionalShadowMatrix[ i ] * worldPosition;
- }
- #endif
- #if NUM_SPOT_LIGHT_SHADOWS > 0
- #pragma unroll_loop
- for ( int i = 0; i < NUM_SPOT_LIGHT_SHADOWS; i ++ ) {
- vSpotShadowCoord[ i ] = spotShadowMatrix[ i ] * worldPosition;
- }
- #endif
- #if NUM_POINT_LIGHT_SHADOWS > 0
- #pragma unroll_loop
- for ( int i = 0; i < NUM_POINT_LIGHT_SHADOWS; i ++ ) {
- vPointShadowCoord[ i ] = pointShadowMatrix[ i ] * worldPosition;
- }
- #endif
- #endif`,shadowmask_pars_fragment:`float getShadowMask() {
- float shadow = 1.0;
- #ifdef USE_SHADOWMAP
- #if NUM_DIR_LIGHT_SHADOWS > 0
- DirectionalLight directionalLight;
- #pragma unroll_loop
- for ( int i = 0; i < NUM_DIR_LIGHT_SHADOWS; i ++ ) {
- directionalLight = directionalLights[ i ];
- shadow *= all( bvec2( directionalLight.shadow, receiveShadow ) ) ? getShadow( directionalShadowMap[ i ], directionalLight.shadowMapSize, directionalLight.shadowBias, directionalLight.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;
- }
- #endif
- #if NUM_SPOT_LIGHT_SHADOWS > 0
- SpotLight spotLight;
- #pragma unroll_loop
- for ( int i = 0; i < NUM_SPOT_LIGHT_SHADOWS; i ++ ) {
- spotLight = spotLights[ i ];
- shadow *= all( bvec2( spotLight.shadow, receiveShadow ) ) ? getShadow( spotShadowMap[ i ], spotLight.shadowMapSize, spotLight.shadowBias, spotLight.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;
- }
- #endif
- #if NUM_POINT_LIGHT_SHADOWS > 0
- PointLight pointLight;
- #pragma unroll_loop
- for ( int i = 0; i < NUM_POINT_LIGHT_SHADOWS; i ++ ) {
- pointLight = pointLights[ i ];
- shadow *= all( bvec2( pointLight.shadow, receiveShadow ) ) ? getPointShadow( pointShadowMap[ i ], pointLight.shadowMapSize, pointLight.shadowBias, pointLight.shadowRadius, vPointShadowCoord[ i ], pointLight.shadowCameraNear, pointLight.shadowCameraFar ) : 1.0;
- }
- #endif
- #endif
- return shadow;
- }`,skinbase_vertex:`#ifdef USE_SKINNING
- mat4 boneMatX = getBoneMatrix( skinIndex.x );
- mat4 boneMatY = getBoneMatrix( skinIndex.y );
- mat4 boneMatZ = getBoneMatrix( skinIndex.z );
- mat4 boneMatW = getBoneMatrix( skinIndex.w );
- #endif`,skinning_pars_vertex:`#ifdef USE_SKINNING
- uniform mat4 bindMatrix;
- uniform mat4 bindMatrixInverse;
- #ifdef BONE_TEXTURE
- uniform highp sampler2D boneTexture;
- uniform int boneTextureSize;
- mat4 getBoneMatrix( const in float i ) {
- float j = i * 4.0;
- float x = mod( j, float( boneTextureSize ) );
- float y = floor( j / float( boneTextureSize ) );
- float dx = 1.0 / float( boneTextureSize );
- float dy = 1.0 / float( boneTextureSize );
- y = dy * ( y + 0.5 );
- vec4 v1 = texture2D( boneTexture, vec2( dx * ( x + 0.5 ), y ) );
- vec4 v2 = texture2D( boneTexture, vec2( dx * ( x + 1.5 ), y ) );
- vec4 v3 = texture2D( boneTexture, vec2( dx * ( x + 2.5 ), y ) );
- vec4 v4 = texture2D( boneTexture, vec2( dx * ( x + 3.5 ), y ) );
- mat4 bone = mat4( v1, v2, v3, v4 );
- return bone;
- }
- #else
- uniform mat4 boneMatrices[ MAX_BONES ];
- mat4 getBoneMatrix( const in float i ) {
- mat4 bone = boneMatrices[ int(i) ];
- return bone;
- }
- #endif
- #endif`,skinning_vertex:`#ifdef USE_SKINNING
- vec4 skinVertex = bindMatrix * vec4( transformed, 1.0 );
- vec4 skinned = vec4( 0.0 );
- skinned += boneMatX * skinVertex * skinWeight.x;
- skinned += boneMatY * skinVertex * skinWeight.y;
- skinned += boneMatZ * skinVertex * skinWeight.z;
- skinned += boneMatW * skinVertex * skinWeight.w;
- transformed = ( bindMatrixInverse * skinned ).xyz;
- #endif`,skinnormal_vertex:`#ifdef USE_SKINNING
- mat4 skinMatrix = mat4( 0.0 );
- skinMatrix += skinWeight.x * boneMatX;
- skinMatrix += skinWeight.y * boneMatY;
- skinMatrix += skinWeight.z * boneMatZ;
- skinMatrix += skinWeight.w * boneMatW;
- skinMatrix = bindMatrixInverse * skinMatrix * bindMatrix;
- objectNormal = vec4( skinMatrix * vec4( objectNormal, 0.0 ) ).xyz;
- #ifdef USE_TANGENT
- objectTangent = vec4( skinMatrix * vec4( objectTangent, 0.0 ) ).xyz;
- #endif
- #endif`,specularmap_fragment:`float specularStrength;
- #ifdef USE_SPECULARMAP
- vec4 texelSpecular = texture2D( specularMap, vUv );
- specularStrength = texelSpecular.r;
- #else
- specularStrength = 1.0;
- #endif`,specularmap_pars_fragment:`#ifdef USE_SPECULARMAP
- uniform sampler2D specularMap;
- #endif`,tonemapping_fragment:`#if defined( TONE_MAPPING )
- gl_FragColor.rgb = toneMapping( gl_FragColor.rgb );
- #endif`,tonemapping_pars_fragment:`#ifndef saturate
- #define saturate(a) clamp( a, 0.0, 1.0 )
- #endif
- uniform float toneMappingExposure;
- uniform float toneMappingWhitePoint;
- vec3 LinearToneMapping( vec3 color ) {
- return toneMappingExposure * color;
- }
- vec3 ReinhardToneMapping( vec3 color ) {
- color *= toneMappingExposure;
- return saturate( color / ( vec3( 1.0 ) + color ) );
- }
- #define Uncharted2Helper( x ) max( ( ( x * ( 0.15 * x + 0.10 * 0.50 ) + 0.20 * 0.02 ) / ( x * ( 0.15 * x + 0.50 ) + 0.20 * 0.30 ) ) - 0.02 / 0.30, vec3( 0.0 ) )
- vec3 Uncharted2ToneMapping( vec3 color ) {
- color *= toneMappingExposure;
- return saturate( Uncharted2Helper( color ) / Uncharted2Helper( vec3( toneMappingWhitePoint ) ) );
- }
- vec3 OptimizedCineonToneMapping( vec3 color ) {
- color *= toneMappingExposure;
- color = max( vec3( 0.0 ), color - 0.004 );
- return pow( ( color * ( 6.2 * color + 0.5 ) ) / ( color * ( 6.2 * color + 1.7 ) + 0.06 ), vec3( 2.2 ) );
- }
- vec3 ACESFilmicToneMapping( vec3 color ) {
- color *= toneMappingExposure;
- return saturate( ( color * ( 2.51 * color + 0.03 ) ) / ( color * ( 2.43 * color + 0.59 ) + 0.14 ) );
- }`,uv_pars_fragment:`#if ( defined( USE_UV ) && ! defined( UVS_VERTEX_ONLY ) )
- varying vec2 vUv;
- #endif`,uv_pars_vertex:`#ifdef USE_UV
- #ifdef UVS_VERTEX_ONLY
- vec2 vUv;
- #else
- varying vec2 vUv;
- #endif
- uniform mat3 uvTransform;
- #endif`,uv_vertex:`#ifdef USE_UV
- vUv = ( uvTransform * vec3( uv, 1 ) ).xy;
- #endif`,uv2_pars_fragment:`#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )
- varying vec2 vUv2;
- #endif`,uv2_pars_vertex:`#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )
- attribute vec2 uv2;
- varying vec2 vUv2;
- uniform mat3 uv2Transform;
- #endif`,uv2_vertex:`#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )
- vUv2 = ( uv2Transform * vec3( uv2, 1 ) ).xy;
- #endif`,worldpos_vertex:`#if defined( USE_ENVMAP ) || defined( DISTANCE ) || defined ( USE_SHADOWMAP )
- vec4 worldPosition = vec4( transformed, 1.0 );
- #ifdef USE_INSTANCING
- worldPosition = instanceMatrix * worldPosition;
- #endif
- worldPosition = modelMatrix * worldPosition;
- #endif`,background_frag:`uniform sampler2D t2D;
- varying vec2 vUv;
- void main() {
- vec4 texColor = texture2D( t2D, vUv );
- gl_FragColor = mapTexelToLinear( texColor );
- #include <tonemapping_fragment>
- #include <encodings_fragment>
- }`,background_vert:`varying vec2 vUv;
- uniform mat3 uvTransform;
- void main() {
- vUv = ( uvTransform * vec3( uv, 1 ) ).xy;
- gl_Position = vec4( position.xy, 1.0, 1.0 );
- }`,cube_frag:`#include <envmap_common_pars_fragment>
- uniform float opacity;
- varying vec3 vWorldDirection;
- #include <cube_uv_reflection_fragment>
- void main() {
- vec3 vReflect = vWorldDirection;
- #include <envmap_fragment>
- gl_FragColor = envColor;
- gl_FragColor.a *= opacity;
- #include <tonemapping_fragment>
- #include <encodings_fragment>
- }`,cube_vert:`varying vec3 vWorldDirection;
- #include <common>
- void main() {
- vWorldDirection = transformDirection( position, modelMatrix );
- #include <begin_vertex>
- #include <project_vertex>
- gl_Position.z = gl_Position.w;
- }`,depth_frag:`#if DEPTH_PACKING == 3200
- uniform float opacity;
- #endif
- #include <common>
- #include <packing>
- #include <uv_pars_fragment>
- #include <map_pars_fragment>
- #include <alphamap_pars_fragment>
- #include <logdepthbuf_pars_fragment>
- #include <clipping_planes_pars_fragment>
- void main() {
- #include <clipping_planes_fragment>
- vec4 diffuseColor = vec4( 1.0 );
- #if DEPTH_PACKING == 3200
- diffuseColor.a = opacity;
- #endif
- #include <map_fragment>
- #include <alphamap_fragment>
- #include <alphatest_fragment>
- #include <logdepthbuf_fragment>
- #if DEPTH_PACKING == 3200
- gl_FragColor = vec4( vec3( 1.0 - gl_FragCoord.z ), opacity );
- #elif DEPTH_PACKING == 3201
- gl_FragColor = packDepthToRGBA( gl_FragCoord.z );
- #endif
- }`,depth_vert:`#include <common>
- #include <uv_pars_vertex>
- #include <displacementmap_pars_vertex>
- #include <morphtarget_pars_vertex>
- #include <skinning_pars_vertex>
- #include <logdepthbuf_pars_vertex>
- #include <clipping_planes_pars_vertex>
- void main() {
- #include <uv_vertex>
- #include <skinbase_vertex>
- #ifdef USE_DISPLACEMENTMAP
- #include <beginnormal_vertex>
- #include <morphnormal_vertex>
- #include <skinnormal_vertex>
- #endif
- #include <begin_vertex>
- #include <morphtarget_vertex>
- #include <skinning_vertex>
- #include <displacementmap_vertex>
- #include <project_vertex>
- #include <logdepthbuf_vertex>
- #include <clipping_planes_vertex>
- }`,distanceRGBA_frag:`#define DISTANCE
- uniform vec3 referencePosition;
- uniform float nearDistance;
- uniform float farDistance;
- varying vec3 vWorldPosition;
- #include <common>
- #include <packing>
- #include <uv_pars_fragment>
- #include <map_pars_fragment>
- #include <alphamap_pars_fragment>
- #include <clipping_planes_pars_fragment>
- void main () {
- #include <clipping_planes_fragment>
- vec4 diffuseColor = vec4( 1.0 );
- #include <map_fragment>
- #include <alphamap_fragment>
- #include <alphatest_fragment>
- float dist = length( vWorldPosition - referencePosition );
- dist = ( dist - nearDistance ) / ( farDistance - nearDistance );
- dist = saturate( dist );
- gl_FragColor = packDepthToRGBA( dist );
- }`,distanceRGBA_vert:`#define DISTANCE
- varying vec3 vWorldPosition;
- #include <common>
- #include <uv_pars_vertex>
- #include <displacementmap_pars_vertex>
- #include <morphtarget_pars_vertex>
- #include <skinning_pars_vertex>
- #include <clipping_planes_pars_vertex>
- void main() {
- #include <uv_vertex>
- #include <skinbase_vertex>
- #ifdef USE_DISPLACEMENTMAP
- #include <beginnormal_vertex>
- #include <morphnormal_vertex>
- #include <skinnormal_vertex>
- #endif
- #include <begin_vertex>
- #include <morphtarget_vertex>
- #include <skinning_vertex>
- #include <displacementmap_vertex>
- #include <project_vertex>
- #include <worldpos_vertex>
- #include <clipping_planes_vertex>
- vWorldPosition = worldPosition.xyz;
- }`,equirect_frag:`uniform sampler2D tEquirect;
- varying vec3 vWorldDirection;
- #include <common>
- void main() {
- vec3 direction = normalize( vWorldDirection );
- vec2 sampleUV;
- sampleUV.y = asin( clamp( direction.y, - 1.0, 1.0 ) ) * RECIPROCAL_PI + 0.5;
- sampleUV.x = atan( direction.z, direction.x ) * RECIPROCAL_PI2 + 0.5;
- vec4 texColor = texture2D( tEquirect, sampleUV );
- gl_FragColor = mapTexelToLinear( texColor );
- #include <tonemapping_fragment>
- #include <encodings_fragment>
- }`,equirect_vert:`varying vec3 vWorldDirection;
- #include <common>
- void main() {
- vWorldDirection = transformDirection( position, modelMatrix );
- #include <begin_vertex>
- #include <project_vertex>
- }`,linedashed_frag:`uniform vec3 diffuse;
- uniform float opacity;
- uniform float dashSize;
- uniform float totalSize;
- varying float vLineDistance;
- #include <common>
- #include <color_pars_fragment>
- #include <fog_pars_fragment>
- #include <logdepthbuf_pars_fragment>
- #include <clipping_planes_pars_fragment>
- void main() {
- #include <clipping_planes_fragment>
- if ( mod( vLineDistance, totalSize ) > dashSize ) {
- discard;
- }
- vec3 outgoingLight = vec3( 0.0 );
- vec4 diffuseColor = vec4( diffuse, opacity );
- #include <logdepthbuf_fragment>
- #include <color_fragment>
- outgoingLight = diffuseColor.rgb;
- gl_FragColor = vec4( outgoingLight, diffuseColor.a );
- #include <tonemapping_fragment>
- #include <encodings_fragment>
- #include <fog_fragment>
- #include <premultiplied_alpha_fragment>
- }`,linedashed_vert:`uniform float scale;
- attribute float lineDistance;
- varying float vLineDistance;
- #include <common>
- #include <color_pars_vertex>
- #include <fog_pars_vertex>
- #include <logdepthbuf_pars_vertex>
- #include <clipping_planes_pars_vertex>
- void main() {
- #include <color_vertex>
- vLineDistance = scale * lineDistance;
- vec4 mvPosition = modelViewMatrix * vec4( position, 1.0 );
- gl_Position = projectionMatrix * mvPosition;
- #include <logdepthbuf_vertex>
- #include <clipping_planes_vertex>
- #include <fog_vertex>
- }`,meshbasic_frag:`uniform vec3 diffuse;
- uniform float opacity;
- #ifndef FLAT_SHADED
- varying vec3 vNormal;
- #endif
- #include <common>
- #include <color_pars_fragment>
- #include <uv_pars_fragment>
- #include <uv2_pars_fragment>
- #include <map_pars_fragment>
- #include <alphamap_pars_fragment>
- #include <aomap_pars_fragment>
- #include <lightmap_pars_fragment>
- #include <envmap_common_pars_fragment>
- #include <envmap_pars_fragment>
- #include <cube_uv_reflection_fragment>
- #include <fog_pars_fragment>
- #include <specularmap_pars_fragment>
- #include <logdepthbuf_pars_fragment>
- #include <clipping_planes_pars_fragment>
- void main() {
- #include <clipping_planes_fragment>
- vec4 diffuseColor = vec4( diffuse, opacity );
- #include <logdepthbuf_fragment>
- #include <map_fragment>
- #include <color_fragment>
- #include <alphamap_fragment>
- #include <alphatest_fragment>
- #include <specularmap_fragment>
- ReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );
- #ifdef USE_LIGHTMAP
-
- vec4 lightMapTexel= texture2D( lightMap, vUv2 );
- reflectedLight.indirectDiffuse += lightMapTexelToLinear( lightMapTexel ).rgb * lightMapIntensity;
- #else
- reflectedLight.indirectDiffuse += vec3( 1.0 );
- #endif
- #include <aomap_fragment>
- reflectedLight.indirectDiffuse *= diffuseColor.rgb;
- vec3 outgoingLight = reflectedLight.indirectDiffuse;
- #include <envmap_fragment>
- gl_FragColor = vec4( outgoingLight, diffuseColor.a );
- #include <tonemapping_fragment>
- #include <encodings_fragment>
- #include <fog_fragment>
- #include <premultiplied_alpha_fragment>
- }`,meshbasic_vert:`#include <common>
- #include <uv_pars_vertex>
- #include <uv2_pars_vertex>
- #include <envmap_pars_vertex>
- #include <color_pars_vertex>
- #include <fog_pars_vertex>
- #include <morphtarget_pars_vertex>
- #include <skinning_pars_vertex>
- #include <logdepthbuf_pars_vertex>
- #include <clipping_planes_pars_vertex>
- void main() {
- #include <uv_vertex>
- #include <uv2_vertex>
- #include <color_vertex>
- #include <skinbase_vertex>
- #ifdef USE_ENVMAP
- #include <beginnormal_vertex>
- #include <morphnormal_vertex>
- #include <skinnormal_vertex>
- #include <defaultnormal_vertex>
- #endif
- #include <begin_vertex>
- #include <morphtarget_vertex>
- #include <skinning_vertex>
- #include <project_vertex>
- #include <logdepthbuf_vertex>
- #include <worldpos_vertex>
- #include <clipping_planes_vertex>
- #include <envmap_vertex>
- #include <fog_vertex>
- }`,meshlambert_frag:`uniform vec3 diffuse;
- uniform vec3 emissive;
- uniform float opacity;
- varying vec3 vLightFront;
- varying vec3 vIndirectFront;
- #ifdef DOUBLE_SIDED
- varying vec3 vLightBack;
- varying vec3 vIndirectBack;
- #endif
- #include <common>
- #include <packing>
- #include <dithering_pars_fragment>
- #include <color_pars_fragment>
- #include <uv_pars_fragment>
- #include <uv2_pars_fragment>
- #include <map_pars_fragment>
- #include <alphamap_pars_fragment>
- #include <aomap_pars_fragment>
- #include <lightmap_pars_fragment>
- #include <emissivemap_pars_fragment>
- #include <envmap_common_pars_fragment>
- #include <envmap_pars_fragment>
- #include <cube_uv_reflection_fragment>
- #include <bsdfs>
- #include <lights_pars_begin>
- #include <fog_pars_fragment>
- #include <shadowmap_pars_fragment>
- #include <shadowmask_pars_fragment>
- #include <specularmap_pars_fragment>
- #include <logdepthbuf_pars_fragment>
- #include <clipping_planes_pars_fragment>
- void main() {
- #include <clipping_planes_fragment>
- vec4 diffuseColor = vec4( diffuse, opacity );
- ReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );
- vec3 totalEmissiveRadiance = emissive;
- #include <logdepthbuf_fragment>
- #include <map_fragment>
- #include <color_fragment>
- #include <alphamap_fragment>
- #include <alphatest_fragment>
- #include <specularmap_fragment>
- #include <emissivemap_fragment>
- reflectedLight.indirectDiffuse = getAmbientLightIrradiance( ambientLightColor );
- #ifdef DOUBLE_SIDED
- reflectedLight.indirectDiffuse += ( gl_FrontFacing ) ? vIndirectFront : vIndirectBack;
- #else
- reflectedLight.indirectDiffuse += vIndirectFront;
- #endif
- #include <lightmap_fragment>
- reflectedLight.indirectDiffuse *= BRDF_Diffuse_Lambert( diffuseColor.rgb );
- #ifdef DOUBLE_SIDED
- reflectedLight.directDiffuse = ( gl_FrontFacing ) ? vLightFront : vLightBack;
- #else
- reflectedLight.directDiffuse = vLightFront;
- #endif
- reflectedLight.directDiffuse *= BRDF_Diffuse_Lambert( diffuseColor.rgb ) * getShadowMask();
- #include <aomap_fragment>
- vec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + totalEmissiveRadiance;
- #include <envmap_fragment>
- gl_FragColor = vec4( outgoingLight, diffuseColor.a );
- #include <tonemapping_fragment>
- #include <encodings_fragment>
- #include <fog_fragment>
- #include <premultiplied_alpha_fragment>
- #include <dithering_fragment>
- }`,meshlambert_vert:`#define LAMBERT
- varying vec3 vLightFront;
- varying vec3 vIndirectFront;
- #ifdef DOUBLE_SIDED
- varying vec3 vLightBack;
- varying vec3 vIndirectBack;
- #endif
- #include <common>
- #include <uv_pars_vertex>
- #include <uv2_pars_vertex>
- #include <envmap_pars_vertex>
- #include <bsdfs>
- #include <lights_pars_begin>
- #include <color_pars_vertex>
- #include <fog_pars_vertex>
- #include <morphtarget_pars_vertex>
- #include <skinning_pars_vertex>
- #include <shadowmap_pars_vertex>
- #include <logdepthbuf_pars_vertex>
- #include <clipping_planes_pars_vertex>
- void main() {
- #include <uv_vertex>
- #include <uv2_vertex>
- #include <color_vertex>
- #include <beginnormal_vertex>
- #include <morphnormal_vertex>
- #include <skinbase_vertex>
- #include <skinnormal_vertex>
- #include <defaultnormal_vertex>
- #include <begin_vertex>
- #include <morphtarget_vertex>
- #include <skinning_vertex>
- #include <project_vertex>
- #include <logdepthbuf_vertex>
- #include <clipping_planes_vertex>
- #include <worldpos_vertex>
- #include <envmap_vertex>
- #include <lights_lambert_vertex>
- #include <shadowmap_vertex>
- #include <fog_vertex>
- }`,meshmatcap_frag:`#define MATCAP
- uniform vec3 diffuse;
- uniform float opacity;
- uniform sampler2D matcap;
- varying vec3 vViewPosition;
- #ifndef FLAT_SHADED
- varying vec3 vNormal;
- #endif
- #include <common>
- #include <uv_pars_fragment>
- #include <map_pars_fragment>
- #include <alphamap_pars_fragment>
- #include <fog_pars_fragment>
- #include <bumpmap_pars_fragment>
- #include <normalmap_pars_fragment>
- #include <logdepthbuf_pars_fragment>
- #include <clipping_planes_pars_fragment>
- void main() {
- #include <clipping_planes_fragment>
- vec4 diffuseColor = vec4( diffuse, opacity );
- #include <logdepthbuf_fragment>
- #include <map_fragment>
- #include <alphamap_fragment>
- #include <alphatest_fragment>
- #include <normal_fragment_begin>
- #include <normal_fragment_maps>
- vec3 viewDir = normalize( vViewPosition );
- vec3 x = normalize( vec3( viewDir.z, 0.0, - viewDir.x ) );
- vec3 y = cross( viewDir, x );
- vec2 uv = vec2( dot( x, normal ), dot( y, normal ) ) * 0.495 + 0.5;
- #ifdef USE_MATCAP
- vec4 matcapColor = texture2D( matcap, uv );
- matcapColor = matcapTexelToLinear( matcapColor );
- #else
- vec4 matcapColor = vec4( 1.0 );
- #endif
- vec3 outgoingLight = diffuseColor.rgb * matcapColor.rgb;
- gl_FragColor = vec4( outgoingLight, diffuseColor.a );
- #include <tonemapping_fragment>
- #include <encodings_fragment>
- #include <fog_fragment>
- #include <premultiplied_alpha_fragment>
- }`,meshmatcap_vert:`#define MATCAP
- varying vec3 vViewPosition;
- #ifndef FLAT_SHADED
- varying vec3 vNormal;
- #endif
- #include <common>
- #include <uv_pars_vertex>
- #include <displacementmap_pars_vertex>
- #include <fog_pars_vertex>
- #include <morphtarget_pars_vertex>
- #include <skinning_pars_vertex>
- #include <logdepthbuf_pars_vertex>
- #include <clipping_planes_pars_vertex>
- void main() {
- #include <uv_vertex>
- #include <beginnormal_vertex>
- #include <morphnormal_vertex>
- #include <skinbase_vertex>
- #include <skinnormal_vertex>
- #include <defaultnormal_vertex>
- #ifndef FLAT_SHADED
- vNormal = normalize( transformedNormal );
- #endif
- #include <begin_vertex>
- #include <morphtarget_vertex>
- #include <skinning_vertex>
- #include <displacementmap_vertex>
- #include <project_vertex>
- #include <logdepthbuf_vertex>
- #include <clipping_planes_vertex>
- #include <fog_vertex>
- vViewPosition = - mvPosition.xyz;
- }`,meshtoon_frag:`#define TOON
- uniform vec3 diffuse;
- uniform vec3 emissive;
- uniform vec3 specular;
- uniform float shininess;
- uniform float opacity;
- #include <common>
- #include <packing>
- #include <dithering_pars_fragment>
- #include <color_pars_fragment>
- #include <uv_pars_fragment>
- #include <uv2_pars_fragment>
- #include <map_pars_fragment>
- #include <alphamap_pars_fragment>
- #include <aomap_pars_fragment>
- #include <lightmap_pars_fragment>
- #include <emissivemap_pars_fragment>
- #include <gradientmap_pars_fragment>
- #include <fog_pars_fragment>
- #include <bsdfs>
- #include <lights_pars_begin>
- #include <lights_toon_pars_fragment>
- #include <shadowmap_pars_fragment>
- #include <bumpmap_pars_fragment>
- #include <normalmap_pars_fragment>
- #include <specularmap_pars_fragment>
- #include <logdepthbuf_pars_fragment>
- #include <clipping_planes_pars_fragment>
- void main() {
- #include <clipping_planes_fragment>
- vec4 diffuseColor = vec4( diffuse, opacity );
- ReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );
- vec3 totalEmissiveRadiance = emissive;
- #include <logdepthbuf_fragment>
- #include <map_fragment>
- #include <color_fragment>
- #include <alphamap_fragment>
- #include <alphatest_fragment>
- #include <specularmap_fragment>
- #include <normal_fragment_begin>
- #include <normal_fragment_maps>
- #include <emissivemap_fragment>
- #include <lights_toon_fragment>
- #include <lights_fragment_begin>
- #include <lights_fragment_maps>
- #include <lights_fragment_end>
- #include <aomap_fragment>
- vec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveRadiance;
- gl_FragColor = vec4( outgoingLight, diffuseColor.a );
- #include <tonemapping_fragment>
- #include <encodings_fragment>
- #include <fog_fragment>
- #include <premultiplied_alpha_fragment>
- #include <dithering_fragment>
- }`,meshtoon_vert:`#define TOON
- varying vec3 vViewPosition;
- #ifndef FLAT_SHADED
- varying vec3 vNormal;
- #endif
- #include <common>
- #include <uv_pars_vertex>
- #include <uv2_pars_vertex>
- #include <displacementmap_pars_vertex>
- #include <color_pars_vertex>
- #include <fog_pars_vertex>
- #include <morphtarget_pars_vertex>
- #include <skinning_pars_vertex>
- #include <shadowmap_pars_vertex>
- #include <logdepthbuf_pars_vertex>
- #include <clipping_planes_pars_vertex>
- void main() {
- #include <uv_vertex>
- #include <uv2_vertex>
- #include <color_vertex>
- #include <beginnormal_vertex>
- #include <morphnormal_vertex>
- #include <skinbase_vertex>
- #include <skinnormal_vertex>
- #include <defaultnormal_vertex>
- #ifndef FLAT_SHADED
- vNormal = normalize( transformedNormal );
- #endif
- #include <begin_vertex>
- #include <morphtarget_vertex>
- #include <skinning_vertex>
- #include <displacementmap_vertex>
- #include <project_vertex>
- #include <logdepthbuf_vertex>
- #include <clipping_planes_vertex>
- vViewPosition = - mvPosition.xyz;
- #include <worldpos_vertex>
- #include <shadowmap_vertex>
- #include <fog_vertex>
- }`,meshphong_frag:`#define PHONG
- uniform vec3 diffuse;
- uniform vec3 emissive;
- uniform vec3 specular;
- uniform float shininess;
- uniform float opacity;
- #include <common>
- #include <packing>
- #include <dithering_pars_fragment>
- #include <color_pars_fragment>
- #include <uv_pars_fragment>
- #include <uv2_pars_fragment>
- #include <map_pars_fragment>
- #include <alphamap_pars_fragment>
- #include <aomap_pars_fragment>
- #include <lightmap_pars_fragment>
- #include <emissivemap_pars_fragment>
- #include <envmap_common_pars_fragment>
- #include <envmap_pars_fragment>
- #include <cube_uv_reflection_fragment>
- #include <fog_pars_fragment>
- #include <bsdfs>
- #include <lights_pars_begin>
- #include <lights_phong_pars_fragment>
- #include <shadowmap_pars_fragment>
- #include <bumpmap_pars_fragment>
- #include <normalmap_pars_fragment>
- #include <specularmap_pars_fragment>
- #include <logdepthbuf_pars_fragment>
- #include <clipping_planes_pars_fragment>
- void main() {
- #include <clipping_planes_fragment>
- vec4 diffuseColor = vec4( diffuse, opacity );
- ReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );
- vec3 totalEmissiveRadiance = emissive;
- #include <logdepthbuf_fragment>
- #include <map_fragment>
- #include <color_fragment>
- #include <alphamap_fragment>
- #include <alphatest_fragment>
- #include <specularmap_fragment>
- #include <normal_fragment_begin>
- #include <normal_fragment_maps>
- #include <emissivemap_fragment>
- #include <lights_phong_fragment>
- #include <lights_fragment_begin>
- #include <lights_fragment_maps>
- #include <lights_fragment_end>
- #include <aomap_fragment>
- vec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveRadiance;
- #include <envmap_fragment>
- gl_FragColor = vec4( outgoingLight, diffuseColor.a );
- #include <tonemapping_fragment>
- #include <encodings_fragment>
- #include <fog_fragment>
- #include <premultiplied_alpha_fragment>
- #include <dithering_fragment>
- }`,meshphong_vert:`#define PHONG
- varying vec3 vViewPosition;
- #ifndef FLAT_SHADED
- varying vec3 vNormal;
- #endif
- #include <common>
- #include <uv_pars_vertex>
- #include <uv2_pars_vertex>
- #include <displacementmap_pars_vertex>
- #include <envmap_pars_vertex>
- #include <color_pars_vertex>
- #include <fog_pars_vertex>
- #include <morphtarget_pars_vertex>
- #include <skinning_pars_vertex>
- #include <shadowmap_pars_vertex>
- #include <logdepthbuf_pars_vertex>
- #include <clipping_planes_pars_vertex>
- void main() {
- #include <uv_vertex>
- #include <uv2_vertex>
- #include <color_vertex>
- #include <beginnormal_vertex>
- #include <morphnormal_vertex>
- #include <skinbase_vertex>
- #include <skinnormal_vertex>
- #include <defaultnormal_vertex>
- #ifndef FLAT_SHADED
- vNormal = normalize( transformedNormal );
- #endif
- #include <begin_vertex>
- #include <morphtarget_vertex>
- #include <skinning_vertex>
- #include <displacementmap_vertex>
- #include <project_vertex>
- #include <logdepthbuf_vertex>
- #include <clipping_planes_vertex>
- vViewPosition = - mvPosition.xyz;
- #include <worldpos_vertex>
- #include <envmap_vertex>
- #include <shadowmap_vertex>
- #include <fog_vertex>
- }`,meshphysical_frag:`#define STANDARD
- #ifdef PHYSICAL
- #define REFLECTIVITY
- #define CLEARCOAT
- #define TRANSPARENCY
- #endif
- uniform vec3 diffuse;
- uniform vec3 emissive;
- uniform float roughness;
- uniform float metalness;
- uniform float opacity;
- #ifdef TRANSPARENCY
- uniform float transparency;
- #endif
- #ifdef REFLECTIVITY
- uniform float reflectivity;
- #endif
- #ifdef CLEARCOAT
- uniform float clearcoat;
- uniform float clearcoatRoughness;
- #endif
- #ifdef USE_SHEEN
- uniform vec3 sheen;
- #endif
- varying vec3 vViewPosition;
- #ifndef FLAT_SHADED
- varying vec3 vNormal;
- #ifdef USE_TANGENT
- varying vec3 vTangent;
- varying vec3 vBitangent;
- #endif
- #endif
- #include <common>
- #include <packing>
- #include <dithering_pars_fragment>
- #include <color_pars_fragment>
- #include <uv_pars_fragment>
- #include <uv2_pars_fragment>
- #include <map_pars_fragment>
- #include <alphamap_pars_fragment>
- #include <aomap_pars_fragment>
- #include <lightmap_pars_fragment>
- #include <emissivemap_pars_fragment>
- #include <bsdfs>
- #include <cube_uv_reflection_fragment>
- #include <envmap_common_pars_fragment>
- #include <envmap_physical_pars_fragment>
- #include <fog_pars_fragment>
- #include <lights_pars_begin>
- #include <lights_physical_pars_fragment>
- #include <shadowmap_pars_fragment>
- #include <bumpmap_pars_fragment>
- #include <normalmap_pars_fragment>
- #include <clearcoat_normalmap_pars_fragment>
- #include <roughnessmap_pars_fragment>
- #include <metalnessmap_pars_fragment>
- #include <logdepthbuf_pars_fragment>
- #include <clipping_planes_pars_fragment>
- void main() {
- #include <clipping_planes_fragment>
- vec4 diffuseColor = vec4( diffuse, opacity );
- ReflectedLight reflectedLight = ReflectedLight( vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ), vec3( 0.0 ) );
- vec3 totalEmissiveRadiance = emissive;
- #include <logdepthbuf_fragment>
- #include <map_fragment>
- #include <color_fragment>
- #include <alphamap_fragment>
- #include <alphatest_fragment>
- #include <roughnessmap_fragment>
- #include <metalnessmap_fragment>
- #include <normal_fragment_begin>
- #include <normal_fragment_maps>
- #include <clearcoat_normal_fragment_begin>
- #include <clearcoat_normal_fragment_maps>
- #include <emissivemap_fragment>
- #include <lights_physical_fragment>
- #include <lights_fragment_begin>
- #include <lights_fragment_maps>
- #include <lights_fragment_end>
- #include <aomap_fragment>
- vec3 outgoingLight = reflectedLight.directDiffuse + reflectedLight.indirectDiffuse + reflectedLight.directSpecular + reflectedLight.indirectSpecular + totalEmissiveRadiance;
- #ifdef TRANSPARENCY
- diffuseColor.a *= saturate( 1. - transparency + linearToRelativeLuminance( reflectedLight.directSpecular + reflectedLight.indirectSpecular ) );
- #endif
- gl_FragColor = vec4( outgoingLight, diffuseColor.a );
- #include <tonemapping_fragment>
- #include <encodings_fragment>
- #include <fog_fragment>
- #include <premultiplied_alpha_fragment>
- #include <dithering_fragment>
- }`,meshphysical_vert:`#define STANDARD
- varying vec3 vViewPosition;
- #ifndef FLAT_SHADED
- varying vec3 vNormal;
- #ifdef USE_TANGENT
- varying vec3 vTangent;
- varying vec3 vBitangent;
- #endif
- #endif
- #include <common>
- #include <uv_pars_vertex>
- #include <uv2_pars_vertex>
- #include <displacementmap_pars_vertex>
- #include <color_pars_vertex>
- #include <fog_pars_vertex>
- #include <morphtarget_pars_vertex>
- #include <skinning_pars_vertex>
- #include <shadowmap_pars_vertex>
- #include <logdepthbuf_pars_vertex>
- #include <clipping_planes_pars_vertex>
- void main() {
- #include <uv_vertex>
- #include <uv2_vertex>
- #include <color_vertex>
- #include <beginnormal_vertex>
- #include <morphnormal_vertex>
- #include <skinbase_vertex>
- #include <skinnormal_vertex>
- #include <defaultnormal_vertex>
- #ifndef FLAT_SHADED
- vNormal = normalize( transformedNormal );
- #ifdef USE_TANGENT
- vTangent = normalize( transformedTangent );
- vBitangent = normalize( cross( vNormal, vTangent ) * tangent.w );
- #endif
- #endif
- #include <begin_vertex>
- #include <morphtarget_vertex>
- #include <skinning_vertex>
- #include <displacementmap_vertex>
- #include <project_vertex>
- #include <logdepthbuf_vertex>
- #include <clipping_planes_vertex>
- vViewPosition = - mvPosition.xyz;
- #include <worldpos_vertex>
- #include <shadowmap_vertex>
- #include <fog_vertex>
- }`,normal_frag:`#define NORMAL
- uniform float opacity;
- #if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )
- varying vec3 vViewPosition;
- #endif
- #ifndef FLAT_SHADED
- varying vec3 vNormal;
- #ifdef USE_TANGENT
- varying vec3 vTangent;
- varying vec3 vBitangent;
- #endif
- #endif
- #include <packing>
- #include <uv_pars_fragment>
- #include <bumpmap_pars_fragment>
- #include <normalmap_pars_fragment>
- #include <logdepthbuf_pars_fragment>
- #include <clipping_planes_pars_fragment>
- void main() {
- #include <clipping_planes_fragment>
- #include <logdepthbuf_fragment>
- #include <normal_fragment_begin>
- #include <normal_fragment_maps>
- gl_FragColor = vec4( packNormalToRGB( normal ), opacity );
- }`,normal_vert:`#define NORMAL
- #if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )
- varying vec3 vViewPosition;
- #endif
- #ifndef FLAT_SHADED
- varying vec3 vNormal;
- #ifdef USE_TANGENT
- varying vec3 vTangent;
- varying vec3 vBitangent;
- #endif
- #endif
- #include <common>
- #include <uv_pars_vertex>
- #include <displacementmap_pars_vertex>
- #include <morphtarget_pars_vertex>
- #include <skinning_pars_vertex>
- #include <logdepthbuf_pars_vertex>
- #include <clipping_planes_pars_vertex>
- void main() {
- #include <uv_vertex>
- #include <beginnormal_vertex>
- #include <morphnormal_vertex>
- #include <skinbase_vertex>
- #include <skinnormal_vertex>
- #include <defaultnormal_vertex>
- #ifndef FLAT_SHADED
- vNormal = normalize( transformedNormal );
- #ifdef USE_TANGENT
- vTangent = normalize( transformedTangent );
- vBitangent = normalize( cross( vNormal, vTangent ) * tangent.w );
- #endif
- #endif
- #include <begin_vertex>
- #include <morphtarget_vertex>
- #include <skinning_vertex>
- #include <displacementmap_vertex>
- #include <project_vertex>
- #include <logdepthbuf_vertex>
- #include <clipping_planes_vertex>
- #if defined( FLAT_SHADED ) || defined( USE_BUMPMAP ) || defined( TANGENTSPACE_NORMALMAP )
- vViewPosition = - mvPosition.xyz;
- #endif
- }`,points_frag:`uniform vec3 diffuse;
- uniform float opacity;
- #include <common>
- #include <color_pars_fragment>
- #include <map_particle_pars_fragment>
- #include <fog_pars_fragment>
- #include <logdepthbuf_pars_fragment>
- #include <clipping_planes_pars_fragment>
- void main() {
- #include <clipping_planes_fragment>
- vec3 outgoingLight = vec3( 0.0 );
- vec4 diffuseColor = vec4( diffuse, opacity );
- #include <logdepthbuf_fragment>
- #include <map_particle_fragment>
- #include <color_fragment>
- #include <alphatest_fragment>
- outgoingLight = diffuseColor.rgb;
- gl_FragColor = vec4( outgoingLight, diffuseColor.a );
- #include <tonemapping_fragment>
- #include <encodings_fragment>
- #include <fog_fragment>
- #include <premultiplied_alpha_fragment>
- }`,points_vert:`uniform float size;
- uniform float scale;
- #include <common>
- #include <color_pars_vertex>
- #include <fog_pars_vertex>
- #include <morphtarget_pars_vertex>
- #include <logdepthbuf_pars_vertex>
- #include <clipping_planes_pars_vertex>
- void main() {
- #include <color_vertex>
- #include <begin_vertex>
- #include <morphtarget_vertex>
- #include <project_vertex>
- gl_PointSize = size;
- #ifdef USE_SIZEATTENUATION
- bool isPerspective = isPerspectiveMatrix( projectionMatrix );
- if ( isPerspective ) gl_PointSize *= ( scale / - mvPosition.z );
- #endif
- #include <logdepthbuf_vertex>
- #include <clipping_planes_vertex>
- #include <worldpos_vertex>
- #include <fog_vertex>
- }`,shadow_frag:`uniform vec3 color;
- uniform float opacity;
- #include <common>
- #include <packing>
- #include <fog_pars_fragment>
- #include <bsdfs>
- #include <lights_pars_begin>
- #include <shadowmap_pars_fragment>
- #include <shadowmask_pars_fragment>
- void main() {
- gl_FragColor = vec4( color, opacity * ( 1.0 - getShadowMask() ) );
- #include <tonemapping_fragment>
- #include <encodings_fragment>
- #include <fog_fragment>
- }`,shadow_vert:`#include <fog_pars_vertex>
- #include <shadowmap_pars_vertex>
- void main() {
- #include <begin_vertex>
- #include <project_vertex>
- #include <worldpos_vertex>
- #include <shadowmap_vertex>
- #include <fog_vertex>
- }`,sprite_frag:`uniform vec3 diffuse;
- uniform float opacity;
- #include <common>
- #include <uv_pars_fragment>
- #include <map_pars_fragment>
- #include <alphamap_pars_fragment>
- #include <fog_pars_fragment>
- #include <logdepthbuf_pars_fragment>
- #include <clipping_planes_pars_fragment>
- void main() {
- #include <clipping_planes_fragment>
- vec3 outgoingLight = vec3( 0.0 );
- vec4 diffuseColor = vec4( diffuse, opacity );
- #include <logdepthbuf_fragment>
- #include <map_fragment>
- #include <alphamap_fragment>
- #include <alphatest_fragment>
- outgoingLight = diffuseColor.rgb;
- gl_FragColor = vec4( outgoingLight, diffuseColor.a );
- #include <tonemapping_fragment>
- #include <encodings_fragment>
- #include <fog_fragment>
- }`,sprite_vert:`uniform float rotation;
- uniform vec2 center;
- #include <common>
- #include <uv_pars_vertex>
- #include <fog_pars_vertex>
- #include <logdepthbuf_pars_vertex>
- #include <clipping_planes_pars_vertex>
- void main() {
- #include <uv_vertex>
- vec4 mvPosition = modelViewMatrix * vec4( 0.0, 0.0, 0.0, 1.0 );
- vec2 scale;
- scale.x = length( vec3( modelMatrix[ 0 ].x, modelMatrix[ 0 ].y, modelMatrix[ 0 ].z ) );
- scale.y = length( vec3( modelMatrix[ 1 ].x, modelMatrix[ 1 ].y, modelMatrix[ 1 ].z ) );
- #ifndef USE_SIZEATTENUATION
- bool isPerspective = isPerspectiveMatrix( projectionMatrix );
- if ( isPerspective ) scale *= - mvPosition.z;
- #endif
- vec2 alignedPosition = ( position.xy - ( center - vec2( 0.5 ) ) ) * scale;
- vec2 rotatedPosition;
- rotatedPosition.x = cos( rotation ) * alignedPosition.x - sin( rotation ) * alignedPosition.y;
- rotatedPosition.y = sin( rotation ) * alignedPosition.x + cos( rotation ) * alignedPosition.y;
- mvPosition.xy += rotatedPosition;
- gl_Position = projectionMatrix * mvPosition;
- #include <logdepthbuf_vertex>
- #include <clipping_planes_vertex>
- #include <fog_vertex>
- }`},Xd={basic:{uniforms:kc([Ts.common,Ts.specularmap,Ts.envmap,Ts.aomap,Ts.lightmap,Ts.fog]),vertexShader:ql.meshbasic_vert,fragmentShader:ql.meshbasic_frag},lambert:{uniforms:kc([Ts.common,Ts.specularmap,Ts.envmap,Ts.aomap,Ts.lightmap,Ts.emissivemap,Ts.fog,Ts.lights,{emissive:{value:new la(0)}}]),vertexShader:ql.meshlambert_vert,fragmentShader:ql.meshlambert_frag},phong:{uniforms:kc([Ts.common,Ts.specularmap,Ts.envmap,Ts.aomap,Ts.lightmap,Ts.emissivemap,Ts.bumpmap,Ts.normalmap,Ts.displacementmap,Ts.fog,Ts.lights,{emissive:{value:new la(0)},specular:{value:new la(1118481)},shininess:{value:30}}]),vertexShader:ql.meshphong_vert,fragmentShader:ql.meshphong_frag},standard:{uniforms:kc([Ts.common,Ts.envmap,Ts.aomap,Ts.lightmap,Ts.emissivemap,Ts.bumpmap,Ts.normalmap,Ts.displacementmap,Ts.roughnessmap,Ts.metalnessmap,Ts.fog,Ts.lights,{emissive:{value:new la(0)},roughness:{value:.5},metalness:{value:.5},envMapIntensity:{value:1}}]),vertexShader:ql.meshphysical_vert,fragmentShader:ql.meshphysical_frag},toon:{uniforms:kc([Ts.common,Ts.specularmap,Ts.aomap,Ts.lightmap,Ts.emissivemap,Ts.bumpmap,Ts.normalmap,Ts.displacementmap,Ts.gradientmap,Ts.fog,Ts.lights,{emissive:{value:new la(0)},specular:{value:new la(1118481)},shininess:{value:30}}]),vertexShader:ql.meshtoon_vert,fragmentShader:ql.meshtoon_frag},matcap:{uniforms:kc([Ts.common,Ts.bumpmap,Ts.normalmap,Ts.displacementmap,Ts.fog,{matcap:{value:null}}]),vertexShader:ql.meshmatcap_vert,fragmentShader:ql.meshmatcap_frag},points:{uniforms:kc([Ts.points,Ts.fog]),vertexShader:ql.points_vert,fragmentShader:ql.points_frag},dashed:{uniforms:kc([Ts.common,Ts.fog,{scale:{value:1},dashSize:{value:1},totalSize:{value:2}}]),vertexShader:ql.linedashed_vert,fragmentShader:ql.linedashed_frag},depth:{uniforms:kc([Ts.common,Ts.displacementmap]),vertexShader:ql.depth_vert,fragmentShader:ql.depth_frag},normal:{uniforms:kc([Ts.common,Ts.bumpmap,Ts.normalmap,Ts.displacementmap,{opacity:{value:1}}]),vertexShader:ql.normal_vert,fragmentShader:ql.normal_frag},sprite:{uniforms:kc([Ts.sprite,Ts.fog]),vertexShader:ql.sprite_vert,fragmentShader:ql.sprite_frag},background:{uniforms:{uvTransform:{value:new Vl},t2D:{value:null}},vertexShader:ql.background_vert,fragmentShader:ql.background_frag},cube:{uniforms:kc([Ts.envmap,{opacity:{value:1}}]),vertexShader:ql.cube_vert,fragmentShader:ql.cube_frag},equirect:{uniforms:{tEquirect:{value:null}},vertexShader:ql.equirect_vert,fragmentShader:ql.equirect_frag},distanceRGBA:{uniforms:kc([Ts.common,Ts.displacementmap,{referencePosition:{value:new yi},nearDistance:{value:1},farDistance:{value:1e3}}]),vertexShader:ql.distanceRGBA_vert,fragmentShader:ql.distanceRGBA_frag},shadow:{uniforms:kc([Ts.lights,Ts.fog,{color:{value:new la(0)},opacity:{value:1}}]),vertexShader:ql.shadow_vert,fragmentShader:ql.shadow_frag}};function Kl(f,E,W,ge){var ct,gt,St=new la(0),Pt=0,sn=null,ln=0,Sn=null;function En(On,mn){E.buffers.color.setClear(On.r,On.g,On.b,mn,ge)}return{getClearColor:function(){return St},setClearColor:function(On,mn){St.set(On),En(St,Pt=mn!==void 0?mn:1)},getClearAlpha:function(){return Pt},setClearAlpha:function(On){En(St,Pt=On)},render:function(On,mn,Hn,mr){var _r=mn.background,gi=f.xr,Ci=gi.getSession&&gi.getSession();if(Ci&&Ci.environmentBlendMode==="additive"&&(_r=null),_r===null?En(St,Pt):_r&&_r.isColor&&(En(_r,1),mr=!0),(f.autoClear||mr)&&f.clear(f.autoClearColor,f.autoClearDepth,f.autoClearStencil),_r&&(_r.isCubeTexture||_r.isWebGLCubeRenderTarget||_r.mapping===fi)){gt===void 0&&((gt=new lu(new Zo(1,1,1),new Ld({type:"BackgroundCubeMaterial",uniforms:Xh(Xd.cube.uniforms),vertexShader:Xd.cube.vertexShader,fragmentShader:Xd.cube.fragmentShader,side:q,depthTest:!1,depthWrite:!1,fog:!1}))).geometry.deleteAttribute("normal"),gt.geometry.deleteAttribute("uv"),gt.onBeforeRender=function(da,ji,Sa){this.matrixWorld.copyPosition(Sa.matrixWorld)},Object.defineProperty(gt.material,"envMap",{get:function(){return this.uniforms.envMap.value}}),W.update(gt));var $i=_r.isWebGLCubeRenderTarget?_r.texture:_r;gt.material.uniforms.envMap.value=$i,gt.material.uniforms.flipEnvMap.value=$i.isCubeTexture?-1:1,sn===_r&&ln===$i.version&&Sn===f.toneMapping||(gt.material.needsUpdate=!0,sn=_r,ln=$i.version,Sn=f.toneMapping),On.unshift(gt,gt.geometry,gt.material,0,0,null)}else _r&&_r.isTexture&&(ct===void 0&&((ct=new lu(new Qh(2,2),new Ld({type:"BackgroundMaterial",uniforms:Xh(Xd.background.uniforms),vertexShader:Xd.background.vertexShader,fragmentShader:Xd.background.fragmentShader,side:G,depthTest:!1,depthWrite:!1,fog:!1}))).geometry.deleteAttribute("normal"),Object.defineProperty(ct.material,"map",{get:function(){return this.uniforms.t2D.value}}),W.update(ct)),(ct.material.uniforms.t2D.value=_r).matrixAutoUpdate===!0&&_r.updateMatrix(),ct.material.uniforms.uvTransform.value.copy(_r.matrix),sn===_r&&ln===_r.version&&Sn===f.toneMapping||(ct.material.needsUpdate=!0,ln=(sn=_r).version,Sn=f.toneMapping),On.unshift(ct,ct.geometry,ct.material,0,0,null))}}}function Vp(f,E){return Math.abs(E[1])-Math.abs(f[1])}function ep(f,E,W,ge,ct,gt,St,Pt,sn,ln){Ql.call(this,f=f!==void 0?f:[],E=E!==void 0?E:ia,W,ge,ct,gt,St=St!==void 0?St:il,Pt,sn,ln),this.flipY=!1}function Df(f,E,W,ge){Ql.call(this,null),this.image={data:f||null,width:E||1,height:W||1,depth:ge||1},this.magFilter=un,this.minFilter=un,this.wrapR=Nn,this.generateMipmaps=!1,this.flipY=!1,this.needsUpdate=!0}function xd(f,E,W,ge){Ql.call(this,null),this.image={data:f||null,width:E||1,height:W||1,depth:ge||1},this.magFilter=un,this.minFilter=un,this.wrapR=Nn,this.generateMipmaps=!1,this.flipY=!1,this.needsUpdate=!0}Xd.physical={uniforms:kc([Xd.standard.uniforms,{transparency:{value:0},clearcoat:{value:0},clearcoatRoughness:{value:0},sheen:{value:new la(0)},clearcoatNormalScale:{value:new co(1,1)},clearcoatNormalMap:{value:null}}]),vertexShader:ql.meshphysical_vert,fragmentShader:ql.meshphysical_frag},((ep.prototype=Object.create(Ql.prototype)).constructor=ep).prototype.isCubeTexture=!0,Object.defineProperty(ep.prototype,"images",{get:function(){return this.image},set:function(f){this.image=f}}),((Df.prototype=Object.create(Ql.prototype)).constructor=Df).prototype.isDataTexture2DArray=!0,((xd.prototype=Object.create(Ql.prototype)).constructor=xd).prototype.isDataTexture3D=!0;var rf=new Ql,af=new Df,Yf=new xd,fp=new ep,Zf=[],pd=[],gh=new Float32Array(16),Np=new Float32Array(9),Im=new Float32Array(4);function Rh(f,E,W){var ge=f[0];if(ge<=0||0<ge)return f;var ct=E*W,gt=Zf[ct];if(gt===void 0&&(gt=new Float32Array(ct),Zf[ct]=gt),E!==0){ge.toArray(gt,0);for(var St=1,Pt=0;St!==E;++St)Pt+=W,f[St].toArray(gt,Pt)}return gt}function bd(f,E){if(f.length===E.length){for(var W=0,ge=f.length;W<ge;W++)if(f[W]!==E[W])return;return 1}}function sd(f,E){for(var W=0,ge=E.length;W<ge;W++)f[W]=E[W]}function of(f,E){var W=pd[E];W===void 0&&(W=new Int32Array(E),pd[E]=W);for(var ge=0;ge!==E;++ge)W[ge]=f.allocateTextureUnit();return W}function Rm(f,E){var W=this.cache;W[0]!==E&&(f.uniform1f(this.addr,E),W[0]=E)}function Om(f,E){var W=this.cache;if(E.x!==void 0)W[0]===E.x&&W[1]===E.y||(f.uniform2f(this.addr,E.x,E.y),W[0]=E.x,W[1]=E.y);else{if(bd(W,E))return;f.uniform2fv(this.addr,E),sd(W,E)}}function Oh(f,E){var W=this.cache;if(E.x!==void 0)W[0]===E.x&&W[1]===E.y&&W[2]===E.z||(f.uniform3f(this.addr,E.x,E.y,E.z),W[0]=E.x,W[1]=E.y,W[2]=E.z);else if(E.r!==void 0)W[0]===E.r&&W[1]===E.g&&W[2]===E.b||(f.uniform3f(this.addr,E.r,E.g,E.b),W[0]=E.r,W[1]=E.g,W[2]=E.b);else{if(bd(W,E))return;f.uniform3fv(this.addr,E),sd(W,E)}}function Ef(f,E){var W=this.cache;if(E.x!==void 0)W[0]===E.x&&W[1]===E.y&&W[2]===E.z&&W[3]===E.w||(f.uniform4f(this.addr,E.x,E.y,E.z,E.w),W[0]=E.x,W[1]=E.y,W[2]=E.z,W[3]=E.w);else{if(bd(W,E))return;f.uniform4fv(this.addr,E),sd(W,E)}}function Lh(f,E){var W=this.cache,ge=E.elements;if(ge===void 0){if(bd(W,E))return;f.uniformMatrix2fv(this.addr,!1,E),sd(W,E)}else{if(bd(W,ge))return;Im.set(ge),f.uniformMatrix2fv(this.addr,!1,Im),sd(W,ge)}}function Kf(f,E){var W=this.cache,ge=E.elements;if(ge===void 0){if(bd(W,E))return;f.uniformMatrix3fv(this.addr,!1,E),sd(W,E)}else{if(bd(W,ge))return;Np.set(ge),f.uniformMatrix3fv(this.addr,!1,Np),sd(W,ge)}}function Fd(f,E){var W=this.cache,ge=E.elements;if(ge===void 0){if(bd(W,E))return;f.uniformMatrix4fv(this.addr,!1,E),sd(W,E)}else{if(bd(W,ge))return;gh.set(ge),f.uniformMatrix4fv(this.addr,!1,gh),sd(W,ge)}}function Bd(f,E,W){var ge=this.cache,ct=W.allocateTextureUnit();ge[0]!==ct&&(f.uniform1i(this.addr,ct),ge[0]=ct),W.safeSetTexture2D(E||rf,ct)}function sf(f,E,W){var ge=this.cache,ct=W.allocateTextureUnit();ge[0]!==ct&&(f.uniform1i(this.addr,ct),ge[0]=ct),W.setTexture2DArray(E||af,ct)}function mp(f,E,W){var ge=this.cache,ct=W.allocateTextureUnit();ge[0]!==ct&&(f.uniform1i(this.addr,ct),ge[0]=ct),W.setTexture3D(E||Yf,ct)}function Xf(f,E,W){var ge=this.cache,ct=W.allocateTextureUnit();ge[0]!==ct&&(f.uniform1i(this.addr,ct),ge[0]=ct),W.safeSetTextureCube(E||fp,ct)}function Af(f,E){var W=this.cache;W[0]!==E&&(f.uniform1i(this.addr,E),W[0]=E)}function Qc(f,E){var W=this.cache;bd(W,E)||(f.uniform2iv(this.addr,E),sd(W,E))}function $c(f,E){var W=this.cache;bd(W,E)||(f.uniform3iv(this.addr,E),sd(W,E))}function Iu(f,E){var W=this.cache;bd(W,E)||(f.uniform4iv(this.addr,E),sd(W,E))}function Fh(f,E){var W=this.cache;W[0]!==E&&(f.uniform1ui(this.addr,E),W[0]=E)}function zp(f,E){f.uniform1fv(this.addr,E)}function Ee(f,E){f.uniform1iv(this.addr,E)}function w(f,E){f.uniform2iv(this.addr,E)}function se(f,E){f.uniform3iv(this.addr,E)}function it(f,E){f.uniform4iv(this.addr,E)}function xt(f,E){var W=Rh(E,this.size,2);f.uniform2fv(this.addr,W)}function Dt(f,E){var W=Rh(E,this.size,3);f.uniform3fv(this.addr,W)}function Ot(f,E){var W=Rh(E,this.size,4);f.uniform4fv(this.addr,W)}function rn(f,E){var W=Rh(E,this.size,4);f.uniformMatrix2fv(this.addr,!1,W)}function Tn(f,E){var W=Rh(E,this.size,9);f.uniformMatrix3fv(this.addr,!1,W)}function kn(f,E){var W=Rh(E,this.size,16);f.uniformMatrix4fv(this.addr,!1,W)}function Bn(f,E,W){var ge=E.length,ct=of(W,ge);f.uniform1iv(this.addr,ct);for(var gt=0;gt!==ge;++gt)W.safeSetTexture2D(E[gt]||rf,ct[gt])}function Wn(f,E,W){var ge=E.length,ct=of(W,ge);f.uniform1iv(this.addr,ct);for(var gt=0;gt!==ge;++gt)W.safeSetTextureCube(E[gt]||fp,ct[gt])}function Fr(f,E,W){this.id=f,this.addr=W,this.cache=[],this.setValue=function(ge){switch(E.type){case 5126:return Rm;case 35664:return Om;case 35665:return Oh;case 35666:return Ef;case 35674:return Lh;case 35675:return Kf;case 35676:return Fd;case 5124:case 35670:return Af;case 35667:case 35671:return Qc;case 35668:case 35672:return $c;case 35669:case 35673:return Iu;case 5125:return Fh;case 35678:case 36198:case 36298:case 36306:case 35682:return Bd;case 35679:case 36299:case 36307:return mp;case 35680:case 36300:case 36308:case 36293:return Xf;case 36289:case 36303:case 36311:case 36292:return sf}}()}function ri(f,E,W){this.id=f,this.addr=W,this.cache=[],this.size=E.size,this.setValue=function(ge){switch(E.type){case 5126:return zp;case 35664:return xt;case 35665:return Dt;case 35666:return Ot;case 35674:return rn;case 35675:return Tn;case 35676:return kn;case 5124:case 35670:return Ee;case 35667:case 35671:return w;case 35668:case 35672:return se;case 35669:case 35673:return it;case 35678:case 36198:case 36298:case 36306:case 35682:return Bn;case 35680:case 36300:case 36308:case 36293:return Wn}}()}function Zr(f){this.id=f,this.seq=[],this.map={}}ri.prototype.updateCache=function(f){var E=this.cache;f instanceof Float32Array&&E.length!==f.length&&(this.cache=new Float32Array(f.length)),sd(E,f)},Zr.prototype.setValue=function(f,E,W){for(var ge=this.seq,ct=0,gt=ge.length;ct!==gt;++ct){var St=ge[ct];St.setValue(f,E[St.id],W)}};var Sr=/([\w\d_]+)(\])?(\[|\.)?/g;function Di(f,E){f.seq.push(E),f.map[E.id]=E}function di(f,E,W){var ge=f.name,ct=ge.length;for(Sr.lastIndex=0;;){var gt=Sr.exec(ge),St=Sr.lastIndex,Pt=gt[1],sn=gt[2]==="]",ln=gt[3];if(sn&&(Pt|=0),ln===void 0||ln==="["&&St+2===ct){Di(W,new(ln===void 0?Fr:ri)(Pt,f,E));break}var Sn=W.map[Pt];Sn===void 0&&Di(W,Sn=new Zr(Pt)),W=Sn}}function wi(f,E){this.seq=[],this.map={};for(var W=f.getProgramParameter(E,35718),ge=0;ge<W;++ge){var ct=f.getActiveUniform(E,ge);di(ct,f.getUniformLocation(E,ct.name),this)}}function Ti(f,E,W){var ge=f.createShader(E);return f.shaderSource(ge,W),f.compileShader(ge),ge}wi.prototype.setValue=function(f,E,W,ge){var ct=this.map[E];ct!==void 0&&ct.setValue(f,W,ge)},wi.prototype.setOptional=function(f,E,W){var ge=E[W];ge!==void 0&&this.setValue(f,W,ge)},wi.upload=function(f,E,W,ge){for(var ct=0,gt=E.length;ct!==gt;++ct){var St=E[ct],Pt=W[St.id];Pt.needsUpdate!==!1&&St.setValue(f,Pt.value,ge)}},wi.seqWithValue=function(f,E){for(var W=[],ge=0,ct=f.length;ge!==ct;++ge){var gt=f[ge];gt.id in E&&W.push(gt)}return W};var Oi=0;function _i(f){switch(f){case qi:return["Linear","( value )"];case ga:return["sRGB","( value )"];case mo:return["RGBE","( value )"];case Uo:return["RGBM","( value, 7.0 )"];case Ns:return["RGBM","( value, 16.0 )"];case jl:return["RGBD","( value, 256.0 )"];case no:return["Gamma","( value, float( GAMMA_FACTOR ) )"];case Go:return["LogLuv","( value )"];default:throw new Error("unsupported encoding: "+f)}}function Fi(f,E,W){var ge=f.getShaderParameter(E,35713),ct=f.getShaderInfoLog(E).trim();return ge&&ct===""?"":"THREE.WebGLShader: gl.getShaderInfoLog() "+W+`
- `+ct+function(gt){for(var St=gt.split(`
- `),Pt=0;Pt<St.length;Pt++)St[Pt]=Pt+1+": "+St[Pt];return St.join(`
- `)}(f.getShaderSource(E))}function Ta(f,E){var W=_i(E);return"vec4 "+f+"( vec4 value ) { return "+W[0]+"ToLinear"+W[1]+"; }"}function Fa(f){return f!==""}function qa(f,E){return f.replace(/NUM_DIR_LIGHTS/g,E.numDirLights).replace(/NUM_SPOT_LIGHTS/g,E.numSpotLights).replace(/NUM_RECT_AREA_LIGHTS/g,E.numRectAreaLights).replace(/NUM_POINT_LIGHTS/g,E.numPointLights).replace(/NUM_HEMI_LIGHTS/g,E.numHemiLights).replace(/NUM_DIR_LIGHT_SHADOWS/g,E.numDirLightShadows).replace(/NUM_SPOT_LIGHT_SHADOWS/g,E.numSpotLightShadows).replace(/NUM_POINT_LIGHT_SHADOWS/g,E.numPointLightShadows)}function ja(f,E){return f.replace(/NUM_CLIPPING_PLANES/g,E.numClippingPlanes).replace(/UNION_CLIPPING_PLANES/g,E.numClippingPlanes-E.numClipIntersection)}var To=/^[ \t]*#include +<([\w\d./]+)>/gm;function na(f){return f.replace(To,Eo)}function Eo(f,E){var W=ql[E];if(W===void 0)throw new Error("Can not resolve #include <"+E+">");return na(W)}var So=/#pragma unroll_loop[\s]+?for \( int i \= (\d+)\; i < (\d+)\; i \+\+ \) \{([\s\S]+?)(?=\})\}/g;function Qo(f){return f.replace(So,Za)}function Za(f,E,W,ge){for(var ct="",gt=parseInt(E);gt<parseInt(W);gt++)ct+=ge.replace(/\[ i \]/g,"[ "+gt+" ]").replace(/UNROLLED_LOOP_INDEX/g,gt);return ct}function rs(f){var E="precision "+f.precision+` float;
- precision `+f.precision+" int;";return f.precision==="highp"?E+=`
- #define HIGH_PRECISION`:f.precision==="mediump"?E+=`
- #define MEDIUM_PRECISION`:f.precision==="lowp"&&(E+=`
- #define LOW_PRECISION`),E}function is(f,E,W){var ge,ct,gt,St,Pt,sn,ln,Sn=f.getContext(),En=W.defines,On=W.vertexShader,mn=W.fragmentShader,Hn=(ct="SHADOWMAP_TYPE_BASIC",(ge=W).shadowMapType===O?ct="SHADOWMAP_TYPE_PCF":ge.shadowMapType===N?ct="SHADOWMAP_TYPE_PCF_SOFT":ge.shadowMapType===L&&(ct="SHADOWMAP_TYPE_VSM"),ct),mr=function(gl){var Os="ENVMAP_TYPE_CUBE";if(gl.envMap)switch(gl.envMapMode){case ia:case Wi:Os="ENVMAP_TYPE_CUBE";break;case fi:case An:Os="ENVMAP_TYPE_CUBE_UV";break;case ha:case ai:Os="ENVMAP_TYPE_EQUIREC";break;case Ia:Os="ENVMAP_TYPE_SPHERE"}return Os}(W),_r=function(gl){var Os="ENVMAP_MODE_REFLECTION";if(gl.envMap)switch(gl.envMapMode){case Wi:case ai:Os="ENVMAP_MODE_REFRACTION"}return Os}(W),gi=function(gl){var Os="ENVMAP_BLENDING_NONE";if(gl.envMap)switch(gl.combine){case gn:Os="ENVMAP_BLENDING_MULTIPLY";break;case Xn:Os="ENVMAP_BLENDING_MIX";break;case Kn:Os="ENVMAP_BLENDING_ADD"}return Os}(W),Ci=0<f.gammaFactor?f.gammaFactor:1,$i=W.isWebGL2?"":[(gt=W).extensionDerivatives||gt.envMapCubeUV||gt.bumpMap||gt.tangentSpaceNormalMap||gt.clearcoatNormalMap||gt.flatShading||gt.shaderID==="physical"?"#extension GL_OES_standard_derivatives : enable":"",(gt.extensionFragDepth||gt.logarithmicDepthBuffer)&>.rendererExtensionFragDepth?"#extension GL_EXT_frag_depth : enable":"",gt.extensionDrawBuffers&>.rendererExtensionDrawBuffers?"#extension GL_EXT_draw_buffers : require":"",(gt.extensionShaderTextureLOD||gt.envMap)&>.rendererExtensionShaderTextureLod?"#extension GL_EXT_shader_texture_lod : enable":""].filter(Fa).join(`
- `),da=function(gl){var Os=[];for(var Ii in gl){var va=gl[Ii];va!==!1&&Os.push("#define "+Ii+" "+va)}return Os.join(`
- `)}(En),ji=Sn.createProgram(),Sa=W.numMultiviewViews;if(W.isRawShaderMaterial?(0<(St=[da].filter(Fa).join(`
- `)).length&&(St+=`
- `),0<(Pt=[$i,da].filter(Fa).join(`
- `)).length&&(Pt+=`
- `)):(St=[rs(W),"#define SHADER_NAME "+W.shaderName,da,W.instancing?"#define USE_INSTANCING":"",W.supportsVertexTextures?"#define VERTEX_TEXTURES":"","#define GAMMA_FACTOR "+Ci,"#define MAX_BONES "+W.maxBones,W.useFog&&W.fog?"#define USE_FOG":"",W.useFog&&W.fogExp2?"#define FOG_EXP2":"",W.map?"#define USE_MAP":"",W.envMap?"#define USE_ENVMAP":"",W.envMap?"#define "+_r:"",W.lightMap?"#define USE_LIGHTMAP":"",W.aoMap?"#define USE_AOMAP":"",W.emissiveMap?"#define USE_EMISSIVEMAP":"",W.bumpMap?"#define USE_BUMPMAP":"",W.normalMap?"#define USE_NORMALMAP":"",W.normalMap&&W.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",W.normalMap&&W.tangentSpaceNormalMap?"#define TANGENTSPACE_NORMALMAP":"",W.clearcoatNormalMap?"#define USE_CLEARCOAT_NORMALMAP":"",W.displacementMap&&W.supportsVertexTextures?"#define USE_DISPLACEMENTMAP":"",W.specularMap?"#define USE_SPECULARMAP":"",W.roughnessMap?"#define USE_ROUGHNESSMAP":"",W.metalnessMap?"#define USE_METALNESSMAP":"",W.alphaMap?"#define USE_ALPHAMAP":"",W.vertexTangents?"#define USE_TANGENT":"",W.vertexColors?"#define USE_COLOR":"",W.vertexUvs?"#define USE_UV":"",W.uvsVertexOnly?"#define UVS_VERTEX_ONLY":"",W.flatShading?"#define FLAT_SHADED":"",W.skinning?"#define USE_SKINNING":"",W.useVertexTexture?"#define BONE_TEXTURE":"",W.morphTargets?"#define USE_MORPHTARGETS":"",W.morphNormals&&W.flatShading===!1?"#define USE_MORPHNORMALS":"",W.doubleSided?"#define DOUBLE_SIDED":"",W.flipSided?"#define FLIP_SIDED":"",W.shadowMapEnabled?"#define USE_SHADOWMAP":"",W.shadowMapEnabled?"#define "+Hn:"",W.sizeAttenuation?"#define USE_SIZEATTENUATION":"",W.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",W.logarithmicDepthBuffer&&W.rendererExtensionFragDepth?"#define USE_LOGDEPTHBUF_EXT":"","uniform mat4 modelMatrix;","uniform mat4 modelViewMatrix;","uniform mat4 projectionMatrix;","uniform mat4 viewMatrix;","uniform mat3 normalMatrix;","uniform vec3 cameraPosition;","uniform bool isOrthographic;","#ifdef USE_INSTANCING"," attribute mat4 instanceMatrix;","#endif","attribute vec3 position;","attribute vec3 normal;","attribute vec2 uv;","#ifdef USE_TANGENT"," attribute vec4 tangent;","#endif","#ifdef USE_COLOR"," attribute vec3 color;","#endif","#ifdef USE_MORPHTARGETS"," attribute vec3 morphTarget0;"," attribute vec3 morphTarget1;"," attribute vec3 morphTarget2;"," attribute vec3 morphTarget3;"," #ifdef USE_MORPHNORMALS"," attribute vec3 morphNormal0;"," attribute vec3 morphNormal1;"," attribute vec3 morphNormal2;"," attribute vec3 morphNormal3;"," #else"," attribute vec3 morphTarget4;"," attribute vec3 morphTarget5;"," attribute vec3 morphTarget6;"," attribute vec3 morphTarget7;"," #endif","#endif","#ifdef USE_SKINNING"," attribute vec4 skinIndex;"," attribute vec4 skinWeight;","#endif",`
- `].filter(Fa).join(`
- `),Pt=[$i,rs(W),"#define SHADER_NAME "+W.shaderName,da,W.alphaTest?"#define ALPHATEST "+W.alphaTest+(W.alphaTest%1?"":".0"):"","#define GAMMA_FACTOR "+Ci,W.useFog&&W.fog?"#define USE_FOG":"",W.useFog&&W.fogExp2?"#define FOG_EXP2":"",W.map?"#define USE_MAP":"",W.matcap?"#define USE_MATCAP":"",W.envMap?"#define USE_ENVMAP":"",W.envMap?"#define "+mr:"",W.envMap?"#define "+_r:"",W.envMap?"#define "+gi:"",W.lightMap?"#define USE_LIGHTMAP":"",W.aoMap?"#define USE_AOMAP":"",W.emissiveMap?"#define USE_EMISSIVEMAP":"",W.bumpMap?"#define USE_BUMPMAP":"",W.normalMap?"#define USE_NORMALMAP":"",W.normalMap&&W.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",W.normalMap&&W.tangentSpaceNormalMap?"#define TANGENTSPACE_NORMALMAP":"",W.clearcoatNormalMap?"#define USE_CLEARCOAT_NORMALMAP":"",W.specularMap?"#define USE_SPECULARMAP":"",W.roughnessMap?"#define USE_ROUGHNESSMAP":"",W.metalnessMap?"#define USE_METALNESSMAP":"",W.alphaMap?"#define USE_ALPHAMAP":"",W.sheen?"#define USE_SHEEN":"",W.vertexTangents?"#define USE_TANGENT":"",W.vertexColors?"#define USE_COLOR":"",W.vertexUvs?"#define USE_UV":"",W.uvsVertexOnly?"#define UVS_VERTEX_ONLY":"",W.gradientMap?"#define USE_GRADIENTMAP":"",W.flatShading?"#define FLAT_SHADED":"",W.doubleSided?"#define DOUBLE_SIDED":"",W.flipSided?"#define FLIP_SIDED":"",W.shadowMapEnabled?"#define USE_SHADOWMAP":"",W.shadowMapEnabled?"#define "+Hn:"",W.premultipliedAlpha?"#define PREMULTIPLIED_ALPHA":"",W.physicallyCorrectLights?"#define PHYSICALLY_CORRECT_LIGHTS":"",W.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",W.logarithmicDepthBuffer&&W.rendererExtensionFragDepth?"#define USE_LOGDEPTHBUF_EXT":"",(W.extensionShaderTextureLOD||W.envMap)&&W.rendererExtensionShaderTextureLod?"#define TEXTURE_LOD_EXT":"","uniform mat4 viewMatrix;","uniform vec3 cameraPosition;","uniform bool isOrthographic;",W.toneMapping!==Vn?"#define TONE_MAPPING":"",W.toneMapping!==Vn?ql.tonemapping_pars_fragment:"",W.toneMapping!==Vn?function(gl,Os){var Ii;switch(Os){case Yn:Ii="Linear";break;case Vr:Ii="Reinhard";break;case xi:Ii="Uncharted2";break;case Si:Ii="OptimizedCineon";break;case qn:Ii="ACESFilmic";break;default:throw new Error("unsupported toneMapping: "+Os)}return"vec3 toneMapping( vec3 color ) { return "+Ii+"ToneMapping( color ); }"}(0,W.toneMapping):"",W.dithering?"#define DITHERING":"",W.outputEncoding||W.mapEncoding||W.matcapEncoding||W.envMapEncoding||W.emissiveMapEncoding||W.lightMapEncoding?ql.encodings_pars_fragment:"",W.mapEncoding?Ta("mapTexelToLinear",W.mapEncoding):"",W.matcapEncoding?Ta("matcapTexelToLinear",W.matcapEncoding):"",W.envMapEncoding?Ta("envMapTexelToLinear",W.envMapEncoding):"",W.emissiveMapEncoding?Ta("emissiveMapTexelToLinear",W.emissiveMapEncoding):"",W.lightMapEncoding?Ta("lightMapTexelToLinear",W.lightMapEncoding):"",W.outputEncoding?(sn=W.outputEncoding,ln=_i(sn),"vec4 linearToOutputTexel( vec4 value ) { return LinearTo"+ln[0]+ln[1]+"; }"):"",W.depthPacking?"#define DEPTH_PACKING "+W.depthPacking:"",`
- `].filter(Fa).join(`
- `)),On=ja(On=qa(On=na(On),W),W),mn=ja(mn=qa(mn=na(mn),W),W),On=Qo(On),mn=Qo(mn),W.isWebGL2&&!W.isRawShaderMaterial){var ea=!1,Ba=/^\s*#version\s+300\s+es\s*\n/;W.isShaderMaterial&&On.match(Ba)!==null&&mn.match(Ba)!==null&&(ea=!0,On=On.replace(Ba,""),mn=mn.replace(Ba,"")),St=[`#version 300 es
- `,"#define attribute in","#define varying out","#define texture2D texture"].join(`
- `)+`
- `+St,Pt=[`#version 300 es
- `,"#define varying in",ea?"":"out highp vec4 pc_fragColor;",ea?"":"#define gl_FragColor pc_fragColor","#define gl_FragDepthEXT gl_FragDepth","#define texture2D texture","#define textureCube texture","#define texture2DProj textureProj","#define texture2DLodEXT textureLod","#define texture2DProjLodEXT textureProjLod","#define textureCubeLodEXT textureLod","#define texture2DGradEXT textureGrad","#define texture2DProjGradEXT textureProjGrad","#define textureCubeGradEXT textureGrad"].join(`
- `)+`
- `+Pt,0<Sa&&(St=(St=St.replace(`#version 300 es
- `,[`#version 300 es
- `,"#extension GL_OVR_multiview2 : require","layout(num_views = "+Sa+") in;","#define VIEW_ID gl_ViewID_OVR"].join(`
- `))).replace(["uniform mat4 modelViewMatrix;","uniform mat4 projectionMatrix;","uniform mat4 viewMatrix;","uniform mat3 normalMatrix;"].join(`
- `),["uniform mat4 modelViewMatrices["+Sa+"];","uniform mat4 projectionMatrices["+Sa+"];","uniform mat4 viewMatrices["+Sa+"];","uniform mat3 normalMatrices["+Sa+"];","#define modelViewMatrix modelViewMatrices[VIEW_ID]","#define projectionMatrix projectionMatrices[VIEW_ID]","#define viewMatrix viewMatrices[VIEW_ID]","#define normalMatrix normalMatrices[VIEW_ID]"].join(`
- `)),Pt=(Pt=Pt.replace(`#version 300 es
- `,[`#version 300 es
- `,"#extension GL_OVR_multiview2 : require","#define VIEW_ID gl_ViewID_OVR"].join(`
- `))).replace("uniform mat4 viewMatrix;",["uniform mat4 viewMatrices["+Sa+"];","#define viewMatrix viewMatrices[VIEW_ID]"].join(`
- `)))}var Ya,ro,$a=Pt+mn,go=Ti(Sn,35633,St+On),ko=Ti(Sn,35632,$a);if(Sn.attachShader(ji,go),Sn.attachShader(ji,ko),W.index0AttributeName!==void 0?Sn.bindAttribLocation(ji,0,W.index0AttributeName):W.morphTargets===!0&&Sn.bindAttribLocation(ji,0,"position"),Sn.linkProgram(ji),f.debug.checkShaderErrors){var Qa=Sn.getProgramInfoLog(ji).trim(),Ha=Sn.getShaderInfoLog(go).trim(),fs=Sn.getShaderInfoLog(ko).trim(),os=!0,Ks=!0;if(Sn.getProgramParameter(ji,35714)===!1){os=!1;var Xs=Fi(Sn,go,"vertex"),zs=Fi(Sn,ko,"fragment");console.error("THREE.WebGLProgram: shader error: ",Sn.getError(),"35715",Sn.getProgramParameter(ji,35715),"gl.getProgramInfoLog",Qa,Xs,zs)}else Qa!==""?console.warn("THREE.WebGLProgram: gl.getProgramInfoLog()",Qa):Ha!==""&&fs!==""||(Ks=!1);Ks&&(this.diagnostics={runnable:os,programLog:Qa,vertexShader:{log:Ha,prefix:St},fragmentShader:{log:fs,prefix:Pt}})}return Sn.deleteShader(go),Sn.deleteShader(ko),this.getUniforms=function(){return Ya===void 0&&(Ya=new wi(Sn,ji)),Ya},this.getAttributes=function(){return ro===void 0&&(ro=function(gl,Os){for(var Ii={},va=gl.getProgramParameter(Os,35721),Bo=0;Bo<va;Bo++){var Co=gl.getActiveAttrib(Os,Bo).name;Ii[Co]=gl.getAttribLocation(Os,Co)}return Ii}(Sn,ji)),ro},this.destroy=function(){Sn.deleteProgram(ji),this.program=void 0},this.name=W.shaderName,this.id=Oi++,this.cacheKey=E,this.usedTimes=1,this.program=ji,this.vertexShader=go,this.fragmentShader=ko,this.numMultiviewViews=Sa,this}function hs(f,E,W){var ge=[],ct=W.isWebGL2,gt=W.logarithmicDepthBuffer,St=W.floatVertexTextures,Pt=W.precision,sn=W.maxVertexUniforms,ln=W.vertexTextures,Sn={MeshDepthMaterial:"depth",MeshDistanceMaterial:"distanceRGBA",MeshNormalMaterial:"normal",MeshBasicMaterial:"basic",MeshLambertMaterial:"lambert",MeshPhongMaterial:"phong",MeshToonMaterial:"toon",MeshStandardMaterial:"physical",MeshPhysicalMaterial:"physical",MeshMatcapMaterial:"matcap",LineBasicMaterial:"basic",LineDashedMaterial:"dashed",PointsMaterial:"points",ShadowMaterial:"shadow",SpriteMaterial:"sprite"},En=["precision","isWebGL2","supportsVertexTextures","outputEncoding","instancing","numMultiviewViews","map","mapEncoding","matcap","matcapEncoding","envMap","envMapMode","envMapEncoding","envMapCubeUV","lightMap","lightMapEncoding","aoMap","emissiveMap","emissiveMapEncoding","bumpMap","normalMap","objectSpaceNormalMap","tangentSpaceNormalMap","clearcoatNormalMap","displacementMap","specularMap","roughnessMap","metalnessMap","gradientMap","alphaMap","combine","vertexColors","vertexTangents","vertexUvs","uvsVertexOnly","fog","useFog","fogExp2","flatShading","sizeAttenuation","logarithmicDepthBuffer","skinning","maxBones","useVertexTexture","morphTargets","morphNormals","maxMorphTargets","maxMorphNormals","premultipliedAlpha","numDirLights","numPointLights","numSpotLights","numHemiLights","numRectAreaLights","numDirLightShadows","numPointLightShadows","numSpotLightShadows","shadowMapEnabled","shadowMapType","toneMapping","physicallyCorrectLights","alphaTest","doubleSided","flipSided","numClippingPlanes","numClipIntersection","depthPacking","dithering","sheen"];function On(mn){var Hn;return mn?mn.isTexture?Hn=mn.encoding:mn.isWebGLRenderTarget&&(console.warn("THREE.WebGLPrograms.getTextureEncodingFromMap: don't use render targets as textures. Use their .texture property instead."),Hn=mn.texture.encoding):Hn=qi,Hn}this.getParameters=function(mn,Hn,mr,_r,gi,Ci,$i){var da=_r.fog,ji=mn.isMeshStandardMaterial?_r.environment:null,Sa=mn.envMap||ji,ea=Sn[mn.type],Ba=$i.isSkinnedMesh?function(go){var ko=$i.skeleton.bones;if(St)return 1024;var Qa=sn,Ha=Math.floor((Qa-20)/4),fs=Math.min(Ha,ko.length);return fs<ko.length?(console.warn("THREE.WebGLRenderer: Skeleton has "+ko.length+" bones. This GPU supports "+fs+"."),0):fs}():0;mn.precision!==null&&(Pt=W.getMaxPrecision(mn.precision))!==mn.precision&&console.warn("THREE.WebGLProgram.getParameters:",mn.precision,"not supported, using",Pt,"instead.");var Ya=function(go,ko){var Qa;if(ea){var Ha=Xd[ea];Qa={name:go.type,uniforms:Fp.clone(Ha.uniforms),vertexShader:Ha.vertexShader,fragmentShader:Ha.fragmentShader}}else Qa={name:go.type,uniforms:go.uniforms,vertexShader:go.vertexShader,fragmentShader:go.fragmentShader};return Qa}(mn);mn.onBeforeCompile(Ya,f);var ro=f.getRenderTarget(),$a=ro&&ro.isWebGLMultiviewRenderTarget?ro.numViews:0;return{isWebGL2:ct,shaderID:ea,shaderName:Ya.name,uniforms:Ya.uniforms,vertexShader:Ya.vertexShader,fragmentShader:Ya.fragmentShader,defines:mn.defines,isRawShaderMaterial:mn.isRawShaderMaterial,isShaderMaterial:mn.isShaderMaterial,precision:Pt,instancing:$i.isInstancedMesh===!0,supportsVertexTextures:ln,numMultiviewViews:$a,outputEncoding:ro!==null?On(ro.texture):f.outputEncoding,map:!!mn.map,mapEncoding:On(mn.map),matcap:!!mn.matcap,matcapEncoding:On(mn.matcap),envMap:!!Sa,envMapMode:Sa&&Sa.mapping,envMapEncoding:On(Sa),envMapCubeUV:!!Sa&&(Sa.mapping===fi||Sa.mapping===An),lightMap:!!mn.lightMap,lightMapEncoding:On(mn.lightMap),aoMap:!!mn.aoMap,emissiveMap:!!mn.emissiveMap,emissiveMapEncoding:On(mn.emissiveMap),bumpMap:!!mn.bumpMap,normalMap:!!mn.normalMap,objectSpaceNormalMap:mn.normalMapType===Ol,tangentSpaceNormalMap:mn.normalMapType===mu,clearcoatNormalMap:!!mn.clearcoatNormalMap,displacementMap:!!mn.displacementMap,roughnessMap:!!mn.roughnessMap,metalnessMap:!!mn.metalnessMap,specularMap:!!mn.specularMap,alphaMap:!!mn.alphaMap,gradientMap:!!mn.gradientMap,sheen:!!mn.sheen,combine:mn.combine,vertexTangents:mn.normalMap&&mn.vertexTangents,vertexColors:mn.vertexColors,vertexUvs:!!(mn.map||mn.bumpMap||mn.normalMap||mn.specularMap||mn.alphaMap||mn.emissiveMap||mn.roughnessMap||mn.metalnessMap||mn.clearcoatNormalMap||mn.displacementMap),uvsVertexOnly:!(mn.map||mn.bumpMap||mn.normalMap||mn.specularMap||mn.alphaMap||mn.emissiveMap||mn.roughnessMap||mn.metalnessMap||mn.clearcoatNormalMap||!mn.displacementMap),fog:!!da,useFog:mn.fog,fogExp2:da&&da.isFogExp2,flatShading:mn.flatShading,sizeAttenuation:mn.sizeAttenuation,logarithmicDepthBuffer:gt,skinning:mn.skinning&&0<Ba,maxBones:Ba,useVertexTexture:St,morphTargets:mn.morphTargets,morphNormals:mn.morphNormals,maxMorphTargets:f.maxMorphTargets,maxMorphNormals:f.maxMorphNormals,numDirLights:Hn.directional.length,numPointLights:Hn.point.length,numSpotLights:Hn.spot.length,numRectAreaLights:Hn.rectArea.length,numHemiLights:Hn.hemi.length,numDirLightShadows:Hn.directionalShadowMap.length,numPointLightShadows:Hn.pointShadowMap.length,numSpotLightShadows:Hn.spotShadowMap.length,numClippingPlanes:gi,numClipIntersection:Ci,dithering:mn.dithering,shadowMapEnabled:f.shadowMap.enabled&&0<mr.length,shadowMapType:f.shadowMap.type,toneMapping:mn.toneMapped?f.toneMapping:Vn,physicallyCorrectLights:f.physicallyCorrectLights,premultipliedAlpha:mn.premultipliedAlpha,alphaTest:mn.alphaTest,doubleSided:mn.side===J,flipSided:mn.side===q,depthPacking:mn.depthPacking!==void 0&&mn.depthPacking,index0AttributeName:mn.index0AttributeName,extensionDerivatives:mn.extensions&&mn.extensions.derivatives,extensionFragDepth:mn.extensions&&mn.extensions.frawbuffers,extensionDrawbuffers:mn.extensions&&mn.extensions.drawbuffers,extensionShaderTextureLOD:mn.extensions&&mn.extensions.shaderTextureLOD,rendererExtensionFragDepth:ct||E.get("EXT_frag_depth")!==null,rendererExtensionDrawBuffers:ct||E.get("WEBGL_draw_buffers")!==null,rendererExtensionShaderTextureLod:ct||E.get("EXT_shader_texture_lod")!==null,onBeforeCompile:mn.onBeforeCompile}},this.getProgramCacheKey=function(mn){var Hn=[];if(mn.shaderID?Hn.push(mn.shaderID):(Hn.push(mn.fragmentShader),Hn.push(mn.vertexShader)),mn.defines!==void 0)for(var mr in mn.defines)Hn.push(mr),Hn.push(mn.defines[mr]);if(mn.isRawShaderMaterial===void 0){for(var _r=0;_r<En.length;_r++)Hn.push(mn[En[_r]]);Hn.push(f.outputEncoding),Hn.push(f.gammaFactor)}return Hn.push(mn.onBeforeCompile.toString()),Hn.join()},this.acquireProgram=function(mn,Hn){for(var mr,_r=0,gi=ge.length;_r<gi;_r++){var Ci=ge[_r];if(Ci.cacheKey===Hn){++(mr=Ci).usedTimes;break}}return mr===void 0&&(mr=new is(f,Hn,mn),ge.push(mr)),mr},this.releaseProgram=function(mn){if(--mn.usedTimes==0){var Hn=ge.indexOf(mn);ge[Hn]=ge[ge.length-1],ge.pop(),mn.destroy()}},this.programs=ge}function ps(f,E){return f.groupOrder!==E.groupOrder?f.groupOrder-E.groupOrder:f.renderOrder!==E.renderOrder?f.renderOrder-E.renderOrder:f.program!==E.program?f.program.id-E.program.id:f.material.id!==E.material.id?f.material.id-E.material.id:f.z!==E.z?f.z-E.z:f.id-E.id}function Js(f,E){return f.groupOrder!==E.groupOrder?f.groupOrder-E.groupOrder:f.renderOrder!==E.renderOrder?f.renderOrder-E.renderOrder:f.z!==E.z?E.z-f.z:f.id-E.id}function fl(){var f=[],E=0,W=[],ge=[],ct={id:-1};function gt(St,Pt,sn,ln,Sn,En){var On=f[E];return On===void 0?(On={id:St.id,object:St,geometry:Pt,material:sn,program:sn.program||ct,groupOrder:ln,renderOrder:St.renderOrder,z:Sn,group:En},f[E]=On):(On.id=St.id,On.object=St,On.geometry=Pt,On.material=sn,On.program=sn.program||ct,On.groupOrder=ln,On.renderOrder=St.renderOrder,On.z=Sn,On.group=En),E++,On}return{opaque:W,transparent:ge,init:function(){E=0,W.length=0,ge.length=0},push:function(St,Pt,sn,ln,Sn,En){var On=gt(St,Pt,sn,ln,Sn,En);(sn.transparent===!0?ge:W).push(On)},unshift:function(St,Pt,sn,ln,Sn,En){var On=gt(St,Pt,sn,ln,Sn,En);(sn.transparent===!0?ge:W).unshift(On)},sort:function(St,Pt){1<W.length&&W.sort(St||ps),1<ge.length&&ge.sort(Pt||Js)}}}var as=0;function ll(f,E){return(E.castShadow?1:0)-(f.castShadow?1:0)}function Yl(){for(var f=new function(){var St={};return{get:function(Pt){if(St[Pt.id]!==void 0)return St[Pt.id];var sn;switch(Pt.type){case"DirectionalLight":sn={direction:new yi,color:new la,shadow:!1,shadowBias:0,shadowRadius:1,shadowMapSize:new co};break;case"SpotLight":sn={position:new yi,direction:new yi,color:new la,distance:0,coneCos:0,penumbraCos:0,decay:0,shadow:!1,shadowBias:0,shadowRadius:1,shadowMapSize:new co};break;case"PointLight":sn={position:new yi,color:new la,distance:0,decay:0,shadow:!1,shadowBias:0,shadowRadius:1,shadowMapSize:new co,shadowCameraNear:1,shadowCameraFar:1e3};break;case"HemisphereLight":sn={direction:new yi,skyColor:new la,groundColor:new la};break;case"RectAreaLight":sn={color:new la,position:new yi,halfWidth:new yi,halfHeight:new yi}}return St[Pt.id]=sn}}},E={version:0,hash:{directionalLength:-1,pointLength:-1,spotLength:-1,rectAreaLength:-1,hemiLength:-1,numDirectionalShadows:-1,numPointShadows:-1,numSpotShadows:-1},ambient:[0,0,0],probe:[],directional:[],directionalShadowMap:[],directionalShadowMatrix:[],spot:[],spotShadowMap:[],spotShadowMatrix:[],rectArea:[],point:[],pointShadowMap:[],pointShadowMatrix:[],hemi:[],numDirectionalShadows:-1,numPointShadows:-1,numSpotShadows:-1},W=0;W<9;W++)E.probe.push(new yi);var ge=new yi,ct=new Vo,gt=new Vo;return{setup:function(St,Pt,sn){for(var ln=0,Sn=0,En=0,On=0;On<9;On++)E.probe[On].set(0,0,0);var mn=0,Hn=0,mr=0,_r=0,gi=0,Ci=0,$i=0,da=0,ji=sn.matrixWorldInverse;St.sort(ll),On=0;for(var Sa=St.length;On<Sa;On++){var ea=St[On],Ba=ea.color,Ya=ea.intensity,ro=ea.distance,$a=ea.shadow&&ea.shadow.map?ea.shadow.map.texture:null;if(ea.isAmbientLight)ln+=Ba.r*Ya,Sn+=Ba.g*Ya,En+=Ba.b*Ya;else if(ea.isLightProbe)for(var go=0;go<9;go++)E.probe[go].addScaledVector(ea.sh.coefficients[go],Ya);else if(ea.isDirectionalLight){if((Qa=f.get(ea)).color.copy(ea.color).multiplyScalar(ea.intensity),Qa.direction.setFromMatrixPosition(ea.matrixWorld),ge.setFromMatrixPosition(ea.target.matrixWorld),Qa.direction.sub(ge),Qa.direction.transformDirection(ji),Qa.shadow=ea.castShadow,ea.castShadow){var ko=ea.shadow;Qa.shadowBias=ko.bias,Qa.shadowRadius=ko.radius,Qa.shadowMapSize=ko.mapSize,E.directionalShadowMap[mn]=$a,E.directionalShadowMatrix[mn]=ea.shadow.matrix,Ci++}E.directional[mn]=Qa,mn++}else if(ea.isSpotLight)(Qa=f.get(ea)).position.setFromMatrixPosition(ea.matrixWorld),Qa.position.applyMatrix4(ji),Qa.color.copy(Ba).multiplyScalar(Ya),Qa.distance=ro,Qa.direction.setFromMatrixPosition(ea.matrixWorld),ge.setFromMatrixPosition(ea.target.matrixWorld),Qa.direction.sub(ge),Qa.direction.transformDirection(ji),Qa.coneCos=Math.cos(ea.angle),Qa.penumbraCos=Math.cos(ea.angle*(1-ea.penumbra)),Qa.decay=ea.decay,Qa.shadow=ea.castShadow,ea.castShadow&&(ko=ea.shadow,Qa.shadowBias=ko.bias,Qa.shadowRadius=ko.radius,Qa.shadowMapSize=ko.mapSize,E.spotShadowMap[mr]=$a,E.spotShadowMatrix[mr]=ea.shadow.matrix,da++),E.spot[mr]=Qa,mr++;else if(ea.isRectAreaLight)(Qa=f.get(ea)).color.copy(Ba).multiplyScalar(Ya),Qa.position.setFromMatrixPosition(ea.matrixWorld),Qa.position.applyMatrix4(ji),gt.identity(),ct.copy(ea.matrixWorld),ct.premultiply(ji),gt.extractRotation(ct),Qa.halfWidth.set(.5*ea.width,0,0),Qa.halfHeight.set(0,.5*ea.height,0),Qa.halfWidth.applyMatrix4(gt),Qa.halfHeight.applyMatrix4(gt),E.rectArea[_r]=Qa,_r++;else if(ea.isPointLight)(Qa=f.get(ea)).position.setFromMatrixPosition(ea.matrixWorld),Qa.position.applyMatrix4(ji),Qa.color.copy(ea.color).multiplyScalar(ea.intensity),Qa.distance=ea.distance,Qa.decay=ea.decay,Qa.shadow=ea.castShadow,ea.castShadow&&(ko=ea.shadow,Qa.shadowBias=ko.bias,Qa.shadowRadius=ko.radius,Qa.shadowMapSize=ko.mapSize,Qa.shadowCameraNear=ko.camera.near,Qa.shadowCameraFar=ko.camera.far,E.pointShadowMap[Hn]=$a,E.pointShadowMatrix[Hn]=ea.shadow.matrix,$i++),E.point[Hn]=Qa,Hn++;else if(ea.isHemisphereLight){var Qa;(Qa=f.get(ea)).direction.setFromMatrixPosition(ea.matrixWorld),Qa.direction.transformDirection(ji),Qa.direction.normalize(),Qa.skyColor.copy(ea.color).multiplyScalar(Ya),Qa.groundColor.copy(ea.groundColor).multiplyScalar(Ya),E.hemi[gi]=Qa,gi++}}E.ambient[0]=ln,E.ambient[1]=Sn,E.ambient[2]=En;var Ha=E.hash;Ha.directionalLength===mn&&Ha.pointLength===Hn&&Ha.spotLength===mr&&Ha.rectAreaLength===_r&&Ha.hemiLength===gi&&Ha.numDirectionalShadows===Ci&&Ha.numPointShadows===$i&&Ha.numSpotShadows===da||(E.directional.length=mn,E.spot.length=mr,E.rectArea.length=_r,E.point.length=Hn,E.hemi.length=gi,E.directionalShadowMap.length=Ci,E.pointShadowMap.length=$i,E.spotShadowMap.length=da,E.directionalShadowMatrix.length=Ci,E.pointShadowMatrix.length=$i,E.spotShadowMatrix.length=da,Ha.directionalLength=mn,Ha.pointLength=Hn,Ha.spotLength=mr,Ha.rectAreaLength=_r,Ha.hemiLength=gi,Ha.numDirectionalShadows=Ci,Ha.numPointShadows=$i,Ha.numSpotShadows=da,E.version=as++)},state:E}}function dc(){var f=new Yl,E=[],W=[];return{init:function(){E.length=0,W.length=0},state:{lightsArray:E,shadowsArray:W,lights:f},setupLights:function(ge){f.setup(E,W,ge)},pushLight:function(ge){E.push(ge)},pushShadow:function(ge){W.push(ge)}}}function _c(f){ii.call(this),this.type="MeshDepthMaterial",this.depthPacking=Bl,this.skinning=!1,this.morphTargets=!1,this.map=null,this.alphaMap=null,this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.fog=!1,this.setValues(f)}function Bc(f){ii.call(this),this.type="MeshDistanceMaterial",this.referencePosition=new yi,this.nearDistance=1,this.farDistance=1e3,this.skinning=!1,this.morphTargets=!1,this.map=null,this.alphaMap=null,this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.fog=!1,this.setValues(f)}((_c.prototype=Object.create(ii.prototype)).constructor=_c).prototype.isMeshDepthMaterial=!0,_c.prototype.copy=function(f){return ii.prototype.copy.call(this,f),this.depthPacking=f.depthPacking,this.skinning=f.skinning,this.morphTargets=f.morphTargets,this.map=f.map,this.alphaMap=f.alphaMap,this.displacementMap=f.displacementMap,this.displacementScale=f.displacementScale,this.displacementBias=f.displacementBias,this.wireframe=f.wireframe,this.wireframeLinewidth=f.wireframeLinewidth,this},((Bc.prototype=Object.create(ii.prototype)).constructor=Bc).prototype.isMeshDistanceMaterial=!0,Bc.prototype.copy=function(f){return ii.prototype.copy.call(this,f),this.referencePosition.copy(f.referencePosition),this.nearDistance=f.nearDistance,this.farDistance=f.farDistance,this.skinning=f.skinning,this.morphTargets=f.morphTargets,this.map=f.map,this.alphaMap=f.alphaMap,this.displacementMap=f.displacementMap,this.displacementScale=f.displacementScale,this.displacementBias=f.displacementBias,this};var Ud=`uniform sampler2D shadow_pass;
- uniform vec2 resolution;
- uniform float radius;
- #include <packing>
- void main() {
- float mean = 0.0;
- float squared_mean = 0.0;
- float depth = unpackRGBAToDepth( texture2D( shadow_pass, ( gl_FragCoord.xy ) / resolution ) );
- for ( float i = -1.0; i < 1.0 ; i += SAMPLE_RATE) {
- #ifdef HORIZONAL_PASS
- vec2 distribution = unpackRGBATo2Half( texture2D( shadow_pass, ( gl_FragCoord.xy + vec2( i, 0.0 ) * radius ) / resolution ) );
- mean += distribution.x;
- squared_mean += distribution.y * distribution.y + distribution.x * distribution.x;
- #else
- float depth = unpackRGBAToDepth( texture2D( shadow_pass, ( gl_FragCoord.xy + vec2( 0.0, i ) * radius ) / resolution ) );
- mean += depth;
- squared_mean += depth * depth;
- #endif
- }
- mean = mean * HALF_SAMPLE_RATE;
- squared_mean = squared_mean * HALF_SAMPLE_RATE;
- float std_dev = sqrt( squared_mean - mean * mean );
- gl_FragColor = pack2HalfToRGBA( vec2( mean, std_dev ) );
- }`,sh=`void main() {
- gl_Position = vec4( position, 1.0 );
- }`;function yh(f,E,W){var ge=new Ih,ct=new co,gt=new co,St=new Ll,Pt=[],sn=[],ln={},Sn={0:q,1:G,2:J},En=new Ld({defines:{SAMPLE_RATE:.25,HALF_SAMPLE_RATE:1/8},uniforms:{shadow_pass:{value:null},resolution:{value:new co},radius:{value:4}},vertexShader:sh,fragmentShader:Ud}),On=En.clone();On.defines.HORIZONAL_PASS=1;var mn=new Ds;mn.setAttribute("position",new ca(new Float32Array([-1,-1,.5,3,-1,.5,-1,3,.5]),3));var Hn=new lu(mn,En),mr=this;function _r(ji,Sa){var ea=E.update(Hn);En.uniforms.shadow_pass.value=ji.map.texture,En.uniforms.resolution.value=ji.mapSize,En.uniforms.radius.value=ji.radius,f.setRenderTarget(ji.mapPass),f.clear(),f.renderBufferDirect(Sa,null,ea,En,Hn,null),On.uniforms.shadow_pass.value=ji.mapPass.texture,On.uniforms.resolution.value=ji.mapSize,On.uniforms.radius.value=ji.radius,f.setRenderTarget(ji.map),f.clear(),f.renderBufferDirect(Sa,null,ea,On,Hn,null)}function gi(ji,Sa,ea){var Ba=ji<<0|Sa<<1|ea<<2,Ya=Pt[Ba];return Ya===void 0&&(Ya=new _c({depthPacking:Jl,morphTargets:ji,skinning:Sa}),Pt[Ba]=Ya),Ya}function Ci(ji,Sa,ea){var Ba=ji<<0|Sa<<1|ea<<2,Ya=sn[Ba];return Ya===void 0&&(Ya=new Bc({morphTargets:ji,skinning:Sa}),sn[Ba]=Ya),Ya}function $i(ji,Sa,ea,Ba,Ya,ro){var $a=ji.geometry,go=null,ko=gi,Qa=ji.customDepthMaterial;if(ea.isPointLight===!0&&(ko=Ci,Qa=ji.customDistanceMaterial),Qa===void 0){var Ha=!1;Sa.morphTargets===!0&&($a.isBufferGeometry===!0?Ha=$a.morphAttributes&&$a.morphAttributes.position&&0<$a.morphAttributes.position.length:$a.isGeometry===!0&&(Ha=$a.morphTargets&&0<$a.morphTargets.length));var fs=!1;ji.isSkinnedMesh===!0&&(Sa.skinning===!0?fs=!0:console.warn("THREE.WebGLShadowMap: THREE.SkinnedMesh with material.skinning set to false:",ji)),go=ko(Ha,fs,ji.isInstancedMesh===!0)}else go=Qa;if(f.localClippingEnabled&&Sa.clipShadows===!0&&Sa.clippingPlanes.length!==0){var os=go.uuid,Ks=Sa.uuid,Xs=ln[os];Xs===void 0&&(Xs={},ln[os]=Xs);var zs=Xs[Ks];zs===void 0&&(zs=go.clone(),Xs[Ks]=zs),go=zs}return go.visible=Sa.visible,go.wireframe=Sa.wireframe,go.side=ro===L?Sa.shadowSide!==null?Sa.shadowSide:Sa.side:Sa.shadowSide!==null?Sa.shadowSide:Sn[Sa.side],go.clipShadows=Sa.clipShadows,go.clippingPlanes=Sa.clippingPlanes,go.clipIntersection=Sa.clipIntersection,go.wireframeLinewidth=Sa.wireframeLinewidth,go.linewidth=Sa.linewidth,ea.isPointLight===!0&&go.isMeshDistanceMaterial===!0&&(go.referencePosition.setFromMatrixPosition(ea.matrixWorld),go.nearDistance=Ba,go.farDistance=Ya),go}function da(ji,Sa,ea,Ba,Ya){if(ji.visible!==!1){if(ji.layers.test(Sa.layers)&&(ji.isMesh||ji.isLine||ji.isPoints)&&(ji.castShadow||ji.receiveShadow&&Ya===L)&&(!ji.frustumCulled||ge.intersectsObject(ji))){ji.modelViewMatrix.multiplyMatrices(ea.matrixWorldInverse,ji.matrixWorld);var ro=E.update(ji),$a=ji.material;if(Array.isArray($a))for(var go=ro.groups,ko=0,Qa=go.length;ko<Qa;ko++){var Ha=go[ko],fs=$a[Ha.materialIndex];if(fs&&fs.visible){var os=$i(ji,fs,Ba,ea.near,ea.far,Ya);f.renderBufferDirect(ea,null,ro,os,ji,Ha)}}else $a.visible&&(os=$i(ji,$a,Ba,ea.near,ea.far,Ya),f.renderBufferDirect(ea,null,ro,os,ji,null))}for(var Ks=ji.children,Xs=0,zs=Ks.length;Xs<zs;Xs++)da(Ks[Xs],Sa,ea,Ba,Ya)}}this.enabled=!1,this.autoUpdate=!0,this.needsUpdate=!1,this.type=O,this.render=function(ji,Sa,ea){if(mr.enabled!==!1&&(mr.autoUpdate!==!1||mr.needsUpdate!==!1)&&ji.length!==0){var Ba=f.getRenderTarget(),Ya=f.getActiveCubeFace(),ro=f.getActiveMipmapLevel(),$a=f.state;$a.setBlending(ve),$a.buffers.color.setClear(1,1,1,1),$a.buffers.depth.setTest(!0),$a.setScissorTest(!1);for(var go=0,ko=ji.length;go<ko;go++){var Qa=ji[go],Ha=Qa.shadow;if(Ha!==void 0){ct.copy(Ha.mapSize);var fs=Ha.getFrameExtents();if(ct.multiply(fs),gt.copy(Ha.mapSize),(ct.x>W||ct.y>W)&&(console.warn("THREE.WebGLShadowMap:",Qa,"has shadow exceeding max texture size, reducing"),ct.x>W&&(gt.x=Math.floor(W/fs.x),ct.x=gt.x*fs.x,Ha.mapSize.x=gt.x),ct.y>W&&(gt.y=Math.floor(W/fs.y),ct.y=gt.y*fs.y,Ha.mapSize.y=gt.y)),Ha.map===null&&!Ha.isPointLightShadow&&this.type===L){var os={minFilter:hi,magFilter:hi,format:zr};Ha.map=new Au(ct.x,ct.y,os),Ha.map.texture.name=Qa.name+".shadowMap",Ha.mapPass=new Au(ct.x,ct.y,os),Ha.camera.updateProjectionMatrix()}Ha.map===null&&(os={minFilter:un,magFilter:un,format:zr},Ha.map=new Au(ct.x,ct.y,os),Ha.map.texture.name=Qa.name+".shadowMap",Ha.camera.updateProjectionMatrix()),f.setRenderTarget(Ha.map),f.clear();for(var Ks=Ha.getViewportCount(),Xs=0;Xs<Ks;Xs++){var zs=Ha.getViewport(Xs);St.set(gt.x*zs.x,gt.y*zs.y,gt.x*zs.z,gt.y*zs.w),$a.viewport(St),Ha.updateMatrices(Qa,Xs),ge=Ha.getFrustum(),da(Sa,ea,Ha.camera,Qa,this.type)}Ha.isPointLightShadow||this.type!==L||_r(Ha,ea)}else console.warn("THREE.WebGLShadowMap:",Qa,"has no shadow.")}mr.needsUpdate=!1,f.setRenderTarget(Ba,Ya,ro)}}}function Bh(f,E,W){var ge=W.isWebGL2,ct=new function(){var Pa=!1,Rs=new Ll,Ls=null,ml=new Ll(0,0,0,0);return{setMask:function(ns){Ls===ns||Pa||(f.colorMask(ns,ns,ns,ns),Ls=ns)},setLocked:function(ns){Pa=ns},setClear:function(ns,Rl,ou,Hu,rh){rh===!0&&(ns*=Hu,Rl*=Hu,ou*=Hu),Rs.set(ns,Rl,ou,Hu),ml.equals(Rs)===!1&&(f.clearColor(ns,Rl,ou,Hu),ml.copy(Rs))},reset:function(){Pa=!1,Ls=null,ml.set(-1,0,0,0)}}},gt=new function(){var Pa=!1,Rs=null,Ls=null,ml=null;return{setTest:function(ns){(ns?Os:Ii)(2929)},setMask:function(ns){Rs===ns||Pa||(f.depthMask(ns),Rs=ns)},setFunc:function(ns){if(Ls!==ns){if(ns)switch(ns){case Rn:f.depthFunc(512);break;case Lt:f.depthFunc(519);break;case wn:f.depthFunc(513);break;case hn:f.depthFunc(515);break;case xn:f.depthFunc(514);break;case $n:f.depthFunc(518);break;case Xr:f.depthFunc(516);break;case ti:f.depthFunc(517);break;default:f.depthFunc(515)}else f.depthFunc(515);Ls=ns}},setLocked:function(ns){Pa=ns},setClear:function(ns){ml!==ns&&(f.clearDepth(ns),ml=ns)},reset:function(){Pa=!1,ml=Ls=Rs=null}}},St=new function(){var Pa=!1,Rs=null,Ls=null,ml=null,ns=null,Rl=null,ou=null,Hu=null,rh=null;return{setTest:function(uu){Pa||(uu?Os:Ii)(2960)},setMask:function(uu){Rs===uu||Pa||(f.stencilMask(uu),Rs=uu)},setFunc:function(uu,Ou,nu){Ls===uu&&ml===Ou&&ns===nu||(f.stencilFunc(uu,Ou,nu),Ls=uu,ml=Ou,ns=nu)},setOp:function(uu,Ou,nu){Rl===uu&&ou===Ou&&Hu===nu||(f.stencilOp(uu,Ou,nu),Rl=uu,ou=Ou,Hu=nu)},setLocked:function(uu){Pa=uu},setClear:function(uu){rh!==uu&&(f.clearStencil(uu),rh=uu)},reset:function(){Pa=!1,rh=Hu=ou=Rl=ns=ml=Ls=Rs=null}}},Pt=f.getParameter(34921),sn=new Uint8Array(Pt),ln=new Uint8Array(Pt),Sn=new Uint8Array(Pt),En={},On=null,mn=null,Hn=null,mr=null,_r=null,gi=null,Ci=null,$i=null,da=null,ji=!1,Sa=null,ea=null,Ba=null,Ya=null,ro=null,$a=f.getParameter(35661),go=!1,ko=0,Qa=f.getParameter(7938);Qa.indexOf("WebGL")!==-1?(ko=parseFloat(/^WebGL\ ([0-9])/.exec(Qa)[1]),go=1<=ko):Qa.indexOf("OpenGL ES")!==-1&&(ko=parseFloat(/^OpenGL\ ES\ ([0-9])/.exec(Qa)[1]),go=2<=ko);var Ha=null,fs={},os=new Ll,Ks=new Ll;function Xs(Pa,Rs,Ls){var ml=new Uint8Array(4),ns=f.createTexture();f.bindTexture(Pa,ns),f.texParameteri(Pa,10241,9728),f.texParameteri(Pa,10240,9728);for(var Rl=0;Rl<Ls;Rl++)f.texImage2D(Rs+Rl,0,6408,1,1,0,6408,5121,ml);return ns}var zs={};function gl(Pa,Rs){sn[Pa]=1,ln[Pa]===0&&(f.enableVertexAttribArray(Pa),ln[Pa]=1),Sn[Pa]!==Rs&&((ge?f:E.get("ANGLE_instanced_arrays"))[ge?"vertexAttribDivisor":"vertexAttribDivisorANGLE"](Pa,Rs),Sn[Pa]=Rs)}function Os(Pa){En[Pa]!==!0&&(f.enable(Pa),En[Pa]=!0)}function Ii(Pa){En[Pa]!==!1&&(f.disable(Pa),En[Pa]=!1)}zs[3553]=Xs(3553,3553,1),zs[34067]=Xs(34067,34069,6),ct.setClear(0,0,0,1),gt.setClear(1),St.setClear(0),Os(2929),gt.setFunc(hn),Us(!1),eo(b),Os(2884),Cl(ve);var va={};if(va[Ae]=32774,va[Te]=32778,va[Xe]=32779,ge)va[ie]=32775,va[ue]=32776;else{var Bo=E.get("EXT_blend_minmax");Bo!==null&&(va[ie]=Bo.MIN_EXT,va[ue]=Bo.MAX_EXT)}var Co={};function Cl(Pa,Rs,Ls,ml,ns,Rl,ou,Hu){if(Pa!==ve){if(mn||(Os(3042),mn=!0),Pa===rt)ns=ns||Rs,Rl=Rl||Ls,ou=ou||ml,Rs===mr&&ns===Ci||(f.blendEquationSeparate(va[Rs],va[ns]),mr=Rs,Ci=ns),Ls===_r&&ml===gi&&Rl===$i&&ou===da||(f.blendFuncSeparate(Co[Ls],Co[ml],Co[Rl],Co[ou]),_r=Ls,gi=ml,$i=Rl,da=ou),Hn=Pa,ji=null;else if(Pa!==Hn||Hu!==ji){if(mr===Ae&&Ci===Ae||(f.blendEquation(32774),Ci=mr=Ae),Hu)switch(Pa){case ne:f.blendFuncSeparate(1,771,1,771);break;case Ue:f.blendFunc(1,1);break;case De:f.blendFuncSeparate(0,0,769,771);break;case Ve:f.blendFuncSeparate(0,768,0,770);break;default:console.error("THREE.WebGLState: Invalid blending: ",Pa)}else switch(Pa){case ne:f.blendFuncSeparate(770,771,1,771);break;case Ue:f.blendFunc(770,1);break;case De:f.blendFunc(0,769);break;case Ve:f.blendFunc(0,768);break;default:console.error("THREE.WebGLState: Invalid blending: ",Pa)}da=$i=gi=_r=null,Hn=Pa,ji=Hu}}else mn&&(Ii(3042),mn=!1)}function Us(Pa){Sa!==Pa&&(Pa?f.frontFace(2304):f.frontFace(2305),Sa=Pa)}function eo(Pa){Pa!==y?(Os(2884),Pa!==ea&&(Pa===b?f.cullFace(1029):Pa===m?f.cullFace(1028):f.cullFace(1032))):Ii(2884),ea=Pa}function Hs(Pa,Rs,Ls){Pa?(Os(32823),Ya===Rs&&ro===Ls||(f.polygonOffset(Rs,Ls),Ya=Rs,ro=Ls)):Ii(32823)}function Dl(Pa){Pa===void 0&&(Pa=33984+$a-1),Ha!==Pa&&(f.activeTexture(Pa),Ha=Pa)}return Co[pt]=0,Co[mt]=1,Co[Tt]=768,Co[It]=770,Co[an]=776,Co[_n]=774,Co[tn]=772,Co[kt]=769,Co[nn]=771,Co[Dn]=775,Co[pn]=773,{buffers:{color:ct,depth:gt,stencil:St},initAttributes:function(){for(var Pa=0,Rs=sn.length;Pa<Rs;Pa++)sn[Pa]=0},enableAttribute:function(Pa){gl(Pa,0)},enableAttributeAndDivisor:gl,disableUnusedAttributes:function(){for(var Pa=0,Rs=ln.length;Pa!==Rs;++Pa)ln[Pa]!==sn[Pa]&&(f.disableVertexAttribArray(Pa),ln[Pa]=0)},enable:Os,disable:Ii,useProgram:function(Pa){return On!==Pa&&(f.useProgram(Pa),On=Pa,!0)},setBlending:Cl,setMaterial:function(Pa,Rs){(Pa.side===J?Ii:Os)(2884);var Ls=Pa.side===q;Rs&&(Ls=!Ls),Us(Ls),Pa.blending===ne&&Pa.transparent===!1?Cl(ve):Cl(Pa.blending,Pa.blendEquation,Pa.blendSrc,Pa.blendDst,Pa.blendEquationAlpha,Pa.blendSrcAlpha,Pa.blendDstAlpha,Pa.premultipliedAlpha),gt.setFunc(Pa.depthFunc),gt.setTest(Pa.depthTest),gt.setMask(Pa.depthWrite),ct.setMask(Pa.colorWrite);var ml=Pa.stencilWrite;St.setTest(ml),ml&&(St.setMask(Pa.stencilWriteMask),St.setFunc(Pa.stencilFunc,Pa.stencilRef,Pa.stencilFuncMask),St.setOp(Pa.stencilFail,Pa.stencilZFail,Pa.stencilZPass)),Hs(Pa.polygonOffset,Pa.polygonOffsetFactor,Pa.polygonOffsetUnits)},setFlipSided:Us,setCullFace:eo,setLineWidth:function(Pa){Pa!==Ba&&(go&&f.lineWidth(Pa),Ba=Pa)},setPolygonOffset:Hs,setScissorTest:function(Pa){(Pa?Os:Ii)(3089)},activeTexture:Dl,bindTexture:function(Pa,Rs){Ha===null&&Dl();var Ls=fs[Ha];Ls===void 0&&(Ls={type:void 0,texture:void 0},fs[Ha]=Ls),Ls.type===Pa&&Ls.texture===Rs||(f.bindTexture(Pa,Rs||zs[Pa]),Ls.type=Pa,Ls.texture=Rs)},unbindTexture:function(){var Pa=fs[Ha];Pa!==void 0&&Pa.type!==void 0&&(f.bindTexture(Pa.type,null),Pa.type=void 0,Pa.texture=void 0)},compressedTexImage2D:function(){try{f.compressedTexImage2D.apply(f,arguments)}catch(Pa){console.error("THREE.WebGLState:",Pa)}},texImage2D:function(){try{f.texImage2D.apply(f,arguments)}catch(Pa){console.error("THREE.WebGLState:",Pa)}},texImage3D:function(){try{f.texImage3D.apply(f,arguments)}catch(Pa){console.error("THREE.WebGLState:",Pa)}},scissor:function(Pa){os.equals(Pa)===!1&&(f.scissor(Pa.x,Pa.y,Pa.z,Pa.w),os.copy(Pa))},viewport:function(Pa){Ks.equals(Pa)===!1&&(f.viewport(Pa.x,Pa.y,Pa.z,Pa.w),Ks.copy(Pa))},reset:function(){for(var Pa=0;Pa<ln.length;Pa++)ln[Pa]===1&&(f.disableVertexAttribArray(Pa),ln[Pa]=0);En={},fs={},ea=Sa=Hn=On=Ha=null,ct.reset(),gt.reset(),St.reset()}}}function Vh(f,E,W,ge,ct,gt,St){var Pt,sn=ct.isWebGL2,ln=ct.maxTextures,Sn=ct.maxCubemapSize,En=ct.maxTextureSize,On=ct.maxSamples,mn=new WeakMap,Hn=!1;try{Hn=typeof OffscreenCanvas<"u"&&new OffscreenCanvas(1,1).getContext("2d")!==null}catch{}function mr(Ii,va){return Hn?new OffscreenCanvas(Ii,va):document.createElementNS("http://www.w3.org/1999/xhtml","canvas")}function _r(Ii,va,Bo,Co){var Cl=1;if((Ii.width>Co||Ii.height>Co)&&(Cl=Co/Math.max(Ii.width,Ii.height)),Cl<1||va===!0){if(typeof HTMLImageElement<"u"&&Ii instanceof HTMLImageElement||typeof HTMLCanvasElement<"u"&&Ii instanceof HTMLCanvasElement||typeof ImageBitmap<"u"&&Ii instanceof ImageBitmap){var Us=va?js.floorPowerOfTwo:Math.floor,eo=Us(Cl*Ii.width),Hs=Us(Cl*Ii.height);Pt===void 0&&(Pt=mr(eo,Hs));var Dl=Bo?mr(eo,Hs):Pt;return Dl.width=eo,Dl.height=Hs,Dl.getContext("2d").drawImage(Ii,0,0,eo,Hs),console.warn("THREE.WebGLRenderer: Texture has been resized from ("+Ii.width+"x"+Ii.height+") to ("+eo+"x"+Hs+")."),Dl}return"data"in Ii&&console.warn("THREE.WebGLRenderer: Image in DataTexture is too big ("+Ii.width+"x"+Ii.height+")."),Ii}return Ii}function gi(Ii){return js.isPowerOfTwo(Ii.width)&&js.isPowerOfTwo(Ii.height)}function Ci(Ii,va){return Ii.generateMipmaps&&va&&Ii.minFilter!==un&&Ii.minFilter!==hi}function $i(Ii,va,Bo,Co){f.generateMipmap(Ii),ge.get(va).__maxMipLevel=Math.log(Math.max(Bo,Co))*Math.LOG2E}function da(Ii,va,Bo){if(sn===!1)return va;if(Ii!==null){if(f[Ii]!==void 0)return f[Ii];console.warn("THREE.WebGLRenderer: Attempt to use non-existing WebGL internal format '"+Ii+"'")}var Co=va;return va===6403&&(Bo===5126&&(Co=33326),Bo===5131&&(Co=33325),Bo===5121&&(Co=33321)),va===6407&&(Bo===5126&&(Co=34837),Bo===5131&&(Co=34843),Bo===5121&&(Co=32849)),va===6408&&(Bo===5126&&(Co=34836),Bo===5131&&(Co=34842),Bo===5121&&(Co=32856)),Co===33325||Co===33326||Co===34842||Co===34836?E.get("EXT_color_buffer_float"):Co!==34843&&Co!==34837||console.warn("THREE.WebGLRenderer: Floating point textures with RGB format not supported. Please use RGBA instead."),Co}function ji(Ii){return Ii===un||Ii===Ln||Ii===hr?9728:9729}function Sa(Ii){var va=Ii.target;va.removeEventListener("dispose",Sa),function(Bo){var Co=ge.get(Bo);Co.__webglInit!==void 0&&(f.deleteTexture(Co.__webglTexture),ge.remove(Bo))}(va),va.isVideoTexture&&mn.delete(va),St.memory.textures--}function ea(Ii){var va=Ii.target;va.removeEventListener("dispose",ea),function(Bo){var Co=ge.get(Bo),Cl=ge.get(Bo.texture);if(Bo){if(Cl.__webglTexture!==void 0&&f.deleteTexture(Cl.__webglTexture),Bo.depthTexture&&Bo.depthTexture.dispose(),Bo.isWebGLCubeRenderTarget)for(var Us=0;Us<6;Us++)f.deleteFramebuffer(Co.__webglFramebuffer[Us]),Co.__webglDepthbuffer&&f.deleteRenderbuffer(Co.__webglDepthbuffer[Us]);else f.deleteFramebuffer(Co.__webglFramebuffer),Co.__webglDepthbuffer&&f.deleteRenderbuffer(Co.__webglDepthbuffer);if(Bo.isWebGLMultiviewRenderTarget){f.deleteTexture(Co.__webglColorTexture),f.deleteTexture(Co.__webglDepthStencilTexture),St.memory.textures-=2,Us=0;for(var eo=Co.__webglViewFramebuffers.length;Us<eo;Us++)f.deleteFramebuffer(Co.__webglViewFramebuffers[Us])}ge.remove(Bo.texture),ge.remove(Bo)}}(va),St.memory.textures--}var Ba=0;function Ya(Ii,va){var Bo,Co,Cl=ge.get(Ii);if(Ii.isVideoTexture&&(Bo=Ii,Co=St.render.frame,mn.get(Bo)!==Co&&(mn.set(Bo,Co),Bo.update())),0<Ii.version&&Cl.__version!==Ii.version){var Us=Ii.image;if(Us===void 0)console.warn("THREE.WebGLRenderer: Texture marked for update but image is undefined");else{if(Us.complete!==!1)return void fs(Cl,Ii,va);console.warn("THREE.WebGLRenderer: Texture marked for update but image is incomplete")}}W.activeTexture(33984+va),W.bindTexture(3553,Cl.__webglTexture)}function ro(Ii,va){if(Ii.image.length===6){var Bo=ge.get(Ii);if(0<Ii.version&&Bo.__version!==Ii.version){Ha(Bo,Ii),W.activeTexture(33984+va),W.bindTexture(34067,Bo.__webglTexture),f.pixelStorei(37440,Ii.flipY);for(var Co=Ii&&(Ii.isCompressedTexture||Ii.image[0].isCompressedTexture),Cl=Ii.image[0]&&Ii.image[0].isDataTexture,Us=[],eo=0;eo<6;eo++)Us[eo]=Co||Cl?Cl?Ii.image[eo].image:Ii.image[eo]:_r(Ii.image[eo],!1,!0,Sn);var Hs,Dl=Us[0],Pa=gi(Dl)||sn,Rs=gt.convert(Ii.format),Ls=gt.convert(Ii.type),ml=da(Ii.internalFormat,Rs,Ls);if(Qa(34067,Ii,Pa),Co){for(eo=0;eo<6;eo++){Hs=Us[eo].mipmaps;for(var ns=0;ns<Hs.length;ns++){var Rl=Hs[ns];Ii.format!==zr&&Ii.format!==il?Rs!==null?W.compressedTexImage2D(34069+eo,ns,ml,Rl.width,Rl.height,0,Rl.data):console.warn("THREE.WebGLRenderer: Attempt to load unsupported compressed texture format in .setTextureCube()"):W.texImage2D(34069+eo,ns,ml,Rl.width,Rl.height,0,Rs,Ls,Rl.data)}}Bo.__maxMipLevel=Hs.length-1}else{for(Hs=Ii.mipmaps,eo=0;eo<6;eo++)if(Cl)for(W.texImage2D(34069+eo,0,ml,Us[eo].width,Us[eo].height,0,Rs,Ls,Us[eo].data),ns=0;ns<Hs.length;ns++){var ou=(Rl=Hs[ns]).image[eo].image;W.texImage2D(34069+eo,ns+1,ml,ou.width,ou.height,0,Rs,Ls,ou.data)}else for(W.texImage2D(34069+eo,0,ml,Rs,Ls,Us[eo]),ns=0;ns<Hs.length;ns++)Rl=Hs[ns],W.texImage2D(34069+eo,ns+1,ml,Rs,Ls,Rl.image[eo]);Bo.__maxMipLevel=Hs.length}Ci(Ii,Pa)&&$i(34067,Ii,Dl.width,Dl.height),Bo.__version=Ii.version,Ii.onUpdate&&Ii.onUpdate(Ii)}else W.activeTexture(33984+va),W.bindTexture(34067,Bo.__webglTexture)}}function $a(Ii,va){W.activeTexture(33984+va),W.bindTexture(34067,ge.get(Ii).__webglTexture)}var go={};go[sa]=10497,go[Nn]=33071,go[fn]=33648;var ko={};function Qa(Ii,va,Bo){Bo?(f.texParameteri(Ii,10242,go[va.wrapS]),f.texParameteri(Ii,10243,go[va.wrapT]),Ii!==32879&&Ii!==35866||f.texParameteri(Ii,32882,go[va.wrapR]),f.texParameteri(Ii,10240,ko[va.magFilter]),f.texParameteri(Ii,10241,ko[va.minFilter])):(f.texParameteri(Ii,10242,33071),f.texParameteri(Ii,10243,33071),Ii!==32879&&Ii!==35866||f.texParameteri(Ii,32882,33071),va.wrapS===Nn&&va.wrapT===Nn||console.warn("THREE.WebGLRenderer: Texture is not power of two. Texture.wrapS and Texture.wrapT should be set to THREE.ClampToEdgeWrapping."),f.texParameteri(Ii,10240,ji(va.magFilter)),f.texParameteri(Ii,10241,ji(va.minFilter)),va.minFilter!==un&&va.minFilter!==hi&&console.warn("THREE.WebGLRenderer: Texture is not power of two. Texture.minFilter should be set to THREE.NearestFilter or THREE.LinearFilter."));var Co=E.get("EXT_texture_filter_anisotropic");if(Co){if(va.type===Aa&&E.get("OES_texture_float_linear")===null||va.type===Ja&&(sn||E.get("OES_texture_half_float_linear"))===null)return;(1<va.anisotropy||ge.get(va).__currentAnisotropy)&&(f.texParameterf(Ii,Co.TEXTURE_MAX_ANISOTROPY_EXT,Math.min(va.anisotropy,ct.getMaxAnisotropy())),ge.get(va).__currentAnisotropy=va.anisotropy)}}function Ha(Ii,va){Ii.__webglInit===void 0&&(Ii.__webglInit=!0,va.addEventListener("dispose",Sa),Ii.__webglTexture=f.createTexture(),St.memory.textures++)}function fs(Ii,va,Bo){var Co=3553;va.isDataTexture2DArray&&(Co=35866),va.isDataTexture3D&&(Co=32879),Ha(Ii,va),W.activeTexture(33984+Bo),W.bindTexture(Co,Ii.__webglTexture),f.pixelStorei(37440,va.flipY),f.pixelStorei(37441,va.premultiplyAlpha),f.pixelStorei(3317,va.unpackAlignment);var Cl,Us=(Cl=va,!sn&&(Cl.wrapS!==Nn||Cl.wrapT!==Nn||Cl.minFilter!==un&&Cl.minFilter!==hi)&&gi(va.image)===!1),eo=_r(va.image,Us,!1,En),Hs=gi(eo)||sn,Dl=gt.convert(va.format),Pa=gt.convert(va.type),Rs=da(va.internalFormat,Dl,Pa);Qa(Co,va,Hs);var Ls,ml=va.mipmaps;if(va.isDepthTexture){if(Rs=6402,va.type===Aa){if(sn===!1)throw new Error("Float Depth Texture only supported in WebGL2.0");Rs=36012}else sn&&(Rs=33189);va.format===ni&&Rs===6402&&va.type!==Ni&&va.type!==ki&&(console.warn("THREE.WebGLRenderer: Use UnsignedShortType or UnsignedIntType for DepthFormat DepthTexture."),va.type=Ni,Pa=gt.convert(va.type)),va.format===Ei&&(Rs=34041,va.type!==_o&&(console.warn("THREE.WebGLRenderer: Use UnsignedInt248Type for DepthStencilFormat DepthTexture."),va.type=_o,Pa=gt.convert(va.type))),W.texImage2D(3553,0,Rs,eo.width,eo.height,0,Dl,Pa,null)}else if(va.isDataTexture)if(0<ml.length&&Hs){for(var ns=0,Rl=ml.length;ns<Rl;ns++)Ls=ml[ns],W.texImage2D(3553,ns,Rs,Ls.width,Ls.height,0,Dl,Pa,Ls.data);va.generateMipmaps=!1,Ii.__maxMipLevel=ml.length-1}else W.texImage2D(3553,0,Rs,eo.width,eo.height,0,Dl,Pa,eo.data),Ii.__maxMipLevel=0;else if(va.isCompressedTexture){for(ns=0,Rl=ml.length;ns<Rl;ns++)Ls=ml[ns],va.format!==zr&&va.format!==il?Dl!==null?W.compressedTexImage2D(3553,ns,Rs,Ls.width,Ls.height,0,Ls.data):console.warn("THREE.WebGLRenderer: Attempt to load unsupported compressed texture format in .uploadTexture()"):W.texImage2D(3553,ns,Rs,Ls.width,Ls.height,0,Dl,Pa,Ls.data);Ii.__maxMipLevel=ml.length-1}else if(va.isDataTexture2DArray)W.texImage3D(35866,0,Rs,eo.width,eo.height,eo.depth,0,Dl,Pa,eo.data),Ii.__maxMipLevel=0;else if(va.isDataTexture3D)W.texImage3D(32879,0,Rs,eo.width,eo.height,eo.depth,0,Dl,Pa,eo.data),Ii.__maxMipLevel=0;else if(0<ml.length&&Hs){for(ns=0,Rl=ml.length;ns<Rl;ns++)Ls=ml[ns],W.texImage2D(3553,ns,Rs,Dl,Pa,Ls);va.generateMipmaps=!1,Ii.__maxMipLevel=ml.length-1}else W.texImage2D(3553,0,Rs,Dl,Pa,eo),Ii.__maxMipLevel=0;Ci(va,Hs)&&$i(Co,va,eo.width,eo.height),Ii.__version=va.version,va.onUpdate&&va.onUpdate(va)}function os(Ii,va,Bo,Co){var Cl=gt.convert(va.texture.format),Us=gt.convert(va.texture.type),eo=da(va.texture.internalFormat,Cl,Us);W.texImage2D(Co,0,eo,va.width,va.height,0,Cl,Us,null),f.bindFramebuffer(36160,Ii),f.framebufferTexture2D(36160,Bo,Co,ge.get(va.texture).__webglTexture,0),f.bindFramebuffer(36160,null)}function Ks(Ii,va,Bo){if(f.bindRenderbuffer(36161,Ii),va.depthBuffer&&!va.stencilBuffer){if(Bo){var Co=zs(va);f.renderbufferStorageMultisample(36161,Co,33189,va.width,va.height)}else f.renderbufferStorage(36161,33189,va.width,va.height);f.framebufferRenderbuffer(36160,36096,36161,Ii)}else if(va.depthBuffer&&va.stencilBuffer)Bo?(Co=zs(va),f.renderbufferStorageMultisample(36161,Co,35056,va.width,va.height)):f.renderbufferStorage(36161,34041,va.width,va.height),f.framebufferRenderbuffer(36160,33306,36161,Ii);else{var Cl=gt.convert(va.texture.format),Us=gt.convert(va.texture.type),eo=da(va.texture.internalFormat,Cl,Us);Bo?(Co=zs(va),f.renderbufferStorageMultisample(36161,Co,eo,va.width,va.height)):f.renderbufferStorage(36161,eo,va.width,va.height)}f.bindRenderbuffer(36161,null)}function Xs(Ii){var va=ge.get(Ii),Bo=Ii.isWebGLCubeRenderTarget===!0;if(Ii.depthTexture){if(Bo)throw new Error("target.depthTexture not supported in Cube render targets");(function(Cl,Us){if(Us&&Us.isWebGLCubeRenderTarget)throw new Error("Depth Texture with cube render targets is not supported");if(f.bindFramebuffer(36160,Cl),!Us.depthTexture||!Us.depthTexture.isDepthTexture)throw new Error("renderTarget.depthTexture must be an instance of THREE.DepthTexture");ge.get(Us.depthTexture).__webglTexture&&Us.depthTexture.image.width===Us.width&&Us.depthTexture.image.height===Us.height||(Us.depthTexture.image.width=Us.width,Us.depthTexture.image.height=Us.height,Us.depthTexture.needsUpdate=!0),Ya(Us.depthTexture,0);var eo=ge.get(Us.depthTexture).__webglTexture;if(Us.depthTexture.format===ni)f.framebufferTexture2D(36160,36096,3553,eo,0);else{if(Us.depthTexture.format!==Ei)throw new Error("Unknown depthTexture format");f.framebufferTexture2D(36160,33306,3553,eo,0)}})(va.__webglFramebuffer,Ii)}else if(Bo){va.__webglDepthbuffer=[];for(var Co=0;Co<6;Co++)f.bindFramebuffer(36160,va.__webglFramebuffer[Co]),va.__webglDepthbuffer[Co]=f.createRenderbuffer(),Ks(va.__webglDepthbuffer[Co],Ii)}else f.bindFramebuffer(36160,va.__webglFramebuffer),va.__webglDepthbuffer=f.createRenderbuffer(),Ks(va.__webglDepthbuffer,Ii);f.bindFramebuffer(36160,null)}function zs(Ii){return sn&&Ii.isWebGLMultisampleRenderTarget?Math.min(On,Ii.samples):0}ko[un]=9728,ko[Ln]=9984,ko[hr]=9986,ko[hi]=9729,ko[bi]=9985;var gl=!(ko[Ra]=9987),Os=!1;this.allocateTextureUnit=function(){var Ii=Ba;return ln<=Ii&&console.warn("THREE.WebGLTextures: Trying to use "+Ii+" texture units while this GPU supports only "+ln),Ba+=1,Ii},this.resetTextureUnits=function(){Ba=0},this.setTexture2D=Ya,this.setTexture2DArray=function(Ii,va){var Bo=ge.get(Ii);0<Ii.version&&Bo.__version!==Ii.version?fs(Bo,Ii,va):(W.activeTexture(33984+va),W.bindTexture(35866,Bo.__webglTexture))},this.setTexture3D=function(Ii,va){var Bo=ge.get(Ii);0<Ii.version&&Bo.__version!==Ii.version?fs(Bo,Ii,va):(W.activeTexture(33984+va),W.bindTexture(32879,Bo.__webglTexture))},this.setTextureCube=ro,this.setTextureCubeDynamic=$a,this.setupRenderTarget=function(Ii){var va=ge.get(Ii),Bo=ge.get(Ii.texture);Ii.addEventListener("dispose",ea),Bo.__webglTexture=f.createTexture(),St.memory.textures++;var Co=Ii.isWebGLCubeRenderTarget===!0,Cl=Ii.isWebGLMultisampleRenderTarget===!0,Us=Ii.isWebGLMultiviewRenderTarget===!0,eo=gi(Ii)||sn;if(Co){va.__webglFramebuffer=[];for(var Hs=0;Hs<6;Hs++)va.__webglFramebuffer[Hs]=f.createFramebuffer()}else if(va.__webglFramebuffer=f.createFramebuffer(),Cl)if(sn){va.__webglMultisampledFramebuffer=f.createFramebuffer(),va.__webglColorRenderbuffer=f.createRenderbuffer(),f.bindRenderbuffer(36161,va.__webglColorRenderbuffer);var Dl=gt.convert(Ii.texture.format),Pa=gt.convert(Ii.texture.type),Rs=da(Ii.texture.internalFormat,Dl,Pa),Ls=zs(Ii);f.renderbufferStorageMultisample(36161,Ls,Rs,Ii.width,Ii.height),f.bindFramebuffer(36160,va.__webglMultisampledFramebuffer),f.framebufferRenderbuffer(36160,36064,36161,va.__webglColorRenderbuffer),f.bindRenderbuffer(36161,null),Ii.depthBuffer&&(va.__webglDepthRenderbuffer=f.createRenderbuffer(),Ks(va.__webglDepthRenderbuffer,Ii,!0)),f.bindFramebuffer(36160,null)}else console.warn("THREE.WebGLRenderer: WebGLMultisampleRenderTarget can only be used with WebGL2.");else if(Us){var ml=Ii.width,ns=Ii.height,Rl=Ii.numViews;f.bindFramebuffer(36160,va.__webglFramebuffer);var ou=E.get("OVR_multiview2");St.memory.textures+=2;var Hu=f.createTexture();f.bindTexture(35866,Hu),f.texParameteri(35866,10240,9728),f.texParameteri(35866,10241,9728),f.texImage3D(35866,0,32856,ml,ns,Rl,0,6408,5121,null),ou.framebufferTextureMultiviewOVR(36160,36064,Hu,0,0,Rl);var rh=f.createTexture();f.bindTexture(35866,rh),f.texParameteri(35866,10240,9728),f.texParameteri(35866,10241,9728),f.texImage3D(35866,0,35056,ml,ns,Rl,0,34041,34042,null),ou.framebufferTextureMultiviewOVR(36160,33306,rh,0,0,Rl);var uu=new Array(Rl);for(Hs=0;Hs<Rl;++Hs)uu[Hs]=f.createFramebuffer(),f.bindFramebuffer(36160,uu[Hs]),f.framebufferTextureLayer(36160,36064,Hu,0,Hs);va.__webglColorTexture=Hu,va.__webglDepthStencilTexture=rh,va.__webglViewFramebuffers=uu,f.bindFramebuffer(36160,null),f.bindTexture(35866,null)}if(Co){for(W.bindTexture(34067,Bo.__webglTexture),Qa(34067,Ii.texture,eo),Hs=0;Hs<6;Hs++)os(va.__webglFramebuffer[Hs],Ii,36064,34069+Hs);Ci(Ii.texture,eo)&&$i(34067,Ii.texture,Ii.width,Ii.height),W.bindTexture(34067,null)}else Us||(W.bindTexture(3553,Bo.__webglTexture),Qa(3553,Ii.texture,eo),os(va.__webglFramebuffer,Ii,36064,3553),Ci(Ii.texture,eo)&&$i(3553,Ii.texture,Ii.width,Ii.height),W.bindTexture(3553,null));Ii.depthBuffer&&Xs(Ii)},this.updateRenderTargetMipmap=function(Ii){var va=Ii.texture;if(Ci(va,gi(Ii)||sn)){var Bo=Ii.isWebGLCubeRenderTarget?34067:3553,Co=ge.get(va).__webglTexture;W.bindTexture(Bo,Co),$i(Bo,va,Ii.width,Ii.height),W.bindTexture(Bo,null)}},this.updateMultisampleRenderTarget=function(Ii){if(Ii.isWebGLMultisampleRenderTarget)if(sn){var va=ge.get(Ii);f.bindFramebuffer(36008,va.__webglMultisampledFramebuffer),f.bindFramebuffer(36009,va.__webglFramebuffer);var Bo=Ii.width,Co=Ii.height,Cl=16384;Ii.depthBuffer&&(Cl|=256),Ii.stencilBuffer&&(Cl|=1024),f.blitFramebuffer(0,0,Bo,Co,0,0,Bo,Co,Cl,9728)}else console.warn("THREE.WebGLRenderer: WebGLMultisampleRenderTarget can only be used with WebGL2.")},this.safeSetTexture2D=function(Ii,va){Ii&&Ii.isWebGLRenderTarget&&(gl===!1&&(console.warn("THREE.WebGLTextures.safeSetTexture2D: don't use render targets as textures. Use their .texture property instead."),gl=!0),Ii=Ii.texture),Ya(Ii,va)},this.safeSetTextureCube=function(Ii,va){Ii&&Ii.isWebGLCubeRenderTarget&&(Os===!1&&(console.warn("THREE.WebGLTextures.safeSetTextureCube: don't use cube render targets as textures. Use their .texture property instead."),Os=!0),Ii=Ii.texture),(Ii&&Ii.isCubeTexture||Array.isArray(Ii.image)&&Ii.image.length===6?ro:$a)(Ii,va)}}function Uu(f,E,W){var ge=W.isWebGL2;return{convert:function(ct){var gt;if(ct===so)return 5121;if(ct===yo)return 32819;if(ct===ls)return 32820;if(ct===xo)return 33635;if(ct===Pi)return 5120;if(ct===oi)return 5122;if(ct===Ni)return 5123;if(ct===za)return 5124;if(ct===ki)return 5125;if(ct===Aa)return 5126;if(ct===Ja)return ge?5131:(gt=E.get("OES_texture_half_float"))!==null?gt.HALF_FLOAT_OES:null;if(ct===Ao)return 6406;if(ct===il)return 6407;if(ct===zr)return 6408;if(ct===zn)return 6409;if(ct===Un)return 6410;if(ct===ni)return 6402;if(ct===Ei)return 34041;if(ct===$t)return 6403;if(ct===ta)return 36244;if(ct===Hi)return 33319;if(ct===Ai)return 33320;if(ct===Ea)return 36248;if(ct===wo)return 36249;if(ct===to||ct===zo||ct===Po||ct===Lo){if((gt=E.get("WEBGL_compressed_texture_s3tc"))===null)return null;if(ct===to)return gt.COMPRESSED_RGB_S3TC_DXT1_EXT;if(ct===zo)return gt.COMPRESSED_RGBA_S3TC_DXT1_EXT;if(ct===Po)return gt.COMPRESSED_RGBA_S3TC_DXT3_EXT;if(ct===Lo)return gt.COMPRESSED_RGBA_S3TC_DXT5_EXT}if(ct===Wo||ct===ma||ct===$s||ct===ao){if((gt=E.get("WEBGL_compressed_texture_pvrtc"))===null)return null;if(ct===Wo)return gt.COMPRESSED_RGB_PVRTC_4BPPV1_IMG;if(ct===ma)return gt.COMPRESSED_RGB_PVRTC_2BPPV1_IMG;if(ct===$s)return gt.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG;if(ct===ao)return gt.COMPRESSED_RGBA_PVRTC_2BPPV1_IMG}return ct===Ps?(gt=E.get("WEBGL_compressed_texture_etc1"))!==null?gt.COMPRESSED_RGB_ETC1_WEBGL:null:ct===qo||ct===wl||ct===yu||ct===po||ct===Zs||ct===Es||ct===Xl||ct===xl||ct===jo||ct===ju||ct===Pl||ct===tl||ct===zl||ct===Is?(gt=E.get("WEBGL_compressed_texture_astc"))!==null?ct:null:ct===_o?ge?34042:(gt=E.get("WEBGL_depth_texture"))!==null?gt.UNSIGNED_INT_24_8_WEBGL:null:void 0}}}function ec(f,E,W,ge){Au.call(this,f,E,ge),this.depthBuffer=!1,this.stencilBuffer=!1,this.numViews=W}function tu(f){cc.call(this),this.cameras=f||[]}function tc(){Ri.call(this),this.type="Group"}function fd(f,E){var W=this,ge=null,ct=null,gt="local-floor",St=null,Pt=[],sn=new Map,ln=new cc;ln.layers.enable(1),ln.viewport=new Ll;var Sn=new cc;Sn.layers.enable(2),Sn.viewport=new Ll;var En=new tu([ln,Sn]);En.layers.enable(1),En.layers.enable(2);var On=null,mn=null;function Hn(ea){var Ba=sn.get(ea.inputSource);Ba&&(Ba.targetRay&&Ba.targetRay.dispatchEvent({type:ea.type}),Ba.grip&&Ba.grip.dispatchEvent({type:ea.type}))}function mr(){sn.forEach(function(ea,Ba){ea.targetRay&&(ea.targetRay.dispatchEvent({type:"disconnected",data:Ba}),ea.targetRay.visible=!1),ea.grip&&(ea.grip.dispatchEvent({type:"disconnected",data:Ba}),ea.grip.visible=!1)}),sn.clear(),f.setFramebuffer(null),f.setRenderTarget(f.getRenderTarget()),Sa.stop(),W.isPresenting=!1,W.dispatchEvent({type:"sessionend"})}function _r(ea){ct=ea,Sa.setContext(ge),Sa.start(),W.isPresenting=!0,W.dispatchEvent({type:"sessionstart"})}function gi(ea){for(var Ba=ge.inputSources,Ya=0;Ya<Pt.length;Ya++)sn.set(Ba[Ya],Pt[Ya]);for(Ya=0;Ya<ea.removed.length;Ya++){var ro=ea.removed[Ya];($a=sn.get(ro))&&($a.targetRay&&$a.targetRay.dispatchEvent({type:"disconnected",data:ro}),$a.grip&&$a.grip.dispatchEvent({type:"disconnected",data:ro}),sn.delete(ro))}for(Ya=0;Ya<ea.added.length;Ya++){var $a;ro=ea.added[Ya],($a=sn.get(ro))&&($a.targetRay&&$a.targetRay.dispatchEvent({type:"connected",data:ro}),$a.grip&&$a.grip.dispatchEvent({type:"connected",data:ro}))}}this.enabled=!1,this.isPresenting=!1,this.getController=function(ea){var Ba=Pt[ea];return Ba===void 0&&(Ba={},Pt[ea]=Ba),Ba.targetRay===void 0&&(Ba.targetRay=new tc,Ba.targetRay.matrixAutoUpdate=!1,Ba.targetRay.visible=!1),Ba.targetRay},this.getControllerGrip=function(ea){var Ba=Pt[ea];return Ba===void 0&&(Ba={},Pt[ea]=Ba),Ba.grip===void 0&&(Ba.grip=new tc,Ba.grip.matrixAutoUpdate=!1,Ba.grip.visible=!1),Ba.grip},this.setFramebufferScaleFactor=function(){},this.setReferenceSpaceType=function(ea){gt=ea},this.getReferenceSpace=function(){return ct},this.getSession=function(){return ge},this.setSession=function(ea){if((ge=ea)!==null){ge.addEventListener("select",Hn),ge.addEventListener("selectstart",Hn),ge.addEventListener("selectend",Hn),ge.addEventListener("squeeze",Hn),ge.addEventListener("squeezestart",Hn),ge.addEventListener("squeezeend",Hn),ge.addEventListener("end",mr);var Ba=E.getContextAttributes(),Ya={antialias:Ba.antialias,alpha:Ba.alpha,depth:Ba.depth,stencil:Ba.stencil},ro=new XRWebGLLayer(ge,E,Ya);ge.updateRenderState({baseLayer:ro}),ge.requestReferenceSpace(gt).then(_r),ge.addEventListener("inputsourceschange",gi)}};var Ci=new yi,$i=new yi;function da(ea,Ba){Ba===null?ea.matrixWorld.copy(ea.matrix):ea.matrixWorld.multiplyMatrices(Ba.matrixWorld,ea.matrix),ea.matrixWorldInverse.getInverse(ea.matrixWorld)}this.getCamera=function(ea){En.near=Sn.near=ln.near=ea.near,En.far=Sn.far=ln.far=ea.far,On===En.near&&mn===En.far||(ge.updateRenderState({depthNear:En.near,depthFar:En.far}),On=En.near,mn=En.far);var Ba=ea.parent,Ya=En.cameras;da(En,Ba);for(var ro=0;ro<Ya.length;ro++)da(Ya[ro],Ba);ea.matrixWorld.copy(En.matrixWorld);for(var $a=ea.children,go=(ro=0,$a.length);ro<go;ro++)$a[ro].updateMatrixWorld(!0);return function(ko,Qa,Ha){Ci.setFromMatrixPosition(Qa.matrixWorld),$i.setFromMatrixPosition(Ha.matrixWorld);var fs=Ci.distanceTo($i),os=Qa.projectionMatrix.elements,Ks=Ha.projectionMatrix.elements,Xs=os[14]/(os[10]-1),zs=os[14]/(os[10]+1),gl=(os[9]+1)/os[5],Os=(os[9]-1)/os[5],Ii=(os[8]-1)/os[0],va=(Ks[8]+1)/Ks[0],Bo=Xs*Ii,Co=Xs*va,Cl=fs/(va-Ii),Us=Cl*-Ii;Qa.matrixWorld.decompose(ko.position,ko.quaternion,ko.scale),ko.translateX(Us),ko.translateZ(Cl),ko.matrixWorld.compose(ko.position,ko.quaternion,ko.scale),ko.matrixWorldInverse.getInverse(ko.matrixWorld);var eo=Xs+Cl,Hs=zs+Cl,Dl=Bo-Us,Pa=fs-Us+Co,Rs=gl*zs/Hs*eo,Ls=Os*zs/Hs*eo;ko.projectionMatrix.makePerspective(Dl,Pa,Rs,Ls,eo,Hs)}(En,ln,Sn),En};var ji=null,Sa=new qf;Sa.setAnimationLoop(function(ea,Ba){if((St=Ba.getViewerPose(ct))!==null){var Ya=St.views,ro=ge.renderState.baseLayer;f.setFramebuffer(ro.framebuffer);for(var $a=0;$a<Ya.length;$a++){var go=Ya[$a],ko=ro.getViewport(go),Qa=En.cameras[$a];Qa.matrix.fromArray(go.transform.matrix),Qa.projectionMatrix.fromArray(go.projectionMatrix),Qa.viewport.set(ko.x,ko.y,ko.width,ko.height),$a===0&&En.matrix.copy(Qa.matrix)}}var Ha=ge.inputSources;for($a=0;$a<Pt.length;$a++){var fs=Pt[$a],os=Ha[$a],Ks=null,Xs=null;os&&(fs.targetRay&&(Ks=Ba.getPose(os.targetRaySpace,ct))!==null&&(fs.targetRay.matrix.fromArray(Ks.transform.matrix),fs.targetRay.matrix.decompose(fs.targetRay.position,fs.targetRay.rotation,fs.targetRay.scale)),fs.grip&&os.gripSpace&&(Xs=Ba.getPose(os.gripSpace,ct))!==null&&(fs.grip.matrix.fromArray(Xs.transform.matrix),fs.grip.matrix.decompose(fs.grip.position,fs.grip.rotation,fs.grip.scale))),fs.targetRay&&(fs.targetRay.visible=Ks!==null),fs.grip&&(fs.grip.visible=Xs!==null)}ji&&ji(ea,Ba)}),this.setAnimationLoop=function(ea){ji=ea},this.dispose=function(){}}function Yu(f){var E=(f=f||{}).canvas!==void 0?f.canvas:document.createElementNS("http://www.w3.org/1999/xhtml","canvas"),W=f.context!==void 0?f.context:null,ge=f.alpha!==void 0&&f.alpha,ct=f.depth===void 0||f.depth,gt=f.stencil===void 0||f.stencil,St=f.antialias!==void 0&&f.antialias,Pt=f.premultipliedAlpha===void 0||f.premultipliedAlpha,sn=f.preserveDrawingBuffer!==void 0&&f.preserveDrawingBuffer,ln=f.powerPreference!==void 0?f.powerPreference:"default",Sn=f.failIfMajorPerformanceCaveat!==void 0&&f.failIfMajorPerformanceCaveat,En=null,On=null;this.domElement=E,this.debug={checkShaderErrors:!0},this.autoClear=!0,this.autoClearColor=!0,this.autoClearDepth=!0,this.autoClearStencil=!0,this.sortObjects=!0,this.clippingPlanes=[],this.localClippingEnabled=!1,this.gammaFactor=2,this.outputEncoding=qi,this.physicallyCorrectLights=!1,this.toneMapping=Yn,this.toneMappingExposure=1,this.toneMappingWhitePoint=1,this.maxMorphTargets=8,this.maxMorphNormals=4;var mn,Hn,mr,_r,gi,Ci,$i,da,ji,Sa,ea,Ba,Ya,ro,$a,go,ko,Qa,Ha=this,fs=!1,os=null,Ks=0,Xs=0,zs=null,gl=null,Os=-1,Ii={geometry:null,program:null,wireframe:!1},va=null,Bo=null,Co=new Ll,Cl=new Ll,Us=null,eo=E.width,Hs=E.height,Dl=1,Pa=null,Rs=null,Ls=new Ll(0,0,eo,Hs),ml=new Ll(0,0,eo,Hs),ns=!1,Rl=new Ih,ou=new function(){var ci=this,oa=null,Yi=0,Da=!1,Na=!1,xs=new wu,ss=new Vl,Ko={value:null,needsUpdate:!1};function Cs(){Ko.value!==oa&&(Ko.value=oa,Ko.needsUpdate=0<Yi),ci.numPlanes=Yi,ci.numIntersection=0}function vo(Yo,rl,dl,us){var D=Yo!==null?Yo.length:0,_=null;if(D!==0){if(_=Ko.value,us!==!0||_===null){var k=dl+4*D,X=rl.matrixWorldInverse;ss.getNormalMatrix(X),(_===null||_.length<k)&&(_=new Float32Array(k));for(var de=0,Ge=dl;de!==D;++de,Ge+=4)xs.copy(Yo[de]).applyMatrix4(X,ss),xs.normal.toArray(_,Ge),_[Ge+3]=xs.constant}Ko.value=_,Ko.needsUpdate=!0}return ci.numPlanes=D,_}this.uniform=Ko,this.numPlanes=0,this.numIntersection=0,this.init=function(Yo,rl,dl){var us=Yo.length!==0||rl||Yi!==0||Da;return Da=rl,oa=vo(Yo,dl,0),Yi=Yo.length,us},this.beginShadows=function(){Na=!0,vo(null)},this.endShadows=function(){Na=!1,Cs()},this.setState=function(Yo,rl,dl,us,D,_){if(!Da||Yo===null||Yo.length===0||Na&&!dl)Na?vo(null):Cs();else{var k=Na?0:Yi,X=4*k,de=D.clippingState||null;Ko.value=de,de=vo(Yo,us,X,_);for(var Ge=0;Ge!==X;++Ge)de[Ge]=oa[Ge];D.clippingState=de,this.numIntersection=rl?this.numPlanes:0,this.numPlanes+=k}}},Hu=!1,rh=!1,uu=new Vo,Ou=new yi;function nu(){return zs===null?Dl:1}try{var Zu={alpha:ge,depth:ct,stencil:gt,antialias:St,premultipliedAlpha:Pt,preserveDrawingBuffer:sn,powerPreference:ln,failIfMajorPerformanceCaveat:Sn,xrCompatible:!0};E.addEventListener("webglcontextlost",ph,!1),E.addEventListener("webglcontextrestored",Ap,!1);var xu="webgl";if(f.webgl2===!0&&(xu="webgl2"),(mn=W||E.getContext(xu,Zu)||E.getContext("experimental-webgl",Zu))===null)throw E.getContext("webgl")!==null?new Error("Error creating WebGL context with your selected attributes."):new Error("Error creating WebGL context.");f.retver=xu,mn.getShaderPrecisionFormat===void 0&&(mn.getShaderPrecisionFormat=function(){return{rangeMin:1,rangeMax:1,precision:1}})}catch(ci){throw console.error("THREE.WebGLRenderer: "+ci.message),ci}function Oc(){Hn=new function(ci){var oa={};return{get:function(Yi){if(oa[Yi]!==void 0)return oa[Yi];var Da;switch(Yi){case"WEBGL_depth_texture":Da=ci.getExtension("WEBGL_depth_texture")||ci.getExtension("MOZ_WEBGL_depth_texture")||ci.getExtension("WEBKIT_WEBGL_depth_texture");break;case"EXT_texture_filter_anisotropic":Da=ci.getExtension("EXT_texture_filter_anisotropic")||ci.getExtension("MOZ_EXT_texture_filter_anisotropic")||ci.getExtension("WEBKIT_EXT_texture_filter_anisotropic");break;case"WEBGL_compressed_texture_s3tc":Da=ci.getExtension("WEBGL_compressed_texture_s3tc")||ci.getExtension("MOZ_WEBGL_compressed_texture_s3tc")||ci.getExtension("WEBKIT_WEBGL_compressed_texture_s3tc");break;case"WEBGL_compressed_texture_pvrtc":Da=ci.getExtension("WEBGL_compressed_texture_pvrtc")||ci.getExtension("WEBKIT_WEBGL_compressed_texture_pvrtc");break;default:Da=ci.getExtension(Yi)}return Da===null&&console.warn("THREE.WebGLRenderer: "+Yi+" extension not supported."),oa[Yi]=Da}}}(mn),(mr=new function(ci,oa,Yi){var Da;function Na(Ge){if(Ge==="highp"){if(0<ci.getShaderPrecisionFormat(35633,36338).precision&&0<ci.getShaderPrecisionFormat(35632,36338).precision)return"highp";Ge="mediump"}return Ge==="mediump"&&0<ci.getShaderPrecisionFormat(35633,36337).precision&&0<ci.getShaderPrecisionFormat(35632,36337).precision?"mediump":"lowp"}var xs=typeof WebGL2RenderingContext<"u"&&ci instanceof WebGL2RenderingContext||typeof WebGL2ComputeRenderingContext<"u"&&ci instanceof WebGL2ComputeRenderingContext,ss=Yi.precision!==void 0?Yi.precision:"highp",Ko=Na(ss);Ko!==ss&&(console.warn("THREE.WebGLRenderer:",ss,"not supported, using",Ko,"instead."),ss=Ko);var Cs=Yi.logarithmicDepthBuffer===!0,vo=ci.getParameter(34930),Yo=ci.getParameter(35660),rl=ci.getParameter(3379),dl=ci.getParameter(34076),us=ci.getParameter(34921),D=ci.getParameter(36347),_=ci.getParameter(36348),k=ci.getParameter(36349),X=0<Yo,de=xs||!!oa.get("OES_texture_float");return{isWebGL2:xs,getMaxAnisotropy:function(){if(Da!==void 0)return Da;var Ge=oa.get("EXT_texture_filter_anisotropic");return Da=Ge!==null?ci.getParameter(Ge.MAX_TEXTURE_MAX_ANISOTROPY_EXT):0},getMaxPrecision:Na,precision:ss,logarithmicDepthBuffer:Cs,maxTextures:vo,maxVertexTextures:Yo,maxTextureSize:rl,maxCubemapSize:dl,maxAttributes:us,maxVertexUniforms:D,maxVaryings:_,maxFragmentUniforms:k,vertexTextures:X,floatFragmentTextures:de,floatVertexTextures:X&&de,maxSamples:xs?ci.getParameter(36183):0}}(mn,Hn,f)).isWebGL2===!1&&(Hn.get("WEBGL_depth_texture"),Hn.get("OES_texture_float"),Hn.get("OES_texture_half_float"),Hn.get("OES_texture_half_float_linear"),Hn.get("OES_standard_derivatives"),Hn.get("OES_element_index_uint"),Hn.get("ANGLE_instanced_arrays")),Hn.get("OES_texture_float_linear"),Qa=new Uu(0,Hn,mr),(_r=new Bh(mn,Hn,mr)).scissor(Cl.copy(ml).multiplyScalar(Dl).floor()),_r.viewport(Co.copy(Ls).multiplyScalar(Dl).floor()),gi=new function(ci){var oa={frame:0,calls:0,triangles:0,points:0,lines:0};return{memory:{geometries:0,textures:0},render:oa,programs:null,autoReset:!0,reset:function(){oa.frame++,oa.calls=0,oa.triangles=0,oa.points=0,oa.lines=0},update:function(Yi,Da,Na){switch(Na=Na||1,oa.calls++,Da){case 4:oa.triangles+=Na*(Yi/3);break;case 1:oa.lines+=Na*(Yi/2);break;case 3:oa.lines+=Na*(Yi-1);break;case 2:oa.lines+=Na*Yi;break;case 0:oa.points+=Na*Yi;break;default:console.error("THREE.WebGLInfo: Unknown draw mode:",Da)}}}},Ci=new function(){var ci=new WeakMap;return{get:function(oa){var Yi=ci.get(oa);return Yi===void 0&&(Yi={},ci.set(oa,Yi)),Yi},remove:function(oa){ci.delete(oa)},update:function(oa,Yi,Da){ci.get(oa)[Yi]=Da},dispose:function(){ci=new WeakMap}}},$i=new Vh(mn,Hn,_r,Ci,mr,Qa,gi),da=new function(ci,oa){var Yi=oa.isWebGL2,Da=new WeakMap;return{get:function(Na){return Na.isInterleavedBufferAttribute&&(Na=Na.data),Da.get(Na)},remove:function(Na){Na.isInterleavedBufferAttribute&&(Na=Na.data);var xs=Da.get(Na);xs&&(ci.deleteBuffer(xs.buffer),Da.delete(Na))},update:function(Na,xs){Na.isInterleavedBufferAttribute&&(Na=Na.data);var ss,Ko,Cs,vo,Yo,rl=Da.get(Na);rl===void 0?Da.set(Na,function(dl,us){var D=dl.array,_=dl.usage,k=ci.createBuffer();ci.bindBuffer(us,k),ci.bufferData(us,D,_),dl.onUploadCallback();var X=5126;return D instanceof Float32Array?X=5126:D instanceof Float64Array?console.warn("THREE.WebGLAttributes: Unsupported data buffer format: Float64Array."):D instanceof Uint16Array?X=5123:D instanceof Int16Array?X=5122:D instanceof Uint32Array?X=5125:D instanceof Int32Array?X=5124:D instanceof Int8Array?X=5120:D instanceof Uint8Array&&(X=5121),{buffer:k,type:X,bytesPerElement:D.BYTES_PER_ELEMENT,version:dl.version}}(Na,xs)):rl.version<Na.version&&(ss=rl.buffer,Cs=xs,vo=(Ko=Na).array,Yo=Ko.updateRange,ci.bindBuffer(Cs,ss),Yo.count===-1?ci.bufferSubData(Cs,0,vo):(Yi?ci.bufferSubData(Cs,Yo.offset*vo.BYTES_PER_ELEMENT,vo,Yo.offset,Yo.count):ci.bufferSubData(Cs,Yo.offset*vo.BYTES_PER_ELEMENT,vo.subarray(Yo.offset,Yo.offset+Yo.count)),Yo.count=-1),rl.version=Na.version)}}}(mn,mr),ji=new function(ci,oa,Yi){var Da=new WeakMap,Na=new WeakMap;function xs(Ko){var Cs=Ko.target,vo=Da.get(Cs);for(var Yo in vo.index!==null&&oa.remove(vo.index),vo.attributes)oa.remove(vo.attributes[Yo]);Cs.removeEventListener("dispose",xs),Da.delete(Cs);var rl=Na.get(vo);rl&&(oa.remove(rl),Na.delete(vo)),Yi.memory.geometries--}function ss(Ko){var Cs=[],vo=Ko.index,Yo=Ko.attributes.position,rl=0;if(vo!==null){var dl=vo.array;rl=vo.version;for(var us=0,D=dl.length;us<D;us+=3){var _=dl[us+0],k=dl[us+1],X=dl[us+2];Cs.push(_,k,k,X,X,_)}}else for(dl=Yo.array,rl=Yo.version,us=0,D=dl.length/3-1;us<D;us+=3)_=us+0,k=us+1,X=us+2,Cs.push(_,k,k,X,X,_);var de=new(65535<Gl(Cs)?ws:Ws)(Cs,1);de.version=rl,oa.update(de,34963);var Ge=Na.get(Ko);Ge&&oa.remove(Ge),Na.set(Ko,de)}return{get:function(Ko,Cs){var vo=Da.get(Cs);return vo||(Cs.addEventListener("dispose",xs),Cs.isBufferGeometry?vo=Cs:Cs.isGeometry&&(Cs._bufferGeometry===void 0&&(Cs._bufferGeometry=new Ds().setFromObject(Ko)),vo=Cs._bufferGeometry),Da.set(Cs,vo),Yi.memory.geometries++,vo)},update:function(Ko){var Cs=Ko.index,vo=Ko.attributes;for(var Yo in Cs!==null&&oa.update(Cs,34963),vo)oa.update(vo[Yo],34962);var rl=Ko.morphAttributes;for(var Yo in rl)for(var dl=rl[Yo],us=0,D=dl.length;us<D;us++)oa.update(dl[us],34962)},getWireframeAttribute:function(Ko){var Cs=Na.get(Ko);if(Cs){var vo=Ko.index;vo!==null&&Cs.version<vo.version&&ss(Ko)}else ss(Ko);return Na.get(Ko)}}}(0,da,gi),Sa=new function(ci,oa,Yi,Da){var Na={};return{update:function(xs){var ss=Da.render.frame,Ko=xs.geometry,Cs=oa.get(xs,Ko);return Na[Cs.id]!==ss&&(Ko.isGeometry&&Cs.updateFromObject(xs),oa.update(Cs),Na[Cs.id]=ss),xs.isInstancedMesh&&Yi.update(xs.instanceMatrix,34962),Cs},dispose:function(){Na={}}}}(0,ji,da,gi),$a=new function(ci){var oa={},Yi=new Float32Array(8);return{update:function(Da,Na,xs,ss){var Ko=Da.morphTargetInfluences,Cs=Ko===void 0?0:Ko.length,vo=oa[Na.id];if(vo===void 0){vo=[];for(var Yo=0;Yo<Cs;Yo++)vo[Yo]=[Yo,0];oa[Na.id]=vo}var rl=xs.morphTargets&&Na.morphAttributes.position,dl=xs.morphNormals&&Na.morphAttributes.normal;for(Yo=0;Yo<Cs;Yo++)(D=vo[Yo])[1]!==0&&(rl&&Na.deleteAttribute("morphTarget"+Yo),dl&&Na.deleteAttribute("morphNormal"+Yo));for(Yo=0;Yo<Cs;Yo++)(D=vo[Yo])[0]=Yo,D[1]=Ko[Yo];vo.sort(Vp);var us=0;for(Yo=0;Yo<8;Yo++){var D;if(D=vo[Yo]){var _=D[0],k=D[1];if(k){rl&&Na.setAttribute("morphTarget"+Yo,rl[_]),dl&&Na.setAttribute("morphNormal"+Yo,dl[_]),us+=Yi[Yo]=k;continue}}Yi[Yo]=0}var X=Na.morphTargetsRelative?1:1-us;ss.getUniforms().setValue(ci,"morphTargetBaseInfluence",X),ss.getUniforms().setValue(ci,"morphTargetInfluences",Yi)}}}(mn),ea=new hs(Ha,Hn,mr),Ba=new function(){var ci=new WeakMap;function oa(Yi){var Da=Yi.target;Da.removeEventListener("dispose",oa),ci.delete(Da)}return{get:function(Yi,Da){var Na,xs=ci.get(Yi);return xs===void 0?(Na=new fl,ci.set(Yi,new WeakMap),ci.get(Yi).set(Da,Na),Yi.addEventListener("dispose",oa)):(Na=xs.get(Da))===void 0&&(Na=new fl,xs.set(Da,Na)),Na},dispose:function(){ci=new WeakMap}}},Ya=new function(){var ci=new WeakMap;function oa(Yi){var Da=Yi.target;Da.removeEventListener("dispose",oa),ci.delete(Da)}return{get:function(Yi,Da){var Na;return ci.has(Yi)===!1?(Na=new dc,ci.set(Yi,new WeakMap),ci.get(Yi).set(Da,Na),Yi.addEventListener("dispose",oa)):ci.get(Yi).has(Da)===!1?(Na=new dc,ci.get(Yi).set(Da,Na)):Na=ci.get(Yi).get(Da),Na},dispose:function(){ci=new WeakMap}}},ro=new Kl(Ha,_r,Sa,Pt),go=new function(ci,oa,Yi,Da){var Na,xs=Da.isWebGL2;this.setMode=function(ss){Na=ss},this.render=function(ss,Ko){ci.drawArrays(Na,ss,Ko),Yi.update(Ko,Na)},this.renderInstances=function(ss,Ko,Cs,vo){if(vo!==0){var Yo,rl;if(xs)Yo=ci,rl="drawArraysInstanced";else if(rl="drawArraysInstancedANGLE",(Yo=oa.get("ANGLE_instanced_arrays"))===null)return void console.error("THREE.WebGLBufferRenderer: using THREE.InstancedBufferGeometry but hardware does not support extension ANGLE_instanced_arrays.");Yo[rl](Na,Ko,Cs,vo),Yi.update(Cs,Na,vo)}}}(mn,Hn,gi,mr),ko=new function(ci,oa,Yi,Da){var Na,xs,ss,Ko=Da.isWebGL2;this.setMode=function(Cs){Na=Cs},this.setIndex=function(Cs){xs=Cs.type,ss=Cs.bytesPerElement},this.render=function(Cs,vo){ci.drawElements(Na,vo,xs,Cs*ss),Yi.update(vo,Na)},this.renderInstances=function(Cs,vo,Yo,rl){if(rl!==0){var dl,us;if(Ko)dl=ci,us="drawElementsInstanced";else if(us="drawElementsInstancedANGLE",(dl=oa.get("ANGLE_instanced_arrays"))===null)return void console.error("THREE.WebGLIndexedBufferRenderer: using THREE.InstancedBufferGeometry but hardware does not support extension ANGLE_instanced_arrays.");dl[us](Na,Yo,xs,vo*ss,rl),Yi.update(Yo,Na,rl)}}}(mn,Hn,gi,mr),gi.programs=ea.programs,Ha.capabilities=mr,Ha.extensions=Hn,Ha.properties=Ci,Ha.renderLists=Ba,Ha.state=_r,Ha.info=gi}Oc();var zu=new fd(Ha,mn);this.xr=zu;var rd=new function(ci,oa){var Yi,Da,Na,xs,ss,Ko,Cs,vo=ci.extensions,Yo=ci.properties,rl=0;function dl(us){return us.isArrayCamera?us.cameras:(ss[0]=us,ss)}this.isAvailable=function(){if(Cs===void 0){var us=vo.get("OVR_multiview2");if(Cs=us!==null&&oa.getContextAttributes().antialias===!1){rl=oa.getParameter(us.MAX_VIEWS_OVR),Yi=new ec(0,0,2),Ko=new co,xs=[],Na=[],ss=[];for(var D=0;D<rl;D++)xs[D]=new Vo,Na[D]=new Vl}}return Cs},this.attachCamera=function(us){(function(D){if(D.isArrayCamera===void 0)return!0;var _=D.cameras;if(_.length>rl)return!1;for(var k=1,X=_.length;k<X;k++)if(_[0].viewport.z!==_[k].viewport.z||_[0].viewport.w!==_[k].viewport.w)return!1;return!0})(us)!==!1&&(Da=ci.getRenderTarget(),function(D){if(Da?Ko.set(Da.width,Da.height):ci.getDrawingBufferSize(Ko),D.isArrayCamera){var _=D.cameras[0].viewport;Yi.setSize(_.z,_.w),Yi.setNumViews(D.cameras.length)}else Yi.setSize(Ko.x,Ko.y),Yi.setNumViews(2)}(us),ci.setRenderTarget(Yi))},this.detachCamera=function(us){Yi===ci.getRenderTarget()&&(ci.setRenderTarget(Da),function(D){var _=Yi,k=_.numViews,X=Yo.get(_).__webglViewFramebuffers,de=_.width,Ge=_.height;if(D.isArrayCamera)for(var ft=0;ft<k;ft++){var _t=D.cameras[ft].viewport,At=_t.x,Nt=_t.y,cn=At+_t.z,vn=Nt+_t.w;oa.bindFramebuffer(36008,X[ft]),oa.blitFramebuffer(0,0,de,Ge,At,Nt,cn,vn,16384,9728)}else oa.bindFramebuffer(36008,X[0]),oa.blitFramebuffer(0,0,de,Ge,0,0,Ko.x,Ko.y,16384,9728)}(us))},this.updateCameraProjectionMatricesUniform=function(us,D){for(var _=dl(us),k=0;k<_.length;k++)xs[k].copy(_[k].projectionMatrix);D.setValue(oa,"projectionMatrices",xs)},this.updateCameraViewMatricesUniform=function(us,D){for(var _=dl(us),k=0;k<_.length;k++)xs[k].copy(_[k].matrixWorldInverse);D.setValue(oa,"viewMatrices",xs)},this.updateObjectMatricesUniforms=function(us,D,_){for(var k=dl(D),X=0;X<k.length;X++)xs[X].multiplyMatrices(k[X].matrixWorldInverse,us.matrixWorld),Na[X].getNormalMatrix(xs[X]);_.setValue(oa,"modelViewMatrices",xs),_.setValue(oa,"normalMatrices",Na)}}(Ha,mn),zd=new yh(Ha,Sa,mr.maxTextureSize);function ph(ci){ci.preventDefault(),console.log("THREE.WebGLRenderer: Context Lost."),fs=!0}function Ap(){console.log("THREE.WebGLRenderer: Context Restored."),fs=!1,Oc()}function wf(ci){var oa,Yi=ci.target;Yi.removeEventListener("dispose",wf),o3(oa=Yi),Ci.remove(oa)}function o3(ci){var oa=Ci.get(ci).program;(ci.program=void 0)!==oa&&ea.releaseProgram(oa)}this.shadowMap=zd,this.getContext=function(){return mn},this.getContextAttributes=function(){return mn.getContextAttributes()},this.forceContextLoss=function(){var ci=Hn.get("WEBGL_lose_context");ci&&ci.loseContext()},this.forceContextRestore=function(){var ci=Hn.get("WEBGL_lose_context");ci&&ci.restoreContext()},this.getPixelRatio=function(){return Dl},this.setPixelRatio=function(ci){ci!==void 0&&(Dl=ci,this.setSize(eo,Hs,!1))},this.getSize=function(ci){return ci===void 0&&(console.warn("WebGLRenderer: .getsize() now requires a Vector2 as an argument"),ci=new co),ci.set(eo,Hs)},this.setSize=function(ci,oa,Yi){zu.isPresenting?console.warn("THREE.WebGLRenderer: Can't change size while VR device is presenting."):(eo=ci,Hs=oa,E.width=Math.floor(ci*Dl),E.height=Math.floor(oa*Dl),Yi!==!1&&(E.style.width=ci+"px",E.style.height=oa+"px"),this.setViewport(0,0,ci,oa))},this.getDrawingBufferSize=function(ci){return ci===void 0&&(console.warn("WebGLRenderer: .getdrawingBufferSize() now requires a Vector2 as an argument"),ci=new co),ci.set(eo*Dl,Hs*Dl).floor()},this.setDrawingBufferSize=function(ci,oa,Yi){eo=ci,Hs=oa,Dl=Yi,E.width=Math.floor(ci*Yi),E.height=Math.floor(oa*Yi),this.setViewport(0,0,ci,oa)},this.getCurrentViewport=function(ci){return ci===void 0&&(console.warn("WebGLRenderer: .getCurrentViewport() now requires a Vector4 as an argument"),ci=new Ll),ci.copy(Co)},this.getViewport=function(ci){return ci.copy(Ls)},this.setViewport=function(ci,oa,Yi,Da){ci.isVector4?Ls.set(ci.x,ci.y,ci.z,ci.w):Ls.set(ci,oa,Yi,Da),_r.viewport(Co.copy(Ls).multiplyScalar(Dl).floor())},this.getScissor=function(ci){return ci.copy(ml)},this.setScissor=function(ci,oa,Yi,Da){ci.isVector4?ml.set(ci.x,ci.y,ci.z,ci.w):ml.set(ci,oa,Yi,Da),_r.scissor(Cl.copy(ml).multiplyScalar(Dl).floor())},this.getScissorTest=function(){return ns},this.setScissorTest=function(ci){_r.setScissorTest(ns=ci)},this.setOpaqueSort=function(ci){Pa=ci},this.setTransparentSort=function(ci){Rs=ci},this.getClearColor=function(){return ro.getClearColor()},this.setClearColor=function(){ro.setClearColor.apply(ro,arguments)},this.getClearAlpha=function(){return ro.getClearAlpha()},this.setClearAlpha=function(){ro.setClearAlpha.apply(ro,arguments)},this.clear=function(ci,oa,Yi){var Da=0;ci!==void 0&&!ci||(Da|=16384),oa!==void 0&&!oa||(Da|=256),Yi!==void 0&&!Yi||(Da|=1024),mn.clear(Da)},this.clearColor=function(){this.clear(!0,!1,!1)},this.clearDepth=function(){this.clear(!1,!0,!1)},this.clearStencil=function(){this.clear(!1,!1,!0)},this.dispose=function(){E.removeEventListener("webglcontextlost",ph,!1),E.removeEventListener("webglcontextrestored",Ap,!1),Ba.dispose(),Ya.dispose(),Ci.dispose(),Sa.dispose(),zu.dispose(),Em.stop()},this.renderBufferImmediate=function(ci,oa){_r.initAttributes();var Yi=Ci.get(ci);ci.hasPositions&&!Yi.position&&(Yi.position=mn.createBuffer()),ci.hasNormals&&!Yi.normal&&(Yi.normal=mn.createBuffer()),ci.hasUvs&&!Yi.uv&&(Yi.uv=mn.createBuffer()),ci.hasColors&&!Yi.color&&(Yi.color=mn.createBuffer());var Da=oa.getAttributes();ci.hasPositions&&(mn.bindBuffer(34962,Yi.position),mn.bufferData(34962,ci.positionArray,35048),_r.enableAttribute(Da.position),mn.vertexAttribPointer(Da.position,3,5126,!1,0,0)),ci.hasNormals&&(mn.bindBuffer(34962,Yi.normal),mn.bufferData(34962,ci.normalArray,35048),_r.enableAttribute(Da.normal),mn.vertexAttribPointer(Da.normal,3,5126,!1,0,0)),ci.hasUvs&&(mn.bindBuffer(34962,Yi.uv),mn.bufferData(34962,ci.uvArray,35048),_r.enableAttribute(Da.uv),mn.vertexAttribPointer(Da.uv,2,5126,!1,0,0)),ci.hasColors&&(mn.bindBuffer(34962,Yi.color),mn.bufferData(34962,ci.colorArray,35048),_r.enableAttribute(Da.color),mn.vertexAttribPointer(Da.color,3,5126,!1,0,0)),_r.disableUnusedAttributes(),mn.drawArrays(4,0,ci.count),ci.count=0};var Jg=new fa;this.renderBufferDirect=function(ci,oa,Yi,Da,Na,xs){oa===null&&(oa=Jg);var ss=Na.isMesh&&Na.matrixWorld.determinant()<0,Ko=K3(ci,oa,Da,Na);_r.setMaterial(Da,ss);var Cs=!1;Ii.geometry===Yi.id&&Ii.program===Ko.id&&Ii.wireframe===(Da.wireframe===!0)||(Ii.geometry=Yi.id,Ii.program=Ko.id,Ii.wireframe=Da.wireframe===!0,Cs=!0),(Da.morphTargets||Da.morphNormals)&&($a.update(Na,Yi,Da,Ko),Cs=!0);var vo=Yi.index,Yo=Yi.attributes.position;if(vo===null){if(Yo===void 0||Yo.count===0)return}else if(vo.count===0)return;var rl,dl=1;Da.wireframe===!0&&(vo=ji.getWireframeAttribute(Yi),dl=2);var us=go;vo!==null&&((rl=da.get(vo))?(us=ko).setIndex(rl):(console.log("mx attribute == null"),vo=null)),Cs&&(function(Nt,cn,vn,bn){if(mr.isWebGL2!==!1||!Nt.isInstancedMesh&&!cn.isInstancedBufferGeometry||Hn.get("ANGLE_instanced_arrays")!==null){_r.initAttributes();var jn=cn.attributes,Zn=bn.getAttributes(),Br=vn.defaultAttributeValues;for(var Jr in Zn){var si=Zn[Jr];if(0<=si){var Li=jn[Jr];if(Li!==void 0){var vi=Li.normalized,ui=Li.itemSize;if((Va=da.get(Li))===void 0)continue;var ua=Va.buffer,ba=Va.type,Ua=Va.bytesPerElement;if(Li.isInterleavedBufferAttribute){var Ga=Li.data,ho=Ga.stride,bo=Li.offset;Ga&&Ga.isInstancedInterleavedBuffer?(_r.enableAttributeAndDivisor(si,Ga.meshPerAttribute),cn.maxInstancedCount===void 0&&(cn.maxInstancedCount=Ga.meshPerAttribute*Ga.count)):_r.enableAttribute(si),mn.bindBuffer(34962,ua),mn.vertexAttribPointer(si,ui,ba,vi,ho*Ua,bo*Ua)}else Li.isInstancedBufferAttribute?(_r.enableAttributeAndDivisor(si,Li.meshPerAttribute),cn.maxInstancedCount===void 0&&(cn.maxInstancedCount=Li.meshPerAttribute*Li.count)):_r.enableAttribute(si),mn.bindBuffer(34962,ua),mn.vertexAttribPointer(si,ui,ba,vi,0,0)}else if(Jr==="instanceMatrix"){var Va;if((Va=da.get(Nt.instanceMatrix))===void 0)continue;ua=Va.buffer,ba=Va.type,_r.enableAttributeAndDivisor(si+0,1),_r.enableAttributeAndDivisor(si+1,1),_r.enableAttributeAndDivisor(si+2,1),_r.enableAttributeAndDivisor(si+3,1),mn.bindBuffer(34962,ua),mn.vertexAttribPointer(si+0,4,ba,!1,64,0),mn.vertexAttribPointer(si+1,4,ba,!1,64,16),mn.vertexAttribPointer(si+2,4,ba,!1,64,32),mn.vertexAttribPointer(si+3,4,ba,!1,64,48)}else if(Br!==void 0){var Ka=Br[Jr];if(Ka!==void 0)switch(Ka.length){case 2:mn.vertexAttrib2fv(si,Ka);break;case 3:mn.vertexAttrib3fv(si,Ka);break;case 4:mn.vertexAttrib4fv(si,Ka);break;default:mn.vertexAttrib1fv(si,Ka)}}}}_r.disableUnusedAttributes()}}(Na,Yi,Da,Ko),vo!==null&&mn.bindBuffer(34963,rl.buffer));var D=vo!==null?vo.count:Yo.count,_=Yi.drawRange.start*dl,k=Yi.drawRange.count*dl,X=xs!==null?xs.start*dl:0,de=xs!==null?xs.count*dl:1/0,Ge=Math.max(_,X),ft=Math.min(D,_+k,X+de)-1,_t=Math.max(0,ft-Ge+1);if(_t!==0){if(Na.isMesh)Da.wireframe===!0?(_r.setLineWidth(Da.wireframeLinewidth*nu()),us.setMode(1)):us.setMode(4);else if(Na.isLine){var At=Da.linewidth;At===void 0&&(At=1),_r.setLineWidth(At*nu()),Na.isLineSegments?us.setMode(1):Na.isLineLoop?us.setMode(2):us.setMode(3)}else Na.isPoints?us.setMode(0):Na.isSprite&&us.setMode(4);Na.isInstancedMesh?us.renderInstances(Yi,Ge,_t,Na.count):Yi.isInstancedBufferGeometry?us.renderInstances(Yi,Ge,_t,Yi.maxInstancedCount):us.render(Ge,_t)}},this.compile=function(ci,oa){(On=Ya.get(ci,oa)).init(),ci.traverse(function(Da){Da.isLight&&(On.pushLight(Da),Da.castShadow&&On.pushShadow(Da))}),On.setupLights(oa);var Yi={};ci.traverse(function(Da){if(Da.material)if(Array.isArray(Da.material))for(var Na=0;Na<Da.material.length;Na++)Da.material[Na].uuid in Yi==0&&(Uh(Da.material[Na],ci,Da),Yi[Da.material[Na].uuid]=!0);else Da.material.uuid in Yi==0&&(Uh(Da.material,ci,Da),Yi[Da.material.uuid]=!0)})};var Dm=null,Em=new qf;function Am(ci,oa,Yi,Da){for(var Na=0,xs=ci.length;Na<xs;Na++){var ss=ci[Na],Ko=ss.object,Cs=ss.geometry,vo=Da===void 0?ss.material:Da,Yo=ss.group;if(Yi.isArrayCamera)if(Bo=Yi,zu.enabled&&rd.isAvailable())s3(Ko,oa,Yi,Cs,vo,Yo);else for(var rl=Yi.cameras,dl=0,us=rl.length;dl<us;dl++){var D=rl[dl];Ko.layers.test(D.layers)&&(_r.viewport(Co.copy(D.viewport)),On.setupLights(D),s3(Ko,oa,D,Cs,vo,Yo))}else Bo=null,s3(Ko,oa,Yi,Cs,vo,Yo)}}function s3(ci,oa,Yi,Da,Na,xs){if(ci.onBeforeRender(Ha,oa,Yi,Da,Na,xs),On=Ya.get(oa,Bo||Yi),ci.modelViewMatrix.multiplyMatrices(Yi.matrixWorldInverse,ci.matrixWorld),ci.normalMatrix.getNormalMatrix(ci.modelViewMatrix),ci.isImmediateRenderObject){var ss=K3(Yi,oa,Na,ci);_r.setMaterial(Na),Ii.geometry=null,Ii.program=null,Ii.wireframe=!1,Ko=ss,ci.render(function(Cs){Ha.renderBufferImmediate(Cs,Ko)})}else Ha.renderBufferDirect(Yi,oa,Da,Na,ci,xs);var Ko;ci.onAfterRender(Ha,oa,Yi,Da,Na,xs),On=Ya.get(oa,Bo||Yi)}function Uh(ci,oa,Yi){var Da=Ci.get(ci),Na=On.state.lights,xs=On.state.shadowsArray,ss=Na.state.version,Ko=ea.getParameters(ci,Na.state,xs,oa,ou.numPlanes,ou.numIntersection,Yi),Cs=ea.getProgramCacheKey(Ko),vo=Da.program,Yo=!0;if(vo===void 0)ci.addEventListener("dispose",wf);else if(vo.cacheKey!==Cs)o3(ci);else if(Da.lightsStateVersion!==ss)Da.lightsStateVersion=ss,Yo=!1;else{if(Ko.shaderID!==void 0)return;Yo=!1}Yo&&(vo=ea.acquireProgram(Ko,Cs),Da.program=vo,Da.uniforms=Ko.uniforms,Da.environment=ci.isMeshStandardMaterial?oa.environment:null,Da.outputEncoding=Ha.outputEncoding,ci.program=vo);var rl=vo.getAttributes();if(ci.morphTargets)for(var dl=ci.numSupportedMorphTargets=0;dl<Ha.maxMorphTargets;dl++)0<=rl["morphTarget"+dl]&&ci.numSupportedMorphTargets++;if(ci.morphNormals)for(dl=ci.numSupportedMorphNormals=0;dl<Ha.maxMorphNormals;dl++)0<=rl["morphNormal"+dl]&&ci.numSupportedMorphNormals++;var us,D=Da.uniforms;(ci.isShaderMaterial||ci.isRawShaderMaterial)&&ci.clipping!==!0||(Da.numClippingPlanes=ou.numPlanes,Da.numIntersection=ou.numIntersection,D.clippingPlanes=ou.uniform),Da.fog=oa.fog,Da.needsLights=(us=ci).isMeshLambertMaterial||us.isMeshToonMaterial||us.isMeshPhongMaterial||us.isMeshStandardMaterial||us.isShadowMaterial||us.isShaderMaterial&&us.lights===!0,Da.lightsStateVersion=ss,Da.needsLights&&(D.ambientLightColor.value=Na.state.ambient,D.lightProbe.value=Na.state.probe,D.directionalLights.value=Na.state.directional,D.spotLights.value=Na.state.spot,D.rectAreaLights.value=Na.state.rectArea,D.pointLights.value=Na.state.point,D.hemisphereLights.value=Na.state.hemi,D.directionalShadowMap.value=Na.state.directionalShadowMap,D.directionalShadowMatrix.value=Na.state.directionalShadowMatrix,D.spotShadowMap.value=Na.state.spotShadowMap,D.spotShadowMatrix.value=Na.state.spotShadowMatrix,D.pointShadowMap.value=Na.state.pointShadowMap,D.pointShadowMatrix.value=Na.state.pointShadowMatrix);var _=Da.program.getUniforms(),k=wi.seqWithValue(_.seq,D);Da.uniformsList=k}function K3(ci,oa,Yi,Da){$i.resetTextureUnits();var Na=oa.fog,xs=Yi.isMeshStandardMaterial?oa.environment:null,ss=Ci.get(Yi),Ko=On.state.lights;if(Hu&&(rh||ci!==va)){var Cs=ci===va&&Yi.id===Os;ou.setState(Yi.clippingPlanes,Yi.clipIntersection,Yi.clipShadows,ci,ss,Cs)}Yi.version===ss.__version?(ss.program===void 0||Yi.fog&&ss.fog!==Na||ss.environment!==xs||ss.needsLights&&ss.lightsStateVersion!==Ko.state.version||ss.numClippingPlanes!==void 0&&(ss.numClippingPlanes!==ou.numPlanes||ss.numIntersection!==ou.numIntersection)||ss.outputEncoding!==Ha.outputEncoding)&&Uh(Yi,oa,Da):(Ci.update(Yi,"uniforms",Yi.uniforms),Uh(Yi,oa,Da),ss.__version=Yi.version);var vo,Yo,rl,dl,us,D,_,k,X,de,Ge,ft,_t=!1,At=!1,Nt=!1,cn=ss.program,vn=cn.getUniforms(),bn=ss.uniforms;if(_r.useProgram(cn.program)&&(Nt=At=_t=!0),Yi.id!==Os&&(Os=Yi.id,At=!0),_t||va!==ci){if(0<cn.numMultiviewViews?rd.updateCameraProjectionMatricesUniform(ci,vn):vn.setValue(mn,"projectionMatrix",ci.projectionMatrix),mr.logarithmicDepthBuffer&&vn.setValue(mn,"logDepthBufFC",2/(Math.log(ci.far+1)/Math.LN2)),va!==ci&&(va=ci,Nt=At=!0),Yi.isShaderMaterial||Yi.isMeshPhongMaterial||Yi.isMeshToonMaterial||Yi.isMeshStandardMaterial||Yi.envMap){var jn=vn.map.cameraPosition;jn!==void 0&&jn.setValue(mn,Ou.setFromMatrixPosition(ci.matrixWorld))}(Yi.isMeshPhongMaterial||Yi.isMeshToonMaterial||Yi.isMeshLambertMaterial||Yi.isMeshBasicMaterial||Yi.isMeshStandardMaterial||Yi.isShaderMaterial)&&vn.setValue(mn,"isOrthographic",ci.isOrthographicCamera===!0),(Yi.isMeshPhongMaterial||Yi.isMeshToonMaterial||Yi.isMeshLambertMaterial||Yi.isMeshBasicMaterial||Yi.isMeshStandardMaterial||Yi.isShaderMaterial||Yi.skinning)&&(0<cn.numMultiviewViews?rd.updateCameraViewMatricesUniform(ci,vn):vn.setValue(mn,"viewMatrix",ci.matrixWorldInverse))}if(Yi.skinning){vn.setOptional(mn,Da,"bindMatrix"),vn.setOptional(mn,Da,"bindMatrixInverse");var Zn=Da.skeleton;if(Zn){var Br=Zn.bones;if(mr.floatVertexTextures){if(Zn.boneTexture===void 0){var Jr=Math.sqrt(4*Br.length);Jr=js.ceilPowerOfTwo(Jr),Jr=Math.max(Jr,4);var si=new Float32Array(Jr*Jr*4);si.set(Zn.boneMatrices);var Li=new pp(si,Jr,Jr,zr,Aa);Zn.boneMatrices=si,Zn.boneTexture=Li,Zn.boneTextureSize=Jr}vn.setValue(mn,"boneTexture",Zn.boneTexture,$i),vn.setValue(mn,"boneTextureSize",Zn.boneTextureSize)}else vn.setOptional(mn,Zn,"boneMatrices")}}return!At&&ss.receiveShadow===Da.receiveShadow||(ss.receiveShadow=Da.receiveShadow,vn.setValue(mn,"receiveShadow",Da.receiveShadow)),At&&(vn.setValue(mn,"toneMappingExposure",Ha.toneMappingExposure),vn.setValue(mn,"toneMappingWhitePoint",Ha.toneMappingWhitePoint),ss.needsLights&&(ft=Nt,(Ge=bn).ambientLightColor.needsUpdate=ft,Ge.lightProbe.needsUpdate=ft,Ge.directionalLights.needsUpdate=ft,Ge.pointLights.needsUpdate=ft,Ge.spotLights.needsUpdate=ft,Ge.rectAreaLights.needsUpdate=ft,Ge.hemisphereLights.needsUpdate=ft),Na&&Yi.fog&&(de=Na,(X=bn).fogColor.value.copy(de.color),de.isFog?(X.fogNear.value=de.near,X.fogFar.value=de.far):de.isFogExp2&&(X.fogDensity.value=de.density)),Yi.isMeshBasicMaterial?$h(bn,Yi):Yi.isMeshLambertMaterial?($h(bn,Yi),_=bn,(k=Yi).emissiveMap&&(_.emissiveMap.value=k.emissiveMap)):Yi.isMeshToonMaterial?($h(bn,Yi),function(vi,ui){vi.specular.value.copy(ui.specular),vi.shininess.value=Math.max(ui.shininess,1e-4),ui.gradientMap&&(vi.gradientMap.value=ui.gradientMap),ui.emissiveMap&&(vi.emissiveMap.value=ui.emissiveMap),ui.bumpMap&&(vi.bumpMap.value=ui.bumpMap,vi.bumpScale.value=ui.bumpScale,ui.side===q&&(vi.bumpScale.value*=-1)),ui.normalMap&&(vi.normalMap.value=ui.normalMap,vi.normalScale.value.copy(ui.normalScale),ui.side===q&&vi.normalScale.value.negate()),ui.displacementMap&&(vi.displacementMap.value=ui.displacementMap,vi.displacementScale.value=ui.displacementScale,vi.displacementBias.value=ui.displacementBias)}(bn,Yi)):Yi.isMeshPhongMaterial?($h(bn,Yi),function(vi,ui){vi.specular.value.copy(ui.specular),vi.shininess.value=Math.max(ui.shininess,1e-4),ui.emissiveMap&&(vi.emissiveMap.value=ui.emissiveMap),ui.bumpMap&&(vi.bumpMap.value=ui.bumpMap,vi.bumpScale.value=ui.bumpScale,ui.side===q&&(vi.bumpScale.value*=-1)),ui.normalMap&&(vi.normalMap.value=ui.normalMap,vi.normalScale.value.copy(ui.normalScale),ui.side===q&&vi.normalScale.value.negate()),ui.displacementMap&&(vi.displacementMap.value=ui.displacementMap,vi.displacementScale.value=ui.displacementScale,vi.displacementBias.value=ui.displacementBias)}(bn,Yi)):Yi.isMeshStandardMaterial?($h(bn,Yi,xs),(Yi.isMeshPhysicalMaterial?function(vi,ui,ua){M3(vi,ui,ua),vi.reflectivity.value=ui.reflectivity,vi.clearcoat.value=ui.clearcoat,vi.clearcoatRoughness.value=ui.clearcoatRoughness,ui.sheen&&vi.sheen.value.copy(ui.sheen),ui.clearcoatNormalMap&&(vi.clearcoatNormalScale.value.copy(ui.clearcoatNormalScale),vi.clearcoatNormalMap.value=ui.clearcoatNormalMap,ui.side===q&&vi.clearcoatNormalScale.value.negate()),vi.transparency.value=ui.transparency}:M3)(bn,Yi,xs)):Yi.isMeshMatcapMaterial?($h(bn,Yi),function(vi,ui){ui.matcap&&(vi.matcap.value=ui.matcap),ui.bumpMap&&(vi.bumpMap.value=ui.bumpMap,vi.bumpScale.value=ui.bumpScale,ui.side===q&&(vi.bumpScale.value*=-1)),ui.normalMap&&(vi.normalMap.value=ui.normalMap,vi.normalScale.value.copy(ui.normalScale),ui.side===q&&vi.normalScale.value.negate()),ui.displacementMap&&(vi.displacementMap.value=ui.displacementMap,vi.displacementScale.value=ui.displacementScale,vi.displacementBias.value=ui.displacementBias)}(bn,Yi)):Yi.isMeshDepthMaterial?($h(bn,Yi),us=bn,(D=Yi).displacementMap&&(us.displacementMap.value=D.displacementMap,us.displacementScale.value=D.displacementScale,us.displacementBias.value=D.displacementBias)):Yi.isMeshDistanceMaterial?($h(bn,Yi),function(vi,ui){ui.displacementMap&&(vi.displacementMap.value=ui.displacementMap,vi.displacementScale.value=ui.displacementScale,vi.displacementBias.value=ui.displacementBias),vi.referencePosition.value.copy(ui.referencePosition),vi.nearDistance.value=ui.nearDistance,vi.farDistance.value=ui.farDistance}(bn,Yi)):Yi.isMeshNormalMaterial?($h(bn,Yi),function(vi,ui){ui.bumpMap&&(vi.bumpMap.value=ui.bumpMap,vi.bumpScale.value=ui.bumpScale,ui.side===q&&(vi.bumpScale.value*=-1)),ui.normalMap&&(vi.normalMap.value=ui.normalMap,vi.normalScale.value.copy(ui.normalScale),ui.side===q&&vi.normalScale.value.negate()),ui.displacementMap&&(vi.displacementMap.value=ui.displacementMap,vi.displacementScale.value=ui.displacementScale,vi.displacementBias.value=ui.displacementBias)}(bn,Yi)):Yi.isLineBasicMaterial?(dl=Yi,(rl=bn).diffuse.value.copy(dl.color),rl.opacity.value=dl.opacity,Yi.isLineDashedMaterial&&(Yo=Yi,(vo=bn).dashSize.value=Yo.dashSize,vo.totalSize.value=Yo.dashSize+Yo.gapSize,vo.scale.value=Yo.scale)):Yi.isPointsMaterial?function(vi,ui){var ua;vi.diffuse.value.copy(ui.color),vi.opacity.value=ui.opacity,vi.size.value=ui.size*Dl,vi.scale.value=.5*Hs,ui.map&&(vi.map.value=ui.map),ui.alphaMap&&(vi.alphaMap.value=ui.alphaMap),ui.map?ua=ui.map:ui.alphaMap&&(ua=ui.alphaMap),ua!==void 0&&(ua.matrixAutoUpdate===!0&&ua.updateMatrix(),vi.uvTransform.value.copy(ua.matrix))}(bn,Yi):Yi.isSpriteMaterial?function(vi,ui){var ua;vi.diffuse.value.copy(ui.color),vi.opacity.value=ui.opacity,vi.rotation.value=ui.rotation,ui.map&&(vi.map.value=ui.map),ui.alphaMap&&(vi.alphaMap.value=ui.alphaMap),ui.map?ua=ui.map:ui.alphaMap&&(ua=ui.alphaMap),ua!==void 0&&(ua.matrixAutoUpdate===!0&&ua.updateMatrix(),vi.uvTransform.value.copy(ua.matrix))}(bn,Yi):Yi.isShadowMaterial&&(bn.color.value.copy(Yi.color),bn.opacity.value=Yi.opacity),bn.ltc_1!==void 0&&(bn.ltc_1.value=Ts.LTC_1),bn.ltc_2!==void 0&&(bn.ltc_2.value=Ts.LTC_2),wi.upload(mn,ss.uniformsList,bn,$i),Yi.isShaderMaterial&&(Yi.uniformsNeedUpdate=!1)),Yi.isShaderMaterial&&Yi.uniformsNeedUpdate===!0&&(wi.upload(mn,ss.uniformsList,bn,$i),Yi.uniformsNeedUpdate=!1),Yi.isSpriteMaterial&&vn.setValue(mn,"center",Da.center),0<cn.numMultiviewViews?rd.updateObjectMatricesUniforms(Da,ci,vn):(vn.setValue(mn,"modelViewMatrix",Da.modelViewMatrix),vn.setValue(mn,"normalMatrix",Da.normalMatrix)),vn.setValue(mn,"modelMatrix",Da.matrixWorld),cn}function $h(ci,oa,Yi){ci.opacity.value=oa.opacity,oa.color&&ci.diffuse.value.copy(oa.color),oa.emissive&&ci.emissive.value.copy(oa.emissive).multiplyScalar(oa.emissiveIntensity),oa.map&&(ci.map.value=oa.map),oa.alphaMap&&(ci.alphaMap.value=oa.alphaMap),oa.specularMap&&(ci.specularMap.value=oa.specularMap);var Da,Na,xs=oa.envMap||Yi;xs&&(ci.envMap.value=xs,ci.flipEnvMap.value=xs.isCubeTexture?-1:1,ci.reflectivity.value=oa.reflectivity,ci.refractionRatio.value=oa.refractionRatio,ci.maxMipLevel.value=Ci.get(xs).__maxMipLevel),oa.lightMap&&(ci.lightMap.value=oa.lightMap,ci.lightMapIntensity.value=oa.lightMapIntensity),oa.aoMap&&(ci.aoMap.value=oa.aoMap,ci.aoMapIntensity.value=oa.aoMapIntensity),oa.map?Da=oa.map:oa.specularMap?Da=oa.specularMap:oa.displacementMap?Da=oa.displacementMap:oa.normalMap?Da=oa.normalMap:oa.bumpMap?Da=oa.bumpMap:oa.roughnessMap?Da=oa.roughnessMap:oa.metalnessMap?Da=oa.metalnessMap:oa.alphaMap?Da=oa.alphaMap:oa.emissiveMap&&(Da=oa.emissiveMap),Da!==void 0&&(Da.isWebGLRenderTarget&&(Da=Da.texture),Da.matrixAutoUpdate===!0&&Da.updateMatrix(),ci.uvTransform.value.copy(Da.matrix)),oa.aoMap?Na=oa.aoMap:oa.lightMap&&(Na=oa.lightMap),Na!==void 0&&(Na.isWebGLRenderTarget&&(Na=Na.texture),Na.matrixAutoUpdate===!0&&Na.updateMatrix(),ci.uv2Transform.value.copy(Na.matrix))}function M3(ci,oa,Yi){ci.roughness.value=oa.roughness,ci.metalness.value=oa.metalness,oa.roughnessMap&&(ci.roughnessMap.value=oa.roughnessMap),oa.metalnessMap&&(ci.metalnessMap.value=oa.metalnessMap),oa.emissiveMap&&(ci.emissiveMap.value=oa.emissiveMap),oa.bumpMap&&(ci.bumpMap.value=oa.bumpMap,ci.bumpScale.value=oa.bumpScale,oa.side===q&&(ci.bumpScale.value*=-1)),oa.normalMap&&(ci.normalMap.value=oa.normalMap,ci.normalScale.value.copy(oa.normalScale),oa.side===q&&ci.normalScale.value.negate()),oa.displacementMap&&(ci.displacementMap.value=oa.displacementMap,ci.displacementScale.value=oa.displacementScale,ci.displacementBias.value=oa.displacementBias),(oa.envMap||Yi)&&(ci.envMapIntensity.value=oa.envMapIntensity)}Em.setAnimationLoop(function(ci){zu.isPresenting||Dm&&Dm(ci)}),typeof window<"u"&&Em.setContext(window),this.setAnimationLoop=function(ci){Dm=ci,zu.setAnimationLoop(ci),Em.start()},this.render=function(ci,oa){var Yi,Da;if(arguments[2]!==void 0&&(console.warn("THREE.WebGLRenderer.render(): the renderTarget argument has been removed. Use .setRenderTarget() instead."),Yi=arguments[2]),arguments[3]!==void 0&&(console.warn("THREE.WebGLRenderer.render(): the forceClear argument has been removed. Use .clear() instead."),Da=arguments[3]),oa&&oa.isCamera){if(!fs){Ii.geometry=null,Ii.program=null,Ii.wireframe=!1,Os=-1,!(va=null)===ci.autoUpdate&&ci.updateMatrixWorld(),oa.parent===null&&oa.updateMatrixWorld(),zu.enabled&&zu.isPresenting&&(oa=zu.getCamera(oa)),(On=Ya.get(ci,oa)).init(),ci.onBeforeRender(Ha,ci,oa,Yi||zs),uu.multiplyMatrices(oa.projectionMatrix,oa.matrixWorldInverse),Rl.setFromProjectionMatrix(uu),rh=this.localClippingEnabled,Hu=ou.init(this.clippingPlanes,rh,oa),(En=Ba.get(ci,oa)).init(),function Cs(vo,Yo,rl,dl){if(vo.visible!==!1){if(vo.layers.test(Yo.layers)){if(vo.isGroup)rl=vo.renderOrder;else if(vo.isLOD)vo.autoUpdate===!0&&vo.update(Yo);else if(vo.isLight)On.pushLight(vo),vo.castShadow&&On.pushShadow(vo);else if(vo.isSprite){if(!vo.frustumCulled||Rl.intersectsSprite(vo)){dl&&Ou.setFromMatrixPosition(vo.matrixWorld).applyMatrix4(uu);var us=Sa.update(vo);(D=vo.material).visible&&En.push(vo,us,D,rl,Ou.z,null)}}else if(vo.isImmediateRenderObject)dl&&Ou.setFromMatrixPosition(vo.matrixWorld).applyMatrix4(uu),En.push(vo,null,vo.material,rl,Ou.z,null);else if((vo.isMesh||vo.isLine||vo.isPoints)&&(vo.isSkinnedMesh&&vo.skeleton.frame!==gi.render.frame&&(vo.skeleton.update(),vo.skeleton.frame=gi.render.frame),!vo.frustumCulled||Rl.intersectsObject(vo))){dl&&Ou.setFromMatrixPosition(vo.matrixWorld).applyMatrix4(uu),us=Sa.update(vo);var D=vo.material;if(Array.isArray(D))for(var _=us.groups,k=0,X=_.length;k<X;k++){var de=_[k],Ge=D[de.materialIndex];Ge&&Ge.visible&&En.push(vo,us,Ge,rl,Ou.z,de)}else D.visible&&En.push(vo,us,D,rl,Ou.z,null)}}var ft=vo.children;for(k=0,X=ft.length;k<X;k++)Cs(ft[k],Yo,rl,dl)}}(ci,oa,0,Ha.sortObjects),Ha.sortObjects===!0&&En.sort(Pa,Rs),Hu&&ou.beginShadows();var Na=On.state.shadowsArray;zd.render(Na,ci,oa),On.setupLights(oa),Hu&&ou.endShadows(),this.info.autoReset&&this.info.reset(),Yi!==void 0&&this.setRenderTarget(Yi),zu.enabled&&rd.isAvailable()&&rd.attachCamera(oa),ro.render(En,ci,oa,Da);var xs=En.opaque,ss=En.transparent;if(ci.overrideMaterial){var Ko=ci.overrideMaterial;xs.length&&Am(xs,ci,oa,Ko),ss.length&&Am(ss,ci,oa,Ko)}else xs.length&&Am(xs,ci,oa),ss.length&&Am(ss,ci,oa);ci.onAfterRender(Ha,ci,oa),zs!==null&&($i.updateRenderTargetMipmap(zs),$i.updateMultisampleRenderTarget(zs)),_r.buffers.depth.setTest(!0),_r.buffers.depth.setMask(!0),_r.buffers.color.setMask(!0),_r.setPolygonOffset(!1),zu.enabled&&rd.isAvailable()&&rd.detachCamera(oa),On=En=null}}else console.error("THREE.WebGLRenderer.render: camera is not an instance of THREE.Camera.")},this.mxRenderObject=function(ci,oa,Yi,Da,Na){s3(ci,oa,Yi,Sa.update(ci),Da,Na)},this.setFramebuffer=function(ci){os!==ci&&zs===null&&mn.bindFramebuffer(36160,ci),os=ci},this.getActiveCubeFace=function(){return Ks},this.getActiveMipmapLevel=function(){return Xs},this.getRenderTarget=function(){return zs},this.setRenderTarget=function(ci,oa,Yi){Ks=oa,Xs=Yi,(zs=ci)&&Ci.get(ci).__webglFramebuffer===void 0&&$i.setupRenderTarget(ci);var Da=os,Na=!1;if(ci){var xs=Ci.get(ci).__webglFramebuffer;ci.isWebGLCubeRenderTarget?(Da=xs[oa||0],Na=!0):Da=ci.isWebGLMultisampleRenderTarget?Ci.get(ci).__webglMultisampledFramebuffer:xs,Co.copy(ci.viewport),Cl.copy(ci.scissor),Us=ci.scissorTest}else Co.copy(Ls).multiplyScalar(Dl).floor(),Cl.copy(ml).multiplyScalar(Dl).floor(),Us=ns;if(gl!==Da&&(mn.bindFramebuffer(36160,Da),gl=Da),_r.viewport(Co),_r.scissor(Cl),_r.setScissorTest(Us),Na){var ss=Ci.get(ci.texture);mn.framebufferTexture2D(36160,36064,34069+(oa||0),ss.__webglTexture,Yi||0)}},this.readRenderTargetPixels=function(ci,oa,Yi,Da,Na,xs,ss){if(ci&&ci.isWebGLRenderTarget){var Ko=Ci.get(ci).__webglFramebuffer;if(ci.isWebGLCubeRenderTarget&&ss!==void 0&&(Ko=Ko[ss]),Ko){var Cs=!1;Ko!==gl&&(mn.bindFramebuffer(36160,Ko),Cs=!0);try{var vo=ci.texture,Yo=vo.format,rl=vo.type;if(Yo!==zr&&Qa.convert(Yo)!==mn.getParameter(35739))return void console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in RGBA or implementation defined format.");if(!(rl===so||Qa.convert(rl)===mn.getParameter(35738)||rl===Aa&&(mr.isWebGL2||Hn.get("OES_texture_float")||Hn.get("WEBGL_color_buffer_float"))||rl===Ja&&(mr.isWebGL2?Hn.get("EXT_color_buffer_float"):Hn.get("EXT_color_buffer_half_float"))))return void console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in UnsignedByteType or implementation defined type.");mn.checkFramebufferStatus(36160)===36053?0<=oa&&oa<=ci.width-Da&&0<=Yi&&Yi<=ci.height-Na&&mn.readPixels(oa,Yi,Da,Na,Qa.convert(Yo),Qa.convert(rl),xs):console.error("THREE.WebGLRenderer.readRenderTargetPixels: readPixels from renderTarget failed. Framebuffer not complete.")}finally{Cs&&mn.bindFramebuffer(36160,gl)}}}else console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not THREE.WebGLRenderTarget.")},this.copyFramebufferToTexture=function(ci,oa,Yi){Yi===void 0&&(Yi=0);var Da=Math.pow(2,-Yi),Na=Math.floor(oa.image.width*Da),xs=Math.floor(oa.image.height*Da),ss=Qa.convert(oa.format);$i.setTexture2D(oa,0),mn.copyTexImage2D(3553,Yi,ss,ci.x,ci.y,Na,xs,0),_r.unbindTexture()},this.copyTextureToTexture=function(ci,oa,Yi,Da){var Na=oa.image.width,xs=oa.image.height,ss=Qa.convert(Yi.format),Ko=Qa.convert(Yi.type);$i.setTexture2D(Yi,0),oa.isDataTexture?mn.texSubImage2D(3553,Da||0,ci.x,ci.y,Na,xs,ss,Ko,oa.image.data):mn.texSubImage2D(3553,Da||0,ci.x,ci.y,ss,Ko,oa.image),_r.unbindTexture()},this.initTexture=function(ci){$i.setTexture2D(ci,0),_r.unbindTexture()},typeof __THREE_DEVTOOLS__<"u"&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe",{detail:this}))}function Tc(f,E){this.name="",this.color=new la(f),this.density=E!==void 0?E:25e-5}function $d(f,E,W){this.name="",this.color=new la(f),this.near=E!==void 0?E:1,this.far=W!==void 0?W:1e3}function Vc(f,E){this.array=f,this.stride=E,this.count=f!==void 0?f.length/E:0,this.usage=hl,this.updateRange={offset:0,count:-1},this.version=0}ec.prototype=Object.assign(Object.create(Au.prototype),{constructor:ec,isWebGLMultiviewRenderTarget:!0,copy:function(f){return Au.prototype.copy.call(this,f),this.numViews=f.numViews,this},setNumViews:function(f){return this.numViews!==f&&(this.numViews=f,this.dispose()),this}}),tu.prototype=Object.assign(Object.create(cc.prototype),{constructor:tu,isArrayCamera:!0}),tc.prototype=Object.assign(Object.create(Ri.prototype),{constructor:tc,isGroup:!0}),Object.assign(fd.prototype,Ku.prototype),Object.assign(Tc.prototype,{isFogExp2:!0,clone:function(){return new Tc(this.color,this.density)},toJSON:function(){return{type:"FogExp2",color:this.color.getHex(),density:this.density}}}),Object.assign($d.prototype,{isFog:!0,clone:function(){return new $d(this.color,this.near,this.far)},toJSON:function(){return{type:"Fog",color:this.color.getHex(),near:this.near,far:this.far}}}),Object.defineProperty(Vc.prototype,"needsUpdate",{set:function(f){f===!0&&this.version++}}),Object.assign(Vc.prototype,{isInterleavedBuffer:!0,onUploadCallback:function(){},setUsage:function(f){return this.usage=f,this},copy:function(f){return this.array=new f.array.constructor(f.array),this.count=f.count,this.stride=f.stride,this.usage=f.usage,this},copyAt:function(f,E,W){f*=this.stride,W*=E.stride;for(var ge=0,ct=this.stride;ge<ct;ge++)this.array[f+ge]=E.array[W+ge];return this},set:function(f,E){return E===void 0&&(E=0),this.array.set(f,E),this},clone:function(){return new this.constructor().copy(this)},onUpload:function(f){return this.onUploadCallback=f,this}});var lh,gp=new yi;function jp(f,E,W,ge){this.data=f,this.itemSize=E,this.offset=W,this.normalized=ge===!0}function uh(f){ii.call(this),this.type="SpriteMaterial",this.color=new la(16777215),this.map=null,this.alphaMap=null,this.rotation=0,this.sizeAttenuation=!0,this.transparent=!0,this.setValues(f)}Object.defineProperties(jp.prototype,{count:{get:function(){return this.data.count}},array:{get:function(){return this.data.array}}}),Object.assign(jp.prototype,{isInterleavedBufferAttribute:!0,applyMatrix4:function(f){for(var E=0,W=this.data.count;E<W;E++)gp.x=this.getX(E),gp.y=this.getY(E),gp.z=this.getZ(E),gp.applyMatrix4(f),this.setXYZ(E,gp.x,gp.y,gp.z);return this},setX:function(f,E){return this.data.array[f*this.data.stride+this.offset]=E,this},setY:function(f,E){return this.data.array[f*this.data.stride+this.offset+1]=E,this},setZ:function(f,E){return this.data.array[f*this.data.stride+this.offset+2]=E,this},setW:function(f,E){return this.data.array[f*this.data.stride+this.offset+3]=E,this},getX:function(f){return this.data.array[f*this.data.stride+this.offset]},getY:function(f){return this.data.array[f*this.data.stride+this.offset+1]},getZ:function(f){return this.data.array[f*this.data.stride+this.offset+2]},getW:function(f){return this.data.array[f*this.data.stride+this.offset+3]},setXY:function(f,E,W){return f=f*this.data.stride+this.offset,this.data.array[f+0]=E,this.data.array[f+1]=W,this},setXYZ:function(f,E,W,ge){return f=f*this.data.stride+this.offset,this.data.array[f+0]=E,this.data.array[f+1]=W,this.data.array[f+2]=ge,this},setXYZW:function(f,E,W,ge,ct){return f=f*this.data.stride+this.offset,this.data.array[f+0]=E,this.data.array[f+1]=W,this.data.array[f+2]=ge,this.data.array[f+3]=ct,this}}),((uh.prototype=Object.create(ii.prototype)).constructor=uh).prototype.isSpriteMaterial=!0,uh.prototype.copy=function(f){return ii.prototype.copy.call(this,f),this.color.copy(f.color),this.map=f.map,this.alphaMap=f.alphaMap,this.rotation=f.rotation,this.sizeAttenuation=f.sizeAttenuation,this};var lf=new yi,Hd=new yi,tp=new yi,Gp=new co,Jf=new co,l3=new Vo,wd=new yi,vh=new yi,uf=new yi,T3=new co,Qf=new co,J3=new co;function Lm(f){if(Ri.call(this),this.type="Sprite",lh===void 0){lh=new Ds;var E=new Vc(new Float32Array([-.5,-.5,0,0,0,.5,-.5,0,1,0,.5,.5,0,1,1,-.5,.5,0,0,1]),5);lh.setIndex([0,1,2,0,2,3]),lh.setAttribute("position",new jp(E,3,0,!1)),lh.setAttribute("uv",new jp(E,2,3,!1))}this.geometry=lh,this.material=f!==void 0?f:new uh,this.center=new co(.5,.5)}function u3(f,E,W,ge,ct,gt){Gp.subVectors(f,W).addScalar(.5).multiply(ge),ct!==void 0?(Jf.x=gt*Gp.x-ct*Gp.y,Jf.y=ct*Gp.x+gt*Gp.y):Jf.copy(Gp),f.copy(E),f.x+=Jf.x,f.y+=Jf.y,f.applyMatrix4(l3)}Lm.prototype=Object.assign(Object.create(Ri.prototype),{constructor:Lm,isSprite:!0,raycast:function(f,E){f.camera===null&&console.error('THREE.Sprite: "Raycaster.camera" needs to be set in order to raycast against sprites.'),Hd.setFromMatrixScale(this.matrixWorld),l3.copy(f.camera.matrixWorld),this.modelViewMatrix.multiplyMatrices(f.camera.matrixWorldInverse,this.matrixWorld),tp.setFromMatrixPosition(this.modelViewMatrix),f.camera.isPerspectiveCamera&&this.material.sizeAttenuation===!1&&Hd.multiplyScalar(-tp.z);var W,ge,ct=this.material.rotation;ct!==0&&(ge=Math.cos(ct),W=Math.sin(ct));var gt=this.center;u3(wd.set(-.5,-.5,0),tp,gt,Hd,W,ge),u3(vh.set(.5,-.5,0),tp,gt,Hd,W,ge),u3(uf.set(.5,.5,0),tp,gt,Hd,W,ge),T3.set(0,0),Qf.set(1,0),J3.set(1,1);var St=f.ray.intersectTriangle(wd,vh,uf,!1,lf);if(St!==null||(u3(vh.set(-.5,.5,0),tp,gt,Hd,W,ge),Qf.set(0,1),(St=f.ray.intersectTriangle(wd,uf,vh,!1,lf))!==null)){var Pt=f.ray.origin.distanceTo(lf);Pt<f.near||Pt>f.far||E.push({distance:Pt,point:lf.clone(),uv:qu.getUV(lf,wd,vh,uf,T3,Qf,J3,new co),face:null,object:this})}},clone:function(){return new this.constructor(this.material).copy(this)},copy:function(f){return Ri.prototype.copy.call(this,f),f.center!==void 0&&this.center.copy(f.center),this}});var cf=new yi,kf=new yi;function yp(){Ri.call(this),this.type="LOD",Object.defineProperties(this,{levels:{enumerable:!0,value:[]}}),this.autoUpdate=!0}function _h(f,E){f&&f.isGeometry&&console.error("THREE.SkinnedMesh no longer supports THREE.Geometry. Use THREE.BufferGeometry instead."),lu.call(this,f,E),this.type="SkinnedMesh",this.bindMode="attached",this.bindMatrix=new Vo,this.bindMatrixInverse=new Vo}yp.prototype=Object.assign(Object.create(Ri.prototype),{constructor:yp,isLOD:!0,copy:function(f){Ri.prototype.copy.call(this,f,!1);for(var E=f.levels,W=0,ge=E.length;W<ge;W++){var ct=E[W];this.addLevel(ct.object.clone(),ct.distance)}return this.autoUpdate=f.autoUpdate,this},addLevel:function(f,E){E===void 0&&(E=0),E=Math.abs(E);for(var W=this.levels,ge=0;ge<W.length&&!(E<W[ge].distance);ge++);return W.splice(ge,0,{distance:E,object:f}),this.add(f),this},getObjectForDistance:function(f){var E=this.levels;if(0<E.length){for(var W=1,ge=E.length;W<ge&&!(f<E[W].distance);W++);return E[W-1].object}return null},raycast:function(f,E){if(0<this.levels.length){cf.setFromMatrixPosition(this.matrixWorld);var W=f.ray.origin.distanceTo(cf);this.getObjectForDistance(W).raycast(f,E)}},update:function(f){var E=this.levels;if(1<E.length){cf.setFromMatrixPosition(f.matrixWorld),kf.setFromMatrixPosition(this.matrixWorld);var W=cf.distanceTo(kf);E[0].object.visible=!0;for(var ge=1,ct=E.length;ge<ct&&W>=E[ge].distance;ge++)E[ge-1].object.visible=!1,E[ge].object.visible=!0;for(;ge<ct;ge++)E[ge].object.visible=!1}},toJSON:function(f){var E=Ri.prototype.toJSON.call(this,f);this.autoUpdate===!1&&(E.object.autoUpdate=!1),E.object.levels=[];for(var W=this.levels,ge=0,ct=W.length;ge<ct;ge++){var gt=W[ge];E.object.levels.push({object:gt.object.uuid,distance:gt.distance})}return E}}),_h.prototype=Object.assign(Object.create(lu.prototype),{constructor:_h,isSkinnedMesh:!0,bind:function(f,E){this.skeleton=f,E===void 0&&(this.updateMatrixWorld(!0),this.skeleton.calculateInverses(),E=this.matrixWorld),this.bindMatrix.copy(E),this.bindMatrixInverse.getInverse(E)},pose:function(){this.skeleton.pose()},normalizeSkinWeights:function(){for(var f=new Ll,E=this.geometry.attributes.skinWeight,W=0,ge=E.count;W<ge;W++){f.x=E.getX(W),f.y=E.getY(W),f.z=E.getZ(W),f.w=E.getW(W);var ct=1/f.manhattanLength();ct!=1/0?f.multiplyScalar(ct):f.set(1,0,0,0),E.setXYZW(W,f.x,f.y,f.z,f.w)}},updateMatrixWorld:function(f){lu.prototype.updateMatrixWorld.call(this,f),this.bindMode==="attached"?this.bindMatrixInverse.getInverse(this.matrixWorld):this.bindMode==="detached"?this.bindMatrixInverse.getInverse(this.bindMatrix):console.warn("THREE.SkinnedMesh: Unrecognized bindMode: "+this.bindMode)},clone:function(){return new this.constructor(this.geometry,this.material).copy(this)}});var Nh=new Vo,df=new Vo;function np(f,E){if(f=f||[],this.bones=f.slice(0),this.boneMatrices=new Float32Array(16*this.bones.length),this.frame=-1,E===void 0)this.calculateInverses();else if(this.bones.length===E.length)this.boneInverses=E.slice(0);else{console.warn("THREE.Skeleton boneInverses is the wrong length."),this.boneInverses=[];for(var W=0,ge=this.bones.length;W<ge;W++)this.boneInverses.push(new Vo)}}function Up(){Ri.call(this),this.type="Bone"}Object.assign(np.prototype,{calculateInverses:function(){this.boneInverses=[];for(var f=0,E=this.bones.length;f<E;f++){var W=new Vo;this.bones[f]&&W.getInverse(this.bones[f].matrixWorld),this.boneInverses.push(W)}},pose:function(){var f,E,W;for(E=0,W=this.bones.length;E<W;E++)(f=this.bones[E])&&f.matrixWorld.getInverse(this.boneInverses[E]);for(E=0,W=this.bones.length;E<W;E++)(f=this.bones[E])&&(f.parent&&f.parent.isBone?(f.matrix.getInverse(f.parent.matrixWorld),f.matrix.multiply(f.matrixWorld)):f.matrix.copy(f.matrixWorld),f.matrix.decompose(f.position,f.quaternion,f.scale))},update:function(){for(var f=this.bones,E=this.boneInverses,W=this.boneMatrices,ge=this.boneTexture,ct=0,gt=f.length;ct<gt;ct++){var St=f[ct]?f[ct].matrixWorld:df;Nh.multiplyMatrices(St,E[ct]),Nh.toArray(W,16*ct)}ge!==void 0&&(ge.needsUpdate=!0)},clone:function(){return new np(this.bones,this.boneInverses)},getBoneByName:function(f){for(var E=0,W=this.bones.length;E<W;E++){var ge=this.bones[E];if(ge.name===f)return ge}}}),Up.prototype=Object.assign(Object.create(Ri.prototype),{constructor:Up,isBone:!0});var D3=new Vo,Fm=new Vo,em=[],Bm=new lu;function Vm(f,E,W){lu.call(this,f,E),this.instanceMatrix=new ca(new Float32Array(16*W),16),this.count=W,this.frustumCulled=!1}function Pc(f){ii.call(this),this.type="LineBasicMaterial",this.color=new la(16777215),this.linewidth=1,this.linecap="round",this.linejoin="round",this.setValues(f)}Vm.prototype=Object.assign(Object.create(lu.prototype),{constructor:Vm,isInstancedMesh:!0,getMatrixAt:function(f,E){E.fromArray(this.instanceMatrix.array,16*f)},raycast:function(f,E){var W=this.matrixWorld,ge=this.count;if(Bm.geometry=this.geometry,Bm.material=this.material,Bm.material!==void 0)for(var ct=0;ct<ge;ct++)this.getMatrixAt(ct,D3),Fm.multiplyMatrices(W,D3),Bm.matrixWorld=Fm,Bm.raycast(f,em),0<em.length&&(em[0].instanceId=ct,em[0].object=this,E.push(em[0]),em.length=0)},setMatrixAt:function(f,E){E.toArray(this.instanceMatrix.array,16*f)},updateMorphTargets:function(){}}),((Pc.prototype=Object.create(ii.prototype)).constructor=Pc).prototype.isLineBasicMaterial=!0,Pc.prototype.copy=function(f){return ii.prototype.copy.call(this,f),this.color.copy(f.color),this.linewidth=f.linewidth,this.linecap=f.linecap,this.linejoin=f.linejoin,this};var xh=new yi,E3=new yi,Q3=new Vo,hc=new Hl,Ml=new Nl;function Hc(f,E,W){W===1&&console.error("THREE.Line: parameter THREE.LinePieces no longer supported. Use THREE.LineSegments instead."),Ri.call(this),this.type="Line",this.geometry=f!==void 0?f:new Ds,this.material=E!==void 0?E:new Pc}Hc.prototype=Object.assign(Object.create(Ri.prototype),{constructor:Hc,isLine:!0,computeLineDistances:function(){var f=this.geometry;if(f.isBufferGeometry)if(f.index===null){for(var E=f.attributes.position,W=[0],ge=1,ct=E.count;ge<ct;ge++)xh.fromBufferAttribute(E,ge-1),E3.fromBufferAttribute(E,ge),W[ge]=W[ge-1],W[ge]+=xh.distanceTo(E3);f.setAttribute("lineDistance",new io(W,1))}else console.warn("THREE.Line.computeLineDistances(): Computation only possible with non-indexed BufferGeometry.");else if(f.isGeometry){var gt=f.vertices;for((W=f.lineDistances)[0]=0,ge=1,ct=gt.length;ge<ct;ge++)W[ge]=W[ge-1],W[ge]+=gt[ge-1].distanceTo(gt[ge])}return this},raycast:function(f,E){var W=f.linePrecision,ge=this.geometry,ct=this.matrixWorld;if(ge.boundingSphere===null&&ge.computeBoundingSphere(),Ml.copy(ge.boundingSphere),Ml.applyMatrix4(ct),Ml.radius+=W,f.ray.intersectsSphere(Ml)!==!1){Q3.getInverse(ct),hc.copy(f.ray).applyMatrix4(Q3);var gt=W/((this.scale.x+this.scale.y+this.scale.z)/3),St=gt*gt,Pt=new yi,sn=new yi,ln=new yi,Sn=new yi,En=this&&this.isLineSegments?2:1;if(ge.isBufferGeometry){var On=ge.index,mn=ge.attributes.position.array;if(On!==null)for(var Hn=On.array,mr=0,_r=Hn.length-1;mr<_r;mr+=En){var gi=Hn[mr],Ci=Hn[mr+1];Pt.fromArray(mn,3*gi),sn.fromArray(mn,3*Ci),St<hc.distanceSqToSegment(Pt,sn,Sn,ln)||(Sn.applyMatrix4(this.matrixWorld),(ji=f.ray.origin.distanceTo(Sn))<f.near||ji>f.far||E.push({distance:ji,point:ln.clone().applyMatrix4(this.matrixWorld),index:mr,face:null,faceIndex:null,object:this}))}else for(mr=0,_r=mn.length/3-1;mr<_r;mr+=En)Pt.fromArray(mn,3*mr),sn.fromArray(mn,3*mr+3),St<hc.distanceSqToSegment(Pt,sn,Sn,ln)||(Sn.applyMatrix4(this.matrixWorld),(ji=f.ray.origin.distanceTo(Sn))<f.near||ji>f.far||E.push({distance:ji,point:ln.clone().applyMatrix4(this.matrixWorld),index:mr,face:null,faceIndex:null,object:this}))}else if(ge.isGeometry){var $i=ge.vertices,da=$i.length;for(mr=0;mr<da-1;mr+=En){var ji;St<hc.distanceSqToSegment($i[mr],$i[mr+1],Sn,ln)||(Sn.applyMatrix4(this.matrixWorld),(ji=f.ray.origin.distanceTo(Sn))<f.near||ji>f.far||E.push({distance:ji,point:ln.clone().applyMatrix4(this.matrixWorld),index:mr,face:null,faceIndex:null,object:this}))}}}},clone:function(){return new this.constructor(this.geometry,this.material).copy(this)}});var tm=new yi,_u=new yi;function xc(f,E){Hc.call(this,f,E),this.type="LineSegments"}function Pf(f,E){Hc.call(this,f,E),this.type="LineLoop"}function ch(f){ii.call(this),this.type="PointsMaterial",this.color=new la(16777215),this.map=null,this.alphaMap=null,this.size=1,this.sizeAttenuation=!0,this.morphTargets=!1,this.setValues(f)}xc.prototype=Object.assign(Object.create(Hc.prototype),{constructor:xc,isLineSegments:!0,computeLineDistances:function(){var f=this.geometry;if(f.isBufferGeometry)if(f.index===null){for(var E=f.attributes.position,W=[],ge=0,ct=E.count;ge<ct;ge+=2)tm.fromBufferAttribute(E,ge),_u.fromBufferAttribute(E,ge+1),W[ge]=ge===0?0:W[ge-1],W[ge+1]=W[ge]+tm.distanceTo(_u);f.setAttribute("lineDistance",new io(W,1))}else console.warn("THREE.LineSegments.computeLineDistances(): Computation only possible with non-indexed BufferGeometry.");else if(f.isGeometry){var gt=f.vertices;for(W=f.lineDistances,ge=0,ct=gt.length;ge<ct;ge+=2)tm.copy(gt[ge]),_u.copy(gt[ge+1]),W[ge]=ge===0?0:W[ge-1],W[ge+1]=W[ge]+tm.distanceTo(_u)}return this}}),Pf.prototype=Object.assign(Object.create(Hc.prototype),{constructor:Pf,isLineLoop:!0}),((ch.prototype=Object.create(ii.prototype)).constructor=ch).prototype.isPointsMaterial=!0,ch.prototype.copy=function(f){return ii.prototype.copy.call(this,f),this.color.copy(f.color),this.map=f.map,this.alphaMap=f.alphaMap,this.size=f.size,this.sizeAttenuation=f.sizeAttenuation,this.morphTargets=f.morphTargets,this};var $p=new Vo,Hp=new Hl,Wd=new Nl,ed=new yi;function If(f,E){Ri.call(this),this.type="Points",this.geometry=f!==void 0?f:new Ds,this.material=E!==void 0?E:new ch,this.updateMorphTargets()}function Jd(f,E,W,ge,ct,gt,St){var Pt=Hp.distanceSqToPoint(f);if(Pt<W){var sn=new yi;Hp.closestPointToPoint(f,sn),sn.applyMatrix4(ge);var ln=ct.ray.origin.distanceTo(sn);if(ln<ct.near||ln>ct.far)return;gt.push({distance:ln,distanceToRay:Math.sqrt(Pt),point:sn,index:E,face:null,object:St})}}function Wp(f,E,W,ge,ct,gt,St,Pt,sn){Ql.call(this,f,E,W,ge,ct,gt,St,Pt,sn),this.format=St!==void 0?St:il,this.minFilter=gt!==void 0?gt:hi,this.magFilter=ct!==void 0?ct:hi,this.generateMipmaps=!1}function nm(f,E,W,ge,ct,gt,St,Pt,sn,ln,Sn,En){Ql.call(this,null,gt,St,Pt,sn,ln,ge,ct,Sn,En),this.image={width:E,height:W},this.mipmaps=f,this.flipY=!1,this.generateMipmaps=!1}function Nm(f,E,W,ge,ct,gt,St,Pt,sn){Ql.call(this,f,E,W,ge,ct,gt,St,Pt,sn),this.needsUpdate=!0}function rm(f,E,W,ge,ct,gt,St,Pt,sn,ln){if((ln=ln!==void 0?ln:ni)!==ni&&ln!==Ei)throw new Error("DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat");W===void 0&&ln===ni&&(W=Ni),W===void 0&&ln===Ei&&(W=_o),Ql.call(this,null,ge,ct,gt,St,Pt,ln,W,sn),this.image={width:f,height:E},this.magFilter=St!==void 0?St:un,this.minFilter=Pt!==void 0?Pt:un,this.flipY=!1,this.generateMipmaps=!1}function im(f){Ds.call(this),this.type="WireframeGeometry";var E,W,ge,ct,gt,St,Pt,sn,ln,Sn,En=[],On=[0,0],mn={},Hn=["a","b","c"];if(f&&f.isGeometry){var mr=f.faces;for(E=0,ge=mr.length;E<ge;E++){var _r=mr[E];for(W=0;W<3;W++)Pt=_r[Hn[W]],sn=_r[Hn[(W+1)%3]],On[0]=Math.min(Pt,sn),On[1]=Math.max(Pt,sn),mn[ln=On[0]+","+On[1]]===void 0&&(mn[ln]={index1:On[0],index2:On[1]})}for(ln in mn)St=mn[ln],Sn=f.vertices[St.index1],En.push(Sn.x,Sn.y,Sn.z),Sn=f.vertices[St.index2],En.push(Sn.x,Sn.y,Sn.z)}else if(f&&f.isBufferGeometry){var gi,Ci,$i,da,ji,Sa;if(Sn=new yi,f.index!==null){for(gi=f.attributes.position,Ci=f.index,($i=f.groups).length===0&&($i=[{start:0,count:Ci.count,materialIndex:0}]),ct=0,gt=$i.length;ct<gt;++ct)for(ge=(E=(da=$i[ct]).start)+da.count;E<ge;E+=3)for(W=0;W<3;W++)Pt=Ci.getX(E+W),sn=Ci.getX(E+(W+1)%3),On[0]=Math.min(Pt,sn),On[1]=Math.max(Pt,sn),mn[ln=On[0]+","+On[1]]===void 0&&(mn[ln]={index1:On[0],index2:On[1]});for(ln in mn)St=mn[ln],Sn.fromBufferAttribute(gi,St.index1),En.push(Sn.x,Sn.y,Sn.z),Sn.fromBufferAttribute(gi,St.index2),En.push(Sn.x,Sn.y,Sn.z)}else for(E=0,ge=(gi=f.attributes.position).count/3;E<ge;E++)for(W=0;W<3;W++)ji=3*E+W,Sn.fromBufferAttribute(gi,ji),En.push(Sn.x,Sn.y,Sn.z),Sa=3*E+(W+1)%3,Sn.fromBufferAttribute(gi,Sa),En.push(Sn.x,Sn.y,Sn.z)}this.setAttribute("position",new io(En,3))}function dh(f,E,W){ul.call(this),this.type="ParametricGeometry",this.parameters={func:f,slices:E,stacks:W},this.fromBufferGeometry(new bh(f,E,W)),this.mergeVertices()}function bh(f,E,W){Ds.call(this),this.type="ParametricBufferGeometry",this.parameters={func:f,slices:E,stacks:W};var ge,ct,gt=[],St=[],Pt=[],sn=[],ln=new yi,Sn=new yi,En=new yi,On=new yi,mn=new yi;f.length<3&&console.error("THREE.ParametricGeometry: Function must now modify a Vector3 as third parameter.");var Hn=E+1;for(ge=0;ge<=W;ge++){var mr=ge/W;for(ct=0;ct<=E;ct++){var _r=ct/E;f(_r,mr,Sn),St.push(Sn.x,Sn.y,Sn.z),0<=_r-1e-5?(f(_r-1e-5,mr,En),On.subVectors(Sn,En)):(f(1e-5+_r,mr,En),On.subVectors(En,Sn)),0<=mr-1e-5?(f(_r,mr-1e-5,En),mn.subVectors(Sn,En)):(f(_r,1e-5+mr,En),mn.subVectors(En,Sn)),ln.crossVectors(On,mn).normalize(),Pt.push(ln.x,ln.y,ln.z),sn.push(_r,mr)}}for(ge=0;ge<W;ge++)for(ct=0;ct<E;ct++){var gi=ge*Hn+ct,Ci=ge*Hn+ct+1,$i=(ge+1)*Hn+ct+1,da=(ge+1)*Hn+ct;gt.push(gi,Ci,da),gt.push(Ci,$i,da)}this.setIndex(gt),this.setAttribute("position",new io(St,3)),this.setAttribute("normal",new io(Pt,3)),this.setAttribute("uv",new io(sn,2))}function vp(f,E,W,ge){ul.call(this),this.type="PolyhedronGeometry",this.parameters={vertices:f,indices:E,radius:W,detail:ge},this.fromBufferGeometry(new Yc(f,E,W,ge)),this.mergeVertices()}function Yc(f,E,W,ge){Ds.call(this),this.type="PolyhedronBufferGeometry",this.parameters={vertices:f,indices:E,radius:W,detail:ge},W=W||1;var ct=[],gt=[];function St(En,On,mn,Hn){var mr,_r,gi=Math.pow(2,Hn),Ci=[];for(mr=0;mr<=gi;mr++){Ci[mr]=[];var $i=En.clone().lerp(mn,mr/gi),da=On.clone().lerp(mn,mr/gi),ji=gi-mr;for(_r=0;_r<=ji;_r++)Ci[mr][_r]=_r===0&&mr===gi?$i:$i.clone().lerp(da,_r/ji)}for(mr=0;mr<gi;mr++)for(_r=0;_r<2*(gi-mr)-1;_r++){var Sa=Math.floor(_r/2);_r%2==0?(Pt(Ci[mr][Sa+1]),Pt(Ci[mr+1][Sa]),Pt(Ci[mr][Sa])):(Pt(Ci[mr][Sa+1]),Pt(Ci[mr+1][Sa+1]),Pt(Ci[mr+1][Sa]))}}function Pt(En){ct.push(En.x,En.y,En.z)}function sn(En,On){var mn=3*En;On.x=f[0+mn],On.y=f[1+mn],On.z=f[2+mn]}function ln(En,On,mn,Hn){Hn<0&&En.x===1&&(gt[On]=En.x-1),mn.x===0&&mn.z===0&&(gt[On]=Hn/2/Math.PI+.5)}function Sn(En){return Math.atan2(En.z,-En.x)}(function(En){for(var On=new yi,mn=new yi,Hn=new yi,mr=0;mr<E.length;mr+=3)sn(E[mr+0],On),sn(E[mr+1],mn),sn(E[mr+2],Hn),St(On,mn,Hn,En)})(ge=ge||0),function(En){for(var On=new yi,mn=0;mn<ct.length;mn+=3)On.x=ct[mn+0],On.y=ct[mn+1],On.z=ct[mn+2],On.normalize().multiplyScalar(En),ct[mn+0]=On.x,ct[mn+1]=On.y,ct[mn+2]=On.z}(W),function(){for(var En=new yi,On=0;On<ct.length;On+=3){En.x=ct[On+0],En.y=ct[On+1],En.z=ct[On+2];var mn=Sn(En)/2/Math.PI+.5,Hn=(mr=En,Math.atan2(-mr.y,Math.sqrt(mr.x*mr.x+mr.z*mr.z))/Math.PI+.5);gt.push(mn,1-Hn)}var mr;(function(){for(var _r=new yi,gi=new yi,Ci=new yi,$i=new yi,da=new co,ji=new co,Sa=new co,ea=0,Ba=0;ea<ct.length;ea+=9,Ba+=6){_r.set(ct[ea+0],ct[ea+1],ct[ea+2]),gi.set(ct[ea+3],ct[ea+4],ct[ea+5]),Ci.set(ct[ea+6],ct[ea+7],ct[ea+8]),da.set(gt[Ba+0],gt[Ba+1]),ji.set(gt[Ba+2],gt[Ba+3]),Sa.set(gt[Ba+4],gt[Ba+5]),$i.copy(_r).add(gi).add(Ci).divideScalar(3);var Ya=Sn($i);ln(da,Ba+0,_r,Ya),ln(ji,Ba+2,gi,Ya),ln(Sa,Ba+4,Ci,Ya)}})(),function(){for(var _r=0;_r<gt.length;_r+=6){var gi=gt[_r+0],Ci=gt[_r+2],$i=gt[_r+4],da=Math.max(gi,Ci,$i),ji=Math.min(gi,Ci,$i);.9<da&&ji<.1&&(gi<.2&&(gt[_r+0]+=1),Ci<.2&&(gt[_r+2]+=1),$i<.2&&(gt[_r+4]+=1))}}()}(),this.setAttribute("position",new io(ct,3)),this.setAttribute("normal",new io(ct.slice(),3)),this.setAttribute("uv",new io(gt,2)),ge===0?this.computeVertexNormals():this.normalizeNormals()}function kl(f,E){ul.call(this),this.type="TetrahedronGeometry",this.parameters={radius:f,detail:E},this.fromBufferGeometry(new Rf(f,E)),this.mergeVertices()}function Rf(f,E){Yc.call(this,[1,1,1,-1,-1,1,-1,1,-1,1,-1,-1],[2,1,0,0,3,2,1,3,0,2,3,1],f,E),this.type="TetrahedronBufferGeometry",this.parameters={radius:f,detail:E}}function Md(f,E){ul.call(this),this.type="OctahedronGeometry",this.parameters={radius:f,detail:E},this.fromBufferGeometry(new Dc(f,E)),this.mergeVertices()}function Dc(f,E){Yc.call(this,[1,0,0,-1,0,0,0,1,0,0,-1,0,0,0,1,0,0,-1],[0,2,4,0,4,3,0,3,5,0,5,2,1,2,5,1,5,3,1,3,4,1,4,2],f,E),this.type="OctahedronBufferGeometry",this.parameters={radius:f,detail:E}}function zh(f,E){ul.call(this),this.type="IcosahedronGeometry",this.parameters={radius:f,detail:E},this.fromBufferGeometry(new zm(f,E)),this.mergeVertices()}function zm(f,E){var W=(1+Math.sqrt(5))/2;Yc.call(this,[-1,W,0,1,W,0,-1,-W,0,1,-W,0,0,-1,W,0,1,W,0,-1,-W,0,1,-W,W,0,-1,W,0,1,-W,0,-1,-W,0,1],[0,11,5,0,5,1,0,1,7,0,7,10,0,10,11,1,5,9,5,11,4,11,10,2,10,7,6,7,1,8,3,9,4,3,4,2,3,2,6,3,6,8,3,8,9,4,9,5,2,4,11,6,2,10,8,6,7,9,8,1],f,E),this.type="IcosahedronBufferGeometry",this.parameters={radius:f,detail:E}}function hf(f,E){ul.call(this),this.type="DodecahedronGeometry",this.parameters={radius:f,detail:E},this.fromBufferGeometry(new wh(f,E)),this.mergeVertices()}function wh(f,E){var W=(1+Math.sqrt(5))/2,ge=1/W;Yc.call(this,[-1,-1,-1,-1,-1,1,-1,1,-1,-1,1,1,1,-1,-1,1,-1,1,1,1,-1,1,1,1,0,-ge,-W,0,-ge,W,0,ge,-W,0,ge,W,-ge,-W,0,-ge,W,0,ge,-W,0,ge,W,0,-W,0,-ge,W,0,-ge,-W,0,ge,W,0,ge],[3,11,7,3,7,15,3,15,13,7,19,17,7,17,6,7,6,15,17,4,8,17,8,10,17,10,6,8,0,16,8,16,2,8,2,10,0,12,1,0,1,18,0,18,16,6,10,2,6,2,13,6,13,15,2,16,18,2,18,3,2,3,13,18,1,9,18,9,11,18,11,3,4,14,12,4,12,0,4,0,8,11,9,5,11,5,19,11,19,7,19,5,14,19,14,4,19,4,17,1,12,14,1,14,5,1,5,9],f,E),this.type="DodecahedronBufferGeometry",this.parameters={radius:f,detail:E}}function Of(f,E,W,ge,ct,gt){ul.call(this),this.type="TubeGeometry",this.parameters={path:f,tubularSegments:E,radius:W,radialSegments:ge,closed:ct},gt!==void 0&&console.warn("THREE.TubeGeometry: taper has been removed.");var St=new qp(f,E,W,ge,ct);this.tangents=St.tangents,this.normals=St.normals,this.binormals=St.binormals,this.fromBufferGeometry(St),this.mergeVertices()}function qp(f,E,W,ge,ct){Ds.call(this),this.type="TubeBufferGeometry",this.parameters={path:f,tubularSegments:E,radius:W,radialSegments:ge,closed:ct},E=E||64,W=W||1,ge=ge||8,ct=ct||!1;var gt=f.computeFrenetFrames(E,ct);this.tangents=gt.tangents,this.normals=gt.normals,this.binormals=gt.binormals;var St,Pt,sn=new yi,ln=new yi,Sn=new co,En=new yi,On=[],mn=[],Hn=[],mr=[];function _r(gi){En=f.getPointAt(gi/E,En);var Ci=gt.normals[gi],$i=gt.binormals[gi];for(Pt=0;Pt<=ge;Pt++){var da=Pt/ge*Math.PI*2,ji=Math.sin(da),Sa=-Math.cos(da);ln.x=Sa*Ci.x+ji*$i.x,ln.y=Sa*Ci.y+ji*$i.y,ln.z=Sa*Ci.z+ji*$i.z,ln.normalize(),mn.push(ln.x,ln.y,ln.z),sn.x=En.x+W*ln.x,sn.y=En.y+W*ln.y,sn.z=En.z+W*ln.z,On.push(sn.x,sn.y,sn.z)}}(function(){for(St=0;St<E;St++)_r(St);_r(ct===!1?E:0),function(){for(St=0;St<=E;St++)for(Pt=0;Pt<=ge;Pt++)Sn.x=St/E,Sn.y=Pt/ge,Hn.push(Sn.x,Sn.y)}(),function(){for(Pt=1;Pt<=E;Pt++)for(St=1;St<=ge;St++){var gi=(ge+1)*(Pt-1)+(St-1),Ci=(ge+1)*Pt+(St-1),$i=(ge+1)*Pt+St,da=(ge+1)*(Pt-1)+St;mr.push(gi,Ci,da),mr.push(Ci,$i,da)}}()})(),this.setIndex(mr),this.setAttribute("position",new io(On,3)),this.setAttribute("normal",new io(mn,3)),this.setAttribute("uv",new io(Hn,2))}function bc(f,E,W,ge,ct,gt,St){ul.call(this),this.type="TorusKnotGeometry",this.parameters={radius:f,tube:E,tubularSegments:W,radialSegments:ge,p:ct,q:gt},St!==void 0&&console.warn("THREE.TorusKnotGeometry: heightScale has been deprecated. Use .scale( x, y, z ) instead."),this.fromBufferGeometry(new $u(f,E,W,ge,ct,gt)),this.mergeVertices()}function $u(f,E,W,ge,ct,gt){Ds.call(this),this.type="TorusKnotBufferGeometry",this.parameters={radius:f,tube:E,tubularSegments:W,radialSegments:ge,p:ct,q:gt},f=f||1,E=E||.4,W=Math.floor(W)||64,ge=Math.floor(ge)||8,ct=ct||2,gt=gt||3;var St,Pt,sn=[],ln=[],Sn=[],En=[],On=new yi,mn=new yi,Hn=new yi,mr=new yi,_r=new yi,gi=new yi,Ci=new yi;for(St=0;St<=W;++St){var $i=St/W*ct*Math.PI*2;for($a($i,ct,gt,f,Hn),$a(.01+$i,ct,gt,f,mr),gi.subVectors(mr,Hn),Ci.addVectors(mr,Hn),_r.crossVectors(gi,Ci),Ci.crossVectors(_r,gi),_r.normalize(),Ci.normalize(),Pt=0;Pt<=ge;++Pt){var da=Pt/ge*Math.PI*2,ji=-E*Math.cos(da),Sa=E*Math.sin(da);On.x=Hn.x+(ji*Ci.x+Sa*_r.x),On.y=Hn.y+(ji*Ci.y+Sa*_r.y),On.z=Hn.z+(ji*Ci.z+Sa*_r.z),ln.push(On.x,On.y,On.z),mn.subVectors(On,Hn).normalize(),Sn.push(mn.x,mn.y,mn.z),En.push(St/W),En.push(Pt/ge)}}for(Pt=1;Pt<=W;Pt++)for(St=1;St<=ge;St++){var ea=(ge+1)*(Pt-1)+(St-1),Ba=(ge+1)*Pt+(St-1),Ya=(ge+1)*Pt+St,ro=(ge+1)*(Pt-1)+St;sn.push(ea,Ba,ro),sn.push(Ba,Ya,ro)}function $a(go,ko,Qa,Ha,fs){var os=Math.cos(go),Ks=Math.sin(go),Xs=Qa/ko*go,zs=Math.cos(Xs);fs.x=Ha*(2+zs)*.5*os,fs.y=Ha*(2+zs)*Ks*.5,fs.z=Ha*Math.sin(Xs)*.5}this.setIndex(sn),this.setAttribute("position",new io(ln,3)),this.setAttribute("normal",new io(Sn,3)),this.setAttribute("uv",new io(En,2))}function am(f,E,W,ge,ct){ul.call(this),this.type="TorusGeometry",this.parameters={radius:f,tube:E,radialSegments:W,tubularSegments:ge,arc:ct},this.fromBufferGeometry(new om(f,E,W,ge,ct)),this.mergeVertices()}function om(f,E,W,ge,ct){Ds.call(this),this.type="TorusBufferGeometry",this.parameters={radius:f,tube:E,radialSegments:W,tubularSegments:ge,arc:ct},f=f||1,E=E||.4,W=Math.floor(W)||8,ge=Math.floor(ge)||6,ct=ct||2*Math.PI;var gt,St,Pt=[],sn=[],ln=[],Sn=[],En=new yi,On=new yi,mn=new yi;for(gt=0;gt<=W;gt++)for(St=0;St<=ge;St++){var Hn=St/ge*ct,mr=gt/W*Math.PI*2;On.x=(f+E*Math.cos(mr))*Math.cos(Hn),On.y=(f+E*Math.cos(mr))*Math.sin(Hn),On.z=E*Math.sin(mr),sn.push(On.x,On.y,On.z),En.x=f*Math.cos(Hn),En.y=f*Math.sin(Hn),mn.subVectors(On,En).normalize(),ln.push(mn.x,mn.y,mn.z),Sn.push(St/ge),Sn.push(gt/W)}for(gt=1;gt<=W;gt++)for(St=1;St<=ge;St++){var _r=(ge+1)*gt+St-1,gi=(ge+1)*(gt-1)+St-1,Ci=(ge+1)*(gt-1)+St,$i=(ge+1)*gt+St;Pt.push(_r,gi,$i),Pt.push(gi,Ci,$i)}this.setIndex(Pt),this.setAttribute("position",new io(sn,3)),this.setAttribute("normal",new io(ln,3)),this.setAttribute("uv",new io(Sn,2))}function rp(f,E,W,ge,ct){var gt,St;if(ct===0<function(Pt,sn,ln,Sn){for(var En=0,On=sn,mn=ln-Sn;On<ln;On+=Sn)En+=(Pt[mn]-Pt[On])*(Pt[On+1]+Pt[mn+1]),mn=On;return En}(f,E,W,ge))for(gt=E;gt<W;gt+=ge)St=lm(gt,f[gt],f[gt+1],St);else for(gt=W-ge;E<=gt;gt-=ge)St=lm(gt,f[gt],f[gt+1],St);return St&&xp(St,St.next)&&(um(St),St=St.next),St}function _p(f,E){if(!f)return f;E=E||f;var W,ge=f;do if(W=!1,ge.steiner||!xp(ge,ge.next)&&Cu(ge.prev,ge,ge.next)!==0)ge=ge.next;else{if(um(ge),(ge=E=ge.prev)===ge.next)break;W=!0}while(W||ge!==E);return E}function Lf(f,E,W,ge,ct,gt,St){if(f){!St&>&&function(Sn,En,On,mn){for(var Hn=Sn;Hn.z===null&&(Hn.z=ld(Hn.x,Hn.y,En,On,mn)),Hn.prevZ=Hn.prev,Hn.nextZ=Hn.next,(Hn=Hn.next)!==Sn;);Hn.prevZ.nextZ=null,Hn.prevZ=null,function(mr){var _r,gi,Ci,$i,da,ji,Sa,ea,Ba=1;do{for(gi=mr,da=mr=null,ji=0;gi;){for(ji++,Ci=gi,_r=Sa=0;_r<Ba&&(Sa++,Ci=Ci.nextZ);_r++);for(ea=Ba;0<Sa||0<ea&&Ci;)Sa!==0&&(ea===0||!Ci||gi.z<=Ci.z)?(gi=($i=gi).nextZ,Sa--):(Ci=($i=Ci).nextZ,ea--),da?da.nextZ=$i:mr=$i,$i.prevZ=da,da=$i;gi=Ci}da.nextZ=null,Ba*=2}while(1<ji)}(Hn)}(f,ge,ct,gt);for(var Pt,sn,ln=f;f.prev!==f.next;)if(Pt=f.prev,sn=f.next,gt?Mh(f,ge,ct,gt):jm(f))E.push(Pt.i/W),E.push(f.i/W),E.push(sn.i/W),um(f),f=sn.next,ln=sn.next;else if((f=sn)===ln){St?St===1?Lf(f=sm(f,E,W),E,W,ge,ct,gt,2):St===2&&A3(f,E,W,ge,ct,gt):Lf(_p(f),E,W,ge,ct,gt,1);break}}}function jm(f){var E=f.prev,W=f,ge=f.next;if(!(0<=Cu(E,W,ge))){for(var ct=f.next.next;ct!==f.prev;){if(Ch(E.x,E.y,W.x,W.y,ge.x,ge.y,ct.x,ct.y)&&0<=Cu(ct.prev,ct,ct.next))return;ct=ct.next}return 1}}function Mh(f,E,W,ge){var ct=f.prev,gt=f,St=f.next;if(!(0<=Cu(ct,gt,St))){for(var Pt=ct.x<gt.x?ct.x<St.x?ct.x:St.x:gt.x<St.x?gt.x:St.x,sn=ct.y<gt.y?ct.y<St.y?ct.y:St.y:gt.y<St.y?gt.y:St.y,ln=ct.x>gt.x?ct.x>St.x?ct.x:St.x:gt.x>St.x?gt.x:St.x,Sn=ct.y>gt.y?ct.y>St.y?ct.y:St.y:gt.y>St.y?gt.y:St.y,En=ld(Pt,sn,E,W,ge),On=ld(ln,Sn,E,W,ge),mn=f.prevZ,Hn=f.nextZ;mn&&mn.z>=En&&Hn&&Hn.z<=On;){if(mn!==f.prev&&mn!==f.next&&Ch(ct.x,ct.y,gt.x,gt.y,St.x,St.y,mn.x,mn.y)&&0<=Cu(mn.prev,mn,mn.next)||(mn=mn.prevZ,Hn!==f.prev&&Hn!==f.next&&Ch(ct.x,ct.y,gt.x,gt.y,St.x,St.y,Hn.x,Hn.y)&&0<=Cu(Hn.prev,Hn,Hn.next)))return;Hn=Hn.nextZ}for(;mn&&mn.z>=En;){if(mn!==f.prev&&mn!==f.next&&Ch(ct.x,ct.y,gt.x,gt.y,St.x,St.y,mn.x,mn.y)&&0<=Cu(mn.prev,mn,mn.next))return;mn=mn.prevZ}for(;Hn&&Hn.z<=On;){if(Hn!==f.prev&&Hn!==f.next&&Ch(ct.x,ct.y,gt.x,gt.y,St.x,St.y,Hn.x,Hn.y)&&0<=Cu(Hn.prev,Hn,Hn.next))return;Hn=Hn.nextZ}return 1}}function sm(f,E,W){var ge=f;do{var ct=ge.prev,gt=ge.next.next;!xp(ct,gt)&&Ru(ct,ge,ge.next,gt)&&Gm(ct,gt)&&Gm(gt,ct)&&(E.push(ct.i/W),E.push(ge.i/W),E.push(gt.i/W),um(ge),um(ge.next),ge=f=gt),ge=ge.next}while(ge!==f);return ge}function A3(f,E,W,ge,ct,gt){var St,Pt,sn=f;do{for(var ln=sn.next.next;ln!==sn.prev;){if(sn.i!==ln.i&&(Pt=ln,(St=sn).next.i!==Pt.i&&St.prev.i!==Pt.i&&!function(En,On){var mn=En;do{if(mn.i!==En.i&&mn.next.i!==En.i&&mn.i!==On.i&&mn.next.i!==On.i&&Ru(mn,mn.next,En,On))return 1;mn=mn.next}while(mn!==En)}(St,Pt)&&Gm(St,Pt)&&Gm(Pt,St)&&function(En,On){for(var mn=En,Hn=!1,mr=(En.x+On.x)/2,_r=(En.y+On.y)/2;mn.y>_r!=mn.next.y>_r&&mn.next.y!==mn.y&&mr<(mn.next.x-mn.x)*(_r-mn.y)/(mn.next.y-mn.y)+mn.x&&(Hn=!Hn),(mn=mn.next)!==En;);return Hn}(St,Pt))){var Sn=Um(sn,ln);return sn=_p(sn,sn.next),Sn=_p(Sn,Sn.next),Lf(sn,E,W,ge,ct,gt),void Lf(Sn,E,W,ge,ct,gt)}ln=ln.next}sn=sn.next}while(sn!==f)}function hh(f,E){return f.x-E.x}function k3(f,E){if(E=function(ge,ct){var gt,St=ct,Pt=ge.x,sn=ge.y,ln=-1/0;do{if(sn<=St.y&&sn>=St.next.y&&St.next.y!==St.y){var Sn=St.x+(sn-St.y)*(St.next.x-St.x)/(St.next.y-St.y);if(Sn<=Pt&&ln<Sn){if((ln=Sn)===Pt){if(sn===St.y)return St;if(sn===St.next.y)return St.next}gt=St.x<St.next.x?St:St.next}}St=St.next}while(St!==ct);if(!gt)return null;if(Pt===ln)return gt.prev;var En,On=gt,mn=gt.x,Hn=gt.y,mr=1/0;for(St=gt.next;St!==On;)Pt>=St.x&&St.x>=mn&&Pt!==St.x&&Ch(sn<Hn?Pt:ln,sn,mn,Hn,sn<Hn?ln:Pt,sn,St.x,St.y)&&((En=Math.abs(sn-St.y)/(Pt-St.x))<mr||En===mr&&St.x>gt.x)&&Gm(St,ge)&&(gt=St,mr=En),St=St.next;return gt}(f,E)){var W=Um(E,f);_p(W,W.next)}}function ld(f,E,W,ge,ct){return(f=1431655765&((f=858993459&((f=252645135&((f=16711935&((f=32767*(f-W)*ct)|f<<8))|f<<4))|f<<2))|f<<1))|(E=1431655765&((E=858993459&((E=252645135&((E=16711935&((E=32767*(E-ge)*ct)|E<<8))|E<<4))|E<<2))|E<<1))<<1}function Zl(f){for(var E=f,W=f;(E.x<W.x||E.x===W.x&&E.y<W.y)&&(W=E),(E=E.next)!==f;);return W}function Ch(f,E,W,ge,ct,gt,St,Pt){return 0<=(ct-St)*(E-Pt)-(f-St)*(gt-Pt)&&0<=(f-St)*(ge-Pt)-(W-St)*(E-Pt)&&0<=(W-St)*(gt-Pt)-(ct-St)*(ge-Pt)}function Cu(f,E,W){return(E.y-f.y)*(W.x-E.x)-(E.x-f.x)*(W.y-E.y)}function xp(f,E){return f.x===E.x&&f.y===E.y}function Ru(f,E,W,ge){return xp(f,W)&&xp(E,ge)||xp(f,ge)&&xp(W,E)||0<Cu(f,E,W)!=0<Cu(f,E,ge)&&0<Cu(W,ge,f)!=0<Cu(W,ge,E)}function Gm(f,E){return Cu(f.prev,f,f.next)<0?0<=Cu(f,E,f.next)&&0<=Cu(f,f.prev,E):Cu(f,E,f.prev)<0||Cu(f,f.next,E)<0}function Um(f,E){var W=new Ff(f.i,f.x,f.y),ge=new Ff(E.i,E.x,E.y),ct=f.next,gt=E.prev;return(f.next=E).prev=f,(W.next=ct).prev=W,(ge.next=W).prev=ge,(gt.next=ge).prev=gt,ge}function lm(f,E,W,ge){var ct=new Ff(f,E,W);return ge?(ct.next=ge.next,(ct.prev=ge).next.prev=ct,ge.next=ct):(ct.prev=ct).next=ct,ct}function um(f){f.next.prev=f.prev,f.prev.next=f.next,f.prevZ&&(f.prevZ.nextZ=f.nextZ),f.nextZ&&(f.nextZ.prevZ=f.prevZ)}function Ff(f,E,W){this.i=f,this.x=E,this.y=W,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}If.prototype=Object.assign(Object.create(Ri.prototype),{constructor:If,isPoints:!0,raycast:function(f,E){var W=this.geometry,ge=this.matrixWorld,ct=f.params.Points.threshold;if(W.boundingSphere===null&&W.computeBoundingSphere(),Wd.copy(W.boundingSphere),Wd.applyMatrix4(ge),Wd.radius+=ct,f.ray.intersectsSphere(Wd)!==!1){$p.getInverse(ge),Hp.copy(f.ray).applyMatrix4($p);var gt=ct/((this.scale.x+this.scale.y+this.scale.z)/3),St=gt*gt;if(W.isBufferGeometry){var Pt=W.index,sn=W.attributes.position.array;if(Pt!==null)for(var ln=Pt.array,Sn=0,En=ln.length;Sn<En;Sn++){var On=ln[Sn];ed.fromArray(sn,3*On),Jd(ed,On,St,ge,f,E,this)}else{Sn=0;for(var mn=sn.length/3;Sn<mn;Sn++)ed.fromArray(sn,3*Sn),Jd(ed,Sn,St,ge,f,E,this)}}else{var Hn=W.vertices;for(Sn=0,mn=Hn.length;Sn<mn;Sn++)Jd(Hn[Sn],Sn,St,ge,f,E,this)}}},updateMorphTargets:function(){var f,E,W,ge=this.geometry;if(ge.isBufferGeometry){var ct=ge.morphAttributes,gt=Object.keys(ct);if(0<gt.length){var St=ct[gt[0]];if(St!==void 0)for(this.morphTargetInfluences=[],this.morphTargetDictionary={},f=0,E=St.length;f<E;f++)W=St[f].name||String(f),this.morphTargetInfluences.push(0),this.morphTargetDictionary[W]=f}}else{var Pt=ge.morphTargets;Pt!==void 0&&0<Pt.length&&console.error("THREE.Points.updateMorphTargets() does not support THREE.Geometry. Use THREE.BufferGeometry instead.")}},clone:function(){return new this.constructor(this.geometry,this.material).copy(this)}}),Wp.prototype=Object.assign(Object.create(Ql.prototype),{constructor:Wp,isVideoTexture:!0,update:function(){var f=this.image;f.readyState>=f.HAVE_CURRENT_DATA&&(this.needsUpdate=!0)}}),((nm.prototype=Object.create(Ql.prototype)).constructor=nm).prototype.isCompressedTexture=!0,((Nm.prototype=Object.create(Ql.prototype)).constructor=Nm).prototype.isCanvasTexture=!0,((rm.prototype=Object.create(Ql.prototype)).constructor=rm).prototype.isDepthTexture=!0,(im.prototype=Object.create(Ds.prototype)).constructor=im,(dh.prototype=Object.create(ul.prototype)).constructor=dh,(bh.prototype=Object.create(Ds.prototype)).constructor=bh,(vp.prototype=Object.create(ul.prototype)).constructor=vp,(Yc.prototype=Object.create(Ds.prototype)).constructor=Yc,(kl.prototype=Object.create(ul.prototype)).constructor=kl,(Rf.prototype=Object.create(Yc.prototype)).constructor=Rf,(Md.prototype=Object.create(ul.prototype)).constructor=Md,(Dc.prototype=Object.create(Yc.prototype)).constructor=Dc,(zh.prototype=Object.create(ul.prototype)).constructor=zh,(zm.prototype=Object.create(Yc.prototype)).constructor=zm,(hf.prototype=Object.create(ul.prototype)).constructor=hf,(wh.prototype=Object.create(Yc.prototype)).constructor=wh,(Of.prototype=Object.create(ul.prototype)).constructor=Of,((qp.prototype=Object.create(Ds.prototype)).constructor=qp).prototype.toJSON=function(){var f=Ds.prototype.toJSON.call(this);return f.path=this.parameters.path.toJSON(),f},(bc.prototype=Object.create(ul.prototype)).constructor=bc,($u.prototype=Object.create(Ds.prototype)).constructor=$u,(am.prototype=Object.create(ul.prototype)).constructor=am,(om.prototype=Object.create(Ds.prototype)).constructor=om;var bp={area:function(f){for(var E=f.length,W=0,ge=E-1,ct=0;ct<E;ge=ct++)W+=f[ge].x*f[ct].y-f[ct].x*f[ge].y;return .5*W},isClockWise:function(f){return bp.area(f)<0},triangulateShape:function(f,E){var W=[],ge=[],ct=[];P3(f),$m(W,f);var gt=f.length;E.forEach(P3);for(var St=0;St<E.length;St++)ge.push(gt),gt+=E[St].length,$m(W,E[St]);var Pt=function(sn,ln,Sn){Sn=Sn||2;var En,On,mn,Hn,mr,_r,gi,Ci=ln&&ln.length,$i=Ci?ln[0]*Sn:sn.length,da=rp(sn,0,$i,Sn,!0),ji=[];if(!da||da.next===da.prev)return ji;if(Ci&&(da=function(ea,Ba,Ya,ro){var $a,go,ko,Qa=[];for($a=0,go=Ba.length;$a<go;$a++)(ko=rp(ea,Ba[$a]*ro,$a<go-1?Ba[$a+1]*ro:ea.length,ro,!1))===ko.next&&(ko.steiner=!0),Qa.push(Zl(ko));for(Qa.sort(hh),$a=0;$a<Qa.length;$a++)k3(Qa[$a],Ya),Ya=_p(Ya,Ya.next);return Ya}(sn,ln,da,Sn)),sn.length>80*Sn){En=mn=sn[0],On=Hn=sn[1];for(var Sa=Sn;Sa<$i;Sa+=Sn)(mr=sn[Sa])<En&&(En=mr),(_r=sn[Sa+1])<On&&(On=_r),mn<mr&&(mn=mr),Hn<_r&&(Hn=_r);gi=(gi=Math.max(mn-En,Hn-On))!==0?1/gi:0}return Lf(da,ji,Sn,En,On,gi),ji}(W,ge);for(St=0;St<Pt.length;St+=3)ct.push(Pt.slice(St,St+3));return ct}};function P3(f){var E=f.length;2<E&&f[E-1].equals(f[0])&&f.pop()}function $m(f,E){for(var W=0;W<E.length;W++)f.push(E[W].x),f.push(E[W].y)}function Yp(f,E){ul.call(this),this.type="ExtrudeGeometry",this.parameters={shapes:f,options:E},this.fromBufferGeometry(new wp(f,E)),this.mergeVertices()}function wp(f,E){Ds.call(this),this.type="ExtrudeBufferGeometry",this.parameters={shapes:f,options:E};for(var W=this,ge=[],ct=[],gt=0,St=(f=Array.isArray(f)?f:[f]).length;gt<St;gt++)Pt(f[gt]);function Pt(sn){var ln=[],Sn=E.curveSegments!==void 0?E.curveSegments:12,En=E.steps!==void 0?E.steps:1,On=E.depth!==void 0?E.depth:100,mn=E.bevelEnabled===void 0||E.bevelEnabled,Hn=E.bevelThickness!==void 0?E.bevelThickness:6,mr=E.bevelSize!==void 0?E.bevelSize:Hn-2,_r=E.bevelOffset!==void 0?E.bevelOffset:0,gi=E.bevelSegments!==void 0?E.bevelSegments:3,Ci=E.extrudePath,$i=E.UVGenerator!==void 0?E.UVGenerator:Hm;E.amount!==void 0&&(console.warn("THREE.ExtrudeBufferGeometry: amount has been renamed to depth."),On=E.amount);var da,ji,Sa,ea,Ba,Ya,ro,$a,go=!1;Ci&&(da=Ci.getSpacedPoints(En),mn=!(go=!0),ji=Ci.computeFrenetFrames(En,!1),Sa=new yi,ea=new yi,Ba=new yi),mn||(_r=mr=Hn=gi=0);var ko=sn.extractPoints(Sn),Qa=ko.shape,Ha=ko.holes;if(!bp.isClockWise(Qa))for(Qa=Qa.reverse(),ro=0,$a=Ha.length;ro<$a;ro++)Ya=Ha[ro],bp.isClockWise(Ya)&&(Ha[ro]=Ya.reverse());var fs=bp.triangulateShape(Qa,Ha),os=Qa;for(ro=0,$a=Ha.length;ro<$a;ro++)Ya=Ha[ro],Qa=Qa.concat(Ya);function Ks(nu,Zu,xu){return Zu||console.error("THREE.ExtrudeGeometry: vec does not exist"),Zu.clone().multiplyScalar(xu).add(nu)}var Xs,zs,gl,Os,Ii,va,Bo=Qa.length,Co=fs.length;function Cl(nu,Zu,xu){var Oc,zu,rd,zd=nu.x-Zu.x,ph=nu.y-Zu.y,Ap=xu.x-nu.x,wf=xu.y-nu.y,o3=zd*zd+ph*ph,Jg=zd*wf-ph*Ap;if(Math.abs(Jg)>Number.EPSILON){var Dm=Math.sqrt(o3),Em=Math.sqrt(Ap*Ap+wf*wf),Am=Zu.x-ph/Dm,s3=Zu.y+zd/Dm,Uh=((xu.x-wf/Em-Am)*wf-(xu.y+Ap/Em-s3)*Ap)/(zd*wf-ph*Ap),K3=(Oc=Am+zd*Uh-nu.x)*Oc+(zu=s3+ph*Uh-nu.y)*zu;if(K3<=2)return new co(Oc,zu);rd=Math.sqrt(K3/2)}else{var $h=!1;zd>Number.EPSILON?Ap>Number.EPSILON&&($h=!0):zd<-Number.EPSILON?Ap<-Number.EPSILON&&($h=!0):Math.sign(ph)===Math.sign(wf)&&($h=!0),rd=$h?(Oc=-ph,zu=zd,Math.sqrt(o3)):(Oc=zd,zu=ph,Math.sqrt(o3/2))}return new co(Oc/rd,zu/rd)}for(var Us=[],eo=0,Hs=os.length,Dl=Hs-1,Pa=eo+1;eo<Hs;eo++,Dl++,Pa++)Dl===Hs&&(Dl=0),Pa===Hs&&(Pa=0),Us[eo]=Cl(os[eo],os[Dl],os[Pa]);var Rs,Ls,ml=[],ns=Us.concat();for(ro=0,$a=Ha.length;ro<$a;ro++){for(Ya=Ha[ro],Rs=[],eo=0,Dl=(Hs=Ya.length)-1,Pa=eo+1;eo<Hs;eo++,Dl++,Pa++)Dl===Hs&&(Dl=0),Pa===Hs&&(Pa=0),Rs[eo]=Cl(Ya[eo],Ya[Dl],Ya[Pa]);ml.push(Rs),ns=ns.concat(Rs)}for(Xs=0;Xs<gi;Xs++){for(gl=Xs/gi,Os=Hn*Math.cos(gl*Math.PI/2),zs=mr*Math.sin(gl*Math.PI/2)+_r,eo=0,Hs=os.length;eo<Hs;eo++)ou((Ii=Ks(os[eo],Us[eo],zs)).x,Ii.y,-Os);for(ro=0,$a=Ha.length;ro<$a;ro++)for(Ya=Ha[ro],Rs=ml[ro],eo=0,Hs=Ya.length;eo<Hs;eo++)ou((Ii=Ks(Ya[eo],Rs[eo],zs)).x,Ii.y,-Os)}for(zs=mr+_r,eo=0;eo<Bo;eo++)Ii=mn?Ks(Qa[eo],ns[eo],zs):Qa[eo],go?(ea.copy(ji.normals[0]).multiplyScalar(Ii.x),Sa.copy(ji.binormals[0]).multiplyScalar(Ii.y),Ba.copy(da[0]).add(ea).add(Sa),ou(Ba.x,Ba.y,Ba.z)):ou(Ii.x,Ii.y,0);for(Ls=1;Ls<=En;Ls++)for(eo=0;eo<Bo;eo++)Ii=mn?Ks(Qa[eo],ns[eo],zs):Qa[eo],go?(ea.copy(ji.normals[Ls]).multiplyScalar(Ii.x),Sa.copy(ji.binormals[Ls]).multiplyScalar(Ii.y),Ba.copy(da[Ls]).add(ea).add(Sa),ou(Ba.x,Ba.y,Ba.z)):ou(Ii.x,Ii.y,On/En*Ls);for(Xs=gi-1;0<=Xs;Xs--){for(gl=Xs/gi,Os=Hn*Math.cos(gl*Math.PI/2),zs=mr*Math.sin(gl*Math.PI/2)+_r,eo=0,Hs=os.length;eo<Hs;eo++)ou((Ii=Ks(os[eo],Us[eo],zs)).x,Ii.y,On+Os);for(ro=0,$a=Ha.length;ro<$a;ro++)for(Ya=Ha[ro],Rs=ml[ro],eo=0,Hs=Ya.length;eo<Hs;eo++)Ii=Ks(Ya[eo],Rs[eo],zs),go?ou(Ii.x,Ii.y+da[En-1].y,da[En-1].x+Os):ou(Ii.x,Ii.y,On+Os)}function Rl(nu,Zu){var xu,Oc;for(eo=nu.length;0<=--eo;){(Oc=(xu=eo)-1)<0&&(Oc=nu.length-1);var zu=0,rd=En+2*gi;for(zu=0;zu<rd;zu++){var zd=Bo*zu,ph=Bo*(zu+1);rh(Zu+xu+zd,Zu+Oc+zd,Zu+Oc+ph,Zu+xu+ph)}}}function ou(nu,Zu,xu){ln.push(nu),ln.push(Zu),ln.push(xu)}function Hu(nu,Zu,xu){uu(nu),uu(Zu),uu(xu);var Oc=ge.length/3,zu=$i.generateTopUV(W,ge,Oc-3,Oc-2,Oc-1);Ou(zu[0]),Ou(zu[1]),Ou(zu[2])}function rh(nu,Zu,xu,Oc){uu(nu),uu(Zu),uu(Oc),uu(Zu),uu(xu),uu(Oc);var zu=ge.length/3,rd=$i.generateSideWallUV(W,ge,zu-6,zu-3,zu-2,zu-1);Ou(rd[0]),Ou(rd[1]),Ou(rd[3]),Ou(rd[1]),Ou(rd[2]),Ou(rd[3])}function uu(nu){ge.push(ln[3*nu+0]),ge.push(ln[3*nu+1]),ge.push(ln[3*nu+2])}function Ou(nu){ct.push(nu.x),ct.push(nu.y)}(function(){var nu=ge.length/3;if(mn){var Zu=0,xu=Bo*Zu;for(eo=0;eo<Co;eo++)Hu((va=fs[eo])[2]+xu,va[1]+xu,va[0]+xu);for(xu=Bo*(Zu=En+2*gi),eo=0;eo<Co;eo++)Hu((va=fs[eo])[0]+xu,va[1]+xu,va[2]+xu)}else{for(eo=0;eo<Co;eo++)Hu((va=fs[eo])[2],va[1],va[0]);for(eo=0;eo<Co;eo++)Hu((va=fs[eo])[0]+Bo*En,va[1]+Bo*En,va[2]+Bo*En)}W.addGroup(nu,ge.length/3-nu,0)})(),function(){var nu=ge.length/3,Zu=0;for(Rl(os,Zu),Zu+=os.length,ro=0,$a=Ha.length;ro<$a;ro++)Rl(Ya=Ha[ro],Zu),Zu+=Ya.length;W.addGroup(nu,ge.length/3-nu,1)}()}this.setAttribute("position",new io(ge,3)),this.setAttribute("uv",new io(ct,2)),this.computeVertexNormals()}((Yp.prototype=Object.create(ul.prototype)).constructor=Yp).prototype.toJSON=function(){var f=ul.prototype.toJSON.call(this);return c3(this.parameters.shapes,this.parameters.options,f)},((wp.prototype=Object.create(Ds.prototype)).constructor=wp).prototype.toJSON=function(){var f=Ds.prototype.toJSON.call(this);return c3(this.parameters.shapes,this.parameters.options,f)};var Hm={generateTopUV:function(f,E,W,ge,ct){var gt=E[3*W],St=E[3*W+1],Pt=E[3*ge],sn=E[3*ge+1],ln=E[3*ct],Sn=E[3*ct+1];return[new co(gt,St),new co(Pt,sn),new co(ln,Sn)]},generateSideWallUV:function(f,E,W,ge,ct,gt){var St=E[3*W],Pt=E[3*W+1],sn=E[3*W+2],ln=E[3*ge],Sn=E[3*ge+1],En=E[3*ge+2],On=E[3*ct],mn=E[3*ct+1],Hn=E[3*ct+2],mr=E[3*gt],_r=E[3*gt+1],gi=E[3*gt+2];return Math.abs(Pt-Sn)<.01?[new co(St,1-sn),new co(ln,1-En),new co(On,1-Hn),new co(mr,1-gi)]:[new co(Pt,1-sn),new co(Sn,1-En),new co(mn,1-Hn),new co(_r,1-gi)]}};function c3(f,E,W){if(W.shapes=[],Array.isArray(f))for(var ge=0,ct=f.length;ge<ct;ge++){var gt=f[ge];W.shapes.push(gt.uuid)}else W.shapes.push(f.uuid);return E.extrudePath!==void 0&&(W.options.extrudePath=E.extrudePath.toJSON()),W}function Ic(f,E){ul.call(this),this.type="TextGeometry",this.parameters={text:f,parameters:E},this.fromBufferGeometry(new Zc(f,E)),this.mergeVertices()}function Zc(f,E){var W=(E=E||{}).font;if(!W||!W.isFont)return console.error("THREE.TextGeometry: font parameter is not an instance of THREE.Font."),new ul;var ge=W.generateShapes(f,E.size);E.depth=E.height!==void 0?E.height:50,E.bevelThickness===void 0&&(E.bevelThickness=10),E.bevelSize===void 0&&(E.bevelSize=8),E.bevelEnabled===void 0&&(E.bevelEnabled=!1),wp.call(this,ge,E),this.type="TextBufferGeometry"}function Wm(f,E,W,ge,ct,gt,St){ul.call(this),this.type="SphereGeometry",this.parameters={radius:f,widthSegments:E,heightSegments:W,phiStart:ge,phiLength:ct,thetaStart:gt,thetaLength:St},this.fromBufferGeometry(new Sh(f,E,W,ge,ct,gt,St)),this.mergeVertices()}function Sh(f,E,W,ge,ct,gt,St){Ds.call(this),this.type="SphereBufferGeometry",this.parameters={radius:f,widthSegments:E,heightSegments:W,phiStart:ge,phiLength:ct,thetaStart:gt,thetaLength:St},f=f||1,E=Math.max(3,Math.floor(E)||8),W=Math.max(2,Math.floor(W)||6),ge=ge!==void 0?ge:0,ct=ct!==void 0?ct:2*Math.PI,gt=gt!==void 0?gt:0,St=St!==void 0?St:Math.PI;var Pt,sn,ln=Math.min(gt+St,Math.PI),Sn=0,En=[],On=new yi,mn=new yi,Hn=[],mr=[],_r=[],gi=[];for(sn=0;sn<=W;sn++){var Ci=[],$i=sn/W,da=0;for(sn==0&>==0?da=.5/E:sn==W&&ln==Math.PI&&(da=-.5/E),Pt=0;Pt<=E;Pt++){var ji=Pt/E;On.x=-f*Math.cos(ge+ji*ct)*Math.sin(gt+$i*St),On.y=f*Math.cos(gt+$i*St),On.z=f*Math.sin(ge+ji*ct)*Math.sin(gt+$i*St),mr.push(On.x,On.y,On.z),mn.copy(On).normalize(),_r.push(mn.x,mn.y,mn.z),gi.push(ji+da,1-$i),Ci.push(Sn++)}En.push(Ci)}for(sn=0;sn<W;sn++)for(Pt=0;Pt<E;Pt++){var Sa=En[sn][Pt+1],ea=En[sn][Pt],Ba=En[sn+1][Pt],Ya=En[sn+1][Pt+1];(sn!==0||0<gt)&&Hn.push(Sa,ea,Ya),(sn!==W-1||ln<Math.PI)&&Hn.push(ea,Ba,Ya)}this.setIndex(Hn),this.setAttribute("position",new io(mr,3)),this.setAttribute("normal",new io(_r,3)),this.setAttribute("uv",new io(gi,2))}function qm(f,E,W,ge,ct,gt){ul.call(this),this.type="RingGeometry",this.parameters={innerRadius:f,outerRadius:E,thetaSegments:W,phiSegments:ge,thetaStart:ct,thetaLength:gt},this.fromBufferGeometry(new Zp(f,E,W,ge,ct,gt)),this.mergeVertices()}function Zp(f,E,W,ge,ct,gt){Ds.call(this),this.type="RingBufferGeometry",this.parameters={innerRadius:f,outerRadius:E,thetaSegments:W,phiSegments:ge,thetaStart:ct,thetaLength:gt},f=f||.5,E=E||1,ct=ct!==void 0?ct:0,gt=gt!==void 0?gt:2*Math.PI,W=W!==void 0?Math.max(3,W):8;var St,Pt,sn,ln=[],Sn=[],En=[],On=[],mn=f,Hn=(E-f)/(ge=ge!==void 0?Math.max(1,ge):1),mr=new yi,_r=new co;for(Pt=0;Pt<=ge;Pt++){for(sn=0;sn<=W;sn++)St=ct+sn/W*gt,mr.x=mn*Math.cos(St),mr.y=mn*Math.sin(St),Sn.push(mr.x,mr.y,mr.z),En.push(0,0,1),_r.x=(mr.x/E+1)/2,_r.y=(mr.y/E+1)/2,On.push(_r.x,_r.y);mn+=Hn}for(Pt=0;Pt<ge;Pt++){var gi=Pt*(W+1);for(sn=0;sn<W;sn++){var Ci=St=sn+gi,$i=St+W+1,da=St+W+2,ji=St+1;ln.push(Ci,$i,ji),ln.push($i,da,ji)}}this.setIndex(ln),this.setAttribute("position",new io(Sn,3)),this.setAttribute("normal",new io(En,3)),this.setAttribute("uv",new io(On,2))}function Mp(f,E,W,ge){ul.call(this),this.type="LatheGeometry",this.parameters={points:f,segments:E,phiStart:W,phiLength:ge},this.fromBufferGeometry(new cm(f,E,W,ge)),this.mergeVertices()}function cm(f,E,W,ge){Ds.call(this),this.type="LatheBufferGeometry",this.parameters={points:f,segments:E,phiStart:W,phiLength:ge},E=Math.floor(E)||12,W=W||0,ge=ge||2*Math.PI,ge=js.clamp(ge,0,2*Math.PI);var ct,gt,St,Pt=[],sn=[],ln=[],Sn=1/E,En=new yi,On=new co;for(gt=0;gt<=E;gt++){var mn=W+gt*Sn*ge,Hn=Math.sin(mn),mr=Math.cos(mn);for(St=0;St<=f.length-1;St++)En.x=f[St].x*Hn,En.y=f[St].y,En.z=f[St].x*mr,sn.push(En.x,En.y,En.z),On.x=gt/E,On.y=St/(f.length-1),ln.push(On.x,On.y)}for(gt=0;gt<E;gt++)for(St=0;St<f.length-1;St++){var _r=ct=St+gt*f.length,gi=ct+f.length,Ci=ct+f.length+1,$i=ct+1;Pt.push(_r,gi,$i),Pt.push(gi,Ci,$i)}if(this.setIndex(Pt),this.setAttribute("position",new io(sn,3)),this.setAttribute("uv",new io(ln,2)),this.computeVertexNormals(),ge===2*Math.PI){var da=this.attributes.normal.array,ji=new yi,Sa=new yi,ea=new yi;for(ct=E*f.length*3,St=gt=0;gt<f.length;gt++,St+=3)ji.x=da[St+0],ji.y=da[St+1],ji.z=da[St+2],Sa.x=da[ct+St+0],Sa.y=da[ct+St+1],Sa.z=da[ct+St+2],ea.addVectors(ji,Sa).normalize(),da[St+0]=da[ct+St+0]=ea.x,da[St+1]=da[ct+St+1]=ea.y,da[St+2]=da[ct+St+2]=ea.z}}function dm(f,E){ul.call(this),this.type="ShapeGeometry",typeof E=="object"&&(console.warn("THREE.ShapeGeometry: Options parameter has been removed."),E=E.curveSegments),this.parameters={shapes:f,curveSegments:E},this.fromBufferGeometry(new Qd(f,E)),this.mergeVertices()}function Qd(f,E){Ds.call(this),this.type="ShapeBufferGeometry",this.parameters={shapes:f,curveSegments:E},E=E||12;var W=[],ge=[],ct=[],gt=[],St=0,Pt=0;if(Array.isArray(f)===!1)ln(f);else for(var sn=0;sn<f.length;sn++)ln(f[sn]),this.addGroup(St,Pt,sn),St+=Pt,Pt=0;function ln(Sn){var En,On,mn,Hn=ge.length/3,mr=Sn.extractPoints(E),_r=mr.shape,gi=mr.holes;for(bp.isClockWise(_r)===!1&&(_r=_r.reverse()),En=0,On=gi.length;En<On;En++)mn=gi[En],bp.isClockWise(mn)===!0&&(gi[En]=mn.reverse());var Ci=bp.triangulateShape(_r,gi);for(En=0,On=gi.length;En<On;En++)mn=gi[En],_r=_r.concat(mn);for(En=0,On=_r.length;En<On;En++){var $i=_r[En];ge.push($i.x,$i.y,0),ct.push(0,0,1),gt.push($i.x,$i.y)}for(En=0,On=Ci.length;En<On;En++){var da=Ci[En],ji=da[0]+Hn,Sa=da[1]+Hn,ea=da[2]+Hn;W.push(ji,Sa,ea),Pt+=3}}this.setIndex(W),this.setAttribute("position",new io(ge,3)),this.setAttribute("normal",new io(ct,3)),this.setAttribute("uv",new io(gt,2))}function I3(f,E){if(E.shapes=[],Array.isArray(f))for(var W=0,ge=f.length;W<ge;W++){var ct=f[W];E.shapes.push(ct.uuid)}else E.shapes.push(f.uuid);return E}function Bf(f,E){Ds.call(this),this.type="EdgesGeometry",this.parameters={thresholdAngle:E},E=E!==void 0?E:1;var W,ge,ct,gt,St=[],Pt=Math.cos(js.DEG2RAD*E),sn=[0,0],ln={},Sn=["a","b","c"];f.isBufferGeometry?(gt=new ul).fromBufferGeometry(f):gt=f.clone(),gt.mergeVertices(),gt.computeFaceNormals();for(var En=gt.vertices,On=gt.faces,mn=0,Hn=On.length;mn<Hn;mn++)for(var mr=On[mn],_r=0;_r<3;_r++)W=mr[Sn[_r]],ge=mr[Sn[(_r+1)%3]],sn[0]=Math.min(W,ge),sn[1]=Math.max(W,ge),ln[ct=sn[0]+","+sn[1]]===void 0?ln[ct]={index1:sn[0],index2:sn[1],face1:mn,face2:void 0}:ln[ct].face2=mn;for(ct in ln){var gi=ln[ct];if(gi.face2===void 0||On[gi.face1].normal.dot(On[gi.face2].normal)<=Pt){var Ci=En[gi.index1];St.push(Ci.x,Ci.y,Ci.z),Ci=En[gi.index2],St.push(Ci.x,Ci.y,Ci.z)}}this.setAttribute("position",new io(St,3))}function pf(f,E,W,ge,ct,gt,St,Pt){ul.call(this),this.type="CylinderGeometry",this.parameters={radiusTop:f,radiusBottom:E,height:W,radialSegments:ge,heightSegments:ct,openEnded:gt,thetaStart:St,thetaLength:Pt},this.fromBufferGeometry(new Cp(f,E,W,ge,ct,gt,St,Pt)),this.mergeVertices()}function Cp(f,E,W,ge,ct,gt,St,Pt){Ds.call(this),this.type="CylinderBufferGeometry",this.parameters={radiusTop:f,radiusBottom:E,height:W,radialSegments:ge,heightSegments:ct,openEnded:gt,thetaStart:St,thetaLength:Pt};var sn=this;f=f!==void 0?f:1,E=E!==void 0?E:1,W=W||1,ge=Math.floor(ge)||8,ct=Math.floor(ct)||1,gt=gt!==void 0&>,St=St!==void 0?St:0,Pt=Pt!==void 0?Pt:2*Math.PI;var ln=[],Sn=[],En=[],On=[],mn=0,Hn=[],mr=W/2,_r=0;function gi(Ci){var $i,da,ji,Sa=new co,ea=new yi,Ba=0,Ya=Ci===!0?f:E,ro=Ci===!0?1:-1;for(da=mn,$i=1;$i<=ge;$i++)Sn.push(0,mr*ro,0),En.push(0,ro,0),On.push(.5,.5),mn++;for(ji=mn,$i=0;$i<=ge;$i++){var $a=$i/ge*Pt+St,go=Math.cos($a),ko=Math.sin($a);ea.x=Ya*ko,ea.y=mr*ro,ea.z=Ya*go,Sn.push(ea.x,ea.y,ea.z),En.push(0,ro,0),Sa.x=.5*go+.5,Sa.y=.5*ko*ro+.5,On.push(Sa.x,Sa.y),mn++}for($i=0;$i<ge;$i++){var Qa=da+$i,Ha=ji+$i;Ci===!0?ln.push(Ha,Ha+1,Qa):ln.push(Ha+1,Ha,Qa),Ba+=3}sn.addGroup(_r,Ba,Ci===!0?1:2),_r+=Ba}(function(){var Ci,$i,da=new yi,ji=new yi,Sa=0,ea=(E-f)/W;for($i=0;$i<=ct;$i++){var Ba=[],Ya=$i/ct,ro=Ya*(E-f)+f;for(Ci=0;Ci<=ge;Ci++){var $a=Ci/ge,go=$a*Pt+St,ko=Math.sin(go),Qa=Math.cos(go);ji.x=ro*ko,ji.y=-Ya*W+mr,ji.z=ro*Qa,Sn.push(ji.x,ji.y,ji.z),da.set(ko,ea,Qa).normalize(),En.push(da.x,da.y,da.z),On.push($a,1-Ya),Ba.push(mn++)}Hn.push(Ba)}for(Ci=0;Ci<ge;Ci++)for($i=0;$i<ct;$i++){var Ha=Hn[$i][Ci],fs=Hn[$i+1][Ci],os=Hn[$i+1][Ci+1],Ks=Hn[$i][Ci+1];ln.push(Ha,fs,Ks),ln.push(fs,os,Ks),Sa+=6}sn.addGroup(_r,Sa,0),_r+=Sa})(),gt===!1&&(0<f&&gi(!0),0<E&&gi(!1)),this.setIndex(ln),this.setAttribute("position",new io(Sn,3)),this.setAttribute("normal",new io(En,3)),this.setAttribute("uv",new io(On,2))}function qd(f,E,W,ge,ct,gt,St){pf.call(this,0,f,E,W,ge,ct,gt,St),this.type="ConeGeometry",this.parameters={radius:f,height:E,radialSegments:W,heightSegments:ge,openEnded:ct,thetaStart:gt,thetaLength:St}}function Ym(f,E,W,ge,ct,gt,St){Cp.call(this,0,f,E,W,ge,ct,gt,St),this.type="ConeBufferGeometry",this.parameters={radius:f,height:E,radialSegments:W,heightSegments:ge,openEnded:ct,thetaStart:gt,thetaLength:St}}function d3(f,E,W,ge){ul.call(this),this.type="CircleGeometry",this.parameters={radius:f,segments:E,thetaStart:W,thetaLength:ge},this.fromBufferGeometry(new hm(f,E,W,ge)),this.mergeVertices()}function hm(f,E,W,ge){Ds.call(this),this.type="CircleBufferGeometry",this.parameters={radius:f,segments:E,thetaStart:W,thetaLength:ge},f=f||1,E=E!==void 0?Math.max(3,E):8,W=W!==void 0?W:0,ge=ge!==void 0?ge:2*Math.PI;var ct,gt,St=[],Pt=[],sn=[],ln=[],Sn=new yi,En=new co;for(Pt.push(0,0,0),sn.push(0,0,1),ln.push(.5,.5),gt=0,ct=3;gt<=E;gt++,ct+=3){var On=W+gt/E*ge;Sn.x=f*Math.cos(On),Sn.y=f*Math.sin(On),Pt.push(Sn.x,Sn.y,Sn.z),sn.push(0,0,1),En.x=(Pt[ct]/f+1)/2,En.y=(Pt[ct+1]/f+1)/2,ln.push(En.x,En.y)}for(ct=1;ct<=E;ct++)St.push(ct,ct+1,0);this.setIndex(St),this.setAttribute("position",new io(Pt,3)),this.setAttribute("normal",new io(sn,3)),this.setAttribute("uv",new io(ln,2))}(Ic.prototype=Object.create(ul.prototype)).constructor=Ic,(Zc.prototype=Object.create(wp.prototype)).constructor=Zc,(Wm.prototype=Object.create(ul.prototype)).constructor=Wm,(Sh.prototype=Object.create(Ds.prototype)).constructor=Sh,(qm.prototype=Object.create(ul.prototype)).constructor=qm,(Zp.prototype=Object.create(Ds.prototype)).constructor=Zp,(Mp.prototype=Object.create(ul.prototype)).constructor=Mp,(cm.prototype=Object.create(Ds.prototype)).constructor=cm,((dm.prototype=Object.create(ul.prototype)).constructor=dm).prototype.toJSON=function(){var f=ul.prototype.toJSON.call(this);return I3(this.parameters.shapes,f)},((Qd.prototype=Object.create(Ds.prototype)).constructor=Qd).prototype.toJSON=function(){var f=Ds.prototype.toJSON.call(this);return I3(this.parameters.shapes,f)},(Bf.prototype=Object.create(Ds.prototype)).constructor=Bf,(pf.prototype=Object.create(ul.prototype)).constructor=pf,(Cp.prototype=Object.create(Ds.prototype)).constructor=Cp,(qd.prototype=Object.create(pf.prototype)).constructor=qd,(Ym.prototype=Object.create(Cp.prototype)).constructor=Ym,(d3.prototype=Object.create(ul.prototype)).constructor=d3,(hm.prototype=Object.create(Ds.prototype)).constructor=hm;var eh=Object.freeze({__proto__:null,WireframeGeometry:im,ParametricGeometry:dh,ParametricBufferGeometry:bh,TetrahedronGeometry:kl,TetrahedronBufferGeometry:Rf,OctahedronGeometry:Md,OctahedronBufferGeometry:Dc,IcosahedronGeometry:zh,IcosahedronBufferGeometry:zm,DodecahedronGeometry:hf,DodecahedronBufferGeometry:wh,PolyhedronGeometry:vp,PolyhedronBufferGeometry:Yc,TubeGeometry:Of,TubeBufferGeometry:qp,TorusKnotGeometry:bc,TorusKnotBufferGeometry:$u,TorusGeometry:am,TorusBufferGeometry:om,TextGeometry:Ic,TextBufferGeometry:Zc,SphereGeometry:Wm,SphereBufferGeometry:Sh,RingGeometry:qm,RingBufferGeometry:Zp,PlaneGeometry:Bp,PlaneBufferGeometry:Qh,LatheGeometry:Mp,LatheBufferGeometry:cm,ShapeGeometry:dm,ShapeBufferGeometry:Qd,ExtrudeGeometry:Yp,ExtrudeBufferGeometry:wp,EdgesGeometry:Bf,ConeGeometry:qd,ConeBufferGeometry:Ym,CylinderGeometry:pf,CylinderBufferGeometry:Cp,CircleGeometry:d3,CircleBufferGeometry:hm,BoxGeometry:dp,BoxBufferGeometry:Zo});function Vf(f){ii.call(this),this.type="ShadowMaterial",this.color=new la(0),this.transparent=!0,this.setValues(f)}function Kp(f){Ld.call(this,f),this.type="RawShaderMaterial"}function Sp(f){ii.call(this),this.defines={STANDARD:""},this.type="MeshStandardMaterial",this.color=new la(16777215),this.roughness=1,this.metalness=0,this.map=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new la(0),this.emissiveIntensity=1,this.emissiveMap=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=mu,this.normalScale=new co(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.roughnessMap=null,this.metalnessMap=null,this.alphaMap=null,this.envMap=null,this.envMapIntensity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.skinning=!1,this.morphTargets=!1,this.morphNormals=!1,this.setValues(f)}function pm(f){Sp.call(this),this.defines={STANDARD:"",PHYSICAL:""},this.type="MeshPhysicalMaterial",this.reflectivity=.5,this.clearcoat=0,this.clearcoatRoughness=0,this.sheen=null,this.clearcoatNormalScale=new co(1,1),this.clearcoatNormalMap=null,this.transparency=0,this.setValues(f)}function Tp(f){ii.call(this),this.type="MeshPhongMaterial",this.color=new la(16777215),this.specular=new la(1118481),this.shininess=30,this.map=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new la(0),this.emissiveIntensity=1,this.emissiveMap=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=mu,this.normalScale=new co(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.specularMap=null,this.alphaMap=null,this.envMap=null,this.combine=gn,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.skinning=!1,this.morphTargets=!1,this.morphNormals=!1,this.setValues(f)}function Th(f){ii.call(this),this.defines={TOON:""},this.type="MeshToonMaterial",this.color=new la(16777215),this.specular=new la(1118481),this.shininess=30,this.map=null,this.gradientMap=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new la(0),this.emissiveIntensity=1,this.emissiveMap=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=mu,this.normalScale=new co(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.specularMap=null,this.alphaMap=null,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.skinning=!1,this.morphTargets=!1,this.morphNormals=!1,this.setValues(f)}function Cd(f){ii.call(this),this.type="MeshNormalMaterial",this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=mu,this.normalScale=new co(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.fog=!1,this.skinning=!1,this.morphTargets=!1,this.morphNormals=!1,this.setValues(f)}function Sd(f){ii.call(this),this.type="MeshLambertMaterial",this.color=new la(16777215),this.map=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new la(0),this.emissiveIntensity=1,this.emissiveMap=null,this.specularMap=null,this.alphaMap=null,this.envMap=null,this.combine=gn,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.skinning=!1,this.morphTargets=!1,this.morphNormals=!1,this.setValues(f)}function Xp(f){ii.call(this),this.defines={MATCAP:""},this.type="MeshMatcapMaterial",this.color=new la(16777215),this.matcap=null,this.map=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=mu,this.normalScale=new co(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.alphaMap=null,this.skinning=!1,this.morphTargets=!1,this.morphNormals=!1,this.setValues(f)}function Zm(f){Pc.call(this),this.type="LineDashedMaterial",this.scale=1,this.dashSize=3,this.gapSize=1,this.setValues(f)}((Vf.prototype=Object.create(ii.prototype)).constructor=Vf).prototype.isShadowMaterial=!0,Vf.prototype.copy=function(f){return ii.prototype.copy.call(this,f),this.color.copy(f.color),this},((Kp.prototype=Object.create(Ld.prototype)).constructor=Kp).prototype.isRawShaderMaterial=!0,((Sp.prototype=Object.create(ii.prototype)).constructor=Sp).prototype.isMeshStandardMaterial=!0,Sp.prototype.copy=function(f){return ii.prototype.copy.call(this,f),this.defines={STANDARD:""},this.color.copy(f.color),this.roughness=f.roughness,this.metalness=f.metalness,this.map=f.map,this.lightMap=f.lightMap,this.lightMapIntensity=f.lightMapIntensity,this.aoMap=f.aoMap,this.aoMapIntensity=f.aoMapIntensity,this.emissive.copy(f.emissive),this.emissiveMap=f.emissiveMap,this.emissiveIntensity=f.emissiveIntensity,this.bumpMap=f.bumpMap,this.bumpScale=f.bumpScale,this.normalMap=f.normalMap,this.normalMapType=f.normalMapType,this.normalScale.copy(f.normalScale),this.displacementMap=f.displacementMap,this.displacementScale=f.displacementScale,this.displacementBias=f.displacementBias,this.roughnessMap=f.roughnessMap,this.metalnessMap=f.metalnessMap,this.alphaMap=f.alphaMap,this.envMap=f.envMap,this.envMapIntensity=f.envMapIntensity,this.refractionRatio=f.refractionRatio,this.wireframe=f.wireframe,this.wireframeLinewidth=f.wireframeLinewidth,this.wireframeLinecap=f.wireframeLinecap,this.wireframeLinejoin=f.wireframeLinejoin,this.skinning=f.skinning,this.morphTargets=f.morphTargets,this.morphNormals=f.morphNormals,this},((pm.prototype=Object.create(Sp.prototype)).constructor=pm).prototype.isMeshPhysicalMaterial=!0,pm.prototype.copy=function(f){return Sp.prototype.copy.call(this,f),this.defines={STANDARD:"",PHYSICAL:""},this.reflectivity=f.reflectivity,this.clearcoat=f.clearcoat,this.clearcoatRoughness=f.clearcoatRoughness,f.sheen?this.sheen=(this.sheen||new la).copy(f.sheen):this.sheen=null,this.clearcoatNormalMap=f.clearcoatNormalMap,this.clearcoatNormalScale.copy(f.clearcoatNormalScale),this.transparency=f.transparency,this},((Tp.prototype=Object.create(ii.prototype)).constructor=Tp).prototype.isMeshPhongMaterial=!0,Tp.prototype.copy=function(f){return ii.prototype.copy.call(this,f),this.color.copy(f.color),this.specular.copy(f.specular),this.shininess=f.shininess,this.map=f.map,this.lightMap=f.lightMap,this.lightMapIntensity=f.lightMapIntensity,this.aoMap=f.aoMap,this.aoMapIntensity=f.aoMapIntensity,this.emissive.copy(f.emissive),this.emissiveMap=f.emissiveMap,this.emissiveIntensity=f.emissiveIntensity,this.bumpMap=f.bumpMap,this.bumpScale=f.bumpScale,this.normalMap=f.normalMap,this.normalMapType=f.normalMapType,this.normalScale.copy(f.normalScale),this.displacementMap=f.displacementMap,this.displacementScale=f.displacementScale,this.displacementBias=f.displacementBias,this.specularMap=f.specularMap,this.alphaMap=f.alphaMap,this.envMap=f.envMap,this.combine=f.combine,this.reflectivity=f.reflectivity,this.refractionRatio=f.refractionRatio,this.wireframe=f.wireframe,this.wireframeLinewidth=f.wireframeLinewidth,this.wireframeLinecap=f.wireframeLinecap,this.wireframeLinejoin=f.wireframeLinejoin,this.skinning=f.skinning,this.morphTargets=f.morphTargets,this.morphNormals=f.morphNormals,this},((Th.prototype=Object.create(ii.prototype)).constructor=Th).prototype.isMeshToonMaterial=!0,Th.prototype.copy=function(f){return ii.prototype.copy.call(this,f),this.color.copy(f.color),this.specular.copy(f.specular),this.shininess=f.shininess,this.map=f.map,this.gradientMap=f.gradientMap,this.lightMap=f.lightMap,this.lightMapIntensity=f.lightMapIntensity,this.aoMap=f.aoMap,this.aoMapIntensity=f.aoMapIntensity,this.emissive.copy(f.emissive),this.emissiveMap=f.emissiveMap,this.emissiveIntensity=f.emissiveIntensity,this.bumpMap=f.bumpMap,this.bumpScale=f.bumpScale,this.normalMap=f.normalMap,this.normalMapType=f.normalMapType,this.normalScale.copy(f.normalScale),this.displacementMap=f.displacementMap,this.displacementScale=f.displacementScale,this.displacementBias=f.displacementBias,this.specularMap=f.specularMap,this.alphaMap=f.alphaMap,this.wireframe=f.wireframe,this.wireframeLinewidth=f.wireframeLinewidth,this.wireframeLinecap=f.wireframeLinecap,this.wireframeLinejoin=f.wireframeLinejoin,this.skinning=f.skinning,this.morphTargets=f.morphTargets,this.morphNormals=f.morphNormals,this},((Cd.prototype=Object.create(ii.prototype)).constructor=Cd).prototype.isMeshNormalMaterial=!0,Cd.prototype.copy=function(f){return ii.prototype.copy.call(this,f),this.bumpMap=f.bumpMap,this.bumpScale=f.bumpScale,this.normalMap=f.normalMap,this.normalMapType=f.normalMapType,this.normalScale.copy(f.normalScale),this.displacementMap=f.displacementMap,this.displacementScale=f.displacementScale,this.displacementBias=f.displacementBias,this.wireframe=f.wireframe,this.wireframeLinewidth=f.wireframeLinewidth,this.skinning=f.skinning,this.morphTargets=f.morphTargets,this.morphNormals=f.morphNormals,this},((Sd.prototype=Object.create(ii.prototype)).constructor=Sd).prototype.isMeshLambertMaterial=!0,Sd.prototype.copy=function(f){return ii.prototype.copy.call(this,f),this.color.copy(f.color),this.map=f.map,this.lightMap=f.lightMap,this.lightMapIntensity=f.lightMapIntensity,this.aoMap=f.aoMap,this.aoMapIntensity=f.aoMapIntensity,this.emissive.copy(f.emissive),this.emissiveMap=f.emissiveMap,this.emissiveIntensity=f.emissiveIntensity,this.specularMap=f.specularMap,this.alphaMap=f.alphaMap,this.envMap=f.envMap,this.combine=f.combine,this.reflectivity=f.reflectivity,this.refractionRatio=f.refractionRatio,this.wireframe=f.wireframe,this.wireframeLinewidth=f.wireframeLinewidth,this.wireframeLinecap=f.wireframeLinecap,this.wireframeLinejoin=f.wireframeLinejoin,this.skinning=f.skinning,this.morphTargets=f.morphTargets,this.morphNormals=f.morphNormals,this},((Xp.prototype=Object.create(ii.prototype)).constructor=Xp).prototype.isMeshMatcapMaterial=!0,Xp.prototype.copy=function(f){return ii.prototype.copy.call(this,f),this.defines={MATCAP:""},this.color.copy(f.color),this.matcap=f.matcap,this.map=f.map,this.bumpMap=f.bumpMap,this.bumpScale=f.bumpScale,this.normalMap=f.normalMap,this.normalMapType=f.normalMapType,this.normalScale.copy(f.normalScale),this.displacementMap=f.displacementMap,this.displacementScale=f.displacementScale,this.displacementBias=f.displacementBias,this.alphaMap=f.alphaMap,this.skinning=f.skinning,this.morphTargets=f.morphTargets,this.morphNormals=f.morphNormals,this},((Zm.prototype=Object.create(Pc.prototype)).constructor=Zm).prototype.isLineDashedMaterial=!0,Zm.prototype.copy=function(f){return Pc.prototype.copy.call(this,f),this.scale=f.scale,this.dashSize=f.dashSize,this.gapSize=f.gapSize,this};var Og=Object.freeze({__proto__:null,ShadowMaterial:Vf,SpriteMaterial:uh,RawShaderMaterial:Kp,ShaderMaterial:Ld,PointsMaterial:ch,MeshPhysicalMaterial:pm,MeshStandardMaterial:Sp,MeshPhongMaterial:Tp,MeshToonMaterial:Th,MeshNormalMaterial:Cd,MeshLambertMaterial:Sd,MeshDepthMaterial:_c,MeshDistanceMaterial:Bc,MeshBasicMaterial:Ma,MeshMatcapMaterial:Xp,LineDashedMaterial:Zm,LineBasicMaterial:Pc,Material:ii}),Nc={arraySlice:function(f,E,W){return Nc.isTypedArray(f)?new f.constructor(f.subarray(E,W!==void 0?W:f.length)):f.slice(E,W)},convertArray:function(f,E,W){return!f||!W&&f.constructor===E?f:typeof E.BYTES_PER_ELEMENT=="number"?new E(f):Array.prototype.slice.call(f)},isTypedArray:function(f){return ArrayBuffer.isView(f)&&!(f instanceof DataView)},getKeyframeOrder:function(f){for(var E=f.length,W=new Array(E),ge=0;ge!==E;++ge)W[ge]=ge;return W.sort(function(ct,gt){return f[ct]-f[gt]}),W},sortedArray:function(f,E,W){for(var ge=f.length,ct=new f.constructor(ge),gt=0,St=0;St!==ge;++gt)for(var Pt=W[gt]*E,sn=0;sn!==E;++sn)ct[St++]=f[Pt+sn];return ct},flattenJSON:function(f,E,W,ge){for(var ct=1,gt=f[0];gt!==void 0&>[ge]===void 0;)gt=f[ct++];if(gt!==void 0){var St=gt[ge];if(St!==void 0)if(Array.isArray(St))for(;(St=gt[ge])!==void 0&&(E.push(gt.time),W.push.apply(W,St)),(gt=f[ct++])!==void 0;);else if(St.toArray!==void 0)for(;(St=gt[ge])!==void 0&&(E.push(gt.time),St.toArray(W,W.length)),(gt=f[ct++])!==void 0;);else for(;(St=gt[ge])!==void 0&&(E.push(gt.time),W.push(St)),(gt=f[ct++])!==void 0;);}},subclip:function(f,E,W,ge,ct){ct=ct||30;var gt=f.clone();gt.name=E;for(var St=[],Pt=0;Pt<gt.tracks.length;++Pt){for(var sn=gt.tracks[Pt],ln=sn.getValueSize(),Sn=[],En=[],On=0;On<sn.times.length;++On){var mn=sn.times[On]*ct;if(!(mn<W||ge<=mn)){Sn.push(sn.times[On]);for(var Hn=0;Hn<ln;++Hn)En.push(sn.values[On*ln+Hn])}}Sn.length!==0&&(sn.times=Nc.convertArray(Sn,sn.times.constructor),sn.values=Nc.convertArray(En,sn.values.constructor),St.push(sn))}gt.tracks=St;var mr=1/0;for(Pt=0;Pt<gt.tracks.length;++Pt)mr>gt.tracks[Pt].times[0]&&(mr=gt.tracks[Pt].times[0]);for(Pt=0;Pt<gt.tracks.length;++Pt)gt.tracks[Pt].shift(-1*mr);return gt.resetDuration(),gt}};function Td(f,E,W,ge){this.parameterPositions=f,this._cachedIndex=0,this.resultBuffer=ge!==void 0?ge:new E.constructor(W),this.sampleValues=E,this.valueSize=W}function h3(f,E,W,ge){Td.call(this,f,E,W,ge),this._weightPrev=-0,this._offsetPrev=-0,this._weightNext=-0,this._offsetNext=-0}function ff(f,E,W,ge){Td.call(this,f,E,W,ge)}function Km(f,E,W,ge){Td.call(this,f,E,W,ge)}function Rc(f,E,W,ge){if(f===void 0)throw new Error("THREE.KeyframeTrack: track name is undefined");if(E===void 0||E.length===0)throw new Error("THREE.KeyframeTrack: no keyframes in track named "+f);this.name=f,this.times=Nc.convertArray(E,this.TimeBufferType),this.values=Nc.convertArray(W,this.ValueBufferType),this.setInterpolation(ge||this.DefaultInterpolation)}function mf(f,E,W){Rc.call(this,f,E,W)}function p3(f,E,W,ge){Rc.call(this,f,E,W,ge)}function gf(f,E,W,ge){Rc.call(this,f,E,W,ge)}function fm(f,E,W,ge){Td.call(this,f,E,W,ge)}function Nf(f,E,W,ge){Rc.call(this,f,E,W,ge)}function f3(f,E,W,ge){Rc.call(this,f,E,W,ge)}function mm(f,E,W,ge){Rc.call(this,f,E,W,ge)}function jh(f,E,W){this.name=f,this.tracks=W,this.duration=E!==void 0?E:-1,this.uuid=js.generateUUID(),this.duration<0&&this.resetDuration()}function R3(f){if(f.type===void 0)throw new Error("THREE.KeyframeTrack: track type undefined, can not parse");var E=function(ct){switch(ct.toLowerCase()){case"scalar":case"double":case"float":case"number":case"integer":return gf;case"vector":case"vector2":case"vector3":case"vector4":return mm;case"color":return p3;case"quaternion":return Nf;case"bool":case"boolean":return mf;case"string":return f3}throw new Error("THREE.KeyframeTrack: Unsupported typeName: "+ct)}(f.type);if(f.times===void 0){var W=[],ge=[];Nc.flattenJSON(f.keys,W,ge,"value"),f.times=W,f.values=ge}return E.parse!==void 0?E.parse(f):new E(f.name,f.times,f.values,f.interpolation)}Object.assign(Td.prototype,{evaluate:function(f){var E=this.parameterPositions,W=this._cachedIndex,ge=E[W],ct=E[W-1];e:{t:{var gt;n:{a:if(!(f<ge)){for(var St=W+2;;){if(ge===void 0){if(f<ct)break a;return W=E.length,this._cachedIndex=W,this.afterEnd_(W-1,f,ct)}if(W===St)break;if(ct=ge,f<(ge=E[++W]))break t}gt=E.length;break n}if(ct<=f)break e;var Pt=E[1];for(f<Pt&&(W=2,ct=Pt),St=W-2;;){if(ct===void 0)return this._cachedIndex=0,this.beforeStart_(0,f,ge);if(W===St)break;if(ge=ct,(ct=E[--W-1])<=f)break t}gt=W,W=0}for(;W<gt;){var sn=W+gt>>>1;f<E[sn]?gt=sn:W=1+sn}if(ge=E[W],(ct=E[W-1])===void 0)return this._cachedIndex=0,this.beforeStart_(0,f,ge);if(ge===void 0)return W=E.length,this._cachedIndex=W,this.afterEnd_(W-1,ct,f)}this._cachedIndex=W,this.intervalChanged_(W,ct,ge)}return this.interpolate_(W,ct,f,ge)},settings:null,DefaultSettings_:{},getSettings_:function(){return this.settings||this.DefaultSettings_},copySampleValue_:function(f){for(var E=this.resultBuffer,W=this.sampleValues,ge=this.valueSize,ct=f*ge,gt=0;gt!==ge;++gt)E[gt]=W[ct+gt];return E},interpolate_:function(){throw new Error("call to abstract method")},intervalChanged_:function(){}}),Object.assign(Td.prototype,{beforeStart_:Td.prototype.copySampleValue_,afterEnd_:Td.prototype.copySampleValue_}),h3.prototype=Object.assign(Object.create(Td.prototype),{constructor:h3,DefaultSettings_:{endingStart:Ur,endingEnd:Ur},intervalChanged_:function(f,E,W){var ge=this.parameterPositions,ct=f-2,gt=f+1,St=ge[ct],Pt=ge[gt];if(St===void 0)switch(this.getSettings_().endingStart){case Gn:ct=f,St=2*E-W;break;case Qr:St=E+ge[ct=ge.length-2]-ge[ct+1];break;default:ct=f,St=W}if(Pt===void 0)switch(this.getSettings_().endingEnd){case Gn:gt=f,Pt=2*W-E;break;case Qr:Pt=W+ge[gt=1]-ge[0];break;default:gt=f-1,Pt=E}var sn=.5*(W-E),ln=this.valueSize;this._weightPrev=sn/(E-St),this._weightNext=sn/(Pt-W),this._offsetPrev=ct*ln,this._offsetNext=gt*ln},interpolate_:function(f,E,W,ge){for(var ct=this.resultBuffer,gt=this.sampleValues,St=this.valueSize,Pt=f*St,sn=Pt-St,ln=this._offsetPrev,Sn=this._offsetNext,En=this._weightPrev,On=this._weightNext,mn=(W-E)/(ge-E),Hn=mn*mn,mr=Hn*mn,_r=-En*mr+2*En*Hn-En*mn,gi=(1+En)*mr+(-1.5-2*En)*Hn+(-.5+En)*mn+1,Ci=(-1-On)*mr+(1.5+On)*Hn+.5*mn,$i=On*mr-On*Hn,da=0;da!==St;++da)ct[da]=_r*gt[ln+da]+gi*gt[sn+da]+Ci*gt[Pt+da]+$i*gt[Sn+da];return ct}}),ff.prototype=Object.assign(Object.create(Td.prototype),{constructor:ff,interpolate_:function(f,E,W,ge){for(var ct=this.resultBuffer,gt=this.sampleValues,St=this.valueSize,Pt=f*St,sn=Pt-St,ln=(W-E)/(ge-E),Sn=1-ln,En=0;En!==St;++En)ct[En]=gt[sn+En]*Sn+gt[Pt+En]*ln;return ct}}),Km.prototype=Object.assign(Object.create(Td.prototype),{constructor:Km,interpolate_:function(f){return this.copySampleValue_(f-1)}}),Object.assign(Rc,{toJSON:function(f){var E,W=f.constructor;if(W.toJSON!==void 0)E=W.toJSON(f);else{E={name:f.name,times:Nc.convertArray(f.times,Array),values:Nc.convertArray(f.values,Array)};var ge=f.getInterpolation();ge!==f.DefaultInterpolation&&(E.interpolation=ge)}return E.type=f.ValueTypeName,E}}),Object.assign(Rc.prototype,{constructor:Rc,TimeBufferType:Float32Array,ValueBufferType:Float32Array,DefaultInterpolation:Mn,InterpolantFactoryMethodDiscrete:function(f){return new Km(this.times,this.values,this.getValueSize(),f)},InterpolantFactoryMethodLinear:function(f){return new ff(this.times,this.values,this.getValueSize(),f)},InterpolantFactoryMethodSmooth:function(f){return new h3(this.times,this.values,this.getValueSize(),f)},setInterpolation:function(f){var E;switch(f){case al:E=this.InterpolantFactoryMethodDiscrete;break;case Mn:E=this.InterpolantFactoryMethodLinear;break;case 2302:E=this.InterpolantFactoryMethodSmooth}if(E!==void 0)return this.createInterpolant=E,this;var W="unsupported interpolation for "+this.ValueTypeName+" keyframe track named "+this.name;if(this.createInterpolant===void 0){if(f===this.DefaultInterpolation)throw new Error(W);this.setInterpolation(this.DefaultInterpolation)}return console.warn("THREE.KeyframeTrack:",W),this},getInterpolation:function(){switch(this.createInterpolant){case this.InterpolantFactoryMethodDiscrete:return al;case this.InterpolantFactoryMethodLinear:return Mn;case this.InterpolantFactoryMethodSmooth:return 2302}},getValueSize:function(){return this.values.length/this.times.length},shift:function(f){if(f!==0)for(var E=this.times,W=0,ge=E.length;W!==ge;++W)E[W]+=f;return this},scale:function(f){if(f!==1)for(var E=this.times,W=0,ge=E.length;W!==ge;++W)E[W]*=f;return this},trim:function(f,E){for(var W=this.times,ge=W.length,ct=0,gt=ge-1;ct!==ge&&W[ct]<f;)++ct;for(;gt!==-1&&W[gt]>E;)--gt;if(++gt,ct!==0||gt!==ge){gt<=ct&&(ct=(gt=Math.max(gt,1))-1);var St=this.getValueSize();this.times=Nc.arraySlice(W,ct,gt),this.values=Nc.arraySlice(this.values,ct*St,gt*St)}return this},validate:function(){var f=!0,E=this.getValueSize();E-Math.floor(E)!=0&&(console.error("THREE.KeyframeTrack: Invalid value size in track.",this),f=!1);var W=this.times,ge=this.values,ct=W.length;ct===0&&(console.error("THREE.KeyframeTrack: Track is empty.",this),f=!1);for(var gt=null,St=0;St!==ct;St++){var Pt=W[St];if(typeof Pt=="number"&&isNaN(Pt)){console.error("THREE.KeyframeTrack: Time is not a valid number.",this,St,Pt),f=!1;break}if(gt!==null&&Pt<gt){console.error("THREE.KeyframeTrack: Out of order keys.",this,St,Pt,gt),f=!1;break}gt=Pt}if(ge!==void 0&&Nc.isTypedArray(ge)){St=0;for(var sn=ge.length;St!==sn;++St){var ln=ge[St];if(isNaN(ln)){console.error("THREE.KeyframeTrack: Value is not a valid number.",this,St,ln),f=!1;break}}}return f},optimize:function(){for(var f=Nc.arraySlice(this.times),E=Nc.arraySlice(this.values),W=this.getValueSize(),ge=this.getInterpolation()===2302,ct=1,gt=f.length-1,St=1;St<gt;++St){var Pt=!1,sn=f[St];if(sn!==f[St+1]&&(St!==1||sn!==sn[0]))if(ge)Pt=!0;else for(var ln=St*W,Sn=ln-W,En=ln+W,On=0;On!==W;++On){var mn=E[ln+On];if(mn!==E[Sn+On]||mn!==E[En+On]){Pt=!0;break}}if(Pt){if(St!==ct){f[ct]=f[St];var Hn=St*W,mr=ct*W;for(On=0;On!==W;++On)E[mr+On]=E[Hn+On]}++ct}}if(0<gt){for(f[ct]=f[gt],Hn=gt*W,mr=ct*W,On=0;On!==W;++On)E[mr+On]=E[Hn+On];++ct}return ct!==f.length?(this.times=Nc.arraySlice(f,0,ct),this.values=Nc.arraySlice(E,0,ct*W)):(this.times=f,this.values=E),this},clone:function(){var f=Nc.arraySlice(this.times,0),E=Nc.arraySlice(this.values,0),W=new this.constructor(this.name,f,E);return W.createInterpolant=this.createInterpolant,W}}),mf.prototype=Object.assign(Object.create(Rc.prototype),{constructor:mf,ValueTypeName:"bool",ValueBufferType:Array,DefaultInterpolation:al,InterpolantFactoryMethodLinear:void 0,InterpolantFactoryMethodSmooth:void 0}),p3.prototype=Object.assign(Object.create(Rc.prototype),{constructor:p3,ValueTypeName:"color"}),gf.prototype=Object.assign(Object.create(Rc.prototype),{constructor:gf,ValueTypeName:"number"}),fm.prototype=Object.assign(Object.create(Td.prototype),{constructor:fm,interpolate_:function(f,E,W,ge){for(var ct=this.resultBuffer,gt=this.sampleValues,St=this.valueSize,Pt=f*St,sn=(W-E)/(ge-E),ln=Pt+St;Pt!==ln;Pt+=4)Wu.slerpFlat(ct,0,gt,Pt-St,gt,Pt,sn);return ct}}),Nf.prototype=Object.assign(Object.create(Rc.prototype),{constructor:Nf,ValueTypeName:"quaternion",DefaultInterpolation:Mn,InterpolantFactoryMethodLinear:function(f){return new fm(this.times,this.values,this.getValueSize(),f)},InterpolantFactoryMethodSmooth:void 0}),f3.prototype=Object.assign(Object.create(Rc.prototype),{constructor:f3,ValueTypeName:"string",ValueBufferType:Array,DefaultInterpolation:al,InterpolantFactoryMethodLinear:void 0,InterpolantFactoryMethodSmooth:void 0}),mm.prototype=Object.assign(Object.create(Rc.prototype),{constructor:mm,ValueTypeName:"vector"}),Object.assign(jh,{parse:function(f){for(var E=[],W=f.tracks,ge=1/(f.fps||1),ct=0,gt=W.length;ct!==gt;++ct)E.push(R3(W[ct]).scale(ge));return new jh(f.name,f.duration,E)},toJSON:function(f){for(var E=[],W=f.tracks,ge={name:f.name,duration:f.duration,tracks:E,uuid:f.uuid},ct=0,gt=W.length;ct!==gt;++ct)E.push(Rc.toJSON(W[ct]));return ge},CreateFromMorphTargetSequence:function(f,E,W,ge){for(var ct=E.length,gt=[],St=0;St<ct;St++){var Pt=[],sn=[];Pt.push((St+ct-1)%ct,St,(St+1)%ct),sn.push(0,1,0);var ln=Nc.getKeyframeOrder(Pt);Pt=Nc.sortedArray(Pt,1,ln),sn=Nc.sortedArray(sn,1,ln),ge||Pt[0]!==0||(Pt.push(ct),sn.push(sn[0])),gt.push(new gf(".morphTargetInfluences["+E[St].name+"]",Pt,sn).scale(1/W))}return new jh(f,-1,gt)},findByName:function(f,E){var W=f;Array.isArray(f)||(W=f.geometry&&f.geometry.animations||f.animations);for(var ge=0;ge<W.length;ge++)if(W[ge].name===E)return W[ge];return null},CreateClipsFromMorphTargetSequences:function(f,E,W){for(var ge={},ct=/^([\w-]*?)([\d]+)$/,gt=0,St=f.length;gt<St;gt++){var Pt=f[gt],sn=Pt.name.match(ct);if(sn&&1<sn.length){var ln=ge[En=sn[1]];ln||(ge[En]=ln=[]),ln.push(Pt)}}var Sn=[];for(var En in ge)Sn.push(jh.CreateFromMorphTargetSequence(En,ge[En],E,W));return Sn},parseAnimation:function(f,E){if(!f)return console.error("THREE.AnimationClip: No animation in JSONLoader data."),null;for(var W=function(Ci,$i,da,ji,Sa){if(da.length!==0){var ea=[],Ba=[];Nc.flattenJSON(da,ea,Ba,ji),ea.length!==0&&Sa.push(new Ci($i,ea,Ba))}},ge=[],ct=f.name||"default",gt=f.length||-1,St=f.fps||30,Pt=f.hierarchy||[],sn=0;sn<Pt.length;sn++){var ln=Pt[sn].keys;if(ln&&ln.length!==0)if(ln[0].morphTargets){for(var Sn={},En=0;En<ln.length;En++)if(ln[En].morphTargets)for(var On=0;On<ln[En].morphTargets.length;On++)Sn[ln[En].morphTargets[On]]=-1;for(var mn in Sn){var Hn=[],mr=[];for(On=0;On!==ln[En].morphTargets.length;++On){var _r=ln[En];Hn.push(_r.time),mr.push(_r.morphTarget===mn?1:0)}ge.push(new gf(".morphTargetInfluence["+mn+"]",Hn,mr))}gt=Sn.length*(St||1)}else{var gi=".bones["+E[sn].name+"]";W(mm,gi+".position",ln,"pos",ge),W(Nf,gi+".quaternion",ln,"rot",ge),W(mm,gi+".scale",ln,"scl",ge)}}return ge.length===0?null:new jh(ct,gt,ge)}}),Object.assign(jh.prototype,{resetDuration:function(){for(var f=0,E=0,W=this.tracks.length;E!==W;++E){var ge=this.tracks[E];f=Math.max(f,ge.times[ge.times.length-1])}return this.duration=f,this},trim:function(){for(var f=0;f<this.tracks.length;f++)this.tracks[f].trim(0,this.duration);return this},validate:function(){for(var f=!0,E=0;E<this.tracks.length;E++)f=f&&this.tracks[E].validate();return f},optimize:function(){for(var f=0;f<this.tracks.length;f++)this.tracks[f].optimize();return this},clone:function(){for(var f=[],E=0;E<this.tracks.length;E++)f.push(this.tracks[E].clone());return new jh(this.name,this.duration,f)}});var zf={enabled:!1,files:{},add:function(f,E){this.enabled!==!1&&(this.files[f]=E)},get:function(f){if(this.enabled!==!1)return this.files[f]},remove:function(f){delete this.files[f]},clear:function(){this.files={}}};function yf(f,E,W){var ge=this,ct=!1,gt=0,St=0,Pt=void 0,sn=[];this.onStart=void 0,this.onLoad=f,this.onProgress=E,this.onError=W,this.itemStart=function(ln){St++,ct===!1&&ge.onStart!==void 0&&ge.onStart(ln,gt,St),ct=!0},this.itemEnd=function(ln){gt++,ge.onProgress!==void 0&&ge.onProgress(ln,gt,St),gt===St&&(ct=!1,ge.onLoad!==void 0&&ge.onLoad())},this.itemError=function(ln){ge.onError!==void 0&&ge.onError(ln)},this.resolveURL=function(ln){return Pt?Pt(ln):ln},this.setURLModifier=function(ln){return Pt=ln,this},this.addHandler=function(ln,Sn){return sn.push(ln,Sn),this},this.removeHandler=function(ln){var Sn=sn.indexOf(ln);return Sn!==-1&&sn.splice(Sn,2),this},this.getHandler=function(ln){for(var Sn=0,En=sn.length;Sn<En;Sn+=2){var On=sn[Sn],mn=sn[Sn+1];if(On.global&&(On.lastIndex=0),On.test(ln))return mn}return null}}var eg=new yf;function Ze(f){this.manager=f!==void 0?f:eg,this.crossOrigin="anonymous",this.path="",this.resourcePath=""}Object.assign(Ze.prototype,{load:function(){},parse:function(){},setCrossOrigin:function(f){return this.crossOrigin=f,this},setPath:function(f){return this.path=f,this},setResourcePath:function(f){return this.resourcePath=f,this}});var vt={};function on(f){Ze.call(this,f)}function Fn(f){Ze.call(this,f)}function Qn(f){Ze.call(this,f)}function mi(f){Ze.call(this,f)}function ra(f){Ze.call(this,f)}function Ca(f){Ze.call(this,f)}function La(f){Ze.call(this,f)}function Oa(){this.type="Curve",this.arcLengthDivisions=200}function fo(f,E,W,ge,ct,gt,St,Pt){Oa.call(this),this.type="EllipseCurve",this.aX=f||0,this.aY=E||0,this.xRadius=W||1,this.yRadius=ge||1,this.aStartAngle=ct||0,this.aEndAngle=gt||2*Math.PI,this.aClockwise=St||!1,this.aRotation=Pt||0}function Ho(f,E,W,ge,ct,gt){fo.call(this,f,E,W,W,ge,ct,gt),this.type="ArcCurve"}function qs(){var f=0,E=0,W=0,ge=0;function ct(gt,St,Pt,sn){W=-3*(f=gt)+3*St-2*(E=Pt)-sn,ge=2*gt-2*St+Pt+sn}return{initCatmullRom:function(gt,St,Pt,sn,ln){ct(St,Pt,ln*(Pt-gt),ln*(sn-St))},initNonuniformCatmullRom:function(gt,St,Pt,sn,ln,Sn,En){var On=(St-gt)/ln-(Pt-gt)/(ln+Sn)+(Pt-St)/Sn,mn=(Pt-St)/Sn-(sn-St)/(Sn+En)+(sn-Pt)/En;ct(St,Pt,On*=Sn,mn*=Sn)},calc:function(gt){var St=gt*gt;return f+E*gt+W*St+ge*(St*gt)}}}on.prototype=Object.assign(Object.create(Ze.prototype),{constructor:on,load:function(f,E,W,ge){f===void 0&&(f=""),this.path!==void 0&&(f=this.path+f),f=this.manager.resolveURL(f);var ct=this,gt=zf.get(f);if(gt!==void 0)return ct.manager.itemStart(f),setTimeout(function(){E&&E(gt),ct.manager.itemEnd(f)},0),gt;if(vt[f]===void 0){var St=f.match(/^data:(.*?)(;base64)?,(.*)$/);if(St){var Pt=St[1],sn=!!St[2],ln=St[3];ln=decodeURIComponent(ln),sn&&(ln=atob(ln));try{var Sn,En=(this.responseType||"").toLowerCase();switch(En){case"arraybuffer":case"blob":for(var On=new Uint8Array(ln.length),mn=0;mn<ln.length;mn++)On[mn]=ln.charCodeAt(mn);Sn=En==="blob"?new Blob([On.buffer],{type:Pt}):On.buffer;break;case"document":var Hn=new DOMParser;Sn=Hn.parseFromString(ln,Pt);break;case"json":Sn=JSON.parse(ln);break;default:Sn=ln}setTimeout(function(){E&&E(Sn),ct.manager.itemEnd(f)},0)}catch(gi){setTimeout(function(){ge&&ge(gi),ct.manager.itemError(f),ct.manager.itemEnd(f)},0)}}else{vt[f]=[],vt[f].push({onLoad:E,onProgress:W,onError:ge});var mr=new XMLHttpRequest;for(var _r in mr.open("GET",f,!0),mr.addEventListener("load",function(gi){var Ci=this.response,$i=vt[f];if(delete vt[f],this.status===200||this.status===0){this.status===0&&console.warn("THREE.FileLoader: HTTP Status 0 received."),zf.add(f,Ci);for(var da=0,ji=$i.length;da<ji;da++)(Sa=$i[da]).onLoad&&Sa.onLoad(Ci);ct.manager.itemEnd(f)}else{for(da=0,ji=$i.length;da<ji;da++){var Sa;(Sa=$i[da]).onError&&Sa.onError(gi)}ct.manager.itemError(f),ct.manager.itemEnd(f)}},!1),mr.addEventListener("progress",function(gi){for(var Ci=vt[f],$i=0,da=Ci.length;$i<da;$i++){var ji=Ci[$i];ji.onProgress&&ji.onProgress(gi)}},!1),mr.addEventListener("error",function(gi){var Ci=vt[f];delete vt[f];for(var $i=0,da=Ci.length;$i<da;$i++){var ji=Ci[$i];ji.onError&&ji.onError(gi)}ct.manager.itemError(f),ct.manager.itemEnd(f)},!1),mr.addEventListener("abort",function(gi){var Ci=vt[f];delete vt[f];for(var $i=0,da=Ci.length;$i<da;$i++){var ji=Ci[$i];ji.onError&&ji.onError(gi)}ct.manager.itemError(f),ct.manager.itemEnd(f)},!1),this.responseType!==void 0&&(mr.responseType=this.responseType),this.withCredentials!==void 0&&(mr.withCredentials=this.withCredentials),mr.overrideMimeType&&mr.overrideMimeType(this.mimeType!==void 0?this.mimeType:"text/plain"),this.requestHeader)mr.setRequestHeader(_r,this.requestHeader[_r]);mr.send(null)}return ct.manager.itemStart(f),mr}vt[f].push({onLoad:E,onProgress:W,onError:ge})},setResponseType:function(f){return this.responseType=f,this},setWithCredentials:function(f){return this.withCredentials=f,this},setMimeType:function(f){return this.mimeType=f,this},setRequestHeader:function(f){return this.requestHeader=f,this}}),Fn.prototype=Object.assign(Object.create(Ze.prototype),{constructor:Fn,load:function(f,E,W,ge){var ct=this,gt=new on(ct.manager);gt.setPath(ct.path),gt.load(f,function(St){E(ct.parse(JSON.parse(St)))},W,ge)},parse:function(f){for(var E=[],W=0;W<f.length;W++){var ge=jh.parse(f[W]);E.push(ge)}return E}}),Qn.prototype=Object.assign(Object.create(Ze.prototype),{constructor:Qn,load:function(f,E,W,ge){var ct=this,gt=[],St=new nm;St.image=gt;var Pt=new on(this.manager);function sn(On){Pt.load(f[On],function(mn){var Hn=ct.parse(mn,!0);gt[On]={width:Hn.width,height:Hn.height,format:Hn.format,mipmaps:Hn.mipmaps},(ln+=1)===6&&(Hn.mipmapCount===1&&(St.minFilter=hi),St.format=Hn.format,St.needsUpdate=!0,E&&E(St))},W,ge)}if(Pt.setPath(this.path),Pt.setResponseType("arraybuffer"),Array.isArray(f))for(var ln=0,Sn=0,En=f.length;Sn<En;++Sn)sn(Sn);else Pt.load(f,function(On){var mn=ct.parse(On,!0);if(mn.isCubemap)for(var Hn=mn.mipmaps.length/mn.mipmapCount,mr=0;mr<Hn;mr++){gt[mr]={mipmaps:[]};for(var _r=0;_r<mn.mipmapCount;_r++)gt[mr].mipmaps.push(mn.mipmaps[mr*mn.mipmapCount+_r]),gt[mr].format=mn.format,gt[mr].width=mn.width,gt[mr].height=mn.height}else St.image.width=mn.width,St.image.height=mn.height,St.mipmaps=mn.mipmaps;mn.mipmapCount===1&&(St.minFilter=hi),St.format=mn.format,St.needsUpdate=!0,E&&E(St)},W,ge);return St}}),mi.prototype=Object.assign(Object.create(Ze.prototype),{constructor:mi,load:function(f,E,W,ge){var ct=this,gt=new pp,St=new on(this.manager);return St.setResponseType("arraybuffer"),St.setPath(this.path),St.load(f,function(Pt){var sn=ct.parse(Pt);sn&&(sn.image!==void 0?gt.image=sn.image:sn.data!==void 0&&(gt.image.width=sn.width,gt.image.height=sn.height,gt.image.data=sn.data),gt.wrapS=sn.wrapS!==void 0?sn.wrapS:Nn,gt.wrapT=sn.wrapT!==void 0?sn.wrapT:Nn,gt.magFilter=sn.magFilter!==void 0?sn.magFilter:hi,gt.minFilter=sn.minFilter!==void 0?sn.minFilter:hi,gt.anisotropy=sn.anisotropy!==void 0?sn.anisotropy:1,sn.format!==void 0&&(gt.format=sn.format),sn.type!==void 0&&(gt.type=sn.type),sn.mipmaps!==void 0&&(gt.mipmaps=sn.mipmaps,gt.minFilter=Ra),sn.mipmapCount===1&&(gt.minFilter=hi),gt.needsUpdate=!0,E&&E(gt,sn))},W,ge),gt}}),ra.prototype=Object.assign(Object.create(Ze.prototype),{constructor:ra,load:function(f,E,W,ge){this.path!==void 0&&(f=this.path+f),f=this.manager.resolveURL(f);var ct=this,gt=zf.get(f);if(gt!==void 0)return ct.manager.itemStart(f),setTimeout(function(){E&&E(gt),ct.manager.itemEnd(f)},0),gt;var St=document.createElementNS("http://www.w3.org/1999/xhtml","img");function Pt(){St.removeEventListener("load",Pt,!1),St.removeEventListener("error",sn,!1),zf.add(f,this),E&&E(this),ct.manager.itemEnd(f)}function sn(ln){St.removeEventListener("load",Pt,!1),St.removeEventListener("error",sn,!1),ge&&ge(ln),ct.manager.itemError(f),ct.manager.itemEnd(f)}return St.addEventListener("load",Pt,!1),St.addEventListener("error",sn,!1),f.substr(0,5)!=="data:"&&this.crossOrigin!==void 0&&(St.crossOrigin=this.crossOrigin),ct.manager.itemStart(f),St.src=f,St}}),Ca.prototype=Object.assign(Object.create(Ze.prototype),{constructor:Ca,load:function(f,E,W,ge){var ct=new ep,gt=new ra(this.manager);gt.setCrossOrigin(this.crossOrigin),gt.setPath(this.path);var St=0;function Pt(ln){gt.load(f[ln],function(Sn){ct.images[ln]=Sn,++St==6&&(ct.needsUpdate=!0,E&&E(ct))},void 0,ge)}for(var sn=0;sn<f.length;++sn)Pt(sn);return ct}}),La.prototype=Object.assign(Object.create(Ze.prototype),{constructor:La,load:function(f,E,W,ge){var ct=new Ql,gt=new ra(this.manager);return gt.setCrossOrigin(this.crossOrigin),gt.setPath(this.path),gt.load(f,function(St){ct.image=St;var Pt=0<f.search(/\.jpe?g($|\?)/i)||f.search(/^data\:image\/jpeg/)===0;ct.format=Pt?il:zr,ct.needsUpdate=!0,E!==void 0&&E(ct)},W,ge),ct}}),Object.assign(Oa.prototype,{getPoint:function(){return console.warn("THREE.Curve: .getPoint() not implemented."),null},getPointAt:function(f,E){var W=this.getUtoTmapping(f);return this.getPoint(W,E)},getPoints:function(f){f===void 0&&(f=5);for(var E=[],W=0;W<=f;W++)E.push(this.getPoint(W/f));return E},getSpacedPoints:function(f){f===void 0&&(f=5);for(var E=[],W=0;W<=f;W++)E.push(this.getPointAt(W/f));return E},getLength:function(){var f=this.getLengths();return f[f.length-1]},getLengths:function(f){if(f===void 0&&(f=this.arcLengthDivisions),this.cacheArcLengths&&this.cacheArcLengths.length===f+1&&!this.needsUpdate)return this.cacheArcLengths;this.needsUpdate=!1;var E,W,ge=[],ct=this.getPoint(0),gt=0;for(ge.push(0),W=1;W<=f;W++)gt+=(E=this.getPoint(W/f)).distanceTo(ct),ge.push(gt),ct=E;return this.cacheArcLengths=ge},updateArcLengths:function(){this.needsUpdate=!0,this.getLengths()},getUtoTmapping:function(f,E){var W,ge=this.getLengths(),ct=0,gt=ge.length;W=E||f*ge[gt-1];for(var St,Pt=0,sn=gt-1;Pt<=sn;)if((St=ge[ct=Math.floor(Pt+(sn-Pt)/2)]-W)<0)Pt=ct+1;else{if(!(0<St)){sn=ct;break}sn=ct-1}if(ge[ct=sn]===W)return ct/(gt-1);var ln=ge[ct];return(ct+(W-ln)/(ge[ct+1]-ln))/(gt-1)},getTangent:function(f){var E=f-1e-4,W=f+1e-4;E<0&&(E=0),1<W&&(W=1);var ge=this.getPoint(E);return this.getPoint(W).clone().sub(ge).normalize()},getTangentAt:function(f){var E=this.getUtoTmapping(f);return this.getTangent(E)},computeFrenetFrames:function(f,E){var W,ge,ct,gt=new yi,St=[],Pt=[],sn=[],ln=new yi,Sn=new Vo;for(W=0;W<=f;W++)ge=W/f,St[W]=this.getTangentAt(ge),St[W].normalize();Pt[0]=new yi,sn[0]=new yi;var En=Number.MAX_VALUE,On=Math.abs(St[0].x),mn=Math.abs(St[0].y),Hn=Math.abs(St[0].z);for(On<=En&&(En=On,gt.set(1,0,0)),mn<=En&&(En=mn,gt.set(0,1,0)),Hn<=En&>.set(0,0,1),ln.crossVectors(St[0],gt).normalize(),Pt[0].crossVectors(St[0],ln),sn[0].crossVectors(St[0],Pt[0]),W=1;W<=f;W++)Pt[W]=Pt[W-1].clone(),sn[W]=sn[W-1].clone(),ln.crossVectors(St[W-1],St[W]),ln.length()>Number.EPSILON&&(ln.normalize(),ct=Math.acos(js.clamp(St[W-1].dot(St[W]),-1,1)),Pt[W].applyMatrix4(Sn.makeRotationAxis(ln,ct))),sn[W].crossVectors(St[W],Pt[W]);if(E===!0)for(ct=Math.acos(js.clamp(Pt[0].dot(Pt[f]),-1,1)),ct/=f,0<St[0].dot(ln.crossVectors(Pt[0],Pt[f]))&&(ct=-ct),W=1;W<=f;W++)Pt[W].applyMatrix4(Sn.makeRotationAxis(St[W],ct*W)),sn[W].crossVectors(St[W],Pt[W]);return{tangents:St,normals:Pt,binormals:sn}},clone:function(){return new this.constructor().copy(this)},copy:function(f){return this.arcLengthDivisions=f.arcLengthDivisions,this},toJSON:function(){var f={metadata:{version:4.5,type:"Curve",generator:"Curve.toJSON"}};return f.arcLengthDivisions=this.arcLengthDivisions,f.type=this.type,f},fromJSON:function(f){return this.arcLengthDivisions=f.arcLengthDivisions,this}}),((fo.prototype=Object.create(Oa.prototype)).constructor=fo).prototype.isEllipseCurve=!0,fo.prototype.getPoint=function(f,E){for(var W=E||new co,ge=2*Math.PI,ct=this.aEndAngle-this.aStartAngle,gt=Math.abs(ct)<Number.EPSILON;ct<0;)ct+=ge;for(;ge<ct;)ct-=ge;ct<Number.EPSILON&&(ct=gt?0:ge),this.aClockwise!==!0||gt||(ct===ge?ct=-ge:ct-=ge);var St=this.aStartAngle+f*ct,Pt=this.aX+this.xRadius*Math.cos(St),sn=this.aY+this.yRadius*Math.sin(St);if(this.aRotation!==0){var ln=Math.cos(this.aRotation),Sn=Math.sin(this.aRotation),En=Pt-this.aX,On=sn-this.aY;Pt=En*ln-On*Sn+this.aX,sn=En*Sn+On*ln+this.aY}return W.set(Pt,sn)},fo.prototype.copy=function(f){return Oa.prototype.copy.call(this,f),this.aX=f.aX,this.aY=f.aY,this.xRadius=f.xRadius,this.yRadius=f.yRadius,this.aStartAngle=f.aStartAngle,this.aEndAngle=f.aEndAngle,this.aClockwise=f.aClockwise,this.aRotation=f.aRotation,this},fo.prototype.toJSON=function(){var f=Oa.prototype.toJSON.call(this);return f.aX=this.aX,f.aY=this.aY,f.xRadius=this.xRadius,f.yRadius=this.yRadius,f.aStartAngle=this.aStartAngle,f.aEndAngle=this.aEndAngle,f.aClockwise=this.aClockwise,f.aRotation=this.aRotation,f},fo.prototype.fromJSON=function(f){return Oa.prototype.fromJSON.call(this,f),this.aX=f.aX,this.aY=f.aY,this.xRadius=f.xRadius,this.yRadius=f.yRadius,this.aStartAngle=f.aStartAngle,this.aEndAngle=f.aEndAngle,this.aClockwise=f.aClockwise,this.aRotation=f.aRotation,this},((Ho.prototype=Object.create(fo.prototype)).constructor=Ho).prototype.isArcCurve=!0;var Ys=new yi,_l=new qs,Mo=new qs,es=new qs;function Qs(f,E,W,ge){Oa.call(this),this.type="CatmullRomCurve3",this.points=f||[],this.closed=E||!1,this.curveType=W||"centripetal",this.tension=ge||.5}function Ms(f,E,W,ge,ct){var gt=.5*(ge-E),St=.5*(ct-W),Pt=f*f;return(2*W-2*ge+gt+St)*(f*Pt)+(-3*W+3*ge-2*gt-St)*Pt+gt*f+W}function Tl(f,E,W,ge){return(St=1-f)*St*E+2*(1-(gt=f))*gt*W+(ct=f)*ct*ge;var ct,gt,St}function Al(f,E,W,ge,ct){return(ln=1-f)*ln*ln*E+3*(sn=1-(Pt=f))*sn*Pt*W+3*(1-(St=f))*St*St*ge+(gt=f)*gt*gt*ct;var gt,St,Pt,sn,ln}function au(f,E,W,ge){Oa.call(this),this.type="CubicBezierCurve",this.v0=f||new co,this.v1=E||new co,this.v2=W||new co,this.v3=ge||new co}function sl(f,E,W,ge){Oa.call(this),this.type="CubicBezierCurve3",this.v0=f||new yi,this.v1=E||new yi,this.v2=W||new yi,this.v3=ge||new yi}function cl(f,E){Oa.call(this),this.type="LineCurve",this.v1=f||new co,this.v2=E||new co}function wc(f,E){Oa.call(this),this.type="LineCurve3",this.v1=f||new yi,this.v2=E||new yi}function nc(f,E,W){Oa.call(this),this.type="QuadraticBezierCurve",this.v0=f||new co,this.v1=E||new co,this.v2=W||new co}function Wc(f,E,W){Oa.call(this),this.type="QuadraticBezierCurve3",this.v0=f||new yi,this.v1=E||new yi,this.v2=W||new yi}function pu(f){Oa.call(this),this.type="SplineCurve",this.points=f||[]}((Qs.prototype=Object.create(Oa.prototype)).constructor=Qs).prototype.isCatmullRomCurve3=!0,Qs.prototype.getPoint=function(f,E){var W,ge,ct,gt,St=E||new yi,Pt=this.points,sn=Pt.length,ln=(sn-(this.closed?0:1))*f,Sn=Math.floor(ln),En=ln-Sn;if(this.closed?Sn+=0<Sn?0:(Math.floor(Math.abs(Sn)/sn)+1)*sn:En===0&&Sn===sn-1&&(Sn=sn-2,En=1),W=this.closed||0<Sn?Pt[(Sn-1)%sn]:(Ys.subVectors(Pt[0],Pt[1]).add(Pt[0]),Ys),ge=Pt[Sn%sn],ct=Pt[(Sn+1)%sn],gt=this.closed||Sn+2<sn?Pt[(Sn+2)%sn]:(Ys.subVectors(Pt[sn-1],Pt[sn-2]).add(Pt[sn-1]),Ys),this.curveType==="centripetal"||this.curveType==="chordal"){var On=this.curveType==="chordal"?.5:.25,mn=Math.pow(W.distanceToSquared(ge),On),Hn=Math.pow(ge.distanceToSquared(ct),On),mr=Math.pow(ct.distanceToSquared(gt),On);Hn<1e-4&&(Hn=1),mn<1e-4&&(mn=Hn),mr<1e-4&&(mr=Hn),_l.initNonuniformCatmullRom(W.x,ge.x,ct.x,gt.x,mn,Hn,mr),Mo.initNonuniformCatmullRom(W.y,ge.y,ct.y,gt.y,mn,Hn,mr),es.initNonuniformCatmullRom(W.z,ge.z,ct.z,gt.z,mn,Hn,mr)}else this.curveType==="catmullrom"&&(_l.initCatmullRom(W.x,ge.x,ct.x,gt.x,this.tension),Mo.initCatmullRom(W.y,ge.y,ct.y,gt.y,this.tension),es.initCatmullRom(W.z,ge.z,ct.z,gt.z,this.tension));return St.set(_l.calc(En),Mo.calc(En),es.calc(En)),St},Qs.prototype.copy=function(f){Oa.prototype.copy.call(this,f),this.points=[];for(var E=0,W=f.points.length;E<W;E++){var ge=f.points[E];this.points.push(ge.clone())}return this.closed=f.closed,this.curveType=f.curveType,this.tension=f.tension,this},Qs.prototype.toJSON=function(){var f=Oa.prototype.toJSON.call(this);f.points=[];for(var E=0,W=this.points.length;E<W;E++){var ge=this.points[E];f.points.push(ge.toArray())}return f.closed=this.closed,f.curveType=this.curveType,f.tension=this.tension,f},Qs.prototype.fromJSON=function(f){Oa.prototype.fromJSON.call(this,f),this.points=[];for(var E=0,W=f.points.length;E<W;E++){var ge=f.points[E];this.points.push(new yi().fromArray(ge))}return this.closed=f.closed,this.curveType=f.curveType,this.tension=f.tension,this},((au.prototype=Object.create(Oa.prototype)).constructor=au).prototype.isCubicBezierCurve=!0,au.prototype.getPoint=function(f,E){var W=E||new co,ge=this.v0,ct=this.v1,gt=this.v2,St=this.v3;return W.set(Al(f,ge.x,ct.x,gt.x,St.x),Al(f,ge.y,ct.y,gt.y,St.y)),W},au.prototype.copy=function(f){return Oa.prototype.copy.call(this,f),this.v0.copy(f.v0),this.v1.copy(f.v1),this.v2.copy(f.v2),this.v3.copy(f.v3),this},au.prototype.toJSON=function(){var f=Oa.prototype.toJSON.call(this);return f.v0=this.v0.toArray(),f.v1=this.v1.toArray(),f.v2=this.v2.toArray(),f.v3=this.v3.toArray(),f},au.prototype.fromJSON=function(f){return Oa.prototype.fromJSON.call(this,f),this.v0.fromArray(f.v0),this.v1.fromArray(f.v1),this.v2.fromArray(f.v2),this.v3.fromArray(f.v3),this},((sl.prototype=Object.create(Oa.prototype)).constructor=sl).prototype.isCubicBezierCurve3=!0,sl.prototype.getPoint=function(f,E){var W=E||new yi,ge=this.v0,ct=this.v1,gt=this.v2,St=this.v3;return W.set(Al(f,ge.x,ct.x,gt.x,St.x),Al(f,ge.y,ct.y,gt.y,St.y),Al(f,ge.z,ct.z,gt.z,St.z)),W},sl.prototype.copy=function(f){return Oa.prototype.copy.call(this,f),this.v0.copy(f.v0),this.v1.copy(f.v1),this.v2.copy(f.v2),this.v3.copy(f.v3),this},sl.prototype.toJSON=function(){var f=Oa.prototype.toJSON.call(this);return f.v0=this.v0.toArray(),f.v1=this.v1.toArray(),f.v2=this.v2.toArray(),f.v3=this.v3.toArray(),f},sl.prototype.fromJSON=function(f){return Oa.prototype.fromJSON.call(this,f),this.v0.fromArray(f.v0),this.v1.fromArray(f.v1),this.v2.fromArray(f.v2),this.v3.fromArray(f.v3),this},((cl.prototype=Object.create(Oa.prototype)).constructor=cl).prototype.isLineCurve=!0,cl.prototype.getPoint=function(f,E){var W=E||new co;return f===1?W.copy(this.v2):(W.copy(this.v2).sub(this.v1),W.multiplyScalar(f).add(this.v1)),W},cl.prototype.getPointAt=function(f,E){return this.getPoint(f,E)},cl.prototype.getTangent=function(){return this.v2.clone().sub(this.v1).normalize()},cl.prototype.copy=function(f){return Oa.prototype.copy.call(this,f),this.v1.copy(f.v1),this.v2.copy(f.v2),this},cl.prototype.toJSON=function(){var f=Oa.prototype.toJSON.call(this);return f.v1=this.v1.toArray(),f.v2=this.v2.toArray(),f},cl.prototype.fromJSON=function(f){return Oa.prototype.fromJSON.call(this,f),this.v1.fromArray(f.v1),this.v2.fromArray(f.v2),this},((wc.prototype=Object.create(Oa.prototype)).constructor=wc).prototype.isLineCurve3=!0,wc.prototype.getPoint=function(f,E){var W=E||new yi;return f===1?W.copy(this.v2):(W.copy(this.v2).sub(this.v1),W.multiplyScalar(f).add(this.v1)),W},wc.prototype.getPointAt=function(f,E){return this.getPoint(f,E)},wc.prototype.copy=function(f){return Oa.prototype.copy.call(this,f),this.v1.copy(f.v1),this.v2.copy(f.v2),this},wc.prototype.toJSON=function(){var f=Oa.prototype.toJSON.call(this);return f.v1=this.v1.toArray(),f.v2=this.v2.toArray(),f},wc.prototype.fromJSON=function(f){return Oa.prototype.fromJSON.call(this,f),this.v1.fromArray(f.v1),this.v2.fromArray(f.v2),this},((nc.prototype=Object.create(Oa.prototype)).constructor=nc).prototype.isQuadraticBezierCurve=!0,nc.prototype.getPoint=function(f,E){var W=E||new co,ge=this.v0,ct=this.v1,gt=this.v2;return W.set(Tl(f,ge.x,ct.x,gt.x),Tl(f,ge.y,ct.y,gt.y)),W},nc.prototype.copy=function(f){return Oa.prototype.copy.call(this,f),this.v0.copy(f.v0),this.v1.copy(f.v1),this.v2.copy(f.v2),this},nc.prototype.toJSON=function(){var f=Oa.prototype.toJSON.call(this);return f.v0=this.v0.toArray(),f.v1=this.v1.toArray(),f.v2=this.v2.toArray(),f},nc.prototype.fromJSON=function(f){return Oa.prototype.fromJSON.call(this,f),this.v0.fromArray(f.v0),this.v1.fromArray(f.v1),this.v2.fromArray(f.v2),this},((Wc.prototype=Object.create(Oa.prototype)).constructor=Wc).prototype.isQuadraticBezierCurve3=!0,Wc.prototype.getPoint=function(f,E){var W=E||new yi,ge=this.v0,ct=this.v1,gt=this.v2;return W.set(Tl(f,ge.x,ct.x,gt.x),Tl(f,ge.y,ct.y,gt.y),Tl(f,ge.z,ct.z,gt.z)),W},Wc.prototype.copy=function(f){return Oa.prototype.copy.call(this,f),this.v0.copy(f.v0),this.v1.copy(f.v1),this.v2.copy(f.v2),this},Wc.prototype.toJSON=function(){var f=Oa.prototype.toJSON.call(this);return f.v0=this.v0.toArray(),f.v1=this.v1.toArray(),f.v2=this.v2.toArray(),f},Wc.prototype.fromJSON=function(f){return Oa.prototype.fromJSON.call(this,f),this.v0.fromArray(f.v0),this.v1.fromArray(f.v1),this.v2.fromArray(f.v2),this},((pu.prototype=Object.create(Oa.prototype)).constructor=pu).prototype.isSplineCurve=!0,pu.prototype.getPoint=function(f,E){var W=E||new co,ge=this.points,ct=(ge.length-1)*f,gt=Math.floor(ct),St=ct-gt,Pt=ge[gt===0?gt:gt-1],sn=ge[gt],ln=ge[gt>ge.length-2?ge.length-1:gt+1],Sn=ge[gt>ge.length-3?ge.length-1:gt+2];return W.set(Ms(St,Pt.x,sn.x,ln.x,Sn.x),Ms(St,Pt.y,sn.y,ln.y,Sn.y)),W},pu.prototype.copy=function(f){Oa.prototype.copy.call(this,f),this.points=[];for(var E=0,W=f.points.length;E<W;E++){var ge=f.points[E];this.points.push(ge.clone())}return this},pu.prototype.toJSON=function(){var f=Oa.prototype.toJSON.call(this);f.points=[];for(var E=0,W=this.points.length;E<W;E++){var ge=this.points[E];f.points.push(ge.toArray())}return f},pu.prototype.fromJSON=function(f){Oa.prototype.fromJSON.call(this,f),this.points=[];for(var E=0,W=f.points.length;E<W;E++){var ge=f.points[E];this.points.push(new co().fromArray(ge))}return this};var Dd=Object.freeze({__proto__:null,ArcCurve:Ho,CatmullRomCurve3:Qs,CubicBezierCurve:au,CubicBezierCurve3:sl,EllipseCurve:fo,LineCurve:cl,LineCurve3:wc,QuadraticBezierCurve:nc,QuadraticBezierCurve3:Wc,SplineCurve:pu});function Ed(){Oa.call(this),this.type="CurvePath",this.curves=[],this.autoClose=!1}function md(f){Ed.call(this),this.type="Path",this.currentPoint=new co,f&&this.setFromPoints(f)}function th(f){md.call(this,f),this.uuid=js.generateUUID(),this.type="Shape",this.holes=[]}function Eu(f,E){Ri.call(this),this.type="Light",this.color=new la(f),this.intensity=E!==void 0?E:1,this.receiveShadow=void 0}function Xm(f,E,W){Eu.call(this,f,W),this.type="HemisphereLight",this.castShadow=void 0,this.position.copy(Ri.DefaultUp),this.updateMatrix(),this.groundColor=new la(E)}function Vd(f){this.camera=f,this.bias=0,this.radius=1,this.mapSize=new co(512,512),this.map=null,this.mapPass=null,this.matrix=new Vo,this._frustum=new Ih,this._frameExtents=new co(1,1),this._viewportCount=1,this._viewports=[new Ll(0,0,1,1)]}function Dp(){Vd.call(this,new cc(50,1,.5,500))}function gm(f,E,W,ge,ct,gt){Eu.call(this,f,E),this.type="SpotLight",this.position.copy(Ri.DefaultUp),this.updateMatrix(),this.target=new Ri,Object.defineProperty(this,"power",{get:function(){return this.intensity*Math.PI},set:function(St){this.intensity=St/Math.PI}}),this.distance=W!==void 0?W:0,this.angle=ge!==void 0?ge:Math.PI/3,this.penumbra=ct!==void 0?ct:0,this.decay=gt!==void 0?gt:1,this.shadow=new Dp}function ym(){Vd.call(this,new cc(90,1,.5,500)),this._frameExtents=new co(4,2),this._viewportCount=6,this._viewports=[new Ll(2,1,1,1),new Ll(0,1,1,1),new Ll(3,1,1,1),new Ll(1,1,1,1),new Ll(3,0,1,1),new Ll(1,0,1,1)],this._cubeDirections=[new yi(1,0,0),new yi(-1,0,0),new yi(0,0,1),new yi(0,0,-1),new yi(0,1,0),new yi(0,-1,0)],this._cubeUps=[new yi(0,1,0),new yi(0,1,0),new yi(0,1,0),new yi(0,1,0),new yi(0,0,1),new yi(0,0,-1)]}function ip(f,E,W,ge){Eu.call(this,f,E),this.type="PointLight",Object.defineProperty(this,"power",{get:function(){return 4*this.intensity*Math.PI},set:function(ct){this.intensity=ct/(4*Math.PI)}}),this.distance=W!==void 0?W:0,this.decay=ge!==void 0?ge:1,this.shadow=new ym}function ap(f,E,W,ge,ct,gt){Gd.call(this),this.type="OrthographicCamera",this.zoom=1,this.view=null,this.left=f!==void 0?f:-1,this.right=E!==void 0?E:1,this.top=W!==void 0?W:1,this.bottom=ge!==void 0?ge:-1,this.near=ct!==void 0?ct:.1,this.far=gt!==void 0?gt:2e3,this.updateProjectionMatrix()}function vf(){Vd.call(this,new ap(-5,5,5,-5,.5,500))}function op(f,E){Eu.call(this,f,E),this.type="DirectionalLight",this.position.copy(Ri.DefaultUp),this.updateMatrix(),this.target=new Ri,this.shadow=new vf}function tg(f,E){Eu.call(this,f,E),this.type="AmbientLight",this.castShadow=void 0}function ng(f,E,W,ge){Eu.call(this,f,E),this.type="RectAreaLight",this.width=W!==void 0?W:10,this.height=ge!==void 0?ge:10}function vm(f){Ze.call(this,f),this.textures={}}Ed.prototype=Object.assign(Object.create(Oa.prototype),{constructor:Ed,add:function(f){this.curves.push(f)},closePath:function(){var f=this.curves[0].getPoint(0),E=this.curves[this.curves.length-1].getPoint(1);f.equals(E)||this.curves.push(new cl(E,f))},getPoint:function(f){for(var E=f*this.getLength(),W=this.getCurveLengths(),ge=0;ge<W.length;){if(W[ge]>=E){var ct=W[ge]-E,gt=this.curves[ge],St=gt.getLength(),Pt=St===0?0:1-ct/St;return gt.getPointAt(Pt)}ge++}return null},getLength:function(){var f=this.getCurveLengths();return f[f.length-1]},updateArcLengths:function(){this.needsUpdate=!0,this.cacheLengths=null,this.getCurveLengths()},getCurveLengths:function(){if(this.cacheLengths&&this.cacheLengths.length===this.curves.length)return this.cacheLengths;for(var f=[],E=0,W=0,ge=this.curves.length;W<ge;W++)E+=this.curves[W].getLength(),f.push(E);return this.cacheLengths=f},getSpacedPoints:function(f){f===void 0&&(f=40);for(var E=[],W=0;W<=f;W++)E.push(this.getPoint(W/f));return this.autoClose&&E.push(E[0]),E},getPoints:function(f){f=f||12;for(var E,W=[],ge=0,ct=this.curves;ge<ct.length;ge++)for(var gt=ct[ge],St=gt&>.isEllipseCurve?2*f:gt&&(gt.isLineCurve||gt.isLineCurve3)?1:gt&>.isSplineCurve?f*gt.points.length:f,Pt=gt.getPoints(St),sn=0;sn<Pt.length;sn++){var ln=Pt[sn];E&&E.equals(ln)||(W.push(ln),E=ln)}return this.autoClose&&1<W.length&&!W[W.length-1].equals(W[0])&&W.push(W[0]),W},copy:function(f){Oa.prototype.copy.call(this,f),this.curves=[];for(var E=0,W=f.curves.length;E<W;E++){var ge=f.curves[E];this.curves.push(ge.clone())}return this.autoClose=f.autoClose,this},toJSON:function(){var f=Oa.prototype.toJSON.call(this);f.autoClose=this.autoClose,f.curves=[];for(var E=0,W=this.curves.length;E<W;E++){var ge=this.curves[E];f.curves.push(ge.toJSON())}return f},fromJSON:function(f){Oa.prototype.fromJSON.call(this,f),this.autoClose=f.autoClose,this.curves=[];for(var E=0,W=f.curves.length;E<W;E++){var ge=f.curves[E];this.curves.push(new Dd[ge.type]().fromJSON(ge))}return this}}),md.prototype=Object.assign(Object.create(Ed.prototype),{constructor:md,setFromPoints:function(f){this.moveTo(f[0].x,f[0].y);for(var E=1,W=f.length;E<W;E++)this.lineTo(f[E].x,f[E].y);return this},moveTo:function(f,E){return this.currentPoint.set(f,E),this},lineTo:function(f,E){var W=new cl(this.currentPoint.clone(),new co(f,E));return this.curves.push(W),this.currentPoint.set(f,E),this},quadraticCurveTo:function(f,E,W,ge){var ct=new nc(this.currentPoint.clone(),new co(f,E),new co(W,ge));return this.curves.push(ct),this.currentPoint.set(W,ge),this},bezierCurveTo:function(f,E,W,ge,ct,gt){var St=new au(this.currentPoint.clone(),new co(f,E),new co(W,ge),new co(ct,gt));return this.curves.push(St),this.currentPoint.set(ct,gt),this},splineThru:function(f){var E=new pu([this.currentPoint.clone()].concat(f));return this.curves.push(E),this.currentPoint.copy(f[f.length-1]),this},arc:function(f,E,W,ge,ct,gt){var St=this.currentPoint.x,Pt=this.currentPoint.y;return this.absarc(f+St,E+Pt,W,ge,ct,gt),this},absarc:function(f,E,W,ge,ct,gt){return this.absellipse(f,E,W,W,ge,ct,gt),this},ellipse:function(f,E,W,ge,ct,gt,St,Pt){var sn=this.currentPoint.x,ln=this.currentPoint.y;return this.absellipse(f+sn,E+ln,W,ge,ct,gt,St,Pt),this},absellipse:function(f,E,W,ge,ct,gt,St,Pt){var sn=new fo(f,E,W,ge,ct,gt,St,Pt);if(0<this.curves.length){var ln=sn.getPoint(0);ln.equals(this.currentPoint)||this.lineTo(ln.x,ln.y)}this.curves.push(sn);var Sn=sn.getPoint(1);return this.currentPoint.copy(Sn),this},copy:function(f){return Ed.prototype.copy.call(this,f),this.currentPoint.copy(f.currentPoint),this},toJSON:function(){var f=Ed.prototype.toJSON.call(this);return f.currentPoint=this.currentPoint.toArray(),f},fromJSON:function(f){return Ed.prototype.fromJSON.call(this,f),this.currentPoint.fromArray(f.currentPoint),this}}),th.prototype=Object.assign(Object.create(md.prototype),{constructor:th,getPointsHoles:function(f){for(var E=[],W=0,ge=this.holes.length;W<ge;W++)E[W]=this.holes[W].getPoints(f);return E},extractPoints:function(f){return{shape:this.getPoints(f),holes:this.getPointsHoles(f)}},copy:function(f){md.prototype.copy.call(this,f),this.holes=[];for(var E=0,W=f.holes.length;E<W;E++){var ge=f.holes[E];this.holes.push(ge.clone())}return this},toJSON:function(){var f=md.prototype.toJSON.call(this);f.uuid=this.uuid,f.holes=[];for(var E=0,W=this.holes.length;E<W;E++){var ge=this.holes[E];f.holes.push(ge.toJSON())}return f},fromJSON:function(f){md.prototype.fromJSON.call(this,f),this.uuid=f.uuid,this.holes=[];for(var E=0,W=f.holes.length;E<W;E++){var ge=f.holes[E];this.holes.push(new md().fromJSON(ge))}return this}}),Eu.prototype=Object.assign(Object.create(Ri.prototype),{constructor:Eu,isLight:!0,copy:function(f){return Ri.prototype.copy.call(this,f),this.color.copy(f.color),this.intensity=f.intensity,this},toJSON:function(f){var E=Ri.prototype.toJSON.call(this,f);return E.object.color=this.color.getHex(),E.object.intensity=this.intensity,this.groundColor!==void 0&&(E.object.groundColor=this.groundColor.getHex()),this.distance!==void 0&&(E.object.distance=this.distance),this.angle!==void 0&&(E.object.angle=this.angle),this.decay!==void 0&&(E.object.decay=this.decay),this.penumbra!==void 0&&(E.object.penumbra=this.penumbra),this.shadow!==void 0&&(E.object.shadow=this.shadow.toJSON()),E}}),Xm.prototype=Object.assign(Object.create(Eu.prototype),{constructor:Xm,isHemisphereLight:!0,copy:function(f){return Eu.prototype.copy.call(this,f),this.groundColor.copy(f.groundColor),this}}),Object.assign(Vd.prototype,{_projScreenMatrix:new Vo,_lightPositionWorld:new yi,_lookTarget:new yi,getViewportCount:function(){return this._viewportCount},getFrustum:function(){return this._frustum},updateMatrices:function(f){var E=this.camera,W=this.matrix,ge=this._projScreenMatrix,ct=this._lookTarget,gt=this._lightPositionWorld;gt.setFromMatrixPosition(f.matrixWorld),E.position.copy(gt),ct.setFromMatrixPosition(f.target.matrixWorld),E.lookAt(ct),E.updateMatrixWorld(),ge.multiplyMatrices(E.projectionMatrix,E.matrixWorldInverse),this._frustum.setFromProjectionMatrix(ge),W.set(.5,0,0,.5,0,.5,0,.5,0,0,.5,.5,0,0,0,1),W.multiply(E.projectionMatrix),W.multiply(E.matrixWorldInverse)},getViewport:function(f){return this._viewports[f]},getFrameExtents:function(){return this._frameExtents},copy:function(f){return this.camera=f.camera.clone(),this.bias=f.bias,this.radius=f.radius,this.mapSize.copy(f.mapSize),this},clone:function(){return new this.constructor().copy(this)},toJSON:function(){var f={};return this.bias!==0&&(f.bias=this.bias),this.radius!==1&&(f.radius=this.radius),this.mapSize.x===512&&this.mapSize.y===512||(f.mapSize=this.mapSize.toArray()),f.camera=this.camera.toJSON(!1).object,delete f.camera.matrix,f}}),Dp.prototype=Object.assign(Object.create(Vd.prototype),{constructor:Dp,isSpotLightShadow:!0,updateMatrices:function(f){var E=this.camera,W=2*js.RAD2DEG*f.angle,ge=this.mapSize.width/this.mapSize.height,ct=f.distance||E.far;W===E.fov&&ge===E.aspect&&ct===E.far||(E.fov=W,E.aspect=ge,E.far=ct,E.updateProjectionMatrix()),Vd.prototype.updateMatrices.call(this,f)}}),gm.prototype=Object.assign(Object.create(Eu.prototype),{constructor:gm,isSpotLight:!0,copy:function(f){return Eu.prototype.copy.call(this,f),this.distance=f.distance,this.angle=f.angle,this.penumbra=f.penumbra,this.decay=f.decay,this.target=f.target.clone(),this.shadow=f.shadow.clone(),this}}),ym.prototype=Object.assign(Object.create(Vd.prototype),{constructor:ym,isPointLightShadow:!0,updateMatrices:function(f,E){E===void 0&&(E=0);var W=this.camera,ge=this.matrix,ct=this._lightPositionWorld,gt=this._lookTarget,St=this._projScreenMatrix;ct.setFromMatrixPosition(f.matrixWorld),W.position.copy(ct),gt.copy(W.position),gt.add(this._cubeDirections[E]),W.up.copy(this._cubeUps[E]),W.lookAt(gt),W.updateMatrixWorld(),ge.makeTranslation(-ct.x,-ct.y,-ct.z),St.multiplyMatrices(W.projectionMatrix,W.matrixWorldInverse),this._frustum.setFromProjectionMatrix(St)}}),ip.prototype=Object.assign(Object.create(Eu.prototype),{constructor:ip,isPointLight:!0,copy:function(f){return Eu.prototype.copy.call(this,f),this.distance=f.distance,this.decay=f.decay,this.shadow=f.shadow.clone(),this}}),ap.prototype=Object.assign(Object.create(Gd.prototype),{constructor:ap,isOrthographicCamera:!0,copy:function(f,E){return Gd.prototype.copy.call(this,f,E),this.left=f.left,this.right=f.right,this.top=f.top,this.bottom=f.bottom,this.near=f.near,this.far=f.far,this.zoom=f.zoom,this.view=f.view===null?null:Object.assign({},f.view),this},setViewOffset:function(f,E,W,ge,ct,gt){this.view===null&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=f,this.view.fullHeight=E,this.view.offsetX=W,this.view.offsetY=ge,this.view.width=ct,this.view.height=gt,this.updateProjectionMatrix()},clearViewOffset:function(){this.view!==null&&(this.view.enabled=!1),this.updateProjectionMatrix()},updateProjectionMatrix:function(){var f=(this.right-this.left)/(2*this.zoom),E=(this.top-this.bottom)/(2*this.zoom),W=(this.right+this.left)/2,ge=(this.top+this.bottom)/2,ct=W-f,gt=W+f,St=ge+E,Pt=ge-E;if(this.view!==null&&this.view.enabled){var sn=(this.right-this.left)/this.view.fullWidth/this.zoom,ln=(this.top-this.bottom)/this.view.fullHeight/this.zoom;gt=(ct+=sn*this.view.offsetX)+sn*this.view.width,Pt=(St-=ln*this.view.offsetY)-ln*this.view.height}this.projectionMatrix.makeOrthographic(ct,gt,St,Pt,this.near,this.far),this.projectionMatrixInverse.getInverse(this.projectionMatrix)},toJSON:function(f){var E=Ri.prototype.toJSON.call(this,f);return E.object.zoom=this.zoom,E.object.left=this.left,E.object.right=this.right,E.object.top=this.top,E.object.bottom=this.bottom,E.object.near=this.near,E.object.far=this.far,this.view!==null&&(E.object.view=Object.assign({},this.view)),E}}),vf.prototype=Object.assign(Object.create(Vd.prototype),{constructor:vf,isDirectionalLightShadow:!0,updateMatrices:function(f){Vd.prototype.updateMatrices.call(this,f)}}),op.prototype=Object.assign(Object.create(Eu.prototype),{constructor:op,isDirectionalLight:!0,copy:function(f){return Eu.prototype.copy.call(this,f),this.target=f.target.clone(),this.shadow=f.shadow.clone(),this}}),tg.prototype=Object.assign(Object.create(Eu.prototype),{constructor:tg,isAmbientLight:!0}),ng.prototype=Object.assign(Object.create(Eu.prototype),{constructor:ng,isRectAreaLight:!0,copy:function(f){return Eu.prototype.copy.call(this,f),this.width=f.width,this.height=f.height,this},toJSON:function(f){var E=Eu.prototype.toJSON.call(this,f);return E.object.width=this.width,E.object.height=this.height,E}}),vm.prototype=Object.assign(Object.create(Ze.prototype),{constructor:vm,load:function(f,E,W,ge){var ct=this,gt=new on(ct.manager);gt.setPath(ct.path),gt.load(f,function(St){E(ct.parse(JSON.parse(St)))},W,ge)},parse:function(f){var E=this.textures;function W(sn){return E[sn]===void 0&&console.warn("THREE.MaterialLoader: Undefined texture",sn),E[sn]}var ge=new Og[f.type];if(f.uuid!==void 0&&(ge.uuid=f.uuid),f.name!==void 0&&(ge.name=f.name),f.color!==void 0&&ge.color.setHex(f.color),f.roughness!==void 0&&(ge.roughness=f.roughness),f.metalness!==void 0&&(ge.metalness=f.metalness),f.sheen!==void 0&&(ge.sheen=new la().setHex(f.sheen)),f.emissive!==void 0&&ge.emissive.setHex(f.emissive),f.specular!==void 0&&ge.specular.setHex(f.specular),f.shininess!==void 0&&(ge.shininess=f.shininess),f.clearcoat!==void 0&&(ge.clearcoat=f.clearcoat),f.clearcoatRoughness!==void 0&&(ge.clearcoatRoughness=f.clearcoatRoughness),f.vertexColors!==void 0&&(ge.vertexColors=f.vertexColors),f.fog!==void 0&&(ge.fog=f.fog),f.flatShading!==void 0&&(ge.flatShading=f.flatShading),f.blending!==void 0&&(ge.blending=f.blending),f.combine!==void 0&&(ge.combine=f.combine),f.side!==void 0&&(ge.side=f.side),f.opacity!==void 0&&(ge.opacity=f.opacity),f.transparent!==void 0&&(ge.transparent=f.transparent),f.alphaTest!==void 0&&(ge.alphaTest=f.alphaTest),f.depthTest!==void 0&&(ge.depthTest=f.depthTest),f.depthWrite!==void 0&&(ge.depthWrite=f.depthWrite),f.colorWrite!==void 0&&(ge.colorWrite=f.colorWrite),f.stencilWrite!==void 0&&(ge.stencilWrite=f.stencilWrite),f.stencilWriteMask!==void 0&&(ge.stencilWriteMask=f.stencilWriteMask),f.stencilFunc!==void 0&&(ge.stencilFunc=f.stencilFunc),f.stencilRef!==void 0&&(ge.stencilRef=f.stencilRef),f.stencilFuncMask!==void 0&&(ge.stencilFuncMask=f.stencilFuncMask),f.stencilFail!==void 0&&(ge.stencilFail=f.stencilFail),f.stencilZFail!==void 0&&(ge.stencilZFail=f.stencilZFail),f.stencilZPass!==void 0&&(ge.stencilZPass=f.stencilZPass),f.wireframe!==void 0&&(ge.wireframe=f.wireframe),f.wireframeLinewidth!==void 0&&(ge.wireframeLinewidth=f.wireframeLinewidth),f.wireframeLinecap!==void 0&&(ge.wireframeLinecap=f.wireframeLinecap),f.wireframeLinejoin!==void 0&&(ge.wireframeLinejoin=f.wireframeLinejoin),f.rotation!==void 0&&(ge.rotation=f.rotation),f.linewidth!==1&&(ge.linewidth=f.linewidth),f.dashSize!==void 0&&(ge.dashSize=f.dashSize),f.gapSize!==void 0&&(ge.gapSize=f.gapSize),f.scale!==void 0&&(ge.scale=f.scale),f.polygonOffset!==void 0&&(ge.polygonOffset=f.polygonOffset),f.polygonOffsetFactor!==void 0&&(ge.polygonOffsetFactor=f.polygonOffsetFactor),f.polygonOffsetUnits!==void 0&&(ge.polygonOffsetUnits=f.polygonOffsetUnits),f.skinning!==void 0&&(ge.skinning=f.skinning),f.morphTargets!==void 0&&(ge.morphTargets=f.morphTargets),f.morphNormals!==void 0&&(ge.morphNormals=f.morphNormals),f.dithering!==void 0&&(ge.dithering=f.dithering),f.visible!==void 0&&(ge.visible=f.visible),f.toneMapped!==void 0&&(ge.toneMapped=f.toneMapped),f.userData!==void 0&&(ge.userData=f.userData),f.uniforms!==void 0)for(var ct in f.uniforms){var gt=f.uniforms[ct];switch(ge.uniforms[ct]={},gt.type){case"t":ge.uniforms[ct].value=W(gt.value);break;case"c":ge.uniforms[ct].value=new la().setHex(gt.value);break;case"v2":ge.uniforms[ct].value=new co().fromArray(gt.value);break;case"v3":ge.uniforms[ct].value=new yi().fromArray(gt.value);break;case"v4":ge.uniforms[ct].value=new Ll().fromArray(gt.value);break;case"m3":ge.uniforms[ct].value=new Vl().fromArray(gt.value);case"m4":ge.uniforms[ct].value=new Vo().fromArray(gt.value);break;default:ge.uniforms[ct].value=gt.value}}if(f.defines!==void 0&&(ge.defines=f.defines),f.vertexShader!==void 0&&(ge.vertexShader=f.vertexShader),f.fragmentShader!==void 0&&(ge.fragmentShader=f.fragmentShader),f.extensions!==void 0)for(var St in f.extensions)ge.extensions[St]=f.extensions[St];if(f.shading!==void 0&&(ge.flatShading=f.shading===1),f.size!==void 0&&(ge.size=f.size),f.sizeAttenuation!==void 0&&(ge.sizeAttenuation=f.sizeAttenuation),f.map!==void 0&&(ge.map=W(f.map)),f.matcap!==void 0&&(ge.matcap=W(f.matcap)),f.alphaMap!==void 0&&(ge.alphaMap=W(f.alphaMap),ge.transparent=!0),f.bumpMap!==void 0&&(ge.bumpMap=W(f.bumpMap)),f.bumpScale!==void 0&&(ge.bumpScale=f.bumpScale),f.normalMap!==void 0&&(ge.normalMap=W(f.normalMap)),f.normalMapType!==void 0&&(ge.normalMapType=f.normalMapType),f.normalScale!==void 0){var Pt=f.normalScale;Array.isArray(Pt)===!1&&(Pt=[Pt,Pt]),ge.normalScale=new co().fromArray(Pt)}return f.displacementMap!==void 0&&(ge.displacementMap=W(f.displacementMap)),f.displacementScale!==void 0&&(ge.displacementScale=f.displacementScale),f.displacementBias!==void 0&&(ge.displacementBias=f.displacementBias),f.roughnessMap!==void 0&&(ge.roughnessMap=W(f.roughnessMap)),f.metalnessMap!==void 0&&(ge.metalnessMap=W(f.metalnessMap)),f.emissiveMap!==void 0&&(ge.emissiveMap=W(f.emissiveMap)),f.emissiveIntensity!==void 0&&(ge.emissiveIntensity=f.emissiveIntensity),f.specularMap!==void 0&&(ge.specularMap=W(f.specularMap)),f.envMap!==void 0&&(ge.envMap=W(f.envMap)),f.envMapIntensity!==void 0&&(ge.envMapIntensity=f.envMapIntensity),f.reflectivity!==void 0&&(ge.reflectivity=f.reflectivity),f.refractionRatio!==void 0&&(ge.refractionRatio=f.refractionRatio),f.lightMap!==void 0&&(ge.lightMap=W(f.lightMap)),f.lightMapIntensity!==void 0&&(ge.lightMapIntensity=f.lightMapIntensity),f.aoMap!==void 0&&(ge.aoMap=W(f.aoMap)),f.aoMapIntensity!==void 0&&(ge.aoMapIntensity=f.aoMapIntensity),f.gradientMap!==void 0&&(ge.gradientMap=W(f.gradientMap)),f.clearcoatNormalMap!==void 0&&(ge.clearcoatNormalMap=W(f.clearcoatNormalMap)),f.clearcoatNormalScale!==void 0&&(ge.clearcoatNormalScale=new co().fromArray(f.clearcoatNormalScale)),ge},setTextures:function(f){return this.textures=f,this}});var rg={decodeText:function(f){if(typeof TextDecoder<"u")return new TextDecoder().decode(f);for(var E="",W=0,ge=f.length;W<ge;W++)E+=String.fromCharCode(f[W]);try{return decodeURIComponent(escape(E))}catch{return E}},extractUrlBase:function(f){var E=f.lastIndexOf("/");return E===-1?"./":f.substr(0,E+1)}};function O3(){Ds.call(this),this.type="InstancedBufferGeometry",this.maxInstancedCount=void 0}function ig(f,E,W,ge){typeof W=="number"&&(ge=W,W=!1,console.error("THREE.InstancedBufferAttribute: The constructor now expects normalized as the third argument.")),ca.call(this,f,E,W),this.meshPerAttribute=ge||1}function ag(f){Ze.call(this,f)}O3.prototype=Object.assign(Object.create(Ds.prototype),{constructor:O3,isInstancedBufferGeometry:!0,copy:function(f){return Ds.prototype.copy.call(this,f),this.maxInstancedCount=f.maxInstancedCount,this},clone:function(){return new this.constructor().copy(this)},toJSON:function(){var f=Ds.prototype.toJSON.call(this);return f.maxInstancedCount=this.maxInstancedCount,f.isInstancedBufferGeometry=!0,f}}),ig.prototype=Object.assign(Object.create(ca.prototype),{constructor:ig,isInstancedBufferAttribute:!0,copy:function(f){return ca.prototype.copy.call(this,f),this.meshPerAttribute=f.meshPerAttribute,this},toJSON:function(){var f=ca.prototype.toJSON.call(this);return f.meshPerAttribute=this.meshPerAttribute,f.isInstancedBufferAttribute=!0,f}}),ag.prototype=Object.assign(Object.create(Ze.prototype),{constructor:ag,load:function(f,E,W,ge){var ct=this,gt=new on(ct.manager);gt.setPath(ct.path),gt.load(f,function(St){E(ct.parse(JSON.parse(St)))},W,ge)},parse:function(f){var E=new(f.isInstancedBufferGeometry?O3:Ds),W=f.data.index;if(W!==void 0){var ge=new Lg[W.type](W.array);E.setIndex(new ca(ge,1))}var ct=f.data.attributes;for(var gt in ct){var St=ct[gt],Pt=(ge=new Lg[St.type](St.array),new(St.isInstancedBufferAttribute?ig:ca)(ge,St.itemSize,St.normalized));St.name!==void 0&&(Pt.name=St.name),E.setAttribute(gt,Pt)}var sn=f.data.morphAttributes;if(sn)for(var gt in sn){for(var ln=sn[gt],Sn=[],En=0,On=ln.length;En<On;En++)St=ln[En],Pt=new ca(ge=new Lg[St.type](St.array),St.itemSize,St.normalized),St.name!==void 0&&(Pt.name=St.name),Sn.push(Pt);E.morphAttributes[gt]=Sn}f.data.morphTargetsRelative&&(E.morphTargetsRelative=!0);var mn=f.data.groups||f.data.drawcalls||f.data.offsets;if(mn!==void 0){En=0;for(var Hn=mn.length;En!==Hn;++En){var mr=mn[En];E.addGroup(mr.start,mr.count,mr.materialIndex)}}var _r=f.data.boundingSphere;if(_r!==void 0){var gi=new yi;_r.center!==void 0&&gi.fromArray(_r.center),E.boundingSphere=new Nl(gi,_r.radius)}return f.name&&(E.name=f.name),f.userData&&(E.userData=f.userData),E}});var Lg={Int8Array,Uint8Array,Uint8ClampedArray:typeof Uint8ClampedArray<"u"?Uint8ClampedArray:Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array};function og(f){Ze.call(this,f)}og.prototype=Object.assign(Object.create(Ze.prototype),{constructor:og,load:function(f,E,W,ge){var ct=this,gt=this.path===""?rg.extractUrlBase(f):this.path;this.resourcePath=this.resourcePath||gt;var St=new on(ct.manager);St.setPath(this.path),St.load(f,function(Pt){var sn=null;try{sn=JSON.parse(Pt)}catch(Sn){return ge!==void 0&&ge(Sn),void console.error("THREE:ObjectLoader: Can't parse "+f+".",Sn.message)}var ln=sn.metadata;ln!==void 0&&ln.type!==void 0&&ln.type.toLowerCase()!=="geometry"?ct.parse(sn,E):console.error("THREE.ObjectLoader: Can't load "+f)},W,ge)},parse:function(f,E){var W=this.parseShape(f.shapes),ge=this.parseGeometries(f.geometries,W),ct=this.parseImages(f.images,function(){E!==void 0&&E(Pt)}),gt=this.parseTextures(f.textures,ct),St=this.parseMaterials(f.materials,gt),Pt=this.parseObject(f.object,ge,St);return f.animations&&(Pt.animations=this.parseAnimations(f.animations)),f.images!==void 0&&f.images.length!==0||E!==void 0&&E(Pt),Pt},parseShape:function(f){var E={};if(f!==void 0)for(var W=0,ge=f.length;W<ge;W++){var ct=new th().fromJSON(f[W]);E[ct.uuid]=ct}return E},parseGeometries:function(f,E){var W={};if(f!==void 0)for(var ge=new ag,ct=0,gt=f.length;ct<gt;ct++){var St,Pt=f[ct];switch(Pt.type){case"PlaneGeometry":case"PlaneBufferGeometry":St=new eh[Pt.type](Pt.width,Pt.height,Pt.widthSegments,Pt.heightSegments);break;case"BoxGeometry":case"BoxBufferGeometry":case"CubeGeometry":St=new eh[Pt.type](Pt.width,Pt.height,Pt.depth,Pt.widthSegments,Pt.heightSegments,Pt.depthSegments);break;case"CircleGeometry":case"CircleBufferGeometry":St=new eh[Pt.type](Pt.radius,Pt.segments,Pt.thetaStart,Pt.thetaLength);break;case"CylinderGeometry":case"CylinderBufferGeometry":St=new eh[Pt.type](Pt.radiusTop,Pt.radiusBottom,Pt.height,Pt.radialSegments,Pt.heightSegments,Pt.openEnded,Pt.thetaStart,Pt.thetaLength);break;case"ConeGeometry":case"ConeBufferGeometry":St=new eh[Pt.type](Pt.radius,Pt.height,Pt.radialSegments,Pt.heightSegments,Pt.openEnded,Pt.thetaStart,Pt.thetaLength);break;case"SphereGeometry":case"SphereBufferGeometry":St=new eh[Pt.type](Pt.radius,Pt.widthSegments,Pt.heightSegments,Pt.phiStart,Pt.phiLength,Pt.thetaStart,Pt.thetaLength);break;case"DodecahedronGeometry":case"DodecahedronBufferGeometry":case"IcosahedronGeometry":case"IcosahedronBufferGeometry":case"OctahedronGeometry":case"OctahedronBufferGeometry":case"TetrahedronGeometry":case"TetrahedronBufferGeometry":St=new eh[Pt.type](Pt.radius,Pt.detail);break;case"RingGeometry":case"RingBufferGeometry":St=new eh[Pt.type](Pt.innerRadius,Pt.outerRadius,Pt.thetaSegments,Pt.phiSegments,Pt.thetaStart,Pt.thetaLength);break;case"TorusGeometry":case"TorusBufferGeometry":St=new eh[Pt.type](Pt.radius,Pt.tube,Pt.radialSegments,Pt.tubularSegments,Pt.arc);break;case"TorusKnotGeometry":case"TorusKnotBufferGeometry":St=new eh[Pt.type](Pt.radius,Pt.tube,Pt.tubularSegments,Pt.radialSegments,Pt.p,Pt.q);break;case"TubeGeometry":case"TubeBufferGeometry":St=new eh[Pt.type](new Dd[Pt.path.type]().fromJSON(Pt.path),Pt.tubularSegments,Pt.radius,Pt.radialSegments,Pt.closed);break;case"LatheGeometry":case"LatheBufferGeometry":St=new eh[Pt.type](Pt.points,Pt.segments,Pt.phiStart,Pt.phiLength);break;case"PolyhedronGeometry":case"PolyhedronBufferGeometry":St=new eh[Pt.type](Pt.vertices,Pt.indices,Pt.radius,Pt.details);break;case"ShapeGeometry":case"ShapeBufferGeometry":for(var sn=[],ln=0,Sn=Pt.shapes.length;ln<Sn;ln++){var En=E[Pt.shapes[ln]];sn.push(En)}St=new eh[Pt.type](sn,Pt.curveSegments);break;case"ExtrudeGeometry":case"ExtrudeBufferGeometry":for(sn=[],ln=0,Sn=Pt.shapes.length;ln<Sn;ln++)En=E[Pt.shapes[ln]],sn.push(En);var On=Pt.options.extrudePath;On!==void 0&&(Pt.options.extrudePath=new Dd[On.type]().fromJSON(On)),St=new eh[Pt.type](sn,Pt.options);break;case"BufferGeometry":case"InstancedBufferGeometry":St=ge.parse(Pt);break;case"Geometry":"THREE"in window&&"LegacyJSONLoader"in THREE?St=new THREE.LegacyJSONLoader().parse(Pt,this.resourcePath).geometry:console.error('THREE.ObjectLoader: You have to import LegacyJSONLoader in order load geometry data of type "Geometry".');break;default:console.warn('THREE.ObjectLoader: Unsupported geometry type "'+Pt.type+'"');continue}St.uuid=Pt.uuid,Pt.name!==void 0&&(St.name=Pt.name),St.isBufferGeometry===!0&&Pt.userData!==void 0&&(St.userData=Pt.userData),W[Pt.uuid]=St}return W},parseMaterials:function(f,E){var W={},ge={};if(f!==void 0){var ct=new vm;ct.setTextures(E);for(var gt=0,St=f.length;gt<St;gt++){var Pt=f[gt];if(Pt.type==="MultiMaterial"){for(var sn=[],ln=0;ln<Pt.materials.length;ln++){var Sn=Pt.materials[ln];W[Sn.uuid]===void 0&&(W[Sn.uuid]=ct.parse(Sn)),sn.push(W[Sn.uuid])}ge[Pt.uuid]=sn}else W[Pt.uuid]===void 0&&(W[Pt.uuid]=ct.parse(Pt)),ge[Pt.uuid]=W[Pt.uuid]}}return ge},parseAnimations:function(f){for(var E=[],W=0;W<f.length;W++){var ge=f[W],ct=jh.parse(ge);ge.uuid!==void 0&&(ct.uuid=ge.uuid),E.push(ct)}return E},parseImages:function(f,E){var W=this,ge={};function ct(Hn){return W.manager.itemStart(Hn),gt.load(Hn,function(){W.manager.itemEnd(Hn)},void 0,function(){W.manager.itemError(Hn),W.manager.itemEnd(Hn)})}if(f!==void 0&&0<f.length){var gt=new ra(new yf(E));gt.setCrossOrigin(this.crossOrigin);for(var St=0,Pt=f.length;St<Pt;St++){var sn=f[St],ln=sn.url;if(Array.isArray(ln)){ge[sn.uuid]=[];for(var Sn=0,En=ln.length;Sn<En;Sn++){var On=ln[Sn],mn=/^(\/\/)|([a-z]+:(\/\/)?)/i.test(On)?On:W.resourcePath+On;ge[sn.uuid].push(ct(mn))}}else mn=/^(\/\/)|([a-z]+:(\/\/)?)/i.test(sn.url)?sn.url:W.resourcePath+sn.url,ge[sn.uuid]=ct(mn)}}return ge},parseTextures:function(f,E){function W(sn,ln){return typeof sn=="number"?sn:(console.warn("THREE.ObjectLoader.parseTexture: Constant should be in numeric form.",sn),ln[sn])}var ge={};if(f!==void 0)for(var ct=0,gt=f.length;ct<gt;ct++){var St,Pt=f[ct];Pt.image===void 0&&console.warn('THREE.ObjectLoader: No "image" specified for',Pt.uuid),E[Pt.image]===void 0&&console.warn("THREE.ObjectLoader: Undefined image",Pt.image),(St=new(Array.isArray(E[Pt.image])?ep:Ql)(E[Pt.image])).needsUpdate=!0,St.uuid=Pt.uuid,Pt.name!==void 0&&(St.name=Pt.name),Pt.mapping!==void 0&&(St.mapping=W(Pt.mapping,x0)),Pt.offset!==void 0&&St.offset.fromArray(Pt.offset),Pt.repeat!==void 0&&St.repeat.fromArray(Pt.repeat),Pt.center!==void 0&&St.center.fromArray(Pt.center),Pt.rotation!==void 0&&(St.rotation=Pt.rotation),Pt.wrap!==void 0&&(St.wrapS=W(Pt.wrap[0],n0),St.wrapT=W(Pt.wrap[1],n0)),Pt.format!==void 0&&(St.format=Pt.format),Pt.type!==void 0&&(St.type=Pt.type),Pt.encoding!==void 0&&(St.encoding=Pt.encoding),Pt.minFilter!==void 0&&(St.minFilter=W(Pt.minFilter,L3)),Pt.magFilter!==void 0&&(St.magFilter=W(Pt.magFilter,L3)),Pt.anisotropy!==void 0&&(St.anisotropy=Pt.anisotropy),Pt.flipY!==void 0&&(St.flipY=Pt.flipY),Pt.premultiplyAlpha!==void 0&&(St.premultiplyAlpha=Pt.premultiplyAlpha),Pt.unpackAlignment!==void 0&&(St.unpackAlignment=Pt.unpackAlignment),ge[Pt.uuid]=St}return ge},parseObject:function(f,E,W){var ge;function ct(_r){return E[_r]===void 0&&console.warn("THREE.ObjectLoader: Undefined geometry",_r),E[_r]}function gt(_r){if(_r!==void 0){if(Array.isArray(_r)){for(var gi=[],Ci=0,$i=_r.length;Ci<$i;Ci++){var da=_r[Ci];W[da]===void 0&&console.warn("THREE.ObjectLoader: Undefined material",da),gi.push(W[da])}return gi}return W[_r]===void 0&&console.warn("THREE.ObjectLoader: Undefined material",_r),W[_r]}}switch(f.type){case"Scene":ge=new fa,f.background!==void 0&&Number.isInteger(f.background)&&(ge.background=new la(f.background)),f.fog!==void 0&&(f.fog.type==="Fog"?ge.fog=new $d(f.fog.color,f.fog.near,f.fog.far):f.fog.type==="FogExp2"&&(ge.fog=new Tc(f.fog.color,f.fog.density)));break;case"PerspectiveCamera":ge=new cc(f.fov,f.aspect,f.near,f.far),f.focus!==void 0&&(ge.focus=f.focus),f.zoom!==void 0&&(ge.zoom=f.zoom),f.filmGauge!==void 0&&(ge.filmGauge=f.filmGauge),f.filmOffset!==void 0&&(ge.filmOffset=f.filmOffset),f.view!==void 0&&(ge.view=Object.assign({},f.view));break;case"OrthographicCamera":ge=new ap(f.left,f.right,f.top,f.bottom,f.near,f.far),f.zoom!==void 0&&(ge.zoom=f.zoom),f.view!==void 0&&(ge.view=Object.assign({},f.view));break;case"AmbientLight":ge=new tg(f.color,f.intensity);break;case"DirectionalLight":ge=new op(f.color,f.intensity);break;case"PointLight":ge=new ip(f.color,f.intensity,f.distance,f.decay);break;case"RectAreaLight":ge=new ng(f.color,f.intensity,f.width,f.height);break;case"SpotLight":ge=new gm(f.color,f.intensity,f.distance,f.angle,f.penumbra,f.decay);break;case"HemisphereLight":ge=new Xm(f.color,f.groundColor,f.intensity);break;case"SkinnedMesh":console.warn("THREE.ObjectLoader.parseObject() does not support SkinnedMesh yet.");case"Mesh":var St=ct(f.geometry),Pt=gt(f.material);ge=new(St.bones&&0<St.bones.length?_h:lu)(St,Pt);break;case"InstancedMesh":St=ct(f.geometry),Pt=gt(f.material);var sn=f.count,ln=f.instanceMatrix;(ge=new Vm(St,Pt,sn)).instanceMatrix=new ca(new Float32Array(ln.array),16);break;case"LOD":ge=new yp;break;case"Line":ge=new Hc(ct(f.geometry),gt(f.material),f.mode);break;case"LineLoop":ge=new Pf(ct(f.geometry),gt(f.material));break;case"LineSegments":ge=new xc(ct(f.geometry),gt(f.material));break;case"PointCloud":case"Points":ge=new If(ct(f.geometry),gt(f.material));break;case"Sprite":ge=new Lm(gt(f.material));break;case"Group":ge=new tc;break;default:ge=new Ri}if(ge.uuid=f.uuid,f.name!==void 0&&(ge.name=f.name),f.matrix!==void 0?(ge.matrix.fromArray(f.matrix),f.matrixAutoUpdate!==void 0&&(ge.matrixAutoUpdate=f.matrixAutoUpdate),ge.matrixAutoUpdate&&ge.matrix.decompose(ge.position,ge.quaternion,ge.scale)):(f.position!==void 0&&ge.position.fromArray(f.position),f.rotation!==void 0&&ge.rotation.fromArray(f.rotation),f.quaternion!==void 0&&ge.quaternion.fromArray(f.quaternion),f.scale!==void 0&&ge.scale.fromArray(f.scale)),f.castShadow!==void 0&&(ge.castShadow=f.castShadow),f.receiveShadow!==void 0&&(ge.receiveShadow=f.receiveShadow),f.shadow&&(f.shadow.bias!==void 0&&(ge.shadow.bias=f.shadow.bias),f.shadow.radius!==void 0&&(ge.shadow.radius=f.shadow.radius),f.shadow.mapSize!==void 0&&ge.shadow.mapSize.fromArray(f.shadow.mapSize),f.shadow.camera!==void 0&&(ge.shadow.camera=this.parseObject(f.shadow.camera))),f.visible!==void 0&&(ge.visible=f.visible),f.frustumCulled!==void 0&&(ge.frustumCulled=f.frustumCulled),f.renderOrder!==void 0&&(ge.renderOrder=f.renderOrder),f.userData!==void 0&&(ge.userData=f.userData),f.layers!==void 0&&(ge.layers.mask=f.layers),f.children!==void 0)for(var Sn=f.children,En=0;En<Sn.length;En++)ge.add(this.parseObject(Sn[En],E,W));if(f.type==="LOD"){f.autoUpdate!==void 0&&(ge.autoUpdate=f.autoUpdate);for(var On=f.levels,mn=0;mn<On.length;mn++){var Hn=On[mn],mr=ge.getObjectByProperty("uuid",Hn.object);mr!==void 0&&ge.addLevel(mr,Hn.distance)}}return ge}});var sg,x0={UVMapping:300,CubeReflectionMapping:ia,CubeRefractionMapping:Wi,EquirectangularReflectionMapping:ha,EquirectangularRefractionMapping:ai,SphericalReflectionMapping:Ia,CubeUVReflectionMapping:fi,CubeUVRefractionMapping:An},n0={RepeatWrapping:sa,ClampToEdgeWrapping:Nn,MirroredRepeatWrapping:fn},L3={NearestFilter:un,NearestMipmapNearestFilter:Ln,NearestMipmapLinearFilter:hr,LinearFilter:hi,LinearMipmapNearestFilter:bi,LinearMipmapLinearFilter:Ra};function Fg(f){typeof createImageBitmap>"u"&&console.warn("THREE.ImageBitmapLoader: createImageBitmap() not supported."),typeof fetch>"u"&&console.warn("THREE.ImageBitmapLoader: fetch() not supported."),Ze.call(this,f),this.options=void 0}function lg(){this.type="ShapePath",this.color=new la,this.subPaths=[],this.currentPath=null}function ug(f){this.type="Font",this.data=f}function r0(f,E,W,ge,ct){var gt=ct.glyphs[f]||ct.glyphs["?"];if(gt){var St,Pt,sn,ln,Sn,En,On,mn,Hn=new lg;if(gt.o)for(var mr=gt._cachedOutline||(gt._cachedOutline=gt.o.split(" ")),_r=0,gi=mr.length;_r<gi;)switch(mr[_r++]){case"m":St=mr[_r++]*E+W,Pt=mr[_r++]*E+ge,Hn.moveTo(St,Pt);break;case"l":St=mr[_r++]*E+W,Pt=mr[_r++]*E+ge,Hn.lineTo(St,Pt);break;case"q":sn=mr[_r++]*E+W,ln=mr[_r++]*E+ge,Sn=mr[_r++]*E+W,En=mr[_r++]*E+ge,Hn.quadraticCurveTo(Sn,En,sn,ln);break;case"b":sn=mr[_r++]*E+W,ln=mr[_r++]*E+ge,Sn=mr[_r++]*E+W,En=mr[_r++]*E+ge,On=mr[_r++]*E+W,mn=mr[_r++]*E+ge,Hn.bezierCurveTo(Sn,En,On,mn,sn,ln)}return{offsetX:gt.ha*E,path:Hn}}console.error('THREE.Font: character "'+f+'" does not exists in font family '+ct.familyName+".")}function Bg(f){Ze.call(this,f)}Fg.prototype=Object.assign(Object.create(Ze.prototype),{constructor:Fg,setOptions:function(f){return this.options=f,this},load:function(f,E,W,ge){f===void 0&&(f=""),this.path!==void 0&&(f=this.path+f),f=this.manager.resolveURL(f);var ct=this,gt=zf.get(f);if(gt!==void 0)return ct.manager.itemStart(f),setTimeout(function(){E&&E(gt),ct.manager.itemEnd(f)},0),gt;fetch(f).then(function(St){return St.blob()}).then(function(St){return ct.options===void 0?createImageBitmap(St):createImageBitmap(St,ct.options)}).then(function(St){zf.add(f,St),E&&E(St),ct.manager.itemEnd(f)}).catch(function(St){ge&&ge(St),ct.manager.itemError(f),ct.manager.itemEnd(f)}),ct.manager.itemStart(f)}}),Object.assign(lg.prototype,{moveTo:function(f,E){return this.currentPath=new md,this.subPaths.push(this.currentPath),this.currentPath.moveTo(f,E),this},lineTo:function(f,E){return this.currentPath.lineTo(f,E),this},quadraticCurveTo:function(f,E,W,ge){return this.currentPath.quadraticCurveTo(f,E,W,ge),this},bezierCurveTo:function(f,E,W,ge,ct,gt){return this.currentPath.bezierCurveTo(f,E,W,ge,ct,gt),this},splineThru:function(f){return this.currentPath.splineThru(f),this},toShapes:function(f,E){function W(Ha){for(var fs=[],os=0,Ks=Ha.length;os<Ks;os++){var Xs=Ha[os],zs=new th;zs.curves=Xs.curves,fs.push(zs)}return fs}function ge(Ha,fs){for(var os=fs.length,Ks=!1,Xs=os-1,zs=0;zs<os;Xs=zs++){var gl=fs[Xs],Os=fs[zs],Ii=Os.x-gl.x,va=Os.y-gl.y;if(Math.abs(va)>Number.EPSILON){if(va<0&&(gl=fs[zs],Ii=-Ii,Os=fs[Xs],va=-va),Ha.y<gl.y||Ha.y>Os.y)continue;if(Ha.y===gl.y){if(Ha.x===gl.x)return 1}else{var Bo=va*(Ha.x-gl.x)-Ii*(Ha.y-gl.y);if(Bo==0)return 1;if(Bo<0)continue;Ks=!Ks}}else{if(Ha.y!==gl.y)continue;if(Os.x<=Ha.x&&Ha.x<=gl.x||gl.x<=Ha.x&&Ha.x<=Os.x)return 1}}return Ks}var ct=bp.isClockWise,gt=this.subPaths;if(gt.length===0)return[];if(E===!0)return W(gt);var St,Pt,sn,ln=[];if(gt.length===1)return Pt=gt[0],(sn=new th).curves=Pt.curves,ln.push(sn),ln;var Sn=!ct(gt[0].getPoints());Sn=f?!Sn:Sn;var En,On,mn=[],Hn=[],mr=[],_r=0;Hn[_r]=void 0,mr[_r]=[];for(var gi=0,Ci=gt.length;gi<Ci;gi++)St=ct(En=(Pt=gt[gi]).getPoints()),(St=f?!St:St)?(!Sn&&Hn[_r]&&_r++,Hn[_r]={s:new th,p:En},Hn[_r].s.curves=Pt.curves,Sn&&_r++,mr[_r]=[]):mr[_r].push({h:Pt,p:En[0]});if(!Hn[0])return W(gt);if(1<Hn.length){for(var $i=!1,da=[],ji=0,Sa=Hn.length;ji<Sa;ji++)mn[ji]=[];for(ji=0,Sa=Hn.length;ji<Sa;ji++)for(var ea=mr[ji],Ba=0;Ba<ea.length;Ba++){for(var Ya=ea[Ba],ro=!0,$a=0;$a<Hn.length;$a++)ge(Ya.p,Hn[$a].p)&&(ji!==$a&&da.push({froms:ji,tos:$a,hole:Ba}),ro?(ro=!1,mn[$a].push(Ya)):$i=!0);ro&&mn[ji].push(Ya)}0<da.length&&($i||(mr=mn))}gi=0;for(var go=Hn.length;gi<go;gi++){sn=Hn[gi].s,ln.push(sn);for(var ko=0,Qa=(On=mr[gi]).length;ko<Qa;ko++)sn.holes.push(On[ko].h)}return ln}}),Object.assign(ug.prototype,{isFont:!0,generateShapes:function(f,E){E===void 0&&(E=100);for(var W=[],ge=function(St,Pt,sn){for(var ln=Array.from?Array.from(St):String(St).split(""),Sn=Pt/sn.resolution,En=(sn.boundingBox.yMax-sn.boundingBox.yMin+sn.underlineThickness)*Sn,On=[],mn=0,Hn=0,mr=0;mr<ln.length;mr++){var _r=ln[mr];if(_r===`
- `)mn=0,Hn-=En;else{var gi=r0(_r,Sn,mn,Hn,sn);mn+=gi.offsetX,On.push(gi.path)}}return On}(f,E,this.data),ct=0,gt=ge.length;ct<gt;ct++)Array.prototype.push.apply(W,ge[ct].toShapes());return W}}),Bg.prototype=Object.assign(Object.create(Ze.prototype),{constructor:Bg,load:function(f,E,W,ge){var ct=this,gt=new on(this.manager);gt.setPath(this.path),gt.load(f,function(St){var Pt;try{Pt=JSON.parse(St)}catch{console.warn("THREE.FontLoader: typeface.js support is being deprecated. Use typeface.json instead."),Pt=JSON.parse(St.substring(65,St.length-2))}var sn=ct.parse(Pt);E&&E(sn)},W,ge)},parse:function(f){return new ug(f)}});var Vg={getContext:function(){return sg===void 0&&(sg=new(window.AudioContext||window.webkitAudioContext)),sg},setContext:function(f){sg=f}};function cg(f){Ze.call(this,f)}function dg(){this.coefficients=[];for(var f=0;f<9;f++)this.coefficients.push(new yi)}function Ep(f,E){Eu.call(this,void 0,E),this.sh=f!==void 0?f:new dg}function Ng(f,E,W){Ep.call(this,void 0,W);var ge=new la().set(f),ct=new la().set(E),gt=new yi(ge.r,ge.g,ge.b),St=new yi(ct.r,ct.g,ct.b),Pt=Math.sqrt(Math.PI),sn=Pt*Math.sqrt(.75);this.sh.coefficients[0].copy(gt).add(St).multiplyScalar(Pt),this.sh.coefficients[1].copy(gt).sub(St).multiplyScalar(sn)}function Ad(f,E){Ep.call(this,void 0,E);var W=new la().set(f);this.sh.coefficients[0].set(W.r,W.g,W.b).multiplyScalar(2*Math.sqrt(Math.PI))}cg.prototype=Object.assign(Object.create(Ze.prototype),{constructor:cg,load:function(f,E,W,ge){var ct=new on(this.manager);ct.setResponseType("arraybuffer"),ct.setPath(this.path),ct.load(f,function(gt){var St=gt.slice(0);Vg.getContext().decodeAudioData(St,function(Pt){E(Pt)})},W,ge)}}),Object.assign(dg.prototype,{isSphericalHarmonics3:!0,set:function(f){for(var E=0;E<9;E++)this.coefficients[E].copy(f[E]);return this},zero:function(){for(var f=0;f<9;f++)this.coefficients[f].set(0,0,0);return this},getAt:function(f,E){var W=f.x,ge=f.y,ct=f.z,gt=this.coefficients;return E.copy(gt[0]).multiplyScalar(.282095),E.addScale(gt[1],.488603*ge),E.addScale(gt[2],.488603*ct),E.addScale(gt[3],.488603*W),E.addScale(gt[4],W*ge*1.092548),E.addScale(gt[5],ge*ct*1.092548),E.addScale(gt[6],.315392*(3*ct*ct-1)),E.addScale(gt[7],W*ct*1.092548),E.addScale(gt[8],.546274*(W*W-ge*ge)),E},getIrradianceAt:function(f,E){var W=f.x,ge=f.y,ct=f.z,gt=this.coefficients;return E.copy(gt[0]).multiplyScalar(.886227),E.addScale(gt[1],1.023328*ge),E.addScale(gt[2],1.023328*ct),E.addScale(gt[3],1.023328*W),E.addScale(gt[4],.858086*W*ge),E.addScale(gt[5],.858086*ge*ct),E.addScale(gt[6],.743125*ct*ct-.247708),E.addScale(gt[7],.858086*W*ct),E.addScale(gt[8],.429043*(W*W-ge*ge)),E},add:function(f){for(var E=0;E<9;E++)this.coefficients[E].add(f.coefficients[E]);return this},scale:function(f){for(var E=0;E<9;E++)this.coefficients[E].multiplyScalar(f);return this},lerp:function(f,E){for(var W=0;W<9;W++)this.coefficients[W].lerp(f.coefficients[W],E);return this},equals:function(f){for(var E=0;E<9;E++)if(!this.coefficients[E].equals(f.coefficients[E]))return!1;return!0},copy:function(f){return this.set(f.coefficients)},clone:function(){return new this.constructor().copy(this)},fromArray:function(f,E){E===void 0&&(E=0);for(var W=this.coefficients,ge=0;ge<9;ge++)W[ge].fromArray(f,E+3*ge);return this},toArray:function(f,E){f===void 0&&(f=[]),E===void 0&&(E=0);for(var W=this.coefficients,ge=0;ge<9;ge++)W[ge].toArray(f,E+3*ge);return f}}),Object.assign(dg,{getBasisAt:function(f,E){var W=f.x,ge=f.y,ct=f.z;E[0]=.282095,E[1]=.488603*ge,E[2]=.488603*ct,E[3]=.488603*W,E[4]=1.092548*W*ge,E[5]=1.092548*ge*ct,E[6]=.315392*(3*ct*ct-1),E[7]=1.092548*W*ct,E[8]=.546274*(W*W-ge*ge)}}),Ep.prototype=Object.assign(Object.create(Eu.prototype),{constructor:Ep,isLightProbe:!0,copy:function(f){return Eu.prototype.copy.call(this,f),this.sh.copy(f.sh),this.intensity=f.intensity,this},toJSON:function(f){return Eu.prototype.toJSON.call(this,f)}}),Ng.prototype=Object.assign(Object.create(Ep.prototype),{constructor:Ng,isHemisphereLightProbe:!0,copy:function(f){return Ep.prototype.copy.call(this,f),this},toJSON:function(f){return Ep.prototype.toJSON.call(this,f)}}),Ad.prototype=Object.assign(Object.create(Ep.prototype),{constructor:Ad,isAmbientLightProbe:!0,copy:function(f){return Ep.prototype.copy.call(this,f),this},toJSON:function(f){return Ep.prototype.toJSON.call(this,f)}});var Jp=new Vo,hg=new Vo;function F3(){this.type="StereoCamera",this.aspect=1,this.eyeSep=.064,this.cameraL=new cc,this.cameraL.layers.enable(1),this.cameraL.matrixAutoUpdate=!1,this.cameraR=new cc,this.cameraR.layers.enable(2),this.cameraR.matrixAutoUpdate=!1,this._cache={focus:null,fov:null,aspect:null,near:null,far:null,zoom:null,eyeSep:null}}function _m(f){this.autoStart=f===void 0||f,this.startTime=0,this.oldTime=0,this.elapsedTime=0,this.running=!1}Object.assign(F3.prototype,{update:function(f){var E=this._cache;if(E.focus!==f.focus||E.fov!==f.fov||E.aspect!==f.aspect*this.aspect||E.near!==f.near||E.far!==f.far||E.zoom!==f.zoom||E.eyeSep!==this.eyeSep){E.focus=f.focus,E.fov=f.fov,E.aspect=f.aspect*this.aspect,E.near=f.near,E.far=f.far,E.zoom=f.zoom,E.eyeSep=this.eyeSep;var W,ge,ct=f.projectionMatrix.clone(),gt=E.eyeSep/2,St=gt*E.near/E.focus,Pt=E.near*Math.tan(js.DEG2RAD*E.fov*.5)/E.zoom;hg.elements[12]=-gt,Jp.elements[12]=gt,W=-Pt*E.aspect+St,ge=Pt*E.aspect+St,ct.elements[0]=2*E.near/(ge-W),ct.elements[8]=(ge+W)/(ge-W),this.cameraL.projectionMatrix.copy(ct),W=-Pt*E.aspect-St,ge=Pt*E.aspect-St,ct.elements[0]=2*E.near/(ge-W),ct.elements[8]=(ge+W)/(ge-W),this.cameraR.projectionMatrix.copy(ct)}this.cameraL.matrixWorld.copy(f.matrixWorld).multiply(hg),this.cameraR.matrixWorld.copy(f.matrixWorld).multiply(Jp)}}),Object.assign(_m.prototype,{start:function(){this.startTime=(typeof performance>"u"?Date:performance).now(),this.oldTime=this.startTime,this.elapsedTime=0,this.running=!0},stop:function(){this.getElapsedTime(),this.running=!1,this.autoStart=!1},getElapsedTime:function(){return this.getDelta(),this.elapsedTime},getDelta:function(){var f=0;if(this.autoStart&&!this.running)return this.start(),0;if(this.running){var E=(typeof performance>"u"?Date:performance).now();f=(E-this.oldTime)/1e3,this.oldTime=E,this.elapsedTime+=f}return f}});var Jm=new yi,i0=new Wu,B3=new yi,Qm=new yi;function zg(){Ri.call(this),this.type="AudioListener",this.context=Vg.getContext(),this.gain=this.context.createGain(),this.gain.connect(this.context.destination),this.filter=null,this.timeDelta=0,this._clock=new _m}function e3(f){Ri.call(this),this.type="Audio",this.listener=f,this.context=f.context,this.gain=this.context.createGain(),this.gain.connect(f.getInput()),this.autoplay=!1,this.buffer=null,this.detune=0,this.loop=!1,this.loopStart=0,this.loopEnd=0,this.offset=0,this.duration=void 0,this.playbackRate=1,this.isPlaying=!1,this.hasPlaybackControl=!0,this.sourceType="empty",this._startedAt=0,this._pausedAt=0,this.filters=[]}zg.prototype=Object.assign(Object.create(Ri.prototype),{constructor:zg,getInput:function(){return this.gain},removeFilter:function(){return this.filter!==null&&(this.gain.disconnect(this.filter),this.filter.disconnect(this.context.destination),this.gain.connect(this.context.destination),this.filter=null),this},getFilter:function(){return this.filter},setFilter:function(f){return this.filter!==null?(this.gain.disconnect(this.filter),this.filter.disconnect(this.context.destination)):this.gain.disconnect(this.context.destination),this.filter=f,this.gain.connect(this.filter),this.filter.connect(this.context.destination),this},getMasterVolume:function(){return this.gain.gain.value},setMasterVolume:function(f){return this.gain.gain.setTargetAtTime(f,this.context.currentTime,.01),this},updateMatrixWorld:function(f){Ri.prototype.updateMatrixWorld.call(this,f);var E=this.context.listener,W=this.up;if(this.timeDelta=this._clock.getDelta(),this.matrixWorld.decompose(Jm,i0,B3),Qm.set(0,0,-1).applyQuaternion(i0),E.positionX){var ge=this.context.currentTime+this.timeDelta;E.positionX.linearRampToValueAtTime(Jm.x,ge),E.positionY.linearRampToValueAtTime(Jm.y,ge),E.positionZ.linearRampToValueAtTime(Jm.z,ge),E.forwardX.linearRampToValueAtTime(Qm.x,ge),E.forwardY.linearRampToValueAtTime(Qm.y,ge),E.forwardZ.linearRampToValueAtTime(Qm.z,ge),E.upX.linearRampToValueAtTime(W.x,ge),E.upY.linearRampToValueAtTime(W.y,ge),E.upZ.linearRampToValueAtTime(W.z,ge)}else E.setPosition(Jm.x,Jm.y,Jm.z),E.setOrientation(Qm.x,Qm.y,Qm.z,W.x,W.y,W.z)}}),e3.prototype=Object.assign(Object.create(Ri.prototype),{constructor:e3,getOutput:function(){return this.gain},setNodeSource:function(f){return this.hasPlaybackControl=!1,this.sourceType="audioNode",this.source=f,this.connect(),this},setMediaElementSource:function(f){return this.hasPlaybackControl=!1,this.sourceType="mediaNode",this.source=this.context.createMediaElementSource(f),this.connect(),this},setMediaStreamSource:function(f){return this.hasPlaybackControl=!1,this.sourceType="mediaStreamNode",this.source=this.context.createMediaStreamSource(f),this.connect(),this},setBuffer:function(f){return this.buffer=f,this.sourceType="buffer",this.autoplay&&this.play(),this},play:function(f){if(f===void 0&&(f=0),this.isPlaying!==!0){if(this.hasPlaybackControl!==!1){this._startedAt=this.context.currentTime+f;var E=this.context.createBufferSource();return E.buffer=this.buffer,E.loop=this.loop,E.loopStart=this.loopStart,E.loopEnd=this.loopEnd,E.onended=this.onEnded.bind(this),E.start(this._startedAt,this._pausedAt+this.offset,this.duration),this.isPlaying=!0,this.source=E,this.setDetune(this.detune),this.setPlaybackRate(this.playbackRate),this.connect()}console.warn("THREE.Audio: this Audio has no playback control.")}else console.warn("THREE.Audio: Audio is already playing.")},pause:function(){if(this.hasPlaybackControl!==!1)return this.isPlaying===!0&&(this._pausedAt=(this.context.currentTime-this._startedAt)*this.playbackRate,this.source.stop(),this.source.onended=null,this.isPlaying=!1),this;console.warn("THREE.Audio: this Audio has no playback control.")},stop:function(){if(this.hasPlaybackControl!==!1)return this._pausedAt=0,this.source.stop(),this.source.onended=null,this.isPlaying=!1,this;console.warn("THREE.Audio: this Audio has no playback control.")},connect:function(){if(0<this.filters.length){this.source.connect(this.filters[0]);for(var f=1,E=this.filters.length;f<E;f++)this.filters[f-1].connect(this.filters[f]);this.filters[this.filters.length-1].connect(this.getOutput())}else this.source.connect(this.getOutput());return this},disconnect:function(){if(0<this.filters.length){this.source.disconnect(this.filters[0]);for(var f=1,E=this.filters.length;f<E;f++)this.filters[f-1].disconnect(this.filters[f]);this.filters[this.filters.length-1].disconnect(this.getOutput())}else this.source.disconnect(this.getOutput());return this},getFilters:function(){return this.filters},setFilters:function(f){return f=f||[],this.isPlaying===!0?(this.disconnect(),this.filters=f,this.connect()):this.filters=f,this},setDetune:function(f){if(this.detune=f,this.source.detune!==void 0)return this.isPlaying===!0&&this.source.detune.setTargetAtTime(this.detune,this.context.currentTime,.01),this},getDetune:function(){return this.detune},getFilter:function(){return this.getFilters()[0]},setFilter:function(f){return this.setFilters(f?[f]:[])},setPlaybackRate:function(f){if(this.hasPlaybackControl!==!1)return this.playbackRate=f,this.isPlaying===!0&&this.source.playbackRate.setTargetAtTime(this.playbackRate,this.context.currentTime,.01),this;console.warn("THREE.Audio: this Audio has no playback control.")},getPlaybackRate:function(){return this.playbackRate},onEnded:function(){this.isPlaying=!1},getLoop:function(){return this.hasPlaybackControl===!1?(console.warn("THREE.Audio: this Audio has no playback control."),!1):this.loop},setLoop:function(f){if(this.hasPlaybackControl!==!1)return this.loop=f,this.isPlaying===!0&&(this.source.loop=this.loop),this;console.warn("THREE.Audio: this Audio has no playback control.")},setLoopStart:function(f){return this.loopStart=f,this},setLoopEnd:function(f){return this.loopEnd=f,this},getVolume:function(){return this.gain.gain.value},setVolume:function(f){return this.gain.gain.setTargetAtTime(f,this.context.currentTime,.01),this}});var xm=new yi,m3=new Wu,rc=new yi,jf=new yi;function pg(f){e3.call(this,f),this.panner=this.context.createPanner(),this.panner.panningModel="HRTF",this.panner.connect(this.gain)}function fg(f,E){this.analyser=f.context.createAnalyser(),this.analyser.fftSize=E!==void 0?E:2048,this.data=new Uint8Array(this.analyser.frequencyBinCount),f.getOutput().connect(this.analyser)}function Qp(f,E,W){this.binding=f,this.valueSize=W;var ge,ct=Float64Array;switch(E){case"quaternion":ge=this._slerp;break;case"string":case"bool":ct=Array,ge=this._select;break;default:ge=this._lerp}this.buffer=new ct(4*W),this._mixBufferRegion=ge,this.cumulativeWeight=0,this.useCount=0,this.referenceCount=0}pg.prototype=Object.assign(Object.create(e3.prototype),{constructor:pg,getOutput:function(){return this.panner},getRefDistance:function(){return this.panner.refDistance},setRefDistance:function(f){return this.panner.refDistance=f,this},getRolloffFactor:function(){return this.panner.rolloffFactor},setRolloffFactor:function(f){return this.panner.rolloffFactor=f,this},getDistanceModel:function(){return this.panner.distanceModel},setDistanceModel:function(f){return this.panner.distanceModel=f,this},getMaxDistance:function(){return this.panner.maxDistance},setMaxDistance:function(f){return this.panner.maxDistance=f,this},setDirectionalCone:function(f,E,W){return this.panner.coneInnerAngle=f,this.panner.coneOuterAngle=E,this.panner.coneOuterGain=W,this},updateMatrixWorld:function(f){if(Ri.prototype.updateMatrixWorld.call(this,f),this.hasPlaybackControl!==!0||this.isPlaying!==!1){this.matrixWorld.decompose(xm,m3,rc),jf.set(0,0,1).applyQuaternion(m3);var E=this.panner;if(E.positionX){var W=this.context.currentTime+this.listener.timeDelta;E.positionX.linearRampToValueAtTime(xm.x,W),E.positionY.linearRampToValueAtTime(xm.y,W),E.positionZ.linearRampToValueAtTime(xm.z,W),E.orientationX.linearRampToValueAtTime(jf.x,W),E.orientationY.linearRampToValueAtTime(jf.y,W),E.orientationZ.linearRampToValueAtTime(jf.z,W)}else E.setPosition(xm.x,xm.y,xm.z),E.setOrientation(jf.x,jf.y,jf.z)}}}),Object.assign(fg.prototype,{getFrequencyData:function(){return this.analyser.getByteFrequencyData(this.data),this.data},getAverageFrequency:function(){for(var f=0,E=this.getFrequencyData(),W=0;W<E.length;W++)f+=E[W];return f/E.length}}),Object.assign(Qp.prototype,{accumulate:function(f,E){var W=this.buffer,ge=this.valueSize,ct=f*ge+ge,gt=this.cumulativeWeight;if(gt===0){for(var St=0;St!==ge;++St)W[ct+St]=W[St];gt=E}else{var Pt=E/(gt+=E);this._mixBufferRegion(W,ct,0,Pt,ge)}this.cumulativeWeight=gt},apply:function(f){var E=this.valueSize,W=this.buffer,ge=f*E+E,ct=this.cumulativeWeight,gt=this.binding;if(this.cumulativeWeight=0,ct<1){var St=3*E;this._mixBufferRegion(W,ge,St,1-ct,E)}for(var Pt=E,sn=E+E;Pt!==sn;++Pt)if(W[Pt]!==W[Pt+E]){gt.setValue(W,ge);break}},saveOriginalState:function(){var f=this.binding,E=this.buffer,W=this.valueSize,ge=3*W;f.getValue(E,ge);for(var ct=W,gt=ge;ct!==gt;++ct)E[ct]=E[ge+ct%W];this.cumulativeWeight=0},restoreOriginalState:function(){var f=3*this.valueSize;this.binding.setValue(this.buffer,f)},_select:function(f,E,W,ge,ct){if(.5<=ge)for(var gt=0;gt!==ct;++gt)f[E+gt]=f[W+gt]},_slerp:function(f,E,W,ge){Wu.slerpFlat(f,E,f,E,f,W,ge)},_lerp:function(f,E,W,ge,ct){for(var gt=1-ge,St=0;St!==ct;++St){var Pt=E+St;f[Pt]=f[Pt]*gt+f[W+St]*ge}}});var bm="\\[\\]\\.:\\/",a0=new RegExp("["+bm+"]","g"),jg="[^"+bm+"]",b0="[^"+bm.replace("\\.","")+"]",w0=/((?:WC+[\/:])*)/.source.replace("WC",jg),M0=/(WCOD+)?/.source.replace("WCOD",b0),C0=/(?:\.(WC+)(?:\[(.+)\])?)?/.source.replace("WC",jg),S0=/\.(WC+)(?:\[(.+)\])?/.source.replace("WC",jg),T0=new RegExp("^"+w0+M0+C0+S0+"$"),D0=["material","materials","bones"];function o0(f,E,W){var ge=W||Nd.parseTrackName(E);this._targetGroup=f,this._bindings=f.subscribe_(E,ge)}function Nd(f,E,W){this.path=E,this.parsedPath=W||Nd.parseTrackName(E),this.node=Nd.findNode(f,this.parsedPath.nodeName)||f,this.rootNode=f}function t3(){this.uuid=js.generateUUID(),this._objects=Array.prototype.slice.call(arguments),this.nCachedObjects_=0;var f={};this._indicesByUUID=f;for(var E=0,W=arguments.length;E!==W;++E)f[arguments[E].uuid]=E;this._paths=[],this._parsedPaths=[],this._bindings=[],this._bindingsIndicesByPath={};var ge=this;this.stats={objects:{get total(){return ge._objects.length},get inUse(){return this.total-ge.nCachedObjects_}},get bindingsPerObject(){return ge._bindings.length}}}function Gg(f,E,W){this._mixer=f,this._clip=E,this._localRoot=W||null;for(var ge=E.tracks,ct=ge.length,gt=new Array(ct),St={endingStart:Ur,endingEnd:Ur},Pt=0;Pt!==ct;++Pt){var sn=ge[Pt].createInterpolant(null);(gt[Pt]=sn).settings=St}this._interpolantSettings=St,this._interpolants=gt,this._propertyBindings=new Array(ct),this._cacheIndex=null,this._byClipCacheIndex=null,this._timeScaleInterpolant=null,this._weightInterpolant=null,this.loop=2201,this._loopCount=-1,this._startTime=null,this.time=0,this.timeScale=1,this._effectiveTimeScale=1,this.weight=1,this._effectiveWeight=1,this.repetitions=1/0,this.paused=!1,this.enabled=!0,this.clampWhenFinished=!1,this.zeroSlopeAtStart=!0,this.zeroSlopeAtEnd=!0}function Ug(f){this._root=f,this._initMemoryManager(),this._accuIndex=0,this.time=0,this.timeScale=1}function mg(f){typeof f=="string"&&(console.warn("THREE.Uniform: Type parameter is no longer needed."),f=arguments[1]),this.value=f}function $g(f,E,W){Vc.call(this,f,E),this.meshPerAttribute=W||1}function gg(f,E,W,ge){this.ray=new Hl(f,E),this.near=W||0,this.far=ge||1/0,this.camera=null,this.params={Mesh:{},Line:{},LOD:{},Points:{threshold:1},Sprite:{}},Object.defineProperties(this.params,{PointCloud:{get:function(){return console.warn("THREE.Raycaster: params.PointCloud has been renamed to params.Points."),this.Points}}})}function yg(f,E){return f.distance-E.distance}function vg(f,E,W,ge){if(f.visible!==!1&&(f.raycast(E,W),ge===!0))for(var ct=f.children,gt=0,St=ct.length;gt<St;gt++)vg(ct[gt],E,W,!0)}function Gh(f,E,W){return this.radius=f!==void 0?f:1,this.phi=E!==void 0?E:0,this.theta=W!==void 0?W:0,this}function g3(f,E,W){return this.radius=f!==void 0?f:1,this.theta=E!==void 0?E:0,this.y=W!==void 0?W:0,this}Object.assign(o0.prototype,{getValue:function(f,E){this.bind();var W=this._targetGroup.nCachedObjects_,ge=this._bindings[W];ge!==void 0&&ge.getValue(f,E)},setValue:function(f,E){for(var W=this._bindings,ge=this._targetGroup.nCachedObjects_,ct=W.length;ge!==ct;++ge)W[ge].setValue(f,E)},bind:function(){for(var f=this._bindings,E=this._targetGroup.nCachedObjects_,W=f.length;E!==W;++E)f[E].bind()},unbind:function(){for(var f=this._bindings,E=this._targetGroup.nCachedObjects_,W=f.length;E!==W;++E)f[E].unbind()}}),Object.assign(Nd,{Composite:o0,create:function(f,E,W){return f&&f.isAnimationObjectGroup?new Nd.Composite(f,E,W):new Nd(f,E,W)},sanitizeNodeName:function(f){return f.replace(/\s/g,"_").replace(a0,"")},parseTrackName:function(f){var E=T0.exec(f);if(!E)throw new Error("PropertyBinding: Cannot parse trackName: "+f);var W={nodeName:E[2],objectName:E[3],objectIndex:E[4],propertyName:E[5],propertyIndex:E[6]},ge=W.nodeName&&W.nodeName.lastIndexOf(".");if(ge!==void 0&&ge!==-1){var ct=W.nodeName.substring(ge+1);D0.indexOf(ct)!==-1&&(W.nodeName=W.nodeName.substring(0,ge),W.objectName=ct)}if(W.propertyName===null||W.propertyName.length===0)throw new Error("PropertyBinding: can not parse propertyName from trackName: "+f);return W},findNode:function(f,E){if(!E||E===""||E==="root"||E==="."||E===-1||E===f.name||E===f.uuid)return f;if(f.skeleton){var W=f.skeleton.getBoneByName(E);if(W!==void 0)return W}if(f.children){var ge=function(gt){for(var St=0;St<gt.length;St++){var Pt=gt[St];if(Pt.name===E||Pt.uuid===E)return Pt;var sn=ge(Pt.children);if(sn)return sn}return null},ct=ge(f.children);if(ct)return ct}return null}}),Object.assign(Nd.prototype,{_getValue_unavailable:function(){},_setValue_unavailable:function(){},BindingType:{Direct:0,EntireArray:1,ArrayElement:2,HasFromToArray:3},Versioning:{None:0,NeedsUpdate:1,MatrixWorldNeedsUpdate:2},GetterByBindingType:[function(f,E){f[E]=this.node[this.propertyName]},function(f,E){for(var W=this.resolvedProperty,ge=0,ct=W.length;ge!==ct;++ge)f[E++]=W[ge]},function(f,E){f[E]=this.resolvedProperty[this.propertyIndex]},function(f,E){this.resolvedProperty.toArray(f,E)}],SetterByBindingTypeAndVersioning:[[function(f,E){this.targetObject[this.propertyName]=f[E]},function(f,E){this.targetObject[this.propertyName]=f[E],this.targetObject.needsUpdate=!0},function(f,E){this.targetObject[this.propertyName]=f[E],this.targetObject.matrixWorldNeedsUpdate=!0}],[function(f,E){for(var W=this.resolvedProperty,ge=0,ct=W.length;ge!==ct;++ge)W[ge]=f[E++]},function(f,E){for(var W=this.resolvedProperty,ge=0,ct=W.length;ge!==ct;++ge)W[ge]=f[E++];this.targetObject.needsUpdate=!0},function(f,E){for(var W=this.resolvedProperty,ge=0,ct=W.length;ge!==ct;++ge)W[ge]=f[E++];this.targetObject.matrixWorldNeedsUpdate=!0}],[function(f,E){this.resolvedProperty[this.propertyIndex]=f[E]},function(f,E){this.resolvedProperty[this.propertyIndex]=f[E],this.targetObject.needsUpdate=!0},function(f,E){this.resolvedProperty[this.propertyIndex]=f[E],this.targetObject.matrixWorldNeedsUpdate=!0}],[function(f,E){this.resolvedProperty.fromArray(f,E)},function(f,E){this.resolvedProperty.fromArray(f,E),this.targetObject.needsUpdate=!0},function(f,E){this.resolvedProperty.fromArray(f,E),this.targetObject.matrixWorldNeedsUpdate=!0}]],getValue:function(f,E){this.bind(),this.getValue(f,E)},setValue:function(f,E){this.bind(),this.setValue(f,E)},bind:function(){var f=this.node,E=this.parsedPath,W=E.objectName,ge=E.propertyName,ct=E.propertyIndex;if(f||(f=Nd.findNode(this.rootNode,E.nodeName)||this.rootNode,this.node=f),this.getValue=this._getValue_unavailable,this.setValue=this._setValue_unavailable,f){if(W){var gt=E.objectIndex;switch(W){case"materials":if(!f.material)return void console.error("THREE.PropertyBinding: Can not bind to material as node does not have a material.",this);if(!f.material.materials)return void console.error("THREE.PropertyBinding: Can not bind to material.materials as node.material does not have a materials array.",this);f=f.material.materials;break;case"bones":if(!f.skeleton)return void console.error("THREE.PropertyBinding: Can not bind to bones as node does not have a skeleton.",this);f=f.skeleton.bones;for(var St=0;St<f.length;St++)if(f[St].name===gt){gt=St;break}break;default:if(f[W]===void 0)return void console.error("THREE.PropertyBinding: Can not bind to objectName of node undefined.",this);f=f[W]}if(gt!==void 0){if(f[gt]===void 0)return void console.error("THREE.PropertyBinding: Trying to bind to objectIndex of objectName, but is undefined.",this,f);f=f[gt]}}var Pt=f[ge];if(Pt!==void 0){var sn=this.Versioning.None;(this.targetObject=f).needsUpdate!==void 0?sn=this.Versioning.NeedsUpdate:f.matrixWorldNeedsUpdate!==void 0&&(sn=this.Versioning.MatrixWorldNeedsUpdate);var ln=this.BindingType.Direct;if(ct!==void 0){if(ge==="morphTargetInfluences"){if(!f.geometry)return void console.error("THREE.PropertyBinding: Can not bind to morphTargetInfluences because node does not have a geometry.",this);if(f.geometry.isBufferGeometry){if(!f.geometry.morphAttributes)return void console.error("THREE.PropertyBinding: Can not bind to morphTargetInfluences because node does not have a geometry.morphAttributes.",this);for(St=0;St<this.node.geometry.morphAttributes.position.length;St++)if(f.geometry.morphAttributes.position[St].name===ct){ct=St;break}}else{if(!f.geometry.morphTargets)return void console.error("THREE.PropertyBinding: Can not bind to morphTargetInfluences because node does not have a geometry.morphTargets.",this);for(St=0;St<this.node.geometry.morphTargets.length;St++)if(f.geometry.morphTargets[St].name===ct){ct=St;break}}}ln=this.BindingType.ArrayElement,this.resolvedProperty=Pt,this.propertyIndex=ct}else Pt.fromArray!==void 0&&Pt.toArray!==void 0?(ln=this.BindingType.HasFromToArray,this.resolvedProperty=Pt):Array.isArray(Pt)?(ln=this.BindingType.EntireArray,this.resolvedProperty=Pt):this.propertyName=ge;this.getValue=this.GetterByBindingType[ln],this.setValue=this.SetterByBindingTypeAndVersioning[ln][sn]}else{var Sn=E.nodeName;console.error("THREE.PropertyBinding: Trying to update property for track: "+Sn+"."+ge+" but it wasn't found.",f)}}else console.error("THREE.PropertyBinding: Trying to update node for track: "+this.path+" but it wasn't found.")},unbind:function(){this.node=null,this.getValue=this._getValue_unbound,this.setValue=this._setValue_unbound}}),Object.assign(Nd.prototype,{_getValue_unbound:Nd.prototype.getValue,_setValue_unbound:Nd.prototype.setValue}),Object.assign(t3.prototype,{isAnimationObjectGroup:!0,add:function(){for(var f=this._objects,E=f.length,W=this.nCachedObjects_,ge=this._indicesByUUID,ct=this._paths,gt=this._parsedPaths,St=this._bindings,Pt=St.length,sn=void 0,ln=0,Sn=arguments.length;ln!==Sn;++ln){var En=arguments[ln],On=En.uuid,mn=ge[On];if(mn===void 0){mn=E++,ge[On]=mn,f.push(En);for(var Hn=0,mr=Pt;Hn!==mr;++Hn)St[Hn].push(new Nd(En,ct[Hn],gt[Hn]))}else if(mn<W){sn=f[mn];var _r=--W,gi=f[_r];for(f[ge[gi.uuid]=mn]=gi,f[ge[On]=_r]=En,Hn=0,mr=Pt;Hn!==mr;++Hn){var Ci=St[Hn],$i=Ci[_r],da=Ci[mn];Ci[mn]=$i,da===void 0&&(da=new Nd(En,ct[Hn],gt[Hn])),Ci[_r]=da}}else f[mn]!==sn&&console.error("THREE.AnimationObjectGroup: Different objects with the same UUID detected. Clean the caches or recreate your infrastructure when reloading scenes.")}this.nCachedObjects_=W},remove:function(){for(var f=this._objects,E=this.nCachedObjects_,W=this._indicesByUUID,ge=this._bindings,ct=ge.length,gt=0,St=arguments.length;gt!==St;++gt){var Pt=arguments[gt],sn=Pt.uuid,ln=W[sn];if(ln!==void 0&&E<=ln){var Sn=E++,En=f[Sn];f[W[En.uuid]=ln]=En,f[W[sn]=Sn]=Pt;for(var On=0,mn=ct;On!==mn;++On){var Hn=ge[On],mr=Hn[Sn],_r=Hn[ln];Hn[ln]=mr,Hn[Sn]=_r}}}this.nCachedObjects_=E},uncache:function(){for(var f=this._objects,E=f.length,W=this.nCachedObjects_,ge=this._indicesByUUID,ct=this._bindings,gt=ct.length,St=0,Pt=arguments.length;St!==Pt;++St){var sn=arguments[St].uuid,ln=ge[sn];if(ln!==void 0)if(delete ge[sn],ln<W){var Sn=--W,En=f[Sn],On=f[gi=--E];f[ge[En.uuid]=ln]=En,f[ge[On.uuid]=Sn]=On,f.pop();for(var mn=0,Hn=gt;mn!==Hn;++mn){var mr=(Ci=ct[mn])[Sn],_r=Ci[gi];Ci[ln]=mr,Ci[Sn]=_r,Ci.pop()}}else{var gi;for(f[ge[(On=f[gi=--E]).uuid]=ln]=On,f.pop(),mn=0,Hn=gt;mn!==Hn;++mn){var Ci;(Ci=ct[mn])[ln]=Ci[gi],Ci.pop()}}}this.nCachedObjects_=W},subscribe_:function(f,E){var W=this._bindingsIndicesByPath,ge=W[f],ct=this._bindings;if(ge!==void 0)return ct[ge];var gt=this._paths,St=this._parsedPaths,Pt=this._objects,sn=Pt.length,ln=this.nCachedObjects_,Sn=new Array(sn);ge=ct.length,W[f]=ge,gt.push(f),St.push(E),ct.push(Sn);for(var En=ln,On=Pt.length;En!==On;++En){var mn=Pt[En];Sn[En]=new Nd(mn,f,E)}return Sn},unsubscribe_:function(f){var E=this._bindingsIndicesByPath,W=E[f];if(W!==void 0){var ge=this._paths,ct=this._parsedPaths,gt=this._bindings,St=gt.length-1,Pt=gt[St];gt[E[f[St]]=W]=Pt,gt.pop(),ct[W]=ct[St],ct.pop(),ge[W]=ge[St],ge.pop()}}}),Object.assign(Gg.prototype,{play:function(){return this._mixer._activateAction(this),this},stop:function(){return this._mixer._deactivateAction(this),this.reset()},reset:function(){return this.paused=!1,this.enabled=!0,this.time=0,this._loopCount=-1,this._startTime=null,this.stopFading().stopWarping()},isRunning:function(){return this.enabled&&!this.paused&&this.timeScale!==0&&this._startTime===null&&this._mixer._isActiveAction(this)},isScheduled:function(){return this._mixer._isActiveAction(this)},startAt:function(f){return this._startTime=f,this},setLoop:function(f,E){return this.loop=f,this.repetitions=E,this},setEffectiveWeight:function(f){return this.weight=f,this._effectiveWeight=this.enabled?f:0,this.stopFading()},getEffectiveWeight:function(){return this._effectiveWeight},fadeIn:function(f){return this._scheduleFading(f,0,1)},fadeOut:function(f){return this._scheduleFading(f,1,0)},crossFadeFrom:function(f,E,W){if(f.fadeOut(E),this.fadeIn(E),W){var ge=this._clip.duration,ct=f._clip.duration,gt=ct/ge,St=ge/ct;f.warp(1,gt,E),this.warp(St,1,E)}return this},crossFadeTo:function(f,E,W){return f.crossFadeFrom(this,E,W)},stopFading:function(){var f=this._weightInterpolant;return f!==null&&(this._weightInterpolant=null,this._mixer._takeBackControlInterpolant(f)),this},setEffectiveTimeScale:function(f){return this.timeScale=f,this._effectiveTimeScale=this.paused?0:f,this.stopWarping()},getEffectiveTimeScale:function(){return this._effectiveTimeScale},setDuration:function(f){return this.timeScale=this._clip.duration/f,this.stopWarping()},syncWith:function(f){return this.time=f.time,this.timeScale=f.timeScale,this.stopWarping()},halt:function(f){return this.warp(this._effectiveTimeScale,0,f)},warp:function(f,E,W){var ge=this._mixer,ct=ge.time,gt=this._timeScaleInterpolant,St=this.timeScale;gt===null&&(gt=ge._lendControlInterpolant(),this._timeScaleInterpolant=gt);var Pt=gt.parameterPositions,sn=gt.sampleValues;return Pt[0]=ct,Pt[1]=ct+W,sn[0]=f/St,sn[1]=E/St,this},stopWarping:function(){var f=this._timeScaleInterpolant;return f!==null&&(this._timeScaleInterpolant=null,this._mixer._takeBackControlInterpolant(f)),this},getMixer:function(){return this._mixer},getClip:function(){return this._clip},getRoot:function(){return this._localRoot||this._mixer._root},_update:function(f,E,W,ge){if(this.enabled){var ct=this._startTime;if(ct!==null){var gt=(f-ct)*W;if(gt<0||W===0)return;this._startTime=null,E=W*gt}E*=this._updateTimeScale(f);var St=this._updateTime(E),Pt=this._updateWeight(f);if(0<Pt)for(var sn=this._interpolants,ln=this._propertyBindings,Sn=0,En=sn.length;Sn!==En;++Sn)sn[Sn].evaluate(St),ln[Sn].accumulate(ge,Pt)}else this._updateWeight(f)},_updateWeight:function(f){var E=0;if(this.enabled){E=this.weight;var W=this._weightInterpolant;if(W!==null){var ge=W.evaluate(f)[0];E*=ge,f>W.parameterPositions[1]&&(this.stopFading(),ge===0&&(this.enabled=!1))}}return this._effectiveWeight=E},_updateTimeScale:function(f){var E=0;if(!this.paused){E=this.timeScale;var W=this._timeScaleInterpolant;W!==null&&(E*=W.evaluate(f)[0],f>W.parameterPositions[1]&&(this.stopWarping(),E===0?this.paused=!0:this.timeScale=E))}return this._effectiveTimeScale=E},_updateTime:function(f){var E=this.time+f,W=this._clip.duration,ge=this.loop,ct=this._loopCount,gt=ge===2202;if(f===0)return ct!==-1&>&&(1&ct)==1?W-E:E;if(ge===2200){ct===-1&&(this._loopCount=0,this._setEndings(!0,!0,!1));e:{if(W<=E)E=W;else{if(!(E<0)){this.time=E;break e}E=0}this.clampWhenFinished?this.paused=!0:this.enabled=!1,this.time=E,this._mixer.dispatchEvent({type:"finished",action:this,direction:f<0?-1:1})}}else{if(ct===-1&&(0<=f?(ct=0,this._setEndings(!0,this.repetitions===0,gt)):this._setEndings(this.repetitions===0,!0,gt)),W<=E||E<0){var St=Math.floor(E/W);E-=W*St,ct+=Math.abs(St);var Pt=this.repetitions-ct;if(Pt<=0)this.clampWhenFinished?this.paused=!0:this.enabled=!1,E=0<f?W:0,this.time=E,this._mixer.dispatchEvent({type:"finished",action:this,direction:0<f?1:-1});else{if(Pt==1){var sn=f<0;this._setEndings(sn,!sn,gt)}else this._setEndings(!1,!1,gt);this._loopCount=ct,this.time=E,this._mixer.dispatchEvent({type:"loop",action:this,loopDelta:St})}}else this.time=E;if(gt&&(1&ct)==1)return W-E}return E},_setEndings:function(f,E,W){var ge=this._interpolantSettings;W?(ge.endingStart=Gn,ge.endingEnd=Gn):(ge.endingStart=f?this.zeroSlopeAtStart?Gn:Ur:Qr,ge.endingEnd=E?this.zeroSlopeAtEnd?Gn:Ur:Qr)},_scheduleFading:function(f,E,W){var ge=this._mixer,ct=ge.time,gt=this._weightInterpolant;gt===null&&(gt=ge._lendControlInterpolant(),this._weightInterpolant=gt);var St=gt.parameterPositions,Pt=gt.sampleValues;return St[0]=ct,Pt[0]=E,St[1]=ct+f,Pt[1]=W,this}}),Ug.prototype=Object.assign(Object.create(Ku.prototype),{constructor:Ug,_bindAction:function(f,E){var W=f._localRoot||this._root,ge=f._clip.tracks,ct=ge.length,gt=f._propertyBindings,St=f._interpolants,Pt=W.uuid,sn=this._bindingsByRootAndName,ln=sn[Pt];ln===void 0&&(ln={},sn[Pt]=ln);for(var Sn=0;Sn!==ct;++Sn){var En=ge[Sn],On=En.name,mn=ln[On];if(mn!==void 0)gt[Sn]=mn;else{if((mn=gt[Sn])!==void 0){mn._cacheIndex===null&&(++mn.referenceCount,this._addInactiveBinding(mn,Pt,On));continue}var Hn=E&&E._propertyBindings[Sn].binding.parsedPath;++(mn=new Qp(Nd.create(W,On,Hn),En.ValueTypeName,En.getValueSize())).referenceCount,this._addInactiveBinding(mn,Pt,On),gt[Sn]=mn}St[Sn].resultBuffer=mn.buffer}},_activateAction:function(f){if(!this._isActiveAction(f)){if(f._cacheIndex===null){var E=(f._localRoot||this._root).uuid,W=f._clip.uuid,ge=this._actionsByClip[W];this._bindAction(f,ge&&ge.knownActions[0]),this._addInactiveAction(f,W,E)}for(var ct=f._propertyBindings,gt=0,St=ct.length;gt!==St;++gt){var Pt=ct[gt];Pt.useCount++==0&&(this._lendBinding(Pt),Pt.saveOriginalState())}this._lendAction(f)}},_deactivateAction:function(f){if(this._isActiveAction(f)){for(var E=f._propertyBindings,W=0,ge=E.length;W!==ge;++W){var ct=E[W];--ct.useCount==0&&(ct.restoreOriginalState(),this._takeBackBinding(ct))}this._takeBackAction(f)}},_initMemoryManager:function(){this._actions=[],this._nActiveActions=0,this._actionsByClip={},this._bindings=[],this._nActiveBindings=0,this._bindingsByRootAndName={},this._controlInterpolants=[],this._nActiveControlInterpolants=0;var f=this;this.stats={actions:{get total(){return f._actions.length},get inUse(){return f._nActiveActions}},bindings:{get total(){return f._bindings.length},get inUse(){return f._nActiveBindings}},controlInterpolants:{get total(){return f._controlInterpolants.length},get inUse(){return f._nActiveControlInterpolants}}}},_isActiveAction:function(f){var E=f._cacheIndex;return E!==null&&E<this._nActiveActions},_addInactiveAction:function(f,E,W){var ge=this._actions,ct=this._actionsByClip,gt=ct[E];if(gt===void 0)gt={knownActions:[f],actionByRoot:{}},f._byClipCacheIndex=0,ct[E]=gt;else{var St=gt.knownActions;f._byClipCacheIndex=St.length,St.push(f)}f._cacheIndex=ge.length,ge.push(f),gt.actionByRoot[W]=f},_removeInactiveAction:function(f){var E=this._actions,W=E[E.length-1],ge=f._cacheIndex;E[W._cacheIndex=ge]=W,E.pop(),f._cacheIndex=null;var ct=f._clip.uuid,gt=this._actionsByClip,St=gt[ct],Pt=St.knownActions,sn=Pt[Pt.length-1],ln=f._byClipCacheIndex;Pt[sn._byClipCacheIndex=ln]=sn,Pt.pop(),f._byClipCacheIndex=null,delete St.actionByRoot[(f._localRoot||this._root).uuid],Pt.length===0&&delete gt[ct],this._removeInactiveBindingsForAction(f)},_removeInactiveBindingsForAction:function(f){for(var E=f._propertyBindings,W=0,ge=E.length;W!==ge;++W){var ct=E[W];--ct.referenceCount==0&&this._removeInactiveBinding(ct)}},_lendAction:function(f){var E=this._actions,W=f._cacheIndex,ge=this._nActiveActions++,ct=E[ge];E[f._cacheIndex=ge]=f,E[ct._cacheIndex=W]=ct},_takeBackAction:function(f){var E=this._actions,W=f._cacheIndex,ge=--this._nActiveActions,ct=E[ge];E[f._cacheIndex=ge]=f,E[ct._cacheIndex=W]=ct},_addInactiveBinding:function(f,E,W){var ge=this._bindingsByRootAndName,ct=ge[E],gt=this._bindings;ct===void 0&&(ct={},ge[E]=ct),(ct[W]=f)._cacheIndex=gt.length,gt.push(f)},_removeInactiveBinding:function(f){var E=this._bindings,W=f.binding,ge=W.rootNode.uuid,ct=W.path,gt=this._bindingsByRootAndName,St=gt[ge],Pt=E[E.length-1],sn=f._cacheIndex;E[Pt._cacheIndex=sn]=Pt,E.pop(),delete St[ct],Object.keys(St).length===0&&delete gt[ge]},_lendBinding:function(f){var E=this._bindings,W=f._cacheIndex,ge=this._nActiveBindings++,ct=E[ge];E[f._cacheIndex=ge]=f,E[ct._cacheIndex=W]=ct},_takeBackBinding:function(f){var E=this._bindings,W=f._cacheIndex,ge=--this._nActiveBindings,ct=E[ge];E[f._cacheIndex=ge]=f,E[ct._cacheIndex=W]=ct},_lendControlInterpolant:function(){var f=this._controlInterpolants,E=this._nActiveControlInterpolants++,W=f[E];return W===void 0&&(f[(W=new ff(new Float32Array(2),new Float32Array(2),1,this._controlInterpolantsResultBuffer)).__cacheIndex=E]=W),W},_takeBackControlInterpolant:function(f){var E=this._controlInterpolants,W=f.__cacheIndex,ge=--this._nActiveControlInterpolants,ct=E[ge];E[f.__cacheIndex=ge]=f,E[ct.__cacheIndex=W]=ct},_controlInterpolantsResultBuffer:new Float32Array(1),clipAction:function(f,E){var W=E||this._root,ge=W.uuid,ct=typeof f=="string"?jh.findByName(W,f):f,gt=ct!==null?ct.uuid:f,St=this._actionsByClip[gt],Pt=null;if(St!==void 0){var sn=St.actionByRoot[ge];if(sn!==void 0)return sn;Pt=St.knownActions[0],ct===null&&(ct=Pt._clip)}if(ct===null)return null;var ln=new Gg(this,ct,E);return this._bindAction(ln,Pt),this._addInactiveAction(ln,gt,ge),ln},existingAction:function(f,E){var W=E||this._root,ge=W.uuid,ct=typeof f=="string"?jh.findByName(W,f):f,gt=ct?ct.uuid:f,St=this._actionsByClip[gt];return St!==void 0&&St.actionByRoot[ge]||null},stopAllAction:function(){var f=this._actions,E=this._nActiveActions,W=this._bindings,ge=this._nActiveBindings;this._nActiveActions=0;for(var ct=this._nActiveBindings=0;ct!==E;++ct)f[ct].reset();for(ct=0;ct!==ge;++ct)W[ct].useCount=0;return this},update:function(f){f*=this.timeScale;for(var E=this._actions,W=this._nActiveActions,ge=this.time+=f,ct=Math.sign(f),gt=this._accuIndex^=1,St=0;St!==W;++St)E[St]._update(ge,f,ct,gt);var Pt=this._bindings,sn=this._nActiveBindings;for(St=0;St!==sn;++St)Pt[St].apply(gt);return this},setTime:function(f){for(var E=this.time=0;E<this._actions.length;E++)this._actions[E].time=0;return this.update(f)},getRoot:function(){return this._root},uncacheClip:function(f){var E=this._actions,W=f.uuid,ge=this._actionsByClip,ct=ge[W];if(ct!==void 0){for(var gt=ct.knownActions,St=0,Pt=gt.length;St!==Pt;++St){var sn=gt[St];this._deactivateAction(sn);var ln=sn._cacheIndex,Sn=E[E.length-1];sn._cacheIndex=null,sn._byClipCacheIndex=null,E[Sn._cacheIndex=ln]=Sn,E.pop(),this._removeInactiveBindingsForAction(sn)}delete ge[W]}},uncacheRoot:function(f){var E=f.uuid,W=this._actionsByClip;for(var ge in W){var ct=W[ge].actionByRoot[E];ct!==void 0&&(this._deactivateAction(ct),this._removeInactiveAction(ct))}var gt=this._bindingsByRootAndName[E];if(gt!==void 0)for(var St in gt){var Pt=gt[St];Pt.restoreOriginalState(),this._removeInactiveBinding(Pt)}},uncacheAction:function(f,E){var W=this.existingAction(f,E);W!==null&&(this._deactivateAction(W),this._removeInactiveAction(W))}}),mg.prototype.clone=function(){return new mg(this.value.clone===void 0?this.value:this.value.clone())},$g.prototype=Object.assign(Object.create(Vc.prototype),{constructor:$g,isInstancedInterleavedBuffer:!0,copy:function(f){return Vc.prototype.copy.call(this,f),this.meshPerAttribute=f.meshPerAttribute,this}}),Object.assign(gg.prototype,{linePrecision:1,set:function(f,E){this.ray.set(f,E)},setFromCamera:function(f,E){E&&E.isPerspectiveCamera?(this.ray.origin.setFromMatrixPosition(E.matrixWorld),this.ray.direction.set(f.x,f.y,.5).unproject(E).sub(this.ray.origin).normalize(),this.camera=E):E&&E.isOrthographicCamera?(this.ray.origin.set(f.x,f.y,(E.near+E.far)/(E.near-E.far)).unproject(E),this.ray.direction.set(0,0,-1).transformDirection(E.matrixWorld),this.camera=E):console.error("THREE.Raycaster: Unsupported camera type.")},intersectObject:function(f,E,W){var ge=W||[];return vg(f,this,ge,E),ge.sort(yg),ge},intersectObjects:function(f,E,W){var ge=W||[];if(Array.isArray(f)===!1)return console.warn("THREE.Raycaster.intersectObjects: objects is not an Array."),ge;for(var ct=0,gt=f.length;ct<gt;ct++)vg(f[ct],this,ge,E);return ge.sort(yg),ge}}),Object.assign(Gh.prototype,{set:function(f,E,W){return this.radius=f,this.phi=E,this.theta=W,this},clone:function(){return new this.constructor().copy(this)},copy:function(f){return this.radius=f.radius,this.phi=f.phi,this.theta=f.theta,this},makeSafe:function(){return this.phi=Math.max(1e-6,Math.min(Math.PI-1e-6,this.phi)),this},setFromVector3:function(f){return this.setFromCartesianCoords(f.x,f.y,f.z)},setFromCartesianCoords:function(f,E,W){return this.radius=Math.sqrt(f*f+E*E+W*W),this.radius===0?(this.theta=0,this.phi=0):(this.theta=Math.atan2(f,W),this.phi=Math.acos(js.clamp(E/this.radius,-1,1))),this}}),Object.assign(g3.prototype,{set:function(f,E,W){return this.radius=f,this.theta=E,this.y=W,this},clone:function(){return new this.constructor().copy(this)},copy:function(f){return this.radius=f.radius,this.theta=f.theta,this.y=f.y,this},setFromVector3:function(f){return this.setFromCartesianCoords(f.x,f.y,f.z)},setFromCartesianCoords:function(f,E,W){return this.radius=Math.sqrt(f*f+W*W),this.theta=Math.atan2(f,W),this.y=E,this}});var n3=new co;function V3(f,E){this.min=f!==void 0?f:new co(1/0,1/0),this.max=E!==void 0?E:new co(-1/0,-1/0)}Object.assign(V3.prototype,{set:function(f,E){return this.min.copy(f),this.max.copy(E),this},setFromPoints:function(f){this.makeEmpty();for(var E=0,W=f.length;E<W;E++)this.expandByPoint(f[E]);return this},setFromCenterAndSize:function(f,E){var W=n3.copy(E).multiplyScalar(.5);return this.min.copy(f).sub(W),this.max.copy(f).add(W),this},clone:function(){return new this.constructor().copy(this)},copy:function(f){return this.min.copy(f.min),this.max.copy(f.max),this},makeEmpty:function(){return this.min.x=this.min.y=1/0,this.max.x=this.max.y=-1/0,this},isEmpty:function(){return this.max.x<this.min.x||this.max.y<this.min.y},getCenter:function(f){return f===void 0&&(console.warn("THREE.Box2: .getCenter() target is now required"),f=new co),this.isEmpty()?f.set(0,0):f.addVectors(this.min,this.max).multiplyScalar(.5)},getSize:function(f){return f===void 0&&(console.warn("THREE.Box2: .getSize() target is now required"),f=new co),this.isEmpty()?f.set(0,0):f.subVectors(this.max,this.min)},expandByPoint:function(f){return this.min.min(f),this.max.max(f),this},expandByVector:function(f){return this.min.sub(f),this.max.add(f),this},expandByScalar:function(f){return this.min.addScalar(-f),this.max.addScalar(f),this},containsPoint:function(f){return!(f.x<this.min.x||f.x>this.max.x||f.y<this.min.y||f.y>this.max.y)},containsBox:function(f){return this.min.x<=f.min.x&&f.max.x<=this.max.x&&this.min.y<=f.min.y&&f.max.y<=this.max.y},getParameter:function(f,E){return E===void 0&&(console.warn("THREE.Box2: .getParameter() target is now required"),E=new co),E.set((f.x-this.min.x)/(this.max.x-this.min.x),(f.y-this.min.y)/(this.max.y-this.min.y))},intersectsBox:function(f){return!(f.max.x<this.min.x||f.min.x>this.max.x||f.max.y<this.min.y||f.min.y>this.max.y)},clampPoint:function(f,E){return E===void 0&&(console.warn("THREE.Box2: .clampPoint() target is now required"),E=new co),E.copy(f).clamp(this.min,this.max)},distanceToPoint:function(f){return n3.copy(f).clamp(this.min,this.max).sub(f).length()},intersect:function(f){return this.min.max(f.min),this.max.min(f.max),this},union:function(f){return this.min.min(f.min),this.max.max(f.max),this},translate:function(f){return this.min.add(f),this.max.add(f),this},equals:function(f){return f.min.equals(this.min)&&f.max.equals(this.max)}});var N3=new yi,_g=new yi;function xg(f,E){this.start=f!==void 0?f:new yi,this.end=E!==void 0?E:new yi}function bg(f){Ri.call(this),this.material=f,this.render=function(){}}Object.assign(xg.prototype,{set:function(f,E){return this.start.copy(f),this.end.copy(E),this},clone:function(){return new this.constructor().copy(this)},copy:function(f){return this.start.copy(f.start),this.end.copy(f.end),this},getCenter:function(f){return f===void 0&&(console.warn("THREE.Line3: .getCenter() target is now required"),f=new yi),f.addVectors(this.start,this.end).multiplyScalar(.5)},delta:function(f){return f===void 0&&(console.warn("THREE.Line3: .delta() target is now required"),f=new yi),f.subVectors(this.end,this.start)},distanceSq:function(){return this.start.distanceToSquared(this.end)},distance:function(){return this.start.distanceTo(this.end)},at:function(f,E){return E===void 0&&(console.warn("THREE.Line3: .at() target is now required"),E=new yi),this.delta(E).multiplyScalar(f).add(this.start)},closestPointToPointParameter:function(f,E){N3.subVectors(f,this.start),_g.subVectors(this.end,this.start);var W=_g.dot(_g),ge=_g.dot(N3)/W;return E&&(ge=js.clamp(ge,0,1)),ge},closestPointToPoint:function(f,E,W){var ge=this.closestPointToPointParameter(f,E);return W===void 0&&(console.warn("THREE.Line3: .closestPointToPoint() target is now required"),W=new yi),this.delta(W).multiplyScalar(ge).add(this.start)},applyMatrix4:function(f){return this.start.applyMatrix4(f),this.end.applyMatrix4(f),this},equals:function(f){return f.start.equals(this.start)&&f.end.equals(this.end)}}),((bg.prototype=Object.create(Ri.prototype)).constructor=bg).prototype.isImmediateRenderObject=!0;var s0=new yi;function z3(f,E){Ri.call(this),this.light=f,this.light.updateMatrixWorld(),this.matrix=f.matrixWorld,this.matrixAutoUpdate=!1,this.color=E;for(var W=new Ds,ge=[0,0,0,0,0,1,0,0,0,1,0,1,0,0,0,-1,0,1,0,0,0,0,1,1,0,0,0,0,-1,1],ct=0,gt=1;ct<32;ct++,gt++){var St=ct/32*Math.PI*2,Pt=gt/32*Math.PI*2;ge.push(Math.cos(St),Math.sin(St),1,Math.cos(Pt),Math.sin(Pt),1)}W.setAttribute("position",new io(ge,3));var sn=new Pc({fog:!1});this.cone=new xc(W,sn),this.add(this.cone),this.update()}((z3.prototype=Object.create(Ri.prototype)).constructor=z3).prototype.dispose=function(){this.cone.geometry.dispose(),this.cone.material.dispose()},z3.prototype.update=function(){this.light.updateMatrixWorld();var f=this.light.distance?this.light.distance:1e3,E=f*Math.tan(this.light.angle);this.cone.scale.set(E,E,f),s0.setFromMatrixPosition(this.light.target.matrixWorld),this.cone.lookAt(s0),this.color!==void 0?this.cone.material.color.set(this.color):this.cone.material.color.copy(this.light.color)};var Gf=new yi,y3=new Vo,j3=new Vo;function G3(f){for(var E=function Sn(En){var On=[];En&&En.isBone&&On.push(En);for(var mn=0;mn<En.children.length;mn++)On.push.apply(On,Sn(En.children[mn]));return On}(f),W=new Ds,ge=[],ct=[],gt=new la(0,0,1),St=new la(0,1,0),Pt=0;Pt<E.length;Pt++){var sn=E[Pt];sn.parent&&sn.parent.isBone&&(ge.push(0,0,0),ge.push(0,0,0),ct.push(gt.r,gt.g,gt.b),ct.push(St.r,St.g,St.b))}W.setAttribute("position",new io(ge,3)),W.setAttribute("color",new io(ct,3));var ln=new Pc({vertexColors:2,depthTest:!1,depthWrite:!1,transparent:!0});xc.call(this,W,ln),this.root=f,this.bones=E,this.matrix=f.matrixWorld,this.matrixAutoUpdate=!1}function wg(f,E,W){this.light=f,this.light.updateMatrixWorld(),this.color=W;var ge=new Sh(E,4,2),ct=new Ma({wireframe:!0,fog:!1});lu.call(this,ge,ct),this.matrix=this.light.matrixWorld,this.matrixAutoUpdate=!1,this.update()}((G3.prototype=Object.create(xc.prototype)).constructor=G3).prototype.updateMatrixWorld=function(f){var E=this.bones,W=this.geometry,ge=W.getAttribute("position");j3.getInverse(this.root.matrixWorld);for(var ct=0,gt=0;ct<E.length;ct++){var St=E[ct];St.parent&&St.parent.isBone&&(y3.multiplyMatrices(j3,St.matrixWorld),Gf.setFromMatrixPosition(y3),ge.setXYZ(gt,Gf.x,Gf.y,Gf.z),y3.multiplyMatrices(j3,St.parent.matrixWorld),Gf.setFromMatrixPosition(y3),ge.setXYZ(gt+1,Gf.x,Gf.y,Gf.z),gt+=2)}W.getAttribute("position").needsUpdate=!0,Ri.prototype.updateMatrixWorld.call(this,f)},((wg.prototype=Object.create(lu.prototype)).constructor=wg).prototype.dispose=function(){this.geometry.dispose(),this.material.dispose()},wg.prototype.update=function(){this.color!==void 0?this.material.color.set(this.color):this.material.color.copy(this.light.color)};var l0=new yi,_f=new la,Hg=new la;function U3(f,E,W){Ri.call(this),this.light=f,this.light.updateMatrixWorld(),this.matrix=f.matrixWorld,this.matrixAutoUpdate=!1,this.color=W;var ge=new Dc(E);ge.rotateY(.5*Math.PI),this.material=new Ma({wireframe:!0,fog:!1}),this.color===void 0&&(this.material.vertexColors=2);var ct=ge.getAttribute("position"),gt=new Float32Array(3*ct.count);ge.setAttribute("color",new ca(gt,3)),this.add(new lu(ge,this.material)),this.update()}function $3(f,E,W,ge){f=f||10,E=E||10,W=new la(W!==void 0?W:4473924),ge=new la(ge!==void 0?ge:8947848);for(var ct=E/2,gt=f/E,St=f/2,Pt=[],sn=[],ln=0,Sn=0,En=-St;ln<=E;ln++,En+=gt){Pt.push(-St,0,En,St,0,En),Pt.push(En,0,-St,En,0,St);var On=ln===ct?W:ge;On.toArray(sn,Sn),Sn+=3,On.toArray(sn,Sn),Sn+=3,On.toArray(sn,Sn),Sn+=3,On.toArray(sn,Sn),Sn+=3}var mn=new Ds;mn.setAttribute("position",new io(Pt,3)),mn.setAttribute("color",new io(sn,3));var Hn=new Pc({vertexColors:2});xc.call(this,mn,Hn)}function Mg(f,E,W,ge,ct,gt){f=f||10,E=E||16,W=W||8,ge=ge||64,ct=new la(ct!==void 0?ct:4473924),gt=new la(gt!==void 0?gt:8947848);var St,Pt,sn,ln,Sn,En,On,mn=[],Hn=[];for(ln=0;ln<=E;ln++)sn=ln/E*(2*Math.PI),St=Math.sin(sn)*f,Pt=Math.cos(sn)*f,mn.push(0,0,0),mn.push(St,0,Pt),On=1&ln?ct:gt,Hn.push(On.r,On.g,On.b),Hn.push(On.r,On.g,On.b);for(ln=0;ln<=W;ln++)for(On=1&ln?ct:gt,En=f-f/W*ln,Sn=0;Sn<ge;Sn++)sn=Sn/ge*(2*Math.PI),St=Math.sin(sn)*En,Pt=Math.cos(sn)*En,mn.push(St,0,Pt),Hn.push(On.r,On.g,On.b),sn=(Sn+1)/ge*(2*Math.PI),St=Math.sin(sn)*En,Pt=Math.cos(sn)*En,mn.push(St,0,Pt),Hn.push(On.r,On.g,On.b);var mr=new Ds;mr.setAttribute("position",new io(mn,3)),mr.setAttribute("color",new io(Hn,3));var _r=new Pc({vertexColors:2});xc.call(this,mr,_r)}((U3.prototype=Object.create(Ri.prototype)).constructor=U3).prototype.dispose=function(){this.children[0].geometry.dispose(),this.children[0].material.dispose()},U3.prototype.update=function(){var f=this.children[0];if(this.color!==void 0)this.material.color.set(this.color);else{var E=f.geometry.getAttribute("color");_f.copy(this.light.color),Hg.copy(this.light.groundColor);for(var W=0,ge=E.count;W<ge;W++){var ct=W<ge/2?_f:Hg;E.setXYZ(W,ct.r,ct.g,ct.b)}E.needsUpdate=!0}f.lookAt(l0.setFromMatrixPosition(this.light.matrixWorld).negate())},$3.prototype=Object.assign(Object.create(xc.prototype),{constructor:$3,copy:function(f){return xc.prototype.copy.call(this,f),this.geometry.copy(f.geometry),this.material.copy(f.material),this},clone:function(){return new this.constructor().copy(this)}}),(Mg.prototype=Object.create(xc.prototype)).constructor=Mg;var u0=new yi,Cg=new yi,Wg=new yi;function H3(f,E,W){Ri.call(this),this.light=f,this.light.updateMatrixWorld(),this.matrix=f.matrixWorld,this.matrixAutoUpdate=!1,this.color=W,E===void 0&&(E=1);var ge=new Ds;ge.setAttribute("position",new io([-E,E,0,E,E,0,E,-E,0,-E,-E,0,-E,E,0],3));var ct=new Pc({fog:!1});this.lightPlane=new Hc(ge,ct),this.add(this.lightPlane),(ge=new Ds).setAttribute("position",new io([0,0,0,0,0,1],3)),this.targetLine=new Hc(ge,ct),this.add(this.targetLine),this.update()}((H3.prototype=Object.create(Ri.prototype)).constructor=H3).prototype.dispose=function(){this.lightPlane.geometry.dispose(),this.lightPlane.material.dispose(),this.targetLine.geometry.dispose(),this.targetLine.material.dispose()},H3.prototype.update=function(){u0.setFromMatrixPosition(this.light.matrixWorld),Cg.setFromMatrixPosition(this.light.target.matrixWorld),Wg.subVectors(Cg,u0),this.lightPlane.lookAt(Cg),this.color!==void 0?(this.lightPlane.material.color.set(this.color),this.targetLine.material.color.set(this.color)):(this.lightPlane.material.color.copy(this.light.color),this.targetLine.material.color.copy(this.light.color)),this.targetLine.lookAt(Cg),this.targetLine.scale.z=Wg.length()};var wm=new yi,td=new Gd;function Sg(f){var E=new Ds,W=new Pc({color:16777215,vertexColors:1}),ge=[],ct=[],gt={},St=new la(16755200),Pt=new la(16711680),sn=new la(43775),ln=new la(16777215),Sn=new la(3355443);function En(mn,Hn,mr){On(mn,mr),On(Hn,mr)}function On(mn,Hn){ge.push(0,0,0),ct.push(Hn.r,Hn.g,Hn.b),gt[mn]===void 0&&(gt[mn]=[]),gt[mn].push(ge.length/3-1)}En("n1","n2",St),En("n2","n4",St),En("n4","n3",St),En("n3","n1",St),En("f1","f2",St),En("f2","f4",St),En("f4","f3",St),En("f3","f1",St),En("n1","f1",St),En("n2","f2",St),En("n3","f3",St),En("n4","f4",St),En("p","n1",Pt),En("p","n2",Pt),En("p","n3",Pt),En("p","n4",Pt),En("u1","u2",sn),En("u2","u3",sn),En("u3","u1",sn),En("c","t",ln),En("p","c",Sn),En("cn1","cn2",Sn),En("cn3","cn4",Sn),En("cf1","cf2",Sn),En("cf3","cf4",Sn),E.setAttribute("position",new io(ge,3)),E.setAttribute("color",new io(ct,3)),xc.call(this,E,W),this.camera=f,this.camera.updateProjectionMatrix&&this.camera.updateProjectionMatrix(),this.matrix=f.matrixWorld,this.matrixAutoUpdate=!1,this.pointMap=gt,this.update()}function nd(f,E,W,ge,ct,gt,St){wm.set(ct,gt,St).unproject(ge);var Pt=E[f];if(Pt!==void 0)for(var sn=W.getAttribute("position"),ln=0,Sn=Pt.length;ln<Sn;ln++)sn.setXYZ(Pt[ln],wm.x,wm.y,wm.z)}((Sg.prototype=Object.create(xc.prototype)).constructor=Sg).prototype.update=function(){var f=this.geometry,E=this.pointMap;td.projectionMatrixInverse.copy(this.camera.projectionMatrixInverse),nd("c",E,f,td,0,0,-1),nd("t",E,f,td,0,0,1),nd("n1",E,f,td,-1,-1,-1),nd("n2",E,f,td,1,-1,-1),nd("n3",E,f,td,-1,1,-1),nd("n4",E,f,td,1,1,-1),nd("f1",E,f,td,-1,-1,1),nd("f2",E,f,td,1,-1,1),nd("f3",E,f,td,-1,1,1),nd("f4",E,f,td,1,1,1),nd("u1",E,f,td,.7,1.1,-1),nd("u2",E,f,td,-.7,1.1,-1),nd("u3",E,f,td,0,2,-1),nd("cf1",E,f,td,-1,0,1),nd("cf2",E,f,td,1,0,1),nd("cf3",E,f,td,0,-1,1),nd("cf4",E,f,td,0,1,1),nd("cn1",E,f,td,-1,0,-1),nd("cn2",E,f,td,1,0,-1),nd("cn3",E,f,td,0,-1,-1),nd("cn4",E,f,td,0,1,-1),f.getAttribute("position").needsUpdate=!0};var Uf=new Xu;function Mm(f,E){this.object=f,E===void 0&&(E=16776960);var W=new Uint16Array([0,1,1,2,2,3,3,0,4,5,5,6,6,7,7,4,0,4,1,5,2,6,3,7]),ge=new Float32Array(24),ct=new Ds;ct.setIndex(new ca(W,1)),ct.setAttribute("position",new ca(ge,3)),xc.call(this,ct,new Pc({color:E})),this.matrixAutoUpdate=!1,this.update()}function v3(f,E){this.type="Box3Helper",this.box=f,E=E||16776960;var W=new Uint16Array([0,1,1,2,2,3,3,0,4,5,5,6,6,7,7,4,0,4,1,5,2,6,3,7]),ge=new Ds;ge.setIndex(new ca(W,1)),ge.setAttribute("position",new io([1,1,1,-1,1,1,-1,-1,1,1,-1,1,1,1,-1,-1,1,-1,-1,-1,-1,1,-1,-1],3)),xc.call(this,ge,new Pc({color:E})),this.geometry.computeBoundingSphere()}function Tg(f,E,W){this.type="PlaneHelper",this.plane=f,this.size=E===void 0?1:E;var ge=W!==void 0?W:16776960,ct=new Ds;ct.setAttribute("position",new io([1,-1,1,-1,1,1,-1,-1,1,1,1,1,-1,1,1,-1,-1,1,1,-1,1,1,1,1,0,0,1,0,0,0],3)),ct.computeBoundingSphere(),Hc.call(this,ct,new Pc({color:ge}));var gt=new Ds;gt.setAttribute("position",new io([1,1,1,-1,1,1,-1,-1,1,1,1,1,-1,-1,1,1,-1,1],3)),gt.computeBoundingSphere(),this.add(new lu(gt,new Ma({color:ge,opacity:.2,transparent:!0,depthWrite:!1})))}((Mm.prototype=Object.create(xc.prototype)).constructor=Mm).prototype.update=function(f){if(f!==void 0&&console.warn("THREE.BoxHelper: .update() has no longer arguments."),this.object!==void 0&&Uf.setFromObject(this.object),!Uf.isEmpty()){var E=Uf.min,W=Uf.max,ge=this.geometry.attributes.position,ct=ge.array;ct[0]=W.x,ct[1]=W.y,ct[2]=W.z,ct[3]=E.x,ct[4]=W.y,ct[5]=W.z,ct[6]=E.x,ct[7]=E.y,ct[8]=W.z,ct[9]=W.x,ct[10]=E.y,ct[11]=W.z,ct[12]=W.x,ct[13]=W.y,ct[14]=E.z,ct[15]=E.x,ct[16]=W.y,ct[17]=E.z,ct[18]=E.x,ct[19]=E.y,ct[20]=E.z,ct[21]=W.x,ct[22]=E.y,ct[23]=E.z,ge.needsUpdate=!0,this.geometry.computeBoundingSphere()}},Mm.prototype.setFromObject=function(f){return this.object=f,this.update(),this},Mm.prototype.copy=function(f){return xc.prototype.copy.call(this,f),this.object=f.object,this},Mm.prototype.clone=function(){return new this.constructor().copy(this)},((v3.prototype=Object.create(xc.prototype)).constructor=v3).prototype.updateMatrixWorld=function(f){var E=this.box;E.isEmpty()||(E.getCenter(this.position),E.getSize(this.scale),this.scale.multiplyScalar(.5),Ri.prototype.updateMatrixWorld.call(this,f))},((Tg.prototype=Object.create(Hc.prototype)).constructor=Tg).prototype.updateMatrixWorld=function(f){var E=-this.plane.constant;Math.abs(E)<1e-8&&(E=1e-8),this.scale.set(.5*this.size,.5*this.size,E),this.children[0].material.side=E<0?q:G,this.lookAt(this.plane.normal),Ri.prototype.updateMatrixWorld.call(this,f)};var _3,W3,c0=new yi;function r3(f,E,W,ge,ct,gt){Ri.call(this),f===void 0&&(f=new yi(0,0,1)),E===void 0&&(E=new yi(0,0,0)),W===void 0&&(W=1),ge===void 0&&(ge=16776960),ct===void 0&&(ct=.2*W),gt===void 0&&(gt=.2*ct),_3===void 0&&((_3=new Ds).setAttribute("position",new io([0,0,0,0,1,0],3)),(W3=new Cp(0,.5,1,5,1)).translate(0,-.5,0)),this.position.copy(E),this.line=new Hc(_3,new Pc({color:ge})),this.line.matrixAutoUpdate=!1,this.add(this.line),this.cone=new lu(W3,new Ma({color:ge})),this.cone.matrixAutoUpdate=!1,this.add(this.cone),this.setDirection(f),this.setLength(W,ct,gt)}function Dg(f){var E=[0,0,0,f=f||1,0,0,0,0,0,0,f,0,0,0,0,0,0,f],W=new Ds;W.setAttribute("position",new io(E,3)),W.setAttribute("color",new io([1,0,0,1,.6,0,0,1,0,.6,1,0,0,0,1,0,.6,1],3));var ge=new Pc({vertexColors:2});xc.call(this,W,ge)}((r3.prototype=Object.create(Ri.prototype)).constructor=r3).prototype.setDirection=function(f){if(.99999<f.y)this.quaternion.set(0,0,0,1);else if(f.y<-.99999)this.quaternion.set(1,0,0,0);else{c0.set(f.z,0,-f.x).normalize();var E=Math.acos(f.y);this.quaternion.setFromAxisAngle(c0,E)}},r3.prototype.setLength=function(f,E,W){E===void 0&&(E=.2*f),W===void 0&&(W=.2*E),this.line.scale.set(1,Math.max(1e-4,f-E),1),this.line.updateMatrix(),this.cone.scale.set(W,E,W),this.cone.position.y=f,this.cone.updateMatrix()},r3.prototype.setColor=function(f){this.line.material.color.set(f),this.cone.material.color.set(f)},r3.prototype.copy=function(f){return Ri.prototype.copy.call(this,f,!1),this.line.copy(f.line),this.cone.copy(f.cone),this},r3.prototype.clone=function(){return new this.constructor().copy(this)},(Dg.prototype=Object.create(xc.prototype)).constructor=Dg;var x3=4,Cm=8,Dh=Math.pow(2,Cm),Eg=[.125,.215,.35,.446,.526,.582],d0=Cm-x3+1+Eg.length,i3=20,nh={};nh[qi]=0,nh[ga]=1,nh[mo]=2,nh[Uo]=3,nh[Ns]=4,nh[jl]=5,nh[no]=6;var Ag,h0,xf=new ap,q3=((h0=new Kp({defines:{n:Ag=i3},uniforms:{envMap:{value:null},samples:{value:1},weights:{value:new Float32Array(Ag)},latitudinal:{value:!1},dTheta:{value:0},mipInt:{value:0},poleAxis:{value:new yi(0,1,0)},inputEncoding:{value:nh[qi]},outputEncoding:{value:nh[qi]}},vertexShader:`
- precision mediump float;
- precision mediump int;
- attribute vec3 position;
- attribute vec2 uv;
- attribute float faceIndex;
- varying vec3 vOutputDirection;
- vec3 getDirection(vec2 uv, float face) {
- uv = 2.0 * uv - 1.0;
- vec3 direction = vec3(uv, 1.0);
- if (face == 0.0) {
- direction = direction.zyx;
- direction.z *= -1.0;
- } else if (face == 1.0) {
- direction = direction.xzy;
- direction.z *= -1.0;
- } else if (face == 3.0) {
- direction = direction.zyx;
- direction.x *= -1.0;
- } else if (face == 4.0) {
- direction = direction.xzy;
- direction.y *= -1.0;
- } else if (face == 5.0) {
- direction.xz *= -1.0;
- }
- return direction;
- }
- void main() {
- vOutputDirection = getDirection(uv, faceIndex);
- gl_Position = vec4( position, 1.0 );
- }
- `,fragmentShader:`
- precision mediump float;
- precision mediump int;
- varying vec3 vOutputDirection;
- uniform sampler2D envMap;
- uniform int samples;
- uniform float weights[n];
- uniform bool latitudinal;
- uniform float dTheta;
- uniform float mipInt;
- uniform vec3 poleAxis;
- uniform int inputEncoding;
- uniform int outputEncoding;
- #include <encodings_pars_fragment>
- vec4 inputTexelToLinear(vec4 value){
- if(inputEncoding == 0){
- return value;
- }else if(inputEncoding == 1){
- return sRGBToLinear(value);
- }else if(inputEncoding == 2){
- return RGBEToLinear(value);
- }else if(inputEncoding == 3){
- return RGBMToLinear(value, 7.0);
- }else if(inputEncoding == 4){
- return RGBMToLinear(value, 16.0);
- }else if(inputEncoding == 5){
- return RGBDToLinear(value, 256.0);
- }else{
- return GammaToLinear(value, 2.2);
- }
- }
- vec4 linearToOutputTexel(vec4 value){
- if(outputEncoding == 0){
- return value;
- }else if(outputEncoding == 1){
- return LinearTosRGB(value);
- }else if(outputEncoding == 2){
- return LinearToRGBE(value);
- }else if(outputEncoding == 3){
- return LinearToRGBM(value, 7.0);
- }else if(outputEncoding == 4){
- return LinearToRGBM(value, 16.0);
- }else if(outputEncoding == 5){
- return LinearToRGBD(value, 256.0);
- }else{
- return LinearToGamma(value, 2.2);
- }
- }
- vec4 envMapTexelToLinear(vec4 color) {
- return inputTexelToLinear(color);
- }
-
- #define ENVMAP_TYPE_CUBE_UV
- #include <cube_uv_reflection_fragment>
- void main() {
- gl_FragColor = vec4(0.0);
- for (int i = 0; i < n; i++) {
- if (i >= samples)
- break;
- for (int dir = -1; dir < 2; dir += 2) {
- if (i == 0 && dir == 1)
- continue;
- vec3 axis = latitudinal ? poleAxis : cross(poleAxis, vOutputDirection);
- if (all(equal(axis, vec3(0.0))))
- axis = cross(vec3(0.0, 1.0, 0.0), vOutputDirection);
- axis = normalize(axis);
- float theta = dTheta * float(dir * i);
- float cosTheta = cos(theta);
- // Rodrigues' axis-angle rotation
- vec3 sampleDirection = vOutputDirection * cosTheta
- + cross(axis, vOutputDirection) * sin(theta)
- + axis * dot(axis, vOutputDirection) * (1.0 - cosTheta);
- gl_FragColor.rgb +=
- weights[i] * bilinearCubeUV(envMap, sampleDirection, mipInt);
- }
- }
- gl_FragColor = linearToOutputTexel(gl_FragColor);
- }
- `,blending:ve,depthTest:!1,depthWrite:!1})).type="SphericalGaussianBlur",h0),Sm=null,bf=null,Y3=function(){for(var f=[],E=[],W=[],ge=Cm,ct=0;ct<d0;ct++){var gt=Math.pow(2,ge);E.push(gt);var St=1/gt;Cm-x3<ct?St=Eg[ct-Cm+x3-1]:ct==0&&(St=0),W.push(St);for(var Pt=1/(gt-1),sn=-Pt/2,ln=1+Pt/2,Sn=[sn,sn,ln,sn,ln,ln,sn,sn,ln,ln,sn,ln],En=new Float32Array(108),On=new Float32Array(72),mn=new Float32Array(36),Hn=0;Hn<6;Hn++){var mr=Hn%3*2/3-1,_r=2<Hn?0:-1,gi=[mr,_r,0,mr+2/3,_r,0,mr+2/3,1+_r,0,mr,_r,0,mr+2/3,1+_r,0,mr,1+_r,0];En.set(gi,18*Hn),On.set(Sn,12*Hn);var Ci=[Hn,Hn,Hn,Hn,Hn,Hn];mn.set(Ci,6*Hn)}var $i=new Ds;$i.setAttribute("position",new ca(En,3)),$i.setAttribute("uv",new ca(On,2)),$i.setAttribute("faceIndex",new ca(mn,1)),f.push($i),x3<ge&&ge--}return{_lodPlanes:f,_sizeLods:E,_sigmas:W}}(),Z3=Y3._lodPlanes,p0=Y3._sizeLods,kg=Y3._sigmas,a3=null,Mc=null,qg=null,$f=(1+Math.sqrt(5))/2,Tm=1/$f,Hf=[new yi(1,1,1),new yi(-1,1,1),new yi(1,1,-1),new yi(-1,1,-1),new yi(0,$f,Tm),new yi(0,$f,-Tm),new yi(Tm,0,$f),new yi(-Tm,0,$f),new yi($f,Tm,0),new yi(-$f,Tm,0)];function Yg(f){Mc=f,b3(q3)}function Pg(f){var E={magFilter:un,minFilter:un,generateMipmaps:!1,type:f?f.type:so,format:f?f.format:Gr,encoding:f?f.encoding:mo,depthBuffer:!1,stencilBuffer:!1},W=f0(E);return W.depthBuffer=!f,a3=f0(E),W}function Zg(f){a3.dispose(),Mc.setRenderTarget(qg),f.scissorTest=!1,f.setSize(f.width,f.height)}function b3(f){var E=new fa;E.add(new lu(Z3[0],f)),Mc.compile(E,xf)}function f0(f){var E=new Au(3*Dh,3*Dh,f);return E.texture.mapping=fi,E.texture.name="PMREM.cubeUv",E.scissorTest=!0,E}function Kg(f,E,W,ge,ct){f.viewport.set(E,W,ge,ct),f.scissor.set(E,W,ge,ct)}function m0(f){var E=Mc.autoClear;Mc.autoClear=!1;for(var W=1;W<d0;W++)g0(f,W-1,W,Math.sqrt(kg[W]*kg[W]-kg[W-1]*kg[W-1]),Hf[(W-1)%Hf.length]);Mc.autoClear=E}function g0(f,E,W,ge,ct){Ig(f,a3,E,W,ge,"latitudinal",ct),Ig(a3,f,W,W,ge,"longitudinal",ct)}function Ig(f,E,W,ge,ct,gt,St){gt!=="latitudinal"&>!=="longitudinal"&&console.error("blur direction must be either latitudinal or longitudinal!");var Pt=new fa;Pt.add(new lu(Z3[ge],q3));var sn=q3.uniforms,ln=p0[W]-1,Sn=isFinite(ct)?Math.PI/(2*ln):2*Math.PI/(2*i3-1),En=ct/Sn,On=isFinite(ct)?1+Math.floor(3*En):i3;i3<On&&console.warn("sigmaRadians, "+ct+", is too large and will clip, as it requested "+On+" samples when the maximum is set to "+i3);for(var mn=[],Hn=0,mr=0;mr<i3;++mr){var _r=mr/En,gi=Math.exp(-_r*_r/2);mn.push(gi),mr==0?Hn+=gi:mr<On&&(Hn+=2*gi)}for(mr=0;mr<mn.length;mr++)mn[mr]=mn[mr]/Hn;sn.envMap.value=f.texture,sn.samples.value=On,sn.weights.value=mn,sn.latitudinal.value=gt==="latitudinal",St&&(sn.poleAxis.value=St),sn.dTheta.value=Sn,sn.mipInt.value=Cm-W,sn.inputEncoding.value=nh[f.texture.encoding],sn.outputEncoding.value=nh[f.texture.encoding];var Ci=p0[ge];Kg(E,_r=3*Math.max(0,Dh-2*Ci),(ge===0?0:2*Dh)+2*Ci*(Cm-x3<ge?ge-Cm+x3:0),3*Ci,2*Ci),Mc.setRenderTarget(E),Mc.render(Pt,xf)}function y0(){var f=new Kp({uniforms:{envMap:{value:null},texelSize:{value:new co(1,1)},inputEncoding:{value:nh[qi]},outputEncoding:{value:nh[qi]}},vertexShader:`
- precision mediump float;
- precision mediump int;
- attribute vec3 position;
- attribute vec2 uv;
- attribute float faceIndex;
- varying vec3 vOutputDirection;
- vec3 getDirection(vec2 uv, float face) {
- uv = 2.0 * uv - 1.0;
- vec3 direction = vec3(uv, 1.0);
- if (face == 0.0) {
- direction = direction.zyx;
- direction.z *= -1.0;
- } else if (face == 1.0) {
- direction = direction.xzy;
- direction.z *= -1.0;
- } else if (face == 3.0) {
- direction = direction.zyx;
- direction.x *= -1.0;
- } else if (face == 4.0) {
- direction = direction.xzy;
- direction.y *= -1.0;
- } else if (face == 5.0) {
- direction.xz *= -1.0;
- }
- return direction;
- }
- void main() {
- vOutputDirection = getDirection(uv, faceIndex);
- gl_Position = vec4( position, 1.0 );
- }
- `,fragmentShader:`
- precision mediump float;
- precision mediump int;
- varying vec3 vOutputDirection;
- uniform sampler2D envMap;
- uniform vec2 texelSize;
- uniform int inputEncoding;
- uniform int outputEncoding;
- #include <encodings_pars_fragment>
- vec4 inputTexelToLinear(vec4 value){
- if(inputEncoding == 0){
- return value;
- }else if(inputEncoding == 1){
- return sRGBToLinear(value);
- }else if(inputEncoding == 2){
- return RGBEToLinear(value);
- }else if(inputEncoding == 3){
- return RGBMToLinear(value, 7.0);
- }else if(inputEncoding == 4){
- return RGBMToLinear(value, 16.0);
- }else if(inputEncoding == 5){
- return RGBDToLinear(value, 256.0);
- }else{
- return GammaToLinear(value, 2.2);
- }
- }
- vec4 linearToOutputTexel(vec4 value){
- if(outputEncoding == 0){
- return value;
- }else if(outputEncoding == 1){
- return LinearTosRGB(value);
- }else if(outputEncoding == 2){
- return LinearToRGBE(value);
- }else if(outputEncoding == 3){
- return LinearToRGBM(value, 7.0);
- }else if(outputEncoding == 4){
- return LinearToRGBM(value, 16.0);
- }else if(outputEncoding == 5){
- return LinearToRGBD(value, 256.0);
- }else{
- return LinearToGamma(value, 2.2);
- }
- }
- vec4 envMapTexelToLinear(vec4 color) {
- return inputTexelToLinear(color);
- }
-
- #define RECIPROCAL_PI 0.31830988618
- #define RECIPROCAL_PI2 0.15915494
- void main() {
- gl_FragColor = vec4(0.0);
- vec3 outputDirection = normalize(vOutputDirection);
- vec2 uv;
- uv.y = asin(clamp(outputDirection.y, -1.0, 1.0)) * RECIPROCAL_PI + 0.5;
- uv.x = atan(outputDirection.z, outputDirection.x) * RECIPROCAL_PI2 + 0.5;
- vec2 f = fract(uv / texelSize - 0.5);
- uv -= f * texelSize;
- vec3 tl = envMapTexelToLinear(texture2D(envMap, uv)).rgb;
- uv.x += texelSize.x;
- vec3 tr = envMapTexelToLinear(texture2D(envMap, uv)).rgb;
- uv.y += texelSize.y;
- vec3 br = envMapTexelToLinear(texture2D(envMap, uv)).rgb;
- uv.x -= texelSize.x;
- vec3 bl = envMapTexelToLinear(texture2D(envMap, uv)).rgb;
- vec3 tm = mix(tl, tr, f.x);
- vec3 bm = mix(bl, br, f.x);
- gl_FragColor.rgb = mix(tm, bm, f.y);
- gl_FragColor = linearToOutputTexel(gl_FragColor);
- }
- `,blending:ve,depthTest:!1,depthWrite:!1});return f.type="EquirectangularToCubeUV",f}function w3(){var f=new Kp({uniforms:{envMap:{value:null},inputEncoding:{value:nh[qi]},outputEncoding:{value:nh[qi]}},vertexShader:`
- precision mediump float;
- precision mediump int;
- attribute vec3 position;
- attribute vec2 uv;
- attribute float faceIndex;
- varying vec3 vOutputDirection;
- vec3 getDirection(vec2 uv, float face) {
- uv = 2.0 * uv - 1.0;
- vec3 direction = vec3(uv, 1.0);
- if (face == 0.0) {
- direction = direction.zyx;
- direction.z *= -1.0;
- } else if (face == 1.0) {
- direction = direction.xzy;
- direction.z *= -1.0;
- } else if (face == 3.0) {
- direction = direction.zyx;
- direction.x *= -1.0;
- } else if (face == 4.0) {
- direction = direction.xzy;
- direction.y *= -1.0;
- } else if (face == 5.0) {
- direction.xz *= -1.0;
- }
- return direction;
- }
- void main() {
- vOutputDirection = getDirection(uv, faceIndex);
- gl_Position = vec4( position, 1.0 );
- }
- `,fragmentShader:`
- precision mediump float;
- precision mediump int;
- varying vec3 vOutputDirection;
- uniform samplerCube envMap;
- uniform int inputEncoding;
- uniform int outputEncoding;
- #include <encodings_pars_fragment>
- vec4 inputTexelToLinear(vec4 value){
- if(inputEncoding == 0){
- return value;
- }else if(inputEncoding == 1){
- return sRGBToLinear(value);
- }else if(inputEncoding == 2){
- return RGBEToLinear(value);
- }else if(inputEncoding == 3){
- return RGBMToLinear(value, 7.0);
- }else if(inputEncoding == 4){
- return RGBMToLinear(value, 16.0);
- }else if(inputEncoding == 5){
- return RGBDToLinear(value, 256.0);
- }else{
- return GammaToLinear(value, 2.2);
- }
- }
- vec4 linearToOutputTexel(vec4 value){
- if(outputEncoding == 0){
- return value;
- }else if(outputEncoding == 1){
- return LinearTosRGB(value);
- }else if(outputEncoding == 2){
- return LinearToRGBE(value);
- }else if(outputEncoding == 3){
- return LinearToRGBM(value, 7.0);
- }else if(outputEncoding == 4){
- return LinearToRGBM(value, 16.0);
- }else if(outputEncoding == 5){
- return LinearToRGBD(value, 256.0);
- }else{
- return LinearToGamma(value, 2.2);
- }
- }
- vec4 envMapTexelToLinear(vec4 color) {
- return inputTexelToLinear(color);
- }
-
- void main() {
- gl_FragColor = vec4(0.0);
- gl_FragColor.rgb = envMapTexelToLinear(textureCube(envMap, vec3( - vOutputDirection.x, vOutputDirection.yz ))).rgb;
- gl_FragColor = linearToOutputTexel(gl_FragColor);
- }
- `,blending:ve,depthTest:!1,depthWrite:!1});return f.type="CubemapToCubeUV",f}function Rg(f){console.warn("THREE.ClosedSplineCurve3 has been deprecated. Use THREE.CatmullRomCurve3 instead."),Qs.call(this,f),this.type="catmullrom",this.closed=!0}function v0(f){console.warn("THREE.SplineCurve3 has been deprecated. Use THREE.CatmullRomCurve3 instead."),Qs.call(this,f),this.type="catmullrom"}function Xg(f){console.warn("THREE.Spline has been removed. Use THREE.CatmullRomCurve3 instead."),Qs.call(this,f),this.type="catmullrom"}Yg.prototype={constructor:Yg,fromScene:function(f,E,W,ge){E===void 0&&(E=0),W===void 0&&(W=.1),ge===void 0&&(ge=100),qg=Mc.getRenderTarget();var ct=Pg();return function(gt,St,Pt,sn){var ln=new cc(90,1,St,Pt),Sn=[1,1,1,1,-1,1],En=[1,1,-1,-1,-1,1],On=Mc.outputEncoding,mn=Mc.toneMapping,Hn=Mc.toneMappingExposure,mr=Mc.getClearColor(),_r=Mc.getClearAlpha();Mc.toneMapping=Yn,Mc.toneMappingExposure=1,Mc.outputEncoding=qi,gt.scale.z*=-1;var gi=gt.background;if(gi&&gi.isColor){gi.convertSRGBToLinear();var Ci=Math.max(gi.r,gi.g,gi.b),$i=Math.min(Math.max(Math.ceil(Math.log2(Ci)),-128),127);gi=gi.multiplyScalar(Math.pow(2,-$i));var da=($i+128)/255;Mc.setClearColor(gi,da),gt.background=null}for(var ji=0;ji<6;ji++){var Sa=ji%3;Sa==0?(ln.up.set(0,Sn[ji],0),ln.lookAt(En[ji],0,0)):Sa==1?(ln.up.set(0,0,Sn[ji]),ln.lookAt(0,En[ji],0)):(ln.up.set(0,Sn[ji],0),ln.lookAt(0,0,En[ji])),Kg(sn,Sa*Dh,2<ji?Dh:0,Dh,Dh),Mc.setRenderTarget(sn),Mc.render(gt,ln)}Mc.toneMapping=mn,Mc.toneMappingExposure=Hn,Mc.outputEncoding=On,Mc.setClearColor(mr,_r),gt.scale.z*=-1}(f,W,ge,ct),0<E&&g0(ct,0,0,E),m0(ct),Zg(ct),ct},fromEquirectangular:function(f){return f.magFilter=un,f.minFilter=un,f.generateMipmaps=!1,this.fromCubemap(f)},fromCubemap:function(f){qg=Mc.getRenderTarget();var E=Pg(f);return function(W,ge){var ct=new fa;W.isCubeTexture?bf==null&&(bf=w3()):Sm==null&&(Sm=y0());var gt=W.isCubeTexture?bf:Sm;ct.add(new lu(Z3[0],gt));var St=gt.uniforms;(St.envMap.value=W).isCubeTexture||St.texelSize.value.set(1/W.image.width,1/W.image.height),St.inputEncoding.value=nh[W.encoding],St.outputEncoding.value=nh[W.encoding],Kg(ge,0,0,3*Dh,2*Dh),Mc.setRenderTarget(ge),Mc.render(ct,xf)}(f,E),m0(E),Zg(E),E},compileCubemapShader:function(){bf==null&&b3(bf=w3())},compileEquirectangularShader:function(){Sm==null&&b3(Sm=y0())},dispose:function(){q3.dispose(),bf?.dispose(),Sm?.dispose();for(var f=0;f<Z3.length;f++)Z3[f].dispose()}},Oa.create=function(f,E){return console.log("THREE.Curve.create() has been deprecated"),f.prototype=Object.create(Oa.prototype),(f.prototype.constructor=f).prototype.getPoint=E,f},Object.assign(Ed.prototype,{createPointsGeometry:function(f){console.warn("THREE.CurvePath: .createPointsGeometry() has been removed. Use new THREE.Geometry().setFromPoints( points ) instead.");var E=this.getPoints(f);return this.createGeometry(E)},createSpacedPointsGeometry:function(f){console.warn("THREE.CurvePath: .createSpacedPointsGeometry() has been removed. Use new THREE.Geometry().setFromPoints( points ) instead.");var E=this.getSpacedPoints(f);return this.createGeometry(E)},createGeometry:function(f){console.warn("THREE.CurvePath: .createGeometry() has been removed. Use new THREE.Geometry().setFromPoints( points ) instead.");for(var E=new ul,W=0,ge=f.length;W<ge;W++){var ct=f[W];E.vertices.push(new yi(ct.x,ct.y,ct.z||0))}return E}}),Object.assign(md.prototype,{fromPoints:function(f){return console.warn("THREE.Path: .fromPoints() has been renamed to .setFromPoints()."),this.setFromPoints(f)}}),Rg.prototype=Object.create(Qs.prototype),v0.prototype=Object.create(Qs.prototype),Xg.prototype=Object.create(Qs.prototype),Object.assign(Xg.prototype,{initFromArray:function(){console.error("THREE.Spline: .initFromArray() has been removed.")},getControlPointsArray:function(){console.error("THREE.Spline: .getControlPointsArray() has been removed.")},reparametrizeByArcLength:function(){console.error("THREE.Spline: .reparametrizeByArcLength() has been removed.")}}),$3.prototype.setColors=function(){console.error("THREE.GridHelper: setColors() has been deprecated, pass them in the constructor instead.")},G3.prototype.update=function(){console.error("THREE.SkeletonHelper: update() no longer needs to be called.")},Object.assign(Ze.prototype,{extractUrlBase:function(f){return console.warn("THREE.Loader: .extractUrlBase() has been deprecated. Use THREE.LoaderUtils.extractUrlBase() instead."),rg.extractUrlBase(f)}}),Ze.Handlers={add:function(){console.error("THREE.Loader: Handlers.add() has been removed. Use LoadingManager.addHandler() instead.")},get:function(){console.error("THREE.Loader: Handlers.get() has been removed. Use LoadingManager.getHandler() instead.")}},Object.assign(og.prototype,{setTexturePath:function(f){return console.warn("THREE.ObjectLoader: .setTexturePath() has been renamed to .setResourcePath()."),this.setResourcePath(f)}}),Object.assign(V3.prototype,{center:function(f){return console.warn("THREE.Box2: .center() has been renamed to .getCenter()."),this.getCenter(f)},empty:function(){return console.warn("THREE.Box2: .empty() has been renamed to .isEmpty()."),this.isEmpty()},isIntersectionBox:function(f){return console.warn("THREE.Box2: .isIntersectionBox() has been renamed to .intersectsBox()."),this.intersectsBox(f)},size:function(f){return console.warn("THREE.Box2: .size() has been renamed to .getSize()."),this.getSize(f)}}),Object.assign(Xu.prototype,{center:function(f){return console.warn("THREE.Box3: .center() has been renamed to .getCenter()."),this.getCenter(f)},empty:function(){return console.warn("THREE.Box3: .empty() has been renamed to .isEmpty()."),this.isEmpty()},isIntersectionBox:function(f){return console.warn("THREE.Box3: .isIntersectionBox() has been renamed to .intersectsBox()."),this.intersectsBox(f)},isIntersectionSphere:function(f){return console.warn("THREE.Box3: .isIntersectionSphere() has been renamed to .intersectsSphere()."),this.intersectsSphere(f)},size:function(f){return console.warn("THREE.Box3: .size() has been renamed to .getSize()."),this.getSize(f)}}),Ih.prototype.setFromMatrix=function(f){return console.warn("THREE.Frustum: .setFromMatrix() has been renamed to .setFromProjectionMatrix()."),this.setFromProjectionMatrix(f)},xg.prototype.center=function(f){return console.warn("THREE.Line3: .center() has been renamed to .getCenter()."),this.getCenter(f)},Object.assign(js,{random16:function(){return console.warn("THREE.Math: .random16() has been deprecated. Use Math.random() instead."),Math.random()},nearestPowerOfTwo:function(f){return console.warn("THREE.Math: .nearestPowerOfTwo() has been renamed to .floorPowerOfTwo()."),js.floorPowerOfTwo(f)},nextPowerOfTwo:function(f){return console.warn("THREE.Math: .nextPowerOfTwo() has been renamed to .ceilPowerOfTwo()."),js.ceilPowerOfTwo(f)}}),Object.assign(Vl.prototype,{flattenToArrayOffset:function(f,E){return console.warn("THREE.Matrix3: .flattenToArrayOffset() has been deprecated. Use .toArray() instead."),this.toArray(f,E)},multiplyVector3:function(f){return console.warn("THREE.Matrix3: .multiplyVector3() has been removed. Use vector.applyMatrix3( matrix ) instead."),f.applyMatrix3(this)},multiplyVector3Array:function(){console.error("THREE.Matrix3: .multiplyVector3Array() has been removed.")},applyToBufferAttribute:function(f){return console.warn("THREE.Matrix3: .applyToBufferAttribute() has been removed. Use attribute.applyMatrix3( matrix ) instead."),f.applyMatrix3(this)},applyToVector3Array:function(){console.error("THREE.Matrix3: .applyToVector3Array() has been removed.")}}),Object.assign(Vo.prototype,{extractPosition:function(f){return console.warn("THREE.Matrix4: .extractPosition() has been renamed to .copyPosition()."),this.copyPosition(f)},flattenToArrayOffset:function(f,E){return console.warn("THREE.Matrix4: .flattenToArrayOffset() has been deprecated. Use .toArray() instead."),this.toArray(f,E)},getPosition:function(){return console.warn("THREE.Matrix4: .getPosition() has been removed. Use Vector3.setFromMatrixPosition( matrix ) instead."),new yi().setFromMatrixColumn(this,3)},setRotationFromQuaternion:function(f){return console.warn("THREE.Matrix4: .setRotationFromQuaternion() has been renamed to .makeRotationFromQuaternion()."),this.makeRotationFromQuaternion(f)},multiplyToArray:function(){console.warn("THREE.Matrix4: .multiplyToArray() has been removed.")},multiplyVector3:function(f){return console.warn("THREE.Matrix4: .multiplyVector3() has been removed. Use vector.applyMatrix4( matrix ) instead."),f.applyMatrix4(this)},multiplyVector4:function(f){return console.warn("THREE.Matrix4: .multiplyVector4() has been removed. Use vector.applyMatrix4( matrix ) instead."),f.applyMatrix4(this)},multiplyVector3Array:function(){console.error("THREE.Matrix4: .multiplyVector3Array() has been removed.")},rotateAxis:function(f){console.warn("THREE.Matrix4: .rotateAxis() has been removed. Use Vector3.transformDirection( matrix ) instead."),f.transformDirection(this)},crossVector:function(f){return console.warn("THREE.Matrix4: .crossVector() has been removed. Use vector.applyMatrix4( matrix ) instead."),f.applyMatrix4(this)},translate:function(){console.error("THREE.Matrix4: .translate() has been removed.")},rotateX:function(){console.error("THREE.Matrix4: .rotateX() has been removed.")},rotateY:function(){console.error("THREE.Matrix4: .rotateY() has been removed.")},rotateZ:function(){console.error("THREE.Matrix4: .rotateZ() has been removed.")},rotateByAxis:function(){console.error("THREE.Matrix4: .rotateByAxis() has been removed.")},applyToBufferAttribute:function(f){return console.warn("THREE.Matrix4: .applyToBufferAttribute() has been removed. Use attribute.applyMatrix4( matrix ) instead."),f.applyMatrix4(this)},applyToVector3Array:function(){console.error("THREE.Matrix4: .applyToVector3Array() has been removed.")},makeFrustum:function(f,E,W,ge,ct,gt){return console.warn("THREE.Matrix4: .makeFrustum() has been removed. Use .makePerspective( left, right, top, bottom, near, far ) instead."),this.makePerspective(f,E,ge,W,ct,gt)}}),wu.prototype.isIntersectionLine=function(f){return console.warn("THREE.Plane: .isIntersectionLine() has been renamed to .intersectsLine()."),this.intersectsLine(f)},Wu.prototype.multiplyVector3=function(f){return console.warn("THREE.Quaternion: .multiplyVector3() has been removed. Use is now vector.applyQuaternion( quaternion ) instead."),f.applyQuaternion(this)},Object.assign(Hl.prototype,{isIntersectionBox:function(f){return console.warn("THREE.Ray: .isIntersectionBox() has been renamed to .intersectsBox()."),this.intersectsBox(f)},isIntersectionPlane:function(f){return console.warn("THREE.Ray: .isIntersectionPlane() has been renamed to .intersectsPlane()."),this.intersectsPlane(f)},isIntersectionSphere:function(f){return console.warn("THREE.Ray: .isIntersectionSphere() has been renamed to .intersectsSphere()."),this.intersectsSphere(f)}}),Object.assign(qu.prototype,{area:function(){return console.warn("THREE.Triangle: .area() has been renamed to .getArea()."),this.getArea()},barycoordFromPoint:function(f,E){return console.warn("THREE.Triangle: .barycoordFromPoint() has been renamed to .getBarycoord()."),this.getBarycoord(f,E)},midpoint:function(f){return console.warn("THREE.Triangle: .midpoint() has been renamed to .getMidpoint()."),this.getMidpoint(f)},normal:function(f){return console.warn("THREE.Triangle: .normal() has been renamed to .getNormal()."),this.getNormal(f)},plane:function(f){return console.warn("THREE.Triangle: .plane() has been renamed to .getPlane()."),this.getPlane(f)}}),Object.assign(qu,{barycoordFromPoint:function(f,E,W,ge,ct){return console.warn("THREE.Triangle: .barycoordFromPoint() has been renamed to .getBarycoord()."),qu.getBarycoord(f,E,W,ge,ct)},normal:function(f,E,W,ge){return console.warn("THREE.Triangle: .normal() has been renamed to .getNormal()."),qu.getNormal(f,E,W,ge)}}),Object.assign(th.prototype,{extractAllPoints:function(f){return console.warn("THREE.Shape: .extractAllPoints() has been removed. Use .extractPoints() instead."),this.extractPoints(f)},extrude:function(f){return console.warn("THREE.Shape: .extrude() has been removed. Use ExtrudeGeometry() instead."),new Yp(this,f)},makeGeometry:function(f){return console.warn("THREE.Shape: .makeGeometry() has been removed. Use ShapeGeometry() instead."),new dm(this,f)}}),Object.assign(co.prototype,{fromAttribute:function(f,E,W){return console.warn("THREE.Vector2: .fromAttribute() has been renamed to .fromBufferAttribute()."),this.fromBufferAttribute(f,E,W)},distanceToManhattan:function(f){return console.warn("THREE.Vector2: .distanceToManhattan() has been renamed to .manhattanDistanceTo()."),this.manhattanDistanceTo(f)},lengthManhattan:function(){return console.warn("THREE.Vector2: .lengthManhattan() has been renamed to .manhattanLength()."),this.manhattanLength()}}),Object.assign(yi.prototype,{setEulerFromRotationMatrix:function(){console.error("THREE.Vector3: .setEulerFromRotationMatrix() has been removed. Use Euler.setFromRotationMatrix() instead.")},setEulerFromQuaternion:function(){console.error("THREE.Vector3: .setEulerFromQuaternion() has been removed. Use Euler.setFromQuaternion() instead.")},getPositionFromMatrix:function(f){return console.warn("THREE.Vector3: .getPositionFromMatrix() has been renamed to .setFromMatrixPosition()."),this.setFromMatrixPosition(f)},getScaleFromMatrix:function(f){return console.warn("THREE.Vector3: .getScaleFromMatrix() has been renamed to .setFromMatrixScale()."),this.setFromMatrixScale(f)},getColumnFromMatrix:function(f,E){return console.warn("THREE.Vector3: .getColumnFromMatrix() has been renamed to .setFromMatrixColumn()."),this.setFromMatrixColumn(E,f)},applyProjection:function(f){return console.warn("THREE.Vector3: .applyProjection() has been removed. Use .applyMatrix4( m ) instead."),this.applyMatrix4(f)},fromAttribute:function(f,E,W){return console.warn("THREE.Vector3: .fromAttribute() has been renamed to .fromBufferAttribute()."),this.fromBufferAttribute(f,E,W)},distanceToManhattan:function(f){return console.warn("THREE.Vector3: .distanceToManhattan() has been renamed to .manhattanDistanceTo()."),this.manhattanDistanceTo(f)},lengthManhattan:function(){return console.warn("THREE.Vector3: .lengthManhattan() has been renamed to .manhattanLength()."),this.manhattanLength()}}),Object.assign(Ll.prototype,{fromAttribute:function(f,E,W){return console.warn("THREE.Vector4: .fromAttribute() has been renamed to .fromBufferAttribute()."),this.fromBufferAttribute(f,E,W)},lengthManhattan:function(){return console.warn("THREE.Vector4: .lengthManhattan() has been renamed to .manhattanLength()."),this.manhattanLength()}}),Object.assign(ul.prototype,{computeTangents:function(){console.error("THREE.Geometry: .computeTangents() has been removed.")},computeLineDistances:function(){console.error("THREE.Geometry: .computeLineDistances() has been removed. Use THREE.Line.computeLineDistances() instead.")},applyMatrix:function(f){return console.warn("THREE.Geometry: .applyMatrix() has been renamed to .applyMatrix4()."),this.applyMatrix4(f)}}),Object.assign(Ri.prototype,{getChildByName:function(f){return console.warn("THREE.Object3D: .getChildByName() has been renamed to .getObjectByName()."),this.getObjectByName(f)},renderDepth:function(){console.warn("THREE.Object3D: .renderDepth has been removed. Use .renderOrder, instead.")},translate:function(f,E){return console.warn("THREE.Object3D: .translate() has been removed. Use .translateOnAxis( axis, distance ) instead."),this.translateOnAxis(E,f)},getWorldRotation:function(){console.error("THREE.Object3D: .getWorldRotation() has been removed. Use THREE.Object3D.getWorldQuaternion( target ) instead.")},applyMatrix:function(f){return console.warn("THREE.Object3D: .applyMatrix() has been renamed to .applyMatrix4()."),this.applyMatrix4(f)}}),Object.defineProperties(Ri.prototype,{eulerOrder:{get:function(){return console.warn("THREE.Object3D: .eulerOrder is now .rotation.order."),this.rotation.order},set:function(f){console.warn("THREE.Object3D: .eulerOrder is now .rotation.order."),this.rotation.order=f}},useQuaternion:{get:function(){console.warn("THREE.Object3D: .useQuaternion has been removed. The library now uses quaternions by default.")},set:function(){console.warn("THREE.Object3D: .useQuaternion has been removed. The library now uses quaternions by default.")}}}),Object.assign(lu.prototype,{setDrawMode:function(){console.error("THREE.Mesh: .setDrawMode() has been removed. The renderer now always assumes THREE.TrianglesDrawMode. Transform your geometry via BufferGeometryUtils.toTrianglesDrawMode() if necessary.")}}),Object.defineProperties(lu.prototype,{drawMode:{get:function(){return console.error("THREE.Mesh: .drawMode has been removed. The renderer now always assumes THREE.TrianglesDrawMode."),0},set:function(){console.error("THREE.Mesh: .drawMode has been removed. The renderer now always assumes THREE.TrianglesDrawMode. Transform your geometry via BufferGeometryUtils.toTrianglesDrawMode() if necessary.")}}}),Object.defineProperties(yp.prototype,{objects:{get:function(){return console.warn("THREE.LOD: .objects has been renamed to .levels."),this.levels}}}),Object.defineProperty(np.prototype,"useVertexTexture",{get:function(){console.warn("THREE.Skeleton: useVertexTexture has been removed.")},set:function(){console.warn("THREE.Skeleton: useVertexTexture has been removed.")}}),_h.prototype.initBones=function(){console.error("THREE.SkinnedMesh: initBones() has been removed.")},Object.defineProperty(Oa.prototype,"__arcLengthDivisions",{get:function(){return console.warn("THREE.Curve: .__arcLengthDivisions is now .arcLengthDivisions."),this.arcLengthDivisions},set:function(f){console.warn("THREE.Curve: .__arcLengthDivisions is now .arcLengthDivisions."),this.arcLengthDivisions=f}}),cc.prototype.setLens=function(f,E){console.warn("THREE.PerspectiveCamera.setLens is deprecated. Use .setFocalLength and .filmGauge for a photographic setup."),E!==void 0&&(this.filmGauge=E),this.setFocalLength(f)},Object.defineProperties(Eu.prototype,{onlyShadow:{set:function(){console.warn("THREE.Light: .onlyShadow has been removed.")}},shadowCameraFov:{set:function(f){console.warn("THREE.Light: .shadowCameraFov is now .shadow.camera.fov."),this.shadow.camera.fov=f}},shadowCameraLeft:{set:function(f){console.warn("THREE.Light: .shadowCameraLeft is now .shadow.camera.left."),this.shadow.camera.left=f}},shadowCameraRight:{set:function(f){console.warn("THREE.Light: .shadowCameraRight is now .shadow.camera.right."),this.shadow.camera.right=f}},shadowCameraTop:{set:function(f){console.warn("THREE.Light: .shadowCameraTop is now .shadow.camera.top."),this.shadow.camera.top=f}},shadowCameraBottom:{set:function(f){console.warn("THREE.Light: .shadowCameraBottom is now .shadow.camera.bottom."),this.shadow.camera.bottom=f}},shadowCameraNear:{set:function(f){console.warn("THREE.Light: .shadowCameraNear is now .shadow.camera.near."),this.shadow.camera.near=f}},shadowCameraFar:{set:function(f){console.warn("THREE.Light: .shadowCameraFar is now .shadow.camera.far."),this.shadow.camera.far=f}},shadowCameraVisible:{set:function(){console.warn("THREE.Light: .shadowCameraVisible has been removed. Use new THREE.CameraHelper( light.shadow.camera ) instead.")}},shadowBias:{set:function(f){console.warn("THREE.Light: .shadowBias is now .shadow.bias."),this.shadow.bias=f}},shadowDarkness:{set:function(){console.warn("THREE.Light: .shadowDarkness has been removed.")}},shadowMapWidth:{set:function(f){console.warn("THREE.Light: .shadowMapWidth is now .shadow.mapSize.width."),this.shadow.mapSize.width=f}},shadowMapHeight:{set:function(f){console.warn("THREE.Light: .shadowMapHeight is now .shadow.mapSize.height."),this.shadow.mapSize.height=f}}}),Object.defineProperties(ca.prototype,{length:{get:function(){return console.warn("THREE.BufferAttribute: .length has been deprecated. Use .count instead."),this.array.length}},dynamic:{get:function(){return console.warn("THREE.BufferAttribute: .dynamic has been deprecated. Use .usage instead."),this.usage===vu},set:function(){console.warn("THREE.BufferAttribute: .dynamic has been deprecated. Use .usage instead."),this.setUsage(vu)}}}),Object.assign(ca.prototype,{setDynamic:function(f){return console.warn("THREE.BufferAttribute: .setDynamic() has been deprecated. Use .setUsage() instead."),this.setUsage(f===!0?vu:hl),this},copyIndicesArray:function(){console.error("THREE.BufferAttribute: .copyIndicesArray() has been removed.")},setArray:function(){console.error("THREE.BufferAttribute: .setArray has been removed. Use BufferGeometry .setAttribute to replace/resize attribute buffers")}}),Object.assign(Ds.prototype,{addIndex:function(f){console.warn("THREE.BufferGeometry: .addIndex() has been renamed to .setIndex()."),this.setIndex(f)},addAttribute:function(f,E){return console.warn("THREE.BufferGeometry: .addAttribute() has been renamed to .setAttribute()."),E&&E.isBufferAttribute||E&&E.isInterleavedBufferAttribute?f==="index"?(console.warn("THREE.BufferGeometry.addAttribute: Use .setIndex() for index attribute."),this.setIndex(E),this):this.setAttribute(f,E):(console.warn("THREE.BufferGeometry: .addAttribute() now expects ( name, attribute )."),this.setAttribute(f,new ca(E,arguments[2])))},addDrawCall:function(f,E,W){W!==void 0&&console.warn("THREE.BufferGeometry: .addDrawCall() no longer supports indexOffset."),console.warn("THREE.BufferGeometry: .addDrawCall() is now .addGroup()."),this.addGroup(f,E)},clearDrawCalls:function(){console.warn("THREE.BufferGeometry: .clearDrawCalls() is now .clearGroups()."),this.clearGroups()},computeTangents:function(){console.warn("THREE.BufferGeometry: .computeTangents() has been removed.")},computeOffsets:function(){console.warn("THREE.BufferGeometry: .computeOffsets() has been removed.")},removeAttribute:function(f){return console.warn("THREE.BufferGeometry: .removeAttribute() has been renamed to .deleteAttribute()."),this.deleteAttribute(f)},applyMatrix:function(f){return console.warn("THREE.BufferGeometry: .applyMatrix() has been renamed to .applyMatrix4()."),this.applyMatrix4(f)}}),Object.defineProperties(Ds.prototype,{drawcalls:{get:function(){return console.error("THREE.BufferGeometry: .drawcalls has been renamed to .groups."),this.groups}},offsets:{get:function(){return console.warn("THREE.BufferGeometry: .offsets has been renamed to .groups."),this.groups}}}),Object.defineProperties(Vc.prototype,{dynamic:{get:function(){return console.warn("THREE.InterleavedBuffer: .length has been deprecated. Use .usage instead."),this.usage===vu},set:function(f){console.warn("THREE.InterleavedBuffer: .length has been deprecated. Use .usage instead."),this.setUsage(f)}}}),Object.assign(Vc.prototype,{setDynamic:function(f){return console.warn("THREE.InterleavedBuffer: .setDynamic() has been deprecated. Use .setUsage() instead."),this.setUsage(f===!0?vu:hl),this},setArray:function(){console.error("THREE.InterleavedBuffer: .setArray has been removed. Use BufferGeometry .setAttribute to replace/resize attribute buffers")}}),Object.assign(wp.prototype,{getArrays:function(){console.error("THREE.ExtrudeBufferGeometry: .getArrays() has been removed.")},addShapeList:function(){console.error("THREE.ExtrudeBufferGeometry: .addShapeList() has been removed.")},addShape:function(){console.error("THREE.ExtrudeBufferGeometry: .addShape() has been removed.")}}),Object.defineProperties(mg.prototype,{dynamic:{set:function(){console.warn("THREE.Uniform: .dynamic has been removed. Use object.onBeforeRender() instead.")}},onUpdate:{value:function(){return console.warn("THREE.Uniform: .onUpdate() has been removed. Use object.onBeforeRender() instead."),this}}}),Object.defineProperties(ii.prototype,{wrapAround:{get:function(){console.warn("THREE.Material: .wrapAround has been removed.")},set:function(){console.warn("THREE.Material: .wrapAround has been removed.")}},overdraw:{get:function(){console.warn("THREE.Material: .overdraw has been removed.")},set:function(){console.warn("THREE.Material: .overdraw has been removed.")}},wrapRGB:{get:function(){return console.warn("THREE.Material: .wrapRGB has been removed."),new la}},shading:{get:function(){console.error("THREE."+this.type+": .shading has been removed. Use the boolean .flatShading instead.")},set:function(f){console.warn("THREE."+this.type+": .shading has been removed. Use the boolean .flatShading instead."),this.flatShading=f===1}},stencilMask:{get:function(){return console.warn("THREE."+this.type+": .stencilMask has been removed. Use .stencilFuncMask instead."),this.stencilFuncMask},set:function(f){console.warn("THREE."+this.type+": .stencilMask has been removed. Use .stencilFuncMask instead."),this.stencilFuncMask=f}}}),Object.defineProperties(Tp.prototype,{metal:{get:function(){return console.warn("THREE.MeshPhongMaterial: .metal has been removed. Use THREE.MeshStandardMaterial instead."),!1},set:function(){console.warn("THREE.MeshPhongMaterial: .metal has been removed. Use THREE.MeshStandardMaterial instead")}}}),Object.defineProperties(Ld.prototype,{derivatives:{get:function(){return console.warn("THREE.ShaderMaterial: .derivatives has been moved to .extensions.derivatives."),this.extensions.derivatives},set:function(f){console.warn("THREE. ShaderMaterial: .derivatives has been moved to .extensions.derivatives."),this.extensions.derivatives=f}}}),Object.assign(Yu.prototype,{clearTarget:function(f,E,W,ge){console.warn("THREE.WebGLRenderer: .clearTarget() has been deprecated. Use .setRenderTarget() and .clear() instead."),this.setRenderTarget(f),this.clear(E,W,ge)},animate:function(f){console.warn("THREE.WebGLRenderer: .animate() is now .setAnimationLoop()."),this.setAnimationLoop(f)},getCurrentRenderTarget:function(){return console.warn("THREE.WebGLRenderer: .getCurrentRenderTarget() is now .getRenderTarget()."),this.getRenderTarget()},getMaxAnisotropy:function(){return console.warn("THREE.WebGLRenderer: .getMaxAnisotropy() is now .capabilities.getMaxAnisotropy()."),this.capabilities.getMaxAnisotropy()},getPrecision:function(){return console.warn("THREE.WebGLRenderer: .getPrecision() is now .capabilities.precision."),this.capabilities.precision},resetGLState:function(){return console.warn("THREE.WebGLRenderer: .resetGLState() is now .state.reset()."),this.state.reset()},supportsFloatTextures:function(){return console.warn("THREE.WebGLRenderer: .supportsFloatTextures() is now .extensions.get( 'OES_texture_float' )."),this.extensions.get("OES_texture_float")},supportsHalfFloatTextures:function(){return console.warn("THREE.WebGLRenderer: .supportsHalfFloatTextures() is now .extensions.get( 'OES_texture_half_float' )."),this.extensions.get("OES_texture_half_float")},supportsStandardDerivatives:function(){return console.warn("THREE.WebGLRenderer: .supportsStandardDerivatives() is now .extensions.get( 'OES_standard_derivatives' )."),this.extensions.get("OES_standard_derivatives")},supportsCompressedTextureS3TC:function(){return console.warn("THREE.WebGLRenderer: .supportsCompressedTextureS3TC() is now .extensions.get( 'WEBGL_compressed_texture_s3tc' )."),this.extensions.get("WEBGL_compressed_texture_s3tc")},supportsCompressedTexturePVRTC:function(){return console.warn("THREE.WebGLRenderer: .supportsCompressedTexturePVRTC() is now .extensions.get( 'WEBGL_compressed_texture_pvrtc' )."),this.extensions.get("WEBGL_compressed_texture_pvrtc")},supportsBlendMinMax:function(){return console.warn("THREE.WebGLRenderer: .supportsBlendMinMax() is now .extensions.get( 'EXT_blend_minmax' )."),this.extensions.get("EXT_blend_minmax")},supportsVertexTextures:function(){return console.warn("THREE.WebGLRenderer: .supportsVertexTextures() is now .capabilities.vertexTextures."),this.capabilities.vertexTextures},supportsInstancedArrays:function(){return console.warn("THREE.WebGLRenderer: .supportsInstancedArrays() is now .extensions.get( 'ANGLE_instanced_arrays' )."),this.extensions.get("ANGLE_instanced_arrays")},enableScissorTest:function(f){console.warn("THREE.WebGLRenderer: .enableScissorTest() is now .setScissorTest()."),this.setScissorTest(f)},initMaterial:function(){console.warn("THREE.WebGLRenderer: .initMaterial() has been removed.")},addPrePlugin:function(){console.warn("THREE.WebGLRenderer: .addPrePlugin() has been removed.")},addPostPlugin:function(){console.warn("THREE.WebGLRenderer: .addPostPlugin() has been removed.")},updateShadowMap:function(){console.warn("THREE.WebGLRenderer: .updateShadowMap() has been removed.")},setFaceCulling:function(){console.warn("THREE.WebGLRenderer: .setFaceCulling() has been removed.")},allocTextureUnit:function(){console.warn("THREE.WebGLRenderer: .allocTextureUnit() has been removed.")},setTexture:function(){console.warn("THREE.WebGLRenderer: .setTexture() has been removed.")},setTexture2D:function(){console.warn("THREE.WebGLRenderer: .setTexture2D() has been removed.")},setTextureCube:function(){console.warn("THREE.WebGLRenderer: .setTextureCube() has been removed.")},getActiveMipMapLevel:function(){return console.warn("THREE.WebGLRenderer: .getActiveMipMapLevel() is now .getActiveMipmapLevel()."),this.getActiveMipmapLevel()}}),Object.defineProperties(Yu.prototype,{shadowMapEnabled:{get:function(){return this.shadowMap.enabled},set:function(f){console.warn("THREE.WebGLRenderer: .shadowMapEnabled is now .shadowMap.enabled."),this.shadowMap.enabled=f}},shadowMapType:{get:function(){return this.shadowMap.type},set:function(f){console.warn("THREE.WebGLRenderer: .shadowMapType is now .shadowMap.type."),this.shadowMap.type=f}},shadowMapCullFace:{get:function(){console.warn("THREE.WebGLRenderer: .shadowMapCullFace has been removed. Set Material.shadowSide instead.")},set:function(){console.warn("THREE.WebGLRenderer: .shadowMapCullFace has been removed. Set Material.shadowSide instead.")}},context:{get:function(){return console.warn("THREE.WebGLRenderer: .context has been removed. Use .getContext() instead."),this.getContext()}},vr:{get:function(){return console.warn("THREE.WebGLRenderer: .vr has been renamed to .xr"),this.xr}},gammaInput:{get:function(){return console.warn("THREE.WebGLRenderer: .gammaInput has been removed. Set the encoding for textures via Texture.encoding instead."),!1},set:function(){console.warn("THREE.WebGLRenderer: .gammaInput has been removed. Set the encoding for textures via Texture.encoding instead.")}},gammaOutput:{get:function(){return console.warn("THREE.WebGLRenderer: .gammaOutput has been removed. Set WebGLRenderer.outputEncoding instead."),!1},set:function(f){console.warn("THREE.WebGLRenderer: .gammaOutput has been removed. Set WebGLRenderer.outputEncoding instead."),this.outputEncoding=f===!0?ga:qi}}}),Object.defineProperties(yh.prototype,{cullFace:{get:function(){console.warn("THREE.WebGLRenderer: .shadowMap.cullFace has been removed. Set Material.shadowSide instead.")},set:function(){console.warn("THREE.WebGLRenderer: .shadowMap.cullFace has been removed. Set Material.shadowSide instead.")}},renderReverseSided:{get:function(){console.warn("THREE.WebGLRenderer: .shadowMap.renderReverseSided has been removed. Set Material.shadowSide instead.")},set:function(){console.warn("THREE.WebGLRenderer: .shadowMap.renderReverseSided has been removed. Set Material.shadowSide instead.")}},renderSingleSided:{get:function(){console.warn("THREE.WebGLRenderer: .shadowMap.renderSingleSided has been removed. Set Material.shadowSide instead.")},set:function(){console.warn("THREE.WebGLRenderer: .shadowMap.renderSingleSided has been removed. Set Material.shadowSide instead.")}}}),Object.defineProperties(Au.prototype,{wrapS:{get:function(){return console.warn("THREE.WebGLRenderTarget: .wrapS is now .texture.wrapS."),this.texture.wrapS},set:function(f){console.warn("THREE.WebGLRenderTarget: .wrapS is now .texture.wrapS."),this.texture.wrapS=f}},wrapT:{get:function(){return console.warn("THREE.WebGLRenderTarget: .wrapT is now .texture.wrapT."),this.texture.wrapT},set:function(f){console.warn("THREE.WebGLRenderTarget: .wrapT is now .texture.wrapT."),this.texture.wrapT=f}},magFilter:{get:function(){return console.warn("THREE.WebGLRenderTarget: .magFilter is now .texture.magFilter."),this.texture.magFilter},set:function(f){console.warn("THREE.WebGLRenderTarget: .magFilter is now .texture.magFilter."),this.texture.magFilter=f}},minFilter:{get:function(){return console.warn("THREE.WebGLRenderTarget: .minFilter is now .texture.minFilter."),this.texture.minFilter},set:function(f){console.warn("THREE.WebGLRenderTarget: .minFilter is now .texture.minFilter."),this.texture.minFilter=f}},anisotropy:{get:function(){return console.warn("THREE.WebGLRenderTarget: .anisotropy is now .texture.anisotropy."),this.texture.anisotropy},set:function(f){console.warn("THREE.WebGLRenderTarget: .anisotropy is now .texture.anisotropy."),this.texture.anisotropy=f}},offset:{get:function(){return console.warn("THREE.WebGLRenderTarget: .offset is now .texture.offset."),this.texture.offset},set:function(f){console.warn("THREE.WebGLRenderTarget: .offset is now .texture.offset."),this.texture.offset=f}},repeat:{get:function(){return console.warn("THREE.WebGLRenderTarget: .repeat is now .texture.repeat."),this.texture.repeat},set:function(f){console.warn("THREE.WebGLRenderTarget: .repeat is now .texture.repeat."),this.texture.repeat=f}},format:{get:function(){return console.warn("THREE.WebGLRenderTarget: .format is now .texture.format."),this.texture.format},set:function(f){console.warn("THREE.WebGLRenderTarget: .format is now .texture.format."),this.texture.format=f}},type:{get:function(){return console.warn("THREE.WebGLRenderTarget: .type is now .texture.type."),this.texture.type},set:function(f){console.warn("THREE.WebGLRenderTarget: .type is now .texture.type."),this.texture.type=f}},generateMipmaps:{get:function(){return console.warn("THREE.WebGLRenderTarget: .generateMipmaps is now .texture.generateMipmaps."),this.texture.generateMipmaps},set:function(f){console.warn("THREE.WebGLRenderTarget: .generateMipmaps is now .texture.generateMipmaps."),this.texture.generateMipmaps=f}}}),Object.defineProperties(e3.prototype,{load:{value:function(f){console.warn("THREE.Audio: .load has been deprecated. Use THREE.AudioLoader instead.");var E=this;return new cg().load(f,function(W){E.setBuffer(W)}),this}},startTime:{set:function(){console.warn("THREE.Audio: .startTime is now .play( delay ).")}}}),fg.prototype.getData=function(){return console.warn("THREE.AudioAnalyser: .getData() is now .getFrequencyData()."),this.getFrequencyData()},Jh.prototype.updateCubeMap=function(f,E){return console.warn("THREE.CubeCamera: .updateCubeMap() is now .update()."),this.update(f,E)};var _0={merge:function(f,E,W){var ge;console.warn("THREE.GeometryUtils: .merge() has been moved to Geometry. Use geometry.merge( geometry2, matrix, materialIndexOffset ) instead."),E.isMesh&&(E.matrixAutoUpdate&&E.updateMatrix(),ge=E.matrix,E=E.geometry),f.merge(E,ge,W)},center:function(f){return console.warn("THREE.GeometryUtils: .center() has been moved to Geometry. Use geometry.center() instead."),f.center()}};Gc.crossOrigin=void 0,Gc.loadTexture=function(f,E,W,ge){console.warn("THREE.ImageUtils.loadTexture has been deprecated. Use THREE.TextureLoader() instead.");var ct=new La;ct.setCrossOrigin(this.crossOrigin);var gt=ct.load(f,W,void 0,ge);return E&&(gt.mapping=E),gt},Gc.loadTextureCube=function(f,E,W,ge){console.warn("THREE.ImageUtils.loadTextureCube has been deprecated. Use THREE.CubeTextureLoader() instead.");var ct=new Ca;ct.setCrossOrigin(this.crossOrigin);var gt=ct.load(f,W,void 0,ge);return E&&(gt.mapping=E),gt},Gc.loadCompressedTexture=function(){console.error("THREE.ImageUtils.loadCompressedTexture has been removed. Use THREE.DDSLoader instead.")},Gc.loadCompressedTextureCube=function(){console.error("THREE.ImageUtils.loadCompressedTextureCube has been removed. Use THREE.DDSLoader instead.")};var E0={createMultiMaterialObject:function(){console.error("THREE.SceneUtils has been moved to /examples/js/utils/SceneUtils.js")},detach:function(){console.error("THREE.SceneUtils has been moved to /examples/js/utils/SceneUtils.js")},attach:function(){console.error("THREE.SceneUtils has been moved to /examples/js/utils/SceneUtils.js")}};typeof __THREE_DEVTOOLS__<"u"&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("register",{detail:{revision:"113"}})),c.ACESFilmicToneMapping=qn,c.AddEquation=Ae,c.AddOperation=Kn,c.AdditiveBlending=Ue,c.AlphaFormat=Ao,c.AlwaysDepth=Lt,c.AlwaysStencilFunc=Bu,c.AmbientLight=tg,c.AmbientLightProbe=Ad,c.AnimationClip=jh,c.AnimationLoader=Fn,c.AnimationMixer=Ug,c.AnimationObjectGroup=t3,c.AnimationUtils=Nc,c.ArcCurve=Ho,c.ArrayCamera=tu,c.ArrowHelper=r3,c.Audio=e3,c.AudioAnalyser=fg,c.AudioContext=Vg,c.AudioListener=zg,c.AudioLoader=cg,c.AxesHelper=Dg,c.AxisHelper=function(f){return console.warn("THREE.AxisHelper has been renamed to THREE.AxesHelper."),new Dg(f)},c.BackSide=q,c.BasicDepthPacking=Bl,c.BasicShadowMap=0,c.BinaryTextureLoader=function(f){return console.warn("THREE.BinaryTextureLoader has been renamed to THREE.DataTextureLoader."),new mi(f)},c.Bone=Up,c.BooleanKeyframeTrack=mf,c.BoundingBoxHelper=function(f,E){return console.warn("THREE.BoundingBoxHelper has been deprecated. Creating a THREE.BoxHelper instead."),new Mm(f,E)},c.Box2=V3,c.Box3=Xu,c.Box3Helper=v3,c.BoxBufferGeometry=Zo,c.BoxGeometry=dp,c.BoxHelper=Mm,c.BufferAttribute=ca,c.BufferGeometry=Ds,c.BufferGeometryLoader=ag,c.ByteType=Pi,c.Cache=zf,c.Camera=Gd,c.CameraHelper=Sg,c.CanvasRenderer=function(){console.error("THREE.CanvasRenderer has been removed")},c.CanvasTexture=Nm,c.CatmullRomCurve3=Qs,c.CineonToneMapping=Si,c.CircleBufferGeometry=hm,c.CircleGeometry=d3,c.ClampToEdgeWrapping=Nn,c.Clock=_m,c.ClosedSplineCurve3=Rg,c.Color=la,c.ColorKeyframeTrack=p3,c.CompressedTexture=nm,c.CompressedTextureLoader=Qn,c.ConeBufferGeometry=Ym,c.ConeGeometry=qd,c.CubeCamera=Jh,c.CubeGeometry=dp,c.CubeReflectionMapping=ia,c.CubeRefractionMapping=Wi,c.CubeTexture=ep,c.CubeTextureLoader=Ca,c.CubeUVReflectionMapping=fi,c.CubeUVRefractionMapping=An,c.CubicBezierCurve=au,c.CubicBezierCurve3=sl,c.CubicInterpolant=h3,c.CullFaceBack=b,c.CullFaceFront=m,c.CullFaceFrontBack=3,c.CullFaceNone=y,c.Curve=Oa,c.CurvePath=Ed,c.CustomBlending=rt,c.CylinderBufferGeometry=Cp,c.CylinderGeometry=pf,c.Cylindrical=g3,c.DataTexture=pp,c.DataTexture2DArray=Df,c.DataTexture3D=xd,c.DataTextureLoader=mi,c.DecrementStencilOp=7683,c.DecrementWrapStencilOp=34056,c.DefaultLoadingManager=eg,c.DepthFormat=ni,c.DepthStencilFormat=Ei,c.DepthTexture=rm,c.DirectionalLight=op,c.DirectionalLightHelper=H3,c.DirectionalLightShadow=vf,c.DiscreteInterpolant=Km,c.DodecahedronBufferGeometry=wh,c.DodecahedronGeometry=hf,c.DoubleSide=J,c.DstAlphaFactor=tn,c.DstColorFactor=_n,c.DynamicBufferAttribute=function(f,E){return console.warn("THREE.DynamicBufferAttribute has been removed. Use new THREE.BufferAttribute().setUsage( THREE.DynamicDrawUsage ) instead."),new ca(f,E).setUsage(vu)},c.DynamicCopyUsage=35050,c.DynamicDrawUsage=vu,c.DynamicReadUsage=35049,c.EdgesGeometry=Bf,c.EdgesHelper=function(f,E){return console.warn("THREE.EdgesHelper has been removed. Use THREE.EdgesGeometry instead."),new xc(new Bf(f.geometry),new Pc({color:E!==void 0?E:16777215}))},c.EllipseCurve=fo,c.EqualDepth=xn,c.EqualStencilFunc=514,c.EquirectangularReflectionMapping=ha,c.EquirectangularRefractionMapping=ai,c.Euler=wt,c.EventDispatcher=Ku,c.ExtrudeBufferGeometry=wp,c.ExtrudeGeometry=Yp,c.Face3=Xo,c.Face4=function(f,E,W,ge,ct,gt,St){return console.warn("THREE.Face4 has been removed. A THREE.Face3 will be created instead."),new Xo(f,E,W,ct,gt,St)},c.FaceColors=1,c.FileLoader=on,c.FlatShading=1,c.Float32Attribute=function(f,E){return console.warn("THREE.Float32Attribute has been removed. Use new THREE.Float32BufferAttribute() instead."),new io(f,E)},c.Float32BufferAttribute=io,c.Float64Attribute=function(f,E){return console.warn("THREE.Float64Attribute has been removed. Use new THREE.Float64BufferAttribute() instead."),new Fo(f,E)},c.Float64BufferAttribute=Fo,c.FloatType=Aa,c.Fog=$d,c.FogExp2=Tc,c.Font=ug,c.FontLoader=Bg,c.FrontFaceDirectionCCW=1,c.FrontFaceDirectionCW=0,c.FrontSide=G,c.Frustum=Ih,c.GammaEncoding=no,c.Geometry=ul,c.GeometryUtils=_0,c.GreaterDepth=Xr,c.GreaterEqualDepth=$n,c.GreaterEqualStencilFunc=518,c.GreaterStencilFunc=516,c.GridHelper=$3,c.Group=tc,c.HalfFloatType=Ja,c.HemisphereLight=Xm,c.HemisphereLightHelper=U3,c.HemisphereLightProbe=Ng,c.IcosahedronBufferGeometry=zm,c.IcosahedronGeometry=zh,c.ImageBitmapLoader=Fg,c.ImageLoader=ra,c.ImageUtils=Gc,c.ImmediateRenderObject=bg,c.IncrementStencilOp=7682,c.IncrementWrapStencilOp=34055,c.InstancedBufferAttribute=ig,c.InstancedBufferGeometry=O3,c.InstancedInterleavedBuffer=$g,c.InstancedMesh=Vm,c.Int16Attribute=function(f,E){return console.warn("THREE.Int16Attribute has been removed. Use new THREE.Int16BufferAttribute() instead."),new Io(f,E)},c.Int16BufferAttribute=Io,c.Int32Attribute=function(f,E){return console.warn("THREE.Int32Attribute has been removed. Use new THREE.Int32BufferAttribute() instead."),new gr(f,E)},c.Int32BufferAttribute=gr,c.Int8Attribute=function(f,E){return console.warn("THREE.Int8Attribute has been removed. Use new THREE.Int8BufferAttribute() instead."),new uo(f,E)},c.Int8BufferAttribute=uo,c.IntType=za,c.InterleavedBuffer=Vc,c.InterleavedBufferAttribute=jp,c.Interpolant=Td,c.InterpolateDiscrete=al,c.InterpolateLinear=Mn,c.InterpolateSmooth=2302,c.InvertStencilOp=5386,c.JSONLoader=function(){console.error("THREE.JSONLoader has been removed.")},c.KeepStencilOp=bu,c.KeyframeTrack=Rc,c.LOD=yp,c.LatheBufferGeometry=cm,c.LatheGeometry=Mp,c.Layers=qt,c.LensFlare=function(){console.error("THREE.LensFlare has been moved to /examples/js/objects/Lensflare.js")},c.LessDepth=wn,c.LessEqualDepth=hn,c.LessEqualStencilFunc=515,c.LessStencilFunc=513,c.Light=Eu,c.LightProbe=Ep,c.LightShadow=Vd,c.Line=Hc,c.Line3=xg,c.LineBasicMaterial=Pc,c.LineCurve=cl,c.LineCurve3=wc,c.LineDashedMaterial=Zm,c.LineLoop=Pf,c.LinePieces=1,c.LineSegments=xc,c.LineStrip=0,c.LinearEncoding=qi,c.LinearFilter=hi,c.LinearInterpolant=ff,c.LinearMipMapLinearFilter=1008,c.LinearMipMapNearestFilter=1007,c.LinearMipmapLinearFilter=Ra,c.LinearMipmapNearestFilter=bi,c.LinearToneMapping=Yn,c.Loader=Ze,c.LoaderUtils=rg,c.LoadingManager=yf,c.LogLuvEncoding=Go,c.LoopOnce=2200,c.LoopPingPong=2202,c.LoopRepeat=2201,c.LuminanceAlphaFormat=Un,c.LuminanceFormat=zn,c.MOUSE={LEFT:0,MIDDLE:1,RIGHT:2,ROTATE:0,DOLLY:1,PAN:2},c.Material=ii,c.MaterialLoader=vm,c.Math=js,c.MathUtils=js,c.Matrix3=Vl,c.Matrix4=Vo,c.MaxEquation=ue,c.Mesh=lu,c.MeshBasicMaterial=Ma,c.MeshDepthMaterial=_c,c.MeshDistanceMaterial=Bc,c.MeshFaceMaterial=function(f){return console.warn("THREE.MeshFaceMaterial has been removed. Use an Array instead."),f},c.MeshLambertMaterial=Sd,c.MeshMatcapMaterial=Xp,c.MeshNormalMaterial=Cd,c.MeshPhongMaterial=Tp,c.MeshPhysicalMaterial=pm,c.MeshStandardMaterial=Sp,c.MeshToonMaterial=Th,c.MinEquation=ie,c.MirroredRepeatWrapping=fn,c.MixOperation=Xn,c.MultiMaterial=function(f){return f===void 0&&(f=[]),console.warn("THREE.MultiMaterial has been removed. Use an Array instead."),f.isMultiMaterial=!0,(f.materials=f).clone=function(){return f.slice()},f},c.MultiplyBlending=Ve,c.MultiplyOperation=gn,c.NearestFilter=un,c.NearestMipMapLinearFilter=1005,c.NearestMipMapNearestFilter=1004,c.NearestMipmapLinearFilter=hr,c.NearestMipmapNearestFilter=Ln,c.NeverDepth=Rn,c.NeverStencilFunc=512,c.NoBlending=ve,c.NoColors=fe,c.NoToneMapping=Vn,c.NormalBlending=ne,c.NotEqualDepth=ti,c.NotEqualStencilFunc=517,c.NumberKeyframeTrack=gf,c.Object3D=Ri,c.ObjectLoader=og,c.ObjectSpaceNormalMap=Ol,c.OctahedronBufferGeometry=Dc,c.OctahedronGeometry=Md,c.OneFactor=mt,c.OneMinusDstAlphaFactor=pn,c.OneMinusDstColorFactor=Dn,c.OneMinusSrcAlphaFactor=nn,c.OneMinusSrcColorFactor=kt,c.OrthographicCamera=ap,c.PCFShadowMap=O,c.PCFSoftShadowMap=N,c.PMREMGenerator=Yg,c.ParametricBufferGeometry=bh,c.ParametricGeometry=dh,c.Particle=function(f){return console.warn("THREE.Particle has been renamed to THREE.Sprite."),new Lm(f)},c.ParticleBasicMaterial=function(f){return console.warn("THREE.ParticleBasicMaterial has been renamed to THREE.PointsMaterial."),new ch(f)},c.ParticleSystem=function(f,E){return console.warn("THREE.ParticleSystem has been renamed to THREE.Points."),new If(f,E)},c.ParticleSystemMaterial=function(f){return console.warn("THREE.ParticleSystemMaterial has been renamed to THREE.PointsMaterial."),new ch(f)},c.Path=md,c.PerspectiveCamera=cc,c.Plane=wu,c.PlaneBufferGeometry=Qh,c.PlaneGeometry=Bp,c.PlaneHelper=Tg,c.PointCloud=function(f,E){return console.warn("THREE.PointCloud has been renamed to THREE.Points."),new If(f,E)},c.PointCloudMaterial=function(f){return console.warn("THREE.PointCloudMaterial has been renamed to THREE.PointsMaterial."),new ch(f)},c.PointLight=ip,c.PointLightHelper=wg,c.Points=If,c.PointsMaterial=ch,c.PolarGridHelper=Mg,c.PolyhedronBufferGeometry=Yc,c.PolyhedronGeometry=vp,c.PositionalAudio=pg,c.PropertyBinding=Nd,c.PropertyMixer=Qp,c.QuadraticBezierCurve=nc,c.QuadraticBezierCurve3=Wc,c.Quaternion=Wu,c.QuaternionKeyframeTrack=Nf,c.QuaternionLinearInterpolant=fm,c.REVISION="113",c.RGBADepthPacking=Jl,c.RGBAFormat=zr,c.RGBAIntegerFormat=wo,c.RGBA_ASTC_10x10_Format=tl,c.RGBA_ASTC_10x5_Format=jo,c.RGBA_ASTC_10x6_Format=ju,c.RGBA_ASTC_10x8_Format=Pl,c.RGBA_ASTC_12x10_Format=zl,c.RGBA_ASTC_12x12_Format=Is,c.RGBA_ASTC_4x4_Format=qo,c.RGBA_ASTC_5x4_Format=wl,c.RGBA_ASTC_5x5_Format=yu,c.RGBA_ASTC_6x5_Format=po,c.RGBA_ASTC_6x6_Format=Zs,c.RGBA_ASTC_8x5_Format=Es,c.RGBA_ASTC_8x6_Format=Xl,c.RGBA_ASTC_8x8_Format=xl,c.RGBA_PVRTC_2BPPV1_Format=ao,c.RGBA_PVRTC_4BPPV1_Format=$s,c.RGBA_S3TC_DXT1_Format=zo,c.RGBA_S3TC_DXT3_Format=Po,c.RGBA_S3TC_DXT5_Format=Lo,c.RGBDEncoding=jl,c.RGBEEncoding=mo,c.RGBEFormat=Gr,c.RGBFormat=il,c.RGBIntegerFormat=Ea,c.RGBM16Encoding=Ns,c.RGBM7Encoding=Uo,c.RGB_ETC1_Format=Ps,c.RGB_PVRTC_2BPPV1_Format=ma,c.RGB_PVRTC_4BPPV1_Format=Wo,c.RGB_S3TC_DXT1_Format=to,c.RGFormat=Hi,c.RGIntegerFormat=Ai,c.RawShaderMaterial=Kp,c.Ray=Hl,c.Raycaster=gg,c.RectAreaLight=ng,c.RedFormat=$t,c.RedIntegerFormat=ta,c.ReinhardToneMapping=Vr,c.RepeatWrapping=sa,c.ReplaceStencilOp=7681,c.ReverseSubtractEquation=Xe,c.RingBufferGeometry=Zp,c.RingGeometry=qm,c.Scene=fa,c.SceneUtils=E0,c.ShaderChunk=ql,c.ShaderLib=Xd,c.ShaderMaterial=Ld,c.ShadowMaterial=Vf,c.Shape=th,c.ShapeBufferGeometry=Qd,c.ShapeGeometry=dm,c.ShapePath=lg,c.ShapeUtils=bp,c.ShortType=oi,c.Skeleton=np,c.SkeletonHelper=G3,c.SkinnedMesh=_h,c.SmoothShading=2,c.Sphere=Nl,c.SphereBufferGeometry=Sh,c.SphereGeometry=Wm,c.Spherical=Gh,c.SphericalHarmonics3=dg,c.SphericalReflectionMapping=Ia,c.Spline=Xg,c.SplineCurve=pu,c.SplineCurve3=v0,c.SpotLight=gm,c.SpotLightHelper=z3,c.SpotLightShadow=Dp,c.Sprite=Lm,c.SpriteMaterial=uh,c.SrcAlphaFactor=It,c.SrcAlphaSaturateFactor=an,c.SrcColorFactor=Tt,c.StaticCopyUsage=35046,c.StaticDrawUsage=hl,c.StaticReadUsage=35045,c.StereoCamera=F3,c.StreamCopyUsage=35042,c.StreamDrawUsage=35040,c.StreamReadUsage=35041,c.StringKeyframeTrack=f3,c.SubtractEquation=Te,c.SubtractiveBlending=De,c.TOUCH={ROTATE:0,PAN:1,DOLLY_PAN:2,DOLLY_ROTATE:3},c.TangentSpaceNormalMap=mu,c.TetrahedronBufferGeometry=Rf,c.TetrahedronGeometry=kl,c.TextBufferGeometry=Zc,c.TextGeometry=Ic,c.Texture=Ql,c.TextureLoader=La,c.TorusBufferGeometry=om,c.TorusGeometry=am,c.TorusKnotBufferGeometry=$u,c.TorusKnotGeometry=bc,c.Triangle=qu,c.TriangleFanDrawMode=2,c.TriangleStripDrawMode=1,c.TrianglesDrawMode=0,c.TubeBufferGeometry=qp,c.TubeGeometry=Of,c.UVMapping=300,c.Uint16Attribute=function(f,E){return console.warn("THREE.Uint16Attribute has been removed. Use new THREE.Uint16BufferAttribute() instead."),new Ws(f,E)},c.Uint16BufferAttribute=Ws,c.Uint32Attribute=function(f,E){return console.warn("THREE.Uint32Attribute has been removed. Use new THREE.Uint32BufferAttribute() instead."),new ws(f,E)},c.Uint32BufferAttribute=ws,c.Uint8Attribute=function(f,E){return console.warn("THREE.Uint8Attribute has been removed. Use new THREE.Uint8BufferAttribute() instead."),new ya(f,E)},c.Uint8BufferAttribute=ya,c.Uint8ClampedAttribute=function(f,E){return console.warn("THREE.Uint8ClampedAttribute has been removed. Use new THREE.Uint8ClampedBufferAttribute() instead."),new Oo(f,E)},c.Uint8ClampedBufferAttribute=Oo,c.Uncharted2ToneMapping=xi,c.Uniform=mg,c.UniformsLib=Ts,c.UniformsUtils=Fp,c.UnsignedByteType=so,c.UnsignedInt248Type=_o,c.UnsignedIntType=ki,c.UnsignedShort4444Type=yo,c.UnsignedShort5551Type=ls,c.UnsignedShort565Type=xo,c.UnsignedShortType=Ni,c.VSMShadowMap=L,c.Vector2=co,c.Vector3=yi,c.Vector4=Ll,c.VectorKeyframeTrack=mm,c.Vertex=function(f,E,W){return console.warn("THREE.Vertex has been removed. Use THREE.Vector3 instead."),new yi(f,E,W)},c.VertexColors=2,c.VideoTexture=Wp,c.WebGLCubeRenderTarget=hp,c.WebGLMultisampleRenderTarget=jd,c.WebGLRenderTarget=Au,c.WebGLRenderTargetCube=function(f,E,W){return console.warn("THREE.WebGLRenderTargetCube( width, height, options ) is now WebGLCubeRenderTarget( size, options )."),new hp(f,W)},c.WebGLRenderer=Yu,c.WebGLUtils=Uu,c.WireframeGeometry=im,c.WireframeHelper=function(f,E){return console.warn("THREE.WireframeHelper has been removed. Use THREE.WireframeGeometry instead."),new xc(new im(f.geometry),new Pc({color:E!==void 0?E:16777215}))},c.WrapAroundEnding=Qr,c.XHRLoader=function(f){return console.warn("THREE.XHRLoader has been renamed to THREE.FileLoader."),new on(f)},c.ZeroCurvatureEnding=Ur,c.ZeroFactor=pt,c.ZeroSlopeEnding=Gn,c.ZeroStencilOp=0,c.sRGBEncoding=ga,Object.defineProperty(c,"__esModule",{value:!0})},u(typeof l=="object"&&e!==void 0?l:(n=n||self).THREE={})},{}],20:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MrxDbgUtils=void 0;var n,u=t("three"),c=t("./Operate/MxEntSelJig"),y=t("./Operate/MxJigCmdManager"),b=t("./UI/MxUiVue"),m=t("./Operate/MrxDbgUiPrPoint"),O=t("./Operate/MrxDbgUiPrBase"),N=t("./MxThreeJS");(n=l.MrxDbgUtils||(l.MrxDbgUtils={})).findEntAtPoint=function(L,G,q,J,fe){return q===void 0&&(q=null),J===void 0&&(J=!0),new Promise(function(ve){for(var ne=L.findMxEntityAtPoint(G,J,fe),Ue=[],De=ne.length,Ve=0;Ve<De;Ve++){var rt=ne[Ve];if(!q||!q.type||q.type==rt.getTypeName()){var Ae=rt.objectId();Ue.push(Ae)}}ve(Ue)})},n.selectEnt=function(L,G){return G===void 0&&(G=null),new Promise(function(q){var J=new c.MxEntSelJig;J.disableAllTrace(),J.setDynamicInputType(y.MxJigCmdManager.DynamicInputType.kDynTip),L&&b.MxUiVue.acutPrintf(L),J.filter=G,J.callRet=function(fe){q(fe)},y.MxJigCmdManager.runCmd(J)})},n.getCorner=function(L,G,q,J,fe){return q===void 0&&(q=!1),fe===void 0&&(fe=!1),new Promise(function(ve){var ne=new m.MrxDbgUiPrPoint;ne.setMessage(G),q?(ne.setDynamicInputType(y.MxJigCmdManager.DynamicInputType.kDynTip),ne.disableAllTrace()):(ne.setDynamicInputType(y.MxJigCmdManager.DynamicInputType.kXYCoordInput),fe&&ne.disableAllTrace());var Ue=new O.McEdGetPointWorldDrawObject;Ue.setDraw(function(De,Ve){var rt=new u.Vector3(L.x,De.y,De.z),Ae=new u.Vector3(De.x,L.y,De.z),Te=[];Te.push(L),Te.push(rt),Te.push(De),Te.push(Ae),Te.push(L);var Xe=null,ie=65280;if(q){if(De.x>L.x)Xe=N.MxThreeJS.createLines(Te,16777215),ie=255;else{var ue=Ve.getMcEdJig().getMxObject().viewCoordLong2Cad(3);Xe=N.MxThreeJS.createDashedLines(Te,16777215,2*ue,ue)}var pt=[];pt.push(L),pt.push(rt),pt.push(De),pt.push(L),pt.push(De),pt.push(Ae);var mt=N.MxThreeJS.createTriangle(pt,ie,.27);Ve.drawEntity(mt,30),Ve.drawEntity(Xe,31)}else Xe=N.MxThreeJS.createLines(Te,16777215),Ve.drawEntity(Xe,31)}),ne.setUserDraw(Ue),ne.go(function(De){J&&J({status:De,detailedResult:ne.getDetailedResult()}),De!=0?ve(null):(ne.clearLastInputPoint(),ve(ne.value()))})})}},{"./MxThreeJS":37,"./Operate/MrxDbgUiPrBase":45,"./Operate/MrxDbgUiPrPoint":47,"./Operate/MxEntSelJig":50,"./Operate/MxJigCmdManager":54,"./UI/MxUiVue":65,three:19}],21:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxDrawCommands=void 0;var n=t("./MxFun"),u=t("./MxType"),c=t("./Operate/MxIntelliSelect"),y=t("./Operate/MxJigCmdManager");function b(q){q!=null&&q.grips!=null&&q.ids!=null&&n.MxFun.getCurrentMx().getMcObject().getGripManager().gripEditImp(q)}function m(q){if(q!=null&&q.pt!=null){var J=n.MxFun.getCurrentMx(),fe=q.pt;if(!J.getMxDatabase().getGripManager().doPointSelect(fe)){var ve=!0;if(J.isValidMcObject()&&J.getMcObject().getGripManager().doPointSelect(fe)&&(ve=!1),n.MxFun.isPC()||(ve=!1),ve&&J.isMultipleSelect){var ne=J.screenCoord2Current(fe.x,fe.y,0),Ue=new c.MxIntelliSelectJig(ne);Ue.setDisableDynInput(!0),Ue.setDisableOsnap(!0),y.MxJigCmdManager.runCmd(Ue)}}}}function O(q){q!=null&&q.grips!=null&&q.ents!=null&&n.MxFun.getCurrentMx().getMxDatabase().getGripManager().gripEditImp(q)}function N(){n.MxFun.getCurrentMx().getMcObject().undo()}function L(){n.MxFun.getCurrentMx().getMcObject().redo()}function G(){n.MxFun.getCurrentMx().startPanCommand()}(l.MxDrawCommands||(l.MxDrawCommands={})).registerCommand=function(){n.MxFun.addCommand("Mx_FrontEndWebpageIntelliSel",m,u.MxType.MxCommandFlag.MCRX_CMD_TRANSPARENT|u.MxType.MxCommandFlag.MCRX_CMD_NO_UNDO_MARKER|u.MxType.MxCommandFlag.MCRX_CMD_NO_CLEAR_SELECT|u.MxType.MxCommandFlag.MCRX_CMD_NO_RECORD_PRVCMD),n.MxFun.addCommand("Mx_FrontEndWebpageGripEdit",O,u.MxType.MxCommandFlag.MCRX_CMD_TRANSPARENT|u.MxType.MxCommandFlag.MCRX_CMD_NO_UNDO_MARKER|u.MxType.MxCommandFlag.MCRX_CMD_NO_CLEAR_SELECT|u.MxType.MxCommandFlag.MCRX_CMD_NO_RECORD_PRVCMD),n.MxFun.addCommand("McDraw_GripEdit",b,u.MxType.MxCommandFlag.MCRX_CMD_TRANSPARENT|u.MxType.MxCommandFlag.MCRX_CMD_NO_CLEAR_SELECT|u.MxType.MxCommandFlag.MCRX_CMD_NO_RECORD_PRVCMD),n.MxFun.addCommand("Mx_Undo",N,u.MxType.MxCommandFlag.MCRX_CMD_NO_UNDO_MARKER),n.MxFun.addCommand("Mx_Redo",L,u.MxType.MxCommandFlag.MCRX_CMD_NO_UNDO_MARKER),n.MxFun.addCommand("Mx_Pan",G,u.MxType.MxCommandFlag.MCRX_CMD_NO_UNDO_MARKER)}},{"./MxFun":27,"./MxType":39,"./Operate/MxIntelliSelect":52,"./Operate/MxJigCmdManager":54}],22:[function(t,e,l){var n;Object.defineProperty(l,"__esModule",{value:!0}),l.MxDrawData=void 0,(n=l.MxDrawData||(l.MxDrawData={})).m_dInputRectWidth=16,n.m_isEnableIntelliSelect=!0,n.m_isEnableGripEidt=!0,n.m_isForbiddenDynInput=!1,n.m_isMultipleSelect=!1,n.m_isAutoResetRenderer=!1,n.m_isCorrectLargeCoordinates=!0,n.m_isRequestHeaderCacheControl=!1,n.m_gripPointColor=3355443455,n.m_isMapBox=!1,n.setIniset=function(u){u.EnableIntelliSelect!==void 0&&typeof u.EnableIntelliSelect=="boolean"&&(n.m_isEnableIntelliSelect=u.EnableIntelliSelect),u.EnableGripEidt!==void 0&&typeof u.EnableGripEidt=="boolean"&&(n.m_isEnableGripEidt=u.EnableGripEidt),u.ForbiddenDynInput!==void 0&&typeof u.ForbiddenDynInput=="boolean"&&(n.m_isForbiddenDynInput=u.ForbiddenDynInput),u.multipleSelect!==void 0&&typeof u.multipleSelect=="boolean"&&(n.m_isMultipleSelect=u.multipleSelect),u.autoResetRenderer!==void 0&&typeof u.autoResetRenderer=="boolean"&&(n.m_isAutoResetRenderer=u.autoResetRenderer),u.correctLargeCoordinates!==void 0&&typeof u.correctLargeCoordinates=="boolean"&&(n.m_isCorrectLargeCoordinates=u.correctLargeCoordinates),u.requestHeaderCacheControl!==void 0&&typeof u.requestHeaderCacheControl=="boolean"&&(n.m_isRequestHeaderCacheControl=u.requestHeaderCacheControl),u.MapBox!==void 0&&typeof u.MapBox=="boolean"&&(n.m_isMapBox=u.MapBox),u.inputRectWidth!==void 0&&typeof u.inputRectWidth=="number"&&(n.m_dInputRectWidth=u.inputRectWidth),u.gripPointColor!==void 0&&typeof u.gripPointColor=="number"&&(n.m_gripPointColor=u.gripPointColor)}},{}],23:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxDrawObject=l.IniSetName=l.MxRunMode=void 0;var n,u,c,y=t("three"),b=t("./MxFun"),m=t("./View/MxBrowseLayerData"),O=t("./View/MxBrowseDisplay"),N=t("./MxNetData"),L=t("./MxNetData"),G=t("./MxManager"),q=t("./MxSystemVariable"),J=t("./MxLocalFileLoad"),fe=t("./Operate/MxDrawObjectOsnap"),ve=t("./View/MxDbDatabase"),ne=t("./View/MxDrawMapBox"),Ue=t("./MxDrawObjectEvent"),De=t("./View/MxDbEntityGrip"),Ve=t("./cpp/McDrawObject"),rt=t("./UI/MxUiVue"),Ae=t("./MxDrawData"),Te=t("./MxTempMarkDraw");(u=n=l.MxRunMode||(l.MxRunMode={}))[u.kBrowse=1]="kBrowse",u[u.kCPPMxCAD=4]="kCPPMxCAD",(c=l.IniSetName||(l.IniSetName={})).kEnableOsnapFunction="EnableOsnapFunction";var Xe=(ie.prototype.getCurrentMousePostion=function(){return this.curMousePostion},ie.prototype.isValidCurMousePostion=function(){return this.m_isValidCurMousePostion},ie.prototype.setCurrentMousePostion=function(ue,pt){if(pt===void 0&&(pt=!1),pt){if(0<ue.touches.length){var mt=ue.target.getBoundingClientRect();this.curMousePostion.x=ue.touches[0].clientX-mt.left,this.curMousePostion.y=ue.touches[0].clientY-mt.top,this.m_isValidCurMousePostion=!0}}else this.curMousePostion.x=ue.offsetX,this.curMousePostion.y=ue.offsetY,this.m_isValidCurMousePostion=!0},ie.prototype.mapBoxRender=function(ue,pt,mt){this.mcObject.updateDisplayMapBox(pt),mt||(this.camera.projectionMatrix=pt,this.renderer.autoClear=!1,this.renderer.state.reset(),this.secenView&&this.renderer.render(this.secenView,this.cameraView),this.renderer.render(this.scene,this.camera),this._callCreateCanvasImageData!=null&&(this._callCreateCanvasImageData(this.renderer.domElement.toDataURL("image/png")),this._callCreateCanvasImageData=void 0)),this.callEvent("render",this.renderer)},ie.prototype.mapBoxInitThreeJSObject=function(ue,pt,mt,Tt){this.scene=ue,this.camera=pt,this.renderer=mt,this.controls=Tt},ie.prototype.getMxDrawThreeJs=function(){return this.mxdrawThreeJS},ie.prototype.setPointMultipleSelect=function(ue){this.isPointMultipleSelect=ue},ie.prototype.pointMultipleSelect=function(){return this.isPointMultipleSelect},ie.prototype.getMcObject=function(){return this.mcObject},ie.prototype.is3DMode=function(){return this.mcObject.mxdraw3d.is3DMode()},ie.prototype.getSysVarLong=function(ue){return this.mcObject.isValid()?this.mcObject.getSysVarLong(ue):this.m_sysVariable.getSysVarNumber(ue)},ie.prototype.getSysVarDouble=function(ue){return this.mcObject.isValid()?this.mcObject.getSysVarDouble(ue):this.m_sysVariable.getSysVarNumber(ue)},ie.prototype.getSysVarPoint=function(ue){return this.mcObject.isValid()?this.mcObject.getSysVarPoint(ue):this.m_sysVariable.getSysVarPoint(ue)},ie.prototype.getCAD2DocMatrix=function(){return this._cad2Doc},ie.prototype.isValidMcObject=function(){return this.mcObject.isValid()},ie.prototype.getId=function(){return this.id},ie.prototype.getEventManager=function(){return this.eventManager},ie.prototype.setCurrentLoadUrl=function(ue){this._sCurrentLoadURL=ue},ie.prototype.getCurrentLoadUrl=function(){return this._sCurrentLoadURL},ie.prototype.isWebgl2=function(){return!(!this._rendererParam||this._rendererParam.retver!="webgl2")},ie.prototype.getMxDatabase=function(){return this.m_mxDatabase},ie.prototype.updateCanvasSize=function(){this._onResizeFun&&this._onResizeFun(void 0,!1)},ie.prototype.addMxEntity=function(ue){return this.m_mxDatabase.addMxEntity(ue)},ie.prototype.getMxEntity=function(ue){return this.m_mxDatabase.getEntity(ue)},ie.prototype.getMxEntityUserObject=function(ue){var pt=this.getMxEntity(ue);return pt?pt.getUserObject():null},ie.prototype.eraseAllMxEntity=function(){this.m_mxDatabase.eraseAllEntity()},ie.prototype.eraseMxEntity=function(ue){var pt=this.m_mxDatabase.getEntity(ue);return!!pt&&pt.erase()},ie.prototype.getAllMxEntity=function(){var ue=[];return this.m_mxDatabase.getAllEntity().forEach(function(pt){pt&&ue.push(pt.getUserObject())}),ue},ie.prototype.getMxAllSelect=function(){var ue=this.m_mxDatabase.getSelectManager().getAllSelect(),pt=this.m_mxDatabase.getGripManager().getAllSelect(),mt=new Set;return ue.forEach(function(Tt){mt.add(Tt)}),pt.forEach(function(Tt){mt.has(Tt)||ue.push(Tt)}),ue},ie.prototype.getPrvCommandSelect=function(){return this.m_mxDatabase.getSelectManager().getPrvCommandSelect()},ie.prototype.getMxCADAllSelect=function(){return this.mcObject.isValid()?this.mcObject.getGripManager().getAllSelect():[]},ie.prototype.getSelectPoints=function(){return this.mcObject.getGripManager().getSelectPoints()},ie.prototype.getPrvCommandMxCADSelect=function(){return this.mcObject.isValid()?this.mcObject.getGripManager().getPrvCommandSelect():[]},ie.prototype.addMxCurrentSelect=function(ue,pt,mt){return pt===void 0&&(pt=!0),mt===void 0&&(mt=!0),this.m_mxDatabase.getGripManager().addSelect(ue,pt,mt)},ie.prototype.addMxCADCurrentSelect=function(ue,pt,mt){return pt===void 0&&(pt=!0),mt===void 0&&(mt=!0),!!this.mcObject.isValid()&&this.mcObject.getGripManager().addSelect(ue,pt,mt)},ie.prototype.fireSelectChange=function(ue){if(ue){if(this.mcObject.isValid())return this.mcObject.getGripManager().fireSelectChange()}else this.m_mxDatabase.getGripManager().fireMxEntitySelectChange()},ie.prototype.clearMxCurrentSelect=function(){var ue=this.m_mxDatabase.clearMxCurrentSelect();return this.mcObject.isValid()&&this.mcObject.getGripManager().clearAll(),ue},ie.prototype.addViewObject=function(ue){this.secenView?this.threejsselectObjectsView.add(ue):console.log("this.secenView is null")},ie.prototype.removeViewObject=function(ue){b.MxFun.removeThreejsObject(ue,this.threejsselectObjectsView)},ie.prototype.setOtherRefFile=function(ue){this._tzDwgStaticFile=ue},ie.prototype.setRequestHeader=function(ue){this._requestHeader=ue},ie.prototype.initZoomW=function(ue,pt){this._initZoomwCoordPt1=ue.clone(),this._initZoomWCoordPt2=pt.clone()},ie.prototype.setMouseRightRotate=function(ue){this._mouseRightRotate=ue,this.controls!=null&&(this.controls.mouseButtons.RIGHT=ue?y.MOUSE.ROTATE:-1)},ie.prototype.setZoomSpeed=function(ue){var pt=this.controls.zoomSpeed;return this.controls.zoomSpeed=ue,pt},ie.prototype.resetRenderer=function(){this.renderer.info.reset()},ie.prototype.getRenderer=function(){return this.renderer},ie.prototype.isPaningCommand_call=function(){return this.bakControls!=null},ie.prototype.startPanCommand_call=function(){this.bakControls={},this.bakControls.LEFT=this.controls.mouseButtons.LEFT,this.bakControls.RIGHT=this.controls.mouseButtons.RIGHT,this.bakControls.MIDDLE=this.controls.mouseButtons.MIDDLE,this.controls.mouseButtons.LEFT=y.MOUSE.PAN,this._mouseRightRotate?this.controls.mouseButtons.RIGHT=y.MOUSE.ROTATE:this.controls.mouseButtons.RIGHT=-1,this.controls.mouseButtons.MIDDLE=1,rt.MxUiVue.setCursorType(rt.MxUiVue.CursorType.kPan)},ie.prototype.endPanCommand_call=function(){this.bakControls&&(this.controls.mouseButtons.LEFT=this.bakControls.LEFT,this.controls.mouseButtons.RIGHT=this.bakControls.RIGHT,this.controls.mouseButtons.MIDDLE=this.bakControls.MIDDLE,this.bakControls=void 0,rt.MxUiVue.setCursorType(rt.MxUiVue.CursorType.kNormal))},ie.prototype.isPaningCommand=function(){return this.mxdrawThreeJS.isPaningCommand()},ie.prototype.startPanCommand=function(){this.mxdrawThreeJS.startPanCommand()},ie.prototype.endPanCommand=function(){this.mxdrawThreeJS.endPanCommand()},ie.prototype.setMouseMiddlePan=function(ue){this._isMouseMiddlePan=typeof ue=="boolean"?ue?1:0:ue,this.controls!=null&&(this._isMouseMiddlePan==1?(this.controls.mouseButtons.LEFT=-1,this.controls.mouseButtons.RIGHT=-1,this.controls.mouseButtons.MIDDLE=y.MOUSE.PAN):this._isMouseMiddlePan==2?(this.controls.mouseButtons.LEFT=y.MOUSE.PAN,this.controls.mouseButtons.RIGHT=-1,this.controls.mouseButtons.MIDDLE=y.MOUSE.PAN):(this.controls.mouseButtons.LEFT=y.MOUSE.PAN,this._mouseRightRotate?this.controls.mouseButtons.RIGHT=y.MOUSE.ROTATE:this.controls.mouseButtons.RIGHT=-1,this.controls.mouseButtons.MIDDLE=1))},ie.prototype.resetThreeJSControls=function(){this.controls&&(this.controls.saveState(),this.controls.reset())},ie.prototype.enableZoom=function(ue){this.controls!=null&&(this.controls.enableZoom=ue)},ie.prototype.enablePan=function(ue){this.controls!=null&&(this.controls.enablePan=ue)},ie.prototype.getOrbitControls=function(){return this.controls},ie.prototype.enableViewControls=function(ue){this.controls.enabled=ue},ie.prototype.initRunMode=function(ue){this._isCreate?console.log("iniRunMode failed,mxobject already created"):this._runMode=ue},ie.prototype.getRunMode=function(){return this._runMode},ie.prototype.setStaticLocalLoad=function(ue){this._isStaticLocalLoad=ue},ie.prototype.isStaticLocalLoad=function(){return this._isStaticLocalLoad},ie.prototype.setStaticLocalLoadPath=function(ue){this._staticLocalLoadPath=ue},ie.prototype.on=function(ue,pt){if(this._event[ue])if(this._event[ue]instanceof Array){var mt=this._event[ue];mt.includes(pt)||mt.push(pt)}else{var Tt=this._event[ue];if(Tt==pt)return;this._event[ue]=[],this._event[ue].push(Tt),this._event[ue].push(pt)}else this._event[ue]=pt},ie.prototype.addEvent=function(ue,pt){this.on(ue,pt)},ie.prototype.addControlsEvent=function(ue,pt,mt){return mt===void 0&&(mt=!1),this.eventManager.addEventListener(ue,pt,mt)},ie.prototype.removeEvent=function(ue){this._event[ue]=void 0},ie.prototype.removeEventFuction=function(ue,pt){if(this._event[ue]){if(this._event[ue]instanceof Array){var mt=this._event[ue].indexOf(pt);if(mt!=-1)return this._event[ue].splice(mt,1),this._event[ue].length==0&&delete this._event[ue],!0}else if(this._event[ue]==pt)return delete this._event[ue],!0}return!1},ie.prototype.sysVariable=function(){return this.m_sysVariable},ie.prototype.setIniset=function(ue){var pt=this;Object.keys(ue).forEach(function(mt){pt.m_iniSet[mt]=ue[mt]}),Ae.MxDrawData.setIniset(ue),ue.multipleSelect!==void 0&&typeof ue.multipleSelect=="boolean"&&(this.isMultipleSelect=ue.multipleSelect)},ie.prototype.getInisetValue=function(ue){return this.m_iniSet[ue]},ie.prototype.getViewColor=function(){return this._viewcolor},ie.prototype.isWhiteViewColor=function(){return!!this.mcObject.isPaperSpaceDisplay()||this._viewcolor==16777215},ie.prototype.initUserLoginData=function(ue,pt){this._userIdentitySign=ue,this._userRandomToken=pt},ie.prototype.initRendererParam=function(ue){this._rendererParam=ue},ie.prototype.getRendererParam=function(){return this._rendererParam},ie.prototype.automaticInversionColor=function(ue){return this._viewcolor!=16777215||ue!=16777215?ue:0},ie.prototype.automaticInversionColor2=function(ue){return this._viewcolor==16777215&&(16777215&ue)==16777215?4278190080&ue:ue},ie.prototype.setViewColor=function(ue){this._viewcolor=ue,this._runMode!=n.kCPPMxCAD&&this.scene!=null&&(this.scene.background=new y.Color(ue))},ie.prototype.zoomScale=function(ue,pt){this.mxdrawThreeJS.zoomScale(ue,pt)},ie.prototype.setViewAngle=function(ue){this.mxdrawThreeJS.setViewAngle(ue)},ie.prototype.zoomW=function(ue,pt,mt,Tt,kt){kt===void 0&&(kt=!1),this.mxdrawThreeJS.zoomW(ue,pt,mt,Tt,kt)},ie.prototype.zoomCenter=function(ue,pt,mt){this.mxdrawThreeJS.zoomCenter(ue,pt,mt)},ie.prototype.getViewAngle=function(){return this._viewangle},ie.prototype.callInitCompleteEvent=function(){this.callEvent("loadComplete")},ie.prototype.callInitObjectEvent=function(){this.callEvent("initObject")},ie.prototype.callInitSceneEvent=function(ue,pt,mt){var Tt=this._event.initScene;if(!Tt)return 0;if(Tt instanceof Array){var kt=0;return Tt.forEach(function(It){kt=It(ue,pt,mt)}),kt}return Tt(ue,pt,mt)},ie.prototype.callOpenFileComplete=function(ue,pt){pt===void 0&&(pt=0);try{var mt=this._event.openFileComplete;if(!mt)return;mt instanceof Array?mt.forEach(function(Tt){Tt(ue,pt)}):mt(ue,pt)}catch(Tt){throw console.log(Tt),Tt}},ie.prototype.hasEvent=function(ue){return this._event[ue]!=null},ie.prototype.regenAllMxDbEntity=function(){return this.m_mxDatabase.regenAllMxDbEntity()},ie.prototype.callEvent=function(ue,pt){try{var mt=this._event[ue];if(!mt)return!1;if(mt instanceof Array){var Tt=!1;return mt.forEach(function(kt){Tt=kt(pt)}),Tt}return mt(pt)}catch(kt){throw console.log(kt),kt}},ie.prototype.callViewChange=function(){this.onViewChange(),this.callEvent("viewchange")},ie.prototype.userLoginResult=function(ue){this.callEvent("userLoginResult",ue)},ie.prototype.serverReturn=function(ue){var pt=JSON.parse(ue);this.callEvent("serverReturn",pt)},ie.prototype.openFileResult=function(ue){JSON.parse(ue).linkServer||console.log("link mx serverobj error"),this.callEvent("openFileResult",ue)},ie.prototype.xzSize=function(ue){var pt=this._devicePixelRatio;if(pt-1<=1e-4&&-1e-4<=pt-1)return ue;for(var mt=9999999,Tt=ue,kt=0,It=ue;kt<100;kt++){if((tn=(nn=It*pt)-Math.floor(nn))<=.001)return It;tn<mt&&(mt=tn,Tt=It),It+=1}for(It=ue;kt<100;kt++){var nn,tn;if((tn=(nn=It*pt)-Math.floor(nn))<=.001)return It;tn<mt&&(mt=tn,Tt=It),--It}return Tt},ie.prototype.setSize=function(ue,pt){this._viewWidth=ue,this._viewHeight=pt,this._userCanvas!=null&&(this._userCanvas.width=ue,this._userCanvas.height=pt,this._userCanvas.style.width=ue+"px",this._userCanvas.style.height=pt+"px"),this.onResizeImp(),this.updateDisplay()},ie.prototype.getCurrentColor=function(){return this._color},ie.prototype.setCurrentColor=function(ue){this._color=ue},ie.prototype.call=function(ue,pt,mt){this._net.getSend().CallServerJS(ue,pt,mt)},ie.prototype.zoomAll=function(){this._is2d&&this.call("getDatabaseBoundHelp",'{"isBackground":1}',function(ue){if(ue.length!=0){var pt=JSON.parse(ue);this.zoomW(new y.Vector3(pt[0],pt[1],0),new y.Vector3(pt[2],pt[3],0))}})},ie.prototype.getViewCenterDocCoord=function(){return this._userCanvas!=null?this.screenCoord2Current(.5*this._userCanvas.clientWidth,.5*this._userCanvas.clientHeight,0):this.screenCoord2Current(.5*this._viewWidth,.5*this._viewHeight,0)},ie.prototype.closeWebSocket=function(){this._net.closeWebSocket()},ie.prototype.findMxEntityAtPoint=function(ue,pt,mt){!pt&&pt!==void 0||(ue=this.currentCoord2Screen(ue.x,ue.y,0));var Tt=[],kt=this.m_mxDatabase.getIntersectObjects(ue);if(kt.length==0)return Tt;var It=new Map;return kt.forEach(function(nn){var tn=De.MxGetMxDbEntitForThreeJsObject(nn.object);if(tn){var pn=tn.objectId();if(!It.has(pn)){if(mt){var _n=De.MxGetWordDrawxDataForThreeJsObject(nn.object);_n&&mt(pn,_n)}It.set(pn,tn.getUserObject())}}}),It.forEach(function(nn){Tt.push(nn)}),Tt},ie.prototype.isCppMxCAD=function(){return this._runMode==n.kCPPMxCAD},ie.prototype.loadMxCADImage=function(ue,pt){var mt=this;if(this.mcObject.isValid()){var Tt=ue;Tt.lastIndexOf("/")!=-1&&(Tt=Tt.substring(Tt.lastIndexOf("/")+1).toLowerCase()),this.mcObject.getTextureManager().loadImage(ue,Tt,function(kt,It){kt?(mt.mcObject.getTextureManager().createOpenGLTexture(ue),pt(It)):pt(void 0)})}else pt(void 0)},ie.prototype.onLoad=function(ue){if(this._runMode==n.kCPPMxCAD)this.callInitCompleteEvent();else if(this._isStaticLocalLoad)this._net=new L.MxNet,this._net.init(this,!1),0<this._openFile.length&&(this._staticLocalNet=new J.MxLocalDwgFileLoad(this._net),this._staticLocalNet.load(encodeURIComponent(this._staticLocalLoadPath),encodeURIComponent(this._openFile)));else if(this._openFile.length==0)this.callInitCompleteEvent(),this.callOpenFileComplete(0);else if(this._net=new L.MxNet,this._net.init(this,!1),this._staticNet=new L.MxHFileLoad(this._net),this._staticNet.setRequestHeader(this._requestHeader),this._staticNet.setUrlParam(ue),this._staticNet.load(this._openFile,this._staticLoadingOpenFiles),this._tzDwgStaticFile&&0<this._tzDwgStaticFile.length){var pt=new L.MxNet;pt.init(this,!1),this._extRefManager.createTzDwgExternalReferences(99999),pt.setCurrentDatabaseId(99999),this._staticLoadTzNet=new L.MxHFileLoad(pt),this._staticLoadTzNet.setShowloading(!1),this._staticLoadTzNet.setRequestHeader(this._requestHeader),this._staticLoadTzNet.load(this._tzDwgStaticFile,[])}},ie.prototype.stopAllLoading=function(){this._staticNet&&this._staticNet.stopAllLoading()},ie.prototype.getStaticNet=function(){return this._staticNet},ie.prototype.isStaticFileNet=function(){return!this._isStaticLocalLoad&&this._staticNet!=null},ie.prototype.getStaticLocalNet=function(){return this._staticLocalNet},ie.prototype.getStaticLoadTzNet=function(){return this._staticLoadTzNet},ie.prototype.getViewWidth=function(){return this._userCanvas!=null?this._userCanvas.clientWidth:this._viewWidth},ie.prototype.getViewHeight=function(){return this._userCanvas!=null?this._userCanvas.clientHeight:this._viewHeight},ie.prototype.makeCurrent=function(){G.MxManager.setCurrentMx(this),this.mcObject.makeCurrent()},ie.prototype.createCanvasImageData=function(ue,pt){var mt=0,Tt=0,kt=!1,It=!1,nn=!1;pt&&pt.range_pt1&&pt.range_pt2&&(nn=It=!0,this.saveZoom()),pt&&pt.width&&pt.height&&(mt=this.getViewWidth(),Tt=this.getViewHeight(),kt=!0,this.setSize(pt.width,pt.height)),nn&&this.zoomW(pt.range_pt1,pt.range_pt2);var tn=this;this._callCreateCanvasImageData=function(pn){kt&&tn.setSize(mt,Tt),It&&tn.recoverZoom(),ue(pn)},this.updateDisplay()},ie.prototype.getIntersectObjects=function(ue){return this.getMxDrawThreeJs().createRaycaster(ue).intersectObjects(this.threejsselectObjects.children,!0)},ie.prototype.addObject=function(ue){this.threejsselectObjects.add(ue)},ie.prototype.removeObject=function(ue){this.threejsselectObjects.remove(ue)},ie.prototype.render=function(){this.secenView?(this.mcObject.updateDisplay()?(this.renderer.autoClear=!1,this.renderer.state.reset()):this.renderer.autoClear=!0,this.renderer.render(this.secenView,this.cameraView),this.renderer.autoClear=!1):this.mcObject.updateDisplay()?(this.renderer.autoClear=!1,this.renderer.state.reset()):this.renderer.autoClear=!0,this.renderer.render(this.scene,this.camera),this._callCreateCanvasImageData!=null&&(this._callCreateCanvasImageData(this.renderer.domElement.toDataURL("image/png")),this._callCreateCanvasImageData=void 0),this.callEvent("render",this.renderer)},ie.prototype.updateDisplay=function(ue){ue===void 0&&(ue=!1),this.mxdrawThreeJS.updateDisplay(ue)},ie.prototype.isRenderLoop=function(){return this._isAnimation},ie.prototype.renderLoop=function(ue){ue===void 0&&(ue=!0),this._isAnimation=ue,this.updateDisplay()},ie.prototype.updateDisplayImplement=function(ue){ue===void 0&&(ue=!1);var pt=this,mt=function(){pt.m_mxDatabase.upDirtyDisplay(),pt._isAnimation?(pt._isAnimationStarting=!0,requestAnimationFrame(mt)):pt._isWaiteCount=0,pt.render()};ue!==!0?this._isAnimationStarting||(this._isAnimation?requestAnimationFrame(mt):((5<this._isWaiteCount||this._isWaiteCount<0)&&(this._isWaiteCount=0),this._isWaiteCount<=0&&requestAnimationFrame(mt),this._isWaiteCount++)):mt()},ie.prototype.gotoLayoutOld=function(ue){ue=="Modle"&&(ue="");var pt=this._openFile;for(var mt in this._iniParam)(nn=(It=this._iniParam[mt])[0])=="srcname"&&(pt=It[1]);var Tt={},kt="";for(var mt in this._iniParam){var It,nn;if(Tt[nn=(It=this._iniParam[mt])[0]]==null){Tt[nn]=!0;var tn=It[1];if(nn=="file"){if(tn=pt,0<ue.length){var pn=tn.substring(tn.lastIndexOf(".")+1);tn=tn.substring(0,tn.lastIndexOf("."))+"%23"+ue+"%23."+pn}}else if(nn=="srcname")continue;kt.length==0?kt=nn+"="+tn+"&srcname="+pt:kt+="&"+nn+"="+tn}}var _n=b.MxFun.getLocationPageUrl()+"?"+kt;window.location.href=_n},ie.prototype.gotoLayout=function(ue){var pt=!1,mt=!this.isStaticFileNet();for(var Tt in this._iniParam)if((_n=this._iniParam[Tt])[0]=="dwgdir"){pt=!0;break}if(pt||mt)this.gotoLayoutOld(ue);else{ue=="Model"&&(ue="");var kt=this._openFile;if(!kt)return;var It=kt.lastIndexOf(".dwg");if(It===void 0||It===-1)return;if((kt=kt.substring(0,It))[kt.length-1]=="#"){var nn=kt.substring(0,kt.length-1),tn=nn.lastIndexOf("#");tn!==void 0&&tn!==-1&&(kt=nn.substring(0,tn))}0<ue.length?kt=kt+"#"+ue+"#.dwg.mxb1.wgh":kt+=".dwg.mxb1.wgh";var pn={};for(var Tt in this._iniParam){var _n,Dn=(_n=this._iniParam[Tt])[0];if(pn[Dn]==null){pn[Dn]=!0;var an=_n[1];Dn!="file"&&Dn!="srcname"&&(kt+="&"+Dn+"="+an)}}var Rn=b.MxFun.getLocationPageUrl()+"?file="+kt;window.location.href=encodeURI(Rn)}},ie.prototype.addInitParam=function(ue,pt){var mt=new Array;mt.push(ue),mt.push(pt),this._iniParam.push(mt)},ie.prototype.openFile=function(ue,pt){if(pt===void 0&&(pt=""),!this._isCreate)return console.log("mx: openFile Fialed mxasser(_isCreate == false)"),!1;if(this.stopAllLoading(),ue.length==0)return!1;this.reInit(),this._devicePixelRatio=window.devicePixelRatio,ue instanceof Array?(this._openFile=ue[0],this._staticLoadingOpenFiles=ue):this._openFile=ue,this._openFileExtName=this._openFile.substring(this._openFile.lastIndexOf(".")+1),this._iniParam=[],this._initZoomwCoordPt1=null,this._initZoomWCoordPt2=null;var mt=new Array;return mt.push("file"),mt.push(this._openFile),this._iniParam.push(mt),this.onLoad(pt),!0},ie.prototype.updateCameraDisplayRange=function(ue,pt,mt){this.mxdrawThreeJS.updateCameraDisplayRange(ue,pt,mt)},ie.prototype.updateCameraForm3dViewData=function(ue){this.mxdrawThreeJS.updateCameraForm3dViewData(ue)},ie.prototype.clearAllObject=function(){this.reInit()},ie.prototype.newFile=function(ue,pt,mt,Tt){if(!this._isCreate)return console.log("mx: openFile Fialed mxasser(_isCreate == false)"),!1;var kt,It;if(It=ue instanceof Object&&pt instanceof Object?(kt=ue,pt):(kt=new y.Vector3(ue,pt,0),new y.Vector3(mt,Tt,0)),kt.x>It.x){var nn=kt.x;kt.x=It.x,It.x=nn}if(kt.y>It.y){var tn=kt.y;kt.y=It.y,It.y=tn}this.reInit(),this._devicePixelRatio=window.devicePixelRatio,this._openFile="",this._openFileExtName="dwg",this._iniParam=[],this._initZoomwCoordPt1=null,this._initZoomWCoordPt2=null;var pn=new y.Matrix4;pn.identity(),this.intiDoc2Wold(pn),this.initCAD2Doc(pn),this.initializingObjectMatrix(),this.mxdrawThreeJS.updateCameraDisplayRange(kt,It,0),this.updateDisplay(!0);var _n=b.MxFun.getUiObj();_n!=null&&(_n.SetLayoutData(this._allLayoutName),_n.UpDisplayLayout())},ie.prototype.calcViewsize=function(){if(this._userCanvas==null)return{viewWidth:window.innerWidth,viewHeight:window.innerHeight};var ue=this._userCanvas.clientWidth,pt=this._userCanvas.clientHeight;if(this._event.onResize!=null){var mt=this._event.onResize;mt instanceof Array&&(mt=mt[0]);var Tt=mt();Tt!=null&&(ue=parseInt(Tt.width),pt=parseInt(Tt.height))}return{viewWidth:ue,viewHeight:pt}},ie.prototype.initMxCpp=function(ue){ue&&ue.getImp()?(this.mcObject.init(this,ue),this.secenView!=null?this.secenView.background=null:this.scene.background=null):console.log("mxerror: mcppObjectImp is null")},ie.prototype.create=function(ue,pt,mt,Tt){if(this._is2d?this.mxdrawThreeJS=Tt?new ne.MxDrawMapBoxThreeJS(Tt,this):new ne.MxDrawObject2dThreeJS(this):this.mxdrawThreeJS=new ne.MxDrawObject3dThreeJS(this),this._callCreateCanvasImageData=void 0,this._devicePixelRatio=window.devicePixelRatio,this._runMode==n.kCPPMxCAD)this._openFile="";else{if(pt instanceof Array?(this._openFile=pt[0],this._staticLoadingOpenFiles=pt):this._openFile=pt,this._iniParam=b.MxFun.getUrlParams(),this._openFileExtName=this._openFile.substring(this._openFile.lastIndexOf(".")+1),this._openFile!=""){var kt=new Array;kt.push("file"),kt.push(this._openFile),this._iniParam.push(kt)}this._userIdentitySign!=""&&(this.addInitParam("userIdentitySign",this._userIdentitySign),this.addInitParam("userRandomToken",this._userRandomToken)),this.addInitParam("runMode","browse")}this._userCanvas=ue;var It=window.innerWidth,nn=window.innerHeight;if(ue!=null&&(It=ue.clientWidth,nn=ue.clientHeight),this._viewWidth=It,this._viewHeight=nn,this.m_mxDatabase.getSelectManager().setCanvasSize(It,nn),this.mxdrawThreeJS.onInitThreejs(),this.eventManager.registEvent(this),this.onCreate(),this.m_mxDatabase.init(this),this._parentDocObject=new y.Object3D,this.scene.add(this._parentDocObject),this._parentDocObject_SmallCoord=new y.Object3D,this.scene.add(this._parentDocObject_SmallCoord),this.threejsselectObjects=new y.Object3D,this.scene.add(this.threejsselectObjects),this._objectsOsnap=new fe.MxDrawObjectOsnap(this),this.tempMarkDraw.init(this),G.MxManager.add(this),G.MxManager.setCurrentMx(this),this.mxdrawThreeJS.addControlsChangeEvent(),Tt||this.updateDisplay(),this.mxdrawThreeJS.getType()!=ne.MxThreeJSType.kMapBox){var tn=this;if(ue==null){var pn=function(xn,$n){$n===void 0&&($n=!0),tn._viewWidth=window.innerWidth,tn._viewHeight=window.innerHeight,tn.onResizeImp()&&tn.updateDisplay($n)};window.addEventListener("resize",pn,!1),this._onResizeFun=pn}else{var _n=function(xn,$n){$n===void 0&&($n=!0),xn&&xn.viewWidth&&xn.viewHeight||(xn=tn.calcViewsize()),tn._viewWidth=xn.viewWidth,tn._viewHeight=xn.viewHeight,tn.onResizeImp(tn._viewWidth,tn._viewHeight)&&tn.updateDisplay($n)};if(this._onResizeFun=_n,this._event.addResizeEvent!=null){var Dn=this._event.addResizeEvent;Dn instanceof Array&&(Dn=Dn[0]),Dn(_n,ue)}else window.addEventListener("resize",_n,!1);if(window.setTimeout(function(){_n(void 0,!1)},5),this._event.onResize!=null){var an=tn.calcViewsize();_n(an,!1);var Rn=0,Lt=0,wn=!0,hn=window.setInterval(function(){Lt++;var xn=tn.calcViewsize();if(xn.viewWidth==an.viewWidth&&xn.viewHeight==an.viewHeight&&0<xn.viewWidth&&0<xn.viewHeight){if(8<++Rn)return clearInterval(hn),void _n(xn,!1);1<=Rn&&wn&&(_n(xn,!1),2<=Rn&&(wn=!1))}else Rn=0;an=xn,50<Lt&&(clearInterval(hn),0<xn.viewWidth&&0<xn.viewHeight?_n(xn,!1):console.log("mxassert(0) error view size"))},50)}}}this.callInitObjectEvent(),this.onLoad(mt),this._isCreate=!0},ie.prototype.initResize=function(){if(this._userCanvas==null)this._viewWidth=window.innerWidth,this._viewHeight=window.innerHeight,this.onResizeImp();else{if(this._viewWidth=this._userCanvas.clientWidth,this._viewHeight=this._userCanvas.clientHeight,this._event.onResize!=null){var ue=this._event.onResize;ue instanceof Array&&(ue=ue[0]);var pt=ue();pt!=null&&(this._viewWidth=pt.width,this._viewHeight=pt.height)}this.onResizeImp(this._viewWidth,this._viewHeight)}this.updateDisplay()},ie.prototype.is2D=function(){return this._is2d},ie.prototype.getOpenFile=function(){return this._openFile},ie.prototype.getFileTitle=function(){var ue=this._openFile;if(this._openFile.substring(this._openFile.lastIndexOf(".")+1).toLowerCase()=="wgh"){var pt=this._openFile.substring(0,this._openFile.indexOf(".mxb1.wgh")).split("/");(ue=pt.length==1?pt[0]:pt[pt.length-1])[0]=="$"&&(ue=ue.substring(1))}return ue},ie.prototype.getIniParam=function(){return this._iniParam},ie.prototype.getOpenFileExtName=function(){return this._openFileExtName},ie.prototype.loadCodeToServer=function(ue,pt){this._net.getSend().CallLoadCodeToServer(ue,pt)},ie.prototype.userLogin=function(ue,pt){this._net.getSend().UserLogin(ue,pt)},ie.prototype.getUserCanvas=function(){return this._userCanvas},ie.prototype.getCanvas=function(){return this._userCanvas!=null?this._userCanvas:this.renderer.domElement},ie.prototype.getScene=function(){return this.scene},ie.prototype.getCamera=function(){return this.camera},ie.prototype.callCommand=function(ue,pt,mt){pt===void 0&&(pt=""),this._net.getSend().DoCommand(ue,pt,mt)},ie.prototype.deleteAll=function(){this.removeAllEntity(),this.callCommand("Mx_ClearAll"),this.updateDisplay()},ie.prototype.initAllLayoutName=function(ue){this._allLayoutName=ue},ie.prototype.getAllLayoutName=function(){return this._allLayoutName},ie.prototype.updataClipMaterial=function(){this._blocks.updataClipMaterial(this)},ie.prototype.getExtRefManager=function(){return this._extRefManager},ie.prototype.showLayer=function(ue,pt){typeof ue=="string"&&(ue=this._layers.getLayerIdForName(ue)),this._blocks.showLayer(ue,pt),this.updateDisplay()},ie.prototype.addLayerInfo=function(ue,pt,mt){pt=this.automaticInversionColor(16777215&pt),this._layers.add(ue,pt,mt)},ie.prototype.setZeroLayerId=function(ue){this._layers.setZeroLayerId(ue)},ie.prototype.addLayerInfoComplete=function(){this._layers.initComplete()},ie.prototype.addEntity=function(ue,pt){var mt=this._mapId2Entity.get(ue);mt==null&&(mt=new Array,this._mapId2Entity.set(ue,mt)),mt.push(pt)},ie.prototype.getEntity=function(ue){return this._mapId2Entity.get(ue)},ie.prototype.clearThreejsScence=function(){this.m_mxDatabase.getGripManager().reInit(),this.isValidMcObject()&&this.mcObject.getGripManager().reInit(),b.MxFun.removeThreejsObject(this.threejsselectObjects,this.scene),this.threejsselectObjects=new y.Object3D,b.MxFun.removeThreejsObject(this._parentDocObject,this.scene),this._parentDocObject=new y.Object3D,b.MxFun.removeThreejsObject(this._parentDocObject_SmallCoord,this.scene),this._parentDocObject_SmallCoord=new y.Object3D,this.scene.remove(),this.scene.dispose(),this.scene=new y.Scene,this.scene.add(this.threejsselectObjects),this.scene.add(this._parentDocObject),this.scene.add(this._parentDocObject_SmallCoord),this._objectsOsnap=new fe.MxDrawObjectOsnap(this),this.m_mxDatabase.reInit(),this.tempMarkDraw.init(this),this.mxdrawThreeJS.onInitScene(),b.MxFun.removeThreejsObject(this.threejsselectObjectsView,this.secenView),this.threejsselectObjectsView=null,this.secenView.remove(),this.secenView.dispose(),this.secenView=null,this.onInitViewScene(),this._runMode!=n.kCPPMxCAD&&this.mxdrawThreeJS.getType()!=ne.MxThreeJSType.kMapBox||(this.secenView!=null?this.secenView.background=null:this.scene.background=null)},ie.prototype.reInit=function(){this.clearThreejsScence(),this._openFile="",this._openFileExtName="",this._mapId2Entity=new Map,this._setAdyDelete=new Map,this._layers=new m.MxBrowseLayerData,this._blocks=new O.Blocks,this._extRefManager=new O.ExternalReferenceManager,this._doc2World=new y.Matrix4,this._word2doc=new y.Matrix4,this._allLayoutName=new Array,this._tzDwgStaticFile="",this._devicePixelRatio=window.devicePixelRatio,this._blocks.initRootBlockRef()},ie.prototype.removeEntity=function(ue){if(this._setAdyDelete[ue]==null){this._setAdyDelete[ue]=!0;var pt=this._mapId2Entity.get(ue);if(pt!=null){for(var mt in pt)this.scene.remove(pt[mt]);this._mapId2Entity.delete(ue)}}},ie.prototype.removeEntityFromServer=function(ue){for(var pt=ue.getInt32(4,!0),mt=0;mt<pt;mt++){var Tt=ue.getInt32(4*(mt+20),!0);this.removeEntity(Tt)}},ie.prototype.removeAllEntity=function(){var ue=this;this._mapId2Entity.forEach(function(pt,mt,Tt){for(var kt in pt)ue.scene.remove(pt[kt])}),this._mapId2Entity.clear()},ie.prototype.mxWebAddEntity=function(ue){this._setAdyDelete.clear();var pt=this.mxWebAddEntity_3DChild(ue);this.mxWebAddEntity_Curve(ue,pt),this._setAdyDelete.clear()},ie.prototype.getViewWorldCoord=function(){var ue=new y.Vector3(-1,-1,1);ue.unproject(this.camera);var pt=new y.Vector3(-1,1,1);pt.unproject(this.camera);var mt=new y.Vector3(1,1,1);mt.unproject(this.camera);var Tt=new y.Vector3(1,-1,1);return Tt.unproject(this.camera),{pt1:ue,pt2:pt,pt3:mt,pt4:Tt}},ie.prototype.getViewDocCoord=function(){var ue=this.getViewWorldCoord();return ue.pt1=this.docCoord2Cad2(this.worldCoord2Doc(ue.pt1.x,ue.pt1.y,0)),ue.pt2=this.docCoord2Cad2(this.worldCoord2Doc(ue.pt2.x,ue.pt2.y,0)),ue.pt3=this.docCoord2Cad2(this.worldCoord2Doc(ue.pt3.x,ue.pt3.y,0)),ue.pt4=this.docCoord2Cad2(this.worldCoord2Doc(ue.pt4.x,ue.pt4.y,0)),ue},ie.prototype.screenCoord2World=function(ue,pt,mt){return this.mxdrawThreeJS.screenCoord2World(ue,pt,mt)},ie.prototype.worldCoord2Screen=function(ue,pt,mt){return this.mxdrawThreeJS.worldCoord2Screen(ue,pt,mt)},ie.prototype.screenCoord2World_mxdrawThreeJS_call=function(ue,pt,mt){var Tt=this.getCanvas(),kt=Tt.clientWidth,It=Tt.clientHeight;mt=.5;var nn=this.camera;nn&&nn.isOrthographicCamera&&(mt=(nn.near+nn.far)/(nn.near-nn.far));var tn=new y.Vector3(ue/kt*2-1,-pt/It*2+1,mt);return tn.unproject(this.camera),tn.z=0,tn},ie.prototype.worldCoord2Screen_mxdrawThreeJS_call=function(ue,pt,mt){var Tt=new y.Vector3(ue,pt,mt).project(this.camera),kt=this.getCanvas(),It=kt.clientWidth/2,nn=kt.clientHeight/2,tn=Math.round(Tt.x*It+It),pn=Math.round(-Tt.y*nn+nn);return new y.Vector3(tn,pn,0)},ie.prototype.worldCoordLong2Doc=function(ue){var pt=this.worldCoord2Doc(0,0,0),mt=this.worldCoord2Doc(ue,0,0);return pt.distanceTo(mt)},ie.prototype.docCoordLong2World=function(ue){var pt=this.docCoord2World(0,0,0),mt=this.docCoord2World(ue,0,0);return pt.distanceTo(mt)},ie.prototype.getDoc2CADMatrix=function(){return this._doc2CAD},ie.prototype.docCoord2Cad=function(ue,pt,mt){var Tt=new y.Vector3(ue,pt,mt);return Tt.applyMatrix4(this._doc2CAD),Tt},ie.prototype.toSmallcoord=function(ue){return this._runMode==n.kCPPMxCAD?this.cadCoord2Doc2(ue):ue},ie.prototype.toSmallcoord2=function(ue,pt,mt){return mt===void 0&&(mt=0),this._runMode==n.kCPPMxCAD?this.cadCoord2Doc(ue,pt,mt):new y.Vector3(ue,pt,mt)},ie.prototype.docCoord2Cad2=function(ue){return(ue=ue.clone()).applyMatrix4(this._doc2CAD),ue},ie.prototype.cadCoord2Doc=function(ue,pt,mt){var Tt=new y.Vector3(ue,pt,mt);return Tt.applyMatrix4(this._cad2Doc),Tt},ie.prototype.cadCoord2Doc2=function(ue){return(ue=ue.clone()).applyMatrix4(this._cad2Doc),ue},ie.prototype.docCoordLong2Cad=function(ue){var pt=this.docCoord2Cad(0,0,0),mt=this.docCoord2Cad(ue,0,0);return pt.distanceTo(mt)},ie.prototype.cadCoordLong2Doc=function(ue){var pt=this.cadCoord2Doc(0,0,0),mt=this.cadCoord2Doc(ue,0,0);return pt.distanceTo(mt)},ie.prototype.viewCoordLong2Cad=function(ue){return this.docCoordLong2Cad(this.screenCoordLong2Doc(ue))},ie.prototype.cadCoordLong2View=function(ue){return this.docCoordLong2Screen(this.cadCoordLong2Doc(ue))},ie.prototype.viewCoord2Cad=function(ue,pt,mt){var Tt=this.screenCoord2Doc(ue,pt,mt);return this.docCoord2Cad(Tt.x,Tt.y,Tt.z)},ie.prototype.cadCoord2View=function(ue,pt,mt){var Tt=this.cadCoord2Doc(ue,pt,mt);return this.docCoord2Screen(Tt.x,Tt.y,Tt.z)},ie.prototype.docCoord2World=function(ue,pt,mt){var Tt=new y.Vector3(ue,pt,mt);return Tt.applyMatrix4(this._doc2World),Tt},ie.prototype.getDoc2World=function(){return this._doc2World},ie.prototype.getWorldToDoc=function(){return this._word2doc},ie.prototype.worldCoord2Doc=function(ue,pt,mt){var Tt=new y.Vector3(ue,pt,mt);return Tt.applyMatrix4(this._word2doc),Tt},ie.prototype.screenCoord2Doc=function(ue,pt,mt){var Tt=this.screenCoord2World(ue,pt,mt);return this.worldCoord2Doc(Tt.x,Tt.y,0)},ie.prototype.worldCoord2Currnet=function(ue,pt,mt){var Tt=new y.Vector3(ue,pt,mt);return Tt.applyMatrix4(this._word2Current),Tt},ie.prototype.currentCoord2World=function(ue,pt,mt){var Tt=new y.Vector3(ue,pt,mt);return Tt.applyMatrix4(this._current2word),Tt},ie.prototype.screenCoord2Current=function(ue,pt,mt){var Tt=this.screenCoord2World(ue,pt,mt);return Tt.applyMatrix4(this._word2Current),Tt},ie.prototype.currentCoord2Screen=function(ue,pt,mt){var Tt=new y.Vector3(ue,pt,mt);return Tt.applyMatrix4(this._current2word),this.worldCoord2Screen(Tt.x,Tt.y,Tt.z)},ie.prototype.docCoord2Screen=function(ue,pt,mt){var Tt=this.docCoord2World(ue,pt,mt);return this.worldCoord2Screen(Tt.x,Tt.y,Tt.z)},ie.prototype.screenCoordLong2Doc=function(ue){var pt=this.screenCoord2Doc(0,0,0),mt=this.screenCoord2Doc(ue,0,0);return pt.distanceTo(mt)},ie.prototype.screenCoordLong2DocScale=function(){var ue=this.screenCoord2Doc(0,0,0),pt=this.screenCoord2Doc(1,0,0);return ue.distanceTo(pt)},ie.prototype.docCoordLong2Screen=function(ue){var pt=this.docCoord2Screen(0,0,0),mt=this.docCoord2Screen(0<ue?ue:-ue,0,0);return 0<=ue?pt.distanceTo(mt):-pt.distanceTo(mt)},ie.prototype.screenCoordLong2World=function(ue){var pt=this.screenCoord2World(0,0,0),mt=this.screenCoord2World(0<ue?ue:-ue,0,0);return 0<=ue?pt.distanceTo(mt):-pt.distanceTo(mt)},ie.prototype.worldCoordLong2Screen=function(ue){var pt=this.worldCoord2Screen(0,0,0),mt=this.worldCoord2Screen(ue,0,0);return pt.distanceTo(mt)},ie.prototype.initCAD2Doc=function(ue){ue instanceof Array?this._cad2Doc.fromArray(ue):this._cad2Doc=ue,this._doc2CAD.getInverse(this._cad2Doc),this.mcObject.initCAD2Doc(this._cad2Doc,this._doc2CAD)},ie.prototype.intiDoc2Wold=function(ue){ue instanceof Array?this._doc2World.fromArray(ue):this._doc2World=ue,this._word2doc.getInverse(this._doc2World)},ie.prototype.intiword2Current=function(ue){this._word2Current=ue.clone(),this._current2word.getInverse(this._word2Current)},ie.prototype.initializingObjectMatrix=function(){this.isNewObjectMatrix&&this._runMode==n.kCPPMxCAD?(this.m_mxDatabase.initObjectMatrix(this._cad2Doc),this._parentDocObject.matrix=this._cad2Doc,this._parentDocObject.matrixAutoUpdate=!1,this._parentDocObject_SmallCoord.matrix=new y.Matrix4,this._parentDocObject_SmallCoord.matrixAutoUpdate=!1,this.threejsselectObjects.matrix=this._cad2Doc,this.threejsselectObjects.matrixAutoUpdate=!1,this.intiword2Current(this._doc2CAD)):(this.m_mxDatabase.initObjectMatrix(this._doc2World),this._parentDocObject.matrix=this._doc2World,this._parentDocObject.matrixAutoUpdate=!1,this._parentDocObject_SmallCoord.matrix=this._doc2World,this._parentDocObject_SmallCoord.matrixAutoUpdate=!1,this.threejsselectObjects.matrix=this._doc2World,this.threejsselectObjects.matrixAutoUpdate=!1,this.intiword2Current(this._word2doc))},ie.prototype.getDrawContainer=function(){return this.threejsselectObjects},ie.prototype.getTheTempDrawContainer=function(){return this._parentDocObject},ie.prototype.getTheTempDrawContainer_SmallCoord=function(){return this._parentDocObject_SmallCoord},ie.prototype.getTempMarkDraw=function(){return this.tempMarkDraw},ie.prototype.mxWebAddEntityFor2dPointMeshBuffers=function(ue,pt){var mt=new N.MxNetData(ue),Tt=mt.getdPointMeshBuffersHead(),kt=Tt.zeroLayerIdIndex,It=Tt.databaseIndex;pt!=-1&&(It=pt);for(var nn=Tt.datasize,tn=0;tn<Tt.datacount;tn++){var pn=mt.getdPointMeshBufferDataHead(nn);nn=pn.offset;var _n=pn.layerId,Dn=_n==kt,an=pn.blkId,Rn=pn.pointCount;if(!(Rn<1)){for(var Lt=[],wn=[],hn=[],xn=[],$n=[],Xr=0;Xr<Rn;Xr++){var ti=ue.getFloat32(nn,!0);nn+=4;var gn=ue.getFloat32(nn,!0);nn+=4;var Xn=ue.getFloat32(nn,!0);nn+=4;var Kn=ue.getFloat32(nn,!0);nn+=4;var Vn=ue.getFloat32(nn,!0);nn+=4;var Yn=ue.getFloat32(nn,!0);nn+=4;var Vr=ue.getInt32(nn,!0);nn+=4;var xi=Vr>>24&255;xi==2?(xn.push(ti,gn),xn.push(Xn,Kn),xn.push(Vn,Yn)):xi==1?an!=0&&Dn?($n.push(ti,gn),$n.push(Xn,Kn),$n.push(Vn,Yn)):(hn.push(ti,gn),hn.push(Xn,Kn),hn.push(Vn,Yn)):(Vr=this.automaticInversionColor(16777215&Vr),Lt.push(ti,gn),Lt.push(Xn,Kn),Lt.push(Vn,Yn),wn.push((255&Vr)/255,(Vr>>8&255)/255,(Vr>>16&255)/255),wn.push((255&Vr)/255,(Vr>>8&255)/255,(Vr>>16&255)/255),wn.push((255&Vr)/255,(Vr>>8&255)/255,(Vr>>16&255)/255))}var Si=this._blocks,qn=this._layers;It!=0&&(Si=this._extRefManager.getBlocks(It),qn=this._extRefManager.getLayers(It));var ia=Si.crateBlock(an);ia.addGeometryMesh(Lt,wn,_n,xn,hn,$n),Si.createThreejsObj(ia,this,qn)}}},ie.prototype.mxWebAddEntityForMemorySections=function(ue,pt){var mt=new N.MxNetData(ue),Tt=mt.getMemorySectionsHead(),kt=(Tt.zeroLayerIdIndex,Tt.databaseIndex);pt!=-1&&(kt=pt);var It=Tt.nOffset,nn=this._blocks,tn=this._layers;kt!=0&&(nn=this._extRefManager.getBlocks(kt),tn=this._extRefManager.getLayers(kt));for(var pn=0;pn<Tt.datacount;pn++){var _n=mt.getMemorySectionHead(It);It=_n.offset;var Dn=new O.MxNewDisplayMemorySection;Dn.layerId=_n.layerId,Dn.blockId=_n.blkId,Dn.id=_n.memId,Dn.color=_n.memColor,Dn.type=_n.memType;var an=!1;Dn.type==O.MxNewDisplayMemorySectionType.kLinesType_Float?(an=!0,Dn.type=O.MxNewDisplayMemorySectionType.kLinesType):Dn.type==O.MxNewDisplayMemorySectionType.kTriangleType_Float?(an=!0,Dn.type=O.MxNewDisplayMemorySectionType.kTriangleType):Dn.type==O.MxNewDisplayMemorySectionType.kPointType_Float&&(an=!0,Dn.type=O.MxNewDisplayMemorySectionType.kPointType);var Rn=_n.pointCount;if(!(Rn<1)){for(var Lt=[],wn=0;wn<Rn;wn++)if(an){var hn=ue.getFloat32(It,!0);It+=4;var xn=ue.getFloat32(It,!0);It+=4,ue.getFloat32(It,!0),It+=4,Lt.push(hn,xn,0)}else hn=ue.getFloat64(It,!0),It+=8,xn=ue.getFloat64(It,!0),It+=8,ue.getFloat64(It,!0),It+=8,Lt.push(hn,xn,0);Dn.points=Lt;var $n=nn.crateBlock(Dn.blockId);$n.addMemorySections(Dn),nn.createThreejsObj($n,this,tn)}}},ie.prototype.convertBytesToUTF8=function(ue,pt){var mt=0;pt=Math.min(pt||ue.length,ue.length),ue[0]===239&&ue[1]===187&&ue[2]===191&&(mt=3);for(var Tt=[],kt=0;mt<pt;kt++){var It,nn,tn,pn=ue[mt++];if(pn===0)break;pn<128?Tt[kt]=String.fromCharCode(pn):194<=pn&&pn<224?(It=ue[mt++],Tt[kt]=String.fromCharCode(((31&pn)<<6)+(63&It))):224<=pn&&pn<240?(It=ue[mt++],nn=ue[mt++],Tt[kt]=String.fromCharCode(((15&pn)<<12)+((63&It)<<6)+(63&nn))):240<=pn&&pn<245&&(tn=((7&pn)<<18)+((63&(It=ue[mt++]))<<12)+((63&(nn=ue[mt++]))<<6)+(63&ue[mt++])-65536,Tt[kt]=String.fromCharCode(55296+(tn>>10),56320+(1023&tn)))}return Tt.join("")},ie.prototype.mxWebAddEntityFor2dPointTextureBuffers=function(ue,pt){var mt=new N.MxNetData(ue),Tt=mt.getdPointTextureBuffersHead(),kt=Tt.ver,It=(Tt.zeroLayerIdIndex,Tt.databaseIndex);pt!=-1&&(It=pt);for(var nn=Tt.datasize,tn=0;tn<Tt.datacount;tn++){var pn=mt.getdPointTextureBufferDataHead(nn);nn=pn.offset;var _n=pn.layerId,Dn=pn.blkId,an=pn.dataCount;if(!(an<1)){var Rn=0,Lt=this._blocks,wn=this._layers;It!=0&&(Lt=this._extRefManager.getBlocks(It),wn=this._extRefManager.getLayers(It));for(var hn=Lt.crateBlock(Dn);Rn<an;Rn++){var xn=ue.getFloat64(nn,!0);nn+=8;var $n=ue.getFloat64(nn,!0);nn+=8;var Xr=ue.getFloat64(nn,!0);nn+=8;var ti=ue.getUint32(nn,!0);nn+=4;var gn=ue.getUint32(nn,!0);nn+=4;var Xn=this.convertBytesToUTF8(new Uint8Array(ue.buffer.slice(nn,nn+gn)),void 0);nn+=gn;var Kn=[],Vn=[],Yn=[];if(!(ti<1)){for(var Vr=0;Vr<ti;Vr++){if(5<=kt){var xi=ue.getFloat64(nn,!0);nn+=8;var Si=ue.getFloat64(nn,!0);nn+=8,ue.getFloat64(nn,!0),nn+=8;var qn=ue.getFloat64(nn,!0);nn+=8;var ia=ue.getFloat64(nn,!0);nn+=8,ue.getFloat64(nn,!0),nn+=8;var Wi=ue.getFloat64(nn,!0);nn+=8;var ha=ue.getFloat64(nn,!0);nn+=8,ue.getFloat64(nn,!0),nn+=8,Kn.push(xi,Si),Kn.push(qn,ia),Kn.push(Wi,ha)}else xi=ue.getFloat32(nn,!0),nn+=4,Si=ue.getFloat32(nn,!0),nn+=4,qn=ue.getFloat32(nn,!0),nn+=4,ia=ue.getFloat32(nn,!0),nn+=4,Wi=ue.getFloat32(nn,!0),nn+=4,ha=ue.getFloat32(nn,!0),nn+=4,Kn.push(xi,Si),Kn.push(qn,ia),Kn.push(Wi,ha);var ai=ue.getInt32(nn,!0);nn+=4;var Ia=ue.getFloat32(nn,!0);nn+=4;var fi=ue.getFloat32(nn,!0);nn+=4;var An=ue.getFloat32(nn,!0);nn+=4;var sa=ue.getFloat32(nn,!0);nn+=4;var Nn=ue.getFloat32(nn,!0);nn+=4;var fn=ue.getFloat32(nn,!0);nn+=4;var un=ai>>24&255;ai=un==2||un==1?16777215:this.automaticInversionColor(16777215&ai),Yn.push(Ia,fi),Yn.push(An,sa),Yn.push(Nn,fn),Vn.push((255&ai)/255,(ai>>8&255)/255,(ai>>16&255)/255),Vn.push((255&ai)/255,(ai>>8&255)/255,(ai>>16&255)/255),Vn.push((255&ai)/255,(ai>>8&255)/255,(ai>>16&255)/255)}hn.addGeometryTexture(Kn,Yn,Vn,_n,Xn,xn,$n,Xr)}}Lt.createThreejsObj(hn,this,wn)}}},ie.prototype.mxWebAddEntityFor2dPointCurveBuffers=function(ue,pt){var mt=new N.MxNetData(ue),Tt=mt.getdPointCurveBuffersHead(),kt=Tt.zeroLayerIdIndex,It=Tt.databaseIndex;pt!=-1&&(It=pt);for(var nn=Tt.datasize,tn=0;tn<Tt.datacount;tn++){var pn=mt.getdPointCurveBufferDataHead(nn);nn=pn.offset;var _n=pn.layerId,Dn=_n==kt,an=pn.blkId,Rn=pn.pointCount;if(!(Rn<1)){for(var Lt=[],wn=[],hn=[],xn=[],$n=[],Xr=0;Xr<Rn;Xr++){var ti=ue.getFloat32(nn,!0);nn+=4;var gn=ue.getFloat32(nn,!0);nn+=4;var Xn=ue.getFloat32(nn,!0);nn+=4;var Kn=ue.getFloat32(nn,!0);nn+=4;var Vn=ue.getInt32(nn,!0);nn+=4;var Yn=Vn>>24&255;Yn==2?(xn.push(ti,gn),xn.push(Xn,Kn)):Yn==1?an!=0&&Dn?($n.push(ti,gn),$n.push(Xn,Kn)):(hn.push(ti,gn),hn.push(Xn,Kn)):(Lt.push(ti,gn),Lt.push(Xn,Kn),Vn=this.automaticInversionColor(16777215&Vn),wn.push((255&Vn)/255,(Vn>>8&255)/255,(Vn>>16&255)/255),wn.push((255&Vn)/255,(Vn>>8&255)/255,(Vn>>16&255)/255))}var Vr=this._blocks,xi=this._layers;It!=0&&(Vr=this._extRefManager.getBlocks(It),xi=this._extRefManager.getLayers(It));var Si=Vr.crateBlock(an);Si.addGeometryCurve(Lt,wn,_n,xn,hn,$n),Vr.createThreejsObj(Si,this,xi)}}},ie.prototype.mxWebAddEntityFor2dPointCurveBuffer=function(ue,pt){var mt=new N.MxNetData(ue);if(!mt.getIsSketchEntity()){var Tt,kt=mt.getLayerId(),It=kt==mt.getZeroLayerId(),nn=mt.getBlockId();if(!((Tt=ue.getInt32(20,!0)/20)<1)){for(var tn=80,pn=[],_n=[],Dn=[],an=[],Rn=[],Lt=0;Lt<Tt;Lt++){var wn=ue.getFloat32(tn,!0);tn+=4;var hn=ue.getFloat32(tn,!0);tn+=4;var xn=ue.getFloat32(tn,!0);tn+=4;var $n=ue.getFloat32(tn,!0);tn+=4;var Xr=ue.getInt32(tn,!0);tn+=4;var ti=Xr>>24&255;ti==2?(an.push(wn,hn),an.push(xn,$n)):ti==1?nn!=0&&It?(Rn.push(wn,hn),Rn.push(xn,$n)):(Dn.push(wn,hn),Dn.push(xn,$n)):(Xr=this.automaticInversionColor(16777215&Xr),pn.push(wn,hn),pn.push(xn,$n),_n.push((255&Xr)/255,(Xr>>8&255)/255,(Xr>>16&255)/255),_n.push((255&Xr)/255,(Xr>>8&255)/255,(Xr>>16&255)/255))}var gn=mt.getDatabaseIndex();pt!=-1&&(gn=pt);var Xn=this._blocks,Kn=this._layers;gn!=0&&(Xn=this._extRefManager.getBlocks(gn),Kn=this._extRefManager.getLayers(gn));var Vn=Xn.crateBlock(nn);Vn.addGeometryCurve(pn,_n,kt,an,Dn,Rn),Xn.createThreejsObj(Vn,this,Kn)}}},ie.prototype.mxWebAddEntityFor2dPointMeshBuffer=function(ue,pt){var mt=new N.MxNetData(ue);if(!mt.getIsSketchEntity()){var Tt,kt=mt.getLayerId(),It=mt.getBlockId(),nn=kt==mt.getZeroLayerId();if(!((Tt=ue.getInt32(12,!0)/28)<1)){for(var tn=80,pn=[],_n=[],Dn=[],an=[],Rn=[],Lt=0;Lt<Tt;Lt++){var wn=ue.getFloat32(tn,!0);tn+=4;var hn=ue.getFloat32(tn,!0);tn+=4;var xn=ue.getFloat32(tn,!0);tn+=4;var $n=ue.getFloat32(tn,!0);tn+=4;var Xr=ue.getFloat32(tn,!0);tn+=4;var ti=ue.getFloat32(tn,!0);tn+=4;var gn=ue.getInt32(tn,!0);tn+=4;var Xn=gn>>24&255;Xn==2?(an.push(wn,hn),an.push(xn,$n),an.push(Xr,ti)):Xn==1?It!=0&&nn?(Rn.push(wn,hn),Rn.push(xn,$n),Rn.push(Xr,ti)):(Dn.push(wn,hn),Dn.push(xn,$n),Dn.push(Xr,ti)):(pn.push(wn,hn),pn.push(xn,$n),pn.push(Xr,ti),gn=this.automaticInversionColor(16777215&gn),_n.push((255&gn)/255,(gn>>8&255)/255,(gn>>16&255)/255),_n.push((255&gn)/255,(gn>>8&255)/255,(gn>>16&255)/255),_n.push((255&gn)/255,(gn>>8&255)/255,(gn>>16&255)/255))}var Kn=mt.getDatabaseIndex();pt!=-1&&(Kn=pt);var Vn=this._blocks,Yn=this._layers;Kn!=0&&(Vn=this._extRefManager.getBlocks(Kn),Yn=this._extRefManager.getLayers(Kn));var Vr=Vn.crateBlock(It);Vr.addGeometryMesh(pn,_n,kt,an,Dn,Rn),Vn.createThreejsObj(Vr,this,Yn)}}},ie.prototype.mxWebCreateAllBlocks=function(ue,pt){var mt=new N.MxNetData(ue).getDatabaseIndex();pt!=-1&&(mt=pt);var Tt=this._blocks;mt!=0&&(Tt=this._extRefManager.getBlocks(mt)),Tt.createBlocks(ue,this.scene)},ie.prototype.mxWebEntitysData=function(ue,pt){pt==-1&&this._objectsOsnap.mxWebEntitysData(ue,pt)},ie.prototype.getObjectOsnap=function(){return this._objectsOsnap},ie.prototype.saveMxEntityToJson=function(ue){return this.m_mxDatabase.saveJson(ue)},ie.prototype.getDtabaseJsonString=function(){return JSON.stringify(this.m_mxDatabase.toJsonObject())},ie.prototype.loadMxEntityFromJson=function(ue){return this.m_mxDatabase.loadJson(ue)},ie);function ie(ue){this._is2d=!0,this._runMode=n.kBrowse,this._userCanvas=null,this._openFile="empty",this._staticLoadingOpenFiles=[],this._openFileExtName="",this._userIdentitySign="",this._rendererParam=void 0,this._userRandomToken="",this._isCreate=!1,this.m_iniSet={},this._net=null,this._staticNet=null,this._staticLoadTzNet=null,this._staticLocalNet=null,this._isStaticLocalLoad=!1,this._staticLocalLoadPath="",this._viewWidth=1,this._viewHeight=1,this.m_sysVariable=new q.MxSystemVariable,this._color="#FFFFFF",this._viewcolor=15790320,this._isAnimation=!1,this._isAnimationStarting=!1,this._isWaiteCount=0,this._callCreateCanvasImageData=void 0,this._event={},this.scene=null,this.camera=null,this.camera_recover=null,this.secenView=null,this.cameraView=null,this.renderer=null,this.controls=null,this.threejsselectObjectsView=null,this._mouseRightRotate=!1,this._isMouseMiddlePan=1,this._mapId2Entity=new Map,this._setAdyDelete=new Map,this._layers=new m.MxBrowseLayerData,this._blocks=new O.Blocks,this._extRefManager=new O.ExternalReferenceManager,this._doc2World=new y.Matrix4,this._word2doc=new y.Matrix4,this._cad2Doc=new y.Matrix4,this._doc2CAD=new y.Matrix4,this._word2Current=new y.Matrix4,this._current2word=new y.Matrix4,this._allLayoutName=new Array,this._devicePixelRatio=1,this._tzDwgStaticFile="",this._requestHeader="",this._objectsOsnap=null,this._initZoomwCoordPt1=null,this._initZoomWCoordPt2=null,this.m_mxDatabase=null,this._parentDocObject=null,this._parentDocObject_SmallCoord=null,this.threejsselectObjects=null,this.tempMarkDraw=new Te.MxTempMarkDraw,this._onResizeFun=null,this._sCurrentLoadURL="",this.eventManager=new Ue.MxDrawObjectEvent,this._viewangle=0,this.id=0,this.mcObject=new Ve.McDrawObject,this.isPointMultipleSelect=!1,this.isNewObjectMatrix=!0,this.bakControls=void 0,this.isMultipleSelect=!1,this.mxdrawThreeJS=null,this.curMousePostion=new y.Vector2(0,0),this.m_isValidCurMousePostion=!1,this._is2d=ue,this._blocks.initRootBlockRef(),this.m_iniSet[c.kEnableOsnapFunction]=!1,this.m_sysVariable.init(this),this.m_mxDatabase=new ve.MxDbDatabase,this.id=G.MxManager.allocId(),this.isMultipleSelect=Ae.MxDrawData.m_isMultipleSelect,this.mcObject.initMxObject(this)}l.MxDrawObject=Xe},{"./MxDrawData":22,"./MxDrawObjectEvent":26,"./MxFun":27,"./MxLocalFileLoad":28,"./MxManager":29,"./MxNetData":31,"./MxSystemVariable":35,"./MxTempMarkDraw":36,"./Operate/MxDrawObjectOsnap":49,"./UI/MxUiVue":65,"./View/MxBrowseDisplay":66,"./View/MxBrowseLayerData":67,"./View/MxDbDatabase":68,"./View/MxDbEntityGrip":70,"./View/MxDrawMapBox":75,"./cpp/McDrawObject":78,three:19}],24:[function(t,e,l){var n,u=this&&this.__extends||(n=function(ve,ne){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(Ue,De){Ue.__proto__=De}||function(Ue,De){for(var Ve in De)Object.prototype.hasOwnProperty.call(De,Ve)&&(Ue[Ve]=De[Ve])})(ve,ne)},function(ve,ne){function Ue(){this.constructor=ve}n(ve,ne),ve.prototype=ne===null?Object.create(ne):(Ue.prototype=ne.prototype,new Ue)});Object.defineProperty(l,"__esModule",{value:!0}),l.MxDrawObject2d=void 0;var c,y=t("three"),b=t("./MxFun"),m=t("./MxDrawObject"),O=t("three-orbitcontrols"),N=t("./MxNetData"),L=t("./MxMaterial"),G=t("./MxDrawData"),q=t("./View/MxDrawMapBox"),J=(u(fe,c=m.MxDrawObject),fe.prototype.set3DDraw=function(ve){this.is3DDraw=ve},fe.prototype.getOrthographicCamera=function(){return this.camera instanceof y.OrthographicCamera?this.camera:null},fe.prototype.getFullDisplayRange=function(){return{minPt:this._initMinDisplayPoint,maxPt:this._initMaxDisplayPoint}},fe.prototype.saveZoom=function(){this.camera_recover=this.camera.clone(!1),this.controls.saveState()},fe.prototype.recoverZoom=function(){this.camera_recover&&(this.camera.copy(this.camera_recover,!1),this.camera_recover=null,this.getOrthographicCamera().updateProjectionMatrix(),this.controls.reset(),this.mcObject.updateDisplayMatrixData())},fe.prototype.zoomW_call=function(ve,ne,Ue,De){if(ve.distanceTo(ne)<1e-7)console.log("Mx:ZoomW param invalid");else{if(Ue!=null&&Ue||(ve=this.currentCoord2World(ve.x,ve.y,0),ne=this.currentCoord2World(ne.x,ne.y,0)),ve.x>ne.x){var Ve=ve.x;ve.x=ne.x,ne.x=Ve}ve.y>ne.y&&(Ve=ve.y,ve.y=ne.y,ne.y=Ve);var rt=this.getViewWidth(),Ae=this.getViewHeight();Ae<5&&(Ae=5),rt<5&&(rt=5);var Te=Math.abs(ve.x-ne.x),Xe=Math.abs(ve.y-ne.y);Te<1e-5&&(Te=1e-5),Xe<1e-5&&(Xe=1e-5);var ie=this.getOrthographicCamera();if(Te/Xe<rt/Ae){var ue=.5*Xe,pt=rt/Ae;ie.left=-ue*pt,ie.right=ue*pt,ie.top=ue,ie.bottom=-ue}else ue=.5*Te,pt=Ae/rt,ie.left=-ue,ie.right=ue,ie.top=ue*pt,ie.bottom=-ue*pt;var mt=Te,Tt=Xe,kt=mt;kt<Tt&&(kt=Tt),this._runMode==m.MxRunMode.kCPPMxCAD?(ie.far=10240,ie.near=-10240):(ie.far=1e3*kt,ie.far<9e4&&(ie.far=9e4),ie.near=1e3*-kt,-9e4<ie.near&&(ie.near=-9e4));var It=ve.x+.5*mt,nn=ve.y+.5*Tt;ie.zoom=1,ie.position.set(It,nn,100),ie.lookAt(new y.Vector3(It,nn,0)),ie.updateProjectionMatrix(),this.controls.target.x=It,this.controls.target.y=nn,this.controls.target.z=0,this.controls.update(),this.mcObject.updateDisplayMatrixData(De)}},fe.prototype.zoomScale_call=function(ve){var ne=this.getOrthographicCamera();ne.zoom=Math.max(this.controls.minZoom,Math.min(this.controls.maxZoom,ne.zoom*ve)),ne.updateProjectionMatrix(),this.controls.update(),this.mcObject.updateDisplayMatrixData()},fe.prototype.zoomCenter_call=function(ve,ne){var Ue=this.getViewWidth(),De=this.getViewHeight(),Ve=this.screenCoord2World(0,0,0),rt=this.screenCoord2World(Ue,De,0),Ae=ve-(Ve.x+.5*(rt.x-Ve.x)),Te=ne-(Ve.y+.5*(rt.y-Ve.y));Ve.x+=Ae,Ve.y+=Te,rt.x+=Ae,rt.y+=Te,this.zoomW(Ve,rt)},fe.prototype.calcCameraUp=function(ve){var ne=new y.Vector3(0,1,0),Ue=new y.Matrix4;return Ue.makeRotationZ(ve),ne.applyMatrix4(Ue),ne},fe.prototype.updateCameraForm3dViewDataImp=function(ve){ve.updateCamera(this.getOrthographicCamera(),this.controls,this.getViewWidth(),this.getViewHeight()),this.mcObject.updateDisplayMatrixData(!1),this.controls.mouseButtons.LEFT=y.MOUSE.PAN,this.controls.mouseButtons.RIGHT=y.MOUSE.ROTATE,this.controls.mouseButtons.MIDDLE=y.MOUSE.PAN,this.controls.touches.ONE=y.TOUCH.ROTATE,this.controls.touches.TWO=y.TOUCH.PAN},fe.prototype.updateCameraDisplayRangeImp=function(ve,ne,Ue){this._initZoomwCoordPt1!=null&&this._initZoomWCoordPt2!=null?(this._initMinDisplayPoint=this.docCoord2World(this._initZoomwCoordPt1.x,this._initZoomwCoordPt1.y,0),this._initMaxDisplayPoint=this.docCoord2World(this._initZoomWCoordPt2.x,this._initZoomWCoordPt2.y,0)):(this._initMinDisplayPoint=ve,this._initMaxDisplayPoint=ne),this._viewangle=Ue,this.camera.up=this.calcCameraUp(Ue),this.cameraView.up=this.calcCameraUp(Ue),this.cameraView.updateProjectionMatrix(),this.zoomW(this._initMinDisplayPoint,this._initMaxDisplayPoint,!0)},fe.prototype.setViewAngle_call=function(ve){this._viewangle=ve;var ne=this.getOrthographicCamera();ne&&(ne.up=this.calcCameraUp(ve),ne.updateProjectionMatrix()),this.cameraView.up=this.calcCameraUp(ve),this.cameraView.updateProjectionMatrix(),this.controls.update(),this.mcObject.setViewAngle(ve),this.mcObject.updateDisplayMatrixData()},fe.prototype.zoomInitialStates=function(){this._initMinDisplayPoint!=null&&this._initMaxDisplayPoint!=null?(this.camera.up=this.calcCameraUp(this._viewangle),this.cameraView.up=this.calcCameraUp(this._viewangle),this.cameraView.updateProjectionMatrix(),this.zoomW(this._initMinDisplayPoint,this._initMaxDisplayPoint,!0)):console.log("mx assert(0)")},fe.prototype.onInitScene=function(){if(this.callInitSceneEvent(this.scene,this.controls,!0)==0){var ve=new y.AmbientLight(3355443,1);this.scene.add(ve);var ne=new y.DirectionalLight(16777215,1);ne.position.set(-2,2,3).normalize(),this.scene.add(ne)}},fe.prototype.updataCameraView=function(ve,ne){var Ue=ve,De=ne;this.cameraView.left=0,this.cameraView.right=Ue,this.cameraView.top=De,this.cameraView.bottom=0,this.cameraView.updateProjectionMatrix()},fe.prototype.onInitViewScene=function(){if(!this.secenView){this.secenView=new y.Scene,this._runMode!=m.MxRunMode.kCPPMxCAD&&this.mxdrawThreeJS.getType()!=q.MxThreeJSType.kMapBox&&(this.secenView.background=new y.Color(this._viewcolor));var ve=this.getViewWidth(),ne=this.getViewHeight();ve=this.xzSize(ve),ne=this.xzSize(ne),this.cameraView=new y.OrthographicCamera(0,ve,ne,0,1,2e3),this.cameraView.position.set(0,0,2e3),this.cameraView.lookAt(new y.Vector3(0,0,0)),this.cameraView.updateProjectionMatrix();var Ue=new y.AmbientLight(3355443,1);this.secenView.add(Ue);var De=new y.DirectionalLight(16777215,1);De.position.set(-2,2,3).normalize(),this.secenView.add(De),this.threejsselectObjectsView=new y.Object3D,this.secenView.add(this.threejsselectObjectsView)}},fe.prototype.onInitThreejs=function(){var ve=this.getViewWidth(),ne=this.getViewHeight(),Ue=(ve=this.xzSize(ve))/(ne=this.xzSize(ne))*50;this.onInitViewScene(),this.camera=new y.OrthographicCamera(Ue/-2,Ue/2,25,-25,-10240,10240),this.camera.position.set(0,0,200),this.scene=new y.Scene;var De=this.getUserCanvas(),Ve=this._rendererParam;Ve=Ve||{},De==null?(Ve.antialias=!1,Ve.stencil=!0,this.renderer=new y.WebGLRenderer(Ve),this.renderer.setClearColor(0,1),this.renderer.setPixelRatio(this._devicePixelRatio),this.renderer.setSize(ve,ne),document.body.appendChild(this.renderer.domElement)):(Ve.canvas=De,Ve.stencil=!0,this.renderer=new y.WebGLRenderer(Ve),this.renderer.setClearColor(0,1),this.renderer.setPixelRatio(this._devicePixelRatio)),this.renderer.sortObjects=!0,this.renderer.info.autoReset=G.MxDrawData.m_isAutoResetRenderer,this.renderer.info.reset();var rt=this.getUserCanvas();rt==null&&(rt=this.renderer.domElement),this.controls=new O.OrbitControls(this.camera,rt),this.is3DDraw||(this.controls.enableZoom=!0),b.MxFun.isPC()?(this.controls.zoomSpeed=4,this.controls.screenSpacePanning=!0,this.setMouseMiddlePan(this._isMouseMiddlePan),this._mouseRightRotate&&(this.controls.mouseButtons.RIGHT=y.MOUSE.ROTATE)):(this.controls.zoomSpeed=1.5,this.controls.touches.ONE=y.TOUCH.PAN,this.controls.screenSpacePanning=!0)},fe.prototype.onCreate=function(){this._is2d=!0,this.mxdrawThreeJS.onInitScene()},fe.prototype.mxWebAddEntity_3DChild=function(ve){var ne=new N.MxNetData(ve).getMesh();if(ne.id==null)return ne.size;var Ue=new y.Mesh(ne.geometry,L.MxMaterial.GetBaseColorMaterial(ne.nColorIndex));return this.removeEntity(ne.id),this.scene.add(Ue),ne.isSketchEntity&&this.addEntity(ne.id,Ue),ne.size},fe.prototype.mxWebAddEntity_Curve=function(ve,ne){var Ue=new N.MxNetData(ve).getCurve(ne);if(Ue.id!=null){var De=L.MxMaterial.GetCurveColorMaterial(Ue.colorIndex),Ve=new y.LineSegments(Ue.geometry,De);this.removeEntity(Ue.id),this.scene.add(Ve),Ue.isSketchEntity&&this.addEntity(Ue.id,Ve)}},fe.prototype.onViewChange=function(){this._onResizeImpCalling||(this._bakOnResizeViewWorldCoord=void 0)},fe.prototype.mapBox_onResizeImp=function(ve,ne){var Ue=ve,De=ne;this.mcObject.setSize(Ue,De),this.callEvent("viewsizechange",{width:Ue,height:De}),this.callEvent("viewchange"),this.m_mxDatabase.getSelectManager().setCanvasSize(Ue,De)},fe.prototype.callOnResizeImp=function(ve,ne){var Ue;this._bakOnResizeViewWorldCoord?Ue=this._bakOnResizeViewWorldCoord:(Ue=this.getViewWorldCoord(),this._bakOnResizeViewWorldCoord=Ue);var De=Ue.pt1.x+.5*(Ue.pt3.x-Ue.pt1.x),Ve=Ue.pt1.y+.5*(Ue.pt3.y-Ue.pt1.y),rt=new y.Matrix4;rt.makeRotationZ(this._viewangle);var Ae=new y.Matrix4().makeTranslation(De,Ve,0).multiply(rt).multiply(new y.Matrix4().makeTranslation(-De,-Ve,0)),Te=Ue.pt1.clone(),Xe=Ue.pt2.clone(),ie=Ue.pt3.clone(),ue=Ue.pt4.clone();Te.applyMatrix4(Ae),Xe.applyMatrix4(Ae),ie.applyMatrix4(Ae),ue.applyMatrix4(Ae);var pt=Te.clone();pt.x>Xe.x&&(pt.x=Xe.x),pt.x>ie.x&&(pt.x=ie.x),pt.x>ue.x&&(pt.x=ue.x),pt.y>Xe.y&&(pt.y=Xe.y),pt.y>ie.y&&(pt.y=ie.y),pt.y>ue.y&&(pt.y=ue.y);var mt=Te.clone();mt.x<Xe.x&&(mt.x=Xe.x),mt.x<ie.x&&(mt.x=ie.x),mt.x<ue.x&&(mt.x=ue.x),mt.y<Xe.y&&(mt.y=Xe.y),mt.y<ie.y&&(mt.y=ie.y),mt.y<ue.y&&(mt.y=ue.y);var Tt=new y.Vector2;if(this.renderer.getSize(Tt),Tt.x==ve&&Tt.y==ne)return!1;var kt=this.getOrthographicCamera(),It=Math.abs(mt.x-pt.x),nn=Math.abs(mt.y-pt.y);if(It<1e-5&&(It=1e-5),nn<1e-5&&(nn=1e-5),It/nn<ve/ne){var tn=.5*nn,pn=ve/ne;kt.left=-tn*pn,kt.right=tn*pn,kt.top=tn,kt.bottom=-tn}else tn=.5*It,pn=ne/ve,kt.left=-tn,kt.right=tn,kt.top=tn*pn,kt.bottom=-tn*pn;var _n=pt.x+.5*It,Dn=pt.y+.5*nn;kt.zoom=1;var an=kt.position.z;return kt.position.set(_n,Dn,an),kt.lookAt(new y.Vector3(_n,Dn,0)),kt.updateProjectionMatrix(),this.controls.target.x=_n,this.controls.target.y=Dn,this.controls.target.z=0,this.controls.update(),!0},fe.prototype.onResizeImp=function(ve,ne){var Ue=this.getViewWidth();ve!=null&&(Ue=ve);var De=this.getViewHeight();if(ne!=null&&(De=ne),De<5||Ue<5)return!1;Ue=this.xzSize(Ue),De=this.xzSize(De),this._onResizeImpCalling=!0;var Ve=this.mcObject.mxdraw3d.onResize(this.getOrthographicCamera(),this.controls,Ue,De);return Ve&&(this.renderer.setSize(Ue,De),this.mcObject.setSize(Ue,De),this.updataClipMaterial(),this.updataCameraView(Ue,De),this.callEvent("viewsizechange",{width:Ue,height:De}),this.callEvent("viewchange"),this.m_mxDatabase.getSelectManager().setCanvasSize(Ue,De),this.m_mxDatabase.onViewChange()),this._onResizeImpCalling=!1,Ve},fe);function fe(){var ve=c.call(this,!0)||this;return ve._initMinDisplayPoint=null,ve._initMaxDisplayPoint=null,ve.is3DDraw=b.MxFun.is3DDwg(),ve._bakOnResizeViewWorldCoord=void 0,ve._onResizeImpCalling=!1,ve}l.MxDrawObject2d=J},{"./MxDrawData":22,"./MxDrawObject":23,"./MxFun":27,"./MxMaterial":30,"./MxNetData":31,"./View/MxDrawMapBox":75,three:19,"three-orbitcontrols":17}],25:[function(t,e,l){var n,u=this&&this.__extends||(n=function(J,fe){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ve,ne){ve.__proto__=ne}||function(ve,ne){for(var Ue in ne)Object.prototype.hasOwnProperty.call(ne,Ue)&&(ve[Ue]=ne[Ue])})(J,fe)},function(J,fe){function ve(){this.constructor=J}n(J,fe),J.prototype=fe===null?Object.create(fe):(ve.prototype=fe.prototype,new ve)});Object.defineProperty(l,"__esModule",{value:!0}),l.MxDrawObject3d=void 0;var c,y=t("three"),b=t("./MxDrawObject"),m=t("three-orbitcontrols"),O=t("./MxNetData"),N=t("./MxMaterial"),L=t("./MxTools"),G=(u(q,c=b.MxDrawObject),q.prototype.mxWebAddEntity_Curve=function(J,fe){var ve,ne=new O.MxNetData(J),Ue=J.getInt32(32,!0)==0,De=ne.getIsSketchEntity();if(!((ve=Ue?J.getInt32(20,!0)/4/3:J.getInt32(20,!0)/4/2)<2)){for(var Ve=new y.Geometry,rt=fe,Ae=0;Ae<ve;Ae++){var Te=J.getFloat32(rt,!0);rt+=4;var Xe=J.getFloat32(rt,!0);rt+=4;var ie=0;Ue&&(ie=J.getFloat32(rt,!0),rt+=4),Ve.vertices.push(L.MxTools.AsThreeJsPoint(Te,Xe,ie))}var ue=J.getInt32(28,!0),pt=N.MxMaterial.GetCurveColorMaterial(ue),mt=new y.LineSegments(Ve,pt),Tt=J.getInt32(4,!0);this.removeEntity(Tt),this.scene.add(mt),De&&this.addEntity(Tt,mt)}},q.prototype.mxWebAddEntity_3DChild=function(J){var fe=new O.MxNetData(J),ve=fe.getId(),ne=(fe.getColorIndex(),fe.getBufferType()==0),Ue=fe.getIsSketchEntity();this.removeEntity(ve);var De=new y.Mesh(new y.Geometry),Ve=this.mxWebUpdateEntity_3DChild(De,J,ne);return this.scene.add(De),Ue&&this.addEntity(ve,De),De.geometry.computeBoundingBox(),De.geometry.computeBoundingSphere(),Ve},q.prototype.mxWebUpdateEntity_3DChild=function(J,fe,ve){var ne=new O.MxNetData(fe),Ue=ne.getVertexBufferSize(),De=ne.getIndexBufferSize(),Ve=ne.getColorIndex();if(Ue===0||De===0)return ne.getDrawDataOffset();var rt=ne.getMateria(),Ae=void 0,Te=!0,Xe=!1,ie=!1;rt.length!=0&&((Ae=JSON.parse(rt)).computeFaceNonmal!=null&&(Te=Ae.computeFaceNonmal),Ae.castShadow!=null&&(Xe=Ae.castShadow),Ae.receiveShadow!=null&&(ie=Ae.receiveShadow)),J.material=N.MxMaterial.createMaterial(Ae),J.material==null&&(J.material=N.MxMaterial.GetColorMaterial(Ve)),J.castShadow=Xe,J.receiveShadow=ie;var ue,pt=ne.getDrawDataOffset();ue=ve?Ue/4/8:Ue/4/2;var mt=J.geometry;mt.vertices=[],mt.faces=[];for(var Tt=0;Tt<ue;Tt++){var kt=fe.getFloat32(pt+0,!0),It=fe.getFloat32(pt+4,!0),nn=0,tn=0,pn=0,_n=0,Dn=0,an=0;ve?(nn=fe.getFloat32(pt+8,!0),tn=fe.getFloat32(pt+12,!0),pn=fe.getFloat32(pt+16,!0),_n=fe.getFloat32(pt+20,!0),Dn=fe.getFloat32(pt+24,!0),an=fe.getFloat32(pt+28,!0),pt+=32):pt+=8;var Rn=L.MxTools.AsThreeJsPoint(kt,It,nn);mt.vertices.push(Rn),mt.vertices[Tt].normal=L.MxTools.AsThreeJsPoint(tn,pn,_n),mt.vertices[Tt].uv=new y.Vector2(Dn,an)}var Lt=De/4;for(Tt=0;Tt<Lt;Tt+=3){var wn=fe.getInt32(pt,!0);pt+=4;var hn=fe.getInt32(pt,!0);pt+=4;var xn=fe.getInt32(pt,!0);pt+=4;var $n=new y.Face3(wn,hn,xn);Te||$n.vertexNormals.push(mt.vertices[wn].normal,mt.vertices[hn].normal,mt.vertices[xn].normal),mt.faces.push($n),mt.faceVertexUvs[0].push([mt.vertices[wn].uv,mt.vertices[hn].uv,mt.vertices[xn].uv])}return Te&&mt.computeFaceNormals(),pt},q.prototype.updateUVs=function(J){J.faceVertexUvs[0]=[],J.faces.forEach(function(fe){var ve=["x","y","z"].sort(function(Te,Xe){return Math.abs(fe.normal[Te])-Math.abs(fe.normal[Xe])}),ne=J.vertices[fe.a],Ue=J.vertices[fe.b],De=J.vertices[fe.c],Ve=new y.Vector2(ne[ve[0]],ne[ve[1]]),rt=new y.Vector2(Ue[ve[0]],Ue[ve[1]]),Ae=new y.Vector2(De[ve[0]],De[ve[1]]);J.faceVertexUvs[0].push([Ve,rt,Ae])}),J.uvsNeedUpdate=!0},q.prototype.onInitThreejs=function(){var J=this.getViewWidth(),fe=this.getViewHeight(),ve=(J=this.xzSize(J))/(fe=this.xzSize(fe))*50;this.camera=new y.OrthographicCamera(ve/-2,ve/2,25,-25,1,1e3),this.camera.position.set(-200,200,200),this.scene=new y.Scene,this.scene.background=new y.Color(this._viewcolor);var ne=this.getUserCanvas();ne==null?(this.renderer=new y.WebGLRenderer({antialias:!0,alpha:!0}),this.renderer.setPixelRatio(this._devicePixelRatio),this.renderer.setSize(J,fe),document.body.appendChild(this.renderer.domElement)):(this.renderer=new y.WebGLRenderer({canvas:ne,antialias:!0,alpha:!0}),this.renderer.setPixelRatio(this._devicePixelRatio));var Ue=this.getUserCanvas();Ue==null&&(Ue=this.renderer.domElement),this.controls=new m.OrbitControls(this.camera,Ue)},q.prototype.onInitViewScene=function(){},q.prototype.onInitScene=function(){if(this.callInitSceneEvent(this.scene,this.controls,!1)==0){var J=new y.AmbientLight(2236962);J.integrity=1,this.scene.add(J);var fe=new y.DirectionalLight(16777215,1);fe.position.set(-2,2,3).normalize(),this.scene.add(fe);var ve=new y.GridHelper(2e3,100);ve.position.y=-199,ve.material.opacity=.25,ve.material.transparent=!0,this.scene.add(ve);var ne=new y.AxesHelper(20);this.scene.add(ne)}},q.prototype.onCreate=function(){this._is2d=!1,this.callEvent("initRenderer",this.renderer),this.mxdrawThreeJS.onInitScene()},q.prototype.getOrthographicCamera=function(){return this.camera instanceof y.OrthographicCamera?this.camera:null},q.prototype.onViewChange=function(){},q.prototype.callOnResizeImp=function(J,fe){return!1},q.prototype.onResizeImp=function(J,fe){var ve=this.getViewWidth();J!=null&&(ve=J);var ne=this.getViewHeight();fe!=null&&(ne=fe),ve=this.xzSize(ve),ne=this.xzSize(ne);var Ue=this.getOrthographicCamera(),De=ve/ne;return Ue.left=50*De/-2,Ue.right=50*De/2,Ue.top=25,Ue.bottom=-25,Ue.updateProjectionMatrix(),this.renderer.setSize(ve,ne),!0},q.prototype.zoomInitialStates=function(){},q.prototype.saveZoom=function(){},q.prototype.recoverZoom=function(){},q.prototype.zoomScale_call=function(J){},q.prototype.zoomW_call=function(J,fe,ve,ne){},q.prototype.zoomCenter_call=function(J,fe){},q.prototype.setViewAngle_call=function(J){this._viewangle=J},q.prototype.getFullDisplayRange=function(){return{}},q);function q(){var J=c.call(this,!1)||this;return J._viewcolor=15790320,J}l.MxDrawObject3d=G},{"./MxDrawObject":23,"./MxMaterial":30,"./MxNetData":31,"./MxTools":38,three:19,"three-orbitcontrols":17}],26:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxDrawObjectEvent=l.MxDrawObjectEventDefautProc=void 0;var n=t("./MxFun"),u=t("./Operate/MxJigCmdManager"),c=t("three"),y=t("./UI/MxUiVue"),b=t("./MxDrawData"),m=(O.prototype.onMousemove=function(G){if(y.MxUiVue.isNull())return 0;var q=this.mxObj.screenCoord2Doc(G.offsetX,G.offsetY,0);return q=this.mxObj.docCoord2Cad(q.x,q.y,q.z),y.MxUiVue.setTipCoord(n.MxFun.formatString("{0},{1},0.000",q.x.toFixed(3),q.y.toFixed(3))),0},O.prototype.isEnableIntelliSelect=function(){return!!b.MxDrawData.m_isEnableIntelliSelect&&!this.mxObj.is3DMode()},O.prototype.onTouchStart=function(G){if(this.isEnableIntelliSelect()&&!u.MxJigCmdManager.isRunning()&&!this.mxObj.isPaningCommand()&&G.touches.length==1){var q=G.target.getBoundingClientRect(),J=G.touches[0].clientX-q.left,fe=G.touches[0].clientY-q.top,ve=this.mxObj,ne=ve.screenCoord2Current(J,fe,0);if(!(ve.getMxDatabase().getGripManager().onMouseLBDown(ne)||ve.isValidMcObject()&&ve.getMcObject().getGripManager().onMouseLBDown(ne))){var Ue=new c.Vector3(J,fe,0);return n.MxFun.sendStringToExecute("Mx_FrontEndWebpageIntelliSel",{pt:Ue}),1}}return 0},O.prototype.onMousdown=function(G){if(G.button==u.MxJigCmdManager.MouseButton.kRight&&u.MxJigCmdManager.isRunning())return u.MxJigCmdManager.OnEnter(-1),G.stopPropagation(),0;if(this.isEnableIntelliSelect()&&G.button==u.MxJigCmdManager.MouseButton.kLeft&&!u.MxJigCmdManager.isRunning()&&!this.mxObj.isPaningCommand()){var q=this.mxObj,J=q.screenCoord2Current(G.offsetX,G.offsetY,0);if(!(q.getMxDatabase().getGripManager().onMouseLBDown(J)||q.isValidMcObject()&&q.getMcObject().getGripManager().onMouseLBDown(J))){var fe=new c.Vector3(G.offsetX,G.offsetY,0);return n.MxFun.sendStringToExecute("Mx_FrontEndWebpageIntelliSel",{pt:fe}),1}}return 0},O.prototype.init=function(G,q){this.mxObj=G;var J=this;q.addEventListener("mousemove",function(fe){return J.onMousemove(fe)}),q.addEventListener("mousedown",function(fe){return J.onMousdown(fe)}),q.addEventListener("touchstart",function(fe){return J.onTouchStart(fe)})},O);function O(){}l.MxDrawObjectEventDefautProc=m;var N=(L.prototype.onMousedown=function(G,q){this.callEvent("mousedown",G,q)},L.prototype.onMousemove=function(G,q){this.callEvent("mousemove",G,q)},L.prototype.onMouseup=function(G,q){this.callEvent("mouseup",G,q)},L.prototype.registEvent=function(G){var q=G.getMxDrawThreeJs().getRegistEventObject();if(!q)return!1;var J=this;n.MxFun.isPC()?(q.addEventListener("mouseup",function(fe){var ve=G.getMxDrawThreeJs().getDomMousePos(fe);J.onMouseup(fe,ve)},!0),q.addEventListener("mousemove",function(fe){var ve=G.getMxDrawThreeJs().getDomMousePos(fe);G.setCurrentMousePostion(fe),J.onMousemove(fe,ve)},!0),q.addEventListener("mousedown",function(fe){var ve=G.getMxDrawThreeJs().getDomMousePos(fe);G.setCurrentMousePostion(fe),J.onMousedown(fe,ve)},!0)):(q.addEventListener("touchstart",function(fe){G.setCurrentMousePostion(fe,!0),J.callEvent("touchstart",fe)},!0),q.addEventListener("touchend",function(fe){J.callEvent("touchend",fe)},!0),q.addEventListener("touchmove",function(fe){G.setCurrentMousePostion(fe,!0),J.callEvent("touchmove",fe)},!0)),this.defautProc.init(G,this)},L.prototype.getEventCall=function(G){var q;return G=="mousemove"?q=this.aryMousemoveEventCall:G=="mouseup"?q=this.aryMouseupEventCall:G=="mousedown"?q=this.aryMousedownEventCall:G=="touchstart"?q=this.aryTouchstartEventCall:G=="touchend"?q=this.aryTouchendEventCall:G=="touchmove"&&(q=this.aryTouchmoveEventCall),q},L.prototype.callEvent=function(G,q,J){var fe=this.getEventCall(G);if(fe){for(var ve=fe.slice(),ne=0,Ue=ve.length;ne<Ue;ne++){var De=ve[ne](q,J);if(De==1)return De}return 0}},L.prototype.addEventListener=function(G,q,J){J===void 0&&(J=!1);var fe=this.getEventCall(G);return!!fe&&(-1<fe.indexOf(q)||(J?fe.unshift(q):fe.push(q)),!0)},L.prototype.removeEventListener=function(G,q){var J=this.getEventCall(G);if(!J)return!1;var fe=J.indexOf(q);return-1<fe&&(J.splice(fe,1),!0)},L);function L(){this.aryMousedownEventCall=[],this.aryMouseupEventCall=[],this.aryMousemoveEventCall=[],this.aryTouchstartEventCall=[],this.aryTouchendEventCall=[],this.aryTouchmoveEventCall=[],this.defautProc=new m}l.MxDrawObjectEvent=N},{"./MxDrawData":22,"./MxFun":27,"./Operate/MxJigCmdManager":54,"./UI/MxUiVue":65,three:19}],27:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxFun=void 0;var n,u,c,y,b,m,O,N,L,G,q,J,fe,ve,ne,Ue=t("three"),De=t("./MxManager"),Ve=t("./MxDrawObject"),rt=t("./MxDrawObject2d"),Ae=t("./MxDrawObject3d"),Te=t("./UI/MxUiObjectMobile"),Xe=t("./UI/MxUiObjectPC"),ie=t("./Operate/MxJigCmdManager"),ue=t("./Operate/MxJigGetLine"),pt=t("./Operate/MxCmdRunManager"),mt=t("./UI/MxUiVue"),Tt=t("./MxThreeJS"),kt=t("./MxWindowsEvent"),It=t("./MxTools"),nn=t("./MxDrawCommands"),tn=t("./MxDrawData"),pn=t("./MxLocalFileLoad"),_n=t("./TempTest/MxTestJig"),Dn=t("./MxVersion"),an=t("./MrxDbgUtils");function Rn(gn){gn.cmd&&Xr(gn.cmd)}function Lt(gn){var Xn=new RegExp("(^|&)"+gn+"=([^&]*)(&|$)"),Kn=window.location.href,Vn=Kn.indexOf("?"),Yn=(Kn=Vn==-1?"":Kn.substring(Vn)).substr(1).match(Xn);return Yn!=null?decodeURIComponent(Yn[2]):""}function wn(){return De.MxManager.currentMx()}function hn(gn,Xn){var Kn={};if(gn!=null)if(gn instanceof Array)Kn.is2d=!0;else{gn.length==0&&(gn="empty");var Vn=gn.substring(gn.lastIndexOf(".")+1).toLowerCase();if(Vn!="dwg"&&Vn!="dxf"&&Vn!="dwf"&&Vn!="mwg"&&Vn!="wgh"||(Kn.is2d=!0),Xn!=1&&Xn!=null&&Vn!="wgh"){var Yn=void 0,Vr=gn.split("/");(Yn=Vr.length==1?Vr[0]:Vr[Vr.length-1])[0]=="$"&&(Yn=Yn.substring(1));for(var xi=void 0,Si=0;Si<Vr.length-1;Si++)xi=Si==0?Vr[Si]:xi+"/"+Vr[Si];gn=xi?xi+"/$"+Yn+".mxb1.wgh":"$"+Yn+".mxb1.wgh"}}else gn="empty_template.dwg";return Kn.sFileName=gn,Kn}function xn(gn){if(typeof gn=="string"){var Xn=gn.substring(gn.lastIndexOf(".")+1).toLowerCase();if(Xn!="dwg"&&Xn!="wgh"){var Kn=gn.lastIndexOf("?");if(Kn!=-1){var Vn=gn.substring(Kn,gn.length);return{sFileName:gn=gn.substring(0,Kn),sUrlParam:Vn}}}}return null}function $n(){return ie.MxJigCmdManager.stopCmd(ie.MxJigCmdManager.DetailedResult.kUnknown)}function Xr(gn,Xn){if(gn.length!=0){var Kn=wn();return pt.MxCmdRunManager.runCmd(Kn,gn,Xn)}$n()}function ti(gn){gn!=null&&(gn.init(),mt.MxUiVue.init(gn)),q||(console.log("MxDraw Version:"+Dn.MxBulid.getVersion()),q=!0,ve=new pn.MxLocalNodeJs,ie.MxJigCmdManager.init(),kt.MxWindowsEvent.registEvent(),nn.MxDrawCommands.registerCommand(),window.mxConfig_isLoadTest&&_n.MxTest.registerCommand(),fe.sendStringToExecute=Rn)}n=l.MxFun||(l.MxFun={}),u=".",G=null,q=!(L="ws://localhost:5090"),fe={},ve=J=N=m=c=void 0,ne=O=b=y=-1,n.getUiObj=function(){return G},n.on=function(gn,Xn){De.MxManager.on(gn,Xn)},n.callEvent=function(gn,Xn){return De.MxManager.callEvent(gn,Xn)},n.getNodeJs=function(){return ve},n.setMxServer=function(gn){L=gn},n.getMxServer=function(){return L},n.isPC=function(){return ne==-1?function(){if(!/Android|webOS|iPhone|iPod|BlackBerry/i.test(navigator.userAgent)){var gn=navigator.userAgent.toLowerCase();return 0<=gn.indexOf("win64")||0<=gn.indexOf("wow64")||0<=gn.indexOf("win32")||0<=gn.indexOf("wow32")||/macintosh|mac os x/i.test(navigator.userAgent)||!("ontouchstart"in window||0<navigator.maxTouchPoints)}}()?(ne=1,!0):(ne=0,!1):ne==1},n.getClientPlatform=function(){return navigator.platform},n.getClientInfo=function(){return{width:document.body.clientWidth,height:document.body.clientHeight}},n.curPath=function(){return u},n.setCurPath=function(gn){u=gn},n.getQueryString=Lt,n.getLocationPageUrl=function(){var gn=window.location.href,Xn=gn.lastIndexOf("?");return Xn==-1?gn:gn.substring(0,Xn)},n.getHostUrl=function(){var gn=window.location.hostname;return gn.substring(0,4)!="http"&&(gn="http://"+gn),gn},n.isAbsoluteWebPath=function(gn){return gn.substring(0,4)=="http"},n.getUrlParams=function(){var gn=window.location.search,Xn=gn.substr(1,gn.length).split("&"),Kn=new Array;if(Xn!=null)for(var Vn=0;Vn<Xn.length;Vn++){var Yn=Xn[Vn].replace(/[=|^==]/,"&").split("&");if(1<Yn.length){var Vr=new Array;Vr.push(decodeURIComponent(Yn[0])),Vr.push(decodeURIComponent(Yn[1])),Kn.push(Vr)}}return Kn},n.call=function(gn,Xn,Kn){Xn==null?Xn="{}":typeof Xn=="string"?Xn.length==0?Xn="{}":Xn[0]=="["&&Xn[Xn.length-1]=="]"||Xn[0]=="{"&&Xn[Xn.length-1]=="}"||(Xn='"'+(Xn=Xn.replace(/"/g,"'"))+'"'):Xn=typeof Xn=="object"?JSON.stringify(Xn):"{}",De.MxManager.currentMx().call(gn,Xn,Kn)},n.loadCodeToServer=function(gn,Xn){De.MxManager.currentMx().loadCodeToServer(gn,Xn)},n.getCurrentMx=function(){return De.MxManager.currentMx()},n.isEnableSelect=function(){if(y!=-1)return y==1;var gn=Lt("select");return y=0,gn!=null&&gn.toLowerCase()=="y"&&(y=1),y==1},n.is3DDwg=function(){if(O!=-1)return O==1;var gn=Lt("3ddwg");return O=0,gn!=null&&gn.toLowerCase()=="y"&&(O=1),O==1},n.isStaticLoad=function(){if(b!=-1)return b==1;var gn=Lt("static");return b=0,gn!=null&&gn.toLowerCase()=="y"&&(b=1),b==1},n.enableSelect=function(gn){y=gn?1:0},n.enablStaticLoad=function(gn){b=gn==null||gn?1:0},n.dwgDir=function(){return m!=null||(m=Lt("dwgdir"))==null&&(m=""),m},n.setDwgDir=function(gn){m=gn},n.getStaticServer=function(){return N!=null||(N=Lt("staticServer"))==null&&(N=""),N},n.setStaticServer=function(gn){N=gn},n.is2dParam=function(){if(c!=null)return c;var gn=Lt("file");if(c=!1,gn!=null){var Xn=gn.substring(gn.lastIndexOf(".")+1);Xn.toLowerCase()!="dwg"&&Xn.toLowerCase()!="dxf"&&Xn.toLowerCase()!="dwf"&&Xn.toLowerCase()!="mwg"||(c=!0)}return c},n.set2dParam=function(gn){c=gn},n.showLayer=function(gn,Xn){return De.MxManager.currentMx().showLayer(gn,Xn)},n.screenCoord2World=function(gn,Xn,Kn){return gn instanceof Object?De.MxManager.currentMx().screenCoord2World(gn.x,gn.y,gn.z):De.MxManager.currentMx().screenCoord2World(gn,Xn,Kn)},n.worldCoord2Screen=function(gn,Xn,Kn){return gn instanceof Object?De.MxManager.currentMx().worldCoord2Screen(gn.x,gn.y,gn.z):De.MxManager.currentMx().worldCoord2Screen(gn,Xn,Kn)},n.docCoord2Cad=function(gn,Xn,Kn){return gn instanceof Object?De.MxManager.currentMx().docCoord2Cad(gn.x,gn.y,gn.z):De.MxManager.currentMx().docCoord2Cad(gn,Xn,Kn)},n.cadCoord2Doc=function(gn,Xn,Kn){return gn instanceof Object?De.MxManager.currentMx().cadCoord2Doc(gn.x,gn.y,gn.z):De.MxManager.currentMx().cadCoord2Doc(gn,Xn,Kn)},n.docCoord2World=function(gn,Xn,Kn){return gn instanceof Object?De.MxManager.currentMx().docCoord2World(gn.x,gn.y,gn.z):De.MxManager.currentMx().docCoord2World(gn,Xn,Kn)},n.worldCoord2Doc=function(gn,Xn,Kn){return gn instanceof Object?De.MxManager.currentMx().worldCoord2Doc(gn.x,gn.y,gn.z):De.MxManager.currentMx().worldCoord2Doc(gn,Xn,Kn)},n.screenCoord2Doc=function(gn,Xn,Kn){return gn instanceof Object?De.MxManager.currentMx().screenCoord2Doc(gn.x,gn.y,gn.z):De.MxManager.currentMx().screenCoord2Doc(gn,Xn,Kn)},n.docCoord2Screen=function(gn,Xn,Kn){return gn instanceof Object?De.MxManager.currentMx().docCoord2Screen(gn.x,gn.y,gn.z):De.MxManager.currentMx().docCoord2Screen(gn,Xn,Kn)},n.docCoordLong2Cad=function(gn){return De.MxManager.currentMx().docCoordLong2Cad(gn)},n.cadCoordLong2Doc=function(gn){return De.MxManager.currentMx().cadCoordLong2Doc(gn)},n.viewCoordLong2Cad=function(gn){return De.MxManager.currentMx().viewCoordLong2Cad(gn)},n.cadCoordLong2View=function(gn){return De.MxManager.currentMx().cadCoordLong2View(gn)},n.zoomCenter=function(gn,Xn){De.MxManager.currentMx().is2D()&&(De.MxManager.currentMx().zoomCenter(gn,Xn),De.MxManager.currentMx().updateDisplay())},n.zoomW=function(gn,Xn,Kn,Vn,Yn){De.MxManager.currentMx().is2D()&&(De.MxManager.currentMx().zoomW(new Ue.Vector3(gn,Xn,0),new Ue.Vector3(Kn,Vn,0),Yn),De.MxManager.currentMx().updateDisplay())},n.zoomScale=function(gn){De.MxManager.currentMx().is2D()&&(De.MxManager.currentMx().zoomScale(gn),De.MxManager.currentMx().updateDisplay())},n.zoomAll=function(){De.MxManager.currentMx().is2D()&&(De.MxManager.currentMx().zoomAll(),De.MxManager.currentMx().updateDisplay())},n.deleteAll=function(){return De.MxManager.currentMx().deleteAll()},n.callCommand=function(gn,Xn,Kn){De.MxManager.currentMx().callCommand(gn,Xn,Kn)},n.getCurrentColor=function(){return De.MxManager.currentMx().getCurrentColor()},n.setCurrentColor=function(gn){De.MxManager.currentMx().setCurrentColor(gn)},n.showLoading=function(){G?.ShowLoading()},n.hideLoading=function(){G?.HideLoading()},n.showProp=function(gn){G?.ShowObjectProperty(gn)},n.hideProp=function(){G?.HideObjectProp()},n.getUiObject=function(){return G},n.getViewCenterDocCoord=function(){return De.MxManager.currentMx().is2D()?De.MxManager.currentMx().getViewCenterDocCoord():new Ue.Vector3(0,0,0)},n.screenCoordLong2Doc=function(gn){return De.MxManager.currentMx().is2D()?De.MxManager.currentMx().screenCoordLong2Doc(gn):gn},n.docCoordLong2Screen=function(gn){return De.MxManager.currentMx().is2D()?De.MxManager.currentMx().docCoordLong2Screen(gn):gn},n.worldCoordLong2Doc=function(gn){return De.MxManager.currentMx().is2D()?De.MxManager.currentMx().worldCoordLong2Doc(gn):gn},n.docCoordLong2World=function(gn){return De.MxManager.currentMx().is2D()?De.MxManager.currentMx().docCoordLong2World(gn):gn},n.screenCoordLong2World=function(gn){return De.MxManager.currentMx().is2D()?De.MxManager.currentMx().screenCoordLong2World(gn):gn},n.worldCoordLong2Screen=function(gn){return De.MxManager.currentMx().is2D()?De.MxManager.currentMx().worldCoordLong2Screen(gn):gn},n.addSelectEvent=function(gn){De.MxManager.addSelectEvent(gn)},n.clearSelectEvent=function(){De.MxManager.clearSelectEvent()},n.removeThreejsObject=function(gn,Xn,Kn){gn&&(gn.traverse(function(Vn){(Vn instanceof Ue.Mesh||Vn instanceof Ue.Line||Vn instanceof Ue.LineLoop)&&(Vn.geometry.dispose(),Kn&&(Vn.material instanceof Array?Vn.material.forEach(function(Yn){Yn.dispose()}):Vn.material.dispose()))}),Xn.remove(gn))},n.removeThreejsAllChildren=function gn(Xn){for(;0<Xn.children.length;){var Kn=Xn.children[0];Xn.remove(Kn),0<Kn.children.length&&gn(Kn),Kn.geometry&&Kn.geometry.dispose(),Kn.material instanceof Array?Kn.material.forEach(function(Vn){Vn.dispose()}):Kn.material.dispose(),Kn.texture&&Kn.texture.dispose()}},n.setOutServerDebugCall=function(gn){De.MxManager.setOutDebugCall(gn)},n.updateDisplay=function(){De.MxManager.updateDisplay()},n.getCurrentDraw=wn,n.formatString=function(gn){for(var Xn=[],Kn=1;Kn<arguments.length;Kn++)Xn[Kn-1]=arguments[Kn];for(var Vn=0;Vn<Xn.length;Vn++)gn=gn.replace("{"+Vn+"}",Xn[Vn]);return gn},n.createMxUiObject=function(gn){var Xn;return Xn=this.isPC()?new Xe.MxUiObjectPC:new Te.MxUiObjectMobile,gn(G=Xn),Xn.create(),Xn},n.openFile=function(gn,Xn){var Kn="";if(typeof gn=="string"){var Vn=xn(gn);Vn&&(Kn=Vn.sUrlParam,gn=Vn.sFileName)}Xn==null&&(Xn=!1);var Yn=hn(gn,Xn);return Yn.is2d&&(c=Yn.is2d),gn=Yn.sFileName,De.MxManager.currentMx().openFile(gn,Kn)},n.createMxObject=function(gn,Xn,Kn,Vn,Yn,Vr,xi,Si){q||ti(),typeof gn=="string"&&(gn=gn.length==0?void 0:document.getElementById(gn));var qn=null,ia="";if(Si)Xn="",(qn=new rt.MxDrawObject2d).initRunMode(Ve.MxRunMode.kCPPMxCAD),qn.setViewColor(0);else{if(Xn==null)Xn=n.getQueryString("file");else{var Wi=xn(Xn);Wi&&(ia=Wi.sUrlParam,Xn=Wi.sFileName)}var ha=Vn==null||Vn;if(Xn===void 0||Xn.length==0||Xn=="empty")ha=!0,Xn=Xn=="empty"?"":"empty_template.dwg";else{var ai=hn(Xn,Vr);ai.is2d&&(ha=ai.is2d),Xn=ai.sFileName}Yn==1&&(Xn=""),ha?(qn=new rt.MxDrawObject2d).setViewColor(0):(qn=new Ae.MxDrawObject3d).setViewColor(15790320)}return Kn?.(qn),qn.create(gn,Xn,ia,xi),qn},n.getMxObjectFormElement=function(gn){return De.MxManager.getMxObject(gn)},n.initMxCpp=function(gn){De.MxManager.initMxCpp(gn)},n.isRunningCommand=function(){return ie.MxJigCmdManager.isRunning()},n.stopRunCommand=$n,n.runCommand=function(gn){return ie.MxJigCmdManager.runCmd(gn)},n.getTHREE=function(){return Ue},n.getLine=function(gn){var Xn=new ue.MxJigGetLine;Xn.setRetCall(gn),ie.MxJigCmdManager.runCmd(Xn)},n.addCommand=function(gn,Xn,Kn){pt.MxCmdRunManager.addCommand(gn,Xn,Kn)},n.sendStringToExecute=Xr,n.getMxEntity=function(gn){var Xn=wn();return Xn?Xn.getMxEntityUserObject(gn):null},n.initUiDataObject=function(gn){mt.MxUiVue.isNull()&&(gn.init(n),mt.MxUiVue.init(gn))},n.init=ti,n.addWindowsEvent=function(gn){kt.MxWindowsEvent.addEvent(gn)},n.getCurrentMousePostion=function(){return wn().getCurrentMousePostion()},n.getMxThreeJS=function(){return Tt.MxThreeJS},n.getMxTools=function(){return It.MxTools},n.getMxCmdRunManager=function(){return pt.MxCmdRunManager},n.getMxJigCmdManager=function(){return ie.MxJigCmdManager},n.initQuickCommand=function(gn){pt.MxCmdRunManager.InitQuickCommand(gn)},n.InitLanguageString=function(gn){pt.MxCmdRunManager.InitLanguageString(gn)},n.getLanguageString=function(gn,Xn){return Xn===void 0&&(Xn=""),pt.MxCmdRunManager.getLanguageString(gn,Xn)},n.Assert=function(gn){gn||console.log("MxAssert error")},n.setIniset=function(gn){tn.MxDrawData.setIniset(gn)},n.setPostMessageToParentFrameFunction=function(gn){J=gn},n.postMessageToParentFrame=function(gn){return J!=null&&(J(gn),!0)},n.onParentFrameMessage=function(gn){gn!=null&&gn.type!=null&&fe[gn.type]&&fe[gn.type](gn)},n.acutPrintf=function(gn){for(var Xn=[],Kn=1;Kn<arguments.length;Kn++)Xn[Kn-1]=arguments[Kn];if(!mt.MxUiVue.isNull()){for(var Vn=arguments,Yn=Vn[0],Vr=0;Vr<Vn.length-1;Vr++){var xi=new RegExp("\\{"+Vr+"\\}","gm");Yn=Yn.replace(xi,Vn[Vr+1])}mt.MxUiVue.AcutPrintfNoFormat(Yn,!0)}},n.loadImageMaterial=function(gn,Xn){De.MxManager.getMxDbTextureManager().loadImage(gn,Xn)},n.loadSVG=function(gn,Xn,Kn,Vn){De.MxManager.getMxDbSvgManager().loadSVG(gn,Xn,Kn,Vn)},n.initMxDbEntityType=function(gn){De.MxManager.getMxDbEntityClassHierarchy().init(gn)},n.initDynamicCreate=function(gn){De.MxManager.getMxDbEntityClassHierarchy().initDynamic(gn)},n.ceneratecursor=function(gn,Xn,Kn,Vn){gn===void 0&&(gn=128),Xn===void 0&&(Xn=10),Kn===void 0&&(Kn=!0);var Yn=document.createElement("canvas");Yn.width=Yn.height=gn,Yn.style.background="transparent";var Vr=Yn.getContext("2d"),xi=gn%2==0?-.5:0,Si=Xn%2==0?-.5:0;Vr.strokeStyle=Vn||"#fff",Kn&&(Vr.beginPath(),Vr.moveTo(Yn.width/2+xi,xi),Vr.lineTo(Yn.width/2+xi,Yn.height+xi),Vr.stroke(),Vr.beginPath(),Vr.moveTo(xi,Yn.height/2+xi),Vr.lineTo(Yn.width+xi,Yn.height/2+xi),Vr.stroke()),Vr.beginPath(),Vr.strokeRect(gn/2-Xn/2+Si,gn/2-Xn/2+Si,Xn,Xn),Vr.stroke();var qn=new Image;return qn.src=Yn.toDataURL("image/png"),qn.src},n.getMrxDbgUtilsClass=function(){return an.MrxDbgUtils},n.getNumberColor=function(gn){return gn instanceof Object?gn.getHex&&(gn=gn.getHex()):typeof gn=="string"&&(gn=parseInt(gn)),gn}},{"./MrxDbgUtils":20,"./MxDrawCommands":21,"./MxDrawData":22,"./MxDrawObject":23,"./MxDrawObject2d":24,"./MxDrawObject3d":25,"./MxLocalFileLoad":28,"./MxManager":29,"./MxThreeJS":37,"./MxTools":38,"./MxVersion":40,"./MxWindowsEvent":41,"./Operate/MxCmdRunManager":48,"./Operate/MxJigCmdManager":54,"./Operate/MxJigGetLine":55,"./TempTest/MxTestJig":61,"./UI/MxUiObjectMobile":63,"./UI/MxUiObjectPC":64,"./UI/MxUiVue":65,three:19}],28:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxLocalDwgFileLoad=l.MxLocalFileLoad=l.MxLocalNodeJs=void 0;var n=t("./MxFun"),u=(c.prototype.init=function(N){this.loadFileCall=N.loadFileFun},c.prototype.loadFile=function(N,L,G,q,J){this.loadFileCall!=null?this.loadFileCall(N,L,G,q,J):J(void 0)},c);function c(){this.loadFileCall=null}l.MxLocalNodeJs=u;var y=(b.prototype.setPath=function(N){this.path=N},b.prototype.setBinary=function(N){this.isBinary=N},b.prototype.load=function(N,L,G,q){n.MxFun.getNodeJs().loadFile(this.path+N,this.isBinary,L,G,q)},b);function b(){this.path="",this.isBinary=!1}l.MxLocalFileLoad=y;var m=(O.prototype.setShowloading=function(N){this._isShowLoading=N},O.prototype.load=function(N,L){var G="$"+L+".mxb1.wgh";this._path=N,this._filename=L;var q=this;this.getFile(this._path,G,!1,function(J){typeof J=="string"?q.net.onStaticHeadMessage(J):console.log("mx error h1")},function(){console.log("mx get "+G+" faild")})},O.prototype.getDatas=function(){if(this._iGet>=this._dataNum)this._isShowLoading&&n.MxFun.hideLoading();else{var N=this._dataType[this._iGet];this._iGet++;var L=this,G=this._iGet+1,q="$"+this._filename+".mxb"+G+".wgh",J=N!=0;this.getFile(this._path,q,J,function(fe){L.net.onStaticMessage(fe),L.getDatas()},function(){L._dataNum=0,L._iGet=0,L._isShowLoading&&n.MxFun.hideLoading(),console.log("mx get "+q+" faild")})}},O.prototype.onRenderHead=function(N){var L=JSON.parse(N);this._dataType=L.type,this._dataNum=L.count,this._iGet=0,this._isShowLoading&&n.MxFun.showLoading(),this.getDatas()},O.prototype.getFile=function(N,L,G,q,J){var fe=new y;fe.setPath(N),fe.setBinary(G),fe.load(L,q,function(){},J)},O);function O(N){this.net=null,this._dataNum=0,this._iGet=0,this._dataType=[],this._path="",this._filename="",this._isShowLoading=!0,this.net=N}l.MxLocalDwgFileLoad=m},{"./MxFun":27}],29:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxManager=l.MxCpp=l.MxData=void 0;var n,u=t("./View/MxDbEntity"),c=t("./View/MxDbTextureManager"),y=t("./SVGLoader/MxSVGLoader");(n=l.MxData||(l.MxData={})).iSelectRenderOrder=5,n.iCADMeshRenderOrder=10,n.iCADCurveRenderOrder=20,n.iMxEntityRenderOrder=30,n.iGripRenderOrder=110,n.iDynJigRenderOrder=120;var b,m,O,N,L,G,q,J,fe,ve,ne,Ue=(De.prototype.init=function(Ve){this.imp=Ve},De.prototype.getMxCAD_MxCpp=function(){return this.imp},De.prototype.getMxCAD_App=function(){return this.imp.App},De.prototype.newMcGePoint3d=function(Ve){return this.imp?this.imp.newMcGePoint3d(Ve):null},De.prototype.decodeFromGb2312=function(Ve){return this.imp.decodeFromGb2312(Ve)},De.prototype.encodeToGb2312=function(Ve){return this.imp.encodeToGb2312(Ve)},De.prototype.getMcDbCurve=function(Ve){if(this.imp.App.objectIdIsKindOf(Ve,"McDbCurve"))return this.imp.App.objectIdToObject(Ve)},De);function De(){}l.MxCpp=Ue,b=l.MxManager||(l.MxManager={}),m=[],O=null,L=[],G=void(N=0),q=new c.MxDbTextureManager,J=new y.MxSvgManager,fe=new u.MxDbEntityClassHierarchy,ve=new Ue,ne={},b.add=function(Ve){m.push(Ve)},b.on=function(Ve,rt){ne[Ve]||(ne[Ve]=[]),ne[Ve].push(rt)},b.callEvent=function(Ve,rt){var Ae;if(ne[Ve])return ne[Ve].forEach(function(Te){var Xe=Te(rt);Ae=Ae||Xe}),Ae},b.initMxCpp=function(Ve){ve.init(Ve)},b.getMxCpp=function(){return ve},b.allocId=function(){return++N},b.getMxDbEntityClassHierarchy=function(){return fe},b.getMxDbTextureManager=function(){return q},b.getMxDbSvgManager=function(){return J},b.outDebugString=function(Ve){G==null?console.log(Ve):G(Ve)},b.setOutDebugCall=function(Ve){G=Ve},b.onLoad=function(){for(var Ve in m)m[Ve].onLoad("")},b.updateDisplay=function(){for(var Ve in m)m[Ve].updateDisplay()},b.currentMx=function(){return O},b.setCurrentMx=function(Ve){O=Ve},b.initResize=function(){for(var Ve in m)m[Ve].initResize()},b.addSelectEvent=function(Ve){L.push(Ve)},b.clearSelectEvent=function(){L=[]},b.callSelectObject=function(Ve){for(var rt in L)if(L[rt](Ve)==1)break},b.getMxObject=function(Ve){if(typeof Ve=="number"){for(var rt in m)if(m[rt].getId()===Ve)return m[rt]}else for(var rt in m)if(m[rt].getCanvas()===Ve)return m[rt];return null}},{"./SVGLoader/MxSVGLoader":59,"./View/MxDbEntity":69,"./View/MxDbTextureManager":74}],30:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxMaterial=void 0;var n=t("three");(function(u){u.shaderUniforms={crAmbient:{value:new n.Vector3(1,0,0)},crDiffuse:{value:new n.Vector3(1,0,0)},crSpecular:{value:new n.Vector3(1,0,0)}},u.m_arrSystemColors=new Array(0,16711680,16776960,65280,65535,255,16711935,16777215,8421504,12632256,16711680,16744319,13369344,13395558,10027008,10046540,8323072,8339263,4980736,4990502,16727808,16752511,13382400,13401958,10036736,10051404,8331008,8343359,4985600,4992806,16744192,16760703,13395456,13408614,10046464,10056268,8339200,8347455,4990464,4995366,16760576,16768895,13408512,13415014,10056192,10061132,8347392,8351551,4995328,4997670,16776960,16777087,13421568,13421670,10066176,10066252,8355584,8355647,5000192,5000230,12582656,14679935,10079232,11717734,7510272,8755532,6258432,7307071,3755008,4344870,8388352,12582783,6736896,10079334,5019904,7510348,4161280,6258495,2509824,3755046,4194048,10485631,3394560,8375398,2529536,6265164,2064128,5209919,1264640,3099686,65280,8388479,52224,6736998,39168,5019980,32512,4161343,19456,2509862,65343,8388511,52275,6737023,39206,5019999,32543,4161359,19475,2509871,65407,8388543,52326,6737049,39244,5020018,32575,4161375,19494,2509881,65471,8388575,52377,6737074,39282,5020037,32607,4161391,19513,2509890,65535,8388607,52428,6737100,39321,5020057,32639,4161407,19532,2509900,49151,8380415,39372,6730444,29337,5014937,24447,4157311,14668,2507340,32767,8372223,26316,6724044,19609,5010073,16255,4153215,9804,2505036,16383,8364031,13260,6717388,9881,5005209,8063,4149119,4940,2502476,255,8355839,204,6710988,153,5000345,127,4145023,76,2500172,4129023,10452991,3342540,8349388,2490521,6245529,2031743,5193599,1245260,3089996,8323327,12550143,6684876,10053324,4980889,7490713,4128895,6242175,2490444,3745356,12517631,14647295,10027212,11691724,7471257,8735897,6226047,7290751,3735628,4335180,16711935,16744447,13369548,13395660,10027161,10046617,8323199,8339327,4980812,4990540,16711871,16744415,13369497,13395634,10027122,10046597,8323167,8339311,4980793,4990530,16711807,16744383,13369446,13395609,10027084,10046578,8323135,8339295,4980774,4990521,16711743,16744351,13369395,13395583,10027046,10046559,8323103,8339279,4980755,4990511,3355443,5987163,8684676,11382189,14079702,16777215),u.m_arrDefUseMaterials=new Array(null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null),u.m_arrDefUseCurveMaterials=new Array(null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null),u.m_arrDefUseBasicMaterials=new Array(null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null),u.m_selectMaterial=new n.MeshPhongMaterial({color:255,opacity:.2,transparent:!0,side:n.DoubleSide}),u.m_mouseMoveMaterial=new n.MeshPhongMaterial({color:16776960,side:n.DoubleSide}),u.m_lockedMaterial=new n.MeshPhongMaterial({color:197379,side:n.DoubleSide}),u.m_samplePoints=new n.PointsMaterial({color:255,depthTest:!1,size:8}),u.m_samplePointsMouseMove=new n.PointsMaterial({color:16711680,depthTest:!1,size:12});var c=new n.MeshBasicMaterial({color:16777215,transparent:!0,depthTest:!1,side:n.DoubleSide,opacity:1,stencilWrite:!1,colorWrite:!1});u.getStencilMaterial=function(){return c},u.GetColorByIndex=function(y){return u.m_arrSystemColors[y]},u.GetColorMaterial=function(y){var b=u.m_arrDefUseMaterials[y];return b===null&&(b=new n.MeshLambertMaterial({color:u.m_arrSystemColors[y],side:n.DoubleSide}),u.m_arrDefUseMaterials[y]=b),b},u.GetBaseColorMaterial=function(y){var b=u.m_arrDefUseBasicMaterials[y];return b===null&&(b=new n.MeshBasicMaterial({color:u.m_arrSystemColors[y],side:n.DoubleSide}),u.m_arrDefUseMaterials[y]=b),b},u.GetCurveColorMaterial=function(y){var b=u.m_arrDefUseCurveMaterials[y];return b===null&&(b=new n.LineBasicMaterial({color:u.m_arrSystemColors[y],linewidth:1}),u.m_arrDefUseCurveMaterials[y]=b),b},u.GetSelectMaterial=function(){return u.m_selectMaterial},u.GetMouseMoveMaterial=function(){return u.m_mouseMoveMaterial},u.GetLockedMaterial=function(){return u.m_lockedMaterial},u.GetSamplePointsMaterial=function(){return u.m_samplePoints},u.GetSamplePointsMouseMoveMaterial=function(){return u.m_samplePointsMouseMove},u.createMaterial=function(y){var b=void 0;if(y==null)return b;function m(O,N){if(N.map!=null){var L=N.map,G=new n.TextureLoader().load(L);G.wrapS=G.wrapT=n.RepeatWrapping,O.map=G,O.side=n.DoubleSide}}return y.transparent!=0?y.transparent=!0:y.transparent=!1,y.name=="MeshPhongMaterial"?m(b=new n.MeshPhongMaterial(y),y):y.name=="MeshBasicMaterial"?m(b=new n.MeshBasicMaterial(y),y):y.name=="MeshDepthMaterial"?m(b=new n.MeshDepthMaterial(y),y):y.name=="MeshNormalMaterial"?m(b=new n.MeshNormalMaterial(y),y):y.name=="MeshLambertMaterial"?m(b=new n.MeshLambertMaterial(y),y):y.name=="MeshStandardMaterial"&&m(b=new n.MeshStandardMaterial(y),y),b}})(l.MxMaterial||(l.MxMaterial={}))},{three:19}],31:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxHFileLoad=l.MxNet=l.MxNetBinMessageType=l.MxNetSend=l.MxNetMessage=l.MxNetMessageType=l.MxNetData=void 0;var n,u,c=t("three"),y=t("./MxFun"),b=t("pako"),m=t("./MxManager"),O=t("./MxDrawData"),N=(L.prototype.getId=function(){return this._dataView.getInt32(4,!0)},L.prototype.getVersion_MwBlobHead=function(){return this._dataView.getInt32(60,!0)},L.prototype.getVersion_MwBlobHeadDynLen=function(){return this._dataView.getInt32(4,!0)},L.prototype.getdPointCurveBuffersHead=function(){var Ae={};return Ae.ver=this._dataView.getInt32(4,!0),Ae.databaseIndex=this._dataView.getInt32(8,!0),Ae.zeroLayerIdIndex=this._dataView.getInt32(16,!0),Ae.datacount=this._dataView.getInt32(20,!0),Ae.datasize=this._dataView.getInt32(24,!0),Ae},L.prototype.getdPointMeshBuffersHead=function(){var Ae={};return Ae.ver=this._dataView.getInt32(4,!0),Ae.databaseIndex=this._dataView.getInt32(8,!0),Ae.id=this._dataView.getInt32(12,!0),Ae.zeroLayerIdIndex=this._dataView.getInt32(16,!0),Ae.datacount=this._dataView.getInt32(20,!0),Ae.datasize=this._dataView.getInt32(24,!0),Ae},L.prototype.getdPointTextureBuffersHead=function(){var Ae={};return Ae.ver=this._dataView.getInt32(4,!0),Ae.databaseIndex=this._dataView.getInt32(8,!0),Ae.zeroLayerIdIndex=this._dataView.getInt32(16,!0),Ae.datacount=this._dataView.getInt32(20,!0),Ae.datasize=this._dataView.getInt32(24,!0),Ae},L.prototype.getBlobHeadForMemorySectionsHead=function(Ae){var Te={};return Te.type=this._dataView.getInt32(Ae,!0),Ae+=4,Te.ver=this._dataView.getInt32(Ae,!0),Ae+=4,Te.databaseIndex=this._dataView.getInt32(Ae,!0),Ae+=4,Te.nOffset=Ae,Te},L.prototype.getMemorySectionsHead=function(){var Ae=this.getBlobHeadForMemorySectionsHead(0);return Ae.zeroLayerIdIndex=this._dataView.getInt32(Ae.nOffset,!0),Ae.nOffset+=4,Ae.datacount=this._dataView.getInt32(Ae.nOffset,!0),Ae.nOffset+=4,Ae.datasize=this._dataView.getInt32(Ae.nOffset,!0),Ae.nOffset+=4,Ae.datasize!=Ae.nOffset&&console.log("mx: sectionshead size assert(0)"),Ae},L.prototype.getMemorySectionHead=function(Ae){var Te=this.getBlobHeadForMemorySectionsHead(Ae);return Ae=Te.nOffset,Te.pointCount=this._dataView.getInt32(Ae,!0),Ae+=4,Te.layerId=this._dataView.getInt32(Ae,!0),Ae+=4,Te.blkId=this._dataView.getInt32(Ae,!0),Ae+=4,Te.memColor=this._dataView.getInt32(Ae,!0),Ae+=4,Te.memId=this._dataView.getInt32(Ae,!0),Ae+=4,Te.memType=this._dataView.getInt32(Ae,!0),Ae+=4,Te.offset=Ae,Te},L.prototype.getdPointTextureBufferDataHead=function(Ae){Ae+=4,Ae+=4,Ae+=4;var Te={};return Te.dataCount=this._dataView.getInt32(Ae,!0),Ae+=4,Te.layerId=this._dataView.getInt32(Ae,!0),Ae+=4,Te.blkId=this._dataView.getInt32(Ae,!0),Ae+=4,Te.offset=Ae,Te},L.prototype.getdPointCurveBufferDataHead=function(Ae){Ae+=4,Ae+=4,Ae+=4;var Te={};return Te.pointCount=this._dataView.getInt32(Ae,!0),Ae+=4,Te.layerId=this._dataView.getInt32(Ae,!0),Ae+=4,Te.blkId=this._dataView.getInt32(Ae,!0),Ae+=4,Te.offset=Ae,Te},L.prototype.getdPointMeshBufferDataHead=function(Ae){Ae+=4,Ae+=4,Ae+=4;var Te={};return Te.pointCount=this._dataView.getInt32(Ae,!0),Ae+=4,Te.layerId=this._dataView.getInt32(Ae,!0),Ae+=4,Te.blkId=this._dataView.getInt32(Ae,!0),Ae+=4,Te.offset=Ae,Te},L.prototype.getDatabaseIndex=function(){return this._dataView.getInt32(8,!0)},L.prototype.getColorIndex=function(){return this._dataView.getInt32(24,!0)},L.prototype.getBufferType=function(){return this._dataView.getInt32(32,!0)},L.prototype.getIsSketchEntity=function(){return this._dataView.getInt32(40,!0)},L.prototype.getLayerId=function(){return this._dataView.getInt32(44,!0)},L.prototype.getBlockId=function(){return this._dataView.getInt32(48,!0)},L.prototype.getVertexBufferSize=function(){return this._dataView.getInt32(12,!0)},L.prototype.getIndexBufferSize=function(){return this._dataView.getInt32(16,!0)},L.prototype.getZeroLayerId=function(){return this._dataView.getInt32(52,!0)},L.prototype.getSelectMark=function(){return this._dataView.getInt32(56,!0)},L.prototype.getMateria=function(){var Ae=this._dataView.getInt32(36,!0);if(Ae==0)return"";for(var Te=[],Xe=0;Xe<Ae;Xe++){var ie=String.fromCharCode(this._dataView.getUint8(80+Xe));Te.push(ie)}return Te.join("")},L.prototype.getDrawDataOffset=function(){return this._dataView.getInt32(36,!0)+80},L.prototype.getMesh=function(){var Ae=this._dataView.getInt32(4,!0),Te=this._dataView.getInt32(32,!0)==0,Xe={},ie=this._dataView.getInt32(12,!0),ue=this._dataView.getInt32(16,!0);if(ie===0||ue===0)return Xe.size=80,Xe;var pt,mt=new c.Geometry,Tt=80;pt=Te?ie/4/8:ie/4/2;for(var kt=0;kt<pt;kt++){var It=this._dataView.getFloat32(Tt+0,!0),nn=this._dataView.getFloat32(Tt+4,!0),tn=0;Te?(tn=this._dataView.getFloat32(Tt+8,!0),this._dataView.getFloat32(Tt+12,!0),this._dataView.getFloat32(Tt+16,!0),this._dataView.getFloat32(Tt+20,!0),this._dataView.getFloat32(Tt+24,!0),this._dataView.getFloat32(Tt+28,!0),Tt+=32):Tt+=8;var pn=new c.Vector3(It,nn,tn);mt.vertices.push(pn)}var _n=ue/4;for(kt=0;kt<_n;kt+=3){var Dn=this._dataView.getInt32(Tt,!0);Tt+=4;var an=this._dataView.getInt32(Tt,!0);Tt+=4;var Rn=this._dataView.getInt32(Tt,!0);Tt+=4;var Lt=new c.Face3(Dn,an,Rn);mt.faces.push(Lt)}var wn=this.getIsSketchEntity();return Xe.size=Tt,Xe.geometry=mt,Xe.id=Ae,Xe.isSketchEntity=wn,Xe.nColorIndex=this._dataView.getInt32(24,!0),Xe},L.prototype.getCurve=function(Ae){var Te,Xe=this._dataView.getInt32(32,!0),ie=this.getIsSketchEntity(),ue=Xe==0,pt={};if((Te=ue?this._dataView.getInt32(20,!0)/4/3:this._dataView.getInt32(20,!0)/4/2)<2)return pt;for(var mt=new c.Geometry,Tt=Ae,kt=0;kt<Te;kt++){var It=this._dataView.getFloat32(Tt,!0);Tt+=4;var nn=this._dataView.getFloat32(Tt,!0);Tt+=4;var tn=0;ue&&(tn=this._dataView.getFloat32(Tt,!0),Tt+=4),mt.vertices.push(new c.Vector3(It,nn,tn))}var pn=this._dataView.getInt32(4,!0);return pt.size=Tt,pt.geometry=mt,pt.id=pn,pt.isSketchEntity=ie,pt.colorIndex=this._dataView.getInt32(28,!0),pt},L);function L(Ae){this._dataView=Ae}l.MxNetData=N,(u=n=l.MxNetMessageType||(l.MxNetMessageType={})).kAddLayer="00000007",u.kClearLayer="00000008",u.kHideLayer="00000009",u.kShowLayer="00000010",u.kUpdateDisplayRange="00000011",u.kCallJsReturn="00000012",u.kLayerData="00000013",u.kSendDebugString="00000014",u.kShowLoading="00000015",u.kHideLoading="00000016",u.kSelectObject="00000017",u.kGlRenderHead="00000018",u.kUserLoginResult="00000019",u.kOpenFileResult="00000020",u.kServerReturn="00000021",u.kMxCADLayerData="00000056",u.kMxCADSystemVariable="00000057";var G=(q.prototype.setJsRetCall=function(Ae,Te,Xe){this.serverJsRetCall.set(Te+Xe,Ae)},q.prototype.onSocketErrort=function(){this.serverJsRetCall.forEach(function(Ae){Ae(void 0)}),this.serverJsRetCall=new Map},q.prototype.Do=function(Ae){var Te=this.net.getCurrentDatabaseId();if(Te==-1){var Xe=Ae.substring(0,4);Te=parseInt(Xe)}var ie=Ae.substring(4,12),ue=Ae.substring(12);return this.messageCall[ie]!=null&&(this.messageCall[ie](ue,Te),!0)},q);function q(Ae,Te){this.messageCall=new Map,this.serverJsRetCall=new Map,this.net=null,this.net=Te;var Xe=this;this.messageCall[n.kUpdateDisplayRange]=function(ie){if(!Xe.net.isTzDwgStaticFile()){ie=ie.replace(/\\/g,"\\\\");try{var ue=JSON.parse(ie);if(ue!=null&&Ae.is2D()){Ae.initCAD2Doc(new c.Matrix4),ue.newbrownermode?ue.DToSMat?O.MxDrawData.m_isCorrectLargeCoordinates?(Ae.intiDoc2Wold(new c.Matrix4),Ae.initCAD2Doc(ue.DToSMat)):Ae.intiDoc2Wold(ue.DToSMat):Ae.intiDoc2Wold(new c.Matrix4):Ae.intiDoc2Wold(ue.DToWMat),Ae.initializingObjectMatrix(),Ae.updateCameraDisplayRange(new c.Vector3(+ue.pt1[0],+ue.pt1[1],+ue.pt1[2]),new c.Vector3(+ue.pt2[0],+ue.pt2[1],+ue.pt2[2]),+ue.viewangle),Ae.initAllLayoutName(ue.layout),Ae.updateDisplay(!0);var pt=y.MxFun.getUiObj();pt!=null&&(pt.SetLayoutData(ue.layout),pt.UpDisplayLayout())}}catch{console.log("UpdateDisplayRange exception")}}},this.messageCall[n.kCallJsReturn]=function(ie){if(ie.length!=0){var ue=JSON.parse(ie);ue.cmd.length==0&&(ue.cmd="__mx_loadcode");var pt=ue.cmd+ue.count,mt=Xe.serverJsRetCall.get(pt);mt&&(Xe.serverJsRetCall.delete(pt),typeof ue.ret=="string"&&(ue.ret=ue.ret.replace(/\'/g,'"')),mt(ue.ret))}else console.log("assert(0),kCallJsReturn return empty")},this.messageCall[n.kSendDebugString]=function(ie){m.MxManager.outDebugString(ie)},this.messageCall[n.kUserLoginResult]=function(ie){Ae.userLoginResult(ie)},this.messageCall[n.kOpenFileResult]=function(ie){Ae.openFileResult(ie)},this.messageCall[n.kServerReturn]=function(ie){Ae.serverReturn(ie)},this.messageCall[n.kShowLoading]=function(ie){Xe.net.isTzDwgStaticFile()||y.MxFun.showLoading()},this.messageCall[n.kHideLoading]=function(ie){Xe.net.isTzDwgStaticFile()||(y.MxFun.hideLoading(),Ae.callInitCompleteEvent())},this.messageCall[n.kSelectObject]=function(ie){var ue=JSON.parse(ie);m.MxManager.callSelectObject(parseInt(ue.id))},this.messageCall[n.kGlRenderHead]=function(ie){Ae.isStaticLocalLoad()?Ae.getStaticLocalNet().onRenderHead(ie):(Xe.net.isTzDwgStaticFile()?Ae.getStaticLoadTzNet():Ae.getStaticNet()).onRenderHead(ie)},this.messageCall[n.kMxCADSystemVariable]=function(ie,ue){Ae.sysVariable().OnMessageMxCADSystemVariable(ie)},this.messageCall[n.kLayerData]=function(ie,ue){if(ue==0){if(Ae.addLayerInfoComplete(),(kt=JSON.parse(ie))!=null){if(!kt.isSketch){var pt=kt.list;for(var mt in pt)Ae.addLayerInfo(pt[mt].id,pt[mt].colorvalue,pt[mt].name),pt[mt].zerolayer==1&&Ae.setZeroLayerId(pt[mt].id)}kt.isSketch||Ae.callEvent("uiSetLayerData",kt.list);var Tt=y.MxFun.getUiObj();Tt!=null&&(kt.isSketch?Tt.SetSketchLayerData(kt.list):Tt.SetLayerData(kt.list),Tt.UpDisplayLayer())}}else{var kt,It=Ae.getExtRefManager().getLayers(ue);if(It.initComplete(),(kt=JSON.parse(ie))!=null)for(var mt in pt=kt.list)It.add(pt[mt].id,pt[mt].colorvalue,pt[mt].name),pt[mt].zerolayer==1&&It.setZeroLayerId(pt[mt].id)}}}l.MxNetMessage=G;var J,fe,ve=(ne.prototype.setWebSocket=function(Ae){this._webSocket=Ae},ne.prototype.UndoMark=function(){this._webSocket!=null&&this._webSocket.send(this.SendType.kUndoMark+"")},ne.prototype.DoCommand=function(Ae,Te,Xe){this._webSocket!=null&&(Xe!=null?(this._callCount++,200<this._callCount&&(this._callCount=1),this._msg.setJsRetCall(Xe,Ae,this._callCount),Te==null&&(Te=""),this._webSocket.send(this.SendType.kCmdEx+","+Ae+","+this._callCount+","+Te)):Te==null?this._webSocket.send(this.SendType.kCmd+","+Ae):this._webSocket.send(this.SendType.kCmd+","+Ae+","+Te))},ne.prototype.OpenFile=function(Ae){this._webSocket!=null&&this._webSocket.send(this.SendType.kOpenFile+","+Ae)},ne.prototype.UserLogin=function(Ae,Te,Xe){if(this._webSocket!=null){var ie={};ie.IdentitySign=Ae,ie.RandomToken=Te??"",ie.Init=Xe??"",this._webSocket.send(this.SendType.kUserLogin+","+JSON.stringify(ie))}},ne.prototype.Init=function(Ae){this._webSocket!=null&&this._webSocket.send(this.SendType.kInit+","+Ae)},ne.prototype.CallServerJS=function(Ae,Te,Xe){this._webSocket!=null&&(Xe==null?Te==null||Te==null||Te.length==0?this._webSocket.send(this.SendType.kCallJS+',{"command":"'+Ae+'","param":"{}"}'):this._webSocket.send(this.SendType.kCallJS+',{"command":"'+Ae+'","param":'+Te+"}"):(this._callCount++,200<this._callCount&&(this._callCount=1),this._msg.setJsRetCall(Xe,Ae,this._callCount),Te==null||Te==null||Te.length==0?this._webSocket.send(this.SendType.kCallJS+',{"command":"'+Ae+'","param":"{}","count":"'+this._callCount+'"}'):this._webSocket.send(this.SendType.kCallJS+',{"command":"'+Ae+'","param":'+Te+',"count":"'+this._callCount+'"}')))},ne.prototype.CallLoadCodeToServer=function(Ae,Te){this._webSocket!=null&&(this._msg.setJsRetCall(Te,"__mx_loadcode",0),Ae!=null&&Ae!=null&&Ae.length!=0&&this._webSocket.send(this.SendType.kCallJS+","+Ae))},ne.prototype.DeleteObject=function(Ae){this._webSocket!=null&&this._webSocket.send(this.SendType.kDelete+","+Ae)},ne.prototype.SelectObject=function(Ae){this._webSocket!=null&&this._webSocket.send(this.SendType.kSelect+","+Ae)},ne.prototype.QuitSelectObject=function(Ae){this._webSocket!=null&&this._webSocket.send(this.SendType.kQuitSelect+","+Ae)},ne.prototype.SendDragDrawEntity=function(Ae){this._webSocket!=null&&this._webSocket.send(this.SendType.kAddDragDraw+","+Ae)},ne.prototype.SendDragDrawRequest=function(){this._webSocket!=null&&(this.SendMousePickRay(),this._webSocket.send(this.SendType.kRequestDragDraw))},ne.prototype.SendDragDrawDetermine=function(){this._webSocket!=null&&(this.SendMousePickRay(),this._webSocket.send(this.SendType.kDetermineDragDraw))},ne.prototype.SendDragDrawCancel=function(){this._webSocket!=null&&this._webSocket.send(this.SendType.kCancelDragDraw)},ne.prototype.SendMousePickRay=function(){this._webSocket},ne);function ne(Ae,Te){this.SendType={},this._callCount=1,this._webSocket=Ae,this._msg=Te,this.SendType.kCmd=0,this.SendType.kDelete=1,this.SendType.kSelect=2,this.SendType.kOpenFile=3,this.SendType.kGetDemoList=4,this.SendType.kCallJS=5,this.SendType.kAddDragDraw=6,this.SendType.kRequestDragDraw=7,this.SendType.kMousePickRay=8,this.SendType.kDetermineDragDraw=9,this.SendType.kCancelDragDraw=10,this.SendType.kQuitSelect=11,this.SendType.kInit=12,this.SendType.kCmdEx=13,this.SendType.kUserLogin=14,this.SendType.kUndoMark=15}l.MxNetSend=ve,(fe=J=l.MxNetBinMessageType||(l.MxNetBinMessageType={})).eBlockRef=10,fe.eEntitysData=14,fe.eAddEntityFor2dPointTextureBuffers=15,fe.eMxNewMemorySections=16,fe.kMxCADBlockRef=56,fe.kMxCADMemorySections=57,fe.kMxCADMemorySectionsFromChange=59,fe.kMxCADNotUseMemorySectionsForChage=61,fe.kMxCADEntityDisplayDatas=62;var Ue=(De.prototype.setCurrentDatabaseId=function(Ae){this._iCurrentDatabaseId=Ae},De.prototype.getMxDrawObject=function(){return this._mx},De.prototype.getCurrentDatabaseId=function(){return this._iCurrentDatabaseId},De.prototype.isTzDwgStaticFile=function(){return this._iCurrentDatabaseId!=-1},De.prototype.onBinMessage=function(Ae){var Te=this._mx,Xe=b.inflate(Ae),ie=new DataView(Xe.buffer),ue=ie.getInt32(0,!0);this._binMessageCall.has(ue)?this._binMessageCall.get(ue)(ie,this._iCurrentDatabaseId):(this._iCurrentDatabaseId==-1&&(ue==0?Te.mxWebAddEntity(ie):ue==6?Te.removeEntityFromServer(ie):ue==11&&Te.getExtRefManager().createExternalReferences(ie)),ue==12?Te.mxWebAddEntityFor2dPointCurveBuffers(ie,this._iCurrentDatabaseId):ue==13?Te.mxWebAddEntityFor2dPointMeshBuffers(ie,this._iCurrentDatabaseId):ue==8?Te.mxWebAddEntityFor2dPointCurveBuffer(ie,this._iCurrentDatabaseId):ue==9?Te.mxWebAddEntityFor2dPointMeshBuffer(ie,this._iCurrentDatabaseId):ue==J.eBlockRef&&Te.mxWebCreateAllBlocks(ie,this._iCurrentDatabaseId))},De.prototype.socket_onErrort=function(){this._msg.onSocketErrort()},De.prototype.socket_onMessageImp=function(Ae,Te){if(Te===void 0&&(Te=!1),typeof Ae=="string")this._msg.Do(Ae);else if(Te)this.onBinMessage(Ae);else{var Xe=new FileReader;Xe.readAsArrayBuffer(Ae);var ie=this;Xe.onload=function(ue){ie._mx.updateDisplay(),ie.onBinMessage(Xe.result)}}this._mx.updateDisplay()},De.prototype.initBinMessage=function(){var Ae=this._mx;this._binMessageCall.set(J.eEntitysData,function(Te,Xe){Ae.mxWebEntitysData(Te,Xe)}),this._binMessageCall.set(J.eAddEntityFor2dPointTextureBuffers,function(Te,Xe){Ae.mxWebAddEntityFor2dPointTextureBuffers(Te,Xe)}),this._binMessageCall.set(J.eMxNewMemorySections,function(Te,Xe){Ae.mxWebAddEntityForMemorySections(Te,Xe)})},De.prototype.init=function(Ae,Te){var Xe=this;this._mx=Ae,this._msg=new G(Ae,this),this.initBinMessage(),Te&&(this._webSocket=new WebSocket(y.MxFun.getMxServer()),this._webSocket.onopen=function(){var ie=Xe._mx.getIniParam();if(ie.length!=0){for(var ue="{",pt=ie.length,mt=0;mt<pt;mt++)ue=mt==0?ue+'"'+ie[mt][0]+'":"'+ie[mt][1]+'"':ue+',"'+ie[mt][0]+'":"'+ie[mt][1]+'"';ue+="}",Xe._send.Init(ue)}},this._webSocket.onmessage=function(ie){Xe.socket_onMessageImp(ie.data)},this._webSocket.onerror=function(){console.log("mx: socket error"),Xe.socket_onErrort()}),this._send=new ve(this._webSocket,this._msg)},De.prototype.closeWebSocket=function(){this._webSocket&&(this._send.setWebSocket(null),this._webSocket.close(),this._webSocket=null)},De.prototype.getOnMessage=function(){return this._msg},De.prototype.getSend=function(){return this._send},De.prototype.onStaticMessage=function(Ae){try{return this.socket_onMessageImp(Ae,!0),!0}catch(Te){return console.log("mx file data error!"),console.log(Te),!1}},De.prototype.onStaticHeadMessage=function(Ae){return typeof Ae=="string"&&this._msg.Do(Ae)},De);function De(){this._webSocket=null,this._send=null,this._msg=null,this._mx=null,this._binMessageCall=new Map,this._iCurrentDatabaseId=-1}l.MxNet=Ue;var Ve=(rt.prototype.stopAllLoading=function(){this._isStopLoading||(this._isStopLoading=!0,this._isShowLoading&&y.MxFun.hideLoading())},rt.prototype.setShowloading=function(Ae){this._isShowLoading=Ae},rt.prototype.showLoading=function(){this._isShowLoading&&y.MxFun.showLoading()},rt.prototype.hideLoading=function(Ae){this._isStopLoading||(this._isShowLoading&&y.MxFun.hideLoading(),this.net.getMxDrawObject().callInitCompleteEvent(),this.net.getMxDrawObject().callOpenFileComplete(Ae))},rt.prototype.setRequestHeader=function(Ae){this._requestHeader=Ae},rt.prototype.setUrlParam=function(Ae){this._urlParam=Ae},rt.prototype.load=function(Ae,Te){var Xe=y.MxFun.curPath(),ie=y.MxFun.dwgDir(),ue=y.MxFun.getStaticServer(),pt="/buf/";if(Ae.substring(Ae.lastIndexOf(".")+1).toLowerCase()=="wgh"){pt="/";var mt=Ae.substring(0,Ae.indexOf(".mxb1.wgh")).split("/");(Ae=mt.length==1?mt[0]:(ue=Ae.substring(0,Ae.lastIndexOf("/")),mt[mt.length-1]))[0]=="$"&&(Ae=Ae.substring(1))}var Tt="$"+(Ae=encodeURIComponent(Ae))+".mxb1.wgh";ue.length!=0?Xe=ue+pt:ie.length!=0?Xe=Xe+"/"+ie+pt:Xe+=pt,this._path=Xe,this._filename=Ae,1<(this._staticLoadingOpenFiles=Te).length&&(Tt=Te[0],this._path=void 0);var kt=this;this.getFile(this._path,Tt,function(It){if(!kt._isStopLoading)return typeof It!="string"?(console.log("mx error h1"),void kt.hideLoading(4)):kt.net.onStaticHeadMessage(It)?void 0:(console.log("mx error h1:"+It),void kt.hideLoading(2))},function(){kt.hideLoading(3),console.log("mx get "+Tt+" faild")})},rt.prototype.getData=function(){if(this._isStopLoading)this.hideLoading(5);else if(this._iGet>=this._dataNum)this.hideLoading(0);else{var Ae=this._dataType[this._iGet];this._iGet++;var Te=this,Xe=this._iGet+1,ie="$"+this._filename+".mxb"+Xe+".wgh";if(1<this._staticLoadingOpenFiles.length){if(this._iGet>=this._staticLoadingOpenFiles.length)return console.log("Mx staticLoadingOpenFiles error!"),void this.hideLoading(7);ie=this._staticLoadingOpenFiles[this._iGet]}var ue=ie;this._path&&(ue=this._path+ie);var pt=ue.substring(0,ue.lastIndexOf("/")+1);if(this.net.getMxDrawObject().setCurrentLoadUrl(pt),Ae==0)this.getFile(this._path,ie,function(kt){Te._isStopLoading||(Te.net.onStaticMessage(kt)||(console.log(this._path),console.log(ie)),Te.getData())},function(){Te._dataNum=0,Te._iGet=0,Te.hideLoading(8),console.log("mx get "+ie+" faild")});else{var mt=new XMLHttpRequest,Tt=ie;this._path&&(Tt=this._path+ie),this._urlParam.length!=0?mt.open("GET",Tt+this._urlParam):mt.open("GET",Tt),O.MxDrawData.m_isRequestHeaderCacheControl&&mt.setRequestHeader("Cache-Control","max-age=7200"),this._requestHeader.length!=0&&mt.setRequestHeader("usertoken",this._requestHeader),mt.responseType="arraybuffer",mt.onload=function(){Te._isStopLoading||(Te.net.onStaticMessage(mt.response)||console.log(Tt),Te.getData())},mt.addEventListener("error",function(kt){Te._dataNum=0,Te._iGet=0,Te.hideLoading(9),console.log("mx get "+ie+" faild")},!1),mt.send()}}},rt.prototype.onRenderHead=function(Ae){if(!this._isStopLoading){var Te=JSON.parse(Ae);this._dataType=Te.type,this._dataNum=Te.count,this._iGet=0,this.showLoading(),this.getData()}},rt.prototype.getFile=function(Ae,Te,Xe,ie){var ue=new c.FileLoader(this.manager);ue.setPath(Ae);var pt=Te;this._urlParam.length!=0&&(pt=Te+this._urlParam),this._requestHeader.length!=0&&(ue.requestHeader={usertoken:this._requestHeader}),ue.load(pt,Xe,function(){},ie)},rt);function rt(Ae,Te){this.net=null,this.manager=null,this._dataNum=0,this._iGet=0,this._dataType=[],this._path="",this._filename="",this._staticLoadingOpenFiles=[],this._isShowLoading=!0,this._requestHeader="",this._isStopLoading=!1,this._urlParam="",this.net=Ae,this.manager=Te!==void 0?Te:c.DefaultLoadingManager}l.MxHFileLoad=Ve},{"./MxDrawData":22,"./MxFun":27,"./MxManager":29,pako:1,three:19}],32:[function(t,e,l){var n;Object.defineProperty(l,"__esModule",{value:!0}),l.MxShader=void 0,(n=l.MxShader||(l.MxShader={})).VSHADER_COLOR_POINT=` precision highp float;
- uniform mat4 modelViewMatrix;
- uniform mat4 projectionMatrix;
- attribute vec2 position;
- attribute vec3 color;
- attribute vec4 tran1;
- attribute vec4 tran2;
- attribute vec4 tran3;
- attribute vec4 tran4;
- attribute float ishide;
- varying vec4 vColor;
- void main(){
- mat4 tran;
- tran[0][0] = tran1.x;tran[0][1] = tran1.y;tran[0][2] = tran1.z;tran[0][3] = tran1.w;
- tran[1][0] = tran2.x;tran[1][1] = tran2.y;tran[1][2] = tran2.z;tran[1][3] = tran2.w;
- tran[2][0] = tran3.x;tran[2][1] = tran3.y;tran[2][2] = tran3.z;tran[2][3] = tran3.w;
- tran[3][0] = tran4.x;tran[3][1] = tran4.y;tran[3][2] = tran4.z;tran[3][3] = tran4.w;
- if(ishide > 0.1)
- vColor = vec4(color,0.0);
- else
- vColor = vec4(color,1.0);
- gl_Position = projectionMatrix * modelViewMatrix * tran * vec4( position.x,position.y,0.0, 1.0 );
- }
- `,n.VSHADER_COLOR_POINT_BYLAYER=` precision highp float;
- uniform mat4 modelViewMatrix;
- uniform mat4 projectionMatrix;
- uniform vec3 color;
- attribute vec2 position;
- attribute vec4 tran1;
- attribute vec4 tran2;
- attribute vec4 tran3;
- attribute vec4 tran4;
- attribute float ishide;
- varying vec4 vColor;
- void main(){
- mat4 tran;
- tran[0][0] = tran1.x;tran[0][1] = tran1.y;tran[0][2] = tran1.z;tran[0][3] = tran1.w;
- tran[1][0] = tran2.x;tran[1][1] = tran2.y;tran[1][2] = tran2.z;tran[1][3] = tran2.w;
- tran[2][0] = tran3.x;tran[2][1] = tran3.y;tran[2][2] = tran3.z;tran[2][3] = tran3.w;
- tran[3][0] = tran4.x;tran[3][1] = tran4.y;tran[3][2] = tran4.z;tran[3][3] = tran4.w;
- if(ishide > 0.1)
- vColor = vec4(color,0.0);
- else
- vColor = vec4(color,1.0);
- gl_Position = projectionMatrix * modelViewMatrix * tran * vec4( position.x,position.y,0.0, 1.0 );
- }
- `,n.FSHADER_COLOR_POINT=` precision highp float;
- varying vec4 vColor;
- void main() {
- gl_FragColor = vColor;
- }
- `,n.VSHADER_COLOR_POINT_TEXTURE=` precision highp float;
- uniform mat4 modelViewMatrix;
- uniform mat4 projectionMatrix;
- attribute vec2 position;
- attribute vec2 uv;
- attribute vec4 tran1;
- attribute vec4 tran2;
- attribute vec4 tran3;
- attribute vec4 tran4;
- varying vec2 vUv;
- void main(){
- vUv = uv;
- mat4 tran;
- tran[0][0] = tran1.x;tran[0][1] = tran1.y;tran[0][2] = tran1.z;tran[0][3] = tran1.w;
- tran[1][0] = tran2.x;tran[1][1] = tran2.y;tran[1][2] = tran2.z;tran[1][3] = tran2.w;
- tran[2][0] = tran3.x;tran[2][1] = tran3.y;tran[2][2] = tran3.z;tran[2][3] = tran3.w;
- tran[3][0] = tran4.x;tran[3][1] = tran4.y;tran[3][2] = tran4.z;tran[3][3] = tran4.w;
- gl_Position = projectionMatrix * modelViewMatrix * tran * vec4( position.x,position.y,0.0, 1.0 );
- }
- `,n.FSHADER_COLOR_POINT_TEXTURE=` precision highp float;
- varying vec2 vUv;
- uniform sampler2D texture;
- void main() {
- gl_FragColor = texture2D( texture, vUv );
- }
- `,n.VSHADER_COLOR_POINT_CLIP=` precision highp float;
- uniform mat4 modelViewMatrix;
- uniform mat4 projectionMatrix;
- uniform vec2 clippt1;
- uniform vec2 clippt2;
- uniform float vieww;
- uniform float viewh;
- attribute vec2 position;
- attribute vec3 color;
- attribute vec4 tran1;
- attribute vec4 tran2;
- attribute vec4 tran3;
- attribute vec4 tran4;
- attribute float ishide;
- varying vec4 vColor;
- varying vec2 vCp1;
- varying vec2 vCp2;
- void main(){
- mat4 tran;
- tran[0][0] = tran1.x;tran[0][1] = tran1.y;tran[0][2] = tran1.z;tran[0][3] = tran1.w;
- tran[1][0] = tran2.x;tran[1][1] = tran2.y;tran[1][2] = tran2.z;tran[1][3] = tran2.w;
- tran[2][0] = tran3.x;tran[2][1] = tran3.y;tran[2][2] = tran3.z;tran[2][3] = tran3.w;
- tran[3][0] = tran4.x;tran[3][1] = tran4.y;tran[3][2] = tran4.z;tran[3][3] = tran4.w;
- vec4 pt1 = projectionMatrix * modelViewMatrix * vec4( clippt1.x,clippt1.y,0.0, 1.0 );
- vec4 pt2 = projectionMatrix * modelViewMatrix * vec4( clippt2.x,clippt2.y,0.0, 1.0 );
- vCp1 = vec2(pt1.x * vieww + vieww,pt1.y * viewh + viewh);
- vCp2 = vec2(pt2.x * vieww + vieww,pt2.y * viewh + viewh);
- if(ishide > 0.1)
- vColor = vec4(color,0.0);
- else
- vColor = vec4(color,1.0);
- gl_Position = projectionMatrix * modelViewMatrix * tran * vec4( position.x,position.y,0.0, 1.0 );
- }
- `,n.VSHADER_COLOR_POINT_BYLAYER_CLIP=` precision highp float;
- uniform mat4 modelViewMatrix;
- uniform mat4 projectionMatrix;
- uniform vec3 color;
- uniform vec2 clippt1;
- uniform vec2 clippt2;
- uniform float vieww;
- uniform float viewh;
- attribute vec2 position;
- attribute vec4 tran1;
- attribute vec4 tran2;
- attribute vec4 tran3;
- attribute vec4 tran4;
- attribute float ishide;
- varying vec4 vColor;
- varying vec2 vCp1;
- varying vec2 vCp2;
- void main(){
- mat4 tran;
- tran[0][0] = tran1.x;tran[0][1] = tran1.y;tran[0][2] = tran1.z;tran[0][3] = tran1.w;
- tran[1][0] = tran2.x;tran[1][1] = tran2.y;tran[1][2] = tran2.z;tran[1][3] = tran2.w;
- tran[2][0] = tran3.x;tran[2][1] = tran3.y;tran[2][2] = tran3.z;tran[2][3] = tran3.w;
- tran[3][0] = tran4.x;tran[3][1] = tran4.y;tran[3][2] = tran4.z;tran[3][3] = tran4.w;
- vec4 pt1 = projectionMatrix * modelViewMatrix * vec4( clippt1.x,clippt1.y,0.0, 1.0 );
- vec4 pt2 = projectionMatrix * modelViewMatrix * vec4( clippt2.x,clippt2.y,0.0, 1.0 );
- vCp1 = vec2(pt1.x * vieww + vieww,pt1.y * viewh + viewh);
- vCp2 = vec2(pt2.x * vieww + vieww,pt2.y * viewh + viewh);
- if(ishide > 0.1)
- vColor = vec4(color,0.0);
- else
- vColor = vec4(color,1.0);
- gl_Position = projectionMatrix * modelViewMatrix * tran * vec4( position.x,position.y,0.0, 1.0 );
- }
- `,n.FSHADER_COLOR_POINT_CLIP=`precision highp float;
- varying vec4 vColor;
- varying vec2 vCp1;
- varying vec2 vCp2;
- void main() {
- if(gl_FragCoord.x > vCp1.x && gl_FragCoord.x < vCp2.x && gl_FragCoord.y > vCp1.y && gl_FragCoord.y < vCp2.y)
- gl_FragColor = vColor;
- else
- discard;
- }
- `,n.VSHADER_COLOR_POINT_FORMXCAD=` precision highp float;
- uniform mat4 modelViewMatrix;
- uniform mat4 projectionMatrix;
- uniform vec3 color;
- attribute vec2 position;
- attribute vec4 tran1;
- attribute vec4 tran2;
- attribute vec4 tran3;
- attribute vec4 tran4;
- attribute float ishide;
- varying vec4 vColor;
- void main(){
- mat4 tran;
- tran[0][0] = tran1.x;tran[0][1] = tran1.y;tran[0][2] = tran1.z;tran[0][3] = tran1.w;
- tran[1][0] = tran2.x;tran[1][1] = tran2.y;tran[1][2] = tran2.z;tran[1][3] = tran2.w;
- tran[2][0] = tran3.x;tran[2][1] = tran3.y;tran[2][2] = tran3.z;tran[2][3] = tran3.w;
- tran[3][0] = tran4.x;tran[3][1] = tran4.y;tran[3][2] = tran4.z;tran[3][3] = tran4.w;
- gl_PointSize = 1.0;
- if(ishide > 0.1)
- vColor = vec4(color,0.0);
- else
- vColor = vec4(color,1.0);
- gl_Position = projectionMatrix * modelViewMatrix * tran * vec4( position.x,position.y,0.0, 1.0 );
- }
- `,n.FSHADER_COLOR_POINT_FORMXCAD=` precision highp float;
- varying vec4 vColor;
- void main() {
- gl_FragColor = vColor;
- }
- `,n.VSHADER_COLOR_POINT_CLIP_FORMXCAD=` precision highp float;
- uniform mat4 modelViewMatrix;
- uniform mat4 projectionMatrix;
- uniform vec3 color;
- uniform vec2 clippt1;
- uniform vec2 clippt2;
- uniform float vieww;
- uniform float viewh;
- attribute vec2 position;
- attribute vec4 tran1;
- attribute vec4 tran2;
- attribute vec4 tran3;
- attribute vec4 tran4;
- attribute float ishide;
- varying vec4 vColor;
- varying vec2 vCp1;
- varying vec2 vCp2;
- void main(){
- mat4 tran;
- tran[0][0] = tran1.x;tran[0][1] = tran1.y;tran[0][2] = tran1.z;tran[0][3] = tran1.w;
- tran[1][0] = tran2.x;tran[1][1] = tran2.y;tran[1][2] = tran2.z;tran[1][3] = tran2.w;
- tran[2][0] = tran3.x;tran[2][1] = tran3.y;tran[2][2] = tran3.z;tran[2][3] = tran3.w;
- tran[3][0] = tran4.x;tran[3][1] = tran4.y;tran[3][2] = tran4.z;tran[3][3] = tran4.w;
- vec4 pt1 = projectionMatrix * modelViewMatrix * vec4( clippt1.x,clippt1.y,0.0, 1.0 );
- vec4 pt2 = projectionMatrix * modelViewMatrix * vec4( clippt2.x,clippt2.y,0.0, 1.0 );
- vCp1 = vec2(pt1.x * vieww + vieww,pt1.y * viewh + viewh);
- vCp2 = vec2(pt2.x * vieww + vieww,pt2.y * viewh + viewh);
- if(ishide > 0.1)
- vColor = vec4(color,0.0);
- else
- vColor = vec4(color,1.0);
- gl_Position = projectionMatrix * modelViewMatrix * tran * vec4( position.x,position.y,0.0, 1.0 );
- }
- `,n.FSHADER_COLOR_POINT_CLIP_FORMXCAD=`precision highp float;
- varying vec4 vColor;
- varying vec2 vCp1;
- varying vec2 vCp2;
- void main() {
- if(gl_FragCoord.x > vCp1.x && gl_FragCoord.x < vCp2.x && gl_FragCoord.y > vCp1.y && gl_FragCoord.y < vCp2.y)
- gl_FragColor = vColor;
- else
- discard;
- }
- `},{}],33:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxStencilObject=void 0;var n=t("three"),u=t("./MxMaterial"),c=(y.prototype.object_onAfterRender=function(b){var m=this.aryMeshStencil;if(m&&0<m.length){b.getContext();var O=b.state.buffers;O.stencil.setLocked(!1),O.depth.setTest(!0),O.stencil.setTest(!1)}},y.prototype.object_onBeforeRender=function(b,m,O){var N=this.aryMeshStencil;if(N&&0<N.length){var L=b.getContext(),G=b.state.buffers;G.color.setMask(!1),G.color.setLocked(!0),G.depth.setTest(!1),G.stencil.setTest(!0),G.stencil.setMask(255),G.stencil.setClear(0),b.clearStencil(),G.stencil.setLocked(!0);var q=1,J=!0;N.forEach(function(fe){J?(J=!1,G.stencil.setFunc(L.ALWAYS,q,255),G.stencil.setOp(L.KEEP,L.KEEP,L.REPLACE)):(G.stencil.setFunc(L.EQUAL,q,255),G.stencil.setOp(L.KEEP,L.KEEP,L.INCR),q++),b.mxRenderObject(fe,m,O,fe.material,null)}),G.color.setLocked(!1),G.color.setMask(!0),G.stencil.setMask(0),G.stencil.setFunc(L.EQUAL,q,255)}},y.prototype.associateObject=function(b,m){var O=this;m.forEach(function(L){if(3<=L.length){var G=new n.Shape(L),q=new n.ShapeGeometry(G),J=new n.Mesh(q,u.MxMaterial.getStencilMaterial());O.aryMeshStencil.push(J)}});var N=this;b.onBeforeRender=function(L,G,q){N.object_onBeforeRender(L,G,q)},b.onAfterRender=function(L){N.object_onAfterRender(L)}},y);function y(){this.aryMeshStencil=[]}l.MxStencilObject=c},{"./MxMaterial":30,three:19}],34:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxString=void 0;var n=(u.prototype.Find=function(c){return this.m_val.indexOf(c)},u.prototype.Left=function(c){return this.m_val.substring(0,c)},u.prototype.Right=function(c){return this.m_val.substring(this.m_val.length-c,this.m_val.length)},u.prototype.TrimLeft=function(c){for(;0<this.m_val.length&&this.m_val[0]==c;)this.m_val=this.m_val.slice(1)},u.prototype.TrimRight=function(c){for(;0<this.m_val.length&&this.m_val[this.m_val.length-1]==c;)this.m_val=this.m_val.slice(0,-1)},u.prototype.AnalyzeString=function(c){return this.m_val.split(c)},u.prototype.IsEmpty=function(){return this.m_val.length==0},u.prototype.MakeUpper=function(){this.m_val=this.m_val.toUpperCase()},u.prototype.MakeLower=function(){this.m_val=this.m_val.toLowerCase()},u.prototype.GetLength=function(){return this.m_val.length},u);function u(c){this.m_val="",c!=null&&(this.m_val=c)}l.MxString=n},{}],35:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxSystemVariable=void 0;var n=t("three"),u=t("./Operate/McEdJigOsnap"),c=(y.prototype.init=function(b){this.m_mxObj=b},y.prototype.getAllLinetypeName=function(){return this.m_vecLinetype},y.prototype.getSysVarBool=function(b){return this.m_data[b]!=null&&this.m_data[b]},y.prototype.setSysVarBool=function(b,m){this.m_data[b]=m},y.prototype.setSysVarPoint=function(b,m){this.m_data[b]=m},y.prototype.OnMessageMxCADSystemVariable=function(b){this.m_vecLinetype=[];var m=JSON.parse(b);if(m!=null){var O=m.vecLinetypeName;for(var N in O)this.m_vecLinetype.push(O[N]);this.m_data.CELTYPE=m.curLinetypeName,this.m_data.CLAYER=m.clayer,this.m_data.CECOLOR=m.cecolor,this.m_data.CECOLORINDEX=m.cecolorindex}this.m_mxObj.callEvent("loadSystmeVariableComplete")},y.prototype.getSysVarPoint=function(b){return this.m_data[b]==null?new n.Vector3(0,0,0):this.m_data[b]},y.prototype.setSysVarNumber=function(b,m){this.m_data[b]=m},y.prototype.getSysVarNumber=function(b){return this.m_data[b]==null?0:this.m_data[b]},y.prototype.getSysVar=function(b){return this.m_data[b]},y.prototype.setSysVar=function(b,m){this.m_data[b]=m},y);function y(){this.m_data={},this.m_mxObj=null,this.m_vecLinetype=[],this.m_data.GETPOINTSTATUS=0,this.m_data.LASTPOINT=void 0,this.m_data.LASTMOVEPOINT=void 0,this.m_data.CELTYPE="Continuous",this.m_data.CLAYER="0",this.m_data.CECOLOR=67108863,this.m_data.CECOLORINDEX=7,this.m_data.OSMODE=u.MxOsnapDefine.OsModeAll}l.MxSystemVariable=c},{"./Operate/McEdJigOsnap":43,three:19}],36:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxTempMarkDraw=void 0;var n=t("three"),u=t("./MxFun"),c=t("./MxThreeJS"),y=(b.prototype.init=function(m){this.threeObjectGroup=new n.Object3D,m.addObject(this.threeObjectGroup)},b.prototype.clear=function(m){m||u.MxFun.removeThreejsAllChildren(this.threeObjectGroup)},b.prototype.drawLine=function(m,O,N,L){N===void 0&&(N=16777215),L===void 0&&(L=1),this.threeObjectGroup.add(c.MxThreeJS.createLine(m,O,N,L))},b.prototype.drawCircle=function(m,O,N){this.threeObjectGroup.add(c.MxThreeJS.createCircle(m,O,N))},b.prototype.drawEntity=function(m){this.threeObjectGroup.add(m)},b.prototype.drawCircleMark=function(m,O,N){this.drawCircle(m,O,N);var L=new n.Vector3(.3*O,0,0);L.applyAxisAngle(new n.Vector3(0,0,1),60*Math.PI/180);var G=new n.Vector3(.3*O,0,0);G.applyAxisAngle(new n.Vector3(0,0,1),30*Math.PI/180);var q=new n.Vector3(O,0,0);q.applyAxisAngle(new n.Vector3(0,0,1),45*Math.PI/180);var J=m.clone().add(L),fe=m.clone().add(G),ve=m.clone().add(q);this.drawLine(m,J,N),this.drawLine(m,fe,N),this.drawLine(m,ve,N)},b);function b(){this.threeObjectGroup=null}l.MxTempMarkDraw=y},{"./MxFun":27,"./MxThreeJS":37,three:19}],37:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxThreeJS=void 0;var n,u=t("three"),c=t("./MxFun");function y(b){return Math.pow(2,Math.floor(Math.log(b)/Math.LN2))}(n=l.MxThreeJS||(l.MxThreeJS={})).createLine=function(b,m,O,N){var L,G=new u.Geometry;return L=N&&N!=1||N==0?new u.LineBasicMaterial({color:O,transparent:!0,depthTest:!1,opacity:N}):new u.LineBasicMaterial({color:O,transparent:!0,depthTest:!1}),G.vertices.push(b,m),new u.Line(G,L)},n.createSolid=function(b,m,O){if(b.length<3)return null;var N,L=new u.Shape(b.map(function(q){var J=q.x,fe=q.y;return new u.Vector2(J,fe)})),G=new u.ShapeGeometry(L);return N=O&&O!=1||O==0?new u.MeshPhongMaterial({color:m,side:u.DoubleSide,transparent:!0,depthTest:!1,opacity:O}):new u.MeshPhongMaterial({color:m,side:u.DoubleSide,transparent:!0,depthTest:!1}),new u.Mesh(G,N)},n.createPoint=function(b,m,O){O===void 0&&(O=3);var N=new u.Geometry;N.vertices.push(b);var L=new u.PointsMaterial({color:m,size:O});return new u.Points(N,L)},n.createDashedLine=function(b,m,O,N,L){var G=new u.Geometry;G.vertices.push(b,m);var q=new u.Line(G,new u.LineDashedMaterial({color:O,dashSize:N,gapSize:L,transparent:!0,depthTest:!1}));return q.computeLineDistances(),q},n.createCircle=function(b,m,O){var N=new u.CircleGeometry(m,64,3,2*Math.PI),L=new u.LineBasicMaterial({color:O,transparent:!0,depthTest:!1});N.vertices.shift();var G=new u.LineLoop(N,L);return G.position.x=b.x,G.position.y=b.y,G.position.z=b.z,G},n.createSolidCircle=function(b,m,O){var N=new u.MeshBasicMaterial({color:O,transparent:!0,depthTest:!1}),L=new u.CircleGeometry(m,64,3,2*Math.PI),G=new u.Mesh(L,N);return G.position.x=b.x,G.position.y=b.y,G.position.z=b.z,G},n.clacTextSize=function(b,m){var O=document.createElement("canvas").getContext("2d");if(O==null)return m;var N=c.MxFun.formatString("normal {0}px Arial","256");return O.font=N,O.measureText(b).width*m/256},n.clacTextSpriteSize=function(b,m,O){m<=1e-8&&(m=1);var N=document.createElement("canvas"),L=N.getContext("2d"),G=c.MxFun.formatString("normal {0}px Arial","256");L.font=G;var q=m/256,J=0,fe=[],ve=!0,ne=0;if(O){J=O;for(var Ue=0,De=0,Ve=0;De<b.length;De++)(rt=L.measureText(b.substring(Ue,De+1))).width*q>J&&(ne+=(rt.fontBoundingBoxAscent+rt.fontBoundingBoxDescent)*q,fe.push(b.substring(Ue,De)),Ue=De,Ve++);if(Ue<De){var rt=L.measureText(b.substring(Ue,De));fe.push(b.substring(Ue,De)),ne+=(rt.fontBoundingBoxAscent+rt.fontBoundingBoxDescent)*q,Ve++}ve=Ve<=1}else ne=m,J=(rt=L.measureText(b)).width*q,fe.push(b),ve=!1;var Ae=ne/J*(N.width=1024);return N.height=y(Ae),N.height<Ae&&(N.height*=2),N.height==0&&(N.height=512),{spritewidth:J,spriteheight:J*N.height/N.width,textwidth:J,allTextHeight:ne,singleline:ve}},n.creatTextSprite=function(b,m,O,N,L,G,q){O<=1e-8&&(O=1);var J=document.createElement("canvas"),fe=J.getContext("2d");q?(fe.font=q(256),fe.font.length==0&&(fe.font=c.MxFun.formatString("normal {0}px Arial","256"))):fe.font=c.MxFun.formatString("normal {0}px Arial","256");var ve=O/256,ne=0,Ue=[],De=[],Ve=0;if(G){ne=G;for(var rt=0,Ae=0;Ae<b.length;Ae++)(Xe=fe.measureText(b.substring(rt,Ae+1))).width*ve>ne&&(Ve+=Te=(Xe.fontBoundingBoxAscent+Xe.fontBoundingBoxDescent)*ve,Ue.push(b.substring(rt,Ae)),De.push(Te),rt=Ae);if(rt<Ae){var Te,Xe=fe.measureText(b.substring(rt,Ae));Ue.push(b.substring(rt,Ae)),Ve+=Te=(Xe.fontBoundingBoxAscent+Xe.fontBoundingBoxDescent)*ve,De.push(Te)}}else Ve=O,ne=(Xe=fe.measureText(b)).width*ve,Ue.push(b),De.push(Ve);var ie=Ve/ne*(J.width=1024);J.height=y(ie),J.height<ie&&(J.height*=2),J.height==0&&(J.height=512);var ue=1024/ne,pt=ue*O;q?(fe.font=q(pt),fe.font.length==0&&(fe.font=c.MxFun.formatString("normal {0}px Arial",""+pt))):fe.font=c.MxFun.formatString("normal {0}px Arial",""+pt);var mt=c.MxFun.formatString("rgba({0}, {1}, {2}, 1.0)",(L>>16&255)+"",(L>>8&255)+"",(255&L)+"");fe.fillStyle=mt,fe.textAlign="left",fe.textBaseline="bottom";for(var Tt=0,kt=0;Tt<Ue.length;Tt++)kt+=ue*De[Tt];for(Tt=0,kt=.5*(J.height-kt);Tt<Ue.length;Tt++)kt+=ue*De[Tt],fe.fillText(Ue[Tt],0,kt);var It=new u.Texture(J);It.needsUpdate=!0;var nn=new u.SpriteMaterial({transparent:!0,depthTest:!1,map:It});nn.rotation=N;var tn=new u.Sprite(nn);return tn.scale.set(ne,ne/J.width*J.height,1),tn.position.set(m.x,m.y,m.z),tn},n.createTriangle=function(b,m,O){if(!(b.length<3)){for(var N=b.length,L=new u.Geometry,G=0;G+2<N;G+=3){L.vertices.push(b[G]),L.vertices.push(b[G+1]),L.vertices.push(b[G+2]);var q=new u.Face3(G,G+1,G+2);L.faces.push(q)}L.computeFaceNormals(),L.computeVertexNormals(),O==null&&(O=1);var J=new u.MeshBasicMaterial({color:m,transparent:!0,depthTest:!1,side:u.DoubleSide,opacity:O});return new u.Mesh(L,J)}},n.createLines=function(b,m,O){var N,L=new u.Geometry;return L.vertices=b,N=O&&O!=1||O==0?new u.LineBasicMaterial({color:m,transparent:!0,depthTest:!1,opacity:O}):new u.LineBasicMaterial({color:m,transparent:!0,depthTest:!1}),new u.Line(L,N)},n.createDashedArc=function(b,m,O,N,L,G,q){var J=new u.CircleGeometry(m,64,O,N),fe=new u.LineDashedMaterial({color:L,dashSize:G,gapSize:q,transparent:!0,depthTest:!1});J.vertices.shift();var ve=new u.Line(J,fe);return ve.position.x=b.x,ve.position.y=b.y,ve.position.z=b.z,ve},n.createDashedLines=function(b,m,O,N){var L=new u.Geometry;return L.vertices=b,new u.Line(L,new u.LineDashedMaterial({color:m,dashSize:O,gapSize:N,transparent:!0,depthTest:!1}))}},{"./MxFun":27,three:19}],38:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxPair=l.MxTools=void 0;var n,u=t("three");(n=l.MxTools||(l.MxTools={})).AsMxWebPoint=function(c,y,b){return new u.Vector3(-c,b,y)},n.AsMxWebPoint_pt=function(c){return new u.Vector3(-c.x,c.z,c.y)},n.AsThreeJsPoint=function(c,y,b){return new u.Vector3(-c,b,y)},n.stringTrimLeftSpace=function(c){return c.replace(/^\s*/g,"")},n.stringDeleteAllSpace=function(c){return c.replace(/\s*/g,"")},n.stringTrimLeftRightSpace=function(c){return c.replace(/^\s*|\s*$/g,"")},n.stringTrimRightSpace=function(c){return c.replace(/(\s*$)/g,"")},n.IsNumerical=function(c){if(typeof c=="string"){var y=/^(-(([0-9]+\.[0-9]*[1-9][0-9]*)|([0-9]*[1-9][0-9]*\.[0-9]+)|([0-9]*[1-9][0-9]*)))$/;return!(!/^\d+(\.\d+)?$/.test(c)&&!y.test(c))}var b=c.m_val;return y=/^(-(([0-9]+\.[0-9]*[1-9][0-9]*)|([0-9]*[1-9][0-9]*\.[0-9]+)|([0-9]*[1-9][0-9]*)))$/,!(!/^\d+(\.\d+)?$/.test(b)&&!y.test(b))},n.formatString=function(c){for(var y=[],b=1;b<arguments.length;b++)y[b-1]=arguments[b];for(var m=0;m<y.length;m++)c=c.replace("{"+m+"}",y[m]);return c},n._tstof=function(c){return parseFloat(c)},n._tstoi=function(c){return parseInt(c)},n.IsZero=function(c){return-1e-7<c&&c<1e-7},n.MillimeterToPixels=function(c){return 10*c},n.getXYPlanDistance=function(c,y){var b=new u.Vector2(c.x,c.y),m=new u.Vector2(y.x,y.y);return b.distanceTo(m)},n.MxASSERT=function(c,y){c||console.log("MxASSERT(0):"+y)},n.generateUUID=function(){return u.MathUtils.generateUUID()},n.MxMax=function(c,y){return y<c?c:y},n.getOpacity=function(c){var y=(4278190080&c)>>24&255;return y<=0&&(y=255),y/255},n.getColor=function(c){return 16777215&c},l.MxPair=function(c,y){this.first=c,this.second=y}},{three:19}],39:[function(t,e,l){var n,u,c;Object.defineProperty(l,"__esModule",{value:!0}),l.MxType=void 0,(u=(n=l.MxType||(l.MxType={})).MxCommandFlag||(n.MxCommandFlag={}))[u.MCRX_CMD_MODAL=0]="MCRX_CMD_MODAL",u[u.MCRX_CMD_TRANSPARENT=1]="MCRX_CMD_TRANSPARENT",u[u.MCRX_CMD_NO_UNDO_MARKER=2]="MCRX_CMD_NO_UNDO_MARKER",u[u.MCRX_CMD_NOPRV=4]="MCRX_CMD_NOPRV",u[u.MCRX_CMD_NO_RECORD_PRVCMD=8]="MCRX_CMD_NO_RECORD_PRVCMD",u[u.MCRX_CMD_NO_CLEAR_SELECT=16]="MCRX_CMD_NO_CLEAR_SELECT",(c=n.MxCloneType||(n.MxCloneType={}))[c.kClone=1]="kClone",c[c.kDragClone=2]="kDragClone",c[c.kMxFileClone=3]="kMxFileClone",c[c.kSaveDwgClone=4]="kSaveDwgClone"},{}],40:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxBulid=void 0,window.MxDrawVersion="1.0(2024-10-11 11:06)",(l.MxBulid||(l.MxBulid={})).getVersion=function(){return window.MxDrawVersion?window.MxDrawVersion:"inalid version"}},{}],41:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxWindowsEvent=void 0;var n,u,c,y=t("./MxFun"),b=t("./Operate/MxJigCmdManager"),m=t("./MxDrawData"),O=t("./UI/MxUiVue");function N(ve,ne){for(var Ue=0,De=c.length;Ue<De;Ue++){var Ve=c[Ue](ve,ne);if(Ve!=0)return Ve}}function L(ve){N("mousemove",ve)}function G(ve){N("mouseup",ve)}function q(ve){N("dblclick",ve)}function J(ve){N("mousedown",ve)}function fe(ve){var ne=ve||window.event||arguments.callee.caller.arguments[0];if(ne&&ne.keyCode==27){var Ue=y.MxFun.getCurrentMx();if(Ue.isPaningCommand())return void Ue.endPanCommand();if(b.MxJigCmdManager.isRunning()){if(b.MxJigCmdManager.getCurCmd().getDynImput().onKeyEcsDown()!=0)return;b.MxJigCmdManager.stopCmd(b.MxJigCmdManager.DetailedResult.kEcsIn)}else{var De=!1;if(m.MxDrawData.m_isEnableIntelliSelect){var Ve=!1;Ue.getMxDatabase().getGripManager().removeAllGrips()&&(Ve=!0),Ue.getMxDatabase().getSelectManager().removeAllEntity()&&(Ve=!0),Ue.isValidMcObject()&&Ue.getMcObject().getGripManager().clearAll()&&(Ve=!0),Ve&&(Ue.updateDisplay(),Ue.getMxDatabase().getGripManager().fireMxEntitySelectChange(),De=!0)}De||O.MxUiVue.acutPrintf(` *取消*
- 命令:`)}}}n=l.MxWindowsEvent||(l.MxWindowsEvent={}),u=!1,c=new Array,n.addEvent=function(ve){c.push(ve)},n.registEvent=function(){u||(u=!0,y.MxFun.isPC()&&(document.addEventListener("mousemove",L,!1),document.addEventListener("mouseup",G,!1),document.addEventListener("mousedown",J,!1),document.addEventListener("dblclick",q,!1),document.onkeydown=fe))}},{"./MxDrawData":22,"./MxFun":27,"./Operate/MxJigCmdManager":54,"./UI/MxUiVue":65}],42:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.McEdJigDynamicTrace=void 0;var n=t("three"),u=t("./MxJigCmdManager"),c=t("../MxFun"),y=t("../MxDrawData"),b=t("../MxTools"),m=t("../MxManager"),O=t("../MxThreeJS"),N=t("./McEdJigOsnap"),L=(G.prototype.IsEqual=function(ne){return this.m_snapObjectId==ne.m_snapObjectId&&this.m_pt.distanceTo(ne.m_pt)<1e-6},G.prototype.drawLine=function(ne,Ue,De){var Ve=O.MxThreeJS.createLine(new n.Vector3(ne.x,ne.y,ne.z),new n.Vector3(Ue.x,Ue.y,Ue.z),this.m_iColor);De.add(Ve),this.m_aryDynDrawObject.push(Ve)},G.prototype.clearDraw=function(ne){for(var Ue=this.m_aryDynDrawObject.length,De=0;De<Ue;De++)c.MxFun.removeThreejsObject(this.m_aryDynDrawObject[De],ne);this.m_aryDynDrawObject=[]},G.prototype.draw=function(ne,Ue){var De=ne.toSmallcoord(this.m_pt),Ve=new n.Vector3(De.x,De.y+this.m_iGripWidth,0),rt=new n.Vector3(De.x,De.y-this.m_iGripWidth,0);this.drawLine(Ve,rt,Ue);var Ae=new n.Vector3(De.x+this.m_iGripWidth,De.y,0),Te=new n.Vector3(De.x-this.m_iGripWidth,De.y,0);this.drawLine(Ae,Te,Ue)},G);function G(){this.m_snapObjectId=0,this.m_pt=new n.Vector3,this.m_osmode=0,this.m_iColor=16760703,this.m_iGripWidth=10,this.m_aryDynDrawObject=new Array}var q=(J.prototype.clearDraw=function(ne){for(var Ue=this.m_aryDynDrawObject.length,De=0;De<Ue;De++)c.MxFun.removeThreejsObject(this.m_aryDynDrawObject[De],ne);this.m_aryDynDrawObject=[]},J.prototype.draw=function(ne,Ue){this.m_draw.setWidth(this.m_iGripWidth),this.m_draw.draw(ne.toSmallcoord(this.m_pt),this.m_ostype,Ue)},J);function J(ne,Ue){var De=this;this.m_aryDynDrawObject=new Array,this.m_iGripWidth=10,this.m_draw=new N.McEdJigOsnapDraw,this.m_pt=ne,this.m_ostype=Ue,this.m_draw.setAddDynDrawObject_call(function(Ve){De.m_aryDynDrawObject.push(Ve)})}var fe=(ve.prototype.DynamicTraceTimeCall=function(ne){if(!this.m_mxJig.isExit()&&this.m_iTimeCallId==ne&&this.m_isDynTrace&&this.m_snapObjectId!=0){var Ue=new L;Ue.m_osmode=this.m_osmode,Ue.m_snapObjectId=this.m_snapObjectId,Ue.m_pt=this.m_ptSnapPoint,Ue.m_iGripWidth=.5*this.m_mxJig.getMxObject().screenCoordLong2Doc(y.MxDrawData.m_dInputRectWidth);for(var De=this.m_aryTraceObject.length,Ve=this.m_mxJig.getMxObject().getTheTempDrawContainer_SmallCoord(),rt=0;rt<De;rt++)if(this.m_aryTraceObject[rt].IsEqual(Ue))return this.m_aryTraceObject[rt].clearDraw(Ve),void this.m_aryTraceObject.splice(rt,1);this.m_aryTraceObject.push(Ue),Ue.draw(this.m_mxJig.getMxObject(),Ve),this.m_mxJig.getMxObject().updateDisplay()}},ve.prototype.OnDynamicTrace=function(ne,Ue,De){if(this.m_isDynTrace)if(ne==0)this.m_iTimeCallId++,this.m_snapObjectId=0;else{if(De==u.MxJigCmdManager.OsnapMode.kOsModeNear)return;var Ve=.5*this.m_mxJig.getMxObject().screenCoordLong2Doc(y.MxDrawData.m_dInputRectWidth);if(this.m_snapObjectId!=0&&this.m_ptSnapPoint.distanceTo(Ue)<Ve)return;var rt=this.m_iTimeCallId,Ae=this;setTimeout(function(){Ae.DynamicTraceTimeCall(rt)},400),this.m_snapObjectId=ne,this.m_ptSnapPoint=Ue,this.m_osmode=De}},ve.prototype.ClearOsmodeObjectDisplay=function(){for(var ne=this.m_mxJig.getMxObject().getTheTempDrawContainer_SmallCoord(),Ue=this.m_aryTraceOsmodeObject.length,De=0;De<Ue;De++)this.m_aryTraceOsmodeObject[De].clearDraw(ne);this.m_aryTraceOsmodeObject=[]},ve.prototype.ClearTraceObject=function(){for(var ne=this.m_mxJig.getMxObject().getTheTempDrawContainer_SmallCoord(),Ue=this.m_aryTraceObject.length,De=0;De<Ue;De++)this.m_aryTraceObject[De].clearDraw(ne);this.m_aryTraceObject=[]},ve.prototype.ClearDisplay=function(){this.ClearTraceObject(),this.ClearOsmodeObjectDisplay(),this.ClearDynDrawEntity()},ve.prototype.GetTraceLine=function(ne,Ue,De,Ve){var rt=Ue.m_pt;if(rt.distanceTo(ne)<2*De)return[];var Ae={pt1:new n.Vector3(rt.x-Ve,rt.y),pt2:new n.Vector3(rt.x+Ve,rt.y)},Te={pt1:new n.Vector3(rt.x,rt.y-Ve),pt2:new n.Vector3(rt.x,rt.y+Ve)},Xe=[];Xe.push(Ae),Xe.push(Te);for(var ie=m.MxManager.getMxCpp().getMcDbCurve(Ue.m_snapObjectId);ie;){var ue=ie.getFirstDeriv(m.MxManager.getMxCpp().newMcGePoint3d(rt));if(ue.ret!=0||ue.val.isZeroLength())break;ue.val.normalize(),ue.val.mult(Ve);var pt={pt1:new n.Vector3(rt.x-ue.val.x,rt.y-ue.val.y),pt2:new n.Vector3(rt.x+ue.val.x,rt.y+ue.val.y)};Xe.push(pt),ue.val.rotateBy(Math.PI/2);var mt={pt1:new n.Vector3(rt.x-ue.val.x,rt.y-ue.val.y),pt2:new n.Vector3(rt.x+ue.val.x,rt.y+ue.val.y)};Xe.push(mt);break}return Xe},ve.prototype.ClearDynDrawEntity=function(){for(var ne=this.m_mxJig.getMxObject().getTheTempDrawContainer_SmallCoord(),Ue=this.m_vecDynDrawEntity.length,De=0;De<Ue;De++)c.MxFun.removeThreejsObject(this.m_vecDynDrawEntity[De],ne);this.m_vecDynDrawEntity=[]},ve.prototype.DoMouseMove=function(ne){if(this.ClearDynDrawEntity(),this.ClearOsmodeObjectDisplay(),this.m_isValidTracePoint=!1,!this.m_isDynTrace)return[];if(this.m_aryTraceObject.length==0)return[];for(var Ue=[],De=this.m_mxJig.getMxObject(),Ve=De.viewCoordLong2Cad(y.MxDrawData.m_dInputRectWidth),rt=2*Ve,Ae=De.viewCoordLong2Cad(De.getViewWidth()),Te=De.viewCoordLong2Cad(De.getViewHeight()),Xe=b.MxTools.MxMax(Ae,Te),ie=m.MxManager.getMxCpp().getMxCAD_App(),ue=this.m_mxJig.getMxObject().getTheTempDrawContainer_SmallCoord(),pt=this.m_mxJig.getMxObject().viewCoordLong2Cad(this.m_dashedLineLen),mt=0;mt<this.m_aryTraceObject.length-1;mt++){var Tt=this.m_aryTraceObject[mt],kt=Tt.m_pt,It=this.GetTraceLine(ne,Tt,rt,Xe);if(It.length!=0)for(var nn=mt+1;nn<this.m_aryTraceObject.length&&!this.m_isValidTracePoint;nn++){var tn=this.m_aryTraceObject[mt],pn=tn.m_pt,_n=this.GetTraceLine(ne,tn,rt,Xe);if(It.length!=0)for(var Dn=0;Dn<_n.length&&!this.m_isValidTracePoint;Dn++)for(var an=_n[Dn],Rn=0;Rn<It.length&&!this.m_isValidTracePoint;Rn++){var Lt=It[Rn],wn=ie.MxCADAssist.IntersectWith(Lt.pt1.x,Lt.pt1.y,Lt.pt2.x,Lt.pt2.y,an.pt1.x,an.pt1.y,an.pt2.x,an.pt2.y,3);if(0<wn.length()){var hn=wn.at(0),xn=new n.Vector3(hn.x,hn.y,hn.z);if(xn.distanceTo(ne)<rt){var $n=O.MxThreeJS.createDashedLine(De.toSmallcoord(Lt.pt1),De.toSmallcoord(Lt.pt2),this.m_iDashedLineLenColor,pt,pt);ue.add($n),this.m_vecDynDrawEntity.push($n);var Xr=O.MxThreeJS.createDashedLine(De.toSmallcoord(an.pt1),De.toSmallcoord(an.pt2),this.m_iDashedLineLenColor,pt,pt);ue.add(Xr),this.m_vecDynDrawEntity.push(Xr),Dn=_n.length,this.m_isValidTracePoint=!0,this.m_ptTracePoint=xn,this.CreteTracePoint(xn,Ve),Ue.push({pt:kt,ostype:Tt.m_osmode}),Ue.push({pt:pn,ostype:tn.m_osmode});break}}}}}if(this.m_isValidTracePoint||this.TracekPerpLine(ne,Ue,rt,Xe,Ve)||this.TracekTangLine(ne,Ue,rt,Xe,Ve))return Ue;for(mt=0;mt<this.m_aryTraceObject.length;mt++)if(kt=this.m_aryTraceObject[mt].m_pt,this.m_aryTraceObject[mt].m_osmode!=u.MxJigCmdManager.OsnapMode.kOsModePerp&&!(kt.distanceTo(ne)<2*rt)){var ti={pt1:new n.Vector3(kt.x-Xe,kt.y),pt2:new n.Vector3(kt.x+Xe,kt.y)};if(0<(Kn=ie.MxCADAssist.GetClosestPointTo(ti.pt1.x,ti.pt1.y,ti.pt2.x,ti.pt2.y,ne.x,ne.y,!0)).length()){var gn=Kn.at(0);if((Vn=new n.Vector3(gn.x,gn.y,gn.z)).distanceTo(ne)<rt){var Xn=O.MxThreeJS.createDashedLine(De.toSmallcoord(ti.pt1),De.toSmallcoord(ti.pt2),this.m_iDashedLineLenColor,pt,pt);ue.add(Xn),this.m_vecDynDrawEntity.push(Xn),this.m_isValidTracePoint=!0,this.m_ptTracePoint=Vn,Ue.push({pt:kt,ostype:this.m_aryTraceObject[mt].m_osmode}),this.CreteTracePoint(Vn,Ve);break}}var Kn,Vn,Yn={pt1:new n.Vector3(kt.x,kt.y-Xe),pt2:new n.Vector3(kt.x,kt.y+Xe)};if(0<(Kn=ie.MxCADAssist.GetClosestPointTo(Yn.pt1.x,Yn.pt1.y,Yn.pt2.x,Yn.pt2.y,ne.x,ne.y,!0)).length()&&(gn=Kn.at(0),(Vn=new n.Vector3(gn.x,gn.y,gn.z)).distanceTo(ne)<rt)){Xn=O.MxThreeJS.createDashedLine(De.toSmallcoord(Yn.pt1),De.toSmallcoord(Yn.pt2),this.m_iDashedLineLenColor,pt,pt),ue.add(Xn),this.m_vecDynDrawEntity.push(Xn),this.m_isValidTracePoint=!0,this.m_ptTracePoint=Vn,Ue.push({pt:kt,ostype:this.m_aryTraceObject[mt].m_osmode}),this.CreteTracePoint(Vn,Ve);break}}return Ue},ve.prototype.MouseMove=function(ne){var Ue=this.DoMouseMove(ne);if(this.m_isValidTracePoint)for(var De=this.m_mxJig.getMxObject().getTheTempDrawContainer_SmallCoord(),Ve=this.m_mxJig.getMxObject().screenCoordLong2Doc(y.MxDrawData.m_dInputRectWidth),rt=0;rt<Ue.length;rt++){var Ae=new q(Ue[rt].pt,Ue[rt].ostype);Ae.m_iGripWidth=Ve,Ae.draw(this.m_mxJig.getMxObject(),De),this.m_aryTraceOsmodeObject.push(Ae)}},ve.prototype.Init=function(){var ne=this.m_mxJig.getMxObject();ne.getMcObject().isValid()?(this.m_isDynTrace=ne.getSysVarLong("DYNTRACE")!=0,ne.sysVariable().getSysVarNumber("GETPOINTSTATUS")&u.MxJigCmdManager.GETPOINTSTATUS.OsModeDynTraceTempDisable&&(this.m_isDynTrace=!1),this.m_mxJig.isDisableDynamicTrace()&&(this.m_isDynTrace=!1),this.m_isDynTrace):this.m_isDynTrace=!1},ve.prototype.GetTracePoint=function(){if(this.m_isDynTrace)return this.m_isValidTracePoint?this.m_ptTracePoint:void 0},ve.prototype.ReSetTempDisplay=function(){this.ClearDynDrawEntity(),this.ClearOsmodeObjectDisplay(),this.m_isValidTracePoint=!1},ve.prototype.CreteTracePoint=function(ne,Ue){var De=this.m_mxJig.getMxObject(),Ve=De.getTheTempDrawContainer_SmallCoord();Ue/=2;var rt=O.MxThreeJS.createLine(De.toSmallcoord2(ne.x+Ue,ne.y+Ue,0),De.toSmallcoord2(ne.x-Ue,ne.y-Ue,0),16711680);Ve.add(rt),this.m_vecDynDrawEntity.push(rt);var Ae=O.MxThreeJS.createLine(De.toSmallcoord2(ne.x-Ue,ne.y+Ue,0),De.toSmallcoord2(ne.x+Ue,ne.y-Ue,0),16711680);Ve.add(Ae),this.m_vecDynDrawEntity.push(Ae)},ve.prototype.TracekPerpLine=function(ne,Ue,De,Ve,rt){for(var Ae=this.m_aryTraceObject,Te=Ae.length,Xe=m.MxManager.getMxCpp().getMxCAD_App(),ie=this.m_mxJig.getMxObject(),ue=ie.getTheTempDrawContainer_SmallCoord(),pt=ie.viewCoordLong2Cad(this.m_dashedLineLen),mt=0;mt<Te;mt++){var Tt=Ae[mt].m_pt;if(!(Tt.distanceTo(ne)<2*De)){var kt=m.MxManager.getMxCpp().getMcDbCurve(Ae[mt].m_snapObjectId);if(kt){var It=kt.getFirstDeriv(m.MxManager.getMxCpp().newMcGePoint3d(Tt));if(It.ret==0&&!It.val.isZeroLength()){It.val.normalize(),It.val.rotateBy(Math.PI/2),It.val.mult(Ve);var nn={pt1:new n.Vector3(Tt.x-It.val.x,Tt.y-It.val.y),pt2:new n.Vector3(Tt.x+It.val.x,Tt.y+It.val.y)},tn=Xe.MxCADAssist.GetClosestPointTo(nn.pt1.x,nn.pt1.y,nn.pt2.x,nn.pt2.y,ne.x,ne.y,!0);if(0<tn.length()){var pn=tn.at(0),_n=new n.Vector3(pn.x,pn.y,pn.z);if(_n.distanceTo(ne)<De){var Dn=O.MxThreeJS.createDashedLine(ie.toSmallcoord2(Tt.x-It.val.x,Tt.y-It.val.y,0),ie.toSmallcoord2(Tt.x+It.val.x,Tt.y+It.val.y,0),this.m_iDashedLineLenColor,pt,pt);ue.add(Dn),this.m_vecDynDrawEntity.push(Dn),this.m_isValidTracePoint=!0,this.m_ptTracePoint=_n,Ue.push({pt:Tt,ostype:Ae[mt].m_osmode}),this.CreteTracePoint(_n,rt);break}}}}}}return this.m_isValidTracePoint},ve.prototype.TracekTangLine=function(ne,Ue,De,Ve,rt){for(var Ae=this.m_aryTraceObject,Te=Ae.length,Xe=m.MxManager.getMxCpp().getMxCAD_App(),ie=this.m_mxJig.getMxObject(),ue=ie.getTheTempDrawContainer_SmallCoord(),pt=ie.viewCoordLong2Cad(this.m_dashedLineLen),mt=0;mt<Te;mt++){var Tt=Ae[mt].m_pt;if(!(Tt.distanceTo(ne)<2*De)){var kt=m.MxManager.getMxCpp().getMcDbCurve(Ae[mt].m_snapObjectId);if(kt){var It=kt.getFirstDeriv(m.MxManager.getMxCpp().newMcGePoint3d(Tt));if(It.ret==0&&!It.val.isZeroLength()){It.val.normalize(),It.val.mult(Ve);var nn={pt1:new n.Vector3(Tt.x-It.val.x,Tt.y-It.val.y),pt2:new n.Vector3(Tt.x+It.val.x,Tt.y+It.val.y)},tn=Xe.MxCADAssist.GetClosestPointTo(nn.pt1.x,nn.pt1.y,nn.pt2.x,nn.pt2.y,ne.x,ne.y,!0);if(0<tn.length()){var pn=tn.at(0),_n=new n.Vector3(pn.x,pn.y,pn.z);if(_n.distanceTo(ne)<De){var Dn=O.MxThreeJS.createDashedLine(ie.toSmallcoord2(Tt.x-It.val.x,Tt.y-It.val.y),ie.toSmallcoord2(Tt.x+It.val.x,Tt.y+It.val.y),this.m_iDashedLineLenColor,pt,pt);ue.add(Dn),this.m_vecDynDrawEntity.push(Dn),this.m_isValidTracePoint=!0,this.m_ptTracePoint=_n,Ue.push({pt:Tt,ostype:Ae[mt].m_osmode}),this.CreteTracePoint(_n,rt);break}}}}}}return this.m_isValidTracePoint},ve);function ve(ne){this.m_snapObjectId=0,this.m_ptSnapPoint=new n.Vector3,this.m_osmode=0,this.m_ptTracePoint=new n.Vector3,this.m_isValidTracePoint=!1,this.m_isDynTrace=!1,this.m_iTimeCallId=0,this.m_mxJig=null,this.m_aryTraceObject=[],this.m_aryTraceOsmodeObject=[],this.m_vecDynDrawEntity=[],this.m_dashedLineLen=1.5,this.m_iDashedLineLenColor=11184810,this.m_mxJig=ne}l.McEdJigDynamicTrace=fe},{"../MxDrawData":22,"../MxFun":27,"../MxManager":29,"../MxThreeJS":37,"../MxTools":38,"./McEdJigOsnap":43,"./MxJigCmdManager":54,three:19}],43:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.McEdJigOsnap=l.McEdJigOsnapDraw=l.McEdJigOrtho=l.McEdImpJigGlobalData=l.MxOsnapDefine=void 0;var n,u,c,y,b,m,O,N,L,G,q=t("three"),J=t("../MxDrawObject"),fe=t("../MxFun"),ve=t("./MxJigCmdManager"),ne=t("../MxTools"),Ue=t("../MxDrawData");(u=n=l.MxOsnapDefine||(l.MxOsnapDefine={}))[u.OsModeInvalid=0]="OsModeInvalid",u[u.OsModeEnd=1]="OsModeEnd",u[u.OsModeMid=2]="OsModeMid",u[u.OsModeCen=4]="OsModeCen",u[u.OsModeNode=8]="OsModeNode",u[u.OsModeQuad=16]="OsModeQuad",u[u.OsModeInt=32]="OsModeInt",u[u.OsModeIns=64]="OsModeIns",u[u.OsModePerp=128]="OsModePerp",u[u.OsModeTan=256]="OsModeTan",u[u.OsModeNear=512]="OsModeNear",u[u.OsModeApp=2048]="OsModeApp",u[u.OsModeExt=4096]="OsModeExt",u[u.OsModePar=8192]="OsModePar",u[u.OsModeOff=16384]="OsModeOff",u[u.OsModeAll=16383]="OsModeAll",y=c=l.McEdImpJigGlobalData||(l.McEdImpJigGlobalData={}),b=!1,m=new q.Vector3,O=new q.Vector3,L=N=!1,G=new Array,y.setPrvPoint=function(ie){m=ie,L=!0},y.isOsnapZValue=function(){return!1},y.setIsValidPrvpoint=function(ie){L=ie},y.isValidPrvpoint=function(){return L},y.getPrvPoint=function(){return m},y.setIsValidBasepoint=function(ie){b=ie},y.isValidBasepoint=function(){return b},y.setBasepoint=function(ie){b=!0,O=ie},y.getBasepoint=function(){return O},y.initStartCommand=function(){N=b=!1},y.setIsTmpDisableOsmode=function(ie){N=ie},y.isTmpDisableOsmode=function(){return N},y.addDynDrawObject=function(ie){G.push(ie)},y.clearDisplay=function(ie){for(var ue=G.length,pt=0;pt<ue;pt++)fe.MxFun.removeThreejsObject(G[pt],ie);G=[]};var De=(Ve.prototype.Init=function(){this.m_isTrace=!this.m_mxJig.isDisableOrthoTrace(),this.m_isValid=!1},Ve.prototype.OnViewMouseMove=function(ie){if(this.m_isTrace){var ue=this.m_mxJig.getMxObject(),pt=ue.sysVariable().getSysVarNumber("GETPOINTSTATUS");if(!(ue.getSysVarLong("ORTHOMODE")==0||pt&ve.MxJigCmdManager.GETPOINTSTATUS.OsModeOrthoTempDisable)&&pt&ve.MxJigCmdManager.GETPOINTSTATUS.OsModeSValidLastPoint){var mt=ue.sysVariable().getSysVarPoint("LASTPOINT");Math.abs(ie.x-mt.x)>Math.abs(ie.y-mt.y)?(this.m_ptOrtho.x=ie.x,this.m_ptOrtho.y=mt.y):(this.m_ptOrtho.x=mt.x,this.m_ptOrtho.y=ie.y),this.m_isValid=!0}else this.m_isValid=!1}},Ve.prototype.GetCurOrthoPoint=function(){return{pt:this.m_ptOrtho,isValid:this.m_isValid}},Ve);function Ve(ie){this.m_mxJig=null,this.m_ptOrtho=new q.Vector3,this.m_isValid=!1,this.m_isTrace=!0,this.m_mxJig=ie}l.McEdJigOrtho=De;var rt=(Ae.prototype.setAddDynDrawObject_call=function(ie){this.m_addDynDrawObject_call=ie},Ae.prototype.addDynDrawObject=function(ie){this.m_addDynDrawObject_call?this.m_addDynDrawObject_call(ie):c.addDynDrawObject(ie)},Ae.prototype.drawLine=function(ie,ue,pt){var mt=new q.Geometry,Tt=new q.LineBasicMaterial({color:this.m_iColor});mt.vertices.push(new q.Vector3(ie.x,ie.y,ie.z),new q.Vector3(ue.x,ue.y,ue.z));var kt=new q.Line(mt,Tt);pt.add(kt),this.addDynDrawObject(kt)},Ae.prototype.drawPolyline=function(ie,ue){for(var pt=new q.Geometry,mt=new q.LineBasicMaterial({color:this.m_iColor}),Tt=ie.length,kt=0;kt<Tt;kt++)pt.vertices.push(new q.Vector3(ie[kt].x,ie[kt].y,ie[kt].z));var It=new q.Line(pt,mt);ue.add(It),this.addDynDrawObject(It)},Ae.prototype.setWidth=function(ie){this.m_dOsmodeWdith=ie},Ae.prototype.GetDrawRect=function(){var ie=.5*this.m_dOsmodeWdith,ue={};return ue.left=this.m_pt.x-ie,ue.right=this.m_pt.x+ie,ue.top=this.m_pt.y-ie,ue.bottom=this.m_pt.y+ie,ue},Ae.prototype.DrawNear=function(ie){var ue=this.GetDrawRect(),pt=[new q.Vector3,new q.Vector3];pt[0].x=ue.left,pt[0].y=ue.top,pt[1].x=ue.right,pt[1].y=ue.top,this.drawLine(pt[0],pt[1],ie),pt[0].x=ue.left,pt[0].y=ue.bottom,pt[1].x=ue.right,pt[1].y=ue.bottom,this.drawLine(pt[0],pt[1],ie),pt[0].x=ue.right,pt[0].y=ue.top,pt[1].x=ue.left,pt[1].y=ue.bottom,this.drawLine(pt[0],pt[1],ie),pt[0].x=ue.right,pt[0].y=ue.bottom,pt[1].x=ue.left,pt[1].y=ue.top,this.drawLine(pt[0],pt[1],ie)},Ae.prototype.DrawEnd=function(ie){var ue=this.GetDrawRect(),pt=[new q.Vector3,new q.Vector3,new q.Vector3,new q.Vector3];pt[0].x=ue.left,pt[0].y=ue.top,pt[1].x=ue.right,pt[1].y=ue.top,pt[2].x=ue.right,pt[2].y=ue.bottom,pt[3].x=ue.left,pt[3].y=ue.bottom,this.drawLine(pt[0],pt[1],ie),this.drawLine(pt[1],pt[2],ie),this.drawLine(pt[2],pt[3],ie),this.drawLine(pt[3],pt[0],ie)},Ae.prototype.DrawMid=function(ie){var ue=this.GetDrawRect(),pt=1.2*(ue.right-ue.left),mt=pt/2/Math.sin(60*3.14159265/180),Tt=mt*Math.sin(.5235987750000001),kt=new q.Vector3(this.m_pt.x,this.m_pt.y,this.m_pt.z);kt.y-=mt;var It=new q.Vector3;It.x=this.m_pt.x+pt/2,It.y=this.m_pt.y+Tt;var nn=new q.Vector3;nn.x=this.m_pt.x-pt/2,nn.y=this.m_pt.y+Tt;var tn=[new q.Vector3,new q.Vector3,new q.Vector3,new q.Vector3];tn[0].x=kt.x,tn[0].y=kt.y,tn[1].x=It.x,tn[1].y=It.y,tn[2].x=nn.x,tn[2].y=nn.y,tn[3].x=kt.x,tn[3].y=kt.y,this.drawLine(tn[0],tn[1],ie),this.drawLine(tn[1],tn[2],ie),this.drawLine(tn[2],tn[3],ie)},Ae.prototype.DrawPerp=function(ie){var ue=this.GetDrawRect(),pt=[new q.Vector3,new q.Vector3,new q.Vector3];pt[0].x=ue.left,pt[0].y=ue.top,pt[1].x=ue.left,pt[1].y=ue.bottom,pt[2].x=ue.right,pt[2].y=ue.bottom,this.drawPolyline(pt,ie),pt[0].x=ue.left,pt[0].y=this.m_pt.y,pt[1].x=this.m_pt.x,pt[1].y=this.m_pt.y,pt[2].x=this.m_pt.x,pt[2].y=ue.bottom,this.drawPolyline(pt,ie)},Ae.prototype.DrawCircle=function(ie,ue,pt){pt==null&&(pt=.5*this.m_dOsmodeWdith);for(var mt=[],Tt=0,kt=3.14159265/180;Tt<=360;Tt+=15){var It=pt*Math.cos(Tt*kt)+ie.x,nn=pt*Math.sin(Tt*kt)+ie.y;mt.push(new q.Vector3(It,nn))}this.drawPolyline(mt,ue)},Ae.prototype.DrawInt=function(ie){var ue=this.GetDrawRect(),pt=[new q.Vector3,new q.Vector3];pt[0].x=ue.right,pt[0].y=ue.top,pt[1].x=ue.left,pt[1].y=ue.bottom,this.drawLine(pt[0],pt[1],ie),pt[0].x=ue.right,pt[0].y=ue.bottom,pt[1].x=ue.left,pt[1].y=ue.top,this.drawLine(pt[0],pt[1],ie)},Ae.prototype.DrawCen=function(ie){this.DrawInt(ie),this.DrawCircle(this.m_pt,ie)},Ae.prototype.DrawTan=function(ie){this.DrawEnd(ie)},Ae.prototype.DrawIns=function(ie){var ue=this.GetDrawRect(),pt={},mt=(ue.right-ue.left)/1.5;pt.left=this.m_pt.x-mt,pt.right=this.m_pt.x+mt,pt.top=this.m_pt.y-mt,pt.bottom=this.m_pt.y+mt;var Tt=this.m_pt.x,kt=this.m_pt.y,It=[new q.Vector3,new q.Vector3,new q.Vector3,new q.Vector3,new q.Vector3,new q.Vector3,new q.Vector3,new q.Vector3,new q.Vector3];It[0].x=pt.left,It[0].y=pt.top,It[1].x=pt.left,It[1].y=kt+2,It[2].x=Tt,It[2].y=kt+2,It[3].x=Tt,It[3].y=pt.bottom,It[4].x=pt.right,It[4].y=pt.bottom,It[5].x=pt.right,It[5].y=kt-2,It[6].x=Tt,It[6].y=kt-2,It[7].x=Tt,It[7].y=pt.top,It[8].x=pt.left,It[8].y=pt.top,this.drawPolyline(It,ie)},Ae.prototype.DrawNode=function(ie){var ue=this.GetDrawRect(),pt={},mt=(ue.right-ue.left)/1.5;pt.left=this.m_pt.x-mt,pt.right=this.m_pt.x+mt,pt.top=this.m_pt.y-mt,pt.bottom=this.m_pt.y+mt;var Tt=this.m_dOsmodeWdith/1.3;this.m_pt.x,this.m_pt.x,this.m_pt.y,this.m_pt.y;var kt=[new q.Vector3,new q.Vector3,new q.Vector3,new q.Vector3];kt[0].x=pt.left,kt[0].y=pt.top,kt[1].x=pt.right,kt[1].y=pt.bottom,kt[2].x=pt.left,kt[2].y=pt.bottom,kt[3].x=pt.right,kt[3].y=pt.top,this.drawLine(kt[0],kt[1],ie),this.drawLine(kt[2],kt[3],ie),this.DrawCircle(this.m_pt,ie,Tt)},Ae.prototype.draw=function(ie,ue,pt){this.m_pt=ie,this.m_osmode=ue;var mt=.5*this.m_dOsmodeWdith;if(this.m_osmode!=ve.MxJigCmdManager.OsnapMode.kOsModekInValid)if(this.m_osmode==ve.MxJigCmdManager.OsnapMode.kOsModeNear)this.DrawNear(pt);else if(this.m_osmode==ve.MxJigCmdManager.OsnapMode.kOsModeEnd)this.DrawEnd(pt);else if(this.m_osmode==ve.MxJigCmdManager.OsnapMode.kOsModeMid)this.DrawMid(pt);else if(this.m_osmode==ve.MxJigCmdManager.OsnapMode.kOsModePerp)this.DrawPerp(pt);else if(this.m_osmode==ve.MxJigCmdManager.OsnapMode.kOsModeInt)this.DrawInt(pt);else if(this.m_osmode==ve.MxJigCmdManager.OsnapMode.kOsModeCen)this.DrawCen(pt);else if(this.m_osmode==ve.MxJigCmdManager.OsnapMode.kOsModeTan)this.DrawTan(pt);else if(this.m_osmode==ve.MxJigCmdManager.OsnapMode.kOsModeIns)this.DrawIns(pt);else if(this.m_osmode==ve.MxJigCmdManager.OsnapMode.kOsModeNode)this.DrawNode(pt);else{var Tt=new q.Vector3(ie.x-mt,ie.y-mt,0),kt=new q.Vector3(ie.x+mt,ie.y+mt,0);this.drawLine(Tt,kt,pt);var It=new q.Vector3(ie.x-mt,ie.y+mt,0),nn=new q.Vector3(ie.x+mt,ie.y-mt,0);this.drawLine(It,nn,pt)}},Ae.prototype.upDisplay=function(ie,ue,pt){this.clearDisplay(pt);var mt=pt.getMxObject();this.setWidth(mt.screenCoordLong2Doc(Ue.MxDrawData.m_dInputRectWidth)),ie=mt.toSmallcoord(ie),this.draw(ie,ue,mt.getTheTempDrawContainer_SmallCoord())},Ae.prototype.clearDisplay=function(ie){var ue=ie.getMxObject().getTheTempDrawContainer_SmallCoord();c.clearDisplay(ue)},Ae);function Ae(){this.m_iColor=16711935,this.m_addDynDrawObject_call=void 0,this.m_pt=new q.Vector3,this.m_osmode=ve.MxJigCmdManager.OsnapMode.kOsModekInValid,this.m_dOsmodeWdith=10}l.McEdJigOsnapDraw=rt;var Te=(Xe.prototype.resetData=function(){this.m_osmode=ve.MxJigCmdManager.OsnapMode.kOsModekInValid,this.m_isValidPrvInputPoint=!1,this.m_lOSmode=0,this.m_vecOffset.set(0,0,0),this.m_isValid=!1,this.m_iLongprogressStatus=-1,this.reComputeOffset()},Xe.prototype.notifyOsnapToServer=function(){var ie=this;if(this.m_isRuning){var ue={ptx:this.m_pt.x,pty:this.m_pt.y,osmode:this.m_lOSmode,isValidPrvInputPoint:this.m_isValidPrvInputPoint};this.m_isValidPrvInputPoint&&(ue.prvPtx=this.m_prvInputPoint.x,ue.prvPty=this.m_prvInputPoint.y);var pt=this.m_mxJig.getMxObject();if(pt.getRunMode()==J.MxRunMode.kBrowse){var mt=this,Tt=pt.getCurrentMousePostion();pt.getObjectOsnap().getOsnapData(Tt,function(nn,tn){nn=pt.worldCoord2Doc(nn.x,nn.y,nn.z),mt.m_ptSnapPoint.x=nn.x,mt.m_ptSnapPoint.y=nn.y,mt.m_ptSnapPoint.z=0,mt.m_ptSnapSrcPoint.x=mt.m_pt.x,mt.m_ptSnapSrcPoint.y=mt.m_pt.y,mt.m_ptSnapSrcPoint.z=0,mt.m_osmode=tn,mt.m_draw.upDisplay(new q.Vector3(nn.x,nn.y,0),tn,mt.m_mxJig)})}else if(pt.getRunMode()==J.MxRunMode.kCPPMxCAD){var kt=this;ue.SearchRnge=pt.viewCoordLong2Cad(Ue.MxDrawData.m_dInputRectWidth),pt.getMcObject().onNotifyOsnap(ue,function(nn){kt.m_ptSnapPoint.x=nn.ptsx,kt.m_ptSnapPoint.y=nn.ptsy,kt.m_ptSnapPoint.z=nn.ptsz,kt.m_ptSnapSrcPoint.x=nn.ptx,kt.m_ptSnapSrcPoint.y=nn.pty,kt.m_ptSnapSrcPoint.z=0,kt.m_osmode=nn.osmode,kt.m_snapObjectId=nn.id,kt.m_draw.upDisplay(new q.Vector3(nn.ptsx,nn.ptsy,nn.ptsz),nn.osmode,kt.m_mxJig),kt.m_mxJig.onGetOsnapData(nn)})}else{ue.SearchRnge=pt.viewCoordLong2Cad(Ue.MxDrawData.m_dInputRectWidth);var It=this;pt.callCommand("MxCAD_NotifyOsnap",JSON.stringify(ue),function(nn){if(!(typeof nn!="string"||nn.length<1)&&It.m_isRuning){var tn=JSON.parse(nn);ie.m_ptSnapPoint.x=tn.ptsx,ie.m_ptSnapPoint.y=tn.ptsy,ie.m_ptSnapPoint.z=tn.ptsz,ie.m_ptSnapSrcPoint.x=tn.ptx,ie.m_ptSnapSrcPoint.y=tn.pty,ie.m_ptSnapSrcPoint.z=0,ie.m_osmode=tn.osmode,It.m_draw.upDisplay(new q.Vector3(tn.ptsx,tn.ptsy,tn.ptsz),tn.osmode,It.m_mxJig)}})}}},Xe.prototype.startDrag=function(ie,ue){this.m_mxJig=ue;var pt,mt,Tt=this.m_mxJig.getMxObject();function kt(){pt.notifyOsnapToServer()}return ue.isDisableOsnap()?this.m_isEnable=!1:this.m_isEnable=Tt.getInisetValue(J.IniSetName.kEnableOsnapFunction)===!0,this.m_isOffsetInputPostion=ie,this.m_isRuning=!0,this.resetData(),this.m_notifyOsnap_delayCall=(pt=this,mt=null,function(){clearTimeout(mt),mt=setTimeout(kt,20)}),!0},Xe.prototype.endDrag=function(){return this.m_isRuning=!1,this.m_draw.clearDisplay(this.m_mxJig),!0},Xe.prototype.reCompteCurrentPoint=function(ie){return this.m_isOffsetInputPostion&&ie.add(this.m_vecOffset),ie},Xe.prototype.isEnable=function(){var ie,ue=this.m_mxJig.getMxObject().getSysVarLong("OSMODE");return ie=!(ue==0||ue&n.OsModeOff||c.isTmpDisableOsmode()),this.m_isEnable&&ie},Xe.prototype.notifyOsnap=function(ie,ue){this.m_lOSmode=ie,ue==null?this.m_isValidPrvInputPoint=!1:(this.m_isValidPrvInputPoint=!0,this.m_prvInputPoint=ue),this.m_osmode==ve.MxJigCmdManager.OsnapMode.kOsModekInValid&&this.m_draw.clearDisplay(this.m_mxJig),this.m_notifyOsnap_delayCall()},Xe.prototype.setPoint=function(ie,ue){if(this.isEnable()){ie==null?(this.m_isValid=!1,this.m_osmode=ve.MxJigCmdManager.OsnapMode.kOsModekInValid):(this.m_iLongprogressStatus==-1||this.m_iLongprogressStatus,this.m_pt=ie,this.m_inPoint=ie,this.m_isValid=!0,(ue==null||this.m_osmode!=ve.MxJigCmdManager.OsnapMode.kOsModekInValid&&ne.MxTools.getXYPlanDistance(this.m_ptSnapSrcPoint,ie)>ue)&&(this.m_osmode=ve.MxJigCmdManager.OsnapMode.kOsModekInValid));var pt=this.m_mxJig.getMxObject().getSysVarLong("OSMODE"),mt=c.getPrvPoint();this.notifyOsnap(pt,c.isValidPrvpoint()?mt:void 0)}},Xe.prototype.seInValidPoint=function(){this.setPoint(void 0)},Xe.prototype.getCurrentOSnapPoint=function(ie){var ue={isSnapPoint:!1};return this.isEnable()?(ue.pt=ie,ue.osmode=this.m_osmode,this.m_osmode!=ve.MxJigCmdManager.OsnapMode.kOsModekInValid?(ue.isSnapPoint=!0,ue.pt.x=this.m_ptSnapPoint.x,ue.pt.y=this.m_ptSnapPoint.y,ue.pt.z=this.m_ptSnapPoint.z,c.isOsnapZValue()||(ie.z=0)):ue.pt=ie):(ue.pt=ie,ue.osmode=ve.MxJigCmdManager.OsnapMode.kOsModekInValid),ue},Xe.prototype.setLongprogressStatus=function(ie){this.m_iLongprogressStatus=ie},Xe.prototype.reComputeOffset=function(){if(this.m_isOffsetInputPostion){var ie=this.m_mxJig.getMxObject(),ue=ne.MxTools.MillimeterToPixels(8);ue=ie.screenCoordLong2Doc(ue),this.m_vecOffset.set(0,ue,0),this.m_vecOffset.applyAxisAngle(new q.Vector3(0,0,1),20*Math.PI/180)}},Xe);function Xe(ie){this.m_inPoint=new q.Vector3,this.m_vecOffset=new q.Vector3,this.m_pt=new q.Vector3,this.m_isValid=!1,this.m_ptSnapPoint=new q.Vector3,this.m_ptSnapSrcPoint=new q.Vector3,this.m_snapObjectId=0,this.m_osmode=ve.MxJigCmdManager.OsnapMode.kOsModekInValid,this.m_prvInputPoint=new q.Vector3,this.m_isValidPrvInputPoint=!1,this.m_lOSmode=0,this.m_iLongprogressStatus=-1,this.m_isOffsetInputPostion=!1,this.m_mxJig=null,this.m_notifyOsnap_delayCall=void 0,this.m_isRuning=!1,this.m_isEnable=!1,this.m_mxJig=ie,this.m_draw=new rt}l.McEdJigOsnap=Te},{"../MxDrawData":22,"../MxDrawObject":23,"../MxFun":27,"../MxTools":38,"./MxJigCmdManager":54,three:19}],44:[function(t,e,l){var n,u=this&&this.__extends||(n=function(ne,Ue){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(De,Ve){De.__proto__=Ve}||function(De,Ve){for(var rt in Ve)Object.prototype.hasOwnProperty.call(Ve,rt)&&(De[rt]=Ve[rt])})(ne,Ue)},function(ne,Ue){function De(){this.constructor=ne}n(ne,Ue),ne.prototype=Ue===null?Object.create(Ue):(De.prototype=Ue.prototype,new De)});Object.defineProperty(l,"__esModule",{value:!0}),l.McGiWorldDrawSelect=l.McGiWorldDraw=l.McGiWorldDrawType=void 0;var c,y,b=t("three"),m=t("../MxThreeJS"),O=t("../MxManager"),N=t("three.meshline"),L=t("../MxFun");(y=c=l.McGiWorldDrawType||(l.McGiWorldDrawType={}))[y.kWorldDraw=1]="kWorldDraw",y[y.kDynDragDraw=2]="kDynDragDraw",y[y.kSelectDraw=3]="kSelectDraw";var G=(q.prototype.getType=function(){return this.worldDrawType},q.prototype.setXData=function(ne){this.xData=ne},q.prototype.setMatrix=function(ne){this.matrix=ne},q.prototype.getMatrix=function(){return this.matrix},q.prototype.setOpacity=function(ne){this.opacity=ne},q.prototype.getOpacity=function(){return this.opacity},q.prototype.setColor=function(ne){ne=L.MxFun.getNumberColor(ne),this.iColor!=ne&&(this.widthMaterial=null),this.iColor=ne},q.prototype.setDash=function(ne,Ue){this.dDashArray=ne,this.dDashRatio=Ue},q.prototype.getDash=function(){return{dDashArray:this.dDashArray,dDashRatio:this.dDashRatio}},q.prototype.setDashLineDisplay=function(ne){ne?(this.dDashArray=.03,this.dDashRatio=.1,this.dLineWidth==0&&(this.dLineWidth=6,this.lineWidthByPixels=!0)):(this.dDashArray=0,this.dDashRatio=0)},q.prototype.isDashLineDisplay=function(){return 0<this.dDashArray&&0<this.dDashRatio},q.prototype.getColor=function(){return this.iColor},q.prototype.setRenderOrder=function(ne){this.iRenderOrder=ne},q.prototype.getRenderOrder=function(){return this.iRenderOrder},q.prototype.setLineWidthByPixels=function(ne){this.lineWidthByPixels!=ne&&(this.widthMaterial=null),this.lineWidthByPixels=ne},q.prototype.getLineWidthByPixels=function(){return this.lineWidthByPixels},q.prototype.setLineWidth=function(ne){this.dLineWidth!=ne&&(this.widthMaterial=null),this.dLineWidth=ne},q.prototype.getLineWidth=function(){return this.dLineWidth},q.prototype.drawEntity=function(ne){var Ue=this.iRenderOrder;ne.type=="Group"?ne.traverse(function(De){De.type!="Group"&&(De.renderOrder=Ue)}):ne.renderOrder=Ue,this.matrix!=null&&ne.applyMatrix4(this.matrix),this.aryEntity.push(ne),this.xData&&(ne.MxWordDrawXData=this.xData,this.xData=null)},q.prototype.getEntitys=function(){return this.aryEntity},q.prototype.getMxObject=function(){return this.mxObj},q.prototype.createWidthMaterial=function(){this.widthMaterial==null&&(0<this.dDashArray&&0<this.dDashRatio?this.widthMaterial=new N.MeshLineMaterial({useMap:!1,color:this.iColor,opacity:1,resolution:new b.Vector2(this.mxObj.getViewWidth(),this.mxObj.getViewHeight()),sizeAttenuation:!this.lineWidthByPixels,lineWidth:this.dLineWidth,transparent:!0,depthTest:!1,dashArray:this.dDashArray,dashRatio:this.dDashRatio}):this.widthMaterial=new N.MeshLineMaterial({useMap:!1,color:this.iColor,opacity:1,resolution:new b.Vector2(this.mxObj.getViewWidth(),this.mxObj.getViewHeight()),sizeAttenuation:!this.lineWidthByPixels,lineWidth:this.dLineWidth,transparent:!0,depthTest:!1}))},q.prototype.drawSolid=function(ne){if(!(ne.length<3)){var Ue=new b.Shape(ne.map(function(rt){var Ae=rt.x,Te=rt.y;return new b.Vector2(Ae,Te)})),De=new b.ShapeGeometry(Ue),Ve=new b.Mesh(De,new b.MeshPhongMaterial({color:this.getColor(),side:b.DoubleSide,transparent:!0,opacity:this.getOpacity()}));this.drawEntity(Ve)}},q.prototype.drawLines=function(ne){if(!(ne.length<2))if(this.dLineWidth!=0){this.createWidthMaterial();var Ue=new b.Geometry;Ue.vertices=ne;var De=new N.MeshLine;De.setGeometry(Ue);var Ve=new b.Mesh(De.geometry,this.widthMaterial);this.drawEntity(Ve),this.drawEntity(m.MxThreeJS.createLines(ne.slice(0),this.iColor,0))}else this.drawEntity(m.MxThreeJS.createLines(ne.slice(0),this.iColor,this.opacity))},q.prototype.drawGeometryLines=function(ne){if(!(ne.vertices.length<2))if(this.dLineWidth!=0){this.createWidthMaterial();var Ue=new N.MeshLine;if(!(ne instanceof b.Geometry)){var De=new b.Geometry;De.vertices=ne.vertices,ne=De}Ue.setGeometry(ne);var Ve=new b.Mesh(Ue.geometry,this.widthMaterial);this.drawEntity(Ve);var rt=new b.LineBasicMaterial({color:this.iColor,transparent:!0,depthTest:!1,opacity:0}),Ae=new b.Line(ne,rt);this.drawEntity(Ae)}else rt=void 0,rt=this.opacity&&this.opacity!=1||this.opacity==0?new b.LineBasicMaterial({color:this.iColor,transparent:!0,depthTest:!1,opacity:this.opacity}):new b.LineBasicMaterial({color:this.iColor,transparent:!0,depthTest:!1}),Ae=new b.Line(ne,rt),this.drawEntity(Ae)},q.prototype.drawSelectLine=function(ne,Ue,De,Ve){ne instanceof Object&&Ue instanceof Object?this.drawEntity(m.MxThreeJS.createLine(ne,Ue,this.iColor,0)):typeof ne=="number"&&typeof Ue=="number"&&this.drawEntity(m.MxThreeJS.createLine(new b.Vector3(ne,Ue,0),new b.Vector3(De,Ve,0),this.iColor,0))},q.prototype.drawLine=function(ne,Ue,De,Ve){var rt,Ae;if(ne instanceof Object&&Ue instanceof Object?(rt=ne,Ae=Ue):typeof ne=="number"&&typeof Ue=="number"&&(rt=new b.Vector3(ne,Ue,0),Ae=new b.Vector3(De,Ve,0)),this.dLineWidth!=0){this.createWidthMaterial();var Te=new Float32Array(6);Te[0]=rt.x,Te[1]=rt.y,Te[2]=0,Te[3]=Ae.x,Te[4]=Ae.y,Te[5]=0;var Xe=new N.MeshLine;Xe.setGeometry(Te);var ie=new b.Mesh(Xe.geometry,this.widthMaterial);ie.renderOrder=this.iRenderOrder,this.drawEntity(ie),this.drawSelectLine(rt,Ae)}else this.drawEntity(m.MxThreeJS.createLine(rt,Ae,this.iColor,this.opacity))},q.prototype.drawCircle=function(ne,Ue){this.drawEntity(m.MxThreeJS.createCircle(ne,Ue,this.iColor))},q.prototype.drawText=function(ne,Ue,De,Ve,rt,Ae){var Te=m.MxThreeJS.creatTextSprite(ne,Ve,Ue,De,this.iColor,rt,Ae);return this.drawEntity(Te),Te},q.prototype.setupForEntity=function(ne){this.iColor=L.MxFun.getNumberColor(ne.getColor()),this.iRenderOrder=ne.getRenderOrder(),this.opacity=ne.opacity,this.dLineWidth=ne.getLineWidth(),this.lineWidthByPixels=ne.getLineWidthByPixels(),this.dDashArray=ne.getDash().dDashArray,this.dDashRatio=ne.getDash().dDashRatio},q);function q(ne,Ue){this.aryEntity=[],this.iColor=16777215,this.dLineWidth=0,this.lineWidthByPixels=!0,this.iRenderOrder=O.MxData.iMxEntityRenderOrder,this.worldDrawType=1,this.widthMaterial=null,this.dDashArray=0,this.dDashRatio=0,this.matrix=null,this.opacity=1,this.xData=null,this.mxObj=ne,this.worldDrawType=Ue}l.McGiWorldDraw=G;var J,fe=(u(ve,J=G),ve.prototype.setSmallCoordDraw=function(ne){this.isSmallCorrdDraw=ne},ve.prototype.setCurEntityId=function(ne){this.curEntityId=ne},ve.prototype.drawEntity=function(ne){},ve.prototype.drawText=function(ne,Ue,De,Ve,rt,Ae){return null},ve.prototype.drawSelectLine=function(ne,Ue,De,Ve){},ve.prototype.isValid=function(){return this.curEntityId!=0||(console.log("this.curEntityId == 0"),!1)},ve.prototype.drawLine=function(ne,Ue,De,Ve){var rt,Ae;this.isValid()&&(ne instanceof Object&&Ue instanceof Object?(rt=ne,Ae=Ue):typeof ne=="number"&&typeof Ue=="number"&&(rt=new b.Vector3(ne,Ue,0),Ae=new b.Vector3(De,Ve,0)),this.selectManager.addLineDisplay(this.curEntityId,rt,Ae,this.isSmallCorrdDraw))},ve.prototype.drawCircle=function(ne,Ue){this.isValid()&&this.selectManager.addCircleDisplay(this.curEntityId,ne,Ue,this.isSmallCorrdDraw)},ve.prototype.drawLines=function(ne){if(!(ne.length<2))for(var Ue=ne.length,De=0;De<Ue-1;De++)this.selectManager.addLineDisplay(this.curEntityId,ne[De],ne[De+1],this.isSmallCorrdDraw)},ve);function ve(ne,Ue){var De=J.call(this,ne,c.kSelectDraw)||this;return De.isSmallCorrdDraw=!1,De.selectManager=Ue,De.curEntityId=0,De.isSmallCorrdDraw=!1,De}l.McGiWorldDrawSelect=fe},{"../MxFun":27,"../MxManager":29,"../MxThreeJS":37,three:19,"three.meshline":18}],45:[function(t,e,l){var n,u=this&&this.__extends||(n=function(Te,Xe){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ie,ue){ie.__proto__=ue}||function(ie,ue){for(var pt in ue)Object.prototype.hasOwnProperty.call(ue,pt)&&(ie[pt]=ue[pt])})(Te,Xe)},function(Te,Xe){function ie(){this.constructor=Te}n(Te,Xe),Te.prototype=Xe===null?Object.create(Xe):(ie.prototype=Xe.prototype,new ie)});Object.defineProperty(l,"__esModule",{value:!0}),l.MrxDbgUiPrBase=l.MrxDbgUiPrBase_Return=l.McEdGetPointWorldDrawObject=l.McEdGetPointWorldDraw=void 0;var c=t("three"),y=t("./MxJig"),b=t("./MxJigCmdManager"),m=t("../MxThreeJS"),O=t("../UI/MxUiVue"),N=t("../MxString"),L=t("./McGiWorldDraw"),G=t("../MxManager"),q=(J.prototype.setMcEdJig=function(Te){this.m_pJig=Te},J.prototype.getMcEdJig=function(){return this.m_pJig},J.prototype.setColor=function(Te){this.m_iColor=Te},J.prototype.getColor=function(){return this.m_iColor},J.prototype.getDrawColor=function(){return this.m_pJig.getMxObject().automaticInversionColor(this.m_iColor)},J.prototype.drawLine=function(Te,Xe){this.m_pJig.drawEntity(m.MxThreeJS.createLine(Te,Xe,this.getDrawColor()))},J.prototype.drawRect=function(Te,Xe){var ie=new c.Vector3(Te.x,Xe.y,0),ue=new c.Vector3(Xe.x,Te.y,0);this.drawLine(Te,ie),this.drawLine(ie,Xe),this.drawLine(Xe,ue),this.drawLine(ue,Te)},J.prototype.drawMcDbEntity=function(Te,Xe){this.m_pJig.drawMcDbEntity(Te,Xe?0:this.getDrawColor(),Xe)},J.prototype.drawMcDbLine=function(Te,Xe,ie,ue,pt,mt){this.m_pJig.drawMcDbLine(Te,Xe,ie,ue,pt,mt,this.getDrawColor())},J.prototype.drawCircle=function(Te,Xe){this.m_pJig.drawEntity(m.MxThreeJS.createCircle(Te,Xe,this.getDrawColor()))},J.prototype.drawEntity=function(Te,Xe,ie){ie===void 0&&(ie=!1),this.m_pJig.drawEntity(Te,Xe,ie)},J.prototype.drawText=function(Te,Xe,ie,ue){var pt=m.MxThreeJS.creatTextSprite(Te,ue,Xe,ie,this.getDrawColor());this.drawEntity(pt)},J.prototype.drawSolid=function(Te,Xe){var ie=m.MxThreeJS.createSolid(Te,this.getDrawColor(),Xe);ie&&this.drawEntity(ie)},J.prototype.drawCustomEntity=function(Te,Xe){var ie=new L.McGiWorldDraw(this.m_pJig.getMxObject(),L.McGiWorldDrawType.kDynDragDraw);ie.setupForEntity(Te),Te.worldDraw(ie);for(var ue=ie.getEntitys(),pt=ue.length,mt=0;mt<pt;mt++)this.drawEntity(ue[mt],Xe,Te.isUseSmallcoordDisplay())},J);function J(){this.m_pJig=null,this.m_iColor=16777215}l.McEdGetPointWorldDraw=q;var fe,ve,ne,Ue=(u(De,fe=q),De.prototype.setDraw=function(Te){this.m_callDraw=Te},De.prototype.worldDraw=function(Te){this.m_callDraw!=null&&this.m_callDraw(Te,this)},De);function De(){var Te=fe!==null&&fe.apply(this,arguments)||this;return Te.m_callDraw=void 0,Te}l.McEdGetPointWorldDrawObject=Ue,(ne=ve=l.MrxDbgUiPrBase_Return||(l.MrxDbgUiPrBase_Return={}))[ne.kCancel=-2]="kCancel",ne[ne.kNone=-1]="kNone",ne[ne.kOk=0]="kOk",ne[ne.kKeyWord=1]="kKeyWord";var Ve,rt=(u(Ae,Ve=y.McEdJigCommand),Ae.prototype.procInKeyword=function(Te){Te.status>=b.MxJigCmdManager.DragStatus.kKW1&&0<Te.sKeyValue.length?this.m_keyWordPicked=Te.sKeyValue.toUpperCase():this.m_keyWordPicked=""},Ae.prototype.getReturnStatus=function(Te){switch(Te){case b.MxJigCmdManager.DragStatus.kNoChange:return ve.kNone;case b.MxJigCmdManager.DragStatus.kCancel:return ve.kCancel;case b.MxJigCmdManager.DragStatus.kNull:return ve.kNone;case b.MxJigCmdManager.DragStatus.kNormal:return ve.kOk}return 1<=Te?ve.kKeyWord:ve.kCancel},Ae.prototype.SetLASTPOINT=function(Te){var Xe=this._mxObject;if((Xe=Xe||G.MxManager.currentMx()).sysVariable().setSysVarPoint("LASTPOINT",Te),Te){var ie=Xe.sysVariable().getSysVarNumber("GETPOINTSTATUS");ie|=b.MxJigCmdManager.GETPOINTSTATUS.OsModeSValidLastPoint,Xe.sysVariable().setSysVarNumber("GETPOINTSTATUS",ie)}else ie=Xe.sysVariable().getSysVarNumber("GETPOINTSTATUS"),ie&=~b.MxJigCmdManager.GETPOINTSTATUS.OsModeSValidLastPoint,Xe.sysVariable().setSysVarNumber("GETPOINTSTATUS",ie)},Ae.prototype.clearLastInputPoint=function(){this._mxObject||(this._mxObject=G.MxManager.currentMx()),this.SetLASTPOINT(void 0)},Ae.prototype.setCursorType=function(Te){this.m_cursorType=Te},Ae.prototype.getCursorType=function(){return this.m_cursorType},Ae.prototype.setInputToucheType=function(Te){this.m_toucheType=Te},Ae.prototype.getInputToucheType=function(){return this.m_toucheType},Ae.prototype.keyWords=function(){return this.m_keyWords},Ae.prototype.setKeyWords=function(Te){this.m_keyWords=Te},Ae.prototype.message=function(){return this.m_message},Ae.prototype.setMessage=function(Te){this.m_message=Te},Ae.prototype.keyWordPicked=function(){return this.m_keyWordPicked},Ae.prototype.isKeyWordPicked=function(Te){return Te=Te.toUpperCase(),this.m_keyWordPicked==Te},Ae.prototype.setUserDraw=function(Te){Te.setMcEdJig(this),this.m_pWorldDraw=Te},Ae.prototype.printMessage=function(){var Te=new N.MxString(this.m_message);Te.TrimRight(":"),1<this.m_keyWords.length&&this.m_keyWords[0]=="["&&this.m_keyWords[this.m_keyWords.length-1]=="]"?Te.m_val.indexOf(`
- `)==-1?O.MxUiVue.acutPrintf(`
- `+Te.m_val+" 或"+this.m_keyWords+":"):O.MxUiVue.acutPrintf(Te.m_val+" 或"+this.m_keyWords+":"):Te.m_val.indexOf(`
- `)==-1?O.MxUiVue.acutPrintf(`
- `+Te.m_val+":"):O.MxUiVue.acutPrintf(Te.m_val+":")},Ae);function Ae(){var Te=Ve!==null&&Ve.apply(this,arguments)||this;return Te.m_keyWords="",Te.m_message="",Te.m_keyWordPicked="",Te.m_pWorldDraw=null,Te.m_toucheType=b.MxJigCmdManager.InType.kGetBegan,Te.m_cursorType=O.MxUiVue.CursorType.kNormal,Te}l.MrxDbgUiPrBase=rt},{"../MxManager":29,"../MxString":34,"../MxThreeJS":37,"../UI/MxUiVue":65,"./McGiWorldDraw":44,"./MxJig":53,"./MxJigCmdManager":54,three:19}],46:[function(t,e,l){var n,u=this&&this.__extends||(n=function(pt,mt){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(Tt,kt){Tt.__proto__=kt}||function(Tt,kt){for(var It in kt)Object.prototype.hasOwnProperty.call(kt,It)&&(Tt[It]=kt[It])})(pt,mt)},function(pt,mt){function Tt(){this.constructor=pt}n(pt,mt),pt.prototype=mt===null?Object.create(mt):(Tt.prototype=mt.prototype,new Tt)});Object.defineProperty(l,"__esModule",{value:!0}),l.MrxDbgUiPrAngle=l.MrxDbgUiPrKeyWord=l.MrxDbgUiPrString=l.MrxDbgUiPrInt=l.MrxDbgUiPrDist=void 0;var c,y=t("three"),b=t("./MxJigCmdManager"),m=t("../MxFun"),O=t("./MrxDbgUiPrBase"),N=t("../UI/MxUiVue"),L=t("../MxThreeJS"),G=t("../MxString"),q=(u(J,c=O.MrxDbgUiPrBase),J.prototype.value=function(){return this.m_value},J.prototype.basePt=function(){return new y.Vector3(this.m_basePt.x,this.m_basePt.y,0)},J.prototype.setBasePt=function(pt){this.m_basePt==null?this.m_basePt=new y.Vector3(pt.x,pt.y,0):(this.m_basePt.x=pt.x,this.m_basePt.y=pt.y),this.m_useBasePt=!0},J.prototype.setUseBasePt=function(pt){this.m_useBasePt=pt},J.prototype.initGo=function(){this.m_keyWordPicked="",this.m_retcall=null,this.clearLastInputPoint(),this.m_useBasePt&&this.SetLASTPOINT(this.m_basePt)},J.prototype.go=function(pt){this.initGo(),this.m_retcall=pt,this.m_previousInPoint=null,this.m_currentInPoint=null,this.m_value=0,b.MxJigCmdManager.runCmd(this)},J.prototype.onExitCommand=function(){var pt=this;N.MxUiVue.setCursorType(N.MxUiVue.CursorType.kNormal);var mt=!1;this.m_retcall!=null&&(b.MxJigCmdManager.setRunCmdEvent(function(){c.prototype.onExitCommand.call(pt,!1),mt=!0}),this.m_retcall(this.getReturnStatus(this.m_resultDragStatus)),b.MxJigCmdManager.setRunCmdEvent(void 0)),!mt&&b.MxJigCmdManager.isWaitCmdNull()&&N.MxUiVue.restoreCmdStatus(),mt||c.prototype.onExitCommand.call(this,!0)},J.prototype.onStartCommand=function(){N.MxUiVue.setCursorType(this.m_cursorType),this.printMessage(),b.MxJigCmdManager.setKeywordList(this.keyWords()),c.prototype.onStartCommand.call(this)},J.prototype.sampler=function(){var pt,mt=b.MxJigCmdManager.acquirePoint(this.m_toucheType,!1);return mt.status==b.MxJigCmdManager.DragStatus.kNormal&&(this.m_currSamplerPoint==null?this.m_currSamplerPoint=new y.Vector3(mt.pt.x,mt.pt.y,0):(this.m_currSamplerPoint.x=mt.pt.x,this.m_currSamplerPoint.y=mt.pt.y)),pt=this.m_useBasePt?this.acquireDist(this.m_toucheType,this.m_basePt):this.acquireDist(this.m_toucheType,this.m_currentInPoint),this.procInKeyword(pt),pt.status==b.MxJigCmdManager.DragStatus.kNormal?(this.m_value=pt.dist,pt.status):pt.status==b.MxJigCmdManager.DragStatus.kKW1?pt.status:this.m_useBasePt||this.m_currentInPoint?mt.status:((pt=this.acquirePoint(this.m_toucheType,!1)).status==b.MxJigCmdManager.DragStatus.kNormal&&pt.exit&&(this.m_previousInPoint==null?this.m_previousInPoint=new y.Vector3(pt.pt.x,pt.pt.y,0):(this.m_previousInPoint.x=pt.pt.x,this.m_previousInPoint.y=pt.pt.y)),pt.status)},J.prototype.done=function(pt){if(this.m_retcall!=null)return this.m_resultDragStatus=pt,this.m_useBasePt||pt!=b.MxJigCmdManager.DragStatus.kNormal||!this.m_previousInPoint||this.m_currentInPoint?b.MxJigCmdManager.DoneStatius.kExitCommand:(this.m_currentInPoint=this.m_previousInPoint,this.m_previousInPoint=null,b.MxJigCmdManager.DoneStatius.kContinueCommand);m.MxFun.Assert(0)},J.prototype.upDisplay=function(){this.m_currSamplerPoint&&(this.m_pWorldDraw&&(this._mxObject.getMcObject().onReadyJigUpdateDispla(),this.m_pWorldDraw.worldDraw(this.m_currSamplerPoint)),this.m_useBasePt&&this.m_basePt?this.drawEntity(L.MxThreeJS.createLine(this.m_currSamplerPoint,this.m_basePt,16777215)):this.m_currentInPoint&&this.drawEntity(L.MxThreeJS.createLine(this.m_currSamplerPoint,this.m_currentInPoint,16777215)))},J);function J(){var pt=c.call(this)||this;return pt.m_useBasePt=!1,pt.m_basePt=null,pt.m_previousInPoint=null,pt.m_currentInPoint=null,pt.m_value=0,pt.m_currSamplerPoint=null,pt.m_retcall=null,pt.m_resultDragStatus=b.MxJigCmdManager.DragStatus.kCancel,pt.m_cursorType=N.MxUiVue.CursorType.kCross,pt}l.MrxDbgUiPrDist=q;var fe,ve=(u(ne,fe=O.MrxDbgUiPrBase),ne.prototype.value=function(){return this.m_value},ne.prototype.initGo=function(){this.m_keyWordPicked="",this.m_retcall=null,this.clearLastInputPoint()},ne.prototype.go=function(pt){this.initGo(),this.m_retcall=pt,this.m_value=0,this.m_currSamplerPoint=null,b.MxJigCmdManager.runCmd(this)},ne.prototype.onExitCommand=function(){var pt=this;N.MxUiVue.setCursorType(N.MxUiVue.CursorType.kNormal);var mt=!1;this.m_retcall!=null&&(b.MxJigCmdManager.setRunCmdEvent(function(){fe.prototype.onExitCommand.call(pt,!1),mt=!0}),this.m_retcall(this.getReturnStatus(this.m_resultDragStatus)),b.MxJigCmdManager.setRunCmdEvent(void 0)),!mt&&b.MxJigCmdManager.isWaitCmdNull()&&N.MxUiVue.restoreCmdStatus(),mt||fe.prototype.onExitCommand.call(this,!0)},ne.prototype.onStartCommand=function(){N.MxUiVue.setCursorType(this.m_cursorType),this.printMessage(),b.MxJigCmdManager.setKeywordList(this.keyWords()),fe.prototype.onStartCommand.call(this)},ne.prototype.sampler=function(){var pt=b.MxJigCmdManager.acquirePoint(this.m_toucheType,!1);pt.status==b.MxJigCmdManager.DragStatus.kNormal&&(this.m_currSamplerPoint==null?this.m_currSamplerPoint=new y.Vector3(pt.pt.x,pt.pt.y,0):(this.m_currSamplerPoint.x=pt.pt.x,this.m_currSamplerPoint.y=pt.pt.y));var mt=this.acquireInt();return this.procInKeyword(mt),mt.status==b.MxJigCmdManager.DragStatus.kNormal?this.m_value=mt.iVal:(mt.status,b.MxJigCmdManager.DragStatus.kKW1),mt.status},ne.prototype.done=function(pt){if(this.m_retcall!=null)return this.m_resultDragStatus=pt,b.MxJigCmdManager.DoneStatius.kExitCommand;m.MxFun.Assert(0)},ne.prototype.upDisplay=function(){this.m_currSamplerPoint&&this.m_pWorldDraw&&(this._mxObject.getMcObject().onReadyJigUpdateDispla(),this.m_pWorldDraw.worldDraw(this.m_currSamplerPoint))},ne);function ne(){var pt=fe.call(this)||this;return pt.m_value=0,pt.m_currSamplerPoint=null,pt.m_retcall=null,pt.m_resultDragStatus=b.MxJigCmdManager.DragStatus.kCancel,pt.m_cursorType=N.MxUiVue.CursorType.kNormal,pt.setDynamicInputType(b.MxJigCmdManager.DynamicInputType.kNoInput),pt}l.MrxDbgUiPrInt=ve;var Ue,De=(u(Ve,Ue=O.MrxDbgUiPrBase),Ve.prototype.value=function(){return this.m_value},Ve.prototype.initGo=function(){this.m_keyWordPicked="",this.m_retcall=null},Ve.prototype.go=function(pt){this.initGo(),this.m_retcall=pt,this.m_value="",this.m_currSamplerPoint=null,b.MxJigCmdManager.runCmd(this)},Ve.prototype.onExitCommand=function(){var pt=this;N.MxUiVue.setCursorType(N.MxUiVue.CursorType.kNormal);var mt=!1;this.m_retcall!=null&&(b.MxJigCmdManager.setRunCmdEvent(function(){Ue.prototype.onExitCommand.call(pt,!1),mt=!0}),this.m_retcall(this.getReturnStatus(this.m_resultDragStatus)),b.MxJigCmdManager.setRunCmdEvent(void 0)),!mt&&b.MxJigCmdManager.isWaitCmdNull()&&N.MxUiVue.restoreCmdStatus(),mt||Ue.prototype.onExitCommand.call(this,!0)},Ve.prototype.onStartCommand=function(){N.MxUiVue.setCursorType(this.m_cursorType),this.printMessage(),b.MxJigCmdManager.setKeywordList(this.keyWords()),Ue.prototype.onStartCommand.call(this)},Ve.prototype.sampler=function(){var pt=b.MxJigCmdManager.acquirePoint(this.m_toucheType,!1);pt.status==b.MxJigCmdManager.DragStatus.kNormal&&(this.m_currSamplerPoint==null?this.m_currSamplerPoint=new y.Vector3(pt.pt.x,pt.pt.y,0):(this.m_currSamplerPoint.x=pt.pt.x,this.m_currSamplerPoint.y=pt.pt.y));var mt=this.acquireString();return this.procInKeyword(mt),mt.status==b.MxJigCmdManager.DragStatus.kNormal?this.m_value=mt.sValue:(mt.status,b.MxJigCmdManager.DragStatus.kKW1),mt.status},Ve.prototype.done=function(pt){if(this.m_retcall!=null)return this.m_resultDragStatus=pt,b.MxJigCmdManager.DoneStatius.kExitCommand;m.MxFun.Assert(0)},Ve.prototype.upDisplay=function(){this.m_currSamplerPoint&&this.m_pWorldDraw&&(this._mxObject.getMcObject().onReadyJigUpdateDispla(),this.m_pWorldDraw.worldDraw(this.m_currSamplerPoint))},Ve);function Ve(){var pt=Ue.call(this)||this;return pt.m_value="",pt.m_currSamplerPoint=null,pt.m_retcall=null,pt.m_resultDragStatus=b.MxJigCmdManager.DragStatus.kCancel,pt.m_cursorType=N.MxUiVue.CursorType.kCross,pt}l.MrxDbgUiPrString=De;var rt,Ae=(u(Te,rt=O.MrxDbgUiPrBase),Te.prototype.initGo=function(){this.m_keyWordPicked="",this.m_retcall=null},Te.prototype.printMessage=function(){var pt=new G.MxString(this.m_message);pt.TrimRight(":"),1<this.m_keyWords.length&&this.m_keyWords[0]=="["&&this.m_keyWords[this.m_keyWords.length-1]=="]"?pt.m_val.indexOf(`
- `)==-1?N.MxUiVue.acutPrintf(`
- `+pt.m_val+" "+this.m_keyWords+":"):N.MxUiVue.acutPrintf(pt.m_val+" "+this.m_keyWords+":"):pt.m_val.indexOf(`
- `)==-1?N.MxUiVue.acutPrintf(`
- `+pt.m_val+":"):N.MxUiVue.acutPrintf(pt.m_val+":")},Te.prototype.go=function(pt){this.initGo(),this.m_retcall=pt,this.m_currSamplerPoint=null,b.MxJigCmdManager.runCmd(this)},Te.prototype.onExitCommand=function(){var pt=this;N.MxUiVue.setCursorType(N.MxUiVue.CursorType.kNormal);var mt=!1;this.m_retcall!=null&&(b.MxJigCmdManager.setRunCmdEvent(function(){rt.prototype.onExitCommand.call(pt,!1),mt=!0}),this.m_retcall(this.getReturnStatus(this.m_resultDragStatus)),b.MxJigCmdManager.setRunCmdEvent(void 0)),!mt&&b.MxJigCmdManager.isWaitCmdNull()&&N.MxUiVue.restoreCmdStatus(),mt||rt.prototype.onExitCommand.call(this,!0)},Te.prototype.onStartCommand=function(){N.MxUiVue.setCursorType(this.m_cursorType),this.printMessage(),b.MxJigCmdManager.setKeywordList(this.keyWords()),rt.prototype.onStartCommand.call(this)},Te.prototype.sampler=function(){var pt=b.MxJigCmdManager.acquirePoint(this.m_toucheType,!1);pt.status==b.MxJigCmdManager.DragStatus.kNormal&&(this.m_currSamplerPoint==null?this.m_currSamplerPoint=new y.Vector3(pt.pt.x,pt.pt.y,0):(this.m_currSamplerPoint.x=pt.pt.x,this.m_currSamplerPoint.y=pt.pt.y));var mt=this.acquireKeyword();return this.procInKeyword(mt),mt.status,b.MxJigCmdManager.DragStatus.kKW1,mt.status},Te.prototype.done=function(pt){if(this.m_retcall!=null)return pt>=b.MxJigCmdManager.DragStatus.kKW1&&(pt=b.MxJigCmdManager.DragStatus.kNormal),this.m_resultDragStatus=pt,b.MxJigCmdManager.DoneStatius.kExitCommand;m.MxFun.Assert(0)},Te.prototype.upDisplay=function(){this.m_currSamplerPoint&&this.m_pWorldDraw&&(this._mxObject.getMcObject().onReadyJigUpdateDispla(),this.m_pWorldDraw.worldDraw(this.m_currSamplerPoint))},Te);function Te(){var pt=rt.call(this)||this;return pt.m_currSamplerPoint=null,pt.m_retcall=null,pt.m_resultDragStatus=b.MxJigCmdManager.DragStatus.kCancel,pt.m_cursorType=N.MxUiVue.CursorType.kCross,pt.setUserInputControls(0),pt.setDisableDynInput(!0),pt}l.MrxDbgUiPrKeyWord=Ae;var Xe,ie=(u(ue,Xe=O.MrxDbgUiPrBase),ue.prototype.value=function(){return this.m_value},ue.prototype.basePt=function(){return new y.Vector3(this.m_basePt.x,this.m_basePt.y,0)},ue.prototype.setBasePt=function(pt){this.m_basePt==null?this.m_basePt=new y.Vector3(pt.x,pt.y,0):(this.m_basePt.x=pt.x,this.m_basePt.y=pt.y),this.m_useBasePt=!0},ue.prototype.setUseBasePt=function(pt){this.m_useBasePt=pt},ue.prototype.initGo=function(){this.m_keyWordPicked="",this.m_retcall=null,this.clearLastInputPoint(),this.m_useBasePt&&this.SetLASTPOINT(this.m_basePt)},ue.prototype.go=function(pt){this.initGo(),this.m_retcall=pt,this.m_previousInPoint=null,this.m_currentInPoint=null,this.m_value=0,b.MxJigCmdManager.runCmd(this)},ue.prototype.onExitCommand=function(){var pt=this;N.MxUiVue.setCursorType(N.MxUiVue.CursorType.kNormal);var mt=!1;this.m_retcall!=null&&(b.MxJigCmdManager.setRunCmdEvent(function(){Xe.prototype.onExitCommand.call(pt,!1),mt=!0}),this.m_retcall(this.getReturnStatus(this.m_resultDragStatus)),b.MxJigCmdManager.setRunCmdEvent(void 0)),!mt&&b.MxJigCmdManager.isWaitCmdNull()&&N.MxUiVue.restoreCmdStatus(),mt||Xe.prototype.onExitCommand.call(this,!0)},ue.prototype.onStartCommand=function(){N.MxUiVue.setCursorType(this.m_cursorType),this.printMessage(),b.MxJigCmdManager.setKeywordList(this.keyWords()),Xe.prototype.onStartCommand.call(this)},ue.prototype.sampler=function(){var pt,mt=b.MxJigCmdManager.acquirePoint(this.m_toucheType,!1);return mt.status==b.MxJigCmdManager.DragStatus.kNormal&&(this.m_currSamplerPoint==null?this.m_currSamplerPoint=new y.Vector3(mt.pt.x,mt.pt.y,0):(this.m_currSamplerPoint.x=mt.pt.x,this.m_currSamplerPoint.y=mt.pt.y)),pt=this.m_useBasePt?this.acquireAngle(this.m_toucheType,this.m_basePt):this.acquireAngle(this.m_toucheType,this.m_currentInPoint),this.procInKeyword(pt),pt.status==b.MxJigCmdManager.DragStatus.kNormal?(this.m_value=pt.ang,pt.status):pt.status==b.MxJigCmdManager.DragStatus.kKW1?pt.status:this.m_useBasePt||this.m_currentInPoint?mt.status:((pt=this.acquirePoint(this.m_toucheType,!1)).status==b.MxJigCmdManager.DragStatus.kNormal&&pt.exit&&(this.m_previousInPoint==null?this.m_previousInPoint=new y.Vector3(pt.pt.x,pt.pt.y,0):(this.m_previousInPoint.x=pt.pt.x,this.m_previousInPoint.y=pt.pt.y)),pt.status)},ue.prototype.done=function(pt){if(this.m_retcall!=null)return this.m_resultDragStatus=pt,this.m_useBasePt||pt!=b.MxJigCmdManager.DragStatus.kNormal||!this.m_previousInPoint||this.m_currentInPoint?b.MxJigCmdManager.DoneStatius.kExitCommand:(this.m_currentInPoint=this.m_previousInPoint,this.m_previousInPoint=null,b.MxJigCmdManager.DoneStatius.kContinueCommand);m.MxFun.Assert(0)},ue.prototype.upDisplay=function(){this.m_currSamplerPoint&&(this.m_pWorldDraw&&(this._mxObject.getMcObject().onReadyJigUpdateDispla(),this.m_pWorldDraw.worldDraw(this.m_currSamplerPoint)),this.m_useBasePt&&this.m_basePt?this.drawEntity(L.MxThreeJS.createLine(this.m_currSamplerPoint,this.m_basePt,16777215)):this.m_currentInPoint&&this.drawEntity(L.MxThreeJS.createLine(this.m_currSamplerPoint,this.m_currentInPoint,16777215)))},ue);function ue(){var pt=Xe.call(this)||this;return pt.m_useBasePt=!1,pt.m_basePt=null,pt.m_previousInPoint=null,pt.m_currentInPoint=null,pt.m_value=0,pt.m_currSamplerPoint=null,pt.m_retcall=null,pt.m_resultDragStatus=b.MxJigCmdManager.DragStatus.kCancel,pt.m_cursorType=N.MxUiVue.CursorType.kCross,pt}l.MrxDbgUiPrAngle=ie},{"../MxFun":27,"../MxString":34,"../MxThreeJS":37,"../UI/MxUiVue":65,"./MrxDbgUiPrBase":45,"./MxJigCmdManager":54,three:19}],47:[function(t,e,l){var n,u=this&&this.__extends||(n=function(fe,ve){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ne,Ue){ne.__proto__=Ue}||function(ne,Ue){for(var De in Ue)Object.prototype.hasOwnProperty.call(Ue,De)&&(ne[De]=Ue[De])})(fe,ve)},function(fe,ve){function ne(){this.constructor=fe}n(fe,ve),fe.prototype=ve===null?Object.create(ve):(ne.prototype=ve.prototype,new ne)});Object.defineProperty(l,"__esModule",{value:!0}),l.MrxDbgUiPrPoint=void 0;var c,y=t("three"),b=t("./MxJigCmdManager"),m=t("../MxFun"),O=t("./MrxDbgUiPrBase"),N=t("../UI/MxUiVue"),L=t("../MxThreeJS"),G=t("../MxManager"),q=(u(J,c=O.MrxDbgUiPrBase),J.prototype.value=function(){return new y.Vector3(this.m_value.x,this.m_value.y,0)},J.prototype.getCADValue=function(){return G.MxManager.getMxCpp().newMcGePoint3d(new y.Vector3(this.m_value.x,this.m_value.y,0))},J.prototype.basePt=function(){return new y.Vector3(this.m_basePt.x,this.m_basePt.y,0)},J.prototype.setBasePt=function(fe){this.m_basePt==null?this.m_basePt=new y.Vector3(fe.x,fe.y,0):(this.m_basePt.x=fe.x,this.m_basePt.y=fe.y),this.m_useBasePt=!0},J.prototype.setUseBasePt=function(fe){this.m_useBasePt=fe},J.prototype.initGo=function(){this.m_keyWordPicked="",this.m_retcall=null,this.m_retWhileCall=null,this.m_exitCall=null,this.m_useBasePt&&this.SetLASTPOINT(this.m_basePt)},J.prototype.go=function(fe){this.initGo(),this.m_retcall=fe,b.MxJigCmdManager.runCmd(this)},J.prototype.goWhile=function(fe,ve){this.initGo(),this.m_retWhileCall=fe,ve&&(this.m_exitCall=ve),b.MxJigCmdManager.runCmd(this)},J.prototype.onExitCommand=function(){var fe=this;N.MxUiVue.setCursorType(N.MxUiVue.CursorType.kNormal);var ve=!1;this.m_retcall!=null&&(b.MxJigCmdManager.setRunCmdEvent(function(){c.prototype.onExitCommand.call(fe,!1),ve=!0}),this.m_retcall(this.getReturnStatus(this.m_resultDragStatus)),b.MxJigCmdManager.setRunCmdEvent(void 0)),!ve&&b.MxJigCmdManager.isWaitCmdNull()&&N.MxUiVue.restoreCmdStatus(),ve||c.prototype.onExitCommand.call(this,!0)},J.prototype.onStartCommand=function(){N.MxUiVue.setCursorType(this.m_cursorType),this.printMessage(),b.MxJigCmdManager.setKeywordList(this.keyWords()),this.m_useBasePt&&this.SetLASTPOINT(this.m_basePt),c.prototype.onStartCommand.call(this)},J.prototype.sampler=function(){var fe=this.acquirePoint(this.m_toucheType);return this.procInKeyword(fe),fe.status==b.MxJigCmdManager.DragStatus.kNormal&&(this.m_value==null?this.m_value=new y.Vector3(fe.pt.x,fe.pt.y,0):(this.m_value.x=fe.pt.x,this.m_value.y=fe.pt.y)),fe.status},J.prototype.done=function(fe){if(this.m_retcall!=null)return this.m_resultDragStatus=fe,this.m_exitCall&&this.m_exitCall(this.getReturnStatus(this.m_resultDragStatus)),b.MxJigCmdManager.DoneStatius.kExitCommand;if(this.m_retWhileCall!=null){if((this.m_resultDragStatus=fe)==b.MxJigCmdManager.DragStatus.kCancel)return this.m_exitCall&&this.m_exitCall(this.getReturnStatus(this.m_resultDragStatus)),b.MxJigCmdManager.DoneStatius.kExitCommand;var ve=!1;fe==b.MxJigCmdManager.DragStatus.kNull&&(ve=!0);var ne=this.m_retWhileCall(this.getReturnStatus(this.m_resultDragStatus));return ne!=null&&ne.exit!=null&&(ve=ne.exit),ve?(this.m_exitCall&&this.m_exitCall(this.getReturnStatus(this.m_resultDragStatus)),b.MxJigCmdManager.DoneStatius.kExitCommand):(b.MxJigCmdManager.setKeywordList(this.keyWords()),this.printMessage(),b.MxJigCmdManager.DoneStatius.kContinueCommand)}m.MxFun.Assert(0)},J.prototype.upDisplay=function(){if(this.m_value&&(this.m_pWorldDraw&&(this._mxObject.getMcObject().onReadyJigUpdateDispla(0,this.m_value),this.m_pWorldDraw.worldDraw(this.m_value)),this.m_useBasePt&&this.m_basePt)){var fe=16777215;this._mxObject.isWhiteViewColor()&&(fe=0);var ve=this._mxObject;this.drawEntity(L.MxThreeJS.createLine(ve.toSmallcoord(this.m_value),ve.toSmallcoord(this.m_basePt),fe),void 0,!0)}},J);function J(){var fe=c.call(this)||this;return fe.m_useBasePt=!1,fe.m_basePt=null,fe.m_value=null,fe.m_retcall=null,fe.m_retWhileCall=null,fe.m_exitCall=null,fe.m_resultDragStatus=b.MxJigCmdManager.DragStatus.kCancel,fe.m_cursorType=N.MxUiVue.CursorType.kCross,fe}l.MrxDbgUiPrPoint=q},{"../MxFun":27,"../MxManager":29,"../MxThreeJS":37,"../UI/MxUiVue":65,"./MrxDbgUiPrBase":45,"./MxJigCmdManager":54,three:19}],48:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxCmdRunManager=void 0;var n,u,c,y,b,m,O,N,L=t("../MxFun"),G=t("../MxType"),q=t("./MxJigCmdManager"),J=t("../UI/MxUiVue"),fe=t("../MxDrawData");n=l.MxCmdRunManager||(l.MxCmdRunManager={}),u={},c=new Array,y=0,b=!1,m="",O={},N={},n.InitQuickCommand=function(ve){if(ve)if(ve instanceof Array)for(var ne=ve.length,Ue=0;Ue<ne;Ue++){var De=ve[Ue];if(!(De.length<2)){var Ve=De[0];if(Ve.length!=0)for(var rt=De.length,Ae=1;Ae<rt;Ae++)De[Ae].length!=0&&(O[De[Ae].toUpperCase()]=Ve)}}else console.log("Mx:QuickCommand data error,Not an array");else console.log("Mx:QuickCommand data error")},n.InitLanguageString=function(ve){this.m_mapLanguageString=ve},n.getLanguageString=function(ve,ne){var Ue=N[ve];return Ue===void 0&&(Ue=ne),Ue},n.MoveUpKey=function(){return b?++y>=c.length&&(y=0):b=!0,!0},n.MoveDownKey=function(){return!!b&&(--y<0&&(y=c.length-1),!0)},n.GetListCommad=function(){return y<0||y>=c.length?"":c[y]},n.ClearPrvCmd=function(){m=""},n.GetPrvCmd=function(){return m},n.SetPrvCmd=function(ve){m=ve},n.runCmd=function(ve,ne,Ue){var De=ne.toUpperCase(),Ve=u[De];if(ve&&Ve==null){var rt=O[De];if(rt!=null&&(Ve=u[rt.toUpperCase()]),Ve==null)return J.MxUiVue.isNull()?console.log(L.MxFun.formatString('未知命令"{0}"',ne)):J.MxUiVue.acutPrintf(`未知命令"{0}"。
- 命令:`,ne),!1}if(!Ve)return!1;ve.endPanCommand(),ve.getTempMarkDraw().clear(!1);var Ae=c.indexOf(Ve.cmd);-1<Ae&&c.splice(Ae,1),b=!(y=0),c.push(Ve.cmd),!(Ve.flag&G.MxType.MxCommandFlag.MCRX_CMD_NO_RECORD_PRVCMD)&&(m=Ve.cmd);var Te=Ve.fun;ve&&!(Ve.flag&G.MxType.MxCommandFlag.MCRX_CMD_TRANSPARENT)&&J.MxUiVue.acutPrintf(`{0}
- `,Ve.cmd),q.MxJigCmdManager.stopCmd(q.MxJigCmdManager.DetailedResult.kNewCommadIn),ve.callEvent("commandWillStart",{cmd:Ve.cmd}),ve.getMcObject().fireStartRunCommand(Ve.cmd,Ve.flag);var Xe=ve.sysVariable().getSysVarNumber("GETPOINTSTATUS");if(Xe&=~q.MxJigCmdManager.GETPOINTSTATUS.OsModeSValidLastPoint,Xe&=~q.MxJigCmdManager.GETPOINTSTATUS.OsModeSValidLastMovePoint,ve.sysVariable().setSysVarNumber("GETPOINTSTATUS",Xe),ve&&(Ve.flag&G.MxType.MxCommandFlag.MCRX_CMD_NO_CLEAR_SELECT)==0){var ie=!1,ue=ve.getMxAllSelect();if(ve.getMxDatabase().getGripManager().removeAllGrips()&&(ie=!0),ve.getMxDatabase().getSelectManager().removeAllEntity()&&(ie=!0),ve.isValidMcObject()){var pt=ve.getMcObject().getGripManager().getAllSelect();ve.getMcObject().getGripManager().setPrvCommandSelect(pt),ve.getMcObject().getGripManager().clearAll()&&(ie=!0)}ve.getMxDatabase().getSelectManager().setPrvCommandSelect(ue),ie&&(ve.getMxDatabase().getGripManager().fireMxEntitySelectChange(),ve.updateDisplay())}try{Te(Ue)}catch(mt){console.log("mx: run cmd error"),console.log(mt)}return ve.getMcObject().fireEndRunCommand(Ve.cmd,Ve.flag),ve&&(q.MxJigCmdManager.isRunning()||J.MxUiVue.restoreCmdStatus(),ve.updateDisplay(),fe.MxDrawData.m_isAutoResetRenderer||ve.resetRenderer()),!0},n.addCommand=function(ve,ne,Ue){Ue==null&&(Ue=G.MxType.MxCommandFlag.MCRX_CMD_MODAL);var De=ve.toUpperCase();u[De]={fun:ne,cmd:ve,flag:Ue}}},{"../MxDrawData":22,"../MxFun":27,"../MxType":39,"../UI/MxUiVue":65,"./MxJigCmdManager":54}],49:[function(t,e,l){var n,u=this&&this.__extends||(n=function(Ae,Te){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(Xe,ie){Xe.__proto__=ie}||function(Xe,ie){for(var ue in ie)Object.prototype.hasOwnProperty.call(ie,ue)&&(Xe[ue]=ie[ue])})(Ae,Te)},function(Ae,Te){function Xe(){this.constructor=Ae}n(Ae,Te),Ae.prototype=Te===null?Object.create(Te):(Xe.prototype=Te.prototype,new Xe)});Object.defineProperty(l,"__esModule",{value:!0}),l.MxDrawObjectOsnap=l.McDbLine=l.McDbCurve=l.McDbEntity=l.McDbType=void 0;var c,y,b=t("three"),m=t("../MxThreeJS"),O=t("../MxDrawData"),N=t("./MxJigCmdManager"),L=t("./McEdJigOsnap");(y=c=l.McDbType||(l.McDbType={}))[y.kInValid=0]="kInValid",y[y.kLine=1]="kLine";var G=(q.prototype.getType=function(){return this.m_type},q);function q(){this.m_type=c.kInValid}l.McDbEntity=G;var J,fe=(u(ve,J=G),ve);function ve(){return J!==null&&J.apply(this,arguments)||this}l.McDbCurve=fe;var ne,Ue=(u(De,ne=fe),De);function De(){var Ae=ne.call(this)||this;return Ae.m_type=c.kLine,Ae}l.McDbLine=Ue;var Ve=(rt.prototype.getBlobHead=function(Ae,Te){var Xe={};return Xe.type=Ae.getInt32(Te,!0),Te+=4,Xe.ver=Ae.getInt32(Te,!0),Te+=4,Xe.databaseIndex=Ae.getInt32(Te,!0),Te+=4,Xe.nOffset=Te,Xe},rt.prototype.clearData=function(){this.threejsObjects=new b.Object3D},rt.prototype.calculateDistance=function(Ae,Te,Xe){var ie=new b.Vector3().subVectors(Te,Ae),ue=new b.Vector3().subVectors(Xe,Ae),pt=ie.clone().normalize(),mt=ue.clone().normalize(),Tt=pt.dot(mt),kt=new b.Vector3().subVectors(Xe,Te),It=new b.Vector3().subVectors(Ae,Te),nn=kt.clone().normalize(),tn=It.clone().normalize();if(0<nn.dot(tn)&&0<Tt){var pn=Math.sqrt(1-Tt*Tt),_n=Ae.distanceTo(Xe),Dn=_n*pn,an=_n*Tt,Rn=ie.clone().normalize().multiplyScalar(an),Lt=Ae.clone().add(Rn),wn=ie.clone().normalize().multiplyScalar(200+an);return{pt1:Ae,pt2:Te,pt:Xe,distance:Dn,targetPt:Lt,warningPt:Ae.clone().add(wn)}}return null},rt.prototype.getOsnapData=function(Ae,Te){if(this.threejsObjects){var Xe=new b.Raycaster,ie=O.MxDrawData.m_dInputRectWidth;Xe.linePrecision=this.mxObj.screenCoordLong2World(ie);var ue=this.mxObj.getCanvas(),pt=ue.clientWidth,mt=ue.clientHeight,Tt=this.mxObj.screenCoord2World(Ae.x,Ae.y);Tt.z=0,Ae=new b.Vector2(Ae.x/pt*2-1,-Ae.y/mt*2+1),Xe.setFromCamera(Ae,this.mxObj.getCamera());var kt=Xe.intersectObjects(this.threejsObjects.children,!0),It=this.mxObj.getSysVarLong("OSMODE"),nn=new Map;if(kt.length)for(var tn=0;tn<kt.length;tn++){var pn=kt[tn];if(pn.object.userData&&pn.object.userData.obj.getType()==c.kLine){var _n=pn.object.userData.obj;if(It&L.MxOsnapDefine.OsModeEnd){var Dn=Tt.distanceTo(_n.pt1);_n.pt1.type=N.MxJigCmdManager.OsnapMode.kOsModeEnd,nn.set(Dn,_n.pt1);var an=Tt.distanceTo(_n.pt2);_n.pt2.type=N.MxJigCmdManager.OsnapMode.kOsModeEnd,nn.set(an,_n.pt2)}if(It&L.MxOsnapDefine.OsModeNear&&(!_n.bulge||_n.bulge==0)){var Rn=this.calculateDistance(_n.pt1,_n.pt2,Tt);Rn&&(Rn.targetPt.type=N.MxJigCmdManager.OsnapMode.kOsModeNear,nn.set(Rn.distance,Rn.targetPt))}}}if(nn.size){var Lt=this.mxObj.screenCoordLong2World(ie),wn=Array.from(nn);wn.sort(function(hn,xn){return hn[0]-xn[0]}),wn[0][0]<Lt&&Te(wn[0][1],wn[0][1].type)}}},rt.prototype.mxWebEntitysData=function(Ae,Te){var Xe=this.getBlobHead(Ae,0);Ae.getInt32(Xe.nOffset,!0),Xe.nOffset+=4;var ie=Ae.getInt32(Xe.nOffset,!0);Xe.nOffset+=4;var ue=Ae.getInt32(Xe.nOffset,!0);if(Xe.nOffset+=4,1<ue)console.log("mx:error mxfun.js version is old!");else{var pt=Ae.getInt32(Xe.nOffset,!0);if(Xe.nOffset+=4,pt==Xe.nOffset){this.threejsObjects=new b.Object3D;for(var mt=0;mt<ie;mt++){var Tt=Ae.getInt8(Xe.nOffset);Xe.nOffset+=1;var kt=Ae.getInt32(Xe.nOffset,!0);if(Xe.nOffset+=4,Tt==1){var It=Ae.getFloat32(Xe.nOffset,!0);Xe.nOffset+=4;var nn=Ae.getFloat32(Xe.nOffset,!0);Xe.nOffset+=4;var tn=Ae.getFloat32(Xe.nOffset,!0);Xe.nOffset+=4;var pn=Ae.getFloat32(Xe.nOffset,!0);Xe.nOffset+=4,(xn=new Ue).pt1=new b.Vector3(It,nn,0),xn.pt2=new b.Vector3(tn,pn,0),($n=m.MxThreeJS.createLine(xn.pt1,xn.pt2,16777215)).userData.obj=xn,this.threejsObjects.add($n)}else if(Tt==2){var _n=Ae.getInt8(Xe.nOffset);Xe.nOffset+=1;var Dn=Ae.getInt32(Xe.nOffset,!0);Xe.nOffset+=4;for(var an=new b.Vector3,Rn=0,Lt=null,wn=0;wn<Dn;wn++){var hn=new b.Vector3;hn.x=Ae.getFloat32(Xe.nOffset,!0),Xe.nOffset+=4,hn.y=Ae.getFloat32(Xe.nOffset,!0),Xe.nOffset+=4;var xn,$n,Xr=Ae.getFloat32(Xe.nOffset,!0);Xe.nOffset+=4,0<wn&&((xn=new Ue).pt1=an.clone(),xn.pt2=hn.clone(),xn.bulge=Xr,($n=m.MxThreeJS.createLine(xn.pt1,xn.pt2,16777215)).userData.obj=xn,this.threejsObjects.add($n)),an=hn,Rn=Xr,wn==0&&(Lt=hn)}_n&&2<Dn&&((xn=new Ue).pt1=Lt.clone(),xn.pt2=an.clone(),xn.bulge=Rn,($n=m.MxThreeJS.createLine(xn.pt1,xn.pt2,16777215)).userData.obj=xn,this.threejsObjects.add($n))}else console.log("mx:error mxWebEntitysData type"),Xe.nOffset=Xe.nOffset-5+kt}}else console.log("mx: mxWebEntitysData size assert(0)")}},rt);function rt(Ae){this.threejsObjects=null,this.mxObj=null,this.mxObj=Ae}l.MxDrawObjectOsnap=Ve},{"../MxDrawData":22,"../MxThreeJS":37,"./McEdJigOsnap":43,"./MxJigCmdManager":54,three:19}],50:[function(t,e,l){var n,u=this&&this.__extends||(n=function(G,q){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(J,fe){J.__proto__=fe}||function(J,fe){for(var ve in fe)Object.prototype.hasOwnProperty.call(fe,ve)&&(J[ve]=fe[ve])})(G,q)},function(G,q){function J(){this.constructor=G}n(G,q),G.prototype=q===null?Object.create(q):(J.prototype=q.prototype,new J)});Object.defineProperty(l,"__esModule",{value:!0}),l.MxEntSelJig=void 0;var c,y=t("./MxJig"),b=t("./MxJigCmdManager"),m=t("../UI/MxUiVue"),O=t("../MrxDbgUtils"),N=(u(L,c=y.McEdJigCommand),L.prototype.sampler=function(){var G=b.MxJigCmdManager.InType.kGetBegan,q=this.acquirePoint(G);return q.status==b.MxJigCmdManager.DragStatus.kNormal&&(this.point=q.pt),q.status},L.prototype.done=function(G){if(G==b.MxJigCmdManager.DragStatus.kNormal){var q=this;O.MrxDbgUtils.findEntAtPoint(this.getMxObject(),this.point,this.filter).then(function(J){q.callRet(J)})}else this.callRet([]);return b.MxJigCmdManager.DoneStatius.kExitCommand},L.prototype.onStartCommand=function(){m.MxUiVue.setCursorType(m.MxUiVue.CursorType.kRect),c.prototype.onStartCommand.call(this)},L.prototype.onExitCommand=function(){m.MxUiVue.setCursorType(m.MxUiVue.CursorType.kNormal),b.MxJigCmdManager.isWaitCmdNull()&&m.MxUiVue.restoreCmdStatus(),c.prototype.onExitCommand.call(this,!0)},L.prototype.upDisplay=function(){},L);function L(){return c!==null&&c.apply(this,arguments)||this}l.MxEntSelJig=N},{"../MrxDbgUtils":20,"../UI/MxUiVue":65,"./MxJig":53,"./MxJigCmdManager":54}],51:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxGridTrace=void 0;var n=t("three"),u=t("./MxJigCmdManager"),c=t("../MxFun"),y=t("../MxDrawData"),b=t("../MxThreeJS"),m=(O.prototype.ClearDynDrawEntity=function(){for(var N=this.m_mxJig.getMxObject().getTheTempDrawContainer_SmallCoord(),L=this.m_vecDynDrawEntity.length,G=0;G<L;G++)c.MxFun.removeThreejsObject(this.m_vecDynDrawEntity[G],N);this.m_vecDynDrawEntity=[]},O.prototype.GetSanpValue=function(N,L){var G=N%L;return 0<=G?L/2<G?N+=L-G:N-=G:L/2<(G=Math.abs(G))?N-=L-G:N+=G,N},O.prototype.CreteTracePoint=function(N,L){var G=this.m_mxJig.getMxObject(),q=G.getTheTempDrawContainer_SmallCoord();L/=2;var J=b.MxThreeJS.createLine(G.toSmallcoord2(N.x+L,N.y+L,0),G.toSmallcoord2(N.x-L,N.y-L,0),16711680);q.add(J),this.m_vecDynDrawEntity.push(J);var fe=b.MxThreeJS.createLine(G.toSmallcoord2(N.x-L,N.y+L,0),G.toSmallcoord2(N.x+L,N.y-L,0),16711680);q.add(fe),this.m_vecDynDrawEntity.push(fe)},O.prototype.MouseMove=function(N){var L=this.m_mxJig.getMxObject();if(L.getMcObject().isValid()){if(this.ClearDynDrawEntity(),this.m_isValidTracePoint=!1,this.m_isTrace){var G=L.getSysVarPoint("SNAPUNIT");if(!(G.x<1e-6||G.y<1e-6)){N.z=0;var q=new n.Vector3;q.x=this.GetSanpValue(N.x,G.x),q.y=this.GetSanpValue(N.y,G.y);var J=L.viewCoordLong2Cad(y.MxDrawData.m_dInputRectWidth),fe=2*J;q.distanceTo(N)<fe&&(this.m_isValidTracePoint=!0,this.m_ptTracePoint=q,this.CreteTracePoint(q,J))}}}else this.m_isTrace=!1},O.prototype.Init=function(){var N=this.m_mxJig.getMxObject();N.getMcObject().isValid()?(this.m_isValidTracePoint=!1,this.m_isTrace=!1,N.getSysVarLong("GRIDMODE")!=0&&(this.m_isTrace=!0),N.sysVariable().getSysVarNumber("GETPOINTSTATUS")&u.MxJigCmdManager.GETPOINTSTATUS.OsModeGridSnapTempDisable&&(this.m_isTrace=!1),this.m_mxJig.isDisableGridTrace()&&(this.m_isTrace=!1),this.m_isTrace):this.m_isTrace=!1},O.prototype.GetTracePoint=function(){if(this.m_isTrace)return this.m_isValidTracePoint?this.m_ptTracePoint:void 0},O.prototype.ClearDisplay=function(){this.ClearDynDrawEntity()},O.prototype.ReSetTempDisplay=function(){this.ClearDynDrawEntity(),this.m_isValidTracePoint=!1},O);function O(N){this.m_vecDynDrawEntity=[],this.m_ptTracePoint=new n.Vector3,this.m_isValidTracePoint=!1,this.m_isTrace=!1,this.m_mxJig=null,this.m_mxJig=N}l.MxGridTrace=m},{"../MxDrawData":22,"../MxFun":27,"../MxThreeJS":37,"./MxJigCmdManager":54,three:19}],52:[function(t,e,l){var n,u=this&&this.__extends||(n=function(q,J){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(fe,ve){fe.__proto__=ve}||function(fe,ve){for(var ne in ve)Object.prototype.hasOwnProperty.call(ve,ne)&&(fe[ne]=ve[ne])})(q,J)},function(q,J){function fe(){this.constructor=q}n(q,J),q.prototype=J===null?Object.create(J):(fe.prototype=J.prototype,new fe)});Object.defineProperty(l,"__esModule",{value:!0}),l.MxIntelliSelectJig=void 0;var c,y=t("three"),b=t("./MxJig"),m=t("./MxJigCmdManager"),O=t("../MxThreeJS"),N=t("../MxTools"),L=(u(G,c=b.McEdJigCommand),G.prototype.sampler=function(){var q=m.MxJigCmdManager.InType.kGetBegan,J=this.acquirePoint(q);return J.status==m.MxJigCmdManager.DragStatus.kNormal&&(this.m_pt2=J.pt),J.status},G.prototype.getTypeName=function(){return"MxIntelliSelect"},G.prototype.done=function(q){if(q==m.MxJigCmdManager.DragStatus.kNormal){var J=this.getMxObject();J.getMxDatabase().getGripManager().doWindowsSelect(this.m_pt1,this.m_pt2),J.getMcObject().getGripManager().doRangeSelect(this.m_pt1,this.m_pt2)}return m.MxJigCmdManager.DoneStatius.kExitCommand},G.prototype.doPointSelect=function(q,J,fe){var ve=q.viewCoordLong2Cad(16),ne={x:J.x,y:J.y,tol:ve};q.callCommand("MxCAD_IntelliSelect_Point",JSON.stringify(ne),function(Ue){fe(Ue)})},G.prototype.upDisplay=function(){var q=this.getMxObject(),J=this.m_pt1.clone(),fe=this.m_pt2.clone(),ve=new y.Vector3(this.m_pt1.x,this.m_pt2.y,this.m_pt2.z),ne=new y.Vector3(this.m_pt2.x,this.m_pt1.y,this.m_pt2.z);if(!N.MxTools.IsZero(q.getViewAngle())){var Ue=new y.Matrix4;Ue.makeRotationZ(q.getViewAngle());var De=new y.Matrix4().makeTranslation(J.x,J.y,0).multiply(Ue).multiply(new y.Matrix4().makeTranslation(-J.x,-J.y,0));J.applyMatrix4(De),fe.applyMatrix4(De),ve=new y.Vector3(J.x,fe.y,fe.z),ne=new y.Vector3(fe.x,J.y,fe.z);var Ve=new y.Matrix4;Ve.getInverse(De),J.applyMatrix4(Ve),fe.applyMatrix4(Ve),ve.applyMatrix4(Ve),ne.applyMatrix4(Ve)}var rt=[];rt.push(J),rt.push(ve),rt.push(fe),rt.push(ne),rt.push(J);var Ae=null,Te=65280;if(fe.x>J.x)Ae=O.MxThreeJS.createLines(rt,16777215),Te=255;else{var Xe=this.getMxObject().viewCoordLong2Cad(3);Ae=O.MxThreeJS.createDashedLines(rt,16777215,2*Xe,Xe)}var ie=[];ie.push(J),ie.push(ve),ie.push(fe),ie.push(J),ie.push(fe),ie.push(ne);var ue=O.MxThreeJS.createTriangle(ie,Te,.27);this.drawEntity(ue,30),this.drawEntity(Ae,31)},G);function G(q){var J=c.call(this)||this;return J.m_pt1=q,J.m_pt2=q,J}l.MxIntelliSelectJig=L},{"../MxThreeJS":37,"../MxTools":38,"./MxJig":53,"./MxJigCmdManager":54,three:19}],53:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.McEdJigCommand=l.MxDynamicInput=void 0;var n=t("three"),u=t("../MxFun"),c=t("./MxJigCmdManager"),y=t("../MxManager"),b=t("../MxTools"),m=t("../UI/MxUiVue"),O=t("./McEdJigOsnap"),N=t("./McEdJigDynamicTrace"),L=t("./MxPolarAxisTrace"),G=t("./MxGridTrace"),q=t("../MxThreeJS"),J=t("../MxDrawData"),fe=t("./MxOffsetArrow"),ve=(ne.prototype.getFocusIndex=function(){return this.m_isShowDynInput?this.m_iFocusIndex:-1},ne.prototype.ClearDynDrawEntity=function(){for(var Ve=this.m_jig.getMxObject().getTheTempDrawContainer_SmallCoord(),rt=this.m_vecDynDrawEntity.length,Ae=0;Ae<rt;Ae++)u.MxFun.removeThreejsObject(this.m_vecDynDrawEntity[Ae],Ve);this.m_vecDynDrawEntity=[]},ne.prototype.ClearDisplay=function(){this.ClearDynDrawEntity()},ne.prototype.onKeyEcsDown=function(){return this.m_isShowDynInput&&this.m_isInputStatus?(this.m_isInputStatus=!1,m.MxUiVue.OnMxEvent({name:"dynInputReSet"}),1):0},ne.prototype.onKeyDonw=function(Ve){if(!this.m_isShowDynInput||Ve==27||Ve==16||Ve==17||Ve==18)return 0;if(Ve!=32&&Ve!=13)return this.m_isInputStatus=!0,0;if(this.m_isInputStatus&&m.MxUiVue.DynamicInput_isShow())if(m.MxUiVue.DynamicInput_getType()==c.MxJigCmdManager.DynamicInputType.kXYCoordInput){var rt=m.MxUiVue.DynamicInput_getValue1(),Ae=m.MxUiVue.DynamicInput_getValue2(),Te=m.MxUiVue.DynamicInput_getFocusValue(),Xe=m.MxUiVue.DynamicInput_getFocusIndex(),ie="";Te.length!=0?ie=b.MxTools.IsNumerical(Te)?Xe==0?u.MxFun.formatString("{0},{1}",Te,Ae):u.MxFun.formatString("{0},{1}",rt,Te):Te:b.MxTools.IsNumerical(rt)&&b.MxTools.IsNumerical(Ae)&&(ie=u.MxFun.formatString("{0},{1}",rt,Ae)),this.m_iFocusIndex=Xe,m.MxUiVue.setCmdText(ie)}else m.MxUiVue.DynamicInput_getType()==c.MxJigCmdManager.DynamicInputType.kDistanceInput&&(Te=m.MxUiVue.DynamicInput_getFocusValue(),this.m_iFocusIndex=m.MxUiVue.DynamicInput_getFocusIndex(),m.MxUiVue.setCmdText(Te));return this.m_isInputStatus=!1,0},ne.prototype.isInputStatus=function(){return this.m_isInputStatus},ne.prototype.isTruncatedInput=function(){return this.m_isShowDynInput&&this.m_isInputStatus},ne.prototype.initDynInput=function(Ve){this.m_jig=Ve;var rt=this.m_jig.getMxObject();if(this.m_iFocusIndex=-1,this.m_isShowDynInput=!1,!m.MxUiVue.isNull()){m.MxUiVue.DynamicInput_setType(this.m_dynType);var Ae=rt.sysVariable().getSysVarNumber("GETPOINTSTATUS");Ae&c.MxJigCmdManager.GETPOINTSTATUS.OsModeSValidLastPoint&&m.MxUiVue.SetLasetPoint(rt.sysVariable().getSysVarPoint("LASTPOINT")),this.m_dynType==c.MxJigCmdManager.DynamicInputType.kAutoInput&&(Ae&c.MxJigCmdManager.GETPOINTSTATUS.OsModeSValidLastPoint?m.MxUiVue.DynamicInput_setType(c.MxJigCmdManager.DynamicInputType.kDistanceInput):m.MxUiVue.DynamicInput_setType(c.MxJigCmdManager.DynamicInputType.kXYCoordInput))}},ne.prototype.setFocus=function(Ve){m.MxUiVue.OnMxEvent({name:"dynInputSetFocus",param:{isFocus:Ve}})},ne.prototype.exitDynInput=function(){m.MxUiVue.DynamicInput_setShow(!1),m.MxUiVue.DynamicInput_upDisplay()},ne.prototype.isShow=function(){return m.MxUiVue.DynamicInput_isShow()},ne.prototype.drawSolidPoint=function(Ve,rt,Ae,Te){var Xe=q.MxThreeJS.createPoint(Te.toSmallcoord(Ve),this.m_iDashedLineLenColor,rt);Ae.add(Xe),this.m_vecDynDrawEntity.push(Xe)},ne.prototype.drawDashedLine=function(Ve,rt,Ae,Te,Xe,ie){var ue=q.MxThreeJS.createDashedLine(ie.toSmallcoord2(Ve.x,Ve.y,Ve.z),ie.toSmallcoord2(rt.x,rt.y,rt.z),this.m_iDashedLineLenColor,Te,Te);Ae.add(ue),this.m_vecDynDrawEntity.push(ue)},ne.prototype.worldDrawDistanceInput=function(Ve,rt){var Ae=this.m_jig.getMxObject();if(Ae.getMcObject().isValid()&&((Ve=Ve.clone()).z=0,(rt=rt.clone()).z=0,!(Ae.docCoordLong2Screen(Ve.distanceTo(rt))<20))){var Te=Ae.getTheTempDrawContainer_SmallCoord(),Xe=Ae.viewCoordLong2Cad(this.m_dashedLineLen),ie=Ve.clone().sub(rt),ue=ie.clone();ue.applyAxisAngle(new n.Vector3(0,0,1),.5*Math.PI),ue.normalize(),ue.multiplyScalar(Ae.viewCoordLong2Cad(50));var pt=new n.Vector3(0,1,0),mt=new n.Vector3(1,0,0);ue.dot(pt)<0&&ue.multiplyScalar(-1),ie.dot(pt)<0&&ue.multiplyScalar(-1),ie.dot(mt)<0&&ue.multiplyScalar(-1);var Tt=rt.clone().add(ue),kt=Ve.clone().add(ue),It=rt.distanceTo(Ve),nn=new n.Vector3(rt.x+It,rt.y,rt.z);this.drawSolidPoint(rt.clone().add(ue),3,Te,Ae),this.drawSolidPoint(Ve.clone().add(ue),3,Te,Ae),this.drawSolidPoint(nn,3,Te,Ae),this.drawDashedLine(Tt,kt,Te,Xe,Xe,Ae),this.drawDashedLine(rt,Tt,Te,Xe,Xe,Ae),this.drawDashedLine(Ve,kt,Te,Xe,Xe,Ae),this.drawDashedLine(rt,nn,Te,Xe,Xe,Ae);var tn=Ve.clone().sub(rt),pn=0;1e-6<tn.length()&&(pn=tn.angleTo(new n.Vector3(1,0,0)));var _n=0,Dn=pn;tn.dot(pt)<0&&(_n=2*Math.PI-pn,Dn=pn);var an=q.MxThreeJS.createDashedArc(Ae.toSmallcoord(rt),It,_n,Dn,this.m_iDashedLineLenColor,Xe,Xe);Te.add(an),this.m_vecDynDrawEntity.push(an)}},ne.prototype.upDynInput=function(){if(!m.MxUiVue.isNull()){var Ve=this.m_jig.getMxObject(),rt=!1;if(rt=!this.m_jig.isDisableDynInput()&&Ve.getSysVarLong("DYNINPUT")==1,J.MxDrawData.m_isForbiddenDynInput&&(rt=!1),u.MxFun.isPC()||(rt=!1),m.MxUiVue.DynamicInput_setShow(rt),this.m_isShowDynInput=rt){if(m.MxUiVue.DynamicInput_setTip(m.MxUiVue.getCmdTip()),c.MxJigCmdManager.getAcquireStatus()==c.MxJigCmdManager.AcquireStatus.kMove){var Ae=c.MxJigCmdManager.getAcquirePoint();if(m.MxUiVue.DynamicInput_setPos(Ve.currentCoord2Screen(Ae.x,Ae.y,Ae.z)),m.MxUiVue.DynamicInput_getType()==c.MxJigCmdManager.DynamicInputType.kXYCoordInput)m.MxUiVue.DynamicInput_setValue1(Ae.x.toFixed(3)),m.MxUiVue.DynamicInput_setValue2(Ae.y.toFixed(3));else if(m.MxUiVue.DynamicInput_getType()==c.MxJigCmdManager.DynamicInputType.kDistanceInput){var Te=c.MxJigCmdManager.getAcquirePoint(),Xe=m.MxUiVue.GetLasetPoint();this.worldDrawDistanceInput(Te,Xe);var ie=new n.Vector3(Xe.x+.5*(Te.x-Xe.x),Xe.y+.5*(Te.y-Xe.y),Xe.z+.5*(Te.z-Xe.z)),ue=Te.clone().sub(Xe);ue.length()<1e-8&&(ue=new n.Vector3(1,0,0));var pt=ue.clone();pt.applyAxisAngle(new n.Vector3(0,0,1),.5*Math.PI),pt.normalize(),pt.multiplyScalar(Ve.viewCoordLong2Cad(50));var mt=new n.Vector3(0,1,0),Tt=new n.Vector3(1,0,0);pt.dot(mt)<0&&pt.multiplyScalar(-1),ue.dot(mt)<0&&pt.multiplyScalar(-1),ue.dot(Tt)<0&&pt.multiplyScalar(-1),ie.add(pt);var kt=Xe.distanceTo(Te);m.MxUiVue.DynamicInput_setValue1(kt.toFixed(3)),m.MxUiVue.DynamicInput_setValue1Pos(Ve.currentCoord2Screen(ie.x,ie.y,Ae.z)),kt=Xe.distanceTo(Te);var It=Xe.clone();It.x+=kt;var nn=(ie=new n.Vector3(It.x+.5*(Te.x-It.x),It.y+.5*(Te.y-It.y),It.z+.5*(Te.z-It.z))).clone().sub(Xe);nn.normalize(),nn.multiplyScalar(kt),ie=Xe.clone().add(nn);var tn=Te.clone().sub(Xe),pn=0;1e-6<tn.length()&&(pn=tn.angleTo(new n.Vector3(1,0,0))),pn=180*pn/Math.PI,m.MxUiVue.DynamicInput_setValue2(pn.toFixed(3)+"°"),m.MxUiVue.DynamicInput_setValue2Pos(Ve.currentCoord2Screen(ie.x,ie.y,Ae.z))}}m.MxUiVue.DynamicInput_upDisplay()}}},ne.prototype.setDynamicInputType=function(Ve){this.m_dynType=Ve},ne.prototype.getDynamicInputType=function(){return this.m_dynType},ne);function ne(Ve){this.m_dynType=c.MxJigCmdManager.DynamicInputType.kAutoInput,this.m_isInputStatus=!1,this.m_vecDynDrawEntity=[],this.m_dashedLineLen=1.5,this.m_iDashedLineLenColor=8421504,this.m_iFocusIndex=-1,this.m_isShowDynInput=!1,this.m_jig=Ve}l.MxDynamicInput=ve;var Ue=(De.prototype.getTypeName=function(){return""},De.prototype.isExit=function(){return this._isExit},De.prototype.getDetailedResult=function(){return this.m_DetailedResult},De.prototype.clearGroup=function(){this.drawGroup&&(this._mxObject.getTheTempDrawContainer().remove(this.drawGroup),this.drawGroup=null),this.drawGroup_smallCoord&&(this._mxObject.getTheTempDrawContainer().remove(this.drawGroup_smallCoord),this.drawGroup_smallCoord=null)},De.prototype.getParentGroup=function(){return this.drawGroup||(this.drawGroup=new n.Group,this.drawGroup.renderOrder=y.MxData.iGripRenderOrder,this._mxObject.getTheTempDrawContainer().add(this.drawGroup)),this.drawGroup},De.prototype.getParentGroup_smallCoord=function(){return this.drawGroup_smallCoord||(this.drawGroup_smallCoord=new n.Group,this.drawGroup_smallCoord.renderOrder=y.MxData.iGripRenderOrder,this._mxObject.getTheTempDrawContainer_SmallCoord().add(this.drawGroup_smallCoord)),this.drawGroup_smallCoord},De.prototype.onExitCommand=function(Ve){Ve&&this.m_dynInput.exitDynInput(),this.m_osnap.endDrag(),this.m_dynamicTrace.ClearDisplay(),this.m_polarAxisTrace.ClearDisplay(),this.m_offsetArrow.ClearDisplay(),this.m_gridTrace.ClearDisplay(),this.m_dynInput.ClearDisplay(),this.clearGroup(),this._mxObject.getMcObject().onJigCommandEnd()},De.prototype.getOsnap=function(){return this.m_osnap},De.prototype.getOrtho=function(){return this.m_ortho},De.prototype.getDynamicTrace=function(){return this.m_dynamicTrace},De.prototype.getPolarAxisTrace=function(){return this.m_polarAxisTrace},De.prototype.getOffsetArrow=function(){return this.m_offsetArrow},De.prototype.getGridTrace=function(){return this.m_gridTrace},De.prototype.onGetOsnapData=function(Ve){this.m_dynamicTrace.OnDynamicTrace(Ve.id,new n.Vector3(Ve.ptsx,Ve.ptsy,Ve.ptsz),Ve.osmode)},De.prototype.isDisableDynInput=function(){return this.m_isDisableDynInput},De.prototype.setDisableDynInput=function(Ve){this.m_isDisableDynInput=Ve},De.prototype.setDisableOsnap=function(Ve){this.m_isDisableOsnap=Ve},De.prototype.setOffsetInputPostion=function(Ve){this.m_isOffsetInputPostion=Ve},De.prototype.isOffsetInputPostion=function(){return this.m_isOffsetInputPostion},De.prototype.isDisableOsnap=function(){return this.m_isDisableOsnap},De.prototype.setDisableDynamicTrace=function(Ve){this.m_isDisableDynamicTrace=Ve},De.prototype.isDisableDynamicTrace=function(){return this.m_isDisableDynamicTrace},De.prototype.setDisablePolarAxisTrace=function(Ve){this.m_isDisablePolarAxisTrace=Ve},De.prototype.isDisablePolarAxisTrace=function(){return this.m_isDisablePolarAxisTrace},De.prototype.setDisableGridTrace=function(Ve){this.m_isDisableGridTrace=Ve},De.prototype.isDisableGridTrace=function(){return this.m_isDisableGridTrace},De.prototype.setDisableOrthoTrace=function(Ve){this.m_isDisableOrtho=Ve},De.prototype.isDisableOrthoTrace=function(){return this.m_isDisableOrtho},De.prototype.disableAllTrace=function(Ve){Ve===void 0&&(Ve=!0),this.m_isDisableOsnap=Ve,this.m_isDisableDynamicTrace=Ve,this.m_isDisablePolarAxisTrace=Ve,this.m_isDisableGridTrace=Ve,this.m_isDisableOrtho=Ve},De.prototype.onStartCommand=function(){this._isCancle=!1,this._isExit=!1,this.m_DetailedResult=c.MxJigCmdManager.DetailedResult.kUnknown,this.m_dynInput.initDynInput(this),this.m_osnap.startDrag(this.m_isOffsetInputPostion,this);var Ve=this._mxObject.getCurrentMousePostion();this._mxObject.isValidCurMousePostion()||(Ve.x=.5*this._mxObject.getViewWidth(),Ve.y=.5*this._mxObject.getViewHeight());var rt=this._mxObject.screenCoord2Current(Ve.x,Ve.y,0);this.m_osnap.setPoint(rt),this.m_dynamicTrace.Init(),this.m_polarAxisTrace.Init(),this.m_offsetArrow.Init(),this.m_gridTrace.Init(),this.m_ortho.Init(),c.MxJigCmdManager.doMouseMoveImp(),this.m_dynInput.setFocus(!0)},De.prototype.getDynImput=function(){return this.m_dynInput},De.prototype.setMxObject=function(Ve){this._mxObject=Ve},De.prototype.getMxObject=function(){return this._mxObject},De.prototype.setColor=function(Ve){this._iColor=Ve},De.prototype.getColor=function(){return this._iColor},De.prototype.setDynamicInputType=function(Ve){this.m_dynInput.setDynamicInputType(Ve)},De.prototype.getDynamicInputType=function(){return this.m_dynInput.getDynamicInputType()},De.prototype.createTriangle=function(Ve,rt,Ae){var Te=new n.MeshBasicMaterial({color:this._iColor,side:n.DoubleSide}),Xe=new n.Geometry;Xe.vertices.push(Ve),Xe.vertices.push(rt),Xe.vertices.push(Ae);var ie=new n.Vector3(1,1,1),ue=new n.Color(this._iColor),pt=new n.Face3(0,1,2,ie,ue,0);return Xe.faces.push(pt),Xe.computeFaceNormals(),Xe.computeVertexNormals(),new n.Mesh(Xe,Te)},De.prototype.createPoint=function(Ve){var rt=new n.Geometry;rt.vertices.push(Ve);var Ae=new n.PointsMaterial({color:this._iColor,size:3});return new n.Points(rt,Ae)},De.prototype.createLine=function(Ve,rt){var Ae=new n.Geometry,Te=new n.LineBasicMaterial({color:this._iColor});return Ae.vertices.push(Ve,rt),new n.Line(Ae,Te)},De.prototype.drawReserve=function(Ve){this.m_isReserveDrawStatus=!0,this.m_callReserveDrawAddEntity=Ve,this.upDisplay(),this.m_isReserveDrawStatus=!1,this.m_callReserveDrawAddEntity=null},De.prototype.drawMcDbEntity=function(Ve,rt,Ae){var Te=Ve.getImp(),Xe=Te.GetObjectID();Xe==0&&Ve.tempRelationObject(),this.m_isReserveDrawStatus?this._mxObject.getMcObject().DrawEntity(Te,rt,Ae):this._mxObject.getMcObject().onJigDrawEntityDisplay(Te,rt,Ae),Xe==0&&Ve.freeTempRelationObject()},De.prototype.drawMcDbLine=function(Ve,rt,Ae,Te,Xe,ie,ue){this.m_isReserveDrawStatus?this._mxObject.getMcObject().DrawLine(Ve,rt,Ae,Te,Xe,ie,ue):this._mxObject.getMcObject().onJigDrawEntityDisplay_line(Ve,rt,Ae,Te,Xe,ie,ue)},De.prototype.drawEntity=function(Ve,rt,Ae){if(Ae===void 0&&(Ae=!1),Ve!=null)if(this.m_isReserveDrawStatus)Ve.renderOrder=rt??y.MxData.iDynJigRenderOrder,this._mxObject.addObject(Ve),this.m_callReserveDrawAddEntity&&this.m_callReserveDrawAddEntity(Ve);else{var Te="MxDynDraw_"+this._DynNameId.toString();Ve.name=Te,Ve.renderOrder=rt??y.MxData.iDynJigRenderOrder,this._aryDynDrawObjectNamesId==null&&(this._aryDynDrawObjectNamesId=new Array),this._aryDynDrawObjectNamesId.push(this._DynNameId),this._DynNameId++,Ae?this.getParentGroup_smallCoord().add(Ve):this.getParentGroup().add(Ve)}},De.prototype.floorPowerOfTwo=function(Ve){return Math.pow(2,Math.floor(Math.log(Ve)/Math.LN2))},De.prototype.makeTextSprite=function(Ve,rt,Ae,Te,Xe){var ie,ue=document.createElement("canvas"),pt=ue.getContext("2d"),mt=u.MxFun.formatString("normal {0}px Arial","256");pt.font=mt;var Tt=pt.measureText(Ve);ie=2*this.floorPowerOfTwo(Tt.width),ue.width=ie,ue.height=256,pt.font=mt,pt.textAlign="center",pt.textBaseline="middle";var kt=u.MxFun.formatString("#{0}",Xe.toString(16));pt.fillStyle=kt,pt.fillText(Ve,ie/2,128);var It=new n.Texture(ue);It.needsUpdate=!0;var nn=new n.SpriteMaterial({map:It});nn.transparent=!1,nn.rotation=Te;var tn=new n.Sprite(nn);return tn.scale.set(ie/256*Ae,Ae,1),tn.position.set(rt.x,rt.y,0),tn},De.prototype.drawText=function(Ve,rt,Ae,Te){var Xe=this.makeTextSprite(Ve,Te,rt,Ae,this._iColor);this.drawEntity(Xe)},De.prototype.drawPoints=function(Ve){for(var rt=0;rt<Ve.length;rt++){var Ae=new n.Geometry;Ae.vertices.push(Ve[rt]);var Te=new n.PointsMaterial({color:this._iColor,size:3}),Xe=new n.Points(Ae,Te);this.drawEntity(Xe)}},De.prototype.drawPoint=function(Ve){var rt=new n.Geometry;rt.vertices.push(Ve);var Ae=new n.PointsMaterial({color:this._iColor,size:3}),Te=new n.Points(rt,Ae);this.drawEntity(Te)},De.prototype.drawPolyline=function(Ve){for(var rt=new n.Geometry,Ae=0;Ae<Ve.length;Ae++)rt.vertices.push(Ve[Ae]);var Te=new n.LineBasicMaterial({color:this._iColor}),Xe=new n.Line(rt,Te);this.drawEntity(Xe)},De.prototype.drawSpline=function(Ve){},De.prototype.drawCircle=function(Ve,rt){var Ae=new n.CircleGeometry(rt,64,3,2*Math.PI),Te=new n.LineBasicMaterial({color:this._iColor});Ae.vertices.shift();var Xe=new n.LineLoop(Ae,Te);Xe.position.x=Ve.x,Xe.position.y=Ve.y,Xe.position.z=Ve.z,this.drawEntity(Xe)},De.prototype.drawArc=function(Ve,rt,Ae,Te){var Xe=new n.CircleGeometry(rt,64,Ae,Te),ie=new n.LineBasicMaterial({color:this._iColor});Xe.vertices.shift();var ue=new n.Line(Xe,ie);ue.position.x=Ve.x,ue.position.y=Ve.y,ue.position.z=Ve.z,this.drawEntity(ue)},De.prototype.drawLine=function(Ve,rt){var Ae=new n.Geometry,Te=new n.LineBasicMaterial({color:this._iColor});Ae.vertices.push(Ve,rt);var Xe=new n.Line(Ae,Te);this.drawEntity(Xe)},De.prototype.removeDynDrawObject=function(){if(this._aryDynDrawObjectNamesId!=null){for(var Ve=0;Ve<this._aryDynDrawObjectNamesId.length;Ve++){var rt,Ae="MxDynDraw_"+this._aryDynDrawObjectNamesId[Ve].toString();(rt=this.getParentGroup().getObjectByName(Ae))?u.MxFun.removeThreejsObject(rt,this.getParentGroup()):(rt=this.getParentGroup_smallCoord().getObjectByName(Ae))&&u.MxFun.removeThreejsObject(rt,this.getParentGroup_smallCoord())}this._aryDynDrawObjectNamesId=[],this._mxObject.getMcObject().onJigClearDisplay()}},De.prototype.acquirePoint=function(Ve,rt){rt===void 0&&(rt=!0);var Ae=c.MxJigCmdManager.acquirePoint(Ve,rt);return this._isExit=Ae.exit,this._isExit&&(this.m_DetailedResult=Ae.DetailedResult),Ae},De.prototype.acquireDist=function(Ve,rt){var Ae=c.MxJigCmdManager.acquireDist(Ve,rt);return this._isExit=Ae.exit,this._isExit&&(this.m_DetailedResult=Ae.DetailedResult),Ae},De.prototype.acquireAngle=function(Ve,rt){var Ae=c.MxJigCmdManager.acquireAngle(Ve,rt);return this._isExit=Ae.exit,this._isExit&&(this.m_DetailedResult=Ae.DetailedResult),Ae},De.prototype.acquireInt=function(){var Ve=c.MxJigCmdManager.acquireInt();return this._isExit=Ve.exit,this._isExit&&(this.m_DetailedResult=Ve.DetailedResult),Ve},De.prototype.acquireString=function(){var Ve=c.MxJigCmdManager.acquireString();return this._isExit=Ve.exit,this._isExit&&(this.m_DetailedResult=Ve.DetailedResult),Ve},De.prototype.acquireKeyword=function(){var Ve=c.MxJigCmdManager.acquireKeyword();return this._isExit=Ve.exit,this._isExit&&(this.m_DetailedResult=Ve.DetailedResult),Ve},De.prototype.notifyCancleExit=function(Ve){this.m_DetailedResult=Ve,this._isCancle=!0,this.removeDynDrawObject(),this.done(c.MxJigCmdManager.DragStatus.kCancel),this.onExitCommand(!0),c.MxJigCmdManager.commandRunComplete(this)},De.prototype.notifySampler=function(){var Ve=this.sampler();if(this.m_dynInput.upDynInput(),Ve==c.MxJigCmdManager.DragStatus.kNormal&&(this.removeDynDrawObject(),this.upDisplay()),this._isExit){var rt=this.done(Ve);this._isCancle||(rt==c.MxJigCmdManager.DoneStatius.kContinueCommand?(this._isExit=!1,c.MxJigCmdManager.doMouseMoveImp(),m.MxUiVue.OnMxEvent({name:"dynInputReSet"})):(this.removeDynDrawObject(),c.MxJigCmdManager.commandRunComplete(this),this.onExitCommand(!0)))}this._mxObject.updateDisplay()},De.prototype.getCurrentMouseButton=function(){return c.MxJigCmdManager.getCurrentMouseButton()},De.prototype.userInputControls=function(){return this._userInputContros},De.prototype.setUserInputControls=function(Ve){this._userInputContros=Ve},De.prototype.abort=function(Ve){c.MxJigCmdManager.stopCmd(Ve)},De);function De(){this._isExit=!1,this._aryDynDrawObjectNamesId=void 0,this._DynNameId=1,this._iColor=16777215,this._isCancle=!1,this.m_isDisableDynInput=!1,this.m_isDisableOsnap=!1,this.m_isDisableDynamicTrace=!1,this.m_isDisablePolarAxisTrace=!1,this.m_isDisableGridTrace=!1,this.m_isDisableOrtho=!1,this.m_dynInput=new ve(this),this.m_dynamicTrace=new N.McEdJigDynamicTrace(this),this.m_polarAxisTrace=new L.MxPolarAxisTrace(this),this.m_offsetArrow=new fe.MxOffsetArrow(this),this.m_gridTrace=new G.MxGridTrace(this),this.m_osnap=new O.McEdJigOsnap(this),this.m_ortho=new O.McEdJigOrtho(this),this._userInputContros=c.MxJigCmdManager.UserInputControls.kNullResponseAccepted,this.m_isOffsetInputPostion=!1,this.m_isReserveDrawStatus=!1,this.m_callReserveDrawAddEntity=null,this.drawGroup=null,this.drawGroup_smallCoord=null,this._mxObject=null,this.m_DetailedResult=c.MxJigCmdManager.DetailedResult.kUnknown}l.McEdJigCommand=Ue},{"../MxDrawData":22,"../MxFun":27,"../MxManager":29,"../MxThreeJS":37,"../MxTools":38,"../UI/MxUiVue":65,"./McEdJigDynamicTrace":42,"./McEdJigOsnap":43,"./MxGridTrace":51,"./MxJigCmdManager":54,"./MxOffsetArrow":56,"./MxPolarAxisTrace":57,three:19}],54:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxJigCmdManager=l.AcquireReturn=void 0;var n,u=t("three"),c=t("../MxFun"),y=t("./MxJig"),b=t("../MxManager"),m=t("./MrxDbgUiPrPoint"),O=t("./MrxDbgUiPrBase"),N=t("../UI/MxUiVue"),L=t("../MxTools"),G=t("../MxString"),q=t("./McEdJigOsnap"),J=t("../MxDrawData"),fe=t("./MrxDbgUiPrDist"),ve=function(){this.status=n.DragStatus.kNoChange,this.exit=!0,this.DetailedResult=n.DetailedResult.kUnknown,this.sKeyValue="",this.dist=0,this.iVal=0,this.sValue="",this.ang=0};l.AcquireReturn=ve,function(ne){var Ue,De,Ve,rt,Ae,Te,Xe,ie,ue,pt,mt,Tt,kt,It,nn,tn,pn,_n,Dn,an;(De=Ue=ne.UserInputControls||(ne.UserInputControls={}))[De.kGovernedByOrthoMode=1]="kGovernedByOrthoMode",De[De.kNullResponseAccepted=2]="kNullResponseAccepted",De[De.kDontEchoCancelForCtrlC=4]="kDontEchoCancelForCtrlC",De[De.kDontUpdateLastPoint=8]="kDontUpdateLastPoint",De[De.kNoDwgLimitsChecking=16]="kNoDwgLimitsChecking",De[De.kNoZeroResponseAccepted=32]="kNoZeroResponseAccepted",De[De.kNoNegativeResponseAccepted=64]="kNoNegativeResponseAccepted",De[De.kAccept3dCoordinates=128]="kAccept3dCoordinates",De[De.kAcceptMouseUpAsPoint=256]="kAcceptMouseUpAsPoint",De[De.kAnyBlankTerminatesInput=512]="kAnyBlankTerminatesInput",De[De.kInitialBlankTerminatesInput=1024]="kInitialBlankTerminatesInput",De[De.kAcceptOtherInputString=2048]="kAcceptOtherInputString",De[De.kGovernedByUCSDetect=4096]="kGovernedByUCSDetect",De[De.kNoZDirectionOrtho=8192]="kNoZDirectionOrtho",De[De.kSpacesInAccepted=16384]="kSpacesInAccepted",(rt=Ve=ne.AcquireStatus||(ne.AcquireStatus={}))[rt.kNoChange=0]="kNoChange",rt[rt.kMove=1]="kMove",rt[rt.kBegan=2]="kBegan",rt[rt.kEnd=3]="kEnd",rt[rt.kMouseUp=4]="kMouseUp",rt[rt.kMouseDown=5]="kMouseDown",rt[rt.kCancle=6]="kCancle",(Te=Ae=ne.DragStatus||(ne.DragStatus={}))[Te.kNoChange=-6]="kNoChange",Te[Te.kCancel=-4]="kCancel",Te[Te.kOther=-3]="kOther",Te[Te.kNull=-1]="kNull",Te[Te.kNormal=0]="kNormal",Te[Te.kKW1=1]="kKW1",(ie=Xe=ne.DetailedResult||(ne.DetailedResult={}))[ie.kUnknown=1]="kUnknown",ie[ie.kTouchDownIn=2]="kTouchDownIn",ie[ie.kTouchUpIn=3]="kTouchUpIn",ie[ie.kMouseLeftIn=4]="kMouseLeftIn",ie[ie.kMouseLeftUpIn=5]="kMouseLeftUpIn",ie[ie.kMouseRightIn=6]="kMouseRightIn",ie[ie.kKeyIn=7]="kKeyIn",ie[ie.kCoordIn=8]="kCoordIn",ie[ie.kNullEnterIn=9]="kNullEnterIn",ie[ie.kNullSpaceIn=10]="kNullSpaceIn",ie[ie.kEcsIn=11]="kEcsIn",ie[ie.kNewCommadIn=12]="kNewCommadIn",(ue=ne.DoneStatius||(ne.DoneStatius={}))[ue.kContinueCommand=0]="kContinueCommand",ue[ue.kExitCommand=1]="kExitCommand",(mt=pt=ne.InType||(ne.InType={}))[mt.kGetBegan=1]="kGetBegan",mt[mt.kGetEnd=2]="kGetEnd",(kt=Tt=ne.MouseButton||(ne.MouseButton={}))[kt.kInvalid=-1]="kInvalid",kt[kt.kLeft=0]="kLeft",kt[kt.kMid=1]="kMid",kt[kt.kRight=2]="kRight",(nn=It=ne.COMMAND_IN||(ne.COMMAND_IN={}))[nn.COMMAND_IN_NO_ENTITY=0]="COMMAND_IN_NO_ENTITY",nn[nn.COMMAND_IN_EMTPY=1]="COMMAND_IN_EMTPY",nn[nn.COMMAND_IN_KEY=2]="COMMAND_IN_KEY",nn[nn.COMMAND_IN_STRING=3]="COMMAND_IN_STRING",nn[nn.COMMAND_IN_COORD=5]="COMMAND_IN_COORD",nn[nn.COMMAND_IN_DIST=6]="COMMAND_IN_DIST",nn[nn.COMMAND_IN_INVALID=7]="COMMAND_IN_INVALID",nn[nn.COMMAND_IN_INVALID_ZERO=8]="COMMAND_IN_INVALID_ZERO",nn[nn.COMMAND_IN_INVALID_NEG=9]="COMMAND_IN_INVALID_NEG",nn[nn.COMMAND_IN_INT=10]="COMMAND_IN_INT",(pn=tn=ne.COMMAND_GET||(ne.COMMAND_GET={}))[pn.COMMAND_GET_STRING=1]="COMMAND_GET_STRING",pn[pn.COMMAND_GET_KEY=2]="COMMAND_GET_KEY",pn[pn.COMMAND_GET_DIST=4]="COMMAND_GET_DIST",pn[pn.COMMAND_GET_COORD=8]="COMMAND_GET_COORD",pn[pn.COMMAND_GET_INT=16]="COMMAND_GET_INT",(_n=ne.DynamicInputType||(ne.DynamicInputType={}))[_n.kNoInput=0]="kNoInput",_n[_n.kXYCoordInput=1]="kXYCoordInput",_n[_n.kDistanceInput=2]="kDistanceInput",_n[_n.kDynTip=3]="kDynTip",_n[_n.kAutoInput=4]="kAutoInput",_n[_n.kAngleInput=5]="kAngleInput",(Dn=ne.GETPOINTSTATUS||(ne.GETPOINTSTATUS={}))[Dn.OsModeSValidLastPoint=1]="OsModeSValidLastPoint",Dn[Dn.OsModeSTempDisable=2]="OsModeSTempDisable",Dn[Dn.OsModeOrthoTempDisable=4]="OsModeOrthoTempDisable",Dn[Dn.OsModeSValidLastMovePoint=8]="OsModeSValidLastMovePoint",Dn[Dn.OsModePoloarTempDisable=16]="OsModePoloarTempDisable",Dn[Dn.OsModeDynTraceTempDisable=32]="OsModeDynTraceTempDisable",Dn[Dn.OsModeGridSnapTempDisable=64]="OsModeGridSnapTempDisable",(an=ne.OsnapMode||(ne.OsnapMode={}))[an.kOsModekInValid=0]="kOsModekInValid",an[an.kOsModeEnd=1]="kOsModeEnd",an[an.kOsModeMid=2]="kOsModeMid",an[an.kOsModeCen=3]="kOsModeCen",an[an.kOsModeNode=4]="kOsModeNode",an[an.kOsModeQuad=5]="kOsModeQuad",an[an.kOsModeIns=7]="kOsModeIns",an[an.kOsModePerp=8]="kOsModePerp",an[an.kOsModeTan=9]="kOsModeTan",an[an.kOsModeNear=10]="kOsModeNear",an[an.kOsModeInt=11]="kOsModeInt";var Rn,Lt=void 0,wn=void 0,hn=Ve.kNoChange,xn=Tt.kInvalid,$n=-9999999,Xr=new u.Vector2($n,$n),ti=!1,gn=void 0,Xn=!1,Kn=0,Vn=new Map,Yn=new Array,Vr=new G.MxString,xi=void 0,Si=-2;function qn(){Lt?.notifySampler()}function ia(Pi,oi){var Ni=Pi.srcElement;if(Ni&&(J.MxDrawData.m_isMapBox||Ni.tagName=="CANVAS")){if(Lt==null||Lt.getDynImput().isTruncatedInput())return 0;Xr.x=Pi.offsetX,Xr.y=Pi.offsetY,oi&&(Xr.x=oi.x,Xr.y=oi.y),sa(Xr)}return 0}function Wi(Pi,oi){if(Pi.button!=Tt.kLeft)return 0;var Ni=Pi.srcElement;if(!Ni||!J.MxDrawData.m_isMapBox&&Ni.tagName!="CANVAS"||Lt==null||Lt.getDynImput().isTruncatedInput())return 0;Xr.x=Pi.offsetX,Xr.y=Pi.offsetY,oi&&(Xr.x=oi.x,Xr.y=oi.y),Rn=Lt.getMxObject().screenCoord2Current(Pi.offsetX,Pi.offsetY,0);var za=Lt.getOsnap();return Rn=za.reCompteCurrentPoint(Rn),hn=Ve.kMouseUp,xn=Pi.button,qn(),Pi.stopPropagation(),1}function ha(Pi,oi,Ni){var za=Lt.getMxObject().screenCoord2Current(Pi,oi,Ni),ki=Lt.getOsnap();za=ki.reCompteCurrentPoint(za);var Aa=ki.getCurrentOSnapPoint(za);za=Aa.pt;var Ja,yo=!1;if(Aa.isSnapPoint&&(yo=!0),yo||(Ja=Lt.getDynamicTrace().GetTracePoint())&&(za.copy(Ja),yo=!0),yo||(Ja=Lt.getPolarAxisTrace().GetTracePoint())&&(za.copy(Ja),yo=!0),!yo){var ls=Lt.getOrtho();ls.OnViewMouseMove(za);var xo=ls.GetCurOrthoPoint();xo.isValid&&(za.copy(xo.pt),yo=!0)}return yo||(Ja=Lt.getGridTrace().GetTracePoint())&&(za.copy(Ja),yo=!0),za}function ai(Pi,oi){if(Pi.button!=Tt.kLeft)return 0;Lt!=null&&Lt.getDynImput().isShow()&&Lt.getDynImput().setFocus(!0);var Ni=Pi.srcElement;if(!Ni||!J.MxDrawData.m_isMapBox&&Ni.tagName!="CANVAS"||Lt==null||Lt.getDynImput().isTruncatedInput())return 0;Xr.x=Pi.offsetX,Xr.y=Pi.offsetY,oi&&(Xr.x=oi.x,Xr.y=oi.y);var za=ha(Pi.offsetX,Pi.offsetY,0);return q.McEdImpJigGlobalData.setPrvPoint(za),Lt.getOsnap().seInValidPoint(),Rn=za,hn=Ve.kMouseDown,xn=Pi.button,qn(),Pi.stopPropagation(),1}function Ia(Pi){if(Pi.stopPropagation(),Pi.preventDefault(),Pi.touches.length!=0){Lt!=null&&Lt.getDynImput().isShow()&&Lt.getDynImput().setFocus(!0);var oi=Pi.srcElement;if(oi&&(J.MxDrawData.m_isMapBox||oi.tagName=="CANVAS")){if(Lt==null)return;var Ni=Pi.target.getBoundingClientRect();Xr.x=Pi.touches[0].clientX-Ni.left,Xr.y=Pi.touches[0].clientY-Ni.top;var za=ha(Xr.x,Xr.y,0);return q.McEdImpJigGlobalData.setPrvPoint(za),Lt.getOsnap().seInValidPoint(),Rn=za,hn=Ve.kBegan,xn=Tt.kInvalid,qn(),1}}}function fi(Pi){Pi.stopPropagation(),Pi.preventDefault();var oi=Pi.srcElement;if(oi&&(J.MxDrawData.m_isMapBox||oi.tagName=="CANVAS")){if(Lt==null||Xr.x==$n||Xr.y==$n)return;if(0<Pi.touches.length){var Ni=Pi.target.getBoundingClientRect();Xr.x=Pi.touches[0].clientX-Ni.left,Xr.y=Pi.touches[0].clientY-Ni.top}var za=ha(Xr.x,Xr.y,0);return q.McEdImpJigGlobalData.setPrvPoint(za),Lt.getOsnap().seInValidPoint(),Rn=za,hn=Ve.kEnd,xn=Tt.kInvalid,qn(),1}}function An(Pi){Pi.stopPropagation(),Pi.preventDefault();var oi=Pi.srcElement;if(oi&&(J.MxDrawData.m_isMapBox||oi.tagName=="CANVAS")){if(Lt==null)return;var Ni=Pi.target.getBoundingClientRect();Xr.x=Pi.touches[0].clientX-Ni.left,Xr.y=Pi.touches[0].clientY-Ni.top,sa(Xr)}}function sa(Pi){if(Xn=!1,Pi==null){if(Xr.x==$n||Xr.y==$n)return;Pi=Xr}Lt.getDynImput().ClearDisplay();var oi=Lt.getMxObject().screenCoord2Current(Pi.x,Pi.y,0),Ni=Lt.getOffsetArrow();Ni.ReSetTempDisplay(),Ni.MouseMove(oi);var za=Lt.getOsnap();oi=za.reCompteCurrentPoint(oi);var ki=Lt.getMxObject().viewCoordLong2Cad(.5*J.MxDrawData.m_dInputRectWidth);za.setPoint(oi,ki);var Aa=Lt.getDynamicTrace();Aa.ReSetTempDisplay(),Aa.OnDynamicTrace(0,oi,ne.OsnapMode.kOsModekInValid),Aa.MouseMove(oi);var Ja=!1,yo=Aa.GetTracePoint();yo&&(oi.x=yo.x,oi.y=yo.y,oi.z=yo.z,Ja=!0);var ls=Lt.getPolarAxisTrace();if(ls.ReSetTempDisplay(),Ja||(ls.MouseMove(oi),(yo=ls.GetTracePoint())&&(oi.x=yo.x,oi.y=yo.y,oi.z=yo.z,Ja=!0)),!Ja){var xo=Lt.getOrtho();xo.OnViewMouseMove(oi);var _o=xo.GetCurOrthoPoint();_o.isValid&&oi.copy(_o.pt)}var Ao=Lt.getGridTrace();Ao.ReSetTempDisplay(),Ja||(Ao.MouseMove(oi),(yo=Ao.GetTracePoint())&&(oi.x=yo.x,oi.y=yo.y,oi.z=yo.z,Ja=!0)),Rn=oi,hn=Ve.kMove;var il=Lt.getMxObject();il.sysVariable().setSysVarPoint("LASTMOVEPOINT",oi);var zr=il.sysVariable().getSysVarNumber("GETPOINTSTATUS");zr|=ne.GETPOINTSTATUS.OsModeSValidLastMovePoint,il.sysVariable().setSysVarNumber("GETPOINTSTATUS",zr),qn.call(this)}function Nn(){Lt&&(xi=Lt.getMxObject().getEventManager(),c.MxFun.isPC()?(xi.addEventListener("mouseup",Wi,!0),xi.addEventListener("mousemove",ia,!0),xi.addEventListener("mousedown",ai,!0)):(xi.addEventListener("touchstart",Ia,!0),xi.addEventListener("touchend",fi,!0),xi.addEventListener("touchmove",An,!0)))}function fn(){xi&&(c.MxFun.isPC()?(xi.removeEventListener("mouseup",Wi,!0),xi.removeEventListener("mousemove",ia,!0),xi.removeEventListener("mousedown",ai,!0)):(xi.removeEventListener("touchstart",Ia,!0),xi.removeEventListener("touchend",fi,!0),xi.removeEventListener("touchmove",An,!0)),xi=void 0)}function un(Pi){var oi=Pi.getOrbitControls();c.MxFun.isPC()?(Si=oi.mouseButtons.LEFT,oi.mouseButtons.LEFT=-1):oi.enabled=!1,oi.resetStatusValue(),Pi.callEvent("dragWillStart"),Pi.updateDisplay()}function Ln(Pi){var oi=new u.Vector3,Ni=!1,za=new G.MxString(Pi),ki=za.AnalyzeString(",");if(ki.length<2)for(;;){var Aa=Lt.getDynImput().getFocusIndex();if(Aa==-1||za.IsEmpty()||!L.MxTools.IsNumerical(za))break;if(Aa==0){var Ja=L.MxTools._tstof(za.m_val);if(L.MxTools.IsZero(Ja)||!((il=(zr=Lt.getMxObject()).sysVariable().getSysVarNumber("GETPOINTSTATUS"))&ne.GETPOINTSTATUS.OsModeSValidLastPoint)||!(il&ne.GETPOINTSTATUS.OsModeSValidLastMovePoint))break;var yo=zr.sysVariable().getSysVarPoint("LASTPOINT");if((xo=zr.sysVariable().getSysVarPoint("LASTMOVEPOINT").clone().sub(yo)).length()<1e-7)break;xo.normalize(),xo.multiplyScalar(Ja);var ls=(oi=yo.add(xo)).clone().add(xo.multiplyScalar(10));zr.sysVariable().setSysVarPoint("LASTMOVEPOINT",ls),Ni=!0}else if(Aa==1){var xo,_o=L.MxTools._tstof(za.m_val);if(!((il=(zr=Lt.getMxObject()).sysVariable().getSysVarNumber("GETPOINTSTATUS"))&ne.GETPOINTSTATUS.OsModeSValidLastPoint)||!(il&ne.GETPOINTSTATUS.OsModeSValidLastMovePoint)||(yo=zr.sysVariable().getSysVarPoint("LASTPOINT"),(xo=zr.sysVariable().getSysVarPoint("LASTMOVEPOINT").clone().sub(yo)).length()<1e-7))break;var Ao=new u.Vector3(xo.length(),0,0);Ao.applyAxisAngle(new u.Vector3(0,0,1),_o*Math.PI/180),ls=(oi=yo.add(Ao)).clone().add(Ao.multiplyScalar(2)),zr.sysVariable().setSysVarPoint("LASTMOVEPOINT",ls),Ni=!0}break}else{var il,zr=Lt.getMxObject(),zn=new G.MxString(ki[0]),Un=new G.MxString(ki[1]),Gr=new G.MxString("0");if(2<ki.length&&(Gr.m_val=ki[2]),zn.IsEmpty()||zn.Left(1)!="@")L.MxTools.IsNumerical(zn)&&L.MxTools.IsNumerical(Un)&&L.MxTools.IsNumerical(Gr)?(Ni=!0,oi.x=L.MxTools._tstof(zn.m_val),oi.y=L.MxTools._tstof(Un.m_val),oi.z=L.MxTools._tstof(Gr.m_val)):Ni=!1;else if(zn.m_val=zn.m_val.substring(1,zn.m_val.length),L.MxTools.IsNumerical(zn)&&L.MxTools.IsNumerical(Un)&&L.MxTools.IsNumerical(Gr))if((il=zr.sysVariable().getSysVarNumber("GETPOINTSTATUS"))&ne.GETPOINTSTATUS.OsModeSValidLastPoint){Ni=!0;var ni=L.MxTools._tstof(zn.m_val),Ei=L.MxTools._tstof(Un.m_val),$t=L.MxTools._tstof(Gr.m_val);yo=zr.sysVariable().getSysVarPoint("LASTPOINT"),oi.x=yo.x+ni,oi.y=yo.y+Ei,oi.z=yo.z+$t}else Ni=!1;else Ni=!1}return Ni?oi:null}function hr(Pi,oi){oi===void 0&&(oi=!1),N.MxUiVue.AcutPrintfNoFormat(Pi,oi)}function hi(Pi,oi){if(Pi==It.COMMAND_IN_INVALID){var Ni=N.MxUiVue.getCmdTip();return hr(oi),hr(Ni),Ae.kNoChange}return Pi==It.COMMAND_IN_INVALID_ZERO?(Ni=N.MxUiVue.getCmdTip(),Lt.userInputControls()&Ue.kNoNegativeResponseAccepted?hr(`
- 值必须为正 且非零。
- `):hr(`
- 值必不能为零。
- `),hr(Ni),Ae.kOther):Pi!=It.COMMAND_IN_INVALID_NEG?Ae.kNoChange:(Ni=N.MxUiVue.getCmdTip(),Lt.userInputControls()&Ue.kNoZeroResponseAccepted?hr(`
- 值必须为正 且非零。
- `):hr(`
- 值必不能为负。
- `),hr(Ni),Ae.kOther)}function bi(Pi){var oi={iRet:It.COMMAND_IN_NO_ENTITY,sValue:"",iKey:Ae.kNull,dDist:0,iVal:0,pt:null,cmdText:""};if(!Xn)return oi;var Ni=Lt.userInputControls(),za=N.MxUiVue.getCmdText();if((oi.cmdText=za).length==0)return Ni&Ue.kNullResponseAccepted?oi.iRet=It.COMMAND_IN_EMTPY:oi.iRet=It.COMMAND_IN_INVALID,oi;if(Pi&tn.COMMAND_GET_KEY&&0<Vn.size){var ki=new G.MxString(za);ki.MakeUpper(),ki.TrimLeft(" "),ki.TrimRight(" ");var Aa=Vn.get(ki.m_val);if(Aa!=null)return oi.iRet=It.COMMAND_IN_KEY,oi.iKey=Aa,oi.sValue=ki.m_val,oi}if(Pi&tn.COMMAND_GET_DIST&&L.MxTools.IsNumerical(za))return oi.dDist=L.MxTools._tstof(za),Ni&Ue.kNoZeroResponseAccepted&&L.MxTools.IsZero(oi.dDist)?oi.iRet=It.COMMAND_IN_INVALID_ZERO:Ni&Ue.kNoNegativeResponseAccepted&&oi.dDist<0?oi.iRet=It.COMMAND_IN_INVALID_NEG:(oi.sValue=za,oi.iRet=It.COMMAND_IN_DIST),oi;if(Pi&tn.COMMAND_GET_INT&&L.MxTools.IsNumerical(za))return oi.iVal=L.MxTools._tstoi(za),Ni&Ue.kNoZeroResponseAccepted&&oi.iVal==0?oi.iRet=It.COMMAND_IN_INVALID_ZERO:Ni&Ue.kNoNegativeResponseAccepted&&oi.iVal<0?oi.iRet=It.COMMAND_IN_INVALID_NEG:(oi.sValue=za,oi.iRet=It.COMMAND_IN_INT),oi;if(Pi&tn.COMMAND_GET_COORD){var Ja=Ln(za);if(Ja!=null)return oi.sValue=za,oi.iRet=It.COMMAND_IN_COORD,oi.pt=Ja,oi}return Pi&tn.COMMAND_GET_STRING?(oi.sValue=za,oi.iRet=It.COMMAND_IN_STRING):oi.iRet=It.COMMAND_IN_INVALID,oi}function Ra(Pi){var oi=Lt.getMxObject();if(oi.sysVariable().setSysVarPoint("LASTPOINT",Pi),Pi){var Ni=oi.sysVariable().getSysVarNumber("GETPOINTSTATUS");Ni|=ne.GETPOINTSTATUS.OsModeSValidLastPoint,oi.sysVariable().setSysVarNumber("GETPOINTSTATUS",Ni)}else Ni=oi.sysVariable().getSysVarNumber("GETPOINTSTATUS"),Ni&=~ne.GETPOINTSTATUS.OsModeSValidLastPoint,oi.sysVariable().setSysVarNumber("GETPOINTSTATUS",Ni)}function so(Pi){var oi=new ve;return hn==Ve.kMove?(oi.status=Ae.kNormal,oi.pt=Rn,oi.exit=!1):hn==Ve.kEnd?Pi&pt.kGetEnd?(oi.status=Ae.kNormal,oi.pt=Rn,oi.exit=!0,oi.DetailedResult=Xe.kTouchUpIn,Ra(oi.pt)):(oi.status=Ae.kNormal,oi.pt=Rn,oi.exit=!1):hn==Ve.kCancle?(oi.status=Ae.kCancel,oi.pt=Rn,oi.exit=!0):hn==Ve.kBegan?Pi&pt.kGetBegan?(oi.status=Ae.kNormal,oi.pt=Rn,oi.exit=!0,oi.DetailedResult=Xe.kTouchDownIn,Ra(oi.pt)):(oi.status=Ae.kNormal,oi.pt=Rn,oi.exit=!1):hn==Ve.kMouseDown?(oi.status=Ae.kNormal,oi.pt=Rn,oi.exit=!0,oi.DetailedResult=Xe.kMouseLeftIn,Ra(oi.pt)):(oi.status=Ae.kNoChange,oi.pt=void 0,oi.exit=!1),oi}ne.getInputKeyword=function(Pi){if(Pi<1)return"";for(var oi,Ni=Vn.entries();!(oi=Ni.next()).done;)if(oi.value==Pi)return oi.key;return""},ne.GetKeyWordToString=function(){return Yn},ne.keywordList=function(){return Vr.m_val},ne.setKeywordList=function(Pi){if(Vr.m_val=Pi,Vn.clear(),Yn.length=0,!Vr.IsEmpty())if(Vr.TrimLeft(" "),Vr.TrimRight(" "),Vr.m_val[0]=="["&&Vr.m_val[Vr.m_val.length-1]=="]"){Vr.TrimLeft("["),Vr.TrimRight("]");for(var oi=Vr.AnalyzeString("/"),Ni=1,za=0;za<oi.length;za++){var ki=(yo=new G.MxString(oi[za])).Find("(");if(ki!=-1){var Aa=new G.MxString(yo.Left(ki)),Ja=new G.MxString(yo.Right(yo.GetLength()-ki-1));Ja.TrimRight(")"),Aa.IsEmpty()||Ja.IsEmpty()||(Ja.MakeUpper(),Vn.set(Ja.m_val,Ni),Ni++,Yn.push(new L.MxPair(Ja.m_val,Aa.m_val)))}}}else for(oi=Vr.AnalyzeString(" "),Ni=1,za=0;za<oi.length;za++){var yo;(yo=new G.MxString(oi[za])).IsEmpty()||(yo.MakeUpper(),Vn.set(yo.m_val,Ni),Ni++)}},ne.getAcquirePoint=function(){return Rn},ne.getAcquireStatus=function(){return hn},ne.doMouseMoveImp=sa,ne.OnThreeControlsChage=function(){if(Lt!=null)return Lt.getOsnap().reComputeOffset(),void(Xr.x!=$n&&Xr.y!=$n&&sa(Xr))},ne.OnEnter=function(Pi){Kn=Pi,Xn=!0,hn=Ve.kNoChange,qn(),Xn=!1},ne.Test=function(){Xn=!0},ne.registEvent=Nn,ne.unRegistEvent=fn,ne.getCurrentMouseButton=function(){return xn},ne.isRunning=function(){return Lt!=null},ne.getCurCmd=function(){return Lt},ne.commandRunComplete=function(Pi){Lt!=Pi&&console.log("aseert:_curCmd == cmd");var oi,Ni,za=b.MxManager.currentMx();Lt!=null&&(za=Lt.getMxObject()),wn!=null?(Lt=wn,wn=void 0,xn=Tt.kInvalid,Nn(),Lt.onStartCommand(),un(za)):(fn(),Lt=void 0,Ni=(oi=za).getOrbitControls(),c.MxFun.isPC()?Si!=-2&&(Ni.mouseButtons.LEFT=Si,Si=-2,Ni.resetStatusValue()):(Ni.enabled=!0,Ni.resetStatusValue()),oi.callEvent("dragWillEnd"),oi.updateDisplay(),J.MxDrawData.m_isAutoResetRenderer||oi.resetRenderer())},ne.isWaitCmdNull=function(){return wn==null},ne.stopCmd=function(Pi){b.MxManager.currentMx().endPanCommand(),Lt!=null&&(ti=!0,Lt.notifyCancleExit(Pi),ti=!1)},ne.setRunCmdEvent=function(Pi){gn=Pi},ne.runCmd=function(Pi){if(!ti){var oi=b.MxManager.currentMx();Pi.setMxObject(oi),oi.isValidCurMousePostion()?Xr=oi.getCurrentMousePostion():c.MxFun.isPC()?(Xr.x=$n,Xr.y=$n):(Xr.x=.5*oi.getViewWidth(),Xr.y=.5*oi.getViewHeight()),gn&&gn(),Lt==null?(Lt=Pi,xn=Tt.kInvalid,Nn(),Lt.onStartCommand(),un(oi)):(wn=Pi,ti=!0,Lt.notifyCancleExit(Xe.kNewCommadIn),ti=!1)}},ne.GetAcqurePointFromStringTo=Ln,ne.ProcCommandRetResult=hi,ne.GetCommandLineContent=bi,ne.acquireKeyword=function(){var Pi=new ve;if(Lt==null)return Pi.status=Ae.kCancel,Pi.exit=!0,Pi;var oi=bi(tn.COMMAND_GET_STRING|tn.COMMAND_GET_KEY);return oi.iRet==It.COMMAND_IN_EMTPY?(Pi.status=Ae.kNull,Pi.exit=!0,Kn==13?Pi.DetailedResult=Xe.kNullEnterIn:Kn==32?Pi.DetailedResult=Xe.kNullSpaceIn:Kn==-1&&(Pi.DetailedResult=Xe.kMouseRightIn)):oi.iRet==It.COMMAND_IN_KEY?(Pi.status=oi.iKey,Pi.exit=!0,Pi.sKeyValue=oi.sValue,Pi.DetailedResult=Xe.kKeyIn):(oi.cmdText.length==0?Pi.status=Ae.kNoChange:Pi.status=hi(oi.iRet,`
- 需要输入关键字。
- `),Pi.exit=!1),Pi},ne.acquireString=function(){var Pi=new ve;if(Lt==null)return Pi.status=Ae.kCancel,Pi.exit=!0,Pi;var oi=bi(tn.COMMAND_GET_STRING|tn.COMMAND_GET_KEY);return oi.iRet==It.COMMAND_IN_EMTPY?(Pi.status=Ae.kNull,Pi.exit=!0,Kn==13?Pi.DetailedResult=Xe.kNullEnterIn:Kn==32?Pi.DetailedResult=Xe.kNullSpaceIn:Kn==-1&&(Pi.DetailedResult=Xe.kMouseRightIn)):oi.iRet==It.COMMAND_IN_KEY?(Pi.status=oi.iKey,Pi.exit=!0,Pi.sKeyValue=oi.sValue,Pi.DetailedResult=Xe.kKeyIn):oi.iRet==It.COMMAND_IN_STRING?(Pi.status=Ae.kNormal,Pi.sValue=oi.sValue,Pi.exit=!0,Pi.DetailedResult=Xe.kKeyIn):(Pi.status=hi(oi.iRet,`
- 需要输入非空字符串。
- `),Pi.exit=!1),Pi},ne.acquireInt=function(){var Pi=new ve;if(Lt==null)return Pi.status=Ae.kCancel,Pi.exit=!0,Pi;var oi=bi(tn.COMMAND_GET_INT|tn.COMMAND_GET_KEY);return oi.iRet==It.COMMAND_IN_EMTPY?(Pi.status=Ae.kNull,Pi.exit=!0,Kn==13?Pi.DetailedResult=Xe.kNullEnterIn:Kn==32?Pi.DetailedResult=Xe.kNullSpaceIn:Kn==-1&&(Pi.DetailedResult=Xe.kMouseRightIn)):oi.iRet==It.COMMAND_IN_KEY?(Pi.status=oi.iKey,Pi.exit=!0,Pi.sKeyValue=oi.sValue,Pi.DetailedResult=Xe.kKeyIn):oi.iRet==It.COMMAND_IN_INT?(Pi.status=Ae.kNormal,Pi.iVal=oi.iVal,Pi.exit=!0,Pi.DetailedResult=Xe.kKeyIn):(Pi.status=hi(oi.iRet,`
- 需要整数或选项关键字。
- `),Pi.exit=!1),Pi},ne.acquireDist=function(Pi,oi){var Ni=new ve;if(Lt==null)return Ni.status=Ae.kCancel,Ni.exit=!0,Ni;var za=bi(tn.COMMAND_GET_DIST|tn.COMMAND_GET_KEY);if(za.iRet==It.COMMAND_IN_EMTPY)return Ni.status=Ae.kNull,Ni.exit=!0,Kn==13?Ni.DetailedResult=Xe.kNullEnterIn:Kn==32?Ni.DetailedResult=Xe.kNullSpaceIn:Kn==-1&&(Ni.DetailedResult=Xe.kMouseRightIn),Ni;if(za.iRet==It.COMMAND_IN_KEY)return Ni.status=za.iKey,Ni.exit=!0,Ni.sKeyValue=za.sValue,Ni.DetailedResult=Xe.kKeyIn,Ni;if(za.iRet==It.COMMAND_IN_DIST)return Ni.status=Ae.kNormal,Ni.dist=za.dDist,Ni.exit=!0,Ni.DetailedResult=Xe.kCoordIn,Ni;if(Ni.status=hi(za.iRet,`
- 需要点或选项关键字。
- `),!oi||za.iRet==It.COMMAND_IN_INVALID_ZERO||za.iRet==It.COMMAND_IN_INVALID_NEG)return Ni.exit=!1,Ni;var ki=so(Pi);if(ki.status==Ae.kNormal&&ki.exit){var Aa=ki.pt.clone(),Ja=oi.clone();Aa.z=Ja.z=0;var yo=Aa.distanceTo(Ja);return Lt.userInputControls()&Ue.kNoZeroResponseAccepted&&L.MxTools.IsZero(yo)?(hi(It.COMMAND_IN_INVALID_ZERO,`
- 需要点或选项关键字。
- `),Ni.status=Ae.kOther,Ni.exit=!1,Ni):(Ni.status=Ae.kNormal,Ni.dist=yo,Ni.exit=!0,Ni.DetailedResult=ki.DetailedResult,Ni)}return Ni.exit=!1,Ni.status=Ae.kNoChange,Ni},ne.acquirePoint=function(Pi,oi){oi===void 0&&(oi=!0);var Ni=new ve;if(Lt==null)return Ni.status=Ae.kCancel,Ni;var za=bi(tn.COMMAND_GET_COORD|tn.COMMAND_GET_KEY);return za.iRet==It.COMMAND_IN_EMTPY?(Ni.status=Ae.kNull,Ni.exit=!0,Kn==13?Ni.DetailedResult=Xe.kNullEnterIn:Kn==32?Ni.DetailedResult=Xe.kNullSpaceIn:Kn==-1&&(Ni.DetailedResult=Xe.kMouseRightIn),Ni):za.iRet==It.COMMAND_IN_KEY?(Ni.status=za.iKey,Ni.exit=!0,Ni.sKeyValue=za.sValue,Ni.DetailedResult=Xe.kKeyIn,Ni):za.iRet==It.COMMAND_IN_COORD?(Ni.status=Ae.kNormal,Ni.pt=new u.Vector3(za.pt.x,za.pt.y,za.pt.z),Ni.exit=!0,Ni.DetailedResult=Xe.kCoordIn,Ni):(oi&&hi(za.iRet,`
- 需要点或选项关键字。
- `),so(Pi))},ne.acquireAngle=function(Pi,oi){var Ni=new ve;if(Lt==null)return Ni.status=Ae.kCancel,Ni.exit=!0,Ni;var za=bi(tn.COMMAND_GET_DIST|tn.COMMAND_GET_KEY);if(za.iRet==It.COMMAND_IN_EMTPY)return Ni.status=Ae.kNull,Ni.exit=!0,Kn==13?Ni.DetailedResult=Xe.kNullEnterIn:Kn==32?Ni.DetailedResult=Xe.kNullSpaceIn:Kn==-1&&(Ni.DetailedResult=Xe.kMouseRightIn),Ni;if(za.iRet==It.COMMAND_IN_KEY)return Ni.status=za.iKey,Ni.exit=!0,Ni.sKeyValue=za.sValue,Ni.DetailedResult=Xe.kKeyIn,Ni;if(za.iRet==It.COMMAND_IN_DIST)return Ni.status=Ae.kNormal,Ni.ang=3.14159265*za.dDist/180,Ni.exit=!0,Ni.DetailedResult=Xe.kCoordIn,Ni;if(Ni.status=hi(za.iRet,`
- 需要点或选项关键字。
- `),!oi||za.iRet==It.COMMAND_IN_INVALID_ZERO||za.iRet==It.COMMAND_IN_INVALID_NEG)return Ni.exit=!1,Ni;var ki=so(Pi);if(ki.status==Ae.kNormal&&ki.exit){var Aa=new u.Vector3(ki.pt.x-oi.x,ki.pt.y-oi.y,0),Ja=Aa.angleTo(new u.Vector3(1,0,0));Aa.dot(new u.Vector3(0,1,0))<-1e-11&&(Ja=2*Math.PI-Ja);var yo=Lt.userInputControls();return yo&Ue.kNoZeroResponseAccepted&&L.MxTools.IsZero(Ja)?(hi(It.COMMAND_IN_INVALID_ZERO,`
- 需要点或选项关键字。
- `),Ni.status=Ae.kOther,Ni.exit=!1,Ni):(yo&Ue.kNoNegativeResponseAccepted&&Ja<0?(hi(It.COMMAND_IN_INVALID_NEG,`
- 需要点或选项关键字。
- `),Ni.status=Ae.kOther,Ni.exit=!1):(Ni.status=Ae.kNormal,Ni.ang=Ja,Ni.exit=!0,Ni.DetailedResult=ki.DetailedResult),Ni)}return Ni.exit=!1,Ni.status=Ae.kNoChange,Ni},ne.getMcEdJigCommandClass=function(){return y.McEdJigCommand},ne.getMrxDbgUiPrPointClass=function(){return m.MrxDbgUiPrPoint},ne.getMrxDbgUiPrDistClass=function(){return fe.MrxDbgUiPrDist},ne.getMrxDbgUiPrIntClass=function(){return fe.MrxDbgUiPrInt},ne.getMrxDbgUiPrStringClass=function(){return fe.MrxDbgUiPrString},ne.getMrxDbgUiPrKeyWordClass=function(){return fe.MrxDbgUiPrKeyWord},ne.getMrxDbgUiPrAngleClass=function(){return fe.MrxDbgUiPrAngle},ne.getMcEdGetPointWorldDrawClass=function(){return O.McEdGetPointWorldDraw},ne.McEdGetPointWorldDrawObjectClass=function(){return O.McEdGetPointWorldDrawObject},ne.init=function(){this._curCmd=void 0}}(n=l.MxJigCmdManager||(l.MxJigCmdManager={}))},{"../MxDrawData":22,"../MxFun":27,"../MxManager":29,"../MxString":34,"../MxTools":38,"../UI/MxUiVue":65,"./McEdJigOsnap":43,"./MrxDbgUiPrBase":45,"./MrxDbgUiPrDist":46,"./MrxDbgUiPrPoint":47,"./MxJig":53,three:19}],55:[function(t,e,l){var n,u=this&&this.__extends||(n=function(N,L){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(G,q){G.__proto__=q}||function(G,q){for(var J in q)Object.prototype.hasOwnProperty.call(q,J)&&(G[J]=q[J])})(N,L)},function(N,L){function G(){this.constructor=N}n(N,L),N.prototype=L===null?Object.create(L):(G.prototype=L.prototype,new G)});Object.defineProperty(l,"__esModule",{value:!0}),l.MxJigGetLine=void 0;var c,y=t("./MxJig"),b=t("./MxJigCmdManager"),m=(u(O,c=y.McEdJigCommand),O.prototype.sampler=function(){var N=b.MxJigCmdManager.InType.kGetBegan;this._isGetPt1||(N=b.MxJigCmdManager.InType.kGetEnd);var L=this.acquirePoint(N);return L.status==b.MxJigCmdManager.DragStatus.kNormal&&(this._isGetPt1?this._pt1=L.pt:this._pt2=L.pt),L.status},O.prototype.setRetCall=function(N){this._retCall=N},O.prototype.done=function(N){if(this._isGetPt1)return this._isGetPt1=!1,b.MxJigCmdManager.DoneStatius.kContinueCommand;var L={};return L.pt1=this.getMxObject().worldCoord2Currnet(this._pt1.x,this._pt1.y,this._pt1.z),L.pt2=this.getMxObject().worldCoord2Currnet(this._pt2.x,this._pt2.y,this._pt2.z),this._retCall(L),b.MxJigCmdManager.DoneStatius.kExitCommand},O.prototype.upDisplay=function(){this._isGetPt1||this._pt1==null||this._pt2==null||this.drawLine(this._pt1,this._pt2)},O);function O(){var N=c!==null&&c.apply(this,arguments)||this;return N._isGetPt1=!0,N}l.MxJigGetLine=m},{"./MxJig":53,"./MxJigCmdManager":54}],56:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxOffsetArrow=void 0;var n=t("three"),u=t("../MxFun"),c=t("../MxThreeJS"),y=t("../MxTools"),b=(m.prototype.ClearDynDrawEntity=function(){var O=this.m_vecDynDrawEntity.length;if(O!=0){for(var N=this.m_mxJig.getMxObject().getTheTempDrawContainer_SmallCoord(),L=0;L<O;L++)u.MxFun.removeThreejsObject(this.m_vecDynDrawEntity[L],N);this.m_vecDynDrawEntity=[]}},m.prototype.MouseMove=function(O){var N=this.m_mxJig.getMxObject();if(N.getMcObject().isValid()&&(this.ClearDynDrawEntity(),this.m_mxJig.isOffsetInputPostion())){var L=O.clone(),G=this.m_mxJig.getOsnap().reCompteCurrentPoint(L.clone()),q=c.MxThreeJS.createLine(N.toSmallcoord(L),N.toSmallcoord(G),16777215),J=N.getTheTempDrawContainer_SmallCoord();J.add(q),this.m_vecDynDrawEntity.push(q);var fe=y.MxTools.MillimeterToPixels(2.9);fe=N.screenCoordLong2Doc(fe);var ve=c.MxThreeJS.createSolidCircle(N.toSmallcoord(L),.85*fe,16777215);J.add(ve),this.m_vecDynDrawEntity.push(ve);var ne=c.MxThreeJS.createCircle(N.toSmallcoord(L),fe,16777215);J.add(ne),this.m_vecDynDrawEntity.push(ne);var Ue=L.sub(G);Ue.normalize().multiplyScalar(.8*fe);var De=Ue.clone().applyAxisAngle(new n.Vector3(0,0,1),15*Math.PI/180),Ve=Ue.clone().applyAxisAngle(new n.Vector3(0,0,1),15*-Math.PI/180),rt=G.clone().add(De),Ae=G.clone().add(Ve),Te=c.MxThreeJS.createLine(N.toSmallcoord(rt),N.toSmallcoord(G),16777215);N.getTheTempDrawContainer_SmallCoord().add(Te),this.m_vecDynDrawEntity.push(Te);var Xe=c.MxThreeJS.createLine(N.toSmallcoord(Ae),N.toSmallcoord(G),16777215);N.getTheTempDrawContainer_SmallCoord().add(Xe),this.m_vecDynDrawEntity.push(Xe)}},m.prototype.ClearDisplay=function(){this.ClearDynDrawEntity()},m.prototype.ReSetTempDisplay=function(){this.ClearDynDrawEntity()},m.prototype.Init=function(){},m);function m(O){this.m_vecDynDrawEntity=[],this.m_mxJig=null,this.m_mxJig=O}l.MxOffsetArrow=b},{"../MxFun":27,"../MxThreeJS":37,"../MxTools":38,three:19}],57:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxPolarAxisTrace=void 0;var n=t("three"),u=t("./MxJigCmdManager"),c=t("../MxFun"),y=t("../MxDrawData"),b=t("../MxTools"),m=t("../MxManager"),O=t("../MxThreeJS"),N=(L.prototype.ClearDynDrawEntity=function(){for(var G=this.m_mxJig.getMxObject().getTheTempDrawContainer_SmallCoord(),q=this.m_vecDynDrawEntity.length,J=0;J<q;J++)c.MxFun.removeThreejsObject(this.m_vecDynDrawEntity[J],G);this.m_vecDynDrawEntity=[]},L.prototype.CreteTracePoint=function(G,q){var J=this.m_mxJig.getMxObject(),fe=J.getTheTempDrawContainer_SmallCoord();q/=2;var ve=O.MxThreeJS.createLine(J.toSmallcoord2(G.x+q,G.y+q,0),J.toSmallcoord2(G.x-q,G.y-q,0),16711680);fe.add(ve),this.m_vecDynDrawEntity.push(ve);var ne=O.MxThreeJS.createLine(J.toSmallcoord2(G.x-q,G.y+q,0),J.toSmallcoord2(G.x+q,G.y-q,0),16711680);fe.add(ne),this.m_vecDynDrawEntity.push(ne)},L.prototype.MouseMove=function(G){var q=this.m_mxJig.getMxObject();if(q.getMcObject().isValid()){if(this.ClearDynDrawEntity(),this.m_isValidTracePoint=!1,this.m_isTrace&&q.sysVariable().getSysVarNumber("GETPOINTSTATUS")&u.MxJigCmdManager.GETPOINTSTATUS.OsModeSValidLastPoint){var J=q.sysVariable().getSysVarPoint("LASTPOINT"),fe=q.getSysVarDouble("POLARANG");if(fe=180*fe/Math.PI,!((fe=Math.abs(fe))<.001)){var ve=q.viewCoordLong2Cad(y.MxDrawData.m_dInputRectWidth),ne=2*ve,Ue=G.clone().sub(J);if(!(Ue.length()<ne)){Ue.normalize();var De=m.MxManager.getMxCpp().getMxCAD_MxCpp(),Ve=m.MxManager.getMxCpp().getMxCAD_App(),rt=q.getTheTempDrawContainer_SmallCoord(),Ae=q.viewCoordLong2Cad(this.m_dashedLineLen);Ue=De.newMcGeVector3d(Ue);var Te=De.newMcGeVector3d(new n.Vector3(1,0,0)),Xe=Ue.angleTo2(Te),ie=(Xe=180*Xe/Math.PI)%fe;ie<fe/2?Xe-=ie:Xe+=fe-ie;var ue=q.viewCoordLong2Cad(q.getViewWidth()),pt=q.viewCoordLong2Cad(q.getViewHeight()),mt=b.MxTools.MxMax(ue,pt);(Ue=Te.clone()).rotateBy(Xe*Math.PI/180),Ue.mult(mt);var Tt=new n.Vector3(J.x+Ue.x,J.y+Ue.y,J.z+Ue.z),kt={pt1:Tt,pt2:J},It=Ve.MxCADAssist.GetClosestPointTo(kt.pt1.x,kt.pt1.y,kt.pt2.x,kt.pt2.y,G.x,G.y,!0);if(0<It.length()){var nn=It.at(0),tn=new n.Vector3(nn.x,nn.y,nn.z);if(tn.distanceTo(G)<ne){var pn=O.MxThreeJS.createDashedLine(q.toSmallcoord2(J.x-Ue.x,J.y-Ue.y,J.z-Ue.z),q.toSmallcoord(Tt),this.m_iDashedLineLenColor,Ae,Ae);rt.add(pn),this.m_vecDynDrawEntity.push(pn),this.m_isValidTracePoint=!0,this.m_ptTracePoint=tn,this.CreteTracePoint(tn,ve)}}}}}}else this.m_isTrace=!1},L.prototype.Init=function(){var G=this.m_mxJig.getMxObject();G.getMcObject().isValid()?(this.m_isValidTracePoint=!1,this.m_isTrace=!1,8&G.getSysVarLong("AUTOSNAP")&&(this.m_isTrace=!0),G.sysVariable().getSysVarNumber("GETPOINTSTATUS")&u.MxJigCmdManager.GETPOINTSTATUS.OsModePoloarTempDisable&&(this.m_isTrace=!1),this.m_mxJig.isDisablePolarAxisTrace()&&(this.m_isTrace=!1),this.m_isTrace):this.m_isTrace=!1},L.prototype.GetTracePoint=function(){if(this.m_isTrace)return this.m_isValidTracePoint?this.m_ptTracePoint:void 0},L.prototype.ClearDisplay=function(){this.ClearDynDrawEntity()},L.prototype.ReSetTempDisplay=function(){this.ClearDynDrawEntity(),this.m_isValidTracePoint=!1},L);function L(G){this.m_vecDynDrawEntity=[],this.m_ptTracePoint=new n.Vector3,this.m_isValidTracePoint=!1,this.m_isTrace=!1,this.m_mxJig=null,this.m_dashedLineLen=1.5,this.m_iDashedLineLenColor=11184810,this.m_mxJig=G}l.MxPolarAxisTrace=N},{"../MxDrawData":22,"../MxFun":27,"../MxManager":29,"../MxThreeJS":37,"../MxTools":38,"./MxJigCmdManager":54,three:19}],58:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0});var n=t("./MxFun");window.MXFUN_THREE=n.MxFun.getTHREE();var u=t("./MxManager");function c(){}(c.CreateMx=function(){n.MxFun.init(),typeof MxMain<"u"&&MxMain(t)==0||n.MxFun.createMxObject(),u.MxManager.callEvent("init");var y=n.MxFun.getUiObject();y!=null&&(y.sTitle=n.MxFun.getCurrentDraw().getFileTitle(),setTimeout(function(){y.init()},400))},c.Main=function(){if(typeof MxUiMain<"u"){MxUiMain(t);var y=n.MxFun.getUiObject();y?.writeUICSS()}typeof MxDocumentReady>"u"?$(document).ready(function(){c.CreateMx()}):MxDocumentReady(t,c.CreateMx)},c).Main()},{"./MxFun":27,"./MxManager":29}],59:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxSvgManager=void 0;var n=t("three"),u=t("three"),c=t("./SVGLoader"),y=function(){this.svg=new n.Group,this.aryMeterial=[],this.boxSize=new u.Vector3(1,1,1)},b=(m.prototype.loadSVGImp=function(L,G,q,J){new c.SVGLoader().load(L,function(fe){if(fe.paths.length){var ve=[],ne=fe.paths,Ue=new n.Group,De=!0,Ve=!0,rt=!1,Ae=!1;J&&(J.drawStrokes&&(De=J.drawStrokes),J.drawFillShapes&&(Ve=J.drawFillShapes),J.fillShapesWireframe&&(rt=J.fillShapesWireframe),J.strokesWireframe&&(Ae=J.strokesWireframe));for(var Te=0;Te<ne.length;Te++){var Xe=ne[Te],ie=Xe.userData.style.fill;if(Ve&&ie!==void 0&&ie!=="none"){for(var ue=new n.MeshBasicMaterial({color:G||new n.Color().setStyle(ie),opacity:Xe.userData.style.fillOpacity,transparent:Xe.userData.style.fillOpacity<1,side:n.DoubleSide,depthWrite:!1,wireframe:rt}),pt=c.SVGLoader.createShapes(Xe),mt=0;mt<pt.length;mt++){var Tt=pt[mt],kt=new n.ShapeBufferGeometry(Tt),It=new n.Mesh(kt,ue);Ue.add(It)}ve.push(ue)}var nn=Xe.userData.style.stroke;if(De&&nn!==void 0&&nn!=="none"){ue=new n.MeshBasicMaterial({color:G||new n.Color().setStyle(nn),opacity:Xe.userData.style.strokeOpacity,transparent:Xe.userData.style.strokeOpacity<1,side:n.DoubleSide,depthWrite:!1,wireframe:Ae}),mt=0;for(var tn=Xe.subPaths.length;mt<tn;mt++){var pn=Xe.subPaths[mt];(kt=c.SVGLoader.pointsToStroke(pn.getPoints(),Xe.userData.style,12,.001))&&(It=new n.Mesh(kt,ue),Ue.add(It))}ve.push(ue)}}q&&q(Ue,ve)}else console.log("mx svg:"+L+" data.paths.length == 0"),q&&q(null,null)},void 0,function(){q&&q(null,null)})},m.prototype.loadSVG=function(L,G,q,J){var fe=this,ve=this.mapSvgUrlToData.get(L),ne=!J||!J.useBuffer||J.useBuffer;if(ve&&ne){if(q)if(ve==null)q(null,null);else{var Ue=ve.svg.clone();Ue.boxSize=ve.boxSize,q(Ue,ve.aryMeterial)}}else this.loadSVGImp(L,G,function(De,Ve){if(De&&Ve){var rt=new y;rt.svg=De,rt.aryMeterial=Ve;var Ae=new u.Box3().setFromObject(De);rt.boxSize.x=Ae.max.x-Ae.min.x,rt.boxSize.y=Ae.max.y-Ae.min.y,rt.boxSize.x!==-1/0&&rt.boxSize.y!==-1/0||console.log("mx svg:"+L+" boxSize invalid"),fe.mapSvgUrlToData.set(L,rt);var Te=rt.svg.clone();Te.boxSize=rt.boxSize,q&&q(Te,rt.aryMeterial)}else fe.mapSvgUrlToData.set(L,null),q&&q(null,null)},J)},m);function m(){this.mapSvgUrlToData=new Map}var O=(N.prototype.loadSVG=function(L,G,q,J){q&&this.mxThreeJsBuffer.loadSVG(L,G,q,J)},N);function N(){this.mxThreeJsBuffer=new b}l.MxSvgManager=O},{"./SVGLoader":60,three:19}],60:[function(t,e,l){var n,u=this&&this.__extends||(n=function(O,N){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(L,G){L.__proto__=G}||function(L,G){for(var q in G)Object.prototype.hasOwnProperty.call(G,q)&&(L[q]=G[q])})(O,N)},function(O,N){function L(){this.constructor=O}n(O,N),O.prototype=N===null?Object.create(N):(L.prototype=N.prototype,new L)});Object.defineProperty(l,"__esModule",{value:!0}),l.SVGLoader=void 0;var c,y=t("three"),b=(u(m,c=y.Loader),m.prototype.load=function(O,N,L,G){var q=this,J=new y.FileLoader(q.manager);J.setPath(q.path),J.setRequestHeader(q.requestHeader),J.setWithCredentials(q.withCredentials),J.load(O,function(fe){try{N(q.parse(fe))}catch(ve){G?G(ve):console.error(ve),q.manager.itemError(O)}},L,G)},m.prototype.parse=function(O){var N=this;function L(kt,It,nn,tn,pn,_n,Dn,an){if(It!=0&&nn!=0){tn=tn*Math.PI/180,It=Math.abs(It),nn=Math.abs(nn);var Rn=(Dn.x-an.x)/2,Lt=(Dn.y-an.y)/2,wn=Math.cos(tn)*Rn+Math.sin(tn)*Lt,hn=-Math.sin(tn)*Rn+Math.cos(tn)*Lt,xn=It*It,$n=nn*nn,Xr=wn*wn,ti=hn*hn,gn=Xr/xn+ti/$n;if(1<gn){var Xn=Math.sqrt(gn);xn=(It*=Xn)*It,$n=(nn*=Xn)*nn}var Kn=xn*ti+$n*Xr,Vn=(xn*$n-Kn)/Kn,Yn=Math.sqrt(Math.max(0,Vn));pn===_n&&(Yn=-Yn);var Vr=Yn*It*hn/nn,xi=-Yn*nn*wn/It,Si=Math.cos(tn)*Vr-Math.sin(tn)*xi+(Dn.x+an.x)/2,qn=Math.sin(tn)*Vr+Math.cos(tn)*xi+(Dn.y+an.y)/2,ia=G(1,0,(wn-Vr)/It,(hn-xi)/nn),Wi=G((wn-Vr)/It,(hn-xi)/nn,(-wn-Vr)/It,(-hn-xi)/nn)%(2*Math.PI);kt.currentPath.absellipse(Si,qn,It,nn,ia,ia+Wi,_n===0,tn)}else kt.lineTo(an.x,an.y)}function G(kt,It,nn,tn){var pn=kt*nn+It*tn,_n=Math.sqrt(kt*kt+It*It)*Math.sqrt(nn*nn+tn*tn),Dn=Math.acos(Math.max(-1,Math.min(1,pn/_n)));return kt*tn-It*nn<0&&(Dn=-Dn),Dn}function q(kt,It){It=Object.assign({},It);var nn={};if(kt.hasAttribute("class"))for(var tn=kt.getAttribute("class").split(/\s/).filter(Boolean).map(function(Rn){return Rn.trim()}),pn=0;pn<tn.length;pn++)nn=Object.assign(nn,Ve["."+tn[pn]]);function _n(Rn,Lt,wn){wn===void 0&&(wn=function(hn){return hn.startsWith("url")&&console.warn("SVGLoader: url access in attributes is not implemented."),hn}),kt.hasAttribute(Rn)&&(It[Lt]=wn(kt.getAttribute(Rn))),nn[Rn]&&(It[Lt]=wn(nn[Rn])),kt.style&&kt.style[Rn]!==""&&(It[Lt]=wn(kt.style[Rn]))}function Dn(Rn){return Math.max(0,Math.min(1,Ue(Rn)))}function an(Rn){return Math.max(0,Ue(Rn))}return kt.hasAttribute("id")&&(nn=Object.assign(nn,Ve["#"+kt.getAttribute("id")])),_n("fill","fill"),_n("fill-opacity","fillOpacity",Dn),_n("fill-rule","fillRule"),_n("opacity","opacity",Dn),_n("stroke","stroke"),_n("stroke-opacity","strokeOpacity",Dn),_n("stroke-width","strokeWidth",an),_n("stroke-linejoin","strokeLineJoin"),_n("stroke-linecap","strokeLineCap"),_n("stroke-miterlimit","strokeMiterLimit",an),_n("visibility","visibility"),It}function J(kt,It){return kt-(It-kt)}function fe(kt,It,nn){if(typeof kt!="string")throw new TypeError("Invalid input: "+typeof kt);var tn,pn={SEPARATOR:/[ \t\r\n\,.\-+]/,WHITESPACE:/[ \t\r\n]/,DIGIT:/[\d]/,SIGN:/[-+]/,POINT:/\./,COMMA:/,/,EXP:/e/i,FLAGS:/[01]/},_n=0,Dn=!0,an="",Rn="",Lt=[];function wn(Xr,ti,gn){var Xn=new SyntaxError('Unexpected character "'+Xr+'" at index '+ti+".");throw Xn.partial=gn,Xn}function hn(){an!==""&&(Rn===""?Lt.push(Number(an)):Lt.push(Number(an)*Math.pow(10,Number(Rn)))),Rn=an=""}for(var xn=kt.length,$n=0;$n<xn;$n++)if(tn=kt[$n],Array.isArray(It)&&It.includes(Lt.length%nn)&&pn.FLAGS.test(tn))_n=1,an=tn,hn();else{if(_n===0){if(pn.WHITESPACE.test(tn))continue;if(pn.DIGIT.test(tn)||pn.SIGN.test(tn)){_n=1,an=tn;continue}if(pn.POINT.test(tn)){_n=2,an=tn;continue}pn.COMMA.test(tn)&&(Dn&&wn(tn,$n,Lt),Dn=!0)}if(_n===1){if(pn.DIGIT.test(tn)){an+=tn;continue}if(pn.POINT.test(tn)){an+=tn,_n=2;continue}if(pn.EXP.test(tn)){_n=3;continue}pn.SIGN.test(tn)&&an.length===1&&pn.SIGN.test(an[0])&&wn(tn,$n,Lt)}if(_n===2){if(pn.DIGIT.test(tn)){an+=tn;continue}if(pn.EXP.test(tn)){_n=3;continue}pn.POINT.test(tn)&&an[an.length-1]==="."&&wn(tn,$n,Lt)}if(_n===3){if(pn.DIGIT.test(tn)){Rn+=tn;continue}if(pn.SIGN.test(tn)){if(Rn===""){Rn+=tn;continue}Rn.length===1&&pn.SIGN.test(Rn)&&wn(tn,$n,Lt)}}pn.WHITESPACE.test(tn)?(hn(),_n=0,Dn=!1):pn.COMMA.test(tn)?(hn(),Dn=!(_n=0)):pn.SIGN.test(tn)?(hn(),_n=1,an=tn):pn.POINT.test(tn)?(hn(),_n=2,an=tn):wn(tn,$n,Lt)}return hn(),Lt}var ve=["mm","cm","in","pt","pc","px"],ne={mm:{mm:1,cm:.1,in:1/25.4,pt:72/25.4,pc:6/25.4,px:-1},cm:{mm:10,cm:1,in:1/2.54,pt:72/2.54,pc:6/2.54,px:-1},in:{mm:25.4,cm:2.54,in:1,pt:72,pc:6,px:-1},pt:{mm:25.4/72,cm:2.54/72,in:1/72,pt:1,pc:6/72,px:-1},pc:{mm:25.4/6,cm:2.54/6,in:1/6,pt:12,pc:1,px:-1},px:{px:1}};function Ue(kt){var It="px";if(typeof kt=="string"||kt instanceof String)for(var nn=0,tn=ve.length;nn<tn;nn++){var pn=ve[nn];if(kt.endsWith(pn)){It=pn,kt=kt.substring(0,kt.length-pn.length);break}}var _n=void 0;return It==="px"&&N.defaultUnit!=="px"?_n=ne.in[N.defaultUnit]/N.defaultDPI:(_n=ne[It][N.defaultUnit])<0&&(_n=ne[It].in*N.defaultDPI),_n*parseFloat(kt)}var De=[],Ve={},rt=[],Ae=new y.Matrix3,Te=new y.Matrix3,Xe=new y.Matrix3,ie=new y.Matrix3,ue=new y.Vector2,pt=new y.Vector3,mt=new y.Matrix3,Tt=new DOMParser().parseFromString(O,"image/svg+xml");return function kt(It,nn){if(It.nodeType===1){var tn,pn,_n,Dn,an,Rn,Lt,wn,hn,xn,$n,Xr,ti=function(xi){if(!(xi.hasAttribute("transform")||xi.nodeName==="use"&&(xi.hasAttribute("x")||xi.hasAttribute("y"))))return null;var Si=function(qn){var ia=new y.Matrix3,Wi=Ae;if(qn.nodeName==="use"&&(qn.hasAttribute("x")||qn.hasAttribute("y"))){var ha=Ue(qn.getAttribute("x")),ai=Ue(qn.getAttribute("y"));ia.translate(ha,ai)}if(qn.hasAttribute("transform"))for(var Ia=qn.getAttribute("transform").split(")"),fi=Ia.length-1;0<=fi;fi--){var An=Ia[fi].trim();if(An!==""){var sa=An.indexOf("("),Nn=An.length;if(0<sa&&sa<Nn){var fn=An.substr(0,sa),un=fe(An.substr(sa+1,Nn-sa-1));switch(Wi.identity(),fn){case"translate":1<=un.length&&(ai=ha=un[0],2<=un.length&&(ai=un[1]),Wi.translate(ha,ai));break;case"rotate":if(1<=un.length){var Ln,hr=0,hi=0;Ln=-un[0]*Math.PI/180,3<=un.length&&(hr=un[1],hi=un[2]),Te.identity().translate(-hr,-hi),Xe.identity().rotate(Ln),ie.multiplyMatrices(Xe,Te),Te.identity().translate(hr,hi),Wi.multiplyMatrices(Te,ie)}break;case"scale":if(1<=un.length){var bi=un[0],Ra=bi;2<=un.length&&(Ra=un[1]),Wi.scale(bi,Ra)}break;case"skewX":un.length===1&&Wi.set(1,Math.tan(un[0]*Math.PI/180),0,0,1,0,0,0,1);break;case"skewY":un.length===1&&Wi.set(1,0,0,Math.tan(un[0]*Math.PI/180),1,0,0,0,1);break;case"matrix":un.length===6&&Wi.set(un[0],un[2],un[4],un[1],un[3],un[5],0,0,1)}}ia.premultiply(Wi)}}return ia}(xi);return 0<rt.length&&Si.premultiply(rt[rt.length-1]),mt.copy(Si),rt.push(Si),Si}(It),gn=!0,Xn=null;switch(It.nodeName){case"svg":break;case"style":(function(xi){if(xi.sheet&&xi.sheet.cssRules&&xi.sheet.cssRules.length)for(var Si=0;Si<xi.sheet.cssRules.length;Si++){var qn=xi.sheet.cssRules[Si];if(qn.type===1)for(var ia=qn.selectorText.split(/,/gm).filter(Boolean).map(function(ha){return ha.trim()}),Wi=0;Wi<ia.length;Wi++)Ve[ia[Wi]]=Object.assign(Ve[ia[Wi]]||{},qn.style)}})(It);break;case"g":nn=q(It,nn);break;case"path":nn=q(It,nn),It.hasAttribute("d")&&(Xn=function(xi){for(var Si=new y.ShapePath,qn=new y.Vector2,ia=new y.Vector2,Wi=new y.Vector2,ha=!0,ai=!1,Ia=xi.getAttribute("d").match(/[a-df-z][^a-df-z]*/gi),fi=0,An=Ia.length;fi<An;fi++){var sa=Ia[fi],Nn=sa.charAt(0),fn=sa.substr(1).trim();ha===!0&&(ha=!(ai=!0));var un=void 0;switch(Nn){case"M":for(var Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln+=2)qn.x=un[Ln+0],qn.y=un[Ln+1],ia.x=qn.x,ia.y=qn.y,Ln===0?Si.moveTo(qn.x,qn.y):Si.lineTo(qn.x,qn.y),Ln===0&&Wi.copy(qn);break;case"H":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln++)qn.x=un[Ln],ia.x=qn.x,ia.y=qn.y,Si.lineTo(qn.x,qn.y),Ln===0&&ai===!0&&Wi.copy(qn);break;case"V":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln++)qn.y=un[Ln],ia.x=qn.x,ia.y=qn.y,Si.lineTo(qn.x,qn.y),Ln===0&&ai===!0&&Wi.copy(qn);break;case"L":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln+=2)qn.x=un[Ln+0],qn.y=un[Ln+1],ia.x=qn.x,ia.y=qn.y,Si.lineTo(qn.x,qn.y),Ln===0&&ai===!0&&Wi.copy(qn);break;case"C":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln+=6)Si.bezierCurveTo(un[Ln+0],un[Ln+1],un[Ln+2],un[Ln+3],un[Ln+4],un[Ln+5]),ia.x=un[Ln+2],ia.y=un[Ln+3],qn.x=un[Ln+4],qn.y=un[Ln+5],Ln===0&&ai===!0&&Wi.copy(qn);break;case"S":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln+=4)Si.bezierCurveTo(J(qn.x,ia.x),J(qn.y,ia.y),un[Ln+0],un[Ln+1],un[Ln+2],un[Ln+3]),ia.x=un[Ln+0],ia.y=un[Ln+1],qn.x=un[Ln+2],qn.y=un[Ln+3],Ln===0&&ai===!0&&Wi.copy(qn);break;case"Q":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln+=4)Si.quadraticCurveTo(un[Ln+0],un[Ln+1],un[Ln+2],un[Ln+3]),ia.x=un[Ln+0],ia.y=un[Ln+1],qn.x=un[Ln+2],qn.y=un[Ln+3],Ln===0&&ai===!0&&Wi.copy(qn);break;case"T":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln+=2){var hi=J(qn.x,ia.x),bi=J(qn.y,ia.y);Si.quadraticCurveTo(hi,bi,un[Ln+0],un[Ln+1]),ia.x=hi,ia.y=bi,qn.x=un[Ln+0],qn.y=un[Ln+1],Ln===0&&ai===!0&&Wi.copy(qn)}break;case"A":for(Ln=0,hr=(un=fe(fn,[3,4],7)).length;Ln<hr;Ln+=7)if(un[Ln+5]!=qn.x||un[Ln+6]!=qn.y){var Ra=qn.clone();qn.x=un[Ln+5],qn.y=un[Ln+6],ia.x=qn.x,ia.y=qn.y,L(Si,un[Ln],un[Ln+1],un[Ln+2],un[Ln+3],un[Ln+4],Ra,qn),Ln===0&&ai===!0&&Wi.copy(qn)}break;case"m":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln+=2)qn.x+=un[Ln+0],qn.y+=un[Ln+1],ia.x=qn.x,ia.y=qn.y,Ln===0?Si.moveTo(qn.x,qn.y):Si.lineTo(qn.x,qn.y),Ln===0&&Wi.copy(qn);break;case"h":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln++)qn.x+=un[Ln],ia.x=qn.x,ia.y=qn.y,Si.lineTo(qn.x,qn.y),Ln===0&&ai===!0&&Wi.copy(qn);break;case"v":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln++)qn.y+=un[Ln],ia.x=qn.x,ia.y=qn.y,Si.lineTo(qn.x,qn.y),Ln===0&&ai===!0&&Wi.copy(qn);break;case"l":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln+=2)qn.x+=un[Ln+0],qn.y+=un[Ln+1],ia.x=qn.x,ia.y=qn.y,Si.lineTo(qn.x,qn.y),Ln===0&&ai===!0&&Wi.copy(qn);break;case"c":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln+=6)Si.bezierCurveTo(qn.x+un[Ln+0],qn.y+un[Ln+1],qn.x+un[Ln+2],qn.y+un[Ln+3],qn.x+un[Ln+4],qn.y+un[Ln+5]),ia.x=qn.x+un[Ln+2],ia.y=qn.y+un[Ln+3],qn.x+=un[Ln+4],qn.y+=un[Ln+5],Ln===0&&ai===!0&&Wi.copy(qn);break;case"s":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln+=4)Si.bezierCurveTo(J(qn.x,ia.x),J(qn.y,ia.y),qn.x+un[Ln+0],qn.y+un[Ln+1],qn.x+un[Ln+2],qn.y+un[Ln+3]),ia.x=qn.x+un[Ln+0],ia.y=qn.y+un[Ln+1],qn.x+=un[Ln+2],qn.y+=un[Ln+3],Ln===0&&ai===!0&&Wi.copy(qn);break;case"q":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln+=4)Si.quadraticCurveTo(qn.x+un[Ln+0],qn.y+un[Ln+1],qn.x+un[Ln+2],qn.y+un[Ln+3]),ia.x=qn.x+un[Ln+0],ia.y=qn.y+un[Ln+1],qn.x+=un[Ln+2],qn.y+=un[Ln+3],Ln===0&&ai===!0&&Wi.copy(qn);break;case"t":for(Ln=0,hr=(un=fe(fn)).length;Ln<hr;Ln+=2)hi=J(qn.x,ia.x),bi=J(qn.y,ia.y),Si.quadraticCurveTo(hi,bi,qn.x+un[Ln+0],qn.y+un[Ln+1]),ia.x=hi,ia.y=bi,qn.x=qn.x+un[Ln+0],qn.y=qn.y+un[Ln+1],Ln===0&&ai===!0&&Wi.copy(qn);break;case"a":for(Ln=0,hr=(un=fe(fn,[3,4],7)).length;Ln<hr;Ln+=7)un[Ln+5]==0&&un[Ln+6]==0||(Ra=qn.clone(),qn.x+=un[Ln+5],qn.y+=un[Ln+6],ia.x=qn.x,ia.y=qn.y,L(Si,un[Ln],un[Ln+1],un[Ln+2],un[Ln+3],un[Ln+4],Ra,qn),Ln===0&&ai===!0&&Wi.copy(qn));break;case"Z":case"z":Si.currentPath.autoClose=!0,0<Si.currentPath.curves.length&&(qn.copy(Wi),Si.currentPath.currentPoint.copy(qn),ha=!0);break;default:console.warn(sa)}ai=!1}return Si}(It));break;case"rect":nn=q(It,nn),Xn=function(xi){var Si=Ue(xi.getAttribute("x")||0),qn=Ue(xi.getAttribute("y")||0),ia=Ue(xi.getAttribute("rx")||xi.getAttribute("ry")||0),Wi=Ue(xi.getAttribute("ry")||xi.getAttribute("rx")||0),ha=Ue(xi.getAttribute("width")),ai=Ue(xi.getAttribute("height")),Ia=.448084975506,fi=new y.ShapePath;return fi.moveTo(Si+ia,qn),fi.lineTo(Si+ha-ia,qn),ia===0&&Wi===0||fi.bezierCurveTo(Si+ha-ia*Ia,qn,Si+ha,qn+Wi*Ia,Si+ha,qn+Wi),fi.lineTo(Si+ha,qn+ai-Wi),ia===0&&Wi===0||fi.bezierCurveTo(Si+ha,qn+ai-Wi*Ia,Si+ha-ia*Ia,qn+ai,Si+ha-ia,qn+ai),fi.lineTo(Si+ia,qn+ai),ia===0&&Wi===0||fi.bezierCurveTo(Si+ia*Ia,qn+ai,Si,qn+ai-Wi*Ia,Si,qn+ai-Wi),fi.lineTo(Si,qn+Wi),ia===0&&Wi===0||fi.bezierCurveTo(Si,qn+Wi*Ia,Si+ia*Ia,qn,Si+ia,qn),fi}(It);break;case"polygon":nn=q(It,nn),xn=It,$n=new y.ShapePath,Xr=0,xn.getAttribute("points").replace(/(-?[\d\.?]+)[,|\s](-?[\d\.?]+)/g,function(xi,Si,qn){var ia=Ue(Si),Wi=Ue(qn);Xr===0?$n.moveTo(ia,Wi):$n.lineTo(ia,Wi),Xr++}),$n.currentPath.autoClose=!0,Xn=$n;break;case"polyline":nn=q(It,nn),Lt=It,wn=new y.ShapePath,hn=0,Lt.getAttribute("points").replace(/(-?[\d\.?]+)[,|\s](-?[\d\.?]+)/g,function(xi,Si,qn){var ia=Ue(Si),Wi=Ue(qn);hn===0?wn.moveTo(ia,Wi):wn.lineTo(ia,Wi),hn++}),wn.currentPath.autoClose=!1,Xn=wn;break;case"circle":nn=q(It,nn),Xn=function(xi){var Si=Ue(xi.getAttribute("cx")||0),qn=Ue(xi.getAttribute("cy")||0),ia=Ue(xi.getAttribute("r")||0),Wi=new y.Path;Wi.absarc(Si,qn,ia,0,2*Math.PI,!1);var ha=new y.ShapePath;return ha.subPaths.push(Wi),ha}(It);break;case"ellipse":nn=q(It,nn),Xn=function(xi){var Si=Ue(xi.getAttribute("cx")||0),qn=Ue(xi.getAttribute("cy")||0),ia=Ue(xi.getAttribute("rx")||0),Wi=Ue(xi.getAttribute("ry")||0),ha=new y.Path;ha.absellipse(Si,qn,ia,Wi,0,2*Math.PI,void 0,void 0);var ai=new y.ShapePath;return ai.subPaths.push(ha),ai}(It);break;case"line":nn=q(It,nn),pn=Ue((tn=It).getAttribute("x1")||0),_n=Ue(tn.getAttribute("y1")||0),Dn=Ue(tn.getAttribute("x2")||0),an=Ue(tn.getAttribute("y2")||0),(Rn=new y.ShapePath).moveTo(pn,_n),Rn.lineTo(Dn,an),Rn.currentPath.autoClose=!1,Xn=Rn;break;case"defs":gn=!1;break;case"use":nn=q(It,nn);var Kn=It.href.baseVal.substring(1),Vn=It.viewportElement.getElementById(Kn);Vn?kt(Vn,nn):console.warn("SVGLoader: 'use node' references non-existent node id: "+Kn)}if(Xn&&(nn.fill!==void 0&&nn.fill!=="none"&&Xn.color.setStyle(nn.fill),function(xi,Si){function qn(fn){pt.set(fn.x,fn.y,1).applyMatrix3(Si),fn.set(pt.x,pt.y)}for(var ia=function(fn){return fn.elements[1]!==0||fn.elements[3]!==0}(Si),Wi=xi.subPaths,ha=0,ai=Wi.length;ha<ai;ha++)for(var Ia=Wi[ha].curves,fi=0;fi<Ia.length;fi++){var An=Ia[fi];An.isLineCurve?(qn(An.v1),qn(An.v2)):An.isCubicBezierCurve?(qn(An.v0),qn(An.v1),qn(An.v2),qn(An.v3)):An.isQuadraticBezierCurve?(qn(An.v0),qn(An.v1),qn(An.v2)):An.isEllipseCurve&&(ia&&console.warn("SVGLoader: Elliptic arc or ellipse rotation or skewing is not implemented."),ue.set(An.aX,An.aY),qn(ue),An.aX=ue.x,An.aY=ue.y,An.xRadius*=(Nn=Si.elements,Math.sqrt(Nn[0]*Nn[0]+Nn[1]*Nn[1])),An.yRadius*=(sa=Si.elements,Math.sqrt(sa[3]*sa[3]+sa[4]*sa[4])))}var sa,Nn}(Xn,mt),De.push(Xn),Xn.userData={node:It,style:nn}),gn)for(var Yn=It.childNodes,Vr=0;Vr<Yn.length;Vr++)kt(Yn[Vr],nn);ti&&(rt.pop(),0<rt.length?mt.copy(rt[rt.length-1]):mt.identity())}}(Tt.documentElement,{fill:"#000",fillOpacity:1,strokeOpacity:1,strokeWidth:1,strokeLineJoin:"miter",strokeLineCap:"butt",strokeMiterLimit:4}),{paths:De,xml:Tt.documentElement}},m.createShapes=function(O){var N=999999999,L={ORIGIN:0,DESTINATION:1,BETWEEN:2,LEFT:3,RIGHT:4,BEHIND:5,BEYOND:6},G={loc:L.ORIGIN,t:0};function q(Ae,Te,Xe,ie){var ue=Ae.x,pt=Te.x,mt=Xe.x,Tt=ie.x,kt=Ae.y,It=Te.y,nn=Xe.y,tn=ie.y,pn=(Tt-mt)*(kt-nn)-(tn-nn)*(ue-mt),_n=(tn-nn)*(pt-ue)-(Tt-mt)*(It-kt),Dn=pn/_n,an=((pt-ue)*(kt-nn)-(It-kt)*(ue-mt))/_n;if(_n==0&&pn!=0||Dn<=0||1<=Dn||an<0||1<an)return null;if(pn==0&&_n==0){for(var Rn=0;Rn<2;Rn++){if(J(Rn===0?Xe:ie,Ae,Te),G.loc==L.ORIGIN)return{x:(Lt=Rn===0?Xe:ie).x,y:Lt.y,t:G.t};if(G.loc==L.BETWEEN)return{x:+(ue+G.t*(pt-ue)).toPrecision(10),y:+(kt+G.t*(It-kt)).toPrecision(10),t:G.t}}return null}for(Rn=0;Rn<2;Rn++){var Lt;if(J(Rn===0?Xe:ie,Ae,Te),G.loc==L.ORIGIN)return{x:(Lt=Rn===0?Xe:ie).x,y:Lt.y,t:G.t}}return{x:+(ue+Dn*(pt-ue)).toPrecision(10),y:+(kt+Dn*(It-kt)).toPrecision(10),t:Dn}}function J(Ae,Te,Xe){var ie,ue=Xe.x-Te.x,pt=Xe.y-Te.y,mt=Ae.x-Te.x,Tt=Ae.y-Te.y,kt=ue*Tt-mt*pt;return Ae.x===Te.x&&Ae.y===Te.y?(G.loc=L.ORIGIN,G.t=0):Ae.x===Xe.x&&Ae.y===Xe.y?(G.loc=L.DESTINATION,G.t=1,0):void(kt<-Number.EPSILON?G.loc=L.LEFT:kt>Number.EPSILON?G.loc=L.RIGHT:ue*mt<0||pt*Tt<0?G.loc=L.BEHIND:Math.sqrt(ue*ue+pt*pt)<Math.sqrt(mt*mt+Tt*Tt)?G.loc=L.BEYOND:(ie=ue!=0?mt/ue:Tt/pt,G.loc=L.BETWEEN,G.t=ie))}function fe(Ae,Te,Xe){var ie=new y.Vector2;Te.getCenter(ie);var ue=[];return Xe.forEach(function(pt){pt.boundingBox.containsPoint(ie)&&function(mt,Tt){for(var kt=[],It=[],nn=1;nn<mt.length;nn++)for(var tn=mt[nn-1],pn=mt[nn],_n=function(an){var Rn=Tt[an-1],Lt=Tt[an],wn=q(tn,pn,Rn,Lt);wn!==null&&kt.find(function(hn){return hn.t<=wn.t+Number.EPSILON&&hn.t>=wn.t-Number.EPSILON})===void 0&&(kt.push(wn),It.push(new y.Vector2(wn.x,wn.y)))},Dn=1;Dn<Tt.length;Dn++)_n(Dn);return It}(Ae,pt.points).forEach(function(mt){ue.push({identifier:pt.identifier,isCW:pt.isCW,point:mt})})}),ue.sort(function(pt,mt){return pt.point.x-mt.point.x}),ue}var ve=0,ne=N,Ue=-N,De=O.subPaths.map(function(Ae){for(var Te=Ae.getPoints(),Xe=-N,ie=N,ue=-N,pt=N,mt=0;mt<Te.length;mt++){var Tt=Te[mt];Tt.y>Xe&&(Xe=Tt.y),Tt.y<ie&&(ie=Tt.y),Tt.x>ue&&(ue=Tt.x),Tt.x<pt&&(pt=Tt.x)}return Ue<=ue&&(Ue=ue+1),pt<=ne&&(ne=pt-1),{curves:Ae.curves,points:Te,isCW:y.ShapeUtils.isClockWise(Te),identifier:ve++,boundingBox:new y.Box2(new y.Vector2(pt,ie),new y.Vector2(ue,Xe))}});De=De.filter(function(Ae){return 1<Ae.points.length}),ve=0;var Ve=(De=De.map(function(Ae){return Ae.identifier=ve,ve++,Ae})).map(function(Ae){return function(Te,Xe,ie,ue,pt){pt!=null&&pt!==""||(pt="nonzero");var mt=new y.Vector2;Te.boundingBox.getCenter(mt);var Tt=fe([new y.Vector2(ie,mt.y),new y.Vector2(ue,mt.y)],Te.boundingBox,Xe);Tt.sort(function(wn,hn){return wn.point.x-hn.point.x});var kt=[],It=[];Tt.forEach(function(wn){wn.identifier===Te.identifier?kt.push(wn):It.push(wn)});for(var nn=kt[0].point.x,tn=[],pn=0;pn<It.length&&It[pn].point.x<nn;)0<tn.length&&tn[tn.length-1]===It[pn].identifier?tn.pop():tn.push(It[pn].identifier),pn++;if(tn.push(Te.identifier),pt==="evenodd"){var _n=tn.length%2==0,Dn=tn[tn.length-2];return{identifier:Te.identifier,isHole:_n,for:Dn}}if(pt==="nonzero"){_n=!0;for(var an=Dn=null,Rn=0;Rn<tn.length;Rn++){var Lt=tn[Rn];_n?(an=Xe[Lt].isCW,_n=!1,Dn=Lt):an!==Xe[Lt].isCW&&(an=Xe[Lt].isCW,_n=!0)}return{identifier:Te.identifier,isHole:_n,for:Dn}}console.warn('fill-rule: "'+pt+'" is currently not implemented.')}(Ae,De,ne,Ue,O.userData.style.fillRule)}),rt=[];return De.forEach(function(Ae){if(!Ve[Ae.identifier].isHole){var Te=new y.Shape;Te.curves=Ae.curves,Ve.filter(function(Xe){return Xe.isHole&&Xe.for===Ae.identifier}).forEach(function(Xe){var ie=De[Xe.identifier],ue=new y.Path;ue.curves=ie.curves,Te.holes.push(ue)}),rt.push(Te)}}),rt},m.getStrokeStyle=function(O,N,L,G,q){return{strokeColor:N=N!==void 0?N:"#000",strokeWidth:O=O!==void 0?O:1,strokeLineJoin:L=L!==void 0?L:"miter",strokeLineCap:G=G!==void 0?G:"butt",strokeMiterLimit:q=q!==void 0?q:4}},m.pointsToStroke=function(O,N,L,G){var q=[],J=[],fe=[];if(m.pointsToStrokeWithBuffers(O,N,L,G,q,J,fe)===0)return null;var ve=new y.BufferGeometry;return ve.setAttribute("position",new y.Float32BufferAttribute(q,3)),ve.setAttribute("normal",new y.Float32BufferAttribute(J,3)),ve.setAttribute("uv",new y.Float32BufferAttribute(fe,2)),ve},m.pointsToStrokeWithBuffers=function(O,N,L,G,q,J,fe,ve){var ne=new y.Vector2,Ue=new y.Vector2,De=new y.Vector2,Ve=new y.Vector2,rt=new y.Vector2,Ae=new y.Vector2,Te=new y.Vector2,Xe=new y.Vector2,ie=new y.Vector2,ue=new y.Vector2,pt=new y.Vector2,mt=new y.Vector2,Tt=new y.Vector2,kt=new y.Vector2,It=new y.Vector2,nn=new y.Vector2,tn=new y.Vector2;L=L!==void 0?L:12,G=G!==void 0?G:.001,ve=ve!==void 0?ve:0;var pn=(O=function(hr){for(var hi=!1,bi=1,Ra=hr.length-1;bi<Ra;bi++)if(hr[bi].distanceTo(hr[bi+1])<G){hi=!0;break}if(!hi)return hr;var so=[];for(so.push(hr[0]),bi=1,Ra=hr.length-1;bi<Ra;bi++)hr[bi].distanceTo(hr[bi+1])>=G&&so.push(hr[bi]);return so.push(hr[hr.length-1]),so}(O)).length;if(pn<2)return 0;var _n,Dn,an,Rn,Lt,wn,hn=O[0].equals(O[pn-1]),xn=O[0],$n=N.strokeWidth/2,Xr=1/(pn-1),ti=0,gn=!1,Xn=0,Kn=3*ve,Vn=2*ve;fi(O[0],O[1],ne).multiplyScalar($n),Xe.copy(O[0]).sub(ne),ie.copy(O[0]).add(ne),ue.copy(Xe),pt.copy(ie);for(var Yn=1;Yn<pn;Yn++){_n=O[Yn],Dn=Yn===pn-1?hn?O[1]:void 0:O[Yn+1];var Vr=ne;if(fi(xn,_n,Vr),De.copy(Vr).multiplyScalar($n),mt.copy(_n).sub(De),Tt.copy(_n).add(De),an=ti+Xr,Rn=!1,Dn!==void 0){fi(_n,Dn,Ue),De.copy(Ue).multiplyScalar($n),kt.copy(_n).sub(De),It.copy(_n).add(De),Lt=!0,De.subVectors(Dn,xn),Vr.dot(De)<0&&(Lt=!1),Yn===1&&(gn=Lt),De.subVectors(Dn,_n),De.normalize();var xi=Math.abs(Vr.dot(De));if(xi!==0){var Si=$n/xi;De.multiplyScalar(-Si),Ve.subVectors(_n,xn),rt.copy(Ve).setLength(Si).add(De),nn.copy(rt).negate();var qn=rt.length(),ia=Ve.length();Ve.divideScalar(ia),Ae.subVectors(Dn,_n);var Wi=Ae.length();switch(Ae.divideScalar(Wi),Ve.dot(nn)<ia&&Ae.dot(nn)<Wi&&(Rn=!0),tn.copy(rt).add(_n),nn.add(_n),wn=!1,Rn?Lt?(It.copy(nn),Tt.copy(nn)):(kt.copy(nn),mt.copy(nn)):Nn(),N.strokeLineJoin){case"bevel":fn(Lt,Rn,an);break;case"round":un(Lt,Rn),Lt?sa(_n,mt,kt,an,0):sa(_n,It,Tt,an,1);break;default:var ha=$n*N.strokeMiterLimit/qn;if(ha<1){if(N.strokeLineJoin!=="miter-clip"){fn(Lt,Rn,an);break}un(Lt,Rn),Lt?(Ae.subVectors(tn,mt).multiplyScalar(ha).add(mt),Te.subVectors(tn,kt).multiplyScalar(ha).add(kt),An(mt,an,0),An(Ae,an,0),An(_n,an,.5),An(_n,an,.5),An(Ae,an,0),An(Te,an,0),An(_n,an,.5),An(Te,an,0),An(kt,an,0)):(Ae.subVectors(tn,Tt).multiplyScalar(ha).add(Tt),Te.subVectors(tn,It).multiplyScalar(ha).add(It),An(Tt,an,1),An(Ae,an,1),An(_n,an,.5),An(_n,an,.5),An(Ae,an,1),An(Te,an,1),An(_n,an,.5),An(Te,an,1),An(It,an,1))}else Rn?(Lt?(An(ie,ti,1),An(Xe,ti,0),An(tn,an,0),An(ie,ti,1),An(tn,an,0),An(nn,an,1)):(An(ie,ti,1),An(Xe,ti,0),An(tn,an,1),An(Xe,ti,0),An(nn,an,0),An(tn,an,1)),Lt?kt.copy(tn):It.copy(tn)):Lt?(An(mt,an,0),An(tn,an,0),An(_n,an,.5),An(_n,an,.5),An(tn,an,0),An(kt,an,0)):(An(Tt,an,1),An(tn,an,1),An(_n,an,.5),An(_n,an,.5),An(tn,an,1),An(It,an,1)),wn=!0}}else Nn()}else Nn();hn||Yn!==pn-1||Ln(O[0],ue,pt,Lt,!0,ti),ti=an,xn=_n,Xe.copy(kt),ie.copy(It)}if(hn){if(Rn&&q){var ai=tn,Ia=nn;gn!==Lt&&(ai=nn,Ia=tn),Lt?(wn||gn)&&(Ia.toArray(q,0),Ia.toArray(q,9),wn&&ai.toArray(q,3)):!wn&&gn||(Ia.toArray(q,3),Ia.toArray(q,9),wn&&ai.toArray(q,0))}}else Ln(_n,mt,Tt,Lt,!1,an);return Xn;function fi(hr,hi,bi){return bi.subVectors(hi,hr),bi.set(-bi.y,bi.x).normalize()}function An(hr,hi,bi){q&&(q[Kn]=hr.x,q[Kn+1]=hr.y,q[Kn+2]=0,J&&(J[Kn]=0,J[Kn+1]=0,J[Kn+2]=1),Kn+=3,fe&&(fe[Vn]=hi,fe[Vn+1]=bi,Vn+=2)),Xn+=3}function sa(hr,hi,bi,Ra,so){ne.copy(hi).sub(hr).normalize(),Ue.copy(bi).sub(hr).normalize();var Pi=Math.PI,oi=ne.dot(Ue);Math.abs(oi)<1&&(Pi=Math.abs(Math.acos(oi))),Pi/=L,De.copy(hi);for(var Ni=0,za=L-1;Ni<za;Ni++)Ve.copy(De).rotateAround(hr,Pi),An(De,Ra,so),An(Ve,Ra,so),An(hr,Ra,.5),De.copy(Ve);An(Ve,Ra,so),An(bi,Ra,so),An(hr,Ra,.5)}function Nn(){An(ie,ti,1),An(Xe,ti,0),An(mt,an,0),An(ie,ti,1),An(mt,an,1),An(Tt,an,0)}function fn(hr,hi,bi){hi?(hr?(An(ie,ti,1),An(Xe,ti,0),An(mt,an,0),An(ie,ti,1),An(mt,an,0),An(nn,an,1),An(mt,bi,0),An(kt,bi,0)):(An(ie,ti,1),An(Xe,ti,0),An(Tt,an,1),An(Xe,ti,0),An(nn,an,0),An(Tt,an,1),An(Tt,bi,1),An(It,bi,0)),An(nn,bi,.5)):(hr?(An(mt,bi,0),An(kt,bi,0)):(An(Tt,bi,1),An(It,bi,0)),An(_n,bi,.5))}function un(hr,hi){hi&&(hr?(An(ie,ti,1),An(Xe,ti,0),An(mt,an,0),An(ie,ti,1),An(mt,an,0),An(nn,an,1),An(mt,ti,0),An(_n,an,.5),An(nn,an,1),An(_n,an,.5),An(kt,ti,0),An(nn,an,1)):(An(ie,ti,1),An(Xe,ti,0),An(Tt,an,1),An(Xe,ti,0),An(nn,an,0),An(Tt,an,1),An(Tt,ti,1),An(nn,an,0),An(_n,an,.5),An(_n,an,.5),An(nn,an,0),An(It,ti,1)))}function Ln(hr,hi,bi,Ra,so,Pi){switch(N.strokeLineCap){case"round":so?sa(hr,bi,hi,Pi,.5):sa(hr,hi,bi,Pi,.5);break;case"square":if(so)ne.subVectors(hi,hr),Ue.set(ne.y,-ne.x),De.addVectors(ne,Ue).add(hr),Ve.subVectors(Ue,ne).add(hr),Ra?(De.toArray(q,3),Ve.toArray(q,0),Ve.toArray(q,9)):(De.toArray(q,3),De.toArray(q,9),Ve.toArray(q,0));else{ne.subVectors(bi,hr),Ue.set(ne.y,-ne.x),De.addVectors(ne,Ue).add(hr),Ve.subVectors(Ue,ne).add(hr);var oi=q.length;Ra?(De.toArray(q,oi-3),Ve.toArray(q,oi-6)):(De.toArray(q,oi-6),Ve.toArray(q,oi-3)),Ve.toArray(q,oi-12)}}}},m);function m(O){var N=c.call(this,O)||this;return N.defaultDPI=90,N.defaultUnit="px",N}l.SVGLoader=b},{three:19}],61:[function(t,e,l){var n,u=this&&this.__extends||(n=function(Xe,ie){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ue,pt){ue.__proto__=pt}||function(ue,pt){for(var mt in pt)Object.prototype.hasOwnProperty.call(pt,mt)&&(ue[mt]=pt[mt])})(Xe,ie)},function(Xe,ie){function ue(){this.constructor=Xe}n(Xe,ie),Xe.prototype=ie===null?Object.create(ie):(ue.prototype=ie.prototype,new ue)});Object.defineProperty(l,"__esModule",{value:!0}),l.MxTest=void 0;var c,y,b=t("../Operate/MrxDbgUiPrBase"),m=t("../Operate/MrxDbgUiPrPoint"),O=t("../MxThreeJS"),N=t("three"),L=t("../MxFun"),G=t("../View/MxDbEntity"),q=t("../MrxDbgUtils"),J=t("../Operate/MrxDbgUiPrDist"),fe=(t("../MxString"),u(ve,c=G.MxDbEntityUserObject),ve.prototype.worldDraw=function(Xe){var ie=new N.Vector3(this.pt.x-this.r,this.pt.y-this.r,0),ue=new N.Vector3(this.pt.x+this.r,this.pt.y+this.r,0);new N.Vector3(ie.x,ue.y);var pt=new N.Vector3(ue.x,ie.y);Xe.setDashLineDisplay(!0),Xe.setDash(.1,.2),Xe.drawLine(pt,ie)},ve.prototype.setPoint=function(Xe){this.pt=Xe},ve.prototype.setR=function(Xe){this.r=Xe},ve.prototype.getTypeName=function(){return"MxDbTest"},ve.prototype.getGripPoints=function(){var Xe=[];return Xe.push(this.pt),Xe},ve.prototype.moveGripPointsAt=function(Xe,ie){return Xe==0&&this.pt.add(ie),!0},ve.prototype.dwgIn=function(Xe){return c.prototype.dwgIn.call(this,Xe),this.pt.copy(Xe.pt),this.r=Xe.r,!0},ve.prototype.dwgOut=function(Xe){return c.prototype.dwgOut.call(this,Xe),Xe.pt=this.pt,Xe.r=this.r,Xe},ve.prototype.create=function(){return new ve},ve);function ve(){var Xe=c!==null&&c.apply(this,arguments)||this;return Xe.pt=new N.Vector3,Xe.r=100,Xe}function ne(Xe){var ie=new m.MrxDbgUiPrPoint;ie.setMessage(`
- 指定第一点:`),ie.go(function(ue){if(ue==0){var pt=ie.value(),mt=new N.Vector3;mt.x=pt.x,mt.y=pt.y;var Tt=new b.McEdGetPointWorldDrawObject;Tt.setDraw(function(kt,It){It.setColor(255),It.drawLine(kt,mt)}),ie.setUserDraw(Tt),ie.setMessage(`
- 指定下一点:`),ie.go(function(kt){if(kt==0){var It=ie.value(),nn=L.MxFun.getCurrentDraw(),tn=O.MxThreeJS.createLine(pt,It,16777215);nn.addObject(tn)}})}})}function Ue(){var Xe=new m.MrxDbgUiPrPoint;Xe.setMessage(`
- 指定第一点:`),Xe.go(function(ie){if(ie==0){var ue=L.MxFun.getCurrentDraw(),pt=new fe;pt.setColor(16711680),pt.setPoint(Xe.value()),pt.setR(ue.viewCoordLong2Cad(100)),ue.addMxEntity(pt),ue.addMxCurrentSelect(pt.objectId())}})}function De(){q.MrxDbgUtils.selectEnt("Test").then(function(Xe){console.log(Xe)})}function Ve(){var Xe=L.MxFun.getCurrentDraw();y?(Xe.eraseAllMxEntity(),Xe.loadMxEntityFromJson(y)):(y=Xe.saveMxEntityToJson(),console.log(y))}function rt(){L.MxFun.openFile("demo/buf/hhhh.dwg?token=123456")}function Ae(){var Xe=new m.MrxDbgUiPrPoint;Xe.setMessage(`
- 指定第一点:`),Xe.go(function(ie){if(ie==0){var ue=Xe.value();q.MrxDbgUtils.getCorner(ue,"Test",!0).then(function(pt){console.log("xxxdddd"),console.log(pt)})}})}function Te(){var Xe=new J.MrxDbgUiPrDist;Xe.setMessage(`
- 输入距离:`),Xe.go(function(ie){if(ie==0){var ue=Xe.value();console.log(ue)}})}(l.MxTest||(l.MxTest={})).registerCommand=function(){console.log("regist mx test"),new fe().init(),L.MxFun.addCommand("MxTest_GetPoint",ne),L.MxFun.addCommand("MxTest_GetDist",Te),L.MxFun.addCommand("MxTest_DrawCustomEntity",Ue),L.MxFun.addCommand("MxTest_EntSel",De),L.MxFun.addCommand("MxTest_SaveMxDbEntityToJson",Ve),L.MxFun.addCommand("MxTest_OpenFile",rt),L.MxFun.addCommand("MxTest_GetCorner",Ae),L.MxFun.addWindowsEvent(function(Xe,ie){if(Xe=="mouseup"){if(L.MxFun.isRunningCommand()||ie.button!=0)return 0;var ue=ie.srcElement;if(ue&&ue.tagName=="CANVAS"){var pt=L.MxFun.getCurrentDraw(),mt=new N.Vector3(ie.offsetX,ie.offsetY,0);pt.findMxEntityAtPoint(mt,!1).length&&ie.preventDefault()}return 0}})}},{"../MrxDbgUtils":20,"../MxFun":27,"../MxString":34,"../MxThreeJS":37,"../Operate/MrxDbgUiPrBase":45,"../Operate/MrxDbgUiPrDist":46,"../Operate/MrxDbgUiPrPoint":47,"../View/MxDbEntity":69,three:19}],62:[function(require,module,exports){Object.defineProperty(exports,"__esModule",{value:!0}),exports.MxUiObject=exports.MxToolBarItem=exports.MxMenuItem=void 0;var MxFun_1=require("../MxFun"),MxMenuItem=function(){this.id=-1,this.text="",this.evalString="",this.parentId=-1};exports.MxMenuItem=MxMenuItem;var MxToolBarItem=function(){this.isMxCommand=!1,this.itemid=""};exports.MxToolBarItem=MxToolBarItem;var MxUiObject=function(){function MxUiObject(){this.vecMenuItem=new Array,this.vecToolBarItem=new Array,this.uiPath="./ui",this.idMenuItemCount=100,this.isShowTitle=!1,this.isShowStructTree=!1,this.isEnableLoading=!0,this.isShowLayer=!1,this.isShowTakeColor=!1,this.isShowLayout=!1,this.isEnableObjectProperty=!1,this.isShowToolbar=!1,this.isShowMainMenu=!1,this.sTitle="",this.sLanguageTable={layout:"布局",layer:"图层",visible:"可见",color:"颜色",name:"名字",status:"状态",openComplete:"提示:打开图纸完成"}}return MxUiObject.prototype.SetLayoutData=function(t){this.vecLayoutData=t},MxUiObject.prototype.CallMxCommand=function(t){MxFun_1.MxFun.callCommand(t,"")},MxUiObject.prototype.EvalJs=function(value){eval(value)},MxUiObject.prototype.SetLayerData=function(t){this.vecLayerData=t},MxUiObject.prototype.SetSketchLayerData=function(t){this.vecSketchLayerData=t},MxUiObject.prototype.init=function(){this.onInit()},MxUiObject.prototype.addMenuItem=function(t,e,l,n){e===void 0&&(e=""),l===void 0&&(l=-1),n===void 0&&(n=-1);var u=new MxMenuItem;u.text=t,u.evalString=e,n==-1&&(n=this.idMenuItemCount,this.idMenuItemCount++),u.id=n,u.parentId=l,this.vecMenuItem.push(u)},MxUiObject.prototype.addToolBarItem=function(t,e,l,n,u){e===void 0&&(e=""),l===void 0&&(l=""),n===void 0&&(n=!1),u===void 0&&(u="");var c=new MxToolBarItem;c.image=t,c.evalString=l,c.text=e,c.isMxCommand=n,c.itemid=u,this.vecToolBarItem.push(c)},MxUiObject.prototype.setPath=function(t){this.uiPath=t},MxUiObject.prototype.getPath=function(){return this.uiPath},MxUiObject.prototype.create=function(){this.onCreate()},MxUiObject.prototype.writeUICSS=function(){var t=this.uiPath;MxFun_1.MxFun.isPC()?(document.write("<link rel='stylesheet' href='"+t+"/css/mxbimpcm.css'>"),this.isShowMainMenu&&(document.write("<link rel='stylesheet' href='"+t+"/css/rightfacefonts2.css'>"),document.write("<link rel='stylesheet' href='"+t+"/css/rightmnu.css'>"),document.write("<script type='text/javascript' src='"+t+"/hc-mobile-nav.js'><\/script>"))):(document.write("<link rel='stylesheet' href='"+t+"/css/mxmobile.css'>"),this.isShowMainMenu&&(document.write("<link href='"+t+"/css/font-awesome.min.css' rel='stylesheet'>"),document.write("<link rel='stylesheet' href='"+t+"/css/rightfacefonts1.css'>"),document.write("<link rel='stylesheet' href='"+t+"/css/rightfacefonts2.css'>"),document.write("<link rel='stylesheet' href='"+t+"/css/rightmnu.css'>"),document.write("<script type='text/javascript' src='"+t+"/hc-mobile-nav.js'><\/script>")))},MxUiObject}();exports.MxUiObject=MxUiObject},{"../MxFun":27}],63:[function(t,e,l){var n,u=this&&this.__extends||(n=function(N,L){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(G,q){G.__proto__=q}||function(G,q){for(var J in q)Object.prototype.hasOwnProperty.call(q,J)&&(G[J]=q[J])})(N,L)},function(N,L){function G(){this.constructor=N}n(N,L),N.prototype=L===null?Object.create(L):(G.prototype=L.prototype,new G)});Object.defineProperty(l,"__esModule",{value:!0}),l.MxUiObjectMobile=void 0;var c,y=t("./MxUiObject"),b=t("../MxFun"),m=(u(O,c=y.MxUiObject),O.prototype.onCreate=function(){this.isShowTitle&&this.WriteTitle(),this.WriteStructTree(),this.isEnableLoading&&this.WriteLoading(),this.WriteLayer(),this.WriteTakeColor(),this.WriteLayout(),this.isEnableObjectProperty&&this.WriteObjectProperty(),this.isShowToolbar&&this.WriteToolbar()},O.prototype.onInit=function(){this.InitEvent()},O.prototype.ShowLoading=function(){this.isEnableLoading&&($(".Prompt").css("background","rgba(0, 0, 0, 0)"),$(".Prompt").fadeIn(100),$(".Prompt span").css("display","none"))},O.prototype.HideLoading=function(){this.isEnableLoading&&($(".Prompt").css("background","rgba(0, 0, 0, 0.8)"),$(".Prompt div").fadeOut(100),$(".Prompt span").fadeIn(200),setTimeout(function(){$(".Prompt").fadeOut(1e3)},1e3))},O.prototype.ShowObjectProperty=function(N){if(N.length!=0){var L;L=typeof N=="string"?JSON.parse(N):N;var G="";for(var q in L){var J=L[q];for(var fe in G+='<tbody class="bf-group undefined bf-collapse">',G+='<tr class="bf-group-title">',G+='<td colspan="2"><i class="bf-icon" style=" padding: 12px;"></i>'+J.name+"</td>",G+="</tr>",J.datas){var ve=J.datas[fe];G+="<tr class='bf-group-content'>",G+="<td class='bf-key'>"+ve.name+"</td>",G+="<td class='bf-value'>"+ve.value+"</td>",G+="</tr>"}G+="</tbody>"}document.getElementById("ComponentContent").innerHTML=G,$(".bf-group").click(function(){$(this).hasClass("bf-collapse")?$(this).removeClass("bf-collapse"):$(this).addClass("bf-collapse")})}},O.prototype.HideObjectProp=function(){},O.prototype.SwitchShowLayer=function(){var N=document.getElementById("LayerInterface");N.style.display=="none"?(N.style.display="block",N.style.left="80px",N.style.top="50px"):N.style.display="none"},O.prototype.SwitchShowStructTree=function(){},O.prototype.Chosecolor=function(){document.getElementById("color-picker").click()},O.prototype.ColorChange=function(N){document.getElementById("colorbox").style.backgroundColor=N,b.MxFun.setCurrentColor(N)},O.prototype.SwitchShowLayout=function(){var N=document.getElementById("LayerOutInterface");N.style.display=="none"?N.style.display="block":N.style.display="none"},O.prototype.WriteTitle=function(){var N=this.uiPath;document.write("<div class='bar1'>"),document.write("<img src='"+N+"/image/mxcad.png' style='height: 50%;position: absolute;top: 12px;left: 10px;'>"),document.write("<span class='barspan' style='position: absolute;left: 45px;'>"),document.write("</span>"),document.write("<div id='container'>"),this.isShowMainMenu&&(document.write("<header>"),document.write("<div class='wrapper cf'style='z-index: 999'>"),document.write("<nav id='main-nav' >"),document.write("</nav>"),document.write("<a class='toggle'>"),document.write("<span></span>"),document.write("</a>"),document.write("</div>"),document.write("</header>")),document.write("</div>"),document.write("</div>")},O.prototype.WriteToolbar=function(){document.write("<div id='MainMenuContent' class='bf-toolbar bf-toolbar-bottom'>"),document.write("</div>")},O.prototype.WriteLoading=function(){var N=this.uiPath;document.write("<div class='Prompt' style='width: 100px;height:30px;position:"),document.write("absolute;top: 60px;left: 50%;margin-left: -50px;color: #fff;text-align: center;'>"),document.write("<div style='text-align: center;'>"),document.write("<img src='"+N+"/image/loading.gif' alt='' style='width:30px;height:30px;float: left'>"),document.write("<p style='color:black;vertical-align: middle;float: left; margin-top: 5px;margin-left: 5px;'>加载中.....</p>"),document.write("</div>"),document.write("<span style='vertical-align: middle;display: none'>图纸加载完毕</span>"),document.write("</div>")},O.prototype.WriteLayer=function(){var N=this.uiPath;this.isShowLayer&&(document.write("<div class='bf-toolbar bf-toolbar bf-tree-toolbar' title='ModelTree' style='position: absolute; top:111px;left: 0px;' onclick='uiObj.SwitchShowLayer()'>"),document.write("<div class='bf-button mxbim-bf-tree' title='图层'>"),document.write("<img src='"+N+"/image/layer.png.gif' alt='' style='width: 24px;'>"),document.write("</div>"),document.write("</div>")),document.write("<div class='bf-panel bf-has-title bf-sizable' id='LayerInterface' title='图层'"),document.write("style='left: 0px;"),document.write("top: 0px;"),document.write("width: 100%;"),document.write("height: 100%;"),document.write("display: none;'>"),document.write("<div class='bf-close' onclick='uiObj.SwitchShowLayer()' style='text-align: center;'><i class='fa fa-times' aria-hidden='true'></i></div>"),document.write("<div class='bf-title' style='cursor: move; user-select: none;'>图层</div>"),document.write("<div>"),document.write("<div class='layer-title' style='width: 12.5%;'>可见</div>"),document.write("<div class='layer-title' style='width: 12.5%;'>颜色</div>"),document.write("<div class='layer-title' style='width: 62.5%'>名字</div>"),document.write("<div class='layer-title' style='width: 12.5%'>状态</div>"),document.write("</div>"),document.write("<div id='Layer-Info' style='margin-top: 26px;height: 79%;width: 100%; position: absolute;overflow-y: auto;'>"),document.write("</div>"),document.write("</div>")},O.prototype.WriteStructTree=function(){this.isShowStructTree&&(document.write("<div class='bf-toolbar bf-toolbar bf-tree-toolbar' id='Fmj' title='ModelTree'"),document.write("style='position: absolute; top:60px;left: 0px;' onclick='uiObj.SwitchShowStructTree()'>"),document.write("<div class='bf-button mxbim-bf-tree' title='构件树'><i class='fa fa-sitemap' aria-hidden='true' style='font-size: 24px;'></i></div>"),document.write("</div>")),document.write("<div class='bf-panel bf-has-title bf-sizable tree-panel' id='dv' title='目录树' style='left: 0px; top: 0px; width: 100%; height: 100%; display: none;'>"),document.write("<div class='bf-close' onclick='uiObj.SwitchShowStructTree()'><i class='fa fa-times fa-2x' aria-hidden='true'></i></div>"),document.write("<div class='bf-title' style='cursor: move; user-select: none;'>目录树</div>"),document.write("<div class='bf-panel-body' style='padding-top: 57px;overflow-y: scroll;'>"),document.write("<div class='bf-panel-header'>"),document.write("<div class='bf-panel-header'>"),document.write("<div class='bf-tree-header' style='margin-top: -57px;'>"),document.write("<div class='bf-tabs bf-tabs-tree'>"),document.write("<ul class='bf-tabs-list'>"),document.write("<li class='bf-tabs-option my-option undefined active' id='component'>构件</li>"),document.write("<li class='bf-tabs-option my-option undefined' id='area'>空间</li>"),document.write("<li class='bf-tabs-option my-option undefined' id='drawing'>图纸</li>"),document.write("</ul>"),document.write("</div>"),document.write("</div>"),document.write("</div>"),document.write("</div>"),document.write("<div class='' style='margin-bottom: 100px;' id='DirectoryContent'>"),document.write("</div>"),document.write("</div>"),document.write("</div>")},O.prototype.WriteTakeColor=function(){var N=this.uiPath;this.isShowTakeColor&&(document.write("<div class='bf-toolbar bf-toolbar bf-tree-toolbar' id='TakeColor'"),document.write("style='position: absolute;left: 0px; top: 162px;width: 45px; '>"),document.write("<div class='bf-button' onclick='uiObj.Chosecolor()' style='opacity: 1;width: 45px;'>"),document.write("<div style='position: relative;margin-left: 10px;margin-top: -5px;'>"),document.write("<img src='"+N+"/image/color.png' alt='' style='width: 40px;margin-left: -21px;'>"),document.write("</div>"),document.write("<div id='colorbox' style='width: 30px;height: 5px;background-color: #cccccc;margin-left: -3px;margin-top: -5px;'>"),document.write("</div>"),document.write("<div style='width: 18px;height: 40px;float: right;margin-top: -38px;margin-left: 14px;position: absolute;'>"),document.write("<img src='"+N+"/image/daojiao.png' alt='' style='width: 15px;margin-top: 10px;z-index: 999;position: relative'>"),document.write("<input id='color-picker' type='color' value='#c0c0c0' style='display: none' onchange='colorChange(value)'>"),document.write("</div>"),document.write("</div>"),document.write("</div>"))},O.prototype.WriteLayout=function(){var N=this.uiPath;this.isShowLayout&&(document.write("<div class='bf-toolbar bf-toolbar bf-tree-toolbar' id='LayerOut'"),document.write("style='position: absolute;left: 0px; top: 213px; ' onclick='uiObj.SwitchShowLayout()'>"),document.write("<div class='bf-button'>"),document.write("<img src='"+N+"/image/layout.png' alt='' style='width: 24px;'>"),document.write("</div>"),document.write("</div>")),document.write("<div class='bf-panel bf-has-title bf-sizable' id='LayerOutInterface'"),document.write("style='left: 0; top: 0; width: 100%;display:none'>"),document.write("<div class='bf-close' onclick='uiObj.SwitchShowLayout()'><i class='fa fa-times' aria-hidden='true'></i></div>"),document.write("<div class='bf-title' id='buju' style='cursor: move; user-select: none;'>布局</div>"),document.write("<div>"),document.write("</div>"),document.write("<div id=''>"),document.write("<div>"),document.write("<table class='bf-table'>"),document.write("<tbody class='bf-group'>"),document.write("<tr class='bf-group-title bf_layerout' style='height: 30px;cursor: pointer;'>"),document.write("<td class='bf_layerout_td' style='width: 60px' >"),document.write("<div class='bf_layer_div layer_on'></div>"),document.write("</td>"),document.write("<td style='width: 238px' >"),document.write("<span style='color: white;cursor: pointer;'>LayerOut</span>"),document.write("</td>"),document.write("</tr>"),document.write("<tr class='bf-group-title bf_layerout' style='height: 30px;cursor: pointer;'>"),document.write("<td class='bf_layerout_td' style='width: 60px' >"),document.write("<div class='bf_layer_div' ></div>"),document.write("</td>"),document.write("<td style='width: 238px' >"),document.write("<span style='color: white;cursor: pointer;'>LayerOut</span>"),document.write("</td>"),document.write("</tr>"),document.write("<tr class='bf-group-title bf_layerout' style='height: 30px;cursor: pointer;'>"),document.write("<td class='bf_layerout_td' style='width: 60px' >"),document.write("<div class='bf_layer_div' ></div>"),document.write("</td>"),document.write("<td style='width: 238px' >"),document.write("<span style='color: white;cursor: pointer;'>LayerOut</span>"),document.write("</td>"),document.write("</tr>"),document.write("<tr class='bf-group-title bf_layerout' style='height: 30px;cursor: pointer;'>"),document.write("<td class='bf_layerout_td' style='width: 60px' >"),document.write("<div class='bf_layer_div'></div>"),document.write("</td>"),document.write("<td style='width: 238px' >"),document.write("<span style='color: white;cursor: pointer;'>LayerOut</span>"),document.write("</td>"),document.write("</tr>"),document.write("</tbody>"),document.write("</table>"),document.write("</div>"),document.write("</div>"),document.write("</div>")},O.prototype.WriteObjectProperty=function(){document.write("<div class='bf-panel bf-has-title bf-sizable property-panel' id='fmj2' title='构件详情' style='left: 0px; top: 0px; width: 100%; height: 100%;display: none;'>"),document.write("<div class='bf-close' id='close2' style='top:4.0em;'><i class='fa fa-times fa-2x' aria-hidden='true'></i></div>"),document.write("<div class='bf-title' style='cursor: move; user-select: none;'>构件详情</div>"),document.write("<div class='bf-panel-body' style='padding-top: 41px;'>"),document.write("<div class='bf-panel-container bf-scroll-bar' style='top:0;width: 100%;height: 100%;overflow-y: auto;position: relative;'>"),document.write("<table class='bf-table' id='ComponentContent'>"),document.write("</table>"),document.write("</div>"),document.write("</div>"),document.write("</div>")},O.prototype.UpDisplayLayout=function(){},O.prototype.UpDisplayLayer=function(){var N=this.uiPath,L=this.vecLayerData,G=this.vecSketchLayerData,q="";if(G!=null){var J=G;for(var fe in J){q+="<div>";var ve="hide.png";J[fe].off==0&&(ve="show.png");var ne="unlock.png";q+="<table class='bf-table'>",q+="<tbody class='bf-group'>",q+="<tr class='bf-group-title'>",q+='<td><img class="layer-enable" sketch=1 id='+J[fe].id+' src="'+N+"/image/"+ve+'"/></td>',q+='<td><span class="layer-color" style="background-color:'+J[fe].color+'"></span></td>',q+='<td><span class="layer-text">草图_'+J[fe].name+"</span></td>",q+='<td><img class="layer-state" src="'+N+"/image/"+ne+'"/></td>',q+="</tr>",q+="</tbody>",q+="</table>",q+="</div>"}}if(L!=null)for(var fe in J=L)q+="<div>",ve="hide.png",J[fe].off==0&&(ve="show.png"),ne="lock.png",q+="<table class='bf-table'>",q+="<tbody class='bf-group'>",q+="<tr class='bf-group-title'>",q+='<td><img class="layer-enable" sketch=0 id='+J[fe].id+' src="'+N+"/image/"+ve+'"/></td>',q+='<td><span class="layer-color" style="background-color:'+J[fe].color+'"></span></td>',q+='<td><span class="layer-text">'+J[fe].name+"</span></td>",q+='<td><img class="layer-state" src="'+N+"/image/"+ne+'"/></td>',q+="</tr>",q+="</tbody>",q+="</table>",q+="</div>";var Ue=document.getElementById("Layer-Info");Ue!=null&&(Ue.innerHTML=q)},O.prototype.WriteFooter=function(){document.write("<div class='footer' style='background: rgba(0, 0, 0, 0.7);min-width: auto;position: fixed;left: 0;bottom: 0;width: 100%;'>"),document.write("<div style='line-height: 40px;font-size: 12px;color: #999;padding: 0 10px;'>"),document.write("<p style='float: right;line-height: 15px;font-size: 12px;color: #999;display: block;'>"),document.write("<a style='color: #4a90e2;text-decoration: none;outline: none;' href='http://www.mxdraw.com/' target='_blank'>梦想CAD</a>旗下产品"),document.write("</p>"),document.write("<a style='color: #4a90e2;text-decoration: none;outline: none;' href='http://www.mxdraw.com' target='_blank'>MX3D</a> 蜀ICP备15011727号"),document.write("</div>"),document.write("</div>")},O.prototype.CreateToolBar=function(N){if(this.isShowToolbar){var L="";for(var G in N){var q=N[G],J="uiObj.CallMxCommand";q.isMxCommand||(J="uiObj.EvalJs"),0<q.itemid.length?L+='<div class="bf-button" onclick="'+J+"('"+N[G].evalString+`')"><img class="mainimage-bf-butto" id="`+q.itemid+'" src="'+this.uiPath+"\\image\\"+q.image+'" title="'+N[G].text+'"></div>':L+='<div class="bf-button" onclick="'+J+"('"+N[G].evalString+`')"><img class="mainimage-bf-butto" src="`+this.uiPath+"\\image\\"+q.image+'" title="'+N[G].text+'"></div>'}document.getElementById("MainMenuContent").innerHTML=L}},O.prototype.InitEvent=function(){var N=document.getElementById("LayerInterface");this.CreateToolBar(this.vecToolBarItem),N.style.display="none";var L=this.vecMenuItem;this.isShowMainMenu&&function(ve){var ne="";(function Te(Xe,ie){var ue=function(mt,Tt){var kt=new Array;for(var It in Tt)Tt[It].parentId==mt&&kt.push(Tt[It]);return kt}(Xe,ie);if(0<ue.length){for(var pt in ne+="<ul>",ue)ue[pt].evalString.length!=0?(ne+='<li><p class="li_option" ',ne+=`onclick="uiObj.EvalJs('`+ue[pt].evalString+`')"`,ne+=">"+ue[pt].text+"</p>"):(ne+="<li><a ",ne+=">"+ue[pt].text+"</a>"),Te(ue[pt].id,ie),ne+="</li>";ne+="</br>",ne+="</br>",ne+="</br>",ne+="</ul>"}})(-1,L),ve("#main-nav").append(ne);var Ue=ve("#main-nav"),De=ve(".toggle"),Ve={maxWidth:!1,customToggle:De,levelTitles:!0},rt=null,Ae={};rt&&rt.remove(),De.off("click"),rt=Ue.clone(),ve.extend(Ae,{side:"right"}),rt.hcMobileNav(ve.extend({},Ve,Ae))}(jQuery);var G=window.location.href,q=G.length,J=G.indexOf("?"),fe=G.substr(J,q).split("=")[1];$(".barspan").html(decodeURIComponent(fe)),$("#close2").click(function(){$(this).parent("div").fadeOut(200)}),$(".bf-select-current").click(function(){$(this).hasClass("bf-open")?$(this).removeClass("bf-open"):$(this).addClass("bf-open")}),$(".my-option").click(function(){var ve=$(this);$(".my-option").each(function(){$(this).removeClass("active")}),ve.addClass("active")}),$(".bf-select-option").click(function(){$(this).parent("ul").prev("span").html($(this).text()),$(this).parent("ul").prev("span").removeClass("bf-open")}),$(document).on("click",".layer-enable",function(){var ve=b.MxFun.getUiObj().getPath(),ne=parseInt($(this).attr("id")),Ue=!0;$(this).attr("src")==ve+"/image/show.png"?($(this).attr("src",ve+"/image/hide.png"),Ue=!1):$(this).attr("src",ve+"/image/show.png"),b.MxFun.showLayer(ne,Ue)})},O.prototype.Fullscreen=function(){var N=document.documentElement;N.requestFullscreen?N.requestFullscreen():N.mozRequestFullScreen?N.mozRequestFullScreen():N.webkitRequestFullScreen&&N.webkitRequestFullScreen(),document.exitFullscreen?document.exitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitCancelFullScreen?document.webkitCancelFullScreen():document.msExitFullscreen&&document.msExitFullscreen(),this.IsFullStatus()?($("img[title='取消全屏']").attr("src",this.uiPath+"/image\\fullscreen1.gif"),$("img[title='取消全屏']").attr("title","全屏")):($("img[title='全屏']").attr("src",this.uiPath+"/image\\escscreen1.gif"),$("img[title='全屏']").attr("title","取消全屏"))},O.prototype.IsFullStatus=function(){return(document.fullscreenEnabled||document.mozFullscreenElement||document.webkitFullscreenElement)!=null},O);function O(){return c!==null&&c.apply(this,arguments)||this}l.MxUiObjectMobile=m},{"../MxFun":27,"./MxUiObject":62}],64:[function(t,e,l){var n,u=this&&this.__extends||(n=function(N,L){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(G,q){G.__proto__=q}||function(G,q){for(var J in q)Object.prototype.hasOwnProperty.call(q,J)&&(G[J]=q[J])})(N,L)},function(N,L){function G(){this.constructor=N}n(N,L),N.prototype=L===null?Object.create(L):(G.prototype=L.prototype,new G)});Object.defineProperty(l,"__esModule",{value:!0}),l.MxUiObjectPC=void 0;var c,y=t("./MxUiObject"),b=t("../MxFun"),m=(u(O,c=y.MxUiObject),O.prototype.onCreate=function(){this.isShowTitle&&this.WriteTitle(),this.WriteStructTree(),this.isEnableLoading&&this.WriteLoading(),this.WriteLayer(),this.WriteTakeColor(),this.WriteLayout(),this.isEnableObjectProperty&&this.WriteObjectProperty(),this.isShowToolbar&&this.WriteToolbar()},O.prototype.onInit=function(){this.InitEvent()},O.prototype.WriteTitle=function(){var N=this.uiPath;document.write("<div id='all'>"),document.write(" <div class='bar1'>"),document.write(" <img src="+N+"/image/mxcad.png style='height: 50%;position: absolute;top: 12px;left: 10px;'>"),document.write(" <span class='barspan' style='position: absolute;left: 45px;'>"),document.write(" </span>"),document.write(" <div id='container'>"),this.isShowMainMenu&&(document.write(" <header>"),document.write(" <div class='wrapper cf'style='z-index: 999'>"),document.write(" <nav id='main-nav' >"),document.write(" </nav>"),document.write(" <a class='toggle'>"),document.write(" <span></span>"),document.write(" </a>"),document.write(" </div>"),document.write(" </header>")),document.write(" </div>"),document.write(" </div>")},O.prototype.WriteStructTree=function(){this.isShowStructTree&&(document.write("<div class='bf-toolbar bf-toolbar bf-tree-toolbar' id='ModelTreeThumbnail' title='目录树'"),document.write("style='position: absolute;left: 10px; top: 97px; ' onclick='uiObj.SwitchShowStructTree()'>"),document.write("<div class='bf-button mxbim-bf-tree' title='目录树'><i class='fa fa-sitemap' aria-hidden='true'></i></div>"),document.write("</div>")),document.write("<div class='bf-panel bf-has-title bf-sizable' id='ModelTreeInterface' title='目录树'"),document.write("style='left:0px; top: 0px; width: 300px; height: 416px;display: none'>"),document.write(" <div class='bf-close' onclick='uiObj.SwitchShowStructTree()'><i class='fa fa-times' aria-hidden='true'></i></div>"),document.write("<div class='bf-title' style='cursor: move; user-select: none;' id='mulushu'>目录树</div>"),document.write("<div class='bf-panel-body' style='padding-top: 36px;'>"),document.write("<div class='bf-panel-header'>"),document.write("<div class='bf-tree-header' style='margin-top: -36px;'>"),document.write("<div class='bf-select bf-select-tree'>"),document.write("<span class='bf-select-current'>构件</span>"),document.write("<ul class='bf-select-list'>"),document.write("<li class='bf-select-option' id='type'>构件</li>"),document.write("<li class='bf-select-option' id='file'>文件</li>"),document.write("<li class='bf-select-option' id='area'>空间</li>"),document.write("<li class='bf-select-option' id='drawing'>图纸</li>"),document.write("</ul>"),document.write("</div>"),document.write("</div>"),document.write("</div>"),document.write("<div id='DirectoryContent' class='bf-panel-container TreeInfo'>"),document.write("</div>"),document.write("</div>"),document.write("</div>")},O.prototype.WriteLoading=function(){var N=this.uiPath;document.write("<div class='Prompt'>"),document.write("<div style='text-align: center;'>"),document.write("<img src='"+N+"/image/loading.gif' alt='' style='width:30px;height:30px;float: left'>"),document.write("<p style='color:black;vertical-align: middle;float: left; margin-top: 5px;margin-left: 5px;'>加载中.....</p>"),document.write("</div>"),document.write("<span style='display: none'>"+this.sLanguageTable.openComplete+"</span>"),document.write("</div>")},O.prototype.WriteLayer=function(){var N=this.uiPath;this.isShowLayer&&(document.write("<div class='bf-toolbar bf-toolbar bf-tree-toolbar' id='LayerThumbnail' title='"+this.sLanguageTable.layer+"'"),document.write("style='position: absolute;left: 10px; top: 45px; ' onclick='uiObj.SwitchShowLayer()'>"),document.write("<div class='bf-button'>"),document.write("<img src='"+N+"/image/layer.png.gif' alt='' style='width: 32px;'>"),document.write("</div>"),document.write("</div>")),document.write("<div class='bf-panel bf-has-title bf-sizable' id='LayerInterface'"),document.write("style='left: 10px; top: 50px; width: 300px; height: 416px;display: none'>"),document.write("<div class='bf-close' onclick='uiObj.SwitchShowLayer(false)'><i class='fa fa-times' aria-hidden='true'></i></div>"),document.write("<div class='bf-title' id='tuceng' style='cursor: move; user-select: none;'>"+this.sLanguageTable.layer+"</div>"),document.write("<div>"),document.write("<div class='layer-title' style='width: 50px;font-size: 14px'>"+this.sLanguageTable.visible+"</div>"),document.write("<div class='layer-title' style='width: 50px;font-size: 14px'>"+this.sLanguageTable.color+"</div>"),document.write("<div class='layer-title' style='width: 148px;font-size: 14px'>"+this.sLanguageTable.name+"</div>"),document.write("<div class='layer-title' style='width: 50px;font-size: 14px'>"+this.sLanguageTable.status+"</div>"),document.write("</div>"),document.write("<div id='Layer-Info' style='margin-top: 25px;height: 349px;position: absolute;overflow-y: auto;'>"),document.write("</div>"),document.write("</div>")},O.prototype.WriteTakeColor=function(){var N=this.uiPath;this.isShowTakeColor&&(document.write("<div class='bf-toolbar bf-toolbar bf-tree-toolbar' id='TakeColor' title='选择颜色'"),document.write("style='position: absolute;left: 10px; top: 149px; '>"),document.write("<div class='bf-button' onclick='uiObj.Chosecolor()' style='opacity: 1;'>"),document.write("<img src='"+N+"/image/color.png' alt='' style='width: 40px;margin-left: -10px;'>"),document.write("<div id='colorbox' style='width: 35px;height: 5px;background-color: #cccccc;margin-left: -3px'>"),document.write("</div>"),document.write("<div style='width: 18px;height: 40px;float: right;margin-top: -42px;margin-left: 14px;'>"),document.write("<img src='"+N+"/image/daojiao.png' alt='' style='width: 15px;margin-top: 10px;z-index: 999;position: relative'>"),document.write("<input id='color-picker' type='color' value='#c0c0c0' style='display: none' onchange='uiObj.ColorChange(value)'>"),document.write("</div>"),document.write("</div>"),document.write("</div>"))},O.prototype.WriteLayout=function(){var N=this.uiPath;this.isShowLayout&&(document.write("<div class='bf-toolbar bf-toolbar bf-tree-toolbar' id='LayerOut' title='"+this.sLanguageTable.layout+"'"),document.write("style='position: absolute;left: 10px; top: 97px; ' onclick='uiObj.SwitchShowLayout()'>"),document.write("<div class='bf-button'>"),document.write("<img src='"+N+"/image/layout.png' alt='' style='width: 32px;'>"),document.write("</div>"),document.write("</div>")),document.write("<div class='bf-panel bf-has-title bf-sizable' id='LayerOutInterface'"),document.write("style='left: 10px; top: 50px; width: 300px;display:none'>"),document.write("<div class='bf-close' onclick='uiObj.SwitchShowLayout()'><i class='fa fa-times' aria-hidden='true'></i></div>"),document.write("<div class='bf-title' id='buju' style='cursor: move; user-select: none;'>"+this.sLanguageTable.layout+"</div>"),document.write("<div>"),document.write("</div>"),document.write("<div id='layout-Info'>"),document.write("</div>"),document.write("</div>")},O.prototype.WriteObjectProperty=function(){document.write("<div class='bf-panel bf-has-title bf-sizable' id='StrcutInfoBase' title='属性'"),document.write("style='right: 10px; top: 45px; width: 300px; height: 416px;display: none'>"),document.write("<div class='bf-close' id='close2'><i class='fa fa-times' aria-hidden='true'></i></div>"),document.write("<div class='bf-title' style='cursor: move; user-select: none;'>属性</div>"),document.write("<div id='ComponentContent' class='bf-panel-body StructInfo'></div>"),document.write("<div class='bf-resize'></div>"),document.write("</div>")},O.prototype.WriteToolbar=function(){document.write("<div id='MainMenuContent' class='bf-toolbar bf-toolbar-bottom' style='position: fixed'></div>")},O.prototype.CreateToolBar=function(N){if(this.isShowToolbar){var L="";for(var G in N){var q=N[G],J="uiObj.CallMxCommand";q.isMxCommand||(J="uiObj.EvalJs"),0<q.itemid.length?L+='<div class="bf-button" onclick="'+J+"('"+N[G].evalString+`')"><img class="mainimage-bf-butto" id="`+q.itemid+'" src="'+this.uiPath+"\\image\\"+q.image+'" title="'+N[G].text+'"></div>':L+='<div class="bf-button" onclick="'+J+"('"+N[G].evalString+`')"><img class="mainimage-bf-butto" src="`+this.uiPath+"\\image\\"+q.image+'" title="'+N[G].text+'"></div>'}document.getElementById("MainMenuContent").innerHTML=L}},O.prototype.UpDisplayLayer=function(){var N=this.uiPath,L=this.vecLayerData,G=this.vecSketchLayerData,q="";if(G!=null){var J=G;for(var fe in J){q+="<div>";var ve="hide.png";J[fe].off==0&&(ve="show.png");var ne="unlock.png";q+="<table class='bf-table'>",q+="<tbody class='bf-group'>",q+="<tr class='bf-group-title'>",q+='<td><img class="layer-enable" sketch=1 id='+J[fe].id+' src="'+N+"/image/"+ve+'"/></td>',q+='<td><span class="layer-color" style="background-color:'+J[fe].color+'"></span></td>',q+='<td><span class="layer-text">草图_'+J[fe].name+"</span></td>",q+='<td><img class="layer-state" src="'+N+"/image/"+ne+'"/></td>',q+="</tr>",q+="</tbody>",q+="</table>",q+="</div>"}}if(L!=null)for(var fe in J=L)q+="<div>",ve="hide.png",J[fe].off==0&&(ve="show.png"),ne="lock.png",q+="<table class='bf-table'>",q+="<tbody class='bf-group'>",q+="<tr class='bf-group-title'>",q+='<td><img class="layer-enable" sketch=0 id='+J[fe].id+' src="'+N+"/image/"+ve+'"/></td>',q+='<td><span class="layer-color" style="background-color:'+J[fe].color+'"></span></td>',q+='<td><span class="layer-text">'+J[fe].name+"</span></td>",q+='<td><img class="layer-state" src="'+N+"/image/"+ne+'"/></td>',q+="</tr>",q+="</tbody>",q+="</table>",q+="</div>";var Ue=document.getElementById("Layer-Info");Ue!=null&&(Ue.innerHTML=q)},O.prototype.UpDisplayLayout=function(){var N=this.vecLayoutData,L="";if(L+="<div>",L+="<table class='bf-table'>",L+="<tbody class='bf-group'>",L+="<tr class='bf-group-title bf_layerout' style='height: 30px;cursor: pointer;'>",L+="<td class='bf_layerout_td' style='width: 60px' >",L+="<div class='bf_layer_div layer_on'></div>",L+="</td>",L+="<td style='width: 238px' >",L+="<span class='layout-name' name='Model' style='color: white;cursor: pointer;'>Model</span>",L+="</td>",L+="</tr>",N!=null){var G=N;for(var q in G)L+="<tr class='bf-group-title bf_layerout' style='height: 30px;cursor: pointer;'>",L+="<td class='bf_layerout_td' style='width: 60px' >",L+="<div class='bf_layer_div layer_on'></div>",L+="</td>",L+="<td style='width: 238px' >",L+="<span class='layout-name' name='"+G[q]+"' style='color: white;cursor: pointer;'>"+G[q]+"</span>",L+="</td>",L+="</tr>"}L+="</tbody>",L+="</table>",L+="</div>";var J=document.getElementById("layout-Info");J!=null&&(J.innerHTML=L)},O.prototype.InitEvent=function(){var N=document.getElementById("ModelTreeInterface"),L=document.getElementById("LayerInterface"),G=document.getElementById("LayerOutInterface"),q=document.getElementById("tuceng"),J=document.getElementById("mulushu"),fe=document.getElementById("buju"),ve=0,ne=0,Ue=0,De=0,Ve=!1;J.onmousedown=function(pt){ve=pt.clientX,ne=pt.clientY,Ue=N.offsetLeft,De=N.offsetTop,Ve=!0,N.style.cursor="move"},q.onmousedown=function(pt){ve=pt.clientX,ne=pt.clientY,Ue=L.offsetLeft,De=L.offsetTop,Ve=!0,L.style.cursor="move"},fe.onmousedown=function(pt){ve=pt.clientX,ne=pt.clientY,Ue=G.offsetLeft,De=G.offsetTop,Ve=!0,G.style.cursor="move"},window.onmousemove=function(pt){if(Ve!=0){var mt=pt.clientX,Tt=pt.clientY,kt=mt-(ve-Ue),It=Tt-(ne-De);N.style.left=kt+"px",N.style.top=It+"px",L.style.left=kt+"px",L.style.top=It+"px",G.style.left=kt+"px",G.style.top=It+"px"}},J.onmouseup=function(){Ve=!1,N.style.cursor="default"},q.onmouseup=function(){Ve=!1,L.style.cursor="default"},fe.onmouseup=function(){Ve=!1,G.style.cursor="default"},$("#close2").click(function(){$(this).parent("div").fadeOut(200)}),$("#menu4").click(function(){$("#StrcutInfoBase").hasClass("hide")?($("#StrcutInfoBase").fadeIn(200),$("#StrcutInfoBase").removeClass("hide")):($("#StrcutInfoBase").fadeOut(200),$("#StrcutInfoBase").addClass("hide"))}),$(".bf-select-current").click(function(){$(this).hasClass("bf-open")?$(this).removeClass("bf-open"):$(this).addClass("bf-open")}),$(".bf-select-option").click(function(){$(this).parent("ul").prev("span").html($(this).text()),$(this).parent("ul").prev("span").removeClass("bf-open")});var rt=$("#StrcutInfoBase");rt.bind("mousedown",function(pt){var mt=$(this)[0].offsetLeft,Tt=$(this)[0].offsetTop,kt=pt.pageX,It=pt.pageY;$(document).bind("mousemove",function(nn){var tn=nn.pageX-kt,pn=nn.pageY-It,_n=mt+tn+"px",Dn=Tt+pn+"px";rt.css({top:Dn,left:_n})})}),$(document).bind("mouseup",function(){$(this).unbind("mousemove")}),this.CreateToolBar(this.vecToolBarItem);var Ae=this.vecMenuItem;if(this.isShowMainMenu&&function(pt){var mt="";(function pn(_n,Dn){var an=function(Lt,wn){var hn=new Array;for(var xn in wn)wn[xn].parentId==Lt&&hn.push(wn[xn]);return hn}(_n,Dn);if(0<an.length){for(var Rn in mt+="<ul>",an)an[Rn].evalString.length!=0?(mt+='<li><p class="li_option" ',mt+=`onclick="uiObj.EvalJs('`+an[Rn].evalString+`')"`,mt+=">"+an[Rn].text+"</p>"):(mt+="<li><a ",mt+=">"+an[Rn].text+"</a>"),pn(an[Rn].id,Dn),mt+="</li>";mt+="</br>",mt+="</br>",mt+="</br>",mt+="</ul>"}})(-1,Ae),pt("#main-nav").append(mt);var Tt=pt("#main-nav"),kt=pt(".toggle"),It={maxWidth:!1,customToggle:kt,levelTitles:!0},nn=null,tn={};nn&&nn.remove(),kt.off("click"),nn=Tt.clone(),pt.extend(tn,{side:"right"}),nn.hcMobileNav(pt.extend({},It,tn))}(jQuery),$(".li_option").click(function(){var pt=$(this);$(".li_option").each(function(){$(this).removeClass("active")}),pt.addClass("active")}),this.sTitle==""){var Te=window.location.href,Xe=Te.length,ie=Te.indexOf("?"),ue=Te.substr(ie,Xe).split("=")[1];ue!=null&&(this.sTitle=ue)}$(".barspan").html(decodeURIComponent(this.sTitle)),$(document).on("click",".layer-enable",function(){var pt=b.MxFun.getUiObj().getPath(),mt=parseInt($(this).attr("id")),Tt=(parseInt($(this).attr("sketch")),!0);$(this).attr("src")==pt+"/image/show.png"?($(this).attr("src",pt+"/image/hide.png"),Tt=!1):$(this).attr("src",pt+"/image/show.png"),b.MxFun.showLayer(mt,Tt)}),$(document).on("click",".layout-name",function(){var pt=$(this).attr("name");pt=="Model"&&(pt=""),b.MxFun.getCurrentDraw().gotoLayout(pt)})},O.prototype.WriteFooter=function(){document.write("<div class='footer' style='background: rgba(0, 0, 0, 0.7);position: fixed;left: 0;bottom: 0;width: 100%;'>"),document.write(" <div style='line-height: 40px;font-size: 12px;color: #999;padding: 0 10px;'>"),document.write(" <p style='float: right;line-height: 15px;font-size: 12px;color: #999;display: block;'>"),document.write(" <a style='color: #4a90e2;text-decoration: none;outline: none;' href='http://www.mxdraw.com/' target='_blank'>MxDraw </a>旗下产品"),document.write(" </p>"),document.write(" <a style='color: #4a90e2;text-decoration: none;outline: none;' href='http://www.mxdraw.com' target='_blank'>MX3D </a> 蜀ICP备15011727号"),document.write(" </div>"),document.write(" </div>")},O.prototype.ShowLoading=function(){this.isEnableLoading&&($(".Prompt").css("background","rgba(0, 0, 0, 0)"),$(".Prompt").fadeIn(100),$(".Prompt span").css("display","none"))},O.prototype.HideLoading=function(){this.isEnableLoading&&($(".Prompt").css("background","rgba(0, 0, 0, 0.8)"),$(".Prompt div").fadeOut(100),$(".Prompt span").fadeIn(200),setTimeout(function(){$(".Prompt").fadeOut(1e3)},1e3))},O.prototype.ShowObjectProperty=function(N){if(N.length!=0){var L;L=typeof N=="string"?JSON.parse(N):N;var G="";for(var q in L){var J=L[q];for(var fe in G+="<table class='bf-table'>",G+="<tbody class='bf-group'>",G+="<tr class='bf-group-title'>",G+="<td colspan='2'><i class='bf-icon'></i>"+J.name+"</td>",G+="</tr>",J.datas){var ve=J.datas[fe];G+="<tr class='bf-group-content'>",G+="<td class='bf-key'>"+ve.name+"</td>",G+="<td class='bf-value'>"+ve.value+"</td>",G+="</tr>"}G+="</tbody>",G+="</table>"}document.getElementById("ComponentContent").innerHTML=G,$(".bf-group").click(function(){$(this).hasClass("bf-collapse")?$(this).removeClass("bf-collapse"):$(this).addClass("bf-collapse")}),$("#StrcutInfoBase").fadeIn(200),$("#StrcutInfoBase").removeClass("hide")}},O.prototype.HideObjectProp=function(){$("#StrcutInfoBase").hasClass("hide")||($("#StrcutInfoBase").fadeOut(200),$("#StrcutInfoBase").addClass("hide"))},O.prototype.SwitchShowLayer=function(){var N=document.getElementById("ModelTreeInterface"),L=document.getElementById("ModelTreeThumbnail"),G=document.getElementById("LayerThumbnail"),q=document.getElementById("LayerInterface"),J=document.getElementById("LayerOut"),fe=document.getElementById("LayerOutInterface");N.style.display="none",(fe.style.display="none")==q.style.display?(G.style.display="block",q.style.display="block",q.style.left="80px",q.style.top="50px",L!=null&&(L.style.display="block"),J!=null&&(J.style.display="block"),N.style.display="none",fe.style.display="none"):(q.style.display="none",L!=null&&(L.style.display="block"),G.style.display="block",J!=null&&(J.style.display="block"))},O.prototype.SwitchShowStructTree=function(){var N=document.getElementById("ModelTreeInterface"),L=document.getElementById("ModelTreeThumbnail"),G=document.getElementById("LayerThumbnail"),q=document.getElementById("LayerInterface"),J=document.getElementById("LayerOut"),fe=document.getElementById("LayerOutInterface");q.style.display="none",(fe.style.display="none")==N.style.display?(L!=null&&(L.style.display="block"),N.style.display="block",N.style.left="80px",N.style.top="50px",G.style.display="block",J!=null&&(J.style.display="block"),q.style.display="none",fe.style.display="none"):(N.style.display="none",L!=null&&(L.style.display="block"),G.style.display="block",J!=null&&(J.style.display="block"))},O.prototype.Chosecolor=function(){document.getElementById("color-picker").click()},O.prototype.ColorChange=function(N){document.getElementById("colorbox").style.backgroundColor=N,b.MxFun.setCurrentColor(N)},O.prototype.SwitchShowLayout=function(){var N=document.getElementById("ModelTreeInterface"),L=document.getElementById("ModelTreeThumbnail"),G=document.getElementById("LayerThumbnail"),q=document.getElementById("LayerInterface"),J=document.getElementById("LayerOut"),fe=document.getElementById("LayerOutInterface");N.style.display="none",q.style.display="none",fe&&fe.style.display=="none"?(J&&(J.style.display="block"),fe.style.display="block",fe.style.left="80px",fe.style.top="120px",L!=null&&(L.style.display="block"),G&&(G.style.display="block"),N.style.display="none",q.style.display="none"):(fe&&(fe.style.display="none"),L!=null&&(L.style.display="block"),G&&(G.style.display="block"),J&&(J.style.display="block"))},O.prototype.Fullscreen=function(){var N=document.documentElement;N.requestFullscreen?N.requestFullscreen():N.mozRequestFullScreen?N.mozRequestFullScreen():N.webkitRequestFullScreen&&N.webkitRequestFullScreen(),document.exitFullscreen?document.exitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitCancelFullScreen?document.webkitCancelFullScreen():document.msExitFullscreen&&document.msExitFullscreen(),this.IsFullStatus()?($("img[title='取消全屏']").attr("src",this.uiPath+"/image\\fullscreen1.gif"),$("img[title='取消全屏']").attr("title","全屏")):($("img[title='全屏']").attr("src",this.uiPath+"/image\\escscreen1.gif"),$("img[title='全屏']").attr("title","取消全屏"))},O.prototype.IsFullStatus=function(){return(document.fullscreenEnabled||document.mozFullscreenElement||document.webkitFullscreenElement)!=null},O);function O(){return c!==null&&c.apply(this,arguments)||this}l.MxUiObjectPC=m},{"../MxFun":27,"./MxUiObject":62}],65:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxUiVue=void 0;var n,u,c,y,b=t("three"),m=t("../MxFun"),O=t("../Operate/MxJigCmdManager"),N=t("../MxTools"),L=t("../Operate/MxCmdRunManager");function G(De){if(De==32||De==13)if(O.MxJigCmdManager.isRunning())O.MxJigCmdManager.OnEnter(De);else{var Ve=ve(),rt="";rt=Ve.length==0?L.MxCmdRunManager.GetPrvCmd():Ve,ne(""),rt=N.MxTools.stringTrimLeftSpace(rt),m.MxFun.sendStringToExecute(rt)}else if(De==38)O.MxJigCmdManager.isRunning()||(L.MxCmdRunManager.MoveUpKey(),(Ae=L.MxCmdRunManager.GetListCommad()).length!=0&&(ne(Ae),fe()));else if(De==40){var Ae;O.MxJigCmdManager.isRunning()||(L.MxCmdRunManager.MoveDownKey(),(Ae=L.MxCmdRunManager.GetListCommad()).length!=0&&(ne(Ae),fe()))}}function q(De,Ve){Ve===void 0&&(Ve=!0);var rt=De.length;if(!(rt<1)){for(var Ae=c.getCmdLine(),Te=Ae.getCmdTip(),Xe=Ae.getCmdText(),ie=De.indexOf(`
- `),ue=0,pt=!0;ie!=-1&&(pt?(Ae.addCmdDisplay(`
- `+Te+Xe+De.substring(ue,ie-ue)),Xe=Te="",pt=!1):Ae.addCmdDisplay(`
- `+De.substring(ue,ie-ue)),(ue=ie+1)<rt);)ie=De.indexOf(`
- `,ue);if(pt){var mt=De.substring(ue,rt-ue),Tt=mt.indexOf("\r"),kt=mt.length;Te=Tt==-1?Te+Xe+mt:Tt+1<kt?mt.substring(Tt+1,kt-Tt-1):""}else ue<rt&&(Te=De.substring(ue,rt));Xe="",Ve&&(Te+=" "),Ae.setCmdTip(Te),Ae.setCmdText(Xe),Ae.upDisplay()}}function J(De){for(var Ve=[],rt=1;rt<arguments.length;rt++)Ve[rt-1]=arguments[rt];if(c!=null){for(var Ae=arguments,Te=Ae[0],Xe=0;Xe<Ae.length-1;Xe++){var ie=new RegExp("\\{"+Xe+"\\}","gm");Te=Te.replace(ie,Ae[Xe+1])}q(Te,!0)}}function fe(){c?.getCmdLine().upDisplay()}function ve(){if(c==null)return"";var De=c.getCmdLine();return N.MxTools.stringTrimLeftRightSpace(De.getCmdText())}function ne(De){if(c!=null)return c.getCmdLine().setCmdText(De)}function Ue(De){var Ve=O.MxJigCmdManager.getCurCmd();Ve!=null&&(Ve.getDynImput().onKeyDonw(De)||G(De))}n=l.MxUiVue||(l.MxUiVue={}),c=void 0,y=new b.Vector3,n.SetLasetPoint=function(De){y=De},n.GetLasetPoint=function(){return y},(u=n.CursorType||(n.CursorType={}))[u.kNormal=0]="kNormal",u[u.kRect=1]="kRect",u[u.kCross=2]="kCross",u[u.kPan=3]="kPan",n.isNull=function(){return c==null},n.init=function(De){(c=De).mountKeydownEvent(G),c.getDynamicInput().mountKeydownEvent(Ue)},n.setTipCoord=function(De){c?.setTipCoord(De)},n.setCursorType=function(De){c?.setCursorType(De)},n.AcutPrintfNoFormat=q,n.acutPrintf=J,n.cmdLineUpDisplay=fe,n.getCmdText=ve,n.setCmdText=ne,n.getCmdDisplay=function(){return c==null?"":c.getCmdLine().getCmdDisplay()},n.setCmdDisplay=function(De){if(c!=null)return c.getCmdLine().setCmdDisplay(De)},n.getCmdTip=function(){return c==null?"":c.getCmdLine().getCmdTip()},n.setCmdTip=function(De){if(c!=null)return c.getCmdLine().setCmdTip(De)},n.restoreCmdStatus=function(){if(c!=null){var De=c.getCmdLine();De.getCmdTip()==" "&&De.getCmdText().length==0?(De.setCmdTip(""),J("{0}:","命令")):J(`
- {0}:`,"命令")}},n.DynamicInput_upDisplay=function(){c!=null&&n.OnMxEvent({name:"dynInputUpDisplay"})},n.DynamicInput_setType=function(De){c?.getDynamicInput().setType(De)},n.DynamicInput_getType=function(){return c==null?O.MxJigCmdManager.DynamicInputType.kNoInput:c.getDynamicInput().getType()},n.DynamicInput_setPos=function(De){c?.getDynamicInput().setPos([De.x,De.y])},n.DynamicInput_setTip=function(De){c?.getDynamicInput().setTip(De)},n.DynamicInput_setValue1=function(De){c?.getDynamicInput().setValue1(De)},n.DynamicInput_getValue1=function(){return c==null?"":c.getDynamicInput().getValue1()},n.DynamicInput_setValue1Pos=function(De){c?.getDynamicInput().setValue1Pos([De.x,De.y])},n.DynamicInput_setValue2=function(De){c?.getDynamicInput().setValue2(De)},n.DynamicInput_getValue2=function(){return c==null?"":c.getDynamicInput().getValue2()},n.DynamicInput_getFocusValue=function(){return c==null?"":c.getDynamicInput().getFocusValue()},n.DynamicInput_getFocusIndex=function(){return c==null?0:c.getDynamicInput().getFocusIndex()},n.DynamicInput_setValue2Pos=function(De){c?.getDynamicInput().setValue2Pos([De.x,De.y])},n.DynamicInput_setShow=function(De){c?.getDynamicInput().setShow(De)},n.DynamicInput_isShow=function(){return c!=null&&c.getDynamicInput().isShow()},n.OnMxEvent=function(De){if(c==null)return!1;c.OnMxEvent(De)}},{"../MxFun":27,"../MxTools":38,"../Operate/MxCmdRunManager":48,"../Operate/MxJigCmdManager":54,three:19}],66:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.ExternalReferenceManager=l.ExternalReferenceDatabase=l.Blocks=l.Block=l.Layer=l.MxNewDisplayMemorySection=l.MxNewDisplayMemorySectionType=l.TextureData=l.BlockInstance=l.BlockRef=l.ClipPlans=l.ClipPlan=void 0;var n=t("three"),u=t("../MxShader"),c=t("./MxBrowseLayerData"),y=t("../MxManager"),b=t("../MxNetData"),m=t("../MxStencilObject"),O=t("../MxFun"),N=function(){this.x1=0,this.y1=0,this.x2=0,this.y2=0};l.ClipPlan=N;var L=function(){this.ver=4,this.id=1,this.clipPlanArray=new Array,this.clipPoints=[],this.instansClipePoints=[]};l.ClipPlans=L;var G=function(){this.ver=4,this.mat=new n.Matrix4,this.blkRecId=-1,this.blkOwnerId=0,this.layerId=-1,this.color=16777215,this.clipPlans=new L};l.BlockRef=G;var q=function(){this.mat=new n.Matrix4,this.color=new Array,this.topLayerColor=new Array,this.clipPlans=new L,this.clipMat=new n.Matrix4};l.BlockInstance=q;var J,fe,ve=function(){};l.TextureData=ve,(fe=J=l.MxNewDisplayMemorySectionType||(l.MxNewDisplayMemorySectionType={}))[fe.kLinesType=1]="kLinesType",fe[fe.kTriangleType=2]="kTriangleType",fe[fe.kLinesType_Float=3]="kLinesType_Float",fe[fe.kTriangleType_Float=4]="kTriangleType_Float",fe[fe.kPointType_Float=5]="kPointType_Float",fe[fe.kPointType=6]="kPointType",l.MxNewDisplayMemorySection=function(){this.id=0,this.type=J.kLinesType,this.blockId=0,this.layerId=0,this.color=0,this.points=[]};var ne=(Ue.prototype.Show=function(ue){for(var pt=0,mt=this._entitys.length;pt<mt;pt++)this._entitys[pt].visible=ue},Ue.prototype.updataClipMaterial=function(ue){for(var pt=this._material_clip.length,mt=.5*ue.width,Tt=.5*ue.height,kt=0;kt<pt;kt++)this._material_clip[kt].uniforms.vieww.value=mt,this._material_clip[kt].uniforms.viewh.value=Tt},Ue.prototype.createThreejsObjForMesh_Clip=function(ue,pt,mt){ue.size!=0&&ue.forEach(function(Tt){var kt=Tt;if(kt.length!=0){var It=[],nn=[],tn=kt[0].clipPlans;tn.ver<=3&&(It.push(tn.clipPlanArray[0].x1,tn.clipPlanArray[0].y1),nn.push(tn.clipPlanArray[0].x2,tn.clipPlanArray[0].y2));for(var pn=[],_n=[],Dn=[],an=[],Rn=[],Lt=[],wn=[],hn=0;hn<kt.length;hn++){var xn=kt[hn];pn=pn.concat(xn.mat.elements.slice(0,4)),_n=_n.concat(xn.mat.elements.slice(4,8)),Dn=Dn.concat(xn.mat.elements.slice(8,12)),an=an.concat(xn.mat.elements.slice(12,16)),Rn.push(0),Lt=Lt.concat(kt[hn].color)}if(0<this._geometryMeshPositionsByBlock.length)for(hn=0;hn<kt.length;hn++)Lt=Lt.concat(kt[hn].color);if(0<this._geometryMeshPositionsByBlock_ZeroLayer.length)for(hn=0;hn<kt.length;hn++)wn=wn.concat(kt[hn].topLayerColor);var $n,Xr=.5*mt.width,ti=.5*mt.height;tn.ver<=3?($n=new n.RawShaderMaterial({uniforms:{clippt1:{value:It},clippt2:{value:nn},vieww:{value:Xr},viewh:{value:ti}},vertexShader:u.MxShader.VSHADER_COLOR_POINT_CLIP,fragmentShader:u.MxShader.FSHADER_COLOR_POINT_CLIP,linewidth:1,transparent:!0,side:n.DoubleSide}),this._material_clip.push($n)):$n=new n.RawShaderMaterial({vertexShader:u.MxShader.VSHADER_COLOR_POINT,fragmentShader:u.MxShader.FSHADER_COLOR_POINT,linewidth:1,transparent:!0,side:n.DoubleSide});for(var gn=0;gn<this._geometryMeshPostion.length;gn++)(Kn=new n.InstancedBufferGeometry).maxInstancedCount=kt.length,Kn.setAttribute("position",new n.Float32BufferAttribute(this._geometryMeshPostion[gn],2)),Kn.setAttribute("color",new n.Float32BufferAttribute(this._geometryMeshColor[gn],3)),Kn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(pn),4)),Kn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(_n),4)),Kn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(Dn),4)),Kn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(an),4)),Kn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(Rn),1)),(Vn=new n.Mesh(Kn,$n)).frustumCulled=!1,Vn.renderOrder=y.MxData.iCADMeshRenderOrder,pt.add(Vn),this._entitys.push(Vn),4<=tn.ver&&0<tn.instansClipePoints.length&&new m.MxStencilObject().associateObject(Vn,tn.instansClipePoints);for(gn=0;gn<this._geometryMeshPositionsByBlock.length;gn++)(Kn=new n.InstancedBufferGeometry).maxInstancedCount=kt.length,Kn.setAttribute("position",new n.Float32BufferAttribute(this._geometryMeshPositionsByBlock[gn],2)),Kn.setAttribute("color",new n.InstancedBufferAttribute(new Float32Array(Lt),3)),Kn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(pn),4)),Kn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(_n),4)),Kn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(Dn),4)),Kn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(an),4)),Kn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(Rn),1)),(Vn=new n.Mesh(Kn,$n)).frustumCulled=!1,Vn.renderOrder=y.MxData.iCADMeshRenderOrder,pt.add(Vn),this._entitys.push(Vn),4<=tn.ver&&0<tn.instansClipePoints.length&&new m.MxStencilObject().associateObject(Vn,tn.instansClipePoints);for(gn=0;gn<this._geometryMeshPositionsByBlock_ZeroLayer.length;gn++)(Kn=new n.InstancedBufferGeometry).maxInstancedCount=kt.length,Kn.setAttribute("position",new n.Float32BufferAttribute(this._geometryMeshPositionsByBlock_ZeroLayer[gn],2)),Kn.setAttribute("color",new n.InstancedBufferAttribute(new Float32Array(wn),3)),Kn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(pn),4)),Kn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(_n),4)),Kn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(Dn),4)),Kn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(an),4)),Kn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(Rn),1)),(Vn=new n.Mesh(Kn,$n)).frustumCulled=!1,Vn.renderOrder=y.MxData.iCADMeshRenderOrder,pt.add(Vn),this._entitys.push(Vn),4<=tn.ver&&0<tn.instansClipePoints.length&&new m.MxStencilObject().associateObject(Vn,tn.instansClipePoints);var Xn=new n.RawShaderMaterial({uniforms:{color:{value:this._color},clippt1:{value:It},clippt2:{value:nn},vieww:{value:Xr},viewh:{value:ti}},vertexShader:u.MxShader.VSHADER_COLOR_POINT_BYLAYER_CLIP,fragmentShader:u.MxShader.FSHADER_COLOR_POINT_CLIP,linewidth:1,transparent:!0,side:n.DoubleSide});for(this._material_clip.push(Xn),gn=0;gn<this._geometryMeshPositionsByLayer.length;gn++){var Kn,Vn;(Kn=new n.InstancedBufferGeometry).maxInstancedCount=kt.length,Kn.setAttribute("position",new n.Float32BufferAttribute(this._geometryMeshPositionsByLayer[gn],2)),Kn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(pn),4)),Kn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(_n),4)),Kn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(Dn),4)),Kn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(an),4)),Kn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(Rn),1)),(Vn=new n.Mesh(Kn,Xn)).frustumCulled=!1,Vn.renderOrder=y.MxData.iCADMeshRenderOrder,pt.add(Vn),this._entitys.push(Vn),4<=tn.ver&&0<tn.instansClipePoints.length&&new m.MxStencilObject().associateObject(Vn,tn.instansClipePoints)}}},this)},Ue.prototype.createThreejsObjForCurve_Clip=function(ue,pt,mt){ue.size!=0&&ue.forEach(function(Tt,kt,It){var nn=Tt;if(nn.length!=0){var tn=[],pn=[],_n=nn[0].clipPlans;_n.ver<=3&&(tn.push(_n.clipPlanArray[0].x1,_n.clipPlanArray[0].y1),pn.push(_n.clipPlanArray[0].x2,_n.clipPlanArray[0].y2));for(var Dn=[],an=[],Rn=[],Lt=[],wn=[],hn=[],xn=[],$n=0;$n<nn.length;$n++){var Xr=nn[$n];Dn=Dn.concat(Xr.mat.elements.slice(0,4)),an=an.concat(Xr.mat.elements.slice(4,8)),Rn=Rn.concat(Xr.mat.elements.slice(8,12)),Lt=Lt.concat(Xr.mat.elements.slice(12,16)),wn.push(0)}if(0<this._geometryCurvePositionsByBlock.length)for($n=0;$n<nn.length;$n++)hn=hn.concat(nn[$n].color);if(0<this._geometryCurvePositionsByBlock_ZeroLayer.length)for($n=0;$n<nn.length;$n++)xn=xn.concat(nn[$n].topLayerColor);var ti,gn=.5*mt.width,Xn=.5*mt.height;_n.ver<=3?(ti=new n.RawShaderMaterial({uniforms:{clippt1:{value:tn},clippt2:{value:pn},vieww:{value:gn},viewh:{value:Xn}},vertexShader:u.MxShader.VSHADER_COLOR_POINT_CLIP,fragmentShader:u.MxShader.FSHADER_COLOR_POINT_CLIP,linewidth:1,transparent:!0,side:n.DoubleSide}),this._material_clip.push(ti)):ti=new n.RawShaderMaterial({vertexShader:u.MxShader.VSHADER_COLOR_POINT,fragmentShader:u.MxShader.FSHADER_COLOR_POINT,linewidth:1,transparent:!0,side:n.DoubleSide});for(var Kn=0;Kn<this._geometryCurvePostion.length;Kn++)(Yn=new n.InstancedBufferGeometry).maxInstancedCount=nn.length,Yn.setAttribute("position",new n.Float32BufferAttribute(this._geometryCurvePostion[Kn],2)),Yn.setAttribute("color",new n.Float32BufferAttribute(this._geometryCurveColor[Kn],3)),Yn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(Dn),4)),Yn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(an),4)),Yn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(Rn),4)),Yn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(Lt),4)),Yn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(wn),1)),(Vr=new n.LineSegments(Yn,ti)).frustumCulled=!1,Vr.renderOrder=y.MxData.iCADCurveRenderOrder,pt.add(Vr),this._entitys.push(Vr),4<=_n.ver&&0<_n.instansClipePoints.length&&new m.MxStencilObject().associateObject(Vr,_n.instansClipePoints);for(Kn=0;Kn<this._geometryCurvePositionsByBlock.length;Kn++)(Yn=new n.InstancedBufferGeometry).maxInstancedCount=nn.length,Yn.setAttribute("position",new n.Float32BufferAttribute(this._geometryCurvePositionsByBlock[Kn],2)),Yn.setAttribute("color",new n.InstancedBufferAttribute(new Float32Array(hn),3)),Yn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(Dn),4)),Yn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(an),4)),Yn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(Rn),4)),Yn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(Lt),4)),Yn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(wn),1)),(Vr=new n.LineSegments(Yn,ti)).frustumCulled=!1,Vr.renderOrder=y.MxData.iCADCurveRenderOrder,pt.add(Vr),this._entitys.push(Vr),4<=_n.ver&&0<_n.instansClipePoints.length&&new m.MxStencilObject().associateObject(Vr,_n.instansClipePoints);for(Kn=0;Kn<this._geometryCurvePositionsByBlock_ZeroLayer.length;Kn++)(Yn=new n.InstancedBufferGeometry).maxInstancedCount=nn.length,Yn.setAttribute("position",new n.Float32BufferAttribute(this._geometryCurvePositionsByBlock_ZeroLayer[Kn],2)),Yn.setAttribute("color",new n.InstancedBufferAttribute(new Float32Array(xn),3)),Yn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(Dn),4)),Yn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(an),4)),Yn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(Rn),4)),Yn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(Lt),4)),Yn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(wn),1)),(Vr=new n.LineSegments(Yn,ti)).frustumCulled=!1,Vr.renderOrder=y.MxData.iCADCurveRenderOrder,pt.add(Vr),this._entitys.push(Vr),4<=_n.ver&&0<_n.instansClipePoints.length&&new m.MxStencilObject().associateObject(Vr,_n.instansClipePoints);var Vn=new n.RawShaderMaterial({uniforms:{color:{value:this._color},clippt1:{value:tn},clippt2:{value:pn},vieww:{value:gn},viewh:{value:Xn}},vertexShader:u.MxShader.VSHADER_COLOR_POINT_BYLAYER_CLIP,fragmentShader:u.MxShader.FSHADER_COLOR_POINT_CLIP,linewidth:1,transparent:!0,side:n.DoubleSide});for(this._material_clip.push(Vn),Kn=0;Kn<this._geometryCurvePositionsByLayer.length;Kn++){var Yn,Vr;(Yn=new n.InstancedBufferGeometry).maxInstancedCount=nn.length,Yn.setAttribute("position",new n.Float32BufferAttribute(this._geometryCurvePositionsByLayer[Kn],2)),Yn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(Dn),4)),Yn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(an),4)),Yn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(Rn),4)),Yn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(Lt),4)),Yn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(wn),1)),(Vr=new n.LineSegments(Yn,Vn)).frustumCulled=!1,Vr.renderOrder=y.MxData.iCADCurveRenderOrder,pt.add(Vr),this._entitys.push(Vr),4<=_n.ver&&0<_n.instansClipePoints.length&&new m.MxStencilObject().associateObject(Vr,_n.instansClipePoints)}}},this)},Ue.prototype.createThreejsObjForCurve=function(ue,pt){if(ue.length!=0){for(var mt=[],Tt=[],kt=[],It=[],nn=[],tn=[],pn=[],_n=0;_n<ue.length;_n++){var Dn=ue[_n];mt=mt.concat(Dn.mat.elements.slice(0,4)),Tt=Tt.concat(Dn.mat.elements.slice(4,8)),kt=kt.concat(Dn.mat.elements.slice(8,12)),It=It.concat(Dn.mat.elements.slice(12,16)),nn.push(0)}if(0<this._geometryCurvePositionsByBlock.length)for(_n=0;_n<ue.length;_n++)tn=tn.concat(ue[_n].color);if(0<this._geometryCurvePositionsByBlock_ZeroLayer.length)for(_n=0;_n<ue.length;_n++)pn=pn.concat(ue[_n].topLayerColor);for(var an=new n.RawShaderMaterial({vertexShader:u.MxShader.VSHADER_COLOR_POINT,fragmentShader:u.MxShader.FSHADER_COLOR_POINT,linewidth:1,transparent:!0,side:n.DoubleSide}),Rn=0;Rn<this._geometryCurvePostion.length;Rn++)(wn=new n.InstancedBufferGeometry).maxInstancedCount=ue.length,wn.setAttribute("position",new n.Float32BufferAttribute(this._geometryCurvePostion[Rn],2)),wn.setAttribute("color",new n.Float32BufferAttribute(this._geometryCurveColor[Rn],3)),wn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(mt),4)),wn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(Tt),4)),wn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(kt),4)),wn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(It),4)),wn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(nn),1)),(hn=new n.LineSegments(wn,an)).frustumCulled=!1,hn.renderOrder=y.MxData.iCADCurveRenderOrder,pt.add(hn),this._entitys.push(hn);for(Rn=0;Rn<this._geometryCurvePositionsByBlock.length;Rn++)(wn=new n.InstancedBufferGeometry).maxInstancedCount=ue.length,wn.setAttribute("position",new n.Float32BufferAttribute(this._geometryCurvePositionsByBlock[Rn],2)),wn.setAttribute("color",new n.InstancedBufferAttribute(new Float32Array(tn),3)),wn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(mt),4)),wn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(Tt),4)),wn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(kt),4)),wn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(It),4)),wn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(nn),1)),(hn=new n.LineSegments(wn,an)).frustumCulled=!1,hn.renderOrder=y.MxData.iCADCurveRenderOrder,pt.add(hn),this._entitys.push(hn);for(Rn=0;Rn<this._geometryCurvePositionsByBlock_ZeroLayer.length;Rn++)(wn=new n.InstancedBufferGeometry).maxInstancedCount=ue.length,wn.setAttribute("position",new n.Float32BufferAttribute(this._geometryCurvePositionsByBlock_ZeroLayer[Rn],2)),wn.setAttribute("color",new n.InstancedBufferAttribute(new Float32Array(pn),3)),wn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(mt),4)),wn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(Tt),4)),wn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(kt),4)),wn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(It),4)),wn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(nn),1)),(hn=new n.LineSegments(wn,an)).frustumCulled=!1,hn.renderOrder=y.MxData.iCADCurveRenderOrder,pt.add(hn),this._entitys.push(hn);var Lt=new n.RawShaderMaterial({uniforms:{color:{value:this._color}},vertexShader:u.MxShader.VSHADER_COLOR_POINT_BYLAYER,fragmentShader:u.MxShader.FSHADER_COLOR_POINT,linewidth:1,transparent:!0,side:n.DoubleSide});for(Rn=0;Rn<this._geometryCurvePositionsByLayer.length;Rn++){var wn,hn;(wn=new n.InstancedBufferGeometry).maxInstancedCount=ue.length,wn.setAttribute("position",new n.Float32BufferAttribute(this._geometryCurvePositionsByLayer[Rn],2)),wn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(mt),4)),wn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(Tt),4)),wn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(kt),4)),wn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(It),4)),wn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(nn),1)),(hn=new n.LineSegments(wn,Lt)).frustumCulled=!1,hn.renderOrder=y.MxData.iCADCurveRenderOrder,pt.add(hn),this._entitys.push(hn)}}},Ue.prototype.createThreejsObjForMemorySections_clip=function(ue,pt,mt){ue.size!=0&&ue.forEach(function(Tt){var kt=Tt;if(kt.length!=0){for(var It=kt[0].clipPlans,nn=[],tn=[],pn=[],_n=[],Dn=[],an=0;an<kt.length;an++){var Rn=kt[an];nn.push.apply(nn,Rn.mat.elements.slice(0,4)),tn.push.apply(tn,Rn.mat.elements.slice(4,8)),pn.push.apply(pn,Rn.mat.elements.slice(8,12)),_n.push.apply(_n,Rn.mat.elements.slice(12,16)),Dn.push(0)}for(var Lt=this._MemorySections.length,wn=0;wn<Lt;wn++){var hn=this._MemorySections[wn],xn=mt.automaticInversionColor2(hn.color),$n=[];if((4278190080&xn)==16777216?$n=this._color:$n.push((255&xn)/255,(xn>>8&255)/255,(xn>>16&255)/255),hn.type==J.kLinesType){var Xr=new n.RawShaderMaterial({uniforms:{color:{value:$n}},vertexShader:u.MxShader.VSHADER_COLOR_POINT_FORMXCAD,fragmentShader:u.MxShader.FSHADER_COLOR_POINT_FORMXCAD,linewidth:1,transparent:!0,side:n.DoubleSide});(gn=new n.InstancedBufferGeometry).maxInstancedCount=kt.length,gn.setAttribute("position",new n.Float32BufferAttribute(hn.points,3)),gn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(nn),4)),gn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(tn),4)),gn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(pn),4)),gn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(_n),4)),gn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(Dn),1)),(Xn=new n.LineSegments(gn,Xr)).frustumCulled=!1,Xn.renderOrder=y.MxData.iCADCurveRenderOrder,4<=It.ver&&0<It.instansClipePoints.length&&new m.MxStencilObject().associateObject(Xn,It.instansClipePoints),pt.add(Xn),this._entitys.push(Xn)}else if(hn.type==J.kTriangleType){Xr=new n.RawShaderMaterial({uniforms:{color:{value:$n}},vertexShader:u.MxShader.VSHADER_COLOR_POINT_FORMXCAD,fragmentShader:u.MxShader.FSHADER_COLOR_POINT_FORMXCAD,transparent:!0,side:n.DoubleSide}),(gn=new n.InstancedBufferGeometry).maxInstancedCount=kt.length,gn.setAttribute("position",new n.Float32BufferAttribute(hn.points,3)),gn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(nn),4)),gn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(tn),4)),gn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(pn),4)),gn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(_n),4)),gn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(Dn),1));var ti=new n.Mesh(gn,Xr);ti.frustumCulled=!1,ti.renderOrder=y.MxData.iCADMeshRenderOrder,4<=It.ver&&0<It.instansClipePoints.length&&new m.MxStencilObject().associateObject(ti,It.instansClipePoints),pt.add(ti),this._entitys.push(ti)}else if(hn.type==J.kPointType){var gn,Xn;Xr=new n.RawShaderMaterial({uniforms:{color:{value:$n}},vertexShader:u.MxShader.VSHADER_COLOR_POINT_FORMXCAD,fragmentShader:u.MxShader.FSHADER_COLOR_POINT_FORMXCAD,transparent:!0,side:n.DoubleSide}),(gn=new n.InstancedBufferGeometry).maxInstancedCount=kt.length,gn.setAttribute("position",new n.Float32BufferAttribute(hn.points,3)),gn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(nn),4)),gn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(tn),4)),gn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(pn),4)),gn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(_n),4)),gn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(Dn),1)),(Xn=new n.Points(gn,Xr)).frustumCulled=!1,Xn.renderOrder=y.MxData.iCADCurveRenderOrder,4<=It.ver&&0<It.instansClipePoints.length&&new m.MxStencilObject().associateObject(Xn,It.instansClipePoints),pt.add(Xn),this._entitys.push(Xn)}}}},this)},Ue.prototype.createThreejsObjForMemorySections=function(ue,pt,mt){if(ue.length!=0){for(var Tt=[],kt=[],It=[],nn=[],tn=[],pn=0;pn<ue.length;pn++){var _n=ue[pn];Tt.push.apply(Tt,_n.mat.elements.slice(0,4)),kt.push.apply(kt,_n.mat.elements.slice(4,8)),It.push.apply(It,_n.mat.elements.slice(8,12)),nn.push.apply(nn,_n.mat.elements.slice(12,16)),tn.push(0)}for(var Dn=this._MemorySections.length,an=0;an<Dn;an++){var Rn=this._MemorySections[an],Lt=mt.automaticInversionColor2(Rn.color),wn=[];if((4278190080&Lt)==16777216?(wn=this._color,this._colorValue):wn.push((255&Lt)/255,(Lt>>8&255)/255,(Lt>>16&255)/255),Rn.type==J.kLinesType){var hn=new n.RawShaderMaterial({uniforms:{color:{value:wn}},vertexShader:u.MxShader.VSHADER_COLOR_POINT_FORMXCAD,fragmentShader:u.MxShader.FSHADER_COLOR_POINT_FORMXCAD,linewidth:1,transparent:!0,side:n.DoubleSide});($n=new n.InstancedBufferGeometry).maxInstancedCount=ue.length,$n.setAttribute("position",new n.Float32BufferAttribute(Rn.points,3)),$n.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(Tt),4)),$n.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(kt),4)),$n.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(It),4)),$n.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(nn),4)),$n.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(tn),1)),(Xr=new n.LineSegments($n,hn)).frustumCulled=!1,Xr.renderOrder=y.MxData.iCADCurveRenderOrder,pt.add(Xr),this._entitys.push(Xr)}else if(Rn.type==J.kTriangleType){hn=new n.RawShaderMaterial({uniforms:{color:{value:wn}},vertexShader:u.MxShader.VSHADER_COLOR_POINT_FORMXCAD,fragmentShader:u.MxShader.FSHADER_COLOR_POINT_FORMXCAD,transparent:!0,side:n.DoubleSide}),($n=new n.InstancedBufferGeometry).maxInstancedCount=ue.length,$n.setAttribute("position",new n.Float32BufferAttribute(Rn.points,3)),$n.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(Tt),4)),$n.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(kt),4)),$n.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(It),4)),$n.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(nn),4)),$n.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(tn),1));var xn=new n.Mesh($n,hn);xn.frustumCulled=!1,xn.renderOrder=y.MxData.iCADMeshRenderOrder,pt.add(xn),this._entitys.push(xn)}else if(Rn.type==J.kPointType){var $n,Xr;hn=new n.RawShaderMaterial({uniforms:{color:{value:wn},size:1},vertexShader:u.MxShader.VSHADER_COLOR_POINT_FORMXCAD,fragmentShader:u.MxShader.FSHADER_COLOR_POINT_FORMXCAD,transparent:!0,side:n.DoubleSide}),($n=new n.InstancedBufferGeometry).maxInstancedCount=ue.length,$n.setAttribute("position",new n.Float32BufferAttribute(Rn.points,3)),$n.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(Tt),4)),$n.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(kt),4)),$n.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(It),4)),$n.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(nn),4)),$n.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(tn),1)),(Xr=new n.Points($n,hn)).frustumCulled=!1,Xr.renderOrder=y.MxData.iCADCurveRenderOrder,pt.add(Xr),this._entitys.push(Xr)}}}},Ue.prototype.createThreejsObjForTexture=function(ue,pt,mt){if(ue.length!=0){var Tt=[],kt=[],It=[],nn=[],tn=[],pn=mt.getCurrentLoadUrl(),_n=O.MxFun.dwgDir();_n.length!=0&&pn.substring(pn.lastIndexOf("/buf/")).toLowerCase()!="/buf/"&&(pn=pn+_n+"/buf/");for(var Dn=0;Dn<ue.length;Dn++){var an=ue[Dn];Tt=Tt.concat(an.mat.elements.slice(0,4)),kt=kt.concat(an.mat.elements.slice(4,8)),It=It.concat(an.mat.elements.slice(8,12)),nn=nn.concat(an.mat.elements.slice(12,16)),tn.push(0)}for(var Rn=0;Rn<this._TextureData.length;Rn++){var Lt=this._TextureData[Rn],wn=new n.InstancedBufferGeometry;wn.maxInstancedCount=ue.length,wn.setAttribute("position",new n.Float32BufferAttribute(Lt.pos,2)),wn.setAttribute("uv",new n.Float32BufferAttribute(Lt.textureCoord,2)),wn.setAttribute("color",new n.Float32BufferAttribute(Lt.color,3)),wn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(Tt),4)),wn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(kt),4)),wn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(It),4)),wn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(nn),4)),wn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(tn),1));var hn=pn+Lt.sFileName,xn={texture:{value:new n.TextureLoader().load(hn,function(ti){ti&&mt.updateDisplay()})}};xn.texture.value.wrapS=xn.texture.value.wrapT=n.RepeatWrapping;var $n=new n.RawShaderMaterial({uniforms:xn,vertexShader:u.MxShader.VSHADER_COLOR_POINT_TEXTURE,fragmentShader:u.MxShader.FSHADER_COLOR_POINT_TEXTURE,transparent:!0,side:n.DoubleSide}),Xr=new n.Mesh(wn,$n);Xr.renderOrder=y.MxData.iCADMeshRenderOrder,Xr.frustumCulled=!1,pt.add(Xr),this._entitys.push(Xr)}}},Ue.prototype.createThreejsObjForTexture_Clip=function(ue,pt,mt){if(ue.size!=0){var Tt=mt.getCurrentLoadUrl(),kt=O.MxFun.dwgDir();kt.length!=0&&Tt.substring(Tt.lastIndexOf("/buf/")).toLowerCase()!="/buf/"&&(Tt=Tt+kt+"/buf/"),ue.forEach(function(It){var nn=It;if(nn.length!=0){for(var tn=nn[0].clipPlans,pn=[],_n=[],Dn=[],an=[],Rn=[],Lt=0;Lt<nn.length;Lt++){var wn=nn[Lt];pn=pn.concat(wn.mat.elements.slice(0,4)),_n=_n.concat(wn.mat.elements.slice(4,8)),Dn=Dn.concat(wn.mat.elements.slice(8,12)),an=an.concat(wn.mat.elements.slice(12,16)),Rn.push(0)}for(var hn=0;hn<this._TextureData.length;hn++){var xn=this._TextureData[hn],$n=new n.InstancedBufferGeometry;$n.maxInstancedCount=nn.length,$n.setAttribute("position",new n.Float32BufferAttribute(xn.pos,2)),$n.setAttribute("uv",new n.Float32BufferAttribute(xn.textureCoord,2)),$n.setAttribute("color",new n.Float32BufferAttribute(xn.color,3)),$n.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(pn),4)),$n.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(_n),4)),$n.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(Dn),4)),$n.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(an),4)),$n.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(Rn),1));var Xr=Tt+xn.sFileName,ti={texture:{value:new n.TextureLoader().load(Xr,function(Kn){Kn&&mt.updateDisplay()})}};ti.texture.value.wrapS=ti.texture.value.wrapT=n.RepeatWrapping;var gn=new n.RawShaderMaterial({uniforms:ti,vertexShader:u.MxShader.VSHADER_COLOR_POINT_TEXTURE,fragmentShader:u.MxShader.FSHADER_COLOR_POINT_TEXTURE,transparent:!0,side:n.DoubleSide}),Xn=new n.Mesh($n,gn);Xn.renderOrder=y.MxData.iCADMeshRenderOrder,Xn.frustumCulled=!1,4<=tn.ver&&0<tn.instansClipePoints.length&&new m.MxStencilObject().associateObject(Xn,tn.instansClipePoints),pt.add(Xn),this._entitys.push(Xn)}}},this)}},Ue.prototype.createThreejsObjForMesh=function(ue,pt){if(ue.length!=0){for(var mt=[],Tt=[],kt=[],It=[],nn=[],tn=[],pn=[],_n=0;_n<ue.length;_n++){var Dn=ue[_n];mt=mt.concat(Dn.mat.elements.slice(0,4)),Tt=Tt.concat(Dn.mat.elements.slice(4,8)),kt=kt.concat(Dn.mat.elements.slice(8,12)),It=It.concat(Dn.mat.elements.slice(12,16)),nn.push(0),tn=tn.concat(ue[_n].color)}if(0<this._geometryMeshPositionsByBlock.length)for(_n=0;_n<ue.length;_n++)tn=tn.concat(ue[_n].color);if(0<this._geometryMeshPositionsByBlock_ZeroLayer.length)for(_n=0;_n<ue.length;_n++)pn=pn.concat(ue[_n].topLayerColor);for(var an=new n.RawShaderMaterial({vertexShader:u.MxShader.VSHADER_COLOR_POINT,fragmentShader:u.MxShader.FSHADER_COLOR_POINT,transparent:!0,side:n.DoubleSide}),Rn=0;Rn<this._geometryMeshPostion.length;Rn++)(wn=new n.InstancedBufferGeometry).maxInstancedCount=ue.length,wn.setAttribute("position",new n.Float32BufferAttribute(this._geometryMeshPostion[Rn],2)),wn.setAttribute("color",new n.Float32BufferAttribute(this._geometryMeshColor[Rn],3)),wn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(mt),4)),wn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(Tt),4)),wn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(kt),4)),wn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(It),4)),wn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(nn),1)),(hn=new n.Mesh(wn,an)).frustumCulled=!1,hn.renderOrder=y.MxData.iCADMeshRenderOrder,pt.add(hn),this._entitys.push(hn);for(Rn=0;Rn<this._geometryMeshPositionsByBlock.length;Rn++)(wn=new n.InstancedBufferGeometry).maxInstancedCount=ue.length,wn.setAttribute("position",new n.Float32BufferAttribute(this._geometryMeshPositionsByBlock[Rn],2)),wn.setAttribute("color",new n.InstancedBufferAttribute(new Float32Array(tn),3)),wn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(mt),4)),wn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(Tt),4)),wn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(kt),4)),wn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(It),4)),wn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(nn),1)),(hn=new n.Mesh(wn,an)).frustumCulled=!1,hn.renderOrder=y.MxData.iCADMeshRenderOrder,pt.add(hn),this._entitys.push(hn);for(Rn=0;Rn<this._geometryMeshPositionsByBlock_ZeroLayer.length;Rn++)(wn=new n.InstancedBufferGeometry).maxInstancedCount=ue.length,wn.setAttribute("position",new n.Float32BufferAttribute(this._geometryMeshPositionsByBlock_ZeroLayer[Rn],2)),wn.setAttribute("color",new n.InstancedBufferAttribute(new Float32Array(pn),3)),wn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(mt),4)),wn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(Tt),4)),wn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(kt),4)),wn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(It),4)),wn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(nn),1)),(hn=new n.Mesh(wn,an)).frustumCulled=!1,hn.renderOrder=y.MxData.iCADMeshRenderOrder,pt.add(hn),this._entitys.push(hn);var Lt=new n.RawShaderMaterial({uniforms:{color:{value:this._color}},vertexShader:u.MxShader.VSHADER_COLOR_POINT,fragmentShader:u.MxShader.FSHADER_COLOR_POINT,transparent:!0,side:n.DoubleSide});for(Rn=0;Rn<this._geometryMeshPositionsByLayer.length;Rn++){var wn,hn;(wn=new n.InstancedBufferGeometry).maxInstancedCount=ue.length,wn.setAttribute("position",new n.Float32BufferAttribute(this._geometryMeshPositionsByLayer[Rn],2)),wn.setAttribute("tran1",new n.InstancedBufferAttribute(new Float32Array(mt),4)),wn.setAttribute("tran2",new n.InstancedBufferAttribute(new Float32Array(Tt),4)),wn.setAttribute("tran3",new n.InstancedBufferAttribute(new Float32Array(kt),4)),wn.setAttribute("tran4",new n.InstancedBufferAttribute(new Float32Array(It),4)),wn.setAttribute("ishide",new n.InstancedBufferAttribute(new Float32Array(nn),1)),(hn=new n.Mesh(wn,Lt)).frustumCulled=!1,hn.renderOrder=y.MxData.iCADMeshRenderOrder,pt.add(hn),this._entitys.push(hn)}}},Ue.prototype.addGeometryCurve=function(ue,pt,mt,Tt,kt){0<ue.length&&(this._geometryCurvePostion.push(ue),this._geometryCurveColor.push(pt)),0<mt.length&&this._geometryCurvePositionsByBlock.push(mt),0<Tt.length&&this._geometryCurvePositionsByLayer.push(Tt),0<kt.length&&this._geometryCurvePositionsByBlock_ZeroLayer.push(kt)},Ue.prototype.addGeometryMesh=function(ue,pt,mt,Tt,kt){0<ue.length&&(this._geometryMeshPostion.push(ue),this._geometryMeshColor.push(pt)),0<mt.length&&this._geometryMeshPositionsByBlock.push(mt),0<Tt.length&&this._geometryMeshPositionsByLayer.push(Tt),0<kt.length&&this._geometryMeshPositionsByBlock_ZeroLayer.push(kt)},Ue.prototype.addGeometryTexture=function(ue,pt,mt,Tt,kt,It,nn){var tn=new ve;tn.pos=ue,tn.textureCoord=pt,tn.color=mt,tn.sFileName=Tt,tn.dAngel=kt,tn.ptRotationPostionX=It,tn.ptRotationPostionY=nn,this._TextureData.push(tn)},Ue.prototype.addMemorySections=function(ue){this._MemorySections.push(ue)},Ue.prototype.createThreejsObj=function(ue,pt,mt,Tt,kt){var It=mt.getScene(),nn=mt.getCanvas();if(ue.length!=0){if(this._color==null){var tn=Tt.getColor(kt);this._color=[],this._color.push((255&tn)/255,(tn>>8&255)/255,(tn>>16&255)/255),this._colorValue=16777215&tn}this._geometryCurvePostion.length==0&&this._geometryCurvePositionsByBlock.length==0&&this._geometryCurvePositionsByLayer.length==0&&this._geometryCurvePositionsByBlock_ZeroLayer.length==0||this.createThreejsObjForCurve(ue,It),this._geometryMeshPostion.length==0&&this._geometryMeshPositionsByBlock.length==0&&this._geometryMeshPositionsByLayer.length==0&&this._geometryMeshPositionsByBlock_ZeroLayer.length==0||this.createThreejsObjForMesh(ue,It),this._TextureData.length!=0&&this.createThreejsObjForTexture(ue,It,mt),this._MemorySections.length!=0&&this.createThreejsObjForMemorySections(ue,It,mt)}pt.size!=0&&(this._color==null&&(tn=Tt.getColor(kt),this._color=[],this._color.push((255&tn)/255,(tn>>8&255)/255,(tn>>16&255)/255),this._colorValue=16777215&tn),this._geometryCurvePostion.length==0&&this._geometryCurvePositionsByBlock.length==0&&this._geometryCurvePositionsByLayer.length==0&&this._geometryCurvePositionsByBlock_ZeroLayer.length==0||this.createThreejsObjForCurve_Clip(pt,It,nn),this._geometryMeshPostion.length==0&&this._geometryMeshPositionsByBlock.length==0&&this._geometryMeshPositionsByLayer.length==0&&this._geometryMeshPositionsByBlock_ZeroLayer.length==0||this.createThreejsObjForMesh_Clip(pt,It,nn),this._TextureData.length!=0&&this.createThreejsObjForTexture_Clip(pt,It,mt),this._MemorySections.length!=0&&this.createThreejsObjForMemorySections_clip(pt,It,mt)),this._geometryCurvePostion=[],this._geometryCurvePositionsByBlock=[],this._geometryCurvePositionsByLayer=[],this._geometryCurvePositionsByBlock_ZeroLayer=[],this._geometryCurveColor=[],this._geometryMeshPostion=[],this._geometryMeshPositionsByBlock=[],this._geometryMeshPositionsByLayer=[],this._geometryMeshPositionsByBlock_ZeroLayer=[],this._geometryMeshColor=[],this._TextureData=[],this._MemorySections=[]},Ue);function Ue(ue){this._blockRecId=0,this._TextureData=[],this._MemorySections=[],this._geometryCurvePostion=new Array,this._geometryCurveColor=new Array,this._geometryMeshPostion=new Array,this._geometryMeshColor=new Array,this._geometryCurvePositionsByBlock=new Array,this._geometryMeshPositionsByBlock=new Array,this._geometryCurvePositionsByLayer=new Array,this._geometryMeshPositionsByLayer=new Array,this._geometryCurvePositionsByBlock_ZeroLayer=new Array,this._geometryMeshPositionsByBlock_ZeroLayer=new Array,this._entitys=new Array,this._color=void 0,this._colorValue=16777215,this._material_clip=[],this._blockRecId=ue}l.Layer=ne;var De=(Ve.prototype.showLayer=function(ue,pt){var mt=this._layerTogeometry.get(ue);mt?.Show(pt)},Ve.prototype.updataClipMaterial=function(ue){var pt=ue.getCanvas();this._layerTogeometry.forEach(function(mt,Tt,kt){mt.updataClipMaterial(pt)})},Ve.prototype.getId=function(){return this._id},Ve.prototype.getBlkRef=function(){return this._blkRef},Ve.prototype.createThreejsObj=function(ue,pt){var mt=this;this._layerTogeometry.forEach(function(Tt,kt,It){Tt.createThreejsObj(mt._instance,mt._instance_clip,ue,pt,kt)})},Ve.prototype.addGeometryCurve=function(ue,pt,mt,Tt,kt,It){var nn=this._layerTogeometry.get(mt);nn==null&&(nn=new ne(this._id),this._layerTogeometry.set(mt,nn)),nn.addGeometryCurve(ue,pt,Tt,kt,It)},Ve.prototype.addMemorySections=function(ue){var pt=this._layerTogeometry.get(ue.layerId);pt==null&&(pt=new ne(this._id),this._layerTogeometry.set(ue.layerId,pt)),pt.addMemorySections(ue)},Ve.prototype.addGeometryTexture=function(ue,pt,mt,Tt,kt,It,nn,tn){var pn=this._layerTogeometry.get(Tt);pn==null&&(pn=new ne(this._id),this._layerTogeometry.set(Tt,pn)),pn.addGeometryTexture(ue,pt,mt,kt,It,nn,tn)},Ve.prototype.addGeometryMesh=function(ue,pt,mt,Tt,kt,It){var nn=this._layerTogeometry.get(mt);nn==null&&(nn=new ne(this._id),this._layerTogeometry.set(mt,nn)),nn.addGeometryMesh(ue,pt,Tt,kt,It)},Ve.prototype.addInstance=function(ue){var pt;ue.clipPlans.ver<=3?ue.clipPlans.clipPlanArray.length==0?this._instance.length<5e4&&this._instance.push(ue):((pt=this._instance_clip.get(ue.clipPlans.id))==null&&(pt=[],this._instance_clip.set(ue.clipPlans.id,pt)),pt.push(ue)):ue.clipPlans.instansClipePoints.length==0||100<this._instance_clip.size?this._instance.length<5e4&&this._instance.push(ue):((pt=this._instance_clip.get(ue.clipPlans.id))==null&&(pt=[],this._instance_clip.set(ue.clipPlans.id,pt)),pt.push(ue))},Ve.prototype.addBlkRef=function(ue){this._blkRef.push(ue)},Ve);function Ve(ue){this._id=0,this._layerTogeometry=new Map,this._blkRef=[],this._instance=[],this._instance_clip=new Map,this._id=ue}l.Block=De;var rt=(Ae.prototype.crateBlock=function(ue){var pt=this._mapBlock.get(ue);return pt==null&&(pt=new De(ue),this._mapBlock.set(ue,pt)),pt},Ae.prototype.getBlock=function(ue){return this._mapBlock.get(ue)},Ae.prototype.addBlockRef=function(ue){this.crateBlock(ue.blkOwnerId).addBlkRef(ue)},Ae.prototype.showLayer=function(ue,pt){this._mapBlock.forEach(function(mt,Tt){var kt=mt,It=Tt;return function(nn,tn,pn){nn.showLayer(kt,It)}}.call(this,ue,pt))},Ae.prototype.createBlocks_30=function(ue,pt){if(!this._isCreate){this.crateBlock(0);for(var mt=1,Tt=ue.getInt32(12,!0),kt=80,It=0;It<Tt;It++){var nn=ue.getInt32(kt,!0);kt+=4;var tn=ue.getInt32(kt,!0);kt+=4;var pn=ue.getInt32(kt,!0);kt+=4;var _n=ue.getInt32(kt,!0);kt+=4;for(var Dn=new Array,an=0;an<16;an++){var Rn=ue.getFloat32(kt,!0);kt+=4,Dn.push(Rn)}var Lt=ue.getInt32(kt,!0);kt+=4;var wn=new L;wn.id=mt,wn.ver=3,mt++,wn.clipPlanArray=[];for(var hn=0;hn<Lt;hn++){var xn=ue.getFloat32(kt,!0);kt+=4;var $n=ue.getFloat32(kt,!0);kt+=4;var Xr=ue.getFloat32(kt,!0);kt+=4;var ti=ue.getFloat32(kt,!0);kt+=4;var gn=new N;gn.x1=xn,gn.y1=$n,gn.x2=Xr,gn.y2=ti,wn.clipPlanArray.push(gn)}var Xn=new G;Xn.ver=3,Xn.mat=new n.Matrix4,Xn.mat.fromArray(Dn),Xn.blkRecId=pn,Xn.blkOwnerId=nn,Xn.layerId=tn,Xn.color=_n,Xn.clipPlans=wn,this.crateBlock(pn),this.addBlockRef(Xn)}this._isGetAllBlocks=!0,this._isCreate=!0}},Ae.prototype.createBlocks_40=function(ue,pt){if(!this._isCreate){this.crateBlock(0);for(var mt=1,Tt=ue.getInt32(12,!0),kt=80,It=0;It<Tt;It++){var nn=ue.getInt32(kt,!0);kt+=4;var tn=ue.getInt32(kt,!0);kt+=4;var pn=ue.getInt32(kt,!0);kt+=4;var _n=ue.getInt32(kt,!0);kt+=4;for(var Dn=new Array,an=0;an<16;an++){var Rn=ue.getFloat32(kt,!0);kt+=4,Dn.push(Rn)}var Lt=ue.getInt32(kt,!0);kt+=4;var wn=new L;wn.id=mt,wn.ver=4,mt++,wn.clipPoints=[];for(var hn=0;hn<Lt;hn++){var xn=new n.Vector2;xn.x=ue.getFloat32(kt,!0),kt+=4,xn.y=ue.getFloat32(kt,!0),kt+=4,wn.clipPoints.push(xn)}var $n=new G;$n.ver=4,$n.mat=new n.Matrix4,$n.mat.fromArray(Dn),$n.blkRecId=pn,$n.blkOwnerId=nn,$n.layerId=tn,$n.color=_n,$n.clipPlans=wn,this.crateBlock(pn),this.addBlockRef($n)}this._isGetAllBlocks=!0,this._isCreate=!0}},Ae.prototype.createBlocks=function(ue,pt){this._isCreate||(new b.MxNetData(ue).getVersion_MwBlobHead()<=3?this.createBlocks_30(ue,pt):this.createBlocks_40(ue,pt))},Ae.prototype.updataClipMaterial=function(ue){this._mapBlock.forEach(function(pt,mt,Tt){pt.updataClipMaterial(ue)})},Ae.prototype.createAllInstance=function(ue){var pt=this.getBlock(0);if(pt==null||this._rootBlockRef==null)return!1;var mt=new n.Matrix4,Tt=new Map,kt=new L;return this._iClipIdCount=1,kt.id=this._iClipIdCount,this._iClipIdCount++,this.createAllInstanceCall(pt,this._rootBlockRef,mt,Tt,16777215,ue,void 0,kt),!0},Ae.prototype.createThreejsObj=function(ue,pt,mt){this._mapNeedCreateThreejsObj.get(ue.getId())==null&&this._mapNeedCreateThreejsObj.set(ue.getId(),ue),this._isCreateAllInstance||this._isGetAllBlocks&&mt.isInitComplete()&&(this._isCreateAllInstance=this.createAllInstance(mt)),this._isCreateAllInstance&&(this._mapNeedCreateThreejsObj.forEach(function(Tt,kt,It){Tt.createThreejsObj(pt,mt)}),this._mapNeedCreateThreejsObj.clear())},Ae.prototype.createAllInstanceCall=function(ue,pt,mt,Tt,kt,It,nn,tn){if(Tt[ue.getId()]!=1){Tt[ue.getId()]=!0;var pn=new q;if(pn.mat=new n.Matrix4,pn.mat.copy(mt),pn.mat.multiply(pt.mat),pt.ver<=3)if(pt.clipPlans.clipPlanArray.length==0)pn.clipPlans=tn;else{pn.clipPlans=pt.clipPlans,pn.clipPlans.ver=3;for(var _n,Dn,an,Rn,Lt=pn.clipPlans.clipPlanArray.length,wn=function(){_n=new n.Vector3(pn.clipPlans.clipPlanArray[hn].x1,pn.clipPlans.clipPlanArray[hn].y1,0),Dn=new n.Vector3(pn.clipPlans.clipPlanArray[hn].x2,pn.clipPlans.clipPlanArray[hn].y2,0),an=new n.Vector3(pn.clipPlans.clipPlanArray[hn].x1,pn.clipPlans.clipPlanArray[hn].y2,0),Rn=new n.Vector3(pn.clipPlans.clipPlanArray[hn].x2,pn.clipPlans.clipPlanArray[hn].y1,0),_n.applyMatrix4(pn.mat),Dn.applyMatrix4(pn.mat),an.applyMatrix4(pn.mat),Rn.applyMatrix4(pn.mat);var Vr=_n.x,xi=_n.x,Si=_n.y,qn=_n.y,ia=[];ia.push(Dn),ia.push(an),ia.push(Rn),ia.forEach(function(Wi){Vr>Wi.x&&(Vr=Wi.x),xi<Wi.x&&(xi=Wi.x),Si>Wi.y&&(Si=Wi.y),qn<Wi.y&&(qn=Wi.y)}),pn.clipPlans.clipPlanArray[hn].x1=Vr,pn.clipPlans.clipPlanArray[hn].y1=Si,pn.clipPlans.clipPlanArray[hn].x2=xi,pn.clipPlans.clipPlanArray[hn].y2=qn},hn=0;hn<Lt;hn++)wn()}else if(pt.clipPlans.clipPoints.length==0)pn.clipPlans=tn;else{pn.clipPlans=new L,pn.clipPlans.ver=4,pn.clipPlans.id=this._iClipIdCount,this._iClipIdCount++,pn.clipPlans.instansClipePoints=tn.instansClipePoints.slice(0);var xn=[],$n=pt.clipPlans.clipPoints;for(Lt=$n.length,hn=0;hn<Lt;hn++){var Xr=new n.Vector3($n[hn].x,$n[hn].y,0);Xr.applyMatrix4(pn.mat),xn.push(new n.Vector2(Xr.x,Xr.y))}pn.clipPlans.instansClipePoints.push(xn)}nn==null?pn.topLayerColor.push(1,1,1):pn.topLayerColor.push(nn[0],nn[1],nn[2]);var ti=pt.color>>24&255;if(ti==2)pn.color.push((255&kt)/255,(kt>>8&255)/255,(kt>>16&255)/255);else if(ti==1){var gn=It.getColor(pt.layerId);pn.color.push((255&gn)/255,(gn>>8&255)/255,(gn>>16&255)/255),kt=gn}else pn.color.push((255&pt.color)/255,(pt.color>>8&255)/255,(pt.color>>16&255)/255),kt=pt.color;ue.addInstance(pn);for(var Xn=ue.getBlkRef(),Kn=nn==null,Vn=0;Vn<Xn.length;Vn++)if(Xn[Vn].blkRecId!=0){var Yn=this.getBlock(Xn[Vn].blkRecId);if(Yn==null)return;Kn&&(nn=[],gn=It.getColor(Xn[Vn].layerId),nn.push((255&gn)/255,(gn>>8&255)/255,(gn>>16&255)/255)),this.createAllInstanceCall(Yn,Xn[Vn],pn.mat,Tt,kt,It,nn,pn.clipPlans)}Tt[ue.getId()]=!1}},Ae.prototype.initRootBlockRef=function(ue){ue==null&&((ue=new G).mat=new n.Matrix4,ue.blkRecId=0,ue.blkOwnerId=-1,ue.layerId=-1,ue.color=16777215),this._rootBlockRef=ue},Ae);function Ae(){this._mapBlock=new Map,this._mapNeedCreateThreejsObj=new Map,this._isCreate=!1,this._isGetAllBlocks=!1,this._isCreateAllInstance=!1,this._rootBlockRef=void 0,this._iClipIdCount=1}l.Blocks=rt;var Te=function(){this.blocks=new rt,this.layers=new c.MxBrowseLayerData};l.ExternalReferenceDatabase=Te;var Xe=(ie.prototype.createTzDwgExternalReferences=function(ue){this._mapId2ExternalDatabase.get(ue)||this.getBlocks(ue).initRootBlockRef()},ie.prototype.createExternalReferences=function(ue){for(var pt=ue.getInt32(12,!0),mt=80,Tt=0;Tt<pt;Tt++){for(var kt=new Array,It=0;It<16;It++){var nn=ue.getFloat32(mt,!0);mt+=4,kt.push(nn)}var tn=ue.getInt32(mt,!0);mt+=4;var pn=ue.getInt32(mt,!0);if(mt+=4,ue.getInt32(mt,!0),mt+=4,tn!=0){var _n=this.getBlocks(tn),Dn=new G;Dn.mat=new n.Matrix4,Dn.mat.fromArray(kt),Dn.blkRecId=0,Dn.blkOwnerId=-1,Dn.layerId=-1,Dn.color=pn,_n.initRootBlockRef(Dn)}else console.log("mx error iDatabaseIndex")}},ie.prototype.getBlocks=function(ue){if(ue!=0){var pt=this._mapId2ExternalDatabase.get(ue);return pt==null&&(pt=new Te,this._mapId2ExternalDatabase.set(ue,pt)),pt.blocks}console.log("mx error iDatabaseIndex")},ie.prototype.getLayers=function(ue){if(ue!=0){var pt=this._mapId2ExternalDatabase.get(ue);return pt==null&&(pt=new Te,this._mapId2ExternalDatabase.set(ue,pt)),pt.layers}console.log("mx error iDatabaseIndex")},ie);function ie(){this._mapId2ExternalDatabase=new Map}l.ExternalReferenceManager=Xe},{"../MxFun":27,"../MxManager":29,"../MxNetData":31,"../MxShader":32,"../MxStencilObject":33,"./MxBrowseLayerData":67,three:19}],67:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxBrowseLayerData=void 0;var n=(u.prototype.add=function(c,y,b){this._layerColor[c]=y,this._nametoId[b]=c},u.prototype.setZeroLayerId=function(c){this._zeroLayerId=c},u.prototype.getZeroLayerId=function(){return this._zeroLayerId},u.prototype.getLayerIdForName=function(c){return this._nametoId[c]==null?0:this._nametoId[c]},u.prototype.getColor=function(c){return this._layerColor[c]==null?16777215:this._layerColor[c]},u.prototype.initComplete=function(){this._isSetInstanceComplete=!0},u.prototype.isInitComplete=function(){return this._isSetInstanceComplete},u);function u(){this._isSetInstanceComplete=!1,this._layerColor=new Map,this._nametoId=new Map,this._zeroLayerId=0}l.MxBrowseLayerData=n},{}],68:[function(t,e,l){var n=this&&this.__awaiter||function(ne,Ue,De,Ve){return new(De=De||Promise)(function(rt,Ae){function Te(ue){try{ie(Ve.next(ue))}catch(pt){Ae(pt)}}function Xe(ue){try{ie(Ve.throw(ue))}catch(pt){Ae(pt)}}function ie(ue){var pt;ue.done?rt(ue.value):((pt=ue.value)instanceof De?pt:new De(function(mt){mt(pt)})).then(Te,Xe)}ie((Ve=Ve.apply(ne,Ue||[])).next())})},u=this&&this.__generator||function(ne,Ue){var De,Ve,rt,Ae,Te={label:0,sent:function(){if(1&rt[0])throw rt[1];return rt[1]},trys:[],ops:[]};return Ae={next:Xe(0),throw:Xe(1),return:Xe(2)},typeof Symbol=="function"&&(Ae[Symbol.iterator]=function(){return this}),Ae;function Xe(ie){return function(ue){return function(pt){if(De)throw new TypeError("Generator is already executing.");for(;Te;)try{if(De=1,Ve&&(rt=2&pt[0]?Ve.return:pt[0]?Ve.throw||((rt=Ve.return)&&rt.call(Ve),0):Ve.next)&&!(rt=rt.call(Ve,pt[1])).done)return rt;switch(Ve=0,rt&&(pt=[2&pt[0],rt.value]),pt[0]){case 0:case 1:rt=pt;break;case 4:return Te.label++,{value:pt[1],done:!1};case 5:Te.label++,Ve=pt[1],pt=[0];continue;case 7:pt=Te.ops.pop(),Te.trys.pop();continue;default:if(!(rt=0<(rt=Te.trys).length&&rt[rt.length-1])&&(pt[0]===6||pt[0]===2)){Te=0;continue}if(pt[0]===3&&(!rt||pt[1]>rt[0]&&pt[1]<rt[3])){Te.label=pt[1];break}if(pt[0]===6&&Te.label<rt[1]){Te.label=rt[1],rt=pt;break}if(rt&&Te.label<rt[2]){Te.label=rt[2],Te.ops.push(pt);break}rt[2]&&Te.ops.pop(),Te.trys.pop();continue}pt=Ue.call(ne,Te)}catch(mt){pt=[6,mt],Ve=0}finally{De=rt=0}if(5&pt[0])throw pt[1];return{value:pt[0]?pt[1]:void 0,done:!0}}([ie,ue])}}};Object.defineProperty(l,"__esModule",{value:!0}),l.MxDbDatabase=void 0;var c=t("three"),y=t("../MxFun"),b=t("./MxDbEntity"),m=t("./MxDbEntityGrip"),O=t("./MxDbEntitySelect"),N=t("../MxManager"),L=t("../MxType"),G=t("./MxDbLayerTable"),q=t("./MxDbGroup"),J=t("../MxTools"),fe=(ve.prototype.getAllEntity=function(){return this.mapIdToEntity},ve.prototype.getGroupDictionary=function(){return this.groupDictionary},ve.prototype.regenAllMxDbEntity=function(){return this.mapIdToEntity.forEach(function(ne){ne.upDisplay(),ne.setDirtyDisplay(!1)}),!0},ve.prototype.upDirtyDisplay=function(){var ne=!1;return this.mapIdToEntity.forEach(function(Ue){Ue.getDirtyDisplay()&&(Ue.upDisplay(),Ue.setDirtyDisplay(!1),ne=!0)}),ne},ve.prototype.onViewChange=function(){var ne=!1;return this.mapIdToEntity.forEach(function(Ue){Ue.onViewChange()&&(ne=!0)}),ne},ve.prototype.toJsonObject=function(ne){var Ue={ver:1},De=new c.Vector3(0,0,0),Ve=new c.Vector3(this.mxObj.getViewWidth(),this.mxObj.getViewHeight(),0),rt=L.MxType.MxCloneType.kMxFileClone;ne&&(rt=L.MxType.MxCloneType.kSaveDwgClone);var Ae=this.mxObj.screenCoord2Current(De.x,De.y,0),Te=this.mxObj.screenCoord2Current(Ve.x,Ve.y,0);Ue.view={ptView1:Ae,ptView2:Te};var Xe=[];return this.mapNameToLayer.forEach(function(ie){var ue={type:rt};ie.dwgOut(ue),ue.TypeName="MxDbLayerTableRecord",Xe.push(ue)}),Ue.layers=Xe,this.groupDictionary.dwgOut(Ue),Ue},ve.prototype.saveJson=function(ne){var Ue=this,De=this.toJsonObject(ne),Ve=L.MxType.MxCloneType.kMxFileClone;ne&&(Ve=L.MxType.MxCloneType.kSaveDwgClone);var rt=[];return this.mapIdToEntity.forEach(function(Ae){var Te=Ae.getUserObject(),Xe={type:Ve};Te.dwgOut(Xe),Xe.TypeName=Te.getTypeName(),Xe.group=Ue.groupDictionary.getEntityInGroupName(Ae.objectId()),rt.push(Xe)}),De.entitys=rt,De},ve.prototype.reInit=function(){this.eraseAllEntity(),this.groupDictionary=new q.MxDbGroupDictionary;var ne=this.parentObject.matrix;this.init(this.mxObj),this.initObjectMatrix(ne)},ve.prototype.init=function(ne){this.mxObj=ne,this.scene=ne.getScene(),y.MxFun.removeThreejsObject(this.parentObject,this.scene),y.MxFun.removeThreejsObject(this.parentObject_SmallCoord,this.scene),this.parentObject=new c.Object3D,this.parentObject.renderOrder=N.MxData.iMxEntityRenderOrder,this.scene.add(this.parentObject),this.parentObject_SmallCoord=new c.Object3D,this.parentObject_SmallCoord.renderOrder=N.MxData.iMxEntityRenderOrder,this.scene.add(this.parentObject_SmallCoord),this.initLayerTable()},ve.prototype.loadJson=function(ne){return n(this,void 0,void 0,function(){var Ue,De,Ve,rt,Ae,Te,Xe,ie,ue,pt,mt=this;return u(this,function(Tt){switch(Tt.label){case 0:if(this.reInit(),(Ue=ne).view&&(De=Ue.view,this.mxObj.zoomW(new c.Vector3(De.ptView1.x,De.ptView1.y,0),new c.Vector3(De.ptView2.x,De.ptView2.y,0),!1)),Ve=Ue.layers)for(rt=Ve.length,pt=0;pt<rt;pt++)Ae=Ve[pt],this.addLayer(Ae.name).dwgIn(Ae);this.groupDictionary.dwgIn(Ue),Te=Ue.entitys,Xe=Te.length,ie=function(kt){var It,nn,tn,pn;return u(this,function(_n){switch(_n.label){case 0:return It=Te[kt],[4,N.MxManager.getMxDbEntityClassHierarchy().createMxEntity(It.TypeName)];case 1:return(nn=_n.sent())?(nn.dwgIn(It),(tn=new b.MxDbEntity).initUserObject(nn),ue.addEntityImp(tn),(pn=It.group)&&0<pn.length&&pn.forEach(function(Dn){mt.groupDictionary.add(Dn).append(tn.objectId())}),[2]):[2,"continue"]}})},ue=this,pt=0,Tt.label=1;case 1:return pt<Xe?[5,ie(pt)]:[3,4];case 2:Tt.sent(),Tt.label=3;case 3:return pt++,[3,1];case 4:return[2,new Promise(function(kt){kt(!0)})]}})})},ve.prototype.getMxObject=function(){return this.mxObj},ve.prototype.getGripManager=function(){return this.gripManager},ve.prototype.getSelectManager=function(){return this.selectManager},ve.prototype.clearMxCurrentSelect=function(){var ne=!1;return this.gripManager.removeAllGrips()&&(ne=!0),this.selectManager.removeAllEntity()&&(ne=!0),ne},ve.prototype.eraseAllEntity=function(){this.mapIdToEntity.forEach(function(ne){ne.clearDisplayImp()}),this.mapIdToEntity=new Map,this.clearMxCurrentSelect()},ve.prototype.initObjectMatrix=function(ne){this.parentObject.matrix=ne,this.parentObject.matrixAutoUpdate=!1,this.parentObject_SmallCoord.matrix=new c.Matrix4,this.parentObject_SmallCoord.matrixAutoUpdate=!1},ve.prototype.initLayerTable=function(){this.mapNameToLayer=new Map,this.curLayer="0";var ne=new G.MxDbLayerTableRecord;ne.init(this.curLayer,this.parentObject,this.parentObject_SmallCoord),this.mapNameToLayer.set(this.curLayer,ne)},ve.prototype.getEntity=function(ne){return this.mapIdToEntity.get(ne)},ve.prototype.isValidId=function(ne){return this.mapIdToEntity.has(ne)},ve.prototype.setRenderOrder=function(ne){var Ue=this.parentObject.renderOrder;return this.parentObject.renderOrder=ne,this.parentObject_SmallCoord.renderOrder=ne,Ue},ve.prototype.eraseEntity=function(ne){this.gripManager.deleteGripData(ne),this.selectManager.deleteSelect(ne),this.mapIdToEntity.delete(ne)},ve.prototype.showLayer=function(ne,Ue){var De=this.getLayer(ne);De&&De.setVisible(Ue)},ve.prototype.setCurrentLayer=function(ne){if(ne.length!=0)return this.curLayer=ne,this.addLayer(ne)},ve.prototype.addLayer=function(ne){var Ue=this.mapNameToLayer.get(ne);return Ue||((Ue=new G.MxDbLayerTableRecord).init(ne,this.parentObject,this.parentObject_SmallCoord),this.mapNameToLayer.set(ne,Ue),Ue)},ve.prototype.getLayer=function(ne){return this.mapNameToLayer.get(ne)},ve.prototype.addMxEntity=function(ne){if(ne.getImp())return ne.objectId();var Ue=new b.MxDbEntity;return Ue.initUserObject(ne),ne.initGuid(J.MxTools.generateUUID()),this.addEntityImp(Ue)},ve.prototype.addEntityImp=function(ne){return this.mapIdToEntity.set(this.idCount,ne),ne.setMxDatabase(this),ne.setObjectId(this.idCount),ne.getLayer().length==0&&ne.setLayer(this.curLayer),ne.upDisplay(),this.idCount++},ve.prototype.getThreeJSParentObject=function(){return this.parentObject},ve.prototype.getThreeJSParentObject_SmallCoord=function(){return this.parentObject_SmallCoord},ve.prototype.getIntersectObjects=function(ne){var Ue=this.getIntersectObjects_imp(ne),De=this.getIntersectObjects_SmallCoord_imp(ne);return Ue.concat(De)},ve.prototype.getIntersectObjects_imp=function(ne){return this.mxObj.getMxDrawThreeJs().createRaycaster(ne).intersectObjects(this.parentObject.children,!0)},ve.prototype.getIntersectObjects_SmallCoord_imp=function(ne){return this.mxObj.getMxDrawThreeJs().createRaycaster(ne).intersectObjects(this.parentObject_SmallCoord.children,!0)},ve);function ve(){this.mapIdToEntity=new Map,this.mxObj=null,this.scene=null,this.idCount=1,this.parentObject=null,this.parentObject_SmallCoord=null,this.mapNameToLayer=new Map,this.curLayer="0",this.gripManager=new m.MxDbEntityGrip(this),this.selectManager=new O.MxDbEntitySelect(this),this.groupDictionary=new q.MxDbGroupDictionary}l.MxDbDatabase=fe},{"../MxFun":27,"../MxManager":29,"../MxTools":38,"../MxType":39,"./MxDbEntity":69,"./MxDbEntityGrip":70,"./MxDbEntitySelect":71,"./MxDbGroup":72,"./MxDbLayerTable":73,three:19}],69:[function(t,e,l){var n=this&&this.__awaiter||function(ve,ne,Ue,De){return new(Ue=Ue||Promise)(function(Ve,rt){function Ae(ie){try{Xe(De.next(ie))}catch(ue){rt(ue)}}function Te(ie){try{Xe(De.throw(ie))}catch(ue){rt(ue)}}function Xe(ie){var ue;ie.done?Ve(ie.value):((ue=ie.value)instanceof Ue?ue:new Ue(function(pt){pt(ue)})).then(Ae,Te)}Xe((De=De.apply(ve,ne||[])).next())})},u=this&&this.__generator||function(ve,ne){var Ue,De,Ve,rt,Ae={label:0,sent:function(){if(1&Ve[0])throw Ve[1];return Ve[1]},trys:[],ops:[]};return rt={next:Te(0),throw:Te(1),return:Te(2)},typeof Symbol=="function"&&(rt[Symbol.iterator]=function(){return this}),rt;function Te(Xe){return function(ie){return function(ue){if(Ue)throw new TypeError("Generator is already executing.");for(;Ae;)try{if(Ue=1,De&&(Ve=2&ue[0]?De.return:ue[0]?De.throw||((Ve=De.return)&&Ve.call(De),0):De.next)&&!(Ve=Ve.call(De,ue[1])).done)return Ve;switch(De=0,Ve&&(ue=[2&ue[0],Ve.value]),ue[0]){case 0:case 1:Ve=ue;break;case 4:return Ae.label++,{value:ue[1],done:!1};case 5:Ae.label++,De=ue[1],ue=[0];continue;case 7:ue=Ae.ops.pop(),Ae.trys.pop();continue;default:if(!(Ve=0<(Ve=Ae.trys).length&&Ve[Ve.length-1])&&(ue[0]===6||ue[0]===2)){Ae=0;continue}if(ue[0]===3&&(!Ve||ue[1]>Ve[0]&&ue[1]<Ve[3])){Ae.label=ue[1];break}if(ue[0]===6&&Ae.label<Ve[1]){Ae.label=Ve[1],Ve=ue;break}if(Ve&&Ae.label<Ve[2]){Ae.label=Ve[2],Ae.ops.push(ue);break}Ve[2]&&Ae.ops.pop(),Ae.trys.pop();continue}ue=ne.call(ve,Ae)}catch(pt){ue=[6,pt],De=0}finally{Ue=Ve=0}if(5&ue[0])throw ue[1];return{value:ue[0]?ue[1]:void 0,done:!0}}([Xe,ie])}}};Object.defineProperty(l,"__esModule",{value:!0}),l.MxDbEntity=l.MxDbEntityClassHierarchy=l.MxDbEntityUserObject=void 0;var c=t("three"),y=t("../Operate/McGiWorldDraw"),b=t("../MxManager"),m=t("../MxTools"),O=t("../MxType"),N=(L.prototype.getClosestPointTo=function(ve,ne){return null},L.prototype.getTypeName=function(){return""},L.prototype.isUseSmallcoordDisplay=function(){return this.use_smallcoord_display},L.prototype.toSmallcoord=function(ve,ne){return this.use_smallcoord_display?ve.toSmallcoord(ne):ne},L.prototype.initGuid=function(ve){0<this.sGuid.length?console.log("mx: init guid error"):this.sGuid=ve},L.prototype.guid=function(){return this.sGuid},L.prototype.setGuid=function(ve){this.sGuid=ve},L.prototype.setLayer=function(ve){var ne=this.getImp();ne&&ne.nodifySetLayer(),this.layer=ve},L.prototype.getLayer=function(){return this.layer},L.prototype.setDash=function(ve,ne){this.dDashArray=ve,this.dDashRatio=ne,this.dLineWidth==0&&(this.dLineWidth=6,this.lineWidthByPixels=!0)},L.prototype.getDash=function(){return{dDashArray:this.dDashArray,dDashRatio:this.dDashRatio}},L.prototype.setDashLineDisplay=function(ve){ve?(this.dDashArray=.03,this.dDashRatio=.1,this.dLineWidth==0&&(this.dLineWidth=6,this.lineWidthByPixels=!0)):(this.dDashArray=0,this.dDashRatio=0)},L.prototype.isDashLineDisplay=function(){return 0<this.dDashArray&&0<this.dDashRatio},L.prototype.setLineWidthByPixels=function(ve){this.lineWidthByPixels=ve},L.prototype.getLineWidthByPixels=function(){return this.lineWidthByPixels},L.prototype.setLineWidth=function(ve){this.dLineWidth=ve},L.prototype.getLineWidth=function(){return this.dLineWidth},L.prototype.getMxObject=function(){var ve=this.getImp();return ve?ve.getMxObject():null},L.prototype.onViewChange=function(){return!1},L.prototype.getImp=function(){return this.MxDbEntityImp},L.prototype.upDisplay=function(){var ve=this.getImp();return!!ve&&ve.upDisplay()},L.prototype.erase=function(){var ve=this.getImp();return!!ve&&ve.erase()},L.prototype.setColor=function(ve){this.iColor=ve},L.prototype.getColor=function(){return this.iColor},L.prototype.setRenderOrder=function(ve){this.iRenderOrder=ve},L.prototype.getRenderOrder=function(){return this.iRenderOrder},L.prototype.onEndGripEidt=function(){},L.prototype.onStartGripEidt=function(){},L.prototype.dwgIn=function(ve){return this.iColor=ve.iColor,this.iRenderOrder=ve.iRenderOrder,this.opacity=ve.opacity,this.visible=ve.visible,this.dLineWidth=ve.lineWidth,this.lineWidthByPixels=ve.lineWidthByPixels,this.dDashArray=ve.dashArray,this.dDashRatio=ve.dashRatio,this.layer=ve.layer,ve.guid&&(this.sGuid=ve.guid),!0},L.prototype.dwgOut=function(ve){return ve.iColor=this.iColor,ve.iRenderOrder=this.iRenderOrder,ve.opacity=this.opacity,ve.visible=this.visible,ve.lineWidth=this.dLineWidth,ve.lineWidthByPixels=this.lineWidthByPixels,ve.dashArray=this.dDashArray,ve.dashRatio=this.dDashRatio,ve.layer=this.layer,ve.guid=this.sGuid,ve},L.prototype.clone=function(ve){var ne=this.create(),Ue={type:ve||O.MxType.MxCloneType.kClone};return this.dwgOut(Ue),ne.dwgIn(Ue),ne.sGuid="",ne},L.prototype.init=function(){b.MxManager.getMxDbEntityClassHierarchy().init(this)},L.prototype.transformBy=function(ve){},L.prototype.objectId=function(){var ve=this.getImp();return ve?ve.objectId():0},L);function L(){this.iColor=16777215,this.iRenderOrder=b.MxData.iMxEntityRenderOrder,this.opacity=1,this.visible=!0,this.dLineWidth=0,this.lineWidthByPixels=!0,this.dDashArray=0,this.dDashRatio=0,this.layer="",this.sGuid="",this.use_smallcoord_display=!1}l.MxDbEntityUserObject=N;var G=(q.prototype.init=function(ve){var ne=ve.getTypeName();this.mapType2Create.get(ne)&&console.log("MxError:already has this class name "+ne),this.mapType2Create.set(ne,{type:0,createfun:ve})},q.prototype.initDynamic=function(ve){this.dynmaicCreate=ve},q.prototype.createMxEntity=function(ve){return n(this,void 0,void 0,function(){var ne,Ue;return u(this,function(De){switch(De.label){case 0:return(ne=this.mapType2Create.get(ve))?[3,3]:this.dynmaicCreate?[4,this.dynmaicCreate(ve)]:[3,2];case 1:return(Ue=De.sent())?(this.mapType2Create.set(ve,{type:1,createfun:Ue}),[2,new Promise(function(Ve,rt){Ve(new Ue)})]):[2,new Promise(function(Ve,rt){Ve(null)})];case 2:return[2,new Promise(function(Ve,rt){Ve(null)})];case 3:return ne.type==0?[2,new Promise(function(Ve,rt){Ve(ne.createfun.create())})]:ne.type==1?[2,new Promise(function(Ve,rt){Ve(new ne.createfun)})]:[2,new Promise(function(Ve,rt){Ve(null)})]}})})},q);function q(){this.mapType2Create=new Map,this.dynmaicCreate=null}l.MxDbEntityClassHierarchy=G;var J=(fe.prototype.setObjectId=function(ve){this.id=ve},fe.prototype.nodifySetLayer=function(){this.layerObjectGroup&&this.clearDisplayImp()},fe.prototype.setLayer=function(ve){this.userObject.setLayer(ve)},fe.prototype.getLayer=function(){return this.userObject.getLayer()},fe.prototype.setDirtyDisplay=function(ve){this.isDirtyDisplay=ve},fe.prototype.getDirtyDisplay=function(){return this.isDirtyDisplay},fe.prototype.setMxDatabase=function(ve){this.mxDatabase=ve},fe.prototype.objectId=function(){return this.id},fe.prototype.initUserObject=function(ve){(this.userObject=ve).MxDbEntityImp=this},fe.prototype.upDisplay=function(){if(!this.mxDatabase)return console.log("mxassert(0) this.mxDatabase is null"),!1;this.updateDisplayImp(this.mxDatabase.getMxObject())},fe.prototype.erase=function(){if(this.id==0)return!1;this.clearDisplayImp(),this.userObject=null,this.mxDatabase.eraseEntity(this.id),this.id=0,this.mxDatabase=null},fe.prototype.clearDisplayImp=function(){this.layerObjectGroup&&(this.threeObjectGroup&&(this.threeObjectGroup.traverse(function(ve){ve.type==="Mesh"&&(ve.geometry.dispose(),ve.material.dispose())}),this.layerObjectGroup.remove(this.threeObjectGroup)),this.threeObjectGroup=null,this.layerObjectGroup=null)},fe.prototype.updateDisplayImp=function(ve){if(this.clearDisplayImp(),this.userObject){if(this.userObject.visible){var ne=this.mxDatabase.addLayer(this.userObject.getLayer());if(!ne)return console.log("mxassert(0) this.layerRecord is null"),!1;this.threeObjectGroup=new c.Object3D;var Ue=new y.McGiWorldDraw(ve,y.McGiWorldDrawType.kWorldDraw);Ue.setupForEntity(this.userObject),this.worldDraw(Ue);for(var De=Ue.getEntitys(),Ve=De.length,rt=0;rt<Ve;rt++){var Ae=De[rt];(Ae.MxDbEntity=this).threeObjectGroup.add(Ae)}this.userObject.isUseSmallcoordDisplay()?this.layerObjectGroup=ne.getGroup_SmallCoord():this.layerObjectGroup=ne.getGroup(),this.layerObjectGroup.add(this.threeObjectGroup)}}else m.MxTools.MxASSERT(!1,"this.userObject == null")},fe.prototype.worldDraw=function(ve){this.userObject.worldDraw(ve)},fe.prototype.getGripPoints=function(){return this.userObject.getGripPoints()},fe.prototype.getClosestPointTo=function(ve,ne){return this.userObject.getClosestPointTo(ve,ne)},fe.prototype.getUserObject=function(){return this.userObject},fe.prototype.clone=function(ve){var ne=new fe;return ne.initUserObject(this.userObject.clone(ve)),ne},fe.prototype.transformBy=function(ve){this.userObject.transformBy(ve)},fe.prototype.setColor=function(ve){this.userObject.setColor(ve)},fe.prototype.onEndGripEidt=function(){this.userObject.onEndGripEidt()},fe.prototype.onStartGripEidt=function(){return this.userObject.onStartGripEidt()},fe.prototype.getColor=function(){return this.userObject.getColor()},fe.prototype.getMxObject=function(){return this.mxDatabase?this.mxDatabase.getMxObject():null},fe.prototype.onViewChange=function(){return!!this.userObject&&this.userObject.onViewChange()},fe);function fe(){this.threeObjectGroup=null,this.userObject=null,this.mxDatabase=null,this.isDirtyDisplay=!1,this.layerObjectGroup=null,this.id=0}l.MxDbEntity=J},{"../MxManager":29,"../MxTools":38,"../MxType":39,"../Operate/McGiWorldDraw":44,three:19}],70:[function(t,e,l){var n,u=this&&this.__extends||(n=function(Ve,rt){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(Ae,Te){Ae.__proto__=Te}||function(Ae,Te){for(var Xe in Te)Object.prototype.hasOwnProperty.call(Te,Xe)&&(Ae[Xe]=Te[Xe])})(Ve,rt)},function(Ve,rt){function Ae(){this.constructor=Ve}n(Ve,rt),Ve.prototype=rt===null?Object.create(rt):(Ae.prototype=rt.prototype,new Ae)});Object.defineProperty(l,"__esModule",{value:!0}),l.MxDbEntityGrip=l.MxDbEntityGripJig=l.MxGetWordDrawxDataForThreeJsObject=l.MxGetMxDbEntitForThreeJsObject=l.MxDbEntityGripData=void 0;var c=t("three"),y=t("../MxFun"),b=t("../MxDrawData"),m=t("../Operate/MxJig"),O=t("../Operate/MxJigCmdManager"),N=t("../Operate/McGiWorldDraw"),L=t("../MxManager"),G=t("../MxType"),q=function(){this.threeObject=null};function J(Ve){for(var rt=null;Ve&&!(rt=Ve.MxDbEntity)&&Ve.parent;)Ve=Ve.parent;return rt}l.MxDbEntityGripData=q,l.MxGetMxDbEntitForThreeJsObject=J,l.MxGetWordDrawxDataForThreeJsObject=function(Ve){for(var rt=null;Ve&&!(rt=Ve.MxWordDrawXData)&&Ve.parent;)Ve=Ve.parent;return rt};var fe,ve=(u(ne,fe=m.McEdJigCommand),ne.prototype.sampler=function(){var Ve=O.MxJigCmdManager.InType.kGetBegan|O.MxJigCmdManager.InType.kGetEnd,rt=this.acquirePoint(Ve);return rt.status==O.MxJigCmdManager.DragStatus.kNormal&&(this.currPt=rt.pt),rt.status},ne.prototype.getTypeName=function(){return"MxGripEdit"},ne.prototype.onStartCommand=function(){this.iscallOnStartCommand=!0,fe.prototype.onStartCommand.call(this)},ne.prototype.done=function(Ve){if(Ve==O.MxJigCmdManager.DragStatus.kNormal){var rt=this.currPt.clone();rt.sub(this.dragBasePt);for(var Ae=this.getMxObject(),Te=Ae.getMxDatabase(),Xe=Ae.getMxDatabase().getGripManager(),ie=this.grips.length,ue=new Set,pt=[],mt=0;mt<ie;mt++){var Tt=this.grips[mt],kt=this.ents[mt];Xe.deleteGripData(kt.objectId()),kt.getUserObject().moveGripPointsAt(Tt.iIndex,rt),Xe.addGripFromEntity(kt),kt.upDisplay(),ue.add(kt.objectId());var It={type:"mxdraw",id:kt.objectId(),index:Tt.iIndex,curentPoint:this.currPt,point:Tt.point,offset_x:rt.x,offset_y:rt.y};pt.push(It)}Ae.updateDisplay(),0<pt.length&&Ae.callEvent("objectGripEdit",pt),Te.getSelectManager().upSelectDilsplay(ue)}var nn=this.ents.length;for(mt=0;mt<nn;mt++)(kt=this.ents[mt]).onEndGripEidt(),Ve!=O.MxJigCmdManager.DragStatus.kNormal&&kt.upDisplay();return O.MxJigCmdManager.DoneStatius.kExitCommand},ne.prototype.upDisplay=function(){var Ve=this.currPt.clone();if(Ve.sub(this.dragBasePt),!(Ve.length()<.001)){if(this.iscallOnStartCommand){for(var rt=this.ents.length,Ae=0;Ae<rt;Ae++){var Te=this.ents[Ae];this.aryParam.push(Te.onStartGripEidt())}this.iscallOnStartCommand=!1}var Xe=this.getMxObject(),ie=this.grips.length;for(Ae=0;Ae<ie;Ae++){var ue=this.grips[Ae],pt=(Te=this.ents[Ae],this.aryParam[Ae]),mt=Te.clone(G.MxType.MxCloneType.kDragClone);mt.getUserObject().moveGripPointsAt(ue.iIndex,Ve);var Tt=new N.McGiWorldDraw(Xe,N.McGiWorldDrawType.kDynDragDraw);Tt.setupForEntity(mt.getUserObject()),mt.worldDraw(Tt);var kt=Tt.getEntitys(),It=kt.length,nn=31;pt&&pt.renderOrder&&(nn=pt.renderOrder);for(var tn=0;tn<It;tn++)this.drawEntity(kt[tn],nn,mt.getUserObject().isUseSmallcoordDisplay())}}},ne);function ne(Ve,rt,Ae){var Te=fe.call(this)||this;return Te.aryParam=[],Te.iscallOnStartCommand=!0,Te.dragBasePt=Ve,Te.grips=rt,Te.ents=Ae,Te.currPt=Ve,Te.iscallOnStartCommand=!0,Te}l.MxDbEntityGripJig=ve;var Ue=(De.prototype.getAllSelect=function(){var Ve=[];return this.mapGrips.forEach(function(rt,Ae){Ve.push(Ae)}),Ve},De.prototype.getParentGroup=function(){return this.drawGroup||(this.drawGroup=new c.Group,this.drawGroup.renderOrder=L.MxData.iGripRenderOrder,this.database.getMxObject().getTheTempDrawContainer_SmallCoord().add(this.drawGroup)),this.drawGroup},De.prototype.reInit=function(){this.removeAllGrips(),this.drawGroup&&y.MxFun.removeThreejsObject(this.drawGroup,this.database.getMxObject().getTheTempDrawContainer_SmallCoord()),this.drawGroup=null},De.prototype.removeAllGrips=function(){if(this.mapGrips.size==0)return!1;var Ve=this.getParentGroup();return this.mapGrips.forEach(function(rt,Ae,Te){for(var Xe=rt.length,ie=0;ie<Xe;ie++){var ue=rt[ie];y.MxFun.removeThreejsObject(ue.threeObject,Ve)}}),this.mapGrips=new Map,!0},De.prototype.deleteGripData=function(Ve){var rt=this.getParentGroup(),Ae=this.mapGrips.get(Ve);if(Ae)for(var Te=Ae.length,Xe=0;Xe<Te;Xe++){var ie=Ae[Xe];y.MxFun.removeThreejsObject(ie.threeObject,rt)}this.mapGrips.delete(Ve)},De.prototype.createGripDisplayObject=function(Ve){var rt=this.database.getMxObject(),Ae=this.getParentGroup();Ve.geometry=new c.Geometry;var Te=rt.toSmallcoord2(Ve.point.x,Ve.point.y,Ve.point.z),Xe=rt.screenCoordLong2World(b.MxDrawData.m_dInputRectWidth/2);Ve.geometry.vertices.push(new c.Vector3(Te.x-Xe,Te.y-Xe,0)),Ve.geometry.vertices.push(new c.Vector3(Te.x-Xe,Te.y+Xe,0)),Ve.geometry.vertices.push(new c.Vector3(Te.x+Xe,Te.y+Xe,0)),Ve.geometry.vertices.push(new c.Vector3(Te.x+Xe,Te.y-Xe,0)),Ve.geometry.faces.push(new c.Face3(0,1,2)),Ve.geometry.faces.push(new c.Face3(2,3,0)),Ve.geometry.computeFaceNormals(),Ve.geometry.computeVertexNormals();var ie=new c.MeshBasicMaterial({color:255,transparent:!0,depthTest:!1,side:c.DoubleSide,opacity:.9}),ue=new c.Mesh(Ve.geometry,ie);Ae.add(ue),Ve.threeObject=ue},De.prototype.addGripData=function(Ve,rt,Ae){var Te=this.mapGrips.get(Ve);Te==null&&(Te=new Array,this.mapGrips.set(Ve,Te));var Xe=new q;return Xe.iIndex=rt,Xe.point=new c.Vector3(Ae.x,Ae.y,0),Te.push(Xe),Xe},De.prototype.hitTest=function(Ve){var rt=this,Ae={grips:new Array,ents:new Array,pt:Ve},Te=new c.Vector3(Ve.x,Ve.y,0),Xe=this.database.getMxObject(),ie=Xe.viewCoordLong2Cad(b.MxDrawData.m_dInputRectWidth/2);return this.mapGrips.forEach(function(ue,pt){for(var mt=ue.length,Tt=0;Tt<mt;Tt++){var kt=ue[Tt];if(kt.point.distanceTo(Te)<=ie){var It=rt.database.getEntity(pt),nn=!0;Xe.hasEvent("whetherEditTheGripPoint")&&(nn=Xe.callEvent("whetherEditTheGripPoint",{entity:It.getUserObject(),index:kt.iIndex})),nn&&(Ae.grips.push(kt),Ae.ents.push(It));break}}}),Ae},De.prototype.onMouseLBDown=function(Ve){if(!b.MxDrawData.m_isEnableGripEidt)return!1;var rt=this.hitTest(Ve);return rt.grips.length!=0&&(y.MxFun.sendStringToExecute("Mx_FrontEndWebpageGripEdit",rt),!0)},De.prototype.gripEditImp=function(Ve){var rt=Ve.grips,Ae=Ve.ents,Te=Ve.pt,Xe=new ve(Te,rt,Ae);Xe.setDisableDynInput(!0),Xe.setDisableOsnap(!0),O.MxJigCmdManager.runCmd(Xe)},De.prototype.doWindowsSelect=function(Ve,rt){},De.prototype.addGripFromEntity=function(Ve){if(b.MxDrawData.m_isEnableGripEidt){var rt=Ve.getGripPoints(),Ae=Ve.objectId();this.deleteGripData(Ae);for(var Te=0;Te<rt.length;Te++){var Xe=this.addGripData(Ae,Te,rt[Te]);this.createGripDisplayObject(Xe)}}},De.prototype.addSelect=function(Ve,rt,Ae){Ae===void 0&&(Ae=!0);var Te=this.database.getSelectManager(),Xe=!1;if(this.getAllSelect().forEach(function(pt){pt==Ve&&(Xe=!0)}),Xe)return!1;var ie=this.database.getMxObject().getMxEntity(Ve);if(!ie)return!1;var ue=new Set;return ue.add(Ve),Ae&&this.addGripFromEntity(ie),Te.upSelectDilsplay(ue),rt&&this.fireMxEntitySelectChange(),!0},De.prototype.fireMxEntitySelectChange=function(){var Ve=this.database.getMxObject();this.isCallingMxEntitySelectChange||(this.isCallingMxEntitySelectChange=!0,Ve.callEvent("mxdrawSelectChange",this.getAllSelect()),this.isCallingMxEntitySelectChange=!1)},De.prototype.doPointSelect=function(Ve){for(var rt=!1,Ae=this.database.getSelectManager(),Te=this.database.getMxObject(),Xe=Ae.isEmptySelect(),ie=!1,ue=Te.viewCoordLong2Cad(.5*b.MxDrawData.m_dInputRectWidth),pt=function(){Te.pointMultipleSelect()||(mt.removeAllGrips()&&(ie=!0),Ae.removeAllEntity()&&(ie=!0),Te.getMcObject().isValid()&&(ie=Te.getMcObject().getGripManager().clearAll()));var Tt=mt.database.getIntersectObjects(Ve);if(Tt.length==0)return Te.updateDisplay(),"break";var kt=Te.screenCoord2Current(Ve.x,Ve.y,Ve.z),It=mt,nn=new Set;Tt.forEach(function(_n){var Dn=J(_n.object);if(Dn){var an=Dn.objectId();if(It.database.isValidId(an)&&!nn.has(an)){var Rn=Dn.getClosestPointTo(kt,1),Lt=!1;(!Rn||Rn.distanceTo(kt)<ue)&&(Lt=!0),Lt&&(nn.add(an),It.addGripFromEntity(Dn))}}});var tn=new Set,pn=mt.database.getGroupDictionary();return nn.forEach(function(_n){tn.add(_n),pn.getEntityInGroup(_n).forEach(function(Dn){Dn.getAll().forEach(function(an){It.database.isValidId(an)&&tn.add(an)})})}),ie=!0,Ae.upSelectDilsplay(tn),Te.updateDisplay(),rt=!0,"break"},mt=this;pt()!=="break";);return!ie&&Xe==Ae.isEmptySelect()||this.fireMxEntitySelectChange(),rt},De);function De(Ve){this.database=null,this.mapGrips=new Map,this.isCallingMxEntitySelectChange=!1,this.drawGroup=null,this.database=Ve}l.MxDbEntityGrip=Ue},{"../MxDrawData":22,"../MxFun":27,"../MxManager":29,"../MxType":39,"../Operate/McGiWorldDraw":44,"../Operate/MxJig":53,"../Operate/MxJigCmdManager":54,three:19}],71:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxDbEntitySelect=void 0;var n=t("three"),u=t("../MxFun"),c=t("three.meshline"),y=t("../Operate/McGiWorldDraw"),b=t("../MxManager"),m=(O.prototype.setRenderOrder=function(N){this.iRenderOrder=N},O.prototype.getRenderOrder=function(){return this.iRenderOrder},O.prototype.setCanvasSize=function(N,L){this.canvasWidth==N&&this.canvasHeight==L||(this.canvasWidth=N,this.canvasHeight=L,this.material.resolution=new n.Vector2(this.canvasWidth,this.canvasHeight),this.material.needsUpdate=!0)},O.prototype.removeAllEntity=function(){return this.mapIdToThreeObject.size!=0&&(this.mapIdToThreeObject.forEach(function(N){for(var L=N.length,G=0;G<L;G++){var q=N[G];u.MxFun.removeThreejsObject(q,q.parentObject)}}),this.mapIdToThreeObject.clear(),!0)},O.prototype.isEmptySelect=function(){return this.mapIdToThreeObject.size==0},O.prototype.getParentObject=function(N){return N?this.mxDatabase.getMxObject().getTheTempDrawContainer_SmallCoord():this.mxDatabase.getMxObject().getTheTempDrawContainer()},O.prototype.getAllSelect=function(){var N=[];return this.mapIdToThreeObject.forEach(function(L,G){N.push(G)}),N},O.prototype.setPrvCommandSelect=function(N){this.aryPrvCommandSelect=N},O.prototype.getPrvCommandSelect=function(){return this.aryPrvCommandSelect},O.prototype.deleteSelect=function(N){var L=this.mapIdToThreeObject.get(N);if(L){for(var G=L.length,q=0;q<G;q++){var J=L[q];u.MxFun.removeThreejsObject(J,J.parentObject)}this.mapIdToThreeObject.delete(N)}},O.prototype.upSelectDilsplayFromId=function(N){var L=new Set;L.add(N),this.upSelectDilsplay(L)},O.prototype.upSelectDilsplay=function(N){var L=this,G=new y.McGiWorldDrawSelect(this.mxDatabase.getMxObject(),this);N.forEach(function(q){L.deleteSelect(q);var J=L.mxDatabase.getEntity(q);J&&(G.setSmallCoordDraw(J.getUserObject().isUseSmallcoordDisplay()),G.setCurEntityId(q),J.worldDraw(G))})},O.prototype.addCircleDisplay=function(N,L,G,q){var J=new n.CircleGeometry(G,64,3,2*Math.PI);if(J.vertices.shift(),J.vertices.length!=0){J.vertices.push(J.vertices[0]);var fe=3*J.vertices.length;if(fe!=0){for(var ve=this.getParentObject(q),ne=new Float32Array(fe),Ue=0,De=0;Ue+2<fe;Ue+=3,De++)ne[Ue]=J.vertices[De].x+L.x,ne[Ue+1]=J.vertices[De].y+L.y,ne[Ue+2]=L.z;var Ve=new c.MeshLine;Ve.setGeometry(ne);var rt=new n.Mesh(Ve.geometry,this.material);rt.renderOrder=this.iRenderOrder,(rt.parentObject=ve).add(rt);var Ae=this.mapIdToThreeObject.get(N);Ae||(Ae=new Array,this.mapIdToThreeObject.set(N,Ae)),Ae.push(rt)}}},O.prototype.addLineDisplay=function(N,L,G,q){var J=this.getParentObject(q),fe=new Float32Array(6);fe[0]=L.x,fe[1]=L.y,fe[2]=0,fe[3]=G.x,fe[4]=G.y,fe[5]=0;var ve=new c.MeshLine;ve.setGeometry(fe);var ne=new n.Mesh(ve.geometry,this.material);ne.renderOrder=this.iRenderOrder,(ne.parentObject=J).add(ne);var Ue=this.mapIdToThreeObject.get(N);Ue||(Ue=new Array,this.mapIdToThreeObject.set(N,Ue)),Ue.push(ne)},O);function O(N){this.mapIdToThreeObject=new Map,this.canvasWidth=800,this.canvasHeight=500,this.mxDatabase=null,this.material=new c.MeshLineMaterial({useMap:!1,color:new n.Color(2641557),opacity:.8,resolution:new n.Vector2(800,500),sizeAttenuation:!1,lineWidth:10,transparent:!0,depthTest:!1}),this.iRenderOrder=b.MxData.iSelectRenderOrder,this.aryPrvCommandSelect=[],this.mxDatabase=N}l.MxDbEntitySelect=m},{"../MxFun":27,"../MxManager":29,"../Operate/McGiWorldDraw":44,three:19,"three.meshline":18}],72:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxDbGroupDictionary=l.MxDbGroup=void 0;var n=(u.prototype.name=function(){return this.sName},u.prototype.append=function(b){this.has(b)||this.setId.add(b)},u.prototype.clear=function(){this.setId=new Set},u.prototype.getAll=function(){var b=[];return this.setId.forEach(function(m){b.push(m)}),b},u.prototype.has=function(b){return this.setId.has(b)},u.prototype.delete=function(b){return this.setId.delete(b)},u);function u(b){this.setId=new Set,this.sName="",this.sName=b}l.MxDbGroup=n;var c=(y.prototype.getAt=function(b){return this.mapNameToGroup.get(b)},y.prototype.delete=function(b){return!!this.mapNameToGroup.has(b)&&this.mapNameToGroup.delete(b)},y.prototype.add=function(b){var m=this.mapNameToGroup.get(b);return m||(m=new n(b),this.mapNameToGroup.set(b,m),m)},y.prototype.dwgOut=function(b){var m=[];return this.mapNameToGroup.forEach(function(O,N){m.push(N)}),b.groups=m,b},y.prototype.dwgIn=function(b){var m=this;return b.groups.forEach(function(O){var N=new n(O);m.mapNameToGroup.set(O,N)}),!0},y.prototype.getEntityInGroup=function(b){var m=[];return this.mapNameToGroup.forEach(function(O){O.has(b)&&m.push(O)}),m},y.prototype.getEntityInGroupName=function(b){var m=[];return this.mapNameToGroup.forEach(function(O,N){O.has(b)&&m.push(N)}),m},y);function y(){this.mapNameToGroup=new Map}l.MxDbGroupDictionary=c},{}],73:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxDbLayerTableRecord=void 0;var n=t("three"),u=(c.prototype.getGroup=function(){return this.group},c.prototype.getGroup_SmallCoord=function(){return this.group_SmallCoord},c.prototype.getName=function(){return this.name},c.prototype.setName=function(y){this.name=y},c.prototype.setVisible=function(y){this.visible=y,this.group.visible=y,this.group_SmallCoord.visible=y},c.prototype.getVisible=function(){return this.visible},c.prototype.init=function(y,b,m){return this.name=y,b.add(this.group),m.add(this.group_SmallCoord),!0},c.prototype.dwgIn=function(y){return this.visible=y.visible,this.name=y.name,this.group.visible=this.visible,this.group_SmallCoord.visible=this.visible,!0},c.prototype.dwgOut=function(y){return y.visible=this.visible,y.name=this.name,y},c);function c(){this.group=new n.Group,this.group_SmallCoord=new n.Group,this.name="",this.visible=!0}l.MxDbLayerTableRecord=u},{three:19}],74:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.MxDbTextureManager=void 0;var n=t("three"),u=(c.prototype.loadImage=function(y,b){var m=this.mapImageUrlToMaterialTexture.get(y);if(m)b(m);else{var O=this;new n.TextureLoader().load(y,function(N){var L=new n.MeshLambertMaterial({map:N,transparent:!0,side:n.DoubleSide});L.map&&(L.map.needsUpdate=!0),O.mapImageUrlToMaterialTexture.set(y,L),b&&b(L)},void 0,function(N){console.log(N),b&&b(null)})}},c);function c(){this.mapImageUrlToMaterialTexture=new Map}l.MxDbTextureManager=u},{three:19}],75:[function(t,e,l){var n,u=this&&this.__extends||(n=function(ie,ue){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(pt,mt){pt.__proto__=mt}||function(pt,mt){for(var Tt in mt)Object.prototype.hasOwnProperty.call(mt,Tt)&&(pt[Tt]=mt[Tt])})(ie,ue)},function(ie,ue){function pt(){this.constructor=ie}n(ie,ue),ie.prototype=ue===null?Object.create(ue):(pt.prototype=ue.prototype,new pt)});Object.defineProperty(l,"__esModule",{value:!0}),l.MxDrawObject3dThreeJS=l.MxDrawMapBoxThreeJS=l.MxDrawObject2dThreeJS=l.MxDrawThreeJS=l.MxThreeJSType=void 0;var c,y,b,m=t("three"),O=t("../Operate/MxJigCmdManager"),N=t("three-orbitcontrols"),L=t("../UI/MxUiVue"),G=(u(q,c=N.OrbitControls),q.prototype.update=function(){},q);function q(ie,ue){return c.call(this,ie,ue)||this}(b=y=l.MxThreeJSType||(l.MxThreeJSType={}))[b.k2d=0]="k2d",b[b.k3d=1]="k3d",b[b.kMapBox=2]="kMapBox";var J=(fe.prototype.screenCoord2World=function(ie,ue,pt){return this.mxObject.screenCoord2World_mxdrawThreeJS_call(ie,ue,pt)},fe.prototype.worldCoord2Screen=function(ie,ue,pt){return this.mxObject.worldCoord2Screen_mxdrawThreeJS_call(ie,ue,pt)},fe.prototype.getDomMousePos=function(ie){},fe.prototype.createRaycaster=function(ie){var ue=new m.Raycaster;ue.linePrecision=this.mxObject.screenCoordLong2World(10);var pt=this.mxObject.getCanvas(),mt=pt.clientWidth,Tt=pt.clientHeight,kt=new m.Vector2(ie.x/mt*2-1,-ie.y/Tt*2+1);return ue.setFromCamera(kt,this.mxObject.getCamera()),ue},fe.prototype.zoomW=function(ie,ue,pt,mt,Tt){return this.mxObject.zoomW_call(ie,ue,pt,Tt)},fe.prototype.zoomCenter=function(ie,ue,pt){return this.mxObject.zoomCenter_call(ie,ue)},fe.prototype.zoomScale=function(ie,ue){return this.mxObject.zoomScale_call(ie)},fe.prototype.setViewAngle=function(ie){return this.mxObject.setViewAngle_call(ie)},fe.prototype.startPanCommand=function(){return this.mxObject.startPanCommand_call()},fe.prototype.endPanCommand=function(){return this.mxObject.endPanCommand_call()},fe.prototype.isPaningCommand=function(){return this.mxObject.isPaningCommand_call()},fe);function fe(ie){this.mxObject=ie}l.MxDrawThreeJS=J;var ve,ne=(u(Ue,ve=J),Ue.prototype.onInitThreejs=function(){this.proxyObj.onInitThreejs()},Ue.prototype.onInitScene=function(){this.proxyObj.onInitScene()},Ue.prototype.getType=function(){return y.k2d},Ue.prototype.updateCameraDisplayRange=function(ie,ue,pt){this.proxyObj.updateCameraDisplayRangeImp(ie,ue,pt)},Ue.prototype.updateCameraForm3dViewData=function(ie){this.proxyObj.updateCameraForm3dViewDataImp(ie)},Ue.prototype.addControlsChangeEvent=function(){var ie=this.mxObject;this.mxObject.getOrbitControls().addEventListener("change",function(){O.MxJigCmdManager.OnThreeControlsChage(),ie.callViewChange(),ie.getMxDatabase().onViewChange(),ie.getMcObject().isValid()&&ie.getMcObject().getGripManager().onControlsChage(),ie.getTempMarkDraw().clear(!0),ie.updateDisplay()})},Ue.prototype.updateDisplay=function(ie){ie===void 0&&(ie=!1),this.mxObject.updateDisplayImplement(ie)},Ue.prototype.getRegistEventObject=function(){return this.mxObject.getCanvas()},Ue);function Ue(ie){var ue=ve.call(this,ie)||this;return ue.proxyObj=ie,ue}l.MxDrawObject2dThreeJS=ne;var De,Ve=(u(rt,De=J),rt.prototype.startPanCommand=function(){this.mapBox.map&&(this.isPaning=!0,this.bakPan=this.mapBox.map.dragPan.useMouseMiddle(!1),L.MxUiVue.setCursorType(L.MxUiVue.CursorType.kPan))},rt.prototype.endPanCommand=function(){this.mapBox.map&&this.isPaning&&(this.isPaning=!1,this.mapBox.map.dragPan.useMouseMiddle(this.bakPan),L.MxUiVue.setCursorType(L.MxUiVue.CursorType.kNormal))},rt.prototype.isPaningCommand=function(){return this.mapBox.map,this.isPaning},rt.prototype.mercatorCoord2CAD=function(ie,ue){var pt=new m.Vector3(ie,ue,0);return pt.applyMatrix4(this.mapBox.matMapToCad),pt},rt.prototype.cadToMercatorCoord=function(ie){return ie.applyMatrix4(this.mapBox.matCadToMap),ie},rt.prototype.setViewAngle=function(ie){this.mapBox.map&&this.mapBox.map.setBearing(180*ie/Math.PI)},rt.prototype.zoomCenter=function(ie,ue,pt){if(this.mapBox.map){var mt=this.cadToMercatorCoord(new m.Vector3(ie,ue,0)),Tt=this.mapBox.map.mercator_to_lnglat(mt.x,mt.y,0),kt=this.mapBox.map.getBounds(),It=.5*(kt._ne.wrap().lng-kt._sw.wrap().lng),nn=.5*(kt._ne.wrap().lat-kt._sw.wrap().lat);this.mapBox.map.fitBounds([[Tt.lng-It,Tt.lat-nn],[Tt.lng+It,Tt.lat+nn]],{animate:!!pt})}},rt.prototype.zoomScale=function(ie,ue){if(this.mapBox.map){var pt=this.mapBox.map.getBounds(),mt=.5*(pt._ne.wrap().lng-pt._sw.wrap().lng),Tt=.5*(pt._ne.wrap().lat-pt._sw.wrap().lat),kt=pt._sw.wrap().lng+mt,It=pt._sw.wrap().lat+Tt;mt*=ie,Tt*=ie,this.mapBox.map.fitBounds([[kt-mt,It-Tt],[kt+mt,It+Tt]],{animate:!!ue})}},rt.prototype.zoomW=function(ie,ue,pt,mt,Tt){if(this.mapBox.map)if(ie.distanceTo(ue)<1e-7)console.log("Mx:ZoomW param invalid");else{pt!==void 0&&pt&&(ie=this.mxObject2d.docCoord2Cad(ie.x,ie.y,0),ue=this.mxObject2d.docCoord2Cad(ue.x,ue.y,0));var kt=this.cadToMercatorCoord(ie),It=this.cadToMercatorCoord(ue),nn=this.mapBox.map.mercator_to_lnglat(kt.x,kt.y,0),tn=this.mapBox.map.mercator_to_lnglat(It.x,It.y,0),pn=Math.min(nn.lng,tn.lng),_n=Math.max(nn.lng,tn.lng),Dn=Math.min(nn.lat,tn.lat),an=Math.max(nn.lat,tn.lat);this.mapBox.map.fitBounds([[pn,Dn],[_n,an]],{animate:!!mt})}},rt.prototype.onInitScene=function(){},rt.prototype.addControlsChangeEvent=function(){},rt.prototype.updateDisplay=function(ie){this.mapBox.map&&(this.mapBox.map.repaint=!0)},rt.prototype.createRaycaster=function(ie){if(this.mapBox.map){var ue=ie.x/this.mapBox.map.transform.width*2-1,pt=-ie.y/this.mapBox.map.transform.height*2+1,mt=this.mxObject2d.getCamera(),Tt=new m.Raycaster;Tt.linePrecision=this.mxObject2d.screenCoordLong2World(10);var kt=new m.Matrix4().getInverse(mt.projectionMatrix),It=new m.Vector3().applyMatrix4(kt),nn=new m.Vector3(ue,pt,1).applyMatrix4(kt).clone().sub(It).normalize();return Tt.setFromCamera(new m.Vector2(ue,pt),mt),Tt.set(It,nn),Tt}return De.prototype.createRaycaster.call(this,ie)},rt.prototype.getRegistEventObject=function(){return this.mapBox.canvasContainer},rt.prototype.getType=function(){return y.kMapBox},rt.prototype.getDomMousePos=function(ie){return this.mapBox.map?this.mapBox.map.dom_mousePos(ie):void 0},rt.prototype.screenCoord2World=function(ie,ue,pt){if(this.mapBox.map){var mt=this.mapBox.map.unproject({x:ie,y:ue}),Tt=this.mapBox.map.lnglat_to_mercator(mt.lng,mt.lat),kt=new m.Vector3(Tt.x,Tt.y,0);return kt.applyMatrix4(this.mapBox.matMapToCADDrawCoord),kt}return De.prototype.screenCoord2World.call(this,ie,ue,pt)},rt.prototype.worldCoord2Screen=function(ie,ue,pt){if(this.mapBox.map){var mt=new m.Vector3(ie,ue,pt);mt.applyMatrix4(this.mapBox.matCADDrawCoordToMap);var Tt=this.mapBox.map.mercator_to_lnglat(mt.x,mt.y,0),kt=this.mapBox.map.project([Tt.lng,Tt.lat]);return new m.Vector3(kt.x,kt.y,0)}De.prototype.worldCoord2Screen.call(this,ie,ue,pt)},rt.prototype.onInitThreejs=function(){var ie=this,ue=this.mapBox.threebox;if(ue){var pt=ue.camera,mt=ue.scene,Tt=this.mapBox.canvas,kt=ue.renderer;this.canvas=Tt,kt.autoClear=!1;var It=new G(pt,Tt);this.mxObject2d.mapBoxInitThreeJSObject(mt,pt,kt,It)}else{this.mxObject2d.onInitViewScene(),mt=new m.Scene;var nn=(Tt=this.mapBox.canvas).clientHeight,tn=Tt.clientWidth;pt=new m.OrthographicCamera(tn/-2,tn/2,nn/2,nn/-2,.1,1e21),this.canvas=Tt;var pn=new m.DirectionalLight(16777215);pn.position.set(0,-70,100).normalize(),mt.add(pn);var _n=new m.DirectionalLight(16777215);_n.position.set(0,70,100).normalize(),mt.add(_n);var Dn=this.mxObject2d.getRendererParam();(Dn=Dn||{}).canvas=Tt,Dn.context=this.mapBox.gl,(kt=new m.WebGLRenderer(Dn)).autoClear=!1,(It=new G(new m.Camera,Tt)).enabled=!1,this.mxObject2d.mapBoxInitThreeJSObject(mt,pt,kt,It)}this.mxObject2d.initRendererParam({retver:"webgl2",webgl2:!0});var an=this;this.mapBox.render=function(Rn,Lt){var wn=new m.Matrix4().fromArray(Lt);wn.multiply(ie.matCADDrawCoordToMap);var hn=new m.Vector3(0,0,0);if(hn.applyMatrix4(wn),1<hn.z){var xn=1-hn.z-1e-5;wn=new m.Matrix4().makeTranslation(0,0,xn).multiply(wn)}an.mxObject2d.mapBoxRender(Rn,wn,!!an.mapBox.threebox),an.mxObject2d.isRenderLoop()&&ie.mapBox.map&&(ie.mapBox.map.repaint=!0)},this.mapBox.onResize=function(){an.mxObject2d.mapBox_onResizeImp(an.canvas.clientWidth,an.canvas.clientHeight)}},rt.prototype.updateCameraForm3dViewData=function(ie){console.log("assert(0) map does not support 3ddwg")},rt.prototype.updateCameraDisplayRange=function(ie,ue,pt){if(this.mxObject2d.isCppMxCAD()){(kt=new m.Matrix4).makeTranslation(-this.mapBox.cadOrigin.x,-this.mapBox.cadOrigin.y,-this.mapBox.cadOrigin.z),(It=new m.Matrix4).makeTranslation(this.mapBox.mapOrigin.x,this.mapBox.mapOrigin.y,this.mapBox.elevation),(nn=new m.Matrix4).makeScale(this.mapBox.mapLenInCADUnits,-this.mapBox.mapLenInCADUnits,this.mapBox.mapLenInCADUnits);var mt=It.multiply(nn).multiply(kt),Tt=this.mxObject2d.getDoc2CADMatrix();this.matCADDrawCoordToMap=mt.clone().multiply(Tt),this.mapBox.matcadtsmall=new m.Matrix4,this.mapBox.matcadtsmall.getInverse(Tt),this.mapBox.matCADDrawCoordToMap=this.matCADDrawCoordToMap,this.mapBox.matMapToCADDrawCoord=new m.Matrix4,this.mapBox.matMapToCADDrawCoord.getInverse(this.matCADDrawCoordToMap),this.mapBox.matCadToMap=mt,this.mapBox.matMapToCad=new m.Matrix4,this.mapBox.matMapToCad.getInverse(mt),1e-5<Math.abs(pt)&&this.setViewAngle(pt),this.zoomW(ie,ue,!0,!1)}else{var kt,It,nn;(kt=new m.Matrix4).makeTranslation(-this.mapBox.cadOrigin.x,-this.mapBox.cadOrigin.y,-this.mapBox.cadOrigin.z),(It=new m.Matrix4).makeTranslation(this.mapBox.mapOrigin.x,this.mapBox.mapOrigin.y,this.mapBox.elevation),(nn=new m.Matrix4).makeScale(this.mapBox.mapLenInCADUnits,-this.mapBox.mapLenInCADUnits,this.mapBox.mapLenInCADUnits);var tn=It.multiply(nn).multiply(kt),pn=this.mxObject2d.getWorldToDoc();this.matCADDrawCoordToMap=tn.clone().multiply(pn),this.mapBox.matcadtsmall=new m.Matrix4,this.mapBox.matcadtsmall.getInverse(pn),this.mapBox.matCADDrawCoordToMap=this.matCADDrawCoordToMap,this.mapBox.matMapToCADDrawCoord=new m.Matrix4,this.mapBox.matMapToCADDrawCoord.getInverse(this.matCADDrawCoordToMap),this.mapBox.matCadToMap=tn,this.mapBox.matMapToCad=new m.Matrix4,this.mapBox.matMapToCad.getInverse(tn)}},rt);function rt(ie,ue){var pt=De.call(this,ue)||this;return pt.matCADDrawCoordToMap=new m.Matrix4,pt.isPaning=!1,pt.bakPan=!0,pt.mapBox=ie,pt.mxObject2d=ue,pt.mapBox.matMapToCad=pt.mapBox.matCadToMap=pt.mapBox.matCADDrawCoordToMap=pt.mapBox.matMapToCADDrawCoord=new m.Matrix4,pt}l.MxDrawMapBoxThreeJS=Ve;var Ae,Te=(u(Xe,Ae=J),Xe.prototype.onInitThreejs=function(){this.proxyObj.onInitThreejs()},Xe.prototype.onInitScene=function(){this.proxyObj.onInitScene()},Xe.prototype.getType=function(){return y.k3d},Xe.prototype.updateCameraDisplayRange=function(ie,ue,pt){},Xe.prototype.updateCameraForm3dViewData=function(ie){},Xe.prototype.addControlsChangeEvent=function(){var ie=this.mxObject;this.mxObject.getOrbitControls().addEventListener("change",function(){O.MxJigCmdManager.OnThreeControlsChage(),ie.callViewChange(),ie.getMxDatabase().onViewChange(),ie.getMcObject().isValid()&&ie.getMcObject().getGripManager().onControlsChage(),ie.getTempMarkDraw().clear(!0),ie.updateDisplay()})},Xe.prototype.updateDisplay=function(ie){ie===void 0&&(ie=!1),this.mxObject.updateDisplayImplement(ie)},Xe.prototype.getRegistEventObject=function(){return this.mxObject.getCanvas()},Xe);function Xe(ie){var ue=Ae.call(this,ie)||this;return ue.proxyObj=ie,ue}l.MxDrawObject3dThreeJS=Te},{"../Operate/MxJigCmdManager":54,"../UI/MxUiVue":65,three:19,"three-orbitcontrols":17}],76:[function(t,e,l){var n,u=this&&this.__extends||(n=function(fe,ve){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ne,Ue){ne.__proto__=Ue}||function(ne,Ue){for(var De in Ue)Object.prototype.hasOwnProperty.call(Ue,De)&&(ne[De]=Ue[De])})(fe,ve)},function(fe,ve){function ne(){this.constructor=fe}n(fe,ve),fe.prototype=ve===null?Object.create(ve):(ne.prototype=ve.prototype,new ne)});function c(){}Object.defineProperty(l,"__esModule",{value:!0}),l.McDraw2d=l.McDraw3d=l.McDraw3dViewData=l.McDraw3dBase=void 0;var y=t("three");l.McDraw3dBase=c;var b=(m.prototype.updateCamera=function(fe,ve,ne,Ue){var De=this.width,Ve=this.height;De<1e-5&&(De=1e-5),Ve<1e-5&&(Ve=1e-5);var rt=ne/Ue,Ae=rt*Ve;De<Ae?De=Ae:Ve=De/rt,fe.left=.5*-De,fe.right=.5*De,fe.top=.5*Ve,fe.bottom=.5*-Ve,fe.far=this.frontClip,fe.near=this.backClip,fe.up=this.up,fe.zoom=1;var Te=this.target.clone().add(this.dir);fe.position.set(Te.x,Te.y,Te.z),fe.lookAt(this.target),fe.updateProjectionMatrix(),ve.target.x=this.target.x,ve.target.y=this.target.y,ve.target.z=this.target.z,ve.update()},m);function m(){}l.McDraw3dViewData=b;var O,N=(u(L,O=c),L.prototype.is3DMode=function(){return!0},L.prototype.onResize=function(fe,ve,ne,Ue){var De=fe.right-fe.left,Ve=fe.top-fe.bottom;De<1e-5&&(De=1e-5),Ve<1e-5&&(Ve=1e-5);var rt=ne/Ue,Ae=rt*Ve;return De<Ae?De=Ae:Ve=De/rt,fe.left=.5*-De,fe.right=.5*De,fe.top=.5*Ve,fe.bottom=.5*-Ve,fe.updateProjectionMatrix(),ve.update(),!0},L.prototype.initDisplayRange=function(fe){var ve=this.mcObject.mxObject;ve.intiDoc2Wold(new y.Matrix4),ve.initCAD2Doc(JSON.parse(fe.DToSMat)),ve.initializingObjectMatrix();var ne=new b;ne.dir=new y.Vector3(fe.vecDirectionx,fe.vecDirectiony,fe.vecDirectionz),ne.up=new y.Vector3(fe.vecUpx,fe.vecUpy,fe.vecUpz),ne.target=new y.Vector3(fe.targetx,fe.targety,fe.targetz),ne.height=fe.height,ne.width=fe.width,ne.backClip=fe.backClip,ne.frontClip=fe.frontClip,ve.updateCameraForm3dViewData(ne)},L);function L(){return O!==null&&O.apply(this,arguments)||this}l.McDraw3d=N;var G,q=(u(J,G=c),J.prototype.is3DMode=function(){return!1},J.prototype.initDisplayRange=function(fe){var ve=this.mcObject.mxObject;ve.intiDoc2Wold(new y.Matrix4),ve.initCAD2Doc(JSON.parse(fe.DToSMat)),ve.initializingObjectMatrix(),ve.updateCameraDisplayRange(new y.Vector3(fe.pt1x,fe.pt1y,0),new y.Vector3(fe.pt2x,fe.pt2y,0),fe.viewangle)},J.prototype.onResize=function(fe,ve,ne,Ue){return this.mcObject.mxObject.callOnResizeImp(ne,Ue)},J);function J(){return G!==null&&G.apply(this,arguments)||this}l.McDraw2d=q},{three:19}],77:[function(t,e,l){var n,u=this&&this.__extends||(n=function(Ve,rt){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(Ae,Te){Ae.__proto__=Te}||function(Ae,Te){for(var Xe in Te)Object.prototype.hasOwnProperty.call(Te,Xe)&&(Ae[Xe]=Te[Xe])})(Ve,rt)},function(Ve,rt){function Ae(){this.constructor=Ve}n(Ve,rt),Ve.prototype=rt===null?Object.create(rt):(Ae.prototype=rt.prototype,new Ae)});Object.defineProperty(l,"__esModule",{value:!0}),l.McDrawGripJig=l.McDrawGrip=l.McDrawSlect=l.McDrawGripData=void 0;var c=t("three"),y=t("../MxFun"),b=t("../Operate/MxJig"),m=t("../Operate/MxJigCmdManager"),O=t("../MxManager"),N=t("../MxDrawData"),L=t("../MxTools"),G=function(){this.threeObject=null};l.McDrawGripData=G;var q=(J.prototype.add=function(Ve){return!this.setId.has(Ve)&&(this.setId.add(Ve),this.mcObj.HighlightEntity(Ve,!0),!0)},J.prototype.remove=function(Ve){this.setId.has(Ve)&&(this.setId.delete(Ve),this.mcObj.HighlightEntity(Ve,!1))},J.prototype.removeAll=function(){var Ve=this;this.setId.forEach(function(rt){Ve.mcObj.HighlightEntity(rt,!1)}),this.setId.clear()},J.prototype.getAllSelect=function(){var Ve=[];return this.setId.forEach(function(rt,Ae){Ve.push(Ae)}),Ve},J.prototype.getSelectCount=function(){return this.setId.size},J.prototype.isEmpty=function(){return this.setId.size==0},J);function J(Ve){this.mcObj=null,this.setId=new Set,this.mcObj=Ve}l.McDrawSlect=q;var fe=(ve.prototype.fireSelectChange=function(){this.isCallingSelectChange||(this.isCallingSelectChange=!0,this.mxObj.callEvent("selectChange",this.getAllSelect()),this.isCallingSelectChange=!1)},ve.prototype.getParentGroup=function(){return this.drawGroup||(this.drawGroup=new c.Group,this.drawGroup.renderOrder=O.MxData.iGripRenderOrder,this.mxObj.getTheTempDrawContainer_SmallCoord().add(this.drawGroup)),this.drawGroup},ve.prototype.reInit=function(){this.clearAll(),this.drawGroup&&y.MxFun.removeThreejsObject(this.drawGroup,this.mxObj.getTheTempDrawContainer_SmallCoord()),this.drawGroup=null,this.selectPoint1=null,this.selectPoint2=null},ve.prototype.removeAllEntity=function(){var Ve=this.getParentGroup();this.mapGrips.forEach(function(rt,Ae,Te){for(var Xe=rt.length,ie=0;ie<Xe;ie++){var ue=rt[ie];y.MxFun.removeThreejsObject(ue.threeObject,Ve)}}),this.mapGrips=new Map},ve.prototype.deleteGripData=function(Ve){var rt=this.getParentGroup(),Ae=this.mapGrips.get(Ve);if(Ae)for(var Te=Ae.length,Xe=0;Xe<Te;Xe++){var ie=Ae[Xe];y.MxFun.removeThreejsObject(ie.threeObject,rt)}this.mapGrips.delete(Ve)},ve.prototype.addGripData=function(Ve,rt,Ae,Te){var Xe=this.mapGrips.get(Ve);Xe==null&&(Xe=new Array,this.mapGrips.set(Ve,Xe));var ie=new G;return ie.iIndex=rt,ie.point=new c.Vector3(Ae,Te),Xe.push(ie),ie},ve.prototype.createGripDisplayObject=function(Ve){var rt=this.getParentGroup();Ve.geometry=new c.Geometry;var Ae=this.mxObj.toSmallcoord2(Ve.point.x,Ve.point.y,Ve.point.z),Te=this.mxObj.screenCoordLong2World(.5*N.MxDrawData.m_dInputRectWidth);Ve.geometry.vertices.push(new c.Vector3(Ae.x-Te,Ae.y-Te,0)),Ve.geometry.vertices.push(new c.Vector3(Ae.x-Te,Ae.y+Te,0)),Ve.geometry.vertices.push(new c.Vector3(Ae.x+Te,Ae.y+Te,0)),Ve.geometry.vertices.push(new c.Vector3(Ae.x+Te,Ae.y-Te,0)),Ve.geometry.faces.push(new c.Face3(0,1,2)),Ve.geometry.faces.push(new c.Face3(2,3,0)),Ve.geometry.computeFaceNormals(),Ve.geometry.computeVertexNormals();var Xe=L.MxTools.getColor(N.MxDrawData.m_gripPointColor),ie=L.MxTools.getOpacity(N.MxDrawData.m_gripPointColor),ue=new c.MeshBasicMaterial({color:Xe,transparent:!0,depthTest:!1,side:c.DoubleSide,opacity:ie}),pt=new c.Mesh(Ve.geometry,ue);rt.add(pt),Ve.threeObject=pt},ve.prototype.setPrvCommandSelect=function(Ve){this.aryPrvCommandSelect=Ve},ve.prototype.getPrvCommandSelect=function(){return this.aryPrvCommandSelect},ve.prototype.getAllSelect=function(){return this.mcSelect.getAllSelect()},ve.prototype.getSelectPoints=function(){var Ve=this.selectPoint1!==null;return Ve&&this.mcSelect.getSelectCount()==0&&this.aryPrvCommandSelect.length==0&&(Ve=!1),{point1:this.selectPoint1,point2:this.selectPoint2,isvalid:Ve}},ve.prototype.clearAll=function(){var Ve=this.mcSelect.isEmpty();return this.mcSelect.removeAll(),this.mapGrips.size==0?!Ve:(this.removeAllEntity(),!0)},ve.prototype.onControlsChage=function(){var Ve=this;if(this.mapGrips.size!=0){var rt=this.mxObj.screenCoordLong2World(.5*N.MxDrawData.m_dInputRectWidth),Ae=!1;this.mapGrips.forEach(function(Te,Xe,ie){for(var ue=Te.length,pt=0;pt<ue;pt++){var mt=Te[pt];if(mt.geometry.vertices.length==4){var Tt=Ve.mxObj.cadCoord2Doc(mt.point.x,mt.point.y,mt.point.z);mt.geometry.vertices[0].x=Tt.x-rt,mt.geometry.vertices[0].y=Tt.y-rt,mt.geometry.vertices[1].x=Tt.x-rt,mt.geometry.vertices[1].y=Tt.y+rt,mt.geometry.vertices[2].x=Tt.x+rt,mt.geometry.vertices[2].y=Tt.y+rt,mt.geometry.vertices[3].x=Tt.x+rt,mt.geometry.vertices[3].y=Tt.y-rt,mt.geometry.computeFaceNormals(),mt.geometry.computeVertexNormals(),mt.geometry.verticesNeedUpdate=!0,Ae=!0}}}),Ae&&this.mxObj.resetRenderer()}},ve.prototype.getGripNum=function(Ve){for(var rt=new Set,Ae=Ve.length(),Te=0;Te<Ae;Te++)rt.add(Ve.at(Te));var Xe=0;return this.mapGrips.forEach(function(ie,ue){rt.has(ue)||(Xe+=ie.length)}),Xe},ve.prototype.hitTest=function(Ve){var rt={grips:new Array,ids:new Array,pt:Ve},Ae=new c.Vector3(Ve.x,Ve.y,0),Te=this.mxObj.viewCoordLong2Cad(32);return this.mapGrips.forEach(function(Xe,ie){for(var ue=Xe.length,pt=0;pt<ue;pt++){var mt=Xe[pt];if(mt.point.distanceTo(Ae)<=Te){rt.grips.push(mt),rt.ids.push(ie),rt.pt=mt.point;break}}}),rt},ve.prototype.onMouseLBDown=function(Ve){if(!N.MxDrawData.m_isEnableGripEidt)return!1;var rt=this.hitTest(Ve);return rt.grips.length!=0&&(y.MxFun.sendStringToExecute("McDraw_GripEdit",rt),!0)},ve.prototype.gripEditImp=function(Ve){var rt=Ve.grips,Ae=Ve.ids,Te=Ve.pt,Xe=new Ue(Te,rt,Ae,this.mcObj);m.MxJigCmdManager.runCmd(Xe)},ve.prototype.addGridDisplay=function(Ve,rt){var Ae=this;Ve&&Ve.length()!=0&&(this.deleteGripData(rt),Ve.forEach(function(Te,Xe){var ie=Ae.addGripData(rt,Xe,Te.x,Te.y);Ae.createGripDisplayObject(ie)}))},ve.prototype.upEntityGridDisplay=function(Ve){if(!N.MxDrawData.m_isEnableGripEidt||Ve==0)return 0;var rt=this.mcObj.ObjectIdToObject(Ve);if(!rt)return 0;var Ae=rt.getGripPoints();return this.addGridDisplay(Ae,Ve),Ae.length()},ve.prototype.doPointSelect=function(Ve){if(!this.mcObj.mcObjectImp)return!1;var rt=this.mxObj.docCoordLong2Cad(this.mxObj.screenCoordLong2Doc(10)),Ae=this.mxObj.screenCoord2Doc(Ve.x,Ve.y,0),Te=this.mxObj.docCoord2Cad(Ae.x,Ae.y,Ae.z),Xe=this.mcObj.mcObjectImp.IntelliSelect_PointSelect(Te.x,Te.y,rt),ie=Xe.length();if(ie==0)return this.mcObj.mxappimp.DestroyMdGeLongArray(Xe),!1;this.mxObj.pointMultipleSelect()||(this.mxObj.getMxDatabase().clearMxCurrentSelect(),this.clearAll());for(var ue=ie+this.mcSelect.getSelectCount(),pt=0;pt<ie;pt++){var mt=Xe.at(pt);this.mcSelect.add(mt),ue<100&&this.upEntityGridDisplay(mt)}return this.selectPoint1=Te,this.selectPoint2=Te,this.fireSelectChange(),this.mcObj.mxappimp.DestroyMdGeLongArray(Xe),!0},ve.prototype.doRangeSelect=function(Ve,rt){if(this.mcObj.mcObjectImp){var Ae,Te=Ve.clone(),Xe=rt.clone();Ae=rt.x<Ve.x?0:1;for(var ie=this.mcObj.mcObjectImp.IntelliSelect_RangeSelect(Te.x,Te.y,Xe.x,Xe.y,Ae),ue=ie.length(),pt=ue+this.mcSelect.getSelectCount(),mt=this.getGripNum(ie),Tt=0;Tt<ue;Tt++){var kt=ie.at(Tt);this.mcSelect.add(kt),pt<50&&mt<200&&(mt+=this.upEntityGridDisplay(kt))}0<ue&&(this.selectPoint1=Te,this.selectPoint2=Xe,this.fireSelectChange()),this.mcObj.mxappimp.DestroyMdGeLongArray(ie)}},ve.prototype.addSelect=function(Ve,rt,Ae){if(Ae===void 0&&(Ae=!0),Ve==0)return!1;var Te=this.mcSelect.add(Ve);return Ae&&this.upEntityGridDisplay(Ve),rt&&this.fireSelectChange(),Te},ve);function ve(Ve,rt){this.mxObj=null,this.mcObj=null,this.mcSelect=null,this.mapGrips=new Map,this.aryPrvCommandSelect=[],this.drawGroup=null,this.isCallingSelectChange=!1,this.selectPoint1=null,this.selectPoint2=null,this.mxObj=Ve,this.mcObj=rt,this.mcSelect=new q(rt)}l.McDrawGrip=fe;var ne,Ue=(u(De,ne=b.McEdJigCommand),De.prototype.onExitCommand=function(Ve){this.tempEntity=null,this.tempEntityWordDraw=null,ne.prototype.onExitCommand.call(this,Ve)},De.prototype.sampler=function(){var Ve=m.MxJigCmdManager.InType.kGetBegan|m.MxJigCmdManager.InType.kGetEnd,rt=this.acquirePoint(Ve);if(rt.status==m.MxJigCmdManager.DragStatus.kNormal&&(this.currPt=rt.pt,this.tempEntity)){var Ae=new c.Vector3(rt.pt.x,rt.pt.y,rt.pt.z),Te=new c.Vector3(this.pt.x,this.pt.y,this.pt.z);this.tempEntityWordDraw=this.tempEntity.clone(),this.tempEntityWordDraw&&this.tempEntityWordDraw.moveGripPointsAt(this.grips[0].iIndex,Ae.x-Te.x,Ae.y-Te.y,Ae.z-Te.z)}return rt.status},De.prototype.getTypeName=function(){return"McDrawGripEdit"},De.prototype.done=function(Ve){if(Ve==m.MxJigCmdManager.DragStatus.kNormal){for(var rt=new c.Vector3(this.pt.x,this.pt.y,this.pt.z),Ae=new c.Vector3(this.currPt.x,this.currPt.y,this.currPt.z),Te=Ae.x-rt.x,Xe=Ae.y-rt.y,ie=this.getMxObject().getMcObject().getGripManager(),ue=this.grips.length,pt=[],mt=0;mt<ue;mt++){var Tt=this.grips[mt],kt=this.ids[mt],It=this.mcObj.ObjectIdToObject(kt);It&&It.moveGripPointsAt(Tt.iIndex,Te,Xe,0),ie.upEntityGridDisplay(kt),pt.push({type:"mxcad",id:kt,index:Tt.iIndex,curentPoint:this.currPt,point:Tt.point,offset_x:Te,offset_y:Xe})}0<pt.length&&this._mxObject.callEvent("objectGripEdit",pt)}return m.MxJigCmdManager.DoneStatius.kExitCommand},De.prototype.upDisplay=function(){this.mcObj.onReadyJigUpdateDispla(1,this.currPt),this.tempEntityWordDraw.tempRelationObject(),this.mcObj.onJigDrawEntityDisplay(this.tempEntityWordDraw.getImp()),this.tempEntityWordDraw.freeTempRelationObject()},De);function De(Ve,rt,Ae,Te){var Xe=ne.call(this)||this;return Xe.pt=Ve,Xe.grips=rt,Xe.ids=Ae,Xe.currPt=Ve,Xe.mcObj=Te,Xe.ids.length&&(Xe.tempEntity=Te.ObjectIdToObject(Xe.ids[0])),Xe}l.McDrawGripJig=Ue},{"../MxDrawData":22,"../MxFun":27,"../MxManager":29,"../MxTools":38,"../Operate/MxJig":53,"../Operate/MxJigCmdManager":54,three:19}],78:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.McDrawObject=void 0;var n=t("../MxManager"),u=t("three"),c=t("../MxFun"),y=t("./McDrawGrip"),b=t("./McTextureManager"),m=t("./McDraw3D"),O=window;O.McDrawObjectEvent_openFileComplete=function(G,q,J){var fe=n.MxManager.getMxObject(q);fe&&fe.getMcObject().openFileComplete(G,J)},O.McDrawObjectEvent_call=function(G,q,J){if(q=="mxpost")try{var fe=JSON.parse(J);if(fe&&fe.url&&fe.data){var ve=new XMLHttpRequest;ve.open("POST",fe.url,!0),ve.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),ve.onreadystatechange=function(){ve.readyState===4&&ve.status},ve.send(fe.data)}}catch{}else if(q=="regen_complete"){if(!(ne=n.MxManager.getMxObject(G)))return;ne.regenAllMxDbEntity()}else{var ne;if(!(ne=n.MxManager.getMxObject(G)))return;ne.callEvent(q,J)}},O.McDrawObjectEvent_synchronizeuUdateDisplayRange=function(G,q){var J=n.MxManager.getMxObject(G);J&&J.getMcObject().updateDisplayRange(q==1)},O.McDrawObjectEvent_osnapComplete=function(G,q){var J=n.MxManager.getMxObject(G);J&&J.getMcObject().callOsnapComplete(q)},O.McDrawObjectEvent_mcutPrintf=function(G){c.MxFun.acutPrintf(G)},O.McDrawObjectEvent_updateDisplay=function(G){var q=n.MxManager.getMxObject(G);q&&q.updateDisplay()},O.McDrawObjectEvent_loadImages=function(G,q,J,fe){var ve=n.MxManager.getMxObject(G);if(ve){ve.getMcObject().getTextureManager().clear();var ne=0,Ue=[];fe.substring(0,5)=="blob:"&&(fe=fe.substring(5)),q.forEach(function(De){var Ve=n.MxManager.getMxCpp().decodeFromGb2312(De),rt=Ve;Ve.lastIndexOf("/")==-1?(J&&0<J.length&&(rt=J+"/"+rt),fe&&0<fe.length&&(rt=fe+"/"+rt)):Ve=Ve.substring(Ve.lastIndexOf("/")+1).toLowerCase(),Ue.push(rt),ve.getMcObject().getTextureManager().loadImage(rt,Ve,function(){++ne==q.length&&(Ue.forEach(function(Ae){ve.getMcObject().getTextureManager().createOpenGLTexture(Ae)}),ve.updateDisplay(!1))})})}},O.McDrawObjectEvent_loadImagesBase64=function(G,q){var J=n.MxManager.getMxObject(G);if(J){var fe=q.indexOf("data:image/png;base64");if(fe!=-1){var ve=q.substring(0,fe);q=q.substring(fe),J.getMcObject().getTextureManager().loadImageBase64(ve,q,function(){J.getMcObject().getTextureManager().createOpenGLTexture(ve),J.updateDisplay(!1)})}}};var N=(L.prototype.getTextureManager=function(){return this.textureManager},L.prototype.isValid=function(){return this.mcObjectImp!==null},L.prototype.isPaperSpaceDisplay=function(){return!!this.mcObjectImp&&this.mcObjectImp.isPaperSpaceDisplay()},L.prototype.fireStartRunCommand=function(G,q){this.mcObjectImp&&this.mcObjectImp.fireStartRunCommand(G,q)},L.prototype.fireEndRunCommand=function(G,q){this.mcObjectImp&&this.mcObjectImp.fireEndRunCommand(G,q)},L.prototype.undo=function(){this.mcObjectImp&&this.mcObjectImp.undo()},L.prototype.redo=function(){this.mcObjectImp&&this.mcObjectImp.redo()},L.prototype.initCAD2Doc=function(G,q){this.matCad2doc=G,this.matDoc2cad=q},L.prototype.getSysVarLong=function(G){return this.mcObjectImp.GetSysVarLong(G)},L.prototype.getSysVarDouble=function(G){return this.mcObjectImp.GetSysVarDouble(G)},L.prototype.getSysVarPoint=function(G){var q=this.mcObjectImp.GetSysVarPoint(G);return new u.Vector3(q.x,q.y,q.z)},L.prototype.ObjectIdToMdObjectImp=function(G){return this.mcObjectImp?this.mxcpp.App.getImp().ObjectIdToMdObject(G):null},L.prototype.DestroyObject=function(G){if(!this.mcObjectImp)return null;this.mcObject.destroyObject(G)},L.prototype.onJigCommandEnd=function(){this.mcObjectImp&&this.mcObjectImp.EntityTempWordDraw_onJigCommandEnd()},L.prototype.callOsnapComplete=function(G){if(this.m_retCall&&G)try{var q=G;if(typeof G=="string"&&(q=JSON.parse(G)),q.callId!=this.m_lOsnapCallCount)return;this.m_retCall(q)}catch{}},L.prototype.doc2cad1=function(G){return G},L.prototype.doc2cad2=function(G,q){return new u.Vector3(G,q,0)},L.prototype.cad2doc1=function(G){return G},L.prototype.cad2doc2=function(G,q){return new u.Vector3(G,q,0)},L.prototype.onNotifyOsnap=function(G,q){if(this.mcObjectImp){this.m_lOsnapCallCount++,this.m_retCall=q,1e5<this.m_lOsnapCallCount&&(this.m_lOsnapCallCount=1);var J,fe=this.doc2cad2(G.ptx,G.pty);G.isValidPrvInputPoint&&(J=this.doc2cad2(G.prvPtx,G.prvPty)),this.mcObjectImp.Osnap_NotifyOsnap(fe.x,fe.y,G.isValidPrvInputPoint,G.isValidPrvInputPoint?J.x:0,G.isValidPrvInputPoint?J.y:0,G.osmode,G.SearchRnge,this.m_lOsnapCallCount)}},L.prototype.DrawEntity=function(G,q,J){G&&this.mcObjectImp&&(q&&G.SetTrueColor(this.THREEColor2MdCmColor(q)),this.mcObjectImp.DrawEntity(G,J))},L.prototype.onJigDrawEntityDisplay=function(G,q,J){G&&this.mcObjectImp&&(q&&G.SetTrueColor(this.THREEColor2MdCmColor(q)),this.mcObjectImp.EntityTempWordDraw_onJigDrawEntityDisplay(G,J===!0))},L.prototype.THREEColor2MdCmColor=function(G){var q=new u.Color(G),J=new this.mxcppImp.MdCmColor;return J.setRGB(255*q.r,255*q.g,255*q.b),J},L.prototype.onJigDrawEntityDisplay_line=function(G,q,J,fe,ve,ne,Ue){if(this.mcObjectImp){var De=new this.mxcppImp.MdDbLine,Ve=new this.mxcppImp.MdGePoint3d;Ve.x=G,Ve.y=q,Ve.z=J,De.setStartPoint(Ve);var rt=new this.mxcppImp.MdGePoint3d;rt.x=fe,rt.y=ve,rt.z=ne,De.setEndPoint(rt),De.SetTrueColor(this.THREEColor2MdCmColor(Ue)),this.mcObjectImp.EntityTempWordDraw_onJigDrawEntityDisplay(De,!1)}},L.prototype.DrawLine=function(G,q,J,fe,ve,ne,Ue){if(this.mcObjectImp){var De=new this.mxcppImp.MdDbLine,Ve=new this.mxcppImp.MdGePoint3d;Ve.x=G,Ve.y=q,Ve.z=J,De.setStartPoint(Ve);var rt=new this.mxcppImp.MdGePoint3d;rt.x=fe,rt.y=ve,rt.z=ne,De.setEndPoint(rt),De.SetTrueColor(this.THREEColor2MdCmColor(Ue)),this.mcObjectImp.DrawEntity(De,!1)}},L.prototype.HighlightEntity=function(G,q){if(!this.mcDrawUtility)return!1;this.mcDrawUtility.highlightEntity(G,q)},L.prototype.onReadyJigUpdateDispla=function(G,q){G===void 0&&(G=0),q===void 0&&(q=void 0),this.mcObjectImp&&this.mcObjectImp.EntityTempWordDraw_onReadyJigUpdateDispla(G,q?q.x:0,q?q.y:0)},L.prototype.onJigClearDisplay=function(){this.mcObjectImp&&this.mcObjectImp.EntityTempWordDraw_onJigClearDisplay()},L.prototype.ObjectIdToObject=function(G){return this.mcObject?this.mxcpp.App.objectIdToObject(G):null},L.prototype.initMxObject=function(G){this.mxObject=G},L.prototype.init=function(G,q){q.initMxObject(G),this.mxObject=G,this.mcObject=q,this.mcObjectImp=q.getImp(),this.mxcpp=q.getMxCpp(),this.mxcppImp=this.mxcpp.mxcadassemblyimp,this.mxapp=this.mxcpp.App,this.mxappimp=this.mxapp.getImp(),this.grip=new y.McDrawGrip(G,this),this.mcDrawUtility=new this.mxcppImp.McDrawUtility,this.textureManager=new b.McTextureManager(this,G.getRenderer().getContext());var J=this;this.mxObject.addEvent("dragWillEnd",function(){J.mcObjectImp.fireEventDragWillEnd()})},L.prototype.setSize=function(G,q){if(!this.mcObjectImp)return!1;this.mcObjectImp.fireEventWindowSize(G,q)},L.prototype.getGripManager=function(){return this.grip},L.prototype.updateDisplayRange=function(G){if(G===void 0&&(G=!1),this.mcObjectImp){var q=this.mcObjectImp.getViewDataJsonParam(G);q=q.replace(/\\/g,"\\\\");try{var J=JSON.parse(q),fe=this.mxObject;if(J!=null){J.is3d?this.mxdraw3d.is3DMode()||(this.mxdraw3d=new m.McDraw3d,this.mxdraw3d.mcObject=this):this.mxdraw3d.is3DMode()&&(this.mxdraw3d=new m.McDraw2d,this.mxdraw3d.mcObject=this),this.mxdraw3d.initDisplayRange(J),fe.initAllLayoutName(JSON.parse(J.layout)),fe.updateDisplay(!0);var ve=c.MxFun.getUiObj();ve!=null&&(ve.SetLayoutData(J.layout),ve.UpDisplayLayout())}}catch{console.log("getViewDataJsonParam exception")}}},L.prototype.openFileComplete=function(G,q){this.updateDisplayRange(),this.mxObject.callOpenFileComplete(G,q)},L.prototype.updateDisplayMapBox=function(G){return!!this.mcObjectImp&&(this.mxObject.getScene().background!==null&&console.log("mxerror: background must be empty"),this.mcObjectImp_updateDisplay(new u.Matrix4().elements,G.elements))},L.prototype.mcObjectImp_updateDisplay=function(G,q){if(this.m_isCallingUpDisplay)return!0;var J=!(this.m_isCallingUpDisplay=!0);try{J=this.mcObjectImp.updateDisplay(G,q),this.m_isCallingUpDisplay=!1}catch(fe){this.m_isCallingUpDisplay=!1,console.log(fe)}return J},L.prototype.updateDisplay=function(){if(!this.mcObjectImp)return!1;var G=this.mxObject.getCamera();this.mxObject.getScene().background!==null&&console.log("mxerror: background must be empty");var q=new u.Matrix4;q.multiplyMatrices(G.matrixWorldInverse,this.mxObject.getDoc2World());var J=G.projectionMatrix;return this.mcObjectImp_updateDisplay(q.elements,J.elements)},L.prototype.updateDisplayMatrixData=function(G){if(this.mcObjectImp){var q=this.mxObject.getCamera(),J=new u.Matrix4;J.multiplyMatrices(q.matrixWorldInverse,this.mxObject.getDoc2World());var fe=q.projectionMatrix;return this.mcObjectImp.updateDisplayMatrixData(J.elements,fe.elements,!!G)}},L.prototype.setViewAngle=function(G){this.mcObjectImp&&this.mcObjectImp.fireViewAngleChange(G)},L.prototype.createTexture=function(){return this.mcObjectImp.createTexture()},L.prototype.deleteTexture=function(G){return this.mcObjectImp.deleteTexture(G)},L.prototype.bindTexture=function(G,q){return this.mcObjectImp.bindTexture(G,q)},L.prototype.allocTextureHandle=function(G){return this.mcObjectImp.allocTextureHandle(G)},L.prototype.registTexture=function(G,q){return this.mcObjectImp.registTexture(G,q)},L.prototype.makeCurrent=function(){this.mcObjectImp&&this.mcObjectImp.makeCurrent()},L);function L(){this.grip=null,this.mcObjectImp=null,this.mxcppImp=null,this.mxcpp=null,this.mcObject=null,this.mxapp=null,this.mxappimp=null,this.mcDrawUtility=null,this.m_lOsnapCallCount=1,this.m_retCall=null,this.matCad2doc=new u.Matrix4,this.matDoc2cad=new u.Matrix4,this.m_isCallingUpDisplay=!1,this.mxdraw3d=new m.McDraw2d,this.mxdraw3d.mcObject=this}l.McDrawObject=N},{"../MxFun":27,"../MxManager":29,"./McDraw3D":76,"./McDrawGrip":77,"./McTextureManager":79,three:19}],79:[function(t,e,l){Object.defineProperty(l,"__esModule",{value:!0}),l.McTextureManager=void 0;var n=t("three"),u=t("../MxManager"),c=(y.prototype.get=function(O){if(this.extensions[O]!==void 0)return this.extensions[O];var N;switch(O){case"WEBGL_depth_texture":N=this.gl.getExtension("WEBGL_depth_texture")||this.gl.getExtension("MOZ_WEBGL_depth_texture")||this.gl.getExtension("WEBKIT_WEBGL_depth_texture");break;case"EXT_texture_filter_anisotropic":N=this.gl.getExtension("EXT_texture_filter_anisotropic")||this.gl.getExtension("MOZ_EXT_texture_filter_anisotropic")||this.gl.getExtension("WEBKIT_EXT_texture_filter_anisotropic");break;case"WEBGL_compressed_texture_s3tc":N=this.gl.getExtension("WEBGL_compressed_texture_s3tc")||this.gl.getExtension("MOZ_WEBGL_compressed_texture_s3tc")||this.gl.getExtension("WEBKIT_WEBGL_compressed_texture_s3tc");break;case"WEBGL_compressed_texture_pvrtc":N=this.gl.getExtension("WEBGL_compressed_texture_pvrtc")||this.gl.getExtension("WEBKIT_WEBGL_compressed_texture_pvrtc");break;default:N=this.gl.getExtension(O)}return N===null&&console.warn("THREE.WebGLRenderer: "+O+" extension not supported."),this.extensions[O]=N},y);function y(O){this.extensions={},this.gl=O}var b=(m.prototype.allocHandle=function(O){return this.mcObject.allocTextureHandle(u.MxManager.getMxCpp().encodeToGb2312(O))},m.prototype.convert=function(O){var N;if(O===n.UnsignedByteType)return 5121;if(O===n.UnsignedShort4444Type)return 32819;if(O===n.UnsignedShort5551Type)return 32820;if(O===n.UnsignedShort565Type)return 33635;if(O===n.ByteType)return 5120;if(O===n.ShortType)return 5122;if(O===n.UnsignedShortType)return 5123;if(O===n.IntType)return 5124;if(O===n.UnsignedIntType)return 5125;if(O===n.FloatType)return 5126;if(O===n.HalfFloatType)return this.isWebGL2?5131:(N=this.extensions.get("OES_texture_half_float"))!==null?N.HALF_FLOAT_OES:null;if(O===n.AlphaFormat)return 6406;if(O===n.RGBFormat)return 6407;if(O===n.RGBAFormat)return 6408;if(O===n.LuminanceFormat)return 6409;if(O===n.LuminanceAlphaFormat)return 6410;if(O===n.DepthFormat)return 6402;if(O===n.DepthStencilFormat)return 34041;if(O===n.RedFormat)return 6403;if(O===n.RedIntegerFormat)return 36244;if(O===n.RGFormat)return 33319;if(O===n.RGIntegerFormat)return 33320;if(O===n.RGBIntegerFormat)return 36248;if(O===n.RGBAIntegerFormat)return 36249;if(O===n.RGB_S3TC_DXT1_Format||O===n.RGBA_S3TC_DXT1_Format||O===n.RGBA_S3TC_DXT3_Format||O===n.RGBA_S3TC_DXT5_Format){if((N=this.extensions.get("WEBGL_compressed_texture_s3tc"))===null)return null;if(O===n.RGB_S3TC_DXT1_Format)return N.COMPRESSED_RGB_S3TC_DXT1_EXT;if(O===n.RGBA_S3TC_DXT1_Format)return N.COMPRESSED_RGBA_S3TC_DXT1_EXT;if(O===n.RGBA_S3TC_DXT3_Format)return N.COMPRESSED_RGBA_S3TC_DXT3_EXT;if(O===n.RGBA_S3TC_DXT5_Format)return N.COMPRESSED_RGBA_S3TC_DXT5_EXT}if(O===n.RGB_PVRTC_4BPPV1_Format||O===n.RGB_PVRTC_2BPPV1_Format||O===n.RGBA_PVRTC_4BPPV1_Format||O===n.RGBA_PVRTC_2BPPV1_Format){if((N=this.extensions.get("WEBGL_compressed_texture_pvrtc"))===null)return null;if(O===n.RGB_PVRTC_4BPPV1_Format)return N.COMPRESSED_RGB_PVRTC_4BPPV1_IMG;if(O===n.RGB_PVRTC_2BPPV1_Format)return N.COMPRESSED_RGB_PVRTC_2BPPV1_IMG;if(O===n.RGBA_PVRTC_4BPPV1_Format)return N.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG;if(O===n.RGBA_PVRTC_2BPPV1_Format)return N.COMPRESSED_RGBA_PVRTC_2BPPV1_IMG}return O===n.RGB_ETC1_Format?(N=this.extensions.get("WEBGL_compressed_texture_etc1"))!==null?N.COMPRESSED_RGB_ETC1_WEBGL:null:O===n.RGBA_ASTC_4x4_Format||O===n.RGBA_ASTC_5x4_Format||O===n.RGBA_ASTC_5x5_Format||O===n.RGBA_ASTC_6x5_Format||O===n.RGBA_ASTC_6x6_Format||O===n.RGBA_ASTC_8x5_Format||O===n.RGBA_ASTC_8x6_Format||O===n.RGBA_ASTC_8x8_Format||O===n.RGBA_ASTC_10x5_Format||O===n.RGBA_ASTC_10x6_Format||O===n.RGBA_ASTC_10x8_Format||O===n.RGBA_ASTC_10x10_Format||O===n.RGBA_ASTC_12x10_Format||O===n.RGBA_ASTC_12x12_Format?(N=this.extensions.get("WEBGL_compressed_texture_astc"))!==null?O:null:O===n.UnsignedInt248Type?this.isWebGL2?34042:(N=this.extensions.get("WEBGL_depth_texture"))!==null?N.UNSIGNED_INT_24_8_WEBGL:null:void 0},m.prototype.textureNeedsPowerOfTwo=function(O){return O.wrapS!==1001||O.wrapT!==1001||O.minFilter!==1003&&O.minFilter!==1006},m.prototype.createCanvas=function(O,N){return document.createElementNS("http://www.w3.org/1999/xhtml","canvas")},m.prototype.floorPowerOfTwo=function(O){return Math.pow(2,Math.floor(Math.log(O)/Math.LN2))},m.prototype.resizeImage=function(O,N,L,G){var q=1;if((O.width>G||O.height>G)&&(q=G/Math.max(O.width,O.height)),q<1||N===!0){if(typeof HTMLImageElement<"u"&&O instanceof HTMLImageElement||typeof HTMLCanvasElement<"u"&&O instanceof HTMLCanvasElement||typeof ImageBitmap<"u"&&O instanceof ImageBitmap){var J=N?this.floorPowerOfTwo:Math.floor,fe=J(q*O.width),ve=J(q*O.height);this._canvas===void 0&&(this._canvas=this.createCanvas(fe,ve));var ne=L?this.createCanvas(fe,ve):this._canvas;return ne.width=fe,ne.height=ve,ne.getContext("2d").drawImage(O,0,0,fe,ve),console.warn("THREE.WebGLRenderer: Texture has been resized from ("+O.width+"x"+O.height+") to ("+fe+"x"+ve+")."),ne}return"data"in O&&console.warn("THREE.WebGLRenderer: Image in DataTexture is too big ("+O.width+"x"+O.height+")."),O}return O},m.prototype.mathIsPowerOfTwo=function(O){return(O&O-1)==0&&O!==0},m.prototype.isPowerOfTwo=function(O){return this.mathIsPowerOfTwo(O.width)&&this.mathIsPowerOfTwo(O.height)},m.prototype.getInternalFormat=function(O,N,L){if(this.isWebGL2===!1)return N;if(O!==null){if(this._gl[O]!==void 0)return this._gl[O];console.warn("THREE.WebGLRenderer: Attempt to use non-existing WebGL internal format '"+O+"'")}var G=N;return N===6403&&(L===5126&&(G=33326),L===5131&&(G=33325),L===5121&&(G=33321)),N===6407&&(L===5126&&(G=34837),L===5131&&(G=34843),L===5121&&(G=32849)),N===6408&&(L===5126&&(G=34836),L===5131&&(G=34842),L===5121&&(G=32856)),G===33325||G===33326||G===34842||G===34836?this.extensions.get("EXT_color_buffer_float"):G!==34843&&G!==34837||console.warn("THREE.WebGLRenderer: Floating point textures with RGB format not supported. Please use RGBA instead."),G},m.prototype.filterFallback=function(O){return O===n.NearestFilter||O===n.NearestMipmapNearestFilter||O===n.NearestMipmapLinearFilter?9728:9729},m.prototype.setTextureParameters=function(O,N,L){var G={};G[n.RepeatWrapping]=10497,G[n.ClampToEdgeWrapping]=33071,G[n.MirroredRepeatWrapping]=33648;var q={};q[n.NearestFilter]=9728,q[n.NearestMipmapNearestFilter]=9984,q[n.NearestMipmapLinearFilter]=9986,q[n.LinearFilter]=9729,q[n.LinearMipmapNearestFilter]=9985,q[n.LinearMipmapLinearFilter]=9987,L?(this._gl.texParameteri(O,10242,G[N.wrapS]),this._gl.texParameteri(O,10243,G[N.wrapT]),O!==32879&&O!==35866||this._gl.texParameteri(O,32882,G[N.wrapR]),this._gl.texParameteri(O,10240,q[N.magFilter]),this._gl.texParameteri(O,10241,q[N.minFilter])):(this._gl.texParameteri(O,10242,33071),this._gl.texParameteri(O,10243,33071),O!==32879&&O!==35866||this._gl.texParameteri(O,32882,33071),N.wrapS===n.ClampToEdgeWrapping&&N.wrapT===n.ClampToEdgeWrapping||console.warn("THREE.WebGLRenderer: Texture is not power of two. Texture.wrapS and Texture.wrapT should be set to THREE.ClampToEdgeWrapping."),this._gl.texParameteri(O,10240,this.filterFallback(N.magFilter)),this._gl.texParameteri(O,10241,this.filterFallback(N.minFilter)),N.minFilter!==n.NearestFilter&&N.minFilter!==n.LinearFilter&&console.warn("THREE.WebGLRenderer: Texture is not power of two. Texture.minFilter should be set to THREE.NearestFilter or THREE.LinearFilter."))},m.prototype.textureNeedsGenerateMipmaps=function(O,N){return O.generateMipmaps&&N&&O.minFilter!==n.NearestFilter&&O.minFilter!==n.LinearFilter},m.prototype.generateMipmap=function(O,N,L,G,q){this._gl.generateMipmap(N)},m.prototype.clear=function(){var O=this;Object.keys(this.mapImagePathToTexture).forEach(function(N){var L=O.mapImagePathToTexture[N];L&&L.webglTexture&&O.mcObject.deleteTexture(L.webglTexture)}),this.mapImagePathToTexture={}},m.prototype.loadImage=function(O,N,L){if(this.mapImagePathToTexture[O]){var G=this.mapImagePathToTexture[O];return G&&G.isload&&G.texture?L(!0,G.texture.image):L(!1,void 0),0}var q={isload:!1,texture:null,handle:this.allocHandle(N),webglTexture:void 0};return this.mapImagePathToTexture[O]=q,new n.TextureLoader().load(O,function(J){q.isload=!0,q.texture=J,L(!0,J.image)},void 0,function(J){q.isload=!1,L(!1,void 0)}),q.handle},m.prototype.loadImageBase64=function(O,N,L){if(this.mapImagePathToTexture[O]){var G=this.mapImagePathToTexture[O];return G&&G.isload&&G.texture?L(!0,G.texture.image):L(!1,void 0),0}var q={isload:!1,texture:null,handle:this.allocHandle(O),webglTexture:void 0};return this.mapImagePathToTexture[O]=q,new n.TextureLoader().load(N,function(J){q.isload=!0,q.texture=J,L(!0,J.image)},void 0,function(J){q.isload=!1,L(!1,void 0)}),q.handle},m.prototype.createOpenGLTexture=function(O){var N=this.mapImagePathToTexture[O];if(!N||!N.isload||N.webglTexture)return!1;var L=N.texture;N.webglTexture=this.mcObject.createTexture(),this._gl.activeTexture(33984),this.mcObject.bindTexture(3553,N.webglTexture),this._gl.pixelStorei(37440,L.flipY),this._gl.pixelStorei(37441,L.premultiplyAlpha),this._gl.pixelStorei(3317,L.unpackAlignment);var G=this._gl.getParameter(3379),q=this.textureNeedsPowerOfTwo(L)&&this.isPowerOfTwo(L.image)===!1,J=this.resizeImage(L.image,q,!1,G),fe=this.isPowerOfTwo(J)||this.isWebGL2,ve=this.convert(L.format),ne=this.convert(L.type),Ue=this.getInternalFormat(L.internalFormat,ve,ne);this.setTextureParameters(3553,L,fe);var De,Ve=L.mipmaps;if(0<Ve.length&&fe){for(var rt=0,Ae=Ve.length;rt<Ae;rt++)De=Ve[rt],this._gl.texImage2D(3553,rt,Ue,ve,ne,De);L.generateMipmaps=!1}else this._gl.texImage2D(3553,0,Ue,ve,ne,J);this.textureNeedsGenerateMipmaps(L,fe)&&this.generateMipmap(N,3553,L,J.width,J.height),this.mcObject.registTexture(N.handle,N.webglTexture)},m);function m(O,N){this.mapImagePathToTexture={},this.mcObject=O,this._gl=N,this.extensions=new c(N),this.isWebGL2=typeof WebGL2RenderingContext<"u"&&N instanceof WebGL2RenderingContext}l.McTextureManager=b},{"../MxManager":29,three:19}]},{},[58])}function registerMxDbEntity(){store.events.emit("MxDbEntityRegister")}let registerList=[];function addRegisterMxDbEntity(t){t.isRegister=!1;const e=()=>{!t.isRegister&&t.register&&t.register(),store.events.off("stateChange",e)};registerList.push(e)}const callRegisterMxDbEntityLists=()=>{registerList.forEach(t=>{t&&t()}),registerList=[]};store.events.on("MxDbEntityRegister",callRegisterMxDbEntityLists);var commonjsGlobal=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function unwrapExports(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function createCommonjsModule(t,e){return t(e={exports:{}},e.exports),e.exports}var jquery$1=createCommonjsModule(function(t){var e,l;e=typeof window<"u"?window:commonjsGlobal,l=function(n,u){var c=[],y=Object.getPrototypeOf,b=c.slice,m=c.flat?function(wt){return c.flat.call(wt)}:function(wt){return c.concat.apply([],wt)},O=c.push,N=c.indexOf,L={},G=L.toString,q=L.hasOwnProperty,J=q.toString,fe=J.call(Object),ve={},ne=function(wt){return typeof wt=="function"&&typeof wt.nodeType!="number"&&typeof wt.item!="function"},Ue=function(wt){return wt!=null&&wt===wt.window},De=n.document,Ve={type:!0,src:!0,nonce:!0,noModule:!0};function rt(wt,qt,Cn){var Pn,Qe,yt=(Cn=Cn||De).createElement("script");if(yt.text=wt,qt)for(Pn in Ve)(Qe=qt[Pn]||qt.getAttribute&&qt.getAttribute(Pn))&&yt.setAttribute(Pn,Qe);Cn.head.appendChild(yt).parentNode.removeChild(yt)}function Ae(wt){return wt==null?wt+"":typeof wt=="object"||typeof wt=="function"?L[G.call(wt)]||"object":typeof wt}var Te="3.7.0",Xe=/HTML$/i,ie=function(wt,qt){return new ie.fn.init(wt,qt)};function ue(wt){var qt=!!wt&&"length"in wt&&wt.length,Cn=Ae(wt);return!ne(wt)&&!Ue(wt)&&(Cn==="array"||qt===0||typeof qt=="number"&&qt>0&&qt-1 in wt)}function pt(wt,qt){return wt.nodeName&&wt.nodeName.toLowerCase()===qt.toLowerCase()}ie.fn=ie.prototype={jquery:Te,constructor:ie,length:0,toArray:function(){return b.call(this)},get:function(wt){return wt==null?b.call(this):wt<0?this[wt+this.length]:this[wt]},pushStack:function(wt){var qt=ie.merge(this.constructor(),wt);return qt.prevObject=this,qt},each:function(wt){return ie.each(this,wt)},map:function(wt){return this.pushStack(ie.map(this,function(qt,Cn){return wt.call(qt,Cn,qt)}))},slice:function(){return this.pushStack(b.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(ie.grep(this,function(wt,qt){return(qt+1)%2}))},odd:function(){return this.pushStack(ie.grep(this,function(wt,qt){return qt%2}))},eq:function(wt){var qt=this.length,Cn=+wt+(wt<0?qt:0);return this.pushStack(Cn>=0&&Cn<qt?[this[Cn]]:[])},end:function(){return this.prevObject||this.constructor()},push:O,sort:c.sort,splice:c.splice},ie.extend=ie.fn.extend=function(){var wt,qt,Cn,Pn,Qe,yt,Rt=arguments[0]||{},jt=1,dn=arguments.length,yn=!1;for(typeof Rt=="boolean"&&(yn=Rt,Rt=arguments[jt]||{},jt++),typeof Rt=="object"||ne(Rt)||(Rt={}),jt===dn&&(Rt=this,jt--);jt<dn;jt++)if((wt=arguments[jt])!=null)for(qt in wt)Pn=wt[qt],qt!=="__proto__"&&Rt!==Pn&&(yn&&Pn&&(ie.isPlainObject(Pn)||(Qe=Array.isArray(Pn)))?(Cn=Rt[qt],yt=Qe&&!Array.isArray(Cn)?[]:Qe||ie.isPlainObject(Cn)?Cn:{},Qe=!1,Rt[qt]=ie.extend(yn,yt,Pn)):Pn!==void 0&&(Rt[qt]=Pn));return Rt},ie.extend({expando:"jQuery"+(Te+Math.random()).replace(/\D/g,""),isReady:!0,error:function(wt){throw new Error(wt)},noop:function(){},isPlainObject:function(wt){var qt,Cn;return!(!wt||G.call(wt)!=="[object Object]"||(qt=y(wt))&&(typeof(Cn=q.call(qt,"constructor")&&qt.constructor)!="function"||J.call(Cn)!==fe))},isEmptyObject:function(wt){var qt;for(qt in wt)return!1;return!0},globalEval:function(wt,qt,Cn){rt(wt,{nonce:qt&&qt.nonce},Cn)},each:function(wt,qt){var Cn,Pn=0;if(ue(wt))for(Cn=wt.length;Pn<Cn&&qt.call(wt[Pn],Pn,wt[Pn])!==!1;Pn++);else for(Pn in wt)if(qt.call(wt[Pn],Pn,wt[Pn])===!1)break;return wt},text:function(wt){var qt,Cn="",Pn=0,Qe=wt.nodeType;if(Qe){if(Qe===1||Qe===9||Qe===11)return wt.textContent;if(Qe===3||Qe===4)return wt.nodeValue}else for(;qt=wt[Pn++];)Cn+=ie.text(qt);return Cn},makeArray:function(wt,qt){var Cn=qt||[];return wt!=null&&(ue(Object(wt))?ie.merge(Cn,typeof wt=="string"?[wt]:wt):O.call(Cn,wt)),Cn},inArray:function(wt,qt,Cn){return qt==null?-1:N.call(qt,wt,Cn)},isXMLDoc:function(wt){var qt=wt&&wt.namespaceURI,Cn=wt&&(wt.ownerDocument||wt).documentElement;return!Xe.test(qt||Cn&&Cn.nodeName||"HTML")},merge:function(wt,qt){for(var Cn=+qt.length,Pn=0,Qe=wt.length;Pn<Cn;Pn++)wt[Qe++]=qt[Pn];return wt.length=Qe,wt},grep:function(wt,qt,Cn){for(var Pn=[],Qe=0,yt=wt.length,Rt=!Cn;Qe<yt;Qe++)!qt(wt[Qe],Qe)!==Rt&&Pn.push(wt[Qe]);return Pn},map:function(wt,qt,Cn){var Pn,Qe,yt=0,Rt=[];if(ue(wt))for(Pn=wt.length;yt<Pn;yt++)(Qe=qt(wt[yt],yt,Cn))!=null&&Rt.push(Qe);else for(yt in wt)(Qe=qt(wt[yt],yt,Cn))!=null&&Rt.push(Qe);return m(Rt)},guid:1,support:ve}),typeof Symbol=="function"&&(ie.fn[Symbol.iterator]=c[Symbol.iterator]),ie.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(wt,qt){L["[object "+qt+"]"]=qt.toLowerCase()});var mt=c.pop,Tt=c.sort,kt=c.splice,It="[\\x20\\t\\r\\n\\f]",nn=new RegExp("^"+It+"+|((?:^|[^\\\\])(?:\\\\.)*)"+It+"+$","g");ie.contains=function(wt,qt){var Cn=qt&&qt.parentNode;return wt===Cn||!(!Cn||Cn.nodeType!==1||!(wt.contains?wt.contains(Cn):wt.compareDocumentPosition&&16&wt.compareDocumentPosition(Cn)))};var tn=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\x80-\uFFFF\w-]/g;function pn(wt,qt){return qt?wt==="\0"?"�":wt.slice(0,-1)+"\\"+wt.charCodeAt(wt.length-1).toString(16)+" ":"\\"+wt}ie.escapeSelector=function(wt){return(wt+"").replace(tn,pn)};var _n=De,Dn=O;(function(){var wt,qt,Cn,Pn,Qe,yt,Rt,jt,dn,yn,In=Dn,vr=ie.expando,Jn=0,li=0,xa=su(),Ri=su(),fa=su(),oo=su(),ts=function(Mi,wa){return Mi===wa&&(Qe=!0),0},bl="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",nl="(?:\\\\[\\da-fA-F]{1,6}"+It+"?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+",Fs="\\["+It+"*("+nl+")(?:"+It+"*([*^$|!~]?=)"+It+`*(?:'((?:\\\\.|[^\\\\'])*)'|"((?:\\\\.|[^\\\\"])*)"|(`+nl+"))|)"+It+"*\\]",eu=":("+nl+`)(?:\\((('((?:\\\\.|[^\\\\'])*)'|"((?:\\\\.|[^\\\\"])*)")|((?:\\\\.|[^\\\\()[\\]]|`+Fs+")*)|.*)\\)|)",Gs=new RegExp(It+"+","g"),As=new RegExp("^"+It+"*,"+It+"*"),yl=new RegExp("^"+It+"*([>+~]|"+It+")"+It+"*"),Lc=new RegExp(It+"|>"),vl=new RegExp(eu),du=new RegExp("^"+nl+"$"),ac={ID:new RegExp("^#("+nl+")"),CLASS:new RegExp("^\\.("+nl+")"),TAG:new RegExp("^("+nl+"|[*])"),ATTR:new RegExp("^"+Fs),PSEUDO:new RegExp("^"+eu),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+It+"*(even|odd|(([+-]|)(\\d*)n|)"+It+"*(?:([+-]|)"+It+"*(\\d+)|))"+It+"*\\)|)","i"),bool:new RegExp("^(?:"+bl+")$","i"),needsContext:new RegExp("^"+It+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+It+"*((?:-\\d)?\\d*)"+It+"*\\)|)(?=[^-]|$)","i")},Xu=/^(?:input|select|textarea|button)$/i,Ju=/^h\d$/i,Vu=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,Nl=/[+~]/,$l=new RegExp("\\\\[\\da-fA-F]{1,6}"+It+"?|\\\\([^\\r\\n\\f])","g"),hu=function(Mi,wa){var la="0x"+Mi.slice(1)-65536;return wa||(la<0?String.fromCharCode(la+65536):String.fromCharCode(la>>10|55296,1023&la|56320))},Qu=function(){gc()},Gu=qc(function(Mi){return Mi.disabled===!0&&pt(Mi,"fieldset")},{dir:"parentNode",next:"legend"});try{In.apply(c=b.call(_n.childNodes),_n.childNodes),c[_n.childNodes.length].nodeType}catch{In={apply:function(wa,la){Dn.apply(wa,b.call(la))},call:function(wa){Dn.apply(wa,b.call(arguments,1))}}}function Bs(Mi,wa,la,Wa){var lo,Jo,Xo,ei,ii,Ma,pa,ca=wa&&wa.ownerDocument,uo=wa?wa.nodeType:9;if(la=la||[],typeof Mi!="string"||!Mi||uo!==1&&uo!==9&&uo!==11)return la;if(!Wa&&(gc(wa),wa=wa||yt,jt)){if(uo!==11&&(ii=Vu.exec(Mi)))if(lo=ii[1]){if(uo===9){if(!(Xo=wa.getElementById(lo)))return la;if(Xo.id===lo)return In.call(la,Xo),la}else if(ca&&(Xo=ca.getElementById(lo))&&Bs.contains(wa,Xo)&&Xo.id===lo)return In.call(la,Xo),la}else{if(ii[2])return In.apply(la,wa.getElementsByTagName(Mi)),la;if((lo=ii[3])&&wa.getElementsByClassName)return In.apply(la,wa.getElementsByClassName(lo)),la}if(!(oo[Mi+" "]||dn&&dn.test(Mi))){if(pa=Mi,ca=wa,uo===1&&(Lc.test(Mi)||yl.test(Mi))){for((ca=Nl.test(Mi)&&oc(wa.parentNode)||wa)==wa&&ve.scope||((ei=wa.getAttribute("id"))?ei=ie.escapeSelector(ei):wa.setAttribute("id",ei=vr)),Jo=(Ma=Jc(Mi)).length;Jo--;)Ma[Jo]=(ei?"#"+ei:":scope")+" "+sc(Ma[Jo]);pa=Ma.join(",")}try{return In.apply(la,ca.querySelectorAll(pa)),la}catch{oo(Mi,!0)}finally{ei===vr&&wa.removeAttribute("id")}}}return ah(Mi.replace(nn,"$1"),wa,la,Wa)}function su(){var Mi=[];return function wa(la,Wa){return Mi.push(la+" ")>qt.cacheLength&&delete wa[Mi.shift()],wa[la+" "]=Wa}}function ku(Mi){return Mi[vr]=!0,Mi}function Hl(Mi){var wa=yt.createElement("fieldset");try{return!!Mi(wa)}catch{return!1}finally{wa.parentNode&&wa.parentNode.removeChild(wa),wa=null}}function Uc(Mi){return function(wa){return pt(wa,"input")&&wa.type===Mi}}function Wl(Mi){return function(wa){return(pt(wa,"input")||pt(wa,"button"))&&wa.type===Mi}}function cd(Mi){return function(wa){return"form"in wa?wa.parentNode&&wa.disabled===!1?"label"in wa?"label"in wa.parentNode?wa.parentNode.disabled===Mi:wa.disabled===Mi:wa.isDisabled===Mi||wa.isDisabled!==!Mi&&Gu(wa)===Mi:wa.disabled===Mi:"label"in wa&&wa.disabled===Mi}}function wu(Mi){return ku(function(wa){return wa=+wa,ku(function(la,Wa){for(var lo,Jo=Mi([],la.length,wa),Xo=Jo.length;Xo--;)la[lo=Jo[Xo]]&&(la[lo]=!(Wa[lo]=la[lo]))})})}function oc(Mi){return Mi&&Mi.getElementsByTagName!==void 0&&Mi}function gc(Mi){var wa,la=Mi?Mi.ownerDocument||Mi:_n;return la!=yt&&la.nodeType===9&&la.documentElement&&(Rt=(yt=la).documentElement,jt=!ie.isXMLDoc(yt),yn=Rt.matches||Rt.webkitMatchesSelector||Rt.msMatchesSelector,_n!=yt&&(wa=yt.defaultView)&&wa.top!==wa&&wa.addEventListener("unload",Qu),ve.getById=Hl(function(Wa){return Rt.appendChild(Wa).id=ie.expando,!yt.getElementsByName||!yt.getElementsByName(ie.expando).length}),ve.disconnectedMatch=Hl(function(Wa){return yn.call(Wa,"*")}),ve.scope=Hl(function(){return yt.querySelectorAll(":scope")}),ve.cssHas=Hl(function(){try{return yt.querySelector(":has(*,:jqfake)"),!1}catch{return!0}}),ve.getById?(qt.filter.ID=function(Wa){var lo=Wa.replace($l,hu);return function(Jo){return Jo.getAttribute("id")===lo}},qt.find.ID=function(Wa,lo){if(lo.getElementById!==void 0&&jt){var Jo=lo.getElementById(Wa);return Jo?[Jo]:[]}}):(qt.filter.ID=function(Wa){var lo=Wa.replace($l,hu);return function(Jo){var Xo=Jo.getAttributeNode!==void 0&&Jo.getAttributeNode("id");return Xo&&Xo.value===lo}},qt.find.ID=function(Wa,lo){if(lo.getElementById!==void 0&&jt){var Jo,Xo,ei,ii=lo.getElementById(Wa);if(ii){if((Jo=ii.getAttributeNode("id"))&&Jo.value===Wa)return[ii];for(ei=lo.getElementsByName(Wa),Xo=0;ii=ei[Xo++];)if((Jo=ii.getAttributeNode("id"))&&Jo.value===Wa)return[ii]}return[]}}),qt.find.TAG=function(Wa,lo){return lo.getElementsByTagName!==void 0?lo.getElementsByTagName(Wa):lo.querySelectorAll(Wa)},qt.find.CLASS=function(Wa,lo){if(lo.getElementsByClassName!==void 0&&jt)return lo.getElementsByClassName(Wa)},dn=[],Hl(function(Wa){var lo;Rt.appendChild(Wa).innerHTML="<a id='"+vr+"' href='' disabled='disabled'></a><select id='"+vr+"-\r\\' disabled='disabled'><option selected=''></option></select>",Wa.querySelectorAll("[selected]").length||dn.push("\\["+It+"*(?:value|"+bl+")"),Wa.querySelectorAll("[id~="+vr+"-]").length||dn.push("~="),Wa.querySelectorAll("a#"+vr+"+*").length||dn.push(".#.+[+~]"),Wa.querySelectorAll(":checked").length||dn.push(":checked"),(lo=yt.createElement("input")).setAttribute("type","hidden"),Wa.appendChild(lo).setAttribute("name","D"),Rt.appendChild(Wa).disabled=!0,Wa.querySelectorAll(":disabled").length!==2&&dn.push(":enabled",":disabled"),(lo=yt.createElement("input")).setAttribute("name",""),Wa.appendChild(lo),Wa.querySelectorAll("[name='']").length||dn.push("\\["+It+"*name"+It+"*="+It+`*(?:''|"")`)}),ve.cssHas||dn.push(":has"),dn=dn.length&&new RegExp(dn.join("|")),ts=function(Wa,lo){if(Wa===lo)return Qe=!0,0;var Jo=!Wa.compareDocumentPosition-!lo.compareDocumentPosition;return Jo||(1&(Jo=(Wa.ownerDocument||Wa)==(lo.ownerDocument||lo)?Wa.compareDocumentPosition(lo):1)||!ve.sortDetached&&lo.compareDocumentPosition(Wa)===Jo?Wa===yt||Wa.ownerDocument==_n&&Bs.contains(_n,Wa)?-1:lo===yt||lo.ownerDocument==_n&&Bs.contains(_n,lo)?1:Pn?N.call(Pn,Wa)-N.call(Pn,lo):0:4&Jo?-1:1)}),yt}for(wt in Bs.matches=function(Mi,wa){return Bs(Mi,null,null,wa)},Bs.matchesSelector=function(Mi,wa){if(gc(Mi),jt&&!oo[wa+" "]&&(!dn||!dn.test(wa)))try{var la=yn.call(Mi,wa);if(la||ve.disconnectedMatch||Mi.document&&Mi.document.nodeType!==11)return la}catch{oo(wa,!0)}return Bs(wa,yt,null,[Mi]).length>0},Bs.contains=function(Mi,wa){return(Mi.ownerDocument||Mi)!=yt&&gc(Mi),ie.contains(Mi,wa)},Bs.attr=function(Mi,wa){(Mi.ownerDocument||Mi)!=yt&&gc(Mi);var la=qt.attrHandle[wa.toLowerCase()],Wa=la&&q.call(qt.attrHandle,wa.toLowerCase())?la(Mi,wa,!jt):void 0;return Wa!==void 0?Wa:Mi.getAttribute(wa)},Bs.error=function(Mi){throw new Error("Syntax error, unrecognized expression: "+Mi)},ie.uniqueSort=function(Mi){var wa,la=[],Wa=0,lo=0;if(Qe=!ve.sortStable,Pn=!ve.sortStable&&b.call(Mi,0),Tt.call(Mi,ts),Qe){for(;wa=Mi[lo++];)wa===Mi[lo]&&(Wa=la.push(lo));for(;Wa--;)kt.call(Mi,la[Wa],1)}return Pn=null,Mi},ie.fn.uniqueSort=function(){return this.pushStack(ie.uniqueSort(b.apply(this)))},(qt=ie.expr={cacheLength:50,createPseudo:ku,match:ac,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(Mi){return Mi[1]=Mi[1].replace($l,hu),Mi[3]=(Mi[3]||Mi[4]||Mi[5]||"").replace($l,hu),Mi[2]==="~="&&(Mi[3]=" "+Mi[3]+" "),Mi.slice(0,4)},CHILD:function(Mi){return Mi[1]=Mi[1].toLowerCase(),Mi[1].slice(0,3)==="nth"?(Mi[3]||Bs.error(Mi[0]),Mi[4]=+(Mi[4]?Mi[5]+(Mi[6]||1):2*(Mi[3]==="even"||Mi[3]==="odd")),Mi[5]=+(Mi[7]+Mi[8]||Mi[3]==="odd")):Mi[3]&&Bs.error(Mi[0]),Mi},PSEUDO:function(Mi){var wa,la=!Mi[6]&&Mi[2];return ac.CHILD.test(Mi[0])?null:(Mi[3]?Mi[2]=Mi[4]||Mi[5]||"":la&&vl.test(la)&&(wa=Jc(la,!0))&&(wa=la.indexOf(")",la.length-wa)-la.length)&&(Mi[0]=Mi[0].slice(0,wa),Mi[2]=la.slice(0,wa)),Mi.slice(0,3))}},filter:{TAG:function(Mi){var wa=Mi.replace($l,hu).toLowerCase();return Mi==="*"?function(){return!0}:function(la){return pt(la,wa)}},CLASS:function(Mi){var wa=xa[Mi+" "];return wa||(wa=new RegExp("(^|"+It+")"+Mi+"("+It+"|$)"))&&xa(Mi,function(la){return wa.test(typeof la.className=="string"&&la.className||la.getAttribute!==void 0&&la.getAttribute("class")||"")})},ATTR:function(Mi,wa,la){return function(Wa){var lo=Bs.attr(Wa,Mi);return lo==null?wa==="!=":!wa||(lo+="",wa==="="?lo===la:wa==="!="?lo!==la:wa==="^="?la&&lo.indexOf(la)===0:wa==="*="?la&&lo.indexOf(la)>-1:wa==="$="?la&&lo.slice(-la.length)===la:wa==="~="?(" "+lo.replace(Gs," ")+" ").indexOf(la)>-1:wa==="|="&&(lo===la||lo.slice(0,la.length+1)===la+"-"))}},CHILD:function(Mi,wa,la,Wa,lo){var Jo=Mi.slice(0,3)!=="nth",Xo=Mi.slice(-4)!=="last",ei=wa==="of-type";return Wa===1&&lo===0?function(ii){return!!ii.parentNode}:function(ii,Ma,pa){var ca,uo,ya,Oo,Io,Ws=Jo!==Xo?"nextSibling":"previousSibling",gr=ii.parentNode,ws=ei&&ii.nodeName.toLowerCase(),io=!pa&&!ei,Fo=!1;if(gr){if(Jo){for(;Ws;){for(ya=ii;ya=ya[Ws];)if(ei?pt(ya,ws):ya.nodeType===1)return!1;Io=Ws=Mi==="only"&&!Io&&"nextSibling"}return!0}if(Io=[Xo?gr.firstChild:gr.lastChild],Xo&&io){for(Fo=(Oo=(ca=(uo=gr[vr]||(gr[vr]={}))[Mi]||[])[0]===Jn&&ca[1])&&ca[2],ya=Oo&&gr.childNodes[Oo];ya=++Oo&&ya&&ya[Ws]||(Fo=Oo=0)||Io.pop();)if(ya.nodeType===1&&++Fo&&ya===ii){uo[Mi]=[Jn,Oo,Fo];break}}else if(io&&(Fo=Oo=(ca=(uo=ii[vr]||(ii[vr]={}))[Mi]||[])[0]===Jn&&ca[1]),Fo===!1)for(;(ya=++Oo&&ya&&ya[Ws]||(Fo=Oo=0)||Io.pop())&&(!(ei?pt(ya,ws):ya.nodeType===1)||!++Fo||(io&&((uo=ya[vr]||(ya[vr]={}))[Mi]=[Jn,Fo]),ya!==ii)););return(Fo-=lo)===Wa||Fo%Wa==0&&Fo/Wa>=0}}},PSEUDO:function(Mi,wa){var la,Wa=qt.pseudos[Mi]||qt.setFilters[Mi.toLowerCase()]||Bs.error("unsupported pseudo: "+Mi);return Wa[vr]?Wa(wa):Wa.length>1?(la=[Mi,Mi,"",wa],qt.setFilters.hasOwnProperty(Mi.toLowerCase())?ku(function(lo,Jo){for(var Xo,ei=Wa(lo,wa),ii=ei.length;ii--;)lo[Xo=N.call(lo,ei[ii])]=!(Jo[Xo]=ei[ii])}):function(lo){return Wa(lo,0,la)}):Wa}},pseudos:{not:ku(function(Mi){var wa=[],la=[],Wa=qu(Mi.replace(nn,"$1"));return Wa[vr]?ku(function(lo,Jo,Xo,ei){for(var ii,Ma=Wa(lo,null,ei,[]),pa=lo.length;pa--;)(ii=Ma[pa])&&(lo[pa]=!(Jo[pa]=ii))}):function(lo,Jo,Xo){return wa[0]=lo,Wa(wa,null,Xo,la),wa[0]=null,!la.pop()}}),has:ku(function(Mi){return function(wa){return Bs(Mi,wa).length>0}}),contains:ku(function(Mi){return Mi=Mi.replace($l,hu),function(wa){return(wa.textContent||ie.text(wa)).indexOf(Mi)>-1}}),lang:ku(function(Mi){return du.test(Mi||"")||Bs.error("unsupported lang: "+Mi),Mi=Mi.replace($l,hu).toLowerCase(),function(wa){var la;do if(la=jt?wa.lang:wa.getAttribute("xml:lang")||wa.getAttribute("lang"))return(la=la.toLowerCase())===Mi||la.indexOf(Mi+"-")===0;while((wa=wa.parentNode)&&wa.nodeType===1);return!1}}),target:function(Mi){var wa=n.location&&n.location.hash;return wa&&wa.slice(1)===Mi.id},root:function(Mi){return Mi===Rt},focus:function(Mi){return Mi===function(){try{return yt.activeElement}catch{}}()&&yt.hasFocus()&&!!(Mi.type||Mi.href||~Mi.tabIndex)},enabled:cd(!1),disabled:cd(!0),checked:function(Mi){return pt(Mi,"input")&&!!Mi.checked||pt(Mi,"option")&&!!Mi.selected},selected:function(Mi){return Mi.parentNode&&Mi.parentNode.selectedIndex,Mi.selected===!0},empty:function(Mi){for(Mi=Mi.firstChild;Mi;Mi=Mi.nextSibling)if(Mi.nodeType<6)return!1;return!0},parent:function(Mi){return!qt.pseudos.empty(Mi)},header:function(Mi){return Ju.test(Mi.nodeName)},input:function(Mi){return Xu.test(Mi.nodeName)},button:function(Mi){return pt(Mi,"input")&&Mi.type==="button"||pt(Mi,"button")},text:function(Mi){var wa;return pt(Mi,"input")&&Mi.type==="text"&&((wa=Mi.getAttribute("type"))==null||wa.toLowerCase()==="text")},first:wu(function(){return[0]}),last:wu(function(Mi,wa){return[wa-1]}),eq:wu(function(Mi,wa,la){return[la<0?la+wa:la]}),even:wu(function(Mi,wa){for(var la=0;la<wa;la+=2)Mi.push(la);return Mi}),odd:wu(function(Mi,wa){for(var la=1;la<wa;la+=2)Mi.push(la);return Mi}),lt:wu(function(Mi,wa,la){var Wa;for(Wa=la<0?la+wa:la>wa?wa:la;--Wa>=0;)Mi.push(Wa);return Mi}),gt:wu(function(Mi,wa,la){for(var Wa=la<0?la+wa:la;++Wa<wa;)Mi.push(Wa);return Mi})}}).pseudos.nth=qt.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})qt.pseudos[wt]=Uc(wt);for(wt in{submit:!0,reset:!0})qt.pseudos[wt]=Wl(wt);function dd(){}function Jc(Mi,wa){var la,Wa,lo,Jo,Xo,ei,ii,Ma=Ri[Mi+" "];if(Ma)return wa?0:Ma.slice(0);for(Xo=Mi,ei=[],ii=qt.preFilter;Xo;){for(Jo in la&&!(Wa=As.exec(Xo))||(Wa&&(Xo=Xo.slice(Wa[0].length)||Xo),ei.push(lo=[])),la=!1,(Wa=yl.exec(Xo))&&(la=Wa.shift(),lo.push({value:la,type:Wa[0].replace(nn," ")}),Xo=Xo.slice(la.length)),qt.filter)!(Wa=ac[Jo].exec(Xo))||ii[Jo]&&!(Wa=ii[Jo](Wa))||(la=Wa.shift(),lo.push({value:la,type:Jo,matches:Wa}),Xo=Xo.slice(la.length));if(!la)break}return wa?Xo.length:Xo?Bs.error(Mi):Ri(Mi,ei).slice(0)}function sc(Mi){for(var wa=0,la=Mi.length,Wa="";wa<la;wa++)Wa+=Mi[wa].value;return Wa}function qc(Mi,wa,la){var Wa=wa.dir,lo=wa.next,Jo=lo||Wa,Xo=la&&Jo==="parentNode",ei=li++;return wa.first?function(ii,Ma,pa){for(;ii=ii[Wa];)if(ii.nodeType===1||Xo)return Mi(ii,Ma,pa);return!1}:function(ii,Ma,pa){var ca,uo,ya=[Jn,ei];if(pa){for(;ii=ii[Wa];)if((ii.nodeType===1||Xo)&&Mi(ii,Ma,pa))return!0}else for(;ii=ii[Wa];)if(ii.nodeType===1||Xo)if(uo=ii[vr]||(ii[vr]={}),lo&&pt(ii,lo))ii=ii[Wa]||ii;else{if((ca=uo[Jo])&&ca[0]===Jn&&ca[1]===ei)return ya[2]=ca[2];if(uo[Jo]=ya,ya[2]=Mi(ii,Ma,pa))return!0}return!1}}function vd(Mi){return Mi.length>1?function(wa,la,Wa){for(var lo=Mi.length;lo--;)if(!Mi[lo](wa,la,Wa))return!1;return!0}:Mi[0]}function Pu(Mi,wa,la,Wa,lo){for(var Jo,Xo=[],ei=0,ii=Mi.length,Ma=wa!=null;ei<ii;ei++)(Jo=Mi[ei])&&(la&&!la(Jo,Wa,lo)||(Xo.push(Jo),Ma&&wa.push(ei)));return Xo}function ol(Mi,wa,la,Wa,lo,Jo){return Wa&&!Wa[vr]&&(Wa=ol(Wa)),lo&&!lo[vr]&&(lo=ol(lo,Jo)),ku(function(Xo,ei,ii,Ma){var pa,ca,uo,ya,Oo=[],Io=[],Ws=ei.length,gr=Xo||function(io,Fo,vs){for(var Gl=0,Mu=Fo.length;Gl<Mu;Gl++)Bs(io,Fo[Gl],vs);return vs}(wa||"*",ii.nodeType?[ii]:ii,[]),ws=!Mi||!Xo&&wa?gr:Pu(gr,Oo,Mi,ii,Ma);if(la?la(ws,ya=lo||(Xo?Mi:Ws||Wa)?[]:ei,ii,Ma):ya=ws,Wa)for(pa=Pu(ya,Io),Wa(pa,[],ii,Ma),ca=pa.length;ca--;)(uo=pa[ca])&&(ya[Io[ca]]=!(ws[Io[ca]]=uo));if(Xo){if(lo||Mi){if(lo){for(pa=[],ca=ya.length;ca--;)(uo=ya[ca])&&pa.push(ws[ca]=uo);lo(null,ya=[],pa,Ma)}for(ca=ya.length;ca--;)(uo=ya[ca])&&(pa=lo?N.call(Xo,uo):Oo[ca])>-1&&(Xo[pa]=!(ei[pa]=uo))}}else ya=Pu(ya===ei?ya.splice(Ws,ya.length):ya),lo?lo(null,ei,ya,Ma):In.apply(ei,ya)})}function od(Mi){for(var wa,la,Wa,lo=Mi.length,Jo=qt.relative[Mi[0].type],Xo=Jo||qt.relative[" "],ei=Jo?1:0,ii=qc(function(ca){return ca===wa},Xo,!0),Ma=qc(function(ca){return N.call(wa,ca)>-1},Xo,!0),pa=[function(ca,uo,ya){var Oo=!Jo&&(ya||uo!=Cn)||((wa=uo).nodeType?ii(ca,uo,ya):Ma(ca,uo,ya));return wa=null,Oo}];ei<lo;ei++)if(la=qt.relative[Mi[ei].type])pa=[qc(vd(pa),la)];else{if((la=qt.filter[Mi[ei].type].apply(null,Mi[ei].matches))[vr]){for(Wa=++ei;Wa<lo&&!qt.relative[Mi[Wa].type];Wa++);return ol(ei>1&&vd(pa),ei>1&&sc(Mi.slice(0,ei-1).concat({value:Mi[ei-2].type===" "?"*":""})).replace(nn,"$1"),la,ei<Wa&&od(Mi.slice(ei,Wa)),Wa<lo&&od(Mi=Mi.slice(Wa)),Wa<lo&&sc(Mi))}pa.push(la)}return vd(pa)}function qu(Mi,wa){var la,Wa=[],lo=[],Jo=fa[Mi+" "];if(!Jo){for(wa||(wa=Jc(Mi)),la=wa.length;la--;)(Jo=od(wa[la]))[vr]?Wa.push(Jo):lo.push(Jo);(Jo=fa(Mi,function(Xo,ei){var ii=ei.length>0,Ma=Xo.length>0,pa=function(ca,uo,ya,Oo,Io){var Ws,gr,ws,io=0,Fo="0",vs=ca&&[],Gl=[],Mu=Cn,gu=ca||Ma&&qt.find.TAG("*",Io),Nu=Jn+=Mu==null?1:Math.random()||.1,lc=gu.length;for(Io&&(Cn=uo==yt||uo||Io);Fo!==lc&&(Ws=gu[Fo])!=null;Fo++){if(Ma&&Ws){for(gr=0,uo||Ws.ownerDocument==yt||(gc(Ws),ya=!jt);ws=Xo[gr++];)if(ws(Ws,uo||yt,ya)){In.call(Oo,Ws);break}Io&&(Jn=Nu)}ii&&((Ws=!ws&&Ws)&&io--,ca&&vs.push(Ws))}if(io+=Fo,ii&&Fo!==io){for(gr=0;ws=ei[gr++];)ws(vs,Gl,uo,ya);if(ca){if(io>0)for(;Fo--;)vs[Fo]||Gl[Fo]||(Gl[Fo]=mt.call(Oo));Gl=Pu(Gl)}In.apply(Oo,Gl),Io&&!ca&&Gl.length>0&&io+ei.length>1&&ie.uniqueSort(Oo)}return Io&&(Jn=Nu,Cn=Mu),vs};return ii?ku(pa):pa}(lo,Wa))).selector=Mi}return Jo}function ah(Mi,wa,la,Wa){var lo,Jo,Xo,ei,ii,Ma=typeof Mi=="function"&&Mi,pa=!Wa&&Jc(Mi=Ma.selector||Mi);if(la=la||[],pa.length===1){if((Jo=pa[0]=pa[0].slice(0)).length>2&&(Xo=Jo[0]).type==="ID"&&wa.nodeType===9&&jt&&qt.relative[Jo[1].type]){if(!(wa=(qt.find.ID(Xo.matches[0].replace($l,hu),wa)||[])[0]))return la;Ma&&(wa=wa.parentNode),Mi=Mi.slice(Jo.shift().value.length)}for(lo=ac.needsContext.test(Mi)?0:Jo.length;lo--&&(Xo=Jo[lo],!qt.relative[ei=Xo.type]);)if((ii=qt.find[ei])&&(Wa=ii(Xo.matches[0].replace($l,hu),Nl.test(Jo[0].type)&&oc(wa.parentNode)||wa))){if(Jo.splice(lo,1),!(Mi=Wa.length&&sc(Jo)))return In.apply(la,Wa),la;break}}return(Ma||qu(Mi,pa))(Wa,wa,!jt,la,!wa||Nl.test(Mi)&&oc(wa.parentNode)||wa),la}dd.prototype=qt.filters=qt.pseudos,qt.setFilters=new dd,ve.sortStable=vr.split("").sort(ts).join("")===vr,gc(),ve.sortDetached=Hl(function(Mi){return 1&Mi.compareDocumentPosition(yt.createElement("fieldset"))}),ie.find=Bs,ie.expr[":"]=ie.expr.pseudos,ie.unique=ie.uniqueSort,Bs.compile=qu,Bs.select=ah,Bs.setDocument=gc,Bs.escape=ie.escapeSelector,Bs.getText=ie.text,Bs.isXML=ie.isXMLDoc,Bs.selectors=ie.expr,Bs.support=ie.support,Bs.uniqueSort=ie.uniqueSort})();var an=function(wt,qt,Cn){for(var Pn=[],Qe=Cn!==void 0;(wt=wt[qt])&&wt.nodeType!==9;)if(wt.nodeType===1){if(Qe&&ie(wt).is(Cn))break;Pn.push(wt)}return Pn},Rn=function(wt,qt){for(var Cn=[];wt;wt=wt.nextSibling)wt.nodeType===1&&wt!==qt&&Cn.push(wt);return Cn},Lt=ie.expr.match.needsContext,wn=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function hn(wt,qt,Cn){return ne(qt)?ie.grep(wt,function(Pn,Qe){return!!qt.call(Pn,Qe,Pn)!==Cn}):qt.nodeType?ie.grep(wt,function(Pn){return Pn===qt!==Cn}):typeof qt!="string"?ie.grep(wt,function(Pn){return N.call(qt,Pn)>-1!==Cn}):ie.filter(qt,wt,Cn)}ie.filter=function(wt,qt,Cn){var Pn=qt[0];return Cn&&(wt=":not("+wt+")"),qt.length===1&&Pn.nodeType===1?ie.find.matchesSelector(Pn,wt)?[Pn]:[]:ie.find.matches(wt,ie.grep(qt,function(Qe){return Qe.nodeType===1}))},ie.fn.extend({find:function(wt){var qt,Cn,Pn=this.length,Qe=this;if(typeof wt!="string")return this.pushStack(ie(wt).filter(function(){for(qt=0;qt<Pn;qt++)if(ie.contains(Qe[qt],this))return!0}));for(Cn=this.pushStack([]),qt=0;qt<Pn;qt++)ie.find(wt,Qe[qt],Cn);return Pn>1?ie.uniqueSort(Cn):Cn},filter:function(wt){return this.pushStack(hn(this,wt||[],!1))},not:function(wt){return this.pushStack(hn(this,wt||[],!0))},is:function(wt){return!!hn(this,typeof wt=="string"&&Lt.test(wt)?ie(wt):wt||[],!1).length}});var xn,$n=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(ie.fn.init=function(wt,qt,Cn){var Pn,Qe;if(!wt)return this;if(Cn=Cn||xn,typeof wt=="string"){if(!(Pn=wt[0]==="<"&&wt[wt.length-1]===">"&&wt.length>=3?[null,wt,null]:$n.exec(wt))||!Pn[1]&&qt)return!qt||qt.jquery?(qt||Cn).find(wt):this.constructor(qt).find(wt);if(Pn[1]){if(qt=qt instanceof ie?qt[0]:qt,ie.merge(this,ie.parseHTML(Pn[1],qt&&qt.nodeType?qt.ownerDocument||qt:De,!0)),wn.test(Pn[1])&&ie.isPlainObject(qt))for(Pn in qt)ne(this[Pn])?this[Pn](qt[Pn]):this.attr(Pn,qt[Pn]);return this}return(Qe=De.getElementById(Pn[2]))&&(this[0]=Qe,this.length=1),this}return wt.nodeType?(this[0]=wt,this.length=1,this):ne(wt)?Cn.ready!==void 0?Cn.ready(wt):wt(ie):ie.makeArray(wt,this)}).prototype=ie.fn,xn=ie(De);var Xr=/^(?:parents|prev(?:Until|All))/,ti={children:!0,contents:!0,next:!0,prev:!0};function gn(wt,qt){for(;(wt=wt[qt])&&wt.nodeType!==1;);return wt}ie.fn.extend({has:function(wt){var qt=ie(wt,this),Cn=qt.length;return this.filter(function(){for(var Pn=0;Pn<Cn;Pn++)if(ie.contains(this,qt[Pn]))return!0})},closest:function(wt,qt){var Cn,Pn=0,Qe=this.length,yt=[],Rt=typeof wt!="string"&&ie(wt);if(!Lt.test(wt)){for(;Pn<Qe;Pn++)for(Cn=this[Pn];Cn&&Cn!==qt;Cn=Cn.parentNode)if(Cn.nodeType<11&&(Rt?Rt.index(Cn)>-1:Cn.nodeType===1&&ie.find.matchesSelector(Cn,wt))){yt.push(Cn);break}}return this.pushStack(yt.length>1?ie.uniqueSort(yt):yt)},index:function(wt){return wt?typeof wt=="string"?N.call(ie(wt),this[0]):N.call(this,wt.jquery?wt[0]:wt):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(wt,qt){return this.pushStack(ie.uniqueSort(ie.merge(this.get(),ie(wt,qt))))},addBack:function(wt){return this.add(wt==null?this.prevObject:this.prevObject.filter(wt))}}),ie.each({parent:function(wt){var qt=wt.parentNode;return qt&&qt.nodeType!==11?qt:null},parents:function(wt){return an(wt,"parentNode")},parentsUntil:function(wt,qt,Cn){return an(wt,"parentNode",Cn)},next:function(wt){return gn(wt,"nextSibling")},prev:function(wt){return gn(wt,"previousSibling")},nextAll:function(wt){return an(wt,"nextSibling")},prevAll:function(wt){return an(wt,"previousSibling")},nextUntil:function(wt,qt,Cn){return an(wt,"nextSibling",Cn)},prevUntil:function(wt,qt,Cn){return an(wt,"previousSibling",Cn)},siblings:function(wt){return Rn((wt.parentNode||{}).firstChild,wt)},children:function(wt){return Rn(wt.firstChild)},contents:function(wt){return wt.contentDocument!=null&&y(wt.contentDocument)?wt.contentDocument:(pt(wt,"template")&&(wt=wt.content||wt),ie.merge([],wt.childNodes))}},function(wt,qt){ie.fn[wt]=function(Cn,Pn){var Qe=ie.map(this,qt,Cn);return wt.slice(-5)!=="Until"&&(Pn=Cn),Pn&&typeof Pn=="string"&&(Qe=ie.filter(Pn,Qe)),this.length>1&&(ti[wt]||ie.uniqueSort(Qe),Xr.test(wt)&&Qe.reverse()),this.pushStack(Qe)}});var Xn=/[^\x20\t\r\n\f]+/g;function Kn(wt){return wt}function Vn(wt){throw wt}function Yn(wt,qt,Cn,Pn){var Qe;try{wt&&ne(Qe=wt.promise)?Qe.call(wt).done(qt).fail(Cn):wt&&ne(Qe=wt.then)?Qe.call(wt,qt,Cn):qt.apply(void 0,[wt].slice(Pn))}catch(yt){Cn.apply(void 0,[yt])}}ie.Callbacks=function(wt){wt=typeof wt=="string"?function(In){var vr={};return ie.each(In.match(Xn)||[],function(Jn,li){vr[li]=!0}),vr}(wt):ie.extend({},wt);var qt,Cn,Pn,Qe,yt=[],Rt=[],jt=-1,dn=function(){for(Qe=Qe||wt.once,Pn=qt=!0;Rt.length;jt=-1)for(Cn=Rt.shift();++jt<yt.length;)yt[jt].apply(Cn[0],Cn[1])===!1&&wt.stopOnFalse&&(jt=yt.length,Cn=!1);wt.memory||(Cn=!1),qt=!1,Qe&&(yt=Cn?[]:"")},yn={add:function(){return yt&&(Cn&&!qt&&(jt=yt.length-1,Rt.push(Cn)),function In(vr){ie.each(vr,function(Jn,li){ne(li)?wt.unique&&yn.has(li)||yt.push(li):li&&li.length&&Ae(li)!=="string"&&In(li)})}(arguments),Cn&&!qt&&dn()),this},remove:function(){return ie.each(arguments,function(In,vr){for(var Jn;(Jn=ie.inArray(vr,yt,Jn))>-1;)yt.splice(Jn,1),Jn<=jt&&jt--}),this},has:function(In){return In?ie.inArray(In,yt)>-1:yt.length>0},empty:function(){return yt&&(yt=[]),this},disable:function(){return Qe=Rt=[],yt=Cn="",this},disabled:function(){return!yt},lock:function(){return Qe=Rt=[],Cn||qt||(yt=Cn=""),this},locked:function(){return!!Qe},fireWith:function(In,vr){return Qe||(vr=[In,(vr=vr||[]).slice?vr.slice():vr],Rt.push(vr),qt||dn()),this},fire:function(){return yn.fireWith(this,arguments),this},fired:function(){return!!Pn}};return yn},ie.extend({Deferred:function(wt){var qt=[["notify","progress",ie.Callbacks("memory"),ie.Callbacks("memory"),2],["resolve","done",ie.Callbacks("once memory"),ie.Callbacks("once memory"),0,"resolved"],["reject","fail",ie.Callbacks("once memory"),ie.Callbacks("once memory"),1,"rejected"]],Cn="pending",Pn={state:function(){return Cn},always:function(){return Qe.done(arguments).fail(arguments),this},catch:function(yt){return Pn.then(null,yt)},pipe:function(){var yt=arguments;return ie.Deferred(function(Rt){ie.each(qt,function(jt,dn){var yn=ne(yt[dn[4]])&&yt[dn[4]];Qe[dn[1]](function(){var In=yn&&yn.apply(this,arguments);In&&ne(In.promise)?In.promise().progress(Rt.notify).done(Rt.resolve).fail(Rt.reject):Rt[dn[0]+"With"](this,yn?[In]:arguments)})}),yt=null}).promise()},then:function(yt,Rt,jt){var dn=0;function yn(In,vr,Jn,li){return function(){var xa=this,Ri=arguments,fa=function(){var ts,bl;if(!(In<dn)){if((ts=Jn.apply(xa,Ri))===vr.promise())throw new TypeError("Thenable self-resolution");bl=ts&&(typeof ts=="object"||typeof ts=="function")&&ts.then,ne(bl)?li?bl.call(ts,yn(dn,vr,Kn,li),yn(dn,vr,Vn,li)):(dn++,bl.call(ts,yn(dn,vr,Kn,li),yn(dn,vr,Vn,li),yn(dn,vr,Kn,vr.notifyWith))):(Jn!==Kn&&(xa=void 0,Ri=[ts]),(li||vr.resolveWith)(xa,Ri))}},oo=li?fa:function(){try{fa()}catch(ts){ie.Deferred.exceptionHook&&ie.Deferred.exceptionHook(ts,oo.error),In+1>=dn&&(Jn!==Vn&&(xa=void 0,Ri=[ts]),vr.rejectWith(xa,Ri))}};In?oo():(ie.Deferred.getErrorHook?oo.error=ie.Deferred.getErrorHook():ie.Deferred.getStackHook&&(oo.error=ie.Deferred.getStackHook()),n.setTimeout(oo))}}return ie.Deferred(function(In){qt[0][3].add(yn(0,In,ne(jt)?jt:Kn,In.notifyWith)),qt[1][3].add(yn(0,In,ne(yt)?yt:Kn)),qt[2][3].add(yn(0,In,ne(Rt)?Rt:Vn))}).promise()},promise:function(yt){return yt!=null?ie.extend(yt,Pn):Pn}},Qe={};return ie.each(qt,function(yt,Rt){var jt=Rt[2],dn=Rt[5];Pn[Rt[1]]=jt.add,dn&&jt.add(function(){Cn=dn},qt[3-yt][2].disable,qt[3-yt][3].disable,qt[0][2].lock,qt[0][3].lock),jt.add(Rt[3].fire),Qe[Rt[0]]=function(){return Qe[Rt[0]+"With"](this===Qe?void 0:this,arguments),this},Qe[Rt[0]+"With"]=jt.fireWith}),Pn.promise(Qe),wt&&wt.call(Qe,Qe),Qe},when:function(wt){var qt=arguments.length,Cn=qt,Pn=Array(Cn),Qe=b.call(arguments),yt=ie.Deferred(),Rt=function(jt){return function(dn){Pn[jt]=this,Qe[jt]=arguments.length>1?b.call(arguments):dn,--qt||yt.resolveWith(Pn,Qe)}};if(qt<=1&&(Yn(wt,yt.done(Rt(Cn)).resolve,yt.reject,!qt),yt.state()==="pending"||ne(Qe[Cn]&&Qe[Cn].then)))return yt.then();for(;Cn--;)Yn(Qe[Cn],Rt(Cn),yt.reject);return yt.promise()}});var Vr=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;ie.Deferred.exceptionHook=function(wt,qt){n.console&&n.console.warn&&wt&&Vr.test(wt.name)&&n.console.warn("jQuery.Deferred exception: "+wt.message,wt.stack,qt)},ie.readyException=function(wt){n.setTimeout(function(){throw wt})};var xi=ie.Deferred();function Si(){De.removeEventListener("DOMContentLoaded",Si),n.removeEventListener("load",Si),ie.ready()}ie.fn.ready=function(wt){return xi.then(wt).catch(function(qt){ie.readyException(qt)}),this},ie.extend({isReady:!1,readyWait:1,ready:function(wt){(wt===!0?--ie.readyWait:ie.isReady)||(ie.isReady=!0,wt!==!0&&--ie.readyWait>0||xi.resolveWith(De,[ie]))}}),ie.ready.then=xi.then,De.readyState==="complete"||De.readyState!=="loading"&&!De.documentElement.doScroll?n.setTimeout(ie.ready):(De.addEventListener("DOMContentLoaded",Si),n.addEventListener("load",Si));var qn=function(wt,qt,Cn,Pn,Qe,yt,Rt){var jt=0,dn=wt.length,yn=Cn==null;if(Ae(Cn)==="object")for(jt in Qe=!0,Cn)qn(wt,qt,jt,Cn[jt],!0,yt,Rt);else if(Pn!==void 0&&(Qe=!0,ne(Pn)||(Rt=!0),yn&&(Rt?(qt.call(wt,Pn),qt=null):(yn=qt,qt=function(In,vr,Jn){return yn.call(ie(In),Jn)})),qt))for(;jt<dn;jt++)qt(wt[jt],Cn,Rt?Pn:Pn.call(wt[jt],jt,qt(wt[jt],Cn)));return Qe?wt:yn?qt.call(wt):dn?qt(wt[0],Cn):yt},ia=/^-ms-/,Wi=/-([a-z])/g;function ha(wt,qt){return qt.toUpperCase()}function ai(wt){return wt.replace(ia,"ms-").replace(Wi,ha)}var Ia=function(wt){return wt.nodeType===1||wt.nodeType===9||!+wt.nodeType};function fi(){this.expando=ie.expando+fi.uid++}fi.uid=1,fi.prototype={cache:function(wt){var qt=wt[this.expando];return qt||(qt={},Ia(wt)&&(wt.nodeType?wt[this.expando]=qt:Object.defineProperty(wt,this.expando,{value:qt,configurable:!0}))),qt},set:function(wt,qt,Cn){var Pn,Qe=this.cache(wt);if(typeof qt=="string")Qe[ai(qt)]=Cn;else for(Pn in qt)Qe[ai(Pn)]=qt[Pn];return Qe},get:function(wt,qt){return qt===void 0?this.cache(wt):wt[this.expando]&&wt[this.expando][ai(qt)]},access:function(wt,qt,Cn){return qt===void 0||qt&&typeof qt=="string"&&Cn===void 0?this.get(wt,qt):(this.set(wt,qt,Cn),Cn!==void 0?Cn:qt)},remove:function(wt,qt){var Cn,Pn=wt[this.expando];if(Pn!==void 0){if(qt!==void 0)for(Cn=(qt=Array.isArray(qt)?qt.map(ai):(qt=ai(qt))in Pn?[qt]:qt.match(Xn)||[]).length;Cn--;)delete Pn[qt[Cn]];(qt===void 0||ie.isEmptyObject(Pn))&&(wt.nodeType?wt[this.expando]=void 0:delete wt[this.expando])}},hasData:function(wt){var qt=wt[this.expando];return qt!==void 0&&!ie.isEmptyObject(qt)}};var An=new fi,sa=new fi,Nn=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,fn=/[A-Z]/g;function un(wt,qt,Cn){var Pn;if(Cn===void 0&&wt.nodeType===1)if(Pn="data-"+qt.replace(fn,"-$&").toLowerCase(),typeof(Cn=wt.getAttribute(Pn))=="string"){try{Cn=function(Qe){return Qe==="true"||Qe!=="false"&&(Qe==="null"?null:Qe===+Qe+""?+Qe:Nn.test(Qe)?JSON.parse(Qe):Qe)}(Cn)}catch{}sa.set(wt,qt,Cn)}else Cn=void 0;return Cn}ie.extend({hasData:function(wt){return sa.hasData(wt)||An.hasData(wt)},data:function(wt,qt,Cn){return sa.access(wt,qt,Cn)},removeData:function(wt,qt){sa.remove(wt,qt)},_data:function(wt,qt,Cn){return An.access(wt,qt,Cn)},_removeData:function(wt,qt){An.remove(wt,qt)}}),ie.fn.extend({data:function(wt,qt){var Cn,Pn,Qe,yt=this[0],Rt=yt&&yt.attributes;if(wt===void 0){if(this.length&&(Qe=sa.get(yt),yt.nodeType===1&&!An.get(yt,"hasDataAttrs"))){for(Cn=Rt.length;Cn--;)Rt[Cn]&&(Pn=Rt[Cn].name).indexOf("data-")===0&&(Pn=ai(Pn.slice(5)),un(yt,Pn,Qe[Pn]));An.set(yt,"hasDataAttrs",!0)}return Qe}return typeof wt=="object"?this.each(function(){sa.set(this,wt)}):qn(this,function(jt){var dn;if(yt&&jt===void 0)return(dn=sa.get(yt,wt))!==void 0||(dn=un(yt,wt))!==void 0?dn:void 0;this.each(function(){sa.set(this,wt,jt)})},null,qt,arguments.length>1,null,!0)},removeData:function(wt){return this.each(function(){sa.remove(this,wt)})}}),ie.extend({queue:function(wt,qt,Cn){var Pn;if(wt)return qt=(qt||"fx")+"queue",Pn=An.get(wt,qt),Cn&&(!Pn||Array.isArray(Cn)?Pn=An.access(wt,qt,ie.makeArray(Cn)):Pn.push(Cn)),Pn||[]},dequeue:function(wt,qt){qt=qt||"fx";var Cn=ie.queue(wt,qt),Pn=Cn.length,Qe=Cn.shift(),yt=ie._queueHooks(wt,qt);Qe==="inprogress"&&(Qe=Cn.shift(),Pn--),Qe&&(qt==="fx"&&Cn.unshift("inprogress"),delete yt.stop,Qe.call(wt,function(){ie.dequeue(wt,qt)},yt)),!Pn&&yt&&yt.empty.fire()},_queueHooks:function(wt,qt){var Cn=qt+"queueHooks";return An.get(wt,Cn)||An.access(wt,Cn,{empty:ie.Callbacks("once memory").add(function(){An.remove(wt,[qt+"queue",Cn])})})}}),ie.fn.extend({queue:function(wt,qt){var Cn=2;return typeof wt!="string"&&(qt=wt,wt="fx",Cn--),arguments.length<Cn?ie.queue(this[0],wt):qt===void 0?this:this.each(function(){var Pn=ie.queue(this,wt,qt);ie._queueHooks(this,wt),wt==="fx"&&Pn[0]!=="inprogress"&&ie.dequeue(this,wt)})},dequeue:function(wt){return this.each(function(){ie.dequeue(this,wt)})},clearQueue:function(wt){return this.queue(wt||"fx",[])},promise:function(wt,qt){var Cn,Pn=1,Qe=ie.Deferred(),yt=this,Rt=this.length,jt=function(){--Pn||Qe.resolveWith(yt,[yt])};for(typeof wt!="string"&&(qt=wt,wt=void 0),wt=wt||"fx";Rt--;)(Cn=An.get(yt[Rt],wt+"queueHooks"))&&Cn.empty&&(Pn++,Cn.empty.add(jt));return jt(),Qe.promise(qt)}});var Ln=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,hr=new RegExp("^(?:([+-])=|)("+Ln+")([a-z%]*)$","i"),hi=["Top","Right","Bottom","Left"],bi=De.documentElement,Ra=function(wt){return ie.contains(wt.ownerDocument,wt)},so={composed:!0};bi.getRootNode&&(Ra=function(wt){return ie.contains(wt.ownerDocument,wt)||wt.getRootNode(so)===wt.ownerDocument});var Pi=function(wt,qt){return(wt=qt||wt).style.display==="none"||wt.style.display===""&&Ra(wt)&&ie.css(wt,"display")==="none"};function oi(wt,qt,Cn,Pn){var Qe,yt,Rt=20,jt=Pn?function(){return Pn.cur()}:function(){return ie.css(wt,qt,"")},dn=jt(),yn=Cn&&Cn[3]||(ie.cssNumber[qt]?"":"px"),In=wt.nodeType&&(ie.cssNumber[qt]||yn!=="px"&&+dn)&&hr.exec(ie.css(wt,qt));if(In&&In[3]!==yn){for(dn/=2,yn=yn||In[3],In=+dn||1;Rt--;)ie.style(wt,qt,In+yn),(1-yt)*(1-(yt=jt()/dn||.5))<=0&&(Rt=0),In/=yt;In*=2,ie.style(wt,qt,In+yn),Cn=Cn||[]}return Cn&&(In=+In||+dn||0,Qe=Cn[1]?In+(Cn[1]+1)*Cn[2]:+Cn[2],Pn&&(Pn.unit=yn,Pn.start=In,Pn.end=Qe)),Qe}var Ni={};function za(wt){var qt,Cn=wt.ownerDocument,Pn=wt.nodeName,Qe=Ni[Pn];return Qe||(qt=Cn.body.appendChild(Cn.createElement(Pn)),Qe=ie.css(qt,"display"),qt.parentNode.removeChild(qt),Qe==="none"&&(Qe="block"),Ni[Pn]=Qe,Qe)}function ki(wt,qt){for(var Cn,Pn,Qe=[],yt=0,Rt=wt.length;yt<Rt;yt++)(Pn=wt[yt]).style&&(Cn=Pn.style.display,qt?(Cn==="none"&&(Qe[yt]=An.get(Pn,"display")||null,Qe[yt]||(Pn.style.display="")),Pn.style.display===""&&Pi(Pn)&&(Qe[yt]=za(Pn))):Cn!=="none"&&(Qe[yt]="none",An.set(Pn,"display",Cn)));for(yt=0;yt<Rt;yt++)Qe[yt]!=null&&(wt[yt].style.display=Qe[yt]);return wt}ie.fn.extend({show:function(){return ki(this,!0)},hide:function(){return ki(this)},toggle:function(wt){return typeof wt=="boolean"?wt?this.show():this.hide():this.each(function(){Pi(this)?ie(this).show():ie(this).hide()})}});var Aa,Ja,yo=/^(?:checkbox|radio)$/i,ls=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,xo=/^$|^module$|\/(?:java|ecma)script/i;Aa=De.createDocumentFragment().appendChild(De.createElement("div")),(Ja=De.createElement("input")).setAttribute("type","radio"),Ja.setAttribute("checked","checked"),Ja.setAttribute("name","t"),Aa.appendChild(Ja),ve.checkClone=Aa.cloneNode(!0).cloneNode(!0).lastChild.checked,Aa.innerHTML="<textarea>x</textarea>",ve.noCloneChecked=!!Aa.cloneNode(!0).lastChild.defaultValue,Aa.innerHTML="<option></option>",ve.option=!!Aa.lastChild;var _o={thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};function Ao(wt,qt){var Cn;return Cn=wt.getElementsByTagName!==void 0?wt.getElementsByTagName(qt||"*"):wt.querySelectorAll!==void 0?wt.querySelectorAll(qt||"*"):[],qt===void 0||qt&&pt(wt,qt)?ie.merge([wt],Cn):Cn}function il(wt,qt){for(var Cn=0,Pn=wt.length;Cn<Pn;Cn++)An.set(wt[Cn],"globalEval",!qt||An.get(qt[Cn],"globalEval"))}_o.tbody=_o.tfoot=_o.colgroup=_o.caption=_o.thead,_o.th=_o.td,ve.option||(_o.optgroup=_o.option=[1,"<select multiple='multiple'>","</select>"]);var zr=/<|&#?\w+;/;function zn(wt,qt,Cn,Pn,Qe){for(var yt,Rt,jt,dn,yn,In,vr=qt.createDocumentFragment(),Jn=[],li=0,xa=wt.length;li<xa;li++)if((yt=wt[li])||yt===0)if(Ae(yt)==="object")ie.merge(Jn,yt.nodeType?[yt]:yt);else if(zr.test(yt)){for(Rt=Rt||vr.appendChild(qt.createElement("div")),jt=(ls.exec(yt)||["",""])[1].toLowerCase(),dn=_o[jt]||_o._default,Rt.innerHTML=dn[1]+ie.htmlPrefilter(yt)+dn[2],In=dn[0];In--;)Rt=Rt.lastChild;ie.merge(Jn,Rt.childNodes),(Rt=vr.firstChild).textContent=""}else Jn.push(qt.createTextNode(yt));for(vr.textContent="",li=0;yt=Jn[li++];)if(Pn&&ie.inArray(yt,Pn)>-1)Qe&&Qe.push(yt);else if(yn=Ra(yt),Rt=Ao(vr.appendChild(yt),"script"),yn&&il(Rt),Cn)for(In=0;yt=Rt[In++];)xo.test(yt.type||"")&&Cn.push(yt);return vr}var Un=/^([^.]*)(?:\.(.+)|)/;function Gr(){return!0}function ni(){return!1}function Ei(wt,qt,Cn,Pn,Qe,yt){var Rt,jt;if(typeof qt=="object"){for(jt in typeof Cn!="string"&&(Pn=Pn||Cn,Cn=void 0),qt)Ei(wt,jt,Cn,Pn,qt[jt],yt);return wt}if(Pn==null&&Qe==null?(Qe=Cn,Pn=Cn=void 0):Qe==null&&(typeof Cn=="string"?(Qe=Pn,Pn=void 0):(Qe=Pn,Pn=Cn,Cn=void 0)),Qe===!1)Qe=ni;else if(!Qe)return wt;return yt===1&&(Rt=Qe,(Qe=function(dn){return ie().off(dn),Rt.apply(this,arguments)}).guid=Rt.guid||(Rt.guid=ie.guid++)),wt.each(function(){ie.event.add(this,qt,Qe,Pn,Cn)})}function $t(wt,qt,Cn){Cn?(An.set(wt,qt,!1),ie.event.add(wt,qt,{namespace:!1,handler:function(Pn){var Qe,yt=An.get(this,qt);if(1&Pn.isTrigger&&this[qt]){if(yt)(ie.event.special[qt]||{}).delegateType&&Pn.stopPropagation();else if(yt=b.call(arguments),An.set(this,qt,yt),this[qt](),Qe=An.get(this,qt),An.set(this,qt,!1),yt!==Qe)return Pn.stopImmediatePropagation(),Pn.preventDefault(),Qe}else yt&&(An.set(this,qt,ie.event.trigger(yt[0],yt.slice(1),this)),Pn.stopPropagation(),Pn.isImmediatePropagationStopped=Gr)}})):An.get(wt,qt)===void 0&&ie.event.add(wt,qt,Gr)}ie.event={global:{},add:function(wt,qt,Cn,Pn,Qe){var yt,Rt,jt,dn,yn,In,vr,Jn,li,xa,Ri,fa=An.get(wt);if(Ia(wt))for(Cn.handler&&(Cn=(yt=Cn).handler,Qe=yt.selector),Qe&&ie.find.matchesSelector(bi,Qe),Cn.guid||(Cn.guid=ie.guid++),(dn=fa.events)||(dn=fa.events=Object.create(null)),(Rt=fa.handle)||(Rt=fa.handle=function(oo){return ie!==void 0&&ie.event.triggered!==oo.type?ie.event.dispatch.apply(wt,arguments):void 0}),yn=(qt=(qt||"").match(Xn)||[""]).length;yn--;)li=Ri=(jt=Un.exec(qt[yn])||[])[1],xa=(jt[2]||"").split(".").sort(),li&&(vr=ie.event.special[li]||{},li=(Qe?vr.delegateType:vr.bindType)||li,vr=ie.event.special[li]||{},In=ie.extend({type:li,origType:Ri,data:Pn,handler:Cn,guid:Cn.guid,selector:Qe,needsContext:Qe&&ie.expr.match.needsContext.test(Qe),namespace:xa.join(".")},yt),(Jn=dn[li])||((Jn=dn[li]=[]).delegateCount=0,vr.setup&&vr.setup.call(wt,Pn,xa,Rt)!==!1||wt.addEventListener&&wt.addEventListener(li,Rt)),vr.add&&(vr.add.call(wt,In),In.handler.guid||(In.handler.guid=Cn.guid)),Qe?Jn.splice(Jn.delegateCount++,0,In):Jn.push(In),ie.event.global[li]=!0)},remove:function(wt,qt,Cn,Pn,Qe){var yt,Rt,jt,dn,yn,In,vr,Jn,li,xa,Ri,fa=An.hasData(wt)&&An.get(wt);if(fa&&(dn=fa.events)){for(yn=(qt=(qt||"").match(Xn)||[""]).length;yn--;)if(li=Ri=(jt=Un.exec(qt[yn])||[])[1],xa=(jt[2]||"").split(".").sort(),li){for(vr=ie.event.special[li]||{},Jn=dn[li=(Pn?vr.delegateType:vr.bindType)||li]||[],jt=jt[2]&&new RegExp("(^|\\.)"+xa.join("\\.(?:.*\\.|)")+"(\\.|$)"),Rt=yt=Jn.length;yt--;)In=Jn[yt],!Qe&&Ri!==In.origType||Cn&&Cn.guid!==In.guid||jt&&!jt.test(In.namespace)||Pn&&Pn!==In.selector&&(Pn!=="**"||!In.selector)||(Jn.splice(yt,1),In.selector&&Jn.delegateCount--,vr.remove&&vr.remove.call(wt,In));Rt&&!Jn.length&&(vr.teardown&&vr.teardown.call(wt,xa,fa.handle)!==!1||ie.removeEvent(wt,li,fa.handle),delete dn[li])}else for(li in dn)ie.event.remove(wt,li+qt[yn],Cn,Pn,!0);ie.isEmptyObject(dn)&&An.remove(wt,"handle events")}},dispatch:function(wt){var qt,Cn,Pn,Qe,yt,Rt,jt=new Array(arguments.length),dn=ie.event.fix(wt),yn=(An.get(this,"events")||Object.create(null))[dn.type]||[],In=ie.event.special[dn.type]||{};for(jt[0]=dn,qt=1;qt<arguments.length;qt++)jt[qt]=arguments[qt];if(dn.delegateTarget=this,!In.preDispatch||In.preDispatch.call(this,dn)!==!1){for(Rt=ie.event.handlers.call(this,dn,yn),qt=0;(Qe=Rt[qt++])&&!dn.isPropagationStopped();)for(dn.currentTarget=Qe.elem,Cn=0;(yt=Qe.handlers[Cn++])&&!dn.isImmediatePropagationStopped();)dn.rnamespace&&yt.namespace!==!1&&!dn.rnamespace.test(yt.namespace)||(dn.handleObj=yt,dn.data=yt.data,(Pn=((ie.event.special[yt.origType]||{}).handle||yt.handler).apply(Qe.elem,jt))!==void 0&&(dn.result=Pn)===!1&&(dn.preventDefault(),dn.stopPropagation()));return In.postDispatch&&In.postDispatch.call(this,dn),dn.result}},handlers:function(wt,qt){var Cn,Pn,Qe,yt,Rt,jt=[],dn=qt.delegateCount,yn=wt.target;if(dn&&yn.nodeType&&!(wt.type==="click"&&wt.button>=1)){for(;yn!==this;yn=yn.parentNode||this)if(yn.nodeType===1&&(wt.type!=="click"||yn.disabled!==!0)){for(yt=[],Rt={},Cn=0;Cn<dn;Cn++)Rt[Qe=(Pn=qt[Cn]).selector+" "]===void 0&&(Rt[Qe]=Pn.needsContext?ie(Qe,this).index(yn)>-1:ie.find(Qe,this,null,[yn]).length),Rt[Qe]&&yt.push(Pn);yt.length&&jt.push({elem:yn,handlers:yt})}}return yn=this,dn<qt.length&&jt.push({elem:yn,handlers:qt.slice(dn)}),jt},addProp:function(wt,qt){Object.defineProperty(ie.Event.prototype,wt,{enumerable:!0,configurable:!0,get:ne(qt)?function(){if(this.originalEvent)return qt(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[wt]},set:function(Cn){Object.defineProperty(this,wt,{enumerable:!0,configurable:!0,writable:!0,value:Cn})}})},fix:function(wt){return wt[ie.expando]?wt:new ie.Event(wt)},special:{load:{noBubble:!0},click:{setup:function(wt){var qt=this||wt;return yo.test(qt.type)&&qt.click&&pt(qt,"input")&&$t(qt,"click",!0),!1},trigger:function(wt){var qt=this||wt;return yo.test(qt.type)&&qt.click&&pt(qt,"input")&&$t(qt,"click"),!0},_default:function(wt){var qt=wt.target;return yo.test(qt.type)&&qt.click&&pt(qt,"input")&&An.get(qt,"click")||pt(qt,"a")}},beforeunload:{postDispatch:function(wt){wt.result!==void 0&&wt.originalEvent&&(wt.originalEvent.returnValue=wt.result)}}}},ie.removeEvent=function(wt,qt,Cn){wt.removeEventListener&&wt.removeEventListener(qt,Cn)},ie.Event=function(wt,qt){if(!(this instanceof ie.Event))return new ie.Event(wt,qt);wt&&wt.type?(this.originalEvent=wt,this.type=wt.type,this.isDefaultPrevented=wt.defaultPrevented||wt.defaultPrevented===void 0&&wt.returnValue===!1?Gr:ni,this.target=wt.target&&wt.target.nodeType===3?wt.target.parentNode:wt.target,this.currentTarget=wt.currentTarget,this.relatedTarget=wt.relatedTarget):this.type=wt,qt&&ie.extend(this,qt),this.timeStamp=wt&&wt.timeStamp||Date.now(),this[ie.expando]=!0},ie.Event.prototype={constructor:ie.Event,isDefaultPrevented:ni,isPropagationStopped:ni,isImmediatePropagationStopped:ni,isSimulated:!1,preventDefault:function(){var wt=this.originalEvent;this.isDefaultPrevented=Gr,wt&&!this.isSimulated&&wt.preventDefault()},stopPropagation:function(){var wt=this.originalEvent;this.isPropagationStopped=Gr,wt&&!this.isSimulated&&wt.stopPropagation()},stopImmediatePropagation:function(){var wt=this.originalEvent;this.isImmediatePropagationStopped=Gr,wt&&!this.isSimulated&&wt.stopImmediatePropagation(),this.stopPropagation()}},ie.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,char:!0,code:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:!0},ie.event.addProp),ie.each({focus:"focusin",blur:"focusout"},function(wt,qt){function Cn(Pn){if(De.documentMode){var Qe=An.get(this,"handle"),yt=ie.event.fix(Pn);yt.type=Pn.type==="focusin"?"focus":"blur",yt.isSimulated=!0,Qe(Pn),yt.target===yt.currentTarget&&Qe(yt)}else ie.event.simulate(qt,Pn.target,ie.event.fix(Pn))}ie.event.special[wt]={setup:function(){var Pn;if($t(this,wt,!0),!De.documentMode)return!1;(Pn=An.get(this,qt))||this.addEventListener(qt,Cn),An.set(this,qt,(Pn||0)+1)},trigger:function(){return $t(this,wt),!0},teardown:function(){var Pn;if(!De.documentMode)return!1;(Pn=An.get(this,qt)-1)?An.set(this,qt,Pn):(this.removeEventListener(qt,Cn),An.remove(this,qt))},_default:function(Pn){return An.get(Pn.target,wt)},delegateType:qt},ie.event.special[qt]={setup:function(){var Pn=this.ownerDocument||this.document||this,Qe=De.documentMode?this:Pn,yt=An.get(Qe,qt);yt||(De.documentMode?this.addEventListener(qt,Cn):Pn.addEventListener(wt,Cn,!0)),An.set(Qe,qt,(yt||0)+1)},teardown:function(){var Pn=this.ownerDocument||this.document||this,Qe=De.documentMode?this:Pn,yt=An.get(Qe,qt)-1;yt?An.set(Qe,qt,yt):(De.documentMode?this.removeEventListener(qt,Cn):Pn.removeEventListener(wt,Cn,!0),An.remove(Qe,qt))}}}),ie.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(wt,qt){ie.event.special[wt]={delegateType:qt,bindType:qt,handle:function(Cn){var Pn,Qe=Cn.relatedTarget,yt=Cn.handleObj;return Qe&&(Qe===this||ie.contains(this,Qe))||(Cn.type=yt.origType,Pn=yt.handler.apply(this,arguments),Cn.type=qt),Pn}}}),ie.fn.extend({on:function(wt,qt,Cn,Pn){return Ei(this,wt,qt,Cn,Pn)},one:function(wt,qt,Cn,Pn){return Ei(this,wt,qt,Cn,Pn,1)},off:function(wt,qt,Cn){var Pn,Qe;if(wt&&wt.preventDefault&&wt.handleObj)return Pn=wt.handleObj,ie(wt.delegateTarget).off(Pn.namespace?Pn.origType+"."+Pn.namespace:Pn.origType,Pn.selector,Pn.handler),this;if(typeof wt=="object"){for(Qe in wt)this.off(Qe,qt,wt[Qe]);return this}return qt!==!1&&typeof qt!="function"||(Cn=qt,qt=void 0),Cn===!1&&(Cn=ni),this.each(function(){ie.event.remove(this,wt,Cn,qt)})}});var ta=/<script|<style|<link/i,Hi=/checked\s*(?:[^=]|=\s*.checked.)/i,Ai=/^\s*<!\[CDATA\[|\]\]>\s*$/g;function Ea(wt,qt){return pt(wt,"table")&&pt(qt.nodeType!==11?qt:qt.firstChild,"tr")&&ie(wt).children("tbody")[0]||wt}function wo(wt){return wt.type=(wt.getAttribute("type")!==null)+"/"+wt.type,wt}function to(wt){return(wt.type||"").slice(0,5)==="true/"?wt.type=wt.type.slice(5):wt.removeAttribute("type"),wt}function zo(wt,qt){var Cn,Pn,Qe,yt,Rt,jt;if(qt.nodeType===1){if(An.hasData(wt)&&(jt=An.get(wt).events))for(Qe in An.remove(qt,"handle events"),jt)for(Cn=0,Pn=jt[Qe].length;Cn<Pn;Cn++)ie.event.add(qt,Qe,jt[Qe][Cn]);sa.hasData(wt)&&(yt=sa.access(wt),Rt=ie.extend({},yt),sa.set(qt,Rt))}}function Po(wt,qt){var Cn=qt.nodeName.toLowerCase();Cn==="input"&&yo.test(wt.type)?qt.checked=wt.checked:Cn!=="input"&&Cn!=="textarea"||(qt.defaultValue=wt.defaultValue)}function Lo(wt,qt,Cn,Pn){qt=m(qt);var Qe,yt,Rt,jt,dn,yn,In=0,vr=wt.length,Jn=vr-1,li=qt[0],xa=ne(li);if(xa||vr>1&&typeof li=="string"&&!ve.checkClone&&Hi.test(li))return wt.each(function(Ri){var fa=wt.eq(Ri);xa&&(qt[0]=li.call(this,Ri,fa.html())),Lo(fa,qt,Cn,Pn)});if(vr&&(yt=(Qe=zn(qt,wt[0].ownerDocument,!1,wt,Pn)).firstChild,Qe.childNodes.length===1&&(Qe=yt),yt||Pn)){for(jt=(Rt=ie.map(Ao(Qe,"script"),wo)).length;In<vr;In++)dn=Qe,In!==Jn&&(dn=ie.clone(dn,!0,!0),jt&&ie.merge(Rt,Ao(dn,"script"))),Cn.call(wt[In],dn,In);if(jt)for(yn=Rt[Rt.length-1].ownerDocument,ie.map(Rt,to),In=0;In<jt;In++)dn=Rt[In],xo.test(dn.type||"")&&!An.access(dn,"globalEval")&&ie.contains(yn,dn)&&(dn.src&&(dn.type||"").toLowerCase()!=="module"?ie._evalUrl&&!dn.noModule&&ie._evalUrl(dn.src,{nonce:dn.nonce||dn.getAttribute("nonce")},yn):rt(dn.textContent.replace(Ai,""),dn,yn))}return wt}function Wo(wt,qt,Cn){for(var Pn,Qe=qt?ie.filter(qt,wt):wt,yt=0;(Pn=Qe[yt])!=null;yt++)Cn||Pn.nodeType!==1||ie.cleanData(Ao(Pn)),Pn.parentNode&&(Cn&&Ra(Pn)&&il(Ao(Pn,"script")),Pn.parentNode.removeChild(Pn));return wt}ie.extend({htmlPrefilter:function(wt){return wt},clone:function(wt,qt,Cn){var Pn,Qe,yt,Rt,jt=wt.cloneNode(!0),dn=Ra(wt);if(!(ve.noCloneChecked||wt.nodeType!==1&&wt.nodeType!==11||ie.isXMLDoc(wt)))for(Rt=Ao(jt),Pn=0,Qe=(yt=Ao(wt)).length;Pn<Qe;Pn++)Po(yt[Pn],Rt[Pn]);if(qt)if(Cn)for(yt=yt||Ao(wt),Rt=Rt||Ao(jt),Pn=0,Qe=yt.length;Pn<Qe;Pn++)zo(yt[Pn],Rt[Pn]);else zo(wt,jt);return(Rt=Ao(jt,"script")).length>0&&il(Rt,!dn&&Ao(wt,"script")),jt},cleanData:function(wt){for(var qt,Cn,Pn,Qe=ie.event.special,yt=0;(Cn=wt[yt])!==void 0;yt++)if(Ia(Cn)){if(qt=Cn[An.expando]){if(qt.events)for(Pn in qt.events)Qe[Pn]?ie.event.remove(Cn,Pn):ie.removeEvent(Cn,Pn,qt.handle);Cn[An.expando]=void 0}Cn[sa.expando]&&(Cn[sa.expando]=void 0)}}}),ie.fn.extend({detach:function(wt){return Wo(this,wt,!0)},remove:function(wt){return Wo(this,wt)},text:function(wt){return qn(this,function(qt){return qt===void 0?ie.text(this):this.empty().each(function(){this.nodeType!==1&&this.nodeType!==11&&this.nodeType!==9||(this.textContent=qt)})},null,wt,arguments.length)},append:function(){return Lo(this,arguments,function(wt){this.nodeType!==1&&this.nodeType!==11&&this.nodeType!==9||Ea(this,wt).appendChild(wt)})},prepend:function(){return Lo(this,arguments,function(wt){if(this.nodeType===1||this.nodeType===11||this.nodeType===9){var qt=Ea(this,wt);qt.insertBefore(wt,qt.firstChild)}})},before:function(){return Lo(this,arguments,function(wt){this.parentNode&&this.parentNode.insertBefore(wt,this)})},after:function(){return Lo(this,arguments,function(wt){this.parentNode&&this.parentNode.insertBefore(wt,this.nextSibling)})},empty:function(){for(var wt,qt=0;(wt=this[qt])!=null;qt++)wt.nodeType===1&&(ie.cleanData(Ao(wt,!1)),wt.textContent="");return this},clone:function(wt,qt){return wt=wt!=null&&wt,qt=qt??wt,this.map(function(){return ie.clone(this,wt,qt)})},html:function(wt){return qn(this,function(qt){var Cn=this[0]||{},Pn=0,Qe=this.length;if(qt===void 0&&Cn.nodeType===1)return Cn.innerHTML;if(typeof qt=="string"&&!ta.test(qt)&&!_o[(ls.exec(qt)||["",""])[1].toLowerCase()]){qt=ie.htmlPrefilter(qt);try{for(;Pn<Qe;Pn++)(Cn=this[Pn]||{}).nodeType===1&&(ie.cleanData(Ao(Cn,!1)),Cn.innerHTML=qt);Cn=0}catch{}}Cn&&this.empty().append(qt)},null,wt,arguments.length)},replaceWith:function(){var wt=[];return Lo(this,arguments,function(qt){var Cn=this.parentNode;ie.inArray(this,wt)<0&&(ie.cleanData(Ao(this)),Cn&&Cn.replaceChild(qt,this))},wt)}}),ie.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(wt,qt){ie.fn[wt]=function(Cn){for(var Pn,Qe=[],yt=ie(Cn),Rt=yt.length-1,jt=0;jt<=Rt;jt++)Pn=jt===Rt?this:this.clone(!0),ie(yt[jt])[qt](Pn),O.apply(Qe,Pn.get());return this.pushStack(Qe)}});var ma=new RegExp("^("+Ln+")(?!px)[a-z%]+$","i"),$s=/^--/,ao=function(wt){var qt=wt.ownerDocument.defaultView;return qt&&qt.opener||(qt=n),qt.getComputedStyle(wt)},Ps=function(wt,qt,Cn){var Pn,Qe,yt={};for(Qe in qt)yt[Qe]=wt.style[Qe],wt.style[Qe]=qt[Qe];for(Qe in Pn=Cn.call(wt),qt)wt.style[Qe]=yt[Qe];return Pn},qo=new RegExp(hi.join("|"),"i");function wl(wt,qt,Cn){var Pn,Qe,yt,Rt,jt=$s.test(qt),dn=wt.style;return(Cn=Cn||ao(wt))&&(Rt=Cn.getPropertyValue(qt)||Cn[qt],jt&&Rt&&(Rt=Rt.replace(nn,"$1")||void 0),Rt!==""||Ra(wt)||(Rt=ie.style(wt,qt)),!ve.pixelBoxStyles()&&ma.test(Rt)&&qo.test(qt)&&(Pn=dn.width,Qe=dn.minWidth,yt=dn.maxWidth,dn.minWidth=dn.maxWidth=dn.width=Rt,Rt=Cn.width,dn.width=Pn,dn.minWidth=Qe,dn.maxWidth=yt)),Rt!==void 0?Rt+"":Rt}function yu(wt,qt){return{get:function(){if(!wt())return(this.get=qt).apply(this,arguments);delete this.get}}}(function(){function wt(){if(yn){dn.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",yn.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",bi.appendChild(dn).appendChild(yn);var In=n.getComputedStyle(yn);Cn=In.top!=="1%",jt=qt(In.marginLeft)===12,yn.style.right="60%",yt=qt(In.right)===36,Pn=qt(In.width)===36,yn.style.position="absolute",Qe=qt(yn.offsetWidth/3)===12,bi.removeChild(dn),yn=null}}function qt(In){return Math.round(parseFloat(In))}var Cn,Pn,Qe,yt,Rt,jt,dn=De.createElement("div"),yn=De.createElement("div");yn.style&&(yn.style.backgroundClip="content-box",yn.cloneNode(!0).style.backgroundClip="",ve.clearCloneStyle=yn.style.backgroundClip==="content-box",ie.extend(ve,{boxSizingReliable:function(){return wt(),Pn},pixelBoxStyles:function(){return wt(),yt},pixelPosition:function(){return wt(),Cn},reliableMarginLeft:function(){return wt(),jt},scrollboxSize:function(){return wt(),Qe},reliableTrDimensions:function(){var In,vr,Jn,li;return Rt==null&&(In=De.createElement("table"),vr=De.createElement("tr"),Jn=De.createElement("div"),In.style.cssText="position:absolute;left:-11111px;border-collapse:separate",vr.style.cssText="border:1px solid",vr.style.height="1px",Jn.style.height="9px",Jn.style.display="block",bi.appendChild(In).appendChild(vr).appendChild(Jn),li=n.getComputedStyle(vr),Rt=parseInt(li.height,10)+parseInt(li.borderTopWidth,10)+parseInt(li.borderBottomWidth,10)===vr.offsetHeight,bi.removeChild(In)),Rt}}))})();var po=["Webkit","Moz","ms"],Zs=De.createElement("div").style,Es={};function Xl(wt){return ie.cssProps[wt]||Es[wt]||(wt in Zs?wt:Es[wt]=function(qt){for(var Cn=qt[0].toUpperCase()+qt.slice(1),Pn=po.length;Pn--;)if((qt=po[Pn]+Cn)in Zs)return qt}(wt)||wt)}var xl=/^(none|table(?!-c[ea]).+)/,jo={position:"absolute",visibility:"hidden",display:"block"},ju={letterSpacing:"0",fontWeight:"400"};function Pl(wt,qt,Cn){var Pn=hr.exec(qt);return Pn?Math.max(0,Pn[2]-(Cn||0))+(Pn[3]||"px"):qt}function tl(wt,qt,Cn,Pn,Qe,yt){var Rt=qt==="width"?1:0,jt=0,dn=0,yn=0;if(Cn===(Pn?"border":"content"))return 0;for(;Rt<4;Rt+=2)Cn==="margin"&&(yn+=ie.css(wt,Cn+hi[Rt],!0,Qe)),Pn?(Cn==="content"&&(dn-=ie.css(wt,"padding"+hi[Rt],!0,Qe)),Cn!=="margin"&&(dn-=ie.css(wt,"border"+hi[Rt]+"Width",!0,Qe))):(dn+=ie.css(wt,"padding"+hi[Rt],!0,Qe),Cn!=="padding"?dn+=ie.css(wt,"border"+hi[Rt]+"Width",!0,Qe):jt+=ie.css(wt,"border"+hi[Rt]+"Width",!0,Qe));return!Pn&&yt>=0&&(dn+=Math.max(0,Math.ceil(wt["offset"+qt[0].toUpperCase()+qt.slice(1)]-yt-dn-jt-.5))||0),dn+yn}function zl(wt,qt,Cn){var Pn=ao(wt),Qe=(!ve.boxSizingReliable()||Cn)&&ie.css(wt,"boxSizing",!1,Pn)==="border-box",yt=Qe,Rt=wl(wt,qt,Pn),jt="offset"+qt[0].toUpperCase()+qt.slice(1);if(ma.test(Rt)){if(!Cn)return Rt;Rt="auto"}return(!ve.boxSizingReliable()&&Qe||!ve.reliableTrDimensions()&&pt(wt,"tr")||Rt==="auto"||!parseFloat(Rt)&&ie.css(wt,"display",!1,Pn)==="inline")&&wt.getClientRects().length&&(Qe=ie.css(wt,"boxSizing",!1,Pn)==="border-box",(yt=jt in wt)&&(Rt=wt[jt])),(Rt=parseFloat(Rt)||0)+tl(wt,qt,Cn||(Qe?"border":"content"),yt,Pn,Rt)+"px"}function Is(wt,qt,Cn,Pn,Qe){return new Is.prototype.init(wt,qt,Cn,Pn,Qe)}ie.extend({cssHooks:{opacity:{get:function(wt,qt){if(qt){var Cn=wl(wt,"opacity");return Cn===""?"1":Cn}}}},cssNumber:{animationIterationCount:!0,aspectRatio:!0,borderImageSlice:!0,columnCount:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,scale:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeMiterlimit:!0,strokeOpacity:!0},cssProps:{},style:function(wt,qt,Cn,Pn){if(wt&&wt.nodeType!==3&&wt.nodeType!==8&&wt.style){var Qe,yt,Rt,jt=ai(qt),dn=$s.test(qt),yn=wt.style;if(dn||(qt=Xl(jt)),Rt=ie.cssHooks[qt]||ie.cssHooks[jt],Cn===void 0)return Rt&&"get"in Rt&&(Qe=Rt.get(wt,!1,Pn))!==void 0?Qe:yn[qt];(yt=typeof Cn)=="string"&&(Qe=hr.exec(Cn))&&Qe[1]&&(Cn=oi(wt,qt,Qe),yt="number"),Cn!=null&&Cn==Cn&&(yt!=="number"||dn||(Cn+=Qe&&Qe[3]||(ie.cssNumber[jt]?"":"px")),ve.clearCloneStyle||Cn!==""||qt.indexOf("background")!==0||(yn[qt]="inherit"),Rt&&"set"in Rt&&(Cn=Rt.set(wt,Cn,Pn))===void 0||(dn?yn.setProperty(qt,Cn):yn[qt]=Cn))}},css:function(wt,qt,Cn,Pn){var Qe,yt,Rt,jt=ai(qt);return $s.test(qt)||(qt=Xl(jt)),(Rt=ie.cssHooks[qt]||ie.cssHooks[jt])&&"get"in Rt&&(Qe=Rt.get(wt,!0,Cn)),Qe===void 0&&(Qe=wl(wt,qt,Pn)),Qe==="normal"&&qt in ju&&(Qe=ju[qt]),Cn===""||Cn?(yt=parseFloat(Qe),Cn===!0||isFinite(yt)?yt||0:Qe):Qe}}),ie.each(["height","width"],function(wt,qt){ie.cssHooks[qt]={get:function(Cn,Pn,Qe){if(Pn)return!xl.test(ie.css(Cn,"display"))||Cn.getClientRects().length&&Cn.getBoundingClientRect().width?zl(Cn,qt,Qe):Ps(Cn,jo,function(){return zl(Cn,qt,Qe)})},set:function(Cn,Pn,Qe){var yt,Rt=ao(Cn),jt=!ve.scrollboxSize()&&Rt.position==="absolute",dn=(jt||Qe)&&ie.css(Cn,"boxSizing",!1,Rt)==="border-box",yn=Qe?tl(Cn,qt,Qe,dn,Rt):0;return dn&&jt&&(yn-=Math.ceil(Cn["offset"+qt[0].toUpperCase()+qt.slice(1)]-parseFloat(Rt[qt])-tl(Cn,qt,"border",!1,Rt)-.5)),yn&&(yt=hr.exec(Pn))&&(yt[3]||"px")!=="px"&&(Cn.style[qt]=Pn,Pn=ie.css(Cn,qt)),Pl(0,Pn,yn)}}}),ie.cssHooks.marginLeft=yu(ve.reliableMarginLeft,function(wt,qt){if(qt)return(parseFloat(wl(wt,"marginLeft"))||wt.getBoundingClientRect().left-Ps(wt,{marginLeft:0},function(){return wt.getBoundingClientRect().left}))+"px"}),ie.each({margin:"",padding:"",border:"Width"},function(wt,qt){ie.cssHooks[wt+qt]={expand:function(Cn){for(var Pn=0,Qe={},yt=typeof Cn=="string"?Cn.split(" "):[Cn];Pn<4;Pn++)Qe[wt+hi[Pn]+qt]=yt[Pn]||yt[Pn-2]||yt[0];return Qe}},wt!=="margin"&&(ie.cssHooks[wt+qt].set=Pl)}),ie.fn.extend({css:function(wt,qt){return qn(this,function(Cn,Pn,Qe){var yt,Rt,jt={},dn=0;if(Array.isArray(Pn)){for(yt=ao(Cn),Rt=Pn.length;dn<Rt;dn++)jt[Pn[dn]]=ie.css(Cn,Pn[dn],!1,yt);return jt}return Qe!==void 0?ie.style(Cn,Pn,Qe):ie.css(Cn,Pn)},wt,qt,arguments.length>1)}}),ie.Tween=Is,Is.prototype={constructor:Is,init:function(wt,qt,Cn,Pn,Qe,yt){this.elem=wt,this.prop=Cn,this.easing=Qe||ie.easing._default,this.options=qt,this.start=this.now=this.cur(),this.end=Pn,this.unit=yt||(ie.cssNumber[Cn]?"":"px")},cur:function(){var wt=Is.propHooks[this.prop];return wt&&wt.get?wt.get(this):Is.propHooks._default.get(this)},run:function(wt){var qt,Cn=Is.propHooks[this.prop];return this.options.duration?this.pos=qt=ie.easing[this.easing](wt,this.options.duration*wt,0,1,this.options.duration):this.pos=qt=wt,this.now=(this.end-this.start)*qt+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),Cn&&Cn.set?Cn.set(this):Is.propHooks._default.set(this),this}},Is.prototype.init.prototype=Is.prototype,Is.propHooks={_default:{get:function(wt){var qt;return wt.elem.nodeType!==1||wt.elem[wt.prop]!=null&&wt.elem.style[wt.prop]==null?wt.elem[wt.prop]:(qt=ie.css(wt.elem,wt.prop,""))&&qt!=="auto"?qt:0},set:function(wt){ie.fx.step[wt.prop]?ie.fx.step[wt.prop](wt):wt.elem.nodeType!==1||!ie.cssHooks[wt.prop]&&wt.elem.style[Xl(wt.prop)]==null?wt.elem[wt.prop]=wt.now:ie.style(wt.elem,wt.prop,wt.now+wt.unit)}}},Is.propHooks.scrollTop=Is.propHooks.scrollLeft={set:function(wt){wt.elem.nodeType&&wt.elem.parentNode&&(wt.elem[wt.prop]=wt.now)}},ie.easing={linear:function(wt){return wt},swing:function(wt){return .5-Math.cos(wt*Math.PI)/2},_default:"swing"},ie.fx=Is.prototype.init,ie.fx.step={};var al,Mn,Ur=/^(?:toggle|show|hide)$/,Gn=/queueHooks$/;function Qr(){Mn&&(De.hidden===!1&&n.requestAnimationFrame?n.requestAnimationFrame(Qr):n.setTimeout(Qr,ie.fx.interval),ie.fx.tick())}function qi(){return n.setTimeout(function(){al=void 0}),al=Date.now()}function ga(wt,qt){var Cn,Pn=0,Qe={height:wt};for(qt=qt?1:0;Pn<4;Pn+=2-qt)Qe["margin"+(Cn=hi[Pn])]=Qe["padding"+Cn]=wt;return qt&&(Qe.opacity=Qe.width=wt),Qe}function no(wt,qt,Cn){for(var Pn,Qe=(mo.tweeners[qt]||[]).concat(mo.tweeners["*"]),yt=0,Rt=Qe.length;yt<Rt;yt++)if(Pn=Qe[yt].call(Cn,qt,wt))return Pn}function mo(wt,qt,Cn){var Pn,Qe,yt=0,Rt=mo.prefilters.length,jt=ie.Deferred().always(function(){delete dn.elem}),dn=function(){if(Qe)return!1;for(var vr=al||qi(),Jn=Math.max(0,yn.startTime+yn.duration-vr),li=1-(Jn/yn.duration||0),xa=0,Ri=yn.tweens.length;xa<Ri;xa++)yn.tweens[xa].run(li);return jt.notifyWith(wt,[yn,li,Jn]),li<1&&Ri?Jn:(Ri||jt.notifyWith(wt,[yn,1,0]),jt.resolveWith(wt,[yn]),!1)},yn=jt.promise({elem:wt,props:ie.extend({},qt),opts:ie.extend(!0,{specialEasing:{},easing:ie.easing._default},Cn),originalProperties:qt,originalOptions:Cn,startTime:al||qi(),duration:Cn.duration,tweens:[],createTween:function(vr,Jn){var li=ie.Tween(wt,yn.opts,vr,Jn,yn.opts.specialEasing[vr]||yn.opts.easing);return yn.tweens.push(li),li},stop:function(vr){var Jn=0,li=vr?yn.tweens.length:0;if(Qe)return this;for(Qe=!0;Jn<li;Jn++)yn.tweens[Jn].run(1);return vr?(jt.notifyWith(wt,[yn,1,0]),jt.resolveWith(wt,[yn,vr])):jt.rejectWith(wt,[yn,vr]),this}}),In=yn.props;for(function(vr,Jn){var li,xa,Ri,fa,oo;for(li in vr)if(Ri=Jn[xa=ai(li)],fa=vr[li],Array.isArray(fa)&&(Ri=fa[1],fa=vr[li]=fa[0]),li!==xa&&(vr[xa]=fa,delete vr[li]),(oo=ie.cssHooks[xa])&&"expand"in oo)for(li in fa=oo.expand(fa),delete vr[xa],fa)li in vr||(vr[li]=fa[li],Jn[li]=Ri);else Jn[xa]=Ri}(In,yn.opts.specialEasing);yt<Rt;yt++)if(Pn=mo.prefilters[yt].call(yn,wt,In,yn.opts))return ne(Pn.stop)&&(ie._queueHooks(yn.elem,yn.opts.queue).stop=Pn.stop.bind(Pn)),Pn;return ie.map(In,no,yn),ne(yn.opts.start)&&yn.opts.start.call(wt,yn),yn.progress(yn.opts.progress).done(yn.opts.done,yn.opts.complete).fail(yn.opts.fail).always(yn.opts.always),ie.fx.timer(ie.extend(dn,{elem:wt,anim:yn,queue:yn.opts.queue})),yn}ie.Animation=ie.extend(mo,{tweeners:{"*":[function(wt,qt){var Cn=this.createTween(wt,qt);return oi(Cn.elem,wt,hr.exec(qt),Cn),Cn}]},tweener:function(wt,qt){ne(wt)?(qt=wt,wt=["*"]):wt=wt.match(Xn);for(var Cn,Pn=0,Qe=wt.length;Pn<Qe;Pn++)Cn=wt[Pn],mo.tweeners[Cn]=mo.tweeners[Cn]||[],mo.tweeners[Cn].unshift(qt)},prefilters:[function(wt,qt,Cn){var Pn,Qe,yt,Rt,jt,dn,yn,In,vr="width"in qt||"height"in qt,Jn=this,li={},xa=wt.style,Ri=wt.nodeType&&Pi(wt),fa=An.get(wt,"fxshow");for(Pn in Cn.queue||((Rt=ie._queueHooks(wt,"fx")).unqueued==null&&(Rt.unqueued=0,jt=Rt.empty.fire,Rt.empty.fire=function(){Rt.unqueued||jt()}),Rt.unqueued++,Jn.always(function(){Jn.always(function(){Rt.unqueued--,ie.queue(wt,"fx").length||Rt.empty.fire()})})),qt)if(Qe=qt[Pn],Ur.test(Qe)){if(delete qt[Pn],yt=yt||Qe==="toggle",Qe===(Ri?"hide":"show")){if(Qe!=="show"||!fa||fa[Pn]===void 0)continue;Ri=!0}li[Pn]=fa&&fa[Pn]||ie.style(wt,Pn)}if((dn=!ie.isEmptyObject(qt))||!ie.isEmptyObject(li))for(Pn in vr&&wt.nodeType===1&&(Cn.overflow=[xa.overflow,xa.overflowX,xa.overflowY],(yn=fa&&fa.display)==null&&(yn=An.get(wt,"display")),(In=ie.css(wt,"display"))==="none"&&(yn?In=yn:(ki([wt],!0),yn=wt.style.display||yn,In=ie.css(wt,"display"),ki([wt]))),(In==="inline"||In==="inline-block"&&yn!=null)&&ie.css(wt,"float")==="none"&&(dn||(Jn.done(function(){xa.display=yn}),yn==null&&(In=xa.display,yn=In==="none"?"":In)),xa.display="inline-block")),Cn.overflow&&(xa.overflow="hidden",Jn.always(function(){xa.overflow=Cn.overflow[0],xa.overflowX=Cn.overflow[1],xa.overflowY=Cn.overflow[2]})),dn=!1,li)dn||(fa?"hidden"in fa&&(Ri=fa.hidden):fa=An.access(wt,"fxshow",{display:yn}),yt&&(fa.hidden=!Ri),Ri&&ki([wt],!0),Jn.done(function(){for(Pn in Ri||ki([wt]),An.remove(wt,"fxshow"),li)ie.style(wt,Pn,li[Pn])})),dn=no(Ri?fa[Pn]:0,Pn,Jn),Pn in fa||(fa[Pn]=dn.start,Ri&&(dn.end=dn.start,dn.start=0))}],prefilter:function(wt,qt){qt?mo.prefilters.unshift(wt):mo.prefilters.push(wt)}}),ie.speed=function(wt,qt,Cn){var Pn=wt&&typeof wt=="object"?ie.extend({},wt):{complete:Cn||!Cn&&qt||ne(wt)&&wt,duration:wt,easing:Cn&&qt||qt&&!ne(qt)&&qt};return ie.fx.off?Pn.duration=0:typeof Pn.duration!="number"&&(Pn.duration in ie.fx.speeds?Pn.duration=ie.fx.speeds[Pn.duration]:Pn.duration=ie.fx.speeds._default),Pn.queue!=null&&Pn.queue!==!0||(Pn.queue="fx"),Pn.old=Pn.complete,Pn.complete=function(){ne(Pn.old)&&Pn.old.call(this),Pn.queue&&ie.dequeue(this,Pn.queue)},Pn},ie.fn.extend({fadeTo:function(wt,qt,Cn,Pn){return this.filter(Pi).css("opacity",0).show().end().animate({opacity:qt},wt,Cn,Pn)},animate:function(wt,qt,Cn,Pn){var Qe=ie.isEmptyObject(wt),yt=ie.speed(qt,Cn,Pn),Rt=function(){var jt=mo(this,ie.extend({},wt),yt);(Qe||An.get(this,"finish"))&&jt.stop(!0)};return Rt.finish=Rt,Qe||yt.queue===!1?this.each(Rt):this.queue(yt.queue,Rt)},stop:function(wt,qt,Cn){var Pn=function(Qe){var yt=Qe.stop;delete Qe.stop,yt(Cn)};return typeof wt!="string"&&(Cn=qt,qt=wt,wt=void 0),qt&&this.queue(wt||"fx",[]),this.each(function(){var Qe=!0,yt=wt!=null&&wt+"queueHooks",Rt=ie.timers,jt=An.get(this);if(yt)jt[yt]&&jt[yt].stop&&Pn(jt[yt]);else for(yt in jt)jt[yt]&&jt[yt].stop&&Gn.test(yt)&&Pn(jt[yt]);for(yt=Rt.length;yt--;)Rt[yt].elem!==this||wt!=null&&Rt[yt].queue!==wt||(Rt[yt].anim.stop(Cn),Qe=!1,Rt.splice(yt,1));!Qe&&Cn||ie.dequeue(this,wt)})},finish:function(wt){return wt!==!1&&(wt=wt||"fx"),this.each(function(){var qt,Cn=An.get(this),Pn=Cn[wt+"queue"],Qe=Cn[wt+"queueHooks"],yt=ie.timers,Rt=Pn?Pn.length:0;for(Cn.finish=!0,ie.queue(this,wt,[]),Qe&&Qe.stop&&Qe.stop.call(this,!0),qt=yt.length;qt--;)yt[qt].elem===this&&yt[qt].queue===wt&&(yt[qt].anim.stop(!0),yt.splice(qt,1));for(qt=0;qt<Rt;qt++)Pn[qt]&&Pn[qt].finish&&Pn[qt].finish.call(this);delete Cn.finish})}}),ie.each(["toggle","show","hide"],function(wt,qt){var Cn=ie.fn[qt];ie.fn[qt]=function(Pn,Qe,yt){return Pn==null||typeof Pn=="boolean"?Cn.apply(this,arguments):this.animate(ga(qt,!0),Pn,Qe,yt)}}),ie.each({slideDown:ga("show"),slideUp:ga("hide"),slideToggle:ga("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(wt,qt){ie.fn[wt]=function(Cn,Pn,Qe){return this.animate(qt,Cn,Pn,Qe)}}),ie.timers=[],ie.fx.tick=function(){var wt,qt=0,Cn=ie.timers;for(al=Date.now();qt<Cn.length;qt++)(wt=Cn[qt])()||Cn[qt]!==wt||Cn.splice(qt--,1);Cn.length||ie.fx.stop(),al=void 0},ie.fx.timer=function(wt){ie.timers.push(wt),ie.fx.start()},ie.fx.interval=13,ie.fx.start=function(){Mn||(Mn=!0,Qr())},ie.fx.stop=function(){Mn=null},ie.fx.speeds={slow:600,fast:200,_default:400},ie.fn.delay=function(wt,qt){return wt=ie.fx&&ie.fx.speeds[wt]||wt,qt=qt||"fx",this.queue(qt,function(Cn,Pn){var Qe=n.setTimeout(Cn,wt);Pn.stop=function(){n.clearTimeout(Qe)}})},function(){var wt=De.createElement("input"),qt=De.createElement("select").appendChild(De.createElement("option"));wt.type="checkbox",ve.checkOn=wt.value!=="",ve.optSelected=qt.selected,(wt=De.createElement("input")).value="t",wt.type="radio",ve.radioValue=wt.value==="t"}();var Go,Uo=ie.expr.attrHandle;ie.fn.extend({attr:function(wt,qt){return qn(this,ie.attr,wt,qt,arguments.length>1)},removeAttr:function(wt){return this.each(function(){ie.removeAttr(this,wt)})}}),ie.extend({attr:function(wt,qt,Cn){var Pn,Qe,yt=wt.nodeType;if(yt!==3&&yt!==8&&yt!==2)return wt.getAttribute===void 0?ie.prop(wt,qt,Cn):(yt===1&&ie.isXMLDoc(wt)||(Qe=ie.attrHooks[qt.toLowerCase()]||(ie.expr.match.bool.test(qt)?Go:void 0)),Cn!==void 0?Cn===null?void ie.removeAttr(wt,qt):Qe&&"set"in Qe&&(Pn=Qe.set(wt,Cn,qt))!==void 0?Pn:(wt.setAttribute(qt,Cn+""),Cn):Qe&&"get"in Qe&&(Pn=Qe.get(wt,qt))!==null?Pn:(Pn=ie.find.attr(wt,qt))==null?void 0:Pn)},attrHooks:{type:{set:function(wt,qt){if(!ve.radioValue&&qt==="radio"&&pt(wt,"input")){var Cn=wt.value;return wt.setAttribute("type",qt),Cn&&(wt.value=Cn),qt}}}},removeAttr:function(wt,qt){var Cn,Pn=0,Qe=qt&&qt.match(Xn);if(Qe&&wt.nodeType===1)for(;Cn=Qe[Pn++];)wt.removeAttribute(Cn)}}),Go={set:function(wt,qt,Cn){return qt===!1?ie.removeAttr(wt,Cn):wt.setAttribute(Cn,Cn),Cn}},ie.each(ie.expr.match.bool.source.match(/\w+/g),function(wt,qt){var Cn=Uo[qt]||ie.find.attr;Uo[qt]=function(Pn,Qe,yt){var Rt,jt,dn=Qe.toLowerCase();return yt||(jt=Uo[dn],Uo[dn]=Rt,Rt=Cn(Pn,Qe,yt)!=null?dn:null,Uo[dn]=jt),Rt}});var Ns=/^(?:input|select|textarea|button)$/i,jl=/^(?:a|area)$/i;function Bl(wt){return(wt.match(Xn)||[]).join(" ")}function Jl(wt){return wt.getAttribute&&wt.getAttribute("class")||""}function mu(wt){return Array.isArray(wt)?wt:typeof wt=="string"&&wt.match(Xn)||[]}ie.fn.extend({prop:function(wt,qt){return qn(this,ie.prop,wt,qt,arguments.length>1)},removeProp:function(wt){return this.each(function(){delete this[ie.propFix[wt]||wt]})}}),ie.extend({prop:function(wt,qt,Cn){var Pn,Qe,yt=wt.nodeType;if(yt!==3&&yt!==8&&yt!==2)return yt===1&&ie.isXMLDoc(wt)||(qt=ie.propFix[qt]||qt,Qe=ie.propHooks[qt]),Cn!==void 0?Qe&&"set"in Qe&&(Pn=Qe.set(wt,Cn,qt))!==void 0?Pn:wt[qt]=Cn:Qe&&"get"in Qe&&(Pn=Qe.get(wt,qt))!==null?Pn:wt[qt]},propHooks:{tabIndex:{get:function(wt){var qt=ie.find.attr(wt,"tabindex");return qt?parseInt(qt,10):Ns.test(wt.nodeName)||jl.test(wt.nodeName)&&wt.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),ve.optSelected||(ie.propHooks.selected={get:function(wt){var qt=wt.parentNode;return qt&&qt.parentNode&&qt.parentNode.selectedIndex,null},set:function(wt){var qt=wt.parentNode;qt&&(qt.selectedIndex,qt.parentNode&&qt.parentNode.selectedIndex)}}),ie.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){ie.propFix[this.toLowerCase()]=this}),ie.fn.extend({addClass:function(wt){var qt,Cn,Pn,Qe,yt,Rt;return ne(wt)?this.each(function(jt){ie(this).addClass(wt.call(this,jt,Jl(this)))}):(qt=mu(wt)).length?this.each(function(){if(Pn=Jl(this),Cn=this.nodeType===1&&" "+Bl(Pn)+" "){for(yt=0;yt<qt.length;yt++)Qe=qt[yt],Cn.indexOf(" "+Qe+" ")<0&&(Cn+=Qe+" ");Rt=Bl(Cn),Pn!==Rt&&this.setAttribute("class",Rt)}}):this},removeClass:function(wt){var qt,Cn,Pn,Qe,yt,Rt;return ne(wt)?this.each(function(jt){ie(this).removeClass(wt.call(this,jt,Jl(this)))}):arguments.length?(qt=mu(wt)).length?this.each(function(){if(Pn=Jl(this),Cn=this.nodeType===1&&" "+Bl(Pn)+" "){for(yt=0;yt<qt.length;yt++)for(Qe=qt[yt];Cn.indexOf(" "+Qe+" ")>-1;)Cn=Cn.replace(" "+Qe+" "," ");Rt=Bl(Cn),Pn!==Rt&&this.setAttribute("class",Rt)}}):this:this.attr("class","")},toggleClass:function(wt,qt){var Cn,Pn,Qe,yt,Rt=typeof wt,jt=Rt==="string"||Array.isArray(wt);return ne(wt)?this.each(function(dn){ie(this).toggleClass(wt.call(this,dn,Jl(this),qt),qt)}):typeof qt=="boolean"&&jt?qt?this.addClass(wt):this.removeClass(wt):(Cn=mu(wt),this.each(function(){if(jt)for(yt=ie(this),Qe=0;Qe<Cn.length;Qe++)Pn=Cn[Qe],yt.hasClass(Pn)?yt.removeClass(Pn):yt.addClass(Pn);else wt!==void 0&&Rt!=="boolean"||((Pn=Jl(this))&&An.set(this,"__className__",Pn),this.setAttribute&&this.setAttribute("class",Pn||wt===!1?"":An.get(this,"__className__")||""))}))},hasClass:function(wt){var qt,Cn,Pn=0;for(qt=" "+wt+" ";Cn=this[Pn++];)if(Cn.nodeType===1&&(" "+Bl(Jl(Cn))+" ").indexOf(qt)>-1)return!0;return!1}});var Ol=/\r/g;ie.fn.extend({val:function(wt){var qt,Cn,Pn,Qe=this[0];return arguments.length?(Pn=ne(wt),this.each(function(yt){var Rt;this.nodeType===1&&((Rt=Pn?wt.call(this,yt,ie(this).val()):wt)==null?Rt="":typeof Rt=="number"?Rt+="":Array.isArray(Rt)&&(Rt=ie.map(Rt,function(jt){return jt==null?"":jt+""})),(qt=ie.valHooks[this.type]||ie.valHooks[this.nodeName.toLowerCase()])&&"set"in qt&&qt.set(this,Rt,"value")!==void 0||(this.value=Rt))})):Qe?(qt=ie.valHooks[Qe.type]||ie.valHooks[Qe.nodeName.toLowerCase()])&&"get"in qt&&(Cn=qt.get(Qe,"value"))!==void 0?Cn:typeof(Cn=Qe.value)=="string"?Cn.replace(Ol,""):Cn??"":void 0}}),ie.extend({valHooks:{option:{get:function(wt){var qt=ie.find.attr(wt,"value");return qt??Bl(ie.text(wt))}},select:{get:function(wt){var qt,Cn,Pn,Qe=wt.options,yt=wt.selectedIndex,Rt=wt.type==="select-one",jt=Rt?null:[],dn=Rt?yt+1:Qe.length;for(Pn=yt<0?dn:Rt?yt:0;Pn<dn;Pn++)if(((Cn=Qe[Pn]).selected||Pn===yt)&&!Cn.disabled&&(!Cn.parentNode.disabled||!pt(Cn.parentNode,"optgroup"))){if(qt=ie(Cn).val(),Rt)return qt;jt.push(qt)}return jt},set:function(wt,qt){for(var Cn,Pn,Qe=wt.options,yt=ie.makeArray(qt),Rt=Qe.length;Rt--;)((Pn=Qe[Rt]).selected=ie.inArray(ie.valHooks.option.get(Pn),yt)>-1)&&(Cn=!0);return Cn||(wt.selectedIndex=-1),yt}}}}),ie.each(["radio","checkbox"],function(){ie.valHooks[this]={set:function(wt,qt){if(Array.isArray(qt))return wt.checked=ie.inArray(ie(wt).val(),qt)>-1}},ve.checkOn||(ie.valHooks[this].get=function(wt){return wt.getAttribute("value")===null?"on":wt.value})});var bu=n.location,Bu={guid:Date.now()},hl=/\?/;ie.parseXML=function(wt){var qt,Cn;if(!wt||typeof wt!="string")return null;try{qt=new n.DOMParser().parseFromString(wt,"text/xml")}catch{}return Cn=qt&&qt.getElementsByTagName("parsererror")[0],qt&&!Cn||ie.error("Invalid XML: "+(Cn?ie.map(Cn.childNodes,function(Pn){return Pn.textContent}).join(`
- `):wt)),qt};var vu=/^(?:focusinfocus|focusoutblur)$/,Ku=function(wt){wt.stopPropagation()};ie.extend(ie.event,{trigger:function(wt,qt,Cn,Pn){var Qe,yt,Rt,jt,dn,yn,In,vr,Jn=[Cn||De],li=q.call(wt,"type")?wt.type:wt,xa=q.call(wt,"namespace")?wt.namespace.split("."):[];if(yt=vr=Rt=Cn=Cn||De,Cn.nodeType!==3&&Cn.nodeType!==8&&!vu.test(li+ie.event.triggered)&&(li.indexOf(".")>-1&&(li=(xa=li.split(".")).shift(),xa.sort()),dn=li.indexOf(":")<0&&"on"+li,(wt=wt[ie.expando]?wt:new ie.Event(li,typeof wt=="object"&&wt)).isTrigger=Pn?2:3,wt.namespace=xa.join("."),wt.rnamespace=wt.namespace?new RegExp("(^|\\.)"+xa.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,wt.result=void 0,wt.target||(wt.target=Cn),qt=qt==null?[wt]:ie.makeArray(qt,[wt]),In=ie.event.special[li]||{},Pn||!In.trigger||In.trigger.apply(Cn,qt)!==!1)){if(!Pn&&!In.noBubble&&!Ue(Cn)){for(jt=In.delegateType||li,vu.test(jt+li)||(yt=yt.parentNode);yt;yt=yt.parentNode)Jn.push(yt),Rt=yt;Rt===(Cn.ownerDocument||De)&&Jn.push(Rt.defaultView||Rt.parentWindow||n)}for(Qe=0;(yt=Jn[Qe++])&&!wt.isPropagationStopped();)vr=yt,wt.type=Qe>1?jt:In.bindType||li,(yn=(An.get(yt,"events")||Object.create(null))[wt.type]&&An.get(yt,"handle"))&&yn.apply(yt,qt),(yn=dn&&yt[dn])&&yn.apply&&Ia(yt)&&(wt.result=yn.apply(yt,qt),wt.result===!1&&wt.preventDefault());return wt.type=li,Pn||wt.isDefaultPrevented()||In._default&&In._default.apply(Jn.pop(),qt)!==!1||!Ia(Cn)||dn&&ne(Cn[li])&&!Ue(Cn)&&((Rt=Cn[dn])&&(Cn[dn]=null),ie.event.triggered=li,wt.isPropagationStopped()&&vr.addEventListener(li,Ku),Cn[li](),wt.isPropagationStopped()&&vr.removeEventListener(li,Ku),ie.event.triggered=void 0,Rt&&(Cn[dn]=Rt)),wt.result}},simulate:function(wt,qt,Cn){var Pn=ie.extend(new ie.Event,Cn,{type:wt,isSimulated:!0});ie.event.trigger(Pn,null,qt)}}),ie.fn.extend({trigger:function(wt,qt){return this.each(function(){ie.event.trigger(wt,qt,this)})},triggerHandler:function(wt,qt){var Cn=this[0];if(Cn)return ie.event.trigger(wt,qt,Cn,!0)}});var Ul=/\[\]$/,ad=/\r?\n/g,jc=/^(?:submit|button|image|reset|file)$/i,js=/^(?:input|select|textarea|keygen)/i;function co(wt,qt,Cn,Pn){var Qe;if(Array.isArray(qt))ie.each(qt,function(yt,Rt){Cn||Ul.test(wt)?Pn(wt,Rt):co(wt+"["+(typeof Rt=="object"&&Rt!=null?yt:"")+"]",Rt,Cn,Pn)});else if(Cn||Ae(qt)!=="object")Pn(wt,qt);else for(Qe in qt)co(wt+"["+Qe+"]",qt[Qe],Cn,Pn)}ie.param=function(wt,qt){var Cn,Pn=[],Qe=function(yt,Rt){var jt=ne(Rt)?Rt():Rt;Pn[Pn.length]=encodeURIComponent(yt)+"="+encodeURIComponent(jt??"")};if(wt==null)return"";if(Array.isArray(wt)||wt.jquery&&!ie.isPlainObject(wt))ie.each(wt,function(){Qe(this.name,this.value)});else for(Cn in wt)co(Cn,wt[Cn],qt,Qe);return Pn.join("&")},ie.fn.extend({serialize:function(){return ie.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var wt=ie.prop(this,"elements");return wt?ie.makeArray(wt):this}).filter(function(){var wt=this.type;return this.name&&!ie(this).is(":disabled")&&js.test(this.nodeName)&&!jc.test(wt)&&(this.checked||!yo.test(wt))}).map(function(wt,qt){var Cn=ie(this).val();return Cn==null?null:Array.isArray(Cn)?ie.map(Cn,function(Pn){return{name:qt.name,value:Pn.replace(ad,`\r
- `)}}):{name:qt.name,value:Cn.replace(ad,`\r
- `)}}).get()}});var Vl=/%20/g,Gc=/#.*$/,yd=/([?&])_=[^&]*/,Ql=/^(.*?):[ \t]*([^\r\n]*)$/gm,Ll=/^(?:GET|HEAD)$/,Au=/^\/\//,jd={},Wu={},ud="*/".concat("*"),Xc=De.createElement("a");function yi(wt){return function(qt,Cn){typeof qt!="string"&&(Cn=qt,qt="*");var Pn,Qe=0,yt=qt.toLowerCase().match(Xn)||[];if(ne(Cn))for(;Pn=yt[Qe++];)Pn[0]==="+"?(Pn=Pn.slice(1)||"*",(wt[Pn]=wt[Pn]||[]).unshift(Cn)):(wt[Pn]=wt[Pn]||[]).push(Cn)}}function mc(wt,qt,Cn,Pn){var Qe={},yt=wt===Wu;function Rt(jt){var dn;return Qe[jt]=!0,ie.each(wt[jt]||[],function(yn,In){var vr=In(qt,Cn,Pn);return typeof vr!="string"||yt||Qe[vr]?yt?!(dn=vr):void 0:(qt.dataTypes.unshift(vr),Rt(vr),!1)}),dn}return Rt(qt.dataTypes[0])||!Qe["*"]&&Rt("*")}function Su(wt,qt){var Cn,Pn,Qe=ie.ajaxSettings.flatOptions||{};for(Cn in qt)qt[Cn]!==void 0&&((Qe[Cn]?wt:Pn||(Pn={}))[Cn]=qt[Cn]);return Pn&&ie.extend(!0,wt,Pn),wt}Xc.href=bu.href,ie.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:bu.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(bu.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":ud,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":ie.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(wt,qt){return qt?Su(Su(wt,ie.ajaxSettings),qt):Su(ie.ajaxSettings,wt)},ajaxPrefilter:yi(jd),ajaxTransport:yi(Wu),ajax:function(wt,qt){typeof wt=="object"&&(qt=wt,wt=void 0),qt=qt||{};var Cn,Pn,Qe,yt,Rt,jt,dn,yn,In,vr,Jn=ie.ajaxSetup({},qt),li=Jn.context||Jn,xa=Jn.context&&(li.nodeType||li.jquery)?ie(li):ie.event,Ri=ie.Deferred(),fa=ie.Callbacks("once memory"),oo=Jn.statusCode||{},ts={},bl={},nl="canceled",Fs={readyState:0,getResponseHeader:function(Gs){var As;if(dn){if(!yt)for(yt={};As=Ql.exec(Qe);)yt[As[1].toLowerCase()+" "]=(yt[As[1].toLowerCase()+" "]||[]).concat(As[2]);As=yt[Gs.toLowerCase()+" "]}return As==null?null:As.join(", ")},getAllResponseHeaders:function(){return dn?Qe:null},setRequestHeader:function(Gs,As){return dn==null&&(Gs=bl[Gs.toLowerCase()]=bl[Gs.toLowerCase()]||Gs,ts[Gs]=As),this},overrideMimeType:function(Gs){return dn==null&&(Jn.mimeType=Gs),this},statusCode:function(Gs){var As;if(Gs)if(dn)Fs.always(Gs[Fs.status]);else for(As in Gs)oo[As]=[oo[As],Gs[As]];return this},abort:function(Gs){var As=Gs||nl;return Cn&&Cn.abort(As),eu(0,As),this}};if(Ri.promise(Fs),Jn.url=((wt||Jn.url||bu.href)+"").replace(Au,bu.protocol+"//"),Jn.type=qt.method||qt.type||Jn.method||Jn.type,Jn.dataTypes=(Jn.dataType||"*").toLowerCase().match(Xn)||[""],Jn.crossDomain==null){jt=De.createElement("a");try{jt.href=Jn.url,jt.href=jt.href,Jn.crossDomain=Xc.protocol+"//"+Xc.host!=jt.protocol+"//"+jt.host}catch{Jn.crossDomain=!0}}if(Jn.data&&Jn.processData&&typeof Jn.data!="string"&&(Jn.data=ie.param(Jn.data,Jn.traditional)),mc(jd,Jn,qt,Fs),dn)return Fs;for(In in(yn=ie.event&&Jn.global)&&ie.active++==0&&ie.event.trigger("ajaxStart"),Jn.type=Jn.type.toUpperCase(),Jn.hasContent=!Ll.test(Jn.type),Pn=Jn.url.replace(Gc,""),Jn.hasContent?Jn.data&&Jn.processData&&(Jn.contentType||"").indexOf("application/x-www-form-urlencoded")===0&&(Jn.data=Jn.data.replace(Vl,"+")):(vr=Jn.url.slice(Pn.length),Jn.data&&(Jn.processData||typeof Jn.data=="string")&&(Pn+=(hl.test(Pn)?"&":"?")+Jn.data,delete Jn.data),Jn.cache===!1&&(Pn=Pn.replace(yd,"$1"),vr=(hl.test(Pn)?"&":"?")+"_="+Bu.guid+++vr),Jn.url=Pn+vr),Jn.ifModified&&(ie.lastModified[Pn]&&Fs.setRequestHeader("If-Modified-Since",ie.lastModified[Pn]),ie.etag[Pn]&&Fs.setRequestHeader("If-None-Match",ie.etag[Pn])),(Jn.data&&Jn.hasContent&&Jn.contentType!==!1||qt.contentType)&&Fs.setRequestHeader("Content-Type",Jn.contentType),Fs.setRequestHeader("Accept",Jn.dataTypes[0]&&Jn.accepts[Jn.dataTypes[0]]?Jn.accepts[Jn.dataTypes[0]]+(Jn.dataTypes[0]!=="*"?", "+ud+"; q=0.01":""):Jn.accepts["*"]),Jn.headers)Fs.setRequestHeader(In,Jn.headers[In]);if(Jn.beforeSend&&(Jn.beforeSend.call(li,Fs,Jn)===!1||dn))return Fs.abort();if(nl="abort",fa.add(Jn.complete),Fs.done(Jn.success),Fs.fail(Jn.error),Cn=mc(Wu,Jn,qt,Fs)){if(Fs.readyState=1,yn&&xa.trigger("ajaxSend",[Fs,Jn]),dn)return Fs;Jn.async&&Jn.timeout>0&&(Rt=n.setTimeout(function(){Fs.abort("timeout")},Jn.timeout));try{dn=!1,Cn.send(ts,eu)}catch(Gs){if(dn)throw Gs;eu(-1,Gs)}}else eu(-1,"No Transport");function eu(Gs,As,yl,Lc){var vl,du,ac,Xu,Ju,Vu=As;dn||(dn=!0,Rt&&n.clearTimeout(Rt),Cn=void 0,Qe=Lc||"",Fs.readyState=Gs>0?4:0,vl=Gs>=200&&Gs<300||Gs===304,yl&&(Xu=function(Nl,$l,hu){for(var Qu,Gu,Bs,su,ku=Nl.contents,Hl=Nl.dataTypes;Hl[0]==="*";)Hl.shift(),Qu===void 0&&(Qu=Nl.mimeType||$l.getResponseHeader("Content-Type"));if(Qu){for(Gu in ku)if(ku[Gu]&&ku[Gu].test(Qu)){Hl.unshift(Gu);break}}if(Hl[0]in hu)Bs=Hl[0];else{for(Gu in hu){if(!Hl[0]||Nl.converters[Gu+" "+Hl[0]]){Bs=Gu;break}su||(su=Gu)}Bs=Bs||su}if(Bs)return Bs!==Hl[0]&&Hl.unshift(Bs),hu[Bs]}(Jn,Fs,yl)),!vl&&ie.inArray("script",Jn.dataTypes)>-1&&ie.inArray("json",Jn.dataTypes)<0&&(Jn.converters["text script"]=function(){}),Xu=function(Nl,$l,hu,Qu){var Gu,Bs,su,ku,Hl,Uc={},Wl=Nl.dataTypes.slice();if(Wl[1])for(su in Nl.converters)Uc[su.toLowerCase()]=Nl.converters[su];for(Bs=Wl.shift();Bs;)if(Nl.responseFields[Bs]&&(hu[Nl.responseFields[Bs]]=$l),!Hl&&Qu&&Nl.dataFilter&&($l=Nl.dataFilter($l,Nl.dataType)),Hl=Bs,Bs=Wl.shift()){if(Bs==="*")Bs=Hl;else if(Hl!=="*"&&Hl!==Bs){if(!(su=Uc[Hl+" "+Bs]||Uc["* "+Bs])){for(Gu in Uc)if((ku=Gu.split(" "))[1]===Bs&&(su=Uc[Hl+" "+ku[0]]||Uc["* "+ku[0]])){su===!0?su=Uc[Gu]:Uc[Gu]!==!0&&(Bs=ku[0],Wl.unshift(ku[1]));break}}if(su!==!0)if(su&&Nl.throws)$l=su($l);else try{$l=su($l)}catch(cd){return{state:"parsererror",error:su?cd:"No conversion from "+Hl+" to "+Bs}}}}return{state:"success",data:$l}}(Jn,Xu,Fs,vl),vl?(Jn.ifModified&&((Ju=Fs.getResponseHeader("Last-Modified"))&&(ie.lastModified[Pn]=Ju),(Ju=Fs.getResponseHeader("etag"))&&(ie.etag[Pn]=Ju)),Gs===204||Jn.type==="HEAD"?Vu="nocontent":Gs===304?Vu="notmodified":(Vu=Xu.state,du=Xu.data,vl=!(ac=Xu.error))):(ac=Vu,!Gs&&Vu||(Vu="error",Gs<0&&(Gs=0))),Fs.status=Gs,Fs.statusText=(As||Vu)+"",vl?Ri.resolveWith(li,[du,Vu,Fs]):Ri.rejectWith(li,[Fs,Vu,ac]),Fs.statusCode(oo),oo=void 0,yn&&xa.trigger(vl?"ajaxSuccess":"ajaxError",[Fs,Jn,vl?du:ac]),fa.fireWith(li,[Fs,Vu]),yn&&(xa.trigger("ajaxComplete",[Fs,Jn]),--ie.active||ie.event.trigger("ajaxStop")))}return Fs},getJSON:function(wt,qt,Cn){return ie.get(wt,qt,Cn,"json")},getScript:function(wt,qt){return ie.get(wt,void 0,qt,"script")}}),ie.each(["get","post"],function(wt,qt){ie[qt]=function(Cn,Pn,Qe,yt){return ne(Pn)&&(yt=yt||Qe,Qe=Pn,Pn=void 0),ie.ajax(ie.extend({url:Cn,type:qt,dataType:yt,data:Pn,success:Qe},ie.isPlainObject(Cn)&&Cn))}}),ie.ajaxPrefilter(function(wt){var qt;for(qt in wt.headers)qt.toLowerCase()==="content-type"&&(wt.contentType=wt.headers[qt]||"")}),ie._evalUrl=function(wt,qt,Cn){return ie.ajax({url:wt,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(Pn){ie.globalEval(Pn,qt,Cn)}})},ie.fn.extend({wrapAll:function(wt){var qt;return this[0]&&(ne(wt)&&(wt=wt.call(this[0])),qt=ie(wt,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&qt.insertBefore(this[0]),qt.map(function(){for(var Cn=this;Cn.firstElementChild;)Cn=Cn.firstElementChild;return Cn}).append(this)),this},wrapInner:function(wt){return ne(wt)?this.each(function(qt){ie(this).wrapInner(wt.call(this,qt))}):this.each(function(){var qt=ie(this),Cn=qt.contents();Cn.length?Cn.wrapAll(wt):qt.append(wt)})},wrap:function(wt){var qt=ne(wt);return this.each(function(Cn){ie(this).wrapAll(qt?wt.call(this,Cn):wt)})},unwrap:function(wt){return this.parent(wt).not("body").each(function(){ie(this).replaceWith(this.childNodes)}),this}}),ie.expr.pseudos.hidden=function(wt){return!ie.expr.pseudos.visible(wt)},ie.expr.pseudos.visible=function(wt){return!!(wt.offsetWidth||wt.offsetHeight||wt.getClientRects().length)},ie.ajaxSettings.xhr=function(){try{return new n.XMLHttpRequest}catch{}};var Yh={0:200,1223:204},ka=ie.ajaxSettings.xhr();ve.cors=!!ka&&"withCredentials"in ka,ve.ajax=ka=!!ka,ie.ajaxTransport(function(wt){var qt,Cn;if(ve.cors||ka&&!wt.crossDomain)return{send:function(Pn,Qe){var yt,Rt=wt.xhr();if(Rt.open(wt.type,wt.url,wt.async,wt.username,wt.password),wt.xhrFields)for(yt in wt.xhrFields)Rt[yt]=wt.xhrFields[yt];for(yt in wt.mimeType&&Rt.overrideMimeType&&Rt.overrideMimeType(wt.mimeType),wt.crossDomain||Pn["X-Requested-With"]||(Pn["X-Requested-With"]="XMLHttpRequest"),Pn)Rt.setRequestHeader(yt,Pn[yt]);qt=function(jt){return function(){qt&&(qt=Cn=Rt.onload=Rt.onerror=Rt.onabort=Rt.ontimeout=Rt.onreadystatechange=null,jt==="abort"?Rt.abort():jt==="error"?typeof Rt.status!="number"?Qe(0,"error"):Qe(Rt.status,Rt.statusText):Qe(Yh[Rt.status]||Rt.status,Rt.statusText,(Rt.responseType||"text")!=="text"||typeof Rt.responseText!="string"?{binary:Rt.response}:{text:Rt.responseText},Rt.getAllResponseHeaders()))}},Rt.onload=qt(),Cn=Rt.onerror=Rt.ontimeout=qt("error"),Rt.onabort!==void 0?Rt.onabort=Cn:Rt.onreadystatechange=function(){Rt.readyState===4&&n.setTimeout(function(){qt&&Cn()})},qt=qt("abort");try{Rt.send(wt.hasContent&&wt.data||null)}catch(jt){if(qt)throw jt}},abort:function(){qt&&qt()}}}),ie.ajaxPrefilter(function(wt){wt.crossDomain&&(wt.contents.script=!1)}),ie.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(wt){return ie.globalEval(wt),wt}}}),ie.ajaxPrefilter("script",function(wt){wt.cache===void 0&&(wt.cache=!1),wt.crossDomain&&(wt.type="GET")}),ie.ajaxTransport("script",function(wt){var qt,Cn;if(wt.crossDomain||wt.scriptAttrs)return{send:function(Pn,Qe){qt=ie("<script>").attr(wt.scriptAttrs||{}).prop({charset:wt.scriptCharset,src:wt.url}).on("load error",Cn=function(yt){qt.remove(),Cn=null,yt&&Qe(yt.type==="error"?404:200,yt.type)}),De.head.appendChild(qt[0])},abort:function(){Cn&&Cn()}}});var pl,Il=[],Ss=/(=)\?(?=&|$)|\?\?/;ie.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var wt=Il.pop()||ie.expando+"_"+Bu.guid++;return this[wt]=!0,wt}}),ie.ajaxPrefilter("json jsonp",function(wt,qt,Cn){var Pn,Qe,yt,Rt=wt.jsonp!==!1&&(Ss.test(wt.url)?"url":typeof wt.data=="string"&&(wt.contentType||"").indexOf("application/x-www-form-urlencoded")===0&&Ss.test(wt.data)&&"data");if(Rt||wt.dataTypes[0]==="jsonp")return Pn=wt.jsonpCallback=ne(wt.jsonpCallback)?wt.jsonpCallback():wt.jsonpCallback,Rt?wt[Rt]=wt[Rt].replace(Ss,"$1"+Pn):wt.jsonp!==!1&&(wt.url+=(hl.test(wt.url)?"&":"?")+wt.jsonp+"="+Pn),wt.converters["script json"]=function(){return yt||ie.error(Pn+" was not called"),yt[0]},wt.dataTypes[0]="json",Qe=n[Pn],n[Pn]=function(){yt=arguments},Cn.always(function(){Qe===void 0?ie(n).removeProp(Pn):n[Pn]=Qe,wt[Pn]&&(wt.jsonpCallback=qt.jsonpCallback,Il.push(Pn)),yt&&ne(Qe)&&Qe(yt[0]),yt=Qe=void 0}),"script"}),ve.createHTMLDocument=((pl=De.implementation.createHTMLDocument("").body).innerHTML="<form></form><form></form>",pl.childNodes.length===2),ie.parseHTML=function(wt,qt,Cn){return typeof wt!="string"?[]:(typeof qt=="boolean"&&(Cn=qt,qt=!1),qt||(ve.createHTMLDocument?((Pn=(qt=De.implementation.createHTMLDocument("")).createElement("base")).href=De.location.href,qt.head.appendChild(Pn)):qt=De),yt=!Cn&&[],(Qe=wn.exec(wt))?[qt.createElement(Qe[1])]:(Qe=zn([wt],qt,yt),yt&&yt.length&&ie(yt).remove(),ie.merge([],Qe.childNodes)));var Pn,Qe,yt},ie.fn.load=function(wt,qt,Cn){var Pn,Qe,yt,Rt=this,jt=wt.indexOf(" ");return jt>-1&&(Pn=Bl(wt.slice(jt)),wt=wt.slice(0,jt)),ne(qt)?(Cn=qt,qt=void 0):qt&&typeof qt=="object"&&(Qe="POST"),Rt.length>0&&ie.ajax({url:wt,type:Qe||"GET",dataType:"html",data:qt}).done(function(dn){yt=arguments,Rt.html(Pn?ie("<div>").append(ie.parseHTML(dn)).find(Pn):dn)}).always(Cn&&function(dn,yn){Rt.each(function(){Cn.apply(this,yt||[dn.responseText,yn,dn])})}),this},ie.expr.pseudos.animated=function(wt){return ie.grep(ie.timers,function(qt){return wt===qt.elem}).length},ie.offset={setOffset:function(wt,qt,Cn){var Pn,Qe,yt,Rt,jt,dn,yn=ie.css(wt,"position"),In=ie(wt),vr={};yn==="static"&&(wt.style.position="relative"),jt=In.offset(),yt=ie.css(wt,"top"),dn=ie.css(wt,"left"),(yn==="absolute"||yn==="fixed")&&(yt+dn).indexOf("auto")>-1?(Rt=(Pn=In.position()).top,Qe=Pn.left):(Rt=parseFloat(yt)||0,Qe=parseFloat(dn)||0),ne(qt)&&(qt=qt.call(wt,Cn,ie.extend({},jt))),qt.top!=null&&(vr.top=qt.top-jt.top+Rt),qt.left!=null&&(vr.left=qt.left-jt.left+Qe),"using"in qt?qt.using.call(wt,vr):In.css(vr)}},ie.fn.extend({offset:function(wt){if(arguments.length)return wt===void 0?this:this.each(function(Qe){ie.offset.setOffset(this,wt,Qe)});var qt,Cn,Pn=this[0];return Pn?Pn.getClientRects().length?(qt=Pn.getBoundingClientRect(),Cn=Pn.ownerDocument.defaultView,{top:qt.top+Cn.pageYOffset,left:qt.left+Cn.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var wt,qt,Cn,Pn=this[0],Qe={top:0,left:0};if(ie.css(Pn,"position")==="fixed")qt=Pn.getBoundingClientRect();else{for(qt=this.offset(),Cn=Pn.ownerDocument,wt=Pn.offsetParent||Cn.documentElement;wt&&(wt===Cn.body||wt===Cn.documentElement)&&ie.css(wt,"position")==="static";)wt=wt.parentNode;wt&&wt!==Pn&&wt.nodeType===1&&((Qe=ie(wt).offset()).top+=ie.css(wt,"borderTopWidth",!0),Qe.left+=ie.css(wt,"borderLeftWidth",!0))}return{top:qt.top-Qe.top-ie.css(Pn,"marginTop",!0),left:qt.left-Qe.left-ie.css(Pn,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var wt=this.offsetParent;wt&&ie.css(wt,"position")==="static";)wt=wt.offsetParent;return wt||bi})}}),ie.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(wt,qt){var Cn=qt==="pageYOffset";ie.fn[wt]=function(Pn){return qn(this,function(Qe,yt,Rt){var jt;if(Ue(Qe)?jt=Qe:Qe.nodeType===9&&(jt=Qe.defaultView),Rt===void 0)return jt?jt[qt]:Qe[yt];jt?jt.scrollTo(Cn?jt.pageXOffset:Rt,Cn?Rt:jt.pageYOffset):Qe[yt]=Rt},wt,Pn,arguments.length)}}),ie.each(["top","left"],function(wt,qt){ie.cssHooks[qt]=yu(ve.pixelPosition,function(Cn,Pn){if(Pn)return Pn=wl(Cn,qt),ma.test(Pn)?ie(Cn).position()[qt]+"px":Pn})}),ie.each({Height:"height",Width:"width"},function(wt,qt){ie.each({padding:"inner"+wt,content:qt,"":"outer"+wt},function(Cn,Pn){ie.fn[Pn]=function(Qe,yt){var Rt=arguments.length&&(Cn||typeof Qe!="boolean"),jt=Cn||(Qe===!0||yt===!0?"margin":"border");return qn(this,function(dn,yn,In){var vr;return Ue(dn)?Pn.indexOf("outer")===0?dn["inner"+wt]:dn.document.documentElement["client"+wt]:dn.nodeType===9?(vr=dn.documentElement,Math.max(dn.body["scroll"+wt],vr["scroll"+wt],dn.body["offset"+wt],vr["offset"+wt],vr["client"+wt])):In===void 0?ie.css(dn,yn,jt):ie.style(dn,yn,In,jt)},qt,Rt?Qe:void 0,Rt)}})}),ie.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(wt,qt){ie.fn[qt]=function(Cn){return this.on(qt,Cn)}}),ie.fn.extend({bind:function(wt,qt,Cn){return this.on(wt,null,qt,Cn)},unbind:function(wt,qt){return this.off(wt,null,qt)},delegate:function(wt,qt,Cn,Pn){return this.on(qt,wt,Cn,Pn)},undelegate:function(wt,qt,Cn){return arguments.length===1?this.off(wt,"**"):this.off(qt,wt||"**",Cn)},hover:function(wt,qt){return this.mouseenter(wt).mouseleave(qt||wt)}}),ie.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(wt,qt){ie.fn[qt]=function(Cn,Pn){return arguments.length>0?this.on(qt,null,Cn,Pn):this.trigger(qt)}});var Vo=/^[\s\uFEFF\xA0]+|([^\s\uFEFF\xA0])[\s\uFEFF\xA0]+$/g;ie.proxy=function(wt,qt){var Cn,Pn,Qe;if(typeof qt=="string"&&(Cn=wt[qt],qt=wt,wt=Cn),ne(wt))return Pn=b.call(arguments,2),(Qe=function(){return wt.apply(qt||this,Pn.concat(b.call(arguments)))}).guid=wt.guid=wt.guid||ie.guid++,Qe},ie.holdReady=function(wt){wt?ie.readyWait++:ie.ready(!0)},ie.isArray=Array.isArray,ie.parseJSON=JSON.parse,ie.nodeName=pt,ie.isFunction=ne,ie.isWindow=Ue,ie.camelCase=ai,ie.type=Ae,ie.now=Date.now,ie.isNumeric=function(wt){var qt=ie.type(wt);return(qt==="number"||qt==="string")&&!isNaN(wt-parseFloat(wt))},ie.trim=function(wt){return wt==null?"":(wt+"").replace(Vo,"$1")};var iu=n.jQuery,Tu=n.$;return ie.noConflict=function(wt){return n.$===ie&&(n.$=Tu),wt&&n.jQuery===ie&&(n.jQuery=iu),ie},u===void 0&&(n.jQuery=n.$=ie),ie},t.exports=e.document?l(e,!0):function(n){if(!n.document)throw new Error("jQuery requires a window with a document");return l(n)}}),jquery$1$1=Object.freeze({__proto__:null,default:jquery$1,__moduleExports:jquery$1});function mxcadassemblyinit(){var t,e=(t=typeof document<"u"&&document.currentScript?document.currentScript.src:void 0,typeof __filename<"u"&&(t=t||__filename),function(l){var n,u,c;l=l||{},n||(n=l!==void 0?l:{}),n.ready=new Promise(function(ki,Aa){u=ki,c=Aa});var y,b,m,O,N,L,G=Object.assign({},n),q=typeof window=="object",J=typeof importScripts=="function",fe=typeof process=="object"&&typeof process.versions=="object"&&typeof process.versions.node=="string",ve="";fe?(ve=J?xxxxx("path").dirname(ve)+"/":__dirname+"/",L=()=>{N||(O=xxxxx("fs"),N=xxxxx("path"))},y=function(ki,Aa){var Ja=ti(ki);return Ja?Aa?Ja:Ja.toString():(L(),ki=N.normalize(ki),O.readFileSync(ki,Aa?void 0:"utf8"))},m=ki=>((ki=y(ki,!0)).buffer||(ki=new Uint8Array(ki)),ki),b=(ki,Aa,Ja)=>{var yo=ti(ki);yo&&Aa(yo),L(),ki=N.normalize(ki),O.readFile(ki,function(ls,xo){ls?Ja(ls):Aa(xo.buffer)})},1<process.argv.length&&process.argv[1].replace(/\\/g,"/"),process.argv.slice(2),process.on("uncaughtException",function(ki){throw ki}),process.on("unhandledRejection",function(ki){throw ki}),n.inspect=function(){return"[Emscripten Module object]"}):(q||J)&&(J?ve=self.location.href:typeof document<"u"&&document.currentScript&&(ve=document.currentScript.src),t&&(ve=t),ve=ve.indexOf("blob:")!==0?ve.substr(0,ve.replace(/[?#].*/,"").lastIndexOf("/")+1):"",y=ki=>{try{var Aa=new XMLHttpRequest;return Aa.open("GET",ki,!1),Aa.send(null),Aa.responseText}catch(ls){if(ki=ti(ki)){Aa=[];for(var Ja=0;Ja<ki.length;Ja++){var yo=ki[Ja];255<yo&&(yo&=255),Aa.push(String.fromCharCode(yo))}return Aa.join("")}throw ls}},J&&(m=ki=>{try{var Aa=new XMLHttpRequest;return Aa.open("GET",ki,!1),Aa.responseType="arraybuffer",Aa.send(null),new Uint8Array(Aa.response)}catch(Ja){if(ki=ti(ki))return ki;throw Ja}}),b=(ki,Aa,Ja)=>{var yo=new XMLHttpRequest;yo.open("GET",ki,!0),yo.responseType="arraybuffer",yo.onload=()=>{if(yo.status==200||yo.status==0&&yo.response)Aa(yo.response);else{var ls=ti(ki);ls?Aa(ls.buffer):Ja()}},yo.onerror=Ja,yo.send(null)}),n.print||console.log.bind(console);var ne,Ue=n.printErr||console.warn.bind(console);Object.assign(n,G),G=null,n.wasmBinary&&(ne=n.wasmBinary),n.noExitRuntime;var De=Error,Ve={};ne=[],typeof Ve!="object"&&Dn("no native wasm support detected");var rt,Ae,Te,Xe,ie,ue=!1,pt=n.INITIAL_MEMORY||16777216;(rt=n.wasmMemory?n.wasmMemory:new function(){this.buffer=new ArrayBuffer(pt/65536*65536)})&&(Ae=rt.buffer),pt=Ae.byteLength;var mt=Ae;Ae=mt,n.HEAP8=Te=new Int8Array(mt),n.HEAP16=new Int16Array(mt),n.HEAP32=ie=new Int32Array(mt),n.HEAPU8=Xe=new Uint8Array(mt),n.HEAPU16=new Uint16Array(mt),n.HEAPU32=new Uint32Array(mt),n.HEAPF32=new Float32Array(mt),n.HEAPF64=new Float64Array(mt);var Tt,kt=[],It=[],nn=[];function tn(){var ki=n.preRun.shift();kt.unshift(ki)}var pn=0,_n=null;function Dn(ki){throw n.onAbort&&n.onAbort(ki),Ue(ki="Aborted("+ki+")"),ue=!0,ki=new De(ki+". Build with -s ASSERTIONS=1 for more info."),c(ki),ki}n.preloadedImages={},n.preloadedAudios={};var an,Rn="data:application/octet-stream;base64,";if(!(an="mxcadassembly_min.wasm").startsWith(Rn)){var Lt=an;an=n.locateFile?n.locateFile(Lt,ve):ve+Lt}function wn(){var ki=an;try{if(ki==an&&ne)return new Uint8Array(ne);var Aa=ti(ki);if(Aa)return Aa;if(m)return m(ki);throw"both async and sync fetching of the wasm failed"}catch(Ja){Dn(Ja)}}function hn(ki){for(;0<ki.length;){var Aa=ki.shift();if(typeof Aa=="function")Aa(n);else{var Ja=Aa.U;typeof Ja=="number"?Aa.G===void 0?$n(Ja)():$n(Ja)(Aa.G):Ja(Aa.G===void 0?null:Aa.G)}}}var xn=[];function $n(ki){var Aa=xn[ki];return Aa||(ki>=xn.length&&(xn.length=ki+1),xn[ki]=Aa=Tt.get(ki)),Aa}var Xr=typeof atob=="function"?atob:function(ki){var Aa="",Ja=0;ki=ki.replace(/[^A-Za-z0-9\+\/=]/g,"");do{var yo="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(ki.charAt(Ja++)),ls="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(ki.charAt(Ja++)),xo="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(ki.charAt(Ja++)),_o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(ki.charAt(Ja++));yo=yo<<2|ls>>4,ls=(15&ls)<<4|xo>>2;var Ao=(3&xo)<<6|_o;Aa+=String.fromCharCode(yo),xo!==64&&(Aa+=String.fromCharCode(ls)),_o!==64&&(Aa+=String.fromCharCode(Ao))}while(Ja<ki.length);return Aa};function ti(ki){if(ki.startsWith(Rn)){if(ki=ki.slice(Rn.length),typeof fe=="boolean"&&fe){var Aa=Buffer.from(ki,"base64");Aa=new Uint8Array(Aa.buffer,Aa.byteOffset,Aa.byteLength)}else try{var Ja=Xr(ki),yo=new Uint8Array(Ja.length);for(ki=0;ki<Ja.length;++ki)yo[ki]=Ja.charCodeAt(ki);Aa=yo}catch{throw Error("Converting base64 string to bytes failed.")}return Aa}}var gn={f:function(ki){return hr(ki+16)+16},e:function(ki,Aa,Ja){throw new function(yo){this.C=yo-16,this.P=function(ls){ie[this.C+4>>2]=ls},this.M=function(ls){ie[this.C+8>>2]=ls},this.N=function(){ie[this.C>>2]=0},this.L=function(){Te[this.C+12>>0]=0},this.O=function(){Te[this.C+13>>0]=0},this.K=function(ls,xo){this.P(ls),this.M(xo),this.N(),this.L(),this.O()}}(ki).K(Aa,Ja),ki},c:function(){Dn("")},d:function(ki,Aa,Ja){Xe.copyWithin(ki,Aa,Aa+Ja)},b:function(){Dn("OOM")},a:rt};(function(){function ki(ls){n.asm=ls.exports,Tt=n.asm.A,It.unshift(n.asm.g),pn--,n.monitorRunDependencies&&n.monitorRunDependencies(pn),pn==0&&_n&&(ls=_n,_n=null,ls())}function Aa(ls){ki(ls.instance)}function Ja(ls){return function(){if(!ne&&(q||J)){if(typeof fetch=="function"&&!an.startsWith("file://"))return fetch(an,{credentials:"same-origin"}).then(function(xo){if(!xo.ok)throw"failed to load wasm binary file at '"+an+"'";return xo.arrayBuffer()}).catch(function(){return wn()});if(b)return new Promise(function(xo,_o){b(an,function(Ao){xo(new Uint8Array(Ao))},_o)})}return Promise.resolve().then(function(){return wn()})}().then(function(){return{then:function(xo){xo({instance:new function(){this.exports=function(_o){for(var Ao,il=new Uint8Array(123),zr=25;zr>=0;--zr)il[48+zr]=52+zr,il[65+zr]=zr,il[97+zr]=26+zr;function zn(Un,Gr,ni){for(var Ei,$t,ta=0,Hi=Gr,Ai=ni.length,Ea=Gr+(3*Ai>>2)-(ni[Ai-2]=="=")-(ni[Ai-1]=="=");ta<Ai;ta+=4)Ei=il[ni.charCodeAt(ta+1)],$t=il[ni.charCodeAt(ta+2)],Un[Hi++]=il[ni.charCodeAt(ta)]<<2|Ei>>4,Hi<Ea&&(Un[Hi++]=Ei<<4|$t>>2),Hi<Ea&&(Un[Hi++]=$t<<6|il[ni.charCodeAt(ta+3)])}return il[43]=62,il[47]=63,function(Un){var Gr=Un.a.buffer,ni=new Int8Array(Gr),Ei=new Int16Array(Gr),$t=new Int32Array(Gr),ta=new Uint8Array(Gr),Hi=new Uint32Array(Gr),Ai=new Float64Array(Gr),Ea=Math.imul,wo=Un.abort,to=Un.b,zo=Un.c,Po=Un.d,Lo=Un.e,Wo=Un.f,ma=5245008;function $s(Mn){var Ur,Gn=0,Qr=0,qi=0,ga=0,no=0,mo=0,Go=0,Uo=0,Ns=0,jl=0;ma=Ur=ma-16|0;e:{t:{n:{a:{i:{l:{r:{u:{c:{s:{o:{if((Mn|=0)>>>0<=244){if(3&(Gn=(ga=$t[404])>>>(Qr=(mo=Mn>>>0<11?16:Mn+11&-8)>>>3|0)|0)){Mn=(no=$t[1664+(Gn=(qi=Qr+(1&(-1^Gn))|0)<<3)>>2])+8|0,(0|(Qr=$t[no+8>>2]))!=(0|(Gn=Gn+1656|0))?($t[Qr+12>>2]=Gn,$t[Gn+8>>2]=Qr):$t[404]=jo(qi)&ga,Gn=qi<<3,$t[no+4>>2]=3|Gn,$t[4+(Gn=Gn+no|0)>>2]=1|$t[Gn+4>>2];break e}if((jl=$t[406])>>>0>=mo>>>0)break o;if(Gn){Qr=Mn=(Gn=(0-(Mn=(0-(Mn=2<<Qr)|Mn)&Gn<<Qr)&Mn)-1|0)>>>12&16,Qr|=Mn=(Gn=Gn>>>Mn|0)>>>5&8,Qr|=Mn=(Gn=Gn>>>Mn|0)>>>2&4,Ns=$t[1664+(Mn=(Qr=((Qr|=Mn=(Gn=Gn>>>Mn|0)>>>1&2)|(Mn=(Gn=Gn>>>Mn|0)>>>1&1))+(Gn>>>Mn|0)|0)<<3)>>2],(0|(Gn=$t[Ns+8>>2]))!=(0|(Mn=Mn+1656|0))?($t[Gn+12>>2]=Mn,$t[Mn+8>>2]=Gn):(ga=jo(Qr)&ga,$t[404]=ga),Mn=Ns+8|0,$t[Ns+4>>2]=3|mo,no=(Gn=Qr<<3)-mo|0,$t[4+(qi=mo+Ns|0)>>2]=1|no,$t[Gn+Ns>>2]=no,jl&&(Qr=1656+((Gn=jl>>>3|0)<<3)|0,Ns=$t[409],(Gn=1<<Gn)&ga?Gn=$t[Qr+8>>2]:($t[404]=Gn|ga,Gn=Qr),$t[Qr+8>>2]=Ns,$t[Gn+12>>2]=Ns,$t[Ns+12>>2]=Qr,$t[Ns+8>>2]=Gn),$t[409]=qi,$t[406]=no;break e}if(!(Go=$t[405]))break o;for(Qr=Mn=(Gn=(0-Go&Go)-1|0)>>>12&16,Qr|=Mn=(Gn=Gn>>>Mn|0)>>>5&8,Qr|=Mn=(Gn=Gn>>>Mn|0)>>>2&4,Gn=$t[1920+(((Qr|=Mn=(Gn=Gn>>>Mn|0)>>>1&2)|(Mn=(Gn=Gn>>>Mn|0)>>>1&1))+(Gn>>>Mn|0)<<2)>>2],qi=(-8&$t[Gn+4>>2])-mo|0,Qr=Gn;(Mn=$t[Qr+16>>2])||(Mn=$t[Qr+20>>2]);)qi=(no=(Qr=(-8&$t[Mn+4>>2])-mo|0)>>>0<qi>>>0)?Qr:qi,Gn=no?Mn:Gn,Qr=Mn;if(Uo=$t[Gn+24>>2],(0|(no=$t[Gn+12>>2]))!=(0|Gn)){Mn=$t[Gn+8>>2],$t[Mn+12>>2]=no,$t[no+8>>2]=Mn;break t}if(!(Mn=$t[(Qr=Gn+20|0)>>2])){if(!(Mn=$t[Gn+16>>2]))break s;Qr=Gn+16|0}for(;Ns=Qr,no=Mn,(Mn=$t[(Qr=Mn+20|0)>>2])||(Qr=no+16|0,Mn=$t[no+16>>2]););$t[Ns>>2]=0;break t}if(mo=-1,!(Mn>>>0>4294967231)&&(mo=-8&(Mn=Mn+11|0),Uo=$t[405])){qi=0-mo|0,ga=0,mo>>>0<256||(ga=31,mo>>>0>16777215||(Mn=Mn>>>8|0,Mn<<=Ns=Mn+1048320>>>16&8,ga=28+((Mn=((Mn<<=Qr=Mn+520192>>>16&4)<<(Gn=Mn+245760>>>16&2)>>>15|0)-(Gn|Qr|Ns)|0)<<1|mo>>>Mn+21&1)|0));d:{h:{if(Qr=$t[1920+(ga<<2)>>2])for(Mn=0,Gn=mo<<((0|ga)==31?0:25-(ga>>>1|0)|0);;){if(!((Ns=(Go=-8&$t[Qr+4>>2])-mo|0)>>>0>=qi>>>0)&&(qi=Ns,no=Qr,(0|mo)==(0|Go))){qi=0,Mn=Qr;break h}if(Ns=$t[Qr+20>>2],Qr=$t[16+((Gn>>>29&4)+Qr|0)>>2],Mn=Ns?(0|Ns)==(0|Qr)?Mn:Ns:Mn,Gn<<=1,!Qr)break}else Mn=0;if(!(Mn|no)){if(no=0,!(Mn=(0-(Mn=2<<ga)|Mn)&Uo))break o;Qr=Mn=(Gn=(Mn&0-Mn)-1|0)>>>12&16,Qr|=Mn=(Gn=Gn>>>Mn|0)>>>5&8,Qr|=Mn=(Gn=Gn>>>Mn|0)>>>2&4,Mn=$t[1920+(((Qr|=Mn=(Gn=Gn>>>Mn|0)>>>1&2)|(Mn=(Gn=Gn>>>Mn|0)>>>1&1))+(Gn>>>Mn|0)<<2)>>2]}if(!Mn)break d}for(;qi=(Qr=(Gn=(-8&$t[Mn+4>>2])-mo|0)>>>0<qi>>>0)?Gn:qi,no=Qr?Mn:no,Mn=(Gn=$t[Mn+16>>2])||$t[Mn+20>>2];);}if(!(!no|$t[406]-mo>>>0<=qi>>>0)){if(ga=$t[no+24>>2],(0|no)!=(0|(Gn=$t[no+12>>2]))){Mn=$t[no+8>>2],$t[Mn+12>>2]=Gn,$t[Gn+8>>2]=Mn;break n}if(!(Mn=$t[(Qr=no+20|0)>>2])){if(!(Mn=$t[no+16>>2]))break c;Qr=no+16|0}for(;Ns=Qr,Gn=Mn,(Mn=$t[(Qr=Mn+20|0)>>2])||(Qr=Gn+16|0,Mn=$t[Gn+16>>2]););$t[Ns>>2]=0;break n}}}if((Qr=$t[406])>>>0>=mo>>>0){qi=$t[409],(Gn=Qr-mo|0)>>>0>=16?($t[406]=Gn,Mn=qi+mo|0,$t[409]=Mn,$t[Mn+4>>2]=1|Gn,$t[Qr+qi>>2]=Gn,$t[qi+4>>2]=3|mo):($t[409]=0,$t[406]=0,$t[qi+4>>2]=3|Qr,$t[4+(Mn=Qr+qi|0)>>2]=1|$t[Mn+4>>2]),Mn=qi+8|0;break e}if((Uo=$t[407])>>>0>mo>>>0){Gn=Uo-mo|0,$t[407]=Gn,Mn=(Qr=$t[410])+mo|0,$t[410]=Mn,$t[Mn+4>>2]=1|Gn,$t[Qr+4>>2]=3|mo,Mn=Qr+8|0;break e}if(Mn=0,Go=mo+47|0,$t[522]?Qr=$t[524]:($t[525]=-1,$t[526]=-1,$t[523]=4096,$t[524]=4096,$t[522]=Ur+12&-16^1431655768,$t[527]=0,$t[515]=0,Qr=4096),(Qr=(Ns=Go+Qr|0)&(no=0-Qr|0))>>>0<=mo>>>0||(qi=$t[514])&&(ga=(Gn=$t[512])+Qr|0)>>>0>qi>>>0|Gn>>>0>=ga>>>0)break e;if(4&ta[2060])break l;o:{d:{if(qi=$t[410])for(Mn=2064;;){if((Gn=$t[Mn>>2])>>>0<=qi>>>0&qi>>>0<Gn+$t[Mn+4>>2]>>>0)break d;if(!(Mn=$t[Mn+8>>2]))break}if((0|(Gn=Es(0)))==-1||(ga=Qr,(Mn=(qi=$t[523])-1|0)&Gn&&(ga=(Qr-Gn|0)+(Mn+Gn&0-qi)|0),ga>>>0<=mo>>>0|ga>>>0>2147483646)||(qi=$t[514])&&qi>>>0<(no=(Mn=$t[512])+ga|0)>>>0|Mn>>>0>=no>>>0)break r;if((0|Gn)!=(0|(Mn=Es(ga))))break o;break i}if((ga=no&Ns-Uo)>>>0>2147483646)break r;if((0|(Gn=Es(ga)))==($t[Mn>>2]+$t[Mn+4>>2]|0))break u;Mn=Gn}if(!((0|Mn)==-1|mo+48>>>0<=ga>>>0)){if((Gn=(Gn=$t[524])+(Go-ga|0)&0-Gn)>>>0>2147483646){Gn=Mn;break i}if((0|Es(Gn))!=-1){ga=Gn+ga|0,Gn=Mn;break i}Es(0-ga|0);break r}if(Gn=Mn,(0|Mn)!=-1)break i;break r}no=0;break t}Gn=0;break n}if((0|Gn)!=-1)break i}$t[515]=4|$t[515]}if(Qr>>>0>2147483646||(0|(Gn=Es(Qr)))==-1|(0|(Mn=Es(0)))==-1|Mn>>>0<=Gn>>>0||(ga=Mn-Gn|0)>>>0<=mo+40>>>0)break a}Mn=$t[512]+ga|0,$t[512]=Mn,Mn>>>0>Hi[513]&&($t[513]=Mn);i:{l:{r:{if(Go=$t[410]){for(Mn=2064;;){if(((qi=$t[Mn>>2])+(Qr=$t[Mn+4>>2])|0)==(0|Gn))break r;if(!(Mn=$t[Mn+8>>2]))break}break l}for((Mn=$t[408])>>>0<=Gn>>>0&&Mn||($t[408]=Gn),Mn=0,$t[517]=ga,$t[516]=Gn,$t[412]=-1,$t[413]=$t[522],$t[519]=0;Qr=1656+(qi=Mn<<3)|0,$t[qi+1664>>2]=Qr,$t[qi+1668>>2]=Qr,(0|(Mn=Mn+1|0))!=32;);Qr=(qi=ga-40|0)-(Mn=Gn+8&7?-8-Gn&7:0)|0,$t[407]=Qr,Mn=Mn+Gn|0,$t[410]=Mn,$t[Mn+4>>2]=1|Qr,$t[4+(Gn+qi|0)>>2]=40,$t[411]=$t[526];break i}if(!(8&ta[Mn+12|0]|qi>>>0>Go>>>0|Gn>>>0<=Go>>>0)){$t[Mn+4>>2]=Qr+ga,Qr=(Mn=Go+8&7?-8-Go&7:0)+Go|0,$t[410]=Qr,Mn=(Gn=$t[407]+ga|0)-Mn|0,$t[407]=Mn,$t[Qr+4>>2]=1|Mn,$t[4+(Gn+Go|0)>>2]=40,$t[411]=$t[526];break i}}Hi[408]>Gn>>>0&&($t[408]=Gn),Qr=Gn+ga|0,Mn=2064;l:{r:{u:{c:{s:{o:{for(;;){if((0|Qr)!=$t[Mn>>2]){if(Mn=$t[Mn+8>>2])continue;break o}break}if(!(8&ta[Mn+12|0]))break s}for(Mn=2064;;){if((Qr=$t[Mn>>2])>>>0<=Go>>>0&&(no=Qr+$t[Mn+4>>2]|0)>>>0>Go>>>0)break c;Mn=$t[Mn+8>>2]}}if($t[Mn>>2]=Gn,$t[Mn+4>>2]=$t[Mn+4>>2]+ga,$t[4+(Ns=(Gn+8&7?-8-Gn&7:0)+Gn|0)>>2]=3|mo,mo=(ga=Qr+(Qr+8&7?-8-Qr&7:0)|0)-(Uo=mo+Ns|0)|0,(0|ga)==(0|Go)){$t[410]=Uo,Mn=$t[407]+mo|0,$t[407]=Mn,$t[Uo+4>>2]=1|Mn;break r}if($t[409]==(0|ga)){$t[409]=Uo,Mn=$t[406]+mo|0,$t[406]=Mn,$t[Uo+4>>2]=1|Mn,$t[Mn+Uo>>2]=Mn;break r}if((3&(Mn=$t[ga+4>>2]))==1){no=-8&Mn;s:if(Mn>>>0<=255){if(Qr=$t[ga+8>>2],Mn=Mn>>>3|0,(0|(Gn=$t[ga+12>>2]))==(0|Qr)){$t[404]=$t[404]&jo(Mn);break s}$t[Qr+12>>2]=Gn,$t[Gn+8>>2]=Qr}else{if(Go=$t[ga+24>>2],(0|ga)==(0|(Gn=$t[ga+12>>2])))if((qi=$t[(Mn=ga+20|0)>>2])||(qi=$t[(Mn=ga+16|0)>>2])){for(;Qr=Mn,(qi=$t[(Mn=(Gn=qi)+20|0)>>2])||(Mn=Gn+16|0,qi=$t[Gn+16>>2]););$t[Qr>>2]=0}else Gn=0;else Mn=$t[ga+8>>2],$t[Mn+12>>2]=Gn,$t[Gn+8>>2]=Mn;if(Go){Qr=$t[ga+28>>2];o:{if($t[(Mn=1920+(Qr<<2)|0)>>2]==(0|ga)){if($t[Mn>>2]=Gn,Gn)break o;$t[405]=$t[405]&jo(Qr);break s}if($t[Go+($t[Go+16>>2]==(0|ga)?16:20)>>2]=Gn,!Gn)break s}$t[Gn+24>>2]=Go,(Mn=$t[ga+16>>2])&&($t[Gn+16>>2]=Mn,$t[Mn+24>>2]=Gn),(Mn=$t[ga+20>>2])&&($t[Gn+20>>2]=Mn,$t[Mn+24>>2]=Gn)}}mo=no+mo|0,ga=ga+no|0}if($t[ga+4>>2]=-2&$t[ga+4>>2],$t[Uo+4>>2]=1|mo,$t[mo+Uo>>2]=mo,mo>>>0<=255){Gn=1656+((Mn=mo>>>3|0)<<3)|0,(Qr=$t[404])&(Mn=1<<Mn)?Mn=$t[Gn+8>>2]:($t[404]=Mn|Qr,Mn=Gn),$t[Gn+8>>2]=Uo,$t[Mn+12>>2]=Uo,$t[Uo+12>>2]=Gn,$t[Uo+8>>2]=Mn;break r}if(Mn=31,mo>>>0<=16777215&&(Mn=mo>>>8|0,Mn<<=qi=Mn+1048320>>>16&8,Mn=28+((Mn=((Mn<<=Qr=Mn+520192>>>16&4)<<(Gn=Mn+245760>>>16&2)>>>15|0)-(Gn|Qr|qi)|0)<<1|mo>>>Mn+21&1)|0),$t[Uo+28>>2]=Mn,$t[Uo+16>>2]=0,$t[Uo+20>>2]=0,qi=1920+(Mn<<2)|0,(Qr=$t[405])&(Gn=1<<Mn)){for(Mn=mo<<((0|Mn)==31?0:25-(Mn>>>1|0)|0),Gn=$t[qi>>2];;){if(Qr=Gn,(-8&$t[Gn+4>>2])==(0|mo))break u;if(Gn=Mn>>>29|0,Mn<<=1,!(Gn=$t[16+(qi=Qr+(4&Gn)|0)>>2]))break}$t[qi+16>>2]=Uo,$t[Uo+24>>2]=Qr}else $t[405]=Gn|Qr,$t[qi>>2]=Uo,$t[Uo+24>>2]=qi;$t[Uo+12>>2]=Uo,$t[Uo+8>>2]=Uo;break r}for(Qr=(qi=ga-40|0)-(Mn=Gn+8&7?-8-Gn&7:0)|0,$t[407]=Qr,Mn=Mn+Gn|0,$t[410]=Mn,$t[Mn+4>>2]=1|Qr,$t[4+(Gn+qi|0)>>2]=40,$t[411]=$t[526],$t[(Qr=(Mn=(no+(no-39&7?39-no&7:0)|0)-47|0)>>>0<Go+16>>>0?Go:Mn)+4>>2]=27,Mn=$t[519],$t[Qr+16>>2]=$t[518],$t[Qr+20>>2]=Mn,Mn=$t[517],$t[Qr+8>>2]=$t[516],$t[Qr+12>>2]=Mn,$t[518]=Qr+8,$t[517]=ga,$t[516]=Gn,$t[519]=0,Mn=Qr+24|0;$t[Mn+4>>2]=7,Gn=Mn+8|0,Mn=Mn+4|0,Gn>>>0<no>>>0;);if((0|Qr)==(0|Go))break i;if($t[Qr+4>>2]=-2&$t[Qr+4>>2],no=Qr-Go|0,$t[Go+4>>2]=1|no,$t[Qr>>2]=no,no>>>0<=255){Gn=1656+((Mn=no>>>3|0)<<3)|0,(Qr=$t[404])&(Mn=1<<Mn)?Mn=$t[Gn+8>>2]:($t[404]=Mn|Qr,Mn=Gn),$t[Gn+8>>2]=Go,$t[Mn+12>>2]=Go,$t[Go+12>>2]=Gn,$t[Go+8>>2]=Mn;break i}if(Mn=31,$t[Go+16>>2]=0,$t[Go+20>>2]=0,no>>>0<=16777215&&(Mn=no>>>8|0,Mn<<=qi=Mn+1048320>>>16&8,Mn=28+((Mn=((Mn<<=Qr=Mn+520192>>>16&4)<<(Gn=Mn+245760>>>16&2)>>>15|0)-(Gn|Qr|qi)|0)<<1|no>>>Mn+21&1)|0),$t[Go+28>>2]=Mn,qi=1920+(Mn<<2)|0,(Qr=$t[405])&(Gn=1<<Mn)){for(Mn=no<<((0|Mn)==31?0:25-(Mn>>>1|0)|0),Gn=$t[qi>>2];;){if(Qr=Gn,(0|no)==(-8&$t[Gn+4>>2]))break l;if(Gn=Mn>>>29|0,Mn<<=1,!(Gn=$t[16+(qi=Qr+(4&Gn)|0)>>2]))break}$t[qi+16>>2]=Go,$t[Go+24>>2]=Qr}else $t[405]=Gn|Qr,$t[qi>>2]=Go,$t[Go+24>>2]=qi;$t[Go+12>>2]=Go,$t[Go+8>>2]=Go;break i}Mn=$t[Qr+8>>2],$t[Mn+12>>2]=Uo,$t[Qr+8>>2]=Uo,$t[Uo+24>>2]=0,$t[Uo+12>>2]=Qr,$t[Uo+8>>2]=Mn}Mn=Ns+8|0;break e}Mn=$t[Qr+8>>2],$t[Mn+12>>2]=Go,$t[Qr+8>>2]=Go,$t[Go+24>>2]=0,$t[Go+12>>2]=Qr,$t[Go+8>>2]=Mn}if(!((Mn=$t[407])>>>0<=mo>>>0)){Gn=Mn-mo|0,$t[407]=Gn,Mn=(Qr=$t[410])+mo|0,$t[410]=Mn,$t[Mn+4>>2]=1|Gn,$t[Qr+4>>2]=3|mo,Mn=Qr+8|0;break e}}$t[403]=48,Mn=0;break e}n:if(ga){Qr=$t[no+28>>2];a:{if($t[(Mn=1920+(Qr<<2)|0)>>2]==(0|no)){if($t[Mn>>2]=Gn,Gn)break a;Uo=jo(Qr)&Uo,$t[405]=Uo;break n}if($t[ga+($t[ga+16>>2]==(0|no)?16:20)>>2]=Gn,!Gn)break n}$t[Gn+24>>2]=ga,(Mn=$t[no+16>>2])&&($t[Gn+16>>2]=Mn,$t[Mn+24>>2]=Gn),(Mn=$t[no+20>>2])&&($t[Gn+20>>2]=Mn,$t[Mn+24>>2]=Gn)}n:if(qi>>>0<=15)Mn=qi+mo|0,$t[no+4>>2]=3|Mn,$t[4+(Mn=Mn+no|0)>>2]=1|$t[Mn+4>>2];else if($t[no+4>>2]=3|mo,$t[4+(ga=no+mo|0)>>2]=1|qi,$t[ga+qi>>2]=qi,qi>>>0<=255)Gn=1656+((Mn=qi>>>3|0)<<3)|0,(Qr=$t[404])&(Mn=1<<Mn)?Mn=$t[Gn+8>>2]:($t[404]=Mn|Qr,Mn=Gn),$t[Gn+8>>2]=ga,$t[Mn+12>>2]=ga,$t[ga+12>>2]=Gn,$t[ga+8>>2]=Mn;else{Mn=31,qi>>>0<=16777215&&(Mn=qi>>>8|0,Mn<<=Ns=Mn+1048320>>>16&8,Mn=28+((Mn=((Mn<<=Qr=Mn+520192>>>16&4)<<(Gn=Mn+245760>>>16&2)>>>15|0)-(Gn|Qr|Ns)|0)<<1|qi>>>Mn+21&1)|0),$t[ga+28>>2]=Mn,$t[ga+16>>2]=0,$t[ga+20>>2]=0,Gn=1920+(Mn<<2)|0;a:{if((Qr=1<<Mn)&Uo){for(Mn=qi<<((0|Mn)==31?0:25-(Mn>>>1|0)|0),Qr=$t[Gn>>2];;){if((-8&$t[(Gn=Qr)+4>>2])==(0|qi))break a;if(Qr=Mn>>>29|0,Mn<<=1,!(Qr=$t[16+(Ns=(4&Qr)+Gn|0)>>2]))break}$t[Ns+16>>2]=ga}else $t[405]=Qr|Uo,$t[Gn>>2]=ga;$t[ga+24>>2]=Gn,$t[ga+12>>2]=ga,$t[ga+8>>2]=ga;break n}Mn=$t[Gn+8>>2],$t[Mn+12>>2]=ga,$t[Gn+8>>2]=ga,$t[ga+24>>2]=0,$t[ga+12>>2]=Gn,$t[ga+8>>2]=Mn}Mn=no+8|0;break e}t:if(Uo){Qr=$t[Gn+28>>2];n:{if($t[(Mn=1920+(Qr<<2)|0)>>2]==(0|Gn)){if($t[Mn>>2]=no,no)break n;$t[405]=jo(Qr)&Go;break t}if($t[Uo+($t[Uo+16>>2]==(0|Gn)?16:20)>>2]=no,!no)break t}$t[no+24>>2]=Uo,(Mn=$t[Gn+16>>2])&&($t[no+16>>2]=Mn,$t[Mn+24>>2]=no),(Mn=$t[Gn+20>>2])&&($t[no+20>>2]=Mn,$t[Mn+24>>2]=no)}qi>>>0<=15?(Mn=qi+mo|0,$t[Gn+4>>2]=3|Mn,$t[4+(Mn=Mn+Gn|0)>>2]=1|$t[Mn+4>>2]):($t[Gn+4>>2]=3|mo,$t[4+(no=Gn+mo|0)>>2]=1|qi,$t[qi+no>>2]=qi,jl&&(Qr=1656+((Mn=jl>>>3|0)<<3)|0,Ns=$t[409],(Mn=1<<Mn)&ga?Mn=$t[Qr+8>>2]:($t[404]=Mn|ga,Mn=Qr),$t[Qr+8>>2]=Ns,$t[Mn+12>>2]=Ns,$t[Ns+12>>2]=Qr,$t[Ns+8>>2]=Mn),$t[409]=no,$t[406]=qi),Mn=Gn+8|0}return ma=Ur+16|0,0|Mn}function ao(Mn){var Ur=0,Gn=0,Qr=0,qi=0,ga=0,no=0,mo=0;e:if(Mn){ga=(Qr=Mn-8|0)+(Mn=-8&(Ur=$t[Mn-4>>2]))|0;t:if(!(1&Ur)){if(!(3&Ur)||(Qr=Qr-(Ur=$t[Qr>>2])|0)>>>0<Hi[408])break e;if(Mn=Mn+Ur|0,$t[409]==(0|Qr)){if((3&(Ur=$t[ga+4>>2]))==3)return $t[406]=Mn,$t[ga+4>>2]=-2&Ur,$t[Qr+4>>2]=1|Mn,void($t[Mn+Qr>>2]=Mn)}else{if(Ur>>>0<=255){if(qi=$t[Qr+8>>2],Ur=Ur>>>3|0,(0|(Gn=$t[Qr+12>>2]))==(0|qi)){$t[404]=$t[404]&jo(Ur);break t}$t[qi+12>>2]=Gn,$t[Gn+8>>2]=qi;break t}if(mo=$t[Qr+24>>2],(0|Qr)==(0|(Ur=$t[Qr+12>>2])))if((Gn=$t[(qi=Qr+20|0)>>2])||(Gn=$t[(qi=Qr+16|0)>>2])){for(;no=qi,(Gn=$t[(qi=(Ur=Gn)+20|0)>>2])||(qi=Ur+16|0,Gn=$t[Ur+16>>2]););$t[no>>2]=0}else Ur=0;else Gn=$t[Qr+8>>2],$t[Gn+12>>2]=Ur,$t[Ur+8>>2]=Gn;if(!mo)break t;qi=$t[Qr+28>>2];n:{if($t[(Gn=1920+(qi<<2)|0)>>2]==(0|Qr)){if($t[Gn>>2]=Ur,Ur)break n;$t[405]=$t[405]&jo(qi);break t}if($t[mo+($t[mo+16>>2]==(0|Qr)?16:20)>>2]=Ur,!Ur)break t}if($t[Ur+24>>2]=mo,(Gn=$t[Qr+16>>2])&&($t[Ur+16>>2]=Gn,$t[Gn+24>>2]=Ur),!(Gn=$t[Qr+20>>2]))break t;$t[Ur+20>>2]=Gn,$t[Gn+24>>2]=Ur}}if(!(Qr>>>0>=ga>>>0)&&1&(Ur=$t[ga+4>>2])){t:{if(!(2&Ur)){if($t[410]==(0|ga)){if($t[410]=Qr,Mn=$t[407]+Mn|0,$t[407]=Mn,$t[Qr+4>>2]=1|Mn,$t[409]!=(0|Qr))break e;return $t[406]=0,void($t[409]=0)}if($t[409]==(0|ga))return $t[409]=Qr,Mn=$t[406]+Mn|0,$t[406]=Mn,$t[Qr+4>>2]=1|Mn,void($t[Mn+Qr>>2]=Mn);Mn=(-8&Ur)+Mn|0;n:if(Ur>>>0<=255){if(qi=$t[ga+8>>2],Ur=Ur>>>3|0,(0|(Gn=$t[ga+12>>2]))==(0|qi)){$t[404]=$t[404]&jo(Ur);break n}$t[qi+12>>2]=Gn,$t[Gn+8>>2]=qi}else{if(mo=$t[ga+24>>2],(0|ga)==(0|(Ur=$t[ga+12>>2])))if((Gn=$t[(qi=ga+20|0)>>2])||(Gn=$t[(qi=ga+16|0)>>2])){for(;no=qi,(Gn=$t[(qi=(Ur=Gn)+20|0)>>2])||(qi=Ur+16|0,Gn=$t[Ur+16>>2]););$t[no>>2]=0}else Ur=0;else Gn=$t[ga+8>>2],$t[Gn+12>>2]=Ur,$t[Ur+8>>2]=Gn;if(mo){qi=$t[ga+28>>2];a:{if($t[(Gn=1920+(qi<<2)|0)>>2]==(0|ga)){if($t[Gn>>2]=Ur,Ur)break a;$t[405]=$t[405]&jo(qi);break n}if($t[mo+($t[mo+16>>2]==(0|ga)?16:20)>>2]=Ur,!Ur)break n}$t[Ur+24>>2]=mo,(Gn=$t[ga+16>>2])&&($t[Ur+16>>2]=Gn,$t[Gn+24>>2]=Ur),(Gn=$t[ga+20>>2])&&($t[Ur+20>>2]=Gn,$t[Gn+24>>2]=Ur)}}if($t[Qr+4>>2]=1|Mn,$t[Mn+Qr>>2]=Mn,$t[409]!=(0|Qr))break t;return void($t[406]=Mn)}$t[ga+4>>2]=-2&Ur,$t[Qr+4>>2]=1|Mn,$t[Mn+Qr>>2]=Mn}if(Mn>>>0<=255)return Ur=1656+((Mn=Mn>>>3|0)<<3)|0,(Gn=$t[404])&(Mn=1<<Mn)?Mn=$t[Ur+8>>2]:($t[404]=Mn|Gn,Mn=Ur),$t[Ur+8>>2]=Qr,$t[Mn+12>>2]=Qr,$t[Qr+12>>2]=Ur,void($t[Qr+8>>2]=Mn);qi=31,$t[Qr+16>>2]=0,$t[Qr+20>>2]=0,Mn>>>0<=16777215&&(Ur=Mn>>>8|0,Ur<<=no=Ur+1048320>>>16&8,qi=28+((Ur=((Ur<<=qi=Ur+520192>>>16&4)<<(Gn=Ur+245760>>>16&2)>>>15|0)-(Gn|qi|no)|0)<<1|Mn>>>Ur+21&1)|0),$t[Qr+28>>2]=qi,no=1920+(qi<<2)|0;t:{n:{if((Gn=$t[405])&(Ur=1<<qi)){for(qi=Mn<<((0|qi)==31?0:25-(qi>>>1|0)|0),Ur=$t[no>>2];;){if(Gn=Ur,(-8&$t[Ur+4>>2])==(0|Mn))break n;if(Ur=qi>>>29|0,qi<<=1,!(Ur=$t[16+(no=Gn+(4&Ur)|0)>>2]))break}$t[no+16>>2]=Qr,$t[Qr+24>>2]=Gn}else $t[405]=Ur|Gn,$t[no>>2]=Qr,$t[Qr+24>>2]=no;$t[Qr+12>>2]=Qr,$t[Qr+8>>2]=Qr;break t}Mn=$t[Gn+8>>2],$t[Mn+12>>2]=Qr,$t[Gn+8>>2]=Qr,$t[Qr+24>>2]=0,$t[Qr+12>>2]=Gn,$t[Qr+8>>2]=Mn}Mn=$t[412]-1|0,$t[412]=Mn||-1}}}function Ps(Mn,Ur,Gn){var Qr,qi=0,ga=0;if(Gn>>>0>=512)return Po(0|Mn,0|Ur,0|Gn),Mn;Qr=Mn+Gn|0;e:if(3&(Mn^Ur))if(Qr>>>0<4)Gn=Mn;else if((qi=Qr-4|0)>>>0<Mn>>>0)Gn=Mn;else for(Gn=Mn;ni[0|Gn]=ta[0|Ur],ni[Gn+1|0]=ta[Ur+1|0],ni[Gn+2|0]=ta[Ur+2|0],ni[Gn+3|0]=ta[Ur+3|0],Ur=Ur+4|0,qi>>>0>=(Gn=Gn+4|0)>>>0;);else{t:if(3&Mn)if(Gn)for(Gn=Mn;;){if(ni[0|Gn]=ta[0|Ur],Ur=Ur+1|0,!(3&(Gn=Gn+1|0)))break t;if(!(Gn>>>0<Qr>>>0))break}else Gn=Mn;else Gn=Mn;if(!((qi=-4&Qr)>>>0<64||(ga=qi+-64|0)>>>0<Gn>>>0))for(;$t[Gn>>2]=$t[Ur>>2],$t[Gn+4>>2]=$t[Ur+4>>2],$t[Gn+8>>2]=$t[Ur+8>>2],$t[Gn+12>>2]=$t[Ur+12>>2],$t[Gn+16>>2]=$t[Ur+16>>2],$t[Gn+20>>2]=$t[Ur+20>>2],$t[Gn+24>>2]=$t[Ur+24>>2],$t[Gn+28>>2]=$t[Ur+28>>2],$t[Gn+32>>2]=$t[Ur+32>>2],$t[Gn+36>>2]=$t[Ur+36>>2],$t[Gn+40>>2]=$t[Ur+40>>2],$t[Gn+44>>2]=$t[Ur+44>>2],$t[Gn+48>>2]=$t[Ur+48>>2],$t[Gn+52>>2]=$t[Ur+52>>2],$t[Gn+56>>2]=$t[Ur+56>>2],$t[Gn+60>>2]=$t[Ur+60>>2],Ur=Ur- -64|0,ga>>>0>=(Gn=Gn- -64|0)>>>0;);if(Gn>>>0>=qi>>>0)break e;for(;$t[Gn>>2]=$t[Ur>>2],Ur=Ur+4|0,qi>>>0>(Gn=Gn+4|0)>>>0;);}if(Gn>>>0<Qr>>>0)for(;ni[0|Gn]=ta[0|Ur],Ur=Ur+1|0,(0|Qr)!=(0|(Gn=Gn+1|0)););return Mn}function qo(Mn,Ur){var Gn=0;if(Ur&&(ni[0|Mn]=0,ni[(Gn=Mn+Ur|0)-1|0]=0,!(Ur>>>0<3||(ni[Mn+2|0]=0,ni[Mn+1|0]=0,ni[Gn-3|0]=0,ni[Gn-2|0]=0,Ur>>>0<7||(ni[Mn+3|0]=0,ni[Gn-4|0]=0,Ur>>>0<9||($t[(Mn=(Gn=0-Mn&3)+Mn|0)>>2]=0,$t[(Ur=(Gn=Ur-Gn&-4)+Mn|0)-4>>2]=0,Gn>>>0<9||($t[Mn+8>>2]=0,$t[Mn+4>>2]=0,$t[Ur-8>>2]=0,$t[Ur-12>>2]=0,Gn>>>0<25||($t[Mn+24>>2]=0,$t[Mn+20>>2]=0,$t[Mn+16>>2]=0,$t[Mn+12>>2]=0,$t[Ur-16>>2]=0,$t[Ur-20>>2]=0,$t[Ur-24>>2]=0,$t[Ur-28>>2]=0,(Ur=(Ur=Gn)-(Gn=4&Mn|24)|0)>>>0<32))))))))for(Mn=Mn+Gn|0;$t[Mn+24>>2]=0,$t[Mn+28>>2]=0,$t[Mn+16>>2]=0,$t[Mn+20>>2]=0,$t[Mn+8>>2]=0,$t[Mn+12>>2]=0,$t[Mn>>2]=0,$t[Mn+4>>2]=0,Mn=Mn+32|0,(Ur=Ur-32|0)>>>0>31;);}function wl(Mn){var Ur,Gn=0,Qr=0,qi=0;Ur=0|Wo(8),$t[Ur>>2]=1348,$t[Ur>>2]=1392;e:{t:{if(3&(Gn=Mn))for(;;){if(!ta[0|Gn])break t;if(!(3&(Gn=Gn+1|0)))break}for(;Qr=Gn,Gn=Gn+4|0,!((-1^(qi=$t[Qr>>2]))&qi-16843009&-2139062144););if(Gn=Qr-Mn|0,!(255&qi))break e;for(;qi=ta[Qr+1|0],Qr=Gn=Qr+1|0,qi;);}Gn=Gn-Mn|0}Qr=Xl(Gn+13|0),$t[Qr+8>>2]=0,$t[Qr+4>>2]=Gn,$t[Qr>>2]=Gn,$t[Ur+4>>2]=Ps(Qr+12|0,Mn,Gn+1|0),$t[Ur>>2]=1440,Lo(0|Ur,1472,1),wo()}function yu(Mn,Ur,Gn,Qr){ni[Mn+53|0]=1;e:if($t[Mn+4>>2]==(0|Gn)){ni[Mn+52|0]=1;t:{if(!(Gn=$t[Mn+16>>2])){if($t[Mn+36>>2]=1,$t[Mn+24>>2]=Qr,$t[Mn+16>>2]=Ur,(0|Qr)!=1)break e;if($t[Mn+48>>2]==1)break t;break e}if((0|Ur)==(0|Gn)){if((0|(Gn=$t[Mn+24>>2]))==2&&($t[Mn+24>>2]=Qr,Gn=Qr),$t[Mn+48>>2]!=1)break e;if((0|Gn)==1)break t;break e}$t[Mn+36>>2]=$t[Mn+36>>2]+1}ni[Mn+54|0]=1}}function po(Mn,Ur,Gn){var Qr=0;if(!Gn)return $t[Mn+4>>2]==$t[Ur+4>>2];if((0|Mn)==(0|Ur))return 1;Qr=$t[Mn+4>>2],Mn=ta[0|Qr],Gn=$t[Ur+4>>2];e:if(!(!Mn|(0|(Ur=ta[0|Gn]))!=(0|Mn)))for(;;){if(Ur=ta[Gn+1|0],!(Mn=ta[Qr+1|0]))break e;if(Gn=Gn+1|0,Qr=Qr+1|0,(0|Mn)!=(0|Ur))break}return(0|Mn)==(0|Ur)}function Zs(Mn,Ur,Gn){var Qr;if(!(Qr=$t[Mn+16>>2]))return $t[Mn+36>>2]=1,$t[Mn+24>>2]=Gn,void($t[Mn+16>>2]=Ur);e:{if((0|Ur)==(0|Qr)){if($t[Mn+24>>2]!=2)break e;return void($t[Mn+24>>2]=Gn)}ni[Mn+54|0]=1,$t[Mn+24>>2]=2,$t[Mn+36>>2]=$t[Mn+36>>2]+1}}function Es(Mn){var Ur,Gn;return(Mn=(Ur=$t[377])+(Gn=Mn+3&-4)|0)>>>0<=Ur>>>0&&Gn||Mn>>>0>(Gr.byteLength/65536|0)<<16>>>0&&!(0|to(0|Mn))?($t[403]=48,-1):($t[377]=Mn,Ur)}function Xl(Mn){var Ur=0;Mn=Mn||1;e:{for(;;){if(Ur=$s(Mn))break e;if(!(Ur=$t[528]))break;al[0|Ur]()}zo(),wo()}return Ur}function xl(Mn){var Ur,Gn;return $t[(Mn|=0)>>2]=1392,Ur=$t[Mn+4>>2]-12|0,Gn=$t[Ur+8>>2]-1|0,$t[Ur+8>>2]=Gn,(0|Gn)<0&&ao(Ur),0|Mn}function jo(Mn){var Ur;return(-1>>>(Ur=31&Mn)&-2)<<Ur|(-1<<(Mn=0-Mn&31)&-2)>>>Mn}function ju(Mn){(Mn|=0)&&ao(Mn)}function Pl(Mn){xl(Mn|=0),ao(Mn)}function tl(Mn){return 0|Mn}function zl(Mn){ao(Mn|=0)}function Is(Mn){}zn(Ao=ta,1024,"dmVjdG9yAHN0ZDo6ZXhjZXB0aW9uAGFsbG9jYXRvcjxUPjo6YWxsb2NhdGUoc2l6ZV90IG4pICduJyBleGNlZWRzIG1heGltdW0gc3VwcG9ydGVkIHNpemUATjEwX19jeHhhYml2MTE2X19zaGltX3R5cGVfaW5mb0UAAOgEAABaBAAA3AUAAE4xMF9fY3h4YWJpdjExN19fY2xhc3NfdHlwZV9pbmZvRQAAAOgEAACIBAAAfAQAAAAAAACsBAAAAgAAAAMAAAAEAAAABQAAAAYAAAAHAAAACAAAAAkAAAAAAAAAMAUAAAIAAAAKAAAABAAAAAUAAAAGAAAACwAAAAwAAAANAAAATjEwX19jeHhhYml2MTIwX19zaV9jbGFzc190eXBlX2luZm9FAAAAAOgEAAAIBQAArAQAAAAAAABgBQAADgAAAA8AAAAQAAAAU3Q5ZXhjZXB0aW9uAAAAAMAEAABQBQAAAAAAAIwFAAABAAAAEQAAABIAAABTdDExbG9naWNfZXJyb3IA6AQAAHwFAABgBQAAAAAAAMAFAAABAAAAEwAAABIAAABTdDEybGVuZ3RoX2Vycm9yAAAAAOgEAACsBQAAjAUAAFN0OXR5cGVfaW5mbwAAAADABAAAzAU="),zn(Ao,1508,"UAhQ");var al=function(Mn){return Mn.grow=function(Ur){var Gn=this.length;return this.length=this.length+Ur,Gn},Mn.set=function(Ur,Gn){this[Ur]=Gn},Mn.get=function(Ur){return this[Ur]},Mn}([null,xl,tl,zl,Is,Is,function(Mn,Ur,Gn){Gn|=0;var Qr,qi=0,ga=0,no=0,mo=0;if(ma=Qr=ma+-64|0,qi=1,!po(Mn|=0,Ur|=0,0)&&(qi=0,Ur)){ma=qi=ma+-64|0,ga=$t[Ur>>2],no=$t[ga-4>>2],mo=$t[ga-8>>2],$t[qi+20>>2]=0,$t[qi+16>>2]=1148,$t[qi+12>>2]=Ur,$t[qi+8>>2]=1196,ga=0,qo(qi+24|0,39),Ur=Ur+mo|0;e:if(po(no,1196,0))$t[qi+56>>2]=1,al[$t[$t[no>>2]+20>>2]](no,qi+8|0,Ur,Ur,1,0),ga=$t[qi+32>>2]==1?Ur:0;else{al[$t[$t[no>>2]+24>>2]](no,qi+8|0,Ur,1,0);t:switch($t[qi+44>>2]){case 0:ga=$t[qi+48>>2]==1&&$t[qi+36>>2]==1&&$t[qi+40>>2]==1?$t[qi+28>>2]:0;break e;case 1:break t;default:break e}$t[qi+32>>2]!=1&&$t[qi+48>>2]|$t[qi+36>>2]!=1|$t[qi+40>>2]!=1||(ga=$t[qi+24>>2])}ma=qi- -64|0,qi=0,ga&&(qo(4|(Ur=Qr+8|0),52),$t[Qr+56>>2]=1,$t[Qr+20>>2]=-1,$t[Qr+16>>2]=Mn,$t[Qr+8>>2]=ga,al[$t[$t[ga>>2]+28>>2]](ga,Ur,$t[Gn>>2],1),(0|(Mn=$t[Qr+32>>2]))==1&&($t[Gn>>2]=$t[Qr+24>>2]),qi=(0|Mn)==1)}return ma=Qr- -64|0,0|qi},function(Mn,Ur,Gn,Qr,qi,ga){Gn|=0,Qr|=0,qi|=0,ga|=0,po(Mn|=0,$t[8+(Ur|=0)>>2],ga)&&yu(Ur,Gn,Qr,qi)},function(Mn,Ur,Gn,Qr,qi){if(Gn|=0,Qr|=0,qi|=0,po(Mn|=0,$t[8+(Ur|=0)>>2],qi))$t[Ur+28>>2]==1|$t[Ur+4>>2]!=(0|Gn)||($t[Ur+28>>2]=Qr);else e:if(po(Mn,$t[Ur>>2],qi)){if(!($t[Ur+16>>2]!=(0|Gn)&$t[Ur+20>>2]!=(0|Gn))){if((0|Qr)!=1)break e;return void($t[Ur+32>>2]=1)}$t[Ur+20>>2]=Gn,$t[Ur+32>>2]=Qr,$t[Ur+40>>2]=$t[Ur+40>>2]+1,$t[Ur+36>>2]!=1|$t[Ur+24>>2]!=2||(ni[Ur+54|0]=1),$t[Ur+44>>2]=4}},function(Mn,Ur,Gn,Qr){Gn|=0,Qr|=0,po(Mn|=0,$t[8+(Ur|=0)>>2],0)&&Zs(Ur,Gn,Qr)},zl,function(Mn,Ur,Gn,Qr,qi,ga){Gn|=0,Qr|=0,qi|=0,ga|=0,po(Mn|=0,$t[8+(Ur|=0)>>2],ga)?yu(Ur,Gn,Qr,qi):(Mn=$t[Mn+8>>2],al[$t[$t[Mn>>2]+20>>2]](Mn,Ur,Gn,Qr,qi,ga))},function(Mn,Ur,Gn,Qr,qi){if(Gn|=0,Qr|=0,qi|=0,po(Mn|=0,$t[8+(Ur|=0)>>2],qi))$t[Ur+28>>2]==1|$t[Ur+4>>2]!=(0|Gn)||($t[Ur+28>>2]=Qr);else e:{if(po(Mn,$t[Ur>>2],qi)){if(!($t[Ur+16>>2]!=(0|Gn)&$t[Ur+20>>2]!=(0|Gn))){if((0|Qr)!=1)break e;return void($t[Ur+32>>2]=1)}$t[Ur+32>>2]=Qr;t:if($t[Ur+44>>2]!=4){if(Ei[Ur+52>>1]=0,Mn=$t[Mn+8>>2],al[$t[$t[Mn>>2]+20>>2]](Mn,Ur,Gn,Gn,1,qi),ta[Ur+53|0]){if($t[Ur+44>>2]=3,!ta[Ur+52|0])break t;break e}$t[Ur+44>>2]=4}if($t[Ur+20>>2]=Gn,$t[Ur+40>>2]=$t[Ur+40>>2]+1,$t[Ur+36>>2]!=1|$t[Ur+24>>2]!=2)break e;return void(ni[Ur+54|0]=1)}Mn=$t[Mn+8>>2],al[$t[$t[Mn>>2]+24>>2]](Mn,Ur,Gn,Qr,qi)}},function(Mn,Ur,Gn,Qr){Gn|=0,Qr|=0,po(Mn|=0,$t[8+(Ur|=0)>>2],0)?Zs(Ur,Gn,Qr):(Mn=$t[Mn+8>>2],al[$t[$t[Mn>>2]+28>>2]](Mn,Ur,Gn,Qr))},tl,zl,function(Mn){return 1031},Pl,function(Mn){return $t[4+(Mn|=0)>>2]},Pl]);return{g:function(){},h:ju,i:function(){var Mn;return Mn=Xl(24),$t[Mn>>2]=0,$t[Mn+4>>2]=0,$t[Mn+16>>2]=0,$t[Mn+20>>2]=0,$t[Mn+8>>2]=0,$t[Mn+12>>2]=0,0|Mn},j:function(Mn,Ur,Gn){var Qr;return Mn=+Mn,Ur=+Ur,Gn=+Gn,Qr=Xl(24),Ai[Qr+16>>3]=Gn,Ai[Qr+8>>3]=Ur,Ai[Qr>>3]=Mn,0|Qr},k:function(Mn,Ur){Ur|=0,Ai[(Mn|=0)>>3]=Ai[Mn>>3]+Ai[Ur>>3],Ai[Mn+8>>3]=Ai[Mn+8>>3]+Ai[Ur+8>>3],Ai[Mn+16>>3]=Ai[Mn+16>>3]+Ai[Ur+16>>3]},l:function(Mn,Ur){Ur|=0,Ai[(Mn|=0)>>3]=Ai[Mn>>3]-Ai[Ur>>3],Ai[Mn+8>>3]=Ai[Mn+8>>3]-Ai[Ur+8>>3],Ai[Mn+16>>3]=Ai[Mn+16>>3]-Ai[Ur+16>>3]},m:function(Mn){return+Ai[(Mn|=0)>>3]},n:function(Mn,Ur){Ur=+Ur,Ai[(Mn|=0)>>3]=Ur},o:function(Mn){return+Ai[8+(Mn|=0)>>3]},p:function(Mn,Ur){Ur=+Ur,Ai[8+(Mn|=0)>>3]=Ur},q:function(Mn){return+Ai[16+(Mn|=0)>>3]},r:function(Mn,Ur){Ur=+Ur,Ai[16+(Mn|=0)>>3]=Ur},s:ju,t:function(){var Mn;return Mn=Xl(12),$t[Mn+8>>2]=0,$t[Mn>>2]=0,$t[Mn+4>>2]=0,0|Mn},u:function(Mn,Ur){Ur|=0;var Gn=0,Qr=0,qi=0,ga=0,no=0,mo=0;e:if((0|(Gn=$t[4+(Mn|=0)>>2]))==$t[Mn+8>>2]){t:{if((qi=1+(Gn=(0|(mo=Gn-(Qr=$t[Mn>>2])|0))/24|0)|0)>>>0<178956971){if(ga=Gn<<1,qi=Gn>>>0<89478485?qi>>>0<ga>>>0?ga:qi:178956970){if(qi>>>0>=178956971)break t;ga=Xl(Ea(qi,24))}else ga=0;Gn=ga+Ea(Gn,24)|0,no=$t[Ur+4>>2],$t[Gn>>2]=$t[Ur>>2],$t[Gn+4>>2]=no,no=$t[Ur+20>>2],$t[Gn+16>>2]=$t[Ur+16>>2],$t[Gn+20>>2]=no,no=$t[Ur+12>>2],$t[Gn+8>>2]=$t[Ur+8>>2],$t[Gn+12>>2]=no,Ur=Gn+Ea((0|mo)/-24|0,24)|0,(0|mo)>0&&Ps(Ur,Qr,mo),$t[Mn+8>>2]=ga+Ea(qi,24),$t[Mn+4>>2]=Gn+24,$t[Mn>>2]=Ur,Qr&&ao(Qr);break e}wl(1024),wo()}wl(1046),wo()}else Qr=$t[Ur+4>>2],$t[Gn>>2]=$t[Ur>>2],$t[Gn+4>>2]=Qr,Qr=$t[Ur+20>>2],$t[Gn+16>>2]=$t[Ur+16>>2],$t[Gn+20>>2]=Qr,Qr=$t[Ur+12>>2],$t[Gn+8>>2]=$t[Ur+8>>2],$t[Gn+12>>2]=Qr,$t[Mn+4>>2]=Gn+24},v:function(Mn){var Ur=0;(Mn|=0)&&((Ur=$t[Mn>>2])&&($t[Mn+4>>2]=Ur,ao(Ur)),ao(Mn))},w:function(){return 0|Xl(1)},x:function(Mn,Ur){Mn|=0;var Gn=0,Qr=0,qi=0,ga=0,no=0,mo=0,Go=0,Uo=0,Ns=0,jl=0,Bl=0,Jl=0;if(Mn=$t[(Ur|=0)>>2],(Qr=(0|(qi=$t[Ur+4>>2]-Mn|0))/24|0)>>>0>=2){if(!(qi-24>>>0<24)){if(Gn=Ai[Mn+8>>3],Ur=1,Bl=1&(Qr=Qr-1|0),no=Ai[Mn>>3],qi-48>>>0<24)mo=Gn;else for(Jl=-2&Qr,Qr=0,Go=no,Uo=Gn;qi=Mn+Ea(Ur,24)|0,ga=.5*((no=Ai[qi+24>>3])-(Ns=Ai[qi>>3]))*((jl=Ai[qi+8>>3]-Gn)+((mo=Ai[qi+32>>3])-Gn))+(.5*(Ns-Go)*(Uo-Gn+jl)+ga),Ur=Ur+2|0,Go=no,Uo=mo,(0|Jl)!=(0|(Qr=Qr+2|0)););Bl&&(Mn=Mn+Ea(Ur,24)|0,ga=.5*(Ai[Mn>>3]-no)*(mo-Gn+(Ai[Mn+8>>3]-Gn))+ga)}Gn=ga<0?-ga:ga}else Gn=0;return+Gn},y:function(Mn,Ur,Gn){Mn|=0,Ur|=0;var Qr,qi=0,ga=0,no=0,mo=0,Go=0,Uo=0,Ns=0;if((Qr=((Mn=$t[4+(Gn|=0)>>2])-(Gn=$t[Gn>>2])|0)/24|0)>>>0>=3)for(Mn=Qr-1|0,qi=Ai[Ur+8>>3],Ns=Ai[Ur>>3],Ur=0;mo=Gn+Ea(Mn,24)|0,no=Ai[mo+8>>3],Mn=Ur,Ur=Gn+Ea(Ur,24)|0,!(qi<no&(ga=Ai[Ur+8>>3])<=qi)&(!(qi>=no)|!(qi<ga))||Ns-(Go=Ai[Ur>>3])<(qi-ga)*(Ai[mo>>3]-Go)/(no-ga)&&(Uo^=1),(0|Qr)!=(0|(Ur=Mn+1|0)););return 1&Uo},z:ju,A:al,B:$s}}(_o)}(gn)}})}}}).then(function(xo){return xo}).then(ls,function(xo){Ue("failed to asynchronously prepare wasm: "+xo),Dn(xo)})}var yo={a:gn};if(pn++,n.monitorRunDependencies&&n.monitorRunDependencies(pn),n.instantiateWasm)try{return n.instantiateWasm(yo,ki)}catch(ls){return Ue("Module.instantiateWasm callback failed with error: "+ls),!1}(ne||typeof Ve.instantiateStreaming!="function"||an.startsWith(Rn)||an.startsWith("file://")||typeof fetch!="function"?Ja(Aa):fetch(an,{credentials:"same-origin"}).then(function(ls){return Ve.instantiateStreaming(ls,yo).then(Aa,function(xo){return Ue("wasm streaming compile failed: "+xo),Ue("falling back to ArrayBuffer instantiation"),Ja(Aa)})})).catch(c)})(),n.___wasm_call_ctors=function(){return(n.___wasm_call_ctors=n.asm.g).apply(null,arguments)};var Xn,Kn=n._emscripten_bind_VoidPtr___destroy___0=function(){return(Kn=n._emscripten_bind_VoidPtr___destroy___0=n.asm.h).apply(null,arguments)},Vn=n._emscripten_bind_McGePoint3d_McGePoint3d_0=function(){return(Vn=n._emscripten_bind_McGePoint3d_McGePoint3d_0=n.asm.i).apply(null,arguments)},Yn=n._emscripten_bind_McGePoint3d_McGePoint3d_3=function(){return(Yn=n._emscripten_bind_McGePoint3d_McGePoint3d_3=n.asm.j).apply(null,arguments)},Vr=n._emscripten_bind_McGePoint3d_op_add_1=function(){return(Vr=n._emscripten_bind_McGePoint3d_op_add_1=n.asm.k).apply(null,arguments)},xi=n._emscripten_bind_McGePoint3d_op_sub_1=function(){return(xi=n._emscripten_bind_McGePoint3d_op_sub_1=n.asm.l).apply(null,arguments)},Si=n._emscripten_bind_McGePoint3d_get_x_0=function(){return(Si=n._emscripten_bind_McGePoint3d_get_x_0=n.asm.m).apply(null,arguments)},qn=n._emscripten_bind_McGePoint3d_set_x_1=function(){return(qn=n._emscripten_bind_McGePoint3d_set_x_1=n.asm.n).apply(null,arguments)},ia=n._emscripten_bind_McGePoint3d_get_y_0=function(){return(ia=n._emscripten_bind_McGePoint3d_get_y_0=n.asm.o).apply(null,arguments)},Wi=n._emscripten_bind_McGePoint3d_set_y_1=function(){return(Wi=n._emscripten_bind_McGePoint3d_set_y_1=n.asm.p).apply(null,arguments)},ha=n._emscripten_bind_McGePoint3d_get_z_0=function(){return(ha=n._emscripten_bind_McGePoint3d_get_z_0=n.asm.q).apply(null,arguments)},ai=n._emscripten_bind_McGePoint3d_set_z_1=function(){return(ai=n._emscripten_bind_McGePoint3d_set_z_1=n.asm.r).apply(null,arguments)},Ia=n._emscripten_bind_McGePoint3d___destroy___0=function(){return(Ia=n._emscripten_bind_McGePoint3d___destroy___0=n.asm.s).apply(null,arguments)},fi=n._emscripten_bind_McGePoint3dArray_McGePoint3dArray_0=function(){return(fi=n._emscripten_bind_McGePoint3dArray_McGePoint3dArray_0=n.asm.t).apply(null,arguments)},An=n._emscripten_bind_McGePoint3dArray_append_1=function(){return(An=n._emscripten_bind_McGePoint3dArray_append_1=n.asm.u).apply(null,arguments)},sa=n._emscripten_bind_McGePoint3dArray___destroy___0=function(){return(sa=n._emscripten_bind_McGePoint3dArray___destroy___0=n.asm.v).apply(null,arguments)},Nn=n._emscripten_bind_McGeTool_McGeTool_0=function(){return(Nn=n._emscripten_bind_McGeTool_McGeTool_0=n.asm.w).apply(null,arguments)},fn=n._emscripten_bind_McGeTool_calcArea_1=function(){return(fn=n._emscripten_bind_McGeTool_calcArea_1=n.asm.x).apply(null,arguments)},un=n._emscripten_bind_McGeTool_pointInPolyline_2=function(){return(un=n._emscripten_bind_McGeTool_pointInPolyline_2=n.asm.y).apply(null,arguments)},Ln=n._emscripten_bind_McGeTool___destroy___0=function(){return(Ln=n._emscripten_bind_McGeTool___destroy___0=n.asm.z).apply(null,arguments)},hr=n._malloc=function(){return(hr=n._malloc=n.asm.B).apply(null,arguments)};function hi(){function ki(){if(!Xn&&(Xn=!0,n.calledRun=!0,!ue)){if(hn(It),u(n),n.onRuntimeInitialized&&n.onRuntimeInitialized(),n.postRun)for(typeof n.postRun=="function"&&(n.postRun=[n.postRun]);n.postRun.length;){var Aa=n.postRun.shift();nn.unshift(Aa)}hn(nn)}}if(!(0<pn)){if(n.preRun)for(typeof n.preRun=="function"&&(n.preRun=[n.preRun]);n.preRun.length;)tn();hn(kt),0<pn||(n.setStatus?(n.setStatus("Running..."),setTimeout(function(){setTimeout(function(){n.setStatus("")},1),ki()},1)):ki())}}if(_n=function ki(){Xn||hi(),Xn||(_n=ki)},n.run=hi,n.preInit)for(typeof n.preInit=="function"&&(n.preInit=[n.preInit]);0<n.preInit.length;)n.preInit.pop()();function bi(){}function Ra(ki){return(ki||bi).F}function so(ki,Aa){var Ja=Ra(Aa),yo=Ja[ki];return yo||((yo=Object.create((Aa||bi).prototype)).C=ki,Ja[ki]=yo)}function Pi(){throw"cannot construct a VoidPtr, no constructor in IDL"}function oi(ki,Aa,Ja){ki&&typeof ki=="object"&&(ki=ki.C),Aa&&typeof Aa=="object"&&(Aa=Aa.C),Ja&&typeof Ja=="object"&&(Ja=Ja.C),this.C=ki===void 0?Vn():Aa===void 0?_emscripten_bind_McGePoint3d_McGePoint3d_1(ki):Ja===void 0?_emscripten_bind_McGePoint3d_McGePoint3d_2(ki,Aa):Yn(ki,Aa,Ja),Ra(oi)[this.C]=this}function Ni(){this.C=fi(),Ra(Ni)[this.C]=this}function za(){this.C=Nn(),Ra(za)[this.C]=this}return hi(),bi.prototype=Object.create(bi.prototype),bi.prototype.constructor=bi,bi.prototype.D=bi,bi.F={},n.WrapperObject=bi,n.getCache=Ra,n.wrapPointer=so,n.castObject=function(ki,Aa){return so(ki.C,Aa)},n.NULL=so(0),n.destroy=function(ki){if(!ki.__destroy__)throw"Error: Cannot destroy object. (Did you create it yourself?)";ki.__destroy__(),delete Ra(ki.D)[ki.C]},n.compare=function(ki,Aa){return ki.C===Aa.C},n.getPointer=function(ki){return ki.C},n.getClass=function(ki){return ki.D},Pi.prototype=Object.create(bi.prototype),Pi.prototype.constructor=Pi,Pi.prototype.D=Pi,Pi.F={},n.VoidPtr=Pi,Pi.prototype.__destroy__=function(){Kn(this.C)},oi.prototype=Object.create(bi.prototype),oi.prototype.constructor=oi,oi.prototype.D=oi,oi.F={},n.McGePoint3d=oi,oi.prototype.op_add=function(ki){var Aa=this.C;ki&&typeof ki=="object"&&(ki=ki.C),Vr(Aa,ki)},oi.prototype.op_sub=function(ki){var Aa=this.C;ki&&typeof ki=="object"&&(ki=ki.C),xi(Aa,ki)},oi.prototype.get_x=oi.prototype.H=function(){return Si(this.C)},oi.prototype.set_x=oi.prototype.R=function(ki){var Aa=this.C;ki&&typeof ki=="object"&&(ki=ki.C),qn(Aa,ki)},Object.defineProperty(oi.prototype,"x",{get:oi.prototype.H,set:oi.prototype.R}),oi.prototype.get_y=oi.prototype.I=function(){return ia(this.C)},oi.prototype.set_y=oi.prototype.S=function(ki){var Aa=this.C;ki&&typeof ki=="object"&&(ki=ki.C),Wi(Aa,ki)},Object.defineProperty(oi.prototype,"y",{get:oi.prototype.I,set:oi.prototype.S}),oi.prototype.get_z=oi.prototype.J=function(){return ha(this.C)},oi.prototype.set_z=oi.prototype.T=function(ki){var Aa=this.C;ki&&typeof ki=="object"&&(ki=ki.C),ai(Aa,ki)},Object.defineProperty(oi.prototype,"z",{get:oi.prototype.J,set:oi.prototype.T}),oi.prototype.__destroy__=function(){Ia(this.C)},Ni.prototype=Object.create(bi.prototype),Ni.prototype.constructor=Ni,Ni.prototype.D=Ni,Ni.F={},n.McGePoint3dArray=Ni,Ni.prototype.append=Ni.prototype.append=function(ki){var Aa=this.C;ki&&typeof ki=="object"&&(ki=ki.C),An(Aa,ki)},Ni.prototype.__destroy__=function(){sa(this.C)},za.prototype=Object.create(bi.prototype),za.prototype.constructor=za,za.prototype.D=za,za.F={},n.McGeTool=za,za.prototype.calcArea=function(ki){var Aa=this.C;return ki&&typeof ki=="object"&&(ki=ki.C),fn(Aa,ki)},za.prototype.pointInPolyline=function(ki,Aa){var Ja=this.C;return ki&&typeof ki=="object"&&(ki=ki.C),Aa&&typeof Aa=="object"&&(Aa=Aa.C),!!un(Ja,ki,Aa)},za.prototype.__destroy__=function(){Ln(this.C)},l.ready});return typeof exports=="object"&&typeof module=="object"?module.exports=e:typeof exports=="object"&&(exports.mxcadassembly=e),e()}function loadMxcadAssembly(){mxcadassemblyinit().then(function(t){store.commit("setMxassembly",t)})}function _load(t){window.MxDocumentReady=void 0,window.MxUiMain=e=>{const l=e("./MxFun").MxFun;window.THREE=l.getTHREE(),store.commit("setMxFun",l),store.events.emit("MxUiMain",e),window.MxUiMain=void 0},window.MxMain=e=>(store.events.emit("MxMain",e),window.MxMain=void 0,registerMxDbEntity(),t(),0),mxfun(),loadMxcadAssembly()}async function loadCoreCode(){return new Promise(async(t,e)=>{try{if(store.state.MxFun)return console.warn("程序已自动调用loadCoreCode 无需主动调用 | The program has automatically called loadCoreCode without actively calling it"),void t();_load(t)}catch(l){e({code:"error",msg:l})}})}function createCanvas(t="mx-canvas"){let e=document.getElementById(t);return e||(console.warn("没有找到id为:"+t+"的canvas元素"),(e=document.createElement("canvas")).id=t),e}function createCanvasParent(t=createCanvas()){let e;return t||(t=createCanvas()),t.parentNode?e=t.parentNode:((e=document.createElement("div")).style.height="80vh",e.appendChild(t)),e}async function dynamicImport(t){let e;switch(t){case"jquery":e=await dynamicImportJquery();break;case"element-resize-event-polyfill":e=await dynamicImportResize()}return e}async function dynamicImportResize(){try{const t=await Promise.resolve().then(function(){return elementResizeEventPolyfill_umd_min$2});return t.default?t.default:t}catch(t){console.log("import动态导入:element-resize-event-polyfill失败!",t)}}async function dynamicImportJquery(){try{const t=await Promise.resolve().then(function(){return jquery$1$1});return t.default?t.default:t}catch(t){console.log("import动态导入:jquery失败!",t)}}window.$=window.jQuery=jquery$1,_load(()=>{});var lodash=createCommonjsModule(function(t,e){(function(){var l,n="Expected a function",u="__lodash_hash_undefined__",c="__lodash_placeholder__",y=16,b=32,m=64,O=128,N=256,L=1/0,G=9007199254740991,q=NaN,J=4294967295,fe=[["ary",O],["bind",1],["bindKey",2],["curry",8],["curryRight",y],["flip",512],["partial",b],["partialRight",m],["rearg",N]],ve="[object Arguments]",ne="[object Array]",Ue="[object Boolean]",De="[object Date]",Ve="[object Error]",rt="[object Function]",Ae="[object GeneratorFunction]",Te="[object Map]",Xe="[object Number]",ie="[object Object]",ue="[object Promise]",pt="[object RegExp]",mt="[object Set]",Tt="[object String]",kt="[object Symbol]",It="[object WeakMap]",nn="[object ArrayBuffer]",tn="[object DataView]",pn="[object Float32Array]",_n="[object Float64Array]",Dn="[object Int8Array]",an="[object Int16Array]",Rn="[object Int32Array]",Lt="[object Uint8Array]",wn="[object Uint8ClampedArray]",hn="[object Uint16Array]",xn="[object Uint32Array]",$n=/\b__p \+= '';/g,Xr=/\b(__p \+=) '' \+/g,ti=/(__e\(.*?\)|\b__t\)) \+\n'';/g,gn=/&(?:amp|lt|gt|quot|#39);/g,Xn=/[&<>"']/g,Kn=RegExp(gn.source),Vn=RegExp(Xn.source),Yn=/<%-([\s\S]+?)%>/g,Vr=/<%([\s\S]+?)%>/g,xi=/<%=([\s\S]+?)%>/g,Si=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,qn=/^\w*$/,ia=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Wi=/[\\^$.*+?()[\]{}|]/g,ha=RegExp(Wi.source),ai=/^\s+/,Ia=/\s/,fi=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,An=/\{\n\/\* \[wrapped with (.+)\] \*/,sa=/,? & /,Nn=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,fn=/[()=,{}\[\]\/\s]/,un=/\\(\\)?/g,Ln=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,hr=/\w*$/,hi=/^[-+]0x[0-9a-f]+$/i,bi=/^0b[01]+$/i,Ra=/^\[object .+?Constructor\]$/,so=/^0o[0-7]+$/i,Pi=/^(?:0|[1-9]\d*)$/,oi=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Ni=/($^)/,za=/['\n\r\u2028\u2029\\]/g,ki="\\ud800-\\udfff",Aa="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",Ja="\\u2700-\\u27bf",yo="a-z\\xdf-\\xf6\\xf8-\\xff",ls="A-Z\\xc0-\\xd6\\xd8-\\xde",xo="\\ufe0e\\ufe0f",_o="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Ao="["+ki+"]",il="["+_o+"]",zr="["+Aa+"]",zn="\\d+",Un="["+Ja+"]",Gr="["+yo+"]",ni="[^"+ki+_o+zn+Ja+yo+ls+"]",Ei="\\ud83c[\\udffb-\\udfff]",$t="[^"+ki+"]",ta="(?:\\ud83c[\\udde6-\\uddff]){2}",Hi="[\\ud800-\\udbff][\\udc00-\\udfff]",Ai="["+ls+"]",Ea="\\u200d",wo="(?:"+Gr+"|"+ni+")",to="(?:"+Ai+"|"+ni+")",zo="(?:['’](?:d|ll|m|re|s|t|ve))?",Po="(?:['’](?:D|LL|M|RE|S|T|VE))?",Lo="(?:"+zr+"|"+Ei+")?",Wo="["+xo+"]?",ma=Wo+Lo+"(?:"+Ea+"(?:"+[$t,ta,Hi].join("|")+")"+Wo+Lo+")*",$s="(?:"+[Un,ta,Hi].join("|")+")"+ma,ao="(?:"+[$t+zr+"?",zr,ta,Hi,Ao].join("|")+")",Ps=RegExp("['’]","g"),qo=RegExp(zr,"g"),wl=RegExp(Ei+"(?="+Ei+")|"+ao+ma,"g"),yu=RegExp([Ai+"?"+Gr+"+"+zo+"(?="+[il,Ai,"$"].join("|")+")",to+"+"+Po+"(?="+[il,Ai+wo,"$"].join("|")+")",Ai+"?"+wo+"+"+zo,Ai+"+"+Po,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",zn,$s].join("|"),"g"),po=RegExp("["+Ea+ki+Aa+xo+"]"),Zs=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Es=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Xl=-1,xl={};xl[pn]=xl[_n]=xl[Dn]=xl[an]=xl[Rn]=xl[Lt]=xl[wn]=xl[hn]=xl[xn]=!0,xl[ve]=xl[ne]=xl[nn]=xl[Ue]=xl[tn]=xl[De]=xl[Ve]=xl[rt]=xl[Te]=xl[Xe]=xl[ie]=xl[pt]=xl[mt]=xl[Tt]=xl[It]=!1;var jo={};jo[ve]=jo[ne]=jo[nn]=jo[tn]=jo[Ue]=jo[De]=jo[pn]=jo[_n]=jo[Dn]=jo[an]=jo[Rn]=jo[Te]=jo[Xe]=jo[ie]=jo[pt]=jo[mt]=jo[Tt]=jo[kt]=jo[Lt]=jo[wn]=jo[hn]=jo[xn]=!0,jo[Ve]=jo[rt]=jo[It]=!1;var ju={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Pl=parseFloat,tl=parseInt,zl=typeof commonjsGlobal=="object"&&commonjsGlobal&&commonjsGlobal.Object===Object&&commonjsGlobal,Is=typeof self=="object"&&self&&self.Object===Object&&self,al=zl||Is||Function("return this")(),Mn=e&&!e.nodeType&&e,Ur=Mn&&t&&!t.nodeType&&t,Gn=Ur&&Ur.exports===Mn,Qr=Gn&&zl.process,qi=function(){try{return Ur&&Ur.require&&Ur.require("util").types||Qr&&Qr.binding&&Qr.binding("util")}catch{}}(),ga=qi&&qi.isArrayBuffer,no=qi&&qi.isDate,mo=qi&&qi.isMap,Go=qi&&qi.isRegExp,Uo=qi&&qi.isSet,Ns=qi&&qi.isTypedArray;function jl(jt,dn,yn){switch(yn.length){case 0:return jt.call(dn);case 1:return jt.call(dn,yn[0]);case 2:return jt.call(dn,yn[0],yn[1]);case 3:return jt.call(dn,yn[0],yn[1],yn[2])}return jt.apply(dn,yn)}function Bl(jt,dn,yn,In){for(var vr=-1,Jn=jt==null?0:jt.length;++vr<Jn;){var li=jt[vr];dn(In,li,yn(li),jt)}return In}function Jl(jt,dn){for(var yn=-1,In=jt==null?0:jt.length;++yn<In&&dn(jt[yn],yn,jt)!==!1;);return jt}function mu(jt,dn){for(var yn=-1,In=jt==null?0:jt.length;++yn<In;)if(!dn(jt[yn],yn,jt))return!1;return!0}function Ol(jt,dn){for(var yn=-1,In=jt==null?0:jt.length,vr=0,Jn=[];++yn<In;){var li=jt[yn];dn(li,yn,jt)&&(Jn[vr++]=li)}return Jn}function bu(jt,dn){return!(jt==null||!jt.length)&&Vl(jt,dn,0)>-1}function Bu(jt,dn,yn){for(var In=-1,vr=jt==null?0:jt.length;++In<vr;)if(yn(dn,jt[In]))return!0;return!1}function hl(jt,dn){for(var yn=-1,In=jt==null?0:jt.length,vr=Array(In);++yn<In;)vr[yn]=dn(jt[yn],yn,jt);return vr}function vu(jt,dn){for(var yn=-1,In=dn.length,vr=jt.length;++yn<In;)jt[vr+yn]=dn[yn];return jt}function Ku(jt,dn,yn,In){var vr=-1,Jn=jt==null?0:jt.length;for(In&&Jn&&(yn=jt[++vr]);++vr<Jn;)yn=dn(yn,jt[vr],vr,jt);return yn}function Ul(jt,dn,yn,In){var vr=jt==null?0:jt.length;for(In&&vr&&(yn=jt[--vr]);vr--;)yn=dn(yn,jt[vr],vr,jt);return yn}function ad(jt,dn){for(var yn=-1,In=jt==null?0:jt.length;++yn<In;)if(dn(jt[yn],yn,jt))return!0;return!1}var jc=Ll("length");function js(jt,dn,yn){var In;return yn(jt,function(vr,Jn,li){if(dn(vr,Jn,li))return In=Jn,!1}),In}function co(jt,dn,yn,In){for(var vr=jt.length,Jn=yn+(In?1:-1);In?Jn--:++Jn<vr;)if(dn(jt[Jn],Jn,jt))return Jn;return-1}function Vl(jt,dn,yn){return dn==dn?function(In,vr,Jn){for(var li=Jn-1,xa=In.length;++li<xa;)if(In[li]===vr)return li;return-1}(jt,dn,yn):co(jt,yd,yn)}function Gc(jt,dn,yn,In){for(var vr=yn-1,Jn=jt.length;++vr<Jn;)if(In(jt[vr],dn))return vr;return-1}function yd(jt){return jt!=jt}function Ql(jt,dn){var yn=jt==null?0:jt.length;return yn?Wu(jt,dn)/yn:q}function Ll(jt){return function(dn){return dn==null?l:dn[jt]}}function Au(jt){return function(dn){return jt==null?l:jt[dn]}}function jd(jt,dn,yn,In,vr){return vr(jt,function(Jn,li,xa){yn=In?(In=!1,Jn):dn(yn,Jn,li,xa)}),yn}function Wu(jt,dn){for(var yn,In=-1,vr=jt.length;++In<vr;){var Jn=dn(jt[In]);Jn!==l&&(yn=yn===l?Jn:yn+Jn)}return yn}function ud(jt,dn){for(var yn=-1,In=Array(jt);++yn<jt;)In[yn]=dn(yn);return In}function Xc(jt){return jt&&jt.slice(0,Qe(jt)+1).replace(ai,"")}function yi(jt){return function(dn){return jt(dn)}}function mc(jt,dn){return hl(dn,function(yn){return jt[yn]})}function Su(jt,dn){return jt.has(dn)}function Yh(jt,dn){for(var yn=-1,In=jt.length;++yn<In&&Vl(dn,jt[yn],0)>-1;);return yn}function ka(jt,dn){for(var yn=jt.length;yn--&&Vl(dn,jt[yn],0)>-1;);return yn}var pl=Au({À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"}),Il=Au({"&":"&","<":"<",">":">",'"':""","'":"'"});function Ss(jt){return"\\"+ju[jt]}function Vo(jt){return po.test(jt)}function iu(jt){var dn=-1,yn=Array(jt.size);return jt.forEach(function(In,vr){yn[++dn]=[vr,In]}),yn}function Tu(jt,dn){return function(yn){return jt(dn(yn))}}function wt(jt,dn){for(var yn=-1,In=jt.length,vr=0,Jn=[];++yn<In;){var li=jt[yn];li!==dn&&li!==c||(jt[yn]=c,Jn[vr++]=yn)}return Jn}function qt(jt){var dn=-1,yn=Array(jt.size);return jt.forEach(function(In){yn[++dn]=In}),yn}function Cn(jt){return Vo(jt)?function(dn){for(var yn=wl.lastIndex=0;wl.test(dn);)++yn;return yn}(jt):jc(jt)}function Pn(jt){return Vo(jt)?function(dn){return dn.match(wl)||[]}(jt):function(dn){return dn.split("")}(jt)}function Qe(jt){for(var dn=jt.length;dn--&&Ia.test(jt.charAt(dn)););return dn}var yt=Au({"&":"&","<":"<",">":">",""":'"',"'":"'"}),Rt=function jt(dn){var yn,In=(dn=dn==null?al:Rt.defaults(al.Object(),dn,Rt.pick(al,Es))).Array,vr=dn.Date,Jn=dn.Error,li=dn.Function,xa=dn.Math,Ri=dn.Object,fa=dn.RegExp,oo=dn.String,ts=dn.TypeError,bl=In.prototype,nl=li.prototype,Fs=Ri.prototype,eu=dn["__core-js_shared__"],Gs=nl.toString,As=Fs.hasOwnProperty,yl=0,Lc=(yn=/[^.]+$/.exec(eu&&eu.keys&&eu.keys.IE_PROTO||""))?"Symbol(src)_1."+yn:"",vl=Fs.toString,du=Gs.call(Ri),ac=al._,Xu=fa("^"+Gs.call(As).replace(Wi,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ju=Gn?dn.Buffer:l,Vu=dn.Symbol,Nl=dn.Uint8Array,$l=Ju?Ju.allocUnsafe:l,hu=Tu(Ri.getPrototypeOf,Ri),Qu=Ri.create,Gu=Fs.propertyIsEnumerable,Bs=bl.splice,su=Vu?Vu.isConcatSpreadable:l,ku=Vu?Vu.iterator:l,Hl=Vu?Vu.toStringTag:l,Uc=function(){try{var Ze=Qo(Ri,"defineProperty");return Ze({},"",{}),Ze}catch{}}(),Wl=dn.clearTimeout!==al.clearTimeout&&dn.clearTimeout,cd=vr&&vr.now!==al.Date.now&&vr.now,wu=dn.setTimeout!==al.setTimeout&&dn.setTimeout,oc=xa.ceil,gc=xa.floor,dd=Ri.getOwnPropertySymbols,Jc=Ju?Ju.isBuffer:l,sc=dn.isFinite,qc=bl.join,vd=Tu(Ri.keys,Ri),Pu=xa.max,ol=xa.min,od=vr.now,qu=dn.parseInt,ah=xa.random,Mi=bl.reverse,wa=Qo(dn,"DataView"),la=Qo(dn,"Map"),Wa=Qo(dn,"Promise"),lo=Qo(dn,"Set"),Jo=Qo(dn,"WeakMap"),Xo=Qo(Ri,"create"),ei=Jo&&new Jo,ii={},Ma=$d(wa),pa=$d(la),ca=$d(Wa),uo=$d(lo),ya=$d(Jo),Oo=Vu?Vu.prototype:l,Io=Oo?Oo.valueOf:l,Ws=Oo?Oo.toString:l;function gr(Ze){if($u(Ze)&&!kl(Ze)&&!(Ze instanceof vs)){if(Ze instanceof Fo)return Ze;if(As.call(Ze,"__wrapped__"))return Vc(Ze)}return new Fo(Ze)}var ws=function(){function Ze(){}return function(vt){if(!bc(vt))return{};if(Qu)return Qu(vt);Ze.prototype=vt;var on=new Ze;return Ze.prototype=l,on}}();function io(){}function Fo(Ze,vt){this.__wrapped__=Ze,this.__actions__=[],this.__chain__=!!vt,this.__index__=0,this.__values__=l}function vs(Ze){this.__wrapped__=Ze,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=J,this.__views__=[]}function Gl(Ze){var vt=-1,on=Ze==null?0:Ze.length;for(this.clear();++vt<on;){var Fn=Ze[vt];this.set(Fn[0],Fn[1])}}function Mu(Ze){var vt=-1,on=Ze==null?0:Ze.length;for(this.clear();++vt<on;){var Fn=Ze[vt];this.set(Fn[0],Fn[1])}}function gu(Ze){var vt=-1,on=Ze==null?0:Ze.length;for(this.clear();++vt<on;){var Fn=Ze[vt];this.set(Fn[0],Fn[1])}}function Nu(Ze){var vt=-1,on=Ze==null?0:Ze.length;for(this.__data__=new gu;++vt<on;)this.add(Ze[vt])}function lc(Ze){var vt=this.__data__=new Mu(Ze);this.size=vt.size}function Du(Ze,vt){var on=kl(Ze),Fn=!on&&Yc(Ze),Qn=!on&&!Fn&&zh(Ze),mi=!on&&!Fn&&!Qn&&sm(Ze),ra=on||Fn||Qn||mi,Ca=ra?ud(Ze.length,oo):[],La=Ca.length;for(var Oa in Ze)!vt&&!As.call(Ze,Oa)||ra&&(Oa=="length"||Qn&&(Oa=="offset"||Oa=="parent")||mi&&(Oa=="buffer"||Oa=="byteLength"||Oa=="byteOffset")||fl(Oa,La))||Ca.push(Oa);return Ca}function Zh(Ze){var vt=Ze.length;return vt?Ze[ql(0,vt-1)]:l}function uc(Ze,vt,on){(on!==l&&!dh(Ze[vt],on)||on===l&&!(vt in Ze))&&Fc(Ze,vt,on)}function Ds(Ze,vt,on){var Fn=Ze[vt];As.call(Ze,vt)&&dh(Fn,on)&&(on!==l||vt in Ze)||Fc(Ze,vt,on)}function Op(Ze,vt){for(var on=Ze.length;on--;)if(dh(Ze[on][0],vt))return on;return-1}function Kh(Ze,vt,on,Fn){return oh(Ze,function(Qn,mi,ra){vt(Fn,Qn,on(Qn),ra)}),Fn}function up(Ze,vt){return Ze&&$c(vt,Ic(vt),Ze)}function Fc(Ze,vt,on){vt=="__proto__"&&Uc?Uc(Ze,vt,{configurable:!0,enumerable:!0,value:on,writable:!0}):Ze[vt]=on}function fh(Ze,vt){for(var on=-1,Fn=vt.length,Qn=In(Fn),mi=Ze==null;++on<Fn;)Qn[on]=mi?l:$m(Ze,vt[on]);return Qn}function Rd(Ze,vt,on){return Ze==Ze&&(on!==l&&(Ze=Ze<=on?Ze:on),vt!==l&&(Ze=Ze>=vt?Ze:vt)),Ze}function hd(Ze,vt,on,Fn,Qn,mi){var ra,Ca=1&vt,La=2&vt,Oa=4&vt;if(on&&(ra=Qn?on(Ze,Fn,Qn,mi):on(Ze)),ra!==l)return ra;if(!bc(Ze))return Ze;var fo=kl(Ze);if(fo){if(ra=function(Mo){var es=Mo.length,Qs=new Mo.constructor(es);return es&&typeof Mo[0]=="string"&&As.call(Mo,"index")&&(Qs.index=Mo.index,Qs.input=Mo.input),Qs}(Ze),!Ca)return Qc(Ze,ra)}else{var Ho=is(Ze),qs=Ho==rt||Ho==Ae;if(zh(Ze))return Fd(Ze,Ca);if(Ho==ie||Ho==ve||qs&&!Qn){if(ra=La||qs?{}:ps(Ze),!Ca)return La?function(Mo,es){return $c(Mo,rs(Mo),es)}(Ze,function(Mo,es){return Mo&&$c(es,Zc(es),Mo)}(ra,Ze)):function(Mo,es){return $c(Mo,Za(Mo),es)}(Ze,up(ra,Ze))}else{if(!jo[Ho])return Qn?Ze:{};ra=function(Mo,es,Qs){var Ms,Tl=Mo.constructor;switch(es){case nn:return Bd(Mo);case Ue:case De:return new Tl(+Mo);case tn:return function(Al,au){var sl=au?Bd(Al.buffer):Al.buffer;return new Al.constructor(sl,Al.byteOffset,Al.byteLength)}(Mo,Qs);case pn:case _n:case Dn:case an:case Rn:case Lt:case wn:case hn:case xn:return sf(Mo,Qs);case Te:return new Tl;case Xe:case Tt:return new Tl(Mo);case pt:return function(Al){var au=new Al.constructor(Al.source,hr.exec(Al));return au.lastIndex=Al.lastIndex,au}(Mo);case mt:return new Tl;case kt:return Ms=Mo,Io?Ri(Io.call(Ms)):{}}}(Ze,Ho,Ca)}}mi||(mi=new lc);var Ys=mi.get(Ze);if(Ys)return Ys;mi.set(Ze,ra),Lf(Ze)?Ze.forEach(function(Mo){ra.add(hd(Mo,vt,on,Mo,Ze,mi))}):am(Ze)&&Ze.forEach(function(Mo,es){ra.set(es,hd(Mo,vt,on,es,Ze,mi))});var _l=fo?l:(Oa?La?Fa:Ta:La?Zc:Ic)(Ze);return Jl(_l||Ze,function(Mo,es){_l&&(Mo=Ze[es=Mo]),Ds(ra,es,hd(Mo,vt,on,es,Ze,mi))}),ra}function ef(Ze,vt,on){var Fn=on.length;if(Ze==null)return!Fn;for(Ze=Ri(Ze);Fn--;){var Qn=on[Fn],mi=vt[Qn],ra=Ze[Qn];if(ra===l&&!(Qn in Ze)||!mi(ra))return!1}return!0}function Cf(Ze,vt,on){if(typeof Ze!="function")throw new ts(n);return Uu(function(){Ze.apply(l,on)},vt)}function _d(Ze,vt,on,Fn){var Qn=-1,mi=bu,ra=!0,Ca=Ze.length,La=[],Oa=vt.length;if(!Ca)return La;on&&(vt=hl(vt,yi(on))),Fn?(mi=Bu,ra=!1):vt.length>=200&&(mi=Su,ra=!1,vt=new Nu(vt));e:for(;++Qn<Ca;){var fo=Ze[Qn],Ho=on==null?fo:on(fo);if(fo=Fn||fo!==0?fo:0,ra&&Ho==Ho){for(var qs=Oa;qs--;)if(vt[qs]===Ho)continue e;La.push(fo)}else mi(vt,Ho,Fn)||La.push(fo)}return La}gr.templateSettings={escape:Yn,evaluate:Vr,interpolate:xi,variable:"",imports:{_:gr}},gr.prototype=io.prototype,gr.prototype.constructor=gr,Fo.prototype=ws(io.prototype),Fo.prototype.constructor=Fo,vs.prototype=ws(io.prototype),vs.prototype.constructor=vs,Gl.prototype.clear=function(){this.__data__=Xo?Xo(null):{},this.size=0},Gl.prototype.delete=function(Ze){var vt=this.has(Ze)&&delete this.__data__[Ze];return this.size-=vt?1:0,vt},Gl.prototype.get=function(Ze){var vt=this.__data__;if(Xo){var on=vt[Ze];return on===u?l:on}return As.call(vt,Ze)?vt[Ze]:l},Gl.prototype.has=function(Ze){var vt=this.__data__;return Xo?vt[Ze]!==l:As.call(vt,Ze)},Gl.prototype.set=function(Ze,vt){var on=this.__data__;return this.size+=this.has(Ze)?0:1,on[Ze]=Xo&&vt===l?u:vt,this},Mu.prototype.clear=function(){this.__data__=[],this.size=0},Mu.prototype.delete=function(Ze){var vt=this.__data__,on=Op(vt,Ze);return!(on<0||(on==vt.length-1?vt.pop():Bs.call(vt,on,1),--this.size,0))},Mu.prototype.get=function(Ze){var vt=this.__data__,on=Op(vt,Ze);return on<0?l:vt[on][1]},Mu.prototype.has=function(Ze){return Op(this.__data__,Ze)>-1},Mu.prototype.set=function(Ze,vt){var on=this.__data__,Fn=Op(on,Ze);return Fn<0?(++this.size,on.push([Ze,vt])):on[Fn][1]=vt,this},gu.prototype.clear=function(){this.size=0,this.__data__={hash:new Gl,map:new(la||Mu),string:new Gl}},gu.prototype.delete=function(Ze){var vt=Eo(this,Ze).delete(Ze);return this.size-=vt?1:0,vt},gu.prototype.get=function(Ze){return Eo(this,Ze).get(Ze)},gu.prototype.has=function(Ze){return Eo(this,Ze).has(Ze)},gu.prototype.set=function(Ze,vt){var on=Eo(this,Ze),Fn=on.size;return on.set(Ze,vt),this.size+=on.size==Fn?0:1,this},Nu.prototype.add=Nu.prototype.push=function(Ze){return this.__data__.set(Ze,u),this},Nu.prototype.has=function(Ze){return this.__data__.has(Ze)},lc.prototype.clear=function(){this.__data__=new Mu,this.size=0},lc.prototype.delete=function(Ze){var vt=this.__data__,on=vt.delete(Ze);return this.size=vt.size,on},lc.prototype.get=function(Ze){return this.__data__.get(Ze)},lc.prototype.has=function(Ze){return this.__data__.has(Ze)},lc.prototype.set=function(Ze,vt){var on=this.__data__;if(on instanceof Mu){var Fn=on.__data__;if(!la||Fn.length<199)return Fn.push([Ze,vt]),this.size=++on.size,this;on=this.__data__=new gu(Fn)}return on.set(Ze,vt),this.size=on.size,this};var oh=zp(Od),tf=zp(nf,!0);function Lp(Ze,vt){var on=!0;return oh(Ze,function(Fn,Qn,mi){return on=!!vt(Fn,Qn,mi)}),on}function Ah(Ze,vt,on){for(var Fn=-1,Qn=Ze.length;++Fn<Qn;){var mi=Ze[Fn],ra=vt(mi);if(ra!=null&&(Ca===l?ra==ra&&!Mh(ra):on(ra,Ca)))var Ca=ra,La=mi}return La}function cp(Ze,vt){var on=[];return oh(Ze,function(Fn,Qn,mi){vt(Fn,Qn,mi)&&on.push(Fn)}),on}function yc(Ze,vt,on,Fn,Qn){var mi=-1,ra=Ze.length;for(on||(on=Js),Qn||(Qn=[]);++mi<ra;){var Ca=Ze[mi];vt>0&&on(Ca)?vt>1?yc(Ca,vt-1,on,Fn,Qn):vu(Qn,Ca):Fn||(Qn[Qn.length]=Ca)}return Qn}var Cc=Ee(),lu=Ee(!0);function Od(Ze,vt){return Ze&&Cc(Ze,vt,Ic)}function nf(Ze,vt){return Ze&&lu(Ze,vt,Ic)}function Wf(Ze,vt){return Ol(vt,function(on){return wh(Ze[on])})}function Sc(Ze,vt){for(var on=0,Fn=(vt=Oh(vt,Ze)).length;Ze!=null&&on<Fn;)Ze=Ze[Tc(vt[on++])];return on&&on==Fn?Ze:l}function Sf(Ze,vt,on){var Fn=vt(Ze);return kl(Ze)?Fn:vu(Fn,on(Ze))}function vc(Ze){return Ze==null?Ze===l?"[object Undefined]":"[object Null]":Hl&&Hl in Ri(Ze)?function(vt){var on=As.call(vt,Hl),Fn=vt[Hl];try{vt[Hl]=l;var Qn=!0}catch{}var mi=vl.call(vt);return Qn&&(on?vt[Hl]=Fn:delete vt[Hl]),mi}(Ze):function(vt){return vl.call(vt)}(Ze)}function ul(Ze,vt){return Ze>vt}function dp(Ze,vt){return Ze!=null&&As.call(Ze,vt)}function Zo(Ze,vt){return Ze!=null&&vt in Ri(Ze)}function Xh(Ze,vt,on){for(var Fn=on?Bu:bu,Qn=Ze[0].length,mi=Ze.length,ra=mi,Ca=In(mi),La=1/0,Oa=[];ra--;){var fo=Ze[ra];ra&&vt&&(fo=hl(fo,yi(vt))),La=ol(fo.length,La),Ca[ra]=!on&&(vt||Qn>=120&&fo.length>=120)?new Nu(ra&&fo):l}fo=Ze[0];var Ho=-1,qs=Ca[0];e:for(;++Ho<Qn&&Oa.length<La;){var Ys=fo[Ho],_l=vt?vt(Ys):Ys;if(Ys=on||Ys!==0?Ys:0,!(qs?Su(qs,_l):Fn(Oa,_l,on))){for(ra=mi;--ra;){var Mo=Ca[ra];if(!(Mo?Su(Mo,_l):Fn(Ze[ra],_l,on)))continue e}qs&&qs.push(_l),Oa.push(Ys)}}return Oa}function kc(Ze,vt,on){var Fn=(Ze=yh(Ze,vt=Oh(vt,Ze)))==null?Ze:Ze[Tc(wd(vt))];return Fn==null?l:jl(Fn,Ze,on)}function Fp(Ze){return $u(Ze)&&vc(Ze)==ve}function kh(Ze,vt,on,Fn,Qn){return Ze===vt||(Ze==null||vt==null||!$u(Ze)&&!$u(vt)?Ze!=Ze&&vt!=vt:function(mi,ra,Ca,La,Oa,fo){var Ho=kl(mi),qs=kl(ra),Ys=Ho?ne:is(mi),_l=qs?ne:is(ra),Mo=(Ys=Ys==ve?ie:Ys)==ie,es=(_l=_l==ve?ie:_l)==ie,Qs=Ys==_l;if(Qs&&zh(mi)){if(!zh(ra))return!1;Ho=!0,Mo=!1}if(Qs&&!Mo)return fo||(fo=new lc),Ho||sm(mi)?_i(mi,ra,Ca,La,Oa,fo):function(sl,cl,wc,nc,Wc,pu,Dd){switch(wc){case tn:if(sl.byteLength!=cl.byteLength||sl.byteOffset!=cl.byteOffset)return!1;sl=sl.buffer,cl=cl.buffer;case nn:return!(sl.byteLength!=cl.byteLength||!pu(new Nl(sl),new Nl(cl)));case Ue:case De:case Xe:return dh(+sl,+cl);case Ve:return sl.name==cl.name&&sl.message==cl.message;case pt:case Tt:return sl==cl+"";case Te:var Ed=iu;case mt:var md=1&nc;if(Ed||(Ed=qt),sl.size!=cl.size&&!md)return!1;var th=Dd.get(sl);if(th)return th==cl;nc|=2,Dd.set(sl,cl);var Eu=_i(Ed(sl),Ed(cl),nc,Wc,pu,Dd);return Dd.delete(sl),Eu;case kt:if(Io)return Io.call(sl)==Io.call(cl)}return!1}(mi,ra,Ys,Ca,La,Oa,fo);if(!(1&Ca)){var Ms=Mo&&As.call(mi,"__wrapped__"),Tl=es&&As.call(ra,"__wrapped__");if(Ms||Tl){var Al=Ms?mi.value():mi,au=Tl?ra.value():ra;return fo||(fo=new lc),Oa(Al,au,Ca,La,fo)}}return!!Qs&&(fo||(fo=new lc),function(sl,cl,wc,nc,Wc,pu){var Dd=1&wc,Ed=Ta(sl),md=Ed.length;if(md!=Ta(cl).length&&!Dd)return!1;for(var th=md;th--;){var Eu=Ed[th];if(!(Dd?Eu in cl:As.call(cl,Eu)))return!1}var Xm=pu.get(sl),Vd=pu.get(cl);if(Xm&&Vd)return Xm==cl&&Vd==sl;var Dp=!0;pu.set(sl,cl),pu.set(cl,sl);for(var gm=Dd;++th<md;){var ym=sl[Eu=Ed[th]],ip=cl[Eu];if(nc)var ap=Dd?nc(ip,ym,Eu,cl,sl,pu):nc(ym,ip,Eu,sl,cl,pu);if(!(ap===l?ym===ip||Wc(ym,ip,wc,nc,pu):ap)){Dp=!1;break}gm||(gm=Eu=="constructor")}if(Dp&&!gm){var vf=sl.constructor,op=cl.constructor;vf==op||!("constructor"in sl)||!("constructor"in cl)||typeof vf=="function"&&vf instanceof vf&&typeof op=="function"&&op instanceof op||(Dp=!1)}return pu.delete(sl),pu.delete(cl),Dp}(mi,ra,Ca,La,Oa,fo))}(Ze,vt,on,Fn,kh,Qn))}function Tf(Ze,vt,on,Fn){var Qn=on.length,mi=Qn,ra=!Fn;if(Ze==null)return!mi;for(Ze=Ri(Ze);Qn--;){var Ca=on[Qn];if(ra&&Ca[2]?Ca[1]!==Ze[Ca[0]]:!(Ca[0]in Ze))return!1}for(;++Qn<mi;){var La=(Ca=on[Qn])[0],Oa=Ze[La],fo=Ca[1];if(ra&&Ca[2]){if(Oa===l&&!(La in Ze))return!1}else{var Ho=new lc;if(Fn)var qs=Fn(Oa,fo,La,Ze,vt,Ho);if(!(qs===l?kh(fo,Oa,3,Fn,Ho):qs))return!1}}return!0}function Ld(Ze){return!(!bc(Ze)||(vt=Ze,Lc&&Lc in vt))&&(wh(Ze)?Xu:Ra).test($d(Ze));var vt}function Gd(Ze){return typeof Ze=="function"?Ze:Ze==null?Sd:typeof Ze=="object"?kl(Ze)?Ph(Ze[0],Ze[1]):pp(Ze):Rc(Ze)}function cc(Ze){if(!_c(Ze))return vd(Ze);var vt=[];for(var on in Ri(Ze))As.call(Ze,on)&&on!="constructor"&&vt.push(on);return vt}function Jh(Ze,vt){return Ze<vt}function hp(Ze,vt){var on=-1,Fn=Md(Ze)?In(Ze.length):[];return oh(Ze,function(Qn,mi,ra){Fn[++on]=vt(Qn,mi,ra)}),Fn}function pp(Ze){var vt=So(Ze);return vt.length==1&&vt[0][2]?Ud(vt[0][0],vt[0][1]):function(on){return on===Ze||Tf(on,Ze,vt)}}function Ph(Ze,vt){return ll(Ze)&&Bc(vt)?Ud(Tc(Ze),vt):function(on){var Fn=$m(on,Ze);return Fn===l&&Fn===vt?Yp(on,Ze):kh(vt,Fn,3)}}function mh(Ze,vt,on,Fn,Qn){Ze!==vt&&Cc(vt,function(mi,ra){if(Qn||(Qn=new lc),bc(mi))(function(La,Oa,fo,Ho,qs,Ys,_l){var Mo=Bh(La,fo),es=Bh(Oa,fo),Qs=_l.get(es);if(Qs)uc(La,fo,Qs);else{var Ms=Ys?Ys(Mo,es,fo+"",La,Oa,_l):l,Tl=Ms===l;if(Tl){var Al=kl(es),au=!Al&&zh(es),sl=!Al&&!au&&sm(es);Ms=es,Al||au||sl?kl(Mo)?Ms=Mo:Dc(Mo)?Ms=Qc(Mo):au?(Tl=!1,Ms=Fd(es,!0)):sl?(Tl=!1,Ms=sf(es,!0)):Ms=[]:rp(es)||Yc(es)?(Ms=Mo,Yc(Mo)?Ms=xp(Mo):bc(Mo)&&!wh(Mo)||(Ms=ps(es))):Tl=!1}Tl&&(_l.set(es,Ms),qs(Ms,es,Ho,Ys,_l),_l.delete(es)),uc(La,fo,Ms)}})(Ze,vt,ra,on,mh,Fn,Qn);else{var Ca=Fn?Fn(Bh(Ze,ra),mi,ra+"",Ze,vt,Qn):l;Ca===l&&(Ca=mi),uc(Ze,ra,Ca)}},Zc)}function Ih(Ze,vt){var on=Ze.length;if(on)return fl(vt+=vt<0?on:0,on)?Ze[vt]:l}function Ts(Ze,vt,on){var Fn=-1;return vt=hl(vt=vt.length?hl(vt,function(Qn){return kl(Qn)?function(mi){return Sc(mi,Qn.length===1?Qn[0]:Qn)}:Qn}):[Sd],yi(na())),function(Qn,mi){var ra=Qn.length;for(Qn.sort(mi);ra--;)Qn[ra]=Qn[ra].value;return Qn}(hp(Ze,function(Qn,mi,ra){return{criteria:hl(vt,function(Ca){return Ca(Qn)}),index:++Fn,value:Qn}}),function(Qn,mi){return function(ra,Ca,La){for(var Oa=-1,fo=ra.criteria,Ho=Ca.criteria,qs=fo.length,Ys=La.length;++Oa<qs;){var _l=mp(fo[Oa],Ho[Oa]);if(_l)return Oa>=Ys?_l:_l*(La[Oa]=="desc"?-1:1)}return ra.index-Ca.index}(Qn,mi,on)})}function qf(Ze,vt,on){for(var Fn=-1,Qn=vt.length,mi={};++Fn<Qn;){var ra=vt[Fn],Ca=Sc(Ze,ra);on(Ca,ra)&&Vp(mi,Oh(ra,Ze),Ca)}return mi}function Bp(Ze,vt,on,Fn){var Qn=Fn?Gc:Vl,mi=-1,ra=vt.length,Ca=Ze;for(Ze===vt&&(vt=Qc(vt)),on&&(Ca=hl(Ze,yi(on)));++mi<ra;)for(var La=0,Oa=vt[mi],fo=on?on(Oa):Oa;(La=Qn(Ca,fo,La,Fn))>-1;)Ca!==Ze&&Bs.call(Ca,La,1),Bs.call(Ze,La,1);return Ze}function Qh(Ze,vt){for(var on=Ze?vt.length:0,Fn=on-1;on--;){var Qn=vt[on];if(on==Fn||Qn!==mi){var mi=Qn;fl(Qn)?Bs.call(Ze,Qn,1):Np(Ze,Qn)}}return Ze}function ql(Ze,vt){return Ze+gc(ah()*(vt-Ze+1))}function Xd(Ze,vt){var on="";if(!Ze||vt<1||vt>G)return on;do vt%2&&(on+=Ze),(vt=gc(vt/2))&&(Ze+=Ze);while(vt);return on}function Kl(Ze,vt){return ec(sh(Ze,vt,Sd),Ze+"")}function Vp(Ze,vt,on,Fn){if(!bc(Ze))return Ze;for(var Qn=-1,mi=(vt=Oh(vt,Ze)).length,ra=mi-1,Ca=Ze;Ca!=null&&++Qn<mi;){var La=Tc(vt[Qn]),Oa=on;if(La==="__proto__"||La==="constructor"||La==="prototype")return Ze;if(Qn!=ra){var fo=Ca[La];(Oa=Fn?Fn(fo,La,Ca):l)===l&&(Oa=bc(fo)?fo:fl(vt[Qn+1])?[]:{})}Ds(Ca,La,Oa),Ca=Ca[La]}return Ze}var ep=ei?function(Ze,vt){return ei.set(Ze,vt),Ze}:Sd,Df=Uc?function(Ze,vt){return Uc(Ze,"toString",{configurable:!0,enumerable:!1,value:Tp(vt),writable:!0})}:Sd;function xd(Ze,vt,on){var Fn=-1,Qn=Ze.length;vt<0&&(vt=-vt>Qn?0:Qn+vt),(on=on>Qn?Qn:on)<0&&(on+=Qn),Qn=vt>on?0:on-vt>>>0,vt>>>=0;for(var mi=In(Qn);++Fn<Qn;)mi[Fn]=Ze[Fn+vt];return mi}function rf(Ze,vt){var on;return oh(Ze,function(Fn,Qn,mi){return!(on=vt(Fn,Qn,mi))}),!!on}function af(Ze,vt,on){var Fn=0,Qn=Ze==null?Fn:Ze.length;if(typeof vt=="number"&&vt==vt&&Qn<=2147483647){for(;Fn<Qn;){var mi=Fn+Qn>>>1,ra=Ze[mi];ra!==null&&!Mh(ra)&&(on?ra<=vt:ra<vt)?Fn=mi+1:Qn=mi}return Qn}return Yf(Ze,vt,Sd,on)}function Yf(Ze,vt,on,Fn){var Qn=0,mi=Ze==null?0:Ze.length;if(mi===0)return 0;for(var ra=(vt=on(vt))!=vt,Ca=vt===null,La=Mh(vt),Oa=vt===l;Qn<mi;){var fo=gc((Qn+mi)/2),Ho=on(Ze[fo]),qs=Ho!==l,Ys=Ho===null,_l=Ho==Ho,Mo=Mh(Ho);if(ra)var es=Fn||_l;else es=Oa?_l&&(Fn||qs):Ca?_l&&qs&&(Fn||!Ys):La?_l&&qs&&!Ys&&(Fn||!Mo):!Ys&&!Mo&&(Fn?Ho<=vt:Ho<vt);es?Qn=fo+1:mi=fo}return ol(mi,4294967294)}function fp(Ze,vt){for(var on=-1,Fn=Ze.length,Qn=0,mi=[];++on<Fn;){var ra=Ze[on],Ca=vt?vt(ra):ra;if(!on||!dh(Ca,La)){var La=Ca;mi[Qn++]=ra===0?0:ra}}return mi}function Zf(Ze){return typeof Ze=="number"?Ze:Mh(Ze)?q:+Ze}function pd(Ze){if(typeof Ze=="string")return Ze;if(kl(Ze))return hl(Ze,pd)+"";if(Mh(Ze))return Ws?Ws.call(Ze):"";var vt=Ze+"";return vt=="0"&&1/Ze==-1/0?"-0":vt}function gh(Ze,vt,on){var Fn=-1,Qn=bu,mi=Ze.length,ra=!0,Ca=[],La=Ca;if(on)ra=!1,Qn=Bu;else if(mi>=200){var Oa=vt?null:Sr(Ze);if(Oa)return qt(Oa);ra=!1,Qn=Su,La=new Nu}else La=vt?[]:Ca;e:for(;++Fn<mi;){var fo=Ze[Fn],Ho=vt?vt(fo):fo;if(fo=on||fo!==0?fo:0,ra&&Ho==Ho){for(var qs=La.length;qs--;)if(La[qs]===Ho)continue e;vt&&La.push(Ho),Ca.push(fo)}else Qn(La,Ho,on)||(La!==Ca&&La.push(Ho),Ca.push(fo))}return Ca}function Np(Ze,vt){return(Ze=yh(Ze,vt=Oh(vt,Ze)))==null||delete Ze[Tc(wd(vt))]}function Im(Ze,vt,on,Fn){return Vp(Ze,vt,on(Sc(Ze,vt)),Fn)}function Rh(Ze,vt,on,Fn){for(var Qn=Ze.length,mi=Fn?Qn:-1;(Fn?mi--:++mi<Qn)&&vt(Ze[mi],mi,Ze););return on?xd(Ze,Fn?0:mi,Fn?mi+1:Qn):xd(Ze,Fn?mi+1:0,Fn?Qn:mi)}function bd(Ze,vt){var on=Ze;return on instanceof vs&&(on=on.value()),Ku(vt,function(Fn,Qn){return Qn.func.apply(Qn.thisArg,vu([Fn],Qn.args))},on)}function sd(Ze,vt,on){var Fn=Ze.length;if(Fn<2)return Fn?gh(Ze[0]):[];for(var Qn=-1,mi=In(Fn);++Qn<Fn;)for(var ra=Ze[Qn],Ca=-1;++Ca<Fn;)Ca!=Qn&&(mi[Qn]=_d(mi[Qn]||ra,Ze[Ca],vt,on));return gh(yc(mi,1),vt,on)}function of(Ze,vt,on){for(var Fn=-1,Qn=Ze.length,mi=vt.length,ra={};++Fn<Qn;){var Ca=Fn<mi?vt[Fn]:l;on(ra,Ze[Fn],Ca)}return ra}function Rm(Ze){return Dc(Ze)?Ze:[]}function Om(Ze){return typeof Ze=="function"?Ze:Sd}function Oh(Ze,vt){return kl(Ze)?Ze:ll(Ze,vt)?[Ze]:Yu(Ru(Ze))}var Ef=Kl;function Lh(Ze,vt,on){var Fn=Ze.length;return on=on===l?Fn:on,!vt&&on>=Fn?Ze:xd(Ze,vt,on)}var Kf=Wl||function(Ze){return al.clearTimeout(Ze)};function Fd(Ze,vt){if(vt)return Ze.slice();var on=Ze.length,Fn=$l?$l(on):new Ze.constructor(on);return Ze.copy(Fn),Fn}function Bd(Ze){var vt=new Ze.constructor(Ze.byteLength);return new Nl(vt).set(new Nl(Ze)),vt}function sf(Ze,vt){var on=vt?Bd(Ze.buffer):Ze.buffer;return new Ze.constructor(on,Ze.byteOffset,Ze.length)}function mp(Ze,vt){if(Ze!==vt){var on=Ze!==l,Fn=Ze===null,Qn=Ze==Ze,mi=Mh(Ze),ra=vt!==l,Ca=vt===null,La=vt==vt,Oa=Mh(vt);if(!Ca&&!Oa&&!mi&&Ze>vt||mi&&ra&&La&&!Ca&&!Oa||Fn&&ra&&La||!on&&La||!Qn)return 1;if(!Fn&&!mi&&!Oa&&Ze<vt||Oa&&on&&Qn&&!Fn&&!mi||Ca&&on&&Qn||!ra&&Qn||!La)return-1}return 0}function Xf(Ze,vt,on,Fn){for(var Qn=-1,mi=Ze.length,ra=on.length,Ca=-1,La=vt.length,Oa=Pu(mi-ra,0),fo=In(La+Oa),Ho=!Fn;++Ca<La;)fo[Ca]=vt[Ca];for(;++Qn<ra;)(Ho||Qn<mi)&&(fo[on[Qn]]=Ze[Qn]);for(;Oa--;)fo[Ca++]=Ze[Qn++];return fo}function Af(Ze,vt,on,Fn){for(var Qn=-1,mi=Ze.length,ra=-1,Ca=on.length,La=-1,Oa=vt.length,fo=Pu(mi-Ca,0),Ho=In(fo+Oa),qs=!Fn;++Qn<fo;)Ho[Qn]=Ze[Qn];for(var Ys=Qn;++La<Oa;)Ho[Ys+La]=vt[La];for(;++ra<Ca;)(qs||Qn<mi)&&(Ho[Ys+on[ra]]=Ze[Qn++]);return Ho}function Qc(Ze,vt){var on=-1,Fn=Ze.length;for(vt||(vt=In(Fn));++on<Fn;)vt[on]=Ze[on];return vt}function $c(Ze,vt,on,Fn){var Qn=!on;on||(on={});for(var mi=-1,ra=vt.length;++mi<ra;){var Ca=vt[mi],La=Fn?Fn(on[Ca],Ze[Ca],Ca,on,Ze):l;La===l&&(La=Ze[Ca]),Qn?Fc(on,Ca,La):Ds(on,Ca,La)}return on}function Iu(Ze,vt){return function(on,Fn){var Qn=kl(on)?Bl:Kh,mi=vt?vt():{};return Qn(on,Ze,na(Fn,2),mi)}}function Fh(Ze){return Kl(function(vt,on){var Fn=-1,Qn=on.length,mi=Qn>1?on[Qn-1]:l,ra=Qn>2?on[2]:l;for(mi=Ze.length>3&&typeof mi=="function"?(Qn--,mi):l,ra&&as(on[0],on[1],ra)&&(mi=Qn<3?l:mi,Qn=1),vt=Ri(vt);++Fn<Qn;){var Ca=on[Fn];Ca&&Ze(vt,Ca,Fn,mi)}return vt})}function zp(Ze,vt){return function(on,Fn){if(on==null)return on;if(!Md(on))return Ze(on,Fn);for(var Qn=on.length,mi=vt?Qn:-1,ra=Ri(on);(vt?mi--:++mi<Qn)&&Fn(ra[mi],mi,ra)!==!1;);return on}}function Ee(Ze){return function(vt,on,Fn){for(var Qn=-1,mi=Ri(vt),ra=Fn(vt),Ca=ra.length;Ca--;){var La=ra[Ze?Ca:++Qn];if(on(mi[La],La,mi)===!1)break}return vt}}function w(Ze){return function(vt){var on=Vo(vt=Ru(vt))?Pn(vt):l,Fn=on?on[0]:vt.charAt(0),Qn=on?Lh(on,1).join(""):vt.slice(1);return Fn[Ze]()+Qn}}function se(Ze){return function(vt){return Ku(Kp(pf(vt).replace(Ps,"")),Ze,"")}}function it(Ze){return function(){var vt=arguments;switch(vt.length){case 0:return new Ze;case 1:return new Ze(vt[0]);case 2:return new Ze(vt[0],vt[1]);case 3:return new Ze(vt[0],vt[1],vt[2]);case 4:return new Ze(vt[0],vt[1],vt[2],vt[3]);case 5:return new Ze(vt[0],vt[1],vt[2],vt[3],vt[4]);case 6:return new Ze(vt[0],vt[1],vt[2],vt[3],vt[4],vt[5]);case 7:return new Ze(vt[0],vt[1],vt[2],vt[3],vt[4],vt[5],vt[6])}var on=ws(Ze.prototype),Fn=Ze.apply(on,vt);return bc(Fn)?Fn:on}}function xt(Ze){return function(vt,on,Fn){var Qn=Ri(vt);if(!Md(vt)){var mi=na(on,3);vt=Ic(vt),on=function(Ca){return mi(Qn[Ca],Ca,Qn)}}var ra=Ze(vt,on,Fn);return ra>-1?Qn[mi?vt[ra]:ra]:l}}function Dt(Ze){return Fi(function(vt){var on=vt.length,Fn=on,Qn=Fo.prototype.thru;for(Ze&&vt.reverse();Fn--;){var mi=vt[Fn];if(typeof mi!="function")throw new ts(n);if(Qn&&!ra&&ja(mi)=="wrapper")var ra=new Fo([],!0)}for(Fn=ra?Fn:on;++Fn<on;){var Ca=ja(mi=vt[Fn]),La=Ca=="wrapper"?qa(mi):l;ra=La&&Yl(La[0])&&La[1]==424&&!La[4].length&&La[9]==1?ra[ja(La[0])].apply(ra,La[3]):mi.length==1&&Yl(mi)?ra[Ca]():ra.thru(mi)}return function(){var Oa=arguments,fo=Oa[0];if(ra&&Oa.length==1&&kl(fo))return ra.plant(fo).value();for(var Ho=0,qs=on?vt[Ho].apply(this,Oa):fo;++Ho<on;)qs=vt[Ho].call(this,qs);return qs}})}function Ot(Ze,vt,on,Fn,Qn,mi,ra,Ca,La,Oa){var fo=vt&O,Ho=1&vt,qs=2&vt,Ys=24&vt,_l=512&vt,Mo=qs?l:it(Ze);return function es(){for(var Qs=arguments.length,Ms=In(Qs),Tl=Qs;Tl--;)Ms[Tl]=arguments[Tl];if(Ys)var Al=To(es),au=function(nc,Wc){for(var pu=nc.length,Dd=0;pu--;)nc[pu]===Wc&&++Dd;return Dd}(Ms,Al);if(Fn&&(Ms=Xf(Ms,Fn,Qn,Ys)),mi&&(Ms=Af(Ms,mi,ra,Ys)),Qs-=au,Ys&&Qs<Oa){var sl=wt(Ms,Al);return ri(Ze,vt,Ot,es.placeholder,on,Ms,sl,Ca,La,Oa-Qs)}var cl=Ho?on:this,wc=qs?cl[Ze]:Ze;return Qs=Ms.length,Ca?Ms=function(nc,Wc){for(var pu=nc.length,Dd=ol(Wc.length,pu),Ed=Qc(nc);Dd--;){var md=Wc[Dd];nc[Dd]=fl(md,pu)?Ed[md]:l}return nc}(Ms,Ca):_l&&Qs>1&&Ms.reverse(),fo&&La<Qs&&(Ms.length=La),this&&this!==al&&this instanceof es&&(wc=Mo||it(wc)),wc.apply(cl,Ms)}}function rn(Ze,vt){return function(on,Fn){return function(Qn,mi,ra,Ca){return Od(Qn,function(La,Oa,fo){mi(Ca,ra(La),Oa,fo)}),Ca}(on,Ze,vt(Fn),{})}}function Tn(Ze,vt){return function(on,Fn){var Qn;if(on===l&&Fn===l)return vt;if(on!==l&&(Qn=on),Fn!==l){if(Qn===l)return Fn;typeof on=="string"||typeof Fn=="string"?(on=pd(on),Fn=pd(Fn)):(on=Zf(on),Fn=Zf(Fn)),Qn=Ze(on,Fn)}return Qn}}function kn(Ze){return Fi(function(vt){return vt=hl(vt,yi(na())),Kl(function(on){var Fn=this;return Ze(vt,function(Qn){return jl(Qn,Fn,on)})})})}function Bn(Ze,vt){var on=(vt=vt===l?" ":pd(vt)).length;if(on<2)return on?Xd(vt,Ze):vt;var Fn=Xd(vt,oc(Ze/Cn(vt)));return Vo(vt)?Lh(Pn(Fn),0,Ze).join(""):Fn.slice(0,Ze)}function Wn(Ze){return function(vt,on,Fn){return Fn&&typeof Fn!="number"&&as(vt,on,Fn)&&(on=Fn=l),vt=ld(vt),on===l?(on=vt,vt=0):on=ld(on),function(Qn,mi,ra,Ca){for(var La=-1,Oa=Pu(oc((mi-Qn)/(ra||1)),0),fo=In(Oa);Oa--;)fo[Ca?Oa:++La]=Qn,Qn+=ra;return fo}(vt,on,Fn=Fn===l?vt<on?1:-1:ld(Fn),Ze)}}function Fr(Ze){return function(vt,on){return typeof vt=="string"&&typeof on=="string"||(vt=Cu(vt),on=Cu(on)),Ze(vt,on)}}function ri(Ze,vt,on,Fn,Qn,mi,ra,Ca,La,Oa){var fo=8&vt;vt|=fo?b:m,4&(vt&=~(fo?m:b))||(vt&=-4);var Ho=[Ze,vt,Qn,fo?mi:l,fo?ra:l,fo?l:mi,fo?l:ra,Ca,La,Oa],qs=on.apply(l,Ho);return Yl(Ze)&&Vh(qs,Ho),qs.placeholder=Fn,tu(qs,Ze,vt)}function Zr(Ze){var vt=xa[Ze];return function(on,Fn){if(on=Cu(on),(Fn=Fn==null?0:ol(Zl(Fn),292))&&sc(on)){var Qn=(Ru(on)+"e").split("e");return+((Qn=(Ru(vt(Qn[0]+"e"+(+Qn[1]+Fn)))+"e").split("e"))[0]+"e"+(+Qn[1]-Fn))}return vt(on)}}var Sr=lo&&1/qt(new lo([,-0]))[1]==L?function(Ze){return new lo(Ze)}:Td;function Di(Ze){return function(vt){var on=is(vt);return on==Te?iu(vt):on==mt?function(Fn){var Qn=-1,mi=Array(Fn.size);return Fn.forEach(function(ra){mi[++Qn]=[ra,ra]}),mi}(vt):function(Fn,Qn){return hl(Qn,function(mi){return[mi,Fn[mi]]})}(vt,Ze(vt))}}function di(Ze,vt,on,Fn,Qn,mi,ra,Ca){var La=2&vt;if(!La&&typeof Ze!="function")throw new ts(n);var Oa=Fn?Fn.length:0;if(Oa||(vt&=-97,Fn=Qn=l),ra=ra===l?ra:Pu(Zl(ra),0),Ca=Ca===l?Ca:Zl(Ca),Oa-=Qn?Qn.length:0,vt&m){var fo=Fn,Ho=Qn;Fn=Qn=l}var qs=La?l:qa(Ze),Ys=[Ze,vt,on,Fn,Qn,fo,Ho,mi,ra,Ca];if(qs&&function(Mo,es){var Qs=Mo[1],Ms=es[1],Tl=Qs|Ms,Al=Tl<131,au=Ms==O&&Qs==8||Ms==O&&Qs==N&&Mo[7].length<=es[8]||Ms==384&&es[7].length<=es[8]&&Qs==8;if(!Al&&!au)return Mo;1&Ms&&(Mo[2]=es[2],Tl|=1&Qs?0:4);var sl=es[3];if(sl){var cl=Mo[3];Mo[3]=cl?Xf(cl,sl,es[4]):sl,Mo[4]=cl?wt(Mo[3],c):es[4]}(sl=es[5])&&(cl=Mo[5],Mo[5]=cl?Af(cl,sl,es[6]):sl,Mo[6]=cl?wt(Mo[5],c):es[6]),(sl=es[7])&&(Mo[7]=sl),Ms&O&&(Mo[8]=Mo[8]==null?es[8]:ol(Mo[8],es[8])),Mo[9]==null&&(Mo[9]=es[9]),Mo[0]=es[0],Mo[1]=Tl}(Ys,qs),Ze=Ys[0],vt=Ys[1],on=Ys[2],Fn=Ys[3],Qn=Ys[4],!(Ca=Ys[9]=Ys[9]===l?La?0:Ze.length:Pu(Ys[9]-Oa,0))&&24&vt&&(vt&=-25),vt&&vt!=1)_l=vt==8||vt==y?function(Mo,es,Qs){var Ms=it(Mo);return function Tl(){for(var Al=arguments.length,au=In(Al),sl=Al,cl=To(Tl);sl--;)au[sl]=arguments[sl];var wc=Al<3&&au[0]!==cl&&au[Al-1]!==cl?[]:wt(au,cl);return(Al-=wc.length)<Qs?ri(Mo,es,Ot,Tl.placeholder,l,au,wc,l,l,Qs-Al):jl(this&&this!==al&&this instanceof Tl?Ms:Mo,this,au)}}(Ze,vt,Ca):vt!=b&&vt!=33||Qn.length?Ot.apply(l,Ys):function(Mo,es,Qs,Ms){var Tl=1&es,Al=it(Mo);return function au(){for(var sl=-1,cl=arguments.length,wc=-1,nc=Ms.length,Wc=In(nc+cl),pu=this&&this!==al&&this instanceof au?Al:Mo;++wc<nc;)Wc[wc]=Ms[wc];for(;cl--;)Wc[wc++]=arguments[++sl];return jl(pu,Tl?Qs:this,Wc)}}(Ze,vt,on,Fn);else var _l=function(Mo,es,Qs){var Ms=1&es,Tl=it(Mo);return function Al(){return(this&&this!==al&&this instanceof Al?Tl:Mo).apply(Ms?Qs:this,arguments)}}(Ze,vt,on);return tu((qs?ep:Vh)(_l,Ys),Ze,vt)}function wi(Ze,vt,on,Fn){return Ze===l||dh(Ze,Fs[on])&&!As.call(Fn,on)?vt:Ze}function Ti(Ze,vt,on,Fn,Qn,mi){return bc(Ze)&&bc(vt)&&(mi.set(vt,Ze),mh(Ze,vt,l,Ti,mi),mi.delete(vt)),Ze}function Oi(Ze){return rp(Ze)?l:Ze}function _i(Ze,vt,on,Fn,Qn,mi){var ra=1&on,Ca=Ze.length,La=vt.length;if(Ca!=La&&!(ra&&La>Ca))return!1;var Oa=mi.get(Ze),fo=mi.get(vt);if(Oa&&fo)return Oa==vt&&fo==Ze;var Ho=-1,qs=!0,Ys=2&on?new Nu:l;for(mi.set(Ze,vt),mi.set(vt,Ze);++Ho<Ca;){var _l=Ze[Ho],Mo=vt[Ho];if(Fn)var es=ra?Fn(Mo,_l,Ho,vt,Ze,mi):Fn(_l,Mo,Ho,Ze,vt,mi);if(es!==l){if(es)continue;qs=!1;break}if(Ys){if(!ad(vt,function(Qs,Ms){if(!Su(Ys,Ms)&&(_l===Qs||Qn(_l,Qs,on,Fn,mi)))return Ys.push(Ms)})){qs=!1;break}}else if(_l!==Mo&&!Qn(_l,Mo,on,Fn,mi)){qs=!1;break}}return mi.delete(Ze),mi.delete(vt),qs}function Fi(Ze){return ec(sh(Ze,l,Hd),Ze+"")}function Ta(Ze){return Sf(Ze,Ic,Za)}function Fa(Ze){return Sf(Ze,Zc,rs)}var qa=ei?function(Ze){return ei.get(Ze)}:Td;function ja(Ze){for(var vt=Ze.name+"",on=ii[vt],Fn=As.call(ii,vt)?on.length:0;Fn--;){var Qn=on[Fn],mi=Qn.func;if(mi==null||mi==Ze)return Qn.name}return vt}function To(Ze){return(As.call(gr,"placeholder")?gr:Ze).placeholder}function na(){var Ze=gr.iteratee||Xp;return Ze=Ze===Xp?Gd:Ze,arguments.length?Ze(arguments[0],arguments[1]):Ze}function Eo(Ze,vt){var on,Fn,Qn=Ze.__data__;return((Fn=typeof(on=vt))=="string"||Fn=="number"||Fn=="symbol"||Fn=="boolean"?on!=="__proto__":on===null)?Qn[typeof vt=="string"?"string":"hash"]:Qn.map}function So(Ze){for(var vt=Ic(Ze),on=vt.length;on--;){var Fn=vt[on],Qn=Ze[Fn];vt[on]=[Fn,Qn,Bc(Qn)]}return vt}function Qo(Ze,vt){var on=function(Fn,Qn){return Fn==null?l:Fn[Qn]}(Ze,vt);return Ld(on)?on:l}var Za=dd?function(Ze){return Ze==null?[]:(Ze=Ri(Ze),Ol(dd(Ze),function(vt){return Gu.call(Ze,vt)}))}:gf,rs=dd?function(Ze){for(var vt=[];Ze;)vu(vt,Za(Ze)),Ze=hu(Ze);return vt}:gf,is=vc;function hs(Ze,vt,on){for(var Fn=-1,Qn=(vt=Oh(vt,Ze)).length,mi=!1;++Fn<Qn;){var ra=Tc(vt[Fn]);if(!(mi=Ze!=null&&on(Ze,ra)))break;Ze=Ze[ra]}return mi||++Fn!=Qn?mi:!!(Qn=Ze==null?0:Ze.length)&&qp(Qn)&&fl(ra,Qn)&&(kl(Ze)||Yc(Ze))}function ps(Ze){return typeof Ze.constructor!="function"||_c(Ze)?{}:ws(hu(Ze))}function Js(Ze){return kl(Ze)||Yc(Ze)||!!(su&&Ze&&Ze[su])}function fl(Ze,vt){var on=typeof Ze;return!!(vt=vt??G)&&(on=="number"||on!="symbol"&&Pi.test(Ze))&&Ze>-1&&Ze%1==0&&Ze<vt}function as(Ze,vt,on){if(!bc(on))return!1;var Fn=typeof vt;return!!(Fn=="number"?Md(on)&&fl(vt,on.length):Fn=="string"&&vt in on)&&dh(on[vt],Ze)}function ll(Ze,vt){if(kl(Ze))return!1;var on=typeof Ze;return!(on!="number"&&on!="symbol"&&on!="boolean"&&Ze!=null&&!Mh(Ze))||qn.test(Ze)||!Si.test(Ze)||vt!=null&&Ze in Ri(vt)}function Yl(Ze){var vt=ja(Ze),on=gr[vt];if(typeof on!="function"||!(vt in vs.prototype))return!1;if(Ze===on)return!0;var Fn=qa(on);return!!Fn&&Ze===Fn[0]}(wa&&is(new wa(new ArrayBuffer(1)))!=tn||la&&is(new la)!=Te||Wa&&is(Wa.resolve())!=ue||lo&&is(new lo)!=mt||Jo&&is(new Jo)!=It)&&(is=function(Ze){var vt=vc(Ze),on=vt==ie?Ze.constructor:l,Fn=on?$d(on):"";if(Fn)switch(Fn){case Ma:return tn;case pa:return Te;case ca:return ue;case uo:return mt;case ya:return It}return vt});var dc=eu?wh:fm;function _c(Ze){var vt=Ze&&Ze.constructor;return Ze===(typeof vt=="function"&&vt.prototype||Fs)}function Bc(Ze){return Ze==Ze&&!bc(Ze)}function Ud(Ze,vt){return function(on){return on!=null&&on[Ze]===vt&&(vt!==l||Ze in Ri(on))}}function sh(Ze,vt,on){return vt=Pu(vt===l?Ze.length-1:vt,0),function(){for(var Fn=arguments,Qn=-1,mi=Pu(Fn.length-vt,0),ra=In(mi);++Qn<mi;)ra[Qn]=Fn[vt+Qn];Qn=-1;for(var Ca=In(vt+1);++Qn<vt;)Ca[Qn]=Fn[Qn];return Ca[vt]=on(ra),jl(Ze,this,Ca)}}function yh(Ze,vt){return vt.length<2?Ze:Sc(Ze,xd(vt,0,-1))}function Bh(Ze,vt){if((vt!=="constructor"||typeof Ze[vt]!="function")&&vt!="__proto__")return Ze[vt]}var Vh=tc(ep),Uu=wu||function(Ze,vt){return al.setTimeout(Ze,vt)},ec=tc(Df);function tu(Ze,vt,on){var Fn=vt+"";return ec(Ze,function(Qn,mi){var ra=mi.length;if(!ra)return Qn;var Ca=ra-1;return mi[Ca]=(ra>1?"& ":"")+mi[Ca],mi=mi.join(ra>2?", ":" "),Qn.replace(fi,`{
- /* [wrapped with `+mi+`] */
- `)}(Fn,function(Qn,mi){return Jl(fe,function(ra){var Ca="_."+ra[0];mi&ra[1]&&!bu(Qn,Ca)&&Qn.push(Ca)}),Qn.sort()}(function(Qn){var mi=Fn.match(An);return mi?mi[1].split(sa):[]}(),on)))}function tc(Ze){var vt=0,on=0;return function(){var Fn=od(),Qn=16-(Fn-on);if(on=Fn,Qn>0){if(++vt>=800)return arguments[0]}else vt=0;return Ze.apply(l,arguments)}}function fd(Ze,vt){var on=-1,Fn=Ze.length,Qn=Fn-1;for(vt=vt===l?Fn:vt;++on<vt;){var mi=ql(on,Qn),ra=Ze[mi];Ze[mi]=Ze[on],Ze[on]=ra}return Ze.length=vt,Ze}var Yu=function(Ze){var vt=Jd(function(Fn){var Qn=[];return Fn.charCodeAt(0)===46&&Qn.push(""),Fn.replace(ia,function(mi,ra,Ca,La){Qn.push(Ca?La.replace(un,"$1"):ra||mi)}),Qn},function(Fn){return on.size===500&&on.clear(),Fn}),on=vt.cache;return vt}();function Tc(Ze){if(typeof Ze=="string"||Mh(Ze))return Ze;var vt=Ze+"";return vt=="0"&&1/Ze==-1/0?"-0":vt}function $d(Ze){if(Ze!=null){try{return Gs.call(Ze)}catch{}try{return Ze+""}catch{}}return""}function Vc(Ze){if(Ze instanceof vs)return Ze.clone();var vt=new Fo(Ze.__wrapped__,Ze.__chain__);return vt.__actions__=Qc(Ze.__actions__),vt.__index__=Ze.__index__,vt.__values__=Ze.__values__,vt}var lh=Kl(function(Ze,vt){return Dc(Ze)?_d(Ze,yc(vt,1,Dc,!0)):[]}),gp=Kl(function(Ze,vt){var on=wd(vt);return Dc(on)&&(on=l),Dc(Ze)?_d(Ze,yc(vt,1,Dc,!0),na(on,2)):[]}),jp=Kl(function(Ze,vt){var on=wd(vt);return Dc(on)&&(on=l),Dc(Ze)?_d(Ze,yc(vt,1,Dc,!0),l,on):[]});function uh(Ze,vt,on){var Fn=Ze==null?0:Ze.length;if(!Fn)return-1;var Qn=on==null?0:Zl(on);return Qn<0&&(Qn=Pu(Fn+Qn,0)),co(Ze,na(vt,3),Qn)}function lf(Ze,vt,on){var Fn=Ze==null?0:Ze.length;if(!Fn)return-1;var Qn=Fn-1;return on!==l&&(Qn=Zl(on),Qn=on<0?Pu(Fn+Qn,0):ol(Qn,Fn-1)),co(Ze,na(vt,3),Qn,!0)}function Hd(Ze){return Ze!=null&&Ze.length?yc(Ze,1):[]}function tp(Ze){return Ze&&Ze.length?Ze[0]:l}var Gp=Kl(function(Ze){var vt=hl(Ze,Rm);return vt.length&&vt[0]===Ze[0]?Xh(vt):[]}),Jf=Kl(function(Ze){var vt=wd(Ze),on=hl(Ze,Rm);return vt===wd(on)?vt=l:on.pop(),on.length&&on[0]===Ze[0]?Xh(on,na(vt,2)):[]}),l3=Kl(function(Ze){var vt=wd(Ze),on=hl(Ze,Rm);return(vt=typeof vt=="function"?vt:l)&&on.pop(),on.length&&on[0]===Ze[0]?Xh(on,l,vt):[]});function wd(Ze){var vt=Ze==null?0:Ze.length;return vt?Ze[vt-1]:l}var vh=Kl(uf);function uf(Ze,vt){return Ze&&Ze.length&&vt&&vt.length?Bp(Ze,vt):Ze}var T3=Fi(function(Ze,vt){var on=Ze==null?0:Ze.length,Fn=fh(Ze,vt);return Qh(Ze,hl(vt,function(Qn){return fl(Qn,on)?+Qn:Qn}).sort(mp)),Fn});function Qf(Ze){return Ze==null?Ze:Mi.call(Ze)}var J3=Kl(function(Ze){return gh(yc(Ze,1,Dc,!0))}),Lm=Kl(function(Ze){var vt=wd(Ze);return Dc(vt)&&(vt=l),gh(yc(Ze,1,Dc,!0),na(vt,2))}),u3=Kl(function(Ze){var vt=wd(Ze);return vt=typeof vt=="function"?vt:l,gh(yc(Ze,1,Dc,!0),l,vt)});function cf(Ze){if(!Ze||!Ze.length)return[];var vt=0;return Ze=Ol(Ze,function(on){if(Dc(on))return vt=Pu(on.length,vt),!0}),ud(vt,function(on){return hl(Ze,Ll(on))})}function kf(Ze,vt){if(!Ze||!Ze.length)return[];var on=cf(Ze);return vt==null?on:hl(on,function(Fn){return jl(vt,l,Fn)})}var yp=Kl(function(Ze,vt){return Dc(Ze)?_d(Ze,vt):[]}),_h=Kl(function(Ze){return sd(Ol(Ze,Dc))}),Nh=Kl(function(Ze){var vt=wd(Ze);return Dc(vt)&&(vt=l),sd(Ol(Ze,Dc),na(vt,2))}),df=Kl(function(Ze){var vt=wd(Ze);return vt=typeof vt=="function"?vt:l,sd(Ol(Ze,Dc),l,vt)}),np=Kl(cf),Up=Kl(function(Ze){var vt=Ze.length,on=vt>1?Ze[vt-1]:l;return kf(Ze,on=typeof on=="function"?(Ze.pop(),on):l)});function D3(Ze){var vt=gr(Ze);return vt.__chain__=!0,vt}function Fm(Ze,vt){return vt(Ze)}var em=Fi(function(Ze){var vt=Ze.length,on=vt?Ze[0]:0,Fn=this.__wrapped__,Qn=function(mi){return fh(mi,Ze)};return!(vt>1||this.__actions__.length)&&Fn instanceof vs&&fl(on)?((Fn=Fn.slice(on,+on+(vt?1:0))).__actions__.push({func:Fm,args:[Qn],thisArg:l}),new Fo(Fn,this.__chain__).thru(function(mi){return vt&&!mi.length&&mi.push(l),mi})):this.thru(Qn)}),Bm=Iu(function(Ze,vt,on){As.call(Ze,on)?++Ze[on]:Fc(Ze,on,1)}),Vm=xt(uh),Pc=xt(lf);function xh(Ze,vt){return(kl(Ze)?Jl:oh)(Ze,na(vt,3))}function E3(Ze,vt){return(kl(Ze)?function(on,Fn){for(var Qn=on==null?0:on.length;Qn--&&Fn(on[Qn],Qn,on)!==!1;);return on}:tf)(Ze,na(vt,3))}var Q3=Iu(function(Ze,vt,on){As.call(Ze,on)?Ze[on].push(vt):Fc(Ze,on,[vt])}),hc=Kl(function(Ze,vt,on){var Fn=-1,Qn=typeof vt=="function",mi=Md(Ze)?In(Ze.length):[];return oh(Ze,function(ra){mi[++Fn]=Qn?jl(vt,ra,on):kc(ra,vt,on)}),mi}),Ml=Iu(function(Ze,vt,on){Fc(Ze,on,vt)});function Hc(Ze,vt){return(kl(Ze)?hl:hp)(Ze,na(vt,3))}var tm=Iu(function(Ze,vt,on){Ze[on?0:1].push(vt)},function(){return[[],[]]}),_u=Kl(function(Ze,vt){if(Ze==null)return[];var on=vt.length;return on>1&&as(Ze,vt[0],vt[1])?vt=[]:on>2&&as(vt[0],vt[1],vt[2])&&(vt=[vt[0]]),Ts(Ze,yc(vt,1),[])}),xc=cd||function(){return al.Date.now()};function Pf(Ze,vt,on){return vt=on?l:vt,vt=Ze&&vt==null?Ze.length:vt,di(Ze,O,l,l,l,l,vt)}function ch(Ze,vt){var on;if(typeof vt!="function")throw new ts(n);return Ze=Zl(Ze),function(){return--Ze>0&&(on=vt.apply(this,arguments)),Ze<=1&&(vt=l),on}}var $p=Kl(function(Ze,vt,on){var Fn=1;if(on.length){var Qn=wt(on,To($p));Fn|=b}return di(Ze,Fn,vt,on,Qn)}),Hp=Kl(function(Ze,vt,on){var Fn=3;if(on.length){var Qn=wt(on,To(Hp));Fn|=b}return di(vt,Fn,Ze,on,Qn)});function Wd(Ze,vt,on){var Fn,Qn,mi,ra,Ca,La,Oa=0,fo=!1,Ho=!1,qs=!0;if(typeof Ze!="function")throw new ts(n);function Ys(Ms){var Tl=Fn,Al=Qn;return Fn=Qn=l,Oa=Ms,ra=Ze.apply(Al,Tl)}function _l(Ms){var Tl=Ms-La;return La===l||Tl>=vt||Tl<0||Ho&&Ms-Oa>=mi}function Mo(){var Ms=xc();if(_l(Ms))return es(Ms);Ca=Uu(Mo,function(Tl){var Al=vt-(Tl-La);return Ho?ol(Al,mi-(Tl-Oa)):Al}(Ms))}function es(Ms){return Ca=l,qs&&Fn?Ys(Ms):(Fn=Qn=l,ra)}function Qs(){var Ms=xc(),Tl=_l(Ms);if(Fn=arguments,Qn=this,La=Ms,Tl){if(Ca===l)return function(Al){return Oa=Al,Ca=Uu(Mo,vt),fo?Ys(Al):ra}(La);if(Ho)return Kf(Ca),Ca=Uu(Mo,vt),Ys(La)}return Ca===l&&(Ca=Uu(Mo,vt)),ra}return vt=Cu(vt)||0,bc(on)&&(fo=!!on.leading,mi=(Ho="maxWait"in on)?Pu(Cu(on.maxWait)||0,vt):mi,qs="trailing"in on?!!on.trailing:qs),Qs.cancel=function(){Ca!==l&&Kf(Ca),Oa=0,Fn=La=Qn=Ca=l},Qs.flush=function(){return Ca===l?ra:es(xc())},Qs}var ed=Kl(function(Ze,vt){return Cf(Ze,1,vt)}),If=Kl(function(Ze,vt,on){return Cf(Ze,Cu(vt)||0,on)});function Jd(Ze,vt){if(typeof Ze!="function"||vt!=null&&typeof vt!="function")throw new ts(n);var on=function(){var Fn=arguments,Qn=vt?vt.apply(this,Fn):Fn[0],mi=on.cache;if(mi.has(Qn))return mi.get(Qn);var ra=Ze.apply(this,Fn);return on.cache=mi.set(Qn,ra)||mi,ra};return on.cache=new(Jd.Cache||gu),on}function Wp(Ze){if(typeof Ze!="function")throw new ts(n);return function(){var vt=arguments;switch(vt.length){case 0:return!Ze.call(this);case 1:return!Ze.call(this,vt[0]);case 2:return!Ze.call(this,vt[0],vt[1]);case 3:return!Ze.call(this,vt[0],vt[1],vt[2])}return!Ze.apply(this,vt)}}Jd.Cache=gu;var nm=Ef(function(Ze,vt){var on=(vt=vt.length==1&&kl(vt[0])?hl(vt[0],yi(na())):hl(yc(vt,1),yi(na()))).length;return Kl(function(Fn){for(var Qn=-1,mi=ol(Fn.length,on);++Qn<mi;)Fn[Qn]=vt[Qn].call(this,Fn[Qn]);return jl(Ze,this,Fn)})}),Nm=Kl(function(Ze,vt){var on=wt(vt,To(Nm));return di(Ze,b,l,vt,on)}),rm=Kl(function(Ze,vt){var on=wt(vt,To(rm));return di(Ze,m,l,vt,on)}),im=Fi(function(Ze,vt){return di(Ze,N,l,l,l,vt)});function dh(Ze,vt){return Ze===vt||Ze!=Ze&&vt!=vt}var bh=Fr(ul),vp=Fr(function(Ze,vt){return Ze>=vt}),Yc=Fp(function(){return arguments}())?Fp:function(Ze){return $u(Ze)&&As.call(Ze,"callee")&&!Gu.call(Ze,"callee")},kl=In.isArray,Rf=ga?yi(ga):function(Ze){return $u(Ze)&&vc(Ze)==nn};function Md(Ze){return Ze!=null&&qp(Ze.length)&&!wh(Ze)}function Dc(Ze){return $u(Ze)&&Md(Ze)}var zh=Jc||fm,zm=no?yi(no):function(Ze){return $u(Ze)&&vc(Ze)==De};function hf(Ze){if(!$u(Ze))return!1;var vt=vc(Ze);return vt==Ve||vt=="[object DOMException]"||typeof Ze.message=="string"&&typeof Ze.name=="string"&&!rp(Ze)}function wh(Ze){if(!bc(Ze))return!1;var vt=vc(Ze);return vt==rt||vt==Ae||vt=="[object AsyncFunction]"||vt=="[object Proxy]"}function Of(Ze){return typeof Ze=="number"&&Ze==Zl(Ze)}function qp(Ze){return typeof Ze=="number"&&Ze>-1&&Ze%1==0&&Ze<=G}function bc(Ze){var vt=typeof Ze;return Ze!=null&&(vt=="object"||vt=="function")}function $u(Ze){return Ze!=null&&typeof Ze=="object"}var am=mo?yi(mo):function(Ze){return $u(Ze)&&is(Ze)==Te};function om(Ze){return typeof Ze=="number"||$u(Ze)&&vc(Ze)==Xe}function rp(Ze){if(!$u(Ze)||vc(Ze)!=ie)return!1;var vt=hu(Ze);if(vt===null)return!0;var on=As.call(vt,"constructor")&&vt.constructor;return typeof on=="function"&&on instanceof on&&Gs.call(on)==du}var _p=Go?yi(Go):function(Ze){return $u(Ze)&&vc(Ze)==pt},Lf=Uo?yi(Uo):function(Ze){return $u(Ze)&&is(Ze)==mt};function jm(Ze){return typeof Ze=="string"||!kl(Ze)&&$u(Ze)&&vc(Ze)==Tt}function Mh(Ze){return typeof Ze=="symbol"||$u(Ze)&&vc(Ze)==kt}var sm=Ns?yi(Ns):function(Ze){return $u(Ze)&&qp(Ze.length)&&!!xl[vc(Ze)]},A3=Fr(Jh),hh=Fr(function(Ze,vt){return Ze<=vt});function k3(Ze){if(!Ze)return[];if(Md(Ze))return jm(Ze)?Pn(Ze):Qc(Ze);if(ku&&Ze[ku])return function(on){for(var Fn,Qn=[];!(Fn=on.next()).done;)Qn.push(Fn.value);return Qn}(Ze[ku]());var vt=is(Ze);return(vt==Te?iu:vt==mt?qt:Qd)(Ze)}function ld(Ze){return Ze?(Ze=Cu(Ze))===L||Ze===-1/0?17976931348623157e292*(Ze<0?-1:1):Ze==Ze?Ze:0:Ze===0?Ze:0}function Zl(Ze){var vt=ld(Ze),on=vt%1;return vt==vt?on?vt-on:vt:0}function Ch(Ze){return Ze?Rd(Zl(Ze),0,J):0}function Cu(Ze){if(typeof Ze=="number")return Ze;if(Mh(Ze))return q;if(bc(Ze)){var vt=typeof Ze.valueOf=="function"?Ze.valueOf():Ze;Ze=bc(vt)?vt+"":vt}if(typeof Ze!="string")return Ze===0?Ze:+Ze;Ze=Xc(Ze);var on=bi.test(Ze);return on||so.test(Ze)?tl(Ze.slice(2),on?2:8):hi.test(Ze)?q:+Ze}function xp(Ze){return $c(Ze,Zc(Ze))}function Ru(Ze){return Ze==null?"":pd(Ze)}var Gm=Fh(function(Ze,vt){if(_c(vt)||Md(vt))$c(vt,Ic(vt),Ze);else for(var on in vt)As.call(vt,on)&&Ds(Ze,on,vt[on])}),Um=Fh(function(Ze,vt){$c(vt,Zc(vt),Ze)}),lm=Fh(function(Ze,vt,on,Fn){$c(vt,Zc(vt),Ze,Fn)}),um=Fh(function(Ze,vt,on,Fn){$c(vt,Ic(vt),Ze,Fn)}),Ff=Fi(fh),bp=Kl(function(Ze,vt){Ze=Ri(Ze);var on=-1,Fn=vt.length,Qn=Fn>2?vt[2]:l;for(Qn&&as(vt[0],vt[1],Qn)&&(Fn=1);++on<Fn;)for(var mi=vt[on],ra=Zc(mi),Ca=-1,La=ra.length;++Ca<La;){var Oa=ra[Ca],fo=Ze[Oa];(fo===l||dh(fo,Fs[Oa])&&!As.call(Ze,Oa))&&(Ze[Oa]=mi[Oa])}return Ze}),P3=Kl(function(Ze){return Ze.push(l,Ti),jl(Sh,l,Ze)});function $m(Ze,vt,on){var Fn=Ze==null?l:Sc(Ze,vt);return Fn===l?on:Fn}function Yp(Ze,vt){return Ze!=null&&hs(Ze,vt,Zo)}var wp=rn(function(Ze,vt,on){vt!=null&&typeof vt.toString!="function"&&(vt=vl.call(vt)),Ze[vt]=on},Tp(Sd)),Hm=rn(function(Ze,vt,on){vt!=null&&typeof vt.toString!="function"&&(vt=vl.call(vt)),As.call(Ze,vt)?Ze[vt].push(on):Ze[vt]=[on]},na),c3=Kl(kc);function Ic(Ze){return Md(Ze)?Du(Ze):cc(Ze)}function Zc(Ze){return Md(Ze)?Du(Ze,!0):function(vt){if(!bc(vt))return function(mi){var ra=[];if(mi!=null)for(var Ca in Ri(mi))ra.push(Ca);return ra}(vt);var on=_c(vt),Fn=[];for(var Qn in vt)(Qn!="constructor"||!on&&As.call(vt,Qn))&&Fn.push(Qn);return Fn}(Ze)}var Wm=Fh(function(Ze,vt,on){mh(Ze,vt,on)}),Sh=Fh(function(Ze,vt,on,Fn){mh(Ze,vt,on,Fn)}),qm=Fi(function(Ze,vt){var on={};if(Ze==null)return on;var Fn=!1;vt=hl(vt,function(mi){return mi=Oh(mi,Ze),Fn||(Fn=mi.length>1),mi}),$c(Ze,Fa(Ze),on),Fn&&(on=hd(on,7,Oi));for(var Qn=vt.length;Qn--;)Np(on,vt[Qn]);return on}),Zp=Fi(function(Ze,vt){return Ze==null?{}:function(on,Fn){return qf(on,Fn,function(Qn,mi){return Yp(on,mi)})}(Ze,vt)});function Mp(Ze,vt){if(Ze==null)return{};var on=hl(Fa(Ze),function(Fn){return[Fn]});return vt=na(vt),qf(Ze,on,function(Fn,Qn){return vt(Fn,Qn[0])})}var cm=Di(Ic),dm=Di(Zc);function Qd(Ze){return Ze==null?[]:mc(Ze,Ic(Ze))}var I3=se(function(Ze,vt,on){return vt=vt.toLowerCase(),Ze+(on?Bf(vt):vt)});function Bf(Ze){return Vf(Ru(Ze).toLowerCase())}function pf(Ze){return(Ze=Ru(Ze))&&Ze.replace(oi,pl).replace(qo,"")}var Cp=se(function(Ze,vt,on){return Ze+(on?"-":"")+vt.toLowerCase()}),qd=se(function(Ze,vt,on){return Ze+(on?" ":"")+vt.toLowerCase()}),Ym=w("toLowerCase"),d3=se(function(Ze,vt,on){return Ze+(on?"_":"")+vt.toLowerCase()}),hm=se(function(Ze,vt,on){return Ze+(on?" ":"")+Vf(vt)}),eh=se(function(Ze,vt,on){return Ze+(on?" ":"")+vt.toUpperCase()}),Vf=w("toUpperCase");function Kp(Ze,vt,on){return Ze=Ru(Ze),(vt=on?l:vt)===l?function(Fn){return Zs.test(Fn)}(Ze)?function(Fn){return Fn.match(yu)||[]}(Ze):function(Fn){return Fn.match(Nn)||[]}(Ze):Ze.match(vt)||[]}var Sp=Kl(function(Ze,vt){try{return jl(Ze,l,vt)}catch(on){return hf(on)?on:new Jn(on)}}),pm=Fi(function(Ze,vt){return Jl(vt,function(on){on=Tc(on),Fc(Ze,on,$p(Ze[on],Ze))}),Ze});function Tp(Ze){return function(){return Ze}}var Th=Dt(),Cd=Dt(!0);function Sd(Ze){return Ze}function Xp(Ze){return Gd(typeof Ze=="function"?Ze:hd(Ze,1))}var Zm=Kl(function(Ze,vt){return function(on){return kc(on,Ze,vt)}}),Og=Kl(function(Ze,vt){return function(on){return kc(Ze,on,vt)}});function Nc(Ze,vt,on){var Fn=Ic(vt),Qn=Wf(vt,Fn);on!=null||bc(vt)&&(Qn.length||!Fn.length)||(on=vt,vt=Ze,Ze=this,Qn=Wf(vt,Ic(vt)));var mi=!(bc(on)&&"chain"in on&&!on.chain),ra=wh(Ze);return Jl(Qn,function(Ca){var La=vt[Ca];Ze[Ca]=La,ra&&(Ze.prototype[Ca]=function(){var Oa=this.__chain__;if(mi||Oa){var fo=Ze(this.__wrapped__);return(fo.__actions__=Qc(this.__actions__)).push({func:La,args:arguments,thisArg:Ze}),fo.__chain__=Oa,fo}return La.apply(Ze,vu([this.value()],arguments))})}),Ze}function Td(){}var h3=kn(hl),ff=kn(mu),Km=kn(ad);function Rc(Ze){return ll(Ze)?Ll(Tc(Ze)):function(vt){return function(on){return Sc(on,vt)}}(Ze)}var mf=Wn(),p3=Wn(!0);function gf(){return[]}function fm(){return!1}var Nf,f3=Tn(function(Ze,vt){return Ze+vt},0),mm=Zr("ceil"),jh=Tn(function(Ze,vt){return Ze/vt},1),R3=Zr("floor"),zf=Tn(function(Ze,vt){return Ze*vt},1),yf=Zr("round"),eg=Tn(function(Ze,vt){return Ze-vt},0);return gr.after=function(Ze,vt){if(typeof vt!="function")throw new ts(n);return Ze=Zl(Ze),function(){if(--Ze<1)return vt.apply(this,arguments)}},gr.ary=Pf,gr.assign=Gm,gr.assignIn=Um,gr.assignInWith=lm,gr.assignWith=um,gr.at=Ff,gr.before=ch,gr.bind=$p,gr.bindAll=pm,gr.bindKey=Hp,gr.castArray=function(){if(!arguments.length)return[];var Ze=arguments[0];return kl(Ze)?Ze:[Ze]},gr.chain=D3,gr.chunk=function(Ze,vt,on){vt=(on?as(Ze,vt,on):vt===l)?1:Pu(Zl(vt),0);var Fn=Ze==null?0:Ze.length;if(!Fn||vt<1)return[];for(var Qn=0,mi=0,ra=In(oc(Fn/vt));Qn<Fn;)ra[mi++]=xd(Ze,Qn,Qn+=vt);return ra},gr.compact=function(Ze){for(var vt=-1,on=Ze==null?0:Ze.length,Fn=0,Qn=[];++vt<on;){var mi=Ze[vt];mi&&(Qn[Fn++]=mi)}return Qn},gr.concat=function(){var Ze=arguments.length;if(!Ze)return[];for(var vt=In(Ze-1),on=arguments[0],Fn=Ze;Fn--;)vt[Fn-1]=arguments[Fn];return vu(kl(on)?Qc(on):[on],yc(vt,1))},gr.cond=function(Ze){var vt=Ze==null?0:Ze.length,on=na();return Ze=vt?hl(Ze,function(Fn){if(typeof Fn[1]!="function")throw new ts(n);return[on(Fn[0]),Fn[1]]}):[],Kl(function(Fn){for(var Qn=-1;++Qn<vt;){var mi=Ze[Qn];if(jl(mi[0],this,Fn))return jl(mi[1],this,Fn)}})},gr.conforms=function(Ze){return function(vt){var on=Ic(vt);return function(Fn){return ef(Fn,vt,on)}}(hd(Ze,1))},gr.constant=Tp,gr.countBy=Bm,gr.create=function(Ze,vt){var on=ws(Ze);return vt==null?on:up(on,vt)},gr.curry=function Ze(vt,on,Fn){var Qn=di(vt,8,l,l,l,l,l,on=Fn?l:on);return Qn.placeholder=Ze.placeholder,Qn},gr.curryRight=function Ze(vt,on,Fn){var Qn=di(vt,y,l,l,l,l,l,on=Fn?l:on);return Qn.placeholder=Ze.placeholder,Qn},gr.debounce=Wd,gr.defaults=bp,gr.defaultsDeep=P3,gr.defer=ed,gr.delay=If,gr.difference=lh,gr.differenceBy=gp,gr.differenceWith=jp,gr.drop=function(Ze,vt,on){var Fn=Ze==null?0:Ze.length;return Fn?xd(Ze,(vt=on||vt===l?1:Zl(vt))<0?0:vt,Fn):[]},gr.dropRight=function(Ze,vt,on){var Fn=Ze==null?0:Ze.length;return Fn?xd(Ze,0,(vt=Fn-(vt=on||vt===l?1:Zl(vt)))<0?0:vt):[]},gr.dropRightWhile=function(Ze,vt){return Ze&&Ze.length?Rh(Ze,na(vt,3),!0,!0):[]},gr.dropWhile=function(Ze,vt){return Ze&&Ze.length?Rh(Ze,na(vt,3),!0):[]},gr.fill=function(Ze,vt,on,Fn){var Qn=Ze==null?0:Ze.length;return Qn?(on&&typeof on!="number"&&as(Ze,vt,on)&&(on=0,Fn=Qn),function(mi,ra,Ca,La){var Oa=mi.length;for((Ca=Zl(Ca))<0&&(Ca=-Ca>Oa?0:Oa+Ca),(La=La===l||La>Oa?Oa:Zl(La))<0&&(La+=Oa),La=Ca>La?0:Ch(La);Ca<La;)mi[Ca++]=ra;return mi}(Ze,vt,on,Fn)):[]},gr.filter=function(Ze,vt){return(kl(Ze)?Ol:cp)(Ze,na(vt,3))},gr.flatMap=function(Ze,vt){return yc(Hc(Ze,vt),1)},gr.flatMapDeep=function(Ze,vt){return yc(Hc(Ze,vt),L)},gr.flatMapDepth=function(Ze,vt,on){return on=on===l?1:Zl(on),yc(Hc(Ze,vt),on)},gr.flatten=Hd,gr.flattenDeep=function(Ze){return Ze!=null&&Ze.length?yc(Ze,L):[]},gr.flattenDepth=function(Ze,vt){return Ze!=null&&Ze.length?yc(Ze,vt=vt===l?1:Zl(vt)):[]},gr.flip=function(Ze){return di(Ze,512)},gr.flow=Th,gr.flowRight=Cd,gr.fromPairs=function(Ze){for(var vt=-1,on=Ze==null?0:Ze.length,Fn={};++vt<on;){var Qn=Ze[vt];Fn[Qn[0]]=Qn[1]}return Fn},gr.functions=function(Ze){return Ze==null?[]:Wf(Ze,Ic(Ze))},gr.functionsIn=function(Ze){return Ze==null?[]:Wf(Ze,Zc(Ze))},gr.groupBy=Q3,gr.initial=function(Ze){return Ze!=null&&Ze.length?xd(Ze,0,-1):[]},gr.intersection=Gp,gr.intersectionBy=Jf,gr.intersectionWith=l3,gr.invert=wp,gr.invertBy=Hm,gr.invokeMap=hc,gr.iteratee=Xp,gr.keyBy=Ml,gr.keys=Ic,gr.keysIn=Zc,gr.map=Hc,gr.mapKeys=function(Ze,vt){var on={};return vt=na(vt,3),Od(Ze,function(Fn,Qn,mi){Fc(on,vt(Fn,Qn,mi),Fn)}),on},gr.mapValues=function(Ze,vt){var on={};return vt=na(vt,3),Od(Ze,function(Fn,Qn,mi){Fc(on,Qn,vt(Fn,Qn,mi))}),on},gr.matches=function(Ze){return pp(hd(Ze,1))},gr.matchesProperty=function(Ze,vt){return Ph(Ze,hd(vt,1))},gr.memoize=Jd,gr.merge=Wm,gr.mergeWith=Sh,gr.method=Zm,gr.methodOf=Og,gr.mixin=Nc,gr.negate=Wp,gr.nthArg=function(Ze){return Ze=Zl(Ze),Kl(function(vt){return Ih(vt,Ze)})},gr.omit=qm,gr.omitBy=function(Ze,vt){return Mp(Ze,Wp(na(vt)))},gr.once=function(Ze){return ch(2,Ze)},gr.orderBy=function(Ze,vt,on,Fn){return Ze==null?[]:(kl(vt)||(vt=vt==null?[]:[vt]),kl(on=Fn?l:on)||(on=on==null?[]:[on]),Ts(Ze,vt,on))},gr.over=h3,gr.overArgs=nm,gr.overEvery=ff,gr.overSome=Km,gr.partial=Nm,gr.partialRight=rm,gr.partition=tm,gr.pick=Zp,gr.pickBy=Mp,gr.property=Rc,gr.propertyOf=function(Ze){return function(vt){return Ze==null?l:Sc(Ze,vt)}},gr.pull=vh,gr.pullAll=uf,gr.pullAllBy=function(Ze,vt,on){return Ze&&Ze.length&&vt&&vt.length?Bp(Ze,vt,na(on,2)):Ze},gr.pullAllWith=function(Ze,vt,on){return Ze&&Ze.length&&vt&&vt.length?Bp(Ze,vt,l,on):Ze},gr.pullAt=T3,gr.range=mf,gr.rangeRight=p3,gr.rearg=im,gr.reject=function(Ze,vt){return(kl(Ze)?Ol:cp)(Ze,Wp(na(vt,3)))},gr.remove=function(Ze,vt){var on=[];if(!Ze||!Ze.length)return on;var Fn=-1,Qn=[],mi=Ze.length;for(vt=na(vt,3);++Fn<mi;){var ra=Ze[Fn];vt(ra,Fn,Ze)&&(on.push(ra),Qn.push(Fn))}return Qh(Ze,Qn),on},gr.rest=function(Ze,vt){if(typeof Ze!="function")throw new ts(n);return Kl(Ze,vt=vt===l?vt:Zl(vt))},gr.reverse=Qf,gr.sampleSize=function(Ze,vt,on){return vt=(on?as(Ze,vt,on):vt===l)?1:Zl(vt),(kl(Ze)?function(Fn,Qn){return fd(Qc(Fn),Rd(Qn,0,Fn.length))}:function(Fn,Qn){var mi=Qd(Fn);return fd(mi,Rd(Qn,0,mi.length))})(Ze,vt)},gr.set=function(Ze,vt,on){return Ze==null?Ze:Vp(Ze,vt,on)},gr.setWith=function(Ze,vt,on,Fn){return Fn=typeof Fn=="function"?Fn:l,Ze==null?Ze:Vp(Ze,vt,on,Fn)},gr.shuffle=function(Ze){return(kl(Ze)?function(vt){return fd(Qc(vt))}:function(vt){return fd(Qd(vt))})(Ze)},gr.slice=function(Ze,vt,on){var Fn=Ze==null?0:Ze.length;return Fn?(on&&typeof on!="number"&&as(Ze,vt,on)?(vt=0,on=Fn):(vt=vt==null?0:Zl(vt),on=on===l?Fn:Zl(on)),xd(Ze,vt,on)):[]},gr.sortBy=_u,gr.sortedUniq=function(Ze){return Ze&&Ze.length?fp(Ze):[]},gr.sortedUniqBy=function(Ze,vt){return Ze&&Ze.length?fp(Ze,na(vt,2)):[]},gr.split=function(Ze,vt,on){return on&&typeof on!="number"&&as(Ze,vt,on)&&(vt=on=l),(on=on===l?J:on>>>0)?(Ze=Ru(Ze))&&(typeof vt=="string"||vt!=null&&!_p(vt))&&!(vt=pd(vt))&&Vo(Ze)?Lh(Pn(Ze),0,on):Ze.split(vt,on):[]},gr.spread=function(Ze,vt){if(typeof Ze!="function")throw new ts(n);return vt=vt==null?0:Pu(Zl(vt),0),Kl(function(on){var Fn=on[vt],Qn=Lh(on,0,vt);return Fn&&vu(Qn,Fn),jl(Ze,this,Qn)})},gr.tail=function(Ze){var vt=Ze==null?0:Ze.length;return vt?xd(Ze,1,vt):[]},gr.take=function(Ze,vt,on){return Ze&&Ze.length?xd(Ze,0,(vt=on||vt===l?1:Zl(vt))<0?0:vt):[]},gr.takeRight=function(Ze,vt,on){var Fn=Ze==null?0:Ze.length;return Fn?xd(Ze,(vt=Fn-(vt=on||vt===l?1:Zl(vt)))<0?0:vt,Fn):[]},gr.takeRightWhile=function(Ze,vt){return Ze&&Ze.length?Rh(Ze,na(vt,3),!1,!0):[]},gr.takeWhile=function(Ze,vt){return Ze&&Ze.length?Rh(Ze,na(vt,3)):[]},gr.tap=function(Ze,vt){return vt(Ze),Ze},gr.throttle=function(Ze,vt,on){var Fn=!0,Qn=!0;if(typeof Ze!="function")throw new ts(n);return bc(on)&&(Fn="leading"in on?!!on.leading:Fn,Qn="trailing"in on?!!on.trailing:Qn),Wd(Ze,vt,{leading:Fn,maxWait:vt,trailing:Qn})},gr.thru=Fm,gr.toArray=k3,gr.toPairs=cm,gr.toPairsIn=dm,gr.toPath=function(Ze){return kl(Ze)?hl(Ze,Tc):Mh(Ze)?[Ze]:Qc(Yu(Ru(Ze)))},gr.toPlainObject=xp,gr.transform=function(Ze,vt,on){var Fn=kl(Ze),Qn=Fn||zh(Ze)||sm(Ze);if(vt=na(vt,4),on==null){var mi=Ze&&Ze.constructor;on=Qn?Fn?new mi:[]:bc(Ze)&&wh(mi)?ws(hu(Ze)):{}}return(Qn?Jl:Od)(Ze,function(ra,Ca,La){return vt(on,ra,Ca,La)}),on},gr.unary=function(Ze){return Pf(Ze,1)},gr.union=J3,gr.unionBy=Lm,gr.unionWith=u3,gr.uniq=function(Ze){return Ze&&Ze.length?gh(Ze):[]},gr.uniqBy=function(Ze,vt){return Ze&&Ze.length?gh(Ze,na(vt,2)):[]},gr.uniqWith=function(Ze,vt){return vt=typeof vt=="function"?vt:l,Ze&&Ze.length?gh(Ze,l,vt):[]},gr.unset=function(Ze,vt){return Ze==null||Np(Ze,vt)},gr.unzip=cf,gr.unzipWith=kf,gr.update=function(Ze,vt,on){return Ze==null?Ze:Im(Ze,vt,Om(on))},gr.updateWith=function(Ze,vt,on,Fn){return Fn=typeof Fn=="function"?Fn:l,Ze==null?Ze:Im(Ze,vt,Om(on),Fn)},gr.values=Qd,gr.valuesIn=function(Ze){return Ze==null?[]:mc(Ze,Zc(Ze))},gr.without=yp,gr.words=Kp,gr.wrap=function(Ze,vt){return Nm(Om(vt),Ze)},gr.xor=_h,gr.xorBy=Nh,gr.xorWith=df,gr.zip=np,gr.zipObject=function(Ze,vt){return of(Ze||[],vt||[],Ds)},gr.zipObjectDeep=function(Ze,vt){return of(Ze||[],vt||[],Vp)},gr.zipWith=Up,gr.entries=cm,gr.entriesIn=dm,gr.extend=Um,gr.extendWith=lm,Nc(gr,gr),gr.add=f3,gr.attempt=Sp,gr.camelCase=I3,gr.capitalize=Bf,gr.ceil=mm,gr.clamp=function(Ze,vt,on){return on===l&&(on=vt,vt=l),on!==l&&(on=(on=Cu(on))==on?on:0),vt!==l&&(vt=(vt=Cu(vt))==vt?vt:0),Rd(Cu(Ze),vt,on)},gr.clone=function(Ze){return hd(Ze,4)},gr.cloneDeep=function(Ze){return hd(Ze,5)},gr.cloneDeepWith=function(Ze,vt){return hd(Ze,5,vt=typeof vt=="function"?vt:l)},gr.cloneWith=function(Ze,vt){return hd(Ze,4,vt=typeof vt=="function"?vt:l)},gr.conformsTo=function(Ze,vt){return vt==null||ef(Ze,vt,Ic(vt))},gr.deburr=pf,gr.defaultTo=function(Ze,vt){return Ze==null||Ze!=Ze?vt:Ze},gr.divide=jh,gr.endsWith=function(Ze,vt,on){Ze=Ru(Ze),vt=pd(vt);var Fn=Ze.length,Qn=on=on===l?Fn:Rd(Zl(on),0,Fn);return(on-=vt.length)>=0&&Ze.slice(on,Qn)==vt},gr.eq=dh,gr.escape=function(Ze){return(Ze=Ru(Ze))&&Vn.test(Ze)?Ze.replace(Xn,Il):Ze},gr.escapeRegExp=function(Ze){return(Ze=Ru(Ze))&&ha.test(Ze)?Ze.replace(Wi,"\\$&"):Ze},gr.every=function(Ze,vt,on){var Fn=kl(Ze)?mu:Lp;return on&&as(Ze,vt,on)&&(vt=l),Fn(Ze,na(vt,3))},gr.find=Vm,gr.findIndex=uh,gr.findKey=function(Ze,vt){return js(Ze,na(vt,3),Od)},gr.findLast=Pc,gr.findLastIndex=lf,gr.findLastKey=function(Ze,vt){return js(Ze,na(vt,3),nf)},gr.floor=R3,gr.forEach=xh,gr.forEachRight=E3,gr.forIn=function(Ze,vt){return Ze==null?Ze:Cc(Ze,na(vt,3),Zc)},gr.forInRight=function(Ze,vt){return Ze==null?Ze:lu(Ze,na(vt,3),Zc)},gr.forOwn=function(Ze,vt){return Ze&&Od(Ze,na(vt,3))},gr.forOwnRight=function(Ze,vt){return Ze&&nf(Ze,na(vt,3))},gr.get=$m,gr.gt=bh,gr.gte=vp,gr.has=function(Ze,vt){return Ze!=null&&hs(Ze,vt,dp)},gr.hasIn=Yp,gr.head=tp,gr.identity=Sd,gr.includes=function(Ze,vt,on,Fn){Ze=Md(Ze)?Ze:Qd(Ze),on=on&&!Fn?Zl(on):0;var Qn=Ze.length;return on<0&&(on=Pu(Qn+on,0)),jm(Ze)?on<=Qn&&Ze.indexOf(vt,on)>-1:!!Qn&&Vl(Ze,vt,on)>-1},gr.indexOf=function(Ze,vt,on){var Fn=Ze==null?0:Ze.length;if(!Fn)return-1;var Qn=on==null?0:Zl(on);return Qn<0&&(Qn=Pu(Fn+Qn,0)),Vl(Ze,vt,Qn)},gr.inRange=function(Ze,vt,on){return vt=ld(vt),on===l?(on=vt,vt=0):on=ld(on),function(Fn,Qn,mi){return Fn>=ol(Qn,mi)&&Fn<Pu(Qn,mi)}(Ze=Cu(Ze),vt,on)},gr.invoke=c3,gr.isArguments=Yc,gr.isArray=kl,gr.isArrayBuffer=Rf,gr.isArrayLike=Md,gr.isArrayLikeObject=Dc,gr.isBoolean=function(Ze){return Ze===!0||Ze===!1||$u(Ze)&&vc(Ze)==Ue},gr.isBuffer=zh,gr.isDate=zm,gr.isElement=function(Ze){return $u(Ze)&&Ze.nodeType===1&&!rp(Ze)},gr.isEmpty=function(Ze){if(Ze==null)return!0;if(Md(Ze)&&(kl(Ze)||typeof Ze=="string"||typeof Ze.splice=="function"||zh(Ze)||sm(Ze)||Yc(Ze)))return!Ze.length;var vt=is(Ze);if(vt==Te||vt==mt)return!Ze.size;if(_c(Ze))return!cc(Ze).length;for(var on in Ze)if(As.call(Ze,on))return!1;return!0},gr.isEqual=function(Ze,vt){return kh(Ze,vt)},gr.isEqualWith=function(Ze,vt,on){var Fn=(on=typeof on=="function"?on:l)?on(Ze,vt):l;return Fn===l?kh(Ze,vt,l,on):!!Fn},gr.isError=hf,gr.isFinite=function(Ze){return typeof Ze=="number"&&sc(Ze)},gr.isFunction=wh,gr.isInteger=Of,gr.isLength=qp,gr.isMap=am,gr.isMatch=function(Ze,vt){return Ze===vt||Tf(Ze,vt,So(vt))},gr.isMatchWith=function(Ze,vt,on){return on=typeof on=="function"?on:l,Tf(Ze,vt,So(vt),on)},gr.isNaN=function(Ze){return om(Ze)&&Ze!=+Ze},gr.isNative=function(Ze){if(dc(Ze))throw new Jn("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return Ld(Ze)},gr.isNil=function(Ze){return Ze==null},gr.isNull=function(Ze){return Ze===null},gr.isNumber=om,gr.isObject=bc,gr.isObjectLike=$u,gr.isPlainObject=rp,gr.isRegExp=_p,gr.isSafeInteger=function(Ze){return Of(Ze)&&Ze>=-9007199254740991&&Ze<=G},gr.isSet=Lf,gr.isString=jm,gr.isSymbol=Mh,gr.isTypedArray=sm,gr.isUndefined=function(Ze){return Ze===l},gr.isWeakMap=function(Ze){return $u(Ze)&&is(Ze)==It},gr.isWeakSet=function(Ze){return $u(Ze)&&vc(Ze)=="[object WeakSet]"},gr.join=function(Ze,vt){return Ze==null?"":qc.call(Ze,vt)},gr.kebabCase=Cp,gr.last=wd,gr.lastIndexOf=function(Ze,vt,on){var Fn=Ze==null?0:Ze.length;if(!Fn)return-1;var Qn=Fn;return on!==l&&(Qn=(Qn=Zl(on))<0?Pu(Fn+Qn,0):ol(Qn,Fn-1)),vt==vt?function(mi,ra,Ca){for(var La=Qn+1;La--;)if(mi[La]===ra)return La;return La}(Ze,vt):co(Ze,yd,Qn,!0)},gr.lowerCase=qd,gr.lowerFirst=Ym,gr.lt=A3,gr.lte=hh,gr.max=function(Ze){return Ze&&Ze.length?Ah(Ze,Sd,ul):l},gr.maxBy=function(Ze,vt){return Ze&&Ze.length?Ah(Ze,na(vt,2),ul):l},gr.mean=function(Ze){return Ql(Ze,Sd)},gr.meanBy=function(Ze,vt){return Ql(Ze,na(vt,2))},gr.min=function(Ze){return Ze&&Ze.length?Ah(Ze,Sd,Jh):l},gr.minBy=function(Ze,vt){return Ze&&Ze.length?Ah(Ze,na(vt,2),Jh):l},gr.stubArray=gf,gr.stubFalse=fm,gr.stubObject=function(){return{}},gr.stubString=function(){return""},gr.stubTrue=function(){return!0},gr.multiply=zf,gr.nth=function(Ze,vt){return Ze&&Ze.length?Ih(Ze,Zl(vt)):l},gr.noConflict=function(){return al._===this&&(al._=ac),this},gr.noop=Td,gr.now=xc,gr.pad=function(Ze,vt,on){Ze=Ru(Ze);var Fn=(vt=Zl(vt))?Cn(Ze):0;if(!vt||Fn>=vt)return Ze;var Qn=(vt-Fn)/2;return Bn(gc(Qn),on)+Ze+Bn(oc(Qn),on)},gr.padEnd=function(Ze,vt,on){Ze=Ru(Ze);var Fn=(vt=Zl(vt))?Cn(Ze):0;return vt&&Fn<vt?Ze+Bn(vt-Fn,on):Ze},gr.padStart=function(Ze,vt,on){Ze=Ru(Ze);var Fn=(vt=Zl(vt))?Cn(Ze):0;return vt&&Fn<vt?Bn(vt-Fn,on)+Ze:Ze},gr.parseInt=function(Ze,vt,on){return on||vt==null?vt=0:vt&&(vt=+vt),qu(Ru(Ze).replace(ai,""),vt||0)},gr.random=function(Ze,vt,on){if(on&&typeof on!="boolean"&&as(Ze,vt,on)&&(vt=on=l),on===l&&(typeof vt=="boolean"?(on=vt,vt=l):typeof Ze=="boolean"&&(on=Ze,Ze=l)),Ze===l&&vt===l?(Ze=0,vt=1):(Ze=ld(Ze),vt===l?(vt=Ze,Ze=0):vt=ld(vt)),Ze>vt){var Fn=Ze;Ze=vt,vt=Fn}if(on||Ze%1||vt%1){var Qn=ah();return ol(Ze+Qn*(vt-Ze+Pl("1e-"+((Qn+"").length-1))),vt)}return ql(Ze,vt)},gr.reduce=function(Ze,vt,on){var Fn=kl(Ze)?Ku:jd,Qn=arguments.length<3;return Fn(Ze,na(vt,4),on,Qn,oh)},gr.reduceRight=function(Ze,vt,on){var Fn=kl(Ze)?Ul:jd,Qn=arguments.length<3;return Fn(Ze,na(vt,4),on,Qn,tf)},gr.repeat=function(Ze,vt,on){return vt=(on?as(Ze,vt,on):vt===l)?1:Zl(vt),Xd(Ru(Ze),vt)},gr.replace=function(){var Ze=arguments,vt=Ru(Ze[0]);return Ze.length<3?vt:vt.replace(Ze[1],Ze[2])},gr.result=function(Ze,vt,on){var Fn=-1,Qn=(vt=Oh(vt,Ze)).length;for(Qn||(Qn=1,Ze=l);++Fn<Qn;){var mi=Ze==null?l:Ze[Tc(vt[Fn])];mi===l&&(Fn=Qn,mi=on),Ze=wh(mi)?mi.call(Ze):mi}return Ze},gr.round=yf,gr.runInContext=jt,gr.sample=function(Ze){return(kl(Ze)?Zh:function(vt){return Zh(Qd(vt))})(Ze)},gr.size=function(Ze){if(Ze==null)return 0;if(Md(Ze))return jm(Ze)?Cn(Ze):Ze.length;var vt=is(Ze);return vt==Te||vt==mt?Ze.size:cc(Ze).length},gr.snakeCase=d3,gr.some=function(Ze,vt,on){var Fn=kl(Ze)?ad:rf;return on&&as(Ze,vt,on)&&(vt=l),Fn(Ze,na(vt,3))},gr.sortedIndex=function(Ze,vt){return af(Ze,vt)},gr.sortedIndexBy=function(Ze,vt,on){return Yf(Ze,vt,na(on,2))},gr.sortedIndexOf=function(Ze,vt){var on=Ze==null?0:Ze.length;if(on){var Fn=af(Ze,vt);if(Fn<on&&dh(Ze[Fn],vt))return Fn}return-1},gr.sortedLastIndex=function(Ze,vt){return af(Ze,vt,!0)},gr.sortedLastIndexBy=function(Ze,vt,on){return Yf(Ze,vt,na(on,2),!0)},gr.sortedLastIndexOf=function(Ze,vt){if(Ze!=null&&Ze.length){var on=af(Ze,vt,!0)-1;if(dh(Ze[on],vt))return on}return-1},gr.startCase=hm,gr.startsWith=function(Ze,vt,on){return Ze=Ru(Ze),on=on==null?0:Rd(Zl(on),0,Ze.length),vt=pd(vt),Ze.slice(on,on+vt.length)==vt},gr.subtract=eg,gr.sum=function(Ze){return Ze&&Ze.length?Wu(Ze,Sd):0},gr.sumBy=function(Ze,vt){return Ze&&Ze.length?Wu(Ze,na(vt,2)):0},gr.template=function(Ze,vt,on){var Fn=gr.templateSettings;on&&as(Ze,vt,on)&&(vt=l),Ze=Ru(Ze),vt=lm({},vt,Fn,wi);var Qn,mi,ra=lm({},vt.imports,Fn.imports,wi),Ca=Ic(ra),La=mc(ra,Ca),Oa=0,fo=vt.interpolate||Ni,Ho="__p += '",qs=fa((vt.escape||Ni).source+"|"+fo.source+"|"+(fo===xi?Ln:Ni).source+"|"+(vt.evaluate||Ni).source+"|$","g"),Ys="//# sourceURL="+(As.call(vt,"sourceURL")?(vt.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Xl+"]")+`
- `;Ze.replace(qs,function(es,Qs,Ms,Tl,Al,au){return Ms||(Ms=Tl),Ho+=Ze.slice(Oa,au).replace(za,Ss),Qs&&(Qn=!0,Ho+=`' +
- __e(`+Qs+`) +
- '`),Al&&(mi=!0,Ho+=`';
- `+Al+`;
- __p += '`),Ms&&(Ho+=`' +
- ((__t = (`+Ms+`)) == null ? '' : __t) +
- '`),Oa=au+es.length,es}),Ho+=`';
- `;var _l=As.call(vt,"variable")&&vt.variable;if(_l){if(fn.test(_l))throw new Jn("Invalid `variable` option passed into `_.template`")}else Ho=`with (obj) {
- `+Ho+`
- }
- `;Ho=(mi?Ho.replace($n,""):Ho).replace(Xr,"$1").replace(ti,"$1;"),Ho="function("+(_l||"obj")+`) {
- `+(_l?"":`obj || (obj = {});
- `)+"var __t, __p = ''"+(Qn?", __e = _.escape":"")+(mi?`, __j = Array.prototype.join;
- function print() { __p += __j.call(arguments, '') }
- `:`;
- `)+Ho+`return __p
- }`;var Mo=Sp(function(){return li(Ca,Ys+"return "+Ho).apply(l,La)});if(Mo.source=Ho,hf(Mo))throw Mo;return Mo},gr.times=function(Ze,vt){if((Ze=Zl(Ze))<1||Ze>G)return[];var on=J,Fn=ol(Ze,J);vt=na(vt),Ze-=J;for(var Qn=ud(Fn,vt);++on<Ze;)vt(on);return Qn},gr.toFinite=ld,gr.toInteger=Zl,gr.toLength=Ch,gr.toLower=function(Ze){return Ru(Ze).toLowerCase()},gr.toNumber=Cu,gr.toSafeInteger=function(Ze){return Ze?Rd(Zl(Ze),-9007199254740991,G):Ze===0?Ze:0},gr.toString=Ru,gr.toUpper=function(Ze){return Ru(Ze).toUpperCase()},gr.trim=function(Ze,vt,on){if((Ze=Ru(Ze))&&(on||vt===l))return Xc(Ze);if(!Ze||!(vt=pd(vt)))return Ze;var Fn=Pn(Ze),Qn=Pn(vt);return Lh(Fn,Yh(Fn,Qn),ka(Fn,Qn)+1).join("")},gr.trimEnd=function(Ze,vt,on){if((Ze=Ru(Ze))&&(on||vt===l))return Ze.slice(0,Qe(Ze)+1);if(!Ze||!(vt=pd(vt)))return Ze;var Fn=Pn(Ze);return Lh(Fn,0,ka(Fn,Pn(vt))+1).join("")},gr.trimStart=function(Ze,vt,on){if((Ze=Ru(Ze))&&(on||vt===l))return Ze.replace(ai,"");if(!Ze||!(vt=pd(vt)))return Ze;var Fn=Pn(Ze);return Lh(Fn,Yh(Fn,Pn(vt))).join("")},gr.truncate=function(Ze,vt){var on=30,Fn="...";if(bc(vt)){var Qn="separator"in vt?vt.separator:Qn;on="length"in vt?Zl(vt.length):on,Fn="omission"in vt?pd(vt.omission):Fn}var mi=(Ze=Ru(Ze)).length;if(Vo(Ze)){var ra=Pn(Ze);mi=ra.length}if(on>=mi)return Ze;var Ca=on-Cn(Fn);if(Ca<1)return Fn;var La=ra?Lh(ra,0,Ca).join(""):Ze.slice(0,Ca);if(Qn===l)return La+Fn;if(ra&&(Ca+=La.length-Ca),_p(Qn)){if(Ze.slice(Ca).search(Qn)){var Oa,fo=La;for(Qn.global||(Qn=fa(Qn.source,Ru(hr.exec(Qn))+"g")),Qn.lastIndex=0;Oa=Qn.exec(fo);)var Ho=Oa.index;La=La.slice(0,Ho===l?Ca:Ho)}}else if(Ze.indexOf(pd(Qn),Ca)!=Ca){var qs=La.lastIndexOf(Qn);qs>-1&&(La=La.slice(0,qs))}return La+Fn},gr.unescape=function(Ze){return(Ze=Ru(Ze))&&Kn.test(Ze)?Ze.replace(gn,yt):Ze},gr.uniqueId=function(Ze){var vt=++yl;return Ru(Ze)+vt},gr.upperCase=eh,gr.upperFirst=Vf,gr.each=xh,gr.eachRight=E3,gr.first=tp,Nc(gr,(Nf={},Od(gr,function(Ze,vt){As.call(gr.prototype,vt)||(Nf[vt]=Ze)}),Nf),{chain:!1}),gr.VERSION="4.17.21",Jl(["bind","bindKey","curry","curryRight","partial","partialRight"],function(Ze){gr[Ze].placeholder=gr}),Jl(["drop","take"],function(Ze,vt){vs.prototype[Ze]=function(on){on=on===l?1:Pu(Zl(on),0);var Fn=this.__filtered__&&!vt?new vs(this):this.clone();return Fn.__filtered__?Fn.__takeCount__=ol(on,Fn.__takeCount__):Fn.__views__.push({size:ol(on,J),type:Ze+(Fn.__dir__<0?"Right":"")}),Fn},vs.prototype[Ze+"Right"]=function(on){return this.reverse()[Ze](on).reverse()}}),Jl(["filter","map","takeWhile"],function(Ze,vt){var on=vt+1,Fn=on==1||on==3;vs.prototype[Ze]=function(Qn){var mi=this.clone();return mi.__iteratees__.push({iteratee:na(Qn,3),type:on}),mi.__filtered__=mi.__filtered__||Fn,mi}}),Jl(["head","last"],function(Ze,vt){var on="take"+(vt?"Right":"");vs.prototype[Ze]=function(){return this[on](1).value()[0]}}),Jl(["initial","tail"],function(Ze,vt){var on="drop"+(vt?"":"Right");vs.prototype[Ze]=function(){return this.__filtered__?new vs(this):this[on](1)}}),vs.prototype.compact=function(){return this.filter(Sd)},vs.prototype.find=function(Ze){return this.filter(Ze).head()},vs.prototype.findLast=function(Ze){return this.reverse().find(Ze)},vs.prototype.invokeMap=Kl(function(Ze,vt){return typeof Ze=="function"?new vs(this):this.map(function(on){return kc(on,Ze,vt)})}),vs.prototype.reject=function(Ze){return this.filter(Wp(na(Ze)))},vs.prototype.slice=function(Ze,vt){Ze=Zl(Ze);var on=this;return on.__filtered__&&(Ze>0||vt<0)?new vs(on):(Ze<0?on=on.takeRight(-Ze):Ze&&(on=on.drop(Ze)),vt!==l&&(on=(vt=Zl(vt))<0?on.dropRight(-vt):on.take(vt-Ze)),on)},vs.prototype.takeRightWhile=function(Ze){return this.reverse().takeWhile(Ze).reverse()},vs.prototype.toArray=function(){return this.take(J)},Od(vs.prototype,function(Ze,vt){var on=/^(?:filter|find|map|reject)|While$/.test(vt),Fn=/^(?:head|last)$/.test(vt),Qn=gr[Fn?"take"+(vt=="last"?"Right":""):vt],mi=Fn||/^find/.test(vt);Qn&&(gr.prototype[vt]=function(){var ra=this.__wrapped__,Ca=Fn?[1]:arguments,La=ra instanceof vs,Oa=Ca[0],fo=La||kl(ra),Ho=function(Qs){var Ms=Qn.apply(gr,vu([Qs],Ca));return Fn&&qs?Ms[0]:Ms};fo&&on&&typeof Oa=="function"&&Oa.length!=1&&(La=fo=!1);var qs=this.__chain__,Ys=!!this.__actions__.length,_l=mi&&!qs,Mo=La&&!Ys;if(!mi&&fo){ra=Mo?ra:new vs(this);var es=Ze.apply(ra,Ca);return es.__actions__.push({func:Fm,args:[Ho],thisArg:l}),new Fo(es,qs)}return _l&&Mo?Ze.apply(this,Ca):(es=this.thru(Ho),_l?Fn?es.value()[0]:es.value():es)})}),Jl(["pop","push","shift","sort","splice","unshift"],function(Ze){var vt=bl[Ze],on=/^(?:push|sort|unshift)$/.test(Ze)?"tap":"thru",Fn=/^(?:pop|shift)$/.test(Ze);gr.prototype[Ze]=function(){var Qn=arguments;if(Fn&&!this.__chain__){var mi=this.value();return vt.apply(kl(mi)?mi:[],Qn)}return this[on](function(ra){return vt.apply(kl(ra)?ra:[],Qn)})}}),Od(vs.prototype,function(Ze,vt){var on=gr[vt];if(on){var Fn=on.name+"";As.call(ii,Fn)||(ii[Fn]=[]),ii[Fn].push({name:vt,func:on})}}),ii[Ot(l,2).name]=[{name:"wrapper",func:l}],vs.prototype.clone=function(){var Ze=new vs(this.__wrapped__);return Ze.__actions__=Qc(this.__actions__),Ze.__dir__=this.__dir__,Ze.__filtered__=this.__filtered__,Ze.__iteratees__=Qc(this.__iteratees__),Ze.__takeCount__=this.__takeCount__,Ze.__views__=Qc(this.__views__),Ze},vs.prototype.reverse=function(){if(this.__filtered__){var Ze=new vs(this);Ze.__dir__=-1,Ze.__filtered__=!0}else(Ze=this.clone()).__dir__*=-1;return Ze},vs.prototype.value=function(){var Ze=this.__wrapped__.value(),vt=this.__dir__,on=kl(Ze),Fn=vt<0,Qn=on?Ze.length:0,mi=function(au,sl,cl){for(var wc=-1,nc=cl.length;++wc<nc;){var Wc=cl[wc],pu=Wc.size;switch(Wc.type){case"drop":au+=pu;break;case"dropRight":sl-=pu;break;case"take":sl=ol(sl,au+pu);break;case"takeRight":au=Pu(au,sl-pu)}}return{start:au,end:sl}}(0,Qn,this.__views__),ra=mi.start,Ca=mi.end,La=Ca-ra,Oa=Fn?Ca:ra-1,fo=this.__iteratees__,Ho=fo.length,qs=0,Ys=ol(La,this.__takeCount__);if(!on||!Fn&&Qn==La&&Ys==La)return bd(Ze,this.__actions__);var _l=[];e:for(;La--&&qs<Ys;){for(var Mo=-1,es=Ze[Oa+=vt];++Mo<Ho;){var Qs=fo[Mo],Ms=Qs.iteratee,Tl=Qs.type,Al=Ms(es);if(Tl==2)es=Al;else if(!Al){if(Tl==1)continue e;break e}}_l[qs++]=es}return _l},gr.prototype.at=em,gr.prototype.chain=function(){return D3(this)},gr.prototype.commit=function(){return new Fo(this.value(),this.__chain__)},gr.prototype.next=function(){this.__values__===l&&(this.__values__=k3(this.value()));var Ze=this.__index__>=this.__values__.length;return{done:Ze,value:Ze?l:this.__values__[this.__index__++]}},gr.prototype.plant=function(Ze){for(var vt,on=this;on instanceof io;){var Fn=Vc(on);Fn.__index__=0,Fn.__values__=l,vt?Qn.__wrapped__=Fn:vt=Fn;var Qn=Fn;on=on.__wrapped__}return Qn.__wrapped__=Ze,vt},gr.prototype.reverse=function(){var Ze=this.__wrapped__;if(Ze instanceof vs){var vt=Ze;return this.__actions__.length&&(vt=new vs(this)),(vt=vt.reverse()).__actions__.push({func:Fm,args:[Qf],thisArg:l}),new Fo(vt,this.__chain__)}return this.thru(Qf)},gr.prototype.toJSON=gr.prototype.valueOf=gr.prototype.value=function(){return bd(this.__wrapped__,this.__actions__)},gr.prototype.first=gr.prototype.head,ku&&(gr.prototype[ku]=function(){return this}),gr}();Ur?((Ur.exports=Rt)._=Rt,Mn._=Rt):al._=Rt}).call(commonjsGlobal)}),MrxDbgUiPrBaseReturn;async function useCanvasResizeListener(t,e,l=100){if(!store.state.MxFun)return void console.error("请先调用loadCoreCode方法! ");if(!t)return void console.error("请确保mxdrawObj参数 是通过调用MxFun.createMxObject的callback回调函数拿到的mxDraw对象");let n=t;if(!n.isLoadCanvasResizeListene){let u;n.isLoadCanvasResizeListene=!0,t.addEvent("addResizeEvent",y=>{u=y}),await dynamicImport("element-resize-event-polyfill");let c=createCanvasParent(e);c.addEventListener?c.addEventListener("resize",lodash.throttle(function(y){u&&u()},l),!1):console.log("mx: parentdiv[addEventListener] invalid")}}class McEdGetPointWorldDrawObject{constructor(){var e;this._McEdGetPointWorldDraw=new((e=store.state.MxFun)===null||e===void 0?void 0:e.getMxJigCmdManager().McEdGetPointWorldDrawObjectClass()),this._get=()=>this._McEdGetPointWorldDraw}drawCircle(e,l){return this._McEdGetPointWorldDraw.drawCircle(e,l)}drawLine(e,l){return this._McEdGetPointWorldDraw.drawLine(e,l)}drawSolid(e,l){this.drawSolid(e,l)}drawRect(e,l){return this._McEdGetPointWorldDraw.drawRect(e,l)}drawEntity(e,l){return this._McEdGetPointWorldDraw.drawEntity(e,l)}drawMcDbEntity(e,l){return this._McEdGetPointWorldDraw.drawMcDbEntity(e,l)}drawMcDbLine(e,l,n,u,c,y){return this._McEdGetPointWorldDraw.drawMcDbLine(e,l,n,u,c,y)}drawText(e,l,n,u){return this._McEdGetPointWorldDraw.drawText(e,l,n,u)}setDraw(e){return this._McEdGetPointWorldDraw.setDraw(e)}setColor(e){return this._McEdGetPointWorldDraw.setColor(e)}getColor(){return this._McEdGetPointWorldDraw.getColor()}drawCustomEntity(e,l){return this._McEdGetPointWorldDraw.drawCustomEntity(e,l)}}(function(t){t[t.kCancel=-2]="kCancel",t[t.kNone=-1]="kNone",t[t.kOk=0]="kOk",t[t.kKeyWord=1]="kKeyWord"})(MrxDbgUiPrBaseReturn||(MrxDbgUiPrBaseReturn={}));var MrxDbgUiPrBaseReturn$1=MrxDbgUiPrBaseReturn,MxCursorType,DynamicInputType,DetailedResult,UserInputControls;(function(t){t[t.kNormal=0]="kNormal",t[t.kRect=1]="kRect",t[t.kCross=2]="kCross"})(MxCursorType||(MxCursorType={})),function(t){t[t.kNoInput=0]="kNoInput",t[t.kXYCoordInput=1]="kXYCoordInput",t[t.kDistanceInput=2]="kDistanceInput",t[t.kDynTip=3]="kDynTip",t[t.kAutoInput=4]="kAutoInput",t[t.kAngleInput=5]="kAngleInput"}(DynamicInputType||(DynamicInputType={})),function(t){t[t.kUnknown=1]="kUnknown",t[t.kTouchDownIn=2]="kTouchDownIn",t[t.kTouchUpIn=3]="kTouchUpIn",t[t.kMouseLeftIn=4]="kMouseLeftIn",t[t.kMouseLeftUpIn=5]="kMouseLeftUpIn",t[t.kMouseRightIn=6]="kMouseRightIn",t[t.kKeyIn=7]="kKeyIn",t[t.kCoordIn=8]="kCoordIn",t[t.kNullEnterIn=9]="kNullEnterIn",t[t.kNullSpaceIn=10]="kNullSpaceIn",t[t.kEcsIn=11]="kEcsIn",t[t.kNewCommadIn=12]="kNewCommadIn",t[t.kCodeAbort=13]="kCodeAbort"}(DetailedResult||(DetailedResult={})),function(t){t[t.kGovernedByOrthoMode=1]="kGovernedByOrthoMode",t[t.kNullResponseAccepted=2]="kNullResponseAccepted",t[t.kDontEchoCancelForCtrlC=4]="kDontEchoCancelForCtrlC",t[t.kDontUpdateLastPoint=8]="kDontUpdateLastPoint",t[t.kNoDwgLimitsChecking=16]="kNoDwgLimitsChecking",t[t.kNoZeroResponseAccepted=32]="kNoZeroResponseAccepted",t[t.kNoNegativeResponseAccepted=64]="kNoNegativeResponseAccepted",t[t.kAccept3dCoordinates=128]="kAccept3dCoordinates",t[t.kAcceptMouseUpAsPoint=256]="kAcceptMouseUpAsPoint",t[t.kAnyBlankTerminatesInput=512]="kAnyBlankTerminatesInput",t[t.kInitialBlankTerminatesInput=1024]="kInitialBlankTerminatesInput",t[t.kAcceptOtherInputString=2048]="kAcceptOtherInputString",t[t.kGovernedByUCSDetect=4096]="kGovernedByUCSDetect",t[t.kNoZDirectionOrtho=8192]="kNoZDirectionOrtho",t[t.kSpacesInAccepted=16384]="kSpacesInAccepted"}(UserInputControls||(UserInputControls={}));class MrxDbgUiPrBase{constructor(e){this.imp=e,this.status=MrxDbgUiPrBaseReturn$1.kCancel}keyWords(){return this.imp.keyWords()}setKeyWords(e){return this.imp.setKeyWords(e)}message(){return this.imp.message()}setMessage(e){return this.imp.setMessage(e)}clearLastInputPoint(){this.imp.clearLastInputPoint()}setLastInputPoint(e){this.imp.SetLASTPOINT(e)}keyWordPicked(){return this.imp.keyWordPicked()}isKeyWordPicked(e){return this.status==MrxDbgUiPrBaseReturn$1.kKeyWord&&this.imp.isKeyWordPicked(e)}setUserDraw(e){if(typeof e!="function")return this.imp.setUserDraw(e._get?e._get():e);{const l=new McEdGetPointWorldDrawObject;l.setDraw(e),this.imp.setUserDraw(l._get())}}getDetailedResult(){return this.imp.getDetailedResult()}getStatus(){return this.status}drawReserve(e){return this.imp.drawReserve(e)}setInputToucheType(e){return this.imp.setInputToucheType(e)}getInputToucheType(){return this.imp.getInputToucheType()}setCursorType(e){this.imp.setCursorType(e)}getCursorType(){return this.imp.getCursorType()}setDynamicInputType(e){this.imp.setDynamicInputType(e)}getDynamicInputType(){return this.imp.getDynamicInputType()}isDisableDynInput(){return this.imp.isDisableDynInput()}setDisableDynInput(e){return this.imp.setDisableDynInput(e)}setDisableOsnap(e){return this.imp.setDisableOsnap(e)}isOffsetInputPostion(){return this.imp.isOffsetInputPostion()}setOffsetInputPostion(e){return this.imp.setOffsetInputPostion(e)}isDisableOsnap(){return this.imp.isDisableOsnap()}setDisableDynamicTrace(e){this.imp.setDisableDynamicTrace(e)}isDisableDynamicTrace(){return this.imp.isDisableDynamicTrace()}setDisablePolarAxisTrace(e){this.imp.setDisablePolarAxisTrace(e)}isDisablePolarAxisTrace(){return this.imp.isDisablePolarAxisTrace()}setDisableGridTrace(e){this.imp.setDisableGridTrace(e)}isDisableGridTrace(){return this.imp.isDisableGridTrace()}setDisableOrthoTrace(e){this.imp.setDisableOrthoTrace(e)}isDisableOrthoTrace(){return this.imp.isDisableOrtho()}disableAllTrace(e=!0){this.imp.disableAllTrace(e)}userInputControls(){return this.imp.userInputControls()}setUserInputControls(e){this.imp.setUserInputControls(e)}}class MrxDbgUiPrPoint extends MrxDbgUiPrBase{constructor(){var e;super(new((e=store.state.MxFun)===null||e===void 0?void 0:e.getMxJigCmdManager().getMrxDbgUiPrPointClass()))}value(){return this.imp.value()}getCADValue(){return this.imp.getCADValue()}valueDocCoord(){return this.imp.valueDocCoord()}basePt(){return this.imp.basePt()}setBasePt(e){return this.imp.setBasePt(e)}setUseBasePt(e){return this.imp.setUseBasePt(e)}go(e){let l=this;return e?(l.imp.go(n=>{l.status=n,e(n)}),new Promise((n,u)=>{n(null)})):new Promise((n,u)=>{l.imp.go(c=>{l.status=c,n(c!=0?null:l.imp.value())})})}goWhile(e,l){return this.imp.goWhile(e,l)}abort(e){this.imp.abort(e)}}class MxVueComandLine{constructor(){this.msCmdText="",this.msCmdDisplay="",this.msCmdTip="",this.mxFunObject=void 0,this.mountUpDisplayFun=e=>{this.mUpDisplayFun=e},this.setCmdText=e=>{this.msCmdText=e},this.getCmdText=()=>this.msCmdText,this.getCmdDisplay=()=>this.msCmdDisplay,this.setCmdDisplay=e=>{this.msCmdDisplay=e},this.addCmdDisplay=e=>{this.msCmdDisplay.length>1024?(this.msCmdDisplay=this.msCmdDisplay.substring(this.msCmdDisplay.length-1024,this.msCmdDisplay.length),this.msCmdDisplay=this.msCmdDisplay+e):this.msCmdDisplay=this.msCmdDisplay+e},this.setCmdTip=e=>{this.msCmdTip=e},this.getCmdTip=()=>this.msCmdTip}upDisplay(){const{msCmdTip:e,msCmdDisplay:l,msCmdText:n}=this;this.mUpDisplayFun!=null&&this.mUpDisplayFun({msCmdTip:e,msCmdDisplay:l,msCmdText:n})}}const MxInputType={kNoInput:0,kXYCoordInput:1,kDistanceInput:2,kDynTip:3},MxInputPostionType={kRelative:0,kAbsolutely:1};class MxDynamicInput{constructor(){this.mType=MxInputType.kNoInput,this.mPos=[0,0],this.mTip="",this.mValue1="",this.mValue1Pos=[0,0],this.mValue2="",this.mValue2Pos=[0,0],this.misShow=!1,this.focusIndex=0,this.mOnKeydownEvent=void 0,this.mFocusValue="",this.setFocusValue=e=>{this.mFocusValue=e},this.getFocusValue=()=>this.mFocusValue,this.getFocusIndex=()=>this.focusIndex,this.setFocusIndex=e=>{this.focusIndex=e},this.mountKeydownEvent=e=>{this.mOnKeydownEvent=e},this.onKeydown=e=>{this.mOnKeydownEvent!=null&&this.mOnKeydownEvent(e)},this.setType=e=>{this.mType=e},this.getType=()=>this.mType,this.isShow=()=>this.misShow,this.setPos=e=>{this.mPos=e},this.setTip=e=>{this.mTip=e},this.setValue1=e=>{this.mValue1=e},this.getValue1=()=>this.mValue1,this.setValue1Pos=e=>{this.mValue1Pos=e},this.setValue2=e=>{this.mValue2=e},this.getValue2=()=>this.mValue2,this.setValue2Pos=e=>{this.mValue2Pos=e},this.setShow=e=>{this.misShow=e},this.getData=()=>{if(!this.misShow)return;let e={list:[{value:"",readonly:!0},{value:"",readonly:!1},{value:"",readonly:!1}],pos:this.mPos,postype:MxInputPostionType.kRelative};return this.mType!=MxInputType.kNoInput?(this.mType==MxInputType.kXYCoordInput?(e.list[0].show=!0,e.list[0].value=this.mTip,e.list[0].readonly=!0,e.list[1].show=!0,e.list[1].value=this.mValue1,e.list[1].readonly=!1,e.list[2].show=!0,e.list[2].value=this.mValue2,e.list[2].readonly=!1):this.mType==MxInputType.kDistanceInput?(e.list[0].show=!0,e.list[0].value=this.mTip,e.list[0].readonly=!0,e.list[1].show=!0,e.list[1].value=this.mValue1,e.list[1].readonly=!1,e.list[1].pos=this.mValue1Pos,e.list[2].show=!0,e.list[2].value=this.mValue2,e.list[2].readonly=!1,e.list[2].pos=this.mValue2Pos,e.postype=MxInputPostionType.kAbsolutely):this.mType==MxInputType.kDynTip?(e.list[0].show=!0,e.list[0].value=this.mTip,e.list[0].readonly=!0,e.list[1].show=!1,e.list[2].show=!1):e=void 0,e):void 0}}}const CursorType={kNormal:"Normal",kRect:"Rect",kCross:"Cross",kPan:"Pan"};class MxVueInterface{constructor(){this.mSetCoordFun=void 0,this.mUpdateCursorFun=void 0,this.mOnKeydownEvent=void 0,this.mCursorType=CursorType.kNormal,this.mComandLine=new MxVueComandLine,this.mdynamicInput=new MxDynamicInput,this.mMxEvents={},this.mountSetCoordFun=e=>{this.mSetCoordFun=e},this.mountUpdateCursorFun=e=>{this.mUpdateCursorFun=e},this.mountKeydownEvent=e=>{this.mOnKeydownEvent=e},this.onKeydown=e=>{this.mOnKeydownEvent!=null&&this.mOnKeydownEvent(e)},this.setTipCoord=e=>{this.mSetCoordFun!=null&&this.mSetCoordFun(e)},this.getCursorType=()=>this.mCursorType,this.setCursorType=e=>{if(typeof e=="number")switch(e){case 0:this.mCursorType=CursorType.kNormal;break;case 1:this.mCursorType=CursorType.kRect;break;case 2:this.mCursorType=CursorType.kCross;break;case 3:this.mCursorType=CursorType.kPan}else this.mCursorType=e;this.mUpdateCursorFun!=null&&this.mUpdateCursorFun(this.mCursorType)},this.getTitle=()=>this.mTitle,this.getTopButtonBarData=()=>this.mTopButtonBarData,this.getMenuBarData=()=>this.mMenuBarData,this.getRighButtonBarData=()=>this.mRighButtonBarData,this.getLeftButtonBarData=()=>this.mLeftButtonBarData,this.getTitleButtonBarData=()=>this.mTitleButtonBarData,this.getLayerComboxData=()=>this.mLayerComboxData,this.getColorComboxData=()=>this.mColorComboxData,this.getLinetypeComboxData=()=>this.mLinetypeComboxData,this.getFooterData=()=>this.mFooterData,this.sendStringToExecute=e=>{this.mxFunObject.sendStringToExecute(e)},this.getCmdLine=()=>this.mComandLine,this.getDynamicInput=()=>this.mdynamicInput,this.init=e=>{this.mxFunObject=e},this.OnMxEvent=e=>{const l=e.name;if(l==null)return;const n=this.mMxEvents[l];n?.(e.param)},this.mountMxEvent=(e,l)=>{this.mMxEvents[e]=l}}}const mxUiData$1=new MxVueInterface;function createReandomId(t=10){return new Number(Math.random().toString().substr(3,t)+Date.now()).toString(36)}let Node$1=class extends PubSub$1{constructor(){super(...arguments),this.parent=null,this.children=[]}add(...e){if(e.length>1){for(let n=0;n<e.length;n++){const u=e[n];this.add(u)}return this}const l=e[0];return l===this?(console.error("Node.add 不可以添加它自己"),this):(l&&(l.parent!==null&&l.parent.remove(l),l.parent=this,this.children.push(l)),this)}remove(...e){e.length>1&&e.forEach(u=>{this.remove(u)});const l=e[0],n=this.children.indexOf(l);return n!==-1&&(l.parent=null,this.children.splice(n,1)),this}removeFromParent(){const e=this.parent;return e!==null&&e.remove(this),this}clear(){for(let e=0;e<this.children.length;e++)this.children[e].parent=null;return this.children.length=0,this}getNodeByProperty(e,l){if(this[e]===l)return this;for(let n=0,u=this.children.length;n<u;n++){const c=this.children[n].getNodeByProperty(e,l);if(c!==void 0)return c}}getNodesByProperty(e,l){let n=[];this[e]===l&&n.push(this);for(let u=0,c=this.children.length;u<c;u++){const y=this.children[u].getNodesByProperty(e,l);y.length>0&&(n=n.concat(y))}return n}traverse(e){e(this);const l=this.children;for(let n=0,u=l.length;n<u;n++)l[n].traverse(e)}traverseParent(e){this.parent!==null&&e(this.parent)!==!1&&this.parent.traverseParent(e)}emit(e,...l){super.emit(e,...l),this.traverseParent(n=>(n.emit(e,...l),l?.isEventBubbling!==!1&&void 0))}};class RenderOrderNode extends Node$1{constructor(){super(),this.renderOrder=30}setRenderOrder(e){this.renderOrder=e}getRenderOrder(){return this.renderOrder}top(){var e;if(!this.parent)return;let l=Math.max(...(e=this.parent)===null||e===void 0?void 0:e.children.map(({renderOrder:n})=>n));l!==this.renderOrder&&l++,this.setRenderOrder(l)}bottom(){var e;if(!this.parent)return;let l=Math.min(...(e=this.parent)===null||e===void 0?void 0:e.children.map(({renderOrder:n})=>n));l--,this.setRenderOrder(l)}restoreDefaultRenderOrder(){this.renderOrder=30}}class Layer extends RenderOrderNode{constructor(e){super(),this.isLayer=!0,this.getLayerMap=()=>this.getDatabase()._mxDatabase.mapNameToLayer,this.getEntityMap=()=>this.getDatabase()._mxDatabase.mapIdToEntity,this.getRootLayerName=()=>this.getNames()[0]||"0";const l=typeof e=="string"?e:Date.now()+Math.random().toString(36).substr(2,9);Object.defineProperty(this,"name",{get:()=>l,set(){throw new Error("不能修改Layer.name值, 因为它是Layer 实例的唯一标识")},configurable:!1});let n=this.renderOrder;Object.defineProperty(this,"renderOrder",{get:()=>n,set(u){this.getLayer().group.renderOrder=u,n=u,MxFun.updateDisplay()}})}get visible(){const e=this.getDatabase().getLayer(this.name);return!e||e.getVisible()}set visible(e){this.getDatabase().showLayer(this.name,e),MxFun.updateDisplay()}setVisible(e){this.visible=e}getDatabase(){return this._database||(this._database=MxFun.getCurrentDatabase()),this._database}getLayer(){return this.getDatabase().getLayer(this.name)||this.getDatabase().addLayer(this.name),this.getDatabase().getLayer(this.name)}getCurrentName(){return this.getDatabase()._mxDatabase.curLayer.toString()}async callLayerContextFun(e){const l=this.getCurrentName();this.getDatabase().setCurrentLayer(this.name);const n=await e();return this.getDatabase().setCurrentLayer(l),n}getNames(){return Array.from(this.getLayerMap().keys())}getAllEntity(){return Array.from(this.getEntityMap().values()).filter(({userObject:e})=>e.layer===this.name).map(({userObject:e})=>e)}add(...e){var l;const n=this.getLayer();return n.group.renderOrder!==this.renderOrder&&(n.group.renderOrder=this.renderOrder,this.children=this.getAllEntity()),this.parent||(this.parent=MxFun.getCurrentDraw(),(l=this.parent)===null||l===void 0||l.add(this)),super.add(...e),this.callLayerContextFun(()=>{e.forEach(u=>{u&&this.getDatabase().addEntity(u)})}),this}remove(...e){super.remove(...e);let l=this.getRootLayerName();return this.callLayerContextFun(()=>{e.forEach(n=>{n&&(n.setLayer(l),n.setNeedUpdateDisplay())})}),this}}class MxDbDatabase{constructor(e){this._mxDatabase=e}addLayer(e){return this._mxDatabase.addLayer(e)}showLayer(e,l){this._mxDatabase.showLayer(e,l)}setCurrentLayer(e){return this._mxDatabase.setCurrentLayer(e)}getLayer(e){return this._mxDatabase.getLayer(e)}addEntity(e){return this._mxDatabase.addMxEntity(e)}getGroup(e){return this._mxDatabase.getGroupDictionary().getAt(e)}addGroup(e){return this._mxDatabase.getGroupDictionary().add(e)}getEntityInGroup(e){return this._mxDatabase.getGroupDictionary().getEntityInGroup(e)}deleteGroup(e){return this._mxDatabase.getGroupDictionary().delete(e)}}class MxTempMarkDraw{constructor(e){this.imp=e}clear(){this.imp.clear()}drawLine(e,l,n=16777215,u=1){this.imp.drawLine(e,l,n,u)}drawCircle(e,l,n){this.imp.drawCircle(e,l,n)}drawEntity(e){this.imp.drawEntity(e)}drawCircleMark(e,l,n){this.imp.drawCircleMark(e,l,n)}}function setGeometrPostion(t,e){for(let l=0;l<t.vertices.length;l++)t.vertices[l].x+=e.x,t.vertices[l].y+=e.y,t.vertices[l].z+=e.z}function repairGeometryFaceVertexUvs(t){t.computeBoundingBox();const e=t.boundingBox.min,l=t.boundingBox.max,n=new THREE.Vector2(0-e.x,0-e.y),u=new THREE.Vector2(l.x-e.x,l.y-e.y);t.faceVertexUvs[0]=[];const c=t.faces;for(let y=0;y<c.length;y++){const b=c[y],m=t.vertices[b.a],O=t.vertices[b.b],N=t.vertices[b.c];t.faceVertexUvs[0].push([new THREE.Vector2((m.x+n.x)/u.x,(m.y+n.y)/u.y),new THREE.Vector2((O.x+n.x)/u.x,(O.y+n.y)/u.y),new THREE.Vector2((N.x+n.x)/u.x,(N.y+n.y)/u.y)])}return t.uvsNeedUpdate=!0,t}function insertPointsWithEqualSpacing(t){const e=[];if(t.length<2)return t;let l=Number.MAX_VALUE;for(let n=0;n<t.length-1;n++){const u=t[n].distanceTo(t[n+1]);u<l&&(l=u)}for(let n=0;n<t.length-1;n++){const u=t[n],c=t[n+1];e.push(u);const y=u.distanceTo(c);if(y>l){const b=Math.floor(y/l),m=c.clone().sub(u).normalize();for(let O=1;O<b;O++){const N=u.clone().add(m.clone().multiplyScalar(O*l));e.push(N)}}}return e.push(t[t.length-1]),e}function getToGenerateRoundedCorners(t,e,l=!0){const n=new THREE.CurvePath;if(t.length<2)throw new Error("Points should have at least 2 items");if(!e||e.length===0)return t;!l&&t[0].equals(t[t.length-1])&&t.pop(),l||t.push(t[0]);for(let c=0;c<t.length-1;c++){const y=e[c]||0;if(c===0&&!l){const q=t[0].clone().sub(t[1]);q.normalize();const J=t[1].clone();J.add(q.clone().multiplyScalar(y));const fe=new THREE.LineCurve3(t[0],J);n.curves.push(fe);continue}const b=!l||t[c-1]?t[c-1].clone().sub(t[c]):t[t.length-1].clone().sub(t[0]);b.normalize();const m=!l||t[c+1]?t[c+1].clone().sub(t[c]):t[1].clone().sub(t[0]);m.normalize();const O=t[c].clone().add(b.clone().multiplyScalar(y)),N=t[c].clone(),L=t[c].clone().add(m.clone().multiplyScalar(y)),G=new THREE.QuadraticBezierCurve3(O,N,L);if(c===t.length-2){const q=t[c].clone().add(m.clone().multiplyScalar(y)),J=t[c+1].clone();l?J.add(m.clone().multiplyScalar(-y)):J.add(m.clone());const fe=new THREE.LineCurve3(q,J);n.curves.push(G,fe)}else n.curves.push(G);c===0&&t.push(t[0])}let u=n.getPoints();return u=insertPointsWithEqualSpacing(u)}function computeRectPoints(t,e){return[t,t.clone().set(e.x,t.y,e.z),e,e.clone().set(t.x,e.y,t.z)]}function calculateArcOrigin(t,e,l){const n=t.x,u=e.x,c=l.x,y=t.y,b=e.y,m=l.y,O=n-u,N=y-b,L=n-c,G=y-m,q=(n*n-u*u+(y*y-b*b))/2,J=(n*n-c*c+(y*y-m*m))/2,fe=N*L-O*G,ve=-(G*q-N*J)/fe,ne=-(O*J-L*q)/fe;return new THREE.Vector3(ve,ne,0)}function calculateRadiusArc(t,e){const l=t.x,n=t.y,u=e.x,c=e.y;return Math.sqrt((l-u)*(l-u)+(n-c)*(n-c))}function calculateArcAngle(t,e,l){const n=t.x,u=e.x;let c,y,b;return c=(t.y-e.y)/l,(y=(n-u)/l)>=.99999&&(y=.99999),y<=-.99999&&(y=-.99999),b=(b=Math.acos(y))/Math.PI*180,c<-.05&&(b=360-b),{sin:c,cos:y,angle:b}}function judgementArcRenderDirection(t,e,l){return(t<e?e-t:e-t+360)>(t<l?l-t:l-t+360)}function createThreePointArc(t,e,l,n=!1,u=!1,c=new THREE.Color("#ff0000")){const y=calculateArcOrigin(t,e,l),b=y.x,m=y.y,O=calculateRadiusArc(t,y),N=calculateArcAngle(t,y,O),L=calculateArcAngle(e,y,O),G=calculateArcAngle(l,y,O);let q,J,fe=N.angle,ve=L.angle,ne=G.angle,Ue=judgementArcRenderDirection(fe,ve,ne);u&&(Ue=!0),n?(J=new THREE.ArcCurve(b,m,O,THREE.MathUtils.degToRad(fe),THREE.MathUtils.degToRad(ve),!Ue),q=Ue?ve>fe?THREE.MathUtils.radToDeg(J.aEndAngle-J.aStartAngle):360-Math.abs(THREE.MathUtils.radToDeg(J.aEndAngle-J.aStartAngle)):fe>ve?Math.abs(THREE.MathUtils.radToDeg(J.aEndAngle-J.aStartAngle)):360-THREE.MathUtils.radToDeg(J.aEndAngle-J.aStartAngle)):(J=new THREE.ArcCurve(b,m,O,THREE.MathUtils.degToRad(fe),THREE.MathUtils.degToRad(ne),Ue),q=Ue?ne>fe?360-THREE.MathUtils.radToDeg(J.aEndAngle-J.aStartAngle):Math.abs(THREE.MathUtils.radToDeg(J.aEndAngle-J.aStartAngle)):fe>ne?360+THREE.MathUtils.radToDeg(J.aEndAngle-J.aStartAngle):THREE.MathUtils.radToDeg(J.aEndAngle-J.aStartAngle));const De=q*Math.PI*O/180,Ve=new THREE.BufferGeometry().setFromPoints(J.getPoints(50)),rt=new THREE.LineBasicMaterial({color:c});return{arc:new THREE.Line(Ve,rt),radius:O,angle:q,arcLength:De}}function computeRegularPolygonVertices$1(t=new THREE.Vector3,e=new THREE.Vector3,l=3){const n=[];l=Math.max(3,l),n.push(e);const u=2*Math.PI/l;for(let c=1;c<l;c++){const y=Math.cos(u*c),b=Math.sin(u*c),m=t.clone(),O=e.clone(),N=O.x-m.x,L=O.y-m.y,G=new THREE.Vector3(N*y-L*b+m.x,N*b+L*y+m.y);n.push(G)}return n}function computeBounding(t){if(t.length==0){let e=new THREE.Vector3;return{centerPoint:e,minPoint:e,maxPoint:e}}{let e=new THREE.Vector3(t[0].x,t[0].y,t[0].z||0),l=new THREE.Vector3(t[0].x,t[0].y,t[0].z||0),n=t.length;for(let u=1;u<n;u++){let c=t[u];e.x>c.x&&(e.x=c.x),e.y>c.y&&(e.y=c.y),l.x<c.x&&(l.x=c.x),l.y<c.y&&(l.y=c.y)}return{centerPoint:new THREE.Vector3(e.x+.5*(l.x-e.x),e.y+.5*(l.y-e.y),0),minPoint:e,maxPoint:l}}}function MxThreeJSMixin(t){return t.createImage=function(e,l,n,u,c){if(!c)return new Promise((y,b)=>{t.createImage.call(this,e,l,n,u,m=>y(m))});new THREE.TextureLoader().load(u,function(y){let b=new THREE.PlaneGeometry(l,n),m=new THREE.MeshLambertMaterial({map:y,transparent:!0,side:THREE.DoubleSide});m.map&&(m.map.needsUpdate=!0),setGeometrPostion(b,e);let O=new THREE.Mesh(b,m);O.material.depthTest=!1,c&&c(O)},void 0,function(y){console.log(y),c&&c(null)})},t.loadSVG=function(e,l,n,u){return n?(store.state.MxFun.loadSVG(e,l,n,u),new Promise(c=>{c(null)})):new Promise(c=>{store.state.MxFun.loadSVG(e,l,y=>{c(y)},u)})},t.clacTextSize=(e,l)=>store.state.MxFun.getMxThreeJS().clacTextSize(e,l),t.clacTextSpriteSize=(e,l,n)=>store.state.MxFun.getMxThreeJS().clacTextSpriteSize(e,l,n),t.creatTextSprite=(e,l,n,u,c)=>e.length===0?null:(c instanceof Object?c.getHex&&(c=c.getHex()):typeof c=="string"&&(c=parseInt(c)),store.state.MxFun.getMxThreeJS().creatTextSprite(e,l,n,u,c)),t}class MxThreeJS$1{createLine(e,l,n){const u=new THREE.Geometry,c=new THREE.LineBasicMaterial({color:n});return u.vertices.push(e,l),new THREE.Line(u,c)}createCircle(e,l,n){const u=new THREE.CircleGeometry(l,64,3,2*Math.PI),c=new THREE.LineBasicMaterial({color:n});u.vertices.shift();const y=new THREE.LineLoop(u,c),{x:b,y:m,z:O}=e;return y.position.set(b,m,O),y}createPoint(e,l,n=3){const u=new THREE.Geometry;u.vertices.push(e);const c=new THREE.PointsMaterial({color:l,size:n});return new THREE.Points(u,c)}createTriangle(e,l,n=1){if(e.length<3)return null;const u=e.length,c=new THREE.Geometry;for(let b=0;b+2<u;b+=3){c.vertices.push(e[b]),c.vertices.push(e[b+1]),c.vertices.push(e[b+2]);const m=new THREE.Face3(b,b+1,b+2);c.faces.push(m)}c.computeFaceNormals(),c.computeVertexNormals();const y=new THREE.MeshBasicMaterial({color:l,transparent:!0,depthTest:!1,side:THREE.DoubleSide,opacity:n});return new THREE.Mesh(c,y)}createLines(e,l){const n=new THREE.Geometry;n.vertices=e;const u=new THREE.LineBasicMaterial({color:l});return new THREE.Line(n,u)}createDashedLines(e,l,n,u){const c=new THREE.Geometry;c.vertices=e;const y=new THREE.Line(c,new THREE.LineDashedMaterial({color:l,dashSize:n,gapSize:u}));return y.computeLineDistances(),y}}const MxThreeJS=MxThreeJSMixin(new MxThreeJS$1);class MxDrawObject extends Node$1{constructor(e){super(),this.rootLayer=new Layer(e.m_mxDatabase.curLayer),this.add(this.rootLayer),this._mxdrawObj=e}getMxObjectImplement(){return this._mxdrawObj}getScene(){return this._mxdrawObj.getScene()}setMultipleSelect(e){this._mxdrawObj.isMultipleSelect=e}getCamera(){return this._mxdrawObj.getCamera()}getRenderer(){return this._mxdrawObj.renderer}setMouseRightRotate(e=!0){return this._mxdrawObj.setMouseRightRotate(e)}getFullDisplayRange(){return this._mxdrawObj.getFullDisplayRange()}getCanvas(){return this._mxdrawObj.getCanvas()}updateDisplay(e=!1){return this._mxdrawObj.updateDisplay(e)}createCanvasImageData(e,l){return this._mxdrawObj.createCanvasImageData(e,l)}setViewColor(e){return this._mxdrawObj.setViewColor(e)}getViewColor(){return this._mxdrawObj.getViewColor()}setSize(e,l){return this._mxdrawObj.setSize(e,l)}getIntersectObjects(e){return this._mxdrawObj.getIntersectObjects(e)}addObject(e,l=!0){return this._mxdrawObj.addObject(e,l)}addViewObject(e){return this._mxdrawObj.addViewObject(e)}getViewWidth(){return this._mxdrawObj.getViewWidth()}getViewHeight(){return this._mxdrawObj.getViewHeight()}removeObject(e,l=!0){return this._mxdrawObj.removeObject(e,l)}zoomInitialStates(){return this._mxdrawObj.zoomInitialStates()}zoomScale(e){return this._mxdrawObj.zoomScale(e)}zoomW(e,l,n,u,c){return this._mxdrawObj.zoomW(e,l,n,u,c)}saveZoom(){return this._mxdrawObj.saveZoom()}recoverZoom(){return this._mxdrawObj.recoverZoom()}zoomCenter(e,l){return this._mxdrawObj.zoomCenter(e,l)}initZoomW(e,l){return this._mxdrawObj.initZoomW(e,l)}addEvent(e,l){return this._mxdrawObj.addEvent(e,l)}on(e,l){return super.on(e,l),this._mxdrawObj.addEvent(e,l)}off(e,l){return super.off(e,l),this.removeEventFuction(e,l)}removeEventFuction(e,l){return this._mxdrawObj.removeEventFuction(e,l)}setIniset(e){return this._mxdrawObj.setIniset(e)}getViewDocCoord(){return this._mxdrawObj.getViewDocCoord()}screenCoord2World(e,l,n){return this._mxdrawObj.screenCoord2World(e,l,n)}worldCoord2Screen(e,l,n){return this._mxdrawObj.worldCoord2Screen(e,l,n)}screenCoord2Doc(e,l){return this._mxdrawObj.screenCoord2Doc(e,l,0)}worldCoordLong2Doc(e){return this._mxdrawObj.worldCoordLong2Doc(e)}docCoordLong2World(e){return this._mxdrawObj.docCoordLong2World(e)}docCoord2World(e,l,n){return this._mxdrawObj.docCoord2World(e,l,n)}docCoord2World2(e){return this._mxdrawObj.docCoord2World(e.x,e.y,e.z)}worldCoord2Doc(e,l,n){return this._mxdrawObj.worldCoord2Doc(e,l,n)}worldCoord2Doc2(e){return this._mxdrawObj.worldCoord2Doc(e.x,e.y,e.z)}docCoord2Screen(e,l){return this._mxdrawObj.docCoord2Screen(e,l,0)}screenCoordLong2Doc(e){return this._mxdrawObj.screenCoordLong2Doc(e)}docCoordLong2Screen(e){return this._mxdrawObj.docCoordLong2Screen(e)}screenCoordLong2World(e){return this._mxdrawObj.screenCoordLong2World(e)}worldCoordLong2Screen(e){return this._mxdrawObj.worldCoordLong2Screen(e)}initRendererParam(e){return this._mxdrawObj.initRendererParam(e)}addMxEntity(e){return this.rootLayer.add(e),e.objectId()}getMxCurrentSelect(){let e=this._mxdrawObj.getMxAllSelect();return e.length==0&&(e=this._mxdrawObj.getPrvCommandSelect()),e}getMxCADCurrentSelect(){let e=this._mxdrawObj.getMxCADAllSelect();return e.length==0&&(e=this._mxdrawObj.getPrvCommandMxCADSelect()),e}getSelectPoints(){return this._mxdrawObj.getSelectPoints()}addMxCurrentSelect(e,l=!0,n=!0){return this._mxdrawObj.addMxCurrentSelect(e,l,n)}addMxCADCurrentSelect(e,l=!0,n=!0){return this._mxdrawObj.addMxCADCurrentSelect(e,l,n)}fireSelectChange(e){this._mxdrawObj.fireSelectChange(e)}clearMxCurrentSelect(){return this._mxdrawObj.clearMxCurrentSelect()}getMxEntity(e){return this._mxdrawObj.getMxEntityUserObject(e)}findMxEntityAtPoint(e,l,n){return this._mxdrawObj.findMxEntityAtPoint(e,l,n)}getAllMxEntity(){return this._mxdrawObj.getAllMxEntity()}setViewMovementMethod(e){return this._mxdrawObj.setMouseMiddlePan(e)}setMouseMiddlePan(e){return this._mxdrawObj.setMouseMiddlePan(e)}resetThreeJSControls(){return this._mxdrawObj.resetThreeJSControls()}enableZoom(e){return this._mxdrawObj.enableZoom(e)}enablePan(e){return this._mxdrawObj.enablePan(e)}eraseMxEntity(e){return this._mxdrawObj.eraseMxEntity(e)}removeViewObject(e){this._mxdrawObj.removeViewObject(e)}saveMxEntityToJson(e){return JSON.stringify(this._mxdrawObj.saveMxEntityToJson(e))}saveMxEntityToObject(e){return this._mxdrawObj.saveMxEntityToJson(e)}async loadMxEntityFromJson(e,l=null){if(l){let n=l.length;for(let u=0;u<n;u++)await MxThreeJS.loadSVG(l[u])}return this.getAllMxEntity().forEach(n=>{for(let u in n)Reflect.deleteProperty(n,u)}),typeof e=="string"?this._mxdrawObj.loadMxEntityFromJson(JSON.parse(e)):this._mxdrawObj.loadMxEntityFromJson(e)}eraseAllMxEntity(){return this._mxdrawObj.eraseAllMxEntity()}makeCurrent(){this._mxdrawObj.makeCurrent()}getViewCenterDocCoord(){return this._mxdrawObj.getViewCenterDocCoord()}updateCanvasSize(){this._mxdrawObj.updateCanvasSize()}newFile(e,l,n,u){return this._mxdrawObj.newFile(e,l,n,u)}stopAllLoading(){this._mxdrawObj.stopAllLoading()}getOrbitControls(){return this._mxdrawObj.getOrbitControls()}enableViewControls(e){return this._mxdrawObj.enableViewControls(e)}getMxDatabase(){return new MxDbDatabase(this._mxdrawObj.getMxDatabase())}getTempMarkDraw(){return new MxTempMarkDraw(this._mxdrawObj.getTempMarkDraw())}setZoomSpeed(e){return this._mxdrawObj.setZoomSpeed(e)}resetRenderer(){return this._mxdrawObj.resetRenderer()}setRequestHeader(e){return this._mxdrawObj.setRequestHeader(e)}closeWebSocket(){return this._mxdrawObj.closeWebSocket()}cadCoord2Doc(e,l,n){return this._mxdrawObj.cadCoord2Doc(e,l,n)}cadCoord2Doc2(e){return this._mxdrawObj.cadCoord2Doc2(e)}toSmallcoord(e){return this._mxdrawObj.toSmallcoord(e)}toSmallcoord2(e,l,n=0){return this._mxdrawObj.toSmallcoord2(e,l,n)}docCoord2Cad(e,l,n){return this._mxdrawObj.docCoord2Cad(e,l,n)}docCoord2Cad2(e){return this._mxdrawObj.docCoord2Cad2(e)}viewCoord2Cad(e,l,n){return this._mxdrawObj.viewCoord2Cad(e,l,n)}cadCoord2View(e,l,n){return this._mxdrawObj.cadCoord2View(e,l,n)}cadCoordLong2View(e){return this._mxdrawObj.cadCoordLong2View(e)}viewCoordLong2Cad(e){return this._mxdrawObj.viewCoordLong2Cad(e)}docCoordLong2Cad(e){return this._mxdrawObj.docCoordLong2Cad(e)}cadCoordLong2Doc(e){return this._mxdrawObj.cadCoordLong2Doc(e)}setViewAngle(e){return this._mxdrawObj.setViewAngle(e)}getViewAngle(){return this._mxdrawObj.getViewAngle()}getSysVar(e){return this._mxdrawObj.sysVariable().getSysVar()}setSysVar(e,l){return this._mxdrawObj.sysVariable().setSysVar(e,l)}isMxCAD(){return this._mxdrawObj.isCppMxCAD()}getAllLayoutName(){return this._mxdrawObj.getAllLayoutName()}getDtabaseJsonString(){return this._mxdrawObj.getDtabaseJsonString()}gotoLayout(e){return this._mxdrawObj.gotoLayout(e)}initMxCpp(e){return this._mxdrawObj.initMxCpp(e)}isWebgl2(){return this._mxdrawObj.isWebgl2()}getId(){return this._mxdrawObj.getId()}addControlsEvent(e,l,n=!1){return this._mxdrawObj.addControlsEvent(e,l,n)}clearAllObject(){return this.rootLayer.clear(),this._mxdrawObj.clearAllObject()}setPointMultipleSelect(e=!0){return this._mxdrawObj.setPointMultipleSelect(e)}isWhiteViewColor(){return this._mxdrawObj.isWhiteViewColor()}automaticInversionColor(e){return this._mxdrawObj.automaticInversionColor(e)}renderLoop(e=!0){return this._mxdrawObj.renderLoop(e)}}const initEvents=t=>{let e=[];["click","mousedown","mouseup"].forEach(l=>{t.addEventListener(l,()=>{e.forEach(n=>{n.emit(l)})})}),t.addEventListener("mousemove",()=>{const l=MxFun.getCurrentDraw().findMxEntityAtPoint(MxFun.getCurrentMousePostion(),!1);l.forEach(n=>{n.emit("mousemove")}),l.length===0&&(e.length>0&&e.forEach(n=>{n.emit("mouseout")}),e=[]),e.length===0&&(e=l).forEach(n=>{n.emit("mouseover"),n.emit("hover")})})};function createMxObject({canvasId:t=createReandomId(),cadFile:e="",callback:l,isNewFile:n=!1,useWebsocket:u=!1,isAutoResize:c=!0,mapBox:y,isMxCAD:b=!1,userIdentitySign:m="emptyUserIdentity",isCPPMxCAD:O=!1}){if(this.initUiDataObject(mxUiData$1),!u&&n&&(n=!1),y)if(O){const N=y.canvas;store.state.MxFun.createMxObject(N,"",G=>{let q=new MxDrawObject(G);G.setMouseRightRotate(!1),G.setIniset({EnableOsnapFunction:!0}),l&&l(q,{canvas:N,canvasParent:void 0})},!0,!1,!1,y,O)}else{const N=y.canvas;store.state.MxFun.createMxObject(N,e,L=>{let G=new MxDrawObject(L);L.setIniset({EnableOsnapFunction:!0}),l&&l(G,{canvas:N,canvasParent:void 0})},void 0,n,u,y)}else if(O){const N=createCanvas(t),L=createCanvasParent(N);L.parentNode&&L.parentNode.nodeType!=11||document.body.appendChild(L),store.state.MxFun.createMxObject(t,"",q=>{let J=new MxDrawObject(q);q.setMouseRightRotate(!1),q.setIniset({EnableOsnapFunction:!0}),q.addEvent("onResize",()=>(L.tabindex=3,{width:L.clientWidth,height:L.clientHeight})),c&&useCanvasResizeListener(J,N),l&&l(J,{canvas:N,canvasParent:L})},!0,!1,!1,void 0,O)}else{const N=createCanvas(t),L=createCanvasParent(N);let G;L.parentNode&&L.parentNode.nodeType!=11||document.body.appendChild(L),b&&(G=!0,u=!0),store.state.MxFun.createMxObject(t,e,q=>{let J=new MxDrawObject(q);b&&(m.length==0&&(m="invalidUserIdentity"),q.initRunMode(2),q.initUserLoginData(m,"")),q.setMouseRightRotate(!1),q.setIniset({EnableOsnapFunction:!0}),q.addEvent("onResize",()=>(L.tabindex=3,{width:L.clientWidth,height:L.clientHeight})),c&&useCanvasResizeListener(J,N),initEvents(N),l&&l(J,{canvas:N,canvasParent:L})},G,n,u,void 0)}}let mxUiData=mxUiData$1,mxFunSyncInitialization;class MxFunClass{constructor(){this.createMxObject=createMxObject,this.getMxFunTHREE=()=>store.state.MxFun.getTHREE()}setMxServer(e="ws://localhost:5090"){store.state.MxFun.setMxServer(e)}onInitSync(e){mxFunSyncInitialization=e}callSyncInitialization(){return mxFunSyncInitialization!=null?mxFunSyncInitialization():new Promise(e=>{e(!0)})}screenCoord2Doc(e,l){return store.state.MxFun.screenCoord2Doc(e,l,0)}docCoord2Screen(e,l){return store.state.MxFun.docCoord2Screen(e,l,0)}getCurrentDraw(){const e=store.state.MxFun.getCurrentDraw();return e.tmp||(e.tmp=new MxDrawObject(e)),e.tmp}addToCurrentSpace(e){return MxFun.getCurrentDraw().addMxEntity(e)}initUiDataObject(e){return mxUiData=e,store.state.MxFun.initUiDataObject(e)}getUIData(){return mxUiData}getCurrentDatabase(){return MxFun.getCurrentDraw().getMxDatabase()}testMX(e){return 11}loadImageMaterial(e,l){return l?(store.state.MxFun.loadImageMaterial(e,l),new Promise((n,u)=>{n(null)})):new Promise((n,u)=>{store.state.MxFun.loadImageMaterial(e,c=>{n(c||null)})})}selectEnt(e,l=null){return new Promise((n,u)=>{const c=new MrxDbgUiPrPoint;c.setMessage(e),c.go(y=>{if(y!=0)return void n(0);const b=c.value();let m=MxFun.getCurrentDraw().findMxEntityAtPoint(b),O=0;for(;m.length!=0;){let N=m.length;for(let L=0;L<N;L++){let G=m[L];if(!l||!l.type||l.type==G.getTypeName()){O=G.objectId();break}}break}n(O)})})}listenForCommandLineInput(e){mxUiData.getCmdLine().mountUpDisplayFun(e)}setCommandLineInputData(e,l){mxUiData.getCmdLine().setCmdText(e),mxUiData.onKeydown(l)}listenForCoordTip(e){mxUiData.mountSetCoordFun(e)}listenForUpdateCursor(e){mxUiData.mountUpdateCursorFun(e)}getMxFunThreeTool(){return store.state.MxFun.getMxThreeJS()}ceneratecursor(e=128,l=10,n=!0,u){return store.state.MxFun.ceneratecursor(e,l,n,u)}getCurrentMousePostion(){let e=store.state.MxFun.getCurrentMousePostion();return new THREE.Vector3(e.x,e.y,0)}onUseCreateMxDbEntity(e){store.events.on("use:create:MxDbEntity",e)}}const _MxFun=new MxFunClass,MxFun=new Proxy({},{get:(t,e)=>typeof _MxFun[e]=="function"?_MxFun[e].bind(_MxFun):store.state.MxFun[e]});var MxCloneType,MxCommandFlag,MxDefaultRenderOrder,InputToucheType;(function(t){t[t.kClone=1]="kClone",t[t.kDragClone=2]="kDragClone",t[t.kMxFileClone=3]="kMxFileClone",t[t.kSaveDwgClone=4]="kSaveDwgClone"})(MxCloneType||(MxCloneType={})),function(t){t[t.MCRX_CMD_MODAL=0]="MCRX_CMD_MODAL",t[t.MCRX_CMD_TRANSPARENT=1]="MCRX_CMD_TRANSPARENT",t[t.MCRX_CMD_NO_UNDO_MARKER=2]="MCRX_CMD_NO_UNDO_MARKER",t[t.MCRX_CMD_NOPRV=4]="MCRX_CMD_NOPRV"}(MxCommandFlag||(MxCommandFlag={})),function(t){t[t.kCADMeshRenderOrder=10]="kCADMeshRenderOrder",t[t.kCADCurveRenderOrder=20]="kCADCurveRenderOrder",t[t.kMxEntityRenderOrder=30]="kMxEntityRenderOrder",t[t.kGripRenderOrder=110]="kGripRenderOrder",t[t.kDynJigRenderOrder=120]="kDynJigRenderOrder"}(MxDefaultRenderOrder||(MxDefaultRenderOrder={})),function(t){t[t.kGetBegan=1]="kGetBegan",t[t.kGetEnd=2]="kGetEnd"}(InputToucheType||(InputToucheType={}));var MxType=Object.freeze({__proto__:null,get MxCloneType(){return MxCloneType},get MxCommandFlag(){return MxCommandFlag},get MxDefaultRenderOrder(){return MxDefaultRenderOrder},get InputToucheType(){return InputToucheType}});class MxassemblyClass{constructor(){this.mxassembly=null}initImp(){this.mxassembly||store.state.Mxassembly&&(this.mxassembly=store.state.Mxassembly)}NewMcGePoint3d(e,l,n){this.initImp();let u=new this.mxassembly.McGePoint3d;return e&&(u.x=e),l&&(u.y=l),n&&(u.z=n),u}NewMcGePoint3dArray(e){this.initImp();let l=new this.mxassembly.McGePoint3dArray;return e&&e.forEach(n=>{let u=this.NewMcGePoint3d();u.x=n.x,u.y=n.y,u.z=n.z,l.append(u)}),l}}const Mxassembly=new MxassemblyClass;class McGeToolClass{constructor(){this.mxgeTool=null}initImp(){this.mxgeTool||store.state.Mxassembly&&(this.mxgeTool=new store.state.Mxassembly.McGeTool)}calcArea(e){if(this.initImp(),!store.state.Mxassembly)return 0;if(e instanceof Array){let l=Mxassembly.NewMcGePoint3dArray(e);return this.mxgeTool.calcArea(l)}return this.mxgeTool.calcArea(e)}pointInPolyline(e,l){this.initImp();let n=l;l instanceof Array&&(n=Mxassembly.NewMcGePoint3dArray(l));let u=Mxassembly.NewMcGePoint3d(e.x,e.y,e.z);return this.mxgeTool.pointInPolyline(u,n)}}const McGeTool=new McGeToolClass;class MrxDbgUtilsClass{constructor(){this.imp=null}initImp(){if(!this.imp&&store.state.MxFun){let e=store.state.MxFun;this.imp=new e.getMrxDbgUtilsClass}}findEntAtPoint(e,l=null,n,u=!0,c){return this.initImp(),n||(n=MxFun.getCurrentDraw()),this.imp.findEntAtPoint(n.getMxObjectImplement(),e,l,u,c)}selectEnt(e,l){return this.initImp(),this.imp.selectEnt(e)}getCorner(e,l,n=!1,u,c=!1){return this.initImp(),this.imp.getCorner(e,l,n,u,c)}}const MrxDbgUtils=new MrxDbgUtilsClass,MxPaintBrushProps={},MxPaintBrush={getProps:()=>MxPaintBrushProps,setProps:t=>Object.assign(MxPaintBrushProps,t),use:t=>Object.assign(t,MxPaintBrushProps)};var DataType;(function(t){t[t.Default=0]="Default",t[t.Color=1]="Color",t[t.Vector2=2]="Vector2",t[t.Vector3=3]="Vector3",t[t.Vector4=4]="Vector4",t[t.Matrix3=5]="Matrix3",t[t.Matrix4=6]="Matrix4"})(DataType||(DataType={}));const MXDBDATATYPE="datatype";function getDwgKeyVal(t,e){let l,n="";return lodash.isObject(e)?(l=e.default,n=e.key):typeof e=="string"&&(n=e),[n,t[n]===void 0?l:t[n]]}class MxDbEntity extends RenderOrderNode{constructor(){super(),this.color=16777215,this.opacity=1,this.visible=!0,this.userData={},this.sGuid="",this.dLineWidth=0,this.lineWidthByPixels=!0,this.dDashArray=0,this.dDashRatio=0,this.layer="",this.use_smallcoord_display=!1,this.addEvent=this.on,this.removeEvent=this.off,this.callEvent=this.emit;const e=this.constructor;e.isPaintBrushDraw&&(MxPaintBrush.use(this),store.events.emit("use:create:MxDbEntity",this),e.isPaintBrushDraw=!1)}static register(){const e=this;e.isRegister||(e.cmd&&e.draw&&MxFun.addCommand(e.cmd,l=>e.use.call(e,void 0,l)),new e().rxInit(),e.isRegister=!0)}static async use(e,l){return new Promise((n,u)=>{const c=this;if(!c.isRegister&&c.register(),c.isPaintBrushDraw=!0,!c.cmd&&c.draw)return u();const y=b=>{n(b),e&&e(b),store.events.off("use:create:MxDbEntity",y)};store.events.on("use:create:MxDbEntity",y),c.draw(l)})}initGuid(e){this.sGuid.length>0?console.log("mx: init guid error"):this.sGuid=e}toSmallcoord2(e,l,n,u=0){return this.use_smallcoord_display?e.toSmallcoord2(l,n,u):new THREE.Vector3(l,n,u)}toSmallcoord(e,l){return this.use_smallcoord_display?e.toSmallcoord(l):l}isUseSmallcoordDisplay(){return this.use_smallcoord_display}setUseSmallcoordDisplay(e){this.use_smallcoord_display=e}dwgInHelp(e,l,n){let u=this;const c=e.type===MxType.MxCloneType.kMxFileClone||e.type===MxType.MxCloneType.kSaveDwgClone,y=m=>{if(!m)return;const{value:O,[MXDBDATATYPE]:N}=m;switch(N){case DataType.Color:return new THREE.Color(...O);case DataType.Vector2:return new THREE.Vector2(...O);case DataType.Vector3:return new THREE.Vector3(...O);case DataType.Vector4:return new THREE.Vector4(...O);case DataType.Matrix3:return new THREE.Matrix3().fromArray(O);case DataType.Matrix4:return new THREE.Matrix4().fromArray(O)}return n&&n.getCacheVal?n.getCacheVal(m):void 0};function b(m){return m instanceof THREE.Color||m instanceof THREE.Vector2||m instanceof THREE.Vector3||m instanceof THREE.Vector4||m instanceof THREE.Matrix3||m instanceof THREE.Matrix4?m.clone():n&&n.getVal?n.getVal(m):void 0}return l.forEach(m=>{const[O,N]=getDwgKeyVal(e,m);u[O]=lodash.cloneDeepWith(N,c?y:b)}),!0}dwgOutHelp(e,l){const n=y=>y instanceof THREE.Color?{[MXDBDATATYPE]:DataType.Color,value:y.toArray()}:y instanceof THREE.Vector2?{[MXDBDATATYPE]:DataType.Vector2,value:y.toArray()}:y instanceof THREE.Vector3?{[MXDBDATATYPE]:DataType.Vector3,value:y.toArray()}:y instanceof THREE.Vector4?{[MXDBDATATYPE]:DataType.Vector4,value:y.toArray()}:y instanceof THREE.Matrix3?{[MXDBDATATYPE]:DataType.Matrix3,value:y.toArray()}:y instanceof THREE.Matrix4?{[MXDBDATATYPE]:DataType.Matrix4,value:y.toArray()}:void 0;let u=this;const c=e.type===MxType.MxCloneType.kMxFileClone||e.type===MxType.MxCloneType.kSaveDwgClone;return l.forEach(y=>{const[b,m]=getDwgKeyVal(u,y);e[b]=c?lodash.cloneDeepWith(m,n):m}),e}create(e){return new this.constructor(e)}transformBy(e){}getGeomExtents(){return null}getClosestPointTo(e,l=0){return null}getImp(){return this.MxDbEntityImp}setNeedUpdateDisplay(e){let l=this.getImp();return!!l&&(e?l.upDisplay():l.setDirtyDisplay(!0),!0)}getMxObject(){let e=this.getImp();return e?e.getMxObject():null}onViewChange(){return!1}objectId(){let e=this.getImp();return e?e.objectId():0}erase(){let e=this.getImp();return!!e&&e.erase()}setLayer(e){let l=this.getImp();l&&l.nodifySetLayer(),this.layer=e}getLayer(){return this.layer}setColor(e){return this.color=e,this}getColor(){return this.color||16777215}clone(e){let l=this.create(),n={type:e||MxType.MxCloneType.kClone};return this.dwgOut(n),l.dwgIn(n),l.sGuid="",l}onDwgIn(e){this.color=e.color,this.renderOrder=e.renderOrder,this.opacity=e.opacity,this.visible=e.visible,e.userData?this.userData=JSON.parse(JSON.stringify(e.userData)):this.userData={},this.dLineWidth=e.lineWidth,this.lineWidthByPixels=e.lineWidthByPixels,this.dDashArray=e.dashArray,this.dDashRatio=e.dashRatio,this.layer=e.layer,e.guid&&(this.sGuid=e.guid)}onDwgOut(e){e.color=this.color,e.renderOrder=this.renderOrder,e.opacity=this.opacity,e.visible=this.visible,e.lineWidth=this.dLineWidth,e.lineWidthByPixels=this.lineWidthByPixels,e.dashArray=this.dDashArray,e.dashRatio=this.dDashRatio,e.layer=this.layer,e.guid=this.sGuid,Object.keys(this.userData).length>0&&(e.userData=this.userData)}rxInit(){MxFun.initMxDbEntityType(this)}setRenderOrder(e){this.renderOrder=e}getRenderOrder(){return this.renderOrder}setLineWidthByPixels(e){return this.lineWidthByPixels=e,this}getLineWidthByPixels(){return this.lineWidthByPixels}setLineWidth(e){return this.dLineWidth=e,this}getLineWidth(){return this.dLineWidth}getGetLength(){return 0}setDashLen(e){let l=this.getGetLength();if(l<1e-6||e<1e-6)return this;let n=Math.floor(l/e);return n<1e-6&&(this.dDashRatio=0),this.dDashArray=1/n,this}setDashRatio(e){return this.dDashRatio=e,this}setDashArray(e){return this.dDashArray=e,this}setDash(e,l){return this.dDashArray=e,this.dDashRatio=l,this.dLineWidth==0&&(this.dLineWidth=6,this.lineWidthByPixels=!0),this}getDash(){return{dDashArray:this.dDashArray,dDashRatio:this.dDashRatio}}setDashLineDisplay(e){return e?(this.dDashArray<1e-5&&(this.dDashArray=.03),this.dDashRatio<1e-5&&(this.dDashRatio=.1),this.dLineWidth==0&&(this.dLineWidth=6,this.lineWidthByPixels=!0)):(this.dDashArray=0,this.dDashRatio=0),this}isDashLineDisplay(){return this.dDashArray>0&&this.dDashRatio>0}guid(){return this.sGuid}setGuid(e){return this.sGuid=e}onEndGripEidt(){this.callEvent("onEndGripEidt")}onStartGripEidt(){return this.callEvent("onStartGripEidt")}toJsonString(e=MxType.MxCloneType.kMxFileClone){let l={type:e};return this.dwgOut(l),l.TypeName=this.getTypeName(),JSON.stringify(l)}fromJsonString(e){let l=JSON.parse(e);return(l.type==MxType.MxCloneType.kMxFileClone||l.type==MxType.MxCloneType.kClone)&&this.dwgIn(l)}}function drawMxDbImage(){const t=new MrxDbgUiPrPoint;t.setMessage(`
- 指定插入点:`);let e=MxFun.getCurrentDraw();t.go(l=>{if(l!=0)return;let n=MxFun.screenCoordLong2Doc(300),u=MxFun.screenCoordLong2Doc(200);const c=t.value();let y=MxFun.screenCoord2Doc(10,10);c.z=y.z;let b=new MxDbImage;b.setRenderOrder(MxType.MxDefaultRenderOrder.kCADMeshRenderOrder-1),b.setPoint1(c);let m=new THREE.Vector3(c.x+n,c.y+u,c.z);b.setPoint2(m);let O=prompt("请填写图片网络地址","https://cdn.pixabay.com/photo/2022/11/15/12/23/winter-7593872_960_720.jpg");O&&(b.setImagePath(O),e.addMxEntity(b),b.addEvent("onStartGripEidt",()=>(b.visible=!1,b.setNeedUpdateDisplay(),{renderOrder:MxType.MxDefaultRenderOrder.kCADMeshRenderOrder-1})),b.addEvent("onEndGripEidt",()=>{b.visible=!0,b.setNeedUpdateDisplay()}))})}MxDbEntity.isRegister=!1;class MxDbImage extends MxDbEntity{constructor(){super(...arguments),this.pt1=new THREE.Vector3,this.pt2=new THREE.Vector3,this.imagePath="",this.isLoadMaterialFromPath=!0,this.material=null,this.angle=0}getTypeName(){return"MxDbImage"}getAngle(){return this.angle}setAngle(e){this.angle=e}worldDraw(e){let l=new THREE.Vector3(this.pt1.x,this.pt2.y),n=new THREE.Vector3(this.pt2.x,this.pt1.y);if(Math.abs(this.angle)>1e-5){let u=new THREE.Vector3(.5*(this.pt1.x-this.pt2.x)+this.pt2.x,.5*(this.pt1.y-this.pt2.y)+this.pt2.y),c=new THREE.Matrix4;c.makeRotationZ(this.angle);let y=new THREE.Matrix4().makeTranslation(u.x,u.y,u.z).multiply(c).multiply(new THREE.Matrix4().makeTranslation(-u.x,-u.y,-u.z));e.setMatrix(y)}if(e.getType()==1){if(e.drawSelectLine(this.pt1,l),e.drawSelectLine(l,this.pt2),e.drawSelectLine(this.pt2,n),e.drawSelectLine(n,this.pt1),this.material){let u=Math.abs(this.pt1.x-this.pt2.x),c=Math.abs(this.pt1.y-this.pt2.y),y=new THREE.PlaneGeometry(u,c),b=Math.min(this.pt1.x,this.pt2.x),m=Math.min(this.pt1.y,this.pt2.y);for(let N=0;N<y.vertices.length;N++)y.vertices[N].x+=b+.5*u,y.vertices[N].y+=m+.5*c,y.vertices[N].z=0;let O=new THREE.Mesh(y,this.material);O.material.depthTest=!1,e.drawEntity(O)}else if(this.imagePath.length>0&&this.isLoadMaterialFromPath){let u=this,c=e.getMxObject();const y=b=>{this.isLoadMaterialFromPath=!1,b&&(u.setMaterial(b),u.setNeedUpdateDisplay(),c.updateDisplay())};MxFun.loadImageMaterial(this.imagePath,b=>{y(b)})}}else if(this.material){let u=Math.abs(this.pt1.x-this.pt2.x),c=Math.abs(this.pt1.y-this.pt2.y),y=new THREE.PlaneGeometry(u,c),b=Math.min(this.pt1.x,this.pt2.x),m=Math.min(this.pt1.y,this.pt2.y);for(let N=0;N<y.vertices.length;N++)y.vertices[N].x+=b+.5*u,y.vertices[N].y+=m+.5*c,y.vertices[N].z=0;let O=new THREE.Mesh(y,this.material);O.material.depthTest=!1,e.drawEntity(O)}else e.drawLine(this.pt1,l),e.drawLine(l,this.pt2),e.drawLine(this.pt2,n),e.drawLine(n,this.pt1);e.setMatrix(null)}setImagePath(e){this.imagePath=e,this.isLoadMaterialFromPath=!0,this.material=null}getImagePath(){return this.imagePath}setMaterial(e){this.material=e}loadMaterial(e){e&&(this.imagePath=e),this.isLoadMaterialFromPath=!1,this.material=null;let l=this;MxFun.loadImageMaterial(this.imagePath,n=>{this.isLoadMaterialFromPath=!1,l.setMaterial(n)})}setPoint1(e){this.pt1=e}getPoint1(){return this.pt1}setPoint2(e){this.pt2=e}getPoint2(){return this.pt2}getGripPoints(){let e=[];e.push(this.pt1),e.push(this.pt2);let l=new THREE.Vector3(this.pt1.x+.5*(this.pt2.x-this.pt1.x),this.pt1.y+.5*(this.pt2.y-this.pt1.y));return e.push(l),e}moveGripPointsAt(e,l){return e==0?this.pt1.add(l):e==1?this.pt2.add(l):e==2&&(this.pt1.add(l),this.pt2.add(l)),!0}dwgIn(e){return this.onDwgIn(e),this.pt1.copy(e.pt1),this.pt2.copy(e.pt2),this.imagePath=e.imagePath.substr(0),this.isLoadMaterialFromPath=!0,e.angle&&(this.angle=e.angle),e.material&&(this.material=e.material),!0}dwgOut(e){return this.onDwgOut(e),e.pt1=this.pt1,e.pt2=this.pt2,e.imagePath=this.imagePath,e.angle=this.angle,e.type==MxType.MxCloneType.kDragClone&&(e.material=this.material),e}create(){return new MxDbImage}}var McGiWorldDrawType;MxDbImage.cmd="Mx_DrawImage",MxDbImage.draw=drawMxDbImage,addRegisterMxDbEntity(MxDbImage),function(t){t[t.kWorldDraw=1]="kWorldDraw",t[t.kDynDragDraw=2]="kDynDragDraw",t[t.kSelectDraw=3]="kSelectDraw"}(McGiWorldDrawType||(McGiWorldDrawType={}));var McGiWorldDrawType$1=McGiWorldDrawType;class MxDbSVGText{constructor(){this.txtPos=new THREE.Vector3,this.txt="",this.txtHeight=1,this.color=void 0,this._txtObject=null,this._txtAspectRatio=-1,this.move=!1,this.drawConnectingLine=!1,this._connectingLine=null,this.fontStyle="",this.underline=!1,this._underLine=null}}async function drawMxDbSVG(){const t=new MrxDbgUiPrPoint;t.setMessage(`
- 指定一点:`);let e=await t.go();if(!e)return;let l=new MxDbSVG,n=prompt("请输入svg图片网络或本地地址","https://img.alicdn.com/imgextra/i2/O1CN01FF1t1g1Q3PDWpSm4b_!!6000000001920-55-tps-508-135.svg");if(!n)return;l.setSvgPath(n),l.setSvgPostion(e),l.svgReverse=!0,l.svgMargin.x=.2,l.setSvgAlignmentRatio(new THREE.Vector2(.5,-1)),l.setRenderOrder(100),l.setSvgSize(new THREE.Vector2(50,0));let u=new MxDbSVGText;u.txt="A1",u.txtPos=new THREE.Vector3(0,-30,0),u.txtHeight=30,l.addText(u),l.fixedSize=!0,l.color=65297,MxFun.addToCurrentSpace(l)}class MxDbSVG extends MxDbEntity{constructor(){super(...arguments),this.svgPos=new THREE.Vector3,this.svg=null,this.svgPath="",this.svgSize=new THREE.Vector2(50,50),this.svgAlignmentRatio=new THREE.Vector2(0,0),this.imagePath="",this.isLoadMaterialFromPath=!0,this.material=null,this.svgRotate=0,this.svgReverse=!1,this.svgMirror=!1,this.svgChildColor=[],this.svgMargin=new THREE.Vector2(0,0),this.isSvgDirtyLocation=!1,this.isLoadFromPath=!0,this.aryText=[],this.svgBoxSize=null,this.fixedSize=!1,this.useSvgColor=!1}setSvgChildColor(e){if(this.svgChildColor=e,!this.useSvgColor&&this.svg){let l=new THREE.Color(this.getColor()),n=0,u=this;this.svg.traverse(function(c){c.material&&(n<u.svgChildColor.length?c.material.color=new THREE.Color(u.svgChildColor[n]):c.material.color=l,n++)}),this.setNeedUpdateDisplay(!0)}}getSvgChildColor(){return this.svgChildColor}calcVewSize(e){let l=this.svgSize.x,n=this.svgSize.y;return n<=0&&(n=this.svgBoxSize?this.svgBoxSize.y/this.svgBoxSize.x*l:l),this.fixedSize&&(l=e.screenCoordLong2Doc(l),n=e.screenCoordLong2Doc(n)),[l,n]}calcSvgDrawRect(e){if(!e)return;this.calcSvgPosition(e);let[l,n]=this.calcVewSize(e),u=new THREE.Matrix4;u.makeScale(this.svgMirror?-1:1,this.svgReverse?-1:1,1);let c=new THREE.Matrix4;c.makeRotationZ(this.svgRotate);let y=new THREE.Matrix4,b=new THREE.Vector3(this.svgPos.x-l*this.svgAlignmentRatio.x,this.svgPos.y-n*this.svgAlignmentRatio.y,0);y.makeTranslation(b.x,b.y,b.z),c.multiply(u),c.premultiply(y);let m=new THREE.Vector3(0,0,0),O=new THREE.Vector3(l,0,0),N=new THREE.Vector3(l,n,0),L=new THREE.Vector3(0,n,0);return m.applyMatrix4(c),O.applyMatrix4(c),N.applyMatrix4(c),L.applyMatrix4(c),{pt1:m,pt2:N,pt3:O,pt4:L,cenpt:N.clone().add(m.clone().sub(N).multiplyScalar(.5)),sizew:l,sizeh:n}}calcImageDrawRect(e){if(!e)return;this.calcSvgPosition(e);let[l,n]=this.calcVewSize(e),u=new THREE.Matrix4;u.makeScale(this.svgMirror?-1:1,this.svgReverse?-1:1,1);let c=new THREE.Matrix4,y=new THREE.Matrix4,b=new THREE.Vector3(this.svgPos.x-l*this.svgAlignmentRatio.x,this.svgPos.y-n*this.svgAlignmentRatio.y,0);y.makeTranslation(b.x,b.y,b.z),c.multiply(u),c.premultiply(y);let m=new THREE.Vector3(0,0,0),O=new THREE.Vector3(l,0,0),N=new THREE.Vector3(l,n,0),L=new THREE.Vector3(0,n,0);return m.applyMatrix4(c),O.applyMatrix4(c),N.applyMatrix4(c),L.applyMatrix4(c),{pt1:m,pt2:N,pt3:O,pt4:L,cenpt:N.clone().add(m.clone().sub(N).multiplyScalar(.5)),sizew:l,sizeh:n}}worldDraw(e){let l,n=e.getMxObject();if(this.imagePath.length>0){if(l=this.calcImageDrawRect(n),Math.abs(this.svgRotate)>1e-5){let L=new THREE.Vector3(.5*(l.pt1.x-l.pt2.x)+l.pt2.x,.5*(l.pt1.y-l.pt2.y)+l.pt2.y),G=new THREE.Matrix4;G.makeRotationZ(this.svgRotate);let q=new THREE.Matrix4().makeTranslation(L.x,L.y,L.z).multiply(G).multiply(new THREE.Matrix4().makeTranslation(-L.x,-L.y,-L.z));e.setMatrix(q)}}else l=this.calcSvgDrawRect(n);let u=l.pt1,c=l.pt2,y=l.pt3,b=l.pt4,m=l.cenpt,O=l.sizew,N=this;if(e.getType()!=McGiWorldDrawType$1.kSelectDraw&&this.aryText.forEach((L,G)=>{if(L.txt.length>0){let fe,ve=new THREE.Vector3(L.txtPos.x,L.txtPos.y,0);this.fixedSize&&(L.txtPos.x>0?ve.x=this.svgPos.x+n.screenCoordLong2Doc(L.txtPos.x):ve.x=this.svgPos.x-n.screenCoordLong2Doc(L.txtPos.x),L.txtPos.y>0?ve.y=this.svgPos.y+n.screenCoordLong2Doc(L.txtPos.y):ve.y=this.svgPos.y-n.screenCoordLong2Doc(L.txtPos.y)),L.color&&(fe=e.getColor(),e.setColor(L.color));let ne=L.txtHeight;N.fixedSize&&(ne=n.screenCoordLong2Doc(L.txtHeight)),e.setXData({type:"text",txt:L.txt,index:G});let Ue=e.drawText(L.txt,ne,0,ve,void 0,De=>L.fontStyle.length>0?`${L.fontStyle} ${De}px Arial`:`normal ${De}px Arial`);if(e.getType()==McGiWorldDrawType$1.kWorldDraw&&(L._txtObject=Ue),L.underline&&L._txtObject){const De=new THREE.Box3;De.expandByObject(L._txtObject);let Ve=new THREE.Vector3(De.min.x,De.min.y+.1*ne,0),rt=new THREE.Vector3(De.max.x,De.min.y+.1*ne,0);var q=new THREE.Geometry;let Ae=new THREE.LineBasicMaterial({color:e.getColor(),transparent:!0,depthTest:!1});q.vertices.push(Ve,rt);var J=new THREE.Line(q,Ae);e.drawEntity(J),e.getType()==McGiWorldDrawType$1.kWorldDraw&&(L._underLine=J)}if(L._txtAspectRatio=-1,fe&&e.setColor(fe),L.drawConnectingLine){let De=m.clone().sub(ve);if(De.length()>ne+O){De.normalize();let Ve=m.clone().sub(De.clone().multiplyScalar(O)),rt=ve.clone().add(De.clone().multiplyScalar(ne));q=new THREE.Geometry;let Ae=new THREE.LineBasicMaterial({color:e.getColor(),transparent:!0,depthTest:!1});q.vertices.push(Ve,rt),J=new THREE.Line(q,Ae),e.setXData({type:"line"}),e.drawEntity(J),e.getType()==McGiWorldDrawType$1.kWorldDraw&&(L._connectingLine=J)}}}}),e.getType()==1){if(this.svg)e.setXData({type:"svg"}),e.drawEntity(this.svg);else if(this.svgPath.length>0&&this.isLoadFromPath){let L=this,G=e.getMxObject();MxThreeJS.loadSVG(this.svgPath,void 0,q=>{if(q){let J=q;if(J.boxSize)L.svgBoxSize=J.boxSize.clone();else{let De=new THREE.Box3().setFromObject(q);L.svgBoxSize||(L.svgBoxSize=new THREE.Vector3),L.svgBoxSize.x=De.max.x-De.min.x,L.svgBoxSize.y=De.max.y-De.min.y}let[fe,ve]=L.calcVewSize(n);L.svgBoxSize&&(q.scale.x=fe/L.svgBoxSize.x,q.scale.y=ve/L.svgBoxSize.y),q.scale.z=q.scale.x,L.svgReverse&&(q.scale.y*=-1),L.svgMirror&&(q.scale.x*=-1),q.rotateZ(L.svgRotate),L.isSvgDirtyLocation=!0;let ne=new THREE.Color(e.getColor()),Ue=0;q.traverse(function(De){De.material&&(De.material=De.material.clone(),De.material.transparent=!0,De.material.depthTest=!1,L.useSvgColor||(Ue<L.svgChildColor.length?De.material.color=new THREE.Color(L.svgChildColor[Ue]):De.material.color=ne),Ue++)}),L.svg=q,L.setNeedUpdateDisplay(),G.updateDisplay()}else console.log("mx LoadSVG:"+L.svgPath+" failed");L.isLoadFromPath=!1})}else if(this.material){let L=Math.abs(u.x-c.x),G=Math.abs(u.y-c.y),q=new THREE.PlaneGeometry(L,G),J=Math.min(u.x,c.x),fe=Math.min(u.y,c.y);for(let ne=0;ne<q.vertices.length;ne++)q.vertices[ne].x+=J+.5*L,q.vertices[ne].y+=fe+.5*G,q.vertices[ne].z=0;let ve=new THREE.Mesh(q,this.material);ve.material.depthTest=!1,e.drawEntity(ve)}else if(this.isLoadMaterialFromPath&&this.imagePath.length>0){let L=this,G=e.getMxObject();MxFun.loadImageMaterial(this.imagePath,q=>{this.isLoadMaterialFromPath=!1,q&&(L.material=q,L.setNeedUpdateDisplay(),G.updateDisplay())})}this.fixedSize||(e.drawSelectLine(u,c),e.drawSelectLine(y,b),e.drawSelectLine(u,y),e.drawSelectLine(y,c),e.drawSelectLine(c,b),e.drawSelectLine(b,u))}else e.drawLine(u,y),e.drawLine(y,c),e.drawLine(c,b),e.drawLine(b,u);this.imagePath.length>0&&e.setMatrix(null)}async setSvgPath(e,l=!1){this.svgPath=e,this.svg=null,this.isLoadFromPath=!0,this.svgBoxSize=null,l&&await MxThreeJS.loadSVG(e)}getSvgPath(){return this.svgPath}setSvgPostion(e){this.svgPos=e.clone(),this.isSvgDirtyLocation=!0}setImagePath(e,l){this.imagePath=e,l?(this.material=l,this.isLoadMaterialFromPath=!1):(this.material=null,this.isLoadMaterialFromPath=!0)}getImagePath(){return this.imagePath}getSvgPostion(){return this.svgPos}setSvgSize(e){this.svgSize=e,this.isSvgDirtyLocation=!0}getSvgSize(){return this.svgSize}setSvgAlignmentRatio(e){this.svgAlignmentRatio=e,this.isSvgDirtyLocation=!0}getSvgAlignmentRatio(){return this.svgAlignmentRatio}getText(e){return e<this.aryText.length?this.aryText[e]:null}addText(e){this.aryText.push(e)}getGripPoints(){let e=[];e.push(this.svgPos);let l=0;for(;l<this.aryText.length;l++){let n=this.aryText[l];if(n.move){let u=new THREE.Vector3(n.txtPos.x,n.txtPos.y,0);if(this.fixedSize){let c=MxFun.getCurrentDraw();n.txtPos.x>0?u.x=this.svgPos.x+c.screenCoordLong2Doc(n.txtPos.x):u.x=this.svgPos.x-c.screenCoordLong2Doc(n.txtPos.x),n.txtPos.y>0?u.y=this.svgPos.y+c.screenCoordLong2Doc(n.txtPos.y):u.y=this.svgPos.y-c.screenCoordLong2Doc(n.txtPos.y)}e.push(u)}}return e}moveGripPointsAt(e,l){if(e==0)this.svgPos.add(l),this.fixedSize||this.aryText.forEach(n=>{n.txtPos.add(l)});else if(e-1>=0&&e-1<this.aryText.length){let n=this.aryText[e-1];if(n.move)if(this.fixedSize){let u=MxFun.getCurrentDraw();n.txtPos.x+=u.docCoordLong2Screen(l.x),n.txtPos.y+=u.docCoordLong2Screen(l.y)}else n.txtPos.add(l)}return this.isSvgDirtyLocation=!0,!0}calcSvgPosition(e){if(!this.svg||!this.isSvgDirtyLocation)return;this.isSvgDirtyLocation=!1;let[l,n]=this.calcVewSize(e);this.svg.position.x=this.svgPos.x-l*this.svgAlignmentRatio.x-this.svgMargin.x*l,this.svg.position.y=this.svgPos.y-n*this.svgAlignmentRatio.y-this.svgMargin.y*n}dwgIn(e){this.onDwgIn(e),this.fixedSize=e.fixedSize,this.fixedSize?this.svg=null:e.type==MxType.MxCloneType.kClone&&e.svg&&(this.svg=e.svg.clone()),this.svgPos.copy(e.svgPos),this.svgPath=e.svgPath.substr(0),this.svgSize.copy(e.svgSize),this.svgAlignmentRatio.copy(e.svgAlignmentRatio),this.isSvgDirtyLocation=!0,this.svg||(this.isLoadFromPath=!0),this.svgBoxSize=null;let l=e.txts;return this.aryText=[],l.forEach(n=>{let u=new MxDbSVGText;u.txt=n.txt,u.txtHeight=n.txtHeight,u.txtPos.copy(n.txtPos),u.move=n.move,u.drawConnectingLine=n.drawConnectingLine,this.aryText.push(u)}),this.svgRotate=e.svgRotate,this.useSvgColor=e.useSvgColor,this.svgReverse=e.svgReverse,this.svgMirror=e.svgMirror,this.svgMargin=e.svgMargin,e.svgChildColor?this.svgChildColor=e.svgChildColor:this.svgChildColor=[],this.imagePath=e.imagePath.substr(0),this.isLoadMaterialFromPath=!0,e.material&&(this.material=e.material),!0}dwgOut(e){this.onDwgOut(e);let l,n=this.getMxObject();return e.type==MxType.MxCloneType.kClone&&(e.svg=this.svg),e.svgPath=this.svgPath,e.svgPos=this.svgPos,e.svgSize=this.svgSize,e.svgAlignmentRatio=this.svgAlignmentRatio,e.txts=[],e.type==MxType.MxCloneType.kSaveDwgClone&&n&&(l=this.calcSvgDrawRect(n)),this.aryText.forEach(u=>{let c={txtPos:u.txtPos,txt:u.txt,txtHeight:u.txtHeight,color:u.color,_txtAspectRatio:u._txtAspectRatio,move:u.move,drawConnectingLine:u.drawConnectingLine};e.type==MxType.MxCloneType.kSaveDwgClone&&(u._connectingLine&&(c.connectingLine=u._connectingLine.geometry.vertice),u._underLine&&(c._underLine=u._underLine.geometry.vertice)),e.txts.push(c)}),e.fixedSize=this.fixedSize,e.svgRotate=this.svgRotate,e.useSvgColor=this.useSvgColor,e.svgReverse=this.svgReverse,e.svgMirror=this.svgMirror,e.svgMargin=this.svgMargin,e.svgChildColor=this.svgChildColor,e.type==MxType.MxCloneType.kSaveDwgClone&&(e.svgRect=l),e.imagePath=this.imagePath,e.type==MxType.MxCloneType.kDragClone&&(e.material=this.material),e}create(){return new MxDbSVG}transformBy(e){this.svgPos.applyMatrix4(e),this.isSvgDirtyLocation=!0,this.fixedSize||this.aryText.forEach(l=>{l.txtPos.applyMatrix4(e)})}getTypeName(){return"MxDbSVG"}setColor(e){if(super.setColor(e),this.svg){let l=new THREE.Color(this.color);this.svg.traverse(function(n){n.material&&(n.material.color=l)})}return this}setSvg(e){this.svg=e,this.isLoadFromPath=!1,this.svgBoxSize=null}calcSvgBoxSize(e){if(!this.svgBoxSize)if(e.boxSize)this.svgBoxSize=e.boxSize.clone();else{let l=new THREE.Box3().setFromObject(e);this.svgBoxSize||(this.svgBoxSize=new THREE.Vector3),this.svgBoxSize.x=l.max.x-l.min.x,this.svgBoxSize.y=l.max.y-l.min.y}}reComputeSVG(){if(!this.svg)return;let e=this.getMxObject();if(!e)return;this.calcSvgBoxSize(this.svg);let[l,n]=this.calcVewSize(e);this.svgBoxSize&&(this.svg.scale.x=l/this.svgBoxSize.x,this.svg.scale.y=n/this.svgBoxSize.y),this.svg.scale.z=this.svg.scale.x,this.svgReverse&&(this.svg.scale.y*=-1),this.svgMirror&&(this.svg.scale.x*=-1),this.isSvgDirtyLocation=!0,this.calcSvgPosition(e)}onViewChange(){if(!this.fixedSize)return!1;if(this.imagePath.length>0)return this.setNeedUpdateDisplay(!1),!0;let e=this.getMxObject();if(e==null)return!1;if(this.svg){this.calcSvgBoxSize(this.svg);let[y,b]=this.calcVewSize(e);this.svgBoxSize&&(this.svg.scale.x=y/this.svgBoxSize.x,this.svg.scale.y=b/this.svgBoxSize.y),this.svg.scale.z=this.svg.scale.x,this.svgReverse&&(this.svg.scale.y*=-1),this.svgMirror&&(this.svg.scale.x*=-1),this.isSvgDirtyLocation=!0,this.calcSvgPosition(e)}let l=this.calcSvgDrawRect(e),n=l.cenpt,u=l.sizew,c=this;return this.aryText.forEach(y=>{if(y._txtObject&&e){let m=e.screenCoordLong2Doc(y.txtHeight);if(m>1e-5){y._txtAspectRatio<=0&&(y._txtAspectRatio=y._txtObject.scale.x/y._txtObject.scale.y),y._txtObject.scale.set(y._txtAspectRatio*m*1.5,1.5*m,1),y.txtPos.x>0?y._txtObject.position.x=c.svgPos.x+e.screenCoordLong2Doc(y.txtPos.x):y._txtObject.position.x=c.svgPos.x-e.screenCoordLong2Doc(y.txtPos.x),y.txtPos.y>0?y._txtObject.position.y=c.svgPos.y+e.screenCoordLong2Doc(y.txtPos.y):y._txtObject.position.y=c.svgPos.y-e.screenCoordLong2Doc(y.txtPos.y);let O=y._txtObject.position;if(y._txtObject.updateMatrix(),y._underLine){const N=new THREE.Box3;let L=y._txtObject.parent;y._txtObject.parent=null,N.expandByObject(y._txtObject),y._txtObject.parent=L;let G=new THREE.Vector3(N.min.x,N.min.y+.1*m,0),q=new THREE.Vector3(N.max.x,N.min.y+.1*m,0);(b=new THREE.Geometry).vertices.push(G,q),y._underLine.geometry=b}if(y._connectingLine){let N=n.clone().sub(O);N.normalize();let L=n.clone().sub(N.clone().multiplyScalar(u)),G=O.clone().add(N.clone().multiplyScalar(m));var b;(b=new THREE.Geometry).vertices.push(L,G),y._connectingLine.geometry=b}}}}),!0}}function drawMxDbPolyline(){const t=new MrxDbgUiPrPoint;t.setMessage(`
- 指定第一点:`);let e,l=new MxDbPolyline;t.go(n=>{if(n!=0)return;let u=t.value();e||(e=u.clone());let c=u;const y=new McEdGetPointWorldDrawObject;y.setDraw((m,O)=>{O.setColor(16711680),O.drawLine(c,m),O.drawCustomEntity(l)}),t.setUserDraw(y),t.setMessage(`
- 指定下一点:`);let b=0;l.addVertexAt(u),t.goWhile(m=>{if(m==0)c=t.value(),l.addVertexAt(c),++b>=2?(t.setMessage(`
- 指定下一点:`),t.setKeyWords("[闭合(C)/放弃(U)]")):b>0?(t.setMessage(`
- 指定下一点:`),t.setKeyWords("[放弃(U)]")):(t.setMessage(`
- 指定第一点:`),t.setKeyWords(""));else if(m==1){if(t.isKeyWordPicked("C"))return{exit:!0};t.isKeyWordPicked("U")&&console.log("Mx_Line undo....")}},()=>{MxFun.getCurrentDraw().addMxEntity(l)})})}MxDbSVG.cmd="Mx_ModelFixedSvg",MxDbSVG.draw=drawMxDbSVG,addRegisterMxDbEntity(MxDbSVG);class MxDbPolyline extends MxDbEntity{constructor(){super(...arguments),this.points=[]}getTypeName(){return"MxDbPolyline"}worldDraw(e){this.points.length<2||e.drawLines(this.points)}getGripPoints(){return this.points}moveGripPointsAt(e,l){return!(e>=this.points.length||(this.points[e].add(l),0))}create(){return new MxDbPolyline}dwgIn(e){this.onDwgIn(e);let l=e.points;return this.points=[],l.forEach(n=>{this.points.push(new THREE.Vector3(n.x,n.y,n.z))}),!0}dwgOut(e){return this.onDwgOut(e),e.points=this.points,e}addVertexAt(e){this.points.push(e)}numVerts(){return this.points.length}getPointAt(e){return e<this.points.length?this.points[e]:null}setPointAt(e,l){return e<this.points.length&&(this.points[e]=l,!0)}}function drawMxDb2LineAngularDimension(){const t=new MrxDbgUiPrPoint,e=MxFun.getCurrentDraw(),l=new MxDb2LineAngularDimension,n=new McEdGetPointWorldDrawObject;return t.setMessage(`
- 指定第一点:`),t.go(u=>{u===0&&(t.setMessage(`
- 指定第二个角度点:`),l.point1=t.value(),n.setDraw((c,y)=>{l.point2=c,n.drawLine(l.point1,c)}),t.setUserDraw(n),t.go(c=>{t.setMessage(`
- 指定最后一个点:`),c===0&&(l.point2=t.value(),n.setDraw((y,b)=>{l.point3=y,n.drawCustomEntity(l)}),t.go(y=>{y===0&&e.addMxEntity(l)}))}))}),l}MxDbPolyline.cmd="Mx_Lines",MxDbPolyline.draw=drawMxDbPolyline,addRegisterMxDbEntity(MxDbPolyline);const propertyDbKeys$6=["colors","point1","point2","point3"];class MxDb2LineAngularDimension extends MxDbEntity{constructor(e){if(super(),this.point1=new THREE.Vector3,this.point2=new THREE.Vector3,this.point3=new THREE.Vector3,this.colors=[],e){const{points:l,colors:n}=e;l&&this.setPoints(l),n&&this.setColor(n)}}calculateLineAngle(e,l,n){const u=2*Math.PI/360;return{startAngle:180*Math.atan2(l.y-e.y,l.x-e.x)/Math.PI*u,endAngle:180*Math.atan2(n.y-e.y,n.x-e.x)/Math.PI*u}}setPoints(e){const[l,n,u]=e;return l&&(this.point1=l),n&&(this.point2=n),u&&(this.point3=u),this}setColor(e){return lodash.isArray(e)?this.colors=e:this.color=e,this}worldDraw(e){if(e.getType()==McGiWorldDrawType$1.kWorldDraw||e.getType()==McGiWorldDrawType$1.kDynDragDraw){const[l,n,u,c]=this.colors||[],y=this.getColor(),b=e.getMxObject();e.setOpacity(this.opacity),e.setColor(l||y),e.drawLine(this.point1,this.point2),e.setColor(n||y),e.drawLine(this.point2,this.point3);const{startAngle:m,endAngle:O}=this.calculateLineAngle(this.point2,this.point1,this.point3),N=this.point2.distanceTo(this.point1),L=this.point2.distanceTo(this.point3),G=Math.min(N,L)/4;let q=THREE.MathUtils.radToDeg(m-O);q<0&&(q+=360);let J=b.screenCoordLong2Doc(50);const fe=new THREE.ArcCurve(this.point2.x,this.point2.y,G,m,O,!0),ve=new THREE.Geometry().setFromPoints(fe.getPoints(50));e.setColor(u||y),e.drawGeometryLines(ve);const ne=fe.getPoint(.5);let Ue=new THREE.Vector3(ne.x,ne.y,0);const De=Ue.sub(this.point2),Ve=De.length()+.5*J;De.normalize().multiplyScalar(Ve),Ue=this.point2.clone().add(De),e.setColor(c||y),e.drawText(q.toFixed(3)+"°",.5*J,0,Ue)}else e.drawLine(this.point1,this.point2),e.drawLine(this.point3,this.point2)}getGripPoints(){return[this.point1,this.point2,this.point3]}moveGripPointsAt(e,l){return e===0?this.point1.add(l):e===1?this.point2.add(l):e===2&&this.point3.add(l),!0}dwgIn(e){return this.onDwgIn(e),this.dwgInHelp(e,propertyDbKeys$6),!0}dwgOut(e){return this.onDwgOut(e),this.dwgOutHelp(e,propertyDbKeys$6),e}create(){return new MxDb2LineAngularDimension}transformBy(e){this.point1.applyMatrix4(e),this.point2.applyMatrix4(e)}getTypeName(){return"MxDb2LineAngularDimension"}}MxDb2LineAngularDimension.cmd="Mx_AngleSurveying",MxDb2LineAngularDimension.draw=drawMxDb2LineAngularDimension,addRegisterMxDbEntity(MxDb2LineAngularDimension);class MxFilters{constructor(){this.uniformObj={},this.filtersStr="",this.filtersTypes="",this.VSHADER_SOURCE=`
- varying vec2 v_Uv;
- void main () {
- v_Uv = uv;
- gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );
- }
- `,this.FSHADER_SOURCE=`
- varying vec2 v_Uv;
- uniform sampler2D e_Texture;
- uniform mat4 colorMatrix;
- ${this.filtersStr}
- void main () {
- vec4 color = texture2D( e_Texture, v_Uv );
- color = color * colorMatrix;
- ${this.filtersTypes}
- gl_FragColor = color;
- }`,this._matrix=new THREE.Matrix4}channel({r:e=1,g:l=1,b:n=1}){return this._matrix=new THREE.Matrix4().set(e,0,0,0,0,l,0,0,0,0,n,0,0,0,0,1).multiply(this._matrix),this}brightness(e){return this._matrix=new THREE.Matrix4().set(e,0,0,0,0,e,0,0,0,0,e,0,0,0,0,1).multiply(this._matrix),this}saturate(e){const l=.2126*(1-e),n=.7152*(1-e),u=.0722*(1-e);return this._matrix=new THREE.Matrix4().set(l+e,n,u,0,l,n+e,u,0,l,n,u+e,0,0,0,0,1).multiply(this._matrix),this}contrast(e){const l=.5*(1-e);return this._matrix=new THREE.Matrix4().set(e,0,0,0,0,e,0,0,0,0,e,0,l,l,l,1).multiply(this._matrix),this}opacity(e){return this._matrix=new THREE.Matrix4().set(1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,e).multiply(this._matrix),this}invert(e){const l=1-2*e;return this._matrix=new THREE.Matrix4().set(l,0,0,0,0,l,0,0,0,0,l,0,e,e,e,1).multiply(this._matrix),this}grayscale(e=1){const l=.2126*e,n=.7152*e,u=.0722*e;return this._matrix=new THREE.Matrix4().set(l+1-e,n,u,0,l,n+1-e,u,0,l,n,u+1-e,0,0,0,0,1).multiply(this._matrix),this}sepia(e=1){return this._matrix=new THREE.Matrix4().set(1-.607*e,.769*e,.189*e,0,.349*e,1-.314*e,.168*e,0,.272*e,.534*e,1-.869*e,0,0,0,0,1).multiply(this._matrix),this}hueRotate(e){const l=e/180*Math.PI,n=Math.cos(l),u=Math.sin(l),c=.2126,y=.7152,b=.0722;return this._matrix=new THREE.Matrix4().set(c+.7874*n+u*-c,y+n*-y+u*-y,b+n*-b+.9278*u,0,c+n*-c+.143*u,y+n*(1-y)+.14*u,b+n*-b+-.283*u,0,c+n*-c+-.7874*u,y+n*-y+u*y,b+.9278*n+u*b,0,0,0,0,1).multiply(this._matrix),this}convolution(e,l=1/9,n=521){return this.uniformObj=Object.assign(Object.assign({},this.uniformObj),{cKernel:{value:e.toArray()},stStep:{value:l},scaleFactor:{value:n}}),this.filtersTypes.indexOf("convolutionTextureColor")<0&&(this.filtersStr+=`
- uniform float cKernel[9];
- uniform float stStep;
- uniform float scaleFactor;
- vec4 convolutionTextureColor(vec4 color) {
- vec2 offsets[9];
- offsets[0] = vec2(-1.0,-1.0);
- offsets[1] = vec2(0.0,-1.0);
- offsets[2] = vec2(1.0,-1.0);
- offsets[3] = vec2(-1.0,0.0);
- offsets[4] = vec2(0.0,0.0);
- offsets[5] = vec2(1.0,0.0);
- offsets[6] = vec2(-1.0,1.0);
- offsets[7] = vec2(0.0,1.0);
- offsets[8] = vec2(1.0,1.0);
- vec4 sum = color;
- for(int i = 0; i < 9; i++) {
- sum = sum + cKernel[i] * scaleFactor * texture2D(e_Texture, v_Uv + offsets[i] / stStep);
- };
- return sum;
- }`,this.filtersTypes+=`color = convolutionTextureColor(color);
- `),this}reset(){return this.uniformObj={},this.filtersStr="",this.filtersTypes="",this._matrix=new THREE.Matrix4,this}_getFilterShaderData(e){return{uniforms:Object.assign({e_Texture:{value:e},colorMatrix:{value:this._matrix}},this.uniformObj),vertexShader:this.VSHADER_SOURCE,fragmentShader:this.FSHADER_SOURCE}}_getFilterColor(e="#000000",l=1){e=new THREE.Color(e);let{r:n,g:u,b:c}=e;const y=this._matrix.toArray();y[12],y[13],y[14],y[15];const b=y[0]*n+y[1]*n+y[2]*n+y[3]*l,m=y[4]*u+y[5]*u+y[6]*u+y[7]*l,O=y[8]*c+y[9]*c+y[10]*c+y[11]*l;return e.setRGB(b,m,O),e}toJSON(){return JSON.stringify({matrix:this._matrix.toArray(),uniformObj:this.uniformObj,filtersStr:this.filtersStr,filtersTypes:this.filtersTypes})}static fromJSON(e){const{matrix:l,uniformObj:n,filtersStr:u,filtersTypes:c}=JSON.parse(e),y=new MxFilters;return y._matrix=new THREE.Matrix4().fromArray(l),y.uniformObj=n,y.filtersStr=u,y.filtersTypes=c,y}}class MxDbShape extends MxDbEntity{constructor(){super(...arguments),this.isLoadMaterialFromPath=!0,this.stroke="#fff",this.strokeLineWidth=2,this.isStrokeDashLine=!1,this.isFill=!1,this._fillImageSrc=null,this.curveSegments=50,this.closed=!0,this.filter=null,this._cornerRadius=[],this._propertyDbKeys=["isFill","stroke","strokeLineWidth","isStrokeDashLine","closed","cornerRadius","fillImageSrc","fillImageParam","curveSegments"]}setStroke(e){return this.stroke=e,this}setStrokeLineWidth(e){return this.strokeLineWidth=e,this}setIsStrokeDashLine(e){return this.isStrokeDashLine=e,this}setIsFill(e){return this.isFill=e,this}get fillImageSrc(){return this._fillImageSrc}set fillImageSrc(e){this._fillImageSrc=e,this.isLoadMaterialFromPath=!0,this.material=null,this.fillImageSrc&&(this.isFill=!0),e!==!1&&e!==null||(this.setNeedUpdateDisplay(),MxFun.updateDisplay())}setFillImageSrc(e){return this.fillImageSrc=e,this}setFillImageParam(e){this.fillImageParam=e===void 0?e:Object.assign(this.fillImageParam,e)}setCurveSegments(e){return this.curveSegments=e,this}setClosed(e){return this.closed=e,this}getFilter(){return this.filter}setFilter(e){this.filter=e,this.isLoadMaterialFromPath=!0,this.material=null}get cornerRadius(){return this._cornerRadius}set cornerRadius(e){this.setCornerRadius(e)}setCornerRadius(e,l=!0){this._cornerRadius=e instanceof Array?e.map(n=>l?MxFun.screenCoordLong2Doc(n):n):l?MxFun.screenCoordLong2Doc(e):e}getTypeName(){return"MxDbShape"}getShapePoints(e){const{curveSegments:l}=this;return this.points=e.getPoints(l).map(n=>n instanceof THREE.Vector2?new THREE.Vector3(n.x,n.y,0):n),this.points}createPaths(e){return this._paths=new THREE.CurvePath,Array.isArray(e)?e.forEach(l=>this._paths.add(l)):this._paths.add(e),this._paths}_draw(e,l){let{isFill:n,closed:u,opacity:c,dLineWidth:y,lineWidthByPixels:b}=this;e.setOpacity(c),e.setLineWidthByPixels(b),e.setLineWidth(y);const m=e.getColor();e.setColor(this.filter?this.filter._getFilterColor(this.color,this.opacity):this.color);const O=this.getCornerRadiusPoints(u||n?this.getClosedPoints(l):l);n?!this.fillImageSrc&&e.drawSolid(O):e.drawLines(O),this._fillImg(e,O),e.setColor(m)}getCornerRadiusPoints(e){const{cornerRadius:l}=this;if(!l)return e;const n=typeof l=="number"?e.map(()=>l):l;return n.length>0?getToGenerateRoundedCorners(e,n):e}_drawStoreLine(e,l,n){const{isFill:u,stroke:c,strokeLineWidth:y}=this,b=e.getLineWidth(),m=e.getColor(),O=e.isDashLineDisplay();c&&u&&(e.setDashLineDisplay(this.isStrokeDashLine),e.setColor(c),e.setLineWidth(y),n?n(e):e.drawLines(this.getCornerRadiusPoints(this.getClosedPoints(l))),e.setColor(m),e.setLineWidth(b),e.setDashLineDisplay(O))}getClosedPoints(e){return[...e,e[0]]}getTotalLength(){if(this.points){let e=0;return this.points.reduce((l,n)=>(e+=l.distanceTo(n),n)),e}if(this._paths)return this._paths.getLength()+(this.closedLine?this.closedLine.getLength():0)}getGetLength(){return this._paths.getLength()}getArea(){return this.points?McGeTool.calcArea(this.closed?this.getClosedPoints(this.points):this.points):0}worldDraw(e){const l=this.createPaths(new THREE.Curve),n=this.getShapePoints(l);this._draw(e,n),this._drawStoreLine(e,n)}_fillImg(e,l){const n={transparent:!0,depthTest:!1,opacity:this.opacity,visible:this.visible};if(!this.isFill||!this.fillImageSrc)return;if(!this.material){let m=this;return void MxFun.loadImageMaterial(this.fillImageSrc,O=>{m.isLoadMaterialFromPath=!1,O&&(m.material=O,m.setNeedUpdateDisplay(),MxFun.updateDisplay())})}const u=l.map(({x:m,y:O})=>new THREE.Vector2(m,O));let c=this.material,y=new THREE.ShapeGeometry(new THREE.Shape(u));if(y=repairGeometryFaceVertexUvs(y),this.filter){const m=c.map,O=this.filter._getFilterShaderData(m);c=new THREE.ShaderMaterial(Object.assign(Object.assign({},O),n))}if(c.depthTest=!1,c.transparent=!0,c.opacity=this.opacity,c.visible=this.visible,this.fillImageParam){const m=this.fillImageParam;for(let O in this.fillImageParam)this.material.map[O]=m[O]}let b=new THREE.Mesh(y,c);e.drawEntity(b)}getGripPoints(){return[]}moveGripPointsAt(e,l){return!0}dwgIn(e){return this.onDwgIn(e),this.dwgInHelp(e,this._propertyDbKeys),this.isLoadMaterialFromPath=!0,this.material=null,e.type===MxType.MxCloneType.kMxFileClone?e.filter&&(this.filter=MxFilters.fromJSON(e.filter)):e.filter&&(this.filter=e.filter),!0}dwgOut(e){var l;return this.onDwgOut(e),this.dwgOutHelp(e,this._propertyDbKeys),e.type===MxType.MxCloneType.kMxFileClone?this.filter&&(e.filter=(l=this.filter)===null||l===void 0?void 0:l.toJSON()):e.filter=this.filter,e}transformBy(e){this.points&&this.points.forEach(l=>{l.applyMatrix4(e)})}}class MxDbEllipseShape extends MxDbShape{constructor(){super(),this.center=new THREE.Vector3,this.xRadius=10,this.yRadius=10,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!1,this.rotation=0,this.isClosedToCenter=!0,this._propertyDbKeys=[...this._propertyDbKeys,"center","xRadius","yRadius","startAngle","endAngle","clockwise","rotation","isClosedToCenter"]}getTypeName(){return"MxDbEllipseShape"}setCenter(e){return this.center=e,this}setXRadius(e){return this.xRadius=e,this}setYRadius(e){return this.yRadius=e,this}setStartAngle(e){return this.startAngle=e,this}setEndAngle(e){return this.endAngle=e,this}setClockwise(e){return this.clockwise=e,this}setRotation(e){return this.rotation=e,this}setIsClosedToCenter(e){return this.isClosedToCenter=e,this}worldDraw(e){this.drawEllipseShape(e)}drawEllipseShape(e){let{startAngle:l,endAngle:n,clockwise:u}=this;const c=this.createEllipseCurve(),y=this.createPaths(c);let b=this.getShapePoints(y);return this._draw(e,b),this._drawStoreLine(e,b),{centralAngle:u?n>l?THREE.MathUtils.radToDeg(c.aEndAngle-c.aStartAngle):360-Math.abs(THREE.MathUtils.radToDeg(c.aEndAngle-c.aStartAngle)):l>n?Math.abs(THREE.MathUtils.radToDeg(c.aEndAngle-c.aStartAngle)):360-THREE.MathUtils.radToDeg(c.aEndAngle-c.aStartAngle),curve:c,points:b}}createEllipseCurve(e=this.center.x,l=this.center.y,n=this.xRadius,u=this.yRadius,c=this.startAngle,y=this.endAngle,b=this.clockwise,m=this.rotation){return new THREE.EllipseCurve(e,l,n,u,c,y,b,m)}getCornerRadiusPoints(e){return e}getClosedPoints(e){try{let l=(this._paths||new THREE.CatmullRomCurve3(e,!1,"catmullrom",0)).getLength();this.closedLine=this.getClosedLine(e);const n=this.closedLine.getLength();let u=this.curveSegments/l,c=2.5*(l>this.curveSegments?n*u:1);if(c>20*this.curveSegments&&(c=20*this.curveSegments),c<=0)return e;const y=this.closedLine.getPoints(c);return[...e,...y]}catch{return[...e,e[0]]}}getClosedLine(e){const{isClosedToCenter:l,center:n}=this;let u=l?[e[e.length-1],n,e[0]]:[e[e.length-1],e[0]];return new THREE.CatmullRomCurve3(u,!1,"catmullrom",.01)}getGripPoints(){return[this.center]}moveGripPointsAt(e,l){return e===0&&this.center.add(l),!0}}class MxDbCircleShape extends MxDbEllipseShape{getTypeName(){return"MxDbCircleShape"}get radius(){return this.xRadius}set radius(e){this.xRadius=e,this.yRadius=e}setRadius(e){return this.radius=e,this}setXRadius(e){return this.setRadius(e),this}setYRadius(e){return this.setRadius(e),this}}function drawMx3PointArc(){const t=new MrxDbgUiPrPoint,e=new McEdGetPointWorldDrawObject,l=new Mx3PointArc;t.setUserDraw(e),t.setMessage(`
- 确定圆弧开始点:`),t.go(n=>{n===MrxDbgUiPrBaseReturn$1.kOk&&(l.point1=t.value(),e.setDraw(u=>{e.drawLine(l.point1,u)})),t.setMessage(`
- 确定圆弧结束点:`),t.go(u=>{u===MrxDbgUiPrBaseReturn$1.kOk&&(l.point2=t.value(),e.setDraw(c=>{l.point3=c,e.drawCustomEntity(l)})),t.setMessage(`
- 确定圆弧上任意一点:`),t.go(c=>{if(c===MrxDbgUiPrBaseReturn$1.kOk){MxFun.getCurrentDraw().addMxEntity(l);const{radius:y,angle:b,arcLength:m}=createThreePointArc(l.point1,l.point2,l.point3,!0);console.log("半径:",y),console.log("圆弧弧长:",m,l.getTotalLength())}})})})}class Mx3PointArc extends MxDbCircleShape{constructor(){super(),this.point1=new THREE.Vector3,this.point2=new THREE.Vector3,this.point3=new THREE.Vector3,this.autoClockwise=!0,this.closed=!1,this.centralAngle=0,this._propertyDbKeys=[...this._propertyDbKeys,"point1","point2","point3","autoClockwise"]}getTypeName(){return"Mx3PointArc"}create(){return new Mx3PointArc}worldDraw(e){this.updateDataInfo();const{centralAngle:l}=this.drawEllipseShape(e);this.centralAngle=l}getGripPoints(){return[this.point1,this.point2,this.point3,this.center]}compute3PointAngle(e=this.point1,l=this.point2,n=this.point3){const u=calculateArcAngle(e,this.center,this.radius),c=calculateArcAngle(l,this.center,this.radius),y=calculateArcAngle(n,this.center,this.radius);return[u.angle,c.angle,y.angle]}upDateCenter(e=this.point1,l=this.point2,n=this.point3){return this.center=calculateArcOrigin(e,l,n),this.center}upDateRadius(e=this.point1){return this.radius=calculateRadiusArc(e,this.center),this.radius}upDataClockwise(e,l,n){const{autoClockwise:u}=this;u&&(this.clockwise=judgementArcRenderDirection(l,e,n))}updateDataInfo(){this.upDateCenter(this.point1,this.point2,this.point3),this.upDateRadius(this.point1);const[e,l,n]=this.compute3PointAngle();this.startAngle=THREE.MathUtils.degToRad(e),this.endAngle=THREE.MathUtils.degToRad(l),this.upDataClockwise(e,l,n)}getArcMidPoint(){const e=MxFun.getMxFunTHREE();this.updateDataInfo();let{startAngle:l,endAngle:n,center:u,radius:c,clockwise:y}=this;y?l<n&&(l+=2*Math.PI):l>n&&(n+=2*Math.PI);const b=(l+n)/2,m=u.x+c*Math.cos(b),O=u.y+c*Math.sin(b);return new e.Vector3(m,O,0)}moveGripPointsAt(e,l){return e===0?this.point1.add(l):e===1?this.point2.add(l):e===2?this.point3.add(l):e===3&&(this.point1.add(l),this.point2.add(l),this.point3.add(l)),this.upDateCenter(),!0}}Mx3PointArc.cmd="Mx_3PointArc",Mx3PointArc.draw=drawMx3PointArc,Mx3PointArc.isRegister=!1,addRegisterMxDbEntity(Mx3PointArc);const drawMx2PointArc=async()=>{const t=new MrxDbgUiPrPoint,e=new Mx2PointArc,l=await t.go();if(!l)return;e.startPoint=l,t.setUserDraw((u,c)=>{e.endPoint=u,c.drawCustomEntity(e)});const n=await t.go();n&&(e.endPoint=n,MxFun.getCurrentDraw().addMxEntity(e))};class Mx2PointArc extends Mx3PointArc{getTypeName(){return"Mx2PointArc"}create(){return new Mx2PointArc}get startPoint(){return this.point1}set startPoint(e){this.point1=e,this.point3.x,this.point1.x,this.point3.y,this.point2.y}get endPoint(){return this.point2}set endPoint(e){this.point2=e,this.point3=this.getArcMidPoint()}}function drawMxDbCoord(){const t=new MrxDbgUiPrPoint;t.setMessage(`
- 指定坐标点:`),t.go(e=>{if(e!=0)return;const l=t.value();let n=new MxDbCoord;n.point1=l,n.point2=l.clone(),t.setBasePt(l),t.setUseBasePt(!0),t.setUserDraw((u,c)=>{n.point2=u,c.drawCustomEntity(n)}),t.setMessage(`
- 指定标注点:`),t.go(u=>{u==0?(n.point2=t.value(),MxFun.addToCurrentSpace(n)):console.log(u)})})}Mx2PointArc.cmd="Mx_2PointArc",Mx2PointArc.draw=drawMx2PointArc,Mx2PointArc.isRegister=!1,addRegisterMxDbEntity(Mx2PointArc);class MxDbCoord extends MxDbEntity{constructor(){super(...arguments),this.point1=new THREE.Vector3,this.point2=new THREE.Vector3}worldDraw(e){let l=e.getMxObject();e.drawLine(this.point1,this.point2);let n=this.point2.clone();var u=l.screenCoordLong2Doc(20),c=6*u;n.x=n.x+c,e.drawLine(this.point2,n);var y=new THREE.Vector3,b=new THREE.Vector3;let m=l.docCoord2Cad(this.point1.x,this.point1.y,this.point1.z),O=m.x.toFixed(3),N=m.y.toFixed(3);y.x=this.point2.x+.3*u+.5*c,y.y=this.point2.y+.1*u+.5*u,e.drawText(O,u,0,y),b.x=this.point2.x+.3*u+.5*c,b.y=this.point2.y-.1*u-.5*u,e.drawText(N,u,0,b)}getGripPoints(){let e=[];return e.push(this.point1),e.push(this.point2),e}moveGripPointsAt(e,l){return e==0?this.point1.add(l):e==1&&this.point2.add(l),!0}dwgIn(e){return this.onDwgIn(e),this.point1.copy(e.point1),this.point2.copy(e.point2),!0}dwgOut(e){return this.onDwgOut(e),e.point1=this.point1,e.point2=this.point2,e}create(){return new MxDbCoord}transformBy(e){this.point1.applyMatrix4(e),this.point2.applyMatrix4(e)}getTypeName(){return"MxDbCoord"}}async function drawMxDbLine(){const t=new MrxDbgUiPrPoint;t.setMessage(`
- 指定第一点:`);let e=await t.go();if(e==null)return;t.setBasePt(e.clone()),t.setUseBasePt(!0),t.setMessage(`
- 指定第二点:`);let l=await t.go();if(l==null)return;let n=new MxDbLine;n.pt1=e,n.pt2=l,MxFun.addToCurrentSpace(n)}MxDbCoord.cmd="Mx_Coord",MxDbCoord.draw=drawMxDbCoord,addRegisterMxDbEntity(MxDbCoord);class MxDbLine extends MxDbEntity{constructor(){super(...arguments),this.pt1=new THREE.Vector3,this.pt2=new THREE.Vector3}getTypeName(){return"MxDbLine"}worldDraw(e){e.drawLine(this.pt1,this.pt2)}setPoint1(e){this.pt1=e}getPoint1(){return this.pt1}setPoint2(e){this.pt2=e}getPoint2(){return this.pt2}getGripPoints(){let e=[];e.push(this.pt1),e.push(this.pt2);let l=new THREE.Vector3(this.pt1.x+.5*(this.pt2.x-this.pt1.x),this.pt1.y+.5*(this.pt2.y-this.pt1.y),0);return e.push(l),e}moveGripPointsAt(e,l){return e==0?this.pt1.add(l):e==1?this.pt2.add(l):e==2&&(this.pt1.add(l),this.pt2.add(l)),!0}dwgIn(e){return this.onDwgIn(e),this.pt1.copy(e.pt1),this.pt2.copy(e.pt2),!0}dwgOut(e){return this.onDwgOut(e),e.pt1=this.pt1,e.pt2=this.pt2,e}create(){return new MxDbLine}getGeomExtents(){return new THREE.Box3(this.pt1,this.pt2)}getGetLength(){return this.pt1.distanceTo(this.pt2)}}async function drawMxDbRect(){const t=new MrxDbgUiPrPoint;t.setMessage(`
- 指定第一点:`);let e=await t.go();if(!e)return;let l=new MxDbRect;l.pt1=e;const n=new McEdGetPointWorldDrawObject;n.setDraw(u=>{l.pt2=u,n.drawCustomEntity(l)}),t.setBasePt(e),t.setUseBasePt(!0),t.setUserDraw(n),t.setMessage(`
- 指定第二点:`),await t.go()&&(l.pt2=t.value(),MxFun.getCurrentDraw().addMxEntity(l))}MxDbLine.cmd="Mx_Line",MxDbLine.draw=drawMxDbLine,addRegisterMxDbEntity(MxDbLine);class MxDbRect extends MxDbEntity{constructor(){super(...arguments),this.cornerRadius=[],this.pt1=new THREE.Vector3,this.pt2=new THREE.Vector3,this.isSolidColorFill=!1,this.isLoadMaterialFromPath=!0,this.material=null}worldDraw(e){let l=computeRectPoints(this.pt1,this.pt2);if(this.cornerRadius.length>0&&(l=getToGenerateRoundedCorners(l,this.cornerRadius)),e.getType()!=McGiWorldDrawType$1.kWorldDraw)return l.push(l[0]),void e.drawLines(l);const n={transparent:!0,depthTest:!1,opacity:this.opacity,visible:this.visible};if(this.isSolidColorFill){let u;l=l.map(({x:b,y:m})=>new THREE.Vector2(b,m)),u=new THREE.ShapeGeometry(new THREE.Shape(l));let c=new THREE.MeshBasicMaterial(Object.assign({color:this.filter?this.filter._getFilterColor(this.color,this.opacity):new THREE.Color(this.color)},n)),y=new THREE.Mesh(u,c);e.drawEntity(y)}else if(this.fillImageSrc){if(this.material){l=l.map(({x:b,y:m})=>new THREE.Vector2(b,m));let u=this.material,c=new THREE.ShapeGeometry(new THREE.Shape(l));if(c=repairGeometryFaceVertexUvs(c),this.filter){const b=u.map;this.fillImageParam&&(this.fillImageParam.center&&(b.center=this.fillImageParam.center),this.fillImageParam.offset&&(b.offset=this.fillImageParam.offset),this.fillImageParam.repeat&&(b.repeat=this.fillImageParam.repeat),this.fillImageParam.rotation&&(b.rotation=this.fillImageParam.rotation));const m=this.filter._getFilterShaderData(b);u=new THREE.ShaderMaterial(Object.assign(Object.assign({},m),n))}u.depthTest=!1,u.transparent=!0,u.opacity=this.opacity,u.visible=this.visible;let y=new THREE.Mesh(c,u);e.drawEntity(y)}else if(this.fillImageSrc.length>0&&this.isLoadMaterialFromPath){let u=this;MxFun.loadImageMaterial(this.fillImageSrc,c=>{this.isLoadMaterialFromPath=!1,c&&(u.material=c,u.setNeedUpdateDisplay(),MxFun.updateDisplay())})}}else{let u=new THREE.BufferGeometry().setFromPoints(l),c=new THREE.LineBasicMaterial(Object.assign({color:this.getColor()},n)),y=new THREE.LineLoop(u,c);e.drawEntity(y)}}getGripPoints(){let e=[];e.push(this.pt1);const l=new THREE.Line3(this.pt1,this.pt2);let n=new THREE.Vector3;return l.getCenter(n),e.push(n),e.push(this.pt2),e}moveGripPointsAt(e,l){return e==0?this.pt1.add(l):e==1?(this.pt1.add(l),this.pt2.add(l)):e==2&&this.pt2.add(l),!0}dwgIn(e){return this.onDwgIn(e),this.pt1.copy(e.pt1),this.pt2.copy(e.pt2),this.isSolidColorFill=e.isSolidColorFill,this.fillImageSrc=e.fillImageSrc,this.fillImageParam=e.fillImageParam,this.cornerRadius=e.cornerRadius,this.filter=e.filter,this.isLoadMaterialFromPath=!0,this.material=null,!0}dwgOut(e){return this.onDwgOut(e),e.pt1=this.pt1,e.pt2=this.pt2,e.isSolidColorFill=this.isSolidColorFill,e.fillImageSrc=this.fillImageSrc,e.fillImageParam=this.fillImageParam,e.cornerRadius=this.cornerRadius,e.filter=this.filter,e}create(){return new MxDbRect}transformBy(e){this.pt1.applyMatrix4(e),this.pt2.applyMatrix4(e)}setRadius(e,l=!0){this.cornerRadius=e instanceof Array?e.map(n=>l?MxFun.screenCoordLong2Doc(n):n):e>0?l?[MxFun.screenCoordLong2Doc(e),MxFun.screenCoordLong2Doc(e),MxFun.screenCoordLong2Doc(e),MxFun.screenCoordLong2Doc(e)]:[e,e,e,e]:[]}getTypeName(){return"MxDbRect"}getFilter(){return this.filter}setFilter(e){this.filter=e,this.isLoadMaterialFromPath=!0,this.material=null}setFillImagePath(e){this.fillImageSrc=e,this.isLoadMaterialFromPath=!0,this.material=null,this.fillImageSrc&&(this.isSolidColorFill=!1)}getFillImagePath(){return this.fillImageSrc}}function drawMxDbAlignedDimension(){let t=new MxDbAlignedDimension;const e=new MrxDbgUiPrPoint;return e.setMessage(`
- 指定第一点:`),e.go(l=>{if(l!=0)return;const n=e.value();t.setPoint1(n),t.setColor(65314);const u=new McEdGetPointWorldDrawObject;u.setDraw(c=>{t.setPoint2(c),u.drawCustomEntity(t)}),e.setBasePt(n),e.setUseBasePt(!0),e.setUserDraw(u),e.setMessage(`
- 指定第二点:`),e.setInputToucheType(MxType.InputToucheType.kGetEnd),e.go(c=>{if(c!=0)return void console.log(c);const y=e.value();t.setPoint2(y),MxFun.getCurrentDraw().addMxEntity(t)})}),t}MxDbRect.cmd="Mx_DrawRect",MxDbRect.draw=drawMxDbRect,addRegisterMxDbEntity(MxDbRect);const propertyDbKeys$5=["point1","point2","fontColor"];class MxDbAlignedDimension extends MxDbEntity{constructor(e){if(super(),this.point1=new THREE.Vector3,this.point2=new THREE.Vector3,e){const{points:l,fontColor:n}=e;l&&this.setPoints(l),n&&(this.fontColor=n)}}setPoints(e){const[l,n]=e;l&&(this.point1=l),n&&(this.point2=n)}getTypeName(){return"MxDbAlignedDimension"}getDirection(e,l,n){const u=new THREE.Vector3(e.x,e.y,0),c=new THREE.Vector3(1,0,0),y=e.angleTo(c);let b=-1;(y<7*Math.PI/18||y>10*Math.PI/18)&&l.x>n.x&&(b=1);const m=new THREE.Matrix4;return m.makeRotationZ(Math.PI/2*b),u.applyMatrix4(m),u}getDimText(){return new THREE.Vector3(this.point1.x-this.point2.x,this.point1.y-this.point2.y,0).length().toFixed(3)}worldDraw(e){if(e.setOpacity(this.opacity),e.getType()==McGiWorldDrawType$1.kWorldDraw||e.getType()==McGiWorldDrawType$1.kDynDragDraw){let Ve=function(rt,Ae){Array.isArray(rt)?rt.forEach(Te=>{Ve(Te,Ae)}):rt.opacity=Ae};const l=this.point1,n=this.point2;let u,c,y,b,m,O,N;const L=new THREE.Vector3(l.x-n.x,l.y-n.y,0),G=this.getDirection(L,l,n),q=new THREE.Matrix4;q.makeScale(.01,.01,.01);const J=new THREE.Vector3(G.x,G.y,0);J.applyMatrix4(q);const fe=new THREE.Vector3(l.x+J.x,l.y+J.y,0),ve=new THREE.Vector3(n.x+J.x,n.y+J.y,0),ne=this.getColor();O=MxThreeJS.createPoint(l,ne),N=MxThreeJS.createPoint(n,ne);const Ue=new THREE.Vector3(G.x,G.y,0),De=new THREE.Vector3(G.x,G.y,0);q.identity(),q.makeScale(.2,.2,0),Ue.applyMatrix4(q),q.identity(),q.makeScale(.02,.02,0),De.applyMatrix4(q),e.drawLine(fe.x+2*De.x,fe.y+2*De.y,ve.x+2*De.x,ve.y+2*De.y),u=MxThreeJS.createLine(new THREE.Vector3(fe.x+3*De.x,fe.y+3*De.y,0),new THREE.Vector3(l.x+.5*De.x,l.y+.5*De.y,0),ne),c=MxThreeJS.createLine(new THREE.Vector3(ve.x+3*De.x,ve.y+3*De.y,0),new THREE.Vector3(n.x+.5*De.x,n.y+.5*De.y,0),ne);{const rt=new THREE.Vector3(1,0,0);let Ae=L.angleTo(rt);const Te=new THREE.Vector3(G.x,G.y,0);Te.normalize();const Xe=l.distanceTo(n);L.y<0?Ae=Ae<Math.PI/2?2*Math.PI-Ae:Math.PI-Ae:Ae>Math.PI/2&&(Ae=Math.PI+Ae);const ie=e.getMxObject();ie&&(Ae-=ie.getViewAngle());const ue=this.getDimText();(y=MxThreeJS.creatTextSprite(ue,new THREE.Vector3(ve.x+L.x/2+Te.x*Xe/15,ve.y+L.y/2+Te.y*Xe/15,0),.07*Xe,Ae,this.fontColor||ne))!=null&&(y.material.opacity=this.opacity,e.drawEntity(y))}{q.identity(),q.makeScale(.08,.08,.08);const rt=new THREE.Matrix4;rt.makeRotationZ(17*Math.PI/18);let Ae=new THREE.Vector3(L.x,L.y,0);Ae.applyMatrix4(q),Ae.applyMatrix4(rt),rt.identity(),rt.makeRotationZ(17*-Math.PI/18);let Te=new THREE.Vector3(L.x,L.y,0);Te.applyMatrix4(q),Te.applyMatrix4(rt);const Xe=new Array;Xe.push(new THREE.Vector3(fe.x+2*De.x,fe.y+2*De.y,0),new THREE.Vector3(fe.x+2*De.x+Ae.x,fe.y+Ae.y+2*De.y,0),new THREE.Vector3(fe.x+2*De.x+Te.x,fe.y+Te.y+2*De.y,0)),b=MxThreeJS.createTriangle(Xe,ne),rt.identity(),rt.makeRotationZ(Math.PI/18),(Ae=new THREE.Vector3(L.x,L.y,0)).applyMatrix4(q),Ae.applyMatrix4(rt),rt.identity(),rt.makeRotationZ(-Math.PI/18),(Te=new THREE.Vector3(L.x,L.y,0)).applyMatrix4(q),Te.applyMatrix4(rt);const ie=new Array;ie.push(new THREE.Vector3(ve.x+2*De.x,ve.y+2*De.y,0),new THREE.Vector3(ve.x+Ae.x+2*De.x,ve.y+Ae.y+2*De.y,0),new THREE.Vector3(ve.x+Te.x+2*De.x,ve.y+Te.y+2*De.y,0)),m=MxThreeJS.createTriangle(ie,ne)}e.drawEntity(u),e.drawEntity(c),b&&(Ve(b.material,this.opacity),e.drawEntity(b)),m&&(Ve(m.material,this.opacity),e.drawEntity(m)),e.drawEntity(O),e.drawEntity(N)}else e.drawLine(this.point1,this.point2)}setPoint1(e){this.point1=e}setPoint2(e){this.point2=e}setColor(e){return lodash.isArray(e)?([this.color=this.color,this.fontColor=this.fontColor||this.color]=e,console.log("this.fontColor : ",this.fontColor)):this.color=e,this}getGripPoints(){let e=[];return e.push(this.point1),e.push(this.point2),e}moveGripPointsAt(e,l){return e==0?this.point1.add(l):(e=1)&&this.point2.add(l),!0}dwgIn(e){return this.onDwgIn(e),this.dwgInHelp(e,propertyDbKeys$5),!0}dwgOut(e){return this.onDwgOut(e),this.dwgOutHelp(e,propertyDbKeys$5),e}create(){return new MxDbAlignedDimension}}MxDbAlignedDimension.cmd="Mx_DimensionMeasurement",MxDbAlignedDimension.draw=drawMxDbAlignedDimension,addRegisterMxDbEntity(MxDbAlignedDimension);class MxDbHatch extends MxDbEntity{constructor(){super(...arguments),this.points=[]}worldDraw(e){e.getType()===McGiWorldDrawType$1.kWorldDraw?e.drawSolid(this.points):e.drawLines([...this.points,this.points[0]])}getTypeName(){return"MxDbHatch"}moveGripPointsAt(e,l){return e===0?this.points.forEach(n=>{n.add(l)}):this.points[e-1]&&this.points[e-1].add(l),!0}setPoints(e){this.points=e.map(l=>l.clone())}getGripPoints(){if(this.points.length>0){const{centerPoint:e}=computeBounding(this.points);return[e,...this.points]}return[]}dwgIn(e){this.onDwgIn(e);const l=e.points;return this.points=l.map(({x:n,y:u,z:c})=>new THREE.Vector3(n,u,c)),!0}dwgOut(e){return this.onDwgOut(e),e.points=this.points,e}}function drawMxDbArea(){const t=new MrxDbgUiPrPoint;t.setMessage(`
- 指定第一点:`),t.go(e=>{if(e!=0)return;const l=t.value();let n=new MxDbArea;n.addPoint(l);const u=new McEdGetPointWorldDrawObject;u.setDraw((c,y)=>{let b=n.clone();b.addPoint(c),u.drawCustomEntity(b)}),t.setUserDraw(u),t.setMessage(`
- 指定下一点:`),t.goWhile(c=>{if(c==0){const y=t.value();n.addPoint(y)}},c=>{n.isFill=!0,n.fillOpacity=.7,n.fillColor=6697540,MxFun.getCurrentDraw().addMxEntity(n)})})}addRegisterMxDbEntity(MxDbHatch);class MxDbArea extends MxDbEntity{constructor(){super(...arguments),this.points=[],this.isFill=!1,this.fillColor=6697540,this.fillOpacity=.7}getTypeName(){return"MxDbArea"}create(){return new MxDbArea}getDimText(){return McGeTool.calcArea(this.points).toFixed(2)}worldDraw(e){if(this.points.length<3)return void(this.points.length==2&&e.drawLine(this.points[0],this.points[1]));let l=this.points[0],n=l.clone(),u=l.clone(),c=this.points.length;for(let N=1;N<c;N++){let L=this.points[N];n.x>L.x&&(n.x=L.x),n.y>L.y&&(n.y=L.y),u.x<L.x&&(u.x=L.x),u.y<L.y&&(u.y=L.y),e.drawLine(l,L),l=L}e.drawLine(l,this.points[0]);let y=new THREE.Vector3(n.x+.5*(u.x-n.x),n.y+.5*(u.y-n.y));const b=e.getColor();let m=MxFun.screenCoordLong2Doc(20),O=MxThreeJS.creatTextSprite(this.getDimText(),y,m,0,b);if(O!=null&&e.drawEntity(O),e.getType()==McGiWorldDrawType$1.kWorldDraw&&this.isFill){e.setColor(this.fillColor),e.setOpacity(this.fillOpacity),e.setRenderOrder(e.getRenderOrder()-1);const N=new MxDbHatch;N.points=this.points,N.worldDraw(e)}}getGripPoints(){return this.points}moveGripPointsAt(e,l){return!(e>=this.points.length||(this.points[e].add(l),0))}dwgIn(e){this.onDwgIn(e);let l=e.points;return this.points=[],l.forEach(n=>{this.points.push(new THREE.Vector3(n.x,n.y,n.z))}),this.dwgInHelp(e,["isFill","fillColor","fillOpacity"]),!0}dwgOut(e){return this.onDwgOut(e),e.points=this.points,this.dwgOutHelp(e,["isFill","fillColor","fillOpacity"]),e}addPoint(e){this.points.push(e.clone())}getPoints(){return this.points}clearPoint(){this.points=[]}}async function drawMxDbLeadTag(){let e=await new MrxDbgUiPrPoint().go();if(!e)return;let l=prompt("请输入文字批注","批注");if(!l)return;const n=new MxDbLeadTag;n.point=e,n.text=l,MxFun.addToCurrentSpace(n)}MxDbArea.cmd="Mx_Area",MxDbArea.draw=drawMxDbArea,addRegisterMxDbEntity(MxDbArea);class MxDbLeadTag extends MxDbEntity{constructor(){super(...arguments),this.point=new THREE.Vector3,this.leadLen=88,this.text="",this.textHeight=24}getTypeName(){return"MxDbLeadTag"}createDots(e,l){const{x:n,y:u,z:c}=e,y=new THREE.Shape;y.arc(n,u,l.screenCoordLong2Doc(6),0,2*Math.PI,!0);const b=new THREE.Path;b.arc(n,u,l.screenCoordLong2Doc(3),0,2*Math.PI,!0),y.holes.push(b);const m=new THREE.ShapeGeometry(y),O=new THREE.MeshPhongMaterial({color:"#ff0000",transparent:!0}),N=new THREE.Shape;N.arc(n,u,l.screenCoordLong2Doc(3),0,2*Math.PI,!0);const L=new THREE.ShapeGeometry(N),G=new THREE.MeshPhongMaterial({color:"#e2da8f",transparent:!0}),q=new THREE.Mesh(m,O),J=new THREE.Mesh(L,G);return q.add(J),q}worldDraw(e){let l=e.getMxObject();const n=this.createDots(this.point,l);if(e.drawEntity(n),n.geometry.computeBoundingBox(),e.drawSelectLine(n.geometry.boundingBox.max,n.geometry.boundingBox.min),e.getType()===2)return;let u=e.getMxObject().screenCoordLong2Doc(this.leadLen),c=new THREE.Vector3(this.point.x+2*u,this.point.y+u,0);const y=c.x-u,b=new THREE.Vector3(y,c.y,c.z);e.setLineWidth(4),e.setColor(16770565),e.drawLines([this.point,b,c]);const m=e.getMxObject().screenCoordLong2Doc(this.textHeight),O=c.clone().setX(c.x);e.setColor(16744448);const N=MxThreeJS.creatTextSprite(this.text,O,m,0,e.getColor());if(N){const L=new THREE.Box3,G=new THREE.Vector3;L.expandByObject(N),L.getSize(G),N.position.setX(N.position.x+G.x/2);const q=e.getMxObject().screenCoordLong2Doc(5),J=L.min.clone().setX(L.min.x+G.x/2).setY(L.min.y-q),fe=L.max.clone().setX(L.max.x+G.x/2).setY(L.min.y+q);fe.setY(L.max.y+q);const ve=new THREE.Vector3(J.x,fe.y),ne=new THREE.Vector3(fe.x,J.y);e.setColor(16777215),e.setLineWidth(0),e.drawLine(J,ve),e.drawLine(fe,ne),e.drawLine(J,ne),e.drawLine(ve,fe);const Ue=q/2,De=[],Ve=[];De.push(new THREE.Vector3(ve.x+Ue,ve.y-q,ve.z),new THREE.Vector3(ve.x+Ue,ve.y-Ue,ve.z),new THREE.Vector3(ve.x+q,ve.y-Ue,ve.z)),Ve.push(new THREE.Vector3(ne.x-Ue,ne.y+q,ne.z),new THREE.Vector3(ne.x-Ue,ne.y+Ue,ne.z),new THREE.Vector3(ne.x-q,ne.y+Ue,ne.z)),e.drawLines(De),e.drawLines(Ve),e.setOpacity(.5),e.setColor(6697540),e.setRenderOrder(-100),e.drawSolid([J,ve,fe,ne]),e.setRenderOrder(100),e.drawEntity(N)}}getGripPoints(){return[this.point]}onViewChange(){return this.setNeedUpdateDisplay(),!0}moveGripPointsAt(e,l){return e===0&&this.point.add(l),!0}dwgIn(e){return this.onDwgIn(e),this.dwgInHelp(e,["point","text","textHeight","leadLen"]),!0}dwgOut(e){return this.onDwgOut(e),this.dwgOutHelp(e,["point","text","textHeight","leadLen"]),e}}function drawMxDbAnyLine(){const t=new MrxDbgUiPrPoint,e=MxFun.getCurrentDraw(),l=new McEdGetPointWorldDrawObject,n=new MxDbAnyLine;t.setUserDraw(l),t.setMessage(`
- 点击开始画线:`),t.go(u=>{u===MrxDbgUiPrBaseReturn$1.kOk&&(n.points.push(t.value()),l.setDraw(c=>{n.points.push(c.clone()),l.drawCustomEntity(n)})),t.setMessage(`
- 再次点击结束画线:`),t.go(c=>{c===MrxDbgUiPrBaseReturn$1.kOk&&e.addMxEntity(n)})})}MxDbLeadTag.cmd="Mx_LeadTag",MxDbLeadTag.draw=drawMxDbLeadTag,addRegisterMxDbEntity(MxDbLeadTag);const propertyDbKeys$4=["points"];class MxDbAnyLine extends MxDbEntity{constructor(){super(...arguments),this.points=[]}getTypeName(){return"MxDbAnyLine"}create(){return new MxDbAnyLine}worldDraw(e){let l=e.getMxObject();const n=new THREE.Box3().setFromPoints(this.points);let u=new THREE.Vector3;if(n.getCenter(u),e.drawLines(this.points),e.getType()===McGiWorldDrawType$1.kSelectDraw){const c=new THREE.Vector3;n.getSize(c),c.addScalar(l.screenCoordLong2Doc(20));const y=c.x/2,b=c.y/2,m={x:u.x-y,y:u.y-b},O={x:u.x+y,y:u.y-b},N={x:u.x+y,y:u.y+b},L={x:u.x-y,y:u.y+b};e.drawLine(O.x,O.y,N.x,N.y),e.drawLine(m.x,m.y,O.x,O.y),e.drawLine(N.x,N.y,L.x,L.y),e.drawLine(L.x,L.y,m.x,m.y)}}setPoints(e){return this.points=e,this}getCenter(){const e=new THREE.Geometry;e.vertices=this.points;const l=new THREE.Vector3;return e.computeBoundingBox(),e.boundingBox.getCenter(l),l}getGripPoints(){return[this.getCenter()]}moveGripPointsAt(e,l){return e===0&&this.points.forEach(n=>{n.add(l)}),!0}dwgIn(e){return this.onDwgIn(e),this.dwgInHelp(e,propertyDbKeys$4),!0}dwgOut(e){return this.onDwgOut(e),this.dwgOutHelp(e,propertyDbKeys$4),e}}function drawMxDbCloudLine(){const t=new MrxDbgUiPrPoint,e=MxFun.getCurrentDraw(),l=new McEdGetPointWorldDrawObject;t.setMessage(`
- 点击开启绘制云线:`),t.go(()=>{const n=MxFun.screenCoordLong2Doc(16);let u=t.value();const c=new MxDbCloudLine;c.setRadius(n),c.addPoint(u),l.setDraw(y=>{u.distanceTo(y)>n&&(u=y.clone(),c.addPoint(y,!0)),l.drawCustomEntity(c)}),t.setUserDraw(l),t.setMessage(`
- 再次点击结束绘制云线:`),t.go(()=>{e.addMxEntity(c)})})}MxDbAnyLine.cmd="Mx_AnyLine",MxDbAnyLine.draw=drawMxDbAnyLine,addRegisterMxDbEntity(MxDbAnyLine);const propertyDbKeys$3=["points","radius"];class MxDbCloudLine extends MxDbEntity{constructor(){super(),this.points=[],this.radius=16,this.cachePoint=null,this.use_smallcoord_display=!0}getTypeName(){return"MxDbCloudLine"}create(){return new MxDbCloudLine}setRadius(e){this.radius=e}getRadius(){return this.radius}getCachePoint(){return this.cachePoint}clacNewArcDiameterPoint(e){if(this.points.length==0)return e;let l=this.points[this.points.length-1];const n=2*this.radius,u=l.distanceTo(e);if(u<n)return null;const c=n*(e.x-l.x)/u+l.x,y=n*(e.y-l.y)/u+l.y;return new THREE.Vector3(c,y,l.z)}createCloudArcCurvePoints(e,l,n){const u=new THREE.Vector3((e.x+l.x)/2,(e.y+l.y)/2,0);n||(n=u.distanceTo(e));const{startAngle:c,endAngle:y}=function(b,m,O){const N=2*Math.PI/360;return{startAngle:180*Math.atan2(m.y-b.y,m.x-b.x)/Math.PI*N,endAngle:180*Math.atan2(O.y-b.y,O.x-b.x)/Math.PI*N}}(u,e,l);return new THREE.ArcCurve(u.x,u.y,n,c,y,!0).getPoints(10)}addPoint(e,l){let n=this.clacNewArcDiameterPoint(e);n&&(this.points.push(n),this.cachePoint=null,l&&(this.cachePoint=this.reCalculateDrawGeometryPoint()))}addLine(e,l){this.addPoint(e);const n=2*this.radius;let u=this.points[this.points.length-1],c=u.distanceTo(l);const y=Math.round(c/n);for(let b=0;b<y;b++){c=u.distanceTo(l);const m=n*(l.x-u.x)/c+u.x,O=n*(l.y-u.y)/c+u.y;let N=new THREE.Vector3(m,O,l.z);this.addPoint(N),u=N}return this.addPoint(l),this.points[this.points.length-1]}reCalculateDrawGeometryPoint(){if(this.points.length<2)return null;let e=this.points[0],l=this.points.length,n=[];for(let u=1;u<l;u++){let c=this.points[u];this.createCloudArcCurvePoints(e,c).forEach(y=>{n.push(new THREE.Vector3(y.x,y.y,0))}),e=c}return n}worldDraw(e){if(this.cachePoint||(this.cachePoint=this.reCalculateDrawGeometryPoint()),!this.cachePoint)return;let l=e.getMxObject();if(e.getType()===McGiWorldDrawType$1.kSelectDraw){let n=new THREE.Geometry;this.cachePoint.forEach(G=>{n.vertices.push(new THREE.Vector3(G.x,G.y,0))}),n.computeBoundingBox();const u=new THREE.Vector3;n.boundingBox.getSize(u);let c=new THREE.Vector3;n.boundingBox.getCenter(c);const y=u.x/2,b=u.y/2,m={x:c.x-y,y:c.y-b},O={x:c.x+y,y:c.y-b},N={x:c.x+y,y:c.y+b},L={x:c.x-y,y:c.y+b};e.drawLine(this.toSmallcoord2(l,m.x,m.y),this.toSmallcoord2(l,O.x,O.y)),e.drawLine(this.toSmallcoord2(l,O.x,O.y),this.toSmallcoord2(l,N.x,N.y)),e.drawLine(this.toSmallcoord2(l,N.x,N.y),this.toSmallcoord2(l,L.x,L.y)),e.drawLine(this.toSmallcoord2(l,L.x,L.y),this.toSmallcoord2(l,m.x,m.y))}else{let n=[];this.cachePoint.forEach(u=>{n.push(this.toSmallcoord(l,u))}),e.drawLines(n)}}getCenter(){const e=new THREE.Geometry;e.vertices=this.points;let l=new THREE.Vector3;return e.computeBoundingBox(),e.boundingBox.getCenter(l),l}getGripPoints(){return[this.getCenter()]}moveGripPointsAt(e,l){return this.points.forEach(n=>{n.add(l)}),this.cachePoint=null,!0}dwgIn(e){return this.onDwgIn(e),this.dwgInHelp(e,propertyDbKeys$3),this.cachePoint=null,!0}dwgOut(e){return this.onDwgOut(e),this.dwgOutHelp(e,propertyDbKeys$3),e.type===MxType.MxCloneType.kSaveDwgClone&&this.dwgOutHelp(e,["cachePoint"]),e}}function drawMxDbRegularPolygon(){const t=new MrxDbgUiPrPoint,e=MxFun.getCurrentDraw(),l=new McEdGetPointWorldDrawObject,n=new MxDbRegularPolygon;t.setMessage(`
- 点击开始绘制多边形:`),t.go(()=>{let u=prompt("请输入多边形的边数","8");u&&(n.sidesNumber=Number(u),n.centerPoint=t.value(),t.setUserDraw(l),l.setDraw(c=>{n.otherPoint=c,l.drawCustomEntity(n)}),t.setMessage(`
- 再次点击结束绘制多边形:`),t.go(()=>{e.addMxEntity(n)}))})}MxDbCloudLine.isRegister=!1,MxDbCloudLine.cmd="Mx_CloudLine",MxDbCloudLine.draw=drawMxDbCloudLine,addRegisterMxDbEntity(MxDbCloudLine);class MxDbRegularPolygon extends MxDbShape{getTypeName(){return"MxDbRegularPolygon"}constructor(){super(),this.centerPoint=new THREE.Vector3,this.otherPoint=new THREE.Vector3,this.sidesNumber=5,this._propertyDbKeys=[...this._propertyDbKeys,"centerPoint","otherPoint","sidesNumber"]}worldDraw(e){const l=computeRegularPolygonVertices$1(this.centerPoint,this.otherPoint,this.sidesNumber);this.closed=!1,l.push(l[0]),this._draw(e,l),this._drawStoreLine(e,l)}getGripPoints(){return[this.centerPoint,this.otherPoint]}moveGripPointsAt(e,l){return e===0?(this.centerPoint.add(l),this.otherPoint.add(l)):e===1&&this.otherPoint.add(l),!0}}function drawMxDbLeadComment(){const t=new MrxDbgUiPrPoint;t.setMessage(`
- 指定第一点:`),t.go(e=>{if(e!=0)return;const l=t.value();let n=new MxDbLeadComment;n.point1=l.clone(),n.textHeight=MxFun.screenCoordLong2Doc(50);let u=prompt("请输入文字批注","批注");if(!u)return;n.text=u,n.textWidth=MxFun.screenCoordLong2Doc(10*u.length),n.fixedSize=!0,n.fixedSize&&(n.textHeight=50,n.textWidth=50*u.length);const c=new McEdGetPointWorldDrawObject;c.setDraw((y,b)=>{n.point2=y,b.drawCustomEntity(n)}),t.setBasePt(l),t.setUseBasePt(!0),t.setUserDraw(c),t.setMessage(`
- 指定第二点:`),t.go(y=>{if(y!=0)return void console.log(y);const b=t.value();n.point2=b,MxFun.addToCurrentSpace(n)})})}MxDbRegularPolygon.cmd="Mx_RegularPolygon",MxDbRegularPolygon.draw=drawMxDbRegularPolygon,addRegisterMxDbEntity(MxDbRegularPolygon);class MxDbLeadComment extends MxDbEntity{constructor(){super(),this.point1=new THREE.Vector3,this.point2=new THREE.Vector3,this.text="",this.textHeight=20,this.textWidth=0,this.fixedSize=!1,this.use_smallcoord_display=!0}getTypeName(){return"MxDbLeadComment"}create(){return new MxDbLeadComment}worldDraw(e){let l=e.getMxObject(),n=this.toSmallcoord(l,this.point1),u=this.toSmallcoord(l,this.point2);if(e.drawLine(n,u),this.text.length>0){const c=new THREE.Vector3;let y=this.textHeight,b=this.textWidth;this.fixedSize&&(y=l.screenCoordLong2Doc(y),b=l.screenCoordLong2Doc(b));let m=MxThreeJS.clacTextSpriteSize(this.text,y,b);c.x=u.x+.5*m.textwidth,c.y=u.y+.5*m.allTextHeight,e.drawText(this.text,y,0,c,b);const O=new THREE.Vector3;O.x=u.x+m.textwidth,O.y=u.y,e.drawLine(O,u)}}getGripPoints(){let e=[];return e.push(this.point1),e.push(this.point2),e}moveGripPointsAt(e,l){return e==0?this.point1.add(l):e==1&&this.point2.add(l),!0}dwgIn(e){return this.onDwgIn(e),this.point1.copy(e.point1),this.point2.copy(e.point2),this.text=e.text.substr(0),this.textHeight=e.textHeight,e.textWidth&&(this.textWidth=e.textWidth),this.fixedSize=e.fixedSize,!0}dwgOut(e){return this.onDwgOut(e),e.point1=this.point1,e.point2=this.point2,e.textHeight=this.textHeight,e.text=this.text,e.textWidth=this.textWidth,e.fixedSize=this.fixedSize,e}onViewChange(){return!!this.fixedSize&&(this.setNeedUpdateDisplay(!1),!0)}}function drawMxDbRectBoxLeadComment(){const t=new MrxDbgUiPrPoint,e=MxFun.getCurrentDraw(),l=new McEdGetPointWorldDrawObject,n=new MxDbRectBoxLeadComment;n.setLineWidth(3),n.setLineWidthByPixels(!0),t.setMessage(`
- 云线框起始点:`),t.go(u=>{n.radius=MxFun.screenCoordLong2Doc(8),u==MrxDbgUiPrBaseReturn$1.kOk&&(n.point1=t.value(),l.setDraw(c=>{n.point2=c,l.drawCustomEntity(n)}),t.setUserDraw(l),t.setMessage(`
- 云线框结束点:`),t.go(c=>{if(c!=MrxDbgUiPrBaseReturn$1.kOk)return;n.point2=t.value(),l.setDraw(b=>{n.point3=b,l.drawCustomEntity(n)});let y=prompt("请输入文字批注","批注");y||(y="默认批注文字"),n.text=y,n.textWidth=MxFun.screenCoordLong2Doc(10*y.length),n.textHeight=MxFun.screenCoordLong2Doc(5*y.length),n.fixedSize=!0,n.fixedSize&&(n.textHeight=20,n.textWidth=20*y.length),t.setMessage(`
- 审图标注点:`),t.go(b=>{b==MrxDbgUiPrBaseReturn$1.kOk&&(n.point3=t.value(),e.addMxEntity(n))})}))})}MxDbLeadComment.cmd="Mx_Comment",MxDbLeadComment.draw=drawMxDbLeadComment,addRegisterMxDbEntity(MxDbLeadComment);class MxDbRectBoxLeadComment extends MxDbEntity{constructor(){super(),this.point1=new THREE.Vector3,this.point2=new THREE.Vector3,this.point3=new THREE.Vector3,this.text="",this.textHeight=20,this.radius=16,this.textWidth=0,this.fixedSize=!1,this.use_smallcoord_display=!0}getTypeName(){return"MxDbRectBoxLeadComment"}create(){return new MxDbRectBoxLeadComment}getCloudLine(){let e=new MxDbCloudLine;e.setRadius(this.radius);let l=this.point1.clone(),n=this.point2.clone();if(l.x>n.x){let m=l.x;l.x=n.x,n.x=m}if(l.y>n.y){let m=l.y;l.y=n.y,n.y=m}let u=new THREE.Vector3(l.x,n.y,l.z);u=e.addLine(l,u),n=new THREE.Vector3(n.x,u.y,n.z),n=e.addLine(u,n);let c=new THREE.Vector3(n.x,l.y,l.z);c=e.addLine(n,c);let y=l=e.addLine(c,l),b=l.distanceTo(this.point3);return b>u.distanceTo(this.point3)&&(y=u,b=u.distanceTo(this.point3)),b>n.distanceTo(this.point3)&&(y=n,b=n.distanceTo(this.point3)),b>c.distanceTo(this.point3)&&(y=c,b=c.distanceTo(this.point3)),{cloudLine:e,pt1:l,pt2:u,pt3:n,pt4:c,leadPt:y}}worldDraw(e){let l=this.getCloudLine(),n=l.cloudLine;if(n.setUseSmallcoordDisplay(this.use_smallcoord_display),n.worldDraw(e),this.text.length>0){let u=l.leadPt,c=new MxDbLeadComment;c.setUseSmallcoordDisplay(this.use_smallcoord_display),c.point1=u,c.point2=this.point3,c.text=this.text,c.textHeight=this.textHeight,c.textWidth=this.textWidth,c.fixedSize=this.fixedSize,c.worldDraw(e)}}getGripPoints(){let e=[];return e.push(this.point1),e.push(this.point2),e.push(this.point3),e}moveGripPointsAt(e,l){return e==0?this.point1.add(l):e==1?this.point2.add(l):e==2&&this.point3.add(l),!0}dwgIn(e){return this.onDwgIn(e),this.point1.copy(e.point1),this.point2.copy(e.point2),this.point3.copy(e.point3),this.text=e.text.substr(0),this.textHeight=e.textHeight,this.radius=e.radius,e.textWidth&&(this.textWidth=e.textWidth),this.fixedSize=e.fixedSize,!0}dwgOut(e){if(this.onDwgOut(e),e.point1=this.point1,e.point2=this.point2,e.point3=this.point3,e.textHeight=this.textHeight,e.text=this.text,e.radius=this.radius,e.textWidth=this.textWidth,e.fixedSize=this.fixedSize,e.type===MxType.MxCloneType.kSaveDwgClone){let l=this.getCloudLine(),n=l.cloudLine.reCalculateDrawGeometryPoint();e.cachePoint=n||[],e.leadPt=l.leadPt}return e}onViewChange(){return!!this.fixedSize&&(this.setNeedUpdateDisplay(!1),!0)}}function drawMxDbEllipse$1(){const t=new MrxDbgUiPrPoint,e=MxFun.getCurrentDraw(),l=new McEdGetPointWorldDrawObject,n=new MxDbEllipse;t.setMessage(`
- 点击开始绘制椭圆:`),t.go(()=>{n.point1=t.value(),l.setDraw(u=>{n.point2=u,l.drawCustomEntity(n)}),t.setUserDraw(l),t.setMessage(`
- 再次点击结束绘制椭圆:`),t.go(()=>{e.addMxEntity(n)})})}MxDbRectBoxLeadComment.cmd="Mx_CheckDraw",MxDbRectBoxLeadComment.draw=drawMxDbRectBoxLeadComment,addRegisterMxDbEntity(MxDbRectBoxLeadComment);class MxDbEllipse extends MxDbEllipseShape{constructor(){super(),this.point1=new THREE.Vector3,this.point2=new THREE.Vector3,this.isClosedToCenter=!1,this.closed=!1,this._propertyDbKeys=[...this._propertyDbKeys,"point1","point2"]}getTypeName(){return"MxDbEllipse"}create(){return new MxDbEllipse}setPoint1(e){return this.point1=e,this}setPoint2(e){return this.point2=e,this}worldDraw(e){const{point1:l,point2:n}=this,u=l.clone().set(n.x,l.y,n.z),c=n.clone().set(l.x,n.y,l.z);this.xRadius=l.distanceTo(u)/2,this.yRadius=l.distanceTo(c)/2;const y=l.x>n.x,b=l.y>n.y,m=y?l.x-this.xRadius:l.x+this.xRadius,O=b?l.y-this.yRadius:l.y+this.yRadius;this.center=new THREE.Vector3(m,O,0),this.drawEllipseShape(e),e.getType()===McGiWorldDrawType$1.kSelectDraw&&e.drawLines([l,new THREE.Vector3(l.x,n.y),n,new THREE.Vector3(n.x,l.y),l])}getGripPoints(){let e=new THREE.Vector3(.5*(this.point2.x+this.point1.x),.5*(this.point2.y+this.point1.y),0);return[this.point1,this.point2,e]}moveGripPointsAt(e,l){return e===0?this.point1.add(l):e===1?this.point2.add(l):e===2&&(this.point1.add(l),this.point2.add(l)),!0}}async function drawMxDbText(){const t=new MrxDbgUiPrPoint;t.setMessage(`
- 点取文字插入点:`);let e=await t.go();if(e==null)return;let l=prompt("请输入文字");if(!l)return;let n=new MxDbText;n.position=e,n.height=MxFun.screenCoordLong2Doc(50),n.text=l,MxFun.addToCurrentSpace(n)}let _SpriteText;function getSpriteTextColor(t){return t?t instanceof THREE.Color?t.getStyle():typeof t=="number"?new THREE.Color(t).getStyle():t:"#fff"}function toCSSFont(t,e,l,n,u){let c=document.createElement("span");return c.style.font="1px serif",c.style.fontFamily=t,c.style.fontSize=`${e}px`,c.style.fontStyle=l,c.style.fontVariant=n,c.style.fontWeight=u,c.style.font}function getSpriteTextClass(){if(!_SpriteText){class t extends THREE.Sprite{constructor(l){super(new THREE.SpriteMaterial);const{text:n,textHeight:u,color:c,backgroundColor:y,padding:b,borderWidth:m,borderRadius:O,borderColor:N,strokeWidth:L,strokeColor:G,fontFace:q,fontSize:J,fontWeight:fe,textAlign:ve,textShadowBlur:ne,textShadowColor:Ue,textShadowOffsetX:De,textShadowOffsetY:Ve,angle:rt,scale:Ae,underline:Te,fontStyle:Xe,fontVariant:ie}=l||{};this._text=`${n}`,this._textHeight=u||10,this._color=c,this._backgroundColor=y,this._padding=b||0,this._borderWidth=m||0,this._borderRadius=O||0,this._borderColor=N||"white",this._strokeWidth=L||0,this._strokeColor=G||"white",this._fontFace=q||"Arial",this._fontSize=J||90,this._fontWeight=fe?.toString()||"normal",this._textAlign=ve||"start",this._fontStyle=Xe||"normal",this._fontVariant=ie||"normal",this._textShadowBlur=ne||0,this._textShadowColor=Ue,this._textShadowOffsetX=De||0,this._textShadowOffsetY=Ve||0,this._angle=rt||0,this._textScale=Ae||1,this._underline=Te||!1,this._canvas=document.createElement("canvas"),this._genCanvas()}get text(){return this._text}set text(l){this._text=l,this._genCanvas()}get textHeight(){return this._textHeight}set textHeight(l){this._textHeight=l,this._genCanvas()}get color(){return this._color}set color(l){this._color=l,this._genCanvas()}get backgroundColor(){return this._backgroundColor}set backgroundColor(l){this._backgroundColor=l,this._genCanvas()}get padding(){return this._padding}set padding(l){this._padding=l,this._genCanvas()}get borderWidth(){return this._borderWidth}set borderWidth(l){this._borderWidth=l,this._genCanvas()}get borderRadius(){return this._borderRadius}set borderRadius(l){this._borderRadius=l,this._genCanvas()}get borderColor(){return this._borderColor}set borderColor(l){this._borderColor=l,this._genCanvas()}get fontFace(){return this._fontFace}set fontFace(l){this._fontFace=l,this._genCanvas()}get fontSize(){return this._fontSize}set fontSize(l){this._fontSize=l,this._genCanvas()}get fontWeight(){return this._fontWeight}set fontWeight(l){this._fontWeight=l,this._genCanvas()}get strokeWidth(){return this._strokeWidth}set strokeWidth(l){this._strokeWidth=l,this._genCanvas()}get strokeColor(){return this._strokeColor}set strokeColor(l){this._strokeColor=l,this._genCanvas()}get textAlign(){return this._textAlign}set textAlign(l){this._textAlign=l,this._genCanvas()}get textShadowBlur(){return this._textShadowBlur}set textShadowBlur(l){this._textShadowBlur=l,this._genCanvas()}get textShadowColor(){return this._textShadowColor}set textShadowColor(l){this._textShadowColor=l,this._genCanvas()}get textShadowOffsetX(){return this._textShadowOffsetX}set textShadowOffsetX(l){this._textShadowOffsetX=l,this._genCanvas()}get textShadowOffsetY(){return this._textShadowOffsetY}set textShadowOffsetY(l){this._textShadowOffsetY=l,this._genCanvas()}get angle(){return this._angle}set angle(l){this._angle=l,this._genCanvas()}get textScale(){return this._textScale}set textScale(l){this._textScale=l,this._genCanvas()}get underline(){return this._underline}set underline(l){this._underline=l,this._genCanvas()}get fontStyle(){return this._fontStyle}set fontStyle(l){this._fontStyle=l,this._genCanvas()}get fontVariant(){return this._fontVariant}set fontVariant(l){this._fontVariant=l,this._genCanvas()}_genCanvas(){const l=this._canvas,n=l.getContext("2d"),u=Array.isArray(this.borderWidth)?this.borderWidth:[this.borderWidth,this.borderWidth],c=u.map(Ve=>Ve*this.fontSize*.1),y=(Array.isArray(this.borderRadius)?this.borderRadius:[this.borderRadius,this.borderRadius,this.borderRadius,this.borderRadius]).map(Ve=>Ve*this.fontSize*.1),b=Array.isArray(this.padding)?this.padding:[this.padding,this.padding],m=b.map(Ve=>Ve*this.fontSize*.1),O=this.text.split(`
- `),N=this.font;n.font=N;const L=Math.max(...O.map(Ve=>n.measureText(Ve).width)),G=4*this.strokeWidth+(this.underline?this.fontSize/15*4:this.fontSize/15),q=(this.fontSize+G)*O.length;if(l.width=L+2*c[0]+2*m[0],l.height=q+2*c[1]+2*m[1],this.borderWidth){if(n.strokeStyle=getSpriteTextColor(this.borderColor),c[0]){const Ve=c[0]/2;n.lineWidth=c[0],n.beginPath(),n.moveTo(Ve,y[0]),n.lineTo(Ve,l.height-y[3]),n.moveTo(l.width-Ve,y[1]),n.lineTo(l.width-Ve,l.height-y[2]),n.stroke()}if(c[1]){const Ve=c[1]/2;n.lineWidth=c[1],n.beginPath(),n.moveTo(Math.max(c[0],y[0]),Ve),n.lineTo(l.width-Math.max(c[0],y[1]),Ve),n.moveTo(Math.max(c[0],y[3]),l.height-Ve),n.lineTo(l.width-Math.max(c[0],y[2]),l.height-Ve),n.stroke()}if(this.borderRadius){const Ve=Math.max(...c),rt=Ve/2;n.lineWidth=Ve,n.beginPath(),[!!y[0]&&[y[0],rt,rt,y[0]],!!y[1]&&[l.width-y[1],l.width-rt,rt,y[1]],!!y[2]&&[l.width-y[2],l.width-rt,l.height-rt,l.height-y[2]],!!y[3]&&[y[3],rt,l.height-rt,l.height-y[3]]].filter(Ae=>Ae).forEach(Ae=>{const[Te,Xe,ie,ue]=Ae;n.moveTo(Te,ie),n.quadraticCurveTo(Xe,ie,Xe,ue)}),n.stroke()}}this.backgroundColor&&(n.fillStyle=getSpriteTextColor(this.backgroundColor),this.borderRadius?(n.beginPath(),n.moveTo(c[0],y[0]),[[c[0],y[0],l.width-y[1],c[1],c[1],c[1]],[l.width-c[0],l.width-c[0],l.width-c[0],c[1],y[1],l.height-y[2]],[l.width-c[0],l.width-y[2],y[3],l.height-c[1],l.height-c[1],l.height-c[1]],[c[0],c[0],c[0],l.height-c[1],l.height-y[3],y[0]]].forEach(([Ve,rt,Ae,Te,Xe,ie])=>{n.quadraticCurveTo(Ve,Te,rt,Xe),n.lineTo(Ae,ie)}),n.closePath(),n.fill()):n.fillRect(c[0],c[1],l.width-2*c[0],l.height-2*c[1])),n.translate(c[0],c[1]),n.translate(m[0],m[1]),n.font=N,n.fillStyle=getSpriteTextColor(this.color),n.textBaseline="bottom",n.shadowBlur=this.textShadowBlur,n.shadowColor=new THREE.Color(this.textShadowColor).getStyle(),n.shadowOffsetX=this.textShadowOffsetX,n.shadowOffsetY=this.textShadowOffsetY;const J=this.strokeWidth>0;J&&(n.lineWidth=this.strokeWidth*this.fontSize/10,n.strokeStyle=getSpriteTextColor(this.strokeColor));const fe=this.textAlign==="center",ve=this.textAlign==="start"||this.textAlign==="left";O.forEach(async(Ve,rt)=>{let Ae=fe?2:1;const Te=n.measureText(Ve).width,Xe=ve?0:(L-Te)/Ae,ie=(rt+1)*(this.fontSize+G);J&&n.strokeText(Ve,Xe,ie),n.fillText(Ve,Xe,ie),this.underline&&n.fillRect(Xe,l.height-this.fontSize/25,Te,this.fontSize/25)}),this.material.map&&this.material.map.dispose();const ne=this.material.map=new THREE.Texture(l);ne.minFilter=THREE.LinearFilter,ne.needsUpdate=!0;const Ue=this.textHeight*O.length+2*u[1]+2*b[1],De=Ue*l.width/l.height;this.scale.set(De,Ue,this.scale.z),this.material.rotation=this.angle,this.scale.applyMatrix4(new THREE.Matrix4().makeScale(this.textScale,this.textScale,1))}clone(){return new this.constructor(this.text,this.textHeight,this.color).copy(THREE.Sprite.prototype.clone.call(this))}copy(l){return THREE.Sprite.prototype.copy.call(this,l),this.color=l.color,this.backgroundColor=l.backgroundColor,this.padding=l.padding,this.borderWidth=l.borderWidth,this.borderColor=l.borderColor,this.fontFace=l.fontFace,this.fontSize=l.fontSize,this.fontWeight=l.fontWeight,this.strokeWidth=l.strokeWidth,this.strokeColor=l.strokeColor,this.textAlign=l.textAlign,this.textShadowBlur=l.textShadowBlur,this.textShadowColor=l.textShadowColor,this.textShadowOffsetX=l.textShadowOffsetX,this.textShadowOffsetY=l.textShadowOffsetY,this.angle=l.angle,this.textScale=l.textScale,this}get font(){return toCSSFont(this.fontFace,this.fontSize,this.fontStyle,this.fontVariant,this.fontWeight)}checkFontFace(){try{const{fontFace:l}=this;return document.fonts.check(l)}catch{}return!0}async loadFontFace(){try{const{fontFace:l}=this;await document.fonts.load(l)}catch{}}dispose(){var l;(l=this.material.map)===null||l===void 0||l.dispose(),this.material.dispose(),this.geometry.dispose(),this.dispatchEvent({type:"dispose"})}}_SpriteText=t}return _SpriteText}MxDbEllipse.cmd="Mx_Ellipse",MxDbEllipse.draw=drawMxDbEllipse$1,addRegisterMxDbEntity(MxDbEllipse);const propertyDbKeys$2=["text","position","height","backgroundColor","padding","borderWidth","borderRadius","borderColor","fontFace","fontSize","fontWeight","strokeWidth","strokeColor","angle","textAlign","textShadowBlur","textShadowColor","textShadowOffsetX","textShadowOffsetY","scale","underline"];class MxDbText extends MxDbEntity{constructor(){super(...arguments),this.position=new THREE.Vector3,this._text="",this._height=16,this._angle=0,this._scale=1,this._underline=!1}setPosition(e){return this.position=e,this}get text(){return this.spriteText?this.spriteText.text:this._text}set text(e){this.spriteText?this.spriteText.text=e:this._text=e}setText(e){return this.text=e,this}get height(){return this.spriteText?this.spriteText.textHeight:this._height}set height(e){this.spriteText?this.spriteText.textHeight=e:this._height=e}setHeight(e){return this.height=e,this}get backgroundColor(){return this.spriteText?this.spriteText.backgroundColor:this._backgroundColor}set backgroundColor(e){this.spriteText?this.spriteText.backgroundColor=e:this._backgroundColor=e}setBackgroundColor(e){return this.backgroundColor=e,this}get padding(){return this.spriteText?this.spriteText.padding:this._padding}set padding(e){this.spriteText?this.spriteText.padding=e:this._padding=e}setPadding(e){return this.padding=e,this}get borderWidth(){return this.spriteText?this.spriteText.borderWidth:this._borderWidth}set borderWidth(e){this.spriteText?this.spriteText.borderWidth=e:this._borderWidth=e}setBorderWidth(e){return this.borderWidth=e,this}get borderRadius(){return this.spriteText?this.spriteText.borderRadius:this._borderRadius}set borderRadius(e){this.spriteText?this.spriteText.borderRadius=e:this._borderRadius=e}setBorderRadius(e){return this.borderRadius=e,this}get borderColor(){return this.spriteText?this.spriteText.borderColor:this._borderColor}set borderColor(e){this.spriteText?this.spriteText.borderColor=e:this._borderColor=e}setBorderColor(e){return this.borderColor=e,this}get fontFace(){return this.spriteText?this.spriteText.fontFace:this._fontFace}set fontFace(e){this.spriteText?this.spriteText.fontFace=e:this._fontFace=e}setFontFace(e){return this.fontFace=e,this}get fontSize(){return this.spriteText?this.spriteText.fontSize:this._fontSize}set fontSize(e){this.spriteText?this.spriteText.fontSize=e:this._fontSize=e}setFontSize(e){return this.fontSize=e,this}get fontWeight(){return this.spriteText?this.spriteText.fontWeight:this._fontWeight}set fontWeight(e){this.spriteText?this.spriteText.fontWeight=e:this._fontWeight=e}setFontWeight(e){return this.fontWeight=e,this}get strokeWidth(){return this.spriteText?this.spriteText.strokeWidth:this._strokeWidth}set strokeWidth(e){this.spriteText?this.spriteText.strokeWidth=e:this._strokeWidth=e}setStrokeWidth(e){return this.strokeWidth=e,this}get strokeColor(){return this.spriteText?this.spriteText.strokeColor:this._strokeColor}set strokeColor(e){this.spriteText?this.spriteText.strokeColor=e:this._strokeColor=e}setStrokeColor(e){return this.strokeColor=e,this}get textAlign(){return this.spriteText?this.spriteText.textAlign:this._textAlign}set textAlign(e){this.spriteText?this.spriteText.textAlign=e:this._textAlign=e}setTextAlign(e){return this.textAlign=e,this}get textShadowBlur(){return this.spriteText?this.spriteText.textShadowBlur:this._textShadowBlur}set textShadowBlur(e){this.spriteText?this.spriteText.textShadowBlur=e:this._textShadowBlur=e}setTextShadowBlur(e){return this.textShadowBlur=e,this}get textShadowColor(){return this.spriteText?this.spriteText.textShadowColor:this._textShadowColor}set textShadowColor(e){this.spriteText?this.spriteText.textShadowColor=e:this._textShadowColor=e}setTextShadowColor(e){return this.textShadowColor=e,this}get textShadowOffsetX(){return this.spriteText?this.spriteText.textShadowOffsetX:this._textShadowOffsetX}set textShadowOffsetX(e){this.spriteText?this.spriteText.textShadowOffsetX=e:this._textShadowOffsetX=e}setTextShadowOffsetX(e){return this.textShadowOffsetX=e,this}get textShadowOffsetY(){return this.spriteText?this.spriteText.textShadowOffsetY:this._textShadowOffsetY}set textShadowOffsetY(e){this.spriteText?this.spriteText.textShadowOffsetY=e:this._textShadowOffsetY=e}setTextShadowOffsetY(e){return this.textShadowOffsetY=e,this}get angle(){return this.spriteText?this.spriteText.angle:this._angle}set angle(e){this.spriteText?this.spriteText.angle=e:this._angle=e}setAngle(e){return this.angle=e,this}get scale(){return this.spriteText?this.spriteText.textScale:this._scale}set scale(e){this.spriteText?this.spriteText.textScale=e:this._scale=e}setScale(e){return this.scale=e,this}get underline(){return this.spriteText?this.spriteText.underline:this._underline}set underline(e){this.spriteText?this.spriteText.underline=e:this._underline=e}setUnderline(e){this.underline=e}getTypeName(){return"MxDbText"}worldDraw(e){if(this.text.length>0){e.getType()!==McGiWorldDrawType$1.kWorldDraw||this.spriteText||this.createSpriteText(),this.color!==this.spriteText.color&&(this.spriteText.color=this.color),this.spriteText.material.setValues({opacity:this.opacity,visible:this.visible});const{x:l,y:n,z:u}=this.position;this.spriteText.position.set(l,n,u),e.drawEntity(this.spriteText)}}createSpriteText(){const e=getSpriteTextClass(),{text:l,height:n,color:u,backgroundColor:c,padding:y,borderWidth:b,borderRadius:m,borderColor:O,strokeWidth:N,strokeColor:L,fontFace:G,fontSize:q,fontWeight:J,textAlign:fe,textShadowBlur:ve,textShadowColor:ne,textShadowOffsetX:Ue,textShadowOffsetY:De,angle:Ve,scale:rt,underline:Ae}=this;this.spriteText=new e({text:l,textHeight:n,color:u,backgroundColor:c,padding:y,borderWidth:b,borderRadius:m,borderColor:O,strokeWidth:N,strokeColor:L,fontFace:G,fontSize:q,fontWeight:J,textAlign:fe,textShadowBlur:ve,textShadowColor:ne,textShadowOffsetX:Ue,textShadowOffsetY:De,angle:Ve,scale:rt,underline:Ae})}getGripPoints(){return[this.position]}moveGripPointsAt(e,l){return e===0&&this.position.add(l),!0}create(){return new MxDbText}dwgIn(e){var l,n;return this.onDwgIn(e),this.dwgInHelp(e,propertyDbKeys$2),typeof e.path=="string"&&(e.path=JSON.parse(e.path)),((n=(l=e?.path)===null||l===void 0?void 0:l.metadata)===null||n===void 0?void 0:n.generator)==="Curve.toJSON"&&(e.path=new THREE.Path().fromJSON(e.path)),e.type===MxType.MxCloneType.kMxFileClone||e.type===MxType.MxCloneType.kSaveDwgClone?this.createSpriteText():this.spriteText=e.spriteText,!0}dwgOut(e){return this.onDwgOut(e),this.dwgOutHelp(e,propertyDbKeys$2),e.type===MxType.MxCloneType.kMxFileClone||e.type===MxType.MxCloneType.kSaveDwgClone?e.spriteText=void 0:e.spriteText=this.spriteText,e}getGeomExtents(){return new THREE.Box3().expandByObject(this.spriteText)}erase(){return super.erase(),this.spriteText&&this.spriteText.dispose(),!0}}function createCurvePath(t=!1){const e=new THREE.CurvePath;return e.autoClose=t,e}function createQuadraticBezierCurve3(t){let e=0,l=[];for(let n=0;n<t.length;n++){const u=t[e],c=t[++e]||u,y=t[++e]||c;if(!u||!c||!y)break;l.push(new THREE.QuadraticBezierCurve3(u,c,y))}return l}function createCubicBezierCurve3(t){let e=0,l=[];for(let n=0;n<t.length;n++){const u=t[e],c=t[++e]||u,y=t[++e]||c,b=t[++e]||y;if(!(u&&c&&y&&b))break;l.push(new THREE.CubicBezierCurve3(u,c,y,b))}return l}function getCurveColorGradientData(t,e){let l=0,n=[],u=[];const c=Number((1/e.length).toFixed(2));let y=new THREE.Color(e[l]),b=new THREE.Color(e[l+1]);for(let m=0,O=t.length;m<O;m++){const N=t[m],L=m/t.length;L/l>=c&&(l++,b.set(new THREE.Color(e[l]||e[--l]))),n.push(N.x,N.y,N.z||0),y.lerpHSL(b,L),u.push(y.r,y.g,y.b)}return[n,u]}function getColorGradientData(t,e){let l=[],n=[];for(let u=0,c=t.length;u<c;u++){const y=t[u];l.push(y.x,y.y,y.z||0);const b=new THREE.Color(e[u]);n.push(b.r,b.g,b.b)}return[l,n]}MxDbText.cmd="Mx_Text",MxDbText.draw=drawMxDbText,addRegisterMxDbEntity(MxDbText);const propertyDbKeys$1=["points","colors","linecap","linejoin","closed","curveType","tension","bezierType"];class MxDbGradientLine extends MxDbEntity{constructor(){super(...arguments),this.linecap="round",this.linejoin="round",this.closed=!1,this.curveType="centripetal",this.tension=0,this.bezierType="quadratic"}create(){return new MxDbGradientLine}getTypeName(){return"MxDbGradientLine"}setPoints(e){return this.points=e,this}setColors(e){return this.colors=e,this}addColor(e){return this.colors.push(e),this}setLinecap(e){this.linecap=e}setClosed(e){this.closed=e}setCurveType(e){this.curveType=e}setTension(e){this.tension=e}setBezierType(e){this.bezierType=e}worldDraw(e){const l=e.getType();let n=this.getPoints();const{closed:u,curveType:c,tension:y,bezierType:b}=this,m=new THREE.BufferGeometry;let O=[],N=[];const L=b==="cubic",G=b==="quadratic";y!==0?this.curve=new THREE.CatmullRomCurve3(n,u,c,y):b?(this.curve=createCurvePath(u),L?this.curve.curves=createCubicBezierCurve3(n):G?this.curve.curves=createQuadraticBezierCurve3(n):this.curve=void 0):this.curve=void 0,this.curve&&(n=this.curve.getPoints(50));const{linecap:q,linejoin:J}=this;let fe;if(this.colors&&this.colors.length>1){const ne=u?[...this.colors,this.colors[0]]:this.colors;[O,N]=this.curve?getCurveColorGradientData(n,ne):getColorGradientData(n,ne),m.setAttribute("position",new THREE.Float32BufferAttribute(O,3)),m.setAttribute("color",new THREE.Float32BufferAttribute(N,3)),fe=new THREE.LineBasicMaterial({vertexColors:THREE.VertexColors,linecap:q,linejoin:J})}else m.setFromPoints(n),fe=new THREE.LineBasicMaterial({color:this.color,linecap:q,linejoin:J});const ve=u?new THREE.LineLoop(m,fe):new THREE.Line(m,fe);if(e.drawEntity(ve),(l===McGiWorldDrawType$1.kSelectDraw||l===McGiWorldDrawType$1.kDynDragDraw)&&this.curve){let ne=this.getPoints();const Ue=e.getLineWidth();e.setLineWidth(1),e.drawLines(ne),e.setLineWidth(Ue)}}getGripPoints(){return this.getPoints()}getPoints(){return this.closed?[...this.points,this.points[0]]:this.points}moveGripPointsAt(e,l){return this.move(e,l),!0}move(e,l){return this.points[e].add(l),this}dwgIn(e){return this.dwgInHelp(e,propertyDbKeys$1),this.curve=e.curve,!0}dwgOut(e){return this.dwgOutHelp(e,propertyDbKeys$1),e.curve=this.curve,e}}function drawMxDbEllipseArc(){const t=new MrxDbgUiPrPoint,e=MxFun.getCurrentDraw(),l=new McEdGetPointWorldDrawObject;let n=new MxDbEllipseArc;t.setUserDraw(l),t.go(async()=>{n.center=t.value(),l.setDraw((u,c)=>{n.startPoint=u,n.yRadius=n.center.distanceTo(u),c.drawCustomEntity(n)}),n.startPoint=await t.go()||new THREE.Vector3,l.setDraw((u,c)=>{n.endPoint=u,c.drawCustomEntity(n)}),n.endPoint=await t.go()||new THREE.Vector3,e.addMxEntity(n)})}addRegisterMxDbEntity(MxDbGradientLine);class MxDbEllipseArc extends MxDbEllipseShape{getTypeName(){return"MxDbEllipseArc"}constructor(){super(),this._propertyDbKeys=[...this._propertyDbKeys,"startPoint","endPoint"]}setStartPoint(e){return this.startPoint=e,this}setEndPoint(e){return this.endPoint=e,this}worldDraw(e){let{center:l,startPoint:n,endPoint:u}=this;n&&(this.xRadius=l.distanceTo(n),this.startAngle=THREE.MathUtils.degToRad(calculateArcAngle(n,l,this.xRadius).angle)),u&&(this.yRadius=l.distanceTo(u),this.endAngle=THREE.MathUtils.degToRad(calculateArcAngle(u,l,this.yRadius).angle)),this.drawEllipseShape(e)}getGripPoints(){return[this.center,this.startPoint,this.endPoint]}moveGripPointsAt(e,l){return e===0&&(this.center.add(l),this.startPoint.add(l),this.endPoint.add(l)),e===1&&this.startPoint.add(l),e===2&&this.endPoint.add(l),!0}}function drawMxDbCircleArc(){const t=new MrxDbgUiPrPoint,e=MxFun.getCurrentDraw(),l=new McEdGetPointWorldDrawObject;let n=new MxDbCircleArc;n.stroke="#ff0000",t.setUserDraw(l),t.setMessage(`
- 确定圆弧中点:`),t.go(async()=>{n.center=t.value(),l.setDraw(u=>{l.drawLine(n.center,u)}),t.setMessage(`
- 确定圆弧开始点:`),n.startPoint=await t.go()||new THREE.Vector3,l.setDraw(u=>{n.endPoint=u,l.drawCustomEntity(n)}),t.setMessage(`
- 确定圆弧结束点:`),n.endPoint=await t.go()||new THREE.Vector3,l.setDraw(()=>{}),e.addMxEntity(n)})}MxDbEllipseArc.cmd="Mx_MxDbEllipseArc",MxDbEllipseArc.draw=drawMxDbEllipseArc,addRegisterMxDbEntity(MxDbEllipseArc);class MxDbCircleArc extends MxDbCircleShape{constructor(){super(),this._propertyDbKeys=[...this._propertyDbKeys,"startPoint","endPoint"]}getTypeName(){return"MxDbCircleArc"}setStartPoint(e){return this.startPoint=e,this}setEndPoint(e){return this.endPoint=e,this}worldDraw(e){let{startPoint:l,endPoint:n}=this;if(l&&(this.startAngle=this.computePointAngle(l)),n&&(this.endAngle=this.computePointAngle(n)),l&&n){const{points:u}=this.drawEllipseShape(e);this.startPoint=u[0]}}computePointAngle(e){return this.radius=this.center.distanceTo(e),THREE.MathUtils.degToRad(calculateArcAngle(e,this.center,this.radius).angle)}getGripPoints(){return[this.center,this.startPoint,this.endPoint]}moveGripPointsAt(e,l){return e===0?(this.center.add(l),this.startPoint.add(l),this.endPoint.add(l)):e===1?this.startPoint.add(l):e===2&&this.endPoint.add(l),!0}}MxDbCircleArc.cmd="Mx_MxDbCircleArc",MxDbCircleArc.draw=drawMxDbCircleArc,addRegisterMxDbEntity(MxDbCircleArc);class MxDbArcShape extends MxDbCircleArc{constructor(){super(),this.center=new THREE.Vector3,this.innerRadius=10,this.outerRadius=20,this._propertyDbKeys=[...this._propertyDbKeys,"center","innerRadius","outerRadius"]}getTypeName(){return"MxDbArcShape"}worldDraw(e){e.getType()===McGiWorldDrawType$1.kDynDragDraw?(e.drawCircle(this.center,this.innerRadius),e.drawCircle(this.center,this.outerRadius)):this.drawArcShape(e)}drawArcShape(e){const{center:l,startAngle:n,endAngle:u,clockwise:c}=this,{x:y,y:b}=l;this.isClosedToCenter=!1;const m=this.createEllipseCurve(y,b,this.innerRadius,this.innerRadius,n,u,c),O=this.createEllipseCurve(y,b,this.outerRadius,this.outerRadius,u,n,!c),N=this.createPaths([m,O]);let L=this.getShapePoints(N);this._draw(e,L),this._drawStoreLine(e,L)}getGripPoints(){return[this.center]}moveGripPointsAt(e,l){return e===0&&this.center.add(l),!0}}function drawMxDbArcShape(){const t=new MrxDbgUiPrPoint,e=MxFun.getCurrentDraw(),l=new McEdGetPointWorldDrawObject;let n=new MxDbArcShapeDraw;t.setMessage(`
- 确定圆弧中点:`),t.setUserDraw(l),t.go(async()=>{t.setMessage(`
- 确定圆弧开始点:`),n.center=t.value(),l.setDraw(u=>{n.interRadiusPoint=u,l.drawCircle(n.center,u.distanceTo(n.center))}),n.interRadiusPoint=await t.go()||new THREE.Vector3,l.setDraw(u=>{n.outerRadiusPoint=u,l.drawCustomEntity(n)}),n.outerRadiusPoint=await t.go()||new THREE.Vector3,e.addMxEntity(n)})}class MxDbArcShapeDraw extends MxDbArcShape{getTypeName(){return"MxDbArcShapeDraw"}constructor(){super(),this.outerRadiusPoint=new THREE.Vector3,this.interRadiusPoint=new THREE.Vector3,this._propertyDbKeys=[...this._propertyDbKeys,"interRadiusPoint","outerRadiusPoint"]}worldDraw(e){this.innerRadius=this.center.distanceTo(this.interRadiusPoint),this.outerRadius=this.center.distanceTo(this.outerRadiusPoint),this.startAngle=THREE.MathUtils.degToRad(calculateArcAngle(this.interRadiusPoint,this.center,this.innerRadius).angle),this.endAngle=THREE.MathUtils.degToRad(calculateArcAngle(this.outerRadiusPoint,this.center,this.outerRadius).angle),this.drawArcShape(e)}getGripPoints(){return[this.center,this.interRadiusPoint,this.outerRadiusPoint]}moveGripPointsAt(e,l){return e===0&&(this.center.add(l),this.interRadiusPoint.add(l),this.outerRadiusPoint.add(l)),e===1&&this.interRadiusPoint.add(l),e===2&&this.outerRadiusPoint.add(l),!0}}function drawMxDbRingShape(){const t=new MrxDbgUiPrPoint,e=MxFun.getCurrentDraw(),l=new McEdGetPointWorldDrawObject;t.setUserDraw(l);const n=new McEdGetPointWorldDrawObject,u=new MxDbRingShapeDraw;t.setUserDraw(n),t.setMessage(`
- 确定圆弧开始点:`),t.go(async c=>{console.log(123),u.center=t.value(),n.setDraw(y=>{n.drawCircle(u.center,u.center.distanceTo(y))}),u.innerPoint=await t.go()||new THREE.Vector3,n.setDraw(y=>{u.outerPoint=y,n.drawCustomEntity(u)}),u.outerPoint=await t.go()||new THREE.Vector3,e.addMxEntity(u)})}MxDbArcShapeDraw.isRegister=!1,MxDbArcShapeDraw.cmd="Mx_MxDbArcShape",MxDbArcShapeDraw.draw=drawMxDbArcShape,addRegisterMxDbEntity(MxDbArcShapeDraw);class MxDbRingShape extends MxDbArcShape{getTypeName(){return"MxDbRingShape"}worldDraw(e){const{center:l,startAngle:n,endAngle:u,clockwise:c}=this,{x:y,y:b}=l;this.isClosedToCenter=!1;const m=this.createEllipseCurve(y,b,this.innerRadius,this.innerRadius,n,u,c),O=this.createEllipseCurve(y,b,this.outerRadius,this.outerRadius,n,u,!c),N=this.createPaths([m,O]);let L=this.getShapePoints(N);const G=this.createPaths(m);let q=this.getShapePoints(G);const J=this.createPaths(O);let fe=this.getShapePoints(J);this.isFill?(this._draw(e,L),this._drawStoreLine(e,q),this._drawStoreLine(e,fe)):(this._draw(e,q),this._drawStoreLine(e,q),this._draw(e,fe),this._drawStoreLine(e,fe))}}MxDbRingShape.isRegister=!1,MxDbRingShape.cmd="Mx_MxDbRingShape",MxDbRingShape.draw=drawMxDbRingShape;class MxDbRingShapeDraw extends MxDbRingShape{constructor(){super(),this.innerPoint=new THREE.Vector3,this.outerPoint=new THREE.Vector3,this._propertyDbKeys=[...this._propertyDbKeys,"innerPoint","outerPoint"]}getGripPoints(){return[this.center,this.innerPoint,this.outerPoint]}moveGripPointsAt(e,l){return e===0&&(this.center.add(l),this.innerPoint.add(l),this.outerPoint.add(l)),e===1&&this.innerPoint.add(l),e===2&&this.outerPoint.add(l),!0}worldDraw(e){this.innerPoint&&(this.innerRadius=this.center.distanceTo(this.innerPoint)),this.outerPoint&&(this.outerRadius=this.center.distanceTo(this.outerPoint)),super.worldDraw(e)}}function drawMxDbStarShape(){const t=new MrxDbgUiPrPoint,e=MxFun.getCurrentDraw(),l=new McEdGetPointWorldDrawObject;t.setUserDraw(l);const n=new McEdGetPointWorldDrawObject,u=new MxDbStarShapeDraw;t.setUserDraw(n),t.setMessage(`
- 确定圆弧开始点:`),t.go(async c=>{u.center=t.value(),n.setDraw(y=>{u.innerPoint=y,n.drawCircle(u.center,u.center.distanceTo(y))}),u.innerPoint=await t.go()||new THREE.Vector3,n.setDraw(y=>{u.outerPoint=y,n.drawCustomEntity(u)}),u.outerPoint=await t.go()||new THREE.Vector3,e.addMxEntity(u)})}addRegisterMxDbEntity(MxDbRingShape);class MxDbStarShape extends MxDbShape{getTypeName(){return"MxDbStarShape"}constructor(){super(),this.center=new THREE.Vector3,this.numPoints=10,this.innerRadius=10,this.outerRadius=10,this._propertyDbKeys=[...this._propertyDbKeys,"center","numPoints","innerRadius","outerRadius"]}worldDraw(e){const{x:l,y:n}=this.center,u=new THREE.Path;u.moveTo(l,n-this.outerRadius);for(let b=1;b<2*this.numPoints;b++){const m=b%2==0?this.outerRadius:this.innerRadius,O=m*Math.sin(b*Math.PI/this.numPoints)+l,N=-1*m*Math.cos(b*Math.PI/this.numPoints)+n;u.lineTo(O,N)}u.closePath();const c=this.createPaths(u),y=this.getShapePoints(c);this._draw(e,y),this._drawStoreLine(e,y)}getGripPoints(){return[this.center]}moveGripPointsAt(e,l){return e===0&&this.center.add(l),!0}}MxDbStarShape.cmd="Mx_MxDbStarShape",MxDbStarShape.draw=drawMxDbStarShape;class MxDbStarShapeDraw extends MxDbStarShape{constructor(){super(),this.innerPoint=new THREE.Vector3,this.outerPoint=new THREE.Vector3,this._propertyDbKeys=[...this._propertyDbKeys,"innerPoint","outerPoint"]}getGripPoints(){return[this.center,this.innerPoint,this.outerPoint]}moveGripPointsAt(e,l){return e===0&&(this.center.add(l),this.innerPoint.add(l),this.outerPoint.add(l)),e===1&&this.innerPoint.add(l),e===2&&this.outerPoint.add(l),!0}worldDraw(e){this.innerPoint&&(this.innerRadius=this.center.distanceTo(this.innerPoint)),this.outerPoint&&(this.outerRadius=this.center.distanceTo(this.outerPoint)),super.worldDraw(e)}}addRegisterMxDbEntity(MxDbStarShape);class MxDbRegularPolygonShape extends MxDbShape{getTypeName(){return"MxDbRegularPolygonShape"}constructor(){super(),this.center=new THREE.Vector3,this.sidesNumber=6,this.radius=70,this._propertyDbKeys=[...this._propertyDbKeys,"center","sidesNumber","radius"]}worldDraw(e){this._drawPolygonShape(e)}_drawPolygonShape(e){const l=this._getPoints(),n=new THREE.Path;n.moveTo(l[0].x,l[0].y);for(let y=0;y<l.length;y++)n.lineTo(l[y].x,l[y].y);n.closePath();const u=this.createPaths(n),c=this.getShapePoints(u);this._draw(e,c),this._drawStoreLine(e,c)}_getPoints(){const{sidesNumber:e,radius:l}=this,{x:n,y:u}=this.center,c=[];for(let y=0;y<e;y++)c.push({x:l*Math.sin(2*y*Math.PI/e)+n,y:-1*l*Math.cos(2*y*Math.PI/e)+u});return c}getGripPoints(){return[this.center]}moveGripPointsAt(e,l){return e===0&&this.center.add(l),!0}}function getScreenPixel(t,e){let l=MxFun.screenCoordLong2World(t-t/3);return l=MxFun.worldCoordLong2Doc(l)}function drawMxDbArrow(){const t=new McEdGetPointWorldDrawObject,e=new MxDbArrow,l=MxFun.getCurrentDraw(),n=new MrxDbgUiPrPoint;n.setUserDraw(t),e.setLineWidth(10),n.go(()=>{e.innerOffset=getScreenPixel(10),e.outerOffset=getScreenPixel(22),e.topOffset=getScreenPixel(36),e.startPoint=n.value(),t.setDraw(u=>{e.endPoint=u,t.drawCustomEntity(e)}),n.go(async u=>{e.endPoint=n.value(),l.addMxEntity(e)})})}addRegisterMxDbEntity(MxDbRegularPolygonShape);class MxDbArrow extends MxDbShape{constructor(){super(),this.isSharpCorner=!1,this.innerOffset=10,this.outerOffset=22,this.topOffset=36,this.startPoint=new THREE.Vector3,this.endPoint=new THREE.Vector3,this._propertyDbKeys=[...this._propertyDbKeys,"outerOffset","topOffset","innerOffset","isSharpCorner","startPoint","endPoint"]}worldDraw(e){const l=this.getArrowVertex(this.startPoint,this.endPoint);l&&(this._draw(e,l),this._drawStoreLine(e,l))}getArrowVertex(e,l,n=this.isSharpCorner){let{innerOffset:u,topOffset:c,outerOffset:y}=this;const b=[];b[3]=l;const m=Math.sqrt((e.x-l.x)*(e.x-l.x)+(e.y-l.y)*(e.y-l.y));if(m===0)return;const O=-(l.x-e.x)/m,N=(l.y-e.y)/m,L=e.x+u,G=e.y+m-c,q=e.x+y,J=e.y+m-c,fe=e.x-u,ve=e.y+m-c,ne=e.x-y,Ue=e.y+m-c;return n?(b[0]=e,b[6]=b[0]):(b[0]=new THREE.Vector3(e.x-(fe-e.x)*N,e.y-(fe-e.x)*O),b[6]=new THREE.Vector3(e.x+(fe-e.x)*N,e.y+(fe-e.x)*O),b[7]=b[0]),b[1]=new THREE.Vector3(e.x+(L-e.x)*N-(G-e.y)*O,e.y+(L-e.x)*O+(G-e.y)*N),b[2]=new THREE.Vector3(e.x+(q-e.x)*N-(J-e.y)*O,e.y+(q-e.x)*O+(J-e.y)*N),b[4]=new THREE.Vector3(e.x+(ne-e.x)*N-(Ue-e.y)*O,e.y+(ne-e.x)*O+(Ue-e.y)*N),b[5]=new THREE.Vector3(e.x+(fe-e.x)*N-(ve-e.y)*O,e.y+(fe-e.x)*O+(ve-e.y)*N),b}getGripPoints(){const e=new THREE.Vector3;return new THREE.Line3(this.startPoint,this.endPoint).getCenter(e),[this.startPoint,e,this.endPoint]}moveGripPointsAt(e,l){return e===0&&this.startPoint.add(l),e===1&&(this.startPoint.add(l),this.endPoint.add(l)),e===2&&this.endPoint.add(l),!0}getCornerRadiusPoints(e){return e}}MxDbArrow.cmd="Mx_MxDbArrow",MxDbArrow.draw=drawMxDbArrow,addRegisterMxDbEntity(MxDbArrow);class MxDbLineShape extends MxDbShape{setPoints(e){return this.points=e,this}addPoint(e){return this.points.push(e),this}removePoint(e){return this.points.splice(e,1),this}constructor(){super(),this.points=[],this._propertyDbKeys=[...this._propertyDbKeys,"points"]}getTypeName(){return"MxDbLineShape"}worldDraw(e){this._draw(e,this.points),this._drawStoreLine(e,this.points)}getGripPoints(){return this.points}moveGripPointsAt(e,l){return this.points[e].add(l),!0}getGeomExtents(){return new THREE.Box3().setFromPoints(this.points)}getGetLength(){let e=0;for(let l=0;l++;l<this.points.length)this.points[l+1]&&(e+=this.points[l].distanceTo(this.points[l+1]));return e}}async function drawMxDbSplineCurve(){const t=new MrxDbgUiPrPoint,e=new MxDbSplineCurve;t.setMessage(`
- 指定第一个点:`),t.goWhile(async l=>{if(l===MrxDbgUiPrBaseReturn$1.kOk)e.points.push(t.value()),t.setUserDraw((n,u)=>{const c=e.clone();c.points.push(n),u.drawCustomEntity(c),e.points.length===0?t.setMessage(`
- 指定第一个点:`):(t.setMessage(`
- 指定下一个点:`),t.setKeyWords("[闭合(C)/ 放弃(U)]"))});else if(l===MrxDbgUiPrBaseReturn$1.kKeyWord){if(t.isKeyWordPicked("C"))return e.closed=!0,{exit:!0};t.isKeyWordPicked("U")&&e.points.pop()}},()=>{MxFun.getCurrentDraw().addMxEntity(e)})}addRegisterMxDbEntity(MxDbLineShape);const propertyDbKeys=["points","closed","tension","curveType"];class MxDbSplineCurve extends MxDbEntity{constructor(){super(...arguments),this.points=[],this.closed=!1,this.tension=.5,this.curveType="centripetal"}worldDraw(e){const l=new THREE.CatmullRomCurve3(this.points,this.closed,"catmullrom",this.tension).getPoints(15*this.points.length),n=new THREE.Geometry().setFromPoints(l),u=new THREE.LineBasicMaterial({color:this.color}),c=new THREE.Line(n,u);e.drawEntity(c)}getGripPoints(){return this.points}moveGripPointsAt(e,l){return this.points[e].add(l),!0}create(){return new MxDbSplineCurve}dwgIn(e){return this.onDwgIn(e),this.dwgInHelp(e,propertyDbKeys),!0}dwgOut(e){return this.onDwgOut(e),this.dwgOutHelp(e,propertyDbKeys),e}getTypeName(){return"MxDbSplineCurve"}}MxDbSplineCurve.draw=drawMxDbSplineCurve,MxDbSplineCurve.cmd="Mx_Spline",addRegisterMxDbEntity(MxDbSplineCurve);class MrxDbgUiPrDist extends MrxDbgUiPrBase{constructor(){var e;super(new((e=store.state.MxFun)===null||e===void 0?void 0:e.getMxJigCmdManager().getMrxDbgUiPrDistClass()))}value(){return this.imp.value()}basePt(){return this.imp.basePt()}setBasePt(e){return this.imp.setBasePt(e)}setUseBasePt(e){return this.imp.setUseBasePt(e)}go(e){let l=this;return e?(l.imp.go(n=>{l.status=n,e(n)}),new Promise((n,u)=>{n(null)})):new Promise((n,u)=>{l.imp.go(c=>{l.status=c,n(c!=0?null:l.imp.value())})})}}class MrxDbgUiPrInt extends MrxDbgUiPrBase{constructor(){var e;super(new((e=store.state.MxFun)===null||e===void 0?void 0:e.getMxJigCmdManager().getMrxDbgUiPrIntClass()))}value(){return this.imp.value()}go(e){let l=this;return e?(l.imp.go(n=>{l.status=n,e(n)}),new Promise((n,u)=>{n(null)})):new Promise((n,u)=>{l.imp.go(c=>{l.status=c,n(c!=0?null:l.imp.value())})})}}class MrxDbgUiPrString extends MrxDbgUiPrBase{constructor(){var e;super(new((e=store.state.MxFun)===null||e===void 0?void 0:e.getMxJigCmdManager().getMrxDbgUiPrStringClass()))}value(){return this.imp.value()}go(e){let l=this;return e?(l.imp.go(n=>{l.status=n,e(n)}),new Promise((n,u)=>{n(null)})):new Promise((n,u)=>{l.imp.go(c=>{l.status=c,n(c!=0?null:l.imp.value())})})}}class MrxDbgUiPrKeyWord extends MrxDbgUiPrBase{constructor(){var e;super(new((e=store.state.MxFun)===null||e===void 0?void 0:e.getMxJigCmdManager().getMrxDbgUiPrKeyWordClass()))}go(e){let l=this;return e?(l.imp.go(n=>{l.status=n,e(n)}),new Promise((n,u)=>{n(null)})):new Promise((n,u)=>{l.imp.go(c=>{l.status=c,n(c!=0?null:l.keyWordPicked())})})}}class MrxDbgUiPrAngle extends MrxDbgUiPrBase{constructor(){var e;super(new((e=store.state.MxFun)===null||e===void 0?void 0:e.getMxJigCmdManager().getMrxDbgUiPrAngleClass()))}value(){return this.imp.value()}basePt(){return this.imp.basePt()}setBasePt(e){return this.imp.setBasePt(e)}setUseBasePt(e){return this.imp.setUseBasePt(e)}go(e){let l=this;return e?(l.imp.go(n=>{l.status=n,e(n)}),new Promise((n,u)=>{n(null)})):new Promise((n,u)=>{l.imp.go(c=>{l.status=c,n(c!=0?null:l.imp.value())})})}}var Mx=Object.freeze({__proto__:null,loadCoreCode,useCanvasResizeListener,store,MxFun,MxThreeJS,MxType,Mxassembly,McGeTool,MrxDbgUtils,MxPaintBrush,MrxDbgUiPrPoint,McEdGetPointWorldDrawObject,MrxDbgUiPrBaseReturn:MrxDbgUiPrBaseReturn$1,MxDbEntity,MxDbImage,MxDbSVG,MxDbSVGText,MxDbPolyline,MxDb2LineAngularDimension,Mx3PointArc,Mx2PointArc,MxDbCoord,MxDbLine,MxDbRect,MxDbAlignedDimension,MxFilters,McGiWorldDrawType:McGiWorldDrawType$1,MxDbArea,MxDbLeadTag,MxDbAnyLine,MxDbCloudLine,MxDbRegularPolygon,MxDbLeadComment,MxDbRectBoxLeadComment,MxDbEllipse,MxDbText,MxDrawObject,MxDbHatch,MxDbDatabase,MxDbGradientLine,MxDbShape,MxDbEllipseShape,MxDbEllipseArc,MxDbCircleShape,MxDbCircleArc,MxDbArcShapeDraw,MxDbRingShape,MxDbStarShape,MxDbRegularPolygonShape,MxDbArrow,MxDbLineShape,Layer,MxDbSplineCurve,MrxDbgUiPrBase,get MxCursorType(){return MxCursorType},get DetailedResult(){return DetailedResult},get DynamicInputType(){return DynamicInputType},get UserInputControls(){return UserInputControls},MrxDbgUiPrDist,MrxDbgUiPrInt,MrxDbgUiPrString,MrxDbgUiPrKeyWord,MrxDbgUiPrAngle,MxTempMarkDraw}),elementResizeEventPolyfill_umd_min=createCommonjsModule(function(t,e){t.exports=function(l){var n={};function u(c){if(n[c])return n[c].exports;var y=n[c]={i:c,l:!1,exports:{}};return l[c].call(y.exports,y,y.exports,u),y.l=!0,y.exports}return u.m=l,u.c=n,u.d=function(c,y,b){u.o(c,y)||Object.defineProperty(c,y,{enumerable:!0,get:b})},u.r=function(c){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(c,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(c,"__esModule",{value:!0})},u.t=function(c,y){if(1&y&&(c=u(c)),8&y||4&y&&typeof c=="object"&&c&&c.__esModule)return c;var b=Object.create(null);if(u.r(b),Object.defineProperty(b,"default",{enumerable:!0,value:c}),2&y&&typeof c!="string")for(var m in c)u.d(b,m,function(O){return c[O]}.bind(null,m));return b},u.n=function(c){var y=c&&c.__esModule?function(){return c.default}:function(){return c};return u.d(y,"a",y),y},u.o=function(c,y){return Object.prototype.hasOwnProperty.call(c,y)},u.p="",u(u.s="fae3")}({"6dd8":function(l,n,u){(function(c){var y=function(){if(typeof Map<"u")return Map;function kt(It,nn){var tn=-1;return It.some(function(pn,_n){return pn[0]===nn&&(tn=_n,!0)}),tn}return function(){function It(){this.__entries__=[]}return Object.defineProperty(It.prototype,"size",{get:function(){return this.__entries__.length},enumerable:!0,configurable:!0}),It.prototype.get=function(nn){var tn=kt(this.__entries__,nn),pn=this.__entries__[tn];return pn&&pn[1]},It.prototype.set=function(nn,tn){var pn=kt(this.__entries__,nn);~pn?this.__entries__[pn][1]=tn:this.__entries__.push([nn,tn])},It.prototype.delete=function(nn){var tn=this.__entries__,pn=kt(tn,nn);~pn&&tn.splice(pn,1)},It.prototype.has=function(nn){return!!~kt(this.__entries__,nn)},It.prototype.clear=function(){this.__entries__.splice(0)},It.prototype.forEach=function(nn,tn){tn===void 0&&(tn=null);for(var pn=0,_n=this.__entries__;pn<_n.length;pn++){var Dn=_n[pn];nn.call(tn,Dn[1],Dn[0])}},It}()}(),b=typeof window<"u"&&typeof document<"u"&&window.document===document,m=c!==void 0&&c.Math===Math?c:typeof self<"u"&&self.Math===Math?self:typeof window<"u"&&window.Math===Math?window:Function("return this")(),O=typeof requestAnimationFrame=="function"?requestAnimationFrame.bind(m):function(kt){return setTimeout(function(){return kt(Date.now())},1e3/60)},N=2,L=20,G=["top","right","bottom","left","width","height","size","weight"],q=typeof MutationObserver<"u",J=function(){function kt(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=function(It,nn){var tn=!1,pn=!1,_n=0;function Dn(){tn&&(tn=!1,It()),pn&&Rn()}function an(){O(Dn)}function Rn(){var Lt=Date.now();if(tn){if(Lt-_n<N)return;pn=!0}else tn=!0,pn=!1,setTimeout(an,nn);_n=Lt}return Rn}(this.refresh.bind(this),L)}return kt.prototype.addObserver=function(It){~this.observers_.indexOf(It)||this.observers_.push(It),this.connected_||this.connect_()},kt.prototype.removeObserver=function(It){var nn=this.observers_,tn=nn.indexOf(It);~tn&&nn.splice(tn,1),!nn.length&&this.connected_&&this.disconnect_()},kt.prototype.refresh=function(){this.updateObservers_()&&this.refresh()},kt.prototype.updateObservers_=function(){var It=this.observers_.filter(function(nn){return nn.gatherActive(),nn.hasActive()});return It.forEach(function(nn){return nn.broadcastActive()}),It.length>0},kt.prototype.connect_=function(){b&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),q?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},kt.prototype.disconnect_=function(){b&&this.connected_&&(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},kt.prototype.onTransitionEnd_=function(It){var nn=It.propertyName,tn=nn===void 0?"":nn;G.some(function(pn){return!!~tn.indexOf(pn)})&&this.refresh()},kt.getInstance=function(){return this.instance_||(this.instance_=new kt),this.instance_},kt.instance_=null,kt}(),fe=function(kt,It){for(var nn=0,tn=Object.keys(It);nn<tn.length;nn++){var pn=tn[nn];Object.defineProperty(kt,pn,{value:It[pn],enumerable:!1,writable:!1,configurable:!0})}return kt},ve=function(kt){return kt&&kt.ownerDocument&&kt.ownerDocument.defaultView||m},ne=Te(0,0,0,0);function Ue(kt){return parseFloat(kt)||0}function De(kt){for(var It=[],nn=1;nn<arguments.length;nn++)It[nn-1]=arguments[nn];return It.reduce(function(tn,pn){return tn+Ue(kt["border-"+pn+"-width"])},0)}function Ve(kt){var It=kt.clientWidth,nn=kt.clientHeight;if(!It&&!nn)return ne;var tn=ve(kt).getComputedStyle(kt),pn=function(hn){for(var xn={},$n=0,Xr=["top","right","bottom","left"];$n<Xr.length;$n++){var ti=Xr[$n],gn=hn["padding-"+ti];xn[ti]=Ue(gn)}return xn}(tn),_n=pn.left+pn.right,Dn=pn.top+pn.bottom,an=Ue(tn.width),Rn=Ue(tn.height);if(tn.boxSizing==="border-box"&&(Math.round(an+_n)!==It&&(an-=De(tn,"left","right")+_n),Math.round(Rn+Dn)!==nn&&(Rn-=De(tn,"top","bottom")+Dn)),!function(hn){return hn===ve(hn).document.documentElement}(kt)){var Lt=Math.round(an+_n)-It,wn=Math.round(Rn+Dn)-nn;Math.abs(Lt)!==1&&(an-=Lt),Math.abs(wn)!==1&&(Rn-=wn)}return Te(pn.left,pn.top,an,Rn)}var rt=typeof SVGGraphicsElement<"u"?function(kt){return kt instanceof ve(kt).SVGGraphicsElement}:function(kt){return kt instanceof ve(kt).SVGElement&&typeof kt.getBBox=="function"};function Ae(kt){return b?rt(kt)?function(It){var nn=It.getBBox();return Te(0,0,nn.width,nn.height)}(kt):Ve(kt):ne}function Te(kt,It,nn,tn){return{x:kt,y:It,width:nn,height:tn}}var Xe=function(){function kt(It){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=Te(0,0,0,0),this.target=It}return kt.prototype.isActive=function(){var It=Ae(this.target);return this.contentRect_=It,It.width!==this.broadcastWidth||It.height!==this.broadcastHeight},kt.prototype.broadcastRect=function(){var It=this.contentRect_;return this.broadcastWidth=It.width,this.broadcastHeight=It.height,It},kt}(),ie=function(){return function(kt,It){var nn=function(tn){var pn=tn.x,_n=tn.y,Dn=tn.width,an=tn.height,Rn=typeof DOMRectReadOnly<"u"?DOMRectReadOnly:Object,Lt=Object.create(Rn.prototype);return fe(Lt,{x:pn,y:_n,width:Dn,height:an,top:_n,right:pn+Dn,bottom:an+_n,left:pn}),Lt}(It);fe(this,{target:kt,contentRect:nn})}}(),ue=function(){function kt(It,nn,tn){if(this.activeObservations_=[],this.observations_=new y,typeof It!="function")throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=It,this.controller_=nn,this.callbackCtx_=tn}return kt.prototype.observe=function(It){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(typeof Element<"u"&&Element instanceof Object){if(!(It instanceof ve(It).Element))throw new TypeError('parameter 1 is not of type "Element".');var nn=this.observations_;nn.has(It)||(nn.set(It,new Xe(It)),this.controller_.addObserver(this),this.controller_.refresh())}},kt.prototype.unobserve=function(It){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(typeof Element<"u"&&Element instanceof Object){if(!(It instanceof ve(It).Element))throw new TypeError('parameter 1 is not of type "Element".');var nn=this.observations_;nn.has(It)&&(nn.delete(It),nn.size||this.controller_.removeObserver(this))}},kt.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},kt.prototype.gatherActive=function(){var It=this;this.clearActive(),this.observations_.forEach(function(nn){nn.isActive()&&It.activeObservations_.push(nn)})},kt.prototype.broadcastActive=function(){if(this.hasActive()){var It=this.callbackCtx_,nn=this.activeObservations_.map(function(tn){return new ie(tn.target,tn.broadcastRect())});this.callback_.call(It,nn,It),this.clearActive()}},kt.prototype.clearActive=function(){this.activeObservations_.splice(0)},kt.prototype.hasActive=function(){return this.activeObservations_.length>0},kt}(),pt=typeof WeakMap<"u"?new WeakMap:new y,mt=function(){return function kt(It){if(!(this instanceof kt))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var nn=J.getInstance(),tn=new ue(It,nn,this);pt.set(this,tn)}}();["observe","unobserve","disconnect"].forEach(function(kt){mt.prototype[kt]=function(){var It;return(It=pt.get(this))[kt].apply(It,arguments)}});var Tt=m.ResizeObserver!==void 0?m.ResizeObserver:mt;n.a=Tt}).call(this,u("c8ba"))},c8ba:function(l,n){var u;u=function(){return this}();try{u=u||new Function("return this")()}catch{typeof window=="object"&&(u=window)}l.exports=u},f6fd:function(l,n){(function(u){var c="currentScript",y=u.getElementsByTagName("script");c in u||Object.defineProperty(u,c,{get:function(){try{throw new Error}catch(O){var b,m=(/.*at [^\(]*\((.*):.+:.+\)$/gi.exec(O.stack)||[!1])[1];for(b in y)if(y[b].src==m||y[b].readyState=="interactive")return y[b];return null}}})})(document)},fae3:function(l,n,u){var c;u.r(n),u.d(n,"EventListenerWrapper",function(){return O}),typeof window<"u"&&(u("f6fd"),(c=window.document.currentScript)&&(c=c.src.match(/(.+\/)[^/]+\.js(\?.*)?$/))&&(u.p=c[1]));var y=u("6dd8");const b=EventTarget.prototype.addEventListener,m=function(G){const q=document.createEvent("HTMLEvents");return q.initEvent(G),q},O=function(G){G==="resize"&&L(this),b.apply(this,arguments)};function N(G){const q=N.observer=N.observer||new y.a(G);return q.initialized=!0,q}function L(G){const q=N(J=>{if(q.initialized)q.initialized=!1;else for(let fe of J){const ve=m("resize");fe.target.dispatchEvent(ve),fe&&fe.target&&typeof fe.target.onresize=="function"&&fe.target.onresize(ve)}});q.observe(G)}HTMLElement.prototype.addEventListener=O,Reflect.defineProperty(HTMLElement.prototype,"onresize",{set(G){this._onresize=G,typeof G=="function"&&L(this)},get(){return this._onresize||null}})}})}),elementResizeEventPolyfill_umd_min$1=unwrapExports(elementResizeEventPolyfill_umd_min),elementResizeEventPolyfill_umd_min$2=Object.freeze({__proto__:null,default:elementResizeEventPolyfill_umd_min$1,__moduleExports:elementResizeEventPolyfill_umd_min});const Mx$1=Object.freeze(Object.defineProperty({__proto__:null,get DetailedResult(){return DetailedResult},get DynamicInputType(){return DynamicInputType},Layer,McEdGetPointWorldDrawObject,McGeTool,McGiWorldDrawType:McGiWorldDrawType$1,MrxDbgUiPrAngle,MrxDbgUiPrBase,MrxDbgUiPrBaseReturn:MrxDbgUiPrBaseReturn$1,MrxDbgUiPrDist,MrxDbgUiPrInt,MrxDbgUiPrKeyWord,MrxDbgUiPrPoint,MrxDbgUiPrString,MrxDbgUtils,Mx2PointArc,Mx3PointArc,get MxCursorType(){return MxCursorType},MxDb2LineAngularDimension,MxDbAlignedDimension,MxDbAnyLine,MxDbArcShapeDraw,MxDbArea,MxDbArrow,MxDbCircleArc,MxDbCircleShape,MxDbCloudLine,MxDbCoord,MxDbDatabase,MxDbEllipse,MxDbEllipseArc,MxDbEllipseShape,MxDbEntity,MxDbGradientLine,MxDbHatch,MxDbImage,MxDbLeadComment,MxDbLeadTag,MxDbLine,MxDbLineShape,MxDbPolyline,MxDbRect,MxDbRectBoxLeadComment,MxDbRegularPolygon,MxDbRegularPolygonShape,MxDbRingShape,MxDbSVG,MxDbSVGText,MxDbShape,MxDbSplineCurve,MxDbStarShape,MxDbText,MxDrawObject,MxFilters,MxFun,MxPaintBrush,MxTempMarkDraw,MxThreeJS,MxType,Mxassembly,get UserInputControls(){return UserInputControls},default:Mx,loadCoreCode,store,useCanvasResizeListener},Symbol.toStringTag,{value:"Module"}));let commands=[];const items=new Set([]),comboboxItems=ref([]),registerCmdRecord=()=>{comboboxItems.value=Array.from(items)},addCmdRecord=(t,e=!1)=>{items.add(t),e&®isterCmdRecord()},registerCommand=()=>{for(;commands.length!==0;){const t=commands.pop();if(t){const{cmd:e,fun:l}=t;MxFun.addCommand(e,l),addCmdRecord(e)}}registerCmdRecord()},add$1=MxFun.addCommand;let str="";window.getCmdListString=()=>str;store.state.MxFun.addCommand=(t,e)=>{str+=`${t},`,add$1(t,e)};const addCommand=(t,e)=>{store.state.MxFun!==null?(MxFun.addCommand(t,e),addCmdRecord(t,!0)):commands.push({cmd:t,fun:e})},callCommand=(t,e)=>MxFun.sendStringToExecute(t,e);var isVue2$1=!1;/*!
- * pinia v2.0.32
- * (c) 2023 Eduardo San Martin Morote
- * @license MIT
- */let activePinia;const setActivePinia=t=>activePinia=t,piniaSymbol=Symbol();function isPlainObject$2(t){return t&&typeof t=="object"&&Object.prototype.toString.call(t)==="[object Object]"&&typeof t.toJSON!="function"}var MutationType;(function(t){t.direct="direct",t.patchObject="patch object",t.patchFunction="patch function"})(MutationType||(MutationType={}));function createPinia(){const t=effectScope(!0),e=t.run(()=>ref({}));let l=[],n=[];const u=markRaw({install(c){setActivePinia(u),u._a=c,c.provide(piniaSymbol,u),c.config.globalProperties.$pinia=u,n.forEach(y=>l.push(y)),n=[]},use(c){return!this._a&&!isVue2$1?n.push(c):l.push(c),this},_p:l,_a:null,_e:t,_s:new Map,state:e});return u}const noop$3=()=>{};function addSubscription(t,e,l,n=noop$3){t.push(e);const u=()=>{const c=t.indexOf(e);c>-1&&(t.splice(c,1),n())};return!l&&getCurrentScope()&&onScopeDispose(u),u}function triggerSubscriptions(t,...e){t.slice().forEach(l=>{l(...e)})}function mergeReactiveObjects(t,e){t instanceof Map&&e instanceof Map&&e.forEach((l,n)=>t.set(n,l)),t instanceof Set&&e instanceof Set&&e.forEach(t.add,t);for(const l in e){if(!e.hasOwnProperty(l))continue;const n=e[l],u=t[l];isPlainObject$2(u)&&isPlainObject$2(n)&&t.hasOwnProperty(l)&&!isRef(n)&&!isReactive(n)?t[l]=mergeReactiveObjects(u,n):t[l]=n}return t}const skipHydrateSymbol=Symbol();function shouldHydrate(t){return!isPlainObject$2(t)||!t.hasOwnProperty(skipHydrateSymbol)}const{assign}=Object;function isComputed(t){return!!(isRef(t)&&t.effect)}function createOptionsStore(t,e,l,n){const{state:u,actions:c,getters:y}=e,b=l.state.value[t];let m;function O(){b||(l.state.value[t]=u?u():{});const N=toRefs(l.state.value[t]);return assign(N,c,Object.keys(y||{}).reduce((L,G)=>(L[G]=markRaw(computed(()=>{setActivePinia(l);const q=l._s.get(t);return y[G].call(q,q)})),L),{}))}return m=createSetupStore(t,O,e,l,n,!0),m.$reset=function(){const L=u?u():{};this.$patch(G=>{assign(G,L)})},m}function createSetupStore(t,e,l={},n,u,c){let y;const b=assign({actions:{}},l),m={deep:!0};let O,N,L=markRaw([]),G=markRaw([]),q;const J=n.state.value[t];!c&&!J&&(n.state.value[t]={}),ref({});let fe;function ve(Te){let Xe;O=N=!1,typeof Te=="function"?(Te(n.state.value[t]),Xe={type:MutationType.patchFunction,storeId:t,events:q}):(mergeReactiveObjects(n.state.value[t],Te),Xe={type:MutationType.patchObject,payload:Te,storeId:t,events:q});const ie=fe=Symbol();nextTick().then(()=>{fe===ie&&(O=!0)}),N=!0,triggerSubscriptions(L,Xe,n.state.value[t])}const ne=noop$3;function Ue(){y.stop(),L=[],G=[],n._s.delete(t)}function De(Te,Xe){return function(){setActivePinia(n);const ie=Array.from(arguments),ue=[],pt=[];function mt(It){ue.push(It)}function Tt(It){pt.push(It)}triggerSubscriptions(G,{args:ie,name:Te,store:rt,after:mt,onError:Tt});let kt;try{kt=Xe.apply(this&&this.$id===t?this:rt,ie)}catch(It){throw triggerSubscriptions(pt,It),It}return kt instanceof Promise?kt.then(It=>(triggerSubscriptions(ue,It),It)).catch(It=>(triggerSubscriptions(pt,It),Promise.reject(It))):(triggerSubscriptions(ue,kt),kt)}}const Ve={_p:n,$id:t,$onAction:addSubscription.bind(null,G),$patch:ve,$reset:ne,$subscribe(Te,Xe={}){const ie=addSubscription(L,Te,Xe.detached,()=>ue()),ue=y.run(()=>watch(()=>n.state.value[t],pt=>{(Xe.flush==="sync"?N:O)&&Te({storeId:t,type:MutationType.direct,events:q},pt)},assign({},m,Xe)));return ie},$dispose:Ue},rt=reactive(Ve);n._s.set(t,rt);const Ae=n._e.run(()=>(y=effectScope(),y.run(()=>e())));for(const Te in Ae){const Xe=Ae[Te];if(isRef(Xe)&&!isComputed(Xe)||isReactive(Xe))c||(J&&shouldHydrate(Xe)&&(isRef(Xe)?Xe.value=J[Te]:mergeReactiveObjects(Xe,J[Te])),n.state.value[t][Te]=Xe);else if(typeof Xe=="function"){const ie=De(Te,Xe);Ae[Te]=ie,b.actions[Te]=Xe}}return assign(rt,Ae),assign(toRaw(rt),Ae),Object.defineProperty(rt,"$state",{get:()=>n.state.value[t],set:Te=>{ve(Xe=>{assign(Xe,Te)})}}),n._p.forEach(Te=>{assign(rt,y.run(()=>Te({store:rt,app:n._a,pinia:n,options:b})))}),J&&c&&l.hydrate&&l.hydrate(rt.$state,J),O=!0,N=!0,rt}function defineStore(t,e,l){let n,u;const c=typeof e=="function";typeof t=="string"?(n=t,u=c?l:e):(u=t,n=t.id);function y(b,m){const O=getCurrentInstance$1();return b=b||O&&inject$1(piniaSymbol,null),b&&setActivePinia(b),b=activePinia,b._s.has(n)||(c?createSetupStore(n,e,u,b):createOptionsStore(n,u,b)),b._s.get(n)}return y.$id=n,y}function storeToRefs(t){{t=toRaw(t);const e={};for(const l in t){const n=t[l];(isRef(n)||isReactive(n))&&(e[l]=toRef(t,l))}return e}}var isVue2=!1,isVue3=!0,_a;const isClient=typeof window<"u",isBoolean$1=t=>typeof t=="boolean",isFunction$1=t=>typeof t=="function",isString$1=t=>typeof t=="string",noop$2=()=>{};isClient&&((_a=window?.navigator)!=null&&_a.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function resolveUnref(t){return typeof t=="function"?t():unref(t)}function createFilterWrapper(t,e){function l(...n){return new Promise((u,c)=>{Promise.resolve(t(()=>e.apply(this,n),{fn:e,thisArg:this,args:n})).then(u).catch(c)})}return l}const bypassFilter=t=>t();function debounceFilter(t,e={}){let l,n,u=noop$2;const c=b=>{clearTimeout(b),u(),u=noop$2};return b=>{const m=resolveUnref(t),O=resolveUnref(e.maxWait);return l&&c(l),m<=0||O!==void 0&&O<=0?(n&&(c(n),n=null),Promise.resolve(b())):new Promise((N,L)=>{u=e.rejectOnCancel?L:N,O&&!n&&(n=setTimeout(()=>{l&&c(l),n=null,N(b())},O)),l=setTimeout(()=>{n&&c(n),n=null,N(b())},m)})}}function pausableFilter(t=bypassFilter){const e=ref(!0);function l(){e.value=!1}function n(){e.value=!0}const u=(...c)=>{e.value&&t(...c)};return{isActive:readonly(e),pause:l,resume:n,eventFilter:u}}function identity(t){return t}function tryOnScopeDispose(t){return getCurrentScope()?(onScopeDispose(t),!0):!1}function createEventHook(){const t=[],e=u=>{const c=t.indexOf(u);c!==-1&&t.splice(c,1)};return{on:u=>{t.push(u);const c=()=>e(u);return tryOnScopeDispose(c),{off:c}},off:e,trigger:u=>{t.forEach(c=>c(u))}}}function useDebounceFn(t,e=200,l={}){return createFilterWrapper(debounceFilter(e,l),t)}var __getOwnPropSymbols$6=Object.getOwnPropertySymbols,__hasOwnProp$6=Object.prototype.hasOwnProperty,__propIsEnum$6=Object.prototype.propertyIsEnumerable,__objRest$5=(t,e)=>{var l={};for(var n in t)__hasOwnProp$6.call(t,n)&&e.indexOf(n)<0&&(l[n]=t[n]);if(t!=null&&__getOwnPropSymbols$6)for(var n of __getOwnPropSymbols$6(t))e.indexOf(n)<0&&__propIsEnum$6.call(t,n)&&(l[n]=t[n]);return l};function watchWithFilter(t,e,l={}){const n=l,{eventFilter:u=bypassFilter}=n,c=__objRest$5(n,["eventFilter"]);return watch(t,createFilterWrapper(u,e),c)}var __defProp$2$1=Object.defineProperty,__defProps$2=Object.defineProperties,__getOwnPropDescs$2=Object.getOwnPropertyDescriptors,__getOwnPropSymbols$2=Object.getOwnPropertySymbols,__hasOwnProp$2=Object.prototype.hasOwnProperty,__propIsEnum$2=Object.prototype.propertyIsEnumerable,__defNormalProp$2$1=(t,e,l)=>e in t?__defProp$2$1(t,e,{enumerable:!0,configurable:!0,writable:!0,value:l}):t[e]=l,__spreadValues$2=(t,e)=>{for(var l in e||(e={}))__hasOwnProp$2.call(e,l)&&__defNormalProp$2$1(t,l,e[l]);if(__getOwnPropSymbols$2)for(var l of __getOwnPropSymbols$2(e))__propIsEnum$2.call(e,l)&&__defNormalProp$2$1(t,l,e[l]);return t},__spreadProps$2=(t,e)=>__defProps$2(t,__getOwnPropDescs$2(e)),__objRest$1=(t,e)=>{var l={};for(var n in t)__hasOwnProp$2.call(t,n)&&e.indexOf(n)<0&&(l[n]=t[n]);if(t!=null&&__getOwnPropSymbols$2)for(var n of __getOwnPropSymbols$2(t))e.indexOf(n)<0&&__propIsEnum$2.call(t,n)&&(l[n]=t[n]);return l};function watchPausable(t,e,l={}){const n=l,{eventFilter:u}=n,c=__objRest$1(n,["eventFilter"]),{eventFilter:y,pause:b,resume:m,isActive:O}=pausableFilter(u);return{stop:watchWithFilter(t,e,__spreadProps$2(__spreadValues$2({},c),{eventFilter:y})),pause:b,resume:m,isActive:O}}function unrefElement(t){var e;const l=resolveUnref(t);return(e=l?.$el)!=null?e:l}const defaultWindow=isClient?window:void 0,defaultDocument=isClient?window.document:void 0;function useEventListener(...t){let e,l,n,u;if(isString$1(t[0])||Array.isArray(t[0])?([l,n,u]=t,e=defaultWindow):[e,l,n,u]=t,!e)return noop$2;Array.isArray(l)||(l=[l]),Array.isArray(n)||(n=[n]);const c=[],y=()=>{c.forEach(N=>N()),c.length=0},b=(N,L,G,q)=>(N.addEventListener(L,G,q),()=>N.removeEventListener(L,G,q)),m=watch(()=>[unrefElement(e),resolveUnref(u)],([N,L])=>{y(),N&&c.push(...l.flatMap(G=>n.map(q=>b(N,G,q,L))))},{immediate:!0,flush:"post"}),O=()=>{m(),y()};return tryOnScopeDispose(O),O}const _global$1=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},globalKey="__vueuse_ssr_handlers__";_global$1[globalKey]=_global$1[globalKey]||{};const handlers$1=_global$1[globalKey];function getSSRHandler(t,e){return handlers$1[t]||e}function guessSerializerType(t){return t==null?"any":t instanceof Set?"set":t instanceof Map?"map":t instanceof Date?"date":typeof t=="boolean"?"boolean":typeof t=="string"?"string":typeof t=="object"?"object":Number.isNaN(t)?"any":"number"}var __defProp$k=Object.defineProperty,__getOwnPropSymbols$m=Object.getOwnPropertySymbols,__hasOwnProp$m=Object.prototype.hasOwnProperty,__propIsEnum$m=Object.prototype.propertyIsEnumerable,__defNormalProp$k=(t,e,l)=>e in t?__defProp$k(t,e,{enumerable:!0,configurable:!0,writable:!0,value:l}):t[e]=l,__spreadValues$k=(t,e)=>{for(var l in e||(e={}))__hasOwnProp$m.call(e,l)&&__defNormalProp$k(t,l,e[l]);if(__getOwnPropSymbols$m)for(var l of __getOwnPropSymbols$m(e))__propIsEnum$m.call(e,l)&&__defNormalProp$k(t,l,e[l]);return t};const StorageSerializers={boolean:{read:t=>t==="true",write:t=>String(t)},object:{read:t=>JSON.parse(t),write:t=>JSON.stringify(t)},number:{read:t=>Number.parseFloat(t),write:t=>String(t)},any:{read:t=>t,write:t=>String(t)},string:{read:t=>t,write:t=>String(t)},map:{read:t=>new Map(JSON.parse(t)),write:t=>JSON.stringify(Array.from(t.entries()))},set:{read:t=>new Set(JSON.parse(t)),write:t=>JSON.stringify(Array.from(t))},date:{read:t=>new Date(t),write:t=>t.toISOString()}},customStorageEventName="vueuse-storage";function useStorage(t,e,l,n={}){var u;const{flush:c="pre",deep:y=!0,listenToStorageChanges:b=!0,writeDefaults:m=!0,mergeDefaults:O=!1,shallow:N,window:L=defaultWindow,eventFilter:G,onError:q=Xe=>{console.error(Xe)}}=n,J=(N?shallowRef:ref)(e);if(!l)try{l=getSSRHandler("getDefaultStorage",()=>{var Xe;return(Xe=defaultWindow)==null?void 0:Xe.localStorage})()}catch(Xe){q(Xe)}if(!l)return J;const fe=resolveUnref(e),ve=guessSerializerType(fe),ne=(u=n.serializer)!=null?u:StorageSerializers[ve],{pause:Ue,resume:De}=watchPausable(J,()=>Ve(J.value),{flush:c,deep:y,eventFilter:G});return L&&b&&(useEventListener(L,"storage",Te),useEventListener(L,customStorageEventName,Ae)),Te(),J;function Ve(Xe){try{if(Xe==null)l.removeItem(t);else{const ie=ne.write(Xe),ue=l.getItem(t);ue!==ie&&(l.setItem(t,ie),L&&L.dispatchEvent(new CustomEvent(customStorageEventName,{detail:{key:t,oldValue:ue,newValue:ie,storageArea:l}})))}}catch(ie){q(ie)}}function rt(Xe){const ie=Xe?Xe.newValue:l.getItem(t);if(ie==null)return m&&fe!==null&&l.setItem(t,ne.write(fe)),fe;if(!Xe&&O){const ue=ne.read(ie);return isFunction$1(O)?O(ue,fe):ve==="object"&&!Array.isArray(ue)?__spreadValues$k(__spreadValues$k({},fe),ue):ue}else return typeof ie!="string"?ie:ne.read(ie)}function Ae(Xe){Te(Xe.detail)}function Te(Xe){if(!(Xe&&Xe.storageArea!==l)){if(Xe&&Xe.key==null){J.value=fe;return}if(!(Xe&&Xe.key!==t)){Ue();try{J.value=rt(Xe)}catch(ie){q(ie)}finally{Xe?nextTick(De):De()}}}}}function useConfirmDialog(t=ref(!1)){const e=createEventHook(),l=createEventHook(),n=createEventHook();let u=noop$2;const c=m=>(n.trigger(m),t.value=!0,new Promise(O=>{u=O})),y=m=>{t.value=!1,e.trigger(m),u({data:m,isCanceled:!1})},b=m=>{t.value=!1,l.trigger(m),u({data:m,isCanceled:!0})};return{isRevealed:computed(()=>t.value),reveal:c,confirm:y,cancel:b,onReveal:n.on,onConfirm:e.on,onCancel:l.on}}const defaultEvents=["mousedown","mouseup","keydown","keyup"];function useKeyModifier(t,e={}){const{events:l=defaultEvents,document:n=defaultDocument,initial:u=null}=e,c=ref(u);return n&&l.forEach(y=>{useEventListener(n,y,b=>{typeof b.getModifierState=="function"&&(c.value=b.getModifierState(t))})}),c}function useLocalStorage(t,e,l={}){const{window:n=defaultWindow}=l;return useStorage(t,e,n?.localStorage,l)}function useMouse(t={}){const{type:e="page",touch:l=!0,resetOnTouchEnds:n=!1,initialValue:u={x:0,y:0},window:c=defaultWindow,eventFilter:y}=t,b=ref(u.x),m=ref(u.y),O=ref(null),N=fe=>{e==="page"?(b.value=fe.pageX,m.value=fe.pageY):e==="client"?(b.value=fe.clientX,m.value=fe.clientY):e==="movement"&&(b.value=fe.movementX,m.value=fe.movementY),O.value="mouse"},L=()=>{b.value=u.x,m.value=u.y},G=fe=>{if(fe.touches.length>0){const ve=fe.touches[0];e==="page"?(b.value=ve.pageX,m.value=ve.pageY):e==="client"&&(b.value=ve.clientX,m.value=ve.clientY),O.value="touch"}},q=fe=>y===void 0?N(fe):y(()=>N(fe),{}),J=fe=>y===void 0?G(fe):y(()=>G(fe),{});return c&&(useEventListener(c,"mousemove",q,{passive:!0}),useEventListener(c,"dragover",q,{passive:!0}),l&&e!=="movement"&&(useEventListener(c,"touchstart",J,{passive:!0}),useEventListener(c,"touchmove",J,{passive:!0}),n&&useEventListener(c,"touchend",L,{passive:!0}))),{x:b,y:m,sourceType:O}}var SwipeDirection;(function(t){t.UP="UP",t.RIGHT="RIGHT",t.DOWN="DOWN",t.LEFT="LEFT",t.NONE="NONE"})(SwipeDirection||(SwipeDirection={}));var __defProp$4=Object.defineProperty,__getOwnPropSymbols$1=Object.getOwnPropertySymbols,__hasOwnProp$1=Object.prototype.hasOwnProperty,__propIsEnum$1=Object.prototype.propertyIsEnumerable,__defNormalProp$4=(t,e,l)=>e in t?__defProp$4(t,e,{enumerable:!0,configurable:!0,writable:!0,value:l}):t[e]=l,__spreadValues$1=(t,e)=>{for(var l in e||(e={}))__hasOwnProp$1.call(e,l)&&__defNormalProp$4(t,l,e[l]);if(__getOwnPropSymbols$1)for(var l of __getOwnPropSymbols$1(e))__propIsEnum$1.call(e,l)&&__defNormalProp$4(t,l,e[l]);return t};const _TransitionPresets={easeInSine:[.12,0,.39,0],easeOutSine:[.61,1,.88,1],easeInOutSine:[.37,0,.63,1],easeInQuad:[.11,0,.5,0],easeOutQuad:[.5,1,.89,1],easeInOutQuad:[.45,0,.55,1],easeInCubic:[.32,0,.67,0],easeOutCubic:[.33,1,.68,1],easeInOutCubic:[.65,0,.35,1],easeInQuart:[.5,0,.75,0],easeOutQuart:[.25,1,.5,1],easeInOutQuart:[.76,0,.24,1],easeInQuint:[.64,0,.78,0],easeOutQuint:[.22,1,.36,1],easeInOutQuint:[.83,0,.17,1],easeInExpo:[.7,0,.84,0],easeOutExpo:[.16,1,.3,1],easeInOutExpo:[.87,0,.13,1],easeInCirc:[.55,0,1,.45],easeOutCirc:[0,.55,.45,1],easeInOutCirc:[.85,0,.15,1],easeInBack:[.36,0,.66,-.56],easeOutBack:[.34,1.56,.64,1],easeInOutBack:[.68,-.6,.32,1.6]};__spreadValues$1({linear:identity},_TransitionPresets);const isCommandFocus=ref(!0),inputEl=ref(),useFocus$1=defineStore("focus",()=>{const t=c=>{isCommandFocus.value=c},e=new Set(["ArrowUp","ArrowDown","ArrowRight","ArrowLeft"]);return useEventListener("keydown",c=>{isCommandFocus.value&&document.activeElement!==inputEl.value&&!e.has(c.code)&&inputEl.value?.focus()}),{isCommandFocus,setCommandFocus:t,setInputEl:c=>{inputEl.value=c},destroyInputAutoFocus:()=>{inputEl.value=void 0},filterKeydownNotFocusCodes:e,inputEl}});var Status=(t=>(t[t.Off=0]="Off",t[t.On=1]="On",t))(Status||{});const __vite_glob_0_0=""+new URL("mxdrawassembly_min-CfChv3Vg.js",import.meta.url).href,__vite_glob_0_1=""+new URL("mxdrawassembly_min-CtXWQvKw.wasm",import.meta.url).href,__vite_glob_0_2=""+new URL("mxdrawassembly_min.worker-B6AbC3KO.js",import.meta.url).href,__vite_glob_1_0=""+new URL("mxdrawassembly_min-C3kJMNOg.js",import.meta.url).href,__vite_glob_1_1=""+new URL("mxdrawassembly_minst-CRsf2BRQ.wasm",import.meta.url).href;function _classCallCheck$1(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _typeof$2(t){"@babel/helpers - typeof";return _typeof$2=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof$2(t)}function toPrimitive$1(t,e){if(_typeof$2(t)!="object"||!t)return t;var l=t[Symbol.toPrimitive];if(l!==void 0){var n=l.call(t,e||"default");if(_typeof$2(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function toPropertyKey$1(t){var e=toPrimitive$1(t,"string");return _typeof$2(e)=="symbol"?e:String(e)}function _defineProperties$1(t,e){for(var l=0;l<e.length;l++){var n=e[l];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,toPropertyKey$1(n.key),n)}}function _createClass$1(t,e,l){return e&&_defineProperties$1(t.prototype,e),l&&_defineProperties$1(t,l),Object.defineProperty(t,"prototype",{writable:!1}),t}function _assertThisInitialized$1(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function _setPrototypeOf$1(t,e){return _setPrototypeOf$1=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,u){return n.__proto__=u,n},_setPrototypeOf$1(t,e)}function _inherits$1(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&_setPrototypeOf$1(t,e)}function _possibleConstructorReturn$1(t,e){if(e&&(_typeof$2(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return _assertThisInitialized$1(t)}function _getPrototypeOf$1(t){return _getPrototypeOf$1=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(l){return l.__proto__||Object.getPrototypeOf(l)},_getPrototypeOf$1(t)}function getAugmentedNamespace(t){var e=t.default;if(typeof e=="function"){var l=function(){return e.apply(this,arguments)};l.prototype=e.prototype}else l={};return Object.defineProperty(l,"__esModule",{value:!0}),Object.keys(t).forEach(function(n){var u=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(l,n,u.get?u:{enumerable:!0,get:function(){return t[n]}})}),l}var buffer$1={},base64Js={};base64Js.byteLength=byteLength;base64Js.toByteArray=toByteArray;base64Js.fromByteArray=fromByteArray;var lookup=[],revLookup=[],Arr=typeof Uint8Array<"u"?Uint8Array:Array,code="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(var i=0,len=code.length;i<len;++i)lookup[i]=code[i],revLookup[code.charCodeAt(i)]=i;revLookup[45]=62;revLookup[95]=63;function getLens(t){var e=t.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var l=t.indexOf("=");l===-1&&(l=e);var n=l===e?0:4-l%4;return[l,n]}function byteLength(t){var e=getLens(t),l=e[0],n=e[1];return(l+n)*3/4-n}function _byteLength(t,e,l){return(e+l)*3/4-l}function toByteArray(t){var e,l=getLens(t),n=l[0],u=l[1],c=new Arr(_byteLength(t,n,u)),y=0,b=u>0?n-4:n,m;for(m=0;m<b;m+=4)e=revLookup[t.charCodeAt(m)]<<18|revLookup[t.charCodeAt(m+1)]<<12|revLookup[t.charCodeAt(m+2)]<<6|revLookup[t.charCodeAt(m+3)],c[y++]=e>>16&255,c[y++]=e>>8&255,c[y++]=e&255;return u===2&&(e=revLookup[t.charCodeAt(m)]<<2|revLookup[t.charCodeAt(m+1)]>>4,c[y++]=e&255),u===1&&(e=revLookup[t.charCodeAt(m)]<<10|revLookup[t.charCodeAt(m+1)]<<4|revLookup[t.charCodeAt(m+2)]>>2,c[y++]=e>>8&255,c[y++]=e&255),c}function tripletToBase64(t){return lookup[t>>18&63]+lookup[t>>12&63]+lookup[t>>6&63]+lookup[t&63]}function encodeChunk(t,e,l){for(var n,u=[],c=e;c<l;c+=3)n=(t[c]<<16&16711680)+(t[c+1]<<8&65280)+(t[c+2]&255),u.push(tripletToBase64(n));return u.join("")}function fromByteArray(t){for(var e,l=t.length,n=l%3,u=[],c=16383,y=0,b=l-n;y<b;y+=c)u.push(encodeChunk(t,y,y+c>b?b:y+c));return n===1?(e=t[l-1],u.push(lookup[e>>2]+lookup[e<<4&63]+"==")):n===2&&(e=(t[l-2]<<8)+t[l-1],u.push(lookup[e>>10]+lookup[e>>4&63]+lookup[e<<2&63]+"=")),u.join("")}var ieee754={};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */ieee754.read=function(t,e,l,n,u){var c,y,b=u*8-n-1,m=(1<<b)-1,O=m>>1,N=-7,L=l?u-1:0,G=l?-1:1,q=t[e+L];for(L+=G,c=q&(1<<-N)-1,q>>=-N,N+=b;N>0;c=c*256+t[e+L],L+=G,N-=8);for(y=c&(1<<-N)-1,c>>=-N,N+=n;N>0;y=y*256+t[e+L],L+=G,N-=8);if(c===0)c=1-O;else{if(c===m)return y?NaN:(q?-1:1)*(1/0);y=y+Math.pow(2,n),c=c-O}return(q?-1:1)*y*Math.pow(2,c-n)};ieee754.write=function(t,e,l,n,u,c){var y,b,m,O=c*8-u-1,N=(1<<O)-1,L=N>>1,G=u===23?Math.pow(2,-24)-Math.pow(2,-77):0,q=n?0:c-1,J=n?1:-1,fe=e<0||e===0&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(b=isNaN(e)?1:0,y=N):(y=Math.floor(Math.log(e)/Math.LN2),e*(m=Math.pow(2,-y))<1&&(y--,m*=2),y+L>=1?e+=G/m:e+=G*Math.pow(2,1-L),e*m>=2&&(y++,m/=2),y+L>=N?(b=0,y=N):y+L>=1?(b=(e*m-1)*Math.pow(2,u),y=y+L):(b=e*Math.pow(2,L-1)*Math.pow(2,u),y=0));u>=8;t[l+q]=b&255,q+=J,b/=256,u-=8);for(y=y<<u|b,O+=u;O>0;t[l+q]=y&255,q+=J,y/=256,O-=8);t[l+q-J]|=fe*128};function _createSuper$7(t){var e=_isNativeReflectConstruct$7();return function(){var n=_getPrototypeOf$1(t),u;if(e){var c=_getPrototypeOf$1(this).constructor;u=Reflect.construct(n,arguments,c)}else u=n.apply(this,arguments);return _possibleConstructorReturn$1(this,u)}}function _isNativeReflectConstruct$7(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(function(t){var e=base64Js,l=ieee754,n=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=b,t.SlowBuffer=Ue,t.INSPECT_MAX_BYTES=50;var u=2147483647;t.kMaxLength=u,b.TYPED_ARRAY_SUPPORT=c(),!b.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function c(){try{var Nn=new Uint8Array(1),fn={foo:function(){return 42}};return Object.setPrototypeOf(fn,Uint8Array.prototype),Object.setPrototypeOf(Nn,fn),Nn.foo()===42}catch{return!1}}Object.defineProperty(b.prototype,"parent",{enumerable:!0,get:function(){if(b.isBuffer(this))return this.buffer}}),Object.defineProperty(b.prototype,"offset",{enumerable:!0,get:function(){if(b.isBuffer(this))return this.byteOffset}});function y(Nn){if(Nn>u)throw new RangeError('The value "'+Nn+'" is invalid for option "size"');var fn=new Uint8Array(Nn);return Object.setPrototypeOf(fn,b.prototype),fn}function b(Nn,fn,un){if(typeof Nn=="number"){if(typeof fn=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return L(Nn)}return m(Nn,fn,un)}b.poolSize=8192;function m(Nn,fn,un){if(typeof Nn=="string")return G(Nn,fn);if(ArrayBuffer.isView(Nn))return J(Nn);if(Nn==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+_typeof$2(Nn));if(ai(Nn,ArrayBuffer)||Nn&&ai(Nn.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(ai(Nn,SharedArrayBuffer)||Nn&&ai(Nn.buffer,SharedArrayBuffer)))return fe(Nn,fn,un);if(typeof Nn=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var Ln=Nn.valueOf&&Nn.valueOf();if(Ln!=null&&Ln!==Nn)return b.from(Ln,fn,un);var hr=ve(Nn);if(hr)return hr;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof Nn[Symbol.toPrimitive]=="function")return b.from(Nn[Symbol.toPrimitive]("string"),fn,un);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+_typeof$2(Nn))}b.from=function(Nn,fn,un){return m(Nn,fn,un)},Object.setPrototypeOf(b.prototype,Uint8Array.prototype),Object.setPrototypeOf(b,Uint8Array);function O(Nn){if(typeof Nn!="number")throw new TypeError('"size" argument must be of type number');if(Nn<0)throw new RangeError('The value "'+Nn+'" is invalid for option "size"')}function N(Nn,fn,un){return O(Nn),Nn<=0?y(Nn):fn!==void 0?typeof un=="string"?y(Nn).fill(fn,un):y(Nn).fill(fn):y(Nn)}b.alloc=function(Nn,fn,un){return N(Nn,fn,un)};function L(Nn){return O(Nn),y(Nn<0?0:ne(Nn)|0)}b.allocUnsafe=function(Nn){return L(Nn)},b.allocUnsafeSlow=function(Nn){return L(Nn)};function G(Nn,fn){if((typeof fn!="string"||fn==="")&&(fn="utf8"),!b.isEncoding(fn))throw new TypeError("Unknown encoding: "+fn);var un=De(Nn,fn)|0,Ln=y(un),hr=Ln.write(Nn,fn);return hr!==un&&(Ln=Ln.slice(0,hr)),Ln}function q(Nn){for(var fn=Nn.length<0?0:ne(Nn.length)|0,un=y(fn),Ln=0;Ln<fn;Ln+=1)un[Ln]=Nn[Ln]&255;return un}function J(Nn){if(ai(Nn,Uint8Array)){var fn=new Uint8Array(Nn);return fe(fn.buffer,fn.byteOffset,fn.byteLength)}return q(Nn)}function fe(Nn,fn,un){if(fn<0||Nn.byteLength<fn)throw new RangeError('"offset" is outside of buffer bounds');if(Nn.byteLength<fn+(un||0))throw new RangeError('"length" is outside of buffer bounds');var Ln;return fn===void 0&&un===void 0?Ln=new Uint8Array(Nn):un===void 0?Ln=new Uint8Array(Nn,fn):Ln=new Uint8Array(Nn,fn,un),Object.setPrototypeOf(Ln,b.prototype),Ln}function ve(Nn){if(b.isBuffer(Nn)){var fn=ne(Nn.length)|0,un=y(fn);return un.length===0||Nn.copy(un,0,0,fn),un}if(Nn.length!==void 0)return typeof Nn.length!="number"||Ia(Nn.length)?y(0):q(Nn);if(Nn.type==="Buffer"&&Array.isArray(Nn.data))return q(Nn.data)}function ne(Nn){if(Nn>=u)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+u.toString(16)+" bytes");return Nn|0}function Ue(Nn){return+Nn!=Nn&&(Nn=0),b.alloc(+Nn)}b.isBuffer=function(fn){return fn!=null&&fn._isBuffer===!0&&fn!==b.prototype},b.compare=function(fn,un){if(ai(fn,Uint8Array)&&(fn=b.from(fn,fn.offset,fn.byteLength)),ai(un,Uint8Array)&&(un=b.from(un,un.offset,un.byteLength)),!b.isBuffer(fn)||!b.isBuffer(un))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(fn===un)return 0;for(var Ln=fn.length,hr=un.length,hi=0,bi=Math.min(Ln,hr);hi<bi;++hi)if(fn[hi]!==un[hi]){Ln=fn[hi],hr=un[hi];break}return Ln<hr?-1:hr<Ln?1:0},b.isEncoding=function(fn){switch(String(fn).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},b.concat=function(fn,un){if(!Array.isArray(fn))throw new TypeError('"list" argument must be an Array of Buffers');if(fn.length===0)return b.alloc(0);var Ln;if(un===void 0)for(un=0,Ln=0;Ln<fn.length;++Ln)un+=fn[Ln].length;var hr=b.allocUnsafe(un),hi=0;for(Ln=0;Ln<fn.length;++Ln){var bi=fn[Ln];if(ai(bi,Uint8Array))hi+bi.length>hr.length?(b.isBuffer(bi)||(bi=b.from(bi)),bi.copy(hr,hi)):Uint8Array.prototype.set.call(hr,bi,hi);else if(b.isBuffer(bi))bi.copy(hr,hi);else throw new TypeError('"list" argument must be an Array of Buffers');hi+=bi.length}return hr};function De(Nn,fn){if(b.isBuffer(Nn))return Nn.length;if(ArrayBuffer.isView(Nn)||ai(Nn,ArrayBuffer))return Nn.byteLength;if(typeof Nn!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+_typeof$2(Nn));var un=Nn.length,Ln=arguments.length>2&&arguments[2]===!0;if(!Ln&&un===0)return 0;for(var hr=!1;;)switch(fn){case"ascii":case"latin1":case"binary":return un;case"utf8":case"utf-8":return Si(Nn).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return un*2;case"hex":return un>>>1;case"base64":return Wi(Nn).length;default:if(hr)return Ln?-1:Si(Nn).length;fn=(""+fn).toLowerCase(),hr=!0}}b.byteLength=De;function Ve(Nn,fn,un){var Ln=!1;if((fn===void 0||fn<0)&&(fn=0),fn>this.length||((un===void 0||un>this.length)&&(un=this.length),un<=0)||(un>>>=0,fn>>>=0,un<=fn))return"";for(Nn||(Nn="utf8");;)switch(Nn){case"hex":return _n(this,fn,un);case"utf8":case"utf-8":return kt(this,fn,un);case"ascii":return tn(this,fn,un);case"latin1":case"binary":return pn(this,fn,un);case"base64":return Tt(this,fn,un);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Dn(this,fn,un);default:if(Ln)throw new TypeError("Unknown encoding: "+Nn);Nn=(Nn+"").toLowerCase(),Ln=!0}}b.prototype._isBuffer=!0;function rt(Nn,fn,un){var Ln=Nn[fn];Nn[fn]=Nn[un],Nn[un]=Ln}b.prototype.swap16=function(){var fn=this.length;if(fn%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var un=0;un<fn;un+=2)rt(this,un,un+1);return this},b.prototype.swap32=function(){var fn=this.length;if(fn%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var un=0;un<fn;un+=4)rt(this,un,un+3),rt(this,un+1,un+2);return this},b.prototype.swap64=function(){var fn=this.length;if(fn%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var un=0;un<fn;un+=8)rt(this,un,un+7),rt(this,un+1,un+6),rt(this,un+2,un+5),rt(this,un+3,un+4);return this},b.prototype.toString=function(){var fn=this.length;return fn===0?"":arguments.length===0?kt(this,0,fn):Ve.apply(this,arguments)},b.prototype.toLocaleString=b.prototype.toString,b.prototype.equals=function(fn){if(!b.isBuffer(fn))throw new TypeError("Argument must be a Buffer");return this===fn?!0:b.compare(this,fn)===0},b.prototype.inspect=function(){var fn="",un=t.INSPECT_MAX_BYTES;return fn=this.toString("hex",0,un).replace(/(.{2})/g,"$1 ").trim(),this.length>un&&(fn+=" ... "),"<Buffer "+fn+">"},n&&(b.prototype[n]=b.prototype.inspect),b.prototype.compare=function(fn,un,Ln,hr,hi){if(ai(fn,Uint8Array)&&(fn=b.from(fn,fn.offset,fn.byteLength)),!b.isBuffer(fn))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+_typeof$2(fn));if(un===void 0&&(un=0),Ln===void 0&&(Ln=fn?fn.length:0),hr===void 0&&(hr=0),hi===void 0&&(hi=this.length),un<0||Ln>fn.length||hr<0||hi>this.length)throw new RangeError("out of range index");if(hr>=hi&&un>=Ln)return 0;if(hr>=hi)return-1;if(un>=Ln)return 1;if(un>>>=0,Ln>>>=0,hr>>>=0,hi>>>=0,this===fn)return 0;for(var bi=hi-hr,Ra=Ln-un,so=Math.min(bi,Ra),Pi=this.slice(hr,hi),oi=fn.slice(un,Ln),Ni=0;Ni<so;++Ni)if(Pi[Ni]!==oi[Ni]){bi=Pi[Ni],Ra=oi[Ni];break}return bi<Ra?-1:Ra<bi?1:0};function Ae(Nn,fn,un,Ln,hr){if(Nn.length===0)return-1;if(typeof un=="string"?(Ln=un,un=0):un>2147483647?un=2147483647:un<-2147483648&&(un=-2147483648),un=+un,Ia(un)&&(un=hr?0:Nn.length-1),un<0&&(un=Nn.length+un),un>=Nn.length){if(hr)return-1;un=Nn.length-1}else if(un<0)if(hr)un=0;else return-1;if(typeof fn=="string"&&(fn=b.from(fn,Ln)),b.isBuffer(fn))return fn.length===0?-1:Te(Nn,fn,un,Ln,hr);if(typeof fn=="number")return fn=fn&255,typeof Uint8Array.prototype.indexOf=="function"?hr?Uint8Array.prototype.indexOf.call(Nn,fn,un):Uint8Array.prototype.lastIndexOf.call(Nn,fn,un):Te(Nn,[fn],un,Ln,hr);throw new TypeError("val must be string, number or Buffer")}function Te(Nn,fn,un,Ln,hr){var hi=1,bi=Nn.length,Ra=fn.length;if(Ln!==void 0&&(Ln=String(Ln).toLowerCase(),Ln==="ucs2"||Ln==="ucs-2"||Ln==="utf16le"||Ln==="utf-16le")){if(Nn.length<2||fn.length<2)return-1;hi=2,bi/=2,Ra/=2,un/=2}function so(ki,Aa){return hi===1?ki[Aa]:ki.readUInt16BE(Aa*hi)}var Pi;if(hr){var oi=-1;for(Pi=un;Pi<bi;Pi++)if(so(Nn,Pi)===so(fn,oi===-1?0:Pi-oi)){if(oi===-1&&(oi=Pi),Pi-oi+1===Ra)return oi*hi}else oi!==-1&&(Pi-=Pi-oi),oi=-1}else for(un+Ra>bi&&(un=bi-Ra),Pi=un;Pi>=0;Pi--){for(var Ni=!0,za=0;za<Ra;za++)if(so(Nn,Pi+za)!==so(fn,za)){Ni=!1;break}if(Ni)return Pi}return-1}b.prototype.includes=function(fn,un,Ln){return this.indexOf(fn,un,Ln)!==-1},b.prototype.indexOf=function(fn,un,Ln){return Ae(this,fn,un,Ln,!0)},b.prototype.lastIndexOf=function(fn,un,Ln){return Ae(this,fn,un,Ln,!1)};function Xe(Nn,fn,un,Ln){un=Number(un)||0;var hr=Nn.length-un;Ln?(Ln=Number(Ln),Ln>hr&&(Ln=hr)):Ln=hr;var hi=fn.length;Ln>hi/2&&(Ln=hi/2);var bi;for(bi=0;bi<Ln;++bi){var Ra=parseInt(fn.substr(bi*2,2),16);if(Ia(Ra))return bi;Nn[un+bi]=Ra}return bi}function ie(Nn,fn,un,Ln){return ha(Si(fn,Nn.length-un),Nn,un,Ln)}function ue(Nn,fn,un,Ln){return ha(qn(fn),Nn,un,Ln)}function pt(Nn,fn,un,Ln){return ha(Wi(fn),Nn,un,Ln)}function mt(Nn,fn,un,Ln){return ha(ia(fn,Nn.length-un),Nn,un,Ln)}b.prototype.write=function(fn,un,Ln,hr){if(un===void 0)hr="utf8",Ln=this.length,un=0;else if(Ln===void 0&&typeof un=="string")hr=un,Ln=this.length,un=0;else if(isFinite(un))un=un>>>0,isFinite(Ln)?(Ln=Ln>>>0,hr===void 0&&(hr="utf8")):(hr=Ln,Ln=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var hi=this.length-un;if((Ln===void 0||Ln>hi)&&(Ln=hi),fn.length>0&&(Ln<0||un<0)||un>this.length)throw new RangeError("Attempt to write outside buffer bounds");hr||(hr="utf8");for(var bi=!1;;)switch(hr){case"hex":return Xe(this,fn,un,Ln);case"utf8":case"utf-8":return ie(this,fn,un,Ln);case"ascii":case"latin1":case"binary":return ue(this,fn,un,Ln);case"base64":return pt(this,fn,un,Ln);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return mt(this,fn,un,Ln);default:if(bi)throw new TypeError("Unknown encoding: "+hr);hr=(""+hr).toLowerCase(),bi=!0}},b.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function Tt(Nn,fn,un){return fn===0&&un===Nn.length?e.fromByteArray(Nn):e.fromByteArray(Nn.slice(fn,un))}function kt(Nn,fn,un){un=Math.min(Nn.length,un);for(var Ln=[],hr=fn;hr<un;){var hi=Nn[hr],bi=null,Ra=hi>239?4:hi>223?3:hi>191?2:1;if(hr+Ra<=un){var so=void 0,Pi=void 0,oi=void 0,Ni=void 0;switch(Ra){case 1:hi<128&&(bi=hi);break;case 2:so=Nn[hr+1],(so&192)===128&&(Ni=(hi&31)<<6|so&63,Ni>127&&(bi=Ni));break;case 3:so=Nn[hr+1],Pi=Nn[hr+2],(so&192)===128&&(Pi&192)===128&&(Ni=(hi&15)<<12|(so&63)<<6|Pi&63,Ni>2047&&(Ni<55296||Ni>57343)&&(bi=Ni));break;case 4:so=Nn[hr+1],Pi=Nn[hr+2],oi=Nn[hr+3],(so&192)===128&&(Pi&192)===128&&(oi&192)===128&&(Ni=(hi&15)<<18|(so&63)<<12|(Pi&63)<<6|oi&63,Ni>65535&&Ni<1114112&&(bi=Ni))}}bi===null?(bi=65533,Ra=1):bi>65535&&(bi-=65536,Ln.push(bi>>>10&1023|55296),bi=56320|bi&1023),Ln.push(bi),hr+=Ra}return nn(Ln)}var It=4096;function nn(Nn){var fn=Nn.length;if(fn<=It)return String.fromCharCode.apply(String,Nn);for(var un="",Ln=0;Ln<fn;)un+=String.fromCharCode.apply(String,Nn.slice(Ln,Ln+=It));return un}function tn(Nn,fn,un){var Ln="";un=Math.min(Nn.length,un);for(var hr=fn;hr<un;++hr)Ln+=String.fromCharCode(Nn[hr]&127);return Ln}function pn(Nn,fn,un){var Ln="";un=Math.min(Nn.length,un);for(var hr=fn;hr<un;++hr)Ln+=String.fromCharCode(Nn[hr]);return Ln}function _n(Nn,fn,un){var Ln=Nn.length;(!fn||fn<0)&&(fn=0),(!un||un<0||un>Ln)&&(un=Ln);for(var hr="",hi=fn;hi<un;++hi)hr+=fi[Nn[hi]];return hr}function Dn(Nn,fn,un){for(var Ln=Nn.slice(fn,un),hr="",hi=0;hi<Ln.length-1;hi+=2)hr+=String.fromCharCode(Ln[hi]+Ln[hi+1]*256);return hr}b.prototype.slice=function(fn,un){var Ln=this.length;fn=~~fn,un=un===void 0?Ln:~~un,fn<0?(fn+=Ln,fn<0&&(fn=0)):fn>Ln&&(fn=Ln),un<0?(un+=Ln,un<0&&(un=0)):un>Ln&&(un=Ln),un<fn&&(un=fn);var hr=this.subarray(fn,un);return Object.setPrototypeOf(hr,b.prototype),hr};function an(Nn,fn,un){if(Nn%1!==0||Nn<0)throw new RangeError("offset is not uint");if(Nn+fn>un)throw new RangeError("Trying to access beyond buffer length")}b.prototype.readUintLE=b.prototype.readUIntLE=function(fn,un,Ln){fn=fn>>>0,un=un>>>0,Ln||an(fn,un,this.length);for(var hr=this[fn],hi=1,bi=0;++bi<un&&(hi*=256);)hr+=this[fn+bi]*hi;return hr},b.prototype.readUintBE=b.prototype.readUIntBE=function(fn,un,Ln){fn=fn>>>0,un=un>>>0,Ln||an(fn,un,this.length);for(var hr=this[fn+--un],hi=1;un>0&&(hi*=256);)hr+=this[fn+--un]*hi;return hr},b.prototype.readUint8=b.prototype.readUInt8=function(fn,un){return fn=fn>>>0,un||an(fn,1,this.length),this[fn]},b.prototype.readUint16LE=b.prototype.readUInt16LE=function(fn,un){return fn=fn>>>0,un||an(fn,2,this.length),this[fn]|this[fn+1]<<8},b.prototype.readUint16BE=b.prototype.readUInt16BE=function(fn,un){return fn=fn>>>0,un||an(fn,2,this.length),this[fn]<<8|this[fn+1]},b.prototype.readUint32LE=b.prototype.readUInt32LE=function(fn,un){return fn=fn>>>0,un||an(fn,4,this.length),(this[fn]|this[fn+1]<<8|this[fn+2]<<16)+this[fn+3]*16777216},b.prototype.readUint32BE=b.prototype.readUInt32BE=function(fn,un){return fn=fn>>>0,un||an(fn,4,this.length),this[fn]*16777216+(this[fn+1]<<16|this[fn+2]<<8|this[fn+3])},b.prototype.readBigUInt64LE=An(function(fn){fn=fn>>>0,Vn(fn,"offset");var un=this[fn],Ln=this[fn+7];(un===void 0||Ln===void 0)&&Yn(fn,this.length-8);var hr=un+this[++fn]*Math.pow(2,8)+this[++fn]*Math.pow(2,16)+this[++fn]*Math.pow(2,24),hi=this[++fn]+this[++fn]*Math.pow(2,8)+this[++fn]*Math.pow(2,16)+Ln*Math.pow(2,24);return BigInt(hr)+(BigInt(hi)<<BigInt(32))}),b.prototype.readBigUInt64BE=An(function(fn){fn=fn>>>0,Vn(fn,"offset");var un=this[fn],Ln=this[fn+7];(un===void 0||Ln===void 0)&&Yn(fn,this.length-8);var hr=un*Math.pow(2,24)+this[++fn]*Math.pow(2,16)+this[++fn]*Math.pow(2,8)+this[++fn],hi=this[++fn]*Math.pow(2,24)+this[++fn]*Math.pow(2,16)+this[++fn]*Math.pow(2,8)+Ln;return(BigInt(hr)<<BigInt(32))+BigInt(hi)}),b.prototype.readIntLE=function(fn,un,Ln){fn=fn>>>0,un=un>>>0,Ln||an(fn,un,this.length);for(var hr=this[fn],hi=1,bi=0;++bi<un&&(hi*=256);)hr+=this[fn+bi]*hi;return hi*=128,hr>=hi&&(hr-=Math.pow(2,8*un)),hr},b.prototype.readIntBE=function(fn,un,Ln){fn=fn>>>0,un=un>>>0,Ln||an(fn,un,this.length);for(var hr=un,hi=1,bi=this[fn+--hr];hr>0&&(hi*=256);)bi+=this[fn+--hr]*hi;return hi*=128,bi>=hi&&(bi-=Math.pow(2,8*un)),bi},b.prototype.readInt8=function(fn,un){return fn=fn>>>0,un||an(fn,1,this.length),this[fn]&128?(255-this[fn]+1)*-1:this[fn]},b.prototype.readInt16LE=function(fn,un){fn=fn>>>0,un||an(fn,2,this.length);var Ln=this[fn]|this[fn+1]<<8;return Ln&32768?Ln|4294901760:Ln},b.prototype.readInt16BE=function(fn,un){fn=fn>>>0,un||an(fn,2,this.length);var Ln=this[fn+1]|this[fn]<<8;return Ln&32768?Ln|4294901760:Ln},b.prototype.readInt32LE=function(fn,un){return fn=fn>>>0,un||an(fn,4,this.length),this[fn]|this[fn+1]<<8|this[fn+2]<<16|this[fn+3]<<24},b.prototype.readInt32BE=function(fn,un){return fn=fn>>>0,un||an(fn,4,this.length),this[fn]<<24|this[fn+1]<<16|this[fn+2]<<8|this[fn+3]},b.prototype.readBigInt64LE=An(function(fn){fn=fn>>>0,Vn(fn,"offset");var un=this[fn],Ln=this[fn+7];(un===void 0||Ln===void 0)&&Yn(fn,this.length-8);var hr=this[fn+4]+this[fn+5]*Math.pow(2,8)+this[fn+6]*Math.pow(2,16)+(Ln<<24);return(BigInt(hr)<<BigInt(32))+BigInt(un+this[++fn]*Math.pow(2,8)+this[++fn]*Math.pow(2,16)+this[++fn]*Math.pow(2,24))}),b.prototype.readBigInt64BE=An(function(fn){fn=fn>>>0,Vn(fn,"offset");var un=this[fn],Ln=this[fn+7];(un===void 0||Ln===void 0)&&Yn(fn,this.length-8);var hr=(un<<24)+this[++fn]*Math.pow(2,16)+this[++fn]*Math.pow(2,8)+this[++fn];return(BigInt(hr)<<BigInt(32))+BigInt(this[++fn]*Math.pow(2,24)+this[++fn]*Math.pow(2,16)+this[++fn]*Math.pow(2,8)+Ln)}),b.prototype.readFloatLE=function(fn,un){return fn=fn>>>0,un||an(fn,4,this.length),l.read(this,fn,!0,23,4)},b.prototype.readFloatBE=function(fn,un){return fn=fn>>>0,un||an(fn,4,this.length),l.read(this,fn,!1,23,4)},b.prototype.readDoubleLE=function(fn,un){return fn=fn>>>0,un||an(fn,8,this.length),l.read(this,fn,!0,52,8)},b.prototype.readDoubleBE=function(fn,un){return fn=fn>>>0,un||an(fn,8,this.length),l.read(this,fn,!1,52,8)};function Rn(Nn,fn,un,Ln,hr,hi){if(!b.isBuffer(Nn))throw new TypeError('"buffer" argument must be a Buffer instance');if(fn>hr||fn<hi)throw new RangeError('"value" argument is out of bounds');if(un+Ln>Nn.length)throw new RangeError("Index out of range")}b.prototype.writeUintLE=b.prototype.writeUIntLE=function(fn,un,Ln,hr){if(fn=+fn,un=un>>>0,Ln=Ln>>>0,!hr){var hi=Math.pow(2,8*Ln)-1;Rn(this,fn,un,Ln,hi,0)}var bi=1,Ra=0;for(this[un]=fn&255;++Ra<Ln&&(bi*=256);)this[un+Ra]=fn/bi&255;return un+Ln},b.prototype.writeUintBE=b.prototype.writeUIntBE=function(fn,un,Ln,hr){if(fn=+fn,un=un>>>0,Ln=Ln>>>0,!hr){var hi=Math.pow(2,8*Ln)-1;Rn(this,fn,un,Ln,hi,0)}var bi=Ln-1,Ra=1;for(this[un+bi]=fn&255;--bi>=0&&(Ra*=256);)this[un+bi]=fn/Ra&255;return un+Ln},b.prototype.writeUint8=b.prototype.writeUInt8=function(fn,un,Ln){return fn=+fn,un=un>>>0,Ln||Rn(this,fn,un,1,255,0),this[un]=fn&255,un+1},b.prototype.writeUint16LE=b.prototype.writeUInt16LE=function(fn,un,Ln){return fn=+fn,un=un>>>0,Ln||Rn(this,fn,un,2,65535,0),this[un]=fn&255,this[un+1]=fn>>>8,un+2},b.prototype.writeUint16BE=b.prototype.writeUInt16BE=function(fn,un,Ln){return fn=+fn,un=un>>>0,Ln||Rn(this,fn,un,2,65535,0),this[un]=fn>>>8,this[un+1]=fn&255,un+2},b.prototype.writeUint32LE=b.prototype.writeUInt32LE=function(fn,un,Ln){return fn=+fn,un=un>>>0,Ln||Rn(this,fn,un,4,4294967295,0),this[un+3]=fn>>>24,this[un+2]=fn>>>16,this[un+1]=fn>>>8,this[un]=fn&255,un+4},b.prototype.writeUint32BE=b.prototype.writeUInt32BE=function(fn,un,Ln){return fn=+fn,un=un>>>0,Ln||Rn(this,fn,un,4,4294967295,0),this[un]=fn>>>24,this[un+1]=fn>>>16,this[un+2]=fn>>>8,this[un+3]=fn&255,un+4};function Lt(Nn,fn,un,Ln,hr){Kn(fn,Ln,hr,Nn,un,7);var hi=Number(fn&BigInt(4294967295));Nn[un++]=hi,hi=hi>>8,Nn[un++]=hi,hi=hi>>8,Nn[un++]=hi,hi=hi>>8,Nn[un++]=hi;var bi=Number(fn>>BigInt(32)&BigInt(4294967295));return Nn[un++]=bi,bi=bi>>8,Nn[un++]=bi,bi=bi>>8,Nn[un++]=bi,bi=bi>>8,Nn[un++]=bi,un}function wn(Nn,fn,un,Ln,hr){Kn(fn,Ln,hr,Nn,un,7);var hi=Number(fn&BigInt(4294967295));Nn[un+7]=hi,hi=hi>>8,Nn[un+6]=hi,hi=hi>>8,Nn[un+5]=hi,hi=hi>>8,Nn[un+4]=hi;var bi=Number(fn>>BigInt(32)&BigInt(4294967295));return Nn[un+3]=bi,bi=bi>>8,Nn[un+2]=bi,bi=bi>>8,Nn[un+1]=bi,bi=bi>>8,Nn[un]=bi,un+8}b.prototype.writeBigUInt64LE=An(function(fn){var un=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return Lt(this,fn,un,BigInt(0),BigInt("0xffffffffffffffff"))}),b.prototype.writeBigUInt64BE=An(function(fn){var un=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return wn(this,fn,un,BigInt(0),BigInt("0xffffffffffffffff"))}),b.prototype.writeIntLE=function(fn,un,Ln,hr){if(fn=+fn,un=un>>>0,!hr){var hi=Math.pow(2,8*Ln-1);Rn(this,fn,un,Ln,hi-1,-hi)}var bi=0,Ra=1,so=0;for(this[un]=fn&255;++bi<Ln&&(Ra*=256);)fn<0&&so===0&&this[un+bi-1]!==0&&(so=1),this[un+bi]=(fn/Ra>>0)-so&255;return un+Ln},b.prototype.writeIntBE=function(fn,un,Ln,hr){if(fn=+fn,un=un>>>0,!hr){var hi=Math.pow(2,8*Ln-1);Rn(this,fn,un,Ln,hi-1,-hi)}var bi=Ln-1,Ra=1,so=0;for(this[un+bi]=fn&255;--bi>=0&&(Ra*=256);)fn<0&&so===0&&this[un+bi+1]!==0&&(so=1),this[un+bi]=(fn/Ra>>0)-so&255;return un+Ln},b.prototype.writeInt8=function(fn,un,Ln){return fn=+fn,un=un>>>0,Ln||Rn(this,fn,un,1,127,-128),fn<0&&(fn=255+fn+1),this[un]=fn&255,un+1},b.prototype.writeInt16LE=function(fn,un,Ln){return fn=+fn,un=un>>>0,Ln||Rn(this,fn,un,2,32767,-32768),this[un]=fn&255,this[un+1]=fn>>>8,un+2},b.prototype.writeInt16BE=function(fn,un,Ln){return fn=+fn,un=un>>>0,Ln||Rn(this,fn,un,2,32767,-32768),this[un]=fn>>>8,this[un+1]=fn&255,un+2},b.prototype.writeInt32LE=function(fn,un,Ln){return fn=+fn,un=un>>>0,Ln||Rn(this,fn,un,4,2147483647,-2147483648),this[un]=fn&255,this[un+1]=fn>>>8,this[un+2]=fn>>>16,this[un+3]=fn>>>24,un+4},b.prototype.writeInt32BE=function(fn,un,Ln){return fn=+fn,un=un>>>0,Ln||Rn(this,fn,un,4,2147483647,-2147483648),fn<0&&(fn=4294967295+fn+1),this[un]=fn>>>24,this[un+1]=fn>>>16,this[un+2]=fn>>>8,this[un+3]=fn&255,un+4},b.prototype.writeBigInt64LE=An(function(fn){var un=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return Lt(this,fn,un,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),b.prototype.writeBigInt64BE=An(function(fn){var un=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return wn(this,fn,un,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function hn(Nn,fn,un,Ln,hr,hi){if(un+Ln>Nn.length)throw new RangeError("Index out of range");if(un<0)throw new RangeError("Index out of range")}function xn(Nn,fn,un,Ln,hr){return fn=+fn,un=un>>>0,hr||hn(Nn,fn,un,4),l.write(Nn,fn,un,Ln,23,4),un+4}b.prototype.writeFloatLE=function(fn,un,Ln){return xn(this,fn,un,!0,Ln)},b.prototype.writeFloatBE=function(fn,un,Ln){return xn(this,fn,un,!1,Ln)};function $n(Nn,fn,un,Ln,hr){return fn=+fn,un=un>>>0,hr||hn(Nn,fn,un,8),l.write(Nn,fn,un,Ln,52,8),un+8}b.prototype.writeDoubleLE=function(fn,un,Ln){return $n(this,fn,un,!0,Ln)},b.prototype.writeDoubleBE=function(fn,un,Ln){return $n(this,fn,un,!1,Ln)},b.prototype.copy=function(fn,un,Ln,hr){if(!b.isBuffer(fn))throw new TypeError("argument should be a Buffer");if(Ln||(Ln=0),!hr&&hr!==0&&(hr=this.length),un>=fn.length&&(un=fn.length),un||(un=0),hr>0&&hr<Ln&&(hr=Ln),hr===Ln||fn.length===0||this.length===0)return 0;if(un<0)throw new RangeError("targetStart out of bounds");if(Ln<0||Ln>=this.length)throw new RangeError("Index out of range");if(hr<0)throw new RangeError("sourceEnd out of bounds");hr>this.length&&(hr=this.length),fn.length-un<hr-Ln&&(hr=fn.length-un+Ln);var hi=hr-Ln;return this===fn&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(un,Ln,hr):Uint8Array.prototype.set.call(fn,this.subarray(Ln,hr),un),hi},b.prototype.fill=function(fn,un,Ln,hr){if(typeof fn=="string"){if(typeof un=="string"?(hr=un,un=0,Ln=this.length):typeof Ln=="string"&&(hr=Ln,Ln=this.length),hr!==void 0&&typeof hr!="string")throw new TypeError("encoding must be a string");if(typeof hr=="string"&&!b.isEncoding(hr))throw new TypeError("Unknown encoding: "+hr);if(fn.length===1){var hi=fn.charCodeAt(0);(hr==="utf8"&&hi<128||hr==="latin1")&&(fn=hi)}}else typeof fn=="number"?fn=fn&255:typeof fn=="boolean"&&(fn=Number(fn));if(un<0||this.length<un||this.length<Ln)throw new RangeError("Out of range index");if(Ln<=un)return this;un=un>>>0,Ln=Ln===void 0?this.length:Ln>>>0,fn||(fn=0);var bi;if(typeof fn=="number")for(bi=un;bi<Ln;++bi)this[bi]=fn;else{var Ra=b.isBuffer(fn)?fn:b.from(fn,hr),so=Ra.length;if(so===0)throw new TypeError('The value "'+fn+'" is invalid for argument "value"');for(bi=0;bi<Ln-un;++bi)this[bi+un]=Ra[bi%so]}return this};var Xr={};function ti(Nn,fn,un){Xr[Nn]=function(Ln){_inherits$1(hi,Ln);var hr=_createSuper$7(hi);function hi(){var bi;return _classCallCheck$1(this,hi),bi=hr.call(this),Object.defineProperty(_assertThisInitialized$1(bi),"message",{value:fn.apply(_assertThisInitialized$1(bi),arguments),writable:!0,configurable:!0}),bi.name="".concat(bi.name," [").concat(Nn,"]"),bi.stack,delete bi.name,bi}return _createClass$1(hi,[{key:"code",get:function(){return Nn},set:function(Ra){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:Ra,writable:!0})}},{key:"toString",value:function(){return"".concat(this.name," [").concat(Nn,"]: ").concat(this.message)}}]),hi}(un)}ti("ERR_BUFFER_OUT_OF_BOUNDS",function(Nn){return Nn?"".concat(Nn," is outside of buffer bounds"):"Attempt to access memory outside buffer bounds"},RangeError),ti("ERR_INVALID_ARG_TYPE",function(Nn,fn){return'The "'.concat(Nn,'" argument must be of type number. Received type ').concat(_typeof$2(fn))},TypeError),ti("ERR_OUT_OF_RANGE",function(Nn,fn,un){var Ln='The value of "'.concat(Nn,'" is out of range.'),hr=un;return Number.isInteger(un)&&Math.abs(un)>Math.pow(2,32)?hr=gn(String(un)):typeof un=="bigint"&&(hr=String(un),(un>Math.pow(BigInt(2),BigInt(32))||un<-Math.pow(BigInt(2),BigInt(32)))&&(hr=gn(hr)),hr+="n"),Ln+=" It must be ".concat(fn,". Received ").concat(hr),Ln},RangeError);function gn(Nn){for(var fn="",un=Nn.length,Ln=Nn[0]==="-"?1:0;un>=Ln+4;un-=3)fn="_".concat(Nn.slice(un-3,un)).concat(fn);return"".concat(Nn.slice(0,un)).concat(fn)}function Xn(Nn,fn,un){Vn(fn,"offset"),(Nn[fn]===void 0||Nn[fn+un]===void 0)&&Yn(fn,Nn.length-(un+1))}function Kn(Nn,fn,un,Ln,hr,hi){if(Nn>un||Nn<fn){var bi=typeof fn=="bigint"?"n":"",Ra;throw fn===0||fn===BigInt(0)?Ra=">= 0".concat(bi," and < 2").concat(bi," ** ").concat((hi+1)*8).concat(bi):Ra=">= -(2".concat(bi," ** ").concat((hi+1)*8-1).concat(bi,") and < 2 ** ")+"".concat((hi+1)*8-1).concat(bi),new Xr.ERR_OUT_OF_RANGE("value",Ra,Nn)}Xn(Ln,hr,hi)}function Vn(Nn,fn){if(typeof Nn!="number")throw new Xr.ERR_INVALID_ARG_TYPE(fn,"number",Nn)}function Yn(Nn,fn,un){throw Math.floor(Nn)!==Nn?(Vn(Nn,un),new Xr.ERR_OUT_OF_RANGE("offset","an integer",Nn)):fn<0?new Xr.ERR_BUFFER_OUT_OF_BOUNDS:new Xr.ERR_OUT_OF_RANGE("offset",">= ".concat(0," and <= ").concat(fn),Nn)}var Vr=/[^+/0-9A-Za-z-_]/g;function xi(Nn){if(Nn=Nn.split("=")[0],Nn=Nn.trim().replace(Vr,""),Nn.length<2)return"";for(;Nn.length%4!==0;)Nn=Nn+"=";return Nn}function Si(Nn,fn){fn=fn||1/0;for(var un,Ln=Nn.length,hr=null,hi=[],bi=0;bi<Ln;++bi){if(un=Nn.charCodeAt(bi),un>55295&&un<57344){if(!hr){if(un>56319){(fn-=3)>-1&&hi.push(239,191,189);continue}else if(bi+1===Ln){(fn-=3)>-1&&hi.push(239,191,189);continue}hr=un;continue}if(un<56320){(fn-=3)>-1&&hi.push(239,191,189),hr=un;continue}un=(hr-55296<<10|un-56320)+65536}else hr&&(fn-=3)>-1&&hi.push(239,191,189);if(hr=null,un<128){if((fn-=1)<0)break;hi.push(un)}else if(un<2048){if((fn-=2)<0)break;hi.push(un>>6|192,un&63|128)}else if(un<65536){if((fn-=3)<0)break;hi.push(un>>12|224,un>>6&63|128,un&63|128)}else if(un<1114112){if((fn-=4)<0)break;hi.push(un>>18|240,un>>12&63|128,un>>6&63|128,un&63|128)}else throw new Error("Invalid code point")}return hi}function qn(Nn){for(var fn=[],un=0;un<Nn.length;++un)fn.push(Nn.charCodeAt(un)&255);return fn}function ia(Nn,fn){for(var un,Ln,hr,hi=[],bi=0;bi<Nn.length&&!((fn-=2)<0);++bi)un=Nn.charCodeAt(bi),Ln=un>>8,hr=un%256,hi.push(hr),hi.push(Ln);return hi}function Wi(Nn){return e.toByteArray(xi(Nn))}function ha(Nn,fn,un,Ln){var hr;for(hr=0;hr<Ln&&!(hr+un>=fn.length||hr>=Nn.length);++hr)fn[hr+un]=Nn[hr];return hr}function ai(Nn,fn){return Nn instanceof fn||Nn!=null&&Nn.constructor!=null&&Nn.constructor.name!=null&&Nn.constructor.name===fn.name}function Ia(Nn){return Nn!==Nn}var fi=function(){for(var Nn="0123456789abcdef",fn=new Array(256),un=0;un<16;++un)for(var Ln=un*16,hr=0;hr<16;++hr)fn[Ln+hr]=Nn[un]+Nn[hr];return fn}();function An(Nn){return typeof BigInt>"u"?sa:Nn}function sa(){throw new Error("BigInt not supported")}})(buffer$1);function asyncGeneratorStep(t,e,l,n,u,c,y){try{var b=t[c](y),m=b.value}catch(O){l(O);return}b.done?e(m):Promise.resolve(m).then(n,u)}function _asyncToGenerator(t){return function(){var e=this,l=arguments;return new Promise(function(n,u){var c=t.apply(e,l);function y(m){asyncGeneratorStep(c,n,u,y,b,"next",m)}function b(m){asyncGeneratorStep(c,n,u,y,b,"throw",m)}y(void 0)})}}var regeneratorRuntime$1={exports:{}},_typeof$1={exports:{}};(function(t){function e(l){"@babel/helpers - typeof";return t.exports=e=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},t.exports.__esModule=!0,t.exports.default=t.exports,e(l)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports})(_typeof$1);(function(t){var e=_typeof$1.exports.default;function l(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */t.exports=l=function(){return u},t.exports.__esModule=!0,t.exports.default=t.exports;var n,u={},c=Object.prototype,y=c.hasOwnProperty,b=Object.defineProperty||function(_n,Dn,an){_n[Dn]=an.value},m=typeof Symbol=="function"?Symbol:{},O=m.iterator||"@@iterator",N=m.asyncIterator||"@@asyncIterator",L=m.toStringTag||"@@toStringTag";function G(_n,Dn,an){return Object.defineProperty(_n,Dn,{value:an,enumerable:!0,configurable:!0,writable:!0}),_n[Dn]}try{G({},"")}catch{G=function(an,Rn,Lt){return an[Rn]=Lt}}function q(_n,Dn,an,Rn){var Lt=Dn&&Dn.prototype instanceof Ve?Dn:Ve,wn=Object.create(Lt.prototype),hn=new tn(Rn||[]);return b(wn,"_invoke",{value:Tt(_n,an,hn)}),wn}function J(_n,Dn,an){try{return{type:"normal",arg:_n.call(Dn,an)}}catch(Rn){return{type:"throw",arg:Rn}}}u.wrap=q;var fe="suspendedStart",ve="suspendedYield",ne="executing",Ue="completed",De={};function Ve(){}function rt(){}function Ae(){}var Te={};G(Te,O,function(){return this});var Xe=Object.getPrototypeOf,ie=Xe&&Xe(Xe(pn([])));ie&&ie!==c&&y.call(ie,O)&&(Te=ie);var ue=Ae.prototype=Ve.prototype=Object.create(Te);function pt(_n){["next","throw","return"].forEach(function(Dn){G(_n,Dn,function(an){return this._invoke(Dn,an)})})}function mt(_n,Dn){function an(Lt,wn,hn,xn){var $n=J(_n[Lt],_n,wn);if($n.type!=="throw"){var Xr=$n.arg,ti=Xr.value;return ti&&e(ti)=="object"&&y.call(ti,"__await")?Dn.resolve(ti.__await).then(function(gn){an("next",gn,hn,xn)},function(gn){an("throw",gn,hn,xn)}):Dn.resolve(ti).then(function(gn){Xr.value=gn,hn(Xr)},function(gn){return an("throw",gn,hn,xn)})}xn($n.arg)}var Rn;b(this,"_invoke",{value:function(wn,hn){function xn(){return new Dn(function($n,Xr){an(wn,hn,$n,Xr)})}return Rn=Rn?Rn.then(xn,xn):xn()}})}function Tt(_n,Dn,an){var Rn=fe;return function(Lt,wn){if(Rn===ne)throw new Error("Generator is already running");if(Rn===Ue){if(Lt==="throw")throw wn;return{value:n,done:!0}}for(an.method=Lt,an.arg=wn;;){var hn=an.delegate;if(hn){var xn=kt(hn,an);if(xn){if(xn===De)continue;return xn}}if(an.method==="next")an.sent=an._sent=an.arg;else if(an.method==="throw"){if(Rn===fe)throw Rn=Ue,an.arg;an.dispatchException(an.arg)}else an.method==="return"&&an.abrupt("return",an.arg);Rn=ne;var $n=J(_n,Dn,an);if($n.type==="normal"){if(Rn=an.done?Ue:ve,$n.arg===De)continue;return{value:$n.arg,done:an.done}}$n.type==="throw"&&(Rn=Ue,an.method="throw",an.arg=$n.arg)}}}function kt(_n,Dn){var an=Dn.method,Rn=_n.iterator[an];if(Rn===n)return Dn.delegate=null,an==="throw"&&_n.iterator.return&&(Dn.method="return",Dn.arg=n,kt(_n,Dn),Dn.method==="throw")||an!=="return"&&(Dn.method="throw",Dn.arg=new TypeError("The iterator does not provide a '"+an+"' method")),De;var Lt=J(Rn,_n.iterator,Dn.arg);if(Lt.type==="throw")return Dn.method="throw",Dn.arg=Lt.arg,Dn.delegate=null,De;var wn=Lt.arg;return wn?wn.done?(Dn[_n.resultName]=wn.value,Dn.next=_n.nextLoc,Dn.method!=="return"&&(Dn.method="next",Dn.arg=n),Dn.delegate=null,De):wn:(Dn.method="throw",Dn.arg=new TypeError("iterator result is not an object"),Dn.delegate=null,De)}function It(_n){var Dn={tryLoc:_n[0]};1 in _n&&(Dn.catchLoc=_n[1]),2 in _n&&(Dn.finallyLoc=_n[2],Dn.afterLoc=_n[3]),this.tryEntries.push(Dn)}function nn(_n){var Dn=_n.completion||{};Dn.type="normal",delete Dn.arg,_n.completion=Dn}function tn(_n){this.tryEntries=[{tryLoc:"root"}],_n.forEach(It,this),this.reset(!0)}function pn(_n){if(_n||_n===""){var Dn=_n[O];if(Dn)return Dn.call(_n);if(typeof _n.next=="function")return _n;if(!isNaN(_n.length)){var an=-1,Rn=function Lt(){for(;++an<_n.length;)if(y.call(_n,an))return Lt.value=_n[an],Lt.done=!1,Lt;return Lt.value=n,Lt.done=!0,Lt};return Rn.next=Rn}}throw new TypeError(e(_n)+" is not iterable")}return rt.prototype=Ae,b(ue,"constructor",{value:Ae,configurable:!0}),b(Ae,"constructor",{value:rt,configurable:!0}),rt.displayName=G(Ae,L,"GeneratorFunction"),u.isGeneratorFunction=function(_n){var Dn=typeof _n=="function"&&_n.constructor;return!!Dn&&(Dn===rt||(Dn.displayName||Dn.name)==="GeneratorFunction")},u.mark=function(_n){return Object.setPrototypeOf?Object.setPrototypeOf(_n,Ae):(_n.__proto__=Ae,G(_n,L,"GeneratorFunction")),_n.prototype=Object.create(ue),_n},u.awrap=function(_n){return{__await:_n}},pt(mt.prototype),G(mt.prototype,N,function(){return this}),u.AsyncIterator=mt,u.async=function(_n,Dn,an,Rn,Lt){Lt===void 0&&(Lt=Promise);var wn=new mt(q(_n,Dn,an,Rn),Lt);return u.isGeneratorFunction(Dn)?wn:wn.next().then(function(hn){return hn.done?hn.value:wn.next()})},pt(ue),G(ue,L,"Generator"),G(ue,O,function(){return this}),G(ue,"toString",function(){return"[object Generator]"}),u.keys=function(_n){var Dn=Object(_n),an=[];for(var Rn in Dn)an.push(Rn);return an.reverse(),function Lt(){for(;an.length;){var wn=an.pop();if(wn in Dn)return Lt.value=wn,Lt.done=!1,Lt}return Lt.done=!0,Lt}},u.values=pn,tn.prototype={constructor:tn,reset:function(Dn){if(this.prev=0,this.next=0,this.sent=this._sent=n,this.done=!1,this.delegate=null,this.method="next",this.arg=n,this.tryEntries.forEach(nn),!Dn)for(var an in this)an.charAt(0)==="t"&&y.call(this,an)&&!isNaN(+an.slice(1))&&(this[an]=n)},stop:function(){this.done=!0;var Dn=this.tryEntries[0].completion;if(Dn.type==="throw")throw Dn.arg;return this.rval},dispatchException:function(Dn){if(this.done)throw Dn;var an=this;function Rn(Xr,ti){return hn.type="throw",hn.arg=Dn,an.next=Xr,ti&&(an.method="next",an.arg=n),!!ti}for(var Lt=this.tryEntries.length-1;Lt>=0;--Lt){var wn=this.tryEntries[Lt],hn=wn.completion;if(wn.tryLoc==="root")return Rn("end");if(wn.tryLoc<=this.prev){var xn=y.call(wn,"catchLoc"),$n=y.call(wn,"finallyLoc");if(xn&&$n){if(this.prev<wn.catchLoc)return Rn(wn.catchLoc,!0);if(this.prev<wn.finallyLoc)return Rn(wn.finallyLoc)}else if(xn){if(this.prev<wn.catchLoc)return Rn(wn.catchLoc,!0)}else{if(!$n)throw new Error("try statement without catch or finally");if(this.prev<wn.finallyLoc)return Rn(wn.finallyLoc)}}}},abrupt:function(Dn,an){for(var Rn=this.tryEntries.length-1;Rn>=0;--Rn){var Lt=this.tryEntries[Rn];if(Lt.tryLoc<=this.prev&&y.call(Lt,"finallyLoc")&&this.prev<Lt.finallyLoc){var wn=Lt;break}}wn&&(Dn==="break"||Dn==="continue")&&wn.tryLoc<=an&&an<=wn.finallyLoc&&(wn=null);var hn=wn?wn.completion:{};return hn.type=Dn,hn.arg=an,wn?(this.method="next",this.next=wn.finallyLoc,De):this.complete(hn)},complete:function(Dn,an){if(Dn.type==="throw")throw Dn.arg;return Dn.type==="break"||Dn.type==="continue"?this.next=Dn.arg:Dn.type==="return"?(this.rval=this.arg=Dn.arg,this.method="return",this.next="end"):Dn.type==="normal"&&an&&(this.next=an),De},finish:function(Dn){for(var an=this.tryEntries.length-1;an>=0;--an){var Rn=this.tryEntries[an];if(Rn.finallyLoc===Dn)return this.complete(Rn.completion,Rn.afterLoc),nn(Rn),De}},catch:function(Dn){for(var an=this.tryEntries.length-1;an>=0;--an){var Rn=this.tryEntries[an];if(Rn.tryLoc===Dn){var Lt=Rn.completion;if(Lt.type==="throw"){var wn=Lt.arg;nn(Rn)}return wn}}throw new Error("illegal catch attempt")},delegateYield:function(Dn,an,Rn){return this.delegate={iterator:pn(Dn),resultName:an,nextLoc:Rn},this.method==="next"&&(this.arg=n),De}},u}t.exports=l,t.exports.__esModule=!0,t.exports.default=t.exports})(regeneratorRuntime$1);var runtime=regeneratorRuntime$1.exports(),regenerator=runtime;try{regeneratorRuntime=runtime}catch(t){(typeof globalThis>"u"?"undefined":_typeof$2(globalThis))==="object"?globalThis.regeneratorRuntime=runtime:Function("r","regeneratorRuntime = r")(runtime)}function b64Encode(t){return btoa(unescape(encodeURIComponent(t)))}function b64Decode(t){return decodeURIComponent(escape(atob(t)))}function saveAsFileDialog(t){return _saveAsFileDialog.apply(this,arguments)}function _saveAsFileDialog(){return _saveAsFileDialog=_asyncToGenerator(regenerator.mark(function t(e){var l,n,u,c,y,b,m,O,N,L,G;return regenerator.wrap(function(J){for(;;)switch(J.prev=J.next){case 0:if(l=e.blob,n=e.filename,u=n===void 0?"":n,c=e.types,y=c===void 0?[{description:"mxweb File",accept:{"application/octet-stream":[".mxweb"]}}]:c,J.prev=1,!window.showSaveFilePicker){J.next=28;break}if(!((m=window.navigator)!==null&&m!==void 0&&(O=m.userActivation)!==null&&O!==void 0&&O.isActive)){J.next=27;break}if(J.prev=4,window.showSaveFilePicker){J.next=7;break}return J.abrupt("return");case 7:return J.next=9,window.showSaveFilePicker({suggestedName:u,types:y});case 9:return N=J.sent,J.next=12,N.createWritable();case 12:return L=J.sent,J.next=15,L.write(l);case 15:return J.next=17,L.close();case 17:return J.abrupt("return",N);case 20:if(J.prev=20,J.t0=J.catch(4),(J.t0===null||J.t0===void 0?void 0:J.t0.name)!=="AbortError"){J.next=24;break}return J.abrupt("return");case 24:console.error(J.t0);case 25:J.next=28;break;case 27:console.warn("非用户交互 无法调用showSaveFilePicker 已选择兼容方案");case 28:if(!((b=window.navigator)!==null&&b!==void 0&&b.msSaveOrOpenBlob)){J.next=31;break}return window.navigator.msSaveOrOpenBlob(l,u),J.abrupt("return");case 31:G=document.createElement("a"),G.href=window.URL.createObjectURL(l),G.download=u,G.style.display="none",document.body.appendChild(G),G.click(),document.body.removeChild(G),typeof window.URL.revokeObjectURL=="function"?window.URL.revokeObjectURL(G.href):typeof window.webkitURL<"u"&&typeof window.webkitURL.revokeObjectURL=="function"?window.webkitURL.revokeObjectURL(G.href):window.URL.revokeObjectURL(G.href),J.next=44;break;case 41:J.prev=41,J.t1=J.catch(1),console.error(J.t1.name,J.t1.message);case 44:case"end":return J.stop()}},t,null,[[1,41],[4,20]])})),_saveAsFileDialog.apply(this,arguments)}function downloadFile(t,e){var l=document.createElement("a");l.href=window.URL.createObjectURL(t),l.download=e,l.click()}function downloadFileFromUrl(t,e){fetch(t).then(function(l){return l.blob()}).then(function(l){var n=document.createElement("a");n.href=window.URL.createObjectURL(l),n.download=e,n.click()})}var getJsonFromUrl=function(){var t=_asyncToGenerator(regenerator.mark(function e(l){return regenerator.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:return u.prev=0,u.next=3,fetch(l);case 3:return u.next=5,u.sent.json();case 5:return u.abrupt("return",u.sent);case 8:u.prev=8,u.t0=u.catch(0),console.error("MxTip:error getJsonFromurl:"+l);case 11:case"end":return u.stop()}},e,null,[[0,8]])}));return function(l){return t.apply(this,arguments)}}(),getFileFromUrl=function(){var t=_asyncToGenerator(regenerator.mark(function e(l){return regenerator.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:return u.prev=0,u.next=3,fetch(l);case 3:return u.abrupt("return",u.sent);case 6:u.prev=6,u.t0=u.catch(0),console.error("MxTip:error getFileFromUrl:"+l);case 9:case"end":return u.stop()}},e,null,[[0,6]])}));return function(l){return t.apply(this,arguments)}}();function _ML_String(t,e){return MxFun.getLanguageString(t,e)}function IsZero(t){return Math.abs(t)<1e-7}function postMemoryFile(t,e,l,n,u){try{var c=new FormData,y=new Blob([t],{type:"application/octet-stream"});c.append("file",new File([y],l)),u&&c.append("param",u);var b=new XMLHttpRequest;b.open("POST",e),b.send(c),b.onreadystatechange=function(){b.readyState===XMLHttpRequest.DONE&&(b.status===200?n(0,b.responseText):(console.log(b.responseText),n(4,"server error")))}}catch{n(-1,"catch error")}}function postEmscriptenIndexedDBFile(t,e,l,n){var u=window.indexedDB.open("emscripten_filesystem",1);u.onerror=function(){l(1,"open emscripten_filesystem failed")},u.onsuccess=function(c){try{if(c.target!=null){var y=c.target.result,b=y.transaction("FILES","readonly"),m=b.objectStore("FILES"),O=m.get(t);O.onerror=function(){l(3,"get file error")},O.onsuccess=function(){var N=O.result;if(N){var L=new FormData;L.append("file",N),n&&L.append("param",n);var G=new XMLHttpRequest;G.open("POST",e),G.send(L),G.onreadystatechange=function(){G.readyState===XMLHttpRequest.DONE&&(G.status===200?l(0,G.responseText):(console.log(G.responseText),l(4,"server error")))}}else l(5,"get file data error")}}else l(2,"event.target == null")}catch{l(-1,"catch error")}}}function createCursorHelp(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:128,e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:10,l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"#ffffff",u=arguments.length>4&&arguments[4]!==void 0?arguments[4]:document.createElement("canvas"),c=arguments.length>5&&arguments[5]!==void 0?arguments[5]:"transparent";u.width=u.height=t,u.style.background=c;var y=u.getContext("2d"),b=t%2===0?-.5:0,m=e%2===0?-.5:0;return y.strokeStyle=n,y.lineWidth=0,y.imageSmoothingEnabled=!1,l&&(y.beginPath(),y.moveTo(u.width/2+b,b),y.lineTo(u.width/2+b,u.height+b),y.stroke(),y.beginPath(),y.moveTo(b,u.height/2+b),y.lineTo(u.width+b,u.height/2+b),y.stroke()),y.beginPath(),y.strokeRect(t/2-e/2+m,t/2-e/2+m,e,e),y.stroke(),u.toDataURL("image/png")}function createCursor(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:128,e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:10,l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"#ffffff";return{Rect:"url('".concat(createCursorHelp(t,e,!1,l),"') ").concat(t/2," ").concat(t/2,", auto"),Cross:"url('".concat(createCursorHelp(t,0,!0,l),"') ").concat(t/2," ").concat(t/2," , auto"),Normal:"url('".concat(createCursorHelp(t,e,!0,l),"') ").concat(t/2," ").concat(t/2,", auto")}}var MxTools={b64Encode,b64Decode,saveAsFileDialog,downloadFile,downloadFileFromUrl,getJsonFromUrl,getFileFromUrl,_ML_String,IsZero,postEmscriptenIndexedDBFile,postMemoryFile,createCursor};function _defineProperty$1(t,e,l){return e=toPropertyKey$1(e),e in t?Object.defineProperty(t,e,{value:l,enumerable:!0,configurable:!0,writable:!0}):t[e]=l,t}var lib={exports:{}},buffer=buffer$1,Buffer$1=buffer.Buffer,safer={},key$1;for(key$1 in buffer)buffer.hasOwnProperty(key$1)&&(key$1==="SlowBuffer"||key$1==="Buffer"||(safer[key$1]=buffer[key$1]));var Safer=safer.Buffer={};for(key$1 in Buffer$1)Buffer$1.hasOwnProperty(key$1)&&(key$1==="allocUnsafe"||key$1==="allocUnsafeSlow"||(Safer[key$1]=Buffer$1[key$1]));safer.Buffer.prototype=Buffer$1.prototype;(!Safer.from||Safer.from===Uint8Array.from)&&(Safer.from=function(t,e,l){if(typeof t=="number")throw new TypeError('The "value" argument must not be of type number. Received type '+_typeof$2(t));if(t&&typeof t.length>"u")throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+_typeof$2(t));return Buffer$1(t,e,l)});Safer.alloc||(Safer.alloc=function(t,e,l){if(typeof t!="number")throw new TypeError('The "size" argument must be of type number. Received type '+_typeof$2(t));if(t<0||t>=2*(1<<30))throw new RangeError('The value "'+t+'" is invalid for option "size"');var n=Buffer$1(t);return!e||e.length===0?n.fill(0):typeof l=="string"?n.fill(e,l):n.fill(e),n});if(!safer.kStringMaxLength)try{safer.kStringMaxLength=process.binding("buffer").kStringMaxLength}catch{}safer.constants||(safer.constants={MAX_LENGTH:safer.kMaxLength},safer.kStringMaxLength&&(safer.constants.MAX_STRING_LENGTH=safer.kStringMaxLength));var safer_1=safer,bomHandling={},BOMChar="\uFEFF";bomHandling.PrependBOM=PrependBOMWrapper;function PrependBOMWrapper(t,e){this.encoder=t,this.addBOM=!0}PrependBOMWrapper.prototype.write=function(t){return this.addBOM&&(t=BOMChar+t,this.addBOM=!1),this.encoder.write(t)};PrependBOMWrapper.prototype.end=function(){return this.encoder.end()};bomHandling.StripBOM=StripBOMWrapper;function StripBOMWrapper(t,e){this.decoder=t,this.pass=!1,this.options=e||{}}StripBOMWrapper.prototype.write=function(t){var e=this.decoder.write(t);return this.pass||!e||(e[0]===BOMChar&&(e=e.slice(1),typeof this.options.stripBOM=="function"&&this.options.stripBOM()),this.pass=!0),e};StripBOMWrapper.prototype.end=function(){return this.decoder.end()};var encodings={},string_decoder={},safeBuffer$1={exports:{}};/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */var hasRequiredSafeBuffer;function requireSafeBuffer(){return hasRequiredSafeBuffer||(hasRequiredSafeBuffer=1,function(t,e){var l=buffer$1,n=l.Buffer;function u(y,b){for(var m in y)b[m]=y[m]}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?t.exports=l:(u(l,e),e.Buffer=c);function c(y,b,m){return n(y,b,m)}c.prototype=Object.create(n.prototype),u(n,c),c.from=function(y,b,m){if(typeof y=="number")throw new TypeError("Argument must not be a number");return n(y,b,m)},c.alloc=function(y,b,m){if(typeof y!="number")throw new TypeError("Argument must be a number");var O=n(y);return b!==void 0?typeof m=="string"?O.fill(b,m):O.fill(b):O.fill(0),O},c.allocUnsafe=function(y){if(typeof y!="number")throw new TypeError("Argument must be a number");return n(y)},c.allocUnsafeSlow=function(y){if(typeof y!="number")throw new TypeError("Argument must be a number");return l.SlowBuffer(y)}}(safeBuffer$1,safeBuffer$1.exports)),safeBuffer$1.exports}var hasRequiredString_decoder;function requireString_decoder(){if(hasRequiredString_decoder)return string_decoder;hasRequiredString_decoder=1;var t=requireSafeBuffer().Buffer,e=t.isEncoding||function(ne){switch(ne=""+ne,ne&&ne.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function l(ne){if(!ne)return"utf8";for(var Ue;;)switch(ne){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return ne;default:if(Ue)return;ne=(""+ne).toLowerCase(),Ue=!0}}function n(ne){var Ue=l(ne);if(typeof Ue!="string"&&(t.isEncoding===e||!e(ne)))throw new Error("Unknown encoding: "+ne);return Ue||ne}string_decoder.StringDecoder=u;function u(ne){this.encoding=n(ne);var Ue;switch(this.encoding){case"utf16le":this.text=L,this.end=G,Ue=4;break;case"utf8":this.fillLast=m,Ue=4;break;case"base64":this.text=q,this.end=J,Ue=3;break;default:this.write=fe,this.end=ve;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=t.allocUnsafe(Ue)}u.prototype.write=function(ne){if(ne.length===0)return"";var Ue,De;if(this.lastNeed){if(Ue=this.fillLast(ne),Ue===void 0)return"";De=this.lastNeed,this.lastNeed=0}else De=0;return De<ne.length?Ue?Ue+this.text(ne,De):this.text(ne,De):Ue||""},u.prototype.end=N,u.prototype.text=O,u.prototype.fillLast=function(ne){if(this.lastNeed<=ne.length)return ne.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);ne.copy(this.lastChar,this.lastTotal-this.lastNeed,0,ne.length),this.lastNeed-=ne.length};function c(ne){return ne<=127?0:ne>>5===6?2:ne>>4===14?3:ne>>3===30?4:ne>>6===2?-1:-2}function y(ne,Ue,De){var Ve=Ue.length-1;if(Ve<De)return 0;var rt=c(Ue[Ve]);return rt>=0?(rt>0&&(ne.lastNeed=rt-1),rt):--Ve<De||rt===-2?0:(rt=c(Ue[Ve]),rt>=0?(rt>0&&(ne.lastNeed=rt-2),rt):--Ve<De||rt===-2?0:(rt=c(Ue[Ve]),rt>=0?(rt>0&&(rt===2?rt=0:ne.lastNeed=rt-3),rt):0))}function b(ne,Ue,De){if((Ue[0]&192)!==128)return ne.lastNeed=0,"�";if(ne.lastNeed>1&&Ue.length>1){if((Ue[1]&192)!==128)return ne.lastNeed=1,"�";if(ne.lastNeed>2&&Ue.length>2&&(Ue[2]&192)!==128)return ne.lastNeed=2,"�"}}function m(ne){var Ue=this.lastTotal-this.lastNeed,De=b(this,ne);if(De!==void 0)return De;if(this.lastNeed<=ne.length)return ne.copy(this.lastChar,Ue,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);ne.copy(this.lastChar,Ue,0,ne.length),this.lastNeed-=ne.length}function O(ne,Ue){var De=y(this,ne,Ue);if(!this.lastNeed)return ne.toString("utf8",Ue);this.lastTotal=De;var Ve=ne.length-(De-this.lastNeed);return ne.copy(this.lastChar,0,Ve),ne.toString("utf8",Ue,Ve)}function N(ne){var Ue=ne&&ne.length?this.write(ne):"";return this.lastNeed?Ue+"�":Ue}function L(ne,Ue){if((ne.length-Ue)%2===0){var De=ne.toString("utf16le",Ue);if(De){var Ve=De.charCodeAt(De.length-1);if(Ve>=55296&&Ve<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=ne[ne.length-2],this.lastChar[1]=ne[ne.length-1],De.slice(0,-1)}return De}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=ne[ne.length-1],ne.toString("utf16le",Ue,ne.length-1)}function G(ne){var Ue=ne&&ne.length?this.write(ne):"";if(this.lastNeed){var De=this.lastTotal-this.lastNeed;return Ue+this.lastChar.toString("utf16le",0,De)}return Ue}function q(ne,Ue){var De=(ne.length-Ue)%3;return De===0?ne.toString("base64",Ue):(this.lastNeed=3-De,this.lastTotal=3,De===1?this.lastChar[0]=ne[ne.length-1]:(this.lastChar[0]=ne[ne.length-2],this.lastChar[1]=ne[ne.length-1]),ne.toString("base64",Ue,ne.length-De))}function J(ne){var Ue=ne&&ne.length?this.write(ne):"";return this.lastNeed?Ue+this.lastChar.toString("base64",0,3-this.lastNeed):Ue}function fe(ne){return ne.toString(this.encoding)}function ve(ne){return ne&&ne.length?this.write(ne):""}return string_decoder}var internal,hasRequiredInternal;function requireInternal(){if(hasRequiredInternal)return internal;hasRequiredInternal=1;var t=safer_1.Buffer;internal={utf8:{type:"_internal",bomAware:!0},cesu8:{type:"_internal",bomAware:!0},unicode11utf8:"utf8",ucs2:{type:"_internal",bomAware:!0},utf16le:"ucs2",binary:{type:"_internal"},base64:{type:"_internal"},hex:{type:"_internal"},_internal:e};function e(m,O){this.enc=m.encodingName,this.bomAware=m.bomAware,this.enc==="base64"?this.encoder=c:this.enc==="cesu8"&&(this.enc="utf8",this.encoder=y,t.from("eda0bdedb2a9","hex").toString()!=="💩"&&(this.decoder=b,this.defaultCharUnicode=O.defaultCharUnicode))}e.prototype.encoder=u,e.prototype.decoder=n;var l=requireString_decoder().StringDecoder;l.prototype.end||(l.prototype.end=function(){});function n(m,O){this.decoder=new l(O.enc)}n.prototype.write=function(m){return t.isBuffer(m)||(m=t.from(m)),this.decoder.write(m)},n.prototype.end=function(){return this.decoder.end()};function u(m,O){this.enc=O.enc}u.prototype.write=function(m){return t.from(m,this.enc)},u.prototype.end=function(){};function c(m,O){this.prevStr=""}c.prototype.write=function(m){m=this.prevStr+m;var O=m.length-m.length%4;return this.prevStr=m.slice(O),m=m.slice(0,O),t.from(m,"base64")},c.prototype.end=function(){return t.from(this.prevStr,"base64")};function y(m,O){}y.prototype.write=function(m){for(var O=t.alloc(m.length*3),N=0,L=0;L<m.length;L++){var G=m.charCodeAt(L);G<128?O[N++]=G:G<2048?(O[N++]=192+(G>>>6),O[N++]=128+(G&63)):(O[N++]=224+(G>>>12),O[N++]=128+(G>>>6&63),O[N++]=128+(G&63))}return O.slice(0,N)},y.prototype.end=function(){};function b(m,O){this.acc=0,this.contBytes=0,this.accBytes=0,this.defaultCharUnicode=O.defaultCharUnicode}return b.prototype.write=function(m){for(var O=this.acc,N=this.contBytes,L=this.accBytes,G="",q=0;q<m.length;q++){var J=m[q];(J&192)!==128?(N>0&&(G+=this.defaultCharUnicode,N=0),J<128?G+=String.fromCharCode(J):J<224?(O=J&31,N=1,L=1):J<240?(O=J&15,N=2,L=1):G+=this.defaultCharUnicode):N>0?(O=O<<6|J&63,N--,L++,N===0&&(L===2&&O<128&&O>0?G+=this.defaultCharUnicode:L===3&&O<2048?G+=this.defaultCharUnicode:G+=String.fromCharCode(O))):G+=this.defaultCharUnicode}return this.acc=O,this.contBytes=N,this.accBytes=L,G},b.prototype.end=function(){var m=0;return this.contBytes>0&&(m+=this.defaultCharUnicode),m},internal}var utf32={},hasRequiredUtf32;function requireUtf32(){if(hasRequiredUtf32)return utf32;hasRequiredUtf32=1;var t=safer_1.Buffer;utf32._utf32=e;function e(O,N){this.iconv=N,this.bomAware=!0,this.isLE=O.isLE}utf32.utf32le={type:"_utf32",isLE:!0},utf32.utf32be={type:"_utf32",isLE:!1},utf32.ucs4le="utf32le",utf32.ucs4be="utf32be",e.prototype.encoder=l,e.prototype.decoder=n;function l(O,N){this.isLE=N.isLE,this.highSurrogate=0}l.prototype.write=function(O){for(var N=t.from(O,"ucs2"),L=t.alloc(N.length*2),G=this.isLE?L.writeUInt32LE:L.writeUInt32BE,q=0,J=0;J<N.length;J+=2){var fe=N.readUInt16LE(J),ve=55296<=fe&&fe<56320,ne=56320<=fe&&fe<57344;if(this.highSurrogate)if(ve||!ne)G.call(L,this.highSurrogate,q),q+=4;else{var Ue=(this.highSurrogate-55296<<10|fe-56320)+65536;G.call(L,Ue,q),q+=4,this.highSurrogate=0;continue}ve?this.highSurrogate=fe:(G.call(L,fe,q),q+=4,this.highSurrogate=0)}return q<L.length&&(L=L.slice(0,q)),L},l.prototype.end=function(){if(this.highSurrogate){var O=t.alloc(4);return this.isLE?O.writeUInt32LE(this.highSurrogate,0):O.writeUInt32BE(this.highSurrogate,0),this.highSurrogate=0,O}};function n(O,N){this.isLE=N.isLE,this.badChar=N.iconv.defaultCharUnicode.charCodeAt(0),this.overflow=[]}n.prototype.write=function(O){if(O.length===0)return"";var N=0,L=0,G=t.alloc(O.length+4),q=0,J=this.isLE,fe=this.overflow,ve=this.badChar;if(fe.length>0){for(;N<O.length&&fe.length<4;N++)fe.push(O[N]);fe.length===4&&(J?L=fe[N]|fe[N+1]<<8|fe[N+2]<<16|fe[N+3]<<24:L=fe[N+3]|fe[N+2]<<8|fe[N+1]<<16|fe[N]<<24,fe.length=0,q=u(G,q,L,ve))}for(;N<O.length-3;N+=4)J?L=O[N]|O[N+1]<<8|O[N+2]<<16|O[N+3]<<24:L=O[N+3]|O[N+2]<<8|O[N+1]<<16|O[N]<<24,q=u(G,q,L,ve);for(;N<O.length;N++)fe.push(O[N]);return G.slice(0,q).toString("ucs2")};function u(O,N,L,G){if((L<0||L>1114111)&&(L=G),L>=65536){L-=65536;var q=55296|L>>10;O[N++]=q&255,O[N++]=q>>8;var L=56320|L&1023}return O[N++]=L&255,O[N++]=L>>8,N}n.prototype.end=function(){this.overflow.length=0},utf32.utf32=c,utf32.ucs4="utf32";function c(O,N){this.iconv=N}c.prototype.encoder=y,c.prototype.decoder=b;function y(O,N){O=O||{},O.addBOM===void 0&&(O.addBOM=!0),this.encoder=N.iconv.getEncoder(O.defaultEncoding||"utf-32le",O)}y.prototype.write=function(O){return this.encoder.write(O)},y.prototype.end=function(){return this.encoder.end()};function b(O,N){this.decoder=null,this.initialBufs=[],this.initialBufsLen=0,this.options=O||{},this.iconv=N.iconv}b.prototype.write=function(O){if(!this.decoder){if(this.initialBufs.push(O),this.initialBufsLen+=O.length,this.initialBufsLen<32)return"";var N=m(this.initialBufs,this.options.defaultEncoding);this.decoder=this.iconv.getDecoder(N,this.options);for(var L="",G=0;G<this.initialBufs.length;G++)L+=this.decoder.write(this.initialBufs[G]);return this.initialBufs.length=this.initialBufsLen=0,L}return this.decoder.write(O)},b.prototype.end=function(){if(!this.decoder){var O=m(this.initialBufs,this.options.defaultEncoding);this.decoder=this.iconv.getDecoder(O,this.options);for(var N="",L=0;L<this.initialBufs.length;L++)N+=this.decoder.write(this.initialBufs[L]);var G=this.decoder.end();return G&&(N+=G),this.initialBufs.length=this.initialBufsLen=0,N}return this.decoder.end()};function m(O,N){var L=[],G=0,q=0,J=0,fe=0,ve=0;e:for(var ne=0;ne<O.length;ne++)for(var Ue=O[ne],De=0;De<Ue.length;De++)if(L.push(Ue[De]),L.length===4){if(G===0){if(L[0]===255&&L[1]===254&&L[2]===0&&L[3]===0)return"utf-32le";if(L[0]===0&&L[1]===0&&L[2]===254&&L[3]===255)return"utf-32be"}if((L[0]!==0||L[1]>16)&&J++,(L[3]!==0||L[2]>16)&&q++,L[0]===0&&L[1]===0&&(L[2]!==0||L[3]!==0)&&ve++,(L[0]!==0||L[1]!==0)&&L[2]===0&&L[3]===0&&fe++,L.length=0,G++,G>=100)break e}return ve-J>fe-q?"utf-32be":ve-J<fe-q?"utf-32le":N||"utf-32le"}return utf32}var utf16={},hasRequiredUtf16;function requireUtf16(){if(hasRequiredUtf16)return utf16;hasRequiredUtf16=1;var t=safer_1.Buffer;utf16.utf16be=e;function e(){}e.prototype.encoder=l,e.prototype.decoder=n,e.prototype.bomAware=!0;function l(){}l.prototype.write=function(m){for(var O=t.from(m,"ucs2"),N=0;N<O.length;N+=2){var L=O[N];O[N]=O[N+1],O[N+1]=L}return O},l.prototype.end=function(){};function n(){this.overflowByte=-1}n.prototype.write=function(m){if(m.length==0)return"";var O=t.alloc(m.length+1),N=0,L=0;for(this.overflowByte!==-1&&(O[0]=m[0],O[1]=this.overflowByte,N=1,L=2);N<m.length-1;N+=2,L+=2)O[L]=m[N+1],O[L+1]=m[N];return this.overflowByte=N==m.length-1?m[m.length-1]:-1,O.slice(0,L).toString("ucs2")},n.prototype.end=function(){this.overflowByte=-1},utf16.utf16=u;function u(m,O){this.iconv=O}u.prototype.encoder=c,u.prototype.decoder=y;function c(m,O){m=m||{},m.addBOM===void 0&&(m.addBOM=!0),this.encoder=O.iconv.getEncoder("utf-16le",m)}c.prototype.write=function(m){return this.encoder.write(m)},c.prototype.end=function(){return this.encoder.end()};function y(m,O){this.decoder=null,this.initialBufs=[],this.initialBufsLen=0,this.options=m||{},this.iconv=O.iconv}y.prototype.write=function(m){if(!this.decoder){if(this.initialBufs.push(m),this.initialBufsLen+=m.length,this.initialBufsLen<16)return"";var O=b(this.initialBufs,this.options.defaultEncoding);this.decoder=this.iconv.getDecoder(O,this.options);for(var N="",L=0;L<this.initialBufs.length;L++)N+=this.decoder.write(this.initialBufs[L]);return this.initialBufs.length=this.initialBufsLen=0,N}return this.decoder.write(m)},y.prototype.end=function(){if(!this.decoder){var m=b(this.initialBufs,this.options.defaultEncoding);this.decoder=this.iconv.getDecoder(m,this.options);for(var O="",N=0;N<this.initialBufs.length;N++)O+=this.decoder.write(this.initialBufs[N]);var L=this.decoder.end();return L&&(O+=L),this.initialBufs.length=this.initialBufsLen=0,O}return this.decoder.end()};function b(m,O){var N=[],L=0,G=0,q=0;e:for(var J=0;J<m.length;J++)for(var fe=m[J],ve=0;ve<fe.length;ve++)if(N.push(fe[ve]),N.length===2){if(L===0){if(N[0]===255&&N[1]===254)return"utf-16le";if(N[0]===254&&N[1]===255)return"utf-16be"}if(N[0]===0&&N[1]!==0&&q++,N[0]!==0&&N[1]===0&&G++,N.length=0,L++,L>=100)break e}return q>G?"utf-16be":q<G?"utf-16le":O||"utf-16le"}return utf16}var utf7={},hasRequiredUtf7;function requireUtf7(){if(hasRequiredUtf7)return utf7;hasRequiredUtf7=1;var t=safer_1.Buffer;utf7.utf7=e,utf7.unicode11utf7="utf7";function e(fe,ve){this.iconv=ve}e.prototype.encoder=n,e.prototype.decoder=u,e.prototype.bomAware=!0;var l=/[^A-Za-z0-9'\(\),-\.\/:\? \n\r\t]+/g;function n(fe,ve){this.iconv=ve.iconv}n.prototype.write=function(fe){return t.from(fe.replace(l,function(ve){return"+"+(ve==="+"?"":this.iconv.encode(ve,"utf16-be").toString("base64").replace(/=+$/,""))+"-"}.bind(this)))},n.prototype.end=function(){};function u(fe,ve){this.iconv=ve.iconv,this.inBase64=!1,this.base64Accum=""}for(var c=/[A-Za-z0-9\/+]/,y=[],b=0;b<256;b++)y[b]=c.test(String.fromCharCode(b));var m=43,O=45,N=38;u.prototype.write=function(fe){for(var ve="",ne=0,Ue=this.inBase64,De=this.base64Accum,Ve=0;Ve<fe.length;Ve++)if(!Ue)fe[Ve]==m&&(ve+=this.iconv.decode(fe.slice(ne,Ve),"ascii"),ne=Ve+1,Ue=!0);else if(!y[fe[Ve]]){if(Ve==ne&&fe[Ve]==O)ve+="+";else{var rt=De+this.iconv.decode(fe.slice(ne,Ve),"ascii");ve+=this.iconv.decode(t.from(rt,"base64"),"utf16-be")}fe[Ve]!=O&&Ve--,ne=Ve+1,Ue=!1,De=""}if(!Ue)ve+=this.iconv.decode(fe.slice(ne),"ascii");else{var rt=De+this.iconv.decode(fe.slice(ne),"ascii"),Ae=rt.length-rt.length%8;De=rt.slice(Ae),rt=rt.slice(0,Ae),ve+=this.iconv.decode(t.from(rt,"base64"),"utf16-be")}return this.inBase64=Ue,this.base64Accum=De,ve},u.prototype.end=function(){var fe="";return this.inBase64&&this.base64Accum.length>0&&(fe=this.iconv.decode(t.from(this.base64Accum,"base64"),"utf16-be")),this.inBase64=!1,this.base64Accum="",fe},utf7.utf7imap=L;function L(fe,ve){this.iconv=ve}L.prototype.encoder=G,L.prototype.decoder=q,L.prototype.bomAware=!0;function G(fe,ve){this.iconv=ve.iconv,this.inBase64=!1,this.base64Accum=t.alloc(6),this.base64AccumIdx=0}G.prototype.write=function(fe){for(var ve=this.inBase64,ne=this.base64Accum,Ue=this.base64AccumIdx,De=t.alloc(fe.length*5+10),Ve=0,rt=0;rt<fe.length;rt++){var Ae=fe.charCodeAt(rt);32<=Ae&&Ae<=126?(ve&&(Ue>0&&(Ve+=De.write(ne.slice(0,Ue).toString("base64").replace(/\//g,",").replace(/=+$/,""),Ve),Ue=0),De[Ve++]=O,ve=!1),ve||(De[Ve++]=Ae,Ae===N&&(De[Ve++]=O))):(ve||(De[Ve++]=N,ve=!0),ve&&(ne[Ue++]=Ae>>8,ne[Ue++]=Ae&255,Ue==ne.length&&(Ve+=De.write(ne.toString("base64").replace(/\//g,","),Ve),Ue=0)))}return this.inBase64=ve,this.base64AccumIdx=Ue,De.slice(0,Ve)},G.prototype.end=function(){var fe=t.alloc(10),ve=0;return this.inBase64&&(this.base64AccumIdx>0&&(ve+=fe.write(this.base64Accum.slice(0,this.base64AccumIdx).toString("base64").replace(/\//g,",").replace(/=+$/,""),ve),this.base64AccumIdx=0),fe[ve++]=O,this.inBase64=!1),fe.slice(0,ve)};function q(fe,ve){this.iconv=ve.iconv,this.inBase64=!1,this.base64Accum=""}var J=y.slice();return J[44]=!0,q.prototype.write=function(fe){for(var ve="",ne=0,Ue=this.inBase64,De=this.base64Accum,Ve=0;Ve<fe.length;Ve++)if(!Ue)fe[Ve]==N&&(ve+=this.iconv.decode(fe.slice(ne,Ve),"ascii"),ne=Ve+1,Ue=!0);else if(!J[fe[Ve]]){if(Ve==ne&&fe[Ve]==O)ve+="&";else{var rt=De+this.iconv.decode(fe.slice(ne,Ve),"ascii").replace(/,/g,"/");ve+=this.iconv.decode(t.from(rt,"base64"),"utf16-be")}fe[Ve]!=O&&Ve--,ne=Ve+1,Ue=!1,De=""}if(!Ue)ve+=this.iconv.decode(fe.slice(ne),"ascii");else{var rt=De+this.iconv.decode(fe.slice(ne),"ascii").replace(/,/g,"/"),Ae=rt.length-rt.length%8;De=rt.slice(Ae),rt=rt.slice(0,Ae),ve+=this.iconv.decode(t.from(rt,"base64"),"utf16-be")}return this.inBase64=Ue,this.base64Accum=De,ve},q.prototype.end=function(){var fe="";return this.inBase64&&this.base64Accum.length>0&&(fe=this.iconv.decode(t.from(this.base64Accum,"base64"),"utf16-be")),this.inBase64=!1,this.base64Accum="",fe},utf7}var sbcsCodec={},hasRequiredSbcsCodec;function requireSbcsCodec(){if(hasRequiredSbcsCodec)return sbcsCodec;hasRequiredSbcsCodec=1;var t=safer_1.Buffer;sbcsCodec._sbcs=e;function e(u,c){if(!u)throw new Error("SBCS codec is called without the data.");if(!u.chars||u.chars.length!==128&&u.chars.length!==256)throw new Error("Encoding '"+u.type+"' has incorrect 'chars' (must be of len 128 or 256)");if(u.chars.length===128){for(var y="",b=0;b<128;b++)y+=String.fromCharCode(b);u.chars=y+u.chars}this.decodeBuf=t.from(u.chars,"ucs2");for(var m=t.alloc(65536,c.defaultCharSingleByte.charCodeAt(0)),b=0;b<u.chars.length;b++)m[u.chars.charCodeAt(b)]=b;this.encodeBuf=m}e.prototype.encoder=l,e.prototype.decoder=n;function l(u,c){this.encodeBuf=c.encodeBuf}l.prototype.write=function(u){for(var c=t.alloc(u.length),y=0;y<u.length;y++)c[y]=this.encodeBuf[u.charCodeAt(y)];return c},l.prototype.end=function(){};function n(u,c){this.decodeBuf=c.decodeBuf}return n.prototype.write=function(u){for(var c=this.decodeBuf,y=t.alloc(u.length*2),b=0,m=0,O=0;O<u.length;O++)b=u[O]*2,m=O*2,y[m]=c[b],y[m+1]=c[b+1];return y.toString("ucs2")},n.prototype.end=function(){},sbcsCodec}var sbcsData,hasRequiredSbcsData;function requireSbcsData(){return hasRequiredSbcsData||(hasRequiredSbcsData=1,sbcsData={10029:"maccenteuro",maccenteuro:{type:"_sbcs",chars:"ÄĀāÉĄÖÜáąČäčĆć鏟ĎíďĒēĖóėôöõúĚěü†°Ę£§•¶ß®©™ę¨≠ģĮįĪ≤≥īĶ∂∑łĻļĽľĹĺŅņѬ√ńŇ∆«»… ňŐÕőŌ–—“”‘’÷◊ōŔŕŘ‹›řŖŗŠ‚„šŚśÁŤťÍŽžŪÓÔūŮÚůŰűŲųÝýķŻŁżĢˇ"},808:"cp808",ibm808:"cp808",cp808:{type:"_sbcs",chars:"АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмноп░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀рстуфхцчшщъыьэюяЁёЄєЇїЎў°∙·√№€■ "},mik:{type:"_sbcs",chars:"АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя└┴┬├─┼╣║╚╔╩╦╠═╬┐░▒▓│┤№§╗╝┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "},cp720:{type:"_sbcs",chars:"éâàçêëèïîّْô¤ـûùءآأؤ£إئابةتثجحخدذرزسشص«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀ضطظعغفµقكلمنهوىي≡ًٌٍَُِ≈°∙·√ⁿ²■ "},ascii8bit:"ascii",usascii:"ascii",ansix34:"ascii",ansix341968:"ascii",ansix341986:"ascii",csascii:"ascii",cp367:"ascii",ibm367:"ascii",isoir6:"ascii",iso646us:"ascii",iso646irv:"ascii",us:"ascii",latin1:"iso88591",latin2:"iso88592",latin3:"iso88593",latin4:"iso88594",latin5:"iso88599",latin6:"iso885910",latin7:"iso885913",latin8:"iso885914",latin9:"iso885915",latin10:"iso885916",csisolatin1:"iso88591",csisolatin2:"iso88592",csisolatin3:"iso88593",csisolatin4:"iso88594",csisolatincyrillic:"iso88595",csisolatinarabic:"iso88596",csisolatingreek:"iso88597",csisolatinhebrew:"iso88598",csisolatin5:"iso88599",csisolatin6:"iso885910",l1:"iso88591",l2:"iso88592",l3:"iso88593",l4:"iso88594",l5:"iso88599",l6:"iso885910",l7:"iso885913",l8:"iso885914",l9:"iso885915",l10:"iso885916",isoir14:"iso646jp",isoir57:"iso646cn",isoir100:"iso88591",isoir101:"iso88592",isoir109:"iso88593",isoir110:"iso88594",isoir144:"iso88595",isoir127:"iso88596",isoir126:"iso88597",isoir138:"iso88598",isoir148:"iso88599",isoir157:"iso885910",isoir166:"tis620",isoir179:"iso885913",isoir199:"iso885914",isoir203:"iso885915",isoir226:"iso885916",cp819:"iso88591",ibm819:"iso88591",cyrillic:"iso88595",arabic:"iso88596",arabic8:"iso88596",ecma114:"iso88596",asmo708:"iso88596",greek:"iso88597",greek8:"iso88597",ecma118:"iso88597",elot928:"iso88597",hebrew:"iso88598",hebrew8:"iso88598",turkish:"iso88599",turkish8:"iso88599",thai:"iso885911",thai8:"iso885911",celtic:"iso885914",celtic8:"iso885914",isoceltic:"iso885914",tis6200:"tis620",tis62025291:"tis620",tis62025330:"tis620",1e4:"macroman",10006:"macgreek",10007:"maccyrillic",10079:"maciceland",10081:"macturkish",cspc8codepage437:"cp437",cspc775baltic:"cp775",cspc850multilingual:"cp850",cspcp852:"cp852",cspc862latinhebrew:"cp862",cpgr:"cp869",msee:"cp1250",mscyrl:"cp1251",msansi:"cp1252",msgreek:"cp1253",msturk:"cp1254",mshebr:"cp1255",msarab:"cp1256",winbaltrim:"cp1257",cp20866:"koi8r",20866:"koi8r",ibm878:"koi8r",cskoi8r:"koi8r",cp21866:"koi8u",21866:"koi8u",ibm1168:"koi8u",strk10482002:"rk1048",tcvn5712:"tcvn",tcvn57121:"tcvn",gb198880:"iso646cn",cn:"iso646cn",csiso14jisc6220ro:"iso646jp",jisc62201969ro:"iso646jp",jp:"iso646jp",cshproman8:"hproman8",r8:"hproman8",roman8:"hproman8",xroman8:"hproman8",ibm1051:"hproman8",mac:"macintosh",csmacintosh:"macintosh"}),sbcsData}var sbcsDataGenerated,hasRequiredSbcsDataGenerated;function requireSbcsDataGenerated(){return hasRequiredSbcsDataGenerated||(hasRequiredSbcsDataGenerated=1,sbcsDataGenerated={437:"cp437",737:"cp737",775:"cp775",850:"cp850",852:"cp852",855:"cp855",856:"cp856",857:"cp857",858:"cp858",860:"cp860",861:"cp861",862:"cp862",863:"cp863",864:"cp864",865:"cp865",866:"cp866",869:"cp869",874:"windows874",922:"cp922",1046:"cp1046",1124:"cp1124",1125:"cp1125",1129:"cp1129",1133:"cp1133",1161:"cp1161",1162:"cp1162",1163:"cp1163",1250:"windows1250",1251:"windows1251",1252:"windows1252",1253:"windows1253",1254:"windows1254",1255:"windows1255",1256:"windows1256",1257:"windows1257",1258:"windows1258",28591:"iso88591",28592:"iso88592",28593:"iso88593",28594:"iso88594",28595:"iso88595",28596:"iso88596",28597:"iso88597",28598:"iso88598",28599:"iso88599",28600:"iso885910",28601:"iso885911",28603:"iso885913",28604:"iso885914",28605:"iso885915",28606:"iso885916",windows874:{type:"_sbcs",chars:"€����…�����������‘’“”•–—�������� กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู����฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛����"},win874:"windows874",cp874:"windows874",windows1250:{type:"_sbcs",chars:"€�‚�„…†‡�‰Š‹ŚŤŽŹ�‘’“”•–—�™š›śťžź ˇ˘Ł¤Ą¦§¨©Ş«¬®Ż°±˛ł´µ¶·¸ąş»Ľ˝ľżŔÁÂĂÄĹĆÇČÉĘËĚÍÎĎĐŃŇÓÔŐÖ×ŘŮÚŰÜÝŢßŕáâăäĺćçčéęëěíîďđńňóôőö÷řůúűüýţ˙"},win1250:"windows1250",cp1250:"windows1250",windows1251:{type:"_sbcs",chars:"ЂЃ‚ѓ„…†‡€‰Љ‹ЊЌЋЏђ‘’“”•–—�™љ›њќћџ ЎўЈ¤Ґ¦§Ё©Є«¬®Ї°±Ііґµ¶·ё№є»јЅѕїАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя"},win1251:"windows1251",cp1251:"windows1251",windows1252:{type:"_sbcs",chars:"€�‚ƒ„…†‡ˆ‰Š‹Œ�Ž��‘’“”•–—˜™š›œ�žŸ ¡¢£¤¥¦§¨©ª«¬®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ"},win1252:"windows1252",cp1252:"windows1252",windows1253:{type:"_sbcs",chars:"€�‚ƒ„…†‡�‰�‹�����‘’“”•–—�™�›���� ΅Ά£¤¥¦§¨©�«¬®―°±²³΄µ¶·ΈΉΊ»Ό½ΎΏΐΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡ�ΣΤΥΦΧΨΩΪΫάέήίΰαβγδεζηθικλμνξοπρςστυφχψωϊϋόύώ�"},win1253:"windows1253",cp1253:"windows1253",windows1254:{type:"_sbcs",chars:"€�‚ƒ„…†‡ˆ‰Š‹Œ����‘’“”•–—˜™š›œ��Ÿ ¡¢£¤¥¦§¨©ª«¬®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏĞÑÒÓÔÕÖ×ØÙÚÛÜİŞßàáâãäåæçèéêëìíîïğñòóôõö÷øùúûüışÿ"},win1254:"windows1254",cp1254:"windows1254",windows1255:{type:"_sbcs",chars:"€�‚ƒ„…†‡ˆ‰�‹�����‘’“”•–—˜™�›���� ¡¢£₪¥¦§¨©×«¬®¯°±²³´µ¶·¸¹÷»¼½¾¿ְֱֲֳִֵֶַָֹֺֻּֽ־ֿ׀ׁׂ׃װױײ׳״�������אבגדהוזחטיךכלםמןנסעףפץצקרשת���"},win1255:"windows1255",cp1255:"windows1255",windows1256:{type:"_sbcs",chars:"€پ‚ƒ„…†‡ˆ‰ٹ‹Œچژڈگ‘’“”•–—ک™ڑ›œں ،¢£¤¥¦§¨©ھ«¬®¯°±²³´µ¶·¸¹؛»¼½¾؟ہءآأؤإئابةتثجحخدذرزسشصض×طظعغـفقكàلâمنهوçèéêëىيîïًٌٍَôُِ÷ّùْûüے"},win1256:"windows1256",cp1256:"windows1256",windows1257:{type:"_sbcs",chars:"€�‚�„…†‡�‰�‹�¨ˇ¸�‘’“”•–—�™�›�¯˛� �¢£¤�¦§Ø©Ŗ«¬®Æ°±²³´µ¶·ø¹ŗ»¼½¾æĄĮĀĆÄÅĘĒČÉŹĖĢĶĪĻŠŃŅÓŌÕÖ×ŲŁŚŪÜŻŽßąįāćäåęēčéźėģķīļšńņóōõö÷ųłśūüżž˙"},win1257:"windows1257",cp1257:"windows1257",windows1258:{type:"_sbcs",chars:"€�‚ƒ„…†‡ˆ‰�‹Œ����‘’“”•–—˜™�›œ��Ÿ ¡¢£¤¥¦§¨©ª«¬®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂĂÄÅÆÇÈÉÊË̀ÍÎÏĐÑ̉ÓÔƠÖ×ØÙÚÛÜỮßàáâăäåæçèéêë́íîïđṇ̃óôơö÷øùúûüư₫ÿ"},win1258:"windows1258",cp1258:"windows1258",iso88591:{type:"_sbcs",chars:"
¡¢£¤¥¦§¨©ª«¬®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ"},cp28591:"iso88591",iso88592:{type:"_sbcs",chars:"
Ą˘Ł¤ĽŚ§¨ŠŞŤŹŽŻ°ą˛ł´ľśˇ¸šşťź˝žżŔÁÂĂÄĹĆÇČÉĘËĚÍÎĎĐŃŇÓÔŐÖ×ŘŮÚŰÜÝŢßŕáâăäĺćçčéęëěíîďđńňóôőö÷řůúűüýţ˙"},cp28592:"iso88592",iso88593:{type:"_sbcs",chars:"
Ħ˘£¤�Ĥ§¨İŞĞĴ�Ż°ħ²³´µĥ·¸ışğĵ½�żÀÁÂ�ÄĊĈÇÈÉÊËÌÍÎÏ�ÑÒÓÔĠÖ×ĜÙÚÛÜŬŜßàáâ�äċĉçèéêëìíîï�ñòóôġö÷ĝùúûüŭŝ˙"},cp28593:"iso88593",iso88594:{type:"_sbcs",chars:"
ĄĸŖ¤ĨĻ§¨ŠĒĢŦŽ¯°ą˛ŗ´ĩļˇ¸šēģŧŊžŋĀÁÂÃÄÅÆĮČÉĘËĖÍÎĪĐŅŌĶÔÕÖ×ØŲÚÛÜŨŪßāáâãäåæįčéęëėíîīđņōķôõö÷øųúûüũū˙"},cp28594:"iso88594",iso88595:{type:"_sbcs",chars:"
ЁЂЃЄЅІЇЈЉЊЋЌЎЏАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя№ёђѓєѕіїјљњћќ§ўџ"},cp28595:"iso88595",iso88596:{type:"_sbcs",chars:"
���¤�������،�������������؛���؟�ءآأؤإئابةتثجحخدذرزسشصضطظعغ�����ـفقكلمنهوىيًٌٍَُِّْ�������������"},cp28596:"iso88596",iso88597:{type:"_sbcs",chars:"
‘’£€₯¦§¨©ͺ«¬�―°±²³΄΅Ά·ΈΉΊ»Ό½ΎΏΐΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡ�ΣΤΥΦΧΨΩΪΫάέήίΰαβγδεζηθικλμνξοπρςστυφχψωϊϋόύώ�"},cp28597:"iso88597",iso88598:{type:"_sbcs",chars:"
�¢£¤¥¦§¨©×«¬®¯°±²³´µ¶·¸¹÷»¼½¾��������������������������������‗אבגדהוזחטיךכלםמןנסעףפץצקרשת���"},cp28598:"iso88598",iso88599:{type:"_sbcs",chars:"
¡¢£¤¥¦§¨©ª«¬®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏĞÑÒÓÔÕÖ×ØÙÚÛÜİŞßàáâãäåæçèéêëìíîïğñòóôõö÷øùúûüışÿ"},cp28599:"iso88599",iso885910:{type:"_sbcs",chars:"
ĄĒĢĪĨĶ§ĻĐŠŦŽŪŊ°ąēģīĩķ·ļđšŧž―ūŋĀÁÂÃÄÅÆĮČÉĘËĖÍÎÏÐŅŌÓÔÕÖŨØŲÚÛÜÝÞßāáâãäåæįčéęëėíîïðņōóôõöũøųúûüýþĸ"},cp28600:"iso885910",iso885911:{type:"_sbcs",chars:"
กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู����฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛����"},cp28601:"iso885911",iso885913:{type:"_sbcs",chars:"
”¢£¤„¦§Ø©Ŗ«¬®Æ°±²³“µ¶·ø¹ŗ»¼½¾æĄĮĀĆÄÅĘĒČÉŹĖĢĶĪĻŠŃŅÓŌÕÖ×ŲŁŚŪÜŻŽßąįāćäåęēčéźėģķīļšńņóōõö÷ųłśūüżž’"},cp28603:"iso885913",iso885914:{type:"_sbcs",chars:"
Ḃḃ£ĊċḊ§Ẁ©ẂḋỲ®ŸḞḟĠġṀṁ¶ṖẁṗẃṠỳẄẅṡÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏŴÑÒÓÔÕÖṪØÙÚÛÜÝŶßàáâãäåæçèéêëìíîïŵñòóôõöṫøùúûüýŷÿ"},cp28604:"iso885914",iso885915:{type:"_sbcs",chars:"
¡¢£€¥Š§š©ª«¬®¯°±²³Žµ¶·ž¹º»ŒœŸ¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ"},cp28605:"iso885915",iso885916:{type:"_sbcs",chars:"
ĄąŁ€„Š§š©Ș«ŹźŻ°±ČłŽ”¶·žčș»ŒœŸżÀÁÂĂÄĆÆÇÈÉÊËÌÍÎÏĐŃÒÓÔŐÖŚŰÙÚÛÜĘȚßàáâăäćæçèéêëìíîïđńòóôőöśűùúûüęțÿ"},cp28606:"iso885916",cp437:{type:"_sbcs",chars:"ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜ¢£¥₧ƒáíóúñѪº¿⌐¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "},ibm437:"cp437",csibm437:"cp437",cp737:{type:"_sbcs",chars:"ΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩαβγδεζηθικλμνξοπρσςτυφχψ░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀ωάέήϊίόύϋώΆΈΉΊΌΎΏ±≥≤ΪΫ÷≈°∙·√ⁿ²■ "},ibm737:"cp737",csibm737:"cp737",cp775:{type:"_sbcs",chars:"ĆüéāäģåćłēŖŗīŹÄÅÉæÆōöĢ¢ŚśÖÜø£ØפĀĪóŻżź”¦©®¬½¼Ł«»░▒▓│┤ĄČĘĖ╣║╗╝ĮŠ┐└┴┬├─┼ŲŪ╚╔╩╦╠═╬Žąčęėįšųūž┘┌█▄▌▐▀ÓßŌŃõÕµńĶķĻļņĒŅ’±“¾¶§÷„°∙·¹³²■ "},ibm775:"cp775",csibm775:"cp775",cp850:{type:"_sbcs",chars:"ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜø£Ø׃áíóúñѪº¿®¬½¼¡«»░▒▓│┤ÁÂÀ©╣║╗╝¢¥┐└┴┬├─┼ãÃ╚╔╩╦╠═╬¤ðÐÊËÈıÍÎÏ┘┌█▄¦Ì▀ÓßÔÒõÕµþÞÚÛÙýݯ´±‗¾¶§÷¸°¨·¹³²■ "},ibm850:"cp850",csibm850:"cp850",cp852:{type:"_sbcs",chars:"ÇüéâäůćçłëŐőîŹÄĆÉĹĺôöĽľŚśÖÜŤťŁ×čáíóúĄąŽžĘ꬟Ⱥ«»░▒▓│┤ÁÂĚŞ╣║╗╝Żż┐└┴┬├─┼Ăă╚╔╩╦╠═╬¤đĐĎËďŇÍÎě┘┌█▄ŢŮ▀ÓßÔŃńňŠšŔÚŕŰýÝţ´˝˛ˇ˘§÷¸°¨˙űŘř■ "},ibm852:"cp852",csibm852:"cp852",cp855:{type:"_sbcs",chars:"ђЂѓЃёЁєЄѕЅіІїЇјЈљЉњЊћЋќЌўЎџЏюЮъЪаАбБцЦдДеЕфФгГ«»░▒▓│┤хХиИ╣║╗╝йЙ┐└┴┬├─┼кК╚╔╩╦╠═╬¤лЛмМнНоОп┘┌█▄Пя▀ЯрРсСтТуУжЖвВьЬ№ыЫзЗшШэЭщЩчЧ§■ "},ibm855:"cp855",csibm855:"cp855",cp856:{type:"_sbcs",chars:"אבגדהוזחטיךכלםמןנסעףפץצקרשת�£�×����������®¬½¼�«»░▒▓│┤���©╣║╗╝¢¥┐└┴┬├─┼��╚╔╩╦╠═╬¤���������┘┌█▄¦�▀������µ�������¯´±‗¾¶§÷¸°¨·¹³²■ "},ibm856:"cp856",csibm856:"cp856",cp857:{type:"_sbcs",chars:"ÇüéâäàåçêëèïîıÄÅÉæÆôöòûùİÖÜø£ØŞşáíóúñÑĞ𿮬½¼¡«»░▒▓│┤ÁÂÀ©╣║╗╝¢¥┐└┴┬├─┼ãÃ╚╔╩╦╠═╬¤ºªÊËÈ�ÍÎÏ┘┌█▄¦Ì▀ÓßÔÒõÕµ�×ÚÛÙìÿ¯´±�¾¶§÷¸°¨·¹³²■ "},ibm857:"cp857",csibm857:"cp857",cp858:{type:"_sbcs",chars:"ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜø£Ø׃áíóúñѪº¿®¬½¼¡«»░▒▓│┤ÁÂÀ©╣║╗╝¢¥┐└┴┬├─┼ãÃ╚╔╩╦╠═╬¤ðÐÊËÈ€ÍÎÏ┘┌█▄¦Ì▀ÓßÔÒõÕµþÞÚÛÙýݯ´±‗¾¶§÷¸°¨·¹³²■ "},ibm858:"cp858",csibm858:"cp858",cp860:{type:"_sbcs",chars:"ÇüéâãàÁçêÊèÍÔìÃÂÉÀÈôõòÚùÌÕÜ¢£Ù₧ÓáíóúñѪº¿Ò¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "},ibm860:"cp860",csibm860:"cp860",cp861:{type:"_sbcs",chars:"ÇüéâäàåçêëèÐðÞÄÅÉæÆôöþûÝýÖÜø£Ø₧ƒáíóúÁÍÓÚ¿⌐¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "},ibm861:"cp861",csibm861:"cp861",cp862:{type:"_sbcs",chars:"אבגדהוזחטיךכלםמןנסעףפץצקרשת¢£¥₧ƒáíóúñѪº¿⌐¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "},ibm862:"cp862",csibm862:"cp862",cp863:{type:"_sbcs",chars:"ÇüéâÂà¶çêëèïî‗À§ÉÈÊôËÏûù¤ÔÜ¢£ÙÛƒ¦´óú¨¸³¯Î⌐¬½¼¾«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "},ibm863:"cp863",csibm863:"cp863",cp864:{type:"_sbcs",chars:`\0\x07\b
- \v\f\r\x1B !"#$٪&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_\`abcdefghijklmnopqrstuvwxyz{|}~°·∙√▒─│┼┤┬├┴┐┌└┘β∞φ±½¼≈«»ﻷﻸ��ﻻﻼ� ﺂ£¤ﺄ��ﺎﺏﺕﺙ،ﺝﺡﺥ٠١٢٣٤٥٦٧٨٩ﻑ؛ﺱﺵﺹ؟¢ﺀﺁﺃﺅﻊﺋﺍﺑﺓﺗﺛﺟﺣﺧﺩﺫﺭﺯﺳﺷﺻﺿﻁﻅﻋﻏ¦¬÷×ﻉـﻓﻗﻛﻟﻣﻧﻫﻭﻯﻳﺽﻌﻎﻍﻡﹽّﻥﻩﻬﻰﻲﻐﻕﻵﻶﻝﻙﻱ■�`},ibm864:"cp864",csibm864:"cp864",cp865:{type:"_sbcs",chars:"ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜø£Ø₧ƒáíóúñѪº¿⌐¬½¼¡«¤░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "},ibm865:"cp865",csibm865:"cp865",cp866:{type:"_sbcs",chars:"АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмноп░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀рстуфхцчшщъыьэюяЁёЄєЇїЎў°∙·√№¤■ "},ibm866:"cp866",csibm866:"cp866",cp869:{type:"_sbcs",chars:"������Ά�·¬¦‘’Έ―ΉΊΪΌ��ΎΫ©Ώ²³ά£έήίϊΐόύΑΒΓΔΕΖΗ½ΘΙ«»░▒▓│┤ΚΛΜΝ╣║╗╝ΞΟ┐└┴┬├─┼ΠΡ╚╔╩╦╠═╬ΣΤΥΦΧΨΩαβγ┘┌█▄δε▀ζηθικλμνξοπρσςτ΄±υφχ§ψ΅°¨ωϋΰώ■ "},ibm869:"cp869",csibm869:"cp869",cp922:{type:"_sbcs",chars:"
¡¢£¤¥¦§¨©ª«¬®‾°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏŠÑÒÓÔÕÖ×ØÙÚÛÜÝŽßàáâãäåæçèéêëìíîïšñòóôõö÷øùúûüýžÿ"},ibm922:"cp922",csibm922:"cp922",cp1046:{type:"_sbcs",chars:"ﺈ×÷ﹱ■│─┐┌└┘ﹹﹻﹽﹿﹷﺊﻰﻳﻲﻎﻏﻐﻶﻸﻺﻼ ¤ﺋﺑﺗﺛﺟﺣ،ﺧﺳ٠١٢٣٤٥٦٧٨٩ﺷ؛ﺻﺿﻊ؟ﻋءآأؤإئابةتثجحخدذرزسشصضطﻇعغﻌﺂﺄﺎﻓـفقكلمنهوىيًٌٍَُِّْﻗﻛﻟﻵﻷﻹﻻﻣﻧﻬﻩ�"},ibm1046:"cp1046",csibm1046:"cp1046",cp1124:{type:"_sbcs",chars:"
ЁЂҐЄЅІЇЈЉЊЋЌЎЏАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя№ёђґєѕіїјљњћќ§ўџ"},ibm1124:"cp1124",csibm1124:"cp1124",cp1125:{type:"_sbcs",chars:"АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмноп░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀рстуфхцчшщъыьэюяЁёҐґЄєІіЇї·√№¤■ "},ibm1125:"cp1125",csibm1125:"cp1125",cp1129:{type:"_sbcs",chars:"
¡¢£¤¥¦§œ©ª«¬®¯°±²³Ÿµ¶·Œ¹º»¼½¾¿ÀÁÂĂÄÅÆÇÈÉÊË̀ÍÎÏĐÑ̉ÓÔƠÖ×ØÙÚÛÜỮßàáâăäåæçèéêë́íîïđṇ̃óôơö÷øùúûüư₫ÿ"},ibm1129:"cp1129",csibm1129:"cp1129",cp1133:{type:"_sbcs",chars:"
ກຂຄງຈສຊຍດຕຖທນບປຜຝພຟມຢຣລວຫອຮ���ຯະາຳິີຶືຸູຼັົຽ���ເແໂໃໄ່້໊໋໌ໍໆ�ໜໝ₭����������������໐໑໒໓໔໕໖໗໘໙��¢¬¦�"},ibm1133:"cp1133",csibm1133:"cp1133",cp1161:{type:"_sbcs",chars:"��������������������������������่กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู้๊๋€฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛¢¬¦ "},ibm1161:"cp1161",csibm1161:"cp1161",cp1162:{type:"_sbcs",chars:"€…‘’“”•–— กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู����฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛����"},ibm1162:"cp1162",csibm1162:"cp1162",cp1163:{type:"_sbcs",chars:"
¡¢£€¥¦§œ©ª«¬®¯°±²³Ÿµ¶·Œ¹º»¼½¾¿ÀÁÂĂÄÅÆÇÈÉÊË̀ÍÎÏĐÑ̉ÓÔƠÖ×ØÙÚÛÜỮßàáâăäåæçèéêë́íîïđṇ̃óôơö÷øùúûüư₫ÿ"},ibm1163:"cp1163",csibm1163:"cp1163",maccroatian:{type:"_sbcs",chars:"ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®Š™´¨≠ŽØ∞±≤≥∆µ∂∑∏š∫ªºΩžø¿¡¬√ƒ≈Ć«Č… ÀÃÕŒœĐ—“”‘’÷◊�©⁄¤‹›Æ»–·‚„‰ÂćÁčÈÍÎÏÌÓÔđÒÚÛÙıˆ˜¯πË˚¸Êæˇ"},maccyrillic:{type:"_sbcs",chars:"АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ†°¢£§•¶І®©™Ђђ≠Ѓѓ∞±≤≥іµ∂ЈЄєЇїЉљЊњјЅ¬√ƒ≈∆«»… ЋћЌќѕ–—“”‘’÷„ЎўЏџ№Ёёяабвгдежзийклмнопрстуфхцчшщъыьэю¤"},macgreek:{type:"_sbcs",chars:"Ĺ²É³ÖÜ΅àâä΄¨çéèê룙î‰ôö¦ùûü†ΓΔΘΛΞΠß®©ΣΪ§≠°·Α±≤≥¥ΒΕΖΗΙΚΜΦΫΨΩάΝ¬ΟΡ≈Τ«»… ΥΧΆΈœ–―“”‘’÷ΉΊΌΎέήίόΏύαβψδεφγηιξκλμνοπώρστθωςχυζϊϋΐΰ�"},maciceland:{type:"_sbcs",chars:"ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûüÝ°¢£§•¶ß®©™´¨≠ÆØ∞±≤≥¥µ∂∑∏π∫ªºΩæø¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸ⁄¤ÐðÞþý·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙıˆ˜¯˘˙˚¸˝˛ˇ"},macroman:{type:"_sbcs",chars:"ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®©™´¨≠ÆØ∞±≤≥¥µ∂∑∏π∫ªºΩæø¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸ⁄¤‹›fifl‡·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙıˆ˜¯˘˙˚¸˝˛ˇ"},macromania:{type:"_sbcs",chars:"ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®©™´¨≠ĂŞ∞±≤≥¥µ∂∑∏π∫ªºΩăş¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸ⁄¤‹›Ţţ‡·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙıˆ˜¯˘˙˚¸˝˛ˇ"},macthai:{type:"_sbcs",chars:"«»…“”�•‘’� กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู\uFEFF–—฿เแโใไๅๆ็่้๊๋์ํ™๏๐๑๒๓๔๕๖๗๘๙®©����"},macturkish:{type:"_sbcs",chars:"ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®©™´¨≠ÆØ∞±≤≥¥µ∂∑∏π∫ªºΩæø¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸĞğİıŞş‡·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙ�ˆ˜¯˘˙˚¸˝˛ˇ"},macukraine:{type:"_sbcs",chars:"АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ†°Ґ£§•¶І®©™Ђђ≠Ѓѓ∞±≤≥іµґЈЄєЇїЉљЊњјЅ¬√ƒ≈∆«»… ЋћЌќѕ–—“”‘’÷„ЎўЏџ№Ёёяабвгдежзийклмнопрстуфхцчшщъыьэю¤"},koi8r:{type:"_sbcs",chars:"─│┌┐└┘├┤┬┴┼▀▄█▌▐░▒▓⌠■∙√≈≤≥ ⌡°²·÷═║╒ё╓╔╕╖╗╘╙╚╛╜╝╞╟╠╡Ё╢╣╤╥╦╧╨╩╪╫╬©юабцдефгхийклмнопярстужвьызшэщчъЮАБЦДЕФГХИЙКЛМНОПЯРСТУЖВЬЫЗШЭЩЧЪ"},koi8u:{type:"_sbcs",chars:"─│┌┐└┘├┤┬┴┼▀▄█▌▐░▒▓⌠■∙√≈≤≥ ⌡°²·÷═║╒ёє╔ії╗╘╙╚╛ґ╝╞╟╠╡ЁЄ╣ІЇ╦╧╨╩╪Ґ╬©юабцдефгхийклмнопярстужвьызшэщчъЮАБЦДЕФГХИЙКЛМНОПЯРСТУЖВЬЫЗШЭЩЧЪ"},koi8ru:{type:"_sbcs",chars:"─│┌┐└┘├┤┬┴┼▀▄█▌▐░▒▓⌠■∙√≈≤≥ ⌡°²·÷═║╒ёє╔ії╗╘╙╚╛ґў╞╟╠╡ЁЄ╣ІЇ╦╧╨╩╪ҐЎ©юабцдефгхийклмнопярстужвьызшэщчъЮАБЦДЕФГХИЙКЛМНОПЯРСТУЖВЬЫЗШЭЩЧЪ"},koi8t:{type:"_sbcs",chars:"қғ‚Ғ„…†‡�‰ҳ‹ҲҷҶ�Қ‘’“”•–—�™�›�����ӯӮё¤ӣ¦§���«¬®�°±²Ё�Ӣ¶·�№�»���©юабцдефгхийклмнопярстужвьызшэщчъЮАБЦДЕФГХИЙКЛМНОПЯРСТУЖВЬЫЗШЭЩЧЪ"},armscii8:{type:"_sbcs",chars:"
�և։)(»«—.՝,-֊…՜՛՞ԱաԲբԳգԴդԵեԶզԷէԸըԹթԺժԻիԼլԽխԾծԿկՀհՁձՂղՃճՄմՅյՆնՇշՈոՉչՊպՋջՌռՍսՎվՏտՐրՑցՒւՓփՔքՕօՖֆ՚�"},rk1048:{type:"_sbcs",chars:"ЂЃ‚ѓ„…†‡€‰Љ‹ЊҚҺЏђ‘’“”•–—�™љ›њқһџ ҰұӘ¤Ө¦§Ё©Ғ«¬®Ү°±Ііөµ¶·ё№ғ»әҢңүАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя"},tcvn:{type:"_sbcs",chars:`\0ÚỤỪỬỮ\x07\b
- \v\f\rỨỰỲỶỸÝỴ\x1B !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_\`abcdefghijklmnopqrstuvwxyz{|}~ÀẢÃÁẠẶẬÈẺẼÉẸỆÌỈĨÍỊÒỎÕÓỌỘỜỞỠỚỢÙỦŨ ĂÂÊÔƠƯĐăâêôơưđẶ̀̀̉̃́àảãáạẲằẳẵắẴẮẦẨẪẤỀặầẩẫấậèỂẻẽéẹềểễếệìỉỄẾỒĩíịòỔỏõóọồổỗốộờởỡớợùỖủũúụừửữứựỳỷỹýỵỐ`},georgianacademy:{type:"_sbcs",chars:"‚ƒ„…†‡ˆ‰Š‹Œ‘’“”•–—˜™š›œŸ ¡¢£¤¥¦§¨©ª«¬®¯°±²³´µ¶·¸¹º»¼½¾¿აბგდევზთიკლმნოპჟრსტუფქღყშჩცძწჭხჯჰჱჲჳჴჵჶçèéêëìíîïðñòóôõö÷øùúûüýþÿ"},georgianps:{type:"_sbcs",chars:"‚ƒ„…†‡ˆ‰Š‹Œ‘’“”•–—˜™š›œŸ ¡¢£¤¥¦§¨©ª«¬®¯°±²³´µ¶·¸¹º»¼½¾¿აბგდევზჱთიკლმნჲოპჟრსტჳუფქღყშჩცძწჭხჴჯჰჵæçèéêëìíîïðñòóôõö÷øùúûüýþÿ"},pt154:{type:"_sbcs",chars:"ҖҒӮғ„…ҶҮҲүҠӢҢҚҺҸҗ‘’“”•–—ҳҷҡӣңқһҹ ЎўЈӨҘҰ§Ё©Ә«¬ӯ®Ҝ°ұІіҙө¶·ё№ә»јҪҫҝАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя"},viscii:{type:"_sbcs",chars:`\0ẲẴẪ\x07\b
- \v\f\rỶỸ\x1BỴ !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_\`abcdefghijklmnopqrstuvwxyz{|}~ẠẮẰẶẤẦẨẬẼẸẾỀỂỄỆỐỒỔỖỘỢỚỜỞỊỎỌỈỦŨỤỲÕắằặấầẩậẽẹếềểễệốồổỗỠƠộờởịỰỨỪỬơớƯÀÁÂÃẢĂẳẵÈÉÊẺÌÍĨỳĐứÒÓÔạỷừửÙÚỹỵÝỡưàáâãảăữẫèéêẻìíĩỉđựòóôõỏọụùúũủýợỮ`},iso646cn:{type:"_sbcs",chars:`\0\x07\b
- \v\f\r\x1B !"#¥%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_\`abcdefghijklmnopqrstuvwxyz{|}‾��������������������������������������������������������������������������������������������������������������������������������`},iso646jp:{type:"_sbcs",chars:`\0\x07\b
- \v\f\r\x1B !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[¥]^_\`abcdefghijklmnopqrstuvwxyz{|}‾��������������������������������������������������������������������������������������������������������������������������������`},hproman8:{type:"_sbcs",chars:"
ÀÂÈÊËÎÏ´ˋˆ¨˜ÙÛ₤¯Ýý°ÇçÑñ¡¿¤£¥§ƒ¢âêôûáéóúàèòùäëöüÅîØÆåíøæÄìÖÜÉïßÔÁÃãÐðÍÌÓÒÕõŠšÚŸÿÞþ·µ¶¾—¼½ªº«■»±�"},macintosh:{type:"_sbcs",chars:"ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®©™´¨≠ÆØ∞±≤≥¥µ∂∑∏π∫ªºΩæø¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸ⁄¤‹›fifl‡·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙıˆ˜¯˘˙˚¸˝˛ˇ"},ascii:{type:"_sbcs",chars:"��������������������������������������������������������������������������������������������������������������������������������"},tis620:{type:"_sbcs",chars:"���������������������������������กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู����฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛����"}}),sbcsDataGenerated}var dbcsCodec={},hasRequiredDbcsCodec;function requireDbcsCodec(){if(hasRequiredDbcsCodec)return dbcsCodec;hasRequiredDbcsCodec=1;var t=safer_1.Buffer;dbcsCodec._dbcs=m;for(var e=-1,l=-2,n=-10,u=-1e3,c=new Array(256),y=-1,b=0;b<256;b++)c[b]=e;function m(G,q){if(this.encodingName=G.encodingName,!G)throw new Error("DBCS codec is called without the data.");if(!G.table)throw new Error("Encoding '"+this.encodingName+"' has no data.");var J=G.table();this.decodeTables=[],this.decodeTables[0]=c.slice(0),this.decodeTableSeq=[];for(var fe=0;fe<J.length;fe++)this._addDecodeChunk(J[fe]);if(typeof G.gb18030=="function"){this.gb18030=G.gb18030();var ve=this.decodeTables.length;this.decodeTables.push(c.slice(0));var ne=this.decodeTables.length;this.decodeTables.push(c.slice(0));for(var Ue=this.decodeTables[0],fe=129;fe<=254;fe++)for(var De=this.decodeTables[u-Ue[fe]],Ve=48;Ve<=57;Ve++){if(De[Ve]===e)De[Ve]=u-ve;else if(De[Ve]>u)throw new Error("gb18030 decode tables conflict at byte 2");for(var rt=this.decodeTables[u-De[Ve]],Ae=129;Ae<=254;Ae++){if(rt[Ae]===e)rt[Ae]=u-ne;else{if(rt[Ae]===u-ne)continue;if(rt[Ae]>u)throw new Error("gb18030 decode tables conflict at byte 3")}for(var Te=this.decodeTables[u-rt[Ae]],Xe=48;Xe<=57;Xe++)Te[Xe]===e&&(Te[Xe]=l)}}}this.defaultCharUnicode=q.defaultCharUnicode,this.encodeTable=[],this.encodeTableSeq=[];var ie={};if(G.encodeSkipVals)for(var fe=0;fe<G.encodeSkipVals.length;fe++){var ue=G.encodeSkipVals[fe];if(typeof ue=="number")ie[ue]=!0;else for(var Ve=ue.from;Ve<=ue.to;Ve++)ie[Ve]=!0}if(this._fillEncodeTable(0,0,ie),G.encodeAdd)for(var pt in G.encodeAdd)Object.prototype.hasOwnProperty.call(G.encodeAdd,pt)&&this._setEncodeChar(pt.charCodeAt(0),G.encodeAdd[pt]);this.defCharSB=this.encodeTable[0][q.defaultCharSingleByte.charCodeAt(0)],this.defCharSB===e&&(this.defCharSB=this.encodeTable[0]["?"]),this.defCharSB===e&&(this.defCharSB=63)}m.prototype.encoder=O,m.prototype.decoder=N,m.prototype._getDecodeTrieNode=function(G){for(var q=[];G>0;G>>>=8)q.push(G&255);q.length==0&&q.push(0);for(var J=this.decodeTables[0],fe=q.length-1;fe>0;fe--){var ve=J[q[fe]];if(ve==e)J[q[fe]]=u-this.decodeTables.length,this.decodeTables.push(J=c.slice(0));else if(ve<=u)J=this.decodeTables[u-ve];else throw new Error("Overwrite byte in "+this.encodingName+", addr: "+G.toString(16))}return J},m.prototype._addDecodeChunk=function(G){var q=parseInt(G[0],16),J=this._getDecodeTrieNode(q);q=q&255;for(var fe=1;fe<G.length;fe++){var ve=G[fe];if(typeof ve=="string")for(var ne=0;ne<ve.length;){var Ue=ve.charCodeAt(ne++);if(55296<=Ue&&Ue<56320){var De=ve.charCodeAt(ne++);if(56320<=De&&De<57344)J[q++]=65536+(Ue-55296)*1024+(De-56320);else throw new Error("Incorrect surrogate pair in "+this.encodingName+" at chunk "+G[0])}else if(4080<Ue&&Ue<=4095){for(var Ve=4095-Ue+2,rt=[],Ae=0;Ae<Ve;Ae++)rt.push(ve.charCodeAt(ne++));J[q++]=n-this.decodeTableSeq.length,this.decodeTableSeq.push(rt)}else J[q++]=Ue}else if(typeof ve=="number")for(var Te=J[q-1]+1,ne=0;ne<ve;ne++)J[q++]=Te++;else throw new Error("Incorrect type '"+_typeof$2(ve)+"' given in "+this.encodingName+" at chunk "+G[0])}if(q>255)throw new Error("Incorrect chunk in "+this.encodingName+" at addr "+G[0]+": too long"+q)},m.prototype._getEncodeBucket=function(G){var q=G>>8;return this.encodeTable[q]===void 0&&(this.encodeTable[q]=c.slice(0)),this.encodeTable[q]},m.prototype._setEncodeChar=function(G,q){var J=this._getEncodeBucket(G),fe=G&255;J[fe]<=n?this.encodeTableSeq[n-J[fe]][y]=q:J[fe]==e&&(J[fe]=q)},m.prototype._setEncodeSequence=function(G,q){var J=G[0],fe=this._getEncodeBucket(J),ve=J&255,ne;fe[ve]<=n?ne=this.encodeTableSeq[n-fe[ve]]:(ne={},fe[ve]!==e&&(ne[y]=fe[ve]),fe[ve]=n-this.encodeTableSeq.length,this.encodeTableSeq.push(ne));for(var Ue=1;Ue<G.length-1;Ue++){var De=ne[J];_typeof$2(De)==="object"?ne=De:(ne=ne[J]={},De!==void 0&&(ne[y]=De))}J=G[G.length-1],ne[J]=q},m.prototype._fillEncodeTable=function(G,q,J){for(var fe=this.decodeTables[G],ve=!1,ne={},Ue=0;Ue<256;Ue++){var De=fe[Ue],Ve=q+Ue;if(!J[Ve])if(De>=0)this._setEncodeChar(De,Ve),ve=!0;else if(De<=u){var rt=u-De;if(!ne[rt]){var Ae=Ve<<8>>>0;this._fillEncodeTable(rt,Ae,J)?ve=!0:ne[rt]=!0}}else De<=n&&(this._setEncodeSequence(this.decodeTableSeq[n-De],Ve),ve=!0)}return ve};function O(G,q){this.leadSurrogate=-1,this.seqObj=void 0,this.encodeTable=q.encodeTable,this.encodeTableSeq=q.encodeTableSeq,this.defaultCharSingleByte=q.defCharSB,this.gb18030=q.gb18030}O.prototype.write=function(G){for(var q=t.alloc(G.length*(this.gb18030?4:3)),J=this.leadSurrogate,fe=this.seqObj,ve=-1,ne=0,Ue=0;;){if(ve===-1){if(ne==G.length)break;var De=G.charCodeAt(ne++)}else{var De=ve;ve=-1}if(55296<=De&&De<57344)if(De<56320)if(J===-1){J=De;continue}else J=De,De=e;else J!==-1?(De=65536+(J-55296)*1024+(De-56320),J=-1):De=e;else J!==-1&&(ve=De,De=e,J=-1);var Ve=e;if(fe!==void 0&&De!=e){var rt=fe[De];if(_typeof$2(rt)==="object"){fe=rt;continue}else typeof rt=="number"?Ve=rt:rt==null&&(rt=fe[y],rt!==void 0&&(Ve=rt,ve=De));fe=void 0}else if(De>=0){var Ae=this.encodeTable[De>>8];if(Ae!==void 0&&(Ve=Ae[De&255]),Ve<=n){fe=this.encodeTableSeq[n-Ve];continue}if(Ve==e&&this.gb18030){var Te=L(this.gb18030.uChars,De);if(Te!=-1){var Ve=this.gb18030.gbChars[Te]+(De-this.gb18030.uChars[Te]);q[Ue++]=129+Math.floor(Ve/12600),Ve=Ve%12600,q[Ue++]=48+Math.floor(Ve/1260),Ve=Ve%1260,q[Ue++]=129+Math.floor(Ve/10),Ve=Ve%10,q[Ue++]=48+Ve;continue}}}Ve===e&&(Ve=this.defaultCharSingleByte),Ve<256?q[Ue++]=Ve:Ve<65536?(q[Ue++]=Ve>>8,q[Ue++]=Ve&255):Ve<16777216?(q[Ue++]=Ve>>16,q[Ue++]=Ve>>8&255,q[Ue++]=Ve&255):(q[Ue++]=Ve>>>24,q[Ue++]=Ve>>>16&255,q[Ue++]=Ve>>>8&255,q[Ue++]=Ve&255)}return this.seqObj=fe,this.leadSurrogate=J,q.slice(0,Ue)},O.prototype.end=function(){if(!(this.leadSurrogate===-1&&this.seqObj===void 0)){var G=t.alloc(10),q=0;if(this.seqObj){var J=this.seqObj[y];J!==void 0&&(J<256?G[q++]=J:(G[q++]=J>>8,G[q++]=J&255)),this.seqObj=void 0}return this.leadSurrogate!==-1&&(G[q++]=this.defaultCharSingleByte,this.leadSurrogate=-1),G.slice(0,q)}},O.prototype.findIdx=L;function N(G,q){this.nodeIdx=0,this.prevBytes=[],this.decodeTables=q.decodeTables,this.decodeTableSeq=q.decodeTableSeq,this.defaultCharUnicode=q.defaultCharUnicode,this.gb18030=q.gb18030}N.prototype.write=function(G){for(var q=t.alloc(G.length*2),J=this.nodeIdx,fe=this.prevBytes,ve=this.prevBytes.length,ne=-this.prevBytes.length,Ue,De=0,Ve=0;De<G.length;De++){var rt=De>=0?G[De]:fe[De+ve],Ue=this.decodeTables[J][rt];if(!(Ue>=0))if(Ue===e)Ue=this.defaultCharUnicode.charCodeAt(0),De=ne;else if(Ue===l){if(De>=3)var Ae=(G[De-3]-129)*12600+(G[De-2]-48)*1260+(G[De-1]-129)*10+(rt-48);else var Ae=(fe[De-3+ve]-129)*12600+((De-2>=0?G[De-2]:fe[De-2+ve])-48)*1260+((De-1>=0?G[De-1]:fe[De-1+ve])-129)*10+(rt-48);var Te=L(this.gb18030.gbChars,Ae);Ue=this.gb18030.uChars[Te]+Ae-this.gb18030.gbChars[Te]}else if(Ue<=u){J=u-Ue;continue}else if(Ue<=n){for(var Xe=this.decodeTableSeq[n-Ue],ie=0;ie<Xe.length-1;ie++)Ue=Xe[ie],q[Ve++]=Ue&255,q[Ve++]=Ue>>8;Ue=Xe[Xe.length-1]}else throw new Error("iconv-lite internal error: invalid decoding table value "+Ue+" at "+J+"/"+rt);if(Ue>=65536){Ue-=65536;var ue=55296|Ue>>10;q[Ve++]=ue&255,q[Ve++]=ue>>8,Ue=56320|Ue&1023}q[Ve++]=Ue&255,q[Ve++]=Ue>>8,J=0,ne=De+1}return this.nodeIdx=J,this.prevBytes=ne>=0?Array.prototype.slice.call(G,ne):fe.slice(ne+ve).concat(Array.prototype.slice.call(G)),q.slice(0,Ve).toString("ucs2")},N.prototype.end=function(){for(var G="";this.prevBytes.length>0;){G+=this.defaultCharUnicode;var q=this.prevBytes.slice(1);this.prevBytes=[],this.nodeIdx=0,q.length>0&&(G+=this.write(q))}return this.prevBytes=[],this.nodeIdx=0,G};function L(G,q){if(G[0]>q)return-1;for(var J=0,fe=G.length;J<fe-1;){var ve=J+(fe-J+1>>1);G[ve]<=q?J=ve:fe=ve}return J}return dbcsCodec}const require$$0=[["0","\0",128],["a1","。",62],["8140"," 、。,.・:;?!゛゜´`¨^ ̄_ヽヾゝゞ〃仝々〆〇ー―‐/\~∥|…‥‘’“”()〔〕[]{}〈",9,"+-±×"],["8180","÷=≠<>≦≧∞∴♂♀°′″℃¥$¢£%#&*@§☆★○●◎◇◆□■△▲▽▼※〒→←↑↓〓"],["81b8","∈∋⊆⊇⊂⊃∪∩"],["81c8","∧∨¬⇒⇔∀∃"],["81da","∠⊥⌒∂∇≡≒≪≫√∽∝∵∫∬"],["81f0","ʼn♯♭♪†‡¶"],["81fc","◯"],["824f","0",9],["8260","A",25],["8281","a",25],["829f","ぁ",82],["8340","ァ",62],["8380","ム",22],["839f","Α",16,"Σ",6],["83bf","α",16,"σ",6],["8440","А",5,"ЁЖ",25],["8470","а",5,"ёж",7],["8480","о",17],["849f","─│┌┐┘└├┬┤┴┼━┃┏┓┛┗┣┳┫┻╋┠┯┨┷┿┝┰┥┸╂"],["8740","①",19,"Ⅰ",9],["875f","㍉㌔㌢㍍㌘㌧㌃㌶㍑㍗㌍㌦㌣㌫㍊㌻㎜㎝㎞㎎㎏㏄㎡"],["877e","㍻"],["8780","〝〟№㏍℡㊤",4,"㈱㈲㈹㍾㍽㍼≒≡∫∮∑√⊥∠∟⊿∵∩∪"],["889f","亜唖娃阿哀愛挨姶逢葵茜穐悪握渥旭葦芦鯵梓圧斡扱宛姐虻飴絢綾鮎或粟袷安庵按暗案闇鞍杏以伊位依偉囲夷委威尉惟意慰易椅為畏異移維緯胃萎衣謂違遺医井亥域育郁磯一壱溢逸稲茨芋鰯允印咽員因姻引飲淫胤蔭"],["8940","院陰隠韻吋右宇烏羽迂雨卯鵜窺丑碓臼渦嘘唄欝蔚鰻姥厩浦瓜閏噂云運雲荏餌叡営嬰影映曳栄永泳洩瑛盈穎頴英衛詠鋭液疫益駅悦謁越閲榎厭円"],["8980","園堰奄宴延怨掩援沿演炎焔煙燕猿縁艶苑薗遠鉛鴛塩於汚甥凹央奥往応押旺横欧殴王翁襖鴬鴎黄岡沖荻億屋憶臆桶牡乙俺卸恩温穏音下化仮何伽価佳加可嘉夏嫁家寡科暇果架歌河火珂禍禾稼箇花苛茄荷華菓蝦課嘩貨迦過霞蚊俄峨我牙画臥芽蛾賀雅餓駕介会解回塊壊廻快怪悔恢懐戒拐改"],["8a40","魁晦械海灰界皆絵芥蟹開階貝凱劾外咳害崖慨概涯碍蓋街該鎧骸浬馨蛙垣柿蛎鈎劃嚇各廓拡撹格核殻獲確穫覚角赫較郭閣隔革学岳楽額顎掛笠樫"],["8a80","橿梶鰍潟割喝恰括活渇滑葛褐轄且鰹叶椛樺鞄株兜竃蒲釜鎌噛鴨栢茅萱粥刈苅瓦乾侃冠寒刊勘勧巻喚堪姦完官寛干幹患感慣憾換敢柑桓棺款歓汗漢澗潅環甘監看竿管簡緩缶翰肝艦莞観諌貫還鑑間閑関陥韓館舘丸含岸巌玩癌眼岩翫贋雁頑顔願企伎危喜器基奇嬉寄岐希幾忌揮机旗既期棋棄"],["8b40","機帰毅気汽畿祈季稀紀徽規記貴起軌輝飢騎鬼亀偽儀妓宜戯技擬欺犠疑祇義蟻誼議掬菊鞠吉吃喫桔橘詰砧杵黍却客脚虐逆丘久仇休及吸宮弓急救"],["8b80","朽求汲泣灸球究窮笈級糾給旧牛去居巨拒拠挙渠虚許距鋸漁禦魚亨享京供侠僑兇競共凶協匡卿叫喬境峡強彊怯恐恭挟教橋況狂狭矯胸脅興蕎郷鏡響饗驚仰凝尭暁業局曲極玉桐粁僅勤均巾錦斤欣欽琴禁禽筋緊芹菌衿襟謹近金吟銀九倶句区狗玖矩苦躯駆駈駒具愚虞喰空偶寓遇隅串櫛釧屑屈"],["8c40","掘窟沓靴轡窪熊隈粂栗繰桑鍬勲君薫訓群軍郡卦袈祁係傾刑兄啓圭珪型契形径恵慶慧憩掲携敬景桂渓畦稽系経継繋罫茎荊蛍計詣警軽頚鶏芸迎鯨"],["8c80","劇戟撃激隙桁傑欠決潔穴結血訣月件倹倦健兼券剣喧圏堅嫌建憲懸拳捲検権牽犬献研硯絹県肩見謙賢軒遣鍵険顕験鹸元原厳幻弦減源玄現絃舷言諺限乎個古呼固姑孤己庫弧戸故枯湖狐糊袴股胡菰虎誇跨鈷雇顧鼓五互伍午呉吾娯後御悟梧檎瑚碁語誤護醐乞鯉交佼侯候倖光公功効勾厚口向"],["8d40","后喉坑垢好孔孝宏工巧巷幸広庚康弘恒慌抗拘控攻昂晃更杭校梗構江洪浩港溝甲皇硬稿糠紅紘絞綱耕考肯肱腔膏航荒行衡講貢購郊酵鉱砿鋼閤降"],["8d80","項香高鴻剛劫号合壕拷濠豪轟麹克刻告国穀酷鵠黒獄漉腰甑忽惚骨狛込此頃今困坤墾婚恨懇昏昆根梱混痕紺艮魂些佐叉唆嵯左差査沙瑳砂詐鎖裟坐座挫債催再最哉塞妻宰彩才採栽歳済災采犀砕砦祭斎細菜裁載際剤在材罪財冴坂阪堺榊肴咲崎埼碕鷺作削咋搾昨朔柵窄策索錯桜鮭笹匙冊刷"],["8e40","察拶撮擦札殺薩雑皐鯖捌錆鮫皿晒三傘参山惨撒散桟燦珊産算纂蚕讃賛酸餐斬暫残仕仔伺使刺司史嗣四士始姉姿子屍市師志思指支孜斯施旨枝止"],["8e80","死氏獅祉私糸紙紫肢脂至視詞詩試誌諮資賜雌飼歯事似侍児字寺慈持時次滋治爾璽痔磁示而耳自蒔辞汐鹿式識鴫竺軸宍雫七叱執失嫉室悉湿漆疾質実蔀篠偲柴芝屡蕊縞舎写射捨赦斜煮社紗者謝車遮蛇邪借勺尺杓灼爵酌釈錫若寂弱惹主取守手朱殊狩珠種腫趣酒首儒受呪寿授樹綬需囚収周"],["8f40","宗就州修愁拾洲秀秋終繍習臭舟蒐衆襲讐蹴輯週酋酬集醜什住充十従戎柔汁渋獣縦重銃叔夙宿淑祝縮粛塾熟出術述俊峻春瞬竣舜駿准循旬楯殉淳"],["8f80","準潤盾純巡遵醇順処初所暑曙渚庶緒署書薯藷諸助叙女序徐恕鋤除傷償勝匠升召哨商唱嘗奨妾娼宵将小少尚庄床廠彰承抄招掌捷昇昌昭晶松梢樟樵沼消渉湘焼焦照症省硝礁祥称章笑粧紹肖菖蒋蕉衝裳訟証詔詳象賞醤鉦鍾鐘障鞘上丈丞乗冗剰城場壌嬢常情擾条杖浄状畳穣蒸譲醸錠嘱埴飾"],["9040","拭植殖燭織職色触食蝕辱尻伸信侵唇娠寝審心慎振新晋森榛浸深申疹真神秦紳臣芯薪親診身辛進針震人仁刃塵壬尋甚尽腎訊迅陣靭笥諏須酢図厨"],["9080","逗吹垂帥推水炊睡粋翠衰遂酔錐錘随瑞髄崇嵩数枢趨雛据杉椙菅頗雀裾澄摺寸世瀬畝是凄制勢姓征性成政整星晴棲栖正清牲生盛精聖声製西誠誓請逝醒青静斉税脆隻席惜戚斥昔析石積籍績脊責赤跡蹟碩切拙接摂折設窃節説雪絶舌蝉仙先千占宣専尖川戦扇撰栓栴泉浅洗染潜煎煽旋穿箭線"],["9140","繊羨腺舛船薦詮賎践選遷銭銑閃鮮前善漸然全禅繕膳糎噌塑岨措曾曽楚狙疏疎礎祖租粗素組蘇訴阻遡鼠僧創双叢倉喪壮奏爽宋層匝惣想捜掃挿掻"],["9180","操早曹巣槍槽漕燥争痩相窓糟総綜聡草荘葬蒼藻装走送遭鎗霜騒像増憎臓蔵贈造促側則即息捉束測足速俗属賊族続卒袖其揃存孫尊損村遜他多太汰詑唾堕妥惰打柁舵楕陀駄騨体堆対耐岱帯待怠態戴替泰滞胎腿苔袋貸退逮隊黛鯛代台大第醍題鷹滝瀧卓啄宅托択拓沢濯琢託鐸濁諾茸凧蛸只"],["9240","叩但達辰奪脱巽竪辿棚谷狸鱈樽誰丹単嘆坦担探旦歎淡湛炭短端箪綻耽胆蛋誕鍛団壇弾断暖檀段男談値知地弛恥智池痴稚置致蜘遅馳築畜竹筑蓄"],["9280","逐秩窒茶嫡着中仲宙忠抽昼柱注虫衷註酎鋳駐樗瀦猪苧著貯丁兆凋喋寵帖帳庁弔張彫徴懲挑暢朝潮牒町眺聴脹腸蝶調諜超跳銚長頂鳥勅捗直朕沈珍賃鎮陳津墜椎槌追鎚痛通塚栂掴槻佃漬柘辻蔦綴鍔椿潰坪壷嬬紬爪吊釣鶴亭低停偵剃貞呈堤定帝底庭廷弟悌抵挺提梯汀碇禎程締艇訂諦蹄逓"],["9340","邸鄭釘鼎泥摘擢敵滴的笛適鏑溺哲徹撤轍迭鉄典填天展店添纏甜貼転顛点伝殿澱田電兎吐堵塗妬屠徒斗杜渡登菟賭途都鍍砥砺努度土奴怒倒党冬"],["9380","凍刀唐塔塘套宕島嶋悼投搭東桃梼棟盗淘湯涛灯燈当痘祷等答筒糖統到董蕩藤討謄豆踏逃透鐙陶頭騰闘働動同堂導憧撞洞瞳童胴萄道銅峠鴇匿得徳涜特督禿篤毒独読栃橡凸突椴届鳶苫寅酉瀞噸屯惇敦沌豚遁頓呑曇鈍奈那内乍凪薙謎灘捺鍋楢馴縄畷南楠軟難汝二尼弐迩匂賑肉虹廿日乳入"],["9440","如尿韮任妊忍認濡禰祢寧葱猫熱年念捻撚燃粘乃廼之埜嚢悩濃納能脳膿農覗蚤巴把播覇杷波派琶破婆罵芭馬俳廃拝排敗杯盃牌背肺輩配倍培媒梅"],["9480","楳煤狽買売賠陪這蝿秤矧萩伯剥博拍柏泊白箔粕舶薄迫曝漠爆縛莫駁麦函箱硲箸肇筈櫨幡肌畑畠八鉢溌発醗髪伐罰抜筏閥鳩噺塙蛤隼伴判半反叛帆搬斑板氾汎版犯班畔繁般藩販範釆煩頒飯挽晩番盤磐蕃蛮匪卑否妃庇彼悲扉批披斐比泌疲皮碑秘緋罷肥被誹費避非飛樋簸備尾微枇毘琵眉美"],["9540","鼻柊稗匹疋髭彦膝菱肘弼必畢筆逼桧姫媛紐百謬俵彪標氷漂瓢票表評豹廟描病秒苗錨鋲蒜蛭鰭品彬斌浜瀕貧賓頻敏瓶不付埠夫婦富冨布府怖扶敷"],["9580","斧普浮父符腐膚芙譜負賦赴阜附侮撫武舞葡蕪部封楓風葺蕗伏副復幅服福腹複覆淵弗払沸仏物鮒分吻噴墳憤扮焚奮粉糞紛雰文聞丙併兵塀幣平弊柄並蔽閉陛米頁僻壁癖碧別瞥蔑箆偏変片篇編辺返遍便勉娩弁鞭保舗鋪圃捕歩甫補輔穂募墓慕戊暮母簿菩倣俸包呆報奉宝峰峯崩庖抱捧放方朋"],["9640","法泡烹砲縫胞芳萌蓬蜂褒訪豊邦鋒飽鳳鵬乏亡傍剖坊妨帽忘忙房暴望某棒冒紡肪膨謀貌貿鉾防吠頬北僕卜墨撲朴牧睦穆釦勃没殆堀幌奔本翻凡盆"],["9680","摩磨魔麻埋妹昧枚毎哩槙幕膜枕鮪柾鱒桝亦俣又抹末沫迄侭繭麿万慢満漫蔓味未魅巳箕岬密蜜湊蓑稔脈妙粍民眠務夢無牟矛霧鵡椋婿娘冥名命明盟迷銘鳴姪牝滅免棉綿緬面麺摸模茂妄孟毛猛盲網耗蒙儲木黙目杢勿餅尤戻籾貰問悶紋門匁也冶夜爺耶野弥矢厄役約薬訳躍靖柳薮鑓愉愈油癒"],["9740","諭輸唯佑優勇友宥幽悠憂揖有柚湧涌猶猷由祐裕誘遊邑郵雄融夕予余与誉輿預傭幼妖容庸揚揺擁曜楊様洋溶熔用窯羊耀葉蓉要謡踊遥陽養慾抑欲"],["9780","沃浴翌翼淀羅螺裸来莱頼雷洛絡落酪乱卵嵐欄濫藍蘭覧利吏履李梨理璃痢裏裡里離陸律率立葎掠略劉流溜琉留硫粒隆竜龍侶慮旅虜了亮僚両凌寮料梁涼猟療瞭稜糧良諒遼量陵領力緑倫厘林淋燐琳臨輪隣鱗麟瑠塁涙累類令伶例冷励嶺怜玲礼苓鈴隷零霊麗齢暦歴列劣烈裂廉恋憐漣煉簾練聯"],["9840","蓮連錬呂魯櫓炉賂路露労婁廊弄朗楼榔浪漏牢狼篭老聾蝋郎六麓禄肋録論倭和話歪賄脇惑枠鷲亙亘鰐詫藁蕨椀湾碗腕"],["989f","弌丐丕个丱丶丼丿乂乖乘亂亅豫亊舒弍于亞亟亠亢亰亳亶从仍仄仆仂仗仞仭仟价伉佚估佛佝佗佇佶侈侏侘佻佩佰侑佯來侖儘俔俟俎俘俛俑俚俐俤俥倚倨倔倪倥倅伜俶倡倩倬俾俯們倆偃假會偕偐偈做偖偬偸傀傚傅傴傲"],["9940","僉僊傳僂僖僞僥僭僣僮價僵儉儁儂儖儕儔儚儡儺儷儼儻儿兀兒兌兔兢竸兩兪兮冀冂囘册冉冏冑冓冕冖冤冦冢冩冪冫决冱冲冰况冽凅凉凛几處凩凭"],["9980","凰凵凾刄刋刔刎刧刪刮刳刹剏剄剋剌剞剔剪剴剩剳剿剽劍劔劒剱劈劑辨辧劬劭劼劵勁勍勗勞勣勦飭勠勳勵勸勹匆匈甸匍匐匏匕匚匣匯匱匳匸區卆卅丗卉卍凖卞卩卮夘卻卷厂厖厠厦厥厮厰厶參簒雙叟曼燮叮叨叭叺吁吽呀听吭吼吮吶吩吝呎咏呵咎呟呱呷呰咒呻咀呶咄咐咆哇咢咸咥咬哄哈咨"],["9a40","咫哂咤咾咼哘哥哦唏唔哽哮哭哺哢唹啀啣啌售啜啅啖啗唸唳啝喙喀咯喊喟啻啾喘喞單啼喃喩喇喨嗚嗅嗟嗄嗜嗤嗔嘔嗷嘖嗾嗽嘛嗹噎噐營嘴嘶嘲嘸"],["9a80","噫噤嘯噬噪嚆嚀嚊嚠嚔嚏嚥嚮嚶嚴囂嚼囁囃囀囈囎囑囓囗囮囹圀囿圄圉圈國圍圓團圖嗇圜圦圷圸坎圻址坏坩埀垈坡坿垉垓垠垳垤垪垰埃埆埔埒埓堊埖埣堋堙堝塲堡塢塋塰毀塒堽塹墅墹墟墫墺壞墻墸墮壅壓壑壗壙壘壥壜壤壟壯壺壹壻壼壽夂夊夐夛梦夥夬夭夲夸夾竒奕奐奎奚奘奢奠奧奬奩"],["9b40","奸妁妝佞侫妣妲姆姨姜妍姙姚娥娟娑娜娉娚婀婬婉娵娶婢婪媚媼媾嫋嫂媽嫣嫗嫦嫩嫖嫺嫻嬌嬋嬖嬲嫐嬪嬶嬾孃孅孀孑孕孚孛孥孩孰孳孵學斈孺宀"],["9b80","它宦宸寃寇寉寔寐寤實寢寞寥寫寰寶寳尅將專對尓尠尢尨尸尹屁屆屎屓屐屏孱屬屮乢屶屹岌岑岔妛岫岻岶岼岷峅岾峇峙峩峽峺峭嶌峪崋崕崗嵜崟崛崑崔崢崚崙崘嵌嵒嵎嵋嵬嵳嵶嶇嶄嶂嶢嶝嶬嶮嶽嶐嶷嶼巉巍巓巒巖巛巫已巵帋帚帙帑帛帶帷幄幃幀幎幗幔幟幢幤幇幵并幺麼广庠廁廂廈廐廏"],["9c40","廖廣廝廚廛廢廡廨廩廬廱廳廰廴廸廾弃弉彝彜弋弑弖弩弭弸彁彈彌彎弯彑彖彗彙彡彭彳彷徃徂彿徊很徑徇從徙徘徠徨徭徼忖忻忤忸忱忝悳忿怡恠"],["9c80","怙怐怩怎怱怛怕怫怦怏怺恚恁恪恷恟恊恆恍恣恃恤恂恬恫恙悁悍惧悃悚悄悛悖悗悒悧悋惡悸惠惓悴忰悽惆悵惘慍愕愆惶惷愀惴惺愃愡惻惱愍愎慇愾愨愧慊愿愼愬愴愽慂慄慳慷慘慙慚慫慴慯慥慱慟慝慓慵憙憖憇憬憔憚憊憑憫憮懌懊應懷懈懃懆憺懋罹懍懦懣懶懺懴懿懽懼懾戀戈戉戍戌戔戛"],["9d40","戞戡截戮戰戲戳扁扎扞扣扛扠扨扼抂抉找抒抓抖拔抃抔拗拑抻拏拿拆擔拈拜拌拊拂拇抛拉挌拮拱挧挂挈拯拵捐挾捍搜捏掖掎掀掫捶掣掏掉掟掵捫"],["9d80","捩掾揩揀揆揣揉插揶揄搖搴搆搓搦搶攝搗搨搏摧摯摶摎攪撕撓撥撩撈撼據擒擅擇撻擘擂擱擧舉擠擡抬擣擯攬擶擴擲擺攀擽攘攜攅攤攣攫攴攵攷收攸畋效敖敕敍敘敞敝敲數斂斃變斛斟斫斷旃旆旁旄旌旒旛旙无旡旱杲昊昃旻杳昵昶昴昜晏晄晉晁晞晝晤晧晨晟晢晰暃暈暎暉暄暘暝曁暹曉暾暼"],["9e40","曄暸曖曚曠昿曦曩曰曵曷朏朖朞朦朧霸朮朿朶杁朸朷杆杞杠杙杣杤枉杰枩杼杪枌枋枦枡枅枷柯枴柬枳柩枸柤柞柝柢柮枹柎柆柧檜栞框栩桀桍栲桎"],["9e80","梳栫桙档桷桿梟梏梭梔條梛梃檮梹桴梵梠梺椏梍桾椁棊椈棘椢椦棡椌棍棔棧棕椶椒椄棗棣椥棹棠棯椨椪椚椣椡棆楹楷楜楸楫楔楾楮椹楴椽楙椰楡楞楝榁楪榲榮槐榿槁槓榾槎寨槊槝榻槃榧樮榑榠榜榕榴槞槨樂樛槿權槹槲槧樅榱樞槭樔槫樊樒櫁樣樓橄樌橲樶橸橇橢橙橦橈樸樢檐檍檠檄檢檣"],["9f40","檗蘗檻櫃櫂檸檳檬櫞櫑櫟檪櫚櫪櫻欅蘖櫺欒欖鬱欟欸欷盜欹飮歇歃歉歐歙歔歛歟歡歸歹歿殀殄殃殍殘殕殞殤殪殫殯殲殱殳殷殼毆毋毓毟毬毫毳毯"],["9f80","麾氈氓气氛氤氣汞汕汢汪沂沍沚沁沛汾汨汳沒沐泄泱泓沽泗泅泝沮沱沾沺泛泯泙泪洟衍洶洫洽洸洙洵洳洒洌浣涓浤浚浹浙涎涕濤涅淹渕渊涵淇淦涸淆淬淞淌淨淒淅淺淙淤淕淪淮渭湮渮渙湲湟渾渣湫渫湶湍渟湃渺湎渤滿渝游溂溪溘滉溷滓溽溯滄溲滔滕溏溥滂溟潁漑灌滬滸滾漿滲漱滯漲滌"],["e040","漾漓滷澆潺潸澁澀潯潛濳潭澂潼潘澎澑濂潦澳澣澡澤澹濆澪濟濕濬濔濘濱濮濛瀉瀋濺瀑瀁瀏濾瀛瀚潴瀝瀘瀟瀰瀾瀲灑灣炙炒炯烱炬炸炳炮烟烋烝"],["e080","烙焉烽焜焙煥煕熈煦煢煌煖煬熏燻熄熕熨熬燗熹熾燒燉燔燎燠燬燧燵燼燹燿爍爐爛爨爭爬爰爲爻爼爿牀牆牋牘牴牾犂犁犇犒犖犢犧犹犲狃狆狄狎狒狢狠狡狹狷倏猗猊猜猖猝猴猯猩猥猾獎獏默獗獪獨獰獸獵獻獺珈玳珎玻珀珥珮珞璢琅瑯琥珸琲琺瑕琿瑟瑙瑁瑜瑩瑰瑣瑪瑶瑾璋璞璧瓊瓏瓔珱"],["e140","瓠瓣瓧瓩瓮瓲瓰瓱瓸瓷甄甃甅甌甎甍甕甓甞甦甬甼畄畍畊畉畛畆畚畩畤畧畫畭畸當疆疇畴疊疉疂疔疚疝疥疣痂疳痃疵疽疸疼疱痍痊痒痙痣痞痾痿"],["e180","痼瘁痰痺痲痳瘋瘍瘉瘟瘧瘠瘡瘢瘤瘴瘰瘻癇癈癆癜癘癡癢癨癩癪癧癬癰癲癶癸發皀皃皈皋皎皖皓皙皚皰皴皸皹皺盂盍盖盒盞盡盥盧盪蘯盻眈眇眄眩眤眞眥眦眛眷眸睇睚睨睫睛睥睿睾睹瞎瞋瞑瞠瞞瞰瞶瞹瞿瞼瞽瞻矇矍矗矚矜矣矮矼砌砒礦砠礪硅碎硴碆硼碚碌碣碵碪碯磑磆磋磔碾碼磅磊磬"],["e240","磧磚磽磴礇礒礑礙礬礫祀祠祗祟祚祕祓祺祿禊禝禧齋禪禮禳禹禺秉秕秧秬秡秣稈稍稘稙稠稟禀稱稻稾稷穃穗穉穡穢穩龝穰穹穽窈窗窕窘窖窩竈窰"],["e280","窶竅竄窿邃竇竊竍竏竕竓站竚竝竡竢竦竭竰笂笏笊笆笳笘笙笞笵笨笶筐筺笄筍笋筌筅筵筥筴筧筰筱筬筮箝箘箟箍箜箚箋箒箏筝箙篋篁篌篏箴篆篝篩簑簔篦篥籠簀簇簓篳篷簗簍篶簣簧簪簟簷簫簽籌籃籔籏籀籐籘籟籤籖籥籬籵粃粐粤粭粢粫粡粨粳粲粱粮粹粽糀糅糂糘糒糜糢鬻糯糲糴糶糺紆"],["e340","紂紜紕紊絅絋紮紲紿紵絆絳絖絎絲絨絮絏絣經綉絛綏絽綛綺綮綣綵緇綽綫總綢綯緜綸綟綰緘緝緤緞緻緲緡縅縊縣縡縒縱縟縉縋縢繆繦縻縵縹繃縷"],["e380","縲縺繧繝繖繞繙繚繹繪繩繼繻纃緕繽辮繿纈纉續纒纐纓纔纖纎纛纜缸缺罅罌罍罎罐网罕罔罘罟罠罨罩罧罸羂羆羃羈羇羌羔羞羝羚羣羯羲羹羮羶羸譱翅翆翊翕翔翡翦翩翳翹飜耆耄耋耒耘耙耜耡耨耿耻聊聆聒聘聚聟聢聨聳聲聰聶聹聽聿肄肆肅肛肓肚肭冐肬胛胥胙胝胄胚胖脉胯胱脛脩脣脯腋"],["e440","隋腆脾腓腑胼腱腮腥腦腴膃膈膊膀膂膠膕膤膣腟膓膩膰膵膾膸膽臀臂膺臉臍臑臙臘臈臚臟臠臧臺臻臾舁舂舅與舊舍舐舖舩舫舸舳艀艙艘艝艚艟艤"],["e480","艢艨艪艫舮艱艷艸艾芍芒芫芟芻芬苡苣苟苒苴苳苺莓范苻苹苞茆苜茉苙茵茴茖茲茱荀茹荐荅茯茫茗茘莅莚莪莟莢莖茣莎莇莊荼莵荳荵莠莉莨菴萓菫菎菽萃菘萋菁菷萇菠菲萍萢萠莽萸蔆菻葭萪萼蕚蒄葷葫蒭葮蒂葩葆萬葯葹萵蓊葢蒹蒿蒟蓙蓍蒻蓚蓐蓁蓆蓖蒡蔡蓿蓴蔗蔘蔬蔟蔕蔔蓼蕀蕣蕘蕈"],["e540","蕁蘂蕋蕕薀薤薈薑薊薨蕭薔薛藪薇薜蕷蕾薐藉薺藏薹藐藕藝藥藜藹蘊蘓蘋藾藺蘆蘢蘚蘰蘿虍乕虔號虧虱蚓蚣蚩蚪蚋蚌蚶蚯蛄蛆蚰蛉蠣蚫蛔蛞蛩蛬"],["e580","蛟蛛蛯蜒蜆蜈蜀蜃蛻蜑蜉蜍蛹蜊蜴蜿蜷蜻蜥蜩蜚蝠蝟蝸蝌蝎蝴蝗蝨蝮蝙蝓蝣蝪蠅螢螟螂螯蟋螽蟀蟐雖螫蟄螳蟇蟆螻蟯蟲蟠蠏蠍蟾蟶蟷蠎蟒蠑蠖蠕蠢蠡蠱蠶蠹蠧蠻衄衂衒衙衞衢衫袁衾袞衵衽袵衲袂袗袒袮袙袢袍袤袰袿袱裃裄裔裘裙裝裹褂裼裴裨裲褄褌褊褓襃褞褥褪褫襁襄褻褶褸襌褝襠襞"],["e640","襦襤襭襪襯襴襷襾覃覈覊覓覘覡覩覦覬覯覲覺覽覿觀觚觜觝觧觴觸訃訖訐訌訛訝訥訶詁詛詒詆詈詼詭詬詢誅誂誄誨誡誑誥誦誚誣諄諍諂諚諫諳諧"],["e680","諤諱謔諠諢諷諞諛謌謇謚諡謖謐謗謠謳鞫謦謫謾謨譁譌譏譎證譖譛譚譫譟譬譯譴譽讀讌讎讒讓讖讙讚谺豁谿豈豌豎豐豕豢豬豸豺貂貉貅貊貍貎貔豼貘戝貭貪貽貲貳貮貶賈賁賤賣賚賽賺賻贄贅贊贇贏贍贐齎贓賍贔贖赧赭赱赳趁趙跂趾趺跏跚跖跌跛跋跪跫跟跣跼踈踉跿踝踞踐踟蹂踵踰踴蹊"],["e740","蹇蹉蹌蹐蹈蹙蹤蹠踪蹣蹕蹶蹲蹼躁躇躅躄躋躊躓躑躔躙躪躡躬躰軆躱躾軅軈軋軛軣軼軻軫軾輊輅輕輒輙輓輜輟輛輌輦輳輻輹轅轂輾轌轉轆轎轗轜"],["e780","轢轣轤辜辟辣辭辯辷迚迥迢迪迯邇迴逅迹迺逑逕逡逍逞逖逋逧逶逵逹迸遏遐遑遒逎遉逾遖遘遞遨遯遶隨遲邂遽邁邀邊邉邏邨邯邱邵郢郤扈郛鄂鄒鄙鄲鄰酊酖酘酣酥酩酳酲醋醉醂醢醫醯醪醵醴醺釀釁釉釋釐釖釟釡釛釼釵釶鈞釿鈔鈬鈕鈑鉞鉗鉅鉉鉤鉈銕鈿鉋鉐銜銖銓銛鉚鋏銹銷鋩錏鋺鍄錮"],["e840","錙錢錚錣錺錵錻鍜鍠鍼鍮鍖鎰鎬鎭鎔鎹鏖鏗鏨鏥鏘鏃鏝鏐鏈鏤鐚鐔鐓鐃鐇鐐鐶鐫鐵鐡鐺鑁鑒鑄鑛鑠鑢鑞鑪鈩鑰鑵鑷鑽鑚鑼鑾钁鑿閂閇閊閔閖閘閙"],["e880","閠閨閧閭閼閻閹閾闊濶闃闍闌闕闔闖關闡闥闢阡阨阮阯陂陌陏陋陷陜陞陝陟陦陲陬隍隘隕隗險隧隱隲隰隴隶隸隹雎雋雉雍襍雜霍雕雹霄霆霈霓霎霑霏霖霙霤霪霰霹霽霾靄靆靈靂靉靜靠靤靦靨勒靫靱靹鞅靼鞁靺鞆鞋鞏鞐鞜鞨鞦鞣鞳鞴韃韆韈韋韜韭齏韲竟韶韵頏頌頸頤頡頷頽顆顏顋顫顯顰"],["e940","顱顴顳颪颯颱颶飄飃飆飩飫餃餉餒餔餘餡餝餞餤餠餬餮餽餾饂饉饅饐饋饑饒饌饕馗馘馥馭馮馼駟駛駝駘駑駭駮駱駲駻駸騁騏騅駢騙騫騷驅驂驀驃"],["e980","騾驕驍驛驗驟驢驥驤驩驫驪骭骰骼髀髏髑髓體髞髟髢髣髦髯髫髮髴髱髷髻鬆鬘鬚鬟鬢鬣鬥鬧鬨鬩鬪鬮鬯鬲魄魃魏魍魎魑魘魴鮓鮃鮑鮖鮗鮟鮠鮨鮴鯀鯊鮹鯆鯏鯑鯒鯣鯢鯤鯔鯡鰺鯲鯱鯰鰕鰔鰉鰓鰌鰆鰈鰒鰊鰄鰮鰛鰥鰤鰡鰰鱇鰲鱆鰾鱚鱠鱧鱶鱸鳧鳬鳰鴉鴈鳫鴃鴆鴪鴦鶯鴣鴟鵄鴕鴒鵁鴿鴾鵆鵈"],["ea40","鵝鵞鵤鵑鵐鵙鵲鶉鶇鶫鵯鵺鶚鶤鶩鶲鷄鷁鶻鶸鶺鷆鷏鷂鷙鷓鷸鷦鷭鷯鷽鸚鸛鸞鹵鹹鹽麁麈麋麌麒麕麑麝麥麩麸麪麭靡黌黎黏黐黔黜點黝黠黥黨黯"],["ea80","黴黶黷黹黻黼黽鼇鼈皷鼕鼡鼬鼾齊齒齔齣齟齠齡齦齧齬齪齷齲齶龕龜龠堯槇遙瑤凜熙"],["ed40","纊褜鍈銈蓜俉炻昱棈鋹曻彅丨仡仼伀伃伹佖侒侊侚侔俍偀倢俿倞偆偰偂傔僴僘兊兤冝冾凬刕劜劦勀勛匀匇匤卲厓厲叝﨎咜咊咩哿喆坙坥垬埈埇﨏"],["ed80","塚增墲夋奓奛奝奣妤妺孖寀甯寘寬尞岦岺峵崧嵓﨑嵂嵭嶸嶹巐弡弴彧德忞恝悅悊惞惕愠惲愑愷愰憘戓抦揵摠撝擎敎昀昕昻昉昮昞昤晥晗晙晴晳暙暠暲暿曺朎朗杦枻桒柀栁桄棏﨓楨﨔榘槢樰橫橆橳橾櫢櫤毖氿汜沆汯泚洄涇浯涖涬淏淸淲淼渹湜渧渼溿澈澵濵瀅瀇瀨炅炫焏焄煜煆煇凞燁燾犱"],["ee40","犾猤猪獷玽珉珖珣珒琇珵琦琪琩琮瑢璉璟甁畯皂皜皞皛皦益睆劯砡硎硤硺礰礼神祥禔福禛竑竧靖竫箞精絈絜綷綠緖繒罇羡羽茁荢荿菇菶葈蒴蕓蕙"],["ee80","蕫﨟薰蘒﨡蠇裵訒訷詹誧誾諟諸諶譓譿賰賴贒赶﨣軏﨤逸遧郞都鄕鄧釚釗釞釭釮釤釥鈆鈐鈊鈺鉀鈼鉎鉙鉑鈹鉧銧鉷鉸鋧鋗鋙鋐﨧鋕鋠鋓錥錡鋻﨨錞鋿錝錂鍰鍗鎤鏆鏞鏸鐱鑅鑈閒隆﨩隝隯霳霻靃靍靏靑靕顗顥飯飼餧館馞驎髙髜魵魲鮏鮱鮻鰀鵰鵫鶴鸙黑"],["eeef","ⅰ",9,"¬¦'""],["f040","",62],["f080","",124],["f140","",62],["f180","",124],["f240","",62],["f280","",124],["f340","",62],["f380","",124],["f440","",62],["f480","",124],["f540","",62],["f580","",124],["f640","",62],["f680","",124],["f740","",62],["f780","",124],["f840","",62],["f880","",124],["f940",""],["fa40","ⅰ",9,"Ⅰ",9,"¬¦'"㈱№℡∵纊褜鍈銈蓜俉炻昱棈鋹曻彅丨仡仼伀伃伹佖侒侊侚侔俍偀倢俿倞偆偰偂傔僴僘兊"],["fa80","兤冝冾凬刕劜劦勀勛匀匇匤卲厓厲叝﨎咜咊咩哿喆坙坥垬埈埇﨏塚增墲夋奓奛奝奣妤妺孖寀甯寘寬尞岦岺峵崧嵓﨑嵂嵭嶸嶹巐弡弴彧德忞恝悅悊惞惕愠惲愑愷愰憘戓抦揵摠撝擎敎昀昕昻昉昮昞昤晥晗晙晴晳暙暠暲暿曺朎朗杦枻桒柀栁桄棏﨓楨﨔榘槢樰橫橆橳橾櫢櫤毖氿汜沆汯泚洄涇浯"],["fb40","涖涬淏淸淲淼渹湜渧渼溿澈澵濵瀅瀇瀨炅炫焏焄煜煆煇凞燁燾犱犾猤猪獷玽珉珖珣珒琇珵琦琪琩琮瑢璉璟甁畯皂皜皞皛皦益睆劯砡硎硤硺礰礼神"],["fb80","祥禔福禛竑竧靖竫箞精絈絜綷綠緖繒罇羡羽茁荢荿菇菶葈蒴蕓蕙蕫﨟薰蘒﨡蠇裵訒訷詹誧誾諟諸諶譓譿賰賴贒赶﨣軏﨤逸遧郞都鄕鄧釚釗釞釭釮釤釥鈆鈐鈊鈺鉀鈼鉎鉙鉑鈹鉧銧鉷鉸鋧鋗鋙鋐﨧鋕鋠鋓錥錡鋻﨨錞鋿錝錂鍰鍗鎤鏆鏞鏸鐱鑅鑈閒隆﨩隝隯霳霻靃靍靏靑靕顗顥飯飼餧館馞驎髙"],["fc40","髜魵魲鮏鮱鮻鰀鵰鵫鶴鸙黑"]],require$$1=[["0","\0",127],["8ea1","。",62],["a1a1"," 、。,.・:;?!゛゜´`¨^ ̄_ヽヾゝゞ〃仝々〆〇ー―‐/\~∥|…‥‘’“”()〔〕[]{}〈",9,"+-±×÷=≠<>≦≧∞∴♂♀°′″℃¥$¢£%#&*@§☆★○●◎◇"],["a2a1","◆□■△▲▽▼※〒→←↑↓〓"],["a2ba","∈∋⊆⊇⊂⊃∪∩"],["a2ca","∧∨¬⇒⇔∀∃"],["a2dc","∠⊥⌒∂∇≡≒≪≫√∽∝∵∫∬"],["a2f2","ʼn♯♭♪†‡¶"],["a2fe","◯"],["a3b0","0",9],["a3c1","A",25],["a3e1","a",25],["a4a1","ぁ",82],["a5a1","ァ",85],["a6a1","Α",16,"Σ",6],["a6c1","α",16,"σ",6],["a7a1","А",5,"ЁЖ",25],["a7d1","а",5,"ёж",25],["a8a1","─│┌┐┘└├┬┤┴┼━┃┏┓┛┗┣┳┫┻╋┠┯┨┷┿┝┰┥┸╂"],["ada1","①",19,"Ⅰ",9],["adc0","㍉㌔㌢㍍㌘㌧㌃㌶㍑㍗㌍㌦㌣㌫㍊㌻㎜㎝㎞㎎㎏㏄㎡"],["addf","㍻〝〟№㏍℡㊤",4,"㈱㈲㈹㍾㍽㍼≒≡∫∮∑√⊥∠∟⊿∵∩∪"],["b0a1","亜唖娃阿哀愛挨姶逢葵茜穐悪握渥旭葦芦鯵梓圧斡扱宛姐虻飴絢綾鮎或粟袷安庵按暗案闇鞍杏以伊位依偉囲夷委威尉惟意慰易椅為畏異移維緯胃萎衣謂違遺医井亥域育郁磯一壱溢逸稲茨芋鰯允印咽員因姻引飲淫胤蔭"],["b1a1","院陰隠韻吋右宇烏羽迂雨卯鵜窺丑碓臼渦嘘唄欝蔚鰻姥厩浦瓜閏噂云運雲荏餌叡営嬰影映曳栄永泳洩瑛盈穎頴英衛詠鋭液疫益駅悦謁越閲榎厭円園堰奄宴延怨掩援沿演炎焔煙燕猿縁艶苑薗遠鉛鴛塩於汚甥凹央奥往応"],["b2a1","押旺横欧殴王翁襖鴬鴎黄岡沖荻億屋憶臆桶牡乙俺卸恩温穏音下化仮何伽価佳加可嘉夏嫁家寡科暇果架歌河火珂禍禾稼箇花苛茄荷華菓蝦課嘩貨迦過霞蚊俄峨我牙画臥芽蛾賀雅餓駕介会解回塊壊廻快怪悔恢懐戒拐改"],["b3a1","魁晦械海灰界皆絵芥蟹開階貝凱劾外咳害崖慨概涯碍蓋街該鎧骸浬馨蛙垣柿蛎鈎劃嚇各廓拡撹格核殻獲確穫覚角赫較郭閣隔革学岳楽額顎掛笠樫橿梶鰍潟割喝恰括活渇滑葛褐轄且鰹叶椛樺鞄株兜竃蒲釜鎌噛鴨栢茅萱"],["b4a1","粥刈苅瓦乾侃冠寒刊勘勧巻喚堪姦完官寛干幹患感慣憾換敢柑桓棺款歓汗漢澗潅環甘監看竿管簡緩缶翰肝艦莞観諌貫還鑑間閑関陥韓館舘丸含岸巌玩癌眼岩翫贋雁頑顔願企伎危喜器基奇嬉寄岐希幾忌揮机旗既期棋棄"],["b5a1","機帰毅気汽畿祈季稀紀徽規記貴起軌輝飢騎鬼亀偽儀妓宜戯技擬欺犠疑祇義蟻誼議掬菊鞠吉吃喫桔橘詰砧杵黍却客脚虐逆丘久仇休及吸宮弓急救朽求汲泣灸球究窮笈級糾給旧牛去居巨拒拠挙渠虚許距鋸漁禦魚亨享京"],["b6a1","供侠僑兇競共凶協匡卿叫喬境峡強彊怯恐恭挟教橋況狂狭矯胸脅興蕎郷鏡響饗驚仰凝尭暁業局曲極玉桐粁僅勤均巾錦斤欣欽琴禁禽筋緊芹菌衿襟謹近金吟銀九倶句区狗玖矩苦躯駆駈駒具愚虞喰空偶寓遇隅串櫛釧屑屈"],["b7a1","掘窟沓靴轡窪熊隈粂栗繰桑鍬勲君薫訓群軍郡卦袈祁係傾刑兄啓圭珪型契形径恵慶慧憩掲携敬景桂渓畦稽系経継繋罫茎荊蛍計詣警軽頚鶏芸迎鯨劇戟撃激隙桁傑欠決潔穴結血訣月件倹倦健兼券剣喧圏堅嫌建憲懸拳捲"],["b8a1","検権牽犬献研硯絹県肩見謙賢軒遣鍵険顕験鹸元原厳幻弦減源玄現絃舷言諺限乎個古呼固姑孤己庫弧戸故枯湖狐糊袴股胡菰虎誇跨鈷雇顧鼓五互伍午呉吾娯後御悟梧檎瑚碁語誤護醐乞鯉交佼侯候倖光公功効勾厚口向"],["b9a1","后喉坑垢好孔孝宏工巧巷幸広庚康弘恒慌抗拘控攻昂晃更杭校梗構江洪浩港溝甲皇硬稿糠紅紘絞綱耕考肯肱腔膏航荒行衡講貢購郊酵鉱砿鋼閤降項香高鴻剛劫号合壕拷濠豪轟麹克刻告国穀酷鵠黒獄漉腰甑忽惚骨狛込"],["baa1","此頃今困坤墾婚恨懇昏昆根梱混痕紺艮魂些佐叉唆嵯左差査沙瑳砂詐鎖裟坐座挫債催再最哉塞妻宰彩才採栽歳済災采犀砕砦祭斎細菜裁載際剤在材罪財冴坂阪堺榊肴咲崎埼碕鷺作削咋搾昨朔柵窄策索錯桜鮭笹匙冊刷"],["bba1","察拶撮擦札殺薩雑皐鯖捌錆鮫皿晒三傘参山惨撒散桟燦珊産算纂蚕讃賛酸餐斬暫残仕仔伺使刺司史嗣四士始姉姿子屍市師志思指支孜斯施旨枝止死氏獅祉私糸紙紫肢脂至視詞詩試誌諮資賜雌飼歯事似侍児字寺慈持時"],["bca1","次滋治爾璽痔磁示而耳自蒔辞汐鹿式識鴫竺軸宍雫七叱執失嫉室悉湿漆疾質実蔀篠偲柴芝屡蕊縞舎写射捨赦斜煮社紗者謝車遮蛇邪借勺尺杓灼爵酌釈錫若寂弱惹主取守手朱殊狩珠種腫趣酒首儒受呪寿授樹綬需囚収周"],["bda1","宗就州修愁拾洲秀秋終繍習臭舟蒐衆襲讐蹴輯週酋酬集醜什住充十従戎柔汁渋獣縦重銃叔夙宿淑祝縮粛塾熟出術述俊峻春瞬竣舜駿准循旬楯殉淳準潤盾純巡遵醇順処初所暑曙渚庶緒署書薯藷諸助叙女序徐恕鋤除傷償"],["bea1","勝匠升召哨商唱嘗奨妾娼宵将小少尚庄床廠彰承抄招掌捷昇昌昭晶松梢樟樵沼消渉湘焼焦照症省硝礁祥称章笑粧紹肖菖蒋蕉衝裳訟証詔詳象賞醤鉦鍾鐘障鞘上丈丞乗冗剰城場壌嬢常情擾条杖浄状畳穣蒸譲醸錠嘱埴飾"],["bfa1","拭植殖燭織職色触食蝕辱尻伸信侵唇娠寝審心慎振新晋森榛浸深申疹真神秦紳臣芯薪親診身辛進針震人仁刃塵壬尋甚尽腎訊迅陣靭笥諏須酢図厨逗吹垂帥推水炊睡粋翠衰遂酔錐錘随瑞髄崇嵩数枢趨雛据杉椙菅頗雀裾"],["c0a1","澄摺寸世瀬畝是凄制勢姓征性成政整星晴棲栖正清牲生盛精聖声製西誠誓請逝醒青静斉税脆隻席惜戚斥昔析石積籍績脊責赤跡蹟碩切拙接摂折設窃節説雪絶舌蝉仙先千占宣専尖川戦扇撰栓栴泉浅洗染潜煎煽旋穿箭線"],["c1a1","繊羨腺舛船薦詮賎践選遷銭銑閃鮮前善漸然全禅繕膳糎噌塑岨措曾曽楚狙疏疎礎祖租粗素組蘇訴阻遡鼠僧創双叢倉喪壮奏爽宋層匝惣想捜掃挿掻操早曹巣槍槽漕燥争痩相窓糟総綜聡草荘葬蒼藻装走送遭鎗霜騒像増憎"],["c2a1","臓蔵贈造促側則即息捉束測足速俗属賊族続卒袖其揃存孫尊損村遜他多太汰詑唾堕妥惰打柁舵楕陀駄騨体堆対耐岱帯待怠態戴替泰滞胎腿苔袋貸退逮隊黛鯛代台大第醍題鷹滝瀧卓啄宅托択拓沢濯琢託鐸濁諾茸凧蛸只"],["c3a1","叩但達辰奪脱巽竪辿棚谷狸鱈樽誰丹単嘆坦担探旦歎淡湛炭短端箪綻耽胆蛋誕鍛団壇弾断暖檀段男談値知地弛恥智池痴稚置致蜘遅馳築畜竹筑蓄逐秩窒茶嫡着中仲宙忠抽昼柱注虫衷註酎鋳駐樗瀦猪苧著貯丁兆凋喋寵"],["c4a1","帖帳庁弔張彫徴懲挑暢朝潮牒町眺聴脹腸蝶調諜超跳銚長頂鳥勅捗直朕沈珍賃鎮陳津墜椎槌追鎚痛通塚栂掴槻佃漬柘辻蔦綴鍔椿潰坪壷嬬紬爪吊釣鶴亭低停偵剃貞呈堤定帝底庭廷弟悌抵挺提梯汀碇禎程締艇訂諦蹄逓"],["c5a1","邸鄭釘鼎泥摘擢敵滴的笛適鏑溺哲徹撤轍迭鉄典填天展店添纏甜貼転顛点伝殿澱田電兎吐堵塗妬屠徒斗杜渡登菟賭途都鍍砥砺努度土奴怒倒党冬凍刀唐塔塘套宕島嶋悼投搭東桃梼棟盗淘湯涛灯燈当痘祷等答筒糖統到"],["c6a1","董蕩藤討謄豆踏逃透鐙陶頭騰闘働動同堂導憧撞洞瞳童胴萄道銅峠鴇匿得徳涜特督禿篤毒独読栃橡凸突椴届鳶苫寅酉瀞噸屯惇敦沌豚遁頓呑曇鈍奈那内乍凪薙謎灘捺鍋楢馴縄畷南楠軟難汝二尼弐迩匂賑肉虹廿日乳入"],["c7a1","如尿韮任妊忍認濡禰祢寧葱猫熱年念捻撚燃粘乃廼之埜嚢悩濃納能脳膿農覗蚤巴把播覇杷波派琶破婆罵芭馬俳廃拝排敗杯盃牌背肺輩配倍培媒梅楳煤狽買売賠陪這蝿秤矧萩伯剥博拍柏泊白箔粕舶薄迫曝漠爆縛莫駁麦"],["c8a1","函箱硲箸肇筈櫨幡肌畑畠八鉢溌発醗髪伐罰抜筏閥鳩噺塙蛤隼伴判半反叛帆搬斑板氾汎版犯班畔繁般藩販範釆煩頒飯挽晩番盤磐蕃蛮匪卑否妃庇彼悲扉批披斐比泌疲皮碑秘緋罷肥被誹費避非飛樋簸備尾微枇毘琵眉美"],["c9a1","鼻柊稗匹疋髭彦膝菱肘弼必畢筆逼桧姫媛紐百謬俵彪標氷漂瓢票表評豹廟描病秒苗錨鋲蒜蛭鰭品彬斌浜瀕貧賓頻敏瓶不付埠夫婦富冨布府怖扶敷斧普浮父符腐膚芙譜負賦赴阜附侮撫武舞葡蕪部封楓風葺蕗伏副復幅服"],["caa1","福腹複覆淵弗払沸仏物鮒分吻噴墳憤扮焚奮粉糞紛雰文聞丙併兵塀幣平弊柄並蔽閉陛米頁僻壁癖碧別瞥蔑箆偏変片篇編辺返遍便勉娩弁鞭保舗鋪圃捕歩甫補輔穂募墓慕戊暮母簿菩倣俸包呆報奉宝峰峯崩庖抱捧放方朋"],["cba1","法泡烹砲縫胞芳萌蓬蜂褒訪豊邦鋒飽鳳鵬乏亡傍剖坊妨帽忘忙房暴望某棒冒紡肪膨謀貌貿鉾防吠頬北僕卜墨撲朴牧睦穆釦勃没殆堀幌奔本翻凡盆摩磨魔麻埋妹昧枚毎哩槙幕膜枕鮪柾鱒桝亦俣又抹末沫迄侭繭麿万慢満"],["cca1","漫蔓味未魅巳箕岬密蜜湊蓑稔脈妙粍民眠務夢無牟矛霧鵡椋婿娘冥名命明盟迷銘鳴姪牝滅免棉綿緬面麺摸模茂妄孟毛猛盲網耗蒙儲木黙目杢勿餅尤戻籾貰問悶紋門匁也冶夜爺耶野弥矢厄役約薬訳躍靖柳薮鑓愉愈油癒"],["cda1","諭輸唯佑優勇友宥幽悠憂揖有柚湧涌猶猷由祐裕誘遊邑郵雄融夕予余与誉輿預傭幼妖容庸揚揺擁曜楊様洋溶熔用窯羊耀葉蓉要謡踊遥陽養慾抑欲沃浴翌翼淀羅螺裸来莱頼雷洛絡落酪乱卵嵐欄濫藍蘭覧利吏履李梨理璃"],["cea1","痢裏裡里離陸律率立葎掠略劉流溜琉留硫粒隆竜龍侶慮旅虜了亮僚両凌寮料梁涼猟療瞭稜糧良諒遼量陵領力緑倫厘林淋燐琳臨輪隣鱗麟瑠塁涙累類令伶例冷励嶺怜玲礼苓鈴隷零霊麗齢暦歴列劣烈裂廉恋憐漣煉簾練聯"],["cfa1","蓮連錬呂魯櫓炉賂路露労婁廊弄朗楼榔浪漏牢狼篭老聾蝋郎六麓禄肋録論倭和話歪賄脇惑枠鷲亙亘鰐詫藁蕨椀湾碗腕"],["d0a1","弌丐丕个丱丶丼丿乂乖乘亂亅豫亊舒弍于亞亟亠亢亰亳亶从仍仄仆仂仗仞仭仟价伉佚估佛佝佗佇佶侈侏侘佻佩佰侑佯來侖儘俔俟俎俘俛俑俚俐俤俥倚倨倔倪倥倅伜俶倡倩倬俾俯們倆偃假會偕偐偈做偖偬偸傀傚傅傴傲"],["d1a1","僉僊傳僂僖僞僥僭僣僮價僵儉儁儂儖儕儔儚儡儺儷儼儻儿兀兒兌兔兢竸兩兪兮冀冂囘册冉冏冑冓冕冖冤冦冢冩冪冫决冱冲冰况冽凅凉凛几處凩凭凰凵凾刄刋刔刎刧刪刮刳刹剏剄剋剌剞剔剪剴剩剳剿剽劍劔劒剱劈劑辨"],["d2a1","辧劬劭劼劵勁勍勗勞勣勦飭勠勳勵勸勹匆匈甸匍匐匏匕匚匣匯匱匳匸區卆卅丗卉卍凖卞卩卮夘卻卷厂厖厠厦厥厮厰厶參簒雙叟曼燮叮叨叭叺吁吽呀听吭吼吮吶吩吝呎咏呵咎呟呱呷呰咒呻咀呶咄咐咆哇咢咸咥咬哄哈咨"],["d3a1","咫哂咤咾咼哘哥哦唏唔哽哮哭哺哢唹啀啣啌售啜啅啖啗唸唳啝喙喀咯喊喟啻啾喘喞單啼喃喩喇喨嗚嗅嗟嗄嗜嗤嗔嘔嗷嘖嗾嗽嘛嗹噎噐營嘴嘶嘲嘸噫噤嘯噬噪嚆嚀嚊嚠嚔嚏嚥嚮嚶嚴囂嚼囁囃囀囈囎囑囓囗囮囹圀囿圄圉"],["d4a1","圈國圍圓團圖嗇圜圦圷圸坎圻址坏坩埀垈坡坿垉垓垠垳垤垪垰埃埆埔埒埓堊埖埣堋堙堝塲堡塢塋塰毀塒堽塹墅墹墟墫墺壞墻墸墮壅壓壑壗壙壘壥壜壤壟壯壺壹壻壼壽夂夊夐夛梦夥夬夭夲夸夾竒奕奐奎奚奘奢奠奧奬奩"],["d5a1","奸妁妝佞侫妣妲姆姨姜妍姙姚娥娟娑娜娉娚婀婬婉娵娶婢婪媚媼媾嫋嫂媽嫣嫗嫦嫩嫖嫺嫻嬌嬋嬖嬲嫐嬪嬶嬾孃孅孀孑孕孚孛孥孩孰孳孵學斈孺宀它宦宸寃寇寉寔寐寤實寢寞寥寫寰寶寳尅將專對尓尠尢尨尸尹屁屆屎屓"],["d6a1","屐屏孱屬屮乢屶屹岌岑岔妛岫岻岶岼岷峅岾峇峙峩峽峺峭嶌峪崋崕崗嵜崟崛崑崔崢崚崙崘嵌嵒嵎嵋嵬嵳嵶嶇嶄嶂嶢嶝嶬嶮嶽嶐嶷嶼巉巍巓巒巖巛巫已巵帋帚帙帑帛帶帷幄幃幀幎幗幔幟幢幤幇幵并幺麼广庠廁廂廈廐廏"],["d7a1","廖廣廝廚廛廢廡廨廩廬廱廳廰廴廸廾弃弉彝彜弋弑弖弩弭弸彁彈彌彎弯彑彖彗彙彡彭彳彷徃徂彿徊很徑徇從徙徘徠徨徭徼忖忻忤忸忱忝悳忿怡恠怙怐怩怎怱怛怕怫怦怏怺恚恁恪恷恟恊恆恍恣恃恤恂恬恫恙悁悍惧悃悚"],["d8a1","悄悛悖悗悒悧悋惡悸惠惓悴忰悽惆悵惘慍愕愆惶惷愀惴惺愃愡惻惱愍愎慇愾愨愧慊愿愼愬愴愽慂慄慳慷慘慙慚慫慴慯慥慱慟慝慓慵憙憖憇憬憔憚憊憑憫憮懌懊應懷懈懃懆憺懋罹懍懦懣懶懺懴懿懽懼懾戀戈戉戍戌戔戛"],["d9a1","戞戡截戮戰戲戳扁扎扞扣扛扠扨扼抂抉找抒抓抖拔抃抔拗拑抻拏拿拆擔拈拜拌拊拂拇抛拉挌拮拱挧挂挈拯拵捐挾捍搜捏掖掎掀掫捶掣掏掉掟掵捫捩掾揩揀揆揣揉插揶揄搖搴搆搓搦搶攝搗搨搏摧摯摶摎攪撕撓撥撩撈撼"],["daa1","據擒擅擇撻擘擂擱擧舉擠擡抬擣擯攬擶擴擲擺攀擽攘攜攅攤攣攫攴攵攷收攸畋效敖敕敍敘敞敝敲數斂斃變斛斟斫斷旃旆旁旄旌旒旛旙无旡旱杲昊昃旻杳昵昶昴昜晏晄晉晁晞晝晤晧晨晟晢晰暃暈暎暉暄暘暝曁暹曉暾暼"],["dba1","曄暸曖曚曠昿曦曩曰曵曷朏朖朞朦朧霸朮朿朶杁朸朷杆杞杠杙杣杤枉杰枩杼杪枌枋枦枡枅枷柯枴柬枳柩枸柤柞柝柢柮枹柎柆柧檜栞框栩桀桍栲桎梳栫桙档桷桿梟梏梭梔條梛梃檮梹桴梵梠梺椏梍桾椁棊椈棘椢椦棡椌棍"],["dca1","棔棧棕椶椒椄棗棣椥棹棠棯椨椪椚椣椡棆楹楷楜楸楫楔楾楮椹楴椽楙椰楡楞楝榁楪榲榮槐榿槁槓榾槎寨槊槝榻槃榧樮榑榠榜榕榴槞槨樂樛槿權槹槲槧樅榱樞槭樔槫樊樒櫁樣樓橄樌橲樶橸橇橢橙橦橈樸樢檐檍檠檄檢檣"],["dda1","檗蘗檻櫃櫂檸檳檬櫞櫑櫟檪櫚櫪櫻欅蘖櫺欒欖鬱欟欸欷盜欹飮歇歃歉歐歙歔歛歟歡歸歹歿殀殄殃殍殘殕殞殤殪殫殯殲殱殳殷殼毆毋毓毟毬毫毳毯麾氈氓气氛氤氣汞汕汢汪沂沍沚沁沛汾汨汳沒沐泄泱泓沽泗泅泝沮沱沾"],["dea1","沺泛泯泙泪洟衍洶洫洽洸洙洵洳洒洌浣涓浤浚浹浙涎涕濤涅淹渕渊涵淇淦涸淆淬淞淌淨淒淅淺淙淤淕淪淮渭湮渮渙湲湟渾渣湫渫湶湍渟湃渺湎渤滿渝游溂溪溘滉溷滓溽溯滄溲滔滕溏溥滂溟潁漑灌滬滸滾漿滲漱滯漲滌"],["dfa1","漾漓滷澆潺潸澁澀潯潛濳潭澂潼潘澎澑濂潦澳澣澡澤澹濆澪濟濕濬濔濘濱濮濛瀉瀋濺瀑瀁瀏濾瀛瀚潴瀝瀘瀟瀰瀾瀲灑灣炙炒炯烱炬炸炳炮烟烋烝烙焉烽焜焙煥煕熈煦煢煌煖煬熏燻熄熕熨熬燗熹熾燒燉燔燎燠燬燧燵燼"],["e0a1","燹燿爍爐爛爨爭爬爰爲爻爼爿牀牆牋牘牴牾犂犁犇犒犖犢犧犹犲狃狆狄狎狒狢狠狡狹狷倏猗猊猜猖猝猴猯猩猥猾獎獏默獗獪獨獰獸獵獻獺珈玳珎玻珀珥珮珞璢琅瑯琥珸琲琺瑕琿瑟瑙瑁瑜瑩瑰瑣瑪瑶瑾璋璞璧瓊瓏瓔珱"],["e1a1","瓠瓣瓧瓩瓮瓲瓰瓱瓸瓷甄甃甅甌甎甍甕甓甞甦甬甼畄畍畊畉畛畆畚畩畤畧畫畭畸當疆疇畴疊疉疂疔疚疝疥疣痂疳痃疵疽疸疼疱痍痊痒痙痣痞痾痿痼瘁痰痺痲痳瘋瘍瘉瘟瘧瘠瘡瘢瘤瘴瘰瘻癇癈癆癜癘癡癢癨癩癪癧癬癰"],["e2a1","癲癶癸發皀皃皈皋皎皖皓皙皚皰皴皸皹皺盂盍盖盒盞盡盥盧盪蘯盻眈眇眄眩眤眞眥眦眛眷眸睇睚睨睫睛睥睿睾睹瞎瞋瞑瞠瞞瞰瞶瞹瞿瞼瞽瞻矇矍矗矚矜矣矮矼砌砒礦砠礪硅碎硴碆硼碚碌碣碵碪碯磑磆磋磔碾碼磅磊磬"],["e3a1","磧磚磽磴礇礒礑礙礬礫祀祠祗祟祚祕祓祺祿禊禝禧齋禪禮禳禹禺秉秕秧秬秡秣稈稍稘稙稠稟禀稱稻稾稷穃穗穉穡穢穩龝穰穹穽窈窗窕窘窖窩竈窰窶竅竄窿邃竇竊竍竏竕竓站竚竝竡竢竦竭竰笂笏笊笆笳笘笙笞笵笨笶筐"],["e4a1","筺笄筍笋筌筅筵筥筴筧筰筱筬筮箝箘箟箍箜箚箋箒箏筝箙篋篁篌篏箴篆篝篩簑簔篦篥籠簀簇簓篳篷簗簍篶簣簧簪簟簷簫簽籌籃籔籏籀籐籘籟籤籖籥籬籵粃粐粤粭粢粫粡粨粳粲粱粮粹粽糀糅糂糘糒糜糢鬻糯糲糴糶糺紆"],["e5a1","紂紜紕紊絅絋紮紲紿紵絆絳絖絎絲絨絮絏絣經綉絛綏絽綛綺綮綣綵緇綽綫總綢綯緜綸綟綰緘緝緤緞緻緲緡縅縊縣縡縒縱縟縉縋縢繆繦縻縵縹繃縷縲縺繧繝繖繞繙繚繹繪繩繼繻纃緕繽辮繿纈纉續纒纐纓纔纖纎纛纜缸缺"],["e6a1","罅罌罍罎罐网罕罔罘罟罠罨罩罧罸羂羆羃羈羇羌羔羞羝羚羣羯羲羹羮羶羸譱翅翆翊翕翔翡翦翩翳翹飜耆耄耋耒耘耙耜耡耨耿耻聊聆聒聘聚聟聢聨聳聲聰聶聹聽聿肄肆肅肛肓肚肭冐肬胛胥胙胝胄胚胖脉胯胱脛脩脣脯腋"],["e7a1","隋腆脾腓腑胼腱腮腥腦腴膃膈膊膀膂膠膕膤膣腟膓膩膰膵膾膸膽臀臂膺臉臍臑臙臘臈臚臟臠臧臺臻臾舁舂舅與舊舍舐舖舩舫舸舳艀艙艘艝艚艟艤艢艨艪艫舮艱艷艸艾芍芒芫芟芻芬苡苣苟苒苴苳苺莓范苻苹苞茆苜茉苙"],["e8a1","茵茴茖茲茱荀茹荐荅茯茫茗茘莅莚莪莟莢莖茣莎莇莊荼莵荳荵莠莉莨菴萓菫菎菽萃菘萋菁菷萇菠菲萍萢萠莽萸蔆菻葭萪萼蕚蒄葷葫蒭葮蒂葩葆萬葯葹萵蓊葢蒹蒿蒟蓙蓍蒻蓚蓐蓁蓆蓖蒡蔡蓿蓴蔗蔘蔬蔟蔕蔔蓼蕀蕣蕘蕈"],["e9a1","蕁蘂蕋蕕薀薤薈薑薊薨蕭薔薛藪薇薜蕷蕾薐藉薺藏薹藐藕藝藥藜藹蘊蘓蘋藾藺蘆蘢蘚蘰蘿虍乕虔號虧虱蚓蚣蚩蚪蚋蚌蚶蚯蛄蛆蚰蛉蠣蚫蛔蛞蛩蛬蛟蛛蛯蜒蜆蜈蜀蜃蛻蜑蜉蜍蛹蜊蜴蜿蜷蜻蜥蜩蜚蝠蝟蝸蝌蝎蝴蝗蝨蝮蝙"],["eaa1","蝓蝣蝪蠅螢螟螂螯蟋螽蟀蟐雖螫蟄螳蟇蟆螻蟯蟲蟠蠏蠍蟾蟶蟷蠎蟒蠑蠖蠕蠢蠡蠱蠶蠹蠧蠻衄衂衒衙衞衢衫袁衾袞衵衽袵衲袂袗袒袮袙袢袍袤袰袿袱裃裄裔裘裙裝裹褂裼裴裨裲褄褌褊褓襃褞褥褪褫襁襄褻褶褸襌褝襠襞"],["eba1","襦襤襭襪襯襴襷襾覃覈覊覓覘覡覩覦覬覯覲覺覽覿觀觚觜觝觧觴觸訃訖訐訌訛訝訥訶詁詛詒詆詈詼詭詬詢誅誂誄誨誡誑誥誦誚誣諄諍諂諚諫諳諧諤諱謔諠諢諷諞諛謌謇謚諡謖謐謗謠謳鞫謦謫謾謨譁譌譏譎證譖譛譚譫"],["eca1","譟譬譯譴譽讀讌讎讒讓讖讙讚谺豁谿豈豌豎豐豕豢豬豸豺貂貉貅貊貍貎貔豼貘戝貭貪貽貲貳貮貶賈賁賤賣賚賽賺賻贄贅贊贇贏贍贐齎贓賍贔贖赧赭赱赳趁趙跂趾趺跏跚跖跌跛跋跪跫跟跣跼踈踉跿踝踞踐踟蹂踵踰踴蹊"],["eda1","蹇蹉蹌蹐蹈蹙蹤蹠踪蹣蹕蹶蹲蹼躁躇躅躄躋躊躓躑躔躙躪躡躬躰軆躱躾軅軈軋軛軣軼軻軫軾輊輅輕輒輙輓輜輟輛輌輦輳輻輹轅轂輾轌轉轆轎轗轜轢轣轤辜辟辣辭辯辷迚迥迢迪迯邇迴逅迹迺逑逕逡逍逞逖逋逧逶逵逹迸"],["eea1","遏遐遑遒逎遉逾遖遘遞遨遯遶隨遲邂遽邁邀邊邉邏邨邯邱邵郢郤扈郛鄂鄒鄙鄲鄰酊酖酘酣酥酩酳酲醋醉醂醢醫醯醪醵醴醺釀釁釉釋釐釖釟釡釛釼釵釶鈞釿鈔鈬鈕鈑鉞鉗鉅鉉鉤鉈銕鈿鉋鉐銜銖銓銛鉚鋏銹銷鋩錏鋺鍄錮"],["efa1","錙錢錚錣錺錵錻鍜鍠鍼鍮鍖鎰鎬鎭鎔鎹鏖鏗鏨鏥鏘鏃鏝鏐鏈鏤鐚鐔鐓鐃鐇鐐鐶鐫鐵鐡鐺鑁鑒鑄鑛鑠鑢鑞鑪鈩鑰鑵鑷鑽鑚鑼鑾钁鑿閂閇閊閔閖閘閙閠閨閧閭閼閻閹閾闊濶闃闍闌闕闔闖關闡闥闢阡阨阮阯陂陌陏陋陷陜陞"],["f0a1","陝陟陦陲陬隍隘隕隗險隧隱隲隰隴隶隸隹雎雋雉雍襍雜霍雕雹霄霆霈霓霎霑霏霖霙霤霪霰霹霽霾靄靆靈靂靉靜靠靤靦靨勒靫靱靹鞅靼鞁靺鞆鞋鞏鞐鞜鞨鞦鞣鞳鞴韃韆韈韋韜韭齏韲竟韶韵頏頌頸頤頡頷頽顆顏顋顫顯顰"],["f1a1","顱顴顳颪颯颱颶飄飃飆飩飫餃餉餒餔餘餡餝餞餤餠餬餮餽餾饂饉饅饐饋饑饒饌饕馗馘馥馭馮馼駟駛駝駘駑駭駮駱駲駻駸騁騏騅駢騙騫騷驅驂驀驃騾驕驍驛驗驟驢驥驤驩驫驪骭骰骼髀髏髑髓體髞髟髢髣髦髯髫髮髴髱髷"],["f2a1","髻鬆鬘鬚鬟鬢鬣鬥鬧鬨鬩鬪鬮鬯鬲魄魃魏魍魎魑魘魴鮓鮃鮑鮖鮗鮟鮠鮨鮴鯀鯊鮹鯆鯏鯑鯒鯣鯢鯤鯔鯡鰺鯲鯱鯰鰕鰔鰉鰓鰌鰆鰈鰒鰊鰄鰮鰛鰥鰤鰡鰰鱇鰲鱆鰾鱚鱠鱧鱶鱸鳧鳬鳰鴉鴈鳫鴃鴆鴪鴦鶯鴣鴟鵄鴕鴒鵁鴿鴾鵆鵈"],["f3a1","鵝鵞鵤鵑鵐鵙鵲鶉鶇鶫鵯鵺鶚鶤鶩鶲鷄鷁鶻鶸鶺鷆鷏鷂鷙鷓鷸鷦鷭鷯鷽鸚鸛鸞鹵鹹鹽麁麈麋麌麒麕麑麝麥麩麸麪麭靡黌黎黏黐黔黜點黝黠黥黨黯黴黶黷黹黻黼黽鼇鼈皷鼕鼡鼬鼾齊齒齔齣齟齠齡齦齧齬齪齷齲齶龕龜龠"],["f4a1","堯槇遙瑤凜熙"],["f9a1","纊褜鍈銈蓜俉炻昱棈鋹曻彅丨仡仼伀伃伹佖侒侊侚侔俍偀倢俿倞偆偰偂傔僴僘兊兤冝冾凬刕劜劦勀勛匀匇匤卲厓厲叝﨎咜咊咩哿喆坙坥垬埈埇﨏塚增墲夋奓奛奝奣妤妺孖寀甯寘寬尞岦岺峵崧嵓﨑嵂嵭嶸嶹巐弡弴彧德"],["faa1","忞恝悅悊惞惕愠惲愑愷愰憘戓抦揵摠撝擎敎昀昕昻昉昮昞昤晥晗晙晴晳暙暠暲暿曺朎朗杦枻桒柀栁桄棏﨓楨﨔榘槢樰橫橆橳橾櫢櫤毖氿汜沆汯泚洄涇浯涖涬淏淸淲淼渹湜渧渼溿澈澵濵瀅瀇瀨炅炫焏焄煜煆煇凞燁燾犱"],["fba1","犾猤猪獷玽珉珖珣珒琇珵琦琪琩琮瑢璉璟甁畯皂皜皞皛皦益睆劯砡硎硤硺礰礼神祥禔福禛竑竧靖竫箞精絈絜綷綠緖繒罇羡羽茁荢荿菇菶葈蒴蕓蕙蕫﨟薰蘒﨡蠇裵訒訷詹誧誾諟諸諶譓譿賰賴贒赶﨣軏﨤逸遧郞都鄕鄧釚"],["fca1","釗釞釭釮釤釥鈆鈐鈊鈺鉀鈼鉎鉙鉑鈹鉧銧鉷鉸鋧鋗鋙鋐﨧鋕鋠鋓錥錡鋻﨨錞鋿錝錂鍰鍗鎤鏆鏞鏸鐱鑅鑈閒隆﨩隝隯霳霻靃靍靏靑靕顗顥飯飼餧館馞驎髙髜魵魲鮏鮱鮻鰀鵰鵫鶴鸙黑"],["fcf1","ⅰ",9,"¬¦'""],["8fa2af","˘ˇ¸˙˝¯˛˚~΄΅"],["8fa2c2","¡¦¿"],["8fa2eb","ºª©®™¤№"],["8fa6e1","ΆΈΉΊΪ"],["8fa6e7","Ό"],["8fa6e9","ΎΫ"],["8fa6ec","Ώ"],["8fa6f1","άέήίϊΐόςύϋΰώ"],["8fa7c2","Ђ",10,"ЎЏ"],["8fa7f2","ђ",10,"ўџ"],["8fa9a1","ÆĐ"],["8fa9a4","Ħ"],["8fa9a6","IJ"],["8fa9a8","ŁĿ"],["8fa9ab","ŊØŒ"],["8fa9af","ŦÞ"],["8fa9c1","æđðħıijĸłŀʼnŋøœßŧþ"],["8faaa1","ÁÀÄÂĂǍĀĄÅÃĆĈČÇĊĎÉÈËÊĚĖĒĘ"],["8faaba","ĜĞĢĠĤÍÌÏÎǏİĪĮĨĴĶĹĽĻŃŇŅÑÓÒÖÔǑŐŌÕŔŘŖŚŜŠŞŤŢÚÙÜÛŬǓŰŪŲŮŨǗǛǙǕŴÝŸŶŹŽŻ"],["8faba1","áàäâăǎāąåãćĉčçċďéèëêěėēęǵĝğ"],["8fabbd","ġĥíìïîǐ"],["8fabc5","īįĩĵķĺľļńňņñóòöôǒőōõŕřŗśŝšşťţúùüûŭǔűūųůũǘǜǚǖŵýÿŷźžż"],["8fb0a1","丂丄丅丌丒丟丣两丨丫丮丯丰丵乀乁乄乇乑乚乜乣乨乩乴乵乹乿亍亖亗亝亯亹仃仐仚仛仠仡仢仨仯仱仳仵份仾仿伀伂伃伈伋伌伒伕伖众伙伮伱你伳伵伷伹伻伾佀佂佈佉佋佌佒佔佖佘佟佣佪佬佮佱佷佸佹佺佽佾侁侂侄"],["8fb1a1","侅侉侊侌侎侐侒侓侔侗侙侚侞侟侲侷侹侻侼侽侾俀俁俅俆俈俉俋俌俍俏俒俜俠俢俰俲俼俽俿倀倁倄倇倊倌倎倐倓倗倘倛倜倝倞倢倧倮倰倲倳倵偀偁偂偅偆偊偌偎偑偒偓偗偙偟偠偢偣偦偧偪偭偰偱倻傁傃傄傆傊傎傏傐"],["8fb2a1","傒傓傔傖傛傜傞",4,"傪傯傰傹傺傽僀僃僄僇僌僎僐僓僔僘僜僝僟僢僤僦僨僩僯僱僶僺僾儃儆儇儈儋儌儍儎僲儐儗儙儛儜儝儞儣儧儨儬儭儯儱儳儴儵儸儹兂兊兏兓兕兗兘兟兤兦兾冃冄冋冎冘冝冡冣冭冸冺冼冾冿凂"],["8fb3a1","凈减凑凒凓凕凘凞凢凥凮凲凳凴凷刁刂刅划刓刕刖刘刢刨刱刲刵刼剅剉剕剗剘剚剜剟剠剡剦剮剷剸剹劀劂劅劊劌劓劕劖劗劘劚劜劤劥劦劧劯劰劶劷劸劺劻劽勀勄勆勈勌勏勑勔勖勛勜勡勥勨勩勪勬勰勱勴勶勷匀匃匊匋"],["8fb4a1","匌匑匓匘匛匜匞匟匥匧匨匩匫匬匭匰匲匵匼匽匾卂卌卋卙卛卡卣卥卬卭卲卹卾厃厇厈厎厓厔厙厝厡厤厪厫厯厲厴厵厷厸厺厽叀叅叏叒叓叕叚叝叞叠另叧叵吂吓吚吡吧吨吪启吱吴吵呃呄呇呍呏呞呢呤呦呧呩呫呭呮呴呿"],["8fb5a1","咁咃咅咈咉咍咑咕咖咜咟咡咦咧咩咪咭咮咱咷咹咺咻咿哆哊响哎哠哪哬哯哶哼哾哿唀唁唅唈唉唌唍唎唕唪唫唲唵唶唻唼唽啁啇啉啊啍啐啑啘啚啛啞啠啡啤啦啿喁喂喆喈喎喏喑喒喓喔喗喣喤喭喲喿嗁嗃嗆嗉嗋嗌嗎嗑嗒"],["8fb6a1","嗓嗗嗘嗛嗞嗢嗩嗶嗿嘅嘈嘊嘍",5,"嘙嘬嘰嘳嘵嘷嘹嘻嘼嘽嘿噀噁噃噄噆噉噋噍噏噔噞噠噡噢噣噦噩噭噯噱噲噵嚄嚅嚈嚋嚌嚕嚙嚚嚝嚞嚟嚦嚧嚨嚩嚫嚬嚭嚱嚳嚷嚾囅囉囊囋囏囐囌囍囙囜囝囟囡囤",4,"囱囫园"],["8fb7a1","囶囷圁圂圇圊圌圑圕圚圛圝圠圢圣圤圥圩圪圬圮圯圳圴圽圾圿坅坆坌坍坒坢坥坧坨坫坭",4,"坳坴坵坷坹坺坻坼坾垁垃垌垔垗垙垚垜垝垞垟垡垕垧垨垩垬垸垽埇埈埌埏埕埝埞埤埦埧埩埭埰埵埶埸埽埾埿堃堄堈堉埡"],["8fb8a1","堌堍堛堞堟堠堦堧堭堲堹堿塉塌塍塏塐塕塟塡塤塧塨塸塼塿墀墁墇墈墉墊墌墍墏墐墔墖墝墠墡墢墦墩墱墲壄墼壂壈壍壎壐壒壔壖壚壝壡壢壩壳夅夆夋夌夒夓夔虁夝夡夣夤夨夯夰夳夵夶夿奃奆奒奓奙奛奝奞奟奡奣奫奭"],["8fb9a1","奯奲奵奶她奻奼妋妌妎妒妕妗妟妤妧妭妮妯妰妳妷妺妼姁姃姄姈姊姍姒姝姞姟姣姤姧姮姯姱姲姴姷娀娄娌娍娎娒娓娞娣娤娧娨娪娭娰婄婅婇婈婌婐婕婞婣婥婧婭婷婺婻婾媋媐媓媖媙媜媞媟媠媢媧媬媱媲媳媵媸媺媻媿"],["8fbaa1","嫄嫆嫈嫏嫚嫜嫠嫥嫪嫮嫵嫶嫽嬀嬁嬈嬗嬴嬙嬛嬝嬡嬥嬭嬸孁孋孌孒孖孞孨孮孯孼孽孾孿宁宄宆宊宎宐宑宓宔宖宨宩宬宭宯宱宲宷宺宼寀寁寍寏寖",4,"寠寯寱寴寽尌尗尞尟尣尦尩尫尬尮尰尲尵尶屙屚屜屢屣屧屨屩"],["8fbba1","屭屰屴屵屺屻屼屽岇岈岊岏岒岝岟岠岢岣岦岪岲岴岵岺峉峋峒峝峗峮峱峲峴崁崆崍崒崫崣崤崦崧崱崴崹崽崿嵂嵃嵆嵈嵕嵑嵙嵊嵟嵠嵡嵢嵤嵪嵭嵰嵹嵺嵾嵿嶁嶃嶈嶊嶒嶓嶔嶕嶙嶛嶟嶠嶧嶫嶰嶴嶸嶹巃巇巋巐巎巘巙巠巤"],["8fbca1","巩巸巹帀帇帍帒帔帕帘帟帠帮帨帲帵帾幋幐幉幑幖幘幛幜幞幨幪",4,"幰庀庋庎庢庤庥庨庪庬庱庳庽庾庿廆廌廋廎廑廒廔廕廜廞廥廫异弆弇弈弎弙弜弝弡弢弣弤弨弫弬弮弰弴弶弻弽弿彀彄彅彇彍彐彔彘彛彠彣彤彧"],["8fbda1","彯彲彴彵彸彺彽彾徉徍徏徖徜徝徢徧徫徤徬徯徰徱徸忄忇忈忉忋忐",4,"忞忡忢忨忩忪忬忭忮忯忲忳忶忺忼怇怊怍怓怔怗怘怚怟怤怭怳怵恀恇恈恉恌恑恔恖恗恝恡恧恱恾恿悂悆悈悊悎悑悓悕悘悝悞悢悤悥您悰悱悷"],["8fbea1","悻悾惂惄惈惉惊惋惎惏惔惕惙惛惝惞惢惥惲惵惸惼惽愂愇愊愌愐",4,"愖愗愙愜愞愢愪愫愰愱愵愶愷愹慁慅慆慉慞慠慬慲慸慻慼慿憀憁憃憄憋憍憒憓憗憘憜憝憟憠憥憨憪憭憸憹憼懀懁懂懎懏懕懜懝懞懟懡懢懧懩懥"],["8fbfa1","懬懭懯戁戃戄戇戓戕戜戠戢戣戧戩戫戹戽扂扃扄扆扌扐扑扒扔扖扚扜扤扭扯扳扺扽抍抎抏抐抦抨抳抶抷抺抾抿拄拎拕拖拚拪拲拴拼拽挃挄挊挋挍挐挓挖挘挩挪挭挵挶挹挼捁捂捃捄捆捊捋捎捒捓捔捘捛捥捦捬捭捱捴捵"],["8fc0a1","捸捼捽捿掂掄掇掊掐掔掕掙掚掞掤掦掭掮掯掽揁揅揈揎揑揓揔揕揜揠揥揪揬揲揳揵揸揹搉搊搐搒搔搘搞搠搢搤搥搩搪搯搰搵搽搿摋摏摑摒摓摔摚摛摜摝摟摠摡摣摭摳摴摻摽撅撇撏撐撑撘撙撛撝撟撡撣撦撨撬撳撽撾撿"],["8fc1a1","擄擉擊擋擌擎擐擑擕擗擤擥擩擪擭擰擵擷擻擿攁攄攈攉攊攏攓攔攖攙攛攞攟攢攦攩攮攱攺攼攽敃敇敉敐敒敔敟敠敧敫敺敽斁斅斊斒斕斘斝斠斣斦斮斲斳斴斿旂旈旉旎旐旔旖旘旟旰旲旴旵旹旾旿昀昄昈昉昍昑昒昕昖昝"],["8fc2a1","昞昡昢昣昤昦昩昪昫昬昮昰昱昳昹昷晀晅晆晊晌晑晎晗晘晙晛晜晠晡曻晪晫晬晾晳晵晿晷晸晹晻暀晼暋暌暍暐暒暙暚暛暜暟暠暤暭暱暲暵暻暿曀曂曃曈曌曎曏曔曛曟曨曫曬曮曺朅朇朎朓朙朜朠朢朳朾杅杇杈杌杔杕杝"],["8fc3a1","杦杬杮杴杶杻极构枎枏枑枓枖枘枙枛枰枱枲枵枻枼枽柹柀柂柃柅柈柉柒柗柙柜柡柦柰柲柶柷桒栔栙栝栟栨栧栬栭栯栰栱栳栻栿桄桅桊桌桕桗桘桛桫桮",4,"桵桹桺桻桼梂梄梆梈梖梘梚梜梡梣梥梩梪梮梲梻棅棈棌棏"],["8fc4a1","棐棑棓棖棙棜棝棥棨棪棫棬棭棰棱棵棶棻棼棽椆椉椊椐椑椓椖椗椱椳椵椸椻楂楅楉楎楗楛楣楤楥楦楨楩楬楰楱楲楺楻楿榀榍榒榖榘榡榥榦榨榫榭榯榷榸榺榼槅槈槑槖槗槢槥槮槯槱槳槵槾樀樁樃樏樑樕樚樝樠樤樨樰樲"],["8fc5a1","樴樷樻樾樿橅橆橉橊橎橐橑橒橕橖橛橤橧橪橱橳橾檁檃檆檇檉檋檑檛檝檞檟檥檫檯檰檱檴檽檾檿櫆櫉櫈櫌櫐櫔櫕櫖櫜櫝櫤櫧櫬櫰櫱櫲櫼櫽欂欃欆欇欉欏欐欑欗欛欞欤欨欫欬欯欵欶欻欿歆歊歍歒歖歘歝歠歧歫歮歰歵歽"],["8fc6a1","歾殂殅殗殛殟殠殢殣殨殩殬殭殮殰殸殹殽殾毃毄毉毌毖毚毡毣毦毧毮毱毷毹毿氂氄氅氉氍氎氐氒氙氟氦氧氨氬氮氳氵氶氺氻氿汊汋汍汏汒汔汙汛汜汫汭汯汴汶汸汹汻沅沆沇沉沔沕沗沘沜沟沰沲沴泂泆泍泏泐泑泒泔泖"],["8fc7a1","泚泜泠泧泩泫泬泮泲泴洄洇洊洎洏洑洓洚洦洧洨汧洮洯洱洹洼洿浗浞浟浡浥浧浯浰浼涂涇涑涒涔涖涗涘涪涬涴涷涹涽涿淄淈淊淎淏淖淛淝淟淠淢淥淩淯淰淴淶淼渀渄渞渢渧渲渶渹渻渼湄湅湈湉湋湏湑湒湓湔湗湜湝湞"],["8fc8a1","湢湣湨湳湻湽溍溓溙溠溧溭溮溱溳溻溿滀滁滃滇滈滊滍滎滏滫滭滮滹滻滽漄漈漊漌漍漖漘漚漛漦漩漪漯漰漳漶漻漼漭潏潑潒潓潗潙潚潝潞潡潢潨潬潽潾澃澇澈澋澌澍澐澒澓澔澖澚澟澠澥澦澧澨澮澯澰澵澶澼濅濇濈濊"],["8fc9a1","濚濞濨濩濰濵濹濼濽瀀瀅瀆瀇瀍瀗瀠瀣瀯瀴瀷瀹瀼灃灄灈灉灊灋灔灕灝灞灎灤灥灬灮灵灶灾炁炅炆炔",4,"炛炤炫炰炱炴炷烊烑烓烔烕烖烘烜烤烺焃",4,"焋焌焏焞焠焫焭焯焰焱焸煁煅煆煇煊煋煐煒煗煚煜煞煠"],["8fcaa1","煨煹熀熅熇熌熒熚熛熠熢熯熰熲熳熺熿燀燁燄燋燌燓燖燙燚燜燸燾爀爇爈爉爓爗爚爝爟爤爫爯爴爸爹牁牂牃牅牎牏牐牓牕牖牚牜牞牠牣牨牫牮牯牱牷牸牻牼牿犄犉犍犎犓犛犨犭犮犱犴犾狁狇狉狌狕狖狘狟狥狳狴狺狻"],["8fcba1","狾猂猄猅猇猋猍猒猓猘猙猞猢猤猧猨猬猱猲猵猺猻猽獃獍獐獒獖獘獝獞獟獠獦獧獩獫獬獮獯獱獷獹獼玀玁玃玅玆玎玐玓玕玗玘玜玞玟玠玢玥玦玪玫玭玵玷玹玼玽玿珅珆珉珋珌珏珒珓珖珙珝珡珣珦珧珩珴珵珷珹珺珻珽"],["8fcca1","珿琀琁琄琇琊琑琚琛琤琦琨",9,"琹瑀瑃瑄瑆瑇瑋瑍瑑瑒瑗瑝瑢瑦瑧瑨瑫瑭瑮瑱瑲璀璁璅璆璇璉璏璐璑璒璘璙璚璜璟璠璡璣璦璨璩璪璫璮璯璱璲璵璹璻璿瓈瓉瓌瓐瓓瓘瓚瓛瓞瓟瓤瓨瓪瓫瓯瓴瓺瓻瓼瓿甆"],["8fcda1","甒甖甗甠甡甤甧甩甪甯甶甹甽甾甿畀畃畇畈畎畐畒畗畞畟畡畯畱畹",5,"疁疅疐疒疓疕疙疜疢疤疴疺疿痀痁痄痆痌痎痏痗痜痟痠痡痤痧痬痮痯痱痹瘀瘂瘃瘄瘇瘈瘊瘌瘏瘒瘓瘕瘖瘙瘛瘜瘝瘞瘣瘥瘦瘩瘭瘲瘳瘵瘸瘹"],["8fcea1","瘺瘼癊癀癁癃癄癅癉癋癕癙癟癤癥癭癮癯癱癴皁皅皌皍皕皛皜皝皟皠皢",6,"皪皭皽盁盅盉盋盌盎盔盙盠盦盨盬盰盱盶盹盼眀眆眊眎眒眔眕眗眙眚眜眢眨眭眮眯眴眵眶眹眽眾睂睅睆睊睍睎睏睒睖睗睜睞睟睠睢"],["8fcfa1","睤睧睪睬睰睲睳睴睺睽瞀瞄瞌瞍瞔瞕瞖瞚瞟瞢瞧瞪瞮瞯瞱瞵瞾矃矉矑矒矕矙矞矟矠矤矦矪矬矰矱矴矸矻砅砆砉砍砎砑砝砡砢砣砭砮砰砵砷硃硄硇硈硌硎硒硜硞硠硡硣硤硨硪确硺硾碊碏碔碘碡碝碞碟碤碨碬碭碰碱碲碳"],["8fd0a1","碻碽碿磇磈磉磌磎磒磓磕磖磤磛磟磠磡磦磪磲磳礀磶磷磺磻磿礆礌礐礚礜礞礟礠礥礧礩礭礱礴礵礻礽礿祄祅祆祊祋祏祑祔祘祛祜祧祩祫祲祹祻祼祾禋禌禑禓禔禕禖禘禛禜禡禨禩禫禯禱禴禸离秂秄秇秈秊秏秔秖秚秝秞"],["8fd1a1","秠秢秥秪秫秭秱秸秼稂稃稇稉稊稌稑稕稛稞稡稧稫稭稯稰稴稵稸稹稺穄穅穇穈穌穕穖穙穜穝穟穠穥穧穪穭穵穸穾窀窂窅窆窊窋窐窑窔窞窠窣窬窳窵窹窻窼竆竉竌竎竑竛竨竩竫竬竱竴竻竽竾笇笔笟笣笧笩笪笫笭笮笯笰"],["8fd2a1","笱笴笽笿筀筁筇筎筕筠筤筦筩筪筭筯筲筳筷箄箉箎箐箑箖箛箞箠箥箬箯箰箲箵箶箺箻箼箽篂篅篈篊篔篖篗篙篚篛篨篪篲篴篵篸篹篺篼篾簁簂簃簄簆簉簋簌簎簏簙簛簠簥簦簨簬簱簳簴簶簹簺籆籊籕籑籒籓籙",5],["8fd3a1","籡籣籧籩籭籮籰籲籹籼籽粆粇粏粔粞粠粦粰粶粷粺粻粼粿糄糇糈糉糍糏糓糔糕糗糙糚糝糦糩糫糵紃紇紈紉紏紑紒紓紖紝紞紣紦紪紭紱紼紽紾絀絁絇絈絍絑絓絗絙絚絜絝絥絧絪絰絸絺絻絿綁綂綃綅綆綈綋綌綍綑綖綗綝"],["8fd4a1","綞綦綧綪綳綶綷綹緂",4,"緌緍緎緗緙縀緢緥緦緪緫緭緱緵緶緹緺縈縐縑縕縗縜縝縠縧縨縬縭縯縳縶縿繄繅繇繎繐繒繘繟繡繢繥繫繮繯繳繸繾纁纆纇纊纍纑纕纘纚纝纞缼缻缽缾缿罃罄罇罏罒罓罛罜罝罡罣罤罥罦罭"],["8fd5a1","罱罽罾罿羀羋羍羏羐羑羖羗羜羡羢羦羪羭羴羼羿翀翃翈翎翏翛翟翣翥翨翬翮翯翲翺翽翾翿耇耈耊耍耎耏耑耓耔耖耝耞耟耠耤耦耬耮耰耴耵耷耹耺耼耾聀聄聠聤聦聭聱聵肁肈肎肜肞肦肧肫肸肹胈胍胏胒胔胕胗胘胠胭胮"],["8fd6a1","胰胲胳胶胹胺胾脃脋脖脗脘脜脞脠脤脧脬脰脵脺脼腅腇腊腌腒腗腠腡腧腨腩腭腯腷膁膐膄膅膆膋膎膖膘膛膞膢膮膲膴膻臋臃臅臊臎臏臕臗臛臝臞臡臤臫臬臰臱臲臵臶臸臹臽臿舀舃舏舓舔舙舚舝舡舢舨舲舴舺艃艄艅艆"],["8fd7a1","艋艎艏艑艖艜艠艣艧艭艴艻艽艿芀芁芃芄芇芉芊芎芑芔芖芘芚芛芠芡芣芤芧芨芩芪芮芰芲芴芷芺芼芾芿苆苐苕苚苠苢苤苨苪苭苯苶苷苽苾茀茁茇茈茊茋荔茛茝茞茟茡茢茬茭茮茰茳茷茺茼茽荂荃荄荇荍荎荑荕荖荗荰荸"],["8fd8a1","荽荿莀莂莄莆莍莒莔莕莘莙莛莜莝莦莧莩莬莾莿菀菇菉菏菐菑菔菝荓菨菪菶菸菹菼萁萆萊萏萑萕萙莭萯萹葅葇葈葊葍葏葑葒葖葘葙葚葜葠葤葥葧葪葰葳葴葶葸葼葽蒁蒅蒒蒓蒕蒞蒦蒨蒩蒪蒯蒱蒴蒺蒽蒾蓀蓂蓇蓈蓌蓏蓓"],["8fd9a1","蓜蓧蓪蓯蓰蓱蓲蓷蔲蓺蓻蓽蔂蔃蔇蔌蔎蔐蔜蔞蔢蔣蔤蔥蔧蔪蔫蔯蔳蔴蔶蔿蕆蕏",4,"蕖蕙蕜",6,"蕤蕫蕯蕹蕺蕻蕽蕿薁薅薆薉薋薌薏薓薘薝薟薠薢薥薧薴薶薷薸薼薽薾薿藂藇藊藋藎薭藘藚藟藠藦藨藭藳藶藼"],["8fdaa1","藿蘀蘄蘅蘍蘎蘐蘑蘒蘘蘙蘛蘞蘡蘧蘩蘶蘸蘺蘼蘽虀虂虆虒虓虖虗虘虙虝虠",4,"虩虬虯虵虶虷虺蚍蚑蚖蚘蚚蚜蚡蚦蚧蚨蚭蚱蚳蚴蚵蚷蚸蚹蚿蛀蛁蛃蛅蛑蛒蛕蛗蛚蛜蛠蛣蛥蛧蚈蛺蛼蛽蜄蜅蜇蜋蜎蜏蜐蜓蜔蜙蜞蜟蜡蜣"],["8fdba1","蜨蜮蜯蜱蜲蜹蜺蜼蜽蜾蝀蝃蝅蝍蝘蝝蝡蝤蝥蝯蝱蝲蝻螃",6,"螋螌螐螓螕螗螘螙螞螠螣螧螬螭螮螱螵螾螿蟁蟈蟉蟊蟎蟕蟖蟙蟚蟜蟟蟢蟣蟤蟪蟫蟭蟱蟳蟸蟺蟿蠁蠃蠆蠉蠊蠋蠐蠙蠒蠓蠔蠘蠚蠛蠜蠞蠟蠨蠭蠮蠰蠲蠵"],["8fdca1","蠺蠼衁衃衅衈衉衊衋衎衑衕衖衘衚衜衟衠衤衩衱衹衻袀袘袚袛袜袟袠袨袪袺袽袾裀裊",4,"裑裒裓裛裞裧裯裰裱裵裷褁褆褍褎褏褕褖褘褙褚褜褠褦褧褨褰褱褲褵褹褺褾襀襂襅襆襉襏襒襗襚襛襜襡襢襣襫襮襰襳襵襺"],["8fdda1","襻襼襽覉覍覐覔覕覛覜覟覠覥覰覴覵覶覷覼觔",4,"觥觩觫觭觱觳觶觹觽觿訄訅訇訏訑訒訔訕訞訠訢訤訦訫訬訯訵訷訽訾詀詃詅詇詉詍詎詓詖詗詘詜詝詡詥詧詵詶詷詹詺詻詾詿誀誃誆誋誏誐誒誖誗誙誟誧誩誮誯誳"],["8fdea1","誶誷誻誾諃諆諈諉諊諑諓諔諕諗諝諟諬諰諴諵諶諼諿謅謆謋謑謜謞謟謊謭謰謷謼譂",4,"譈譒譓譔譙譍譞譣譭譶譸譹譼譾讁讄讅讋讍讏讔讕讜讞讟谸谹谽谾豅豇豉豋豏豑豓豔豗豘豛豝豙豣豤豦豨豩豭豳豵豶豻豾貆"],["8fdfa1","貇貋貐貒貓貙貛貜貤貹貺賅賆賉賋賏賖賕賙賝賡賨賬賯賰賲賵賷賸賾賿贁贃贉贒贗贛赥赩赬赮赿趂趄趈趍趐趑趕趞趟趠趦趫趬趯趲趵趷趹趻跀跅跆跇跈跊跎跑跔跕跗跙跤跥跧跬跰趼跱跲跴跽踁踄踅踆踋踑踔踖踠踡踢"],["8fe0a1","踣踦踧踱踳踶踷踸踹踽蹀蹁蹋蹍蹎蹏蹔蹛蹜蹝蹞蹡蹢蹩蹬蹭蹯蹰蹱蹹蹺蹻躂躃躉躐躒躕躚躛躝躞躢躧躩躭躮躳躵躺躻軀軁軃軄軇軏軑軔軜軨軮軰軱軷軹軺軭輀輂輇輈輏輐輖輗輘輞輠輡輣輥輧輨輬輭輮輴輵輶輷輺轀轁"],["8fe1a1","轃轇轏轑",4,"轘轝轞轥辝辠辡辤辥辦辵辶辸达迀迁迆迊迋迍运迒迓迕迠迣迤迨迮迱迵迶迻迾适逄逈逌逘逛逨逩逯逪逬逭逳逴逷逿遃遄遌遛遝遢遦遧遬遰遴遹邅邈邋邌邎邐邕邗邘邙邛邠邡邢邥邰邲邳邴邶邽郌邾郃"],["8fe2a1","郄郅郇郈郕郗郘郙郜郝郟郥郒郶郫郯郰郴郾郿鄀鄄鄅鄆鄈鄍鄐鄔鄖鄗鄘鄚鄜鄞鄠鄥鄢鄣鄧鄩鄮鄯鄱鄴鄶鄷鄹鄺鄼鄽酃酇酈酏酓酗酙酚酛酡酤酧酭酴酹酺酻醁醃醅醆醊醎醑醓醔醕醘醞醡醦醨醬醭醮醰醱醲醳醶醻醼醽醿"],["8fe3a1","釂釃釅釓釔釗釙釚釞釤釥釩釪釬",5,"釷釹釻釽鈀鈁鈄鈅鈆鈇鈉鈊鈌鈐鈒鈓鈖鈘鈜鈝鈣鈤鈥鈦鈨鈮鈯鈰鈳鈵鈶鈸鈹鈺鈼鈾鉀鉂鉃鉆鉇鉊鉍鉎鉏鉑鉘鉙鉜鉝鉠鉡鉥鉧鉨鉩鉮鉯鉰鉵",4,"鉻鉼鉽鉿銈銉銊銍銎銒銗"],["8fe4a1","銙銟銠銤銥銧銨銫銯銲銶銸銺銻銼銽銿",4,"鋅鋆鋇鋈鋋鋌鋍鋎鋐鋓鋕鋗鋘鋙鋜鋝鋟鋠鋡鋣鋥鋧鋨鋬鋮鋰鋹鋻鋿錀錂錈錍錑錔錕錜錝錞錟錡錤錥錧錩錪錳錴錶錷鍇鍈鍉鍐鍑鍒鍕鍗鍘鍚鍞鍤鍥鍧鍩鍪鍭鍯鍰鍱鍳鍴鍶"],["8fe5a1","鍺鍽鍿鎀鎁鎂鎈鎊鎋鎍鎏鎒鎕鎘鎛鎞鎡鎣鎤鎦鎨鎫鎴鎵鎶鎺鎩鏁鏄鏅鏆鏇鏉",4,"鏓鏙鏜鏞鏟鏢鏦鏧鏹鏷鏸鏺鏻鏽鐁鐂鐄鐈鐉鐍鐎鐏鐕鐖鐗鐟鐮鐯鐱鐲鐳鐴鐻鐿鐽鑃鑅鑈鑊鑌鑕鑙鑜鑟鑡鑣鑨鑫鑭鑮鑯鑱鑲钄钃镸镹"],["8fe6a1","镾閄閈閌閍閎閝閞閟閡閦閩閫閬閴閶閺閽閿闆闈闉闋闐闑闒闓闙闚闝闞闟闠闤闦阝阞阢阤阥阦阬阱阳阷阸阹阺阼阽陁陒陔陖陗陘陡陮陴陻陼陾陿隁隂隃隄隉隑隖隚隝隟隤隥隦隩隮隯隳隺雊雒嶲雘雚雝雞雟雩雯雱雺霂"],["8fe7a1","霃霅霉霚霛霝霡霢霣霨霱霳靁靃靊靎靏靕靗靘靚靛靣靧靪靮靳靶靷靸靻靽靿鞀鞉鞕鞖鞗鞙鞚鞞鞟鞢鞬鞮鞱鞲鞵鞶鞸鞹鞺鞼鞾鞿韁韄韅韇韉韊韌韍韎韐韑韔韗韘韙韝韞韠韛韡韤韯韱韴韷韸韺頇頊頙頍頎頔頖頜頞頠頣頦"],["8fe8a1","頫頮頯頰頲頳頵頥頾顄顇顊顑顒顓顖顗顙顚顢顣顥顦顪顬颫颭颮颰颴颷颸颺颻颿飂飅飈飌飡飣飥飦飧飪飳飶餂餇餈餑餕餖餗餚餛餜餟餢餦餧餫餱",4,"餹餺餻餼饀饁饆饇饈饍饎饔饘饙饛饜饞饟饠馛馝馟馦馰馱馲馵"],["8fe9a1","馹馺馽馿駃駉駓駔駙駚駜駞駧駪駫駬駰駴駵駹駽駾騂騃騄騋騌騐騑騖騞騠騢騣騤騧騭騮騳騵騶騸驇驁驄驊驋驌驎驑驔驖驝骪骬骮骯骲骴骵骶骹骻骾骿髁髃髆髈髎髐髒髕髖髗髛髜髠髤髥髧髩髬髲髳髵髹髺髽髿",4],["8feaa1","鬄鬅鬈鬉鬋鬌鬍鬎鬐鬒鬖鬙鬛鬜鬠鬦鬫鬭鬳鬴鬵鬷鬹鬺鬽魈魋魌魕魖魗魛魞魡魣魥魦魨魪",4,"魳魵魷魸魹魿鮀鮄鮅鮆鮇鮉鮊鮋鮍鮏鮐鮔鮚鮝鮞鮦鮧鮩鮬鮰鮱鮲鮷鮸鮻鮼鮾鮿鯁鯇鯈鯎鯐鯗鯘鯝鯟鯥鯧鯪鯫鯯鯳鯷鯸"],["8feba1","鯹鯺鯽鯿鰀鰂鰋鰏鰑鰖鰘鰙鰚鰜鰞鰢鰣鰦",4,"鰱鰵鰶鰷鰽鱁鱃鱄鱅鱉鱊鱎鱏鱐鱓鱔鱖鱘鱛鱝鱞鱟鱣鱩鱪鱜鱫鱨鱮鱰鱲鱵鱷鱻鳦鳲鳷鳹鴋鴂鴑鴗鴘鴜鴝鴞鴯鴰鴲鴳鴴鴺鴼鵅鴽鵂鵃鵇鵊鵓鵔鵟鵣鵢鵥鵩鵪鵫鵰鵶鵷鵻"],["8feca1","鵼鵾鶃鶄鶆鶊鶍鶎鶒鶓鶕鶖鶗鶘鶡鶪鶬鶮鶱鶵鶹鶼鶿鷃鷇鷉鷊鷔鷕鷖鷗鷚鷞鷟鷠鷥鷧鷩鷫鷮鷰鷳鷴鷾鸊鸂鸇鸎鸐鸑鸒鸕鸖鸙鸜鸝鹺鹻鹼麀麂麃麄麅麇麎麏麖麘麛麞麤麨麬麮麯麰麳麴麵黆黈黋黕黟黤黧黬黭黮黰黱黲黵"],["8feda1","黸黿鼂鼃鼉鼏鼐鼑鼒鼔鼖鼗鼙鼚鼛鼟鼢鼦鼪鼫鼯鼱鼲鼴鼷鼹鼺鼼鼽鼿齁齃",4,"齓齕齖齗齘齚齝齞齨齩齭",4,"齳齵齺齽龏龐龑龒龔龖龗龞龡龢龣龥"]],require$$2=[["0","\0",127,"€"],["8140","丂丄丅丆丏丒丗丟丠両丣並丩丮丯丱丳丵丷丼乀乁乂乄乆乊乑乕乗乚乛乢乣乤乥乧乨乪",5,"乲乴",9,"乿",6,"亇亊"],["8180","亐亖亗亙亜亝亞亣亪亯亰亱亴亶亷亸亹亼亽亾仈仌仏仐仒仚仛仜仠仢仦仧仩仭仮仯仱仴仸仹仺仼仾伀伂",6,"伋伌伒",4,"伜伝伡伣伨伩伬伭伮伱伳伵伷伹伻伾",4,"佄佅佇",5,"佒佔佖佡佢佦佨佪佫佭佮佱佲併佷佸佹佺佽侀侁侂侅來侇侊侌侎侐侒侓侕侖侘侙侚侜侞侟価侢"],["8240","侤侫侭侰",4,"侶",8,"俀俁係俆俇俈俉俋俌俍俒",4,"俙俛俠俢俤俥俧俫俬俰俲俴俵俶俷俹俻俼俽俿",11],["8280","個倎倐們倓倕倖倗倛倝倞倠倢倣値倧倫倯",10,"倻倽倿偀偁偂偄偅偆偉偊偋偍偐",4,"偖偗偘偙偛偝",7,"偦",5,"偭",8,"偸偹偺偼偽傁傂傃傄傆傇傉傊傋傌傎",20,"傤傦傪傫傭",4,"傳",6,"傼"],["8340","傽",17,"僐",5,"僗僘僙僛",10,"僨僩僪僫僯僰僱僲僴僶",4,"僼",9,"儈"],["8380","儉儊儌",5,"儓",13,"儢",28,"兂兇兊兌兎兏児兒兓兗兘兙兛兝",4,"兣兤兦內兩兪兯兲兺兾兿冃冄円冇冊冋冎冏冐冑冓冔冘冚冝冞冟冡冣冦",4,"冭冮冴冸冹冺冾冿凁凂凃凅凈凊凍凎凐凒",5],["8440","凘凙凚凜凞凟凢凣凥",5,"凬凮凱凲凴凷凾刄刅刉刋刌刏刐刓刔刕刜刞刟刡刢刣別刦刧刪刬刯刱刲刴刵刼刾剄",5,"剋剎剏剒剓剕剗剘"],["8480","剙剚剛剝剟剠剢剣剤剦剨剫剬剭剮剰剱剳",9,"剾劀劃",4,"劉",6,"劑劒劔",6,"劜劤劥劦劧劮劯劰労",9,"勀勁勂勄勅勆勈勊勌勍勎勏勑勓勔動勗務",5,"勠勡勢勣勥",10,"勱",7,"勻勼勽匁匂匃匄匇匉匊匋匌匎"],["8540","匑匒匓匔匘匛匜匞匟匢匤匥匧匨匩匫匬匭匯",9,"匼匽區卂卄卆卋卌卍卐協単卙卛卝卥卨卪卬卭卲卶卹卻卼卽卾厀厁厃厇厈厊厎厏"],["8580","厐",4,"厖厗厙厛厜厞厠厡厤厧厪厫厬厭厯",6,"厷厸厹厺厼厽厾叀參",4,"収叏叐叒叓叕叚叜叝叞叡叢叧叴叺叾叿吀吂吅吇吋吔吘吙吚吜吢吤吥吪吰吳吶吷吺吽吿呁呂呄呅呇呉呌呍呎呏呑呚呝",4,"呣呥呧呩",7,"呴呹呺呾呿咁咃咅咇咈咉咊咍咑咓咗咘咜咞咟咠咡"],["8640","咢咥咮咰咲咵咶咷咹咺咼咾哃哅哊哋哖哘哛哠",4,"哫哬哯哰哱哴",5,"哻哾唀唂唃唄唅唈唊",4,"唒唓唕",5,"唜唝唞唟唡唥唦"],["8680","唨唩唫唭唲唴唵唶唸唹唺唻唽啀啂啅啇啈啋",4,"啑啒啓啔啗",4,"啝啞啟啠啢啣啨啩啫啯",5,"啹啺啽啿喅喆喌喍喎喐喒喓喕喖喗喚喛喞喠",6,"喨",8,"喲喴営喸喺喼喿",4,"嗆嗇嗈嗊嗋嗎嗏嗐嗕嗗",4,"嗞嗠嗢嗧嗩嗭嗮嗰嗱嗴嗶嗸",4,"嗿嘂嘃嘄嘅"],["8740","嘆嘇嘊嘋嘍嘐",7,"嘙嘚嘜嘝嘠嘡嘢嘥嘦嘨嘩嘪嘫嘮嘯嘰嘳嘵嘷嘸嘺嘼嘽嘾噀",11,"噏",4,"噕噖噚噛噝",4],["8780","噣噥噦噧噭噮噯噰噲噳噴噵噷噸噹噺噽",7,"嚇",6,"嚐嚑嚒嚔",14,"嚤",10,"嚰",6,"嚸嚹嚺嚻嚽",12,"囋",8,"囕囖囘囙囜団囥",5,"囬囮囯囲図囶囷囸囻囼圀圁圂圅圇國",6],["8840","園",9,"圝圞圠圡圢圤圥圦圧圫圱圲圴",4,"圼圽圿坁坃坄坅坆坈坉坋坒",4,"坘坙坢坣坥坧坬坮坰坱坲坴坵坸坹坺坽坾坿垀"],["8880","垁垇垈垉垊垍",4,"垔",6,"垜垝垞垟垥垨垪垬垯垰垱垳垵垶垷垹",8,"埄",6,"埌埍埐埑埓埖埗埛埜埞埡埢埣埥",7,"埮埰埱埲埳埵埶執埻埼埾埿堁堃堄堅堈堉堊堌堎堏堐堒堓堔堖堗堘堚堛堜堝堟堢堣堥",4,"堫",4,"報堲堳場堶",7],["8940","堾",5,"塅",6,"塎塏塐塒塓塕塖塗塙",4,"塟",5,"塦",4,"塭",16,"塿墂墄墆墇墈墊墋墌"],["8980","墍",4,"墔",4,"墛墜墝墠",7,"墪",17,"墽墾墿壀壂壃壄壆",10,"壒壓壔壖",13,"壥",5,"壭壯壱売壴壵壷壸壺",7,"夃夅夆夈",4,"夎夐夑夒夓夗夘夛夝夞夠夡夢夣夦夨夬夰夲夳夵夶夻"],["8a40","夽夾夿奀奃奅奆奊奌奍奐奒奓奙奛",4,"奡奣奤奦",12,"奵奷奺奻奼奾奿妀妅妉妋妌妎妏妐妑妔妕妘妚妛妜妝妟妠妡妢妦"],["8a80","妧妬妭妰妱妳",5,"妺妼妽妿",6,"姇姈姉姌姍姎姏姕姖姙姛姞",4,"姤姦姧姩姪姫姭",11,"姺姼姽姾娀娂娊娋娍娎娏娐娒娔娕娖娗娙娚娛娝娞娡娢娤娦娧娨娪",6,"娳娵娷",4,"娽娾娿婁",4,"婇婈婋",9,"婖婗婘婙婛",5],["8b40","婡婣婤婥婦婨婩婫",8,"婸婹婻婼婽婾媀",17,"媓",6,"媜",13,"媫媬"],["8b80","媭",4,"媴媶媷媹",4,"媿嫀嫃",5,"嫊嫋嫍",4,"嫓嫕嫗嫙嫚嫛嫝嫞嫟嫢嫤嫥嫧嫨嫪嫬",4,"嫲",22,"嬊",11,"嬘",25,"嬳嬵嬶嬸",7,"孁",6],["8c40","孈",7,"孒孖孞孠孡孧孨孫孭孮孯孲孴孶孷學孹孻孼孾孿宂宆宊宍宎宐宑宒宔宖実宧宨宩宬宭宮宯宱宲宷宺宻宼寀寁寃寈寉寊寋寍寎寏"],["8c80","寑寔",8,"寠寢寣實寧審",4,"寯寱",6,"寽対尀専尃尅將專尋尌對導尐尒尓尗尙尛尞尟尠尡尣尦尨尩尪尫尭尮尯尰尲尳尵尶尷屃屄屆屇屌屍屒屓屔屖屗屘屚屛屜屝屟屢層屧",6,"屰屲",6,"屻屼屽屾岀岃",4,"岉岊岋岎岏岒岓岕岝",4,"岤",4],["8d40","岪岮岯岰岲岴岶岹岺岻岼岾峀峂峃峅",5,"峌",5,"峓",5,"峚",6,"峢峣峧峩峫峬峮峯峱",9,"峼",4],["8d80","崁崄崅崈",5,"崏",4,"崕崗崘崙崚崜崝崟",4,"崥崨崪崫崬崯",4,"崵",7,"崿",7,"嵈嵉嵍",10,"嵙嵚嵜嵞",10,"嵪嵭嵮嵰嵱嵲嵳嵵",12,"嶃",21,"嶚嶛嶜嶞嶟嶠"],["8e40","嶡",21,"嶸",12,"巆",6,"巎",12,"巜巟巠巣巤巪巬巭"],["8e80","巰巵巶巸",4,"巿帀帄帇帉帊帋帍帎帒帓帗帞",7,"帨",4,"帯帰帲",4,"帹帺帾帿幀幁幃幆",5,"幍",6,"幖",4,"幜幝幟幠幣",14,"幵幷幹幾庁庂広庅庈庉庌庍庎庒庘庛庝庡庢庣庤庨",4,"庮",4,"庴庺庻庼庽庿",6],["8f40","廆廇廈廋",5,"廔廕廗廘廙廚廜",11,"廩廫",8,"廵廸廹廻廼廽弅弆弇弉弌弍弎弐弒弔弖弙弚弜弝弞弡弢弣弤"],["8f80","弨弫弬弮弰弲",6,"弻弽弾弿彁",14,"彑彔彙彚彛彜彞彟彠彣彥彧彨彫彮彯彲彴彵彶彸彺彽彾彿徃徆徍徎徏徑従徔徖徚徛徝從徟徠徢",5,"復徫徬徯",5,"徶徸徹徺徻徾",4,"忇忈忊忋忎忓忔忕忚忛応忞忟忢忣忥忦忨忩忬忯忰忲忳忴忶忷忹忺忼怇"],["9040","怈怉怋怌怐怑怓怗怘怚怞怟怢怣怤怬怭怮怰",4,"怶",4,"怽怾恀恄",6,"恌恎恏恑恓恔恖恗恘恛恜恞恟恠恡恥恦恮恱恲恴恵恷恾悀"],["9080","悁悂悅悆悇悈悊悋悎悏悐悑悓悕悗悘悙悜悞悡悢悤悥悧悩悪悮悰悳悵悶悷悹悺悽",7,"惇惈惉惌",4,"惒惓惔惖惗惙惛惞惡",4,"惪惱惲惵惷惸惻",4,"愂愃愄愅愇愊愋愌愐",4,"愖愗愘愙愛愜愝愞愡愢愥愨愩愪愬",18,"慀",6],["9140","慇慉態慍慏慐慒慓慔慖",6,"慞慟慠慡慣慤慥慦慩",6,"慱慲慳慴慶慸",18,"憌憍憏",4,"憕"],["9180","憖",6,"憞",8,"憪憫憭",9,"憸",5,"憿懀懁懃",4,"應懌",4,"懓懕",16,"懧",13,"懶",8,"戀",5,"戇戉戓戔戙戜戝戞戠戣戦戧戨戩戫戭戯戰戱戲戵戶戸",4,"扂扄扅扆扊"],["9240","扏扐払扖扗扙扚扜",6,"扤扥扨扱扲扴扵扷扸扺扻扽抁抂抃抅抆抇抈抋",5,"抔抙抜抝択抣抦抧抩抪抭抮抯抰抲抳抴抶抷抸抺抾拀拁"],["9280","拃拋拏拑拕拝拞拠拡拤拪拫拰拲拵拸拹拺拻挀挃挄挅挆挊挋挌挍挏挐挒挓挔挕挗挘挙挜挦挧挩挬挭挮挰挱挳",5,"挻挼挾挿捀捁捄捇捈捊捑捒捓捔捖",7,"捠捤捥捦捨捪捫捬捯捰捲捳捴捵捸捹捼捽捾捿掁掃掄掅掆掋掍掑掓掔掕掗掙",6,"採掤掦掫掯掱掲掵掶掹掻掽掿揀"],["9340","揁揂揃揅揇揈揊揋揌揑揓揔揕揗",6,"揟揢揤",4,"揫揬揮揯揰揱揳揵揷揹揺揻揼揾搃搄搆",4,"損搎搑搒搕",5,"搝搟搢搣搤"],["9380","搥搧搨搩搫搮",5,"搵",4,"搻搼搾摀摂摃摉摋",6,"摓摕摖摗摙",4,"摟",7,"摨摪摫摬摮",9,"摻",6,"撃撆撈",8,"撓撔撗撘撚撛撜撝撟",4,"撥撦撧撨撪撫撯撱撲撳撴撶撹撻撽撾撿擁擃擄擆",6,"擏擑擓擔擕擖擙據"],["9440","擛擜擝擟擠擡擣擥擧",24,"攁",7,"攊",7,"攓",4,"攙",8],["9480","攢攣攤攦",4,"攬攭攰攱攲攳攷攺攼攽敀",4,"敆敇敊敋敍敎敐敒敓敔敗敘敚敜敟敠敡敤敥敧敨敩敪敭敮敯敱敳敵敶數",14,"斈斉斊斍斎斏斒斔斕斖斘斚斝斞斠斢斣斦斨斪斬斮斱",7,"斺斻斾斿旀旂旇旈旉旊旍旐旑旓旔旕旘",7,"旡旣旤旪旫"],["9540","旲旳旴旵旸旹旻",4,"昁昄昅昇昈昉昋昍昐昑昒昖昗昘昚昛昜昞昡昢昣昤昦昩昪昫昬昮昰昲昳昷",4,"昽昿晀時晄",6,"晍晎晐晑晘"],["9580","晙晛晜晝晞晠晢晣晥晧晩",4,"晱晲晳晵晸晹晻晼晽晿暀暁暃暅暆暈暉暊暋暍暎暏暐暒暓暔暕暘",4,"暞",8,"暩",4,"暯",4,"暵暶暷暸暺暻暼暽暿",25,"曚曞",7,"曧曨曪",5,"曱曵曶書曺曻曽朁朂會"],["9640","朄朅朆朇朌朎朏朑朒朓朖朘朙朚朜朞朠",5,"朧朩朮朰朲朳朶朷朸朹朻朼朾朿杁杄杅杇杊杋杍杒杔杕杗",4,"杝杢杣杤杦杧杫杬杮東杴杶"],["9680","杸杹杺杻杽枀枂枃枅枆枈枊枌枍枎枏枑枒枓枔枖枙枛枟枠枡枤枦枩枬枮枱枲枴枹",7,"柂柅",9,"柕柖柗柛柟柡柣柤柦柧柨柪柫柭柮柲柵",7,"柾栁栂栃栄栆栍栐栒栔栕栘",4,"栞栟栠栢",6,"栫",6,"栴栵栶栺栻栿桇桋桍桏桒桖",5],["9740","桜桝桞桟桪桬",7,"桵桸",8,"梂梄梇",7,"梐梑梒梔梕梖梘",9,"梣梤梥梩梪梫梬梮梱梲梴梶梷梸"],["9780","梹",6,"棁棃",5,"棊棌棎棏棐棑棓棔棖棗棙棛",4,"棡棢棤",9,"棯棲棳棴棶棷棸棻棽棾棿椀椂椃椄椆",4,"椌椏椑椓",11,"椡椢椣椥",7,"椮椯椱椲椳椵椶椷椸椺椻椼椾楀楁楃",16,"楕楖楘楙楛楜楟"],["9840","楡楢楤楥楧楨楩楪楬業楯楰楲",4,"楺楻楽楾楿榁榃榅榊榋榌榎",5,"榖榗榙榚榝",9,"榩榪榬榮榯榰榲榳榵榶榸榹榺榼榽"],["9880","榾榿槀槂",7,"構槍槏槑槒槓槕",5,"槜槝槞槡",11,"槮槯槰槱槳",9,"槾樀",9,"樋",11,"標",5,"樠樢",5,"権樫樬樭樮樰樲樳樴樶",6,"樿",4,"橅橆橈",7,"橑",6,"橚"],["9940","橜",4,"橢橣橤橦",10,"橲",6,"橺橻橽橾橿檁檂檃檅",8,"檏檒",4,"檘",7,"檡",5],["9980","檧檨檪檭",114,"欥欦欨",6],["9a40","欯欰欱欳欴欵欶欸欻欼欽欿歀歁歂歄歅歈歊歋歍",11,"歚",7,"歨歩歫",13,"歺歽歾歿殀殅殈"],["9a80","殌殎殏殐殑殔殕殗殘殙殜",4,"殢",7,"殫",7,"殶殸",6,"毀毃毄毆",4,"毌毎毐毑毘毚毜",4,"毢",7,"毬毭毮毰毱毲毴毶毷毸毺毻毼毾",6,"氈",4,"氎氒気氜氝氞氠氣氥氫氬氭氱氳氶氷氹氺氻氼氾氿汃汄汅汈汋",4,"汑汒汓汖汘"],["9b40","汙汚汢汣汥汦汧汫",4,"汱汳汵汷汸決汻汼汿沀沄沇沊沋沍沎沑沒沕沖沗沘沚沜沝沞沠沢沨沬沯沰沴沵沶沷沺泀況泂泃泆泇泈泋泍泎泏泑泒泘"],["9b80","泙泚泜泝泟泤泦泧泩泬泭泲泴泹泿洀洂洃洅洆洈洉洊洍洏洐洑洓洔洕洖洘洜洝洟",5,"洦洨洩洬洭洯洰洴洶洷洸洺洿浀浂浄浉浌浐浕浖浗浘浛浝浟浡浢浤浥浧浨浫浬浭浰浱浲浳浵浶浹浺浻浽",4,"涃涄涆涇涊涋涍涏涐涒涖",4,"涜涢涥涬涭涰涱涳涴涶涷涹",5,"淁淂淃淈淉淊"],["9c40","淍淎淏淐淒淓淔淕淗淚淛淜淟淢淣淥淧淨淩淪淭淯淰淲淴淵淶淸淺淽",7,"渆渇済渉渋渏渒渓渕渘渙減渜渞渟渢渦渧渨渪測渮渰渱渳渵"],["9c80","渶渷渹渻",7,"湅",7,"湏湐湑湒湕湗湙湚湜湝湞湠",10,"湬湭湯",14,"満溁溂溄溇溈溊",4,"溑",6,"溙溚溛溝溞溠溡溣溤溦溨溩溫溬溭溮溰溳溵溸溹溼溾溿滀滃滄滅滆滈滉滊滌滍滎滐滒滖滘滙滛滜滝滣滧滪",5],["9d40","滰滱滲滳滵滶滷滸滺",7,"漃漄漅漇漈漊",4,"漐漑漒漖",9,"漡漢漣漥漦漧漨漬漮漰漲漴漵漷",6,"漿潀潁潂"],["9d80","潃潄潅潈潉潊潌潎",9,"潙潚潛潝潟潠潡潣潤潥潧",5,"潯潰潱潳潵潶潷潹潻潽",6,"澅澆澇澊澋澏",12,"澝澞澟澠澢",4,"澨",10,"澴澵澷澸澺",5,"濁濃",5,"濊",6,"濓",10,"濟濢濣濤濥"],["9e40","濦",7,"濰",32,"瀒",7,"瀜",6,"瀤",6],["9e80","瀫",9,"瀶瀷瀸瀺",17,"灍灎灐",13,"灟",11,"灮灱灲灳灴灷灹灺灻災炁炂炃炄炆炇炈炋炌炍炏炐炑炓炗炘炚炛炞",12,"炰炲炴炵炶為炾炿烄烅烆烇烉烋",12,"烚"],["9f40","烜烝烞烠烡烢烣烥烪烮烰",6,"烸烺烻烼烾",10,"焋",4,"焑焒焔焗焛",10,"焧",7,"焲焳焴"],["9f80","焵焷",13,"煆煇煈煉煋煍煏",12,"煝煟",4,"煥煩",4,"煯煰煱煴煵煶煷煹煻煼煾",5,"熅",4,"熋熌熍熎熐熑熒熓熕熖熗熚",4,"熡",6,"熩熪熫熭",5,"熴熶熷熸熺",8,"燄",9,"燏",4],["a040","燖",9,"燡燢燣燤燦燨",5,"燯",9,"燺",11,"爇",19],["a080","爛爜爞",9,"爩爫爭爮爯爲爳爴爺爼爾牀",6,"牉牊牋牎牏牐牑牓牔牕牗牘牚牜牞牠牣牤牥牨牪牫牬牭牰牱牳牴牶牷牸牻牼牽犂犃犅",4,"犌犎犐犑犓",11,"犠",11,"犮犱犲犳犵犺",6,"狅狆狇狉狊狋狌狏狑狓狔狕狖狘狚狛"],["a1a1"," 、。·ˉˇ¨〃々—~‖…‘’“”〔〕〈",7,"〖〗【】±×÷∶∧∨∑∏∪∩∈∷√⊥∥∠⌒⊙∫∮≡≌≈∽∝≠≮≯≤≥∞∵∴♂♀°′″℃$¤¢£‰§№☆★○●◎◇◆□■△▲※→←↑↓〓"],["a2a1","ⅰ",9],["a2b1","⒈",19,"⑴",19,"①",9],["a2e5","㈠",9],["a2f1","Ⅰ",11],["a3a1","!"#¥%",88," ̄"],["a4a1","ぁ",82],["a5a1","ァ",85],["a6a1","Α",16,"Σ",6],["a6c1","α",16,"σ",6],["a6e0","︵︶︹︺︿﹀︽︾﹁﹂﹃﹄"],["a6ee","︻︼︷︸︱"],["a6f4","︳︴"],["a7a1","А",5,"ЁЖ",25],["a7d1","а",5,"ёж",25],["a840","ˊˋ˙–―‥‵℅℉↖↗↘↙∕∟∣≒≦≧⊿═",35,"▁",6],["a880","█",7,"▓▔▕▼▽◢◣◤◥☉⊕〒〝〞"],["a8a1","āáǎàēéěèīíǐìōóǒòūúǔùǖǘǚǜüêɑ"],["a8bd","ńň"],["a8c0","ɡ"],["a8c5","ㄅ",36],["a940","〡",8,"㊣㎎㎏㎜㎝㎞㎡㏄㏎㏑㏒㏕︰¬¦"],["a959","℡㈱"],["a95c","‐"],["a960","ー゛゜ヽヾ〆ゝゞ﹉",9,"﹔﹕﹖﹗﹙",8],["a980","﹢",4,"﹨﹩﹪﹫"],["a996","〇"],["a9a4","─",75],["aa40","狜狝狟狢",5,"狪狫狵狶狹狽狾狿猀猂猄",5,"猋猌猍猏猐猑猒猔猘猙猚猟猠猣猤猦猧猨猭猯猰猲猳猵猶猺猻猼猽獀",8],["aa80","獉獊獋獌獎獏獑獓獔獕獖獘",7,"獡",10,"獮獰獱"],["ab40","獲",11,"獿",4,"玅玆玈玊玌玍玏玐玒玓玔玕玗玘玙玚玜玝玞玠玡玣",5,"玪玬玭玱玴玵玶玸玹玼玽玾玿珁珃",4],["ab80","珋珌珎珒",6,"珚珛珜珝珟珡珢珣珤珦珨珪珫珬珮珯珰珱珳",4],["ac40","珸",10,"琄琇琈琋琌琍琎琑",8,"琜",5,"琣琤琧琩琫琭琯琱琲琷",4,"琽琾琿瑀瑂",11],["ac80","瑎",6,"瑖瑘瑝瑠",12,"瑮瑯瑱",4,"瑸瑹瑺"],["ad40","瑻瑼瑽瑿璂璄璅璆璈璉璊璌璍璏璑",10,"璝璟",7,"璪",15,"璻",12],["ad80","瓈",9,"瓓",8,"瓝瓟瓡瓥瓧",6,"瓰瓱瓲"],["ae40","瓳瓵瓸",6,"甀甁甂甃甅",7,"甎甐甒甔甕甖甗甛甝甞甠",4,"甦甧甪甮甴甶甹甼甽甿畁畂畃畄畆畇畉畊畍畐畑畒畓畕畖畗畘"],["ae80","畝",7,"畧畨畩畫",6,"畳畵當畷畺",4,"疀疁疂疄疅疇"],["af40","疈疉疊疌疍疎疐疓疕疘疛疜疞疢疦",4,"疭疶疷疺疻疿痀痁痆痋痌痎痏痐痑痓痗痙痚痜痝痟痠痡痥痩痬痭痮痯痲痳痵痶痷痸痺痻痽痾瘂瘄瘆瘇"],["af80","瘈瘉瘋瘍瘎瘏瘑瘒瘓瘔瘖瘚瘜瘝瘞瘡瘣瘧瘨瘬瘮瘯瘱瘲瘶瘷瘹瘺瘻瘽癁療癄"],["b040","癅",6,"癎",5,"癕癗",4,"癝癟癠癡癢癤",6,"癬癭癮癰",7,"癹発發癿皀皁皃皅皉皊皌皍皏皐皒皔皕皗皘皚皛"],["b080","皜",7,"皥",8,"皯皰皳皵",9,"盀盁盃啊阿埃挨哎唉哀皑癌蔼矮艾碍爱隘鞍氨安俺按暗岸胺案肮昂盎凹敖熬翱袄傲奥懊澳芭捌扒叭吧笆八疤巴拔跋靶把耙坝霸罢爸白柏百摆佰败拜稗斑班搬扳般颁板版扮拌伴瓣半办绊邦帮梆榜膀绑棒磅蚌镑傍谤苞胞包褒剥"],["b140","盄盇盉盋盌盓盕盙盚盜盝盞盠",4,"盦",7,"盰盳盵盶盷盺盻盽盿眀眂眃眅眆眊県眎",10,"眛眜眝眞眡眣眤眥眧眪眫"],["b180","眬眮眰",4,"眹眻眽眾眿睂睄睅睆睈",7,"睒",7,"睜薄雹保堡饱宝抱报暴豹鲍爆杯碑悲卑北辈背贝钡倍狈备惫焙被奔苯本笨崩绷甭泵蹦迸逼鼻比鄙笔彼碧蓖蔽毕毙毖币庇痹闭敝弊必辟壁臂避陛鞭边编贬扁便变卞辨辩辫遍标彪膘表鳖憋别瘪彬斌濒滨宾摈兵冰柄丙秉饼炳"],["b240","睝睞睟睠睤睧睩睪睭",11,"睺睻睼瞁瞂瞃瞆",5,"瞏瞐瞓",11,"瞡瞣瞤瞦瞨瞫瞭瞮瞯瞱瞲瞴瞶",4],["b280","瞼瞾矀",12,"矎",8,"矘矙矚矝",4,"矤病并玻菠播拨钵波博勃搏铂箔伯帛舶脖膊渤泊驳捕卜哺补埠不布步簿部怖擦猜裁材才财睬踩采彩菜蔡餐参蚕残惭惨灿苍舱仓沧藏操糙槽曹草厕策侧册测层蹭插叉茬茶查碴搽察岔差诧拆柴豺搀掺蝉馋谗缠铲产阐颤昌猖"],["b340","矦矨矪矯矰矱矲矴矵矷矹矺矻矼砃",5,"砊砋砎砏砐砓砕砙砛砞砠砡砢砤砨砪砫砮砯砱砲砳砵砶砽砿硁硂硃硄硆硈硉硊硋硍硏硑硓硔硘硙硚"],["b380","硛硜硞",11,"硯",7,"硸硹硺硻硽",6,"场尝常长偿肠厂敞畅唱倡超抄钞朝嘲潮巢吵炒车扯撤掣彻澈郴臣辰尘晨忱沉陈趁衬撑称城橙成呈乘程惩澄诚承逞骋秤吃痴持匙池迟弛驰耻齿侈尺赤翅斥炽充冲虫崇宠抽酬畴踌稠愁筹仇绸瞅丑臭初出橱厨躇锄雏滁除楚"],["b440","碄碅碆碈碊碋碏碐碒碔碕碖碙碝碞碠碢碤碦碨",7,"碵碶碷碸確碻碼碽碿磀磂磃磄磆磇磈磌磍磎磏磑磒磓磖磗磘磚",9],["b480","磤磥磦磧磩磪磫磭",4,"磳磵磶磸磹磻",5,"礂礃礄礆",6,"础储矗搐触处揣川穿椽传船喘串疮窗幢床闯创吹炊捶锤垂春椿醇唇淳纯蠢戳绰疵茨磁雌辞慈瓷词此刺赐次聪葱囱匆从丛凑粗醋簇促蹿篡窜摧崔催脆瘁粹淬翠村存寸磋撮搓措挫错搭达答瘩打大呆歹傣戴带殆代贷袋待逮"],["b540","礍",5,"礔",9,"礟",4,"礥",14,"礵",4,"礽礿祂祃祄祅祇祊",8,"祔祕祘祙祡祣"],["b580","祤祦祩祪祫祬祮祰",6,"祹祻",4,"禂禃禆禇禈禉禋禌禍禎禐禑禒怠耽担丹单郸掸胆旦氮但惮淡诞弹蛋当挡党荡档刀捣蹈倒岛祷导到稻悼道盗德得的蹬灯登等瞪凳邓堤低滴迪敌笛狄涤翟嫡抵底地蒂第帝弟递缔颠掂滇碘点典靛垫电佃甸店惦奠淀殿碉叼雕凋刁掉吊钓调跌爹碟蝶迭谍叠"],["b640","禓",6,"禛",11,"禨",10,"禴",4,"禼禿秂秄秅秇秈秊秌秎秏秐秓秔秖秗秙",5,"秠秡秢秥秨秪"],["b680","秬秮秱",6,"秹秺秼秾秿稁稄稅稇稈稉稊稌稏",4,"稕稖稘稙稛稜丁盯叮钉顶鼎锭定订丢东冬董懂动栋侗恫冻洞兜抖斗陡豆逗痘都督毒犊独读堵睹赌杜镀肚度渡妒端短锻段断缎堆兑队对墩吨蹲敦顿囤钝盾遁掇哆多夺垛躲朵跺舵剁惰堕蛾峨鹅俄额讹娥恶厄扼遏鄂饿恩而儿耳尔饵洱二"],["b740","稝稟稡稢稤",14,"稴稵稶稸稺稾穀",5,"穇",9,"穒",4,"穘",16],["b780","穩",6,"穱穲穳穵穻穼穽穾窂窅窇窉窊窋窌窎窏窐窓窔窙窚窛窞窡窢贰发罚筏伐乏阀法珐藩帆番翻樊矾钒繁凡烦反返范贩犯饭泛坊芳方肪房防妨仿访纺放菲非啡飞肥匪诽吠肺废沸费芬酚吩氛分纷坟焚汾粉奋份忿愤粪丰封枫蜂峰锋风疯烽逢冯缝讽奉凤佛否夫敷肤孵扶拂辐幅氟符伏俘服"],["b840","窣窤窧窩窪窫窮",4,"窴",10,"竀",10,"竌",9,"竗竘竚竛竜竝竡竢竤竧",5,"竮竰竱竲竳"],["b880","竴",4,"竻竼竾笀笁笂笅笇笉笌笍笎笐笒笓笖笗笘笚笜笝笟笡笢笣笧笩笭浮涪福袱弗甫抚辅俯釜斧脯腑府腐赴副覆赋复傅付阜父腹负富讣附妇缚咐噶嘎该改概钙盖溉干甘杆柑竿肝赶感秆敢赣冈刚钢缸肛纲岗港杠篙皋高膏羔糕搞镐稿告哥歌搁戈鸽胳疙割革葛格蛤阁隔铬个各给根跟耕更庚羹"],["b940","笯笰笲笴笵笶笷笹笻笽笿",5,"筆筈筊筍筎筓筕筗筙筜筞筟筡筣",10,"筯筰筳筴筶筸筺筼筽筿箁箂箃箄箆",6,"箎箏"],["b980","箑箒箓箖箘箙箚箛箞箟箠箣箤箥箮箯箰箲箳箵箶箷箹",7,"篂篃範埂耿梗工攻功恭龚供躬公宫弓巩汞拱贡共钩勾沟苟狗垢构购够辜菇咕箍估沽孤姑鼓古蛊骨谷股故顾固雇刮瓜剐寡挂褂乖拐怪棺关官冠观管馆罐惯灌贯光广逛瑰规圭硅归龟闺轨鬼诡癸桂柜跪贵刽辊滚棍锅郭国果裹过哈"],["ba40","篅篈築篊篋篍篎篏篐篒篔",4,"篛篜篞篟篠篢篣篤篧篨篩篫篬篭篯篰篲",4,"篸篹篺篻篽篿",7,"簈簉簊簍簎簐",5,"簗簘簙"],["ba80","簚",4,"簠",5,"簨簩簫",12,"簹",5,"籂骸孩海氦亥害骇酣憨邯韩含涵寒函喊罕翰撼捍旱憾悍焊汗汉夯杭航壕嚎豪毫郝好耗号浩呵喝荷菏核禾和何合盒貉阂河涸赫褐鹤贺嘿黑痕很狠恨哼亨横衡恒轰哄烘虹鸿洪宏弘红喉侯猴吼厚候后呼乎忽瑚壶葫胡蝴狐糊湖"],["bb40","籃",9,"籎",36,"籵",5,"籾",9],["bb80","粈粊",6,"粓粔粖粙粚粛粠粡粣粦粧粨粩粫粬粭粯粰粴",4,"粺粻弧虎唬护互沪户花哗华猾滑画划化话槐徊怀淮坏欢环桓还缓换患唤痪豢焕涣宦幻荒慌黄磺蝗簧皇凰惶煌晃幌恍谎灰挥辉徽恢蛔回毁悔慧卉惠晦贿秽会烩汇讳诲绘荤昏婚魂浑混豁活伙火获或惑霍货祸击圾基机畸稽积箕"],["bc40","粿糀糂糃糄糆糉糋糎",6,"糘糚糛糝糞糡",6,"糩",5,"糰",7,"糹糺糼",13,"紋",5],["bc80","紑",14,"紡紣紤紥紦紨紩紪紬紭紮細",6,"肌饥迹激讥鸡姬绩缉吉极棘辑籍集及急疾汲即嫉级挤几脊己蓟技冀季伎祭剂悸济寄寂计记既忌际妓继纪嘉枷夹佳家加荚颊贾甲钾假稼价架驾嫁歼监坚尖笺间煎兼肩艰奸缄茧检柬碱硷拣捡简俭剪减荐槛鉴践贱见键箭件"],["bd40","紷",54,"絯",7],["bd80","絸",32,"健舰剑饯渐溅涧建僵姜将浆江疆蒋桨奖讲匠酱降蕉椒礁焦胶交郊浇骄娇嚼搅铰矫侥脚狡角饺缴绞剿教酵轿较叫窖揭接皆秸街阶截劫节桔杰捷睫竭洁结解姐戒藉芥界借介疥诫届巾筋斤金今津襟紧锦仅谨进靳晋禁近烬浸"],["be40","継",12,"綧",6,"綯",42],["be80","線",32,"尽劲荆兢茎睛晶鲸京惊精粳经井警景颈静境敬镜径痉靖竟竞净炯窘揪究纠玖韭久灸九酒厩救旧臼舅咎就疚鞠拘狙疽居驹菊局咀矩举沮聚拒据巨具距踞锯俱句惧炬剧捐鹃娟倦眷卷绢撅攫抉掘倔爵觉决诀绝均菌钧军君峻"],["bf40","緻",62],["bf80","縺縼",4,"繂",4,"繈",21,"俊竣浚郡骏喀咖卡咯开揩楷凯慨刊堪勘坎砍看康慷糠扛抗亢炕考拷烤靠坷苛柯棵磕颗科壳咳可渴克刻客课肯啃垦恳坑吭空恐孔控抠口扣寇枯哭窟苦酷库裤夸垮挎跨胯块筷侩快宽款匡筐狂框矿眶旷况亏盔岿窥葵奎魁傀"],["c040","繞",35,"纃",23,"纜纝纞"],["c080","纮纴纻纼绖绤绬绹缊缐缞缷缹缻",6,"罃罆",9,"罒罓馈愧溃坤昆捆困括扩廓阔垃拉喇蜡腊辣啦莱来赖蓝婪栏拦篮阑兰澜谰揽览懒缆烂滥琅榔狼廊郎朗浪捞劳牢老佬姥酪烙涝勒乐雷镭蕾磊累儡垒擂肋类泪棱楞冷厘梨犁黎篱狸离漓理李里鲤礼莉荔吏栗丽厉励砾历利傈例俐"],["c140","罖罙罛罜罝罞罠罣",4,"罫罬罭罯罰罳罵罶罷罸罺罻罼罽罿羀羂",7,"羋羍羏",4,"羕",4,"羛羜羠羢羣羥羦羨",6,"羱"],["c180","羳",4,"羺羻羾翀翂翃翄翆翇翈翉翋翍翏",4,"翖翗翙",5,"翢翣痢立粒沥隶力璃哩俩联莲连镰廉怜涟帘敛脸链恋炼练粮凉梁粱良两辆量晾亮谅撩聊僚疗燎寥辽潦了撂镣廖料列裂烈劣猎琳林磷霖临邻鳞淋凛赁吝拎玲菱零龄铃伶羚凌灵陵岭领另令溜琉榴硫馏留刘瘤流柳六龙聋咙笼窿"],["c240","翤翧翨翪翫翬翭翯翲翴",6,"翽翾翿耂耇耈耉耊耎耏耑耓耚耛耝耞耟耡耣耤耫",5,"耲耴耹耺耼耾聀聁聄聅聇聈聉聎聏聐聑聓聕聖聗"],["c280","聙聛",13,"聫",5,"聲",11,"隆垄拢陇楼娄搂篓漏陋芦卢颅庐炉掳卤虏鲁麓碌露路赂鹿潞禄录陆戮驴吕铝侣旅履屡缕虑氯律率滤绿峦挛孪滦卵乱掠略抡轮伦仑沦纶论萝螺罗逻锣箩骡裸落洛骆络妈麻玛码蚂马骂嘛吗埋买麦卖迈脉瞒馒蛮满蔓曼慢漫"],["c340","聾肁肂肅肈肊肍",5,"肔肕肗肙肞肣肦肧肨肬肰肳肵肶肸肹肻胅胇",4,"胏",6,"胘胟胠胢胣胦胮胵胷胹胻胾胿脀脁脃脄脅脇脈脋"],["c380","脌脕脗脙脛脜脝脟",12,"脭脮脰脳脴脵脷脹",4,"脿谩芒茫盲氓忙莽猫茅锚毛矛铆卯茂冒帽貌贸么玫枚梅酶霉煤没眉媒镁每美昧寐妹媚门闷们萌蒙檬盟锰猛梦孟眯醚靡糜迷谜弥米秘觅泌蜜密幂棉眠绵冕免勉娩缅面苗描瞄藐秒渺庙妙蔑灭民抿皿敏悯闽明螟鸣铭名命谬摸"],["c440","腀",5,"腇腉腍腎腏腒腖腗腘腛",4,"腡腢腣腤腦腨腪腫腬腯腲腳腵腶腷腸膁膃",4,"膉膋膌膍膎膐膒",5,"膙膚膞",4,"膤膥"],["c480","膧膩膫",7,"膴",5,"膼膽膾膿臄臅臇臈臉臋臍",6,"摹蘑模膜磨摩魔抹末莫墨默沫漠寞陌谋牟某拇牡亩姆母墓暮幕募慕木目睦牧穆拿哪呐钠那娜纳氖乃奶耐奈南男难囊挠脑恼闹淖呢馁内嫩能妮霓倪泥尼拟你匿腻逆溺蔫拈年碾撵捻念娘酿鸟尿捏聂孽啮镊镍涅您柠狞凝宁"],["c540","臔",14,"臤臥臦臨臩臫臮",4,"臵",5,"臽臿舃與",4,"舎舏舑舓舕",5,"舝舠舤舥舦舧舩舮舲舺舼舽舿"],["c580","艀艁艂艃艅艆艈艊艌艍艎艐",7,"艙艛艜艝艞艠",7,"艩拧泞牛扭钮纽脓浓农弄奴努怒女暖虐疟挪懦糯诺哦欧鸥殴藕呕偶沤啪趴爬帕怕琶拍排牌徘湃派攀潘盘磐盼畔判叛乓庞旁耪胖抛咆刨炮袍跑泡呸胚培裴赔陪配佩沛喷盆砰抨烹澎彭蓬棚硼篷膨朋鹏捧碰坯砒霹批披劈琵毗"],["c640","艪艫艬艭艱艵艶艷艸艻艼芀芁芃芅芆芇芉芌芐芓芔芕芖芚芛芞芠芢芣芧芲芵芶芺芻芼芿苀苂苃苅苆苉苐苖苙苚苝苢苧苨苩苪苬苭苮苰苲苳苵苶苸"],["c680","苺苼",4,"茊茋茍茐茒茓茖茘茙茝",9,"茩茪茮茰茲茷茻茽啤脾疲皮匹痞僻屁譬篇偏片骗飘漂瓢票撇瞥拼频贫品聘乒坪苹萍平凭瓶评屏坡泼颇婆破魄迫粕剖扑铺仆莆葡菩蒲埔朴圃普浦谱曝瀑期欺栖戚妻七凄漆柒沏其棋奇歧畦崎脐齐旗祈祁骑起岂乞企启契砌器气迄弃汽泣讫掐"],["c740","茾茿荁荂荄荅荈荊",4,"荓荕",4,"荝荢荰",6,"荹荺荾",6,"莇莈莊莋莌莍莏莐莑莔莕莖莗莙莚莝莟莡",6,"莬莭莮"],["c780","莯莵莻莾莿菂菃菄菆菈菉菋菍菎菐菑菒菓菕菗菙菚菛菞菢菣菤菦菧菨菫菬菭恰洽牵扦钎铅千迁签仟谦乾黔钱钳前潜遣浅谴堑嵌欠歉枪呛腔羌墙蔷强抢橇锹敲悄桥瞧乔侨巧鞘撬翘峭俏窍切茄且怯窃钦侵亲秦琴勤芹擒禽寝沁青轻氢倾卿清擎晴氰情顷请庆琼穷秋丘邱球求囚酋泅趋区蛆曲躯屈驱渠"],["c840","菮華菳",4,"菺菻菼菾菿萀萂萅萇萈萉萊萐萒",5,"萙萚萛萞",5,"萩",7,"萲",5,"萹萺萻萾",7,"葇葈葉"],["c880","葊",6,"葒",4,"葘葝葞葟葠葢葤",4,"葪葮葯葰葲葴葷葹葻葼取娶龋趣去圈颧权醛泉全痊拳犬券劝缺炔瘸却鹊榷确雀裙群然燃冉染瓤壤攘嚷让饶扰绕惹热壬仁人忍韧任认刃妊纫扔仍日戎茸蓉荣融熔溶容绒冗揉柔肉茹蠕儒孺如辱乳汝入褥软阮蕊瑞锐闰润若弱撒洒萨腮鳃塞赛三叁"],["c940","葽",4,"蒃蒄蒅蒆蒊蒍蒏",7,"蒘蒚蒛蒝蒞蒟蒠蒢",12,"蒰蒱蒳蒵蒶蒷蒻蒼蒾蓀蓂蓃蓅蓆蓇蓈蓋蓌蓎蓏蓒蓔蓕蓗"],["c980","蓘",4,"蓞蓡蓢蓤蓧",4,"蓭蓮蓯蓱",10,"蓽蓾蔀蔁蔂伞散桑嗓丧搔骚扫嫂瑟色涩森僧莎砂杀刹沙纱傻啥煞筛晒珊苫杉山删煽衫闪陕擅赡膳善汕扇缮墒伤商赏晌上尚裳梢捎稍烧芍勺韶少哨邵绍奢赊蛇舌舍赦摄射慑涉社设砷申呻伸身深娠绅神沈审婶甚肾慎渗声生甥牲升绳"],["ca40","蔃",8,"蔍蔎蔏蔐蔒蔔蔕蔖蔘蔙蔛蔜蔝蔞蔠蔢",8,"蔭",9,"蔾",4,"蕄蕅蕆蕇蕋",10],["ca80","蕗蕘蕚蕛蕜蕝蕟",4,"蕥蕦蕧蕩",8,"蕳蕵蕶蕷蕸蕼蕽蕿薀薁省盛剩胜圣师失狮施湿诗尸虱十石拾时什食蚀实识史矢使屎驶始式示士世柿事拭誓逝势是嗜噬适仕侍释饰氏市恃室视试收手首守寿授售受瘦兽蔬枢梳殊抒输叔舒淑疏书赎孰熟薯暑曙署蜀黍鼠属术述树束戍竖墅庶数漱"],["cb40","薂薃薆薈",6,"薐",10,"薝",6,"薥薦薧薩薫薬薭薱",5,"薸薺",6,"藂",6,"藊",4,"藑藒"],["cb80","藔藖",5,"藝",6,"藥藦藧藨藪",14,"恕刷耍摔衰甩帅栓拴霜双爽谁水睡税吮瞬顺舜说硕朔烁斯撕嘶思私司丝死肆寺嗣四伺似饲巳松耸怂颂送宋讼诵搜艘擞嗽苏酥俗素速粟僳塑溯宿诉肃酸蒜算虽隋随绥髓碎岁穗遂隧祟孙损笋蓑梭唆缩琐索锁所塌他它她塔"],["cc40","藹藺藼藽藾蘀",4,"蘆",10,"蘒蘓蘔蘕蘗",15,"蘨蘪",13,"蘹蘺蘻蘽蘾蘿虀"],["cc80","虁",11,"虒虓處",4,"虛虜虝號虠虡虣",7,"獭挞蹋踏胎苔抬台泰酞太态汰坍摊贪瘫滩坛檀痰潭谭谈坦毯袒碳探叹炭汤塘搪堂棠膛唐糖倘躺淌趟烫掏涛滔绦萄桃逃淘陶讨套特藤腾疼誊梯剔踢锑提题蹄啼体替嚏惕涕剃屉天添填田甜恬舔腆挑条迢眺跳贴铁帖厅听烃"],["cd40","虭虯虰虲",6,"蚃",6,"蚎",4,"蚔蚖",5,"蚞",4,"蚥蚦蚫蚭蚮蚲蚳蚷蚸蚹蚻",4,"蛁蛂蛃蛅蛈蛌蛍蛒蛓蛕蛖蛗蛚蛜"],["cd80","蛝蛠蛡蛢蛣蛥蛦蛧蛨蛪蛫蛬蛯蛵蛶蛷蛺蛻蛼蛽蛿蜁蜄蜅蜆蜋蜌蜎蜏蜐蜑蜔蜖汀廷停亭庭挺艇通桐酮瞳同铜彤童桶捅筒统痛偷投头透凸秃突图徒途涂屠土吐兔湍团推颓腿蜕褪退吞屯臀拖托脱鸵陀驮驼椭妥拓唾挖哇蛙洼娃瓦袜歪外豌弯湾玩顽丸烷完碗挽晚皖惋宛婉万腕汪王亡枉网往旺望忘妄威"],["ce40","蜙蜛蜝蜟蜠蜤蜦蜧蜨蜪蜫蜬蜭蜯蜰蜲蜳蜵蜶蜸蜹蜺蜼蜽蝀",6,"蝊蝋蝍蝏蝐蝑蝒蝔蝕蝖蝘蝚",5,"蝡蝢蝦",7,"蝯蝱蝲蝳蝵"],["ce80","蝷蝸蝹蝺蝿螀螁螄螆螇螉螊螌螎",4,"螔螕螖螘",6,"螠",4,"巍微危韦违桅围唯惟为潍维苇萎委伟伪尾纬未蔚味畏胃喂魏位渭谓尉慰卫瘟温蚊文闻纹吻稳紊问嗡翁瓮挝蜗涡窝我斡卧握沃巫呜钨乌污诬屋无芜梧吾吴毋武五捂午舞伍侮坞戊雾晤物勿务悟误昔熙析西硒矽晰嘻吸锡牺"],["cf40","螥螦螧螩螪螮螰螱螲螴螶螷螸螹螻螼螾螿蟁",4,"蟇蟈蟉蟌",4,"蟔",6,"蟜蟝蟞蟟蟡蟢蟣蟤蟦蟧蟨蟩蟫蟬蟭蟯",9],["cf80","蟺蟻蟼蟽蟿蠀蠁蠂蠄",5,"蠋",7,"蠔蠗蠘蠙蠚蠜",4,"蠣稀息希悉膝夕惜熄烯溪汐犀檄袭席习媳喜铣洗系隙戏细瞎虾匣霞辖暇峡侠狭下厦夏吓掀锨先仙鲜纤咸贤衔舷闲涎弦嫌显险现献县腺馅羡宪陷限线相厢镶香箱襄湘乡翔祥详想响享项巷橡像向象萧硝霄削哮嚣销消宵淆晓"],["d040","蠤",13,"蠳",5,"蠺蠻蠽蠾蠿衁衂衃衆",5,"衎",5,"衕衖衘衚",6,"衦衧衪衭衯衱衳衴衵衶衸衹衺"],["d080","衻衼袀袃袆袇袉袊袌袎袏袐袑袓袔袕袗",4,"袝",4,"袣袥",5,"小孝校肖啸笑效楔些歇蝎鞋协挟携邪斜胁谐写械卸蟹懈泄泻谢屑薪芯锌欣辛新忻心信衅星腥猩惺兴刑型形邢行醒幸杏性姓兄凶胸匈汹雄熊休修羞朽嗅锈秀袖绣墟戌需虚嘘须徐许蓄酗叙旭序畜恤絮婿绪续轩喧宣悬旋玄"],["d140","袬袮袯袰袲",4,"袸袹袺袻袽袾袿裀裃裄裇裈裊裋裌裍裏裐裑裓裖裗裚",4,"裠裡裦裧裩",6,"裲裵裶裷裺裻製裿褀褁褃",5],["d180","褉褋",4,"褑褔",4,"褜",4,"褢褣褤褦褧褨褩褬褭褮褯褱褲褳褵褷选癣眩绚靴薛学穴雪血勋熏循旬询寻驯巡殉汛训讯逊迅压押鸦鸭呀丫芽牙蚜崖衙涯雅哑亚讶焉咽阉烟淹盐严研蜒岩延言颜阎炎沿奄掩眼衍演艳堰燕厌砚雁唁彦焰宴谚验殃央鸯秧杨扬佯疡羊洋阳氧仰痒养样漾邀腰妖瑶"],["d240","褸",8,"襂襃襅",24,"襠",5,"襧",19,"襼"],["d280","襽襾覀覂覄覅覇",26,"摇尧遥窑谣姚咬舀药要耀椰噎耶爷野冶也页掖业叶曳腋夜液一壹医揖铱依伊衣颐夷遗移仪胰疑沂宜姨彝椅蚁倚已乙矣以艺抑易邑屹亿役臆逸肄疫亦裔意毅忆义益溢诣议谊译异翼翌绎茵荫因殷音阴姻吟银淫寅饮尹引隐"],["d340","覢",30,"觃觍觓觔觕觗觘觙觛觝觟觠觡觢觤觧觨觩觪觬觭觮觰觱觲觴",6],["d380","觻",4,"訁",5,"計",21,"印英樱婴鹰应缨莹萤营荧蝇迎赢盈影颖硬映哟拥佣臃痈庸雍踊蛹咏泳涌永恿勇用幽优悠忧尤由邮铀犹油游酉有友右佑釉诱又幼迂淤于盂榆虞愚舆余俞逾鱼愉渝渔隅予娱雨与屿禹宇语羽玉域芋郁吁遇喻峪御愈欲狱育誉"],["d440","訞",31,"訿",8,"詉",21],["d480","詟",25,"詺",6,"浴寓裕预豫驭鸳渊冤元垣袁原援辕园员圆猿源缘远苑愿怨院曰约越跃钥岳粤月悦阅耘云郧匀陨允运蕴酝晕韵孕匝砸杂栽哉灾宰载再在咱攒暂赞赃脏葬遭糟凿藻枣早澡蚤躁噪造皂灶燥责择则泽贼怎增憎曾赠扎喳渣札轧"],["d540","誁",7,"誋",7,"誔",46],["d580","諃",32,"铡闸眨栅榨咋乍炸诈摘斋宅窄债寨瞻毡詹粘沾盏斩辗崭展蘸栈占战站湛绽樟章彰漳张掌涨杖丈帐账仗胀瘴障招昭找沼赵照罩兆肇召遮折哲蛰辙者锗蔗这浙珍斟真甄砧臻贞针侦枕疹诊震振镇阵蒸挣睁征狰争怔整拯正政"],["d640","諤",34,"謈",27],["d680","謤謥謧",30,"帧症郑证芝枝支吱蜘知肢脂汁之织职直植殖执值侄址指止趾只旨纸志挚掷至致置帜峙制智秩稚质炙痔滞治窒中盅忠钟衷终种肿重仲众舟周州洲诌粥轴肘帚咒皱宙昼骤珠株蛛朱猪诸诛逐竹烛煮拄瞩嘱主著柱助蛀贮铸筑"],["d740","譆",31,"譧",4,"譭",25],["d780","讇",24,"讬讱讻诇诐诪谉谞住注祝驻抓爪拽专砖转撰赚篆桩庄装妆撞壮状椎锥追赘坠缀谆准捉拙卓桌琢茁酌啄着灼浊兹咨资姿滋淄孜紫仔籽滓子自渍字鬃棕踪宗综总纵邹走奏揍租足卒族祖诅阻组钻纂嘴醉最罪尊遵昨左佐柞做作坐座"],["d840","谸",8,"豂豃豄豅豈豊豋豍",7,"豖豗豘豙豛",5,"豣",6,"豬",6,"豴豵豶豷豻",6,"貃貄貆貇"],["d880","貈貋貍",6,"貕貖貗貙",20,"亍丌兀丐廿卅丕亘丞鬲孬噩丨禺丿匕乇夭爻卮氐囟胤馗毓睾鼗丶亟鼐乜乩亓芈孛啬嘏仄厍厝厣厥厮靥赝匚叵匦匮匾赜卦卣刂刈刎刭刳刿剀剌剞剡剜蒯剽劂劁劐劓冂罔亻仃仉仂仨仡仫仞伛仳伢佤仵伥伧伉伫佞佧攸佚佝"],["d940","貮",62],["d980","賭",32,"佟佗伲伽佶佴侑侉侃侏佾佻侪佼侬侔俦俨俪俅俚俣俜俑俟俸倩偌俳倬倏倮倭俾倜倌倥倨偾偃偕偈偎偬偻傥傧傩傺僖儆僭僬僦僮儇儋仝氽佘佥俎龠汆籴兮巽黉馘冁夔勹匍訇匐凫夙兕亠兖亳衮袤亵脔裒禀嬴蠃羸冫冱冽冼"],["da40","贎",14,"贠赑赒赗赟赥赨赩赪赬赮赯赱赲赸",8,"趂趃趆趇趈趉趌",4,"趒趓趕",9,"趠趡"],["da80","趢趤",12,"趲趶趷趹趻趽跀跁跂跅跇跈跉跊跍跐跒跓跔凇冖冢冥讠讦讧讪讴讵讷诂诃诋诏诎诒诓诔诖诘诙诜诟诠诤诨诩诮诰诳诶诹诼诿谀谂谄谇谌谏谑谒谔谕谖谙谛谘谝谟谠谡谥谧谪谫谮谯谲谳谵谶卩卺阝阢阡阱阪阽阼陂陉陔陟陧陬陲陴隈隍隗隰邗邛邝邙邬邡邴邳邶邺"],["db40","跕跘跙跜跠跡跢跥跦跧跩跭跮跰跱跲跴跶跼跾",6,"踆踇踈踋踍踎踐踑踒踓踕",7,"踠踡踤",4,"踫踭踰踲踳踴踶踷踸踻踼踾"],["db80","踿蹃蹅蹆蹌",4,"蹓",5,"蹚",11,"蹧蹨蹪蹫蹮蹱邸邰郏郅邾郐郄郇郓郦郢郜郗郛郫郯郾鄄鄢鄞鄣鄱鄯鄹酃酆刍奂劢劬劭劾哿勐勖勰叟燮矍廴凵凼鬯厶弁畚巯坌垩垡塾墼壅壑圩圬圪圳圹圮圯坜圻坂坩垅坫垆坼坻坨坭坶坳垭垤垌垲埏垧垴垓垠埕埘埚埙埒垸埴埯埸埤埝"],["dc40","蹳蹵蹷",4,"蹽蹾躀躂躃躄躆躈",6,"躑躒躓躕",6,"躝躟",11,"躭躮躰躱躳",6,"躻",7],["dc80","軃",10,"軏",21,"堋堍埽埭堀堞堙塄堠塥塬墁墉墚墀馨鼙懿艹艽艿芏芊芨芄芎芑芗芙芫芸芾芰苈苊苣芘芷芮苋苌苁芩芴芡芪芟苄苎芤苡茉苷苤茏茇苜苴苒苘茌苻苓茑茚茆茔茕苠苕茜荑荛荜茈莒茼茴茱莛荞茯荏荇荃荟荀茗荠茭茺茳荦荥"],["dd40","軥",62],["dd80","輤",32,"荨茛荩荬荪荭荮莰荸莳莴莠莪莓莜莅荼莶莩荽莸荻莘莞莨莺莼菁萁菥菘堇萘萋菝菽菖萜萸萑萆菔菟萏萃菸菹菪菅菀萦菰菡葜葑葚葙葳蒇蒈葺蒉葸萼葆葩葶蒌蒎萱葭蓁蓍蓐蓦蒽蓓蓊蒿蒺蓠蒡蒹蒴蒗蓥蓣蔌甍蔸蓰蔹蔟蔺"],["de40","轅",32,"轪辀辌辒辝辠辡辢辤辥辦辧辪辬辭辮辯農辳辴辵辷辸辺辻込辿迀迃迆"],["de80","迉",4,"迏迒迖迗迚迠迡迣迧迬迯迱迲迴迵迶迺迻迼迾迿逇逈逌逎逓逕逘蕖蔻蓿蓼蕙蕈蕨蕤蕞蕺瞢蕃蕲蕻薤薨薇薏蕹薮薜薅薹薷薰藓藁藜藿蘧蘅蘩蘖蘼廾弈夼奁耷奕奚奘匏尢尥尬尴扌扪抟抻拊拚拗拮挢拶挹捋捃掭揶捱捺掎掴捭掬掊捩掮掼揲揸揠揿揄揞揎摒揆掾摅摁搋搛搠搌搦搡摞撄摭撖"],["df40","這逜連逤逥逧",5,"逰",4,"逷逹逺逽逿遀遃遅遆遈",4,"過達違遖遙遚遜",5,"遤遦遧適遪遫遬遯",4,"遶",6,"遾邁"],["df80","還邅邆邇邉邊邌",4,"邒邔邖邘邚邜邞邟邠邤邥邧邨邩邫邭邲邷邼邽邿郀摺撷撸撙撺擀擐擗擤擢攉攥攮弋忒甙弑卟叱叽叩叨叻吒吖吆呋呒呓呔呖呃吡呗呙吣吲咂咔呷呱呤咚咛咄呶呦咝哐咭哂咴哒咧咦哓哔呲咣哕咻咿哌哙哚哜咩咪咤哝哏哞唛哧唠哽唔哳唢唣唏唑唧唪啧喏喵啉啭啁啕唿啐唼"],["e040","郂郃郆郈郉郋郌郍郒郔郕郖郘郙郚郞郟郠郣郤郥郩郪郬郮郰郱郲郳郵郶郷郹郺郻郼郿鄀鄁鄃鄅",19,"鄚鄛鄜"],["e080","鄝鄟鄠鄡鄤",10,"鄰鄲",6,"鄺",8,"酄唷啖啵啶啷唳唰啜喋嗒喃喱喹喈喁喟啾嗖喑啻嗟喽喾喔喙嗪嗷嗉嘟嗑嗫嗬嗔嗦嗝嗄嗯嗥嗲嗳嗌嗍嗨嗵嗤辔嘞嘈嘌嘁嘤嘣嗾嘀嘧嘭噘嘹噗嘬噍噢噙噜噌噔嚆噤噱噫噻噼嚅嚓嚯囔囗囝囡囵囫囹囿圄圊圉圜帏帙帔帑帱帻帼"],["e140","酅酇酈酑酓酔酕酖酘酙酛酜酟酠酦酧酨酫酭酳酺酻酼醀",4,"醆醈醊醎醏醓",6,"醜",5,"醤",5,"醫醬醰醱醲醳醶醷醸醹醻"],["e180","醼",10,"釈釋釐釒",9,"針",8,"帷幄幔幛幞幡岌屺岍岐岖岈岘岙岑岚岜岵岢岽岬岫岱岣峁岷峄峒峤峋峥崂崃崧崦崮崤崞崆崛嵘崾崴崽嵬嵛嵯嵝嵫嵋嵊嵩嵴嶂嶙嶝豳嶷巅彳彷徂徇徉後徕徙徜徨徭徵徼衢彡犭犰犴犷犸狃狁狎狍狒狨狯狩狲狴狷猁狳猃狺"],["e240","釦",62],["e280","鈥",32,"狻猗猓猡猊猞猝猕猢猹猥猬猸猱獐獍獗獠獬獯獾舛夥飧夤夂饣饧",5,"饴饷饽馀馄馇馊馍馐馑馓馔馕庀庑庋庖庥庠庹庵庾庳赓廒廑廛廨廪膺忄忉忖忏怃忮怄忡忤忾怅怆忪忭忸怙怵怦怛怏怍怩怫怊怿怡恸恹恻恺恂"],["e340","鉆",45,"鉵",16],["e380","銆",7,"銏",24,"恪恽悖悚悭悝悃悒悌悛惬悻悱惝惘惆惚悴愠愦愕愣惴愀愎愫慊慵憬憔憧憷懔懵忝隳闩闫闱闳闵闶闼闾阃阄阆阈阊阋阌阍阏阒阕阖阗阙阚丬爿戕氵汔汜汊沣沅沐沔沌汨汩汴汶沆沩泐泔沭泷泸泱泗沲泠泖泺泫泮沱泓泯泾"],["e440","銨",5,"銯",24,"鋉",31],["e480","鋩",32,"洹洧洌浃浈洇洄洙洎洫浍洮洵洚浏浒浔洳涑浯涞涠浞涓涔浜浠浼浣渚淇淅淞渎涿淠渑淦淝淙渖涫渌涮渫湮湎湫溲湟溆湓湔渲渥湄滟溱溘滠漭滢溥溧溽溻溷滗溴滏溏滂溟潢潆潇漤漕滹漯漶潋潴漪漉漩澉澍澌潸潲潼潺濑"],["e540","錊",51,"錿",10],["e580","鍊",31,"鍫濉澧澹澶濂濡濮濞濠濯瀚瀣瀛瀹瀵灏灞宀宄宕宓宥宸甯骞搴寤寮褰寰蹇謇辶迓迕迥迮迤迩迦迳迨逅逄逋逦逑逍逖逡逵逶逭逯遄遑遒遐遨遘遢遛暹遴遽邂邈邃邋彐彗彖彘尻咫屐屙孱屣屦羼弪弩弭艴弼鬻屮妁妃妍妩妪妣"],["e640","鍬",34,"鎐",27],["e680","鎬",29,"鏋鏌鏍妗姊妫妞妤姒妲妯姗妾娅娆姝娈姣姘姹娌娉娲娴娑娣娓婀婧婊婕娼婢婵胬媪媛婷婺媾嫫媲嫒嫔媸嫠嫣嫱嫖嫦嫘嫜嬉嬗嬖嬲嬷孀尕尜孚孥孳孑孓孢驵驷驸驺驿驽骀骁骅骈骊骐骒骓骖骘骛骜骝骟骠骢骣骥骧纟纡纣纥纨纩"],["e740","鏎",7,"鏗",54],["e780","鐎",32,"纭纰纾绀绁绂绉绋绌绐绔绗绛绠绡绨绫绮绯绱绲缍绶绺绻绾缁缂缃缇缈缋缌缏缑缒缗缙缜缛缟缡",6,"缪缫缬缭缯",4,"缵幺畿巛甾邕玎玑玮玢玟珏珂珑玷玳珀珉珈珥珙顼琊珩珧珞玺珲琏琪瑛琦琥琨琰琮琬"],["e840","鐯",14,"鐿",43,"鑬鑭鑮鑯"],["e880","鑰",20,"钑钖钘铇铏铓铔铚铦铻锜锠琛琚瑁瑜瑗瑕瑙瑷瑭瑾璜璎璀璁璇璋璞璨璩璐璧瓒璺韪韫韬杌杓杞杈杩枥枇杪杳枘枧杵枨枞枭枋杷杼柰栉柘栊柩枰栌柙枵柚枳柝栀柃枸柢栎柁柽栲栳桠桡桎桢桄桤梃栝桕桦桁桧桀栾桊桉栩梵梏桴桷梓桫棂楮棼椟椠棹"],["e940","锧锳锽镃镈镋镕镚镠镮镴镵長",7,"門",42],["e980","閫",32,"椤棰椋椁楗棣椐楱椹楠楂楝榄楫榀榘楸椴槌榇榈槎榉楦楣楹榛榧榻榫榭槔榱槁槊槟榕槠榍槿樯槭樗樘橥槲橄樾檠橐橛樵檎橹樽樨橘橼檑檐檩檗檫猷獒殁殂殇殄殒殓殍殚殛殡殪轫轭轱轲轳轵轶轸轷轹轺轼轾辁辂辄辇辋"],["ea40","闌",27,"闬闿阇阓阘阛阞阠阣",6,"阫阬阭阯阰阷阸阹阺阾陁陃陊陎陏陑陒陓陖陗"],["ea80","陘陙陚陜陝陞陠陣陥陦陫陭",4,"陳陸",12,"隇隉隊辍辎辏辘辚軎戋戗戛戟戢戡戥戤戬臧瓯瓴瓿甏甑甓攴旮旯旰昊昙杲昃昕昀炅曷昝昴昱昶昵耆晟晔晁晏晖晡晗晷暄暌暧暝暾曛曜曦曩贲贳贶贻贽赀赅赆赈赉赇赍赕赙觇觊觋觌觎觏觐觑牮犟牝牦牯牾牿犄犋犍犏犒挈挲掰"],["eb40","隌階隑隒隓隕隖隚際隝",9,"隨",7,"隱隲隴隵隷隸隺隻隿雂雃雈雊雋雐雑雓雔雖",9,"雡",6,"雫"],["eb80","雬雭雮雰雱雲雴雵雸雺電雼雽雿霂霃霅霊霋霌霐霑霒霔霕霗",4,"霝霟霠搿擘耄毪毳毽毵毹氅氇氆氍氕氘氙氚氡氩氤氪氲攵敕敫牍牒牖爰虢刖肟肜肓肼朊肽肱肫肭肴肷胧胨胩胪胛胂胄胙胍胗朐胝胫胱胴胭脍脎胲胼朕脒豚脶脞脬脘脲腈腌腓腴腙腚腱腠腩腼腽腭腧塍媵膈膂膑滕膣膪臌朦臊膻"],["ec40","霡",8,"霫霬霮霯霱霳",4,"霺霻霼霽霿",18,"靔靕靗靘靚靜靝靟靣靤靦靧靨靪",7],["ec80","靲靵靷",4,"靽",7,"鞆",4,"鞌鞎鞏鞐鞓鞕鞖鞗鞙",4,"臁膦欤欷欹歃歆歙飑飒飓飕飙飚殳彀毂觳斐齑斓於旆旄旃旌旎旒旖炀炜炖炝炻烀炷炫炱烨烊焐焓焖焯焱煳煜煨煅煲煊煸煺熘熳熵熨熠燠燔燧燹爝爨灬焘煦熹戾戽扃扈扉礻祀祆祉祛祜祓祚祢祗祠祯祧祺禅禊禚禧禳忑忐"],["ed40","鞞鞟鞡鞢鞤",6,"鞬鞮鞰鞱鞳鞵",46],["ed80","韤韥韨韮",4,"韴韷",23,"怼恝恚恧恁恙恣悫愆愍慝憩憝懋懑戆肀聿沓泶淼矶矸砀砉砗砘砑斫砭砜砝砹砺砻砟砼砥砬砣砩硎硭硖硗砦硐硇硌硪碛碓碚碇碜碡碣碲碹碥磔磙磉磬磲礅磴礓礤礞礴龛黹黻黼盱眄眍盹眇眈眚眢眙眭眦眵眸睐睑睇睃睚睨"],["ee40","頏",62],["ee80","顎",32,"睢睥睿瞍睽瞀瞌瞑瞟瞠瞰瞵瞽町畀畎畋畈畛畲畹疃罘罡罟詈罨罴罱罹羁罾盍盥蠲钅钆钇钋钊钌钍钏钐钔钗钕钚钛钜钣钤钫钪钭钬钯钰钲钴钶",4,"钼钽钿铄铈",6,"铐铑铒铕铖铗铙铘铛铞铟铠铢铤铥铧铨铪"],["ef40","顯",5,"颋颎颒颕颙颣風",37,"飏飐飔飖飗飛飜飝飠",4],["ef80","飥飦飩",30,"铩铫铮铯铳铴铵铷铹铼铽铿锃锂锆锇锉锊锍锎锏锒",4,"锘锛锝锞锟锢锪锫锩锬锱锲锴锶锷锸锼锾锿镂锵镄镅镆镉镌镎镏镒镓镔镖镗镘镙镛镞镟镝镡镢镤",8,"镯镱镲镳锺矧矬雉秕秭秣秫稆嵇稃稂稞稔"],["f040","餈",4,"餎餏餑",28,"餯",26],["f080","饊",9,"饖",12,"饤饦饳饸饹饻饾馂馃馉稹稷穑黏馥穰皈皎皓皙皤瓞瓠甬鸠鸢鸨",4,"鸲鸱鸶鸸鸷鸹鸺鸾鹁鹂鹄鹆鹇鹈鹉鹋鹌鹎鹑鹕鹗鹚鹛鹜鹞鹣鹦",6,"鹱鹭鹳疒疔疖疠疝疬疣疳疴疸痄疱疰痃痂痖痍痣痨痦痤痫痧瘃痱痼痿瘐瘀瘅瘌瘗瘊瘥瘘瘕瘙"],["f140","馌馎馚",10,"馦馧馩",47],["f180","駙",32,"瘛瘼瘢瘠癀瘭瘰瘿瘵癃瘾瘳癍癞癔癜癖癫癯翊竦穸穹窀窆窈窕窦窠窬窨窭窳衤衩衲衽衿袂袢裆袷袼裉裢裎裣裥裱褚裼裨裾裰褡褙褓褛褊褴褫褶襁襦襻疋胥皲皴矜耒耔耖耜耠耢耥耦耧耩耨耱耋耵聃聆聍聒聩聱覃顸颀颃"],["f240","駺",62],["f280","騹",32,"颉颌颍颏颔颚颛颞颟颡颢颥颦虍虔虬虮虿虺虼虻蚨蚍蚋蚬蚝蚧蚣蚪蚓蚩蚶蛄蚵蛎蚰蚺蚱蚯蛉蛏蚴蛩蛱蛲蛭蛳蛐蜓蛞蛴蛟蛘蛑蜃蜇蛸蜈蜊蜍蜉蜣蜻蜞蜥蜮蜚蜾蝈蜴蜱蜩蜷蜿螂蜢蝽蝾蝻蝠蝰蝌蝮螋蝓蝣蝼蝤蝙蝥螓螯螨蟒"],["f340","驚",17,"驲骃骉骍骎骔骕骙骦骩",6,"骲骳骴骵骹骻骽骾骿髃髄髆",4,"髍髎髏髐髒體髕髖髗髙髚髛髜"],["f380","髝髞髠髢髣髤髥髧髨髩髪髬髮髰",8,"髺髼",6,"鬄鬅鬆蟆螈螅螭螗螃螫蟥螬螵螳蟋蟓螽蟑蟀蟊蟛蟪蟠蟮蠖蠓蟾蠊蠛蠡蠹蠼缶罂罄罅舐竺竽笈笃笄笕笊笫笏筇笸笪笙笮笱笠笥笤笳笾笞筘筚筅筵筌筝筠筮筻筢筲筱箐箦箧箸箬箝箨箅箪箜箢箫箴篑篁篌篝篚篥篦篪簌篾篼簏簖簋"],["f440","鬇鬉",5,"鬐鬑鬒鬔",10,"鬠鬡鬢鬤",10,"鬰鬱鬳",7,"鬽鬾鬿魀魆魊魋魌魎魐魒魓魕",5],["f480","魛",32,"簟簪簦簸籁籀臾舁舂舄臬衄舡舢舣舭舯舨舫舸舻舳舴舾艄艉艋艏艚艟艨衾袅袈裘裟襞羝羟羧羯羰羲籼敉粑粝粜粞粢粲粼粽糁糇糌糍糈糅糗糨艮暨羿翎翕翥翡翦翩翮翳糸絷綦綮繇纛麸麴赳趄趔趑趱赧赭豇豉酊酐酎酏酤"],["f540","魼",62],["f580","鮻",32,"酢酡酰酩酯酽酾酲酴酹醌醅醐醍醑醢醣醪醭醮醯醵醴醺豕鹾趸跫踅蹙蹩趵趿趼趺跄跖跗跚跞跎跏跛跆跬跷跸跣跹跻跤踉跽踔踝踟踬踮踣踯踺蹀踹踵踽踱蹉蹁蹂蹑蹒蹊蹰蹶蹼蹯蹴躅躏躔躐躜躞豸貂貊貅貘貔斛觖觞觚觜"],["f640","鯜",62],["f680","鰛",32,"觥觫觯訾謦靓雩雳雯霆霁霈霏霎霪霭霰霾龀龃龅",5,"龌黾鼋鼍隹隼隽雎雒瞿雠銎銮鋈錾鍪鏊鎏鐾鑫鱿鲂鲅鲆鲇鲈稣鲋鲎鲐鲑鲒鲔鲕鲚鲛鲞",5,"鲥",4,"鲫鲭鲮鲰",7,"鲺鲻鲼鲽鳄鳅鳆鳇鳊鳋"],["f740","鰼",62],["f780","鱻鱽鱾鲀鲃鲄鲉鲊鲌鲏鲓鲖鲗鲘鲙鲝鲪鲬鲯鲹鲾",4,"鳈鳉鳑鳒鳚鳛鳠鳡鳌",4,"鳓鳔鳕鳗鳘鳙鳜鳝鳟鳢靼鞅鞑鞒鞔鞯鞫鞣鞲鞴骱骰骷鹘骶骺骼髁髀髅髂髋髌髑魅魃魇魉魈魍魑飨餍餮饕饔髟髡髦髯髫髻髭髹鬈鬏鬓鬟鬣麽麾縻麂麇麈麋麒鏖麝麟黛黜黝黠黟黢黩黧黥黪黯鼢鼬鼯鼹鼷鼽鼾齄"],["f840","鳣",62],["f880","鴢",32],["f940","鵃",62],["f980","鶂",32],["fa40","鶣",62],["fa80","鷢",32],["fb40","鸃",27,"鸤鸧鸮鸰鸴鸻鸼鹀鹍鹐鹒鹓鹔鹖鹙鹝鹟鹠鹡鹢鹥鹮鹯鹲鹴",9,"麀"],["fb80","麁麃麄麅麆麉麊麌",5,"麔",8,"麞麠",5,"麧麨麩麪"],["fc40","麫",8,"麵麶麷麹麺麼麿",4,"黅黆黇黈黊黋黌黐黒黓黕黖黗黙黚點黡黣黤黦黨黫黬黭黮黰",8,"黺黽黿",6],["fc80","鼆",4,"鼌鼏鼑鼒鼔鼕鼖鼘鼚",5,"鼡鼣",8,"鼭鼮鼰鼱"],["fd40","鼲",4,"鼸鼺鼼鼿",4,"齅",10,"齒",38],["fd80","齹",5,"龁龂龍",11,"龜龝龞龡",4,"郎凉秊裏隣"],["fe40","兀嗀﨎﨏﨑﨓﨔礼﨟蘒﨡﨣﨤﨧﨨﨩"]],require$$3=[["a140","",62],["a180","",32],["a240","",62],["a280","",32],["a2ab","",5],["a2e3","€"],["a2ef",""],["a2fd",""],["a340","",62],["a380","",31," "],["a440","",62],["a480","",32],["a4f4","",10],["a540","",62],["a580","",32],["a5f7","",7],["a640","",62],["a680","",32],["a6b9","",7],["a6d9","",6],["a6ec",""],["a6f3",""],["a6f6","",8],["a740","",62],["a780","",32],["a7c2","",14],["a7f2","",12],["a896","",10],["a8bc","ḿ"],["a8bf","ǹ"],["a8c1",""],["a8ea","",20],["a958",""],["a95b",""],["a95d",""],["a989","〾⿰",11],["a997","",12],["a9f0","",14],["aaa1","",93],["aba1","",93],["aca1","",93],["ada1","",93],["aea1","",93],["afa1","",93],["d7fa","",4],["f8a1","",93],["f9a1","",93],["faa1","",93],["fba1","",93],["fca1","",93],["fda1","",93],["fe50","⺁⺄㑳㑇⺈⺋㖞㘚㘎⺌⺗㥮㤘㧏㧟㩳㧐㭎㱮㳠⺧⺪䁖䅟⺮䌷⺳⺶⺷䎱䎬⺻䏝䓖䙡䙌"],["fe80","䜣䜩䝼䞍⻊䥇䥺䥽䦂䦃䦅䦆䦟䦛䦷䦶䲣䲟䲠䲡䱷䲢䴓",6,"䶮",93],["8135f437",""]],uChars=[128,165,169,178,184,216,226,235,238,244,248,251,253,258,276,284,300,325,329,334,364,463,465,467,469,471,473,475,477,506,594,610,712,716,730,930,938,962,970,1026,1104,1106,8209,8215,8218,8222,8231,8241,8244,8246,8252,8365,8452,8454,8458,8471,8482,8556,8570,8596,8602,8713,8720,8722,8726,8731,8737,8740,8742,8748,8751,8760,8766,8777,8781,8787,8802,8808,8816,8854,8858,8870,8896,8979,9322,9372,9548,9588,9616,9622,9634,9652,9662,9672,9676,9680,9702,9735,9738,9793,9795,11906,11909,11913,11917,11928,11944,11947,11951,11956,11960,11964,11979,12284,12292,12312,12319,12330,12351,12436,12447,12535,12543,12586,12842,12850,12964,13200,13215,13218,13253,13263,13267,13270,13384,13428,13727,13839,13851,14617,14703,14801,14816,14964,15183,15471,15585,16471,16736,17208,17325,17330,17374,17623,17997,18018,18212,18218,18301,18318,18760,18811,18814,18820,18823,18844,18848,18872,19576,19620,19738,19887,40870,59244,59336,59367,59413,59417,59423,59431,59437,59443,59452,59460,59478,59493,63789,63866,63894,63976,63986,64016,64018,64021,64025,64034,64037,64042,65074,65093,65107,65112,65127,65132,65375,65510,65536],gbChars=[0,36,38,45,50,81,89,95,96,100,103,104,105,109,126,133,148,172,175,179,208,306,307,308,309,310,311,312,313,341,428,443,544,545,558,741,742,749,750,805,819,820,7922,7924,7925,7927,7934,7943,7944,7945,7950,8062,8148,8149,8152,8164,8174,8236,8240,8262,8264,8374,8380,8381,8384,8388,8390,8392,8393,8394,8396,8401,8406,8416,8419,8424,8437,8439,8445,8482,8485,8496,8521,8603,8936,8946,9046,9050,9063,9066,9076,9092,9100,9108,9111,9113,9131,9162,9164,9218,9219,11329,11331,11334,11336,11346,11361,11363,11366,11370,11372,11375,11389,11682,11686,11687,11692,11694,11714,11716,11723,11725,11730,11736,11982,11989,12102,12336,12348,12350,12384,12393,12395,12397,12510,12553,12851,12962,12973,13738,13823,13919,13933,14080,14298,14585,14698,15583,15847,16318,16434,16438,16481,16729,17102,17122,17315,17320,17402,17418,17859,17909,17911,17915,17916,17936,17939,17961,18664,18703,18814,18962,19043,33469,33470,33471,33484,33485,33490,33497,33501,33505,33513,33520,33536,33550,37845,37921,37948,38029,38038,38064,38065,38066,38069,38075,38076,38078,39108,39109,39113,39114,39115,39116,39265,39394,189e3],require$$4$1={uChars,gbChars},require$$5=[["0","\0",127],["8141","갂갃갅갆갋",4,"갘갞갟갡갢갣갥",6,"갮갲갳갴"],["8161","갵갶갷갺갻갽갾갿걁",9,"걌걎",5,"걕"],["8181","걖걗걙걚걛걝",18,"걲걳걵걶걹걻",4,"겂겇겈겍겎겏겑겒겓겕",6,"겞겢",5,"겫겭겮겱",6,"겺겾겿곀곂곃곅곆곇곉곊곋곍",7,"곖곘",7,"곢곣곥곦곩곫곭곮곲곴곷",4,"곾곿괁괂괃괅괇",4,"괎괐괒괓"],["8241","괔괕괖괗괙괚괛괝괞괟괡",7,"괪괫괮",5],["8261","괶괷괹괺괻괽",6,"굆굈굊",5,"굑굒굓굕굖굗"],["8281","굙",7,"굢굤",7,"굮굯굱굲굷굸굹굺굾궀궃",4,"궊궋궍궎궏궑",10,"궞",5,"궥",17,"궸",7,"귂귃귅귆귇귉",6,"귒귔",7,"귝귞귟귡귢귣귥",18],["8341","귺귻귽귾긂",5,"긊긌긎",5,"긕",7],["8361","긝",18,"긲긳긵긶긹긻긼"],["8381","긽긾긿깂깄깇깈깉깋깏깑깒깓깕깗",4,"깞깢깣깤깦깧깪깫깭깮깯깱",6,"깺깾",5,"꺆",5,"꺍",46,"꺿껁껂껃껅",6,"껎껒",5,"껚껛껝",8],["8441","껦껧껩껪껬껮",5,"껵껶껷껹껺껻껽",8],["8461","꼆꼉꼊꼋꼌꼎꼏꼑",18],["8481","꼤",7,"꼮꼯꼱꼳꼵",6,"꼾꽀꽄꽅꽆꽇꽊",5,"꽑",10,"꽞",5,"꽦",18,"꽺",5,"꾁꾂꾃꾅꾆꾇꾉",6,"꾒꾓꾔꾖",5,"꾝",26,"꾺꾻꾽꾾"],["8541","꾿꿁",5,"꿊꿌꿏",4,"꿕",6,"꿝",4],["8561","꿢",5,"꿪",5,"꿲꿳꿵꿶꿷꿹",6,"뀂뀃"],["8581","뀅",6,"뀍뀎뀏뀑뀒뀓뀕",6,"뀞",9,"뀩",26,"끆끇끉끋끍끏끐끑끒끖끘끚끛끜끞",29,"끾끿낁낂낃낅",6,"낎낐낒",5,"낛낝낞낣낤"],["8641","낥낦낧낪낰낲낶낷낹낺낻낽",6,"냆냊",5,"냒"],["8661","냓냕냖냗냙",6,"냡냢냣냤냦",10],["8681","냱",22,"넊넍넎넏넑넔넕넖넗넚넞",4,"넦넧넩넪넫넭",6,"넶넺",5,"녂녃녅녆녇녉",6,"녒녓녖녗녙녚녛녝녞녟녡",22,"녺녻녽녾녿놁놃",4,"놊놌놎놏놐놑놕놖놗놙놚놛놝"],["8741","놞",9,"놩",15],["8761","놹",18,"뇍뇎뇏뇑뇒뇓뇕"],["8781","뇖",5,"뇞뇠",7,"뇪뇫뇭뇮뇯뇱",7,"뇺뇼뇾",5,"눆눇눉눊눍",6,"눖눘눚",5,"눡",18,"눵",6,"눽",26,"뉙뉚뉛뉝뉞뉟뉡",6,"뉪",4],["8841","뉯",4,"뉶",5,"뉽",6,"늆늇늈늊",4],["8861","늏늒늓늕늖늗늛",4,"늢늤늧늨늩늫늭늮늯늱늲늳늵늶늷"],["8881","늸",15,"닊닋닍닎닏닑닓",4,"닚닜닞닟닠닡닣닧닩닪닰닱닲닶닼닽닾댂댃댅댆댇댉",6,"댒댖",5,"댝",54,"덗덙덚덝덠덡덢덣"],["8941","덦덨덪덬덭덯덲덳덵덶덷덹",6,"뎂뎆",5,"뎍"],["8961","뎎뎏뎑뎒뎓뎕",10,"뎢",5,"뎩뎪뎫뎭"],["8981","뎮",21,"돆돇돉돊돍돏돑돒돓돖돘돚돜돞돟돡돢돣돥돦돧돩",18,"돽",18,"됑",6,"됙됚됛됝됞됟됡",6,"됪됬",7,"됵",15],["8a41","둅",10,"둒둓둕둖둗둙",6,"둢둤둦"],["8a61","둧",4,"둭",18,"뒁뒂"],["8a81","뒃",4,"뒉",19,"뒞",5,"뒥뒦뒧뒩뒪뒫뒭",7,"뒶뒸뒺",5,"듁듂듃듅듆듇듉",6,"듑듒듓듔듖",5,"듞듟듡듢듥듧",4,"듮듰듲",5,"듹",26,"딖딗딙딚딝"],["8b41","딞",5,"딦딫",4,"딲딳딵딶딷딹",6,"땂땆"],["8b61","땇땈땉땊땎땏땑땒땓땕",6,"땞땢",8],["8b81","땫",52,"떢떣떥떦떧떩떬떭떮떯떲떶",4,"떾떿뗁뗂뗃뗅",6,"뗎뗒",5,"뗙",18,"뗭",18],["8c41","똀",15,"똒똓똕똖똗똙",4],["8c61","똞",6,"똦",5,"똭",6,"똵",5],["8c81","똻",12,"뙉",26,"뙥뙦뙧뙩",50,"뚞뚟뚡뚢뚣뚥",5,"뚭뚮뚯뚰뚲",16],["8d41","뛃",16,"뛕",8],["8d61","뛞",17,"뛱뛲뛳뛵뛶뛷뛹뛺"],["8d81","뛻",4,"뜂뜃뜄뜆",33,"뜪뜫뜭뜮뜱",6,"뜺뜼",7,"띅띆띇띉띊띋띍",6,"띖",9,"띡띢띣띥띦띧띩",6,"띲띴띶",5,"띾띿랁랂랃랅",6,"랎랓랔랕랚랛랝랞"],["8e41","랟랡",6,"랪랮",5,"랶랷랹",8],["8e61","럂",4,"럈럊",19],["8e81","럞",13,"럮럯럱럲럳럵",6,"럾렂",4,"렊렋렍렎렏렑",6,"렚렜렞",5,"렦렧렩렪렫렭",6,"렶렺",5,"롁롂롃롅",11,"롒롔",7,"롞롟롡롢롣롥",6,"롮롰롲",5,"롹롺롻롽",7],["8f41","뢅",7,"뢎",17],["8f61","뢠",7,"뢩",6,"뢱뢲뢳뢵뢶뢷뢹",4],["8f81","뢾뢿룂룄룆",5,"룍룎룏룑룒룓룕",7,"룞룠룢",5,"룪룫룭룮룯룱",6,"룺룼룾",5,"뤅",18,"뤙",6,"뤡",26,"뤾뤿륁륂륃륅",6,"륍륎륐륒",5],["9041","륚륛륝륞륟륡",6,"륪륬륮",5,"륶륷륹륺륻륽"],["9061","륾",5,"릆릈릋릌릏",15],["9081","릟",12,"릮릯릱릲릳릵",6,"릾맀맂",5,"맊맋맍맓",4,"맚맜맟맠맢맦맧맩맪맫맭",6,"맶맻",4,"먂",5,"먉",11,"먖",33,"먺먻먽먾먿멁멃멄멅멆"],["9141","멇멊멌멏멐멑멒멖멗멙멚멛멝",6,"멦멪",5],["9161","멲멳멵멶멷멹",9,"몆몈몉몊몋몍",5],["9181","몓",20,"몪몭몮몯몱몳",4,"몺몼몾",5,"뫅뫆뫇뫉",14,"뫚",33,"뫽뫾뫿묁묂묃묅",7,"묎묐묒",5,"묙묚묛묝묞묟묡",6],["9241","묨묪묬",7,"묷묹묺묿",4,"뭆뭈뭊뭋뭌뭎뭑뭒"],["9261","뭓뭕뭖뭗뭙",7,"뭢뭤",7,"뭭",4],["9281","뭲",21,"뮉뮊뮋뮍뮎뮏뮑",18,"뮥뮦뮧뮩뮪뮫뮭",6,"뮵뮶뮸",7,"믁믂믃믅믆믇믉",6,"믑믒믔",35,"믺믻믽믾밁"],["9341","밃",4,"밊밎밐밒밓밙밚밠밡밢밣밦밨밪밫밬밮밯밲밳밵"],["9361","밶밷밹",6,"뱂뱆뱇뱈뱊뱋뱎뱏뱑",8],["9381","뱚뱛뱜뱞",37,"벆벇벉벊벍벏",4,"벖벘벛",4,"벢벣벥벦벩",6,"벲벶",5,"벾벿볁볂볃볅",7,"볎볒볓볔볖볗볙볚볛볝",22,"볷볹볺볻볽"],["9441","볾",5,"봆봈봊",5,"봑봒봓봕",8],["9461","봞",5,"봥",6,"봭",12],["9481","봺",5,"뵁",6,"뵊뵋뵍뵎뵏뵑",6,"뵚",9,"뵥뵦뵧뵩",22,"붂붃붅붆붋",4,"붒붔붖붗붘붛붝",6,"붥",10,"붱",6,"붹",24],["9541","뷒뷓뷖뷗뷙뷚뷛뷝",11,"뷪",5,"뷱"],["9561","뷲뷳뷵뷶뷷뷹",6,"븁븂븄븆",5,"븎븏븑븒븓"],["9581","븕",6,"븞븠",35,"빆빇빉빊빋빍빏",4,"빖빘빜빝빞빟빢빣빥빦빧빩빫",4,"빲빶",4,"빾빿뺁뺂뺃뺅",6,"뺎뺒",5,"뺚",13,"뺩",14],["9641","뺸",23,"뻒뻓"],["9661","뻕뻖뻙",6,"뻡뻢뻦",5,"뻭",8],["9681","뻶",10,"뼂",5,"뼊",13,"뼚뼞",33,"뽂뽃뽅뽆뽇뽉",6,"뽒뽓뽔뽖",44],["9741","뾃",16,"뾕",8],["9761","뾞",17,"뾱",7],["9781","뾹",11,"뿆",5,"뿎뿏뿑뿒뿓뿕",6,"뿝뿞뿠뿢",89,"쀽쀾쀿"],["9841","쁀",16,"쁒",5,"쁙쁚쁛"],["9861","쁝쁞쁟쁡",6,"쁪",15],["9881","쁺",21,"삒삓삕삖삗삙",6,"삢삤삦",5,"삮삱삲삷",4,"삾샂샃샄샆샇샊샋샍샎샏샑",6,"샚샞",5,"샦샧샩샪샫샭",6,"샶샸샺",5,"섁섂섃섅섆섇섉",6,"섑섒섓섔섖",5,"섡섢섥섨섩섪섫섮"],["9941","섲섳섴섵섷섺섻섽섾섿셁",6,"셊셎",5,"셖셗"],["9961","셙셚셛셝",6,"셦셪",5,"셱셲셳셵셶셷셹셺셻"],["9981","셼",8,"솆",5,"솏솑솒솓솕솗",4,"솞솠솢솣솤솦솧솪솫솭솮솯솱",11,"솾",5,"쇅쇆쇇쇉쇊쇋쇍",6,"쇕쇖쇙",6,"쇡쇢쇣쇥쇦쇧쇩",6,"쇲쇴",7,"쇾쇿숁숂숃숅",6,"숎숐숒",5,"숚숛숝숞숡숢숣"],["9a41","숤숥숦숧숪숬숮숰숳숵",16],["9a61","쉆쉇쉉",6,"쉒쉓쉕쉖쉗쉙",6,"쉡쉢쉣쉤쉦"],["9a81","쉧",4,"쉮쉯쉱쉲쉳쉵",6,"쉾슀슂",5,"슊",5,"슑",6,"슙슚슜슞",5,"슦슧슩슪슫슮",5,"슶슸슺",33,"싞싟싡싢싥",5,"싮싰싲싳싴싵싷싺싽싾싿쌁",6,"쌊쌋쌎쌏"],["9b41","쌐쌑쌒쌖쌗쌙쌚쌛쌝",6,"쌦쌧쌪",8],["9b61","쌳",17,"썆",7],["9b81","썎",25,"썪썫썭썮썯썱썳",4,"썺썻썾",5,"쎅쎆쎇쎉쎊쎋쎍",50,"쏁",22,"쏚"],["9c41","쏛쏝쏞쏡쏣",4,"쏪쏫쏬쏮",5,"쏶쏷쏹",5],["9c61","쏿",8,"쐉",6,"쐑",9],["9c81","쐛",8,"쐥",6,"쐭쐮쐯쐱쐲쐳쐵",6,"쐾",9,"쑉",26,"쑦쑧쑩쑪쑫쑭",6,"쑶쑷쑸쑺",5,"쒁",18,"쒕",6,"쒝",12],["9d41","쒪",13,"쒹쒺쒻쒽",8],["9d61","쓆",25],["9d81","쓠",8,"쓪",5,"쓲쓳쓵쓶쓷쓹쓻쓼쓽쓾씂",9,"씍씎씏씑씒씓씕",6,"씝",10,"씪씫씭씮씯씱",6,"씺씼씾",5,"앆앇앋앏앐앑앒앖앚앛앜앟앢앣앥앦앧앩",6,"앲앶",5,"앾앿얁얂얃얅얆얈얉얊얋얎얐얒얓얔"],["9e41","얖얙얚얛얝얞얟얡",7,"얪",9,"얶"],["9e61","얷얺얿",4,"엋엍엏엒엓엕엖엗엙",6,"엢엤엦엧"],["9e81","엨엩엪엫엯엱엲엳엵엸엹엺엻옂옃옄옉옊옋옍옎옏옑",6,"옚옝",6,"옦옧옩옪옫옯옱옲옶옸옺옼옽옾옿왂왃왅왆왇왉",6,"왒왖",5,"왞왟왡",10,"왭왮왰왲",5,"왺왻왽왾왿욁",6,"욊욌욎",5,"욖욗욙욚욛욝",6,"욦"],["9f41","욨욪",5,"욲욳욵욶욷욻",4,"웂웄웆",5,"웎"],["9f61","웏웑웒웓웕",6,"웞웟웢",5,"웪웫웭웮웯웱웲"],["9f81","웳",4,"웺웻웼웾",5,"윆윇윉윊윋윍",6,"윖윘윚",5,"윢윣윥윦윧윩",6,"윲윴윶윸윹윺윻윾윿읁읂읃읅",4,"읋읎읐읙읚읛읝읞읟읡",6,"읩읪읬",7,"읶읷읹읺읻읿잀잁잂잆잋잌잍잏잒잓잕잙잛",4,"잢잧",4,"잮잯잱잲잳잵잶잷"],["a041","잸잹잺잻잾쟂",5,"쟊쟋쟍쟏쟑",6,"쟙쟚쟛쟜"],["a061","쟞",5,"쟥쟦쟧쟩쟪쟫쟭",13],["a081","쟻",4,"젂젃젅젆젇젉젋",4,"젒젔젗",4,"젞젟젡젢젣젥",6,"젮젰젲",5,"젹젺젻젽젾젿졁",6,"졊졋졎",5,"졕",26,"졲졳졵졶졷졹졻",4,"좂좄좈좉좊좎",5,"좕",7,"좞좠좢좣좤"],["a141","좥좦좧좩",18,"좾좿죀죁"],["a161","죂죃죅죆죇죉죊죋죍",6,"죖죘죚",5,"죢죣죥"],["a181","죦",14,"죶",5,"죾죿줁줂줃줇",4,"줎 、。·‥…¨〃―∥\∼‘’“”〔〕〈",9,"±×÷≠≤≥∞∴°′″℃Å¢£¥♂♀∠⊥⌒∂∇≡≒§※☆★○●◎◇◆□■△▲▽▼→←↑↓↔〓≪≫√∽∝∵∫∬∈∋⊆⊇⊂⊃∪∩∧∨¬"],["a241","줐줒",5,"줙",18],["a261","줭",6,"줵",18],["a281","쥈",7,"쥒쥓쥕쥖쥗쥙",6,"쥢쥤",7,"쥭쥮쥯⇒⇔∀∃´~ˇ˘˝˚˙¸˛¡¿ː∮∑∏¤℉‰◁◀▷▶♤♠♡♥♧♣⊙◈▣◐◑▒▤▥▨▧▦▩♨☏☎☜☞¶†‡↕↗↙↖↘♭♩♪♬㉿㈜№㏇™㏂㏘℡€®"],["a341","쥱쥲쥳쥵",6,"쥽",10,"즊즋즍즎즏"],["a361","즑",6,"즚즜즞",16],["a381","즯",16,"짂짃짅짆짉짋",4,"짒짔짗짘짛!",58,"₩]",32," ̄"],["a441","짞짟짡짣짥짦짨짩짪짫짮짲",5,"짺짻짽짾짿쨁쨂쨃쨄"],["a461","쨅쨆쨇쨊쨎",5,"쨕쨖쨗쨙",12],["a481","쨦쨧쨨쨪",28,"ㄱ",93],["a541","쩇",4,"쩎쩏쩑쩒쩓쩕",6,"쩞쩢",5,"쩩쩪"],["a561","쩫",17,"쩾",5,"쪅쪆"],["a581","쪇",16,"쪙",14,"ⅰ",9],["a5b0","Ⅰ",9],["a5c1","Α",16,"Σ",6],["a5e1","α",16,"σ",6],["a641","쪨",19,"쪾쪿쫁쫂쫃쫅"],["a661","쫆",5,"쫎쫐쫒쫔쫕쫖쫗쫚",5,"쫡",6],["a681","쫨쫩쫪쫫쫭",6,"쫵",18,"쬉쬊─│┌┐┘└├┬┤┴┼━┃┏┓┛┗┣┳┫┻╋┠┯┨┷┿┝┰┥┸╂┒┑┚┙┖┕┎┍┞┟┡┢┦┧┩┪┭┮┱┲┵┶┹┺┽┾╀╁╃",7],["a741","쬋",4,"쬑쬒쬓쬕쬖쬗쬙",6,"쬢",7],["a761","쬪",22,"쭂쭃쭄"],["a781","쭅쭆쭇쭊쭋쭍쭎쭏쭑",6,"쭚쭛쭜쭞",5,"쭥",7,"㎕㎖㎗ℓ㎘㏄㎣㎤㎥㎦㎙",9,"㏊㎍㎎㎏㏏㎈㎉㏈㎧㎨㎰",9,"㎀",4,"㎺",5,"㎐",4,"Ω㏀㏁㎊㎋㎌㏖㏅㎭㎮㎯㏛㎩㎪㎫㎬㏝㏐㏓㏃㏉㏜㏆"],["a841","쭭",10,"쭺",14],["a861","쮉",18,"쮝",6],["a881","쮤",19,"쮹",11,"ÆЪĦ"],["a8a6","IJ"],["a8a8","ĿŁØŒºÞŦŊ"],["a8b1","㉠",27,"ⓐ",25,"①",14,"½⅓⅔¼¾⅛⅜⅝⅞"],["a941","쯅",14,"쯕",10],["a961","쯠쯡쯢쯣쯥쯦쯨쯪",18],["a981","쯽",14,"찎찏찑찒찓찕",6,"찞찟찠찣찤æđðħıijĸŀłøœßþŧŋʼn㈀",27,"⒜",25,"⑴",14,"¹²³⁴ⁿ₁₂₃₄"],["aa41","찥찦찪찫찭찯찱",6,"찺찿",4,"챆챇챉챊챋챍챎"],["aa61","챏",4,"챖챚",5,"챡챢챣챥챧챩",6,"챱챲"],["aa81","챳챴챶",29,"ぁ",82],["ab41","첔첕첖첗첚첛첝첞첟첡",6,"첪첮",5,"첶첷첹"],["ab61","첺첻첽",6,"쳆쳈쳊",5,"쳑쳒쳓쳕",5],["ab81","쳛",8,"쳥",6,"쳭쳮쳯쳱",12,"ァ",85],["ac41","쳾쳿촀촂",5,"촊촋촍촎촏촑",6,"촚촜촞촟촠"],["ac61","촡촢촣촥촦촧촩촪촫촭",11,"촺",4],["ac81","촿",28,"쵝쵞쵟А",5,"ЁЖ",25],["acd1","а",5,"ёж",25],["ad41","쵡쵢쵣쵥",6,"쵮쵰쵲",5,"쵹",7],["ad61","춁",6,"춉",10,"춖춗춙춚춛춝춞춟"],["ad81","춠춡춢춣춦춨춪",5,"춱",18,"췅"],["ae41","췆",5,"췍췎췏췑",16],["ae61","췢",5,"췩췪췫췭췮췯췱",6,"췺췼췾",4],["ae81","츃츅츆츇츉츊츋츍",6,"츕츖츗츘츚",5,"츢츣츥츦츧츩츪츫"],["af41","츬츭츮츯츲츴츶",19],["af61","칊",13,"칚칛칝칞칢",5,"칪칬"],["af81","칮",5,"칶칷칹칺칻칽",6,"캆캈캊",5,"캒캓캕캖캗캙"],["b041","캚",5,"캢캦",5,"캮",12],["b061","캻",5,"컂",19],["b081","컖",13,"컦컧컩컪컭",6,"컶컺",5,"가각간갇갈갉갊감",7,"같",4,"갠갤갬갭갯갰갱갸갹갼걀걋걍걔걘걜거걱건걷걸걺검겁것겄겅겆겉겊겋게겐겔겜겝겟겠겡겨격겪견겯결겸겹겻겼경곁계곈곌곕곗고곡곤곧골곪곬곯곰곱곳공곶과곽관괄괆"],["b141","켂켃켅켆켇켉",6,"켒켔켖",5,"켝켞켟켡켢켣"],["b161","켥",6,"켮켲",5,"켹",11],["b181","콅",14,"콖콗콙콚콛콝",6,"콦콨콪콫콬괌괍괏광괘괜괠괩괬괭괴괵괸괼굄굅굇굉교굔굘굡굣구국군굳굴굵굶굻굼굽굿궁궂궈궉권궐궜궝궤궷귀귁귄귈귐귑귓규균귤그극근귿글긁금급긋긍긔기긱긴긷길긺김깁깃깅깆깊까깍깎깐깔깖깜깝깟깠깡깥깨깩깬깰깸"],["b241","콭콮콯콲콳콵콶콷콹",6,"쾁쾂쾃쾄쾆",5,"쾍"],["b261","쾎",18,"쾢",5,"쾩"],["b281","쾪",5,"쾱",18,"쿅",6,"깹깻깼깽꺄꺅꺌꺼꺽꺾껀껄껌껍껏껐껑께껙껜껨껫껭껴껸껼꼇꼈꼍꼐꼬꼭꼰꼲꼴꼼꼽꼿꽁꽂꽃꽈꽉꽐꽜꽝꽤꽥꽹꾀꾄꾈꾐꾑꾕꾜꾸꾹꾼꿀꿇꿈꿉꿋꿍꿎꿔꿜꿨꿩꿰꿱꿴꿸뀀뀁뀄뀌뀐뀔뀜뀝뀨끄끅끈끊끌끎끓끔끕끗끙"],["b341","쿌",19,"쿢쿣쿥쿦쿧쿩"],["b361","쿪",5,"쿲쿴쿶",5,"쿽쿾쿿퀁퀂퀃퀅",5],["b381","퀋",5,"퀒",5,"퀙",19,"끝끼끽낀낄낌낍낏낑나낙낚난낟날낡낢남납낫",4,"낱낳내낵낸낼냄냅냇냈냉냐냑냔냘냠냥너넉넋넌널넒넓넘넙넛넜넝넣네넥넨넬넴넵넷넸넹녀녁년녈념녑녔녕녘녜녠노녹논놀놂놈놉놋농높놓놔놘놜놨뇌뇐뇔뇜뇝"],["b441","퀮",5,"퀶퀷퀹퀺퀻퀽",6,"큆큈큊",5],["b461","큑큒큓큕큖큗큙",6,"큡",10,"큮큯"],["b481","큱큲큳큵",6,"큾큿킀킂",18,"뇟뇨뇩뇬뇰뇹뇻뇽누눅눈눋눌눔눕눗눙눠눴눼뉘뉜뉠뉨뉩뉴뉵뉼늄늅늉느늑는늘늙늚늠늡늣능늦늪늬늰늴니닉닌닐닒님닙닛닝닢다닥닦단닫",4,"닳담답닷",4,"닿대댁댄댈댐댑댓댔댕댜더덕덖던덛덜덞덟덤덥"],["b541","킕",14,"킦킧킩킪킫킭",5],["b561","킳킶킸킺",5,"탂탃탅탆탇탊",5,"탒탖",4],["b581","탛탞탟탡탢탣탥",6,"탮탲",5,"탹",11,"덧덩덫덮데덱덴델뎀뎁뎃뎄뎅뎌뎐뎔뎠뎡뎨뎬도독돈돋돌돎돐돔돕돗동돛돝돠돤돨돼됐되된될됨됩됫됴두둑둔둘둠둡둣둥둬뒀뒈뒝뒤뒨뒬뒵뒷뒹듀듄듈듐듕드득든듣들듦듬듭듯등듸디딕딘딛딜딤딥딧딨딩딪따딱딴딸"],["b641","턅",7,"턎",17],["b661","턠",15,"턲턳턵턶턷턹턻턼턽턾"],["b681","턿텂텆",5,"텎텏텑텒텓텕",6,"텞텠텢",5,"텩텪텫텭땀땁땃땄땅땋때땍땐땔땜땝땟땠땡떠떡떤떨떪떫떰떱떳떴떵떻떼떽뗀뗄뗌뗍뗏뗐뗑뗘뗬또똑똔똘똥똬똴뙈뙤뙨뚜뚝뚠뚤뚫뚬뚱뛔뛰뛴뛸뜀뜁뜅뜨뜩뜬뜯뜰뜸뜹뜻띄띈띌띔띕띠띤띨띰띱띳띵라락란랄람랍랏랐랑랒랖랗"],["b741","텮",13,"텽",6,"톅톆톇톉톊"],["b761","톋",20,"톢톣톥톦톧"],["b781","톩",6,"톲톴톶톷톸톹톻톽톾톿퇁",14,"래랙랜랠램랩랫랬랭랴략랸럇량러럭런럴럼럽럿렀렁렇레렉렌렐렘렙렛렝려력련렬렴렵렷렸령례롄롑롓로록론롤롬롭롯롱롸롼뢍뢨뢰뢴뢸룀룁룃룅료룐룔룝룟룡루룩룬룰룸룹룻룽뤄뤘뤠뤼뤽륀륄륌륏륑류륙륜률륨륩"],["b841","퇐",7,"퇙",17],["b861","퇫",8,"퇵퇶퇷퇹",13],["b881","툈툊",5,"툑",24,"륫륭르륵른를름릅릇릉릊릍릎리릭린릴림립릿링마막만많",4,"맘맙맛망맞맡맣매맥맨맬맴맵맷맸맹맺먀먁먈먕머먹먼멀멂멈멉멋멍멎멓메멕멘멜멤멥멧멨멩며멱면멸몃몄명몇몌모목몫몬몰몲몸몹못몽뫄뫈뫘뫙뫼"],["b941","툪툫툮툯툱툲툳툵",6,"툾퉀퉂",5,"퉉퉊퉋퉌"],["b961","퉍",14,"퉝",6,"퉥퉦퉧퉨"],["b981","퉩",22,"튂튃튅튆튇튉튊튋튌묀묄묍묏묑묘묜묠묩묫무묵묶문묻물묽묾뭄뭅뭇뭉뭍뭏뭐뭔뭘뭡뭣뭬뮈뮌뮐뮤뮨뮬뮴뮷므믄믈믐믓미믹민믿밀밂밈밉밋밌밍및밑바",4,"받",4,"밤밥밧방밭배백밴밸뱀뱁뱃뱄뱅뱉뱌뱍뱐뱝버벅번벋벌벎범법벗"],["ba41","튍튎튏튒튓튔튖",5,"튝튞튟튡튢튣튥",6,"튭"],["ba61","튮튯튰튲",5,"튺튻튽튾틁틃",4,"틊틌",5],["ba81","틒틓틕틖틗틙틚틛틝",6,"틦",9,"틲틳틵틶틷틹틺벙벚베벡벤벧벨벰벱벳벴벵벼벽변별볍볏볐병볕볘볜보복볶본볼봄봅봇봉봐봔봤봬뵀뵈뵉뵌뵐뵘뵙뵤뵨부북분붇불붉붊붐붑붓붕붙붚붜붤붰붸뷔뷕뷘뷜뷩뷰뷴뷸븀븃븅브븍븐블븜븝븟비빅빈빌빎빔빕빗빙빚빛빠빡빤"],["bb41","틻",4,"팂팄팆",5,"팏팑팒팓팕팗",4,"팞팢팣"],["bb61","팤팦팧팪팫팭팮팯팱",6,"팺팾",5,"퍆퍇퍈퍉"],["bb81","퍊",31,"빨빪빰빱빳빴빵빻빼빽뺀뺄뺌뺍뺏뺐뺑뺘뺙뺨뻐뻑뻔뻗뻘뻠뻣뻤뻥뻬뼁뼈뼉뼘뼙뼛뼜뼝뽀뽁뽄뽈뽐뽑뽕뾔뾰뿅뿌뿍뿐뿔뿜뿟뿡쀼쁑쁘쁜쁠쁨쁩삐삑삔삘삠삡삣삥사삭삯산삳살삵삶삼삽삿샀상샅새색샌샐샘샙샛샜생샤"],["bc41","퍪",17,"퍾퍿펁펂펃펅펆펇"],["bc61","펈펉펊펋펎펒",5,"펚펛펝펞펟펡",6,"펪펬펮"],["bc81","펯",4,"펵펶펷펹펺펻펽",6,"폆폇폊",5,"폑",5,"샥샨샬샴샵샷샹섀섄섈섐섕서",4,"섣설섦섧섬섭섯섰성섶세섹센셀셈셉셋셌셍셔셕션셜셤셥셧셨셩셰셴셸솅소속솎손솔솖솜솝솟송솥솨솩솬솰솽쇄쇈쇌쇔쇗쇘쇠쇤쇨쇰쇱쇳쇼쇽숀숄숌숍숏숑수숙순숟술숨숩숫숭"],["bd41","폗폙",7,"폢폤",7,"폮폯폱폲폳폵폶폷"],["bd61","폸폹폺폻폾퐀퐂",5,"퐉",13],["bd81","퐗",5,"퐞",25,"숯숱숲숴쉈쉐쉑쉔쉘쉠쉥쉬쉭쉰쉴쉼쉽쉿슁슈슉슐슘슛슝스슥슨슬슭슴습슷승시식신싣실싫심십싯싱싶싸싹싻싼쌀쌈쌉쌌쌍쌓쌔쌕쌘쌜쌤쌥쌨쌩썅써썩썬썰썲썸썹썼썽쎄쎈쎌쏀쏘쏙쏜쏟쏠쏢쏨쏩쏭쏴쏵쏸쐈쐐쐤쐬쐰"],["be41","퐸",7,"푁푂푃푅",14],["be61","푔",7,"푝푞푟푡푢푣푥",7,"푮푰푱푲"],["be81","푳",4,"푺푻푽푾풁풃",4,"풊풌풎",5,"풕",8,"쐴쐼쐽쑈쑤쑥쑨쑬쑴쑵쑹쒀쒔쒜쒸쒼쓩쓰쓱쓴쓸쓺쓿씀씁씌씐씔씜씨씩씬씰씸씹씻씽아악안앉않알앍앎앓암압앗았앙앝앞애액앤앨앰앱앳앴앵야약얀얄얇얌얍얏양얕얗얘얜얠얩어억언얹얻얼얽얾엄",6,"엌엎"],["bf41","풞",10,"풪",14],["bf61","풹",18,"퓍퓎퓏퓑퓒퓓퓕"],["bf81","퓖",5,"퓝퓞퓠",7,"퓩퓪퓫퓭퓮퓯퓱",6,"퓹퓺퓼에엑엔엘엠엡엣엥여역엮연열엶엷염",5,"옅옆옇예옌옐옘옙옛옜오옥온올옭옮옰옳옴옵옷옹옻와왁완왈왐왑왓왔왕왜왝왠왬왯왱외왹왼욀욈욉욋욍요욕욘욜욤욥욧용우욱운울욹욺움웁웃웅워웍원월웜웝웠웡웨"],["c041","퓾",5,"픅픆픇픉픊픋픍",6,"픖픘",5],["c061","픞",25],["c081","픸픹픺픻픾픿핁핂핃핅",6,"핎핐핒",5,"핚핛핝핞핟핡핢핣웩웬웰웸웹웽위윅윈윌윔윕윗윙유육윤율윰윱윳융윷으윽은을읊음읍읏응",7,"읜읠읨읫이익인일읽읾잃임입잇있잉잊잎자작잔잖잗잘잚잠잡잣잤장잦재잭잰잴잼잽잿쟀쟁쟈쟉쟌쟎쟐쟘쟝쟤쟨쟬저적전절젊"],["c141","핤핦핧핪핬핮",5,"핶핷핹핺핻핽",6,"햆햊햋"],["c161","햌햍햎햏햑",19,"햦햧"],["c181","햨",31,"점접젓정젖제젝젠젤젬젭젯젱져젼졀졈졉졌졍졔조족존졸졺좀좁좃종좆좇좋좌좍좔좝좟좡좨좼좽죄죈죌죔죕죗죙죠죡죤죵주죽준줄줅줆줌줍줏중줘줬줴쥐쥑쥔쥘쥠쥡쥣쥬쥰쥴쥼즈즉즌즐즘즙즛증지직진짇질짊짐집짓"],["c241","헊헋헍헎헏헑헓",4,"헚헜헞",5,"헦헧헩헪헫헭헮"],["c261","헯",4,"헶헸헺",5,"혂혃혅혆혇혉",6,"혒"],["c281","혖",5,"혝혞혟혡혢혣혥",7,"혮",9,"혺혻징짖짙짚짜짝짠짢짤짧짬짭짯짰짱째짹짼쨀쨈쨉쨋쨌쨍쨔쨘쨩쩌쩍쩐쩔쩜쩝쩟쩠쩡쩨쩽쪄쪘쪼쪽쫀쫄쫌쫍쫏쫑쫓쫘쫙쫠쫬쫴쬈쬐쬔쬘쬠쬡쭁쭈쭉쭌쭐쭘쭙쭝쭤쭸쭹쮜쮸쯔쯤쯧쯩찌찍찐찔찜찝찡찢찧차착찬찮찰참찹찻"],["c341","혽혾혿홁홂홃홄홆홇홊홌홎홏홐홒홓홖홗홙홚홛홝",4],["c361","홢",4,"홨홪",5,"홲홳홵",11],["c381","횁횂횄횆",5,"횎횏횑횒횓횕",7,"횞횠횢",5,"횩횪찼창찾채책챈챌챔챕챗챘챙챠챤챦챨챰챵처척천철첨첩첫첬청체첵첸첼쳄쳅쳇쳉쳐쳔쳤쳬쳰촁초촉촌촐촘촙촛총촤촨촬촹최쵠쵤쵬쵭쵯쵱쵸춈추축춘출춤춥춧충춰췄췌췐취췬췰췸췹췻췽츄츈츌츔츙츠측츤츨츰츱츳층"],["c441","횫횭횮횯횱",7,"횺횼",7,"훆훇훉훊훋"],["c461","훍훎훏훐훒훓훕훖훘훚",5,"훡훢훣훥훦훧훩",4],["c481","훮훯훱훲훳훴훶",5,"훾훿휁휂휃휅",11,"휒휓휔치칙친칟칠칡침칩칫칭카칵칸칼캄캅캇캉캐캑캔캘캠캡캣캤캥캬캭컁커컥컨컫컬컴컵컷컸컹케켁켄켈켐켑켓켕켜켠켤켬켭켯켰켱켸코콕콘콜콤콥콧콩콰콱콴콸쾀쾅쾌쾡쾨쾰쿄쿠쿡쿤쿨쿰쿱쿳쿵쿼퀀퀄퀑퀘퀭퀴퀵퀸퀼"],["c541","휕휖휗휚휛휝휞휟휡",6,"휪휬휮",5,"휶휷휹"],["c561","휺휻휽",6,"흅흆흈흊",5,"흒흓흕흚",4],["c581","흟흢흤흦흧흨흪흫흭흮흯흱흲흳흵",6,"흾흿힀힂",5,"힊힋큄큅큇큉큐큔큘큠크큭큰클큼큽킁키킥킨킬킴킵킷킹타탁탄탈탉탐탑탓탔탕태택탠탤탬탭탯탰탱탸턍터턱턴털턺텀텁텃텄텅테텍텐텔템텝텟텡텨텬텼톄톈토톡톤톨톰톱톳통톺톼퇀퇘퇴퇸툇툉툐투툭툰툴툼툽툿퉁퉈퉜"],["c641","힍힎힏힑",6,"힚힜힞",5],["c6a1","퉤튀튁튄튈튐튑튕튜튠튤튬튱트특튼튿틀틂틈틉틋틔틘틜틤틥티틱틴틸팀팁팃팅파팍팎판팔팖팜팝팟팠팡팥패팩팬팰팸팹팻팼팽퍄퍅퍼퍽펀펄펌펍펏펐펑페펙펜펠펨펩펫펭펴편펼폄폅폈평폐폘폡폣포폭폰폴폼폽폿퐁"],["c7a1","퐈퐝푀푄표푠푤푭푯푸푹푼푿풀풂품풉풋풍풔풩퓌퓐퓔퓜퓟퓨퓬퓰퓸퓻퓽프픈플픔픕픗피픽핀필핌핍핏핑하학한할핥함합핫항해핵핸핼햄햅햇했행햐향허헉헌헐헒험헙헛헝헤헥헨헬헴헵헷헹혀혁현혈혐협혓혔형혜혠"],["c8a1","혤혭호혹혼홀홅홈홉홋홍홑화확환활홧황홰홱홴횃횅회획횐횔횝횟횡효횬횰횹횻후훅훈훌훑훔훗훙훠훤훨훰훵훼훽휀휄휑휘휙휜휠휨휩휫휭휴휵휸휼흄흇흉흐흑흔흖흗흘흙흠흡흣흥흩희흰흴흼흽힁히힉힌힐힘힙힛힝"],["caa1","伽佳假價加可呵哥嘉嫁家暇架枷柯歌珂痂稼苛茄街袈訶賈跏軻迦駕刻却各恪慤殼珏脚覺角閣侃刊墾奸姦干幹懇揀杆柬桿澗癎看磵稈竿簡肝艮艱諫間乫喝曷渴碣竭葛褐蝎鞨勘坎堪嵌感憾戡敢柑橄減甘疳監瞰紺邯鑑鑒龕"],["cba1","匣岬甲胛鉀閘剛堈姜岡崗康强彊慷江畺疆糠絳綱羌腔舡薑襁講鋼降鱇介价個凱塏愷愾慨改槪漑疥皆盖箇芥蓋豈鎧開喀客坑更粳羹醵倨去居巨拒据據擧渠炬祛距踞車遽鉅鋸乾件健巾建愆楗腱虔蹇鍵騫乞傑杰桀儉劍劒檢"],["cca1","瞼鈐黔劫怯迲偈憩揭擊格檄激膈覡隔堅牽犬甄絹繭肩見譴遣鵑抉決潔結缺訣兼慊箝謙鉗鎌京俓倞傾儆勁勍卿坰境庚徑慶憬擎敬景暻更梗涇炅烱璟璥瓊痙硬磬竟競絅經耕耿脛莖警輕逕鏡頃頸驚鯨係啓堺契季屆悸戒桂械"],["cda1","棨溪界癸磎稽系繫繼計誡谿階鷄古叩告呱固姑孤尻庫拷攷故敲暠枯槁沽痼皐睾稿羔考股膏苦苽菰藁蠱袴誥賈辜錮雇顧高鼓哭斛曲梏穀谷鵠困坤崑昆梱棍滾琨袞鯤汨滑骨供公共功孔工恐恭拱控攻珙空蚣貢鞏串寡戈果瓜"],["cea1","科菓誇課跨過鍋顆廓槨藿郭串冠官寬慣棺款灌琯瓘管罐菅觀貫關館刮恝括适侊光匡壙廣曠洸炚狂珖筐胱鑛卦掛罫乖傀塊壞怪愧拐槐魁宏紘肱轟交僑咬喬嬌嶠巧攪敎校橋狡皎矯絞翹膠蕎蛟較轎郊餃驕鮫丘久九仇俱具勾"],["cfa1","區口句咎嘔坵垢寇嶇廐懼拘救枸柩構歐毆毬求溝灸狗玖球瞿矩究絿耉臼舅舊苟衢謳購軀逑邱鉤銶駒驅鳩鷗龜國局菊鞠鞫麴君窘群裙軍郡堀屈掘窟宮弓穹窮芎躬倦券勸卷圈拳捲權淃眷厥獗蕨蹶闕机櫃潰詭軌饋句晷歸貴"],["d0a1","鬼龜叫圭奎揆槻珪硅窺竅糾葵規赳逵閨勻均畇筠菌鈞龜橘克剋劇戟棘極隙僅劤勤懃斤根槿瑾筋芹菫覲謹近饉契今妗擒昑檎琴禁禽芩衾衿襟金錦伋及急扱汲級給亘兢矜肯企伎其冀嗜器圻基埼夔奇妓寄岐崎己幾忌技旗旣"],["d1a1","朞期杞棋棄機欺氣汽沂淇玘琦琪璂璣畸畿碁磯祁祇祈祺箕紀綺羈耆耭肌記譏豈起錡錤飢饑騎騏驥麒緊佶吉拮桔金喫儺喇奈娜懦懶拏拿癩",5,"那樂",4,"諾酪駱亂卵暖欄煖爛蘭難鸞捏捺南嵐枏楠湳濫男藍襤拉"],["d2a1","納臘蠟衲囊娘廊",4,"乃來內奈柰耐冷女年撚秊念恬拈捻寧寗努勞奴弩怒擄櫓爐瑙盧",5,"駑魯",10,"濃籠聾膿農惱牢磊腦賂雷尿壘",7,"嫩訥杻紐勒",5,"能菱陵尼泥匿溺多茶"],["d3a1","丹亶但單團壇彖斷旦檀段湍短端簞緞蛋袒鄲鍛撻澾獺疸達啖坍憺擔曇淡湛潭澹痰聃膽蕁覃談譚錟沓畓答踏遝唐堂塘幢戇撞棠當糖螳黨代垈坮大對岱帶待戴擡玳臺袋貸隊黛宅德悳倒刀到圖堵塗導屠島嶋度徒悼挑掉搗桃"],["d4a1","棹櫂淘渡滔濤燾盜睹禱稻萄覩賭跳蹈逃途道都鍍陶韜毒瀆牘犢獨督禿篤纛讀墩惇敦旽暾沌焞燉豚頓乭突仝冬凍動同憧東桐棟洞潼疼瞳童胴董銅兜斗杜枓痘竇荳讀豆逗頭屯臀芚遁遯鈍得嶝橙燈登等藤謄鄧騰喇懶拏癩羅"],["d5a1","蘿螺裸邏樂洛烙珞絡落諾酪駱丹亂卵欄欒瀾爛蘭鸞剌辣嵐擥攬欖濫籃纜藍襤覽拉臘蠟廊朗浪狼琅瑯螂郞來崍徠萊冷掠略亮倆兩凉梁樑粮粱糧良諒輛量侶儷勵呂廬慮戾旅櫚濾礪藜蠣閭驢驪麗黎力曆歷瀝礫轢靂憐戀攣漣"],["d6a1","煉璉練聯蓮輦連鍊冽列劣洌烈裂廉斂殮濂簾獵令伶囹寧岺嶺怜玲笭羚翎聆逞鈴零靈領齡例澧禮醴隷勞怒撈擄櫓潞瀘爐盧老蘆虜路輅露魯鷺鹵碌祿綠菉錄鹿麓論壟弄朧瀧瓏籠聾儡瀨牢磊賂賚賴雷了僚寮廖料燎療瞭聊蓼"],["d7a1","遼鬧龍壘婁屢樓淚漏瘻累縷蔞褸鏤陋劉旒柳榴流溜瀏琉瑠留瘤硫謬類六戮陸侖倫崙淪綸輪律慄栗率隆勒肋凜凌楞稜綾菱陵俚利厘吏唎履悧李梨浬犁狸理璃異痢籬罹羸莉裏裡里釐離鯉吝潾燐璘藺躪隣鱗麟林淋琳臨霖砬"],["d8a1","立笠粒摩瑪痲碼磨馬魔麻寞幕漠膜莫邈万卍娩巒彎慢挽晩曼滿漫灣瞞萬蔓蠻輓饅鰻唜抹末沫茉襪靺亡妄忘忙望網罔芒茫莽輞邙埋妹媒寐昧枚梅每煤罵買賣邁魅脈貊陌驀麥孟氓猛盲盟萌冪覓免冕勉棉沔眄眠綿緬面麵滅"],["d9a1","蔑冥名命明暝椧溟皿瞑茗蓂螟酩銘鳴袂侮冒募姆帽慕摸摹暮某模母毛牟牡瑁眸矛耗芼茅謀謨貌木沐牧目睦穆鶩歿沒夢朦蒙卯墓妙廟描昴杳渺猫竗苗錨務巫憮懋戊拇撫无楙武毋無珷畝繆舞茂蕪誣貿霧鵡墨默們刎吻問文"],["daa1","汶紊紋聞蚊門雯勿沕物味媚尾嵋彌微未梶楣渼湄眉米美薇謎迷靡黴岷悶愍憫敏旻旼民泯玟珉緡閔密蜜謐剝博拍搏撲朴樸泊珀璞箔粕縛膊舶薄迫雹駁伴半反叛拌搬攀斑槃泮潘班畔瘢盤盼磐磻礬絆般蟠返頒飯勃拔撥渤潑"],["dba1","發跋醱鉢髮魃倣傍坊妨尨幇彷房放方旁昉枋榜滂磅紡肪膀舫芳蒡蚌訪謗邦防龐倍俳北培徘拜排杯湃焙盃背胚裴裵褙賠輩配陪伯佰帛柏栢白百魄幡樊煩燔番磻繁蕃藩飜伐筏罰閥凡帆梵氾汎泛犯範范法琺僻劈壁擘檗璧癖"],["dca1","碧蘗闢霹便卞弁變辨辯邊別瞥鱉鼈丙倂兵屛幷昞昺柄棅炳甁病秉竝輧餠騈保堡報寶普步洑湺潽珤甫菩補褓譜輔伏僕匐卜宓復服福腹茯蔔複覆輹輻馥鰒本乶俸奉封峯峰捧棒烽熢琫縫蓬蜂逢鋒鳳不付俯傅剖副否咐埠夫婦"],["dda1","孚孵富府復扶敷斧浮溥父符簿缶腐腑膚艀芙莩訃負賦賻赴趺部釜阜附駙鳧北分吩噴墳奔奮忿憤扮昐汾焚盆粉糞紛芬賁雰不佛弗彿拂崩朋棚硼繃鵬丕備匕匪卑妃婢庇悲憊扉批斐枇榧比毖毗毘沸泌琵痺砒碑秕秘粃緋翡肥"],["dea1","脾臂菲蜚裨誹譬費鄙非飛鼻嚬嬪彬斌檳殯浜濱瀕牝玭貧賓頻憑氷聘騁乍事些仕伺似使俟僿史司唆嗣四士奢娑寫寺射巳師徙思捨斜斯柶査梭死沙泗渣瀉獅砂社祀祠私篩紗絲肆舍莎蓑蛇裟詐詞謝賜赦辭邪飼駟麝削數朔索"],["dfa1","傘刪山散汕珊産疝算蒜酸霰乷撒殺煞薩三參杉森渗芟蔘衫揷澁鈒颯上傷像償商喪嘗孀尙峠常床庠廂想桑橡湘爽牀狀相祥箱翔裳觴詳象賞霜塞璽賽嗇塞穡索色牲生甥省笙墅壻嶼序庶徐恕抒捿敍暑曙書栖棲犀瑞筮絮緖署"],["e0a1","胥舒薯西誓逝鋤黍鼠夕奭席惜昔晳析汐淅潟石碩蓆釋錫仙僊先善嬋宣扇敾旋渲煽琁瑄璇璿癬禪線繕羨腺膳船蘚蟬詵跣選銑鐥饍鮮卨屑楔泄洩渫舌薛褻設說雪齧剡暹殲纖蟾贍閃陝攝涉燮葉城姓宬性惺成星晟猩珹盛省筬"],["e1a1","聖聲腥誠醒世勢歲洗稅笹細說貰召嘯塑宵小少巢所掃搔昭梳沼消溯瀟炤燒甦疏疎瘙笑篠簫素紹蔬蕭蘇訴逍遡邵銷韶騷俗屬束涑粟續謖贖速孫巽損蓀遜飡率宋悚松淞訟誦送頌刷殺灑碎鎖衰釗修受嗽囚垂壽嫂守岫峀帥愁"],["e2a1","戍手授搜收數樹殊水洙漱燧狩獸琇璲瘦睡秀穗竪粹綏綬繡羞脩茱蒐蓚藪袖誰讐輸遂邃酬銖銹隋隧隨雖需須首髓鬚叔塾夙孰宿淑潚熟琡璹肅菽巡徇循恂旬栒楯橓殉洵淳珣盾瞬筍純脣舜荀蓴蕣詢諄醇錞順馴戌術述鉥崇崧"],["e3a1","嵩瑟膝蝨濕拾習褶襲丞乘僧勝升承昇繩蠅陞侍匙嘶始媤尸屎屍市弑恃施是時枾柴猜矢示翅蒔蓍視試詩諡豕豺埴寔式息拭植殖湜熄篒蝕識軾食飾伸侁信呻娠宸愼新晨燼申神紳腎臣莘薪藎蜃訊身辛辰迅失室實悉審尋心沁"],["e4a1","沈深瀋甚芯諶什十拾雙氏亞俄兒啞娥峨我牙芽莪蛾衙訝阿雅餓鴉鵝堊岳嶽幄惡愕握樂渥鄂鍔顎鰐齷安岸按晏案眼雁鞍顔鮟斡謁軋閼唵岩巖庵暗癌菴闇壓押狎鴨仰央怏昻殃秧鴦厓哀埃崖愛曖涯碍艾隘靄厄扼掖液縊腋額"],["e5a1","櫻罌鶯鸚也倻冶夜惹揶椰爺耶若野弱掠略約若葯蒻藥躍亮佯兩凉壤孃恙揚攘敭暘梁楊樣洋瀁煬痒瘍禳穰糧羊良襄諒讓釀陽量養圄御於漁瘀禦語馭魚齬億憶抑檍臆偃堰彦焉言諺孼蘖俺儼嚴奄掩淹嶪業円予余勵呂女如廬"],["e6a1","旅歟汝濾璵礖礪與艅茹輿轝閭餘驪麗黎亦力域役易曆歷疫繹譯轢逆驛嚥堧姸娟宴年延憐戀捐挻撚椽沇沿涎涓淵演漣烟然煙煉燃燕璉硏硯秊筵緣練縯聯衍軟輦蓮連鉛鍊鳶列劣咽悅涅烈熱裂說閱厭廉念捻染殮炎焰琰艶苒"],["e7a1","簾閻髥鹽曄獵燁葉令囹塋寧嶺嶸影怜映暎楹榮永泳渶潁濚瀛瀯煐營獰玲瑛瑩瓔盈穎纓羚聆英詠迎鈴鍈零霙靈領乂倪例刈叡曳汭濊猊睿穢芮藝蘂禮裔詣譽豫醴銳隸霓預五伍俉傲午吾吳嗚塢墺奧娛寤悟惡懊敖旿晤梧汚澳"],["e8a1","烏熬獒筽蜈誤鰲鼇屋沃獄玉鈺溫瑥瘟穩縕蘊兀壅擁瓮甕癰翁邕雍饔渦瓦窩窪臥蛙蝸訛婉完宛梡椀浣玩琓琬碗緩翫脘腕莞豌阮頑曰往旺枉汪王倭娃歪矮外嵬巍猥畏了僚僥凹堯夭妖姚寥寮尿嶢拗搖撓擾料曜樂橈燎燿瑤療"],["e9a1","窈窯繇繞耀腰蓼蟯要謠遙遼邀饒慾欲浴縟褥辱俑傭冗勇埇墉容庸慂榕涌湧溶熔瑢用甬聳茸蓉踊鎔鏞龍于佑偶優又友右宇寓尤愚憂旴牛玗瑀盂祐禑禹紆羽芋藕虞迂遇郵釪隅雨雩勖彧旭昱栯煜稶郁頊云暈橒殞澐熉耘芸蕓"],["eaa1","運隕雲韻蔚鬱亐熊雄元原員圓園垣媛嫄寃怨愿援沅洹湲源爰猿瑗苑袁轅遠阮院願鴛月越鉞位偉僞危圍委威尉慰暐渭爲瑋緯胃萎葦蔿蝟衛褘謂違韋魏乳侑儒兪劉唯喩孺宥幼幽庾悠惟愈愉揄攸有杻柔柚柳楡楢油洧流游溜"],["eba1","濡猶猷琉瑜由留癒硫紐維臾萸裕誘諛諭踰蹂遊逾遺酉釉鍮類六堉戮毓肉育陸倫允奫尹崙淪潤玧胤贇輪鈗閏律慄栗率聿戎瀜絨融隆垠恩慇殷誾銀隱乙吟淫蔭陰音飮揖泣邑凝應膺鷹依倚儀宜意懿擬椅毅疑矣義艤薏蟻衣誼"],["eca1","議醫二以伊利吏夷姨履已弛彛怡易李梨泥爾珥理異痍痢移罹而耳肄苡荑裏裡貽貳邇里離飴餌匿溺瀷益翊翌翼謚人仁刃印吝咽因姻寅引忍湮燐璘絪茵藺蚓認隣靭靷鱗麟一佚佾壹日溢逸鎰馹任壬妊姙恁林淋稔臨荏賃入卄"],["eda1","立笠粒仍剩孕芿仔刺咨姉姿子字孜恣慈滋炙煮玆瓷疵磁紫者自茨蔗藉諮資雌作勺嚼斫昨灼炸爵綽芍酌雀鵲孱棧殘潺盞岑暫潛箴簪蠶雜丈仗匠場墻壯奬將帳庄張掌暲杖樟檣欌漿牆狀獐璋章粧腸臟臧莊葬蔣薔藏裝贓醬長"],["eea1","障再哉在宰才材栽梓渽滓災縡裁財載齋齎爭箏諍錚佇低儲咀姐底抵杵楮樗沮渚狙猪疽箸紵苧菹著藷詛貯躇這邸雎齟勣吊嫡寂摘敵滴狄炙的積笛籍績翟荻謫賊赤跡蹟迪迹適鏑佃佺傳全典前剪塡塼奠專展廛悛戰栓殿氈澱"],["efa1","煎琠田甸畑癲筌箋箭篆纏詮輾轉鈿銓錢鐫電顚顫餞切截折浙癤竊節絶占岾店漸点粘霑鮎點接摺蝶丁井亭停偵呈姃定幀庭廷征情挺政整旌晶晸柾楨檉正汀淀淨渟湞瀞炡玎珽町睛碇禎程穽精綎艇訂諪貞鄭酊釘鉦鋌錠霆靖"],["f0a1","靜頂鼎制劑啼堤帝弟悌提梯濟祭第臍薺製諸蹄醍除際霽題齊俎兆凋助嘲弔彫措操早晁曺曹朝條棗槽漕潮照燥爪璪眺祖祚租稠窕粗糟組繰肇藻蚤詔調趙躁造遭釣阻雕鳥族簇足鏃存尊卒拙猝倧宗從悰慫棕淙琮種終綜縱腫"],["f1a1","踪踵鍾鐘佐坐左座挫罪主住侏做姝胄呪周嗾奏宙州廚晝朱柱株注洲湊澍炷珠疇籌紂紬綢舟蛛註誅走躊輳週酎酒鑄駐竹粥俊儁准埈寯峻晙樽浚準濬焌畯竣蠢逡遵雋駿茁中仲衆重卽櫛楫汁葺增憎曾拯烝甑症繒蒸證贈之只"],["f2a1","咫地址志持指摯支旨智枝枳止池沚漬知砥祉祗紙肢脂至芝芷蜘誌識贄趾遲直稙稷織職唇嗔塵振搢晉晋桭榛殄津溱珍瑨璡畛疹盡眞瞋秦縉縝臻蔯袗診賑軫辰進鎭陣陳震侄叱姪嫉帙桎瓆疾秩窒膣蛭質跌迭斟朕什執潗緝輯"],["f3a1","鏶集徵懲澄且侘借叉嗟嵯差次此磋箚茶蹉車遮捉搾着窄錯鑿齪撰澯燦璨瓚竄簒纂粲纘讚贊鑽餐饌刹察擦札紮僭參塹慘慙懺斬站讒讖倉倡創唱娼廠彰愴敞昌昶暢槍滄漲猖瘡窓脹艙菖蒼債埰寀寨彩採砦綵菜蔡采釵冊柵策"],["f4a1","責凄妻悽處倜刺剔尺慽戚拓擲斥滌瘠脊蹠陟隻仟千喘天川擅泉淺玔穿舛薦賤踐遷釧闡阡韆凸哲喆徹撤澈綴輟轍鐵僉尖沾添甛瞻簽籤詹諂堞妾帖捷牒疊睫諜貼輒廳晴淸聽菁請靑鯖切剃替涕滯締諦逮遞體初剿哨憔抄招梢"],["f5a1","椒楚樵炒焦硝礁礎秒稍肖艸苕草蕉貂超酢醋醮促囑燭矗蜀觸寸忖村邨叢塚寵悤憁摠總聰蔥銃撮催崔最墜抽推椎楸樞湫皺秋芻萩諏趨追鄒酋醜錐錘鎚雛騶鰍丑畜祝竺筑築縮蓄蹙蹴軸逐春椿瑃出朮黜充忠沖蟲衝衷悴膵萃"],["f6a1","贅取吹嘴娶就炊翠聚脆臭趣醉驟鷲側仄厠惻測層侈値嗤峙幟恥梔治淄熾痔痴癡稚穉緇緻置致蚩輜雉馳齒則勅飭親七柒漆侵寢枕沈浸琛砧針鍼蟄秤稱快他咤唾墮妥惰打拖朶楕舵陀馱駝倬卓啄坼度托拓擢晫柝濁濯琢琸託"],["f7a1","鐸呑嘆坦彈憚歎灘炭綻誕奪脫探眈耽貪塔搭榻宕帑湯糖蕩兌台太怠態殆汰泰笞胎苔跆邰颱宅擇澤撑攄兎吐土討慟桶洞痛筒統通堆槌腿褪退頹偸套妬投透鬪慝特闖坡婆巴把播擺杷波派爬琶破罷芭跛頗判坂板版瓣販辦鈑"],["f8a1","阪八叭捌佩唄悖敗沛浿牌狽稗覇貝彭澎烹膨愎便偏扁片篇編翩遍鞭騙貶坪平枰萍評吠嬖幣廢弊斃肺蔽閉陛佈包匍匏咆哺圃布怖抛抱捕暴泡浦疱砲胞脯苞葡蒲袍褒逋鋪飽鮑幅暴曝瀑爆輻俵剽彪慓杓標漂瓢票表豹飇飄驃"],["f9a1","品稟楓諷豊風馮彼披疲皮被避陂匹弼必泌珌畢疋筆苾馝乏逼下何厦夏廈昰河瑕荷蝦賀遐霞鰕壑學虐謔鶴寒恨悍旱汗漢澣瀚罕翰閑閒限韓割轄函含咸啣喊檻涵緘艦銜陷鹹合哈盒蛤閤闔陜亢伉姮嫦巷恒抗杭桁沆港缸肛航"],["faa1","行降項亥偕咳垓奚孩害懈楷海瀣蟹解該諧邂駭骸劾核倖幸杏荇行享向嚮珦鄕響餉饗香噓墟虛許憲櫶獻軒歇險驗奕爀赫革俔峴弦懸晛泫炫玄玹現眩睍絃絢縣舷衒見賢鉉顯孑穴血頁嫌俠協夾峽挾浹狹脅脇莢鋏頰亨兄刑型"],["fba1","形泂滎瀅灐炯熒珩瑩荊螢衡逈邢鎣馨兮彗惠慧暳蕙蹊醯鞋乎互呼壕壺好岵弧戶扈昊晧毫浩淏湖滸澔濠濩灝狐琥瑚瓠皓祜糊縞胡芦葫蒿虎號蝴護豪鎬頀顥惑或酷婚昏混渾琿魂忽惚笏哄弘汞泓洪烘紅虹訌鴻化和嬅樺火畵"],["fca1","禍禾花華話譁貨靴廓擴攫確碻穫丸喚奐宦幻患換歡晥桓渙煥環紈還驩鰥活滑猾豁闊凰幌徨恍惶愰慌晃晄榥況湟滉潢煌璜皇篁簧荒蝗遑隍黃匯回廻徊恢悔懷晦會檜淮澮灰獪繪膾茴蛔誨賄劃獲宖橫鐄哮嚆孝效斅曉梟涍淆"],["fda1","爻肴酵驍侯候厚后吼喉嗅帿後朽煦珝逅勛勳塤壎焄熏燻薰訓暈薨喧暄煊萱卉喙毁彙徽揮暉煇諱輝麾休携烋畦虧恤譎鷸兇凶匈洶胸黑昕欣炘痕吃屹紇訖欠欽歆吸恰洽翕興僖凞喜噫囍姬嬉希憙憘戱晞曦熙熹熺犧禧稀羲詰"]],require$$6=[["0","\0",127],["a140"," ,、。.‧;:?!︰…‥﹐﹑﹒·﹔﹕﹖﹗|–︱—︳╴︴﹏()︵︶{}︷︸〔〕︹︺【】︻︼《》︽︾〈〉︿﹀「」﹁﹂『』﹃﹄﹙﹚"],["a1a1","﹛﹜﹝﹞‘’“”〝〞‵′#&*※§〃○●△▲◎☆★◇◆□■▽▼㊣℅¯ ̄_ˍ﹉﹊﹍﹎﹋﹌﹟﹠﹡+-×÷±√<>=≦≧≠∞≒≡﹢",4,"~∩∪⊥∠∟⊿㏒㏑∫∮∵∴♀♂⊕⊙↑↓←→↖↗↙↘∥∣/"],["a240","\∕﹨$¥〒¢£%@℃℉﹩﹪﹫㏕㎜㎝㎞㏎㎡㎎㎏㏄°兙兛兞兝兡兣嗧瓩糎▁",7,"▏▎▍▌▋▊▉┼┴┬┤├▔─│▕┌┐└┘╭"],["a2a1","╮╰╯═╞╪╡◢◣◥◤╱╲╳0",9,"Ⅰ",9,"〡",8,"十卄卅A",25,"a",21],["a340","wxyzΑ",16,"Σ",6,"α",16,"σ",6,"ㄅ",10],["a3a1","ㄐ",25,"˙ˉˊˇˋ"],["a3e1","€"],["a440","一乙丁七乃九了二人儿入八几刀刁力匕十卜又三下丈上丫丸凡久么也乞于亡兀刃勺千叉口土士夕大女子孑孓寸小尢尸山川工己已巳巾干廾弋弓才"],["a4a1","丑丐不中丰丹之尹予云井互五亢仁什仃仆仇仍今介仄元允內六兮公冗凶分切刈勻勾勿化匹午升卅卞厄友及反壬天夫太夭孔少尤尺屯巴幻廿弔引心戈戶手扎支文斗斤方日曰月木欠止歹毋比毛氏水火爪父爻片牙牛犬王丙"],["a540","世丕且丘主乍乏乎以付仔仕他仗代令仙仞充兄冉冊冬凹出凸刊加功包匆北匝仟半卉卡占卯卮去可古右召叮叩叨叼司叵叫另只史叱台句叭叻四囚外"],["a5a1","央失奴奶孕它尼巨巧左市布平幼弁弘弗必戊打扔扒扑斥旦朮本未末札正母民氐永汁汀氾犯玄玉瓜瓦甘生用甩田由甲申疋白皮皿目矛矢石示禾穴立丞丟乒乓乩亙交亦亥仿伉伙伊伕伍伐休伏仲件任仰仳份企伋光兇兆先全"],["a640","共再冰列刑划刎刖劣匈匡匠印危吉吏同吊吐吁吋各向名合吃后吆吒因回囝圳地在圭圬圯圩夙多夷夸妄奸妃好她如妁字存宇守宅安寺尖屹州帆并年"],["a6a1","式弛忙忖戎戌戍成扣扛托收早旨旬旭曲曳有朽朴朱朵次此死氖汝汗汙江池汐汕污汛汍汎灰牟牝百竹米糸缶羊羽老考而耒耳聿肉肋肌臣自至臼舌舛舟艮色艾虫血行衣西阡串亨位住佇佗佞伴佛何估佐佑伽伺伸佃佔似但佣"],["a740","作你伯低伶余佝佈佚兌克免兵冶冷別判利刪刨劫助努劬匣即卵吝吭吞吾否呎吧呆呃吳呈呂君吩告吹吻吸吮吵吶吠吼呀吱含吟听囪困囤囫坊坑址坍"],["a7a1","均坎圾坐坏圻壯夾妝妒妨妞妣妙妖妍妤妓妊妥孝孜孚孛完宋宏尬局屁尿尾岐岑岔岌巫希序庇床廷弄弟彤形彷役忘忌志忍忱快忸忪戒我抄抗抖技扶抉扭把扼找批扳抒扯折扮投抓抑抆改攻攸旱更束李杏材村杜杖杞杉杆杠"],["a840","杓杗步每求汞沙沁沈沉沅沛汪決沐汰沌汨沖沒汽沃汲汾汴沆汶沍沔沘沂灶灼災灸牢牡牠狄狂玖甬甫男甸皂盯矣私秀禿究系罕肖肓肝肘肛肚育良芒"],["a8a1","芋芍見角言谷豆豕貝赤走足身車辛辰迂迆迅迄巡邑邢邪邦那酉釆里防阮阱阪阬並乖乳事些亞享京佯依侍佳使佬供例來侃佰併侈佩佻侖佾侏侑佺兔兒兕兩具其典冽函刻券刷刺到刮制剁劾劻卒協卓卑卦卷卸卹取叔受味呵"],["a940","咖呸咕咀呻呷咄咒咆呼咐呱呶和咚呢周咋命咎固垃坷坪坩坡坦坤坼夜奉奇奈奄奔妾妻委妹妮姑姆姐姍始姓姊妯妳姒姅孟孤季宗定官宜宙宛尚屈居"],["a9a1","屆岷岡岸岩岫岱岳帘帚帖帕帛帑幸庚店府底庖延弦弧弩往征彿彼忝忠忽念忿怏怔怯怵怖怪怕怡性怩怫怛或戕房戾所承拉拌拄抿拂抹拒招披拓拔拋拈抨抽押拐拙拇拍抵拚抱拘拖拗拆抬拎放斧於旺昔易昌昆昂明昀昏昕昊"],["aa40","昇服朋杭枋枕東果杳杷枇枝林杯杰板枉松析杵枚枓杼杪杲欣武歧歿氓氛泣注泳沱泌泥河沽沾沼波沫法泓沸泄油況沮泗泅泱沿治泡泛泊沬泯泜泖泠"],["aaa1","炕炎炒炊炙爬爭爸版牧物狀狎狙狗狐玩玨玟玫玥甽疝疙疚的盂盲直知矽社祀祁秉秈空穹竺糾罔羌羋者肺肥肢肱股肫肩肴肪肯臥臾舍芳芝芙芭芽芟芹花芬芥芯芸芣芰芾芷虎虱初表軋迎返近邵邸邱邶采金長門阜陀阿阻附"],["ab40","陂隹雨青非亟亭亮信侵侯便俠俑俏保促侶俘俟俊俗侮俐俄係俚俎俞侷兗冒冑冠剎剃削前剌剋則勇勉勃勁匍南卻厚叛咬哀咨哎哉咸咦咳哇哂咽咪品"],["aba1","哄哈咯咫咱咻咩咧咿囿垂型垠垣垢城垮垓奕契奏奎奐姜姘姿姣姨娃姥姪姚姦威姻孩宣宦室客宥封屎屏屍屋峙峒巷帝帥帟幽庠度建弈弭彥很待徊律徇後徉怒思怠急怎怨恍恰恨恢恆恃恬恫恪恤扁拜挖按拼拭持拮拽指拱拷"],["ac40","拯括拾拴挑挂政故斫施既春昭映昧是星昨昱昤曷柿染柱柔某柬架枯柵柩柯柄柑枴柚查枸柏柞柳枰柙柢柝柒歪殃殆段毒毗氟泉洋洲洪流津洌洱洞洗"],["aca1","活洽派洶洛泵洹洧洸洩洮洵洎洫炫為炳炬炯炭炸炮炤爰牲牯牴狩狠狡玷珊玻玲珍珀玳甚甭畏界畎畋疫疤疥疢疣癸皆皇皈盈盆盃盅省盹相眉看盾盼眇矜砂研砌砍祆祉祈祇禹禺科秒秋穿突竿竽籽紂紅紀紉紇約紆缸美羿耄"],["ad40","耐耍耑耶胖胥胚胃胄背胡胛胎胞胤胝致舢苧范茅苣苛苦茄若茂茉苒苗英茁苜苔苑苞苓苟苯茆虐虹虻虺衍衫要觔計訂訃貞負赴赳趴軍軌述迦迢迪迥"],["ada1","迭迫迤迨郊郎郁郃酋酊重閂限陋陌降面革韋韭音頁風飛食首香乘亳倌倍倣俯倦倥俸倩倖倆值借倚倒們俺倀倔倨俱倡個候倘俳修倭倪俾倫倉兼冤冥冢凍凌准凋剖剜剔剛剝匪卿原厝叟哨唐唁唷哼哥哲唆哺唔哩哭員唉哮哪"],["ae40","哦唧唇哽唏圃圄埂埔埋埃堉夏套奘奚娑娘娜娟娛娓姬娠娣娩娥娌娉孫屘宰害家宴宮宵容宸射屑展屐峭峽峻峪峨峰島崁峴差席師庫庭座弱徒徑徐恙"],["aea1","恣恥恐恕恭恩息悄悟悚悍悔悌悅悖扇拳挈拿捎挾振捕捂捆捏捉挺捐挽挪挫挨捍捌效敉料旁旅時晉晏晃晒晌晅晁書朔朕朗校核案框桓根桂桔栩梳栗桌桑栽柴桐桀格桃株桅栓栘桁殊殉殷氣氧氨氦氤泰浪涕消涇浦浸海浙涓"],["af40","浬涉浮浚浴浩涌涊浹涅浥涔烊烘烤烙烈烏爹特狼狹狽狸狷玆班琉珮珠珪珞畔畝畜畚留疾病症疲疳疽疼疹痂疸皋皰益盍盎眩真眠眨矩砰砧砸砝破砷"],["afa1","砥砭砠砟砲祕祐祠祟祖神祝祗祚秤秣秧租秦秩秘窄窈站笆笑粉紡紗紋紊素索純紐紕級紜納紙紛缺罟羔翅翁耆耘耕耙耗耽耿胱脂胰脅胭胴脆胸胳脈能脊胼胯臭臬舀舐航舫舨般芻茫荒荔荊茸荐草茵茴荏茲茹茶茗荀茱茨荃"],["b040","虔蚊蚪蚓蚤蚩蚌蚣蚜衰衷袁袂衽衹記訐討訌訕訊託訓訖訏訑豈豺豹財貢起躬軒軔軏辱送逆迷退迺迴逃追逅迸邕郡郝郢酒配酌釘針釗釜釙閃院陣陡"],["b0a1","陛陝除陘陞隻飢馬骨高鬥鬲鬼乾偺偽停假偃偌做偉健偶偎偕偵側偷偏倏偯偭兜冕凰剪副勒務勘動匐匏匙匿區匾參曼商啪啦啄啞啡啃啊唱啖問啕唯啤唸售啜唬啣唳啁啗圈國圉域堅堊堆埠埤基堂堵執培夠奢娶婁婉婦婪婀"],["b140","娼婢婚婆婊孰寇寅寄寂宿密尉專將屠屜屝崇崆崎崛崖崢崑崩崔崙崤崧崗巢常帶帳帷康庸庶庵庾張強彗彬彩彫得徙從徘御徠徜恿患悉悠您惋悴惦悽"],["b1a1","情悻悵惜悼惘惕惆惟悸惚惇戚戛扈掠控捲掖探接捷捧掘措捱掩掉掃掛捫推掄授掙採掬排掏掀捻捩捨捺敝敖救教敗啟敏敘敕敔斜斛斬族旋旌旎晝晚晤晨晦晞曹勗望梁梯梢梓梵桿桶梱梧梗械梃棄梭梆梅梔條梨梟梡梂欲殺"],["b240","毫毬氫涎涼淳淙液淡淌淤添淺清淇淋涯淑涮淞淹涸混淵淅淒渚涵淚淫淘淪深淮淨淆淄涪淬涿淦烹焉焊烽烯爽牽犁猜猛猖猓猙率琅琊球理現琍瓠瓶"],["b2a1","瓷甜產略畦畢異疏痔痕疵痊痍皎盔盒盛眷眾眼眶眸眺硫硃硎祥票祭移窒窕笠笨笛第符笙笞笮粒粗粕絆絃統紮紹紼絀細紳組累終紲紱缽羞羚翌翎習耜聊聆脯脖脣脫脩脰脤舂舵舷舶船莎莞莘荸莢莖莽莫莒莊莓莉莠荷荻荼"],["b340","莆莧處彪蛇蛀蚶蛄蚵蛆蛋蚱蚯蛉術袞袈被袒袖袍袋覓規訪訝訣訥許設訟訛訢豉豚販責貫貨貪貧赧赦趾趺軛軟這逍通逗連速逝逐逕逞造透逢逖逛途"],["b3a1","部郭都酗野釵釦釣釧釭釩閉陪陵陳陸陰陴陶陷陬雀雪雩章竟頂頃魚鳥鹵鹿麥麻傢傍傅備傑傀傖傘傚最凱割剴創剩勞勝勛博厥啻喀喧啼喊喝喘喂喜喪喔喇喋喃喳單喟唾喲喚喻喬喱啾喉喫喙圍堯堪場堤堰報堡堝堠壹壺奠"],["b440","婷媚婿媒媛媧孳孱寒富寓寐尊尋就嵌嵐崴嵇巽幅帽幀幃幾廊廁廂廄弼彭復循徨惑惡悲悶惠愜愣惺愕惰惻惴慨惱愎惶愉愀愒戟扉掣掌描揀揩揉揆揍"],["b4a1","插揣提握揖揭揮捶援揪換摒揚揹敞敦敢散斑斐斯普晰晴晶景暑智晾晷曾替期朝棺棕棠棘棗椅棟棵森棧棹棒棲棣棋棍植椒椎棉棚楮棻款欺欽殘殖殼毯氮氯氬港游湔渡渲湧湊渠渥渣減湛湘渤湖湮渭渦湯渴湍渺測湃渝渾滋"],["b540","溉渙湎湣湄湲湩湟焙焚焦焰無然煮焜牌犄犀猶猥猴猩琺琪琳琢琥琵琶琴琯琛琦琨甥甦畫番痢痛痣痙痘痞痠登發皖皓皴盜睏短硝硬硯稍稈程稅稀窘"],["b5a1","窗窖童竣等策筆筐筒答筍筋筏筑粟粥絞結絨絕紫絮絲絡給絢絰絳善翔翕耋聒肅腕腔腋腑腎脹腆脾腌腓腴舒舜菩萃菸萍菠菅萋菁華菱菴著萊菰萌菌菽菲菊萸萎萄菜萇菔菟虛蛟蛙蛭蛔蛛蛤蛐蛞街裁裂袱覃視註詠評詞証詁"],["b640","詔詛詐詆訴診訶詖象貂貯貼貳貽賁費賀貴買貶貿貸越超趁跎距跋跚跑跌跛跆軻軸軼辜逮逵週逸進逶鄂郵鄉郾酣酥量鈔鈕鈣鈉鈞鈍鈐鈇鈑閔閏開閑"],["b6a1","間閒閎隊階隋陽隅隆隍陲隄雁雅雄集雇雯雲韌項順須飧飪飯飩飲飭馮馭黃黍黑亂傭債傲傳僅傾催傷傻傯僇剿剷剽募勦勤勢勣匯嗟嗨嗓嗦嗎嗜嗇嗑嗣嗤嗯嗚嗡嗅嗆嗥嗉園圓塞塑塘塗塚塔填塌塭塊塢塒塋奧嫁嫉嫌媾媽媼"],["b740","媳嫂媲嵩嵯幌幹廉廈弒彙徬微愚意慈感想愛惹愁愈慎慌慄慍愾愴愧愍愆愷戡戢搓搾搞搪搭搽搬搏搜搔損搶搖搗搆敬斟新暗暉暇暈暖暄暘暍會榔業"],["b7a1","楚楷楠楔極椰概楊楨楫楞楓楹榆楝楣楛歇歲毀殿毓毽溢溯滓溶滂源溝滇滅溥溘溼溺溫滑準溜滄滔溪溧溴煎煙煩煤煉照煜煬煦煌煥煞煆煨煖爺牒猷獅猿猾瑯瑚瑕瑟瑞瑁琿瑙瑛瑜當畸瘀痰瘁痲痱痺痿痴痳盞盟睛睫睦睞督"],["b840","睹睪睬睜睥睨睢矮碎碰碗碘碌碉硼碑碓硿祺祿禁萬禽稜稚稠稔稟稞窟窠筷節筠筮筧粱粳粵經絹綑綁綏絛置罩罪署義羨群聖聘肆肄腱腰腸腥腮腳腫"],["b8a1","腹腺腦舅艇蒂葷落萱葵葦葫葉葬葛萼萵葡董葩葭葆虞虜號蛹蜓蜈蜇蜀蛾蛻蜂蜃蜆蜊衙裟裔裙補裘裝裡裊裕裒覜解詫該詳試詩詰誇詼詣誠話誅詭詢詮詬詹詻訾詨豢貊貉賊資賈賄貲賃賂賅跡跟跨路跳跺跪跤跦躲較載軾輊"],["b940","辟農運遊道遂達逼違遐遇遏過遍遑逾遁鄒鄗酬酪酩釉鈷鉗鈸鈽鉀鈾鉛鉋鉤鉑鈴鉉鉍鉅鈹鈿鉚閘隘隔隕雍雋雉雊雷電雹零靖靴靶預頑頓頊頒頌飼飴"],["b9a1","飽飾馳馱馴髡鳩麂鼎鼓鼠僧僮僥僖僭僚僕像僑僱僎僩兢凳劃劂匱厭嗾嘀嘛嘗嗽嘔嘆嘉嘍嘎嗷嘖嘟嘈嘐嗶團圖塵塾境墓墊塹墅塽壽夥夢夤奪奩嫡嫦嫩嫗嫖嫘嫣孵寞寧寡寥實寨寢寤察對屢嶄嶇幛幣幕幗幔廓廖弊彆彰徹慇"],["ba40","愿態慷慢慣慟慚慘慵截撇摘摔撤摸摟摺摑摧搴摭摻敲斡旗旖暢暨暝榜榨榕槁榮槓構榛榷榻榫榴槐槍榭槌榦槃榣歉歌氳漳演滾漓滴漩漾漠漬漏漂漢"],["baa1","滿滯漆漱漸漲漣漕漫漯澈漪滬漁滲滌滷熔熙煽熊熄熒爾犒犖獄獐瑤瑣瑪瑰瑭甄疑瘧瘍瘋瘉瘓盡監瞄睽睿睡磁碟碧碳碩碣禎福禍種稱窪窩竭端管箕箋筵算箝箔箏箸箇箄粹粽精綻綰綜綽綾綠緊綴網綱綺綢綿綵綸維緒緇綬"],["bb40","罰翠翡翟聞聚肇腐膀膏膈膊腿膂臧臺與舔舞艋蓉蒿蓆蓄蒙蒞蒲蒜蓋蒸蓀蓓蒐蒼蓑蓊蜿蜜蜻蜢蜥蜴蜘蝕蜷蜩裳褂裴裹裸製裨褚裯誦誌語誣認誡誓誤"],["bba1","說誥誨誘誑誚誧豪貍貌賓賑賒赫趙趕跼輔輒輕輓辣遠遘遜遣遙遞遢遝遛鄙鄘鄞酵酸酷酴鉸銀銅銘銖鉻銓銜銨鉼銑閡閨閩閣閥閤隙障際雌雒需靼鞅韶頗領颯颱餃餅餌餉駁骯骰髦魁魂鳴鳶鳳麼鼻齊億儀僻僵價儂儈儉儅凜"],["bc40","劇劈劉劍劊勰厲嘮嘻嘹嘲嘿嘴嘩噓噎噗噴嘶嘯嘰墀墟增墳墜墮墩墦奭嬉嫻嬋嫵嬌嬈寮寬審寫層履嶝嶔幢幟幡廢廚廟廝廣廠彈影德徵慶慧慮慝慕憂"],["bca1","慼慰慫慾憧憐憫憎憬憚憤憔憮戮摩摯摹撞撲撈撐撰撥撓撕撩撒撮播撫撚撬撙撢撳敵敷數暮暫暴暱樣樟槨樁樞標槽模樓樊槳樂樅槭樑歐歎殤毅毆漿潼澄潑潦潔澆潭潛潸潮澎潺潰潤澗潘滕潯潠潟熟熬熱熨牖犛獎獗瑩璋璃"],["bd40","瑾璀畿瘠瘩瘟瘤瘦瘡瘢皚皺盤瞎瞇瞌瞑瞋磋磅確磊碾磕碼磐稿稼穀稽稷稻窯窮箭箱範箴篆篇篁箠篌糊締練緯緻緘緬緝編緣線緞緩綞緙緲緹罵罷羯"],["bda1","翩耦膛膜膝膠膚膘蔗蔽蔚蓮蔬蔭蔓蔑蔣蔡蔔蓬蔥蓿蔆螂蝴蝶蝠蝦蝸蝨蝙蝗蝌蝓衛衝褐複褒褓褕褊誼諒談諄誕請諸課諉諂調誰論諍誶誹諛豌豎豬賠賞賦賤賬賭賢賣賜質賡赭趟趣踫踐踝踢踏踩踟踡踞躺輝輛輟輩輦輪輜輞"],["be40","輥適遮遨遭遷鄰鄭鄧鄱醇醉醋醃鋅銻銷鋪銬鋤鋁銳銼鋒鋇鋰銲閭閱霄霆震霉靠鞍鞋鞏頡頫頜颳養餓餒餘駝駐駟駛駑駕駒駙骷髮髯鬧魅魄魷魯鴆鴉"],["bea1","鴃麩麾黎墨齒儒儘儔儐儕冀冪凝劑劓勳噙噫噹噩噤噸噪器噥噱噯噬噢噶壁墾壇壅奮嬝嬴學寰導彊憲憑憩憊懍憶憾懊懈戰擅擁擋撻撼據擄擇擂操撿擒擔撾整曆曉暹曄曇暸樽樸樺橙橫橘樹橄橢橡橋橇樵機橈歙歷氅濂澱澡"],["bf40","濃澤濁澧澳激澹澶澦澠澴熾燉燐燒燈燕熹燎燙燜燃燄獨璜璣璘璟璞瓢甌甍瘴瘸瘺盧盥瞠瞞瞟瞥磨磚磬磧禦積穎穆穌穋窺篙簑築篤篛篡篩篦糕糖縊"],["bfa1","縑縈縛縣縞縝縉縐罹羲翰翱翮耨膳膩膨臻興艘艙蕊蕙蕈蕨蕩蕃蕉蕭蕪蕞螃螟螞螢融衡褪褲褥褫褡親覦諦諺諫諱謀諜諧諮諾謁謂諷諭諳諶諼豫豭貓賴蹄踱踴蹂踹踵輻輯輸輳辨辦遵遴選遲遼遺鄴醒錠錶鋸錳錯錢鋼錫錄錚"],["c040","錐錦錡錕錮錙閻隧隨險雕霎霑霖霍霓霏靛靜靦鞘頰頸頻頷頭頹頤餐館餞餛餡餚駭駢駱骸骼髻髭鬨鮑鴕鴣鴦鴨鴒鴛默黔龍龜優償儡儲勵嚎嚀嚐嚅嚇"],["c0a1","嚏壕壓壑壎嬰嬪嬤孺尷屨嶼嶺嶽嶸幫彌徽應懂懇懦懋戲戴擎擊擘擠擰擦擬擱擢擭斂斃曙曖檀檔檄檢檜櫛檣橾檗檐檠歜殮毚氈濘濱濟濠濛濤濫濯澀濬濡濩濕濮濰燧營燮燦燥燭燬燴燠爵牆獰獲璩環璦璨癆療癌盪瞳瞪瞰瞬"],["c140","瞧瞭矯磷磺磴磯礁禧禪穗窿簇簍篾篷簌篠糠糜糞糢糟糙糝縮績繆縷縲繃縫總縱繅繁縴縹繈縵縿縯罄翳翼聱聲聰聯聳臆臃膺臂臀膿膽臉膾臨舉艱薪"],["c1a1","薄蕾薜薑薔薯薛薇薨薊虧蟀蟑螳蟒蟆螫螻螺蟈蟋褻褶襄褸褽覬謎謗謙講謊謠謝謄謐豁谿豳賺賽購賸賻趨蹉蹋蹈蹊轄輾轂轅輿避遽還邁邂邀鄹醣醞醜鍍鎂錨鍵鍊鍥鍋錘鍾鍬鍛鍰鍚鍔闊闋闌闈闆隱隸雖霜霞鞠韓顆颶餵騁"],["c240","駿鮮鮫鮪鮭鴻鴿麋黏點黜黝黛鼾齋叢嚕嚮壙壘嬸彝懣戳擴擲擾攆擺擻擷斷曜朦檳檬櫃檻檸櫂檮檯歟歸殯瀉瀋濾瀆濺瀑瀏燻燼燾燸獷獵璧璿甕癖癘"],["c2a1","癒瞽瞿瞻瞼礎禮穡穢穠竄竅簫簧簪簞簣簡糧織繕繞繚繡繒繙罈翹翻職聶臍臏舊藏薩藍藐藉薰薺薹薦蟯蟬蟲蟠覆覲觴謨謹謬謫豐贅蹙蹣蹦蹤蹟蹕軀轉轍邇邃邈醫醬釐鎔鎊鎖鎢鎳鎮鎬鎰鎘鎚鎗闔闖闐闕離雜雙雛雞霤鞣鞦"],["c340","鞭韹額顏題顎顓颺餾餿餽餮馥騎髁鬃鬆魏魎魍鯊鯉鯽鯈鯀鵑鵝鵠黠鼕鼬儳嚥壞壟壢寵龐廬懲懷懶懵攀攏曠曝櫥櫝櫚櫓瀛瀟瀨瀚瀝瀕瀘爆爍牘犢獸"],["c3a1","獺璽瓊瓣疇疆癟癡矇礙禱穫穩簾簿簸簽簷籀繫繭繹繩繪羅繳羶羹羸臘藩藝藪藕藤藥藷蟻蠅蠍蟹蟾襠襟襖襞譁譜識證譚譎譏譆譙贈贊蹼蹲躇蹶蹬蹺蹴轔轎辭邊邋醱醮鏡鏑鏟鏃鏈鏜鏝鏖鏢鏍鏘鏤鏗鏨關隴難霪霧靡韜韻類"],["c440","願顛颼饅饉騖騙鬍鯨鯧鯖鯛鶉鵡鵲鵪鵬麒麗麓麴勸嚨嚷嚶嚴嚼壤孀孃孽寶巉懸懺攘攔攙曦朧櫬瀾瀰瀲爐獻瓏癢癥礦礪礬礫竇競籌籃籍糯糰辮繽繼"],["c4a1","纂罌耀臚艦藻藹蘑藺蘆蘋蘇蘊蠔蠕襤覺觸議譬警譯譟譫贏贍躉躁躅躂醴釋鐘鐃鏽闡霰飄饒饑馨騫騰騷騵鰓鰍鹹麵黨鼯齟齣齡儷儸囁囀囂夔屬巍懼懾攝攜斕曩櫻欄櫺殲灌爛犧瓖瓔癩矓籐纏續羼蘗蘭蘚蠣蠢蠡蠟襪襬覽譴"],["c540","護譽贓躊躍躋轟辯醺鐮鐳鐵鐺鐸鐲鐫闢霸霹露響顧顥饗驅驃驀騾髏魔魑鰭鰥鶯鶴鷂鶸麝黯鼙齜齦齧儼儻囈囊囉孿巔巒彎懿攤權歡灑灘玀瓤疊癮癬"],["c5a1","禳籠籟聾聽臟襲襯觼讀贖贗躑躓轡酈鑄鑑鑒霽霾韃韁顫饕驕驍髒鬚鱉鰱鰾鰻鷓鷗鼴齬齪龔囌巖戀攣攫攪曬欐瓚竊籤籣籥纓纖纔臢蘸蘿蠱變邐邏鑣鑠鑤靨顯饜驚驛驗髓體髑鱔鱗鱖鷥麟黴囑壩攬灞癱癲矗罐羈蠶蠹衢讓讒"],["c640","讖艷贛釀鑪靂靈靄韆顰驟鬢魘鱟鷹鷺鹼鹽鼇齷齲廳欖灣籬籮蠻觀躡釁鑲鑰顱饞髖鬣黌灤矚讚鑷韉驢驥纜讜躪釅鑽鑾鑼鱷鱸黷豔鑿鸚爨驪鬱鸛鸞籲"],["c940","乂乜凵匚厂万丌乇亍囗兀屮彳丏冇与丮亓仂仉仈冘勼卬厹圠夃夬尐巿旡殳毌气爿丱丼仨仜仩仡仝仚刌匜卌圢圣夗夯宁宄尒尻屴屳帄庀庂忉戉扐氕"],["c9a1","氶汃氿氻犮犰玊禸肊阞伎优伬仵伔仱伀价伈伝伂伅伢伓伄仴伒冱刓刉刐劦匢匟卍厊吇囡囟圮圪圴夼妀奼妅奻奾奷奿孖尕尥屼屺屻屾巟幵庄异弚彴忕忔忏扜扞扤扡扦扢扙扠扚扥旯旮朾朹朸朻机朿朼朳氘汆汒汜汏汊汔汋"],["ca40","汌灱牞犴犵玎甪癿穵网艸艼芀艽艿虍襾邙邗邘邛邔阢阤阠阣佖伻佢佉体佤伾佧佒佟佁佘伭伳伿佡冏冹刜刞刡劭劮匉卣卲厎厏吰吷吪呔呅吙吜吥吘"],["caa1","吽呏呁吨吤呇囮囧囥坁坅坌坉坋坒夆奀妦妘妠妗妎妢妐妏妧妡宎宒尨尪岍岏岈岋岉岒岊岆岓岕巠帊帎庋庉庌庈庍弅弝彸彶忒忑忐忭忨忮忳忡忤忣忺忯忷忻怀忴戺抃抌抎抏抔抇扱扻扺扰抁抈扷扽扲扴攷旰旴旳旲旵杅杇"],["cb40","杙杕杌杈杝杍杚杋毐氙氚汸汧汫沄沋沏汱汯汩沚汭沇沕沜汦汳汥汻沎灴灺牣犿犽狃狆狁犺狅玕玗玓玔玒町甹疔疕皁礽耴肕肙肐肒肜芐芏芅芎芑芓"],["cba1","芊芃芄豸迉辿邟邡邥邞邧邠阰阨阯阭丳侘佼侅佽侀侇佶佴侉侄佷佌侗佪侚佹侁佸侐侜侔侞侒侂侕佫佮冞冼冾刵刲刳剆刱劼匊匋匼厒厔咇呿咁咑咂咈呫呺呾呥呬呴呦咍呯呡呠咘呣呧呤囷囹坯坲坭坫坱坰坶垀坵坻坳坴坢"],["cc40","坨坽夌奅妵妺姏姎妲姌姁妶妼姃姖妱妽姀姈妴姇孢孥宓宕屄屇岮岤岠岵岯岨岬岟岣岭岢岪岧岝岥岶岰岦帗帔帙弨弢弣弤彔徂彾彽忞忥怭怦怙怲怋"],["cca1","怴怊怗怳怚怞怬怢怍怐怮怓怑怌怉怜戔戽抭抴拑抾抪抶拊抮抳抯抻抩抰抸攽斨斻昉旼昄昒昈旻昃昋昍昅旽昑昐曶朊枅杬枎枒杶杻枘枆构杴枍枌杺枟枑枙枃杽极杸杹枔欥殀歾毞氝沓泬泫泮泙沶泔沭泧沷泐泂沺泃泆泭泲"],["cd40","泒泝沴沊沝沀泞泀洰泍泇沰泹泏泩泑炔炘炅炓炆炄炑炖炂炚炃牪狖狋狘狉狜狒狔狚狌狑玤玡玭玦玢玠玬玝瓝瓨甿畀甾疌疘皯盳盱盰盵矸矼矹矻矺"],["cda1","矷祂礿秅穸穻竻籵糽耵肏肮肣肸肵肭舠芠苀芫芚芘芛芵芧芮芼芞芺芴芨芡芩苂芤苃芶芢虰虯虭虮豖迒迋迓迍迖迕迗邲邴邯邳邰阹阽阼阺陃俍俅俓侲俉俋俁俔俜俙侻侳俛俇俖侺俀侹俬剄剉勀勂匽卼厗厖厙厘咺咡咭咥哏"],["ce40","哃茍咷咮哖咶哅哆咠呰咼咢咾呲哞咰垵垞垟垤垌垗垝垛垔垘垏垙垥垚垕壴复奓姡姞姮娀姱姝姺姽姼姶姤姲姷姛姩姳姵姠姾姴姭宨屌峐峘峌峗峋峛"],["cea1","峞峚峉峇峊峖峓峔峏峈峆峎峟峸巹帡帢帣帠帤庰庤庢庛庣庥弇弮彖徆怷怹恔恲恞恅恓恇恉恛恌恀恂恟怤恄恘恦恮扂扃拏挍挋拵挎挃拫拹挏挌拸拶挀挓挔拺挕拻拰敁敃斪斿昶昡昲昵昜昦昢昳昫昺昝昴昹昮朏朐柁柲柈枺"],["cf40","柜枻柸柘柀枷柅柫柤柟枵柍枳柷柶柮柣柂枹柎柧柰枲柼柆柭柌枮柦柛柺柉柊柃柪柋欨殂殄殶毖毘毠氠氡洨洴洭洟洼洿洒洊泚洳洄洙洺洚洑洀洝浂"],["cfa1","洁洘洷洃洏浀洇洠洬洈洢洉洐炷炟炾炱炰炡炴炵炩牁牉牊牬牰牳牮狊狤狨狫狟狪狦狣玅珌珂珈珅玹玶玵玴珫玿珇玾珃珆玸珋瓬瓮甮畇畈疧疪癹盄眈眃眄眅眊盷盻盺矧矨砆砑砒砅砐砏砎砉砃砓祊祌祋祅祄秕种秏秖秎窀"],["d040","穾竑笀笁籺籸籹籿粀粁紃紈紁罘羑羍羾耇耎耏耔耷胘胇胠胑胈胂胐胅胣胙胜胊胕胉胏胗胦胍臿舡芔苙苾苹茇苨茀苕茺苫苖苴苬苡苲苵茌苻苶苰苪"],["d0a1","苤苠苺苳苭虷虴虼虳衁衎衧衪衩觓訄訇赲迣迡迮迠郱邽邿郕郅邾郇郋郈釔釓陔陏陑陓陊陎倞倅倇倓倢倰倛俵俴倳倷倬俶俷倗倜倠倧倵倯倱倎党冔冓凊凄凅凈凎剡剚剒剞剟剕剢勍匎厞唦哢唗唒哧哳哤唚哿唄唈哫唑唅哱"],["d140","唊哻哷哸哠唎唃唋圁圂埌堲埕埒垺埆垽垼垸垶垿埇埐垹埁夎奊娙娖娭娮娕娏娗娊娞娳孬宧宭宬尃屖屔峬峿峮峱峷崀峹帩帨庨庮庪庬弳弰彧恝恚恧"],["d1a1","恁悢悈悀悒悁悝悃悕悛悗悇悜悎戙扆拲挐捖挬捄捅挶捃揤挹捋捊挼挩捁挴捘捔捙挭捇挳捚捑挸捗捀捈敊敆旆旃旄旂晊晟晇晑朒朓栟栚桉栲栳栻桋桏栖栱栜栵栫栭栯桎桄栴栝栒栔栦栨栮桍栺栥栠欬欯欭欱欴歭肂殈毦毤"],["d240","毨毣毢毧氥浺浣浤浶洍浡涒浘浢浭浯涑涍淯浿涆浞浧浠涗浰浼浟涂涘洯浨涋浾涀涄洖涃浻浽浵涐烜烓烑烝烋缹烢烗烒烞烠烔烍烅烆烇烚烎烡牂牸"],["d2a1","牷牶猀狺狴狾狶狳狻猁珓珙珥珖玼珧珣珩珜珒珛珔珝珚珗珘珨瓞瓟瓴瓵甡畛畟疰痁疻痄痀疿疶疺皊盉眝眛眐眓眒眣眑眕眙眚眢眧砣砬砢砵砯砨砮砫砡砩砳砪砱祔祛祏祜祓祒祑秫秬秠秮秭秪秜秞秝窆窉窅窋窌窊窇竘笐"],["d340","笄笓笅笏笈笊笎笉笒粄粑粊粌粈粍粅紞紝紑紎紘紖紓紟紒紏紌罜罡罞罠罝罛羖羒翃翂翀耖耾耹胺胲胹胵脁胻脀舁舯舥茳茭荄茙荑茥荖茿荁茦茜茢"],["d3a1","荂荎茛茪茈茼荍茖茤茠茷茯茩荇荅荌荓茞茬荋茧荈虓虒蚢蚨蚖蚍蚑蚞蚇蚗蚆蚋蚚蚅蚥蚙蚡蚧蚕蚘蚎蚝蚐蚔衃衄衭衵衶衲袀衱衿衯袃衾衴衼訒豇豗豻貤貣赶赸趵趷趶軑軓迾迵适迿迻逄迼迶郖郠郙郚郣郟郥郘郛郗郜郤酐"],["d440","酎酏釕釢釚陜陟隼飣髟鬯乿偰偪偡偞偠偓偋偝偲偈偍偁偛偊偢倕偅偟偩偫偣偤偆偀偮偳偗偑凐剫剭剬剮勖勓匭厜啵啶唼啍啐唴唪啑啢唶唵唰啒啅"],["d4a1","唌唲啥啎唹啈唭唻啀啋圊圇埻堔埢埶埜埴堀埭埽堈埸堋埳埏堇埮埣埲埥埬埡堎埼堐埧堁堌埱埩埰堍堄奜婠婘婕婧婞娸娵婭婐婟婥婬婓婤婗婃婝婒婄婛婈媎娾婍娹婌婰婩婇婑婖婂婜孲孮寁寀屙崞崋崝崚崠崌崨崍崦崥崏"],["d540","崰崒崣崟崮帾帴庱庴庹庲庳弶弸徛徖徟悊悐悆悾悰悺惓惔惏惤惙惝惈悱惛悷惊悿惃惍惀挲捥掊掂捽掽掞掭掝掗掫掎捯掇掐据掯捵掜捭掮捼掤挻掟"],["d5a1","捸掅掁掑掍捰敓旍晥晡晛晙晜晢朘桹梇梐梜桭桮梮梫楖桯梣梬梩桵桴梲梏桷梒桼桫桲梪梀桱桾梛梖梋梠梉梤桸桻梑梌梊桽欶欳欷欸殑殏殍殎殌氪淀涫涴涳湴涬淩淢涷淶淔渀淈淠淟淖涾淥淜淝淛淴淊涽淭淰涺淕淂淏淉"],["d640","淐淲淓淽淗淍淣涻烺焍烷焗烴焌烰焄烳焐烼烿焆焓焀烸烶焋焂焎牾牻牼牿猝猗猇猑猘猊猈狿猏猞玈珶珸珵琄琁珽琇琀珺珼珿琌琋珴琈畤畣痎痒痏"],["d6a1","痋痌痑痐皏皉盓眹眯眭眱眲眴眳眽眥眻眵硈硒硉硍硊硌砦硅硐祤祧祩祪祣祫祡离秺秸秶秷窏窔窐笵筇笴笥笰笢笤笳笘笪笝笱笫笭笯笲笸笚笣粔粘粖粣紵紽紸紶紺絅紬紩絁絇紾紿絊紻紨罣羕羜羝羛翊翋翍翐翑翇翏翉耟"],["d740","耞耛聇聃聈脘脥脙脛脭脟脬脞脡脕脧脝脢舑舸舳舺舴舲艴莐莣莨莍荺荳莤荴莏莁莕莙荵莔莩荽莃莌莝莛莪莋荾莥莯莈莗莰荿莦莇莮荶莚虙虖蚿蚷"],["d7a1","蛂蛁蛅蚺蚰蛈蚹蚳蚸蛌蚴蚻蚼蛃蚽蚾衒袉袕袨袢袪袚袑袡袟袘袧袙袛袗袤袬袌袓袎覂觖觙觕訰訧訬訞谹谻豜豝豽貥赽赻赹趼跂趹趿跁軘軞軝軜軗軠軡逤逋逑逜逌逡郯郪郰郴郲郳郔郫郬郩酖酘酚酓酕釬釴釱釳釸釤釹釪"],["d840","釫釷釨釮镺閆閈陼陭陫陱陯隿靪頄飥馗傛傕傔傞傋傣傃傌傎傝偨傜傒傂傇兟凔匒匑厤厧喑喨喥喭啷噅喢喓喈喏喵喁喣喒喤啽喌喦啿喕喡喎圌堩堷"],["d8a1","堙堞堧堣堨埵塈堥堜堛堳堿堶堮堹堸堭堬堻奡媯媔媟婺媢媞婸媦婼媥媬媕媮娷媄媊媗媃媋媩婻婽媌媜媏媓媝寪寍寋寔寑寊寎尌尰崷嵃嵫嵁嵋崿崵嵑嵎嵕崳崺嵒崽崱嵙嵂崹嵉崸崼崲崶嵀嵅幄幁彘徦徥徫惉悹惌惢惎惄愔"],["d940","惲愊愖愅惵愓惸惼惾惁愃愘愝愐惿愄愋扊掔掱掰揎揥揨揯揃撝揳揊揠揶揕揲揵摡揟掾揝揜揄揘揓揂揇揌揋揈揰揗揙攲敧敪敤敜敨敥斌斝斞斮旐旒"],["d9a1","晼晬晻暀晱晹晪晲朁椌棓椄棜椪棬棪棱椏棖棷棫棤棶椓椐棳棡椇棌椈楰梴椑棯棆椔棸棐棽棼棨椋椊椗棎棈棝棞棦棴棑椆棔棩椕椥棇欹欻欿欼殔殗殙殕殽毰毲毳氰淼湆湇渟湉溈渼渽湅湢渫渿湁湝湳渜渳湋湀湑渻渃渮湞"],["da40","湨湜湡渱渨湠湱湫渹渢渰湓湥渧湸湤湷湕湹湒湦渵渶湚焠焞焯烻焮焱焣焥焢焲焟焨焺焛牋牚犈犉犆犅犋猒猋猰猢猱猳猧猲猭猦猣猵猌琮琬琰琫琖"],["daa1","琚琡琭琱琤琣琝琩琠琲瓻甯畯畬痧痚痡痦痝痟痤痗皕皒盚睆睇睄睍睅睊睎睋睌矞矬硠硤硥硜硭硱硪确硰硩硨硞硢祴祳祲祰稂稊稃稌稄窙竦竤筊笻筄筈筌筎筀筘筅粢粞粨粡絘絯絣絓絖絧絪絏絭絜絫絒絔絩絑絟絎缾缿罥"],["db40","罦羢羠羡翗聑聏聐胾胔腃腊腒腏腇脽腍脺臦臮臷臸臹舄舼舽舿艵茻菏菹萣菀菨萒菧菤菼菶萐菆菈菫菣莿萁菝菥菘菿菡菋菎菖菵菉萉萏菞萑萆菂菳"],["dba1","菕菺菇菑菪萓菃菬菮菄菻菗菢萛菛菾蛘蛢蛦蛓蛣蛚蛪蛝蛫蛜蛬蛩蛗蛨蛑衈衖衕袺裗袹袸裀袾袶袼袷袽袲褁裉覕覘覗觝觚觛詎詍訹詙詀詗詘詄詅詒詈詑詊詌詏豟貁貀貺貾貰貹貵趄趀趉跘跓跍跇跖跜跏跕跙跈跗跅軯軷軺"],["dc40","軹軦軮軥軵軧軨軶軫軱軬軴軩逭逴逯鄆鄬鄄郿郼鄈郹郻鄁鄀鄇鄅鄃酡酤酟酢酠鈁鈊鈥鈃鈚鈦鈏鈌鈀鈒釿釽鈆鈄鈧鈂鈜鈤鈙鈗鈅鈖镻閍閌閐隇陾隈"],["dca1","隉隃隀雂雈雃雱雰靬靰靮頇颩飫鳦黹亃亄亶傽傿僆傮僄僊傴僈僂傰僁傺傱僋僉傶傸凗剺剸剻剼嗃嗛嗌嗐嗋嗊嗝嗀嗔嗄嗩喿嗒喍嗏嗕嗢嗖嗈嗲嗍嗙嗂圔塓塨塤塏塍塉塯塕塎塝塙塥塛堽塣塱壼嫇嫄嫋媺媸媱媵媰媿嫈媻嫆"],["dd40","媷嫀嫊媴媶嫍媹媐寖寘寙尟尳嵱嵣嵊嵥嵲嵬嵞嵨嵧嵢巰幏幎幊幍幋廅廌廆廋廇彀徯徭惷慉慊愫慅愶愲愮慆愯慏愩慀戠酨戣戥戤揅揱揫搐搒搉搠搤"],["dda1","搳摃搟搕搘搹搷搢搣搌搦搰搨摁搵搯搊搚摀搥搧搋揧搛搮搡搎敯斒旓暆暌暕暐暋暊暙暔晸朠楦楟椸楎楢楱椿楅楪椹楂楗楙楺楈楉椵楬椳椽楥棰楸椴楩楀楯楄楶楘楁楴楌椻楋椷楜楏楑椲楒椯楻椼歆歅歃歂歈歁殛嗀毻毼"],["de40","毹毷毸溛滖滈溏滀溟溓溔溠溱溹滆滒溽滁溞滉溷溰滍溦滏溲溾滃滜滘溙溒溎溍溤溡溿溳滐滊溗溮溣煇煔煒煣煠煁煝煢煲煸煪煡煂煘煃煋煰煟煐煓"],["dea1","煄煍煚牏犍犌犑犐犎猼獂猻猺獀獊獉瑄瑊瑋瑒瑑瑗瑀瑏瑐瑎瑂瑆瑍瑔瓡瓿瓾瓽甝畹畷榃痯瘏瘃痷痾痼痹痸瘐痻痶痭痵痽皙皵盝睕睟睠睒睖睚睩睧睔睙睭矠碇碚碔碏碄碕碅碆碡碃硹碙碀碖硻祼禂祽祹稑稘稙稒稗稕稢稓"],["df40","稛稐窣窢窞竫筦筤筭筴筩筲筥筳筱筰筡筸筶筣粲粴粯綈綆綀綍絿綅絺綎絻綃絼綌綔綄絽綒罭罫罧罨罬羦羥羧翛翜耡腤腠腷腜腩腛腢腲朡腞腶腧腯"],["dfa1","腄腡舝艉艄艀艂艅蓱萿葖葶葹蒏蒍葥葑葀蒆葧萰葍葽葚葙葴葳葝蔇葞萷萺萴葺葃葸萲葅萩菙葋萯葂萭葟葰萹葎葌葒葯蓅蒎萻葇萶萳葨葾葄萫葠葔葮葐蜋蜄蛷蜌蛺蛖蛵蝍蛸蜎蜉蜁蛶蜍蜅裖裋裍裎裞裛裚裌裐覅覛觟觥觤"],["e040","觡觠觢觜触詶誆詿詡訿詷誂誄詵誃誁詴詺谼豋豊豥豤豦貆貄貅賌赨赩趑趌趎趏趍趓趔趐趒跰跠跬跱跮跐跩跣跢跧跲跫跴輆軿輁輀輅輇輈輂輋遒逿"],["e0a1","遄遉逽鄐鄍鄏鄑鄖鄔鄋鄎酮酯鉈鉒鈰鈺鉦鈳鉥鉞銃鈮鉊鉆鉭鉬鉏鉠鉧鉯鈶鉡鉰鈱鉔鉣鉐鉲鉎鉓鉌鉖鈲閟閜閞閛隒隓隑隗雎雺雽雸雵靳靷靸靲頏頍頎颬飶飹馯馲馰馵骭骫魛鳪鳭鳧麀黽僦僔僗僨僳僛僪僝僤僓僬僰僯僣僠"],["e140","凘劀劁勩勫匰厬嘧嘕嘌嘒嗼嘏嘜嘁嘓嘂嗺嘝嘄嗿嗹墉塼墐墘墆墁塿塴墋塺墇墑墎塶墂墈塻墔墏壾奫嫜嫮嫥嫕嫪嫚嫭嫫嫳嫢嫠嫛嫬嫞嫝嫙嫨嫟孷寠"],["e1a1","寣屣嶂嶀嵽嶆嵺嶁嵷嶊嶉嶈嵾嵼嶍嵹嵿幘幙幓廘廑廗廎廜廕廙廒廔彄彃彯徶愬愨慁慞慱慳慒慓慲慬憀慴慔慺慛慥愻慪慡慖戩戧戫搫摍摛摝摴摶摲摳摽摵摦撦摎撂摞摜摋摓摠摐摿搿摬摫摙摥摷敳斠暡暠暟朅朄朢榱榶槉"],["e240","榠槎榖榰榬榼榑榙榎榧榍榩榾榯榿槄榽榤槔榹槊榚槏榳榓榪榡榞槙榗榐槂榵榥槆歊歍歋殞殟殠毃毄毾滎滵滱漃漥滸漷滻漮漉潎漙漚漧漘漻漒滭漊"],["e2a1","漶潳滹滮漭潀漰漼漵滫漇漎潃漅滽滶漹漜滼漺漟漍漞漈漡熇熐熉熀熅熂熏煻熆熁熗牄牓犗犕犓獃獍獑獌瑢瑳瑱瑵瑲瑧瑮甀甂甃畽疐瘖瘈瘌瘕瘑瘊瘔皸瞁睼瞅瞂睮瞀睯睾瞃碲碪碴碭碨硾碫碞碥碠碬碢碤禘禊禋禖禕禔禓"],["e340","禗禈禒禐稫穊稰稯稨稦窨窫窬竮箈箜箊箑箐箖箍箌箛箎箅箘劄箙箤箂粻粿粼粺綧綷緂綣綪緁緀緅綝緎緄緆緋緌綯綹綖綼綟綦綮綩綡緉罳翢翣翥翞"],["e3a1","耤聝聜膉膆膃膇膍膌膋舕蒗蒤蒡蒟蒺蓎蓂蒬蒮蒫蒹蒴蓁蓍蒪蒚蒱蓐蒝蒧蒻蒢蒔蓇蓌蒛蒩蒯蒨蓖蒘蒶蓏蒠蓗蓔蓒蓛蒰蒑虡蜳蜣蜨蝫蝀蜮蜞蜡蜙蜛蝃蜬蝁蜾蝆蜠蜲蜪蜭蜼蜒蜺蜱蜵蝂蜦蜧蜸蜤蜚蜰蜑裷裧裱裲裺裾裮裼裶裻"],["e440","裰裬裫覝覡覟覞觩觫觨誫誙誋誒誏誖谽豨豩賕賏賗趖踉踂跿踍跽踊踃踇踆踅跾踀踄輐輑輎輍鄣鄜鄠鄢鄟鄝鄚鄤鄡鄛酺酲酹酳銥銤鉶銛鉺銠銔銪銍"],["e4a1","銦銚銫鉹銗鉿銣鋮銎銂銕銢鉽銈銡銊銆銌銙銧鉾銇銩銝銋鈭隞隡雿靘靽靺靾鞃鞀鞂靻鞄鞁靿韎韍頖颭颮餂餀餇馝馜駃馹馻馺駂馽駇骱髣髧鬾鬿魠魡魟鳱鳲鳵麧僿儃儰僸儆儇僶僾儋儌僽儊劋劌勱勯噈噂噌嘵噁噊噉噆噘"],["e540","噚噀嘳嘽嘬嘾嘸嘪嘺圚墫墝墱墠墣墯墬墥墡壿嫿嫴嫽嫷嫶嬃嫸嬂嫹嬁嬇嬅嬏屧嶙嶗嶟嶒嶢嶓嶕嶠嶜嶡嶚嶞幩幝幠幜緳廛廞廡彉徲憋憃慹憱憰憢憉"],["e5a1","憛憓憯憭憟憒憪憡憍慦憳戭摮摰撖撠撅撗撜撏撋撊撌撣撟摨撱撘敶敺敹敻斲斳暵暰暩暲暷暪暯樀樆樗槥槸樕槱槤樠槿槬槢樛樝槾樧槲槮樔槷槧橀樈槦槻樍槼槫樉樄樘樥樏槶樦樇槴樖歑殥殣殢殦氁氀毿氂潁漦潾澇濆澒"],["e640","澍澉澌潢潏澅潚澖潶潬澂潕潲潒潐潗澔澓潝漀潡潫潽潧澐潓澋潩潿澕潣潷潪潻熲熯熛熰熠熚熩熵熝熥熞熤熡熪熜熧熳犘犚獘獒獞獟獠獝獛獡獚獙"],["e6a1","獢璇璉璊璆璁瑽璅璈瑼瑹甈甇畾瘥瘞瘙瘝瘜瘣瘚瘨瘛皜皝皞皛瞍瞏瞉瞈磍碻磏磌磑磎磔磈磃磄磉禚禡禠禜禢禛歶稹窲窴窳箷篋箾箬篎箯箹篊箵糅糈糌糋緷緛緪緧緗緡縃緺緦緶緱緰緮緟罶羬羰羭翭翫翪翬翦翨聤聧膣膟"],["e740","膞膕膢膙膗舖艏艓艒艐艎艑蔤蔻蔏蔀蔩蔎蔉蔍蔟蔊蔧蔜蓻蔫蓺蔈蔌蓴蔪蓲蔕蓷蓫蓳蓼蔒蓪蓩蔖蓾蔨蔝蔮蔂蓽蔞蓶蔱蔦蓧蓨蓰蓯蓹蔘蔠蔰蔋蔙蔯虢"],["e7a1","蝖蝣蝤蝷蟡蝳蝘蝔蝛蝒蝡蝚蝑蝞蝭蝪蝐蝎蝟蝝蝯蝬蝺蝮蝜蝥蝏蝻蝵蝢蝧蝩衚褅褌褔褋褗褘褙褆褖褑褎褉覢覤覣觭觰觬諏諆誸諓諑諔諕誻諗誾諀諅諘諃誺誽諙谾豍貏賥賟賙賨賚賝賧趠趜趡趛踠踣踥踤踮踕踛踖踑踙踦踧"],["e840","踔踒踘踓踜踗踚輬輤輘輚輠輣輖輗遳遰遯遧遫鄯鄫鄩鄪鄲鄦鄮醅醆醊醁醂醄醀鋐鋃鋄鋀鋙銶鋏鋱鋟鋘鋩鋗鋝鋌鋯鋂鋨鋊鋈鋎鋦鋍鋕鋉鋠鋞鋧鋑鋓"],["e8a1","銵鋡鋆銴镼閬閫閮閰隤隢雓霅霈霂靚鞊鞎鞈韐韏頞頝頦頩頨頠頛頧颲餈飺餑餔餖餗餕駜駍駏駓駔駎駉駖駘駋駗駌骳髬髫髳髲髱魆魃魧魴魱魦魶魵魰魨魤魬鳼鳺鳽鳿鳷鴇鴀鳹鳻鴈鴅鴄麃黓鼏鼐儜儓儗儚儑凞匴叡噰噠噮"],["e940","噳噦噣噭噲噞噷圜圛壈墽壉墿墺壂墼壆嬗嬙嬛嬡嬔嬓嬐嬖嬨嬚嬠嬞寯嶬嶱嶩嶧嶵嶰嶮嶪嶨嶲嶭嶯嶴幧幨幦幯廩廧廦廨廥彋徼憝憨憖懅憴懆懁懌憺"],["e9a1","憿憸憌擗擖擐擏擉撽撉擃擛擳擙攳敿敼斢曈暾曀曊曋曏暽暻暺曌朣樴橦橉橧樲橨樾橝橭橶橛橑樨橚樻樿橁橪橤橐橏橔橯橩橠樼橞橖橕橍橎橆歕歔歖殧殪殫毈毇氄氃氆澭濋澣濇澼濎濈潞濄澽澞濊澨瀄澥澮澺澬澪濏澿澸"],["ea40","澢濉澫濍澯澲澰燅燂熿熸燖燀燁燋燔燊燇燏熽燘熼燆燚燛犝犞獩獦獧獬獥獫獪瑿璚璠璔璒璕璡甋疀瘯瘭瘱瘽瘳瘼瘵瘲瘰皻盦瞚瞝瞡瞜瞛瞢瞣瞕瞙"],["eaa1","瞗磝磩磥磪磞磣磛磡磢磭磟磠禤穄穈穇窶窸窵窱窷篞篣篧篝篕篥篚篨篹篔篪篢篜篫篘篟糒糔糗糐糑縒縡縗縌縟縠縓縎縜縕縚縢縋縏縖縍縔縥縤罃罻罼罺羱翯耪耩聬膱膦膮膹膵膫膰膬膴膲膷膧臲艕艖艗蕖蕅蕫蕍蕓蕡蕘"],["eb40","蕀蕆蕤蕁蕢蕄蕑蕇蕣蔾蕛蕱蕎蕮蕵蕕蕧蕠薌蕦蕝蕔蕥蕬虣虥虤螛螏螗螓螒螈螁螖螘蝹螇螣螅螐螑螝螄螔螜螚螉褞褦褰褭褮褧褱褢褩褣褯褬褟觱諠"],["eba1","諢諲諴諵諝謔諤諟諰諈諞諡諨諿諯諻貑貒貐賵賮賱賰賳赬赮趥趧踳踾踸蹀蹅踶踼踽蹁踰踿躽輶輮輵輲輹輷輴遶遹遻邆郺鄳鄵鄶醓醐醑醍醏錧錞錈錟錆錏鍺錸錼錛錣錒錁鍆錭錎錍鋋錝鋺錥錓鋹鋷錴錂錤鋿錩錹錵錪錔錌"],["ec40","錋鋾錉錀鋻錖閼闍閾閹閺閶閿閵閽隩雔霋霒霐鞙鞗鞔韰韸頵頯頲餤餟餧餩馞駮駬駥駤駰駣駪駩駧骹骿骴骻髶髺髹髷鬳鮀鮅鮇魼魾魻鮂鮓鮒鮐魺鮕"],["eca1","魽鮈鴥鴗鴠鴞鴔鴩鴝鴘鴢鴐鴙鴟麈麆麇麮麭黕黖黺鼒鼽儦儥儢儤儠儩勴嚓嚌嚍嚆嚄嚃噾嚂噿嚁壖壔壏壒嬭嬥嬲嬣嬬嬧嬦嬯嬮孻寱寲嶷幬幪徾徻懃憵憼懧懠懥懤懨懞擯擩擣擫擤擨斁斀斶旚曒檍檖檁檥檉檟檛檡檞檇檓檎"],["ed40","檕檃檨檤檑橿檦檚檅檌檒歛殭氉濌澩濴濔濣濜濭濧濦濞濲濝濢濨燡燱燨燲燤燰燢獳獮獯璗璲璫璐璪璭璱璥璯甐甑甒甏疄癃癈癉癇皤盩瞵瞫瞲瞷瞶"],["eda1","瞴瞱瞨矰磳磽礂磻磼磲礅磹磾礄禫禨穜穛穖穘穔穚窾竀竁簅簏篲簀篿篻簎篴簋篳簂簉簃簁篸篽簆篰篱簐簊糨縭縼繂縳顈縸縪繉繀繇縩繌縰縻縶繄縺罅罿罾罽翴翲耬膻臄臌臊臅臇膼臩艛艚艜薃薀薏薧薕薠薋薣蕻薤薚薞"],["ee40","蕷蕼薉薡蕺蕸蕗薎薖薆薍薙薝薁薢薂薈薅蕹蕶薘薐薟虨螾螪螭蟅螰螬螹螵螼螮蟉蟃蟂蟌螷螯蟄蟊螴螶螿螸螽蟞螲褵褳褼褾襁襒褷襂覭覯覮觲觳謞"],["eea1","謘謖謑謅謋謢謏謒謕謇謍謈謆謜謓謚豏豰豲豱豯貕貔賹赯蹎蹍蹓蹐蹌蹇轃轀邅遾鄸醚醢醛醙醟醡醝醠鎡鎃鎯鍤鍖鍇鍼鍘鍜鍶鍉鍐鍑鍠鍭鎏鍌鍪鍹鍗鍕鍒鍏鍱鍷鍻鍡鍞鍣鍧鎀鍎鍙闇闀闉闃闅閷隮隰隬霠霟霘霝霙鞚鞡鞜"],["ef40","鞞鞝韕韔韱顁顄顊顉顅顃餥餫餬餪餳餲餯餭餱餰馘馣馡騂駺駴駷駹駸駶駻駽駾駼騃骾髾髽鬁髼魈鮚鮨鮞鮛鮦鮡鮥鮤鮆鮢鮠鮯鴳鵁鵧鴶鴮鴯鴱鴸鴰"],["efa1","鵅鵂鵃鴾鴷鵀鴽翵鴭麊麉麍麰黈黚黻黿鼤鼣鼢齔龠儱儭儮嚘嚜嚗嚚嚝嚙奰嬼屩屪巀幭幮懘懟懭懮懱懪懰懫懖懩擿攄擽擸攁攃擼斔旛曚曛曘櫅檹檽櫡櫆檺檶檷櫇檴檭歞毉氋瀇瀌瀍瀁瀅瀔瀎濿瀀濻瀦濼濷瀊爁燿燹爃燽獶"],["f040","璸瓀璵瓁璾璶璻瓂甔甓癜癤癙癐癓癗癚皦皽盬矂瞺磿礌礓礔礉礐礒礑禭禬穟簜簩簙簠簟簭簝簦簨簢簥簰繜繐繖繣繘繢繟繑繠繗繓羵羳翷翸聵臑臒"],["f0a1","臐艟艞薴藆藀藃藂薳薵薽藇藄薿藋藎藈藅薱薶藒蘤薸薷薾虩蟧蟦蟢蟛蟫蟪蟥蟟蟳蟤蟔蟜蟓蟭蟘蟣螤蟗蟙蠁蟴蟨蟝襓襋襏襌襆襐襑襉謪謧謣謳謰謵譇謯謼謾謱謥謷謦謶謮謤謻謽謺豂豵貙貘貗賾贄贂贀蹜蹢蹠蹗蹖蹞蹥蹧"],["f140","蹛蹚蹡蹝蹩蹔轆轇轈轋鄨鄺鄻鄾醨醥醧醯醪鎵鎌鎒鎷鎛鎝鎉鎧鎎鎪鎞鎦鎕鎈鎙鎟鎍鎱鎑鎲鎤鎨鎴鎣鎥闒闓闑隳雗雚巂雟雘雝霣霢霥鞬鞮鞨鞫鞤鞪"],["f1a1","鞢鞥韗韙韖韘韺顐顑顒颸饁餼餺騏騋騉騍騄騑騊騅騇騆髀髜鬈鬄鬅鬩鬵魊魌魋鯇鯆鯃鮿鯁鮵鮸鯓鮶鯄鮹鮽鵜鵓鵏鵊鵛鵋鵙鵖鵌鵗鵒鵔鵟鵘鵚麎麌黟鼁鼀鼖鼥鼫鼪鼩鼨齌齕儴儵劖勷厴嚫嚭嚦嚧嚪嚬壚壝壛夒嬽嬾嬿巃幰"],["f240","徿懻攇攐攍攉攌攎斄旞旝曞櫧櫠櫌櫑櫙櫋櫟櫜櫐櫫櫏櫍櫞歠殰氌瀙瀧瀠瀖瀫瀡瀢瀣瀩瀗瀤瀜瀪爌爊爇爂爅犥犦犤犣犡瓋瓅璷瓃甖癠矉矊矄矱礝礛"],["f2a1","礡礜礗礞禰穧穨簳簼簹簬簻糬糪繶繵繸繰繷繯繺繲繴繨罋罊羃羆羷翽翾聸臗臕艤艡艣藫藱藭藙藡藨藚藗藬藲藸藘藟藣藜藑藰藦藯藞藢蠀蟺蠃蟶蟷蠉蠌蠋蠆蟼蠈蟿蠊蠂襢襚襛襗襡襜襘襝襙覈覷覶觶譐譈譊譀譓譖譔譋譕"],["f340","譑譂譒譗豃豷豶貚贆贇贉趬趪趭趫蹭蹸蹳蹪蹯蹻軂轒轑轏轐轓辴酀鄿醰醭鏞鏇鏏鏂鏚鏐鏹鏬鏌鏙鎩鏦鏊鏔鏮鏣鏕鏄鏎鏀鏒鏧镽闚闛雡霩霫霬霨霦"],["f3a1","鞳鞷鞶韝韞韟顜顙顝顗颿颽颻颾饈饇饃馦馧騚騕騥騝騤騛騢騠騧騣騞騜騔髂鬋鬊鬎鬌鬷鯪鯫鯠鯞鯤鯦鯢鯰鯔鯗鯬鯜鯙鯥鯕鯡鯚鵷鶁鶊鶄鶈鵱鶀鵸鶆鶋鶌鵽鵫鵴鵵鵰鵩鶅鵳鵻鶂鵯鵹鵿鶇鵨麔麑黀黼鼭齀齁齍齖齗齘匷嚲"],["f440","嚵嚳壣孅巆巇廮廯忀忁懹攗攖攕攓旟曨曣曤櫳櫰櫪櫨櫹櫱櫮櫯瀼瀵瀯瀷瀴瀱灂瀸瀿瀺瀹灀瀻瀳灁爓爔犨獽獼璺皫皪皾盭矌矎矏矍矲礥礣礧礨礤礩"],["f4a1","禲穮穬穭竷籉籈籊籇籅糮繻繾纁纀羺翿聹臛臙舋艨艩蘢藿蘁藾蘛蘀藶蘄蘉蘅蘌藽蠙蠐蠑蠗蠓蠖襣襦覹觷譠譪譝譨譣譥譧譭趮躆躈躄轙轖轗轕轘轚邍酃酁醷醵醲醳鐋鐓鏻鐠鐏鐔鏾鐕鐐鐨鐙鐍鏵鐀鏷鐇鐎鐖鐒鏺鐉鏸鐊鏿"],["f540","鏼鐌鏶鐑鐆闞闠闟霮霯鞹鞻韽韾顠顢顣顟飁飂饐饎饙饌饋饓騲騴騱騬騪騶騩騮騸騭髇髊髆鬐鬒鬑鰋鰈鯷鰅鰒鯸鱀鰇鰎鰆鰗鰔鰉鶟鶙鶤鶝鶒鶘鶐鶛"],["f5a1","鶠鶔鶜鶪鶗鶡鶚鶢鶨鶞鶣鶿鶩鶖鶦鶧麙麛麚黥黤黧黦鼰鼮齛齠齞齝齙龑儺儹劘劗囃嚽嚾孈孇巋巏廱懽攛欂櫼欃櫸欀灃灄灊灈灉灅灆爝爚爙獾甗癪矐礭礱礯籔籓糲纊纇纈纋纆纍罍羻耰臝蘘蘪蘦蘟蘣蘜蘙蘧蘮蘡蘠蘩蘞蘥"],["f640","蠩蠝蠛蠠蠤蠜蠫衊襭襩襮襫觺譹譸譅譺譻贐贔趯躎躌轞轛轝酆酄酅醹鐿鐻鐶鐩鐽鐼鐰鐹鐪鐷鐬鑀鐱闥闤闣霵霺鞿韡顤飉飆飀饘饖騹騽驆驄驂驁騺"],["f6a1","騿髍鬕鬗鬘鬖鬺魒鰫鰝鰜鰬鰣鰨鰩鰤鰡鶷鶶鶼鷁鷇鷊鷏鶾鷅鷃鶻鶵鷎鶹鶺鶬鷈鶱鶭鷌鶳鷍鶲鹺麜黫黮黭鼛鼘鼚鼱齎齥齤龒亹囆囅囋奱孋孌巕巑廲攡攠攦攢欋欈欉氍灕灖灗灒爞爟犩獿瓘瓕瓙瓗癭皭礵禴穰穱籗籜籙籛籚"],["f740","糴糱纑罏羇臞艫蘴蘵蘳蘬蘲蘶蠬蠨蠦蠪蠥襱覿覾觻譾讄讂讆讅譿贕躕躔躚躒躐躖躗轠轢酇鑌鑐鑊鑋鑏鑇鑅鑈鑉鑆霿韣顪顩飋饔饛驎驓驔驌驏驈驊"],["f7a1","驉驒驐髐鬙鬫鬻魖魕鱆鱈鰿鱄鰹鰳鱁鰼鰷鰴鰲鰽鰶鷛鷒鷞鷚鷋鷐鷜鷑鷟鷩鷙鷘鷖鷵鷕鷝麶黰鼵鼳鼲齂齫龕龢儽劙壨壧奲孍巘蠯彏戁戃戄攩攥斖曫欑欒欏毊灛灚爢玂玁玃癰矔籧籦纕艬蘺虀蘹蘼蘱蘻蘾蠰蠲蠮蠳襶襴襳觾"],["f840","讌讎讋讈豅贙躘轤轣醼鑢鑕鑝鑗鑞韄韅頀驖驙鬞鬟鬠鱒鱘鱐鱊鱍鱋鱕鱙鱌鱎鷻鷷鷯鷣鷫鷸鷤鷶鷡鷮鷦鷲鷰鷢鷬鷴鷳鷨鷭黂黐黲黳鼆鼜鼸鼷鼶齃齏"],["f8a1","齱齰齮齯囓囍孎屭攭曭曮欓灟灡灝灠爣瓛瓥矕礸禷禶籪纗羉艭虃蠸蠷蠵衋讔讕躞躟躠躝醾醽釂鑫鑨鑩雥靆靃靇韇韥驞髕魙鱣鱧鱦鱢鱞鱠鸂鷾鸇鸃鸆鸅鸀鸁鸉鷿鷽鸄麠鼞齆齴齵齶囔攮斸欘欙欗欚灢爦犪矘矙礹籩籫糶纚"],["f940","纘纛纙臠臡虆虇虈襹襺襼襻觿讘讙躥躤躣鑮鑭鑯鑱鑳靉顲饟鱨鱮鱭鸋鸍鸐鸏鸒鸑麡黵鼉齇齸齻齺齹圞灦籯蠼趲躦釃鑴鑸鑶鑵驠鱴鱳鱱鱵鸔鸓黶鼊"],["f9a1","龤灨灥糷虪蠾蠽蠿讞貜躩軉靋顳顴飌饡馫驤驦驧鬤鸕鸗齈戇欞爧虌躨钂钀钁驩驨鬮鸙爩虋讟钃鱹麷癵驫鱺鸝灩灪麤齾齉龘碁銹裏墻恒粧嫺╔╦╗╠╬╣╚╩╝╒╤╕╞╪╡╘╧╛╓╥╖╟╫╢╙╨╜║═╭╮╰╯▓"]],require$$7=[["8740","䏰䰲䘃䖦䕸𧉧䵷䖳𧲱䳢𧳅㮕䜶䝄䱇䱀𤊿𣘗𧍒𦺋𧃒䱗𪍑䝏䗚䲅𧱬䴇䪤䚡𦬣爥𥩔𡩣𣸆𣽡晍囻"],["8767","綕夝𨮹㷴霴𧯯寛𡵞媤㘥𩺰嫑宷峼杮薓𩥅瑡璝㡵𡵓𣚞𦀡㻬"],["87a1","𥣞㫵竼龗𤅡𨤍𣇪𠪊𣉞䌊蒄龖鐯䤰蘓墖靊鈘秐稲晠権袝瑌篅枂稬剏遆㓦珄𥶹瓆鿇垳䤯呌䄱𣚎堘穲𧭥讏䚮𦺈䆁𥶙箮𢒼鿈𢓁𢓉𢓌鿉蔄𣖻䂴鿊䓡𪷿拁灮鿋"],["8840","㇀",4,"𠄌㇅𠃑𠃍㇆㇇𠃋𡿨㇈𠃊㇉㇊㇋㇌𠄎㇍㇎ĀÁǍÀĒÉĚÈŌÓǑÒÊ̄ẾÊ̌ỀÊāáǎàɑēéěèīíǐìōóǒòūúǔùǖǘǚ"],["88a1","ǜüê̄ếê̌ềêɡ⏚⏛"],["8940","𪎩𡅅"],["8943","攊"],["8946","丽滝鵎釟"],["894c","𧜵撑会伨侨兖兴农凤务动医华发变团声处备夲头学实実岚庆总斉柾栄桥济炼电纤纬纺织经统缆缷艺苏药视设询车轧轮"],["89a1","琑糼緍楆竉刧"],["89ab","醌碸酞肼"],["89b0","贋胶𠧧"],["89b5","肟黇䳍鷉鸌䰾𩷶𧀎鸊𪄳㗁"],["89c1","溚舾甙"],["89c5","䤑马骏龙禇𨑬𡷊𠗐𢫦两亁亀亇亿仫伷㑌侽㹈倃傈㑽㒓㒥円夅凛凼刅争剹劐匧㗇厩㕑厰㕓参吣㕭㕲㚁咓咣咴咹哐哯唘唣唨㖘唿㖥㖿嗗㗅"],["8a40","𧶄唥"],["8a43","𠱂𠴕𥄫喐𢳆㧬𠍁蹆𤶸𩓥䁓𨂾睺𢰸㨴䟕𨅝𦧲𤷪擝𠵼𠾴𠳕𡃴撍蹾𠺖𠰋𠽤𢲩𨉖𤓓"],["8a64","𠵆𩩍𨃩䟴𤺧𢳂骲㩧𩗴㿭㔆𥋇𩟔𧣈𢵄鵮頕"],["8a76","䏙𦂥撴哣𢵌𢯊𡁷㧻𡁯"],["8aa1","𦛚𦜖𧦠擪𥁒𠱃蹨𢆡𨭌𠜱"],["8aac","䠋𠆩㿺塳𢶍"],["8ab2","𤗈𠓼𦂗𠽌𠶖啹䂻䎺"],["8abb","䪴𢩦𡂝膪飵𠶜捹㧾𢝵跀嚡摼㹃"],["8ac9","𪘁𠸉𢫏𢳉"],["8ace","𡃈𣧂㦒㨆𨊛㕸𥹉𢃇噒𠼱𢲲𩜠㒼氽𤸻"],["8adf","𧕴𢺋𢈈𪙛𨳍𠹺𠰴𦠜羓𡃏𢠃𢤹㗻𥇣𠺌𠾍𠺪㾓𠼰𠵇𡅏𠹌"],["8af6","𠺫𠮩𠵈𡃀𡄽㿹𢚖搲𠾭"],["8b40","𣏴𧘹𢯎𠵾𠵿𢱑𢱕㨘𠺘𡃇𠼮𪘲𦭐𨳒𨶙𨳊閪哌苄喹"],["8b55","𩻃鰦骶𧝞𢷮煀腭胬尜𦕲脴㞗卟𨂽醶𠻺𠸏𠹷𠻻㗝𤷫㘉𠳖嚯𢞵𡃉𠸐𠹸𡁸𡅈𨈇𡑕𠹹𤹐𢶤婔𡀝𡀞𡃵𡃶垜𠸑"],["8ba1","𧚔𨋍𠾵𠹻𥅾㜃𠾶𡆀𥋘𪊽𤧚𡠺𤅷𨉼墙剨㘚𥜽箲孨䠀䬬鼧䧧鰟鮍𥭴𣄽嗻㗲嚉丨夂𡯁屮靑𠂆乛亻㔾尣彑忄㣺扌攵歺氵氺灬爫丬犭𤣩罒礻糹罓𦉪㓁"],["8bde","𦍋耂肀𦘒𦥑卝衤见𧢲讠贝钅镸长门𨸏韦页风飞饣𩠐鱼鸟黄歯龜丷𠂇阝户钢"],["8c40","倻淾𩱳龦㷉袏𤅎灷峵䬠𥇍㕙𥴰愢𨨲辧釶熑朙玺𣊁𪄇㲋𡦀䬐磤琂冮𨜏䀉橣𪊺䈣蘏𠩯稪𩥇𨫪靕灍匤𢁾鏴盙𨧣龧矝亣俰傼丯众龨吴綋墒壐𡶶庒庙忂𢜒斋"],["8ca1","𣏹椙橃𣱣泿"],["8ca7","爀𤔅玌㻛𤨓嬕璹讃𥲤𥚕窓篬糃繬苸薗龩袐龪躹龫迏蕟駠鈡龬𨶹𡐿䁱䊢娚"],["8cc9","顨杫䉶圽"],["8cce","藖𤥻芿𧄍䲁𦵴嵻𦬕𦾾龭龮宖龯曧繛湗秊㶈䓃𣉖𢞖䎚䔶"],["8ce6","峕𣬚諹屸㴒𣕑嵸龲煗䕘𤃬𡸣䱷㥸㑊𠆤𦱁諌侴𠈹妿腬顖𩣺弻"],["8d40","𠮟"],["8d42","𢇁𨥭䄂䚻𩁹㼇龳𪆵䃸㟖䛷𦱆䅼𨚲𧏿䕭㣔𥒚䕡䔛䶉䱻䵶䗪㿈𤬏㙡䓞䒽䇭崾嵈嵖㷼㠏嶤嶹㠠㠸幂庽弥徃㤈㤔㤿㥍惗愽峥㦉憷憹懏㦸戬抐拥挘㧸嚱"],["8da1","㨃揢揻搇摚㩋擀崕嘡龟㪗斆㪽旿晓㫲暒㬢朖㭂枤栀㭘桊梄㭲㭱㭻椉楃牜楤榟榅㮼槖㯝橥橴橱檂㯬檙㯲檫檵櫔櫶殁毁毪汵沪㳋洂洆洦涁㳯涤涱渕渘温溆𨧀溻滢滚齿滨滩漤漴㵆𣽁澁澾㵪㵵熷岙㶊瀬㶑灐灔灯灿炉𠌥䏁㗱𠻘"],["8e40","𣻗垾𦻓焾𥟠㙎榢𨯩孴穉𥣡𩓙穥穽𥦬窻窰竂竃燑𦒍䇊竚竝竪䇯咲𥰁笋筕笩𥌎𥳾箢筯莜𥮴𦱿篐萡箒箸𥴠㶭𥱥蒒篺簆簵𥳁籄粃𤢂粦晽𤕸糉糇糦籴糳糵糎"],["8ea1","繧䔝𦹄絝𦻖璍綉綫焵綳緒𤁗𦀩緤㴓緵𡟹緥𨍭縝𦄡𦅚繮纒䌫鑬縧罀罁罇礶𦋐駡羗𦍑羣𡙡𠁨䕜𣝦䔃𨌺翺𦒉者耈耝耨耯𪂇𦳃耻耼聡𢜔䦉𦘦𣷣𦛨朥肧𨩈脇脚墰𢛶汿𦒘𤾸擧𡒊舘𡡞橓𤩥𤪕䑺舩𠬍𦩒𣵾俹𡓽蓢荢𦬊𤦧𣔰𡝳𣷸芪椛芳䇛"],["8f40","蕋苐茚𠸖𡞴㛁𣅽𣕚艻苢茘𣺋𦶣𦬅𦮗𣗎㶿茝嗬莅䔋𦶥莬菁菓㑾𦻔橗蕚㒖𦹂𢻯葘𥯤葱㷓䓤檧葊𣲵祘蒨𦮖𦹷𦹃蓞萏莑䒠蒓蓤𥲑䉀𥳀䕃蔴嫲𦺙䔧蕳䔖枿蘖"],["8fa1","𨘥𨘻藁𧂈蘂𡖂𧃍䕫䕪蘨㙈𡢢号𧎚虾蝱𪃸蟮𢰧螱蟚蠏噡虬桖䘏衅衆𧗠𣶹𧗤衞袜䙛袴袵揁装睷𧜏覇覊覦覩覧覼𨨥觧𧤤𧪽誜瞓釾誐𧩙竩𧬺𣾏䜓𧬸煼謌謟𥐰𥕥謿譌譍誩𤩺讐讛誯𡛟䘕衏貛𧵔𧶏貫㜥𧵓賖𧶘𧶽贒贃𡤐賛灜贑𤳉㻐起"],["9040","趩𨀂𡀔𤦊㭼𨆼𧄌竧躭躶軃鋔輙輭𨍥𨐒辥錃𪊟𠩐辳䤪𨧞𨔽𣶻廸𣉢迹𪀔𨚼𨔁𢌥㦀𦻗逷𨔼𧪾遡𨕬𨘋邨𨜓郄𨛦邮都酧㫰醩釄粬𨤳𡺉鈎沟鉁鉢𥖹銹𨫆𣲛𨬌𥗛"],["90a1","𠴱錬鍫𨫡𨯫炏嫃𨫢𨫥䥥鉄𨯬𨰹𨯿鍳鑛躼閅閦鐦閠濶䊹𢙺𨛘𡉼𣸮䧟氜陻隖䅬隣𦻕懚隶磵𨫠隽双䦡𦲸𠉴𦐐𩂯𩃥𤫑𡤕𣌊霱虂霶䨏䔽䖅𤫩灵孁霛靜𩇕靗孊𩇫靟鐥僐𣂷𣂼鞉鞟鞱鞾韀韒韠𥑬韮琜𩐳響韵𩐝𧥺䫑頴頳顋顦㬎𧅵㵑𠘰𤅜"],["9140","𥜆飊颷飈飇䫿𦴧𡛓喰飡飦飬鍸餹𤨩䭲𩡗𩤅駵騌騻騐驘𥜥㛄𩂱𩯕髠髢𩬅髴䰎鬔鬭𨘀倴鬴𦦨㣃𣁽魐魀𩴾婅𡡣鮎𤉋鰂鯿鰌𩹨鷔𩾷𪆒𪆫𪃡𪄣𪇟鵾鶃𪄴鸎梈"],["91a1","鷄𢅛𪆓𪈠𡤻𪈳鴹𪂹𪊴麐麕麞麢䴴麪麯𤍤黁㭠㧥㴝伲㞾𨰫鼂鼈䮖鐤𦶢鼗鼖鼹嚟嚊齅馸𩂋韲葿齢齩竜龎爖䮾𤥵𤦻煷𤧸𤍈𤩑玞𨯚𡣺禟𨥾𨸶鍩鏳𨩄鋬鎁鏋𨥬𤒹爗㻫睲穃烐𤑳𤏸煾𡟯炣𡢾𣖙㻇𡢅𥐯𡟸㜢𡛻𡠹㛡𡝴𡣑𥽋㜣𡛀坛𤨥𡏾𡊨"],["9240","𡏆𡒶蔃𣚦蔃葕𤦔𧅥𣸱𥕜𣻻𧁒䓴𣛮𩦝𦼦柹㜳㰕㷧塬𡤢栐䁗𣜿𤃡𤂋𤄏𦰡哋嚞𦚱嚒𠿟𠮨𠸍鏆𨬓鎜仸儫㠙𤐶亼𠑥𠍿佋侊𥙑婨𠆫𠏋㦙𠌊𠐔㐵伩𠋀𨺳𠉵諚𠈌亘"],["92a1","働儍侢伃𤨎𣺊佂倮偬傁俌俥偘僼兙兛兝兞湶𣖕𣸹𣺿浲𡢄𣺉冨凃𠗠䓝𠒣𠒒𠒑赺𨪜𠜎剙劤𠡳勡鍮䙺熌𤎌𠰠𤦬𡃤槑𠸝瑹㻞璙琔瑖玘䮎𤪼𤂍叐㖄爏𤃉喴𠍅响𠯆圝鉝雴鍦埝垍坿㘾壋媙𨩆𡛺𡝯𡜐娬妸銏婾嫏娒𥥆𡧳𡡡𤊕㛵洅瑃娡𥺃"],["9340","媁𨯗𠐓鏠璌𡌃焅䥲鐈𨧻鎽㞠尞岞幞幈𡦖𡥼𣫮廍孏𡤃𡤄㜁𡢠㛝𡛾㛓脪𨩇𡶺𣑲𨦨弌弎𡤧𡞫婫𡜻孄蘔𧗽衠恾𢡠𢘫忛㺸𢖯𢖾𩂈𦽳懀𠀾𠁆𢘛憙憘恵𢲛𢴇𤛔𩅍"],["93a1","摱𤙥𢭪㨩𢬢𣑐𩣪𢹸挷𪑛撶挱揑𤧣𢵧护𢲡搻敫楲㯴𣂎𣊭𤦉𣊫唍𣋠𡣙𩐿曎𣊉𣆳㫠䆐𥖄𨬢𥖏𡛼𥕛𥐥磮𣄃𡠪𣈴㑤𣈏𣆂𤋉暎𦴤晫䮓昰𧡰𡷫晣𣋒𣋡昞𥡲㣑𣠺𣞼㮙𣞢𣏾瓐㮖枏𤘪梶栞㯄檾㡣𣟕𤒇樳橒櫉欅𡤒攑梘橌㯗橺歗𣿀𣲚鎠鋲𨯪𨫋"],["9440","銉𨀞𨧜鑧涥漋𤧬浧𣽿㶏渄𤀼娽渊塇洤硂焻𤌚𤉶烱牐犇犔𤞏𤜥兹𤪤𠗫瑺𣻸𣙟𤩊𤤗𥿡㼆㺱𤫟𨰣𣼵悧㻳瓌琼鎇琷䒟𦷪䕑疃㽣𤳙𤴆㽘畕癳𪗆㬙瑨𨫌𤦫𤦎㫻"],["94a1","㷍𤩎㻿𤧅𤣳釺圲鍂𨫣𡡤僟𥈡𥇧睸𣈲眎眏睻𤚗𣞁㩞𤣰琸璛㺿𤪺𤫇䃈𤪖𦆮錇𥖁砞碍碈磒珐祙𧝁𥛣䄎禛蒖禥樭𣻺稺秴䅮𡛦䄲鈵秱𠵌𤦌𠊙𣶺𡝮㖗啫㕰㚪𠇔𠰍竢婙𢛵𥪯𥪜娍𠉛磰娪𥯆竾䇹籝籭䈑𥮳𥺼𥺦糍𤧹𡞰粎籼粮檲緜縇緓罎𦉡"],["9540","𦅜𧭈綗𥺂䉪𦭵𠤖柖𠁎𣗏埄𦐒𦏸𤥢翝笧𠠬𥫩𥵃笌𥸎駦虅驣樜𣐿㧢𤧷𦖭騟𦖠蒀𧄧𦳑䓪脷䐂胆脉腂𦞴飃𦩂艢艥𦩑葓𦶧蘐𧈛媆䅿𡡀嬫𡢡嫤𡣘蚠蜨𣶏蠭𧐢娂"],["95a1","衮佅袇袿裦襥襍𥚃襔𧞅𧞄𨯵𨯙𨮜𨧹㺭蒣䛵䛏㟲訽訜𩑈彍鈫𤊄旔焩烄𡡅鵭貟賩𧷜妚矃姰䍮㛔踪躧𤰉輰轊䋴汘澻𢌡䢛潹溋𡟚鯩㚵𤤯邻邗啱䤆醻鐄𨩋䁢𨫼鐧𨰝𨰻蓥訫閙閧閗閖𨴴瑅㻂𤣿𤩂𤏪㻧𣈥随𨻧𨹦𨹥㻌𤧭𤩸𣿮琒瑫㻼靁𩂰"],["9640","桇䨝𩂓𥟟靝鍨𨦉𨰦𨬯𦎾銺嬑譩䤼珹𤈛鞛靱餸𠼦巁𨯅𤪲頟𩓚鋶𩗗釥䓀𨭐𤩧𨭤飜𨩅㼀鈪䤥萔餻饍𧬆㷽馛䭯馪驜𨭥𥣈檏騡嫾騯𩣱䮐𩥈馼䮽䮗鍽塲𡌂堢𤦸"],["96a1","𡓨硄𢜟𣶸棅㵽鑘㤧慐𢞁𢥫愇鱏鱓鱻鰵鰐魿鯏𩸭鮟𪇵𪃾鴡䲮𤄄鸘䲰鴌𪆴𪃭𪃳𩤯鶥蒽𦸒𦿟𦮂藼䔳𦶤𦺄𦷰萠藮𦸀𣟗𦁤秢𣖜𣙀䤭𤧞㵢鏛銾鍈𠊿碹鉷鑍俤㑀遤𥕝砽硔碶硋𡝗𣇉𤥁㚚佲濚濙瀞瀞吔𤆵垻壳垊鴖埗焴㒯𤆬燫𦱀𤾗嬨𡞵𨩉"],["9740","愌嫎娋䊼𤒈㜬䭻𨧼鎻鎸𡣖𠼝葲𦳀𡐓𤋺𢰦𤏁妔𣶷𦝁綨𦅛𦂤𤦹𤦋𨧺鋥珢㻩璴𨭣𡢟㻡𤪳櫘珳珻㻖𤨾𤪔𡟙𤩦𠎧𡐤𤧥瑈𤤖炥𤥶銄珦鍟𠓾錱𨫎𨨖鎆𨯧𥗕䤵𨪂煫"],["97a1","𤥃𠳿嚤𠘚𠯫𠲸唂秄𡟺緾𡛂𤩐𡡒䔮鐁㜊𨫀𤦭妰𡢿𡢃𧒄媡㛢𣵛㚰鉟婹𨪁𡡢鍴㳍𠪴䪖㦊僴㵩㵌𡎜煵䋻𨈘渏𩃤䓫浗𧹏灧沯㳖𣿭𣸭渂漌㵯𠏵畑㚼㓈䚀㻚䡱姄鉮䤾轁𨰜𦯀堒埈㛖𡑒烾𤍢𤩱𢿣𡊰𢎽梹楧𡎘𣓥𧯴𣛟𨪃𣟖𣏺𤲟樚𣚭𦲷萾䓟䓎"],["9840","𦴦𦵑𦲂𦿞漗𧄉茽𡜺菭𦲀𧁓𡟛妉媂𡞳婡婱𡤅𤇼㜭姯𡜼㛇熎鎐暚𤊥婮娫𤊓樫𣻹𧜶𤑛𤋊焝𤉙𨧡侰𦴨峂𤓎𧹍𤎽樌𤉖𡌄炦焳𤏩㶥泟勇𤩏繥姫崯㷳彜𤩝𡟟綤萦"],["98a1","咅𣫺𣌀𠈔坾𠣕𠘙㿥𡾞𪊶瀃𩅛嵰玏糓𨩙𩐠俈翧狍猐𧫴猸猹𥛶獁獈㺩𧬘遬燵𤣲珡臶㻊県㻑沢国琙琞琟㻢㻰㻴㻺瓓㼎㽓畂畭畲疍㽼痈痜㿀癍㿗癴㿜発𤽜熈嘣覀塩䀝睃䀹条䁅㗛瞘䁪䁯属瞾矋売砘点砜䂨砹硇硑硦葈𥔵礳栃礲䄃"],["9940","䄉禑禙辻稆込䅧窑䆲窼艹䇄竏竛䇏両筢筬筻簒簛䉠䉺类粜䊌粸䊔糭输烀𠳏総緔緐緽羮羴犟䎗耠耥笹耮耱联㷌垴炠肷胩䏭脌猪脎脒畠脔䐁㬹腖腙腚"],["99a1","䐓堺腼膄䐥膓䐭膥埯臁臤艔䒏芦艶苊苘苿䒰荗险榊萅烵葤惣蒈䔄蒾蓡蓸蔐蔸蕒䔻蕯蕰藠䕷虲蚒蚲蛯际螋䘆䘗袮裿褤襇覑𧥧訩訸誔誴豑賔賲贜䞘塟跃䟭仮踺嗘坔蹱嗵躰䠷軎転軤軭軲辷迁迊迌逳駄䢭飠鈓䤞鈨鉘鉫銱銮銿"],["9a40","鋣鋫鋳鋴鋽鍃鎄鎭䥅䥑麿鐗匁鐝鐭鐾䥪鑔鑹锭関䦧间阳䧥枠䨤靀䨵鞲韂噔䫤惨颹䬙飱塄餎餙冴餜餷饂饝饢䭰駅䮝騼鬏窃魩鮁鯝鯱鯴䱭鰠㝯𡯂鵉鰺"],["9aa1","黾噐鶓鶽鷀鷼银辶鹻麬麱麽黆铜黢黱黸竈齄𠂔𠊷𠎠椚铃妬𠓗塀铁㞹𠗕𠘕𠙶𡚺块煳𠫂𠫍𠮿呪吆𠯋咞𠯻𠰻𠱓𠱥𠱼惧𠲍噺𠲵𠳝𠳭𠵯𠶲𠷈楕鰯螥𠸄𠸎𠻗𠾐𠼭𠹳尠𠾼帋𡁜𡁏𡁶朞𡁻𡂈𡂖㙇𡂿𡃓𡄯𡄻卤蒭𡋣𡍵𡌶讁𡕷𡘙𡟃𡟇乸炻𡠭𡥪"],["9b40","𡨭𡩅𡰪𡱰𡲬𡻈拃𡻕𡼕熘桕𢁅槩㛈𢉼𢏗𢏺𢜪𢡱𢥏苽𢥧𢦓𢫕覥𢫨辠𢬎鞸𢬿顇骽𢱌"],["9b62","𢲈𢲷𥯨𢴈𢴒𢶷𢶕𢹂𢽴𢿌𣀳𣁦𣌟𣏞徱晈暿𧩹𣕧𣗳爁𤦺矗𣘚𣜖纇𠍆墵朎"],["9ba1","椘𣪧𧙗𥿢𣸑𣺹𧗾𢂚䣐䪸𤄙𨪚𤋮𤌍𤀻𤌴𤎖𤩅𠗊凒𠘑妟𡺨㮾𣳿𤐄𤓖垈𤙴㦛𤜯𨗨𩧉㝢𢇃譞𨭎駖𤠒𤣻𤨕爉𤫀𠱸奥𤺥𤾆𠝹軚𥀬劏圿煱𥊙𥐙𣽊𤪧喼𥑆𥑮𦭒釔㑳𥔿𧘲𥕞䜘𥕢𥕦𥟇𤤿𥡝偦㓻𣏌惞𥤃䝼𨥈𥪮𥮉𥰆𡶐垡煑澶𦄂𧰒遖𦆲𤾚譢𦐂𦑊"],["9c40","嵛𦯷輶𦒄𡤜諪𤧶𦒈𣿯𦔒䯀𦖿𦚵𢜛鑥𥟡憕娧晉侻嚹𤔡𦛼乪𤤴陖涏𦲽㘘襷𦞙𦡮𦐑𦡞營𦣇筂𩃀𠨑𦤦鄄𦤹穅鷰𦧺騦𦨭㙟𦑩𠀡禃𦨴𦭛崬𣔙菏𦮝䛐𦲤画补𦶮墶"],["9ca1","㜜𢖍𧁋𧇍㱔𧊀𧊅銁𢅺𧊋錰𧋦𤧐氹钟𧑐𠻸蠧裵𢤦𨑳𡞱溸𤨪𡠠㦤㚹尐秣䔿暶𩲭𩢤襃𧟌𧡘囖䃟𡘊㦡𣜯𨃨𡏅熭荦𧧝𩆨婧䲷𧂯𨦫𧧽𧨊𧬋𧵦𤅺筃祾𨀉澵𪋟樃𨌘厢𦸇鎿栶靝𨅯𨀣𦦵𡏭𣈯𨁈嶅𨰰𨂃圕頣𨥉嶫𤦈斾槕叒𤪥𣾁㰑朶𨂐𨃴𨄮𡾡𨅏"],["9d40","𨆉𨆯𨈚𨌆𨌯𨎊㗊𨑨𨚪䣺揦𨥖砈鉕𨦸䏲𨧧䏟𨧨𨭆𨯔姸𨰉輋𨿅𩃬筑𩄐𩄼㷷𩅞𤫊运犏嚋𩓧𩗩𩖰𩖸𩜲𩣑𩥉𩥪𩧃𩨨𩬎𩵚𩶛纟𩻸𩼣䲤镇𪊓熢𪋿䶑递𪗋䶜𠲜达嗁"],["9da1","辺𢒰边𤪓䔉繿潖檱仪㓤𨬬𧢝㜺躀𡟵𨀤𨭬𨮙𧨾𦚯㷫𧙕𣲷𥘵𥥖亚𥺁𦉘嚿𠹭踎孭𣺈𤲞揞拐𡟶𡡻攰嘭𥱊吚𥌑㷆𩶘䱽嘢嘞罉𥻘奵𣵀蝰东𠿪𠵉𣚺脗鵞贘瘻鱅癎瞹鍅吲腈苷嘥脲萘肽嗪祢噃吖𠺝㗎嘅嗱曱𨋢㘭甴嗰喺咗啲𠱁𠲖廐𥅈𠹶𢱢"],["9e40","𠺢麫絚嗞𡁵抝靭咔賍燶酶揼掹揾啩𢭃鱲𢺳冚㓟𠶧冧呍唞唓癦踭𦢊疱肶蠄螆裇膶萜𡃁䓬猄𤜆宐茋𦢓噻𢛴𧴯𤆣𧵳𦻐𧊶酰𡇙鈈𣳼𪚩𠺬𠻹牦𡲢䝎𤿂𧿹𠿫䃺"],["9ea1","鱝攟𢶠䣳𤟠𩵼𠿬𠸊恢𧖣𠿭"],["9ead","𦁈𡆇熣纎鵐业丄㕷嬍沲卧㚬㧜卽㚥𤘘墚𤭮舭呋垪𥪕𠥹"],["9ec5","㩒𢑥獴𩺬䴉鯭𣳾𩼰䱛𤾩𩖞𩿞葜𣶶𧊲𦞳𣜠挮紥𣻷𣸬㨪逈勌㹴㙺䗩𠒎癀嫰𠺶硺𧼮墧䂿噼鮋嵴癔𪐴麅䳡痹㟻愙𣃚𤏲"],["9ef5","噝𡊩垧𤥣𩸆刴𧂮㖭汊鵼"],["9f40","籖鬹埞𡝬屓擓𩓐𦌵𧅤蚭𠴨𦴢𤫢𠵱"],["9f4f","凾𡼏嶎霃𡷑麁遌笟鬂峑箣扨挵髿篏鬪籾鬮籂粆鰕篼鬉鼗鰛𤤾齚啳寃俽麘俲剠㸆勑坧偖妷帒韈鶫轜呩鞴饀鞺匬愰"],["9fa1","椬叚鰊鴂䰻陁榀傦畆𡝭駚剳"],["9fae","酙隁酜"],["9fb2","酑𨺗捿𦴣櫊嘑醎畺抅𠏼獏籰𥰡𣳽"],["9fc1","𤤙盖鮝个𠳔莾衂"],["9fc9","届槀僭坺刟巵从氱𠇲伹咜哚劚趂㗾弌㗳"],["9fdb","歒酼龥鮗頮颴骺麨麄煺笔"],["9fe7","毺蠘罸"],["9feb","嘠𪙊蹷齓"],["9ff0","跔蹏鸜踁抂𨍽踨蹵竓𤩷稾磘泪詧瘇"],["a040","𨩚鼦泎蟖痃𪊲硓咢贌狢獱謭猂瓱賫𤪻蘯徺袠䒷"],["a055","𡠻𦸅"],["a058","詾𢔛"],["a05b","惽癧髗鵄鍮鮏蟵"],["a063","蠏賷猬霡鮰㗖犲䰇籑饊𦅙慙䰄麖慽"],["a073","坟慯抦戹拎㩜懢厪𣏵捤栂㗒"],["a0a1","嵗𨯂迚𨸹"],["a0a6","僙𡵆礆匲阸𠼻䁥"],["a0ae","矾"],["a0b0","糂𥼚糚稭聦聣絍甅瓲覔舚朌聢𧒆聛瓰脃眤覉𦟌畓𦻑螩蟎臈螌詉貭譃眫瓸蓚㘵榲趦"],["a0d4","覩瑨涹蟁𤀑瓧㷛煶悤憜㳑煢恷"],["a0e2","罱𨬭牐惩䭾删㰘𣳇𥻗𧙖𥔱𡥄𡋾𩤃𦷜𧂭峁𦆭𨨏𣙷𠃮𦡆𤼎䕢嬟𦍌齐麦𦉫"],["a3c0","␀",31,"␡"],["c6a1","①",9,"⑴",9,"ⅰ",9,"丶丿亅亠冂冖冫勹匸卩厶夊宀巛⼳广廴彐彡攴无疒癶辵隶¨ˆヽヾゝゞ〃仝々〆〇ー[]✽ぁ",23],["c740","す",58,"ァアィイ"],["c7a1","ゥ",81,"А",5,"ЁЖ",4],["c840","Л",26,"ёж",25,"⇧↸↹㇏𠃌乚𠂊刂䒑"],["c8a1","龰冈龱𧘇"],["c8cd","¬¦'"㈱№℡゛゜⺀⺄⺆⺇⺈⺊⺌⺍⺕⺜⺝⺥⺧⺪⺬⺮⺶⺼⺾⻆⻊⻌⻍⻏⻖⻗⻞⻣"],["c8f5","ʃɐɛɔɵœøŋʊɪ"],["f9fe","■"],["fa40","𠕇鋛𠗟𣿅蕌䊵珯况㙉𤥂𨧤鍄𡧛苮𣳈砼杄拟𤤳𨦪𠊠𦮳𡌅侫𢓭倈𦴩𧪄𣘀𤪱𢔓倩𠍾徤𠎀𠍇滛𠐟偽儁㑺儎顬㝃萖𤦤𠒇兠𣎴兪𠯿𢃼𠋥𢔰𠖎𣈳𡦃宂蝽𠖳𣲙冲冸"],["faa1","鴴凉减凑㳜凓𤪦决凢卂凭菍椾𣜭彻刋刦刼劵剗劔効勅簕蕂勠蘍𦬓包𨫞啉滙𣾀𠥔𣿬匳卄𠯢泋𡜦栛珕恊㺪㣌𡛨燝䒢卭却𨚫卾卿𡖖𡘓矦厓𨪛厠厫厮玧𥝲㽙玜叁叅汉义埾叙㪫𠮏叠𣿫𢶣叶𠱷吓灹唫晗浛呭𦭓𠵴啝咏咤䞦𡜍𠻝㶴𠵍"],["fb40","𨦼𢚘啇䳭启琗喆喩嘅𡣗𤀺䕒𤐵暳𡂴嘷曍𣊊暤暭噍噏磱囱鞇叾圀囯园𨭦㘣𡉏坆𤆥汮炋坂㚱𦱾埦𡐖堃𡑔𤍣堦𤯵塜墪㕡壠壜𡈼壻寿坃𪅐𤉸鏓㖡够梦㛃湙"],["fba1","𡘾娤啓𡚒蔅姉𠵎𦲁𦴪𡟜姙𡟻𡞲𦶦浱𡠨𡛕姹𦹅媫婣㛦𤦩婷㜈媖瑥嫓𦾡𢕔㶅𡤑㜲𡚸広勐孶斈孼𧨎䀄䡝𠈄寕慠𡨴𥧌𠖥寳宝䴐尅𡭄尓珎尔𡲥𦬨屉䣝岅峩峯嶋𡷹𡸷崐崘嵆𡺤岺巗苼㠭𤤁𢁉𢅳芇㠶㯂帮檊幵幺𤒼𠳓厦亷廐厨𡝱帉廴𨒂"],["fc40","廹廻㢠廼栾鐛弍𠇁弢㫞䢮𡌺强𦢈𢏐彘𢑱彣鞽𦹮彲鍀𨨶徧嶶㵟𥉐𡽪𧃸𢙨釖𠊞𨨩怱暅𡡷㥣㷇㘹垐𢞴祱㹀悞悤悳𤦂𤦏𧩓璤僡媠慤萤慂慈𦻒憁凴𠙖憇宪𣾷"],["fca1","𢡟懓𨮝𩥝懐㤲𢦀𢣁怣慜攞掋𠄘担𡝰拕𢸍捬𤧟㨗搸揸𡎎𡟼撐澊𢸶頔𤂌𥜝擡擥鑻㩦携㩗敍漖𤨨𤨣斅敭敟𣁾斵𤥀䬷旑䃘𡠩无旣忟𣐀昘𣇷𣇸晄𣆤𣆥晋𠹵晧𥇦晳晴𡸽𣈱𨗴𣇈𥌓矅𢣷馤朂𤎜𤨡㬫槺𣟂杞杧杢𤇍𩃭柗䓩栢湐鈼栁𣏦𦶠桝"],["fd40","𣑯槡樋𨫟楳棃𣗍椁椀㴲㨁𣘼㮀枬楡𨩊䋼椶榘㮡𠏉荣傐槹𣙙𢄪橅𣜃檝㯳枱櫈𩆜㰍欝𠤣惞欵歴𢟍溵𣫛𠎵𡥘㝀吡𣭚毡𣻼毜氷𢒋𤣱𦭑汚舦汹𣶼䓅𣶽𤆤𤤌𤤀"],["fda1","𣳉㛥㳫𠴲鮃𣇹𢒑羏样𦴥𦶡𦷫涖浜湼漄𤥿𤂅𦹲蔳𦽴凇沜渝萮𨬡港𣸯瑓𣾂秌湏媑𣁋濸㜍澝𣸰滺𡒗𤀽䕕鏰潄潜㵎潴𩅰㴻澟𤅄濓𤂑𤅕𤀹𣿰𣾴𤄿凟𤅖𤅗𤅀𦇝灋灾炧炁烌烕烖烟䄄㷨熴熖𤉷焫煅媈煊煮岜𤍥煏鍢𤋁焬𤑚𤨧𤨢熺𨯨炽爎"],["fe40","鑂爕夑鑃爤鍁𥘅爮牀𤥴梽牕牗㹕𣁄栍漽犂猪猫𤠣𨠫䣭𨠄猨献珏玪𠰺𦨮珉瑉𤇢𡛧𤨤昣㛅𤦷𤦍𤧻珷琕椃𤨦琹𠗃㻗瑜𢢭瑠𨺲瑇珤瑶莹瑬㜰瑴鏱樬璂䥓𤪌"],["fea1","𤅟𤩹𨮏孆𨰃𡢞瓈𡦈甎瓩甞𨻙𡩋寗𨺬鎅畍畊畧畮𤾂㼄𤴓疎瑝疞疴瘂瘬癑癏癯癶𦏵皐臯㟸𦤑𦤎皡皥皷盌𦾟葢𥂝𥅽𡸜眞眦着撯𥈠睘𣊬瞯𨥤𨥨𡛁矴砉𡍶𤨒棊碯磇磓隥礮𥗠磗礴碱𧘌辸袄𨬫𦂃𢘜禆褀椂禀𥡗禝𧬹礼禩渪𧄦㺨秆𩄍秔"]];var dbcsData,hasRequiredDbcsData;function requireDbcsData(){return hasRequiredDbcsData||(hasRequiredDbcsData=1,dbcsData={shiftjis:{type:"_dbcs",table:function(){return require$$0},encodeAdd:{"¥":92,"‾":126},encodeSkipVals:[{from:60736,to:63808}]},csshiftjis:"shiftjis",mskanji:"shiftjis",sjis:"shiftjis",windows31j:"shiftjis",ms31j:"shiftjis",xsjis:"shiftjis",windows932:"shiftjis",ms932:"shiftjis",932:"shiftjis",cp932:"shiftjis",eucjp:{type:"_dbcs",table:function(){return require$$1},encodeAdd:{"¥":92,"‾":126}},gb2312:"cp936",gb231280:"cp936",gb23121980:"cp936",csgb2312:"cp936",csiso58gb231280:"cp936",euccn:"cp936",windows936:"cp936",ms936:"cp936",936:"cp936",cp936:{type:"_dbcs",table:function(){return require$$2}},gbk:{type:"_dbcs",table:function(){return require$$2.concat(require$$3)}},xgbk:"gbk",isoir58:"gbk",gb18030:{type:"_dbcs",table:function(){return require$$2.concat(require$$3)},gb18030:function(){return require$$4$1},encodeSkipVals:[128],encodeAdd:{"€":41699}},chinese:"gb18030",windows949:"cp949",ms949:"cp949",949:"cp949",cp949:{type:"_dbcs",table:function(){return require$$5}},cseuckr:"cp949",csksc56011987:"cp949",euckr:"cp949",isoir149:"cp949",korean:"cp949",ksc56011987:"cp949",ksc56011989:"cp949",ksc5601:"cp949",windows950:"cp950",ms950:"cp950",950:"cp950",cp950:{type:"_dbcs",table:function(){return require$$6}},big5:"big5hkscs",big5hkscs:{type:"_dbcs",table:function(){return require$$6.concat(require$$7)},encodeSkipVals:[36457,36463,36478,36523,36532,36557,36560,36695,36713,36718,36811,36862,36973,36986,37060,37084,37105,37311,37551,37552,37553,37554,37585,37959,38090,38361,38652,39285,39798,39800,39803,39878,39902,39916,39926,40002,40019,40034,40040,40043,40055,40124,40125,40144,40279,40282,40388,40431,40443,40617,40687,40701,40800,40907,41079,41180,41183,36812,37576,38468,38637,41636,41637,41639,41638,41676,41678]},cnbig5:"big5hkscs",csbig5:"big5hkscs",xxbig5:"big5hkscs"}),dbcsData}var hasRequiredEncodings;function requireEncodings(){return hasRequiredEncodings||(hasRequiredEncodings=1,function(t){for(var e=[requireInternal(),requireUtf32(),requireUtf16(),requireUtf7(),requireSbcsCodec(),requireSbcsData(),requireSbcsDataGenerated(),requireDbcsCodec(),requireDbcsData()],l=0;l<e.length;l++){var n=e[l];for(var u in n)Object.prototype.hasOwnProperty.call(n,u)&&(t[u]=n[u])}}(encodings)),encodings}var streams,hasRequiredStreams;function requireStreams(){if(hasRequiredStreams)return streams;hasRequiredStreams=1;var t=safer_1.Buffer;return streams=function(l){var n=l.Transform;function u(y,b){this.conv=y,b=b||{},b.decodeStrings=!1,n.call(this,b)}u.prototype=Object.create(n.prototype,{constructor:{value:u}}),u.prototype._transform=function(y,b,m){if(typeof y!="string")return m(new Error("Iconv encoding stream needs strings as its input."));try{var O=this.conv.write(y);O&&O.length&&this.push(O),m()}catch(N){m(N)}},u.prototype._flush=function(y){try{var b=this.conv.end();b&&b.length&&this.push(b),y()}catch(m){y(m)}},u.prototype.collect=function(y){var b=[];return this.on("error",y),this.on("data",function(m){b.push(m)}),this.on("end",function(){y(null,t.concat(b))}),this};function c(y,b){this.conv=y,b=b||{},b.encoding=this.encoding="utf8",n.call(this,b)}return c.prototype=Object.create(n.prototype,{constructor:{value:c}}),c.prototype._transform=function(y,b,m){if(!t.isBuffer(y)&&!(y instanceof Uint8Array))return m(new Error("Iconv decoding stream needs buffers as its input."));try{var O=this.conv.write(y);O&&O.length&&this.push(O,this.encoding),m()}catch(N){m(N)}},c.prototype._flush=function(y){try{var b=this.conv.end();b&&b.length&&this.push(b,this.encoding),y()}catch(m){y(m)}},c.prototype.collect=function(y){var b="";return this.on("error",y),this.on("data",function(m){b+=m}),this.on("end",function(){y(null,b)}),this},{IconvLiteEncoderStream:u,IconvLiteDecoderStream:c}},streams}const __viteBrowserExternal={},__viteBrowserExternal$1=Object.freeze(Object.defineProperty({__proto__:null,default:__viteBrowserExternal},Symbol.toStringTag,{value:"Module"})),require$$4=getAugmentedNamespace(__viteBrowserExternal$1);(function(t){var e=safer_1.Buffer,l=bomHandling,n=t.exports;n.encodings=null,n.defaultCharUnicode="�",n.defaultCharSingleByte="?",n.encode=function(y,b,m){y=""+(y||"");var O=n.getEncoder(b,m),N=O.write(y),L=O.end();return L&&L.length>0?e.concat([N,L]):N},n.decode=function(y,b,m){typeof y=="string"&&(n.skipDecodeWarning||(console.error("Iconv-lite warning: decode()-ing strings is deprecated. Refer to https://github.com/ashtuchkin/iconv-lite/wiki/Use-Buffers-when-decoding"),n.skipDecodeWarning=!0),y=e.from(""+(y||""),"binary"));var O=n.getDecoder(b,m),N=O.write(y),L=O.end();return L?N+L:N},n.encodingExists=function(y){try{return n.getCodec(y),!0}catch{return!1}},n.toEncoding=n.encode,n.fromEncoding=n.decode,n._codecDataCache={},n.getCodec=function(y){n.encodings||(n.encodings=requireEncodings());for(var b=n._canonicalizeEncoding(y),m={};;){var O=n._codecDataCache[b];if(O)return O;var N=n.encodings[b];switch(_typeof$2(N)){case"string":b=N;break;case"object":for(var L in N)m[L]=N[L];m.encodingName||(m.encodingName=b),b=N.type;break;case"function":return m.encodingName||(m.encodingName=b),O=new N(m,n),n._codecDataCache[m.encodingName]=O,O;default:throw new Error("Encoding not recognized: '"+y+"' (searched as: '"+b+"')")}}},n._canonicalizeEncoding=function(c){return(""+c).toLowerCase().replace(/:\d{4}$|[^0-9a-z]/g,"")},n.getEncoder=function(y,b){var m=n.getCodec(y),O=new m.encoder(b,m);return m.bomAware&&b&&b.addBOM&&(O=new l.PrependBOM(O,b)),O},n.getDecoder=function(y,b){var m=n.getCodec(y),O=new m.decoder(b,m);return m.bomAware&&!(b&&b.stripBOM===!1)&&(O=new l.StripBOM(O,b)),O},n.enableStreamingAPI=function(y){if(!n.supportsStreams){var b=requireStreams()(y);n.IconvLiteEncoderStream=b.IconvLiteEncoderStream,n.IconvLiteDecoderStream=b.IconvLiteDecoderStream,n.encodeStream=function(O,N){return new n.IconvLiteEncoderStream(n.getEncoder(O,N),N)},n.decodeStream=function(O,N){return new n.IconvLiteDecoderStream(n.getDecoder(O,N),N)},n.supportsStreams=!0}};var u;try{u=require$$4}catch{}u&&u.Transform?n.enableStreamingAPI(u):n.encodeStream=n.decodeStream=function(){throw new Error("iconv-lite Streaming API is not enabled. Use iconv.enableStreamingAPI(require('stream')); to enable it.")}})(lib);var safeBuffer={exports:{}};(function(t,e){var l=buffer$1,n=l.Buffer;function u(y,b){for(var m in y)b[m]=y[m]}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?t.exports=l:(u(l,e),e.Buffer=c);function c(y,b,m){return n(y,b,m)}u(n,c),c.from=function(y,b,m){if(typeof y=="number")throw new TypeError("Argument must not be a number");return n(y,b,m)},c.alloc=function(y,b,m){if(typeof y!="number")throw new TypeError("Argument must be a number");var O=n(y);return b!==void 0?typeof m=="string"?O.fill(b,m):O.fill(b):O.fill(0),O},c.allocUnsafe=function(y){if(typeof y!="number")throw new TypeError("Argument must be a number");return n(y)},c.allocUnsafeSlow=function(y){if(typeof y!="number")throw new TypeError("Argument must be a number");return l.SlowBuffer(y)}})(safeBuffer,safeBuffer.exports);var MxG2312=function(){function t(){_classCallCheck$1(this,t)}return _createClass$1(t,[{key:"encodeToGb2312",value:function(l){var n=lib.exports.encode(l,"gb2312"),u="";return n.forEach(function(c){u+="%"+c.toString(16)}),u}},{key:"decodeFromGb2312",value:function(l){for(var n=[],u=l.length,c=0;c<u;){var y=l.charAt(c);if(y=="%"){c+=1;var b=parseInt(l.slice(c,c+2),16);n.push(b),c+=2}else{console.log("decode hexstr error");break}}return lib.exports.decode(safeBuffer.exports.Buffer.from(n),"gb2312")}}]),t}(),MxG2312Obj=new MxG2312,win=window;win.McDrawObjectEvent_utf8ToAscii=function(t){return MxG2312Obj.encodeToGb2312(t)};win.McDrawObjectEvent_asciiToUTF8=function(t){return MxG2312Obj.decodeFromGb2312(t)};const version$1$1="1.0.261";var isSharedArrayBuffer="SharedArrayBuffer"in window,isCdn=document.currentScript&&/unpkg\.com\/mxcad/.test(document.currentScript.src),get2DFileURL=function t(e){var l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:self.location.href;return isCdn?"https://unpkg.com/mxcad@".concat(version$1$1,"/dist/wasm/2d-st/").concat(e):l+e},get2DSTFileURL=function t(e){var l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:self.location.href;return isCdn?"https://unpkg.com/mxcad@".concat(version$1$1,"/dist/wasm/2d/").concat(e):l+e},get3DFileURL=function t(e){var l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:self.location.href;return isCdn?"https://unpkg.com/mxcad@".concat(version$1$1,"/dist/wasm/3d/").concat(e):l+e},loadScript=function t(e){return new Promise(function(l,n){var u=document.createElement("script");u.src=e,u.type="text/javascript",u.crossOrigin="anonymous",document.body.appendChild(u),u.onload=function(){l()},u.onerror=function(c){n(c)}})},loadWams$1=function(){var t=_asyncToGenerator(regenerator.mark(function e(l,n,u){var c,y;return regenerator.wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return c=u.locateFile,y=c(l+".js"),m.prev=2,m.next=5,loadScript(y);case 5:return m.next=7,globalThis[n](u);case 7:return m.abrupt("return",m.sent);case 10:m.prev=10,m.t0=m.catch(2),console.error(`加载wasm文件失败, 请检查locateFile返回的路径是否可以正常访问:
- createMxCad({
- locateFile: (fileName)=> {
- // 该网络路径无法访问对应fileName的文件
- retrun "`.concat(y,`"
- }
- })
- `)),console.error(m.t0);case 14:case"end":return m.stop()}},e,null,[[2,10]])}));return function(l,n,u){return t.apply(this,arguments)}}(),_mxFinalizationRegistry$1=new FinalizationRegistry(function(t){MxCpp.App.destroyObject(t)}),_mxFinalizationRegistry_token$1={},McRxObject=function(){function t(e){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",0),this.imp=e,this.imp&&(this.imp.isNull()&&console.log("Mx:error null constructor object "),_mxFinalizationRegistry$1.register(this,e,_mxFinalizationRegistry_token$1))}return _createClass$1(t,[{key:"constructor_MxCADResbuf",value:function(l){this.imp=l,this.imp&&_mxFinalizationRegistry$1.register(this,l,_mxFinalizationRegistry_token$1)}},{key:"getImp",value:function(){return this.imp}},{key:"initTempObject",value:function(l){this.imp=l}},{key:"objectName",get:function(){return this.imp.getObjectName()}},{key:"dxf0",get:function(){return this.imp.getDxf0()}},{key:"getJson",value:function(){var l=this.imp.getJson();return MxG2312Obj.decodeFromGb2312(l)}},{key:"setJson",value:function(l){var n=MxG2312Obj.encodeToGb2312(l);return this.imp.setJson(n)}},{key:"isKindOf",value:function(l){return this.imp.isKindOf(l)}},{key:"isNull",value:function(){return this.imp.isNull()}}]),t}();function _createSuper$6(t){var e=_isNativeReflectConstruct$6();return function(){var n=_getPrototypeOf$1(t),u;if(e){var c=_getPrototypeOf$1(this).constructor;u=Reflect.construct(n,arguments,c)}else u=n.apply(this,arguments);return _possibleConstructorReturn$1(this,u)}}function _isNativeReflectConstruct$6(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var McObjectIdType=function(t){return t[t.kMxCAD=0]="kMxCAD",t[t.kMxDraw=1]="kMxDraw",t[t.kInvalid=2]="kInvalid",t}(McObjectIdType||{}),McObjectId=function(){function t(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:2;_classCallCheck$1(this,t),_defineProperty$1(this,"id",void 0),_defineProperty$1(this,"type",void 0),this.id=e,e?l==2?this.type=0:this.type=l:this.type=2}return _createClass$1(t,[{key:"isValid",value:function(){return this.type!=2&&this.id!=0}},{key:"isNull",value:function(){return this.type==2||this.id==0}},{key:"isErase",value:function(){return this.isValid()&&this.type==0&&this.id!=0?MxCpp.App.getImp().isObjectEraseSataus(this.id):!1}},{key:"erase",value:function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.isValid()&&(this.type==1?MxFun.getCurrentDraw().eraseMxEntity(this.id):this.type==0&&MxCADUtility.eraseObject(this.id,l))}},{key:"getMcDbObject",value:function(){return this.isValid()&&this.type==0?MxCpp.App.objectIdToObject(this.id):null}},{key:"isKindOf",value:function(l){return this.isValid()&&this.type==0?MxCpp.App.objectIdIsKindOf(this.id,l):!1}},{key:"getMcDbEntity",value:function(){return this.isValid()&&this.type==0&&MxCpp.App.objectIdIsKindOf(this.id,"McDbEntity")?MxCpp.App.objectIdToObject(this.id):null}},{key:"getMcDbCurve",value:function(){return this.isValid()&&this.type==0&&MxCpp.App.objectIdIsKindOf(this.id,"McDbCurve")?MxCpp.App.objectIdToObject(this.id):null}},{key:"getMcDbBlockTableRecord",value:function(){return this.isValid()&&this.type==0&&MxCpp.App.objectIdIsKindOf(this.id,"McDbBlockTableRecord")?MxCpp.App.objectIdToObject(this.id):null}},{key:"getMcDbLayerTableRecord",value:function(){return this.isValid()&&this.type==0&&MxCpp.App.objectIdIsKindOf(this.id,"McDbLayerTableRecord")?MxCpp.App.objectIdToObject(this.id):null}},{key:"getMcDbDimStyleTableRecord",value:function(){return this.isValid()&&this.type==0&&MxCpp.App.objectIdIsKindOf(this.id,"McDbDimStyleTableRecord")?MxCpp.App.objectIdToObject(this.id):null}},{key:"getMcDbLinetypeTableRecord",value:function(){return this.isValid()&&this.type==0&&MxCpp.App.objectIdIsKindOf(this.id,"McDbLinetypeTableRecord")?MxCpp.App.objectIdToObject(this.id):null}},{key:"getMcDbTextStyleTableRecord",value:function(){return this.isValid()&&this.type==0&&MxCpp.App.objectIdIsKindOf(this.id,"McDbTextStyleTableRecord")?MxCpp.App.objectIdToObject(this.id):null}},{key:"getMcDbDimension",value:function(){return this.isValid()&&this.type==0&&MxCpp.App.objectIdIsKindOf(this.id,"McDbDimension")?MxCpp.App.objectIdToObject(this.id):null}},{key:"getMcDbCustomEntity",value:function(){return this.isValid()&&this.type==0&&MxCpp.App.objectIdIsKindOf(this.id,"McDbCustomEntity")?MxCpp.App.objectIdToObject(this.id):null}},{key:"clone",value:function(){if(!this.isValid())return null;if(this.type==0){var l=MxCpp.App.getImp();if(l.ObjectIdIsKindOf(this.id,"McDbCustomEntity")){var n=this.getMcDbCustomEntity();return n?n.clone():null}else{var u=l.ObjectIdToMdObject(this.id);if(!u)return null;var c=u.Clone();return MxCpp.App.destroyObject(u),MxCpp.App.createCloneObject(c)}}return null}},{key:"getObjectName",value:function(){if(this.type==0)return MxCpp.App.getImp().ObjectIdToObjectName(this.id);if(this.type==1){var l=MxFun.getCurrentDraw().getMxEntity(this.id);if(l)return l.getTypeName()}return""}},{key:"getMxDbEntity",value:function(){return this.isValid()&&this.type==1?MxFun.getCurrentDraw().getMxEntity(this.id):null}},{key:"getMcDbRasterImageDef",value:function(){return this.isValid()&&this.type==0&&MxCpp.App.objectIdIsKindOf(this.id,"McDbRasterImageDef")?MxCpp.App.objectIdToObject(this.id):null}},{key:"getMcDbDictionary",value:function(){return this.isValid()&&this.type==0&&MxCpp.App.objectIdIsKindOf(this.id,"McDbDictionary")?MxCpp.App.objectIdToObject(this.id):null}},{key:"getMcDbXrecord",value:function(){return this.isValid()&&this.type==0&&MxCpp.App.objectIdIsKindOf(this.id,"McDbXrecord")?MxCpp.App.objectIdToObject(this.id):null}}]),t}(),McDbObject=function(t){_inherits$1(l,t);var e=_createSuper$6(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"getObjectID",value:function(){return new McObjectId(this.imp.GetObjectID(),0)}},{key:"erase",value:function(){return this.imp.Erase()}},{key:"isErased",value:function(){return this.imp.isErased()}},{key:"unErase",value:function(){return this.imp.unErase()}},{key:"clone",value:function(){var u=this.imp.Clone();return MxCpp.App.createCloneObject(u)}},{key:"getHandle",value:function(){return this.imp.GetHandle()}},{key:"getDatabase",value:function(){return new McDbDatabase(this.imp.GetDatabase())}},{key:"getOwnerID",value:function(){return this.imp.GetOwnerID()}},{key:"getExtensionDictionary",value:function(){return new McDbDictionary(this.imp.GetExtensionDictionary())}},{key:"isHaveExtensionDictionary",value:function(){return this.imp.IsHaveExtensionDictionary()}},{key:"createExtensionDictionary",value:function(){return this.imp.createExtensionDictionary()}},{key:"getDatabaseIndexId",value:function(){return this.imp.GetDatabaseIndexId()}},{key:"moveGripPointsAt",value:function(u,c,y,b){return this.imp.moveGripPointsAt(u,c,y,b)}},{key:"getGripPoints",value:function(){return new McGePoint3dArray(this.imp.getGripPoints())}},{key:"tempRelationObject",value:function(){return 0}},{key:"freeTempRelationObject",value:function(){}},{key:"assertObjectModification",value:function(){var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return this.imp.assertObjectModification(u)}}]),l}(McRxObject),McDbObjectArray=function(){function t(e){if(_classCallCheck$1(this,t),_defineProperty$1(this,"aryVal",[]),e){for(var l=0,n=e.length();l<n;l++){var u=e.release(l),c=MxCpp.App.createCloneObject(u);c!=null&&this.aryVal.push(c)}MxCpp.App.destroyObject(e)}}return _createClass$1(t,[{key:"forEach",value:function(l){for(var n=this.aryVal.length,u=0;u<n;u++)l(this.aryVal[u],u)}},{key:"length",value:function(){return this.aryVal.length}},{key:"empty",value:function(){return this.aryVal.length==0}}]),t}();function _createSuper$5(t){var e=_isNativeReflectConstruct$5();return function(){var n=_getPrototypeOf$1(t),u;if(e){var c=_getPrototypeOf$1(this).constructor;u=Reflect.construct(n,arguments,c)}else u=n.apply(this,arguments);return _possibleConstructorReturn$1(this,u)}}function _isNativeReflectConstruct$5(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var MxCoordConvertType=function(){function t(){_classCallCheck$1(this,t)}return _createClass$1(t,[{key:"doc2cad",value:function(l){return l}},{key:"cad2doc",value:function(l){return l}},{key:"doc2cad1",value:function(l){return new McGePoint3d(l.x,l.y,l.z)}},{key:"doc2cad2",value:function(l,n,u){return new McGePoint3d(l,n,u)}},{key:"cad2doc1",value:function(l){return new THREE.Vector3(l.x,l.y,l.z)}},{key:"cad2doc2",value:function(l,n,u){return new THREE.Vector3(l,n,u)}}]),t}(),MxCoordConvert;MxCoordConvert=new MxCoordConvertType;function getFilterImp(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null,e;return t?e=t.getImp():e=new MxCpp.mxcadassemblyimp.McDrawResbuf,e}var MxCADResbuf=function(t){_inherits$1(l,t);var e=_createSuper$5(l);function l(n){var u;if(_classCallCheck$1(this,l),n)if(n instanceof Array){u=e.call(this),u.initTempObject(new MxCpp.mxcadassemblyimp.McDrawResbuf);for(var c=n.length,y=!1,b=0;b<c;b++)if(n[b]instanceof Object){y=!0;break}if(y)u.setJson(JSON.stringify(n));else{for(var m=[],O=0;O+1<c;O+=2)typeof n[O]=="number"&&m.push({type:n[O],val:n[O+1]});m.length>0&&u.setJson(JSON.stringify(m))}}else u=e.call(this),u.constructor_MxCADResbuf(n);else u=e.call(this),u.initTempObject(new MxCpp.mxcadassemblyimp.McDrawResbuf);return _possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"Clear",value:function(){this.imp.Clear()}},{key:"forEach",value:function(u){for(var c=this.GetCount(),y=0;y<c;y++){var b=this.ItemDataType(y),m=this.ItemDataDxf(y);b==5005?u(this.AtString(y,!0).val,b,m,y):b==5009?u(this.AtPoint(y).val,b,m,y):b==5001?u(this.AtDouble(y).val,b,m,y):b==5003||b==5010?u(this.AtLong(y).val,5010,m,y):m==-8500?u(this.AtObject(y).val,-8500,-8500,y):b==-8e3||b==-8001||b==-8002||b==-8003||b==-8004?u(this.AtObjectId(y).val,-8e3,-8e3,y):u(void 0,b,m,y)}}},{key:"GetCount",value:function(){return this.imp.GetCount()}},{key:"AtDouble",value:function(u){return{val:this.imp.AtDouble(u),ret:MxCpp.getCallResult()==0}}},{key:"AtLong",value:function(u){return{val:this.imp.Atlong(u),ret:MxCpp.getCallResult()==0}}},{key:"AtObject",value:function(u){if(u>=this.imp.GetCount())return{val:void 0,ret:!1};var c=this.imp.AtObject(u),y=MxCpp.App.createCloneObject(c);return y===null?{val:void 0,ret:!1}:{val:y,ret:!0}}},{key:"AddObject",value:function(u){this.imp.AddObject(u.getImp())}},{key:"AtObjectId",value:function(u){return{val:new McObjectId(this.imp.AtObjectId(u),McObjectIdType.kMxCAD),ret:MxCpp.getCallResult()==0}}},{key:"AtString",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;if(c){var y=MxG2312Obj.decodeFromGb2312(this.imp.AtString(u));return{val:y,ret:MxCpp.getCallResult()==0}}else return{val:this.imp.AtString(u),ret:MxCpp.getCallResult()==0}}},{key:"AtPoint",value:function(u){return{val:new McGePoint3d(this.imp.AtPoint(u)),ret:MxCpp.getCallResult()==0}}},{key:"ItemDataType",value:function(u){return this.imp.ItemDataType(u)}},{key:"ItemDataDxf",value:function(u){return this.imp.ItemDataDxf(u)}},{key:"AddDouble",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:-10;return this.imp.AddDouble(u,c)}},{key:"AddLong",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:-10;return this.imp.Addlong(u,c)}},{key:"AddObjectId",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:-10;return this.imp.AddObjectId(u,c)}},{key:"AddString",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:-10,y=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;return y?this.imp.AddString(MxG2312Obj.encodeToGb2312(u),c):this.imp.AddString(u,c)}},{key:"AddMcDbEntityTypes",value:function(u){return this.imp.AddString(u,5020)}},{key:"AddPoint",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:-10;return this.imp.AddPoint(u.imp,c)}},{key:"RemoveAll",value:function(){this.imp.RemoveAll()}},{key:"Remove",value:function(u){this.imp.Remove(u)}},{key:"PrintData",value:function(){this.imp.PrintData()}}]),l}(McRxObject),MxCADUtilityClass=function(){function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0)}return _createClass$1(t,[{key:"eraseObject",value:function(l){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return this.init(),this.imp.eraseObject(l,n)}},{key:"highlightEntity",value:function(l){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return this.init(),this.imp.highlightEntity(l,n)}},{key:"findEntAtPoint",value:function(l,n,u){var c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:-1,y=arguments.length>4&&arguments[4]!==void 0?arguments[4]:null;this.init();var b=this.imp.findEntAtPoint(l,n,u,c,getFilterImp(y));return new McObjectId(b,McObjectIdType.kMxCAD)}},{key:"selectEnt",value:function(l){var n=this,u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null,c=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,y=arguments.length>3?arguments[3]:void 0,b=arguments.length>4?arguments[4]:void 0;return this.init(),new Promise(function(){var m=_asyncToGenerator(regenerator.mark(function O(N){var L,G,q,J,fe;return regenerator.wrap(function(ne){for(;;)switch(ne.prev=ne.next){case 0:return L=new MrxDbgUiPrPoint,typeof y=="function"&&y(L),l&&L.setMessage(l),L.setCursorType(MxCursorType.kRect),L.disableAllTrace(),L.setDynamicInputType(DynamicInputType.kDynTip),ne.next=8,L.go();case 8:if(G=ne.sent,G){ne.next=12;break}return N([]),ne.abrupt("return");case 12:typeof b=="function"&&b(new McGePoint3d().setFromVector3(G)),L.clearLastInputPoint(),c?MrxDbgUtils.findEntAtPoint(G).then(function(Ue){var De=[];Ue.forEach(function(Ae){De.push(new McObjectId(Ae,McObjectIdType.kMxDraw))});var Ve=MxCoordConvert.doc2cad1(G),rt=n.findEntAtPoint(Ve.x,Ve.y,Ve.z,-1,u);rt.isValid()&&De.push(rt),N(De)}):(q=[],J=MxCoordConvert.doc2cad1(G),fe=n.findEntAtPoint(J.x,J.y,J.z,-1,u),fe.isValid()&&q.push(fe),N(q));case 15:case"end":return ne.stop()}},O)}));return function(O){return m.apply(this,arguments)}}())}},{key:"getCurrentSelectPoints",value:function(){var l=MxFun.getCurrentDraw().getSelectPoints();return l.isvalid?{point1:new McGePoint3d(l.point1),point2:new McGePoint3d(l.point2),isvalid:!0}:{point1:new McGePoint3d,point2:new McGePoint3d,isvalid:!1}}},{key:"getCurrentSelect",value:function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null,n=[],u=MxFun.getCurrentDraw().getMxCurrentSelect();u.forEach(function(L){n.push(new McObjectId(L,McObjectIdType.kMxDraw))});var c=MxFun.getCurrentDraw().getMxCADCurrentSelect();if(c.length<=0)return n;if(l){var y=new McGeLongArray;c.forEach(function(L){y.append(L)});var b=new MxCpp.mxcadassemblyimp.McDrawSelSet,m=b.getFilterEntity(y.imp,getFilterImp(l));MxCpp.App.destroyObject(b),c=[];for(var O=m.length(),N=0;N<O;N++)c.push(m.at(N))}return c.forEach(function(L){n.push(new McObjectId(L,McObjectIdType.kMxCAD))}),n}},{key:"userSelect",value:function(){var e=_asyncToGenerator(regenerator.mark(function n(u){var c,y,b,m,O=arguments;return regenerator.wrap(function(L){for(;;)switch(L.prev=L.next){case 0:if(c=O.length>1&&O[1]!==void 0?O[1]:null,y=O.length>2?O[2]:void 0,b=this.getCurrentSelect(c),b.length!=0){L.next=9;break}return m=new MxCADSelectionSet,L.next=7,m.userSelect(u,c,function(G){y&&y(m,G)});case 7:if(!L.sent){L.next=9;break}m.forEach(function(G){b.push(G)});case 9:return L.abrupt("return",new Promise(function(G){G(b)}));case 10:case"end":return L.stop()}},n,this)}));function l(n){return e.apply(this,arguments)}return l}()},{key:"init",value:function(){this.imp||(this.imp=new MxCpp.mxcadassemblyimp.McDrawUtility)}},{key:"getCorner",value:function(){var e=_asyncToGenerator(regenerator.mark(function n(u,c,y){var b,m,O,N,L,G,q,J,fe=arguments;return regenerator.wrap(function(ne){for(;;)switch(ne.prev=ne.next){case 0:b=fe.length>3&&fe[3]!==void 0?fe[3]:!1,m=fe.length>4&&fe[4]!==void 0?fe[4]:!1,O=fe.length>5?fe[5]:void 0,N=0,L=void 0;case 5:if(c){ne.next=16;break}return G=new MxCADUiPrPoint,u&&G.setMessage(u),m&&G.disableAllTrace(!0),O&&O(G),G.setDynamicInputType(DynamicInputType.kDynTip),ne.next=14,G.go();case 14:c=ne.sent,N=G.getDetailedResult();case 16:if(c){ne.next=18;break}return ne.abrupt("break",26);case 18:return q=MxCoordConvert.cad2doc1(c),ne.next=21,MrxDbgUtils.getCorner(q,u,b,function(Ue){N=Ue.detailedResult},m);case 21:return J=ne.sent,J&&(L=MxCoordConvert.doc2cad1(J)),ne.abrupt("break",26);case 26:return y&&y(N),ne.abrupt("return",new Promise(function(Ue){N==DetailedResult.kEcsIn||N==DetailedResult.kNewCommadIn||N==DetailedResult.kUnknown?Ue(null):Ue(c&&L?{pt1:c,pt2:L}:null)}));case 28:case"end":return ne.stop()}},n)}));function l(n,u,c){return e.apply(this,arguments)}return l}()},{key:"getMcDbEntitysBoundingBox",value:function(l){var n=void 0,u=void 0;if(l.forEach(function(c){var y=c.getMcDbEntity();if(y!=null){var b=y.getBoundingBox();b.ret&&(!n||!u?(n=new THREE.Vector3(b.minPt.x,b.minPt.y,0),u=new THREE.Vector3(b.maxPt.x,b.maxPt.y,0)):(n.x>b.minPt.x&&(n.x=b.minPt.x),n.y>b.minPt.y&&(n.y=b.minPt.y),u.x<b.maxPt.x&&(u.x=b.maxPt.x),u.y<b.maxPt.y&&(u.y=b.maxPt.y)))}}),n&&u)return{minPt:new McGePoint3d(n),maxPt:new McGePoint3d(u)}}},{key:"calcBulge",value:function(l,n,u){var c=this.imp.calcBulge(l.imp,n.imp,u.imp);return{val:c,ret:MxCpp.getCallResult()==0}}},{key:"builderHatchFromPoint",value:function(l){var n=this.imp.builderHatchFromPoint(l.x,l.y);return n.isNull()?(MxCpp.App.destroyObject(n),null):new McDbHatch(n)}}]),t}(),MxCADUtility=new MxCADUtilityClass,MxCADSelectionSetStatus=function(t){return t[t.kSelected=0]="kSelected",t[t.kNone=1]="kNone",t[t.kCanceled=2]="kCanceled",t[t.kRejected=3]="kRejected",t[t.kKeyword=4]="kKeyword",t}(MxCADSelectionSetStatus||{}),MxCADSelectionSet=function(t){_inherits$1(l,t);var e=_createSuper$5(l);function l(){var n;return _classCallCheck$1(this,l),n=e.call(this),_defineProperty$1(_assertThisInitialized$1(n),"isWhileSelect",!0),_defineProperty$1(_assertThisInitialized$1(n),"isSelectHighlight",!0),_defineProperty$1(_assertThisInitialized$1(n),"selectPt1",new McGePoint3d),_defineProperty$1(_assertThisInitialized$1(n),"selectPt2",new McGePoint3d),n.initTempObject(new MxCpp.mxcadassemblyimp.McDrawSelSet),n}return _createClass$1(l,[{key:"getSelectPoint",value:function(){return{pt1:this.selectPt1,pt2:this.selectPt2}}},{key:"allSelect",value:function(){var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null;return this.imp.allSelect(getFilterImp(u))}},{key:"pointSelect",value:function(u,c){var y=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null,b=arguments.length>3&&arguments[3]!==void 0?arguments[3]:-1;return this.imp.pointSelect(u,c,getFilterImp(y),b)}},{key:"crossingSelect",value:function(u,c,y,b){var m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:null;return this.imp.crossingSelect(u,c,y,b,getFilterImp(m))}},{key:"count",value:function(){return this.imp.count()}},{key:"isNull",value:function(){return this.imp.count()==0}},{key:"item",value:function(u){return new McObjectId(this.imp.item(u),McObjectIdType.kMxCAD)}},{key:"forEach",value:function(u){for(var c=this.imp.count(),y=0;y<c;y++)u(this.item(y))}},{key:"getIds",value:function(){for(var u=[],c=this.imp.count(),y=0;y<c;y++)u.push(this.item(y));return u}},{key:"userSelect",value:function(){var n=_asyncToGenerator(regenerator.mark(function c(y){var b,m,O,N,L,G,q,J,fe,ve=arguments;return regenerator.wrap(function(Ue){for(;;)switch(Ue.prev=Ue.next){case 0:b=ve.length>1&&ve[1]!==void 0?ve[1]:null,m=ve.length>2?ve[2]:void 0,this.selectPt1=new McGePoint3d,this.selectPt2=new McGePoint3d,O=new MrxDbgUiPrPoint,y&&O.setMessage(y),O.setCursorType(MxCursorType.kRect),O.setDynamicInputType(DynamicInputType.kDynTip),O.disableAllTrace(),N=0,m&&m(O),L=getFilterImp(b);case 12:return O.setDynamicInputType(DynamicInputType.kDynTip),Ue.next=16,O.go();case 16:if(G=Ue.sent,O.clearLastInputPoint(),N=O.getDetailedResult(),G){Ue.next=21;break}return Ue.abrupt("break",43);case 21:if(q=MxCoordConvert.doc2cad1(G),this.imp.userPointSelect(q.x,q.y,L,this.isSelectHighlight)!=0){Ue.next=30;break}if(this.selectPt1.copy(q),this.selectPt2.copy(q),!this.isWhileSelect){Ue.next=29;break}return Ue.abrupt("continue",12);case 29:return Ue.abrupt("break",43);case 30:return Ue.next=32,MrxDbgUtils.getCorner(G,y,!0,function(De){N=De.detailedResult});case 32:if(J=Ue.sent,J){Ue.next=35;break}return Ue.abrupt("break",43);case 35:if(fe=MxCoordConvert.doc2cad1(J),this.imp.userSelect(q.x,q.y,fe.x,fe.y,L,this.isSelectHighlight),this.selectPt1.copy(q),this.selectPt2.copy(fe),this.isWhileSelect){Ue.next=41;break}return Ue.abrupt("break",43);case 41:Ue.next=12;break;case 43:if(this.isSelectHighlight&&this.imp.highlightEntity(!1),!(N==DetailedResult.kEcsIn||N==DetailedResult.kNewCommadIn||N==DetailedResult.kUnknown)){Ue.next=48;break}return Ue.abrupt("return",new Promise(function(De){De(!1)}));case 48:return Ue.abrupt("return",new Promise(function(De){De(!0)}));case 49:case"end":return Ue.stop()}},c,this)}));function u(c){return n.apply(this,arguments)}return u}()}]),l}(McRxObject),MxCADUiPrBase=function(){function t(e){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),_defineProperty$1(this,"mxobj",void 0),this.imp=e,this.mxobj=MxFun.getCurrentDraw()}return _createClass$1(t,[{key:"doc2cad1",value:function(l){return new McGePoint3d(l.x,l.y,l.z)}},{key:"doc2cad2",value:function(l,n,u){return new McGePoint3d(l,n,u)}},{key:"cad2doc1",value:function(l){return new THREE.Vector3(l.x,l.y,l.z)}},{key:"cad2doc2",value:function(l,n,u){return new THREE.Vector3(l,n,u)}},{key:"keyWords",value:function(){return this.imp.keyWords()}},{key:"setKeyWords",value:function(l){this.imp.setKeyWords(l)}},{key:"clearLastInputPoint",value:function(){this.imp.clearLastInputPoint()}},{key:"setLastInputPoint",value:function(l){this.imp.setLastInputPoint(this.cad2doc1(l))}},{key:"message",value:function(){return this.imp.message()}},{key:"setMessage",value:function(l){this.imp.setMessage(l)}},{key:"keyWordPicked",value:function(){return this.imp.keyWordPicked()}},{key:"isKeyWordPicked",value:function(l){return this.imp.isKeyWordPicked(l)}},{key:"setUserDraw",value:function(l){var n=this;this.imp.setUserDraw(function(u,c){l(n.doc2cad1(u),c)})}},{key:"getDetailedResult",value:function(){return this.imp.getDetailedResult()}},{key:"getStatus",value:function(){return this.imp.getStatus()}},{key:"drawReserve",value:function(l){this.imp.drawReserve(l)}},{key:"setInputToucheType",value:function(l){this.imp.setInputToucheType(l)}},{key:"getInputToucheType",value:function(){return this.imp.getInputToucheType()}},{key:"setCursorType",value:function(l){this.imp.setCursorType(l)}},{key:"getCursorType",value:function(){return this.imp.getCursorType()}},{key:"setDynamicInputType",value:function(l){this.imp.setDynamicInputType(l)}},{key:"getDynamicInputType",value:function(){return this.imp.getDynamicInputType()}},{key:"isDisableDynInput",value:function(){return this.imp.isDisableDynInput()}},{key:"setDisableDynInput",value:function(l){this.imp.setDisableDynInput(l)}},{key:"setDisableOsnap",value:function(l){this.imp.setDisableOsnap(l)}},{key:"isDisableOsnap",value:function(){return this.imp.isDisableOsnap()}},{key:"isOffsetInputPostion",value:function(){return this.imp.isOffsetInputPostion()}},{key:"setOffsetInputPostion",value:function(l){return this.imp.setOffsetInputPostion(l)}},{key:"setDisableDynamicTrace",value:function(l){this.imp.setDisableDynamicTrace(l)}},{key:"isDisableDynamicTrace",value:function(){return this.imp.isDisableDynamicTrace()}},{key:"setDisablePolarAxisTrace",value:function(l){this.imp.setDisablePolarAxisTrace(l)}},{key:"isDisablePolarAxisTrace",value:function(){return this.imp.isDisablePolarAxisTrace()}},{key:"setDisableGridTrace",value:function(l){this.imp.setDisableGridTrace(l)}},{key:"isDisableGridTrace",value:function(){return this.imp.isDisableGridTrace()}},{key:"setDisableOrthoTrace",value:function(l){this.imp.setDisableOrthoTrace(l)}},{key:"isDisableOrthoTrace",value:function(){return this.imp.isDisableOrtho()}},{key:"disableAllTrace",value:function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.imp.disableAllTrace(l)}},{key:"userInputControls",value:function(){return this.imp.userInputControls()}},{key:"setUserInputControls",value:function(l){this.imp.setUserInputControls(l)}},{key:"abort",value:function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:DetailedResult.kCodeAbort;this.imp.abort(l)}}]),t}(),MxCADUiPrPoint=function(t){_inherits$1(l,t);var e=_createSuper$5(l);function l(){return _classCallCheck$1(this,l),e.call(this,new MrxDbgUiPrPoint)}return _createClass$1(l,[{key:"go",value:function(){var u=this;return new Promise(function(c){u.imp.go(function(y){y!=0?c(null):c(u.doc2cad1(u.imp.value()))})})}},{key:"value",value:function(){return this.doc2cad1(this.imp.value())}},{key:"getDocValue",value:function(){return new McGePoint3d(this.imp.value())}},{key:"basePt",value:function(){return this.doc2cad1(this.imp.basePt())}},{key:"setBasePt",value:function(u){this.imp.setBasePt(this.cad2doc1(u)),this.imp.setUseBasePt(!0)}},{key:"setUseBasePt",value:function(u){this.imp.setUseBasePt(u)}}]),l}(MxCADUiPrBase),MxCADUiPrDist=function(t){_inherits$1(l,t);var e=_createSuper$5(l);function l(){return _classCallCheck$1(this,l),e.call(this,new MrxDbgUiPrDist)}return _createClass$1(l,[{key:"value",value:function(){return this.imp.value()}},{key:"basePt",value:function(){return this.doc2cad1(this.imp.basePt())}},{key:"setBasePt",value:function(u){this.imp.setBasePt(this.cad2doc1(u)),this.imp.setUseBasePt(!0)}},{key:"setUseBasePt",value:function(u){return this.imp.setUseBasePt(u)}},{key:"go",value:function(){return this.imp.go()}}]),l}(MxCADUiPrBase),MxCADUiPrAngle=function(t){_inherits$1(l,t);var e=_createSuper$5(l);function l(){return _classCallCheck$1(this,l),e.call(this,new MrxDbgUiPrAngle)}return _createClass$1(l,[{key:"value",value:function(){return this.imp.value()}},{key:"basePt",value:function(){return this.doc2cad1(this.imp.basePt())}},{key:"setBasePt",value:function(u){this.imp.setBasePt(this.cad2doc1(u)),this.imp.setUseBasePt(!0)}},{key:"setUseBasePt",value:function(u){return this.imp.setUseBasePt(u)}},{key:"go",value:function(){return this.imp.go()}}]),l}(MxCADUiPrBase),MxCADUiPrInt=function(t){_inherits$1(l,t);var e=_createSuper$5(l);function l(){return _classCallCheck$1(this,l),e.call(this,new MrxDbgUiPrInt)}return _createClass$1(l,[{key:"value",value:function(){return this.imp.value()}},{key:"go",value:function(){return this.imp.go()}}]),l}(MxCADUiPrBase),MxCADUiPrKeyWord=function(t){_inherits$1(l,t);var e=_createSuper$5(l);function l(){return _classCallCheck$1(this,l),e.call(this,new MrxDbgUiPrKeyWord)}return _createClass$1(l,[{key:"go",value:function(){return this.imp.go()}}]),l}(MxCADUiPrBase),MxCADUiPrString=function(t){_inherits$1(l,t);var e=_createSuper$5(l);function l(){var n;return _classCallCheck$1(this,l),n=e.call(this,new MrxDbgUiPrString),n.setDynamicInputType(DynamicInputType.kNoInput),n.disableAllTrace(),n}return _createClass$1(l,[{key:"value",value:function(){return this.imp.value()}},{key:"go",value:function(){return this.imp.go()}}]),l}(MxCADUiPrBase),MxCADUiPrEntity=function(t){_inherits$1(l,t);var e=_createSuper$5(l);function l(){var n;return _classCallCheck$1(this,l),n=e.call(this,new MrxDbgUiPrPoint),_defineProperty$1(_assertThisInitialized$1(n),"filter",void 0),_defineProperty$1(_assertThisInitialized$1(n),"id",new McObjectId),n.setCursorType(MxCursorType.kRect),n.setDynamicInputType(DynamicInputType.kDynTip),n.disableAllTrace(),n}return _createClass$1(l,[{key:"setFilter",value:function(u){this.filter=u}},{key:"getFilter",value:function(){return this.filter}},{key:"go",value:function(){var u=this;return new Promise(function(c){var y=u;u.imp.go(function(b){if(y.clearLastInputPoint(),b!=0)c(new McObjectId);else{var m=y.imp.value(),O=y.doc2cad1(m);y.id=MxCADUtility.findEntAtPoint(O.x,O.y,O.z,-1,y.filter),c(y.id)}})})}},{key:"pickPoint",value:function(){return this.doc2cad1(this.imp.value())}},{key:"value",value:function(){return this.id}},{key:"getDocPickPoint",value:function(){return new McGePoint3d(this.imp.value())}}]),l}(MxCADUiPrBase);function _createSuper$4(t){var e=_isNativeReflectConstruct$4();return function(){var n=_getPrototypeOf$1(t),u;if(e){var c=_getPrototypeOf$1(this).constructor;u=Reflect.construct(n,arguments,c)}else u=n.apply(this,arguments);return _possibleConstructorReturn$1(this,u)}}function _isNativeReflectConstruct$4(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var McDbEntity=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"explode",value:function(){var u=this.imp.explode();return new MxCADResbuf(u)}},{key:"trueColor",get:function(){return new McCmColor(this.imp.TrueColor())},set:function(u){this.imp.SetTrueColor(u.getImp())}},{key:"colorIndex",get:function(){return this.imp.ColorIndex()},set:function(u){this.imp.SetColorIndex(u)}},{key:"layer",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.Layer())},set:function(u){this.imp.SetLayer(MxG2312Obj.encodeToGb2312(u))}},{key:"linetype",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.Linetype())},set:function(u){this.imp.SetLinetype(MxG2312Obj.encodeToGb2312(u))}},{key:"linetypeScale",get:function(){return this.imp.LinetypeScale()},set:function(u){this.imp.SetLinetypeScale(u)}},{key:"visible",get:function(){return this.imp.Visible()},set:function(u){this.imp.SetVisible(u)}},{key:"lineweight",get:function(){return this.imp.Lineweight()},set:function(u){this.imp.SetLineweight(u)}},{key:"textStyle",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.TextStyle())},set:function(u){this.imp.SetTextStyle(MxG2312Obj.encodeToGb2312(u))}},{key:"highlight",value:function(u){this.imp.Highlight(u)}},{key:"move",value:function(u,c){this.tempRelationObject();var y=this.imp.Move(u.imp,c.imp);return this.freeTempRelationObject(),y}},{key:"rotate",value:function(u,c){this.tempRelationObject();var y=this.imp.Rotate(u.imp,c);return this.freeTempRelationObject(),y}},{key:"mirror",value:function(u,c){this.tempRelationObject();var y=this.imp.Mirror(u.imp,c.imp);return this.freeTempRelationObject(),y}},{key:"scaleEntity",value:function(u,c){this.tempRelationObject();var y=this.imp.ScaleEntity(u.imp,c);return this.freeTempRelationObject(),y}},{key:"transformBy",value:function(u){return this.imp.TransformBy(u.imp)}},{key:"getBoundingBox",value:function(){var u=this.imp.GetBoundingBox();if(u){var c={minPt:new McGePoint3d(u.AtPoint(0)),maxPt:new McGePoint3d(u.AtPoint(1)),ret:!0};return MxCpp.App.destroyObject(u),c}else return{minPt:new McGePoint3d,maxPt:new McGePoint3d,ret:!1}}},{key:"getxData",value:function(){var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return new MxCADResbuf(this.imp.GetXData(MxG2312Obj.encodeToGb2312(u)))}},{key:"setxData",value:function(u){return this.imp.SetXData(u.getImp())}},{key:"getxDataString",value:function(u){var c=this.imp.GetxDataString(MxG2312Obj.encodeToGb2312(u),0);return{val:MxG2312Obj.decodeFromGb2312(c),ret:MxCpp.getCallResult()==0}}},{key:"setxDataString",value:function(u,c){return this.imp.SetxDataString(MxG2312Obj.encodeToGb2312(u),0,MxG2312Obj.encodeToGb2312(c))}},{key:"getxDataDouble",value:function(u){return{val:this.imp.GetxDataDouble(MxG2312Obj.encodeToGb2312(u),0),ret:MxCpp.getCallResult()==0}}},{key:"setxDataDouble",value:function(u,c){return this.imp.SetxDataDouble(MxG2312Obj.encodeToGb2312(u),0,c)}},{key:"getxDataLong",value:function(u){return{val:this.imp.GetxDataLong(MxG2312Obj.encodeToGb2312(u),0),ret:MxCpp.getCallResult()==0}}},{key:"setxDataLong",value:function(u,c){return this.imp.SetxDataLong(MxG2312Obj.encodeToGb2312(u),0,c)}},{key:"getxDataPoint",value:function(u){var c=this.imp.GetxDataPoint(MxG2312Obj.encodeToGb2312(u),0),y=new McGePoint3d;if(MxCpp.getCallResult()==0){var b=!1;return c&&(y.x=c.x,y.y=c.y,y.z=c.z,MxCpp.App.getImp().DestroyMdGePoint3d(c),b=!0),{val:y,ret:b}}else return{val:y,ret:!1}}},{key:"setxDataPoint",value:function(u,c){return this.imp.SetxDataPoint(MxG2312Obj.encodeToGb2312(u),0,c.imp)}},{key:"deleteXData",value:function(u){return this.imp.DeleteXData(MxG2312Obj.encodeToGb2312(u))}},{key:"getAllAppName",value:function(){return new McGeStringArray(this.imp.GetAllAppName())}},{key:"layerId",get:function(){return new McObjectId(this.imp.LayerId(),McObjectIdType.kMxCAD)},set:function(u){u.type==McObjectIdType.kMxCAD&&this.imp.SetLayerId(u.id)}},{key:"linetypeId",get:function(){return new McObjectId(this.imp.LinetypeId(),McObjectIdType.kMxCAD)},set:function(u){u.type==McObjectIdType.kMxCAD&&this.imp.SetLinetypeId(u.id)}},{key:"textStyleId",get:function(){return new McObjectId(this.imp.TextStyleId(),McObjectIdType.kMxCAD)},set:function(u){u.type==McObjectIdType.kMxCAD&&this.imp.SetTextStyleId(u.id)}},{key:"IntersectWith",value:function(u,c){return new McGePoint3dArray(this.imp.IntersectWith(u.imp,c))}},{key:"getArea",value:function(){var u=this.imp.getArea();return{val:u,ret:MxCpp.getCallResult()==0}}},{key:"disableDisplay",value:function(u){this.imp.disableUpdateDisplay(u)}},{key:"updateDisplay",value:function(){this.imp.updateDisplay()}},{key:"syncData",value:function(){return!1}},{key:"drawOrder",get:function(){return this.imp.DrawOrder()},set:function(u){this.imp.SetDrawOrder(u)}},{key:"normal",get:function(){return new McGeVector3d(this.imp.normal())},set:function(u){this.imp.setNormal(u.imp)}}]),l}(McDbObject),McDbCurve=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"getStartParam",value:function(){var u=this.imp.getStartParam();return{val:u,ret:MxCpp.getCallResult()==0}}},{key:"getEndParam",value:function(){return{val:this.imp.getEndParam(),ret:MxCpp.getCallResult()==0}}},{key:"getDistAtParam",value:function(u){return{val:this.imp.getDistAtParam(u),ret:MxCpp.getCallResult()==0}}},{key:"getParamAtDist",value:function(u){return{val:this.imp.getParamAtDist(u),ret:MxCpp.getCallResult()==0}}},{key:"getDistAtPoint",value:function(u){return{val:this.imp.getDistAtPoint(u.imp),ret:MxCpp.getCallResult()==0}}},{key:"getPointAtDist",value:function(u){return{val:new McGePoint3d(this.imp.getPointAtDist(u)),ret:MxCpp.getCallResult()==0}}},{key:"getStartPoint",value:function(){return{val:new McGePoint3d(this.imp.getStartPoint()),ret:MxCpp.getCallResult()==0}}},{key:"getEndPoint",value:function(){return{val:new McGePoint3d(this.imp.getEndPoint()),ret:MxCpp.getCallResult()==0}}},{key:"getPointAtParam",value:function(u){return{val:new McGePoint3d(this.imp.getPointAtParam(u)),ret:MxCpp.getCallResult()==0}}},{key:"getParamAtPoint",value:function(u){return{val:this.imp.getParamAtPoint(u.imp),ret:MxCpp.getCallResult()==0}}},{key:"getFirstDerivFromParam",value:function(u){return{val:new McGeVector3d(this.imp.getFirstDeriv(u)),ret:MxCpp.getCallResult()==0}}},{key:"getFirstDeriv",value:function(u){return{val:new McGeVector3d(this.imp.getFirstDerivEx(u.imp)),ret:MxCpp.getCallResult()==0}}},{key:"getClosestPointTo",value:function(u,c){return{val:new McGePoint3d(this.imp.getClosestPointTo(u.imp,c)),ret:MxCpp.getCallResult()==0}}},{key:"offsetCurves",value:function(u,c){var y=this.imp.offsetCurves(u,c.imp);return new McDbObjectArray(y)}},{key:"splitCurves",value:function(u){var c=new MxCADResbuf;u.forEach(function(b){c.AddPoint(b)});var y=this.imp.splitCurves(c.getImp());return new McDbObjectArray(y)}},{key:"splitCurvesFromParam",value:function(u){var c=new MxCADResbuf;u.forEach(function(b){c.AddDouble(b)});var y=this.imp.splitCurves(c.getImp());return new McDbObjectArray(y)}},{key:"getSamplePoints",value:function(u){var c=this.imp.getSamplePoints(u);return new MxCADResbuf(c)}},{key:"getLength",value:function(){var u=this.imp.getLength();return{val:u,ret:MxCpp.getCallResult()==0}}}]),l}(McDbEntity),McDbLine=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n,u,c,y,b,m){var O;return _classCallCheck$1(this,l),n instanceof Object?n instanceof McGePoint3d?(O=e.call(this),O.initTempObject(new MxCpp.mxcadassemblyimp.MdDbLine),u instanceof McGePoint3d&&(O.startPoint=n,O.endPoint=u)):O=e.call(this,n):(O=e.call(this),O.initTempObject(new MxCpp.mxcadassemblyimp.MdDbLine),O.startPoint=new McGePoint3d(n,u,c),O.endPoint=new McGePoint3d(y,b,m)),_possibleConstructorReturn$1(O)}return _createClass$1(l,[{key:"startPoint",get:function(){return new McGePoint3d(this.imp.startPoint())},set:function(u){this.imp.setStartPoint(u.imp)}},{key:"endPoint",get:function(){return new McGePoint3d(this.imp.endPoint())},set:function(u){this.imp.setEndPoint(u.imp)}}]),l}(McDbCurve),McDbText=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbText),u}return _createClass$1(l,[{key:"position",get:function(){return new McGePoint3d(this.imp.position())},set:function(u){this.imp.setPosition(u.imp)}},{key:"alignmentPoint",get:function(){return new McGePoint3d(this.imp.position())},set:function(u){this.imp.setAlignmentPoint(u.imp)}},{key:"oblique",get:function(){return this.imp.oblique()},set:function(u){this.imp.setOblique(u)}},{key:"rotation",get:function(){return this.imp.rotation()},set:function(u){this.imp.setRotation(u)}},{key:"height",get:function(){return this.imp.height()},set:function(u){this.imp.setHeight(u)}},{key:"widthFactor",get:function(){return this.imp.widthFactor()},set:function(u){this.imp.setWidthFactor(u)}},{key:"textString",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.textString())},set:function(u){this.imp.setTextString(MxG2312Obj.encodeToGb2312(u))}},{key:"horizontalMode",get:function(){return this.imp.horizontalMode()},set:function(u){this.imp.setHorizontalMode(u)}},{key:"verticalMode",get:function(){return this.imp.verticalMode()},set:function(u){this.imp.setVerticalMode(u)}}]),l}(McDbEntity),McDbAttribute=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbAttribute),u}return _createClass$1(l,[{key:"tag",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.tag())},set:function(u){this.imp.setTag(MxG2312Obj.encodeToGb2312(u))}},{key:"isInvisible",get:function(){return this.imp.isInvisible()},set:function(u){this.imp.setInvisible(u)}}]),l}(McDbText),McDbAttributeDefinition=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbAttributeDefinition),u}return _createClass$1(l,[{key:"tag",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.tag())},set:function(u){this.imp.setTag(MxG2312Obj.encodeToGb2312(u))}},{key:"isInvisible",get:function(){return this.imp.isInvisible()},set:function(u){this.imp.setInvisible(u)}},{key:"prompt",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.prompt())},set:function(u){this.imp.setPrompt(MxG2312Obj.encodeToGb2312(u))}},{key:"isConstant",get:function(){return this.imp.isConstant()},set:function(u){this.imp.setConstant(u)}},{key:"isVerifiable",get:function(){return this.imp.isVerifiable()},set:function(u){this.imp.setVerifiable(u)}},{key:"isPreset",get:function(){return this.imp.isPreset()},set:function(u){this.imp.setPreset(u)}}]),l}(McDbText),McDbMText=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbMText),u}return _createClass$1(l,[{key:"location",get:function(){return new McGePoint3d(this.imp.location())},set:function(u){this.imp.setLocation(u.imp)}},{key:"rotation",get:function(){return this.imp.rotation()},set:function(u){this.imp.setRotation(u)}},{key:"width",get:function(){return this.imp.width()},set:function(u){this.imp.setWidth(u)}},{key:"textHeight",get:function(){return this.imp.textHeight()},set:function(u){this.imp.setTextHeight(u)}},{key:"attachment",get:function(){return this.imp.attachment()},set:function(u){this.imp.setAttachment(u)}},{key:"contents",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.contents())},set:function(u){this.imp.setContents(MxG2312Obj.encodeToGb2312(u))}},{key:"getTextString",value:function(){return MxG2312Obj.decodeFromGb2312(this.imp.getTextString())}}]),l}(McDbEntity),McDbCircle=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n,u,c,y){var b;return _classCallCheck$1(this,l),n instanceof Object?b=e.call(this,n):(b=e.call(this),b.initTempObject(new MxCpp.mxcadassemblyimp.MdDbCircle),typeof n=="number"&&(b.imp.setCenter(new McGePoint3d(n,u,c).imp),b.imp.setRadius(y))),_possibleConstructorReturn$1(b)}return _createClass$1(l,[{key:"setCenter",value:function(u,c,y){this.imp.setCenter(new McGePoint3d(u,c,y).imp)}},{key:"center",get:function(){return new McGePoint3d(this.imp.center())},set:function(u){this.imp.setCenter(u.imp)}},{key:"radius",get:function(){return this.imp.radius()},set:function(u){this.imp.setRadius(u)}}]),l}(McDbCurve),McDbPolyline=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbPolyline),u}return _createClass$1(l,[{key:"isClosed",get:function(){return this.imp.isClosed()},set:function(u){this.imp.setClosed(u)}},{key:"constantWidth",get:function(){return this.imp.getConstantWidth()},set:function(u){this.imp.setConstantWidth(u)}},{key:"addVertexAt",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,y=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,b=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;if(u instanceof THREE.Vector3){var O=new MxCpp.mxcadassemblyimp.MdGePoint3d;return O.x=u.x,O.y=u.y,O.z=u.z,this.imp.addVertexAt(m,O,c,y,b)}else return this.imp.addVertexAt(m,u.imp,c,y,b)}},{key:"removeVertexAt",value:function(u){return this.imp.removeVertexAt(u)}},{key:"numVerts",value:function(){return this.imp.numVerts()}},{key:"getPointAt",value:function(u){return{val:new McGePoint3d(this.imp.getPointAt(u)),ret:MxCpp.getCallResult()}}},{key:"getBulgeAt",value:function(u){return this.imp.getBulgeAt(u)}},{key:"getWidthsAt",value:function(u){return{val1:this.imp.getStartWidthsAt(u),val2:this.imp.getEndWidthsAt(u),ret:MxCpp.getCallResult()==0}}},{key:"setPointAt",value:function(u,c){return this.imp.setPointAt(u,c.imp)}},{key:"setBulgeAt",value:function(u,c){return this.imp.setBulgeAt(u,c)}},{key:"setWidthsAt",value:function(u,c,y){return this.imp.setWidthsAt(u,c,y)}},{key:"getType",value:function(){return this.imp.getType()}},{key:"setType",value:function(u){return this.imp.setType(u)}}]),l}(McDbCurve),McDbBlockReference=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbBlockReference),u}return _createClass$1(l,[{key:"blockTableRecordId",get:function(){return new McObjectId(this.imp.blockTableRecordId(),McObjectIdType.kMxCAD)},set:function(u){this.imp.setBlockTableRecordId(u.id)}},{key:"position",get:function(){return new McGePoint3d(this.imp.position())},set:function(u){this.imp.setPosition(u.imp)}},{key:"scaleFactors",get:function(){return new McGePoint3d(this.imp.scaleFactors())},set:function(u){this.imp.setScaleFactors(u.imp)}},{key:"setScale",value:function(u){this.imp.setScaleFactors(new McGePoint3d(u,u,u).imp)}},{key:"getScale",value:function(){return this.imp.scaleFactors().x}},{key:"rotation",get:function(){return this.imp.rotation()},set:function(u){this.imp.setRotation(u)}},{key:"blockTransform",get:function(){return new McGeMatrix3d(this.imp.blockTransform())},set:function(u){this.imp.setBlockTransform(u.imp)}},{key:"blockName",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.getBlockName())}},{key:"appendAttribute",value:function(u){return new McObjectId(this.imp.appendAttribute(u.getImp()),McObjectIdType.kMxCAD)}},{key:"getAllAttribute",value:function(){for(var u=[],c=this.imp.getAllAttribute(),y=c.length(),b=0;b<y;b++)u.push(new McObjectId(c.at(b),McObjectIdType.kMxCAD));return MxCpp.App.getImp().DestroyMdGeLongArray(c),u}},{key:"createAttribute",value:function(){return this.imp.createAttribute()}},{key:"getSpatialFilterId",value:function(){return new McObjectId(this.imp.getSpatialFilterId(),McObjectIdType.kMxCAD)}},{key:"createSpatialFilter",value:function(){return this.imp.createSpatialFilter()}},{key:"clearSpatialFilterCache",value:function(){return this.imp.clearSpatialFilterCache()}}]),l}(McDbEntity),McDbSpatialFilter=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbSpatialFilter),u}return _createClass$1(l,[{key:"boundary",value:function(){return new McGePoint3dArray(this.imp.boundary())}},{key:"setBoundary",value:function(u){return this.imp.setBoundary(u.imp)}},{key:"isFilterInverted",value:function(){return this.imp.isFilterInverted()}},{key:"setFilterInverted",value:function(u){return this.imp.setFilterInverted(u)}},{key:"isEnabled",value:function(){return this.imp.isEnabled()}},{key:"setEnable",value:function(u){return this.imp.setEnable(u)}}]),l}(McDbObject),McDbDimension=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"textPosition",get:function(){return new McGePoint3d(this.imp.textPosition())},set:function(u){this.imp.setTextPosition(u.imp)}},{key:"isUsingDefaultTextPosition",value:function(){return this.imp.isUsingDefaultTextPosition()}},{key:"useSetTextPosition",value:function(){return this.imp.useSetTextPosition()}},{key:"useDefaultTextPosition",value:function(){return this.imp.useDefaultTextPosition()}},{key:"elevation",get:function(){return this.imp.elevation()},set:function(u){this.imp.setElevation(u)}},{key:"dimensionText",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.dimensionText())},set:function(u){this.imp.setDimensionText(MxG2312Obj.encodeToGb2312(u))}},{key:"textRotation",get:function(){return this.imp.textRotation()},set:function(u){this.imp.setTextRotation(u)}},{key:"dimensionStyle",get:function(){return new McObjectId(this.imp.dimensionStyle(),McObjectIdType.kMxCAD)},set:function(u){this.imp.setDimensionStyle(u.id)}},{key:"textAttachment",get:function(){return this.imp.textAttachment()},set:function(u){this.imp.setTextAttachment(u)}},{key:"horizontalRotation",get:function(){return this.imp.horizontalRotation()},set:function(u){this.imp.setHorizontalRotation(u)}},{key:"recomputeDimBlock",value:function(){this.imp.recomputeDimBlock(!0)}},{key:"getDimVarInt",value:function(u){return this.imp.GetDimVarInt(u)}},{key:"setDimVarInt",value:function(u,c){this.imp.SetDimVarInt(u,c)}},{key:"getDimVarDouble",value:function(u){return this.imp.GetDimVarDouble(u)}},{key:"setDimVarDouble",value:function(u,c){this.imp.SetDimVarDouble(u,c)}},{key:"getDimVarString",value:function(u){return this.imp.GetDimVarString(u)}},{key:"setDimVarString",value:function(u,c){this.imp.SetDimVarString(u,c)}},{key:"getDimVarObjectId",value:function(u){return new McObjectId(this.imp.GetDimVarObjectId(u),McObjectIdType.kMxCAD)}},{key:"setDimVarObjectId",value:function(u,c){this.imp.SetDimVarObjectId(u,c.id)}},{key:"GetAllText",value:function(){return new McGeStringArray(this.imp.GetAllText())}}]),l}(McDbEntity),McDbAlignedDimension=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbAlignedDimension),u}return _createClass$1(l,[{key:"xLine1Point",get:function(){return new McGePoint3d(this.imp.xLine1Point())},set:function(u){this.imp.setXLine1Point(u.imp)}},{key:"xLine2Point",get:function(){return new McGePoint3d(this.imp.xLine2Point())},set:function(u){this.imp.setXLine2Point(u.imp)}},{key:"dimLinePoint",get:function(){return new McGePoint3d(this.imp.dimLinePoint())},set:function(u){this.imp.setDimLinePoint(u.imp)}},{key:"oblique",get:function(){return this.imp.oblique()},set:function(u){this.imp.setOblique(u)}}]),l}(McDbDimension),McDbRotatedDimension=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbRotatedDimension),u}return _createClass$1(l,[{key:"xLine1Point",get:function(){return new McGePoint3d(this.imp.xLine1Point())},set:function(u){this.imp.setXLine1Point(u.imp)}},{key:"xLine2Point",get:function(){return new McGePoint3d(this.imp.xLine2Point())},set:function(u){this.imp.setXLine2Point(u.imp)}},{key:"dimLinePoint",get:function(){return new McGePoint3d(this.imp.dimLinePoint())},set:function(u){this.imp.setDimLinePoint(u.imp)}},{key:"oblique",get:function(){return this.imp.oblique()},set:function(u){this.imp.setOblique(u)}},{key:"rotation",get:function(){return this.imp.rotation()},set:function(u){this.imp.setRotation(u)}}]),l}(McDbDimension),McDb2LineAngularDimension=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDb2LineAngularDimension),u}return _createClass$1(l,[{key:"arcPoint",get:function(){return new McGePoint3d(this.imp.arcPoint())},set:function(u){this.imp.setArcPoint(u.imp)}},{key:"xLine1Start",get:function(){return new McGePoint3d(this.imp.xLine1Start())},set:function(u){this.imp.setXLine1Start(u.imp)}},{key:"xLine1End",get:function(){return new McGePoint3d(this.imp.xLine1End())},set:function(u){this.imp.setXLine1End(u.imp)}},{key:"xLine2Start",get:function(){return new McGePoint3d(this.imp.xLine2Start())},set:function(u){this.imp.setXLine2Start(u.imp)}},{key:"xLine2End",get:function(){return new McGePoint3d(this.imp.xLine2End())},set:function(u){this.imp.setXLine2End(u.imp)}},{key:"compute",value:function(u,c,y,b,m,O,N,L){return this.imp.compute(u,c,y,b,m,O,N,L)}}]),l}(McDbDimension),McDbArc=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbArc),u}return _createClass$1(l,[{key:"setCenter",value:function(u,c,y){this.imp.setCenter(new McGePoint3d(u,c,y).imp)}},{key:"center",get:function(){return new McGePoint3d(this.imp.center())},set:function(u){this.imp.setCenter(u.imp)}},{key:"radius",get:function(){return this.imp.radius()},set:function(u){this.imp.setRadius(u)}},{key:"startAngle",get:function(){return this.imp.startAngle()},set:function(u){this.imp.setStartAngle(u)}},{key:"endAngle",get:function(){return this.imp.endAngle()},set:function(u){this.imp.setEndAngle(u)}},{key:"computeArc",value:function(u,c,y,b,m,O){return this.imp.computeArc(u,c,y,b,m,O)}}]),l}(McDbCurve),McDbEllipse=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n,u,c,y,b,m,O,N,L){var G;return _classCallCheck$1(this,l),n instanceof Object?G=e.call(this,n):(G=e.call(this),G.initTempObject(new MxCpp.mxcadassemblyimp.MdDbEllipse),typeof n=="number"&&(O||(O=1),typeof N!="number"&&(N=0),typeof L!="number"&&(L=Math.PI*2),G.imp.InitData(new McGePoint3d(n,u,c).imp,new McGeVector3d(y,b,m).imp,O,N,L))),_possibleConstructorReturn$1(G)}return _createClass$1(l,[{key:"setCenter",value:function(u,c,y){this.imp.setCenter(new McGePoint3d(u,c,y).imp)}},{key:"center",get:function(){return new McGePoint3d(this.imp.center())},set:function(u){this.imp.setCenter(u.imp)}},{key:"setMajorAxis",value:function(u,c,y){this.imp.setMajorAxis(new McGeVector3d(u,c,y).imp)}},{key:"majorAxis",get:function(){return new McGeVector3d(this.imp.majorAxis())},set:function(u){this.imp.setMajorAxis(u.imp)}},{key:"setMinorAxis",value:function(u,c,y){this.imp.setMinorAxis(new McGeVector3d(u,c,y).imp)}},{key:"minorAxis",get:function(){return new McGeVector3d(this.imp.minorAxis())},set:function(u){this.imp.setMinorAxis(u.imp)}},{key:"radiusRatio",get:function(){return this.imp.radiusRatio()},set:function(u){this.imp.setRadiusRatio(u)}},{key:"startAngle",get:function(){return this.imp.startAngle()},set:function(u){this.imp.setStartAngle(u)}},{key:"endAngle",get:function(){return this.imp.endAngle()},set:function(u){this.imp.setEndAngle(u)}}]),l}(McDbCurve),McDbPoint=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),n instanceof Object?n instanceof McGePoint3d?(y=e.call(this),y.initTempObject(new MxCpp.mxcadassemblyimp.MdDbPoint),y.imp.setPosition(n.imp)):y=e.call(this,n):(y=e.call(this),y.initTempObject(new MxCpp.mxcadassemblyimp.MdDbPoint),typeof n=="number"&&y.imp.setPosition(new McGePoint3d(n,u,c).imp)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"setPosition",value:function(u,c,y){this.imp.setPosition(new McGePoint3d(u,c,y).imp)}},{key:"position",get:function(){return new McGePoint3d(this.imp.position())},set:function(u){this.imp.setPosition(u.imp)}}]),l}(McDbEntity),McDbHatch=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),n instanceof Object?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbHatch)),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"numLoops",get:function(){return this.imp.numLoops()}},{key:"loopTypeAt",value:function(u){return this.imp.loopTypeAt(u)}},{key:"getLoopAt",value:function(u){var c=this.imp.getLoopAt(u);if(!c)return{ret:!1,lootype:0,vertices:[],bulges:[]};var y=c.GetCount();if(y<=0)return MxCpp.App.destroyObject(c),{ret:!1,lootype:0,vertices:[],bulges:[]};var b=0;b=c.Atlong(0);for(var m=[],O=[],N=1;N+1<y;N+=2)m.push(new McGePoint3d(c.AtPoint(N))),O.push(c.AtDouble(N+1));return MxCpp.App.destroyObject(c),{ret:!0,lootype:b,vertices:m,bulges:O}}},{key:"patternType",value:function(){return this.imp.patternType()}},{key:"patternName",value:function(){return MxG2312Obj.decodeFromGb2312(this.imp.patternName())}},{key:"setPattern",value:function(u,c){this.imp.setPattern(u,MxG2312Obj.encodeToGb2312(c))}},{key:"patternAngle",get:function(){return this.imp.patternAngle()},set:function(u){this.imp.setPatternAngle(u)}},{key:"patternScale",get:function(){return this.imp.patternScale()},set:function(u){this.imp.setPatternScale(u)}},{key:"patternSpace",get:function(){return this.imp.patternSpace()},set:function(u){this.imp.setPatternSpace(u)}},{key:"patternDouble",get:function(){return this.imp.patternDouble()},set:function(u){this.imp.setPatternDouble(u)}},{key:"numPatternDefinitions",get:function(){return this.imp.numPatternDefinitions()}},{key:"getPatternDefinitionAt",value:function(u){var c=this.imp.getPatternDefinitionAt(u);if(!c)return{ret:!1,angle:0,baseX:0,baseY:0,offsetX:0,offsetY:0,aryDashes:[]};var y=c.length();if(y<5)return MxCpp.App.getImp().DestroyMdGeDoubleArray(c),{ret:!1,angle:0,baseX:0,baseY:0,offsetX:0,offsetY:0,aryDashes:[]};for(var b=c.at(0),m=c.at(1),O=c.at(2),N=c.at(3),L=c.at(4),G=[],q=5;q<y;q++)G.push(c.at(q));return MxCpp.App.getImp().DestroyMdGeDoubleArray(c),{ret:!1,angle:b,baseX:m,baseY:O,offsetX:N,offsetY:L,aryDashes:G}}},{key:"addPatternDefinition",value:function(u,c,y,b,m,O){var N=new McGeDoubleArray;return O.forEach(function(L){N.append(L)}),this.imp.addPatternDefinition(u,c,y,b,m,N.imp)}},{key:"clearPatternDefinition",value:function(){return this.imp.clearPatternDefinition()}},{key:"hatchStyle",value:function(){return this.imp.hatchStyle()}},{key:"setHatchStyle",value:function(u){return this.imp.setHatchStyle(u)}},{key:"evaluateHatch",value:function(){return this.imp.evaluateHatch(!1)}},{key:"appendLoop",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],y=arguments.length>2&&arguments[2]!==void 0?arguments[2]:McDb.HatchLoopType.kPolyline,b=new McGeDoubleArray;return c.forEach(function(m){b.append(m)}),this.imp.appendLoop(y,u.imp,b.imp)}},{key:"appendCircleLoop",value:function(u,c,y){var b=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:McDb.HatchLoopType.kPolyline;return this.imp.appendCircleLoop(m,u,c,0,y,b)}},{key:"removeLoopAt",value:function(u){return this.imp.removeLoopAt(u)}},{key:"removeAllLoop",value:function(){return this.imp.removeAllLoop()}},{key:"setLoopAt",value:function(u,c,y){var b=arguments.length>3&&arguments[3]!==void 0?arguments[3]:McDb.HatchLoopType.kPolyline,m=new McGeDoubleArray;return y.forEach(function(O){m.append(O)}),this.imp.setLoopAt(u,b,c.imp,m.imp)}},{key:"isSolid",value:function(){return this.imp.isSolid()}}]),l}(McDbEntity),McDbProxyEntity=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),n instanceof Object?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbProxyEntity)),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"getAllTextContent",value:function(){return new McGeStringArray(this.imp.getAllTextContent())}},{key:"getAllEntityIds",value:function(){for(var u=[],c=this.imp.getAllEntityIds(),y=c.length(),b=0;b<y;b++)u.push(new McObjectId(c.at(b),McObjectIdType.kMxCAD));return MxCpp.App.getImp().DestroyMdGeLongArray(c),u}},{key:"getOriginalClassName",value:function(){return this.imp.getOriginalClassName()}}]),l}(McDbEntity),McDbRasterImage=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),n instanceof Object?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbRasterImage)),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"setOrientation",value:function(u,c,y){return this.imp.setOrientation(u.imp,c.imp,y.imp)}},{key:"getOrientation",value:function(){var u=this.imp.getOrientation();if(u.length()<3)return{origin:new McGePoint3d,uCorner:McGeVector3d.kXAxis.clone(),vOnPlane:McGeVector3d.kYAxis.clone()};var c=new McGePoint3d(u.at(0)),y=new McGeVector3d(u.at(1)),b=new McGeVector3d(u.at(2));return{origin:c,uCorner:y,vOnPlane:b}}},{key:"setImageDefId",value:function(u){u.type==McObjectIdType.kMxCAD&&this.imp.setImageDefId(u.id)}},{key:"imageDefId",value:function(){return new McObjectId(this.imp.imageDefId(),McObjectIdType.kMxCAD)}},{key:"setClipBoundary",value:function(u,c){return this.imp.setClipBoundary(u,c.imp)}},{key:"clipBoundary",value:function(){return new McGePoint3dArray(this.imp.clipBoundary())}},{key:"clipBoundaryType",value:function(){return this.imp.clipBoundaryType()}}]),l}(McDbEntity),McDbWipeout=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){var u;return _classCallCheck$1(this,l),n instanceof Object?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbWipeout)),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"setVertices",value:function(u){return this.imp.setVertices(u.imp)}},{key:"getVertices",value:function(){return new McGePoint3dArray(this.imp.getVertices())}}]),l}(McDbEntity),McDbBackgroundEntity=function(t){_inherits$1(l,t);var e=_createSuper$4(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"setShow",value:function(u,c){return this.imp.setShow(MxG2312Obj.encodeToGb2312(u),c)}},{key:"isShow",value:function(u){return this.imp.isShow(MxG2312Obj.encodeToGb2312(u))}},{key:"setShowColor",value:function(u,c){return this.imp.setShowColor(MxG2312Obj.encodeToGb2312(u),c)}},{key:"getBackgroundDatabase",value:function(u){var c=this.imp.getBackgroundDatabase(MxG2312Obj.encodeToGb2312(u));return c.isNull()?(MxCpp.App.destroyObject(c),null):new McDbDatabase(c)}},{key:"clearAll",value:function(){return this.imp.clearAll()}},{key:"clearDwg",value:function(u){return this.imp.clearDwg(MxG2312Obj.encodeToGb2312(u))}}]),l}(McDbEntity);function _createSuper$3(t){var e=_isNativeReflectConstruct$3();return function(){var n=_getPrototypeOf$1(t),u;if(e){var c=_getPrototypeOf$1(this).constructor;u=Reflect.construct(n,arguments,c)}else u=n.apply(this,arguments);return _possibleConstructorReturn$1(this,u)}}function _isNativeReflectConstruct$3(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var MxCADCloneType=function(t){return t[t.kClone=1]="kClone",t[t.kDragClone=2]="kDragClone",t[t.kCPPClone=3]="kCPPClone",t}(MxCADCloneType||{}),IMcDbDwgFiler=function(){function t(e){_classCallCheck$1(this,t),_defineProperty$1(this,"type",1),this.type=e}return _createClass$1(t,[{key:"getType",value:function(){return this.type}},{key:"writePoints",value:function(l,n){var u=this;this.writeLong(l+"_n",n.length),n.forEach(function(c,y){u.writePoint(l+"_"+y,c)})}},{key:"readPoints",value:function(l){var n=[],u=this.readLong(l+"_n");if(u.ret)for(var c=0;c<u.val;c++){var y=this.readPoint(l+"_"+c);y.ret&&n.push(y.val)}return{val:n,ret:!0}}}]),t}(),McDbDwgFiler=function(t){_inherits$1(l,t);var e=_createSuper$3(l);function l(){var n,u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:1;return _classCallCheck$1(this,l),n=e.call(this,u),_defineProperty$1(_assertThisInitialized$1(n),"data",{}),n}return _createClass$1(l,[{key:"writePoint",value:function(u,c){this.data[u]=c.clone()}},{key:"readPoint",value:function(u){return this.data[u]&&this.data[u]instanceof McGePoint3d?{val:this.data[u],ret:!0}:{val:new McGePoint3d(0,0,0),ret:!1}}},{key:"writeLong",value:function(u,c){this.data[u]=c}},{key:"readLong",value:function(u){return this.data[u]&&typeof this.data[u]=="number"?{val:this.data[u],ret:!0}:{val:0,ret:!1}}},{key:"writeDouble",value:function(u,c){this.data[u]=c}},{key:"readDouble",value:function(u){return this.data[u]&&typeof this.data[u]=="number"?{val:this.data[u],ret:!0}:{val:0,ret:!1}}},{key:"writeString",value:function(u,c){this.data[u]=c}},{key:"readString",value:function(u){return this.data[u]&&typeof this.data[u]=="string"?{val:this.data[u],ret:!0}:{val:"",ret:!1}}}]),l}(IMcDbDwgFiler),MxCADWorldDraw=function(){function t(e){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),this.imp=new MxCpp.mxcadassemblyimp.MdGiWorldDraw(e)}return _createClass$1(t,[{key:"drawEntity",value:function(l){this.imp.drawEntity(l.imp)}},{key:"drawOsnapEntity",value:function(l){this.imp.drawOsnapEntity(l.imp)}},{key:"trueColor",get:function(){return new McCmColor(this.imp.trueColor())},set:function(l){this.imp.setTrueColor(l.getImp())}}]),t}(),McDbCustomEntity=function(t){_inherits$1(l,t);var e=_createSuper$3(l);function l(n){var u;return _classCallCheck$1(this,l),n instanceof Object?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbCustomEntity(u.getTypeName()))),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"rxInit",value:function(){MxCustomEntityManager.rxInit(this)}},{key:"clone",value:function(){var u=1,c=this.create(),y=new McDbDwgFiler(u);return this.dwgOutFields(y),c.dwgInFields(y),c}},{key:"syncData",value:function(){var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;if(u){var c=this.imp.getFilter(!0),y=new McDbDwgFilerCpp(c);this.dwgOutFields(y),MxCpp.App.getImp().DestroyMdDbCustomEntityDwgFiler(c)}else{var b=this.imp.getFilter(!1),m=new McDbDwgFilerCpp(b);this.dwgInFields(m),MxCpp.App.getImp().DestroyMdDbCustomEntityDwgFiler(b)}return!0}},{key:"tempRelationObject",value:function(){return MxCustomEntityManager.tmpRelationObject(this)}},{key:"freeTempRelationObject",value:function(){MxCustomEntityManager.freeTmpObject(this)}},{key:"assertWrite",value:function(){var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.imp.assertWrite(u,!0,!0,!0,!1)}},{key:"moveGripPointsAt",value:function(u,c,y,b){}},{key:"getGripPoints",value:function(){return new McGePoint3dArray}},{key:"transformBy",value:function(u){return!1}}]),l}(McDbEntity);function _createSuper$2(t){var e=_isNativeReflectConstruct$2();return function(){var n=_getPrototypeOf$1(t),u;if(e){var c=_getPrototypeOf$1(this).constructor;u=Reflect.construct(n,arguments,c)}else u=n.apply(this,arguments);return _possibleConstructorReturn$1(this,u)}}function _isNativeReflectConstruct$2(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var MxCustomEntityManagerImp=function(){function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"mapType2Create",new Map),_defineProperty$1(this,"mapId2DatabaseMap",{}),_defineProperty$1(this,"alloc_id",1),_defineProperty$1(this,"alloc_tempid",1),_defineProperty$1(this,"mapTempId2Entity",new Map)}return _createClass$1(t,[{key:"rxInit",value:function(l){var n=l.getTypeName();this.mapType2Create.get(n)&&console.error("MxCADError:already has this class name "+n),this.mapType2Create.set(n,l)}},{key:"tmpRelationObject",value:function(l){return this.alloc_tempid>9007199254740900&&(this.alloc_tempid=1),this.alloc_tempid+=1,l.imp.setCustomEntityTempid(this.alloc_tempid),this.mapTempId2Entity.set(this.alloc_tempid,l),this.alloc_tempid}},{key:"freeTmpObject",value:function(l){if(typeof l=="number")this.mapTempId2Entity.delete(l);else{var n=l.imp.getCustomEntityTempid();l.imp.setCustomEntityTempid(0),this.mapTempId2Entity.delete(n)}}},{key:"getTmpObject",value:function(l){return this.mapTempId2Entity.get(l)}},{key:"allocId",value:function(){return this.alloc_id>9007199254740900&&(this.alloc_id=1),this.alloc_id+=1,this.alloc_id}},{key:"isHaveType",value:function(l){return this.mapType2Create.has(l)}},{key:"createMxEntity",value:function(l,n){if(l.length==0)return console.log("MxTip:assert(0) typeName is empty "),null;var u=this.mapType2Create.get(l);if(!u)return console.error("mx: error crate,no type name:"+l),null;var c=u.create(n);return c.getTypeName()!=l&&console.error("mx: error crate Type:"+l+","+c.getTypeName()),c}},{key:"relationObject",value:function(l,n){if(n==0)return 0;var u=this.allocId(),c=this.mapId2DatabaseMap[n];return c||(c=new Map,this.mapId2DatabaseMap[n]=c),c.set(u,{idIndex:l,init:!1,customEntity:null}),u}},{key:"freeObject",value:function(l){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;if(n!=0){var u=this.mapId2DatabaseMap[n];if(!u)return;u.delete(l);return}else for(var c in this.mapId2DatabaseMap){var y=this.mapId2DatabaseMap[c];y.delete(l)}}},{key:"freeDatabase",value:function(l){this.mapId2DatabaseMap.hasOwnProperty(l)&&delete this.mapId2DatabaseMap[l]}},{key:"getObjectFormId",value:function(l){return l.isValid()&&l.type==McObjectIdType.kMxCAD&&MxCpp.App.objectIdIsKindOf(l.id,"McDbCustomEntity")?MxCpp.App.objectIdToObject(l.id):null}},{key:"getObject",value:function(l){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;if(l==0)return null;var u=void 0;if(n!=0){var c=this.mapId2DatabaseMap[n];if(!c)return null;u=c.get(l)}else for(var y in this.mapId2DatabaseMap){var b=this.mapId2DatabaseMap[y];if(u=b.get(l),u){n=parseInt(y);break}}if(!u)return null;if(u.customEntity)return u.customEntity;if(u.init)return null;u.init=!0;var m=MxCpp.App.getImp().ObjectIdToMdDbCustomEntity(u.idIndex);if(!m)return null;var O=MxCustomEntityManager.createMxEntity(m.getCustomEntityTypeName(),m);return O==null?null:(O.syncData(!1),u.customEntity=O,O)}},{key:"init",value:function(){var l=window;l.MxCustomEntityManager_freeObject=function(n,u){MxCustomEntityManager.freeObject(n,u)},l.MxCustomEntityManager_relationObject=function(n,u){return MxCustomEntityManager.relationObject(n,u)},l.MxCustomEntityManager_freeDatabase=function(n){MxCustomEntityManager.freeDatabase(n)},l.MxCustomEntityManager_worldDraw=function(n,u,c,y,b,m){var O;if(y!=0?O=MxCustomEntityManager.getTmpObject(y):O=MxCustomEntityManager.getObject(n,u),!!O){var N=new MxCADWorldDraw(c);b!==0&&N.imp.connectVecOsnapEntity(b),m!==0&&N.imp.connectVecExplodeEntity(m),O.worldDraw(N)}},l.MxCustomEntityManager_syncData=function(n,u,c){var y=MxCustomEntityManager.getObject(n,u);y&&y.syncData(c!=0)},l.MxCustomEntityManager_transformBy=function(n,u,c,y){var b=new McGeMatrix3d;b.imp.copyFormPointer(c);var m;y!=0?m=MxCustomEntityManager.getTmpObject(y):m=MxCustomEntityManager.getObject(n,u),m&&m.transformBy(b)}}}]),t}(),McDbDwgFilerCpp=function(t){_inherits$1(l,t);var e=_createSuper$2(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,MxCADCloneType.kCPPClone),_defineProperty$1(_assertThisInitialized$1(u),"imp",void 0),n||(n=new MxCpp.mxcadassemblyimp.MdDbCustomEntityDwgFiler),u.imp=n,u}return _createClass$1(l,[{key:"writePoint",value:function(u,c){this.imp.writePoint(u,c.imp.x,c.imp.y,c.imp.z)}},{key:"readPoint",value:function(u){var c=this.imp.readPoint(u),y={};return MxCpp.getCallResult()==0?y={val:new McGePoint3d(c),ret:!0}:y={val:new McGePoint3d,ret:!1},MxCpp.App.getImp().DestroyMdGePoint3d(c),y}},{key:"writeLong",value:function(u,c){this.imp.writeLong(u,c)}},{key:"readLong",value:function(u){var c=this.imp.readLong(u),y={};return MxCpp.getCallResult()==0?y={val:c,ret:!0}:y={val:0,ret:!1},y}},{key:"writeDouble",value:function(u,c){this.imp.writeDouble(u,c)}},{key:"readDouble",value:function(u){var c=this.imp.readDouble(u),y={};return MxCpp.getCallResult()==0?y={val:c,ret:!0}:y={val:0,ret:!1},y}},{key:"writeString",value:function(u,c){this.imp.writeString(u,MxG2312Obj.encodeToGb2312(c))}},{key:"readString",value:function(u){var c=this.imp.readString(u),y={};return MxCpp.getCallResult()==0?y={val:MxG2312Obj.decodeFromGb2312(c),ret:!0}:y={val:"",ret:!1},y}}]),l}(IMcDbDwgFiler),MxCustomEntityManager;MxCustomEntityManager=new MxCustomEntityManagerImp;function _createSuper$1(t){var e=_isNativeReflectConstruct$1();return function(){var n=_getPrototypeOf$1(t),u;if(e){var c=_getPrototypeOf$1(this).constructor;u=Reflect.construct(n,arguments,c)}else u=n.apply(this,arguments);return _possibleConstructorReturn$1(this,u)}}function _isNativeReflectConstruct$1(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var DxfCode=function(t){return t[t.kEntityType=5020]="kEntityType",t[t.kLayer=8]="kLayer",t[t.kBlockName=2]="kBlockName",t[t.kColor=62]="kColor",t[t.kAppName=-3]="kAppName",t[t.kLong=1071]="kLong",t[t.kDouble=1040]="kDouble",t[t.kString=1e3]="kString",t[t.kPoint=1010]="kPoint",t[t.kEntityId=-8e3]="kEntityId",t[t.kEntity=-8500]="kEntity",t[t.kExDataName=1001]="kExDataName",t}(DxfCode||{}),McDb;(function(t){(function(e){e[e.kLwPolyline=0]="kLwPolyline",e[e.k3dPolyline=2]="k3dPolyline"})(t.PolylineType||(t.PolylineType={})),function(e){e[e.kTextLeft=0]="kTextLeft",e[e.kTextCenter=1]="kTextCenter",e[e.kTextRight=2]="kTextRight",e[e.kTextAlign=3]="kTextAlign",e[e.kTextMid=4]="kTextMid",e[e.kTextFit=5]="kTextFit"}(t.TextHorzMode||(t.TextHorzMode={})),function(e){e[e.kOnBothOperands=0]="kOnBothOperands",e[e.kExtendThis=1]="kExtendThis",e[e.kExtendArg=2]="kExtendArg",e[e.kExtendBoth=3]="kExtendBoth"}(t.Intersect||(t.Intersect={})),function(e){e[e.kTextBase=0]="kTextBase",e[e.kTextBottom=1]="kTextBottom",e[e.kTextVertMid=2]="kTextVertMid",e[e.kTextTop=3]="kTextTop"}(t.TextVertMode||(t.TextVertMode={})),function(e){e[e.kTopLeft=1]="kTopLeft",e[e.kTopCenter=2]="kTopCenter",e[e.kTopRight=3]="kTopRight",e[e.kMiddleLeft=4]="kMiddleLeft",e[e.kMiddleCenter=5]="kMiddleCenter",e[e.kMiddleRight=6]="kMiddleRight",e[e.kBottomLeft=7]="kBottomLeft",e[e.kBottomCenter=8]="kBottomCenter",e[e.kBottomRight=9]="kBottomRight",e[e.kBaseLeft=10]="kBaseLeft",e[e.kBaseCenter=11]="kBaseCenter",e[e.kBaseRight=12]="kBaseRight",e[e.kBaseAlign=13]="kBaseAlign",e[e.kBottomAlign=14]="kBottomAlign",e[e.kMiddleAlign=15]="kMiddleAlign",e[e.kTopAlign=16]="kTopAlign",e[e.kBaseFit=17]="kBaseFit",e[e.kBottomFit=18]="kBottomFit",e[e.kMiddleFit=19]="kMiddleFit",e[e.kTopFit=20]="kTopFit",e[e.kBaseMid=21]="kBaseMid",e[e.kBottomMid=22]="kBottomMid",e[e.kMiddleMid=23]="kMiddleMid",e[e.kTopMid=24]="kTopMid"}(t.AttachmentPoint||(t.AttachmentPoint={})),function(e){e[e.kLnWt000=0]="kLnWt000",e[e.kLnWt005=5]="kLnWt005",e[e.kLnWt009=9]="kLnWt009",e[e.kLnWt013=13]="kLnWt013",e[e.kLnWt015=15]="kLnWt015",e[e.kLnWt018=18]="kLnWt018",e[e.kLnWt020=20]="kLnWt020",e[e.kLnWt025=25]="kLnWt025",e[e.kLnWt030=30]="kLnWt030",e[e.kLnWt035=35]="kLnWt035",e[e.kLnWt040=40]="kLnWt040",e[e.kLnWt050=50]="kLnWt050",e[e.kLnWt053=53]="kLnWt053",e[e.kLnWt060=60]="kLnWt060",e[e.kLnWt070=70]="kLnWt070",e[e.kLnWt080=80]="kLnWt080",e[e.kLnWt090=90]="kLnWt090",e[e.kLnWt100=100]="kLnWt100",e[e.kLnWt106=106]="kLnWt106",e[e.kLnWt120=120]="kLnWt120",e[e.kLnWt140=140]="kLnWt140",e[e.kLnWt158=158]="kLnWt158",e[e.kLnWt200=200]="kLnWt200",e[e.kLnWt211=211]="kLnWt211",e[e.kLnWtByLayer=-1]="kLnWtByLayer",e[e.kLnWtByBlock=-2]="kLnWtByBlock",e[e.kLnWtByLwDefault=-3]="kLnWtByLwDefault"}(t.LineWeight||(t.LineWeight={})),function(e){e[e.kDefault=0]="kDefault",e[e.kExternal=1]="kExternal",e[e.kPolyline=2]="kPolyline",e[e.kDerived=4]="kDerived",e[e.kTextbox=8]="kTextbox",e[e.kOutermost=16]="kOutermost",e[e.kNotClosed=32]="kNotClosed",e[e.kSelfIntersecting=64]="kSelfIntersecting",e[e.kTextIsland=128]="kTextIsland"}(t.HatchLoopType||(t.HatchLoopType={})),function(e){e[e.kLine=1]="kLine",e[e.kCirArc=2]="kCirArc",e[e.kEllArc=3]="kEllArc",e[e.kSpline=4]="kSpline"}(t.HatchEdgeType||(t.HatchEdgeType={})),function(e){e[e.kUserDefined=0]="kUserDefined",e[e.kPreDefined=1]="kPreDefined",e[e.kCustomDefined=2]="kCustomDefined"}(t.HatchPatternType||(t.HatchPatternType={})),function(e){e[e.kNormal=0]="kNormal",e[e.kOuter=1]="kOuter",e[e.kIgnore=2]="kIgnore"}(t.HatchStyle||(t.HatchStyle={})),function(e){e[e.kInvalid=0]="kInvalid",e[e.kRect=1]="kRect",e[e.kPoly=2]="kPoly"}(t.ClipBoundaryType||(t.ClipBoundaryType={}))})(McDb||(McDb={}));var McCmColor=function(){function t(e,l,n){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),this.imp=new MxCpp.mxcadassemblyimp.MdCmColor,e instanceof Object?(this.imp.red=e.red,this.imp.green=e.green,this.imp.blue=e.blue,this.imp.method=e.method,this.imp.n=e.n,this.imp.colorIndex=e.colorIndex):typeof e=="number"&&typeof l=="number"&&typeof n=="number"&&this.imp.setRGB(e,l,n)}return _createClass$1(t,[{key:"getImp",value:function(){return this.imp}},{key:"copy",value:function(l){return this.imp.red=l.imp.red,this.imp.green=l.imp.green,this.imp.blue=l.imp.blue,this.imp.method=l.imp.method,this.imp.n=l.imp.n,this.imp.colorIndex=l.imp.colorIndex,this}},{key:"clone",value:function(){return new t(this.imp)}},{key:"setColorIndex",value:function(l){this.imp.setColorIndex(l)}},{key:"setRGB",value:function(l,n,u){this.imp.setRGB(l,n,u)}},{key:"red",get:function(){return this.imp.red},set:function(l){this.imp.red=l}},{key:"green",get:function(){return this.imp.green},set:function(l){this.imp.green=l}},{key:"blue",get:function(){return this.imp.blue},set:function(l){this.imp.blue=l}},{key:"n",get:function(){return this.imp.n},set:function(l){this.imp.n=l}},{key:"method",get:function(){return this.imp.method},set:function(l){this.imp.method=l}},{key:"colorIndex",get:function(){return this.imp.colorIndex},set:function(l){this.imp.colorIndex=l}},{key:"getColorString",value:function(){return this.imp.getColorString()}},{key:"getColorValue",value:function(l,n){var u=0;l?.type==McObjectIdType.kMxCAD&&(u=l.id);var c=0;return n?.type==McObjectIdType.kMxCAD&&(c=n.id),this.imp.getColorValue(u,c)}},{key:"getStyle",value:function(){var l=this.red,n=this.green,u=this.blue,c=this.colorIndex,y=getColorUtils(l/255,n/255,u/255),b=c===ColorIndexType.kWhite;if(b){var m={h:0,s:0,l:0};y.getHSL(m),m.h=(m.h+.5)%1,y.setHSL(m.h,m.s,m.l)}return y.getStyle()}}]),t}(),McDbLinetypeTableRecord=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbLinetypeTableRecord),u}return _createClass$1(l,[{key:"name",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.getName())},set:function(u){this.imp.setName(MxG2312Obj.encodeToGb2312(u))}},{key:"numDashes",get:function(){return this.imp.numDashes()},set:function(u){this.imp.setNumDashes(u)}},{key:"dashLengthAt",value:function(u){return this.imp.dashLengthAt(u)}},{key:"setDashLengthAt",value:function(u,c){return this.imp.setDashLengthAt(u,c)}},{key:"comments",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.comments())},set:function(u){this.imp.setComments(MxG2312Obj.encodeToGb2312(u))}},{key:"shapeStyleAt",value:function(u){return this.imp.shapeStyleAt(u)}},{key:"setShapeStyleAt",value:function(u,c){return this.imp.setShapeStyleAt(u,c)}},{key:"shapeNumberAt",value:function(u){return this.imp.shapeNumberAt(u)}},{key:"setShapeNumberAt",value:function(u,c){return this.imp.setShapeNumberAt(u,c)}},{key:"shapeOffsetAt",value:function(u){return new McGeVector3d(this.imp.shapeOffsetAt(u))}},{key:"setShapeOffsetAt",value:function(u,c){return this.imp.setShapeOffsetAt(u,c.imp)}},{key:"shapeScaleAt",value:function(u){return this.imp.shapeScaleAt(u)}},{key:"setShapeScaleAt",value:function(u,c){return this.imp.setShapeScaleAt(u,c)}},{key:"isScaledToFit",get:function(){return this.imp.isScaledToFit()},set:function(u){this.imp.setIsScaledToFit(u)}},{key:"shapeIsUcsOrientedAt",value:function(u){return this.imp.shapeIsUcsOrientedAt(u)}},{key:"setShapeIsUcsOrientedAt",value:function(u,c){return this.imp.setShapeScaleAt(u,c)}},{key:"shapeRotationAt",value:function(u){return this.imp.shapeRotationAt(u)}},{key:"setShapeRotationAt",value:function(u,c){return this.imp.setShapeRotationAt(u,c)}},{key:"textAt",value:function(u){return MxG2312Obj.decodeFromGb2312(this.imp.textAt(u))}},{key:"setTextAt",value:function(u,c){return this.imp.setTextAt(u,MxG2312Obj.encodeToGb2312(c))}}]),l}(McDbObject),McDbDimStyleTableRecord=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbDimStyleTableRecord),u}return _createClass$1(l,[{key:"name",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.getName())},set:function(u){this.imp.setName(MxG2312Obj.encodeToGb2312(u))}},{key:"getDimVarInt",value:function(u){return this.imp.getDimVarInt(u)}},{key:"setDimVarInt",value:function(u,c){return this.imp.setDimVarInt(u,c)}},{key:"getDimVarDouble",value:function(u){return this.imp.getDimVarDouble(u)}},{key:"setDimVarDouble",value:function(u,c){return this.imp.setDimVarDouble(u,c)}},{key:"getDimVarString",value:function(u){return MxG2312Obj.decodeFromGb2312(this.imp.getDimVarString(u))}},{key:"setDimVarString",value:function(u,c){return this.imp.setDimVarString(u,MxG2312Obj.encodeToGb2312(c))}},{key:"getDimVarObjectId",value:function(u){return new McObjectId(this.imp.getDimVarObjectId(u),McObjectIdType.kMxCAD)}},{key:"setDimVarObjectId",value:function(u,c){return this.imp.setDimVarObjectId(u,c.id)}}]),l}(McDbObject),McDbTextStyleTableRecord=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbTextStyleTableRecord),u}return _createClass$1(l,[{key:"name",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.getName())},set:function(u){this.imp.setName(MxG2312Obj.encodeToGb2312(u))}},{key:"isShapeFile",get:function(){return this.imp.isShapeFile()},set:function(u){this.imp.setIsShapeFile(u)}},{key:"isVertical",get:function(){return this.imp.isVertical()},set:function(u){this.imp.setIsVertical(u)}},{key:"textSize",get:function(){return this.imp.textSize()},set:function(u){this.imp.setTextSize(u)}},{key:"xScale",get:function(){return this.imp.xScale()},set:function(u){this.imp.setXScale(u)}},{key:"obliquingAngle",get:function(){return this.imp.obliquingAngle()},set:function(u){this.imp.setObliquingAngle(u)}},{key:"flagBits",get:function(){return this.imp.flagBits()},set:function(u){this.imp.setFlagBits(u)}},{key:"fileName",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.fileName())},set:function(u){this.imp.setFileName(MxG2312Obj.encodeToGb2312(u))}},{key:"bigFontFileName",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.bigFontFileName())},set:function(u){this.imp.setBigFontFileName(MxG2312Obj.encodeToGb2312(u))}},{key:"setFont",value:function(u,c,y,b,m){return this.imp.setFont(MxG2312Obj.encodeToGb2312(u),c,y,b,m)}},{key:"font",value:function(){var u=this.imp.font();if(!u)return{sTypeface:"",bold:!1,italic:!1,charset:0,pitchAndFamily:0};var c=MxG2312Obj.decodeFromGb2312(u.AtString(0)),y=u.Atlong(1)!=0,b=u.Atlong(2)!=0,m=u.Atlong(3),O=u.Atlong(4);return{sTypeface:c,bold:y,italic:b,charset:m,pitchAndFamily:O}}}]),l}(McDbObject),McDbLayerTableRecord=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbLayerTableRecord),u}return _createClass$1(l,[{key:"name",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.getName())},set:function(u){this.imp.setName(MxG2312Obj.encodeToGb2312(u))}},{key:"isFrozen",get:function(){return this.imp.isFrozen()},set:function(u){this.imp.setIsFrozen(u)}},{key:"isOff",get:function(){return this.imp.isOff()},set:function(u){this.imp.setIsOff(u)}},{key:"isLocked",get:function(){return this.imp.isLocked()},set:function(u){this.imp.setIsLocked(u)}},{key:"color",get:function(){return new McCmColor(this.imp.color())},set:function(u){this.imp.setColor(u.getImp())}},{key:"linetypeObjectId",get:function(){return new McObjectId(this.imp.linetypeObjectId(),McObjectIdType.kMxCAD)},set:function(u){this.imp.setLinetypeObjectId(u.id)}},{key:"lineWeight",get:function(){return this.imp.lineWeight()},set:function(u){this.imp.setLineWeight(u)}}]),l}(McDbObject),McDbLayerTable=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"getAllRecordId",value:function(){for(var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,c=[],y=this.imp.getAllRecordId(u),b=y.length(),m=0;m<b;m++)c.push(new McObjectId(y.at(m),McObjectIdType.kMxCAD));return MxCpp.App.getImp().DestroyMdGeLongArray(y),c}},{key:"add",value:function(u){return new McObjectId(this.imp.add(u.getImp()),McObjectIdType.kMxCAD)}},{key:"get",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,y=MxG2312Obj.encodeToGb2312(u);return new McObjectId(this.imp.get(y,c))}},{key:"has",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,y=MxG2312Obj.encodeToGb2312(u);return this.imp.get(y,c)!=0}}]),l}(McDbObject),McDbLinetypeTable=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"getAllRecordId",value:function(){for(var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,c=[],y=this.imp.getAllRecordId(u),b=y.length(),m=0;m<b;m++)c.push(new McObjectId(y.at(m),McObjectIdType.kMxCAD));return MxCpp.App.getImp().DestroyMdGeLongArray(y),c}},{key:"add",value:function(u){return new McObjectId(this.imp.add(u.getImp()),McObjectIdType.kMxCAD)}},{key:"get",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,y=MxG2312Obj.encodeToGb2312(u);return new McObjectId(this.imp.get(y,c))}},{key:"has",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,y=MxG2312Obj.encodeToGb2312(u);return this.imp.get(y,c)!=0}}]),l}(McDbObject),McDbDimStyleTable=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"getAllRecordId",value:function(){for(var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,c=[],y=this.imp.getAllRecordId(u),b=y.length(),m=0;m<b;m++)c.push(new McObjectId(y.at(m),McObjectIdType.kMxCAD));return MxCpp.App.getImp().DestroyMdGeLongArray(y),c}},{key:"add",value:function(u){return new McObjectId(this.imp.add(u.getImp()),McObjectIdType.kMxCAD)}},{key:"get",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,y=MxG2312Obj.encodeToGb2312(u);return new McObjectId(this.imp.get(y,c))}},{key:"has",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,y=MxG2312Obj.encodeToGb2312(u);return this.imp.get(y,c)!=0}}]),l}(McDbObject),McDbTextStyleTable=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"getAllRecordId",value:function(){for(var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,c=[],y=this.imp.getAllRecordId(u),b=y.length(),m=0;m<b;m++)c.push(new McObjectId(y.at(m),McObjectIdType.kMxCAD));return MxCpp.App.getImp().DestroyMdGeLongArray(y),c}},{key:"add",value:function(u){return new McObjectId(this.imp.add(u.getImp()),McObjectIdType.kMxCAD)}},{key:"get",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,y=MxG2312Obj.encodeToGb2312(u);return new McObjectId(this.imp.get(y,c))}},{key:"has",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,y=MxG2312Obj.encodeToGb2312(u);return this.imp.get(y,c)!=0}}]),l}(McDbObject),McDbDatabase=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"getLayerTable",value:function(){return new McDbLayerTable(this.imp.GetLayerTable())}},{key:"layerTable",get:function(){return new McDbLayerTable(this.imp.GetLayerTable())}},{key:"getLinetypeTable",value:function(){return new McDbLinetypeTable(this.imp.GetLinetypeTable())}},{key:"getDimStyleTable",value:function(){return new McDbDimStyleTable(this.imp.GetDimStyleTable())}},{key:"dimStyleTable",get:function(){return new McDbDimStyleTable(this.imp.GetDimStyleTable())}},{key:"linetypeTable",get:function(){return new McDbLinetypeTable(this.imp.GetLinetypeTable())}},{key:"getTextStyleTable",value:function(){return new McDbTextStyleTable(this.imp.GetTextStyleTable())}},{key:"textStyleTable",get:function(){return new McDbTextStyleTable(this.imp.GetTextStyleTable())}},{key:"getBlockTable",value:function(){return new McDbBlockTable(this.imp.GetBlockTable())}},{key:"getNamedObjectsDictionary",value:function(){return new McDbDictionary(this.imp.GetNamedObjectsDictionary())}},{key:"getEntitiesInTheGroup",value:function(u){for(var c=[],y=this.imp.getEntitiesInTheGroup(u.id),b=y.length(),m=0;m<b;m++)c.push(new McObjectId(y.at(m),McObjectIdType.kMxCAD));return MxCpp.App.getImp().DestroyMdGeLongArray(y),c}},{key:"GetGroupDictionary",value:function(){return new McDbDictionary(this.imp.GetGroupDictionary())}},{key:"CreateGroup",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",y=this.GetGroupDictionary(),b=new McDbGroup;return b.appendArray(u),b.name=c,y.addObject(c,b),!0}},{key:"blockTable",get:function(){return new McDbBlockTable(this.imp.GetBlockTable())}},{key:"currentSpace",get:function(){return new McDbBlockTableRecord(this.imp.CurrentSpace())}},{key:"getCurrentlyLineTypeScale",value:function(){return this.imp.GetCurrentlyLineTypeScale()}},{key:"setCurrentlyLineTypeScale",value:function(u){return this.imp.SetCurrentlyLineTypeScale(u)}},{key:"getCurrentlyLineTypeName",value:function(){var u=this.imp.GetCurrentlyLineTypeName();return MxG2312Obj.decodeFromGb2312(u)}},{key:"setCurrentlyLineTypeName",value:function(u){var c=MxG2312Obj.encodeToGb2312(u);this.imp.SetCurrentlyLineTypeName(c)}},{key:"getCurrentlyLayerName",value:function(){var u=this.imp.GetCurrentlyLayerName();return MxG2312Obj.decodeFromGb2312(u)}},{key:"setCurrentlyLayerName",value:function(u){var c=MxG2312Obj.encodeToGb2312(u);this.imp.SetCurrentlyLayerName(c)}},{key:"getCurrentlyTrueColor",value:function(){return new McCmColor(this.imp.GetCurrentlyTrueColor())}},{key:"getCurrentlyDrawColor",value:function(){var u=this.imp.GetCurrentlyDrawColor(),c=new THREE.Color;return c.setRGB(u.at(0)/255,u.at(1)/255,u.at(2)/255),c}},{key:"setCurrentlyTrueColor",value:function(u){return this.imp.SetCurrentlyTrueColor(u.getImp())}},{key:"getCurrentlyColorIndex",value:function(){return this.imp.GetCurrentlyColorIndex()}},{key:"setCurrentlyColorIndex",value:function(u){return this.imp.SetCurrentlyColorIndex(u)}},{key:"getCurrentlyTextStyleName",value:function(){var u=this.imp.GetCurrentlyTextStyleName();return MxG2312Obj.decodeFromGb2312(u)}},{key:"setCurrentlyTextStyle",value:function(u){var c=MxG2312Obj.encodeToGb2312(u);this.imp.SetCurrentlyTextStyle(c)}},{key:"getCurrentlyTextStyleId",value:function(){return new McObjectId(this.imp.GetCurrentlyTextStyleId(),McObjectIdType.kMxCAD)}},{key:"SetCurrentlyTextStyleId",value:function(u){return this.imp.SetCurrentlyTextStyleId(u.id)}},{key:"getCurrentlyDimStyleId",value:function(){return new McObjectId(this.imp.GetCurrentlyDimStyleId(),McObjectIdType.kMxCAD)}},{key:"setCurrentlyDimStyleId",value:function(u){return this.imp.SetCurrentlyDimStyleId(u.id)}},{key:"getCurrentlyLayerId",value:function(){return new McObjectId(this.imp.GetCurrentlyLayerId(),McObjectIdType.kMxCAD)}},{key:"setCurrentlyLayerId",value:function(u){return this.imp.SetCurrentlyLayerId(u.id)}},{key:"getCurrentlyLinetypeId",value:function(){return new McObjectId(this.imp.GetCurrentlyLinetypeId(),McObjectIdType.kMxCAD)}},{key:"setCurrentlyLinetypeId",value:function(u){return this.imp.SetCurrentlyLinetypeId(u.id)}},{key:"handleToIdIndex",value:function(u){var c=this.imp.HandleToIdIndex(u);return new McObjectId(c,McObjectIdType.kMxCAD)}},{key:"isModifyed",value:function(){return this.imp.IsModifyed()}},{key:"resetModificationStatus",value:function(){return this.imp.SetModifyed(!1)}}]),l}(McRxObject),McDbBlockTableRecord=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbBlockTableRecord),u}return _createClass$1(l,[{key:"appendAcDbEntity",value:function(u){var c=u.syncData(!0),y=new McObjectId(this.imp.appendAcDbEntity(u.getImp()),McObjectIdType.kMxCAD);return c&&MxCustomEntityManager.getObjectFormId(y),y}},{key:"getAllEntityId",value:function(){for(var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,c=[],y=this.imp.getAllEntityId(u),b=y.length(),m=0;m<b;m++)c.push(new McObjectId(y.at(m),McObjectIdType.kMxCAD));return MxCpp.App.getImp().DestroyMdGeLongArray(y),c}},{key:"getMinMaxDrawOrder",value:function(){var u=this.imp.getMinMaxDrawOrder();return{minDrawOrder:u.x,maxDrawOrder:u.y}}},{key:"origin",get:function(){return new McGePoint3d(this.imp.origin())},set:function(u){this.imp.setOrigin(u.imp)}},{key:"getBoundingBox",value:function(){var u=this.imp.getBoundingBox();if(u.length()<2)return{minPt:new McGePoint3d,maxPt:new McGePoint3d,ret:!1};var c={minPt:new McGePoint3d(u.at(0)),maxPt:new McGePoint3d(u.at(1)),ret:!0};return c}},{key:"invalidBoundingBoxBuffer",value:function(){this.imp.invalidBoundingBoxBuffer()}},{key:"name",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.getName())},set:function(u){this.imp.setName(MxG2312Obj.encodeToGb2312(u))}}]),l}(McDbObject),McDbBlockTable=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbBlockTable),u}return _createClass$1(l,[{key:"getAllRecordId",value:function(){for(var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,c=[],y=this.imp.getAllRecordId(u),b=y.length(),m=0;m<b;m++)c.push(new McObjectId(y.at(m),McObjectIdType.kMxCAD));return MxCpp.App.getImp().DestroyMdGeLongArray(y),c}},{key:"add",value:function(u){if(typeof u=="string"){if(u.length>0){var c=this.get(u,!1);if(c.isValid()){var y=c.getMcDbBlockTableRecord();return y&&y.isErased()&&y.unErase(),c}}var b=new McDbBlockTableRecord;return b.name=u,new McObjectId(this.imp.add(b.getImp()),McObjectIdType.kMxCAD)}else return new McObjectId(this.imp.add(u.getImp()),McObjectIdType.kMxCAD)}},{key:"get",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,y=MxG2312Obj.encodeToGb2312(u);return new McObjectId(this.imp.get(y,c))}},{key:"has",value:function(u){var c=MxG2312Obj.encodeToGb2312(u);return this.imp.get(c,!0)!=0}}]),l}(McDbObject),McDbRasterImageDef=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbRasterImageDef),u}return _createClass$1(l,[{key:"sourceFileName",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.sourceFileName())},set:function(u){this.imp.setSourceFileName(MxG2312Obj.encodeToGb2312(u))}},{key:"saveToBase64",value:function(u){return this.imp.saveToBase64(u)}}]),l}(McDbObject),McDbDictionary=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbDictionary),u}return _createClass$1(l,[{key:"getAllObject",value:function(){for(var u=[],c=this.imp.getAllObject(),y=c.length(),b=0;b<y;b++)u.push(new McObjectId(c.at(b),McObjectIdType.kMxCAD));return MxCpp.App.getImp().DestroyMdGeLongArray(c),u}},{key:"getAllObjectName",value:function(){var u=this.imp.getAllObjectName(),c=new McGeStringArray(u);return MxCpp.App.getImp().DestroyMdGeStringArray(u),c}},{key:"remove",value:function(u){var c=MxG2312Obj.encodeToGb2312(u);return this.imp.remove(c)}},{key:"addObject",value:function(u,c){var y=MxG2312Obj.encodeToGb2312(u);return new McObjectId(this.imp.addObject(y,c.getImp()),McObjectIdType.kMxCAD)}},{key:"getAt",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,y=MxG2312Obj.encodeToGb2312(u);return new McObjectId(this.imp.getAt(y,c),McObjectIdType.kMxCAD)}}]),l}(McDbObject),McDbXrecord=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbXrecord),u}return _createClass$1(l,[{key:"setData",value:function(u){return this.imp.setData(u.getImp())}},{key:"getData",value:function(){return new MxCADResbuf(this.imp.getData())}}]),l}(McDbObject),McDbGroup=function(t){_inherits$1(l,t);var e=_createSuper$1(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this,n),n||u.initTempObject(new MxCpp.mxcadassemblyimp.MdDbGroup),u}return _createClass$1(l,[{key:"description",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.description())},set:function(u){this.imp.setDescription(MxG2312Obj.encodeToGb2312(u))}},{key:"name",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.name())},set:function(u){this.imp.setName(MxG2312Obj.encodeToGb2312(u))}},{key:"isSelectable",get:function(){return this.imp.isSelectable()},set:function(u){this.imp.setSelectable(u)}},{key:"clear",value:function(){return this.imp.clear()}},{key:"append",value:function(u){return this.imp.append(u.id)}},{key:"appendArray",value:function(u){var c=new McGeLongArray;return c.copyFormAryId(u),this.imp.appendArray(c.imp)}},{key:"has",value:function(u){return this.imp.has(u.id)}},{key:"getAllEntityId",value:function(){for(var u=[],c=this.imp.getAllEntityId(),y=c.length(),b=0;b<y;b++)u.push(new McObjectId(c.at(b),McObjectIdType.kMxCAD));return MxCpp.App.getImp().DestroyMdGeLongArray(c),u}},{key:"numEntities",value:function(){return this.imp.numEntities()}}]),l}(McDbObject);function angleTo(t,e,l,n){var u=t-l,c=e-n,y=0;return u==0?y=Math.PI/2:y=Math.atan(Math.abs(c/u)),u<0&&c>=0?y=Math.PI-y:u<0&&c<0?y=Math.PI+y:u>=0&&c<0&&(y=Math.PI*2-y),y}function findArcCenter(t,e,l){var n={x:(t.x+e.x)/2,y:(t.y+e.y)/2},u=Math.sqrt(Math.pow(t.x-n.x,2)+Math.pow(t.y-n.y,2))/Math.sin(l/2),c={x:e.x-t.x,y:e.y-t.y},y={x:c.x/Math.sqrt(Math.pow(c.x,2)+Math.pow(c.y,2)),y:c.y/Math.sqrt(Math.pow(c.x,2)+Math.pow(c.y,2))},b={x:-y.y,y:y.x},m=n.x+u*b.x,O=n.y+u*b.y;return new McGePoint3d(m,O)}function getHostUrl$2(){var t=window.location.hostname;return t.substring(0,4)!="http"&&(t=document.location.protocol+"//"+t),t}function calculateDistanceFromPointToLine(t,e,l){var n=e.clone(),u=l.clone(),c=t.clone(),y=c.sub(n),b=u.sub(n),m=c.sub(u),O,N=y.crossProduct(b).length()/b.length(),L=y.dotProduct(b);return L<0?O=y.length():L>Math.pow(b.length(),2)?O=m.length():O=N,Math.floor(O)}function selectLineSegmentFromPolylineByPoint(t,e){for(var l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,n=0;n<t.numVerts();n++){var u=t.getPointAt(n).val,c=t.getPointAt(n+1).val,y=t.getClosestPointTo(e,!0).val;if(c&&calculateDistanceFromPointToLine(y,u,c)<l)return{start:u,end:c,startIndex:n,endIndex:n+1}}if(t.isClosed){var b=t.getPointAt(0).val,m=t.getPointAt(t.numVerts()-1).val,O=t.getClosestPointTo(e,!0).val;if(calculateDistanceFromPointToLine(O,m,b)<l)return{start:m,end:b,startIndex:t.numVerts()-1,endIndex:0,isClosed:!0}}}function darkenColor(t,e){var l=t.r,n=t.g,u=t.b;l*=e,n*=e,u*=e,t.r=Math.max(Math.min(l,1),0),t.g=Math.max(Math.min(n,1),0),t.b=Math.max(Math.min(u,1),0)}function isSegmentStartCloserToPoint(t,e,l,n){var u=calculateDistanceFromPointToLine(n,t,l),c=calculateDistanceFromPointToLine(n,e,l);return isNaN(c)?!0:isNaN(u)?!1:c===u?l.distanceTo(t)>l.distanceTo(e):u<c}function createChamferedLinesFromSegments(t,e,l,n,u,c,y){var b=arguments.length>7&&arguments[7]!==void 0?arguments[7]:!0,m=new McDbLine,O=t.endPoint.sub(t.startPoint).normalize().mult(c),N=e.endPoint.sub(e.startPoint).normalize().mult(y);if(n){O.negate();var L=l.clone().addvec(O);b&&(t.endPoint=L),m.startPoint=L.clone()}else{var G=l.clone().addvec(O);b&&(t.startPoint=G),m.startPoint=G.clone()}if(u){N.negate();var q=l.clone().addvec(N);b&&(e.endPoint=q),m.endPoint=q.clone()}else{var J=l.clone().addvec(N);b&&(e.startPoint=J),m.endPoint=J.clone()}if(!(c<=0&&y<=0))return m}function createLineSegmentRoundJoin(t,e,l,n,u,c){var y=arguments.length>6&&arguments[6]!==void 0?arguments[6]:!0,b=arguments.length>7&&arguments[7]!==void 0?arguments[7]:!1,m=e.startPoint,O=e.endPoint,N=l.startPoint,L=l.endPoint,G=n.sub(u?m:O),q=n.sub(c?N:L),J=Math.tan(G.angleTo1(q)/2),fe=t/J,ve=createChamferedLinesFromSegments(e,l,n,u,c,b?0:fe,b?0:fe,y);if(!ve)return{segmentLine:ve,chamferDist:fe};var ne=ve.startPoint.sub(n).perpVector(),Ue=ve.endPoint.sub(n).perpVector();ve.endPoint.addvec(Ue);var De=new McDbLine(ve.startPoint,ve.startPoint.clone().addvec(ne)).IntersectWith(new McDbLine(ve.endPoint,ve.endPoint.clone().addvec(Ue)),McDb.Intersect.kExtendBoth);if(!De.isEmpty()){var Ve=De.at(0),rt=Ve.clone().addvec(n.sub(Ve).normalize().mult(t)),Ae=new McDbArc,Te=MxCADUtility.calcBulge(ve.startPoint,rt,ve.endPoint).val;return Ae.computeArc(ve.startPoint.x,ve.startPoint.y,rt.x,rt.y,ve.endPoint.x,ve.endPoint.y),{arc:Ae,bulge:Te,segmentLine:ve,chamferDist:fe,center:Ve,midPoint:rt}}}function calculateSlope(t,e){return(e.y-t.y)/(e.x-t.x)}function areLinesCollinear(t,e){var l=calculateSlope(t.startPoint,t.endPoint),n=calculateSlope(e.startPoint,e.endPoint);return isNaN(l)&&isNaN(n)?t.startPoint.x===e.startPoint.x:l===n}var MxAI=function(){function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"serverUrl",""),_defineProperty$1(this,"mapFun",{})}return _createClass$1(t,[{key:"init",value:function(l){l.substring(0,16)=="http://localhost"&&(l=getHostUrl$2()+l.substring(16)),this.serverUrl=l}},{key:"addFunction",value:function(l,n){this.mapFun[l]=n}},{key:"registTool",value:function(l){if(this.serverUrl.length!=0){var n=new XMLHttpRequest,u=this.serverUrl+"/add_toolfun";n.open("POST",u),n.setRequestHeader("Content-Type","application/json"),n.send(JSON.stringify(l)),n.onreadystatechange=function(){n.readyState===4&&n.status===200&&console.log(n.responseText)}}}},{key:"reloadTools",value:function(l){if(this.serverUrl.length!=0){var n=new XMLHttpRequest,u=this.serverUrl+"/reload_toolfun";n.open("POST",u),n.setRequestHeader("Content-Type","application/json"),n.send(JSON.stringify(l)),n.onreadystatechange=function(){n.readyState===4&&n.status===200&&console.log(n.responseText)}}}},{key:"chat_tool",value:function(l){if(this.serverUrl.length!=0){var n=this,u={text:l},c=new XMLHttpRequest,y=this.serverUrl+"/post";c.open("POST",y),c.setRequestHeader("Content-Type","application/json"),c.send(JSON.stringify(u)),c.onreadystatechange=function(){if(c.readyState===4&&c.status===200)try{var b=JSON.parse(c.responseText),m=b.results;m&&m.name&&n.mapFun[m.name]&&n.mapFun[m.name](m.parameters)}catch(O){console.log(O)}}}}}]),t}(),McAppFunctonImp=function(){function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"mapCppCall",{}),_defineProperty$1(this,"currentOptNum",1)}return _createClass$1(t,[{key:"init",value:function(){var l=window,n=this;l.loadFonts_complete=function(u){n.mapCppCall[u]&&(n.mapCppCall[u](),delete n.mapCppCall[u])}}},{key:"loadFonts",value:function(l,n,u,c){var y=new McGeStringArray;l.forEach(function(b){y.append(b)}),n.forEach(function(b){y.append("{big}"+b)}),u.forEach(function(b){y.append("{font}"+b)}),this.currentOptNum++,this.mapCppCall[this.currentOptNum]=c,MxCpp.App.getImp().loadFonts(y.imp,this.currentOptNum)}}]),t}(),McAppFuncton=new McAppFunctonImp,FetchAttributes=function(t){return t[t.EMSCRIPTEN_FETCH_LOAD_TO_MEMORY=1]="EMSCRIPTEN_FETCH_LOAD_TO_MEMORY",t[t.EMSCRIPTEN_FETCH_PERSIST_FILE=4]="EMSCRIPTEN_FETCH_PERSIST_FILE",t[t.EMSCRIPTEN_FETCH_APPEND=8]="EMSCRIPTEN_FETCH_APPEND",t[t.EMSCRIPTEN_FETCH_REPLACE=16]="EMSCRIPTEN_FETCH_REPLACE",t}(FetchAttributes||{}),McObject=function(){function t(e){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),_defineProperty$1(this,"event",{}),_defineProperty$1(this,"currentFileName",""),_defineProperty$1(this,"firstTimeOpenFile",!0),_defineProperty$1(this,"authorized_service",""),this.imp=e}return _createClass$1(t,[{key:"creaeCallId",value:function(){return Math.round(Math.random()*1e7)}},{key:"setAttribute",value:function(l){return this.imp.setAttribute(JSON.stringify(l))}},{key:"getMxDrawObject",value:function(){return this.imp.mxdrawObject}},{key:"mxdraw",get:function(){return this.imp.mxdrawObject}},{key:"getImp",value:function(){return this.imp}},{key:"init",value:function(l){this.imp=l}},{key:"create",value:function(l){createMxCad(l,this)}},{key:"on",value:function(l,n){if(this.event[l])if(this.event[l]instanceof Array)this.event[l].includes(n)||this.event[l].push(n);else{var u=this.event[l];if(u==n)return;this.event[l]=[],this.event[l].push(u),this.event[l].push(n)}else this.event[l]=n}},{key:"off",value:function(l,n){if(this.event[l])if(!n)this.event[l]=[];else if(this.event[l]instanceof Array){var u=this.event[l].indexOf(n);if(u<0)return;this.event[l].splice(u,1)}else this.event[l]===n&&(this.event[l]=[])}},{key:"callEvent",value:function(l,n){try{var u=this.event[l];if(!u)return!1;if(u instanceof Array){var c=!1;return u.forEach(function(y){c=y(n)}),c}else return u(n)}catch(y){throw console.log(y),y}}},{key:"initMxObject",value:function(l){var n=this;l.tmp||(l.tmp=new MxDrawObject(l)),this.imp.mxdrawObject=l.tmp,l.addEvent("selectChange",function(O){var N=[];O.forEach(function(G){N.push(new McObjectId(G,McObjectIdType.kMxCAD))});var L=l.getMxAllSelect();L.forEach(function(G){N.push(new McObjectId(G,McObjectIdType.kMxDraw))}),n.callEvent("selectChange",N)}),l.addEvent("mxdrawSelectChange",function(O){var N=[];O.forEach(function(G){N.push(new McObjectId(G,McObjectIdType.kMxDraw))});var L=l.getMxCADAllSelect();L.forEach(function(G){N.push(new McObjectId(G,McObjectIdType.kMxCAD))}),n.callEvent("selectChange",N)});var u=this;l.addEvent("openFileComplete",function(){n.callEvent("openFileComplete",u)});var c={selectChange:!0,openFileComplete:!0,init:!0,init_mxdraw:!0,init_mxcad:!0,init_before_mxdraw:!0},y={};for(var b in this.event){var m=this.event[b];if(c[b]){y[b]=m;continue}m instanceof Array?m.forEach(function(O){l.addEvent(b,O)}):l.addEvent(b,m)}this.event=y}},{key:"regen",value:function(){var l=this,n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0;n<=0?this.imp.regen():setTimeout(function(){l.imp.regen(),l.updateDisplay(!1)},n)}},{key:"zoomAll",value:function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,n=this.database.currentSpace.getBoundingBox();if(!n.ret)return!1;var u=this.getMxDrawObject();return u.zoomW(n.minPt.toVector3(),n.maxPt.toVector3(),void 0,void 0,l),!0}},{key:"zoomScale",value:function(l){this.getMxDrawObject().zoomScale(l)}},{key:"addCurrentSelect",value:function(l){var n=this,u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;if(l instanceof Array){var c=!1,y=!1;l.forEach(function(b){b.type==McObjectIdType.kMxDraw?n.getMxDrawObject().addMxCurrentSelect(b.id,!1,u)&&(c=!0):b.type==McObjectIdType.kMxCAD&&n.getMxDrawObject().addMxCADCurrentSelect(b.id,!1,u)&&(y=!0)}),c&&this.getMxDrawObject().fireSelectChange(!1),y&&this.getMxDrawObject().fireSelectChange(!0)}else l.type==McObjectIdType.kMxDraw?this.getMxDrawObject().addMxCurrentSelect(l.id,!0,u):l.type==McObjectIdType.kMxCAD&&this.getMxDrawObject().addMxCADCurrentSelect(l.id,!0,u)}},{key:"clearMxCurrentSelect",value:function(){this.getMxDrawObject().clearMxCurrentSelect()}},{key:"zoomW",value:function(l,n){var u=this.getMxDrawObject();u.zoomW(l.toVector3(),n.toVector3())}},{key:"zoomCenter",value:function(l,n){var u=this.getMxDrawObject();u.zoomCenter(l,n)}},{key:"zoomAngle",value:function(l){var n=this.getMxDrawObject();n.setViewAngle(l),this.updateDisplay(!1,100)}},{key:"openWebFile",value:function(l,n){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,c=arguments.length>3?arguments[3]:void 0,y=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0,b=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!0,m=this.imp.mxdrawObject,O=Math.round(Math.random()*1e7);if(n){var N=function ve(ne,Ue){O==Ue&&(m.removeEventFuction("openFileComplete",ve),n(ne))};m.addEvent("openFileComplete",N)}this.currentFileName=l.split("/").pop();var L="";c&&(L=JSON.stringify(c)),this.firstTimeOpenFile||this.getMxDrawObject().clearAllObject(),this.firstTimeOpenFile=!1;var G=MxCpp.App.getImp().getCodeVersion();if(G==3){var q="";this.authorized_service.length!=0?q=this.authorized_service:q=getHostUrl$2()+":3090/create_app_param";var J=this,fe=new XMLHttpRequest;return fe.open("POST",q),fe.setRequestHeader("Content-Type","application/json"),fe.onreadystatechange=function(){fe.status===200?fe.readyState===4&&(!fe.responseText||fe.responseText.length==0?(J.imp.openWebFile("",u,O,L,y,b),console.log("MxTip:authorized service retrun error!")):J.imp.openWebFile(fe.responseText,u,O,L,y,b)):(J.imp.openWebFile("",u,O,L,y,b),console.log("MxTip:authorized service net error!"))},fe.send(JSON.stringify({param:MxCpp.App.getImp().createAppParam(l)})),!0}else return this.imp.openWebFile(l,u,O,L,y,b)}},{key:"newFile",value:function(){return this.currentFileName="",this.getMxDrawObject().clearAllObject(),this.imp.newFile()}},{key:"insertBlock",value:function(l,n){var u=this,c=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,y=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,b=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1,m=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!1,O=this.imp.mxdrawObject,N=Math.round(Math.random()*1e7);return new Promise(function(L){var G=function J(fe){(!fe||fe.length==0)&&L(new McObjectId);var ve=JSON.parse(fe);ve.callid==N&&(O.removeEventFuction("insertBlockComplete",J),ve.result!=0&&console.log("insertBlock result:"+ve.result),L(new McObjectId(ve.blkrecid,McObjectIdType.kMxCAD)))};O.addEvent("insertBlockComplete",G);var q="";u.imp.insertBlock(l,MxG2312Obj.encodeToGb2312(n),c,N,q,y,b,m)})}},{key:"getCurrentFileName",value:function(){return this.currentFileName}},{key:"saveFileToUrl",value:function(l,n,u,c){var y=this.imp.saveFileToMemory();if(y.getSize()==0)return n(-1,"save failed"),!1;var b=y.getData(),m=y.getSize(),O=MxCpp.mxcadassemblyimp.HEAPU8,N=O.subarray(b,b+m),L=new ArrayBuffer(y.getSize()),G=new Uint8Array(L);return G.set(N),y.clear(),MxTools.postMemoryFile(G,l,u||"temp.mxweb",n,c),!0}},{key:"saveFile",value:function(l,n){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,y=arguments.length>4?arguments[4]:void 0;l||(l=this.getCurrentFileName(),l.length==0&&(l="temp_empty.mxweb")),l.indexOf(".")==-1&&(l+=".mxweb");var b=window;b.mx_saveFile_call=function(O){if(n&&n(O),!!O){if(u){var N,L=/^((?!chrome|android).)*safari/i.test(navigator.userAgent);L?N=new Blob([O.buffer],{type:"application/octet-stream"}):N=new Blob([O.buffer],{type:"application/octet-binary"}),c?MxTools.saveAsFileDialog({blob:N,filename:l,types:[{description:"mxweb File",accept:{"application/octet-stream":[".mxweb"]}}]}):MxTools.downloadFile(N,l)}b.mx_saveFile_call=null}};var m="";return y&&(m=JSON.stringify(y)),this.imp.saveFile(l,m)}},{key:"getDatabase",value:function(){return this.imp.McDbDatabase||(this.imp.McDbDatabase=new McDbDatabase(this.imp.GetDatabase())),this.imp.McDbDatabase}},{key:"database",get:function(){return this.getDatabase()}},{key:"setBrowse",value:function(l){this.imp.setBrowse(l),l&&MxFun.setIniset({ForbiddenDynInput:!0,EnableIntelliSelect:!1})}},{key:"getSysVarString",value:function(l){return this.imp.GetSysVarString(l)}},{key:"setSysVarString",value:function(l,n){return this.imp.SetSysVarString(l,n)}},{key:"getSysVarDouble",value:function(l){return this.imp.GetSysVarDouble(l)}},{key:"getSysVarPoint",value:function(l){return new McGePoint3d(this.imp.GetSysVarPoint(l))}},{key:"setSysVarPoint",value:function(l,n){return this.imp.SetSysVarPoint(l,n.imp,!1)}},{key:"setSysVarPoint2d",value:function(l,n){return this.imp.SetSysVarPoint(l,n.imp,!0)}},{key:"setSysVarDouble",value:function(l,n){return this.imp.SetSysVarDouble(l,n)}},{key:"getSysVarLong",value:function(l){return this.imp.GetSysVarLong(l)}},{key:"setSysVarLong",value:function(l,n){return this.imp.SetSysVarLong(l,n)}},{key:"drawColor",get:function(){return new McCmColor(this.imp.GetDrawColor())},set:function(l){this.imp.SetDrawColor(l.getImp())}},{key:"drawColorIndex",get:function(){return this.imp.GetDrawColor().colorIndex},set:function(l){var n=new McCmColor;n.setColorIndex(l),this.imp.SetDrawColor(n.getImp())}},{key:"drawLineWeight",get:function(){return this.imp.GetDrawLineWeight()},set:function(l){this.imp.SetDrawLineWeight(l)}},{key:"drawLineTypeScale",get:function(){return this.imp.GetDrawLineTypeScale()},set:function(l){this.imp.SetDrawLineTypeScale(l)}},{key:"drawLinetype",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.GetDrawLinetype())},set:function(l){this.imp.SetDrawLinetype(MxG2312Obj.encodeToGb2312(l))}},{key:"drawTextStyle",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.GetDrawTextStyle())},set:function(l){this.imp.SetDrawTextStyle(MxG2312Obj.encodeToGb2312(l))}},{key:"drawLayer",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.GetDrawLayer())},set:function(l){this.imp.SetDrawLayer(MxG2312Obj.encodeToGb2312(l))}},{key:"addLayer",value:function(l){return new McObjectId(this.imp.AddLayer(MxG2312Obj.encodeToGb2312(l)))}},{key:"addTextStyle",value:function(l,n,u){var c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1;return new McObjectId(this.imp.AddTextStyle(MxG2312Obj.encodeToGb2312(l),MxG2312Obj.encodeToGb2312(n),MxG2312Obj.encodeToGb2312(u),c))}},{key:"AddTureTypeTextStyle",value:function(l){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;return new McObjectId(this.imp.AddTureTypeTextStyle(MxG2312Obj.encodeToGb2312(l),MxG2312Obj.encodeToGb2312(n),u))}},{key:"addLinetype",value:function(l,n){return new McObjectId(this.imp.AddLinetype(MxG2312Obj.encodeToGb2312(l),MxG2312Obj.encodeToGb2312(n)))}},{key:"addLinetypeEx",value:function(l,n){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"";return new McObjectId(this.imp.AddLinetypeEx(MxG2312Obj.encodeToGb2312(l),MxG2312Obj.encodeToGb2312(n),MxG2312Obj.encodeToGb2312(u)))}},{key:"drawLine",value:function(l,n,u,c){return new McObjectId(this.imp.DrawLine(l,n,0,u,c,0))}},{key:"drawLine3d",value:function(l,n,u,c,y,b){return new McObjectId(this.imp.DrawLine(l,n,u,c,y,b))}},{key:"addDimStyle",value:function(l,n,u,c,y){return new McObjectId(this.imp.AddDimStyle(MxG2312Obj.encodeToGb2312(l),MxG2312Obj.encodeToGb2312(n),MxG2312Obj.encodeToGb2312(u),MxG2312Obj.encodeToGb2312(c),MxG2312Obj.encodeToGb2312(y)))}},{key:"drawDimStyle",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.GetDrawDimStyle())},set:function(l){this.imp.SetDrawDimStyle(MxG2312Obj.encodeToGb2312(l))}},{key:"pathMakeExclude",value:function(l){this.imp.PathMakeExclude(l)}},{key:"addPatternDefinition",value:function(l,n){this.imp.AddPatternDefinition(MxG2312Obj.encodeToGb2312(l),MxG2312Obj.encodeToGb2312(n))}},{key:"drawPatternDefinition",get:function(){return MxG2312Obj.decodeFromGb2312(this.imp.GetPatternDefinition())},set:function(l){this.imp.SetPatternDefinition(MxG2312Obj.encodeToGb2312(l))}},{key:"drawLineWidth",get:function(){return this.imp.GetDrawLineWidth()},set:function(l){this.imp.SetDrawLineWidth(l)}},{key:"drawUseDefaultProperties",get:function(){return this.imp.GetDrawUseDefaultProperties()},set:function(l){this.imp.SetDrawUseDefaultProperties(l)}},{key:"drawArc",value:function(l,n,u,c,y){return new McObjectId(this.imp.DrawArc(l,n,u,c,y))}},{key:"drawArc2",value:function(l,n,u,c,y,b){return new McObjectId(this.imp.DrawArc2(l,n,u,c,y,b))}},{key:"drawArc3",value:function(l,n,u,c,y){return new McObjectId(this.imp.DrawArc3(l,n,u,c,y))}},{key:"drawCircle",value:function(l,n,u){return new McObjectId(this.imp.DrawCircle(l,n,u))}},{key:"loadImage",value:function(l,n){this.imp.mxdrawObject.getMxObjectImplement().loadMxCADImage(l,n)}},{key:"drawImage",value:function(l,n,u,c,y,b){var m=arguments.length>6&&arguments[6]!==void 0?arguments[6]:!1;return new McObjectId(this.imp.DrawImage(l,n,u,c,y,MxG2312Obj.encodeToGb2312(b),m))}},{key:"addImageDefine",value:function(l){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;return new McObjectId(this.imp.addImageDefine(MxG2312Obj.encodeToGb2312(l),MxG2312Obj.encodeToGb2312(n),u))}},{key:"showLineWeight",value:function(l){var n=this.imp.showLineWeight(l);return this.updateDisplay(!1),n}},{key:"loadDwgBackground",value:function(l,n){var u=this,c=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,y=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,b=this.creaeCallId(),m=this.imp.mxdrawObject,O=function N(L){L=JSON.parse(L),L.callid==b&&(m.removeEventFuction("load_dwg_gackground_result",N),n(L.l_param==1),L.l_param==1&&y&&u.regen(100))};m.addEvent("load_dwg_gackground_result",O),this.imp.loadDwgBackground(l,c,b,y)}},{key:"getBackgroundEntity",value:function(){return new McDbBackgroundEntity(this.imp.GetBackgroundEntity())}},{key:"clearDwgBackground",value:function(){this.getBackgroundEntity().clearAll()}},{key:"addSystemVarNameForEvent",value:function(l){var n=this;l.forEach(function(u){n.imp.addSystemVarNameForEvent(u)})}},{key:"drawEllipse",value:function(l,n,u,c,y){return new McObjectId(this.imp.DrawEllipse(l,n,u,c,y))}},{key:"drawEllipseArc",value:function(l,n,u,c,y,b,m){return new McObjectId(this.imp.DrawEllipseArc(l,n,u,c,y,b,m))}},{key:"drawPoint",value:function(l,n){return new McObjectId(this.imp.DrawPoint(l,n))}},{key:"drawSolid",value:function(l,n,u,c,y,b,m,O){return new McObjectId(this.imp.DrawSolid(l,n,u,c,y,b,m,O))}},{key:"drawMText",value:function(l,n,u,c,y,b,m){return new McObjectId(this.imp.DrawMText(l,n,MxG2312Obj.encodeToGb2312(u),c,y,b,m))}},{key:"drawText",value:function(l,n,u,c,y,b,m){return new McObjectId(this.imp.DrawText(l,n,MxG2312Obj.encodeToGb2312(u),c,y,b,m))}},{key:"drawBlockReference",value:function(l,n,u,c,y){return new McObjectId(this.imp.DrawBlockReference(l,n,MxG2312Obj.encodeToGb2312(u),c,y))}},{key:"drawDimAligned",value:function(l,n,u,c,y,b){return new McObjectId(this.imp.DrawDimAligned(l,n,u,c,y,b))}},{key:"drawDimAngular",value:function(l,n,u,c,y,b,m,O){return new McObjectId(this.imp.DrawDimAngular(l,n,u,c,y,b,m,O))}},{key:"drawDimDiametric",value:function(l,n,u,c,y){return new McObjectId(this.imp.DrawDimDiametric(l,n,u,c,y))}},{key:"drawDimRotated",value:function(l,n,u,c,y,b,m){return new McObjectId(this.imp.DrawDimRotated(l,n,u,c,y,b,m))}},{key:"drawDimOrdinate",value:function(l,n,u,c,y){return new McObjectId(this.imp.DrawDimOrdinate(l,n,u,c,y))}},{key:"drawDimRadial",value:function(l,n,u,c,y){return new McObjectId(this.imp.DrawDimRadial(l,n,u,c,y))}},{key:"pathMoveTo",value:function(l,n){this.imp.PathMoveTo(l,n)}},{key:"pathMoveToEx",value:function(l,n,u,c,y){this.imp.PathMoveToEx(l,n,u,c,y)}},{key:"pathLineTo",value:function(l,n){this.imp.PathLineTo(l,n)}},{key:"pathLineToEx",value:function(l,n,u,c,y){this.imp.PathLineToEx(l,n,u,c,y)}},{key:"pathCircle",value:function(l,n,u){var c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,y=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;return this.imp.PathCircle(l,n,u,c,y)}},{key:"drawPathToPolyline",value:function(){return new McObjectId(this.imp.DrawPathToPolyline())}},{key:"drawPathToSpline",value:function(){return new McObjectId(this.imp.DrawPathToSpline())}},{key:"pathMakeClosed",value:function(){this.imp.PathMakeClosed()}},{key:"drawPathToHatch",value:function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:1;return new McObjectId(this.imp.DrawPathToHatch(l))}},{key:"drawEntity",value:function(l){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,u=l.syncData(!0),c=new McObjectId(this.imp.DrawEntity(l.getImp(),n));return u&&MxCustomEntityManager.getObjectFormId(c),c}},{key:"drawHatch",value:function(l){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;return new McObjectId(this.imp.DrawHatch(l.getImp(),n))}},{key:"objectIdToObject",value:function(l){return MxCpp.App.objectIdToObject(l)}},{key:"destroyObject",value:function(l){l&&MxCpp.App.getImp().DestroyObject(l)}},{key:"getAllLayoutName",value:function(){return new McGeStringArray(this.imp.GetAllLayoutName())}},{key:"setCurrentLayout",value:function(l){this.imp.SetCurrentLayout(MxG2312Obj.encodeToGb2312(l))}},{key:"getMxCpp",value:function(){return MxCpp}},{key:"getViewCADCoord",value:function(){var l=this.getMxDrawObject().getViewDocCoord();return{pt1:new McGePoint3d(l.pt1),pt2:new McGePoint3d(l.pt2),pt3:new McGePoint3d(l.pt3),pt4:new McGePoint3d(l.pt4)}}},{key:"updateDisplay",value:function(){var l=this,n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;u<=0?this.imp.mxdrawObject.updateDisplay(n):setTimeout(function(){l.imp.mxdrawObject.updateDisplay(n)},u)}},{key:"updateLayerDisplayStatus",value:function(){this.imp.UpdateLayerDisplayStatus()}},{key:"initRegist",value:function(l){this.imp.initRegist(l)}},{key:"iniAuthorizedService",value:function(l){this.imp.initAuthorizedService(l),this.authorized_service=l}},{key:"isTryVersion",value:function(){return this.imp.isTryVersion()}},{key:"setViewBackgroundColor",value:function(l,n,u){var c=this.getMxDrawObject();return c&&c.setViewColor(l<<16|n<<8|u),this.imp.setViewBackgroundColor(l,n,u)}},{key:"getCurrentDatabaseDrawColor",value:function(){var l=this.getDatabase().getImp().GetCurrentlyDrawColor(),n=this.getMxDrawObject().getViewColor(),u=l.at(0),c=l.at(1),y=l.at(2);n==16777215?u==255&&c==255&&y==255&&(u=0,c=0,y=0):n==0&&u==0&&c==0&&y==0&&(u=255,c=255,y=255);var b=new THREE.Color;return b.setRGB(u/255,c/255,y/255),b}},{key:"undo",value:function(){this.imp.undo(),this.updateDisplay(!1)}},{key:"redo",value:function(){this.imp.redo(),this.updateDisplay()}},{key:"undoMark",value:function(){this.imp.undoMark()}}]),t}(),McAppType=function(){function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),_defineProperty$1(this,"MxCADAssist",void 0),_defineProperty$1(this,"objectIdToObjectCalls",{}),_defineProperty$1(this,"classNameToCreateCalls",{}),_defineProperty$1(this,"shxFonts",["txt.shx"]),_defineProperty$1(this,"shxBigFonts",["hztxt.shx"]),_defineProperty$1(this,"trueFonts",{syadobe:{name:"syadobe",zhname:"思原黑体",file:"syadobe.otf"}})}return _createClass$1(t,[{key:"init",value:function(l){this.imp=l,McGeVector3d.kZAxis=new McGeVector3d(0,0,1),McGeVector3d.kNegateZAxis=new McGeVector3d(0,0,-1),McGeVector3d.kXAxis=new McGeVector3d(1,0,0),McGeVector3d.kYAxis=new McGeVector3d(0,1,0),McGePoint3d.kOrigin=new McGePoint3d(0,0,0),McGeMatrix3d.kIdentity=new McGeMatrix3d,this.MxCADAssist=new MxCpp.mxcadassemblyimp.MxDrawAssist,this.initCalls(),McAppFuncton.init()}},{key:"getImp",value:function(){return this.imp}},{key:"getLastCallResult",value:function(){return this.imp.getLastCallResult()}},{key:"destroyObject",value:function(l){this.imp.DestroyObject(l)}},{key:"getCurrentMxCAD",value:function(){var l=this.imp.GetCurrentMxDraw();return l.McObject||(l.McObject=new McObject(this.imp.GetCurrentMxDraw())),l.McObject}},{key:"mcedRGB2Index",value:function(l,n,u){var c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0;return this.imp.mcedRGB2Index(l,n,u,c)}},{key:"setDefaultViewBackgroundColor",value:function(l,n,u){return this.imp.setDefaultViewBackgroundColor(l,n,u)}},{key:"objectIdIsKindOf",value:function(l,n){return this.imp.ObjectIdIsKindOf(l,n)}},{key:"initCalls",value:function(){var l=this;this.objectIdToObjectCalls.McDbCurve=function(n){return new McDbCurve(l.imp.ObjectIdToMdDbCurve(n))},this.objectIdToObjectCalls.McDbEntity=function(n){return new McDbEntity(l.imp.ObjectIdToMdDbEntity(n))},this.objectIdToObjectCalls.McDbDimension=function(n){return new McDbDimension(l.imp.ObjectIdToMdDbDimension(n))},this.classNameToCreateCalls.McDbDimension=function(){return new McDbDimension},this.objectIdToObjectCalls.McDbLine=function(n){return new McDbLine(l.imp.ObjectIdToMdDbLine(n))},this.classNameToCreateCalls.McDbLine=function(){return new McDbLine},this.objectIdToObjectCalls.McDbText=function(n){return new McDbText(l.imp.ObjectIdToMdDbText(n))},this.classNameToCreateCalls.McDbText=function(){return new McDbText},this.objectIdToObjectCalls.McDbAttribute=function(n){return new McDbAttribute(l.imp.ObjectIdToMdDbAttribute(n))},this.classNameToCreateCalls.McDbAttribute=function(){return new McDbAttribute},this.objectIdToObjectCalls.McDbAttributeDefinition=function(n){return new McDbAttributeDefinition(l.imp.ObjectIdToMdDbAttributeDefinition(n))},this.classNameToCreateCalls.McDbAttributeDefinition=function(){return new McDbAttributeDefinition},this.objectIdToObjectCalls.McDbPolyline=function(n){return new McDbPolyline(l.imp.ObjectIdToMdDbPolyline(n))},this.classNameToCreateCalls.McDbPolyline=function(){return new McDbPolyline},this.objectIdToObjectCalls.McDbCircle=function(n){return new McDbCircle(l.imp.ObjectIdToMdDbCircle(n))},this.classNameToCreateCalls.McDbCircle=function(){return new McDbCircle},this.objectIdToObjectCalls.McDbArc=function(n){return new McDbArc(l.imp.ObjectIdToMdDbArc(n))},this.classNameToCreateCalls.McDbArc=function(){return new McDbArc},this.objectIdToObjectCalls.McDbBlockReference=function(n){return new McDbBlockReference(l.imp.ObjectIdToMdDbBlockReference(n))},this.classNameToCreateCalls.McDbBlockReference=function(){return new McDbBlockReference},this.objectIdToObjectCalls.McDbSpatialFilter=function(n){return new McDbSpatialFilter(l.imp.ObjectIdToMdDbSpatialFilter(n))},this.classNameToCreateCalls.McDbSpatialFilter=function(){return new McDbSpatialFilter},this.objectIdToObjectCalls.McDbAlignedDimension=function(n){return new McDbAlignedDimension(l.imp.ObjectIdToMdDbAlignedDimension(n))},this.classNameToCreateCalls.McDbAlignedDimension=function(){return new McDbAlignedDimension},this.objectIdToObjectCalls.McDbRotatedDimension=function(n){return new McDbRotatedDimension(l.imp.ObjectIdToMdDbRotatedDimension(n))},this.classNameToCreateCalls.McDbRotatedDimension=function(){return new McDbRotatedDimension},this.objectIdToObjectCalls.McDb2LineAngularDimension=function(n){return new McDb2LineAngularDimension(l.imp.ObjectIdToMdDb2LineAngularDimension(n))},this.classNameToCreateCalls.McDb2LineAngularDimension=function(){return new McDb2LineAngularDimension},this.objectIdToObjectCalls.McDbMText=function(n){return new McDbMText(l.imp.ObjectIdToMdDbMText(n))},this.classNameToCreateCalls.McDbMText=function(){return new McDbMText},this.objectIdToObjectCalls.McDbEllipse=function(n){return new McDbEllipse(l.imp.ObjectIdToMdDbEllipse(n))},this.classNameToCreateCalls.McDbEllipse=function(){return new McDbEllipse},this.objectIdToObjectCalls.McDbPoint=function(n){return new McDbPoint(l.imp.ObjectIdToMdDbPoint(n))},this.classNameToCreateCalls.McDbPoint=function(){return new McDbPoint},this.objectIdToObjectCalls.McDbBlockTableRecord=function(n){return new McDbBlockTableRecord(l.imp.ObjectIdToMdDbBlockTableRecord(n))},this.classNameToCreateCalls.McDbBlockTableRecord=function(){return new McDbBlockTableRecord},this.objectIdToObjectCalls.McDbLayerTableRecord=function(n){return new McDbLayerTableRecord(l.imp.ObjectIdToMdDbLayerTableRecord(n))},this.classNameToCreateCalls.McDbLayerTableRecord=function(){return new McDbLayerTableRecord},this.objectIdToObjectCalls.McDbLinetypeTableRecord=function(n){return new McDbLinetypeTableRecord(l.imp.ObjectIdToMdDbLinetypeTableRecord(n))},this.classNameToCreateCalls.McDbLinetypeTableRecord=function(){return new McDbLinetypeTableRecord},this.objectIdToObjectCalls.McDbDimStyleTableRecord=function(n){return new McDbDimStyleTableRecord(l.imp.ObjectIdToMdDbDimStyleTableRecord(n))},this.classNameToCreateCalls.McDbDimStyleTableRecord=function(){return new McDbDimStyleTableRecord},this.objectIdToObjectCalls.McDbTextStyleTableRecord=function(n){return new McDbTextStyleTableRecord(l.imp.ObjectIdToMdDbTextStyleTableRecord(n))},this.classNameToCreateCalls.McDbTextStyleTableRecord=function(){return new McDbTextStyleTableRecord},this.objectIdToObjectCalls.McDbHatch=function(n){return new McDbHatch(l.imp.ObjectIdToMdDbHatch(n))},this.classNameToCreateCalls.McDbHatch=function(){return new McDbHatch},this.objectIdToObjectCalls.McDbProxyEntity=function(n){return new McDbProxyEntity(l.imp.ObjectIdToMdDbProxyEntity(n))},this.classNameToCreateCalls.McDbProxyEntity=function(){return new McDbProxyEntity},this.objectIdToObjectCalls.McDbRasterImage=function(n){return new McDbRasterImage(l.imp.ObjectIdToMdDbRasterImage(n))},this.classNameToCreateCalls.McDbRasterImage=function(){return new McDbRasterImage},this.objectIdToObjectCalls.McDbRasterImageDef=function(n){return new McDbRasterImageDef(l.imp.ObjectIdToMdDbRasterImageDef(n))},this.classNameToCreateCalls.McDbRasterImageDef=function(){return new McDbRasterImageDef},this.objectIdToObjectCalls.McDbWipeout=function(n){return new McDbWipeout(l.imp.ObjectIdToMdDbWipeout(n))},this.classNameToCreateCalls.McDbWipeout=function(){return new McDbWipeout},this.objectIdToObjectCalls.McDbDictionary=function(n){return new McDbDictionary(l.imp.ObjectIdToMdDbDictionary(n))},this.classNameToCreateCalls.McDbDictionary=function(){return new McDbDictionary},this.objectIdToObjectCalls.McDbXrecord=function(n){return new McDbXrecord(l.imp.ObjectIdToMdDbXrecord(n))},this.classNameToCreateCalls.McDbXrecord=function(){return new McDbXrecord}}},{key:"objectIdToObject",value:function(l){if(!l)return null;var n=this.imp.ObjectIdToObjectName(l);if(this.objectIdToObjectCalls[n])return this.objectIdToObjectCalls[n](l);if(n=="McDbCustomEntity"){var u=this.imp.ObjectIdToMdDbCustomEntity(l);if(!u)return null;var c=u.getCustomEntityid(),y=u.GetDatabaseIndexId();return MxCpp.App.destroyObject(u),c==0||y==0?null:MxCustomEntityManager.getObject(c,y)}if(this.imp.ObjectIdIsKindOf(l,"McDbCurve"))return this.objectIdToObjectCalls.McDbCurve(l);if(this.imp.ObjectIdIsKindOf(l,"McDbDimension"))return this.objectIdToObjectCalls.McDbDimension(l);if(this.imp.ObjectIdIsKindOf(l,"McDbEntity"))return this.objectIdToObjectCalls.McDbEntity(l);var b=this.imp.ObjectIdToMdObject(l);return new McDbObject(b)}},{key:"createCloneObject",value:function(l){if(!l)return null;var n=l.getObjectName();if(n=="McDbCustomEntity"){var u=l.getCustomEntityid(),c=l.GetDatabaseIndexId(),y=null;return u==0||c==0?(y=MxCustomEntityManager.createMxEntity(l.getCustomEntityTypeName()),y&&(y.getImp().ConnectionTempObject(l),y.syncData(!1))):y=MxCustomEntityManager.getObject(u,c),MxCpp.App.destroyObject(l),y}else{var b=null;return this.classNameToCreateCalls[n]?b=this.classNameToCreateCalls[n]():l.isKindOf("McDbCurve")?(b=new McDbCurve,b.initTempObject(new MxCpp.mxcadassemblyimp.MdDbCurve)):l.isKindOf("McDbEntity")&&(b=new McDbEntity,b.initTempObject(new MxCpp.mxcadassemblyimp.MdDbEntity)),b?(b.getImp().ConnectionTempObject(l),MxCpp.App.destroyObject(l),b):new McDbObject(l)}}},{key:"setFontFilePath",value:function(l){this.imp.setFontFilePath(l)}},{key:"setDefaultTrueTypeFontFile",value:function(l){this.imp.setDefaultTrueTypeFontFile(l)}},{key:"addNetworkLoadingFont",value:function(l){var n=this,u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];this.shxFonts=[],typeof l=="string"?(this.imp.addNetworkLoadingFont(l),this.shxFonts.push(l)):(this.shxFonts=l,l.forEach(function(c){n.imp.addNetworkLoadingFont(c)})),u.forEach(function(c){n.imp.addFontsLoadOnInitialization(c,0)})}},{key:"IniSet",value:function(l){return this.imp.IniSet(JSON.stringify(l))}},{key:"addNetworkLoadingBigFont",value:function(l){var n=this,u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];this.shxBigFonts=[],typeof l=="string"?(this.imp.addNetworkLoadingFont(l),this.shxBigFonts.push(l)):(this.shxBigFonts=l,l.forEach(function(c){n.imp.addNetworkLoadingFont(c)})),u.forEach(function(c){n.imp.addFontsLoadOnInitialization(c,1)})}},{key:"addNetworkLoadingTrueTypeFont",value:function(l,n,u){for(var c=this,y=arguments.length>3&&arguments[3]!==void 0?arguments[3]:[],b=l.length,m=0;m<b;m++)this.imp.addNetworkLoadingTrueTypeFont(l[m],n[m],u[m]),this.trueFonts[l[m]]={name:l[m],zhname:n[m],file:u[m]};y.forEach(function(O){c.imp.addFontsLoadOnInitialization(O,2)})}},{key:"getShxFonts",value:function(){return this.shxFonts}},{key:"getShxBigFonts",value:function(){return this.shxBigFonts}},{key:"loadFonts",value:function(l,n,u,c){McAppFuncton.loadFonts(l,n,u,c)}},{key:"getTrueTypeFonts",value:function(){var l=this,n=[];return Object.keys(this.trueFonts).forEach(function(u){n.push(l.trueFonts[u])}),n}},{key:"getVersionString",value:function(){return this.imp.GetVersionString()}}]),t}(),MxCppType=function(){function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"mxcadassemblyimp",void 0),_defineProperty$1(this,"App",new McAppType),_defineProperty$1(this,"PropertiesWindow",new MxPropertiesWindowCustom),_defineProperty$1(this,"Ai",new MxAI)}return _createClass$1(t,[{key:"getCallResult",value:function(){return this.App.getLastCallResult()}},{key:"newMcGePoint3d",value:function(l){var n=new McGePoint3d;return l&&typeof l.x=="number"&&typeof l.y=="number"&&(n.x=l.x,n.y=l.y,typeof l.z=="number"&&(n.z=l.z)),n}},{key:"newMcGeVector3d",value:function(l){var n=new McGeVector3d;return l&&typeof l.x=="number"&&typeof l.y=="number"&&(n.x=l.x,n.y=l.y,typeof l.z=="number"&&(n.z=l.z)),n}},{key:"getCurrentMxCAD",value:function(){return this.App.getCurrentMxCAD()}},{key:"getCurrentDatabase",value:function(){return this.App.getCurrentMxCAD().getDatabase()}},{key:"decodeFromGb2312",value:function(l){return MxG2312Obj.decodeFromGb2312(l)}},{key:"encodeToGb2312",value:function(l){return MxG2312Obj.encodeToGb2312(l)}}]),t}(),MxCADPluginMapDefaultData=_createClass$1(function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"mapOrigin",[]),_defineProperty$1(this,"cadOrigin",[]),_defineProperty$1(this,"meterInCADUnits",1),_defineProperty$1(this,"mapbox_accessToken",""),_defineProperty$1(this,"openFile",void 0),_defineProperty$1(this,"rasterTileLayerList",[]),_defineProperty$1(this,"rasterTileKey",void 0),_defineProperty$1(this,"providers",void 0),_defineProperty$1(this,"viewColor",void 0)}),MxCADPluginSampleCode=_createClass$1(function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"type",""),_defineProperty$1(this,"name",""),_defineProperty$1(this,"code","")}),MxCADPluginBase=_createClass$1(function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"sRegistData",""),_defineProperty$1(this,"mxcadui",void 0),_defineProperty$1(this,"openFile",void 0),_defineProperty$1(this,"map_default_data",void 0),_defineProperty$1(this,"sampleCode",void 0)}),MxPropertiesWindowCustomValueType=function(t){return t[t.kInt=1]="kInt",t[t.kDouble=2]="kDouble",t[t.kString=3]="kString",t}(MxPropertiesWindowCustomValueType||{}),MxPropertiesWindowCustomValue=_createClass$1(function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"sVarName",""),_defineProperty$1(this,"iVarType",1),_defineProperty$1(this,"val",void 0),_defineProperty$1(this,"isOnlyRead",!1)}),MxPropertiesWindowCustom=function(){function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"getPropertiesCall",null),_defineProperty$1(this,"setPropertiesCall",null)}return _createClass$1(t,[{key:"onEvent_getProperties",value:function(l){this.getPropertiesCall=l}},{key:"onEvent_setProperties",value:function(l){this.setPropertiesCall=l}},{key:"setEntitySupportCustom",value:function(l){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,u=l.getMcDbEntity();u&&u.getImp().setPropertiesWindowCustom(n)}},{key:"getEntityProperties",value:function(l){var n=l.getMcDbEntity();return n?n.getImp().isPropertiesWindowCustom()?this.getPropertiesCall==null?[]:this.getPropertiesCall(l):[]:[]}},{key:"setEntityProperties",value:function(l,n){var u=l.getMcDbEntity();if(u&&u.getImp().isPropertiesWindowCustom()&&this.setPropertiesCall!=null)return this.setPropertiesCall(l,n)}}]),t}(),MxCompare=function(){function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),_defineProperty$1(this,"result",[]),this.imp=new MxCpp.mxcadassemblyimp.MxCompare}return _createClass$1(t,[{key:"getTypeString",value:function(l){var n="";switch(l){case 0:n="no modify";break;case 1:n="unknown";break;case 2:n="object modify";break;case 3:n="object erase";break;case 4:n="object add";break;default:n="unknown"}return n}},{key:"do",value:function(l){if(this.result=[],this.imp.Do(l.imp)){for(var n=new MxCADResbuf(this.imp.getResult()),u=n.GetCount(),c=0;c+2<u;c+=3){var y=n.AtLong(c);if(!y.ret)break;var b=n.AtPoint(c+1);if(!b.ret)break;var m=n.AtLong(c+2);if(!m.ret)break;this.result.push({id:new McObjectId(y.val),pos:b.val,type:m.val,str:this.getTypeString(m.val)})}return!0}return!1}},{key:"getResult",value:function(){return this.result}}]),t}(),MxModifyColor=function(){function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),this.imp=new MxCpp.mxcadassemblyimp.MxTempModifyColor}return _createClass$1(t,[{key:"Do",value:function(l,n){return this.imp.Do(l.imp,n.getImp())}},{key:"DoRestore",value:function(){this.imp.DoRestore()}}]),t}(),MxCpp;function loadMxCADassembly(t){return _loadMxCADassembly.apply(this,arguments)}function _loadMxCADassembly(){return _loadMxCADassembly=_asyncToGenerator(regenerator.mark(function t(e){var l,n,u,c,y=arguments;return regenerator.wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return l=y.length>1&&y[1]!==void 0?y[1]:isSharedArrayBuffer||!isCdn?get2DFileURL:get2DSTFileURL,n=y.length>2?y[2]:void 0,u=y.length>3?y[3]:void 0,c=y.length>4?y[4]:void 0,m.abrupt("return",new Promise(function(){var O=_asyncToGenerator(regenerator.mark(function N(L,G){var q,J,fe,ve;return regenerator.wrap(function(Ue){for(;;)switch(Ue.prev=Ue.next){case 0:if(Ue.prev=0,MxCpp||(MxCpp=new MxCppType),!MxCpp.mxcadassemblyimp){Ue.next=5;break}return e&&e(MxCpp),Ue.abrupt("return",L(MxCpp));case 5:return q="mxdrawassembly_min",Ue.next=8,loadWams$1(q,"mxdrawassembly",{locateFile:l,wasmBinary:n});case 8:J=Ue.sent,MxCpp.mxcadassemblyimp=J,fe=new J.McApp,u?fe.setFontFilePath(u):fe.setFontFilePath("fonts"),fe.Init(),MxCustomEntityManager.init(),MxCpp.App.init(fe),c?MxCpp.App.addNetworkLoadingFont(c):MxCpp.App.addNetworkLoadingFont(["txt.shx","hztxt.shx"]),ve=window,ve.__MxCpp__=MxCpp,e&&e(MxCpp),L(MxCpp),Ue.next=25;break;case 22:Ue.prev=22,Ue.t0=Ue.catch(0),G(Ue.t0);case 25:case"end":return Ue.stop()}},N,null,[[0,22]])}));return function(N,L){return O.apply(this,arguments)}}()));case 5:case"end":return m.stop()}},t)})),_loadMxCADassembly.apply(this,arguments)}function MxCheckTheBrowser(){var t={},e=navigator.userAgent.toLowerCase(),l;if((l=e.match(/edg\/([\d.]+)/))?t.edge=l[1]:(l=e.match(/rv:([\d.]+)\) like gecko/))||(l=e.match(/msie ([\d.]+)/))?t.ie=l[1]:(l=e.match(/firefox\/([\d.]+)/))?t.firefox=l[1]:(l=e.match(/chrome\/([\d.]+)/))?t.chrome=l[1]:(l=e.match(/opera.([\d.]+)/))?t.opera=l[1]:(l=e.match(/version\/([\d.]+).*safari/))&&(t.safari=l[1]),t.ie)return{ok:!1,error:"不支持ie浏览器,使用最新的chrome或edge浏览器",var:t};if(t.edge){var n=new RegExp("edg/([0-9]{1,}[.0-9]{0,})");if(n.exec(e)!=null){var u=parseFloat(RegExp.$1);if(u<107)return{ok:!1,error:"edge浏览器版本太旧,使用最新的edge浏览器",var:t}}}else if(t.chrome){var n=new RegExp("chrome/([0-9]{1,}[.0-9]{0,})");if(n.exec(e)!=null){var c=parseFloat(RegExp.$1);if(c<107)return{ok:!1,error:"浏览器版本太旧,使用最新的chrome浏览器",var:t}}}else if(t.firefox){var n=new RegExp("firefox/([0-9]{1,}[.0-9]{0,})");if(n.exec(e)!=null){var y=parseFloat(RegExp.$1);if(y<101)return{ok:!1,error:"firefox浏览器版本太旧,使用最新的firefox浏览器",var:t}}}else if(!t.safari)return t.opera?{ok:!1,error:"不支持opera浏览器,使用最新的chrome或edge浏览器",var:t}:{ok:!1,error:"不支持该浏览器,使用最新的chrome或edge浏览器",var:t};return{ok:!0,error:"",var:t}}var McGePoint3d=function(){function t(e,l,n){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),this.imp=new MxCpp.mxcadassemblyimp.MdGePoint3d,e instanceof Object?(this.imp.x=e.x,this.imp.y=e.y,this.imp.z=e.z):(this.imp.x=e||0,this.imp.y=l||0,this.imp.z=n||0)}return _createClass$1(t,[{key:"toVector3",value:function(){return new THREE.Vector3(this.imp.x,this.imp.y,this.imp.z)}},{key:"setFromVector3",value:function(l){return this.imp.x=l.x,this.imp.y=l.y,this.imp.z=l.z,this}},{key:"copy",value:function(l){return this.imp.x=l.x,this.imp.y=l.y,this.imp.z=l.z,this}},{key:"transformBy",value:function(l){return this.imp.transformBy(l.imp),this}},{key:"addvec",value:function(l){return this.imp.addvec(l.imp),this}},{key:"av",value:function(l){return this.imp.addvec(l.imp),this}},{key:"subvec",value:function(l){return this.imp.subvec(l.imp),this}},{key:"sv",value:function(l){return this.imp.subvec(l.imp),this}},{key:"sub",value:function(l){return new McGeVector3d(this.imp.sub(l.imp))}},{key:"distanceTo",value:function(l){return this.imp.distanceTo(l.imp)}},{key:"isEqualTo",value:function(l){return this.imp.isEqualTo(l.imp)}},{key:"clone",value:function(){return new t(this.imp)}},{key:"c",value:function(){return new t(this.imp)}},{key:"x",get:function(){return this.imp.x},set:function(l){this.imp.x=l}},{key:"y",get:function(){return this.imp.y},set:function(l){this.imp.y=l}},{key:"z",get:function(){return this.imp.z},set:function(l){this.imp.z=l}}]),t}();_defineProperty$1(McGePoint3d,"kOrigin",void 0);var McGeVector3d=function(){function t(e,l,n){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),this.imp=new MxCpp.mxcadassemblyimp.MdGeVector3d,e instanceof Object?(this.imp.x=e.x,this.imp.y=e.y,this.imp.z=e.z):(this.imp.x=e||0,this.imp.y=l||0,this.imp.z=n||0)}return _createClass$1(t,[{key:"toVector3",value:function(){return new THREE.Vector3(this.imp.x,this.imp.y,this.imp.z)}},{key:"copy",value:function(l){return this.imp.x=l.imp.x,this.imp.y=l.imp.y,this.imp.z=l.imp.z,this}},{key:"clone",value:function(){return new t(this.imp)}},{key:"c",value:function(){return new t(this.imp)}},{key:"rotateBy",value:function(l,n){return n||(n=t.kZAxis),this.imp.rotateBy(l,n.imp),this}},{key:"negate",value:function(){return this.imp.negate(),this}},{key:"perpVector",value:function(){return this.imp.perpVector(),this}},{key:"angleTo1",value:function(l){return this.imp.angleTo(l.imp)}},{key:"angleTo2",value:function(l,n){return n||(n=t.kNegateZAxis),this.imp.angleTo(l.imp,n.imp)}},{key:"normalize",value:function(){return this.imp.normalize(),this}},{key:"length",value:function(){return this.imp.length()}},{key:"isUnitLength",value:function(){return this.imp.isUnitLength()}},{key:"isZeroLength",value:function(){return this.imp.isZeroLength()}},{key:"dotProduct",value:function(l){return this.imp.dotProduct(l.imp)}},{key:"crossProduct",value:function(l){var n=new t;return n.imp=this.imp.crossProduct(l.imp),n}},{key:"isEqualTo",value:function(l){return this.imp.isEqualTo(l.imp)}},{key:"mult",value:function(l){return this.imp.mult(l),this}},{key:"x",get:function(){return this.imp.x},set:function(l){this.imp.x=l}},{key:"y",get:function(){return this.imp.y},set:function(l){this.imp.y=l}},{key:"z",get:function(){return this.imp.z},set:function(l){this.imp.z=l}}]),t}();_defineProperty$1(McGeVector3d,"kXAxis",void 0);_defineProperty$1(McGeVector3d,"kYAxis",void 0);_defineProperty$1(McGeVector3d,"kZAxis",void 0);_defineProperty$1(McGeVector3d,"kNegateZAxis",void 0);var McGeMatrix3d=function(){function t(e){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),this.imp=new MxCpp.mxcadassemblyimp.MdGeMatrix3d,e instanceof Object&&this.imp.copy(e)}return _createClass$1(t,[{key:"copy",value:function(l){return this.imp.copy(l.imp),this}},{key:"clone",value:function(){return new t(this.imp)}},{key:"setToIdentity",value:function(){return this.imp.setToIdentity(),this}},{key:"preMultBy",value:function(l){return this.imp.preMultBy(l.imp),this}},{key:"postMultBy",value:function(l){return this.imp.postMultBy(l.imp),this}},{key:"setToProduct",value:function(l,n){return this.imp.setToProduct(l.imp,n.imp),this}},{key:"invert",value:function(){return this.imp.invert(),this}},{key:"isSingular",value:function(){return this.imp.isSingular()}},{key:"transposeIt",value:function(){return this.imp.transposeIt(),this}},{key:"isEqualTo",value:function(l){return this.imp.isEqualTo(l.imp)}},{key:"det",value:function(){return this.imp.det()}},{key:"setCoordSystem",value:function(l,n,u,c){return this.imp.setCoordSystem(l.imp,n.imp,u.imp,c.imp),this}},{key:"setToTranslation",value:function(l){return this.imp.setToTranslation(l.imp),this}},{key:"setToRotation",value:function(l,n,u){return this.imp.setToRotation(l,n.imp,u.imp),this}},{key:"setToScaling",value:function(l,n){return this.imp.setToScaling(l,n.imp),this}},{key:"setMirror",value:function(l,n){return this.imp.setMirror(l.imp,n.imp),this}},{key:"scale",value:function(){return this.imp.scale()}},{key:"getData",value:function(l,n){return this.imp.getData(l,n)}}]),t}();_defineProperty$1(McGeMatrix3d,"kIdentity",void 0);var McGeLongArray=function(){function t(e){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),this.imp=new MxCpp.mxcadassemblyimp.MdGeLongArray,e instanceof Object&&this.imp.copy(e)}return _createClass$1(t,[{key:"copy",value:function(l){return this.imp.clear(),this.imp.copy(l.imp),this}},{key:"copyFormAryId",value:function(l){var n=this;return this.imp.clear(),l.forEach(function(u){n.imp.append(u.id)}),this}},{key:"append",value:function(l){this.imp.append(l)}},{key:"length",value:function(){return this.imp.length()}},{key:"at",value:function(l){return this.imp.at(l)}},{key:"setAt",value:function(l,n){this.imp.setAt(l,n)}},{key:"clear",value:function(){this.imp.clear()}},{key:"forEach",value:function(l){for(var n=this.imp.length(),u=0;u<n;u++)l(this.imp.at(u),u)}}]),t}(),McGeStringArray=function(){function t(e){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),this.imp=new MxCpp.mxcadassemblyimp.MdGeStringArray,e instanceof Object&&this.imp.copy(e)}return _createClass$1(t,[{key:"copy",value:function(l){return this.imp.copy(l.imp),this}},{key:"append",value:function(l){this.imp.append(l)}},{key:"length",value:function(){return this.imp.length()}},{key:"at",value:function(l){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return n?MxG2312Obj.decodeFromGb2312(this.imp.at(l)):this.imp.at(l)}},{key:"setAt",value:function(l,n){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;u?this.imp.setAt(l,MxG2312Obj.encodeToGb2312(n)):this.imp.setAt(l,n)}},{key:"forEach",value:function(l){for(var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,u=this.imp.length(),c=0;c<u;c++)l(n?MxG2312Obj.decodeFromGb2312(this.imp.at(c)):this.imp.at(c),c)}},{key:"clear",value:function(){this.imp.clear()}}]),t}(),McGePoint3dArray=function(){function t(e){var l=this;_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),this.imp=new MxCpp.mxcadassemblyimp.MdGePoint3dArray,e instanceof Array?e.forEach(function(n){l.imp.append(n.imp)}):e instanceof Object&&this.imp.copy(e)}return _createClass$1(t,[{key:"copy",value:function(l){var n=this;return l instanceof Array?l.forEach(function(u){n.imp.append(u.imp)}):this.imp.copy(l.imp),this}},{key:"append",value:function(l){this.imp.append(l.imp)}},{key:"length",value:function(){return this.imp.length()}},{key:"isEmpty",value:function(){return this.imp.length()==0}},{key:"at",value:function(l){return new McGePoint3d(this.imp.at(l))}},{key:"setAt",value:function(l,n){this.imp.setAt(l,n.imp)}},{key:"clear",value:function(){this.imp.clear()}},{key:"forEach",value:function(l){for(var n=this.imp.length(),u=0;u<n;u++)l(new McGePoint3d(this.imp.at(u)),u)}}]),t}(),McGeDoubleArray=function(){function t(e){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),this.imp=new MxCpp.mxcadassemblyimp.MdGeDoubleArray,e instanceof Object&&this.imp.copy(e)}return _createClass$1(t,[{key:"copy",value:function(l){return this.imp.clear(),this.imp.copy(l.imp),this}},{key:"append",value:function(l){this.imp.append(l)}},{key:"length",value:function(){return this.imp.length()}},{key:"at",value:function(l){return this.imp.at(l)}},{key:"setAt",value:function(l,n){this.imp.setAt(l,n)}},{key:"clear",value:function(){this.imp.clear()}},{key:"forEach",value:function(l){for(var n=this.imp.length(),u=0;u<n;u++)l(this.imp.at(u),u)}}]),t}(),McGeBound=function(){function t(e){_classCallCheck$1(this,t),_defineProperty$1(this,"minPoint",void 0),_defineProperty$1(this,"maxPoint",void 0),_defineProperty$1(this,"isValid",void 0),this.minPoint=new McGePoint3d,this.maxPoint=new McGePoint3d,this.isValid=!1,e&&this.addPoints(e)}return _createClass$1(t,[{key:"addPoint",value:function(l){this.isValid?(this.minPoint.x>l.x&&(this.minPoint.x=l.x),this.minPoint.y>l.y&&(this.minPoint.y=l.y),this.minPoint.z>l.z&&(this.minPoint.y=l.z),this.maxPoint.x<l.x&&(this.maxPoint.x=l.x),this.maxPoint.y<l.y&&(this.maxPoint.y=l.y),this.maxPoint.z<l.z&&(this.maxPoint.z=l.z)):(this.minPoint.x=l.x,this.minPoint.y=l.y,this.minPoint.z=l.z,this.maxPoint.x=l.x,this.maxPoint.y=l.y,this.maxPoint.z=l.z,this.isValid=!0)}},{key:"addPoints",value:function(l){var n=this;l.forEach(function(u){n.addPoint(u)})}}]),t}(),_assign=function t(){return _assign=Object.assign||function(l){for(var n,u=1,c=arguments.length;u<c;u++){n=arguments[u];for(var y in n)Object.prototype.hasOwnProperty.call(n,y)&&(l[y]=n[y])}return l},_assign.apply(this,arguments)};function __awaiter$1(t,e,l,n){function u(c){return c instanceof l?c:new l(function(y){y(c)})}return new(l||(l=Promise))(function(c,y){function b(N){try{O(n.next(N))}catch(L){y(L)}}function m(N){try{O(n.throw(N))}catch(L){y(L)}}function O(N){N.done?c(N.value):u(N.value).then(b,m)}O((n=n.apply(t,[])).next())})}function __generator$1(t,e){var l={label:0,sent:function(){if(c[0]&1)throw c[1];return c[1]},trys:[],ops:[]},n,u,c,y;return y={next:b(0),throw:b(1),return:b(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function b(O){return function(N){return m([O,N])}}function m(O){if(n)throw new TypeError("Generator is already executing.");for(;y&&(y=0,O[0]&&(l=0)),l;)try{if(n=1,u&&(c=O[0]&2?u.return:O[0]?u.throw||((c=u.return)&&c.call(u),0):u.next)&&!(c=c.call(u,O[1])).done)return c;switch(u=0,c&&(O=[O[0]&2,c.value]),O[0]){case 0:case 1:c=O;break;case 4:return l.label++,{value:O[1],done:!1};case 5:l.label++,u=O[1],O=[0];continue;case 7:O=l.ops.pop(),l.trys.pop();continue;default:if(c=l.trys,!(c=c.length>0&&c[c.length-1])&&(O[0]===6||O[0]===2)){l=0;continue}if(O[0]===3&&(!c||O[1]>c[0]&&O[1]<c[3])){l.label=O[1];break}if(O[0]===6&&l.label<c[1]){l.label=c[1],c=O;break}if(c&&l.label<c[2]){l.label=c[2],l.ops.push(O);break}c[2]&&l.ops.pop(),l.trys.pop();continue}O=e.call(t,l)}catch(N){O=[6,N],u=0}finally{n=c=0}if(O[0]&5)throw O[1];return{value:O[0]?O[1]:void 0,done:!0}}}function __spreadArray$1(t,e,l){for(var n=0,u=e.length,c;n<u;n++)(c||!(n in e))&&(c||(c=Array.prototype.slice.call(e,0,n)),c[n]=e[n]);return t.concat(c||Array.prototype.slice.call(e))}typeof SuppressedError=="function"&&SuppressedError;var version$3="4.1.0";function wait$1(t,e){return new Promise(function(l){return setTimeout(l,t,e)})}function releaseEventLoop(){return wait$1(0)}function requestIdleCallbackIfAvailable$1(t,e){e===void 0&&(e=1/0);var l=window.requestIdleCallback;return l?new Promise(function(n){return l.call(window,function(){return n()},{timeout:e})}):wait$1(Math.min(t,e))}function isPromise$1(t){return!!t&&typeof t.then=="function"}function awaitIfAsync$1(t,e){try{var l=t();isPromise$1(l)?l.then(function(n){return e(!0,n)},function(n){return e(!1,n)}):e(!0,l)}catch(n){e(!1,n)}}function mapWithBreaks$1(t,e,l){return l===void 0&&(l=16),__awaiter$1(this,void 0,void 0,function(){var n,u,c,y;return __generator$1(this,function(b){switch(b.label){case 0:n=Array(t.length),u=Date.now(),c=0,b.label=1;case 1:return c<t.length?(n[c]=e(t[c],c),y=Date.now(),y>=u+l?(u=y,[4,wait$1(0)]):[3,3]):[3,4];case 2:b.sent(),b.label=3;case 3:return++c,[3,1];case 4:return[2,n]}})})}function suppressUnhandledRejectionWarning$1(t){t.then(void 0,function(){})}function includes$2(t,e){for(var l=0,n=t.length;l<n;++l)if(t[l]===e)return!0;return!1}function excludes$1(t,e){return!includes$2(t,e)}function toInt$1(t){return parseInt(t)}function toFloat$1(t){return parseFloat(t)}function replaceNaN$1(t,e){return typeof t=="number"&&isNaN(t)?e:t}function countTruthy$1(t){return t.reduce(function(e,l){return e+(l?1:0)},0)}function round$1(t,e){if(e===void 0&&(e=1),Math.abs(e)>=1)return Math.round(t/e)*e;var l=1/e;return Math.round(t*l)/l}function parseSimpleCssSelector$1(t){for(var e,l,n="Unexpected syntax '".concat(t,"'"),u=/^\s*([a-z-]*)(.*)$/i.exec(t),c=u[1]||void 0,y={},b=/([.:#][\w-]+|\[.+?\])/gi,m=function(q,J){y[q]=y[q]||[],y[q].push(J)};;){var O=b.exec(u[2]);if(!O)break;var N=O[0];switch(N[0]){case".":m("class",N.slice(1));break;case"#":m("id",N.slice(1));break;case"[":{var L=/^\[([\w-]+)([~|^$*]?=("(.*?)"|([\w-]+)))?(\s+[is])?\]$/.exec(N);if(L)m(L[1],(l=(e=L[4])!==null&&e!==void 0?e:L[5])!==null&&l!==void 0?l:"");else throw new Error(n);break}default:throw new Error(n)}}return[c,y]}function getUTF8Bytes(t){for(var e=new Uint8Array(t.length),l=0;l<t.length;l++){var n=t.charCodeAt(l);if(n<0||n>127)return new TextEncoder().encode(t);e[l]=n}return e}function x64Add$1(t,e){var l=t[0]>>>16,n=t[0]&65535,u=t[1]>>>16,c=t[1]&65535,y=e[0]>>>16,b=e[0]&65535,m=e[1]>>>16,O=e[1]&65535,N=0,L=0,G=0,q=0;q+=c+O,G+=q>>>16,q&=65535,G+=u+m,L+=G>>>16,G&=65535,L+=n+b,N+=L>>>16,L&=65535,N+=l+y,N&=65535,t[0]=N<<16|L,t[1]=G<<16|q}function x64Multiply$1(t,e){var l=t[0]>>>16,n=t[0]&65535,u=t[1]>>>16,c=t[1]&65535,y=e[0]>>>16,b=e[0]&65535,m=e[1]>>>16,O=e[1]&65535,N=0,L=0,G=0,q=0;q+=c*O,G+=q>>>16,q&=65535,G+=u*O,L+=G>>>16,G&=65535,G+=c*m,L+=G>>>16,G&=65535,L+=n*O,N+=L>>>16,L&=65535,L+=u*m,N+=L>>>16,L&=65535,L+=c*b,N+=L>>>16,L&=65535,N+=l*O+n*m+u*b+c*y,N&=65535,t[0]=N<<16|L,t[1]=G<<16|q}function x64Rotl$1(t,e){var l=t[0];e%=64,e===32?(t[0]=t[1],t[1]=l):e<32?(t[0]=l<<e|t[1]>>>32-e,t[1]=t[1]<<e|l>>>32-e):(e-=32,t[0]=t[1]<<e|l>>>32-e,t[1]=l<<e|t[1]>>>32-e)}function x64LeftShift$1(t,e){e%=64,e!==0&&(e<32?(t[0]=t[1]>>>32-e,t[1]=t[1]<<e):(t[0]=t[1]<<e-32,t[1]=0))}function x64Xor$1(t,e){t[0]^=e[0],t[1]^=e[1]}var F1=[4283543511,3981806797],F2=[3301882366,444984403];function x64Fmix$1(t){var e=[0,t[0]>>>1];x64Xor$1(t,e),x64Multiply$1(t,F1),e[1]=t[0]>>>1,x64Xor$1(t,e),x64Multiply$1(t,F2),e[1]=t[0]>>>1,x64Xor$1(t,e)}var C1=[2277735313,289559509],C2=[1291169091,658871167],M$1$1=[0,5],N1=[0,1390208809],N2=[0,944331445];function x64hash128$1(t,e){var l=getUTF8Bytes(t);e=e||0;var n=[0,l.length],u=n[1]%16,c=n[1]-u,y=[0,e],b=[0,e],m=[0,0],O=[0,0],N;for(N=0;N<c;N=N+16)m[0]=l[N+4]|l[N+5]<<8|l[N+6]<<16|l[N+7]<<24,m[1]=l[N]|l[N+1]<<8|l[N+2]<<16|l[N+3]<<24,O[0]=l[N+12]|l[N+13]<<8|l[N+14]<<16|l[N+15]<<24,O[1]=l[N+8]|l[N+9]<<8|l[N+10]<<16|l[N+11]<<24,x64Multiply$1(m,C1),x64Rotl$1(m,31),x64Multiply$1(m,C2),x64Xor$1(y,m),x64Rotl$1(y,27),x64Add$1(y,b),x64Multiply$1(y,M$1$1),x64Add$1(y,N1),x64Multiply$1(O,C2),x64Rotl$1(O,33),x64Multiply$1(O,C1),x64Xor$1(b,O),x64Rotl$1(b,31),x64Add$1(b,y),x64Multiply$1(b,M$1$1),x64Add$1(b,N2);m[0]=0,m[1]=0,O[0]=0,O[1]=0;var L=[0,0];switch(u){case 15:L[1]=l[N+14],x64LeftShift$1(L,48),x64Xor$1(O,L);case 14:L[1]=l[N+13],x64LeftShift$1(L,40),x64Xor$1(O,L);case 13:L[1]=l[N+12],x64LeftShift$1(L,32),x64Xor$1(O,L);case 12:L[1]=l[N+11],x64LeftShift$1(L,24),x64Xor$1(O,L);case 11:L[1]=l[N+10],x64LeftShift$1(L,16),x64Xor$1(O,L);case 10:L[1]=l[N+9],x64LeftShift$1(L,8),x64Xor$1(O,L);case 9:L[1]=l[N+8],x64Xor$1(O,L),x64Multiply$1(O,C2),x64Rotl$1(O,33),x64Multiply$1(O,C1),x64Xor$1(b,O);case 8:L[1]=l[N+7],x64LeftShift$1(L,56),x64Xor$1(m,L);case 7:L[1]=l[N+6],x64LeftShift$1(L,48),x64Xor$1(m,L);case 6:L[1]=l[N+5],x64LeftShift$1(L,40),x64Xor$1(m,L);case 5:L[1]=l[N+4],x64LeftShift$1(L,32),x64Xor$1(m,L);case 4:L[1]=l[N+3],x64LeftShift$1(L,24),x64Xor$1(m,L);case 3:L[1]=l[N+2],x64LeftShift$1(L,16),x64Xor$1(m,L);case 2:L[1]=l[N+1],x64LeftShift$1(L,8),x64Xor$1(m,L);case 1:L[1]=l[N],x64Xor$1(m,L),x64Multiply$1(m,C1),x64Rotl$1(m,31),x64Multiply$1(m,C2),x64Xor$1(y,m)}return x64Xor$1(y,n),x64Xor$1(b,n),x64Add$1(y,b),x64Add$1(b,y),x64Fmix$1(y),x64Fmix$1(b),x64Add$1(y,b),x64Add$1(b,y),("00000000"+(y[0]>>>0).toString(16)).slice(-8)+("00000000"+(y[1]>>>0).toString(16)).slice(-8)+("00000000"+(b[0]>>>0).toString(16)).slice(-8)+("00000000"+(b[1]>>>0).toString(16)).slice(-8)}function errorToObject$1(t){var e;return _assign({name:t.name,message:t.message,stack:(e=t.stack)===null||e===void 0?void 0:e.split(`
- `)},t)}function isFunctionNative(t){return/^function\s.*?\{\s*\[native code]\s*}$/.test(String(t))}function isFinalResultLoaded$1(t){return typeof t!="function"}function loadSource$1(t,e){var l=new Promise(function(n){var u=Date.now();awaitIfAsync$1(t.bind(null,e),function(){for(var c=[],y=0;y<arguments.length;y++)c[y]=arguments[y];var b=Date.now()-u;if(!c[0])return n(function(){return{error:c[1],duration:b}});var m=c[1];if(isFinalResultLoaded$1(m))return n(function(){return{value:m,duration:b}});n(function(){return new Promise(function(O){var N=Date.now();awaitIfAsync$1(m,function(){for(var L=[],G=0;G<arguments.length;G++)L[G]=arguments[G];var q=b+Date.now()-N;if(!L[0])return O({error:L[1],duration:q});O({value:L[1],duration:q})})})})})});return suppressUnhandledRejectionWarning$1(l),function(){return l.then(function(u){return u()})}}function loadSources$1(t,e,l){var n=Object.keys(t).filter(function(c){return excludes$1(l,c)}),u=mapWithBreaks$1(n,function(c){return loadSource$1(t[c],e)});return suppressUnhandledRejectionWarning$1(u),function(){return __awaiter$1(this,void 0,void 0,function(){var y,b,m,O,N;return __generator$1(this,function(L){switch(L.label){case 0:return[4,u];case 1:return y=L.sent(),[4,mapWithBreaks$1(y,function(G){var q=G();return suppressUnhandledRejectionWarning$1(q),q})];case 2:return b=L.sent(),[4,Promise.all(b)];case 3:for(m=L.sent(),O={},N=0;N<n.length;++N)O[n[N]]=m[N];return[2,O]}})})}}function isTrident$1(){var t=window,e=navigator;return countTruthy$1(["MSCSSMatrix"in t,"msSetImmediate"in t,"msIndexedDB"in t,"msMaxTouchPoints"in e,"msPointerEnabled"in e])>=4}function isEdgeHTML$1(){var t=window,e=navigator;return countTruthy$1(["msWriteProfilerMark"in t,"MSStream"in t,"msLaunchUri"in e,"msSaveBlob"in e])>=3&&!isTrident$1()}function isChromium$1(){var t=window,e=navigator;return countTruthy$1(["webkitPersistentStorage"in e,"webkitTemporaryStorage"in e,e.vendor.indexOf("Google")===0,"webkitResolveLocalFileSystemURL"in t,"BatteryManager"in t,"webkitMediaStream"in t,"webkitSpeechGrammar"in t])>=5}function isWebKit$1(){var t=window,e=navigator;return countTruthy$1(["ApplePayError"in t,"CSSPrimitiveValue"in t,"Counter"in t,e.vendor.indexOf("Apple")===0,"getStorageUpdates"in e,"WebKitMediaKeys"in t])>=4}function isDesktopWebKit(){var t=window,e=t.HTMLElement,l=t.Document;return countTruthy$1(["safari"in t,!("ongestureend"in t),!("TouchEvent"in t),!("orientation"in t),e&&!("autocapitalize"in e.prototype),l&&"pointerLockElement"in l.prototype])>=4}function isSafariWebKit(){var t=window;return isFunctionNative(t.print)?countTruthy$1([String(t.browser)==="[object WebPageNamespace]","MicrodataExtractor"in t])>=1:!1}function isGecko$1(){var t,e,l=window;return countTruthy$1(["buildID"in navigator,"MozAppearance"in((e=(t=document.documentElement)===null||t===void 0?void 0:t.style)!==null&&e!==void 0?e:{}),"onmozfullscreenchange"in l,"mozInnerScreenX"in l,"CSSMozDocumentRule"in l,"CanvasCaptureMediaStream"in l])>=4}function isChromium86OrNewer$1(){var t=window;return countTruthy$1([!("MediaSettingsRange"in t),"RTCEncodedAudioFrame"in t,""+t.Intl=="[object Intl]",""+t.Reflect=="[object Reflect]"])>=3}function isWebKit606OrNewer$1(){var t=window;return countTruthy$1(["DOMRectList"in t,"RTCPeerConnectionIceEvent"in t,"SVGGeometryElement"in t,"ontransitioncancel"in t])>=3}function isWebKit616OrNewer(){var t=window,e=navigator,l=t.CSS,n=t.HTMLButtonElement;return countTruthy$1([!("getStorageUpdates"in e),n&&"popover"in n.prototype,"CSSCounterStyleRule"in t,l.supports("font-size-adjust: ex-height 0.5"),l.supports("text-transform: full-width")])>=4}function isIPad$1(){if(navigator.platform==="iPad")return!0;var t=screen,e=t.width/t.height;return countTruthy$1(["MediaSource"in window,!!Element.prototype.webkitRequestFullscreen,e>.65&&e<1.53])>=2}function getFullscreenElement$1(){var t=document;return t.fullscreenElement||t.msFullscreenElement||t.mozFullScreenElement||t.webkitFullscreenElement||null}function exitFullscreen$1(){var t=document;return(t.exitFullscreen||t.msExitFullscreen||t.mozCancelFullScreen||t.webkitExitFullscreen).call(t)}function isAndroid$1(){var t=isChromium$1(),e=isGecko$1();if(!t&&!e)return!1;var l=window;return countTruthy$1(["onorientationchange"in l,"orientation"in l,t&&!("SharedWorker"in l),e&&/android/i.test(navigator.appVersion)])>=2}function getAudioFingerprint$1(){return doesBrowserPerformAntifingerprinting$1()?-4:getRawAudioFingerprint()}function getRawAudioFingerprint(){var t=window,e=t.OfflineAudioContext||t.webkitOfflineAudioContext;if(!e)return-2;if(doesBrowserSuspendAudioContext())return-1;var l=4500,n=5e3,u=new e(1,n,44100),c=u.createOscillator();c.type="triangle",c.frequency.value=1e4;var y=u.createDynamicsCompressor();y.threshold.value=-50,y.knee.value=40,y.ratio.value=12,y.attack.value=0,y.release.value=.25,c.connect(y),y.connect(u.destination),c.start(0);var b=startRenderingAudio$1(u),m=b[0],O=b[1],N=m.then(function(L){return getHash$1(L.getChannelData(0).subarray(l))},function(L){if(L.name==="timeout"||L.name==="suspended")return-3;throw L});return suppressUnhandledRejectionWarning$1(N),function(){return O(),N}}function doesBrowserSuspendAudioContext(){return isWebKit$1()&&!isDesktopWebKit()&&!isWebKit606OrNewer$1()}function doesBrowserPerformAntifingerprinting$1(){return isWebKit$1()&&isWebKit616OrNewer()&&isSafariWebKit()}function startRenderingAudio$1(t){var e=3,l=500,n=500,u=5e3,c=function(){},y=new Promise(function(b,m){var O=!1,N=0,L=0;t.oncomplete=function(J){return b(J.renderedBuffer)};var G=function(){setTimeout(function(){return m(makeInnerError$1("timeout"))},Math.min(n,L+u-Date.now()))},q=function J(){try{var fe=t.startRendering();switch(isPromise$1(fe)&&suppressUnhandledRejectionWarning$1(fe),t.state){case"running":L=Date.now(),O&&G();break;case"suspended":document.hidden||N++,O&&N>=e?m(makeInnerError$1("suspended")):setTimeout(J,l);break}}catch(ve){m(ve)}};q(),c=function(){O||(O=!0,L>0&&G())}});return[y,c]}function getHash$1(t){for(var e=0,l=0;l<t.length;++l)e+=Math.abs(t[l]);return e}function makeInnerError$1(t){var e=new Error(t);return e.name=t,e}function withIframe$1(t,e,l){var n,u,c;return l===void 0&&(l=50),__awaiter$1(this,void 0,void 0,function(){var y,b;return __generator$1(this,function(m){switch(m.label){case 0:y=document,m.label=1;case 1:return y.body?[3,3]:[4,wait$1(l)];case 2:return m.sent(),[3,1];case 3:b=y.createElement("iframe"),m.label=4;case 4:return m.trys.push([4,,10,11]),[4,new Promise(function(O,N){var L=!1,G=function(){L=!0,O()},q=function(ne){L=!0,N(ne)};b.onload=G,b.onerror=q;var J=b.style;J.setProperty("display","block","important"),J.position="absolute",J.top="0",J.left="0",J.visibility="hidden",e&&"srcdoc"in b?b.srcdoc=e:b.src="about:blank",y.body.appendChild(b);var fe=function ve(){var ne,Ue;L||(((Ue=(ne=b.contentWindow)===null||ne===void 0?void 0:ne.document)===null||Ue===void 0?void 0:Ue.readyState)==="complete"?G():setTimeout(ve,10))};fe()})];case 5:m.sent(),m.label=6;case 6:return!((u=(n=b.contentWindow)===null||n===void 0?void 0:n.document)===null||u===void 0)&&u.body?[3,8]:[4,wait$1(l)];case 7:return m.sent(),[3,6];case 8:return[4,t(b,b.contentWindow)];case 9:return[2,m.sent()];case 10:return(c=b.parentNode)===null||c===void 0||c.removeChild(b),[7];case 11:return[2]}})})}function selectorToElement$1(t){for(var e=parseSimpleCssSelector$1(t),l=e[0],n=e[1],u=document.createElement(l??"div"),c=0,y=Object.keys(n);c<y.length;c++){var b=y[c],m=n[b].join(" ");b==="style"?addStyleString$1(u.style,m):u.setAttribute(b,m)}return u}function addStyleString$1(t,e){for(var l=0,n=e.split(";");l<n.length;l++){var u=n[l],c=/^\s*([\w-]+)\s*:\s*(.+?)(\s*!([\w-]+))?\s*$/.exec(u);if(c){var y=c[1],b=c[2],m=c[4];t.setProperty(y,b,m||"")}}}var testString$1="mmMwWLliI0O&1",textSize$1="48px",baseFonts$1=["monospace","sans-serif","serif"],fontList$1=["sans-serif-thin","ARNO PRO","Agency FB","Arabic Typesetting","Arial Unicode MS","AvantGarde Bk BT","BankGothic Md BT","Batang","Bitstream Vera Sans Mono","Calibri","Century","Century Gothic","Clarendon","EUROSTILE","Franklin Gothic","Futura Bk BT","Futura Md BT","GOTHAM","Gill Sans","HELV","Haettenschweiler","Helvetica Neue","Humanst521 BT","Leelawadee","Letter Gothic","Levenim MT","Lucida Bright","Lucida Sans","Menlo","MS Mincho","MS Outlook","MS Reference Specialty","MS UI Gothic","MT Extra","MYRIAD PRO","Marlett","Meiryo UI","Microsoft Uighur","Minion Pro","Monotype Corsiva","PMingLiU","Pristina","SCRIPTINA","Segoe UI Light","Serifa","SimHei","Small Fonts","Staccato222 BT","TRAJAN PRO","Univers CE 55 Medium","Vrinda","ZWAdobeF"];function getFonts$1(){var t=this;return withIframe$1(function(e,l){var n=l.document;return __awaiter$1(t,void 0,void 0,function(){var u,c,y,b,m,O,N,L,G,q,J,fe;return __generator$1(this,function(ve){switch(ve.label){case 0:return u=n.body,u.style.fontSize=textSize$1,c=n.createElement("div"),c.style.setProperty("visibility","hidden","important"),y={},b={},m=function(Ue){var De=n.createElement("span"),Ve=De.style;return Ve.position="absolute",Ve.top="0",Ve.left="0",Ve.fontFamily=Ue,De.textContent=testString$1,c.appendChild(De),De},O=function(Ue,De){return m("'".concat(Ue,"',").concat(De))},N=function(){return baseFonts$1.map(m)},L=function(){for(var Ue={},De=function(Xe){Ue[Xe]=baseFonts$1.map(function(ie){return O(Xe,ie)})},Ve=0,rt=fontList$1;Ve<rt.length;Ve++){var Ae=rt[Ve];De(Ae)}return Ue},G=function(Ue){return baseFonts$1.some(function(De,Ve){return Ue[Ve].offsetWidth!==y[De]||Ue[Ve].offsetHeight!==b[De]})},q=N(),J=L(),u.appendChild(c),[4,releaseEventLoop()];case 1:for(ve.sent(),fe=0;fe<baseFonts$1.length;fe++)y[baseFonts$1[fe]]=q[fe].offsetWidth,b[baseFonts$1[fe]]=q[fe].offsetHeight;return[2,fontList$1.filter(function(ne){return G(J[ne])})]}})})})}function getPlugins$1(){var t=navigator.plugins;if(t){for(var e=[],l=0;l<t.length;++l){var n=t[l];if(n){for(var u=[],c=0;c<n.length;++c){var y=n[c];u.push({type:y.type,suffixes:y.suffixes})}e.push({name:n.name,description:n.description,mimeTypes:u})}}return e}}function getCanvasFingerprint$1(){return getRawCanvasFingerprint(doesBrowserPerformAntifingerprinting())}function getRawCanvasFingerprint(t){return __awaiter$1(this,void 0,void 0,function(){var e,l,n,u,c,y,b;return __generator$1(this,function(m){switch(m.label){case 0:return e=!1,u=makeCanvasContext$1(),c=u[0],y=u[1],isSupported$1(c,y)?[3,1]:(l=n="unsupported",[3,4]);case 1:return e=doesSupportWinding$1(y),t?(l=n="skipped",[3,4]):[3,2];case 2:return[4,renderImages(c,y)];case 3:b=m.sent(),l=b[0],n=b[1],m.label=4;case 4:return[2,{winding:e,geometry:l,text:n}]}})})}function makeCanvasContext$1(){var t=document.createElement("canvas");return t.width=1,t.height=1,[t,t.getContext("2d")]}function isSupported$1(t,e){return!!(e&&t.toDataURL)}function doesSupportWinding$1(t){return t.rect(0,0,10,10),t.rect(2,2,6,6),!t.isPointInPath(5,5,"evenodd")}function renderImages(t,e){return __awaiter$1(this,void 0,void 0,function(){var l,n,u;return __generator$1(this,function(c){switch(c.label){case 0:return renderTextImage$1(t,e),[4,releaseEventLoop()];case 1:return c.sent(),l=canvasToString$1(t),n=canvasToString$1(t),l!==n?[2,["unstable","unstable"]]:(renderGeometryImage$1(t,e),[4,releaseEventLoop()]);case 2:return c.sent(),u=canvasToString$1(t),[2,[l,u]]}})})}function renderTextImage$1(t,e){t.width=240,t.height=60,e.textBaseline="alphabetic",e.fillStyle="#f60",e.fillRect(100,1,62,20),e.fillStyle="#069",e.font='11pt "Times New Roman"';var l="Cwm fjordbank gly ".concat("😃");e.fillText(l,2,15),e.fillStyle="rgba(102, 204, 0, 0.2)",e.font="18pt Arial",e.fillText(l,4,45)}function renderGeometryImage$1(t,e){t.width=122,t.height=110,e.globalCompositeOperation="multiply";for(var l=0,n=[["#f2f",40,40],["#2ff",80,40],["#ff2",60,80]];l<n.length;l++){var u=n[l],c=u[0],y=u[1],b=u[2];e.fillStyle=c,e.beginPath(),e.arc(y,b,40,0,Math.PI*2,!0),e.closePath(),e.fill()}e.fillStyle="#f9c",e.arc(60,60,60,0,Math.PI*2,!0),e.arc(60,60,20,0,Math.PI*2,!0),e.fill("evenodd")}function canvasToString$1(t){return t.toDataURL()}function doesBrowserPerformAntifingerprinting(){return isWebKit$1()&&isWebKit616OrNewer()&&isSafariWebKit()}function getTouchSupport$1(){var t=navigator,e=0,l;t.maxTouchPoints!==void 0?e=toInt$1(t.maxTouchPoints):t.msMaxTouchPoints!==void 0&&(e=t.msMaxTouchPoints);try{document.createEvent("TouchEvent"),l=!0}catch{l=!1}var n="ontouchstart"in window;return{maxTouchPoints:e,touchEvent:l,touchStart:n}}function getOsCpu$1(){return navigator.oscpu}function getLanguages$1(){var t=navigator,e=[],l=t.language||t.userLanguage||t.browserLanguage||t.systemLanguage;if(l!==void 0&&e.push([l]),Array.isArray(t.languages))isChromium$1()&&isChromium86OrNewer$1()||e.push(t.languages);else if(typeof t.languages=="string"){var n=t.languages;n&&e.push(n.split(","))}return e}function getColorDepth$1(){return window.screen.colorDepth}function getDeviceMemory$1(){return replaceNaN$1(toFloat$1(navigator.deviceMemory),void 0)}function getScreenResolution$1(){if(!(isWebKit$1()&&isWebKit616OrNewer()&&isSafariWebKit()))return getRawScreenResolution()}function getRawScreenResolution(){var t=screen,e=function(u){return replaceNaN$1(toInt$1(u),null)},l=[e(t.width),e(t.height)];return l.sort().reverse(),l}var screenFrameCheckInterval$1=2500,roundingPrecision$1=10,screenFrameBackup$1,screenFrameSizeTimeoutId$1;function watchScreenFrame$1(){if(screenFrameSizeTimeoutId$1===void 0){var t=function e(){var l=getCurrentScreenFrame$1();isFrameSizeNull$1(l)?screenFrameSizeTimeoutId$1=setTimeout(e,screenFrameCheckInterval$1):(screenFrameBackup$1=l,screenFrameSizeTimeoutId$1=void 0)};t()}}function getRawScreenFrame(){var t=this;return watchScreenFrame$1(),function(){return __awaiter$1(t,void 0,void 0,function(){var e;return __generator$1(this,function(l){switch(l.label){case 0:return e=getCurrentScreenFrame$1(),isFrameSizeNull$1(e)?screenFrameBackup$1?[2,__spreadArray$1([],screenFrameBackup$1)]:getFullscreenElement$1()?[4,exitFullscreen$1()]:[3,2]:[3,2];case 1:l.sent(),e=getCurrentScreenFrame$1(),l.label=2;case 2:return isFrameSizeNull$1(e)||(screenFrameBackup$1=e),[2,e]}})})}}function getScreenFrame$1(){var t=this;if(isWebKit$1()&&isWebKit616OrNewer()&&isSafariWebKit())return function(){return Promise.resolve(void 0)};var e=getRawScreenFrame();return function(){return __awaiter$1(t,void 0,void 0,function(){var l,n;return __generator$1(this,function(u){switch(u.label){case 0:return[4,e()];case 1:return l=u.sent(),n=function(y){return y===null?null:round$1(y,roundingPrecision$1)},[2,[n(l[0]),n(l[1]),n(l[2]),n(l[3])]]}})})}}function getCurrentScreenFrame$1(){var t=screen;return[replaceNaN$1(toFloat$1(t.availTop),null),replaceNaN$1(toFloat$1(t.width)-toFloat$1(t.availWidth)-replaceNaN$1(toFloat$1(t.availLeft),0),null),replaceNaN$1(toFloat$1(t.height)-toFloat$1(t.availHeight)-replaceNaN$1(toFloat$1(t.availTop),0),null),replaceNaN$1(toFloat$1(t.availLeft),null)]}function isFrameSizeNull$1(t){for(var e=0;e<4;++e)if(t[e])return!1;return!0}function getHardwareConcurrency$1(){return replaceNaN$1(toInt$1(navigator.hardwareConcurrency),void 0)}function getTimezone$1(){var t,e=(t=window.Intl)===null||t===void 0?void 0:t.DateTimeFormat;if(e){var l=new e().resolvedOptions().timeZone;if(l)return l}var n=-getTimezoneOffset$1();return"UTC".concat(n>=0?"+":"").concat(Math.abs(n))}function getTimezoneOffset$1(){var t=new Date().getFullYear();return Math.max(toFloat$1(new Date(t,0,1).getTimezoneOffset()),toFloat$1(new Date(t,6,1).getTimezoneOffset()))}function getSessionStorage$1(){try{return!!window.sessionStorage}catch{return!0}}function getLocalStorage$1(){try{return!!window.localStorage}catch{return!0}}function getIndexedDB$1(){if(!(isTrident$1()||isEdgeHTML$1()))try{return!!window.indexedDB}catch{return!0}}function getOpenDatabase$1(){return!!window.openDatabase}function getCpuClass$1(){return navigator.cpuClass}function getPlatform$2(){var t=navigator.platform;return t==="MacIntel"&&isWebKit$1()&&!isDesktopWebKit()?isIPad$1()?"iPad":"iPhone":t}function getVendor$1(){return navigator.vendor||""}function getVendorFlavors$1(){for(var t=[],e=0,l=["chrome","safari","__crWeb","__gCrWeb","yandex","__yb","__ybro","__firefox__","__edgeTrackingPreventionStatistics","webkit","oprt","samsungAr","ucweb","UCShellJava","puffinDevice"];e<l.length;e++){var n=l[e],u=window[n];u&&_typeof$2(u)==="object"&&t.push(n)}return t.sort()}function areCookiesEnabled$1(){var t=document;try{t.cookie="cookietest=1; SameSite=Strict;";var e=t.cookie.indexOf("cookietest=")!==-1;return t.cookie="cookietest=1; SameSite=Strict; expires=Thu, 01-Jan-1970 00:00:01 GMT",e}catch{return!1}}function getFilters$1(){var t=atob;return{abpIndo:["#Iklan-Melayang","#Kolom-Iklan-728","#SidebarIklan-wrapper",'[title="ALIENBOLA" i]',t("I0JveC1CYW5uZXItYWRz")],abpvn:[".quangcao","#mobileCatfish",t("LmNsb3NlLWFkcw=="),'[id^="bn_bottom_fixed_"]',"#pmadv"],adBlockFinland:[".mainostila",t("LnNwb25zb3JpdA=="),".ylamainos",t("YVtocmVmKj0iL2NsaWNrdGhyZ2guYXNwPyJd"),t("YVtocmVmXj0iaHR0cHM6Ly9hcHAucmVhZHBlYWsuY29tL2FkcyJd")],adBlockPersian:["#navbar_notice_50",".kadr",'TABLE[width="140px"]',"#divAgahi",t("YVtocmVmXj0iaHR0cDovL2cxLnYuZndtcm0ubmV0L2FkLyJd")],adBlockWarningRemoval:["#adblock-honeypot",".adblocker-root",".wp_adblock_detect",t("LmhlYWRlci1ibG9ja2VkLWFk"),t("I2FkX2Jsb2NrZXI=")],adGuardAnnoyances:[".hs-sosyal","#cookieconsentdiv",'div[class^="app_gdpr"]',".as-oil",'[data-cypress="soft-push-notification-modal"]'],adGuardBase:[".BetterJsPopOverlay",t("I2FkXzMwMFgyNTA="),t("I2Jhbm5lcmZsb2F0MjI="),t("I2NhbXBhaWduLWJhbm5lcg=="),t("I0FkLUNvbnRlbnQ=")],adGuardChinese:[t("LlppX2FkX2FfSA=="),t("YVtocmVmKj0iLmh0aGJldDM0LmNvbSJd"),"#widget-quan",t("YVtocmVmKj0iLzg0OTkyMDIwLnh5eiJd"),t("YVtocmVmKj0iLjE5NTZobC5jb20vIl0=")],adGuardFrench:["#pavePub",t("LmFkLWRlc2t0b3AtcmVjdGFuZ2xl"),".mobile_adhesion",".widgetadv",t("LmFkc19iYW4=")],adGuardGerman:['aside[data-portal-id="leaderboard"]'],adGuardJapanese:["#kauli_yad_1",t("YVtocmVmXj0iaHR0cDovL2FkMi50cmFmZmljZ2F0ZS5uZXQvIl0="),t("Ll9wb3BJbl9pbmZpbml0ZV9hZA=="),t("LmFkZ29vZ2xl"),t("Ll9faXNib29zdFJldHVybkFk")],adGuardMobile:[t("YW1wLWF1dG8tYWRz"),t("LmFtcF9hZA=="),'amp-embed[type="24smi"]',"#mgid_iframe1",t("I2FkX2ludmlld19hcmVh")],adGuardRussian:[t("YVtocmVmXj0iaHR0cHM6Ly9hZC5sZXRtZWFkcy5jb20vIl0="),t("LnJlY2xhbWE="),'div[id^="smi2adblock"]',t("ZGl2W2lkXj0iQWRGb3hfYmFubmVyXyJd"),"#psyduckpockeball"],adGuardSocial:[t("YVtocmVmXj0iLy93d3cuc3R1bWJsZXVwb24uY29tL3N1Ym1pdD91cmw9Il0="),t("YVtocmVmXj0iLy90ZWxlZ3JhbS5tZS9zaGFyZS91cmw/Il0="),".etsy-tweet","#inlineShare",".popup-social"],adGuardSpanishPortuguese:["#barraPublicidade","#Publicidade","#publiEspecial","#queTooltip",".cnt-publi"],adGuardTrackingProtection:["#qoo-counter",t("YVtocmVmXj0iaHR0cDovL2NsaWNrLmhvdGxvZy5ydS8iXQ=="),t("YVtocmVmXj0iaHR0cDovL2hpdGNvdW50ZXIucnUvdG9wL3N0YXQucGhwIl0="),t("YVtocmVmXj0iaHR0cDovL3RvcC5tYWlsLnJ1L2p1bXAiXQ=="),"#top100counter"],adGuardTurkish:["#backkapat",t("I3Jla2xhbWk="),t("YVtocmVmXj0iaHR0cDovL2Fkc2Vydi5vbnRlay5jb20udHIvIl0="),t("YVtocmVmXj0iaHR0cDovL2l6bGVuemkuY29tL2NhbXBhaWduLyJd"),t("YVtocmVmXj0iaHR0cDovL3d3dy5pbnN0YWxsYWRzLm5ldC8iXQ==")],bulgarian:[t("dGQjZnJlZW5ldF90YWJsZV9hZHM="),"#ea_intext_div",".lapni-pop-over","#xenium_hot_offers"],easyList:[".yb-floorad",t("LndpZGdldF9wb19hZHNfd2lkZ2V0"),t("LnRyYWZmaWNqdW5reS1hZA=="),".textad_headline",t("LnNwb25zb3JlZC10ZXh0LWxpbmtz")],easyListChina:[t("LmFwcGd1aWRlLXdyYXBbb25jbGljayo9ImJjZWJvcy5jb20iXQ=="),t("LmZyb250cGFnZUFkdk0="),"#taotaole","#aafoot.top_box",".cfa_popup"],easyListCookie:[".ezmob-footer",".cc-CookieWarning","[data-cookie-number]",t("LmF3LWNvb2tpZS1iYW5uZXI="),".sygnal24-gdpr-modal-wrap"],easyListCzechSlovak:["#onlajny-stickers",t("I3Jla2xhbW5pLWJveA=="),t("LnJla2xhbWEtbWVnYWJvYXJk"),".sklik",t("W2lkXj0ic2tsaWtSZWtsYW1hIl0=")],easyListDutch:[t("I2FkdmVydGVudGll"),t("I3ZpcEFkbWFya3RCYW5uZXJCbG9jaw=="),".adstekst",t("YVtocmVmXj0iaHR0cHM6Ly94bHR1YmUubmwvY2xpY2svIl0="),"#semilo-lrectangle"],easyListGermany:["#SSpotIMPopSlider",t("LnNwb25zb3JsaW5rZ3J1ZW4="),t("I3dlcmJ1bmdza3k="),t("I3Jla2xhbWUtcmVjaHRzLW1pdHRl"),t("YVtocmVmXj0iaHR0cHM6Ly9iZDc0Mi5jb20vIl0=")],easyListItaly:[t("LmJveF9hZHZfYW5udW5jaQ=="),".sb-box-pubbliredazionale",t("YVtocmVmXj0iaHR0cDovL2FmZmlsaWF6aW9uaWFkcy5zbmFpLml0LyJd"),t("YVtocmVmXj0iaHR0cHM6Ly9hZHNlcnZlci5odG1sLml0LyJd"),t("YVtocmVmXj0iaHR0cHM6Ly9hZmZpbGlhemlvbmlhZHMuc25haS5pdC8iXQ==")],easyListLithuania:[t("LnJla2xhbW9zX3RhcnBhcw=="),t("LnJla2xhbW9zX251b3JvZG9z"),t("aW1nW2FsdD0iUmVrbGFtaW5pcyBza3lkZWxpcyJd"),t("aW1nW2FsdD0iRGVkaWt1b3RpLmx0IHNlcnZlcmlhaSJd"),t("aW1nW2FsdD0iSG9zdGluZ2FzIFNlcnZlcmlhaS5sdCJd")],estonian:[t("QVtocmVmKj0iaHR0cDovL3BheTRyZXN1bHRzMjQuZXUiXQ==")],fanboyAnnoyances:["#ac-lre-player",".navigate-to-top","#subscribe_popup",".newsletter_holder","#back-top"],fanboyAntiFacebook:[".util-bar-module-firefly-visible"],fanboyEnhancedTrackers:[".open.pushModal","#issuem-leaky-paywall-articles-zero-remaining-nag","#sovrn_container",'div[class$="-hide"][zoompage-fontsize][style="display: block;"]',".BlockNag__Card"],fanboySocial:["#FollowUs","#meteored_share","#social_follow",".article-sharer",".community__social-desc"],frellwitSwedish:[t("YVtocmVmKj0iY2FzaW5vcHJvLnNlIl1bdGFyZ2V0PSJfYmxhbmsiXQ=="),t("YVtocmVmKj0iZG9rdG9yLXNlLm9uZWxpbmsubWUiXQ=="),"article.category-samarbete",t("ZGl2LmhvbGlkQWRz"),"ul.adsmodern"],greekAdBlock:[t("QVtocmVmKj0iYWRtYW4ub3RlbmV0LmdyL2NsaWNrPyJd"),t("QVtocmVmKj0iaHR0cDovL2F4aWFiYW5uZXJzLmV4b2R1cy5nci8iXQ=="),t("QVtocmVmKj0iaHR0cDovL2ludGVyYWN0aXZlLmZvcnRobmV0LmdyL2NsaWNrPyJd"),"DIV.agores300","TABLE.advright"],hungarian:["#cemp_doboz",".optimonk-iframe-container",t("LmFkX19tYWlu"),t("W2NsYXNzKj0iR29vZ2xlQWRzIl0="),"#hirdetesek_box"],iDontCareAboutCookies:['.alert-info[data-block-track*="CookieNotice"]',".ModuleTemplateCookieIndicator",".o--cookies--container","#cookies-policy-sticky","#stickyCookieBar"],icelandicAbp:[t("QVtocmVmXj0iL2ZyYW1ld29yay9yZXNvdXJjZXMvZm9ybXMvYWRzLmFzcHgiXQ==")],latvian:[t("YVtocmVmPSJodHRwOi8vd3d3LnNhbGlkemluaS5sdi8iXVtzdHlsZT0iZGlzcGxheTogYmxvY2s7IHdpZHRoOiAxMjBweDsgaGVpZ2h0OiA0MHB4OyBvdmVyZmxvdzogaGlkZGVuOyBwb3NpdGlvbjogcmVsYXRpdmU7Il0="),t("YVtocmVmPSJodHRwOi8vd3d3LnNhbGlkemluaS5sdi8iXVtzdHlsZT0iZGlzcGxheTogYmxvY2s7IHdpZHRoOiA4OHB4OyBoZWlnaHQ6IDMxcHg7IG92ZXJmbG93OiBoaWRkZW47IHBvc2l0aW9uOiByZWxhdGl2ZTsiXQ==")],listKr:[t("YVtocmVmKj0iLy9hZC5wbGFuYnBsdXMuY28ua3IvIl0="),t("I2xpdmVyZUFkV3JhcHBlcg=="),t("YVtocmVmKj0iLy9hZHYuaW1hZHJlcC5jby5rci8iXQ=="),t("aW5zLmZhc3R2aWV3LWFk"),".revenue_unit_item.dable"],listeAr:[t("LmdlbWluaUxCMUFk"),".right-and-left-sponsers",t("YVtocmVmKj0iLmFmbGFtLmluZm8iXQ=="),t("YVtocmVmKj0iYm9vcmFxLm9yZyJd"),t("YVtocmVmKj0iZHViaXp6bGUuY29tL2FyLz91dG1fc291cmNlPSJd")],listeFr:[t("YVtocmVmXj0iaHR0cDovL3Byb21vLnZhZG9yLmNvbS8iXQ=="),t("I2FkY29udGFpbmVyX3JlY2hlcmNoZQ=="),t("YVtocmVmKj0id2Vib3JhbWEuZnIvZmNnaS1iaW4vIl0="),".site-pub-interstitiel",'div[id^="crt-"][data-criteo-id]'],officialPolish:["#ceneo-placeholder-ceneo-12",t("W2hyZWZePSJodHRwczovL2FmZi5zZW5kaHViLnBsLyJd"),t("YVtocmVmXj0iaHR0cDovL2Fkdm1hbmFnZXIudGVjaGZ1bi5wbC9yZWRpcmVjdC8iXQ=="),t("YVtocmVmXj0iaHR0cDovL3d3dy50cml6ZXIucGwvP3V0bV9zb3VyY2UiXQ=="),t("ZGl2I3NrYXBpZWNfYWQ=")],ro:[t("YVtocmVmXj0iLy9hZmZ0cmsuYWx0ZXgucm8vQ291bnRlci9DbGljayJd"),t("YVtocmVmXj0iaHR0cHM6Ly9ibGFja2ZyaWRheXNhbGVzLnJvL3Ryay9zaG9wLyJd"),t("YVtocmVmXj0iaHR0cHM6Ly9ldmVudC4ycGVyZm9ybWFudC5jb20vZXZlbnRzL2NsaWNrIl0="),t("YVtocmVmXj0iaHR0cHM6Ly9sLnByb2ZpdHNoYXJlLnJvLyJd"),'a[href^="/url/"]'],ruAd:[t("YVtocmVmKj0iLy9mZWJyYXJlLnJ1LyJd"),t("YVtocmVmKj0iLy91dGltZy5ydS8iXQ=="),t("YVtocmVmKj0iOi8vY2hpa2lkaWtpLnJ1Il0="),"#pgeldiz",".yandex-rtb-block"],thaiAds:["a[href*=macau-uta-popup]",t("I2Fkcy1nb29nbGUtbWlkZGxlX3JlY3RhbmdsZS1ncm91cA=="),t("LmFkczMwMHM="),".bumq",".img-kosana"],webAnnoyancesUltralist:["#mod-social-share-2","#social-tools",t("LmN0cGwtZnVsbGJhbm5lcg=="),".zergnet-recommend",".yt.btn-link.btn-md.btn"]}}function getDomBlockers$1(t){var e=t===void 0?{}:t,l=e.debug;return __awaiter$1(this,void 0,void 0,function(){var n,u,c,y,b,m;return __generator$1(this,function(O){switch(O.label){case 0:return isApplicable$1()?(n=getFilters$1(),u=Object.keys(n),c=(m=[]).concat.apply(m,u.map(function(N){return n[N]})),[4,getBlockedSelectors$1(c)]):[2,void 0];case 1:return y=O.sent(),l&&printDebug$1(n,y),b=u.filter(function(N){var L=n[N],G=countTruthy$1(L.map(function(q){return y[q]}));return G>L.length*.6}),b.sort(),[2,b]}})})}function isApplicable$1(){return isWebKit$1()||isAndroid$1()}function getBlockedSelectors$1(t){var e;return __awaiter$1(this,void 0,void 0,function(){var l,n,u,c,m,y,b,m;return __generator$1(this,function(O){switch(O.label){case 0:for(l=document,n=l.createElement("div"),u=new Array(t.length),c={},forceShow$1(n),m=0;m<t.length;++m)y=selectorToElement$1(t[m]),y.tagName==="DIALOG"&&y.show(),b=l.createElement("div"),forceShow$1(b),b.appendChild(y),n.appendChild(b),u[m]=y;O.label=1;case 1:return l.body?[3,3]:[4,wait$1(50)];case 2:return O.sent(),[3,1];case 3:return l.body.appendChild(n),[4,releaseEventLoop()];case 4:O.sent();try{for(m=0;m<t.length;++m)u[m].offsetParent||(c[t[m]]=!0)}finally{(e=n.parentNode)===null||e===void 0||e.removeChild(n)}return[2,c]}})})}function forceShow$1(t){t.style.setProperty("visibility","hidden","important"),t.style.setProperty("display","block","important")}function printDebug$1(t,e){for(var l="DOM blockers debug:\n```",n=0,u=Object.keys(t);n<u.length;n++){var c=u[n];l+=`
- `.concat(c,":");for(var y=0,b=t[c];y<b.length;y++){var m=b[y];l+=`
- `.concat(e[m]?"🚫":"➡️"," ").concat(m)}}console.log("".concat(l,"\n```"))}function getColorGamut$1(){for(var t=0,e=["rec2020","p3","srgb"];t<e.length;t++){var l=e[t];if(matchMedia("(color-gamut: ".concat(l,")")).matches)return l}}function areColorsInverted$1(){if(doesMatch$4$1("inverted"))return!0;if(doesMatch$4$1("none"))return!1}function doesMatch$4$1(t){return matchMedia("(inverted-colors: ".concat(t,")")).matches}function areColorsForced$1(){if(doesMatch$3$1("active"))return!0;if(doesMatch$3$1("none"))return!1}function doesMatch$3$1(t){return matchMedia("(forced-colors: ".concat(t,")")).matches}var maxValueToCheck$1=100;function getMonochromeDepth$1(){if(matchMedia("(min-monochrome: 0)").matches){for(var t=0;t<=maxValueToCheck$1;++t)if(matchMedia("(max-monochrome: ".concat(t,")")).matches)return t;throw new Error("Too high value")}}function getContrastPreference$1(){if(doesMatch$2$1("no-preference"))return 0;if(doesMatch$2$1("high")||doesMatch$2$1("more"))return 1;if(doesMatch$2$1("low")||doesMatch$2$1("less"))return-1;if(doesMatch$2$1("forced"))return 10}function doesMatch$2$1(t){return matchMedia("(prefers-contrast: ".concat(t,")")).matches}function isMotionReduced$1(){if(doesMatch$1$1("reduce"))return!0;if(doesMatch$1$1("no-preference"))return!1}function doesMatch$1$1(t){return matchMedia("(prefers-reduced-motion: ".concat(t,")")).matches}function isHDR$1(){if(doesMatch$5("high"))return!0;if(doesMatch$5("standard"))return!1}function doesMatch$5(t){return matchMedia("(dynamic-range: ".concat(t,")")).matches}var M$2=Math,fallbackFn$1=function t(){return 0};function getMathFingerprint$1(){var t=M$2.acos||fallbackFn$1,e=M$2.acosh||fallbackFn$1,l=M$2.asin||fallbackFn$1,n=M$2.asinh||fallbackFn$1,u=M$2.atanh||fallbackFn$1,c=M$2.atan||fallbackFn$1,y=M$2.sin||fallbackFn$1,b=M$2.sinh||fallbackFn$1,m=M$2.cos||fallbackFn$1,O=M$2.cosh||fallbackFn$1,N=M$2.tan||fallbackFn$1,L=M$2.tanh||fallbackFn$1,G=M$2.exp||fallbackFn$1,q=M$2.expm1||fallbackFn$1,J=M$2.log1p||fallbackFn$1,fe=function(ie){return M$2.pow(M$2.PI,ie)},ve=function(ie){return M$2.log(ie+M$2.sqrt(ie*ie-1))},ne=function(ie){return M$2.log(ie+M$2.sqrt(ie*ie+1))},Ue=function(ie){return M$2.log((1+ie)/(1-ie))/2},De=function(ie){return M$2.exp(ie)-1/M$2.exp(ie)/2},Ve=function(ie){return(M$2.exp(ie)+1/M$2.exp(ie))/2},rt=function(ie){return M$2.exp(ie)-1},Ae=function(ie){return(M$2.exp(2*ie)-1)/(M$2.exp(2*ie)+1)},Te=function(ie){return M$2.log(1+ie)};return{acos:t(.12312423423423424),acosh:e(1e308),acoshPf:ve(1e154),asin:l(.12312423423423424),asinh:n(1),asinhPf:ne(1),atanh:u(.5),atanhPf:Ue(.5),atan:c(.5),sin:y(-1e300),sinh:b(1),sinhPf:De(1),cos:m(10.000000000123),cosh:O(1),coshPf:Ve(1),tan:N(-1e300),tanh:L(1),tanhPf:Ae(1),exp:G(1),expm1:q(1),expm1Pf:rt(1),log1p:J(10),log1pPf:Te(10),powPI:fe(-100)}}var defaultText$1="mmMwWLliI0fiflO&1",presets$1={default:[],apple:[{font:"-apple-system-body"}],serif:[{fontFamily:"serif"}],sans:[{fontFamily:"sans-serif"}],mono:[{fontFamily:"monospace"}],min:[{fontSize:"1px"}],system:[{fontFamily:"system-ui"}]};function getFontPreferences$1(){return withNaturalFonts$1(function(t,e){for(var l={},n={},u=0,c=Object.keys(presets$1);u<c.length;u++){var y=c[u],b=presets$1[y],m=b[0],O=m===void 0?{}:m,N=b[1],L=N===void 0?defaultText$1:N,G=t.createElement("span");G.textContent=L,G.style.whiteSpace="nowrap";for(var q=0,J=Object.keys(O);q<J.length;q++){var fe=J[q],ve=O[fe];ve!==void 0&&(G.style[fe]=ve)}l[y]=G,e.appendChild(t.createElement("br")),e.appendChild(G)}for(var ne=0,Ue=Object.keys(presets$1);ne<Ue.length;ne++){var y=Ue[ne];n[y]=l[y].getBoundingClientRect().width}return n})}function withNaturalFonts$1(t,e){return e===void 0&&(e=4e3),withIframe$1(function(l,n){var u=n.document,c=u.body,y=c.style;y.width="".concat(e,"px"),y.webkitTextSizeAdjust=y.textSizeAdjust="none",isChromium$1()?c.style.zoom="".concat(1/n.devicePixelRatio):isWebKit$1()&&(c.style.zoom="reset");var b=u.createElement("div");return b.textContent=__spreadArray$1([],Array(e/20<<0)).map(function(){return"word"}).join(" "),c.appendChild(b),t(u,c)},'<!doctype html><html><head><meta name="viewport" content="width=device-width, initial-scale=1">')}function isPdfViewerEnabled$1(){return navigator.pdfViewerEnabled}function getArchitecture$1(){var t=new Float32Array(1),e=new Uint8Array(t.buffer);return t[0]=1/0,t[0]=t[0]-t[0],e[3]}function getApplePayState(){var t=window.ApplePaySession;if(typeof t?.canMakePayments!="function")return-1;try{return t.canMakePayments()?1:0}catch(e){return getStateFromError(e)}}function getStateFromError(t){if(t instanceof Error){if(t.name==="InvalidAccessError"){if(/\bfrom\b.*\binsecure\b/i.test(t.message))return-2;if(/\bdifferent\b.*\borigin\b.*top.level\b.*\bframe\b/i.test(t.message))return-3}if(t.name==="SecurityError"&&/\bthird.party iframes?.*\bnot.allowed\b/i.test(t.message))return-3}throw t}function getPrivateClickMeasurement(){var t,e=document.createElement("a"),l=(t=e.attributionSourceId)!==null&&t!==void 0?t:e.attributionsourceid;return l===void 0?void 0:String(l)}var STATUS_NO_GL_CONTEXT=-1,STATUS_GET_PARAMETER_NOT_A_FUNCTION=-2,validContextParameters=new Set([10752,2849,2884,2885,2886,2928,2929,2930,2931,2932,2960,2961,2962,2963,2964,2965,2966,2967,2968,2978,3024,3042,3088,3089,3106,3107,32773,32777,32777,32823,32824,32936,32937,32938,32939,32968,32969,32970,32971,3317,33170,3333,3379,3386,33901,33902,34016,34024,34076,3408,3410,3411,3412,3413,3414,3415,34467,34816,34817,34818,34819,34877,34921,34930,35660,35661,35724,35738,35739,36003,36004,36005,36347,36348,36349,37440,37441,37443,7936,7937,7938]),validExtensionParams=new Set([34047,35723,36063,34852,34853,34854,34229,36392,36795,38449]),shaderTypes=["FRAGMENT_SHADER","VERTEX_SHADER"],precisionTypes=["LOW_FLOAT","MEDIUM_FLOAT","HIGH_FLOAT","LOW_INT","MEDIUM_INT","HIGH_INT"],rendererInfoExtensionName="WEBGL_debug_renderer_info";function getWebGlBasics(t){var e,l,n,u,c,y,b=t.cache,m=getWebGLContext(b);if(!m)return STATUS_NO_GL_CONTEXT;if(!isValidParameterGetter(m))return STATUS_GET_PARAMETER_NOT_A_FUNCTION;var O=shouldAvoidDebugRendererInfo()?null:m.getExtension(rendererInfoExtensionName);return{version:((e=m.getParameter(m.VERSION))===null||e===void 0?void 0:e.toString())||"",vendor:((l=m.getParameter(m.VENDOR))===null||l===void 0?void 0:l.toString())||"",vendorUnmasked:O?(n=m.getParameter(O.UNMASKED_VENDOR_WEBGL))===null||n===void 0?void 0:n.toString():"",renderer:((u=m.getParameter(m.RENDERER))===null||u===void 0?void 0:u.toString())||"",rendererUnmasked:O?(c=m.getParameter(O.UNMASKED_RENDERER_WEBGL))===null||c===void 0?void 0:c.toString():"",shadingLanguageVersion:((y=m.getParameter(m.SHADING_LANGUAGE_VERSION))===null||y===void 0?void 0:y.toString())||""}}function getWebGlExtensions(t){var e=t.cache,l=getWebGLContext(e);if(!l)return STATUS_NO_GL_CONTEXT;if(!isValidParameterGetter(l))return STATUS_GET_PARAMETER_NOT_A_FUNCTION;var n=l.getSupportedExtensions(),u=l.getContextAttributes(),c=[],y=[],b=[],m=[];if(u)for(var O=0,N=Object.keys(u);O<N.length;O++){var L=N[O];c.push("".concat(L,"=").concat(u[L]))}for(var G=getConstantsFromPrototype(l),q=0,J=G;q<J.length;q++){var fe=J[q],ve=l[fe];y.push("".concat(fe,"=").concat(ve).concat(validContextParameters.has(ve)?"=".concat(l.getParameter(ve)):""))}if(n)for(var ne=0,Ue=n;ne<Ue.length;ne++){var De=Ue[ne];if(!(De===rendererInfoExtensionName&&shouldAvoidDebugRendererInfo())){var Ve=l.getExtension(De);if(Ve)for(var rt=0,Ae=getConstantsFromPrototype(Ve);rt<Ae.length;rt++){var fe=Ae[rt],ve=Ve[fe];b.push("".concat(fe,"=").concat(ve).concat(validExtensionParams.has(ve)?"=".concat(l.getParameter(ve)):""))}}}for(var Te=0,Xe=shaderTypes;Te<Xe.length;Te++)for(var ie=Xe[Te],ue=0,pt=precisionTypes;ue<pt.length;ue++){var mt=pt[ue],Tt=getShaderPrecision(l,ie,mt);m.push("".concat(ie,".").concat(mt,"=").concat(Tt.join(",")))}return b.sort(),y.sort(),{contextAttributes:c,parameters:y,shaderPrecisions:m,extensions:n,extensionParameters:b}}function getWebGLContext(t){if(t.webgl)return t.webgl.context;var e=document.createElement("canvas"),l;e.addEventListener("webglCreateContextError",function(){return l=void 0});for(var n=0,u=["webgl","experimental-webgl"];n<u.length;n++){var c=u[n];try{l=e.getContext(c)}catch{}if(l)break}return t.webgl={context:l},l}function getShaderPrecision(t,e,l){var n=t.getShaderPrecisionFormat(t[e],t[l]);return n?[n.rangeMin,n.rangeMax,n.precision]:[]}function getConstantsFromPrototype(t){var e=Object.keys(t.__proto__);return e.filter(isConstantLike)}function isConstantLike(t){return typeof t=="string"&&!t.match(/[^A-Z0-9_x]/)}function shouldAvoidDebugRendererInfo(){return isGecko$1()}function isValidParameterGetter(t){return typeof t.getParameter=="function"}var sources$1={fonts:getFonts$1,domBlockers:getDomBlockers$1,fontPreferences:getFontPreferences$1,audio:getAudioFingerprint$1,screenFrame:getScreenFrame$1,canvas:getCanvasFingerprint$1,osCpu:getOsCpu$1,languages:getLanguages$1,colorDepth:getColorDepth$1,deviceMemory:getDeviceMemory$1,screenResolution:getScreenResolution$1,hardwareConcurrency:getHardwareConcurrency$1,timezone:getTimezone$1,sessionStorage:getSessionStorage$1,localStorage:getLocalStorage$1,indexedDB:getIndexedDB$1,openDatabase:getOpenDatabase$1,cpuClass:getCpuClass$1,platform:getPlatform$2,plugins:getPlugins$1,touchSupport:getTouchSupport$1,vendor:getVendor$1,vendorFlavors:getVendorFlavors$1,cookiesEnabled:areCookiesEnabled$1,colorGamut:getColorGamut$1,invertedColors:areColorsInverted$1,forcedColors:areColorsForced$1,monochrome:getMonochromeDepth$1,contrast:getContrastPreference$1,reducedMotion:isMotionReduced$1,hdr:isHDR$1,math:getMathFingerprint$1,pdfViewerEnabled:isPdfViewerEnabled$1,architecture:getArchitecture$1,applePay:getApplePayState,privateClickMeasurement:getPrivateClickMeasurement,webGlBasics:getWebGlBasics,webGlExtensions:getWebGlExtensions};function loadBuiltinSources$1(t){return loadSources$1(sources$1,t,[])}var commentTemplate$1="$ if upgrade to Pro: https://fpjs.dev/pro";function getConfidence$1(t){var e=getOpenConfidenceScore$1(t),l=deriveProConfidenceScore$1(e);return{score:e,comment:commentTemplate$1.replace(/\$/g,"".concat(l))}}function getOpenConfidenceScore$1(t){if(isAndroid$1())return .4;if(isWebKit$1())return isDesktopWebKit()&&!(isWebKit616OrNewer()&&isSafariWebKit())?.5:.3;var e="value"in t.platform?t.platform.value:"";return/^Win/.test(e)?.6:/^Mac/.test(e)?.5:.7}function deriveProConfidenceScore$1(t){return round$1(.99+.01*t,1e-4)}function componentsToCanonicalString$1(t){for(var e="",l=0,n=Object.keys(t).sort();l<n.length;l++){var u=n[l],c=t[u],y="error"in c?"error":JSON.stringify(c.value);e+="".concat(e?"|":"").concat(u.replace(/([:|\\])/g,"\\$1"),":").concat(y)}return e}function componentsToDebugString$1(t){return JSON.stringify(t,function(e,l){return l instanceof Error?errorToObject$1(l):l},2)}function hashComponents$1(t){return x64hash128$1(componentsToCanonicalString$1(t))}function makeLazyGetResult$1(t){var e,l=getConfidence$1(t);return{get visitorId(){return e===void 0&&(e=hashComponents$1(this.components)),e},set visitorId(n){e=n},confidence:l,components:t,version:version$3}}function prepareForSources$1(t){return t===void 0&&(t=50),requestIdleCallbackIfAvailable$1(t,t*2)}function makeAgent$1(t,e){var l=Date.now();return{get:function(u){return __awaiter$1(this,void 0,void 0,function(){var c,y,b;return __generator$1(this,function(m){switch(m.label){case 0:return c=Date.now(),[4,t()];case 1:return y=m.sent(),b=makeLazyGetResult$1(y),(e||u?.debug)&&console.log("Copy the text below to get the debug data:\n\n```\nversion: ".concat(b.version,`
- userAgent: `).concat(navigator.userAgent,`
- timeBetweenLoadAndGet: `).concat(c-l,`
- visitorId: `).concat(b.visitorId,`
- components: `).concat(componentsToDebugString$1(y),"\n```")),[2,b]}})})}}}function monitor$1(){if(!(window.__fpjs_d_m||Math.random()>=.001))try{var t=new XMLHttpRequest;t.open("get","https://m1.openfpcdn.io/fingerprintjs/v".concat(version$3,"/npm-monitoring"),!0),t.send()}catch(e){console.error(e)}}function load$1(t){var e;return t===void 0&&(t={}),__awaiter$1(this,void 0,void 0,function(){var l,n,u;return __generator$1(this,function(c){switch(c.label){case 0:return(!((e=t.monitoring)!==null&&e!==void 0)||e)&&monitor$1(),l=t.delayFallback,n=t.debug,[4,prepareForSources$1(l)];case 1:return c.sent(),u=loadBuiltinSources$1({cache:{},debug:n}),[2,makeAgent$1(u,n)]}})})}var getCanvasId=function t(e){var l=null;if(typeof e=="string"&&e.length>0){if(l=document.querySelector(e),!l)return e.replace(/^#/,"")}else e instanceof HTMLCanvasElement&&(l=e);if(l)return l.id||(l.id=Math.random().toString(16).slice(2)),l.id},createMxDraw=function t(e,l,n,u,c){return new Promise(function(y,b){try{MxFun.createMxObject({canvasId:getCanvasId(e),isCPPMxCAD:!0,mapBox:n,callback:function(O){O.initRendererParam({webgl2:u!==!0}),O.setViewMovementMethod(l===void 0?!0:l),c&&c.callEvent("init_before_mxdraw",O),O.addEvent("initObject",function(){O.isWebgl2()?console.log("MxTip: use webgl2"):console.log("MxTip: use webgl1"),y(O)})}})}catch(m){b(m)}})},createMxCadCppObject=function t(e,l,n,u,c,y,b,m){var O=e.CreateMxDraw(l,n,u,c,y,b);return m?m.init(O):m=new McObject(O),O.McObject=m,O.McObject};function mx_getapi(){return _mx_getapi.apply(this,arguments)}function _mx_getapi(){return _mx_getapi=_asyncToGenerator(regenerator.mark(function t(){var e;return regenerator.wrap(function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,load$1();case 2:return e=n.sent,n.next=5,e.get();case 5:return n.abrupt("return",n.sent.visitorId);case 6:case"end":return n.stop()}},t)})),_mx_getapi.apply(this,arguments)}function Mx_About(){console.log(MxCpp.App.getVersionString()),mx_getapi().then(function(t){console.log("MxTip appid:",t)})}var createMxCad=function(){var t=_asyncToGenerator(regenerator.mark(function e(l,n){var u,c,y,b,m,O,N,L,G,q,J,fe,ve,ne,Ue,De,Ve,rt,Ae,Te,Xe,ie,ue,pt,mt,Tt,kt,It,nn,tn,pn,_n,Dn;return regenerator.wrap(function(Rn){for(;;)switch(Rn.prev=Rn.next){case 0:if(store.state.MxFun){Rn.next=3;break}return Rn.next=3,loadCoreCode();case 3:return u=l||{},c=u.openParameter,y=u.networkFonts,b=u.fontspath,m=u.locateFile,O=u.wasmBinary,N=u.canvas,L=u.onOpenFileComplete,G=u.fileUrl,q=u.onInit,J=u.middlePan,fe=u.registdata,ve=u.registfile,ne=u.authorized_service,Ue=u.viewBackgroundColor,De=u.map,Ve=u.multipleSelect,rt=u.enableUndo,Ae=u.mouseMiddlePan,Te=u.enableIntelliSelect,Xe=u.browse,ie=u.webgl1,Rn.next=6,loadMxCADassembly(function(){},m,O,b,y);case 6:return MxFun.initMxCpp(MxCpp),MxCADUtility.init(),MxFun.setIniset({EnableIntelliSelect:Te===void 0?!0:Te,IntelliSelectType:1}),rt!==void 0&&MxCpp.App.IniSet({EnableUndo:rt}),Ue&&MxCpp.App.setDefaultViewBackgroundColor(Ue.red,Ue.green,Ue.blue),q&&q(),n&&n.callEvent("init"),Rn.next=15,createMxDraw(N,J,De,ie,n);case 15:if(ue=Rn.sent,Ve!==void 0&&ue.setMultipleSelect(Ve),Ue&&ue.setViewColor(Ue.red<<16|Ue.green<<8|Ue.blue),n&&n.callEvent("init_mxdraw",ue),pt=MxFun.getMxFunTHREE(),mt=new pt.Vector2,ue.getRenderer().getSize(mt),Tt=createMxCadCppObject(MxCpp.App.getImp(),mt.width,mt.height,ue.getCanvas().id,ue.isWebgl2(),ue.getId(),!!De,n),kt=MxCpp.App.getImp().getCodeVersion(),!(kt!=1&&kt!=2)){Rn.next=35;break}if(!(fe&&fe.length>0)){Rn.next=29;break}Tt.initRegist(fe),Rn.next=35;break;case 29:return It=ve,ve&&ve.length>0||(It="mxkey.json.frontpage.json"),Rn.next=33,getJsonFromUrl(It);case 33:nn=Rn.sent,nn&&nn.registdata?(Tt.initRegist(nn.registdata),ne?Tt.iniAuthorizedService(ne):nn.authorized_service&&nn.authorized_service.length>0&&Tt.iniAuthorizedService(nn.authorized_service)):console.log("MxTip:empty regist data");case 35:if(kt!=3){Rn.next=48;break}if(tn=localStorage.getItem("_mx_tmp_id_"),!(!tn||tn.length==0)){Rn.next=47;break}return pn=window,pn.__fpjs_d_m=!0,Rn.next=42,load$1();case 42:return _n=Rn.sent,Rn.next=45,_n.get();case 45:tn=Rn.sent.visitorId,localStorage.setItem("_mx_tmp_id_",tn);case 47:MxCpp.App.getImp().addFontsLoadOnInitialization(tn,-121);case 48:return ue.initMxCpp(Tt),ue.addEvent("openFileComplete",function(){L&&L(Tt)}),n&&(Xe===!0&&(n.setBrowse(!0),Ae===void 0&&(Ae=0)),Ae!==void 0&&n.mxdraw.setMouseMiddlePan(Ae),n.callEvent("init_mxcad",Tt)),kt==3&&mx_getapi().then(function(Lt){Tt.getImp().SetAppId(Lt)}),G&&(Dn=0,c&&c&&(Dn=c),Tt.openWebFile(G,void 0,!0,c,Dn)),Rn.abrupt("return",Tt);case 54:case"end":return Rn.stop()}},e)}));return function(l,n){return t.apply(this,arguments)}}(),ColorMethod$1=function(t){return t[t.kByLayer=1]="kByLayer",t[t.kByBlock=2]="kByBlock",t[t.kByColor=3]="kByColor",t[t.kByACI=4]="kByACI",t[t.kByPen=5]="kByPen",t[t.kForeground=6]="kForeground",t[t.kLayerOff=7]="kLayerOff",t[t.kLayerFrozen=8]="kLayerFrozen",t[t.kNone=9]="kNone",t}(ColorMethod$1||{}),ColorIndexType=function(t){return t[t.kByblock=0]="kByblock",t[t.kRed=1]="kRed",t[t.kYellow=2]="kYellow",t[t.kGreen=3]="kGreen",t[t.KCyan=4]="KCyan",t[t.kBlue=5]="kBlue",t[t.kMagenta=6]="kMagenta",t[t.kWhite=7]="kWhite",t[t.kBylayer=256]="kBylayer",t}(ColorIndexType||{}),_colorUtils,getColorUtils=function t(){if(!_colorUtils){var e=MxFun.getMxFunTHREE();_colorUtils=new e.Color}for(var l=function(J){return _typeof$2(J[0])==="object"&&J[0].isColor},n=function(J){return typeof J[0]=="number"&&J.length===1},u=function(J){return typeof J[0]=="string"&&J.length===1},c=function(J){return J.length===3},y=arguments.length,b=new Array(y),m=0;m<y;m++)b[m]=arguments[m];if(c(b)){var O;(O=_colorUtils).setRGB.apply(O,b)}else if(l(b)){var N;(N=_colorUtils).set.apply(N,b)}else if(n(b)){var L;(L=_colorUtils).set.apply(L,b)}else if(u(b)){var G;(G=_colorUtils).set.apply(G,b)}return _colorUtils},setColorIndex=function t(e){var l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:MxCpp.App.mcedRGB2Index(e.red,e.green,e.blue,!1);l===-1?e.method=3:e.setColorIndex(l),l===7?e.method=4:l===0?e.method=2:l===256?e.method=1:l!==-1&&(e.method=4),e.colorIndex=l},createMcCmColor=function t(){for(var e=new McCmColor,l=arguments.length,n=new Array(l),u=0;u<l;u++)n[u]=arguments[u];return setMcCmColor.apply(void 0,[e].concat(n)),e},setMcCmColor=function t(e){for(var l=function(G){return G.length>1||_typeof$2(G[0])==="object"&&G[0].isColor||typeof G[0]=="string"||typeof G[0]=="number"},n=function(G){return _typeof$2(G[0])==="object"&&!(G[0]&&G[0].isColor)},u=arguments.length,c=new Array(u>1?u-1:0),y=1;y<u;y++)c[y-1]=arguments[y];if(l(c)){var b=getColorUtils.apply(void 0,c),m=b.r,O=b.g,N=b.b;e.red=m*255,e.green=O*255,e.blue=N*255}n(c)&&(e=Object.assign(e,c[0])),setColorIndex(e)};function drawText(){return _drawText.apply(this,arguments)}function _drawText(){return _drawText=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N,L,G,q,J,fe,ve;return regenerator.wrap(function(Ue){for(;;)switch(Ue.prev=Ue.next){case 0:return c=function(){var Ve=new McDbText;return Ve.height=e||100,Ve.textString=l||"",Ve.position=n||new McGePoint3d,Ve.trueColor=new McCmColor(MxCpp.getCurrentMxCAD().getCurrentDatabaseDrawColor()),Ve.rotation=u||0,Ve},y=new MxCADUiPrString,y.setMessage("输入文字内容"),Ue.next=5,y.go();case 5:if(b=Ue.sent,b){Ue.next=8;break}return Ue.abrupt("return");case 8:return l=b,m=new MxCADUiPrPoint,m.clearLastInputPoint(),m.setMessage("指定文字位置"),m.setUserDraw(function(De,Ve){n=De,Ve.drawMcDbEntity(c())}),Ue.next=15,m.go();case 15:if(O=Ue.sent,O){Ue.next=18;break}return Ue.abrupt("return");case 18:return n=O,N=new MxCADUiPrDist,N.setBasePt(n),N.setMessage(_ML_String("Mx_Text_Height","指定文字高度")),N.setUserDraw(function(De,Ve){n&&(e=De.distanceTo(n)),Ve.drawMcDbEntity(c())}),Ue.next=25,N.go();case 25:if(L=Ue.sent,L){Ue.next=28;break}return Ue.abrupt("return");case 28:return e=L,G=new MxCADUiPrAngle,G.setBasePt(n),G.clearLastInputPoint(),G.setMessage(_ML_String("Mx_Text_Angle","指定文字角度")),G.setUserDraw(function(De,Ve){n&&(u=angleTo(De.x,De.y,n.x,n.y)),Ve.drawMcDbEntity(c())}),Ue.next=36,G.go();case 36:return q=Ue.sent,q!==null&&G.getDetailedResult()===8&&(u=q),J=c(),fe=MxCpp.getCurrentMxCAD(),ve=fe.drawEntity(J),fe.updateDisplay(),Ue.abrupt("return",ve);case 43:case"end":return Ue.stop()}},t)})),_drawText.apply(this,arguments)}function _arrayWithHoles$1(t){if(Array.isArray(t))return t}function _iterableToArrayLimit$1(t,e){var l=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(l!=null){var n,u,c,y,b=[],m=!0,O=!1;try{if(c=(l=l.call(t)).next,e===0){if(Object(l)!==l)return;m=!1}else for(;!(m=(n=c.call(l)).done)&&(b.push(n.value),b.length!==e);m=!0);}catch(N){O=!0,u=N}finally{try{if(!m&&l.return!=null&&(y=l.return(),Object(y)!==y))return}finally{if(O)throw u}}return b}}function _arrayLikeToArray$1(t,e){(e==null||e>t.length)&&(e=t.length);for(var l=0,n=new Array(e);l<e;l++)n[l]=t[l];return n}function _unsupportedIterableToArray$1(t,e){if(t){if(typeof t=="string")return _arrayLikeToArray$1(t,e);var l=Object.prototype.toString.call(t).slice(8,-1);if(l==="Object"&&t.constructor&&(l=t.constructor.name),l==="Map"||l==="Set")return Array.from(t);if(l==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(l))return _arrayLikeToArray$1(t,e)}}function _nonIterableRest$1(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function _slicedToArray$1(t,e){return _arrayWithHoles$1(t)||_iterableToArrayLimit$1(t,e)||_unsupportedIterableToArray$1(t,e)||_nonIterableRest$1()}var threePointsToDetermineTheCenterOfTheCircle=function t(e){var l=_slicedToArray$1(e,3),n=l[0],u=l[1],c=l[2],y=n.x,b=n.y,m=n.z,O=u.x,N=u.y,L=u.z,G=c.x,q=c.y,J=c.z,fe=b*L-N*m-b*J+q*m+N*J-q*L,ve=-(y*L-O*m-y*J+G*m+O*J-G*L),ne=y*N-O*b-y*q+G*b+O*q-G*N,Ue=-(y*N*J-y*q*L-O*b*J+O*q*m+G*b*L-G*N*m),De=2*(O-y),Ve=2*(N-b),rt=2*(L-m),Ae=y*y+b*b+m*m-O*O-N*N-L*L,Te=2*(G-y),Xe=2*(q-b),ie=2*(J-m),ue=y*y+b*b+m*m-G*G-q*q-J*J,pt=-(ve*rt*ue-ve*ie*Ae-Ve*ne*ue+Ve*ie*Ue+Xe*ne*Ae-Xe*rt*Ue)/(fe*Ve*ie-fe*Xe*rt-De*ve*ie+De*Xe*ne+Te*ve*rt-Te*Ve*ne),mt=(fe*rt*ue-fe*ie*Ae-De*ne*ue+De*ie*Ue+Te*ne*Ae-Te*rt*Ue)/(fe*Ve*ie-fe*Xe*rt-De*ve*ie+De*Xe*ne+Te*ve*rt-Te*Ve*ne),Tt=-(fe*Ve*ue-fe*Xe*Ae-De*ve*ue+De*Xe*Ue+Te*ve*Ae-Te*Ve*Ue)/(fe*Ve*ie-fe*Xe*rt-De*ve*ie+De*Xe*ne+Te*ve*rt-Te*Ve*ne);return new McGePoint3d(pt,mt,Tt)};function drawCircle(){return _drawCircle.apply(this,arguments)}function _drawCircle(){return _drawCircle=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N,L,G,q,J,fe,ve,ne,Ue;return regenerator.wrap(function(Ve){for(;;)switch(Ve.prev=Ve.next){case 0:e=new MxCADUiPrPoint,l=new McDbCircle,n=MxCpp.getCurrentMxCAD().getCurrentDatabaseDrawColor(),l.trueColor=new McCmColor(n);case 4:if(typeof u>"u"&&(e.setKeyWords("[三点(3P)/两点(2P)]"),u="default"),u!=="default"){Ve.next=49;break}if(y){Ve.next=21;break}return e.setMessage(`
- 指定圆的圆心`),Ve.next=11,e.go();case 11:if(q=Ve.sent,!e.isKeyWordPicked("3P")){Ve.next=15;break}return u="3P",Ve.abrupt("continue",4);case 15:if(!e.isKeyWordPicked("2P")){Ve.next=18;break}return u="2P",Ve.abrupt("continue",4);case 18:if(q){Ve.next=20;break}return Ve.abrupt("return");case 20:y=q;case 21:if(b){Ve.next=46;break}return J=new MxCADUiPrDist,J.setBasePt(y),typeof c>"u"&&(J.setKeyWords("[直径(D)]"),c=!0),J.setMessage(_ML_String("McDbCircle_Radius","指定圆的"+(c?"半径":"直径"))),J.setUserDraw(function(rt,Ae){if(y){var Te=new McDbCircle(y.x,y.y,y.z,c?y.distanceTo(rt):y.distanceTo(rt)/2);Ae.drawMcDbEntity(Te),Ae.drawLine(Te.center.toVector3(),rt.toVector3())}}),Ve.next=29,J.go();case 29:if(fe=Ve.sent,!J.isKeyWordPicked("D")){Ve.next=42;break}return c=!1,J.clearLastInputPoint(),J.setBasePt(y),J.setMessage(_ML_String("McDbCircle_Diameter","指定圆的直径")),J.setKeyWords(""),Ve.next=38,J.go();case 38:if(ve=Ve.sent,ve){Ve.next=41;break}return Ve.abrupt("return");case 41:b=ve/2;case 42:if(b){Ve.next=46;break}if(fe){Ve.next=45;break}return Ve.abrupt("return");case 45:b=fe;case 46:return l.center=y,l.radius=b,Ve.abrupt("return",MxCpp.getCurrentMxCAD().drawEntity(l,!0));case 49:if(u!=="3P"){Ve.next=79;break}if(m){Ve.next=58;break}return e.setMessage("指定圆上的第一个点"),e.setKeyWords(""),Ve.next=55,e.go();case 55:if(m=Ve.sent,m){Ve.next=58;break}return Ve.abrupt("return");case 58:if(O){Ve.next=67;break}return e.setMessage("指定圆上的第二个点"),e.setKeyWords(""),e.setUserDraw(function(rt,Ae){m&&Ae.drawLine(m.toVector3(),rt.toVector3())}),Ve.next=64,e.go();case 64:if(O=Ve.sent,O){Ve.next=67;break}return Ve.abrupt("return");case 67:if(N){Ve.next=76;break}return e.setMessage("指定圆上的第三个点"),e.setKeyWords(""),e.setUserDraw(function(rt,Ae){if(m&&O){var Te=threePointsToDetermineTheCenterOfTheCircle([m,O,rt]);if(Te){var Xe=new McDbCircle(Te.x,Te.y,Te.z,Te.distanceTo(m));Ae.drawMcDbEntity(Xe)}}}),Ve.next=73,e.go();case 73:if(N=Ve.sent,N){Ve.next=76;break}return Ve.abrupt("return");case 76:return ne=threePointsToDetermineTheCenterOfTheCircle([m,O,N]),Ue=new McDbCircle(ne.x,ne.y,ne.z,ne.distanceTo(m)),Ve.abrupt("return",MxCpp.getCurrentMxCAD().drawEntity(Ue,!0));case 79:if(u!=="2P"){Ve.next=100;break}if(L){Ve.next=88;break}return e.setMessage("指定圆直径的第一个端点"),e.setKeyWords(""),Ve.next=85,e.go();case 85:if(L=Ve.sent,L){Ve.next=88;break}return Ve.abrupt("return");case 88:if(G){Ve.next=97;break}return e.setMessage("指定圆直径的第二个端点"),e.setKeyWords(""),e.setUserDraw(function(rt,Ae){L&&(y=new McGePoint3d((rt.x+L.x)/2,(rt.y+L.y)/2,(rt.z+L.z)/2),b=y.distanceTo(L),Ae.drawMcDbEntity(new McDbCircle(y.x,y.y,y.z,b)))}),Ve.next=94,e.go();case 94:if(G=Ve.sent,G){Ve.next=97;break}return Ve.abrupt("return");case 97:return y=new McGePoint3d((G.x+L.x)/2,(G.y+L.y)/2,(G.z+L.z)/2),b=y.distanceTo(L),Ve.abrupt("return",MxCpp.getCurrentMxCAD().drawEntity(new McDbCircle(y.x,y.y,y.z,b),!0));case 100:Ve.next=4;break;case 103:case"end":return Ve.stop()}},t)})),_drawCircle.apply(this,arguments)}MxFun.on("init",function(){MxFun.addCommand("Mx_Circle",drawCircle)});function drawLine(){return _drawLine.apply(this,arguments)}function _drawLine(){return _drawLine=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N;return regenerator.wrap(function(G){for(;;)switch(G.prev=G.next){case 0:return e=new MxCADUiPrPoint,e.setMessage(`
- 指定第一点:`),G.next=4,e.go();case 4:if(l=G.sent,n=l,l){G.next=8;break}return G.abrupt("return");case 8:e.setMessage(`
- 指定下一个点:`),u=0,c=[];case 11:return u>=2?e.setKeyWords("[退出(E)/闭合(C)/放弃(U)]"):u>0?e.setKeyWords("[退出(E)/放弃(U)]"):e.setKeyWords(""),e.setBasePt(l),G.next=16,e.go();case 16:if(y=G.sent,!e.isKeyWordPicked("C")){G.next=23;break}return b=new McDbLine(n,l),MxCpp.getCurrentMxCAD().drawEntity(b),G.abrupt("return");case 23:if(!e.isKeyWordPicked("E")){G.next=27;break}return G.abrupt("return");case 27:if(!e.isKeyWordPicked("U")){G.next=36;break}if(c.length!=0){G.next=30;break}return G.abrupt("continue",11);case 30:return m=c[c.length-1],c.pop(),u--,l=m.prvPoint,m.id.erase(),G.abrupt("continue",11);case 36:if(y){G.next=38;break}return G.abrupt("return");case 38:O=new McDbLine(l,y),u++,N=MxCpp.getCurrentMxCAD().drawEntity(O),c.push({id:N,prvPoint:l}),l=y,G.next=11;break;case 45:case"end":return G.stop()}},t)})),_drawLine.apply(this,arguments)}function Mx_Point(){return _Mx_Point.apply(this,arguments)}function _Mx_Point(){return _Mx_Point=_asyncToGenerator(regenerator.mark(function t(){var e,l;return regenerator.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:e=new MxCADUiPrPoint,e.setMessage("指定点");case 2:return e.clearLastInputPoint(),u.next=6,e.go();case 6:if(l=u.sent,l!=null){u.next=9;break}return u.abrupt("break",12);case 9:MxCpp.getCurrentMxCAD().drawEntity(new McDbPoint(l)),u.next=2;break;case 12:case"end":return u.stop()}},t)})),_Mx_Point.apply(this,arguments)}MxFun.on("init",function(){MxFun.addCommand("Mx_Line",drawLine),MxFun.addCommand("Mx_Point",Mx_Point),MxFun.addCommand("Mx_About",Mx_About)});function drawMText(){return _drawMText.apply(this,arguments)}function _drawMText(){return _drawMText=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N,L,G,q,J,fe,ve;return regenerator.wrap(function(Ue){for(;;)switch(Ue.prev=Ue.next){case 0:return c=function(){var Ve=new McDbMText;return Ve.textHeight=e||100,Ve.contents=l||"",Ve.location=n||new McGePoint3d,Ve.trueColor=new McCmColor(MxCpp.getCurrentMxCAD().getCurrentDatabaseDrawColor()),Ve.rotation=u||0,Ve},y=new MxCADUiPrString,y.setMessage("输入文字内容"),Ue.next=5,y.go();case 5:if(b=Ue.sent,b){Ue.next=8;break}return Ue.abrupt("return");case 8:return l=b,m=new MxCADUiPrPoint,m.clearLastInputPoint(),m.setMessage("指定文字位置"),m.setUserDraw(function(De,Ve){n=De,Ve.drawMcDbEntity(c())}),Ue.next=15,m.go();case 15:if(O=Ue.sent,O){Ue.next=18;break}return Ue.abrupt("return");case 18:return n=O,N=new MxCADUiPrDist,N.setBasePt(n),N.setMessage(_ML_String("Mx_Text_Height","指定文字高度")),N.setUserDraw(function(De,Ve){n&&(e=De.distanceTo(n)),Ve.drawMcDbEntity(c())}),Ue.next=25,N.go();case 25:if(L=Ue.sent,L){Ue.next=28;break}return Ue.abrupt("return");case 28:return e=L,G=new MxCADUiPrAngle,G.setBasePt(n),G.clearLastInputPoint(),G.setMessage(_ML_String("Mx_MText_Angle","指定文字角度")),G.setUserDraw(function(De,Ve){n&&(u=angleTo(De.x,De.y,n.x,n.y)),Ve.drawMcDbEntity(c())}),Ue.next=36,G.go();case 36:return q=Ue.sent,q!==null&&G.getDetailedResult()===8&&(u=q),J=c(),fe=MxCpp.getCurrentMxCAD(),ve=fe.drawEntity(J),fe.updateDisplay(),Ue.abrupt("return",ve);case 43:case"end":return Ue.stop()}},t)})),_drawMText.apply(this,arguments)}function CMxDrawPolylineDragArcDraw_CalcArcBulge(t,e,l){if(t.isEqualTo(e))return 0;var n=t.c().addvec(e.c().sub(t).mult(.5)),u=e.c().sub(t);u.rotateBy(Math.PI/2,McGeVector3d.kZAxis);var c=new McDbLine(n,n.c().addvec(u)),y=l.c();y.rotateBy(Math.PI/2,McGeVector3d.kZAxis);var b=new McDbLine(t,t.c().addvec(y)),m=c.IntersectWith(b,McDb.Intersect.kExtendBoth);if(m.isEmpty())return 0;var O=m.at(0),N=O.distanceTo(t);u.normalize(),u.mult(N);var L=O.c().addvec(u),G=O.c().subvec(u),q=L.c().sub(t),J=G.c().sub(t),fe=L;return q.angleTo1(l)>J.angleTo1(l)&&(fe=G),MxCADUtility.calcBulge(t,fe,e).val}function drawPolyLine(){return _drawPolyLine.apply(this,arguments)}function _drawPolyLine(){return _drawPolyLine=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N,L,G,q,J,fe,ve,ne,Ue,De,Ve;return regenerator.wrap(function(Ae){for(;;)switch(Ae.prev=Ae.next){case 0:return e=new MxCADUiPrPoint,e.setMessage(`
- 指定起点:`),Ae.next=4,e.go();case 4:if(l=Ae.sent,l!==null){Ae.next=7;break}return Ae.abrupt("return");case 7:n=[],u=0,c={},c.dStartWidth=u,c.dEndWidth=u,c.pt=l,c.dBulge=0,n.push(c),y=!1,b=!0,m=!1,O=u,N=u,L=[],G=MxCpp.getCurrentMxCAD(),MxFun.acutPrintf(`
- 当前线宽为 {0}`,u+""),q=!1,J=function(Xe){Xe.key==="Control"&&(q=!0)},fe=function(){return q=!1},window.addEventListener("keydown",J),window.addEventListener("keyup",fe),ve=regenerator.mark(function Te(){var Xe,ie,ue,pt,mt,Tt,kt,It,nn,tn,pn,_n,Dn,an,Rn,Lt,wn,hn,xn,$n,Xr,ti,gn,Xn,Kn,Vn,Yn,Vr,xi,Si,qn,ia,Wi,ha,ai,Ia,fi,An,sa,Nn,fn,un,Ln,hr,hi,bi,Ra,so,Pi,oi,Ni,za,ki,Aa,Ja,yo,ls,xo,_o,Ao,il,zr,zn,Un,Gr,ni,Ei,$t,ta,Hi,Ai,Ea,wo,to,zo,Po,Lo,Wo,ma,$s,ao,Ps,qo,wl,yu,po,Zs,Es,Xl,xl,jo,ju,Pl,tl,zl,Is,al,Mn,Ur,Gn,Qr,qi,ga,no,mo,Go,Uo,Ns,jl,Bl,Jl,mu,Ol,bu,Bu,hl,vu,Ku,Ul,ad,jc,js,co,Vl,Gc,yd,Ql,Ll,Au,jd,Wu,ud,Xc,yi,mc,Su;return regenerator.wrap(function(ka){for(;;)switch(ka.prev=ka.next){case 0:if(!b){ka.next=107;break}return Xe=_ML_String("ID_ARX_PL2","指定下一个点:"),ie="[圆弧(A)/宽度(W)/长度(L)/半宽(H)]",n.length>=3?m?ie="[回退(U)/圆弧(A)/宽度(W)/长度(L)/半宽(H)]":ie="[回退(U)/圆弧(A)/宽度(W)/长度(L)/半宽(H)/闭合(C)]":n.length>=2&&(ie="[回退(U)/圆弧(A)/宽度(W)/半宽(H)/长度(L)]"),ue=new MxCADUiPrPoint,ue.setMessage(Xe),ue.setKeyWords(ie),pt=n[n.length-1],ue.setUserDraw(function(pl,Il){var Ss=new McDbPolyline;Ss.addVertexAt(pt.pt,pt.dBulge,pt.dStartWidth,pt.dEndWidth),Ss.addVertexAt(pl),Il.drawMcDbEntity(Ss)}),ka.next=11,ue.go();case 11:if(mt=ka.sent,mt===null){ka.next=22;break}Tt={},Tt.dStartWidth=O,Tt.dEndWidth=N,Tt.pt=mt,Tt.dBulge=0,n.push(Tt),n.length>=2&&(kt=new McDbPolyline,kt.addVertexAt(n[n.length-2].pt,0,n[n.length-2].dStartWidth,n[n.length-2].dEndWidth),kt.addVertexAt(n[n.length-1].pt),L.push(G.drawEntity(kt))),ka.next=105;break;case 22:if(ue.getStatus()!=MrxDbgUiPrBaseReturn$1.kKeyWord){ka.next=104;break}if(!ue.isKeyWordPicked("A")){ka.next=27;break}b=!1,ka.next=102;break;case 27:if(!ue.isKeyWordPicked("W")){ka.next=49;break}return It=new MxCADUiPrDist,It.setMessage(_ML_String("ID_ARX_PLGETSTARTWIDTH","指定起点宽度")),ka.next=32,It.go();case 32:if(nn=ka.sent,nn!==null){ka.next=35;break}return ka.abrupt("return",0);case 35:return O=It.value(),It.setMessage(_ML_String("ID_ARX_PLGETVERITXWIDTH","指定端点宽度")),ka.next=39,It.go();case 39:if(nn=ka.sent,nn!==null){ka.next=42;break}return ka.abrupt("return",0);case 42:N=It.value(),u=N,n[n.length-1].dStartWidth=O,n[n.length-1].dEndWidth=N,O=N,ka.next=102;break;case 49:if(!ue.isKeyWordPicked("H")){ka.next=71;break}return tn=new MxCADUiPrDist,tn.setMessage(_ML_String("ID_ARX_PLGETSTARTWIDTH","指定起点半宽")),ka.next=54,tn.go();case 54:if(pn=ka.sent,pn!==null){ka.next=57;break}return ka.abrupt("return",0);case 57:return O=tn.value()*2,tn.setMessage(_ML_String("ID_ARX_PLGETVERITXWIDTH","指定端点半宽")),ka.next=61,tn.go();case 61:if(pn=ka.sent,pn!==null){ka.next=64;break}return ka.abrupt("return",0);case 64:N=tn.value()*2,u=N,n[n.length-1].dStartWidth=O,n[n.length-1].dEndWidth=N,O=N,ka.next=102;break;case 71:if(!ue.isKeyWordPicked("C")){ka.next=76;break}return y=!0,ka.abrupt("return",0);case 76:if(!ue.isKeyWordPicked("U")){ka.next=80;break}n.length>1&&(n.pop(),L[L.length-1].erase(),L.pop(),n.length>0&&ue.setLastInputPoint(n[n.length-1].pt)),ka.next=102;break;case 80:if(!ue.isKeyWordPicked("L")){ka.next=102;break}return Dn=McGeVector3d.kXAxis,ue.setMessage("指定直线长度"),ue.setKeyWords(""),ka.next=86,ue.go();case 86:if(Rn=ka.sent,Rn){ka.next=89;break}return ka.abrupt("return",{v:void 0});case 89:Lt=n[n.length-1].pt,wn=Rn.distanceTo(Lt),hn=(_n=n[n.length-2])===null||_n===void 0?void 0:_n.pt,hn&&(Dn=hn.sub(Lt)),an=Lt.clone().addvec(Dn.normalize().mult(-wn)),xn={},xn.dStartWidth=O,xn.dEndWidth=N,xn.pt=an,xn.dBulge=0,n.push(xn),ue.setLastInputPoint(an),n.length>=2&&($n=new McDbPolyline,$n.addVertexAt(n[n.length-2].pt,0,n[n.length-2].dStartWidth,n[n.length-2].dEndWidth),$n.addVertexAt(n[n.length-1].pt),L.push(G.drawEntity($n)));case 102:ka.next=105;break;case 104:return ka.abrupt("return",0);case 105:ka.next=495;break;case 107:return Xr=_ML_String("NO1_ID_ARX_PL5","指定圆弧的端点(按住 Ctrl 键以切换方向)"),ti="[角度(A)/第二个点(S)/圆心(CE)/方向(D)/直线(L)/半径(R)/宽度(W)/半宽(H)]",n.length>=3?m?ti="[角度(A)/第二个点(S)/圆心(CE)/方向(D)/回退(U)/直线(L)/半径(R)/宽度(W)/半宽(H)]":ti="[角度(A)/第二个点(S)/圆心(CE)/方向(D)/回退(U)/直线(L)/半径(R)/宽度(W)/半宽(H)/闭合(C)]":n.length>=2&&(ti="[角度(A)/第二个点(S)/圆心(CE)/方向(D)/回退(U)/直线(L)/半径(R)/宽度(W)/半宽(H)]"),gn=new MxCADUiPrPoint,gn.setMessage(Xr),gn.setKeyWords(ti),Xn=new McGeVector3d,n.length<2?Xn.copy(McGeVector3d.kXAxis):(Kn=n.length,Vn=n[Kn-2].pt,Yn=n[Kn-2].dBulge,Vr=n[Kn-1].pt,IsZero(Yn)?Xn=new McGePoint3d(Vr.x,Vr.y,0).sub(new McGePoint3d(Vn.x,Vn.y,0)):(xi=new McDbPolyline,xi.addVertexAt(Vn,Yn),xi.addVertexAt(Vr),Si=xi.getFirstDeriv(new McGePoint3d(Vr.x,Vr.y,0)),Si.ret?Xn=Si.val:Xn.copy(McGeVector3d.kXAxis))),qn=n[n.length-1],gn.setUserDraw(function(pl,Il){var Ss=CMxDrawPolylineDragArcDraw_CalcArcBulge(qn.pt,pl,q?Xn.clone().negate():Xn),Vo=new McDbPolyline;Vo.addVertexAt(qn.pt,Ss,qn.dStartWidth,qn.dEndWidth),Vo.addVertexAt(pl),Il.drawMcDbEntity(Vo)}),ka.next=119,gn.go();case 119:if(ia=ka.sent,ia===null){ka.next=132;break}Wi={},Wi.dStartWidth=O,Wi.dEndWidth=N,Wi.dBulge=0,Wi.pt=ia,n[n.length-1].dBulge=CMxDrawPolylineDragArcDraw_CalcArcBulge(qn.pt,Wi.pt,q?Xn.clone().negate():Xn),n.push(Wi),ha=n.length,ha>=2&&(ai=new McDbPolyline,ai.addVertexAt(n[ha-2].pt,n[ha-2].dBulge,n[ha-2].dStartWidth,n[ha-2].dEndWidth),ai.addVertexAt(n[ha-1].pt),L.push(G.drawEntity(ai))),ka.next=495;break;case 132:if(gn.getStatus()!=MrxDbgUiPrBaseReturn$1.kKeyWord){ka.next=494;break}if(!gn.isKeyWordPicked("A")){ka.next=215;break}return Ia=new MxCADUiPrAngle,Ia.setBasePt(qn.pt),Ia.setMessage(_ML_String("ID_ARX_PLGET_I_ANGLE","指定夹角")),ka.next=139,Ia.go();case 139:if(fi=ka.sent,fi!==null){ka.next=142;break}return ka.abrupt("return",0);case 142:return gn.setMessage("指定圆弧的端点(按住 Ctrl 键以切换方向)"),gn.setKeyWords("[圆心(CE)/半径(R)]"),gn.setLastInputPoint(qn.pt),An=n[n.length-1].pt,sa=function(Il){var Ss=Math.PI/2-fi/2,Vo=new McGePoint3d((Il.x+An.x)/2,(Il.y+An.y)/2),iu=Vo.distanceTo(An),Tu=iu/Math.sin(Ss),wt=iu/Math.tan(Ss),qt=Vo.sub(An).rotateBy(Math.PI/2).normalize().mult(q?-Tu-wt:Tu-wt),Cn=Vo.addvec(qt);return MxCADUtility.calcBulge(An,Cn,Il).val},gn.setUserDraw(function(pl,Il){var Ss=sa(pl),Vo=new McDbPolyline;Vo.addVertexAt(qn.pt,Ss,qn.dStartWidth,qn.dEndWidth),Vo.addVertexAt(pl),Il.drawMcDbEntity(Vo)}),ka.next=150,gn.go();case 150:if(Nn=ka.sent,!gn.isKeyWordPicked("CE")){ka.next=174;break}return gn.setMessage("指定圆弧的圆心"),gn.setKeyWords(""),gn.setBasePt(An),gn.setUserDraw(function(pl,Il){var Ss=pl.distanceTo(An),Vo=pl.addvec(pl.sub(An).rotateBy(fi).normalize().mult(Ss)),iu=sa(Vo),Tu=new McDbPolyline;Tu.addVertexAt(qn.pt,iu,qn.dStartWidth,qn.dEndWidth),Tu.addVertexAt(Vo),Il.drawMcDbEntity(Tu)}),ka.next=158,gn.go();case 158:if(fn=ka.sent,fn){ka.next=161;break}return ka.abrupt("return",0);case 161:return un=fn.distanceTo(An),Ln=fn.addvec(fn.sub(An).rotateBy(fi).normalize().mult(un)),hr={},hr.dStartWidth=O,hr.dEndWidth=N,hr.dBulge=0,hr.pt=Ln,n[n.length-1].dBulge=sa(Ln),n.push(hr),hi=n.length,hi>=2&&(bi=new McDbPolyline,bi.addVertexAt(n[hi-2].pt,n[hi-2].dBulge,n[hi-2].dStartWidth,n[hi-2].dEndWidth),bi.addVertexAt(n[hi-1].pt),L.push(G.drawEntity(bi))),gn.setLastInputPoint(Ln),ka.abrupt("return",1);case 174:if(!gn.isKeyWordPicked("R")){ka.next=204;break}return Ra=new MxCADUiPrDist,Ra.setMessage("指定圆弧半径"),Ra.setKeyWords(""),ka.next=180,Ra.go();case 180:if(so=ka.sent,typeof so=="number"){ka.next=183;break}return ka.abrupt("return",0);case 183:return Pi=so*Math.sin(fi/2),gn.setBasePt(An),gn.setMessage("指定圆弧的弦方向(按住Ctrl键切换方向)"),gn.setKeyWords(""),gn.setUserDraw(function(pl,Il){var Ss=An.clone().addvec(pl.sub(An).normalize().mult(Pi*2)),Vo=sa(Ss),iu=new McDbPolyline;iu.addVertexAt(qn.pt,Vo,qn.dStartWidth,qn.dEndWidth),iu.addVertexAt(Ss),Il.drawMcDbEntity(iu)}),ka.next=190,gn.go();case 190:if(oi=ka.sent,oi){ka.next=193;break}return ka.abrupt("return",0);case 193:return Ni=An.clone().addvec(oi.sub(An).normalize().mult(Pi*2)),za={},za.dStartWidth=O,za.dEndWidth=N,za.dBulge=0,za.pt=Ni,n[n.length-1].dBulge=sa(Ni),n.push(za),ki=n.length,ki>=2&&(Aa=new McDbPolyline,Aa.addVertexAt(n[ki-2].pt,n[ki-2].dBulge,n[ki-2].dStartWidth,n[ki-2].dEndWidth),Aa.addVertexAt(n[ki-1].pt),L.push(G.drawEntity(Aa))),ka.abrupt("return",1);case 204:if(Nn){ka.next=206;break}return ka.abrupt("return",0);case 206:Ja={},Ja.dStartWidth=O,Ja.dEndWidth=N,Ja.dBulge=0,Ja.pt=Nn,n[n.length-1].dBulge=sa(Nn),n.push(Ja),yo=n.length,yo>=2&&(ls=new McDbPolyline,ls.addVertexAt(n[yo-2].pt,n[yo-2].dBulge,n[yo-2].dStartWidth,n[yo-2].dEndWidth),ls.addVertexAt(n[yo-1].pt),L.push(G.drawEntity(ls)));case 215:if(!gn.isKeyWordPicked("CE")){ka.next=311;break}return gn.setMessage("指定圆弧的圆心"),gn.setKeyWords(""),gn.setUserDraw(function(){}),ka.next=221,gn.go();case 221:if(xo=ka.sent,xo){ka.next=224;break}return ka.abrupt("return",{v:void 0});case 224:return _o=qn.pt,Ao=xo.distanceTo(_o),gn.setLastInputPoint(_o),gn.setMessage("指定圆弧的端点(按住 Ctrl 键以切换方向)"),gn.setKeyWords("[角度(A)/长度(L)]"),gn.clearLastInputPoint(),gn.setUserDraw(function(pl,Il){Il.drawLine(pl.toVector3(),xo.toVector3());var Ss=xo.clone().addvec(pl.sub(xo).normalize().mult(Ao)),Vo=xo.sub(_o).angleTo2(xo.sub(Ss),McGeVector3d.kZAxis),iu=new McGePoint3d((_o.x+Ss.x)/2,(_o.y+Ss.y)/2),Tu=xo.sub(iu).normalize().mult(-Ao),wt=xo.clone().addvec((q?Vo<Math.PI:Vo>Math.PI)?Tu.negate():Tu),qt=MxCADUtility.calcBulge(_o,wt,Ss).val,Cn=new McDbPolyline;Cn.addVertexAt(qn.pt,qt,qn.dStartWidth,qn.dEndWidth),Cn.addVertexAt(Ss),Il.drawMcDbEntity(Cn)}),ka.next=233,gn.go();case 233:if(il=ka.sent,!gn.isKeyWordPicked("A")){ka.next=261;break}return zr=new MxCADUiPrAngle,zr.setBasePt(xo),zr.setMessage(_ML_String("ID_ARX_PLGET_I_ANGLE","指定夹角(按住 Ctrl 键以切换方向")),zr.setKeyWords(""),zr.setUserDraw(function(pl,Il){var Ss=McGeVector3d.kXAxis.clone().angleTo2(pl.sub(xo),McGeVector3d.kZAxis),Vo=q?Math.PI*2-Ss/2:Ss/2,iu=_o.sub(xo).rotateBy(Vo).normalize().mult(Ao),Tu=_o.sub(xo).rotateBy(Ss).normalize().mult(Ao),wt=xo.clone().addvec(iu),qt=xo.clone().addvec(Tu),Cn=MxCADUtility.calcBulge(_o,wt,qt).val,Pn=new McDbPolyline;Pn.addVertexAt(qn.pt,Cn,qn.dStartWidth,qn.dEndWidth),Pn.addVertexAt(qt),Il.drawMcDbEntity(Pn)}),ka.next=242,zr.go();case 242:if(zn=ka.sent,zn!==null){ka.next=245;break}return ka.abrupt("return",0);case 245:return Un=q?Math.PI*2-zn/2:zn/2,Gr=_o.sub(xo).rotateBy(Un).normalize().mult(Ao),ni=_o.sub(xo).rotateBy(zn).normalize().mult(Ao),Ei=xo.clone().addvec(Gr),$t=xo.clone().addvec(ni),ta=MxCADUtility.calcBulge(_o,Ei,$t).val,Hi={},Hi.dStartWidth=O,Hi.dEndWidth=N,Hi.dBulge=0,Hi.pt=$t,n[n.length-1].dBulge=ta,n.push(Hi),Ai=n.length,Ai>=2&&(Ea=new McDbPolyline,Ea.addVertexAt(n[Ai-2].pt,n[Ai-2].dBulge,n[Ai-2].dStartWidth,n[Ai-2].dEndWidth),Ea.addVertexAt(n[Ai-1].pt),L.push(G.drawEntity(Ea))),ka.abrupt("return",1);case 261:if(!gn.isKeyWordPicked("L")){ka.next=292;break}return wo=new MxCADUiPrDist,wo.setMessage("指定弦长(按住 Ctrl 键以切换方向)"),wo.setKeyWords(""),wo.setBasePt(_o),wo.setUserDraw(function(pl,Il){var Ss=pl.distanceTo(_o);if(!(Ss>Ao*2)){var Vo=Math.asin(Ss/2/Ao)*2,iu=_o.sub(xo).normalize().mult(Ao),Tu=xo.clone().addvec(iu.clone().rotateBy(q?Math.PI-Vo/2:Vo/2)),wt=xo.clone().addvec(iu.clone().rotateBy(Vo)),qt=MxCADUtility.calcBulge(_o,Tu,wt).val,Cn=new McDbPolyline;Cn.addVertexAt(qn.pt,qt,qn.dStartWidth,qn.dEndWidth),Cn.addVertexAt(wt),Il.drawMcDbEntity(Cn)}}),ka.next=269,wo.go();case 269:if(to=ka.sent,typeof to=="number"){ka.next=272;break}return ka.abrupt("return",0);case 272:if(!(to>Ao*2)){ka.next=276;break}return MxFun.acutPrintf("*弦长不能大于直径 无效*"),gn.setLastInputPoint(_o),ka.abrupt("return",1);case 276:return zo=Math.asin(to/2/Ao)*2,Po=_o.sub(xo).normalize().mult(Ao),Lo=xo.clone().addvec(Po.clone().rotateBy(q?Math.PI-zo/2:zo/2)),Wo=xo.clone().addvec(Po.clone().rotateBy(zo)),ma=MxCADUtility.calcBulge(_o,Lo,Wo).val,$s={},$s.dStartWidth=O,$s.dEndWidth=N,$s.dBulge=0,$s.pt=Wo,n[n.length-1].dBulge=ma,n.push($s),ao=n.length,ao>=2&&(Ps=new McDbPolyline,Ps.addVertexAt(n[ao-2].pt,n[ao-2].dBulge,n[ao-2].dStartWidth,n[ao-2].dEndWidth),Ps.addVertexAt(n[ao-1].pt),L.push(G.drawEntity(Ps))),gn.setLastInputPoint(Wo),ka.abrupt("return",1);case 292:if(il){ka.next=294;break}return ka.abrupt("return",{v:void 0});case 294:return qo=xo.clone().addvec(il.sub(xo).normalize().mult(Ao)),wl=xo.sub(_o).angleTo2(xo.sub(qo),McGeVector3d.kZAxis),yu=new McGePoint3d((_o.x+qo.x)/2,(_o.y+qo.y)/2),po=xo.sub(yu).normalize().mult(-Ao),Zs=xo.clone().addvec((q?wl<Math.PI:wl>Math.PI)?po.negate():po),Es=MxCADUtility.calcBulge(_o,Zs,qo).val,Xl={},Xl.dStartWidth=O,Xl.dEndWidth=N,Xl.dBulge=0,Xl.pt=qo,n[n.length-1].dBulge=Es,n.push(Xl),xl=n.length,xl>=2&&(jo=new McDbPolyline,jo.addVertexAt(n[xl-2].pt,n[xl-2].dBulge,n[xl-2].dStartWidth,n[xl-2].dEndWidth),jo.addVertexAt(n[xl-1].pt),L.push(G.drawEntity(jo))),gn.setLastInputPoint(qo),ka.abrupt("return",1);case 311:if(!gn.isKeyWordPicked("R")){ka.next=383;break}return ju=new MxCADUiPrDist,ju.setMessage(_ML_String("ID_ARX_PLGETSTARTRADIUS","指定圆弧的半径")),ju.setKeyWords(""),ka.next=317,ju.go();case 317:if(Pl=ka.sent,Pl!==null){ka.next=320;break}return ka.abrupt("return",0);case 320:return tl=qn.pt,gn.setLastInputPoint(tl),gn.setMessage("指定圆弧的端点(按住 Ctrl 键以切换方向)"),gn.setKeyWords("[角度(A)]"),gn.setUserDraw(function(pl,Il){if(Pl){var Ss=pl.distanceTo(tl);if(!(Ss>Pl*2)){var Vo=Math.acos(Ss/2/Pl),iu=tl.clone().addvec(pl.sub(tl).rotateBy(Vo).normalize().mult(Pl)),Tu=iu.clone().addvec(new McGePoint3d((tl.x+pl.x)/2,(tl.y+pl.y)/2).sub(iu).normalize().mult(q?-Pl:Pl)),wt=MxCADUtility.calcBulge(tl,Tu,pl).val,qt=new McDbPolyline;qt.addVertexAt(qn.pt,wt,qn.dStartWidth,qn.dEndWidth),qt.addVertexAt(pl),Il.drawMcDbEntity(qt)}}}),ka.next=327,gn.go();case 327:if(zl=ka.sent,!gn.isKeyWordPicked("A")){ka.next=363;break}return Is=new MxCADUiPrAngle,Is.setMessage(_ML_String("ID_ARX_PLGET_I_ANGLE","指定夹角")),Is.setKeyWords(""),Is.setBasePt(tl),ka.next=335,Is.go();case 335:if(al=ka.sent,typeof al=="number"){ka.next=338;break}return ka.abrupt("return",0);case 338:return Mn=Math.sin(al/2)*Pl*2,gn.setMessage("指定圆弧的弦方向(按住 Ctrl 键以切换方向)"),gn.setKeyWords(""),gn.setBasePt(tl),gn.setUserDraw(function(pl,Il){if(Pl){var Ss=pl.sub(tl).normalize(),Vo=tl.clone().addvec(Ss.clone().mult(Mn)),iu=Vo.clone().addvec(Ss.clone().negate().rotateBy(-(Math.PI/2-al/2)).mult(Pl)),Tu=iu.clone().addvec(iu.sub(new McGePoint3d((tl.x+Vo.x)/2,(tl.y+Vo.y)/2)).normalize().mult(q?Pl:-Pl)),wt=MxCADUtility.calcBulge(tl,Tu,Vo).val,qt=new McDbPolyline;qt.addVertexAt(qn.pt,wt,qn.dStartWidth,qn.dEndWidth),qt.addVertexAt(Vo),Il.drawMcDbEntity(qt)}}),ka.next=345,gn.go();case 345:if(Ur=ka.sent,Ur){ka.next=348;break}return ka.abrupt("return",0);case 348:return Gn=Ur.sub(tl).normalize(),Qr=tl.clone().addvec(Gn.clone().mult(Mn)),qi=Qr.clone().addvec(Gn.clone().negate().rotateBy(-(Math.PI/2-al/2)).mult(Pl)),ga=qi.clone().addvec(qi.sub(new McGePoint3d((tl.x+Qr.x)/2,(tl.y+Qr.y)/2)).normalize().mult(q?Pl:-Pl)),no=MxCADUtility.calcBulge(tl,ga,Qr).val,mo={},mo.dStartWidth=O,mo.dEndWidth=N,mo.dBulge=0,mo.pt=Qr,n[n.length-1].dBulge=no,n.push(mo),Go=n.length,Go>=2&&(Uo=new McDbPolyline,Uo.addVertexAt(n[Go-2].pt,n[Go-2].dBulge,n[Go-2].dStartWidth,n[Go-2].dEndWidth),Uo.addVertexAt(n[Go-1].pt),L.push(G.drawEntity(Uo))),ka.abrupt("return",1);case 363:if(zl){ka.next=365;break}return ka.abrupt("return",0);case 365:if(Ns=zl.distanceTo(tl),!(Ns>Pl*2)){ka.next=369;break}return MxFun.acutPrintf("指定圆弧的端点 *无效*"),ka.abrupt("return",1);case 369:return jl=Math.acos(Ns/2/Pl),Bl=tl.clone().addvec(zl.sub(tl).rotateBy(jl).normalize().mult(Pl)),Jl=Bl.clone().addvec(new McGePoint3d((tl.x+zl.x)/2,(tl.y+zl.y)/2).sub(Bl).normalize().mult(q?-Pl:Pl)),mu=MxCADUtility.calcBulge(tl,Jl,zl).val,Ol={},Ol.dStartWidth=O,Ol.dEndWidth=N,Ol.dBulge=0,Ol.pt=zl,n[n.length-1].dBulge=mu,n.push(Ol),bu=n.length,bu>=2&&(Bu=new McDbPolyline,Bu.addVertexAt(n[bu-2].pt,n[bu-2].dBulge,n[bu-2].dStartWidth,n[bu-2].dEndWidth),Bu.addVertexAt(n[bu-1].pt),L.push(G.drawEntity(Bu))),ka.abrupt("return",1);case 383:if(!gn.isKeyWordPicked("H")){ka.next=404;break}return hl=new MxCADUiPrDist,hl.setMessage(_ML_String("ID_ARX_PLGETSTARTWIDTH","指定起点半宽")),ka.next=388,hl.go();case 388:if(vu=ka.sent,vu!==null){ka.next=391;break}return ka.abrupt("return",0);case 391:return O=hl.value()*2,hl.setMessage(_ML_String("ID_ARX_PLGETVERITXWIDTH","指定端点半宽")),ka.next=395,hl.go();case 395:if(vu=ka.sent,vu!==null){ka.next=398;break}return ka.abrupt("return",0);case 398:return N=hl.value()*2,u=N,n[n.length-1].dStartWidth=O,n[n.length-1].dEndWidth=N,O=N,ka.abrupt("return",1);case 404:if(!gn.isKeyWordPicked("D")){ka.next=433;break}return gn.setMessage("指定圆弧起点切向"),gn.setKeyWords(""),gn.setLastInputPoint(qn.pt),gn.setUserDraw(function(pl,Il){Il.drawLine(pl.toVector3(),qn.pt.toVector3())}),ka.next=411,gn.go();case 411:if(Ku=ka.sent,Ku){ka.next=414;break}return ka.abrupt("return",0);case 414:return Ul=Ku.sub(qn.pt),gn.setLastInputPoint(qn.pt),gn.setBasePt(qn.pt),gn.setMessage("指定圆弧的端点(按住 Ctrl 键以切换方向)"),gn.setKeyWords(""),gn.setUserDraw(function(pl,Il){var Ss=CMxDrawPolylineDragArcDraw_CalcArcBulge(qn.pt,pl,q?Ul.clone().negate():Ul),Vo=new McDbPolyline;Vo.addVertexAt(qn.pt,Ss,qn.dStartWidth,qn.dEndWidth),Vo.addVertexAt(pl),Il.drawMcDbEntity(Vo)}),ka.next=422,gn.go();case 422:return ad=ka.sent,jc={},jc.dStartWidth=O,jc.dEndWidth=N,jc.dBulge=0,jc.pt=ad,n[n.length-1].dBulge=CMxDrawPolylineDragArcDraw_CalcArcBulge(qn.pt,jc.pt,q?Ul.clone().negate():Ul),n.push(jc),js=n.length,js>=2&&(co=new McDbPolyline,co.addVertexAt(n[js-2].pt,n[js-2].dBulge,n[js-2].dStartWidth,n[js-2].dEndWidth),co.addVertexAt(n[js-1].pt),L.push(G.drawEntity(co))),ka.abrupt("return",1);case 433:if(!gn.isKeyWordPicked("L")){ka.next=437;break}b=!0,ka.next=492;break;case 437:if(!gn.isKeyWordPicked("S")){ka.next=463;break}return Vl=new McGePoint3d(n[n.length-1].pt.x,n[n.length-1].pt.y,0),Gc=new MxCADUiPrPoint,Gc.setMessage(_ML_String("NO1_ID_SPECIFY_ARC2","指定圆弧的第二个点")),Gc.setBasePt(Vl),ka.next=444,Gc.go();case 444:if(yd=ka.sent,yd!==null){ka.next=447;break}return ka.abrupt("return",0);case 447:return Ql=new MxCADUiPrPoint,Ql.setMessage(_ML_String("ID_CIRCULAR_ENDPOINT","指定圆弧的端点(按住 Ctrl 键以切换方向)")),Ql.setUserDraw(function(pl,Il){var Ss=new McDbArc;Ss.computeArc(Vl.x,Vl.y,yd.x,yd.y,pl.x,pl.y);var Vo=yd;q&&(Vo=Ss.center.clone().addvec(Ss.center.clone().sub(Vo)),Ss.computeArc(Vl.x,Vl.y,Vo.x,Vo.y,pl.x,pl.y)),Il.drawMcDbEntity(Ss)}),ka.next=452,Ql.go();case 452:if(Ll=ka.sent,Ll===null){ka.next=460;break}Au=yd,q&&(jd=new McDbArc,jd.computeArc(Vl.x,Vl.y,Au.x,Au.y,Ll.x,Ll.y),Au=jd.center.clone().addvec(jd.center.clone().sub(Au))),Wu=MxCADUtility.calcBulge(Vl,Au,Ll),Wu.ret?(ud={},ud.dStartWidth=O,ud.dEndWidth=N,ud.pt=Ll,ud.dBluge=0,n[n.length-1].dBulge=Wu.val,n.push(ud),Xc=n.length,Xc>=2&&(yi=new McDbPolyline,yi.addVertexAt(n[Xc-2].pt,n[Xc-2].dBulge,n[Xc-2].dStartWidth,n[Xc-2].dEndWidth),yi.addVertexAt(n[Xc-1].pt),L.push(G.drawEntity(yi)))):MxFun.acutPrintf(_ML_String("ID_ENDPOINT_INVALID1",`
- 端点 *无效*`)),ka.next=461;break;case 460:return ka.abrupt("return",0);case 461:ka.next=492;break;case 463:if(!gn.isKeyWordPicked("W")){ka.next=485;break}return mc=new MxCADUiPrDist,mc.setMessage(_ML_String("ID_ARX_PLGETSTARTWIDTH","指定起点宽度")),ka.next=468,mc.go();case 468:if(Su=ka.sent,Su!==null){ka.next=471;break}return ka.abrupt("return",0);case 471:return O=mc.value(),mc.setMessage(_ML_String("ID_ARX_PLGETVERITXWIDTH","指定端点宽度")),ka.next=475,mc.go();case 475:if(Su=ka.sent,Su!==null){ka.next=478;break}return ka.abrupt("return",0);case 478:N=mc.value(),u=N,n[n.length-1].dStartWidth=O,n[n.length-1].dEndWidth=N,O=N,ka.next=492;break;case 485:if(!gn.isKeyWordPicked("C")){ka.next=491;break}return n[n.length-1].dBulge=CMxDrawPolylineDragArcDraw_CalcArcBulge(qn.pt,l,q?Xn.clone().negate():Xn),y=!0,ka.abrupt("return",0);case 491:gn.isKeyWordPicked("U")&&n.length>1&&(n.pop(),L[L.length-1].erase(),L.pop(),n.length>0&&gn.setLastInputPoint(n[n.length-1].pt));case 492:ka.next=495;break;case 494:return ka.abrupt("return",0);case 495:case"end":return ka.stop()}},Te)});case 29:return Ae.delegateYield(ve(),"t0",31);case 31:if(ne=Ae.t0,ne!==0){Ae.next=34;break}return Ae.abrupt("break",40);case 34:if(ne!==1){Ae.next=36;break}return Ae.abrupt("continue",29);case 36:if(!ne){Ae.next=38;break}return Ae.abrupt("return",ne.v);case 38:Ae.next=29;break;case 40:for(m&&(y=!0),Ue=0;Ue<L.length;Ue++)L[Ue].erase();if(!(n.length>1)){Ae.next=47;break}for(De=new McDbPolyline,Ve=0;Ve<n.length;Ve++)De.addVertexAt(n[Ve].pt,n[Ve].dBulge,n[Ve].dStartWidth,n[Ve].dEndWidth);return De.isClosed=y,Ae.abrupt("return",G.drawEntity(De));case 47:window.removeEventListener("keydown",J),window.removeEventListener("keyup",fe);case 49:case"end":return Ae.stop()}},t)})),_drawPolyLine.apply(this,arguments)}MxFun.on("init",function(){MxFun.addCommand("Mx_Pline",drawPolyLine)});function computeRegularPolygonVertices(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:new McGePoint3d,e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:new McGePoint3d,l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:3,n=[];l=Math.max(3,l),n.push(e);for(var u=Math.PI*2/l,c=1;c<l;c++){var y=Math.cos(u*c),b=Math.sin(u*c),m=t.clone(),O=e.clone(),N=O.x-m.x,L=O.y-m.y,G=N*y-L*b+m.x,q=N*b+L*y+m.y,J=new McGePoint3d(G,q);n.push(J)}return n}function computePolygonVerticesFromMidpoint(){for(var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:new McGePoint3d,e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:new McGePoint3d,l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:3,n=e.x,u=e.y,c=t.x,y=t.y,b=Math.max(3,l),m=Math.sqrt(Math.pow(n-c,2)+Math.pow(u-y,2)),O=m/Math.cos(Math.PI/b),N=Math.atan2(u-y,n-c)-Math.PI/b,L=[],G=0;G<b;G++){var q=N+G*2*Math.PI/b,J=c+O*Math.cos(q),fe=y+O*Math.sin(q);L.push(new McGePoint3d(J,fe))}return L}function computePolygonVerticesFromEdge(t,e,l){for(var n=e.x-t.x,u=e.y-t.y,c=Math.sqrt(n*n+u*u),y=Math.atan2(u,n),b=2*Math.PI/Math.max(3,l),m=[t,e],O=0;O<l;O++){var N=t.x+c*Math.cos(y+O*b),L=t.y+c*Math.sin(y+O*b);t=new McGePoint3d(N,L),m.push(t)}return m}function drawPolygon(){return _drawPolygon.apply(this,arguments)}function _drawPolygon(){return _drawPolygon=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N,L,G,q,J;return regenerator.wrap(function(ve){for(;;)switch(ve.prev=ve.next){case 0:if(b=new MxCADUiPrPoint,e){ve.next=11;break}return m=new MxCADUiPrInt,m.setMessage(`
- 输入侧面数 <5>`),ve.next=6,m.go();case 6:if(e=ve.sent,m.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){ve.next=9;break}return ve.abrupt("return");case 9:m.getStatus()===MrxDbgUiPrBaseReturn$1.kNone&&(e=5),m.clearLastInputPoint();case 11:O=function(){var ne=_asyncToGenerator(regenerator.mark(function Ue(){var De;return regenerator.wrap(function(rt){for(;;)switch(rt.prev=rt.next){case 0:if(De=function(Te){var Xe=new McDbPolyline,ie=computePolygonVerticesFromEdge(u,Te,e||5);return ie.forEach(function(ue){Xe.addVertexAt(ue)}),Xe.isClosed=!0,Xe},u){rt.next=10;break}return b.setMessage(`
- 指定边的第一个端点`),b.setKeyWords(""),rt.next=6,b.go();case 6:if(u=rt.sent,u){rt.next=9;break}return rt.abrupt("return");case 9:b.setUserDraw(function(Ae,Te){Te.drawMcDbEntity(De(Ae))});case 10:if(c){rt.next=15;break}return b.setMessage(`
- 指定边的第二个端点`),rt.next=14,b.go();case 14:c=rt.sent;case 15:if(c){rt.next=17;break}return rt.abrupt("return");case 17:MxCpp.getCurrentMxCAD().drawEntity(De(c));case 18:case"end":return rt.stop()}},Ue)}));return function(){return ne.apply(this,arguments)}}();{ve.next=16;break}case 15:return ve.abrupt("return",ve.sent);case 16:if(b.setMessage(`
- 指定正多变形的中心点`),b.setKeyWords("[边(E)]"),b.setCursorType(MxCursorType.kCross),l){ve.next=23;break}return ve.next=22,b.go();case 22:l=ve.sent;case 23:if(l){ve.next=28;break}if(!b.isKeyWordPicked("e")){ve.next=27;break}return ve.next=27,O();case 27:return ve.abrupt("return");case 28:if(typeof n=="boolean"){ve.next=38;break}return b.setMessage(`
- 输入选项`),b.setKeyWords("[内接于圆(I)/外切于圆(C)]"),b.clearLastInputPoint(),ve.next=34,b.go();case 34:if(b.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){ve.next=36;break}return ve.abrupt("return");case 36:b.isKeyWordPicked("i")&&(n=!1),b.isKeyWordPicked("c")&&(n=!0);case 38:if(N=function(Ue){var De=MxCpp.getCurrentMxCAD().getCurrentDatabaseDrawColor(),Ve=new McDbPolyline;Ve.trueColor=new McCmColor(De);var rt=n?computePolygonVerticesFromMidpoint(l,Ue,e):computeRegularPolygonVertices(l,Ue,e);return rt.forEach(function(Ae){Ve.addVertexAt(Ae)}),Ve.isClosed=!0,Ve},G=new McGeVector3d,y){ve.next=52;break}return q=new MxCADUiPrDist,q.setBasePt(l),q.setUserDraw(function(ne,Ue){Ue.drawMcDbEntity(N(ne)),l&&(G=ne.sub(l))}),q.setMessage(_ML_String("McDbPolyline_Radius",`
- 指定圆的半径`)),q.setKeyWords(""),ve.next=48,q.go();case 48:if(J=ve.sent,J){ve.next=51;break}return ve.abrupt("return");case 51:y=J;case 52:G=G.normalize().mult(y),L=l.clone().addvec(G),MxCpp.getCurrentMxCAD().drawEntity(N(L),!0);case 55:case"end":return ve.stop()}},t)})),_drawPolygon.apply(this,arguments)}MxFun.addCommand("Mx_Polygon",drawPolygon);function calculateEndPoint(t,e,l,n,u,c){var y=l-t,b=n-e,m=u/c,O=y*Math.cos(m)-b*Math.sin(m),N=y*Math.sin(m)+b*Math.cos(m);return O+=t,N+=e,new McGePoint3d(O,N)}function findArcCenterWithRadius(t,e,l){var n=Math.sqrt(Math.pow(l,2)-(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))/4),u={x:(t.x+e.x)/2,y:(t.y+e.y)/2};return new McGePoint3d(u.x-n*(e.y-t.y)/Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2)),u.y-n*(t.x-e.x)/Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2)))}function findEndAngle(t,e,l,n){var u={x:e.x-t.x,y:e.y-t.y},c={x:l.x-t.x,y:l.y-t.y},y=Math.atan2(u.y,u.x),b=Math.atan2(c.y,c.x),m=b-y;m<0&&(m+=2*Math.PI);var O=n+m;return O}function findEndPoint(t,e,l,n){var u=e+l;return new McGePoint3d(t.x+n*Math.cos(u),t.y+n*Math.sin(u))}function calculateChordLength(t,e,l){var n=Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2)),u={x:e.x-t.x,y:e.y-t.y},c={x:l.x-t.x,y:l.y-t.y},y=u.x*c.x+u.y*c.y,b=u.x*c.y-u.y*c.x,m=Math.atan2(b,y),O=2*n*Math.sin(m/2);return O}function drawArc(){return _drawArc.apply(this,arguments)}function _drawArc(){return _drawArc=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N,L,G,q,J,fe,ve,ne,Ue,De,Ve,rt,Ae,Te,Xe,ie;return regenerator.wrap(function(pt){for(;;)switch(pt.prev=pt.next){case 0:e=MxCpp.getCurrentMxCAD(),l=new MxCADUiPrPoint,n=new McDbArc,L=function(){},G=`
- 指定圆弧的起点:`,q="[圆心(C)]",J=!1,fe=function(Tt){Tt.ctrlKey&&(J=!0)},ve=function(){J=!1},ne=function(){window.removeEventListener("keydown",fe),window.removeEventListener("keyup",ve),window.addEventListener("keydown",fe),window.addEventListener("keyup",ve)},Ue=new McDbLine,De=new McCmColor,De.setRGB(255,211,13),Ue.trueColor=De,Ue.linetype="ACAD_ISO02W100",Ve=!1,Ae=function(Tt,kt){J?(n.startAngle=O,n.endAngle=m):(n.startAngle=m,n.endAngle=O),n.radius=N,n.center=b,Ue.endPoint=Tt,kt.drawMcDbEntity(n),kt.drawMcDbEntity(Ue)},Te=function(Tt){n.computeArc(u.x,u.y,c.x,c.y,y.x,y.y),Tt.drawMcDbEntity(n)},Xe=regenerator.mark(function mt(){var Tt,kt,It,nn,tn,pn,_n,Dn,an;return regenerator.wrap(function(Lt){for(;;)switch(Lt.prev=Lt.next){case 0:return l.setUserDraw(L),l.setMessage(G),l.setKeyWords(q),Lt.next=5,l.go();case 5:if(Tt=Lt.sent,!l.isKeyWordPicked("C")){Lt.next=30;break}if(rt="C",Ve=!0,!u){Lt.next=27;break}return l.setMessage(`
- 指定圆弧的圆心`),l.setKeyWords(""),Lt.next=14,l.go();case 14:if(kt=Lt.sent,kt){Lt.next=17;break}return Lt.abrupt("return",{v:void 0});case 17:b=kt,G=`
- 指定圆弧的端点(按住 ctrl 键取相反方向)`,q="[角度(A)/弦长(L)/修改半径(R)]",l.setLastInputPoint(b),Ue.startPoint=b,N=b.distanceTo(u),L=function(hn,xn){m=angleTo(b.x,b.y,u.x,u.y)-Math.PI,O=angleTo(b.x,b.y,hn.x,hn.y)-Math.PI,Ue.endPoint=hn,Ae(hn,xn)},ne(),Lt.next=29;break;case 27:G=`
- 指定圆弧的圆心`,q="";case 29:return Lt.abrupt("return",0);case 30:if(!Ve){Lt.next=124;break}if(!l.isKeyWordPicked("R")){Lt.next=55;break}if(rt!=="E"){Lt.next=41;break}return It=0,nn=function(){var wn=_asyncToGenerator(regenerator.mark(function hn(){var xn;return regenerator.wrap(function(Xr){for(;;)switch(Xr.prev=Xr.next){case 0:return l.setLastInputPoint(u),l.setMessage(`
- 指定圆弧的半径(按住 ctrl 键取相反方向)`),l.setKeyWords(""),l.setLastInputPoint(u),Ue.startPoint=u,ne(),L=function(gn,Xn){It<0?(Ue.endPoint=gn,Xn.drawMcDbEntity(Ue),It=0):(N=gn.distanceTo(u),b=findArcCenterWithRadius(u,y,N),m=angleTo(b.x,b.y,u.x,u.y)-Math.PI,O=angleTo(b.x,b.y,y.x,y.y)-Math.PI,Ae(gn,Xn),It=calculateChordLength(b,u,y))},l.setUserDraw(L),Xr.next=10,l.go();case 10:if(xn=Xr.sent,xn){Xr.next=13;break}return Xr.abrupt("return",!0);case 13:if(It=calculateChordLength(b,u,y),!(It<0)){Xr.next=20;break}return MxFun.acutPrintf(`
- 半径不能小于弦长的一半,弦长为`+It),It=0,Xr.next=19,nn();case 19:return Xr.abrupt("return",Xr.sent);case 20:e.drawEntity(n);case 21:case"end":return Xr.stop()}},hn)}));return function(){return wn.apply(this,arguments)}}(),Lt.next=37,nn();case 37:return Lt.t0=Lt.sent,Lt.abrupt("return",{v:Lt.t0});case 41:return l.setLastInputPoint(b),l.setMessage(_ML_String("draw_arc_id","指定圆弧的半径<"+n.radius+">")),l.setKeyWords(""),l.setUserDraw(function(wn,hn){Ue.startPoint=b,Ue.endPoint=wn,hn.drawMcDbEntity(Ue)}),Lt.next=47,l.go();case 47:if(tn=Lt.sent,tn){Lt.next=50;break}return Lt.abrupt("return",{v:void 0});case 50:N=tn.distanceTo(b),G=`
- 指定圆弧的端点(按住 ctrl 键取相反方向)`,q="[角度(A)/弦长(L)/修改半径(R)]",ne();case 54:return Lt.abrupt("return",0);case 55:if(!l.isKeyWordPicked("A")){Lt.next=74;break}if(!(rt==="C"||rt==="L")){Lt.next=66;break}return G="指定圆弧夹角(按住 ctrl 键取相反方向)",q="[修改半径(R)]",m=Math.PI+angleTo(b.x,b.y,u.x,u.y),l.setLastInputPoint(b),Ue.startPoint=b,N||(N=b.distanceTo(u)),L=function(hn,xn){var $n=angleTo(b.x,b.y,hn.x,hn.y)-Math.PI;y=findEndPoint(b,m,$n,N),O=findEndAngle(b,u,y,m),Ae(hn,xn)},ne(),Lt.abrupt("return",0);case 66:if(rt!=="E"){Lt.next=74;break}return G="指定圆弧夹角(按住 ctrl 键取相反方向)",q="",l.setLastInputPoint(u),Ue.startPoint=u,L=function(hn,xn){var $n=angleTo(u.x,u.y,hn.x,hn.y)-Math.PI;b=findArcCenter(u,y,$n),N=b.distanceTo(u),m=angleTo(b.x,b.y,u.x,u.y)-Math.PI,O=angleTo(b.x,b.y,y.x,y.y)-Math.PI,Ae(hn,xn)},ne(),Lt.abrupt("return",0);case 74:if(!l.isKeyWordPicked("L")){Lt.next=83;break}return rt="L",G=`
- 指定弦长(按住 ctrl 键取相反方向)`,q="[修改半径(R)]",l.setLastInputPoint(u),Ue.startPoint=u,L=function(hn,xn){var $n=hn.distanceTo(u);if($n>N*2){Ue.endPoint=hn,xn.drawMcDbEntity(Ue);return}y=calculateEndPoint(b.x,b.y,u.x,u.y,$n,n.radius),O=angleTo(b.x,b.y,y.x,y.y)-Math.PI,Ae(hn,xn)},ne(),Lt.abrupt("return",0);case 83:if(!l.isKeyWordPicked("D")){Lt.next=98;break}return l.setMessage(`
- 指定圆弧起点的切向(按住 ctrl 键取相反方向`),l.setKeyWords(""),l.setLastInputPoint(u),Ue.startPoint=u,pn=new McDbPolyline,ne(),l.setUserDraw(function(wn,hn){u=u,y=y;var xn=wn.sub(u),$n=CMxDrawPolylineDragArcDraw_CalcArcBulge(J?u:y,J?y:u,xn);pn=new McDbPolyline,pn.addVertexAt(u,$n),pn.addVertexAt(y),Ue.endPoint=wn,hn.drawMcDbEntity(pn),hn.drawMcDbEntity(Ue)}),Lt.next=93,l.go();case 93:if(_n=Lt.sent,_n){Lt.next=96;break}return Lt.abrupt("return",{v:void 0});case 96:return e.drawEntity(pn),Lt.abrupt("return",{v:void 0});case 98:if(Tt){Lt.next=100;break}return Lt.abrupt("return",{v:void 0});case 100:if(rt!=="L"){Lt.next=106;break}if(Dn=Tt.distanceTo(u),!(Dn>N*2)){Lt.next=106;break}return l.clearLastInputPoint(),MxFun.acutPrintf(`
- 弦长不能超出半径的两倍,半径为`+N),Lt.abrupt("return",0);case 106:if(b){Lt.next=111;break}return b=Tt,G=`
- 指定圆弧的起点`,L=function(hn,xn){xn.drawLine(hn.toVector3(),b.toVector3())},Lt.abrupt("return",0);case 111:if(u){Lt.next=122;break}return u=Tt,m=angleTo(b.x,b.y,u.x,u.y)-Math.PI,N=u.distanceTo(b),G=`
- 指定圆弧的端点(按住 ctrl 键取相反方向)`,q="[角度(A)/弦长(L)/修改半径(R)]",l.setLastInputPoint(b),Ue.startPoint=b,L=function(hn,xn){O=angleTo(b.x,b.y,hn.x,hn.y)-Math.PI,Ae(hn,xn)},ne(),Lt.abrupt("return",0);case 122:return e.drawEntity(n),Lt.abrupt("return",{v:void 0});case 124:if(!l.isKeyWordPicked("E")){Lt.next=146;break}return rt="E",l.clearLastInputPoint(),l.setMessage(`
- 指定圆弧的端点`),l.setKeyWords(""),Ue.startPoint=u,u=u,l.setUserDraw(function(wn,hn){Ue.endPoint=wn,hn.drawMcDbEntity(Ue)}),Lt.next=134,l.go();case 134:if(an=Lt.sent,an){Lt.next=137;break}return Lt.abrupt("return",{v:void 0});case 137:return y=an,Ve=!0,G=`
- 指定圆弧的圆心(按住 ctrl 键取相反方向)`,q="[角度(A)/方向(D)/半径(R)]",l.setLastInputPoint(y),Ue.startPoint=y,L=function(hn,xn){b=hn,N=b.distanceTo(u),m=angleTo(b.x,b.y,u.x,u.y)-Math.PI,O=angleTo(b.x,b.y,y.x,y.y)-Math.PI,Ae(hn,xn)},ne(),Lt.abrupt("return",0);case 146:if(Tt){Lt.next=148;break}return Lt.abrupt("return",{v:void 0});case 148:if(u){Lt.next=155;break}return u=Tt,G=`
- 指定圆弧第二个点`,q="[圆心(C)/端点(E)]",L=function(hn,xn){xn.drawLine(u.toVector3(),hn.toVector3())},l.clearLastInputPoint(),Lt.abrupt("return",0);case 155:if(c){Lt.next=161;break}return c=Tt,G=`
- 指定圆弧的端点`,q="",L=function(hn,xn){y=hn,Te(xn)},Lt.abrupt("return",0);case 161:return L(c,{drawMcDbEntity:function(hn){MxCpp.getCurrentMxCAD().drawEntity(hn,!0)}}),Lt.abrupt("return",{v:void 0});case 163:case"end":return Lt.stop()}},mt)});case 19:return pt.delegateYield(Xe(),"t0",21);case 21:if(ie=pt.t0,ie!==0){pt.next=24;break}return pt.abrupt("continue",19);case 24:if(!ie){pt.next=26;break}return pt.abrupt("return",ie.v);case 26:pt.next=19;break;case 28:case"end":return pt.stop()}},t)})),_drawArc.apply(this,arguments)}MxFun.on("init",function(){MxFun.addCommand("Mx_Arc",drawArc)});function drawEllipticalArc(){return _drawEllipticalArc.apply(this,arguments)}function _drawEllipticalArc(){return _drawEllipticalArc=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N;return regenerator.wrap(function(G){for(;;)switch(G.prev=G.next){case 0:u=1,c=0,y=Math.PI*2,b=0,m=function(){var J=new McDbEllipse;return J.center=e,J.majorAxis=l,J.minorAxis=n,J.radiusRatio=u,J.startAngle=c,J.endAngle=y,J.rotate(e,b),J},O=regenerator.mark(function q(){var J,fe,ve,ne,Ue,De,Ve,rt,Ae,Te,Xe,ie,ue;return regenerator.wrap(function(mt){for(;;)switch(mt.prev=mt.next){case 0:return J=new MxCADUiPrPoint,J.setMessage("指定椭圆弧的轴端点"),J.setKeyWords("[中心点(C)]"),mt.next=5,J.go();case 5:if(fe=mt.sent,ve=0,ne=null,!J.isKeyWordPicked("C")){mt.next=29;break}return J.setMessage("指定椭圆弧的中心点"),J.setKeyWords(""),J.clearLastInputPoint(),mt.next=14,J.go();case 14:if(Ue=mt.sent,Ue){mt.next=17;break}return mt.abrupt("return",{v:void 0});case 17:return e=Ue,J.setMessage("指定椭圆弧轴的端点"),J.setBasePt(e),mt.next=22,J.go();case 22:if(ne=mt.sent,ne){mt.next=25;break}return mt.abrupt("return",{v:void 0});case 25:l=n=e.sub(ne),ve=e.distanceTo(ne),mt.next=42;break;case 29:if(fe){mt.next=31;break}return mt.abrupt("return",{v:void 0});case 31:return J.setBasePt(fe),J.setMessage("指定椭圆弧轴的另一个端点"),J.setKeyWords(""),mt.next=36,J.go();case 36:if(ne=mt.sent,ne){mt.next=39;break}return mt.abrupt("return",{v:void 0});case 39:e=new McGePoint3d((fe.x+ne.x)/2,(fe.y+ne.y)/2),l=n=fe.sub(ne),ve=fe.distanceTo(ne)/2;case 42:return De=new MxCADUiPrDist,De.setMessage(_ML_String("McDbEllipse_lengh","指定另一条半轴长度")),De.setKeyWords("[旋转(R)]"),De.setBasePt(e),De.setUserDraw(function(Tt,kt){var It=e.distanceTo(Tt)/2;u=It/ve;var nn=m();kt.drawMcDbEntity(nn)}),mt.next=49,De.go();case 49:if(Ve=mt.sent,!De.isKeyWordPicked("R")){mt.next=63;break}return De.setMessage(_ML_String("McDbEllipse_Rotation","指定绕主轴旋转的角度")),De.setKeyWords(""),De.setBasePt(e),De.setUserDraw(function(Tt,kt){l=n=l.rotateBy(angleTo(e.x,e.y,Tt.x,Tt.y));var It=m();kt.drawMcDbEntity(It)}),mt.next=57,De.go();case 57:if(rt=mt.sent,rt){mt.next=60;break}return mt.abrupt("return",{v:void 0});case 60:De.getDetailedResult()===8&&(b=rt),mt.next=67;break;case 63:if(Ve){mt.next=65;break}return mt.abrupt("return",{v:void 0});case 65:Ae=Ve/2,u=Ae/ve;case 67:if(ne){mt.next=69;break}return mt.abrupt("return",{v:void 0});case 69:return Te=angleTo(ne.x,ne.y,e.x,e.y),De.setMessage(_ML_String("McDbEllipse_startAngle","指定起点角度")),De.setKeyWords(""),De.setBasePt(e),De.setUserDraw(function(Tt,kt){c=angleTo(e.x,e.y,Tt.x,Tt.y)-Te;var It=m();kt.drawMcDbEntity(It)}),mt.next=76,De.go();case 76:if(Xe=mt.sent,Xe){mt.next=79;break}return mt.abrupt("return",{v:void 0});case 79:return De.getDetailedResult()===8&&(c=Xe),De.clearLastInputPoint(),De.setBasePt(e),De.setMessage(_ML_String("McDbEllipse_endAngle","指定端点角度")),De.setKeyWords("[夹角(I)]"),De.setUserDraw(function(Tt,kt){y=angleTo(e.x,e.y,Tt.x,Tt.y)-Te;var It=m();kt.drawMcDbEntity(It)}),mt.next=87,De.go();case 87:if(ie=mt.sent,!De.isKeyWordPicked("I")){mt.next=99;break}return De.setMessage(_ML_String("McDbEllipse_IncludedAngle","指定椭圆弧的夹角")),De.setKeyWords(""),De.setUserDraw(function(Tt,kt){y=angleTo(e.x,e.y,Tt.x,Tt.y);var It=m();kt.drawMcDbEntity(It)}),mt.next=94,De.go();case 94:if(ue=mt.sent,ue){mt.next=97;break}return mt.abrupt("return",{v:void 0});case 97:return De.getDetailedResult()===8&&(y=ue),mt.abrupt("return",{v:MxCpp.getCurrentMxCAD().drawEntity(m())});case 99:if(ie){mt.next=101;break}return mt.abrupt("return",{v:void 0});case 101:return De.getDetailedResult()===8&&(y=ie),mt.abrupt("return",{v:MxCpp.getCurrentMxCAD().drawEntity(m())});case 103:case"end":return mt.stop()}},q)});case 6:return G.delegateYield(O(),"t0",8);case 8:if(N=G.t0,!N){G.next=11;break}return G.abrupt("return",N.v);case 11:G.next=6;break;case 13:case"end":return G.stop()}},t)})),_drawEllipticalArc.apply(this,arguments)}function drawMxDbEllipse(){return _drawMxDbEllipse.apply(this,arguments)}function _drawMxDbEllipse(){return _drawMxDbEllipse=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N;return regenerator.wrap(function(G){for(;;)switch(G.prev=G.next){case 0:e=new MxCADUiPrPoint,c=1,y=0,b=Math.PI*2,e.setMessage(`
- 指定椭圆的轴端点`),e.setKeyWords("[圆弧(A)/中心点(C)]"),m=function(){var J=new McDbEllipse;return J.center=l,J.majorAxis=n,J.minorAxis=u,J.radiusRatio=c,J.startAngle=y,J.endAngle=b,J},O=regenerator.mark(function q(){var J,fe,ve,ne,Ue,De,Ve,rt,Ae,Te,Xe,ie,ue,pt,mt,Tt,kt,It;return regenerator.wrap(function(tn){for(;;)switch(tn.prev=tn.next){case 0:return J=!1,fe=!1,ve=!1,tn.next=5,e.go();case 5:if(ne=tn.sent,!e.isKeyWordPicked("A")){tn.next=17;break}return e.setMessage(`
- 指定椭圆弧的轴端点`),e.setKeyWords("[中心点(C)]"),tn.next=11,e.go();case 11:if(Ue=tn.sent,e.isKeyWordPicked("C")&&(ve=!0),!(!Ue&&!ve)){tn.next=15;break}return tn.abrupt("return",{v:void 0});case 15:Ue&&(ne=Ue),J=!0;case 17:if(!(e.isKeyWordPicked("C")||ve)){tn.next=27;break}return e.setMessage(`
- 指定椭圆中心点`),e.setKeyWords(""),tn.next=22,e.go();case 22:if(De=tn.sent,De){tn.next=25;break}return tn.abrupt("return",{v:void 0});case 25:l=ne=De,fe=!0;case 27:if(!(!ne&&!J&&!fe)){tn.next=29;break}return tn.abrupt("return",{v:void 0});case 29:return e.setUserDraw(function(pn,_n){_n.drawMcDbLine(ne.x,ne.y,ne.z,pn.x,pn.y,pn.z)}),e.setMessage(fe?`
- 指定椭圆轴的端点`:`
- 指定椭圆轴的另一个端点`),e.setKeyWords(""),tn.next=34,e.go();case 34:if(Ve=tn.sent,Ve){tn.next=37;break}return tn.abrupt("return",{v:void 0});case 37:return l=fe?ne:new McGePoint3d((ne.x+Ve.x)/2,(ne.y+Ve.y)/2),rt=new MxCADUiPrDist,rt.setBasePt(l),Ae=ne.distanceTo(Ve)/2,u=n=ne.sub(Ve),Te=function(_n,Dn){var an=m(),Rn=new McDbLine(l,_n);Rn.trueColor=new McCmColor,Rn.trueColor.setRGB(255,255,0),Dn.drawMcDbEntity(Rn),Dn.drawMcDbEntity(an)},rt.setUserDraw(function(pn,_n){var Dn=l.distanceTo(pn)/2;c=Dn/Ae,Te(pn,_n)}),rt.setMessage(_ML_String("EllipticalArc_length","指定另一条半轴长度")),rt.setKeyWords(""),tn.next=48,rt.go();case 48:if(Xe=tn.sent,Xe){tn.next=51;break}return tn.abrupt("return",{v:void 0});case 51:if(rt.getDetailedResult()===DetailedResult.kCoordIn&&(ie=Xe/2,c=ie/Ae),rt.setLastInputPoint(l),!J){tn.next=86;break}return rt.setMessage(_ML_String("EllipticalArc_startAngle","指定起点角度")),rt.setKeyWords(""),ue=angleTo(l.x,l.y,Ve.x,Ve.y),rt.setUserDraw(function(pn,_n){y=angleTo(l.x,l.y,pn.x,pn.y)-ue-Math.PI,Te(pn,_n)}),tn.next=60,rt.go();case 60:if(pt=tn.sent,pt){tn.next=63;break}return tn.abrupt("return",{v:void 0});case 63:return rt.getDetailedResult()==DetailedResult.kCoordIn&&(y=pt),rt.setLastInputPoint(l),rt.setMessage(_ML_String("EllipticalArc_endAngle","指定端点角度")),rt.setKeyWords("[夹角(I)]"),rt.setUserDraw(function(pn,_n){b=angleTo(l.x,l.y,pn.x,pn.y)-ue-Math.PI,Te(pn,_n)}),tn.next=70,rt.go();case 70:if(mt=tn.sent,!rt.isKeyWordPicked("I")){tn.next=83;break}return rt.setMessage(`
- 指定椭圆弧的夹角`),rt.setKeyWords(""),rt.setUserDraw(function(pn,_n){b=angleTo(l.x,l.y,pn.x,pn.y)-Math.PI,Te(pn,_n)}),tn.next=77,rt.go();case 77:if(Tt=tn.sent,Tt){tn.next=80;break}return tn.abrupt("return",{v:void 0});case 80:return rt.getDetailedResult()===DetailedResult.kCoordIn&&(b=Tt),kt=m(),tn.abrupt("return",{v:MxCpp.getCurrentMxCAD().drawEntity(kt)});case 83:if(mt){tn.next=85;break}return tn.abrupt("return",{v:void 0});case 85:rt.getDetailedResult()===DetailedResult.kCoordIn&&(b=mt);case 86:return It=m(),tn.abrupt("return",{v:MxCpp.getCurrentMxCAD().drawEntity(It)});case 88:case"end":return tn.stop()}},q)});case 8:return G.delegateYield(O(),"t0",10);case 10:if(N=G.t0,!N){G.next=13;break}return G.abrupt("return",N.v);case 13:G.next=8;break;case 15:case"end":return G.stop()}},t)})),_drawMxDbEllipse.apply(this,arguments)}MxFun.on("init",function(){MxFun.addCommand("Mx_EllipseArc",drawEllipticalArc),MxFun.addCommand("Mx_Ellipse",drawMxDbEllipse)});function Mx_Erase(){return _Mx_Erase.apply(this,arguments)}function _Mx_Erase(){return _Mx_Erase=_asyncToGenerator(regenerator.mark(function t(){var e,l;return regenerator.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:if(e=MxCADUtility.getCurrentSelect(),!(e.length>0)){u.next=4;break}return e.forEach(function(c){c.erase()}),u.abrupt("return");case 4:return l=new MxCADSelectionSet,u.next=7,l.userSelect(`
- 选择删除对象`);case 7:if(u.sent){u.next=9;break}return u.abrupt("return");case 9:l.forEach(function(c){c.erase()});case 10:case"end":return u.stop()}},t)})),_Mx_Erase.apply(this,arguments)}function MxGetMcDbEntityBoundingBox(t){var e=void 0,l=void 0;if(t.forEach(function(n){var u=n.getMcDbEntity();if(u!=null){var c=u.getBoundingBox();c.ret&&(!e||!l?(e=new THREE.Vector3(c.minPt.x,c.minPt.y,0),l=new THREE.Vector3(c.maxPt.x,c.maxPt.y,0)):(e.x>c.minPt.x&&(e.x=c.minPt.x),e.y>c.minPt.y&&(e.y=c.minPt.y),l.x<c.maxPt.x&&(l.x=c.maxPt.x),l.y<c.maxPt.y&&(l.y=c.maxPt.y)))}}),e&&l)return{minPt:e,maxPt:l}}function Mx_Copy(){return _Mx_Copy.apply(this,arguments)}function _Mx_Copy(){return _Mx_Copy=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N;return regenerator.wrap(function(G){for(;;)switch(G.prev=G.next){case 0:if(e=MxCADUtility.getCurrentSelect(),!(e.length>0)){G.next=4;break}return G.abrupt("break",15);case 4:return l=new MxCADSelectionSet,G.next=7,l.userSelect(`
- 选择复制对象`);case 7:if(G.sent){G.next=9;break}return G.abrupt("return");case 9:if(e=l.getIds(),e.length!=0){G.next=12;break}return G.abrupt("return");case 12:return G.abrupt("break",15);case 15:return e.length>=10&&(c=MxGetMcDbEntityBoundingBox(e),c&&(n=c.minPt,u=c.maxPt)),y=new MxCADUiPrPoint,y.setMessage(`
- 指定基点`),G.next=20,y.go();case 20:if(b=G.sent,b){G.next=23;break}return G.abrupt("return");case 23:y.setMessage("指定移动到点"),y.setBasePt(b),y.setUseBasePt(!0),y.setUserDraw(function(q,J){if(n&&u){var fe=q.x-b.x,ve=q.y-b.y,ne=new THREE.Vector3(n.x+fe,u.y+ve,0),Ue=new THREE.Vector3(u.x+fe,n.y+ve,0),De=new THREE.Vector3(ne.x,Ue.y,0),Ve=new THREE.Vector3(Ue.x,ne.y,0);ne=MxCoordConvert.cad2doc2(ne.x,ne.y,ne.z),Ue=MxCoordConvert.cad2doc2(Ue.x,Ue.y,Ue.z),De=MxCoordConvert.cad2doc2(De.x,De.y,De.z),Ve=MxCoordConvert.cad2doc2(Ve.x,Ve.y,Ve.z),J.drawLine(Ve,ne),J.drawLine(ne,De),J.drawLine(De,Ue),J.drawLine(Ue,Ve)}for(var rt=0;rt<e.length&&rt<10;rt++){var Ae=e[rt].clone();Ae&&(Ae.move(b,q),J.drawMcDbEntity(Ae))}});case 27:return G.next=30,y.go();case 30:if(m=G.sent,m){G.next=33;break}return G.abrupt("return");case 33:O=0;case 34:if(!(O<e.length)){G.next=43;break}if(N=e[O].clone(),N){G.next=38;break}return G.abrupt("continue",40);case 38:N.move(b,m),MxCpp.getCurrentMxCAD().drawEntity(N);case 40:O++,G.next=34;break;case 43:G.next=27;break;case 45:case"end":return G.stop()}},t)})),_Mx_Copy.apply(this,arguments)}function Mx_Move(){return _Mx_Move.apply(this,arguments)}function _Mx_Move(){return _Mx_Move=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N;return regenerator.wrap(function(G){for(;;)switch(G.prev=G.next){case 0:if(e=MxCADUtility.getCurrentSelect(),!(e.length>0)){G.next=4;break}return G.abrupt("break",15);case 4:return l=new MxCADSelectionSet,G.next=7,l.userSelect(`
- 选择移动对象`);case 7:if(G.sent){G.next=9;break}return G.abrupt("return");case 9:if(e=l.getIds(),e.length!=0){G.next=12;break}return G.abrupt("return");case 12:return G.abrupt("break",15);case 15:return e.length>=10&&(c=MxGetMcDbEntityBoundingBox(e),c&&(n=c.minPt,u=c.maxPt)),y=new MxCADUiPrPoint,y.setMessage("指定基点"),y.clearLastInputPoint(),G.next=21,y.go();case 21:if(b=G.sent,b){G.next=24;break}return G.abrupt("return");case 24:return y.setMessage("指定移动到点"),y.setBasePt(b),y.setUseBasePt(!0),y.setUserDraw(function(q,J){if(n&&u){var fe=q.x-b.x,ve=q.y-b.y,ne=new THREE.Vector3(n.x+fe,u.y+ve,0),Ue=new THREE.Vector3(u.x+fe,n.y+ve,0),De=new THREE.Vector3(ne.x,Ue.y,0),Ve=new THREE.Vector3(Ue.x,ne.y,0);ne=MxCoordConvert.cad2doc2(ne.x,ne.y,ne.z),Ue=MxCoordConvert.cad2doc2(Ue.x,Ue.y,Ue.z),De=MxCoordConvert.cad2doc2(De.x,De.y,De.z),Ve=MxCoordConvert.cad2doc2(Ve.x,Ve.y,Ve.z),J.drawLine(Ve,ne),J.drawLine(ne,De),J.drawLine(De,Ue),J.drawLine(Ue,Ve)}for(var rt=0;rt<e.length&&rt<10;rt++){var Ae=e[rt].clone();Ae&&(Ae.move(b,q),J.drawMcDbEntity(Ae))}}),G.next=30,y.go();case 30:if(m=G.sent,m){G.next=33;break}return G.abrupt("return");case 33:O=0;case 34:if(!(O<e.length)){G.next=42;break}if(N=e[O].getMcDbObject(),N){G.next=38;break}return G.abrupt("continue",39);case 38:N.move(b,m);case 39:O++,G.next=34;break;case 42:case"end":return G.stop()}},t)})),_Mx_Move.apply(this,arguments)}function Mx_Rotate(){return _Mx_Rotate.apply(this,arguments)}function _Mx_Rotate(){return _Mx_Rotate=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N,L,G;return regenerator.wrap(function(J){for(;;)switch(J.prev=J.next){case 0:if(e=MxCADUtility.getCurrentSelect(),!(e.length>0)){J.next=4;break}return J.abrupt("break",15);case 4:return l=new MxCADSelectionSet,J.next=7,l.userSelect(`
- 选择旋转对象`);case 7:if(J.sent){J.next=9;break}return J.abrupt("return");case 9:if(e=l.getIds(),e.length!=0){J.next=12;break}return J.abrupt("return");case 12:return J.abrupt("break",15);case 15:return c=MxGetMcDbEntityBoundingBox(e),c&&(n=c.minPt,u=c.maxPt),y=new MxCADUiPrPoint,y.setMessage("指定基点"),J.next=21,y.go();case 21:if(b=J.sent,b!=null){J.next=24;break}return J.abrupt("return");case 24:m=!1,O=0,N=new MxCADUiPrAngle,N.setMessage(_ML_String("Entity_Rotate_Angle","指定旋转角度")),N.setKeyWords("[复制(C)/参照(R)]"),N.setBasePt(b),N.setUseBasePt(!0),L=regenerator.mark(function fe(){var ve,ne,Ue,De,Ve,rt,Ae,Te,Xe,ie,ue,pt;return regenerator.wrap(function(Tt){for(;;)switch(Tt.prev=Tt.next){case 0:return N.setUserDraw(function(kt,It){var nn=kt,tn=b,pn=nn.sub(tn),_n=pn.angleTo2(McGeVector3d.kXAxis,McGeVector3d.kNegateZAxis)-O,Dn=new McGeMatrix3d;if(Dn.setToRotation(_n,McGeVector3d.kZAxis,tn),n&&u){var an=new McGePoint3d(n.x,u.y,0),Rn=new McGePoint3d(u.x,n.y,0),Lt=new McGePoint3d(an.x,Rn.y,0),wn=new McGePoint3d(Rn.x,an.y,0);an.transformBy(Dn),Rn.transformBy(Dn),Lt.transformBy(Dn),wn.transformBy(Dn),an=MxCoordConvert.cad2doc(an),Rn=MxCoordConvert.cad2doc(Rn),Lt=MxCoordConvert.cad2doc(Lt),wn=MxCoordConvert.cad2doc(wn),It.drawLine(wn.toVector3(),an.toVector3()),It.drawLine(an.toVector3(),Lt.toVector3()),It.drawLine(Lt.toVector3(),Rn.toVector3()),It.drawLine(Rn.toVector3(),wn.toVector3())}Dn.setToRotation(_n,McGeVector3d.kZAxis,tn);for(var hn=0;hn<e.length&&hn<10;hn++){var xn=e[hn].clone();xn&&(xn.transformBy(Dn),It.drawMcDbEntity(xn))}}),Tt.next=3,N.go();case 3:if(ve=Tt.sent,!N.isKeyWordPicked("C")){Tt.next=7;break}return m=!0,Tt.abrupt("return",0);case 7:if(!N.isKeyWordPicked("R")){Tt.next=22;break}return ne=new MxCADUiPrDist,ne.setMessage(_ML_String("Entity_Rotate_Ref_Angle","指定参照角:<"+(O/(Math.PI/180)).toFixed(3)+">")),ne.setKeyWords(""),ne.setBasePt(b),ne.setUseBasePt(!0),Ue=0,ne.setUserDraw(function(kt){if(b){var It=kt.sub(b);Ue=It.angleTo2(McGeVector3d.kXAxis,McGeVector3d.kNegateZAxis)}}),Tt.next=17,ne.go();case 17:if(De=Tt.sent,typeof De=="number"){Tt.next=20;break}return Tt.abrupt("return",{v:void 0});case 20:return ne.getDetailedResult()===DetailedResult.kCoordIn?O=De:Ue!==0&&(O=Ue),Tt.abrupt("return",0);case 22:if(ve){Tt.next=24;break}return Tt.abrupt("return",{v:void 0});case 24:if(Ve=b,rt=new McGeMatrix3d,rt.setToRotation(ve,McGeVector3d.kZAxis,Ve),Ae=function(It){return It instanceof McDbEntity},!m){Tt.next=42;break}Te=[],Xe=0;case 31:if(!(Xe<e.length)){Tt.next=39;break}if(ie=e[Xe].clone(),ie){Tt.next=35;break}return Tt.abrupt("continue",36);case 35:Ae(ie)&&(ie.transformBy(rt),Te.push(MxCpp.getCurrentMxCAD().drawEntity(ie)));case 36:Xe++,Tt.next=31;break;case 39:return Tt.abrupt("return",{v:Te});case 42:ue=0;case 43:if(!(ue<e.length)){Tt.next=51;break}if(pt=e[ue].getMcDbObject(),pt){Tt.next=47;break}return Tt.abrupt("continue",48);case 47:pt.transformBy(rt);case 48:ue++,Tt.next=43;break;case 51:return Tt.abrupt("return",{v:e});case 52:case"end":return Tt.stop()}},fe)});case 32:return J.delegateYield(L(),"t0",34);case 34:if(G=J.t0,G!==0){J.next=37;break}return J.abrupt("continue",32);case 37:if(!G){J.next=39;break}return J.abrupt("return",G.v);case 39:J.next=32;break;case 41:case"end":return J.stop()}},t)})),_Mx_Rotate.apply(this,arguments)}function Mx_Scale(){return _Mx_Scale.apply(this,arguments)}function _Mx_Scale(){return _Mx_Scale=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N,L,G,q,J,fe,ve,ne,Ue,De,Ve,rt,Ae,Te,Xe,ie,ue;return regenerator.wrap(function(mt){for(;;)switch(mt.prev=mt.next){case 0:if(e=MxCADUtility.getCurrentSelect(),!(e.length>0)){mt.next=4;break}return mt.abrupt("break",15);case 4:return l=new MxCADSelectionSet,mt.next=7,l.userSelect(`
- 选择缩放对象`);case 7:if(mt.sent){mt.next=9;break}return mt.abrupt("return");case 9:if(e=l.getIds(),e.length!=0){mt.next=12;break}return mt.abrupt("return");case 12:return mt.abrupt("break",15);case 15:if(c=MxGetMcDbEntityBoundingBox(e),c){mt.next=18;break}return mt.abrupt("return");case 18:return n=c.minPt,u=c.maxPt,y=u.x-n.x,b=u.y-n.y,m=(y+b)/3,m<1e-5&&(m=1),O=new MxCADUiPrPoint,O.setMessage("指定基点"),mt.next=28,O.go();case 28:if(N=mt.sent,N){mt.next=31;break}return mt.abrupt("return");case 31:L=0,G=!1,q=function(kt,It){if(N){var nn=new McGePoint3d(kt),tn=new McGePoint3d(N),pn=nn.distanceTo(tn);if(!(pn<1e-5)){L=pn/m,L>1e5&&(L=1e5);var _n=new McGeMatrix3d;if(_n.setToScaling(L,tn),n&&u){var Dn=new McGePoint3d(n.x,u.y,0),an=new McGePoint3d(u.x,n.y,0),Rn=new McGePoint3d(Dn.x,an.y,0),Lt=new McGePoint3d(an.x,Dn.y,0);Dn.transformBy(_n),an.transformBy(_n),Rn.transformBy(_n),Lt.transformBy(_n),Dn=MxCoordConvert.cad2doc(Dn),an=MxCoordConvert.cad2doc(an),Rn=MxCoordConvert.cad2doc(Rn),Lt=MxCoordConvert.cad2doc(Lt),It.drawLine(Lt.toVector3(),Dn.toVector3()),It.drawLine(Dn.toVector3(),Rn.toVector3()),It.drawLine(Rn.toVector3(),an.toVector3()),It.drawLine(an.toVector3(),Lt.toVector3())}_n.setToScaling(L,tn);for(var wn=0;wn<e.length&&wn<10;wn++){var hn=e[wn].clone();hn&&(hn.transformBy(_n),It.drawMcDbEntity(hn))}}}};case 34:return J=new MxCADUiPrDist,J.setMessage("指定比例因子"),J.setKeyWords("[复制(C)/参照(R)]"),J.setBasePt(N),J.setUseBasePt(!0),J.setUserDraw(q),mt.next=43,J.go();case 43:if(fe=mt.sent,!J.isKeyWordPicked("C")){mt.next=47;break}return G=!0,mt.abrupt("continue",34);case 47:if(!J.isKeyWordPicked("R")){mt.next=73;break}return ve=new MxCADUiPrDist,ve.setMessage("指定参照长度"),ve.setBasePt(N),mt.next=53,ve.go();case 53:if(ne=mt.sent,ne){mt.next=56;break}return mt.abrupt("return");case 56:return m=ne,ve.setMessage("指定新的长度"),ve.setKeyWords("[点(P)]"),ve.setBasePt(N),ve.setUserDraw(q),mt.next=63,ve.go();case 63:if(Ue=mt.sent,!ve.isKeyWordPicked("P")){mt.next=70;break}return De=new MxCADUiPrDist,De.setMessage("指定长度"),mt.next=69,De.go();case 69:Ue=mt.sent;case 70:if(Ue){mt.next=72;break}return mt.abrupt("return");case 72:fe=Ue/ne;case 73:if(fe){mt.next=75;break}return mt.abrupt("return");case 75:if(J.getDetailedResult()===DetailedResult.kCoordIn&&(L=fe),L>1e5&&(L=1e5),Ve=new McGeMatrix3d,Ve.setToScaling(L,N),!G){mt.next=94;break}rt=[],Ae=function(kt){return kt instanceof McDbEntity},Te=0;case 83:if(!(Te<e.length)){mt.next=91;break}if(Xe=e[Te].clone(),Xe){mt.next=87;break}return mt.abrupt("continue",88);case 87:Ae(Xe)&&(Xe.transformBy(Ve),rt.push(MxCpp.getCurrentMxCAD().drawEntity(Xe)));case 88:Te++,mt.next=83;break;case 91:return mt.abrupt("return",rt);case 94:ie=0;case 95:if(!(ie<e.length)){mt.next=103;break}if(ue=e[ie].getMcDbObject(),ue){mt.next=99;break}return mt.abrupt("continue",100);case 99:ue.transformBy(Ve);case 100:ie++,mt.next=95;break;case 103:return mt.abrupt("return",e);case 104:mt.next=34;break;case 106:case"end":return mt.stop()}},t)})),_Mx_Scale.apply(this,arguments)}function Mx_WindowZoom(){return _Mx_WindowZoom.apply(this,arguments)}function _Mx_WindowZoom(){return _Mx_WindowZoom=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u;return regenerator.wrap(function(y){for(;;)switch(y.prev=y.next){case 0:return e=new MxCADUiPrPoint,e.disableAllTrace(),e.setMessage(`
- 点取缩放区域`),e.setDynamicInputType(DynamicInputType.kDynTip),y.next=6,e.go();case 6:if(l=y.sent,l!=null){y.next=9;break}return y.abrupt("return");case 9:return n=MxCpp.getCurrentMxCAD(),e.setUserDraw(function(b,m){m.drawRect(MxCoordConvert.cad2doc1(l),MxCoordConvert.cad2doc1(b))}),y.next=13,e.go();case 13:if(u=y.sent,u!=null){y.next=16;break}return y.abrupt("return");case 16:n.zoomW(l,u);case 17:case"end":return y.stop()}},t)})),_Mx_WindowZoom.apply(this,arguments)}function Mx_ZoomE(){return _Mx_ZoomE.apply(this,arguments)}function _Mx_ZoomE(){return _Mx_ZoomE=_asyncToGenerator(regenerator.mark(function t(){return regenerator.wrap(function(l){for(;;)switch(l.prev=l.next){case 0:MxCpp.getCurrentMxCAD().zoomAll(!0);case 1:case"end":return l.stop()}},t)})),_Mx_ZoomE.apply(this,arguments)}function Mx_Plan90CW(){return _Mx_Plan90CW.apply(this,arguments)}function _Mx_Plan90CW(){return _Mx_Plan90CW=_asyncToGenerator(regenerator.mark(function t(){var e,l;return regenerator.wrap(function(u){for(;;)switch(u.prev=u.next){case 0:e=MxFun.getCurrentDraw().getViewAngle(),e+=Math.PI*.5,l=MxCpp.getCurrentMxCAD(),l.zoomAngle(e);case 4:case"end":return u.stop()}},t)})),_Mx_Plan90CW.apply(this,arguments)}var dist,isDel=!1,isSourceLayer=!0;function Mx_Offset(){return _Mx_Offset.apply(this,arguments)}function _Mx_Offset(){return _Mx_Offset=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N;return regenerator.wrap(function(G){for(;;)switch(G.prev=G.next){case 0:e=new MxCADResbuf,e.AddMcDbEntityTypes("LINE,CIRCLE,LWPOLYLINE,ARC"),l=new MxCADUiPrPoint,n=!1,u=function(){var q=_asyncToGenerator(regenerator.mark(function J(){var fe,ve,ne,Ue=arguments;return regenerator.wrap(function(Ve){for(;;)switch(Ve.prev=Ve.next){case 0:fe=Ue.length>0&&Ue[0]!==void 0?Ue[0]:!1,ve=regenerator.mark(function rt(){var Ae,Te,Xe,ie,ue,pt;return regenerator.wrap(function(Tt){for(;;)switch(Tt.prev=Tt.next){case 0:if(ie=MxCADUtility.getCurrentSelect(),!(ie.length>0&&fe)){Tt.next=5;break}Xe=ie,Tt.next=8;break;case 5:return Tt.next=7,MxCADUtility.selectEnt(`
- 选择偏移对象`,e,!1,function(kt){kt.setKeyWords("[退出(E)/放弃(U)]"),Ae=kt},function(kt){Te=kt});case 7:Xe=Tt.sent;case 8:if(!Ae){Tt.next=15;break}if(!Ae.isKeyWordPicked("E")){Tt.next=11;break}return Tt.abrupt("return",{v:void 0});case 11:if(!Ae.isKeyWordPicked("U")){Tt.next=13;break}return Tt.abrupt("return",0);case 13:if(Ae.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){Tt.next=15;break}return Tt.abrupt("return",{v:void 0});case 15:if(Xe.length!=0){Tt.next=17;break}return Tt.abrupt("return",0);case 17:ue=regenerator.mark(function kt(){var It,nn,tn,pn;return regenerator.wrap(function(Dn){for(;;)switch(Dn.prev=Dn.next){case 0:return l.setDynamicInputType(DynamicInputType.kXYCoordInput),fe?l.setMessage(`
- 指定通过点`+(n?" <下一个对象>":"")):l.setMessage(`
- 指定要偏移那一侧上的点`),l.setKeyWords(n?"[退出(E)/放弃(U)]":"[退出(E)/多个(M)/放弃(U)]"),l.disableAllTrace(),l.setUserDraw(function(an,Rn){var Lt=Xe.map(function(Xr){return Xr.clone()}),wn=Lt[0];if(wn){var hn=dist;if(fe){var xn=wn.getClosestPointTo(an,!0);if(!xn.ret)return;Te=xn.val,hn=an.distanceTo(Te)}if(hn){var $n=wn.offsetCurves(hn,an);$n.empty()||$n.forEach(function(Xr){Xr instanceof McDbEntity&&Rn.drawMcDbEntity(Xr)})}}}),Dn.next=7,l.go();case 7:if(It=Dn.sent,!l.isKeyWordPicked("E")){Dn.next=10;break}return Dn.abrupt("return",{v:{v:void 0}});case 10:if(!l.isKeyWordPicked("M")){Dn.next=13;break}return n=!0,Dn.abrupt("return",0);case 13:if(!l.isKeyWordPicked("U")){Dn.next=15;break}return Dn.abrupt("return",{v:1});case 15:if(It){Dn.next=17;break}return Dn.abrupt("return",{v:{v:void 0}});case 17:if(nn=Xe[0].getMcDbCurve(),nn){Dn.next=20;break}return Dn.abrupt("return",{v:{v:void 0}});case 20:if(!fe){Dn.next=25;break}if(tn=nn.getClosestPointTo(It,!0),tn.ret){Dn.next=24;break}return Dn.abrupt("return",{v:{v:void 0}});case 24:dist=It.distanceTo(tn.val);case 25:if(dist){Dn.next=27;break}return Dn.abrupt("return",{v:{v:void 0}});case 27:if(pn=nn.offsetCurves(dist,It),!pn.empty()){Dn.next=30;break}return Dn.abrupt("return",{v:{v:void 0}});case 30:if(pn.forEach(function(an){an instanceof McDbEntity&&(isSourceLayer&&nn!==null&&nn!==void 0&&nn.layer&&(an.layer=nn.layer),isSourceLayer||(an.layer=MxCpp.getCurrentMxCAD().getDatabase().getCurrentlyLayerName()),MxCpp.getCurrentMxCAD().drawEntity(an))}),n){Dn.next=34;break}return isDel&&Xe[0].erase(!0),Dn.abrupt("return",1);case 34:case"end":return Dn.stop()}},kt)});case 19:return Tt.delegateYield(ue(),"t0",21);case 21:if(pt=Tt.t0,pt!==0){Tt.next=24;break}return Tt.abrupt("continue",19);case 24:if(pt!==1){Tt.next=26;break}return Tt.abrupt("break",30);case 26:if(!pt){Tt.next=28;break}return Tt.abrupt("return",pt.v);case 28:Tt.next=19;break;case 30:case"end":return Tt.stop()}},rt)});case 2:return Ve.delegateYield(ve(),"t0",4);case 4:if(ne=Ve.t0,ne!==0){Ve.next=7;break}return Ve.abrupt("continue",2);case 7:if(ne!==1){Ve.next=9;break}return Ve.abrupt("continue",2);case 9:if(!ne){Ve.next=11;break}return Ve.abrupt("return",ne.v);case 11:Ve.next=2;break;case 13:case"end":return Ve.stop()}},J)}));return function(){return q.apply(this,arguments)}}();case 5:return c=new MxCADUiPrDist,c.setMessage(`
- 指定偏移距离<`.concat((dist||0).toFixed(3),">")),c.setKeyWords("[通过点(T)/删除(E)/图层(L))]"),G.next=11,c.go();case 11:if(y=G.sent,!(c.isKeyWordPicked("T")||c.getStatus()===MrxDbgUiPrBaseReturn$1.kNone)){G.next=16;break}return G.next=15,u(!0);case 15:return G.abrupt("return");case 16:if(!c.isKeyWordPicked("E")){G.next=33;break}return b=new MxCADUiPrKeyWord,b.setMessage("要在偏移后删除源对象吗?<".concat(isDel?"是":"否",">")),b.setKeyWords("[是(Y)/否(N)]"),G.next=22,b.go();case 22:if(m=G.sent,b.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){G.next=25;break}return G.abrupt("return");case 25:if(b.getStatus()!==MrxDbgUiPrBaseReturn$1.kNone){G.next=27;break}return G.abrupt("continue",5);case 27:if(m?.toLocaleLowerCase()!=="y"){G.next=30;break}return isDel=!0,G.abrupt("continue",5);case 30:if(m?.toLocaleLowerCase()!=="n"){G.next=33;break}return isDel=!1,G.abrupt("continue",5);case 33:if(!c.isKeyWordPicked("L")){G.next=51;break}return O=new MxCADUiPrKeyWord,O.setMessage("输入偏移对象的图层选项<".concat(isSourceLayer?"源":"当前",">")),O.setKeyWords("[当前(C)/源(S)]"),G.next=39,O.go();case 39:if(N=G.sent,O.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){G.next=42;break}return G.abrupt("return");case 42:if(O.getStatus()!==MrxDbgUiPrBaseReturn$1.kNone){G.next=45;break}return isSourceLayer=!0,G.abrupt("continue",5);case 45:if(N?.toLocaleLowerCase()!=="c"){G.next=48;break}return isSourceLayer=!1,G.abrupt("continue",5);case 48:if(N?.toLocaleUpperCase()!=="s"){G.next=51;break}return isSourceLayer=!0,G.abrupt("continue",5);case 51:if(y&&(dist=y),dist){G.next=54;break}return G.abrupt("return");case 54:return G.next=56,u();case 56:return G.abrupt("break",59);case 59:case"end":return G.stop()}},t)})),_Mx_Offset.apply(this,arguments)}function Mx_Regen(){MxCpp.getCurrentMxCAD().regen()}function Mx_Mirror(){return _Mx_Mirror.apply(this,arguments)}function _Mx_Mirror(){return _Mx_Mirror=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N,L,G;return regenerator.wrap(function(J){for(;;)switch(J.prev=J.next){case 0:return J.next=2,MxCADUtility.userSelect("选择镜像对象");case 2:if(e=J.sent,e.length!=0){J.next=6;break}return MxFun.acutPrintf(`
- 没有能镜像的对象`),J.abrupt("return");case 6:return u=MxGetMcDbEntityBoundingBox(e),u&&(l=u.minPt,n=u.maxPt),c=new MxCADUiPrPoint,c.setMessage("指定基点"),J.next=12,c.go();case 12:if(y=J.sent,y!=null){J.next=15;break}return J.abrupt("return");case 15:return c.setMessage("指定镜向点"),c.setBasePt(y),c.setUseBasePt(!0),c.setUserDraw(function(fe,ve){if(l&&n){var ne=new McGeMatrix3d;ne.setMirror(y,fe);var Ue=new McGePoint3d(l.x,n.y,0),De=new McGePoint3d(n.x,l.y,0),Ve=new McGePoint3d(Ue.x,De.y,0),rt=new McGePoint3d(De.x,Ue.y,0);Ue.transformBy(ne),De.transformBy(ne),Ve.transformBy(ne),rt.transformBy(ne),Ue=MxCoordConvert.cad2doc(Ue),De=MxCoordConvert.cad2doc(De),Ve=MxCoordConvert.cad2doc(Ve),rt=MxCoordConvert.cad2doc(rt),ve.drawLine(rt.toVector3(),Ue.toVector3()),ve.drawLine(Ue.toVector3(),Ve.toVector3()),ve.drawLine(Ve.toVector3(),De.toVector3()),ve.drawLine(De.toVector3(),rt.toVector3())}for(var Ae=0;Ae<e.length&&Ae<10;Ae++){var Te=e[Ae].clone();Te&&(Te.mirror(y,fe),ve.drawMcDbEntity(Te))}}),c.setDynamicInputType(DynamicInputType.kXYCoordInput),J.next=22,c.go();case 22:if(b=J.sent,b){J.next=25;break}return J.abrupt("return");case 25:return m=new MxCADUiPrKeyWord,m.clearLastInputPoint(),m.setMessage("要删除源对象吗?<N>"),m.setKeyWords("[是(Y)/否(N)]"),J.next=31,m.go();case 31:if(O=J.sent,m.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){J.next=34;break}return J.abrupt("return");case 34:N=0;case 35:if(!(N<e.length)){J.next=44;break}if(L=e[N].clone(),L){J.next=39;break}return J.abrupt("continue",41);case 39:L.mirror(y,b),MxCpp.getCurrentMxCAD().drawEntity(L);case 41:N++,J.next=35;break;case 44:if(O?.toLocaleLowerCase()==="y")for(G=0;G<e.length;G++)e[G].erase();case 45:case"end":return J.stop()}},t)})),_Mx_Mirror.apply(this,arguments)}var copyAttribute=function t(e,l){e.layer=l.layer,e.trueColor=l.trueColor,e.colorIndex=l.colorIndex,e.linetype=l.linetype,e.visible=l.visible,e.textStyle=l.textStyle,e.lineweight=l.lineweight,e.drawOrder=l.drawOrder,e.linetypeScale=l.linetypeScale},isShiftKey=!1,onKeydown$1=function t(e){isShiftKey=e.shiftKey},onKeyup=function t(e){isShiftKey=e.shiftKey};window.addEventListener("keydown",onKeydown$1);window.addEventListener("keyup",onKeyup);function Mx_Chamfer(){return _Mx_Chamfer.apply(this,arguments)}function _Mx_Chamfer(){return _Mx_Chamfer=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N,L,G;return regenerator.wrap(function(J){for(;;)switch(J.prev=J.next){case 0:e=Number(localStorage.getItem("mx_chamfer_dist")),l=Number(localStorage.getItem("mx_chamfer_dist1")),typeof e!="number"&&(e=0),typeof l!="number"&&(l=0),n=0,u=0,c=!1,y=!0,b=!1,MxFun.acutPrintf(`
- (`.concat(y?"修剪":"不修剪","模式) 当前").concat(c?"倒角长度 = "+e.toFixed(4)+", 角度 = "+Math.trunc(u/(Math.PI/180)):"倒角距离1 = "+e.toFixed(4)+", 距离2 = "+l.toFixed(4),`
- `)),m=function(){var fe=_asyncToGenerator(regenerator.mark(function ve(){var ne,Ue,De;return regenerator.wrap(function(rt){for(;;)switch(rt.prev=rt.next){case 0:return ne=new MxCADUiPrDist,ne.setDynamicInputType(DynamicInputType.kXYCoordInput),ne.setMessage("指定第一个倒角距离<".concat(e.toFixed(4),">")),ne.setKeyWords(""),rt.next=6,ne.go();case 6:if(Ue=rt.sent,typeof Ue=="number"){rt.next=9;break}return rt.abrupt("return");case 9:return e=Ue,ne.setMessage("指定第二个倒角距离<".concat(l.toFixed(4),">")),ne.setKeyWords(""),rt.next=14,ne.go();case 14:if(De=rt.sent,typeof De=="number"){rt.next=17;break}return rt.abrupt("return");case 17:return l=De,localStorage.setItem("mx_chamfer_dist",e.toString()),localStorage.setItem("mx_chamfer_dist1",l.toString()),c=!1,rt.abrupt("return",[e,l]);case 22:case"end":return rt.stop()}},ve)}));return function(){return fe.apply(this,arguments)}}(),O=function(){var fe=_asyncToGenerator(regenerator.mark(function ve(){var ne,Ue,De,Ve;return regenerator.wrap(function(Ae){for(;;)switch(Ae.prev=Ae.next){case 0:return ne=new MxCADUiPrDist,ne.setMessage("指定第一条直线的倒角长度<".concat(n.toFixed(4),">")),ne.setKeyWords(""),ne.clearLastInputPoint(),Ae.next=6,ne.go();case 6:if(Ue=Ae.sent,typeof Ue=="number"){Ae.next=9;break}return Ae.abrupt("return");case 9:return n=Ue,De=new MxCADUiPrAngle,De.setMessage("指定第一条直线的倒角角度<".concat(Math.trunc(u/(Math.PI/180)),">")),De.setKeyWords(""),ne.clearLastInputPoint(),Ae.next=16,De.go();case 16:if(Ve=Ae.sent,typeof Ve=="number"){Ae.next=19;break}return Ae.abrupt("return");case 19:return De.getDetailedResult()===DetailedResult.kCoordIn?u=Ve*(Math.PI/180):u=Ve,c=!0,Ae.abrupt("return",[n,u]);case 22:case"end":return Ae.stop()}},ve)}));return function(){return fe.apply(this,arguments)}}(),N=function(ve,ne,Ue,De){var Ve=ve.startPoint.clone(),rt=ne.startPoint.clone(),Ae=ne.endPoint.clone(),Te=rt.clone().addvec(rt.sub(Ve).normalize().mult(-Ue)),Xe=Te.sub(rt).rotateBy(-De).mult(-Ue),ie=Te.clone().addvec(Xe),ue=new McDbLine(Te,ie),pt=new McDbLine(rt,Ae.clone().addvec(rt.sub(Ae).normalize().mult(-Ue))),mt=ue.IntersectWith(pt,McDb.Intersect.kExtendBoth);if(!mt.isEmpty()){var Tt=mt.at(0);return Tt.distanceTo(rt)}},L=regenerator.mark(function fe(){var ve,ne,Ue,De,Ve,rt,Ae,Te,Xe,ie,ue,pt,mt,Tt,kt,It,nn,tn,pn,_n,Dn,an,Rn,Lt,wn,hn,xn,$n,Xr,ti,gn,Xn,Kn,Vn,Yn,Vr,xi,Si,qn,ia,Wi,ha,ai,Ia;return regenerator.wrap(function(An){for(;;)switch(An.prev=An.next){case 0:return ve=new MxCADUiPrEntity,ve.setDynamicInputType(DynamicInputType.kNoInput),ne=new MxCADResbuf,ne.AddMcDbEntityTypes("LINE,LWPOLYLINE"),ve.setFilter(ne),ve.setMessage("选择一条直线"),ve.setKeyWords("[放弃(U)/多段线(P)/距离(D)/角度(A)/修剪(T)/方式(E)/多个(M)]"),An.next=9,ve.go();case 9:if(Ue=An.sent,!ve.isKeyWordPicked("U")){An.next=12;break}return An.abrupt("return",0);case 12:if(!ve.isKeyWordPicked("P")){An.next=77;break}case 13:return De=new MxCADUiPrEntity,De.setDynamicInputType(DynamicInputType.kNoInput),Ve=new MxCADResbuf,Ve.AddMcDbEntityTypes("LWPOLYLINE"),De.setMessage("选择二维多段线"),De.setKeyWords("[距离(D)/角度(A)/方法(M)]"),rt=function(Nn){var fn=Nn.getMcDbEntity();if(fn instanceof McDbPolyline){var un=fn.numVerts();if(un<3)return MxFun.acutPrintf(`没有线可以形成倒角
- `);var Ln=e,hr=l;if(c){var hi=fn.getPointAt(0).val,bi=fn.getPointAt(1).val,Ra=fn.getPointAt(2).val;Ln=n;var so=N(new McDbLine(hi,bi),new McDbLine(bi,Ra),n,u);if(typeof so!="number")return MxFun.acutPrintf(`
- 倒角角度无效。`);hr=so}var Pi=new McDbPolyline;Pi.isClosed=fn.isClosed;for(var oi=[],Ni=function(zn,Un){var Gr=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,ni=zn.sub(Un).normalize().mult(Gr?-hr:-Ln),Ei=zn.clone().addvec(ni),$t=Un.sub(zn).normalize().mult(Gr?-Ln:-hr),ta=Un.clone().addvec($t);return[Ei,ta]},za=function(zn,Un){var Gr=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,ni=Ni(zn,Un,Gr),Ei=_slicedToArray$1(ni,2),$t=Ei[0],ta=Ei[1];y?(Pi.addVertexAt($t),Pi.addVertexAt(ta)):oi.push($t,ta)},ki=0;ki<un;ki++){var Aa=fn.getPointAt(ki).val,Ja=fn.getPointAt(ki+1).val;if(fn.isClosed)ki!==un-1&&za(Aa,Ja);else if(ki===0){Pi.addVertexAt(Aa);var yo=Ja.sub(Aa).normalize().mult(-Ln),ls=Ja.clone().addvec(yo);Pi.addVertexAt(Ja.clone().addvec(yo)),oi.unshift(ls)}else if(ki===un-2){var xo=Aa.sub(Ja).normalize().mult(-hr),_o=Aa.clone().addvec(xo);Pi.addVertexAt(_o),Pi.addVertexAt(Ja),oi.push(_o)}else ki!==un-1&&za(Aa,Ja,!0)}if(fn.isClosed&&za(fn.getPointAt(un-1).val,fn.getPointAt(0).val),y)return copyAttribute(Pi,fn),Pi;var Ao=[],il=[];return fn.isClosed&&oi.unshift(oi[oi.length-1]),oi.forEach(function(zr){if(Ao.push(zr),Ao.length===2){var zn=new McDbLine(Ao[0],Ao[1]);copyAttribute(zn,fn),il.push(zn),Ao=[]}}),il}},An.next=23,De.go();case 23:if(Ae=An.sent,!De.isKeyWordPicked("D")){An.next=30;break}return An.next=27,m();case 27:if(An.sent){An.next=29;break}return An.abrupt("return",{v:void 0});case 29:return An.abrupt("continue",13);case 30:if(!De.isKeyWordPicked("A")){An.next=36;break}return An.next=33,O();case 33:if(An.sent){An.next=35;break}return An.abrupt("return",{v:void 0});case 35:return An.abrupt("continue",13);case 36:if(!De.isKeyWordPicked("M")){An.next=39;break}return b=!0,An.abrupt("continue",13);case 39:if(De.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){An.next=41;break}return An.abrupt("return",{v:void 0});case 41:if(Ae){An.next=43;break}return An.abrupt("continue",13);case 43:if(Ae.isValid()){An.next=45;break}return An.abrupt("continue",13);case 45:if(Te=rt(Ae),Te){An.next=52;break}if(!b){An.next=51;break}return An.abrupt("continue",13);case 51:return An.abrupt("return",{v:void 0});case 52:if(Xe=Ae.getMcDbEntity(),Xe){An.next=59;break}if(!b){An.next=58;break}return An.abrupt("continue",13);case 58:return An.abrupt("return",{v:void 0});case 59:if(!(Te instanceof McDbPolyline)){An.next=68;break}if(Xe instanceof McDbPolyline){An.next=62;break}return An.abrupt("return",{v:void 0});case 62:for(ie=Xe.numVerts(),ue=0;ue<ie;ue++)Xe.removeVertexAt(0);for(pt=Te.numVerts(),mt=0;mt<pt;mt++)Tt=Te.getWidthsAt(mt),kt=Tt.val1,It=Tt.val2,Xe.addVertexAt(Te.getPointAt(mt).val,Te.getBulgeAt(mt),kt,It);An.next=70;break;case 68:Te.forEach(function(sa){MxCpp.getCurrentMxCAD().drawEntity(sa)}),Xe.visible=!0;case 70:if(!b){An.next=74;break}return An.abrupt("continue",13);case 74:return An.abrupt("return",{v:void 0});case 75:An.next=13;break;case 77:if(!ve.isKeyWordPicked("D")){An.next=83;break}return An.next=80,m();case 80:if(An.sent){An.next=82;break}return An.abrupt("return",{v:void 0});case 82:return An.abrupt("return",0);case 83:if(!ve.isKeyWordPicked("A")){An.next=89;break}return An.next=86,O();case 86:if(An.sent){An.next=88;break}return An.abrupt("return",{v:void 0});case 88:return An.abrupt("return",0);case 89:if(!ve.isKeyWordPicked("T")){An.next=108;break}return nn=new MxCADUiPrKeyWord,nn.setMessage("输入修剪模式选项<".concat(y?"修剪":"不修剪",">")),nn.setKeyWords("[修剪(T)/不修剪(N)]"),An.next=95,nn.go();case 95:if(tn=An.sent,nn.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){An.next=98;break}return An.abrupt("return",{v:void 0});case 98:if(nn.getStatus()!==MrxDbgUiPrBaseReturn$1.kNone){An.next=100;break}return An.abrupt("return",0);case 100:if(tn){An.next=102;break}return An.abrupt("return",{v:void 0});case 102:if(tn.toLocaleLowerCase()!=="t"){An.next=105;break}return y=!0,An.abrupt("return",0);case 105:if(tn.toLocaleLowerCase()!=="n"){An.next=108;break}return y=!1,An.abrupt("return",0);case 108:if(!ve.isKeyWordPicked("E")){An.next=127;break}return pn=new MxCADUiPrKeyWord,pn.setMessage("输入剪切方法<".concat(c?"角度":"距离",">")),pn.setKeyWords("[距离(D)/角度(A)]"),An.next=114,pn.go();case 114:if(_n=An.sent,pn.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){An.next=117;break}return An.abrupt("return",{v:void 0});case 117:if(pn.getStatus()!==MrxDbgUiPrBaseReturn$1.kNone){An.next=119;break}return An.abrupt("return",0);case 119:if(typeof _n=="string"){An.next=121;break}return An.abrupt("return",{v:void 0});case 121:if(_n.toLocaleLowerCase()!=="d"){An.next=124;break}return c=!1,An.abrupt("return",0);case 124:if(_n.toLocaleLowerCase()!=="a"){An.next=127;break}return c=!0,An.abrupt("return",0);case 127:if(!ve.isKeyWordPicked("M")){An.next=130;break}return b=!0,An.abrupt("return",0);case 130:if(ve.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){An.next=132;break}return An.abrupt("return",{v:void 0});case 132:if(Ue){An.next=134;break}return An.abrupt("return",0);case 134:if(Ue.isValid()){An.next=136;break}return An.abrupt("return",0);case 136:if(Dn=ve.pickPoint(),an=Ue.getMcDbEntity(),an){An.next=140;break}return An.abrupt("return",0);case 140:if(Rn=new MxCADResbuf,Rn.AddMcDbEntityTypes("LINE,LWPOLYLINE"),an instanceof McDbLine&&an.highlight(!0),!(an instanceof McDbPolyline)){An.next=147;break}if(Lt=selectLineSegmentFromPolylineByPoint(an,Dn,MxFun.viewCoordLong2Cad(2)),Lt){An.next=147;break}return An.abrupt("return",0);case 147:wn=!1,hn=function(Nn){wn&&(MxFun.acutPrintf(Nn),wn=!1)},xn=function(){wn=!0,an.highlight(!1)},$n=function(Nn,fn,un,Ln,hr){var hi=arguments.length>5&&arguments[5]!==void 0?arguments[5]:function(zr){MxCpp.getCurrentMxCAD().drawEntity(zr)},bi=Nn,Ra=fn,so;if(Nn instanceof McDbPolyline&&Lt){var Pi=Lt,oi=Pi.start,Ni=Pi.end;Nn=new McDbLine(oi,Ni)}var za;if(fn instanceof McDbPolyline){if(za=selectLineSegmentFromPolylineByPoint(fn,un,1),!za)return xn();var ki=za,Aa=ki.start,Ja=ki.end;fn=new McDbLine(Aa,Ja)}if(fn=fn.clone(),Nn=Nn.clone(),!fn||!Nn)return xn();if(fn instanceof McDbLine&&Nn instanceof McDbLine){if(fn.startPoint.isEqualTo(Nn.startPoint)&&fn.endPoint.isEqualTo(Nn.endPoint)){hn(`
- 图元无法用自身倒角`);return}var yo=fn.IntersectWith(Nn,McDb.Intersect.kOnBothOperands),ls=yo.isEmpty();if(!ls){var xo=yo.at(0);if((Nn.startPoint.isEqualTo(xo)||Nn.endPoint.isEqualTo(xo)||fn.startPoint.isEqualTo(xo)||fn.endPoint.isEqualTo(xo))&&Ln===0&&hr===0)return{apply:function(){}}}var _o=Nn.IntersectWith(fn,McDb.Intersect.kExtendBoth);if(_o.isEmpty()){hn(`
- 两直线平行`);return}var Ao=_o.at(0),il=function(zn,Un,Gr,ni,Ei,$t){var ta=!1;return ls?ta=Math.max(Gr.distanceTo(Ao),ni.distanceTo(Ao))<Ln&&Ln>0||Math.max(Ei.distanceTo(Ao),$t.distanceTo(Ao))<hr&&hr>0:ta=(zn?Gr.distanceTo(Ao):ni.distanceTo(Ao))<Ln&&Ln>0||(Un?Ei.distanceTo(Ao):$t.distanceTo(Ao))<hr&&hr>0,ta&&hn(`
- 倒角距离太大`),ta};return so=function(){var zn=arguments.length>0&&arguments[0]!==void 0?arguments[0]:bi,Un=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Ra,Gr=arguments.length>2&&arguments[2]!==void 0?arguments[2]:zn.getHandle()===Un.getHandle();if(zn instanceof McDbLine&&Un instanceof McDbLine){var ni=isSegmentStartCloserToPoint(zn.startPoint,zn.endPoint,Ao,Dn),Ei=isSegmentStartCloserToPoint(Un.startPoint,Un.endPoint,Ao,un);if(il(ni,Ei,zn.startPoint,zn.endPoint,Un.startPoint,Un.endPoint))return;var $t=createChamferedLinesFromSegments(zn,Un,Ao,ni,Ei,Ln,hr,y);return $t&&hi($t),!0}var ta=function(Ai,Ea,wo,to,zo,Po){var Lo=Ai.numVerts();if(Gr||(Ai.isClosed=!1),!!zo){var Wo=zo.start,ma=zo.end,$s=zo.endIndex,ao=zo.startIndex,Ps=zo.isClosed,qo=[],wl=function(Bu,hl){var vu=Bu.getBulgeAt(hl),Ku=Bu.getPointAt(hl).val,Ul=Bu.getWidthsAt(hl),ad=Ul.val1,jc=Ul.val2;return{point:Ku,bulge:vu,startWidth:ad,endWidth:jc}},yu=isSegmentStartCloserToPoint(Wo.clone(),ma.clone(),Ao,wo);if(Ea instanceof McDbLine){if(Gr){hn(`
- 同一条直线无法倒角`);return}var po=isSegmentStartCloserToPoint(Ea.startPoint.clone(),Ea.endPoint.clone(),Ao,to);if(il(yu,po,Wo,ma,Ea.startPoint,Ea.endPoint))return;var Zs=Ea.clone(),Es=createChamferedLinesFromSegments(new McDbLine(Wo.clone(),ma.clone()),Zs,Ao,yu,po,Ln,hr,y);if(yu){for(var Xl=Ps?Ai.numVerts():$s,xl=0;xl<Xl;xl++)qo.push(wl(Ai,xl));Es?y?(qo.push({point:Es.startPoint}),qo.push({point:Es.endPoint})):hi(Es):qo.push({point:Ao}),po?qo.push({point:Zs.startPoint.clone()}):qo.push({point:Zs.endPoint.clone()})}else{var jo=Ai.numVerts();if(Ps)qo.push(wl(Ai,0));else for(var ju=$s;ju<jo;ju++)qo.push(wl(Ai,ju));Es?y?(qo.unshift({point:Es.startPoint}),qo.unshift({point:Es.endPoint})):hi(Es):qo.unshift({point:Ao}),po?qo.unshift({point:Ea.startPoint.clone()}):qo.unshift({point:Ea.endPoint.clone()})}}else if(Ea instanceof McDbPolyline&&Po){var Pl=Po.start,tl=Po.end,zl=Po.startIndex,Is=Po.endIndex,al=Po.isClosed,Mn=isSegmentStartCloserToPoint(Pl,tl,Ao,to);if(il(yu,Mn,Wo,ma,Pl,tl))return;var Ur=createChamferedLinesFromSegments(new McDbLine(Wo,ma),new McDbLine(Pl,tl),Ao,yu,Mn,Ln,hr,y);if(Gr){var Gn=Ai.numVerts(),Qr=Ea.numVerts(),qi=(ao===0||ao===Gn-(Ps?1:2))&&(zl===0||zl===Qr-(al?1:2))&&Gn>(Ps||al?2:4),ga=zl-ao;if(qi)return Ur?y?ao===0||zl===0?(ao===0?(Ai.setPointAt(0,Ur.startPoint),Ps||al?Ai.addVertexAt(Ur.endPoint):Ai.setPointAt(Gn-1,Ur.endPoint)):(Ai.setPointAt(0,Ur.endPoint),Ps||al?Ai.addVertexAt(Ur.startPoint):Ai.setPointAt(Gn-1,Ur.startPoint)),Ai.isClosed=!0):y&&(Ai.setPointAt(Gn-1,Ps?Ur.endPoint:Ur.startPoint),Ai.addVertexAt(Ps?Ur.startPoint:Ur.endPoint)):hi(Ur):y&&(Ai.setPointAt(0,Ao),Ai.removeVertexAt(Gn-1),Ai.isClosed=!0),!0;if(Math.abs(ga)>2){hn(`
- 多段线中的直线必须是连续的 或被一条线段断开。`);return}else Ea=Ea.clone()}if(!(Ea instanceof McDbPolyline))return;if(yu){for(var no=0;no<=ao;no++)qo.push(wl(Ai,no));if(Ur?y?(qo.push({point:Ur.startPoint}),qo.push({point:Ur.endPoint})):hi(Ur):qo.push({point:Ao}),Mn)for(var mo=zl;mo>=0;mo--)qo.push(wl(Ea,mo));else if(al)qo.push(wl(Ea,0));else for(var Go=Ea.numVerts(),Uo=Is;Uo<Go;Uo++)qo.push(wl(Ea,Uo))}else{var Ns=Ai.numVerts();if(Ps)qo.push(wl(Ai,0));else for(var jl=$s;jl<Ns;jl++)qo.push(wl(Ai,jl));if(Ur?y?(qo.unshift({point:Ur.startPoint}),qo.unshift({point:Ur.endPoint})):hi(Ur):qo.unshift({point:Ao}),Mn)for(var Bl=zl;Bl>=0;Bl--)qo.unshift(wl(Ea,Bl));else if(al)qo.unshift(wl(Ea,0));else for(var Jl=Ea.numVerts(),mu=Is;mu<Jl;mu++)qo.unshift(wl(Ea,mu))}}else return!1;if(y){for(var Ol=0;Ol<Lo;Ol++)Ai.removeVertexAt(0);qo.forEach(function(bu){var Bu=bu.point,hl=bu.bulge,vu=bu.startWidth,Ku=bu.endWidth;Ai.addVertexAt(Bu,hl,vu,Ku)}),Ea.erase()}return!0}};return zn instanceof McDbPolyline&&Lt?ta(zn,Un,Dn,un,Lt,za):Un instanceof McDbPolyline&&za?ta(Un,zn,un,Dn,za,Lt):!1},{apply:so,line1:Nn,line2:fn}}},ve.setUserDraw(function(sa,Nn){var fn=an.clone(),un=MxCADUtility.findEntAtPoint(sa.x,sa.y,sa.z,-1,Rn);if(!un||!un.isValid())return xn();var Ln=un.getMcDbEntity();if(!Ln)return xn();var hr=Ln?.clone();if(!hr)return xn();var hi=$n(fn,hr,sa,isShiftKey?0:e,isShiftKey?0:l,function(za){Nn.drawMcDbEntity(za)})||{},bi=hi.line1,Ra=hi.line2,so=hi.apply,Pi=so&&so(fn,hr,an.getHandle()===Ln.getHandle());if(bi&&Ra&&Pi){fn.drawOrder=an.drawOrder+Ln.drawOrder+102,bi.drawOrder=an.drawOrder+Ln.drawOrder+101,Ra.drawOrder=an.drawOrder+Ln.drawOrder+101;var oi=new THREE.Color(Number(an.trueColor.getColorValue(an.layerId))),Ni=oi.clone();y&&(darkenColor(Ni,.5),Nn.setColor(Ni)),Nn.drawMcDbEntity(bi),Nn.drawMcDbEntity(Ra),Nn.setColor(oi),Nn.drawMcDbEntity(fn)}});case 152:return ve.setMessage("选择第二条直线,或按住shift键选择直线以应用角点"),ve.setKeyWords("[距离(D)/角度(A)/方法(M)]"),An.next=157,ve.go();case 157:if(Xr=An.sent,!ve.isKeyWordPicked("D")){An.next=164;break}return An.next=161,m();case 161:if(An.sent){An.next=163;break}return An.abrupt("return",{v:void 0});case 163:return An.abrupt("continue",152);case 164:if(!ve.isKeyWordPicked("A")){An.next=170;break}return An.next=167,O();case 167:if(An.sent){An.next=169;break}return An.abrupt("return",{v:void 0});case 169:return An.abrupt("continue",152);case 170:if(!ve.isKeyWordPicked("M")){An.next=173;break}return b=!0,An.abrupt("continue",152);case 173:if(ve.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){An.next=175;break}return An.abrupt("return",{v:void 0});case 175:if(Xr){An.next=177;break}return An.abrupt("return",{v:xn()});case 177:if(Xr.isValid()){An.next=179;break}return An.abrupt("return",{v:xn()});case 179:if(ti=Xr.getMcDbEntity(),ti){An.next=182;break}return An.abrupt("return",{v:xn()});case 182:if(gn=an,Xn=ve.pickPoint(),Kn=gn.clone(),Kn){An.next=191;break}if(!b){An.next=190;break}return An.abrupt("continue",152);case 190:return An.abrupt("return",{v:xn()});case 191:if(Vn=gn.clone(),Vn){An.next=198;break}if(!b){An.next=197;break}return An.abrupt("continue",152);case 197:return An.abrupt("return",{v:xn()});case 198:if(Yn=Kn.IntersectWith(Vn,McDb.Intersect.kOnBothOperands),!Yn.isEmpty()){An.next=205;break}if(!b){An.next=204;break}return An.abrupt("continue",152);case 204:return An.abrupt("return",{v:xn()});case 205:if(Vr=e,xi=l,!c){An.next=219;break}if(Si=Yn.at(0),qn=N(new McDbLine(Dn,Si),new McDbLine(Si,Xn),n,u),typeof qn=="number"){An.next=217;break}if(MxFun.acutPrintf(`
- 倒角角度无效。`),!b){An.next=216;break}return An.abrupt("continue",152);case 216:return An.abrupt("return",{v:xn()});case 217:Vr=n,xi=qn;case 219:if(ia=$n(gn,ti,Xn,isShiftKey?0:Vr,isShiftKey?0:xi)||{},Wi=ia.line1,ha=ia.line2,ai=ia.apply,!(Wi&&ha&&areLinesCollinear(Wi,ha))){An.next=223;break}return MxFun.acutPrintf("共线直线不能为 倒角。"),An.abrupt("return",{v:xn()});case 223:if(!ai){An.next=232;break}if(Ia=ai(),!(b&&typeof Ia>"u")){An.next=229;break}return An.abrupt("continue",152);case 229:return An.abrupt("break",240);case 230:An.next=238;break;case 232:if(MxCpp.App.MxCADAssist.MxChamfer(Ue.id,Xr.id,Dn.x,Dn.y,Xn.x,Xn.y,Vr,xi,y),!b){An.next=237;break}return An.abrupt("continue",152);case 237:return An.abrupt("break",240);case 238:An.next=152;break;case 240:if(an instanceof McDbLine&&an.highlight(!1),!b){An.next=245;break}return An.abrupt("return",0);case 245:return xn(),An.abrupt("return",1);case 247:case"end":return An.stop()}},fe)});case 14:return J.delegateYield(L(),"t0",16);case 16:if(G=J.t0,G!==0){J.next=19;break}return J.abrupt("continue",14);case 19:if(G!==1){J.next=21;break}return J.abrupt("break",25);case 21:if(!G){J.next=23;break}return J.abrupt("return",G.v);case 23:J.next=14;break;case 25:case"end":return J.stop()}},t)})),_Mx_Chamfer.apply(this,arguments)}function Mx_Fillet(){return _Mx_Fillet.apply(this,arguments)}function _Mx_Fillet(){return _Mx_Fillet=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m;return regenerator.wrap(function(N){for(;;)switch(N.prev=N.next){case 0:e=Number(localStorage.getItem("Mx_Fillet_radius"))||0,l=localStorage.getItem("Mx_Fillet_isPruning")!=="false",n=!1,MxFun.acutPrintf(`
- 当前设置: 模式 = `.concat(l?"修剪":"不修剪",", 半径 = ").concat(e.toFixed(4))),u=function(){var L=_asyncToGenerator(regenerator.mark(function G(){var q,J;return regenerator.wrap(function(ve){for(;;)switch(ve.prev=ve.next){case 0:return q=new MxCADUiPrDist,q.setDynamicInputType(DynamicInputType.kDistanceInput),q.setKeyWords("指定圆角半径<".concat(e.toFixed(4),">")),ve.next=5,q.go();case 5:if(J=ve.sent,q.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){ve.next=8;break}return ve.abrupt("return");case 8:if(q.getStatus()!==MrxDbgUiPrBaseReturn$1.kNone){ve.next=10;break}return ve.abrupt("return",e);case 10:if(typeof J=="number"){ve.next=12;break}return ve.abrupt("return");case 12:return e=J,localStorage.setItem("Mx_Fillet_radius",e.toString()),ve.abrupt("return",e);case 15:case"end":return ve.stop()}},G)}));return function(){return L.apply(this,arguments)}}(),c=new MxCADUiPrEntity,y=new MxCADResbuf,y.AddMcDbEntityTypes("LINE,LWPOLYLINE"),b=regenerator.mark(function L(){var G,q,J,fe,ve,ne,Ue,De,Ve,rt,Ae,Te,Xe,ie,ue,pt,mt,Tt,kt,It,nn,tn,pn,_n;return regenerator.wrap(function(an){for(;;)switch(an.prev=an.next){case 0:return c.setDynamicInputType(DynamicInputType.kNoInput),c.setFilter(y),c.setMessage("选择第一个对象"),c.setKeyWords("[放弃(U)/多段线(P)/半径(R)/修剪(T)/多个(M)]"),an.next=6,c.go();case 6:if(G=an.sent,c.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){an.next=9;break}return an.abrupt("return",{v:void 0});case 9:if(!c.isKeyWordPicked("U")){an.next=11;break}return an.abrupt("return",0);case 11:if(!c.isKeyWordPicked("P")){an.next=24;break}q=regenerator.mark(function Rn(){var Lt,wn,hn,xn,$n,Xr,ti,gn,Xn,Kn,Vn,Yn,Vr,xi,Si,qn,ia,Wi,ha,ai,Ia,fi,An,sa,Nn,fn,un;return regenerator.wrap(function(hr){for(;;)switch(hr.prev=hr.next){case 0:return c.setMessage("选择二维多段线"),c.setKeyWords("[半径(R)]"),Lt=new MxCADResbuf,Lt.AddMcDbEntityTypes("LWPOLYLINE"),c.setFilter(Lt),hr.next=7,c.go();case 7:if(wn=hr.sent,c.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){hr.next=10;break}return hr.abrupt("return",{v:{v:void 0}});case 10:if(!c.isKeyWordPicked("R")){hr.next=17;break}return hr.next=13,u();case 13:if(hr.t0=_typeof$2(hr.sent),hr.t0==="number"){hr.next=16;break}return hr.abrupt("return",{v:{v:void 0}});case 16:return hr.abrupt("return",0);case 17:if(wn){hr.next=19;break}return hr.abrupt("return",{v:{v:void 0}});case 19:if(wn.isValid()){hr.next=21;break}return hr.abrupt("return",{v:{v:void 0}});case 21:if(hn=wn.getMcDbEntity(),hn instanceof McDbPolyline){hr.next=24;break}return hr.abrupt("return",{v:{v:void 0}});case 24:xn=hn.numVerts(),$n=0,Xr=0,ti=[],hn.isClosed||xn--;case 29:if(!($n<xn)){hr.next=82;break}if($n++,Xr>xn-1&&(Xr=0),gn=hn.getPointAt(Xr),Xn=gn.val,Xn){hr.next=39;break}if(!n){hr.next=38;break}return hr.abrupt("return",1);case 38:return hr.abrupt("return",{v:{v:void 0}});case 39:if(Xr++,Xr>xn-1&&(Xr=0),Kn=hn.getPointAt(Xr),Vn=Kn.val,Vn){hr.next=48;break}if(!n){hr.next=47;break}return hr.abrupt("return",1);case 47:return hr.abrupt("return",{v:{v:void 0}});case 48:if(Xr++,Xr>xn-1&&(Xr=0),Yn=hn.getPointAt(Xr),Vr=Yn.val,Vr){hr.next=57;break}if(!n){hr.next=56;break}return hr.abrupt("return",1);case 56:return hr.abrupt("return",{v:{v:void 0}});case 57:if(Xr=$n,xi=createLineSegmentRoundJoin(e,new McDbLine(Xn,Vn),new McDbLine(Vn,Vr),Vn,!0,!1,l),xi){hr.next=61;break}return hr.abrupt("return",{v:{v:console.log("两直线平行")}});case 61:if(Si=xi.arc,qn=xi.segmentLine,ia=xi.bulge,qn){hr.next=64;break}return hr.abrupt("return",{v:{v:void 0}});case 64:if(!l){hr.next=78;break}if(Wi=hn.getWidthsAt($n),ha=Wi.ret,ai=Wi.val1,Ia=Wi.val2,ha){hr.next=74;break}if(!hn.isClosed){hr.next=73;break}if(fi=hn.getWidthsAt(0),An=fi.ret,sa=fi.val1,Nn=fi.val2,An){hr.next=71;break}return hr.abrupt("continue",29);case 71:ti.push({width:sa,width1:Nn,bulge:ia,point:qn.startPoint}),ti.unshift({width:sa,width1:Nn,bulge:hn.getBulgeAt(0),point:qn.endPoint});case 73:return hr.abrupt("continue",29);case 74:ti.push({width:ai,width1:Ia,bulge:ia,point:qn.startPoint}),ti.push({width:ai,width1:Ia,bulge:hn.getBulgeAt($n),point:qn.endPoint}),hr.next=80;break;case 78:copyAttribute(Si,hn),MxCpp.getCurrentMxCAD().drawEntity(Si);case 80:hr.next=29;break;case 82:if(l){for(fn=hn.numVerts(),un=0;un<fn;un++)hn.removeVertexAt(0);ti.forEach(function(hi){var bi=hi.point,Ra=hi.bulge,so=hi.width,Pi=hi.width1;hn.addVertexAt(bi,Ra,so,Pi)})}if(!n){hr.next=87;break}return hr.abrupt("return",0);case 87:return hr.abrupt("return",{v:{v:void 0}});case 88:case"end":return hr.stop()}},Rn)});case 13:return an.delegateYield(q(),"t0",15);case 15:if(J=an.t0,J!==0){an.next=18;break}return an.abrupt("continue",13);case 18:if(J!==1){an.next=20;break}return an.abrupt("continue",13);case 20:if(!J){an.next=22;break}return an.abrupt("return",J.v);case 22:an.next=13;break;case 24:if(!c.isKeyWordPicked("R")){an.next=31;break}return an.next=27,u();case 27:if(an.t1=_typeof$2(an.sent),an.t1==="number"){an.next=30;break}return an.abrupt("return",{v:void 0});case 30:return an.abrupt("return",0);case 31:if(!c.isKeyWordPicked("T")){an.next=53;break}return fe=new MxCADUiPrKeyWord,fe.setDynamicInputType(DynamicInputType.kNoInput),fe.setMessage("输入剪切模式选项<".concat(l?"修剪":"不修剪",">")),fe.setKeyWords("[修剪(T)/不修剪(N)]"),an.next=38,fe.go();case 38:if(ve=an.sent,fe.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){an.next=41;break}return an.abrupt("return",{v:void 0});case 41:if(fe.getStatus()!==MrxDbgUiPrBaseReturn$1.kNone){an.next=43;break}return an.abrupt("return",0);case 43:if(typeof ve=="string"){an.next=45;break}return an.abrupt("return",{v:void 0});case 45:if(ve.toLocaleLowerCase()!=="t"){an.next=49;break}return l=!0,localStorage.setItem("Mx_Fillet_isPruning","true"),an.abrupt("return",0);case 49:if(ve.toLocaleLowerCase()!=="n"){an.next=53;break}return l=!1,localStorage.setItem("Mx_Fillet_isPruning","false"),an.abrupt("return",0);case 53:if(!c.isKeyWordPicked("M")){an.next=56;break}return n=!0,an.abrupt("return",0);case 56:if(G){an.next=58;break}return an.abrupt("return",0);case 58:if(G.isValid()){an.next=60;break}return an.abrupt("return",0);case 60:if(ne=c.pickPoint(),Ue=new MxCADResbuf,Ue.AddMcDbEntityTypes("LINE,LWPOLYLINE"),De=new MxCADUiPrEntity,De.setFilter(Ue),Ve=G.getMcDbEntity(),Ve){an.next=68;break}return an.abrupt("return",0);case 68:if(Ve instanceof McDbLine&&Ve.highlight(!0),!(Ve instanceof McDbPolyline)){an.next=73;break}if(rt=selectLineSegmentFromPolylineByPoint(Ve,ne,MxFun.viewCoordLong2Cad(2)),rt){an.next=73;break}return an.abrupt("return",0);case 73:Ae=new MxCADUiPrEntity,Ae.setFilter(Ue),Te=!1,Xe=function(Lt){Te&&(MxFun.acutPrintf(Lt),Te=!1)},ie=function(){Te=!0,Ve.highlight(!1)},ue=function(Lt,wn,hn){var xn=arguments.length>3&&arguments[3]!==void 0?arguments[3]:function(Ia){MxCpp.getCurrentMxCAD().drawEntity(Ia)},$n=Lt,Xr=wn,ti;if(Lt instanceof McDbPolyline&&rt){var gn=rt,Xn=gn.start,Kn=gn.end;Lt=new McDbLine(Xn,Kn)}var Vn;if(wn instanceof McDbPolyline){if(Vn=selectLineSegmentFromPolylineByPoint(wn,hn,1),!Vn)return ie();var Yn=Vn,Vr=Yn.start,xi=Yn.end;wn=new McDbLine(Vr,xi)}if(wn=wn.clone(),Lt=Lt.clone(),!wn||!Lt)return ie();if(wn instanceof McDbLine&&Lt instanceof McDbLine){if(wn.startPoint.isEqualTo(Lt.startPoint)&&wn.endPoint.isEqualTo(Lt.endPoint)){Xe(`
- 图元无法用自身倒角`);return}var Si=wn.IntersectWith(Lt,McDb.Intersect.kOnBothOperands),qn=Si.isEmpty();if(!qn){var ia=Si.at(0);if((Lt.startPoint.isEqualTo(ia)||Lt.endPoint.isEqualTo(ia)||wn.startPoint.isEqualTo(ia)||wn.endPoint.isEqualTo(ia))&&e===0)return{apply:function(){}}}var Wi=Lt.IntersectWith(wn,McDb.Intersect.kExtendBoth);if(Wi.isEmpty()){Xe(`
- 两直线平行`);return}var ha=Wi.at(0),ai=function(fi,An,sa,Nn,fn,un,Ln){var hr=!1;return qn?hr=Math.max(sa.distanceTo(ha),Nn.distanceTo(ha))<Ln&&Ln>0||Math.max(fn.distanceTo(ha),un.distanceTo(ha))<Ln&&Ln>0:hr=(fi?sa.distanceTo(ha):Nn.distanceTo(ha))<Ln&&Ln>0||(An?fn.distanceTo(ha):un.distanceTo(ha))<Ln&&Ln>0,hr&&Xe(`
- 倒角距离太大`),hr};return ti=function(){var fi=arguments.length>0&&arguments[0]!==void 0?arguments[0]:$n,An=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Xr,sa=arguments.length>2&&arguments[2]!==void 0?arguments[2]:fi.getHandle()===An.getHandle();if(fi instanceof McDbLine&&An instanceof McDbLine){var Nn=isSegmentStartCloserToPoint(fi.startPoint,fi.endPoint,ha,ne),fn=isSegmentStartCloserToPoint(An.startPoint,An.endPoint,ha,hn),un=createLineSegmentRoundJoin(e,fi,An,ha,Nn,fn,l,isShiftKey);if(!un){Xe(`
- 直线平行`);return}var Ln=un.arc,hr=un.chamferDist;return ai(Nn,fn,fi.startPoint,fi.endPoint,An.startPoint,An.endPoint,hr)?void 0:(Ln&&xn(Ln),!0)}var hi=function(Ra,so,Pi,oi,Ni,za){var ki=Ra.numVerts();if(sa||(Ra.isClosed=!1),!!Ni){var Aa=Ni.start,Ja=Ni.end,yo=Ni.endIndex,ls=Ni.startIndex,xo=Ni.isClosed,_o=[],Ao=function(Ur,Gn){var Qr=Ur.getBulgeAt(Gn),qi=Ur.getPointAt(Gn).val,ga=Ur.getWidthsAt(Gn),no=ga.val1,mo=ga.val2;return{point:qi,bulge:Qr,startWidth:no,endWidth:mo}},il=isSegmentStartCloserToPoint(Aa.clone(),Ja.clone(),ha,Pi);if(so instanceof McDbLine){if(sa){Xe(`
- 同一条直线无法倒角`);return}var zr=isSegmentStartCloserToPoint(so.startPoint.clone(),so.endPoint.clone(),ha,oi),zn=so.clone(),Un=createLineSegmentRoundJoin(e,new McDbLine(Aa.clone(),Ja.clone()),zn,ha,il,zr,l,isShiftKey);if(!Un){Xe(`
- 直线平行`);return}var Gr=Un.chamferDist,ni=Un.bulge,Ei=Un.segmentLine,$t=Un.arc;if(ai(il,zr,Aa,Ja,so.startPoint,so.endPoint,Gr))return;if(il){for(var ta=xo?Ra.numVerts():yo,Hi=0;Hi<ta;Hi++)_o.push(Ao(Ra,Hi));Ei?l?(_o.push({point:Ei.startPoint,bulge:ni}),_o.push({point:Ei.endPoint})):xn($t):_o.push({point:ha}),zr?_o.push({point:zn.startPoint.clone()}):_o.push({point:zn.endPoint.clone()})}else{var Ai=Ra.numVerts();if(xo)_o.push(Ao(Ra,0));else for(var Ea=yo;Ea<Ai;Ea++)_o.push(Ao(Ra,Ea));Ei?l?(_o.unshift({point:Ei.startPoint}),_o.unshift({point:Ei.endPoint,bulge:-ni})):xn(Ei):_o.unshift({point:ha}),zr?_o.unshift({point:so.startPoint.clone()}):_o.unshift({point:so.endPoint.clone()})}}else if(so instanceof McDbPolyline&&za){var wo=za.start,to=za.end,zo=za.startIndex,Po=za.endIndex,Lo=za.isClosed,Wo=isSegmentStartCloserToPoint(wo,to,ha,oi),ma=createLineSegmentRoundJoin(e,new McDbLine(Aa,Ja),new McDbLine(wo,to),ha,il,Wo,l,isShiftKey);if(!ma){Xe(`
- 直线平行`);return}var $s=ma.arc,ao=ma.segmentLine,Ps=ma.bulge,qo=ma.chamferDist;if(ai(il,Wo,Aa,Ja,wo,to,qo))return;if(sa){var wl=Ra.numVerts(),yu=so.numVerts(),po=(ls===0||ls===wl-(xo?1:2))&&(zo===0||zo===yu-(Lo?1:2))&&wl>(xo||Lo?2:4),Zs=zo-ls;if(po)return ao?l?ls===0||zo===0?(ls===0?(console.log("start1"),Ra.setPointAt(0,ao.startPoint),xo||Lo?Ra.addVertexAt(ao.endPoint,-Ps):(Ra.setPointAt(wl-1,ao.endPoint),Ra.setBulgeAt(wl-1,Ps))):(Ra.setPointAt(0,ao.endPoint),xo||Lo?Ra.addVertexAt(ao.startPoint,Ps):(Ra.setPointAt(wl-1,ao.startPoint),Ra.setBulgeAt(wl-1,Ps))),Ra.isClosed=!0):l&&(Ra.setPointAt(wl-1,xo?ao.endPoint:ao.startPoint),Ra.setBulgeAt(wl-1,xo?-Ps:Ps),Ra.addVertexAt(xo?ao.startPoint:ao.endPoint)):xn($s):l&&(Ra.setPointAt(0,ha),Ra.removeVertexAt(wl-1),Ra.isClosed=!0),!0;if(Math.abs(Zs)>2){Xe(`
- 多段线中的直线必须是连续的 或被一条线段断开。`);return}else so=so.clone()}if(!(so instanceof McDbPolyline))return;if(il){for(var Es=0;Es<=ls;Es++)_o.push(Ao(Ra,Es));if(ao?l?(_o.push({point:ao.startPoint,bulge:Ps}),_o.push({point:ao.endPoint})):xn($s):_o.push({point:ha}),Wo)for(var Xl=zo;Xl>=0;Xl--)_o.push(Ao(so,Xl));else if(Lo)_o.push(Ao(so,0));else for(var xl=so.numVerts(),jo=Po;jo<xl;jo++)_o.push(Ao(so,jo))}else{var ju=Ra.numVerts();if(xo)_o.push(Ao(Ra,0));else for(var Pl=yo;Pl<ju;Pl++)_o.push(Ao(Ra,Pl));if(ao?l?(_o.unshift({point:ao.startPoint}),_o.unshift({point:ao.endPoint,bulge:-Ps})):xn($s):_o.unshift({point:ha}),Wo)for(var tl=zo;tl>=0;tl--)_o.unshift(Ao(so,tl));else if(Lo)_o.unshift(Ao(so,0));else for(var zl=so.numVerts(),Is=Po;Is<zl;Is++)_o.unshift(Ao(so,Is))}}else return!1;if(l){for(var al=0;al<ki;al++)Ra.removeVertexAt(0);_o.forEach(function(Mn){var Ur=Mn.point,Gn=Mn.bulge,Qr=Mn.startWidth,qi=Mn.endWidth;Ra.addVertexAt(Ur,Gn,Qr,qi)}),so.erase()}return!0}};return fi instanceof McDbPolyline&&rt?hi(fi,An,ne,hn,rt,Vn):An instanceof McDbPolyline&&Vn?hi(An,fi,hn,ne,Vn,rt):!1},{apply:ti,line1:Lt,line2:wn}}},Ae.setUserDraw(function(Rn,Lt){var wn=Ve.clone(),hn=MxCADUtility.findEntAtPoint(Rn.x,Rn.y,Rn.z,-1,Ue);if(!hn||!hn.isValid())return ie();var xn=hn.getMcDbEntity();if(!xn)return ie();var $n=xn?.clone();if(!$n)return ie();var Xr=ue(wn,$n,Rn,function(Vr){console.log(121),Lt.drawMcDbEntity(Vr)})||{},ti=Xr.line1,gn=Xr.line2,Xn=Xr.apply,Kn=Xn&&Xn(wn,$n,Ve.getHandle()===xn.getHandle());if(ti&&gn&&Kn){wn.drawOrder=Ve.drawOrder+xn.drawOrder+102,ti.drawOrder=Ve.drawOrder+xn.drawOrder+101,gn.drawOrder=Ve.drawOrder+xn.drawOrder+101;var Vn=new THREE.Color(Number(Ve.trueColor.getColorValue(Ve.layerId))),Yn=Vn.clone();l&&(darkenColor(Yn,.5),Lt.setColor(Yn)),Lt.drawMcDbEntity(ti),Lt.drawMcDbEntity(gn),Lt.setColor(Vn),Lt.drawMcDbEntity(wn)}});case 80:return Ae.setMessage("选择第二条直线"),Ae.setKeyWords("[半径(R)]"),an.next=85,Ae.go();case 85:if(pt=an.sent,!Ae.isKeyWordPicked("R")){an.next=93;break}return an.next=89,u();case 89:if(an.t2=_typeof$2(an.sent),an.t2==="number"){an.next=92;break}return an.abrupt("return",{v:void 0});case 92:return an.abrupt("continue",80);case 93:if(pt){an.next=95;break}return an.abrupt("return",{v:ie()});case 95:if(pt.isValid()){an.next=97;break}return an.abrupt("return",{v:ie()});case 97:if(mt=pt.getMcDbEntity(),mt){an.next=100;break}return an.abrupt("return",{v:ie()});case 100:if(Tt=Ve,kt=Ae.pickPoint(),It=ue(Tt,mt,kt)||{},nn=It.line1,tn=It.line2,pn=It.apply,!(nn&&tn&&areLinesCollinear(nn,tn))){an.next=106;break}return MxFun.acutPrintf("共线直线不能为 倒圆角角。"),an.abrupt("return",{v:ie()});case 106:if(!pn){an.next=115;break}if(_n=pn(),!(n&&typeof _n>"u")){an.next=112;break}return an.abrupt("continue",80);case 112:return an.abrupt("break",123);case 113:an.next=121;break;case 115:if(MxCpp.App.MxCADAssist.MxFillet(G.id,pt.id,ne.x,ne.y,kt.x,kt.y,e,l),!n){an.next=120;break}return an.abrupt("continue",80);case 120:return an.abrupt("break",123);case 121:an.next=80;break;case 123:if(ie(),!n){an.next=128;break}return an.abrupt("return",0);case 128:return an.abrupt("return",1);case 129:case"end":return an.stop()}},L)});case 9:return N.delegateYield(b(),"t0",11);case 11:if(m=N.t0,m!==0){N.next=14;break}return N.abrupt("continue",9);case 14:if(m!==1){N.next=16;break}return N.abrupt("break",20);case 16:if(!m){N.next=18;break}return N.abrupt("return",m.v);case 18:N.next=9;break;case 20:case"end":return N.stop()}},t)})),_Mx_Fillet.apply(this,arguments)}var getHurdleSelectionPoints=function(){var t=_asyncToGenerator(regenerator.mark(function e(){var l,n,u,c;return regenerator.wrap(function(b){for(;;)switch(b.prev=b.next){case 0:l=[];case 1:return n=new MxCADUiPrPoint,n.setMessage(l.length===0?"指定第一个栏选点":"指定下一个栏选点"),n.setKeyWords(l.length===0?"":"[放弃(U)]"),n.setUserDraw(function(m,O){var N=new McDbPolyline;l.forEach(function(L){N.addVertexAt(L)}),N.addVertexAt(m),O.drawMcDbEntity(N)}),b.next=8,n.go();case 8:if(u=b.sent,!n.isKeyWordPicked("U")){b.next=13;break}return c=l.pop(),c&&n.setLastInputPoint(c),b.abrupt("continue",1);case 13:if(n.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){b.next=15;break}return b.abrupt("return",!1);case 15:if(n.getStatus()!==MrxDbgUiPrBaseReturn$1.kNone){b.next=17;break}return b.abrupt("break",22);case 17:if(u){b.next=19;break}return b.abrupt("return",l);case 19:l.push(u),b.next=1;break;case 22:return b.abrupt("return",l);case 23:case"end":return b.stop()}},e)}));return function(){return t.apply(this,arguments)}}();function Mx_Trim(){return _Mx_Trim.apply(this,arguments)}function _Mx_Trim(){return _Mx_Trim=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N,L,G,q,J,fe;return regenerator.wrap(function(ne){for(;;)switch(ne.prev=ne.next){case 0:if(e=!1,l=!1,n=[],u=new MxCADResbuf,u.AddMcDbEntityTypes("LINE,LWPOLYLINE,ELLIPSE,ARC,CIRCLE,SPLINE,XLINE"),b=MxCADUtility.getCurrentSelect(u),b.length!==0){ne.next=16;break}return ne.next=10,MxCADUtility.userSelect("选择对象或<全部选择>",u,function(Ue,De){c=De,y=Ue});case 10:if(b=ne.sent,c.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){ne.next=13;break}return ne.abrupt("return");case 13:if(c.getStatus()===MrxDbgUiPrBaseReturn$1.kNone&&b.length===0&&(y.allSelect(u),y.forEach(function(Ue){b.push(Ue)})),b.length!==0){ne.next=16;break}return ne.abrupt("return");case 16:if(m=new McGeLongArray,m.copyFormAryId(b),O=new MxCpp.mxcadassemblyimp.MxDrawTrimAssist,O.Init(m.imp)){ne.next=21;break}return ne.abrupt("return");case 21:if(N=new MxCpp.mxcadassemblyimp.MxDrawExtendAssist,N.Init(m.imp)){ne.next=24;break}return ne.abrupt("return");case 24:L=!1,G=function(De){L=De.key==="Shift"},window.addEventListener("keydown",G),q=function(){return L=!1},window.addEventListener("keyup",q),J=regenerator.mark(function Ue(){var De,Ve,rt,Ae,Te,Xe,ie,ue,pt,mt,Tt,kt,It,nn,tn,pn,_n;return regenerator.wrap(function(an){for(;;)switch(an.prev=an.next){case 0:return De=new MxCADSelectionSet,De.isWhileSelect=!1,De.isSelectHighlight=!1,an.next=5,De.userSelect("选择要修剪的对象或按住 Shift 键选择要延伸的对象",u,function(Rn){Ve=Rn,Ve.setKeyWords("[栏选(F)/窗交(C)/边(E)/删除(R)".concat(n.length>0?"/放弃(U)":"","]"))});case 5:if(an.sent){an.next=7;break}return an.abrupt("return",0);case 7:if(!Ve.isKeyWordPicked("F")){an.next=18;break}return an.next=10,getHurdleSelectionPoints();case 10:if(rt=an.sent,rt){an.next=13;break}return an.abrupt("return",0);case 13:return Ae=new McDbPolyline,rt.forEach(function(Rn){Ae.addVertexAt(Rn)}),n.push([b,b.map(function(Rn){return Rn.clone()})]),b.forEach(function(Rn){var Lt=Rn.getMcDbEntity();if(Lt instanceof McDbCurve){var wn=Lt.IntersectWith(Ae,McDb.Intersect.kOnBothOperands);wn.isEmpty()||wn.forEach(function(hn){m.copyFormAryId([Rn]),L?N.DoExtend(m.imp,hn.x,hn.y,hn.x,hn.y):O.DoTrim(m.imp,hn.x,hn.y,hn.x,hn.y)})}}),an.abrupt("return",1);case 18:if(!Ve.isKeyWordPicked("C")){an.next=21;break}return e=!0,an.abrupt("return",1);case 21:if(!Ve.isKeyWordPicked("E")){an.next=39;break}return Te=new MxCADUiPrKeyWord,Te.setMessage("指定隐含边延伸模式<".concat(l?"延伸":"不延伸",">")),Te.setKeyWords("[延伸(E)/不延伸(N)]"),an.next=27,Te.go();case 27:if(Xe=Te.keyWordPicked(),Te.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){an.next=30;break}return an.abrupt("return",{v:void 0});case 30:if(Te.getStatus()!==MrxDbgUiPrBaseReturn$1.kNone){an.next=32;break}return an.abrupt("return",1);case 32:if(Te.getStatus()!==MrxDbgUiPrBaseReturn$1.kKeyWord){an.next=39;break}if(Xe!=="E"){an.next=36;break}return l=!0,an.abrupt("return",1);case 36:if(Xe!=="N"){an.next=39;break}return l=!1,an.abrupt("return",1);case 39:if(!Ve.isKeyWordPicked("R")){an.next=46;break}return an.next=42,MxCADUtility.userSelect("选择要删除的对象",u);case 42:return ie=an.sent,n.push([ie,ie.map(function(Rn){return Rn.clone()})]),ie.forEach(function(Rn){Rn.erase()}),an.abrupt("return",1);case 46:if(!Ve.isKeyWordPicked("U")){an.next=52;break}return ue=n.pop()||[],pt=_slicedToArray$1(ue,2),mt=pt[0],Tt=pt[1],mt?.forEach(function(Rn){Rn.erase()}),kt=MxCpp.getCurrentMxCAD(),Tt?.forEach(function(Rn){Rn instanceof McDbEntity&&kt.drawEntity(Rn)}),an.abrupt("return",1);case 52:if(It=De.getIds(),It.length!=0){an.next=55;break}return an.abrupt("return",1);case 55:if(nn=De.getSelectPoint(),!e){an.next=67;break}return tn=nn.pt1,pn=nn.pt2,_n=new McDbPolyline,_n.addVertexAt(tn),_n.addVertexAt(new McGePoint3d(tn.x,pn.y)),_n.addVertexAt(pn),_n.addVertexAt(new McGePoint3d(pn.x,tn.y)),_n.isClosed=!0,n.push([b,b.map(function(Rn){return Rn.clone()})]),b.forEach(function(Rn){var Lt=Rn.getMcDbEntity();if(Lt instanceof McDbCurve){var wn=Lt.IntersectWith(_n,McDb.Intersect.kOnBothOperands);wn.isEmpty()||wn.forEach(function(hn){m.copyFormAryId([Rn]),L?N.DoExtend(m.imp,hn.x,hn.y,hn.x,hn.y):O.DoTrim(m.imp,hn.x,hn.y,hn.x,hn.y)})}}),an.abrupt("return",1);case 67:n.push([It,b.map(function(Rn){return Rn.clone()})]),m.copyFormAryId(It),L?N.DoExtend(m.imp,nn.pt1.x,nn.pt1.y,nn.pt2.x,nn.pt2.y):O.DoTrim(m.imp,nn.pt1.x,nn.pt1.y,nn.pt2.x,nn.pt2.y);case 70:case"end":return an.stop()}},Ue)});case 30:return ne.delegateYield(J(),"t0",32);case 32:if(fe=ne.t0,fe!==0){ne.next=35;break}return ne.abrupt("break",41);case 35:if(fe!==1){ne.next=37;break}return ne.abrupt("continue",30);case 37:if(!fe){ne.next=39;break}return ne.abrupt("return",fe.v);case 39:ne.next=30;break;case 41:window.removeEventListener("keydown",G),window.removeEventListener("keyup",q),O.UnInit(),N.UnInit();case 45:case"end":return ne.stop()}},t)})),_Mx_Trim.apply(this,arguments)}function Mx_Extend(){return _Mx_Extend.apply(this,arguments)}function _Mx_Extend(){return _Mx_Extend=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b,m,O,N,L,G,q,J,fe;return regenerator.wrap(function(ne){for(;;)switch(ne.prev=ne.next){case 0:if(e=new MxCADResbuf,l=!1,c=!1,e.AddMcDbEntityTypes("LINE,LWPOLYLINE,ARC"),y=MxCADUtility.getCurrentSelect(e),y.length!==0){ne.next=15;break}return ne.next=9,MxCADUtility.userSelect("选择对象或<全部选择>",e,function(Ue,De){n=De,u=Ue});case 9:if(y=ne.sent,n.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){ne.next=12;break}return ne.abrupt("return");case 12:if(n.getStatus()===MrxDbgUiPrBaseReturn$1.kNone&&y.length===0&&(u.allSelect(e),u.forEach(function(Ue){y.push(Ue)})),y.length!==0){ne.next=15;break}return ne.abrupt("return");case 15:if(b=new McGeLongArray,b.copyFormAryId(y),m=new MxCpp.mxcadassemblyimp.MxDrawExtendAssist,m.Init(b.imp)){ne.next=20;break}return ne.abrupt("return");case 20:if(O=new MxCpp.mxcadassemblyimp.MxDrawTrimAssist,O.Init(b.imp)){ne.next=23;break}return ne.abrupt("return");case 23:N=[],L=!1,G=function(De){L=De.key==="Shift"},window.addEventListener("keydown",G),q=function(){return L=!1},window.addEventListener("keyup",q),J=regenerator.mark(function Ue(){var De,Ve,rt,Ae,Te,Xe,ie,ue,pt,mt,Tt,kt,It,nn,tn,pn;return regenerator.wrap(function(Dn){for(;;)switch(Dn.prev=Dn.next){case 0:return De=new MxCADSelectionSet,De.isWhileSelect=!1,De.isSelectHighlight=!1,Dn.next=5,De.userSelect("选择要延伸的对象或按住 Shift 键选择要修剪的对象",e,function(an){Ve=an,Ve.setKeyWords("[栏选(F)/窗交(C)/边(E)".concat(N.length>0?"/放弃(U)":"","]"))});case 5:if(Dn.sent){Dn.next=7;break}return Dn.abrupt("return",0);case 7:if(!Ve.isKeyWordPicked("F")){Dn.next=18;break}return Dn.next=10,getHurdleSelectionPoints();case 10:if(rt=Dn.sent,rt){Dn.next=13;break}return Dn.abrupt("return",0);case 13:return Ae=new McDbPolyline,rt.forEach(function(an){Ae.addVertexAt(an)}),N.push([y,y.map(function(an){return an.clone()})]),y.forEach(function(an){var Rn=an.getMcDbEntity();if(Rn instanceof McDbCurve){var Lt=Rn.IntersectWith(Ae,McDb.Intersect.kOnBothOperands);Lt.isEmpty()||Lt.forEach(function(wn){b.copyFormAryId([an]),L?O.DoTrim(b.imp,wn.x,wn.y,wn.x,wn.y):m.DoExtend(b.imp,wn.x,wn.y,wn.x,wn.y)})}}),Dn.abrupt("return",1);case 18:if(!Ve.isKeyWordPicked("C")){Dn.next=21;break}return l=!0,Dn.abrupt("return",1);case 21:if(!Ve.isKeyWordPicked("E")){Dn.next=39;break}return Te=new MxCADUiPrKeyWord,Te.setMessage("指定隐含边延伸模式<".concat(c?"延伸":"不延伸",">")),Te.setKeyWords("[延伸(E)/不延伸(N)]"),Dn.next=27,Te.go();case 27:if(Xe=Te.keyWordPicked(),Te.getStatus()!==MrxDbgUiPrBaseReturn$1.kCancel){Dn.next=30;break}return Dn.abrupt("return",{v:void 0});case 30:if(Te.getStatus()!==MrxDbgUiPrBaseReturn$1.kNone){Dn.next=32;break}return Dn.abrupt("return",1);case 32:if(Te.getStatus()!==MrxDbgUiPrBaseReturn$1.kKeyWord){Dn.next=39;break}if(Xe!=="E"){Dn.next=36;break}return c=!0,Dn.abrupt("return",1);case 36:if(Xe!=="N"){Dn.next=39;break}return c=!1,Dn.abrupt("return",1);case 39:if(!Ve.isKeyWordPicked("U")){Dn.next=46;break}return ie=N.pop()||[],ue=_slicedToArray$1(ie,2),pt=ue[0],mt=ue[1],console.log(pt),pt?.forEach(function(an){an.erase()}),Tt=MxCpp.getCurrentMxCAD(),mt?.forEach(function(an){an instanceof McDbEntity&&Tt.drawEntity(an)}),Dn.abrupt("return",1);case 46:if(kt=De.getIds(),kt.length!=0){Dn.next=49;break}return Dn.abrupt("return",1);case 49:if(It=De.getSelectPoint(),!l){Dn.next=61;break}return nn=It.pt1,tn=It.pt2,pn=new McDbPolyline,pn.addVertexAt(nn),pn.addVertexAt(new McGePoint3d(nn.x,tn.y)),pn.addVertexAt(tn),pn.addVertexAt(new McGePoint3d(tn.x,nn.y)),pn.isClosed=!0,N.push([y,y.map(function(an){return an.clone()})]),y.forEach(function(an){var Rn=an.getMcDbEntity();if(Rn instanceof McDbCurve){var Lt=Rn.IntersectWith(pn,McDb.Intersect.kOnBothOperands);Lt.isEmpty()||Lt.forEach(function(wn){b.copyFormAryId([an]),L?O.DoTrim(b.imp,wn.x,wn.y,wn.x,wn.y):m.DoExtend(b.imp,wn.x,wn.y,wn.x,wn.y)})}}),Dn.abrupt("return",1);case 61:N.push([kt,y.map(function(an){return an.clone()})]),b.copyFormAryId(kt),L?O.DoTrim(b.imp,It.pt1.x,It.pt1.y,It.pt2.x,It.pt2.y):m.DoExtend(b.imp,It.pt1.x,It.pt1.y,It.pt2.x,It.pt2.y);case 64:case"end":return Dn.stop()}},Ue)});case 30:return ne.delegateYield(J(),"t0",32);case 32:if(fe=ne.t0,fe!==0){ne.next=35;break}return ne.abrupt("break",41);case 35:if(fe!==1){ne.next=37;break}return ne.abrupt("continue",30);case 37:if(!fe){ne.next=39;break}return ne.abrupt("return",fe.v);case 39:ne.next=30;break;case 41:window.removeEventListener("keydown",G),window.removeEventListener("keyup",q),O.UnInit(),m.UnInit();case 45:case"end":return ne.stop()}},t)})),_Mx_Extend.apply(this,arguments)}function Mx_Explode(){return _Mx_Explode.apply(this,arguments)}function _Mx_Explode(){return _Mx_Explode=_asyncToGenerator(regenerator.mark(function t(){var e,l,n;return regenerator.wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return e=new MxCADResbuf,e.AddMcDbEntityTypes("INSERT,MTEXT,ROTATEDDIMENSION,ALIGNEDDIMENSION,DIMENSION,LWPOLYLINE"),c.next=4,MxCADUtility.userSelect("选择分解对象",e);case 4:if(l=c.sent,l.length!=0){c.next=7;break}return c.abrupt("return");case 7:n=new McGeLongArray,n.copyFormAryId(l),MxCpp.App.MxCADAssist.MxExplode(n.imp);case 10:case"end":return c.stop()}},t)})),_Mx_Explode.apply(this,arguments)}function Mx_Join(){return _Mx_Join.apply(this,arguments)}function _Mx_Join(){return _Mx_Join=_asyncToGenerator(regenerator.mark(function t(){var e,l,n;return regenerator.wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return e=new MxCADResbuf,e.AddMcDbEntityTypes("LWPOLYLINE,ARC,LINE"),c.next=4,MxCADUtility.userSelect("选择要合并的对象",e);case 4:if(l=c.sent,l.length!=0){c.next=7;break}return c.abrupt("return");case 7:n=new McGeLongArray,n.copyFormAryId(l),MxCpp.App.MxCADAssist.MxJoin(n.imp);case 10:case"end":return c.stop()}},t)})),_Mx_Join.apply(this,arguments)}function Mx_Break(){return _Mx_Break.apply(this,arguments)}function _Mx_Break(){return _Mx_Break=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c,y,b;return regenerator.wrap(function(O){for(;;)switch(O.prev=O.next){case 0:return e=new MxCADResbuf,e.AddMcDbEntityTypes("LWPOLYLINE,ARC,LINE,CIRCLE"),l=new MxCADUiPrEntity,l.setFilter(e),l.setMessage("选择要打断的对象"),O.next=7,l.go();case 7:if(n=O.sent,n.isValid()){O.next=10;break}return O.abrupt("return");case 10:if(u=n.getMcDbCurve(),u){O.next=13;break}return O.abrupt("return");case 13:c=l.pickPoint(),u.highlight(!0),y=regenerator.mark(function N(){var L,G,q,J,fe,ve,ne,Ue,De,Ve,rt,Ae,Te,Xe,ie,ue,pt,mt;return regenerator.wrap(function(kt){for(;;)switch(kt.prev=kt.next){case 0:return L=new MxCADUiPrPoint,L.setMessage(`
- 指定第二个打断点`),L.setKeyWords("[第一点(F)/打断长度(D)/中点打断(M)/交点打断(I)]"),L.setUserDraw(function(It,nn){var tn=u?.clone();if(tn&&tn instanceof McDbCurve){var pn=[];pn.push(c),pn.push(It);var _n=tn.splitCurves(pn);_n.empty()||_n.forEach(function(Dn,an){an%2==0&&nn.drawMcDbEntity(Dn)})}}),kt.next=6,L.go();case 6:if(G=kt.sent,!L.isKeyWordPicked("F")){kt.next=17;break}return L.setMessage("指定第一个打断点"),L.setKeyWords(""),kt.next=12,L.go();case 12:if(q=kt.sent,q){kt.next=15;break}return kt.abrupt("return",{v:void 0});case 15:return c=q,kt.abrupt("return",0);case 17:if(J=!1,!L.isKeyWordPicked("D")){kt.next=33;break}return fe=new MxCADUiPrDist,fe.setMessage("输入打断长度"),fe.setKeyWords(""),kt.next=24,fe.go();case 24:if(ve=kt.sent,typeof ve=="number"){kt.next=27;break}return kt.abrupt("return",{v:void 0});case 27:if(c=u.getStartPoint().val,ne=u.getPointAtDist(ve),Ue=ne.val,De=ne.ret,De){kt.next=31;break}return kt.abrupt("return",{v:MxFun.acutPrintf(`
- 打断长度不正确`)});case 31:G=Ue,J=!0;case 33:if(!L.isKeyWordPicked("M")){kt.next=40;break}if(c=u.getStartPoint().val,Ve=u.getPointAtDist(u.getLength().val/2),rt=Ve.val,Ae=Ve.ret,Ae){kt.next=38;break}return kt.abrupt("return",{v:void 0});case 38:G=rt,J=!0;case 40:if(!L.isKeyWordPicked("I")){kt.next=56;break}return kt.next=43,MxCADUtility.userSelect("选择相交曲线");case 43:if(Te=kt.sent,Xe=u.clone(),ie=[],Te.forEach(function(It){if(Xe instanceof McDbCurve){var nn=It.clone();if(nn instanceof McDbCurve){var tn=Xe.IntersectWith(nn,McDb.Intersect.kOnBothOperands);tn.isEmpty()||tn.forEach(function(pn){return ie.push(pn)})}}}),ie.length!==0){kt.next=49;break}return kt.abrupt("return",{v:MxFun.acutPrintf(`
- 交点为空`)});case 49:if(ue=u.splitCurves(ie),!ue.empty()){kt.next=53;break}return u.highlight(!1),kt.abrupt("return",{v:void 0});case 53:return ue.forEach(function(It){It instanceof McDbEntity&&(u&©Attribute(It,u),MxCpp.getCurrentMxCAD().drawEntity(It))}),u.erase(),kt.abrupt("return",1);case 56:if(G){kt.next=59;break}return u.highlight(!1),kt.abrupt("return",{v:void 0});case 59:if(pt=[],pt.push(c),pt.push(G),mt=u.splitCurves(pt),!mt.empty()){kt.next=66;break}return u.highlight(!1),kt.abrupt("return",{v:void 0});case 66:return mt.forEach(function(It,nn){It instanceof McDbEntity&&(u&©Attribute(It,u),(nn%2==0||J)&&MxCpp.getCurrentMxCAD().drawEntity(It))}),u.erase(),kt.abrupt("return",1);case 69:case"end":return kt.stop()}},N)});case 16:return O.delegateYield(y(),"t0",18);case 18:if(b=O.t0,b!==0){O.next=21;break}return O.abrupt("continue",16);case 21:if(b!==1){O.next=23;break}return O.abrupt("break",27);case 23:if(!b){O.next=25;break}return O.abrupt("return",b.v);case 25:O.next=16;break;case 27:case"end":return O.stop()}},t)})),_Mx_Break.apply(this,arguments)}function Mx_DrawOrderTopmost(){return _Mx_DrawOrderTopmost.apply(this,arguments)}function _Mx_DrawOrderTopmost(){return _Mx_DrawOrderTopmost=_asyncToGenerator(regenerator.mark(function t(){var e,l,n;return regenerator.wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return e=new MxCADSelectionSet,c.next=3,e.userSelect(`
- 选择对象`);case 3:if(c.sent){c.next=5;break}return c.abrupt("return");case 5:l=MxCpp.getCurrentDatabase().currentSpace.getMinMaxDrawOrder(),n=l.maxDrawOrder+1,e.forEach(function(y){var b=y.getMcDbEntity();b&&(b.drawOrder=n)});case 8:case"end":return c.stop()}},t)})),_Mx_DrawOrderTopmost.apply(this,arguments)}function Mx_DrawOrderButtomost(){return _Mx_DrawOrderButtomost.apply(this,arguments)}function _Mx_DrawOrderButtomost(){return _Mx_DrawOrderButtomost=_asyncToGenerator(regenerator.mark(function t(){var e,l,n;return regenerator.wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return e=new MxCADSelectionSet,c.next=3,e.userSelect(`
- 选择对象`);case 3:if(c.sent){c.next=5;break}return c.abrupt("return");case 5:l=MxCpp.getCurrentDatabase().currentSpace.getMinMaxDrawOrder(),n=l.minDrawOrder-1,e.forEach(function(y){var b=y.getMcDbEntity();b&&(b.drawOrder=n)});case 8:case"end":return c.stop()}},t)})),_Mx_DrawOrderButtomost.apply(this,arguments)}function Mx_DrawOrderTop(){return _Mx_DrawOrderTop.apply(this,arguments)}function _Mx_DrawOrderTop(){return _Mx_DrawOrderTop=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c;return regenerator.wrap(function(b){for(;;)switch(b.prev=b.next){case 0:return e=new MxCADSelectionSet,b.next=3,e.userSelect(`
- 选择对象`);case 3:if(b.sent){b.next=5;break}return b.abrupt("return");case 5:if(!e.isNull()){b.next=7;break}return b.abrupt("return");case 7:return l=new MxCADUiPrEntity,l.setMessage("选择参照对象"),b.next=11,l.go();case 11:if(n=b.sent,!n.isNull()){b.next=14;break}return b.abrupt("return");case 14:if(u=n.getMcDbEntity(),u){b.next=17;break}return b.abrupt("return");case 17:c=u.drawOrder+1,e.forEach(function(m){var O=m.getMcDbEntity();O&&(O.drawOrder=c)});case 19:case"end":return b.stop()}},t)})),_Mx_DrawOrderTop.apply(this,arguments)}function Mx_DrawOrderButtom(){return _Mx_DrawOrderButtom.apply(this,arguments)}function _Mx_DrawOrderButtom(){return _Mx_DrawOrderButtom=_asyncToGenerator(regenerator.mark(function t(){var e,l,n,u,c;return regenerator.wrap(function(b){for(;;)switch(b.prev=b.next){case 0:return e=new MxCADSelectionSet,b.next=3,e.userSelect(`
- 选择对象`);case 3:if(b.sent){b.next=5;break}return b.abrupt("return");case 5:if(!e.isNull()){b.next=7;break}return b.abrupt("return");case 7:return l=new MxCADUiPrEntity,l.setMessage("选择参照对象"),b.next=11,l.go();case 11:if(n=b.sent,!n.isNull()){b.next=14;break}return b.abrupt("return");case 14:if(u=n.getMcDbEntity(),u){b.next=17;break}return b.abrupt("return");case 17:c=u.drawOrder-1,e.forEach(function(m){var O=m.getMcDbEntity();O&&(O.drawOrder=c)});case 19:case"end":return b.stop()}},t)})),_Mx_DrawOrderButtom.apply(this,arguments)}MxFun.on("init",function(){MxFun.addCommand("Mx_Erase",Mx_Erase),MxFun.addCommand("Mx_Copy",Mx_Copy),MxFun.addCommand("Mx_Move",Mx_Move),MxFun.addCommand("Mx_Rotate",Mx_Rotate),MxFun.addCommand("Mx_Scale",Mx_Scale),MxFun.addCommand("Mx_WindowZoom",Mx_WindowZoom),MxFun.addCommand("Mx_ZoomE",Mx_ZoomE),MxFun.addCommand("Mx_Plan90CW",Mx_Plan90CW),MxFun.addCommand("Mx_Offset",Mx_Offset),MxFun.addCommand("Mx_Regen",Mx_Regen),MxFun.addCommand("Mx_Mirror",Mx_Mirror),MxFun.addCommand("Mx_Chamfer",Mx_Chamfer),MxFun.addCommand("Mx_Fillet",Mx_Fillet),MxFun.addCommand("Mx_Trim",Mx_Trim),MxFun.addCommand("Mx_Extend",Mx_Extend),MxFun.addCommand("Mx_Explode",Mx_Explode),MxFun.addCommand("Mx_Join",Mx_Join),MxFun.addCommand("Mx_Break",Mx_Break),MxFun.addCommand("Mx_DrawOrderTopmost",Mx_DrawOrderTopmost),MxFun.addCommand("Mx_DrawOrderButtomost",Mx_DrawOrderButtomost),MxFun.addCommand("Mx_DrawOrderTop",Mx_DrawOrderTop),MxFun.addCommand("Mx_DrawOrderButtom",Mx_DrawOrderButtom)});var getQuadrant=function t(e,l){return[l.x>=e.x&&l.y>=e.y,l.x<e.x&&l.y>=e.y,l.x<e.x&&l.y<e.y,l.x>=e.x&&l.y<e.y]};function calculateRoundedRectangleVertices(t,e,l){if(e===0&&l===0)return t;var n=_slicedToArray$1(t,4),u=n[0],c=n[1],y=n[2],b=n[3],m=u.distanceTo(b),O=u.distanceTo(c),N=getQuadrant(u,y),L=_slicedToArray$1(N,4);L[0];var G=L[1],q=L[2],J=L[3],fe=G||q?-e:e,ve=q||J?-l:l;if(m-Math.abs(fe)*2<=0||O-Math.abs(ve)*2<=0)return t;var ne=new McGePoint3d(u.x+fe,u.y,u.z),Ue=new McGePoint3d(u.x,u.y+ve,u.z),De=new McGePoint3d(c.x,c.y-ve,c.z),Ve=new McGePoint3d(c.x+fe,c.y,c.z),rt=new McGePoint3d(y.x-fe,y.y,y.z),Ae=new McGePoint3d(y.x,c.y-ve,y.z),Te=new McGePoint3d(b.x,b.y+ve,b.z),Xe=new McGePoint3d(b.x-fe,b.y,b.z),ie=[ne,Ue,De,Ve,rt,Ae,Te,Xe];return ie}var rotatePoint=function t(e,l,n){var u=Math.cos(n),c=Math.sin(n),y=l.x-e.x,b=l.y-e.y,m=y*u-b*c+e.x,O=y*c+b*u+e.y,N=l.z;return new McGePoint3d(m,O,N)},getRectPoints=function t(e,l){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,u=new McGePoint3d((e.x+l.x)/2,(e.y+l.y)/2,(e.z+l.z)/2),c=new McGePoint3d(e.x,l.y,e.z),y=new McGePoint3d(l.x,e.y,l.z),b=rotatePoint(u,c,n),m=rotatePoint(u,y,n);return[e,b,l,m]},drawRectang=function(){var t=_asyncToGenerator(regenerator.mark(function e(){var l,n,u,c,y,b,m,O,N,L,G,q,J,fe;return regenerator.wrap(function(ne){for(;;)switch(ne.prev=ne.next){case 0:l=new MxCADUiPrPoint,n=0,u=0,c=0,y=0,b=0,m=0,O=200,N=0,L=0,G=0,q="default",J=regenerator.mark(function Ue(){var De,Ve,rt,Ae,Te,Xe,ie,ue;return regenerator.wrap(function(mt){for(;;)switch(mt.prev=mt.next){case 0:return De=function(){var Tt=_asyncToGenerator(regenerator.mark(function kt(It,nn){var tn,pn;return regenerator.wrap(function(Dn){for(;;)switch(Dn.prev=Dn.next){case 0:return tn=new MxCADUiPrDist,tn.setMessage(_ML_String(It,nn)),Dn.next=4,tn.go();case 4:if(pn=Dn.sent,pn){Dn.next=7;break}throw"error getLength";case 7:return Dn.abrupt("return",tn.value());case 8:case"end":return Dn.stop()}},kt)}));return function(It,nn){return Tt.apply(this,arguments)}}(),l.setUserDraw(function(){}),l.clearLastInputPoint(),l.setMessage(`
- 指定第一个角点`),l.setKeyWords("[倒角(C)/标高(E)/圆角(F)/厚度(T)/宽度(W)]"),mt.next=7,l.go();case 7:if(Ve=mt.sent,Ae=new McDbPolyline,mt.prev=9,!l.isKeyWordPicked("C")){mt.next=19;break}return mt.next=13,De("ID_ARX_RECTANG_CHAMFEr1LENGTH",`
- 指定第一个倒角距离:`);case 13:return n=mt.sent,mt.next=16,De("ID_ARX_RECTANG_CHAMFEr2LENGTH",`
- 指定第二个倒角距离`);case 16:return u=mt.sent,q="chamfer",mt.abrupt("return",0);case 19:if(!l.isKeyWordPicked("E")){mt.next=24;break}return mt.next=22,De("ID_ARX_RECTANG_ELEVATION",`
- 指定矩形的标高`);case 22:return c=mt.sent,mt.abrupt("return",0);case 24:if(!l.isKeyWordPicked("F")){mt.next=30;break}return mt.next=27,De("ID_ARX_RECTANG_RADIUS",`
- 指定矩形的圆角半径`);case 27:return y=mt.sent,q="angleRounded",mt.abrupt("return",0);case 30:if(!l.isKeyWordPicked("T")){mt.next=35;break}return mt.next=33,De("ID_ARX_RECTANG_THICKNESS",`
- 指定矩形的厚度`);case 33:return b=mt.sent,mt.abrupt("return",0);case 35:if(!l.isKeyWordPicked("W")){mt.next=40;break}return mt.next=38,De("ID_ARX_RECTANG_WIDTH",`
- 指定矩形的线宽`);case 38:return m=mt.sent,mt.abrupt("return",0);case 40:mt.next=45;break;case 42:return mt.prev=42,mt.t0=mt.catch(9),mt.abrupt("return",1);case 45:if(Ve){mt.next=47;break}return mt.abrupt("return",{v:void 0});case 47:return Te=function(kt,It){var nn=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;Ae=new McDbPolyline,kt.z=It.z=b;var tn=getRectPoints(kt,It,nn),pn=new McGePoint3d((kt.x+It.x)/2,(kt.y+It.y)/2,(kt.z+It.z)/2),_n=tn;if(q==="chamfer"&&(_n=calculateRoundedRectangleVertices(getRectPoints(kt,It),n,u)),q==="angleRounded"&&y!==0){_n=calculateRoundedRectangleVertices(getRectPoints(kt,It),y,y);var Dn=getQuadrant(kt,It),an=_slicedToArray$1(Dn,4);an[0];var Rn=an[1],Lt=an[2],wn=an[3];if(_n.length===8){var hn=function(Xn,Kn,Vn){var Yn=new McGeVector3d(Vn),Vr=CMxDrawPolylineDragArcDraw_CalcArcBulge(Xn,Kn,Yn);Ae.addVertexAt(Xn,Vr),Ae.addVertexAt(Kn,0)},xn=new McGeVector3d(-1,0),$n=new McGeVector3d(0,1),Xr=new McGeVector3d(1,0),ti=new McGeVector3d(0,-1);wn&&($n.y=-1,Xr.x=1,ti.y=1),Rn&&(xn.x=1,$n.y=1,Xr.x=-1,ti.y=-1),Lt&&(xn.x=1,$n.y=-1,Xr.x=-1,ti.y=1),hn(_n[0],_n[1],xn),hn(_n[2],_n[3],$n),hn(_n[4],_n[5],Xr),hn(_n[6],_n[7],ti)}else _n.forEach(function(gn){Ae.addVertexAt(gn,0)})}else _n.forEach(function(gn){Ae.addVertexAt(gn,0,m,m)});return(q==="chamfer"||q==="angleRounded")&&Ae.rotate(pn,nn),Ae.isClosed=!0,Ae.constantWidth=m,rt=It,Ae},Xe=function(kt,It){if(Ve){var nn=Ve,tn=kt;Ae=Te(nn,tn,G),It.drawMcDbEntity(Ae)}},l.setUserDraw(Xe),ie=function(){var Tt=_asyncToGenerator(regenerator.mark(function kt(){var It,nn,tn,pn,_n,Dn,an,Rn,Lt,wn,hn;return regenerator.wrap(function($n){for(;;)switch($n.prev=$n.next){case 0:return l.setMessage(`
- 指定另一个角点`),l.setKeyWords("[面积(A)/尺寸(D)/旋转(R)]"),$n.next=4,l.go();case 4:if(It=$n.sent,nn=function(ti,gn){var Xn=getQuadrant(Ve,ti),Kn=_slicedToArray$1(Xn,4),Vn=Kn[0],Yn=Kn[1],Vr=Kn[2],xi=Kn[3];Vn&&(It=new McGePoint3d(Ve.x+N,Ve.y+L,b)),Yn&&(It=new McGePoint3d(Ve.x-N,Ve.y+L,b)),Vr&&(It=new McGePoint3d(Ve.x-N,Ve.y-L,b)),xi&&(It=new McGePoint3d(Ve.x+N,Ve.y-L,b)),It&&(Ae=Te(Ve,It,G),gn.drawMcDbEntity(Ae))},!l.isKeyWordPicked("A")){$n.next=40;break}return l.setUserDraw(function(){}),tn=new MxCADUiPrInt,tn.setMessage("输入当前单位计算的矩形面积<"+O+">"),$n.next=12,tn.go();case 12:if(pn=$n.sent,pn){$n.next=15;break}return $n.abrupt("return");case 15:return O=pn,_n=new MxCADUiPrKeyWord,_n.setMessage("计算矩形标注时的依据"),_n.setKeyWords("[长度(L)/宽度(W)]"),$n.next=21,_n.go();case 21:if(Dn=$n.sent,Dn!==null){$n.next=24;break}return $n.abrupt("return");case 24:if(Dn!=="w"){$n.next=31;break}return $n.next=27,De("ID_ARX_RECTANG_AREA_WIDTH","输入矩形宽度");case 27:N=$n.sent,L=O/N,$n.next=35;break;case 31:return $n.next=33,De("ID_ARX_RECTANG_AREA_LENGTH","输入矩形长度");case 33:L=$n.sent,N=O/L;case 35:It=new McGePoint3d(Ve.x+N,Ve.y+L,b),Ae=Te(Ve,It,G),MxCpp.getCurrentMxCAD().drawEntity(Ae,!0),$n.next=98;break;case 40:if(!l.isKeyWordPicked("D")){$n.next=62;break}return $n.prev=41,$n.next=44,De("ID_ARX_RECTANG_AREA_WIDTH","指定矩形宽度");case 44:return N=$n.sent,$n.next=47,De("ID_ARX_RECTANG_AREA_LENGTH","指定矩形宽度");case 47:L=$n.sent,$n.next=53;break;case 50:return $n.prev=50,$n.t0=$n.catch(41),$n.abrupt("return");case 53:return l.clearLastInputPoint(),l.setUserDraw(nn),$n.next=57,ie();case 57:if(an=$n.sent,!(typeof an>"u")){$n.next=60;break}return $n.abrupt("return");case 60:$n.next=98;break;case 62:if(!l.isKeyWordPicked("R")){$n.next=97;break}return l.setMessage(`
- 指定旋转角度`),l.setKeyWords("[拾取点(P)]"),l.setUserDraw(function(Xr,ti){G=angleTo(Xr.x,Xr.y,Ve.x,Ve.y),Ae=Te(Ve,rt),Ae.rotate(Ve,G),ti.drawMcDbEntity(Ae)}),$n.next=68,l.go();case 68:if(Rn=$n.sent,!l.isKeyWordPicked("P")){$n.next=87;break}return l.clearLastInputPoint(),l.setUserDraw(function(){}),l.setMessage(`
- 指定第一个点`),$n.next=75,l.go();case 75:if(Lt=$n.sent,Lt){$n.next=78;break}return $n.abrupt("return");case 78:return l.setUserDraw(function(Xr,ti){ti.drawLine(Xr.toVector3(),Lt.toVector3())}),$n.next=81,l.go();case 81:if(wn=$n.sent,wn){$n.next=84;break}return $n.abrupt("return");case 84:G=angleTo(Lt.x,Lt.y,wn.x,wn.y),$n.next=89;break;case 87:if(Rn){$n.next=89;break}return $n.abrupt("return");case 89:return l.setUserDraw(Xe),$n.next=92,ie();case 92:if(hn=$n.sent,!(typeof hn>"u")){$n.next=95;break}return $n.abrupt("return");case 95:$n.next=98;break;case 97:It&&MxCpp.getCurrentMxCAD().drawEntity(Ae,!0);case 98:Ae.setxDataDouble("BG",c);case 99:case"end":return $n.stop()}},kt,null,[[41,50]])}));return function(){return Tt.apply(this,arguments)}}(),mt.next=53,ie();case 53:if(ue=mt.sent,!(typeof ue>"u")){mt.next=56;break}return mt.abrupt("return",1);case 56:case"end":return mt.stop()}},Ue,null,[[9,42]])});case 13:return ne.delegateYield(J(),"t0",15);case 15:if(fe=ne.t0,fe!==0){ne.next=18;break}return ne.abrupt("continue",13);case 18:if(fe!==1){ne.next=20;break}return ne.abrupt("break",24);case 20:if(!fe){ne.next=22;break}return ne.abrupt("return",fe.v);case 22:ne.next=13;break;case 24:case"end":return ne.stop()}},e)}));return function(){return t.apply(this,arguments)}}();MxFun.on("init",function(){MxFun.addCommand("Mx_Rectang",drawRectang)});var MdGe;(function(t){(function(e){e[e.Enum_COMPOUND=0]="Enum_COMPOUND",e[e.Enum_COMPSOLID=1]="Enum_COMPSOLID",e[e.Enum_SOLID=2]="Enum_SOLID",e[e.Enum_SHELL=3]="Enum_SHELL",e[e.Enum_FACE=4]="Enum_FACE",e[e.Enum_WIRE=5]="Enum_WIRE",e[e.Enum_EDGE=6]="Enum_EDGE",e[e.Enum_VERTEX=7]="Enum_VERTEX",e[e.Enum_SHAPE=8]="Enum_SHAPE"})(t.MxShapeEnum||(t.MxShapeEnum={})),function(e){e[e.HTA_LEFT=0]="HTA_LEFT",e[e.HTA_CENTER=1]="HTA_CENTER",e[e.HTA_RIGHT=2]="HTA_RIGHT"}(t.MxHorizontalTextAlignment||(t.MxHorizontalTextAlignment={})),function(e){e[e.CVTA_BOTTOM=0]="CVTA_BOTTOM",e[e.CVTA_CENTER=1]="CVTA_CENTER",e[e.CVTA_TOP=2]="CVTA_TOP",e[e.CVTA_TOPFIRSTLINE=3]="CVTA_TOPFIRSTLINE"}(t.MxVerticalTextAlignment||(t.MxVerticalTextAlignment={})),function(e){e[e.FA_UNDEFINED=-1]="FA_UNDEFINED",e[e.FA_Regular=0]="FA_Regular",e[e.FA_Bold=1]="FA_Bold",e[e.FA_Italic=2]="FA_Italic",e[e.FA_BoldItalic=3]="FA_BoldItalic"}(t.MxFontAspect||(t.MxFontAspect={})),function(e){e[e.TODT_NORMAL=0]="TODT_NORMAL",e[e.TODT_SUBTITLE=1]="TODT_SUBTITLE",e[e.TODT_DEKALE=2]="TODT_DEKALE",e[e.TODT_BLEND=3]="TODT_BLEND",e[e.TODT_DIMENSION=4]="TODT_DIMENSION",e[e.TODT_SHADOW=5]="TODT_SHADOW"}(t.MxTypeOfDisplayText||(t.MxTypeOfDisplayText={})),function(e){e[e.Enum_Rational=0]="Enum_Rational",e[e.Enum_QuasiAngular=1]="Enum_QuasiAngular",e[e.Enum_Polynomial=2]="Enum_Polynomial"}(t.MxCF3dFilletShapeEnum||(t.MxCF3dFilletShapeEnum={})),function(e){e[e.Enum_ClassicChamfer=0]="Enum_ClassicChamfer",e[e.Enum_ConstThroatChamfer=1]="Enum_ConstThroatChamfer",e[e.Enum_ConstThroatWithPenetrationChamfer=2]="Enum_ConstThroatWithPenetrationChamfer"}(t.MxCFDSChamfMode||(t.MxCFDSChamfMode={})),function(e){e[e.GF_IsCorrectedFrenet=0]="GF_IsCorrectedFrenet",e[e.GF_IsFixed=1]="GF_IsFixed",e[e.GF_IsFrenet=2]="GF_IsFrenet",e[e.GF_IsConstantNormal=3]="GF_IsConstantNormal",e[e.GF_IsDarboux=4]="GF_IsDarboux",e[e.GF_IsGuideAC=5]="GF_IsGuideAC",e[e.GF_IsGuidePlan=6]="GF_IsGuidePlan",e[e.GF_IsGuideACWithContact=7]="GF_IsGuideACWithContact",e[e.GF_IsGuidePlanWithContact=8]="GF_IsGuidePlanWithContact",e[e.GF_IsDiscreteTrihedron=9]="GF_IsDiscreteTrihedron"}(t.MxGFTrihedron||(t.MxGFTrihedron={})),function(e){e[e.GA_C0=0]="GA_C0",e[e.GA_G1=1]="GA_G1",e[e.GA_C1=2]="GA_C1",e[e.GA_G2=3]="GA_G2",e[e.GA_C2=4]="GA_C2",e[e.GA_C3=5]="GA_C3",e[e.GA_CN=6]="GA_CN"}(t.MxGAShapeEnum||(t.MxGAShapeEnum={})),function(e){e[e.Offset_Skin=0]="Offset_Skin",e[e.Offset_Pipe=1]="Offset_Pipe",e[e.Offset_RectoVerso=2]="Offset_RectoVerso"}(t.MxOffsetModeEnum||(t.MxOffsetModeEnum={})),function(e){e[e.GA_Arc=0]="GA_Arc",e[e.GA_Tangent=1]="GA_Tangent",e[e.GA_Intersection=2]="GA_Intersection"}(t.MxGAJoinTypeEnum||(t.MxGAJoinTypeEnum={})),function(e){e[e.Material_NOM_Brass=0]="Material_NOM_Brass",e[e.Material_NOM_Bronze=1]="Material_NOM_Bronze",e[e.Material_NOM_Copper=2]="Material_NOM_Copper",e[e.Material_NOM_Gold=3]="Material_NOM_Gold",e[e.Material_NOM_Pewter=4]="Material_NOM_Pewter",e[e.Material_NOM_Plastered=5]="Material_NOM_Plastered",e[e.Material_NOM_Plastified=6]="Material_NOM_Plastified",e[e.Material_NOM_Silver=7]="Material_NOM_Silver",e[e.Material_NOM_Steel=8]="Material_NOM_Steel",e[e.Material_NOM_Stone=9]="Material_NOM_Stone",e[e.Material_NOM_ShinyPlastified=10]="Material_NOM_ShinyPlastified",e[e.Material_NOM_Satin=11]="Material_NOM_Satin",e[e.Material_NOM_Metalized=12]="Material_NOM_Metalized",e[e.Material_NOM_Ionized=13]="Material_NOM_Ionized",e[e.Material_NOM_Chrome=14]="Material_NOM_Chrome",e[e.Material_NOM_Aluminum=15]="Material_NOM_Aluminum",e[e.Material_NOM_Obsidian=16]="Material_NOM_Obsidian",e[e.Material_NOM_Neon=17]="Material_NOM_Neon",e[e.Material_NOM_Jade=18]="Material_NOM_Jade",e[e.Material_NOM_Charcoal=19]="Material_NOM_Charcoal",e[e.Material_NOM_Water=20]="Material_NOM_Water",e[e.Material_NOM_Glass=21]="Material_NOM_Glass",e[e.Material_NOM_Diamond=22]="Material_NOM_Diamond",e[e.Material_NOM_Transparent=23]="Material_NOM_Transparent",e[e.Material_NOM_DEFAULT=24]="Material_NOM_DEFAULT",e[e.Material_NOM_UserDefined=25]="Material_NOM_UserDefined"}(t.MxNameOfMaterial||(t.MxNameOfMaterial={})),function(e){e[e.Material_TOM_ASPECT=0]="Material_TOM_ASPECT",e[e.Material_TOM_PHYSIC=1]="Material_TOM_PHYSIC"}(t.MxTypeOfMaterial||(t.MxTypeOfMaterial={})),function(e){e[e.Reflection_TOR_AMBIENT=0]="Reflection_TOR_AMBIENT",e[e.Reflection_TOR_DIFFUSE=1]="Reflection_TOR_DIFFUSE",e[e.Reflection_TOR_SPECULAR=2]="Reflection_TOR_SPECULAR",e[e.Reflection_TOR_EMISSION=3]="Reflection_TOR_EMISSION"}(t.MxTypeOfReflection||(t.MxTypeOfReflection={})),function(e){e[e.Color_NOC_BLACK=0]="Color_NOC_BLACK",e[e.Color_NOC_MATRABLUE=1]="Color_NOC_MATRABLUE",e[e.Color_NOC_MATRAGRAY=2]="Color_NOC_MATRAGRAY",e[e.Color_NOC_ALICEBLUE=3]="Color_NOC_ALICEBLUE",e[e.Color_NOC_ANTIQUEWHITE=4]="Color_NOC_ANTIQUEWHITE",e[e.Color_NOC_ANTIQUEWHITE1=5]="Color_NOC_ANTIQUEWHITE1",e[e.Color_NOC_ANTIQUEWHITE2=6]="Color_NOC_ANTIQUEWHITE2",e[e.Color_NOC_ANTIQUEWHITE3=7]="Color_NOC_ANTIQUEWHITE3",e[e.Color_NOC_ANTIQUEWHITE4=8]="Color_NOC_ANTIQUEWHITE4",e[e.Color_NOC_AQUAMARINE1=9]="Color_NOC_AQUAMARINE1",e[e.Color_NOC_AQUAMARINE2=10]="Color_NOC_AQUAMARINE2",e[e.Color_NOC_AQUAMARINE4=11]="Color_NOC_AQUAMARINE4",e[e.Color_NOC_AZURE=12]="Color_NOC_AZURE",e[e.Color_NOC_AZURE2=13]="Color_NOC_AZURE2",e[e.Color_NOC_AZURE3=14]="Color_NOC_AZURE3",e[e.Color_NOC_AZURE4=15]="Color_NOC_AZURE4",e[e.Color_NOC_BEIGE=16]="Color_NOC_BEIGE",e[e.Color_NOC_BISQUE=17]="Color_NOC_BISQUE",e[e.Color_NOC_BISQUE2=18]="Color_NOC_BISQUE2",e[e.Color_NOC_BISQUE3=19]="Color_NOC_BISQUE3",e[e.Color_NOC_BISQUE4=20]="Color_NOC_BISQUE4",e[e.Color_NOC_BLANCHEDALMOND=21]="Color_NOC_BLANCHEDALMOND",e[e.Color_NOC_BLUE=22]="Color_NOC_BLUE",e[e.Color_NOC_BLUE1=22]="Color_NOC_BLUE1",e[e.Color_NOC_BLUE2=23]="Color_NOC_BLUE2",e[e.Color_NOC_BLUE3=24]="Color_NOC_BLUE3",e[e.Color_NOC_BLUE4=25]="Color_NOC_BLUE4",e[e.Color_NOC_BLUEVIOLET=26]="Color_NOC_BLUEVIOLET",e[e.Color_NOC_BROWN=27]="Color_NOC_BROWN",e[e.Color_NOC_BROWN1=28]="Color_NOC_BROWN1",e[e.Color_NOC_BROWN2=29]="Color_NOC_BROWN2",e[e.Color_NOC_BROWN3=30]="Color_NOC_BROWN3",e[e.Color_NOC_BROWN4=31]="Color_NOC_BROWN4",e[e.Color_NOC_BURLYWOOD=32]="Color_NOC_BURLYWOOD",e[e.Color_NOC_BURLYWOOD1=33]="Color_NOC_BURLYWOOD1",e[e.Color_NOC_BURLYWOOD2=34]="Color_NOC_BURLYWOOD2",e[e.Color_NOC_BURLYWOOD3=35]="Color_NOC_BURLYWOOD3",e[e.Color_NOC_BURLYWOOD4=36]="Color_NOC_BURLYWOOD4",e[e.Color_NOC_CADETBLUE=37]="Color_NOC_CADETBLUE",e[e.Color_NOC_CADETBLUE1=38]="Color_NOC_CADETBLUE1",e[e.Color_NOC_CADETBLUE2=39]="Color_NOC_CADETBLUE2",e[e.Color_NOC_CADETBLUE3=40]="Color_NOC_CADETBLUE3",e[e.Color_NOC_CADETBLUE4=41]="Color_NOC_CADETBLUE4",e[e.Color_NOC_CHARTREUSE=42]="Color_NOC_CHARTREUSE",e[e.Color_NOC_CHARTREUSE1=42]="Color_NOC_CHARTREUSE1",e[e.Color_NOC_CHARTREUSE2=43]="Color_NOC_CHARTREUSE2",e[e.Color_NOC_CHARTREUSE3=44]="Color_NOC_CHARTREUSE3",e[e.Color_NOC_CHARTREUSE4=45]="Color_NOC_CHARTREUSE4",e[e.Color_NOC_CHOCOLATE=46]="Color_NOC_CHOCOLATE",e[e.Color_NOC_CHOCOLATE1=47]="Color_NOC_CHOCOLATE1",e[e.Color_NOC_CHOCOLATE2=48]="Color_NOC_CHOCOLATE2",e[e.Color_NOC_CHOCOLATE3=49]="Color_NOC_CHOCOLATE3",e[e.Color_NOC_CHOCOLATE4=50]="Color_NOC_CHOCOLATE4",e[e.Color_NOC_CORAL=51]="Color_NOC_CORAL",e[e.Color_NOC_CORAL1=52]="Color_NOC_CORAL1",e[e.Color_NOC_CORAL2=53]="Color_NOC_CORAL2",e[e.Color_NOC_CORAL3=54]="Color_NOC_CORAL3",e[e.Color_NOC_CORAL4=55]="Color_NOC_CORAL4",e[e.Color_NOC_CORNFLOWERBLUE=56]="Color_NOC_CORNFLOWERBLUE",e[e.Color_NOC_CORNSILK1=57]="Color_NOC_CORNSILK1",e[e.Color_NOC_CORNSILK2=58]="Color_NOC_CORNSILK2",e[e.Color_NOC_CORNSILK3=59]="Color_NOC_CORNSILK3",e[e.Color_NOC_CORNSILK4=60]="Color_NOC_CORNSILK4",e[e.Color_NOC_CYAN=61]="Color_NOC_CYAN",e[e.Color_NOC_CYAN1=61]="Color_NOC_CYAN1",e[e.Color_NOC_CYAN2=62]="Color_NOC_CYAN2",e[e.Color_NOC_CYAN3=63]="Color_NOC_CYAN3",e[e.Color_NOC_CYAN4=64]="Color_NOC_CYAN4",e[e.Color_NOC_DARKGOLDENROD=65]="Color_NOC_DARKGOLDENROD",e[e.Color_NOC_DARKGOLDENROD1=66]="Color_NOC_DARKGOLDENROD1",e[e.Color_NOC_DARKGOLDENROD2=67]="Color_NOC_DARKGOLDENROD2",e[e.Color_NOC_DARKGOLDENROD3=68]="Color_NOC_DARKGOLDENROD3",e[e.Color_NOC_DARKGOLDENROD4=69]="Color_NOC_DARKGOLDENROD4",e[e.Color_NOC_DARKGREEN=70]="Color_NOC_DARKGREEN",e[e.Color_NOC_DARKKHAKI=71]="Color_NOC_DARKKHAKI",e[e.Color_NOC_DARKOLIVEGREEN=72]="Color_NOC_DARKOLIVEGREEN",e[e.Color_NOC_DARKOLIVEGREEN1=73]="Color_NOC_DARKOLIVEGREEN1",e[e.Color_NOC_DARKOLIVEGREEN2=74]="Color_NOC_DARKOLIVEGREEN2",e[e.Color_NOC_DARKOLIVEGREEN3=75]="Color_NOC_DARKOLIVEGREEN3",e[e.Color_NOC_DARKOLIVEGREEN4=76]="Color_NOC_DARKOLIVEGREEN4",e[e.Color_NOC_DARKORANGE=77]="Color_NOC_DARKORANGE",e[e.Color_NOC_DARKORANGE1=78]="Color_NOC_DARKORANGE1",e[e.Color_NOC_DARKORANGE2=79]="Color_NOC_DARKORANGE2",e[e.Color_NOC_DARKORANGE3=80]="Color_NOC_DARKORANGE3",e[e.Color_NOC_DARKORANGE4=81]="Color_NOC_DARKORANGE4",e[e.Color_NOC_DARKORCHID=82]="Color_NOC_DARKORCHID",e[e.Color_NOC_DARKORCHID1=83]="Color_NOC_DARKORCHID1",e[e.Color_NOC_DARKORCHID2=84]="Color_NOC_DARKORCHID2",e[e.Color_NOC_DARKORCHID3=85]="Color_NOC_DARKORCHID3",e[e.Color_NOC_DARKORCHID4=86]="Color_NOC_DARKORCHID4",e[e.Color_NOC_DARKSALMON=87]="Color_NOC_DARKSALMON",e[e.Color_NOC_DARKSEAGREEN=88]="Color_NOC_DARKSEAGREEN",e[e.Color_NOC_DARKSEAGREEN1=89]="Color_NOC_DARKSEAGREEN1",e[e.Color_NOC_DARKSEAGREEN2=90]="Color_NOC_DARKSEAGREEN2",e[e.Color_NOC_DARKSEAGREEN3=91]="Color_NOC_DARKSEAGREEN3",e[e.Color_NOC_DARKSEAGREEN4=92]="Color_NOC_DARKSEAGREEN4",e[e.Color_NOC_DARKSLATEBLUE=93]="Color_NOC_DARKSLATEBLUE",e[e.Color_NOC_DARKSLATEGRAY1=94]="Color_NOC_DARKSLATEGRAY1",e[e.Color_NOC_DARKSLATEGRAY2=95]="Color_NOC_DARKSLATEGRAY2",e[e.Color_NOC_DARKSLATEGRAY3=96]="Color_NOC_DARKSLATEGRAY3",e[e.Color_NOC_DARKSLATEGRAY4=97]="Color_NOC_DARKSLATEGRAY4",e[e.Color_NOC_DARKSLATEGRAY=98]="Color_NOC_DARKSLATEGRAY",e[e.Color_NOC_DARKTURQUOISE=99]="Color_NOC_DARKTURQUOISE",e[e.Color_NOC_DARKVIOLET=100]="Color_NOC_DARKVIOLET",e[e.Color_NOC_DEEPPINK=101]="Color_NOC_DEEPPINK",e[e.Color_NOC_DEEPPINK2=102]="Color_NOC_DEEPPINK2",e[e.Color_NOC_DEEPPINK3=103]="Color_NOC_DEEPPINK3",e[e.Color_NOC_DEEPPINK4=104]="Color_NOC_DEEPPINK4",e[e.Color_NOC_DEEPSKYBLUE1=105]="Color_NOC_DEEPSKYBLUE1",e[e.Color_NOC_DEEPSKYBLUE2=106]="Color_NOC_DEEPSKYBLUE2",e[e.Color_NOC_DEEPSKYBLUE3=107]="Color_NOC_DEEPSKYBLUE3",e[e.Color_NOC_DEEPSKYBLUE4=108]="Color_NOC_DEEPSKYBLUE4",e[e.Color_NOC_DODGERBLUE1=109]="Color_NOC_DODGERBLUE1",e[e.Color_NOC_DODGERBLUE2=110]="Color_NOC_DODGERBLUE2",e[e.Color_NOC_DODGERBLUE3=111]="Color_NOC_DODGERBLUE3",e[e.Color_NOC_DODGERBLUE4=112]="Color_NOC_DODGERBLUE4",e[e.Color_NOC_FIREBRICK=113]="Color_NOC_FIREBRICK",e[e.Color_NOC_FIREBRICK1=114]="Color_NOC_FIREBRICK1",e[e.Color_NOC_FIREBRICK2=115]="Color_NOC_FIREBRICK2",e[e.Color_NOC_FIREBRICK3=116]="Color_NOC_FIREBRICK3",e[e.Color_NOC_FIREBRICK4=117]="Color_NOC_FIREBRICK4",e[e.Color_NOC_FLORALWHITE=118]="Color_NOC_FLORALWHITE",e[e.Color_NOC_FORESTGREEN=119]="Color_NOC_FORESTGREEN",e[e.Color_NOC_GAINSBORO=120]="Color_NOC_GAINSBORO",e[e.Color_NOC_GHOSTWHITE=121]="Color_NOC_GHOSTWHITE",e[e.Color_NOC_GOLD=122]="Color_NOC_GOLD",e[e.Color_NOC_GOLD1=122]="Color_NOC_GOLD1",e[e.Color_NOC_GOLD2=123]="Color_NOC_GOLD2",e[e.Color_NOC_GOLD3=124]="Color_NOC_GOLD3",e[e.Color_NOC_GOLD4=125]="Color_NOC_GOLD4",e[e.Color_NOC_GOLDENROD=126]="Color_NOC_GOLDENROD",e[e.Color_NOC_GOLDENROD1=127]="Color_NOC_GOLDENROD1",e[e.Color_NOC_GOLDENROD2=128]="Color_NOC_GOLDENROD2",e[e.Color_NOC_GOLDENROD3=129]="Color_NOC_GOLDENROD3",e[e.Color_NOC_GOLDENROD4=130]="Color_NOC_GOLDENROD4",e[e.Color_NOC_GRAY=131]="Color_NOC_GRAY",e[e.Color_NOC_GRAY0=132]="Color_NOC_GRAY0",e[e.Color_NOC_GRAY1=133]="Color_NOC_GRAY1",e[e.Color_NOC_GRAY2=134]="Color_NOC_GRAY2",e[e.Color_NOC_GRAY3=135]="Color_NOC_GRAY3",e[e.Color_NOC_GRAY4=136]="Color_NOC_GRAY4",e[e.Color_NOC_GRAY5=137]="Color_NOC_GRAY5",e[e.Color_NOC_GRAY6=138]="Color_NOC_GRAY6",e[e.Color_NOC_GRAY7=139]="Color_NOC_GRAY7",e[e.Color_NOC_GRAY8=140]="Color_NOC_GRAY8",e[e.Color_NOC_GRAY9=141]="Color_NOC_GRAY9",e[e.Color_NOC_GRAY10=142]="Color_NOC_GRAY10",e[e.Color_NOC_GRAY11=143]="Color_NOC_GRAY11",e[e.Color_NOC_GRAY12=144]="Color_NOC_GRAY12",e[e.Color_NOC_GRAY13=145]="Color_NOC_GRAY13",e[e.Color_NOC_GRAY14=146]="Color_NOC_GRAY14",e[e.Color_NOC_GRAY15=147]="Color_NOC_GRAY15",e[e.Color_NOC_GRAY16=148]="Color_NOC_GRAY16",e[e.Color_NOC_GRAY17=149]="Color_NOC_GRAY17",e[e.Color_NOC_GRAY18=150]="Color_NOC_GRAY18",e[e.Color_NOC_GRAY19=151]="Color_NOC_GRAY19",e[e.Color_NOC_GRAY20=152]="Color_NOC_GRAY20",e[e.Color_NOC_GRAY21=153]="Color_NOC_GRAY21",e[e.Color_NOC_GRAY22=154]="Color_NOC_GRAY22",e[e.Color_NOC_GRAY23=155]="Color_NOC_GRAY23",e[e.Color_NOC_GRAY24=156]="Color_NOC_GRAY24",e[e.Color_NOC_GRAY25=157]="Color_NOC_GRAY25",e[e.Color_NOC_GRAY26=158]="Color_NOC_GRAY26",e[e.Color_NOC_GRAY27=159]="Color_NOC_GRAY27",e[e.Color_NOC_GRAY28=160]="Color_NOC_GRAY28",e[e.Color_NOC_GRAY29=161]="Color_NOC_GRAY29",e[e.Color_NOC_GRAY30=162]="Color_NOC_GRAY30",e[e.Color_NOC_GRAY31=163]="Color_NOC_GRAY31",e[e.Color_NOC_GRAY32=164]="Color_NOC_GRAY32",e[e.Color_NOC_GRAY33=165]="Color_NOC_GRAY33",e[e.Color_NOC_GRAY34=166]="Color_NOC_GRAY34",e[e.Color_NOC_GRAY35=167]="Color_NOC_GRAY35",e[e.Color_NOC_GRAY36=168]="Color_NOC_GRAY36",e[e.Color_NOC_GRAY37=169]="Color_NOC_GRAY37",e[e.Color_NOC_GRAY38=170]="Color_NOC_GRAY38",e[e.Color_NOC_GRAY39=171]="Color_NOC_GRAY39",e[e.Color_NOC_GRAY40=172]="Color_NOC_GRAY40",e[e.Color_NOC_GRAY41=173]="Color_NOC_GRAY41",e[e.Color_NOC_GRAY42=174]="Color_NOC_GRAY42",e[e.Color_NOC_GRAY43=175]="Color_NOC_GRAY43",e[e.Color_NOC_GRAY44=176]="Color_NOC_GRAY44",e[e.Color_NOC_GRAY45=177]="Color_NOC_GRAY45",e[e.Color_NOC_GRAY46=178]="Color_NOC_GRAY46",e[e.Color_NOC_GRAY47=179]="Color_NOC_GRAY47",e[e.Color_NOC_GRAY48=180]="Color_NOC_GRAY48",e[e.Color_NOC_GRAY49=181]="Color_NOC_GRAY49",e[e.Color_NOC_GRAY50=182]="Color_NOC_GRAY50",e[e.Color_NOC_GRAY51=183]="Color_NOC_GRAY51",e[e.Color_NOC_GRAY52=184]="Color_NOC_GRAY52",e[e.Color_NOC_GRAY53=185]="Color_NOC_GRAY53",e[e.Color_NOC_GRAY54=186]="Color_NOC_GRAY54",e[e.Color_NOC_GRAY55=187]="Color_NOC_GRAY55",e[e.Color_NOC_GRAY56=188]="Color_NOC_GRAY56",e[e.Color_NOC_GRAY57=189]="Color_NOC_GRAY57",e[e.Color_NOC_GRAY58=190]="Color_NOC_GRAY58",e[e.Color_NOC_GRAY59=191]="Color_NOC_GRAY59",e[e.Color_NOC_GRAY60=192]="Color_NOC_GRAY60",e[e.Color_NOC_GRAY61=193]="Color_NOC_GRAY61",e[e.Color_NOC_GRAY62=194]="Color_NOC_GRAY62",e[e.Color_NOC_GRAY63=195]="Color_NOC_GRAY63",e[e.Color_NOC_GRAY64=196]="Color_NOC_GRAY64",e[e.Color_NOC_GRAY65=197]="Color_NOC_GRAY65",e[e.Color_NOC_GRAY66=198]="Color_NOC_GRAY66",e[e.Color_NOC_GRAY67=199]="Color_NOC_GRAY67",e[e.Color_NOC_GRAY68=200]="Color_NOC_GRAY68",e[e.Color_NOC_GRAY69=201]="Color_NOC_GRAY69",e[e.Color_NOC_GRAY70=202]="Color_NOC_GRAY70",e[e.Color_NOC_GRAY71=203]="Color_NOC_GRAY71",e[e.Color_NOC_GRAY72=204]="Color_NOC_GRAY72",e[e.Color_NOC_GRAY73=205]="Color_NOC_GRAY73",e[e.Color_NOC_GRAY74=206]="Color_NOC_GRAY74",e[e.Color_NOC_GRAY75=207]="Color_NOC_GRAY75",e[e.Color_NOC_GRAY76=208]="Color_NOC_GRAY76",e[e.Color_NOC_GRAY77=209]="Color_NOC_GRAY77",e[e.Color_NOC_GRAY78=210]="Color_NOC_GRAY78",e[e.Color_NOC_GRAY79=211]="Color_NOC_GRAY79",e[e.Color_NOC_GRAY80=212]="Color_NOC_GRAY80",e[e.Color_NOC_GRAY81=213]="Color_NOC_GRAY81",e[e.Color_NOC_GRAY82=214]="Color_NOC_GRAY82",e[e.Color_NOC_GRAY83=215]="Color_NOC_GRAY83",e[e.Color_NOC_GRAY85=216]="Color_NOC_GRAY85",e[e.Color_NOC_GRAY86=217]="Color_NOC_GRAY86",e[e.Color_NOC_GRAY87=218]="Color_NOC_GRAY87",e[e.Color_NOC_GRAY88=219]="Color_NOC_GRAY88",e[e.Color_NOC_GRAY89=220]="Color_NOC_GRAY89",e[e.Color_NOC_GRAY90=221]="Color_NOC_GRAY90",e[e.Color_NOC_GRAY91=222]="Color_NOC_GRAY91",e[e.Color_NOC_GRAY92=223]="Color_NOC_GRAY92",e[e.Color_NOC_GRAY93=224]="Color_NOC_GRAY93",e[e.Color_NOC_GRAY94=225]="Color_NOC_GRAY94",e[e.Color_NOC_GRAY95=226]="Color_NOC_GRAY95",e[e.Color_NOC_GRAY97=227]="Color_NOC_GRAY97",e[e.Color_NOC_GRAY98=228]="Color_NOC_GRAY98",e[e.Color_NOC_GRAY99=229]="Color_NOC_GRAY99",e[e.Color_NOC_GREEN=230]="Color_NOC_GREEN",e[e.Color_NOC_GREEN1=230]="Color_NOC_GREEN1",e[e.Color_NOC_GREEN2=231]="Color_NOC_GREEN2",e[e.Color_NOC_GREEN3=232]="Color_NOC_GREEN3",e[e.Color_NOC_GREEN4=233]="Color_NOC_GREEN4",e[e.Color_NOC_GREENYELLOW=234]="Color_NOC_GREENYELLOW",e[e.Color_NOC_HONEYDEW=235]="Color_NOC_HONEYDEW",e[e.Color_NOC_HONEYDEW2=236]="Color_NOC_HONEYDEW2",e[e.Color_NOC_HONEYDEW3=237]="Color_NOC_HONEYDEW3",e[e.Color_NOC_HONEYDEW4=238]="Color_NOC_HONEYDEW4",e[e.Color_NOC_HOTPINK=239]="Color_NOC_HOTPINK",e[e.Color_NOC_HOTPINK1=240]="Color_NOC_HOTPINK1",e[e.Color_NOC_HOTPINK2=241]="Color_NOC_HOTPINK2",e[e.Color_NOC_HOTPINK3=242]="Color_NOC_HOTPINK3",e[e.Color_NOC_HOTPINK4=243]="Color_NOC_HOTPINK4",e[e.Color_NOC_INDIANRED=244]="Color_NOC_INDIANRED",e[e.Color_NOC_INDIANRED1=245]="Color_NOC_INDIANRED1",e[e.Color_NOC_INDIANRED2=246]="Color_NOC_INDIANRED2",e[e.Color_NOC_INDIANRED3=247]="Color_NOC_INDIANRED3",e[e.Color_NOC_INDIANRED4=248]="Color_NOC_INDIANRED4",e[e.Color_NOC_IVORY=249]="Color_NOC_IVORY",e[e.Color_NOC_IVORY2=250]="Color_NOC_IVORY2",e[e.Color_NOC_IVORY3=251]="Color_NOC_IVORY3",e[e.Color_NOC_IVORY4=252]="Color_NOC_IVORY4",e[e.Color_NOC_KHAKI=253]="Color_NOC_KHAKI",e[e.Color_NOC_KHAKI1=254]="Color_NOC_KHAKI1",e[e.Color_NOC_KHAKI2=255]="Color_NOC_KHAKI2",e[e.Color_NOC_KHAKI3=256]="Color_NOC_KHAKI3",e[e.Color_NOC_KHAKI4=257]="Color_NOC_KHAKI4",e[e.Color_NOC_LAVENDER=258]="Color_NOC_LAVENDER",e[e.Color_NOC_LAVENDERBLUSH1=259]="Color_NOC_LAVENDERBLUSH1",e[e.Color_NOC_LAVENDERBLUSH2=260]="Color_NOC_LAVENDERBLUSH2",e[e.Color_NOC_LAVENDERBLUSH3=261]="Color_NOC_LAVENDERBLUSH3",e[e.Color_NOC_LAVENDERBLUSH4=262]="Color_NOC_LAVENDERBLUSH4",e[e.Color_NOC_LAWNGREEN=263]="Color_NOC_LAWNGREEN",e[e.Color_NOC_LEMONCHIFFON1=264]="Color_NOC_LEMONCHIFFON1",e[e.Color_NOC_LEMONCHIFFON2=265]="Color_NOC_LEMONCHIFFON2",e[e.Color_NOC_LEMONCHIFFON3=266]="Color_NOC_LEMONCHIFFON3",e[e.Color_NOC_LEMONCHIFFON4=267]="Color_NOC_LEMONCHIFFON4",e[e.Color_NOC_LIGHTBLUE=268]="Color_NOC_LIGHTBLUE",e[e.Color_NOC_LIGHTBLUE1=269]="Color_NOC_LIGHTBLUE1",e[e.Color_NOC_LIGHTBLUE2=270]="Color_NOC_LIGHTBLUE2",e[e.Color_NOC_LIGHTBLUE3=271]="Color_NOC_LIGHTBLUE3",e[e.Color_NOC_LIGHTBLUE4=272]="Color_NOC_LIGHTBLUE4",e[e.Color_NOC_LIGHTCORAL=273]="Color_NOC_LIGHTCORAL",e[e.Color_NOC_LIGHTCYAN=274]="Color_NOC_LIGHTCYAN",e[e.Color_NOC_LIGHTCYAN1=274]="Color_NOC_LIGHTCYAN1",e[e.Color_NOC_LIGHTCYAN2=275]="Color_NOC_LIGHTCYAN2",e[e.Color_NOC_LIGHTCYAN3=276]="Color_NOC_LIGHTCYAN3",e[e.Color_NOC_LIGHTCYAN4=277]="Color_NOC_LIGHTCYAN4",e[e.Color_NOC_LIGHTGOLDENROD=278]="Color_NOC_LIGHTGOLDENROD",e[e.Color_NOC_LIGHTGOLDENROD1=279]="Color_NOC_LIGHTGOLDENROD1",e[e.Color_NOC_LIGHTGOLDENROD2=280]="Color_NOC_LIGHTGOLDENROD2",e[e.Color_NOC_LIGHTGOLDENROD3=281]="Color_NOC_LIGHTGOLDENROD3",e[e.Color_NOC_LIGHTGOLDENROD4=282]="Color_NOC_LIGHTGOLDENROD4",e[e.Color_NOC_LIGHTGOLDENRODYELLOW=283]="Color_NOC_LIGHTGOLDENRODYELLOW",e[e.Color_NOC_LIGHTGRAY=284]="Color_NOC_LIGHTGRAY",e[e.Color_NOC_LIGHTPINK=285]="Color_NOC_LIGHTPINK",e[e.Color_NOC_LIGHTPINK1=286]="Color_NOC_LIGHTPINK1",e[e.Color_NOC_LIGHTPINK2=287]="Color_NOC_LIGHTPINK2",e[e.Color_NOC_LIGHTPINK3=288]="Color_NOC_LIGHTPINK3",e[e.Color_NOC_LIGHTPINK4=289]="Color_NOC_LIGHTPINK4",e[e.Color_NOC_LIGHTSALMON1=290]="Color_NOC_LIGHTSALMON1",e[e.Color_NOC_LIGHTSALMON2=291]="Color_NOC_LIGHTSALMON2",e[e.Color_NOC_LIGHTSALMON3=292]="Color_NOC_LIGHTSALMON3",e[e.Color_NOC_LIGHTSALMON4=293]="Color_NOC_LIGHTSALMON4",e[e.Color_NOC_LIGHTSEAGREEN=294]="Color_NOC_LIGHTSEAGREEN",e[e.Color_NOC_LIGHTSKYBLUE=295]="Color_NOC_LIGHTSKYBLUE",e[e.Color_NOC_LIGHTSKYBLUE1=296]="Color_NOC_LIGHTSKYBLUE1",e[e.Color_NOC_LIGHTSKYBLUE2=297]="Color_NOC_LIGHTSKYBLUE2",e[e.Color_NOC_LIGHTSKYBLUE3=298]="Color_NOC_LIGHTSKYBLUE3",e[e.Color_NOC_LIGHTSKYBLUE4=299]="Color_NOC_LIGHTSKYBLUE4",e[e.Color_NOC_LIGHTSLATEBLUE=300]="Color_NOC_LIGHTSLATEBLUE",e[e.Color_NOC_LIGHTSLATEGRAY=301]="Color_NOC_LIGHTSLATEGRAY",e[e.Color_NOC_LIGHTSTEELBLUE=302]="Color_NOC_LIGHTSTEELBLUE",e[e.Color_NOC_LIGHTSTEELBLUE1=303]="Color_NOC_LIGHTSTEELBLUE1",e[e.Color_NOC_LIGHTSTEELBLUE2=304]="Color_NOC_LIGHTSTEELBLUE2",e[e.Color_NOC_LIGHTSTEELBLUE3=305]="Color_NOC_LIGHTSTEELBLUE3",e[e.Color_NOC_LIGHTSTEELBLUE4=306]="Color_NOC_LIGHTSTEELBLUE4",e[e.Color_NOC_LIGHTYELLOW=307]="Color_NOC_LIGHTYELLOW",e[e.Color_NOC_LIGHTYELLOW2=308]="Color_NOC_LIGHTYELLOW2",e[e.Color_NOC_LIGHTYELLOW3=309]="Color_NOC_LIGHTYELLOW3",e[e.Color_NOC_LIGHTYELLOW4=310]="Color_NOC_LIGHTYELLOW4",e[e.Color_NOC_LIMEGREEN=311]="Color_NOC_LIMEGREEN",e[e.Color_NOC_LINEN=312]="Color_NOC_LINEN",e[e.Color_NOC_MAGENTA=313]="Color_NOC_MAGENTA",e[e.Color_NOC_MAGENTA1=313]="Color_NOC_MAGENTA1",e[e.Color_NOC_MAGENTA2=314]="Color_NOC_MAGENTA2",e[e.Color_NOC_MAGENTA3=315]="Color_NOC_MAGENTA3",e[e.Color_NOC_MAGENTA4=316]="Color_NOC_MAGENTA4",e[e.Color_NOC_MAROON=317]="Color_NOC_MAROON",e[e.Color_NOC_MAROON1=318]="Color_NOC_MAROON1",e[e.Color_NOC_MAROON2=319]="Color_NOC_MAROON2",e[e.Color_NOC_MAROON3=320]="Color_NOC_MAROON3",e[e.Color_NOC_MAROON4=321]="Color_NOC_MAROON4",e[e.Color_NOC_MEDIUMAQUAMARINE=322]="Color_NOC_MEDIUMAQUAMARINE",e[e.Color_NOC_MEDIUMORCHID=323]="Color_NOC_MEDIUMORCHID",e[e.Color_NOC_MEDIUMORCHID1=324]="Color_NOC_MEDIUMORCHID1",e[e.Color_NOC_MEDIUMORCHID2=325]="Color_NOC_MEDIUMORCHID2",e[e.Color_NOC_MEDIUMORCHID3=326]="Color_NOC_MEDIUMORCHID3",e[e.Color_NOC_MEDIUMORCHID4=327]="Color_NOC_MEDIUMORCHID4",e[e.Color_NOC_MEDIUMPURPLE=328]="Color_NOC_MEDIUMPURPLE",e[e.Color_NOC_MEDIUMPURPLE1=329]="Color_NOC_MEDIUMPURPLE1",e[e.Color_NOC_MEDIUMPURPLE2=330]="Color_NOC_MEDIUMPURPLE2",e[e.Color_NOC_MEDIUMPURPLE3=331]="Color_NOC_MEDIUMPURPLE3",e[e.Color_NOC_MEDIUMPURPLE4=332]="Color_NOC_MEDIUMPURPLE4",e[e.Color_NOC_MEDIUMSEAGREEN=333]="Color_NOC_MEDIUMSEAGREEN",e[e.Color_NOC_MEDIUMSLATEBLUE=334]="Color_NOC_MEDIUMSLATEBLUE",e[e.Color_NOC_MEDIUMSPRINGGREEN=335]="Color_NOC_MEDIUMSPRINGGREEN",e[e.Color_NOC_MEDIUMTURQUOISE=336]="Color_NOC_MEDIUMTURQUOISE",e[e.Color_NOC_MEDIUMVIOLETRED=337]="Color_NOC_MEDIUMVIOLETRED",e[e.Color_NOC_MIDNIGHTBLUE=338]="Color_NOC_MIDNIGHTBLUE",e[e.Color_NOC_MINTCREAM=339]="Color_NOC_MINTCREAM",e[e.Color_NOC_MISTYROSE=340]="Color_NOC_MISTYROSE",e[e.Color_NOC_MISTYROSE2=341]="Color_NOC_MISTYROSE2",e[e.Color_NOC_MISTYROSE3=342]="Color_NOC_MISTYROSE3",e[e.Color_NOC_MISTYROSE4=343]="Color_NOC_MISTYROSE4",e[e.Color_NOC_MOCCASIN=344]="Color_NOC_MOCCASIN",e[e.Color_NOC_NAVAJOWHITE1=345]="Color_NOC_NAVAJOWHITE1",e[e.Color_NOC_NAVAJOWHITE2=346]="Color_NOC_NAVAJOWHITE2",e[e.Color_NOC_NAVAJOWHITE3=347]="Color_NOC_NAVAJOWHITE3",e[e.Color_NOC_NAVAJOWHITE4=348]="Color_NOC_NAVAJOWHITE4",e[e.Color_NOC_NAVYBLUE=349]="Color_NOC_NAVYBLUE",e[e.Color_NOC_OLDLACE=350]="Color_NOC_OLDLACE",e[e.Color_NOC_OLIVEDRAB=351]="Color_NOC_OLIVEDRAB",e[e.Color_NOC_OLIVEDRAB1=352]="Color_NOC_OLIVEDRAB1",e[e.Color_NOC_OLIVEDRAB2=353]="Color_NOC_OLIVEDRAB2",e[e.Color_NOC_OLIVEDRAB3=354]="Color_NOC_OLIVEDRAB3",e[e.Color_NOC_OLIVEDRAB4=355]="Color_NOC_OLIVEDRAB4",e[e.Color_NOC_ORANGE=356]="Color_NOC_ORANGE",e[e.Color_NOC_ORANGE1=356]="Color_NOC_ORANGE1",e[e.Color_NOC_ORANGE2=357]="Color_NOC_ORANGE2",e[e.Color_NOC_ORANGE3=358]="Color_NOC_ORANGE3",e[e.Color_NOC_ORANGE4=359]="Color_NOC_ORANGE4",e[e.Color_NOC_ORANGERED=360]="Color_NOC_ORANGERED",e[e.Color_NOC_ORANGERED1=360]="Color_NOC_ORANGERED1",e[e.Color_NOC_ORANGERED2=361]="Color_NOC_ORANGERED2",e[e.Color_NOC_ORANGERED3=362]="Color_NOC_ORANGERED3",e[e.Color_NOC_ORANGERED4=363]="Color_NOC_ORANGERED4",e[e.Color_NOC_ORCHID=364]="Color_NOC_ORCHID",e[e.Color_NOC_ORCHID1=365]="Color_NOC_ORCHID1",e[e.Color_NOC_ORCHID2=366]="Color_NOC_ORCHID2",e[e.Color_NOC_ORCHID3=367]="Color_NOC_ORCHID3",e[e.Color_NOC_ORCHID4=368]="Color_NOC_ORCHID4",e[e.Color_NOC_PALEGOLDENROD=369]="Color_NOC_PALEGOLDENROD",e[e.Color_NOC_PALEGREEN=370]="Color_NOC_PALEGREEN",e[e.Color_NOC_PALEGREEN1=371]="Color_NOC_PALEGREEN1",e[e.Color_NOC_PALEGREEN2=372]="Color_NOC_PALEGREEN2",e[e.Color_NOC_PALEGREEN3=373]="Color_NOC_PALEGREEN3",e[e.Color_NOC_PALEGREEN4=374]="Color_NOC_PALEGREEN4",e[e.Color_NOC_PALETURQUOISE=375]="Color_NOC_PALETURQUOISE",e[e.Color_NOC_PALETURQUOISE1=376]="Color_NOC_PALETURQUOISE1",e[e.Color_NOC_PALETURQUOISE2=377]="Color_NOC_PALETURQUOISE2",e[e.Color_NOC_PALETURQUOISE3=378]="Color_NOC_PALETURQUOISE3",e[e.Color_NOC_PALETURQUOISE4=379]="Color_NOC_PALETURQUOISE4",e[e.Color_NOC_PALEVIOLETRED=380]="Color_NOC_PALEVIOLETRED",e[e.Color_NOC_PALEVIOLETRED1=381]="Color_NOC_PALEVIOLETRED1",e[e.Color_NOC_PALEVIOLETRED2=382]="Color_NOC_PALEVIOLETRED2",e[e.Color_NOC_PALEVIOLETRED3=383]="Color_NOC_PALEVIOLETRED3",e[e.Color_NOC_PALEVIOLETRED4=384]="Color_NOC_PALEVIOLETRED4",e[e.Color_NOC_PAPAYAWHIP=385]="Color_NOC_PAPAYAWHIP",e[e.Color_NOC_PEACHPUFF=386]="Color_NOC_PEACHPUFF",e[e.Color_NOC_PEACHPUFF2=387]="Color_NOC_PEACHPUFF2",e[e.Color_NOC_PEACHPUFF3=388]="Color_NOC_PEACHPUFF3",e[e.Color_NOC_PEACHPUFF4=389]="Color_NOC_PEACHPUFF4",e[e.Color_NOC_PERU=390]="Color_NOC_PERU",e[e.Color_NOC_PINK=391]="Color_NOC_PINK",e[e.Color_NOC_PINK1=392]="Color_NOC_PINK1",e[e.Color_NOC_PINK2=393]="Color_NOC_PINK2",e[e.Color_NOC_PINK3=394]="Color_NOC_PINK3",e[e.Color_NOC_PINK4=395]="Color_NOC_PINK4",e[e.Color_NOC_PLUM=396]="Color_NOC_PLUM",e[e.Color_NOC_PLUM1=397]="Color_NOC_PLUM1",e[e.Color_NOC_PLUM2=398]="Color_NOC_PLUM2",e[e.Color_NOC_PLUM3=399]="Color_NOC_PLUM3",e[e.Color_NOC_PLUM4=400]="Color_NOC_PLUM4",e[e.Color_NOC_POWDERBLUE=401]="Color_NOC_POWDERBLUE",e[e.Color_NOC_PURPLE=402]="Color_NOC_PURPLE",e[e.Color_NOC_PURPLE1=403]="Color_NOC_PURPLE1",e[e.Color_NOC_PURPLE2=404]="Color_NOC_PURPLE2",e[e.Color_NOC_PURPLE3=405]="Color_NOC_PURPLE3",e[e.Color_NOC_PURPLE4=406]="Color_NOC_PURPLE4",e[e.Color_NOC_RED=407]="Color_NOC_RED",e[e.Color_NOC_RED1=407]="Color_NOC_RED1",e[e.Color_NOC_RED2=408]="Color_NOC_RED2",e[e.Color_NOC_RED3=409]="Color_NOC_RED3",e[e.Color_NOC_RED4=410]="Color_NOC_RED4",e[e.Color_NOC_ROSYBROWN=411]="Color_NOC_ROSYBROWN",e[e.Color_NOC_ROSYBROWN1=412]="Color_NOC_ROSYBROWN1",e[e.Color_NOC_ROSYBROWN2=413]="Color_NOC_ROSYBROWN2",e[e.Color_NOC_ROSYBROWN3=414]="Color_NOC_ROSYBROWN3",e[e.Color_NOC_ROSYBROWN4=415]="Color_NOC_ROSYBROWN4",e[e.Color_NOC_ROYALBLUE=416]="Color_NOC_ROYALBLUE",e[e.Color_NOC_ROYALBLUE1=417]="Color_NOC_ROYALBLUE1",e[e.Color_NOC_ROYALBLUE2=418]="Color_NOC_ROYALBLUE2",e[e.Color_NOC_ROYALBLUE3=419]="Color_NOC_ROYALBLUE3",e[e.Color_NOC_ROYALBLUE4=420]="Color_NOC_ROYALBLUE4",e[e.Color_NOC_SADDLEBROWN=421]="Color_NOC_SADDLEBROWN",e[e.Color_NOC_SALMON=422]="Color_NOC_SALMON",e[e.Color_NOC_SALMON1=423]="Color_NOC_SALMON1",e[e.Color_NOC_SALMON2=424]="Color_NOC_SALMON2",e[e.Color_NOC_SALMON3=425]="Color_NOC_SALMON3",e[e.Color_NOC_SALMON4=426]="Color_NOC_SALMON4",e[e.Color_NOC_SANDYBROWN=427]="Color_NOC_SANDYBROWN",e[e.Color_NOC_SEAGREEN=428]="Color_NOC_SEAGREEN",e[e.Color_NOC_SEAGREEN1=429]="Color_NOC_SEAGREEN1",e[e.Color_NOC_SEAGREEN2=430]="Color_NOC_SEAGREEN2",e[e.Color_NOC_SEAGREEN3=431]="Color_NOC_SEAGREEN3",e[e.Color_NOC_SEAGREEN4=432]="Color_NOC_SEAGREEN4",e[e.Color_NOC_SEASHELL=433]="Color_NOC_SEASHELL",e[e.Color_NOC_SEASHELL2=434]="Color_NOC_SEASHELL2",e[e.Color_NOC_SEASHELL3=435]="Color_NOC_SEASHELL3",e[e.Color_NOC_SEASHELL4=436]="Color_NOC_SEASHELL4",e[e.Color_NOC_BEET=437]="Color_NOC_BEET",e[e.Color_NOC_TEAL=438]="Color_NOC_TEAL",e[e.Color_NOC_SIENNA=439]="Color_NOC_SIENNA",e[e.Color_NOC_SIENNA1=440]="Color_NOC_SIENNA1",e[e.Color_NOC_SIENNA2=441]="Color_NOC_SIENNA2",e[e.Color_NOC_SIENNA3=442]="Color_NOC_SIENNA3",e[e.Color_NOC_SIENNA4=443]="Color_NOC_SIENNA4",e[e.Color_NOC_SKYBLUE=444]="Color_NOC_SKYBLUE",e[e.Color_NOC_SKYBLUE1=445]="Color_NOC_SKYBLUE1",e[e.Color_NOC_SKYBLUE2=446]="Color_NOC_SKYBLUE2",e[e.Color_NOC_SKYBLUE3=447]="Color_NOC_SKYBLUE3",e[e.Color_NOC_SKYBLUE4=448]="Color_NOC_SKYBLUE4",e[e.Color_NOC_SLATEBLUE=449]="Color_NOC_SLATEBLUE",e[e.Color_NOC_SLATEBLUE1=450]="Color_NOC_SLATEBLUE1",e[e.Color_NOC_SLATEBLUE2=451]="Color_NOC_SLATEBLUE2",e[e.Color_NOC_SLATEBLUE3=452]="Color_NOC_SLATEBLUE3",e[e.Color_NOC_SLATEBLUE4=453]="Color_NOC_SLATEBLUE4",e[e.Color_NOC_SLATEGRAY1=454]="Color_NOC_SLATEGRAY1",e[e.Color_NOC_SLATEGRAY2=455]="Color_NOC_SLATEGRAY2",e[e.Color_NOC_SLATEGRAY3=456]="Color_NOC_SLATEGRAY3",e[e.Color_NOC_SLATEGRAY4=457]="Color_NOC_SLATEGRAY4",e[e.Color_NOC_SLATEGRAY=458]="Color_NOC_SLATEGRAY",e[e.Color_NOC_SNOW=459]="Color_NOC_SNOW",e[e.Color_NOC_SNOW2=460]="Color_NOC_SNOW2",e[e.Color_NOC_SNOW3=461]="Color_NOC_SNOW3",e[e.Color_NOC_SNOW4=462]="Color_NOC_SNOW4",e[e.Color_NOC_SPRINGGREEN=463]="Color_NOC_SPRINGGREEN",e[e.Color_NOC_SPRINGGREEN2=464]="Color_NOC_SPRINGGREEN2",e[e.Color_NOC_SPRINGGREEN3=465]="Color_NOC_SPRINGGREEN3",e[e.Color_NOC_SPRINGGREEN4=466]="Color_NOC_SPRINGGREEN4",e[e.Color_NOC_STEELBLUE=467]="Color_NOC_STEELBLUE",e[e.Color_NOC_STEELBLUE1=468]="Color_NOC_STEELBLUE1",e[e.Color_NOC_STEELBLUE2=469]="Color_NOC_STEELBLUE2",e[e.Color_NOC_STEELBLUE3=470]="Color_NOC_STEELBLUE3",e[e.Color_NOC_STEELBLUE4=471]="Color_NOC_STEELBLUE4",e[e.Color_NOC_TAN=472]="Color_NOC_TAN",e[e.Color_NOC_TAN1=473]="Color_NOC_TAN1",e[e.Color_NOC_TAN2=474]="Color_NOC_TAN2",e[e.Color_NOC_TAN3=475]="Color_NOC_TAN3",e[e.Color_NOC_TAN4=476]="Color_NOC_TAN4",e[e.Color_NOC_THISTLE=477]="Color_NOC_THISTLE",e[e.Color_NOC_THISTLE1=478]="Color_NOC_THISTLE1",e[e.Color_NOC_THISTLE2=479]="Color_NOC_THISTLE2",e[e.Color_NOC_THISTLE3=480]="Color_NOC_THISTLE3",e[e.Color_NOC_THISTLE4=481]="Color_NOC_THISTLE4",e[e.Color_NOC_TOMATO=482]="Color_NOC_TOMATO",e[e.Color_NOC_TOMATO1=482]="Color_NOC_TOMATO1",e[e.Color_NOC_TOMATO2=483]="Color_NOC_TOMATO2",e[e.Color_NOC_TOMATO3=484]="Color_NOC_TOMATO3",e[e.Color_NOC_TOMATO4=485]="Color_NOC_TOMATO4",e[e.Color_NOC_TURQUOISE=486]="Color_NOC_TURQUOISE",e[e.Color_NOC_TURQUOISE1=487]="Color_NOC_TURQUOISE1",e[e.Color_NOC_TURQUOISE2=488]="Color_NOC_TURQUOISE2",e[e.Color_NOC_TURQUOISE3=489]="Color_NOC_TURQUOISE3",e[e.Color_NOC_TURQUOISE4=490]="Color_NOC_TURQUOISE4",e[e.Color_NOC_VIOLET=491]="Color_NOC_VIOLET",e[e.Color_NOC_VIOLETRED=492]="Color_NOC_VIOLETRED",e[e.Color_NOC_VIOLETRED1=493]="Color_NOC_VIOLETRED1",e[e.Color_NOC_VIOLETRED2=494]="Color_NOC_VIOLETRED2",e[e.Color_NOC_VIOLETRED3=495]="Color_NOC_VIOLETRED3",e[e.Color_NOC_VIOLETRED4=496]="Color_NOC_VIOLETRED4",e[e.Color_NOC_WHEAT=497]="Color_NOC_WHEAT",e[e.Color_NOC_WHEAT1=498]="Color_NOC_WHEAT1",e[e.Color_NOC_WHEAT2=499]="Color_NOC_WHEAT2",e[e.Color_NOC_WHEAT3=500]="Color_NOC_WHEAT3",e[e.Color_NOC_WHEAT4=501]="Color_NOC_WHEAT4",e[e.Color_NOC_WHITESMOKE=502]="Color_NOC_WHITESMOKE",e[e.Color_NOC_YELLOW=503]="Color_NOC_YELLOW",e[e.Color_NOC_YELLOW1=503]="Color_NOC_YELLOW1",e[e.Color_NOC_YELLOW2=504]="Color_NOC_YELLOW2",e[e.Color_NOC_YELLOW3=505]="Color_NOC_YELLOW3",e[e.Color_NOC_YELLOW4=506]="Color_NOC_YELLOW4",e[e.Color_NOC_YELLOWGREEN=507]="Color_NOC_YELLOWGREEN",e[e.Color_NOC_WHITE=508]="Color_NOC_WHITE"}(t.MxNameOfColor||(t.MxNameOfColor={})),function(e){e[e.Color_TOC_RGB=0]="Color_TOC_RGB",e[e.Color_TOC_sRGB=1]="Color_TOC_sRGB",e[e.Color_TOC_HLS=2]="Color_TOC_HLS",e[e.Color_TOC_CIELab=3]="Color_TOC_CIELab",e[e.Color_TOC_CIELch=4]="Color_TOC_CIELch"}(t.MxTypeOfColor||(t.MxTypeOfColor={})),function(e){e[e.DM_WireFrame=0]="DM_WireFrame",e[e.DM_Shaded=1]="DM_Shaded"}(t.MxDisplayMode||(t.MxDisplayMode={})),function(e){e[e.LightSource_TOLS_AMBIENT=0]="LightSource_TOLS_AMBIENT",e[e.LightSource_TOLS_DIRECTIONAL=1]="LightSource_TOLS_DIRECTIONAL",e[e.LightSource_TOLS_POSITIONAL=2]="LightSource_TOLS_POSITIONAL",e[e.LightSource_TOLS_SPOT=3]="LightSource_TOLS_SPOT"}(t.MxTypeOfLightSource||(t.MxTypeOfLightSource={})),function(e){e[e.CProjection_Orthographic=0]="CProjection_Orthographic",e[e.CProjection_Perspective=1]="CProjection_Perspective",e[e.CProjection_Stereo=2]="CProjection_Stereo",e[e.CProjection_MonoLeftEye=3]="CProjection_MonoLeftEye",e[e.CProjection_MonoRightEye=4]="CProjection_MonoRightEye"}(t.MxCameraProjection||(t.MxCameraProjection={})),function(e){e[e.Orientation_Xpos=0]="Orientation_Xpos",e[e.Orientation_Ypos=1]="Orientation_Ypos",e[e.Orientation_Zpos=2]="Orientation_Zpos",e[e.Orientation_Xneg=3]="Orientation_Xneg",e[e.Orientation_Yneg=4]="Orientation_Yneg",e[e.Orientation_Zneg=5]="Orientation_Zneg",e[e.Orientation_XposYpos=6]="Orientation_XposYpos",e[e.Orientation_XposZpos=7]="Orientation_XposZpos",e[e.Orientation_YposZpos=8]="Orientation_YposZpos",e[e.Orientation_XnegYneg=9]="Orientation_XnegYneg",e[e.Orientation_XnegYpos=10]="Orientation_XnegYpos",e[e.Orientation_XnegZneg=11]="Orientation_XnegZneg",e[e.Orientation_XnegZpos=12]="Orientation_XnegZpos",e[e.Orientation_YnegZneg=13]="Orientation_YnegZneg",e[e.Orientation_YnegZpos=14]="Orientation_YnegZpos",e[e.Orientation_XposYneg=15]="Orientation_XposYneg",e[e.Orientation_XposZneg=16]="Orientation_XposZneg",e[e.Orientation_YposZneg=17]="Orientation_YposZneg",e[e.Orientation_XposYposZpos=18]="Orientation_XposYposZpos",e[e.Orientation_XposYnegZpos=19]="Orientation_XposYnegZpos",e[e.Orientation_XposYposZneg=20]="Orientation_XposYposZneg",e[e.Orientation_XnegYposZpos=21]="Orientation_XnegYposZpos",e[e.Orientation_XposYnegZneg=22]="Orientation_XposYnegZneg",e[e.Orientation_XnegYposZneg=23]="Orientation_XnegYposZneg",e[e.Orientation_XnegYnegZpos=24]="Orientation_XnegYnegZpos",e[e.Orientation_XnegYnegZneg=25]="Orientation_XnegYnegZneg",e[e.Orientation_TypeOfOrientation_Zup_AxoLeft=24]="Orientation_TypeOfOrientation_Zup_AxoLeft",e[e.Orientation_TypeOfOrientation_Zup_AxoRight=19]="Orientation_TypeOfOrientation_Zup_AxoRight",e[e.Orientation_TypeOfOrientation_Zup_Front=4]="Orientation_TypeOfOrientation_Zup_Front",e[e.Orientation_TypeOfOrientation_Zup_Back=1]="Orientation_TypeOfOrientation_Zup_Back",e[e.Orientation_TypeOfOrientation_Zup_Top=2]="Orientation_TypeOfOrientation_Zup_Top",e[e.Orientation_TypeOfOrientation_Zup_Bottom=5]="Orientation_TypeOfOrientation_Zup_Bottom",e[e.Orientation_TypeOfOrientation_Zup_Left=3]="Orientation_TypeOfOrientation_Zup_Left",e[e.Orientation_TypeOfOrientation_Zup_Right=0]="Orientation_TypeOfOrientation_Zup_Right",e[e.Orientation_TypeOfOrientation_Yup_AxoLeft=21]="Orientation_TypeOfOrientation_Yup_AxoLeft",e[e.Orientation_TypeOfOrientation_Yup_AxoRight=18]="Orientation_TypeOfOrientation_Yup_AxoRight",e[e.Orientation_TypeOfOrientation_Yup_Front=2]="Orientation_TypeOfOrientation_Yup_Front",e[e.Orientation_TypeOfOrientation_Yup_Back=5]="Orientation_TypeOfOrientation_Yup_Back",e[e.Orientation_TypeOfOrientation_Yup_Top=1]="Orientation_TypeOfOrientation_Yup_Top",e[e.Orientation_TypeOfOrientation_Yup_Bottom=4]="Orientation_TypeOfOrientation_Yup_Bottom",e[e.Orientation_TypeOfOrientation_Yup_Left=0]="Orientation_TypeOfOrientation_Yup_Left",e[e.Orientation_TypeOfOrientation_Yup_Right=3]="Orientation_TypeOfOrientation_Yup_Right"}(t.MxV3dTypeOfOrientation||(t.MxV3dTypeOfOrientation={})),function(e){e[e.Angle_TypeOfAngle_Interior=0]="Angle_TypeOfAngle_Interior",e[e.Angle_TypeOfAngle_Exterior=1]="Angle_TypeOfAngle_Exterior"}(t.MxTypeOfAngle||(t.MxTypeOfAngle={})),function(e){e[e.Visibility_TOAAV_Both=0]="Visibility_TOAAV_Both",e[e.Visibility_TOAAV_First=1]="Visibility_TOAAV_First",e[e.Visibility_TOAAV_Second=2]="Visibility_TOAAV_Second",e[e.Visibility_TOAAV_None=3]="Visibility_TOAAV_None"}(t.MxTypeOfAngleArrowVisibility||(t.MxTypeOfAngleArrowVisibility={})),function(e){e[e.Line_TOL_EMPTY=-1]="Line_TOL_EMPTY",e[e.Line_TOL_SOLID=0]="Line_TOL_SOLID",e[e.Line_TOL_DASH=1]="Line_TOL_DASH",e[e.Line_TOL_DOT=2]="Line_TOL_DOT",e[e.Line_TOL_DOTDASH=3]="Line_TOL_DOTDASH",e[e.Line_TOL_USERDEFINED=4]="Line_TOL_USERDEFINED"}(t.MxTypeOfLine||(t.MxTypeOfLine={})),function(e){e[e.TextPath_TP_UP=0]="TextPath_TP_UP",e[e.TextPath_TP_DOWN=1]="TextPath_TP_DOWN",e[e.TextPath_TP_LEFT=2]="TextPath_TP_LEFT",e[e.TextPath_TP_RIGHT=3]="TextPath_TP_RIGHT"}(t.MxTextPath||(t.MxTextPath={})),function(e){e[e.DimensionArrowOrientation_DAO_Internal=0]="DimensionArrowOrientation_DAO_Internal",e[e.DimensionArrowOrientation_DAO_External=1]="DimensionArrowOrientation_DAO_External",e[e.DimensionArrowOrientation_DAO_Fit=2]="DimensionArrowOrientation_DAO_Fit"}(t.MxDimensionArrowOrientation||(t.MxDimensionArrowOrientation={})),function(e){e[e.DimensionTextVerticalPosition_DTVP_Above=0]="DimensionTextVerticalPosition_DTVP_Above",e[e.DimensionTextVerticalPosition_DTVP_Below=1]="DimensionTextVerticalPosition_DTVP_Below",e[e.DimensionTextVerticalPosition_DTVP_Center=2]="DimensionTextVerticalPosition_DTVP_Center"}(t.MxDimensionTextVerticalPosition||(t.MxDimensionTextVerticalPosition={})),function(e){e[e.DimensionTextHorizontalPosition_DTHP_Left=0]="DimensionTextHorizontalPosition_DTHP_Left",e[e.DimensionTextHorizontalPosition_DTHP_Right=1]="DimensionTextHorizontalPosition_DTHP_Right",e[e.DimensionTextHorizontalPosition_DTHP_Center=2]="DimensionTextHorizontalPosition_DTHP_Center",e[e.DimensionTextHorizontalPosition_DTHP_Fit=3]="DimensionTextHorizontalPosition_DTHP_Fit"}(t.MxDimensionTextHorizontalPosition||(t.MxDimensionTextHorizontalPosition={})),function(e){e[e.KindOfDimension_KOD_NONE=0]="KindOfDimension_KOD_NONE",e[e.KindOfDimension_KOD_LENGTH=1]="KindOfDimension_KOD_LENGTH",e[e.KindOfDimension_KOD_PLANEANGLE=2]="KindOfDimension_KOD_PLANEANGLE",e[e.KindOfDimension_KOD_SOLIDANGLE=3]="KindOfDimension_KOD_SOLIDANGLE",e[e.KindOfDimension_KOD_AREA=4]="KindOfDimension_KOD_AREA",e[e.KindOfDimension_KOD_VOLUME=5]="KindOfDimension_KOD_VOLUME",e[e.KindOfDimension_KOD_MASS=6]="KindOfDimension_KOD_MASS",e[e.KindOfDimension_KOD_TIME=7]="KindOfDimension_KOD_TIME",e[e.KindOfDimension_KOD_RADIUS=8]="KindOfDimension_KOD_RADIUS",e[e.KindOfDimension_KOD_DIAMETER=9]="KindOfDimension_KOD_DIAMETER",e[e.KindOfDimension_KOD_CHAMF2D=10]="KindOfDimension_KOD_CHAMF2D",e[e.KindOfDimension_KOD_CHAMF3D=11]="KindOfDimension_KOD_CHAMF3D",e[e.KindOfDimension_KOD_OFFSET=12]="KindOfDimension_KOD_OFFSET",e[e.KindOfDimension_KOD_ELLIPSERADIUS=13]="KindOfDimension_KOD_ELLIPSERADIUS"}(t.MxKindOfDimension||(t.MxKindOfDimension={})),function(e){e[e.DocColor_ColorGen=0]="DocColor_ColorGen",e[e.DocColor_ColorSurf=1]="DocColor_ColorSurf",e[e.DocColor_ColorCurv=2]="DocColor_ColorCurv"}(t.MxDocColorType||(t.MxDocColorType={})),function(e){e[e.KindOfInteractive_None=0]="KindOfInteractive_None",e[e.KindOfInteractive_Datum=1]="KindOfInteractive_Datum",e[e.KindOfInteractive_Shape=2]="KindOfInteractive_Shape",e[e.KindOfInteractive_Object=3]="KindOfInteractive_Object",e[e.KindOfInteractive_Relation=4]="KindOfInteractive_Relation",e[e.KindOfInteractive_Dimension=5]="KindOfInteractive_Dimension",e[e.KindOfInteractive_LightSource=6]="KindOfInteractive_LightSource",e[e.KOI_None=0]="KOI_None",e[e.KOI_Datum=1]="KOI_Datum",e[e.KOI_Shape=2]="KOI_Shape",e[e.KOI_Object=3]="KOI_Object",e[e.KOI_Relation=4]="KOI_Relation",e[e.KOI_Dimension=5]="KOI_Dimension"}(t.MxKindOfInteractive||(t.MxKindOfInteractive={})),function(e){e[e.TOH_NotSet=0]="TOH_NotSet",e[e.TOH_PolyAlgo=1]="TOH_PolyAlgo",e[e.TOH_Algo=2]="TOH_Algo"}(t.MxPrs3dTypeOfHLR||(t.MxPrs3dTypeOfHLR={})),function(e){e[e.DisplayStatus_Displayed=0]="DisplayStatus_Displayed",e[e.DisplayStatus_Erased=1]="DisplayStatus_Erased",e[e.DisplayStatus_None=2]="DisplayStatus_None",e[e.DS_Displayed=0]="DS_Displayed",e[e.DS_Erased=1]="DS_Erased",e[e.DS_None=2]="DS_None"}(t.MxDisplayStatus||(t.MxDisplayStatus={})),function(e){e[e.DisplayMode_Wireframe=0]="DisplayMode_Wireframe",e[e.DisplayMode_HiddenLineRemoval=1]="DisplayMode_HiddenLineRemoval",e[e.DisplayMode_Shaded=2]="DisplayMode_Shaded",e[e.DisplayMode_ShadedWithFaceBoundary=3]="DisplayMode_ShadedWithFaceBoundary",e[e.DisplayMode_Transparency=4]="DisplayMode_Transparency"}(t.MxGlobalDisplayMode||(t.MxGlobalDisplayMode={})),function(e){e[e.GradientFillMethod_None=0]="GradientFillMethod_None",e[e.GradientFillMethod_Horizontal=1]="GradientFillMethod_Horizontal",e[e.GradientFillMethod_Vertical=2]="GradientFillMethod_Vertical",e[e.GradientFillMethod_Diagonal1=3]="GradientFillMethod_Diagonal1",e[e.GradientFillMethod_Diagonal2=4]="GradientFillMethod_Diagonal2",e[e.GradientFillMethod_Corner1=5]="GradientFillMethod_Corner1",e[e.GradientFillMethod_Corner2=6]="GradientFillMethod_Corner2",e[e.GradientFillMethod_Corner3=7]="GradientFillMethod_Corner3",e[e.GradientFillMethod_Corner4=8]="GradientFillMethod_Corner4",e[e.GradientFillMethod_Elliptical=9]="GradientFillMethod_Elliptical",e[e.GFM_NONE=0]="GFM_NONE",e[e.GFM_HOR=1]="GFM_HOR",e[e.GFM_VER=2]="GFM_VER",e[e.GFM_DIAG1=3]="GFM_DIAG1",e[e.GFM_DIAG2=4]="GFM_DIAG2",e[e.GFM_CORNER1=5]="GFM_CORNER1",e[e.GFM_CORNER2=6]="GFM_CORNER2",e[e.GFM_CORNER3=7]="GFM_CORNER3",e[e.GFM_CORNER4=8]="GFM_CORNER4"}(t.MxGradientFillMethod||(t.MxGradientFillMethod={})),function(e){e[e.Format_Unknown=0]="Format_Unknown",e[e.Format_Image=1]="Format_Image",e[e.Format_3DS=2]="Format_3DS",e[e.Format_3MF=3]="Format_3MF",e[e.Format_AMF=4]="Format_AMF",e[e.Format_COLLADA=5]="Format_COLLADA",e[e.Format_DXF=6]="Format_DXF",e[e.Format_FBX=7]="Format_FBX",e[e.Format_GLTF=8]="Format_GLTF",e[e.Format_IGES=9]="Format_IGES",e[e.Format_OBJ=10]="Format_OBJ",e[e.Format_OCCBREP=11]="Format_OCCBREP",e[e.Format_OFF=12]="Format_OFF",e[e.Format_PLY=13]="Format_PLY",e[e.Format_STEP=14]="Format_STEP",e[e.Format_STL=15]="Format_STL",e[e.Format_VRML=16]="Format_VRML",e[e.Format_X3D=17]="Format_X3D",e[e.Format_Blender=18]="Format_Blender"}(t.MxFormat||(t.MxFormat={})),function(e){e[e.Quant_Length=0]="Quant_Length",e[e.Quant_Area=1]="Quant_Area",e[e.Quant_Volume=2]="Quant_Volume"}(t.MxQuantAspect||(t.MxQuantAspect={})),function(e){e[e.Orientation_FORWARD=0]="Orientation_FORWARD",e[e.Orientation_REVERSED=1]="Orientation_REVERSED",e[e.Orientation_INTERNAL=2]="Orientation_INTERNAL",e[e.Orientation_EXTERNAL=3]="Orientation_EXTERNAL"}(t.MxOrientation||(t.MxOrientation={}))})(MdGe||(MdGe={}));var PubSub=function(){function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"events",void 0),this.events={}}return _createClass$1(t,[{key:"on",value:function(l,n){var u=this;u.events.hasOwnProperty(l)||(u.events[l]=[]),u.events[l].push(n)}},{key:"emit",value:function(l){for(var n=arguments.length,u=new Array(n>1?n-1:0),c=1;c<n;c++)u[c-1]=arguments[c];var y=this;y.events.hasOwnProperty(l)&&y.events[l].map(function(b){return b.apply(void 0,u)})}},{key:"off",value:function(l,n){if(this.events[l])if(typeof n>"u")this.events[l]=[];else{var u=this.events[l].indexOf(n);this.events[l].splice(u,1)}}}]),t}(),loadWams=function(){var t=_asyncToGenerator(regenerator.mark(function e(l,n,u){var c,y;return regenerator.wrap(function(m){for(;;)switch(m.prev=m.next){case 0:return c=u.locateFile,y=c(l+".js"),m.next=4,loadScript(y);case 4:return m.next=6,globalThis[n](u);case 6:return m.abrupt("return",m.sent);case 7:case"end":return m.stop()}},e)}));return function(l,n,u){return t.apply(this,arguments)}}();function createResizeObserver$1(t){if(typeof ResizeObserver=="function"){var e=new ResizeObserver(t);return e}return null}function addResizeListener$1(t,e){var l=function(){return requestAnimationFrame(e)},n=createResizeObserver$1(l);if(n){n.observe(t);return}if(MutationObserver){var u=new MutationObserver(l);u.observe(t,{attributes:!0});return}}function throttle$1(t,e){var l=null;return function(){for(var n=this,u=arguments.length,c=new Array(u),y=0;y<u;y++)c[y]=arguments[y];l||(l=setTimeout(function(){t.apply(n,c),l=null},e))}}function _createSuper(t){var e=_isNativeReflectConstruct();return function(){var n=_getPrototypeOf$1(t),u;if(e){var c=_getPrototypeOf$1(this).constructor;u=Reflect.construct(n,arguments,c)}else u=n.apply(this,arguments);return _possibleConstructorReturn$1(this,u)}}function _isNativeReflectConstruct(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var MxApp3DType=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(){var n;_classCallCheck$1(this,l);for(var u=arguments.length,c=new Array(u),y=0;y<u;y++)c[y]=arguments[y];return n=e.call.apply(e,[this].concat(c)),_defineProperty$1(_assertThisInitialized$1(n),"imp",void 0),_defineProperty$1(_assertThisInitialized$1(n),"cpp_app",void 0),_defineProperty$1(_assertThisInitialized$1(n),"tool",void 0),_defineProperty$1(_assertThisInitialized$1(n),"globalMethods",void 0),n}return _createClass$1(l,[{key:"init",value:function(u){this.imp=u,this.cpp_app=new u.Mx3dApplication,this.tool=new u.MdGeTopo,this.globalMethods=new u.Mx3dClassMethods}},{key:"createView",value:function(u){return new Mx3dView(this.cpp_app.createView(u))}},{key:"getCurrentActiveView",value:function(){return new Mx3dView(this.cpp_app.getCurrentActiveView())}}]),l}(PubSub),MxApp3D=new MxApp3DType,MxCAD3DObject=function(){function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"event",{}),_defineProperty$1(this,"imp",void 0),_defineProperty$1(this,"canvas",null),_defineProperty$1(this,"ctx",null),_defineProperty$1(this,"updateCanvasSizeFun",null),this.updateCanvasSizeFun=null}return _createClass$1(t,[{key:"getDocument",value:function(){return new Mx3dDbDocument(this.imp.getDoc(),"from view")}},{key:"removeAll",value:function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.imp.removeAll(l)}},{key:"removeSelected",value:function(){this.imp.removeSelected()}},{key:"update",value:function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;this.imp.update(l,n)}},{key:"setProjectionType",value:function(l){this.imp.setProjectionType(l)}},{key:"showCenterTrihedron",value:function(l){this.imp.showCenterTrihedron(l)}},{key:"fitAllObjects",value:function(l){this.imp.fitAllObjects(l)}},{key:"enableXClipPlane",value:function(l){this.imp.enableXClipPlane(l)}},{key:"setXClipPlaneXPosition",value:function(l){this.imp.setXClipPlaneXPosition(l)}},{key:"setXClipPlaneReverse",value:function(){this.imp.setXClipPlaneReverse()}},{key:"enableYClipPlane",value:function(l){this.imp.enableYClipPlane(l)}},{key:"setYClipPlaneYPosition",value:function(l){this.imp.setYClipPlaneYPosition(l)}},{key:"setYClipPlaneReverse",value:function(){this.imp.setYClipPlaneReverse()}},{key:"enableZClipPlane",value:function(l){this.imp.enableZClipPlane(l)}},{key:"setZClipPlaneZPosition",value:function(l){this.imp.setZClipPlaneZPosition(l)}},{key:"setZClipPlaneReverse",value:function(){this.imp.setZClipPlaneReverse()}},{key:"enableCustomClipPlane",value:function(l){this.imp.enableCustomClipPlane(l)}},{key:"setCustomClipPlanePosition",value:function(l){this.imp.setCustomClipPlanePosition(l)}},{key:"setCustomClipPlaneReverse",value:function(){this.imp.setCustomClipPlaneReverse()}},{key:"setCustomClipPlaneDirection",value:function(l,n,u){this.imp.setCustomClipPlaneDirection(l,n,u)}},{key:"displaySymbolText",value:function(l){this.imp.displaySymbolText(l.getImp())}},{key:"displayDimension",value:function(l){this.imp.displayDimension(l.getImp())}},{key:"addModelTexture",value:function(l){this.imp.addModelTexture(l)}},{key:"removeModelTexture",value:function(){this.imp.removeModelTexture()}},{key:"setGradientBgColor",value:function(l,n,u){this.imp.setGradientBgColor(l.getImp(),n.getImp(),u)}},{key:"setProj",value:function(l,n){this.imp.setProj(l,n)}},{key:"setSelectedColor",value:function(l){this.imp.setSelectedColor(l.getImp())}},{key:"setSelectedMaterial",value:function(l){this.imp.setSelectedMaterial(l.getImp())}},{key:"setDisplayMode",value:function(l){this.imp.setDisplayMode(l)}},{key:"enableDirLightSrc",value:function(l){this.imp.enableDirLightSrc(l)}},{key:"setCubemapBackground",value:function(l,n,u,c,y,b){this.imp.setCubemapBackground(l,n,u,c,y,b)}},{key:"setManipulatorEnabled",value:function(l){this.imp.setManipulatorEnabled(l)}},{key:"getImp",value:function(){return this.imp}},{key:"getCtx",value:function(){return this.ctx}},{key:"updateCanvasSize",value:function(){this.updateCanvasSizeFun&&this.updateCanvasSizeFun()}},{key:"init",value:function(l){this.imp=l}},{key:"on",value:function(l,n){if(this.event[l])if(this.event[l]instanceof Array)this.event[l].includes(n)||this.event[l].push(n);else{var u=this.event[l];if(u==n)return;this.event[l]=[],this.event[l].push(u),this.event[l].push(n)}else this.event[l]=n}},{key:"off",value:function(l,n){if(this.event[l])if(!n)this.event[l]=[];else if(this.event[l]instanceof Array){var u=this.event[l].indexOf(n);if(u<0)return;this.event[l].splice(u,1)}else this.event[l]===n&&(this.event[l]=[])}},{key:"callEvent",value:function(l,n){try{var u=this.event[l];if(!u)return!1;if(u instanceof Array){var c=!1;return u.forEach(function(y){c=y(n)}),c}else return u(n)}catch(y){throw console.log(y),y}}},{key:"create",value:function(l){var n=this,u=function(){if(n.canvas){var ve=n.canvas.parentElement?n.canvas.parentElement.clientWidth:window.innerWidth,ne=n.canvas.parentElement?n.canvas.parentElement.clientHeight:window.innerHeight,Ue=Math.min(ve,window.screen.availWidth),De=Math.min(ne,window.screen.availHeight);Ue=Math.max(m,Ue),De=Math.max(N,De),n.canvas.style.width=Ue+1+"px",n.canvas.style.height=De+"px";var Ve=window.devicePixelRatio||1;n.canvas.width=Ue*Ve,n.canvas.height=De*Ve,window.dispatchEvent(new Event("resize"))}},c=throttle$1(u,50),y=l.canvas,b=l.minWidth,m=b===void 0?300:b,O=l.minHeight,N=O===void 0?300:O,L=l.updateCanvasSize,G=L===void 0?c:L,q=!1,J=function(){if(!q){q=!0;var ve=typeof y=="string",ne=ve?document.querySelectorAll(y)[0]:y;if(!ne){ne=document.createElement("canvas"),ve&&(y.startsWith(".")&&ne.classList.add((y+"").replace(".","")),y.startsWith("#")&&(ne.id=(y+"").replace("#","")));var Ue=document.createElement("div");Ue.style.width="100%",Ue.style.height="".concat(Math.max(document.body.clientHeight,N),"px"),Ue.appendChild(ne),document.body.appendChild(Ue)}var De=ne.getContext("webgl2",{alpha:!1,depth:!0,antialias:!1,preserveDrawingBuffer:!0});if(De==null&&(De=ne.getContext("webgl",{alpha:!1,depth:!0,antialias:!1,preserveDrawingBuffer:!0})),n.canvas=ne,n.ctx=De,n.canvas instanceof HTMLCanvasElement){var Ve=n.canvas.parentElement||document.body;addResizeListener$1(Ve,G)}else console.error("createMxDraw3d canvas 参数不正确 无法获取到canvas元素");u();var rt=function(){n.updateCanvasSizeFun=G,n.init(MxApp3D.cpp_app.createView(y)),n.callEvent("init")};l.locateFile||(l.locateFile=get3DFileURL),l.canvas=ne,l.on=MxApp3D.on.bind(MxApp3D),l.emit=MxApp3D.emit.bind(MxApp3D),l.off=MxApp3D.off.bind(MxApp3D),loadWams("mxdraw3d_min","mxdraw3d",Object.assign({},l)).then(function(Ae){MxApp3D.init(Ae),rt()})}};window.onload=function(){J()},document.readyState==="complete"?J():document.addEventListener("DOMContentLoaded",J)}}]),t}(),_mxFinalizationRegistry=new FinalizationRegistry(function(t){MxApp3D.tool.DestroyObject(t)}),_mxFinalizationRegistry_token={};function isUniPoint(t){return t instanceof Mx3dGePoint||t instanceof Array&&typeof t[0]=="number"}function isUniDir(t){return t instanceof Mx3dGeDir||t instanceof Array&&typeof t[0]=="number"}function isUniVec(t){return t instanceof Mx3dGeVec||t instanceof Array&&typeof t[0]=="number"}function uniToPoint(t){return t instanceof Mx3dGePoint?t:new Mx3dGePoint(t[0],t[1],t[2])}function uniToDir(t){return t instanceof Mx3dGeDir?t:new Mx3dGeDir(t[0],t[1],t[2])}function uniToVec(t){return t instanceof Mx3dGeVec?t:new Mx3dGeVec(t[0],t[1],t[2])}function arrShapeToShapeSequence(t){var e=new Mx3dShapeObjectSequence;return t.forEach(function(l){return e.Append(l)}),e}var Mx3dApplication=function(){function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",void 0),this.imp=MxApp3D.cpp_app}return _createClass$1(t,[{key:"createView",value:function(l){return new Mx3dView(this.imp.createView(l))}},{key:"getCurrentActiveView",value:function(){return new Mx3dView(this.imp.getCurrentActiveView())}}]),t}(),Mx3dBaseObject=function(){function t(e){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",0),this.imp=e,this.imp&&_mxFinalizationRegistry.register(this,e,_mxFinalizationRegistry_token)}return _createClass$1(t,[{key:"getImp",value:function(){return this.imp}},{key:"initTempObject",value:function(l){this.imp=l}}]),t}(),Mx3dDimObject=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l)}(Mx3dBaseObject),Mx3dSymbolObject=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l)}(Mx3dBaseObject),Mx3dAlgoObject=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l)}(Mx3dBaseObject),Mx3dAspectObject=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l)}(Mx3dBaseObject),Mx3dGeObject=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l)}(Mx3dBaseObject),Mx3dGeCurve=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l)}(Mx3dGeObject),Mx3dGeConic=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l)}(Mx3dGeCurve),Mx3dGePoint=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),arguments.length===0?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGePoint)):n instanceof Array&&typeof n[0]=="number"?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGePoint(n[0],n[1],n[2]))):typeof n=="number"&&typeof u=="number"&&typeof c=="number"?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGePoint(n,u,c))):n instanceof Object&&arguments.length===1&&(y=e.call(this,n)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"X",value:function(){return this.imp.X()}},{key:"Y",value:function(){return this.imp.Y()}},{key:"Z",value:function(){return this.imp.Z()}},{key:"setX",value:function(u){this.imp.setX(u)}},{key:"setY",value:function(u){this.imp.setY(u)}},{key:"setZ",value:function(u){this.imp.setZ(u)}},{key:"setXYZ",value:function(u,c,y){this.imp.setX(u),this.imp.setY(c),this.imp.setZ(y)}},{key:"Vertex",value:function(){return new Mx3dShapeVertex(this.imp.Vertex())}}]),l}(Mx3dGeObject),Mx3dGeTrsf=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dGeTrsf)),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"SetMirrorByPoint",value:function(u){u=uniToPoint(u),this.imp.SetMirrorByPoint(u.getImp())}},{key:"SetMirrorByAxis",value:function(u){this.imp.SetMirrorByAxis(u.getImp())}},{key:"SetMirrorByCSYSR",value:function(u){this.imp.SetMirrorByCSYSR(u.getImp())}},{key:"SetRotation",value:function(u,c){this.imp.SetRotation(u.getImp(),c)}},{key:"SetScale",value:function(u,c){u=uniToPoint(u),this.imp.SetScale(u.getImp(),c)}},{key:"SetTranslationByVec",value:function(u){u=uniToVec(u),this.imp.SetTranslationByVec(u.getImp())}},{key:"SetTranslationBy2Points",value:function(u,c){u=uniToPoint(u),c=uniToPoint(c),this.imp.SetTranslationBy2Points(u.getImp(),c.getImp())}},{key:"SetTranslationPart",value:function(u){this.imp.SetTranslationPart(u.getImp())}},{key:"SetScaleFactor",value:function(u){this.imp.SetScaleFactor(u)}},{key:"SetValues",value:function(u,c,y,b,m,O,N,L,G,q,J,fe){this.imp.SetValues(u,c,y,b,m,O,N,L,G,q,J,fe)}},{key:"IsNegative",value:function(){return this.imp.IsNegative()}},{key:"ScaleFactor",value:function(){return this.imp.ScaleFactor()}},{key:"Value",value:function(u,c){return this.imp.Value(u,c)}},{key:"Invert",value:function(){this.imp.Invert()}},{key:"Inverted",value:function(){return new l(this.imp.Inverted())}},{key:"Multiplied",value:function(u){return new l(this.imp.Multiplied(u.getImp()))}},{key:"Multiply",value:function(u){this.imp.Multiply(u.getImp())}},{key:"PreMultiply",value:function(u){this.imp.PreMultiply(u.getImp())}},{key:"Power",value:function(u){this.imp.Power(u)}},{key:"Powered",value:function(u){return new l(this.imp.Powered(u))}},{key:"Transforms",value:function(u,c,y){this.imp.Transforms(u,c,y)}}]),l}(Mx3dGeObject),Mx3dGeAxis=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),arguments.length===0?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeAxis)):isUniPoint(n)&&isUniDir(u)?(c=e.call(this),n=uniToPoint(n),u=uniToDir(u),c.initTempObject(new MxApp3D.imp.Mx3dGeAxis(n.getImp(),u.getImp()))):n instanceof Object&&arguments.length===1&&(c=e.call(this,n)),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"Direction",value:function(){return new Mx3dGeDir(this.imp.Direction())}},{key:"Location",value:function(){return new Mx3dGePoint(this.imp.Location())}},{key:"SetDirection",value:function(u){this.imp.SetDirection(u.getImp())}},{key:"SetLocation",value:function(u){u=uniToPoint(u),this.imp.SetLocation(u.getImp())}}]),l}(Mx3dGeObject),Mx3dGeDir=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),arguments.length===0?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeDir)):typeof n=="number"&&typeof u=="number"&&typeof c=="number"?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeDir(n,u,c))):n instanceof Object&&arguments.length===1&&(y=e.call(this,n)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"X",value:function(){return this.imp.X()}},{key:"Y",value:function(){return this.imp.Y()}},{key:"Z",value:function(){return this.imp.Z()}},{key:"SetX",value:function(u){this.imp.SetX(u)}},{key:"SetY",value:function(u){this.imp.SetY(u)}},{key:"SetZ",value:function(u){this.imp.SetZ(u)}},{key:"SetXYZ",value:function(u,c,y){this.imp.SetXYZ(u,c,y)}},{key:"IsEqual",value:function(u,c){return this.imp.IsEqual(u.getImp(),c)}},{key:"IsNormal",value:function(u,c){return this.imp.IsNormal(u.getImp(),c)}},{key:"IsOpposite",value:function(u,c){return this.imp.IsOpposite(u.getImp(),c)}},{key:"IsParallel",value:function(u,c){return this.imp.IsParallel(u.getImp(),c)}},{key:"Angle",value:function(u){return this.imp.Angle(u.getImp())}},{key:"AngleWithRef",value:function(u,c){return this.imp.AngleWithRef(u.getImp(),c.getImp())}},{key:"Cross",value:function(u){this.imp.Cross(u.getImp())}},{key:"Crossed",value:function(u){return new l(this.imp.Crossed(u.getImp()))}},{key:"CrossCross",value:function(u,c){this.imp.CrossCross(u.getImp(),c.getImp())}},{key:"CrossCrossed",value:function(u,c){return new l(this.imp.CrossCrossed(u.getImp(),c.getImp()))}},{key:"Dot",value:function(u){return this.imp.Dot(u.getImp())}},{key:"DotCross",value:function(u,c){return this.imp.DotCross(u.getImp(),c.getImp())}},{key:"Reverse",value:function(){this.imp.Reverse()}},{key:"Reversed",value:function(){return new l(this.imp.Reversed())}},{key:"MirrorByVec",value:function(u){this.imp.MirrorByVec(u.getImp())}},{key:"MirroredByVec",value:function(u){return new l(this.imp.MirroredByVec(u.getImp()))}},{key:"MirrorByAxis",value:function(u){this.imp.MirrorByAxis(u.getImp())}},{key:"MirroredByAxis",value:function(u){return new l(this.imp.MirroredByAxis(u.getImp()))}},{key:"MirrorByCSYSR",value:function(u){this.imp.MirrorByCSYSR(u.getImp())}},{key:"MirroredByCSYSR",value:function(u){return new l(this.imp.MirroredByCSYSR(u.getImp()))}},{key:"Rotate",value:function(u,c){this.imp.Rotate(u.getImp(),c)}},{key:"Rotated",value:function(u,c){return new l(this.imp.Rotated(u.getImp(),c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Transformed",value:function(u){return new l(this.imp.Transformed(u.getImp()))}}]),l}(Mx3dGeObject),Mx3dGeEllipse=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),!n&&!u&&!c?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeEllipse)):n instanceof Mx3dGeCSYSR&&typeof u=="number"&&typeof c=="number"?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeEllipse(n.getImp(),u,c))):n instanceof Object&&(y=e.call(this,n)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"SetAxis",value:function(u){this.imp.SetAxis(u.getImp())}},{key:"SetLocation",value:function(u){this.imp.SetLocation(u.getImp())}},{key:"SetMajorRadius",value:function(u){this.imp.SetMajorRadius(u)}},{key:"SetMinorRadius",value:function(u){this.imp.SetMinorRadius(u)}},{key:"SetPosition",value:function(u){this.imp.SetPosition(u.getImp())}},{key:"Area",value:function(){return this.imp.Area()}},{key:"Axis",value:function(){return new Mx3dGeAxis(this.imp.Axis())}},{key:"Directrix1",value:function(){return new Mx3dGeAxis(this.imp.Directrix1())}},{key:"Directrix2",value:function(){return new Mx3dGeAxis(this.imp.Directrix2())}},{key:"Eccentricity",value:function(){return this.imp.Eccentricity()}},{key:"Focal",value:function(){return this.imp.Focal()}},{key:"Focus1",value:function(){return new Mx3dGePoint(this.imp.Focus1())}},{key:"Focus2",value:function(){return new Mx3dGePoint(this.imp.Focus2())}},{key:"Location",value:function(){return new Mx3dGePoint(this.imp.Location())}},{key:"MajorRadius",value:function(){return this.imp.MajorRadius()}},{key:"MinorRadius",value:function(){return this.imp.MinorRadius()}},{key:"Parameter",value:function(){return this.imp.Parameter()}},{key:"Position",value:function(){return new Mx3dGeCSYSR(this.imp.Position())}},{key:"XAxis",value:function(){return new Mx3dGeAxis(this.imp.XAxis())}},{key:"YAxis",value:function(){return new Mx3dGeAxis(this.imp.YAxis())}},{key:"MirrorByPoint",value:function(u){this.imp.MirrorByPoint(u.getImp())}},{key:"MirroredByPoint",value:function(u){return new l(this.imp.MirroredByPoint(u.getImp()))}},{key:"MirrorByAxis",value:function(u){this.imp.MirrorByAxis(u.getImp())}},{key:"MirroredByAxis",value:function(u){return new l(this.imp.MirroredByAxis(u.getImp()))}},{key:"MirrorByCSYSR",value:function(u){this.imp.MirrorByCSYSR(u.getImp())}},{key:"MirroredByCSYSR",value:function(u){return new l(this.imp.MirroredByCSYSR(u.getImp()))}},{key:"Rotate",value:function(u,c){this.imp.Rotate(u.getImp(),c)}},{key:"Rotated",value:function(u,c){return new l(this.imp.Rotated(u.getImp(),c))}},{key:"Scale",value:function(u,c){this.imp.Scale(u.getImp(),c)}},{key:"Scaled",value:function(u,c){return new l(this.imp.Scaled(u.getImp(),c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Transformed",value:function(u){return new l(this.imp.Transformed(u.getImp()))}},{key:"TranslateByVec",value:function(u){this.imp.TranslateByVec(u.getImp())}},{key:"TranslatedByVec",value:function(u){return new l(this.imp.TranslatedByVec(u.getImp()))}},{key:"TranslateBy2Points",value:function(u,c){this.imp.TranslateBy2Points(u.getImp(),c.getImp())}},{key:"TranslatedBy2Points",value:function(u,c){return new l(this.imp.TranslatedBy2Points(u.getImp(),c.getImp()))}}]),l}(Mx3dGeObject),Mx3dGeHyperbola=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),!n&&!u&&!c?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeHyperbola)):n instanceof Mx3dGeCSYSR&&typeof u=="number"&&typeof c=="number"?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeHyperbola(n.getImp(),u,c))):n instanceof Object&&(y=e.call(this,n)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"SetAxis",value:function(u){this.imp.SetAxis(u.getImp())}},{key:"SetLocation",value:function(u){this.imp.SetLocation(u.getImp())}},{key:"SetMajorRadius",value:function(u){this.imp.SetMajorRadius(u)}},{key:"SetMinorRadius",value:function(u){this.imp.SetMinorRadius(u)}},{key:"SetPosition",value:function(u){this.imp.SetPosition(u.getImp())}},{key:"Asymptote1",value:function(){return new Mx3dGeAxis(this.imp.Asymptote1())}},{key:"Asymptote2",value:function(){return new Mx3dGeAxis(this.imp.Asymptote2())}},{key:"Axis",value:function(){return new Mx3dGeAxis(this.imp.Axis())}},{key:"ConjugateBranch1",value:function(){return new l(this.imp.ConjugateBranch1())}},{key:"ConjugateBranch2",value:function(){return new l(this.imp.ConjugateBranch2())}},{key:"Directrix1",value:function(){return new Mx3dGeAxis(this.imp.Directrix1())}},{key:"Directrix2",value:function(){return new Mx3dGeAxis(this.imp.Directrix2())}},{key:"Eccentricity",value:function(){return this.imp.Eccentricity()}},{key:"Focal",value:function(){return this.imp.Focal()}},{key:"Focus1",value:function(){return new Mx3dGePoint(this.imp.Focus1())}},{key:"Focus2",value:function(){return new Mx3dGePoint(this.imp.Focus2())}},{key:"Location",value:function(){return new Mx3dGePoint(this.imp.Location())}},{key:"MajorRadius",value:function(){return this.imp.MajorRadius()}},{key:"MinorRadius",value:function(){return this.imp.MinorRadius()}},{key:"OtherBranch",value:function(){return new l(this.imp.OtherBranch())}},{key:"Parameter",value:function(){return this.imp.Parameter()}},{key:"Position",value:function(){return new Mx3dGeCSYSR(this.imp.Position())}},{key:"XAxis",value:function(){return new Mx3dGeAxis(this.imp.XAxis())}},{key:"YAxis",value:function(){return new Mx3dGeAxis(this.imp.YAxis())}},{key:"MirrorByPoint",value:function(u){this.imp.MirrorByPoint(u.getImp())}},{key:"MirroredByPoint",value:function(u){return new l(this.imp.MirroredByPoint(u.getImp()))}},{key:"MirrorByAxis",value:function(u){this.imp.MirrorByAxis(u.getImp())}},{key:"MirroredByAxis",value:function(u){return new l(this.imp.MirroredByAxis(u.getImp()))}},{key:"MirrorByCSYSR",value:function(u){this.imp.MirrorByCSYSR(u.getImp())}},{key:"MirroredByCSYSR",value:function(u){return new l(this.imp.MirroredByCSYSR(u.getImp()))}},{key:"Rotate",value:function(u,c){this.imp.Rotate(u.getImp(),c)}},{key:"Rotated",value:function(u,c){return new l(this.imp.Rotated(u.getImp(),c))}},{key:"Scale",value:function(u,c){this.imp.Scale(u.getImp(),c)}},{key:"Scaled",value:function(u,c){return new l(this.imp.Scaled(u.getImp(),c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Transformed",value:function(u){return new l(this.imp.Transformed(u.getImp()))}},{key:"TranslateByVec",value:function(u){this.imp.TranslateByVec(u.getImp())}},{key:"TranslatedByVec",value:function(u){return new l(this.imp.TranslatedByVec(u.getImp()))}},{key:"TranslateBy2Points",value:function(u,c){this.imp.TranslateBy2Points(u.getImp(),c.getImp())}},{key:"TranslatedBy2Points",value:function(u,c){return new l(this.imp.TranslatedBy2Points(u.getImp(),c.getImp()))}}]),l}(Mx3dGeObject),Mx3dGeVec=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),arguments.length==0?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeVec)):n instanceof Mx3dGePoint&&u instanceof Mx3dGePoint&&arguments.length==2?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeVec(n.getImp(),u.getImp()))):typeof n=="number"&&typeof u=="number"&&arguments.length==3?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeVec(n,u,c))):n instanceof Object&&arguments.length==1&&(y=e.call(this,n)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"X",value:function(){return this.imp.X()}},{key:"Y",value:function(){return this.imp.Y()}},{key:"Z",value:function(){return this.imp.Z()}},{key:"SetX",value:function(u){this.imp.SetX(u)}},{key:"SetY",value:function(u){this.imp.SetY(u)}},{key:"SetZ",value:function(u){this.imp.SetZ(u)}},{key:"SetXYZ",value:function(u,c,y){this.imp.SetXYZ(u,c,y)}},{key:"IsEqual",value:function(u,c,y){return this.imp.IsEqual(u.getImp(),c,y)}},{key:"IsNormal",value:function(u,c){return this.imp.IsNormal(u.getImp(),c)}},{key:"IsOpposite",value:function(u,c){return this.imp.IsOpposite(u.getImp(),c)}},{key:"IsParallel",value:function(u,c){return this.imp.IsParallel(u.getImp(),c)}},{key:"Angle",value:function(u){return this.imp.Angle(u.getImp())}},{key:"AngleWithRef",value:function(u,c){return this.imp.AngleWithRef(u.getImp(),c.getImp())}},{key:"Magnitude",value:function(){return this.imp.Magnitude()}},{key:"SquareMagnitude",value:function(){return this.imp.SquareMagnitude()}},{key:"Add",value:function(u){this.imp.Add(u.getImp())}},{key:"Added",value:function(u){return new l(this.imp.Added(u.getImp()))}},{key:"Subtract",value:function(u){this.imp.Subtract(u.getImp())}},{key:"Subtracted",value:function(u){return new l(this.imp.Subtracted(u.getImp()))}},{key:"Multiply",value:function(u){this.imp.Multiply(u)}},{key:"Multiplied",value:function(u){return new l(this.imp.Multiplied(u))}},{key:"Divide",value:function(u){this.imp.Divide(u)}},{key:"Divided",value:function(u){return new l(this.imp.Divided(u))}},{key:"Cross",value:function(u){this.imp.Cross(u.getImp())}},{key:"Crossed",value:function(u){return new l(this.getImp().Crossed(u.getImp()))}},{key:"CrossMagnitude",value:function(u){return this.imp.CrossMagnitude(u.getImp())}},{key:"CrossSquareMagnitude",value:function(u){return this.imp.CrossSquareMagnitude(u.getImp())}},{key:"CrossCross",value:function(u,c){this.imp.CrossCross(u.getImp(),c.getImp())}},{key:"CrossCrossed",value:function(u,c){return new l(this.imp.CrossCrossed(u.getImp(),c.getImp()))}},{key:"Dot",value:function(u){return this.imp.Dot(u.getImp())}},{key:"DotCross",value:function(u,c){return this.imp.DotCross(u.getImp(),c.getImp())}},{key:"Normalize",value:function(){this.imp.Normalize()}},{key:"Normalized",value:function(){return new l(this.imp.Normalized())}},{key:"Reverse",value:function(){this.imp.Reverse()}},{key:"Reversed",value:function(){return new l(this.imp.Reversed())}},{key:"SetLinearForm",value:function(u,c,y,b,m,O,N){isUniVec(u)&&isUniVec(c)&&arguments.length==2?(u=uniToVec(u),c=uniToVec(c),this.imp.SetLinearForm(u.getImp(),c.getImp())):typeof u=="number"&&isUniVec(c)&&isUniVec(y)&&arguments.length==3?(c=uniToVec(c),y=uniToVec(y),this.imp.SetLinearForm(u,c.getImp(),y.getImp())):typeof u=="number"&&isUniVec(c)&&typeof y=="number"&&isUniVec(b)&&arguments.length==4?(c=uniToVec(c),b=uniToVec(b),this.imp.SetLinearForm(u,c.getImp(),y,b.getImp())):typeof u=="number"&&isUniVec(c)&&typeof y=="number"&&isUniVec(b)&&isUniVec(m)&&arguments.length==5?(c=uniToVec(c),b=uniToVec(b),m=uniToVec(m),this.imp.SetLinearForm(u,c.getImp(),y,b.getImp(),m.getImp())):typeof u=="number"&&isUniVec(c)&&typeof y=="number"&&isUniVec(b)&&typeof m=="number"&&isUniVec(O)&&arguments.length==6?(c=uniToVec(c),b=uniToVec(b),O=uniToVec(O),this.imp.SetLinearForm(u,c.getImp(),y,b.getImp(),m,O.getImp())):typeof u=="number"&&isUniVec(c)&&typeof y=="number"&&isUniVec(b)&&typeof m=="number"&&isUniVec(O)&&isUniVec(N)&&(c=uniToVec(c),b=uniToVec(b),O=uniToVec(O),N=uniToVec(N),this.imp.SetLinearForm(u,c.getImp(),y,b.getImp(),m,O.getImp(),N.getImp()))}},{key:"MirrorByVec",value:function(u){this.imp.MirrorByVec(u.getImp())}},{key:"MirroredByVec",value:function(u){return new l(this.imp.MirroredByVec(u.getImp()))}},{key:"MirrorByAxis",value:function(u){this.imp.MirrorByAxis(u.getImp())}},{key:"MirroredByAxis",value:function(u){return new l(this.imp.MirroredByAxis(u.getImp()))}},{key:"MirrorByCSYSR",value:function(u){this.imp.MirrorByCSYSR(u.getImp())}},{key:"MirroredByCSYSR",value:function(u){return new l(this.imp.MirroredByCSYSR(u.getImp()))}},{key:"Rotate",value:function(u,c){this.imp.Rotate(u.getImp(),c)}},{key:"Rotated",value:function(u,c){return new l(this.imp.Rotated(u.getImp(),c))}},{key:"Scale",value:function(u){this.imp.Scale(u)}},{key:"Scaled",value:function(u){return new l(this.imp.Scaled(u))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Transformed",value:function(u){return new l(this.imp.Transformed(u.getImp()))}}]),l}(Mx3dGeObject),Mx3dGeBndBox=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),n?n instanceof Mx3dGePoint&&u instanceof Mx3dGePoint?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeBndBox(n.getImp(),u.getImp()))):n instanceof Object&&arguments.length===1&&(c=e.call(this,n)):(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeBndBox)),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"SetWhole",value:function(){this.imp.SetWhole()}},{key:"SetVoid",value:function(){this.imp.SetVoid()}},{key:"Set",value:function(u,c){this.imp.Set(u.getImp(),c.getImp())}},{key:"Update",value:function(u,c,y,b,m,O){this.imp.Update(u,c,y,b,m,O)}},{key:"GetGap",value:function(){return this.imp.GetGap()}},{key:"SetGap",value:function(u){this.imp.SetGap(u)}},{key:"Enlarge",value:function(u){this.imp.Enlarge(u)}},{key:"CornerMin",value:function(){return new Mx3dGePoint(this.imp.CornerMin())}},{key:"CornerMax",value:function(){return new Mx3dGePoint(this.imp.CornerMax())}},{key:"OpenXmin",value:function(){this.imp.OpenXmin()}},{key:"OpenXmax",value:function(){this.imp.OpenXmax()}},{key:"OpenYmin",value:function(){this.imp.OpenYmin()}},{key:"OpenYmax",value:function(){this.imp.OpenYmax()}},{key:"OpenZmin",value:function(){this.imp.OpenZmin()}},{key:"OpenZmax",value:function(){this.imp.OpenZmax()}},{key:"IsOpen",value:function(){return this.imp.IsOpen()}},{key:"IsOpenXmin",value:function(){return this.imp.IsOpenXmin()}},{key:"IsOpenXmax",value:function(){return this.imp.IsOpenXmax()}},{key:"IsOpenYmin",value:function(){return this.imp.IsOpenYmin()}},{key:"IsOpenYmax",value:function(){return this.imp.IsOpenYmax()}},{key:"IsOpenZmin",value:function(){return this.imp.IsOpenZmin()}},{key:"IsOpenZmax",value:function(){return this.imp.IsOpenZmax()}},{key:"IsWhole",value:function(){return this.imp.IsWhole()}},{key:"IsVoid",value:function(){return this.imp.IsVoid()}},{key:"IsXThin",value:function(u){return this.imp.IsXThin(u)}},{key:"IsYThin",value:function(u){return this.imp.IsYThin(u)}},{key:"IsZThin",value:function(u){return this.imp.IsZThin(u)}},{key:"IsThin",value:function(u){return this.imp.IsThin(u)}},{key:"Transformed",value:function(u){return new l(this.imp.Transformed(u.getImp()))}},{key:"AddBndBox",value:function(u){this.imp.AddBndBox(u.getImp())}},{key:"AddPoint",value:function(u){this.imp.AddPoint(u.getImp())}},{key:"AddPointDir",value:function(u,c){this.imp.AddPointDir(u.getImp(),c.getImp())}},{key:"AddDir",value:function(u){this.imp.AddDir(u.getImp())}},{key:"IsOutPoint",value:function(u){return this.imp.IsOutPoint(u.getImp())}},{key:"IsOutBndBox",value:function(u,c){return c?this.imp.IsOutBndBox(u.getImp(),c.getImp()):this.imp.IsOutBndBox(u.getImp())}},{key:"IsOutTBT",value:function(u,c,y){return this.imp.IsOutTBT(u.getImp(),c.getImp(),y.getImp())}},{key:"IsOutPPD",value:function(u,c,y){return this.imp.IsOutPPD(u.getImp(),c.getImp(),y.getImp())}},{key:"Distance",value:function(u){return this.imp.Distance(u.getImp())}},{key:"SquareExtent",value:function(){return this.imp.SquareExtent()}},{key:"FinitePart",value:function(){return new l(this.imp.FinitePart())}},{key:"HasFinitePart",value:function(){return this.imp.HasFinitePart()}}]),l}(Mx3dGeObject),Mx3dGeCircle=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),!n&&!u?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeCircle)):n instanceof Mx3dGeCSYSR&&typeof u=="number"?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeCircle(n.getImp(),u))):n instanceof Object&&(c=e.call(this,n)),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"SetAxis",value:function(u){this.imp.SetAxis(u.getImp())}},{key:"SetLocation",value:function(u){this.imp.SetLocation(u.getImp())}},{key:"SetPosition",value:function(u){this.imp.SetPosition(u.getImp())}},{key:"SetRadius",value:function(u){this.imp.SetRadius(u)}},{key:"Area",value:function(){return this.imp.Area()}},{key:"Axis",value:function(){return new Mx3dGeAxis(this.imp.Axis())}},{key:"Length",value:function(){return this.imp.Length()}},{key:"Location",value:function(){return new Mx3dGePoint(this.imp.Location())}},{key:"Position",value:function(){return new Mx3dGeCSYSR(this.imp.Position())}},{key:"Radius",value:function(){return this.imp.Radius()}},{key:"XAxis",value:function(){return new Mx3dGeAxis(this.imp.XAxis())}},{key:"YAxis",value:function(){return new Mx3dGeAxis(this.imp.YAxis())}},{key:"Distance",value:function(u){return this.imp.Distance(u.getImp())}},{key:"SquareDistance",value:function(u){return this.imp.SquareDistance(u.getImp())}},{key:"Contains",value:function(u,c){return this.imp.Contains(u.getImp(),c)}},{key:"MirrorByPoint",value:function(u){this.imp.MirrorByPoint(u.getImp())}},{key:"MirroredByPoint",value:function(u){return new l(this.imp.MirroredByPoint(u.getImp()))}},{key:"MirrorByAxis",value:function(u){this.imp.MirrorByAxis(u.getImp())}},{key:"MirroredByAxis",value:function(u){return new l(this.imp.MirroredByAxis(u.getImp()))}},{key:"MirrorByCSYSR",value:function(u){this.imp.MirrorByCSYSR(u.getImp())}},{key:"MirroredByCSYSR",value:function(u){return new l(this.imp.MirroredByCSYSR(u.getImp()))}},{key:"Rotate",value:function(u,c){this.imp.Rotate(u.getImp(),c)}},{key:"Rotated",value:function(u,c){return new l(this.imp.Rotated(u.getImp(),c))}},{key:"Scale",value:function(u,c){this.imp.Scale(u.getImp(),c)}},{key:"Scaled",value:function(u,c){return new l(this.imp.Scaled(u.getImp(),c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Transformed",value:function(u){return new l(this.imp.Transformed(u.getImp()))}},{key:"TranslateByVec",value:function(u){this.imp.TranslateByVec(u.getImp())}},{key:"TranslatedByVec",value:function(u){return new l(this.imp.TranslatedByVec(u.getImp()))}},{key:"TranslateBy2Points",value:function(u,c){this.imp.TranslateBy2Points(u.getImp(),c.getImp())}},{key:"TranslatedBy2Points",value:function(u,c){return new l(this.imp.TranslatedBy2Points(u.getImp(),c.getImp()))}}]),l}(Mx3dGeObject),Mx3dShapeObject=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):u=e.call(this),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"getBndBox",value:function(){return new Mx3dGeBndBox(this.imp.getBndBox())}},{key:"reverse",value:function(){this.imp.reverse()}},{key:"reversed",value:function(){return new l(this.imp.reversed())}},{key:"Orientation",value:function(){return this.imp.Orientation()}},{key:"move",value:function(u){this.imp.move(u.getImp())}},{key:"moved",value:function(u){return new l(this.imp.moved(u.getImp()))}},{key:"clone",value:function(){return new l(this.imp.clone())}},{key:"fuse",value:function(u){return new l(this.imp.fuse(u.getImp()))}},{key:"cut",value:function(u){return new l(this.imp.cut(u.getImp()))}},{key:"common",value:function(u){return new l(this.imp.common(u.getImp()))}},{key:"section",value:function(u){return new l(this.imp.section(u.getImp()))}},{key:"spliter",value:function(u){var c=new Mx3dShapeObjectSequence;u.forEach(function(N){return c.Append(N)});for(var y=new Mx3dShapeObjectSequence(this.imp.spliter(c.getImp())),b=new Array,m=1;m<=y.Length();m++){var O=y.Value(m);b.push(O)}return b}},{key:"MirrorByPoint",value:function(u){this.imp.MirrorByPoint(u.getImp())}},{key:"MirroredByPoint",value:function(u){return new l(this.imp.MirroredByPoint(u.getImp()))}},{key:"MirrorByAxis",value:function(u){this.imp.MirrorByAxis(u.getImp())}},{key:"MirroredByAxis",value:function(u){return new l(this.imp.MirroredByAxis(u.getImp()))}},{key:"MirrorByCSYSR",value:function(u){this.imp.MirrorByCSYSR(u.getImp())}},{key:"MirroredByCSYSR",value:function(u){return new l(this.imp.MirroredByCSYSR(u.getImp()))}},{key:"Rotate",value:function(u,c){this.imp.Rotate(u.getImp(),c)}},{key:"Rotated",value:function(u,c){return new l(this.imp.Rotated(u.getImp(),c))}},{key:"Scale",value:function(u,c){this.imp.Scale(u.getImp(),c)}},{key:"Scaled",value:function(u,c){return new l(this.imp.Scaled(u.getImp(),c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Transformed",value:function(u){return new l(this.imp.Transformed(u.getImp()))}},{key:"TranslateByVec",value:function(u,c,y){u instanceof Mx3dGeVec?this.imp.TranslateByVec(u.getImp()):this.imp.TranslateByVec(u,c,y)}},{key:"TranslatedByVec",value:function(u,c,y){return u instanceof Mx3dGeVec?new l(this.imp.TranslatedByVec(u.getImp())):new l(this.imp.TranslatedByVec(u,c,y))}},{key:"TranslateBy2Points",value:function(u,c){this.imp.TranslateBy2Points(u.getImp(),c.getImp())}},{key:"TranslatedBy2Points",value:function(u,c){return new l(this.imp.TranslatedBy2Points(u.getImp(),c.getImp()))}},{key:"Explore",value:function(u){for(var c=new Mx3dShapeObjectSequence(this.imp.Explore(u)),y=new Array,b=1;b<=c.Length();b++){var m=c.Value(b);y.push(m)}return y}},{key:"ShapeType",value:function(){return this.imp.ShapeType()}},{key:"Quantities",value:function(u){return this.imp.Quantities(u)}},{key:"Centroid",value:function(u){return new Mx3dGePoint(this.imp.Centroid(u))}}]),l}(Mx3dBaseObject),Mx3dShapeFace=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dShapeFace)),_possibleConstructorReturn$1(u)}return _createClass$1(l)}(Mx3dShapeObject),Mx3dShapeVertex=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dShapeVertex)),_possibleConstructorReturn$1(u)}return _createClass$1(l)}(Mx3dShapeObject),Mx3dShapeEdge=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),n?n instanceof Mx3dGePoint&&u instanceof Mx3dGePoint?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dShapeEdge(n.getImp(),u.getImp()))):c=e.call(this,n):(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dShapeEdge)),_possibleConstructorReturn$1(c)}return _createClass$1(l)}(Mx3dShapeObject),Mx3dShapeWire=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dShapeWire)),_possibleConstructorReturn$1(u)}return _createClass$1(l)}(Mx3dShapeObject),Mx3dShapeShell=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dShapeShell)),_possibleConstructorReturn$1(u)}return _createClass$1(l)}(Mx3dShapeObject),Mx3dShapeSolid=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dShapeSolid)),_possibleConstructorReturn$1(u)}return _createClass$1(l)}(Mx3dShapeObject),Mx3dShapeCompSolid=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dShapeCompSolid)),_possibleConstructorReturn$1(u)}return _createClass$1(l)}(Mx3dShapeObject),Mx3dShapeCompound=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dShapeCompound)),_possibleConstructorReturn$1(u)}return _createClass$1(l)}(Mx3dShapeObject),Mx3dAlgoFillet=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),n instanceof Mx3dShapeObject&&typeof u=="number"?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dAlgoFillet(n.getImp(),u))):c=e.call(this,n),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"Add",value:function(u,c){this.imp.Add(u,c.getImp())}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}}]),l}(Mx3dAlgoObject),Mx3dAlgoChamfer=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n instanceof Mx3dShapeObject?(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dAlgoChamfer(n.getImp()))):n instanceof Object&&(u=e.call(this,n)),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"Add",value:function(u,c){this.imp.Add(u,c.getImp())}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}}]),l}(Mx3dAlgoObject),Mx3dAlgoFillet2d=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),n?n instanceof Mx3dShapeWire&&u instanceof Mx3dGePlane?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dAlgoFillet2d(n.getImp(),u.getImp()))):n instanceof Mx3dShapeEdge&&u instanceof Mx3dShapeEdge&&c instanceof Mx3dGePlane?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dAlgoFillet2d(n.getImp(),u.getImp(),c.getImp()))):y=e.call(this,n):(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dAlgoFillet2d)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"Init",value:function(u,c,y){u instanceof Mx3dShapeWire&&c instanceof Mx3dGePlane?this.imp.Init(u.getImp(),c.getImp()):this.imp.Init(u.getImp(),c.getImp(),y?.getImp())}},{key:"Perform",value:function(u){return this.imp.Perform(u)}},{key:"NbResults",value:function(u){return this.imp.NbResults(u.getImp())}},{key:"Result",value:function(u,c,y){var b=arguments.length>3&&arguments[3]!==void 0?arguments[3]:-1;return new Mx3dShapeEdge(this.imp.Result(u.getImp(),c.getImp(),y.getImp(),b))}}]),l}(Mx3dAlgoObject),Mx3dShapeObjectSequence=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dShapeObjectSequence)),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"Length",value:function(){return this.imp.Length()}},{key:"Value",value:function(u){return new Mx3dShapeObject(this.imp.Value(u))}},{key:"Remove",value:function(u,c){c?this.imp.Remove(u,c):this.imp.Remove(u)}},{key:"Append",value:function(u){this.imp.Append(u.getImp())}},{key:"Prepend",value:function(u){this.imp.Prepend(u.getImp())}}]),l}(Mx3dBaseObject),Mx3dDbObject=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l)}(Mx3dBaseObject),Mx3dView=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),u=e.call(this),u.initTempObject(n),u}return _createClass$1(l,[{key:"getDocument",value:function(){return new Mx3dDbDocument(this.imp.getDoc(),"from view")}},{key:"removeAll",value:function(){var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.imp.removeAll(u)}},{key:"removeSelected",value:function(){this.imp.removeSelected()}},{key:"update",value:function(){var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;this.imp.update(u,c)}},{key:"setProjectionType",value:function(u){this.imp.setProjectionType(u)}},{key:"showCenterTrihedron",value:function(u){this.imp.showCenterTrihedron(u)}},{key:"fitAllObjects",value:function(u){this.imp.fitAllObjects(u)}},{key:"enableXClipPlane",value:function(u){this.imp.enableXClipPlane(u)}},{key:"setXClipPlaneXPosition",value:function(u){this.imp.setXClipPlaneXPosition(u)}},{key:"setXClipPlaneReverse",value:function(){this.imp.setXClipPlaneReverse()}},{key:"enableYClipPlane",value:function(u){this.imp.enableYClipPlane(u)}},{key:"setYClipPlaneYPosition",value:function(u){this.imp.setYClipPlaneYPosition(u)}},{key:"setYClipPlaneReverse",value:function(){this.imp.setYClipPlaneReverse()}},{key:"enableZClipPlane",value:function(u){this.imp.enableZClipPlane(u)}},{key:"setZClipPlaneZPosition",value:function(u){this.imp.setZClipPlaneZPosition(u)}},{key:"setZClipPlaneReverse",value:function(){this.imp.setZClipPlaneReverse()}},{key:"enableCustomClipPlane",value:function(u){this.imp.enableCustomClipPlane(u)}},{key:"setCustomClipPlanePosition",value:function(u){this.imp.setCustomClipPlanePosition(u)}},{key:"setCustomClipPlaneReverse",value:function(){this.imp.setCustomClipPlaneReverse()}},{key:"setCustomClipPlaneDirection",value:function(u,c,y){this.imp.setCustomClipPlaneDirection(u,c,y)}},{key:"displaySymbolText",value:function(u){this.imp.displaySymbolText(u.getImp())}},{key:"displayDimension",value:function(u){this.imp.displayDimension(u.getImp())}},{key:"addModelTexture",value:function(u){this.imp.addModelTexture(u)}},{key:"removeModelTexture",value:function(){this.imp.removeModelTexture()}},{key:"setGradientBgColor",value:function(u,c,y){this.imp.setGradientBgColor(u.getImp(),c.getImp(),y)}},{key:"setProj",value:function(u,c){this.imp.setProj(u,c)}},{key:"setSelectedColor",value:function(u){this.imp.setSelectedColor(u.getImp())}},{key:"setSelectedMaterial",value:function(u){this.imp.setSelectedMaterial(u.getImp())}},{key:"setDisplayMode",value:function(u){this.imp.setDisplayMode(u)}},{key:"enableDirLightSrc",value:function(u){this.imp.enableDirLightSrc(u)}},{key:"setCubemapBackground",value:function(u,c,y,b,m,O){this.imp.setCubemapBackground(u,c,y,b,m,O)}},{key:"setManipulatorEnabled",value:function(u){this.imp.setManipulatorEnabled(u)}}]),l}(Mx3dBaseObject),Mx3dGeColor=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y){var b;return _classCallCheck$1(this,l),arguments.length===0?(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dGeColor)):typeof n=="number"&&arguments.length===1?(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dGeColor(n))):n instanceof Object&&arguments.length===1?b=e.call(this,n):typeof n=="number"&&typeof u=="number"&&typeof c=="number"&&typeof y=="number"&&(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dGeColor(n,u,c,y))),_possibleConstructorReturn$1(b)}return _createClass$1(l,[{key:"Name",value:function(){return this.imp.Name()}},{key:"SetValues",value:function(u,c,y,b){arguments.length===1?this.imp.SetValues(u):arguments.length===4&&this.imp.SetValues(u,c,y,b)}},{key:"Red",value:function(){return this.imp.Red()}},{key:"Green",value:function(){return this.imp.Green()}},{key:"Blue",value:function(){return this.imp.Blue()}},{key:"Hue",value:function(){return this.imp.Hue()}},{key:"Light",value:function(){return this.imp.Light()}},{key:"ChangeIntensity",value:function(u){this.imp.ChangeIntensity(u)}},{key:"Saturation",value:function(){return this.imp.Saturation()}},{key:"ChangeContrast",value:function(u){this.imp.ChangeContrast(u)}},{key:"IsDifferent",value:function(u){return this.imp.IsDifferent(u.getImp())}},{key:"IsEqual",value:function(u){return this.imp.IsEqual(u.getImp())}},{key:"Distance",value:function(u){return this.imp.Distance(u.getImp())}},{key:"SquareDistance",value:function(u){return this.imp.SquareDistance(u.getImp())}},{key:"DeltaE2000",value:function(u){return this.imp.DeltaE2000(u.getImp())}}]),l}(Mx3dBaseObject),Mx3dGeCSYS=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),n?n instanceof Mx3dGeCSYSR&&arguments.length===1?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeCSYS(n.getImp()))):n instanceof Mx3dGePoint&&u instanceof Mx3dGeDir&&arguments.length===2?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeCSYS(n.getImp(),u.getImp()))):n instanceof Mx3dGePoint&&u instanceof Mx3dGeDir&&c instanceof Mx3dGeDir?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeCSYS(n.getImp(),u.getImp(),c.getImp()))):n instanceof Object&&(y=e.call(this,n)):(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeCSYS)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"XReverse",value:function(){this.imp.XReverse()}},{key:"YReverse",value:function(){this.imp.YReverse()}},{key:"ZReverse",value:function(){this.imp.ZReverse()}},{key:"SetAxis",value:function(u){this.imp.SetAxis(u.getImp())}},{key:"SetDirection",value:function(u){this.imp.SetDirection(u.getImp())}},{key:"SetLocation",value:function(u,c,y){u instanceof Mx3dGePoint?this.imp.SetLocation(u.getImp()):this.imp.SetLocation(u,c,y)}},{key:"SetXDirection",value:function(u){this.imp.SetXDirection(u.getImp())}},{key:"SetYDirection",value:function(u){this.imp.SetYDirection(u.getImp())}},{key:"Angle",value:function(u){return this.imp.Angle(u.getImp())}},{key:"Axis",value:function(){return new Mx3dGeAxis(this.imp.Axis())}},{key:"CSYSR",value:function(){return new Mx3dGeCSYSR(this.imp.CSYSR())}},{key:"Direction",value:function(){return new Mx3dGeDir(this.imp.Direction())}},{key:"Location",value:function(){return new Mx3dGePoint(this.imp.Location())}},{key:"XDirection",value:function(){return new Mx3dGeDir(this.imp.XDirection())}},{key:"YDirection",value:function(){return new Mx3dGeDir(this.imp.YDirection())}},{key:"Direct",value:function(){return this.imp.Direct()}},{key:"IsCoplanarWithCSYS",value:function(u,c,y){return this.imp.IsCoplanarWithCSYS(u.getImp(),c,y)}},{key:"IsCoplanarWithAxis",value:function(u,c,y){return this.imp.IsCoplanarWithAxis(u.getImp(),c,y)}},{key:"MirrorByPoint",value:function(u){this.imp.MirrorByPoint(u.getImp())}},{key:"MirroredByPoint",value:function(u){return new l(this.imp.MirroredByPoint(u.getImp()))}},{key:"MirrorByAxis",value:function(u){this.imp.MirrorByAxis(u.getImp())}},{key:"MirroredByAxis",value:function(u){return new l(this.imp.MirroredByAxis(u.getImp()))}},{key:"MirrorByCSYSR",value:function(u){this.imp.MirrorByCSYSR(u.getImp())}},{key:"MirroredByCSYSR",value:function(u){return new l(this.imp.MirroredByCSYSR(u.getImp()))}},{key:"Rotate",value:function(u,c){this.imp.Rotate(u.getImp(),c)}},{key:"Rotated",value:function(u,c){return new l(this.imp.Rotated(u.getImp(),c))}},{key:"Scale",value:function(u,c){this.imp.Scale(u.getImp(),c)}},{key:"Scaled",value:function(u,c){return new l(this.imp.Scaled(u.getImp(),c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Transformed",value:function(u){return new l(this.imp.Transformed(u.getImp()))}},{key:"TranslateByVec",value:function(u){this.imp.TranslateByVec(u.getImp())}},{key:"TranslatedByVec",value:function(u){return new l(this.imp.TranslatedByVec(u.getImp()))}},{key:"TranslateBy2Points",value:function(u,c){this.imp.TranslateBy2Points(u.getImp(),c.getImp())}},{key:"TranslatedBy2Points",value:function(u,c){return new l(this.imp.TranslatedBy2Points(u.getImp(),c.getImp()))}}]),l}(Mx3dGeObject),Mx3dGeCSYSR=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),n?n instanceof Mx3dGePoint&&u instanceof Mx3dGeDir&&!c?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeCSYSR(n.getImp(),u.getImp()))):n instanceof Mx3dGePoint&&u instanceof Mx3dGeDir&&c instanceof Mx3dGeDir?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeCSYSR(n.getImp(),u.getImp(),c.getImp()))):n instanceof Object&&arguments.length===1&&(y=e.call(this,n)):(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeCSYSR)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"Location",value:function(){return new Mx3dGePoint(this.imp.Location())}},{key:"XDirection",value:function(){return new Mx3dGeDir(this.imp.XDirection())}},{key:"YDirection",value:function(){return new Mx3dGeDir(this.imp.YDirection())}},{key:"Direction",value:function(){return new Mx3dGeDir(this.imp.Direction())}},{key:"SetLocation",value:function(u,c,y){u instanceof Mx3dGePoint?this.imp.SetLocation(u.getImp()):this.imp.SetLocation(u,c,y)}},{key:"SetXDirection",value:function(u){this.imp.SetXDirection(u.getImp())}},{key:"SetYDirection",value:function(u){this.imp.SetYDirection(u.getImp())}},{key:"SetDirection",value:function(u){this.imp.SetDirection(u.getImp())}},{key:"Angle",value:function(u){return this.imp.Angle(u.getImp())}},{key:"Axis",value:function(){return new Mx3dGeAxis(this.imp.Axis())}},{key:"IsCoplanarWithCSYSR",value:function(u,c,y){return this.imp.IsCoplanarWithCSYSR(u.getImp(),c,y)}},{key:"IsCoplanarWithAxis",value:function(u,c,y){return this.imp.IsCoplanarWithAxis(u.getImp(),c,y)}},{key:"MirrorByPoint",value:function(u){this.imp.MirrorByPoint(u.getImp())}},{key:"MirroredByPoint",value:function(u){return new l(this.imp.MirroredByPoint(u.getImp()))}},{key:"MirrorByAxis",value:function(u){this.imp.MirroredByAxis(u.getImp())}},{key:"MirroredByAxis",value:function(u){return new l(this.imp.MirroredByAxis(u.getImp()))}},{key:"MirrorByCSYSR",value:function(u){this.imp.MirrorByCSYSR(u.getImp())}},{key:"MirroredByCSYSR",value:function(u){return new l(this.imp.MirroredByCSYSR(u.getImp()))}},{key:"Rotate",value:function(u,c){this.imp.Rotate(u.getImp(),c)}},{key:"Rotated",value:function(u,c){return new l(this.imp.Rotated(u.getImp(),c))}},{key:"Scale",value:function(u,c){this.imp.Scale(u.getImp(),c)}},{key:"Scaled",value:function(u,c){return new l(this.imp.Scaled(u.getImp(),c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Transformed",value:function(u){return new l(this.imp.Transformed(u.getImp()))}},{key:"TranslateByVec",value:function(u){this.imp.TranslateByVec(u.getImp())}},{key:"TranslatedByVec",value:function(u){return new l(this.imp.TranslatedByVec(u.getImp()))}},{key:"TranslateBy2Points",value:function(u,c){this.imp.TranslateBy2Points(u.getImp(),c.getImp())}},{key:"TranslatedBy2Points",value:function(u,c){return new l(this.imp.TranslatedBy2Points(u.getImp(),c.getImp()))}}]),l}(Mx3dGeObject),Mx3dGeCylinder=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),n?n instanceof Mx3dGeCSYS&&typeof u=="number"?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeCylinder(n.getImp(),u))):c=e.call(this,n):(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeCylinder)),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"SetAxis",value:function(u){this.imp.SetAxis(u.getImp())}},{key:"SetLocation",value:function(u){this.imp.SetLocation(u.getImp())}},{key:"SetPosition",value:function(u){this.imp.SetPosition(u.getImp())}},{key:"SetRadius",value:function(u){this.imp.SetRadius(u)}},{key:"UReverse",value:function(){this.imp.UReverse()}},{key:"VReverse",value:function(){this.imp.VReverse()}},{key:"Direct",value:function(){return this.imp.Direct()}},{key:"Axis",value:function(){return new Mx3dGeAxis(this.imp.Axis())}},{key:"Location",value:function(){return new Mx3dGePoint(this.imp.Location())}},{key:"Position",value:function(){return new Mx3dGeCSYS(this.imp.Position())}},{key:"Radius",value:function(){return this.imp.Radius()}},{key:"XAxis",value:function(){return new Mx3dGeAxis(this.imp.XAxis())}},{key:"YAxis",value:function(){return new Mx3dGeAxis(this.imp.YAxis())}},{key:"MirrorByPoint",value:function(u){this.imp.MirrorByPoint(u.getImp())}},{key:"MirroredByPoint",value:function(u){return new l(this.imp.MirroredByPoint(u.getImp()))}},{key:"MirrorByAxis",value:function(u){this.imp.MirrorByAxis(u.getImp())}},{key:"MirroredByAxis",value:function(u){return new l(this.imp.MirroredByAxis(u.getImp()))}},{key:"MirrorByCSYSR",value:function(u){this.imp.MirrorByCSYSR(u.getImp())}},{key:"MirroredByCSYSR",value:function(u){return new l(this.imp.MirroredByCSYSR(u.getImp()))}},{key:"Rotate",value:function(u,c){this.imp.Rotate(u.getImp(),c)}},{key:"Rotated",value:function(u,c){return new l(this.imp.Rotated(u.getImp(),c))}},{key:"Scale",value:function(u,c){this.imp.Scale(u.getImp(),c)}},{key:"Scaled",value:function(u,c){return new l(this.imp.Scaled(u.getImp(),c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Transformed",value:function(u){return new l(this.imp.Transformed(u.getImp()))}},{key:"TranslateByVec",value:function(u){this.imp.TranslatedByVec(u.getImp())}},{key:"TranslatedByVec",value:function(u){return new l(this.imp.TranslatedByVec(u.getImp()))}},{key:"TranslateBy2Points",value:function(u,c){this.imp.TranslateBy2Points(u.getImp(),c.getImp())}},{key:"TranslatedBy2Points",value:function(u,c){return new l(this.imp.TranslatedBy2Points(u.getImp(),c.getImp()))}},{key:"Shape",value:function(u,c){return c?new Mx3dShapeObject(this.imp.Shape(u,c)):new Mx3dShapeObject(this.imp.Shape(u))}}]),l}(Mx3dGeObject),MxNewMdGeArray1OfInteger=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),arguments.length==0?(c=e.call(this),c.initTempObject(new MxApp3D.imp.MdGeArray1OfInteger)):typeof n=="number"&&arguments.length==2?(c=e.call(this),c.initTempObject(new MxApp3D.imp.MdGeArray1OfInteger(n,u))):n instanceof Object&&arguments.length==1&&(c=e.call(this,n)),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"Init",value:function(u){this.imp.Init(u)}},{key:"Size",value:function(){return this.imp.Size()}},{key:"Length",value:function(){return this.imp.Length()}},{key:"IsEmpty",value:function(){return this.imp.IsEmpty()}},{key:"Lower",value:function(){return this.imp.Lower()}},{key:"Upper",value:function(){return this.imp.Upper()}},{key:"IsDeletable",value:function(){return this.imp.IsDeletable()}},{key:"IsAllocated",value:function(){return this.imp.IsAllocated()}},{key:"First",value:function(){return this.imp.First()}},{key:"Last",value:function(){return this.imp.Last()}},{key:"Value",value:function(u){return this.imp.Value(u)}},{key:"SetValue",value:function(u,c){this.imp.SetValue(u,c)}},{key:"Resize",value:function(u,c,y){this.imp.Resize(u,c,y)}}]),l}(Mx3dBaseObject),Mx3dDbDocument=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),n?n instanceof Object&&u==="from view"?(c=e.call(this),c.initTempObject(n)):c=e.call(this,n):(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dDbDocument)),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"read",value:function(u,c){var y=this,b=u.name,m=new FileReader;return new Promise(function(O,N){m.onload=function(){var L=new Uint8Array(m.result),G=L.length,q=MxApp3D.imp._malloc(G),J=new Uint8Array(MxApp3D.imp.HEAPU8.buffer,q,G);J.set(L);var fe=function(Ve){var rt=getStrFromMemory(Ve);console.log(rt)},ve=function(Ve){var rt=getStrFromMemory(Ve);console.log("failed load file: "+rt)},ne=MxApp3D.imp.addFunction(fe,"vp"),Ue=MxApp3D.imp.addFunction(ve,"vp");MxApp3D.imp.loadFileFromMemory("/"+b,q,G,!0,ne,Ue),MxApp3D.imp._free(q),O(y.imp.read(b,c))},m.onerror=function(L){N(L)},m.readAsArrayBuffer(u)})}},{key:"readFile",value:function(u,c){return this.imp.read(u,c)}},{key:"getAccessLabel",value:function(){return new Mx3dDbLabel(this.imp.getAccessLabel())}},{key:"getShapesLabel",value:function(){return new Mx3dDbLabel(this.imp.getShapesLabel())}},{key:"getColorsLabel",value:function(){return new Mx3dDbLabel(this.imp.getColorsLabel())}},{key:"getLayersLabel",value:function(){return new Mx3dDbLabel(this.imp.getLayersLabel())}},{key:"addShapeLabel",value:function(){return new Mx3dDbLabel(this.imp.addShapeLabel())}},{key:"removeShapeLabel",value:function(u){return this.imp.removeShapeLabel(u.getImp())}},{key:"removeComponent",value:function(u){this.imp.removeComponent(u.getImp())}},{key:"getTopFreeLabels",value:function(){for(var u=new Mx3dLabelSequence(this.imp.getTopFreeLabels()),c=new Array,y=1;y<=u.Length();y++){var b=u.Value(y);c.push(b)}return c}},{key:"getDocName",value:function(){for(var u=new MxNewMdGeArray1OfInteger(this.imp.getDocName()),c=[],y=1;y<=u.Length();y++)c.push(u.Value(y));return c.map(function(b){return String.fromCharCode(b)}).join("")}},{key:"getView",value:function(){return new Mx3dView(this.imp.getView())}},{key:"addColorLabel",value:function(u){return new Mx3dDbLabel(this.imp.addColorLabel(u.getImp()))}},{key:"write",value:function(u,c){var y=this.imp.write(u,c);if(!y)return y;var b=MxApp3D.imp.getFileSize(u);if(b==-1)return!1;var m=MxApp3D.imp.getFileArryBufferPointer(u);if(m==0)return!1;var O=new Uint8Array(MxApp3D.imp.HEAPU8.buffer,m,b),N=new Blob([O],{type:"application/octet-stream"});return MxTools.saveAsFileDialog({blob:N,filename:u,types:[]}),MxApp3D.imp._free(m),!0}},{key:"newCommand",value:function(){this.imp.newCommand()}},{key:"abortCommand",value:function(){this.imp.abortCommand()}},{key:"commitCommand",value:function(){return this.imp.commitCommand()}},{key:"undo",value:function(){return this.imp.undo()}},{key:"redo",value:function(){return this.imp.redo()}}]),l}(Mx3dDbObject),Mx3dDbLabel=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dDbLabel)),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"setShape",value:function(u){this.imp.setShape(u.getImp())}},{key:"getShape",value:function(){return new Mx3dShapeObject(this.imp.getShape())}},{key:"hasChildLabel",value:function(){return this.imp.hasChildLabel()}},{key:"getChildLabels",value:function(){for(var u=new Mx3dLabelSequence(this.imp.getChildLabels()),c=new Array,y=1;y<=u.Length();y++){var b=u.Value(y);c.push(b)}return c}},{key:"hasParentLabel",value:function(){return this.imp.hasParentLabel()}},{key:"getParentLabel",value:function(){return new l(this.imp.getParentLabel())}},{key:"addChildLabel",value:function(){return new l(this.imp.addChildLabel())}},{key:"addSubShape",value:function(u){return new l(this.imp.addChildShape(u.getImp()))}},{key:"isReference",value:function(){return this.imp.isReference()}},{key:"isAssembly",value:function(){return this.imp.isAssembly()}},{key:"isSimpleShape",value:function(){return this.imp.isSimpleShape()}},{key:"isTopLevel",value:function(){return this.imp.isTopLevel()}},{key:"isFree",value:function(){return this.imp.isFree()}},{key:"isShape",value:function(){return this.imp.isShape()}},{key:"isComponent",value:function(){return this.imp.isComponent()}},{key:"isCompound",value:function(){return this.imp.isCompound()}},{key:"isSubShape",value:function(){return this.imp.isSubShape()}},{key:"getReferredLabel",value:function(){return new l(this.imp.getReferredLabel())}},{key:"getLocation",value:function(){return new Mx3dGeLocation(this.imp.getLocation())}},{key:"addComponent",value:function(u,c){return new l(this.imp.addComponent(u.getImp(),c.getImp()))}},{key:"setName",value:function(u){this.imp.setName(u)}},{key:"hasShape",value:function(){return this.imp.hasShape()}},{key:"isSetColor",value:function(){return this.imp.isSetColor()}},{key:"setColor",value:function(u){this.imp.setColor(u.getImp())}},{key:"getColor",value:function(){return new Mx3dGeColor(this.imp.getColor())}},{key:"getName",value:function(){for(var u=new MxNewMdGeArray1OfInteger(this.imp.getName()),c=[],y=1;y<=u.Length();y++)c.push(u.Value(y));return c.map(function(b){return String.fromCharCode(b)}).join("")}},{key:"getEntry",value:function(){return this.imp.getEntry()}},{key:"getAttributeStr",value:function(){return this.imp.getAttributeStr()}},{key:"setTexture",value:function(u){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,y=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,b=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1,m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:1,O=arguments.length>5&&arguments[5]!==void 0?arguments[5]:0,N=arguments.length>6&&arguments[6]!==void 0?arguments[6]:0;this.imp.setTexture(u,c,y,b,m,O,N)}},{key:"setMaterial",value:function(u){this.imp.setMaterial(u.getImp())}}]),l}(Mx3dDbObject),Mx3dLabelSequence=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dLabelSequence)),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"Length",value:function(){return this.imp.Length()}},{key:"Value",value:function(u){return new Mx3dDbLabel(this.imp.Value(u))}}]),l}(Mx3dBaseObject),Mx3dGeLocation=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?n instanceof Mx3dGeTrsf?(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dGeLocation(n.getImp()))):u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dGeLocation)),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"IsIdentity",value:function(){return this.imp.IsIdentity()}},{key:"Identity",value:function(){this.imp.Identity()}},{key:"FirstPower",value:function(){return this.imp.FirstPower()}},{key:"NextLocation",value:function(){return new l(this.imp.NextLocation())}},{key:"Inverted",value:function(){return new l(this.imp.Inverted())}},{key:"Multiplied",value:function(u){return new l(this.imp.Multiplied(u.getImp()))}},{key:"Divided",value:function(u){return new l(this.imp.Divided(u.getImp()))}},{key:"Predivided",value:function(u){return new l(this.imp.Predivided(u.getImp()))}},{key:"Powered",value:function(u){return new l(this.imp.Powered(u))}},{key:"IsEqual",value:function(u){return this.imp.IsEqual(u.getImp())}},{key:"IsDifferent",value:function(u){return this.imp.IsDifferent(u.getImp())}},{key:"Clear",value:function(){this.imp.Clear()}},{key:"ScalePrec",value:function(){return this.imp.ScalePrec()}}]),l}(Mx3dGeObject),Mx3dGePlane=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y){var b;return _classCallCheck$1(this,l),n?n instanceof Mx3dGeCSYS?(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dGePlane(n.getImp()))):n instanceof Mx3dGePoint&&u instanceof Mx3dGeDir?(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dGePlane(n.getImp(),u.getImp()))):typeof n=="number"&&typeof u=="number"&&typeof c=="number"&&typeof y=="number"?(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dGePlane(n,u,c,y))):n instanceof Object&&(b=e.call(this,n)):(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dGePlane)),_possibleConstructorReturn$1(b)}return _createClass$1(l,[{key:"SetAxis",value:function(u){this.imp.SetAxis(u.getImp())}},{key:"SetLocation",value:function(u){this.imp.SetLocation(u.getImp())}},{key:"SetPosition",value:function(u){this.imp.SetPosition(u.getImp())}},{key:"UReverse",value:function(){this.imp.UReverse()}},{key:"VReverse",value:function(){this.imp.VReverse()}},{key:"Direct",value:function(){return this.imp.Direct()}},{key:"Axis",value:function(){return new Mx3dGeAxis(this.imp.Axis())}},{key:"Location",value:function(){return new Mx3dGePoint(this.imp.Location())}},{key:"Position",value:function(){return new Mx3dGeCSYS(this.imp.Position())}},{key:"DistanceToPoint",value:function(u){return this.imp.DistanceToPoint(u.getImp())}},{key:"DistanceToPlane",value:function(u){return this.imp.DistanceToPlane(u.getImp())}},{key:"SquareDistanceToPoint",value:function(u){return this.imp.SquareDistanceToPoint(u.getImp())}},{key:"SquareDistanceToPlane",value:function(u){return this.imp.SquareDistanceToPlane(u.getImp())}},{key:"XAxis",value:function(){return new Mx3dGeAxis(this.imp.XAxis())}},{key:"YAxis",value:function(){return new Mx3dGeAxis(this.imp.YAxis())}},{key:"Contains",value:function(u,c){return this.imp.Contains(u.getImp(),c)}},{key:"MirrorByPoint",value:function(u){this.imp.MirrorByPoint(u.getImp())}},{key:"MirroredByPoint",value:function(u){return new l(this.imp.MirroredByPoint(u.getImp()))}},{key:"MirrorByAxis",value:function(u){this.imp.MirrorByAxis(u.getImp())}},{key:"MirroredByAxis",value:function(u){return new l(this.imp.MirroredByAxis(u.getImp()))}},{key:"MirrorByCSYSR",value:function(u){this.imp.MirrorByCSYSR(u.getImp())}},{key:"MirroredByCSYSR",value:function(u){return new l(this.imp.MirroredByCSYSR(u.getImp()))}},{key:"Rotate",value:function(u,c){this.imp.Rotate(u.getImp(),c)}},{key:"Rotated",value:function(u,c){return new l(this.imp.Rotated(u.getImp(),c))}},{key:"Scale",value:function(u,c){this.imp.Scale(u.getImp(),c)}},{key:"Scaled",value:function(u,c){return new l(this.imp.Scaled(u.getImp(),c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Transformed",value:function(u){return new l(this.imp.Transformed(u.getImp()))}},{key:"TranslateByVec",value:function(u){this.imp.TranslateByVec(u.getImp())}},{key:"TranslatedByVec",value:function(u){return new l(this.imp.TranslatedByVec(u.getImp()))}},{key:"TranslateBy2Points",value:function(u,c){this.imp.TranslateBy2Points(u.getImp(),c.getImp())}},{key:"TranslatedBy2Points",value:function(u,c){return new l(this.imp.TranslatedBy2Points(u.getImp(),c.getImp()))}},{key:"Shape",value:function(u,c,y,b){return u?new Mx3dShapeObject(this.imp.Shape(u,c,y,b)):new Mx3dShapeObject(this.imp.Shape())}}]),l}(Mx3dGeObject),Mx3dSymbolText=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),n?typeof n=="string"&&typeof u=="number"&&c instanceof Mx3dGePoint?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dSymbolText(n,u,c.getImp()))):n instanceof Object&&(y=e.call(this,n)):(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dSymbolText)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"SetColor",value:function(u,c,y){u instanceof Mx3dGeColor?this.imp.SetColor(u.getImp()):this.imp.SetColor(u,c,y)}},{key:"SetText",value:function(u){this.imp.SetText(u)}},{key:"SetPositon",value:function(u){this.imp.SetPositon(u.getImp())}},{key:"SetHJustification",value:function(u){this.imp.SetHJustification(u)}},{key:"SetVJustification",value:function(u){this.imp.SetVJustification(u)}},{key:"SetAngle",value:function(u){this.imp.SetAngle(u)}},{key:"SetZoomable",value:function(u){this.imp.SetZoomable(u)}},{key:"SetHeight",value:function(u){this.imp.SetHeight(u)}},{key:"SetFontAspect",value:function(u){this.imp.SetFontAspect(u)}},{key:"SetFont",value:function(u){this.imp.SetFont(u)}},{key:"SetOrientation3D",value:function(u){this.imp.SetOrientation3D(u.getImp())}},{key:"UnsetOrientation3D",value:function(){this.imp.UnsetOrientation3D()}},{key:"Position",value:function(){return new Mx3dGePoint(this.imp.Position())}},{key:"FontAspect",value:function(){return this.imp.FontAspect()}},{key:"Orientation3D",value:function(){return new Mx3dGeCSYSR(this.imp.Orientation3D())}},{key:"HasOrientation3D",value:function(){return this.imp.HasOrientation3D()}},{key:"SetFlipping",value:function(u){this.imp.SetFlipping(u)}},{key:"HasFlipping",value:function(){return this.imp.HasFlipping()}},{key:"HasOwnAnchorPoint",value:function(){return this.imp.HasOwnAnchorPoint()}},{key:"SetOwnAnchorPoint",value:function(u){this.imp.SetOwnAnchorPoint(u)}},{key:"SetDisplayType",value:function(u){this.imp.SetDisplayType(u)}},{key:"SetColorSubTitle",value:function(u,c,y){this.imp.SetColorSubTitle(u,c,y)}}]),l}(Mx3dSymbolObject),Mx3dShapeDownCast=function(){function t(){_classCallCheck$1(this,t)}return _createClass$1(t,null,[{key:"Vertex",value:function(l){return new Mx3dShapeVertex(MxApp3D.globalMethods.Vertex(l.getImp()))}},{key:"Edge",value:function(l){return new Mx3dShapeEdge(MxApp3D.globalMethods.Edge(l.getImp()))}},{key:"Wire",value:function(l){return new Mx3dShapeWire(MxApp3D.globalMethods.Wire(l.getImp()))}},{key:"Face",value:function(l){return new Mx3dShapeFace(MxApp3D.globalMethods.Face(l.getImp()))}},{key:"Shell",value:function(l){return new Mx3dShapeShell(MxApp3D.globalMethods.Shell(l.getImp()))}},{key:"Solid",value:function(l){return new Mx3dShapeSolid(MxApp3D.globalMethods.Solid(l.getImp()))}},{key:"CompSolid",value:function(l){return new Mx3dShapeCompSolid(MxApp3D.globalMethods.CompSolid(l.getImp()))}},{key:"Compound",value:function(l){return new Mx3dShapeCompound(MxApp3D.globalMethods.Compound(l.getImp()))}}]),t}(),Mx3dBrepCastGeom=function(){function t(){_classCallCheck$1(this,t)}return _createClass$1(t,null,[{key:"Surface",value:function(l){return new Mx3dGeomSurface(MxApp3D.globalMethods.Surface(l.getImp()))}},{key:"Curve",value:function(l,n){var u=new MxApp3D.imp.MdGeArray1OfReal(1,2),c=MxApp3D.globalMethods.Curve(l.getImp(),u);return n[0]=u.Value(1),n[1]=u.Value(2),new Mx3dGeomCurve(c)}}]),t}();function getStrFromMemory(t){for(var e=MxApp3D.globalMethods.getStrFromMemory(t),l=[],n=1;n<=e.Length();n++)l.push(e.Value(n));return l.map(function(u){return String.fromCharCode(u)}).join("")}var Mx3dUtils=function(){function t(){_classCallCheck$1(this,t)}return _createClass$1(t,null,[{key:"LoadFileFromUrl",value:function(l,n){return new Promise(function(u,c){var y=function(L){var G=getStrFromMemory(L);u(G)},b=function(L){var G=getStrFromMemory(L);c("failed load file: "+G)},m=MxApp3D.imp.addFunction(y,"vp"),O=MxApp3D.imp.addFunction(b,"vp");MxApp3D.globalMethods.LoadFileFromUrl(l,n,m,O)})}},{key:"LoadShapeFromFile",value:function(l,n){for(var u=[],c=MxApp3D.globalMethods.LoadShapeFromFile(l,n),y=1;y<=c.Length();y++)u.push(new Mx3dShapeObject(c.Value(y)));return u}},{key:"LoadLocalFile",value:function(l,n){var u=new FileReader;return new Promise(function(c,y){u.onload=function(){var b=new Uint8Array(u.result),m=b.length,O=MxApp3D.imp._malloc(m),N=new Uint8Array(MxApp3D.imp.HEAPU8.buffer,O,m);N.set(b);var L=function(ve){var ne=getStrFromMemory(ve);c(ne)},G=function(ve){var ne=getStrFromMemory(ve);y("failed load file: "+ne)},q=MxApp3D.imp.addFunction(L,"vp"),J=MxApp3D.imp.addFunction(G,"vp");MxApp3D.imp.loadFileFromMemory(n,O,m,!0,q,J),MxApp3D.imp._free(O)},u.onerror=function(b){y(b)},u.readAsArrayBuffer(l)})}}]),t}(),Mx3dGeLine=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),n instanceof Mx3dGeAxis?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeLine(n.getImp()))):n instanceof Mx3dGePoint&&u instanceof Mx3dGeDir?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeLine(n.getImp(),u.getImp()))):c=e.call(this,n),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"SetDirection",value:function(u){this.imp.SetDirection(u.getImp())}},{key:"SetLocation",value:function(u){this.imp.SetLocation(u.getImp())}},{key:"SetPosition",value:function(u){this.imp.SetPosition(u.getImp())}},{key:"Position",value:function(){return new Mx3dGeAxis(this.imp.Position())}},{key:"Reverse",value:function(){this.imp.Reverse()}},{key:"Reversed",value:function(){return new l(this.imp.Reversed())}},{key:"ReversedParameter",value:function(u){return this.imp.ReversedParameter(u)}},{key:"FirstParameter",value:function(){return this.imp.FirstParameter()}},{key:"LastParameter",value:function(){return this.imp.LastParameter()}},{key:"IsClosed",value:function(){return this.imp.IsClosed()}},{key:"IsPeriodic",value:function(){return this.imp.IsPeriodic()}},{key:"Continuity",value:function(){return this.imp.Continuity()}},{key:"IsCN",value:function(u){return this.imp.IsCN(u)}},{key:"D0",value:function(u,c){this.imp.D0(u,c.getImp())}},{key:"D1",value:function(u,c,y){this.imp.D1(u,c.getImp(),y.getImp())}},{key:"D2",value:function(u,c,y,b){this.imp.D2(u,c.getImp(),y.getImp(),b.getImp())}},{key:"D3",value:function(u,c,y,b,m){this.imp.D3(u,c.getImp(),y.getImp(),b.getImp(),m.getImp())}},{key:"DN",value:function(u,c){return new Mx3dGeVec(this.imp.DN(u,c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"TransformedParameter",value:function(u,c){return this.imp.TransformedParameter(u,c.getImp())}},{key:"ParametricTransformation",value:function(u){return this.imp.ParametricTransformation(u.getImp())}},{key:"Period",value:function(){return this.imp.Period()}},{key:"Value",value:function(u){return new Mx3dGePoint(this.imp.Value(u))}},{key:"Edge",value:function(u,c){return new Mx3dShapeEdge(this.imp.Edge(u,c))}}]),l}(Mx3dGeCurve),Mx3dGeomObject=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"MirrorByPoint",value:function(u){this.imp.MirrorByPoint(u.getImp())}},{key:"MirrorByAxis",value:function(u){this.imp.MirrorByAxis(u.getImp())}},{key:"MirrorByCSYSR",value:function(u){this.imp.MirrorByCSYSR(u.getImp())}},{key:"Rotate",value:function(u,c){this.imp.Rotate(u.getImp(),c)}},{key:"Scale",value:function(u,c){this.imp.Scale(u.getImp(),c)}},{key:"TranslateByVec",value:function(u){this.imp.TranslateByVec(u.getImp())}},{key:"TranslateBy2Points",value:function(u,c){this.imp.TranslateBy2Points(u.getImp(),c.getImp())}},{key:"MirroredByPoint",value:function(u){return this.DynCast(new l(this.imp.MirroredByPoint(u.getImp())))}},{key:"MirroredByAxis",value:function(u){return this.DynCast(new l(this.imp.MirroredByAxis(u.getImp())))}},{key:"MirroredByCSYSR",value:function(u){return this.DynCast(new l(this.imp.MirroredByCSYSR(u.getImp())))}},{key:"Rotated",value:function(u,c){return this.DynCast(new l(this.imp.Rotated(u.getImp(),c)))}},{key:"Scaled",value:function(u,c){return this.DynCast(new l(this.imp.Scaled(u.getImp(),c)))}},{key:"Transformed",value:function(u){return this.DynCast(new l(this.imp.Transformed(u.getImp())))}},{key:"TranslatedByVec",value:function(u){return this.DynCast(new l(this.imp.TranslatedByVec(u.getImp())))}},{key:"TranslatedBy2Points",value:function(u,c){return this.DynCast(new l(this.imp.TranslatedBy2Points(u.getImp(),c.getImp())))}}]),l}(Mx3dBaseObject),Mx3dGeomCurve=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"Reversed",value:function(){return this.DynCast(new l(this.imp.Reversed()))}},{key:"Period",value:function(){return this.imp.Period()}},{key:"Value",value:function(u){return new Mx3dGePoint(u)}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}}]),l}(Mx3dGeomObject),Mx3dGeomConic=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"SetAxis",value:function(u){this.imp.SetAxis(u.getImp())}},{key:"SetLocation",value:function(u){this.imp.SetLocation(u.getImp())}},{key:"SetPosition",value:function(u){this.imp.SetPosition(u.getImp())}},{key:"Axis",value:function(){return new Mx3dGeAxis(this.imp.Axis())}},{key:"Location",value:function(){return new Mx3dGePoint(this.imp.Location())}},{key:"Position",value:function(){return new Mx3dGeCSYSR(this.imp.Position())}},{key:"XAxis",value:function(){return new Mx3dGeAxis(this.imp.XAxis())}},{key:"YAxis",value:function(){return new Mx3dGeAxis(this.imp.YAxis())}},{key:"Reverse",value:function(){this.imp.Reverse()}},{key:"Continuity",value:function(){return this.imp.Continuity()}},{key:"IsCN",value:function(u){return this.imp.IsCN(u)}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}}]),l}(Mx3dGeomCurve),Mx3dGeomCircle=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),n instanceof Mx3dGeCSYSR&&typeof u=="number"?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeomCircle(n.getImp(),u))):c=e.call(this,n),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"SetRadius",value:function(u){this.imp.SetRadius(u)}},{key:"Radius",value:function(){return this.imp.Radius()}},{key:"ReversedParameter",value:function(u){return this.imp.ReversedParameter(u)}},{key:"Eccentricity",value:function(){return this.imp.Eccentricity()}},{key:"FirstParameter",value:function(){return this.imp.FirstParameter()}},{key:"LastParameter",value:function(){return this.imp.LastParameter()}},{key:"IsClosed",value:function(){return this.imp.IsClosed()}},{key:"IsPeriodic",value:function(){return this.imp.IsPeriodic()}},{key:"D0",value:function(u,c){this.imp.D0(u,c.getImp())}},{key:"D1",value:function(u,c,y){this.imp.D1(u,c.getImp(),y.getImp())}},{key:"D2",value:function(u,c,y,b){this.imp.D2(u,c.getImp(),y.getImp(),b.getImp())}},{key:"D3",value:function(u,c,y,b,m){this.imp.D3(u,c.getImp(),y.getImp(),b.getImp(),m.getImp())}},{key:"DN",value:function(u,c){return new Mx3dGeVec(this.imp.DN(u,c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Copy",value:function(){return new Mx3dGeomObject(this.imp.Copy())}},{key:"Edge",value:function(u,c){return new Mx3dShapeEdge(this.imp.Edge(u,c))}},{key:"Wire",value:function(){return new Mx3dShapeWire(this.imp.Wire())}},{key:"OffsetCurve",value:function(u,c,y){return new Mx3dShapeEdge(this.imp.OffsetCurve(u,c.getImp(),y))}},{key:"DynCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToCircle(u.getImp()))}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}}],[{key:"MakeArcOfCircle",value:function(u,c,y){return u=uniToPoint(u),c=uniToPoint(c),y=uniToPoint(y),new Mx3dShapeEdge(MxApp3D.globalMethods.MakeArcOfCircle(u.getImp(),c.getImp(),y.getImp()))}},{key:"DownCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToCircle(u.getImp()))}}]),l}(Mx3dGeomConic),Mx3dGeomLine=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),n instanceof Mx3dGeAxis?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeomLine(n.getImp()))):n instanceof Mx3dGePoint&&u instanceof Mx3dGeDir?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeomLine(n.getImp(),u.getImp()))):c=e.call(this,n),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"SetDirection",value:function(u){this.imp.SetDirection(u.getImp())}},{key:"SetLocation",value:function(u){this.imp.SetLocation(u.getImp())}},{key:"SetPosition",value:function(u){this.imp.SetPosition(u.getImp())}},{key:"Position",value:function(){return new Mx3dGeAxis(this.imp.Position())}},{key:"Reverse",value:function(){this.imp.Reverse()}},{key:"ReversedParameter",value:function(u){return this.imp.ReversedParameter(u)}},{key:"FirstParameter",value:function(){return this.imp.FirstParameter()}},{key:"LastParameter",value:function(){return this.imp.LastParameter()}},{key:"IsClosed",value:function(){return this.imp.IsClosed()}},{key:"IsPeriodic",value:function(){return this.imp.IsPeriodic()}},{key:"Continuity",value:function(){return this.imp.Continuity()}},{key:"IsCN",value:function(u){return this.imp.IsCN(u)}},{key:"D0",value:function(u,c){this.imp.D0(u,c.getImp())}},{key:"D1",value:function(u,c,y){this.imp.D1(u,c.getImp(),y.getImp())}},{key:"D2",value:function(u,c,y,b){this.imp.D2(u,c.getImp(),y.getImp(),b.getImp())}},{key:"D3",value:function(u,c,y,b,m){this.imp.D3(u,c.getImp(),y.getImp(),b.getImp(),m.getImp())}},{key:"DN",value:function(u,c){return new Mx3dGeVec(this.imp.DN(u,c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"TransformedParameter",value:function(u,c){return this.imp.TransformedParameter(u,c.getImp())}},{key:"ParametricTransformation",value:function(u){return this.imp.ParametricTransformation(u.getImp())}},{key:"Copy",value:function(){return new Mx3dGeomObject(this.imp.Copy())}},{key:"Edge",value:function(u,c){return new Mx3dShapeEdge(this.imp.Edge(u,c))}},{key:"OffsetCurve",value:function(u,c,y){return new Mx3dShapeEdge(this.imp.OffsetCurve(u,c.getImp(),y))}},{key:"DynCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToLine(u.getImp()))}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}}],[{key:"DownCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToLine(u.getImp()))}}]),l}(Mx3dGeomCurve),Mx3dGeomEllipse=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),n instanceof Mx3dGeCSYSR&&typeof u=="number"&&typeof c=="number"?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeomEllipse(n.getImp(),u,c))):y=e.call(this,n),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"SetMajorRadius",value:function(u){this.imp.SetMajorRadius(u)}},{key:"SetMinorRadius",value:function(u){this.imp.SetMinorRadius(u)}},{key:"ReversedParameter",value:function(u){return this.imp.ReversedParameter(u)}},{key:"Directrix1",value:function(){return new Mx3dGeAxis(this.imp.Directrix1())}},{key:"Directrix2",value:function(){return new Mx3dGeAxis(this.imp.Directrix2())}},{key:"Eccentricity",value:function(){return this.imp.Eccentricity()}},{key:"Focal",value:function(){return this.imp.Focal()}},{key:"Focus1",value:function(){return new Mx3dGePoint(this.imp.Focus1())}},{key:"Focus2",value:function(){return new Mx3dGePoint(this.imp.Focus2())}},{key:"MajorRadius",value:function(){return this.imp.MajorRadius()}},{key:"MinorRadius",value:function(){return this.imp.MinorRadius()}},{key:"Parameter",value:function(){return this.imp.Parameter()}},{key:"FirstParameter",value:function(){return this.imp.FirstParameter()}},{key:"LastParameter",value:function(){return this.imp.LastParameter()}},{key:"IsClosed",value:function(){return this.imp.IsClosed()}},{key:"IsPeriodic",value:function(){return this.imp.IsPeriodic()}},{key:"D0",value:function(u,c){this.imp.D0(u,c.getImp())}},{key:"D1",value:function(u,c,y){this.imp.D1(u,c.getImp(),y.getImp())}},{key:"D2",value:function(u,c,y,b){this.imp.D2(u,c.getImp(),y.getImp(),b.getImp())}},{key:"D3",value:function(u,c,y,b,m){this.imp.D3(u,c.getImp(),y.getImp(),b.getImp(),m.getImp())}},{key:"DN",value:function(u,c){return new Mx3dGeVec(this.imp.DN(u,c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Copy",value:function(){return new Mx3dGeomObject(this.imp.Copy())}},{key:"Edge",value:function(u,c){return new Mx3dShapeEdge(this.imp.Edge(u,c))}},{key:"Wire",value:function(){return new Mx3dShapeWire(this.imp.Wire())}},{key:"OffsetCurve",value:function(u,c,y){return new Mx3dShapeEdge(this.imp.OffsetCurve(u,c.getImp(),y))}},{key:"DynCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToEllipse(u.getImp()))}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}}],[{key:"DownCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToEllipse(u.getImp()))}}]),l}(Mx3dGeomConic),Mx3dGeomHyperbola=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),n instanceof Mx3dGeCSYSR&&typeof u=="number"&&typeof c=="number"?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeomHyperbola(n.getImp(),u,c))):y=e.call(this,n),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"SetMajorRadius",value:function(u){this.imp.SetMajorRadius(u)}},{key:"SetMinorRadius",value:function(u){this.imp.SetMinorRadius(u)}},{key:"ReversedParameter",value:function(u){return this.imp.ReversedParameter(u)}},{key:"FirstParameter",value:function(){return this.imp.FirstParameter()}},{key:"LastParameter",value:function(){return this.imp.LastParameter()}},{key:"IsClosed",value:function(){return this.imp.IsClosed()}},{key:"IsPeriodic",value:function(){return this.imp.IsPeriodic()}},{key:"Asymptote1",value:function(){return new Mx3dGeAxis(this.imp.Asymptote1())}},{key:"Asymptote2",value:function(){return new Mx3dGeAxis(this.imp.Asymptote2())}},{key:"ConjugateBranch1",value:function(){return new l(this.imp.ConjugateBranch1())}},{key:"ConjugateBranch2",value:function(){return new l(this.imp.ConjugateBranch2())}},{key:"Directrix1",value:function(){return new Mx3dGeAxis(this.imp.Directrix1())}},{key:"Directrix2",value:function(){return new Mx3dGeAxis(this.imp.Directrix2())}},{key:"Eccentricity",value:function(){return this.imp.Eccentricity()}},{key:"Focal",value:function(){return this.imp.Focal()}},{key:"Focus1",value:function(){return new Mx3dGePoint(this.imp.Focus1())}},{key:"Focus2",value:function(){return new Mx3dGePoint(this.imp.Focus2())}},{key:"MajorRadius",value:function(){return this.imp.MajorRadius()}},{key:"MinorRadius",value:function(){return this.imp.MinorRadius()}},{key:"OtherBranch",value:function(){return new l(this.imp.OtherBranch())}},{key:"Parameter",value:function(){return this.imp.Parameter()}},{key:"D0",value:function(u,c){this.imp.D0(u,c.getImp())}},{key:"D1",value:function(u,c,y){this.imp.D1(u,c.getImp(),y.getImp())}},{key:"D2",value:function(u,c,y,b){this.imp.D2(u,c.getImp(),y.getImp(),b.getImp())}},{key:"D3",value:function(u,c,y,b,m){this.imp.D3(u,c.getImp(),y.getImp(),b.getImp(),m.getImp())}},{key:"DN",value:function(u,c){return new Mx3dGeVec(this.imp.DN(u,c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Copy",value:function(){return new Mx3dGeomObject(this.imp.Copy())}},{key:"Edge",value:function(u,c){return new Mx3dShapeEdge(this.imp.Edge(u,c))}},{key:"OffsetCurve",value:function(u,c,y){return new Mx3dShapeEdge(this.imp.OffsetCurve(u,c.getImp(),y))}},{key:"DynCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToHyperbola(u.getImp()))}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}}],[{key:"DownCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToHyperbola(u.getImp()))}}]),l}(Mx3dGeomConic),Mx3dGeomParabola=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),n instanceof Mx3dGeCSYSR&&typeof u=="number"?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeomParabola(n.getImp(),u))):c=e.call(this,n),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"SetFocal",value:function(u){this.imp.SetFocal(u)}},{key:"ReversedParameter",value:function(u){return this.imp.ReversedParameter(u)}},{key:"FirstParameter",value:function(){return this.imp.FirstParameter()}},{key:"LastParameter",value:function(){return this.imp.LastParameter()}},{key:"IsClosed",value:function(){return this.imp.IsClosed()}},{key:"IsPeriodic",value:function(){return this.imp.IsPeriodic()}},{key:"Directrix",value:function(){return new Mx3dGeAxis(this.imp.Directrix())}},{key:"Eccentricity",value:function(){return this.imp.Eccentricity()}},{key:"Focus",value:function(){return new Mx3dGePoint(this.imp.Focus())}},{key:"Focal",value:function(){return this.imp.Focal()}},{key:"Parameter",value:function(){return this.imp.Parameter()}},{key:"D0",value:function(u,c){this.imp.D0(u,c.getImp())}},{key:"D1",value:function(u,c,y){this.imp.D1(u,c.getImp(),y.getImp())}},{key:"D2",value:function(u,c,y,b){this.imp.D2(u,c.getImp(),y.getImp(),b.getImp())}},{key:"D3",value:function(u,c,y,b,m){this.imp.D3(u,c.getImp(),y.getImp(),b.getImp(),m.getImp())}},{key:"DN",value:function(u,c){return new Mx3dGeVec(this.imp.DN(u,c))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"TransformedParameter",value:function(u,c){return this.imp.TransformedParameter(u,c.getImp())}},{key:"ParametricTransformation",value:function(u){return this.imp.ParametricTransformation(u.getImp())}},{key:"Copy",value:function(){return new Mx3dGeomObject(this.imp.Copy())}},{key:"Edge",value:function(u,c){return new Mx3dShapeEdge(this.imp.Edge(u,c))}},{key:"OffsetCurve",value:function(u,c,y){return new Mx3dShapeEdge(this.imp.OffsetCurve(u,c.getImp(),y))}},{key:"DynCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToParabola(u.getImp()))}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}}],[{key:"DownCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToParabola(u.getImp()))}}]),l}(Mx3dGeomConic),Mx3dMkObject=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l)}(Mx3dBaseObject),Mx3dMkBox=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y){var b;if(_classCallCheck$1(this,l),isUniPoint(n)&&isUniPoint(u)){b=e.call(this);var m=uniToPoint(n),O=uniToPoint(u);b.initTempObject(new MxApp3D.imp.Mx3dMkBox(m.getImp(),O.getImp()))}else typeof n=="number"&&typeof u=="number"&&typeof c=="number"?(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dMkBox(n,u,c))):n instanceof Mx3dGeCSYSR&&typeof u=="number"&&typeof c=="number"&&typeof y=="number"?(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dMkBox(n.getImp(),u,c,y))):n instanceof Object&&(b=e.call(this,n));return _possibleConstructorReturn$1(b)}return _createClass$1(l,[{key:"Build",value:function(){this.imp.Build()}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"Shell",value:function(){return new Mx3dShapeShell(this.imp.Shell())}},{key:"Solid",value:function(){return new Mx3dShapeSolid(this.imp.Solid())}},{key:"BottomFace",value:function(){return new Mx3dShapeFace(this.imp.BottomFace())}},{key:"BackFace",value:function(){return new Mx3dShapeFace(this.imp.BackFace())}},{key:"FrontFace",value:function(){return new Mx3dShapeFace(this.imp.FrontFace())}},{key:"LeftFace",value:function(){return new Mx3dShapeFace(this.imp.LeftFace())}},{key:"RightFace",value:function(){return new Mx3dShapeFace(this.imp.RightFace())}},{key:"TopFace",value:function(){return new Mx3dShapeFace(this.imp.TopFace())}},{key:"IsDone",value:function(){return this.imp.IsDone()}}]),l}(Mx3dMkObject),Mx3dMkCone=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y,b){var m;return _classCallCheck$1(this,l),n instanceof Mx3dGeCSYSR&&!b?(m=e.call(this),m.initTempObject(new MxApp3D.imp.Mx3dMkCone(n.getImp(),u,c,y))):n instanceof Mx3dGeCSYSR&&b?(m=e.call(this),m.initTempObject(new MxApp3D.imp.Mx3dMkCone(n.getImp(),u,c,y,b))):n instanceof Object&&(m=e.call(this,n)),_possibleConstructorReturn$1(m)}return _createClass$1(l,[{key:"Build",value:function(){this.imp.Build()}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"Face",value:function(){return new Mx3dShapeFace(this.imp.Face())}},{key:"Shell",value:function(){return new Mx3dShapeShell(this.imp.Shell())}},{key:"Solid",value:function(){return new Mx3dShapeSolid(this.imp.Solid())}},{key:"IsDone",value:function(){return this.imp.IsDone()}}]),l}(Mx3dMkObject),Mx3dMkCylinder=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y){var b;return _classCallCheck$1(this,l),n instanceof Mx3dGeCSYSR&&!y?(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dMkCylinder(n.getImp(),u,c))):n instanceof Mx3dGeCSYSR&&y?(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dMkCylinder(n.getImp(),u,c,y))):n instanceof Object&&(b=e.call(this,n)),_possibleConstructorReturn$1(b)}return _createClass$1(l,[{key:"Build",value:function(){this.imp.Build()}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"Face",value:function(){return new Mx3dShapeFace(this.imp.Face())}},{key:"Shell",value:function(){return new Mx3dShapeShell(this.imp.Shell())}},{key:"Solid",value:function(){return new Mx3dShapeSolid(this.imp.Solid())}},{key:"IsDone",value:function(){return this.imp.IsDone()}}]),l}(Mx3dMkObject),Mx3dMkRevol=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),n instanceof Mx3dShapeObject&&!c?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dMkRevol(n.getImp(),u.getImp()))):n instanceof Mx3dShapeObject&&c?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dMkRevol(n.getImp(),u.getImp(),c))):n instanceof Object&&(y=e.call(this,n)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"Build",value:function(){this.imp.Build()}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"IsDone",value:function(){return this.imp.IsDone()}}]),l}(Mx3dMkObject),Mx3dMkSphere=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y,b){var m;return _classCallCheck$1(this,l),n instanceof Mx3dGeCSYSR&&arguments.length===2?(m=e.call(this),m.initTempObject(new MxApp3D.imp.Mx3dMkSphere(n.getImp(),u))):n instanceof Mx3dGeCSYSR&&arguments.length===3?(m=e.call(this),m.initTempObject(new MxApp3D.imp.Mx3dMkSphere(n.getImp(),u,c))):n instanceof Mx3dGeCSYSR&&arguments.length===4?(m=e.call(this),m.initTempObject(new MxApp3D.imp.Mx3dMkSphere(n.getImp(),u,c,y))):n instanceof Mx3dGeCSYSR&&arguments.length===5?(m=e.call(this),m.initTempObject(new MxApp3D.imp.Mx3dMkSphere(n.getImp(),u,c,y,b))):n instanceof Object&&(m=e.call(this,n)),_possibleConstructorReturn$1(m)}return _createClass$1(l,[{key:"Build",value:function(){this.imp.Build()}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"Face",value:function(){return new Mx3dShapeFace(this.imp.Face())}},{key:"Shell",value:function(){return new Mx3dShapeShell(this.imp.Shell())}},{key:"Solid",value:function(){return new Mx3dShapeSolid(this.imp.Solid())}},{key:"IsDone",value:function(){return this.imp.IsDone()}}]),l}(Mx3dMkObject),Mx3dMkTorus=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y,b,m){var O;return _classCallCheck$1(this,l),n instanceof Mx3dGeCSYSR&&arguments.length===3?(O=e.call(this),O.initTempObject(new MxApp3D.imp.Mx3dMkTorus(n.getImp(),u,c))):n instanceof Mx3dGeCSYSR&&arguments.length===4?(O=e.call(this),O.initTempObject(new MxApp3D.imp.Mx3dMkTorus(n.getImp(),u,c,y))):n instanceof Mx3dGeCSYSR&&arguments.length===5?(O=e.call(this),O.initTempObject(new MxApp3D.imp.Mx3dMkTorus(n.getImp(),u,c,y,b))):n instanceof Mx3dGeCSYSR&&arguments.length===6?(O=e.call(this),O.initTempObject(new MxApp3D.imp.Mx3dMkTorus(n.getImp(),u,c,y,b,m))):n instanceof Object&&(O=e.call(this,n)),_possibleConstructorReturn$1(O)}return _createClass$1(l,[{key:"Build",value:function(){this.imp.Build()}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"Face",value:function(){return new Mx3dShapeFace(this.imp.Face())}},{key:"Shell",value:function(){return new Mx3dShapeShell(this.imp.Shell())}},{key:"Solid",value:function(){return new Mx3dShapeSolid(this.imp.Solid())}},{key:"IsDone",value:function(){return this.imp.IsDone()}}]),l}(Mx3dMkObject),Mx3dMkPipe=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y){var b;return _classCallCheck$1(this,l),n instanceof Mx3dShapeWire&&u instanceof Mx3dShapeObject&&typeof c=="number"&&typeof y=="boolean"?(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dMkPipe(n.getImp(),u.getImp(),c,y))):n instanceof Mx3dShapeWire&&u instanceof Mx3dShapeObject?(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dMkPipe(n.getImp(),u.getImp()))):n instanceof Object&&(b=e.call(this,n)),_possibleConstructorReturn$1(b)}return _createClass$1(l,[{key:"Build",value:function(){this.imp.Build()}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"IsDone",value:function(){return this.imp.IsDone()}}]),l}(Mx3dMkObject),Mx3dMkPrism=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),n instanceof Mx3dShapeObject&&u instanceof Mx3dGeVec?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dMkPrism(n.getImp(),u.getImp(),!1,!0))):n instanceof Mx3dShapeObject&&u instanceof Mx3dGeDir?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dMkPrism(n.getImp(),u.getImp(),!0,!1,!0))):n instanceof Object&&(c=e.call(this,n)),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"Build",value:function(){this.imp.Build()}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"IsDone",value:function(){return this.imp.IsDone()}}]),l}(Mx3dMkObject),Mx3dMkWedge=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y,b,m,O,N){var L;return _classCallCheck$1(this,l),typeof n=="number"&&arguments.length===4?(L=e.call(this),L.initTempObject(new MxApp3D.imp.Mx3dMkWedge(n,u,c,y))):n instanceof Mx3dGeCSYSR&&arguments.length===5?(L=e.call(this),L.initTempObject(new MxApp3D.imp.Mx3dMkWedge(n.getImp(),u,c,y,b))):typeof n=="number"&&arguments.length===7?(L=e.call(this),L.initTempObject(new MxApp3D.imp.Mx3dMkWedge(n,u,c,y,b,m,O))):n instanceof Mx3dGeCSYSR&&arguments.length===8?(L=e.call(this),L.initTempObject(new MxApp3D.imp.Mx3dMkWedge(n.getImp(),u,c,y,b,m,O,N))):n instanceof Object&&(L=e.call(this,n)),_possibleConstructorReturn$1(L)}return _createClass$1(l,[{key:"Build",value:function(){this.imp.Build()}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"Shell",value:function(){return new Mx3dShapeShell(this.imp.Shell())}},{key:"Solid",value:function(){return new Mx3dShapeSolid(this.imp.Solid())}},{key:"IsDone",value:function(){return this.imp.IsDone()}}]),l}(Mx3dMkObject),Mx3dMkLoft=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),arguments.length===0?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dMkLoft)):typeof n=="boolean"&&arguments.length===1?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dMkLoft(n))):typeof n=="boolean"&&typeof u=="boolean"&&arguments.length===2?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dMkLoft(n,u))):typeof n=="boolean"&&typeof u=="boolean"&&typeof c=="number"?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dMkLoft(n,u,c))):n instanceof Object&&(y=e.call(this,n)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"AddWire",value:function(u){this.imp.AddWire(u.getImp())}},{key:"AddVertex",value:function(u){this.imp.AddVertex(u.getImp())}},{key:"SetSmoothing",value:function(u){this.imp.SetSmoothing(u)}},{key:"SetContinuity",value:function(u){this.imp.SetContinuity(u)}},{key:"Continuity",value:function(){return this.imp.Continuity()}},{key:"UseSmoothing",value:function(){return this.imp.UseSmoothing()}},{key:"Build",value:function(){return this.imp.Build()}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"IsDone",value:function(){return this.imp.IsDone()}}]),l}(Mx3dMkObject),Mx3dMkPolygon=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dMkPolygon)),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"Add",value:function(u){this.imp.Add(u.getImp())}},{key:"Added",value:function(){return this.imp.Added()}},{key:"Close",value:function(){this.imp.Close()}},{key:"FirstVertex",value:function(){return new Mx3dShapeVertex(this.imp.FirstVertex())}},{key:"LastVertex",value:function(){return new Mx3dShapeVertex(this.imp.LastVertex())}},{key:"Build",value:function(){this.imp.Build()}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"IsDone",value:function(){return this.imp.IsDone()}},{key:"Edge",value:function(){return new Mx3dShapeEdge(this.imp.Edge())}},{key:"Wire",value:function(){return new Mx3dShapeWire(this.imp.Wire())}}]),l}(Mx3dMkObject),Mx3dMkFace=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u,c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return _classCallCheck$1(this,l),n instanceof Mx3dShapeWire?(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dMkFace(n.getImp(),c))):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dMkFace(n.getImp()))),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"Build",value:function(){this.imp.Build()}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"Face",value:function(){return new Mx3dShapeFace(this.imp.Face())}},{key:"IsDone",value:function(){return this.imp.IsDone()}},{key:"Add",value:function(u){this.imp.Add(u.getImp())}}]),l}(Mx3dMkObject),Mx3dMkThickSolid=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(){var n;return _classCallCheck$1(this,l),n=e.call(this),n.initTempObject(new MxApp3D.imp.Mx3dMkThickSolid),n}return _createClass$1(l,[{key:"MakeThickSolidBySimple",value:function(u,c){this.imp.MakeThickSolidBySimple(u.getImp(),c)}},{key:"MakeThickSolidByJoin",value:function(u,c,y,b){var m=arguments.length>4&&arguments[4]!==void 0?arguments[4]:MdGe.MxOffsetModeEnum.Offset_Skin,O=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!1,N=arguments.length>6&&arguments[6]!==void 0?arguments[6]:!1,L=arguments.length>7&&arguments[7]!==void 0?arguments[7]:MdGe.MxGAJoinTypeEnum.GA_Arc,G=arguments.length>8&&arguments[8]!==void 0?arguments[8]:!1,q=arrShapeToShapeSequence(c);this.imp.MakeThickSolidByJoin(u.getImp(),q.getImp(),y,b,m,O,N,L,G)}},{key:"Build",value:function(){this.imp.Build()}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"IsDone",value:function(){return this.imp.IsDone()}}]),l}(Mx3dMkObject),Mx3dWireTool=function(){function t(){_classCallCheck$1(this,t)}return _createClass$1(t,null,[{key:"ConnectEdgesToWires",value:function(l){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1e-6,u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,c=new Mx3dShapeObjectSequence;l.forEach(function(O){return c.Append(O)});for(var y=new Mx3dShapeObjectSequence(MxApp3D.globalMethods.ConnectEdgesToWires(c.getImp(),n,u)),b=new Array,m=1;m<=y.Length();m++)b.push(y.Value(m));return b}},{key:"ConnectWiresToWires",value:function(l){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1e-6,u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,c=new Mx3dShapeObjectSequence;l.forEach(function(O){return c.Append(O)});for(var y=new Mx3dShapeObjectSequence(MxApp3D.globalMethods.ConnectWiresToWires(c.getImp(),n,u)),b=new Array,m=1;m<=y.Length();m++)b.push(y.Value(m));return b}},{key:"EdgeToWire",value:function(l){return new Mx3dShapeWire(MxApp3D.globalMethods.EdgeToWire(l.getImp()))}}]),t}(),MxNewMdGeArray1OfReal=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),arguments.length==0?(c=e.call(this),c.initTempObject(new MxApp3D.imp.MdGeArray1OfReal)):typeof n=="number"&&arguments.length==2?(c=e.call(this),c.initTempObject(new MxApp3D.imp.MdGeArray1OfReal(n,u))):n instanceof Object&&arguments.length==1&&(c=e.call(this,n)),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"Init",value:function(u){this.imp.Init(u)}},{key:"Size",value:function(){return this.imp.Size()}},{key:"Length",value:function(){return this.imp.Length()}},{key:"IsEmpty",value:function(){return this.imp.IsEmpty()}},{key:"Lower",value:function(){return this.imp.Lower()}},{key:"Upper",value:function(){return this.imp.Upper()}},{key:"IsDeletable",value:function(){return this.imp.IsDeletable()}},{key:"IsAllocated",value:function(){return this.imp.IsAllocated()}},{key:"First",value:function(){return this.imp.First()}},{key:"Last",value:function(){return this.imp.Last()}},{key:"Value",value:function(u){return this.imp.Value(u)}},{key:"SetValue",value:function(u,c){this.imp.SetValue(u,c)}},{key:"Resize",value:function(u,c,y){this.imp.Resize(u,c,y)}}]),l}(Mx3dBaseObject),MxNewMdGeArray1OfPnt=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),arguments.length==0?(c=e.call(this),c.initTempObject(new MxApp3D.imp.MdGeArray1OfPnt)):typeof n=="number"&&arguments.length==2?(c=e.call(this),c.initTempObject(new MxApp3D.imp.MdGeArray1OfPnt(n,u))):n instanceof Object&&arguments.length==1&&(c=e.call(this,n)),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"Init",value:function(u){this.imp.Init(u.getImp())}},{key:"Size",value:function(){return this.imp.Size()}},{key:"Length",value:function(){return this.imp.Length()}},{key:"IsEmpty",value:function(){return this.imp.IsEmpty()}},{key:"Lower",value:function(){return this.imp.Lower()}},{key:"Upper",value:function(){return this.imp.Upper()}},{key:"IsDeletable",value:function(){return this.imp.IsDeletable()}},{key:"IsAllocated",value:function(){return this.imp.IsAllocated()}},{key:"First",value:function(){return new Mx3dGePoint(this.imp.First())}},{key:"Last",value:function(){return new Mx3dGePoint(this.imp.Last())}},{key:"Value",value:function(u){return new Mx3dGePoint(this.imp.Value(u))}},{key:"SetValue",value:function(u,c){this.imp.SetValue(u,c.getImp())}},{key:"Resize",value:function(u,c,y){this.imp.Resize(u,c,y)}}]),l}(Mx3dBaseObject),MxNewMdGeArray2OfPnt=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y,b){var m;return _classCallCheck$1(this,l),arguments.length==0?(m=e.call(this),m.initTempObject(new MxApp3D.imp.MdGeArray2OfPnt)):typeof n=="number"&&arguments.length==4?(m=e.call(this),m.initTempObject(new MxApp3D.imp.MdGeArray2OfPnt(n,u,c,y))):n instanceof Mx3dGePoint&&arguments.length==5?(m=e.call(this),m.initTempObject(new MxApp3D.imp.MdGeArray2OfPnt(n.getImp(),u,c,y,b))):n instanceof Object&&arguments.length==1&&(m=e.call(this,n)),_possibleConstructorReturn$1(m)}return _createClass$1(l,[{key:"Init",value:function(u){this.imp.Init(u.getImp())}},{key:"Size",value:function(){return this.imp.Size()}},{key:"Length",value:function(){return this.imp.Length()}},{key:"NbRows",value:function(){return this.imp.NbRows()}},{key:"NbColumns",value:function(){return this.imp.NbColumns()}},{key:"RowLength",value:function(){return this.imp.RowLength()}},{key:"ColLength",value:function(){return this.imp.ColLength()}},{key:"LowerRow",value:function(){return this.imp.LowerRow()}},{key:"UpperRow",value:function(){return this.imp.UpperRow()}},{key:"LowerCol",value:function(){return this.imp.LowerCol()}},{key:"UpperCol",value:function(){return this.imp.UpperCol()}},{key:"IsDeletable",value:function(){return this.imp.IsDeletable()}},{key:"Value",value:function(u,c){return new Mx3dGePoint(this.imp.Value(u,c))}},{key:"SetValue",value:function(u,c,y){this.imp.SetValue(u,c,y.getImp())}},{key:"Resize",value:function(u,c,y,b,m){this.imp.Resize(u,c,y,b,m)}}]),l}(Mx3dBaseObject),MxNewMdGeArray2OfReal=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y,b){var m;return _classCallCheck$1(this,l),arguments.length==0?(m=e.call(this),m.initTempObject(new MxApp3D.imp.MdGeArray2OfReal)):typeof n=="number"&&arguments.length==4?(m=e.call(this),m.initTempObject(new MxApp3D.imp.MdGeArray2OfReal(n,u,c,y))):typeof n=="number"&&arguments.length==5?(m=e.call(this),m.initTempObject(new MxApp3D.imp.MdGeArray2OfReal(n,u,c,y,b))):n instanceof Object&&arguments.length==1&&(m=e.call(this,n)),_possibleConstructorReturn$1(m)}return _createClass$1(l,[{key:"Init",value:function(u){this.imp.Init(u)}},{key:"Size",value:function(){return this.imp.Size()}},{key:"Length",value:function(){return this.imp.Length()}},{key:"NbRows",value:function(){return this.imp.NbRows()}},{key:"NbColumns",value:function(){return this.imp.NbColumns()}},{key:"RowLength",value:function(){return this.imp.RowLength()}},{key:"ColLength",value:function(){return this.imp.ColLength()}},{key:"LowerRow",value:function(){return this.imp.LowerRow()}},{key:"UpperRow",value:function(){return this.imp.UpperRow()}},{key:"LowerCol",value:function(){return this.imp.LowerCol()}},{key:"UpperCol",value:function(){return this.imp.UpperCol()}},{key:"IsDeletable",value:function(){return this.imp.IsDeletable()}},{key:"Value",value:function(u,c){return this.imp.Value(u,c)}},{key:"SetValue",value:function(u,c,y){this.imp.SetValue(u,c,y)}},{key:"Resize",value:function(u,c,y,b,m){this.imp.Resize(u,c,y,b,m)}}]),l}(Mx3dBaseObject),Mx3dGeomBoundedCurve=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"DynamicType",value:function(){return this.imp.DynamicType()}}]),l}(Mx3dGeomCurve),Mx3dGeomBSplineCurve=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y,b){var m;if(_classCallCheck$1(this,l),n[0]instanceof Mx3dGePoint&&typeof u[0]=="number"&&typeof c[0]=="number"&&typeof y=="number"){m=e.call(this);for(var O=new MxNewMdGeArray1OfPnt(0,n.length-1),N=0;N<n.length;N++)O.SetValue(N,n[N]);for(var L=new MxNewMdGeArray1OfReal(0,u.length-1),G=0;G<u.length;G++)L.SetValue(G,u[G]);for(var q=new MxNewMdGeArray1OfInteger(0,c.length-1),J=0;J<c.length;J++)q.SetValue(J,c[J]);m.initTempObject(new MxApp3D.imp.Mx3dGeomBSplineCurve(O.getImp(),L.getImp(),q.getImp(),y))}else if(n[0]instanceof Mx3dGePoint&&typeof u[0]=="number"&&typeof c[0]=="number"&&y instanceof Array&&typeof y[0]=="number"&&typeof b=="number"){m=e.call(this);for(var fe=new MxNewMdGeArray1OfPnt(0,n.length-1),ve=0;ve<n.length;ve++)fe.SetValue(ve,n[ve]);for(var ne=new MxNewMdGeArray1OfReal(0,u.length-1),Ue=0;Ue<u.length;Ue++)ne.SetValue(Ue,u[Ue]);for(var De=new MxNewMdGeArray1OfReal(0,c.length-1),Ve=0;Ve<c.length;Ve++)De.SetValue(Ve,c[Ve]);for(var rt=new MxNewMdGeArray1OfInteger(0,y.length-1),Ae=0;Ae<y.length;Ae++)rt.SetValue(Ae,y[Ae]);m.initTempObject(new MxApp3D.imp.Mx3dGeomBSplineCurve(fe.getImp(),ne.getImp(),De.getImp(),rt.getImp(),b))}else n instanceof Object&&(m=e.call(this,n));return _possibleConstructorReturn$1(m)}return _createClass$1(l,[{key:"IncreaseDegree",value:function(u){this.imp.IncreaseDegree(u)}},{key:"IncreaseMultiplicity",value:function(u,c,y){y?this.imp.IncreaseMultiplicity(u,c,y):this.imp.IncreaseMultiplicity(u,c)}},{key:"IncrementMultiplicity",value:function(u,c,y){this.imp.IncrementMultiplicity(u,c,y)}},{key:"InsertKnot",value:function(u,c,y,b){!c&&!y&&!b?this.imp.InsertKnot(u):c&&!y&&!b?this.imp.InsertKnot(u,c):c&&y&&!b?this.imp.InsertKnot(u,c,y):c&&y&&b&&this.imp.InsertKnot(u,c,y,b)}},{key:"InsertKnots",value:function(u,c,y,b){for(var m=new MxNewMdGeArray1OfReal(0,u.length-1),O=0;O<u.length;O++)m.SetValue(O,u[O]);for(var N=new MxNewMdGeArray1OfInteger(0,c.length-1),L=0;L<c.length;L++)N.SetValue(L,c[L]);!y&&!b?this.imp.InsertKnots(m.getImp(),N.getImp()):y&&!b?this.imp.InsertKnots(m.getImp(),N.getImp(),y):y&&b&&this.imp.InsertKnots(m.getImp(),N.getImp(),y,b)}},{key:"RemoveKnot",value:function(u,c,y){return this.imp.RemoveKnot(u,c,y)}},{key:"Reverse",value:function(){this.imp.Reverse()}},{key:"ReversedParameter",value:function(u){return this.imp.ReversedParameter(u)}},{key:"Segment",value:function(u,c){this.imp.Segment(u,c)}},{key:"SetKnot",value:function(u,c,y){y?this.imp.SetKnot(u,c,y):this.imp.SetKnot(u,c)}},{key:"SetKnots",value:function(u){for(var c=new MxNewMdGeArray1OfReal(0,u.length),y=0;y<u.length;y++)c.SetValue(y,u[y]);this.imp.SetKnots(c.getImp())}},{key:"SetPeriodic",value:function(){this.imp.SetPeriodic()}},{key:"SetOrigin",value:function(u,c){c?this.imp.SetOrigin(u,c):this.imp.SetOrigin(u)}},{key:"SetNotPeriodic",value:function(){this.imp.SetNotPeriodic()}},{key:"SetPole",value:function(u,c,y){c=uniToPoint(c),y?this.imp.SetPole(u,c.getImp(),y):this.imp.SetPole(u,c.getImp())}},{key:"SetWeight",value:function(u,c){this.imp.SetWeight(u,c)}},{key:"IsCN",value:function(u){return this.imp.IsCN(u)}},{key:"IsG1",value:function(u,c,y){return this.imp.IsG1(u,c,y)}},{key:"IsClosed",value:function(){return this.imp.IsClosed()}},{key:"IsPeriodic",value:function(){return this.imp.IsPeriodic()}},{key:"IsRational",value:function(){return this.imp.IsRational()}},{key:"Continuity",value:function(){return this.imp.Continuity()}},{key:"Degree",value:function(){return this.imp.Degree()}},{key:"D0",value:function(u,c){this.imp.D0(u,c.getImp())}},{key:"D1",value:function(u,c,y){this.imp.D1(u,c.getImp(),y.getImp())}},{key:"D2",value:function(u,c,y,b){this.imp.D2(u,c.getImp(),y.getImp(),b.getImp())}},{key:"D3",value:function(u,c,y,b,m){this.imp.D3(u,c.getImp(),y.getImp(),b.getImp(),m.getImp())}},{key:"DN",value:function(u,c){return new Mx3dGeVec(this.imp.DN(u,c))}},{key:"LocalValue",value:function(u,c,y){return new Mx3dGePoint(this.imp.LocalValue(u,c,y))}},{key:"LocalD0",value:function(u,c,y,b){this.imp.LocalD0(u,c,y,b.getImp())}},{key:"LocalD1",value:function(u,c,y,b,m){this.imp.LocalD1(u,c,y,b.getImp(),m.getImp())}},{key:"LocalD2",value:function(u,c,y,b,m,O){this.imp.LocalD2(u,c,y,b.getImp(),m.getImp(),O.getImp())}},{key:"LocalD3",value:function(u,c,y,b,m,O,N){this.imp.LocalD3(u,c,y,b.getImp(),m.getImp(),O.getImp(),N.getImp())}},{key:"LocalDN",value:function(u,c,y,b){return new Mx3dGeVec(this.imp.LocalDN(u,c,y,b))}},{key:"EndPoint",value:function(){return new Mx3dGePoint(this.imp.EndPoint())}},{key:"FirstUKnotIndex",value:function(){return this.imp.FirstUKnotIndex()}},{key:"FirstParameter",value:function(){return this.imp.FirstParameter()}},{key:"Knot",value:function(u){return this.imp.Knot(u)}},{key:"Knots",value:function(){for(var u=this.imp.Knots(),c=new Array,y=1;y<=u.Length();y++)c.push(u.Value(y));return c}},{key:"LastUKnotIndex",value:function(){return this.imp.LastUKnotIndex()}},{key:"LastParameter",value:function(){return this.imp.LastParameter()}},{key:"Multiplicity",value:function(u){return this.imp.Multiplicity(u)}},{key:"Multiplicities",value:function(){for(var u=this.imp.Multiplicities(),c=new Array,y=1;y<=u.Length();y++)c.push(u.Value(y));return c}},{key:"NbKnots",value:function(){return this.imp.NbKnots()}},{key:"NbPoles",value:function(){return this.imp.NbPoles()}},{key:"Pole",value:function(u){return new Mx3dGePoint(this.imp.Pole(u))}},{key:"Poles",value:function(){for(var u=this.imp.Poles(),c=new Array,y=1;y<=u.Length();y++)c.push(new Mx3dGePoint(u.Value(y)));return c}},{key:"StartPoint",value:function(){return new Mx3dGePoint(this.imp.StartPoint())}},{key:"Weight",value:function(u){return this.imp.Weight(u)}},{key:"Weights",value:function(){for(var u=this.imp.Weights(),c=new Array,y=1;y<=u.Length();y++)c.push(u.Value(y));return c}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Copy",value:function(){return new Mx3dGeomObject(this.imp.Copy())}},{key:"Edge",value:function(u,c){return new Mx3dShapeEdge(this.imp.Edge(u,c))}},{key:"Wire",value:function(){return new Mx3dShapeWire(this.imp.Wire())}},{key:"OffsetCurve",value:function(u,c,y){return c=uniToDir(c),new Mx3dShapeEdge(this.imp.OffsetCurve(u,c.getImp(),y))}},{key:"IsEqual",value:function(u,c){return this.imp.IsEqual(u.getImp(),c)}},{key:"DynCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToBSplineCurve(u.getImp()))}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}}],[{key:"DownCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToBSplineCurve(u.getImp()))}}]),l}(Mx3dGeomBoundedCurve);function getPointArrObject(t){for(var e=new MxNewMdGeArray1OfPnt(0,t.length-1),l=0;l<t.length;l++)e.SetValue(l,t[l]);return e}function getRealArrObject(t){for(var e=new MxNewMdGeArray1OfReal(0,t.length-1),l=0;l<t.length;l++)e.SetValue(l,t[l]);return e}var Mx3dGeomBezierCurve=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;if(_classCallCheck$1(this,l),n[0]instanceof Mx3dGePoint&&!u){c=e.call(this);var y=getPointArrObject(n);c.initTempObject(new MxApp3D.imp.Mx3dGeomBezierCurve(y.getImp()))}else if(n[0]instanceof Mx3dGePoint&&u instanceof Array&&typeof u[0]=="number"){c=e.call(this);var b=getPointArrObject(n),m=getRealArrObject(u);c.initTempObject(new MxApp3D.imp.Mx3dGeomBezierCurve(b.getImp(),m.getImp()))}else n instanceof Object&&(c=e.call(this,n));return _possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"Increase",value:function(u){this.imp.Increase(u)}},{key:"InsertPoleAfter",value:function(u,c,y){y?this.imp.InsertPoleAfter(u,c.getImp(),y):this.imp.InsertPoleAfter(u,c.getImp())}},{key:"InsertPoleBefore",value:function(u,c,y){y?this.imp.InsertPoleBefore(u,c.getImp(),y):this.imp.InsertPoleBefore(u,c.getImp())}},{key:"RemovePole",value:function(u){this.imp.RemovePole(u)}},{key:"Reverse",value:function(){this.imp.Reverse()}},{key:"ReversedParameter",value:function(u){return this.imp.ReversedParameter(u)}},{key:"Segment",value:function(u,c){this.imp.Segment(u,c)}},{key:"SetPole",value:function(u,c,y){y?this.imp.SetPole(u,c.getImp(),y):this.imp.SetPole(u,c.getImp())}},{key:"SetWeight",value:function(u,c){this.imp.SetWeight(u,c)}},{key:"IsClosed",value:function(){return this.imp.IsClosed()}},{key:"IsCN",value:function(u){return this.imp.IsCN(u)}},{key:"IsPeriodic",value:function(){return this.imp.IsPeriodic()}},{key:"IsRational",value:function(){return this.imp.IsRational()}},{key:"Continuity",value:function(){return this.imp.Continuity()}},{key:"Degree",value:function(){return this.imp.Degree()}},{key:"D0",value:function(u,c){this.imp.D0(u,c.getImp())}},{key:"D1",value:function(u,c,y){this.imp.D1(u,c.getImp(),y.getImp())}},{key:"D2",value:function(u,c,y,b){this.imp.D2(u,c.getImp(),y.getImp(),b.getImp())}},{key:"D3",value:function(u,c,y,b,m){this.imp.D3(u,c.getImp(),y.getImp(),b.getImp(),m.getImp())}},{key:"DN",value:function(u,c){return new Mx3dGeVec(this.imp.DN(u,c))}},{key:"StartPoint",value:function(){return new Mx3dGePoint(this.imp.StartPoint())}},{key:"EndPoint",value:function(){return new Mx3dGePoint(this.imp.EndPoint())}},{key:"FirstParameter",value:function(){return this.imp.FirstParameter()}},{key:"LastParameter",value:function(){return this.imp.LastParameter()}},{key:"NbPoles",value:function(){return this.imp.NbPoles()}},{key:"Pole",value:function(u){return new Mx3dGePoint(this.imp.Pole(u))}},{key:"Poles",value:function(){for(var u=this.imp.Poles(),c=new Array,y=1;y<=u.Length();y++)c.push(u.Value(y));return c}},{key:"Weight",value:function(u){return this.imp.Weight(u)}},{key:"Weights",value:function(){for(var u=this.imp.Weights(),c=new Array,y=0;y<=u.Length();y++)c.push(u.Value(y));return c}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Copy",value:function(){return new Mx3dGeomObject(this.imp.Copy())}},{key:"Edge",value:function(u,c){return new Mx3dShapeEdge(this.imp.Edge(u,c))}},{key:"Wire",value:function(){return new Mx3dShapeWire(this.imp.Wire())}},{key:"OffsetCurve",value:function(u,c,y){return c=uniToDir(c),new Mx3dShapeEdge(this.imp.OffsetCurve(u,c.getImp(),y))}},{key:"DynCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToBezierCurve(u.getImp()))}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}}],[{key:"DownCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToBezierCurve(u.getImp()))}}]),l}(Mx3dGeomBoundedCurve),Mx3dGeomSurface=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"UReversed",value:function(){return this.DynCast(new l(this.imp.UReversed()))}},{key:"VReversed",value:function(){return this.DynCast(new l(this.imp.VReversed()))}},{key:"TransformParameters",value:function(u,c){var y=new MxApp3D.imp.MdGeArray1OfReal(1,2);this.imp.TransformParameters(y,c.getImp()),u[0]=y.Value(1),u[1]=y.Value(2)}},{key:"UPeriod",value:function(){return this.imp.UPeriod()}},{key:"VPeriod",value:function(){return this.imp.VPeriod()}},{key:"Value",value:function(u,c){return new Mx3dGePoint(this.imp.Value(u,c))}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}}]),l}(Mx3dGeomObject),Mx3dGeomElementarySurface=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"SetAxis",value:function(u){this.imp.SetAxis(u.getImp())}},{key:"SetLocation",value:function(u){this.imp.SetLocation(u.getImp())}},{key:"SetPosition",value:function(u){this.imp.SetPosition(u.getImp())}},{key:"Axis",value:function(){return new Mx3dGeAxis(this.imp.Axis())}},{key:"Location",value:function(){return new Mx3dGePoint(this.imp.Location())}},{key:"Position",value:function(){return new Mx3dGeCSYSR(this.imp.Position())}},{key:"UReverse",value:function(){this.imp.UReverse()}},{key:"VReverse",value:function(){this.imp.VReverse()}},{key:"Continuity",value:function(){return this.imp.Continuity()}},{key:"IsCNu",value:function(u){return this.imp.IsCNu(u)}},{key:"IsCNv",value:function(u){return this.imp.IsCNv(u)}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}}]),l}(Mx3dGeomSurface),Mx3dGeomPlane=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y){var b;return _classCallCheck$1(this,l),n instanceof Mx3dGeCSYSR?(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dGeomPlane(n.getImp()))):isUniPoint(n)&&isUniDir(u)?(b=e.call(this),n=uniToPoint(n),u=uniToDir(u),b.initTempObject(new MxApp3D.imp.Mx3dGeomPlane(n.getImp(),u.getImp()))):typeof n=="number"&&typeof u=="number"&&typeof c=="number"&&typeof y=="number"?(b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dGeomPlane(n,u,c,y))):n instanceof Object&&(b=e.call(this,n)),_possibleConstructorReturn$1(b)}return _createClass$1(l,[{key:"UReverse",value:function(){this.imp.UReverse()}},{key:"UReversedParameter",value:function(u){return this.imp.UReversedParameter(u)}},{key:"VReverse",value:function(){this.imp.VReverse()}},{key:"VReversedParameter",value:function(u){return this.imp.VReversedParameter(u)}},{key:"TransformParameters",value:function(u,c){var y=new MxApp3D.imp.MdGeArray1OfReal(1,2);this.imp.TransformParameters(y,c.getImp()),u[0]=y.Value(1),u[1]=y.Value(2)}},{key:"Bounds",value:function(u){var c=new MxApp3D.imp.MdGeArray1OfReal(1,4);this.imp.Bounds(c),u[0]=c.Value(1),u[1]=c.Value(2),u[2]=c.Value(3),u[3]=c.Value(4)}},{key:"Coefficients",value:function(u){var c=new MxApp3D.imp.MdGeArray1OfReal(1,4);this.imp.Coefficients(c),u[0]=c.Value(1),u[1]=c.Value(2),u[2]=c.Value(3),u[3]=c.Value(4)}},{key:"IsUClosed",value:function(){return this.imp.IsUClosed()}},{key:"IsVClosed",value:function(){return this.imp.IsVClosed()}},{key:"IsUPeriodic",value:function(){return this.imp.IsUPeriodic()}},{key:"IsVPeriodic",value:function(){return this.imp.IsVPeriodic()}},{key:"D0",value:function(u,c,y){this.imp.D0(u,c,y.getImp())}},{key:"D1",value:function(u,c,y,b,m){this.imp.D1(u,c,y.getImp(),b.getImp(),m.getImp())}},{key:"D2",value:function(u,c,y,b,m,O,N,L){this.imp.D2(u,c,y.getImp(),b.getImp(),m.getImp(),O.getImp(),N.getImp(),L.getImp())}},{key:"D3",value:function(u,c,y,b,m,O,N,L,G,q,J,fe){this.imp.D3(u,c,y.getImp(),b.getImp(),m.getImp(),O.getImp(),N.getImp(),L.getImp(),G.getImp(),q.getImp(),J.getImp(),fe.getImp())}},{key:"DN",value:function(u,c,y,b){return new Mx3dGeVec(this.imp.DN(u,c,y,b))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Copy",value:function(){return new Mx3dGeomObject(this.imp.Copy())}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}},{key:"DynCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToPlane(u.getImp()))}},{key:"Face",value:function(u,c,y,b,m){return typeof u=="number"&&arguments.length===1?new Mx3dShapeFace(this.imp.Face(u)):u instanceof Mx3dShapeWire&&typeof c=="boolean"?new Mx3dShapeFace(this.imp.Face(u.getImp(),c)):typeof u=="number"&&typeof c=="number"&&typeof y=="number"&&typeof b=="number"&&typeof m=="number"?new Mx3dShapeFace(this.imp.Face(u,c,y,b,m)):new Mx3dShapeFace}}],[{key:"DownCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToPlane(u.getImp()))}}]),l}(Mx3dGeomElementarySurface),Mx3dGeomConicalSurface=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),n instanceof Mx3dGeCSYSR&&typeof u=="number"&&typeof c=="number"?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeomConicalSurface(n.getImp(),u,c))):n instanceof Object&&(y=e.call(this,n)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"SetRadius",value:function(u){this.imp.SetRadius(u)}},{key:"SetSemiAngle",value:function(u){this.imp.SetSemiAngle(u)}},{key:"UReversedParameter",value:function(u){return this.imp.rameter(u)}},{key:"VReversedParameter",value:function(u){return this.imp.rameter(u)}},{key:"VReverse",value:function(){this.imp.VReverse()}},{key:"TransformParameters",value:function(u,c){var y=new MxApp3D.imp.MdGeArray1OfReal(1,2);this.imp.TransformParameters(y,c.getImp()),u[0]=y.Value(1),u[1]=y.Value(2)}},{key:"Apex",value:function(){return new Mx3dGePoint(this.imp.Apex())}},{key:"Bounds",value:function(u){var c=new MxApp3D.imp.MdGeArray1OfReal(1,4);this.imp.Bounds(c),u[0]=c.Value(1),u[1]=c.Value(2),u[2]=c.Value(3),u[3]=c.Value(4)}},{key:"Coefficients",value:function(u){var c=new MxApp3D.imp.MdGeArray1OfReal(1,10);this.imp.Coefficients(c),u[0]=c.Value(1),u[1]=c.Value(2),u[2]=c.Value(3),u[3]=c.Value(4),u[4]=c.Value(5),u[5]=c.Value(6),u[6]=c.Value(7),u[7]=c.Value(8),u[8]=c.Value(9),u[9]=c.Value(10)}},{key:"RefRadius",value:function(){return this.imp.RefRadius()}},{key:"SemiAngle",value:function(){return this.imp.SemiAngle()}},{key:"IsUClosed",value:function(){return this.imp.IsUClosed()}},{key:"IsVClosed",value:function(){return this.imp.IsVClosed()}},{key:"IsUPeriodic",value:function(){return this.imp.IsUPeriodic()}},{key:"IsVPeriodic",value:function(){return this.imp.IsVPeriodic()}},{key:"D0",value:function(u,c,y){this.imp.D0(u,c,y.getImp())}},{key:"D1",value:function(u,c,y,b,m){this.imp.D1(u,c,y.getImp(),b.getImp(),m.getImp())}},{key:"D2",value:function(u,c,y,b,m,O,N,L){this.imp.D2(u,c,y.getImp(),b.getImp(),m.getImp(),O.getImp(),N.getImp(),L.getImp())}},{key:"D3",value:function(u,c,y,b,m,O,N,L,G,q,J,fe){this.imp.D3(u,c,y.getImp(),b.getImp(),m.getImp(),O.getImp(),N.getImp(),L.getImp(),G.getImp(),q.getImp(),J.getImp(),fe.getImp())}},{key:"DN",value:function(u,c,y,b){return new Mx3dGeVec(this.imp.DN(u,c,y,b))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Copy",value:function(){return new Mx3dGeomObject(this.imp.Copy())}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}},{key:"DynCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToConicalSurface(u.getImp()))}},{key:"Face",value:function(u,c,y,b,m){return typeof u=="number"&&arguments.length===1?new Mx3dShapeFace(this.imp.Face(u)):u instanceof Mx3dShapeWire&&typeof c=="boolean"?new Mx3dShapeFace(this.imp.Face(u.getImp(),c)):typeof u=="number"&&typeof c=="number"&&typeof y=="number"&&typeof b=="number"&&typeof m=="number"?new Mx3dShapeFace(this.imp.Face(u,c,y,b,m)):new Mx3dShapeFace}}],[{key:"DownCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToConicalSurface(u.getImp()))}}]),l}(Mx3dGeomElementarySurface),Mx3dGeomCylindricalSurface=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),n instanceof Mx3dGeCSYSR&&typeof u=="number"?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeomCylindricalSurface(n.getImp(),u))):n instanceof Object&&(c=e.call(this,n)),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"SetRadius",value:function(u){this.imp.SetRadius(u)}},{key:"UReversedParameter",value:function(u){return this.imp.rameter(u)}},{key:"VReversedParameter",value:function(u){return this.imp.rameter(u)}},{key:"TransformParameters",value:function(u,c){var y=new MxApp3D.imp.MdGeArray1OfReal(1,2);this.imp.TransformParameters(y,c.getImp()),u[0]=y.Value(1),u[1]=y.Value(2)}},{key:"Bounds",value:function(u){var c=new MxApp3D.imp.MdGeArray1OfReal(1,4);this.imp.Bounds(c),u[0]=c.Value(1),u[1]=c.Value(2),u[2]=c.Value(3),u[3]=c.Value(4)}},{key:"Coefficients",value:function(u){var c=new MxApp3D.imp.MdGeArray1OfReal(1,10);this.imp.Coefficients(c),u[0]=c.Value(1),u[1]=c.Value(2),u[2]=c.Value(3),u[3]=c.Value(4),u[4]=c.Value(5),u[5]=c.Value(6),u[6]=c.Value(7),u[7]=c.Value(8),u[8]=c.Value(9),u[9]=c.Value(10)}},{key:"Radius",value:function(){return this.imp.Radius()}},{key:"IsUClosed",value:function(){return this.imp.IsUClosed()}},{key:"IsVClosed",value:function(){return this.imp.IsVClosed()}},{key:"IsUPeriodic",value:function(){return this.imp.IsUPeriodic()}},{key:"IsVPeriodic",value:function(){return this.imp.IsVPeriodic()}},{key:"D0",value:function(u,c,y){this.imp.D0(u,c,y.getImp())}},{key:"D1",value:function(u,c,y,b,m){this.imp.D1(u,c,y.getImp(),b.getImp(),m.getImp())}},{key:"D2",value:function(u,c,y,b,m,O,N,L){this.imp.D2(u,c,y.getImp(),b.getImp(),m.getImp(),O.getImp(),N.getImp(),L.getImp())}},{key:"D3",value:function(u,c,y,b,m,O,N,L,G,q,J,fe){this.imp.D3(u,c,y.getImp(),b.getImp(),m.getImp(),O.getImp(),N.getImp(),L.getImp(),G.getImp(),q.getImp(),J.getImp(),fe.getImp())}},{key:"DN",value:function(u,c,y,b){return new Mx3dGeVec(this.imp.DN(u,c,y,b))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Copy",value:function(){return new Mx3dGeomObject(this.imp.Copy())}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}},{key:"DynCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToCylindricalSurface(u.getImp()))}},{key:"Face",value:function(u,c,y,b,m){return typeof u=="number"&&arguments.length===1?new Mx3dShapeFace(this.imp.Face(u)):u instanceof Mx3dShapeWire&&typeof c=="boolean"?new Mx3dShapeFace(this.imp.Face(u.getImp(),c)):typeof u=="number"&&typeof c=="number"&&typeof y=="number"&&typeof b=="number"&&typeof m=="number"?new Mx3dShapeFace(this.imp.Face(u,c,y,b,m)):new Mx3dShapeFace}}],[{key:"DownCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToCylindricalSurface(u.getImp()))}}]),l}(Mx3dGeomElementarySurface),Mx3dGeomSphericalSurface=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),n instanceof Mx3dGeCSYSR&&typeof u=="number"?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeomSphericalSurface(n.getImp(),u))):n instanceof Object&&(c=e.call(this,n)),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"SetRadius",value:function(u){this.imp.SetRadius(u)}},{key:"UReversedParameter",value:function(u){return this.imp.rameter(u)}},{key:"VReversedParameter",value:function(u){return this.imp.rameter(u)}},{key:"Area",value:function(){return this.imp.Area()}},{key:"Bounds",value:function(u){var c=new MxApp3D.imp.MdGeArray1OfReal(1,4);this.imp.Bounds(c),u[0]=c.Value(1),u[1]=c.Value(2),u[2]=c.Value(3),u[3]=c.Value(4)}},{key:"Coefficients",value:function(u){var c=new MxApp3D.imp.MdGeArray1OfReal(1,10);this.imp.Coefficients(c),u[0]=c.Value(1),u[1]=c.Value(2),u[2]=c.Value(3),u[3]=c.Value(4),u[4]=c.Value(5),u[5]=c.Value(6),u[6]=c.Value(7),u[7]=c.Value(8),u[8]=c.Value(9),u[9]=c.Value(10)}},{key:"Radius",value:function(){return this.imp.Radius()}},{key:"Volume",value:function(){return this.imp.Volume()}},{key:"IsUClosed",value:function(){return this.imp.IsUClosed()}},{key:"IsVClosed",value:function(){return this.imp.IsVClosed()}},{key:"IsUPeriodic",value:function(){return this.imp.IsUPeriodic()}},{key:"IsVPeriodic",value:function(){return this.imp.IsVPeriodic()}},{key:"D0",value:function(u,c,y){this.imp.D0(u,c,y.getImp())}},{key:"D1",value:function(u,c,y,b,m){this.imp.D1(u,c,y.getImp(),b.getImp(),m.getImp())}},{key:"D2",value:function(u,c,y,b,m,O,N,L){this.imp.D2(u,c,y.getImp(),b.getImp(),m.getImp(),O.getImp(),N.getImp(),L.getImp())}},{key:"D3",value:function(u,c,y,b,m,O,N,L,G,q,J,fe){this.imp.D3(u,c,y.getImp(),b.getImp(),m.getImp(),O.getImp(),N.getImp(),L.getImp(),G.getImp(),q.getImp(),J.getImp(),fe.getImp())}},{key:"DN",value:function(u,c,y,b){return new Mx3dGeVec(this.imp.DN(u,c,y,b))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Copy",value:function(){return new Mx3dGeomObject(this.imp.Copy())}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}},{key:"DynCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToSphericalSurface(u.getImp()))}},{key:"Face",value:function(u,c,y,b,m){return typeof u=="number"&&arguments.length===1?new Mx3dShapeFace(this.imp.Face(u)):u instanceof Mx3dShapeWire&&typeof c=="boolean"?new Mx3dShapeFace(this.imp.Face(u.getImp(),c)):typeof u=="number"&&typeof c=="number"&&typeof y=="number"&&typeof b=="number"&&typeof m=="number"?new Mx3dShapeFace(this.imp.Face(u,c,y,b,m)):new Mx3dShapeFace}}],[{key:"DownCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToSphericalSurface(u.getImp()))}}]),l}(Mx3dGeomElementarySurface),Mx3dGeomToroidalSurface=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),n instanceof Mx3dGeCSYSR&&typeof u=="number"&&typeof c=="number"?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dGeomToroidalSurface(n.getImp(),u,c))):n instanceof Object&&(y=e.call(this,n)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"SetMajorRadius",value:function(u){this.imp.ajorRadius(u)}},{key:"SetMinorRadius",value:function(u){this.imp.inorRadius(u)}},{key:"UReversedParameter",value:function(u){return this.imp.rameter(u)}},{key:"VReversedParameter",value:function(u){return this.imp.rameter(u)}},{key:"Area",value:function(){return this.imp.Area()}},{key:"Bounds",value:function(u){var c=new MxApp3D.imp.MdGeArray1OfReal(1,4);this.imp.Bounds(c),u[0]=c.Value(1),u[1]=c.Value(2),u[2]=c.Value(3),u[3]=c.Value(4)}},{key:"Coefficients",value:function(u){var c=new MxApp3D.imp.MdGeArray1OfReal(1,31);this.imp.Coefficients(c);for(var y=1;y<=c.Length();y++)u.push(c.Value(y))}},{key:"MajorRadius",value:function(){return this.imp.MajorRadius()}},{key:"MinorRadius",value:function(){return this.imp.MinorRadius()}},{key:"Volume",value:function(){return this.imp.Volume()}},{key:"IsUClosed",value:function(){return this.imp.IsUClosed()}},{key:"IsVClosed",value:function(){return this.imp.IsVClosed()}},{key:"IsUPeriodic",value:function(){return this.imp.IsUPeriodic()}},{key:"IsVPeriodic",value:function(){return this.imp.IsVPeriodic()}},{key:"D0",value:function(u,c,y){this.imp.D0(u,c,y.getImp())}},{key:"D1",value:function(u,c,y,b,m){this.imp.D1(u,c,y.getImp(),b.getImp(),m.getImp())}},{key:"D2",value:function(u,c,y,b,m,O,N,L){this.imp.D2(u,c,y.getImp(),b.getImp(),m.getImp(),O.getImp(),N.getImp(),L.getImp())}},{key:"D3",value:function(u,c,y,b,m,O,N,L,G,q,J,fe){this.imp.D3(u,c,y.getImp(),b.getImp(),m.getImp(),O.getImp(),N.getImp(),L.getImp(),G.getImp(),q.getImp(),J.getImp(),fe.getImp())}},{key:"DN",value:function(u,c,y,b){return new Mx3dGeVec(this.imp.DN(u,c,y,b))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Copy",value:function(){return new Mx3dGeomObject(this.imp.Copy())}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}},{key:"DynCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToToroidalSurface(u.getImp()))}},{key:"Face",value:function(u,c,y,b,m){return typeof u=="number"&&arguments.length===1?new Mx3dShapeFace(this.imp.Face(u)):u instanceof Mx3dShapeWire&&typeof c=="boolean"?new Mx3dShapeFace(this.imp.Face(u.getImp(),c)):typeof u=="number"&&typeof c=="number"&&typeof y=="number"&&typeof b=="number"&&typeof m=="number"?new Mx3dShapeFace(this.imp.Face(u,c,y,b,m)):new Mx3dShapeFace}}],[{key:"DownCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToToroidalSurface(u.getImp()))}}]),l}(Mx3dGeomElementarySurface),Mx3dGeomBoundedSurface=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){return _classCallCheck$1(this,l),e.call(this,n)}return _createClass$1(l,[{key:"DynamicType",value:function(){return this.imp.DynamicType()}}]),l}(Mx3dGeomSurface);function arrayToArray1OfReal(t){for(var e=new MxNewMdGeArray1OfReal(1,t.length),l=0;l<t.length;l++)e.SetValue(l+1,t[l]);return e}function arrayToArray1OfInteger(t){for(var e=new MxNewMdGeArray1OfInteger(1,t.length),l=0;l<t.length;l++)e.SetValue(l+1,t[l]);return e}function arrayToArray1OfPnt(t){for(var e=new MxNewMdGeArray1OfPnt(1,t.length),l=0;l<t.length;l++)e.SetValue(l+1,t[l]);return e}function arrayToArray2OfPnt(t){for(var e=t.length,l=t[0].length,n=new MxNewMdGeArray2OfPnt(1,e,1,l),u=0;u<e;u++)for(var c=0;c<l;c++)n.SetValue(u+1,c+1,t[u][c]);return n}function arrayToArray2OfReal(t){for(var e=t.length,l=t[0].length,n=new MxNewMdGeArray2OfReal(1,e,1,l),u=0;u<e;u++)for(var c=0;c<l;c++)n.SetValue(u+1,c+1,t[u][c]);return n}function array2OfPntToArray(t){for(var e=new Array,l=1;l<=t.UpperRow();l++){for(var n=new Array,u=1;u<=t.UpperCol();u++)n.push(t.Value(l,u));e.push(n)}return e}function array2OfRealToArray(t){for(var e=new Array,l=1;l<=t.UpperRow();l++){for(var n=new Array,u=1;u<=t.UpperCol();u++)n.push(t.Value(l,u));e.push(n)}return e}function array1OfRealToArray(t){for(var e=new Array,l=1;l<=t.Length();l++)e.push(t.Value(l));return e}function array1OfIntegerToArray(t){for(var e=new Array,l=1;l<=t.Length();l++)e.push(t.Value(l));return e}var Mx3dGeomBSplineSurface=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y,b,m,O,N,L,G){var q;if(_classCallCheck$1(this,l),n instanceof Array&&u instanceof Array&&typeof u[0]=="number"){q=e.call(this);var J=arrayToArray2OfPnt(n),fe=arrayToArray1OfReal(u),ve=arrayToArray1OfReal(c),ne=arrayToArray1OfInteger(y),Ue=arrayToArray1OfInteger(b);q.initTempObject(new MxApp3D.imp.Mx3dGeomBSplineSurface(J.getImp(),fe.getImp(),ve.getImp(),ne.getImp(),Ue.getImp(),m,O,N,L))}else if(u instanceof Array&&u[0]instanceof Array){q=e.call(this);var De=arrayToArray2OfPnt(n),Ve=arrayToArray2OfReal(u),rt=arrayToArray1OfReal(c),Ae=arrayToArray1OfReal(y),Te=arrayToArray1OfInteger(b),Xe=arrayToArray1OfInteger(m);q.initTempObject(new MxApp3D.imp.Mx3dGeomBSplineSurface(De.getImp(),Ve.getImp(),rt.getImp(),Ae.getImp(),Te.getImp(),Xe.getImp(),O,N,L,G))}else n instanceof Object&&(q=e.call(this,n));return _possibleConstructorReturn$1(q)}return _createClass$1(l,[{key:"ExchangeUV",value:function(){this.imp.ExchangeUV()}},{key:"SetUPeriodic",value:function(){this.imp.SetUPeriodic()}},{key:"SetVPeriodic",value:function(){this.imp.SetVPeriodic()}},{key:"PeriodicNormalization",value:function(u){var c=arrayToArray1OfReal(u);this.imp.PeriodicNormalization(c.getImp())}},{key:"SetUOrigin",value:function(u){this.imp.SetUOrigin(u)}},{key:"SetVOrigin",value:function(u){this.imp.SetVOrigin(u)}},{key:"SetUNotPeriodic",value:function(){this.imp.SetUNotPeriodic()}},{key:"SetVNotPeriodic",value:function(){this.imp.SetVNotPeriodic()}},{key:"UReverse",value:function(){this.imp.UReverse()}},{key:"VReverse",value:function(){this.imp.VReverse()}},{key:"UReversedParameter",value:function(u){return this.imp.UReversedParameter(u)}},{key:"VReversedParameter",value:function(u){return this.imp.VReversedParameter(u)}},{key:"IncreaseDegree",value:function(u,c){this.imp.IncreaseDegree(u,c)}},{key:"InsertUKnots",value:function(u,c,y,b){var m=arrayToArray1OfReal(u),O=arrayToArray1OfInteger(c);this.imp.InsertUKnots(m.getImp(),O.getImp(),y,b)}},{key:"InsertVKnots",value:function(u,c,y,b){var m=arrayToArray1OfReal(u),O=arrayToArray1OfInteger(c);this.imp.InsertVKnots(m.getImp(),O.getImp(),y,b)}},{key:"RemoveUKnot",value:function(u,c,y){return this.imp.RemoveUKnot(u,c,y)}},{key:"RemoveVKnot",value:function(u,c,y){return this.imp.RemoveVKnot(u,c,y)}},{key:"IncreaseUMultiplicity",value:function(u,c,y){y?this.imp.IncreaseUMultiplicity(u,c,y):this.imp.IncreaseUMultiplicity(u,c)}},{key:"IncrementUMultiplicity",value:function(u,c,y){this.imp.IncrementUMultiplicity(u,c,y)}},{key:"IncreaseVMultiplicity",value:function(u,c,y){y?this.imp.IncreaseVMultiplicity(u,c,y):this.imp.IncreaseVMultiplicity(u,c)}},{key:"IncrementVMultiplicity",value:function(u,c,y){this.imp.IncrementVMultiplicity(u,c,y)}},{key:"InsertUKnot",value:function(u,c,y,b){this.imp.InsertUKnot(u,c,y,b)}},{key:"InsertVKnot",value:function(u,c,y,b){this.imp.InsertVKnot(u,c,y,b)}},{key:"Segment",value:function(u,c,y,b){this.imp.Segment(u,c,y,b)}},{key:"CheckAndSegment",value:function(u,c,y,b){this.imp.CheckAndSegment(u,c,y,b)}},{key:"SetUKnot",value:function(u,c,y){y?this.imp.SetUKnot(u,c,y):this.imp.SetUKnot(u,c)}},{key:"SetVKnot",value:function(u,c,y){y?this.imp.SetVKnot(u,c,y):this.imp.SetVKnot(u,c)}},{key:"SetUKnots",value:function(u){var c=arrayToArray1OfReal(u);this.imp.SetUKnots(c.getImp())}},{key:"SetVKnots",value:function(u){var c=arrayToArray1OfReal(u);this.imp.SetVKnots(c.getImp())}},{key:"LocateU",value:function(u,c,y,b){var m=arrayToArray1OfInteger(y);this.imp.LocateU(u,c,m.getImp(),b)}},{key:"LocateV",value:function(u,c,y,b){var m=arrayToArray1OfInteger(y);this.imp.LocateV(u,c,m.getImp(),b)}},{key:"SetPole",value:function(u,c,y,b){b?this.imp.SetPole(u,c,y.getImp(),b):this.imp.SetPole(u,c,y.getImp())}},{key:"SetPoleCol",value:function(u,c,y){var b=arrayToArray1OfPnt(c);if(!y)this.imp.SetPoleCol(u,b.getImp());else{var m=arrayToArray1OfReal(y);this.imp.SetPoleCol(u,b.getImp(),m.getImp())}}},{key:"SetPoleRow",value:function(u,c,y){var b=arrayToArray1OfPnt(c);if(!y)this.imp.SetPoleRow(u,b.getImp());else{var m=arrayToArray1OfReal(y);this.imp.SetPoleRow(u,b.getImp(),m.getImp())}}},{key:"SetWeight",value:function(u,c,y){this.imp.SetWeight(u,c,y)}},{key:"SetWeightCol",value:function(u,c){var y=arrayToArray1OfReal(c);this.imp.SetWeightCol(u,y.getImp())}},{key:"SetWeightRow",value:function(u,c){var y=arrayToArray1OfReal(c);this.imp.SetWeightRow(u,y.getImp())}},{key:"MovePoint",value:function(u,c,y,b,m,O,N,L){var G=arrayToArray1OfInteger(L);this.imp.MovePoint(u,c,y.getImp(),b,m,O,N,G.getImp())}},{key:"IsUClosed",value:function(){return this.imp.IsUClosed()}},{key:"IsVClosed",value:function(){return this.imp.IsVClosed()}},{key:"IsCNu",value:function(u){return this.imp.IsCNu(u)}},{key:"IsCNv",value:function(u){return this.imp.IsCNv(u)}},{key:"IsUPeriodic",value:function(){return this.imp.IsUPeriodic()}},{key:"IsURational",value:function(){return this.imp.IsURational()}},{key:"IsVPeriodic",value:function(){return this.imp.IsVPeriodic()}},{key:"IsVRational",value:function(){return this.imp.IsVRational()}},{key:"Bounds",value:function(u){var c=new MxApp3D.imp.MdGeArray1OfReal(1,4);this.imp.Bounds(c),u[0]=c.Value(1),u[1]=c.Value(2),u[2]=c.Value(3),u[3]=c.Value(4)}},{key:"Continuity",value:function(){return this.imp.Continuity()}},{key:"FirstUKnotIndex",value:function(){return this.imp.FirstUKnotIndex()}},{key:"FirstVKnotIndex",value:function(){return this.imp.FirstVKnotIndex()}},{key:"LastUKnotIndex",value:function(){return this.imp.LastUKnotIndex()}},{key:"LastVKnotIndex",value:function(){return this.imp.LastVKnotIndex()}},{key:"NbUKnots",value:function(){return this.imp.NbUKnots()}},{key:"NbUPoles",value:function(){return this.imp.NbUPoles()}},{key:"NbVKnots",value:function(){return this.imp.NbVKnots()}},{key:"NbVPoles",value:function(){return this.imp.NbVPoles()}},{key:"Pole",value:function(u,c){return new Mx3dGePoint(this.imp.Pole(u,c))}},{key:"Poles",value:function(){var u=new MxNewMdGeArray2OfPnt(this.imp.Poles());return array2OfPntToArray(u)}},{key:"UDegree",value:function(){return this.imp.UDegree()}},{key:"UKnot",value:function(u){return this.imp.UKnot(u)}},{key:"UKnots",value:function(){var u=new MxNewMdGeArray1OfReal(this.imp.UKnots());return array1OfRealToArray(u)}},{key:"UKnotSequence",value:function(){var u=new MxNewMdGeArray1OfReal(this.imp.UKnotSequence());return array1OfRealToArray(u)}},{key:"UMultiplicity",value:function(u){return this.imp.UMultiplicity(u)}},{key:"UMultiplicities",value:function(){var u=new MxNewMdGeArray1OfInteger(this.imp.UMultiplicities());return array1OfIntegerToArray(u)}},{key:"VDegree",value:function(){return this.imp.VDegree()}},{key:"VKnot",value:function(u){return this.imp.VKnot(u)}},{key:"VKnots",value:function(){var u=new MxNewMdGeArray1OfReal(this.imp.VKnots());return array1OfRealToArray(u)}},{key:"VKnotSequence",value:function(){var u=new MxNewMdGeArray1OfReal(this.imp.VKnotSequence());return array1OfRealToArray(u)}},{key:"VMultiplicity",value:function(u){return this.imp.VMultiplicity(u)}},{key:"VMultiplicities",value:function(){var u=new MxNewMdGeArray1OfInteger(this.imp.VMultiplicities());return array1OfIntegerToArray(u)}},{key:"Weight",value:function(u,c){return this.imp.Weight(u,c)}},{key:"Weights",value:function(){var u=new MxNewMdGeArray2OfReal(this.imp.Weights());return array2OfRealToArray(u)}},{key:"D0",value:function(u,c,y){this.imp.D0(u,c,y.getImp())}},{key:"D1",value:function(u,c,y,b,m){this.imp.D1(u,c,y.getImp(),b.getImp(),m.getImp())}},{key:"D2",value:function(u,c,y,b,m,O,N,L){this.imp.D2(u,c,y.getImp(),b.getImp(),m.getImp(),O.getImp(),N.getImp(),L.getImp())}},{key:"D3",value:function(u,c,y,b,m,O,N,L,G,q,J,fe){this.imp.D3(u,c,y.getImp(),b.getImp(),m.getImp(),O.getImp(),N.getImp(),L.getImp(),G.getImp(),q.getImp(),J.getImp(),fe.getImp())}},{key:"DN",value:function(u,c,y,b){return new Mx3dGeVec(this.imp.DN(u,c,y,b))}},{key:"LocalD0",value:function(u,c,y,b,m,O,N){this.imp.LocalD0(u,c,y,b,m,O,N.getImp())}},{key:"LocalD1",value:function(u,c,y,b,m,O,N,L,G){this.imp.LocalD1(u,c,y,b,m,O,N.getImp(),L.getImp(),G.getImp())}},{key:"LocalD2",value:function(u,c,y,b,m,O,N,L,G,q,J,fe){this.imp.LocalD2(u,c,y,b,m,O,N.getImp(),L.getImp(),G.getImp(),q.getImp(),J.getImp(),fe.getImp())}},{key:"LocalD3",value:function(u,c,y,b,m,O,N,L,G,q,J,fe,ve,ne,Ue,De){this.imp.LocalD3(u,c,y,b,m,O,N.getImp(),L.getImp(),G.getImp(),q.getImp(),J.getImp(),fe.getImp(),ve.getImp(),ne.getImp(),Ue.getImp(),De.getImp())}},{key:"LocalDN",value:function(u,c,y,b,m,O,N,L){return new Mx3dGeVec(this.imp.LocalDN(u,c,y,b,m,O,N,L))}},{key:"LocalValue",value:function(u,c,y,b,m,O){return new Mx3dGePoint(this.imp.LocalValue(u,c,y,b,m,O))}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Copy",value:function(){return new Mx3dGeomObject(this.imp.Copy())}},{key:"DynamicType",value:function(){return this.imp.DynamicType()}},{key:"DynCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToBSplineSurface(u.getImp()))}},{key:"Face",value:function(u,c,y,b,m){return typeof u=="number"&&arguments.length===1?new Mx3dShapeFace(this.imp.Face(u)):u instanceof Mx3dShapeWire&&typeof c=="boolean"?new Mx3dShapeFace(this.imp.Face(u.getImp(),c)):typeof u=="number"&&typeof c=="number"&&typeof y=="number"&&typeof b=="number"&&typeof m=="number"?new Mx3dShapeFace(this.imp.Face(u,c,y,b,m)):new Mx3dShapeFace}}],[{key:"DownCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToBSplineSurface(u.getImp()))}}]),l}(Mx3dGeomBoundedSurface),Mx3dGeomBezierSurface=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;_classCallCheck$1(this,l);var y=arrayToArray2OfPnt(n);if(n instanceof Array&&n[0]instanceof Array&&n[0][0]instanceof Mx3dGePoint&&arguments.length===1)c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dGeomBezierSurface(y.getImp()));else if(n instanceof Array&&n[0]instanceof Array&&n[0][0]instanceof Mx3dGePoint&&u instanceof Array&&u[0]instanceof Array&&typeof u[0][0]=="number"){c=e.call(this);var b=arrayToArray2OfReal(u);c.initTempObject(new MxApp3D.imp.Mx3dGeomBezierSurface(y.getImp(),b.getImp()))}else n instanceof Object&&(c=e.call(this,n));return _possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"ExchangeUV",value:function(){this.imp.ExchangeUV()}},{key:"Increase",value:function(u,c){this.imp.Increase(u,c)}},{key:"InsertPoleColAfter",value:function(u,c,y){var b=arrayToArray1OfPnt(c);if(!y)this.imp.InsertPoleColAfter(u,b.getImp());else{var m=arrayToArray1OfReal(y);this.imp.InsertPoleColAfter(u,b.getImp(),m.getImp())}}},{key:"InsertPoleColBefore",value:function(u,c,y){var b=arrayToArray1OfPnt(c);if(!y)this.imp.InsertPoleColBefore(u,b.getImp());else{var m=arrayToArray1OfReal(y);this.imp.InsertPoleColBefore(u,b.getImp(),m.getImp())}}},{key:"InsertPoleRowAfter",value:function(u,c,y){var b=arrayToArray1OfPnt(c);if(!y)this.imp.InsertPoleRowAfter(u,b.getImp());else{var m=arrayToArray1OfReal(y);this.imp.InsertPoleRowAfter(u,b.getImp(),m.getImp())}}},{key:"InsertPoleRowBefore",value:function(u,c,y){var b=arrayToArray1OfPnt(c);if(!y)this.imp.InsertPoleRowBefore(u,b.getImp());else{var m=arrayToArray1OfReal(y);this.imp.InsertPoleRowBefore(u,b.getImp(),m.getImp())}}},{key:"RemovePoleCol",value:function(u){this.imp.RemovePoleCol(u)}},{key:"RemovePoleRow",value:function(u){this.imp.RemovePoleRow(u)}},{key:"Segment",value:function(u,c,y,b){this.imp.Segment(u,c,y,b)}},{key:"SetPole",value:function(u,c,y,b){b?this.imp.SetPole(u,c,y.getImp(),b):this.imp.SetPole(u,c,y.getImp())}},{key:"SetPoleCol",value:function(u,c,y){var b=arrayToArray1OfPnt(c);if(!y)this.imp.SetPoleCol(u,b.getImp());else{var m=arrayToArray1OfReal(y);this.imp.SetPoleCol(u,b.getImp(),m.getImp())}}},{key:"SetPoleRow",value:function(u,c,y){var b=arrayToArray1OfPnt(c);if(!y)this.imp.SetPoleRow(u,b.getImp());else{var m=arrayToArray1OfReal(y);this.imp.SetPoleRow(u,b.getImp(),m.getImp())}}},{key:"SetWeight",value:function(u,c,y){this.imp.SetWeight(u,c,y)}},{key:"SetWeightCol",value:function(u,c){var y=arrayToArray1OfReal(c);this.imp.SetWeightCol(u,y.getImp())}},{key:"SetWeightRow",value:function(u,c){var y=arrayToArray1OfReal(c);this.imp.SetWeightRow(u,y.getImp())}},{key:"UReverse",value:function(){this.imp.UReverse()}},{key:"UReversedParameter",value:function(u){return this.imp.UReversedParameter(u)}},{key:"VReverse",value:function(){this.imp.VReverse()}},{key:"VReversedParameter",value:function(u){return this.imp.VReversedParameter(u)}},{key:"Bounds",value:function(u){var c=new MxApp3D.imp.MdGeArray1OfReal(1,4);this.imp.Bounds(c),u[0]=c.Value(1),u[1]=c.Value(2),u[2]=c.Value(3),u[3]=c.Value(4)}},{key:"Continuity",value:function(){return this.imp.Continuity()}},{key:"D0",value:function(u,c,y){this.imp.D0(u,c,y.getImp())}},{key:"D1",value:function(u,c,y,b,m){this.imp.D1(u,c,y.getImp(),b.getImp(),m.getImp())}},{key:"D2",value:function(u,c,y,b,m,O,N,L){this.imp.D2(u,c,y.getImp(),b.getImp(),m.getImp(),O.getImp(),N.getImp(),L.getImp())}},{key:"D3",value:function(u,c,y,b,m,O,N,L,G,q,J,fe){this.imp.D3(u,c,y.getImp(),b.getImp(),m.getImp(),O.getImp(),N.getImp(),L.getImp(),G.getImp(),q.getImp(),J.getImp(),fe.getImp())}},{key:"DN",value:function(u,c,y,b){return new Mx3dGeVec(this.imp.DN(u,c,y,b))}},{key:"NbUPoles",value:function(){return this.imp.NbUPoles()}},{key:"NbVPoles",value:function(){return this.imp.NbVPoles()}},{key:"Pole",value:function(u,c){return new Mx3dGePoint(this.imp.Pole(u,c))}},{key:"Poles",value:function(){var u=new MxNewMdGeArray2OfPnt(this.imp.Poles());return array2OfPntToArray(u)}},{key:"UDegree",value:function(){return this.imp.UDegree()}},{key:"Weight",value:function(u,c){return this.imp.Weight(u,c)}},{key:"Weights",value:function(){var u=new MxNewMdGeArray2OfReal(this.imp.Weights());return array2OfRealToArray(u)}},{key:"IsUClosed",value:function(){return this.imp.IsUClosed()}},{key:"IsVClosed",value:function(){return this.imp.IsVClosed()}},{key:"IsCNu",value:function(u){return this.imp.IsCNu(u)}},{key:"IsCNv",value:function(u){return this.imp.IsCNv(u)}},{key:"IsUPeriodic",value:function(){return this.imp.IsUPeriodic()}},{key:"IsVPeriodic",value:function(){return this.imp.IsVPeriodic()}},{key:"IsURational",value:function(){return this.imp.IsURational()}},{key:"IsVRational",value:function(){return this.imp.IsVRational()}},{key:"Transform",value:function(u){this.imp.Transform(u.getImp())}},{key:"Copy",value:function(){return new Mx3dGeomObject(this.imp.Copy())}},{key:"DynCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToBezierSurface(u.getImp()))}},{key:"Face",value:function(u,c,y,b,m){return typeof u=="number"&&arguments.length===1?new Mx3dShapeFace(this.imp.Face(u)):u instanceof Mx3dShapeWire&&typeof c=="boolean"?new Mx3dShapeFace(this.imp.Face(u.getImp(),c)):typeof u=="number"&&typeof c=="number"&&typeof y=="number"&&typeof b=="number"&&typeof m=="number"?new Mx3dShapeFace(this.imp.Face(u,c,y,b,m)):new Mx3dShapeFace}}],[{key:"DownCast",value:function(u){return new l(MxApp3D.globalMethods.DynCastToBezierSurface(u.getImp()))}}]),l}(Mx3dGeomBoundedSurface),Mx3dGeMaterial=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?typeof n=="number"?(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dGeMaterial(n))):n instanceof Object&&(u=e.call(this,n)):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dGeMaterial)),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"Name",value:function(){return this.imp.Name()}},{key:"RequestedName",value:function(){return this.imp.RequestedName()}},{key:"StringName",value:function(){return this.imp.StringName()}},{key:"MaterialName",value:function(){return this.imp.MaterialName()}},{key:"SetMaterialName",value:function(u){this.imp.SetMaterialName(u)}},{key:"Reset",value:function(){this.imp.Reset()}},{key:"Color",value:function(){return new Mx3dGeColor(this.imp.Color())}},{key:"SetColor",value:function(u){this.imp.SetColor(u.getImp())}},{key:"Transparency",value:function(){return this.imp.Transparency()}},{key:"Alpha",value:function(){return this.imp.Alpha()}},{key:"SetTransparency",value:function(u){this.imp.SetTransparency(u)}},{key:"SetAlpha",value:function(u){this.imp.SetAlpha(u)}},{key:"AmbientColor",value:function(){return new Mx3dGeColor(this.imp.AmbientColor())}},{key:"SetAmbientColor",value:function(u){this.imp.SetAmbientColor(u.getImp())}},{key:"DiffuseColor",value:function(){return new Mx3dGeColor(this.imp.DiffuseColor())}},{key:"SetDiffuseColor",value:function(u){this.imp.SetDiffuseColor(u.getImp())}},{key:"SpecularColor",value:function(){return new Mx3dGeColor(this.imp.SpecularColor())}},{key:"SetSpecularColor",value:function(u){this.imp.SetSpecularColor(u.getImp())}},{key:"EmissiveColor",value:function(){return new Mx3dGeColor(this.imp.EmissiveColor())}},{key:"SetEmissiveColor",value:function(u){this.imp.SetEmissiveColor(u.getImp())}},{key:"Shininess",value:function(){return this.imp.Shininess()}},{key:"SetShininess",value:function(u){this.imp.SetShininess(u)}},{key:"IncreaseShine",value:function(u){this.imp.IncreaseShine(u)}},{key:"RefractionIndex",value:function(){return this.imp.RefractionIndex()}},{key:"SetRefractionIndex",value:function(u){this.imp.SetRefractionIndex(u)}},{key:"ReflectionMode",value:function(u){return this.imp.ReflectionMode(u)}},{key:"MaterialType",value:function(){return this.imp.MaterialType()}},{key:"SetMaterialType",value:function(u){this.imp.SetMaterialType(u)}},{key:"IsDifferent",value:function(u){return this.imp.IsDifferent(u.getImp())}},{key:"IsEqual",value:function(u){return this.imp.IsEqual(u.getImp())}}]),l}(Mx3dBaseObject),Mx3dAspectLine=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),n instanceof Mx3dGeColor&&typeof u=="number"&&typeof c=="number"?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dAspectLine(n.getImp(),u,c))):n instanceof Object&&(y=e.call(this,n)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"SetColor",value:function(u){this.imp.SetColor(u.getImp())}},{key:"SetTypeOfLine",value:function(u){this.imp.SetTypeOfLine(u)}},{key:"SetWidth",value:function(u){this.imp.SetWidth(u)}}]),l}(Mx3dAspectObject),Mx3dAspectText=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dAspectText)),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"SetColor",value:function(u){this.imp.SetColor(u.getImp())}},{key:"SetFont",value:function(u){this.imp.SetFont(u)}},{key:"SetHeight",value:function(u){this.imp.SetHeight(u)}},{key:"SetAngle",value:function(u){this.imp.SetAngle(u)}},{key:"Height",value:function(){return this.imp.Height()}},{key:"Angle",value:function(){return this.imp.Angle()}},{key:"SetHorizontalJustification",value:function(u){this.imp.SetHorizontalJustification(u)}},{key:"SetVerticalJustification",value:function(u){this.imp.SetVerticalJustification(u)}},{key:"SetOrientation",value:function(u){this.imp.SetOrientation(u)}},{key:"HorizontalJustification",value:function(){return this.imp.HorizontalJustification()}},{key:"VerticalJustification",value:function(){return this.imp.VerticalJustification()}},{key:"Orientation",value:function(){return this.imp.Orientation()}}]),l}(Mx3dAspectObject),Mx3dAspectArrow=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),!n&&!u?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dAspectArrow)):typeof n=="number"&&typeof u=="number"?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dAspectArrow(n,u))):n instanceof Object&&(c=e.call(this,n)),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"SetAngle",value:function(u){this.imp.SetAngle(u)}},{key:"Angle",value:function(){return this.imp.Angle()}},{key:"SetLength",value:function(u){this.imp.SetLength(u)}},{key:"Length",value:function(){return this.imp.Length()}},{key:"SetZoomable",value:function(u){this.imp.SetZoomable(u)}},{key:"IsZoomable",value:function(){return this.imp.IsZoomable()}},{key:"SetColor",value:function(u){this.imp.SetColor(u.getImp())}}]),l}(Mx3dAspectObject),Mx3dAspectDim=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n){var u;return _classCallCheck$1(this,l),n?u=e.call(this,n):(u=e.call(this),u.initTempObject(new MxApp3D.imp.Mx3dAspectDim)),_possibleConstructorReturn$1(u)}return _createClass$1(l,[{key:"SetLineAspect",value:function(u){this.imp.SetLineAspect(u.getImp())}},{key:"SetTextAspect",value:function(u){this.imp.SetTextAspect(u.getImp())}},{key:"IsText3d",value:function(){return this.imp.IsText3d()}},{key:"MakeText3d",value:function(u){this.imp.MakeText3d(u)}},{key:"IsTextShaded",value:function(){return this.imp.IsTextShaded()}},{key:"MakeTextShaded",value:function(u){this.imp.MakeTextShaded(u)}},{key:"IsArrows3d",value:function(){return this.imp.IsArrows3d()}},{key:"MakeArrows3d",value:function(u){this.imp.MakeArrows3d(u)}},{key:"IsUnitsDisplayed",value:function(){return this.imp.IsUnitsDisplayed()}},{key:"MakeUnitsDisplayed",value:function(u){this.imp.MakeUnitsDisplayed(u)}},{key:"SetArrowOrientation",value:function(u){this.imp.SetArrowOrientation(u)}},{key:"ArrowOrientation",value:function(){return this.imp.ArrowOrientation()}},{key:"SetTextVerticalPosition",value:function(u){this.imp.SetTextVerticalPosition(u)}},{key:"TextVerticalPosition",value:function(){return this.imp.TextVerticalPosition()}},{key:"SetTextHorizontalPosition",value:function(u){this.imp.SetTextHorizontalPosition(u)}},{key:"TextHorizontalPosition",value:function(){return this.imp.TextHorizontalPosition()}},{key:"SetArrowAspect",value:function(u){this.imp.SetArrowAspect(u.getImp())}},{key:"SetCommonColor",value:function(u){this.imp.SetCommonColor(u.getImp())}},{key:"SetExtensionSize",value:function(u){this.imp.SetExtensionSize(u)}},{key:"ExtensionSize",value:function(){return this.imp.ExtensionSize()}},{key:"SetArrowTailSize",value:function(u){this.imp.SetArrowTailSize(u)}},{key:"ArrowTailSize",value:function(){return this.imp.ArrowTailSize()}},{key:"SetValueStringFormat",value:function(u){this.imp.SetValueStringFormat(u)}},{key:"ValueStringFormat",value:function(){return this.imp.ValueStringFormat()}}]),l}(Mx3dAspectObject),Mx3dDimDiameter=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),n instanceof Mx3dGeCircle&&!u?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dDimDiameter(n.getImp()))):n instanceof Mx3dGeCircle&&u instanceof Mx3dGePlane?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dDimDiameter(n.getImp(),u.getImp()))):n instanceof Object&&(c=e.call(this,n)),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"Circle",value:function(){return new Mx3dGeCircle(this.imp.Circle())}},{key:"AnchorPoint",value:function(){return new Mx3dGePoint(this.imp.AnchorPoint())}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"SetMeasuredGeometry",value:function(u){this.imp.SetMeasuredGeometry(u.getImp())}},{key:"SetTextPosition",value:function(u){this.imp.SetTextPosition(u.getImp())}},{key:"GetTextPosition",value:function(){return new Mx3dGePoint(this.imp.GetTextPosition())}},{key:"SetDisplayUnits",value:function(u){this.imp.SetDisplayUnits(u)}},{key:"SetModelUnits",value:function(u){this.imp.SetModelUnits(u)}},{key:"GetValue",value:function(){return this.imp.GetValue()}},{key:"SetComputedValue",value:function(){this.imp.SetComputedValue()}},{key:"SetCustomValue",value:function(u){this.imp.SetCustomValue(u)}},{key:"GetPlane",value:function(){return new Mx3dGePlane(this.imp.GetPlane())}},{key:"GetGeometryType",value:function(){return this.imp.GetGeometryType()}},{key:"SetCustomPlane",value:function(u){this.imp.SetCustomPlane(u.getImp())}},{key:"UnsetCustomPlane",value:function(){this.imp.UnsetCustomPlane()}},{key:"IsTextPositionCustom",value:function(){return this.imp.IsTextPositionCustom()}},{key:"SetDimensionAspect",value:function(u){this.imp.SetDimensionAspect(u.getImp())}},{key:"KindOfDimension",value:function(){return this.imp.KindOfDimension()}},{key:"UnsetFixedTextPosition",value:function(){this.imp.UnsetFixedTextPosition()}},{key:"SelToleranceForText2d",value:function(){return this.imp.SelToleranceForText2d()}},{key:"SetSelToleranceForText2d",value:function(u){this.imp.SetSelToleranceForText2d(u)}},{key:"GetFlyout",value:function(){return this.imp.GetFlyout()}},{key:"SetFlyout",value:function(u){this.imp.SetFlyout(u)}},{key:"IsValid",value:function(){return this.imp.IsValid()}}]),l}(Mx3dDimObject),Mx3dDimRadius=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u){var c;return _classCallCheck$1(this,l),n instanceof Mx3dGeCircle&&!u?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dDimRadius(n.getImp()))):n instanceof Mx3dGeCircle&&u instanceof Mx3dGePoint?(c=e.call(this),c.initTempObject(new MxApp3D.imp.Mx3dDimRadius(n.getImp(),u.getImp()))):n instanceof Object&&(c=e.call(this,n)),_possibleConstructorReturn$1(c)}return _createClass$1(l,[{key:"Circle",value:function(){return new Mx3dGeCircle(this.imp.Circle())}},{key:"AnchorPoint",value:function(){return new Mx3dGePoint(this.imp.AnchorPoint())}},{key:"Shape",value:function(){return new Mx3dShapeObject(this.imp.Shape())}},{key:"SetMeasuredGeometry",value:function(u,c,y){u instanceof Mx3dGeCircle&&!c&&!y?this.imp.SetMeasuredGeometry(u.getImp()):u instanceof Mx3dGeCircle&&c instanceof Mx3dGePoint&&typeof y=="boolean"&&this.imp.SetMeasuredGeometry(u.getImp(),c.getImp(),y)}},{key:"SetTextPosition",value:function(u){this.imp.SetTextPosition(u.getImp())}},{key:"GetTextPosition",value:function(){return new Mx3dGePoint(this.imp.GetTextPosition())}},{key:"GetValue",value:function(){return this.imp.GetValue()}},{key:"SetComputedValue",value:function(){this.imp.SetComputedValue()}},{key:"SetCustomValue",value:function(u){this.imp.SetCustomValue(u)}},{key:"GetPlane",value:function(){return new Mx3dGePlane(this.imp.GetPlane())}},{key:"GetGeometryType",value:function(){return this.imp.GetGeometryType()}},{key:"SetCustomPlane",value:function(u){this.imp.SetCustomPlane(u.getImp())}},{key:"UnsetCustomPlane",value:function(){this.imp.UnsetCustomPlane()}},{key:"IsTextPositionCustom",value:function(){return this.imp.IsTextPositionCustom()}},{key:"SetDimensionAspect",value:function(u){this.imp.SetDimensionAspect(u.getImp())}},{key:"KindOfDimension",value:function(){return this.imp.KindOfDimension()}},{key:"UnsetFixedTextPosition",value:function(){this.imp.UnsetFixedTextPosition()}},{key:"SelToleranceForText2d",value:function(){return this.imp.SelToleranceForText2d()}},{key:"SetSelToleranceForText2d",value:function(u){this.imp.SetSelToleranceForText2d(u)}},{key:"GetFlyout",value:function(){return this.imp.GetFlyout()}},{key:"SetFlyout",value:function(u){this.imp.SetFlyout(u)}},{key:"IsValid",value:function(){return this.imp.IsValid()}}]),l}(Mx3dDimObject),Mx3dDimAngle=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),n instanceof Mx3dShapeEdge&&u instanceof Mx3dShapeEdge?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dDimAngle(n.getImp(),u.getImp()))):n instanceof Mx3dGePoint&&u instanceof Mx3dGePoint&&c instanceof Mx3dGePoint?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dDimAngle(n.getImp(),u.getImp(),c.getImp()))):n instanceof Object&&(y=e.call(this,n)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"FirstPoint",value:function(){return new Mx3dGePoint(this.imp.FirstPoint())}},{key:"SecondPoint",value:function(){return new Mx3dGePoint(this.imp.SecondPoint())}},{key:"CenterPoint",value:function(){return new Mx3dGePoint(this.imp.CenterPoint())}},{key:"FirstShape",value:function(){return new Mx3dShapeObject(this.imp.FirstShape())}},{key:"SecondShape",value:function(){return new Mx3dShapeObject(this.imp.SecondShape())}},{key:"ThirdShape",value:function(){return new Mx3dShapeObject(this.imp.ThirdShape())}},{key:"SetMeasuredGeometry",value:function(u,c,y){u instanceof Mx3dShapeFace?this.imp.SetMeasuredGeometry(u.getImp()):u instanceof Mx3dShapeEdge&&c instanceof Mx3dShapeEdge?this.imp.SetMeasuredGeometry(u.getImp(),c.getImp()):u instanceof Mx3dGePoint&&c instanceof Mx3dGePoint&&y instanceof Mx3dGePoint&&this.imp.SetMeasuredGeometry(u.getImp(),c.getImp(),y.getImp())}},{key:"SetTextPosition",value:function(u){this.imp.SetTextPosition(u.getImp())}},{key:"GetTextPosition",value:function(){return new Mx3dGePoint(this.imp.GetTextPosition())}},{key:"GetDisplayUnits",value:function(){return this.imp.GetDisplayUnits()}},{key:"GetModelUnits",value:function(){return this.imp.GetModelUnits()}},{key:"SetDisplayUnits",value:function(u){this.imp.SetDisplayUnits(u)}},{key:"SetModelUnits",value:function(u){this.imp.SetModelUnits(u)}},{key:"SetType",value:function(u){this.imp.SetType(u)}},{key:"GetType",value:function(){return this.imp.GetType()}},{key:"SetArrowsVisibility",value:function(u){this.imp.SetArrowsVisibility(u)}},{key:"GetArrowsVisibility",value:function(){return this.imp.GetArrowsVisibility()}},{key:"GetValue",value:function(){return this.imp.GetValue()}},{key:"SetComputedValue",value:function(){this.imp.SetComputedValue()}},{key:"SetCustomValue",value:function(u){this.imp.SetCustomValue(u)}},{key:"GetPlane",value:function(){return new Mx3dGePlane(this.imp.GetPlane())}},{key:"GetGeometryType",value:function(){return this.imp.GetGeometryType()}},{key:"SetCustomPlane",value:function(u){this.imp.SetCustomPlane(u.getImp())}},{key:"UnsetCustomPlane",value:function(){this.imp.UnsetCustomPlane()}},{key:"IsTextPositionCustom",value:function(){return this.imp.IsTextPositionCustom()}},{key:"SetDimensionAspect",value:function(u){this.imp.SetDimensionAspect(u.getImp())}},{key:"KindOfDimension",value:function(){return this.imp.KindOfDimension()}},{key:"UnsetFixedTextPosition",value:function(){this.imp.UnsetFixedTextPosition()}},{key:"SelToleranceForText2d",value:function(){return this.imp.SelToleranceForText2d()}},{key:"SetSelToleranceForText2d",value:function(u){this.imp.SetSelToleranceForText2d(u)}},{key:"GetFlyout",value:function(){return this.imp.GetFlyout()}},{key:"SetFlyout",value:function(u){this.imp.SetFlyout(u)}},{key:"IsValid",value:function(){return this.imp.IsValid()}}]),l}(Mx3dDimObject),Mx3dDimLength=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c){var y;return _classCallCheck$1(this,l),n?n instanceof Mx3dShapeEdge&&u instanceof Mx3dGePlane?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dDimLength(n.getImp(),u.getImp()))):n instanceof Mx3dGePoint&&u instanceof Mx3dGePoint&&c instanceof Mx3dGePlane?(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dDimLength(n.getImp(),u.getImp(),c.getImp()))):n instanceof Object&&(y=e.call(this,n)):(y=e.call(this),y.initTempObject(new MxApp3D.imp.Mx3dDimLength)),_possibleConstructorReturn$1(y)}return _createClass$1(l,[{key:"FirstPoint",value:function(){return new Mx3dGePoint(this.imp.FirstPoint())}},{key:"SecondPoint",value:function(){return new Mx3dGePoint(this.imp.SecondPoint())}},{key:"FirstShape",value:function(){return new Mx3dShapeObject(this.imp.FirstShape())}},{key:"SecondShape",value:function(){return new Mx3dShapeObject(this.imp.SecondShape())}},{key:"SetMeasuredGeometry",value:function(u,c,y){this.imp.SetMeasuredGeometry(u.getImp(),c.getImp(),y.getImp())}},{key:"SetMeasuredShapes",value:function(u,c){this.imp.SetMeasuredShapes(u.getImp(),c.getImp())}},{key:"SetTextPosition",value:function(u){this.imp.SetTextPosition(u.getImp())}},{key:"GetTextPosition",value:function(){return new Mx3dGePoint(this.imp.GetTextPosition())}},{key:"SetDirection",value:function(u,c){this.imp.SetDirection(u.getImp(),c)}},{key:"GetValue",value:function(){return this.imp.GetValue()}},{key:"SetComputedValue",value:function(){this.imp.SetComputedValue()}},{key:"SetCustomValue",value:function(u){this.imp.SetCustomValue(u)}},{key:"GetPlane",value:function(){return new Mx3dGePlane(this.imp.GetPlane())}},{key:"GetGeometryType",value:function(){return this.imp.GetGeometryType()}},{key:"SetCustomPlane",value:function(u){this.imp.SetCustomPlane(u.getImp())}},{key:"UnsetCustomPlane",value:function(){this.imp.UnsetCustomPlane()}},{key:"IsTextPositionCustom",value:function(){return this.imp.IsTextPositionCustom()}},{key:"SetDimensionAspect",value:function(u){this.imp.SetDimensionAspect(u.getImp())}},{key:"KindOfDimension",value:function(){return this.imp.KindOfDimension()}},{key:"UnsetFixedTextPosition",value:function(){this.imp.UnsetFixedTextPosition()}},{key:"SelToleranceForText2d",value:function(){return this.imp.SelToleranceForText2d()}},{key:"SetSelToleranceForText2d",value:function(u){this.imp.SetSelToleranceForText2d(u)}},{key:"GetFlyout",value:function(){return this.imp.GetFlyout()}},{key:"SetFlyout",value:function(u){this.imp.SetFlyout(u)}},{key:"IsValid",value:function(){return this.imp.IsValid()}}]),l}(Mx3dDimObject),Mx3dInterpolateBSplineCurve=function(t){_inherits$1(l,t);var e=_createSuper(l);function l(n,u,c,y){var b;if(_classCallCheck$1(this,l),typeof u=="boolean"&&typeof c=="number"){if(n.length===0)throw new Error("Points.length === 0");var m=arrayToArray1OfPnt(n);b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dInterpolateBSplineCurve(m.getImp(),u,c))}else if(u instanceof Array){if(u.length===0)throw new Error("Parameters.length === 0");if(typeof u[0]!="number")throw new Error("Member of Array is not number");if(typeof c=="boolean"&&typeof y=="number"){var O=arrayToArray1OfPnt(n),N=arrayToArray1OfReal(u);b=e.call(this),b.initTempObject(new MxApp3D.imp.Mx3dInterpolateBSplineCurve(O.getImp(),N,c,y))}}return _possibleConstructorReturn$1(b)}return _createClass$1(l,[{key:"LoadEnds",value:function(u,c){var y=uniToVec(u),b=uniToVec(c);this.imp.LoadEnds(y.getImp(),b.getImp())}},{key:"Load",value:function(u,c){for(var y=u.length,b=c.length,m=new MxNewMdGeArray1OfPnt(1,y),O=new MxNewMdGeArray1OfInteger(1,b),N=1;N<=y;N++)m.SetValue(N,new Mx3dGePoint(u[N-1].X(),u[N-1].Y(),u[N-1].Z()));for(var L=1;L<=b;L++)O.SetValue(L,c[L-1]?1:0);this.imp.Load(m.getImp(),O.getImp())}},{key:"Perform",value:function(){this.imp.Perform()}},{key:"Curve",value:function(){return new Mx3dGeomBSplineCurve(this.imp.Curve())}},{key:"IsDone",value:function(){return this.imp.IsDone()}}]),l}(Mx3dBaseObject);function _objectDestructuringEmpty(t){if(t==null)throw new TypeError("Cannot destructure "+t)}var MxMap=function(){function t(){_classCallCheck$1(this,t),_defineProperty$1(this,"imp",{}),_defineProperty$1(this,"map",void 0),_defineProperty$1(this,"originLngLatLike",[0,0]),_defineProperty$1(this,"originCAD",[0,0]),_defineProperty$1(this,"meterInCADUnits",1),_defineProperty$1(this,"modelAltitude",0),_defineProperty$1(this,"loadOldEditionMethod",!1),_defineProperty$1(this,"mxcad",new McObject)}return _createClass$1(t,[{key:"setLoadOldEditionMethod",value:function(){this.loadOldEditionMethod=!0}},{key:"getMxDrawObject",value:function(){return this.mxcad.getMxDrawObject()}},{key:"initMapbox",value:function(l){this.map=l}},{key:"getMapbox",value:function(){return this.map}},{key:"mercatorCoord2CAD",value:function(l,n){var u=new THREE.Vector3(l,n,0);return u.applyMatrix4(this.imp.matMapToCad),u}},{key:"mercatorCoordToCAD",value:function(l,n){var u=new THREE.Vector3(l,n,0);return u.applyMatrix4(this.imp.matMapToCad),u}},{key:"cadToMercatorCoord",value:function(l){return l.applyMatrix4(this.imp.matCadToMap),l}},{key:"lnglatToCAD",value:function(l,n){var u=this.lnglat_to_mercator(l,n);return this.mercatorCoord2CAD(u.x,u.y)}},{key:"cadTolnglat",value:function(l){var n=this.cadToMercatorCoord(l);return this.mercator_to_lnglat(n.x,n.y,0)}},{key:"map_meters_to_lnglat",value:function(l,n){return l=l/200375083427892e-7*180,n=n/200375083427892e-7*180,n=180/Math.PI*(2*Math.atan(Math.exp(n*Math.PI/180))-Math.PI/2),[l,n]}},{key:"map_lnglat_to_meters",value:function(l,n){var u=l*200375083427892e-7/180,c=Math.log(Math.tan((90+n)*Math.PI/360))/(Math.PI/180);return c=c*200375083427892e-7/180,[u,c]}},{key:"lnglat_to_mercator",value:function(l,n){var u=this.map.lnglat_to_mercator(l,n);return new THREE.Vector3(u.x,u.y,0)}},{key:"mercator_to_lnglat",value:function(l,n,u){var c=this.map.mercator_to_lnglat(l,n,u);return[c.lng,c.lat]}},{key:"outOfChina",value:function(l,n){return!(l>73.66&&l<135.05&&n>3.86&&n<53.55)}},{key:"cadLongToMercatorCoord",value:function(l){var n=new THREE.Vector3(0,0,0),u=new THREE.Vector3(l,0,0);return n.applyMatrix4(this.imp.matCadToMap),u.applyMatrix4(this.imp.matCadToMap),n.distanceTo(u)}},{key:"setCoordinatePointAlignment",value:function(l,n,u){this.originCAD=n,this.originLngLatLike=l,this.meterInCADUnits=u}},{key:"create",value:function(){var e=_asyncToGenerator(regenerator.mark(function n(u,c){var y,b,m,O,N;return regenerator.wrap(function(G){for(;;)switch(G.prev=G.next){case 0:this.map=u,c.middlePan!==void 0&&this.map.dragPan.useMouseMiddle(c.middlePan),c.viewBackgroundColor===void 0&&(c.viewBackgroundColor={red:255,green:255,blue:255}),y=this,b=u.mercatorCoordinate_from_LngLat(y.originLngLatLike,y.modelAltitude),m=b.meterInMercatorCoordinateUnits(),O=y.imp,O.map=u,O.elevation=this.modelAltitude,O.mapOrigin=new THREE.Vector3(b.x,b.y,b.z),O.cadOrigin=new THREE.Vector3(this.originCAD[0],this.originCAD[1],0),O.mapLenInCADUnits=y.meterInCADUnits*m,N={id:"3d-model",type:"custom",renderingMode:"3d",onAdd:function(J,fe){return _asyncToGenerator(regenerator.mark(function ve(){var ne,Ue;return regenerator.wrap(function(Ve){for(;;)switch(Ve.prev=Ve.next){case 0:try{O.canvas=J.getCanvas(),O.gl=fe,O.canvasContainer=J.getCanvasContainer(),y.loadOldEditionMethod?(Ue=c,Ue.mapBox=O,Ue.isAutoResize=!0,Ue.callback=function(rt,Ae){_objectDestructuringEmpty(Ae),rt.addEvent("loadComplete",function(){y.map.triggerRepaint()})},MxFun.createMxObject(Ue)):(c.map=O,ne=c.onOpenFileComplete,c.onOpenFileComplete=function(rt){ne&&ne(rt),y.map.triggerRepaint()},c.onInit=function(){MxFun.setIniset({MapBox:!0})},createMxCad(c,y.mxcad))}catch(rt){console.log(rt)}case 1:case"end":return Ve.stop()}},ve)}))()},render:function(J,fe){O.map.repaint=!1,O.render&&O.render(J,fe)}},u.addLayer(N),u.on("resize",function(){O.onResize&&O.onResize()});case 15:case"end":return G.stop()}},n,this)}));function l(n,u){return e.apply(this,arguments)}return l}()}]),t}();function _createForOfIteratorHelper(t,e){var l=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!l){if(Array.isArray(t)||(l=_unsupportedIterableToArray2(t))||e){l&&(t=l);var n=0,u=function(){};return{s:u,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(O){throw O},f:u}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var c=!0,y=!1,b;return{s:function(){l=l.call(t)},n:function(){var O=l.next();return c=O.done,O},e:function(O){y=!0,b=O},f:function(){try{!c&&l.return!=null&&l.return()}finally{if(y)throw b}}}}function _unsupportedIterableToArray2(t,e){if(t){if(typeof t=="string")return _arrayLikeToArray2(t,e);var l=Object.prototype.toString.call(t).slice(8,-1);if(l==="Object"&&t.constructor&&(l=t.constructor.name),l==="Map"||l==="Set")return Array.from(t);if(l==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(l))return _arrayLikeToArray2(t,e)}}function _arrayLikeToArray2(t,e){(e==null||e>t.length)&&(e=t.length);for(var l=0,n=new Array(e);l<e;l++)n[l]=t[l];return n}Object.freeze=function(t){return t};var create$3=Object.create||function(){function t(){}return function(e){return t.prototype=e,new t}}();function setOptions(t,e){t.hasOwnProperty("options")||(t.options=t.options?create$3(t.options):{});for(var l in e)t.options[l]=e[l]||t.options[l];return t.options}var templateRe=/\{ *([\w_-]+) *\}/g;function template(t,e){return t.replace(templateRe,function(l,n){var u=e[n];if(u===void 0)throw new Error("No value provided for variable "+l);return typeof u=="function"&&(u=u(e)),u})}var isArray$2=Array.isArray||function(t){return Object.prototype.toString.call(t)==="[object Array]"},pi$1=3.141592653589793,a$1=6378245,ee$1=.006693421622965943,x_pi=pi$1*3e3/180;function lonLatToTileNumbers(t,e,l){var n=pi$1/180*e,u=Math.pow(2,l),c=parseInt((t+180)/360*u),y=parseInt((1-Math.asinh(Math.tan(n))/pi$1)/2*u);return[c,y]}function tileNumbersToLonLat(t,e,l){var n=Math.pow(2,l),u=t/n*360-180,c=Math.atan(Math.sinh(pi$1*(1-2*e/n))),y=c*180/pi$1;return[u,y]}function bd09_To_gps84(t,e){if(isArray$2(t)){var l=t[0];e=t[1],t=l}if(t instanceof Object){var l=t.lng;e=t.lat,t=l}var n=bd09_To_gcj02(t,e),u=gcj02_To_gps84(n.lng,n.lat);return u}function gps84_To_bd09(t,e){if(isArray$2(t)){var l=t[0];e=t[1],t=l}if(t instanceof Object){var l=t.lng;e=t.lat,t=l}var n=gps84_To_gcj02(t,e),u=gcj02_To_bd09(n.lng,n.lat);return u}function gps84_To_gcj02(t,e){if(isArray$2(t)){var l=t[0];e=t[1],t=l}if(t instanceof Object){var l=t.lng;e=t.lat,t=l}var n=transformLat$1(t-105,e-35),u=transformLng$1(t-105,e-35),c=e/180*pi$1,y=Math.sin(c);y=1-ee$1*y*y;var b=Math.sqrt(y);n=n*180/(a$1*(1-ee$1)/(y*b)*pi$1),u=u*180/(a$1/b*Math.cos(c)*pi$1);var m=e+n,O=t+u,N={lng:O,lat:m};return N}function gcj02_To_gps84(t,e){if(isArray$2(t)){var l=t[0];e=t[1],t=l}if(t instanceof Object){var l=t.lng;e=t.lat,t=l}var n=transform$1(t,e),u=t*2-n.lng,c=e*2-n.lat,y={lng:u,lat:c};return y}function gcj02_To_bd09(t,e){var l=Math.sqrt(t*t+e*e)+2e-5*Math.sin(e*x_pi),n=Math.atan2(e,t)+3e-6*Math.cos(t*x_pi),u=l*Math.cos(n)+.0065,c=l*Math.sin(n)+.006,y={lng:u,lat:c};return y}function bd09_To_gcj02(t,e){var l=t-.0065,n=e-.006,u=Math.sqrt(l*l+n*n)-2e-5*Math.sin(n*x_pi),c=Math.atan2(n,l)-3e-6*Math.cos(l*x_pi),y=u*Math.cos(c),b=u*Math.sin(c),m={lng:y,lat:b};return m}function transform$1(t,e){var l=transformLat$1(t-105,e-35),n=transformLng$1(t-105,e-35),u=e/180*pi$1,c=Math.sin(u);c=1-ee$1*c*c;var y=Math.sqrt(c);l=l*180/(a$1*(1-ee$1)/(c*y)*pi$1),n=n*180/(a$1/y*Math.cos(u)*pi$1);var b=e+l,m=t+n,O={lng:m,lat:b};return O}function transformLat$1(t,e){var l=-100+2*t+3*e+.2*e*e+.1*t*e+.2*Math.sqrt(Math.abs(t));return l+=(20*Math.sin(6*t*pi$1)+20*Math.sin(2*t*pi$1))*2/3,l+=(20*Math.sin(e*pi$1)+40*Math.sin(e/3*pi$1))*2/3,l+=(160*Math.sin(e/12*pi$1)+320*Math.sin(e*pi$1/30))*2/3,l}function transformLng$1(t,e){var l=300+t+2*e+.1*t*t+.1*t*e+.1*Math.sqrt(Math.abs(t));return l+=(20*Math.sin(6*t*pi$1)+20*Math.sin(2*t*pi$1))*2/3,l+=(20*Math.sin(t*pi$1)+40*Math.sin(t/3*pi$1))*2/3,l+=(150*Math.sin(t/12*pi$1)+300*Math.sin(t/30*pi$1))*2/3,l}function Extend(t,e){for(var l in e)e.hasOwnProperty(l)&&(t[l]=e[l]);return t}function S(t,e){for(var l in e)t[l]=e[l]}function Xa(t){return typeof t=="string"}var j$1=void 0,p$1=null;function H$1(t,e){isNaN(t)&&(t=Ib(t),t=isNaN(t)?0:t),Xa(t)&&(t=parseFloat(t)),isNaN(e)&&(e=Ib(e),e=isNaN(e)?0:e),Xa(e)&&(e=parseFloat(e)),this.lng=t,this.lat=e}H$1.TL=function(t){return t&&180>=t.lng&&-180<=t.lng&&74>=t.lat&&-74<=t.lat};H$1.prototype.lb=function(t){return t&&this.lat==t.lat&&this.lng==t.lng};function Q$1(t,e){this.x=t||0,this.y=e||0,this.x=this.x,this.y=this.y}Q$1.prototype.lb=function(t){return t&&t.x==this.x&&t.y==this.y};function fc(){}fc.prototype.nh=function(){aa("lngLatToPoint方法未实现")};fc.prototype.wi=function(){aa("pointToLngLat方法未实现")};function R$1(){}R$1.prototype=new fc;Extend(R$1,{$O:637099681e-2,lG:[1289059486e-2,836237787e-2,5591021,348198983e-2,167804312e-2,0],Au:[75,60,45,30,15,0],fP:[[1410526172116255e-23,898305509648872e-20,-1.9939833816331,200.9824383106796,-187.2403703815547,91.6087516669843,-23.38765649603339,2.57121317296198,-.03801003308653,173379812e-1],[-7435856389565537e-24,8983055097726239e-21,-.78625201886289,96.32687599759846,-1.85204757529826,-59.36935905485877,47.40033549296737,-16.50741931063887,2.28786674699375,1026014486e-2],[-3030883460898826e-23,898305509983578e-20,.30071316287616,59.74293618442277,7.357984074871,-25.38371002664745,13.45380521110908,-3.29883767235584,.32710905363475,685681737e-2],[-1981981304930552e-23,8983055099779535e-21,.03278182852591,40.31678527705744,.65659298677277,-4.44255534477492,.85341911805263,.12923347998204,-.04625736007561,448277706e-2],[309191371068437e-23,8983055096812155e-21,6995724062e-14,23.10934304144901,-.00023663490511,-.6321817810242,-.00663494467273,.03430082397953,-.00466043876332,25551644e-1],[2890871144776878e-24,8983055095805407e-21,-3068298e-14,7.47137025468032,-353937994e-14,-.02145144861037,-1234426596e-14,.00010322952773,-323890364e-14,826088.5]],iG:[[-.0015702102444,111320.7020616939,0x60e374c3105a3,-0x24bb4115e2e164,0x5cc55543bb0ae8,-0x7ce070193f3784,0x5e7ca61ddf8150,-0x261a578d8b24d0,0x665d60f3742ca,82.5],[.0008277824516172526,111320.7020463578,6477955746671607e-7,-4082003173641316e-6,1077490566351142e-5,-1517187553151559e-5,1205306533862167e-5,-5124939663577472e-6,9133119359512032e-7,67.5],[.00337398766765,111320.7020202162,4481351045890365e-9,-2339375119931662e-8,7968221547186455e-8,-1159649932797253e-7,9723671115602145e-8,-4366194633752821e-8,8477230501135234e-9,52.5],[.00220636496208,111320.7020209128,51751.86112841131,3796837749470245e-9,992013.7397791013,-122195221711287e-8,1340652697009075e-9,-620943.6990984312,144416.9293806241,37.5],[-.0003441963504368392,111320.7020576856,278.2353980772752,2485758690035394e-9,6070.750963243378,54821.18345352118,9540.606633304236,-2710.55326746645,1405.483844121726,22.5],[-.0003218135878613132,111320.7020701615,.00369383431289,823725.6402795718,.46104986909093,2351.343141331292,1.58060784298199,8.77738589078284,.37238884252424,7.45]],Z1:function t(c,l){if(!c||!l)return 0;var n,u,c=this.Fb(c);return c?(n=this.Tk(c.lng),u=this.Tk(c.lat),l=this.Fb(l),l?this.Pe(n,this.Tk(l.lng),u,this.Tk(l.lat)):0):0},Vo:function t(e,l){return!e||!l?0:(e.lng=this.JD(e.lng,-180,180),e.lat=this.ND(e.lat,-74,74),l.lng=this.JD(l.lng,-180,180),l.lat=this.ND(l.lat,-74,74),this.Pe(this.Tk(e.lng),this.Tk(l.lng),this.Tk(e.lat),this.Tk(l.lat)))},Fb:function t(e){if(e===p$1||e===j$1)return new H$1(0,0);var l,n;l=new H$1(Math.abs(e.lng),Math.abs(e.lat));for(var u=0;u<this.lG.length;u++)if(l.lat>=this.lG[u]){n=this.fP[u];break}return e=this.gK(e,n),e=new H$1(e.lng.toFixed(6),e.lat.toFixed(6))},Eb:function t(e){if(e===p$1||e===j$1||180<e.lng||-180>e.lng||90<e.lat||-90>e.lat)return new H$1(0,0);var l,n;e.lng=this.JD(e.lng,-180,180),e.lat=this.ND(e.lat,-74,74),l=new H$1(e.lng,e.lat);for(var u=0;u<this.Au.length;u++)if(l.lat>=this.Au[u]){n=this.iG[u];break}if(!n){for(u=0;u<this.Au.length;u++)if(l.lat<=-this.Au[u]){n=this.iG[u];break}}return e=this.gK(e,n),e=new H$1(e.lng.toFixed(2),e.lat.toFixed(2))},gK:function t(e,l){if(e&&l){var n=l[0]+l[1]*Math.abs(e.lng),u=Math.abs(e.lat)/l[9],u=l[2]+l[3]*u+l[4]*u*u+l[5]*u*u*u+l[6]*u*u*u*u+l[7]*u*u*u*u*u+l[8]*u*u*u*u*u*u,n=n*(0>e.lng?-1:1),u=u*(0>e.lat?-1:1);return new H$1(n,u)}},Pe:function t(e,l,n,u){return this.$O*Math.acos(Math.sin(n)*Math.sin(u)+Math.cos(n)*Math.cos(u)*Math.cos(l-e))},Tk:function t(e){return Math.PI*e/180},Z3:function t(e){return 180*e/Math.PI},ND:function t(e,l,n){return l!=p$1&&(e=Math.max(e,l)),n!=p$1&&(e=Math.min(e,n)),e},JD:function t(e,l,n){for(;e>n;)e-=n-l;for(;e<l;)e+=n-l;return e}});Extend(R$1.prototype,{Jm:function t(e){return R$1.Eb(e)},nh:function t(e){return e=R$1.Eb(e),new Q$1(e.lng,e.lat)},qh:function t(e){return R$1.Fb(e)},wi:function t(e){return e=new H$1(e.x,e.y),R$1.Fb(e)},fc:function t(e,l,n,u,c){if(e)return e=this.Jm(e,c),l=this.Lc(l),new Q$1(Math.round((e.lng-n.lng)/l+u.width/2),Math.round((n.lat-e.lat)/l+u.height/2))},zb:function t(e,l,n,u,c){if(e)return l=this.Lc(l),this.qh(new H$1(n.lng+l*(e.x-u.width/2),n.lat-l*(e.y-u.height/2)),c)},Lc:function t(e){return Math.pow(2,18-e)}});var Je=R$1.prototype;S(Je,{lngLatToPoint:Je.nh,pointToLngLat:Je.wi});var BMap={Point:H$1,Pixel:Q$1,MercatorProjection:R$1},TransformClassBaidu=function(){function t(e,l){_classCallCheck$1(this,t),this.levelMax=e,this.levelMin=l,this.projection=new BMap.MercatorProjection}return _createClass$1(t,[{key:"_getRetain",value:function(l){return Math.pow(2,l-18)}},{key:"getResolution",value:function(l,n){return Math.pow(2,18-n)*Math.cos(l)}},{key:"lnglatToPoint",value:function(l,n){var u=new BMap.Point(l,n),c=this.projection.lngLatToPoint(u);return{pointX:c.x,pointY:c.y}}},{key:"pointToLnglat",value:function(l,n){var u=new BMap.Pixel(l,n),c=this.projection.pointToLngLat(u);return{lng:c.lng,lat:c.lat}}},{key:"_lngToTileX",value:function(l,n){var u=this.lnglatToPoint(l,0),c=Math.floor(u.pointX*this._getRetain(n)/256);return c}},{key:"_latToTileY",value:function(l,n){var u=this.lnglatToPoint(0,l),c=Math.floor(u.pointY*this._getRetain(n)/256);return c}},{key:"lnglatToTile",value:function(l,n,u){var c=this._lngToTileX(l,u),y=this._latToTileY(n,u);return[c,y]}},{key:"_lngToPixelX",value:function(l,n){var u=this._lngToTileX(l,n),c=this.lnglatToPoint(l,0),y=Math.floor(c.pointX*this._getRetain(n)-u*256);return y}},{key:"_latToPixelY",value:function(l,n){var u=this._latToTileY(l,n),c=this.lnglatToPoint(0,l),y=Math.floor(c.pointY*this._getRetain(n)-u*256);return y}},{key:"lnglatToPixel",value:function(l,n,u){var c=this._lngToPixelX(l,u),y=this._latToPixelY(n,u);return{pixelX:c,pixelY:y}}},{key:"_pixelXToLng",value:function(l,n,u){var c=(n*256+l)/this._getRetain(u),y=this.pointToLnglat(c,0);return y.lng}},{key:"_pixelYToLat",value:function(l,n,u){var c=(n*256+l)/this._getRetain(u),y=this.pointToLnglat(0,c);return y.lat}},{key:"pixelToLnglat",value:function(l,n,u,c,y){var b=(u*256+l)/this._getRetain(y),m=(c*256+n)/this._getRetain(y),O=this.pointToLnglat(b,m);return[O.lng,O.lat]}}]),t}();function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _defineProperties(t,e){for(var l=0;l<e.length;l++){var n=e[l];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function _createClass(t,e,l){return e&&_defineProperties(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t}function _typeof$3(t){"@babel/helpers - typeof";return _typeof$3=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof$3(t)}function _assertThisInitialized(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function _possibleConstructorReturn(t,e){if(e&&(_typeof$3(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return _assertThisInitialized(t)}function _getPrototypeOf(t){return _getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf:function(l){return l.__proto__||Object.getPrototypeOf(l)},_getPrototypeOf(t)}function _setPrototypeOf(t,e){return _setPrototypeOf=Object.setPrototypeOf||function(n,u){return n.__proto__=u,n},_setPrototypeOf(t,e)}function _inherits(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&_setPrototypeOf(t,e)}function _arrayWithHoles(t){if(Array.isArray(t))return t}function _iterableToArrayLimit(t,e){var l=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(l!=null){var n=[],u=!0,c=!1,y,b;try{for(l=l.call(t);!(u=(y=l.next()).done)&&(n.push(y.value),!(e&&n.length===e));u=!0);}catch(m){c=!0,b=m}finally{try{!u&&l.return!=null&&l.return()}finally{if(c)throw b}}return n}}function _arrayLikeToArray(t,e){(e==null||e>t.length)&&(e=t.length);for(var l=0,n=new Array(e);l<e;l++)n[l]=t[l];return n}function _unsupportedIterableToArray(t,e){if(t){if(typeof t=="string")return _arrayLikeToArray(t,e);var l=Object.prototype.toString.call(t).slice(8,-1);if(l==="Object"&&t.constructor&&(l=t.constructor.name),l==="Map"||l==="Set")return Array.from(t);if(l==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(l))return _arrayLikeToArray(t,e)}}function _nonIterableRest(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function _slicedToArray(t,e){return _arrayWithHoles(t)||_iterableToArrayLimit(t,e)||_unsupportedIterableToArray(t,e)||_nonIterableRest()}var EPSILON=1e-6,ARRAY_TYPE$1=typeof Float32Array<"u"?Float32Array:Array;Math.hypot||(Math.hypot=function(){for(var t=0,e=arguments.length;e--;)t+=arguments[e]*arguments[e];return Math.sqrt(t)});function create$2(){var t=new ARRAY_TYPE$1(4);return ARRAY_TYPE$1!=Float32Array&&(t[0]=0,t[1]=0,t[2]=0,t[3]=0),t}function scale$1(t,e,l){return t[0]=e[0]*l,t[1]=e[1]*l,t[2]=e[2]*l,t[3]=e[3]*l,t}function transformMat4$1(t,e,l){var n=e[0],u=e[1],c=e[2],y=e[3];return t[0]=l[0]*n+l[4]*u+l[8]*c+l[12]*y,t[1]=l[1]*n+l[5]*u+l[9]*c+l[13]*y,t[2]=l[2]*n+l[6]*u+l[10]*c+l[14]*y,t[3]=l[3]*n+l[7]*u+l[11]*c+l[15]*y,t}(function(){var t=create$2();return function(e,l,n,u,c,y){var b,m;for(l||(l=4),n||(n=0),u?m=Math.min(u*l+n,e.length):m=e.length,b=n;b<m;b+=l)t[0]=e[b],t[1]=e[b+1],t[2]=e[b+2],t[3]=e[b+3],c(t,t,y),e[b]=t[0],e[b+1]=t[1],e[b+2]=t[2],e[b+3]=t[3];return e}})();function createMat4(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}function transformVector(t,e){var l=transformMat4$1([],e,t);return scale$1(l,l,1/l[3]),l}function invert(t,e){var l=e[0],n=e[1],u=e[2],c=e[3],y=e[4],b=e[5],m=e[6],O=e[7],N=e[8],L=e[9],G=e[10],q=e[11],J=e[12],fe=e[13],ve=e[14],ne=e[15],Ue=l*b-n*y,De=l*m-u*y,Ve=l*O-c*y,rt=n*m-u*b,Ae=n*O-c*b,Te=u*O-c*m,Xe=N*fe-L*J,ie=N*ve-G*J,ue=N*ne-q*J,pt=L*ve-G*fe,mt=L*ne-q*fe,Tt=G*ne-q*ve,kt=Ue*Tt-De*mt+Ve*pt+rt*ue-Ae*ie+Te*Xe;return kt?(kt=1/kt,t[0]=(b*Tt-m*mt+O*pt)*kt,t[1]=(u*mt-n*Tt-c*pt)*kt,t[2]=(fe*Te-ve*Ae+ne*rt)*kt,t[3]=(G*Ae-L*Te-q*rt)*kt,t[4]=(m*ue-y*Tt-O*ie)*kt,t[5]=(l*Tt-u*ue+c*ie)*kt,t[6]=(ve*Ve-J*Te-ne*De)*kt,t[7]=(N*Te-G*Ve+q*De)*kt,t[8]=(y*mt-b*ue+O*Xe)*kt,t[9]=(n*ue-l*mt-c*Xe)*kt,t[10]=(J*Ae-fe*Ve+ne*Ue)*kt,t[11]=(L*Ve-N*Ae-q*Ue)*kt,t[12]=(b*ie-y*pt-m*Xe)*kt,t[13]=(l*pt-n*ie+u*Xe)*kt,t[14]=(fe*De-J*rt-ve*Ue)*kt,t[15]=(N*rt-L*De+G*Ue)*kt,t):null}function multiply(t,e,l){var n=e[0],u=e[1],c=e[2],y=e[3],b=e[4],m=e[5],O=e[6],N=e[7],L=e[8],G=e[9],q=e[10],J=e[11],fe=e[12],ve=e[13],ne=e[14],Ue=e[15],De=l[0],Ve=l[1],rt=l[2],Ae=l[3];return t[0]=De*n+Ve*b+rt*L+Ae*fe,t[1]=De*u+Ve*m+rt*G+Ae*ve,t[2]=De*c+Ve*O+rt*q+Ae*ne,t[3]=De*y+Ve*N+rt*J+Ae*Ue,De=l[4],Ve=l[5],rt=l[6],Ae=l[7],t[4]=De*n+Ve*b+rt*L+Ae*fe,t[5]=De*u+Ve*m+rt*G+Ae*ve,t[6]=De*c+Ve*O+rt*q+Ae*ne,t[7]=De*y+Ve*N+rt*J+Ae*Ue,De=l[8],Ve=l[9],rt=l[10],Ae=l[11],t[8]=De*n+Ve*b+rt*L+Ae*fe,t[9]=De*u+Ve*m+rt*G+Ae*ve,t[10]=De*c+Ve*O+rt*q+Ae*ne,t[11]=De*y+Ve*N+rt*J+Ae*Ue,De=l[12],Ve=l[13],rt=l[14],Ae=l[15],t[12]=De*n+Ve*b+rt*L+Ae*fe,t[13]=De*u+Ve*m+rt*G+Ae*ve,t[14]=De*c+Ve*O+rt*q+Ae*ne,t[15]=De*y+Ve*N+rt*J+Ae*Ue,t}function translate(t,e,l){var n=l[0],u=l[1],c=l[2],y,b,m,O,N,L,G,q,J,fe,ve,ne;return e===t?(t[12]=e[0]*n+e[4]*u+e[8]*c+e[12],t[13]=e[1]*n+e[5]*u+e[9]*c+e[13],t[14]=e[2]*n+e[6]*u+e[10]*c+e[14],t[15]=e[3]*n+e[7]*u+e[11]*c+e[15]):(y=e[0],b=e[1],m=e[2],O=e[3],N=e[4],L=e[5],G=e[6],q=e[7],J=e[8],fe=e[9],ve=e[10],ne=e[11],t[0]=y,t[1]=b,t[2]=m,t[3]=O,t[4]=N,t[5]=L,t[6]=G,t[7]=q,t[8]=J,t[9]=fe,t[10]=ve,t[11]=ne,t[12]=y*n+N*u+J*c+e[12],t[13]=b*n+L*u+fe*c+e[13],t[14]=m*n+G*u+ve*c+e[14],t[15]=O*n+q*u+ne*c+e[15]),t}function scale(t,e,l){var n=l[0],u=l[1],c=l[2];return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t[3]=e[3]*n,t[4]=e[4]*u,t[5]=e[5]*u,t[6]=e[6]*u,t[7]=e[7]*u,t[8]=e[8]*c,t[9]=e[9]*c,t[10]=e[10]*c,t[11]=e[11]*c,t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}function rotateX(t,e,l){var n=Math.sin(l),u=Math.cos(l),c=e[4],y=e[5],b=e[6],m=e[7],O=e[8],N=e[9],L=e[10],G=e[11];return e!==t&&(t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[4]=c*u+O*n,t[5]=y*u+N*n,t[6]=b*u+L*n,t[7]=m*u+G*n,t[8]=O*u-c*n,t[9]=N*u-y*n,t[10]=L*u-b*n,t[11]=G*u-m*n,t}function rotateZ(t,e,l){var n=Math.sin(l),u=Math.cos(l),c=e[0],y=e[1],b=e[2],m=e[3],O=e[4],N=e[5],L=e[6],G=e[7];return e!==t&&(t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[0]=c*u+O*n,t[1]=y*u+N*n,t[2]=b*u+L*n,t[3]=m*u+G*n,t[4]=O*u-c*n,t[5]=N*u-y*n,t[6]=L*u-b*n,t[7]=G*u-m*n,t}function perspectiveNO(t,e,l,n,u){var c=1/Math.tan(e/2),y;return t[0]=c/l,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=c,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[11]=-1,t[12]=0,t[13]=0,t[15]=0,u!=null&&u!==1/0?(y=1/(n-u),t[10]=(u+n)*y,t[14]=2*u*n*y):(t[10]=-1,t[14]=-2*n),t}var perspective=perspectiveNO;function equals(t,e){var l=t[0],n=t[1],u=t[2],c=t[3],y=t[4],b=t[5],m=t[6],O=t[7],N=t[8],L=t[9],G=t[10],q=t[11],J=t[12],fe=t[13],ve=t[14],ne=t[15],Ue=e[0],De=e[1],Ve=e[2],rt=e[3],Ae=e[4],Te=e[5],Xe=e[6],ie=e[7],ue=e[8],pt=e[9],mt=e[10],Tt=e[11],kt=e[12],It=e[13],nn=e[14],tn=e[15];return Math.abs(l-Ue)<=EPSILON*Math.max(1,Math.abs(l),Math.abs(Ue))&&Math.abs(n-De)<=EPSILON*Math.max(1,Math.abs(n),Math.abs(De))&&Math.abs(u-Ve)<=EPSILON*Math.max(1,Math.abs(u),Math.abs(Ve))&&Math.abs(c-rt)<=EPSILON*Math.max(1,Math.abs(c),Math.abs(rt))&&Math.abs(y-Ae)<=EPSILON*Math.max(1,Math.abs(y),Math.abs(Ae))&&Math.abs(b-Te)<=EPSILON*Math.max(1,Math.abs(b),Math.abs(Te))&&Math.abs(m-Xe)<=EPSILON*Math.max(1,Math.abs(m),Math.abs(Xe))&&Math.abs(O-ie)<=EPSILON*Math.max(1,Math.abs(O),Math.abs(ie))&&Math.abs(N-ue)<=EPSILON*Math.max(1,Math.abs(N),Math.abs(ue))&&Math.abs(L-pt)<=EPSILON*Math.max(1,Math.abs(L),Math.abs(pt))&&Math.abs(G-mt)<=EPSILON*Math.max(1,Math.abs(G),Math.abs(mt))&&Math.abs(q-Tt)<=EPSILON*Math.max(1,Math.abs(q),Math.abs(Tt))&&Math.abs(J-kt)<=EPSILON*Math.max(1,Math.abs(J),Math.abs(kt))&&Math.abs(fe-It)<=EPSILON*Math.max(1,Math.abs(fe),Math.abs(It))&&Math.abs(ve-nn)<=EPSILON*Math.max(1,Math.abs(ve),Math.abs(nn))&&Math.abs(ne-tn)<=EPSILON*Math.max(1,Math.abs(ne),Math.abs(tn))}function create$1(){var t=new ARRAY_TYPE$1(2);return ARRAY_TYPE$1!=Float32Array&&(t[0]=0,t[1]=0),t}function add(t,e,l){return t[0]=e[0]+l[0],t[1]=e[1]+l[1],t}function negate$1(t,e){return t[0]=-e[0],t[1]=-e[1],t}function lerp(t,e,l,n){var u=e[0],c=e[1];return t[0]=u+n*(l[0]-u),t[1]=c+n*(l[1]-c),t}(function(){var t=create$1();return function(e,l,n,u,c,y){var b,m;for(l||(l=2),n||(n=0),u?m=Math.min(u*l+n,e.length):m=e.length,b=n;b<m;b+=l)t[0]=e[b],t[1]=e[b+1],c(t,t,y),e[b]=t[0],e[b+1]=t[1];return e}})();function create$4(){var t=new ARRAY_TYPE$1(3);return ARRAY_TYPE$1!=Float32Array&&(t[0]=0,t[1]=0,t[2]=0),t}function negate(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t}(function(){var t=create$4();return function(e,l,n,u,c,y){var b,m;for(l||(l=3),n||(n=0),u?m=Math.min(u*l+n,e.length):m=e.length,b=n;b<m;b+=l)t[0]=e[b],t[1]=e[b+1],t[2]=e[b+2],c(t,t,y),e[b]=t[0],e[b+1]=t[1],e[b+2]=t[2];return e}})();function assert(t,e){if(!t)throw new Error(e||"viewport-mercator-project: assertion failed.")}var PI$1=Math.PI,PI_4=PI$1/4,DEGREES_TO_RADIANS$1=PI$1/180,RADIANS_TO_DEGREES=180/PI$1,TILE_SIZE$1=512,EARTH_CIRCUMFERENCE$1=4003e4,DEFAULT_ALTITUDE=1.5;function zoomToScale$1(t){return Math.pow(2,t)}function lngLatToWorld(t,e){var l=_slicedToArray(t,2),n=l[0],u=l[1];assert(Number.isFinite(n)&&Number.isFinite(e)),assert(Number.isFinite(u)&&u>=-90&&u<=90,"invalid latitude"),e*=TILE_SIZE$1;var c=n*DEGREES_TO_RADIANS$1,y=u*DEGREES_TO_RADIANS$1,b=e*(c+PI$1)/(2*PI$1),m=e*(PI$1-Math.log(Math.tan(PI_4+y*.5)))/(2*PI$1);return[b,m]}function worldToLngLat(t,e){var l=_slicedToArray(t,2),n=l[0],u=l[1];e*=TILE_SIZE$1;var c=n/e*(2*PI$1)-PI$1,y=2*(Math.atan(Math.exp(PI$1-u/e*(2*PI$1)))-PI_4);return[c*RADIANS_TO_DEGREES,y*RADIANS_TO_DEGREES]}function getDistanceScales$1(t){var e=t.latitude,l=t.longitude,n=t.zoom,u=t.scale,c=t.highPrecision,y=c===void 0?!1:c;u=u!==void 0?u:zoomToScale$1(n),assert(Number.isFinite(e)&&Number.isFinite(l)&&Number.isFinite(u));var b={},m=TILE_SIZE$1*u,O=Math.cos(e*DEGREES_TO_RADIANS$1),N=m/360,L=N/O,G=m/EARTH_CIRCUMFERENCE$1/O;if(b.pixelsPerMeter=[G,-G,G],b.metersPerPixel=[1/G,-1/G,1/G],b.pixelsPerDegree=[N,-L,G],b.degreesPerPixel=[1/N,-1/L,1/G],y){var q=DEGREES_TO_RADIANS$1*Math.tan(e*DEGREES_TO_RADIANS$1)/O,J=N*q/2,fe=m/EARTH_CIRCUMFERENCE$1*q,ve=fe/L*G;b.pixelsPerDegree2=[0,-J,fe],b.pixelsPerMeter2=[ve,0,ve]}return b}function getViewMatrix(t){var e=t.height,l=t.pitch,n=t.bearing,u=t.altitude,c=t.center,y=c===void 0?null:c,b=t.flipY,m=b===void 0?!1:b,O=createMat4();return translate(O,O,[0,0,-u]),scale(O,O,[1,1,1/e]),rotateX(O,O,-l*DEGREES_TO_RADIANS$1),rotateZ(O,O,n*DEGREES_TO_RADIANS$1),m&&scale(O,O,[1,-1,1]),y&&translate(O,O,negate([],y)),O}function getProjectionParameters(t){var e=t.width,l=t.height,n=t.altitude,u=n===void 0?DEFAULT_ALTITUDE:n,c=t.pitch,y=c===void 0?0:c,b=t.nearZMultiplier,m=b===void 0?1:b,O=t.farZMultiplier,N=O===void 0?1:O,L=y*DEGREES_TO_RADIANS$1,G=Math.atan(.5/u),q=Math.sin(G)*u/Math.sin(Math.PI/2-L-G),J=Math.cos(Math.PI/2-L)*q+u;return{fov:2*Math.atan(l/2/u),aspect:e/l,focalDistance:u,near:m,far:J*N}}function getProjectionMatrix(t){var e=t.width,l=t.height,n=t.pitch,u=t.altitude,c=t.nearZMultiplier,y=t.farZMultiplier,b=getProjectionParameters({width:e,height:l,altitude:u,pitch:n,nearZMultiplier:c,farZMultiplier:y}),m=b.fov,O=b.aspect,N=b.near,L=b.far,G=perspective([],m,O,N,L);return G}function worldToPixels(t,e){var l=_slicedToArray(t,3),n=l[0],u=l[1],c=l[2],y=c===void 0?0:c;return assert(Number.isFinite(n)&&Number.isFinite(u)&&Number.isFinite(y)),transformVector(e,[n,u,y,1])}function pixelsToWorld(t,e){var l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,n=_slicedToArray(t,3),u=n[0],c=n[1],y=n[2];if(assert(Number.isFinite(u)&&Number.isFinite(c),"invalid pixel coordinate"),Number.isFinite(y)){var b=transformVector(e,[u,c,y,1]);return b}var m=transformVector(e,[u,c,0,1]),O=transformVector(e,[u,c,1,1]),N=m[2],L=O[2],G=N===L?0:((l||0)-N)/(L-N);return lerp([],m,O,G)}var IDENTITY=createMat4(),Viewport=function(){function t(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},l=e.width,n=e.height,u=e.viewMatrix,c=u===void 0?IDENTITY:u,y=e.projectionMatrix,b=y===void 0?IDENTITY:y;_classCallCheck(this,t),this.width=l||1,this.height=n||1,this.scale=1,this.pixelsPerMeter=1,this.viewMatrix=c,this.projectionMatrix=b;var m=createMat4();multiply(m,m,this.projectionMatrix),multiply(m,m,this.viewMatrix),this.viewProjectionMatrix=m;var O=createMat4();scale(O,O,[this.width/2,-this.height/2,1]),translate(O,O,[1,-1,0]),multiply(O,O,this.viewProjectionMatrix);var N=invert(createMat4(),O);if(!N)throw new Error("Pixel project matrix not invertible");this.pixelProjectionMatrix=O,this.pixelUnprojectionMatrix=N,this.equals=this.equals.bind(this),this.project=this.project.bind(this),this.unproject=this.unproject.bind(this),this.projectPosition=this.projectPosition.bind(this),this.unprojectPosition=this.unprojectPosition.bind(this),this.projectFlat=this.projectFlat.bind(this),this.unprojectFlat=this.unprojectFlat.bind(this)}return _createClass(t,[{key:"equals",value:function(l){return l instanceof t?l.width===this.width&&l.height===this.height&&equals(l.projectionMatrix,this.projectionMatrix)&&equals(l.viewMatrix,this.viewMatrix):!1}},{key:"project",value:function(l){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},u=n.topLeft,c=u===void 0?!0:u,y=this.projectPosition(l),b=worldToPixels(y,this.pixelProjectionMatrix),m=_slicedToArray(b,2),O=m[0],N=m[1],L=c?N:this.height-N;return l.length===2?[O,L]:[O,L,b[2]]}},{key:"unproject",value:function(l){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},u=n.topLeft,c=u===void 0?!0:u,y=n.targetZ,b=_slicedToArray(l,3),m=b[0],O=b[1],N=b[2],L=c?O:this.height-O,G=y&&y*this.pixelsPerMeter,q=pixelsToWorld([m,L,N],this.pixelUnprojectionMatrix,G),J=this.unprojectPosition(q),fe=_slicedToArray(J,3),ve=fe[0],ne=fe[1],Ue=fe[2];return Number.isFinite(N)?[ve,ne,Ue]:Number.isFinite(y)?[ve,ne,y]:[ve,ne]}},{key:"projectPosition",value:function(l){var n=this.projectFlat(l),u=_slicedToArray(n,2),c=u[0],y=u[1],b=(l[2]||0)*this.pixelsPerMeter;return[c,y,b]}},{key:"unprojectPosition",value:function(l){var n=this.unprojectFlat(l),u=_slicedToArray(n,2),c=u[0],y=u[1],b=(l[2]||0)/this.pixelsPerMeter;return[c,y,b]}},{key:"projectFlat",value:function(l){return arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.scale,l}},{key:"unprojectFlat",value:function(l){return arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.scale,l}}]),t}();function fitBounds(t){var e=t.width,l=t.height,n=t.bounds,u=t.minExtent,c=u===void 0?0:u,y=t.maxZoom,b=y===void 0?24:y,m=t.padding,O=m===void 0?0:m,N=t.offset,L=N===void 0?[0,0]:N,G=_slicedToArray(n,2),q=_slicedToArray(G[0],2),J=q[0],fe=q[1],ve=_slicedToArray(G[1],2),ne=ve[0],Ue=ve[1];if(Number.isFinite(O)){var De=O;O={top:De,bottom:De,left:De,right:De}}else assert(Number.isFinite(O.top)&&Number.isFinite(O.bottom)&&Number.isFinite(O.left)&&Number.isFinite(O.right));var Ve=new WebMercatorViewport({width:e,height:l,longitude:0,latitude:0,zoom:0}),rt=Ve.project([J,Ue]),Ae=Ve.project([ne,fe]),Te=[Math.max(Math.abs(Ae[0]-rt[0]),c),Math.max(Math.abs(Ae[1]-rt[1]),c)],Xe=[e-O.left-O.right-Math.abs(L[0])*2,l-O.top-O.bottom-Math.abs(L[1])*2];assert(Xe[0]>0&&Xe[1]>0);var ie=Xe[0]/Te[0],ue=Xe[1]/Te[1],pt=(O.right-O.left)/2/ie,mt=(O.bottom-O.top)/2/ue,Tt=[(Ae[0]+rt[0])/2+pt,(Ae[1]+rt[1])/2+mt],kt=Ve.unproject(Tt),It=Ve.zoom+Math.log2(Math.abs(Math.min(ie,ue)));return{longitude:kt[0],latitude:kt[1],zoom:Math.min(It,b)}}var WebMercatorViewport=function(t){_inherits(e,t);function e(){var l,n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},u=n.width,c=n.height,y=n.latitude,b=y===void 0?0:y,m=n.longitude,O=m===void 0?0:m,N=n.zoom,L=N===void 0?0:N,G=n.pitch,q=G===void 0?0:G,J=n.bearing,fe=J===void 0?0:J,ve=n.altitude,ne=ve===void 0?1.5:ve,Ue=n.nearZMultiplier,De=n.farZMultiplier;_classCallCheck(this,e),u=u||1,c=c||1;var Ve=zoomToScale$1(L);ne=Math.max(.75,ne);var rt=lngLatToWorld([O,b],Ve);rt[2]=0;var Ae=getProjectionMatrix({width:u,height:c,pitch:q,bearing:fe,altitude:ne,nearZMultiplier:Ue||1/c,farZMultiplier:De||1.01}),Te=getViewMatrix({height:c,center:rt,pitch:q,bearing:fe,altitude:ne,flipY:!0});return l=_possibleConstructorReturn(this,_getPrototypeOf(e).call(this,{width:u,height:c,viewMatrix:Te,projectionMatrix:Ae})),l.latitude=b,l.longitude=O,l.zoom=L,l.pitch=q,l.bearing=fe,l.altitude=ne,l.scale=Ve,l.center=rt,l.pixelsPerMeter=getDistanceScales$1(_assertThisInitialized(_assertThisInitialized(l))).pixelsPerMeter[2],Object.freeze(_assertThisInitialized(_assertThisInitialized(l))),l}return _createClass(e,[{key:"projectFlat",value:function(n){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.scale;return lngLatToWorld(n,u)}},{key:"unprojectFlat",value:function(n){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.scale;return worldToLngLat(n,u)}},{key:"getMapCenterByLngLatPosition",value:function(n){var u=n.lngLat,c=n.pos,y=pixelsToWorld(c,this.pixelUnprojectionMatrix),b=lngLatToWorld(u,this.scale),m=add([],b,negate$1([],y)),O=add([],this.center,m);return worldToLngLat(O,this.scale)}},{key:"getLocationAtPoint",value:function(n){var u=n.lngLat,c=n.pos;return this.getMapCenterByLngLatPosition({lngLat:u,pos:c})}},{key:"fitBounds",value:function(n){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},c=this.width,y=this.height,b=fitBounds(Object.assign({width:c,height:y,bounds:n},u)),m=b.longitude,O=b.latitude,N=b.zoom;return new e({width:c,height:y,longitude:m,latitude:O,zoom:N})}}]),e}(Viewport),PI=Math.PI,DEGREES_TO_RADIANS=PI/180,TILE_SIZE=512,EARTH_CIRCUMFERENCE=4003e4;function zoomToScale(t){return Math.pow(2,t)}function getDistanceScales(t){var e=t.latitude,l=e===void 0?0:e,n=t.zoom,u=n===void 0?1:n,c=t.scale,y=t.highPrecision,b=y===void 0?!1:y;c=c!==void 0?c:zoomToScale(u);var m={},O=TILE_SIZE*c*window.devicePixelRatio,N=Math.cos(l*DEGREES_TO_RADIANS),L=O/360,G=L/N,q=O/EARTH_CIRCUMFERENCE/N;if(m.pixelsPerMeter=[q,-q,q],m.metersPerPixel=[1/q,-1/q,1/q],m.pixelsPerDegree=[L,-G,q],m.degreesPerPixel=[1/L,-1/G,1/q],b){var J=DEGREES_TO_RADIANS*Math.tan(l*DEGREES_TO_RADIANS)/N,fe=L*J/2,ve=O/EARTH_CIRCUMFERENCE*J,ne=ve/G*q;m.pixelsPerDegree2=[0,-fe,ve],m.pixelsPerMeter2=[ne,0,ne]}return m}var customTileLayer=function(){function t(e,l,n){_classCallCheck$1(this,t),this.id=e,this.type="custom",this.renderingMode="2d",this.url=l,this.options={subdomains:null,minZoom:0,maxZoom:24,tileType:"xyz"},setOptions(this,n),this.program,this.showTiles=[],this.tileCache={},this.gridCache={},this.matrix,this.map,this.isLayerShow,this.transformBaidu=new TransformClassBaidu}return _createClass$1(t,[{key:"onAdd",value:function(l,n){var u=this;this.map=l;var c="uniform mat4 u_matrix;attribute vec2 a_pos;attribute vec2 a_TextCoord;varying vec2 v_TextCoord;const float TILE_SIZE = 512.0;const float PI = 3.1415926536;const float WORLD_SCALE = TILE_SIZE / (PI * 2.0);uniform float u_project_scale;uniform bool u_is_offset;uniform vec3 u_pixels_per_degree;uniform vec3 u_pixels_per_degree2;uniform vec3 u_pixels_per_meter;uniform vec2 u_viewport_center;uniform vec4 u_viewport_center_projection;uniform vec2 u_viewport_size;float project_scale(float meters) { return meters * u_pixels_per_meter.z;}vec3 project_scale(vec3 position) { return position * u_pixels_per_meter;}vec2 project_mercator(vec2 lnglat) { float x = lnglat.x; return vec2( radians(x) + PI, PI - log(tan(PI * 0.25 + radians(lnglat.y) * 0.5)) );}vec4 project_offset(vec4 offset) { float dy = offset.y; dy = clamp(dy, -1., 1.); vec3 pixels_per_unit = u_pixels_per_degree + u_pixels_per_degree2 * dy; return vec4(offset.xyz * pixels_per_unit, offset.w);}vec4 project_position(vec4 position) { if (u_is_offset) { float X = position.x - u_viewport_center.x; float Y = position.y - u_viewport_center.y; return project_offset(vec4(X, Y, position.z, position.w)); } else { return vec4( project_mercator(position.xy) * WORLD_SCALE * u_project_scale, project_scale(position.z), position.w ); }}vec4 project_to_clipping_space(vec3 position) { vec4 project_pos = project_position(vec4(position, 1.0)); return u_matrix * project_pos + u_viewport_center_projection;}void main() { vec4 project_pos = project_position(vec4(a_pos, 0.0, 1.0)); gl_Position = u_matrix * project_pos + u_viewport_center_projection; v_TextCoord = a_TextCoord;}",y="precision mediump float;uniform sampler2D u_Sampler; varying vec2 v_TextCoord; void main() { gl_FragColor = texture2D(u_Sampler, v_TextCoord);}",b=n.createShader(n.VERTEX_SHADER);n.shaderSource(b,c),n.compileShader(b);var m=n.createShader(n.FRAGMENT_SHADER);n.shaderSource(m,y),n.compileShader(m),this.program=n.createProgram(),n.attachShader(this.program,b),n.attachShader(this.program,m),n.linkProgram(this.program),this.a_Pos=n.getAttribLocation(this.program,"a_pos"),this.a_TextCoord=n.getAttribLocation(this.program,"a_TextCoord"),this.isLayerShow=!0,l.on("move",function(){u.isLayerShow&&u.update(n,l)}),this.update(n,l)}},{key:"update",value:function(l,n){var u=this,c=n.getCenter(),y,b=n.getBounds(),m,O;if(this.options.tileType==="xyz"){y=parseInt(n.getZoom()+1.4);var N=gps84_To_gcj02(b.getNorthWest()),L=gps84_To_gcj02(b.getSouthEast());m=lonLatToTileNumbers(N.lng,N.lat,y),O=lonLatToTileNumbers(L.lng,L.lat,y)}else if(this.options.tileType==="bd09"){y=parseInt(n.getZoom()+1.8);var G=gps84_To_bd09(b.getSouthWest()),q=gps84_To_bd09(b.getNorthEast());m=this.transformBaidu.lnglatToTile(G.lng,G.lat,y),O=this.transformBaidu.lnglatToTile(q.lng,q.lat,y)}for(var J=[],fe=m[0];fe<=O[0];fe++)for(var ve=m[1];ve<=O[1];ve++){var ne={x:fe,y:ve,z:y};J.push(ne),this.addGridCache(ne,0,0),fe===O[0]&&this.addGridCache(ne,1,0),ve===O[1]&&this.addGridCache(ne,0,1),fe===O[0]&&ve===O[1]&&this.addGridCache(ne,1,1)}if(this.options.tileType==="xyz")var Ue=lonLatToTileNumbers(c.lng,c.lat,y);else this.options.tileType==="bd09"&&(Ue=this.transformBaidu.lnglatToTile(c.lng,c.lat,y));J.sort(function(Ae,Te){return u.tileDistance(Ae,Ue)-u.tileDistance(Te,Ue)}),this.showTiles=[];for(var De=0,Ve=J;De<Ve.length;De++){var ne=Ve[De];if(this.tileCache[this.createTileKey(ne)])this.showTiles.push(this.tileCache[this.createTileKey(ne)]);else{var rt=this.createTile(l,ne);this.showTiles.push(rt),this.tileCache[this.createTileKey(ne)]=rt}}}},{key:"addGridCache",value:function(l,n,u){var c=this.createTileKey(l.x+n,l.y+u,l.z);this.gridCache[c]||(this.options.tileType==="xyz"?this.gridCache[c]=gcj02_To_gps84(tileNumbersToLonLat(l.x+n,l.y+u,l.z)):this.options.tileType==="bd09"&&(this.gridCache[c]=bd09_To_gps84(this.transformBaidu.pixelToLnglat(0,0,l.x+n,l.y+u,l.z))))}},{key:"tileDistance",value:function(l,n){return Math.sqrt(Math.pow(l.x-n[0],2)+Math.pow(l.y-n[1],2))}},{key:"createTileKey",value:function(l,n,u){if(l instanceof Object)return l.z+"/"+l.x+"/"+l.y;var c=l;return u+"/"+c+"/"+n}},{key:"createTile",value:function(l,n){var u=this,c=template(this.url,{s:this.options.subdomains[Math.abs(n.x+n.y)%this.options.subdomains.length],x:n.x,y:n.y,z:n.z}),y={xyz:n},b,m,O,N;this.options.tileType==="xyz"?(b=this.gridCache[this.createTileKey(n)],m=this.gridCache[this.createTileKey(n.x+1,n.y,n.z)],O=this.gridCache[this.createTileKey(n.x,n.y+1,n.z)],N=this.gridCache[this.createTileKey(n.x+1,n.y+1,n.z)]):this.options.tileType==="bd09"&&(b=this.gridCache[this.createTileKey(n.x,n.y+1,n.z)],m=this.gridCache[this.createTileKey(n.x+1,n.y+1,n.z)],O=this.gridCache[this.createTileKey(n)],N=this.gridCache[this.createTileKey(n.x+1,n.y,n.z)]);var L=new Float32Array([b.lng,b.lat,0,1,O.lng,O.lat,0,0,m.lng,m.lat,1,1,N.lng,N.lat,1,0]),G=L.BYTES_PER_ELEMENT,q=l.createBuffer();l.bindBuffer(l.ARRAY_BUFFER,q),l.bufferData(l.ARRAY_BUFFER,L,l.STATIC_DRAW),y.buffer=q,y.PosParam={size:2,stride:G*4,offset:0},y.TextCoordParam={size:2,stride:G*4,offset:G*2};var J=new Image;return J.onload=function(){y.texture=l.createTexture(),l.bindTexture(l.TEXTURE_2D,y.texture),l.pixelStorei(l.UNPACK_FLIP_Y_WEBGL,1),l.texImage2D(l.TEXTURE_2D,0,l.RGBA,l.RGBA,l.UNSIGNED_BYTE,J),y.isLoad=!0,u.map.triggerRepaint()},J.crossOrigin=!0,J.src=c,y}},{key:"render",value:function(l,n){if(!(this.map.getZoom()<this.options.minZoom||this.map.getZoom()>this.options.maxZoom)){this.matrix=n,l.useProgram(this.program);var u=_createForOfIteratorHelper(this.showTiles),c;try{for(u.s();!(c=u.n()).done;){var y=c.value;if(y.isLoad){l.bindTexture(l.TEXTURE_2D,y.texture),l.activeTexture(l.TEXTURE0),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_MIN_FILTER,l.LINEAR),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_S,l.CLAMP_TO_EDGE),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_T,l.MIRRORED_REPEAT);var b=l.getUniformLocation(this.program,"u_Sampler");l.uniform1i(b,0),l.bindBuffer(l.ARRAY_BUFFER,y.buffer),l.vertexAttribPointer(this.a_Pos,y.PosParam.size,l.FLOAT,!1,y.PosParam.stride,y.PosParam.offset),l.vertexAttribPointer(this.a_TextCoord,y.TextCoordParam.size,l.FLOAT,!1,y.TextCoordParam.stride,y.TextCoordParam.offset),l.enableVertexAttribArray(this.a_Pos),l.enableVertexAttribArray(this.a_TextCoord),this.setVertex(l),l.enable(l.BLEND),l.blendFunc(l.SRC_ALPHA,l.ONE_MINUS_SRC_ALPHA),l.drawArrays(l.TRIANGLE_STRIP,0,4)}}}catch(m){u.e(m)}finally{u.f()}}}},{key:"setVertex",value:function(l){var n=this.map.getZoom(),u=this.map.getBearing(),c=this.map.getPitch(),y=this.map.getCenter(),b=new WebMercatorViewport({width:l.drawingBufferWidth,height:l.drawingBufferHeight,longitude:y.lng,latitude:y.lat,zoom:n,pitch:c,bearing:u}),m=b.viewProjectionMatrix,O=b.projectionMatrix,N=b.viewMatrix,L=b.viewMatrixUncentered,G={u_matrix:m,u_point_size:this.pointSize,u_is_offset:!1,u_pixels_per_degree:[0,0,0],u_pixels_per_degree2:[0,0,0],u_viewport_center:[0,0],u_pixels_per_meter:[0,0,0],u_project_scale:zoomToScale(n),u_viewport_center_projection:[0,0,0,0]};if(n>0){var q=getDistanceScales({longitude:y.lng,latitude:y.lat,zoom:n,highPrecision:!0}),J=q.pixelsPerDegree,fe=q.pixelsPerDegree2,ve=b.projectFlat([Math.fround(y.lng),Math.fround(y.lat)],Math.pow(2,n)),ne=transformMat4$1([],[ve[0],ve[1],0,1],m),Ue=L||N,De=multiply([],O,Ue),Ve=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0];De=multiply([],De,Ve),G.u_matrix=De,G.u_is_offset=!0,G.u_viewport_center=[Math.fround(y.lng),Math.fround(y.lat)],G.u_viewport_center_projection=ne,G.u_pixels_per_degree=J&&J.map(function(rt){return Math.fround(rt)}),G.u_pixels_per_degree2=fe&&fe.map(function(rt){return Math.fround(rt)})}l.uniformMatrix4fv(l.getUniformLocation(this.program,"u_matrix"),!1,G.u_matrix),l.uniform1f(l.getUniformLocation(this.program,"u_project_scale"),G.u_project_scale),l.uniform1i(l.getUniformLocation(this.program,"u_is_offset"),G.u_is_offset?1:0),l.uniform3fv(l.getUniformLocation(this.program,"u_pixels_per_degree"),G.u_pixels_per_degree),l.uniform3fv(l.getUniformLocation(this.program,"u_pixels_per_degree2"),G.u_pixels_per_degree2),l.uniform3fv(l.getUniformLocation(this.program,"u_pixels_per_meter"),G.u_pixels_per_meter),l.uniform2fv(l.getUniformLocation(this.program,"u_viewport_center"),G.u_viewport_center),l.uniform4fv(l.getUniformLocation(this.program,"u_viewport_center_projection"),G.u_viewport_center_projection)}},{key:"onRemove",value:function(l,n){this.isLayerShow=!1}}]),t}();function RasterTileLayer(t,e,l,n){var u=l||{};n||(n={TianDiTu:{Normal:{Map:"http://t{s}.tianditu.com/DataServer?T=vec_w&X={x}&Y={y}&L={z}&tk={key}",Annotion:"http://t{s}.tianditu.com/DataServer?T=cva_w&X={x}&Y={y}&L={z}&tk={key}",minzoom:0,maxzoom:18},Satellite:{Map:"http://t{s}.tianditu.com/DataServer?T=img_w&X={x}&Y={y}&L={z}&tk={key}",Annotion:"http://t{s}.tianditu.com/DataServer?T=cia_w&X={x}&Y={y}&L={z}&tk={key}",minzoom:0,maxzoom:18},Terrain:{Map:"http://t{s}.tianditu.com/DataServer?T=ter_w&X={x}&Y={y}&L={z}&tk={key}",Annotion:"http://t{s}.tianditu.com/DataServer?T=cta_w&X={x}&Y={y}&L={z}&tk={key}",minzoom:0,maxzoom:14},Subdomains:["0","1","2","3","4","5","6","7"],key:""},GaoDe:{Normal:{Map:"http://webrd0{s}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}",minzoom:0,maxzoom:18},Normal_NoTag:{Map:"https://wprd0{s}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&style=7&scl=1<ype=11&x={x}&y={y}&z={z}",minzoom:3,maxzoom:18},Satellite:{Map:"http://webst0{s}.is.autonavi.com/appmaptile?style=6&x={x}&y={y}&z={z}",Annotion:"http://webst0{s}.is.autonavi.com/appmaptile?style=8&x={x}&y={y}&z={z}",minzoom:3,maxzoom:18},Subdomains:["1","2","3","4"]},Baidu:{Normal:{Map:"http://online{s}.map.bdimg.com/onlinelabel/?qt=tile&x={x}&y={y}&z={z}&styles=pl&scaler=1&p=1"},Satellite:{Map:"http://shangetu{s}.map.bdimg.com/it/u=x={x};y={y};z={z};v=009;type=sate&fm=46",Annotion:"http://online{s}.map.bdimg.com/tile/?qt=tile&x={x}&y={y}&z={z}&styles=sl&v=020"},Subdomains:"0123456789",tileType:"bd09"},Geoq:{Normal:{Map:"http://map.geoq.cn/ArcGIS/rest/services/ChinaOnlineCommunity/MapServer/tile/{z}/{y}/{x}",PurplishBlue:"http://map.geoq.cn/ArcGIS/rest/services/ChinaOnlineStreetPurplishBlue/MapServer/tile/{z}/{y}/{x}",Gray:"http://map.geoq.cn/ArcGIS/rest/services/ChinaOnlineStreetGray/MapServer/tile/{z}/{y}/{x}",Warm:"http://map.geoq.cn/ArcGIS/rest/services/ChinaOnlineStreetWarm/MapServer/tile/{z}/{y}/{x}",minzoom:3,maxzoom:16},Subdomains:[]},OSM:{Normal:{Map:"http://{s}.tile.osm.org/{z}/{x}/{y}.png",minzoom:0,maxzoom:18},Subdomains:["a","b","c"]}});var c=e.split("."),y=c[0],b=c[1],m=c[2],O=n[y][b][m],N=n[y].Subdomains,L=n[y][b].minzoom,G=n[y][b].maxzoom,q=n[y].tileType,J;if(y==="TianDiTu"||y==="OSM"){var fe=u.key||n[y].key,ve=[],ne=_createForOfIteratorHelper(N),Ue;try{for(ne.s();!(Ue=ne.n()).done;){var De=Ue.value;ve.push(O.replace("{s}",De).replace("{key}",fe))}}catch(Ve){ne.e(Ve)}finally{ne.f()}J={id:t,type:"raster",source:{type:"raster",tiles:ve,tileSize:256,minzoom:L,maxzoom:G}}}else J=new customTileLayer(t,O,{subdomains:N,minZoom:L,maxZoom:G,tileType:q});return J}var loadLayer=[];function MxMapAddRasterTileLayer(t,e,l,n){loadLayer.forEach(function(u){t.getLayer(u)&&t.removeLayer(u),t.getSource(u)&&t.removeSource(u)}),loadLayer=[],e.forEach(function(u){loadLayer.push(u[0]);var c=l?{key:l}:null,y=RasterTileLayer(u[0],u[1],c,n);t.addLayer(y,"mx.layer.fill")})}function MxMapAddGoogleCnLayer(t,e,l){e.forEach(function(n,u){if(n=="Image"){var c="https://gac-geo.googlecnapps.cn/maps/vt?lyrs=s&x={x}&y={y}&z={z}";l&&u<l.length&&(c=l[u]),t.addLayer({id:"GoogleImageLayer",type:"raster",source:{type:"raster",tiles:[c],tileSize:256}})}else if(n=="Lable"){var y="https://gac-geo.googlecnapps.cn/maps/vt?lyrs=s,m&gl=CN&x={x}&y={y}&z={z}";l&&u<l.length&&(y=l[u]),t.addLayer({id:"GoogleImageLableLayer",type:"raster",source:{type:"raster",tiles:[y],tileSize:256}})}})}var pi=3.141592653589793,a=6378245,ee$2=.006693421622965943;function transformLat(t,e){var l=-100+2*t+3*e+.2*e*e+.1*t*e+.2*Math.sqrt(Math.abs(t));return l+=(20*Math.sin(6*t*pi)+20*Math.sin(2*t*pi))*2/3,l+=(20*Math.sin(e*pi)+40*Math.sin(e/3*pi))*2/3,l+=(160*Math.sin(e/12*pi)+320*Math.sin(e*pi/30))*2/3,l}function transformLng(t,e){var l=300+t+2*e+.1*t*t+.1*t*e+.1*Math.sqrt(Math.abs(t));return l+=(20*Math.sin(6*t*pi)+20*Math.sin(2*t*pi))*2/3,l+=(20*Math.sin(t*pi)+40*Math.sin(t/3*pi))*2/3,l+=(150*Math.sin(t/12*pi)+300*Math.sin(t/30*pi))*2/3,l}function transform$2(t,e){var l=transformLat(t-105,e-35),n=transformLng(t-105,e-35),u=e/180*pi,c=Math.sin(u);c=1-ee$2*c*c;var y=Math.sqrt(c);l=l*180/(a*(1-ee$2)/(c*y)*pi),n=n*180/(a/y*Math.cos(u)*pi);var b=e+l,m=t+n,O={lng:m,lat:b};return O}function mx_gps84_To_gcj02(t,e){if(t instanceof Object){var l=t.lng;e=t.lat,t=l}var n=transformLat(t-105,e-35),u=transformLng(t-105,e-35),c=e/180*pi,y=Math.sin(c);y=1-ee$2*y*y;var b=Math.sqrt(y);n=n*180/(a*(1-ee$2)/(y*b)*pi),u=u*180/(a/b*Math.cos(c)*pi);var m=e+n,O=t+u,N={lng:O,lat:m};return N}function mx_gcj02_To_gps84(t,e){if(t instanceof Object){var l=t.lng;e=t.lat,t=l}var n=transform$2(t,e),u=t*2-n.lng,c=e*2-n.lat,y={lng:u,lat:c};return y}const mxcad=Object.freeze(Object.defineProperty({__proto__:null,b64Encode,b64Decode,saveAsFileDialog,downloadFile,downloadFileFromUrl,getJsonFromUrl,getFileFromUrl,_ML_String,IsZero,postMemoryFile,postEmscriptenIndexedDBFile,createCursor,MxTools,McGePoint3d,McGeVector3d,McGeMatrix3d,McGeLongArray,McGeStringArray,McGePoint3dArray,McGeDoubleArray,McGeBound,MxCoordConvertType,get MxCoordConvert(){return MxCoordConvert},getFilterImp,MxCADResbuf,MxCADUtilityClass,MxCADUtility,MxCADSelectionSetStatus,MxCADSelectionSet,MxCADUiPrBase,MxCADUiPrPoint,MxCADUiPrDist,MxCADUiPrAngle,MxCADUiPrInt,MxCADUiPrKeyWord,MxCADUiPrString,MxCADUiPrEntity,McRxObject,McObjectIdType,McObjectId,McDbObject,McDbObjectArray,DxfCode,get McDb(){return McDb},McCmColor,McDbLinetypeTableRecord,McDbDimStyleTableRecord,McDbTextStyleTableRecord,McDbLayerTableRecord,McDbLayerTable,McDbLinetypeTable,McDbDimStyleTable,McDbTextStyleTable,McDbDatabase,McDbBlockTableRecord,McDbBlockTable,McDbRasterImageDef,McDbDictionary,McDbXrecord,McDbGroup,McDbEntity,McDbCurve,McDbLine,McDbText,McDbAttribute,McDbAttributeDefinition,McDbMText,McDbCircle,McDbPolyline,McDbBlockReference,McDbSpatialFilter,McDbDimension,McDbAlignedDimension,McDbRotatedDimension,McDb2LineAngularDimension,McDbArc,McDbEllipse,McDbPoint,McDbHatch,McDbProxyEntity,McDbRasterImage,McDbWipeout,McDbBackgroundEntity,FetchAttributes,McObject,McAppType,MxCppType,MxCADPluginMapDefaultData,MxCADPluginSampleCode,MxCADPluginBase,MxPropertiesWindowCustomValueType,MxPropertiesWindowCustomValue,MxPropertiesWindowCustom,MxCompare,MxModifyColor,MxCADCloneType,IMcDbDwgFiler,MxCADWorldDraw,McDbCustomEntity,get MxCpp(){return MxCpp},loadMxCADassembly,MxCheckTheBrowser,Mx_About,createMxCad,ColorMethod:ColorMethod$1,ColorIndexType,getColorUtils,createMcCmColor,setMcCmColor,drawText,drawCircle,drawLine,drawMText,drawPolyLine,drawPolygon,drawArc,drawEllipticalArc,Mx_Erase,drawRectang,get MdGe(){return MdGe},MxApp3D,MxCAD3DObject,Mx3dApplication,Mx3dBaseObject,Mx3dDimObject,Mx3dSymbolObject,Mx3dAlgoObject,Mx3dAspectObject,Mx3dGeObject,Mx3dGeCurve,Mx3dGeConic,Mx3dGePoint,Mx3dGeTrsf,Mx3dGeAxis,Mx3dGeDir,Mx3dGeEllipse,Mx3dGeHyperbola,Mx3dGeVec,Mx3dGeBndBox,Mx3dGeCircle,Mx3dShapeObject,Mx3dShapeFace,Mx3dShapeVertex,Mx3dShapeEdge,Mx3dShapeWire,Mx3dShapeShell,Mx3dShapeSolid,Mx3dShapeCompSolid,Mx3dShapeCompound,Mx3dAlgoFillet,Mx3dAlgoChamfer,Mx3dAlgoFillet2d,Mx3dDbObject,Mx3dView,Mx3dGeColor,Mx3dGeCSYS,Mx3dGeCSYSR,Mx3dGeCylinder,Mx3dDbDocument,Mx3dDbLabel,Mx3dGeLocation,Mx3dGePlane,Mx3dSymbolText,Mx3dShapeDownCast,Mx3dBrepCastGeom,Mx3dUtils,Mx3dGeLine,Mx3dGeomObject,Mx3dGeomCurve,Mx3dGeomConic,Mx3dGeomCircle,Mx3dGeomLine,Mx3dGeomEllipse,Mx3dGeomHyperbola,Mx3dGeomParabola,Mx3dMkObject,Mx3dMkBox,Mx3dMkCone,Mx3dMkCylinder,Mx3dMkRevol,Mx3dMkSphere,Mx3dMkTorus,Mx3dMkPipe,Mx3dMkPrism,Mx3dMkWedge,Mx3dMkLoft,Mx3dMkPolygon,Mx3dMkFace,Mx3dMkThickSolid,Mx3dWireTool,Mx3dGeomBoundedCurve,Mx3dGeomBSplineCurve,Mx3dGeomBezierCurve,Mx3dGeomSurface,Mx3dGeomElementarySurface,Mx3dGeomPlane,Mx3dGeomConicalSurface,Mx3dGeomCylindricalSurface,Mx3dGeomSphericalSurface,Mx3dGeomToroidalSurface,Mx3dGeomBoundedSurface,Mx3dGeomBSplineSurface,Mx3dGeomBezierSurface,Mx3dGeMaterial,Mx3dAspectLine,Mx3dAspectText,Mx3dAspectArrow,Mx3dAspectDim,Mx3dDimDiameter,Mx3dDimRadius,Mx3dDimAngle,Mx3dDimLength,Mx3dInterpolateBSplineCurve,MxMap,MxMapAddRasterTileLayer,MxMapAddGoogleCnLayer,mx_gps84_To_gcj02,mx_gcj02_To_gps84},Symbol.toStringTag,{value:"Module"}));globalThis.Buffer=buffer$1.Buffer;globalThis.Buffer.alloc=buffer$1.Buffer.alloc;globalThis.Buffer.from=buffer$1.Buffer.from;const MxCAD=Object.freeze(Object.defineProperty({__proto__:null,ColorIndexType,ColorMethod:ColorMethod$1,DxfCode,FetchAttributes,IMcDbDwgFiler,IsZero,McAppType,McCmColor,get McDb(){return McDb},McDb2LineAngularDimension,McDbAlignedDimension,McDbArc,McDbAttribute,McDbAttributeDefinition,McDbBackgroundEntity,McDbBlockReference,McDbBlockTable,McDbBlockTableRecord,McDbCircle,McDbCurve,McDbCustomEntity,McDbDatabase,McDbDictionary,McDbDimStyleTable,McDbDimStyleTableRecord,McDbDimension,McDbEllipse,McDbEntity,McDbGroup,McDbHatch,McDbLayerTable,McDbLayerTableRecord,McDbLine,McDbLinetypeTable,McDbLinetypeTableRecord,McDbMText,McDbObject,McDbObjectArray,McDbPoint,McDbPolyline,McDbProxyEntity,McDbRasterImage,McDbRasterImageDef,McDbRotatedDimension,McDbSpatialFilter,McDbText,McDbTextStyleTable,McDbTextStyleTableRecord,McDbWipeout,McDbXrecord,McGeBound,McGeDoubleArray,McGeLongArray,McGeMatrix3d,McGePoint3d,McGePoint3dArray,McGeStringArray,McGeVector3d,McObject,McObjectId,McObjectIdType,McRxObject,get MdGe(){return MdGe},Mx3dAlgoChamfer,Mx3dAlgoFillet,Mx3dAlgoFillet2d,Mx3dAlgoObject,Mx3dApplication,Mx3dAspectArrow,Mx3dAspectDim,Mx3dAspectLine,Mx3dAspectObject,Mx3dAspectText,Mx3dBaseObject,Mx3dBrepCastGeom,Mx3dDbDocument,Mx3dDbLabel,Mx3dDbObject,Mx3dDimAngle,Mx3dDimDiameter,Mx3dDimLength,Mx3dDimObject,Mx3dDimRadius,Mx3dGeAxis,Mx3dGeBndBox,Mx3dGeCSYS,Mx3dGeCSYSR,Mx3dGeCircle,Mx3dGeColor,Mx3dGeConic,Mx3dGeCurve,Mx3dGeCylinder,Mx3dGeDir,Mx3dGeEllipse,Mx3dGeHyperbola,Mx3dGeLine,Mx3dGeLocation,Mx3dGeMaterial,Mx3dGeObject,Mx3dGePlane,Mx3dGePoint,Mx3dGeTrsf,Mx3dGeVec,Mx3dGeomBSplineCurve,Mx3dGeomBSplineSurface,Mx3dGeomBezierCurve,Mx3dGeomBezierSurface,Mx3dGeomBoundedCurve,Mx3dGeomBoundedSurface,Mx3dGeomCircle,Mx3dGeomConic,Mx3dGeomConicalSurface,Mx3dGeomCurve,Mx3dGeomCylindricalSurface,Mx3dGeomElementarySurface,Mx3dGeomEllipse,Mx3dGeomHyperbola,Mx3dGeomLine,Mx3dGeomObject,Mx3dGeomParabola,Mx3dGeomPlane,Mx3dGeomSphericalSurface,Mx3dGeomSurface,Mx3dGeomToroidalSurface,Mx3dInterpolateBSplineCurve,Mx3dMkBox,Mx3dMkCone,Mx3dMkCylinder,Mx3dMkFace,Mx3dMkLoft,Mx3dMkObject,Mx3dMkPipe,Mx3dMkPolygon,Mx3dMkPrism,Mx3dMkRevol,Mx3dMkSphere,Mx3dMkThickSolid,Mx3dMkTorus,Mx3dMkWedge,Mx3dShapeCompSolid,Mx3dShapeCompound,Mx3dShapeDownCast,Mx3dShapeEdge,Mx3dShapeFace,Mx3dShapeObject,Mx3dShapeShell,Mx3dShapeSolid,Mx3dShapeVertex,Mx3dShapeWire,Mx3dSymbolObject,Mx3dSymbolText,Mx3dUtils,Mx3dView,Mx3dWireTool,MxApp3D,MxCAD3DObject,MxCADCloneType,MxCADPluginBase,MxCADPluginMapDefaultData,MxCADPluginSampleCode,MxCADResbuf,MxCADSelectionSet,MxCADSelectionSetStatus,MxCADUiPrAngle,MxCADUiPrBase,MxCADUiPrDist,MxCADUiPrEntity,MxCADUiPrInt,MxCADUiPrKeyWord,MxCADUiPrPoint,MxCADUiPrString,MxCADUtility,MxCADUtilityClass,MxCADWorldDraw,MxCheckTheBrowser,MxCompare,get MxCoordConvert(){return MxCoordConvert},MxCoordConvertType,get MxCpp(){return MxCpp},MxCppType,MxMap,MxMapAddGoogleCnLayer,MxMapAddRasterTileLayer,MxModifyColor,MxPropertiesWindowCustom,MxPropertiesWindowCustomValue,MxPropertiesWindowCustomValueType,MxTools,Mx_About,Mx_Erase,_ML_String,b64Decode,b64Encode,createCursor,createMcCmColor,createMxCad,default:mxcad,downloadFile,downloadFileFromUrl,drawArc,drawCircle,drawEllipticalArc,drawLine,drawMText,drawPolyLine,drawPolygon,drawRectang,drawText,getColorUtils,getFileFromUrl,getFilterImp,getJsonFromUrl,loadMxCADassembly,mx_gcj02_To_gps84,mx_gps84_To_gcj02,postEmscriptenIndexedDBFile,postMemoryFile,saveAsFileDialog,setMcCmColor},Symbol.toStringTag,{value:"Module"})),isElectron=()=>!1,configMap=new Map,getConfig=async t=>{if(configMap.has(t))return configMap.get(t);try{const e=await(await fetch(t)).json();return configMap.set(t,e),e}catch(e){console.error("error Config:"+t,e)}};let serverConfig;const fetchServerConfig=async()=>{serverConfig||(serverConfig=await getConfig(new URL(""+new URL("../mxServerConfig.json",import.meta.url).href,import.meta.url).href))},getUploadFileConfig=()=>serverConfig?.uploadFileConfig,getWasmConfig=()=>serverConfig?.wasmConfig,getAiConfig=()=>serverConfig?.aiConfig;function isSupportTruetypeFont(){let t=serverConfig?.supportTruetypeFont;return t??!0}function isWebgl1(){let t=MxFun.getQueryString("webgl_ver");if(t&&t.length>0)return t=="1";let e=serverConfig?.webgl1;return e??!1}function getHostUrl$1(){let t=window.location.hostname;return t.substring(0,4)!="http"&&(t=document.location.protocol+"//"+t),t}function getBaseUrl(){let{baseUrl:t=""}=getUploadFileConfig()||{};return t.substring(0,16)=="http://localhost"&&(t=getHostUrl$1()+t.substring(16)),t}function getUrlConfig(){let{baseUrl:t="",saveDwgUrl:e="",mxfilepath:l="",saveUrl:n="",printPdfUrl:u="",cutDwgUrl:c=""}=getUploadFileConfig()||{};return t.substring(0,16)=="http://localhost"&&(t=getHostUrl$1()+t.substring(16)),e.substring(0,16)=="http://localhost"&&(e=getHostUrl$1()+e.substring(16)),n.substring(0,16)=="http://localhost"&&(n=getHostUrl$1()+n.substring(16)),u.substring(0,16)=="http://localhost"&&(u=getHostUrl$1()+u.substring(16)),c.substring(0,16)=="http://localhost"&&(c=getHostUrl$1()+c.substring(16)),{baseUrl:t,saveDwgUrl:e,mxfilepath:l,saveUrl:n,printPdfUrl:u,cutDwgUrl:c}}const getDatabase=()=>MxCpp.getCurrentMxCAD().getDatabase();var colorString$1={exports:{}},colorName={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]},simpleSwizzle={exports:{}},isArrayish$1=function t(e){return!e||typeof e=="string"?!1:e instanceof Array||Array.isArray(e)||e.length>=0&&(e.splice instanceof Function||Object.getOwnPropertyDescriptor(e,e.length-1)&&e.constructor.name!=="String")},isArrayish=isArrayish$1,concat=Array.prototype.concat,slice=Array.prototype.slice,swizzle$1=simpleSwizzle.exports=function t(e){for(var l=[],n=0,u=e.length;n<u;n++){var c=e[n];isArrayish(c)?l=concat.call(l,slice.call(c)):l.push(c)}return l};swizzle$1.wrap=function(t){return function(){return t(swizzle$1(arguments))}};var simpleSwizzleExports=simpleSwizzle.exports,colorNames=colorName,swizzle=simpleSwizzleExports,hasOwnProperty$1=Object.hasOwnProperty,reverseNames=Object.create(null);for(var name$1 in colorNames)hasOwnProperty$1.call(colorNames,name$1)&&(reverseNames[colorNames[name$1]]=name$1);var cs=colorString$1.exports={to:{},get:{}};cs.get=function(t){var e=t.substring(0,3).toLowerCase(),l,n;switch(e){case"hsl":l=cs.get.hsl(t),n="hsl";break;case"hwb":l=cs.get.hwb(t),n="hwb";break;default:l=cs.get.rgb(t),n="rgb";break}return l?{model:n,value:l}:null};cs.get.rgb=function(t){if(!t)return null;var e=/^#([a-f0-9]{3,4})$/i,l=/^#([a-f0-9]{6})([a-f0-9]{2})?$/i,n=/^rgba?\(\s*([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/,u=/^rgba?\(\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/,c=/^(\w+)$/,y=[0,0,0,1],b,m,O;if(b=t.match(l)){for(O=b[2],b=b[1],m=0;m<3;m++){var N=m*2;y[m]=parseInt(b.slice(N,N+2),16)}O&&(y[3]=parseInt(O,16)/255)}else if(b=t.match(e)){for(b=b[1],O=b[3],m=0;m<3;m++)y[m]=parseInt(b[m]+b[m],16);O&&(y[3]=parseInt(O+O,16)/255)}else if(b=t.match(n)){for(m=0;m<3;m++)y[m]=parseInt(b[m+1],0);b[4]&&(b[5]?y[3]=parseFloat(b[4])*.01:y[3]=parseFloat(b[4]))}else if(b=t.match(u)){for(m=0;m<3;m++)y[m]=Math.round(parseFloat(b[m+1])*2.55);b[4]&&(b[5]?y[3]=parseFloat(b[4])*.01:y[3]=parseFloat(b[4]))}else return(b=t.match(c))?b[1]==="transparent"?[0,0,0,0]:hasOwnProperty$1.call(colorNames,b[1])?(y=colorNames[b[1]],y[3]=1,y):null:null;for(m=0;m<3;m++)y[m]=clamp$1(y[m],0,255);return y[3]=clamp$1(y[3],0,1),y};cs.get.hsl=function(t){if(!t)return null;var e=/^hsla?\(\s*([+-]?(?:\d{0,3}\.)?\d+)(?:deg)?\s*,?\s*([+-]?[\d\.]+)%\s*,?\s*([+-]?[\d\.]+)%\s*(?:[,|\/]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/,l=t.match(e);if(l){var n=parseFloat(l[4]),u=(parseFloat(l[1])%360+360)%360,c=clamp$1(parseFloat(l[2]),0,100),y=clamp$1(parseFloat(l[3]),0,100),b=clamp$1(isNaN(n)?1:n,0,1);return[u,c,y,b]}return null};cs.get.hwb=function(t){if(!t)return null;var e=/^hwb\(\s*([+-]?\d{0,3}(?:\.\d+)?)(?:deg)?\s*,\s*([+-]?[\d\.]+)%\s*,\s*([+-]?[\d\.]+)%\s*(?:,\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/,l=t.match(e);if(l){var n=parseFloat(l[4]),u=(parseFloat(l[1])%360+360)%360,c=clamp$1(parseFloat(l[2]),0,100),y=clamp$1(parseFloat(l[3]),0,100),b=clamp$1(isNaN(n)?1:n,0,1);return[u,c,y,b]}return null};cs.to.hex=function(){var t=swizzle(arguments);return"#"+hexDouble(t[0])+hexDouble(t[1])+hexDouble(t[2])+(t[3]<1?hexDouble(Math.round(t[3]*255)):"")};cs.to.rgb=function(){var t=swizzle(arguments);return t.length<4||t[3]===1?"rgb("+Math.round(t[0])+", "+Math.round(t[1])+", "+Math.round(t[2])+")":"rgba("+Math.round(t[0])+", "+Math.round(t[1])+", "+Math.round(t[2])+", "+t[3]+")"};cs.to.rgb.percent=function(){var t=swizzle(arguments),e=Math.round(t[0]/255*100),l=Math.round(t[1]/255*100),n=Math.round(t[2]/255*100);return t.length<4||t[3]===1?"rgb("+e+"%, "+l+"%, "+n+"%)":"rgba("+e+"%, "+l+"%, "+n+"%, "+t[3]+")"};cs.to.hsl=function(){var t=swizzle(arguments);return t.length<4||t[3]===1?"hsl("+t[0]+", "+t[1]+"%, "+t[2]+"%)":"hsla("+t[0]+", "+t[1]+"%, "+t[2]+"%, "+t[3]+")"};cs.to.hwb=function(){var t=swizzle(arguments),e="";return t.length>=4&&t[3]!==1&&(e=", "+t[3]),"hwb("+t[0]+", "+t[1]+"%, "+t[2]+"%"+e+")"};cs.to.keyword=function(t){return reverseNames[t.slice(0,3)]};function clamp$1(t,e,l){return Math.min(Math.max(e,t),l)}function hexDouble(t){var e=Math.round(t).toString(16).toUpperCase();return e.length<2?"0"+e:e}var colorStringExports=colorString$1.exports;const cssKeywords=colorName,reverseKeywords={};for(const t of Object.keys(cssKeywords))reverseKeywords[cssKeywords[t]]=t;const convert$2={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};var conversions$2=convert$2;for(const t of Object.keys(convert$2)){if(!("channels"in convert$2[t]))throw new Error("missing channels property: "+t);if(!("labels"in convert$2[t]))throw new Error("missing channel labels property: "+t);if(convert$2[t].labels.length!==convert$2[t].channels)throw new Error("channel and label counts mismatch: "+t);const{channels:e,labels:l}=convert$2[t];delete convert$2[t].channels,delete convert$2[t].labels,Object.defineProperty(convert$2[t],"channels",{value:e}),Object.defineProperty(convert$2[t],"labels",{value:l})}convert$2.rgb.hsl=function(t){const e=t[0]/255,l=t[1]/255,n=t[2]/255,u=Math.min(e,l,n),c=Math.max(e,l,n),y=c-u;let b,m;c===u?b=0:e===c?b=(l-n)/y:l===c?b=2+(n-e)/y:n===c&&(b=4+(e-l)/y),b=Math.min(b*60,360),b<0&&(b+=360);const O=(u+c)/2;return c===u?m=0:O<=.5?m=y/(c+u):m=y/(2-c-u),[b,m*100,O*100]};convert$2.rgb.hsv=function(t){let e,l,n,u,c;const y=t[0]/255,b=t[1]/255,m=t[2]/255,O=Math.max(y,b,m),N=O-Math.min(y,b,m),L=function(G){return(O-G)/6/N+1/2};return N===0?(u=0,c=0):(c=N/O,e=L(y),l=L(b),n=L(m),y===O?u=n-l:b===O?u=1/3+e-n:m===O&&(u=2/3+l-e),u<0?u+=1:u>1&&(u-=1)),[u*360,c*100,O*100]};convert$2.rgb.hwb=function(t){const e=t[0],l=t[1];let n=t[2];const u=convert$2.rgb.hsl(t)[0],c=1/255*Math.min(e,Math.min(l,n));return n=1-1/255*Math.max(e,Math.max(l,n)),[u,c*100,n*100]};convert$2.rgb.cmyk=function(t){const e=t[0]/255,l=t[1]/255,n=t[2]/255,u=Math.min(1-e,1-l,1-n),c=(1-e-u)/(1-u)||0,y=(1-l-u)/(1-u)||0,b=(1-n-u)/(1-u)||0;return[c*100,y*100,b*100,u*100]};function comparativeDistance(t,e){return(t[0]-e[0])**2+(t[1]-e[1])**2+(t[2]-e[2])**2}convert$2.rgb.keyword=function(t){const e=reverseKeywords[t];if(e)return e;let l=1/0,n;for(const u of Object.keys(cssKeywords)){const c=cssKeywords[u],y=comparativeDistance(t,c);y<l&&(l=y,n=u)}return n};convert$2.keyword.rgb=function(t){return cssKeywords[t]};convert$2.rgb.xyz=function(t){let e=t[0]/255,l=t[1]/255,n=t[2]/255;e=e>.04045?((e+.055)/1.055)**2.4:e/12.92,l=l>.04045?((l+.055)/1.055)**2.4:l/12.92,n=n>.04045?((n+.055)/1.055)**2.4:n/12.92;const u=e*.4124+l*.3576+n*.1805,c=e*.2126+l*.7152+n*.0722,y=e*.0193+l*.1192+n*.9505;return[u*100,c*100,y*100]};convert$2.rgb.lab=function(t){const e=convert$2.rgb.xyz(t);let l=e[0],n=e[1],u=e[2];l/=95.047,n/=100,u/=108.883,l=l>.008856?l**(1/3):7.787*l+16/116,n=n>.008856?n**(1/3):7.787*n+16/116,u=u>.008856?u**(1/3):7.787*u+16/116;const c=116*n-16,y=500*(l-n),b=200*(n-u);return[c,y,b]};convert$2.hsl.rgb=function(t){const e=t[0]/360,l=t[1]/100,n=t[2]/100;let u,c,y;if(l===0)return y=n*255,[y,y,y];n<.5?u=n*(1+l):u=n+l-n*l;const b=2*n-u,m=[0,0,0];for(let O=0;O<3;O++)c=e+1/3*-(O-1),c<0&&c++,c>1&&c--,6*c<1?y=b+(u-b)*6*c:2*c<1?y=u:3*c<2?y=b+(u-b)*(2/3-c)*6:y=b,m[O]=y*255;return m};convert$2.hsl.hsv=function(t){const e=t[0];let l=t[1]/100,n=t[2]/100,u=l;const c=Math.max(n,.01);n*=2,l*=n<=1?n:2-n,u*=c<=1?c:2-c;const y=(n+l)/2,b=n===0?2*u/(c+u):2*l/(n+l);return[e,b*100,y*100]};convert$2.hsv.rgb=function(t){const e=t[0]/60,l=t[1]/100;let n=t[2]/100;const u=Math.floor(e)%6,c=e-Math.floor(e),y=255*n*(1-l),b=255*n*(1-l*c),m=255*n*(1-l*(1-c));switch(n*=255,u){case 0:return[n,m,y];case 1:return[b,n,y];case 2:return[y,n,m];case 3:return[y,b,n];case 4:return[m,y,n];case 5:return[n,y,b]}};convert$2.hsv.hsl=function(t){const e=t[0],l=t[1]/100,n=t[2]/100,u=Math.max(n,.01);let c,y;y=(2-l)*n;const b=(2-l)*u;return c=l*u,c/=b<=1?b:2-b,c=c||0,y/=2,[e,c*100,y*100]};convert$2.hwb.rgb=function(t){const e=t[0]/360;let l=t[1]/100,n=t[2]/100;const u=l+n;let c;u>1&&(l/=u,n/=u);const y=Math.floor(6*e),b=1-n;c=6*e-y,y&1&&(c=1-c);const m=l+c*(b-l);let O,N,L;switch(y){default:case 6:case 0:O=b,N=m,L=l;break;case 1:O=m,N=b,L=l;break;case 2:O=l,N=b,L=m;break;case 3:O=l,N=m,L=b;break;case 4:O=m,N=l,L=b;break;case 5:O=b,N=l,L=m;break}return[O*255,N*255,L*255]};convert$2.cmyk.rgb=function(t){const e=t[0]/100,l=t[1]/100,n=t[2]/100,u=t[3]/100,c=1-Math.min(1,e*(1-u)+u),y=1-Math.min(1,l*(1-u)+u),b=1-Math.min(1,n*(1-u)+u);return[c*255,y*255,b*255]};convert$2.xyz.rgb=function(t){const e=t[0]/100,l=t[1]/100,n=t[2]/100;let u,c,y;return u=e*3.2406+l*-1.5372+n*-.4986,c=e*-.9689+l*1.8758+n*.0415,y=e*.0557+l*-.204+n*1.057,u=u>.0031308?1.055*u**(1/2.4)-.055:u*12.92,c=c>.0031308?1.055*c**(1/2.4)-.055:c*12.92,y=y>.0031308?1.055*y**(1/2.4)-.055:y*12.92,u=Math.min(Math.max(0,u),1),c=Math.min(Math.max(0,c),1),y=Math.min(Math.max(0,y),1),[u*255,c*255,y*255]};convert$2.xyz.lab=function(t){let e=t[0],l=t[1],n=t[2];e/=95.047,l/=100,n/=108.883,e=e>.008856?e**(1/3):7.787*e+16/116,l=l>.008856?l**(1/3):7.787*l+16/116,n=n>.008856?n**(1/3):7.787*n+16/116;const u=116*l-16,c=500*(e-l),y=200*(l-n);return[u,c,y]};convert$2.lab.xyz=function(t){const e=t[0],l=t[1],n=t[2];let u,c,y;c=(e+16)/116,u=l/500+c,y=c-n/200;const b=c**3,m=u**3,O=y**3;return c=b>.008856?b:(c-16/116)/7.787,u=m>.008856?m:(u-16/116)/7.787,y=O>.008856?O:(y-16/116)/7.787,u*=95.047,c*=100,y*=108.883,[u,c,y]};convert$2.lab.lch=function(t){const e=t[0],l=t[1],n=t[2];let u;u=Math.atan2(n,l)*360/2/Math.PI,u<0&&(u+=360);const y=Math.sqrt(l*l+n*n);return[e,y,u]};convert$2.lch.lab=function(t){const e=t[0],l=t[1],u=t[2]/360*2*Math.PI,c=l*Math.cos(u),y=l*Math.sin(u);return[e,c,y]};convert$2.rgb.ansi16=function(t,e=null){const[l,n,u]=t;let c=e===null?convert$2.rgb.hsv(t)[2]:e;if(c=Math.round(c/50),c===0)return 30;let y=30+(Math.round(u/255)<<2|Math.round(n/255)<<1|Math.round(l/255));return c===2&&(y+=60),y};convert$2.hsv.ansi16=function(t){return convert$2.rgb.ansi16(convert$2.hsv.rgb(t),t[2])};convert$2.rgb.ansi256=function(t){const e=t[0],l=t[1],n=t[2];return e===l&&l===n?e<8?16:e>248?231:Math.round((e-8)/247*24)+232:16+36*Math.round(e/255*5)+6*Math.round(l/255*5)+Math.round(n/255*5)};convert$2.ansi16.rgb=function(t){let e=t%10;if(e===0||e===7)return t>50&&(e+=3.5),e=e/10.5*255,[e,e,e];const l=(~~(t>50)+1)*.5,n=(e&1)*l*255,u=(e>>1&1)*l*255,c=(e>>2&1)*l*255;return[n,u,c]};convert$2.ansi256.rgb=function(t){if(t>=232){const c=(t-232)*10+8;return[c,c,c]}t-=16;let e;const l=Math.floor(t/36)/5*255,n=Math.floor((e=t%36)/6)/5*255,u=e%6/5*255;return[l,n,u]};convert$2.rgb.hex=function(t){const l=(((Math.round(t[0])&255)<<16)+((Math.round(t[1])&255)<<8)+(Math.round(t[2])&255)).toString(16).toUpperCase();return"000000".substring(l.length)+l};convert$2.hex.rgb=function(t){const e=t.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!e)return[0,0,0];let l=e[0];e[0].length===3&&(l=l.split("").map(b=>b+b).join(""));const n=parseInt(l,16),u=n>>16&255,c=n>>8&255,y=n&255;return[u,c,y]};convert$2.rgb.hcg=function(t){const e=t[0]/255,l=t[1]/255,n=t[2]/255,u=Math.max(Math.max(e,l),n),c=Math.min(Math.min(e,l),n),y=u-c;let b,m;return y<1?b=c/(1-y):b=0,y<=0?m=0:u===e?m=(l-n)/y%6:u===l?m=2+(n-e)/y:m=4+(e-l)/y,m/=6,m%=1,[m*360,y*100,b*100]};convert$2.hsl.hcg=function(t){const e=t[1]/100,l=t[2]/100,n=l<.5?2*e*l:2*e*(1-l);let u=0;return n<1&&(u=(l-.5*n)/(1-n)),[t[0],n*100,u*100]};convert$2.hsv.hcg=function(t){const e=t[1]/100,l=t[2]/100,n=e*l;let u=0;return n<1&&(u=(l-n)/(1-n)),[t[0],n*100,u*100]};convert$2.hcg.rgb=function(t){const e=t[0]/360,l=t[1]/100,n=t[2]/100;if(l===0)return[n*255,n*255,n*255];const u=[0,0,0],c=e%1*6,y=c%1,b=1-y;let m=0;switch(Math.floor(c)){case 0:u[0]=1,u[1]=y,u[2]=0;break;case 1:u[0]=b,u[1]=1,u[2]=0;break;case 2:u[0]=0,u[1]=1,u[2]=y;break;case 3:u[0]=0,u[1]=b,u[2]=1;break;case 4:u[0]=y,u[1]=0,u[2]=1;break;default:u[0]=1,u[1]=0,u[2]=b}return m=(1-l)*n,[(l*u[0]+m)*255,(l*u[1]+m)*255,(l*u[2]+m)*255]};convert$2.hcg.hsv=function(t){const e=t[1]/100,l=t[2]/100,n=e+l*(1-e);let u=0;return n>0&&(u=e/n),[t[0],u*100,n*100]};convert$2.hcg.hsl=function(t){const e=t[1]/100,n=t[2]/100*(1-e)+.5*e;let u=0;return n>0&&n<.5?u=e/(2*n):n>=.5&&n<1&&(u=e/(2*(1-n))),[t[0],u*100,n*100]};convert$2.hcg.hwb=function(t){const e=t[1]/100,l=t[2]/100,n=e+l*(1-e);return[t[0],(n-e)*100,(1-n)*100]};convert$2.hwb.hcg=function(t){const e=t[1]/100,n=1-t[2]/100,u=n-e;let c=0;return u<1&&(c=(n-u)/(1-u)),[t[0],u*100,c*100]};convert$2.apple.rgb=function(t){return[t[0]/65535*255,t[1]/65535*255,t[2]/65535*255]};convert$2.rgb.apple=function(t){return[t[0]/255*65535,t[1]/255*65535,t[2]/255*65535]};convert$2.gray.rgb=function(t){return[t[0]/100*255,t[0]/100*255,t[0]/100*255]};convert$2.gray.hsl=function(t){return[0,0,t[0]]};convert$2.gray.hsv=convert$2.gray.hsl;convert$2.gray.hwb=function(t){return[0,100,t[0]]};convert$2.gray.cmyk=function(t){return[0,0,0,t[0]]};convert$2.gray.lab=function(t){return[t[0],0,0]};convert$2.gray.hex=function(t){const e=Math.round(t[0]/100*255)&255,n=((e<<16)+(e<<8)+e).toString(16).toUpperCase();return"000000".substring(n.length)+n};convert$2.rgb.gray=function(t){return[(t[0]+t[1]+t[2])/3/255*100]};const conversions$1=conversions$2;function buildGraph(){const t={},e=Object.keys(conversions$1);for(let l=e.length,n=0;n<l;n++)t[e[n]]={distance:-1,parent:null};return t}function deriveBFS(t){const e=buildGraph(),l=[t];for(e[t].distance=0;l.length;){const n=l.pop(),u=Object.keys(conversions$1[n]);for(let c=u.length,y=0;y<c;y++){const b=u[y],m=e[b];m.distance===-1&&(m.distance=e[n].distance+1,m.parent=n,l.unshift(b))}}return e}function link(t,e){return function(l){return e(t(l))}}function wrapConversion(t,e){const l=[e[t].parent,t];let n=conversions$1[e[t].parent][t],u=e[t].parent;for(;e[u].parent;)l.unshift(e[u].parent),n=link(conversions$1[e[u].parent][u],n),u=e[u].parent;return n.conversion=l,n}var route$1=function(t){const e=deriveBFS(t),l={},n=Object.keys(e);for(let u=n.length,c=0;c<u;c++){const y=n[c];e[y].parent!==null&&(l[y]=wrapConversion(y,e))}return l};const conversions=conversions$2,route=route$1,convert$1={},models=Object.keys(conversions);function wrapRaw(t){const e=function(...l){const n=l[0];return n==null?n:(n.length>1&&(l=n),t(l))};return"conversion"in t&&(e.conversion=t.conversion),e}function wrapRounded(t){const e=function(...l){const n=l[0];if(n==null)return n;n.length>1&&(l=n);const u=t(l);if(typeof u=="object")for(let c=u.length,y=0;y<c;y++)u[y]=Math.round(u[y]);return u};return"conversion"in t&&(e.conversion=t.conversion),e}models.forEach(t=>{convert$1[t]={},Object.defineProperty(convert$1[t],"channels",{value:conversions[t].channels}),Object.defineProperty(convert$1[t],"labels",{value:conversions[t].labels});const e=route(t);Object.keys(e).forEach(n=>{const u=e[n];convert$1[t][n]=wrapRounded(u),convert$1[t][n].raw=wrapRaw(u)})});var colorConvert=convert$1;const colorString=colorStringExports,convert=colorConvert,skippedModels=["keyword","gray","hex"],hashedModelKeys={};for(const t of Object.keys(convert))hashedModelKeys[[...convert[t].labels].sort().join("")]=t;const limiters={};function Color(t,e){if(!(this instanceof Color))return new Color(t,e);if(e&&e in skippedModels&&(e=null),e&&!(e in convert))throw new Error("Unknown model: "+e);let l,n;if(t==null)this.model="rgb",this.color=[0,0,0],this.valpha=1;else if(t instanceof Color)this.model=t.model,this.color=[...t.color],this.valpha=t.valpha;else if(typeof t=="string"){const u=colorString.get(t);if(u===null)throw new Error("Unable to parse color from string: "+t);this.model=u.model,n=convert[this.model].channels,this.color=u.value.slice(0,n),this.valpha=typeof u.value[n]=="number"?u.value[n]:1}else if(t.length>0){this.model=e||"rgb",n=convert[this.model].channels;const u=Array.prototype.slice.call(t,0,n);this.color=zeroArray(u,n),this.valpha=typeof t[n]=="number"?t[n]:1}else if(typeof t=="number")this.model="rgb",this.color=[t>>16&255,t>>8&255,t&255],this.valpha=1;else{this.valpha=1;const u=Object.keys(t);"alpha"in t&&(u.splice(u.indexOf("alpha"),1),this.valpha=typeof t.alpha=="number"?t.alpha:0);const c=u.sort().join("");if(!(c in hashedModelKeys))throw new Error("Unable to parse color from object: "+JSON.stringify(t));this.model=hashedModelKeys[c];const{labels:y}=convert[this.model],b=[];for(l=0;l<y.length;l++)b.push(t[y[l]]);this.color=zeroArray(b)}if(limiters[this.model])for(n=convert[this.model].channels,l=0;l<n;l++){const u=limiters[this.model][l];u&&(this.color[l]=u(this.color[l]))}this.valpha=Math.max(0,Math.min(1,this.valpha)),Object.freeze&&Object.freeze(this)}Color.prototype={toString(){return this.string()},toJSON(){return this[this.model]()},string(t){let e=this.model in colorString.to?this:this.rgb();e=e.round(typeof t=="number"?t:1);const l=e.valpha===1?e.color:[...e.color,this.valpha];return colorString.to[e.model](l)},percentString(t){const e=this.rgb().round(typeof t=="number"?t:1),l=e.valpha===1?e.color:[...e.color,this.valpha];return colorString.to.rgb.percent(l)},array(){return this.valpha===1?[...this.color]:[...this.color,this.valpha]},object(){const t={},{channels:e}=convert[this.model],{labels:l}=convert[this.model];for(let n=0;n<e;n++)t[l[n]]=this.color[n];return this.valpha!==1&&(t.alpha=this.valpha),t},unitArray(){const t=this.rgb().color;return t[0]/=255,t[1]/=255,t[2]/=255,this.valpha!==1&&t.push(this.valpha),t},unitObject(){const t=this.rgb().object();return t.r/=255,t.g/=255,t.b/=255,this.valpha!==1&&(t.alpha=this.valpha),t},round(t){return t=Math.max(t||0,0),new Color([...this.color.map(roundToPlace(t)),this.valpha],this.model)},alpha(t){return t!==void 0?new Color([...this.color,Math.max(0,Math.min(1,t))],this.model):this.valpha},red:getset("rgb",0,maxfn(255)),green:getset("rgb",1,maxfn(255)),blue:getset("rgb",2,maxfn(255)),hue:getset(["hsl","hsv","hsl","hwb","hcg"],0,t=>(t%360+360)%360),saturationl:getset("hsl",1,maxfn(100)),lightness:getset("hsl",2,maxfn(100)),saturationv:getset("hsv",1,maxfn(100)),value:getset("hsv",2,maxfn(100)),chroma:getset("hcg",1,maxfn(100)),gray:getset("hcg",2,maxfn(100)),white:getset("hwb",1,maxfn(100)),wblack:getset("hwb",2,maxfn(100)),cyan:getset("cmyk",0,maxfn(100)),magenta:getset("cmyk",1,maxfn(100)),yellow:getset("cmyk",2,maxfn(100)),black:getset("cmyk",3,maxfn(100)),x:getset("xyz",0,maxfn(95.047)),y:getset("xyz",1,maxfn(100)),z:getset("xyz",2,maxfn(108.833)),l:getset("lab",0,maxfn(100)),a:getset("lab",1),b:getset("lab",2),keyword(t){return t!==void 0?new Color(t):convert[this.model].keyword(this.color)},hex(t){return t!==void 0?new Color(t):colorString.to.hex(this.rgb().round().color)},hexa(t){if(t!==void 0)return new Color(t);const e=this.rgb().round().color;let l=Math.round(this.valpha*255).toString(16).toUpperCase();return l.length===1&&(l="0"+l),colorString.to.hex(e)+l},rgbNumber(){const t=this.rgb().color;return(t[0]&255)<<16|(t[1]&255)<<8|t[2]&255},luminosity(){const t=this.rgb().color,e=[];for(const[l,n]of t.entries()){const u=n/255;e[l]=u<=.04045?u/12.92:((u+.055)/1.055)**2.4}return .2126*e[0]+.7152*e[1]+.0722*e[2]},contrast(t){const e=this.luminosity(),l=t.luminosity();return e>l?(e+.05)/(l+.05):(l+.05)/(e+.05)},level(t){const e=this.contrast(t);return e>=7?"AAA":e>=4.5?"AA":""},isDark(){const t=this.rgb().color;return(t[0]*2126+t[1]*7152+t[2]*722)/1e4<128},isLight(){return!this.isDark()},negate(){const t=this.rgb();for(let e=0;e<3;e++)t.color[e]=255-t.color[e];return t},lighten(t){const e=this.hsl();return e.color[2]+=e.color[2]*t,e},darken(t){const e=this.hsl();return e.color[2]-=e.color[2]*t,e},saturate(t){const e=this.hsl();return e.color[1]+=e.color[1]*t,e},desaturate(t){const e=this.hsl();return e.color[1]-=e.color[1]*t,e},whiten(t){const e=this.hwb();return e.color[1]+=e.color[1]*t,e},blacken(t){const e=this.hwb();return e.color[2]+=e.color[2]*t,e},grayscale(){const t=this.rgb().color,e=t[0]*.3+t[1]*.59+t[2]*.11;return Color.rgb(e,e,e)},fade(t){return this.alpha(this.valpha-this.valpha*t)},opaquer(t){return this.alpha(this.valpha+this.valpha*t)},rotate(t){const e=this.hsl();let l=e.color[0];return l=(l+t)%360,l=l<0?360+l:l,e.color[0]=l,e},mix(t,e){if(!t||!t.rgb)throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof t);const l=t.rgb(),n=this.rgb(),u=e===void 0?.5:e,c=2*u-1,y=l.alpha()-n.alpha(),b=((c*y===-1?c:(c+y)/(1+c*y))+1)/2,m=1-b;return Color.rgb(b*l.red()+m*n.red(),b*l.green()+m*n.green(),b*l.blue()+m*n.blue(),l.alpha()*u+n.alpha()*(1-u))}};for(const t of Object.keys(convert)){if(skippedModels.includes(t))continue;const{channels:e}=convert[t];Color.prototype[t]=function(...l){return this.model===t?new Color(this):l.length>0?new Color(l,t):new Color([...assertArray(convert[this.model][t].raw(this.color)),this.valpha],t)},Color[t]=function(...l){let n=l[0];return typeof n=="number"&&(n=zeroArray(l,e)),new Color(n,t)}}function roundTo(t,e){return Number(t.toFixed(e))}function roundToPlace(t){return function(e){return roundTo(e,t)}}function getset(t,e,l){t=Array.isArray(t)?t:[t];for(const n of t)(limiters[n]||(limiters[n]=[]))[e]=l;return t=t[0],function(n){let u;return n!==void 0?(l&&(n=l(n)),u=this[t](),u.color[e]=n,u):(u=this[t]().color[e],l&&(u=l(u)),u)}}function maxfn(t){return function(e){return Math.max(0,Math.min(t,e))}}function assertArray(t){return Array.isArray(t)?t:[t]}function zeroArray(t,e){for(let l=0;l<e;l++)typeof t[l]!="number"&&(t[l]=0);return t}var color$1=Color;const Color$1=getDefaultExportFromCjs(color$1);new Color$1;var ColorMethod=(t=>(t[t.kByLayer=1]="kByLayer",t[t.kByBlock=2]="kByBlock",t[t.kByColor=3]="kByColor",t[t.kByACI=4]="kByACI",t[t.kByPen=5]="kByPen",t[t.kForeground=6]="kForeground",t[t.kLayerOff=7]="kLayerOff",t[t.kLayerFrozen=8]="kLayerFrozen",t[t.kNone=9]="kNone",t))(ColorMethod||{}),ColorNameType=(t=>(t[t.随块=0]="随块",t[t.红色=1]="红色",t[t.黄色=2]="黄色",t[t.绿色=3]="绿色",t[t.青色=4]="青色",t[t.蓝色=5]="蓝色",t[t.洋红色=6]="洋红色",t[t.白色=7]="白色",t[t.随层=256]="随层",t))(ColorNameType||{});const getColorName=t=>{if(t===-1)return;const e=ColorNameType[t];return e||t.toString()},createMxColor=t=>{const e=new McCmColor;if(t){const{red:l,green:n,blue:u,method:c}=t;e.setRGB(l,n,u),e.method=c;let y=indexOfMxColor(l,n,u,!1);y!=-1&&(e.colorIndex=y,e.method=4)}return e},toRGB=t=>Math.abs(t),reverseRGB=t=>t===0?255:t,toRGBCss=(t,e=!1)=>{let{red:l,green:n,blue:u,method:c,colorIndex:y}=t;return`rgb(${toRGB(l)}, ${toRGB(n)}, ${toRGB(u)})`},indexOfMxColor=(...t)=>{const[e,l,n,u=!1]=t;return MxCpp.App.mcedRGB2Index(e,l,n,u)},countColorInfo=(t,e)=>{const l=Color$1(t),n=l.red(),u=l.green(),c=l.blue(),y=indexOfMxColor(n,u,c);return y===7&&(t=`rgb(${reverseRGB(n)}, ${reverseRGB(u)}, ${reverseRGB(c)})`),{name:e===4?getColorName(y)||t:`rgb(${n},${u},${c})`,index:y,color:t,method:e}},getLayerTable=()=>getDatabase()?.getLayerTable(),getLayerJson=()=>getLayerTable()?.getJson(),setLayerJson=t=>{let l=getLayerTable().setJson(t);return MxCpp.getCurrentMxCAD().updateLayerDisplayStatus(),MxCpp.getCurrentMxCAD().updateDisplay(),l},version$2="1.0.0",getVersion=()=>version$2,getLargeVersion=()=>{let t=getVersion();const e=t.lastIndexOf(".");return t=t.substring(0,e),t};let uiConfig;const fetchUiConfig=async()=>{if(uiConfig)return uiConfig;uiConfig=await getConfig(new URL(""+new URL("../mxUiConfig.json",import.meta.url).href,import.meta.url).href),uiConfig.title&&(document.title=uiConfig.title);const t=/<version>/g;return uiConfig.headerTitle&&(uiConfig.headerTitle=uiConfig.headerTitle.replace(t,getLargeVersion())),uiConfig=reactive(uiConfig),uiConfig},fetchQuickCommand=()=>getConfig(new URL(""+new URL("../mxQuickCommand.json",import.meta.url).href,import.meta.url).href);var __assign=function(){return __assign=Object.assign||function(e){for(var l,n=1,u=arguments.length;n<u;n++){l=arguments[n];for(var c in l)Object.prototype.hasOwnProperty.call(l,c)&&(e[c]=l[c])}return e},__assign.apply(this,arguments)};function __awaiter(t,e,l,n){function u(c){return c instanceof l?c:new l(function(y){y(c)})}return new(l||(l=Promise))(function(c,y){function b(N){try{O(n.next(N))}catch(L){y(L)}}function m(N){try{O(n.throw(N))}catch(L){y(L)}}function O(N){N.done?c(N.value):u(N.value).then(b,m)}O((n=n.apply(t,e||[])).next())})}function __generator(t,e){var l={label:0,sent:function(){if(c[0]&1)throw c[1];return c[1]},trys:[],ops:[]},n,u,c,y;return y={next:b(0),throw:b(1),return:b(2)},typeof Symbol=="function"&&(y[Symbol.iterator]=function(){return this}),y;function b(O){return function(N){return m([O,N])}}function m(O){if(n)throw new TypeError("Generator is already executing.");for(;y&&(y=0,O[0]&&(l=0)),l;)try{if(n=1,u&&(c=O[0]&2?u.return:O[0]?u.throw||((c=u.return)&&c.call(u),0):u.next)&&!(c=c.call(u,O[1])).done)return c;switch(u=0,c&&(O=[O[0]&2,c.value]),O[0]){case 0:case 1:c=O;break;case 4:return l.label++,{value:O[1],done:!1};case 5:l.label++,u=O[1],O=[0];continue;case 7:O=l.ops.pop(),l.trys.pop();continue;default:if(c=l.trys,!(c=c.length>0&&c[c.length-1])&&(O[0]===6||O[0]===2)){l=0;continue}if(O[0]===3&&(!c||O[1]>c[0]&&O[1]<c[3])){l.label=O[1];break}if(O[0]===6&&l.label<c[1]){l.label=c[1],c=O;break}if(c&&l.label<c[2]){l.label=c[2],l.ops.push(O);break}c[2]&&l.ops.pop(),l.trys.pop();continue}O=e.call(t,l)}catch(N){O=[6,N],u=0}finally{n=c=0}if(O[0]&5)throw O[1];return{value:O[0]?O[1]:void 0,done:!0}}}function __spreadArray(t,e,l){if(l||arguments.length===2)for(var n=0,u=e.length,c;n<u;n++)(c||!(n in e))&&(c||(c=Array.prototype.slice.call(e,0,n)),c[n]=e[n]);return t.concat(c||Array.prototype.slice.call(e))}typeof SuppressedError=="function"&&SuppressedError;var version$1="3.4.2";function wait(t,e){return new Promise(function(l){return setTimeout(l,t,e)})}function requestIdleCallbackIfAvailable(t,e){e===void 0&&(e=1/0);var l=window.requestIdleCallback;return l?new Promise(function(n){return l.call(window,function(){return n()},{timeout:e})}):wait(Math.min(t,e))}function isPromise(t){return!!t&&typeof t.then=="function"}function awaitIfAsync(t,e){try{var l=t();isPromise(l)?l.then(function(n){return e(!0,n)},function(n){return e(!1,n)}):e(!0,l)}catch(n){e(!1,n)}}function mapWithBreaks(t,e,l){return l===void 0&&(l=16),__awaiter(this,void 0,void 0,function(){var n,u,c,y;return __generator(this,function(b){switch(b.label){case 0:n=Array(t.length),u=Date.now(),c=0,b.label=1;case 1:return c<t.length?(n[c]=e(t[c],c),y=Date.now(),y>=u+l?(u=y,[4,wait(0)]):[3,3]):[3,4];case 2:b.sent(),b.label=3;case 3:return++c,[3,1];case 4:return[2,n]}})})}function suppressUnhandledRejectionWarning(t){t.then(void 0,function(){})}function x64Add(t,e){t=[t[0]>>>16,t[0]&65535,t[1]>>>16,t[1]&65535],e=[e[0]>>>16,e[0]&65535,e[1]>>>16,e[1]&65535];var l=[0,0,0,0];return l[3]+=t[3]+e[3],l[2]+=l[3]>>>16,l[3]&=65535,l[2]+=t[2]+e[2],l[1]+=l[2]>>>16,l[2]&=65535,l[1]+=t[1]+e[1],l[0]+=l[1]>>>16,l[1]&=65535,l[0]+=t[0]+e[0],l[0]&=65535,[l[0]<<16|l[1],l[2]<<16|l[3]]}function x64Multiply(t,e){t=[t[0]>>>16,t[0]&65535,t[1]>>>16,t[1]&65535],e=[e[0]>>>16,e[0]&65535,e[1]>>>16,e[1]&65535];var l=[0,0,0,0];return l[3]+=t[3]*e[3],l[2]+=l[3]>>>16,l[3]&=65535,l[2]+=t[2]*e[3],l[1]+=l[2]>>>16,l[2]&=65535,l[2]+=t[3]*e[2],l[1]+=l[2]>>>16,l[2]&=65535,l[1]+=t[1]*e[3],l[0]+=l[1]>>>16,l[1]&=65535,l[1]+=t[2]*e[2],l[0]+=l[1]>>>16,l[1]&=65535,l[1]+=t[3]*e[1],l[0]+=l[1]>>>16,l[1]&=65535,l[0]+=t[0]*e[3]+t[1]*e[2]+t[2]*e[1]+t[3]*e[0],l[0]&=65535,[l[0]<<16|l[1],l[2]<<16|l[3]]}function x64Rotl(t,e){return e%=64,e===32?[t[1],t[0]]:e<32?[t[0]<<e|t[1]>>>32-e,t[1]<<e|t[0]>>>32-e]:(e-=32,[t[1]<<e|t[0]>>>32-e,t[0]<<e|t[1]>>>32-e])}function x64LeftShift(t,e){return e%=64,e===0?t:e<32?[t[0]<<e|t[1]>>>32-e,t[1]<<e]:[t[1]<<e-32,0]}function x64Xor(t,e){return[t[0]^e[0],t[1]^e[1]]}function x64Fmix(t){return t=x64Xor(t,[0,t[0]>>>1]),t=x64Multiply(t,[4283543511,3981806797]),t=x64Xor(t,[0,t[0]>>>1]),t=x64Multiply(t,[3301882366,444984403]),t=x64Xor(t,[0,t[0]>>>1]),t}function x64hash128(t,e){t=t||"",e=e||0;var l=t.length%16,n=t.length-l,u=[0,e],c=[0,e],y=[0,0],b=[0,0],m=[2277735313,289559509],O=[1291169091,658871167],N;for(N=0;N<n;N=N+16)y=[t.charCodeAt(N+4)&255|(t.charCodeAt(N+5)&255)<<8|(t.charCodeAt(N+6)&255)<<16|(t.charCodeAt(N+7)&255)<<24,t.charCodeAt(N)&255|(t.charCodeAt(N+1)&255)<<8|(t.charCodeAt(N+2)&255)<<16|(t.charCodeAt(N+3)&255)<<24],b=[t.charCodeAt(N+12)&255|(t.charCodeAt(N+13)&255)<<8|(t.charCodeAt(N+14)&255)<<16|(t.charCodeAt(N+15)&255)<<24,t.charCodeAt(N+8)&255|(t.charCodeAt(N+9)&255)<<8|(t.charCodeAt(N+10)&255)<<16|(t.charCodeAt(N+11)&255)<<24],y=x64Multiply(y,m),y=x64Rotl(y,31),y=x64Multiply(y,O),u=x64Xor(u,y),u=x64Rotl(u,27),u=x64Add(u,c),u=x64Add(x64Multiply(u,[0,5]),[0,1390208809]),b=x64Multiply(b,O),b=x64Rotl(b,33),b=x64Multiply(b,m),c=x64Xor(c,b),c=x64Rotl(c,31),c=x64Add(c,u),c=x64Add(x64Multiply(c,[0,5]),[0,944331445]);switch(y=[0,0],b=[0,0],l){case 15:b=x64Xor(b,x64LeftShift([0,t.charCodeAt(N+14)],48));case 14:b=x64Xor(b,x64LeftShift([0,t.charCodeAt(N+13)],40));case 13:b=x64Xor(b,x64LeftShift([0,t.charCodeAt(N+12)],32));case 12:b=x64Xor(b,x64LeftShift([0,t.charCodeAt(N+11)],24));case 11:b=x64Xor(b,x64LeftShift([0,t.charCodeAt(N+10)],16));case 10:b=x64Xor(b,x64LeftShift([0,t.charCodeAt(N+9)],8));case 9:b=x64Xor(b,[0,t.charCodeAt(N+8)]),b=x64Multiply(b,O),b=x64Rotl(b,33),b=x64Multiply(b,m),c=x64Xor(c,b);case 8:y=x64Xor(y,x64LeftShift([0,t.charCodeAt(N+7)],56));case 7:y=x64Xor(y,x64LeftShift([0,t.charCodeAt(N+6)],48));case 6:y=x64Xor(y,x64LeftShift([0,t.charCodeAt(N+5)],40));case 5:y=x64Xor(y,x64LeftShift([0,t.charCodeAt(N+4)],32));case 4:y=x64Xor(y,x64LeftShift([0,t.charCodeAt(N+3)],24));case 3:y=x64Xor(y,x64LeftShift([0,t.charCodeAt(N+2)],16));case 2:y=x64Xor(y,x64LeftShift([0,t.charCodeAt(N+1)],8));case 1:y=x64Xor(y,[0,t.charCodeAt(N)]),y=x64Multiply(y,m),y=x64Rotl(y,31),y=x64Multiply(y,O),u=x64Xor(u,y)}return u=x64Xor(u,[0,t.length]),c=x64Xor(c,[0,t.length]),u=x64Add(u,c),c=x64Add(c,u),u=x64Fmix(u),c=x64Fmix(c),u=x64Add(u,c),c=x64Add(c,u),("00000000"+(u[0]>>>0).toString(16)).slice(-8)+("00000000"+(u[1]>>>0).toString(16)).slice(-8)+("00000000"+(c[0]>>>0).toString(16)).slice(-8)+("00000000"+(c[1]>>>0).toString(16)).slice(-8)}function errorToObject(t){var e;return __assign({name:t.name,message:t.message,stack:(e=t.stack)===null||e===void 0?void 0:e.split(`
- `)},t)}function includes$1(t,e){for(var l=0,n=t.length;l<n;++l)if(t[l]===e)return!0;return!1}function excludes(t,e){return!includes$1(t,e)}function toInt(t){return parseInt(t)}function toFloat(t){return parseFloat(t)}function replaceNaN(t,e){return typeof t=="number"&&isNaN(t)?e:t}function countTruthy(t){return t.reduce(function(e,l){return e+(l?1:0)},0)}function round(t,e){if(e===void 0&&(e=1),Math.abs(e)>=1)return Math.round(t/e)*e;var l=1/e;return Math.round(t*l)/l}function parseSimpleCssSelector(t){for(var e,l,n="Unexpected syntax '".concat(t,"'"),u=/^\s*([a-z-]*)(.*)$/i.exec(t),c=u[1]||void 0,y={},b=/([.:#][\w-]+|\[.+?\])/gi,m=function(G,q){y[G]=y[G]||[],y[G].push(q)};;){var O=b.exec(u[2]);if(!O)break;var N=O[0];switch(N[0]){case".":m("class",N.slice(1));break;case"#":m("id",N.slice(1));break;case"[":{var L=/^\[([\w-]+)([~|^$*]?=("(.*?)"|([\w-]+)))?(\s+[is])?\]$/.exec(N);if(L)m(L[1],(l=(e=L[4])!==null&&e!==void 0?e:L[5])!==null&&l!==void 0?l:"");else throw new Error(n);break}default:throw new Error(n)}}return[c,y]}function ensureErrorWithMessage(t){return t&&typeof t=="object"&&"message"in t?t:{message:t}}function isFinalResultLoaded(t){return typeof t!="function"}function loadSource(t,e){var l=new Promise(function(n){var u=Date.now();awaitIfAsync(t.bind(null,e),function(){for(var c=[],y=0;y<arguments.length;y++)c[y]=arguments[y];var b=Date.now()-u;if(!c[0])return n(function(){return{error:ensureErrorWithMessage(c[1]),duration:b}});var m=c[1];if(isFinalResultLoaded(m))return n(function(){return{value:m,duration:b}});n(function(){return new Promise(function(O){var N=Date.now();awaitIfAsync(m,function(){for(var L=[],G=0;G<arguments.length;G++)L[G]=arguments[G];var q=b+Date.now()-N;if(!L[0])return O({error:ensureErrorWithMessage(L[1]),duration:q});O({value:L[1],duration:q})})})})})});return suppressUnhandledRejectionWarning(l),function(){return l.then(function(u){return u()})}}function loadSources(t,e,l){var n=Object.keys(t).filter(function(c){return excludes(l,c)}),u=mapWithBreaks(n,function(c){return loadSource(t[c],e)});return suppressUnhandledRejectionWarning(u),function(){return __awaiter(this,void 0,void 0,function(){var y,b,m,O,N;return __generator(this,function(L){switch(L.label){case 0:return[4,u];case 1:return y=L.sent(),[4,mapWithBreaks(y,function(G){var q=G();return suppressUnhandledRejectionWarning(q),q})];case 2:return b=L.sent(),[4,Promise.all(b)];case 3:for(m=L.sent(),O={},N=0;N<n.length;++N)O[n[N]]=m[N];return[2,O]}})})}}function isTrident(){var t=window,e=navigator;return countTruthy(["MSCSSMatrix"in t,"msSetImmediate"in t,"msIndexedDB"in t,"msMaxTouchPoints"in e,"msPointerEnabled"in e])>=4}function isEdgeHTML(){var t=window,e=navigator;return countTruthy(["msWriteProfilerMark"in t,"MSStream"in t,"msLaunchUri"in e,"msSaveBlob"in e])>=3&&!isTrident()}function isChromium(){var t=window,e=navigator;return countTruthy(["webkitPersistentStorage"in e,"webkitTemporaryStorage"in e,e.vendor.indexOf("Google")===0,"webkitResolveLocalFileSystemURL"in t,"BatteryManager"in t,"webkitMediaStream"in t,"webkitSpeechGrammar"in t])>=5}function isWebKit(){var t=window,e=navigator;return countTruthy(["ApplePayError"in t,"CSSPrimitiveValue"in t,"Counter"in t,e.vendor.indexOf("Apple")===0,"getStorageUpdates"in e,"WebKitMediaKeys"in t])>=4}function isDesktopSafari(){var t=window;return countTruthy(["safari"in t,!("DeviceMotionEvent"in t),!("ongestureend"in t),!("standalone"in navigator)])>=3}function isGecko(){var t,e,l=window;return countTruthy(["buildID"in navigator,"MozAppearance"in((e=(t=document.documentElement)===null||t===void 0?void 0:t.style)!==null&&e!==void 0?e:{}),"onmozfullscreenchange"in l,"mozInnerScreenX"in l,"CSSMozDocumentRule"in l,"CanvasCaptureMediaStream"in l])>=4}function isChromium86OrNewer(){var t=window;return countTruthy([!("MediaSettingsRange"in t),"RTCEncodedAudioFrame"in t,""+t.Intl=="[object Intl]",""+t.Reflect=="[object Reflect]"])>=3}function isWebKit606OrNewer(){var t=window;return countTruthy(["DOMRectList"in t,"RTCPeerConnectionIceEvent"in t,"SVGGeometryElement"in t,"ontransitioncancel"in t])>=3}function isIPad(){if(navigator.platform==="iPad")return!0;var t=screen,e=t.width/t.height;return countTruthy(["MediaSource"in window,!!Element.prototype.webkitRequestFullscreen,e>.65&&e<1.53])>=2}function getFullscreenElement(){var t=document;return t.fullscreenElement||t.msFullscreenElement||t.mozFullScreenElement||t.webkitFullscreenElement||null}function exitFullscreen(){var t=document;return(t.exitFullscreen||t.msExitFullscreen||t.mozCancelFullScreen||t.webkitExitFullscreen).call(t)}function isAndroid(){var t=isChromium(),e=isGecko();if(!t&&!e)return!1;var l=window;return countTruthy(["onorientationchange"in l,"orientation"in l,t&&!("SharedWorker"in l),e&&/android/i.test(navigator.appVersion)])>=2}function getAudioFingerprint(){var t=window,e=t.OfflineAudioContext||t.webkitOfflineAudioContext;if(!e)return-2;if(doesCurrentBrowserSuspendAudioContext())return-1;var l=4500,n=5e3,u=new e(1,n,44100),c=u.createOscillator();c.type="triangle",c.frequency.value=1e4;var y=u.createDynamicsCompressor();y.threshold.value=-50,y.knee.value=40,y.ratio.value=12,y.attack.value=0,y.release.value=.25,c.connect(y),y.connect(u.destination),c.start(0);var b=startRenderingAudio(u),m=b[0],O=b[1],N=m.then(function(L){return getHash(L.getChannelData(0).subarray(l))},function(L){if(L.name==="timeout"||L.name==="suspended")return-3;throw L});return suppressUnhandledRejectionWarning(N),function(){return O(),N}}function doesCurrentBrowserSuspendAudioContext(){return isWebKit()&&!isDesktopSafari()&&!isWebKit606OrNewer()}function startRenderingAudio(t){var e=3,l=500,n=500,u=5e3,c=function(){},y=new Promise(function(b,m){var O=!1,N=0,L=0;t.oncomplete=function(J){return b(J.renderedBuffer)};var G=function(){setTimeout(function(){return m(makeInnerError("timeout"))},Math.min(n,L+u-Date.now()))},q=function(){try{var J=t.startRendering();switch(isPromise(J)&&suppressUnhandledRejectionWarning(J),t.state){case"running":L=Date.now(),O&&G();break;case"suspended":document.hidden||N++,O&&N>=e?m(makeInnerError("suspended")):setTimeout(q,l);break}}catch(fe){m(fe)}};q(),c=function(){O||(O=!0,L>0&&G())}});return[y,c]}function getHash(t){for(var e=0,l=0;l<t.length;++l)e+=Math.abs(t[l]);return e}function makeInnerError(t){var e=new Error(t);return e.name=t,e}function withIframe(t,e,l){var n,u,c;return l===void 0&&(l=50),__awaiter(this,void 0,void 0,function(){var y,b;return __generator(this,function(m){switch(m.label){case 0:y=document,m.label=1;case 1:return y.body?[3,3]:[4,wait(l)];case 2:return m.sent(),[3,1];case 3:b=y.createElement("iframe"),m.label=4;case 4:return m.trys.push([4,,10,11]),[4,new Promise(function(O,N){var L=!1,G=function(){L=!0,O()},q=function(ve){L=!0,N(ve)};b.onload=G,b.onerror=q;var J=b.style;J.setProperty("display","block","important"),J.position="absolute",J.top="0",J.left="0",J.visibility="hidden",e&&"srcdoc"in b?b.srcdoc=e:b.src="about:blank",y.body.appendChild(b);var fe=function(){var ve,ne;L||(((ne=(ve=b.contentWindow)===null||ve===void 0?void 0:ve.document)===null||ne===void 0?void 0:ne.readyState)==="complete"?G():setTimeout(fe,10))};fe()})];case 5:m.sent(),m.label=6;case 6:return!((u=(n=b.contentWindow)===null||n===void 0?void 0:n.document)===null||u===void 0)&&u.body?[3,8]:[4,wait(l)];case 7:return m.sent(),[3,6];case 8:return[4,t(b,b.contentWindow)];case 9:return[2,m.sent()];case 10:return(c=b.parentNode)===null||c===void 0||c.removeChild(b),[7];case 11:return[2]}})})}function selectorToElement(t){for(var e=parseSimpleCssSelector(t),l=e[0],n=e[1],u=document.createElement(l??"div"),c=0,y=Object.keys(n);c<y.length;c++){var b=y[c],m=n[b].join(" ");b==="style"?addStyleString(u.style,m):u.setAttribute(b,m)}return u}function addStyleString(t,e){for(var l=0,n=e.split(";");l<n.length;l++){var u=n[l],c=/^\s*([\w-]+)\s*:\s*(.+?)(\s*!([\w-]+))?\s*$/.exec(u);if(c){var y=c[1],b=c[2],m=c[4];t.setProperty(y,b,m||"")}}}var testString="mmMwWLliI0O&1",textSize="48px",baseFonts=["monospace","sans-serif","serif"],fontList=["sans-serif-thin","ARNO PRO","Agency FB","Arabic Typesetting","Arial Unicode MS","AvantGarde Bk BT","BankGothic Md BT","Batang","Bitstream Vera Sans Mono","Calibri","Century","Century Gothic","Clarendon","EUROSTILE","Franklin Gothic","Futura Bk BT","Futura Md BT","GOTHAM","Gill Sans","HELV","Haettenschweiler","Helvetica Neue","Humanst521 BT","Leelawadee","Letter Gothic","Levenim MT","Lucida Bright","Lucida Sans","Menlo","MS Mincho","MS Outlook","MS Reference Specialty","MS UI Gothic","MT Extra","MYRIAD PRO","Marlett","Meiryo UI","Microsoft Uighur","Minion Pro","Monotype Corsiva","PMingLiU","Pristina","SCRIPTINA","Segoe UI Light","Serifa","SimHei","Small Fonts","Staccato222 BT","TRAJAN PRO","Univers CE 55 Medium","Vrinda","ZWAdobeF"];function getFonts(){return withIframe(function(t,e){var l=e.document,n=l.body;n.style.fontSize=textSize;var u=l.createElement("div"),c={},y={},b=function(fe){var ve=l.createElement("span"),ne=ve.style;return ne.position="absolute",ne.top="0",ne.left="0",ne.fontFamily=fe,ve.textContent=testString,u.appendChild(ve),ve},m=function(fe,ve){return b("'".concat(fe,"',").concat(ve))},O=function(){return baseFonts.map(b)},N=function(){for(var fe={},ve=function(Ve){fe[Ve]=baseFonts.map(function(rt){return m(Ve,rt)})},ne=0,Ue=fontList;ne<Ue.length;ne++){var De=Ue[ne];ve(De)}return fe},L=function(fe){return baseFonts.some(function(ve,ne){return fe[ne].offsetWidth!==c[ve]||fe[ne].offsetHeight!==y[ve]})},G=O(),q=N();n.appendChild(u);for(var J=0;J<baseFonts.length;J++)c[baseFonts[J]]=G[J].offsetWidth,y[baseFonts[J]]=G[J].offsetHeight;return fontList.filter(function(fe){return L(q[fe])})})}function getPlugins(){var t=navigator.plugins;if(t){for(var e=[],l=0;l<t.length;++l){var n=t[l];if(n){for(var u=[],c=0;c<n.length;++c){var y=n[c];u.push({type:y.type,suffixes:y.suffixes})}e.push({name:n.name,description:n.description,mimeTypes:u})}}return e}}function getCanvasFingerprint(){var t=!1,e,l,n=makeCanvasContext(),u=n[0],c=n[1];if(!isSupported(u,c))e=l="";else{t=doesSupportWinding(c),renderTextImage(u,c);var y=canvasToString(u),b=canvasToString(u);y!==b?e=l="unstable":(l=y,renderGeometryImage(u,c),e=canvasToString(u))}return{winding:t,geometry:e,text:l}}function makeCanvasContext(){var t=document.createElement("canvas");return t.width=1,t.height=1,[t,t.getContext("2d")]}function isSupported(t,e){return!!(e&&t.toDataURL)}function doesSupportWinding(t){return t.rect(0,0,10,10),t.rect(2,2,6,6),!t.isPointInPath(5,5,"evenodd")}function renderTextImage(t,e){t.width=240,t.height=60,e.textBaseline="alphabetic",e.fillStyle="#f60",e.fillRect(100,1,62,20),e.fillStyle="#069",e.font='11pt "Times New Roman"';var l="Cwm fjordbank gly ".concat("😃");e.fillText(l,2,15),e.fillStyle="rgba(102, 204, 0, 0.2)",e.font="18pt Arial",e.fillText(l,4,45)}function renderGeometryImage(t,e){t.width=122,t.height=110,e.globalCompositeOperation="multiply";for(var l=0,n=[["#f2f",40,40],["#2ff",80,40],["#ff2",60,80]];l<n.length;l++){var u=n[l],c=u[0],y=u[1],b=u[2];e.fillStyle=c,e.beginPath(),e.arc(y,b,40,0,Math.PI*2,!0),e.closePath(),e.fill()}e.fillStyle="#f9c",e.arc(60,60,60,0,Math.PI*2,!0),e.arc(60,60,20,0,Math.PI*2,!0),e.fill("evenodd")}function canvasToString(t){return t.toDataURL()}function getTouchSupport(){var t=navigator,e=0,l;t.maxTouchPoints!==void 0?e=toInt(t.maxTouchPoints):t.msMaxTouchPoints!==void 0&&(e=t.msMaxTouchPoints);try{document.createEvent("TouchEvent"),l=!0}catch{l=!1}var n="ontouchstart"in window;return{maxTouchPoints:e,touchEvent:l,touchStart:n}}function getOsCpu(){return navigator.oscpu}function getLanguages(){var t=navigator,e=[],l=t.language||t.userLanguage||t.browserLanguage||t.systemLanguage;if(l!==void 0&&e.push([l]),Array.isArray(t.languages))isChromium()&&isChromium86OrNewer()||e.push(t.languages);else if(typeof t.languages=="string"){var n=t.languages;n&&e.push(n.split(","))}return e}function getColorDepth(){return window.screen.colorDepth}function getDeviceMemory(){return replaceNaN(toFloat(navigator.deviceMemory),void 0)}function getScreenResolution(){var t=screen,e=function(n){return replaceNaN(toInt(n),null)},l=[e(t.width),e(t.height)];return l.sort().reverse(),l}var screenFrameCheckInterval=2500,roundingPrecision=10,screenFrameBackup,screenFrameSizeTimeoutId;function watchScreenFrame(){if(screenFrameSizeTimeoutId===void 0){var t=function(){var e=getCurrentScreenFrame();isFrameSizeNull(e)?screenFrameSizeTimeoutId=setTimeout(t,screenFrameCheckInterval):(screenFrameBackup=e,screenFrameSizeTimeoutId=void 0)};t()}}function getScreenFrame(){var t=this;return watchScreenFrame(),function(){return __awaiter(t,void 0,void 0,function(){var e;return __generator(this,function(l){switch(l.label){case 0:return e=getCurrentScreenFrame(),isFrameSizeNull(e)?screenFrameBackup?[2,__spreadArray([],screenFrameBackup,!0)]:getFullscreenElement()?[4,exitFullscreen()]:[3,2]:[3,2];case 1:l.sent(),e=getCurrentScreenFrame(),l.label=2;case 2:return isFrameSizeNull(e)||(screenFrameBackup=e),[2,e]}})})}}function getRoundedScreenFrame(){var t=this,e=getScreenFrame();return function(){return __awaiter(t,void 0,void 0,function(){var l,n;return __generator(this,function(u){switch(u.label){case 0:return[4,e()];case 1:return l=u.sent(),n=function(c){return c===null?null:round(c,roundingPrecision)},[2,[n(l[0]),n(l[1]),n(l[2]),n(l[3])]]}})})}}function getCurrentScreenFrame(){var t=screen;return[replaceNaN(toFloat(t.availTop),null),replaceNaN(toFloat(t.width)-toFloat(t.availWidth)-replaceNaN(toFloat(t.availLeft),0),null),replaceNaN(toFloat(t.height)-toFloat(t.availHeight)-replaceNaN(toFloat(t.availTop),0),null),replaceNaN(toFloat(t.availLeft),null)]}function isFrameSizeNull(t){for(var e=0;e<4;++e)if(t[e])return!1;return!0}function getHardwareConcurrency(){return replaceNaN(toInt(navigator.hardwareConcurrency),void 0)}function getTimezone(){var t,e=(t=window.Intl)===null||t===void 0?void 0:t.DateTimeFormat;if(e){var l=new e().resolvedOptions().timeZone;if(l)return l}var n=-getTimezoneOffset();return"UTC".concat(n>=0?"+":"").concat(Math.abs(n))}function getTimezoneOffset(){var t=new Date().getFullYear();return Math.max(toFloat(new Date(t,0,1).getTimezoneOffset()),toFloat(new Date(t,6,1).getTimezoneOffset()))}function getSessionStorage(){try{return!!window.sessionStorage}catch{return!0}}function getLocalStorage(){try{return!!window.localStorage}catch{return!0}}function getIndexedDB(){if(!(isTrident()||isEdgeHTML()))try{return!!window.indexedDB}catch{return!0}}function getOpenDatabase(){return!!window.openDatabase}function getCpuClass(){return navigator.cpuClass}function getPlatform$1(){var t=navigator.platform;return t==="MacIntel"&&isWebKit()&&!isDesktopSafari()?isIPad()?"iPad":"iPhone":t}function getVendor(){return navigator.vendor||""}function getVendorFlavors(){for(var t=[],e=0,l=["chrome","safari","__crWeb","__gCrWeb","yandex","__yb","__ybro","__firefox__","__edgeTrackingPreventionStatistics","webkit","oprt","samsungAr","ucweb","UCShellJava","puffinDevice"];e<l.length;e++){var n=l[e],u=window[n];u&&typeof u=="object"&&t.push(n)}return t.sort()}function areCookiesEnabled(){var t=document;try{t.cookie="cookietest=1; SameSite=Strict;";var e=t.cookie.indexOf("cookietest=")!==-1;return t.cookie="cookietest=1; SameSite=Strict; expires=Thu, 01-Jan-1970 00:00:01 GMT",e}catch{return!1}}function getFilters(){var t=atob;return{abpIndo:["#Iklan-Melayang","#Kolom-Iklan-728","#SidebarIklan-wrapper",'[title="ALIENBOLA" i]',t("I0JveC1CYW5uZXItYWRz")],abpvn:[".quangcao","#mobileCatfish",t("LmNsb3NlLWFkcw=="),'[id^="bn_bottom_fixed_"]',"#pmadv"],adBlockFinland:[".mainostila",t("LnNwb25zb3JpdA=="),".ylamainos",t("YVtocmVmKj0iL2NsaWNrdGhyZ2guYXNwPyJd"),t("YVtocmVmXj0iaHR0cHM6Ly9hcHAucmVhZHBlYWsuY29tL2FkcyJd")],adBlockPersian:["#navbar_notice_50",".kadr",'TABLE[width="140px"]',"#divAgahi",t("YVtocmVmXj0iaHR0cDovL2cxLnYuZndtcm0ubmV0L2FkLyJd")],adBlockWarningRemoval:["#adblock-honeypot",".adblocker-root",".wp_adblock_detect",t("LmhlYWRlci1ibG9ja2VkLWFk"),t("I2FkX2Jsb2NrZXI=")],adGuardAnnoyances:[".hs-sosyal","#cookieconsentdiv",'div[class^="app_gdpr"]',".as-oil",'[data-cypress="soft-push-notification-modal"]'],adGuardBase:[".BetterJsPopOverlay",t("I2FkXzMwMFgyNTA="),t("I2Jhbm5lcmZsb2F0MjI="),t("I2NhbXBhaWduLWJhbm5lcg=="),t("I0FkLUNvbnRlbnQ=")],adGuardChinese:[t("LlppX2FkX2FfSA=="),t("YVtocmVmKj0iLmh0aGJldDM0LmNvbSJd"),"#widget-quan",t("YVtocmVmKj0iLzg0OTkyMDIwLnh5eiJd"),t("YVtocmVmKj0iLjE5NTZobC5jb20vIl0=")],adGuardFrench:["#pavePub",t("LmFkLWRlc2t0b3AtcmVjdGFuZ2xl"),".mobile_adhesion",".widgetadv",t("LmFkc19iYW4=")],adGuardGerman:['aside[data-portal-id="leaderboard"]'],adGuardJapanese:["#kauli_yad_1",t("YVtocmVmXj0iaHR0cDovL2FkMi50cmFmZmljZ2F0ZS5uZXQvIl0="),t("Ll9wb3BJbl9pbmZpbml0ZV9hZA=="),t("LmFkZ29vZ2xl"),t("Ll9faXNib29zdFJldHVybkFk")],adGuardMobile:[t("YW1wLWF1dG8tYWRz"),t("LmFtcF9hZA=="),'amp-embed[type="24smi"]',"#mgid_iframe1",t("I2FkX2ludmlld19hcmVh")],adGuardRussian:[t("YVtocmVmXj0iaHR0cHM6Ly9hZC5sZXRtZWFkcy5jb20vIl0="),t("LnJlY2xhbWE="),'div[id^="smi2adblock"]',t("ZGl2W2lkXj0iQWRGb3hfYmFubmVyXyJd"),"#psyduckpockeball"],adGuardSocial:[t("YVtocmVmXj0iLy93d3cuc3R1bWJsZXVwb24uY29tL3N1Ym1pdD91cmw9Il0="),t("YVtocmVmXj0iLy90ZWxlZ3JhbS5tZS9zaGFyZS91cmw/Il0="),".etsy-tweet","#inlineShare",".popup-social"],adGuardSpanishPortuguese:["#barraPublicidade","#Publicidade","#publiEspecial","#queTooltip",".cnt-publi"],adGuardTrackingProtection:["#qoo-counter",t("YVtocmVmXj0iaHR0cDovL2NsaWNrLmhvdGxvZy5ydS8iXQ=="),t("YVtocmVmXj0iaHR0cDovL2hpdGNvdW50ZXIucnUvdG9wL3N0YXQucGhwIl0="),t("YVtocmVmXj0iaHR0cDovL3RvcC5tYWlsLnJ1L2p1bXAiXQ=="),"#top100counter"],adGuardTurkish:["#backkapat",t("I3Jla2xhbWk="),t("YVtocmVmXj0iaHR0cDovL2Fkc2Vydi5vbnRlay5jb20udHIvIl0="),t("YVtocmVmXj0iaHR0cDovL2l6bGVuemkuY29tL2NhbXBhaWduLyJd"),t("YVtocmVmXj0iaHR0cDovL3d3dy5pbnN0YWxsYWRzLm5ldC8iXQ==")],bulgarian:[t("dGQjZnJlZW5ldF90YWJsZV9hZHM="),"#ea_intext_div",".lapni-pop-over","#xenium_hot_offers"],easyList:[".yb-floorad",t("LndpZGdldF9wb19hZHNfd2lkZ2V0"),t("LnRyYWZmaWNqdW5reS1hZA=="),".textad_headline",t("LnNwb25zb3JlZC10ZXh0LWxpbmtz")],easyListChina:[t("LmFwcGd1aWRlLXdyYXBbb25jbGljayo9ImJjZWJvcy5jb20iXQ=="),t("LmZyb250cGFnZUFkdk0="),"#taotaole","#aafoot.top_box",".cfa_popup"],easyListCookie:[".ezmob-footer",".cc-CookieWarning","[data-cookie-number]",t("LmF3LWNvb2tpZS1iYW5uZXI="),".sygnal24-gdpr-modal-wrap"],easyListCzechSlovak:["#onlajny-stickers",t("I3Jla2xhbW5pLWJveA=="),t("LnJla2xhbWEtbWVnYWJvYXJk"),".sklik",t("W2lkXj0ic2tsaWtSZWtsYW1hIl0=")],easyListDutch:[t("I2FkdmVydGVudGll"),t("I3ZpcEFkbWFya3RCYW5uZXJCbG9jaw=="),".adstekst",t("YVtocmVmXj0iaHR0cHM6Ly94bHR1YmUubmwvY2xpY2svIl0="),"#semilo-lrectangle"],easyListGermany:["#SSpotIMPopSlider",t("LnNwb25zb3JsaW5rZ3J1ZW4="),t("I3dlcmJ1bmdza3k="),t("I3Jla2xhbWUtcmVjaHRzLW1pdHRl"),t("YVtocmVmXj0iaHR0cHM6Ly9iZDc0Mi5jb20vIl0=")],easyListItaly:[t("LmJveF9hZHZfYW5udW5jaQ=="),".sb-box-pubbliredazionale",t("YVtocmVmXj0iaHR0cDovL2FmZmlsaWF6aW9uaWFkcy5zbmFpLml0LyJd"),t("YVtocmVmXj0iaHR0cHM6Ly9hZHNlcnZlci5odG1sLml0LyJd"),t("YVtocmVmXj0iaHR0cHM6Ly9hZmZpbGlhemlvbmlhZHMuc25haS5pdC8iXQ==")],easyListLithuania:[t("LnJla2xhbW9zX3RhcnBhcw=="),t("LnJla2xhbW9zX251b3JvZG9z"),t("aW1nW2FsdD0iUmVrbGFtaW5pcyBza3lkZWxpcyJd"),t("aW1nW2FsdD0iRGVkaWt1b3RpLmx0IHNlcnZlcmlhaSJd"),t("aW1nW2FsdD0iSG9zdGluZ2FzIFNlcnZlcmlhaS5sdCJd")],estonian:[t("QVtocmVmKj0iaHR0cDovL3BheTRyZXN1bHRzMjQuZXUiXQ==")],fanboyAnnoyances:["#ac-lre-player",".navigate-to-top","#subscribe_popup",".newsletter_holder","#back-top"],fanboyAntiFacebook:[".util-bar-module-firefly-visible"],fanboyEnhancedTrackers:[".open.pushModal","#issuem-leaky-paywall-articles-zero-remaining-nag","#sovrn_container",'div[class$="-hide"][zoompage-fontsize][style="display: block;"]',".BlockNag__Card"],fanboySocial:["#FollowUs","#meteored_share","#social_follow",".article-sharer",".community__social-desc"],frellwitSwedish:[t("YVtocmVmKj0iY2FzaW5vcHJvLnNlIl1bdGFyZ2V0PSJfYmxhbmsiXQ=="),t("YVtocmVmKj0iZG9rdG9yLXNlLm9uZWxpbmsubWUiXQ=="),"article.category-samarbete",t("ZGl2LmhvbGlkQWRz"),"ul.adsmodern"],greekAdBlock:[t("QVtocmVmKj0iYWRtYW4ub3RlbmV0LmdyL2NsaWNrPyJd"),t("QVtocmVmKj0iaHR0cDovL2F4aWFiYW5uZXJzLmV4b2R1cy5nci8iXQ=="),t("QVtocmVmKj0iaHR0cDovL2ludGVyYWN0aXZlLmZvcnRobmV0LmdyL2NsaWNrPyJd"),"DIV.agores300","TABLE.advright"],hungarian:["#cemp_doboz",".optimonk-iframe-container",t("LmFkX19tYWlu"),t("W2NsYXNzKj0iR29vZ2xlQWRzIl0="),"#hirdetesek_box"],iDontCareAboutCookies:['.alert-info[data-block-track*="CookieNotice"]',".ModuleTemplateCookieIndicator",".o--cookies--container","#cookies-policy-sticky","#stickyCookieBar"],icelandicAbp:[t("QVtocmVmXj0iL2ZyYW1ld29yay9yZXNvdXJjZXMvZm9ybXMvYWRzLmFzcHgiXQ==")],latvian:[t("YVtocmVmPSJodHRwOi8vd3d3LnNhbGlkemluaS5sdi8iXVtzdHlsZT0iZGlzcGxheTogYmxvY2s7IHdpZHRoOiAxMjBweDsgaGVpZ2h0OiA0MHB4OyBvdmVyZmxvdzogaGlkZGVuOyBwb3NpdGlvbjogcmVsYXRpdmU7Il0="),t("YVtocmVmPSJodHRwOi8vd3d3LnNhbGlkemluaS5sdi8iXVtzdHlsZT0iZGlzcGxheTogYmxvY2s7IHdpZHRoOiA4OHB4OyBoZWlnaHQ6IDMxcHg7IG92ZXJmbG93OiBoaWRkZW47IHBvc2l0aW9uOiByZWxhdGl2ZTsiXQ==")],listKr:[t("YVtocmVmKj0iLy9hZC5wbGFuYnBsdXMuY28ua3IvIl0="),t("I2xpdmVyZUFkV3JhcHBlcg=="),t("YVtocmVmKj0iLy9hZHYuaW1hZHJlcC5jby5rci8iXQ=="),t("aW5zLmZhc3R2aWV3LWFk"),".revenue_unit_item.dable"],listeAr:[t("LmdlbWluaUxCMUFk"),".right-and-left-sponsers",t("YVtocmVmKj0iLmFmbGFtLmluZm8iXQ=="),t("YVtocmVmKj0iYm9vcmFxLm9yZyJd"),t("YVtocmVmKj0iZHViaXp6bGUuY29tL2FyLz91dG1fc291cmNlPSJd")],listeFr:[t("YVtocmVmXj0iaHR0cDovL3Byb21vLnZhZG9yLmNvbS8iXQ=="),t("I2FkY29udGFpbmVyX3JlY2hlcmNoZQ=="),t("YVtocmVmKj0id2Vib3JhbWEuZnIvZmNnaS1iaW4vIl0="),".site-pub-interstitiel",'div[id^="crt-"][data-criteo-id]'],officialPolish:["#ceneo-placeholder-ceneo-12",t("W2hyZWZePSJodHRwczovL2FmZi5zZW5kaHViLnBsLyJd"),t("YVtocmVmXj0iaHR0cDovL2Fkdm1hbmFnZXIudGVjaGZ1bi5wbC9yZWRpcmVjdC8iXQ=="),t("YVtocmVmXj0iaHR0cDovL3d3dy50cml6ZXIucGwvP3V0bV9zb3VyY2UiXQ=="),t("ZGl2I3NrYXBpZWNfYWQ=")],ro:[t("YVtocmVmXj0iLy9hZmZ0cmsuYWx0ZXgucm8vQ291bnRlci9DbGljayJd"),t("YVtocmVmXj0iaHR0cHM6Ly9ibGFja2ZyaWRheXNhbGVzLnJvL3Ryay9zaG9wLyJd"),t("YVtocmVmXj0iaHR0cHM6Ly9ldmVudC4ycGVyZm9ybWFudC5jb20vZXZlbnRzL2NsaWNrIl0="),t("YVtocmVmXj0iaHR0cHM6Ly9sLnByb2ZpdHNoYXJlLnJvLyJd"),'a[href^="/url/"]'],ruAd:[t("YVtocmVmKj0iLy9mZWJyYXJlLnJ1LyJd"),t("YVtocmVmKj0iLy91dGltZy5ydS8iXQ=="),t("YVtocmVmKj0iOi8vY2hpa2lkaWtpLnJ1Il0="),"#pgeldiz",".yandex-rtb-block"],thaiAds:["a[href*=macau-uta-popup]",t("I2Fkcy1nb29nbGUtbWlkZGxlX3JlY3RhbmdsZS1ncm91cA=="),t("LmFkczMwMHM="),".bumq",".img-kosana"],webAnnoyancesUltralist:["#mod-social-share-2","#social-tools",t("LmN0cGwtZnVsbGJhbm5lcg=="),".zergnet-recommend",".yt.btn-link.btn-md.btn"]}}function getDomBlockers(t){var e=t===void 0?{}:t,l=e.debug;return __awaiter(this,void 0,void 0,function(){var n,u,c,y,b,m;return __generator(this,function(O){switch(O.label){case 0:return isApplicable()?(n=getFilters(),u=Object.keys(n),c=(m=[]).concat.apply(m,u.map(function(N){return n[N]})),[4,getBlockedSelectors(c)]):[2,void 0];case 1:return y=O.sent(),l&&printDebug(n,y),b=u.filter(function(N){var L=n[N],G=countTruthy(L.map(function(q){return y[q]}));return G>L.length*.6}),b.sort(),[2,b]}})})}function isApplicable(){return isWebKit()||isAndroid()}function getBlockedSelectors(t){var e;return __awaiter(this,void 0,void 0,function(){var l,n,u,c,m,y,b,m;return __generator(this,function(O){switch(O.label){case 0:for(l=document,n=l.createElement("div"),u=new Array(t.length),c={},forceShow(n),m=0;m<t.length;++m)y=selectorToElement(t[m]),y.tagName==="DIALOG"&&y.show(),b=l.createElement("div"),forceShow(b),b.appendChild(y),n.appendChild(b),u[m]=y;O.label=1;case 1:return l.body?[3,3]:[4,wait(50)];case 2:return O.sent(),[3,1];case 3:l.body.appendChild(n);try{for(m=0;m<t.length;++m)u[m].offsetParent||(c[t[m]]=!0)}finally{(e=n.parentNode)===null||e===void 0||e.removeChild(n)}return[2,c]}})})}function forceShow(t){t.style.setProperty("display","block","important")}function printDebug(t,e){for(var l="DOM blockers debug:\n```",n=0,u=Object.keys(t);n<u.length;n++){var c=u[n];l+=`
- `.concat(c,":");for(var y=0,b=t[c];y<b.length;y++){var m=b[y];l+=`
- `.concat(e[m]?"🚫":"➡️"," ").concat(m)}}console.log("".concat(l,"\n```"))}function getColorGamut(){for(var t=0,e=["rec2020","p3","srgb"];t<e.length;t++){var l=e[t];if(matchMedia("(color-gamut: ".concat(l,")")).matches)return l}}function areColorsInverted(){if(doesMatch$4("inverted"))return!0;if(doesMatch$4("none"))return!1}function doesMatch$4(t){return matchMedia("(inverted-colors: ".concat(t,")")).matches}function areColorsForced(){if(doesMatch$3("active"))return!0;if(doesMatch$3("none"))return!1}function doesMatch$3(t){return matchMedia("(forced-colors: ".concat(t,")")).matches}var maxValueToCheck=100;function getMonochromeDepth(){if(matchMedia("(min-monochrome: 0)").matches){for(var t=0;t<=maxValueToCheck;++t)if(matchMedia("(max-monochrome: ".concat(t,")")).matches)return t;throw new Error("Too high value")}}function getContrastPreference(){if(doesMatch$2("no-preference"))return 0;if(doesMatch$2("high")||doesMatch$2("more"))return 1;if(doesMatch$2("low")||doesMatch$2("less"))return-1;if(doesMatch$2("forced"))return 10}function doesMatch$2(t){return matchMedia("(prefers-contrast: ".concat(t,")")).matches}function isMotionReduced(){if(doesMatch$1("reduce"))return!0;if(doesMatch$1("no-preference"))return!1}function doesMatch$1(t){return matchMedia("(prefers-reduced-motion: ".concat(t,")")).matches}function isHDR(){if(doesMatch("high"))return!0;if(doesMatch("standard"))return!1}function doesMatch(t){return matchMedia("(dynamic-range: ".concat(t,")")).matches}var M$1=Math,fallbackFn=function(){return 0};function getMathFingerprint(){var t=M$1.acos||fallbackFn,e=M$1.acosh||fallbackFn,l=M$1.asin||fallbackFn,n=M$1.asinh||fallbackFn,u=M$1.atanh||fallbackFn,c=M$1.atan||fallbackFn,y=M$1.sin||fallbackFn,b=M$1.sinh||fallbackFn,m=M$1.cos||fallbackFn,O=M$1.cosh||fallbackFn,N=M$1.tan||fallbackFn,L=M$1.tanh||fallbackFn,G=M$1.exp||fallbackFn,q=M$1.expm1||fallbackFn,J=M$1.log1p||fallbackFn,fe=function(Xe){return M$1.pow(M$1.PI,Xe)},ve=function(Xe){return M$1.log(Xe+M$1.sqrt(Xe*Xe-1))},ne=function(Xe){return M$1.log(Xe+M$1.sqrt(Xe*Xe+1))},Ue=function(Xe){return M$1.log((1+Xe)/(1-Xe))/2},De=function(Xe){return M$1.exp(Xe)-1/M$1.exp(Xe)/2},Ve=function(Xe){return(M$1.exp(Xe)+1/M$1.exp(Xe))/2},rt=function(Xe){return M$1.exp(Xe)-1},Ae=function(Xe){return(M$1.exp(2*Xe)-1)/(M$1.exp(2*Xe)+1)},Te=function(Xe){return M$1.log(1+Xe)};return{acos:t(.12312423423423424),acosh:e(1e308),acoshPf:ve(1e154),asin:l(.12312423423423424),asinh:n(1),asinhPf:ne(1),atanh:u(.5),atanhPf:Ue(.5),atan:c(.5),sin:y(-1e300),sinh:b(1),sinhPf:De(1),cos:m(10.000000000123),cosh:O(1),coshPf:Ve(1),tan:N(-1e300),tanh:L(1),tanhPf:Ae(1),exp:G(1),expm1:q(1),expm1Pf:rt(1),log1p:J(10),log1pPf:Te(10),powPI:fe(-100)}}var defaultText="mmMwWLliI0fiflO&1",presets={default:[],apple:[{font:"-apple-system-body"}],serif:[{fontFamily:"serif"}],sans:[{fontFamily:"sans-serif"}],mono:[{fontFamily:"monospace"}],min:[{fontSize:"1px"}],system:[{fontFamily:"system-ui"}]};function getFontPreferences(){return withNaturalFonts(function(t,e){for(var l={},n={},u=0,c=Object.keys(presets);u<c.length;u++){var y=c[u],b=presets[y],m=b[0],O=m===void 0?{}:m,N=b[1],L=N===void 0?defaultText:N,G=t.createElement("span");G.textContent=L,G.style.whiteSpace="nowrap";for(var q=0,J=Object.keys(O);q<J.length;q++){var fe=J[q],ve=O[fe];ve!==void 0&&(G.style[fe]=ve)}l[y]=G,e.appendChild(t.createElement("br")),e.appendChild(G)}for(var ne=0,Ue=Object.keys(presets);ne<Ue.length;ne++){var y=Ue[ne];n[y]=l[y].getBoundingClientRect().width}return n})}function withNaturalFonts(t,e){return e===void 0&&(e=4e3),withIframe(function(l,n){var u=n.document,c=u.body,y=c.style;y.width="".concat(e,"px"),y.webkitTextSizeAdjust=y.textSizeAdjust="none",isChromium()?c.style.zoom="".concat(1/n.devicePixelRatio):isWebKit()&&(c.style.zoom="reset");var b=u.createElement("div");return b.textContent=__spreadArray([],Array(e/20<<0),!0).map(function(){return"word"}).join(" "),c.appendChild(b),t(u,c)},'<!doctype html><html><head><meta name="viewport" content="width=device-width, initial-scale=1">')}function getVideoCard(){var t,e=document.createElement("canvas"),l=(t=e.getContext("webgl"))!==null&&t!==void 0?t:e.getContext("experimental-webgl");if(l&&"getExtension"in l){var n=l.getExtension("WEBGL_debug_renderer_info");if(n)return{vendor:(l.getParameter(n.UNMASKED_VENDOR_WEBGL)||"").toString(),renderer:(l.getParameter(n.UNMASKED_RENDERER_WEBGL)||"").toString()}}}function isPdfViewerEnabled(){return navigator.pdfViewerEnabled}function getArchitecture(){var t=new Float32Array(1),e=new Uint8Array(t.buffer);return t[0]=1/0,t[0]=t[0]-t[0],e[3]}var sources={fonts:getFonts,domBlockers:getDomBlockers,fontPreferences:getFontPreferences,audio:getAudioFingerprint,screenFrame:getRoundedScreenFrame,osCpu:getOsCpu,languages:getLanguages,colorDepth:getColorDepth,deviceMemory:getDeviceMemory,screenResolution:getScreenResolution,hardwareConcurrency:getHardwareConcurrency,timezone:getTimezone,sessionStorage:getSessionStorage,localStorage:getLocalStorage,indexedDB:getIndexedDB,openDatabase:getOpenDatabase,cpuClass:getCpuClass,platform:getPlatform$1,plugins:getPlugins,canvas:getCanvasFingerprint,touchSupport:getTouchSupport,vendor:getVendor,vendorFlavors:getVendorFlavors,cookiesEnabled:areCookiesEnabled,colorGamut:getColorGamut,invertedColors:areColorsInverted,forcedColors:areColorsForced,monochrome:getMonochromeDepth,contrast:getContrastPreference,reducedMotion:isMotionReduced,hdr:isHDR,math:getMathFingerprint,videoCard:getVideoCard,pdfViewerEnabled:isPdfViewerEnabled,architecture:getArchitecture};function loadBuiltinSources(t){return loadSources(sources,t,[])}var commentTemplate="$ if upgrade to Pro: https://fpjs.dev/pro";function getConfidence(t){var e=getOpenConfidenceScore(t),l=deriveProConfidenceScore(e);return{score:e,comment:commentTemplate.replace(/\$/g,"".concat(l))}}function getOpenConfidenceScore(t){if(isAndroid())return .4;if(isWebKit())return isDesktopSafari()?.5:.3;var e=t.platform.value||"";return/^Win/.test(e)?.6:/^Mac/.test(e)?.5:.7}function deriveProConfidenceScore(t){return round(.99+.01*t,1e-4)}function componentsToCanonicalString(t){for(var e="",l=0,n=Object.keys(t).sort();l<n.length;l++){var u=n[l],c=t[u],y=c.error?"error":JSON.stringify(c.value);e+="".concat(e?"|":"").concat(u.replace(/([:|\\])/g,"\\$1"),":").concat(y)}return e}function componentsToDebugString(t){return JSON.stringify(t,function(e,l){return l instanceof Error?errorToObject(l):l},2)}function hashComponents(t){return x64hash128(componentsToCanonicalString(t))}function makeLazyGetResult(t){var e,l=getConfidence(t);return{get visitorId(){return e===void 0&&(e=hashComponents(this.components)),e},set visitorId(n){e=n},confidence:l,components:t,version:version$1}}function prepareForSources(t){return t===void 0&&(t=50),requestIdleCallbackIfAvailable(t,t*2)}function makeAgent(t,e){var l=Date.now();return{get:function(n){return __awaiter(this,void 0,void 0,function(){var u,c,y;return __generator(this,function(b){switch(b.label){case 0:return u=Date.now(),[4,t()];case 1:return c=b.sent(),y=makeLazyGetResult(c),(e||n?.debug)&&console.log("Copy the text below to get the debug data:\n\n```\nversion: ".concat(y.version,`
- userAgent: `).concat(navigator.userAgent,`
- timeBetweenLoadAndGet: `).concat(u-l,`
- visitorId: `).concat(y.visitorId,`
- components: `).concat(componentsToDebugString(c),"\n```")),[2,y]}})})}}}function monitor(){if(!(window.__fpjs_d_m||Math.random()>=.001))try{var t=new XMLHttpRequest;t.open("get","https://m1.openfpcdn.io/fingerprintjs/v".concat(version$1,"/npm-monitoring"),!0),t.send()}catch(e){console.error(e)}}function load(t){var e=t===void 0?{}:t,l=e.delayFallback,n=e.debug,u=e.monitoring,c=u===void 0?!0:u;return __awaiter(this,void 0,void 0,function(){var y;return __generator(this,function(b){switch(b.label){case 0:return c&&monitor(),[4,prepareForSources(l)];case 1:return b.sent(),y=loadBuiltinSources({debug:n}),[2,makeAgent(y,n)]}})})}let pluginsConfig;const fetchPluginsConfig=async()=>(pluginsConfig||(pluginsConfig=await getConfig(new URL(""+new URL("../plugins/config.json",import.meta.url).href,import.meta.url).href)),pluginsConfig);let isPuginsConttextInit=!1;const registerPlugins$1=async(t=!1)=>{isPuginsConttextInit||(console.log("正在初始化插件上下文..."),await __vitePreload(()=>import("./init-CzXBwfa2.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url),console.log("初始化插件上下文成功"),isPuginsConttextInit=!0),await Promise.allSettled((await fetchPluginsConfig()).plugins.map(async e=>{let l=e,n=!1;if(typeof e=="object"){if(l=e.name,n=!!e?.dir,"isAfterLoad"in e&&e.isAfterLoad){if(!t)return}else if(t)return}else if(t)return;try{n?await __vitePreload(()=>import("../plugins/"+l+"/index.js"),[],import.meta.url):await __vitePreload(()=>import("../plugins/"+l+".js"),[],import.meta.url)}catch(u){console.warn(`插件${l}执行出现错误!`,u)}}))};var mapboxGl={exports:{}};(function(t,e){var l={};(function(n,u){t.exports=u()})(commonjsGlobal$1,function(){var n,u,c;function y(m,O){if(!n)n=O;else if(!u)u=O;else{var N="self.onerror = function() { console.error('An error occurred while parsing the WebWorker bundle. This is most likely due to improper transpilation by Babel; please see https://docs.mapbox.com/mapbox-gl-js/guides/install/#transpiling'); }; var sharedChunk = {}; ("+n+")(sharedChunk); ("+u+")(sharedChunk); self.onerror = null;",L={};n(L),c=O(L),typeof window<"u"&&window&&window.URL&&window.URL.createObjectURL&&(c.workerUrl=window.URL.createObjectURL(new Blob([N],{type:"text/javascript"})))}}y(["exports"],function(m){var O="2.8.2",N=L;function L(D,_,k,X){this.cx=3*D,this.bx=3*(k-D)-this.cx,this.ax=1-this.cx-this.bx,this.cy=3*_,this.by=3*(X-_)-this.cy,this.ay=1-this.cy-this.by,this.p1x=D,this.p1y=X,this.p2x=k,this.p2y=X}L.prototype.sampleCurveX=function(D){return((this.ax*D+this.bx)*D+this.cx)*D},L.prototype.sampleCurveY=function(D){return((this.ay*D+this.by)*D+this.cy)*D},L.prototype.sampleCurveDerivativeX=function(D){return(3*this.ax*D+2*this.bx)*D+this.cx},L.prototype.solveCurveX=function(D,_){var k,X,de,Ge,ft;for(_===void 0&&(_=1e-6),de=D,ft=0;ft<8;ft++){if(Ge=this.sampleCurveX(de)-D,Math.abs(Ge)<_)return de;var _t=this.sampleCurveDerivativeX(de);if(Math.abs(_t)<1e-6)break;de-=Ge/_t}if((de=D)<(k=0))return k;if(de>(X=1))return X;for(;k<X;){if(Ge=this.sampleCurveX(de),Math.abs(Ge-D)<_)return de;D>Ge?k=de:X=de,de=.5*(X-k)+k}return de},L.prototype.solve=function(D,_){return this.sampleCurveY(this.solveCurveX(D,_))};var G=q;function q(D,_){this.x=D,this.y=_}q.prototype={clone:function(){return new q(this.x,this.y)},add:function(D){return this.clone()._add(D)},sub:function(D){return this.clone()._sub(D)},multByPoint:function(D){return this.clone()._multByPoint(D)},divByPoint:function(D){return this.clone()._divByPoint(D)},mult:function(D){return this.clone()._mult(D)},div:function(D){return this.clone()._div(D)},rotate:function(D){return this.clone()._rotate(D)},rotateAround:function(D,_){return this.clone()._rotateAround(D,_)},matMult:function(D){return this.clone()._matMult(D)},unit:function(){return this.clone()._unit()},perp:function(){return this.clone()._perp()},round:function(){return this.clone()._round()},mag:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},equals:function(D){return this.x===D.x&&this.y===D.y},dist:function(D){return Math.sqrt(this.distSqr(D))},distSqr:function(D){var _=D.x-this.x,k=D.y-this.y;return _*_+k*k},angle:function(){return Math.atan2(this.y,this.x)},angleTo:function(D){return Math.atan2(this.y-D.y,this.x-D.x)},angleWith:function(D){return this.angleWithSep(D.x,D.y)},angleWithSep:function(D,_){return Math.atan2(this.x*_-this.y*D,this.x*D+this.y*_)},_matMult:function(D){var _=D[2]*this.x+D[3]*this.y;return this.x=D[0]*this.x+D[1]*this.y,this.y=_,this},_add:function(D){return this.x+=D.x,this.y+=D.y,this},_sub:function(D){return this.x-=D.x,this.y-=D.y,this},_mult:function(D){return this.x*=D,this.y*=D,this},_div:function(D){return this.x/=D,this.y/=D,this},_multByPoint:function(D){return this.x*=D.x,this.y*=D.y,this},_divByPoint:function(D){return this.x/=D.x,this.y/=D.y,this},_unit:function(){return this._div(this.mag()),this},_perp:function(){var D=this.y;return this.y=this.x,this.x=-D,this},_rotate:function(D){var _=Math.cos(D),k=Math.sin(D),X=k*this.x+_*this.y;return this.x=_*this.x-k*this.y,this.y=X,this},_rotateAround:function(D,_){var k=Math.cos(D),X=Math.sin(D),de=_.y+X*(this.x-_.x)+k*(this.y-_.y);return this.x=_.x+k*(this.x-_.x)-X*(this.y-_.y),this.y=de,this},_round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}},q.convert=function(D){return D instanceof q?D:Array.isArray(D)?new q(D[0],D[1]):D};var J=typeof self<"u"?self:{};const fe=Math.PI/180,ve=180/Math.PI;function ne(D){return D*fe}function Ue(D){return D*ve}const De=[[0,0],[1,0],[1,1],[0,1]];function Ve(D){if(D<=0)return 0;if(D>=1)return 1;const _=D*D,k=_*D;return 4*(D<.5?k:3*(D-_)+k-.75)}function rt(D,_,k,X){const de=new N(D,_,k,X);return function(Ge){return de.solve(Ge)}}const Ae=rt(.25,.1,.25,1);function Te(D,_,k){return Math.min(k,Math.max(_,D))}function Xe(D,_,k){return(k=Te((k-D)/(_-D),0,1))*k*(3-2*k)}function ie(D,_,k){const X=k-_,de=((D-_)%X+X)%X+_;return de===_?k:de}function ue(D,_,k){if(!D.length)return k(null,[]);let X=D.length;const de=new Array(D.length);let Ge=null;D.forEach((ft,_t)=>{_(ft,(At,Nt)=>{At&&(Ge=At),de[_t]=Nt,--X==0&&k(Ge,de)})})}function pt(D){const _=[];for(const k in D)_.push(D[k]);return _}function mt(D,..._){for(const k of _)for(const X in k)D[X]=k[X];return D}let Tt=1;function kt(){return Tt++}function It(){return function D(_){return _?(_^Math.random()*(16>>_/4)).toString(16):([1e7]+-[1e3]+-4e3+-8e3+-1e11).replace(/[018]/g,D)}()}function nn(D){return D<=1?1:Math.pow(2,Math.ceil(Math.log(D)/Math.LN2))}function tn(D){return!!D&&/^[0-9a-f]{8}-[0-9a-f]{4}-[4][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(D)}function pn(D,_){D.forEach(k=>{_[k]&&(_[k]=_[k].bind(_))})}function _n(D,_){return D.indexOf(_,D.length-_.length)!==-1}function Dn(D,_,k){const X={};for(const de in D)X[de]=_.call(this,D[de],de,D);return X}function an(D,_,k){const X={};for(const de in D)_.call(k||this,D[de],de,D)&&(X[de]=D[de]);return X}function Rn(D){return Array.isArray(D)?D.map(Rn):typeof D=="object"&&D?Dn(D,Rn):D}const Lt={};function wn(D){Lt[D]||(typeof console<"u"&&console.warn(D),Lt[D]=!0)}function hn(D,_,k){return(k.y-D.y)*(_.x-D.x)>(_.y-D.y)*(k.x-D.x)}function xn(D){let _=0;for(let k,X,de=0,Ge=D.length,ft=Ge-1;de<Ge;ft=de++)k=D[de],X=D[ft],_+=(X.x-k.x)*(k.y+X.y);return _}function $n(){return typeof WorkerGlobalScope<"u"&&typeof self<"u"&&self instanceof WorkerGlobalScope}function Xr(D){const _={};if(D.replace(/(?:^|(?:\s*\,\s*))([^\x00-\x20\(\)<>@\,;\:\\"\/\[\]\?\=\{\}\x7F]+)(?:\=(?:([^\x00-\x20\(\)<>@\,;\:\\"\/\[\]\?\=\{\}\x7F]+)|(?:\"((?:[^"\\]|\\.)*)\")))?/g,(k,X,de,Ge)=>{const ft=de||Ge;return _[X]=!ft||ft.toLowerCase(),""}),_["max-age"]){const k=parseInt(_["max-age"],10);isNaN(k)?delete _["max-age"]:_["max-age"]=k}return _}let ti,gn,Xn,Kn,Vn=null;function Yn(D){if(Vn==null){const _=D.navigator?D.navigator.userAgent:null;Vn=!!D.safari||!(!_||!(/\b(iPad|iPhone|iPod)\b/.test(_)||_.match("Safari")&&!_.match("Chrome")))}return Vn}function Vr(D){try{const _=J[D];return _.setItem("_mapbox_test_",1),_.removeItem("_mapbox_test_"),!0}catch{return!1}}const xi={now:()=>Xn!==void 0?Xn:J.performance.now(),setNow(D){Xn=D},restoreNow(){Xn=void 0},frame(D){const _=J.requestAnimationFrame(D);return{cancel:()=>J.cancelAnimationFrame(_)}},getImageData(D,_=0){const{width:k,height:X}=D;Kn||(Kn=J.document.createElement("canvas"));const de=Kn.getContext("2d");if(!de)throw new Error("failed to create canvas 2d context");return(k>Kn.width||X>Kn.height)&&(Kn.width=k,Kn.height=X),de.clearRect(-_,-_,k+2*_,X+2*_),de.drawImage(D,0,0,k,X),de.getImageData(-_,-_,k+2*_,X+2*_)},resolveURL:D=>(ti||(ti=J.document.createElement("a")),ti.href=D,ti.href),get devicePixelRatio(){return J.devicePixelRatio},get prefersReducedMotion(){return!!J.matchMedia&&(gn==null&&(gn=J.matchMedia("(prefers-reduced-motion: reduce)")),gn.matches)}};let Si;const qn={API_URL:"https://api.mapbox.com",get API_URL_REGEX(){if(Si==null){const D=/^((https?:)?\/\/)?([^\/]+\.)?mapbox\.c(n|om)(\/|\?|$)/i;try{Si=l.API_URL_REGEX!=null?new RegExp(l.API_URL_REGEX):D}catch{Si=D}}return Si},get EVENTS_URL(){return this.API_URL?this.API_URL.indexOf("https://api.mapbox.cn")===0?"https://events.mapbox.cn/events/v2":this.API_URL.indexOf("https://api.mapbox.com")===0?"https://events.mapbox.com/events/v2":null:null},SESSION_PATH:"/map-sessions/v1",FEEDBACK_URL:"https://apps.mapbox.com/feedback",TILE_URL_VERSION:"v4",RASTER_URL_PREFIX:"raster/v1",REQUIRE_ACCESS_TOKEN:!0,ACCESS_TOKEN:null,MAX_PARALLEL_IMAGE_REQUESTS:16},ia={supported:!1,testSupport:function(D){!ai&&ha&&(Ia?fi(D):Wi=D)}};let Wi,ha,ai=!1,Ia=!1;function fi(D){const _=D.createTexture();D.bindTexture(D.TEXTURE_2D,_);try{if(D.texImage2D(D.TEXTURE_2D,0,D.RGBA,D.RGBA,D.UNSIGNED_BYTE,ha),D.isContextLost())return;ia.supported=!0}catch{}D.deleteTexture(_),ai=!0}J.document&&(ha=J.document.createElement("img"),ha.onload=function(){Wi&&fi(Wi),Wi=null,Ia=!0},ha.onerror=function(){ai=!0,Wi=null},ha.src="data:image/webp;base64,UklGRh4AAABXRUJQVlA4TBEAAAAvAQAAAAfQ//73v/+BiOh/AAA=");const An="01",sa="NO_ACCESS_TOKEN";function Nn(D){return D.indexOf("mapbox:")===0}function fn(D){return qn.API_URL_REGEX.test(D)}const un=/^(\w+):\/\/([^/?]*)(\/[^?]+)?\??(.+)?/;function Ln(D){const _=D.match(un);if(!_)throw new Error("Unable to parse URL object");return{protocol:_[1],authority:_[2],path:_[3]||"/",params:_[4]?_[4].split("&"):[]}}function hr(D){const _=D.params.length?`?${D.params.join("&")}`:"";return`${D.protocol}://${D.authority}${D.path}${_}`}function hi(D){if(!D)return null;const _=D.split(".");if(!_||_.length!==3)return null;try{return JSON.parse(decodeURIComponent(J.atob(_[1]).split("").map(k=>"%"+("00"+k.charCodeAt(0).toString(16)).slice(-2)).join("")))}catch{return null}}class bi{constructor(_){this.type=_,this.anonId=null,this.eventData={},this.queue=[],this.pendingRequest=null}getStorageKey(_){const k=hi(qn.ACCESS_TOKEN);let X="";return X=k&&k.u?J.btoa(encodeURIComponent(k.u).replace(/%([0-9A-F]{2})/g,(de,Ge)=>String.fromCharCode(+("0x"+Ge)))):qn.ACCESS_TOKEN||"",_?`mapbox.eventData.${_}:${X}`:`mapbox.eventData:${X}`}fetchEventData(){const _=Vr("localStorage"),k=this.getStorageKey(),X=this.getStorageKey("uuid");if(_)try{const de=J.localStorage.getItem(k);de&&(this.eventData=JSON.parse(de));const Ge=J.localStorage.getItem(X);Ge&&(this.anonId=Ge)}catch{wn("Unable to read from LocalStorage")}}saveEventData(){const _=Vr("localStorage"),k=this.getStorageKey(),X=this.getStorageKey("uuid");if(_)try{J.localStorage.setItem(X,this.anonId),Object.keys(this.eventData).length>=1&&J.localStorage.setItem(k,JSON.stringify(this.eventData))}catch{wn("Unable to write to LocalStorage")}}processRequests(_){}postEvent(_,k,X,de){if(!qn.EVENTS_URL)return;const Ge=Ln(qn.EVENTS_URL);Ge.params.push(`access_token=${de||qn.ACCESS_TOKEN||""}`);const ft={event:this.type,created:new Date(_).toISOString(),sdkIdentifier:"mapbox-gl-js",sdkVersion:O,skuId:An,userId:this.anonId},_t=k?mt(ft,k):ft,At={url:hr(Ge),headers:{"Content-Type":"text/plain"},body:JSON.stringify([_t])};this.pendingRequest=Ei(At,Nt=>{this.pendingRequest=null,X(Nt),this.saveEventData(),this.processRequests(de)})}queueRequest(_,k){this.queue.push(_),this.processRequests(k)}}const Ra=new class extends bi{constructor(D){super("appUserTurnstile"),this._customAccessToken=D}postTurnstileEvent(D,_){qn.EVENTS_URL&&qn.ACCESS_TOKEN&&Array.isArray(D)&&D.some(k=>Nn(k)||fn(k))&&this.queueRequest(Date.now(),_)}processRequests(D){if(this.pendingRequest||this.queue.length===0)return;this.anonId&&this.eventData.lastSuccess&&this.eventData.tokenU||this.fetchEventData();const _=hi(qn.ACCESS_TOKEN),k=_?_.u:qn.ACCESS_TOKEN;let X=k!==this.eventData.tokenU;tn(this.anonId)||(this.anonId=It(),X=!0);const de=this.queue.shift();if(this.eventData.lastSuccess){const Ge=new Date(this.eventData.lastSuccess),ft=new Date(de),_t=(de-this.eventData.lastSuccess)/864e5;X=X||_t>=1||_t<-1||Ge.getDate()!==ft.getDate()}else X=!0;X?this.postEvent(de,{"enabled.telemetry":!1},Ge=>{Ge||(this.eventData.lastSuccess=de,this.eventData.tokenU=k)},D):this.processRequests()}},so=Ra.postTurnstileEvent.bind(Ra),Pi=new class extends bi{constructor(){super("map.load"),this.success={},this.skuToken=""}postMapLoadEvent(D,_,k,X){this.skuToken=_,this.errorCb=X,qn.EVENTS_URL&&(k||qn.ACCESS_TOKEN?this.queueRequest({id:D,timestamp:Date.now()},k):this.errorCb(new Error(sa)))}processRequests(D){if(this.pendingRequest||this.queue.length===0)return;const{id:_,timestamp:k}=this.queue.shift();_&&this.success[_]||(this.anonId||this.fetchEventData(),tn(this.anonId)||(this.anonId=It()),this.postEvent(k,{skuToken:this.skuToken},X=>{X?this.errorCb(X):_&&(this.success[_]=!0)},D))}},oi=Pi.postMapLoadEvent.bind(Pi),Ni=new class extends bi{constructor(){super("map.auth"),this.success={},this.skuToken=""}getSession(D,_,k,X){if(!qn.API_URL||!qn.SESSION_PATH)return;const de=Ln(qn.API_URL+qn.SESSION_PATH);de.params.push(`sku=${_||""}`),de.params.push(`access_token=${X||qn.ACCESS_TOKEN||""}`);const Ge={url:hr(de),headers:{"Content-Type":"text/plain"}};this.pendingRequest=$t(Ge,ft=>{this.pendingRequest=null,k(ft),this.saveEventData(),this.processRequests(X)})}getSessionAPI(D,_,k,X){this.skuToken=_,this.errorCb=X,qn.SESSION_PATH&&qn.API_URL&&(k||qn.ACCESS_TOKEN?this.queueRequest({id:D,timestamp:Date.now()},k):this.errorCb(new Error(sa)))}processRequests(D){if(this.pendingRequest||this.queue.length===0)return;const{id:_,timestamp:k}=this.queue.shift();_&&this.success[_]||this.getSession(k,this.skuToken,X=>{X?this.errorCb(X):_&&(this.success[_]=!0)},D)}},za=Ni.getSessionAPI.bind(Ni),ki=new Set,Aa="mapbox-tiles";let Ja,yo,ls=500,xo=50;function _o(){J.caches&&!Ja&&(Ja=J.caches.open(Aa))}function Ao(D){const _=D.indexOf("?");return _<0?D:D.slice(0,_)}let il=1/0;const zr={Unknown:"Unknown",Style:"Style",Source:"Source",Tile:"Tile",Glyphs:"Glyphs",SpriteImage:"SpriteImage",SpriteJSON:"SpriteJSON",Image:"Image"};typeof Object.freeze=="function"&&Object.freeze(zr);class zn extends Error{constructor(_,k,X){k===401&&fn(X)&&(_+=": you may have provided an invalid Mapbox access token. See https://www.mapbox.com/api-documentation/#access-tokens-and-token-scopes"),super(_),this.status=k,this.url=X}toString(){return`${this.name}: ${this.message} (${this.status}): ${this.url}`}}const Un=$n()?()=>self.worker&&self.worker.referrer:()=>(J.location.protocol==="blob:"?J.parent:J).location.href,Gr=function(D,_){if(!(/^file:/.test(k=D.url)||/^file:/.test(Un())&&!/^\w+:/.test(k))){if(J.fetch&&J.Request&&J.AbortController&&J.Request.prototype.hasOwnProperty("signal"))return function(X,de){const Ge=new J.AbortController,ft=new J.Request(X.url,{method:X.method||"GET",body:X.body,credentials:X.credentials,headers:X.headers,referrer:Un(),signal:Ge.signal});let _t=!1,At=!1;const Nt=(cn=ft.url).indexOf("sku=")>0&&fn(cn);var cn;X.type==="json"&&ft.headers.set("Accept","application/json");const vn=(jn,Zn,Br)=>{if(At)return;if(jn&&jn.message!=="SecurityError"&&wn(jn),Zn&&Br)return bn(Zn);const Jr=Date.now();J.fetch(ft).then(si=>{if(si.ok){const Li=Nt?si.clone():null;return bn(si,Li,Jr)}return de(new zn(si.statusText,si.status,X.url))}).catch(si=>{si.code!==20&&de(new Error(si.message))})},bn=(jn,Zn,Br)=>{(X.type==="arrayBuffer"?jn.arrayBuffer():X.type==="json"?jn.json():jn.text()).then(Jr=>{At||(Zn&&Br&&function(si,Li,vi){if(_o(),!Ja)return;const ui={status:Li.status,statusText:Li.statusText,headers:new J.Headers};Li.headers.forEach((Ua,Ga)=>ui.headers.set(Ga,Ua));const ua=Xr(Li.headers.get("Cache-Control")||"");if(ua["no-store"])return;ua["max-age"]&&ui.headers.set("Expires",new Date(vi+1e3*ua["max-age"]).toUTCString());const ba=ui.headers.get("Expires");ba&&(new Date(ba).getTime()-vi<42e4||function(Ua,Ga){if(yo===void 0)try{new Response(new ReadableStream),yo=!0}catch{yo=!1}yo?Ga(Ua.body):Ua.blob().then(Ga)}(Li,Ua=>{const Ga=new J.Response(Ua,ui);_o(),Ja&&Ja.then(ho=>ho.put(Ao(si.url),Ga)).catch(ho=>wn(ho.message))}))}(ft,Zn,Br),_t=!0,de(null,Jr,jn.headers.get("Cache-Control"),jn.headers.get("Expires")))}).catch(Jr=>{At||de(new Error(Jr.message))})};return Nt?function(jn,Zn){if(_o(),!Ja)return Zn(null);const Br=Ao(jn.url);Ja.then(Jr=>{Jr.match(Br).then(si=>{const Li=function(vi){if(!vi)return!1;const ui=new Date(vi.headers.get("Expires")||0),ua=Xr(vi.headers.get("Cache-Control")||"");return ui>Date.now()&&!ua["no-cache"]}(si);Jr.delete(Br),Li&&Jr.put(Br,si.clone()),Zn(null,si,Li)}).catch(Zn)}).catch(Zn)}(ft,vn):vn(null,null),{cancel:()=>{At=!0,_t||Ge.abort()}}}(D,_);if($n()&&self.worker&&self.worker.actor)return self.worker.actor.send("getResource",D,_,void 0,!0)}var k;return function(X,de){const Ge=new J.XMLHttpRequest;Ge.open(X.method||"GET",X.url,!0),X.type==="arrayBuffer"&&(Ge.responseType="arraybuffer");for(const ft in X.headers)Ge.setRequestHeader(ft,X.headers[ft]);return X.type==="json"&&(Ge.responseType="text",Ge.setRequestHeader("Accept","application/json")),Ge.withCredentials=X.credentials==="include",Ge.onerror=()=>{de(new Error(Ge.statusText))},Ge.onload=()=>{if((Ge.status>=200&&Ge.status<300||Ge.status===0)&&Ge.response!==null){let ft=Ge.response;if(X.type==="json")try{ft=JSON.parse(Ge.response)}catch(_t){return de(_t)}de(null,ft,Ge.getResponseHeader("Cache-Control"),Ge.getResponseHeader("Expires"))}else de(new zn(Ge.statusText,Ge.status,X.url))},Ge.send(X.body),{cancel:()=>Ge.abort()}}(D,_)},ni=function(D,_){return Gr(mt(D,{type:"arrayBuffer"}),_)},Ei=function(D,_){return Gr(mt(D,{method:"POST"}),_)},$t=function(D,_){return Gr(mt(D,{method:"GET"}),_)};function ta(D){const _=J.document.createElement("a");return _.href=D,_.protocol===J.document.location.protocol&&_.host===J.document.location.host}const Hi="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAC0lEQVQYV2NgAAIAAAUAAarVyFEAAAAASUVORK5CYII=";let Ai,Ea;Ai=[],Ea=0;const wo=function(D,_){if(ia.supported&&(D.headers||(D.headers={}),D.headers.accept="image/webp,*/*"),Ea>=qn.MAX_PARALLEL_IMAGE_REQUESTS){const Ge={requestParameters:D,callback:_,cancelled:!1,cancel(){this.cancelled=!0}};return Ai.push(Ge),Ge}Ea++;let k=!1;const X=()=>{if(!k)for(k=!0,Ea--;Ai.length&&Ea<qn.MAX_PARALLEL_IMAGE_REQUESTS;){const Ge=Ai.shift(),{requestParameters:ft,callback:_t,cancelled:At}=Ge;At||(Ge.cancel=wo(ft,_t).cancel)}},de=ni(D,(Ge,ft,_t,At)=>{X(),Ge?_(Ge):ft&&(J.createImageBitmap?function(Nt,cn){const vn=new J.Blob([new Uint8Array(Nt)],{type:"image/png"});J.createImageBitmap(vn).then(bn=>{cn(null,bn)}).catch(bn=>{cn(new Error(`Could not load image because of ${bn.message}. Please make sure to use a supported image type such as PNG or JPEG. Note that SVGs are not supported.`))})}(ft,(Nt,cn)=>_(Nt,cn,_t,At)):function(Nt,cn){const vn=new J.Image,bn=J.URL;vn.onload=()=>{cn(null,vn),bn.revokeObjectURL(vn.src),vn.onload=null,J.requestAnimationFrame(()=>{vn.src=Hi})},vn.onerror=()=>cn(new Error("Could not load image. Please make sure to use a supported image type such as PNG or JPEG. Note that SVGs are not supported."));const jn=new J.Blob([new Uint8Array(Nt)],{type:"image/png"});vn.src=Nt.byteLength?bn.createObjectURL(jn):Hi}(ft,(Nt,cn)=>_(Nt,cn,_t,At)))});return{cancel:()=>{de.cancel(),X()}}};function to(D,_,k){k[D]&&k[D].indexOf(_)!==-1||(k[D]=k[D]||[],k[D].push(_))}function zo(D,_,k){if(k&&k[D]){const X=k[D].indexOf(_);X!==-1&&k[D].splice(X,1)}}class Po{constructor(_,k={}){mt(this,k),this.type=_}}class Lo extends Po{constructor(_,k={}){super("error",mt({error:_},k))}}class Wo{on(_,k){return this._listeners=this._listeners||{},to(_,k,this._listeners),this}off(_,k){return zo(_,k,this._listeners),zo(_,k,this._oneTimeListeners),this}once(_,k){return k?(this._oneTimeListeners=this._oneTimeListeners||{},to(_,k,this._oneTimeListeners),this):new Promise(X=>this.once(_,X))}fire(_,k){typeof _=="string"&&(_=new Po(_,k||{}));const X=_.type;if(this.listens(X)){_.target=this;const de=this._listeners&&this._listeners[X]?this._listeners[X].slice():[];for(const _t of de)_t.call(this,_);const Ge=this._oneTimeListeners&&this._oneTimeListeners[X]?this._oneTimeListeners[X].slice():[];for(const _t of Ge)zo(X,_t,this._oneTimeListeners),_t.call(this,_);const ft=this._eventedParent;ft&&(mt(_,typeof this._eventedParentData=="function"?this._eventedParentData():this._eventedParentData),ft.fire(_))}else _ instanceof Lo&&console.error(_.error);return this}listens(_){return!!(this._listeners&&this._listeners[_]&&this._listeners[_].length>0||this._oneTimeListeners&&this._oneTimeListeners[_]&&this._oneTimeListeners[_].length>0||this._eventedParent&&this._eventedParent.listens(_))}setEventedParent(_,k){return this._eventedParent=_,this._eventedParentData=k,this}}var ma=JSON.parse('{"$version":8,"$root":{"version":{"required":true,"type":"enum","values":[8]},"name":{"type":"string"},"metadata":{"type":"*"},"center":{"type":"array","value":"number"},"zoom":{"type":"number"},"bearing":{"type":"number","default":0,"period":360,"units":"degrees"},"pitch":{"type":"number","default":0,"units":"degrees"},"light":{"type":"light"},"terrain":{"type":"terrain"},"fog":{"type":"fog"},"sources":{"required":true,"type":"sources"},"sprite":{"type":"string"},"glyphs":{"type":"string"},"transition":{"type":"transition"},"projection":{"type":"projection"},"layers":{"required":true,"type":"array","value":"layer"}},"sources":{"*":{"type":"source"}},"source":["source_vector","source_raster","source_raster_dem","source_geojson","source_video","source_image"],"source_vector":{"type":{"required":true,"type":"enum","values":{"vector":{}}},"url":{"type":"string"},"tiles":{"type":"array","value":"string"},"bounds":{"type":"array","value":"number","length":4,"default":[-180,-85.051129,180,85.051129]},"scheme":{"type":"enum","values":{"xyz":{},"tms":{}},"default":"xyz"},"minzoom":{"type":"number","default":0},"maxzoom":{"type":"number","default":22},"attribution":{"type":"string"},"promoteId":{"type":"promoteId"},"volatile":{"type":"boolean","default":false},"*":{"type":"*"}},"source_raster":{"type":{"required":true,"type":"enum","values":{"raster":{}}},"url":{"type":"string"},"tiles":{"type":"array","value":"string"},"bounds":{"type":"array","value":"number","length":4,"default":[-180,-85.051129,180,85.051129]},"minzoom":{"type":"number","default":0},"maxzoom":{"type":"number","default":22},"tileSize":{"type":"number","default":512,"units":"pixels"},"scheme":{"type":"enum","values":{"xyz":{},"tms":{}},"default":"xyz"},"attribution":{"type":"string"},"volatile":{"type":"boolean","default":false},"*":{"type":"*"}},"source_raster_dem":{"type":{"required":true,"type":"enum","values":{"raster-dem":{}}},"url":{"type":"string"},"tiles":{"type":"array","value":"string"},"bounds":{"type":"array","value":"number","length":4,"default":[-180,-85.051129,180,85.051129]},"minzoom":{"type":"number","default":0},"maxzoom":{"type":"number","default":22},"tileSize":{"type":"number","default":512,"units":"pixels"},"attribution":{"type":"string"},"encoding":{"type":"enum","values":{"terrarium":{},"mapbox":{}},"default":"mapbox"},"volatile":{"type":"boolean","default":false},"*":{"type":"*"}},"source_geojson":{"type":{"required":true,"type":"enum","values":{"geojson":{}}},"data":{"type":"*"},"maxzoom":{"type":"number","default":18},"attribution":{"type":"string"},"buffer":{"type":"number","default":128,"maximum":512,"minimum":0},"filter":{"type":"*"},"tolerance":{"type":"number","default":0.375},"cluster":{"type":"boolean","default":false},"clusterRadius":{"type":"number","default":50,"minimum":0},"clusterMaxZoom":{"type":"number"},"clusterMinPoints":{"type":"number"},"clusterProperties":{"type":"*"},"lineMetrics":{"type":"boolean","default":false},"generateId":{"type":"boolean","default":false},"promoteId":{"type":"promoteId"}},"source_video":{"type":{"required":true,"type":"enum","values":{"video":{}}},"urls":{"required":true,"type":"array","value":"string"},"coordinates":{"required":true,"type":"array","length":4,"value":{"type":"array","length":2,"value":"number"}}},"source_image":{"type":{"required":true,"type":"enum","values":{"image":{}}},"url":{"required":true,"type":"string"},"coordinates":{"required":true,"type":"array","length":4,"value":{"type":"array","length":2,"value":"number"}}},"layer":{"id":{"type":"string","required":true},"type":{"type":"enum","values":{"fill":{},"line":{},"symbol":{},"circle":{},"heatmap":{},"fill-extrusion":{},"raster":{},"hillshade":{},"background":{},"sky":{}},"required":true},"metadata":{"type":"*"},"source":{"type":"string"},"source-layer":{"type":"string"},"minzoom":{"type":"number","minimum":0,"maximum":24},"maxzoom":{"type":"number","minimum":0,"maximum":24},"filter":{"type":"filter"},"layout":{"type":"layout"},"paint":{"type":"paint"}},"layout":["layout_fill","layout_line","layout_circle","layout_heatmap","layout_fill-extrusion","layout_symbol","layout_raster","layout_hillshade","layout_background","layout_sky"],"layout_background":{"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_sky":{"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_fill":{"fill-sort-key":{"type":"number","expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_circle":{"circle-sort-key":{"type":"number","expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_heatmap":{"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_fill-extrusion":{"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_line":{"line-cap":{"type":"enum","values":{"butt":{},"round":{},"square":{}},"default":"butt","expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"line-join":{"type":"enum","values":{"bevel":{},"round":{},"miter":{}},"default":"miter","expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"line-miter-limit":{"type":"number","default":2,"requires":[{"line-join":"miter"}],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"line-round-limit":{"type":"number","default":1.05,"requires":[{"line-join":"round"}],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"line-sort-key":{"type":"number","expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_symbol":{"symbol-placement":{"type":"enum","values":{"point":{},"line":{},"line-center":{}},"default":"point","expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"symbol-spacing":{"type":"number","default":250,"minimum":1,"units":"pixels","requires":[{"symbol-placement":"line"}],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"symbol-avoid-edges":{"type":"boolean","default":false,"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"symbol-sort-key":{"type":"number","expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"symbol-z-order":{"type":"enum","values":{"auto":{},"viewport-y":{},"source":{}},"default":"auto","expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"icon-allow-overlap":{"type":"boolean","default":false,"requires":["icon-image"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"icon-ignore-placement":{"type":"boolean","default":false,"requires":["icon-image"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"icon-optional":{"type":"boolean","default":false,"requires":["icon-image","text-field"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"icon-rotation-alignment":{"type":"enum","values":{"map":{},"viewport":{},"auto":{}},"default":"auto","requires":["icon-image"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"icon-size":{"type":"number","default":1,"minimum":0,"units":"factor of the original icon size","requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"icon-text-fit":{"type":"enum","values":{"none":{},"width":{},"height":{},"both":{}},"default":"none","requires":["icon-image","text-field"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"icon-text-fit-padding":{"type":"array","value":"number","length":4,"default":[0,0,0,0],"units":"pixels","requires":["icon-image","text-field",{"icon-text-fit":["both","width","height"]}],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"icon-image":{"type":"resolvedImage","tokens":true,"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"icon-rotate":{"type":"number","default":0,"period":360,"units":"degrees","requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"icon-padding":{"type":"number","default":2,"minimum":0,"units":"pixels","requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"icon-keep-upright":{"type":"boolean","default":false,"requires":["icon-image",{"icon-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"icon-offset":{"type":"array","value":"number","length":2,"default":[0,0],"requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"icon-anchor":{"type":"enum","values":{"center":{},"left":{},"right":{},"top":{},"bottom":{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},"default":"center","requires":["icon-image"],"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"icon-pitch-alignment":{"type":"enum","values":{"map":{},"viewport":{},"auto":{}},"default":"auto","requires":["icon-image"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-pitch-alignment":{"type":"enum","values":{"map":{},"viewport":{},"auto":{}},"default":"auto","requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-rotation-alignment":{"type":"enum","values":{"map":{},"viewport":{},"auto":{}},"default":"auto","requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-field":{"type":"formatted","default":"","tokens":true,"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-font":{"type":"array","value":"string","default":["Open Sans Regular","Arial Unicode MS Regular"],"requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-size":{"type":"number","default":16,"minimum":0,"units":"pixels","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-max-width":{"type":"number","default":10,"minimum":0,"units":"ems","requires":["text-field",{"symbol-placement":["point"]}],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-line-height":{"type":"number","default":1.2,"units":"ems","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-letter-spacing":{"type":"number","default":0,"units":"ems","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-justify":{"type":"enum","values":{"auto":{},"left":{},"center":{},"right":{}},"default":"center","requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-radial-offset":{"type":"number","units":"ems","default":0,"requires":["text-field"],"property-type":"data-driven","expression":{"interpolated":true,"parameters":["zoom","feature"]}},"text-variable-anchor":{"type":"array","value":"enum","values":{"center":{},"left":{},"right":{},"top":{},"bottom":{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},"requires":["text-field",{"symbol-placement":["point"]}],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-anchor":{"type":"enum","values":{"center":{},"left":{},"right":{},"top":{},"bottom":{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},"default":"center","requires":["text-field",{"!":"text-variable-anchor"}],"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-max-angle":{"type":"number","default":45,"units":"degrees","requires":["text-field",{"symbol-placement":["line","line-center"]}],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"text-writing-mode":{"type":"array","value":"enum","values":{"horizontal":{},"vertical":{}},"requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-rotate":{"type":"number","default":0,"period":360,"units":"degrees","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-padding":{"type":"number","default":2,"minimum":0,"units":"pixels","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"text-keep-upright":{"type":"boolean","default":true,"requires":["text-field",{"text-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-transform":{"type":"enum","values":{"none":{},"uppercase":{},"lowercase":{}},"default":"none","requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-offset":{"type":"array","value":"number","units":"ems","length":2,"default":[0,0],"requires":["text-field",{"!":"text-radial-offset"}],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-allow-overlap":{"type":"boolean","default":false,"requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-ignore-placement":{"type":"boolean","default":false,"requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-optional":{"type":"boolean","default":false,"requires":["text-field","icon-image"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_raster":{"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_hillshade":{"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"filter":{"type":"array","value":"*"},"filter_symbol":{"type":"boolean","default":false,"transition":false,"property-type":"data-driven","expression":{"interpolated":false,"parameters":["zoom","feature","pitch","distance-from-center"]}},"filter_fill":{"type":"boolean","default":false,"transition":false,"property-type":"data-driven","expression":{"interpolated":false,"parameters":["zoom","feature"]}},"filter_line":{"type":"boolean","default":false,"transition":false,"property-type":"data-driven","expression":{"interpolated":false,"parameters":["zoom","feature"]}},"filter_circle":{"type":"boolean","default":false,"transition":false,"property-type":"data-driven","expression":{"interpolated":false,"parameters":["zoom","feature"]}},"filter_fill-extrusion":{"type":"boolean","default":false,"transition":false,"property-type":"data-driven","expression":{"interpolated":false,"parameters":["zoom","feature"]}},"filter_heatmap":{"type":"boolean","default":false,"transition":false,"property-type":"data-driven","expression":{"interpolated":false,"parameters":["zoom","feature"]}},"filter_operator":{"type":"enum","values":{"==":{},"!=":{},">":{},">=":{},"<":{},"<=":{},"in":{},"!in":{},"all":{},"any":{},"none":{},"has":{},"!has":{},"within":{}}},"geometry_type":{"type":"enum","values":{"Point":{},"LineString":{},"Polygon":{}}},"function":{"expression":{"type":"expression"},"stops":{"type":"array","value":"function_stop"},"base":{"type":"number","default":1,"minimum":0},"property":{"type":"string","default":"$zoom"},"type":{"type":"enum","values":{"identity":{},"exponential":{},"interval":{},"categorical":{}},"default":"exponential"},"colorSpace":{"type":"enum","values":{"rgb":{},"lab":{},"hcl":{}},"default":"rgb"},"default":{"type":"*","required":false}},"function_stop":{"type":"array","minimum":0,"maximum":24,"value":["number","color"],"length":2},"expression":{"type":"array","value":"*","minimum":1},"fog":{"range":{"type":"array","default":[0.5,10],"minimum":-20,"maximum":20,"length":2,"value":"number","property-type":"data-constant","transition":true,"expression":{"interpolated":true,"parameters":["zoom"]}},"color":{"type":"color","property-type":"data-constant","default":"#ffffff","expression":{"interpolated":true,"parameters":["zoom"]},"transition":true},"horizon-blend":{"type":"number","property-type":"data-constant","default":0.1,"minimum":0,"maximum":1,"expression":{"interpolated":true,"parameters":["zoom"]},"transition":true}},"light":{"anchor":{"type":"enum","default":"viewport","values":{"map":{},"viewport":{}},"property-type":"data-constant","transition":false,"expression":{"interpolated":false,"parameters":["zoom"]}},"position":{"type":"array","default":[1.15,210,30],"length":3,"value":"number","property-type":"data-constant","transition":true,"expression":{"interpolated":true,"parameters":["zoom"]}},"color":{"type":"color","property-type":"data-constant","default":"#ffffff","expression":{"interpolated":true,"parameters":["zoom"]},"transition":true},"intensity":{"type":"number","property-type":"data-constant","default":0.5,"minimum":0,"maximum":1,"expression":{"interpolated":true,"parameters":["zoom"]},"transition":true}},"projection":{"name":{"type":"enum","values":{"albers":{},"equalEarth":{},"equirectangular":{},"lambertConformalConic":{},"mercator":{},"naturalEarth":{},"winkelTripel":{}},"default":"mercator","required":true},"center":{"type":"array","length":2,"value":"number","property-type":"data-constant","transition":false,"requires":[{"name":["albers","lambertConformalConic"]}]},"parallels":{"type":"array","length":2,"value":"number","property-type":"data-constant","transition":false,"requires":[{"name":["albers","lambertConformalConic"]}]}},"terrain":{"source":{"type":"string","required":true},"exaggeration":{"type":"number","property-type":"data-constant","default":1,"minimum":0,"maximum":1000,"expression":{"interpolated":true,"parameters":["zoom"]},"transition":true}},"paint":["paint_fill","paint_line","paint_circle","paint_heatmap","paint_fill-extrusion","paint_symbol","paint_raster","paint_hillshade","paint_background","paint_sky"],"paint_fill":{"fill-antialias":{"type":"boolean","default":true,"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"fill-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-color":{"type":"color","default":"#000000","transition":true,"requires":[{"!":"fill-pattern"}],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-outline-color":{"type":"color","transition":true,"requires":[{"!":"fill-pattern"},{"fill-antialias":true}],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-translate":{"type":"array","value":"number","length":2,"default":[0,0],"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"fill-translate-anchor":{"type":"enum","values":{"map":{},"viewport":{}},"default":"map","requires":["fill-translate"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"fill-pattern":{"type":"resolvedImage","transition":true,"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"cross-faded-data-driven"}},"paint_fill-extrusion":{"fill-extrusion-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"fill-extrusion-color":{"type":"color","default":"#000000","transition":true,"requires":[{"!":"fill-extrusion-pattern"}],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-translate":{"type":"array","value":"number","length":2,"default":[0,0],"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"fill-extrusion-translate-anchor":{"type":"enum","values":{"map":{},"viewport":{}},"default":"map","requires":["fill-extrusion-translate"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"fill-extrusion-pattern":{"type":"resolvedImage","transition":true,"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"cross-faded-data-driven"},"fill-extrusion-height":{"type":"number","default":0,"minimum":0,"units":"meters","transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-base":{"type":"number","default":0,"minimum":0,"units":"meters","transition":true,"requires":["fill-extrusion-height"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-vertical-gradient":{"type":"boolean","default":true,"transition":false,"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"}},"paint_line":{"line-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-color":{"type":"color","default":"#000000","transition":true,"requires":[{"!":"line-pattern"}],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-translate":{"type":"array","value":"number","length":2,"default":[0,0],"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"line-translate-anchor":{"type":"enum","values":{"map":{},"viewport":{}},"default":"map","requires":["line-translate"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"line-width":{"type":"number","default":1,"minimum":0,"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-gap-width":{"type":"number","default":0,"minimum":0,"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-offset":{"type":"number","default":0,"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-blur":{"type":"number","default":0,"minimum":0,"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-dasharray":{"type":"array","value":"number","minimum":0,"transition":true,"units":"line widths","requires":[{"!":"line-pattern"}],"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"cross-faded-data-driven"},"line-pattern":{"type":"resolvedImage","transition":true,"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"cross-faded-data-driven"},"line-gradient":{"type":"color","transition":false,"requires":[{"!":"line-pattern"},{"source":"geojson","has":{"lineMetrics":true}}],"expression":{"interpolated":true,"parameters":["line-progress"]},"property-type":"color-ramp"}},"paint_circle":{"circle-radius":{"type":"number","default":5,"minimum":0,"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-color":{"type":"color","default":"#000000","transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-blur":{"type":"number","default":0,"transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-translate":{"type":"array","value":"number","length":2,"default":[0,0],"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"circle-translate-anchor":{"type":"enum","values":{"map":{},"viewport":{}},"default":"map","requires":["circle-translate"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"circle-pitch-scale":{"type":"enum","values":{"map":{},"viewport":{}},"default":"map","expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"circle-pitch-alignment":{"type":"enum","values":{"map":{},"viewport":{}},"default":"viewport","expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"circle-stroke-width":{"type":"number","default":0,"minimum":0,"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-color":{"type":"color","default":"#000000","transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"}},"paint_heatmap":{"heatmap-radius":{"type":"number","default":30,"minimum":1,"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-weight":{"type":"number","default":1,"minimum":0,"transition":false,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-intensity":{"type":"number","default":1,"minimum":0,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"heatmap-color":{"type":"color","default":["interpolate",["linear"],["heatmap-density"],0,"rgba(0, 0, 255, 0)",0.1,"royalblue",0.3,"cyan",0.5,"lime",0.7,"yellow",1,"red"],"transition":false,"expression":{"interpolated":true,"parameters":["heatmap-density"]},"property-type":"color-ramp"},"heatmap-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"}},"paint_symbol":{"icon-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-color":{"type":"color","default":"#000000","transition":true,"requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-color":{"type":"color","default":"rgba(0, 0, 0, 0)","transition":true,"requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-width":{"type":"number","default":0,"minimum":0,"transition":true,"units":"pixels","requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-blur":{"type":"number","default":0,"minimum":0,"transition":true,"units":"pixels","requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-translate":{"type":"array","value":"number","length":2,"default":[0,0],"transition":true,"units":"pixels","requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"icon-translate-anchor":{"type":"enum","values":{"map":{},"viewport":{}},"default":"map","requires":["icon-image","icon-translate"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-color":{"type":"color","default":"#000000","transition":true,"overridable":true,"requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-color":{"type":"color","default":"rgba(0, 0, 0, 0)","transition":true,"requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-width":{"type":"number","default":0,"minimum":0,"transition":true,"units":"pixels","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-blur":{"type":"number","default":0,"minimum":0,"transition":true,"units":"pixels","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-translate":{"type":"array","value":"number","length":2,"default":[0,0],"transition":true,"units":"pixels","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"text-translate-anchor":{"type":"enum","values":{"map":{},"viewport":{}},"default":"map","requires":["text-field","text-translate"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"}},"paint_raster":{"raster-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"raster-hue-rotate":{"type":"number","default":0,"period":360,"transition":true,"units":"degrees","expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"raster-brightness-min":{"type":"number","default":0,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"raster-brightness-max":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"raster-saturation":{"type":"number","default":0,"minimum":-1,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"raster-contrast":{"type":"number","default":0,"minimum":-1,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"raster-resampling":{"type":"enum","values":{"linear":{},"nearest":{}},"default":"linear","expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"raster-fade-duration":{"type":"number","default":300,"minimum":0,"transition":false,"units":"milliseconds","expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"}},"paint_hillshade":{"hillshade-illumination-direction":{"type":"number","default":335,"minimum":0,"maximum":359,"transition":false,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"hillshade-illumination-anchor":{"type":"enum","values":{"map":{},"viewport":{}},"default":"viewport","expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"hillshade-exaggeration":{"type":"number","default":0.5,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"hillshade-shadow-color":{"type":"color","default":"#000000","transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"hillshade-highlight-color":{"type":"color","default":"#FFFFFF","transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"hillshade-accent-color":{"type":"color","default":"#000000","transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"}},"paint_background":{"background-color":{"type":"color","default":"#000000","transition":true,"requires":[{"!":"background-pattern"}],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"background-pattern":{"type":"resolvedImage","transition":true,"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"cross-faded"},"background-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"}},"paint_sky":{"sky-type":{"type":"enum","values":{"gradient":{},"atmosphere":{}},"default":"atmosphere","expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"sky-atmosphere-sun":{"type":"array","value":"number","length":2,"units":"degrees","minimum":[0,0],"maximum":[360,180],"transition":false,"requires":[{"sky-type":"atmosphere"}],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"sky-atmosphere-sun-intensity":{"type":"number","requires":[{"sky-type":"atmosphere"}],"default":10,"minimum":0,"maximum":100,"transition":false,"property-type":"data-constant"},"sky-gradient-center":{"type":"array","requires":[{"sky-type":"gradient"}],"value":"number","default":[0,0],"length":2,"units":"degrees","minimum":[0,0],"maximum":[360,180],"transition":false,"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"sky-gradient-radius":{"type":"number","requires":[{"sky-type":"gradient"}],"default":90,"minimum":0,"maximum":180,"transition":false,"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"sky-gradient":{"type":"color","default":["interpolate",["linear"],["sky-radial-progress"],0.8,"#87ceeb",1,"white"],"transition":false,"requires":[{"sky-type":"gradient"}],"expression":{"interpolated":true,"parameters":["sky-radial-progress"]},"property-type":"color-ramp"},"sky-atmosphere-halo-color":{"type":"color","default":"white","transition":false,"requires":[{"sky-type":"atmosphere"}],"property-type":"data-constant"},"sky-atmosphere-color":{"type":"color","default":"white","transition":false,"requires":[{"sky-type":"atmosphere"}],"property-type":"data-constant"},"sky-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"}},"transition":{"duration":{"type":"number","default":300,"minimum":0,"units":"milliseconds"},"delay":{"type":"number","default":0,"minimum":0,"units":"milliseconds"}},"property-type":{"data-driven":{"type":"property-type"},"cross-faded":{"type":"property-type"},"cross-faded-data-driven":{"type":"property-type"},"color-ramp":{"type":"property-type"},"data-constant":{"type":"property-type"},"constant":{"type":"property-type"}},"promoteId":{"*":{"type":"string"}}}');function $s(D,..._){for(const k of _)for(const X in k)D[X]=k[X];return D}function ao(D){return D instanceof Number||D instanceof String||D instanceof Boolean?D.valueOf():D}function Ps(D){if(Array.isArray(D))return D.map(Ps);if(D instanceof Object&&!(D instanceof Number||D instanceof String||D instanceof Boolean)){const _={};for(const k in D)_[k]=Ps(D[k]);return _}return ao(D)}class qo extends Error{constructor(_,k){super(k),this.message=k,this.key=_}}class wl{constructor(_,k=[]){this.parent=_,this.bindings={};for(const[X,de]of k)this.bindings[X]=de}concat(_){return new wl(this,_)}get(_){if(this.bindings[_])return this.bindings[_];if(this.parent)return this.parent.get(_);throw new Error(`${_} not found in scope.`)}has(_){return!!this.bindings[_]||!!this.parent&&this.parent.has(_)}}const yu={kind:"null"},po={kind:"number"},Zs={kind:"string"},Es={kind:"boolean"},Xl={kind:"color"},xl={kind:"object"},jo={kind:"value"},ju={kind:"collator"},Pl={kind:"formatted"},tl={kind:"resolvedImage"};function zl(D,_){return{kind:"array",itemType:D,N:_}}function Is(D){if(D.kind==="array"){const _=Is(D.itemType);return typeof D.N=="number"?`array<${_}, ${D.N}>`:D.itemType.kind==="value"?"array":`array<${_}>`}return D.kind}const al=[yu,po,Zs,Es,Xl,Pl,xl,zl(jo),tl];function Mn(D,_){if(_.kind==="error")return null;if(D.kind==="array"){if(_.kind==="array"&&(_.N===0&&_.itemType.kind==="value"||!Mn(D.itemType,_.itemType))&&(typeof D.N!="number"||D.N===_.N))return null}else{if(D.kind===_.kind)return null;if(D.kind==="value"){for(const k of al)if(!Mn(k,_))return null}}return`Expected ${Is(D)} but found ${Is(_)} instead.`}function Ur(D,_){return _.some(k=>k.kind===D.kind)}function Gn(D,_){return _.some(k=>k==="null"?D===null:k==="array"?Array.isArray(D):k==="object"?D&&!Array.isArray(D)&&typeof D=="object":k===typeof D)}function Qr(D){var _={exports:{}};return D(_,_.exports),_.exports}var qi=Qr(function(D,_){var k={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],rebeccapurple:[102,51,153,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function X(_t){return(_t=Math.round(_t))<0?0:_t>255?255:_t}function de(_t){return X(_t[_t.length-1]==="%"?parseFloat(_t)/100*255:parseInt(_t))}function Ge(_t){return(At=_t[_t.length-1]==="%"?parseFloat(_t)/100:parseFloat(_t))<0?0:At>1?1:At;var At}function ft(_t,At,Nt){return Nt<0?Nt+=1:Nt>1&&(Nt-=1),6*Nt<1?_t+(At-_t)*Nt*6:2*Nt<1?At:3*Nt<2?_t+(At-_t)*(2/3-Nt)*6:_t}try{_.parseCSSColor=function(_t){var At,Nt=_t.replace(/ /g,"").toLowerCase();if(Nt in k)return k[Nt].slice();if(Nt[0]==="#")return Nt.length===4?(At=parseInt(Nt.substr(1),16))>=0&&At<=4095?[(3840&At)>>4|(3840&At)>>8,240&At|(240&At)>>4,15&At|(15&At)<<4,1]:null:Nt.length===7&&(At=parseInt(Nt.substr(1),16))>=0&&At<=16777215?[(16711680&At)>>16,(65280&At)>>8,255&At,1]:null;var cn=Nt.indexOf("("),vn=Nt.indexOf(")");if(cn!==-1&&vn+1===Nt.length){var bn=Nt.substr(0,cn),jn=Nt.substr(cn+1,vn-(cn+1)).split(","),Zn=1;switch(bn){case"rgba":if(jn.length!==4)return null;Zn=Ge(jn.pop());case"rgb":return jn.length!==3?null:[de(jn[0]),de(jn[1]),de(jn[2]),Zn];case"hsla":if(jn.length!==4)return null;Zn=Ge(jn.pop());case"hsl":if(jn.length!==3)return null;var Br=(parseFloat(jn[0])%360+360)%360/360,Jr=Ge(jn[1]),si=Ge(jn[2]),Li=si<=.5?si*(Jr+1):si+Jr-si*Jr,vi=2*si-Li;return[X(255*ft(vi,Li,Br+1/3)),X(255*ft(vi,Li,Br)),X(255*ft(vi,Li,Br-1/3)),Zn];default:return null}}return null}}catch{}});class ga{constructor(_,k,X,de=1){this.r=_,this.g=k,this.b=X,this.a=de}static parse(_){if(!_)return;if(_ instanceof ga)return _;if(typeof _!="string")return;const k=qi.parseCSSColor(_);return k?new ga(k[0]/255*k[3],k[1]/255*k[3],k[2]/255*k[3],k[3]):void 0}toString(){const[_,k,X,de]=this.toArray();return`rgba(${Math.round(_)},${Math.round(k)},${Math.round(X)},${de})`}toArray(){const{r:_,g:k,b:X,a:de}=this;return de===0?[0,0,0,0]:[255*_/de,255*k/de,255*X/de,de]}}ga.black=new ga(0,0,0,1),ga.white=new ga(1,1,1,1),ga.transparent=new ga(0,0,0,0),ga.red=new ga(1,0,0,1),ga.blue=new ga(0,0,1,1);class no{constructor(_,k,X){this.sensitivity=_?k?"variant":"case":k?"accent":"base",this.locale=X,this.collator=new Intl.Collator(this.locale?this.locale:[],{sensitivity:this.sensitivity,usage:"search"})}compare(_,k){return this.collator.compare(_,k)}resolvedLocale(){return new Intl.Collator(this.locale?this.locale:[]).resolvedOptions().locale}}class mo{constructor(_,k,X,de,Ge){this.text=_.normalize?_.normalize():_,this.image=k,this.scale=X,this.fontStack=de,this.textColor=Ge}}class Go{constructor(_){this.sections=_}static fromString(_){return new Go([new mo(_,null,null,null,null)])}isEmpty(){return this.sections.length===0||!this.sections.some(_=>_.text.length!==0||_.image&&_.image.name.length!==0)}static factory(_){return _ instanceof Go?_:Go.fromString(_)}toString(){return this.sections.length===0?"":this.sections.map(_=>_.text).join("")}serialize(){const _=["format"];for(const k of this.sections){if(k.image){_.push(["image",k.image.name]);continue}_.push(k.text);const X={};k.fontStack&&(X["text-font"]=["literal",k.fontStack.split(",")]),k.scale&&(X["font-scale"]=k.scale),k.textColor&&(X["text-color"]=["rgba"].concat(k.textColor.toArray())),_.push(X)}return _}}class Uo{constructor(_){this.name=_.name,this.available=_.available}toString(){return this.name}static fromString(_){return _?new Uo({name:_,available:!1}):null}serialize(){return["image",this.name]}}function Ns(D,_,k,X){return typeof D=="number"&&D>=0&&D<=255&&typeof _=="number"&&_>=0&&_<=255&&typeof k=="number"&&k>=0&&k<=255?X===void 0||typeof X=="number"&&X>=0&&X<=1?null:`Invalid rgba value [${[D,_,k,X].join(", ")}]: 'a' must be between 0 and 1.`:`Invalid rgba value [${(typeof X=="number"?[D,_,k,X]:[D,_,k]).join(", ")}]: 'r', 'g', and 'b' must be between 0 and 255.`}function jl(D){if(D===null||typeof D=="string"||typeof D=="boolean"||typeof D=="number"||D instanceof ga||D instanceof no||D instanceof Go||D instanceof Uo)return!0;if(Array.isArray(D)){for(const _ of D)if(!jl(_))return!1;return!0}if(typeof D=="object"){for(const _ in D)if(!jl(D[_]))return!1;return!0}return!1}function Bl(D){if(D===null)return yu;if(typeof D=="string")return Zs;if(typeof D=="boolean")return Es;if(typeof D=="number")return po;if(D instanceof ga)return Xl;if(D instanceof no)return ju;if(D instanceof Go)return Pl;if(D instanceof Uo)return tl;if(Array.isArray(D)){const _=D.length;let k;for(const X of D){const de=Bl(X);if(k){if(k===de)continue;k=jo;break}k=de}return zl(k||jo,_)}return xl}function Jl(D){const _=typeof D;return D===null?"":_==="string"||_==="number"||_==="boolean"?String(D):D instanceof ga||D instanceof Go||D instanceof Uo?D.toString():JSON.stringify(D)}class mu{constructor(_,k){this.type=_,this.value=k}static parse(_,k){if(_.length!==2)return k.error(`'literal' expression requires exactly one argument, but found ${_.length-1} instead.`);if(!jl(_[1]))return k.error("invalid value");const X=_[1];let de=Bl(X);const Ge=k.expectedType;return de.kind!=="array"||de.N!==0||!Ge||Ge.kind!=="array"||typeof Ge.N=="number"&&Ge.N!==0||(de=Ge),new mu(de,X)}evaluate(){return this.value}eachChild(){}outputDefined(){return!0}serialize(){return this.type.kind==="array"||this.type.kind==="object"?["literal",this.value]:this.value instanceof ga?["rgba"].concat(this.value.toArray()):this.value instanceof Go?this.value.serialize():this.value}}class Ol{constructor(_){this.name="ExpressionEvaluationError",this.message=_}toJSON(){return this.message}}const bu={string:Zs,number:po,boolean:Es,object:xl};class Bu{constructor(_,k){this.type=_,this.args=k}static parse(_,k){if(_.length<2)return k.error("Expected at least one argument.");let X,de=1;const Ge=_[0];if(Ge==="array"){let _t,At;if(_.length>2){const Nt=_[1];if(typeof Nt!="string"||!(Nt in bu)||Nt==="object")return k.error('The item type argument of "array" must be one of string, number, boolean',1);_t=bu[Nt],de++}else _t=jo;if(_.length>3){if(_[2]!==null&&(typeof _[2]!="number"||_[2]<0||_[2]!==Math.floor(_[2])))return k.error('The length argument to "array" must be a positive integer literal',2);At=_[2],de++}X=zl(_t,At)}else X=bu[Ge];const ft=[];for(;de<_.length;de++){const _t=k.parse(_[de],de,jo);if(!_t)return null;ft.push(_t)}return new Bu(X,ft)}evaluate(_){for(let k=0;k<this.args.length;k++){const X=this.args[k].evaluate(_);if(!Mn(this.type,Bl(X)))return X;if(k===this.args.length-1)throw new Ol(`Expected value to be of type ${Is(this.type)}, but found ${Is(Bl(X))} instead.`)}return null}eachChild(_){this.args.forEach(_)}outputDefined(){return this.args.every(_=>_.outputDefined())}serialize(){const _=this.type,k=[_.kind];if(_.kind==="array"){const X=_.itemType;if(X.kind==="string"||X.kind==="number"||X.kind==="boolean"){k.push(X.kind);const de=_.N;(typeof de=="number"||this.args.length>1)&&k.push(de)}}return k.concat(this.args.map(X=>X.serialize()))}}class hl{constructor(_){this.type=Pl,this.sections=_}static parse(_,k){if(_.length<2)return k.error("Expected at least one argument.");const X=_[1];if(!Array.isArray(X)&&typeof X=="object")return k.error("First argument must be an image or text section.");const de=[];let Ge=!1;for(let ft=1;ft<=_.length-1;++ft){const _t=_[ft];if(Ge&&typeof _t=="object"&&!Array.isArray(_t)){Ge=!1;let At=null;if(_t["font-scale"]&&(At=k.parse(_t["font-scale"],1,po),!At))return null;let Nt=null;if(_t["text-font"]&&(Nt=k.parse(_t["text-font"],1,zl(Zs)),!Nt))return null;let cn=null;if(_t["text-color"]&&(cn=k.parse(_t["text-color"],1,Xl),!cn))return null;const vn=de[de.length-1];vn.scale=At,vn.font=Nt,vn.textColor=cn}else{const At=k.parse(_[ft],1,jo);if(!At)return null;const Nt=At.type.kind;if(Nt!=="string"&&Nt!=="value"&&Nt!=="null"&&Nt!=="resolvedImage")return k.error("Formatted text type must be 'string', 'value', 'image' or 'null'.");Ge=!0,de.push({content:At,scale:null,font:null,textColor:null})}}return new hl(de)}evaluate(_){return new Go(this.sections.map(k=>{const X=k.content.evaluate(_);return Bl(X)===tl?new mo("",X,null,null,null):new mo(Jl(X),null,k.scale?k.scale.evaluate(_):null,k.font?k.font.evaluate(_).join(","):null,k.textColor?k.textColor.evaluate(_):null)}))}eachChild(_){for(const k of this.sections)_(k.content),k.scale&&_(k.scale),k.font&&_(k.font),k.textColor&&_(k.textColor)}outputDefined(){return!1}serialize(){const _=["format"];for(const k of this.sections){_.push(k.content.serialize());const X={};k.scale&&(X["font-scale"]=k.scale.serialize()),k.font&&(X["text-font"]=k.font.serialize()),k.textColor&&(X["text-color"]=k.textColor.serialize()),_.push(X)}return _}}class vu{constructor(_){this.type=tl,this.input=_}static parse(_,k){if(_.length!==2)return k.error("Expected two arguments.");const X=k.parse(_[1],1,Zs);return X?new vu(X):k.error("No image name provided.")}evaluate(_){const k=this.input.evaluate(_),X=Uo.fromString(k);return X&&_.availableImages&&(X.available=_.availableImages.indexOf(k)>-1),X}eachChild(_){_(this.input)}outputDefined(){return!1}serialize(){return["image",this.input.serialize()]}}const Ku={"to-boolean":Es,"to-color":Xl,"to-number":po,"to-string":Zs};class Ul{constructor(_,k){this.type=_,this.args=k}static parse(_,k){if(_.length<2)return k.error("Expected at least one argument.");const X=_[0];if((X==="to-boolean"||X==="to-string")&&_.length!==2)return k.error("Expected one argument.");const de=Ku[X],Ge=[];for(let ft=1;ft<_.length;ft++){const _t=k.parse(_[ft],ft,jo);if(!_t)return null;Ge.push(_t)}return new Ul(de,Ge)}evaluate(_){if(this.type.kind==="boolean")return!!this.args[0].evaluate(_);if(this.type.kind==="color"){let k,X;for(const de of this.args){if(k=de.evaluate(_),X=null,k instanceof ga)return k;if(typeof k=="string"){const Ge=_.parseColor(k);if(Ge)return Ge}else if(Array.isArray(k)&&(X=k.length<3||k.length>4?`Invalid rbga value ${JSON.stringify(k)}: expected an array containing either three or four numeric values.`:Ns(k[0],k[1],k[2],k[3]),!X))return new ga(k[0]/255,k[1]/255,k[2]/255,k[3])}throw new Ol(X||`Could not parse color from value '${typeof k=="string"?k:String(JSON.stringify(k))}'`)}if(this.type.kind==="number"){let k=null;for(const X of this.args){if(k=X.evaluate(_),k===null)return 0;const de=Number(k);if(!isNaN(de))return de}throw new Ol(`Could not convert ${JSON.stringify(k)} to number.`)}return this.type.kind==="formatted"?Go.fromString(Jl(this.args[0].evaluate(_))):this.type.kind==="resolvedImage"?Uo.fromString(Jl(this.args[0].evaluate(_))):Jl(this.args[0].evaluate(_))}eachChild(_){this.args.forEach(_)}outputDefined(){return this.args.every(_=>_.outputDefined())}serialize(){if(this.type.kind==="formatted")return new hl([{content:this.args[0],scale:null,font:null,textColor:null}]).serialize();if(this.type.kind==="resolvedImage")return new vu(this.args[0]).serialize();const _=[`to-${this.type.kind}`];return this.eachChild(k=>{_.push(k.serialize())}),_}}const ad=["Unknown","Point","LineString","Polygon"];class jc{constructor(){this.globals=null,this.feature=null,this.featureState=null,this.formattedSection=null,this._parseColorCache={},this.availableImages=null,this.canonical=null,this.featureTileCoord=null,this.featureDistanceData=null}id(){return this.feature&&"id"in this.feature&&this.feature.id?this.feature.id:null}geometryType(){return this.feature?typeof this.feature.type=="number"?ad[this.feature.type]:this.feature.type:null}geometry(){return this.feature&&"geometry"in this.feature?this.feature.geometry:null}canonicalID(){return this.canonical}properties(){return this.feature&&this.feature.properties||{}}distanceFromCenter(){if(this.featureTileCoord&&this.featureDistanceData){const _=this.featureDistanceData.center,k=this.featureDistanceData.scale,{x:X,y:de}=this.featureTileCoord;return this.featureDistanceData.bearing[0]*(X*k-_[0])+this.featureDistanceData.bearing[1]*(de*k-_[1])}return 0}parseColor(_){let k=this._parseColorCache[_];return k||(k=this._parseColorCache[_]=ga.parse(_)),k}}class js{constructor(_,k,X,de){this.name=_,this.type=k,this._evaluate=X,this.args=de}evaluate(_){return this._evaluate(_,this.args)}eachChild(_){this.args.forEach(_)}outputDefined(){return!1}serialize(){return[this.name].concat(this.args.map(_=>_.serialize()))}static parse(_,k){const X=_[0],de=js.definitions[X];if(!de)return k.error(`Unknown expression "${X}". If you wanted a literal array, use ["literal", [...]].`,0);const Ge=Array.isArray(de)?de[0]:de.type,ft=Array.isArray(de)?[[de[1],de[2]]]:de.overloads,_t=ft.filter(([Nt])=>!Array.isArray(Nt)||Nt.length===_.length-1);let At=null;for(const[Nt,cn]of _t){At=new wt(k.registry,k.path,null,k.scope);const vn=[];let bn=!1;for(let jn=1;jn<_.length;jn++){const Zn=_[jn],Br=Array.isArray(Nt)?Nt[jn-1]:Nt.type,Jr=At.parse(Zn,1+vn.length,Br);if(!Jr){bn=!0;break}vn.push(Jr)}if(!bn)if(Array.isArray(Nt)&&Nt.length!==vn.length)At.error(`Expected ${Nt.length} arguments, but found ${vn.length} instead.`);else{for(let jn=0;jn<vn.length;jn++){const Zn=Array.isArray(Nt)?Nt[jn]:Nt.type,Br=vn[jn];At.concat(jn+1).checkSubtype(Zn,Br.type)}if(At.errors.length===0)return new js(X,Ge,cn,vn)}}if(_t.length===1)k.errors.push(...At.errors);else{const Nt=(_t.length?_t:ft).map(([vn])=>{return bn=vn,Array.isArray(bn)?`(${bn.map(Is).join(", ")})`:`(${Is(bn.type)}...)`;var bn}).join(" | "),cn=[];for(let vn=1;vn<_.length;vn++){const bn=k.parse(_[vn],1+cn.length);if(!bn)return null;cn.push(Is(bn.type))}k.error(`Expected arguments of type ${Nt}, but found (${cn.join(", ")}) instead.`)}return null}static register(_,k){js.definitions=k;for(const X in k)_[X]=js}}class co{constructor(_,k,X){this.type=ju,this.locale=X,this.caseSensitive=_,this.diacriticSensitive=k}static parse(_,k){if(_.length!==2)return k.error("Expected one argument.");const X=_[1];if(typeof X!="object"||Array.isArray(X))return k.error("Collator options argument must be an object.");const de=k.parse(X["case-sensitive"]!==void 0&&X["case-sensitive"],1,Es);if(!de)return null;const Ge=k.parse(X["diacritic-sensitive"]!==void 0&&X["diacritic-sensitive"],1,Es);if(!Ge)return null;let ft=null;return X.locale&&(ft=k.parse(X.locale,1,Zs),!ft)?null:new co(de,Ge,ft)}evaluate(_){return new no(this.caseSensitive.evaluate(_),this.diacriticSensitive.evaluate(_),this.locale?this.locale.evaluate(_):null)}eachChild(_){_(this.caseSensitive),_(this.diacriticSensitive),this.locale&&_(this.locale)}outputDefined(){return!1}serialize(){const _={};return _["case-sensitive"]=this.caseSensitive.serialize(),_["diacritic-sensitive"]=this.diacriticSensitive.serialize(),this.locale&&(_.locale=this.locale.serialize()),["collator",_]}}const Vl=8192;function Gc(D,_){D[0]=Math.min(D[0],_[0]),D[1]=Math.min(D[1],_[1]),D[2]=Math.max(D[2],_[0]),D[3]=Math.max(D[3],_[1])}function yd(D,_){return!(D[0]<=_[0]||D[2]>=_[2]||D[1]<=_[1]||D[3]>=_[3])}function Ql(D,_){const k=(180+D[0])/360,X=(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+D[1]*Math.PI/360)))/360,de=Math.pow(2,_.z);return[Math.round(k*de*Vl),Math.round(X*de*Vl)]}function Ll(D,_,k){const X=D[0]-_[0],de=D[1]-_[1],Ge=D[0]-k[0],ft=D[1]-k[1];return X*ft-Ge*de==0&&X*Ge<=0&&de*ft<=0}function Au(D,_){let k=!1;for(let ft=0,_t=_.length;ft<_t;ft++){const At=_[ft];for(let Nt=0,cn=At.length;Nt<cn-1;Nt++){if(Ll(D,At[Nt],At[Nt+1]))return!1;(de=At[Nt])[1]>(X=D)[1]!=(Ge=At[Nt+1])[1]>X[1]&&X[0]<(Ge[0]-de[0])*(X[1]-de[1])/(Ge[1]-de[1])+de[0]&&(k=!k)}}var X,de,Ge;return k}function jd(D,_){for(let k=0;k<_.length;k++)if(Au(D,_[k]))return!0;return!1}function Wu(D,_,k,X){const de=X[0]-k[0],Ge=X[1]-k[1],ft=(D[0]-k[0])*Ge-de*(D[1]-k[1]),_t=(_[0]-k[0])*Ge-de*(_[1]-k[1]);return ft>0&&_t<0||ft<0&&_t>0}function ud(D,_,k){for(const Nt of k)for(let cn=0;cn<Nt.length-1;++cn)if((_t=[(ft=Nt[cn+1])[0]-(Ge=Nt[cn])[0],ft[1]-Ge[1]])[0]*(At=[(de=_)[0]-(X=D)[0],de[1]-X[1]])[1]-_t[1]*At[0]!=0&&Wu(X,de,Ge,ft)&&Wu(Ge,ft,X,de))return!0;var X,de,Ge,ft,_t,At;return!1}function Xc(D,_){for(let k=0;k<D.length;++k)if(!Au(D[k],_))return!1;for(let k=0;k<D.length-1;++k)if(ud(D[k],D[k+1],_))return!1;return!0}function yi(D,_){for(let k=0;k<_.length;k++)if(Xc(D,_[k]))return!0;return!1}function mc(D,_,k){const X=[];for(let de=0;de<D.length;de++){const Ge=[];for(let ft=0;ft<D[de].length;ft++){const _t=Ql(D[de][ft],k);Gc(_,_t),Ge.push(_t)}X.push(Ge)}return X}function Su(D,_,k){const X=[];for(let de=0;de<D.length;de++){const Ge=mc(D[de],_,k);X.push(Ge)}return X}function Yh(D,_,k,X){if(D[0]<k[0]||D[0]>k[2]){const de=.5*X;let Ge=D[0]-k[0]>de?-X:k[0]-D[0]>de?X:0;Ge===0&&(Ge=D[0]-k[2]>de?-X:k[2]-D[0]>de?X:0),D[0]+=Ge}Gc(_,D)}function ka(D,_,k,X){const de=Math.pow(2,X.z)*Vl,Ge=[X.x*Vl,X.y*Vl],ft=[];if(!D)return ft;for(const _t of D)for(const At of _t){const Nt=[At.x+Ge[0],At.y+Ge[1]];Yh(Nt,_,k,de),ft.push(Nt)}return ft}function pl(D,_,k,X){const de=Math.pow(2,X.z)*Vl,Ge=[X.x*Vl,X.y*Vl],ft=[];if(!D)return ft;for(const At of D){const Nt=[];for(const cn of At){const vn=[cn.x+Ge[0],cn.y+Ge[1]];Gc(_,vn),Nt.push(vn)}ft.push(Nt)}if(_[2]-_[0]<=de/2){(_t=_)[0]=_t[1]=1/0,_t[2]=_t[3]=-1/0;for(const At of ft)for(const Nt of At)Yh(Nt,_,k,de)}var _t;return ft}class Il{constructor(_,k){this.type=Es,this.geojson=_,this.geometries=k}static parse(_,k){if(_.length!==2)return k.error(`'within' expression requires exactly one argument, but found ${_.length-1} instead.`);if(jl(_[1])){const X=_[1];if(X.type==="FeatureCollection")for(let de=0;de<X.features.length;++de){const Ge=X.features[de].geometry.type;if(Ge==="Polygon"||Ge==="MultiPolygon")return new Il(X,X.features[de].geometry)}else if(X.type==="Feature"){const de=X.geometry.type;if(de==="Polygon"||de==="MultiPolygon")return new Il(X,X.geometry)}else if(X.type==="Polygon"||X.type==="MultiPolygon")return new Il(X,X)}return k.error("'within' expression requires valid geojson object that contains polygon geometry type.")}evaluate(_){if(_.geometry()!=null&&_.canonicalID()!=null){if(_.geometryType()==="Point")return function(k,X){const de=[1/0,1/0,-1/0,-1/0],Ge=[1/0,1/0,-1/0,-1/0],ft=k.canonicalID();if(!ft)return!1;if(X.type==="Polygon"){const _t=mc(X.coordinates,Ge,ft),At=ka(k.geometry(),de,Ge,ft);if(!yd(de,Ge))return!1;for(const Nt of At)if(!Au(Nt,_t))return!1}if(X.type==="MultiPolygon"){const _t=Su(X.coordinates,Ge,ft),At=ka(k.geometry(),de,Ge,ft);if(!yd(de,Ge))return!1;for(const Nt of At)if(!jd(Nt,_t))return!1}return!0}(_,this.geometries);if(_.geometryType()==="LineString")return function(k,X){const de=[1/0,1/0,-1/0,-1/0],Ge=[1/0,1/0,-1/0,-1/0],ft=k.canonicalID();if(!ft)return!1;if(X.type==="Polygon"){const _t=mc(X.coordinates,Ge,ft),At=pl(k.geometry(),de,Ge,ft);if(!yd(de,Ge))return!1;for(const Nt of At)if(!Xc(Nt,_t))return!1}if(X.type==="MultiPolygon"){const _t=Su(X.coordinates,Ge,ft),At=pl(k.geometry(),de,Ge,ft);if(!yd(de,Ge))return!1;for(const Nt of At)if(!yi(Nt,_t))return!1}return!0}(_,this.geometries)}return!1}eachChild(){}outputDefined(){return!0}serialize(){return["within",this.geojson]}}function Ss(D){if(D instanceof js&&(D.name==="get"&&D.args.length===1||D.name==="feature-state"||D.name==="has"&&D.args.length===1||D.name==="properties"||D.name==="geometry-type"||D.name==="id"||/^filter-/.test(D.name))||D instanceof Il)return!1;let _=!0;return D.eachChild(k=>{_&&!Ss(k)&&(_=!1)}),_}function Vo(D){if(D instanceof js&&D.name==="feature-state")return!1;let _=!0;return D.eachChild(k=>{_&&!Vo(k)&&(_=!1)}),_}function iu(D,_){if(D instanceof js&&_.indexOf(D.name)>=0)return!1;let k=!0;return D.eachChild(X=>{k&&!iu(X,_)&&(k=!1)}),k}class Tu{constructor(_,k){this.type=k.type,this.name=_,this.boundExpression=k}static parse(_,k){if(_.length!==2||typeof _[1]!="string")return k.error("'var' expression requires exactly one string literal argument.");const X=_[1];return k.scope.has(X)?new Tu(X,k.scope.get(X)):k.error(`Unknown variable "${X}". Make sure "${X}" has been bound in an enclosing "let" expression before using it.`,1)}evaluate(_){return this.boundExpression.evaluate(_)}eachChild(){}outputDefined(){return!1}serialize(){return["var",this.name]}}class wt{constructor(_,k=[],X,de=new wl,Ge=[]){this.registry=_,this.path=k,this.key=k.map(ft=>`[${ft}]`).join(""),this.scope=de,this.errors=Ge,this.expectedType=X}parse(_,k,X,de,Ge={}){return k?this.concat(k,X,de)._parse(_,Ge):this._parse(_,Ge)}_parse(_,k){function X(de,Ge,ft){return ft==="assert"?new Bu(Ge,[de]):ft==="coerce"?new Ul(Ge,[de]):de}if(_!==null&&typeof _!="string"&&typeof _!="boolean"&&typeof _!="number"||(_=["literal",_]),Array.isArray(_)){if(_.length===0)return this.error('Expected an array with at least one element. If you wanted a literal array, use ["literal", []].');const de=_[0];if(typeof de!="string")return this.error(`Expression name must be a string, but found ${typeof de} instead. If you wanted a literal array, use ["literal", [...]].`,0),null;const Ge=this.registry[de];if(Ge){let ft=Ge.parse(_,this);if(!ft)return null;if(this.expectedType){const _t=this.expectedType,At=ft.type;if(_t.kind!=="string"&&_t.kind!=="number"&&_t.kind!=="boolean"&&_t.kind!=="object"&&_t.kind!=="array"||At.kind!=="value")if(_t.kind!=="color"&&_t.kind!=="formatted"&&_t.kind!=="resolvedImage"||At.kind!=="value"&&At.kind!=="string"){if(this.checkSubtype(_t,At))return null}else ft=X(ft,_t,k.typeAnnotation||"coerce");else ft=X(ft,_t,k.typeAnnotation||"assert")}if(!(ft instanceof mu)&&ft.type.kind!=="resolvedImage"&&qt(ft)){const _t=new jc;try{ft=new mu(ft.type,ft.evaluate(_t))}catch(At){return this.error(At.message),null}}return ft}return this.error(`Unknown expression "${de}". If you wanted a literal array, use ["literal", [...]].`,0)}return this.error(_===void 0?"'undefined' value invalid. Use null instead.":typeof _=="object"?'Bare objects invalid. Use ["literal", {...}] instead.':`Expected an array, but found ${typeof _} instead.`)}concat(_,k,X){const de=typeof _=="number"?this.path.concat(_):this.path,Ge=X?this.scope.concat(X):this.scope;return new wt(this.registry,de,k||null,Ge,this.errors)}error(_,...k){const X=`${this.key}${k.map(de=>`[${de}]`).join("")}`;this.errors.push(new qo(X,_))}checkSubtype(_,k){const X=Mn(_,k);return X&&this.error(X),X}}function qt(D){if(D instanceof Tu)return qt(D.boundExpression);if(D instanceof js&&D.name==="error"||D instanceof co||D instanceof Il)return!1;const _=D instanceof Ul||D instanceof Bu;let k=!0;return D.eachChild(X=>{k=_?k&&qt(X):k&&X instanceof mu}),!!k&&Ss(D)&&iu(D,["zoom","heatmap-density","line-progress","sky-radial-progress","accumulated","is-supported-script","pitch","distance-from-center"])}function Cn(D,_){const k=D.length-1;let X,de,Ge=0,ft=k,_t=0;for(;Ge<=ft;)if(_t=Math.floor((Ge+ft)/2),X=D[_t],de=D[_t+1],X<=_){if(_t===k||_<de)return _t;Ge=_t+1}else{if(!(X>_))throw new Ol("Input is not a number.");ft=_t-1}return 0}class Pn{constructor(_,k,X){this.type=_,this.input=k,this.labels=[],this.outputs=[];for(const[de,Ge]of X)this.labels.push(de),this.outputs.push(Ge)}static parse(_,k){if(_.length-1<4)return k.error(`Expected at least 4 arguments, but found only ${_.length-1}.`);if((_.length-1)%2!=0)return k.error("Expected an even number of arguments.");const X=k.parse(_[1],1,po);if(!X)return null;const de=[];let Ge=null;k.expectedType&&k.expectedType.kind!=="value"&&(Ge=k.expectedType);for(let ft=1;ft<_.length;ft+=2){const _t=ft===1?-1/0:_[ft],At=_[ft+1],Nt=ft,cn=ft+1;if(typeof _t!="number")return k.error('Input/output pairs for "step" expressions must be defined using literal numeric values (not computed expressions) for the input values.',Nt);if(de.length&&de[de.length-1][0]>=_t)return k.error('Input/output pairs for "step" expressions must be arranged with input values in strictly ascending order.',Nt);const vn=k.parse(At,cn,Ge);if(!vn)return null;Ge=Ge||vn.type,de.push([_t,vn])}return new Pn(Ge,X,de)}evaluate(_){const k=this.labels,X=this.outputs;if(k.length===1)return X[0].evaluate(_);const de=this.input.evaluate(_);if(de<=k[0])return X[0].evaluate(_);const Ge=k.length;return de>=k[Ge-1]?X[Ge-1].evaluate(_):X[Cn(k,de)].evaluate(_)}eachChild(_){_(this.input);for(const k of this.outputs)_(k)}outputDefined(){return this.outputs.every(_=>_.outputDefined())}serialize(){const _=["step",this.input.serialize()];for(let k=0;k<this.labels.length;k++)k>0&&_.push(this.labels[k]),_.push(this.outputs[k].serialize());return _}}function Qe(D,_,k){return D*(1-k)+_*k}var yt=Object.freeze({__proto__:null,number:Qe,color:function(D,_,k){return new ga(Qe(D.r,_.r,k),Qe(D.g,_.g,k),Qe(D.b,_.b,k),Qe(D.a,_.a,k))},array:function(D,_,k){return D.map((X,de)=>Qe(X,_[de],k))}});const Rt=.95047,jt=1.08883,dn=4/29,yn=6/29,In=3*yn*yn,vr=Math.PI/180,Jn=180/Math.PI;function li(D){return D>.008856451679035631?Math.pow(D,1/3):D/In+dn}function xa(D){return D>yn?D*D*D:In*(D-dn)}function Ri(D){return 255*(D<=.0031308?12.92*D:1.055*Math.pow(D,1/2.4)-.055)}function fa(D){return(D/=255)<=.04045?D/12.92:Math.pow((D+.055)/1.055,2.4)}function oo(D){const _=fa(D.r),k=fa(D.g),X=fa(D.b),de=li((.4124564*_+.3575761*k+.1804375*X)/Rt),Ge=li((.2126729*_+.7151522*k+.072175*X)/1);return{l:116*Ge-16,a:500*(de-Ge),b:200*(Ge-li((.0193339*_+.119192*k+.9503041*X)/jt)),alpha:D.a}}function ts(D){let _=(D.l+16)/116,k=isNaN(D.a)?_:_+D.a/500,X=isNaN(D.b)?_:_-D.b/200;return _=1*xa(_),k=Rt*xa(k),X=jt*xa(X),new ga(Ri(3.2404542*k-1.5371385*_-.4985314*X),Ri(-.969266*k+1.8760108*_+.041556*X),Ri(.0556434*k-.2040259*_+1.0572252*X),D.alpha)}function bl(D,_,k){const X=_-D;return D+k*(X>180||X<-180?X-360*Math.round(X/360):X)}const nl={forward:oo,reverse:ts,interpolate:function(D,_,k){return{l:Qe(D.l,_.l,k),a:Qe(D.a,_.a,k),b:Qe(D.b,_.b,k),alpha:Qe(D.alpha,_.alpha,k)}}},Fs={forward:function(D){const{l:_,a:k,b:X}=oo(D),de=Math.atan2(X,k)*Jn;return{h:de<0?de+360:de,c:Math.sqrt(k*k+X*X),l:_,alpha:D.a}},reverse:function(D){const _=D.h*vr,k=D.c;return ts({l:D.l,a:Math.cos(_)*k,b:Math.sin(_)*k,alpha:D.alpha})},interpolate:function(D,_,k){return{h:bl(D.h,_.h,k),c:Qe(D.c,_.c,k),l:Qe(D.l,_.l,k),alpha:Qe(D.alpha,_.alpha,k)}}};var eu=Object.freeze({__proto__:null,lab:nl,hcl:Fs});class Gs{constructor(_,k,X,de,Ge){this.type=_,this.operator=k,this.interpolation=X,this.input=de,this.labels=[],this.outputs=[];for(const[ft,_t]of Ge)this.labels.push(ft),this.outputs.push(_t)}static interpolationFactor(_,k,X,de){let Ge=0;if(_.name==="exponential")Ge=As(k,_.base,X,de);else if(_.name==="linear")Ge=As(k,1,X,de);else if(_.name==="cubic-bezier"){const ft=_.controlPoints;Ge=new N(ft[0],ft[1],ft[2],ft[3]).solve(As(k,1,X,de))}return Ge}static parse(_,k){let[X,de,Ge,...ft]=_;if(!Array.isArray(de)||de.length===0)return k.error("Expected an interpolation type expression.",1);if(de[0]==="linear")de={name:"linear"};else if(de[0]==="exponential"){const Nt=de[1];if(typeof Nt!="number")return k.error("Exponential interpolation requires a numeric base.",1,1);de={name:"exponential",base:Nt}}else{if(de[0]!=="cubic-bezier")return k.error(`Unknown interpolation type ${String(de[0])}`,1,0);{const Nt=de.slice(1);if(Nt.length!==4||Nt.some(cn=>typeof cn!="number"||cn<0||cn>1))return k.error("Cubic bezier interpolation requires four numeric arguments with values between 0 and 1.",1);de={name:"cubic-bezier",controlPoints:Nt}}}if(_.length-1<4)return k.error(`Expected at least 4 arguments, but found only ${_.length-1}.`);if((_.length-1)%2!=0)return k.error("Expected an even number of arguments.");if(Ge=k.parse(Ge,2,po),!Ge)return null;const _t=[];let At=null;X==="interpolate-hcl"||X==="interpolate-lab"?At=Xl:k.expectedType&&k.expectedType.kind!=="value"&&(At=k.expectedType);for(let Nt=0;Nt<ft.length;Nt+=2){const cn=ft[Nt],vn=ft[Nt+1],bn=Nt+3,jn=Nt+4;if(typeof cn!="number")return k.error('Input/output pairs for "interpolate" expressions must be defined using literal numeric values (not computed expressions) for the input values.',bn);if(_t.length&&_t[_t.length-1][0]>=cn)return k.error('Input/output pairs for "interpolate" expressions must be arranged with input values in strictly ascending order.',bn);const Zn=k.parse(vn,jn,At);if(!Zn)return null;At=At||Zn.type,_t.push([cn,Zn])}return At.kind==="number"||At.kind==="color"||At.kind==="array"&&At.itemType.kind==="number"&&typeof At.N=="number"?new Gs(At,X,de,Ge,_t):k.error(`Type ${Is(At)} is not interpolatable.`)}evaluate(_){const k=this.labels,X=this.outputs;if(k.length===1)return X[0].evaluate(_);const de=this.input.evaluate(_);if(de<=k[0])return X[0].evaluate(_);const Ge=k.length;if(de>=k[Ge-1])return X[Ge-1].evaluate(_);const ft=Cn(k,de),_t=Gs.interpolationFactor(this.interpolation,de,k[ft],k[ft+1]),At=X[ft].evaluate(_),Nt=X[ft+1].evaluate(_);return this.operator==="interpolate"?yt[this.type.kind.toLowerCase()](At,Nt,_t):this.operator==="interpolate-hcl"?Fs.reverse(Fs.interpolate(Fs.forward(At),Fs.forward(Nt),_t)):nl.reverse(nl.interpolate(nl.forward(At),nl.forward(Nt),_t))}eachChild(_){_(this.input);for(const k of this.outputs)_(k)}outputDefined(){return this.outputs.every(_=>_.outputDefined())}serialize(){let _;_=this.interpolation.name==="linear"?["linear"]:this.interpolation.name==="exponential"?this.interpolation.base===1?["linear"]:["exponential",this.interpolation.base]:["cubic-bezier"].concat(this.interpolation.controlPoints);const k=[this.operator,_,this.input.serialize()];for(let X=0;X<this.labels.length;X++)k.push(this.labels[X],this.outputs[X].serialize());return k}}function As(D,_,k,X){const de=X-k,Ge=D-k;return de===0?0:_===1?Ge/de:(Math.pow(_,Ge)-1)/(Math.pow(_,de)-1)}class yl{constructor(_,k){this.type=_,this.args=k}static parse(_,k){if(_.length<2)return k.error("Expectected at least one argument.");let X=null;const de=k.expectedType;de&&de.kind!=="value"&&(X=de);const Ge=[];for(const _t of _.slice(1)){const At=k.parse(_t,1+Ge.length,X,void 0,{typeAnnotation:"omit"});if(!At)return null;X=X||At.type,Ge.push(At)}const ft=de&&Ge.some(_t=>Mn(de,_t.type));return new yl(ft?jo:X,Ge)}evaluate(_){let k,X=null,de=0;for(const Ge of this.args){if(de++,X=Ge.evaluate(_),X&&X instanceof Uo&&!X.available&&(k||(k=X),X=null,de===this.args.length))return k;if(X!==null)break}return X}eachChild(_){this.args.forEach(_)}outputDefined(){return this.args.every(_=>_.outputDefined())}serialize(){const _=["coalesce"];return this.eachChild(k=>{_.push(k.serialize())}),_}}class Lc{constructor(_,k){this.type=k.type,this.bindings=[].concat(_),this.result=k}evaluate(_){return this.result.evaluate(_)}eachChild(_){for(const k of this.bindings)_(k[1]);_(this.result)}static parse(_,k){if(_.length<4)return k.error(`Expected at least 3 arguments, but found ${_.length-1} instead.`);const X=[];for(let Ge=1;Ge<_.length-1;Ge+=2){const ft=_[Ge];if(typeof ft!="string")return k.error(`Expected string, but found ${typeof ft} instead.`,Ge);if(/[^a-zA-Z0-9_]/.test(ft))return k.error("Variable names must contain only alphanumeric characters or '_'.",Ge);const _t=k.parse(_[Ge+1],Ge+1);if(!_t)return null;X.push([ft,_t])}const de=k.parse(_[_.length-1],_.length-1,k.expectedType,X);return de?new Lc(X,de):null}outputDefined(){return this.result.outputDefined()}serialize(){const _=["let"];for(const[k,X]of this.bindings)_.push(k,X.serialize());return _.push(this.result.serialize()),_}}class vl{constructor(_,k,X){this.type=_,this.index=k,this.input=X}static parse(_,k){if(_.length!==3)return k.error(`Expected 2 arguments, but found ${_.length-1} instead.`);const X=k.parse(_[1],1,po),de=k.parse(_[2],2,zl(k.expectedType||jo));return X&&de?new vl(de.type.itemType,X,de):null}evaluate(_){const k=this.index.evaluate(_),X=this.input.evaluate(_);if(k<0)throw new Ol(`Array index out of bounds: ${k} < 0.`);if(k>=X.length)throw new Ol(`Array index out of bounds: ${k} > ${X.length-1}.`);if(k!==Math.floor(k))throw new Ol(`Array index must be an integer, but found ${k} instead.`);return X[k]}eachChild(_){_(this.index),_(this.input)}outputDefined(){return!1}serialize(){return["at",this.index.serialize(),this.input.serialize()]}}class du{constructor(_,k){this.type=Es,this.needle=_,this.haystack=k}static parse(_,k){if(_.length!==3)return k.error(`Expected 2 arguments, but found ${_.length-1} instead.`);const X=k.parse(_[1],1,jo),de=k.parse(_[2],2,jo);return X&&de?Ur(X.type,[Es,Zs,po,yu,jo])?new du(X,de):k.error(`Expected first argument to be of type boolean, string, number or null, but found ${Is(X.type)} instead`):null}evaluate(_){const k=this.needle.evaluate(_),X=this.haystack.evaluate(_);if(X==null)return!1;if(!Gn(k,["boolean","string","number","null"]))throw new Ol(`Expected first argument to be of type boolean, string, number or null, but found ${Is(Bl(k))} instead.`);if(!Gn(X,["string","array"]))throw new Ol(`Expected second argument to be of type array or string, but found ${Is(Bl(X))} instead.`);return X.indexOf(k)>=0}eachChild(_){_(this.needle),_(this.haystack)}outputDefined(){return!0}serialize(){return["in",this.needle.serialize(),this.haystack.serialize()]}}class ac{constructor(_,k,X){this.type=po,this.needle=_,this.haystack=k,this.fromIndex=X}static parse(_,k){if(_.length<=2||_.length>=5)return k.error(`Expected 3 or 4 arguments, but found ${_.length-1} instead.`);const X=k.parse(_[1],1,jo),de=k.parse(_[2],2,jo);if(!X||!de)return null;if(!Ur(X.type,[Es,Zs,po,yu,jo]))return k.error(`Expected first argument to be of type boolean, string, number or null, but found ${Is(X.type)} instead`);if(_.length===4){const Ge=k.parse(_[3],3,po);return Ge?new ac(X,de,Ge):null}return new ac(X,de)}evaluate(_){const k=this.needle.evaluate(_),X=this.haystack.evaluate(_);if(!Gn(k,["boolean","string","number","null"]))throw new Ol(`Expected first argument to be of type boolean, string, number or null, but found ${Is(Bl(k))} instead.`);if(!Gn(X,["string","array"]))throw new Ol(`Expected second argument to be of type array or string, but found ${Is(Bl(X))} instead.`);if(this.fromIndex){const de=this.fromIndex.evaluate(_);return X.indexOf(k,de)}return X.indexOf(k)}eachChild(_){_(this.needle),_(this.haystack),this.fromIndex&&_(this.fromIndex)}outputDefined(){return!1}serialize(){if(this.fromIndex!=null&&this.fromIndex!==void 0){const _=this.fromIndex.serialize();return["index-of",this.needle.serialize(),this.haystack.serialize(),_]}return["index-of",this.needle.serialize(),this.haystack.serialize()]}}class Xu{constructor(_,k,X,de,Ge,ft){this.inputType=_,this.type=k,this.input=X,this.cases=de,this.outputs=Ge,this.otherwise=ft}static parse(_,k){if(_.length<5)return k.error(`Expected at least 4 arguments, but found only ${_.length-1}.`);if(_.length%2!=1)return k.error("Expected an even number of arguments.");let X,de;k.expectedType&&k.expectedType.kind!=="value"&&(de=k.expectedType);const Ge={},ft=[];for(let Nt=2;Nt<_.length-1;Nt+=2){let cn=_[Nt];const vn=_[Nt+1];Array.isArray(cn)||(cn=[cn]);const bn=k.concat(Nt);if(cn.length===0)return bn.error("Expected at least one branch label.");for(const Zn of cn){if(typeof Zn!="number"&&typeof Zn!="string")return bn.error("Branch labels must be numbers or strings.");if(typeof Zn=="number"&&Math.abs(Zn)>Number.MAX_SAFE_INTEGER)return bn.error(`Branch labels must be integers no larger than ${Number.MAX_SAFE_INTEGER}.`);if(typeof Zn=="number"&&Math.floor(Zn)!==Zn)return bn.error("Numeric branch labels must be integer values.");if(X){if(bn.checkSubtype(X,Bl(Zn)))return null}else X=Bl(Zn);if(Ge[String(Zn)]!==void 0)return bn.error("Branch labels must be unique.");Ge[String(Zn)]=ft.length}const jn=k.parse(vn,Nt,de);if(!jn)return null;de=de||jn.type,ft.push(jn)}const _t=k.parse(_[1],1,jo);if(!_t)return null;const At=k.parse(_[_.length-1],_.length-1,de);return At?_t.type.kind!=="value"&&k.concat(1).checkSubtype(X,_t.type)?null:new Xu(X,de,_t,Ge,ft,At):null}evaluate(_){const k=this.input.evaluate(_);return(Bl(k)===this.inputType&&this.outputs[this.cases[k]]||this.otherwise).evaluate(_)}eachChild(_){_(this.input),this.outputs.forEach(_),_(this.otherwise)}outputDefined(){return this.outputs.every(_=>_.outputDefined())&&this.otherwise.outputDefined()}serialize(){const _=["match",this.input.serialize()],k=Object.keys(this.cases).sort(),X=[],de={};for(const ft of k){const _t=de[this.cases[ft]];_t===void 0?(de[this.cases[ft]]=X.length,X.push([this.cases[ft],[ft]])):X[_t][1].push(ft)}const Ge=ft=>this.inputType.kind==="number"?Number(ft):ft;for(const[ft,_t]of X)_.push(_t.length===1?Ge(_t[0]):_t.map(Ge)),_.push(this.outputs[ft].serialize());return _.push(this.otherwise.serialize()),_}}class Ju{constructor(_,k,X){this.type=_,this.branches=k,this.otherwise=X}static parse(_,k){if(_.length<4)return k.error(`Expected at least 3 arguments, but found only ${_.length-1}.`);if(_.length%2!=0)return k.error("Expected an odd number of arguments.");let X;k.expectedType&&k.expectedType.kind!=="value"&&(X=k.expectedType);const de=[];for(let ft=1;ft<_.length-1;ft+=2){const _t=k.parse(_[ft],ft,Es);if(!_t)return null;const At=k.parse(_[ft+1],ft+1,X);if(!At)return null;de.push([_t,At]),X=X||At.type}const Ge=k.parse(_[_.length-1],_.length-1,X);return Ge?new Ju(X,de,Ge):null}evaluate(_){for(const[k,X]of this.branches)if(k.evaluate(_))return X.evaluate(_);return this.otherwise.evaluate(_)}eachChild(_){for(const[k,X]of this.branches)_(k),_(X);_(this.otherwise)}outputDefined(){return this.branches.every(([_,k])=>k.outputDefined())&&this.otherwise.outputDefined()}serialize(){const _=["case"];return this.eachChild(k=>{_.push(k.serialize())}),_}}class Vu{constructor(_,k,X,de){this.type=_,this.input=k,this.beginIndex=X,this.endIndex=de}static parse(_,k){if(_.length<=2||_.length>=5)return k.error(`Expected 3 or 4 arguments, but found ${_.length-1} instead.`);const X=k.parse(_[1],1,jo),de=k.parse(_[2],2,po);if(!X||!de)return null;if(!Ur(X.type,[zl(jo),Zs,jo]))return k.error(`Expected first argument to be of type array or string, but found ${Is(X.type)} instead`);if(_.length===4){const Ge=k.parse(_[3],3,po);return Ge?new Vu(X.type,X,de,Ge):null}return new Vu(X.type,X,de)}evaluate(_){const k=this.input.evaluate(_),X=this.beginIndex.evaluate(_);if(!Gn(k,["string","array"]))throw new Ol(`Expected first argument to be of type array or string, but found ${Is(Bl(k))} instead.`);if(this.endIndex){const de=this.endIndex.evaluate(_);return k.slice(X,de)}return k.slice(X)}eachChild(_){_(this.input),_(this.beginIndex),this.endIndex&&_(this.endIndex)}outputDefined(){return!1}serialize(){if(this.endIndex!=null&&this.endIndex!==void 0){const _=this.endIndex.serialize();return["slice",this.input.serialize(),this.beginIndex.serialize(),_]}return["slice",this.input.serialize(),this.beginIndex.serialize()]}}function Nl(D,_){return D==="=="||D==="!="?_.kind==="boolean"||_.kind==="string"||_.kind==="number"||_.kind==="null"||_.kind==="value":_.kind==="string"||_.kind==="number"||_.kind==="value"}function $l(D,_,k,X){return X.compare(_,k)===0}function hu(D,_,k){const X=D!=="=="&&D!=="!=";return class G0{constructor(Ge,ft,_t){this.type=Es,this.lhs=Ge,this.rhs=ft,this.collator=_t,this.hasUntypedArgument=Ge.type.kind==="value"||ft.type.kind==="value"}static parse(Ge,ft){if(Ge.length!==3&&Ge.length!==4)return ft.error("Expected two or three arguments.");const _t=Ge[0];let At=ft.parse(Ge[1],1,jo);if(!At)return null;if(!Nl(_t,At.type))return ft.concat(1).error(`"${_t}" comparisons are not supported for type '${Is(At.type)}'.`);let Nt=ft.parse(Ge[2],2,jo);if(!Nt)return null;if(!Nl(_t,Nt.type))return ft.concat(2).error(`"${_t}" comparisons are not supported for type '${Is(Nt.type)}'.`);if(At.type.kind!==Nt.type.kind&&At.type.kind!=="value"&&Nt.type.kind!=="value")return ft.error(`Cannot compare types '${Is(At.type)}' and '${Is(Nt.type)}'.`);X&&(At.type.kind==="value"&&Nt.type.kind!=="value"?At=new Bu(Nt.type,[At]):At.type.kind!=="value"&&Nt.type.kind==="value"&&(Nt=new Bu(At.type,[Nt])));let cn=null;if(Ge.length===4){if(At.type.kind!=="string"&&Nt.type.kind!=="string"&&At.type.kind!=="value"&&Nt.type.kind!=="value")return ft.error("Cannot use collator to compare non-string types.");if(cn=ft.parse(Ge[3],3,ju),!cn)return null}return new G0(At,Nt,cn)}evaluate(Ge){const ft=this.lhs.evaluate(Ge),_t=this.rhs.evaluate(Ge);if(X&&this.hasUntypedArgument){const At=Bl(ft),Nt=Bl(_t);if(At.kind!==Nt.kind||At.kind!=="string"&&At.kind!=="number")throw new Ol(`Expected arguments for "${D}" to be (string, string) or (number, number), but found (${At.kind}, ${Nt.kind}) instead.`)}if(this.collator&&!X&&this.hasUntypedArgument){const At=Bl(ft),Nt=Bl(_t);if(At.kind!=="string"||Nt.kind!=="string")return _(Ge,ft,_t)}return this.collator?k(Ge,ft,_t,this.collator.evaluate(Ge)):_(Ge,ft,_t)}eachChild(Ge){Ge(this.lhs),Ge(this.rhs),this.collator&&Ge(this.collator)}outputDefined(){return!0}serialize(){const Ge=[D];return this.eachChild(ft=>{Ge.push(ft.serialize())}),Ge}}}const Qu=hu("==",function(D,_,k){return _===k},$l),Gu=hu("!=",function(D,_,k){return _!==k},function(D,_,k,X){return!$l(0,_,k,X)}),Bs=hu("<",function(D,_,k){return _<k},function(D,_,k,X){return X.compare(_,k)<0}),su=hu(">",function(D,_,k){return _>k},function(D,_,k,X){return X.compare(_,k)>0}),ku=hu("<=",function(D,_,k){return _<=k},function(D,_,k,X){return X.compare(_,k)<=0}),Hl=hu(">=",function(D,_,k){return _>=k},function(D,_,k,X){return X.compare(_,k)>=0});class Uc{constructor(_,k,X,de,Ge){this.type=Zs,this.number=_,this.locale=k,this.currency=X,this.minFractionDigits=de,this.maxFractionDigits=Ge}static parse(_,k){if(_.length!==3)return k.error("Expected two arguments.");const X=k.parse(_[1],1,po);if(!X)return null;const de=_[2];if(typeof de!="object"||Array.isArray(de))return k.error("NumberFormat options argument must be an object.");let Ge=null;if(de.locale&&(Ge=k.parse(de.locale,1,Zs),!Ge))return null;let ft=null;if(de.currency&&(ft=k.parse(de.currency,1,Zs),!ft))return null;let _t=null;if(de["min-fraction-digits"]&&(_t=k.parse(de["min-fraction-digits"],1,po),!_t))return null;let At=null;return de["max-fraction-digits"]&&(At=k.parse(de["max-fraction-digits"],1,po),!At)?null:new Uc(X,Ge,ft,_t,At)}evaluate(_){return new Intl.NumberFormat(this.locale?this.locale.evaluate(_):[],{style:this.currency?"currency":"decimal",currency:this.currency?this.currency.evaluate(_):void 0,minimumFractionDigits:this.minFractionDigits?this.minFractionDigits.evaluate(_):void 0,maximumFractionDigits:this.maxFractionDigits?this.maxFractionDigits.evaluate(_):void 0}).format(this.number.evaluate(_))}eachChild(_){_(this.number),this.locale&&_(this.locale),this.currency&&_(this.currency),this.minFractionDigits&&_(this.minFractionDigits),this.maxFractionDigits&&_(this.maxFractionDigits)}outputDefined(){return!1}serialize(){const _={};return this.locale&&(_.locale=this.locale.serialize()),this.currency&&(_.currency=this.currency.serialize()),this.minFractionDigits&&(_["min-fraction-digits"]=this.minFractionDigits.serialize()),this.maxFractionDigits&&(_["max-fraction-digits"]=this.maxFractionDigits.serialize()),["number-format",this.number.serialize(),_]}}class Wl{constructor(_){this.type=po,this.input=_}static parse(_,k){if(_.length!==2)return k.error(`Expected 1 argument, but found ${_.length-1} instead.`);const X=k.parse(_[1],1);return X?X.type.kind!=="array"&&X.type.kind!=="string"&&X.type.kind!=="value"?k.error(`Expected argument of type string or array, but found ${Is(X.type)} instead.`):new Wl(X):null}evaluate(_){const k=this.input.evaluate(_);if(typeof k=="string"||Array.isArray(k))return k.length;throw new Ol(`Expected value to be of type string or array, but found ${Is(Bl(k))} instead.`)}eachChild(_){_(this.input)}outputDefined(){return!1}serialize(){const _=["length"];return this.eachChild(k=>{_.push(k.serialize())}),_}}const cd={"==":Qu,"!=":Gu,">":su,"<":Bs,">=":Hl,"<=":ku,array:Bu,at:vl,boolean:Bu,case:Ju,coalesce:yl,collator:co,format:hl,image:vu,in:du,"index-of":ac,interpolate:Gs,"interpolate-hcl":Gs,"interpolate-lab":Gs,length:Wl,let:Lc,literal:mu,match:Xu,number:Bu,"number-format":Uc,object:Bu,slice:Vu,step:Pn,string:Bu,"to-boolean":Ul,"to-color":Ul,"to-number":Ul,"to-string":Ul,var:Tu,within:Il};function wu(D,[_,k,X,de]){_=_.evaluate(D),k=k.evaluate(D),X=X.evaluate(D);const Ge=de?de.evaluate(D):1,ft=Ns(_,k,X,Ge);if(ft)throw new Ol(ft);return new ga(_/255*Ge,k/255*Ge,X/255*Ge,Ge)}function oc(D,_){return D in _}function gc(D,_){const k=_[D];return k===void 0?null:k}function dd(D){return{type:D}}function Jc(D){return{result:"success",value:D}}function sc(D){return{result:"error",value:D}}function qc(D){return D["property-type"]==="data-driven"||D["property-type"]==="cross-faded-data-driven"}function vd(D){return!!D.expression&&D.expression.parameters.indexOf("zoom")>-1}function Pu(D){return!!D.expression&&D.expression.interpolated}function ol(D){return D instanceof Number?"number":D instanceof String?"string":D instanceof Boolean?"boolean":Array.isArray(D)?"array":D===null?"null":typeof D}function od(D){return typeof D=="object"&&D!==null&&!Array.isArray(D)}function qu(D){return D}function ah(D,_){const k=_.type==="color",X=D.stops&&typeof D.stops[0][0]=="object",de=X||!(X||D.property!==void 0),Ge=D.type||(Pu(_)?"exponential":"interval");if(k&&((D=$s({},D)).stops&&(D.stops=D.stops.map(Nt=>[Nt[0],ga.parse(Nt[1])])),D.default=ga.parse(D.default?D.default:_.default)),D.colorSpace&&D.colorSpace!=="rgb"&&!eu[D.colorSpace])throw new Error(`Unknown color space: ${D.colorSpace}`);let ft,_t,At;if(Ge==="exponential")ft=Wa;else if(Ge==="interval")ft=la;else if(Ge==="categorical"){ft=wa,_t=Object.create(null);for(const Nt of D.stops)_t[Nt[0]]=Nt[1];At=typeof D.stops[0][0]}else{if(Ge!=="identity")throw new Error(`Unknown function type "${Ge}"`);ft=lo}if(X){const Nt={},cn=[];for(let jn=0;jn<D.stops.length;jn++){const Zn=D.stops[jn],Br=Zn[0].zoom;Nt[Br]===void 0&&(Nt[Br]={zoom:Br,type:D.type,property:D.property,default:D.default,stops:[]},cn.push(Br)),Nt[Br].stops.push([Zn[0].value,Zn[1]])}const vn=[];for(const jn of cn)vn.push([Nt[jn].zoom,ah(Nt[jn],_)]);const bn={name:"linear"};return{kind:"composite",interpolationType:bn,interpolationFactor:Gs.interpolationFactor.bind(void 0,bn),zoomStops:vn.map(jn=>jn[0]),evaluate:({zoom:jn},Zn)=>Wa({stops:vn,base:D.base},_,jn).evaluate(jn,Zn)}}if(de){const Nt=Ge==="exponential"?{name:"exponential",base:D.base!==void 0?D.base:1}:null;return{kind:"camera",interpolationType:Nt,interpolationFactor:Gs.interpolationFactor.bind(void 0,Nt),zoomStops:D.stops.map(cn=>cn[0]),evaluate:({zoom:cn})=>ft(D,_,cn,_t,At)}}return{kind:"source",evaluate(Nt,cn){const vn=cn&&cn.properties?cn.properties[D.property]:void 0;return vn===void 0?Mi(D.default,_.default):ft(D,_,vn,_t,At)}}}function Mi(D,_,k){return D!==void 0?D:_!==void 0?_:k!==void 0?k:void 0}function wa(D,_,k,X,de){return Mi(typeof k===de?X[k]:void 0,D.default,_.default)}function la(D,_,k){if(ol(k)!=="number")return Mi(D.default,_.default);const X=D.stops.length;if(X===1||k<=D.stops[0][0])return D.stops[0][1];if(k>=D.stops[X-1][0])return D.stops[X-1][1];const de=Cn(D.stops.map(Ge=>Ge[0]),k);return D.stops[de][1]}function Wa(D,_,k){const X=D.base!==void 0?D.base:1;if(ol(k)!=="number")return Mi(D.default,_.default);const de=D.stops.length;if(de===1||k<=D.stops[0][0])return D.stops[0][1];if(k>=D.stops[de-1][0])return D.stops[de-1][1];const Ge=Cn(D.stops.map(cn=>cn[0]),k),ft=function(cn,vn,bn,jn){const Zn=jn-bn,Br=cn-bn;return Zn===0?0:vn===1?Br/Zn:(Math.pow(vn,Br)-1)/(Math.pow(vn,Zn)-1)}(k,X,D.stops[Ge][0],D.stops[Ge+1][0]),_t=D.stops[Ge][1],At=D.stops[Ge+1][1];let Nt=yt[_.type]||qu;if(D.colorSpace&&D.colorSpace!=="rgb"){const cn=eu[D.colorSpace];Nt=(vn,bn)=>cn.reverse(cn.interpolate(cn.forward(vn),cn.forward(bn),ft))}return typeof _t.evaluate=="function"?{evaluate(...cn){const vn=_t.evaluate.apply(void 0,cn),bn=At.evaluate.apply(void 0,cn);if(vn!==void 0&&bn!==void 0)return Nt(vn,bn,ft)}}:Nt(_t,At,ft)}function lo(D,_,k){return _.type==="color"?k=ga.parse(k):_.type==="formatted"?k=Go.fromString(k.toString()):_.type==="resolvedImage"?k=Uo.fromString(k.toString()):ol(k)===_.type||_.type==="enum"&&_.values[k]||(k=void 0),Mi(k,D.default,_.default)}js.register(cd,{error:[{kind:"error"},[Zs],(D,[_])=>{throw new Ol(_.evaluate(D))}],typeof:[Zs,[jo],(D,[_])=>Is(Bl(_.evaluate(D)))],"to-rgba":[zl(po,4),[Xl],(D,[_])=>_.evaluate(D).toArray()],rgb:[Xl,[po,po,po],wu],rgba:[Xl,[po,po,po,po],wu],has:{type:Es,overloads:[[[Zs],(D,[_])=>oc(_.evaluate(D),D.properties())],[[Zs,xl],(D,[_,k])=>oc(_.evaluate(D),k.evaluate(D))]]},get:{type:jo,overloads:[[[Zs],(D,[_])=>gc(_.evaluate(D),D.properties())],[[Zs,xl],(D,[_,k])=>gc(_.evaluate(D),k.evaluate(D))]]},"feature-state":[jo,[Zs],(D,[_])=>gc(_.evaluate(D),D.featureState||{})],properties:[xl,[],D=>D.properties()],"geometry-type":[Zs,[],D=>D.geometryType()],id:[jo,[],D=>D.id()],zoom:[po,[],D=>D.globals.zoom],pitch:[po,[],D=>D.globals.pitch||0],"distance-from-center":[po,[],D=>D.distanceFromCenter()],"heatmap-density":[po,[],D=>D.globals.heatmapDensity||0],"line-progress":[po,[],D=>D.globals.lineProgress||0],"sky-radial-progress":[po,[],D=>D.globals.skyRadialProgress||0],accumulated:[jo,[],D=>D.globals.accumulated===void 0?null:D.globals.accumulated],"+":[po,dd(po),(D,_)=>{let k=0;for(const X of _)k+=X.evaluate(D);return k}],"*":[po,dd(po),(D,_)=>{let k=1;for(const X of _)k*=X.evaluate(D);return k}],"-":{type:po,overloads:[[[po,po],(D,[_,k])=>_.evaluate(D)-k.evaluate(D)],[[po],(D,[_])=>-_.evaluate(D)]]},"/":[po,[po,po],(D,[_,k])=>_.evaluate(D)/k.evaluate(D)],"%":[po,[po,po],(D,[_,k])=>_.evaluate(D)%k.evaluate(D)],ln2:[po,[],()=>Math.LN2],pi:[po,[],()=>Math.PI],e:[po,[],()=>Math.E],"^":[po,[po,po],(D,[_,k])=>Math.pow(_.evaluate(D),k.evaluate(D))],sqrt:[po,[po],(D,[_])=>Math.sqrt(_.evaluate(D))],log10:[po,[po],(D,[_])=>Math.log(_.evaluate(D))/Math.LN10],ln:[po,[po],(D,[_])=>Math.log(_.evaluate(D))],log2:[po,[po],(D,[_])=>Math.log(_.evaluate(D))/Math.LN2],sin:[po,[po],(D,[_])=>Math.sin(_.evaluate(D))],cos:[po,[po],(D,[_])=>Math.cos(_.evaluate(D))],tan:[po,[po],(D,[_])=>Math.tan(_.evaluate(D))],asin:[po,[po],(D,[_])=>Math.asin(_.evaluate(D))],acos:[po,[po],(D,[_])=>Math.acos(_.evaluate(D))],atan:[po,[po],(D,[_])=>Math.atan(_.evaluate(D))],min:[po,dd(po),(D,_)=>Math.min(..._.map(k=>k.evaluate(D)))],max:[po,dd(po),(D,_)=>Math.max(..._.map(k=>k.evaluate(D)))],abs:[po,[po],(D,[_])=>Math.abs(_.evaluate(D))],round:[po,[po],(D,[_])=>{const k=_.evaluate(D);return k<0?-Math.round(-k):Math.round(k)}],floor:[po,[po],(D,[_])=>Math.floor(_.evaluate(D))],ceil:[po,[po],(D,[_])=>Math.ceil(_.evaluate(D))],"filter-==":[Es,[Zs,jo],(D,[_,k])=>D.properties()[_.value]===k.value],"filter-id-==":[Es,[jo],(D,[_])=>D.id()===_.value],"filter-type-==":[Es,[Zs],(D,[_])=>D.geometryType()===_.value],"filter-<":[Es,[Zs,jo],(D,[_,k])=>{const X=D.properties()[_.value],de=k.value;return typeof X==typeof de&&X<de}],"filter-id-<":[Es,[jo],(D,[_])=>{const k=D.id(),X=_.value;return typeof k==typeof X&&k<X}],"filter->":[Es,[Zs,jo],(D,[_,k])=>{const X=D.properties()[_.value],de=k.value;return typeof X==typeof de&&X>de}],"filter-id->":[Es,[jo],(D,[_])=>{const k=D.id(),X=_.value;return typeof k==typeof X&&k>X}],"filter-<=":[Es,[Zs,jo],(D,[_,k])=>{const X=D.properties()[_.value],de=k.value;return typeof X==typeof de&&X<=de}],"filter-id-<=":[Es,[jo],(D,[_])=>{const k=D.id(),X=_.value;return typeof k==typeof X&&k<=X}],"filter->=":[Es,[Zs,jo],(D,[_,k])=>{const X=D.properties()[_.value],de=k.value;return typeof X==typeof de&&X>=de}],"filter-id->=":[Es,[jo],(D,[_])=>{const k=D.id(),X=_.value;return typeof k==typeof X&&k>=X}],"filter-has":[Es,[jo],(D,[_])=>_.value in D.properties()],"filter-has-id":[Es,[],D=>D.id()!==null&&D.id()!==void 0],"filter-type-in":[Es,[zl(Zs)],(D,[_])=>_.value.indexOf(D.geometryType())>=0],"filter-id-in":[Es,[zl(jo)],(D,[_])=>_.value.indexOf(D.id())>=0],"filter-in-small":[Es,[Zs,zl(jo)],(D,[_,k])=>k.value.indexOf(D.properties()[_.value])>=0],"filter-in-large":[Es,[Zs,zl(jo)],(D,[_,k])=>function(X,de,Ge,ft){for(;Ge<=ft;){const _t=Ge+ft>>1;if(de[_t]===X)return!0;de[_t]>X?ft=_t-1:Ge=_t+1}return!1}(D.properties()[_.value],k.value,0,k.value.length-1)],all:{type:Es,overloads:[[[Es,Es],(D,[_,k])=>_.evaluate(D)&&k.evaluate(D)],[dd(Es),(D,_)=>{for(const k of _)if(!k.evaluate(D))return!1;return!0}]]},any:{type:Es,overloads:[[[Es,Es],(D,[_,k])=>_.evaluate(D)||k.evaluate(D)],[dd(Es),(D,_)=>{for(const k of _)if(k.evaluate(D))return!0;return!1}]]},"!":[Es,[Es],(D,[_])=>!_.evaluate(D)],"is-supported-script":[Es,[Zs],(D,[_])=>{const k=D.globals&&D.globals.isSupportedScript;return!k||k(_.evaluate(D))}],upcase:[Zs,[Zs],(D,[_])=>_.evaluate(D).toUpperCase()],downcase:[Zs,[Zs],(D,[_])=>_.evaluate(D).toLowerCase()],concat:[Zs,dd(jo),(D,_)=>_.map(k=>Jl(k.evaluate(D))).join("")],"resolved-locale":[Zs,[ju],(D,[_])=>_.evaluate(D).resolvedLocale()]});class Jo{constructor(_,k){this.expression=_,this._warningHistory={},this._evaluator=new jc,this._defaultValue=k?function(X){return X.type==="color"&&od(X.default)?new ga(0,0,0,0):X.type==="color"?ga.parse(X.default)||null:X.default===void 0?null:X.default}(k):null,this._enumValues=k&&k.type==="enum"?k.values:null}evaluateWithoutErrorHandling(_,k,X,de,Ge,ft,_t,At){return this._evaluator.globals=_,this._evaluator.feature=k,this._evaluator.featureState=X,this._evaluator.canonical=de||null,this._evaluator.availableImages=Ge||null,this._evaluator.formattedSection=ft,this._evaluator.featureTileCoord=_t||null,this._evaluator.featureDistanceData=At||null,this.expression.evaluate(this._evaluator)}evaluate(_,k,X,de,Ge,ft,_t,At){this._evaluator.globals=_,this._evaluator.feature=k||null,this._evaluator.featureState=X||null,this._evaluator.canonical=de||null,this._evaluator.availableImages=Ge||null,this._evaluator.formattedSection=ft||null,this._evaluator.featureTileCoord=_t||null,this._evaluator.featureDistanceData=At||null;try{const Nt=this.expression.evaluate(this._evaluator);if(Nt==null||typeof Nt=="number"&&Nt!=Nt)return this._defaultValue;if(this._enumValues&&!(Nt in this._enumValues))throw new Ol(`Expected value to be one of ${Object.keys(this._enumValues).map(cn=>JSON.stringify(cn)).join(", ")}, but found ${JSON.stringify(Nt)} instead.`);return Nt}catch(Nt){return this._warningHistory[Nt.message]||(this._warningHistory[Nt.message]=!0,typeof console<"u"&&console.warn(Nt.message)),this._defaultValue}}}function Xo(D){return Array.isArray(D)&&D.length>0&&typeof D[0]=="string"&&D[0]in cd}function ei(D,_){const k=new wt(cd,[],_?function(de){const Ge={color:Xl,string:Zs,number:po,enum:Zs,boolean:Es,formatted:Pl,resolvedImage:tl};return de.type==="array"?zl(Ge[de.value]||jo,de.length):Ge[de.type]}(_):void 0),X=k.parse(D,void 0,void 0,void 0,_&&_.type==="string"?{typeAnnotation:"coerce"}:void 0);return X?Jc(new Jo(X,_)):sc(k.errors)}class ii{constructor(_,k){this.kind=_,this._styleExpression=k,this.isStateDependent=_!=="constant"&&!Vo(k.expression)}evaluateWithoutErrorHandling(_,k,X,de,Ge,ft){return this._styleExpression.evaluateWithoutErrorHandling(_,k,X,de,Ge,ft)}evaluate(_,k,X,de,Ge,ft){return this._styleExpression.evaluate(_,k,X,de,Ge,ft)}}class Ma{constructor(_,k,X,de){this.kind=_,this.zoomStops=X,this._styleExpression=k,this.isStateDependent=_!=="camera"&&!Vo(k.expression),this.interpolationType=de}evaluateWithoutErrorHandling(_,k,X,de,Ge,ft){return this._styleExpression.evaluateWithoutErrorHandling(_,k,X,de,Ge,ft)}evaluate(_,k,X,de,Ge,ft){return this._styleExpression.evaluate(_,k,X,de,Ge,ft)}interpolationFactor(_,k,X){return this.interpolationType?Gs.interpolationFactor(this.interpolationType,_,k,X):0}}function pa(D,_){if((D=ei(D,_)).result==="error")return D;const k=D.value.expression,X=Ss(k);if(!X&&!qc(_))return sc([new qo("","data expressions not supported")]);const de=iu(k,["zoom","pitch","distance-from-center"]);if(!de&&!vd(_))return sc([new qo("","zoom expressions not supported")]);const Ge=uo(k);return Ge||de?Ge instanceof qo?sc([Ge]):Ge instanceof Gs&&!Pu(_)?sc([new qo("",'"interpolate" expressions cannot be used with this property')]):Jc(Ge?new Ma(X?"camera":"composite",D.value,Ge.labels,Ge instanceof Gs?Ge.interpolation:void 0):new ii(X?"constant":"source",D.value)):sc([new qo("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.')])}class ca{constructor(_,k){this._parameters=_,this._specification=k,$s(this,ah(this._parameters,this._specification))}static deserialize(_){return new ca(_._parameters,_._specification)}static serialize(_){return{_parameters:_._parameters,_specification:_._specification}}}function uo(D){let _=null;if(D instanceof Lc)_=uo(D.result);else if(D instanceof yl){for(const k of D.args)if(_=uo(k),_)break}else(D instanceof Pn||D instanceof Gs)&&D.input instanceof js&&D.input.name==="zoom"&&(_=D);return _ instanceof qo||D.eachChild(k=>{const X=uo(k);X instanceof qo?_=X:!_&&X?_=new qo("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.'):_&&X&&_!==X&&(_=new qo("",'Only one zoom-based "step" or "interpolate" subexpression may be used in an expression.'))}),_}class ya{constructor(_,k,X,de){this.message=(_?`${_}: `:"")+X,de&&(this.identifier=de),k!=null&&k.__line__&&(this.line=k.__line__)}}function Oo(D){const _=D.key,k=D.value,X=D.valueSpec||{},de=D.objectElementValidators||{},Ge=D.style,ft=D.styleSpec;let _t=[];const At=ol(k);if(At!=="object")return[new ya(_,k,`object expected, ${At} found`)];for(const Nt in k){const cn=Nt.split(".")[0],vn=X[cn]||X["*"];let bn;de[cn]?bn=de[cn]:X[cn]?bn=Cc:de["*"]?bn=de["*"]:X["*"]&&(bn=Cc),bn?_t=_t.concat(bn({key:(_&&`${_}.`)+Nt,value:k[Nt],valueSpec:vn,style:Ge,styleSpec:ft,object:k,objectKey:Nt},k)):_t.push(new ya(_,k[Nt],`unknown property "${Nt}"`))}for(const Nt in X)de[Nt]||X[Nt].required&&X[Nt].default===void 0&&k[Nt]===void 0&&_t.push(new ya(_,k,`missing required property "${Nt}"`));return _t}function Io(D){const _=D.value,k=D.valueSpec,X=D.style,de=D.styleSpec,Ge=D.key,ft=D.arrayElementValidator||Cc;if(ol(_)!=="array")return[new ya(Ge,_,`array expected, ${ol(_)} found`)];if(k.length&&_.length!==k.length)return[new ya(Ge,_,`array length ${k.length} expected, length ${_.length} found`)];if(k["min-length"]&&_.length<k["min-length"])return[new ya(Ge,_,`array length at least ${k["min-length"]} expected, length ${_.length} found`)];let _t={type:k.value,values:k.values,minimum:k.minimum,maximum:k.maximum,function:void 0};de.$version<7&&(_t.function=k.function),ol(k.value)==="object"&&(_t=k.value);let At=[];for(let Nt=0;Nt<_.length;Nt++)At=At.concat(ft({array:_,arrayIndex:Nt,value:_[Nt],valueSpec:_t,style:X,styleSpec:de,key:`${Ge}[${Nt}]`}));return At}function Ws(D){const _=D.key,k=D.value,X=D.valueSpec;let de=ol(k);if(de==="number"&&k!=k&&(de="NaN"),de!=="number")return[new ya(_,k,`number expected, ${de} found`)];if("minimum"in X){let Ge=X.minimum;if(ol(X.minimum)==="array"&&(Ge=X.minimum[D.arrayIndex]),k<Ge)return[new ya(_,k,`${k} is less than the minimum value ${Ge}`)]}if("maximum"in X){let Ge=X.maximum;if(ol(X.maximum)==="array"&&(Ge=X.maximum[D.arrayIndex]),k>Ge)return[new ya(_,k,`${k} is greater than the maximum value ${Ge}`)]}return[]}function gr(D){const _=D.valueSpec,k=ao(D.value.type);let X,de,Ge,ft={};const _t=k!=="categorical"&&D.value.property===void 0,At=!_t,Nt=ol(D.value.stops)==="array"&&ol(D.value.stops[0])==="array"&&ol(D.value.stops[0][0])==="object",cn=Oo({key:D.key,value:D.value,valueSpec:D.styleSpec.function,style:D.style,styleSpec:D.styleSpec,objectElementValidators:{stops:function(jn){if(k==="identity")return[new ya(jn.key,jn.value,'identity function may not have a "stops" property')];let Zn=[];const Br=jn.value;return Zn=Zn.concat(Io({key:jn.key,value:Br,valueSpec:jn.valueSpec,style:jn.style,styleSpec:jn.styleSpec,arrayElementValidator:vn})),ol(Br)==="array"&&Br.length===0&&Zn.push(new ya(jn.key,Br,"array must have at least one stop")),Zn},default:function(jn){return Cc({key:jn.key,value:jn.value,valueSpec:_,style:jn.style,styleSpec:jn.styleSpec})}}});return k==="identity"&&_t&&cn.push(new ya(D.key,D.value,'missing required property "property"')),k==="identity"||D.value.stops||cn.push(new ya(D.key,D.value,'missing required property "stops"')),k==="exponential"&&D.valueSpec.expression&&!Pu(D.valueSpec)&&cn.push(new ya(D.key,D.value,"exponential functions not supported")),D.styleSpec.$version>=8&&(At&&!qc(D.valueSpec)?cn.push(new ya(D.key,D.value,"property functions not supported")):_t&&!vd(D.valueSpec)&&cn.push(new ya(D.key,D.value,"zoom functions not supported"))),k!=="categorical"&&!Nt||D.value.property!==void 0||cn.push(new ya(D.key,D.value,'"property" property is required')),cn;function vn(jn){let Zn=[];const Br=jn.value,Jr=jn.key;if(ol(Br)!=="array")return[new ya(Jr,Br,`array expected, ${ol(Br)} found`)];if(Br.length!==2)return[new ya(Jr,Br,`array length 2 expected, length ${Br.length} found`)];if(Nt){if(ol(Br[0])!=="object")return[new ya(Jr,Br,`object expected, ${ol(Br[0])} found`)];if(Br[0].zoom===void 0)return[new ya(Jr,Br,"object stop key must have zoom")];if(Br[0].value===void 0)return[new ya(Jr,Br,"object stop key must have value")];const si=ao(Br[0].zoom);if(typeof si!="number")return[new ya(Jr,Br[0].zoom,"stop zoom values must be numbers")];if(Ge&&Ge>si)return[new ya(Jr,Br[0].zoom,"stop zoom values must appear in ascending order")];si!==Ge&&(Ge=si,de=void 0,ft={}),Zn=Zn.concat(Oo({key:`${Jr}[0]`,value:Br[0],valueSpec:{zoom:{}},style:jn.style,styleSpec:jn.styleSpec,objectElementValidators:{zoom:Ws,value:bn}}))}else Zn=Zn.concat(bn({key:`${Jr}[0]`,value:Br[0],valueSpec:{},style:jn.style,styleSpec:jn.styleSpec},Br));return Xo(Ps(Br[1]))?Zn.concat([new ya(`${Jr}[1]`,Br[1],"expressions are not allowed in function stops.")]):Zn.concat(Cc({key:`${Jr}[1]`,value:Br[1],valueSpec:_,style:jn.style,styleSpec:jn.styleSpec}))}function bn(jn,Zn){const Br=ol(jn.value),Jr=ao(jn.value),si=jn.value!==null?jn.value:Zn;if(X){if(Br!==X)return[new ya(jn.key,si,`${Br} stop domain type must match previous stop domain type ${X}`)]}else X=Br;if(Br!=="number"&&Br!=="string"&&Br!=="boolean"&&typeof Jr!="number"&&typeof Jr!="string"&&typeof Jr!="boolean")return[new ya(jn.key,si,"stop domain value must be a number, string, or boolean")];if(Br!=="number"&&k!=="categorical"){let Li=`number expected, ${Br} found`;return qc(_)&&k===void 0&&(Li+='\nIf you intended to use a categorical function, specify `"type": "categorical"`.'),[new ya(jn.key,si,Li)]}return k!=="categorical"||Br!=="number"||typeof Jr=="number"&&isFinite(Jr)&&Math.floor(Jr)===Jr?k!=="categorical"&&Br==="number"&&typeof Jr=="number"&&typeof de=="number"&&de!==void 0&&Jr<de?[new ya(jn.key,si,"stop domain values must appear in ascending order")]:(de=Jr,k==="categorical"&&Jr in ft?[new ya(jn.key,si,"stop domain values must be unique")]:(ft[Jr]=!0,[])):[new ya(jn.key,si,`integer expected, found ${String(Jr)}`)]}}function ws(D){const _=(D.expressionContext==="property"?pa:ei)(Ps(D.value),D.valueSpec);if(_.result==="error")return _.value.map(X=>new ya(`${D.key}${X.key}`,D.value,X.message));const k=_.value.expression||_.value._styleExpression.expression;if(D.expressionContext==="property"&&D.propertyKey==="text-font"&&!k.outputDefined())return[new ya(D.key,D.value,`Invalid data expression for "${D.propertyKey}". Output values must be contained as literals within the expression.`)];if(D.expressionContext==="property"&&D.propertyType==="layout"&&!Vo(k))return[new ya(D.key,D.value,'"feature-state" data expressions are not supported with layout properties.')];if(D.expressionContext==="filter")return io(k,D);if(D.expressionContext&&D.expressionContext.indexOf("cluster")===0){if(!iu(k,["zoom","feature-state"]))return[new ya(D.key,D.value,'"zoom" and "feature-state" expressions are not supported with cluster properties.')];if(D.expressionContext==="cluster-initial"&&!Ss(k))return[new ya(D.key,D.value,"Feature data expressions are not supported with initial expression part of cluster properties.")]}return[]}function io(D,_){const k=new Set(["zoom","feature-state","pitch","distance-from-center"]);if(_.valueSpec&&_.valueSpec.expression)for(const de of _.valueSpec.expression.parameters)k.delete(de);if(k.size===0)return[];const X=[];return D instanceof js&&k.has(D.name)?[new ya(_.key,_.value,`["${D.name}"] expression is not supported in a filter for a ${_.object.type} layer with id: ${_.object.id}`)]:(D.eachChild(de=>{X.push(...io(de,_))}),X)}function Fo(D){const _=D.key,k=D.value,X=D.valueSpec,de=[];return Array.isArray(X.values)?X.values.indexOf(ao(k))===-1&&de.push(new ya(_,k,`expected one of [${X.values.join(", ")}], ${JSON.stringify(k)} found`)):Object.keys(X.values).indexOf(ao(k))===-1&&de.push(new ya(_,k,`expected one of [${Object.keys(X.values).join(", ")}], ${JSON.stringify(k)} found`)),de}function vs(D){if(D===!0||D===!1)return!0;if(!Array.isArray(D)||D.length===0)return!1;switch(D[0]){case"has":return D.length>=2&&D[1]!=="$id"&&D[1]!=="$type";case"in":return D.length>=3&&(typeof D[1]!="string"||Array.isArray(D[2]));case"!in":case"!has":case"none":return!1;case"==":case"!=":case">":case">=":case"<":case"<=":return D.length!==3||Array.isArray(D[1])||Array.isArray(D[2]);case"any":case"all":for(const _ of D.slice(1))if(!vs(_)&&typeof _!="boolean")return!1;return!0;default:return!0}}function Gl(D,_="fill"){if(D==null)return{filter:()=>!0,needGeometry:!1,needFeature:!1};vs(D)||(D=uc(D));const k=D;let X=!0;try{X=function(Nt){if(!Nu(Nt))return Nt;let cn=Ps(Nt);return gu(cn),cn=Mu(cn),cn}(k)}catch{console.warn(`Failed to extract static filter. Filter will continue working, but at higher memory usage and slower framerate.
- This is most likely a bug, please report this via https://github.com/mapbox/mapbox-gl-js/issues/new?assignees=&labels=&template=Bug_report.md
- and paste the contents of this message in the report.
- Thank you!
- Filter Expression:
- ${JSON.stringify(k,null,2)}
- `)}const de=ma[`filter_${_}`],Ge=ei(X,de);let ft=null;if(Ge.result==="error")throw new Error(Ge.value.map(Nt=>`${Nt.key}: ${Nt.message}`).join(", "));ft=(Nt,cn,vn)=>Ge.value.evaluate(Nt,cn,{},vn);let _t=null,At=null;if(X!==k){const Nt=ei(k,de);if(Nt.result==="error")throw new Error(Nt.value.map(cn=>`${cn.key}: ${cn.message}`).join(", "));_t=(cn,vn,bn,jn,Zn)=>Nt.value.evaluate(cn,vn,{},bn,void 0,void 0,jn,Zn),At=!Ss(Nt.value.expression)}return ft=ft,{filter:ft,dynamicFilter:_t||void 0,needGeometry:Zh(X),needFeature:!!At}}function Mu(D){if(!Array.isArray(D))return D;const _=function(k){if(lc.has(k[0])){for(let X=1;X<k.length;X++)if(Nu(k[X]))return!0}return k}(D);return _===!0?_:_.map(k=>Mu(k))}function gu(D){let _=!1;const k=[];if(D[0]==="case"){for(let X=1;X<D.length-1;X+=2)_=_||Nu(D[X]),k.push(D[X+1]);k.push(D[D.length-1])}else if(D[0]==="match"){_=_||Nu(D[1]);for(let X=2;X<D.length-1;X+=2)k.push(D[X+1]);k.push(D[D.length-1])}else if(D[0]==="step"){_=_||Nu(D[1]);for(let X=1;X<D.length-1;X+=2)k.push(D[X+1])}_&&(D.length=0,D.push("any",...k));for(let X=1;X<D.length;X++)gu(D[X])}function Nu(D){if(!Array.isArray(D))return!1;if((_=D[0])==="pitch"||_==="distance-from-center")return!0;var _;for(let k=1;k<D.length;k++)if(Nu(D[k]))return!0;return!1}const lc=new Set(["in","==","!=",">",">=","<","<=","to-boolean"]);function Du(D,_){return D<_?-1:D>_?1:0}function Zh(D){if(!Array.isArray(D))return!1;if(D[0]==="within")return!0;for(let _=1;_<D.length;_++)if(Zh(D[_]))return!0;return!1}function uc(D){if(!D)return!0;const _=D[0];return D.length<=1?_!=="any":_==="=="?Ds(D[1],D[2],"=="):_==="!="?up(Ds(D[1],D[2],"==")):_==="<"||_===">"||_==="<="||_===">="?Ds(D[1],D[2],_):_==="any"?(k=D.slice(1),["any"].concat(k.map(uc))):_==="all"?["all"].concat(D.slice(1).map(uc)):_==="none"?["all"].concat(D.slice(1).map(uc).map(up)):_==="in"?Op(D[1],D.slice(2)):_==="!in"?up(Op(D[1],D.slice(2))):_==="has"?Kh(D[1]):_==="!has"?up(Kh(D[1])):_!=="within"||D;var k}function Ds(D,_,k){switch(D){case"$type":return[`filter-type-${k}`,_];case"$id":return[`filter-id-${k}`,_];default:return[`filter-${k}`,D,_]}}function Op(D,_){if(_.length===0)return!1;switch(D){case"$type":return["filter-type-in",["literal",_]];case"$id":return["filter-id-in",["literal",_]];default:return _.length>200&&!_.some(k=>typeof k!=typeof _[0])?["filter-in-large",D,["literal",_.sort(Du)]]:["filter-in-small",D,["literal",_]]}}function Kh(D){switch(D){case"$type":return!0;case"$id":return["filter-has-id"];default:return["filter-has",D]}}function up(D){return["!",D]}function Fc(D){return vs(Ps(D.value))?ws($s({},D,{expressionContext:"filter",valueSpec:D.styleSpec[`filter_${D.layerType||"fill"}`]})):fh(D)}function fh(D){const _=D.value,k=D.key;if(ol(_)!=="array")return[new ya(k,_,`array expected, ${ol(_)} found`)];const X=D.styleSpec;let de,Ge=[];if(_.length<1)return[new ya(k,_,"filter array must have at least 1 element")];switch(Ge=Ge.concat(Fo({key:`${k}[0]`,value:_[0],valueSpec:X.filter_operator,style:D.style,styleSpec:D.styleSpec})),ao(_[0])){case"<":case"<=":case">":case">=":_.length>=2&&ao(_[1])==="$type"&&Ge.push(new ya(k,_,`"$type" cannot be use with operator "${_[0]}"`));case"==":case"!=":_.length!==3&&Ge.push(new ya(k,_,`filter array for operator "${_[0]}" must have 3 elements`));case"in":case"!in":_.length>=2&&(de=ol(_[1]),de!=="string"&&Ge.push(new ya(`${k}[1]`,_[1],`string expected, ${de} found`)));for(let ft=2;ft<_.length;ft++)de=ol(_[ft]),ao(_[1])==="$type"?Ge=Ge.concat(Fo({key:`${k}[${ft}]`,value:_[ft],valueSpec:X.geometry_type,style:D.style,styleSpec:D.styleSpec})):de!=="string"&&de!=="number"&&de!=="boolean"&&Ge.push(new ya(`${k}[${ft}]`,_[ft],`string, number, or boolean expected, ${de} found`));break;case"any":case"all":case"none":for(let ft=1;ft<_.length;ft++)Ge=Ge.concat(fh({key:`${k}[${ft}]`,value:_[ft],style:D.style,styleSpec:D.styleSpec}));break;case"has":case"!has":de=ol(_[1]),_.length!==2?Ge.push(new ya(k,_,`filter array for "${_[0]}" operator must have 2 elements`)):de!=="string"&&Ge.push(new ya(`${k}[1]`,_[1],`string expected, ${de} found`));break;case"within":de=ol(_[1]),_.length!==2?Ge.push(new ya(k,_,`filter array for "${_[0]}" operator must have 2 elements`)):de!=="object"&&Ge.push(new ya(`${k}[1]`,_[1],`object expected, ${de} found`))}return Ge}function Rd(D,_){const k=D.key,X=D.style,de=D.styleSpec,Ge=D.value,ft=D.objectKey,_t=de[`${_}_${D.layerType}`];if(!_t)return[];const At=ft.match(/^(.*)-transition$/);if(_==="paint"&&At&&_t[At[1]]&&_t[At[1]].transition)return Cc({key:k,value:Ge,valueSpec:de.transition,style:X,styleSpec:de});const Nt=D.valueSpec||_t[ft];if(!Nt)return[new ya(k,Ge,`unknown property "${ft}"`)];let cn;if(ol(Ge)==="string"&&qc(Nt)&&!Nt.tokens&&(cn=/^{([^}]+)}$/.exec(Ge)))return[new ya(k,Ge,`"${ft}" does not support interpolation syntax
- Use an identity property function instead: \`{ "type": "identity", "property": ${JSON.stringify(cn[1])} }\`.`)];const vn=[];return D.layerType==="symbol"&&(ft==="text-field"&&X&&!X.glyphs&&vn.push(new ya(k,Ge,'use of "text-field" requires a style "glyphs" property')),ft==="text-font"&&od(Ps(Ge))&&ao(Ge.type)==="identity"&&vn.push(new ya(k,Ge,'"text-font" does not support identity functions'))),vn.concat(Cc({key:D.key,value:Ge,valueSpec:Nt,style:X,styleSpec:de,expressionContext:"property",propertyType:_,propertyKey:ft}))}function hd(D){return Rd(D,"paint")}function ef(D){return Rd(D,"layout")}function Cf(D){let _=[];const k=D.value,X=D.key,de=D.style,Ge=D.styleSpec;k.type||k.ref||_.push(new ya(X,k,'either "type" or "ref" is required'));let ft=ao(k.type);const _t=ao(k.ref);if(k.id){const At=ao(k.id);for(let Nt=0;Nt<D.arrayIndex;Nt++){const cn=de.layers[Nt];ao(cn.id)===At&&_.push(new ya(X,k.id,`duplicate layer id "${k.id}", previously used at line ${cn.id.__line__}`))}}if("ref"in k){let At;["type","source","source-layer","filter","layout"].forEach(Nt=>{Nt in k&&_.push(new ya(X,k[Nt],`"${Nt}" is prohibited for ref layers`))}),de.layers.forEach(Nt=>{ao(Nt.id)===_t&&(At=Nt)}),At?At.ref?_.push(new ya(X,k.ref,"ref cannot reference another ref layer")):ft=ao(At.type):typeof _t=="string"&&_.push(new ya(X,k.ref,`ref layer "${_t}" not found`))}else if(ft!=="background"&&ft!=="sky")if(k.source){const At=de.sources&&de.sources[k.source],Nt=At&&ao(At.type);At?Nt==="vector"&&ft==="raster"?_.push(new ya(X,k.source,`layer "${k.id}" requires a raster source`)):Nt==="raster"&&ft!=="raster"?_.push(new ya(X,k.source,`layer "${k.id}" requires a vector source`)):Nt!=="vector"||k["source-layer"]?Nt==="raster-dem"&&ft!=="hillshade"?_.push(new ya(X,k.source,"raster-dem source can only be used with layer type 'hillshade'.")):ft!=="line"||!k.paint||!k.paint["line-gradient"]||Nt==="geojson"&&At.lineMetrics||_.push(new ya(X,k,`layer "${k.id}" specifies a line-gradient, which requires a GeoJSON source with \`lineMetrics\` enabled.`)):_.push(new ya(X,k,`layer "${k.id}" must specify a "source-layer"`)):_.push(new ya(X,k.source,`source "${k.source}" not found`))}else _.push(new ya(X,k,'missing required property "source"'));return _=_.concat(Oo({key:X,value:k,valueSpec:Ge.layer,style:D.style,styleSpec:D.styleSpec,objectElementValidators:{"*":()=>[],type:()=>Cc({key:`${X}.type`,value:k.type,valueSpec:Ge.layer.type,style:D.style,styleSpec:D.styleSpec,object:k,objectKey:"type"}),filter:At=>Fc($s({layerType:ft},At)),layout:At=>Oo({layer:k,key:At.key,value:At.value,valueSpec:{},style:At.style,styleSpec:At.styleSpec,objectElementValidators:{"*":Nt=>ef($s({layerType:ft},Nt))}}),paint:At=>Oo({layer:k,key:At.key,value:At.value,valueSpec:{},style:At.style,styleSpec:At.styleSpec,objectElementValidators:{"*":Nt=>hd($s({layerType:ft},Nt))}})}})),_}function _d(D){const _=D.value,k=D.key,X=ol(_);return X!=="string"?[new ya(k,_,`string expected, ${X} found`)]:[]}const oh={promoteId:function({key:D,value:_}){if(ol(_)==="string")return _d({key:D,value:_});{const k=[];for(const X in _)k.push(..._d({key:`${D}.${X}`,value:_[X]}));return k}}};function tf(D){const _=D.value,k=D.key,X=D.styleSpec,de=D.style;if(!_.type)return[new ya(k,_,'"type" is required')];const Ge=ao(_.type);let ft;switch(Ge){case"vector":case"raster":case"raster-dem":return ft=Oo({key:k,value:_,valueSpec:X[`source_${Ge.replace("-","_")}`],style:D.style,styleSpec:X,objectElementValidators:oh}),ft;case"geojson":if(ft=Oo({key:k,value:_,valueSpec:X.source_geojson,style:de,styleSpec:X,objectElementValidators:oh}),_.cluster)for(const _t in _.clusterProperties){const[At,Nt]=_.clusterProperties[_t],cn=typeof At=="string"?[At,["accumulated"],["get",_t]]:At;ft.push(...ws({key:`${k}.${_t}.map`,value:Nt,expressionContext:"cluster-map"})),ft.push(...ws({key:`${k}.${_t}.reduce`,value:cn,expressionContext:"cluster-reduce"}))}return ft;case"video":return Oo({key:k,value:_,valueSpec:X.source_video,style:de,styleSpec:X});case"image":return Oo({key:k,value:_,valueSpec:X.source_image,style:de,styleSpec:X});case"canvas":return[new ya(k,null,"Please use runtime APIs to add canvas sources, rather than including them in stylesheets.","source.canvas")];default:return Fo({key:`${k}.type`,value:_.type,valueSpec:{values:["vector","raster","raster-dem","geojson","video","image"]},style:de,styleSpec:X})}}function Lp(D){const _=D.value,k=D.styleSpec,X=k.light,de=D.style;let Ge=[];const ft=ol(_);if(_===void 0)return Ge;if(ft!=="object")return Ge=Ge.concat([new ya("light",_,`object expected, ${ft} found`)]),Ge;for(const _t in _){const At=_t.match(/^(.*)-transition$/);Ge=Ge.concat(At&&X[At[1]]&&X[At[1]].transition?Cc({key:_t,value:_[_t],valueSpec:k.transition,style:de,styleSpec:k}):X[_t]?Cc({key:_t,value:_[_t],valueSpec:X[_t],style:de,styleSpec:k}):[new ya(_t,_[_t],`unknown property "${_t}"`)])}return Ge}function Ah(D){const _=D.value,k=D.key,X=D.style,de=D.styleSpec,Ge=de.terrain;let ft=[];const _t=ol(_);if(_===void 0)return ft;if(_t!=="object")return ft=ft.concat([new ya("terrain",_,`object expected, ${_t} found`)]),ft;for(const At in _){const Nt=At.match(/^(.*)-transition$/);ft=ft.concat(Nt&&Ge[Nt[1]]&&Ge[Nt[1]].transition?Cc({key:At,value:_[At],valueSpec:de.transition,style:X,styleSpec:de}):Ge[At]?Cc({key:At,value:_[At],valueSpec:Ge[At],style:X,styleSpec:de}):[new ya(At,_[At],`unknown property "${At}"`)])}if(_.source){const At=X.sources&&X.sources[_.source],Nt=At&&ao(At.type);At?Nt!=="raster-dem"&&ft.push(new ya(k,_.source,`terrain cannot be used with a source of type ${String(Nt)}, it only be used with a "raster-dem" source type`)):ft.push(new ya(k,_.source,`source "${_.source}" not found`))}else ft.push(new ya(k,_,'terrain is missing required property "source"'));return ft}function cp(D){const _=D.value,k=D.style,X=D.styleSpec,de=X.fog;let Ge=[];const ft=ol(_);if(_===void 0)return Ge;if(ft!=="object")return Ge=Ge.concat([new ya("fog",_,`object expected, ${ft} found`)]),Ge;for(const _t in _){const At=_t.match(/^(.*)-transition$/);Ge=Ge.concat(At&&de[At[1]]&&de[At[1]].transition?Cc({key:_t,value:_[_t],valueSpec:X.transition,style:k,styleSpec:X}):de[_t]?Cc({key:_t,value:_[_t],valueSpec:de[_t],style:k,styleSpec:X}):[new ya(_t,_[_t],`unknown property "${_t}"`)])}return Ge}const yc={"*":()=>[],array:Io,boolean:function(D){const _=D.value,k=D.key,X=ol(_);return X!=="boolean"?[new ya(k,_,`boolean expected, ${X} found`)]:[]},number:Ws,color:function(D){const _=D.key,k=D.value,X=ol(k);return X!=="string"?[new ya(_,k,`color expected, ${X} found`)]:qi.parseCSSColor(k)===null?[new ya(_,k,`color expected, "${k}" found`)]:[]},enum:Fo,filter:Fc,function:gr,layer:Cf,object:Oo,source:tf,light:Lp,terrain:Ah,fog:cp,string:_d,formatted:function(D){return _d(D).length===0?[]:ws(D)},resolvedImage:function(D){return _d(D).length===0?[]:ws(D)},projection:function(D){const _=D.value,k=D.styleSpec,X=k.projection,de=D.style;let Ge=[];const ft=ol(_);if(ft==="object")for(const _t in _)Ge=Ge.concat(Cc({key:_t,value:_[_t],valueSpec:X[_t],style:de,styleSpec:k}));else ft!=="string"&&(Ge=Ge.concat([new ya("projection",_,`object or string expected, ${ft} found`)]));return Ge}};function Cc(D){const _=D.value,k=D.valueSpec,X=D.styleSpec;return k.expression&&od(ao(_))?gr(D):k.expression&&Xo(Ps(_))?ws(D):k.type&&yc[k.type]?yc[k.type](D):Oo($s({},D,{valueSpec:k.type?X[k.type]:k}))}function lu(D){const _=D.value,k=D.key,X=_d(D);return X.length||(_.indexOf("{fontstack}")===-1&&X.push(new ya(k,_,'"glyphs" url must include a "{fontstack}" token')),_.indexOf("{range}")===-1&&X.push(new ya(k,_,'"glyphs" url must include a "{range}" token'))),X}function Od(D,_=ma){return Sc(Cc({key:"",value:D,valueSpec:_.$root,styleSpec:_,style:D,objectElementValidators:{glyphs:lu,"*":()=>[]}}))}const nf=D=>Sc(hd(D)),Wf=D=>Sc(ef(D));function Sc(D){return D.slice().sort((_,k)=>_.line&&k.line?_.line-k.line:0)}function Sf(D,_){let k=!1;if(_&&_.length)for(const X of _)D.fire(new Lo(new Error(X.message))),k=!0;return k}var vc=ul;function ul(D,_,k){var X=this.cells=[];if(D instanceof ArrayBuffer){this.arrayBuffer=D;var de=new Int32Array(this.arrayBuffer);D=de[0],this.d=(_=de[1])+2*(k=de[2]);for(var Ge=0;Ge<this.d*this.d;Ge++){var ft=de[3+Ge],_t=de[3+Ge+1];X.push(ft===_t?null:de.subarray(ft,_t))}var At=de[3+X.length+1];this.keys=de.subarray(de[3+X.length],At),this.bboxes=de.subarray(At),this.insert=this._insertReadonly}else{this.d=_+2*k;for(var Nt=0;Nt<this.d*this.d;Nt++)X.push([]);this.keys=[],this.bboxes=[]}this.n=_,this.extent=D,this.padding=k,this.scale=_/D,this.uid=0;var cn=k/_*D;this.min=-cn,this.max=D+cn}ul.prototype.insert=function(D,_,k,X,de){this._forEachCell(_,k,X,de,this._insertCell,this.uid++),this.keys.push(D),this.bboxes.push(_),this.bboxes.push(k),this.bboxes.push(X),this.bboxes.push(de)},ul.prototype._insertReadonly=function(){throw"Cannot insert into a GridIndex created from an ArrayBuffer."},ul.prototype._insertCell=function(D,_,k,X,de,Ge){this.cells[de].push(Ge)},ul.prototype.query=function(D,_,k,X,de){var Ge=this.min,ft=this.max;if(D<=Ge&&_<=Ge&&ft<=k&&ft<=X&&!de)return Array.prototype.slice.call(this.keys);var _t=[];return this._forEachCell(D,_,k,X,this._queryCell,_t,{},de),_t},ul.prototype._queryCell=function(D,_,k,X,de,Ge,ft,_t){var At=this.cells[de];if(At!==null)for(var Nt=this.keys,cn=this.bboxes,vn=0;vn<At.length;vn++){var bn=At[vn];if(ft[bn]===void 0){var jn=4*bn;(_t?_t(cn[jn+0],cn[jn+1],cn[jn+2],cn[jn+3]):D<=cn[jn+2]&&_<=cn[jn+3]&&k>=cn[jn+0]&&X>=cn[jn+1])?(ft[bn]=!0,Ge.push(Nt[bn])):ft[bn]=!1}}},ul.prototype._forEachCell=function(D,_,k,X,de,Ge,ft,_t){for(var At=this._convertToCellCoord(D),Nt=this._convertToCellCoord(_),cn=this._convertToCellCoord(k),vn=this._convertToCellCoord(X),bn=At;bn<=cn;bn++)for(var jn=Nt;jn<=vn;jn++){var Zn=this.d*jn+bn;if((!_t||_t(this._convertFromCellCoord(bn),this._convertFromCellCoord(jn),this._convertFromCellCoord(bn+1),this._convertFromCellCoord(jn+1)))&&de.call(this,D,_,k,X,Zn,Ge,ft,_t))return}},ul.prototype._convertFromCellCoord=function(D){return(D-this.padding)/this.scale},ul.prototype._convertToCellCoord=function(D){return Math.max(0,Math.min(this.d-1,Math.floor(D*this.scale)+this.padding))},ul.prototype.toArrayBuffer=function(){if(this.arrayBuffer)return this.arrayBuffer;for(var D=this.cells,_=3+this.cells.length+1+1,k=0,X=0;X<this.cells.length;X++)k+=this.cells[X].length;var de=new Int32Array(_+k+this.keys.length+this.bboxes.length);de[0]=this.extent,de[1]=this.n,de[2]=this.padding;for(var Ge=_,ft=0;ft<D.length;ft++){var _t=D[ft];de[3+ft]=Ge,de.set(_t,Ge),Ge+=_t.length}return de[3+D.length]=Ge,de.set(this.keys,Ge),de[3+D.length+1]=Ge+=this.keys.length,de.set(this.bboxes,Ge),Ge+=this.bboxes.length,de.buffer};const dp={};function Zo(D,_,k={}){Object.defineProperty(D,"_classRegistryKey",{value:_,writeable:!1}),dp[_]={klass:D,omit:k.omit||[]}}Zo(Object,"Object"),vc.serialize=function(D,_){const k=D.toArrayBuffer();return _&&_.push(k),{buffer:k}},vc.deserialize=function(D){return new vc(D.buffer)},Object.defineProperty(vc,"name",{value:"Grid"}),Zo(vc,"Grid"),Zo(ga,"Color"),Zo(Error,"Error"),Zo(zn,"AJAXError"),Zo(Uo,"ResolvedImage"),Zo(ca,"StylePropertyFunction"),Zo(Jo,"StyleExpression",{omit:["_evaluator"]}),Zo(Ma,"ZoomDependentExpression"),Zo(ii,"ZoomConstantExpression"),Zo(js,"CompoundExpression",{omit:["_evaluate"]});for(const D in cd)dp[cd[D]._classRegistryKey]||Zo(cd[D],`Expression${D}`);function Xh(D){return D&&typeof ArrayBuffer<"u"&&(D instanceof ArrayBuffer||D.constructor&&D.constructor.name==="ArrayBuffer")}function kc(D){return J.ImageBitmap&&D instanceof J.ImageBitmap}function Fp(D,_){if(D==null||typeof D=="boolean"||typeof D=="number"||typeof D=="string"||D instanceof Boolean||D instanceof Number||D instanceof String||D instanceof Date||D instanceof RegExp)return D;if(Xh(D)||kc(D))return _&&_.push(D),D;if(ArrayBuffer.isView(D)){const k=D;return _&&_.push(k.buffer),k}if(D instanceof J.ImageData)return _&&_.push(D.data.buffer),D;if(Array.isArray(D)){const k=[];for(const X of D)k.push(Fp(X,_));return k}if(typeof D=="object"){const k=D.constructor,X=k._classRegistryKey;if(!X)throw new Error(`can't serialize object of unregistered class ${X}`);const de=k.serialize?k.serialize(D,_):{};if(!k.serialize){for(const Ge in D)D.hasOwnProperty(Ge)&&(dp[X].omit.indexOf(Ge)>=0||(de[Ge]=Fp(D[Ge],_)));D instanceof Error&&(de.message=D.message)}if(de.$name)throw new Error("$name property is reserved for worker serialization logic.");return X!=="Object"&&(de.$name=X),de}throw new Error("can't serialize object of type "+typeof D)}function kh(D){if(D==null||typeof D=="boolean"||typeof D=="number"||typeof D=="string"||D instanceof Boolean||D instanceof Number||D instanceof String||D instanceof Date||D instanceof RegExp||Xh(D)||kc(D)||ArrayBuffer.isView(D)||D instanceof J.ImageData)return D;if(Array.isArray(D))return D.map(kh);if(typeof D=="object"){const _=D.$name||"Object",{klass:k}=dp[_];if(!k)throw new Error(`can't deserialize unregistered class ${_}`);if(k.deserialize)return k.deserialize(D);const X=Object.create(k.prototype);for(const de of Object.keys(D))de!=="$name"&&(X[de]=kh(D[de]));return X}throw new Error("can't deserialize object of type "+typeof D)}class Tf{constructor(){this.first=!0}update(_,k){const X=Math.floor(_);return this.first?(this.first=!1,this.lastIntegerZoom=X,this.lastIntegerZoomTime=0,this.lastZoom=_,this.lastFloorZoom=X,!0):(this.lastFloorZoom>X?(this.lastIntegerZoom=X+1,this.lastIntegerZoomTime=k):this.lastFloorZoom<X&&(this.lastIntegerZoom=X,this.lastIntegerZoomTime=k),_!==this.lastZoom&&(this.lastZoom=_,this.lastFloorZoom=X,!0))}}const Ld=D=>D>=1536&&D<=1791,Gd=D=>D>=1872&&D<=1919,cc=D=>D>=2208&&D<=2303,Jh=D=>D>=11904&&D<=12031,hp=D=>D>=12032&&D<=12255,pp=D=>D>=12272&&D<=12287,Ph=D=>D>=12288&&D<=12351,mh=D=>D>=12352&&D<=12447,Ih=D=>D>=12448&&D<=12543,Ts=D=>D>=12544&&D<=12591,qf=D=>D>=12704&&D<=12735,Bp=D=>D>=12736&&D<=12783,Qh=D=>D>=12784&&D<=12799,ql=D=>D>=12800&&D<=13055,Xd=D=>D>=13056&&D<=13311,Kl=D=>D>=13312&&D<=19903,Vp=D=>D>=19968&&D<=40959,ep=D=>D>=40960&&D<=42127,Df=D=>D>=42128&&D<=42191,xd=D=>D>=44032&&D<=55215,rf=D=>D>=63744&&D<=64255,af=D=>D>=64336&&D<=65023,Yf=D=>D>=65040&&D<=65055,fp=D=>D>=65072&&D<=65103,Zf=D=>D>=65104&&D<=65135,pd=D=>D>=65136&&D<=65279,gh=D=>D>=65280&&D<=65519;function Np(D){for(const _ of D)if(bd(_.charCodeAt(0)))return!0;return!1}function Im(D){for(const _ of D)if(!Rh(_.charCodeAt(0)))return!1;return!0}function Rh(D){return!(Ld(D)||Gd(D)||cc(D)||af(D)||pd(D))}function bd(D){return!(D!==746&&D!==747&&(D<4352||!(qf(D)||Ts(D)||fp(D)&&!(D>=65097&&D<=65103)||rf(D)||Xd(D)||Jh(D)||Bp(D)||!(!Ph(D)||D>=12296&&D<=12305||D>=12308&&D<=12319||D===12336)||Kl(D)||Vp(D)||ql(D)||(_=>_>=12592&&_<=12687)(D)||(_=>_>=43360&&_<=43391)(D)||(_=>_>=55216&&_<=55295)(D)||(_=>_>=4352&&_<=4607)(D)||xd(D)||mh(D)||pp(D)||(_=>_>=12688&&_<=12703)(D)||hp(D)||Qh(D)||Ih(D)&&D!==12540||!(!gh(D)||D===65288||D===65289||D===65293||D>=65306&&D<=65310||D===65339||D===65341||D===65343||D>=65371&&D<=65503||D===65507||D>=65512&&D<=65519)||!(!Zf(D)||D>=65112&&D<=65118||D>=65123&&D<=65126)||(_=>_>=5120&&_<=5759)(D)||(_=>_>=6320&&_<=6399)(D)||Yf(D)||(_=>_>=19904&&_<=19967)(D)||ep(D)||Df(D))))}function sd(D){return!(bd(D)||function(_){return!!((k=>k>=128&&k<=255)(_)&&(_===167||_===169||_===174||_===177||_===188||_===189||_===190||_===215||_===247)||(k=>k>=8192&&k<=8303)(_)&&(_===8214||_===8224||_===8225||_===8240||_===8241||_===8251||_===8252||_===8258||_===8263||_===8264||_===8265||_===8273)||(k=>k>=8448&&k<=8527)(_)||(k=>k>=8528&&k<=8591)(_)||(k=>k>=8960&&k<=9215)(_)&&(_>=8960&&_<=8967||_>=8972&&_<=8991||_>=8996&&_<=9e3||_===9003||_>=9085&&_<=9114||_>=9150&&_<=9165||_===9167||_>=9169&&_<=9179||_>=9186&&_<=9215)||(k=>k>=9216&&k<=9279)(_)&&_!==9251||(k=>k>=9280&&k<=9311)(_)||(k=>k>=9312&&k<=9471)(_)||(k=>k>=9632&&k<=9727)(_)||(k=>k>=9728&&k<=9983)(_)&&!(_>=9754&&_<=9759)||(k=>k>=11008&&k<=11263)(_)&&(_>=11026&&_<=11055||_>=11088&&_<=11097||_>=11192&&_<=11243)||Ph(_)||Ih(_)||(k=>k>=57344&&k<=63743)(_)||fp(_)||Zf(_)||gh(_)||_===8734||_===8756||_===8757||_>=9984&&_<=10087||_>=10102&&_<=10131||_===65532||_===65533)}(D))}function of(D){return D>=1424&&D<=2303||af(D)||pd(D)}function Rm(D,_){return!(!_&&of(D)||D>=2304&&D<=3583||D>=3840&&D<=4255||(k=>k>=6016&&k<=6143)(D))}function Om(D){for(const _ of D)if(of(_.charCodeAt(0)))return!0;return!1}const Oh="deferred",Ef="loading",Lh="loaded";let Kf=null,Fd="unavailable",Bd=null;const sf=function(D){D&&typeof D=="string"&&D.indexOf("NetworkError")>-1&&(Fd="error"),Kf&&Kf(D)};function mp(){Xf.fire(new Po("pluginStateChange",{pluginStatus:Fd,pluginURL:Bd}))}const Xf=new Wo,Af=function(){return Fd},Qc=function(){if(Fd!==Oh||!Bd)throw new Error("rtl-text-plugin cannot be downloaded unless a pluginURL is specified");Fd=Ef,mp(),Bd&&ni({url:Bd},D=>{D?sf(D):(Fd=Lh,mp())})},$c={applyArabicShaping:null,processBidirectionalText:null,processStyledBidirectionalText:null,isLoaded:()=>Fd===Lh||$c.applyArabicShaping!=null,isLoading:()=>Fd===Ef,setState(D){Fd=D.pluginStatus,Bd=D.pluginURL},isParsed:()=>$c.applyArabicShaping!=null&&$c.processBidirectionalText!=null&&$c.processStyledBidirectionalText!=null,getPluginURL:()=>Bd};class Iu{constructor(_,k){this.zoom=_,k?(this.now=k.now,this.fadeDuration=k.fadeDuration,this.zoomHistory=k.zoomHistory,this.transition=k.transition,this.pitch=k.pitch):(this.now=0,this.fadeDuration=0,this.zoomHistory=new Tf,this.transition={},this.pitch=0)}isSupportedScript(_){return function(k,X){for(const de of k)if(!Rm(de.charCodeAt(0),X))return!1;return!0}(_,$c.isLoaded())}crossFadingFactor(){return this.fadeDuration===0?1:Math.min((this.now-this.zoomHistory.lastIntegerZoomTime)/this.fadeDuration,1)}getCrossfadeParameters(){const _=this.zoom,k=_-Math.floor(_),X=this.crossFadingFactor();return _>this.zoomHistory.lastIntegerZoom?{fromScale:2,toScale:1,t:k+(1-k)*X}:{fromScale:.5,toScale:1,t:1-(1-X)*k}}}class Fh{constructor(_,k){this.property=_,this.value=k,this.expression=function(X,de){if(od(X))return new ca(X,de);if(Xo(X)){const Ge=pa(X,de);if(Ge.result==="error")throw new Error(Ge.value.map(ft=>`${ft.key}: ${ft.message}`).join(", "));return Ge.value}{let Ge=X;return typeof X=="string"&&de.type==="color"&&(Ge=ga.parse(X)),{kind:"constant",evaluate:()=>Ge}}}(k===void 0?_.specification.default:k,_.specification)}isDataDriven(){return this.expression.kind==="source"||this.expression.kind==="composite"}possiblyEvaluate(_,k,X){return this.property.possiblyEvaluate(this,_,k,X)}}class zp{constructor(_){this.property=_,this.value=new Fh(_,void 0)}transitioned(_,k){return new w(this.property,this.value,k,mt({},_.transition,this.transition),_.now)}untransitioned(){return new w(this.property,this.value,null,{},0)}}class Ee{constructor(_){this._properties=_,this._values=Object.create(_.defaultTransitionablePropertyValues)}getValue(_){return Rn(this._values[_].value.value)}setValue(_,k){this._values.hasOwnProperty(_)||(this._values[_]=new zp(this._values[_].property)),this._values[_].value=new Fh(this._values[_].property,k===null?void 0:Rn(k))}getTransition(_){return Rn(this._values[_].transition)}setTransition(_,k){this._values.hasOwnProperty(_)||(this._values[_]=new zp(this._values[_].property)),this._values[_].transition=Rn(k)||void 0}serialize(){const _={};for(const k of Object.keys(this._values)){const X=this.getValue(k);X!==void 0&&(_[k]=X);const de=this.getTransition(k);de!==void 0&&(_[`${k}-transition`]=de)}return _}transitioned(_,k){const X=new se(this._properties);for(const de of Object.keys(this._values))X._values[de]=this._values[de].transitioned(_,k._values[de]);return X}untransitioned(){const _=new se(this._properties);for(const k of Object.keys(this._values))_._values[k]=this._values[k].untransitioned();return _}}class w{constructor(_,k,X,de,Ge){const ft=de.delay||0,_t=de.duration||0;Ge=Ge||0,this.property=_,this.value=k,this.begin=Ge+ft,this.end=this.begin+_t,_.specification.transition&&(de.delay||de.duration)&&(this.prior=X)}possiblyEvaluate(_,k,X){const de=_.now||0,Ge=this.value.possiblyEvaluate(_,k,X),ft=this.prior;if(ft){if(de>this.end)return this.prior=null,Ge;if(this.value.isDataDriven())return this.prior=null,Ge;if(de<this.begin)return ft.possiblyEvaluate(_,k,X);{const _t=(de-this.begin)/(this.end-this.begin);return this.property.interpolate(ft.possiblyEvaluate(_,k,X),Ge,Ve(_t))}}return Ge}}class se{constructor(_){this._properties=_,this._values=Object.create(_.defaultTransitioningPropertyValues)}possiblyEvaluate(_,k,X){const de=new Dt(this._properties);for(const Ge of Object.keys(this._values))de._values[Ge]=this._values[Ge].possiblyEvaluate(_,k,X);return de}hasTransition(){for(const _ of Object.keys(this._values))if(this._values[_].prior)return!0;return!1}}class it{constructor(_){this._properties=_,this._values=Object.create(_.defaultPropertyValues)}getValue(_){return Rn(this._values[_].value)}setValue(_,k){this._values[_]=new Fh(this._values[_].property,k===null?void 0:Rn(k))}serialize(){const _={};for(const k of Object.keys(this._values)){const X=this.getValue(k);X!==void 0&&(_[k]=X)}return _}possiblyEvaluate(_,k,X){const de=new Dt(this._properties);for(const Ge of Object.keys(this._values))de._values[Ge]=this._values[Ge].possiblyEvaluate(_,k,X);return de}}class xt{constructor(_,k,X){this.property=_,this.value=k,this.parameters=X}isConstant(){return this.value.kind==="constant"}constantOr(_){return this.value.kind==="constant"?this.value.value:_}evaluate(_,k,X,de){return this.property.evaluate(this.value,this.parameters,_,k,X,de)}}class Dt{constructor(_){this._properties=_,this._values=Object.create(_.defaultPossiblyEvaluatedValues)}get(_){return this._values[_]}}class Ot{constructor(_){this.specification=_}possiblyEvaluate(_,k){return _.expression.evaluate(k)}interpolate(_,k,X){const de=yt[this.specification.type];return de?de(_,k,X):_}}class rn{constructor(_,k){this.specification=_,this.overrides=k}possiblyEvaluate(_,k,X,de){return new xt(this,_.expression.kind==="constant"||_.expression.kind==="camera"?{kind:"constant",value:_.expression.evaluate(k,null,{},X,de)}:_.expression,k)}interpolate(_,k,X){if(_.value.kind!=="constant"||k.value.kind!=="constant")return _;if(_.value.value===void 0||k.value.value===void 0)return new xt(this,{kind:"constant",value:void 0},_.parameters);const de=yt[this.specification.type];return de?new xt(this,{kind:"constant",value:de(_.value.value,k.value.value,X)},_.parameters):_}evaluate(_,k,X,de,Ge,ft){return _.kind==="constant"?_.value:_.evaluate(k,X,de,Ge,ft)}}class Tn extends rn{possiblyEvaluate(_,k,X,de){if(_.value===void 0)return new xt(this,{kind:"constant",value:void 0},k);if(_.expression.kind==="constant"){const Ge=_.expression.evaluate(k,null,{},X,de),ft=_.property.specification.type==="resolvedImage"&&typeof Ge!="string"?Ge.name:Ge,_t=this._calculate(ft,ft,ft,k);return new xt(this,{kind:"constant",value:_t},k)}if(_.expression.kind==="camera"){const Ge=this._calculate(_.expression.evaluate({zoom:k.zoom-1}),_.expression.evaluate({zoom:k.zoom}),_.expression.evaluate({zoom:k.zoom+1}),k);return new xt(this,{kind:"constant",value:Ge},k)}return new xt(this,_.expression,k)}evaluate(_,k,X,de,Ge,ft){if(_.kind==="source"){const _t=_.evaluate(k,X,de,Ge,ft);return this._calculate(_t,_t,_t,k)}return _.kind==="composite"?this._calculate(_.evaluate({zoom:Math.floor(k.zoom)-1},X,de),_.evaluate({zoom:Math.floor(k.zoom)},X,de),_.evaluate({zoom:Math.floor(k.zoom)+1},X,de),k):_.value}_calculate(_,k,X,de){return de.zoom>de.zoomHistory.lastIntegerZoom?{from:_,to:k,other:X}:{from:X,to:k,other:_}}interpolate(_){return _}}class kn{constructor(_){this.specification=_}possiblyEvaluate(_,k,X,de){if(_.value!==void 0){if(_.expression.kind==="constant"){const Ge=_.expression.evaluate(k,null,{},X,de);return this._calculate(Ge,Ge,Ge,k)}return this._calculate(_.expression.evaluate(new Iu(Math.floor(k.zoom-1),k)),_.expression.evaluate(new Iu(Math.floor(k.zoom),k)),_.expression.evaluate(new Iu(Math.floor(k.zoom+1),k)),k)}}_calculate(_,k,X,de){return de.zoom>de.zoomHistory.lastIntegerZoom?{from:_,to:k}:{from:X,to:k}}interpolate(_){return _}}class Bn{constructor(_){this.specification=_}possiblyEvaluate(_,k,X,de){return!!_.expression.evaluate(k,null,{},X,de)}interpolate(){return!1}}class Wn{constructor(_){this.properties=_,this.defaultPropertyValues={},this.defaultTransitionablePropertyValues={},this.defaultTransitioningPropertyValues={},this.defaultPossiblyEvaluatedValues={},this.overridableProperties=[];for(const k in _){const X=_[k];X.specification.overridable&&this.overridableProperties.push(k);const de=this.defaultPropertyValues[k]=new Fh(X,void 0),Ge=this.defaultTransitionablePropertyValues[k]=new zp(X);this.defaultTransitioningPropertyValues[k]=Ge.untransitioned(),this.defaultPossiblyEvaluatedValues[k]=de.possiblyEvaluate({})}}}function Fr(D,_){return 256*(D=Te(Math.floor(D),0,255))+Te(Math.floor(_),0,255)}Zo(rn,"DataDrivenProperty"),Zo(Ot,"DataConstantProperty"),Zo(Tn,"CrossFadedDataDrivenProperty"),Zo(kn,"CrossFadedProperty"),Zo(Bn,"ColorRampProperty");const ri={Int8:Int8Array,Uint8:Uint8Array,Int16:Int16Array,Uint16:Uint16Array,Int32:Int32Array,Uint32:Uint32Array,Float32:Float32Array};class Zr{constructor(_,k){this._structArray=_,this._pos1=k*this.size,this._pos2=this._pos1/2,this._pos4=this._pos1/4,this._pos8=this._pos1/8}}class Sr{constructor(){this.isTransferred=!1,this.capacity=-1,this.resize(0)}static serialize(_,k){return _._trim(),k&&(_.isTransferred=!0,k.push(_.arrayBuffer)),{length:_.length,arrayBuffer:_.arrayBuffer}}static deserialize(_){const k=Object.create(this.prototype);return k.arrayBuffer=_.arrayBuffer,k.length=_.length,k.capacity=_.arrayBuffer.byteLength/k.bytesPerElement,k._refreshViews(),k}_trim(){this.length!==this.capacity&&(this.capacity=this.length,this.arrayBuffer=this.arrayBuffer.slice(0,this.length*this.bytesPerElement),this._refreshViews())}clear(){this.length=0}resize(_){this.reserve(_),this.length=_}reserve(_){if(_>this.capacity){this.capacity=Math.max(_,Math.floor(5*this.capacity),128),this.arrayBuffer=new ArrayBuffer(this.capacity*this.bytesPerElement);const k=this.uint8;this._refreshViews(),k&&this.uint8.set(k)}}_refreshViews(){throw new Error("_refreshViews() must be implemented by each concrete StructArray layout")}destroy(){this.int8=this.uint8=this.int16=this.uint16=this.int32=this.uint32=this.float32=null,this.arrayBuffer=null}}function Di(D,_=1){let k=0,X=0;return{members:D.map(de=>{const Ge=ri[de.type].BYTES_PER_ELEMENT,ft=k=di(k,Math.max(_,Ge)),_t=de.components||1;return X=Math.max(X,Ge),k+=Ge*_t,{name:de.name,type:de.type,components:_t,offset:ft}}),size:di(k,Math.max(X,_)),alignment:_}}function di(D,_){return Math.ceil(D/_)*_}class wi extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(_,k){const X=this.length;return this.resize(X+1),this.emplace(X,_,k)}emplace(_,k,X){const de=2*_;return this.int16[de+0]=k,this.int16[de+1]=X,_}}wi.prototype.bytesPerElement=4,Zo(wi,"StructArrayLayout2i4");class Ti extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(_,k,X){const de=this.length;return this.resize(de+1),this.emplace(de,_,k,X)}emplace(_,k,X,de){const Ge=3*_;return this.int16[Ge+0]=k,this.int16[Ge+1]=X,this.int16[Ge+2]=de,_}}Ti.prototype.bytesPerElement=6,Zo(Ti,"StructArrayLayout3i6");class Oi extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(_,k,X,de){const Ge=this.length;return this.resize(Ge+1),this.emplace(Ge,_,k,X,de)}emplace(_,k,X,de,Ge){const ft=4*_;return this.int16[ft+0]=k,this.int16[ft+1]=X,this.int16[ft+2]=de,this.int16[ft+3]=Ge,_}}Oi.prototype.bytesPerElement=8,Zo(Oi,"StructArrayLayout4i8");class _i extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(_,k,X,de,Ge,ft,_t){const At=this.length;return this.resize(At+1),this.emplace(At,_,k,X,de,Ge,ft,_t)}emplace(_,k,X,de,Ge,ft,_t,At){const Nt=6*_,cn=12*_,vn=3*_;return this.int16[Nt+0]=k,this.int16[Nt+1]=X,this.uint8[cn+4]=de,this.uint8[cn+5]=Ge,this.uint8[cn+6]=ft,this.uint8[cn+7]=_t,this.float32[vn+2]=At,_}}_i.prototype.bytesPerElement=12,Zo(_i,"StructArrayLayout2i4ub1f12");class Fi extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(_,k,X,de){const Ge=this.length;return this.resize(Ge+1),this.emplace(Ge,_,k,X,de)}emplace(_,k,X,de,Ge){const ft=4*_;return this.float32[ft+0]=k,this.float32[ft+1]=X,this.float32[ft+2]=de,this.float32[ft+3]=Ge,_}}Fi.prototype.bytesPerElement=16,Zo(Fi,"StructArrayLayout4f16");class Ta extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(_,k,X,de,Ge,ft,_t,At,Nt,cn){const vn=this.length;return this.resize(vn+1),this.emplace(vn,_,k,X,de,Ge,ft,_t,At,Nt,cn)}emplace(_,k,X,de,Ge,ft,_t,At,Nt,cn,vn){const bn=10*_;return this.uint16[bn+0]=k,this.uint16[bn+1]=X,this.uint16[bn+2]=de,this.uint16[bn+3]=Ge,this.uint16[bn+4]=ft,this.uint16[bn+5]=_t,this.uint16[bn+6]=At,this.uint16[bn+7]=Nt,this.uint16[bn+8]=cn,this.uint16[bn+9]=vn,_}}Ta.prototype.bytesPerElement=20,Zo(Ta,"StructArrayLayout10ui20");class Fa extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(_,k,X,de,Ge,ft,_t,At){const Nt=this.length;return this.resize(Nt+1),this.emplace(Nt,_,k,X,de,Ge,ft,_t,At)}emplace(_,k,X,de,Ge,ft,_t,At,Nt){const cn=8*_;return this.uint16[cn+0]=k,this.uint16[cn+1]=X,this.uint16[cn+2]=de,this.uint16[cn+3]=Ge,this.uint16[cn+4]=ft,this.uint16[cn+5]=_t,this.uint16[cn+6]=At,this.uint16[cn+7]=Nt,_}}Fa.prototype.bytesPerElement=16,Zo(Fa,"StructArrayLayout8ui16");class qa extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(_,k,X,de,Ge,ft){const _t=this.length;return this.resize(_t+1),this.emplace(_t,_,k,X,de,Ge,ft)}emplace(_,k,X,de,Ge,ft,_t){const At=6*_;return this.int16[At+0]=k,this.int16[At+1]=X,this.int16[At+2]=de,this.int16[At+3]=Ge,this.int16[At+4]=ft,this.int16[At+5]=_t,_}}qa.prototype.bytesPerElement=12,Zo(qa,"StructArrayLayout6i12");class ja extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn,Br,Jr){const si=this.length;return this.resize(si+1),this.emplace(si,_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn,Br,Jr)}emplace(_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn,Br,Jr,si){const Li=16*_;return this.int16[Li+0]=k,this.int16[Li+1]=X,this.int16[Li+2]=de,this.int16[Li+3]=Ge,this.uint16[Li+4]=ft,this.uint16[Li+5]=_t,this.uint16[Li+6]=At,this.uint16[Li+7]=Nt,this.int16[Li+8]=cn,this.int16[Li+9]=vn,this.int16[Li+10]=bn,this.int16[Li+11]=jn,this.int16[Li+12]=Zn,this.int16[Li+13]=Br,this.int16[Li+14]=Jr,this.int16[Li+15]=si,_}}ja.prototype.bytesPerElement=32,Zo(ja,"StructArrayLayout4i4ui4i4i32");class To extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(_,k,X){const de=this.length;return this.resize(de+1),this.emplace(de,_,k,X)}emplace(_,k,X,de){const Ge=3*_;return this.float32[Ge+0]=k,this.float32[Ge+1]=X,this.float32[Ge+2]=de,_}}To.prototype.bytesPerElement=12,Zo(To,"StructArrayLayout3f12");class na extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer)}emplaceBack(_){const k=this.length;return this.resize(k+1),this.emplace(k,_)}emplace(_,k){return this.uint32[1*_+0]=k,_}}na.prototype.bytesPerElement=4,Zo(na,"StructArrayLayout1ul4");class Eo extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn){const Zn=this.length;return this.resize(Zn+1),this.emplace(Zn,_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn)}emplace(_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn){const Br=20*_,Jr=10*_;return this.int16[Br+0]=k,this.int16[Br+1]=X,this.int16[Br+2]=de,this.int16[Br+3]=Ge,this.int16[Br+4]=ft,this.float32[Jr+3]=_t,this.float32[Jr+4]=At,this.float32[Jr+5]=Nt,this.float32[Jr+6]=cn,this.int16[Br+14]=vn,this.uint32[Jr+8]=bn,this.uint16[Br+18]=jn,this.uint16[Br+19]=Zn,_}}Eo.prototype.bytesPerElement=40,Zo(Eo,"StructArrayLayout5i4f1i1ul2ui40");class So extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(_,k,X,de,Ge,ft,_t){const At=this.length;return this.resize(At+1),this.emplace(At,_,k,X,de,Ge,ft,_t)}emplace(_,k,X,de,Ge,ft,_t,At){const Nt=8*_;return this.int16[Nt+0]=k,this.int16[Nt+1]=X,this.int16[Nt+2]=de,this.int16[Nt+4]=Ge,this.int16[Nt+5]=ft,this.int16[Nt+6]=_t,this.int16[Nt+7]=At,_}}So.prototype.bytesPerElement=16,Zo(So,"StructArrayLayout3i2i2i16");class Qo extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(_,k,X,de,Ge){const ft=this.length;return this.resize(ft+1),this.emplace(ft,_,k,X,de,Ge)}emplace(_,k,X,de,Ge,ft){const _t=4*_,At=8*_;return this.float32[_t+0]=k,this.float32[_t+1]=X,this.float32[_t+2]=de,this.int16[At+6]=Ge,this.int16[At+7]=ft,_}}Qo.prototype.bytesPerElement=16,Zo(Qo,"StructArrayLayout2f1f2i16");class Za extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(_,k,X,de){const Ge=this.length;return this.resize(Ge+1),this.emplace(Ge,_,k,X,de)}emplace(_,k,X,de,Ge){const ft=12*_,_t=3*_;return this.uint8[ft+0]=k,this.uint8[ft+1]=X,this.float32[_t+1]=de,this.float32[_t+2]=Ge,_}}Za.prototype.bytesPerElement=12,Zo(Za,"StructArrayLayout2ub2f12");class rs extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(_,k,X){const de=this.length;return this.resize(de+1),this.emplace(de,_,k,X)}emplace(_,k,X,de){const Ge=3*_;return this.uint16[Ge+0]=k,this.uint16[Ge+1]=X,this.uint16[Ge+2]=de,_}}rs.prototype.bytesPerElement=6,Zo(rs,"StructArrayLayout3ui6");class is extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer)}emplaceBack(_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn,Br,Jr,si,Li,vi,ui,ua){const ba=this.length;return this.resize(ba+1),this.emplace(ba,_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn,Br,Jr,si,Li,vi,ui,ua)}emplace(_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn,Br,Jr,si,Li,vi,ui,ua,ba){const Ua=30*_,Ga=15*_,ho=60*_;return this.int16[Ua+0]=k,this.int16[Ua+1]=X,this.int16[Ua+2]=de,this.float32[Ga+2]=Ge,this.float32[Ga+3]=ft,this.uint16[Ua+8]=_t,this.uint16[Ua+9]=At,this.uint32[Ga+5]=Nt,this.uint32[Ga+6]=cn,this.uint32[Ga+7]=vn,this.uint16[Ua+16]=bn,this.uint16[Ua+17]=jn,this.uint16[Ua+18]=Zn,this.float32[Ga+10]=Br,this.float32[Ga+11]=Jr,this.uint8[ho+48]=si,this.uint8[ho+49]=Li,this.uint8[ho+50]=vi,this.uint32[Ga+13]=ui,this.int16[Ua+28]=ua,this.uint8[ho+58]=ba,_}}is.prototype.bytesPerElement=60,Zo(is,"StructArrayLayout3i2f2ui3ul3ui2f3ub1ul1i1ub60");class hs extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer)}emplaceBack(_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn,Br,Jr,si,Li,vi,ui,ua,ba,Ua,Ga,ho,bo,Va,Ka,Do,$o){const Ro=this.length;return this.resize(Ro+1),this.emplace(Ro,_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn,Br,Jr,si,Li,vi,ui,ua,ba,Ua,Ga,ho,bo,Va,Ka,Do,$o)}emplace(_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn,Br,Jr,si,Li,vi,ui,ua,ba,Ua,Ga,ho,bo,Va,Ka,Do,$o,Ro){const No=38*_,Sl=19*_;return this.int16[No+0]=k,this.int16[No+1]=X,this.int16[No+2]=de,this.float32[Sl+2]=Ge,this.float32[Sl+3]=ft,this.int16[No+8]=_t,this.int16[No+9]=At,this.int16[No+10]=Nt,this.int16[No+11]=cn,this.int16[No+12]=vn,this.int16[No+13]=bn,this.uint16[No+14]=jn,this.uint16[No+15]=Zn,this.uint16[No+16]=Br,this.uint16[No+17]=Jr,this.uint16[No+18]=si,this.uint16[No+19]=Li,this.uint16[No+20]=vi,this.uint16[No+21]=ui,this.uint16[No+22]=ua,this.uint16[No+23]=ba,this.uint16[No+24]=Ua,this.uint16[No+25]=Ga,this.uint16[No+26]=ho,this.uint16[No+27]=bo,this.uint16[No+28]=Va,this.uint32[Sl+15]=Ka,this.float32[Sl+16]=Do,this.float32[Sl+17]=$o,this.float32[Sl+18]=Ro,_}}hs.prototype.bytesPerElement=76,Zo(hs,"StructArrayLayout3i2f6i15ui1ul3f76");class ps extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(_){const k=this.length;return this.resize(k+1),this.emplace(k,_)}emplace(_,k){return this.float32[1*_+0]=k,_}}ps.prototype.bytesPerElement=4,Zo(ps,"StructArrayLayout1f4");class Js extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(_,k,X,de,Ge,ft,_t){const At=this.length;return this.resize(At+1),this.emplace(At,_,k,X,de,Ge,ft,_t)}emplace(_,k,X,de,Ge,ft,_t,At){const Nt=7*_;return this.float32[Nt+0]=k,this.float32[Nt+1]=X,this.float32[Nt+2]=de,this.float32[Nt+3]=Ge,this.float32[Nt+4]=ft,this.float32[Nt+5]=_t,this.float32[Nt+6]=At,_}}Js.prototype.bytesPerElement=28,Zo(Js,"StructArrayLayout7f28");class fl extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(_,k,X,de,Ge){const ft=this.length;return this.resize(ft+1),this.emplace(ft,_,k,X,de,Ge)}emplace(_,k,X,de,Ge,ft){const _t=5*_;return this.float32[_t+0]=k,this.float32[_t+1]=X,this.float32[_t+2]=de,this.float32[_t+3]=Ge,this.float32[_t+4]=ft,_}}fl.prototype.bytesPerElement=20,Zo(fl,"StructArrayLayout5f20");class as extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(_,k,X,de){const Ge=this.length;return this.resize(Ge+1),this.emplace(Ge,_,k,X,de)}emplace(_,k,X,de,Ge){const ft=6*_;return this.uint32[3*_+0]=k,this.uint16[ft+2]=X,this.uint16[ft+3]=de,this.uint16[ft+4]=Ge,_}}as.prototype.bytesPerElement=12,Zo(as,"StructArrayLayout1ul3ui12");class ll extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(_,k){const X=this.length;return this.resize(X+1),this.emplace(X,_,k)}emplace(_,k,X){const de=2*_;return this.uint16[de+0]=k,this.uint16[de+1]=X,_}}ll.prototype.bytesPerElement=4,Zo(ll,"StructArrayLayout2ui4");class Yl extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(_){const k=this.length;return this.resize(k+1),this.emplace(k,_)}emplace(_,k){return this.uint16[1*_+0]=k,_}}Yl.prototype.bytesPerElement=2,Zo(Yl,"StructArrayLayout1ui2");class dc extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(_,k){const X=this.length;return this.resize(X+1),this.emplace(X,_,k)}emplace(_,k,X){const de=2*_;return this.float32[de+0]=k,this.float32[de+1]=X,_}}dc.prototype.bytesPerElement=8,Zo(dc,"StructArrayLayout2f8");class _c extends Sr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(_,k,X,de,Ge,ft,_t){const At=this.length;return this.resize(At+1),this.emplace(At,_,k,X,de,Ge,ft,_t)}emplace(_,k,X,de,Ge,ft,_t,At){const Nt=8*_,cn=4*_;return this.int16[Nt+0]=k,this.int16[Nt+1]=X,this.int16[Nt+2]=de,this.int16[Nt+3]=Ge,this.int16[Nt+4]=ft,this.int16[Nt+5]=_t,this.float32[cn+3]=At,_}}_c.prototype.bytesPerElement=16,Zo(_c,"StructArrayLayout6i1f16");class Bc extends Zr{get a_pos_30(){return this._structArray.int16[this._pos2+0]}get a_pos_31(){return this._structArray.int16[this._pos2+1]}get a_pos_32(){return this._structArray.int16[this._pos2+2]}get a_pos_normal_30(){return this._structArray.int16[this._pos2+3]}get a_pos_normal_31(){return this._structArray.int16[this._pos2+4]}get a_pos_normal_32(){return this._structArray.int16[this._pos2+5]}}Bc.prototype.size=12;class Ud extends qa{get(_){return new Bc(this,_)}}Zo(Ud,"FillExtrusionExtArray");class sh extends Zr{get projectedAnchorX(){return this._structArray.int16[this._pos2+0]}get projectedAnchorY(){return this._structArray.int16[this._pos2+1]}get projectedAnchorZ(){return this._structArray.int16[this._pos2+2]}get tileAnchorX(){return this._structArray.int16[this._pos2+3]}get tileAnchorY(){return this._structArray.int16[this._pos2+4]}get x1(){return this._structArray.float32[this._pos4+3]}get y1(){return this._structArray.float32[this._pos4+4]}get x2(){return this._structArray.float32[this._pos4+5]}get y2(){return this._structArray.float32[this._pos4+6]}get padding(){return this._structArray.int16[this._pos2+14]}get featureIndex(){return this._structArray.uint32[this._pos4+8]}get sourceLayerIndex(){return this._structArray.uint16[this._pos2+18]}get bucketIndex(){return this._structArray.uint16[this._pos2+19]}}sh.prototype.size=40;class yh extends Eo{get(_){return new sh(this,_)}}Zo(yh,"CollisionBoxArray");class Bh extends Zr{get projectedAnchorX(){return this._structArray.int16[this._pos2+0]}get projectedAnchorY(){return this._structArray.int16[this._pos2+1]}get projectedAnchorZ(){return this._structArray.int16[this._pos2+2]}get tileAnchorX(){return this._structArray.float32[this._pos4+2]}get tileAnchorY(){return this._structArray.float32[this._pos4+3]}get glyphStartIndex(){return this._structArray.uint16[this._pos2+8]}get numGlyphs(){return this._structArray.uint16[this._pos2+9]}get vertexStartIndex(){return this._structArray.uint32[this._pos4+5]}get lineStartIndex(){return this._structArray.uint32[this._pos4+6]}get lineLength(){return this._structArray.uint32[this._pos4+7]}get segment(){return this._structArray.uint16[this._pos2+16]}get lowerSize(){return this._structArray.uint16[this._pos2+17]}get upperSize(){return this._structArray.uint16[this._pos2+18]}get lineOffsetX(){return this._structArray.float32[this._pos4+10]}get lineOffsetY(){return this._structArray.float32[this._pos4+11]}get writingMode(){return this._structArray.uint8[this._pos1+48]}get placedOrientation(){return this._structArray.uint8[this._pos1+49]}set placedOrientation(_){this._structArray.uint8[this._pos1+49]=_}get hidden(){return this._structArray.uint8[this._pos1+50]}set hidden(_){this._structArray.uint8[this._pos1+50]=_}get crossTileID(){return this._structArray.uint32[this._pos4+13]}set crossTileID(_){this._structArray.uint32[this._pos4+13]=_}get associatedIconIndex(){return this._structArray.int16[this._pos2+28]}get flipState(){return this._structArray.uint8[this._pos1+58]}set flipState(_){this._structArray.uint8[this._pos1+58]=_}}Bh.prototype.size=60;class Vh extends is{get(_){return new Bh(this,_)}}Zo(Vh,"PlacedSymbolArray");class Uu extends Zr{get projectedAnchorX(){return this._structArray.int16[this._pos2+0]}get projectedAnchorY(){return this._structArray.int16[this._pos2+1]}get projectedAnchorZ(){return this._structArray.int16[this._pos2+2]}get tileAnchorX(){return this._structArray.float32[this._pos4+2]}get tileAnchorY(){return this._structArray.float32[this._pos4+3]}get rightJustifiedTextSymbolIndex(){return this._structArray.int16[this._pos2+8]}get centerJustifiedTextSymbolIndex(){return this._structArray.int16[this._pos2+9]}get leftJustifiedTextSymbolIndex(){return this._structArray.int16[this._pos2+10]}get verticalPlacedTextSymbolIndex(){return this._structArray.int16[this._pos2+11]}get placedIconSymbolIndex(){return this._structArray.int16[this._pos2+12]}get verticalPlacedIconSymbolIndex(){return this._structArray.int16[this._pos2+13]}get key(){return this._structArray.uint16[this._pos2+14]}get textBoxStartIndex(){return this._structArray.uint16[this._pos2+15]}get textBoxEndIndex(){return this._structArray.uint16[this._pos2+16]}get verticalTextBoxStartIndex(){return this._structArray.uint16[this._pos2+17]}get verticalTextBoxEndIndex(){return this._structArray.uint16[this._pos2+18]}get iconBoxStartIndex(){return this._structArray.uint16[this._pos2+19]}get iconBoxEndIndex(){return this._structArray.uint16[this._pos2+20]}get verticalIconBoxStartIndex(){return this._structArray.uint16[this._pos2+21]}get verticalIconBoxEndIndex(){return this._structArray.uint16[this._pos2+22]}get featureIndex(){return this._structArray.uint16[this._pos2+23]}get numHorizontalGlyphVertices(){return this._structArray.uint16[this._pos2+24]}get numVerticalGlyphVertices(){return this._structArray.uint16[this._pos2+25]}get numIconVertices(){return this._structArray.uint16[this._pos2+26]}get numVerticalIconVertices(){return this._structArray.uint16[this._pos2+27]}get useRuntimeCollisionCircles(){return this._structArray.uint16[this._pos2+28]}get crossTileID(){return this._structArray.uint32[this._pos4+15]}set crossTileID(_){this._structArray.uint32[this._pos4+15]=_}get textOffset0(){return this._structArray.float32[this._pos4+16]}get textOffset1(){return this._structArray.float32[this._pos4+17]}get collisionCircleDiameter(){return this._structArray.float32[this._pos4+18]}}Uu.prototype.size=76;class ec extends hs{get(_){return new Uu(this,_)}}Zo(ec,"SymbolInstanceArray");class tu extends ps{getoffsetX(_){return this.float32[1*_+0]}}Zo(tu,"GlyphOffsetArray");class tc extends Ti{getx(_){return this.int16[3*_+0]}gety(_){return this.int16[3*_+1]}gettileUnitDistanceFromAnchor(_){return this.int16[3*_+2]}}Zo(tc,"SymbolLineVertexArray");class fd extends Zr{get featureIndex(){return this._structArray.uint32[this._pos4+0]}get sourceLayerIndex(){return this._structArray.uint16[this._pos2+2]}get bucketIndex(){return this._structArray.uint16[this._pos2+3]}get layoutVertexArrayOffset(){return this._structArray.uint16[this._pos2+4]}}fd.prototype.size=12;class Yu extends as{get(_){return new fd(this,_)}}Zo(Yu,"FeatureIndexArray");class Tc extends Zr{get a_centroid_pos0(){return this._structArray.uint16[this._pos2+0]}get a_centroid_pos1(){return this._structArray.uint16[this._pos2+1]}}Tc.prototype.size=4;class $d extends ll{get(_){return new Tc(this,_)}}Zo($d,"FillExtrusionCentroidArray");class Vc extends Zr{get a_pos_30(){return this._structArray.int16[this._pos2+0]}get a_pos_31(){return this._structArray.int16[this._pos2+1]}get a_pos_32(){return this._structArray.int16[this._pos2+2]}get a_pos_normal_30(){return this._structArray.int16[this._pos2+3]}get a_pos_normal_31(){return this._structArray.int16[this._pos2+4]}get a_pos_normal_32(){return this._structArray.int16[this._pos2+5]}get a_scale(){return this._structArray.float32[this._pos4+3]}}Vc.prototype.size=16;class lh extends _c{get(_){return new Vc(this,_)}}Zo(lh,"CircleGlobeExtArray");const gp=Di([{name:"a_pattern_to",components:4,type:"Uint16"},{name:"a_pattern_from",components:4,type:"Uint16"},{name:"a_pixel_ratio_to",components:1,type:"Uint16"},{name:"a_pixel_ratio_from",components:1,type:"Uint16"}]),jp=Di([{name:"a_dash_to",components:4,type:"Uint16"},{name:"a_dash_from",components:4,type:"Uint16"}]);var uh=Qr(function(D){D.exports=function(_,k){var X,de,Ge,ft,_t,At,Nt,cn;for(de=_.length-(X=3&_.length),Ge=k,_t=3432918353,At=461845907,cn=0;cn<de;)Nt=255&_.charCodeAt(cn)|(255&_.charCodeAt(++cn))<<8|(255&_.charCodeAt(++cn))<<16|(255&_.charCodeAt(++cn))<<24,++cn,Ge=27492+(65535&(ft=5*(65535&(Ge=(Ge^=Nt=(65535&(Nt=(Nt=(65535&Nt)*_t+(((Nt>>>16)*_t&65535)<<16)&4294967295)<<15|Nt>>>17))*At+(((Nt>>>16)*At&65535)<<16)&4294967295)<<13|Ge>>>19))+((5*(Ge>>>16)&65535)<<16)&4294967295))+((58964+(ft>>>16)&65535)<<16);switch(Nt=0,X){case 3:Nt^=(255&_.charCodeAt(cn+2))<<16;case 2:Nt^=(255&_.charCodeAt(cn+1))<<8;case 1:Ge^=Nt=(65535&(Nt=(Nt=(65535&(Nt^=255&_.charCodeAt(cn)))*_t+(((Nt>>>16)*_t&65535)<<16)&4294967295)<<15|Nt>>>17))*At+(((Nt>>>16)*At&65535)<<16)&4294967295}return Ge^=_.length,Ge=2246822507*(65535&(Ge^=Ge>>>16))+((2246822507*(Ge>>>16)&65535)<<16)&4294967295,Ge=3266489909*(65535&(Ge^=Ge>>>13))+((3266489909*(Ge>>>16)&65535)<<16)&4294967295,(Ge^=Ge>>>16)>>>0}}),lf=Qr(function(D){D.exports=function(_,k){for(var X,de=_.length,Ge=k^de,ft=0;de>=4;)X=1540483477*(65535&(X=255&_.charCodeAt(ft)|(255&_.charCodeAt(++ft))<<8|(255&_.charCodeAt(++ft))<<16|(255&_.charCodeAt(++ft))<<24))+((1540483477*(X>>>16)&65535)<<16),Ge=1540483477*(65535&Ge)+((1540483477*(Ge>>>16)&65535)<<16)^(X=1540483477*(65535&(X^=X>>>24))+((1540483477*(X>>>16)&65535)<<16)),de-=4,++ft;switch(de){case 3:Ge^=(255&_.charCodeAt(ft+2))<<16;case 2:Ge^=(255&_.charCodeAt(ft+1))<<8;case 1:Ge=1540483477*(65535&(Ge^=255&_.charCodeAt(ft)))+((1540483477*(Ge>>>16)&65535)<<16)}return Ge=1540483477*(65535&(Ge^=Ge>>>13))+((1540483477*(Ge>>>16)&65535)<<16),(Ge^=Ge>>>15)>>>0}}),Hd=uh,tp=lf;Hd.murmur3=uh,Hd.murmur2=tp;class Gp{constructor(){this.ids=[],this.positions=[],this.indexed=!1}add(_,k,X,de){this.ids.push(Jf(_)),this.positions.push(k,X,de)}getPositions(_){const k=Jf(_);let X=0,de=this.ids.length-1;for(;X<de;){const ft=X+de>>1;this.ids[ft]>=k?de=ft:X=ft+1}const Ge=[];for(;this.ids[X]===k;)Ge.push({index:this.positions[3*X],start:this.positions[3*X+1],end:this.positions[3*X+2]}),X++;return Ge}static serialize(_,k){const X=new Float64Array(_.ids),de=new Uint32Array(_.positions);return l3(X,de,0,X.length-1),k&&k.push(X.buffer,de.buffer),{ids:X,positions:de}}static deserialize(_){const k=new Gp;return k.ids=_.ids,k.positions=_.positions,k.indexed=!0,k}}function Jf(D){const _=+D;return!isNaN(_)&&Number.MIN_SAFE_INTEGER<=_&&_<=Number.MAX_SAFE_INTEGER?_:Hd(String(D))}function l3(D,_,k,X){for(;k<X;){const de=D[k+X>>1];let Ge=k-1,ft=X+1;for(;;){do Ge++;while(D[Ge]<de);do ft--;while(D[ft]>de);if(Ge>=ft)break;wd(D,Ge,ft),wd(_,3*Ge,3*ft),wd(_,3*Ge+1,3*ft+1),wd(_,3*Ge+2,3*ft+2)}ft-k<X-ft?(l3(D,_,k,ft),k=ft+1):(l3(D,_,ft+1,X),X=ft)}}function wd(D,_,k){const X=D[_];D[_]=D[k],D[k]=X}Zo(Gp,"FeaturePositionMap");class vh{constructor(_,k){this.gl=_.gl,this.location=k}}class uf extends vh{constructor(_,k){super(_,k),this.current=0}set(_){this.current!==_&&(this.current=_,this.gl.uniform1f(this.location,_))}}class T3 extends vh{constructor(_,k){super(_,k),this.current=[0,0,0,0]}set(_){_[0]===this.current[0]&&_[1]===this.current[1]&&_[2]===this.current[2]&&_[3]===this.current[3]||(this.current=_,this.gl.uniform4f(this.location,_[0],_[1],_[2],_[3]))}}class Qf extends vh{constructor(_,k){super(_,k),this.current=ga.transparent}set(_){_.r===this.current.r&&_.g===this.current.g&&_.b===this.current.b&&_.a===this.current.a||(this.current=_,this.gl.uniform4f(this.location,_.r,_.g,_.b,_.a))}}const J3=new Float32Array(16),Lm=new Float32Array(9),u3=new Float32Array(4);function cf(D){return[Fr(255*D.r,255*D.g),Fr(255*D.b,255*D.a)]}class kf{constructor(_,k,X){this.value=_,this.uniformNames=k.map(de=>`u_${de}`),this.type=X}setUniform(_,k,X){_.set(X.constantOr(this.value))}getBinding(_,k,X){return this.type==="color"?new Qf(_,k):new uf(_,k)}}class yp{constructor(_,k){this.uniformNames=k.map(X=>`u_${X}`),this.patternFrom=null,this.patternTo=null,this.pixelRatioFrom=1,this.pixelRatioTo=1}setConstantPatternPositions(_,k){this.pixelRatioFrom=k.pixelRatio||1,this.pixelRatioTo=_.pixelRatio||1,this.patternFrom=k.tl.concat(k.br),this.patternTo=_.tl.concat(_.br)}setUniform(_,k,X,de){const Ge=de==="u_pattern_to"||de==="u_dash_to"?this.patternTo:de==="u_pattern_from"||de==="u_dash_from"?this.patternFrom:de==="u_pixel_ratio_to"?this.pixelRatioTo:de==="u_pixel_ratio_from"?this.pixelRatioFrom:null;Ge&&_.set(Ge)}getBinding(_,k,X){return X==="u_pattern_from"||X==="u_pattern_to"||X==="u_dash_from"||X==="u_dash_to"?new T3(_,k):new uf(_,k)}}class _h{constructor(_,k,X,de){this.expression=_,this.type=X,this.maxValue=0,this.paintVertexAttributes=k.map(Ge=>({name:`a_${Ge}`,type:"Float32",components:X==="color"?2:1,offset:0})),this.paintVertexArray=new de}populatePaintArray(_,k,X,de,Ge,ft){const _t=this.paintVertexArray.length,At=this.expression.evaluate(new Iu(0),k,{},Ge,de,ft);this.paintVertexArray.resize(_),this._setPaintValue(_t,_,At)}updatePaintArray(_,k,X,de,Ge){const ft=this.expression.evaluate({zoom:0},X,de,void 0,Ge);this._setPaintValue(_,k,ft)}_setPaintValue(_,k,X){if(this.type==="color"){const de=cf(X);for(let Ge=_;Ge<k;Ge++)this.paintVertexArray.emplace(Ge,de[0],de[1])}else{for(let de=_;de<k;de++)this.paintVertexArray.emplace(de,X);this.maxValue=Math.max(this.maxValue,Math.abs(X))}}upload(_){this.paintVertexArray&&this.paintVertexArray.arrayBuffer&&(this.paintVertexBuffer&&this.paintVertexBuffer.buffer?this.paintVertexBuffer.updateData(this.paintVertexArray):this.paintVertexBuffer=_.createVertexBuffer(this.paintVertexArray,this.paintVertexAttributes,this.expression.isStateDependent))}destroy(){this.paintVertexBuffer&&this.paintVertexBuffer.destroy()}}class Nh{constructor(_,k,X,de,Ge,ft){this.expression=_,this.uniformNames=k.map(_t=>`u_${_t}_t`),this.type=X,this.useIntegerZoom=de,this.zoom=Ge,this.maxValue=0,this.paintVertexAttributes=k.map(_t=>({name:`a_${_t}`,type:"Float32",components:X==="color"?4:2,offset:0})),this.paintVertexArray=new ft}populatePaintArray(_,k,X,de,Ge,ft){const _t=this.expression.evaluate(new Iu(this.zoom),k,{},Ge,de,ft),At=this.expression.evaluate(new Iu(this.zoom+1),k,{},Ge,de,ft),Nt=this.paintVertexArray.length;this.paintVertexArray.resize(_),this._setPaintValue(Nt,_,_t,At)}updatePaintArray(_,k,X,de,Ge){const ft=this.expression.evaluate({zoom:this.zoom},X,de,void 0,Ge),_t=this.expression.evaluate({zoom:this.zoom+1},X,de,void 0,Ge);this._setPaintValue(_,k,ft,_t)}_setPaintValue(_,k,X,de){if(this.type==="color"){const Ge=cf(X),ft=cf(de);for(let _t=_;_t<k;_t++)this.paintVertexArray.emplace(_t,Ge[0],Ge[1],ft[0],ft[1])}else{for(let Ge=_;Ge<k;Ge++)this.paintVertexArray.emplace(Ge,X,de);this.maxValue=Math.max(this.maxValue,Math.abs(X),Math.abs(de))}}upload(_){this.paintVertexArray&&this.paintVertexArray.arrayBuffer&&(this.paintVertexBuffer&&this.paintVertexBuffer.buffer?this.paintVertexBuffer.updateData(this.paintVertexArray):this.paintVertexBuffer=_.createVertexBuffer(this.paintVertexArray,this.paintVertexAttributes,this.expression.isStateDependent))}destroy(){this.paintVertexBuffer&&this.paintVertexBuffer.destroy()}setUniform(_,k){const X=this.useIntegerZoom?Math.floor(k.zoom):k.zoom,de=Te(this.expression.interpolationFactor(X,this.zoom,this.zoom+1),0,1);_.set(de)}getBinding(_,k,X){return new uf(_,k)}}class df{constructor(_,k,X,de,Ge,ft,_t){this.expression=_,this.type=X,this.useIntegerZoom=de,this.zoom=Ge,this.layerId=_t,this.paintVertexAttributes=(X==="array"?jp:gp).members;for(let At=0;At<k.length;++At);this.zoomInPaintVertexArray=new ft,this.zoomOutPaintVertexArray=new ft}populatePaintArray(_,k,X){const de=this.zoomInPaintVertexArray.length;this.zoomInPaintVertexArray.resize(_),this.zoomOutPaintVertexArray.resize(_),this._setPaintValues(de,_,k.patterns&&k.patterns[this.layerId],X)}updatePaintArray(_,k,X,de,Ge,ft){this._setPaintValues(_,k,X.patterns&&X.patterns[this.layerId],ft)}_setPaintValues(_,k,X,de){if(!de||!X)return;const{min:Ge,mid:ft,max:_t}=X,At=de[Ge],Nt=de[ft],cn=de[_t];if(At&&Nt&&cn)for(let vn=_;vn<k;vn++)this._setPaintValue(this.zoomInPaintVertexArray,vn,Nt,At),this._setPaintValue(this.zoomOutPaintVertexArray,vn,Nt,cn)}_setPaintValue(_,k,X,de){_.emplace(k,X.tl[0],X.tl[1],X.br[0],X.br[1],de.tl[0],de.tl[1],de.br[0],de.br[1],X.pixelRatio,de.pixelRatio)}upload(_){this.zoomInPaintVertexArray&&this.zoomInPaintVertexArray.arrayBuffer&&this.zoomOutPaintVertexArray&&this.zoomOutPaintVertexArray.arrayBuffer&&(this.zoomInPaintVertexBuffer=_.createVertexBuffer(this.zoomInPaintVertexArray,this.paintVertexAttributes,this.expression.isStateDependent),this.zoomOutPaintVertexBuffer=_.createVertexBuffer(this.zoomOutPaintVertexArray,this.paintVertexAttributes,this.expression.isStateDependent))}destroy(){this.zoomOutPaintVertexBuffer&&this.zoomOutPaintVertexBuffer.destroy(),this.zoomInPaintVertexBuffer&&this.zoomInPaintVertexBuffer.destroy()}}class np{constructor(_,k,X=()=>!0){this.binders={},this._buffers=[];const de=[];for(const Ge in _.paint._values){if(!X(Ge))continue;const ft=_.paint.get(Ge);if(!(ft instanceof xt&&qc(ft.property.specification)))continue;const _t=Fm(Ge,_.type),At=ft.value,Nt=ft.property.specification.type,cn=ft.property.useIntegerZoom,vn=ft.property.specification["property-type"],bn=vn==="cross-faded"||vn==="cross-faded-data-driven",jn=String(Ge)==="line-dasharray"&&_.layout.get("line-cap").value.kind!=="constant";if(At.kind!=="constant"||jn)if(At.kind==="source"||jn||bn){const Zn=Vm(Ge,Nt,"source");this.binders[Ge]=bn?new df(At,_t,Nt,cn,k,Zn,_.id):new _h(At,_t,Nt,Zn),de.push(`/a_${Ge}`)}else{const Zn=Vm(Ge,Nt,"composite");this.binders[Ge]=new Nh(At,_t,Nt,cn,k,Zn),de.push(`/z_${Ge}`)}else this.binders[Ge]=bn?new yp(At.value,_t):new kf(At.value,_t,Nt),de.push(`/u_${Ge}`)}this.cacheKey=de.sort().join("")}getMaxValue(_){const k=this.binders[_];return k instanceof _h||k instanceof Nh?k.maxValue:0}populatePaintArrays(_,k,X,de,Ge,ft){for(const _t in this.binders){const At=this.binders[_t];(At instanceof _h||At instanceof Nh||At instanceof df)&&At.populatePaintArray(_,k,X,de,Ge,ft)}}setConstantPatternPositions(_,k){for(const X in this.binders){const de=this.binders[X];de instanceof yp&&de.setConstantPatternPositions(_,k)}}updatePaintArrays(_,k,X,de,Ge,ft){let _t=!1;for(const At in _){const Nt=k.getPositions(At);for(const cn of Nt){const vn=X.feature(cn.index);for(const bn in this.binders){const jn=this.binders[bn];if((jn instanceof _h||jn instanceof Nh||jn instanceof df)&&jn.expression.isStateDependent===!0){const Zn=de.paint.get(bn);jn.expression=Zn.value,jn.updatePaintArray(cn.start,cn.end,vn,_[At],Ge,ft),_t=!0}}}}return _t}defines(){const _=[];for(const k in this.binders){const X=this.binders[k];(X instanceof kf||X instanceof yp)&&_.push(...X.uniformNames.map(de=>`#define HAS_UNIFORM_${de}`))}return _}getBinderAttributes(){const _=[];for(const k in this.binders){const X=this.binders[k];if(X instanceof _h||X instanceof Nh||X instanceof df)for(let de=0;de<X.paintVertexAttributes.length;de++)_.push(X.paintVertexAttributes[de].name)}return _}getBinderUniforms(){const _=[];for(const k in this.binders){const X=this.binders[k];if(X instanceof kf||X instanceof yp||X instanceof Nh)for(const de of X.uniformNames)_.push(de)}return _}getPaintVertexBuffers(){return this._buffers}getUniforms(_,k){const X=[];for(const de in this.binders){const Ge=this.binders[de];if(Ge instanceof kf||Ge instanceof yp||Ge instanceof Nh){for(const ft of Ge.uniformNames)if(k[ft]){const _t=Ge.getBinding(_,k[ft],ft);X.push({name:ft,property:de,binding:_t})}}}return X}setUniforms(_,k,X,de){for(const{name:Ge,property:ft,binding:_t}of k)this.binders[ft].setUniform(_t,de,X.get(ft),Ge)}updatePaintBuffers(_){this._buffers=[];for(const k in this.binders){const X=this.binders[k];if(_&&X instanceof df){const de=_.fromScale===2?X.zoomInPaintVertexBuffer:X.zoomOutPaintVertexBuffer;de&&this._buffers.push(de)}else(X instanceof _h||X instanceof Nh)&&X.paintVertexBuffer&&this._buffers.push(X.paintVertexBuffer)}}upload(_){for(const k in this.binders){const X=this.binders[k];(X instanceof _h||X instanceof Nh||X instanceof df)&&X.upload(_)}this.updatePaintBuffers()}destroy(){for(const _ in this.binders){const k=this.binders[_];(k instanceof _h||k instanceof Nh||k instanceof df)&&k.destroy()}}}class Up{constructor(_,k,X=()=>!0){this.programConfigurations={};for(const de of _)this.programConfigurations[de.id]=new np(de,k,X);this.needsUpload=!1,this._featureMap=new Gp,this._bufferOffset=0}populatePaintArrays(_,k,X,de,Ge,ft,_t){for(const At in this.programConfigurations)this.programConfigurations[At].populatePaintArrays(_,k,de,Ge,ft,_t);k.id!==void 0&&this._featureMap.add(k.id,X,this._bufferOffset,_),this._bufferOffset=_,this.needsUpload=!0}updatePaintArrays(_,k,X,de,Ge){for(const ft of X)this.needsUpload=this.programConfigurations[ft.id].updatePaintArrays(_,this._featureMap,k,ft,de,Ge)||this.needsUpload}get(_){return this.programConfigurations[_]}upload(_){if(this.needsUpload){for(const k in this.programConfigurations)this.programConfigurations[k].upload(_);this.needsUpload=!1}}destroy(){for(const _ in this.programConfigurations)this.programConfigurations[_].destroy()}}const D3={"text-opacity":["opacity"],"icon-opacity":["opacity"],"text-color":["fill_color"],"icon-color":["fill_color"],"text-halo-color":["halo_color"],"icon-halo-color":["halo_color"],"text-halo-blur":["halo_blur"],"icon-halo-blur":["halo_blur"],"text-halo-width":["halo_width"],"icon-halo-width":["halo_width"],"line-gap-width":["gapwidth"],"line-pattern":["pattern_to","pattern_from","pixel_ratio_to","pixel_ratio_from"],"fill-pattern":["pattern_to","pattern_from","pixel_ratio_to","pixel_ratio_from"],"fill-extrusion-pattern":["pattern_to","pattern_from","pixel_ratio_to","pixel_ratio_from"],"line-dasharray":["dash_to","dash_from"]};function Fm(D,_){return D3[D]||[D.replace(`${_}-`,"").replace(/-/g,"_")]}const em={"line-pattern":{source:Ta,composite:Ta},"fill-pattern":{source:Ta,composite:Ta},"fill-extrusion-pattern":{source:Ta,composite:Ta},"line-dasharray":{source:Fa,composite:Fa}},Bm={color:{source:dc,composite:Fi},number:{source:ps,composite:dc}};function Vm(D,_,k){const X=em[D];return X&&X[k]||Bm[_][k]}Zo(kf,"ConstantBinder"),Zo(yp,"CrossFadedConstantBinder"),Zo(_h,"SourceExpressionBinder"),Zo(df,"CrossFadedCompositeBinder"),Zo(Nh,"CompositeExpressionBinder"),Zo(np,"ProgramConfiguration",{omit:["_buffers"]}),Zo(Up,"ProgramConfigurationSet");const Pc="-transition";class xh extends Wo{constructor(_,k){if(super(),this.id=_.id,this.type=_.type,this._featureFilter={filter:()=>!0,needGeometry:!1,needFeature:!1},this._filterCompiled=!1,_.type!=="custom"&&(this.metadata=(_=_).metadata,this.minzoom=_.minzoom,this.maxzoom=_.maxzoom,_.type!=="background"&&_.type!=="sky"&&(this.source=_.source,this.sourceLayer=_["source-layer"],this.filter=_.filter),k.layout&&(this._unevaluatedLayout=new it(k.layout)),k.paint)){this._transitionablePaint=new Ee(k.paint);for(const X in _.paint)this.setPaintProperty(X,_.paint[X],{validate:!1});for(const X in _.layout)this.setLayoutProperty(X,_.layout[X],{validate:!1});this._transitioningPaint=this._transitionablePaint.untransitioned(),this.paint=new Dt(k.paint)}}getCrossfadeParameters(){return this._crossfadeParameters}getLayoutProperty(_){return _==="visibility"?this.visibility:this._unevaluatedLayout.getValue(_)}setLayoutProperty(_,k,X={}){k!=null&&this._validate(Wf,`layers.${this.id}.layout.${_}`,_,k,X)||(_!=="visibility"?this._unevaluatedLayout.setValue(_,k):this.visibility=k)}getPaintProperty(_){return _n(_,Pc)?this._transitionablePaint.getTransition(_.slice(0,-Pc.length)):this._transitionablePaint.getValue(_)}setPaintProperty(_,k,X={}){if(k!=null&&this._validate(nf,`layers.${this.id}.paint.${_}`,_,k,X))return!1;if(_n(_,Pc))return this._transitionablePaint.setTransition(_.slice(0,-Pc.length),k||void 0),!1;{const de=this._transitionablePaint._values[_],Ge=de.property.specification["property-type"]==="cross-faded-data-driven",ft=de.value.isDataDriven(),_t=de.value;this._transitionablePaint.setValue(_,k),this._handleSpecialPaintPropertyUpdate(_);const At=this._transitionablePaint._values[_].value;return At.isDataDriven()||ft||Ge||this._handleOverridablePaintPropertyUpdate(_,_t,At)}}_handleSpecialPaintPropertyUpdate(_){}getProgramIds(){return null}getProgramConfiguration(_){return null}_handleOverridablePaintPropertyUpdate(_,k,X){return!1}isHidden(_){return!!(this.minzoom&&_<this.minzoom)||!!(this.maxzoom&&_>=this.maxzoom)||this.visibility==="none"}updateTransitions(_){this._transitioningPaint=this._transitionablePaint.transitioned(_,this._transitioningPaint)}hasTransition(){return this._transitioningPaint.hasTransition()}recalculate(_,k){_.getCrossfadeParameters&&(this._crossfadeParameters=_.getCrossfadeParameters()),this._unevaluatedLayout&&(this.layout=this._unevaluatedLayout.possiblyEvaluate(_,void 0,k)),this.paint=this._transitioningPaint.possiblyEvaluate(_,void 0,k)}serialize(){const _={id:this.id,type:this.type,source:this.source,"source-layer":this.sourceLayer,metadata:this.metadata,minzoom:this.minzoom,maxzoom:this.maxzoom,filter:this.filter,layout:this._unevaluatedLayout&&this._unevaluatedLayout.serialize(),paint:this._transitionablePaint&&this._transitionablePaint.serialize()};return this.visibility&&(_.layout=_.layout||{},_.layout.visibility=this.visibility),an(_,(k,X)=>!(k===void 0||X==="layout"&&!Object.keys(k).length||X==="paint"&&!Object.keys(k).length))}_validate(_,k,X,de,Ge={}){return(!Ge||Ge.validate!==!1)&&Sf(this,_.call(Od,{key:k,layerType:this.type,objectKey:X,value:de,styleSpec:ma,style:{glyphs:!0,sprite:!0}}))}is3D(){return!1}isSky(){return!1}isTileClipped(){return!1}hasOffscreenPass(){return!1}resize(){}isStateDependent(){for(const _ in this.paint._values){const k=this.paint.get(_);if(k instanceof xt&&qc(k.property.specification)&&(k.value.kind==="source"||k.value.kind==="composite")&&k.value.isStateDependent)return!0}return!1}compileFilter(){this._filterCompiled||(this._featureFilter=Gl(this.filter),this._filterCompiled=!0)}invalidateCompiledFilter(){this._filterCompiled=!1}dynamicFilter(){return this._featureFilter.dynamicFilter}dynamicFilterNeedsFeature(){return this._featureFilter.needFeature}}const E3=Di([{name:"a_pos",components:2,type:"Int16"}],4),Q3=Di([{name:"a_pos_3",components:3,type:"Int16"},{name:"a_pos_normal_3",components:3,type:"Int16"},{name:"a_scale",components:1,type:"Float32"}]);class hc{constructor(_=[]){this.segments=_}prepareSegment(_,k,X,de){let Ge=this.segments[this.segments.length-1];return _>hc.MAX_VERTEX_ARRAY_LENGTH&&wn(`Max vertices per segment is ${hc.MAX_VERTEX_ARRAY_LENGTH}: bucket requested ${_}`),(!Ge||Ge.vertexLength+_>hc.MAX_VERTEX_ARRAY_LENGTH||Ge.sortKey!==de)&&(Ge={vertexOffset:k.length,primitiveOffset:X.length,vertexLength:0,primitiveLength:0},de!==void 0&&(Ge.sortKey=de),this.segments.push(Ge)),Ge}get(){return this.segments}destroy(){for(const _ of this.segments)for(const k in _.vaos)_.vaos[k].destroy()}static simpleSegment(_,k,X,de){return new hc([{vertexOffset:_,primitiveOffset:k,vertexLength:X,primitiveLength:de,vaos:{},sortKey:0}])}}hc.MAX_VERTEX_ARRAY_LENGTH=Math.pow(2,16)-1,Zo(hc,"SegmentVector");var Ml=8192;class Hc{constructor(_,k){_&&(k?this.setSouthWest(_).setNorthEast(k):_.length===4?this.setSouthWest([_[0],_[1]]).setNorthEast([_[2],_[3]]):this.setSouthWest(_[0]).setNorthEast(_[1]))}setNorthEast(_){return this._ne=_ instanceof _u?new _u(_.lng,_.lat):_u.convert(_),this}setSouthWest(_){return this._sw=_ instanceof _u?new _u(_.lng,_.lat):_u.convert(_),this}extend(_){const k=this._sw,X=this._ne;let de,Ge;if(_ instanceof _u)de=_,Ge=_;else{if(!(_ instanceof Hc))return Array.isArray(_)?_.length===4||_.every(Array.isArray)?this.extend(Hc.convert(_)):this.extend(_u.convert(_)):this;if(de=_._sw,Ge=_._ne,!de||!Ge)return this}return k||X?(k.lng=Math.min(de.lng,k.lng),k.lat=Math.min(de.lat,k.lat),X.lng=Math.max(Ge.lng,X.lng),X.lat=Math.max(Ge.lat,X.lat)):(this._sw=new _u(de.lng,de.lat),this._ne=new _u(Ge.lng,Ge.lat)),this}getCenter(){return new _u((this._sw.lng+this._ne.lng)/2,(this._sw.lat+this._ne.lat)/2)}getSouthWest(){return this._sw}getNorthEast(){return this._ne}getNorthWest(){return new _u(this.getWest(),this.getNorth())}getSouthEast(){return new _u(this.getEast(),this.getSouth())}getWest(){return this._sw.lng}getSouth(){return this._sw.lat}getEast(){return this._ne.lng}getNorth(){return this._ne.lat}toArray(){return[this._sw.toArray(),this._ne.toArray()]}toString(){return`LngLatBounds(${this._sw.toString()}, ${this._ne.toString()})`}isEmpty(){return!(this._sw&&this._ne)}contains(_){const{lng:k,lat:X}=_u.convert(_);let de=this._sw.lng<=k&&k<=this._ne.lng;return this._sw.lng>this._ne.lng&&(de=this._sw.lng>=k&&k>=this._ne.lng),this._sw.lat<=X&&X<=this._ne.lat&&de}static convert(_){return!_||_ instanceof Hc?_:new Hc(_)}}const tm=63710088e-1;class _u{constructor(_,k){if(isNaN(_)||isNaN(k))throw new Error(`Invalid LngLat object: (${_}, ${k})`);if(this.lng=+_,this.lat=+k,this.lat>90||this.lat<-90)throw new Error("Invalid LngLat latitude value: must be between -90 and 90")}wrap(){return new _u(ie(this.lng,-180,180),this.lat)}toArray(){return[this.lng,this.lat]}toString(){return`LngLat(${this.lng}, ${this.lat})`}distanceTo(_){const k=Math.PI/180,X=this.lat*k,de=_.lat*k,Ge=Math.sin(X)*Math.sin(de)+Math.cos(X)*Math.cos(de)*Math.cos((_.lng-this.lng)*k);return tm*Math.acos(Math.min(Ge,1))}toBounds(_=0){const k=360*_/40075017,X=k/Math.cos(Math.PI/180*this.lat);return new Hc(new _u(this.lng-X,this.lat-k),new _u(this.lng+X,this.lat+k))}static convert(_){if(_ instanceof _u)return _;if(Array.isArray(_)&&(_.length===2||_.length===3))return new _u(Number(_[0]),Number(_[1]));if(!Array.isArray(_)&&typeof _=="object"&&_!==null)return new _u(Number("lng"in _?_.lng:_.lon),Number(_.lat));throw new Error("`LngLatLike` argument must be specified as a LngLat instance, an object {lng: <lng>, lat: <lat>}, an object {lon: <lng>, lat: <lat>}, or an array of [<lng>, <lat>]")}}const xc=2*Math.PI*tm;function Pf(D){return xc*Math.cos(D*Math.PI/180)}function ch(D){return(180+D)/360}function $p(D){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+D*Math.PI/360)))/360}function Hp(D,_){return D/Pf(_)}function Wd(D){return 360*D-180}function ed(D){return 360/Math.PI*Math.atan(Math.exp((180-360*D)*Math.PI/180))-90}function If(D,_){return D*Pf(ed(_))}const Jd=85.051129;class Wp{constructor(_,k,X=0){this.x=+_,this.y=+k,this.z=+X}static fromLngLat(_,k=0){const X=_u.convert(_);return new Wp(ch(X.lng),$p(X.lat),Hp(k,X.lat))}toLngLat(){return new _u(Wd(this.x),ed(this.y))}toAltitude(){return If(this.z,this.y)}meterInMercatorCoordinateUnits(){return 1/xc*(_=ed(this.y),1/Math.cos(_*Math.PI/180));var _}}function nm(D,_,k,X,de,Ge,ft,_t,At){const Nt=(_+X)/2,cn=(k+de)/2,vn=new G(Nt,cn);_t(vn),function(bn,jn,Zn,Br,Jr,si){const Li=Zn-Jr,vi=Br-si;return Math.abs((Br-jn)*Li-(Zn-bn)*vi)/Math.hypot(Li,vi)}(vn.x,vn.y,Ge.x,Ge.y,ft.x,ft.y)>=At?(nm(D,_,k,Nt,cn,Ge,vn,_t,At),nm(D,Nt,cn,X,de,vn,ft,_t,At)):D.push(ft)}function Nm(D,_,k){let X=D[0],de=X.x,Ge=X.y;_(X);const ft=[X];for(let _t=1;_t<D.length;_t++){const At=D[_t],{x:Nt,y:cn}=At;_(At),nm(ft,de,Ge,Nt,cn,X,At,_,k),de=Nt,Ge=cn,X=At}return ft}const rm=Math.pow(2,14)-1,im=-rm-1;function dh(D,_){const k=Math.round(D.x*_),X=Math.round(D.y*_);return D.x=Te(k,im,rm),D.y=Te(X,im,rm),(k<D.x||k>D.x+1||X<D.y||X>D.y+1)&&wn("Geometry exceeds allowed extent, reduce your vector tile buffer size"),D}function bh(D,_,k){const X=D.loadGeometry(),de=D.extent,Ge=Ml/de;if(_&&k&&k.projection.isReprojectedInTileSpace){const ft=1<<_.z,{scale:_t,x:At,y:Nt,projection:cn}=k,vn=bn=>{const jn=Wd((_.x+bn.x/de)/ft),Zn=ed((_.y+bn.y/de)/ft),Br=cn.project(jn,Zn);bn.x=(Br.x*_t-At)*de,bn.y=(Br.y*_t-Nt)*de};for(let bn=0;bn<X.length;bn++)if(D.type!==1)X[bn]=Nm(X[bn],vn,1);else{const jn=[];for(const Zn of X[bn])Zn.x<0||Zn.x>=de||Zn.y<0||Zn.y>=de||(vn(Zn),jn.push(Zn));X[bn]=jn}}for(const ft of X)for(const _t of ft)dh(_t,Ge);return X}function vp(D,_){return{type:D.type,id:D.id,properties:D.properties,geometry:_?bh(D):[]}}function Yc(D,_,k,X,de){D.emplaceBack(2*_+(X+1)/2,2*k+(de+1)/2)}function kl(D,_,k,X){D.emplaceBack(_.x,_.y,_.z,k[0]*16384,k[1]*16384,k[2]*16384,X)}class Rf{constructor(_){this.zoom=_.zoom,this.overscaling=_.overscaling,this.layers=_.layers,this.layerIds=this.layers.map(k=>k.id),this.index=_.index,this.hasPattern=!1,this.projection=_.projection,this.layoutVertexArray=new wi,this.indexArray=new rs,this.segments=new hc,this.programConfigurations=new Up(_.layers,_.zoom),this.stateDependentLayerIds=this.layers.filter(k=>k.isStateDependent()).map(k=>k.id)}populate(_,k,X,de){const Ge=this.layers[0],ft=[];let _t=null;Ge.type==="circle"&&(_t=Ge.layout.get("circle-sort-key"));for(const{feature:Nt,id:cn,index:vn,sourceLayerIndex:bn}of _){const jn=this.layers[0]._featureFilter.needGeometry,Zn=vp(Nt,jn);if(!this.layers[0]._featureFilter.filter(new Iu(this.zoom),Zn,X))continue;const Br=_t?_t.evaluate(Zn,{},X):void 0,Jr={id:cn,properties:Nt.properties,type:Nt.type,sourceLayerIndex:bn,index:vn,geometry:jn?Zn.geometry:bh(Nt,X,de),patterns:{},sortKey:Br};ft.push(Jr)}_t&&ft.sort((Nt,cn)=>Nt.sortKey-cn.sortKey);let At=null;de.projection.name==="globe"&&(this.globeExtVertexArray=new lh,At=de.projection);for(const Nt of ft){const{geometry:cn,index:vn,sourceLayerIndex:bn}=Nt,jn=_[vn].feature;this.addFeature(Nt,cn,vn,k.availableImages,X,At),k.featureIndex.insert(jn,cn,vn,bn,this.index)}}update(_,k,X,de){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(_,k,this.stateDependentLayers,X,de)}isEmpty(){return this.layoutVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(_){this.uploaded||(this.layoutVertexBuffer=_.createVertexBuffer(this.layoutVertexArray,E3.members),this.indexBuffer=_.createIndexBuffer(this.indexArray),this.globeExtVertexArray&&(this.globeExtVertexBuffer=_.createVertexBuffer(this.globeExtVertexArray,Q3.members))),this.programConfigurations.upload(_),this.uploaded=!0}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy(),this.globeExtVertexBuffer&&this.globeExtVertexBuffer.destroy())}addFeature(_,k,X,de,Ge,ft){for(const _t of k)for(const At of _t){const Nt=At.x,cn=At.y;if(Nt<0||Nt>=Ml||cn<0||cn>=Ml)continue;if(ft){const jn=ft.projectTilePoint(Nt,cn,Ge),Zn=ft.upVector(Ge,Nt,cn),Br=ed((cn/Ml+Ge.y)/(1<<Ge.z)),Jr=ft.pixelsPerMeter(Br,1)/Hp(1,Br),si=this.globeExtVertexArray;kl(si,jn,Zn,Jr),kl(si,jn,Zn,Jr),kl(si,jn,Zn,Jr),kl(si,jn,Zn,Jr)}const vn=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray,_.sortKey),bn=vn.vertexLength;Yc(this.layoutVertexArray,Nt,cn,-1,-1),Yc(this.layoutVertexArray,Nt,cn,1,-1),Yc(this.layoutVertexArray,Nt,cn,1,1),Yc(this.layoutVertexArray,Nt,cn,-1,1),this.indexArray.emplaceBack(bn,bn+1,bn+2),this.indexArray.emplaceBack(bn,bn+3,bn+2),vn.vertexLength+=4,vn.primitiveLength+=2}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,_,X,{},de,Ge)}}function Md(D,_){for(let k=0;k<D.length;k++)if($u(_,D[k]))return!0;for(let k=0;k<_.length;k++)if($u(D,_[k]))return!0;return!!hf(D,_)}function Dc(D,_,k){return!!$u(D,_)||!!Of(_,D,k)}function zh(D,_){if(D.length===1)return bc(_,D[0]);for(let k=0;k<_.length;k++){const X=_[k];for(let de=0;de<X.length;de++)if($u(D,X[de]))return!0}for(let k=0;k<D.length;k++)if(bc(_,D[k]))return!0;for(let k=0;k<_.length;k++)if(hf(D,_[k]))return!0;return!1}function zm(D,_,k){if(D.length>1){if(hf(D,_))return!0;for(let X=0;X<_.length;X++)if(Of(_[X],D,k))return!0}for(let X=0;X<D.length;X++)if(Of(D[X],_,k))return!0;return!1}function hf(D,_){if(D.length===0||_.length===0)return!1;for(let k=0;k<D.length-1;k++){const X=D[k],de=D[k+1];for(let Ge=0;Ge<_.length-1;Ge++)if(wh(X,de,_[Ge],_[Ge+1]))return!0}return!1}function wh(D,_,k,X){return hn(D,k,X)!==hn(_,k,X)&&hn(D,_,k)!==hn(D,_,X)}function Of(D,_,k){const X=k*k;if(_.length===1)return D.distSqr(_[0])<X;for(let de=1;de<_.length;de++)if(qp(D,_[de-1],_[de])<X)return!0;return!1}function qp(D,_,k){const X=_.distSqr(k);if(X===0)return D.distSqr(_);const de=((D.x-_.x)*(k.x-_.x)+(D.y-_.y)*(k.y-_.y))/X;return D.distSqr(de<0?_:de>1?k:k.sub(_)._mult(de)._add(_))}function bc(D,_){let k,X,de,Ge=!1;for(let ft=0;ft<D.length;ft++){k=D[ft];for(let _t=0,At=k.length-1;_t<k.length;At=_t++)X=k[_t],de=k[At],X.y>_.y!=de.y>_.y&&_.x<(de.x-X.x)*(_.y-X.y)/(de.y-X.y)+X.x&&(Ge=!Ge)}return Ge}function $u(D,_){let k=!1;for(let X=0,de=D.length-1;X<D.length;de=X++){const Ge=D[X],ft=D[de];Ge.y>_.y!=ft.y>_.y&&_.x<(ft.x-Ge.x)*(_.y-Ge.y)/(ft.y-Ge.y)+Ge.x&&(k=!k)}return k}function am(D,_,k,X,de){for(const ft of D)if(_<=ft.x&&k<=ft.y&&X>=ft.x&&de>=ft.y)return!0;const Ge=[new G(_,k),new G(_,de),new G(X,de),new G(X,k)];if(D.length>2){for(const ft of Ge)if($u(D,ft))return!0}for(let ft=0;ft<D.length-1;ft++)if(om(D[ft],D[ft+1],Ge))return!0;return!1}function om(D,_,k){const X=k[0],de=k[2];if(D.x<X.x&&_.x<X.x||D.x>de.x&&_.x>de.x||D.y<X.y&&_.y<X.y||D.y>de.y&&_.y>de.y)return!1;const Ge=hn(D,_,k[0]);return Ge!==hn(D,_,k[1])||Ge!==hn(D,_,k[2])||Ge!==hn(D,_,k[3])}function rp(D,_,k){const X=_.paint.get(D).value;return X.kind==="constant"?X.value:k.programConfigurations.get(_.id).getMaxValue(D)}function _p(D){return Math.sqrt(D[0]*D[0]+D[1]*D[1])}function Lf(D,_,k,X,de){if(!_[0]&&!_[1])return D;const Ge=G.convert(_)._mult(de);k==="viewport"&&Ge._rotate(-X);const ft=[];for(let _t=0;_t<D.length;_t++)ft.push(D[_t].sub(Ge));return ft}function jm(D,_,k,X){const de=G.convert(D)._mult(X);return _==="viewport"&&de._rotate(-k),de}Zo(Rf,"CircleBucket",{omit:["layers"]});const Mh=new Wn({"circle-sort-key":new rn(ma.layout_circle["circle-sort-key"])});var sm={paint:new Wn({"circle-radius":new rn(ma.paint_circle["circle-radius"]),"circle-color":new rn(ma.paint_circle["circle-color"]),"circle-blur":new rn(ma.paint_circle["circle-blur"]),"circle-opacity":new rn(ma.paint_circle["circle-opacity"]),"circle-translate":new Ot(ma.paint_circle["circle-translate"]),"circle-translate-anchor":new Ot(ma.paint_circle["circle-translate-anchor"]),"circle-pitch-scale":new Ot(ma.paint_circle["circle-pitch-scale"]),"circle-pitch-alignment":new Ot(ma.paint_circle["circle-pitch-alignment"]),"circle-stroke-width":new rn(ma.paint_circle["circle-stroke-width"]),"circle-stroke-color":new rn(ma.paint_circle["circle-stroke-color"]),"circle-stroke-opacity":new rn(ma.paint_circle["circle-stroke-opacity"])}),layout:Mh},A3=1e-6,hh=typeof Float32Array<"u"?Float32Array:Array;function k3(){var D=new hh(9);return hh!=Float32Array&&(D[1]=0,D[2]=0,D[3]=0,D[5]=0,D[6]=0,D[7]=0),D[0]=1,D[4]=1,D[8]=1,D}function ld(D){return D[0]=1,D[1]=0,D[2]=0,D[3]=0,D[4]=0,D[5]=1,D[6]=0,D[7]=0,D[8]=0,D[9]=0,D[10]=1,D[11]=0,D[12]=0,D[13]=0,D[14]=0,D[15]=1,D}function Zl(D,_,k){var X=_[0],de=_[1],Ge=_[2],ft=_[3],_t=_[4],At=_[5],Nt=_[6],cn=_[7],vn=_[8],bn=_[9],jn=_[10],Zn=_[11],Br=_[12],Jr=_[13],si=_[14],Li=_[15],vi=k[0],ui=k[1],ua=k[2],ba=k[3];return D[0]=vi*X+ui*_t+ua*vn+ba*Br,D[1]=vi*de+ui*At+ua*bn+ba*Jr,D[2]=vi*Ge+ui*Nt+ua*jn+ba*si,D[3]=vi*ft+ui*cn+ua*Zn+ba*Li,D[4]=(vi=k[4])*X+(ui=k[5])*_t+(ua=k[6])*vn+(ba=k[7])*Br,D[5]=vi*de+ui*At+ua*bn+ba*Jr,D[6]=vi*Ge+ui*Nt+ua*jn+ba*si,D[7]=vi*ft+ui*cn+ua*Zn+ba*Li,D[8]=(vi=k[8])*X+(ui=k[9])*_t+(ua=k[10])*vn+(ba=k[11])*Br,D[9]=vi*de+ui*At+ua*bn+ba*Jr,D[10]=vi*Ge+ui*Nt+ua*jn+ba*si,D[11]=vi*ft+ui*cn+ua*Zn+ba*Li,D[12]=(vi=k[12])*X+(ui=k[13])*_t+(ua=k[14])*vn+(ba=k[15])*Br,D[13]=vi*de+ui*At+ua*bn+ba*Jr,D[14]=vi*Ge+ui*Nt+ua*jn+ba*si,D[15]=vi*ft+ui*cn+ua*Zn+ba*Li,D}function Ch(D,_,k){var X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn,Br=k[0],Jr=k[1],si=k[2];return _===D?(D[12]=_[0]*Br+_[4]*Jr+_[8]*si+_[12],D[13]=_[1]*Br+_[5]*Jr+_[9]*si+_[13],D[14]=_[2]*Br+_[6]*Jr+_[10]*si+_[14],D[15]=_[3]*Br+_[7]*Jr+_[11]*si+_[15]):(de=_[1],Ge=_[2],ft=_[3],_t=_[4],At=_[5],Nt=_[6],cn=_[7],vn=_[8],bn=_[9],jn=_[10],Zn=_[11],D[0]=X=_[0],D[1]=de,D[2]=Ge,D[3]=ft,D[4]=_t,D[5]=At,D[6]=Nt,D[7]=cn,D[8]=vn,D[9]=bn,D[10]=jn,D[11]=Zn,D[12]=X*Br+_t*Jr+vn*si+_[12],D[13]=de*Br+At*Jr+bn*si+_[13],D[14]=Ge*Br+Nt*Jr+jn*si+_[14],D[15]=ft*Br+cn*Jr+Zn*si+_[15]),D}function Cu(D,_,k){var X=k[0],de=k[1],Ge=k[2];return D[0]=_[0]*X,D[1]=_[1]*X,D[2]=_[2]*X,D[3]=_[3]*X,D[4]=_[4]*de,D[5]=_[5]*de,D[6]=_[6]*de,D[7]=_[7]*de,D[8]=_[8]*Ge,D[9]=_[9]*Ge,D[10]=_[10]*Ge,D[11]=_[11]*Ge,D[12]=_[12],D[13]=_[13],D[14]=_[14],D[15]=_[15],D}function xp(D,_,k){var X=Math.sin(k),de=Math.cos(k),Ge=_[4],ft=_[5],_t=_[6],At=_[7],Nt=_[8],cn=_[9],vn=_[10],bn=_[11];return _!==D&&(D[0]=_[0],D[1]=_[1],D[2]=_[2],D[3]=_[3],D[12]=_[12],D[13]=_[13],D[14]=_[14],D[15]=_[15]),D[4]=Ge*de+Nt*X,D[5]=ft*de+cn*X,D[6]=_t*de+vn*X,D[7]=At*de+bn*X,D[8]=Nt*de-Ge*X,D[9]=cn*de-ft*X,D[10]=vn*de-_t*X,D[11]=bn*de-At*X,D}function Ru(D,_,k){var X=Math.sin(k),de=Math.cos(k),Ge=_[0],ft=_[1],_t=_[2],At=_[3],Nt=_[8],cn=_[9],vn=_[10],bn=_[11];return _!==D&&(D[4]=_[4],D[5]=_[5],D[6]=_[6],D[7]=_[7],D[12]=_[12],D[13]=_[13],D[14]=_[14],D[15]=_[15]),D[0]=Ge*de-Nt*X,D[1]=ft*de-cn*X,D[2]=_t*de-vn*X,D[3]=At*de-bn*X,D[8]=Ge*X+Nt*de,D[9]=ft*X+cn*de,D[10]=_t*X+vn*de,D[11]=At*X+bn*de,D}Math.hypot||(Math.hypot=function(){for(var D=0,_=arguments.length;_--;)D+=arguments[_]*arguments[_];return Math.sqrt(D)});var Gm=Zl;function Um(){var D=new hh(3);return hh!=Float32Array&&(D[0]=0,D[1]=0,D[2]=0),D}function lm(D){var _=new hh(3);return _[0]=D[0],_[1]=D[1],_[2]=D[2],_}function um(D){return Math.hypot(D[0],D[1],D[2])}function Ff(D,_,k){var X=new hh(3);return X[0]=D,X[1]=_,X[2]=k,X}function bp(D,_,k){return D[0]=_[0]+k[0],D[1]=_[1]+k[1],D[2]=_[2]+k[2],D}function P3(D,_,k){return D[0]=_[0]-k[0],D[1]=_[1]-k[1],D[2]=_[2]-k[2],D}function $m(D,_,k){return D[0]=_[0]*k[0],D[1]=_[1]*k[1],D[2]=_[2]*k[2],D}function Yp(D,_,k){return D[0]=Math.min(_[0],k[0]),D[1]=Math.min(_[1],k[1]),D[2]=Math.min(_[2],k[2]),D}function wp(D,_,k){return D[0]=Math.max(_[0],k[0]),D[1]=Math.max(_[1],k[1]),D[2]=Math.max(_[2],k[2]),D}function Hm(D,_,k){return D[0]=_[0]*k,D[1]=_[1]*k,D[2]=_[2]*k,D}function c3(D,_,k,X){return D[0]=_[0]+k[0]*X,D[1]=_[1]+k[1]*X,D[2]=_[2]+k[2]*X,D}function Ic(D,_){var k=_[0],X=_[1],de=_[2],Ge=k*k+X*X+de*de;return Ge>0&&(Ge=1/Math.sqrt(Ge)),D[0]=_[0]*Ge,D[1]=_[1]*Ge,D[2]=_[2]*Ge,D}function Zc(D,_){return D[0]*_[0]+D[1]*_[1]+D[2]*_[2]}function Wm(D,_,k){var X=_[0],de=_[1],Ge=_[2],ft=k[0],_t=k[1],At=k[2];return D[0]=de*At-Ge*_t,D[1]=Ge*ft-X*At,D[2]=X*_t-de*ft,D}function Sh(D,_,k){var X=_[0],de=_[1],Ge=_[2],ft=k[3]*X+k[7]*de+k[11]*Ge+k[15];return D[0]=(k[0]*X+k[4]*de+k[8]*Ge+k[12])/(ft=ft||1),D[1]=(k[1]*X+k[5]*de+k[9]*Ge+k[13])/ft,D[2]=(k[2]*X+k[6]*de+k[10]*Ge+k[14])/ft,D}function qm(D,_,k){var X=k[0],de=k[1],Ge=k[2],ft=_[0],_t=_[1],At=_[2],Nt=de*At-Ge*_t,cn=Ge*ft-X*At,vn=X*_t-de*ft,bn=de*vn-Ge*cn,jn=Ge*Nt-X*vn,Zn=X*cn-de*Nt,Br=2*k[3];return cn*=Br,vn*=Br,jn*=2,Zn*=2,D[0]=ft+(Nt*=Br)+(bn*=2),D[1]=_t+cn+jn,D[2]=At+vn+Zn,D}var Zp,Mp=P3,cm=$m,dm=um;function Qd(D,_,k){var X=_[0],de=_[1],Ge=_[2],ft=_[3];return D[0]=k[0]*X+k[4]*de+k[8]*Ge+k[12]*ft,D[1]=k[1]*X+k[5]*de+k[9]*Ge+k[13]*ft,D[2]=k[2]*X+k[6]*de+k[10]*Ge+k[14]*ft,D[3]=k[3]*X+k[7]*de+k[11]*Ge+k[15]*ft,D}function I3(){var D=new hh(4);return hh!=Float32Array&&(D[0]=0,D[1]=0,D[2]=0),D[3]=1,D}function Bf(D){return D[0]=0,D[1]=0,D[2]=0,D[3]=1,D}function pf(D,_,k){k*=.5;var X=_[0],de=_[1],Ge=_[2],ft=_[3],_t=Math.sin(k),At=Math.cos(k);return D[0]=X*At+ft*_t,D[1]=de*At+Ge*_t,D[2]=Ge*At-de*_t,D[3]=ft*At-X*_t,D}Um(),Zp=new hh(4),hh!=Float32Array&&(Zp[0]=0,Zp[1]=0,Zp[2]=0,Zp[3]=0),Um(),Ff(1,0,0),Ff(0,1,0),I3(),I3(),k3();class Cp{constructor(_,k){this.points=_,this.planes=k}static fromInvProjectionMatrix(_,k,X,de){const Ge=Math.pow(2,X),ft=[[-1,1,-1,1],[1,1,-1,1],[1,-1,-1,1],[-1,-1,-1,1],[-1,1,1,1],[1,1,1,1],[1,-1,1,1],[-1,-1,1,1]].map(At=>{const Nt=Qd([],At,_),cn=1/Nt[3]/k*Ge;return function(vn,bn,jn){return vn[0]=bn[0]*jn[0],vn[1]=bn[1]*jn[1],vn[2]=bn[2]*jn[2],vn[3]=bn[3]*jn[3],vn}(Nt,Nt,[cn,cn,de?1/Nt[3]:cn,cn])}),_t=[[0,1,2],[6,5,4],[0,3,7],[2,1,5],[3,2,6],[0,4,5]].map(At=>{const Nt=Ic([],Wm([],Mp([],ft[At[0]],ft[At[1]]),Mp([],ft[At[2]],ft[At[1]]))),cn=-Zc(Nt,ft[At[1]]);return Nt.concat(cn)});return new Cp(ft,_t)}}class qd{constructor(_,k){this.min=_,this.max=k,this.center=Hm([],bp([],this.min,this.max),.5)}quadrant(_){const k=[_%2==0,_<2],X=lm(this.min),de=lm(this.max);for(let Ge=0;Ge<k.length;Ge++)X[Ge]=k[Ge]?this.min[Ge]:this.center[Ge],de[Ge]=k[Ge]?this.center[Ge]:this.max[Ge];return de[2]=this.max[2],new qd(X,de)}distanceX(_){return Math.max(Math.min(this.max[0],_[0]),this.min[0])-_[0]}distanceY(_){return Math.max(Math.min(this.max[1],_[1]),this.min[1])-_[1]}distanceZ(_){return Math.max(Math.min(this.max[2],_[2]),this.min[2])-_[2]}getCorners(){const _=this.min,k=this.max;return[[_[0],_[1],_[2]],[k[0],_[1],_[2]],[k[0],k[1],_[2]],[_[0],k[1],_[2]],[_[0],_[1],k[2]],[k[0],_[1],k[2]],[k[0],k[1],k[2]],[_[0],k[1],k[2]]]}intersects(_){const k=this.getCorners();let X=!0;for(let de=0;de<_.planes.length;de++){const Ge=_.planes[de];let ft=0;for(let _t=0;_t<k.length;_t++)ft+=Zc(Ge,k[_t])+Ge[3]>=0;if(ft===0)return 0;ft!==k.length&&(X=!1)}if(X)return 2;for(let de=0;de<3;de++){let Ge=Number.MAX_VALUE,ft=-Number.MAX_VALUE;for(let _t=0;_t<_.points.length;_t++){const At=_.points[_t][de]-this.min[de];Ge=Math.min(Ge,At),ft=Math.max(ft,At)}if(ft<0||Ge>this.max[de]-this.min[de])return 0}return 1}}function Ym(D,_,k,X,de,Ge,ft,_t,At){if(Ge&&D.queryGeometry.isAboveHorizon)return!1;Ge&&(At*=D.pixelToTileUnitsFactor);for(const Nt of _)for(const cn of Nt){const vn=cn.add(_t),bn=de&&k.elevation?k.elevation.exaggeration()*de.getElevationAt(vn.x,vn.y,!0):0,jn=Ge?vn:d3(vn,bn,X),Zn=Ge?D.tilespaceRays.map(Jr=>Vf(Jr,bn)):D.queryGeometry.screenGeometry,Br=Qd([],[cn.x,cn.y,bn,1],X);if(!ft&&Ge?At*=Br[3]/k.cameraToCenterDistance:ft&&!Ge&&(At*=k.cameraToCenterDistance/Br[3]),Dc(Zn,jn,At))return!0}return!1}function d3(D,_,k){const X=Qd([],[D.x,D.y,_,1],k);return new G(X[0]/X[3],X[1]/X[3])}const hm=Ff(0,0,0),eh=Ff(0,0,1);function Vf(D,_){const k=Um();return hm[2]=_,D.intersectsPlane(hm,eh,k),new G(k[0],k[1])}class Kp extends Rf{}function Sp(D,{width:_,height:k},X,de){if(de){if(de instanceof Uint8ClampedArray)de=new Uint8Array(de.buffer);else if(de.length!==_*k*X)throw new RangeError("mismatched image size")}else de=new Uint8Array(_*k*X);return D.width=_,D.height=k,D.data=de,D}function pm(D,_,k){const{width:X,height:de}=_;X===D.width&&de===D.height||(Tp(D,_,{x:0,y:0},{x:0,y:0},{width:Math.min(D.width,X),height:Math.min(D.height,de)},k),D.width=X,D.height=de,D.data=_.data)}function Tp(D,_,k,X,de,Ge){if(de.width===0||de.height===0)return _;if(de.width>D.width||de.height>D.height||k.x>D.width-de.width||k.y>D.height-de.height)throw new RangeError("out of range source coordinates for image copy");if(de.width>_.width||de.height>_.height||X.x>_.width-de.width||X.y>_.height-de.height)throw new RangeError("out of range destination coordinates for image copy");const ft=D.data,_t=_.data;for(let At=0;At<de.height;At++){const Nt=((k.y+At)*D.width+k.x)*Ge,cn=((X.y+At)*_.width+X.x)*Ge;for(let vn=0;vn<de.width*Ge;vn++)_t[cn+vn]=ft[Nt+vn]}return _}Zo(Kp,"HeatmapBucket",{omit:["layers"]});class Th{constructor(_,k){Sp(this,_,1,k)}resize(_){pm(this,new Th(_),1)}clone(){return new Th({width:this.width,height:this.height},new Uint8Array(this.data))}static copy(_,k,X,de,Ge){Tp(_,k,X,de,Ge,1)}}class Cd{constructor(_,k){Sp(this,_,4,k)}resize(_){pm(this,new Cd(_),4)}replace(_,k){k?this.data.set(_):this.data=_ instanceof Uint8ClampedArray?new Uint8Array(_.buffer):_}clone(){return new Cd({width:this.width,height:this.height},new Uint8Array(this.data))}static copy(_,k,X,de,Ge){Tp(_,k,X,de,Ge,4)}}Zo(Th,"AlphaImage"),Zo(Cd,"RGBAImage");var Sd={paint:new Wn({"heatmap-radius":new rn(ma.paint_heatmap["heatmap-radius"]),"heatmap-weight":new rn(ma.paint_heatmap["heatmap-weight"]),"heatmap-intensity":new Ot(ma.paint_heatmap["heatmap-intensity"]),"heatmap-color":new Bn(ma.paint_heatmap["heatmap-color"]),"heatmap-opacity":new Ot(ma.paint_heatmap["heatmap-opacity"])})};function Xp(D){const _={},k=D.resolution||256,X=D.clips?D.clips.length:1,de=D.image||new Cd({width:k,height:X}),Ge=(ft,_t,At)=>{_[D.evaluationKey]=At;const Nt=D.expression.evaluate(_);de.data[ft+_t+0]=Math.floor(255*Nt.r/Nt.a),de.data[ft+_t+1]=Math.floor(255*Nt.g/Nt.a),de.data[ft+_t+2]=Math.floor(255*Nt.b/Nt.a),de.data[ft+_t+3]=Math.floor(255*Nt.a)};if(D.clips)for(let ft=0,_t=0;ft<X;++ft,_t+=4*k)for(let At=0,Nt=0;At<k;At++,Nt+=4){const cn=At/(k-1),{start:vn,end:bn}=D.clips[ft];Ge(_t,Nt,vn*(1-cn)+bn*cn)}else for(let ft=0,_t=0;ft<k;ft++,_t+=4)Ge(0,_t,ft/(k-1));return de}var Zm={paint:new Wn({"hillshade-illumination-direction":new Ot(ma.paint_hillshade["hillshade-illumination-direction"]),"hillshade-illumination-anchor":new Ot(ma.paint_hillshade["hillshade-illumination-anchor"]),"hillshade-exaggeration":new Ot(ma.paint_hillshade["hillshade-exaggeration"]),"hillshade-shadow-color":new Ot(ma.paint_hillshade["hillshade-shadow-color"]),"hillshade-highlight-color":new Ot(ma.paint_hillshade["hillshade-highlight-color"]),"hillshade-accent-color":new Ot(ma.paint_hillshade["hillshade-accent-color"])})};const Og=Di([{name:"a_pos",components:2,type:"Int16"}],4),{members:Nc}=Og;var Td=ff,h3=ff;function ff(D,_,k){k=k||2;var X,de,Ge,ft,_t,At,Nt,cn=_&&_.length,vn=cn?_[0]*k:D.length,bn=Km(D,0,vn,k,!0),jn=[];if(!bn||bn.next===bn.prev)return jn;if(cn&&(bn=function(Br,Jr,si,Li){var vi,ui,ua,ba=[];for(vi=0,ui=Jr.length;vi<ui;vi++)(ua=Km(Br,Jr[vi]*Li,vi<ui-1?Jr[vi+1]*Li:Br.length,Li,!1))===ua.next&&(ua.steiner=!0),ba.push(zf(ua));for(ba.sort(f3),vi=0;vi<ba.length;vi++)si=Rc(si=mm(ba[vi],si),si.next);return si}(D,_,bn,k)),D.length>80*k){X=Ge=D[0],de=ft=D[1];for(var Zn=k;Zn<vn;Zn+=k)(_t=D[Zn])<X&&(X=_t),(At=D[Zn+1])<de&&(de=At),_t>Ge&&(Ge=_t),At>ft&&(ft=At);Nt=(Nt=Math.max(Ge-X,ft-de))!==0?1/Nt:0}return mf(bn,jn,k,X,de,Nt),jn}function Km(D,_,k,X,de){var Ge,ft;if(de===fo(D,_,k,X)>0)for(Ge=_;Ge<k;Ge+=X)ft=Ca(Ge,D[Ge],D[Ge+1],ft);else for(Ge=k-X;Ge>=_;Ge-=X)ft=Ca(Ge,D[Ge],D[Ge+1],ft);return ft&&vt(ft,ft.next)&&(La(ft),ft=ft.next),ft}function Rc(D,_){if(!D)return D;_||(_=D);var k,X=D;do if(k=!1,X.steiner||!vt(X,X.next)&&Ze(X.prev,X,X.next)!==0)X=X.next;else{if(La(X),(X=_=X.prev)===X.next)break;k=!0}while(k||X!==_);return _}function mf(D,_,k,X,de,Ge,ft){if(D){!ft&&Ge&&function(cn,vn,bn,jn){var Zn=cn;do Zn.z===null&&(Zn.z=R3(Zn.x,Zn.y,vn,bn,jn)),Zn.prevZ=Zn.prev,Zn.nextZ=Zn.next,Zn=Zn.next;while(Zn!==cn);Zn.prevZ.nextZ=null,Zn.prevZ=null,function(Br){var Jr,si,Li,vi,ui,ua,ba,Ua,Ga=1;do{for(si=Br,Br=null,ui=null,ua=0;si;){for(ua++,Li=si,ba=0,Jr=0;Jr<Ga&&(ba++,Li=Li.nextZ);Jr++);for(Ua=Ga;ba>0||Ua>0&&Li;)ba!==0&&(Ua===0||!Li||si.z<=Li.z)?(vi=si,si=si.nextZ,ba--):(vi=Li,Li=Li.nextZ,Ua--),ui?ui.nextZ=vi:Br=vi,vi.prevZ=ui,ui=vi;si=Li}ui.nextZ=null,Ga*=2}while(ua>1)}(Zn)}(D,X,de,Ge);for(var _t,At,Nt=D;D.prev!==D.next;)if(_t=D.prev,At=D.next,Ge?gf(D,X,de,Ge):p3(D))_.push(_t.i/k),_.push(D.i/k),_.push(At.i/k),La(D),D=At.next,Nt=At.next;else if((D=At)===Nt){ft?ft===1?mf(D=fm(Rc(D),_,k),_,k,X,de,Ge,2):ft===2&&Nf(D,_,k,X,de,Ge):mf(Rc(D),_,k,X,de,Ge,1);break}}}function p3(D){var _=D.prev,k=D,X=D.next;if(Ze(_,k,X)>=0)return!1;for(var de=D.next.next;de!==D.prev;){if(yf(_.x,_.y,k.x,k.y,X.x,X.y,de.x,de.y)&&Ze(de.prev,de,de.next)>=0)return!1;de=de.next}return!0}function gf(D,_,k,X){var de=D.prev,Ge=D,ft=D.next;if(Ze(de,Ge,ft)>=0)return!1;for(var _t=de.x>Ge.x?de.x>ft.x?de.x:ft.x:Ge.x>ft.x?Ge.x:ft.x,At=de.y>Ge.y?de.y>ft.y?de.y:ft.y:Ge.y>ft.y?Ge.y:ft.y,Nt=R3(de.x<Ge.x?de.x<ft.x?de.x:ft.x:Ge.x<ft.x?Ge.x:ft.x,de.y<Ge.y?de.y<ft.y?de.y:ft.y:Ge.y<ft.y?Ge.y:ft.y,_,k,X),cn=R3(_t,At,_,k,X),vn=D.prevZ,bn=D.nextZ;vn&&vn.z>=Nt&&bn&&bn.z<=cn;){if(vn!==D.prev&&vn!==D.next&&yf(de.x,de.y,Ge.x,Ge.y,ft.x,ft.y,vn.x,vn.y)&&Ze(vn.prev,vn,vn.next)>=0||(vn=vn.prevZ,bn!==D.prev&&bn!==D.next&&yf(de.x,de.y,Ge.x,Ge.y,ft.x,ft.y,bn.x,bn.y)&&Ze(bn.prev,bn,bn.next)>=0))return!1;bn=bn.nextZ}for(;vn&&vn.z>=Nt;){if(vn!==D.prev&&vn!==D.next&&yf(de.x,de.y,Ge.x,Ge.y,ft.x,ft.y,vn.x,vn.y)&&Ze(vn.prev,vn,vn.next)>=0)return!1;vn=vn.prevZ}for(;bn&&bn.z<=cn;){if(bn!==D.prev&&bn!==D.next&&yf(de.x,de.y,Ge.x,Ge.y,ft.x,ft.y,bn.x,bn.y)&&Ze(bn.prev,bn,bn.next)>=0)return!1;bn=bn.nextZ}return!0}function fm(D,_,k){var X=D;do{var de=X.prev,Ge=X.next.next;!vt(de,Ge)&&on(de,X,X.next,Ge)&&mi(de,Ge)&&mi(Ge,de)&&(_.push(de.i/k),_.push(X.i/k),_.push(Ge.i/k),La(X),La(X.next),X=D=Ge),X=X.next}while(X!==D);return Rc(X)}function Nf(D,_,k,X,de,Ge){var ft=D;do{for(var _t=ft.next.next;_t!==ft.prev;){if(ft.i!==_t.i&&eg(ft,_t)){var At=ra(ft,_t);return ft=Rc(ft,ft.next),At=Rc(At,At.next),mf(ft,_,k,X,de,Ge),void mf(At,_,k,X,de,Ge)}_t=_t.next}ft=ft.next}while(ft!==D)}function f3(D,_){return D.x-_.x}function mm(D,_){var k=function(Ge,ft){var _t,At=ft,Nt=Ge.x,cn=Ge.y,vn=-1/0;do{if(cn<=At.y&&cn>=At.next.y&&At.next.y!==At.y){var bn=At.x+(cn-At.y)*(At.next.x-At.x)/(At.next.y-At.y);if(bn<=Nt&&bn>vn){if(vn=bn,bn===Nt){if(cn===At.y)return At;if(cn===At.next.y)return At.next}_t=At.x<At.next.x?At:At.next}}At=At.next}while(At!==ft);if(!_t)return null;if(Nt===vn)return _t;var jn,Zn=_t,Br=_t.x,Jr=_t.y,si=1/0;At=_t;do Nt>=At.x&&At.x>=Br&&Nt!==At.x&&yf(cn<Jr?Nt:vn,cn,Br,Jr,cn<Jr?vn:Nt,cn,At.x,At.y)&&(jn=Math.abs(cn-At.y)/(Nt-At.x),mi(At,Ge)&&(jn<si||jn===si&&(At.x>_t.x||At.x===_t.x&&jh(_t,At)))&&(_t=At,si=jn)),At=At.next;while(At!==Zn);return _t}(D,_);if(!k)return _;var X=ra(k,D),de=Rc(k,k.next);return Rc(X,X.next),_===k?de:_}function jh(D,_){return Ze(D.prev,D,_.prev)<0&&Ze(_.next,D,D.next)<0}function R3(D,_,k,X,de){return(D=1431655765&((D=858993459&((D=252645135&((D=16711935&((D=32767*(D-k)*de)|D<<8))|D<<4))|D<<2))|D<<1))|(_=1431655765&((_=858993459&((_=252645135&((_=16711935&((_=32767*(_-X)*de)|_<<8))|_<<4))|_<<2))|_<<1))<<1}function zf(D){var _=D,k=D;do(_.x<k.x||_.x===k.x&&_.y<k.y)&&(k=_),_=_.next;while(_!==D);return k}function yf(D,_,k,X,de,Ge,ft,_t){return(de-ft)*(_-_t)-(D-ft)*(Ge-_t)>=0&&(D-ft)*(X-_t)-(k-ft)*(_-_t)>=0&&(k-ft)*(Ge-_t)-(de-ft)*(X-_t)>=0}function eg(D,_){return D.next.i!==_.i&&D.prev.i!==_.i&&!function(k,X){var de=k;do{if(de.i!==k.i&&de.next.i!==k.i&&de.i!==X.i&&de.next.i!==X.i&&on(de,de.next,k,X))return!0;de=de.next}while(de!==k);return!1}(D,_)&&(mi(D,_)&&mi(_,D)&&function(k,X){var de=k,Ge=!1,ft=(k.x+X.x)/2,_t=(k.y+X.y)/2;do de.y>_t!=de.next.y>_t&&de.next.y!==de.y&&ft<(de.next.x-de.x)*(_t-de.y)/(de.next.y-de.y)+de.x&&(Ge=!Ge),de=de.next;while(de!==k);return Ge}(D,_)&&(Ze(D.prev,D,_.prev)||Ze(D,_.prev,_))||vt(D,_)&&Ze(D.prev,D,D.next)>0&&Ze(_.prev,_,_.next)>0)}function Ze(D,_,k){return(_.y-D.y)*(k.x-_.x)-(_.x-D.x)*(k.y-_.y)}function vt(D,_){return D.x===_.x&&D.y===_.y}function on(D,_,k,X){var de=Qn(Ze(D,_,k)),Ge=Qn(Ze(D,_,X)),ft=Qn(Ze(k,X,D)),_t=Qn(Ze(k,X,_));return de!==Ge&&ft!==_t||!(de!==0||!Fn(D,k,_))||!(Ge!==0||!Fn(D,X,_))||!(ft!==0||!Fn(k,D,X))||!(_t!==0||!Fn(k,_,X))}function Fn(D,_,k){return _.x<=Math.max(D.x,k.x)&&_.x>=Math.min(D.x,k.x)&&_.y<=Math.max(D.y,k.y)&&_.y>=Math.min(D.y,k.y)}function Qn(D){return D>0?1:D<0?-1:0}function mi(D,_){return Ze(D.prev,D,D.next)<0?Ze(D,_,D.next)>=0&&Ze(D,D.prev,_)>=0:Ze(D,_,D.prev)<0||Ze(D,D.next,_)<0}function ra(D,_){var k=new Oa(D.i,D.x,D.y),X=new Oa(_.i,_.x,_.y),de=D.next,Ge=_.prev;return D.next=_,_.prev=D,k.next=de,de.prev=k,X.next=k,k.prev=X,Ge.next=X,X.prev=Ge,X}function Ca(D,_,k,X){var de=new Oa(D,_,k);return X?(de.next=X.next,de.prev=X,X.next.prev=de,X.next=de):(de.prev=de,de.next=de),de}function La(D){D.next.prev=D.prev,D.prev.next=D.next,D.prevZ&&(D.prevZ.nextZ=D.nextZ),D.nextZ&&(D.nextZ.prevZ=D.prevZ)}function Oa(D,_,k){this.i=D,this.x=_,this.y=k,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function fo(D,_,k,X){for(var de=0,Ge=_,ft=k-X;Ge<k;Ge+=X)de+=(D[ft]-D[Ge])*(D[Ge+1]+D[ft+1]),ft=Ge;return de}function Ho(D,_,k,X,de){qs(D,_,k,X||D.length-1,de||_l)}function qs(D,_,k,X,de){for(;X>k;){if(X-k>600){var Ge=X-k+1,ft=_-k+1,_t=Math.log(Ge),At=.5*Math.exp(2*_t/3),Nt=.5*Math.sqrt(_t*At*(Ge-At)/Ge)*(ft-Ge/2<0?-1:1);qs(D,_,Math.max(k,Math.floor(_-ft*At/Ge+Nt)),Math.min(X,Math.floor(_+(Ge-ft)*At/Ge+Nt)),de)}var cn=D[_],vn=k,bn=X;for(Ys(D,k,_),de(D[X],cn)>0&&Ys(D,k,X);vn<bn;){for(Ys(D,vn,bn),vn++,bn--;de(D[vn],cn)<0;)vn++;for(;de(D[bn],cn)>0;)bn--}de(D[k],cn)===0?Ys(D,k,bn):Ys(D,++bn,X),bn<=_&&(k=bn+1),_<=bn&&(X=bn-1)}}function Ys(D,_,k){var X=D[_];D[_]=D[k],D[k]=X}function _l(D,_){return D<_?-1:D>_?1:0}function Mo(D,_){const k=D.length;if(k<=1)return[D];const X=[];let de,Ge;for(let ft=0;ft<k;ft++){const _t=xn(D[ft]);_t!==0&&(D[ft].area=Math.abs(_t),Ge===void 0&&(Ge=_t<0),Ge===_t<0?(de&&X.push(de),de=[D[ft]]):de.push(D[ft]))}if(de&&X.push(de),_>1)for(let ft=0;ft<X.length;ft++)X[ft].length<=_||(Ho(X[ft],_,1,X[ft].length-1,es),X[ft]=X[ft].slice(0,_));return X}function es(D,_){return _.area-D.area}function Qs(D,_,k){const X=k.patternDependencies;let de=!1;for(const Ge of _){const ft=Ge.paint.get(`${D}-pattern`);ft.isConstant()||(de=!0);const _t=ft.constantOr(null);_t&&(de=!0,X[_t.to]=!0,X[_t.from]=!0)}return de}function Ms(D,_,k,X,de){const Ge=de.patternDependencies;for(const ft of _){const _t=ft.paint.get(`${D}-pattern`).value;if(_t.kind!=="constant"){let At=_t.evaluate({zoom:X-1},k,{},de.availableImages),Nt=_t.evaluate({zoom:X},k,{},de.availableImages),cn=_t.evaluate({zoom:X+1},k,{},de.availableImages);At=At&&At.name?At.name:At,Nt=Nt&&Nt.name?Nt.name:Nt,cn=cn&&cn.name?cn.name:cn,Ge[At]=!0,Ge[Nt]=!0,Ge[cn]=!0,k.patterns[ft.id]={min:At,mid:Nt,max:cn}}}return k}ff.deviation=function(D,_,k,X){var de=_&&_.length,Ge=Math.abs(fo(D,0,de?_[0]*k:D.length,k));if(de)for(var ft=0,_t=_.length;ft<_t;ft++)Ge-=Math.abs(fo(D,_[ft]*k,ft<_t-1?_[ft+1]*k:D.length,k));var At=0;for(ft=0;ft<X.length;ft+=3){var Nt=X[ft]*k,cn=X[ft+1]*k,vn=X[ft+2]*k;At+=Math.abs((D[Nt]-D[vn])*(D[cn+1]-D[Nt+1])-(D[Nt]-D[cn])*(D[vn+1]-D[Nt+1]))}return Ge===0&&At===0?0:Math.abs((At-Ge)/Ge)},ff.flatten=function(D){for(var _=D[0][0].length,k={vertices:[],holes:[],dimensions:_},X=0,de=0;de<D.length;de++){for(var Ge=0;Ge<D[de].length;Ge++)for(var ft=0;ft<_;ft++)k.vertices.push(D[de][Ge][ft]);de>0&&k.holes.push(X+=D[de-1].length)}return k},Td.default=h3;class Tl{constructor(_){this.zoom=_.zoom,this.overscaling=_.overscaling,this.layers=_.layers,this.layerIds=this.layers.map(k=>k.id),this.index=_.index,this.hasPattern=!1,this.patternFeatures=[],this.layoutVertexArray=new wi,this.indexArray=new rs,this.indexArray2=new ll,this.programConfigurations=new Up(_.layers,_.zoom),this.segments=new hc,this.segments2=new hc,this.stateDependentLayerIds=this.layers.filter(k=>k.isStateDependent()).map(k=>k.id),this.projection=_.projection}populate(_,k,X,de){this.hasPattern=Qs("fill",this.layers,k);const Ge=this.layers[0].layout.get("fill-sort-key"),ft=[];for(const{feature:_t,id:At,index:Nt,sourceLayerIndex:cn}of _){const vn=this.layers[0]._featureFilter.needGeometry,bn=vp(_t,vn);if(!this.layers[0]._featureFilter.filter(new Iu(this.zoom),bn,X))continue;const jn=Ge?Ge.evaluate(bn,{},X,k.availableImages):void 0,Zn={id:At,properties:_t.properties,type:_t.type,sourceLayerIndex:cn,index:Nt,geometry:vn?bn.geometry:bh(_t,X,de),patterns:{},sortKey:jn};ft.push(Zn)}Ge&&ft.sort((_t,At)=>_t.sortKey-At.sortKey);for(const _t of ft){const{geometry:At,index:Nt,sourceLayerIndex:cn}=_t;if(this.hasPattern){const vn=Ms("fill",this.layers,_t,this.zoom,k);this.patternFeatures.push(vn)}else this.addFeature(_t,At,Nt,X,{},k.availableImages);k.featureIndex.insert(_[Nt].feature,At,Nt,cn,this.index)}}update(_,k,X,de){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(_,k,this.stateDependentLayers,X,de)}addFeatures(_,k,X,de,Ge){for(const ft of this.patternFeatures)this.addFeature(ft,ft.geometry,ft.index,k,X,de)}isEmpty(){return this.layoutVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(_){this.uploaded||(this.layoutVertexBuffer=_.createVertexBuffer(this.layoutVertexArray,Nc),this.indexBuffer=_.createIndexBuffer(this.indexArray),this.indexBuffer2=_.createIndexBuffer(this.indexArray2)),this.programConfigurations.upload(_),this.uploaded=!0}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.indexBuffer2.destroy(),this.programConfigurations.destroy(),this.segments.destroy(),this.segments2.destroy())}addFeature(_,k,X,de,Ge,ft=[]){for(const _t of Mo(k,500)){let At=0;for(const Zn of _t)At+=Zn.length;const Nt=this.segments.prepareSegment(At,this.layoutVertexArray,this.indexArray),cn=Nt.vertexLength,vn=[],bn=[];for(const Zn of _t){if(Zn.length===0)continue;Zn!==_t[0]&&bn.push(vn.length/2);const Br=this.segments2.prepareSegment(Zn.length,this.layoutVertexArray,this.indexArray2),Jr=Br.vertexLength;this.layoutVertexArray.emplaceBack(Zn[0].x,Zn[0].y),this.indexArray2.emplaceBack(Jr+Zn.length-1,Jr),vn.push(Zn[0].x),vn.push(Zn[0].y);for(let si=1;si<Zn.length;si++)this.layoutVertexArray.emplaceBack(Zn[si].x,Zn[si].y),this.indexArray2.emplaceBack(Jr+si-1,Jr+si),vn.push(Zn[si].x),vn.push(Zn[si].y);Br.vertexLength+=Zn.length,Br.primitiveLength+=Zn.length}const jn=Td(vn,bn);for(let Zn=0;Zn<jn.length;Zn+=3)this.indexArray.emplaceBack(cn+jn[Zn],cn+jn[Zn+1],cn+jn[Zn+2]);Nt.vertexLength+=At,Nt.primitiveLength+=jn.length/3}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,_,X,Ge,ft,de)}}Zo(Tl,"FillBucket",{omit:["layers","patternFeatures"]});const Al=new Wn({"fill-sort-key":new rn(ma.layout_fill["fill-sort-key"])});var au={paint:new Wn({"fill-antialias":new Ot(ma.paint_fill["fill-antialias"]),"fill-opacity":new rn(ma.paint_fill["fill-opacity"]),"fill-color":new rn(ma.paint_fill["fill-color"]),"fill-outline-color":new rn(ma.paint_fill["fill-outline-color"]),"fill-translate":new Ot(ma.paint_fill["fill-translate"]),"fill-translate-anchor":new Ot(ma.paint_fill["fill-translate-anchor"]),"fill-pattern":new Tn(ma.paint_fill["fill-pattern"])}),layout:Al};const sl=Di([{name:"a_pos_normal_ed",components:4,type:"Int16"}]),cl=Di([{name:"a_centroid_pos",components:2,type:"Uint16"}]),wc=Di([{name:"a_pos_3",components:3,type:"Int16"},{name:"a_pos_normal_3",components:3,type:"Int16"}]),{members:nc}=sl;var Wc=pu;function pu(D,_,k,X,de){this.properties={},this.extent=k,this.type=0,this._pbf=D,this._geometry=-1,this._keys=X,this._values=de,D.readFields(Dd,this,_)}function Dd(D,_,k){D==1?_.id=k.readVarint():D==2?function(X,de){for(var Ge=X.readVarint()+X.pos;X.pos<Ge;){var ft=de._keys[X.readVarint()],_t=de._values[X.readVarint()];de.properties[ft]=_t}}(k,_):D==3?_.type=k.readVarint():D==4&&(_._geometry=k.pos)}function Ed(D){for(var _,k,X=0,de=0,Ge=D.length,ft=Ge-1;de<Ge;ft=de++)X+=((k=D[ft]).x-(_=D[de]).x)*(_.y+k.y);return X}pu.types=["Unknown","Point","LineString","Polygon"],pu.prototype.loadGeometry=function(){var D=this._pbf;D.pos=this._geometry;for(var _,k=D.readVarint()+D.pos,X=1,de=0,Ge=0,ft=0,_t=[];D.pos<k;){if(de<=0){var At=D.readVarint();X=7&At,de=At>>3}if(de--,X===1||X===2)Ge+=D.readSVarint(),ft+=D.readSVarint(),X===1&&(_&&_t.push(_),_=[]),_.push(new G(Ge,ft));else{if(X!==7)throw new Error("unknown command "+X);_&&_.push(_[0].clone())}}return _&&_t.push(_),_t},pu.prototype.bbox=function(){var D=this._pbf;D.pos=this._geometry;for(var _=D.readVarint()+D.pos,k=1,X=0,de=0,Ge=0,ft=1/0,_t=-1/0,At=1/0,Nt=-1/0;D.pos<_;){if(X<=0){var cn=D.readVarint();k=7&cn,X=cn>>3}if(X--,k===1||k===2)(de+=D.readSVarint())<ft&&(ft=de),de>_t&&(_t=de),(Ge+=D.readSVarint())<At&&(At=Ge),Ge>Nt&&(Nt=Ge);else if(k!==7)throw new Error("unknown command "+k)}return[ft,At,_t,Nt]},pu.prototype.toGeoJSON=function(D,_,k){var X,de,Ge=this.extent*Math.pow(2,k),ft=this.extent*D,_t=this.extent*_,At=this.loadGeometry(),Nt=pu.types[this.type];function cn(jn){for(var Zn=0;Zn<jn.length;Zn++){var Br=jn[Zn];jn[Zn]=[360*(Br.x+ft)/Ge-180,360/Math.PI*Math.atan(Math.exp((180-360*(Br.y+_t)/Ge)*Math.PI/180))-90]}}switch(this.type){case 1:var vn=[];for(X=0;X<At.length;X++)vn[X]=At[X][0];cn(At=vn);break;case 2:for(X=0;X<At.length;X++)cn(At[X]);break;case 3:for(At=function(jn){var Zn=jn.length;if(Zn<=1)return[jn];for(var Br,Jr,si=[],Li=0;Li<Zn;Li++){var vi=Ed(jn[Li]);vi!==0&&(Jr===void 0&&(Jr=vi<0),Jr===vi<0?(Br&&si.push(Br),Br=[jn[Li]]):Br.push(jn[Li]))}return Br&&si.push(Br),si}(At),X=0;X<At.length;X++)for(de=0;de<At[X].length;de++)cn(At[X][de])}At.length===1?At=At[0]:Nt="Multi"+Nt;var bn={type:"Feature",geometry:{type:Nt,coordinates:At},properties:this.properties};return"id"in this&&(bn.id=this.id),bn};var md=th;function th(D,_){this.version=1,this.name=null,this.extent=4096,this.length=0,this._pbf=D,this._keys=[],this._values=[],this._features=[],D.readFields(Eu,this,_),this.length=this._features.length}function Eu(D,_,k){D===15?_.version=k.readVarint():D===1?_.name=k.readString():D===5?_.extent=k.readVarint():D===2?_._features.push(k.pos):D===3?_._keys.push(k.readString()):D===4&&_._values.push(function(X){for(var de=null,Ge=X.readVarint()+X.pos;X.pos<Ge;){var ft=X.readVarint()>>3;de=ft===1?X.readString():ft===2?X.readFloat():ft===3?X.readDouble():ft===4?X.readVarint64():ft===5?X.readVarint():ft===6?X.readSVarint():ft===7?X.readBoolean():null}return de}(k))}function Xm(D,_,k){if(D===3){var X=new md(k,k.readVarint()+k.pos);X.length&&(_[X.name]=X)}}th.prototype.feature=function(D){if(D<0||D>=this._features.length)throw new Error("feature index out of bounds");this._pbf.pos=this._features[D];var _=this._pbf.readVarint()+this._pbf.pos;return new Wc(this._pbf,_,this.extent,this._keys,this._values)};var Vd={VectorTile:function(D,_){this.layers=D.readFields(Xm,{},_)},VectorTileFeature:Wc,VectorTileLayer:md};function Dp(D,_,k,X){const de=[],Ge=X===0?(ft,_t,At,Nt,cn,vn)=>{ft.push(new G(vn,At+(vn-_t)/(Nt-_t)*(cn-At)))}:(ft,_t,At,Nt,cn,vn)=>{ft.push(new G(_t+(vn-At)/(cn-At)*(Nt-_t),vn))};for(const ft of D){const _t=[];for(const At of ft){if(At.length<=2)continue;const Nt=[];for(let bn=0;bn<At.length-1;bn++){const jn=At[bn].x,Zn=At[bn].y,Br=At[bn+1].x,Jr=At[bn+1].y,si=X===0?jn:Zn,Li=X===0?Br:Jr;si<_?Li>_&&Ge(Nt,jn,Zn,Br,Jr,_):si>k?Li<k&&Ge(Nt,jn,Zn,Br,Jr,k):Nt.push(At[bn]),Li<_&&si>=_&&Ge(Nt,jn,Zn,Br,Jr,_),Li>k&&si<=k&&Ge(Nt,jn,Zn,Br,Jr,k)}let cn=At[At.length-1];const vn=X===0?cn.x:cn.y;vn>=_&&vn<=k&&Nt.push(cn),Nt.length&&(cn=Nt[Nt.length-1],Nt[0].x===cn.x&&Nt[0].y===cn.y||Nt.push(Nt[0]),_t.push(Nt))}_t.length&&de.push(_t)}return de}const gm=Vd.VectorTileFeature.types,ym=Math.pow(2,13);function ip(D,_,k,X,de,Ge,ft,_t){D.emplaceBack((_<<1)+ft,(k<<1)+Ge,(Math.floor(X*ym)<<1)+de,Math.round(_t))}function ap(D,_,k){D.emplaceBack(_.x,_.y,_.z,k[0]*16384,k[1]*16384,k[2]*16384)}class vf{constructor(){this.acc=new G(0,0),this.polyCount=[]}startRing(_){this.currentPolyCount={edges:0,top:0},this.polyCount.push(this.currentPolyCount),this.min||(this.min=new G(_.x,_.y),this.max=new G(_.x,_.y))}append(_,k){this.currentPolyCount.edges++,this.acc._add(_);const X=this.min,de=this.max;_.x<X.x?X.x=_.x:_.x>de.x&&(de.x=_.x),_.y<X.y?X.y=_.y:_.y>de.y&&(de.y=_.y),((_.x===0||_.x===Ml)&&_.x===k.x)!=((_.y===0||_.y===Ml)&&_.y===k.y)&&this.processBorderOverlap(_,k),k.x<0!=_.x<0&&this.addBorderIntersection(0,Qe(k.y,_.y,(0-k.x)/(_.x-k.x))),k.x>Ml!=_.x>Ml&&this.addBorderIntersection(1,Qe(k.y,_.y,(Ml-k.x)/(_.x-k.x))),k.y<0!=_.y<0&&this.addBorderIntersection(2,Qe(k.x,_.x,(0-k.y)/(_.y-k.y))),k.y>Ml!=_.y>Ml&&this.addBorderIntersection(3,Qe(k.x,_.x,(Ml-k.y)/(_.y-k.y)))}addBorderIntersection(_,k){this.borders||(this.borders=[[Number.MAX_VALUE,-Number.MAX_VALUE],[Number.MAX_VALUE,-Number.MAX_VALUE],[Number.MAX_VALUE,-Number.MAX_VALUE],[Number.MAX_VALUE,-Number.MAX_VALUE]]);const X=this.borders[_];k<X[0]&&(X[0]=k),k>X[1]&&(X[1]=k)}processBorderOverlap(_,k){if(_.x===k.x){if(_.y===k.y)return;const X=_.x===0?0:1;this.addBorderIntersection(X,k.y),this.addBorderIntersection(X,_.y)}else{const X=_.y===0?2:3;this.addBorderIntersection(X,k.x),this.addBorderIntersection(X,_.x)}}centroid(){const _=this.polyCount.reduce((k,X)=>k+X.edges,0);return _!==0?this.acc.div(_)._round():new G(0,0)}span(){return new G(this.max.x-this.min.x,this.max.y-this.min.y)}intersectsCount(){return this.borders.reduce((_,k)=>_+ +(k[0]!==Number.MAX_VALUE),0)}}class op{constructor(_){this.zoom=_.zoom,this.canonical=_.canonical,this.overscaling=_.overscaling,this.layers=_.layers,this.layerIds=this.layers.map(k=>k.id),this.index=_.index,this.hasPattern=!1,this.projection=_.projection,this.layoutVertexArray=new Oi,this.centroidVertexArray=new $d,this.indexArray=new rs,this.programConfigurations=new Up(_.layers,_.zoom),this.segments=new hc,this.stateDependentLayerIds=this.layers.filter(k=>k.isStateDependent()).map(k=>k.id),this.enableTerrain=_.enableTerrain}populate(_,k,X,de){this.features=[],this.hasPattern=Qs("fill-extrusion",this.layers,k),this.featuresOnBorder=[],this.borders=[[],[],[],[]],this.borderDoneWithNeighborZ=[-1,-1,-1,-1],this.tileToMeter=function(Ge){const ft=Math.exp(Math.PI*(1-Ge.y/(1<<Ge.z)*2));return 80150034*ft/(ft*ft+1)/Ml/(1<<Ge.z)}(X);for(const{feature:Ge,id:ft,index:_t,sourceLayerIndex:At}of _){const Nt=this.layers[0]._featureFilter.needGeometry,cn=vp(Ge,Nt);if(!this.layers[0]._featureFilter.filter(new Iu(this.zoom),cn,X))continue;const vn={id:ft,sourceLayerIndex:At,index:_t,geometry:Nt?cn.geometry:bh(Ge,X,de),properties:Ge.properties,type:Ge.type,patterns:{}},bn=this.layoutVertexArray.length;this.hasPattern?this.features.push(Ms("fill-extrusion",this.layers,vn,this.zoom,k)):this.addFeature(vn,vn.geometry,_t,X,{},k.availableImages,de),k.featureIndex.insert(Ge,vn.geometry,_t,At,this.index,bn)}this.sortBorders()}addFeatures(_,k,X,de,Ge){for(const ft of this.features){const{geometry:_t}=ft;this.addFeature(ft,_t,ft.index,k,X,de,Ge)}this.sortBorders()}update(_,k,X,de){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(_,k,this.stateDependentLayers,X,de)}isEmpty(){return this.layoutVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(_){this.uploaded||(this.layoutVertexBuffer=_.createVertexBuffer(this.layoutVertexArray,nc),this.indexBuffer=_.createIndexBuffer(this.indexArray),this.layoutVertexExtArray&&(this.layoutVertexExtBuffer=_.createVertexBuffer(this.layoutVertexExtArray,wc.members,!0))),this.programConfigurations.upload(_),this.uploaded=!0}uploadCentroid(_){this.centroidVertexArray.length!==0&&(this.centroidVertexBuffer?this.needsCentroidUpdate&&this.centroidVertexBuffer.updateData(this.centroidVertexArray):this.centroidVertexBuffer=_.createVertexBuffer(this.centroidVertexArray,cl.members,!0),this.needsCentroidUpdate=!1)}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.centroidVertexBuffer&&this.centroidVertexBuffer.destroy(),this.layoutVertexExtBuffer&&this.layoutVertexExtBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy())}addFeature(_,k,X,de,Ge,ft,_t){const At=[new G(0,0),new G(Ml,Ml)],Nt=_t.projection,cn=Nt.name==="globe",vn=this.enableTerrain&&!cn?new vf:null;cn&&!this.layoutVertexExtArray&&(this.layoutVertexExtArray=new Ud);const bn=Mo(k,500);for(let Br=bn.length-1;Br>=0;Br--){const Jr=bn[Br];(Jr.length===0||(jn=Jr[0]).every(si=>si.x<=0)||jn.every(si=>si.x>=Ml)||jn.every(si=>si.y<=0)||jn.every(si=>si.y>=Ml))&&bn.splice(Br,1)}var jn;let Zn;if(cn){const Jr=1<<de.z,si=Wd(de.x/Jr),Li=Wd((de.x+1)/Jr),vi=ed(de.y/Jr),ui=ed((de.y+1)/Jr);Zn=function(ua,ba,Ua,Ga,ho=0,bo){const Va=[];if(!ua.length||!Ua||!Ga)return Va;const Ka=(El,Fl)=>{for(const Vs of El)Va.push({polygon:Vs,bounds:Fl})},Do=Math.ceil(Math.log2(Ua)),$o=Math.ceil(Math.log2(Ga)),Ro=Do-$o,No=[];for(let El=0;El<Math.abs(Ro);El++)No.push(Ro>0?0:1);for(let El=0;El<Math.min(Do,$o);El++)No.push(0),No.push(1);let Sl=ua;if(Sl=Dp(Sl,ba[0].y-ho,ba[1].y+ho,1),Sl=Dp(Sl,ba[0].x-ho,ba[1].x+ho,0),!Sl.length)return Va;const ru=[];for(No.length?ru.push({polygons:Sl,bounds:ba,depth:0}):Ka(Sl,ba);ru.length;){const El=ru.pop(),Fl=El.depth,Vs=No[Fl],gs=El.bounds[0],cu=El.bounds[1],Lu=Vs===0?gs.x:gs.y,kd=Vs===0?cu.x:cu.y,Ec=bo?bo(Vs,Lu,kd):.5*(Lu+kd),Pd=Dp(El.polygons,Lu-ho,Ec+ho,Vs),Fu=Dp(El.polygons,Ec-ho,kd+ho,Vs);if(Pd.length){const fu=[gs,new G(Vs===0?Ec:cu.x,Vs===1?Ec:cu.y)];No.length>Fl+1?ru.push({polygons:Pd,bounds:fu,depth:Fl+1}):Ka(Pd,fu)}if(Fu.length){const fu=[new G(Vs===0?Ec:gs.x,Vs===1?Ec:gs.y),cu];No.length>Fl+1?ru.push({polygons:Fu,bounds:fu,depth:Fl+1}):Ka(Fu,fu)}}return Va}(bn,At,Math.ceil((Li-si)/11.25),Math.ceil((vi-ui)/11.25),1,(ua,ba,Ua)=>{if(ua===0)return .5*(ba+Ua);{const Ga=ed((de.y+ba/Ml)/Jr);return($p(.5*(ed((de.y+Ua/Ml)/Jr)+Ga))*Jr-de.y)*Ml}})}else{Zn=[];for(const Br of bn)Zn.push({polygon:Br,bounds:At})}for(const Br of Zn){const Jr=Br.polygon;let si=0,Li=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray);for(let Ua=0;Ua<Jr.length;Ua++){const Ga=Jr[Ua];if(Ga.length===0)continue;si+=Ga.length;let ho=0;vn&&vn.startRing(Ga[0]);for(let bo=0;bo<Ga.length;bo++){const Va=Ga[bo];if(bo>=1){const Ka=Ga[bo-1];if(!tg(Va,Ka,Br.bounds)){vn&&vn.append(Va,Ka),Li.vertexLength+4>hc.MAX_VERTEX_ARRAY_LENGTH&&(Li=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray));const Do=Va.sub(Ka)._perp(),$o=Do.x/(Math.abs(Do.x)+Math.abs(Do.y)),Ro=Do.y>0?1:0,No=Ka.dist(Va);ho+No>32768&&(ho=0),ip(this.layoutVertexArray,Va.x,Va.y,$o,Ro,0,0,ho),ip(this.layoutVertexArray,Va.x,Va.y,$o,Ro,0,1,ho),ho+=No,ip(this.layoutVertexArray,Ka.x,Ka.y,$o,Ro,0,0,ho),ip(this.layoutVertexArray,Ka.x,Ka.y,$o,Ro,0,1,ho);const Sl=Li.vertexLength;if(this.indexArray.emplaceBack(Sl,Sl+2,Sl+1),this.indexArray.emplaceBack(Sl+1,Sl+2,Sl+3),Li.vertexLength+=4,Li.primitiveLength+=2,cn){const ru=this.layoutVertexExtArray,El=Nt.projectTilePoint(Va.x,Va.y,de),Fl=Nt.projectTilePoint(Ka.x,Ka.y,de),Vs=Nt.upVector(de,Va.x,Va.y),gs=Nt.upVector(de,Ka.x,Ka.y);ap(ru,El,Vs),ap(ru,El,Vs),ap(ru,Fl,gs),ap(ru,Fl,gs)}}}}}if(Li.vertexLength+si>hc.MAX_VERTEX_ARRAY_LENGTH&&(Li=this.segments.prepareSegment(si,this.layoutVertexArray,this.indexArray)),gm[_.type]!=="Polygon")continue;const vi=[],ui=[],ua=Li.vertexLength;for(let Ua=0;Ua<Jr.length;Ua++){const Ga=Jr[Ua];if(Ga.length!==0){Ga!==Jr[0]&&ui.push(vi.length/2);for(let ho=0;ho<Ga.length;ho++){const bo=Ga[ho];ip(this.layoutVertexArray,bo.x,bo.y,0,0,1,1,0),vi.push(bo.x),vi.push(bo.y),vn&&vn.currentPolyCount.top++,cn&&ap(this.layoutVertexExtArray,Nt.projectTilePoint(bo.x,bo.y,de),Nt.upVector(de,bo.x,bo.y))}}}const ba=Td(vi,ui);for(let Ua=0;Ua<ba.length;Ua+=3)this.indexArray.emplaceBack(ua+ba[Ua],ua+ba[Ua+2],ua+ba[Ua+1]);Li.primitiveLength+=ba.length/3,Li.vertexLength+=si}if(vn&&vn.polyCount.length>0){if(vn.borders){vn.vertexArrayOffset=this.centroidVertexArray.length;const Br=vn.borders,Jr=this.featuresOnBorder.push(vn)-1;for(let si=0;si<4;si++)Br[si][0]!==Number.MAX_VALUE&&this.borders[si].push(Jr)}this.encodeCentroid(vn.borders?void 0:vn.centroid(),vn)}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,_,X,Ge,ft,de)}sortBorders(){for(let _=0;_<4;_++)this.borders[_].sort((k,X)=>this.featuresOnBorder[k].borders[_][0]-this.featuresOnBorder[X].borders[_][0])}encodeCentroid(_,k,X=!0){let de,Ge;if(_)if(_.y!==0){const _t=k.span()._mult(this.tileToMeter);de=(Math.max(_.x,1)<<3)+Math.min(7,Math.round(_t.x/10)),Ge=(Math.max(_.y,1)<<3)+Math.min(7,Math.round(_t.y/10))}else de=Math.ceil(7*(_.x+450)),Ge=0;else de=0,Ge=+X;let ft=X?this.centroidVertexArray.length:k.vertexArrayOffset;for(const _t of k.polyCount){X&&this.centroidVertexArray.resize(this.centroidVertexArray.length+4*_t.edges+_t.top);for(let At=0;At<2*_t.edges;At++)this.centroidVertexArray.emplace(ft++,0,Ge),this.centroidVertexArray.emplace(ft++,de,Ge);for(let At=0;At<_t.top;At++)this.centroidVertexArray.emplace(ft++,de,Ge)}}}function tg(D,_,k){return D.x===_.x&&(D.x<k[0].x||D.x>k[1].x)||D.y===_.y&&(D.y<k[0].y||D.y>k[1].y)}Zo(op,"FillExtrusionBucket",{omit:["layers","features"]}),Zo(vf,"PartMetadata");var ng={paint:new Wn({"fill-extrusion-opacity":new Ot(ma["paint_fill-extrusion"]["fill-extrusion-opacity"]),"fill-extrusion-color":new rn(ma["paint_fill-extrusion"]["fill-extrusion-color"]),"fill-extrusion-translate":new Ot(ma["paint_fill-extrusion"]["fill-extrusion-translate"]),"fill-extrusion-translate-anchor":new Ot(ma["paint_fill-extrusion"]["fill-extrusion-translate-anchor"]),"fill-extrusion-pattern":new Tn(ma["paint_fill-extrusion"]["fill-extrusion-pattern"]),"fill-extrusion-height":new rn(ma["paint_fill-extrusion"]["fill-extrusion-height"]),"fill-extrusion-base":new rn(ma["paint_fill-extrusion"]["fill-extrusion-base"]),"fill-extrusion-vertical-gradient":new Ot(ma["paint_fill-extrusion"]["fill-extrusion-vertical-gradient"])})};function vm(D,_){return D.x*_.x+D.y*_.y}function rg(D,_){if(D.length===1){let k=0;const X=_[k++];let de;for(;!de||X.equals(de);)if(de=_[k++],!de)return 1/0;for(;k<_.length;k++){const Ge=_[k],ft=D[0],_t=de.sub(X),At=Ge.sub(X),Nt=ft.sub(X),cn=vm(_t,_t),vn=vm(_t,At),bn=vm(At,At),jn=vm(Nt,_t),Zn=vm(Nt,At),Br=cn*bn-vn*vn,Jr=(bn*jn-vn*Zn)/Br,si=(cn*Zn-vn*jn)/Br,Li=X.z*(1-Jr-si)+de.z*Jr+Ge.z*si;if(isFinite(Li))return Li}return 1/0}{let k=1/0;for(const X of _)k=Math.min(k,X.z);return k}}function O3(D){const _=new G(D[0],D[1]);return _.z=D[2],_}function ig(D,_,k,X,de,Ge,ft,_t){const At=ft*de.getElevationAt(D,_,!0,!0),Nt=Ge[0]!==0,cn=Nt?Ge[1]===0?ft*(Ge[0]/7-450):ft*function(vn,bn,jn){const Zn=Math.floor(bn[0]/8),Br=Math.floor(bn[1]/8),Jr=10*(bn[0]-8*Zn),si=10*(bn[1]-8*Br),Li=vn.getElevationAt(Zn,Br,!0,!0),vi=vn.getMeterToDEM(jn),ui=Math.floor(.5*(Jr*vi-1)),ua=Math.floor(.5*(si*vi-1)),ba=vn.tileCoordToPixel(Zn,Br),Ua=2*ui+1,Ga=2*ua+1,ho=function(Ro,No,Sl,ru,El){return[Ro.getElevationAtPixel(No,Sl,!0),Ro.getElevationAtPixel(No+El,Sl,!0),Ro.getElevationAtPixel(No,Sl+El,!0),Ro.getElevationAtPixel(No+ru,Sl+El,!0)]}(vn,ba.x-ui,ba.y-ua,Ua,Ga),bo=Math.abs(ho[0]-ho[1]),Va=Math.abs(ho[2]-ho[3]),Ka=Math.abs(ho[0]-ho[2])+Math.abs(ho[1]-ho[3]),Do=Math.min(.25,.5*vi*(bo+Va)/Ua),$o=Math.min(.25,.5*vi*Ka/Ga);return Li+Math.max(Do*Jr,$o*si)}(de,Ge,_t):At;return{base:At+(k===0)?-1:k,top:Nt?Math.max(cn+X,At+k+2):At+X}}const ag=Di([{name:"a_pos_normal",components:2,type:"Int16"},{name:"a_data",components:4,type:"Uint8"},{name:"a_linesofar",components:1,type:"Float32"}],4),{members:Lg}=ag,og=Di([{name:"a_packed",components:3,type:"Float32"}]),{members:sg}=og,x0=Vd.VectorTileFeature.types,n0=Math.cos(Math.PI/180*37.5);class L3{constructor(_){this.zoom=_.zoom,this.overscaling=_.overscaling,this.layers=_.layers,this.layerIds=this.layers.map(k=>k.id),this.index=_.index,this.projection=_.projection,this.hasPattern=!1,this.patternFeatures=[],this.lineClipsArray=[],this.gradients={},this.layers.forEach(k=>{this.gradients[k.id]={}}),this.layoutVertexArray=new _i,this.layoutVertexArray2=new To,this.indexArray=new rs,this.programConfigurations=new Up(_.layers,_.zoom),this.segments=new hc,this.maxLineLength=0,this.stateDependentLayerIds=this.layers.filter(k=>k.isStateDependent()).map(k=>k.id)}populate(_,k,X,de){this.hasPattern=Qs("line",this.layers,k);const Ge=this.layers[0].layout.get("line-sort-key"),ft=[];for(const{feature:cn,id:vn,index:bn,sourceLayerIndex:jn}of _){const Zn=this.layers[0]._featureFilter.needGeometry,Br=vp(cn,Zn);if(!this.layers[0]._featureFilter.filter(new Iu(this.zoom),Br,X))continue;const Jr=Ge?Ge.evaluate(Br,{},X):void 0,si={id:vn,properties:cn.properties,type:cn.type,sourceLayerIndex:jn,index:bn,geometry:Zn?Br.geometry:bh(cn,X,de),patterns:{},sortKey:Jr};ft.push(si)}Ge&&ft.sort((cn,vn)=>cn.sortKey-vn.sortKey);const{lineAtlas:_t,featureIndex:At}=k,Nt=this.addConstantDashes(_t);for(const cn of ft){const{geometry:vn,index:bn,sourceLayerIndex:jn}=cn;if(Nt&&this.addFeatureDashes(cn,_t),this.hasPattern){const Zn=Ms("line",this.layers,cn,this.zoom,k);this.patternFeatures.push(Zn)}else this.addFeature(cn,vn,bn,X,_t.positions,k.availableImages);At.insert(_[bn].feature,vn,bn,jn,this.index)}}addConstantDashes(_){let k=!1;for(const X of this.layers){const de=X.paint.get("line-dasharray").value,Ge=X.layout.get("line-cap").value;if(de.kind!=="constant"||Ge.kind!=="constant")k=!0;else{const ft=Ge.value,_t=de.value;if(!_t)continue;_.addDash(_t.from,ft),_.addDash(_t.to,ft),_t.other&&_.addDash(_t.other,ft)}}return k}addFeatureDashes(_,k){const X=this.zoom;for(const de of this.layers){const Ge=de.paint.get("line-dasharray").value,ft=de.layout.get("line-cap").value;if(Ge.kind==="constant"&&ft.kind==="constant")continue;let _t,At,Nt,cn,vn,bn;if(Ge.kind==="constant"){const Jr=Ge.value;if(!Jr)continue;_t=Jr.other||Jr.to,At=Jr.to,Nt=Jr.from}else _t=Ge.evaluate({zoom:X-1},_),At=Ge.evaluate({zoom:X},_),Nt=Ge.evaluate({zoom:X+1},_);ft.kind==="constant"?cn=vn=bn=ft.value:(cn=ft.evaluate({zoom:X-1},_),vn=ft.evaluate({zoom:X},_),bn=ft.evaluate({zoom:X+1},_)),k.addDash(_t,cn),k.addDash(At,vn),k.addDash(Nt,bn);const jn=k.getKey(_t,cn),Zn=k.getKey(At,vn),Br=k.getKey(Nt,bn);_.patterns[de.id]={min:jn,mid:Zn,max:Br}}}update(_,k,X,de){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(_,k,this.stateDependentLayers,X,de)}addFeatures(_,k,X,de,Ge){for(const ft of this.patternFeatures)this.addFeature(ft,ft.geometry,ft.index,k,X,de)}isEmpty(){return this.layoutVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(_){this.uploaded||(this.layoutVertexArray2.length!==0&&(this.layoutVertexBuffer2=_.createVertexBuffer(this.layoutVertexArray2,sg)),this.layoutVertexBuffer=_.createVertexBuffer(this.layoutVertexArray,Lg),this.indexBuffer=_.createIndexBuffer(this.indexArray)),this.programConfigurations.upload(_),this.uploaded=!0}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy())}lineFeatureClips(_){if(_.properties&&_.properties.hasOwnProperty("mapbox_clip_start")&&_.properties.hasOwnProperty("mapbox_clip_end"))return{start:+_.properties.mapbox_clip_start,end:+_.properties.mapbox_clip_end}}addFeature(_,k,X,de,Ge,ft){const _t=this.layers[0].layout,At=_t.get("line-join").evaluate(_,{}),Nt=_t.get("line-cap").evaluate(_,{}),cn=_t.get("line-miter-limit"),vn=_t.get("line-round-limit");this.lineClips=this.lineFeatureClips(_);for(const bn of k)this.addLine(bn,_,At,Nt,cn,vn);this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,_,X,Ge,ft,de)}addLine(_,k,X,de,Ge,ft){if(this.distance=0,this.scaledDistance=0,this.totalDistance=0,this.lineSoFar=0,this.lineClips){this.lineClipsArray.push(this.lineClips);for(let si=0;si<_.length-1;si++)this.totalDistance+=_[si].dist(_[si+1]);this.updateScaledDistance(),this.maxLineLength=Math.max(this.maxLineLength,this.totalDistance)}const _t=x0[k.type]==="Polygon";let At=_.length;for(;At>=2&&_[At-1].equals(_[At-2]);)At--;let Nt=0;for(;Nt<At-1&&_[Nt].equals(_[Nt+1]);)Nt++;if(At<(_t?3:2))return;X==="bevel"&&(Ge=1.05);const cn=this.overscaling<=16?122880/(512*this.overscaling):0,vn=this.segments.prepareSegment(10*At,this.layoutVertexArray,this.indexArray);let bn,jn,Zn,Br,Jr;this.e1=this.e2=-1,_t&&(bn=_[At-2],Jr=_[Nt].sub(bn)._unit()._perp());for(let si=Nt;si<At;si++){if(Zn=si===At-1?_t?_[Nt+1]:void 0:_[si+1],Zn&&_[si].equals(Zn))continue;Jr&&(Br=Jr),bn&&(jn=bn),bn=_[si],Jr=Zn?Zn.sub(bn)._unit()._perp():Br,Br=Br||Jr;let Li=Br.add(Jr);Li.x===0&&Li.y===0||Li._unit();const vi=Br.x*Jr.x+Br.y*Jr.y,ui=Li.x*Jr.x+Li.y*Jr.y,ua=ui!==0?1/ui:1/0,ba=2*Math.sqrt(2-2*ui),Ua=ui<n0&&jn&&Zn,Ga=Br.x*Jr.y-Br.y*Jr.x>0;if(Ua&&si>Nt){const Va=bn.dist(jn);if(Va>2*cn){const Ka=bn.sub(bn.sub(jn)._mult(cn/Va)._round());this.updateDistance(jn,Ka),this.addCurrentVertex(Ka,Br,0,0,vn),jn=Ka}}const ho=jn&&Zn;let bo=ho?X:_t?"butt":de;if(ho&&bo==="round"&&(ua<ft?bo="miter":ua<=2&&(bo="fakeround")),bo==="miter"&&ua>Ge&&(bo="bevel"),bo==="bevel"&&(ua>2&&(bo="flipbevel"),ua<Ge&&(bo="miter")),jn&&this.updateDistance(jn,bn),bo==="miter")Li._mult(ua),this.addCurrentVertex(bn,Li,0,0,vn);else if(bo==="flipbevel"){if(ua>100)Li=Jr.mult(-1);else{const Va=ua*Br.add(Jr).mag()/Br.sub(Jr).mag();Li._perp()._mult(Va*(Ga?-1:1))}this.addCurrentVertex(bn,Li,0,0,vn),this.addCurrentVertex(bn,Li.mult(-1),0,0,vn)}else if(bo==="bevel"||bo==="fakeround"){const Va=-Math.sqrt(ua*ua-1),Ka=Ga?Va:0,Do=Ga?0:Va;if(jn&&this.addCurrentVertex(bn,Br,Ka,Do,vn),bo==="fakeround"){const $o=Math.round(180*ba/Math.PI/20);for(let Ro=1;Ro<$o;Ro++){let No=Ro/$o;if(No!==.5){const ru=No-.5;No+=No*ru*(No-1)*((1.0904+vi*(vi*(3.55645-1.43519*vi)-3.2452))*ru*ru+(.848013+vi*(.215638*vi-1.06021)))}const Sl=Jr.sub(Br)._mult(No)._add(Br)._unit()._mult(Ga?-1:1);this.addHalfVertex(bn,Sl.x,Sl.y,!1,Ga,0,vn)}}Zn&&this.addCurrentVertex(bn,Jr,-Ka,-Do,vn)}else if(bo==="butt")this.addCurrentVertex(bn,Li,0,0,vn);else if(bo==="square"){const Va=jn?1:-1;jn||this.addCurrentVertex(bn,Li,Va,Va,vn),this.addCurrentVertex(bn,Li,0,0,vn),jn&&this.addCurrentVertex(bn,Li,Va,Va,vn)}else bo==="round"&&(jn&&(this.addCurrentVertex(bn,Br,0,0,vn),this.addCurrentVertex(bn,Br,1,1,vn,!0)),Zn&&(this.addCurrentVertex(bn,Jr,-1,-1,vn,!0),this.addCurrentVertex(bn,Jr,0,0,vn)));if(Ua&&si<At-1){const Va=bn.dist(Zn);if(Va>2*cn){const Ka=bn.add(Zn.sub(bn)._mult(cn/Va)._round());this.updateDistance(bn,Ka),this.addCurrentVertex(Ka,Jr,0,0,vn),bn=Ka}}}}addCurrentVertex(_,k,X,de,Ge,ft=!1){const _t=k.y*de-k.x,At=-k.y-k.x*de;this.addHalfVertex(_,k.x+k.y*X,k.y-k.x*X,ft,!1,X,Ge),this.addHalfVertex(_,_t,At,ft,!0,-de,Ge)}addHalfVertex({x:_,y:k},X,de,Ge,ft,_t,At){this.layoutVertexArray.emplaceBack((_<<1)+(Ge?1:0),(k<<1)+(ft?1:0),Math.round(63*X)+128,Math.round(63*de)+128,1+(_t===0?0:_t<0?-1:1),0,this.lineSoFar),this.lineClips&&this.layoutVertexArray2.emplaceBack(this.scaledDistance,this.lineClipsArray.length,this.lineSoFar);const Nt=At.vertexLength++;this.e1>=0&&this.e2>=0&&(this.indexArray.emplaceBack(this.e1,this.e2,Nt),At.primitiveLength++),ft?this.e2=Nt:this.e1=Nt}updateScaledDistance(){if(this.lineClips){const _=this.totalDistance/(this.lineClips.end-this.lineClips.start);this.scaledDistance=this.distance/this.totalDistance,this.lineSoFar=_*this.lineClips.start+this.distance}else this.lineSoFar=this.distance}updateDistance(_,k){this.distance+=_.dist(k),this.updateScaledDistance()}}Zo(L3,"LineBucket",{omit:["layers","patternFeatures"]});const Fg=new Wn({"line-cap":new rn(ma.layout_line["line-cap"]),"line-join":new rn(ma.layout_line["line-join"]),"line-miter-limit":new Ot(ma.layout_line["line-miter-limit"]),"line-round-limit":new Ot(ma.layout_line["line-round-limit"]),"line-sort-key":new rn(ma.layout_line["line-sort-key"])});var lg={paint:new Wn({"line-opacity":new rn(ma.paint_line["line-opacity"]),"line-color":new rn(ma.paint_line["line-color"]),"line-translate":new Ot(ma.paint_line["line-translate"]),"line-translate-anchor":new Ot(ma.paint_line["line-translate-anchor"]),"line-width":new rn(ma.paint_line["line-width"]),"line-gap-width":new rn(ma.paint_line["line-gap-width"]),"line-offset":new rn(ma.paint_line["line-offset"]),"line-blur":new rn(ma.paint_line["line-blur"]),"line-dasharray":new Tn(ma.paint_line["line-dasharray"]),"line-pattern":new Tn(ma.paint_line["line-pattern"]),"line-gradient":new Bn(ma.paint_line["line-gradient"])}),layout:Fg};const ug=new class extends rn{possiblyEvaluate(D,_){return _=new Iu(Math.floor(_.zoom),{now:_.now,fadeDuration:_.fadeDuration,zoomHistory:_.zoomHistory,transition:_.transition}),super.possiblyEvaluate(D,_)}evaluate(D,_,k,X){return _=mt({},_,{zoom:Math.floor(_.zoom)}),super.evaluate(D,_,k,X)}}(lg.paint.properties["line-width"].specification);function r0(D,_){return _>0?_+2*D:D}ug.useIntegerZoom=!0;const Bg=Di([{name:"a_pos_offset",components:4,type:"Int16"},{name:"a_tex_size",components:4,type:"Uint16"},{name:"a_pixeloffset",components:4,type:"Int16"},{name:"a_z_tile_anchor",components:4,type:"Int16"}],4),Vg=Di([{name:"a_projected_pos",components:3,type:"Float32"}],4);Di([{name:"a_fade_opacity",components:1,type:"Uint32"}],4);const cg=Di([{name:"a_placed",components:2,type:"Uint8"},{name:"a_shift",components:2,type:"Float32"}]),dg=Di([{name:"a_size_scale",components:1,type:"Float32"},{name:"a_padding",components:2,type:"Float32"}]);Di([{type:"Int16",name:"projectedAnchorX"},{type:"Int16",name:"projectedAnchorY"},{type:"Int16",name:"projectedAnchorZ"},{type:"Int16",name:"tileAnchorX"},{type:"Int16",name:"tileAnchorY"},{type:"Float32",name:"x1"},{type:"Float32",name:"y1"},{type:"Float32",name:"x2"},{type:"Float32",name:"y2"},{type:"Int16",name:"padding"},{type:"Uint32",name:"featureIndex"},{type:"Uint16",name:"sourceLayerIndex"},{type:"Uint16",name:"bucketIndex"}]);const Ep=Di([{name:"a_pos",components:3,type:"Int16"},{name:"a_anchor_pos",components:2,type:"Int16"},{name:"a_extrude",components:2,type:"Int16"}],4),Ng=Di([{name:"a_pos_2f",components:2,type:"Float32"},{name:"a_radius",components:1,type:"Float32"},{name:"a_flags",components:2,type:"Int16"}],4);Di([{name:"triangle",components:3,type:"Uint16"}]),Di([{type:"Int16",name:"projectedAnchorX"},{type:"Int16",name:"projectedAnchorY"},{type:"Int16",name:"projectedAnchorZ"},{type:"Float32",name:"tileAnchorX"},{type:"Float32",name:"tileAnchorY"},{type:"Uint16",name:"glyphStartIndex"},{type:"Uint16",name:"numGlyphs"},{type:"Uint32",name:"vertexStartIndex"},{type:"Uint32",name:"lineStartIndex"},{type:"Uint32",name:"lineLength"},{type:"Uint16",name:"segment"},{type:"Uint16",name:"lowerSize"},{type:"Uint16",name:"upperSize"},{type:"Float32",name:"lineOffsetX"},{type:"Float32",name:"lineOffsetY"},{type:"Uint8",name:"writingMode"},{type:"Uint8",name:"placedOrientation"},{type:"Uint8",name:"hidden"},{type:"Uint32",name:"crossTileID"},{type:"Int16",name:"associatedIconIndex"},{type:"Uint8",name:"flipState"}]),Di([{type:"Int16",name:"projectedAnchorX"},{type:"Int16",name:"projectedAnchorY"},{type:"Int16",name:"projectedAnchorZ"},{type:"Float32",name:"tileAnchorX"},{type:"Float32",name:"tileAnchorY"},{type:"Int16",name:"rightJustifiedTextSymbolIndex"},{type:"Int16",name:"centerJustifiedTextSymbolIndex"},{type:"Int16",name:"leftJustifiedTextSymbolIndex"},{type:"Int16",name:"verticalPlacedTextSymbolIndex"},{type:"Int16",name:"placedIconSymbolIndex"},{type:"Int16",name:"verticalPlacedIconSymbolIndex"},{type:"Uint16",name:"key"},{type:"Uint16",name:"textBoxStartIndex"},{type:"Uint16",name:"textBoxEndIndex"},{type:"Uint16",name:"verticalTextBoxStartIndex"},{type:"Uint16",name:"verticalTextBoxEndIndex"},{type:"Uint16",name:"iconBoxStartIndex"},{type:"Uint16",name:"iconBoxEndIndex"},{type:"Uint16",name:"verticalIconBoxStartIndex"},{type:"Uint16",name:"verticalIconBoxEndIndex"},{type:"Uint16",name:"featureIndex"},{type:"Uint16",name:"numHorizontalGlyphVertices"},{type:"Uint16",name:"numVerticalGlyphVertices"},{type:"Uint16",name:"numIconVertices"},{type:"Uint16",name:"numVerticalIconVertices"},{type:"Uint16",name:"useRuntimeCollisionCircles"},{type:"Uint32",name:"crossTileID"},{type:"Float32",components:2,name:"textOffset"},{type:"Float32",name:"collisionCircleDiameter"}]),Di([{type:"Float32",name:"offsetX"}]),Di([{type:"Int16",name:"x"},{type:"Int16",name:"y"},{type:"Int16",name:"tileUnitDistanceFromAnchor"}]);var Ad=24;const Jp=128;function hg(D,_){const{expression:k}=_;if(k.kind==="constant")return{kind:"constant",layoutSize:k.evaluate(new Iu(D+1))};if(k.kind==="source")return{kind:"source"};{const{zoomStops:X,interpolationType:de}=k;let Ge=0;for(;Ge<X.length&&X[Ge]<=D;)Ge++;Ge=Math.max(0,Ge-1);let ft=Ge;for(;ft<X.length&&X[ft]<D+1;)ft++;ft=Math.min(X.length-1,ft);const _t=X[Ge],At=X[ft];return k.kind==="composite"?{kind:"composite",minZoom:_t,maxZoom:At,interpolationType:de}:{kind:"camera",minZoom:_t,maxZoom:At,minSize:k.evaluate(new Iu(_t)),maxSize:k.evaluate(new Iu(At)),interpolationType:de}}}function F3(D,{uSize:_,uSizeT:k},{lowerSize:X,upperSize:de}){return D.kind==="source"?X/Jp:D.kind==="composite"?Qe(X/Jp,de/Jp,k):_}function _m(D,_){let k=0,X=0;if(D.kind==="constant")X=D.layoutSize;else if(D.kind!=="source"){const{interpolationType:de,minZoom:Ge,maxZoom:ft}=D,_t=de?Te(Gs.interpolationFactor(de,_,Ge,ft),0,1):0;D.kind==="camera"?X=Qe(D.minSize,D.maxSize,_t):k=_t}return{uSizeT:k,uSize:X}}var Jm=Object.freeze({__proto__:null,getSizeData:hg,evaluateSizeForFeature:F3,evaluateSizeForZoom:_m,SIZE_PACK_FACTOR:Jp});function i0(D,_,k){return D.sections.forEach(X=>{X.text=function(de,Ge,ft){const _t=Ge.layout.get("text-transform").evaluate(ft,{});return _t==="uppercase"?de=de.toLocaleUpperCase():_t==="lowercase"&&(de=de.toLocaleLowerCase()),$c.applyArabicShaping&&(de=$c.applyArabicShaping(de)),de}(X.text,_,k)}),D}const B3={"!":"︕","#":"#",$:"$","%":"%","&":"&","(":"︵",")":"︶","*":"*","+":"+",",":"︐","-":"︲",".":"・","/":"/",":":"︓",";":"︔","<":"︿","=":"=",">":"﹀","?":"︖","@":"@","[":"﹇","\\":"\","]":"﹈","^":"^",_:"︳","`":"`","{":"︷","|":"―","}":"︸","~":"~","¢":"¢","£":"£","¥":"¥","¦":"¦","¬":"¬","¯":" ̄","–":"︲","—":"︱","‘":"﹃","’":"﹄","“":"﹁","”":"﹂","…":"︙","‧":"・","₩":"₩","、":"︑","。":"︒","〈":"︿","〉":"﹀","《":"︽","》":"︾","「":"﹁","」":"﹂","『":"﹃","』":"﹄","【":"︻","】":"︼","〔":"︹","〕":"︺","〖":"︗","〗":"︘","!":"︕","(":"︵",")":"︶",",":"︐","-":"︲",".":"・",":":"︓",";":"︔","<":"︿",">":"﹀","?":"︖","[":"﹇","]":"﹈","_":"︳","{":"︷","|":"―","}":"︸","⦅":"︵","⦆":"︶","。":"︒","「":"﹁","」":"﹂"};function Qm(D){return D==="︶"||D==="﹈"||D==="︸"||D==="﹄"||D==="﹂"||D==="︾"||D==="︼"||D==="︺"||D==="︘"||D==="﹀"||D==="︐"||D==="︓"||D==="︔"||D==="`"||D===" ̄"||D==="︑"||D==="︒"}function zg(D){return D==="︵"||D==="﹇"||D==="︷"||D==="﹃"||D==="﹁"||D==="︽"||D==="︻"||D==="︹"||D==="︗"||D==="︿"}var e3=function(D,_,k,X,de){var Ge,ft,_t=8*de-X-1,At=(1<<_t)-1,Nt=At>>1,cn=-7,vn=de-1,bn=-1,jn=D[_+vn];for(vn+=bn,Ge=jn&(1<<-cn)-1,jn>>=-cn,cn+=_t;cn>0;Ge=256*Ge+D[_+vn],vn+=bn,cn-=8);for(ft=Ge&(1<<-cn)-1,Ge>>=-cn,cn+=X;cn>0;ft=256*ft+D[_+vn],vn+=bn,cn-=8);if(Ge===0)Ge=1-Nt;else{if(Ge===At)return ft?NaN:1/0*(jn?-1:1);ft+=Math.pow(2,X),Ge-=Nt}return(jn?-1:1)*ft*Math.pow(2,Ge-X)},xm=function(D,_,k,X,de,Ge){var ft,_t,At,Nt=8*Ge-de-1,cn=(1<<Nt)-1,vn=cn>>1,bn=de===23?Math.pow(2,-24)-Math.pow(2,-77):0,jn=0,Zn=1,Br=_<0||_===0&&1/_<0?1:0;for(_=Math.abs(_),isNaN(_)||_===1/0?(_t=isNaN(_)?1:0,ft=cn):(ft=Math.floor(Math.log(_)/Math.LN2),_*(At=Math.pow(2,-ft))<1&&(ft--,At*=2),(_+=ft+vn>=1?bn/At:bn*Math.pow(2,1-vn))*At>=2&&(ft++,At/=2),ft+vn>=cn?(_t=0,ft=cn):ft+vn>=1?(_t=(_*At-1)*Math.pow(2,de),ft+=vn):(_t=_*Math.pow(2,vn-1)*Math.pow(2,de),ft=0));de>=8;D[k+jn]=255&_t,jn+=Zn,_t/=256,de-=8);for(ft=ft<<de|_t,Nt+=de;Nt>0;D[k+jn]=255&ft,jn+=Zn,ft/=256,Nt-=8);D[k+jn-Zn]|=128*Br},m3=rc;function rc(D){this.buf=ArrayBuffer.isView&&ArrayBuffer.isView(D)?D:new Uint8Array(D||0),this.pos=0,this.type=0,this.length=this.buf.length}rc.Varint=0,rc.Fixed64=1,rc.Bytes=2,rc.Fixed32=5;var jf=4294967296,pg=1/jf,fg=typeof TextDecoder>"u"?null:new TextDecoder("utf8");function Qp(D){return D.type===rc.Bytes?D.readVarint()+D.pos:D.pos+1}function bm(D,_,k){return k?4294967296*_+(D>>>0):4294967296*(_>>>0)+(D>>>0)}function a0(D,_,k){var X=_<=16383?1:_<=2097151?2:_<=268435455?3:Math.floor(Math.log(_)/(7*Math.LN2));k.realloc(X);for(var de=k.pos-1;de>=D;de--)k.buf[de+X]=k.buf[de]}function jg(D,_){for(var k=0;k<D.length;k++)_.writeVarint(D[k])}function b0(D,_){for(var k=0;k<D.length;k++)_.writeSVarint(D[k])}function w0(D,_){for(var k=0;k<D.length;k++)_.writeFloat(D[k])}function M0(D,_){for(var k=0;k<D.length;k++)_.writeDouble(D[k])}function C0(D,_){for(var k=0;k<D.length;k++)_.writeBoolean(D[k])}function S0(D,_){for(var k=0;k<D.length;k++)_.writeFixed32(D[k])}function T0(D,_){for(var k=0;k<D.length;k++)_.writeSFixed32(D[k])}function D0(D,_){for(var k=0;k<D.length;k++)_.writeFixed64(D[k])}function o0(D,_){for(var k=0;k<D.length;k++)_.writeSFixed64(D[k])}function Nd(D,_){return(D[_]|D[_+1]<<8|D[_+2]<<16)+16777216*D[_+3]}function t3(D,_,k){D[k]=_,D[k+1]=_>>>8,D[k+2]=_>>>16,D[k+3]=_>>>24}function Gg(D,_){return(D[_]|D[_+1]<<8|D[_+2]<<16)+(D[_+3]<<24)}function Ug(D,_,k){_.glyphs=[],D===1&&k.readMessage(mg,_)}function mg(D,_,k){if(D===3){const{id:X,bitmap:de,width:Ge,height:ft,left:_t,top:At,advance:Nt}=k.readMessage($g,{});_.glyphs.push({id:X,bitmap:new Th({width:Ge+6,height:ft+6},de),metrics:{width:Ge,height:ft,left:_t,top:At,advance:Nt}})}else D===4?_.ascender=k.readSVarint():D===5&&(_.descender=k.readSVarint())}function $g(D,_,k){D===1?_.id=k.readVarint():D===2?_.bitmap=k.readBytes():D===3?_.width=k.readVarint():D===4?_.height=k.readVarint():D===5?_.left=k.readSVarint():D===6?_.top=k.readSVarint():D===7&&(_.advance=k.readVarint())}function gg(D){let _=0,k=0;for(const ft of D)_+=ft.w*ft.h,k=Math.max(k,ft.w);D.sort((ft,_t)=>_t.h-ft.h);const X=[{x:0,y:0,w:Math.max(Math.ceil(Math.sqrt(_/.95)),k),h:1/0}];let de=0,Ge=0;for(const ft of D)for(let _t=X.length-1;_t>=0;_t--){const At=X[_t];if(!(ft.w>At.w||ft.h>At.h)){if(ft.x=At.x,ft.y=At.y,Ge=Math.max(Ge,ft.y+ft.h),de=Math.max(de,ft.x+ft.w),ft.w===At.w&&ft.h===At.h){const Nt=X.pop();_t<X.length&&(X[_t]=Nt)}else ft.h===At.h?(At.x+=ft.w,At.w-=ft.w):ft.w===At.w?(At.y+=ft.h,At.h-=ft.h):(X.push({x:At.x+ft.w,y:At.y,w:At.w-ft.w,h:ft.h}),At.y+=ft.h,At.h-=ft.h);break}}return{w:de,h:Ge,fill:_/(de*Ge)||0}}rc.prototype={destroy:function(){this.buf=null},readFields:function(D,_,k){for(k=k||this.length;this.pos<k;){var X=this.readVarint(),de=X>>3,Ge=this.pos;this.type=7&X,D(de,_,this),this.pos===Ge&&this.skip(X)}return _},readMessage:function(D,_){return this.readFields(D,_,this.readVarint()+this.pos)},readFixed32:function(){var D=Nd(this.buf,this.pos);return this.pos+=4,D},readSFixed32:function(){var D=Gg(this.buf,this.pos);return this.pos+=4,D},readFixed64:function(){var D=Nd(this.buf,this.pos)+Nd(this.buf,this.pos+4)*jf;return this.pos+=8,D},readSFixed64:function(){var D=Nd(this.buf,this.pos)+Gg(this.buf,this.pos+4)*jf;return this.pos+=8,D},readFloat:function(){var D=e3(this.buf,this.pos,!0,23,4);return this.pos+=4,D},readDouble:function(){var D=e3(this.buf,this.pos,!0,52,8);return this.pos+=8,D},readVarint:function(D){var _,k,X=this.buf;return _=127&(k=X[this.pos++]),k<128?_:(_|=(127&(k=X[this.pos++]))<<7,k<128?_:(_|=(127&(k=X[this.pos++]))<<14,k<128?_:(_|=(127&(k=X[this.pos++]))<<21,k<128?_:function(de,Ge,ft){var _t,At,Nt=ft.buf;if(_t=(112&(At=Nt[ft.pos++]))>>4,At<128||(_t|=(127&(At=Nt[ft.pos++]))<<3,At<128)||(_t|=(127&(At=Nt[ft.pos++]))<<10,At<128)||(_t|=(127&(At=Nt[ft.pos++]))<<17,At<128)||(_t|=(127&(At=Nt[ft.pos++]))<<24,At<128)||(_t|=(1&(At=Nt[ft.pos++]))<<31,At<128))return bm(de,_t,Ge);throw new Error("Expected varint not more than 10 bytes")}(_|=(15&(k=X[this.pos]))<<28,D,this))))},readVarint64:function(){return this.readVarint(!0)},readSVarint:function(){var D=this.readVarint();return D%2==1?(D+1)/-2:D/2},readBoolean:function(){return!!this.readVarint()},readString:function(){var D=this.readVarint()+this.pos,_=this.pos;return this.pos=D,D-_>=12&&fg?function(k,X,de){return fg.decode(k.subarray(X,de))}(this.buf,_,D):function(k,X,de){for(var Ge="",ft=X;ft<de;){var _t,At,Nt,cn=k[ft],vn=null,bn=cn>239?4:cn>223?3:cn>191?2:1;if(ft+bn>de)break;bn===1?cn<128&&(vn=cn):bn===2?(192&(_t=k[ft+1]))==128&&(vn=(31&cn)<<6|63&_t)<=127&&(vn=null):bn===3?(At=k[ft+2],(192&(_t=k[ft+1]))==128&&(192&At)==128&&((vn=(15&cn)<<12|(63&_t)<<6|63&At)<=2047||vn>=55296&&vn<=57343)&&(vn=null)):bn===4&&(At=k[ft+2],Nt=k[ft+3],(192&(_t=k[ft+1]))==128&&(192&At)==128&&(192&Nt)==128&&((vn=(15&cn)<<18|(63&_t)<<12|(63&At)<<6|63&Nt)<=65535||vn>=1114112)&&(vn=null)),vn===null?(vn=65533,bn=1):vn>65535&&(vn-=65536,Ge+=String.fromCharCode(vn>>>10&1023|55296),vn=56320|1023&vn),Ge+=String.fromCharCode(vn),ft+=bn}return Ge}(this.buf,_,D)},readBytes:function(){var D=this.readVarint()+this.pos,_=this.buf.subarray(this.pos,D);return this.pos=D,_},readPackedVarint:function(D,_){if(this.type!==rc.Bytes)return D.push(this.readVarint(_));var k=Qp(this);for(D=D||[];this.pos<k;)D.push(this.readVarint(_));return D},readPackedSVarint:function(D){if(this.type!==rc.Bytes)return D.push(this.readSVarint());var _=Qp(this);for(D=D||[];this.pos<_;)D.push(this.readSVarint());return D},readPackedBoolean:function(D){if(this.type!==rc.Bytes)return D.push(this.readBoolean());var _=Qp(this);for(D=D||[];this.pos<_;)D.push(this.readBoolean());return D},readPackedFloat:function(D){if(this.type!==rc.Bytes)return D.push(this.readFloat());var _=Qp(this);for(D=D||[];this.pos<_;)D.push(this.readFloat());return D},readPackedDouble:function(D){if(this.type!==rc.Bytes)return D.push(this.readDouble());var _=Qp(this);for(D=D||[];this.pos<_;)D.push(this.readDouble());return D},readPackedFixed32:function(D){if(this.type!==rc.Bytes)return D.push(this.readFixed32());var _=Qp(this);for(D=D||[];this.pos<_;)D.push(this.readFixed32());return D},readPackedSFixed32:function(D){if(this.type!==rc.Bytes)return D.push(this.readSFixed32());var _=Qp(this);for(D=D||[];this.pos<_;)D.push(this.readSFixed32());return D},readPackedFixed64:function(D){if(this.type!==rc.Bytes)return D.push(this.readFixed64());var _=Qp(this);for(D=D||[];this.pos<_;)D.push(this.readFixed64());return D},readPackedSFixed64:function(D){if(this.type!==rc.Bytes)return D.push(this.readSFixed64());var _=Qp(this);for(D=D||[];this.pos<_;)D.push(this.readSFixed64());return D},skip:function(D){var _=7&D;if(_===rc.Varint)for(;this.buf[this.pos++]>127;);else if(_===rc.Bytes)this.pos=this.readVarint()+this.pos;else if(_===rc.Fixed32)this.pos+=4;else{if(_!==rc.Fixed64)throw new Error("Unimplemented type: "+_);this.pos+=8}},writeTag:function(D,_){this.writeVarint(D<<3|_)},realloc:function(D){for(var _=this.length||16;_<this.pos+D;)_*=2;if(_!==this.length){var k=new Uint8Array(_);k.set(this.buf),this.buf=k,this.length=_}},finish:function(){return this.length=this.pos,this.pos=0,this.buf.subarray(0,this.length)},writeFixed32:function(D){this.realloc(4),t3(this.buf,D,this.pos),this.pos+=4},writeSFixed32:function(D){this.realloc(4),t3(this.buf,D,this.pos),this.pos+=4},writeFixed64:function(D){this.realloc(8),t3(this.buf,-1&D,this.pos),t3(this.buf,Math.floor(D*pg),this.pos+4),this.pos+=8},writeSFixed64:function(D){this.realloc(8),t3(this.buf,-1&D,this.pos),t3(this.buf,Math.floor(D*pg),this.pos+4),this.pos+=8},writeVarint:function(D){(D=+D||0)>268435455||D<0?function(_,k){var X,de;if(_>=0?(X=_%4294967296|0,de=_/4294967296|0):(de=~(-_/4294967296),4294967295^(X=~(-_%4294967296))?X=X+1|0:(X=0,de=de+1|0)),_>=18446744073709552e3||_<-18446744073709552e3)throw new Error("Given varint doesn't fit into 10 bytes");k.realloc(10),function(Ge,ft,_t){_t.buf[_t.pos++]=127&Ge|128,Ge>>>=7,_t.buf[_t.pos++]=127&Ge|128,Ge>>>=7,_t.buf[_t.pos++]=127&Ge|128,Ge>>>=7,_t.buf[_t.pos++]=127&Ge|128,_t.buf[_t.pos]=127&(Ge>>>=7)}(X,0,k),function(Ge,ft){var _t=(7&Ge)<<4;ft.buf[ft.pos++]|=_t|((Ge>>>=3)?128:0),Ge&&(ft.buf[ft.pos++]=127&Ge|((Ge>>>=7)?128:0),Ge&&(ft.buf[ft.pos++]=127&Ge|((Ge>>>=7)?128:0),Ge&&(ft.buf[ft.pos++]=127&Ge|((Ge>>>=7)?128:0),Ge&&(ft.buf[ft.pos++]=127&Ge|((Ge>>>=7)?128:0),Ge&&(ft.buf[ft.pos++]=127&Ge)))))}(de,k)}(D,this):(this.realloc(4),this.buf[this.pos++]=127&D|(D>127?128:0),D<=127||(this.buf[this.pos++]=127&(D>>>=7)|(D>127?128:0),D<=127||(this.buf[this.pos++]=127&(D>>>=7)|(D>127?128:0),D<=127||(this.buf[this.pos++]=D>>>7&127))))},writeSVarint:function(D){this.writeVarint(D<0?2*-D-1:2*D)},writeBoolean:function(D){this.writeVarint(!!D)},writeString:function(D){D=String(D),this.realloc(4*D.length),this.pos++;var _=this.pos;this.pos=function(X,de,Ge){for(var ft,_t,At=0;At<de.length;At++){if((ft=de.charCodeAt(At))>55295&&ft<57344){if(!_t){ft>56319||At+1===de.length?(X[Ge++]=239,X[Ge++]=191,X[Ge++]=189):_t=ft;continue}if(ft<56320){X[Ge++]=239,X[Ge++]=191,X[Ge++]=189,_t=ft;continue}ft=_t-55296<<10|ft-56320|65536,_t=null}else _t&&(X[Ge++]=239,X[Ge++]=191,X[Ge++]=189,_t=null);ft<128?X[Ge++]=ft:(ft<2048?X[Ge++]=ft>>6|192:(ft<65536?X[Ge++]=ft>>12|224:(X[Ge++]=ft>>18|240,X[Ge++]=ft>>12&63|128),X[Ge++]=ft>>6&63|128),X[Ge++]=63&ft|128)}return Ge}(this.buf,D,this.pos);var k=this.pos-_;k>=128&&a0(_,k,this),this.pos=_-1,this.writeVarint(k),this.pos+=k},writeFloat:function(D){this.realloc(4),xm(this.buf,D,this.pos,!0,23,4),this.pos+=4},writeDouble:function(D){this.realloc(8),xm(this.buf,D,this.pos,!0,52,8),this.pos+=8},writeBytes:function(D){var _=D.length;this.writeVarint(_),this.realloc(_);for(var k=0;k<_;k++)this.buf[this.pos++]=D[k]},writeRawMessage:function(D,_){this.pos++;var k=this.pos;D(_,this);var X=this.pos-k;X>=128&&a0(k,X,this),this.pos=k-1,this.writeVarint(X),this.pos+=X},writeMessage:function(D,_,k){this.writeTag(D,rc.Bytes),this.writeRawMessage(_,k)},writePackedVarint:function(D,_){_.length&&this.writeMessage(D,jg,_)},writePackedSVarint:function(D,_){_.length&&this.writeMessage(D,b0,_)},writePackedBoolean:function(D,_){_.length&&this.writeMessage(D,C0,_)},writePackedFloat:function(D,_){_.length&&this.writeMessage(D,w0,_)},writePackedDouble:function(D,_){_.length&&this.writeMessage(D,M0,_)},writePackedFixed32:function(D,_){_.length&&this.writeMessage(D,S0,_)},writePackedSFixed32:function(D,_){_.length&&this.writeMessage(D,T0,_)},writePackedFixed64:function(D,_){_.length&&this.writeMessage(D,D0,_)},writePackedSFixed64:function(D,_){_.length&&this.writeMessage(D,o0,_)},writeBytesField:function(D,_){this.writeTag(D,rc.Bytes),this.writeBytes(_)},writeFixed32Field:function(D,_){this.writeTag(D,rc.Fixed32),this.writeFixed32(_)},writeSFixed32Field:function(D,_){this.writeTag(D,rc.Fixed32),this.writeSFixed32(_)},writeFixed64Field:function(D,_){this.writeTag(D,rc.Fixed64),this.writeFixed64(_)},writeSFixed64Field:function(D,_){this.writeTag(D,rc.Fixed64),this.writeSFixed64(_)},writeVarintField:function(D,_){this.writeTag(D,rc.Varint),this.writeVarint(_)},writeSVarintField:function(D,_){this.writeTag(D,rc.Varint),this.writeSVarint(_)},writeStringField:function(D,_){this.writeTag(D,rc.Bytes),this.writeString(_)},writeFloatField:function(D,_){this.writeTag(D,rc.Fixed32),this.writeFloat(_)},writeDoubleField:function(D,_){this.writeTag(D,rc.Fixed64),this.writeDouble(_)},writeBooleanField:function(D,_){this.writeVarintField(D,!!_)}};class yg{constructor(_,{pixelRatio:k,version:X,stretchX:de,stretchY:Ge,content:ft}){this.paddedRect=_,this.pixelRatio=k,this.stretchX=de,this.stretchY=Ge,this.content=ft,this.version=X}get tl(){return[this.paddedRect.x+1,this.paddedRect.y+1]}get br(){return[this.paddedRect.x+this.paddedRect.w-1,this.paddedRect.y+this.paddedRect.h-1]}get displaySize(){return[(this.paddedRect.w-2)/this.pixelRatio,(this.paddedRect.h-2)/this.pixelRatio]}}class vg{constructor(_,k){const X={},de={};this.haveRenderCallbacks=[];const Ge=[];this.addImages(_,X,Ge),this.addImages(k,de,Ge);const{w:ft,h:_t}=gg(Ge),At=new Cd({width:ft||1,height:_t||1});for(const Nt in _){const cn=_[Nt],vn=X[Nt].paddedRect;Cd.copy(cn.data,At,{x:0,y:0},{x:vn.x+1,y:vn.y+1},cn.data)}for(const Nt in k){const cn=k[Nt],vn=de[Nt].paddedRect,bn=vn.x+1,jn=vn.y+1,Zn=cn.data.width,Br=cn.data.height;Cd.copy(cn.data,At,{x:0,y:0},{x:bn,y:jn},cn.data),Cd.copy(cn.data,At,{x:0,y:Br-1},{x:bn,y:jn-1},{width:Zn,height:1}),Cd.copy(cn.data,At,{x:0,y:0},{x:bn,y:jn+Br},{width:Zn,height:1}),Cd.copy(cn.data,At,{x:Zn-1,y:0},{x:bn-1,y:jn},{width:1,height:Br}),Cd.copy(cn.data,At,{x:0,y:0},{x:bn+Zn,y:jn},{width:1,height:Br})}this.image=At,this.iconPositions=X,this.patternPositions=de}addImages(_,k,X){for(const de in _){const Ge=_[de],ft={x:0,y:0,w:Ge.data.width+2,h:Ge.data.height+2};X.push(ft),k[de]=new yg(ft,Ge),Ge.hasRenderCallback&&this.haveRenderCallbacks.push(de)}}patchUpdatedImages(_,k){this.haveRenderCallbacks=this.haveRenderCallbacks.filter(X=>_.hasImage(X)),_.dispatchRenderCallbacks(this.haveRenderCallbacks);for(const X in _.updatedImages)this.patchUpdatedImage(this.iconPositions[X],_.getImage(X),k),this.patchUpdatedImage(this.patternPositions[X],_.getImage(X),k)}patchUpdatedImage(_,k,X){if(!_||!k||_.version===k.version)return;_.version=k.version;const[de,Ge]=_.tl;X.update(k.data,void 0,{x:de,y:Ge})}}Zo(yg,"ImagePosition"),Zo(vg,"ImageAtlas");const Gh={horizontal:1,vertical:2,horizontalOnly:3};class g3{constructor(){this.scale=1,this.fontStack="",this.imageName=null}static forText(_,k){const X=new g3;return X.scale=_||1,X.fontStack=k,X}static forImage(_){const k=new g3;return k.imageName=_,k}}class n3{constructor(){this.text="",this.sectionIndex=[],this.sections=[],this.imageSectionID=null}static fromFeature(_,k){const X=new n3;for(let de=0;de<_.sections.length;de++){const Ge=_.sections[de];Ge.image?X.addImageSection(Ge):X.addTextSection(Ge,k)}return X}length(){return this.text.length}getSection(_){return this.sections[this.sectionIndex[_]]}getSections(){return this.sections}getSectionIndex(_){return this.sectionIndex[_]}getCharCode(_){return this.text.charCodeAt(_)}verticalizePunctuation(_){this.text=function(k,X){let de="";for(let Ge=0;Ge<k.length;Ge++){const ft=k.charCodeAt(Ge+1)||null,_t=k.charCodeAt(Ge-1)||null;de+=!X&&(ft&&sd(ft)&&!B3[k[Ge+1]]||_t&&sd(_t)&&!B3[k[Ge-1]])||!B3[k[Ge]]?k[Ge]:B3[k[Ge]]}return de}(this.text,_)}trim(){let _=0;for(let X=0;X<this.text.length&&N3[this.text.charCodeAt(X)];X++)_++;let k=this.text.length;for(let X=this.text.length-1;X>=0&&X>=_&&N3[this.text.charCodeAt(X)];X--)k--;this.text=this.text.substring(_,k),this.sectionIndex=this.sectionIndex.slice(_,k)}substring(_,k){const X=new n3;return X.text=this.text.substring(_,k),X.sectionIndex=this.sectionIndex.slice(_,k),X.sections=this.sections,X}toString(){return this.text}getMaxScale(){return this.sectionIndex.reduce((_,k)=>Math.max(_,this.sections[k].scale),0)}addTextSection(_,k){this.text+=_.text,this.sections.push(g3.forText(_.scale,_.fontStack||k));const X=this.sections.length-1;for(let de=0;de<_.text.length;++de)this.sectionIndex.push(X)}addImageSection(_){const k=_.image?_.image.name:"";if(k.length===0)return void wn("Can't add FormattedSection with an empty image.");const X=this.getNextImageSectionCharCode();X?(this.text+=String.fromCharCode(X),this.sections.push(g3.forImage(k)),this.sectionIndex.push(this.sections.length-1)):wn("Reached maximum number of images 6401")}getNextImageSectionCharCode(){return this.imageSectionID?this.imageSectionID>=63743?null:++this.imageSectionID:(this.imageSectionID=57344,this.imageSectionID)}}function V3(D,_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn,Br){const Jr=n3.fromFeature(D,de);let si;vn===Gh.vertical&&Jr.verticalizePunctuation(bn);const{processBidirectionalText:Li,processStyledBidirectionalText:vi}=$c;if(Li&&Jr.sections.length===1){si=[];const ba=Li(Jr.toString(),y3(Jr,Nt,Ge,_,X,jn,Zn));for(const Ua of ba){const Ga=new n3;Ga.text=Ua,Ga.sections=Jr.sections;for(let ho=0;ho<Ua.length;ho++)Ga.sectionIndex.push(0);si.push(Ga)}}else if(vi){si=[];const ba=vi(Jr.text,Jr.sectionIndex,y3(Jr,Nt,Ge,_,X,jn,Zn));for(const Ua of ba){const Ga=new n3;Ga.text=Ua[0],Ga.sectionIndex=Ua[1],Ga.sections=Jr.sections,si.push(Ga)}}else si=function(ba,Ua){const Ga=[],ho=ba.text;let bo=0;for(const Va of Ua)Ga.push(ba.substring(bo,Va)),bo=Va;return bo<ho.length&&Ga.push(ba.substring(bo,ho.length)),Ga}(Jr,y3(Jr,Nt,Ge,_,X,jn,Zn));const ui=[],ua={positionedLines:ui,text:Jr.toString(),top:cn[1],bottom:cn[1],left:cn[0],right:cn[0],writingMode:vn,iconsInText:!1,verticalizable:!1,hasBaseline:!1};return function(ba,Ua,Ga,ho,bo,Va,Ka,Do,$o,Ro,No,Sl){let ru=0,El=0,Fl=0;const Vs=Do==="right"?1:Do==="left"?0:.5;let gs=!1;for(const Fu of bo){const fu=Fu.getSections();for(const ic of fu){if(ic.imageName)continue;const Kc=Ua[ic.fontStack];if(Kc&&(gs=Kc.ascender!==void 0&&Kc.descender!==void 0,!gs))break}if(!gs)break}let cu=0;for(const Fu of bo){Fu.trim();const fu=Fu.getMaxScale(),ic=(fu-1)*Ad,Kc={positionedGlyphs:[],lineOffset:0};ba.positionedLines[cu]=Kc;const id=Kc.positionedGlyphs;let Id=0;if(!Fu.length()){El+=Va,++cu;continue}let Yd=0,kp=0;for(let pc=0;pc<Fu.length();pc++){const Hh=Fu.getSection(pc),Pp=Fu.getSectionIndex(pc),ih=Fu.getCharCode(pc);let Zd=Hh.scale,zc=null,Ac=null,lp=null,Wh=Ad,gd=0;const qh=!($o===Gh.horizontal||!No&&!bd(ih)||No&&(N3[ih]||(Lu=ih,Ld(Lu)||Gd(Lu)||cc(Lu)||af(Lu)||pd(Lu))));if(Hh.imageName){const Eh=ho[Hh.imageName];if(!Eh)continue;lp=Hh.imageName,ba.iconsInText=ba.iconsInText||!0,Ac=Eh.paddedRect;const Kd=Eh.displaySize;Zd=Zd*Ad/Sl,zc={width:Kd[0],height:Kd[1],left:1,top:-3,advance:qh?Kd[1]:Kd[0],localGlyph:!1},gd=gs?-zc.height*Zd:fu*Ad-17-Kd[1]*Zd,Wh=zc.advance;const Mf=(qh?Kd[0]:Kd[1])*Zd-Ad*fu;Mf>0&&Mf>Id&&(Id=Mf)}else{const Eh=Ga[Hh.fontStack];if(!Eh)continue;Eh[ih]&&(Ac=Eh[ih]);const Kd=Ua[Hh.fontStack];if(!Kd)continue;const Mf=Kd.glyphs[ih];if(!Mf)continue;if(zc=Mf.metrics,Wh=ih!==8203?Ad:0,gs){const C3=Kd.ascender!==void 0?Math.abs(Kd.ascender):0,Qg=Kd.descender!==void 0?Math.abs(Kd.descender):0,e0=(C3+Qg)*Zd;Yd<e0&&(Yd=e0,kp=(C3-Qg)/2*Zd),gd=-C3*Zd}else gd=(fu-Zd)*Ad-17}qh?(ba.verticalizable=!0,id.push({glyph:ih,imageName:lp,x:ru,y:El+gd,vertical:qh,scale:Zd,localGlyph:zc.localGlyph,fontStack:Hh.fontStack,sectionIndex:Pp,metrics:zc,rect:Ac}),ru+=Wh*Zd+Ro):(id.push({glyph:ih,imageName:lp,x:ru,y:El+gd,vertical:qh,scale:Zd,localGlyph:zc.localGlyph,fontStack:Hh.fontStack,sectionIndex:Pp,metrics:zc,rect:Ac}),ru+=zc.advance*Zd+Ro)}id.length!==0&&(Fl=Math.max(ru-Ro,Fl),gs?G3(id,Vs,Id,kp,Va*fu/2):G3(id,Vs,Id,0,Va/2)),ru=0;const sp=Va*fu+Id;Kc.lineOffset=Math.max(Id,ic),El+=sp,++cu}var Lu;const kd=El,{horizontalAlign:Ec,verticalAlign:Pd}=j3(Ka);(function(Fu,fu,ic,Kc,id,Id){const Yd=(fu-ic)*id,kp=-Id*Kc;for(const sp of Fu)for(const pc of sp.positionedGlyphs)pc.x+=Yd,pc.y+=kp})(ba.positionedLines,Vs,Ec,Pd,Fl,kd),ba.top+=-Pd*kd,ba.bottom=ba.top+kd,ba.left+=-Ec*Fl,ba.right=ba.left+Fl,ba.hasBaseline=gs}(ua,_,k,X,si,ft,_t,At,vn,Nt,bn,Br),!function(ba){for(const Ua of ba)if(Ua.positionedGlyphs.length!==0)return!1;return!0}(ui)&&ua}const N3={9:!0,10:!0,11:!0,12:!0,13:!0,32:!0},_g={10:!0,32:!0,38:!0,40:!0,41:!0,43:!0,45:!0,47:!0,173:!0,183:!0,8203:!0,8208:!0,8211:!0,8231:!0};function xg(D,_,k,X,de,Ge){if(_.imageName){const ft=X[_.imageName];return ft?ft.displaySize[0]*_.scale*Ad/Ge+de:0}{const ft=k[_.fontStack],_t=ft&&ft.glyphs[D];return _t?_t.metrics.advance*_.scale+de:0}}function bg(D,_,k,X){const de=Math.pow(D-_,2);return X?D<_?de/2:2*de:de+Math.abs(k)*k}function s0(D,_,k){let X=0;return D===10&&(X-=1e4),k&&(X+=150),D!==40&&D!==65288||(X+=50),_!==41&&_!==65289||(X+=50),X}function z3(D,_,k,X,de,Ge){let ft=null,_t=bg(_,k,de,Ge);for(const At of X){const Nt=bg(_-At.x,k,de,Ge)+At.badness;Nt<=_t&&(ft=At,_t=Nt)}return{index:D,x:_,priorBreak:ft,badness:_t}}function Gf(D){return D?Gf(D.priorBreak).concat(D.index):[]}function y3(D,_,k,X,de,Ge,ft){if(Ge!=="point")return[];if(!D)return[];const _t=[],At=function(bn,jn,Zn,Br,Jr,si){let Li=0;for(let vi=0;vi<bn.length();vi++){const ui=bn.getSection(vi);Li+=xg(bn.getCharCode(vi),ui,Br,Jr,jn,si)}return Li/Math.max(1,Math.ceil(Li/Zn))}(D,_,k,X,de,ft),Nt=D.text.indexOf("")>=0;let cn=0;for(let bn=0;bn<D.length();bn++){const jn=D.getSection(bn),Zn=D.getCharCode(bn);if(N3[Zn]||(cn+=xg(Zn,jn,X,de,_,ft)),bn<D.length()-1){const Br=!((vn=Zn)<11904||!(qf(vn)||Ts(vn)||fp(vn)||rf(vn)||Xd(vn)||Jh(vn)||Bp(vn)||Ph(vn)||Kl(vn)||Vp(vn)||ql(vn)||gh(vn)||mh(vn)||pp(vn)||hp(vn)||Qh(vn)||Ih(vn)||Yf(vn)||Df(vn)||ep(vn)));(_g[Zn]||Br||jn.imageName)&&_t.push(z3(bn+1,cn,At,_t,s0(Zn,D.getCharCode(bn+1),Br&&Nt),!1))}}var vn;return Gf(z3(D.length(),cn,At,_t,0,!0))}function j3(D){let _=.5,k=.5;switch(D){case"right":case"top-right":case"bottom-right":_=1;break;case"left":case"top-left":case"bottom-left":_=0}switch(D){case"bottom":case"bottom-right":case"bottom-left":k=1;break;case"top":case"top-right":case"top-left":k=0}return{horizontalAlign:_,verticalAlign:k}}function G3(D,_,k,X,de){if(!(_||k||X||de))return;const Ge=D.length-1,ft=D[Ge],_t=(ft.x+ft.metrics.advance*ft.scale)*_;for(let At=0;At<=Ge;At++)D[At].x-=_t,D[At].y+=k+X+de}function wg(D,_,k){const{horizontalAlign:X,verticalAlign:de}=j3(k),Ge=_[0]-D.displaySize[0]*X,ft=_[1]-D.displaySize[1]*de;return{image:D,top:ft,bottom:ft+D.displaySize[1],left:Ge,right:Ge+D.displaySize[0]}}function l0(D,_,k,X,de,Ge){const ft=D.image;let _t;if(ft.content){const Jr=ft.content,si=ft.pixelRatio||1;_t=[Jr[0]/si,Jr[1]/si,ft.displaySize[0]-Jr[2]/si,ft.displaySize[1]-Jr[3]/si]}const At=_.left*Ge,Nt=_.right*Ge;let cn,vn,bn,jn;k==="width"||k==="both"?(jn=de[0]+At-X[3],vn=de[0]+Nt+X[1]):(jn=de[0]+(At+Nt-ft.displaySize[0])/2,vn=jn+ft.displaySize[0]);const Zn=_.top*Ge,Br=_.bottom*Ge;return k==="height"||k==="both"?(cn=de[1]+Zn-X[0],bn=de[1]+Br+X[2]):(cn=de[1]+(Zn+Br-ft.displaySize[1])/2,bn=cn+ft.displaySize[1]),{image:ft,top:cn,right:vn,bottom:bn,left:jn,collisionPadding:_t}}class _f extends G{constructor(_,k,X,de,Ge){super(_,k),this.angle=de,this.z=X,Ge!==void 0&&(this.segment=Ge)}clone(){return new _f(this.x,this.y,this.z,this.angle,this.segment)}}function Hg(D,_,k,X,de){if(_.segment===void 0)return!0;let Ge=_,ft=_.segment+1,_t=0;for(;_t>-k/2;){if(ft--,ft<0)return!1;_t-=D[ft].dist(Ge),Ge=D[ft]}_t+=D[ft].dist(D[ft+1]),ft++;const At=[];let Nt=0;for(;_t<k/2;){const cn=D[ft],vn=D[ft+1];if(!vn)return!1;let bn=D[ft-1].angleTo(cn)-cn.angleTo(vn);for(bn=Math.abs((bn+3*Math.PI)%(2*Math.PI)-Math.PI),At.push({distance:_t,angleDelta:bn}),Nt+=bn;_t-At[0].distance>X;)Nt-=At.shift().angleDelta;if(Nt>de)return!1;ft++,_t+=cn.dist(vn)}return!0}function U3(D){let _=0;for(let k=0;k<D.length-1;k++)_+=D[k].dist(D[k+1]);return _}function $3(D,_,k){return D?.6*_*k:0}function Mg(D,_){return Math.max(D?D.right-D.left:0,_?_.right-_.left:0)}function u0(D,_,k,X,de,Ge){const ft=$3(k,de,Ge),_t=Mg(k,X)*Ge;let At=0;const Nt=U3(D)/2;for(let cn=0;cn<D.length-1;cn++){const vn=D[cn],bn=D[cn+1],jn=vn.dist(bn);if(At+jn>Nt){const Zn=(Nt-At)/jn,Br=Qe(vn.x,bn.x,Zn),Jr=Qe(vn.y,bn.y,Zn),si=new _f(Br,Jr,0,bn.angleTo(vn),cn);return!ft||Hg(D,si,_t,ft,_)?si:void 0}At+=jn}}function Cg(D,_,k,X,de,Ge,ft,_t,At){const Nt=$3(X,Ge,ft),cn=Mg(X,de),vn=cn*ft,bn=D[0].x===0||D[0].x===At||D[0].y===0||D[0].y===At;return _-vn<_/4&&(_=vn+_/4),Wg(D,bn?_/2*_t%_:(cn/2+2*Ge)*ft*_t%_,_,Nt,k,vn,bn,!1,At)}function Wg(D,_,k,X,de,Ge,ft,_t,At){const Nt=Ge/2,cn=U3(D);let vn=0,bn=_-k,jn=[];for(let Zn=0;Zn<D.length-1;Zn++){const Br=D[Zn],Jr=D[Zn+1],si=Br.dist(Jr),Li=Jr.angleTo(Br);for(;bn+k<vn+si;){bn+=k;const vi=(bn-vn)/si,ui=Qe(Br.x,Jr.x,vi),ua=Qe(Br.y,Jr.y,vi);if(ui>=0&&ui<At&&ua>=0&&ua<At&&bn-Nt>=0&&bn+Nt<=cn){const ba=new _f(ui,ua,0,Li,Zn);ba._round(),X&&!Hg(D,ba,Ge,X,de)||jn.push(ba)}}vn+=si}return _t||jn.length||ft||(jn=Wg(D,vn/2,k,X,de,Ge,ft,!0,At)),jn}function H3(D,_,k,X,de){const Ge=[];for(let ft=0;ft<D.length;ft++){const _t=D[ft];let At;for(let Nt=0;Nt<_t.length-1;Nt++){let cn=_t[Nt],vn=_t[Nt+1];cn.x<_&&vn.x<_||(cn.x<_?cn=new G(_,cn.y+(_-cn.x)/(vn.x-cn.x)*(vn.y-cn.y))._round():vn.x<_&&(vn=new G(_,cn.y+(_-cn.x)/(vn.x-cn.x)*(vn.y-cn.y))._round()),cn.y<k&&vn.y<k||(cn.y<k?cn=new G(cn.x+(k-cn.y)/(vn.y-cn.y)*(vn.x-cn.x),k)._round():vn.y<k&&(vn=new G(cn.x+(k-cn.y)/(vn.y-cn.y)*(vn.x-cn.x),k)._round()),cn.x>=X&&vn.x>=X||(cn.x>=X?cn=new G(X,cn.y+(X-cn.x)/(vn.x-cn.x)*(vn.y-cn.y))._round():vn.x>=X&&(vn=new G(X,cn.y+(X-cn.x)/(vn.x-cn.x)*(vn.y-cn.y))._round()),cn.y>=de&&vn.y>=de||(cn.y>=de?cn=new G(cn.x+(de-cn.y)/(vn.y-cn.y)*(vn.x-cn.x),de)._round():vn.y>=de&&(vn=new G(cn.x+(de-cn.y)/(vn.y-cn.y)*(vn.x-cn.x),de)._round()),At&&cn.equals(At[At.length-1])||(At=[cn],Ge.push(At)),At.push(vn)))))}}return Ge}Zo(_f,"Anchor");const wm=1e20;function td(D,_,k,X,de,Ge,ft,_t,At){for(let Nt=_;Nt<_+X;Nt++)Sg(D,k*Ge+Nt,Ge,de,ft,_t,At);for(let Nt=k;Nt<k+de;Nt++)Sg(D,Nt*Ge+_,1,X,ft,_t,At)}function Sg(D,_,k,X,de,Ge,ft){Ge[0]=0,ft[0]=-wm,ft[1]=wm,de[0]=D[_];for(let _t=1,At=0,Nt=0;_t<X;_t++){de[_t]=D[_+_t*k];const cn=_t*_t;do{const vn=Ge[At];Nt=(de[_t]-de[vn]+cn-vn*vn)/(_t-vn)/2}while(Nt<=ft[At]&&--At>-1);At++,Ge[At]=_t,ft[At]=Nt,ft[At+1]=wm}for(let _t=0,At=0;_t<X;_t++){for(;ft[At+1]<_t;)At++;const Nt=Ge[At],cn=_t-Nt;D[_+_t*k]=de[Nt]+cn*cn}}const nd={none:0,ideographs:1,all:2};class Uf{constructor(_,k,X){this.requestManager=_,this.localGlyphMode=k,this.localFontFamily=X,this.entries={},this.localGlyphs={200:{},400:{},500:{},900:{}}}setURL(_){this.url=_}getGlyphs(_,k){const X=[];for(const de in _)for(const Ge of _[de])X.push({stack:de,id:Ge});ue(X,({stack:de,id:Ge},ft)=>{let _t=this.entries[de];_t||(_t=this.entries[de]={glyphs:{},requests:{},ranges:{},ascender:void 0,descender:void 0});let At=_t.glyphs[Ge];if(At!==void 0)return void ft(null,{stack:de,id:Ge,glyph:At});if(At=this._tinySDF(_t,de,Ge),At)return _t.glyphs[Ge]=At,void ft(null,{stack:de,id:Ge,glyph:At});const Nt=Math.floor(Ge/256);if(256*Nt>65535)return void ft(new Error("glyphs > 65535 not supported"));if(_t.ranges[Nt])return void ft(null,{stack:de,id:Ge,glyph:At});let cn=_t.requests[Nt];cn||(cn=_t.requests[Nt]=[],Uf.loadGlyphRange(de,Nt,this.url,this.requestManager,(vn,bn)=>{if(bn){_t.ascender=bn.ascender,_t.descender=bn.descender;for(const jn in bn.glyphs)this._doesCharSupportLocalGlyph(+jn)||(_t.glyphs[+jn]=bn.glyphs[+jn]);_t.ranges[Nt]=!0}for(const jn of cn)jn(vn,bn);delete _t.requests[Nt]})),cn.push((vn,bn)=>{vn?ft(vn):bn&&ft(null,{stack:de,id:Ge,glyph:bn.glyphs[Ge]||null})})},(de,Ge)=>{if(de)k(de);else if(Ge){const ft={};for(const{stack:_t,id:At,glyph:Nt}of Ge)ft[_t]===void 0&&(ft[_t]={}),ft[_t].glyphs===void 0&&(ft[_t].glyphs={}),ft[_t].glyphs[At]=Nt&&{id:Nt.id,bitmap:Nt.bitmap.clone(),metrics:Nt.metrics},ft[_t].ascender=this.entries[_t].ascender,ft[_t].descender=this.entries[_t].descender;k(null,ft)}})}_doesCharSupportLocalGlyph(_){return this.localGlyphMode!==nd.none&&(this.localGlyphMode===nd.all?!!this.localFontFamily:!!this.localFontFamily&&(Vp(_)||xd(_)||mh(_)||Ih(_)||Ph(_)))}_tinySDF(_,k,X){const de=this.localFontFamily;if(!de||!this._doesCharSupportLocalGlyph(X))return;let Ge=_.tinySDF;if(!Ge){let Br="400";/bold/i.test(k)?Br="900":/medium/i.test(k)?Br="500":/light/i.test(k)&&(Br="200"),Ge=_.tinySDF=new Uf.TinySDF({fontFamily:de,fontWeight:Br,fontSize:48,buffer:6,radius:16}),Ge.fontWeight=Br}if(this.localGlyphs[Ge.fontWeight][X])return this.localGlyphs[Ge.fontWeight][X];const ft=String.fromCharCode(X),{data:_t,width:At,height:Nt,glyphWidth:cn,glyphHeight:vn,glyphLeft:bn,glyphTop:jn,glyphAdvance:Zn}=Ge.draw(ft);return this.localGlyphs[Ge.fontWeight][X]={id:X,bitmap:new Th({width:At,height:Nt},_t),metrics:{width:cn/2,height:vn/2,left:bn/2,top:jn/2-27,advance:Zn/2,localGlyph:!0}}}}function Mm(D,_,k,X){const de=[],Ge=D.image,ft=Ge.pixelRatio,_t=Ge.paddedRect.w-2,At=Ge.paddedRect.h-2,Nt=D.right-D.left,cn=D.bottom-D.top,vn=Ge.stretchX||[[0,_t]],bn=Ge.stretchY||[[0,At]],jn=(Va,Ka)=>Va+Ka[1]-Ka[0],Zn=vn.reduce(jn,0),Br=bn.reduce(jn,0),Jr=_t-Zn,si=At-Br;let Li=0,vi=Zn,ui=0,ua=Br,ba=0,Ua=Jr,Ga=0,ho=si;if(Ge.content&&X){const Va=Ge.content;Li=v3(vn,0,Va[0]),ui=v3(bn,0,Va[1]),vi=v3(vn,Va[0],Va[2]),ua=v3(bn,Va[1],Va[3]),ba=Va[0]-Li,Ga=Va[1]-ui,Ua=Va[2]-Va[0]-vi,ho=Va[3]-Va[1]-ua}const bo=(Va,Ka,Do,$o)=>{const Ro=_3(Va.stretch-Li,vi,Nt,D.left),No=W3(Va.fixed-ba,Ua,Va.stretch,Zn),Sl=_3(Ka.stretch-ui,ua,cn,D.top),ru=W3(Ka.fixed-Ga,ho,Ka.stretch,Br),El=_3(Do.stretch-Li,vi,Nt,D.left),Fl=W3(Do.fixed-ba,Ua,Do.stretch,Zn),Vs=_3($o.stretch-ui,ua,cn,D.top),gs=W3($o.fixed-Ga,ho,$o.stretch,Br),cu=new G(Ro,Sl),Lu=new G(El,Sl),kd=new G(El,Vs),Ec=new G(Ro,Vs),Pd=new G(No/ft,ru/ft),Fu=new G(Fl/ft,gs/ft),fu=_*Math.PI/180;if(fu){const id=Math.sin(fu),Id=Math.cos(fu),Yd=[Id,-id,id,Id];cu._matMult(Yd),Lu._matMult(Yd),Ec._matMult(Yd),kd._matMult(Yd)}const ic=Va.stretch+Va.fixed,Kc=Ka.stretch+Ka.fixed;return{tl:cu,tr:Lu,bl:Ec,br:kd,tex:{x:Ge.paddedRect.x+1+ic,y:Ge.paddedRect.y+1+Kc,w:Do.stretch+Do.fixed-ic,h:$o.stretch+$o.fixed-Kc},writingMode:void 0,glyphOffset:[0,0],sectionIndex:0,pixelOffsetTL:Pd,pixelOffsetBR:Fu,minFontScaleX:Ua/ft/Nt,minFontScaleY:ho/ft/cn,isSDF:k}};if(X&&(Ge.stretchX||Ge.stretchY)){const Va=Tg(vn,Jr,Zn),Ka=Tg(bn,si,Br);for(let Do=0;Do<Va.length-1;Do++){const $o=Va[Do],Ro=Va[Do+1];for(let No=0;No<Ka.length-1;No++)de.push(bo($o,Ka[No],Ro,Ka[No+1]))}}else de.push(bo({fixed:0,stretch:-1},{fixed:0,stretch:-1},{fixed:0,stretch:_t+1},{fixed:0,stretch:At+1}));return de}function v3(D,_,k){let X=0;for(const de of D)X+=Math.max(_,Math.min(k,de[1]))-Math.max(_,Math.min(k,de[0]));return X}function Tg(D,_,k){const X=[{fixed:-1,stretch:0}];for(const[de,Ge]of D){const ft=X[X.length-1];X.push({fixed:de-ft.stretch,stretch:ft.stretch}),X.push({fixed:de-ft.stretch,stretch:ft.stretch+(Ge-de)})}return X.push({fixed:_+1,stretch:k}),X}function _3(D,_,k,X){return D/_*k+X}function W3(D,_,k,X){return D-_*k/X}function c0(D,_,k,X){const de=_+D.positionedLines[X].lineOffset;return X===0?k+de/2:k+(de+(_+D.positionedLines[X-1].lineOffset))/2}Uf.loadGlyphRange=function(D,_,k,X,de){const Ge=256*_,ft=Ge+255,_t=X.transformRequest(X.normalizeGlyphsURL(k).replace("{fontstack}",D).replace("{range}",`${Ge}-${ft}`),zr.Glyphs);ni(_t,(At,Nt)=>{if(At)de(At);else if(Nt){const cn={},vn=function(bn){return new m3(bn).readFields(Ug,{})}(Nt);for(const bn of vn.glyphs)cn[bn.id]=bn;de(null,{glyphs:cn,ascender:vn.ascender,descender:vn.descender})}})},Uf.TinySDF=class{constructor({fontSize:D=24,buffer:_=3,radius:k=8,cutoff:X=.25,fontFamily:de="sans-serif",fontWeight:Ge="normal",fontStyle:ft="normal"}){this.buffer=_,this.cutoff=X,this.radius=k;const _t=this.size=D+4*_,At=this._createCanvas(_t),Nt=this.ctx=At.getContext("2d",{willReadFrequently:!0});Nt.font=`${ft} ${Ge} ${D}px ${de}`,Nt.textBaseline="alphabetic",Nt.textAlign="left",Nt.fillStyle="black",this.gridOuter=new Float64Array(_t*_t),this.gridInner=new Float64Array(_t*_t),this.f=new Float64Array(_t),this.z=new Float64Array(_t+1),this.v=new Uint16Array(_t)}_createCanvas(D){const _=document.createElement("canvas");return _.width=_.height=D,_}draw(D){const{width:_,actualBoundingBoxAscent:k,actualBoundingBoxDescent:X,actualBoundingBoxLeft:de,actualBoundingBoxRight:Ge}=this.ctx.measureText(D),ft=Math.floor(k),_t=Math.min(this.size-this.buffer,Math.ceil(Ge-de)),At=Math.min(this.size-this.buffer,Math.ceil(k)+Math.ceil(X)),Nt=_t+2*this.buffer,cn=At+2*this.buffer,vn=Nt*cn,bn=new Uint8ClampedArray(vn),jn={data:bn,width:Nt,height:cn,glyphWidth:_t,glyphHeight:At,glyphTop:ft,glyphLeft:0,glyphAdvance:_};if(_t===0||At===0)return jn;const{ctx:Zn,buffer:Br,gridInner:Jr,gridOuter:si}=this;Zn.clearRect(Br,Br,_t,At),Zn.fillText(D,Br,Br+ft+1);const Li=Zn.getImageData(Br,Br,_t,At);si.fill(wm,0,vn),Jr.fill(0,0,vn);for(let vi=0;vi<At;vi++)for(let ui=0;ui<_t;ui++){const ua=Li.data[4*(vi*_t+ui)+3]/255;if(ua===0)continue;const ba=(vi+Br)*Nt+ui+Br;if(ua===1)si[ba]=0,Jr[ba]=wm;else{const Ua=.5-ua;si[ba]=Ua>0?Ua*Ua:0,Jr[ba]=Ua<0?Ua*Ua:0}}td(si,0,0,Nt,cn,Nt,this.f,this.v,this.z),td(Jr,Br,Br,_t,At,Nt,this.f,this.v,this.z);for(let vi=0;vi<vn;vi++){const ui=Math.sqrt(si[vi])-Math.sqrt(Jr[vi]);bn[vi]=Math.round(255-255*(ui/this.radius+this.cutoff))}return jn}};class r3{constructor(_=[],k=Dg){if(this.data=_,this.length=this.data.length,this.compare=k,this.length>0)for(let X=(this.length>>1)-1;X>=0;X--)this._down(X)}push(_){this.data.push(_),this.length++,this._up(this.length-1)}pop(){if(this.length===0)return;const _=this.data[0],k=this.data.pop();return this.length--,this.length>0&&(this.data[0]=k,this._down(0)),_}peek(){return this.data[0]}_up(_){const{data:k,compare:X}=this,de=k[_];for(;_>0;){const Ge=_-1>>1,ft=k[Ge];if(X(de,ft)>=0)break;k[_]=ft,_=Ge}k[_]=de}_down(_){const{data:k,compare:X}=this,de=this.length>>1,Ge=k[_];for(;_<de;){let ft=1+(_<<1),_t=k[ft];const At=ft+1;if(At<this.length&&X(k[At],_t)<0&&(ft=At,_t=k[At]),X(_t,Ge)>=0)break;k[_]=_t,_=ft}k[_]=Ge}}function Dg(D,_){return D<_?-1:D>_?1:0}function x3(D,_=1,k=!1){let X=1/0,de=1/0,Ge=-1/0,ft=-1/0;const _t=D[0];for(let jn=0;jn<_t.length;jn++){const Zn=_t[jn];(!jn||Zn.x<X)&&(X=Zn.x),(!jn||Zn.y<de)&&(de=Zn.y),(!jn||Zn.x>Ge)&&(Ge=Zn.x),(!jn||Zn.y>ft)&&(ft=Zn.y)}const At=Math.min(Ge-X,ft-de);let Nt=At/2;const cn=new r3([],Cm);if(At===0)return new G(X,de);for(let jn=X;jn<Ge;jn+=At)for(let Zn=de;Zn<ft;Zn+=At)cn.push(new Dh(jn+Nt,Zn+Nt,Nt,D));let vn=function(jn){let Zn=0,Br=0,Jr=0;const si=jn[0];for(let Li=0,vi=si.length,ui=vi-1;Li<vi;ui=Li++){const ua=si[Li],ba=si[ui],Ua=ua.x*ba.y-ba.x*ua.y;Br+=(ua.x+ba.x)*Ua,Jr+=(ua.y+ba.y)*Ua,Zn+=3*Ua}return new Dh(Br/Zn,Jr/Zn,0,jn)}(D),bn=cn.length;for(;cn.length;){const jn=cn.pop();(jn.d>vn.d||!vn.d)&&(vn=jn,k&&console.log("found best %d after %d probes",Math.round(1e4*jn.d)/1e4,bn)),jn.max-vn.d<=_||(Nt=jn.h/2,cn.push(new Dh(jn.p.x-Nt,jn.p.y-Nt,Nt,D)),cn.push(new Dh(jn.p.x+Nt,jn.p.y-Nt,Nt,D)),cn.push(new Dh(jn.p.x-Nt,jn.p.y+Nt,Nt,D)),cn.push(new Dh(jn.p.x+Nt,jn.p.y+Nt,Nt,D)),bn+=4)}return k&&(console.log(`num probes: ${bn}`),console.log(`best distance: ${vn.d}`)),vn.p}function Cm(D,_){return _.max-D.max}function Dh(D,_,k,X){this.p=new G(D,_),this.h=k,this.d=function(de,Ge){let ft=!1,_t=1/0;for(let At=0;At<Ge.length;At++){const Nt=Ge[At];for(let cn=0,vn=Nt.length,bn=vn-1;cn<vn;bn=cn++){const jn=Nt[cn],Zn=Nt[bn];jn.y>de.y!=Zn.y>de.y&&de.x<(Zn.x-jn.x)*(de.y-jn.y)/(Zn.y-jn.y)+jn.x&&(ft=!ft),_t=Math.min(_t,qp(de,jn,Zn))}}return(ft?1:-1)*Math.sqrt(_t)}(this.p,X),this.max=this.d+this.h*Math.SQRT2}const Eg=Number.POSITIVE_INFINITY,d0=Math.sqrt(2);function i3(D,_){return _[1]!==Eg?function(k,X,de){let Ge=0,ft=0;switch(X=Math.abs(X),de=Math.abs(de),k){case"top-right":case"top-left":case"top":ft=de-7;break;case"bottom-right":case"bottom-left":case"bottom":ft=7-de}switch(k){case"top-right":case"bottom-right":case"right":Ge=-X;break;case"top-left":case"bottom-left":case"left":Ge=X}return[Ge,ft]}(D,_[0],_[1]):function(k,X){let de=0,Ge=0;X<0&&(X=0);const ft=X/d0;switch(k){case"top-right":case"top-left":Ge=ft-7;break;case"bottom-right":case"bottom-left":Ge=7-ft;break;case"bottom":Ge=7-X;break;case"top":Ge=X-7}switch(k){case"top-right":case"bottom-right":de=-ft;break;case"top-left":case"bottom-left":de=ft;break;case"left":de=X;break;case"right":de=-X}return[de,Ge]}(D,_[0])}function nh(D,_,k,X,de,Ge,ft,_t,At,Nt){D.createArrays(),D.tilePixelRatio=Ml/(512*D.overscaling),D.compareText={},D.iconsNeedLinear=!1;const cn=D.layers[0].layout,vn=D.layers[0]._unevaluatedLayout._values,bn={};if(D.textSizeData.kind==="composite"){const{minZoom:Br,maxZoom:Jr}=D.textSizeData;bn.compositeTextSizes=[vn["text-size"].possiblyEvaluate(new Iu(Br),_t),vn["text-size"].possiblyEvaluate(new Iu(Jr),_t)]}if(D.iconSizeData.kind==="composite"){const{minZoom:Br,maxZoom:Jr}=D.iconSizeData;bn.compositeIconSizes=[vn["icon-size"].possiblyEvaluate(new Iu(Br),_t),vn["icon-size"].possiblyEvaluate(new Iu(Jr),_t)]}bn.layoutTextSize=vn["text-size"].possiblyEvaluate(new Iu(At+1),_t),bn.layoutIconSize=vn["icon-size"].possiblyEvaluate(new Iu(At+1),_t),bn.textMaxSize=vn["text-size"].possiblyEvaluate(new Iu(18),_t);const jn=cn.get("text-rotation-alignment")==="map"&&cn.get("symbol-placement")!=="point",Zn=cn.get("text-size");for(const Br of D.features){const Jr=cn.get("text-font").evaluate(Br,{},_t).join(","),si=Zn.evaluate(Br,{},_t),Li=bn.layoutTextSize.evaluate(Br,{},_t),vi=(bn.layoutIconSize.evaluate(Br,{},_t),{horizontal:{},vertical:void 0}),ui=Br.text;let ua,ba=[0,0];if(ui){const ho=ui.toString(),bo=cn.get("text-letter-spacing").evaluate(Br,{},_t)*Ad,Va=cn.get("text-line-height").evaluate(Br,{},_t)*Ad,Ka=Im(ho)?bo:0,Do=cn.get("text-anchor").evaluate(Br,{},_t),$o=cn.get("text-variable-anchor");if(!$o){const Fl=cn.get("text-radial-offset").evaluate(Br,{},_t);ba=Fl?i3(Do,[Fl*Ad,Eg]):cn.get("text-offset").evaluate(Br,{},_t).map(Vs=>Vs*Ad)}let Ro=jn?"center":cn.get("text-justify").evaluate(Br,{},_t);const No=cn.get("symbol-placement"),Sl=No==="point",ru=No==="point"?cn.get("text-max-width").evaluate(Br,{},_t)*Ad:0,El=Fl=>{D.allowVerticalPlacement&&Np(ho)&&(vi.vertical=V3(ui,_,k,de,Jr,ru,Va,Do,Fl,Ka,ba,Gh.vertical,!0,No,Li,si))};if(!jn&&$o){const Fl=Ro==="auto"?$o.map(gs=>Ag(gs)):[Ro];let Vs=!1;for(let gs=0;gs<Fl.length;gs++){const cu=Fl[gs];if(!vi.horizontal[cu])if(Vs)vi.horizontal[cu]=vi.horizontal[0];else{const Lu=V3(ui,_,k,de,Jr,ru,Va,"center",cu,Ka,ba,Gh.horizontal,!1,No,Li,si);Lu&&(vi.horizontal[cu]=Lu,Vs=Lu.positionedLines.length===1)}}El("left")}else{if(Ro==="auto"&&(Ro=Ag(Do)),Sl||cn.get("text-writing-mode").indexOf("horizontal")>=0||!Np(ho)){const Fl=V3(ui,_,k,de,Jr,ru,Va,Do,Ro,Ka,ba,Gh.horizontal,!1,No,Li,si);Fl&&(vi.horizontal[Ro]=Fl)}El(No==="point"?"left":Ro)}}let Ua=!1;if(Br.icon&&Br.icon.name){const ho=X[Br.icon.name];ho&&(ua=wg(de[Br.icon.name],cn.get("icon-offset").evaluate(Br,{},_t),cn.get("icon-anchor").evaluate(Br,{},_t)),Ua=ho.sdf,D.sdfIcons===void 0?D.sdfIcons=ho.sdf:D.sdfIcons!==ho.sdf&&wn("Style sheet warning: Cannot mix SDF and non-SDF icons in one buffer"),(ho.pixelRatio!==D.pixelRatio||cn.get("icon-rotate").constantOr(1)!==0)&&(D.iconsNeedLinear=!0))}const Ga=Sm(vi.horizontal)||vi.vertical;D.iconsInText||(D.iconsInText=!!Ga&&Ga.iconsInText),(Ga||ua)&&h0(D,Br,vi,ua,X,bn,Li,0,ba,Ua,ft,_t,Nt)}Ge&&D.generateCollisionDebugBuffers(At,D.collisionBoxArray)}function Ag(D){switch(D){case"right":case"top-right":case"bottom-right":return"right";case"left":case"top-left":case"bottom-left":return"left"}return"center"}function h0(D,_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn){let jn=Ge.textMaxSize.evaluate(_,{},vn);jn===void 0&&(jn=ft);const Zn=D.layers[0].layout,Br=Zn.get("icon-offset").evaluate(_,{},vn),Jr=Sm(k.horizontal)||k.vertical,si=ft/24,Li=D.tilePixelRatio*jn/24,vi=(Va=D.overscaling,D.zoom>18&&Va>2&&(Va>>=1),Math.max(Ml/(512*Va),1)*Zn.get("symbol-spacing")),ui=Zn.get("text-padding")*D.tilePixelRatio,ua=Zn.get("icon-padding")*D.tilePixelRatio,ba=ne(Zn.get("text-max-angle")),Ua=Zn.get("text-rotation-alignment")==="map"&&Zn.get("symbol-placement")!=="point",Ga=Zn.get("icon-rotation-alignment")==="map"&&Zn.get("symbol-placement")!=="point",ho=Zn.get("symbol-placement"),bo=vi/2;var Va;const Ka=Zn.get("icon-text-fit");let Do;X&&Ka!=="none"&&(D.allowVerticalPlacement&&k.vertical&&(Do=l0(X,k.vertical,Ka,Zn.get("icon-text-fit-padding"),Br,si)),Jr&&(X=l0(X,Jr,Ka,Zn.get("icon-text-fit-padding"),Br,si)));const $o=(Ro,No,Sl)=>{if(No.x<0||No.x>=Ml||No.y<0||No.y>=Ml)return;const{x:ru,y:El,z:Fl}=bn.projectTilePoint(No.x,No.y,Sl),Vs=new _f(ru,El,Fl,0,void 0);(function(gs,cu,Lu,kd,Ec,Pd,Fu,fu,ic,Kc,id,Id,Yd,kp,sp,pc,Hh,Pp,ih,Zd,zc,Ac,lp,Wh,gd){const qh=gs.addToLineVertexArray(cu,kd);let Eh,Kd,Mf,C3,Qg,e0,L0,F0=0,B0=0,V0=0,N0=0,A0=-1,k0=-1;const km={};let z0=Hd(""),P0=0,I0=0;if(ic._unevaluatedLayout.getValue("text-radial-offset")===void 0?[P0,I0]=ic.layout.get("text-offset").evaluate(zc,{},gd).map(Ip=>Ip*Ad):(P0=ic.layout.get("text-radial-offset").evaluate(zc,{},gd)*Ad,I0=Eg),gs.allowVerticalPlacement&&Ec.vertical){const Ip=Ec.vertical;if(sp)e0=Y3(Ip),fu&&(L0=Y3(fu));else{const Rp=ic.layout.get("text-rotate").evaluate(zc,{},gd)+90;Mf=bf(Kc,Lu,cu,id,Id,Yd,Ip,kp,Rp,pc),fu&&(C3=bf(Kc,Lu,cu,id,Id,Yd,fu,Pp,Rp))}}if(Pd){const Ip=ic.layout.get("icon-rotate").evaluate(zc,{},gd),Rp=ic.layout.get("icon-text-fit")!=="none",t0=Mm(Pd,Ip,lp,Rp),O0=fu?Mm(fu,Ip,lp,Rp):void 0;Kd=bf(Kc,Lu,cu,id,Id,Yd,Pd,Pp,Ip),F0=4*t0.length;const j0=gs.iconSizeData;let X3=null;j0.kind==="source"?(X3=[Jp*ic.layout.get("icon-size").evaluate(zc,{},gd)],X3[0]>xf&&wn(`${gs.layerIds[0]}: Value for "icon-size" is >= 255. Reduce your "icon-size".`)):j0.kind==="composite"&&(X3=[Jp*Ac.compositeIconSizes[0].evaluate(zc,{},gd),Jp*Ac.compositeIconSizes[1].evaluate(zc,{},gd)],(X3[0]>xf||X3[1]>xf)&&wn(`${gs.layerIds[0]}: Value for "icon-size" is >= 255. Reduce your "icon-size".`)),gs.addSymbols(gs.icon,t0,X3,Zd,ih,zc,!1,Lu,cu,qh.lineStartIndex,qh.lineLength,-1,Wh,gd),A0=gs.icon.placedSymbolArray.length-1,O0&&(B0=4*O0.length,gs.addSymbols(gs.icon,O0,X3,Zd,ih,zc,Gh.vertical,Lu,cu,qh.lineStartIndex,qh.lineLength,-1,Wh,gd),k0=gs.icon.placedSymbolArray.length-1)}for(const Ip in Ec.horizontal){const Rp=Ec.horizontal[Ip];Eh||(z0=Hd(Rp.text),sp?Qg=Y3(Rp):Eh=bf(Kc,Lu,cu,id,Id,Yd,Rp,kp,ic.layout.get("text-rotate").evaluate(zc,{},gd),pc));const t0=Rp.positionedLines.length===1;if(V0+=q3(gs,Lu,cu,Rp,Fu,ic,sp,zc,pc,qh,Ec.vertical?Gh.horizontal:Gh.horizontalOnly,t0?Object.keys(Ec.horizontal):[Ip],km,A0,Ac,Wh,gd),t0)break}Ec.vertical&&(N0+=q3(gs,Lu,cu,Ec.vertical,Fu,ic,sp,zc,pc,qh,Gh.vertical,["vertical"],km,k0,Ac,Wh,gd));let S3=-1;const R0=(Ip,Rp)=>Ip?Math.max(Ip,Rp):Rp;S3=R0(Qg,S3),S3=R0(e0,S3),S3=R0(L0,S3);const U0=S3>-1?1:0;gs.glyphOffsetArray.length>=Hf.MAX_GLYPHS&&wn("Too many glyphs being rendered in a tile. See https://github.com/mapbox/mapbox-gl-js/issues/2907"),zc.sortKey!==void 0&&gs.addToSortKeyRanges(gs.symbolInstances.length,zc.sortKey),gs.symbolInstances.emplaceBack(Lu.x,Lu.y,Lu.z,cu.x,cu.y,km.right>=0?km.right:-1,km.center>=0?km.center:-1,km.left>=0?km.left:-1,km.vertical>=0?km.vertical:-1,A0,k0,z0,Eh!==void 0?Eh:gs.collisionBoxArray.length,Eh!==void 0?Eh+1:gs.collisionBoxArray.length,Mf!==void 0?Mf:gs.collisionBoxArray.length,Mf!==void 0?Mf+1:gs.collisionBoxArray.length,Kd!==void 0?Kd:gs.collisionBoxArray.length,Kd!==void 0?Kd+1:gs.collisionBoxArray.length,C3||gs.collisionBoxArray.length,C3?C3+1:gs.collisionBoxArray.length,id,V0,N0,F0,B0,U0,0,P0,I0,S3)})(D,No,Vs,Ro,k,X,de,Do,D.layers[0],D.collisionBoxArray,_.index,_.sourceLayerIndex,D.index,ui,Ua,At,0,ua,Ga,Br,_,Ge,Nt,cn,vn)};if(ho==="line")for(const Ro of H3(_.geometry,0,0,Ml,Ml)){const No=Cg(Ro,vi,ba,k.vertical||Jr,X,24,Li,D.overscaling,Ml);for(const Sl of No){const ru=Jr;ru&&Z3(D,ru.text,bo,Sl)||$o(Ro,Sl,vn)}}else if(ho==="line-center"){for(const Ro of _.geometry)if(Ro.length>1){const No=u0(Ro,ba,k.vertical||Jr,X,24,Li);No&&$o(Ro,No,vn)}}else if(_.type==="Polygon")for(const Ro of Mo(_.geometry,0)){const No=x3(Ro,16);$o(Ro[0],new _f(No.x,No.y,0,0,void 0),vn)}else if(_.type==="LineString")for(const Ro of _.geometry)$o(Ro,new _f(Ro[0].x,Ro[0].y,0,0,void 0),vn);else if(_.type==="Point")for(const Ro of _.geometry)for(const No of Ro)$o([No],new _f(No.x,No.y,0,0,void 0),vn)}const xf=32640;function q3(D,_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn,Br,Jr){const si=function(ui,ua,ba,Ua,Ga,ho,bo,Va){const Ka=[];if(ua.positionedLines.length===0)return Ka;const Do=Ua.layout.get("text-rotate").evaluate(ho,{})*Math.PI/180,$o=function(El){const Fl=El[0],Vs=El[1],gs=Fl*Vs;return gs>0?[Fl,-Vs]:gs<0?[-Fl,Vs]:Fl===0?[Vs,Fl]:[Vs,-Fl]}(ba);let Ro=Math.abs(ua.top-ua.bottom);for(const El of ua.positionedLines)Ro-=El.lineOffset;const No=ua.positionedLines.length,Sl=Ro/No;let ru=ua.top-ba[1];for(let El=0;El<No;++El){const Fl=ua.positionedLines[El];ru=c0(ua,Sl,ru,El);for(const Vs of Fl.positionedGlyphs){if(!Vs.rect)continue;const gs=Vs.rect||{};let cu=4,Lu=!0,kd=1,Ec=0;if(Vs.imageName){const Ac=bo[Vs.imageName];if(!Ac)continue;if(Ac.sdf){wn("SDF images are not supported in formatted text and will be ignored.");continue}Lu=!1,kd=Ac.pixelRatio,cu=1/kd}const Pd=(Ga||Va)&&Vs.vertical,Fu=Vs.metrics.advance*Vs.scale/2,fu=Vs.metrics,ic=Vs.rect;if(ic===null)continue;Va&&ua.verticalizable&&(Ec=Vs.imageName?Fu-Vs.metrics.width*Vs.scale/2:0);const Kc=Ga?[Vs.x+Fu,Vs.y]:[0,0];let id=[0,0],Id=[0,0],Yd=!1;Ga||(Pd?(Id=[Vs.x+Fu+$o[0],Vs.y+$o[1]-Ec],Yd=!0):id=[Vs.x+Fu+ba[0],Vs.y+ba[1]-Ec]);const kp=ic.w*Vs.scale/(kd*(Vs.localGlyph?2:1)),sp=ic.h*Vs.scale/(kd*(Vs.localGlyph?2:1));let pc,Hh,Pp,ih;if(Pd){const Ac=Vs.y-ru,lp=new G(-Fu,Fu-Ac),Wh=-Math.PI/2,gd=new G(...Id);pc=new G(-Fu+id[0],id[1]),pc._rotateAround(Wh,lp)._add(gd),pc.x+=-Ac+Fu,pc.y-=(fu.left-cu)*Vs.scale;const qh=Vs.imageName?fu.advance*Vs.scale:Ad*Vs.scale,Eh=String.fromCharCode(Vs.glyph);Qm(Eh)?pc.x+=(1-cu)*Vs.scale:zg(Eh)?pc.x+=qh-fu.height*Vs.scale+(-cu-1)*Vs.scale:pc.x+=Vs.imageName||fu.width+2*cu===ic.w&&fu.height+2*cu===ic.h?(qh-sp)/2:(qh-(fu.height+2*cu)*Vs.scale)/2,Hh=new G(pc.x,pc.y-kp),Pp=new G(pc.x+sp,pc.y),ih=new G(pc.x+sp,pc.y-kp)}else{const Ac=(fu.left-cu)*Vs.scale-Fu+id[0],lp=(-fu.top-cu)*Vs.scale+id[1],Wh=Ac+kp,gd=lp+sp;pc=new G(Ac,lp),Hh=new G(Wh,lp),Pp=new G(Ac,gd),ih=new G(Wh,gd)}if(Do){let Ac;Ac=Ga?new G(0,0):Yd?new G($o[0],$o[1]):new G(ba[0],ba[1]),pc._rotateAround(Do,Ac),Hh._rotateAround(Do,Ac),Pp._rotateAround(Do,Ac),ih._rotateAround(Do,Ac)}const Zd=new G(0,0),zc=new G(0,0);Ka.push({tl:pc,tr:Hh,bl:Pp,br:ih,tex:gs,writingMode:ua.writingMode,glyphOffset:Kc,sectionIndex:Vs.sectionIndex,isSDF:Lu,pixelOffsetTL:Zd,pixelOffsetBR:zc,minFontScaleX:0,minFontScaleY:0})}}return Ka}(0,X,At,Ge,ft,_t,de,D.allowVerticalPlacement),Li=D.textSizeData;let vi=null;Li.kind==="source"?(vi=[Jp*Ge.layout.get("text-size").evaluate(_t,{},Jr)],vi[0]>xf&&wn(`${D.layerIds[0]}: Value for "text-size" is >= 255. Reduce your "text-size".`)):Li.kind==="composite"&&(vi=[Jp*Zn.compositeTextSizes[0].evaluate(_t,{},Jr),Jp*Zn.compositeTextSizes[1].evaluate(_t,{},Jr)],(vi[0]>xf||vi[1]>xf)&&wn(`${D.layerIds[0]}: Value for "text-size" is >= 255. Reduce your "text-size".`)),D.addSymbols(D.text,si,vi,At,ft,_t,cn,_,k,Nt.lineStartIndex,Nt.lineLength,jn,Br,Jr);for(const ui of vn)bn[ui]=D.text.placedSymbolArray.length-1;return 4*si.length}function Sm(D){for(const _ in D)return D[_];return null}function bf(D,_,k,X,de,Ge,ft,_t,At,Nt){let cn=ft.top,vn=ft.bottom,bn=ft.left,jn=ft.right;const Zn=ft.collisionPadding;if(Zn&&(bn-=Zn[0],cn-=Zn[1],jn+=Zn[2],vn+=Zn[3]),At){const Br=new G(bn,cn),Jr=new G(jn,cn),si=new G(bn,vn),Li=new G(jn,vn),vi=ne(At);let ui=new G(0,0);Nt&&(ui=new G(Nt[0],Nt[1])),Br._rotateAround(vi,ui),Jr._rotateAround(vi,ui),si._rotateAround(vi,ui),Li._rotateAround(vi,ui),bn=Math.min(Br.x,Jr.x,si.x,Li.x),jn=Math.max(Br.x,Jr.x,si.x,Li.x),cn=Math.min(Br.y,Jr.y,si.y,Li.y),vn=Math.max(Br.y,Jr.y,si.y,Li.y)}return D.emplaceBack(_.x,_.y,_.z,k.x,k.y,bn,cn,jn,vn,_t,X,de,Ge),D.length-1}function Y3(D){D.collisionPadding&&(D.top-=D.collisionPadding[1],D.bottom+=D.collisionPadding[3]);const _=D.bottom-D.top;return _>0?Math.max(10,_):null}function Z3(D,_,k,X){const de=D.compareText;if(_ in de){const Ge=de[_];for(let ft=Ge.length-1;ft>=0;ft--)if(X.dist(Ge[ft])<k)return!0}else de[_]=[];return de[_].push(X),!1}const p0=Vd.VectorTileFeature.types,kg=[{name:"a_fade_opacity",components:1,type:"Uint8",offset:0}];function a3(D,_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn,Br){const Jr=cn?Math.min(xf,Math.round(cn[0])):0,si=cn?Math.min(xf,Math.round(cn[1])):0;D.emplaceBack(_,k,Math.round(32*ft),Math.round(32*_t),At,Nt,(Jr<<1)+(vn?1:0),si,16*bn,16*jn,256*Zn,256*Br,X,de,Ge,0)}function Mc(D,_,k){D.emplaceBack(_.x,_.y,k),D.emplaceBack(_.x,_.y,k),D.emplaceBack(_.x,_.y,k),D.emplaceBack(_.x,_.y,k)}function qg(D){for(const _ of D.sections)if(Om(_.text))return!0;return!1}class $f{constructor(_){this.layoutVertexArray=new ja,this.indexArray=new rs,this.programConfigurations=_,this.segments=new hc,this.dynamicLayoutVertexArray=new To,this.opacityVertexArray=new na,this.placedSymbolArray=new Vh}isEmpty(){return this.layoutVertexArray.length===0&&this.indexArray.length===0&&this.dynamicLayoutVertexArray.length===0&&this.opacityVertexArray.length===0}upload(_,k,X,de){this.isEmpty()||(X&&(this.layoutVertexBuffer=_.createVertexBuffer(this.layoutVertexArray,Bg.members),this.indexBuffer=_.createIndexBuffer(this.indexArray,k),this.dynamicLayoutVertexBuffer=_.createVertexBuffer(this.dynamicLayoutVertexArray,Vg.members,!0),this.opacityVertexBuffer=_.createVertexBuffer(this.opacityVertexArray,kg,!0),this.opacityVertexBuffer.itemSize=1),(X||de)&&this.programConfigurations.upload(_))}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy(),this.dynamicLayoutVertexBuffer.destroy(),this.opacityVertexBuffer.destroy())}}Zo($f,"SymbolBuffers");class Tm{constructor(_,k,X){this.layoutVertexArray=new _,this.layoutAttributes=k,this.indexArray=new X,this.segments=new hc,this.collisionVertexArray=new Za,this.collisionVertexArrayExt=new To}upload(_){this.layoutVertexBuffer=_.createVertexBuffer(this.layoutVertexArray,this.layoutAttributes),this.indexBuffer=_.createIndexBuffer(this.indexArray),this.collisionVertexBuffer=_.createVertexBuffer(this.collisionVertexArray,cg.members,!0),this.collisionVertexBufferExt=_.createVertexBuffer(this.collisionVertexArrayExt,dg.members,!0)}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.segments.destroy(),this.collisionVertexBuffer.destroy(),this.collisionVertexBufferExt.destroy())}}Zo(Tm,"CollisionBuffers");class Hf{constructor(_){this.collisionBoxArray=_.collisionBoxArray,this.zoom=_.zoom,this.overscaling=_.overscaling,this.layers=_.layers,this.layerIds=this.layers.map(ft=>ft.id),this.index=_.index,this.pixelRatio=_.pixelRatio,this.sourceLayerIndex=_.sourceLayerIndex,this.hasPattern=!1,this.hasRTLText=!1,this.fullyClipped=!1,this.sortKeyRanges=[],this.collisionCircleArray=[],this.placementInvProjMatrix=ld([]),this.placementViewportMatrix=ld([]);const k=this.layers[0]._unevaluatedLayout._values;this.textSizeData=hg(this.zoom,k["text-size"]),this.iconSizeData=hg(this.zoom,k["icon-size"]);const X=this.layers[0].layout,de=X.get("symbol-sort-key"),Ge=X.get("symbol-z-order");this.canOverlap=X.get("text-allow-overlap")||X.get("icon-allow-overlap")||X.get("text-ignore-placement")||X.get("icon-ignore-placement"),this.sortFeaturesByKey=Ge!=="viewport-y"&&de.constantOr(1)!==void 0,this.sortFeaturesByY=(Ge==="viewport-y"||Ge==="auto"&&!this.sortFeaturesByKey)&&this.canOverlap,this.writingModes=X.get("text-writing-mode").map(ft=>Gh[ft]),this.stateDependentLayerIds=this.layers.filter(ft=>ft.isStateDependent()).map(ft=>ft.id),this.sourceID=_.sourceID,this.projection=_.projection}createArrays(){this.text=new $f(new Up(this.layers,this.zoom,_=>/^text/.test(_))),this.icon=new $f(new Up(this.layers,this.zoom,_=>/^icon/.test(_))),this.glyphOffsetArray=new tu,this.lineVertexArray=new tc,this.symbolInstances=new ec}calculateGlyphDependencies(_,k,X,de,Ge){for(let ft=0;ft<_.length;ft++)if(k[_.charCodeAt(ft)]=!0,de&&Ge){const _t=B3[_.charAt(ft)];_t&&(k[_t.charCodeAt(0)]=!0)}}populate(_,k,X,de){const Ge=this.layers[0],ft=Ge.layout,_t=ft.get("text-font"),At=ft.get("text-field"),Nt=ft.get("icon-image"),cn=(At.value.kind!=="constant"||At.value.value instanceof Go&&!At.value.value.isEmpty()||At.value.value.toString().length>0)&&(_t.value.kind!=="constant"||_t.value.value.length>0),vn=Nt.value.kind!=="constant"||!!Nt.value.value||Object.keys(Nt.parameters).length>0,bn=ft.get("symbol-sort-key");if(this.features=[],!cn&&!vn)return;const jn=k.iconDependencies,Zn=k.glyphDependencies,Br=k.availableImages,Jr=new Iu(this.zoom);for(const{feature:si,id:Li,index:vi,sourceLayerIndex:ui}of _){const ua=Ge._featureFilter.needGeometry,ba=vp(si,ua);if(!Ge._featureFilter.filter(Jr,ba,X))continue;let Ua,Ga;if(ua||(ba.geometry=bh(si,X,de)),cn){const bo=Ge.getValueAndResolveTokens("text-field",ba,X,Br),Va=Go.factory(bo);qg(Va)&&(this.hasRTLText=!0),(!this.hasRTLText||Af()==="unavailable"||this.hasRTLText&&$c.isParsed())&&(Ua=i0(Va,Ge,ba))}if(vn){const bo=Ge.getValueAndResolveTokens("icon-image",ba,X,Br);Ga=bo instanceof Uo?bo:Uo.fromString(bo)}if(!Ua&&!Ga)continue;const ho=this.sortFeaturesByKey?bn.evaluate(ba,{},X):void 0;if(this.features.push({id:Li,text:Ua,icon:Ga,index:vi,sourceLayerIndex:ui,geometry:ba.geometry,properties:si.properties,type:p0[si.type],sortKey:ho}),Ga&&(jn[Ga.name]=!0),Ua){const bo=_t.evaluate(ba,{},X).join(","),Va=ft.get("text-rotation-alignment")==="map"&&ft.get("symbol-placement")!=="point";this.allowVerticalPlacement=this.writingModes&&this.writingModes.indexOf(Gh.vertical)>=0;for(const Ka of Ua.sections)if(Ka.image)jn[Ka.image.name]=!0;else{const Do=Np(Ua.toString()),$o=Ka.fontStack||bo,Ro=Zn[$o]=Zn[$o]||{};this.calculateGlyphDependencies(Ka.text,Ro,Va,this.allowVerticalPlacement,Do)}}}ft.get("symbol-placement")==="line"&&(this.features=function(si){const Li={},vi={},ui=[];let ua=0;function ba(bo){ui.push(si[bo]),ua++}function Ua(bo,Va,Ka){const Do=vi[bo];return delete vi[bo],vi[Va]=Do,ui[Do].geometry[0].pop(),ui[Do].geometry[0]=ui[Do].geometry[0].concat(Ka[0]),Do}function Ga(bo,Va,Ka){const Do=Li[Va];return delete Li[Va],Li[bo]=Do,ui[Do].geometry[0].shift(),ui[Do].geometry[0]=Ka[0].concat(ui[Do].geometry[0]),Do}function ho(bo,Va,Ka){const Do=Ka?Va[0][Va[0].length-1]:Va[0][0];return`${bo}:${Do.x}:${Do.y}`}for(let bo=0;bo<si.length;bo++){const Va=si[bo],Ka=Va.geometry,Do=Va.text?Va.text.toString():null;if(!Do){ba(bo);continue}const $o=ho(Do,Ka),Ro=ho(Do,Ka,!0);if($o in vi&&Ro in Li&&vi[$o]!==Li[Ro]){const No=Ga($o,Ro,Ka),Sl=Ua($o,Ro,ui[No].geometry);delete Li[$o],delete vi[Ro],vi[ho(Do,ui[Sl].geometry,!0)]=Sl,ui[No].geometry=null}else $o in vi?Ua($o,Ro,Ka):Ro in Li?Ga($o,Ro,Ka):(ba(bo),Li[$o]=ua-1,vi[Ro]=ua-1)}return ui.filter(bo=>bo.geometry)}(this.features)),this.sortFeaturesByKey&&this.features.sort((si,Li)=>si.sortKey-Li.sortKey)}update(_,k,X,de){this.stateDependentLayers.length&&(this.text.programConfigurations.updatePaintArrays(_,k,this.layers,X,de),this.icon.programConfigurations.updatePaintArrays(_,k,this.layers,X,de))}isEmpty(){return this.symbolInstances.length===0&&!this.hasRTLText}uploadPending(){return!this.uploaded||this.text.programConfigurations.needsUpload||this.icon.programConfigurations.needsUpload}upload(_){!this.uploaded&&this.hasDebugData()&&(this.textCollisionBox.upload(_),this.iconCollisionBox.upload(_)),this.text.upload(_,this.sortFeaturesByY,!this.uploaded,this.text.programConfigurations.needsUpload),this.icon.upload(_,this.sortFeaturesByY,!this.uploaded,this.icon.programConfigurations.needsUpload),this.uploaded=!0}destroyDebugData(){this.textCollisionBox.destroy(),this.iconCollisionBox.destroy()}destroy(){this.text.destroy(),this.icon.destroy(),this.hasDebugData()&&this.destroyDebugData()}addToLineVertexArray(_,k){const X=this.lineVertexArray.length,de=_.segment;if(de!==void 0){let Ge=_.dist(k[de+1]),ft=_.dist(k[de]);const _t={};for(let At=de+1;At<k.length;At++)_t[At]={x:k[At].x,y:k[At].y,tileUnitDistanceFromAnchor:Ge},At<k.length-1&&(Ge+=k[At+1].dist(k[At]));for(let At=de||0;At>=0;At--)_t[At]={x:k[At].x,y:k[At].y,tileUnitDistanceFromAnchor:ft},At>0&&(ft+=k[At-1].dist(k[At]));for(let At=0;At<k.length;At++){const Nt=_t[At];this.lineVertexArray.emplaceBack(Nt.x,Nt.y,Nt.tileUnitDistanceFromAnchor)}}return{lineStartIndex:X,lineLength:this.lineVertexArray.length-X}}addSymbols(_,k,X,de,Ge,ft,_t,At,Nt,cn,vn,bn,jn,Zn){const Br=_.indexArray,Jr=_.layoutVertexArray,si=_.segments.prepareSegment(4*k.length,Jr,Br,this.canOverlap?ft.sortKey:void 0),Li=this.glyphOffsetArray.length,vi=si.vertexLength,ui=this.allowVerticalPlacement&&_t===Gh.vertical?Math.PI/2:0,ua=ft.text&&ft.text.sections;for(let ba=0;ba<k.length;ba++){const{tl:Ua,tr:Ga,bl:ho,br:bo,tex:Va,pixelOffsetTL:Ka,pixelOffsetBR:Do,minFontScaleX:$o,minFontScaleY:Ro,glyphOffset:No,isSDF:Sl,sectionIndex:ru}=k[ba],El=si.vertexLength,Fl=No[1];a3(Jr,At.x,At.y,At.z,Nt.x,Nt.y,Ua.x,Fl+Ua.y,Va.x,Va.y,X,Sl,Ka.x,Ka.y,$o,Ro),a3(Jr,At.x,At.y,At.z,Nt.x,Nt.y,Ga.x,Fl+Ga.y,Va.x+Va.w,Va.y,X,Sl,Do.x,Ka.y,$o,Ro),a3(Jr,At.x,At.y,At.z,Nt.x,Nt.y,ho.x,Fl+ho.y,Va.x,Va.y+Va.h,X,Sl,Ka.x,Do.y,$o,Ro),a3(Jr,At.x,At.y,At.z,Nt.x,Nt.y,bo.x,Fl+bo.y,Va.x+Va.w,Va.y+Va.h,X,Sl,Do.x,Do.y,$o,Ro),Mc(_.dynamicLayoutVertexArray,At,ui),Br.emplaceBack(El,El+1,El+2),Br.emplaceBack(El+1,El+2,El+3),si.vertexLength+=4,si.primitiveLength+=2,this.glyphOffsetArray.emplaceBack(No[0]),ba!==k.length-1&&ru===k[ba+1].sectionIndex||_.programConfigurations.populatePaintArrays(Jr.length,ft,ft.index,{},jn,Zn,ua&&ua[ru])}_.placedSymbolArray.emplaceBack(At.x,At.y,At.z,Nt.x,Nt.y,Li,this.glyphOffsetArray.length-Li,vi,cn,vn,Nt.segment,X?X[0]:0,X?X[1]:0,de[0],de[1],_t,0,!1,0,bn,0)}_commitLayoutVertex(_,k,X,de,Ge,ft,_t){_.emplaceBack(k,X,de,Ge,ft,Math.round(_t.x),Math.round(_t.y))}_addCollisionDebugVertices(_,k,X,de,Ge,ft,_t){const At=X.segments.prepareSegment(4,X.layoutVertexArray,X.indexArray),Nt=At.vertexLength,cn=_t.tileAnchorX,vn=_t.tileAnchorY;for(let jn=0;jn<4;jn++)X.collisionVertexArray.emplaceBack(0,0,0,0);X.collisionVertexArrayExt.emplaceBack(k,-_.padding,-_.padding),X.collisionVertexArrayExt.emplaceBack(k,_.padding,-_.padding),X.collisionVertexArrayExt.emplaceBack(k,_.padding,_.padding),X.collisionVertexArrayExt.emplaceBack(k,-_.padding,_.padding),this._commitLayoutVertex(X.layoutVertexArray,de,Ge,ft,cn,vn,new G(_.x1,_.y1)),this._commitLayoutVertex(X.layoutVertexArray,de,Ge,ft,cn,vn,new G(_.x2,_.y1)),this._commitLayoutVertex(X.layoutVertexArray,de,Ge,ft,cn,vn,new G(_.x2,_.y2)),this._commitLayoutVertex(X.layoutVertexArray,de,Ge,ft,cn,vn,new G(_.x1,_.y2)),At.vertexLength+=4;const bn=X.indexArray;bn.emplaceBack(Nt,Nt+1),bn.emplaceBack(Nt+1,Nt+2),bn.emplaceBack(Nt+2,Nt+3),bn.emplaceBack(Nt+3,Nt),At.primitiveLength+=4}_addTextDebugCollisionBoxes(_,k,X,de,Ge,ft){for(let _t=de;_t<Ge;_t++){const At=X.get(_t),Nt=this.getSymbolInstanceTextSize(_,ft,k,_t);this._addCollisionDebugVertices(At,Nt,this.textCollisionBox,At.projectedAnchorX,At.projectedAnchorY,At.projectedAnchorZ,ft)}}_addIconDebugCollisionBoxes(_,k,X,de,Ge,ft){for(let _t=de;_t<Ge;_t++){const At=X.get(_t),Nt=this.getSymbolInstanceIconSize(_,k,_t);this._addCollisionDebugVertices(At,Nt,this.iconCollisionBox,At.projectedAnchorX,At.projectedAnchorY,At.projectedAnchorZ,ft)}}generateCollisionDebugBuffers(_,k){this.hasDebugData()&&this.destroyDebugData(),this.textCollisionBox=new Tm(So,Ep.members,ll),this.iconCollisionBox=new Tm(So,Ep.members,ll);const X=_m(this.iconSizeData,_),de=_m(this.textSizeData,_);for(let Ge=0;Ge<this.symbolInstances.length;Ge++){const ft=this.symbolInstances.get(Ge);this._addTextDebugCollisionBoxes(de,_,k,ft.textBoxStartIndex,ft.textBoxEndIndex,ft),this._addTextDebugCollisionBoxes(de,_,k,ft.verticalTextBoxStartIndex,ft.verticalTextBoxEndIndex,ft),this._addIconDebugCollisionBoxes(X,_,k,ft.iconBoxStartIndex,ft.iconBoxEndIndex,ft),this._addIconDebugCollisionBoxes(X,_,k,ft.verticalIconBoxStartIndex,ft.verticalIconBoxEndIndex,ft)}}getSymbolInstanceTextSize(_,k,X,de){const Ge=this.text.placedSymbolArray.get(k.rightJustifiedTextSymbolIndex>=0?k.rightJustifiedTextSymbolIndex:k.centerJustifiedTextSymbolIndex>=0?k.centerJustifiedTextSymbolIndex:k.leftJustifiedTextSymbolIndex>=0?k.leftJustifiedTextSymbolIndex:k.verticalPlacedTextSymbolIndex>=0?k.verticalPlacedTextSymbolIndex:de),ft=F3(this.textSizeData,_,Ge)/Ad;return this.tilePixelRatio*ft}getSymbolInstanceIconSize(_,k,X){const de=this.icon.placedSymbolArray.get(X),Ge=F3(this.iconSizeData,_,de);return this.tilePixelRatio*Ge}_commitDebugCollisionVertexUpdate(_,k,X){_.emplaceBack(k,-X,-X),_.emplaceBack(k,X,-X),_.emplaceBack(k,X,X),_.emplaceBack(k,-X,X)}_updateTextDebugCollisionBoxes(_,k,X,de,Ge,ft){for(let _t=de;_t<Ge;_t++){const At=X.get(_t),Nt=this.getSymbolInstanceTextSize(_,ft,k,_t);this._commitDebugCollisionVertexUpdate(this.textCollisionBox.collisionVertexArrayExt,Nt,At.padding)}}_updateIconDebugCollisionBoxes(_,k,X,de,Ge){for(let ft=de;ft<Ge;ft++){const _t=X.get(ft),At=this.getSymbolInstanceIconSize(_,k,ft);this._commitDebugCollisionVertexUpdate(this.iconCollisionBox.collisionVertexArrayExt,At,_t.padding)}}updateCollisionDebugBuffers(_,k){if(!this.hasDebugData())return;this.hasTextCollisionBoxData()&&this.textCollisionBox.collisionVertexArrayExt.clear(),this.hasIconCollisionBoxData()&&this.iconCollisionBox.collisionVertexArrayExt.clear();const X=_m(this.iconSizeData,_),de=_m(this.textSizeData,_);for(let Ge=0;Ge<this.symbolInstances.length;Ge++){const ft=this.symbolInstances.get(Ge);this._updateTextDebugCollisionBoxes(de,_,k,ft.textBoxStartIndex,ft.textBoxEndIndex,ft),this._updateTextDebugCollisionBoxes(de,_,k,ft.verticalTextBoxStartIndex,ft.verticalTextBoxEndIndex,ft),this._updateIconDebugCollisionBoxes(X,_,k,ft.iconBoxStartIndex,ft.iconBoxEndIndex),this._updateIconDebugCollisionBoxes(X,_,k,ft.verticalIconBoxStartIndex,ft.verticalIconBoxEndIndex)}this.hasTextCollisionBoxData()&&this.textCollisionBox.collisionVertexBufferExt&&this.textCollisionBox.collisionVertexBufferExt.updateData(this.textCollisionBox.collisionVertexArrayExt),this.hasIconCollisionBoxData()&&this.iconCollisionBox.collisionVertexBufferExt&&this.iconCollisionBox.collisionVertexBufferExt.updateData(this.iconCollisionBox.collisionVertexArrayExt)}_deserializeCollisionBoxesForSymbol(_,k,X,de,Ge,ft,_t,At,Nt){const cn={};for(let vn=k;vn<X;vn++){const bn=_.get(vn);cn.textBox={x1:bn.x1,y1:bn.y1,x2:bn.x2,y2:bn.y2,padding:bn.padding,projectedAnchorX:bn.projectedAnchorX,projectedAnchorY:bn.projectedAnchorY,projectedAnchorZ:bn.projectedAnchorZ,tileAnchorX:bn.tileAnchorX,tileAnchorY:bn.tileAnchorY},cn.textFeatureIndex=bn.featureIndex;break}for(let vn=de;vn<Ge;vn++){const bn=_.get(vn);cn.verticalTextBox={x1:bn.x1,y1:bn.y1,x2:bn.x2,y2:bn.y2,padding:bn.padding,projectedAnchorX:bn.projectedAnchorX,projectedAnchorY:bn.projectedAnchorY,projectedAnchorZ:bn.projectedAnchorZ,tileAnchorX:bn.tileAnchorX,tileAnchorY:bn.tileAnchorY},cn.verticalTextFeatureIndex=bn.featureIndex;break}for(let vn=ft;vn<_t;vn++){const bn=_.get(vn);cn.iconBox={x1:bn.x1,y1:bn.y1,x2:bn.x2,y2:bn.y2,padding:bn.padding,projectedAnchorX:bn.projectedAnchorX,projectedAnchorY:bn.projectedAnchorY,projectedAnchorZ:bn.projectedAnchorZ,tileAnchorX:bn.tileAnchorX,tileAnchorY:bn.tileAnchorY},cn.iconFeatureIndex=bn.featureIndex;break}for(let vn=At;vn<Nt;vn++){const bn=_.get(vn);cn.verticalIconBox={x1:bn.x1,y1:bn.y1,x2:bn.x2,y2:bn.y2,padding:bn.padding,projectedAnchorX:bn.projectedAnchorX,projectedAnchorY:bn.projectedAnchorY,projectedAnchorZ:bn.projectedAnchorZ,tileAnchorX:bn.tileAnchorX,tileAnchorY:bn.tileAnchorY},cn.verticalIconFeatureIndex=bn.featureIndex;break}return cn}deserializeCollisionBoxes(_){this.collisionArrays=[];for(let k=0;k<this.symbolInstances.length;k++){const X=this.symbolInstances.get(k);this.collisionArrays.push(this._deserializeCollisionBoxesForSymbol(_,X.textBoxStartIndex,X.textBoxEndIndex,X.verticalTextBoxStartIndex,X.verticalTextBoxEndIndex,X.iconBoxStartIndex,X.iconBoxEndIndex,X.verticalIconBoxStartIndex,X.verticalIconBoxEndIndex))}}hasTextData(){return this.text.segments.get().length>0}hasIconData(){return this.icon.segments.get().length>0}hasDebugData(){return this.textCollisionBox&&this.iconCollisionBox}hasTextCollisionBoxData(){return this.hasDebugData()&&this.textCollisionBox.segments.get().length>0}hasIconCollisionBoxData(){return this.hasDebugData()&&this.iconCollisionBox.segments.get().length>0}addIndicesForPlacedSymbol(_,k){const X=_.placedSymbolArray.get(k),de=X.vertexStartIndex+4*X.numGlyphs;for(let Ge=X.vertexStartIndex;Ge<de;Ge+=4)_.indexArray.emplaceBack(Ge,Ge+1,Ge+2),_.indexArray.emplaceBack(Ge+1,Ge+2,Ge+3)}getSortedSymbolIndexes(_){if(this.sortedAngle===_&&this.symbolInstanceIndexes!==void 0)return this.symbolInstanceIndexes;const k=Math.sin(_),X=Math.cos(_),de=[],Ge=[],ft=[];for(let _t=0;_t<this.symbolInstances.length;++_t){ft.push(_t);const At=this.symbolInstances.get(_t);de.push(0|Math.round(k*At.tileAnchorX+X*At.tileAnchorY)),Ge.push(At.featureIndex)}return ft.sort((_t,At)=>de[_t]-de[At]||Ge[At]-Ge[_t]),ft}addToSortKeyRanges(_,k){const X=this.sortKeyRanges[this.sortKeyRanges.length-1];X&&X.sortKey===k?X.symbolInstanceEnd=_+1:this.sortKeyRanges.push({sortKey:k,symbolInstanceStart:_,symbolInstanceEnd:_+1})}sortFeatures(_){if(this.sortFeaturesByY&&this.sortedAngle!==_&&!(this.text.segments.get().length>1||this.icon.segments.get().length>1)){this.symbolInstanceIndexes=this.getSortedSymbolIndexes(_),this.sortedAngle=_,this.text.indexArray.clear(),this.icon.indexArray.clear(),this.featureSortOrder=[];for(const k of this.symbolInstanceIndexes){const X=this.symbolInstances.get(k);this.featureSortOrder.push(X.featureIndex),[X.rightJustifiedTextSymbolIndex,X.centerJustifiedTextSymbolIndex,X.leftJustifiedTextSymbolIndex].forEach((de,Ge,ft)=>{de>=0&&ft.indexOf(de)===Ge&&this.addIndicesForPlacedSymbol(this.text,de)}),X.verticalPlacedTextSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.text,X.verticalPlacedTextSymbolIndex),X.placedIconSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.icon,X.placedIconSymbolIndex),X.verticalPlacedIconSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.icon,X.verticalPlacedIconSymbolIndex)}this.text.indexBuffer&&this.text.indexBuffer.updateData(this.text.indexArray),this.icon.indexBuffer&&this.icon.indexBuffer.updateData(this.icon.indexArray)}}}Zo(Hf,"SymbolBucket",{omit:["layers","collisionBoxArray","features","compareText"]}),Hf.MAX_GLYPHS=65535,Hf.addDynamicAttributes=Mc;const Yg=new Wn({"symbol-placement":new Ot(ma.layout_symbol["symbol-placement"]),"symbol-spacing":new Ot(ma.layout_symbol["symbol-spacing"]),"symbol-avoid-edges":new Ot(ma.layout_symbol["symbol-avoid-edges"]),"symbol-sort-key":new rn(ma.layout_symbol["symbol-sort-key"]),"symbol-z-order":new Ot(ma.layout_symbol["symbol-z-order"]),"icon-allow-overlap":new Ot(ma.layout_symbol["icon-allow-overlap"]),"icon-ignore-placement":new Ot(ma.layout_symbol["icon-ignore-placement"]),"icon-optional":new Ot(ma.layout_symbol["icon-optional"]),"icon-rotation-alignment":new Ot(ma.layout_symbol["icon-rotation-alignment"]),"icon-size":new rn(ma.layout_symbol["icon-size"]),"icon-text-fit":new Ot(ma.layout_symbol["icon-text-fit"]),"icon-text-fit-padding":new Ot(ma.layout_symbol["icon-text-fit-padding"]),"icon-image":new rn(ma.layout_symbol["icon-image"]),"icon-rotate":new rn(ma.layout_symbol["icon-rotate"]),"icon-padding":new Ot(ma.layout_symbol["icon-padding"]),"icon-keep-upright":new Ot(ma.layout_symbol["icon-keep-upright"]),"icon-offset":new rn(ma.layout_symbol["icon-offset"]),"icon-anchor":new rn(ma.layout_symbol["icon-anchor"]),"icon-pitch-alignment":new Ot(ma.layout_symbol["icon-pitch-alignment"]),"text-pitch-alignment":new Ot(ma.layout_symbol["text-pitch-alignment"]),"text-rotation-alignment":new Ot(ma.layout_symbol["text-rotation-alignment"]),"text-field":new rn(ma.layout_symbol["text-field"]),"text-font":new rn(ma.layout_symbol["text-font"]),"text-size":new rn(ma.layout_symbol["text-size"]),"text-max-width":new rn(ma.layout_symbol["text-max-width"]),"text-line-height":new rn(ma.layout_symbol["text-line-height"]),"text-letter-spacing":new rn(ma.layout_symbol["text-letter-spacing"]),"text-justify":new rn(ma.layout_symbol["text-justify"]),"text-radial-offset":new rn(ma.layout_symbol["text-radial-offset"]),"text-variable-anchor":new Ot(ma.layout_symbol["text-variable-anchor"]),"text-anchor":new rn(ma.layout_symbol["text-anchor"]),"text-max-angle":new Ot(ma.layout_symbol["text-max-angle"]),"text-writing-mode":new Ot(ma.layout_symbol["text-writing-mode"]),"text-rotate":new rn(ma.layout_symbol["text-rotate"]),"text-padding":new Ot(ma.layout_symbol["text-padding"]),"text-keep-upright":new Ot(ma.layout_symbol["text-keep-upright"]),"text-transform":new rn(ma.layout_symbol["text-transform"]),"text-offset":new rn(ma.layout_symbol["text-offset"]),"text-allow-overlap":new Ot(ma.layout_symbol["text-allow-overlap"]),"text-ignore-placement":new Ot(ma.layout_symbol["text-ignore-placement"]),"text-optional":new Ot(ma.layout_symbol["text-optional"])});var Pg={paint:new Wn({"icon-opacity":new rn(ma.paint_symbol["icon-opacity"]),"icon-color":new rn(ma.paint_symbol["icon-color"]),"icon-halo-color":new rn(ma.paint_symbol["icon-halo-color"]),"icon-halo-width":new rn(ma.paint_symbol["icon-halo-width"]),"icon-halo-blur":new rn(ma.paint_symbol["icon-halo-blur"]),"icon-translate":new Ot(ma.paint_symbol["icon-translate"]),"icon-translate-anchor":new Ot(ma.paint_symbol["icon-translate-anchor"]),"text-opacity":new rn(ma.paint_symbol["text-opacity"]),"text-color":new rn(ma.paint_symbol["text-color"],{runtimeType:Xl,getOverride:D=>D.textColor,hasOverride:D=>!!D.textColor}),"text-halo-color":new rn(ma.paint_symbol["text-halo-color"]),"text-halo-width":new rn(ma.paint_symbol["text-halo-width"]),"text-halo-blur":new rn(ma.paint_symbol["text-halo-blur"]),"text-translate":new Ot(ma.paint_symbol["text-translate"]),"text-translate-anchor":new Ot(ma.paint_symbol["text-translate-anchor"])}),layout:Yg};class Zg{constructor(_){this.type=_.property.overrides?_.property.overrides.runtimeType:yu,this.defaultValue=_}evaluate(_){if(_.formattedSection){const k=this.defaultValue.property.overrides;if(k&&k.hasOverride(_.formattedSection))return k.getOverride(_.formattedSection)}return _.feature&&_.featureState?this.defaultValue.evaluate(_.feature,_.featureState):this.defaultValue.property.specification.default}eachChild(_){this.defaultValue.isConstant()||_(this.defaultValue.value._styleExpression.expression)}outputDefined(){return!1}serialize(){return null}}Zo(Zg,"FormatSectionOverride",{omit:["defaultValue"]});class b3 extends xh{constructor(_){super(_,Pg)}recalculate(_,k){super.recalculate(_,k),this.layout.get("icon-rotation-alignment")==="auto"&&(this.layout._values["icon-rotation-alignment"]=this.layout.get("symbol-placement")!=="point"?"map":"viewport"),this.layout.get("text-rotation-alignment")==="auto"&&(this.layout._values["text-rotation-alignment"]=this.layout.get("symbol-placement")!=="point"?"map":"viewport"),this.layout.get("text-pitch-alignment")==="auto"&&(this.layout._values["text-pitch-alignment"]=this.layout.get("text-rotation-alignment")),this.layout.get("icon-pitch-alignment")==="auto"&&(this.layout._values["icon-pitch-alignment"]=this.layout.get("icon-rotation-alignment"));const X=this.layout.get("text-writing-mode");if(X){const de=[];for(const Ge of X)de.indexOf(Ge)<0&&de.push(Ge);this.layout._values["text-writing-mode"]=de}else this.layout._values["text-writing-mode"]=this.layout.get("symbol-placement")==="point"?["horizontal"]:["horizontal","vertical"];this._setPaintOverrides()}getValueAndResolveTokens(_,k,X,de){const Ge=this.layout.get(_).evaluate(k,{},X,de),ft=this._unevaluatedLayout._values[_];return ft.isDataDriven()||Xo(ft.value)||!Ge?Ge:function(_t,At){return At.replace(/{([^{}]+)}/g,(Nt,cn)=>cn in _t?String(_t[cn]):"")}(k.properties,Ge)}createBucket(_){return new Hf(_)}queryRadius(){return 0}queryIntersectsFeature(){return!1}_setPaintOverrides(){for(const _ of Pg.paint.overridableProperties){if(!b3.hasPaintOverride(this.layout,_))continue;const k=this.paint.get(_),X=new Zg(k),de=new Jo(X,k.property.specification);let Ge=null;Ge=k.value.kind==="constant"||k.value.kind==="source"?new ii("source",de):new Ma("composite",de,k.value.zoomStops,k.value._interpolationType),this.paint._values[_]=new xt(k.property,Ge,k.parameters)}}_handleOverridablePaintPropertyUpdate(_,k,X){return!(!this.layout||k.isDataDriven()||X.isDataDriven())&&b3.hasPaintOverride(this.layout,_)}static hasPaintOverride(_,k){const X=_.get("text-field"),de=Pg.paint.properties[k];let Ge=!1;const ft=_t=>{for(const At of _t)if(de.overrides&&de.overrides.hasOverride(At))return void(Ge=!0)};if(X.value.kind==="constant"&&X.value.value instanceof Go)ft(X.value.value.sections);else if(X.value.kind==="source"){const _t=Nt=>{Ge||(Nt instanceof mu&&Bl(Nt.value)===Pl?ft(Nt.value.sections):Nt instanceof hl?ft(Nt.sections):Nt.eachChild(_t))},At=X.value;At._styleExpression&&_t(At._styleExpression.expression)}return Ge}getProgramConfiguration(_){return new np(this,_)}}var f0={paint:new Wn({"background-color":new Ot(ma.paint_background["background-color"]),"background-pattern":new kn(ma.paint_background["background-pattern"]),"background-opacity":new Ot(ma.paint_background["background-opacity"])})},Kg={paint:new Wn({"raster-opacity":new Ot(ma.paint_raster["raster-opacity"]),"raster-hue-rotate":new Ot(ma.paint_raster["raster-hue-rotate"]),"raster-brightness-min":new Ot(ma.paint_raster["raster-brightness-min"]),"raster-brightness-max":new Ot(ma.paint_raster["raster-brightness-max"]),"raster-saturation":new Ot(ma.paint_raster["raster-saturation"]),"raster-contrast":new Ot(ma.paint_raster["raster-contrast"]),"raster-resampling":new Ot(ma.paint_raster["raster-resampling"]),"raster-fade-duration":new Ot(ma.paint_raster["raster-fade-duration"])})};class m0 extends xh{constructor(_){super(_,{}),this.implementation=_}is3D(){return this.implementation.renderingMode==="3d"}hasOffscreenPass(){return this.implementation.prerender!==void 0}recalculate(){}updateTransitions(){}hasTransition(){return!1}serialize(){}onAdd(_){this.implementation.onAdd&&this.implementation.onAdd(_,_.painter.context.gl)}onRemove(_){this.implementation.onRemove&&this.implementation.onRemove(_,_.painter.context.gl)}}var g0={paint:new Wn({"sky-type":new Ot(ma.paint_sky["sky-type"]),"sky-atmosphere-sun":new Ot(ma.paint_sky["sky-atmosphere-sun"]),"sky-atmosphere-sun-intensity":new Ot(ma.paint_sky["sky-atmosphere-sun-intensity"]),"sky-gradient-center":new Ot(ma.paint_sky["sky-gradient-center"]),"sky-gradient-radius":new Ot(ma.paint_sky["sky-gradient-radius"]),"sky-gradient":new Bn(ma.paint_sky["sky-gradient"]),"sky-atmosphere-halo-color":new Ot(ma.paint_sky["sky-atmosphere-halo-color"]),"sky-atmosphere-color":new Ot(ma.paint_sky["sky-atmosphere-color"]),"sky-opacity":new Ot(ma.paint_sky["sky-opacity"])})};function Ig(D,_,k){const X=[0,0,1],de=Bf([]);return function(Ge,ft,_t){_t*=.5;var At=ft[0],Nt=ft[1],cn=ft[2],vn=ft[3],bn=Math.sin(_t),jn=Math.cos(_t);Ge[0]=At*jn-cn*bn,Ge[1]=Nt*jn+vn*bn,Ge[2]=cn*jn+At*bn,Ge[3]=vn*jn-Nt*bn}(de,de,k?-ne(D)+Math.PI:ne(D)),pf(de,de,-ne(_)),qm(X,X,de),Ic(X,X)}const y0={circle:class extends xh{constructor(D){super(D,sm)}createBucket(D){return new Rf(D)}queryRadius(D){const _=D;return rp("circle-radius",this,_)+rp("circle-stroke-width",this,_)+_p(this.paint.get("circle-translate"))}queryIntersectsFeature(D,_,k,X,de,Ge,ft,_t){const At=jm(this.paint.get("circle-translate"),this.paint.get("circle-translate-anchor"),Ge.angle,D.pixelToTileUnitsFactor),Nt=this.paint.get("circle-radius").evaluate(_,k)+this.paint.get("circle-stroke-width").evaluate(_,k);return Ym(D,X,Ge,ft,_t,this.paint.get("circle-pitch-alignment")==="map",this.paint.get("circle-pitch-scale")==="map",At,Nt)}getProgramIds(){return["circle"]}getProgramConfiguration(D){return new np(this,D)}},heatmap:class extends xh{createBucket(D){return new Kp(D)}constructor(D){super(D,Sd),this._updateColorRamp()}_handleSpecialPaintPropertyUpdate(D){D==="heatmap-color"&&this._updateColorRamp()}_updateColorRamp(){this.colorRamp=Xp({expression:this._transitionablePaint._values["heatmap-color"].value.expression,evaluationKey:"heatmapDensity",image:this.colorRamp}),this.colorRampTexture=null}resize(){this.heatmapFbo&&(this.heatmapFbo.destroy(),this.heatmapFbo=null)}queryRadius(D){return rp("heatmap-radius",this,D)}queryIntersectsFeature(D,_,k,X,de,Ge,ft,_t){const At=this.paint.get("heatmap-radius").evaluate(_,k);return Ym(D,X,Ge,ft,_t,!0,!0,new G(0,0),At)}hasOffscreenPass(){return this.paint.get("heatmap-opacity")!==0&&this.visibility!=="none"}getProgramIds(){return["heatmap","heatmapTexture"]}getProgramConfiguration(D){return new np(this,D)}},hillshade:class extends xh{constructor(D){super(D,Zm)}hasOffscreenPass(){return this.paint.get("hillshade-exaggeration")!==0&&this.visibility!=="none"}getProgramIds(){return["hillshade","hillshadePrepare"]}},fill:class extends xh{constructor(D){super(D,au)}getProgramIds(){const D=this.paint.get("fill-pattern"),_=D&&D.constantOr(1),k=[_?"fillPattern":"fill"];return this.paint.get("fill-antialias")&&k.push(_&&!this.getPaintProperty("fill-outline-color")?"fillOutlinePattern":"fillOutline"),k}getProgramConfiguration(D){return new np(this,D)}recalculate(D,_){super.recalculate(D,_);const k=this.paint._values["fill-outline-color"];k.value.kind==="constant"&&k.value.value===void 0&&(this.paint._values["fill-outline-color"]=this.paint._values["fill-color"])}createBucket(D){return new Tl(D)}queryRadius(){return _p(this.paint.get("fill-translate"))}queryIntersectsFeature(D,_,k,X,de,Ge){return!D.queryGeometry.isAboveHorizon&&zh(Lf(D.tilespaceGeometry,this.paint.get("fill-translate"),this.paint.get("fill-translate-anchor"),Ge.angle,D.pixelToTileUnitsFactor),X)}isTileClipped(){return!0}},"fill-extrusion":class extends xh{constructor(D){super(D,ng)}createBucket(D){return new op(D)}queryRadius(){return _p(this.paint.get("fill-extrusion-translate"))}is3D(){return!0}getProgramIds(){return[this.paint.get("fill-extrusion-pattern").constantOr(1)?"fillExtrusionPattern":"fillExtrusion"]}getProgramConfiguration(D){return new np(this,D)}queryIntersectsFeature(D,_,k,X,de,Ge,ft,_t,At){const Nt=jm(this.paint.get("fill-extrusion-translate"),this.paint.get("fill-extrusion-translate-anchor"),Ge.angle,D.pixelToTileUnitsFactor),cn=this.paint.get("fill-extrusion-height").evaluate(_,k),vn=this.paint.get("fill-extrusion-base").evaluate(_,k),bn=[0,0],jn=_t&&Ge.elevation,Zn=Ge.elevation?Ge.elevation.exaggeration():1,Br=D.tile.getBucket(this);if(jn&&Br instanceof op){const Li=Br.centroidVertexArray,vi=At+1;if(vi<Li.length){const ui=Li.get(vi);bn[0]=ui.a_centroid_pos0,bn[1]=ui.a_centroid_pos1}}if(bn[0]===0&&bn[1]===1)return!1;const Jr=function(Li,vi,ui,ua,ba,Ua,Ga,ho,bo){return Ua?function(Va,Ka,Do,$o,Ro,No,Sl,ru,El){const Fl=[],Vs=[],gs=[0,0,0,1];for(const cu of Va){const Lu=[],kd=[];for(const Ec of cu){const Pd=Ec.x+$o.x,Fu=Ec.y+$o.y,fu=ig(Pd,Fu,Ka,Do,No,Sl,ru,El);gs[0]=Pd,gs[1]=Fu,gs[2]=fu.base,gs[3]=1,Qd(gs,gs,Ro),gs[3]=Math.max(gs[3],1e-5);const ic=O3([gs[0]/gs[3],gs[1]/gs[3],gs[2]/gs[3]]);gs[0]=Pd,gs[1]=Fu,gs[2]=fu.top,gs[3]=1,Qd(gs,gs,Ro),gs[3]=Math.max(gs[3],1e-5);const Kc=O3([gs[0]/gs[3],gs[1]/gs[3],gs[2]/gs[3]]);Lu.push(ic),kd.push(Kc)}Fl.push(Lu),Vs.push(kd)}return[Fl,Vs]}(Li,vi,ui,ua,ba,Ua,Ga,ho,bo):function(Va,Ka,Do,$o,Ro){const No=[],Sl=[],ru=Ro[8]*Ka,El=Ro[9]*Ka,Fl=Ro[10]*Ka,Vs=Ro[11]*Ka,gs=Ro[8]*Do,cu=Ro[9]*Do,Lu=Ro[10]*Do,kd=Ro[11]*Do;for(const Ec of Va){const Pd=[],Fu=[];for(const fu of Ec){const ic=fu.x+$o.x,Kc=fu.y+$o.y,id=Ro[0]*ic+Ro[4]*Kc+Ro[12],Id=Ro[1]*ic+Ro[5]*Kc+Ro[13],Yd=Ro[2]*ic+Ro[6]*Kc+Ro[14],kp=Ro[3]*ic+Ro[7]*Kc+Ro[15],sp=id+ru,pc=Id+El,Hh=Yd+Fl,Pp=Math.max(kp+Vs,1e-5),ih=id+gs,Zd=Id+cu,zc=Yd+Lu,Ac=Math.max(kp+kd,1e-5),lp=new G(sp/Pp,pc/Pp);lp.z=Hh/Pp,Pd.push(lp);const Wh=new G(ih/Ac,Zd/Ac);Wh.z=zc/Ac,Fu.push(Wh)}No.push(Pd),Sl.push(Fu)}return[No,Sl]}(Li,vi,ui,ua,ba)}(X,vn,cn,Nt,ft,jn?_t:null,bn,Zn,Ge.center.lat),si=D.queryGeometry;return function(Li,vi,ui){let ua=1/0;zh(ui,vi)&&(ua=rg(ui,vi[0]));for(let ba=0;ba<vi.length;ba++){const Ua=vi[ba],Ga=Li[ba];for(let ho=0;ho<Ua.length-1;ho++){const bo=Ua[ho],Va=[bo,Ua[ho+1],Ga[ho+1],Ga[ho],bo];Md(ui,Va)&&(ua=Math.min(ua,rg(ui,Va)))}}return ua!==1/0&&ua}(Jr[0],Jr[1],si.isPointQuery()?si.screenBounds:si.screenGeometry)}},line:class extends xh{constructor(D){super(D,lg),this.gradientVersion=0}_handleSpecialPaintPropertyUpdate(D){if(D==="line-gradient"){const _=this._transitionablePaint._values["line-gradient"].value.expression;this.stepInterpolant=_._styleExpression&&_._styleExpression.expression instanceof Pn,this.gradientVersion=(this.gradientVersion+1)%Number.MAX_SAFE_INTEGER}}gradientExpression(){return this._transitionablePaint._values["line-gradient"].value.expression}recalculate(D,_){super.recalculate(D,_),this.paint._values["line-floorwidth"]=ug.possiblyEvaluate(this._transitioningPaint._values["line-width"].value,D)}createBucket(D){return new L3(D)}getProgramIds(){return[this.paint.get("line-pattern").constantOr(1)?"linePattern":"line"]}getProgramConfiguration(D){return new np(this,D)}queryRadius(D){const _=D,k=r0(rp("line-width",this,_),rp("line-gap-width",this,_)),X=rp("line-offset",this,_);return k/2+Math.abs(X)+_p(this.paint.get("line-translate"))}queryIntersectsFeature(D,_,k,X,de,Ge){if(D.queryGeometry.isAboveHorizon)return!1;const ft=Lf(D.tilespaceGeometry,this.paint.get("line-translate"),this.paint.get("line-translate-anchor"),Ge.angle,D.pixelToTileUnitsFactor),_t=D.pixelToTileUnitsFactor/2*r0(this.paint.get("line-width").evaluate(_,k),this.paint.get("line-gap-width").evaluate(_,k)),At=this.paint.get("line-offset").evaluate(_,k);return At&&(X=function(Nt,cn){const vn=[],bn=new G(0,0);for(let jn=0;jn<Nt.length;jn++){const Zn=Nt[jn],Br=[];for(let Jr=0;Jr<Zn.length;Jr++){const si=Zn[Jr-1],Li=Zn[Jr],vi=Zn[Jr+1],ui=Jr===0?bn:Li.sub(si)._unit()._perp(),ua=Jr===Zn.length-1?bn:vi.sub(Li)._unit()._perp(),ba=ui._add(ua)._unit();ba._mult(1/(ba.x*ua.x+ba.y*ua.y)),Br.push(ba._mult(cn)._add(Li))}vn.push(Br)}return vn}(X,At*D.pixelToTileUnitsFactor)),function(Nt,cn,vn){for(let bn=0;bn<cn.length;bn++){const jn=cn[bn];if(Nt.length>=3){for(let Zn=0;Zn<jn.length;Zn++)if($u(Nt,jn[Zn]))return!0}if(zm(Nt,jn,vn))return!0}return!1}(ft,X,_t)}isTileClipped(){return!0}},symbol:b3,background:class extends xh{constructor(D){super(D,f0)}getProgramIds(){return[this.paint.get("background-pattern")?"backgroundPattern":"background"]}},raster:class extends xh{constructor(D){super(D,Kg)}getProgramIds(){return["raster"]}},sky:class extends xh{constructor(D){super(D,g0),this._updateColorRamp()}_handleSpecialPaintPropertyUpdate(D){D==="sky-gradient"?this._updateColorRamp():D!=="sky-atmosphere-sun"&&D!=="sky-atmosphere-halo-color"&&D!=="sky-atmosphere-color"&&D!=="sky-atmosphere-sun-intensity"||(this._skyboxInvalidated=!0)}_updateColorRamp(){this.colorRamp=Xp({expression:this._transitionablePaint._values["sky-gradient"].value.expression,evaluationKey:"skyRadialProgress"}),this.colorRampTexture&&(this.colorRampTexture.destroy(),this.colorRampTexture=null)}needsSkyboxCapture(D){if(this._skyboxInvalidated||!this.skyboxTexture||!this.skyboxGeometry)return!0;if(!this.paint.get("sky-atmosphere-sun")){const _=D.style.light.properties.get("position");return this._lightPosition.azimuthal!==_.azimuthal||this._lightPosition.polar!==_.polar}return!1}getCenter(D,_){if(this.paint.get("sky-type")==="atmosphere"){const X=this.paint.get("sky-atmosphere-sun"),de=!X,Ge=D.style.light,ft=Ge.properties.get("position");return de&&Ge.properties.get("anchor")==="viewport"&&wn("The sun direction is attached to a light with viewport anchor, lighting may behave unexpectedly."),de?Ig(ft.azimuthal,90-ft.polar,_):Ig(X[0],90-X[1],_)}const k=this.paint.get("sky-gradient-center");return Ig(k[0],90-k[1],_)}is3D(){return!1}isSky(){return!0}markSkyboxValid(D){this._skyboxInvalidated=!1,this._lightPosition=D.style.light.properties.get("position")}hasOffscreenPass(){return!0}getProgramIds(){const D=this.paint.get("sky-type");return D==="atmosphere"?["skyboxCapture","skybox"]:D==="gradient"?["skyboxGradient"]:null}}};class w3{constructor(_,k,X,de){this.context=_,this.format=X,this.texture=_.gl.createTexture(),this.update(k,de)}update(_,k,X){const{width:de,height:Ge}=_,{context:ft}=this,{gl:_t}=ft,{HTMLImageElement:At,HTMLCanvasElement:Nt,HTMLVideoElement:cn,ImageData:vn,ImageBitmap:bn}=J;if(_t.bindTexture(_t.TEXTURE_2D,this.texture),ft.pixelStoreUnpackFlipY.set(!1),ft.pixelStoreUnpack.set(1),ft.pixelStoreUnpackPremultiplyAlpha.set(this.format===_t.RGBA&&(!k||k.premultiply!==!1)),X||this.size&&this.size[0]===de&&this.size[1]===Ge){const{x:jn,y:Zn}=X||{x:0,y:0};_ instanceof At||_ instanceof Nt||_ instanceof cn||_ instanceof vn||bn&&_ instanceof bn?_t.texSubImage2D(_t.TEXTURE_2D,0,jn,Zn,_t.RGBA,_t.UNSIGNED_BYTE,_):_t.texSubImage2D(_t.TEXTURE_2D,0,jn,Zn,de,Ge,_t.RGBA,_t.UNSIGNED_BYTE,_.data)}else this.size=[de,Ge],_ instanceof At||_ instanceof Nt||_ instanceof cn||_ instanceof vn||bn&&_ instanceof bn?_t.texImage2D(_t.TEXTURE_2D,0,this.format,this.format,_t.UNSIGNED_BYTE,_):_t.texImage2D(_t.TEXTURE_2D,0,this.format,de,Ge,0,this.format,_t.UNSIGNED_BYTE,_.data);this.useMipmap=!!(k&&k.useMipmap&&this.isSizePowerOfTwo()),this.useMipmap&&_t.generateMipmap(_t.TEXTURE_2D)}bind(_,k){const{context:X}=this,{gl:de}=X;de.bindTexture(de.TEXTURE_2D,this.texture),_!==this.filter&&(de.texParameteri(de.TEXTURE_2D,de.TEXTURE_MAG_FILTER,_),de.texParameteri(de.TEXTURE_2D,de.TEXTURE_MIN_FILTER,this.useMipmap?_===de.NEAREST?de.NEAREST_MIPMAP_NEAREST:de.LINEAR_MIPMAP_NEAREST:_),this.filter=_),k!==this.wrap&&(de.texParameteri(de.TEXTURE_2D,de.TEXTURE_WRAP_S,k),de.texParameteri(de.TEXTURE_2D,de.TEXTURE_WRAP_T,k),this.wrap=k)}isSizePowerOfTwo(){return this.size[0]===this.size[1]&&Math.log(this.size[0])/Math.LN2%1==0}destroy(){const{gl:_}=this.context;_.deleteTexture(this.texture),this.texture=null}}class Rg{constructor(_,k){this.width=_,this.height=k,this.nextRow=0,this.image=new Th({width:_,height:k}),this.positions={},this.uploaded=!1}getDash(_,k){const X=this.getKey(_,k);return this.positions[X]}trim(){const _=this.width,k=this.height=nn(this.nextRow);this.image.resize({width:_,height:k})}getKey(_,k){return _.join(",")+k}getDashRanges(_,k,X){const de=[];let Ge=_.length%2==1?-_[_.length-1]*X:0,ft=_[0]*X,_t=!0;de.push({left:Ge,right:ft,isDash:_t,zeroLength:_[0]===0});let At=_[0];for(let Nt=1;Nt<_.length;Nt++){_t=!_t;const cn=_[Nt];Ge=At*X,At+=cn,ft=At*X,de.push({left:Ge,right:ft,isDash:_t,zeroLength:cn===0})}return de}addRoundDash(_,k,X){const de=k/2;for(let Ge=-X;Ge<=X;Ge++){const ft=this.width*(this.nextRow+X+Ge);let _t=0,At=_[_t];for(let Nt=0;Nt<this.width;Nt++){Nt/At.right>1&&(At=_[++_t]);const cn=Math.abs(Nt-At.left),vn=Math.abs(Nt-At.right),bn=Math.min(cn,vn);let jn;const Zn=Ge/X*(de+1);if(At.isDash){const Br=de-Math.abs(Zn);jn=Math.sqrt(bn*bn+Br*Br)}else jn=de-Math.sqrt(bn*bn+Zn*Zn);this.image.data[ft+Nt]=Math.max(0,Math.min(255,jn+128))}}}addRegularDash(_,k){for(let At=_.length-1;At>=0;--At){const Nt=_[At],cn=_[At+1];Nt.zeroLength?_.splice(At,1):cn&&cn.isDash===Nt.isDash&&(cn.left=Nt.left,_.splice(At,1))}const X=_[0],de=_[_.length-1];X.isDash===de.isDash&&(X.left=de.left-this.width,de.right=X.right+this.width);const Ge=this.width*this.nextRow;let ft=0,_t=_[ft];for(let At=0;At<this.width;At++){At/_t.right>1&&(_t=_[++ft]);const Nt=Math.abs(At-_t.left),cn=Math.abs(At-_t.right),vn=Math.min(Nt,cn);this.image.data[Ge+At]=Math.max(0,Math.min(255,(_t.isDash?vn:-vn)+k+128))}}addDash(_,k){const X=this.getKey(_,k);if(this.positions[X])return this.positions[X];const de=k==="round",Ge=de?7:0,ft=2*Ge+1;if(this.nextRow+ft>this.height)return wn("LineAtlas out of space"),null;_.length===0&&_.push(1);let _t=0;for(let cn=0;cn<_.length;cn++)_[cn]<0&&(wn("Negative value is found in line dasharray, replacing values with 0"),_[cn]=0),_t+=_[cn];if(_t!==0){const cn=this.width/_t,vn=this.getDashRanges(_,this.width,cn);de?this.addRoundDash(vn,cn,Ge):this.addRegularDash(vn,k==="square"?.5*cn:0)}const At=this.nextRow+Ge;this.nextRow+=ft;const Nt={tl:[At,Ge],br:[_t,0]};return this.positions[X]=Nt,Nt}}Zo(Rg,"LineAtlas");class v0{constructor(_){this._callback=_,this._triggered=!1,typeof MessageChannel<"u"&&(this._channel=new MessageChannel,this._channel.port2.onmessage=()=>{this._triggered=!1,this._callback()})}trigger(){this._triggered||(this._triggered=!0,this._channel?this._channel.port1.postMessage(!0):setTimeout(()=>{this._triggered=!1,this._callback()},0))}remove(){this._channel=void 0,this._callback=()=>{}}}const Xg=J.performance;function _0(D){const _=D?D.url.toString():void 0;return Xg.getEntriesByName(_)}class E0{constructor(){this.tasks={},this.taskQueue=[],pn(["process"],this),this.invoker=new v0(this.process),this.nextId=0}add(_,k){const X=this.nextId++,de=function({type:Ge,isSymbolTile:ft,zoom:_t}){return _t=_t||0,Ge==="message"?0:Ge!=="maybePrepare"||ft?Ge!=="parseTile"||ft?Ge==="parseTile"&&ft?300-_t:Ge==="maybePrepare"&&ft?400-_t:500:200-_t:100-_t}(k);if(de===0){$n();try{_()}finally{}return{cancel:()=>{}}}return this.tasks[X]={fn:_,metadata:k,priority:de,id:X},this.taskQueue.push(X),this.invoker.trigger(),{cancel:()=>{delete this.tasks[X]}}}process(){$n();try{if(this.taskQueue=this.taskQueue.filter(X=>!!this.tasks[X]),!this.taskQueue.length)return;const _=this.pick();if(_===null)return;const k=this.tasks[_];if(delete this.tasks[_],this.taskQueue.length&&this.invoker.trigger(),!k)return;k.fn()}finally{}}pick(){let _=null,k=1/0;for(let de=0;de<this.taskQueue.length;de++){const Ge=this.tasks[this.taskQueue[de]];Ge.priority<k&&(k=Ge.priority,_=de)}if(_===null)return null;const X=this.taskQueue[_];return this.taskQueue.splice(_,1),X}remove(){this.invoker.remove()}}const f=Di([{type:"Float32",name:"a_globe_pos",components:3},{type:"Float32",name:"a_merc_pos",components:2},{type:"Float32",name:"a_uv",components:2}]),E=Di([{type:"Float32",name:"a_pos",components:3},{type:"Float32",name:"a_uv",components:2}]),{members:W}=f,ge=Di([{name:"a_pos_3",components:3,type:"Int16"}]);var ct=Di([{name:"a_pos",type:"Int16",components:2}]);const gt=Ml/Math.PI/2,St=-gt,Pt=gt,sn=[new qd([St,St,St],[Pt,Pt,Pt]),new qd([St,St,St],[0,0,Pt]),new qd([0,St,St],[Pt,0,Pt]),new qd([St,0,St],[0,Pt,Pt]),new qd([0,0,St],[Pt,Pt,Pt])];class ln{constructor(_,k,X){this.a=Mp([],_,X),this.b=Mp([],k,X),this.center=X;const de=Ic([],this.a),Ge=Ic([],this.b);this.angle=Math.acos(Zc(de,Ge))}}function Sn(D,_){if(D.angle===0)return null;let k;return k=D.a[_]===0?1/D.angle*.5*Math.PI:1/D.angle*Math.atan(D.b[_]/D.a[_]/Math.sin(D.angle)-1/Math.tan(D.angle)),k<0||k>1?null:function(X,de,Ge,ft){const _t=Math.sin(Ge);return X*(Math.sin((1-ft)*Ge)/_t)+de*(Math.sin(ft*Ge)/_t)}(D.a[_],D.b[_],D.angle,Te(k,0,1))+D.center[_]}function En(D){if(D.z<=1)return sn[D.z+2*D.y+D.x];const[_,k]=mn(D),X=[mr(_[0],_[1]),mr(_[0],k[1]),mr(k[0],_[1]),mr(k[0],k[1])],de=[Pt,Pt,Pt],Ge=[St,St,St];for(const ft of X)de[0]=Math.min(de[0],ft[0]),de[1]=Math.min(de[1],ft[1]),de[2]=Math.min(de[2],ft[2]),Ge[0]=Math.max(Ge[0],ft[0]),Ge[1]=Math.max(Ge[1],ft[1]),Ge[2]=Math.max(Ge[2],ft[2]);return new qd(de,Ge)}function On(D,_,k){const X=_/D.worldSize,de=(Ka,Do)=>{Hm(Ka,Ka,X),Hm(Do,Do,X)},Ge=Number.MAX_VALUE,ft=[-Ge,-Ge,-Ge],_t=[Ge,Ge,Ge],At=da(D);if(k.z<=1){const Ka=En(k).getCorners();for(let Do=0;Do<Ka.length;Do++)Sh(Ka[Do],Ka[Do],At),Yp(_t,_t,Ka[Do]),wp(ft,ft,Ka[Do]);return de(_t,ft),new qd(_t,ft)}const[Nt,cn]=mn(k),vn=new Hc;vn.setSouthWest([Nt[1],cn[0]]),vn.setNorthEast([cn[1],Nt[0]]);const bn=[mr(vn.getSouth(),vn.getWest()),mr(vn.getSouth(),vn.getEast()),mr(vn.getNorth(),vn.getEast()),mr(vn.getNorth(),vn.getWest())];for(let Ka=0;Ka<bn.length;Ka++)Sh(bn[Ka],bn[Ka],At),Yp(_t,_t,bn[Ka]),wp(ft,ft,bn[Ka]);if(vn.contains(D.center))return ft[2]=0,de(_t,ft),new qd(_t,ft);const jn=[At[12],At[13],At[14]],Zn=D.center.lng,Br=Te(D.center.lat,-85.051129,Jd),Jr=[ch(Zn),$p(Br)],si=vn.getCenter().lng,Li=Te(vn.getCenter().lat,-85.051129,Jd),vi=[ch(si),$p(Li)];let ui=new Array(3),ua=0;const ba=Jr[0]-vi[0],Ua=Jr[1]-vi[1];if(Math.abs(ba)>Math.abs(Ua))ua=ba>=0?1:3,ui=jn;else{ua=Ua>=0?0:2;const Ka=[At[4],At[5],At[6]];let Do;Do=Ua>=0?-Math.sin(ne(vn.getSouth()))*gt:-Math.sin(ne(vn.getNorth()))*gt,ui=c3(ui,jn,Ka,Do)}const Ga=bn[ua],ho=bn[(ua+1)%4],bo=new ln(Ga,ho,ui),Va=[Sn(bo,0)||Ga[0],Sn(bo,1)||Ga[1],Sn(bo,2)||Ga[2]];return _t[2]=Math.min(Ga[2],ho[2]),Yp(_t,_t,Va),wp(ft,ft,Va),de(_t,ft),new qd(_t,ft)}function mn(D){const _=1<<D.z,k=D.x/_,X=(D.x+1)/_,de=(D.y+1)/_;return[[ed(D.y/_),Wd(k)],[ed(de),Wd(X)]]}function Hn(D,_,k,X=gt){return k=ne(k),[D*Math.sin(k)*X,-_*X,D*Math.cos(k)*X]}function mr(D,_,k){return Hn(Math.cos(ne(D)),Math.sin(ne(D)),_,k)}function _r(D,_,k){const X=Math.pow(2,k.z),de=(D/Ml+k.x)/X;return mr(ed((_/Ml+k.y)/X),Wd(de))}function gi(D){return 16383/Math.max(...Mp([],D.max,D.min))}function Ci(D){const _=ld(new Float64Array(16)),k=gi(D);var X,de;return Cu(_,_,[k,k,k]),Ch(_,_,((X=[])[0]=-(de=D.min)[0],X[1]=-de[1],X[2]=-de[2],X)),_}function $i(D,_,k,X,de){const Ge=function(At){const Nt=Ml/(2*Math.PI);return At/(2*Math.PI)/Nt}(k),ft=[D,_,-k/(2*Math.PI)],_t=ld(new Float64Array(16));return Ch(_t,_t,ft),Cu(_t,_t,[Ge,Ge,Ge]),xp(_t,_t,ne(-de)),Ru(_t,_t,ne(-X)),_t}function da(D){const{x:_,y:k}=D.point,{lng:X,lat:de}=D._center;return $i(_,k,D.worldSize,X,de)}const ji=ne(85),Sa=Math.cos(ji),ea=Math.sin(ji);function Ba(D,_,k){var X=2*Math.PI*6378137/256/Math.pow(2,k);return[D*X-2*Math.PI*6378137/2,_*X-2*Math.PI*6378137/2]}class Ya{constructor(_,k,X){this.z=_,this.x=k,this.y=X,this.key=go(0,_,_,k,X)}equals(_){return this.z===_.z&&this.x===_.x&&this.y===_.y}url(_,k){const X=function(Ge,ft,_t){var At=Ba(256*Ge,256*(ft=Math.pow(2,_t)-ft-1),_t),Nt=Ba(256*(Ge+1),256*(ft+1),_t);return At[0]+","+At[1]+","+Nt[0]+","+Nt[1]}(this.x,this.y,this.z),de=function(Ge,ft,_t){let At,Nt="";for(let cn=Ge;cn>0;cn--)At=1<<cn-1,Nt+=(ft&At?1:0)+(_t&At?2:0);return Nt}(this.z,this.x,this.y);return _[(this.x+this.y)%_.length].replace("{prefix}",(this.x%16).toString(16)+(this.y%16).toString(16)).replace("{z}",String(this.z)).replace("{x}",String(this.x)).replace("{y}",String(k==="tms"?Math.pow(2,this.z)-this.y-1:this.y)).replace("{quadkey}",de).replace("{bbox-epsg-3857}",X)}toString(){return`${this.z}/${this.x}/${this.y}`}}class ro{constructor(_,k){this.wrap=_,this.canonical=k,this.key=go(_,k.z,k.z,k.x,k.y)}}class $a{constructor(_,k,X,de,Ge){this.overscaledZ=_,this.wrap=k,this.canonical=new Ya(X,+de,+Ge),this.key=k===0&&_===X?this.canonical.key:go(k,_,X,de,Ge)}equals(_){return this.overscaledZ===_.overscaledZ&&this.wrap===_.wrap&&this.canonical.equals(_.canonical)}scaledTo(_){const k=this.canonical.z-_;return _>this.canonical.z?new $a(_,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y):new $a(_,this.wrap,_,this.canonical.x>>k,this.canonical.y>>k)}calculateScaledKey(_,k=!0){if(this.overscaledZ===_&&k)return this.key;if(_>this.canonical.z)return go(this.wrap*+k,_,this.canonical.z,this.canonical.x,this.canonical.y);{const X=this.canonical.z-_;return go(this.wrap*+k,_,_,this.canonical.x>>X,this.canonical.y>>X)}}isChildOf(_){if(_.wrap!==this.wrap)return!1;const k=this.canonical.z-_.canonical.z;return _.overscaledZ===0||_.overscaledZ<this.overscaledZ&&_.canonical.x===this.canonical.x>>k&&_.canonical.y===this.canonical.y>>k}children(_){if(this.overscaledZ>=_)return[new $a(this.overscaledZ+1,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y)];const k=this.canonical.z+1,X=2*this.canonical.x,de=2*this.canonical.y;return[new $a(k,this.wrap,k,X,de),new $a(k,this.wrap,k,X+1,de),new $a(k,this.wrap,k,X,de+1),new $a(k,this.wrap,k,X+1,de+1)]}isLessThan(_){return this.wrap<_.wrap||!(this.wrap>_.wrap)&&(this.overscaledZ<_.overscaledZ||!(this.overscaledZ>_.overscaledZ)&&(this.canonical.x<_.canonical.x||!(this.canonical.x>_.canonical.x)&&this.canonical.y<_.canonical.y))}wrapped(){return new $a(this.overscaledZ,0,this.canonical.z,this.canonical.x,this.canonical.y)}unwrapTo(_){return new $a(this.overscaledZ,_,this.canonical.z,this.canonical.x,this.canonical.y)}overscaleFactor(){return Math.pow(2,this.overscaledZ-this.canonical.z)}toUnwrapped(){return new ro(this.wrap,this.canonical)}toString(){return`${this.overscaledZ}/${this.canonical.x}/${this.canonical.y}`}}function go(D,_,k,X,de){const Ge=1<<Math.min(k,22);let ft=Ge*(de%Ge)+X%Ge;return D&&k<22&&(ft+=Ge*Ge*((D<0?-2*D-1:2*D)%(1<<2*(22-k)))),16*(32*ft+k)+(_-k)}function ko(D,_){if(!_.isReprojectedInTileSpace)return{scale:1<<D.z,x:D.x,y:D.y,x2:D.x+1,y2:D.y+1,projection:_};const k=Math.pow(2,-D.z),X=D.x*k,de=(D.x+1)*k,Ge=D.y*k,ft=(D.y+1)*k,_t=Wd(X),At=Wd(de),Nt=ed(Ge),cn=ed(ft),vn=_.project(_t,Nt),bn=_.project(At,Nt),jn=_.project(At,cn),Zn=_.project(_t,cn);let Br=Math.min(vn.x,bn.x,jn.x,Zn.x),Jr=Math.min(vn.y,bn.y,jn.y,Zn.y),si=Math.max(vn.x,bn.x,jn.x,Zn.x),Li=Math.max(vn.y,bn.y,jn.y,Zn.y);const vi=k/16;function ui(ba,Ua,Ga,ho,bo,Va){const Ka=(Ga+bo)/2,Do=(ho+Va)/2,$o=_.project(Wd(Ka),ed(Do)),Ro=Math.max(0,Br-$o.x,Jr-$o.y,$o.x-si,$o.y-Li);Br=Math.min(Br,$o.x),si=Math.max(si,$o.x),Jr=Math.min(Jr,$o.y),Li=Math.max(Li,$o.y),Ro>vi&&(ui(ba,$o,Ga,ho,Ka,Do),ui($o,Ua,Ka,Do,bo,Va))}ui(vn,bn,X,Ge,de,Ge),ui(bn,jn,de,Ge,de,ft),ui(jn,Zn,de,ft,X,ft),ui(Zn,vn,X,ft,X,Ge),Br-=vi,Jr-=vi,si+=vi,Li+=vi;const ua=1/Math.max(si-Br,Li-Jr);return{scale:ua,x:Br*ua,y:Jr*ua,x2:si*ua,y2:Li*ua,projection:_}}Zo(Ya,"CanonicalTileID"),Zo($a,"OverscaledTileID",{omit:["projMatrix"]});class Qa{constructor(_){this._stringToNumber={},this._numberToString=[];for(let k=0;k<_.length;k++){const X=_[k];this._stringToNumber[X]=k,this._numberToString[k]=X}}encode(_){return this._stringToNumber[_]}decode(_){return this._numberToString[_]}}const Ha=["tile","layer","source","sourceLayer","state"];class fs{constructor(_,k,X,de,Ge){this.type="Feature",this._vectorTileFeature=_,this._z=k,this._x=X,this._y=de,this.properties=_.properties,this.id=Ge}get geometry(){return this._geometry===void 0&&(this._geometry=this._vectorTileFeature.toGeoJSON(this._x,this._y,this._z).geometry),this._geometry}set geometry(_){this._geometry=_}toJSON(){const _={type:"Feature",geometry:this.geometry,properties:this.properties};this.id!==void 0&&(_.id=this.id);for(const k of Ha)this[k]!==void 0&&(_[k]=this[k]);return _}}const os=32,Ks=33,Xs=new Uint16Array(8184);for(let D=0;D<2046;D++){let _=D+2,k=0,X=0,de=0,Ge=0,ft=0,_t=0;for(1&_?de=Ge=ft=os:k=X=_t=os;(_>>=1)>1;){const Nt=k+de>>1,cn=X+Ge>>1;1&_?(de=k,Ge=X,k=ft,X=_t):(k=de,X=Ge,de=ft,Ge=_t),ft=Nt,_t=cn}const At=4*D;Xs[At+0]=k,Xs[At+1]=X,Xs[At+2]=de,Xs[At+3]=Ge}const zs=new Uint16Array(2178),gl=new Uint8Array(1089),Os=new Uint16Array(1089);function Ii(D){return D===0?-.03125:D===32?.03125:0}var va=Di([{name:"a_pos",type:"Int16",components:2},{name:"a_texture_pos",type:"Int16",components:2}]);const Bo={type:2,extent:Ml,loadGeometry:()=>[[new G(0,0),new G(8193,0),new G(8193,8193),new G(0,8193),new G(0,0)]]};class Co{constructor(_,k,X,de,Ge){this.tileID=_,this.uid=kt(),this.uses=0,this.tileSize=k,this.tileZoom=X,this.buckets={},this.expirationTime=null,this.queryPadding=0,this.hasSymbolBuckets=!1,this.hasRTLText=!1,this.dependencies={},this.isRaster=Ge,this.expiredRequestCount=0,this.state="loading",de&&de.transform&&(this.projection=de.transform.projection)}registerFadeDuration(_){const k=_+this.timeAdded;k<xi.now()||this.fadeEndTime&&k<this.fadeEndTime||(this.fadeEndTime=k)}wasRequested(){return this.state==="errored"||this.state==="loaded"||this.state==="reloading"}get tileTransform(){return this._tileTransform||(this._tileTransform=ko(this.tileID.canonical,this.projection)),this._tileTransform}loadVectorData(_,k,X){if(this.unloadVectorData(),this.state="loaded",_){_.featureIndex&&(this.latestFeatureIndex=_.featureIndex,_.rawTileData?(this.latestRawTileData=_.rawTileData,this.latestFeatureIndex.rawTileData=_.rawTileData):this.latestRawTileData&&(this.latestFeatureIndex.rawTileData=this.latestRawTileData)),this.collisionBoxArray=_.collisionBoxArray,this.buckets=function(de,Ge){const ft={};if(!Ge)return ft;for(const _t of de){const At=_t.layerIds.map(Nt=>Ge.getLayer(Nt)).filter(Boolean);if(At.length!==0){_t.layers=At,_t.stateDependentLayerIds&&(_t.stateDependentLayers=_t.stateDependentLayerIds.map(Nt=>At.filter(cn=>cn.id===Nt)[0]));for(const Nt of At)ft[Nt.id]=_t}}return ft}(_.buckets,k.style),this.hasSymbolBuckets=!1;for(const de in this.buckets){const Ge=this.buckets[de];if(Ge instanceof Hf){if(this.hasSymbolBuckets=!0,!X)break;Ge.justReloaded=!0}}if(this.hasRTLText=!1,this.hasSymbolBuckets)for(const de in this.buckets){const Ge=this.buckets[de];if(Ge instanceof Hf&&Ge.hasRTLText){this.hasRTLText=!0,$c.isLoading()||$c.isLoaded()||Af()!=="deferred"||Qc();break}}this.queryPadding=0;for(const de in this.buckets){const Ge=this.buckets[de];this.queryPadding=Math.max(this.queryPadding,k.style.getLayer(de).queryRadius(Ge))}_.imageAtlas&&(this.imageAtlas=_.imageAtlas),_.glyphAtlasImage&&(this.glyphAtlasImage=_.glyphAtlasImage),_.lineAtlas&&(this.lineAtlas=_.lineAtlas)}else this.collisionBoxArray=new yh}unloadVectorData(){if(this.hasData()){for(const _ in this.buckets)this.buckets[_].destroy();this.buckets={},this.imageAtlas&&(this.imageAtlas=null),this.lineAtlas&&(this.lineAtlas=null),this.imageAtlasTexture&&this.imageAtlasTexture.destroy(),this.glyphAtlasTexture&&this.glyphAtlasTexture.destroy(),this.lineAtlasTexture&&this.lineAtlasTexture.destroy(),this._tileBoundsBuffer&&(this._tileBoundsBuffer.destroy(),this._tileBoundsIndexBuffer.destroy(),this._tileBoundsSegments.destroy(),this._tileBoundsBuffer=null),this._tileDebugBuffer&&(this._tileDebugBuffer.destroy(),this._tileDebugIndexBuffer.destroy(),this._tileDebugSegments.destroy(),this._tileDebugBuffer=null),this._globeTileDebugBorderBuffer&&(this._globeTileDebugBorderBuffer.destroy(),this._globeTileDebugBorderBuffer=null),this._tileDebugTextBuffer&&(this._tileDebugTextBuffer.destroy(),this._tileDebugTextSegments.destroy(),this._tileDebugTextIndexBuffer.destroy(),this._tileDebugTextBuffer=null),this._globeTileDebugTextBuffer&&(this._globeTileDebugTextBuffer.destroy(),this._globeTileDebugTextBuffer=null),this.latestFeatureIndex=null,this.state="unloaded"}}getBucket(_){return this.buckets[_.id]}upload(_){for(const X in this.buckets){const de=this.buckets[X];de.uploadPending()&&de.upload(_)}const k=_.gl;this.imageAtlas&&!this.imageAtlas.uploaded&&(this.imageAtlasTexture=new w3(_,this.imageAtlas.image,k.RGBA),this.imageAtlas.uploaded=!0),this.glyphAtlasImage&&(this.glyphAtlasTexture=new w3(_,this.glyphAtlasImage,k.ALPHA),this.glyphAtlasImage=null),this.lineAtlas&&!this.lineAtlas.uploaded&&(this.lineAtlasTexture=new w3(_,this.lineAtlas.image,k.ALPHA),this.lineAtlas.uploaded=!0)}prepare(_){this.imageAtlas&&this.imageAtlas.patchUpdatedImages(_,this.imageAtlasTexture)}queryRenderedFeatures(_,k,X,de,Ge,ft,_t,At){return this.latestFeatureIndex&&this.latestFeatureIndex.rawTileData?this.latestFeatureIndex.query({tileResult:de,pixelPosMatrix:_t,transform:ft,params:Ge,tileTransform:this.tileTransform},_,k,X):{}}querySourceFeatures(_,k){const X=this.latestFeatureIndex;if(!X||!X.rawTileData)return;const de=X.loadVTLayers(),Ge=k?k.sourceLayer:"",ft=de._geojsonTileLayer||de[Ge];if(!ft)return;const _t=Gl(k&&k.filter),{z:At,x:Nt,y:cn}=this.tileID.canonical,vn={z:At,x:Nt,y:cn};for(let bn=0;bn<ft.length;bn++){const jn=ft.feature(bn);if(_t.needGeometry){const Jr=vp(jn,!0);if(!_t.filter(new Iu(this.tileID.overscaledZ),Jr,this.tileID.canonical))continue}else if(!_t.filter(new Iu(this.tileID.overscaledZ),jn))continue;const Zn=X.getId(jn,Ge),Br=new fs(jn,At,Nt,cn,Zn);Br.tile=vn,_.push(Br)}}hasData(){return this.state==="loaded"||this.state==="reloading"||this.state==="expired"}patternsLoaded(){return!!this.imageAtlas&&!!Object.keys(this.imageAtlas.patternPositions).length}setExpiryData(_){const k=this.expirationTime;if(_.cacheControl){const X=Xr(_.cacheControl);X["max-age"]&&(this.expirationTime=Date.now()+1e3*X["max-age"])}else _.expires&&(this.expirationTime=new Date(_.expires).getTime());if(this.expirationTime){const X=Date.now();let de=!1;if(this.expirationTime>X)de=!1;else if(k)if(this.expirationTime<k)de=!0;else{const Ge=this.expirationTime-k;Ge?this.expirationTime=X+Math.max(Ge,3e4):de=!0}else de=!0;de?(this.expiredRequestCount++,this.state="expired"):this.expiredRequestCount=0}}getExpiryTimeout(){if(this.expirationTime)return this.expiredRequestCount?1e3*(1<<Math.min(this.expiredRequestCount-1,31)):Math.min(this.expirationTime-new Date().getTime(),Math.pow(2,31)-1)}setFeatureState(_,k){if(!this.latestFeatureIndex||!this.latestFeatureIndex.rawTileData||Object.keys(_).length===0||!k)return;const X=this.latestFeatureIndex.loadVTLayers(),de=k.style.listImages();for(const Ge in this.buckets){if(!k.style.hasLayer(Ge))continue;const ft=this.buckets[Ge],_t=ft.layers[0].sourceLayer||"_geojsonTileLayer",At=X[_t],Nt=_[_t];if(!At||!Nt||Object.keys(Nt).length===0)continue;if(ft.update(Nt,At,de,this.imageAtlas&&this.imageAtlas.patternPositions||{}),ft instanceof L3||ft instanceof Tl){const vn=k.style._getSourceCache(ft.layers[0].source);k._terrain&&k._terrain.enabled&&vn&&ft.programConfigurations.needsUpload&&k._terrain._clearRenderCacheForTile(vn.id,this.tileID)}const cn=k&&k.style&&k.style.getLayer(Ge);cn&&(this.queryPadding=Math.max(this.queryPadding,cn.queryRadius(ft)))}}holdingForFade(){return this.symbolFadeHoldUntil!==void 0}symbolFadeFinished(){return!this.symbolFadeHoldUntil||this.symbolFadeHoldUntil<xi.now()}clearFadeHold(){this.symbolFadeHoldUntil=void 0}setHoldDuration(_){this.symbolFadeHoldUntil=xi.now()+_}setTexture(_,k){const X=k.context,de=X.gl;this.texture=k.getTileTexture(_.width),this.texture?this.texture.update(_,{useMipmap:!0}):(this.texture=new w3(X,_,de.RGBA,{useMipmap:!0}),this.texture.bind(de.LINEAR,de.CLAMP_TO_EDGE),X.extTextureFilterAnisotropic&&de.texParameterf(de.TEXTURE_2D,X.extTextureFilterAnisotropic.TEXTURE_MAX_ANISOTROPY_EXT,X.extTextureFilterAnisotropicMax))}setDependencies(_,k){const X={};for(const de of k)X[de]=!0;this.dependencies[_]=X}hasDependency(_,k){for(const X of _){const de=this.dependencies[X];if(de){for(const Ge of k)if(de[Ge])return!0}}return!1}clearQueryDebugViz(){}_makeDebugTileBoundsBuffers(_,k){if(!k||k.name==="mercator"||this._tileDebugBuffer)return;const X=bh(Bo,this.tileID.canonical,this.tileTransform)[0],de=new wi,Ge=new Yl;for(let ft=0;ft<X.length;ft++){const{x:_t,y:At}=X[ft];de.emplaceBack(_t,At),Ge.emplaceBack(ft)}Ge.emplaceBack(0),this._tileDebugIndexBuffer=_.createIndexBuffer(Ge),this._tileDebugBuffer=_.createVertexBuffer(de,ct.members),this._tileDebugSegments=hc.simpleSegment(0,0,de.length,Ge.length)}_makeTileBoundsBuffers(_,k){if(this._tileBoundsBuffer||!k||k.name==="mercator")return;const X=bh(Bo,this.tileID.canonical,this.tileTransform)[0];let de,Ge;if(this.isRaster){const ft=function(_t,At){const Nt=ko(_t,At),cn=Math.pow(2,_t.z);for(let Jr=0;Jr<Ks;Jr++)for(let si=0;si<Ks;si++){const Li=Wd((_t.x+(si+Ii(si))/os)/cn),vi=ed((_t.y+(Jr+Ii(Jr))/os)/cn),ui=At.project(Li,vi),ua=Jr*Ks+si;zs[2*ua+0]=Math.round((ui.x*Nt.scale-Nt.x)*Ml),zs[2*ua+1]=Math.round((ui.y*Nt.scale-Nt.y)*Ml)}gl.fill(0),Os.fill(0);for(let Jr=2045;Jr>=0;Jr--){const si=4*Jr,Li=Xs[si+0],vi=Xs[si+1],ui=Xs[si+2],ua=Xs[si+3],ba=Li+ui>>1,Ua=vi+ua>>1,Ga=ba+Ua-vi,ho=Ua+Li-ba,bo=vi*Ks+Li,Va=ua*Ks+ui,Ka=Ua*Ks+ba,Do=Math.hypot((zs[2*bo+0]+zs[2*Va+0])/2-zs[2*Ka+0],(zs[2*bo+1]+zs[2*Va+1])/2-zs[2*Ka+1])>=16;if(gl[Ka]=gl[Ka]||(Do?1:0),Jr<1022){const $o=(vi+ho>>1)*Ks+(Li+Ga>>1),Ro=(ua+ho>>1)*Ks+(ui+Ga>>1);gl[Ka]=gl[Ka]||gl[$o]||gl[Ro]}}const vn=new Oi,bn=new rs;let jn=0;function Zn(Jr,si){const Li=si*Ks+Jr;return Os[Li]===0&&(vn.emplaceBack(zs[2*Li+0],zs[2*Li+1],Jr*Ml/os,si*Ml/os),Os[Li]=++jn),Os[Li]-1}function Br(Jr,si,Li,vi,ui,ua){const ba=Jr+Li>>1,Ua=si+vi>>1;if(Math.abs(Jr-ui)+Math.abs(si-ua)>1&&gl[Ua*Ks+ba])Br(ui,ua,Jr,si,ba,Ua),Br(Li,vi,ui,ua,ba,Ua);else{const Ga=Zn(Jr,si),ho=Zn(Li,vi),bo=Zn(ui,ua);bn.emplaceBack(Ga,ho,bo)}}return Br(0,0,os,os,os,0),Br(os,os,0,0,0,os),{vertices:vn,indices:bn}}(this.tileID.canonical,k);de=ft.vertices,Ge=ft.indices}else{de=new Oi,Ge=new rs;for(const{x:_t,y:At}of X)de.emplaceBack(_t,At,0,0);const ft=Td(de.int16,void 0,4);for(let _t=0;_t<ft.length;_t+=3)Ge.emplaceBack(ft[_t],ft[_t+1],ft[_t+2])}this._tileBoundsBuffer=_.createVertexBuffer(de,va.members),this._tileBoundsIndexBuffer=_.createIndexBuffer(Ge),this._tileBoundsSegments=hc.simpleSegment(0,0,de.length,Ge.length)}_makeGlobeTileDebugBuffers(_,k){if(this._globeTileDebugBorderBuffer||this._globeTileDebugTextBuffer||!k||k.name!=="globe")return;const X=this.tileID.canonical,de=Ci(En(X));this._makeGlobeTileDebugBorderBuffer(_,X,de),this._makeGlobeTileDebugTextBuffer(_,X,de)}_makeGlobeTileDebugBorderBuffer(_,k,X){const de=new wi,Ge=new Yl,ft=new Ti,_t=(Nt,cn,vn,bn,jn)=>{const Zn=(vn-Nt)/(jn-1),Br=(bn-cn)/(jn-1),Jr=de.length;for(let si=0;si<jn;si++){const Li=Nt+si*Zn,vi=cn+si*Br;de.emplaceBack(Li,vi);const ui=_r(Li,vi,k),ua=Sh(ui,ui,X);ft.emplaceBack(ua[0],ua[1],ua[2]),Ge.emplaceBack(Jr+si)}},At=Ml;_t(0,0,At,0,16),_t(At,0,At,At,16),_t(At,At,0,At,16),_t(0,At,0,0,16),this._tileDebugIndexBuffer=_.createIndexBuffer(Ge),this._tileDebugBuffer=_.createVertexBuffer(de,ct.members),this._globeTileDebugBorderBuffer=_.createVertexBuffer(ft,ge.members),this._tileDebugSegments=hc.simpleSegment(0,0,de.length,Ge.length)}_makeGlobeTileDebugTextBuffer(_,k,X){const de=new wi,Ge=new rs,ft=new Ti,_t=25;Ge.reserve(32),de.reserve(_t),ft.reserve(_t);const At=(Nt,cn)=>_t*Nt+cn;for(let Nt=0;Nt<_t;Nt++){const cn=2048*Nt;for(let vn=0;vn<_t;vn++){const bn=2048*vn;de.emplaceBack(bn,cn);const jn=_r(bn,cn,k),Zn=Sh(jn,jn,X);ft.emplaceBack(Zn[0],Zn[1],Zn[2])}}for(let Nt=0;Nt<4;Nt++)for(let cn=0;cn<4;cn++){const vn=At(Nt,cn),bn=At(Nt,cn+1),jn=At(Nt+1,cn),Zn=At(Nt+1,cn+1);Ge.emplaceBack(vn,bn,jn),Ge.emplaceBack(jn,bn,Zn)}this._tileDebugTextIndexBuffer=_.createIndexBuffer(Ge),this._tileDebugTextBuffer=_.createVertexBuffer(de,ct.members),this._globeTileDebugTextBuffer=_.createVertexBuffer(ft,ge.members),this._tileDebugTextSegments=hc.simpleSegment(0,0,_t,32)}}class Cl{constructor(){this.state={},this.stateChanges={},this.deletedStates={}}updateState(_,k,X){const de=String(k);if(this.stateChanges[_]=this.stateChanges[_]||{},this.stateChanges[_][de]=this.stateChanges[_][de]||{},mt(this.stateChanges[_][de],X),this.deletedStates[_]===null){this.deletedStates[_]={};for(const Ge in this.state[_])Ge!==de&&(this.deletedStates[_][Ge]=null)}else if(this.deletedStates[_]&&this.deletedStates[_][de]===null){this.deletedStates[_][de]={};for(const Ge in this.state[_][de])X[Ge]||(this.deletedStates[_][de][Ge]=null)}else for(const Ge in X)this.deletedStates[_]&&this.deletedStates[_][de]&&this.deletedStates[_][de][Ge]===null&&delete this.deletedStates[_][de][Ge]}removeFeatureState(_,k,X){if(this.deletedStates[_]===null)return;const de=String(k);if(this.deletedStates[_]=this.deletedStates[_]||{},X&&k!==void 0)this.deletedStates[_][de]!==null&&(this.deletedStates[_][de]=this.deletedStates[_][de]||{},this.deletedStates[_][de][X]=null);else if(k!==void 0)if(this.stateChanges[_]&&this.stateChanges[_][de])for(X in this.deletedStates[_][de]={},this.stateChanges[_][de])this.deletedStates[_][de][X]=null;else this.deletedStates[_][de]=null;else this.deletedStates[_]=null}getState(_,k){const X=String(k),de=mt({},(this.state[_]||{})[X],(this.stateChanges[_]||{})[X]);if(this.deletedStates[_]===null)return{};if(this.deletedStates[_]){const Ge=this.deletedStates[_][k];if(Ge===null)return{};for(const ft in Ge)delete de[ft]}return de}initializeTileState(_,k){_.setFeatureState(this.state,k)}coalesceChanges(_,k){const X={};for(const de in this.stateChanges){this.state[de]=this.state[de]||{};const Ge={};for(const ft in this.stateChanges[de])this.state[de][ft]||(this.state[de][ft]={}),mt(this.state[de][ft],this.stateChanges[de][ft]),Ge[ft]=this.state[de][ft];X[de]=Ge}for(const de in this.deletedStates){this.state[de]=this.state[de]||{};const Ge={};if(this.deletedStates[de]===null)for(const ft in this.state[de])Ge[ft]={},this.state[de][ft]={};else for(const ft in this.deletedStates[de]){if(this.deletedStates[de][ft]===null)this.state[de][ft]={};else for(const _t of Object.keys(this.deletedStates[de][ft]))delete this.state[de][ft][_t];Ge[ft]=this.state[de][ft]}X[de]=X[de]||{},mt(X[de],Ge)}if(this.stateChanges={},this.deletedStates={},Object.keys(X).length!==0)for(const de in _)_[de].setFeatureState(X,k)}}class Us{constructor(_){this.size=_,this.minimums=[],this.maximums=[],this.leaves=[]}getElevation(_,k){const X=this.toIdx(_,k);return{min:this.minimums[X],max:this.maximums[X]}}isLeaf(_,k){return this.leaves[this.toIdx(_,k)]}toIdx(_,k){return k*this.size+_}}function eo(D,_,k,X){let de=0,Ge=Number.MAX_VALUE;for(let ft=0;ft<3;ft++)if(Math.abs(X[ft])<1e-15){if(k[ft]<D[ft]||k[ft]>_[ft])return null}else{const _t=1/X[ft];let At=(D[ft]-k[ft])*_t,Nt=(_[ft]-k[ft])*_t;if(At>Nt){const cn=At;At=Nt,Nt=cn}if(At>de&&(de=At),Nt<Ge&&(Ge=Nt),de>Ge)return null}return de}function Hs(D,_,k,X,de,Ge,ft,_t,At,Nt,cn){const vn=X-D,bn=de-_,jn=Ge-k,Zn=ft-D,Br=_t-_,Jr=At-k,si=cn[1]*Jr-cn[2]*Br,Li=cn[2]*Zn-cn[0]*Jr,vi=cn[0]*Br-cn[1]*Zn,ui=vn*si+bn*Li+jn*vi;if(Math.abs(ui)<1e-15)return null;const ua=1/ui,ba=Nt[0]-D,Ua=Nt[1]-_,Ga=Nt[2]-k,ho=(ba*si+Ua*Li+Ga*vi)*ua;if(ho<0||ho>1)return null;const bo=Ua*jn-Ga*bn,Va=Ga*vn-ba*jn,Ka=ba*bn-Ua*vn,Do=(cn[0]*bo+cn[1]*Va+cn[2]*Ka)*ua;return Do<0||ho+Do>1?null:(Zn*bo+Br*Va+Jr*Ka)*ua}function Dl(D,_,k){return(D-_)/(k-_)}function Pa(D,_,k,X,de,Ge,ft,_t,At){const Nt=1<<k,cn=Ge-X,vn=ft-de,bn=(D+1)/Nt*cn+X,jn=(_+0)/Nt*vn+de,Zn=(_+1)/Nt*vn+de;_t[0]=(D+0)/Nt*cn+X,_t[1]=jn,At[0]=bn,At[1]=Zn}class Rs{constructor(_){if(this.maximums=[],this.minimums=[],this.leaves=[],this.childOffsets=[],this.nodeCount=0,this.dem=_,this._siblingOffset=[[0,0],[1,0],[0,1],[1,1]],!this.dem)return;const k=function(Ge){const ft=Math.ceil(Math.log2(Ge.dim/8)),_t=[];let At=Math.ceil(Math.pow(2,ft));const Nt=1/At,cn=(jn,Zn,Br,Jr,si)=>{const Li=Jr?1:0,vi=(jn+1)*Br-Li,ui=Zn*Br,ua=(Zn+1)*Br-Li;si[0]=jn*Br,si[1]=ui,si[2]=vi,si[3]=ua};let vn=new Us(At);const bn=[];for(let jn=0;jn<At*At;jn++){cn(jn%At,Math.floor(jn/At),Nt,!1,bn);const Zn=ml(bn[0],bn[1],Ge),Br=ml(bn[2],bn[1],Ge),Jr=ml(bn[2],bn[3],Ge),si=ml(bn[0],bn[3],Ge);vn.minimums.push(Math.min(Zn,Br,Jr,si)),vn.maximums.push(Math.max(Zn,Br,Jr,si)),vn.leaves.push(1)}for(_t.push(vn),At/=2;At>=1;At/=2){const jn=_t[_t.length-1];vn=new Us(At);for(let Zn=0;Zn<At*At;Zn++){cn(Zn%At,Math.floor(Zn/At),2,!0,bn);const Br=jn.getElevation(bn[0],bn[1]),Jr=jn.getElevation(bn[2],bn[1]),si=jn.getElevation(bn[2],bn[3]),Li=jn.getElevation(bn[0],bn[3]),vi=jn.isLeaf(bn[0],bn[1]),ui=jn.isLeaf(bn[2],bn[1]),ua=jn.isLeaf(bn[2],bn[3]),ba=jn.isLeaf(bn[0],bn[3]),Ua=Math.min(Br.min,Jr.min,si.min,Li.min),Ga=Math.max(Br.max,Jr.max,si.max,Li.max),ho=vi&&ui&&ua&&ba;vn.maximums.push(Ga),vn.minimums.push(Ua),vn.leaves.push(Ga-Ua<=5&&ho?1:0)}_t.push(vn)}return _t}(this.dem),X=k.length-1,de=k[X];this._addNode(de.minimums[0],de.maximums[0],de.leaves[0]),this._construct(k,0,0,X,0)}raycastRoot(_,k,X,de,Ge,ft,_t=1){return eo([_,k,-100],[X,de,this.maximums[0]*_t],Ge,ft)}raycast(_,k,X,de,Ge,ft,_t=1){if(!this.nodeCount)return null;const At=this.raycastRoot(_,k,X,de,Ge,ft,_t);if(At==null)return null;const Nt=[],cn=[],vn=[],bn=[],jn=[{idx:0,t:At,nodex:0,nodey:0,depth:0}];for(;jn.length>0;){const{idx:Zn,t:Br,nodex:Jr,nodey:si,depth:Li}=jn.pop();if(this.leaves[Zn]){Pa(Jr,si,Li,_,k,X,de,vn,bn);const ui=1<<Li,ua=(Jr+0)/ui,ba=(Jr+1)/ui,Ua=(si+0)/ui,Ga=(si+1)/ui,ho=ml(ua,Ua,this.dem)*_t,bo=ml(ba,Ua,this.dem)*_t,Va=ml(ba,Ga,this.dem)*_t,Ka=ml(ua,Ga,this.dem)*_t,Do=Hs(vn[0],vn[1],ho,bn[0],vn[1],bo,bn[0],bn[1],Va,Ge,ft),$o=Hs(bn[0],bn[1],Va,vn[0],bn[1],Ka,vn[0],vn[1],ho,Ge,ft),Ro=Math.min(Do!==null?Do:Number.MAX_VALUE,$o!==null?$o:Number.MAX_VALUE);if(Ro!==Number.MAX_VALUE)return Ro;{const No=c3([],Ge,ft,Br);if(Ls(ho,bo,Ka,Va,Dl(No[0],vn[0],bn[0]),Dl(No[1],vn[1],bn[1]))>=No[2])return Br}continue}let vi=0;for(let ui=0;ui<this._siblingOffset.length;ui++){Pa((Jr<<1)+this._siblingOffset[ui][0],(si<<1)+this._siblingOffset[ui][1],Li+1,_,k,X,de,vn,bn),vn[2]=-100,bn[2]=this.maximums[this.childOffsets[Zn]+ui]*_t;const ua=eo(vn,bn,Ge,ft);if(ua!=null){const ba=ua;Nt[ui]=ba;let Ua=!1;for(let Ga=0;Ga<vi&&!Ua;Ga++)ba>=Nt[cn[Ga]]&&(cn.splice(Ga,0,ui),Ua=!0);Ua||(cn[vi]=ui),vi++}}for(let ui=0;ui<vi;ui++){const ua=cn[ui];jn.push({idx:this.childOffsets[Zn]+ua,t:Nt[ua],nodex:(Jr<<1)+this._siblingOffset[ua][0],nodey:(si<<1)+this._siblingOffset[ua][1],depth:Li+1})}}return null}_addNode(_,k,X){return this.minimums.push(_),this.maximums.push(k),this.leaves.push(X),this.childOffsets.push(0),this.nodeCount++}_construct(_,k,X,de,Ge){if(_[de].isLeaf(k,X)===1)return;this.childOffsets[Ge]||(this.childOffsets[Ge]=this.nodeCount);const ft=de-1,_t=_[ft];let At=0,Nt=0;for(let cn=0;cn<this._siblingOffset.length;cn++){const vn=2*k+this._siblingOffset[cn][0],bn=2*X+this._siblingOffset[cn][1],jn=_t.getElevation(vn,bn),Zn=_t.isLeaf(vn,bn),Br=this._addNode(jn.min,jn.max,Zn);Zn&&(At|=1<<cn),Nt||(Nt=Br)}for(let cn=0;cn<this._siblingOffset.length;cn++)At&1<<cn||this._construct(_,2*k+this._siblingOffset[cn][0],2*X+this._siblingOffset[cn][1],ft,Nt+cn)}}function Ls(D,_,k,X,de,Ge){return Qe(Qe(D,k,Ge),Qe(_,X,Ge),de)}function ml(D,_,k){const X=k.dim,de=Te(D*X-.5,0,X-1),Ge=Te(_*X-.5,0,X-1),ft=Math.floor(de),_t=Math.floor(Ge),At=Math.min(ft+1,X-1),Nt=Math.min(_t+1,X-1);return Ls(k.get(ft,_t),k.get(At,_t),k.get(ft,Nt),k.get(At,Nt),de-ft,Ge-_t)}const ns={mapbox:[6553.6,25.6,.1,1e4],terrarium:[256,1,1/256,32768]};class Rl{get tree(){return this._tree||this._buildQuadTree(),this._tree}constructor(_,k,X,de=!1,Ge=!1){if(this.uid=_,k.height!==k.width)throw new RangeError("DEM tiles must be square");if(X&&X!=="mapbox"&&X!=="terrarium")return wn(`"${X}" is not a valid encoding type. Valid types include "mapbox" and "terrarium".`);this.stride=k.height;const ft=this.dim=k.height-2,_t=new Uint32Array(k.data.buffer);if(this.pixels=new Uint8Array(k.data.buffer),this.encoding=X||"mapbox",this.borderReady=de,!de){for(let At=0;At<ft;At++)_t[this._idx(-1,At)]=_t[this._idx(0,At)],_t[this._idx(ft,At)]=_t[this._idx(ft-1,At)],_t[this._idx(At,-1)]=_t[this._idx(At,0)],_t[this._idx(At,ft)]=_t[this._idx(At,ft-1)];_t[this._idx(-1,-1)]=_t[this._idx(0,0)],_t[this._idx(ft,-1)]=_t[this._idx(ft-1,0)],_t[this._idx(-1,ft)]=_t[this._idx(0,ft-1)],_t[this._idx(ft,ft)]=_t[this._idx(ft-1,ft-1)],Ge&&this._buildQuadTree()}}_buildQuadTree(){this._tree=new Rs(this)}get(_,k,X=!1){X&&(_=Te(_,-1,this.dim),k=Te(k,-1,this.dim));const de=4*this._idx(_,k);return(this.encoding==="terrarium"?this._unpackTerrarium:this._unpackMapbox)(this.pixels[de],this.pixels[de+1],this.pixels[de+2])}static getUnpackVector(_){return ns[_]}get unpackVector(){return ns[this.encoding]}_idx(_,k){if(_<-1||_>=this.dim+1||k<-1||k>=this.dim+1)throw new RangeError("out of range source coordinates for DEM data");return(k+1)*this.stride+(_+1)}_unpackMapbox(_,k,X){return(256*_*256+256*k+X)/10-1e4}_unpackTerrarium(_,k,X){return 256*_+k+X/256-32768}static pack(_,k){const X=[0,0,0,0],de=Rl.getUnpackVector(k);let Ge=Math.floor((_+de[3])/de[2]);return X[2]=Ge%256,Ge=Math.floor(Ge/256),X[1]=Ge%256,Ge=Math.floor(Ge/256),X[0]=Ge,X}getPixels(){return new Cd({width:this.stride,height:this.stride},this.pixels)}backfillBorder(_,k,X){if(this.dim!==_.dim)throw new Error("dem dimension mismatch");let de=k*this.dim,Ge=k*this.dim+this.dim,ft=X*this.dim,_t=X*this.dim+this.dim;switch(k){case-1:de=Ge-1;break;case 1:Ge=de+1}switch(X){case-1:ft=_t-1;break;case 1:_t=ft+1}const At=-k*this.dim,Nt=-X*this.dim;for(let cn=ft;cn<_t;cn++)for(let vn=de;vn<Ge;vn++){const bn=4*this._idx(vn,cn),jn=4*this._idx(vn+At,cn+Nt);this.pixels[bn+0]=_.pixels[jn+0],this.pixels[bn+1]=_.pixels[jn+1],this.pixels[bn+2]=_.pixels[jn+2],this.pixels[bn+3]=_.pixels[jn+3]}}onDeserialize(){this._tree&&(this._tree.dem=this)}}Zo(Rl,"DEMData"),Zo(Rs,"DemMinMaxQuadTree",{omit:["dem"]});class ou{constructor(_,k){this.max=_,this.onRemove=k,this.reset()}reset(){for(const _ in this.data)for(const k of this.data[_])k.timeout&&clearTimeout(k.timeout),this.onRemove(k.value);return this.data={},this.order=[],this}add(_,k,X){const de=_.wrapped().key;this.data[de]===void 0&&(this.data[de]=[]);const Ge={value:k,timeout:void 0};if(X!==void 0&&(Ge.timeout=setTimeout(()=>{this.remove(_,Ge)},X)),this.data[de].push(Ge),this.order.push(de),this.order.length>this.max){const ft=this._getAndRemoveByKey(this.order[0]);ft&&this.onRemove(ft)}return this}has(_){return _.wrapped().key in this.data}getAndRemove(_){return this.has(_)?this._getAndRemoveByKey(_.wrapped().key):null}_getAndRemoveByKey(_){const k=this.data[_].shift();return k.timeout&&clearTimeout(k.timeout),this.data[_].length===0&&delete this.data[_],this.order.splice(this.order.indexOf(_),1),k.value}getByKey(_){const k=this.data[_];return k?k[0].value:null}get(_){return this.has(_)?this.data[_.wrapped().key][0].value:null}remove(_,k){if(!this.has(_))return this;const X=_.wrapped().key,de=k===void 0?0:this.data[X].indexOf(k),Ge=this.data[X][de];return this.data[X].splice(de,1),Ge.timeout&&clearTimeout(Ge.timeout),this.data[X].length===0&&delete this.data[X],this.onRemove(Ge.value),this.order.splice(this.order.indexOf(X),1),this}setMaxSize(_){for(this.max=_;this.order.length>this.max;){const k=this._getAndRemoveByKey(this.order[0]);k&&this.onRemove(k)}return this}filter(_){const k=[];for(const X in this.data)for(const de of this.data[X])_(de.value)||k.push(de);for(const X of k)this.remove(X.value.tileID,X)}}class Hu{constructor(_,k,X){this.func=_,this.mask=k,this.range=X}}Hu.ReadOnly=!1,Hu.ReadWrite=!0,Hu.disabled=new Hu(519,Hu.ReadOnly,[0,1]);const rh=7680;class uu{constructor(_,k,X,de,Ge,ft){this.test=_,this.ref=k,this.mask=X,this.fail=de,this.depthFail=Ge,this.pass=ft}}uu.disabled=new uu({func:519,mask:0},0,0,rh,rh,rh);class Ou{constructor(_,k,X){this.blendFunction=_,this.blendColor=k,this.mask=X}}Ou.Replace=[1,0],Ou.disabled=new Ou(Ou.Replace,ga.transparent,[!1,!1,!1,!1]),Ou.unblended=new Ou(Ou.Replace,ga.transparent,[!0,!0,!0,!0]),Ou.alphaBlended=new Ou([1,771],ga.transparent,[!0,!0,!0,!0]);const nu=1029,Zu=2305;class xu{constructor(_,k,X){this.enable=_,this.mode=k,this.frontFace=X}}xu.disabled=new xu(!1,nu,Zu),xu.backCCW=new xu(!0,nu,Zu),xu.backCW=new xu(!0,nu,2304),xu.frontCW=new xu(!0,1028,2304),xu.frontCCW=new xu(!0,1028,Zu);class Oc extends Wo{constructor(_,k,X){super(),this.id=_,this._onlySymbols=X,k.on("data",de=>{de.dataType==="source"&&de.sourceDataType==="metadata"&&(this._sourceLoaded=!0),this._sourceLoaded&&!this._paused&&de.dataType==="source"&&de.sourceDataType==="content"&&(this.reload(),this.transform&&this.update(this.transform))}),k.on("error",()=>{this._sourceErrored=!0}),this._source=k,this._tiles={},this._cache=new ou(0,this._unloadTile.bind(this)),this._timers={},this._cacheTimers={},this._minTileCacheSize=k.minTileCacheSize,this._maxTileCacheSize=k.maxTileCacheSize,this._loadedParentTiles={},this._coveredTiles={},this._state=new Cl,this._isRaster=this._source.type==="raster"||this._source.type==="raster-dem"||this._source.type==="custom"&&this._source._dataType==="raster"}onAdd(_){this.map=_,this._minTileCacheSize=this._minTileCacheSize===void 0&&_?_._minTileCacheSize:this._minTileCacheSize,this._maxTileCacheSize=this._maxTileCacheSize===void 0&&_?_._maxTileCacheSize:this._maxTileCacheSize}loaded(){if(this._sourceErrored)return!0;if(!this._sourceLoaded||!this._source.loaded())return!1;for(const _ in this._tiles){const k=this._tiles[_];if(k.state!=="loaded"&&k.state!=="errored")return!1}return!0}getSource(){return this._source}pause(){this._paused=!0}resume(){if(!this._paused)return;const _=this._shouldReloadOnResume;this._paused=!1,this._shouldReloadOnResume=!1,_&&this.reload(),this.transform&&this.update(this.transform)}_loadTile(_,k){return _.isSymbolTile=this._onlySymbols,this._source.loadTile(_,k)}_unloadTile(_){if(this._source.unloadTile)return this._source.unloadTile(_,()=>{})}_abortTile(_){if(this._source.abortTile)return this._source.abortTile(_,()=>{})}serialize(){return this._source.serialize()}prepare(_){if(this._source.prepare&&this._source.prepare(),this._state.coalesceChanges(this._tiles,this.map?this.map.painter:null),this._source.prepareTile)for(const k in this._tiles){const X=this._tiles[k];this._source.prepareTile(X)&&this.map.painter.terrain&&this.map.painter.terrain._clearRenderCacheForTile(this.id,X.tileID),X.upload(_),X.prepare(this.map.style.imageManager)}else for(const k in this._tiles){const X=this._tiles[k];X.upload(_),X.prepare(this.map.style.imageManager)}}getIds(){return pt(this._tiles).map(_=>_.tileID).sort(zu).map(_=>_.key)}getRenderableIds(_){const k=[];for(const X in this._tiles)this._isIdRenderable(+X,_)&&k.push(this._tiles[X]);return _?k.sort((X,de)=>{const Ge=X.tileID,ft=de.tileID,_t=new G(Ge.canonical.x,Ge.canonical.y)._rotate(this.transform.angle),At=new G(ft.canonical.x,ft.canonical.y)._rotate(this.transform.angle);return Ge.overscaledZ-ft.overscaledZ||At.y-_t.y||At.x-_t.x}).map(X=>X.tileID.key):k.map(X=>X.tileID).sort(zu).map(X=>X.key)}hasRenderableParent(_){const k=this.findLoadedParent(_,0);return!!k&&this._isIdRenderable(k.tileID.key)}_isIdRenderable(_,k){return this._tiles[_]&&this._tiles[_].hasData()&&!this._coveredTiles[_]&&(k||!this._tiles[_].holdingForFade())}reload(){if(this._paused)this._shouldReloadOnResume=!0;else{this._cache.reset();for(const _ in this._tiles)this._tiles[_].state!=="errored"&&this._reloadTile(+_,"reloading")}}_reloadTile(_,k){const X=this._tiles[_];X&&(X.state!=="loading"&&(X.state=k),this._loadTile(X,this._tileLoaded.bind(this,X,_,k)))}_tileLoaded(_,k,X,de){if(de)if(_.state="errored",de.status!==404)this._source.fire(new Lo(de,{tile:_}));else if(this._source.type==="raster-dem"&&this.usedForTerrain&&this.map.painter.terrain){const Ge=this.map.painter.terrain;this.update(this.transform,Ge.getScaledDemTileSize(),!0),Ge.resetTileLookupCache(this.id)}else this.update(this.transform);else _.timeAdded=xi.now(),X==="expired"&&(_.refreshedUponExpiration=!0),this._setTileReloadTimer(k,_),this._source.type==="raster-dem"&&_.dem&&this._backfillDEM(_),this._state.initializeTileState(_,this.map?this.map.painter:null),this._source.fire(new Po("data",{dataType:"source",tile:_,coord:_.tileID,sourceCacheId:this.id}))}_backfillDEM(_){const k=this.getRenderableIds();for(let de=0;de<k.length;de++){const Ge=k[de];if(_.neighboringTiles&&_.neighboringTiles[Ge]){const ft=this.getTileByID(Ge);X(_,ft),X(ft,_)}}function X(de,Ge){if(!de.dem||de.dem.borderReady)return;de.needsHillshadePrepare=!0,de.needsDEMTextureUpload=!0;let ft=Ge.tileID.canonical.x-de.tileID.canonical.x;const _t=Ge.tileID.canonical.y-de.tileID.canonical.y,At=Math.pow(2,de.tileID.canonical.z),Nt=Ge.tileID.key;ft===0&&_t===0||Math.abs(_t)>1||(Math.abs(ft)>1&&(Math.abs(ft+At)===1?ft+=At:Math.abs(ft-At)===1&&(ft-=At)),Ge.dem&&de.dem&&(de.dem.backfillBorder(Ge.dem,ft,_t),de.neighboringTiles&&de.neighboringTiles[Nt]&&(de.neighboringTiles[Nt].backfilled=!0)))}}getTile(_){return this.getTileByID(_.key)}getTileByID(_){return this._tiles[_]}_retainLoadedChildren(_,k,X,de){for(const Ge in this._tiles){let ft=this._tiles[Ge];if(de[Ge]||!ft.hasData()||ft.tileID.overscaledZ<=k||ft.tileID.overscaledZ>X)continue;let _t=ft.tileID;for(;ft&&ft.tileID.overscaledZ>k+1;){const Nt=ft.tileID.scaledTo(ft.tileID.overscaledZ-1);ft=this._tiles[Nt.key],ft&&ft.hasData()&&(_t=Nt)}let At=_t;for(;At.overscaledZ>k;)if(At=At.scaledTo(At.overscaledZ-1),_[At.key]){de[_t.key]=_t;break}}}findLoadedParent(_,k){if(_.key in this._loadedParentTiles){const X=this._loadedParentTiles[_.key];return X&&X.tileID.overscaledZ>=k?X:null}for(let X=_.overscaledZ-1;X>=k;X--){const de=_.scaledTo(X),Ge=this._getLoadedTile(de);if(Ge)return Ge}}_getLoadedTile(_){const k=this._tiles[_.key];return k&&k.hasData()?k:this._cache.getByKey(this._source.reparseOverscaled?_.wrapped().key:_.canonical.key)}updateCacheSize(_,k){k=k||this._source.tileSize;const X=Math.ceil(_.width/k)+1,de=Math.ceil(_.height/k)+1,Ge=Math.floor(X*de*5),ft=typeof this._minTileCacheSize=="number"?Math.max(this._minTileCacheSize,Ge):Ge,_t=typeof this._maxTileCacheSize=="number"?Math.min(this._maxTileCacheSize,ft):ft;this._cache.setMaxSize(_t)}handleWrapJump(_){const k=Math.round((_-(this._prevLng===void 0?_:this._prevLng))/360);if(this._prevLng=_,k){const X={};for(const de in this._tiles){const Ge=this._tiles[de];Ge.tileID=Ge.tileID.unwrapTo(Ge.tileID.wrap+k),X[Ge.tileID.key]=Ge}this._tiles=X;for(const de in this._timers)clearTimeout(this._timers[de]),delete this._timers[de];for(const de in this._tiles)this._setTileReloadTimer(+de,this._tiles[de])}}update(_,k,X){if(this.transform=_,!this._sourceLoaded||this._paused||this.transform.freezeTileCoverage||this.usedForTerrain&&!X)return;let de;this.updateCacheSize(_,k),this.transform.projection.name!=="globe"&&this.handleWrapJump(this.transform.center.lng),this._coveredTiles={},this.used||this.usedForTerrain?this._source.tileID?de=_.getVisibleUnwrappedCoordinates(this._source.tileID).map(_t=>new $a(_t.canonical.z,_t.wrap,_t.canonical.z,_t.canonical.x,_t.canonical.y)):(de=_.coveringTiles({tileSize:k||this._source.tileSize,minzoom:this._source.minzoom,maxzoom:this._source.maxzoom,roundZoom:this._source.roundZoom&&!X,reparseOverscaled:this._source.reparseOverscaled,isTerrainDEM:this.usedForTerrain}),this._source.hasTile&&(de=de.filter(_t=>this._source.hasTile(_t)))):de=[];const Ge=this._updateRetainedTiles(de);if(rd(this._source.type)&&de.length!==0){const _t={},At={},Nt=Object.keys(Ge);for(const vn of Nt){const bn=Ge[vn],jn=this._tiles[vn];if(!jn||jn.fadeEndTime&&jn.fadeEndTime<=xi.now())continue;const Zn=this.findLoadedParent(bn,Math.max(bn.overscaledZ-Oc.maxOverzooming,this._source.minzoom));Zn&&(this._addTile(Zn.tileID),_t[Zn.tileID.key]=Zn.tileID),At[vn]=bn}const cn=de[de.length-1].overscaledZ;for(const vn in this._tiles){const bn=this._tiles[vn];if(Ge[vn]||!bn.hasData())continue;let jn=bn.tileID;for(;jn.overscaledZ>cn;){jn=jn.scaledTo(jn.overscaledZ-1);const Zn=this._tiles[jn.key];if(Zn&&Zn.hasData()&&At[jn.key]){Ge[vn]=bn.tileID;break}}}for(const vn in _t)Ge[vn]||(this._coveredTiles[vn]=!0,Ge[vn]=_t[vn])}for(const _t in Ge)this._tiles[_t].clearFadeHold();const ft=function(_t,At){const Nt=[];for(const cn in _t)cn in At||Nt.push(cn);return Nt}(this._tiles,Ge);for(const _t of ft){const At=this._tiles[_t];At.hasSymbolBuckets&&!At.holdingForFade()?At.setHoldDuration(this.map._fadeDuration):At.hasSymbolBuckets&&!At.symbolFadeFinished()||this._removeTile(+_t)}this._updateLoadedParentTileCache(),this._onlySymbols&&this._source.afterUpdate&&this._source.afterUpdate()}releaseSymbolFadeTiles(){for(const _ in this._tiles)this._tiles[_].holdingForFade()&&this._removeTile(+_)}_updateRetainedTiles(_){const k={};if(_.length===0)return k;const X={},de=_.reduce((Nt,cn)=>Math.min(Nt,cn.overscaledZ),1/0),Ge=_[0].overscaledZ,ft=Math.max(Ge-Oc.maxOverzooming,this._source.minzoom),_t=Math.max(Ge+Oc.maxUnderzooming,this._source.minzoom),At={};for(const Nt of _){const cn=this._addTile(Nt);k[Nt.key]=Nt,cn.hasData()||de<this._source.maxzoom&&(At[Nt.key]=Nt)}this._retainLoadedChildren(At,de,_t,k);for(const Nt of _){let cn=this._tiles[Nt.key];if(cn.hasData())continue;if(Nt.canonical.z>=this._source.maxzoom){const bn=Nt.children(this._source.maxzoom)[0],jn=this.getTile(bn);if(jn&&jn.hasData()){k[bn.key]=bn;continue}}else{const bn=Nt.children(this._source.maxzoom);if(k[bn[0].key]&&k[bn[1].key]&&k[bn[2].key]&&k[bn[3].key])continue}let vn=cn.wasRequested();for(let bn=Nt.overscaledZ-1;bn>=ft;--bn){const jn=Nt.scaledTo(bn);if(X[jn.key]||(X[jn.key]=!0,cn=this.getTile(jn),!cn&&vn&&(cn=this._addTile(jn)),cn&&(k[jn.key]=jn,vn=cn.wasRequested(),cn.hasData())))break}}return k}_updateLoadedParentTileCache(){this._loadedParentTiles={};for(const _ in this._tiles){const k=[];let X,de=this._tiles[_].tileID;for(;de.overscaledZ>0;){if(de.key in this._loadedParentTiles){X=this._loadedParentTiles[de.key];break}k.push(de.key);const Ge=de.scaledTo(de.overscaledZ-1);if(X=this._getLoadedTile(Ge),X)break;de=Ge}for(const Ge of k)this._loadedParentTiles[Ge]=X}}_addTile(_){let k=this._tiles[_.key];if(k)return this._source.prepareTile&&this._source.prepareTile(k),k;k=this._cache.getAndRemove(_),k&&(this._setTileReloadTimer(_.key,k),k.tileID=_,this._state.initializeTileState(k,this.map?this.map.painter:null),this._cacheTimers[_.key]&&(clearTimeout(this._cacheTimers[_.key]),delete this._cacheTimers[_.key],this._setTileReloadTimer(_.key,k)));const X=!!k;if(!X){const de=this.map?this.map.painter:null;k=new Co(_,this._source.tileSize*_.overscaleFactor(),this.transform.tileZoom,de,this._isRaster),this._source.prepareTile&&this._source.prepareTile(k)||this._loadTile(k,this._tileLoaded.bind(this,k,_.key,k.state))}return k?(k.uses++,this._tiles[_.key]=k,X||this._source.fire(new Po("dataloading",{tile:k,coord:k.tileID,dataType:"source"})),k):null}_setTileReloadTimer(_,k){_ in this._timers&&(clearTimeout(this._timers[_]),delete this._timers[_]);const X=k.getExpiryTimeout();X&&(this._timers[_]=setTimeout(()=>{this._reloadTile(_,"expired"),delete this._timers[_]},X))}_removeTile(_){const k=this._tiles[_];k&&(k.uses--,delete this._tiles[_],this._timers[_]&&(clearTimeout(this._timers[_]),delete this._timers[_]),k.uses>0||(k.hasData()&&k.state!=="reloading"?this._cache.add(k.tileID,k,k.getExpiryTimeout()):(k.aborted=!0,this._abortTile(k),this._unloadTile(k))))}clearTiles(){this._shouldReloadOnResume=!1,this._paused=!1;for(const _ in this._tiles)this._removeTile(+_);this._source._clear&&this._source._clear(),this._cache.reset(),this.map&&this.usedForTerrain&&this.map.painter.terrain&&this.map.painter.terrain.resetTileLookupCache(this.id)}tilesIn(_,k,X){const de=[],Ge=this.transform;if(!Ge)return de;for(const ft in this._tiles){const _t=this._tiles[ft];if(X&&_t.clearQueryDebugViz(),_t.holdingForFade())continue;const At=_.containsTile(_t,Ge,k);At&&de.push(At)}return de}getVisibleCoordinates(_){const k=this.getRenderableIds(_).map(X=>this._tiles[X].tileID);for(const X of k)X.projMatrix=this.transform.calculateProjMatrix(X.toUnwrapped());return k}hasTransition(){if(this._source.hasTransition())return!0;if(rd(this._source.type))for(const _ in this._tiles){const k=this._tiles[_];if(k.fadeEndTime!==void 0&&k.fadeEndTime>=xi.now())return!0}return!1}setFeatureState(_,k,X){this._state.updateState(_=_||"_geojsonTileLayer",k,X)}removeFeatureState(_,k,X){this._state.removeFeatureState(_=_||"_geojsonTileLayer",k,X)}getFeatureState(_,k){return this._state.getState(_=_||"_geojsonTileLayer",k)}setDependencies(_,k,X){const de=this._tiles[_];de&&de.setDependencies(k,X)}reloadTilesForDependencies(_,k){for(const X in this._tiles)this._tiles[X].hasDependency(_,k)&&this._reloadTile(+X,"reloading");this._cache.filter(X=>!X.hasDependency(_,k))}_preloadTiles(_,k){const X=new Map,de=Array.isArray(_)?_:[_],Ge=this.map.painter.terrain,ft=this.usedForTerrain&&Ge?Ge.getScaledDemTileSize():this._source.tileSize;for(const _t of de){const At=_t.coveringTiles({tileSize:ft,minzoom:this._source.minzoom,maxzoom:this._source.maxzoom,roundZoom:this._source.roundZoom&&!this.usedForTerrain,reparseOverscaled:this._source.reparseOverscaled,isTerrainDEM:this.usedForTerrain});for(const Nt of At)X.set(Nt.key,Nt);this.usedForTerrain&&_t.updateElevation(!1)}ue(Array.from(X.values()),(_t,At)=>{const Nt=new Co(_t,this._source.tileSize*_t.overscaleFactor(),this.transform.tileZoom,this.map.painter,this._isRaster);this._loadTile(Nt,cn=>{this._source.type==="raster-dem"&&Nt.dem&&this._backfillDEM(Nt),At(cn,Nt)})},k)}}function zu(D,_){const k=Math.abs(2*D.wrap)-+(D.wrap<0),X=Math.abs(2*_.wrap)-+(_.wrap<0);return D.overscaledZ-_.overscaledZ||X-k||_.canonical.y-D.canonical.y||_.canonical.x-D.canonical.x}function rd(D){return D==="raster"||D==="image"||D==="video"}Oc.maxOverzooming=10,Oc.maxUnderzooming=3;class zd{constructor(_,k,X){this._demTile=_,this._dem=this._demTile.dem,this._scale=k,this._offset=X}static create(_,k,X){const de=X||_.findDEMTileFor(k);if(!de||!de.dem)return;const Ge=de.dem,ft=de.tileID,_t=1<<k.canonical.z-ft.canonical.z;return new zd(de,de.tileSize/Ml/_t,[(k.canonical.x/_t-ft.canonical.x)*Ge.dim,(k.canonical.y/_t-ft.canonical.y)*Ge.dim])}tileCoordToPixel(_,k){const X=k*this._scale+this._offset[1],de=Math.floor(_*this._scale+this._offset[0]),Ge=Math.floor(X);return new G(de,Ge)}getElevationAt(_,k,X,de){const Ge=_*this._scale+this._offset[0],ft=k*this._scale+this._offset[1],_t=Math.floor(Ge),At=Math.floor(ft),Nt=this._dem;return de=!!de,X?Qe(Qe(Nt.get(_t,At,de),Nt.get(_t,At+1,de),ft-At),Qe(Nt.get(_t+1,At,de),Nt.get(_t+1,At+1,de),ft-At),Ge-_t):Nt.get(_t,At,de)}getElevationAtPixel(_,k,X){return this._dem.get(_,k,!!X)}getMeterToDEM(_){return(1<<this._demTile.tileID.canonical.z)*Hp(1,_)*this._dem.stride}}class ph{constructor(_,k){this.tileID=_,this.x=_.canonical.x,this.y=_.canonical.y,this.z=_.canonical.z,this.grid=new vc(Ml,16,0),this.featureIndexArray=new Yu,this.promoteId=k}insert(_,k,X,de,Ge,ft=0){const _t=this.featureIndexArray.length;this.featureIndexArray.emplaceBack(X,de,Ge,ft);const At=this.grid;for(let Nt=0;Nt<k.length;Nt++){const cn=k[Nt],vn=[1/0,1/0,-1/0,-1/0];for(let bn=0;bn<cn.length;bn++){const jn=cn[bn];vn[0]=Math.min(vn[0],jn.x),vn[1]=Math.min(vn[1],jn.y),vn[2]=Math.max(vn[2],jn.x),vn[3]=Math.max(vn[3],jn.y)}vn[0]<Ml&&vn[1]<Ml&&vn[2]>=0&&vn[3]>=0&&At.insert(_t,vn[0],vn[1],vn[2],vn[3])}}loadVTLayers(){if(!this.vtLayers){this.vtLayers=new Vd.VectorTile(new m3(this.rawTileData)).layers,this.sourceLayerCoder=new Qa(this.vtLayers?Object.keys(this.vtLayers).sort():["_geojsonTileLayer"]),this.vtFeatures={};for(const _ in this.vtLayers)this.vtFeatures[_]=[]}return this.vtLayers}query(_,k,X,de){this.loadVTLayers();const Ge=_.params||{},ft=Gl(Ge.filter),_t=_.tileResult,At=_.transform,Nt=_t.bufferedTilespaceBounds,cn=this.grid.query(Nt.min.x,Nt.min.y,Nt.max.x,Nt.max.y,(Zn,Br,Jr,si)=>am(_t.bufferedTilespaceGeometry,Zn,Br,Jr,si));cn.sort(wf);let vn=null;At.elevation&&cn.length>0&&(vn=zd.create(At.elevation,this.tileID));const bn={};let jn;for(let Zn=0;Zn<cn.length;Zn++){const Br=cn[Zn];if(Br===jn)continue;jn=Br;const Jr=this.featureIndexArray.get(Br);let si=null;this.loadMatchingFeature(bn,Jr,ft,Ge.layers,Ge.availableImages,k,X,de,(Li,vi,ui,ua=0)=>(si||(si=bh(Li,this.tileID.canonical,_.tileTransform)),vi.queryIntersectsFeature(_t,Li,ui,si,this.z,_.transform,_.pixelPosMatrix,vn,ua)))}return bn}loadMatchingFeature(_,k,X,de,Ge,ft,_t,At,Nt){const{featureIndex:cn,bucketIndex:vn,sourceLayerIndex:bn,layoutVertexArrayOffset:jn}=k,Zn=this.bucketLayerIDs[vn];if(de&&!function(Li,vi){for(let ui=0;ui<Li.length;ui++)if(vi.indexOf(Li[ui])>=0)return!0;return!1}(de,Zn))return;const Br=this.sourceLayerCoder.decode(bn),Jr=this.vtLayers[Br].feature(cn);if(X.needGeometry){const Li=vp(Jr,!0);if(!X.filter(new Iu(this.tileID.overscaledZ),Li,this.tileID.canonical))return}else if(!X.filter(new Iu(this.tileID.overscaledZ),Jr))return;const si=this.getId(Jr,Br);for(let Li=0;Li<Zn.length;Li++){const vi=Zn[Li];if(de&&de.indexOf(vi)<0)continue;const ui=ft[vi];if(!ui)continue;let ua={};si!==void 0&&At&&(ua=At.getState(ui.sourceLayer||"_geojsonTileLayer",si));const ba=mt({},_t[vi]);ba.paint=Ap(ba.paint,ui.paint,Jr,ua,Ge),ba.layout=Ap(ba.layout,ui.layout,Jr,ua,Ge);const Ua=!Nt||Nt(Jr,ui,ua,jn);if(!Ua)continue;const Ga=new fs(Jr,this.z,this.x,this.y,si);Ga.layer=ba;let ho=_[vi];ho===void 0&&(ho=_[vi]=[]),ho.push({featureIndex:cn,feature:Ga,intersectionZ:Ua})}}lookupSymbolFeatures(_,k,X,de,Ge,ft,_t,At){const Nt={};this.loadVTLayers();const cn=Gl(Ge);for(const vn of _)this.loadMatchingFeature(Nt,{bucketIndex:X,sourceLayerIndex:de,featureIndex:vn,layoutVertexArrayOffset:0},cn,ft,_t,At,k);return Nt}loadFeature(_){const{featureIndex:k,sourceLayerIndex:X}=_;this.loadVTLayers();const de=this.sourceLayerCoder.decode(X),Ge=this.vtFeatures[de];if(Ge[k])return Ge[k];const ft=this.vtLayers[de].feature(k);return Ge[k]=ft,ft}hasLayer(_){for(const k of this.bucketLayerIDs)for(const X of k)if(_===X)return!0;return!1}getId(_,k){let X=_.id;return this.promoteId&&(X=_.properties[typeof this.promoteId=="string"?this.promoteId:this.promoteId[k]],typeof X=="boolean"&&(X=Number(X))),X}}function Ap(D,_,k,X,de){return Dn(D,(Ge,ft)=>{const _t=_ instanceof Dt?_.get(ft):null;return _t&&_t.evaluate?_t.evaluate(k,X,de):_t})}function wf(D,_){return _-D}Zo(ph,"FeatureIndex",{omit:["rawTileData","sourceLayerCoder"]});class o3{constructor(_){const k={},X=[];for(const _t in _){const At=_[_t],Nt=k[_t]={};for(const cn in At.glyphs){const vn=At.glyphs[+cn];if(!vn||vn.bitmap.width===0||vn.bitmap.height===0)continue;const bn=vn.metrics.localGlyph?2:1,jn={x:0,y:0,w:vn.bitmap.width+2*bn,h:vn.bitmap.height+2*bn};X.push(jn),Nt[cn]=jn}}const{w:de,h:Ge}=gg(X),ft=new Th({width:de||1,height:Ge||1});for(const _t in _){const At=_[_t];for(const Nt in At.glyphs){const cn=At.glyphs[+Nt];if(!cn||cn.bitmap.width===0||cn.bitmap.height===0)continue;const vn=k[_t][Nt],bn=cn.metrics.localGlyph?2:1;Th.copy(cn.bitmap,ft,{x:0,y:0},{x:vn.x+bn,y:vn.y+bn},cn.bitmap)}}this.image=ft,this.positions=k}}Zo(o3,"GlyphAtlas");class Jg{constructor(_){this.tileID=new $a(_.tileID.overscaledZ,_.tileID.wrap,_.tileID.canonical.z,_.tileID.canonical.x,_.tileID.canonical.y),this.tileZoom=_.tileZoom,this.uid=_.uid,this.zoom=_.zoom,this.canonical=_.tileID.canonical,this.pixelRatio=_.pixelRatio,this.tileSize=_.tileSize,this.source=_.source,this.overscaling=this.tileID.overscaleFactor(),this.showCollisionBoxes=_.showCollisionBoxes,this.collectResourceTiming=!!_.collectResourceTiming,this.returnDependencies=!!_.returnDependencies,this.promoteId=_.promoteId,this.enableTerrain=!!_.enableTerrain,this.isSymbolTile=_.isSymbolTile,this.tileTransform=ko(_.tileID.canonical,_.projection),this.projection=_.projection}parse(_,k,X,de,Ge){this.status="parsing",this.data=_,this.collisionBoxArray=new yh;const ft=new Qa(Object.keys(_.layers).sort()),_t=new ph(this.tileID,this.promoteId);_t.bucketLayerIDs=[];const At={},Nt=new Rg(256,256),cn={featureIndex:_t,iconDependencies:{},patternDependencies:{},glyphDependencies:{},lineAtlas:Nt,availableImages:X},vn=k.familiesBySource[this.source];for(const ua in vn){const ba=_.layers[ua];if(!ba)continue;let Ua=!1,Ga=!1;for(const Va of vn[ua])Va[0].type==="symbol"?Ua=!0:Ga=!0;if(this.isSymbolTile===!0&&!Ua||this.isSymbolTile===!1&&!Ga)continue;ba.version===1&&wn(`Vector tile source "${this.source}" layer "${ua}" does not use vector tile spec v2 and therefore may have some rendering errors.`);const ho=ft.encode(ua),bo=[];for(let Va=0;Va<ba.length;Va++){const Ka=ba.feature(Va),Do=_t.getId(Ka,ua);bo.push({feature:Ka,id:Do,index:Va,sourceLayerIndex:ho})}for(const Va of vn[ua]){const Ka=Va[0];this.isSymbolTile!==void 0&&Ka.type==="symbol"!==this.isSymbolTile||Ka.minzoom&&this.zoom<Math.floor(Ka.minzoom)||Ka.maxzoom&&this.zoom>=Ka.maxzoom||Ka.visibility!=="none"&&(Dm(Va,this.zoom,X),(At[Ka.id]=Ka.createBucket({index:_t.bucketLayerIDs.length,layers:Va,zoom:this.zoom,canonical:this.canonical,pixelRatio:this.pixelRatio,overscaling:this.overscaling,collisionBoxArray:this.collisionBoxArray,sourceLayerIndex:ho,sourceID:this.source,enableTerrain:this.enableTerrain,projection:this.projection.name,availableImages:X})).populate(bo,cn,this.tileID.canonical,this.tileTransform),_t.bucketLayerIDs.push(Va.map(Do=>Do.id)))}}let bn,jn,Zn,Br;Nt.trim();const Jr={type:"maybePrepare",isSymbolTile:this.isSymbolTile,zoom:this.zoom},si=Dn(cn.glyphDependencies,ua=>Object.keys(ua).map(Number));Object.keys(si).length?de.send("getGlyphs",{uid:this.uid,stacks:si},(ua,ba)=>{bn||(bn=ua,jn=ba,ui.call(this))},void 0,!1,Jr):jn={};const Li=Object.keys(cn.iconDependencies);Li.length?de.send("getImages",{icons:Li,source:this.source,tileID:this.tileID,type:"icons"},(ua,ba)=>{bn||(bn=ua,Zn=ba,ui.call(this))},void 0,!1,Jr):Zn={};const vi=Object.keys(cn.patternDependencies);function ui(){if(bn)return Ge(bn);if(jn&&Zn&&Br){const ua=new o3(jn),ba=new vg(Zn,Br);for(const Ua in At){const Ga=At[Ua];Ga instanceof Hf?(Dm(Ga.layers,this.zoom,X),nh(Ga,jn,ua.positions,Zn,ba.iconPositions,this.showCollisionBoxes,X,this.tileID.canonical,this.tileZoom,this.projection)):Ga.hasPattern&&(Ga instanceof L3||Ga instanceof Tl||Ga instanceof op)&&(Dm(Ga.layers,this.zoom,X),Ga.addFeatures(cn,this.tileID.canonical,ba.patternPositions,X,this.tileTransform))}this.status="done",Ge(null,{buckets:pt(At).filter(Ua=>!Ua.isEmpty()),featureIndex:_t,collisionBoxArray:this.collisionBoxArray,glyphAtlasImage:ua.image,lineAtlas:Nt,imageAtlas:ba,glyphMap:this.returnDependencies?jn:null,iconMap:this.returnDependencies?Zn:null,glyphPositions:this.returnDependencies?ua.positions:null})}}vi.length?de.send("getImages",{icons:vi,source:this.source,tileID:this.tileID,type:"patterns"},(ua,ba)=>{bn||(bn=ua,Br=ba,ui.call(this))},void 0,!1,Jr):Br={},ui.call(this)}}function Dm(D,_,k){const X=new Iu(_);for(const de of D)de.recalculate(X,k)}class Em{constructor(_){this.entries={},this.scheduler=_}request(_,k,X,de){const Ge=this.entries[_]=this.entries[_]||{callbacks:[]};if(Ge.result){const[ft,_t]=Ge.result;return this.scheduler?this.scheduler.add(()=>{de(ft,_t)},k):de(ft,_t),()=>{}}return Ge.callbacks.push(de),Ge.cancel||(Ge.cancel=X((ft,_t)=>{Ge.result=[ft,_t];for(const At of Ge.callbacks)this.scheduler?this.scheduler.add(()=>{At(ft,_t)},k):At(ft,_t);setTimeout(()=>delete this.entries[_],3e3)})),()=>{Ge.result||(Ge.callbacks=Ge.callbacks.filter(ft=>ft!==de),Ge.callbacks.length||(Ge.cancel(),delete this.entries[_]))}}}function Am(D,_,k){const X=JSON.stringify(D.request);return D.data&&(this.deduped.entries[X]={result:[null,D.data]}),this.deduped.request(X,{type:"parseTile",isSymbolTile:D.isSymbolTile,zoom:D.tileZoom},de=>{const Ge=ni(D.request,(ft,_t,At,Nt)=>{ft?de(ft):_t&&de(null,{vectorTile:k?void 0:new Vd.VectorTile(new m3(_t)),rawData:_t,cacheControl:At,expires:Nt})});return()=>{Ge.cancel(),de()}},_)}const s3=ld(new Float32Array(16));class Uh{constructor(_){this.name=_.name,this.wrap=!1,this.requiresDraping=!1,this.supportsWorldCopies=!1,this.supportsTerrain=!1,this.supportsFog=!1,this.supportsFreeCamera=!1,this.zAxisUnit="meters",this.isReprojectedInTileSpace=!0,this.unsupportedLayers=["custom"],this.center=[0,0],this.range=[3.5,7]}project(_,k){return{x:0,y:0,z:0}}unproject(_,k){return new _u(0,0)}projectTilePoint(_,k,X){return{x:_,y:k,z:0}}locationPoint(_,k){return _._coordinatePoint(_.locationCoordinate(k),!1)}pixelsPerMeter(_,k){return Hp(1,_)*k}farthestPixelDistance(_){return function(k,X){const de=k.fovAboveCenter,Ge=k.elevation?k.elevation.getMinElevationBelowMSL()*X:0,ft=(k._camera.position[2]*k.worldSize-Ge)/Math.cos(k._pitch),_t=Math.sin(de)*ft/Math.sin(Math.max(Math.PI/2-k._pitch-de,.01)),At=Math.sin(k._pitch)*_t+ft;return Math.min(1.01*At,ft*(1/k._horizonShift))}(_,_.pixelsPerMeter)}pointCoordinate(_,k,X,de){const Ge=_.horizonLineFromTop(!1),ft=new G(k,Math.max(Ge,X));return _.rayIntersectionCoordinate(_.pointRayIntersection(ft,de))}createInversionMatrix(_,k){return s3}createTileMatrix(_,k,X){let de,Ge,ft;const _t=X.canonical,At=ld(new Float64Array(16));if(this.isReprojectedInTileSpace){const Nt=ko(_t,this);de=1,Ge=Nt.x+X.wrap*Nt.scale,ft=Nt.y,Cu(At,At,[de/Nt.scale,de/Nt.scale,_.pixelsPerMeter/k])}else de=k/_.zoomScale(_t.z),Ge=(_t.x+Math.pow(2,_t.z)*X.wrap)*de,ft=_t.y*de;return Ch(At,At,[Ge,ft,0]),Cu(At,At,[de/Ml,de/Ml,1]),At}upVector(_,k,X){return[0,0,1]}upVectorScale(_,k,X){return{metersToTile:1,metersToLabelSpace:1}}}class K3 extends Uh{constructor(_){super(_),this.wrap=!0,this.supportsWorldCopies=!0,this.supportsTerrain=!0,this.supportsFog=!0,this.supportsFreeCamera=!0,this.isReprojectedInTileSpace=!1,this.unsupportedLayers=[],this.range=null}project(_,k){return{x:ch(_),y:$p(k),z:0}}unproject(_,k){const X=Wd(_),de=ed(k);return new _u(X,de)}}class $h extends Uh{constructor(_){super(_),this.range=[4,7],this.center=_.center||[-96,37.5];const[k,X]=this.parallels=_.parallels||[29.5,45.5],de=Math.sin(ne(k));this.n=(de+Math.sin(ne(X)))/2,this.c=1+de*(2*this.n-de),this.r0=Math.sqrt(this.c)/this.n}project(_,k){const{n:X,c:de,r0:Ge}=this,ft=ne(_-this.center[0]),_t=ne(k),At=Math.sqrt(de-2*X*Math.sin(_t))/X;return{x:At*Math.sin(ft*X),y:At*Math.cos(ft*X)-Ge,z:0}}unproject(_,k){const{n:X,c:de,r0:Ge}=this,ft=Ge+k;let _t=Math.atan2(_,Math.abs(ft))*Math.sign(ft);ft*X<0&&(_t-=Math.PI*Math.sign(_)*Math.sign(ft));const At=ne(this.center[0])*X;_t=ie(_t,-Math.PI-At,Math.PI-At);const Nt=Ue(_t/X)+this.center[0],cn=Math.asin(Te((de-(_*_+ft*ft)*X*X)/(2*X),-1,1)),vn=Te(Ue(cn),-85.051129,Jd);return new _u(Nt,vn)}}const M3=1.340264,ci=-.081106,oa=893e-6,Yi=.003796,Da=Math.sqrt(3)/2;class Na extends Uh{project(_,k){k=k/180*Math.PI,_=_/180*Math.PI;const X=Math.asin(Da*Math.sin(k)),de=X*X,Ge=de*de*de;return{x:.5*(_*Math.cos(X)/(Da*(M3+3*ci*de+Ge*(7*oa+9*Yi*de)))/Math.PI+.5),y:1-.5*(X*(M3+ci*de+Ge*(oa+Yi*de))/Math.PI+1),z:0}}unproject(_,k){_=(2*_-.5)*Math.PI;let X=k=(2*(1-k)-1)*Math.PI,de=X*X,Ge=de*de*de;for(let cn,vn,bn,jn=0;jn<12&&(vn=X*(M3+ci*de+Ge*(oa+Yi*de))-k,bn=M3+3*ci*de+Ge*(7*oa+9*Yi*de),cn=vn/bn,X=Te(X-cn,-Math.PI/3,Math.PI/3),de=X*X,Ge=de*de*de,!(Math.abs(cn)<1e-12));++jn);const ft=Da*_*(M3+3*ci*de+Ge*(7*oa+9*Yi*de))/Math.cos(X),_t=Math.asin(Math.sin(X)/Da),At=Te(180*ft/Math.PI,-180,180),Nt=Te(180*_t/Math.PI,-85.051129,Jd);return new _u(At,Nt)}}class xs extends Uh{constructor(_){super(_),this.wrap=!0,this.supportsWorldCopies=!0}project(_,k){return{x:.5+_/360,y:.5-k/360,z:0}}unproject(_,k){const X=360*(_-.5),de=Te(360*(.5-k),-85.051129,Jd);return new _u(X,de)}}const ss=Math.PI/2;function Ko(D){return Math.tan((ss+D)/2)}class Cs extends Uh{constructor(_){super(_),this.center=_.center||[0,30];const[k,X]=this.parallels=_.parallels||[30,30],de=ne(k),Ge=ne(X),ft=Math.cos(de);this.n=de===Ge?Math.sin(de):Math.log(ft/Math.cos(Ge))/Math.log(Ko(Ge)/Ko(de)),this.f=ft*Math.pow(Ko(de),this.n)/this.n}project(_,k){k=ne(k),_=ne(_-this.center[0]);const X=1e-6,{n:de,f:Ge}=this;Ge>0?k<-ss+X&&(k=-ss+X):k>ss-X&&(k=ss-X);const ft=Ge/Math.pow(Ko(k),de),_t=ft*Math.sin(de*_),At=Ge-ft*Math.cos(de*_);return{x:.5*(_t/Math.PI+.5),y:1-.5*(At/Math.PI+.5),z:0}}unproject(_,k){_=(2*_-.5)*Math.PI,k=(2*(1-k)-.5)*Math.PI;const{n:X,f:de}=this,Ge=de-k,ft=Math.sign(Ge),_t=Math.sign(X)*Math.sqrt(_*_+Ge*Ge);let At=Math.atan2(_,Math.abs(Ge))*ft;Ge*X<0&&(At-=Math.PI*Math.sign(_)*ft);const Nt=Te(Ue(At/X)+this.center[0],-180,180),cn=Te(Ue(2*Math.atan(Math.pow(de/_t,1/X))-ss),-85.051129,Jd);return new _u(Nt,cn)}}const vo=ne(Jd);class Yo extends Uh{project(_,k){const X=(k=ne(k))*k,de=X*X;return{x:.5*((_=ne(_))*(.8707-.131979*X+de*(de*(.003971*X-.001529*de)-.013791))/Math.PI+.5),y:1-.5*(k*(1.007226+X*(.015085+de*(.028874*X-.044475-.005916*de)))/Math.PI+1),z:0}}unproject(_,k){_=(2*_-.5)*Math.PI;let X=k=(2*(1-k)-1)*Math.PI,de=25,Ge=0,ft=X*X;do{ft=X*X;const Nt=ft*ft;Ge=(X*(1.007226+ft*(.015085+Nt*(.028874*ft-.044475-.005916*Nt)))-k)/(1.007226+ft*(.045255+Nt*(.259866*ft-.311325-.005916*11*Nt))),X=Te(X-Ge,-vo,vo)}while(Math.abs(Ge)>1e-6&&--de>0);ft=X*X;const _t=Te(Ue(_/(.8707+ft*(ft*(ft*ft*ft*(.003971-.001529*ft)-.013791)-.131979))),-180,180),At=Ue(X);return new _u(_t,At)}}const rl=ne(Jd);class dl extends Uh{project(_,k){k=ne(k),_=ne(_);const X=Math.cos(k),de=2/Math.PI,Ge=Math.acos(X*Math.cos(_/2)),ft=Math.sin(Ge)/Ge,_t=.5*(_*de+2*X*Math.sin(_/2)/ft)||0,At=.5*(k+Math.sin(k)/ft)||0;return{x:.5*(_t/Math.PI+.5),y:1-.5*(At/Math.PI+1),z:0}}unproject(_,k){let X=_=(2*_-.5)*Math.PI,de=k=(2*(1-k)-1)*Math.PI,Ge=25;const ft=1e-6;let _t=0,At=0;do{const Nt=Math.cos(de),cn=Math.sin(de),vn=2*cn*Nt,bn=cn*cn,jn=Nt*Nt,Zn=Math.cos(X/2),Br=Math.sin(X/2),Jr=2*Zn*Br,si=Br*Br,Li=1-jn*Zn*Zn,vi=Li?1/Li:0,ui=Li?Math.acos(Nt*Zn)*Math.sqrt(1/Li):0,ua=.5*(2*ui*Nt*Br+2*X/Math.PI)-_,ba=.5*(ui*cn+de)-k,Ua=.5*vi*(jn*si+ui*Nt*Zn*bn)+1/Math.PI,Ga=vi*(Jr*vn/4-ui*cn*Br),ho=.125*vi*(vn*Br-ui*cn*jn*Jr),bo=.5*vi*(bn*Zn+ui*si*Nt)+.5,Va=Ga*ho-bo*Ua;_t=(ba*Ga-ua*bo)/Va,At=(ua*ho-ba*Ua)/Va,X=Te(X-_t,-Math.PI,Math.PI),de=Te(de-At,-rl,rl)}while((Math.abs(_t)>ft||Math.abs(At)>ft)&&--Ge>0);return new _u(Ue(X),Ue(de))}}class us extends Uh{constructor(_){super(_),this.center=_.center||[0,0],this.parallels=_.parallels||[0,0],this.cosPhi=Math.max(.01,Math.cos(ne(this.parallels[0]))),this.scale=1/(2*Math.max(Math.PI*this.cosPhi,1/this.cosPhi)),this.wrap=!0,this.supportsWorldCopies=!0}project(_,k){const{scale:X,cosPhi:de}=this;return{x:ne(_)*de*X+.5,y:-Math.sin(ne(k))/de*X+.5,z:0}}unproject(_,k){const{scale:X,cosPhi:de}=this,Ge=-(k-.5)/X,ft=Te(Ue((_-.5)/X)/de,-180,180),_t=Math.asin(Te(Ge*de,-1,1)),At=Te(Ue(_t),-85.051129,Jd);return new _u(ft,At)}}m.ARRAY_TYPE=hh,m.AUTH_ERR_MSG=sa,m.Aabb=qd,m.Actor=class{constructor(D,_,k){this.target=D,this.parent=_,this.mapId=k,this.callbacks={},this.cancelCallbacks={},pn(["receive"],this),this.target.addEventListener("message",this.receive,!1),this.globalScope=$n()?D:J,this.scheduler=new E0}send(D,_,k,X,de=!1,Ge){const ft=Math.round(1e18*Math.random()).toString(36).substring(0,10);k&&(k.metadata=Ge,this.callbacks[ft]=k);const _t=Yn(this.globalScope)?void 0:[];return this.target.postMessage({id:ft,type:D,hasCallback:!!k,targetMapId:X,mustQueue:de,sourceMapId:this.mapId,data:Fp(_,_t)},_t),{cancel:()=>{k&&delete this.callbacks[ft],this.target.postMessage({id:ft,type:"<cancel>",targetMapId:X,sourceMapId:this.mapId})}}}receive(D){const _=D.data,k=_.id;if(k&&(!_.targetMapId||this.mapId===_.targetMapId))if(_.type==="<cancel>"){const X=this.cancelCallbacks[k];delete this.cancelCallbacks[k],X&&X.cancel()}else if(_.mustQueue||$n()){const X=this.callbacks[k];this.cancelCallbacks[k]=this.scheduler.add(()=>this.processTask(k,_),X&&X.metadata||{type:"message"})}else this.processTask(k,_)}processTask(D,_){if(_.type==="<response>"){const k=this.callbacks[D];delete this.callbacks[D],k&&(_.error?k(kh(_.error)):k(null,kh(_.data)))}else{const k=Yn(this.globalScope)?void 0:[],X=_.hasCallback?(Ge,ft)=>{delete this.cancelCallbacks[D],this.target.postMessage({id:D,type:"<response>",sourceMapId:this.mapId,error:Ge?Fp(Ge):null,data:Fp(ft,k)},k)}:Ge=>{},de=kh(_.data);if(this.parent[_.type])this.parent[_.type](_.sourceMapId,de,X);else if(this.parent.getWorkerSource){const Ge=_.type.split(".");this.parent.getWorkerSource(_.sourceMapId,Ge[0],de.source)[Ge[1]](de,X)}else X(new Error(`Could not find function ${_.type}`))}}remove(){this.scheduler.remove(),this.target.removeEventListener("message",this.receive,!1)}},m.CanonicalTileID=Ya,m.Color=ga,m.ColorMode=Ou,m.CullFaceMode=xu,m.DEMData=Rl,m.DataConstantProperty=Ot,m.DedupedRequest=Em,m.DepthMode=Hu,m.EXTENT=Ml,m.Elevation=class{isDataAvailableAtPoint(D){const _=this._source();if(!_||D.y<0||D.y>1)return!1;const k=_.getSource().maxzoom,X=1<<k,de=Math.floor(D.x),Ge=Math.floor((D.x-de)*X),ft=Math.floor(D.y*X),_t=this.findDEMTileFor(new $a(k,de,k,Ge,ft));return!(!_t||!_t.dem)}getAtPointOrZero(D,_=0){return this.getAtPoint(D,_)||0}getAtPoint(D,_,k=!0){_==null&&(_=null);const X=this._source();if(!X||D.y<0||D.y>1)return _;const de=X.getSource().maxzoom,Ge=1<<de,ft=Math.floor(D.x),_t=D.x-ft,At=new $a(de,ft,de,Math.floor(_t*Ge),Math.floor(D.y*Ge)),Nt=this.findDEMTileFor(At);if(!Nt||!Nt.dem)return _;const cn=Nt.dem,vn=1<<Nt.tileID.canonical.z,bn=(_t*vn-Nt.tileID.canonical.x)*cn.dim,jn=(D.y*vn-Nt.tileID.canonical.y)*cn.dim,Zn=Math.floor(bn),Br=Math.floor(jn);return(k?this.exaggeration():1)*Qe(Qe(cn.get(Zn,Br),cn.get(Zn,Br+1),jn-Br),Qe(cn.get(Zn+1,Br),cn.get(Zn+1,Br+1),jn-Br),bn-Zn)}getAtTileOffset(D,_,k){const X=1<<D.canonical.z;return this.getAtPointOrZero(new Wp(D.wrap+(D.canonical.x+_/Ml)/X,(D.canonical.y+k/Ml)/X))}getAtTileOffsetFunc(D,_,k,X){return de=>{const Ge=this.getAtTileOffset(D,de.x,de.y),ft=X.upVector(D.canonical,de.x,de.y);return Hm(ft,ft,Ge*X.upVectorScale(D.canonical,_,k).metersToTile),ft}}getForTilePoints(D,_,k,X){const de=zd.create(this,D,X);return!!de&&(_.forEach(Ge=>{Ge[2]=this.exaggeration()*de.getElevationAt(Ge[0],Ge[1],k)}),!0)}getMinMaxForTile(D){const _=this.findDEMTileFor(D);if(!_||!_.dem)return null;const k=_.dem.tree,X=_.tileID,de=1<<D.canonical.z-X.canonical.z;let Ge=D.canonical.x/de-X.canonical.x,ft=D.canonical.y/de-X.canonical.y,_t=0;for(let At=0;At<D.canonical.z-X.canonical.z&&!k.leaves[_t];At++){Ge*=2,ft*=2;const Nt=2*Math.floor(ft)+Math.floor(Ge);_t=k.childOffsets[_t]+Nt,Ge%=1,ft%=1}return{min:this.exaggeration()*k.minimums[_t],max:this.exaggeration()*k.maximums[_t]}}getMinElevationBelowMSL(){throw new Error("Pure virtual method called.")}raycast(D,_,k){throw new Error("Pure virtual method called.")}pointCoordinate(D){throw new Error("Pure virtual method called.")}_source(){throw new Error("Pure virtual method called.")}exaggeration(){throw new Error("Pure virtual method called.")}findDEMTileFor(D){throw new Error("Pure virtual method called.")}get visibleDemTiles(){throw new Error("Getter must be implemented in subclass.")}},m.ErrorEvent=Lo,m.EvaluationParameters=Iu,m.Event=Po,m.Evented=Wo,m.FillExtrusionBucket=op,m.Frustum=Cp,m.GLOBE_RADIUS=gt,m.GlobeSharedBuffers=class{constructor(D){this._createGrid(D),this._createPoles(D),this._createAtmosphere(D)}destroy(){this._poleIndexBuffer.destroy(),this._gridBuffer.destroy(),this._gridIndexBuffer.destroy(),this._poleNorthVertexBuffer.destroy(),this._poleSouthVertexBuffer.destroy();for(const D of this._poleSegments)D.destroy();this._gridSegments.destroy(),this.atmosphereVertexBuffer.destroy(),this.atmosphereIndexBuffer.destroy(),this.atmosphereSegments.destroy(),this._wireframeIndexBuffer&&(this._wireframeIndexBuffer.destroy(),this._wireframeSegments.destroy())}_createGrid(D){const _=new wi,k=new rs,X=65;for(let de=0;de<X;de++)for(let Ge=0;Ge<X;Ge++)_.emplaceBack(Ge,de);for(let de=0;de<64;de++)for(let Ge=0;Ge<64;Ge++){const ft=de*X+Ge;k.emplaceBack(ft+1,ft,ft+X),k.emplaceBack(ft+X,ft+X+1,ft+1)}this._gridBuffer=D.createVertexBuffer(_,ct.members),this._gridIndexBuffer=D.createIndexBuffer(k,!0),this._gridSegments=hc.simpleSegment(0,0,4225,8192)}_createPoles(D){const _=new rs;for(let de=0;de<=64;de++)_.emplaceBack(0,de+1,de+2);this._poleIndexBuffer=D.createIndexBuffer(_,!0);const k=new Js,X=new Js;this._poleSegments=[];for(let de=0,Ge=0;de<5;de++){const ft=1<<de,_t=512*ft/Math.PI/2,At=360/ft;k.emplaceBack(0,-_t,0,0,0,.5,0),X.emplaceBack(0,-_t,0,0,0,.5,1);for(let Nt=0;Nt<=64;Nt++){const cn=Nt/64,vn=Qe(0,At,cn),[bn,jn,Zn]=Hn(Sa,ea,vn,_t);k.emplaceBack(bn,jn,Zn,0,0,cn,0),X.emplaceBack(bn,jn,Zn,0,0,cn,1)}this._poleSegments.push(hc.simpleSegment(Ge,0,66,64)),Ge+=66}this._poleNorthVertexBuffer=D.createVertexBuffer(k,W,!1),this._poleSouthVertexBuffer=D.createVertexBuffer(X,W,!1)}_createAtmosphere(D){const _=new fl;_.emplaceBack(-1,1,1,0,0),_.emplaceBack(1,1,1,1,0),_.emplaceBack(1,-1,1,1,1),_.emplaceBack(-1,-1,1,0,1);const k=new rs;k.emplaceBack(0,1,2),k.emplaceBack(2,3,0),this.atmosphereVertexBuffer=D.createVertexBuffer(_,E.members),this.atmosphereIndexBuffer=D.createIndexBuffer(k),this.atmosphereSegments=hc.simpleSegment(0,0,4,2)}getGridBuffers(){return[this._gridBuffer,this._gridIndexBuffer,this._gridSegments]}getPoleBuffers(D){return[this._poleNorthVertexBuffer,this._poleSouthVertexBuffer,this._poleIndexBuffer,this._poleSegments[D]]}getWirefameBuffers(D){if(!this._wireframeSegments){const _=new ll,k=64,X=k+1;for(let de=0;de<k;de++)for(let Ge=0;Ge<k;Ge++){const ft=de*X+Ge;_.emplaceBack(ft,ft+1),_.emplaceBack(ft,ft+X),_.emplaceBack(ft,ft+X+1)}this._wireframeIndexBuffer=D.createIndexBuffer(_),this._wireframeSegments=hc.simpleSegment(0,0,k*k,_.length)}return[this._gridBuffer,this._wireframeIndexBuffer,this._wireframeSegments]}},m.GlyphManager=Uf,m.ImagePosition=yg,m.LineAtlas=Rg,m.LngLat=_u,m.LngLatBounds=Hc,m.LocalGlyphMode=nd,m.MAX_MERCATOR_LATITUDE=Jd,m.MercatorCoordinate=Wp,m.ONE_EM=Ad,m.OverscaledTileID=$a,m.Properties=Wn,m.RGBAImage=Cd,m.Ray=class{constructor(D,_){this.pos=D,this.dir=_}intersectsPlane(D,_,k){const X=Zc(_,this.dir);if(Math.abs(X)<1e-6)return!1;const de=((D[0]-this.pos[0])*_[0]+(D[1]-this.pos[1])*_[1]+(D[2]-this.pos[2])*_[2])/X;return k[0]=this.pos[0]+this.dir[0]*de,k[1]=this.pos[1]+this.dir[1]*de,k[2]=this.pos[2]+this.dir[2]*de,!0}closestPointOnSphere(D,_,k){if(function(bn,jn){var Zn=bn[0],Br=bn[1],Jr=bn[2],si=jn[0],Li=jn[1],vi=jn[2];return Math.abs(Zn-si)<=A3*Math.max(1,Math.abs(Zn),Math.abs(si))&&Math.abs(Br-Li)<=A3*Math.max(1,Math.abs(Br),Math.abs(Li))&&Math.abs(Jr-vi)<=A3*Math.max(1,Math.abs(Jr),Math.abs(vi))}(this.pos,D)||_===0)return k[0]=k[1]=k[2]=0,!1;const[X,de,Ge]=this.dir,ft=this.pos[0]-D[0],_t=this.pos[1]-D[1],At=this.pos[2]-D[2],Nt=X*X+de*de+Ge*Ge,cn=2*(ft*X+_t*de+At*Ge),vn=cn*cn-4*Nt*(ft*ft+_t*_t+At*At-_*_);if(vn<0){const bn=Math.max(-cn/2,0),jn=ft+X*bn,Zn=_t+de*bn,Br=At+Ge*bn,Jr=Math.hypot(jn,Zn,Br);return k[0]=jn*_/Jr,k[1]=Zn*_/Jr,k[2]=Br*_/Jr,!1}{const bn=(-cn-Math.sqrt(vn))/(2*Nt);if(bn<0){const jn=Math.hypot(ft,_t,At);return k[0]=ft*_/jn,k[1]=_t*_/jn,k[2]=At*_/jn,!1}return k[0]=ft+X*bn,k[1]=_t+de*bn,k[2]=At+Ge*bn,!0}}},m.RequestManager=class{constructor(D,_,k){this._transformRequestFn=D,this._customAccessToken=_,this._silenceAuthErrors=!!k,this._createSkuToken()}_createSkuToken(){const D=function(){let _="";for(let k=0;k<10;k++)_+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[Math.floor(62*Math.random())];return{token:["1",An,_].join(""),tokenExpiresAt:Date.now()+432e5}}();this._skuToken=D.token,this._skuTokenExpiresAt=D.tokenExpiresAt}_isSkuTokenExpired(){return Date.now()>this._skuTokenExpiresAt}transformRequest(D,_){return this._transformRequestFn&&this._transformRequestFn(D,_)||{url:D}}normalizeStyleURL(D,_){if(!Nn(D))return D;const k=Ln(D);return k.path=`/styles/v1${k.path}`,this._makeAPIURL(k,this._customAccessToken||_)}normalizeGlyphsURL(D,_){if(!Nn(D))return D;const k=Ln(D);return k.path=`/fonts/v1${k.path}`,this._makeAPIURL(k,this._customAccessToken||_)}normalizeSourceURL(D,_){if(!Nn(D))return D;const k=Ln(D);return k.path=`/v4/${k.authority}.json`,k.params.push("secure"),this._makeAPIURL(k,this._customAccessToken||_)}normalizeSpriteURL(D,_,k,X){const de=Ln(D);return Nn(D)?(de.path=`/styles/v1${de.path}/sprite${_}${k}`,this._makeAPIURL(de,this._customAccessToken||X)):(de.path+=`${_}${k}`,hr(de))}normalizeTileURL(D,_,k){if(this._isSkuTokenExpired()&&this._createSkuToken(),D&&!Nn(D))return D;const X=Ln(D);X.path=X.path.replace(/(\.(png|jpg)\d*)(?=$)/,`${_||k&&X.authority!=="raster"&&k===512?"@2x":""}${ia.supported?".webp":"$1"}`),X.authority==="raster"?X.path=`/${qn.RASTER_URL_PREFIX}${X.path}`:(X.path=X.path.replace(/^.+\/v4\//,"/"),X.path=`/${qn.TILE_URL_VERSION}${X.path}`);const de=this._customAccessToken||function(Ge){for(const ft of Ge){const _t=ft.match(/^access_token=(.*)$/);if(_t)return _t[1]}return null}(X.params)||qn.ACCESS_TOKEN;return qn.REQUIRE_ACCESS_TOKEN&&de&&this._skuToken&&X.params.push(`sku=${this._skuToken}`),this._makeAPIURL(X,de)}canonicalizeTileURL(D,_){const k=Ln(D);if(!k.path.match(/^(\/v4\/|\/raster\/v1\/)/)||!k.path.match(/\.[\w]+$/))return D;let X="mapbox://";k.path.match(/^\/raster\/v1\//)?X+=`raster/${k.path.replace(`/${qn.RASTER_URL_PREFIX}/`,"")}`:X+=`tiles/${k.path.replace(`/${qn.TILE_URL_VERSION}/`,"")}`;let de=k.params;return _&&(de=de.filter(Ge=>!Ge.match(/^access_token=/))),de.length&&(X+=`?${de.join("&")}`),X}canonicalizeTileset(D,_){const k=!!_&&Nn(_),X=[];for(const de of D.tiles||[])fn(de)?X.push(this.canonicalizeTileURL(de,k)):X.push(de);return X}_makeAPIURL(D,_){const k="See https://www.mapbox.com/api-documentation/#access-tokens-and-token-scopes",X=Ln(qn.API_URL);if(D.protocol=X.protocol,D.authority=X.authority,D.protocol==="http"){const de=D.params.indexOf("secure");de>=0&&D.params.splice(de,1)}if(X.path!=="/"&&(D.path=`${X.path}${D.path}`),!qn.REQUIRE_ACCESS_TOKEN)return hr(D);if(_=_||qn.ACCESS_TOKEN,!this._silenceAuthErrors){if(!_)throw new Error(`An API access token is required to use Mapbox GL. ${k}`);if(_[0]==="s")throw new Error(`Use a public access token (pk.*) with Mapbox GL, not a secret access token (sk.*). ${k}`)}return D.params=D.params.filter(de=>de.indexOf("access_token")===-1),D.params.push(`access_token=${_||""}`),hr(D)}},m.ResourceType=zr,m.SegmentVector=hc,m.SourceCache=Oc,m.StencilMode=uu,m.StructArrayLayout1ui2=Yl,m.StructArrayLayout2f1f2i16=Qo,m.StructArrayLayout2i4=wi,m.StructArrayLayout2ui4=ll,m.StructArrayLayout3f12=To,m.StructArrayLayout3ui6=rs,m.StructArrayLayout4i8=Oi,m.Texture=w3,m.Tile=Co,m.Transitionable=Ee,m.Uniform1f=uf,m.Uniform1i=class extends vh{constructor(D,_){super(D,_),this.current=0}set(D){this.current!==D&&(this.current=D,this.gl.uniform1i(this.location,D))}},m.Uniform2f=class extends vh{constructor(D,_){super(D,_),this.current=[0,0]}set(D){D[0]===this.current[0]&&D[1]===this.current[1]||(this.current=D,this.gl.uniform2f(this.location,D[0],D[1]))}},m.Uniform3f=class extends vh{constructor(D,_){super(D,_),this.current=[0,0,0]}set(D){D[0]===this.current[0]&&D[1]===this.current[1]&&D[2]===this.current[2]||(this.current=D,this.gl.uniform3f(this.location,D[0],D[1],D[2]))}},m.Uniform4f=T3,m.UniformColor=Qf,m.UniformMatrix2f=class extends vh{constructor(D,_){super(D,_),this.current=u3}set(D){for(let _=0;_<4;_++)if(D[_]!==this.current[_]){this.current=D,this.gl.uniformMatrix2fv(this.location,!1,D);break}}},m.UniformMatrix3f=class extends vh{constructor(D,_){super(D,_),this.current=Lm}set(D){for(let _=0;_<9;_++)if(D[_]!==this.current[_]){this.current=D,this.gl.uniformMatrix3fv(this.location,!1,D);break}}},m.UniformMatrix4f=class extends vh{constructor(D,_){super(D,_),this.current=J3}set(D){if(D[12]!==this.current[12]||D[0]!==this.current[0])return this.current=D,void this.gl.uniformMatrix4fv(this.location,!1,D);for(let _=1;_<16;_++)if(D[_]!==this.current[_]){this.current=D,this.gl.uniformMatrix4fv(this.location,!1,D);break}}},m.UnwrappedTileID=ro,m.ValidationError=ya,m.VectorTileWorkerSource=class extends Wo{constructor(D,_,k,X,de){super(),this.actor=D,this.layerIndex=_,this.availableImages=k,this.loadVectorData=de||Am,this.loading={},this.loaded={},this.deduped=new Em(D.scheduler),this.isSpriteLoaded=X,this.scheduler=D.scheduler}loadTile(D,_){const k=D.uid,X=D&&D.request,de=X&&X.collectResourceTiming,Ge=this.loading[k]=new Jg(D);Ge.abort=this.loadVectorData(D,(ft,_t)=>{const At=!this.loading[k];if(delete this.loading[k],At||ft||!_t)return Ge.status="done",At||(this.loaded[k]=Ge),_(ft);const Nt=_t.rawData,cn={};_t.expires&&(cn.expires=_t.expires),_t.cacheControl&&(cn.cacheControl=_t.cacheControl),Ge.vectorTile=_t.vectorTile||new Vd.VectorTile(new m3(Nt));const vn=()=>{Ge.parse(Ge.vectorTile,this.layerIndex,this.availableImages,this.actor,(bn,jn)=>{if(bn||!jn)return _(bn);const Zn={};if(de){const Br=_0(X);Br.length>0&&(Zn.resourceTiming=JSON.parse(JSON.stringify(Br)))}_(null,mt({rawTileData:Nt.slice(0)},jn,cn,Zn))})};this.isSpriteLoaded?vn():this.once("isSpriteLoaded",()=>{this.scheduler?this.scheduler.add(vn,{type:"parseTile",isSymbolTile:D.isSymbolTile,zoom:D.tileZoom}):vn()}),this.loaded=this.loaded||{},this.loaded[k]=Ge})}reloadTile(D,_){const k=this.loaded,X=D.uid,de=this;if(k&&k[X]){const Ge=k[X];Ge.showCollisionBoxes=D.showCollisionBoxes,Ge.enableTerrain=!!D.enableTerrain,Ge.projection=D.projection,Ge.tileTransform=ko(D.tileID.canonical,D.projection);const ft=(_t,At)=>{const Nt=Ge.reloadCallback;Nt&&(delete Ge.reloadCallback,Ge.parse(Ge.vectorTile,de.layerIndex,this.availableImages,de.actor,Nt)),_(_t,At)};Ge.status==="parsing"?Ge.reloadCallback=ft:Ge.status==="done"&&(Ge.vectorTile?Ge.parse(Ge.vectorTile,this.layerIndex,this.availableImages,this.actor,ft):ft())}}abortTile(D,_){const k=D.uid,X=this.loading[k];X&&(X.abort&&X.abort(),delete this.loading[k]),_()}removeTile(D,_){const k=this.loaded,X=D.uid;k&&k[X]&&delete k[X],_()}},m.WritingMode=Gh,m.ZoomHistory=Tf,m.add=bp,m.addDynamicAttributes=Mc,m.adjoint=function(D,_){var k=_[0],X=_[1],de=_[2],Ge=_[3],ft=_[4],_t=_[5],At=_[6],Nt=_[7],cn=_[8];return D[0]=ft*cn-_t*Nt,D[1]=de*Nt-X*cn,D[2]=X*_t-de*ft,D[3]=_t*At-Ge*cn,D[4]=k*cn-de*At,D[5]=de*Ge-k*_t,D[6]=Ge*Nt-ft*At,D[7]=X*At-k*Nt,D[8]=k*ft-X*Ge,D},m.asyncAll=ue,m.bezier=rt,m.bindAll=pn,m.boundsAttributes=va,m.bufferConvexPolygon=function(D,_){const k=[];for(let X=0;X<D.length;X++){const de=ie(X-1,-1,D.length-1),Ge=ie(X+1,-1,D.length-1),ft=D[X],_t=D[Ge],At=D[de].sub(ft).unit(),Nt=_t.sub(ft).unit(),cn=Nt.angleWithSep(At.x,At.y),vn=At.add(Nt).unit().mult(-1*_/Math.sin(cn/2));k.push(ft.add(vn))}return k},m.cacheEntryPossiblyAdded=function(D){il++,il>xo&&(D.getActor().send("enforceCacheSizeLimit",ls),il=0)},m.calculateGlobeLabelMatrix=function(D,_){const{lng:k,lat:X}=D._center,de=$i(0,0,D.worldSize/D._projectionScaler,k,X);return Zl(de,de,function(Ge){const ft=ld(new Float64Array(16)),_t=1/gi(Ge);return Ch(ft,ft,Ge.min),Cu(ft,ft,[_t,_t,_t]),ft}(En(_)))},m.calculateGlobeMatrix=da,m.calculateGlobeMercatorMatrix=function(D){const _=D.worldSize,k=D.point,X=Hp(1,D.center.lat)*_,de=D.pixelsPerMeter,Ge=_/(X/D.pixelsPerMeter),ft=ld(new Float64Array(16));return Ch(ft,ft,[k.x,k.y,0]),Cu(ft,ft,[Ge,Ge,de]),Float32Array.from(ft)},m.circumferenceAtLatitude=Pf,m.clamp=Te,m.clearTileCache=function(D){const _=J.caches.delete(Aa);D&&_.catch(D).then(()=>D())},m.clipLine=H3,m.clone=function(D){var _=new hh(16);return _[0]=D[0],_[1]=D[1],_[2]=D[2],_[3]=D[3],_[4]=D[4],_[5]=D[5],_[6]=D[6],_[7]=D[7],_[8]=D[8],_[9]=D[9],_[10]=D[10],_[11]=D[11],_[12]=D[12],_[13]=D[13],_[14]=D[14],_[15]=D[15],_},m.clone$1=Rn,m.collisionCircleLayout=Ng,m.config=qn,m.conjugate=function(D,_){return D[0]=-_[0],D[1]=-_[1],D[2]=-_[2],D[3]=_[3],D},m.create=function(){var D=new hh(16);return hh!=Float32Array&&(D[1]=0,D[2]=0,D[3]=0,D[4]=0,D[6]=0,D[7]=0,D[8]=0,D[9]=0,D[11]=0,D[12]=0,D[13]=0,D[14]=0),D[0]=1,D[5]=1,D[10]=1,D[15]=1,D},m.create$1=k3,m.createExpression=ei,m.createLayout=Di,m.createStyleLayer=function(D){return D.type==="custom"?new m0(D):new y0[D.type](D)},m.cross=Wm,m.degToRad=ne,m.div=function(D,_,k){return D[0]=_[0]/k[0],D[1]=_[1]/k[1],D[2]=_[2]/k[2],D},m.dot=Zc,m.earthRadius=tm,m.ease=Ae,m.easeCubicInOut=Ve,m.emitValidationErrors=Sf,m.endsWith=_n,m.enforceCacheSizeLimit=function(D){_o(),Ja&&Ja.then(_=>{_.keys().then(k=>{for(let X=0;X<k.length-D;X++)_.delete(k[X])})})},m.evaluateSizeForFeature=F3,m.evaluateSizeForZoom=_m,m.evaluateVariableOffset=i3,m.evented=Xf,m.exactEquals=function(D,_){return D[0]===_[0]&&D[1]===_[1]&&D[2]===_[2]&&D[3]===_[3]},m.exactEquals$1=function(D,_){return D[0]===_[0]&&D[1]===_[1]&&D[2]===_[2]},m.exported=xi,m.exported$1=ia,m.extend=mt,m.extend$1=$s,m.filterObject=an,m.fromMat4=function(D,_){return D[0]=_[0],D[1]=_[1],D[2]=_[2],D[3]=_[4],D[4]=_[5],D[5]=_[6],D[6]=_[8],D[7]=_[9],D[8]=_[10],D},m.fromQuat=function(D,_){var k=_[0],X=_[1],de=_[2],Ge=_[3],ft=k+k,_t=X+X,At=de+de,Nt=k*ft,cn=X*ft,vn=X*_t,bn=de*ft,jn=de*_t,Zn=de*At,Br=Ge*ft,Jr=Ge*_t,si=Ge*At;return D[0]=1-vn-Zn,D[1]=cn+si,D[2]=bn-Jr,D[3]=0,D[4]=cn-si,D[5]=1-Nt-Zn,D[6]=jn+Br,D[7]=0,D[8]=bn+Jr,D[9]=jn-Br,D[10]=1-Nt-vn,D[11]=0,D[12]=0,D[13]=0,D[14]=0,D[15]=1,D},m.fromRotation=function(D,_){var k=Math.sin(_),X=Math.cos(_);return D[0]=X,D[1]=k,D[2]=0,D[3]=-k,D[4]=X,D[5]=0,D[6]=0,D[7]=0,D[8]=1,D},m.fromScaling=function(D,_){return D[0]=_[0],D[1]=0,D[2]=0,D[3]=0,D[4]=0,D[5]=_[1],D[6]=0,D[7]=0,D[8]=0,D[9]=0,D[10]=_[2],D[11]=0,D[12]=0,D[13]=0,D[14]=0,D[15]=1,D},m.furthestTileCorner=function(D){const _=Math.round((D+45+360)%360/90)%4;return De[_]},m.getAABBPointSquareDist=function(D,_,k){let X=0;for(let de=0;de<2;++de){const Ge=k?k[de]:0;D[de]>Ge&&(X+=(D[de]-Ge)*(D[de]-Ge)),_[de]<Ge&&(X+=(Ge-_[de])*(Ge-_[de]))}return X},m.getAnchorAlignment=j3,m.getAnchorJustification=Ag,m.getBounds=function(D){let _=1/0,k=1/0,X=-1/0,de=-1/0;for(const Ge of D)_=Math.min(_,Ge.x),k=Math.min(k,Ge.y),X=Math.max(X,Ge.x),de=Math.max(de,Ge.y);return{min:new G(_,k),max:new G(X,de)}},m.getColumn=function(D,_){return[D[4*_],D[4*_+1],D[4*_+2],D[4*_+3]]},m.getGridMatrix=function(D,_){const[k,X]=_,de=.015625;return[0,(X[1]-k[1])*de,1<<D.z,(X[0]-k[0])*de,0,D.y,k[0],k[1],de]},m.getImage=wo,m.getJSON=function(D,_){return Gr(mt(D,{type:"json"}),_)},m.getMapSessionAPI=za,m.getPerformanceMeasurement=_0,m.getProjection=function(D){const _=D.parallels,k=!!_&&Math.abs(_[0]+_[1])<.01;switch(D.name){case"mercator":return new K3(D);case"equirectangular":return new xs(D);case"naturalEarth":return new Yo(D);case"equalEarth":return new Na(D);case"winkelTripel":return new dl(D);case"albers":return k?new us(D):new $h(D);case"lambertConformalConic":return k?new us(D):new Cs(D)}throw new Error(`Invalid projection name: ${D.name}`)},m.getRTLTextPluginStatus=Af,m.getReferrer=Un,m.getTilePoint=function(D,{x:_,y:k},X=0){return new G(((_-X)*D.scale-D.x)*Ml,(k*D.scale-D.y)*Ml)},m.getTileVec3=function(D,_,k=0){return Ff(((_.x-k)*D.scale-D.x)*Ml,(_.y*D.scale-D.y)*Ml,If(_.z,_.y))},m.getVideo=function(D,_){const k=J.document.createElement("video");k.muted=!0,k.onloadstart=function(){_(null,k)};for(let X=0;X<D.length;X++){const de=J.document.createElement("source");ta(D[X])||(k.crossOrigin="Anonymous"),de.src=D[X],k.appendChild(de)}return{cancel:()=>{}}},m.globeECEFOrigin=function(D,_){const k=[0,0,0];return Sh(k,k,Ci(En(_.canonical))),Sh(k,k,D),k},m.globePixelsToTileUnits=function(D,_){return Ml/(512*Math.pow(2,D))*gi(En(_))},m.globePoleMatrixForTile=function(D,_,k){const X=ld(new Float64Array(16)),de=1<<D,Ge=360*(_/de-.5),ft=k.point,_t=k.worldSize/(k.tileSize*de);return Ch(X,X,[ft.x,ft.y,-k.worldSize/Math.PI/2]),Cu(X,X,[_t,_t,_t]),xp(X,X,ne(-k._center.lat)),Ru(X,X,ne(-k._center.lng+Ge)),Float32Array.from(X)},m.globeTileLatLngCorners=mn,m.globeToMercatorTransition=function(D){return Xe(5,6,D)},m.identity=ld,m.identity$1=Bf,m.invert=function(D,_){var k=_[0],X=_[1],de=_[2],Ge=_[3],ft=_[4],_t=_[5],At=_[6],Nt=_[7],cn=_[8],vn=_[9],bn=_[10],jn=_[11],Zn=_[12],Br=_[13],Jr=_[14],si=_[15],Li=k*_t-X*ft,vi=k*At-de*ft,ui=k*Nt-Ge*ft,ua=X*At-de*_t,ba=X*Nt-Ge*_t,Ua=de*Nt-Ge*At,Ga=cn*Br-vn*Zn,ho=cn*Jr-bn*Zn,bo=cn*si-jn*Zn,Va=vn*Jr-bn*Br,Ka=vn*si-jn*Br,Do=bn*si-jn*Jr,$o=Li*Do-vi*Ka+ui*Va+ua*bo-ba*ho+Ua*Ga;return $o?(D[0]=(_t*Do-At*Ka+Nt*Va)*($o=1/$o),D[1]=(de*Ka-X*Do-Ge*Va)*$o,D[2]=(Br*Ua-Jr*ba+si*ua)*$o,D[3]=(bn*ba-vn*Ua-jn*ua)*$o,D[4]=(At*bo-ft*Do-Nt*ho)*$o,D[5]=(k*Do-de*bo+Ge*ho)*$o,D[6]=(Jr*ui-Zn*Ua-si*vi)*$o,D[7]=(cn*Ua-bn*ui+jn*vi)*$o,D[8]=(ft*Ka-_t*bo+Nt*Ga)*$o,D[9]=(X*bo-k*Ka-Ge*Ga)*$o,D[10]=(Zn*ba-Br*ui+si*Li)*$o,D[11]=(vn*ui-cn*ba-jn*Li)*$o,D[12]=(_t*ho-ft*Va-At*Ga)*$o,D[13]=(k*Va-X*ho+de*Ga)*$o,D[14]=(Br*vi-Zn*ua-Jr*Li)*$o,D[15]=(cn*ua-vn*vi+bn*Li)*$o,D):null},m.isMapAuthenticated=function(D){return ki.has(D)},m.isMapboxURL=Nn,m.isSafariWithAntialiasingBug=function(D){const _=D.navigator?D.navigator.userAgent:null;return!!Yn(D)&&_&&(_.match("Version/15.4")||_.match("Version/15.5")||_.match(/CPU (OS|iPhone OS) (15_4|15_5) like Mac OS X/))},m.latFromMercatorY=ed,m.len=dm,m.length=um,m.length$1=function(D){return Math.hypot(D[0],D[1],D[2],D[3])},m.loadVectorTile=Am,m.makeRequest=Gr,m.mercatorXfromLng=ch,m.mercatorYfromLat=$p,m.mercatorZfromAltitude=Hp,m.mul=Gm,m.mul$1=cm,m.multiply=function(D,_,k){var X=_[0],de=_[1],Ge=_[2],ft=_[3],_t=_[4],At=_[5],Nt=_[6],cn=_[7],vn=_[8],bn=k[0],jn=k[1],Zn=k[2],Br=k[3],Jr=k[4],si=k[5],Li=k[6],vi=k[7],ui=k[8];return D[0]=bn*X+jn*ft+Zn*Nt,D[1]=bn*de+jn*_t+Zn*cn,D[2]=bn*Ge+jn*At+Zn*vn,D[3]=Br*X+Jr*ft+si*Nt,D[4]=Br*de+Jr*_t+si*cn,D[5]=Br*Ge+Jr*At+si*vn,D[6]=Li*X+vi*ft+ui*Nt,D[7]=Li*de+vi*_t+ui*cn,D[8]=Li*Ge+vi*At+ui*vn,D},m.multiply$1=Zl,m.multiply$2=$m,m.nextPowerOfTwo=nn,m.normalize=Ic,m.normalize$1=function(D,_){var k=_[0],X=_[1],de=_[2],Ge=_[3],ft=k*k+X*X+de*de+Ge*Ge;return ft>0&&(ft=1/Math.sqrt(ft)),D[0]=k*ft,D[1]=X*ft,D[2]=de*ft,D[3]=Ge*ft,D},m.number=Qe,m.ortho=function(D,_,k,X,de,Ge,ft){var _t=1/(_-k),At=1/(X-de),Nt=1/(Ge-ft);return D[0]=-2*_t,D[1]=0,D[2]=0,D[3]=0,D[4]=0,D[5]=-2*At,D[6]=0,D[7]=0,D[8]=0,D[9]=0,D[10]=2*Nt,D[11]=0,D[12]=(_+k)*_t,D[13]=(de+X)*At,D[14]=(ft+Ge)*Nt,D[15]=1,D},m.pbf=m3,m.perspective=function(D,_,k,X,de){var Ge,ft=1/Math.tan(_/2);return D[0]=ft/k,D[1]=0,D[2]=0,D[3]=0,D[4]=0,D[5]=ft,D[6]=0,D[7]=0,D[8]=0,D[9]=0,D[11]=-1,D[12]=0,D[13]=0,D[15]=0,de!=null&&de!==1/0?(D[10]=(de+X)*(Ge=1/(X-de)),D[14]=2*de*X*Ge):(D[10]=-1,D[14]=-2*X),D},m.pick=function(D,_){const k={};for(let X=0;X<_.length;X++){const de=_[X];de in D&&(k[de]=D[de])}return k},m.plugin=$c,m.pointGeometry=G,m.polygonIntersectsBox=am,m.polygonIntersectsPolygon=Md,m.polygonizeBounds=function(D,_,k=0,X=!0){const de=new G(k,k),Ge=D.sub(de),ft=_.add(de),_t=[Ge,new G(ft.x,Ge.y),ft,new G(Ge.x,ft.y)];return X&&_t.push(Ge),_t},m.posAttributes=ct,m.postMapLoadEvent=oi,m.postTurnstileEvent=so,m.potpack=gg,m.prevPowerOfTwo=function(D){return D<=1?1:Math.pow(2,Math.floor(Math.log(D)/Math.LN2))},m.radToDeg=Ue,m.refProperties=["type","source","source-layer","minzoom","maxzoom","filter","layout"],m.registerForPluginStateChange=function(D){return D({pluginStatus:Fd,pluginURL:Bd}),Xf.on("pluginStateChange",D),D},m.removeAuthState=function(D){ki.delete(D)},m.renderColorRamp=Xp,m.rotateX=xp,m.rotateX$1=pf,m.rotateY=Ru,m.rotateZ=function(D,_,k){var X=Math.sin(k),de=Math.cos(k),Ge=_[0],ft=_[1],_t=_[2],At=_[3],Nt=_[4],cn=_[5],vn=_[6],bn=_[7];return _!==D&&(D[8]=_[8],D[9]=_[9],D[10]=_[10],D[11]=_[11],D[12]=_[12],D[13]=_[13],D[14]=_[14],D[15]=_[15]),D[0]=Ge*de+Nt*X,D[1]=ft*de+cn*X,D[2]=_t*de+vn*X,D[3]=At*de+bn*X,D[4]=Nt*de-Ge*X,D[5]=cn*de-ft*X,D[6]=vn*de-_t*X,D[7]=bn*de-At*X,D},m.rotateZ$1=function(D,_,k){k*=.5;var X=_[0],de=_[1],Ge=_[2],ft=_[3],_t=Math.sin(k),At=Math.cos(k);return D[0]=X*At+de*_t,D[1]=de*At-X*_t,D[2]=Ge*At+ft*_t,D[3]=ft*At-Ge*_t,D},m.scale=Cu,m.scale$1=function(D,_,k){return D[0]=_[0]*k,D[1]=_[1]*k,D[2]=_[2]*k,D[3]=_[3]*k,D},m.scale$2=Hm,m.scaleAndAdd=c3,m.setCacheLimits=function(D,_){ls=D,xo=_},m.setColumn=function(D,_,k){D[4*_+0]=k[0],D[4*_+1]=k[1],D[4*_+2]=k[2],D[4*_+3]=k[3]},m.setRTLTextPlugin=function(D,_,k=!1){if(Fd===Oh||Fd===Ef||Fd===Lh)throw new Error("setRTLTextPlugin cannot be called multiple times.");Bd=xi.resolveURL(D),Fd=Oh,Kf=_,mp(),k||Qc()},m.smoothstep=Xe,m.spec=ma,m.storeAuthState=function(D,_){_?ki.add(D):ki.delete(D)},m.sub=Mp,m.subtract=P3,m.symbolSize=Jm,m.tileAABB=function(D,_,k,X,de,Ge,ft,_t,At){if(At.name==="globe")return On(D,_,new Ya(k,X,de));const Nt=ko({z:k,x:X,y:de},At);return new qd([(Ge+Nt.x/Nt.scale)*_,_*(Nt.y/Nt.scale),ft],[(Ge+Nt.x2/Nt.scale)*_,_*(Nt.y2/Nt.scale),_t])},m.tileTransform=ko,m.transformMat3=function(D,_,k){var X=_[0],de=_[1],Ge=_[2];return D[0]=X*k[0]+de*k[3]+Ge*k[6],D[1]=X*k[1]+de*k[4]+Ge*k[7],D[2]=X*k[2]+de*k[5]+Ge*k[8],D},m.transformMat4=Sh,m.transformMat4$1=Qd,m.transformQuat=qm,m.translate=Ch,m.transpose=function(D,_){if(D===_){var k=_[1],X=_[2],de=_[5];D[1]=_[3],D[2]=_[6],D[3]=k,D[5]=_[7],D[6]=X,D[7]=de}else D[0]=_[0],D[1]=_[3],D[2]=_[6],D[3]=_[1],D[4]=_[4],D[5]=_[7],D[6]=_[2],D[7]=_[5],D[8]=_[8];return D},m.triggerPluginCompletionEvent=sf,m.uniqueId=kt,m.validateCustomStyleLayer=function(D){const _=[],k=D.id;return k===void 0&&_.push({message:`layers.${k}: missing required property "id"`}),D.render===void 0&&_.push({message:`layers.${k}: missing required method "render"`}),D.renderingMode&&D.renderingMode!=="2d"&&D.renderingMode!=="3d"&&_.push({message:`layers.${k}: property "renderingMode" must be either "2d" or "3d"`}),_},m.validateFilter=D=>Sc(Fc(D)),m.validateFog=D=>Sc(cp(D)),m.validateLayer=D=>Sc(Cf(D)),m.validateLight=D=>Sc(Lp(D)),m.validateSource=D=>Sc(tf(D)),m.validateStyle=Od,m.validateTerrain=D=>Sc(Ah(D)),m.values=pt,m.vectorTile=Vd,m.version=O,m.warnOnce=wn,m.window=J,m.wrap=ie}),y(["./shared"],function(m){function O(zr){if(typeof zr=="number"||typeof zr=="boolean"||typeof zr=="string"||zr==null)return JSON.stringify(zr);if(Array.isArray(zr)){let Un="[";for(const Gr of zr)Un+=`${O(Gr)},`;return`${Un}]`}let zn="{";for(const Un of Object.keys(zr).sort())zn+=`${Un}:${O(zr[Un])},`;return`${zn}}`}function N(zr){let zn="";for(const Un of m.refProperties)zn+=`/${O(zr[Un])}`;return zn}class L{constructor(zn){this.keyCache={},zn&&this.replace(zn)}replace(zn){this._layerConfigs={},this._layers={},this.update(zn,[])}update(zn,Un){for(const ni of zn)this._layerConfigs[ni.id]=ni,(this._layers[ni.id]=m.createStyleLayer(ni)).compileFilter(),this.keyCache[ni.id]&&delete this.keyCache[ni.id];for(const ni of Un)delete this.keyCache[ni],delete this._layerConfigs[ni],delete this._layers[ni];this.familiesBySource={};const Gr=function(ni,Ei){const $t={};for(let Hi=0;Hi<ni.length;Hi++){const Ai=Ei&&Ei[ni[Hi].id]||N(ni[Hi]);Ei&&(Ei[ni[Hi].id]=Ai);let Ea=$t[Ai];Ea||(Ea=$t[Ai]=[]),Ea.push(ni[Hi])}const ta=[];for(const Hi in $t)ta.push($t[Hi]);return ta}(m.values(this._layerConfigs),this.keyCache);for(const ni of Gr){const Ei=ni.map(wo=>this._layers[wo.id]),$t=Ei[0];if($t.visibility==="none")continue;const ta=$t.source||"";let Hi=this.familiesBySource[ta];Hi||(Hi=this.familiesBySource[ta]={});const Ai=$t.sourceLayer||"_geojsonTileLayer";let Ea=Hi[Ai];Ea||(Ea=Hi[Ai]=[]),Ea.push(Ei)}}}class G{loadTile(zn,Un){const{uid:Gr,encoding:ni,rawImageData:Ei,padding:$t,buildQuadTree:ta}=zn,Hi=m.window.ImageBitmap&&Ei instanceof m.window.ImageBitmap?this.getImageData(Ei,$t):Ei;Un(null,new m.DEMData(Gr,Hi,ni,$t<1,ta))}getImageData(zn,Un){this.offscreenCanvas&&this.offscreenCanvasContext||(this.offscreenCanvas=new OffscreenCanvas(zn.width,zn.height),this.offscreenCanvasContext=this.offscreenCanvas.getContext("2d")),this.offscreenCanvas.width=zn.width,this.offscreenCanvas.height=zn.height,this.offscreenCanvasContext.drawImage(zn,0,0,zn.width,zn.height);const Gr=this.offscreenCanvasContext.getImageData(-Un,-Un,zn.width+2*Un,zn.height+2*Un);return this.offscreenCanvasContext.clearRect(0,0,this.offscreenCanvas.width,this.offscreenCanvas.height),Gr}}var q=function zr(zn,Un){var Gr,ni=zn&&zn.type;if(ni==="FeatureCollection")for(Gr=0;Gr<zn.features.length;Gr++)zr(zn.features[Gr],Un);else if(ni==="GeometryCollection")for(Gr=0;Gr<zn.geometries.length;Gr++)zr(zn.geometries[Gr],Un);else if(ni==="Feature")zr(zn.geometry,Un);else if(ni==="Polygon")J(zn.coordinates,Un);else if(ni==="MultiPolygon")for(Gr=0;Gr<zn.coordinates.length;Gr++)J(zn.coordinates[Gr],Un);return zn};function J(zr,zn){if(zr.length!==0){fe(zr[0],zn);for(var Un=1;Un<zr.length;Un++)fe(zr[Un],!zn)}}function fe(zr,zn){for(var Un=0,Gr=0,ni=0,Ei=zr.length,$t=Ei-1;ni<Ei;$t=ni++){var ta=(zr[ni][0]-zr[$t][0])*(zr[$t][1]+zr[ni][1]),Hi=Un+ta;Gr+=Math.abs(Un)>=Math.abs(ta)?Un-Hi+ta:ta-Hi+Un,Un=Hi}Un+Gr>=0!=!!zn&&zr.reverse()}const ve=m.vectorTile.VectorTileFeature.prototype.toGeoJSON;class ne{constructor(zn){this._feature=zn,this.extent=m.EXTENT,this.type=zn.type,this.properties=zn.tags,"id"in zn&&!isNaN(zn.id)&&(this.id=parseInt(zn.id,10))}loadGeometry(){if(this._feature.type===1){const zn=[];for(const Un of this._feature.geometry)zn.push([new m.pointGeometry(Un[0],Un[1])]);return zn}{const zn=[];for(const Un of this._feature.geometry){const Gr=[];for(const ni of Un)Gr.push(new m.pointGeometry(ni[0],ni[1]));zn.push(Gr)}return zn}}toGeoJSON(zn,Un,Gr){return ve.call(this,zn,Un,Gr)}}class Ue{constructor(zn){this.layers={_geojsonTileLayer:this},this.name="_geojsonTileLayer",this.extent=m.EXTENT,this.length=zn.length,this._features=zn}feature(zn){return new ne(this._features[zn])}}var De=m.vectorTile.VectorTileFeature,Ve=rt;function rt(zr,zn){this.options=zn||{},this.features=zr,this.length=zr.length}function Ae(zr,zn){this.id=typeof zr.id=="number"?zr.id:void 0,this.type=zr.type,this.rawGeometry=zr.type===1?[zr.geometry]:zr.geometry,this.properties=zr.tags,this.extent=zn||4096}rt.prototype.feature=function(zr){return new Ae(this.features[zr],this.options.extent)},Ae.prototype.loadGeometry=function(){var zr=this.rawGeometry;this.geometry=[];for(var zn=0;zn<zr.length;zn++){for(var Un=zr[zn],Gr=[],ni=0;ni<Un.length;ni++)Gr.push(new m.pointGeometry(Un[ni][0],Un[ni][1]));this.geometry.push(Gr)}return this.geometry},Ae.prototype.bbox=function(){this.geometry||this.loadGeometry();for(var zr=this.geometry,zn=1/0,Un=-1/0,Gr=1/0,ni=-1/0,Ei=0;Ei<zr.length;Ei++)for(var $t=zr[Ei],ta=0;ta<$t.length;ta++){var Hi=$t[ta];zn=Math.min(zn,Hi.x),Un=Math.max(Un,Hi.x),Gr=Math.min(Gr,Hi.y),ni=Math.max(ni,Hi.y)}return[zn,Gr,Un,ni]},Ae.prototype.toGeoJSON=De.prototype.toGeoJSON;var Te=ie,Xe=Ve;function ie(zr){var zn=new m.pbf;return function(Un,Gr){for(var ni in Un.layers)Gr.writeMessage(3,ue,Un.layers[ni])}(zr,zn),zn.finish()}function ue(zr,zn){var Un;zn.writeVarintField(15,zr.version||1),zn.writeStringField(1,zr.name||""),zn.writeVarintField(5,zr.extent||4096);var Gr={keys:[],values:[],keycache:{},valuecache:{}};for(Un=0;Un<zr.length;Un++)Gr.feature=zr.feature(Un),zn.writeMessage(2,pt,Gr);var ni=Gr.keys;for(Un=0;Un<ni.length;Un++)zn.writeStringField(3,ni[Un]);var Ei=Gr.values;for(Un=0;Un<Ei.length;Un++)zn.writeMessage(4,nn,Ei[Un])}function pt(zr,zn){var Un=zr.feature;Un.id!==void 0&&zn.writeVarintField(1,Un.id),zn.writeMessage(2,mt,zr),zn.writeVarintField(3,Un.type),zn.writeMessage(4,It,Un)}function mt(zr,zn){var Un=zr.feature,Gr=zr.keys,ni=zr.values,Ei=zr.keycache,$t=zr.valuecache;for(var ta in Un.properties){var Hi=Un.properties[ta],Ai=Ei[ta];if(Hi!==null){Ai===void 0&&(Gr.push(ta),Ei[ta]=Ai=Gr.length-1),zn.writeVarint(Ai);var Ea=typeof Hi;Ea!=="string"&&Ea!=="boolean"&&Ea!=="number"&&(Hi=JSON.stringify(Hi));var wo=Ea+":"+Hi,to=$t[wo];to===void 0&&(ni.push(Hi),$t[wo]=to=ni.length-1),zn.writeVarint(to)}}}function Tt(zr,zn){return(zn<<3)+(7&zr)}function kt(zr){return zr<<1^zr>>31}function It(zr,zn){for(var Un=zr.loadGeometry(),Gr=zr.type,ni=0,Ei=0,$t=Un.length,ta=0;ta<$t;ta++){var Hi=Un[ta],Ai=1;Gr===1&&(Ai=Hi.length),zn.writeVarint(Tt(1,Ai));for(var Ea=Gr===3?Hi.length-1:Hi.length,wo=0;wo<Ea;wo++){wo===1&&Gr!==1&&zn.writeVarint(Tt(2,Ea-1));var to=Hi[wo].x-ni,zo=Hi[wo].y-Ei;zn.writeVarint(kt(to)),zn.writeVarint(kt(zo)),ni+=to,Ei+=zo}Gr===3&&zn.writeVarint(Tt(7,1))}}function nn(zr,zn){var Un=typeof zr;Un==="string"?zn.writeStringField(1,zr):Un==="boolean"?zn.writeBooleanField(7,zr):Un==="number"&&(zr%1!=0?zn.writeDoubleField(3,zr):zr<0?zn.writeSVarintField(6,zr):zn.writeVarintField(5,zr))}function tn(zr,zn,Un,Gr,ni,Ei){if(ni-Gr<=Un)return;const $t=Gr+ni>>1;pn(zr,zn,$t,Gr,ni,Ei%2),tn(zr,zn,Un,Gr,$t-1,Ei+1),tn(zr,zn,Un,$t+1,ni,Ei+1)}function pn(zr,zn,Un,Gr,ni,Ei){for(;ni>Gr;){if(ni-Gr>600){const Ai=ni-Gr+1,Ea=Un-Gr+1,wo=Math.log(Ai),to=.5*Math.exp(2*wo/3),zo=.5*Math.sqrt(wo*to*(Ai-to)/Ai)*(Ea-Ai/2<0?-1:1);pn(zr,zn,Un,Math.max(Gr,Math.floor(Un-Ea*to/Ai+zo)),Math.min(ni,Math.floor(Un+(Ai-Ea)*to/Ai+zo)),Ei)}const $t=zn[2*Un+Ei];let ta=Gr,Hi=ni;for(_n(zr,zn,Gr,Un),zn[2*ni+Ei]>$t&&_n(zr,zn,Gr,ni);ta<Hi;){for(_n(zr,zn,ta,Hi),ta++,Hi--;zn[2*ta+Ei]<$t;)ta++;for(;zn[2*Hi+Ei]>$t;)Hi--}zn[2*Gr+Ei]===$t?_n(zr,zn,Gr,Hi):(Hi++,_n(zr,zn,Hi,ni)),Hi<=Un&&(Gr=Hi+1),Un<=Hi&&(ni=Hi-1)}}function _n(zr,zn,Un,Gr){Dn(zr,Un,Gr),Dn(zn,2*Un,2*Gr),Dn(zn,2*Un+1,2*Gr+1)}function Dn(zr,zn,Un){const Gr=zr[zn];zr[zn]=zr[Un],zr[Un]=Gr}function an(zr,zn,Un,Gr){const ni=zr-Un,Ei=zn-Gr;return ni*ni+Ei*Ei}Te.fromVectorTileJs=ie,Te.fromGeojsonVt=function(zr,zn){zn=zn||{};var Un={};for(var Gr in zr)Un[Gr]=new Ve(zr[Gr].features,zn),Un[Gr].name=Gr,Un[Gr].version=zn.version,Un[Gr].extent=zn.extent;return ie({layers:Un})},Te.GeoJSONWrapper=Xe;const Rn=zr=>zr[0],Lt=zr=>zr[1];class wn{constructor(zn,Un=Rn,Gr=Lt,ni=64,Ei=Float64Array){this.nodeSize=ni,this.points=zn;const $t=zn.length<65536?Uint16Array:Uint32Array,ta=this.ids=new $t(zn.length),Hi=this.coords=new Ei(2*zn.length);for(let Ai=0;Ai<zn.length;Ai++)ta[Ai]=Ai,Hi[2*Ai]=Un(zn[Ai]),Hi[2*Ai+1]=Gr(zn[Ai]);tn(ta,Hi,ni,0,ta.length-1,0)}range(zn,Un,Gr,ni){return function(Ei,$t,ta,Hi,Ai,Ea,wo){const to=[0,Ei.length-1,0],zo=[];let Po,Lo;for(;to.length;){const Wo=to.pop(),ma=to.pop(),$s=to.pop();if(ma-$s<=wo){for(let qo=$s;qo<=ma;qo++)Po=$t[2*qo],Lo=$t[2*qo+1],Po>=ta&&Po<=Ai&&Lo>=Hi&&Lo<=Ea&&zo.push(Ei[qo]);continue}const ao=Math.floor(($s+ma)/2);Po=$t[2*ao],Lo=$t[2*ao+1],Po>=ta&&Po<=Ai&&Lo>=Hi&&Lo<=Ea&&zo.push(Ei[ao]);const Ps=(Wo+1)%2;(Wo===0?ta<=Po:Hi<=Lo)&&(to.push($s),to.push(ao-1),to.push(Ps)),(Wo===0?Ai>=Po:Ea>=Lo)&&(to.push(ao+1),to.push(ma),to.push(Ps))}return zo}(this.ids,this.coords,zn,Un,Gr,ni,this.nodeSize)}within(zn,Un,Gr){return function(ni,Ei,$t,ta,Hi,Ai){const Ea=[0,ni.length-1,0],wo=[],to=Hi*Hi;for(;Ea.length;){const zo=Ea.pop(),Po=Ea.pop(),Lo=Ea.pop();if(Po-Lo<=Ai){for(let Ps=Lo;Ps<=Po;Ps++)an(Ei[2*Ps],Ei[2*Ps+1],$t,ta)<=to&&wo.push(ni[Ps]);continue}const Wo=Math.floor((Lo+Po)/2),ma=Ei[2*Wo],$s=Ei[2*Wo+1];an(ma,$s,$t,ta)<=to&&wo.push(ni[Wo]);const ao=(zo+1)%2;(zo===0?$t-Hi<=ma:ta-Hi<=$s)&&(Ea.push(Lo),Ea.push(Wo-1),Ea.push(ao)),(zo===0?$t+Hi>=ma:ta+Hi>=$s)&&(Ea.push(Wo+1),Ea.push(Po),Ea.push(ao))}return wo}(this.ids,this.coords,zn,Un,Gr,this.nodeSize)}}const hn={minZoom:0,maxZoom:16,minPoints:2,radius:40,extent:512,nodeSize:64,log:!1,generateId:!1,reduce:null,map:zr=>zr},xn=Math.fround||($n=new Float32Array(1),zr=>($n[0]=+zr,$n[0]));var $n;class Xr{constructor(zn){this.options=xi(Object.create(hn),zn),this.trees=new Array(this.options.maxZoom+1)}load(zn){const{log:Un,minZoom:Gr,maxZoom:ni,nodeSize:Ei}=this.options;Un&&console.time("total time");const $t=`prepare ${zn.length} points`;Un&&console.time($t),this.points=zn;let ta=[];for(let Hi=0;Hi<zn.length;Hi++)zn[Hi].geometry&&ta.push(gn(zn[Hi],Hi));this.trees[ni+1]=new wn(ta,Si,qn,Ei,Float32Array),Un&&console.timeEnd($t);for(let Hi=ni;Hi>=Gr;Hi--){const Ai=+Date.now();ta=this._cluster(ta,Hi),this.trees[Hi]=new wn(ta,Si,qn,Ei,Float32Array),Un&&console.log("z%d: %d clusters in %dms",Hi,ta.length,+Date.now()-Ai)}return Un&&console.timeEnd("total time"),this}getClusters(zn,Un){let Gr=((zn[0]+180)%360+360)%360-180;const ni=Math.max(-90,Math.min(90,zn[1]));let Ei=zn[2]===180?180:((zn[2]+180)%360+360)%360-180;const $t=Math.max(-90,Math.min(90,zn[3]));if(zn[2]-zn[0]>=360)Gr=-180,Ei=180;else if(Gr>Ei){const Ea=this.getClusters([Gr,ni,180,$t],Un),wo=this.getClusters([-180,ni,Ei,$t],Un);return Ea.concat(wo)}const ta=this.trees[this._limitZoom(Un)],Hi=ta.range(Vn(Gr),Yn($t),Vn(Ei),Yn(ni)),Ai=[];for(const Ea of Hi){const wo=ta.points[Ea];Ai.push(wo.numPoints?Xn(wo):this.points[wo.index])}return Ai}getChildren(zn){const Un=this._getOriginId(zn),Gr=this._getOriginZoom(zn),ni="No cluster with the specified id.",Ei=this.trees[Gr];if(!Ei)throw new Error(ni);const $t=Ei.points[Un];if(!$t)throw new Error(ni);const ta=this.options.radius/(this.options.extent*Math.pow(2,Gr-1)),Hi=Ei.within($t.x,$t.y,ta),Ai=[];for(const Ea of Hi){const wo=Ei.points[Ea];wo.parentId===zn&&Ai.push(wo.numPoints?Xn(wo):this.points[wo.index])}if(Ai.length===0)throw new Error(ni);return Ai}getLeaves(zn,Un,Gr){const ni=[];return this._appendLeaves(ni,zn,Un=Un||10,Gr=Gr||0,0),ni}getTile(zn,Un,Gr){const ni=this.trees[this._limitZoom(zn)],Ei=Math.pow(2,zn),{extent:$t,radius:ta}=this.options,Hi=ta/$t,Ai=(Gr-Hi)/Ei,Ea=(Gr+1+Hi)/Ei,wo={features:[]};return this._addTileFeatures(ni.range((Un-Hi)/Ei,Ai,(Un+1+Hi)/Ei,Ea),ni.points,Un,Gr,Ei,wo),Un===0&&this._addTileFeatures(ni.range(1-Hi/Ei,Ai,1,Ea),ni.points,Ei,Gr,Ei,wo),Un===Ei-1&&this._addTileFeatures(ni.range(0,Ai,Hi/Ei,Ea),ni.points,-1,Gr,Ei,wo),wo.features.length?wo:null}getClusterExpansionZoom(zn){let Un=this._getOriginZoom(zn)-1;for(;Un<=this.options.maxZoom;){const Gr=this.getChildren(zn);if(Un++,Gr.length!==1)break;zn=Gr[0].properties.cluster_id}return Un}_appendLeaves(zn,Un,Gr,ni,Ei){const $t=this.getChildren(Un);for(const ta of $t){const Hi=ta.properties;if(Hi&&Hi.cluster?Ei+Hi.point_count<=ni?Ei+=Hi.point_count:Ei=this._appendLeaves(zn,Hi.cluster_id,Gr,ni,Ei):Ei<ni?Ei++:zn.push(ta),zn.length===Gr)break}return Ei}_addTileFeatures(zn,Un,Gr,ni,Ei,$t){for(const ta of zn){const Hi=Un[ta],Ai=Hi.numPoints;let Ea,wo,to;if(Ai)Ea=Kn(Hi),wo=Hi.x,to=Hi.y;else{const Lo=this.points[Hi.index];Ea=Lo.properties,wo=Vn(Lo.geometry.coordinates[0]),to=Yn(Lo.geometry.coordinates[1])}const zo={type:1,geometry:[[Math.round(this.options.extent*(wo*Ei-Gr)),Math.round(this.options.extent*(to*Ei-ni))]],tags:Ea};let Po;Ai?Po=Hi.id:this.options.generateId?Po=Hi.index:this.points[Hi.index].id&&(Po=this.points[Hi.index].id),Po!==void 0&&(zo.id=Po),$t.features.push(zo)}}_limitZoom(zn){return Math.max(this.options.minZoom,Math.min(+zn,this.options.maxZoom+1))}_cluster(zn,Un){const Gr=[],{radius:ni,extent:Ei,reduce:$t,minPoints:ta}=this.options,Hi=ni/(Ei*Math.pow(2,Un));for(let Ai=0;Ai<zn.length;Ai++){const Ea=zn[Ai];if(Ea.zoom<=Un)continue;Ea.zoom=Un;const wo=this.trees[Un+1],to=wo.within(Ea.x,Ea.y,Hi),zo=Ea.numPoints||1;let Po=zo;for(const Lo of to){const Wo=wo.points[Lo];Wo.zoom>Un&&(Po+=Wo.numPoints||1)}if(Po>zo&&Po>=ta){let Lo=Ea.x*zo,Wo=Ea.y*zo,ma=$t&&zo>1?this._map(Ea,!0):null;const $s=(Ai<<5)+(Un+1)+this.points.length;for(const ao of to){const Ps=wo.points[ao];if(Ps.zoom<=Un)continue;Ps.zoom=Un;const qo=Ps.numPoints||1;Lo+=Ps.x*qo,Wo+=Ps.y*qo,Ps.parentId=$s,$t&&(ma||(ma=this._map(Ea,!0)),$t(ma,this._map(Ps)))}Ea.parentId=$s,Gr.push(ti(Lo/Po,Wo/Po,$s,Po,ma))}else if(Gr.push(Ea),Po>1)for(const Lo of to){const Wo=wo.points[Lo];Wo.zoom<=Un||(Wo.zoom=Un,Gr.push(Wo))}}return Gr}_getOriginId(zn){return zn-this.points.length>>5}_getOriginZoom(zn){return(zn-this.points.length)%32}_map(zn,Un){if(zn.numPoints)return Un?xi({},zn.properties):zn.properties;const Gr=this.points[zn.index].properties,ni=this.options.map(Gr);return Un&&ni===Gr?xi({},ni):ni}}function ti(zr,zn,Un,Gr,ni){return{x:xn(zr),y:xn(zn),zoom:1/0,id:Un,parentId:-1,numPoints:Gr,properties:ni}}function gn(zr,zn){const[Un,Gr]=zr.geometry.coordinates;return{x:xn(Vn(Un)),y:xn(Yn(Gr)),zoom:1/0,index:zn,parentId:-1}}function Xn(zr){return{type:"Feature",id:zr.id,properties:Kn(zr),geometry:{type:"Point",coordinates:[(zn=zr.x,360*(zn-.5)),Vr(zr.y)]}};var zn}function Kn(zr){const zn=zr.numPoints,Un=zn>=1e4?`${Math.round(zn/1e3)}k`:zn>=1e3?Math.round(zn/100)/10+"k":zn;return xi(xi({},zr.properties),{cluster:!0,cluster_id:zr.id,point_count:zn,point_count_abbreviated:Un})}function Vn(zr){return zr/360+.5}function Yn(zr){const zn=Math.sin(zr*Math.PI/180),Un=.5-.25*Math.log((1+zn)/(1-zn))/Math.PI;return Un<0?0:Un>1?1:Un}function Vr(zr){const zn=(180-360*zr)*Math.PI/180;return 360*Math.atan(Math.exp(zn))/Math.PI-90}function xi(zr,zn){for(const Un in zn)zr[Un]=zn[Un];return zr}function Si(zr){return zr.x}function qn(zr){return zr.y}function ia(zr,zn,Un,Gr){for(var ni,Ei=Gr,$t=Un-zn>>1,ta=Un-zn,Hi=zr[zn],Ai=zr[zn+1],Ea=zr[Un],wo=zr[Un+1],to=zn+3;to<Un;to+=3){var zo=Wi(zr[to],zr[to+1],Hi,Ai,Ea,wo);if(zo>Ei)ni=to,Ei=zo;else if(zo===Ei){var Po=Math.abs(to-$t);Po<ta&&(ni=to,ta=Po)}}Ei>Gr&&(ni-zn>3&&ia(zr,zn,ni,Gr),zr[ni+2]=Ei,Un-ni>3&&ia(zr,ni,Un,Gr))}function Wi(zr,zn,Un,Gr,ni,Ei){var $t=ni-Un,ta=Ei-Gr;if($t!==0||ta!==0){var Hi=((zr-Un)*$t+(zn-Gr)*ta)/($t*$t+ta*ta);Hi>1?(Un=ni,Gr=Ei):Hi>0&&(Un+=$t*Hi,Gr+=ta*Hi)}return($t=zr-Un)*$t+(ta=zn-Gr)*ta}function ha(zr,zn,Un,Gr){var ni={id:zr===void 0?null:zr,type:zn,geometry:Un,tags:Gr,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0};return function(Ei){var $t=Ei.geometry,ta=Ei.type;if(ta==="Point"||ta==="MultiPoint"||ta==="LineString")ai(Ei,$t);else if(ta==="Polygon"||ta==="MultiLineString")for(var Hi=0;Hi<$t.length;Hi++)ai(Ei,$t[Hi]);else if(ta==="MultiPolygon")for(Hi=0;Hi<$t.length;Hi++)for(var Ai=0;Ai<$t[Hi].length;Ai++)ai(Ei,$t[Hi][Ai])}(ni),ni}function ai(zr,zn){for(var Un=0;Un<zn.length;Un+=3)zr.minX=Math.min(zr.minX,zn[Un]),zr.minY=Math.min(zr.minY,zn[Un+1]),zr.maxX=Math.max(zr.maxX,zn[Un]),zr.maxY=Math.max(zr.maxY,zn[Un+1])}function Ia(zr,zn,Un,Gr){if(zn.geometry){var ni=zn.geometry.coordinates,Ei=zn.geometry.type,$t=Math.pow(Un.tolerance/((1<<Un.maxZoom)*Un.extent),2),ta=[],Hi=zn.id;if(Un.promoteId?Hi=zn.properties[Un.promoteId]:Un.generateId&&(Hi=Gr||0),Ei==="Point")fi(ni,ta);else if(Ei==="MultiPoint")for(var Ai=0;Ai<ni.length;Ai++)fi(ni[Ai],ta);else if(Ei==="LineString")An(ni,ta,$t,!1);else if(Ei==="MultiLineString"){if(Un.lineMetrics){for(Ai=0;Ai<ni.length;Ai++)An(ni[Ai],ta=[],$t,!1),zr.push(ha(Hi,"LineString",ta,zn.properties));return}sa(ni,ta,$t,!1)}else if(Ei==="Polygon")sa(ni,ta,$t,!0);else{if(Ei!=="MultiPolygon"){if(Ei==="GeometryCollection"){for(Ai=0;Ai<zn.geometry.geometries.length;Ai++)Ia(zr,{id:Hi,geometry:zn.geometry.geometries[Ai],properties:zn.properties},Un,Gr);return}throw new Error("Input data is not a valid GeoJSON object.")}for(Ai=0;Ai<ni.length;Ai++){var Ea=[];sa(ni[Ai],Ea,$t,!0),ta.push(Ea)}}zr.push(ha(Hi,Ei,ta,zn.properties))}}function fi(zr,zn){zn.push(Nn(zr[0])),zn.push(fn(zr[1])),zn.push(0)}function An(zr,zn,Un,Gr){for(var ni,Ei,$t=0,ta=0;ta<zr.length;ta++){var Hi=Nn(zr[ta][0]),Ai=fn(zr[ta][1]);zn.push(Hi),zn.push(Ai),zn.push(0),ta>0&&($t+=Gr?(ni*Ai-Hi*Ei)/2:Math.sqrt(Math.pow(Hi-ni,2)+Math.pow(Ai-Ei,2))),ni=Hi,Ei=Ai}var Ea=zn.length-3;zn[2]=1,ia(zn,0,Ea,Un),zn[Ea+2]=1,zn.size=Math.abs($t),zn.start=0,zn.end=zn.size}function sa(zr,zn,Un,Gr){for(var ni=0;ni<zr.length;ni++){var Ei=[];An(zr[ni],Ei,Un,Gr),zn.push(Ei)}}function Nn(zr){return zr/360+.5}function fn(zr){var zn=Math.sin(zr*Math.PI/180),Un=.5-.25*Math.log((1+zn)/(1-zn))/Math.PI;return Un<0?0:Un>1?1:Un}function un(zr,zn,Un,Gr,ni,Ei,$t,ta){if(Gr/=zn,Ei>=(Un/=zn)&&$t<Gr)return zr;if($t<Un||Ei>=Gr)return null;for(var Hi=[],Ai=0;Ai<zr.length;Ai++){var Ea=zr[Ai],wo=Ea.geometry,to=Ea.type,zo=ni===0?Ea.minX:Ea.minY,Po=ni===0?Ea.maxX:Ea.maxY;if(zo>=Un&&Po<Gr)Hi.push(Ea);else if(!(Po<Un||zo>=Gr)){var Lo=[];if(to==="Point"||to==="MultiPoint")Ln(wo,Lo,Un,Gr,ni);else if(to==="LineString")hr(wo,Lo,Un,Gr,ni,!1,ta.lineMetrics);else if(to==="MultiLineString")bi(wo,Lo,Un,Gr,ni,!1);else if(to==="Polygon")bi(wo,Lo,Un,Gr,ni,!0);else if(to==="MultiPolygon")for(var Wo=0;Wo<wo.length;Wo++){var ma=[];bi(wo[Wo],ma,Un,Gr,ni,!0),ma.length&&Lo.push(ma)}if(Lo.length){if(ta.lineMetrics&&to==="LineString"){for(Wo=0;Wo<Lo.length;Wo++)Hi.push(ha(Ea.id,to,Lo[Wo],Ea.tags));continue}to!=="LineString"&&to!=="MultiLineString"||(Lo.length===1?(to="LineString",Lo=Lo[0]):to="MultiLineString"),to!=="Point"&&to!=="MultiPoint"||(to=Lo.length===3?"Point":"MultiPoint"),Hi.push(ha(Ea.id,to,Lo,Ea.tags))}}}return Hi.length?Hi:null}function Ln(zr,zn,Un,Gr,ni){for(var Ei=0;Ei<zr.length;Ei+=3){var $t=zr[Ei+ni];$t>=Un&&$t<=Gr&&(zn.push(zr[Ei]),zn.push(zr[Ei+1]),zn.push(zr[Ei+2]))}}function hr(zr,zn,Un,Gr,ni,Ei,$t){for(var ta,Hi,Ai=hi(zr),Ea=ni===0?so:Pi,wo=zr.start,to=0;to<zr.length-3;to+=3){var zo=zr[to],Po=zr[to+1],Lo=zr[to+2],Wo=zr[to+3],ma=zr[to+4],$s=ni===0?zo:Po,ao=ni===0?Wo:ma,Ps=!1;$t&&(ta=Math.sqrt(Math.pow(zo-Wo,2)+Math.pow(Po-ma,2))),$s<Un?ao>Un&&(Hi=Ea(Ai,zo,Po,Wo,ma,Un),$t&&(Ai.start=wo+ta*Hi)):$s>Gr?ao<Gr&&(Hi=Ea(Ai,zo,Po,Wo,ma,Gr),$t&&(Ai.start=wo+ta*Hi)):Ra(Ai,zo,Po,Lo),ao<Un&&$s>=Un&&(Hi=Ea(Ai,zo,Po,Wo,ma,Un),Ps=!0),ao>Gr&&$s<=Gr&&(Hi=Ea(Ai,zo,Po,Wo,ma,Gr),Ps=!0),!Ei&&Ps&&($t&&(Ai.end=wo+ta*Hi),zn.push(Ai),Ai=hi(zr)),$t&&(wo+=ta)}var qo=zr.length-3;zo=zr[qo],Po=zr[qo+1],Lo=zr[qo+2],($s=ni===0?zo:Po)>=Un&&$s<=Gr&&Ra(Ai,zo,Po,Lo),qo=Ai.length-3,Ei&&qo>=3&&(Ai[qo]!==Ai[0]||Ai[qo+1]!==Ai[1])&&Ra(Ai,Ai[0],Ai[1],Ai[2]),Ai.length&&zn.push(Ai)}function hi(zr){var zn=[];return zn.size=zr.size,zn.start=zr.start,zn.end=zr.end,zn}function bi(zr,zn,Un,Gr,ni,Ei){for(var $t=0;$t<zr.length;$t++)hr(zr[$t],zn,Un,Gr,ni,Ei,!1)}function Ra(zr,zn,Un,Gr){zr.push(zn),zr.push(Un),zr.push(Gr)}function so(zr,zn,Un,Gr,ni,Ei){var $t=(Ei-zn)/(Gr-zn);return zr.push(Ei),zr.push(Un+(ni-Un)*$t),zr.push(1),$t}function Pi(zr,zn,Un,Gr,ni,Ei){var $t=(Ei-Un)/(ni-Un);return zr.push(zn+(Gr-zn)*$t),zr.push(Ei),zr.push(1),$t}function oi(zr,zn){for(var Un=[],Gr=0;Gr<zr.length;Gr++){var ni,Ei=zr[Gr],$t=Ei.type;if($t==="Point"||$t==="MultiPoint"||$t==="LineString")ni=Ni(Ei.geometry,zn);else if($t==="MultiLineString"||$t==="Polygon"){ni=[];for(var ta=0;ta<Ei.geometry.length;ta++)ni.push(Ni(Ei.geometry[ta],zn))}else if($t==="MultiPolygon")for(ni=[],ta=0;ta<Ei.geometry.length;ta++){for(var Hi=[],Ai=0;Ai<Ei.geometry[ta].length;Ai++)Hi.push(Ni(Ei.geometry[ta][Ai],zn));ni.push(Hi)}Un.push(ha(Ei.id,$t,ni,Ei.tags))}return Un}function Ni(zr,zn){var Un=[];Un.size=zr.size,zr.start!==void 0&&(Un.start=zr.start,Un.end=zr.end);for(var Gr=0;Gr<zr.length;Gr+=3)Un.push(zr[Gr]+zn,zr[Gr+1],zr[Gr+2]);return Un}function za(zr,zn){if(zr.transformed)return zr;var Un,Gr,ni,Ei=1<<zr.z,$t=zr.x,ta=zr.y;for(Un=0;Un<zr.features.length;Un++){var Hi=zr.features[Un],Ai=Hi.geometry,Ea=Hi.type;if(Hi.geometry=[],Ea===1)for(Gr=0;Gr<Ai.length;Gr+=2)Hi.geometry.push(ki(Ai[Gr],Ai[Gr+1],zn,Ei,$t,ta));else for(Gr=0;Gr<Ai.length;Gr++){var wo=[];for(ni=0;ni<Ai[Gr].length;ni+=2)wo.push(ki(Ai[Gr][ni],Ai[Gr][ni+1],zn,Ei,$t,ta));Hi.geometry.push(wo)}}return zr.transformed=!0,zr}function ki(zr,zn,Un,Gr,ni,Ei){return[Math.round(Un*(zr*Gr-ni)),Math.round(Un*(zn*Gr-Ei))]}function Aa(zr,zn,Un,Gr,ni){for(var Ei=zn===ni.maxZoom?0:ni.tolerance/((1<<zn)*ni.extent),$t={features:[],numPoints:0,numSimplified:0,numFeatures:0,source:null,x:Un,y:Gr,z:zn,transformed:!1,minX:2,minY:1,maxX:-1,maxY:0},ta=0;ta<zr.length;ta++){$t.numFeatures++,Ja($t,zr[ta],Ei,ni);var Hi=zr[ta].minX,Ai=zr[ta].minY,Ea=zr[ta].maxX,wo=zr[ta].maxY;Hi<$t.minX&&($t.minX=Hi),Ai<$t.minY&&($t.minY=Ai),Ea>$t.maxX&&($t.maxX=Ea),wo>$t.maxY&&($t.maxY=wo)}return $t}function Ja(zr,zn,Un,Gr){var ni=zn.geometry,Ei=zn.type,$t=[];if(Ei==="Point"||Ei==="MultiPoint")for(var ta=0;ta<ni.length;ta+=3)$t.push(ni[ta]),$t.push(ni[ta+1]),zr.numPoints++,zr.numSimplified++;else if(Ei==="LineString")yo($t,ni,zr,Un,!1,!1);else if(Ei==="MultiLineString"||Ei==="Polygon")for(ta=0;ta<ni.length;ta++)yo($t,ni[ta],zr,Un,Ei==="Polygon",ta===0);else if(Ei==="MultiPolygon")for(var Hi=0;Hi<ni.length;Hi++){var Ai=ni[Hi];for(ta=0;ta<Ai.length;ta++)yo($t,Ai[ta],zr,Un,!0,ta===0)}if($t.length){var Ea=zn.tags||null;if(Ei==="LineString"&&Gr.lineMetrics){for(var wo in Ea={},zn.tags)Ea[wo]=zn.tags[wo];Ea.mapbox_clip_start=ni.start/ni.size,Ea.mapbox_clip_end=ni.end/ni.size}var to={geometry:$t,type:Ei==="Polygon"||Ei==="MultiPolygon"?3:Ei==="LineString"||Ei==="MultiLineString"?2:1,tags:Ea};zn.id!==null&&(to.id=zn.id),zr.features.push(to)}}function yo(zr,zn,Un,Gr,ni,Ei){var $t=Gr*Gr;if(Gr>0&&zn.size<(ni?$t:Gr))Un.numPoints+=zn.length/3;else{for(var ta=[],Hi=0;Hi<zn.length;Hi+=3)(Gr===0||zn[Hi+2]>$t)&&(Un.numSimplified++,ta.push(zn[Hi]),ta.push(zn[Hi+1])),Un.numPoints++;ni&&function(Ai,Ea){for(var wo=0,to=0,zo=Ai.length,Po=zo-2;to<zo;Po=to,to+=2)wo+=(Ai[to]-Ai[Po])*(Ai[to+1]+Ai[Po+1]);if(wo>0===Ea)for(to=0,zo=Ai.length;to<zo/2;to+=2){var Lo=Ai[to],Wo=Ai[to+1];Ai[to]=Ai[zo-2-to],Ai[to+1]=Ai[zo-1-to],Ai[zo-2-to]=Lo,Ai[zo-1-to]=Wo}}(ta,Ei),zr.push(ta)}}function ls(zr,zn){var Un=(zn=this.options=function(ni,Ei){for(var $t in Ei)ni[$t]=Ei[$t];return ni}(Object.create(this.options),zn)).debug;if(Un&&console.time("preprocess data"),zn.maxZoom<0||zn.maxZoom>24)throw new Error("maxZoom should be in the 0-24 range");if(zn.promoteId&&zn.generateId)throw new Error("promoteId and generateId cannot be used together.");var Gr=function(ni,Ei){var $t=[];if(ni.type==="FeatureCollection")for(var ta=0;ta<ni.features.length;ta++)Ia($t,ni.features[ta],Ei,ta);else Ia($t,ni.type==="Feature"?ni:{geometry:ni},Ei);return $t}(zr,zn);this.tiles={},this.tileCoords=[],Un&&(console.timeEnd("preprocess data"),console.log("index: maxZoom: %d, maxPoints: %d",zn.indexMaxZoom,zn.indexMaxPoints),console.time("generate tiles"),this.stats={},this.total=0),(Gr=function(ni,Ei){var $t=Ei.buffer/Ei.extent,ta=ni,Hi=un(ni,1,-1-$t,$t,0,-1,2,Ei),Ai=un(ni,1,1-$t,2+$t,0,-1,2,Ei);return(Hi||Ai)&&(ta=un(ni,1,-$t,1+$t,0,-1,2,Ei)||[],Hi&&(ta=oi(Hi,1).concat(ta)),Ai&&(ta=ta.concat(oi(Ai,-1)))),ta}(Gr,zn)).length&&this.splitTile(Gr,0,0,0),Un&&(Gr.length&&console.log("features: %d, points: %d",this.tiles[0].numFeatures,this.tiles[0].numPoints),console.timeEnd("generate tiles"),console.log("tiles generated:",this.total,JSON.stringify(this.stats)))}function xo(zr,zn,Un){return 32*((1<<zr)*Un+zn)+zr}function _o(zr,zn){const Un=zr.tileID.canonical;if(!this._geoJSONIndex)return zn(null,null);const Gr=this._geoJSONIndex.getTile(Un.z,Un.x,Un.y);if(!Gr)return zn(null,null);const ni=new Ue(Gr.features);let Ei=Te(ni);Ei.byteOffset===0&&Ei.byteLength===Ei.buffer.byteLength||(Ei=new Uint8Array(Ei)),zn(null,{vectorTile:ni,rawData:Ei.buffer})}ls.prototype.options={maxZoom:14,indexMaxZoom:5,indexMaxPoints:1e5,tolerance:3,extent:4096,buffer:64,lineMetrics:!1,promoteId:null,generateId:!1,debug:0},ls.prototype.splitTile=function(zr,zn,Un,Gr,ni,Ei,$t){for(var ta=[zr,zn,Un,Gr],Hi=this.options,Ai=Hi.debug;ta.length;){Gr=ta.pop(),Un=ta.pop(),zn=ta.pop(),zr=ta.pop();var Ea=1<<zn,wo=xo(zn,Un,Gr),to=this.tiles[wo];if(!to&&(Ai>1&&console.time("creation"),to=this.tiles[wo]=Aa(zr,zn,Un,Gr,Hi),this.tileCoords.push({z:zn,x:Un,y:Gr}),Ai)){Ai>1&&(console.log("tile z%d-%d-%d (features: %d, points: %d, simplified: %d)",zn,Un,Gr,to.numFeatures,to.numPoints,to.numSimplified),console.timeEnd("creation"));var zo="z"+zn;this.stats[zo]=(this.stats[zo]||0)+1,this.total++}if(to.source=zr,ni){if(zn===Hi.maxZoom||zn===ni)continue;var Po=1<<ni-zn;if(Un!==Math.floor(Ei/Po)||Gr!==Math.floor($t/Po))continue}else if(zn===Hi.indexMaxZoom||to.numPoints<=Hi.indexMaxPoints)continue;if(to.source=null,zr.length!==0){Ai>1&&console.time("clipping");var Lo,Wo,ma,$s,ao,Ps,qo=.5*Hi.buffer/Hi.extent,wl=.5-qo,yu=.5+qo,po=1+qo;Lo=Wo=ma=$s=null,ao=un(zr,Ea,Un-qo,Un+yu,0,to.minX,to.maxX,Hi),Ps=un(zr,Ea,Un+wl,Un+po,0,to.minX,to.maxX,Hi),zr=null,ao&&(Lo=un(ao,Ea,Gr-qo,Gr+yu,1,to.minY,to.maxY,Hi),Wo=un(ao,Ea,Gr+wl,Gr+po,1,to.minY,to.maxY,Hi),ao=null),Ps&&(ma=un(Ps,Ea,Gr-qo,Gr+yu,1,to.minY,to.maxY,Hi),$s=un(Ps,Ea,Gr+wl,Gr+po,1,to.minY,to.maxY,Hi),Ps=null),Ai>1&&console.timeEnd("clipping"),ta.push(Lo||[],zn+1,2*Un,2*Gr),ta.push(Wo||[],zn+1,2*Un,2*Gr+1),ta.push(ma||[],zn+1,2*Un+1,2*Gr),ta.push($s||[],zn+1,2*Un+1,2*Gr+1)}}},ls.prototype.getTile=function(zr,zn,Un){var Gr=this.options,ni=Gr.extent,Ei=Gr.debug;if(zr<0||zr>24)return null;var $t=1<<zr,ta=xo(zr,zn=(zn%$t+$t)%$t,Un);if(this.tiles[ta])return za(this.tiles[ta],ni);Ei>1&&console.log("drilling down to z%d-%d-%d",zr,zn,Un);for(var Hi,Ai=zr,Ea=zn,wo=Un;!Hi&&Ai>0;)Ai--,Ea=Math.floor(Ea/2),wo=Math.floor(wo/2),Hi=this.tiles[xo(Ai,Ea,wo)];return Hi&&Hi.source?(Ei>1&&console.log("found parent tile z%d-%d-%d",Ai,Ea,wo),Ei>1&&console.time("drilling down"),this.splitTile(Hi.source,Ai,Ea,wo,zr,zn,Un),Ei>1&&console.timeEnd("drilling down"),this.tiles[ta]?za(this.tiles[ta],ni):null):null};class Ao extends m.VectorTileWorkerSource{constructor(zn,Un,Gr,ni,Ei){super(zn,Un,Gr,ni,_o),Ei&&(this.loadGeoJSON=Ei)}loadData(zn,Un){const Gr=zn&&zn.request,ni=Gr&&Gr.collectResourceTiming;this.loadGeoJSON(zn,(Ei,$t)=>{if(Ei||!$t)return Un(Ei);if(typeof $t!="object")return Un(new Error(`Input data given to '${zn.source}' is not a valid GeoJSON object.`));{q($t,!0);try{if(zn.filter){const Hi=m.createExpression(zn.filter,{type:"boolean","property-type":"data-driven",overridable:!1,transition:!1});if(Hi.result==="error")throw new Error(Hi.value.map(Ea=>`${Ea.key}: ${Ea.message}`).join(", "));$t={type:"FeatureCollection",features:$t.features.filter(Ea=>Hi.value.evaluate({zoom:0},Ea))}}this._geoJSONIndex=zn.cluster?new Xr(function({superclusterOptions:Hi,clusterProperties:Ai}){if(!Ai||!Hi)return Hi;const Ea={},wo={},to={accumulated:null,zoom:0},zo={properties:null},Po=Object.keys(Ai);for(const Lo of Po){const[Wo,ma]=Ai[Lo],$s=m.createExpression(ma),ao=m.createExpression(typeof Wo=="string"?[Wo,["accumulated"],["get",Lo]]:Wo);Ea[Lo]=$s.value,wo[Lo]=ao.value}return Hi.map=Lo=>{zo.properties=Lo;const Wo={};for(const ma of Po)Wo[ma]=Ea[ma].evaluate(to,zo);return Wo},Hi.reduce=(Lo,Wo)=>{zo.properties=Wo;for(const ma of Po)to.accumulated=Lo[ma],Lo[ma]=wo[ma].evaluate(to,zo)},Hi}(zn)).load($t.features):function(Hi,Ai){return new ls(Hi,Ai)}($t,zn.geojsonVtOptions)}catch(Hi){return Un(Hi)}this.loaded={};const ta={};if(ni){const Hi=m.getPerformanceMeasurement(Gr);Hi&&(ta.resourceTiming={},ta.resourceTiming[zn.source]=JSON.parse(JSON.stringify(Hi)))}Un(null,ta)}})}reloadTile(zn,Un){const Gr=this.loaded;return Gr&&Gr[zn.uid]?super.reloadTile(zn,Un):this.loadTile(zn,Un)}loadGeoJSON(zn,Un){if(zn.request)m.getJSON(zn.request,Un);else{if(typeof zn.data!="string")return Un(new Error(`Input data given to '${zn.source}' is not a valid GeoJSON object.`));try{return Un(null,JSON.parse(zn.data))}catch{return Un(new Error(`Input data given to '${zn.source}' is not a valid GeoJSON object.`))}}}getClusterExpansionZoom(zn,Un){try{Un(null,this._geoJSONIndex.getClusterExpansionZoom(zn.clusterId))}catch(Gr){Un(Gr)}}getClusterChildren(zn,Un){try{Un(null,this._geoJSONIndex.getChildren(zn.clusterId))}catch(Gr){Un(Gr)}}getClusterLeaves(zn,Un){try{Un(null,this._geoJSONIndex.getLeaves(zn.clusterId,zn.limit,zn.offset))}catch(Gr){Un(Gr)}}}class il{constructor(zn){this.self=zn,this.actor=new m.Actor(zn,this),this.layerIndexes={},this.availableImages={},this.isSpriteLoaded={},this.projections={},this.defaultProjection=m.getProjection({name:"mercator"}),this.workerSourceTypes={vector:m.VectorTileWorkerSource,geojson:Ao},this.workerSources={},this.demWorkerSources={},this.self.registerWorkerSource=(Un,Gr)=>{if(this.workerSourceTypes[Un])throw new Error(`Worker source with name "${Un}" already registered.`);this.workerSourceTypes[Un]=Gr},this.self.registerRTLTextPlugin=Un=>{if(m.plugin.isParsed())throw new Error("RTL text plugin already registered.");m.plugin.applyArabicShaping=Un.applyArabicShaping,m.plugin.processBidirectionalText=Un.processBidirectionalText,m.plugin.processStyledBidirectionalText=Un.processStyledBidirectionalText}}clearCaches(zn,Un,Gr){delete this.layerIndexes[zn],delete this.availableImages[zn],delete this.workerSources[zn],delete this.demWorkerSources[zn],Gr()}checkIfReady(zn,Un,Gr){Gr()}setReferrer(zn,Un){this.referrer=Un}spriteLoaded(zn,Un){this.isSpriteLoaded[zn]=Un;for(const Gr in this.workerSources[zn]){const ni=this.workerSources[zn][Gr];for(const Ei in ni)ni[Ei]instanceof m.VectorTileWorkerSource&&(ni[Ei].isSpriteLoaded=Un,ni[Ei].fire(new m.Event("isSpriteLoaded")))}}setImages(zn,Un,Gr){this.availableImages[zn]=Un;for(const ni in this.workerSources[zn]){const Ei=this.workerSources[zn][ni];for(const $t in Ei)Ei[$t].availableImages=Un}Gr()}enableTerrain(zn,Un,Gr){this.terrain=Un,Gr()}setProjection(zn,Un){this.projections[zn]=m.getProjection(Un)}setLayers(zn,Un,Gr){this.getLayerIndex(zn).replace(Un),Gr()}updateLayers(zn,Un,Gr){this.getLayerIndex(zn).update(Un.layers,Un.removedIds),Gr()}loadTile(zn,Un,Gr){const ni=this.enableTerrain?m.extend({enableTerrain:this.terrain},Un):Un;ni.projection=this.projections[zn]||this.defaultProjection,this.getWorkerSource(zn,Un.type,Un.source).loadTile(ni,Gr)}loadDEMTile(zn,Un,Gr){const ni=this.enableTerrain?m.extend({buildQuadTree:this.terrain},Un):Un;this.getDEMWorkerSource(zn,Un.source).loadTile(ni,Gr)}reloadTile(zn,Un,Gr){const ni=this.enableTerrain?m.extend({enableTerrain:this.terrain},Un):Un;ni.projection=this.projections[zn]||this.defaultProjection,this.getWorkerSource(zn,Un.type,Un.source).reloadTile(ni,Gr)}abortTile(zn,Un,Gr){this.getWorkerSource(zn,Un.type,Un.source).abortTile(Un,Gr)}removeTile(zn,Un,Gr){this.getWorkerSource(zn,Un.type,Un.source).removeTile(Un,Gr)}removeSource(zn,Un,Gr){if(!this.workerSources[zn]||!this.workerSources[zn][Un.type]||!this.workerSources[zn][Un.type][Un.source])return;const ni=this.workerSources[zn][Un.type][Un.source];delete this.workerSources[zn][Un.type][Un.source],ni.removeSource!==void 0?ni.removeSource(Un,Gr):Gr()}loadWorkerSource(zn,Un,Gr){try{this.self.importScripts(Un.url),Gr()}catch(ni){Gr(ni.toString())}}syncRTLPluginState(zn,Un,Gr){try{m.plugin.setState(Un);const ni=m.plugin.getPluginURL();if(m.plugin.isLoaded()&&!m.plugin.isParsed()&&ni!=null){this.self.importScripts(ni);const Ei=m.plugin.isParsed();Gr(Ei?void 0:new Error(`RTL Text Plugin failed to import scripts from ${ni}`),Ei)}}catch(ni){Gr(ni.toString())}}getAvailableImages(zn){let Un=this.availableImages[zn];return Un||(Un=[]),Un}getLayerIndex(zn){let Un=this.layerIndexes[zn];return Un||(Un=this.layerIndexes[zn]=new L),Un}getWorkerSource(zn,Un,Gr){return this.workerSources[zn]||(this.workerSources[zn]={}),this.workerSources[zn][Un]||(this.workerSources[zn][Un]={}),this.workerSources[zn][Un][Gr]||(this.workerSources[zn][Un][Gr]=new this.workerSourceTypes[Un]({send:(ni,Ei,$t,ta,Hi,Ai)=>{this.actor.send(ni,Ei,$t,zn,Hi,Ai)},scheduler:this.actor.scheduler},this.getLayerIndex(zn),this.getAvailableImages(zn),this.isSpriteLoaded[zn])),this.workerSources[zn][Un][Gr]}getDEMWorkerSource(zn,Un){return this.demWorkerSources[zn]||(this.demWorkerSources[zn]={}),this.demWorkerSources[zn][Un]||(this.demWorkerSources[zn][Un]=new G),this.demWorkerSources[zn][Un]}enforceCacheSizeLimit(zn,Un){m.enforceCacheSizeLimit(Un)}getWorkerPerformanceMetrics(zn,Un,Gr){Gr(void 0,void 0)}}return typeof WorkerGlobalScope<"u"&&typeof self<"u"&&self instanceof WorkerGlobalScope&&(self.worker=new il(self)),il}),y(["./shared"],function(m){var O=N;function N(Ee){return!function(w){return typeof window>"u"||typeof document>"u"?"not a browser":Array.prototype&&Array.prototype.every&&Array.prototype.filter&&Array.prototype.forEach&&Array.prototype.indexOf&&Array.prototype.lastIndexOf&&Array.prototype.map&&Array.prototype.some&&Array.prototype.reduce&&Array.prototype.reduceRight&&Array.isArray?Function.prototype&&Function.prototype.bind?Object.keys&&Object.create&&Object.getPrototypeOf&&Object.getOwnPropertyNames&&Object.isSealed&&Object.isFrozen&&Object.isExtensible&&Object.getOwnPropertyDescriptor&&Object.defineProperty&&Object.defineProperties&&Object.seal&&Object.freeze&&Object.preventExtensions?"JSON"in window&&"parse"in JSON&&"stringify"in JSON?function(){if(!("Worker"in window&&"Blob"in window&&"URL"in window))return!1;var it,xt,Dt=new Blob([""],{type:"text/javascript"}),Ot=URL.createObjectURL(Dt);try{xt=new Worker(Ot),it=!0}catch{it=!1}return xt&&xt.terminate(),URL.revokeObjectURL(Ot),it}()?"Uint8ClampedArray"in window?ArrayBuffer.isView?function(){var it=document.createElement("canvas");it.width=it.height=1;var xt=it.getContext("2d");if(!xt)return!1;var Dt=xt.getImageData(0,0,1,1);return Dt&&Dt.width===it.width}()?(L[se=w&&w.failIfMajorPerformanceCaveat]===void 0&&(L[se]=function(it){var xt,Dt=function(Ot){var rn=document.createElement("canvas"),Tn=Object.create(N.webGLContextAttributes);return Tn.failIfMajorPerformanceCaveat=Ot,rn.getContext("webgl2",Tn)||rn.getContext("experimental-webgl",Tn)}(it);if(!Dt)return!1;try{xt=Dt.createShader(Dt.VERTEX_SHADER)}catch{return!1}return!(!xt||Dt.isContextLost())&&(Dt.shaderSource(xt,"void main() {}"),Dt.compileShader(xt),Dt.getShaderParameter(xt,Dt.COMPILE_STATUS)===!0)}(se)),L[se]?document.documentMode?"insufficient ECMAScript 6 support":void 0:"insufficient WebGL support"):"insufficient Canvas/getImageData support":"insufficient ArrayBuffer support":"insufficient Uint8ClampedArray support":"insufficient worker support":"insufficient JSON support":"insufficient Object support":"insufficient Function support":"insufficent Array support";var se}(Ee)}var L={};function G(Ee,w){if(Array.isArray(Ee)){if(!Array.isArray(w)||Ee.length!==w.length)return!1;for(let se=0;se<Ee.length;se++)if(!G(Ee[se],w[se]))return!1;return!0}if(typeof Ee=="object"&&Ee!==null&&w!==null){if(typeof w!="object"||Object.keys(Ee).length!==Object.keys(w).length)return!1;for(const se in Ee)if(!G(Ee[se],w[se]))return!1;return!0}return Ee===w}function q(Ee,w,se){const it=m.window.document.createElement(Ee);return w!==void 0&&(it.className=w),se&&se.appendChild(it),it}function J(Ee,w,se){const it=m.window.document.createElementNS("http://www.w3.org/2000/svg",Ee);for(const xt of Object.keys(w))it.setAttributeNS(null,xt,w[xt]);return se&&se.appendChild(it),it}N.webGLContextAttributes={antialias:!1,alpha:!0,stencil:!0,depth:!0};const fe=m.window.document&&m.window.document.documentElement.style,ve=fe&&fe.userSelect!==void 0?"userSelect":"WebkitUserSelect";let ne;function Ue(){fe&&ve&&(ne=fe[ve],fe[ve]="none")}function De(){fe&&ve&&(fe[ve]=ne)}function Ve(Ee){Ee.preventDefault(),Ee.stopPropagation(),m.window.removeEventListener("click",Ve,!0)}function rt(){m.window.addEventListener("click",Ve,!0),m.window.setTimeout(()=>{m.window.removeEventListener("click",Ve,!0)},0)}function Ae(Ee,w){const se=Ee.getBoundingClientRect();return ie(Ee,se,w)}function Te(Ee,w){const se=Ee.getBoundingClientRect(),it=[];for(let xt=0;xt<w.length;xt++)it.push(ie(Ee,se,w[xt]));return it}function Xe(Ee){return m.window.InstallTrigger!==void 0&&Ee.button===2&&Ee.ctrlKey&&m.window.navigator.platform.toUpperCase().indexOf("MAC")>=0?0:Ee.button}function ie(Ee,w,se){const it=Ee.offsetWidth===w.width?1:Ee.offsetWidth/w.width;return new m.pointGeometry((se.clientX-w.left)*it,(se.clientY-w.top)*it)}function ue(Ee,w){var se=w[0],it=w[1],xt=w[2],Dt=w[3],Ot=se*Dt-xt*it;return Ot?(Ee[0]=Dt*(Ot=1/Ot),Ee[1]=-it*Ot,Ee[2]=-xt*Ot,Ee[3]=se*Ot,Ee):null}function pt(Ee){const{userImage:w}=Ee;return!!(w&&w.render&&w.render())&&(Ee.data.replace(new Uint8Array(w.data.buffer)),!0)}class mt extends m.Evented{constructor(){super(),this.images={},this.updatedImages={},this.callbackDispatchedThisFrame={},this.loaded=!1,this.requestors=[],this.patterns={},this.atlasImage=new m.RGBAImage({width:1,height:1}),this.dirty=!0}isLoaded(){return this.loaded}setLoaded(w){if(this.loaded!==w&&(this.loaded=w,w)){for(const{ids:se,callback:it}of this.requestors)this._notify(se,it);this.requestors=[]}}hasImage(w){return!!this.getImage(w)}getImage(w){return this.images[w]}addImage(w,se){this._validate(w,se)&&(this.images[w]=se)}_validate(w,se){let it=!0;return this._validateStretch(se.stretchX,se.data&&se.data.width)||(this.fire(new m.ErrorEvent(new Error(`Image "${w}" has invalid "stretchX" value`))),it=!1),this._validateStretch(se.stretchY,se.data&&se.data.height)||(this.fire(new m.ErrorEvent(new Error(`Image "${w}" has invalid "stretchY" value`))),it=!1),this._validateContent(se.content,se)||(this.fire(new m.ErrorEvent(new Error(`Image "${w}" has invalid "content" value`))),it=!1),it}_validateStretch(w,se){if(!w)return!0;let it=0;for(const xt of w){if(xt[0]<it||xt[1]<xt[0]||se<xt[1])return!1;it=xt[1]}return!0}_validateContent(w,se){return!(w&&(w.length!==4||w[0]<0||se.data.width<w[0]||w[1]<0||se.data.height<w[1]||w[2]<0||se.data.width<w[2]||w[3]<0||se.data.height<w[3]||w[2]<w[0]||w[3]<w[1]))}updateImage(w,se){se.version=this.images[w].version+1,this.images[w]=se,this.updatedImages[w]=!0}removeImage(w){const se=this.images[w];delete this.images[w],delete this.patterns[w],se.userImage&&se.userImage.onRemove&&se.userImage.onRemove()}listImages(){return Object.keys(this.images)}getImages(w,se){let it=!0;if(!this.isLoaded())for(const xt of w)this.images[xt]||(it=!1);this.isLoaded()||it?this._notify(w,se):this.requestors.push({ids:w,callback:se})}_notify(w,se){const it={};for(const xt of w){this.images[xt]||this.fire(new m.Event("styleimagemissing",{id:xt}));const Dt=this.images[xt];Dt?it[xt]={data:Dt.data.clone(),pixelRatio:Dt.pixelRatio,sdf:Dt.sdf,version:Dt.version,stretchX:Dt.stretchX,stretchY:Dt.stretchY,content:Dt.content,hasRenderCallback:!!(Dt.userImage&&Dt.userImage.render)}:m.warnOnce(`Image "${xt}" could not be loaded. Please make sure you have added the image with map.addImage() or a "sprite" property in your style. You can provide missing images by listening for the "styleimagemissing" map event.`)}se(null,it)}getPixelSize(){const{width:w,height:se}=this.atlasImage;return{width:w,height:se}}getPattern(w){const se=this.patterns[w],it=this.getImage(w);if(!it)return null;if(se&&se.position.version===it.version)return se.position;if(se)se.position.version=it.version;else{const xt={w:it.data.width+2,h:it.data.height+2,x:0,y:0},Dt=new m.ImagePosition(xt,it);this.patterns[w]={bin:xt,position:Dt}}return this._updatePatternAtlas(),this.patterns[w].position}bind(w){const se=w.gl;this.atlasTexture?this.dirty&&(this.atlasTexture.update(this.atlasImage),this.dirty=!1):this.atlasTexture=new m.Texture(w,this.atlasImage,se.RGBA),this.atlasTexture.bind(se.LINEAR,se.CLAMP_TO_EDGE)}_updatePatternAtlas(){const w=[];for(const Dt in this.patterns)w.push(this.patterns[Dt].bin);const{w:se,h:it}=m.potpack(w),xt=this.atlasImage;xt.resize({width:se||1,height:it||1});for(const Dt in this.patterns){const{bin:Ot}=this.patterns[Dt],rn=Ot.x+1,Tn=Ot.y+1,kn=this.images[Dt].data,Bn=kn.width,Wn=kn.height;m.RGBAImage.copy(kn,xt,{x:0,y:0},{x:rn,y:Tn},{width:Bn,height:Wn}),m.RGBAImage.copy(kn,xt,{x:0,y:Wn-1},{x:rn,y:Tn-1},{width:Bn,height:1}),m.RGBAImage.copy(kn,xt,{x:0,y:0},{x:rn,y:Tn+Wn},{width:Bn,height:1}),m.RGBAImage.copy(kn,xt,{x:Bn-1,y:0},{x:rn-1,y:Tn},{width:1,height:Wn}),m.RGBAImage.copy(kn,xt,{x:0,y:0},{x:rn+Bn,y:Tn},{width:1,height:Wn})}this.dirty=!0}beginFrame(){this.callbackDispatchedThisFrame={}}dispatchRenderCallbacks(w){for(const se of w){if(this.callbackDispatchedThisFrame[se])continue;this.callbackDispatchedThisFrame[se]=!0;const it=this.images[se];pt(it)&&this.updateImage(se,it)}}}const Tt=new m.Properties({anchor:new m.DataConstantProperty(m.spec.light.anchor),position:new class{constructor(){this.specification=m.spec.light.position}possiblyEvaluate(Ee,w){return function([se,it,xt]){const Dt=m.degToRad(it+90),Ot=m.degToRad(xt);return{x:se*Math.cos(Dt)*Math.sin(Ot),y:se*Math.sin(Dt)*Math.sin(Ot),z:se*Math.cos(Ot),azimuthal:it,polar:xt}}(Ee.expression.evaluate(w))}interpolate(Ee,w,se){return{x:m.number(Ee.x,w.x,se),y:m.number(Ee.y,w.y,se),z:m.number(Ee.z,w.z,se),azimuthal:m.number(Ee.azimuthal,w.azimuthal,se),polar:m.number(Ee.polar,w.polar,se)}}},color:new m.DataConstantProperty(m.spec.light.color),intensity:new m.DataConstantProperty(m.spec.light.intensity)}),kt="-transition";class It extends m.Evented{constructor(w){super(),this._transitionable=new m.Transitionable(Tt),this.setLight(w),this._transitioning=this._transitionable.untransitioned()}getLight(){return this._transitionable.serialize()}setLight(w,se={}){if(!this._validate(m.validateLight,w,se))for(const it in w){const xt=w[it];m.endsWith(it,kt)?this._transitionable.setTransition(it.slice(0,-kt.length),xt):this._transitionable.setValue(it,xt)}}updateTransitions(w){this._transitioning=this._transitionable.transitioned(w,this._transitioning)}hasTransition(){return this._transitioning.hasTransition()}recalculate(w){this.properties=this._transitioning.possiblyEvaluate(w)}_validate(w,se,it){return(!it||it.validate!==!1)&&m.emitValidationErrors(this,w.call(m.validateStyle,m.extend({value:se,style:{glyphs:!0,sprite:!0},styleSpec:m.spec})))}}const nn=new m.Properties({source:new m.DataConstantProperty(m.spec.terrain.source),exaggeration:new m.DataConstantProperty(m.spec.terrain.exaggeration)}),tn="-transition";class pn extends m.Evented{constructor(w,se){super(),this._transitionable=new m.Transitionable(nn),this.set(w),this._transitioning=this._transitionable.untransitioned(),this.drapeRenderMode=se}get(){return this._transitionable.serialize()}set(w){for(const se in w){const it=w[se];m.endsWith(se,tn)?this._transitionable.setTransition(se.slice(0,-tn.length),it):this._transitionable.setValue(se,it)}}updateTransitions(w){this._transitioning=this._transitionable.transitioned(w,this._transitioning)}hasTransition(){return this._transitioning.hasTransition()}recalculate(w){this.properties=this._transitioning.possiblyEvaluate(w)}}function _n(Ee,w,se,it){const xt=m.smoothstep(45,65,se),[Dt,Ot]=Dn(Ee,it),rn=m.length(w);let Tn=1-Math.min(1,Math.exp((rn-Dt)/(Ot-Dt)*-6));return Tn*=Tn*Tn,Tn=Math.min(1,1.00747*Tn),Tn*xt*Ee.alpha}function Dn(Ee,w){const se=.5/Math.tan(.5*w);return[Ee.range[0]+se,Ee.range[1]+se]}const an=new m.Properties({range:new m.DataConstantProperty(m.spec.fog.range),color:new m.DataConstantProperty(m.spec.fog.color),"horizon-blend":new m.DataConstantProperty(m.spec.fog["horizon-blend"])}),Rn="-transition";class Lt extends m.Evented{constructor(w,se){super(),this._transitionable=new m.Transitionable(an),this.set(w),this._transitioning=this._transitionable.untransitioned(),this._transform=se}get state(){return{range:this.properties.get("range"),horizonBlend:this.properties.get("horizon-blend"),alpha:this.properties.get("color").a}}get(){return this._transitionable.serialize()}set(w,se={}){if(!this._validate(m.validateFog,w,se))for(const it in w){const xt=w[it];m.endsWith(it,Rn)?this._transitionable.setTransition(it.slice(0,-Rn.length),xt):this._transitionable.setValue(it,xt)}}getOpacity(w){if(!this._transform.projection.supportsFog)return 0;const se=this.properties&&this.properties.get("color")||1;return m.smoothstep(45,65,w)*se.a}getOpacityAtLatLng(w,se){return this._transform.projection.supportsFog?function(it,xt,Dt){const Ot=m.MercatorCoordinate.fromLngLat(xt),rn=Dt.elevation?Dt.elevation.getAtPointOrZero(Ot):0,Tn=[Ot.x,Ot.y,rn];return m.transformMat4(Tn,Tn,Dt.mercatorFogMatrix),_n(it,Tn,Dt.pitch,Dt._fov)}(this.state,w,se):0}getFovAdjustedRange(w){return this._transform.projection.supportsFog?Dn(this.state,w):[0,1]}updateTransitions(w){this._transitioning=this._transitionable.transitioned(w,this._transitioning)}hasTransition(){return this._transitioning.hasTransition()}recalculate(w){this.properties=this._transitioning.possiblyEvaluate(w)}_validate(w,se,it){return(!it||it.validate!==!1)&&m.emitValidationErrors(this,w.call(m.validateStyle,m.extend({value:se,style:{glyphs:!0,sprite:!0},styleSpec:m.spec})))}}class wn{constructor(w,se){this.workerPool=w,this.actors=[],this.currentActor=0,this.id=m.uniqueId();const it=this.workerPool.acquire(this.id);for(let xt=0;xt<it.length;xt++){const Dt=new wn.Actor(it[xt],se,this.id);Dt.name=`Worker ${xt}`,this.actors.push(Dt)}this.ready=!1,this.broadcast("checkIfReady",null,()=>{this.ready=!0})}broadcast(w,se,it){m.asyncAll(this.actors,(xt,Dt)=>{xt.send(w,se,Dt)},it=it||function(){})}getActor(){return this.currentActor=(this.currentActor+1)%this.actors.length,this.actors[this.currentActor]}remove(){this.actors.forEach(w=>{w.remove()}),this.actors=[],this.workerPool.release(this.id)}}function hn(Ee,w,se){return w*(m.EXTENT/(Ee.tileSize*Math.pow(2,se-Ee.tileID.overscaledZ)))}wn.Actor=m.Actor;class xn{constructor(w,se,it,xt){this.screenBounds=w,this.cameraPoint=se,this._screenRaycastCache={},this._cameraRaycastCache={},this.isAboveHorizon=it,this.screenGeometry=this.bufferedScreenGeometry(0),this.screenGeometryMercator=this.screenGeometry.map(Dt=>xt.pointCoordinate3D(Dt)),this.cameraGeometry=this.bufferedCameraGeometry(0)}static createFromScreenPoints(w,se){let it,xt;if(w instanceof m.pointGeometry||typeof w[0]=="number"){const Dt=m.pointGeometry.convert(w);it=[m.pointGeometry.convert(w)],xt=se.isPointAboveHorizon(Dt)}else{const Dt=m.pointGeometry.convert(w[0]),Ot=m.pointGeometry.convert(w[1]);it=[Dt,Ot],xt=m.polygonizeBounds(Dt,Ot).every(rn=>se.isPointAboveHorizon(rn))}return new xn(it,se.getCameraPoint(),xt,se)}isPointQuery(){return this.screenBounds.length===1}bufferedScreenGeometry(w){return m.polygonizeBounds(this.screenBounds[0],this.screenBounds.length===1?this.screenBounds[0]:this.screenBounds[1],w)}bufferedCameraGeometry(w){const se=this.screenBounds[0],it=this.screenBounds.length===1?this.screenBounds[0].add(new m.pointGeometry(1,1)):this.screenBounds[1],xt=m.polygonizeBounds(se,it,0,!1);return this.cameraPoint.y>it.y&&(this.cameraPoint.x>se.x&&this.cameraPoint.x<it.x?xt.splice(3,0,this.cameraPoint):this.cameraPoint.x>=it.x?xt[2]=this.cameraPoint:this.cameraPoint.x<=se.x&&(xt[3]=this.cameraPoint)),m.bufferConvexPolygon(xt,w)}containsTile(w,se,it){const xt=w.queryPadding+1,Dt=w.tileID.wrap,Ot=it?this._bufferedCameraMercator(xt,se).map(Zr=>m.getTilePoint(w.tileTransform,Zr,Dt)):this._bufferedScreenMercator(xt,se).map(Zr=>m.getTilePoint(w.tileTransform,Zr,Dt)),rn=this.screenGeometryMercator.map(Zr=>m.getTileVec3(w.tileTransform,Zr,Dt)),Tn=rn.map(Zr=>new m.pointGeometry(Zr[0],Zr[1])),kn=se.getFreeCameraOptions().position||new m.MercatorCoordinate(0,0,0),Bn=m.getTileVec3(w.tileTransform,kn,Dt),Wn=rn.map(Zr=>{const Sr=m.sub(Zr,Zr,Bn);return m.normalize(Sr,Sr),new m.Ray(Bn,Sr)}),Fr=hn(w,1,se.zoom);if(m.polygonIntersectsBox(Ot,0,0,m.EXTENT,m.EXTENT))return{queryGeometry:this,tilespaceGeometry:Tn,tilespaceRays:Wn,bufferedTilespaceGeometry:Ot,bufferedTilespaceBounds:(ri=m.getBounds(Ot),ri.min.x=m.clamp(ri.min.x,0,m.EXTENT),ri.min.y=m.clamp(ri.min.y,0,m.EXTENT),ri.max.x=m.clamp(ri.max.x,0,m.EXTENT),ri.max.y=m.clamp(ri.max.y,0,m.EXTENT),ri),tile:w,tileID:w.tileID,pixelToTileUnitsFactor:Fr};var ri}_bufferedScreenMercator(w,se){const it=$n(w);if(this._screenRaycastCache[it])return this._screenRaycastCache[it];{const xt=this.bufferedScreenGeometry(w).map(Dt=>se.pointCoordinate3D(Dt));return this._screenRaycastCache[it]=xt,xt}}_bufferedCameraMercator(w,se){const it=$n(w);if(this._cameraRaycastCache[it])return this._cameraRaycastCache[it];{const xt=this.bufferedCameraGeometry(w).map(Dt=>se.pointCoordinate3D(Dt));return this._cameraRaycastCache[it]=xt,xt}}}function $n(Ee){return 100*Ee|0}function Xr(Ee,w,se){const it=function(xt,Dt){if(xt)return se(xt);if(Dt){const Ot=m.pick(m.extend(Dt,Ee),["tiles","minzoom","maxzoom","attribution","mapbox_logo","bounds","scheme","tileSize","encoding"]);Dt.vector_layers&&(Ot.vectorLayers=Dt.vector_layers,Ot.vectorLayerIds=Ot.vectorLayers.map(rn=>rn.id)),Ot.tiles=w.canonicalizeTileset(Ot,Ee.url),se(null,Ot)}};return Ee.url?m.getJSON(w.transformRequest(w.normalizeSourceURL(Ee.url),m.ResourceType.Source),it):m.exported.frame(()=>it(null,Ee))}class ti{constructor(w,se,it){this.bounds=m.LngLatBounds.convert(this.validateBounds(w)),this.minzoom=se||0,this.maxzoom=it||24}validateBounds(w){return Array.isArray(w)&&w.length===4?[Math.max(-180,w[0]),Math.max(-90,w[1]),Math.min(180,w[2]),Math.min(90,w[3])]:[-180,-90,180,90]}contains(w){const se=Math.pow(2,w.z),it=Math.floor(m.mercatorXfromLng(this.bounds.getWest())*se),xt=Math.floor(m.mercatorYfromLat(this.bounds.getNorth())*se),Dt=Math.ceil(m.mercatorXfromLng(this.bounds.getEast())*se),Ot=Math.ceil(m.mercatorYfromLat(this.bounds.getSouth())*se);return w.x>=it&&w.x<Dt&&w.y>=xt&&w.y<Ot}}class gn{constructor(w,se,it){this.context=w;const xt=w.gl;this.buffer=xt.createBuffer(),this.dynamicDraw=!!it,this.context.unbindVAO(),w.bindElementBuffer.set(this.buffer),xt.bufferData(xt.ELEMENT_ARRAY_BUFFER,se.arrayBuffer,this.dynamicDraw?xt.DYNAMIC_DRAW:xt.STATIC_DRAW),this.dynamicDraw||se.destroy()}bind(){this.context.bindElementBuffer.set(this.buffer)}updateData(w){const se=this.context.gl;this.context.unbindVAO(),this.bind(),se.bufferSubData(se.ELEMENT_ARRAY_BUFFER,0,w.arrayBuffer)}destroy(){this.buffer&&(this.context.gl.deleteBuffer(this.buffer),delete this.buffer)}}const Xn={Int8:"BYTE",Uint8:"UNSIGNED_BYTE",Int16:"SHORT",Uint16:"UNSIGNED_SHORT",Int32:"INT",Uint32:"UNSIGNED_INT",Float32:"FLOAT"};class Kn{constructor(w,se,it,xt){this.length=se.length,this.attributes=it,this.itemSize=se.bytesPerElement,this.dynamicDraw=xt,this.context=w;const Dt=w.gl;this.buffer=Dt.createBuffer(),w.bindVertexBuffer.set(this.buffer),Dt.bufferData(Dt.ARRAY_BUFFER,se.arrayBuffer,this.dynamicDraw?Dt.DYNAMIC_DRAW:Dt.STATIC_DRAW),this.dynamicDraw||se.destroy()}bind(){this.context.bindVertexBuffer.set(this.buffer)}updateData(w){const se=this.context.gl;this.bind(),se.bufferSubData(se.ARRAY_BUFFER,0,w.arrayBuffer)}enableAttributes(w,se){for(let it=0;it<this.attributes.length;it++){const xt=se.attributes[this.attributes[it].name];xt!==void 0&&w.enableVertexAttribArray(xt)}}setVertexAttribPointers(w,se,it){for(let xt=0;xt<this.attributes.length;xt++){const Dt=this.attributes[xt],Ot=se.attributes[Dt.name];Ot!==void 0&&w.vertexAttribPointer(Ot,Dt.components,w[Xn[Dt.type]],!1,this.itemSize,Dt.offset+this.itemSize*(it||0))}}destroy(){this.buffer&&(this.context.gl.deleteBuffer(this.buffer),delete this.buffer)}}class Vn{constructor(w){this.gl=w.gl,this.default=this.getDefault(),this.current=this.default,this.dirty=!1}get(){return this.current}set(w){}getDefault(){return this.default}setDefault(){this.set(this.default)}}class Yn extends Vn{getDefault(){return m.Color.transparent}set(w){const se=this.current;(w.r!==se.r||w.g!==se.g||w.b!==se.b||w.a!==se.a||this.dirty)&&(this.gl.clearColor(w.r,w.g,w.b,w.a),this.current=w,this.dirty=!1)}}class Vr extends Vn{getDefault(){return 1}set(w){(w!==this.current||this.dirty)&&(this.gl.clearDepth(w),this.current=w,this.dirty=!1)}}class xi extends Vn{getDefault(){return 0}set(w){(w!==this.current||this.dirty)&&(this.gl.clearStencil(w),this.current=w,this.dirty=!1)}}class Si extends Vn{getDefault(){return[!0,!0,!0,!0]}set(w){const se=this.current;(w[0]!==se[0]||w[1]!==se[1]||w[2]!==se[2]||w[3]!==se[3]||this.dirty)&&(this.gl.colorMask(w[0],w[1],w[2],w[3]),this.current=w,this.dirty=!1)}}class qn extends Vn{getDefault(){return!0}set(w){(w!==this.current||this.dirty)&&(this.gl.depthMask(w),this.current=w,this.dirty=!1)}}class ia extends Vn{getDefault(){return 255}set(w){(w!==this.current||this.dirty)&&(this.gl.stencilMask(w),this.current=w,this.dirty=!1)}}class Wi extends Vn{getDefault(){return{func:this.gl.ALWAYS,ref:0,mask:255}}set(w){const se=this.current;(w.func!==se.func||w.ref!==se.ref||w.mask!==se.mask||this.dirty)&&(this.gl.stencilFunc(w.func,w.ref,w.mask),this.current=w,this.dirty=!1)}}class ha extends Vn{getDefault(){const w=this.gl;return[w.KEEP,w.KEEP,w.KEEP]}set(w){const se=this.current;(w[0]!==se[0]||w[1]!==se[1]||w[2]!==se[2]||this.dirty)&&(this.gl.stencilOp(w[0],w[1],w[2]),this.current=w,this.dirty=!1)}}class ai extends Vn{getDefault(){return!1}set(w){if(w===this.current&&!this.dirty)return;const se=this.gl;w?se.enable(se.STENCIL_TEST):se.disable(se.STENCIL_TEST),this.current=w,this.dirty=!1}}class Ia extends Vn{getDefault(){return[0,1]}set(w){const se=this.current;(w[0]!==se[0]||w[1]!==se[1]||this.dirty)&&(this.gl.depthRange(w[0],w[1]),this.current=w,this.dirty=!1)}}class fi extends Vn{getDefault(){return!1}set(w){if(w===this.current&&!this.dirty)return;const se=this.gl;w?se.enable(se.DEPTH_TEST):se.disable(se.DEPTH_TEST),this.current=w,this.dirty=!1}}class An extends Vn{getDefault(){return this.gl.LESS}set(w){(w!==this.current||this.dirty)&&(this.gl.depthFunc(w),this.current=w,this.dirty=!1)}}class sa extends Vn{getDefault(){return!1}set(w){if(w===this.current&&!this.dirty)return;const se=this.gl;w?se.enable(se.BLEND):se.disable(se.BLEND),this.current=w,this.dirty=!1}}class Nn extends Vn{getDefault(){const w=this.gl;return[w.ONE,w.ZERO]}set(w){const se=this.current;(w[0]!==se[0]||w[1]!==se[1]||this.dirty)&&(this.gl.blendFunc(w[0],w[1]),this.current=w,this.dirty=!1)}}class fn extends Vn{getDefault(){return m.Color.transparent}set(w){const se=this.current;(w.r!==se.r||w.g!==se.g||w.b!==se.b||w.a!==se.a||this.dirty)&&(this.gl.blendColor(w.r,w.g,w.b,w.a),this.current=w,this.dirty=!1)}}class un extends Vn{getDefault(){return this.gl.FUNC_ADD}set(w){(w!==this.current||this.dirty)&&(this.gl.blendEquation(w),this.current=w,this.dirty=!1)}}class Ln extends Vn{getDefault(){return!1}set(w){if(w===this.current&&!this.dirty)return;const se=this.gl;w?se.enable(se.CULL_FACE):se.disable(se.CULL_FACE),this.current=w,this.dirty=!1}}class hr extends Vn{getDefault(){return this.gl.BACK}set(w){(w!==this.current||this.dirty)&&(this.gl.cullFace(w),this.current=w,this.dirty=!1)}}class hi extends Vn{getDefault(){return this.gl.CCW}set(w){(w!==this.current||this.dirty)&&(this.gl.frontFace(w),this.current=w,this.dirty=!1)}}class bi extends Vn{getDefault(){return null}set(w){(w!==this.current||this.dirty)&&(this.gl.useProgram(w),this.current=w,this.dirty=!1)}}class Ra extends Vn{getDefault(){return this.gl.TEXTURE0}set(w){(w!==this.current||this.dirty)&&(this.gl.activeTexture(w),this.current=w,this.dirty=!1)}}class so extends Vn{getDefault(){const w=this.gl;return[0,0,w.drawingBufferWidth,w.drawingBufferHeight]}set(w){const se=this.current;(w[0]!==se[0]||w[1]!==se[1]||w[2]!==se[2]||w[3]!==se[3]||this.dirty)&&(this.gl.viewport(w[0],w[1],w[2],w[3]),this.current=w,this.dirty=!1)}}class Pi extends Vn{getDefault(){return null}set(w){if(w===this.current&&!this.dirty)return;const se=this.gl;se.bindFramebuffer(se.FRAMEBUFFER,w),this.current=w,this.dirty=!1}}class oi extends Vn{getDefault(){return null}set(w){if(w===this.current&&!this.dirty)return;const se=this.gl;se.bindRenderbuffer(se.RENDERBUFFER,w),this.current=w,this.dirty=!1}}class Ni extends Vn{getDefault(){return null}set(w){if(w===this.current&&!this.dirty)return;const se=this.gl;se.bindTexture(se.TEXTURE_2D,w),this.current=w,this.dirty=!1}}class za extends Vn{getDefault(){return null}set(w){if(w===this.current&&!this.dirty)return;const se=this.gl;se.bindBuffer(se.ARRAY_BUFFER,w),this.current=w,this.dirty=!1}}class ki extends Vn{getDefault(){return null}set(w){const se=this.gl;se.bindBuffer(se.ELEMENT_ARRAY_BUFFER,w),this.current=w,this.dirty=!1}}class Aa extends Vn{constructor(w){super(w),this.vao=w.extVertexArrayObject}getDefault(){return null}set(w){this.vao&&(w!==this.current||this.dirty)&&(this.vao.bindVertexArrayOES(w),this.current=w,this.dirty=!1)}}class Ja extends Vn{getDefault(){return 4}set(w){if(w===this.current&&!this.dirty)return;const se=this.gl;se.pixelStorei(se.UNPACK_ALIGNMENT,w),this.current=w,this.dirty=!1}}class yo extends Vn{getDefault(){return!1}set(w){if(w===this.current&&!this.dirty)return;const se=this.gl;se.pixelStorei(se.UNPACK_PREMULTIPLY_ALPHA_WEBGL,w),this.current=w,this.dirty=!1}}class ls extends Vn{getDefault(){return!1}set(w){if(w===this.current&&!this.dirty)return;const se=this.gl;se.pixelStorei(se.UNPACK_FLIP_Y_WEBGL,w),this.current=w,this.dirty=!1}}class xo extends Vn{constructor(w,se){super(w),this.context=w,this.parent=se}getDefault(){return null}}class _o extends xo{setDirty(){this.dirty=!0}set(w){if(w===this.current&&!this.dirty)return;this.context.bindFramebuffer.set(this.parent);const se=this.gl;se.framebufferTexture2D(se.FRAMEBUFFER,se.COLOR_ATTACHMENT0,se.TEXTURE_2D,w,0),this.current=w,this.dirty=!1}}class Ao extends xo{attachment(){return this.gl.DEPTH_ATTACHMENT}set(w){if(w===this.current&&!this.dirty)return;this.context.bindFramebuffer.set(this.parent);const se=this.gl;se.framebufferRenderbuffer(se.FRAMEBUFFER,this.attachment(),se.RENDERBUFFER,w),this.current=w,this.dirty=!1}}class il extends Ao{attachment(){return this.gl.DEPTH_STENCIL_ATTACHMENT}}class zr{constructor(w,se,it,xt){this.context=w,this.width=se,this.height=it;const Dt=this.framebuffer=w.gl.createFramebuffer();this.colorAttachment=new _o(w,Dt),xt&&(this.depthAttachment=new Ao(w,Dt))}destroy(){const w=this.context.gl,se=this.colorAttachment.get();if(se&&w.deleteTexture(se),this.depthAttachment){const it=this.depthAttachment.get();it&&w.deleteRenderbuffer(it)}w.deleteFramebuffer(this.framebuffer)}}class zn{constructor(w){this.gl=w,this.extVertexArrayObject=this.gl.getExtension("OES_vertex_array_object"),this.clearColor=new Yn(this),this.clearDepth=new Vr(this),this.clearStencil=new xi(this),this.colorMask=new Si(this),this.depthMask=new qn(this),this.stencilMask=new ia(this),this.stencilFunc=new Wi(this),this.stencilOp=new ha(this),this.stencilTest=new ai(this),this.depthRange=new Ia(this),this.depthTest=new fi(this),this.depthFunc=new An(this),this.blend=new sa(this),this.blendFunc=new Nn(this),this.blendColor=new fn(this),this.blendEquation=new un(this),this.cullFace=new Ln(this),this.cullFaceSide=new hr(this),this.frontFace=new hi(this),this.program=new bi(this),this.activeTexture=new Ra(this),this.viewport=new so(this),this.bindFramebuffer=new Pi(this),this.bindRenderbuffer=new oi(this),this.bindTexture=new Ni(this),this.bindVertexBuffer=new za(this),this.bindElementBuffer=new ki(this),this.bindVertexArrayOES=this.extVertexArrayObject&&new Aa(this),this.pixelStoreUnpack=new Ja(this),this.pixelStoreUnpackPremultiplyAlpha=new yo(this),this.pixelStoreUnpackFlipY=new ls(this),this.extTextureFilterAnisotropic=w.getExtension("EXT_texture_filter_anisotropic")||w.getExtension("MOZ_EXT_texture_filter_anisotropic")||w.getExtension("WEBKIT_EXT_texture_filter_anisotropic"),this.extTextureFilterAnisotropic&&(this.extTextureFilterAnisotropicMax=w.getParameter(this.extTextureFilterAnisotropic.MAX_TEXTURE_MAX_ANISOTROPY_EXT)),this.extTextureFilterAnisotropicForceOff=!1,this.extTextureHalfFloat=w.getExtension("OES_texture_half_float"),this.extTextureHalfFloat&&(w.getExtension("OES_texture_half_float_linear"),this.extRenderToTextureHalfFloat=w.getExtension("EXT_color_buffer_half_float")),this.extTimerQuery=w.getExtension("EXT_disjoint_timer_query"),this.maxTextureSize=w.getParameter(w.MAX_TEXTURE_SIZE)}setDefault(){this.unbindVAO(),this.clearColor.setDefault(),this.clearDepth.setDefault(),this.clearStencil.setDefault(),this.colorMask.setDefault(),this.depthMask.setDefault(),this.stencilMask.setDefault(),this.stencilFunc.setDefault(),this.stencilOp.setDefault(),this.stencilTest.setDefault(),this.depthRange.setDefault(),this.depthTest.setDefault(),this.depthFunc.setDefault(),this.blend.setDefault(),this.blendFunc.setDefault(),this.blendColor.setDefault(),this.blendEquation.setDefault(),this.cullFace.setDefault(),this.cullFaceSide.setDefault(),this.frontFace.setDefault(),this.program.setDefault(),this.activeTexture.setDefault(),this.bindFramebuffer.setDefault(),this.pixelStoreUnpack.setDefault(),this.pixelStoreUnpackPremultiplyAlpha.setDefault(),this.pixelStoreUnpackFlipY.setDefault()}setDirty(){this.clearColor.dirty=!0,this.clearDepth.dirty=!0,this.clearStencil.dirty=!0,this.colorMask.dirty=!0,this.depthMask.dirty=!0,this.stencilMask.dirty=!0,this.stencilFunc.dirty=!0,this.stencilOp.dirty=!0,this.stencilTest.dirty=!0,this.depthRange.dirty=!0,this.depthTest.dirty=!0,this.depthFunc.dirty=!0,this.blend.dirty=!0,this.blendFunc.dirty=!0,this.blendColor.dirty=!0,this.blendEquation.dirty=!0,this.cullFace.dirty=!0,this.cullFaceSide.dirty=!0,this.frontFace.dirty=!0,this.program.dirty=!0,this.activeTexture.dirty=!0,this.viewport.dirty=!0,this.bindFramebuffer.dirty=!0,this.bindRenderbuffer.dirty=!0,this.bindTexture.dirty=!0,this.bindVertexBuffer.dirty=!0,this.bindElementBuffer.dirty=!0,this.extVertexArrayObject&&(this.bindVertexArrayOES.dirty=!0),this.pixelStoreUnpack.dirty=!0,this.pixelStoreUnpackPremultiplyAlpha.dirty=!0,this.pixelStoreUnpackFlipY.dirty=!0}createIndexBuffer(w,se){return new gn(this,w,se)}createVertexBuffer(w,se,it){return new Kn(this,w,se,it)}createRenderbuffer(w,se,it){const xt=this.gl,Dt=xt.createRenderbuffer();return this.bindRenderbuffer.set(Dt),xt.renderbufferStorage(xt.RENDERBUFFER,w,se,it),this.bindRenderbuffer.set(null),Dt}createFramebuffer(w,se,it){return new zr(this,w,se,it)}clear({color:w,depth:se,stencil:it}){const xt=this.gl;let Dt=0;w&&(Dt|=xt.COLOR_BUFFER_BIT,this.clearColor.set(w),this.colorMask.set([!0,!0,!0,!0])),se!==void 0&&(Dt|=xt.DEPTH_BUFFER_BIT,this.depthRange.set([0,1]),this.clearDepth.set(se),this.depthMask.set(!0)),it!==void 0&&(Dt|=xt.STENCIL_BUFFER_BIT,this.clearStencil.set(it),this.stencilMask.set(255)),xt.clear(Dt)}setCullFace(w){w.enable===!1?this.cullFace.set(!1):(this.cullFace.set(!0),this.cullFaceSide.set(w.mode),this.frontFace.set(w.frontFace))}setDepthMode(w){w.func!==this.gl.ALWAYS||w.mask?(this.depthTest.set(!0),this.depthFunc.set(w.func),this.depthMask.set(w.mask),this.depthRange.set(w.range)):this.depthTest.set(!1)}setStencilMode(w){w.test.func!==this.gl.ALWAYS||w.mask?(this.stencilTest.set(!0),this.stencilMask.set(w.mask),this.stencilOp.set([w.fail,w.depthFail,w.pass]),this.stencilFunc.set({func:w.test.func,ref:w.ref,mask:w.test.mask})):this.stencilTest.set(!1)}setColorMode(w){G(w.blendFunction,m.ColorMode.Replace)?this.blend.set(!1):(this.blend.set(!0),this.blendFunc.set(w.blendFunction),this.blendColor.set(w.blendColor)),this.colorMask.set(w.mask)}unbindVAO(){this.extVertexArrayObject&&this.bindVertexArrayOES.set(null)}}class Un extends m.Evented{constructor(w,se,it,xt){super(),this.id=w,this.dispatcher=it,this.setEventedParent(xt),this.type="raster",this.minzoom=0,this.maxzoom=22,this.roundZoom=!0,this.scheme="xyz",this.tileSize=512,this._loaded=!1,this._options=m.extend({type:"raster"},se),m.extend(this,m.pick(se,["url","scheme","tileSize"]))}load(){this._loaded=!1,this.fire(new m.Event("dataloading",{dataType:"source"})),this._tileJSONRequest=Xr(this._options,this.map._requestManager,(w,se)=>{this._tileJSONRequest=null,this._loaded=!0,w?this.fire(new m.ErrorEvent(w)):se&&(m.extend(this,se),se.bounds&&(this.tileBounds=new ti(se.bounds,this.minzoom,this.maxzoom)),m.postTurnstileEvent(se.tiles),this.fire(new m.Event("data",{dataType:"source",sourceDataType:"metadata"})),this.fire(new m.Event("data",{dataType:"source",sourceDataType:"content"})))})}loaded(){return this._loaded}onAdd(w){this.map=w,this.load()}onRemove(){this._tileJSONRequest&&(this._tileJSONRequest.cancel(),this._tileJSONRequest=null)}serialize(){return m.extend({},this._options)}hasTile(w){return!this.tileBounds||this.tileBounds.contains(w.canonical)}loadTile(w,se){const it=m.exported.devicePixelRatio>=2,xt=this.map._requestManager.normalizeTileURL(w.tileID.canonical.url(this.tiles,this.scheme),it,this.tileSize);w.request=m.getImage(this.map._requestManager.transformRequest(xt,m.ResourceType.Tile),(Dt,Ot,rn,Tn)=>(delete w.request,w.aborted?(w.state="unloaded",se(null)):Dt?(w.state="errored",se(Dt)):Ot?(this.map._refreshExpiredTiles&&w.setExpiryData({cacheControl:rn,expires:Tn}),w.setTexture(Ot,this.map.painter),w.state="loaded",m.cacheEntryPossiblyAdded(this.dispatcher),void se(null)):se(null)))}static loadTileData(w,se,it){w.setTexture(se,it)}static unloadTileData(w,se){w.texture&&se.saveTileTexture(w.texture)}abortTile(w,se){w.request&&(w.request.cancel(),delete w.request),se()}unloadTile(w,se){w.texture&&this.map.painter.saveTileTexture(w.texture),se()}hasTransition(){return!1}}let Gr;function ni(Ee,w,se,it,xt,Dt,Ot,rn){const Tn=[Ee,se,xt,w,it,Dt,1,1,1],kn=[Ot,rn,1],Bn=m.adjoint([],Tn),[Wn,Fr,ri]=m.transformMat3(kn,kn,m.transpose(Bn,Bn));return m.multiply(Tn,[Wn,0,0,0,Fr,0,0,0,ri],Tn)}class Ei extends m.Evented{constructor(w,se,it,xt){super(),this.id=w,this.dispatcher=it,this.coordinates=se.coordinates,this.type="image",this.minzoom=0,this.maxzoom=22,this.tileSize=512,this.tiles={},this._loaded=!1,this.setEventedParent(xt),this.options=se}load(w){this._loaded=!1,this.fire(new m.Event("dataloading",{dataType:"source"})),this.url=this.options.url,m.getImage(this.map._requestManager.transformRequest(this.url,m.ResourceType.Image),(se,it)=>{if(this._loaded=!0,se)this.fire(new m.ErrorEvent(se));else if(it){const{HTMLImageElement:xt}=m.window;this.image=it instanceof xt?m.exported.getImageData(it):it,this.width=this.image.width,this.height=this.image.height,w&&(this.coordinates=w),this._finishLoading()}})}loaded(){return this._loaded}updateImage(w){return this.image&&w.url?(this.options.url=w.url,this.load(w.coordinates),this):this}_finishLoading(){this.map&&(this.setCoordinates(this.coordinates),this.fire(new m.Event("data",{dataType:"source",sourceDataType:"metadata"})))}onAdd(w){this.map=w,this.load()}onRemove(){this.texture&&this.texture.destroy()}setCoordinates(w){this.coordinates=w,this._boundsArray=void 0;const se=w.map(m.MercatorCoordinate.fromLngLat);return this.tileID=function(it){let xt=1/0,Dt=1/0,Ot=-1/0,rn=-1/0;for(const Wn of it)xt=Math.min(xt,Wn.x),Dt=Math.min(Dt,Wn.y),Ot=Math.max(Ot,Wn.x),rn=Math.max(rn,Wn.y);const Tn=Math.max(Ot-xt,rn-Dt),kn=Math.max(0,Math.floor(-Math.log(Tn)/Math.LN2)),Bn=Math.pow(2,kn);return new m.CanonicalTileID(kn,Math.floor((xt+Ot)/2*Bn),Math.floor((Dt+rn)/2*Bn))}(se),this.minzoom=this.maxzoom=this.tileID.z,this.fire(new m.Event("data",{dataType:"source",sourceDataType:"content"})),this}_clear(){this._boundsArray=void 0}_prepareData(w){for(const Tn in this.tiles){const kn=this.tiles[Tn];kn.state!=="loaded"&&(kn.state="loaded",kn.texture=this.texture)}if(this._boundsArray)return;const se=m.tileTransform(this.tileID,this.map.transform.projection),[it,xt,Dt,Ot]=this.coordinates.map(Tn=>{const kn=se.projection.project(Tn[0],Tn[1]);return m.getTilePoint(se,kn)._round()});this.perspectiveTransform=function(Tn,kn,Bn,Wn,Fr,ri,Zr,Sr,Di,di){const wi=ni(0,0,Tn,0,0,kn,Tn,kn),Ti=ni(Bn,Wn,Fr,ri,Zr,Sr,Di,di);return m.multiply(Ti,m.adjoint(wi,wi),Ti),[Ti[6]/Ti[8]*Tn/m.EXTENT,Ti[7]/Ti[8]*kn/m.EXTENT]}(this.width,this.height,it.x,it.y,xt.x,xt.y,Ot.x,Ot.y,Dt.x,Dt.y);const rn=this._boundsArray=new m.StructArrayLayout4i8;rn.emplaceBack(it.x,it.y,0,0),rn.emplaceBack(xt.x,xt.y,m.EXTENT,0),rn.emplaceBack(Ot.x,Ot.y,0,m.EXTENT),rn.emplaceBack(Dt.x,Dt.y,m.EXTENT,m.EXTENT),this.boundsBuffer&&this.boundsBuffer.destroy(),this.boundsBuffer=w.createVertexBuffer(rn,m.boundsAttributes.members),this.boundsSegments=m.SegmentVector.simpleSegment(0,0,4,2)}prepare(){if(Object.keys(this.tiles).length===0||!this.image)return;const w=this.map.painter.context,se=w.gl;this.texture?this.texture.update(this.image):(this.texture=new m.Texture(w,this.image,se.RGBA),this.texture.bind(se.LINEAR,se.CLAMP_TO_EDGE)),this._prepareData(w)}loadTile(w,se){this.tileID&&this.tileID.equals(w.tileID.canonical)?(this.tiles[String(w.tileID.wrap)]=w,w.buckets={},se(null)):(w.state="errored",se(null))}serialize(){return{type:"image",url:this.options.url,coordinates:this.coordinates}}hasTransition(){return!1}}const $t={vector:class extends m.Evented{constructor(Ee,w,se,it){if(super(),this.id=Ee,this.dispatcher=se,this.type="vector",this.minzoom=0,this.maxzoom=22,this.scheme="xyz",this.tileSize=512,this.reparseOverscaled=!0,this.isTileClipped=!0,this._loaded=!1,m.extend(this,m.pick(w,["url","scheme","tileSize","promoteId"])),this._options=m.extend({type:"vector"},w),this._collectResourceTiming=w.collectResourceTiming,this.tileSize!==512)throw new Error("vector tile sources must have a tileSize of 512");this.setEventedParent(it),this._tileWorkers={},this._deduped=new m.DedupedRequest}load(){this._loaded=!1,this.fire(new m.Event("dataloading",{dataType:"source"})),this._tileJSONRequest=Xr(this._options,this.map._requestManager,(Ee,w)=>{this._tileJSONRequest=null,this._loaded=!0,Ee?this.fire(new m.ErrorEvent(Ee)):w&&(m.extend(this,w),w.bounds&&(this.tileBounds=new ti(w.bounds,this.minzoom,this.maxzoom)),m.postTurnstileEvent(w.tiles,this.map._requestManager._customAccessToken),this.fire(new m.Event("data",{dataType:"source",sourceDataType:"metadata"})),this.fire(new m.Event("data",{dataType:"source",sourceDataType:"content"})))})}loaded(){return this._loaded}hasTile(Ee){return!this.tileBounds||this.tileBounds.contains(Ee.canonical)}onAdd(Ee){this.map=Ee,this.load()}setSourceProperty(Ee){this._tileJSONRequest&&this._tileJSONRequest.cancel(),Ee();const w=this.map.style._getSourceCaches(this.id);for(const se of w)se.clearTiles();this.load()}setTiles(Ee){return this.setSourceProperty(()=>{this._options.tiles=Ee}),this}setUrl(Ee){return this.setSourceProperty(()=>{this.url=Ee,this._options.url=Ee}),this}onRemove(){this._tileJSONRequest&&(this._tileJSONRequest.cancel(),this._tileJSONRequest=null)}serialize(){return m.extend({},this._options)}loadTile(Ee,w){const se=this.map._requestManager.normalizeTileURL(Ee.tileID.canonical.url(this.tiles,this.scheme)),it={request:this.map._requestManager.transformRequest(se,m.ResourceType.Tile),data:void 0,uid:Ee.uid,tileID:Ee.tileID,tileZoom:Ee.tileZoom,zoom:Ee.tileID.overscaledZ,tileSize:this.tileSize*Ee.tileID.overscaleFactor(),type:this.type,source:this.id,pixelRatio:m.exported.devicePixelRatio,showCollisionBoxes:this.map.showCollisionBoxes,promoteId:this.promoteId,isSymbolTile:Ee.isSymbolTile};if(it.request.collectResourceTiming=this._collectResourceTiming,Ee.actor&&Ee.state!=="expired")Ee.state==="loading"?Ee.reloadCallback=w:Ee.request=Ee.actor.send("reloadTile",it,xt.bind(this));else if(Ee.actor=this._tileWorkers[se]=this._tileWorkers[se]||this.dispatcher.getActor(),this.dispatcher.ready)Ee.request=Ee.actor.send("loadTile",it,xt.bind(this),void 0,!0);else{const Dt=m.loadVectorTile.call({deduped:this._deduped},it,(Ot,rn)=>{Ot||!rn?xt.call(this,Ot):(it.data={cacheControl:rn.cacheControl,expires:rn.expires,rawData:rn.rawData.slice(0)},Ee.actor&&Ee.actor.send("loadTile",it,xt.bind(this),void 0,!0))},!0);Ee.request={cancel:Dt}}function xt(Dt,Ot){return delete Ee.request,Ee.aborted?w(null):Dt&&Dt.status!==404?w(Dt):(Ot&&Ot.resourceTiming&&(Ee.resourceTiming=Ot.resourceTiming),this.map._refreshExpiredTiles&&Ot&&Ee.setExpiryData(Ot),Ee.loadVectorData(Ot,this.map.painter),m.cacheEntryPossiblyAdded(this.dispatcher),w(null),void(Ee.reloadCallback&&(this.loadTile(Ee,Ee.reloadCallback),Ee.reloadCallback=null)))}}abortTile(Ee){Ee.request&&(Ee.request.cancel(),delete Ee.request),Ee.actor&&Ee.actor.send("abortTile",{uid:Ee.uid,type:this.type,source:this.id})}unloadTile(Ee){Ee.unloadVectorData(),Ee.actor&&Ee.actor.send("removeTile",{uid:Ee.uid,type:this.type,source:this.id})}hasTransition(){return!1}afterUpdate(){this._tileWorkers={}}},raster:Un,"raster-dem":class extends Un{constructor(Ee,w,se,it){super(Ee,w,se,it),this.type="raster-dem",this.maxzoom=22,this._options=m.extend({type:"raster-dem"},w),this.encoding=w.encoding||"mapbox"}loadTile(Ee,w){const se=this.map._requestManager.normalizeTileURL(Ee.tileID.canonical.url(this.tiles,this.scheme),!1,this.tileSize);function it(xt,Dt){xt&&(Ee.state="errored",w(xt)),Dt&&(Ee.dem=Dt,Ee.dem.onDeserialize(),Ee.needsHillshadePrepare=!0,Ee.needsDEMTextureUpload=!0,Ee.state="loaded",w(null))}Ee.request=m.getImage(this.map._requestManager.transformRequest(se,m.ResourceType.Tile),function(xt,Dt,Ot,rn){if(delete Ee.request,Ee.aborted)Ee.state="unloaded",w(null);else if(xt)Ee.state="errored",w(xt);else if(Dt){this.map._refreshExpiredTiles&&Ee.setExpiryData({cacheControl:Ot,expires:rn});const Tn=m.window.ImageBitmap&&Dt instanceof m.window.ImageBitmap&&(Gr==null&&(Gr=m.window.OffscreenCanvas&&new m.window.OffscreenCanvas(1,1).getContext("2d")&&typeof m.window.createImageBitmap=="function"),Gr),kn=1-(Dt.width-m.prevPowerOfTwo(Dt.width))/2;kn<1||Ee.neighboringTiles||(Ee.neighboringTiles=this._getNeighboringTiles(Ee.tileID));const Bn=Tn?Dt:m.exported.getImageData(Dt,kn),Wn={uid:Ee.uid,coord:Ee.tileID,source:this.id,rawImageData:Bn,encoding:this.encoding,padding:kn};Ee.actor&&Ee.state!=="expired"||(Ee.actor=this.dispatcher.getActor(),Ee.actor.send("loadDEMTile",Wn,it.bind(this),void 0,!0))}}.bind(this))}_getNeighboringTiles(Ee){const w=Ee.canonical,se=Math.pow(2,w.z),it=(w.x-1+se)%se,xt=w.x===0?Ee.wrap-1:Ee.wrap,Dt=(w.x+1+se)%se,Ot=w.x+1===se?Ee.wrap+1:Ee.wrap,rn={};return rn[new m.OverscaledTileID(Ee.overscaledZ,xt,w.z,it,w.y).key]={backfilled:!1},rn[new m.OverscaledTileID(Ee.overscaledZ,Ot,w.z,Dt,w.y).key]={backfilled:!1},w.y>0&&(rn[new m.OverscaledTileID(Ee.overscaledZ,xt,w.z,it,w.y-1).key]={backfilled:!1},rn[new m.OverscaledTileID(Ee.overscaledZ,Ee.wrap,w.z,w.x,w.y-1).key]={backfilled:!1},rn[new m.OverscaledTileID(Ee.overscaledZ,Ot,w.z,Dt,w.y-1).key]={backfilled:!1}),w.y+1<se&&(rn[new m.OverscaledTileID(Ee.overscaledZ,xt,w.z,it,w.y+1).key]={backfilled:!1},rn[new m.OverscaledTileID(Ee.overscaledZ,Ee.wrap,w.z,w.x,w.y+1).key]={backfilled:!1},rn[new m.OverscaledTileID(Ee.overscaledZ,Ot,w.z,Dt,w.y+1).key]={backfilled:!1}),rn}unloadTile(Ee){Ee.demTexture&&this.map.painter.saveTileTexture(Ee.demTexture),Ee.fbo&&(Ee.fbo.destroy(),delete Ee.fbo),Ee.dem&&delete Ee.dem,delete Ee.neighboringTiles,Ee.state="unloaded"}},geojson:class extends m.Evented{constructor(Ee,w,se,it){super(),this.id=Ee,this.type="geojson",this.minzoom=0,this.maxzoom=18,this.tileSize=512,this.isTileClipped=!0,this.reparseOverscaled=!0,this._loaded=!1,this.actor=se.getActor(),this.setEventedParent(it),this._data=w.data,this._options=m.extend({},w),this._collectResourceTiming=w.collectResourceTiming,w.maxzoom!==void 0&&(this.maxzoom=w.maxzoom),w.type&&(this.type=w.type),w.attribution&&(this.attribution=w.attribution),this.promoteId=w.promoteId;const xt=m.EXTENT/this.tileSize;this.workerOptions=m.extend({source:this.id,cluster:w.cluster||!1,geojsonVtOptions:{buffer:(w.buffer!==void 0?w.buffer:128)*xt,tolerance:(w.tolerance!==void 0?w.tolerance:.375)*xt,extent:m.EXTENT,maxZoom:this.maxzoom,lineMetrics:w.lineMetrics||!1,generateId:w.generateId||!1},superclusterOptions:{maxZoom:w.clusterMaxZoom!==void 0?w.clusterMaxZoom:this.maxzoom-1,minPoints:Math.max(2,w.clusterMinPoints||2),extent:m.EXTENT,radius:(w.clusterRadius!==void 0?w.clusterRadius:50)*xt,log:!1,generateId:w.generateId||!1},clusterProperties:w.clusterProperties,filter:w.filter},w.workerOptions)}onAdd(Ee){this.map=Ee,this.setData(this._data)}setData(Ee){return this._data=Ee,this._updateWorkerData(),this}getClusterExpansionZoom(Ee,w){return this.actor.send("geojson.getClusterExpansionZoom",{clusterId:Ee,source:this.id},w),this}getClusterChildren(Ee,w){return this.actor.send("geojson.getClusterChildren",{clusterId:Ee,source:this.id},w),this}getClusterLeaves(Ee,w,se,it){return this.actor.send("geojson.getClusterLeaves",{source:this.id,clusterId:Ee,limit:w,offset:se},it),this}_updateWorkerData(){if(this._pendingLoad)return void(this._coalesce=!0);this.fire(new m.Event("dataloading",{dataType:"source"})),this._loaded=!1;const Ee=m.extend({},this.workerOptions),w=this._data;typeof w=="string"?(Ee.request=this.map._requestManager.transformRequest(m.exported.resolveURL(w),m.ResourceType.Source),Ee.request.collectResourceTiming=this._collectResourceTiming):Ee.data=JSON.stringify(w),this._pendingLoad=this.actor.send(`${this.type}.loadData`,Ee,(se,it)=>{if(this._loaded=!0,this._pendingLoad=null,se)this.fire(new m.ErrorEvent(se));else{const xt={dataType:"source",sourceDataType:this._metadataFired?"content":"metadata"};this._collectResourceTiming&&it&&it.resourceTiming&&it.resourceTiming[this.id]&&(xt.resourceTiming=it.resourceTiming[this.id]),this.fire(new m.Event("data",xt)),this._metadataFired=!0}this._coalesce&&(this._updateWorkerData(),this._coalesce=!1)})}loaded(){return this._loaded}loadTile(Ee,w){const se=Ee.actor?"reloadTile":"loadTile";Ee.actor=this.actor,Ee.request=this.actor.send(se,{type:this.type,uid:Ee.uid,tileID:Ee.tileID,tileZoom:Ee.tileZoom,zoom:Ee.tileID.overscaledZ,maxZoom:this.maxzoom,tileSize:this.tileSize,source:this.id,pixelRatio:m.exported.devicePixelRatio,showCollisionBoxes:this.map.showCollisionBoxes,promoteId:this.promoteId},(it,xt)=>(delete Ee.request,Ee.unloadVectorData(),Ee.aborted?w(null):it?w(it):(Ee.loadVectorData(xt,this.map.painter,se==="reloadTile"),w(null))),void 0,se==="loadTile")}abortTile(Ee){Ee.request&&(Ee.request.cancel(),delete Ee.request),Ee.aborted=!0}unloadTile(Ee){Ee.unloadVectorData(),this.actor.send("removeTile",{uid:Ee.uid,type:this.type,source:this.id})}onRemove(){this._pendingLoad&&this._pendingLoad.cancel()}serialize(){return m.extend({},this._options,{type:this.type,data:this._data})}hasTransition(){return!1}},video:class extends Ei{constructor(Ee,w,se,it){super(Ee,w,se,it),this.roundZoom=!0,this.type="video",this.options=w}load(){this._loaded=!1;const Ee=this.options;this.urls=[];for(const w of Ee.urls)this.urls.push(this.map._requestManager.transformRequest(w,m.ResourceType.Source).url);m.getVideo(this.urls,(w,se)=>{this._loaded=!0,w?this.fire(new m.ErrorEvent(w)):se&&(this.video=se,this.video.loop=!0,this.video.setAttribute("playsinline",""),this.video.addEventListener("playing",()=>{this.map.triggerRepaint()}),this.map&&this.video.play(),this._finishLoading())})}pause(){this.video&&this.video.pause()}play(){this.video&&this.video.play()}seek(Ee){if(this.video){const w=this.video.seekable;Ee<w.start(0)||Ee>w.end(0)?this.fire(new m.ErrorEvent(new m.ValidationError(`sources.${this.id}`,null,`Playback for this video can be set only between the ${w.start(0)} and ${w.end(0)}-second mark.`))):this.video.currentTime=Ee}}getVideo(){return this.video}onAdd(Ee){this.map||(this.map=Ee,this.load(),this.video&&(this.video.play(),this.setCoordinates(this.coordinates)))}prepare(){if(Object.keys(this.tiles).length===0||this.video.readyState<2)return;const Ee=this.map.painter.context,w=Ee.gl;this.texture?this.video.paused||(this.texture.bind(w.LINEAR,w.CLAMP_TO_EDGE),w.texSubImage2D(w.TEXTURE_2D,0,0,0,w.RGBA,w.UNSIGNED_BYTE,this.video)):(this.texture=new m.Texture(Ee,this.video,w.RGBA),this.texture.bind(w.LINEAR,w.CLAMP_TO_EDGE),this.width=this.video.videoWidth,this.height=this.video.videoHeight),this._prepareData(Ee)}serialize(){return{type:"video",urls:this.urls,coordinates:this.coordinates}}hasTransition(){return this.video&&!this.video.paused}},image:Ei,canvas:class extends Ei{constructor(Ee,w,se,it){super(Ee,w,se,it),w.coordinates?Array.isArray(w.coordinates)&&w.coordinates.length===4&&!w.coordinates.some(xt=>!Array.isArray(xt)||xt.length!==2||xt.some(Dt=>typeof Dt!="number"))||this.fire(new m.ErrorEvent(new m.ValidationError(`sources.${Ee}`,null,'"coordinates" property must be an array of 4 longitude/latitude array pairs'))):this.fire(new m.ErrorEvent(new m.ValidationError(`sources.${Ee}`,null,'missing required property "coordinates"'))),w.animate&&typeof w.animate!="boolean"&&this.fire(new m.ErrorEvent(new m.ValidationError(`sources.${Ee}`,null,'optional "animate" property must be a boolean value'))),w.canvas?typeof w.canvas=="string"||w.canvas instanceof m.window.HTMLCanvasElement||this.fire(new m.ErrorEvent(new m.ValidationError(`sources.${Ee}`,null,'"canvas" must be either a string representing the ID of the canvas element from which to read, or an HTMLCanvasElement instance'))):this.fire(new m.ErrorEvent(new m.ValidationError(`sources.${Ee}`,null,'missing required property "canvas"'))),this.options=w,this.animate=w.animate===void 0||w.animate}load(){this._loaded=!0,this.canvas||(this.canvas=this.options.canvas instanceof m.window.HTMLCanvasElement?this.options.canvas:m.window.document.getElementById(this.options.canvas)),this.width=this.canvas.width,this.height=this.canvas.height,this._hasInvalidDimensions()?this.fire(new m.ErrorEvent(new Error("Canvas dimensions cannot be less than or equal to zero."))):(this.play=function(){this._playing=!0,this.map.triggerRepaint()},this.pause=function(){this._playing&&(this.prepare(),this._playing=!1)},this._finishLoading())}getCanvas(){return this.canvas}onAdd(Ee){this.map=Ee,this.load(),this.canvas&&this.animate&&this.play()}onRemove(){this.pause()}prepare(){let Ee=!1;if(this.canvas.width!==this.width&&(this.width=this.canvas.width,Ee=!0),this.canvas.height!==this.height&&(this.height=this.canvas.height,Ee=!0),this._hasInvalidDimensions()||Object.keys(this.tiles).length===0)return;const w=this.map.painter.context;this.texture?(Ee||this._playing)&&this.texture.update(this.canvas,{premultiply:!0}):this.texture=new m.Texture(w,this.canvas,w.gl.RGBA,{premultiply:!0}),this._prepareData(w)}serialize(){return{type:"canvas",coordinates:this.coordinates}}hasTransition(){return this._playing}_hasInvalidDimensions(){for(const Ee of[this.canvas.width,this.canvas.height])if(isNaN(Ee)||Ee<=0)return!0;return!1}},custom:class extends m.Evented{constructor(Ee,w,se,it){super(),this.id=Ee,this.type="custom",this._dataType="raster",this._dispatcher=se,this._implementation=w,this.setEventedParent(it),this.scheme="xyz",this.minzoom=0,this.maxzoom=22,this.tileSize=512,this._loaded=!1,this.roundZoom=!0,this._implementation||this.fire(new m.ErrorEvent(new Error(`Missing implementation for ${this.id} custom source`))),this._implementation.loadTile||this.fire(new m.ErrorEvent(new Error(`Missing loadTile implementation for ${this.id} custom source`))),this._implementation.bounds&&(this.tileBounds=new ti(this._implementation.bounds,this.minzoom,this.maxzoom)),w.update=this._update.bind(this),w.coveringTiles=this._coveringTiles.bind(this),m.extend(this,m.pick(w,["dataType","scheme","minzoom","maxzoom","tileSize","attribution","minTileCacheSize","maxTileCacheSize"]))}serialize(){return m.pick(this,["type","scheme","minzoom","maxzoom","tileSize","attribution"])}load(){this._loaded=!0,this.fire(new m.Event("data",{dataType:"source",sourceDataType:"metadata"})),this.fire(new m.Event("data",{dataType:"source",sourceDataType:"content"}))}loaded(){return this._loaded}onAdd(Ee){this._map=Ee,this._loaded=!1,this.fire(new m.Event("dataloading",{dataType:"source"})),this._implementation.onAdd&&this._implementation.onAdd(Ee),this.load()}onRemove(Ee){this._implementation.onRemove&&this._implementation.onRemove(Ee)}hasTile(Ee){if(this._implementation.hasTile){const{x:w,y:se,z:it}=Ee.canonical;return this._implementation.hasTile({x:w,y:se,z:it})}return!this.tileBounds||this.tileBounds.contains(Ee.canonical)}loadTile(Ee,w){const{x:se,y:it,z:xt}=Ee.tileID.canonical,Dt=new m.window.AbortController,Ot=this._implementation.loadTile({x:se,y:it,z:xt},{signal:Dt.signal});if(!Ot)return this.loadTileData(Ee,{width:this.tileSize,height:this.tileSize,data:null}),Ee.state="loaded",w(null);Ot.cancel=()=>Dt.abort(),Ee.request=Ot.then(function(rn){return delete Ee.request,Ee.aborted?(Ee.state="unloaded",w(null)):rn?function(Tn){return Tn instanceof m.window.ImageData||Tn instanceof m.window.ImageBitmap||Tn instanceof m.window.HTMLCanvasElement}(rn)?(this.loadTileData(Ee,rn),Ee.state="loaded",void w(null)):(Ee.state="errored",w(new Error(`Can't infer data type for ${this.id}, only raster data supported at the moment`))):(this.loadTileData(Ee,{width:this.tileSize,height:this.tileSize,data:null}),Ee.state="loaded",w(null))}.bind(this)).catch(rn=>{rn.code!==20&&(Ee.state="errored",w(rn))})}loadTileData(Ee,w){Un.loadTileData(Ee,w,this._map.painter)}unloadTileData(Ee){Un.unloadTileData(Ee,this._map.painter)}prepareTile(Ee){if(!this._implementation.prepareTile)return null;const{x:w,y:se,z:it}=Ee.tileID.canonical,xt=this._implementation.prepareTile({x:w,y:se,z:it});return xt?(this.loadTileData(Ee,xt),Ee.state="loaded",xt):null}unloadTile(Ee,w){if(this.unloadTileData(Ee),this._implementation.unloadTile){const{x:se,y:it,z:xt}=Ee.tileID.canonical;this._implementation.unloadTile({x:se,y:it,z:xt})}w()}abortTile(Ee,w){Ee.request&&Ee.request.cancel&&(Ee.request.cancel(),delete Ee.request),w()}hasTransition(){return!1}_coveringTiles(){return this._map.transform.coveringTiles({tileSize:this.tileSize,minzoom:this.minzoom,maxzoom:this.maxzoom,roundZoom:this.roundZoom}).map(Ee=>({x:Ee.canonical.x,y:Ee.canonical.y,z:Ee.canonical.z}))}_update(){this.fire(new m.Event("data",{dataType:"source",sourceDataType:"content"}))}}},ta=function(Ee,w,se,it){const xt=new $t[w.type](Ee,w,se,it);if(xt.id!==Ee)throw new Error(`Expected Source id to be ${Ee} instead of ${xt.id}`);return m.bindAll(["load","abort","unload","serialize","prepare"],xt),xt};function Hi(Ee,w){const se=m.identity([]);return m.scale(se,se,[.5*Ee.width,.5*-Ee.height,1]),m.translate(se,se,[1,-1,0]),m.multiply$1(se,se,Ee.calculateProjMatrix(w.toUnwrapped())),Float32Array.from(se)}function Ai(Ee,w,se,it,xt,Dt,Ot,rn=!1){const Tn=Ee.tilesIn(it,Ot,rn);Tn.sort(wo);const kn=[];for(const Wn of Tn)kn.push({wrappedTileID:Wn.tile.tileID.wrapped().key,queryResults:Wn.tile.queryRenderedFeatures(w,se,Ee._state,Wn,xt,Dt,Hi(Ee.transform,Wn.tile.tileID),rn)});const Bn=function(Wn){const Fr={},ri={};for(const Zr of Wn){const Sr=Zr.queryResults,Di=Zr.wrappedTileID,di=ri[Di]=ri[Di]||{};for(const wi in Sr){const Ti=Sr[wi],Oi=di[wi]=di[wi]||{},_i=Fr[wi]=Fr[wi]||[];for(const Fi of Ti)Oi[Fi.featureIndex]||(Oi[Fi.featureIndex]=!0,_i.push(Fi))}}return Fr}(kn);for(const Wn in Bn)Bn[Wn].forEach(Fr=>{const ri=Fr.feature,Zr=ri.layer;Zr&&Zr.type!=="background"&&Zr.type!=="sky"&&(ri.source=Zr.source,Zr["source-layer"]&&(ri.sourceLayer=Zr["source-layer"]),ri.state=ri.id!==void 0?Ee.getFeatureState(Zr["source-layer"],ri.id):{})});return Bn}function Ea(Ee,w){const se=Ee.getRenderableIds().map(Dt=>Ee.getTileByID(Dt)),it=[],xt={};for(let Dt=0;Dt<se.length;Dt++){const Ot=se[Dt],rn=Ot.tileID.canonical.key;xt[rn]||(xt[rn]=!0,Ot.querySourceFeatures(it,w))}return it}function wo(Ee,w){const se=Ee.tileID,it=w.tileID;return se.overscaledZ-it.overscaledZ||se.canonical.y-it.canonical.y||se.wrap-it.wrap||se.canonical.x-it.canonical.x}function to(){return zp.workerClass!=null?new zp.workerClass:new m.window.Worker(zp.workerUrl)}const zo="mapboxgl_preloaded_worker_pool";class Po{constructor(){this.active={}}acquire(w){if(!this.workers)for(this.workers=[];this.workers.length<Po.workerCount;)this.workers.push(new to);return this.active[w]=!0,this.workers.slice()}release(w){delete this.active[w],this.numActive()===0&&(this.workers.forEach(se=>{se.terminate()}),this.workers=null)}isPreloaded(){return!!this.active[zo]}numActive(){return Object.keys(this.active).length}}let Lo;function Wo(){return Lo||(Lo=new Po),Lo}function ma(Ee,w){const se={};for(const it in Ee)it!=="ref"&&(se[it]=Ee[it]);return m.refProperties.forEach(it=>{it in w&&(se[it]=w[it])}),se}function $s(Ee){Ee=Ee.slice();const w=Object.create(null);for(let se=0;se<Ee.length;se++)w[Ee[se].id]=Ee[se];for(let se=0;se<Ee.length;se++)"ref"in Ee[se]&&(Ee[se]=ma(Ee[se],w[Ee[se].ref]));return Ee}Po.workerCount=2;const ao={setStyle:"setStyle",addLayer:"addLayer",removeLayer:"removeLayer",setPaintProperty:"setPaintProperty",setLayoutProperty:"setLayoutProperty",setFilter:"setFilter",addSource:"addSource",removeSource:"removeSource",setGeoJSONSourceData:"setGeoJSONSourceData",setLayerZoomRange:"setLayerZoomRange",setLayerProperty:"setLayerProperty",setCenter:"setCenter",setZoom:"setZoom",setBearing:"setBearing",setPitch:"setPitch",setSprite:"setSprite",setGlyphs:"setGlyphs",setTransition:"setTransition",setLight:"setLight",setTerrain:"setTerrain",setFog:"setFog",setProjection:"setProjection"};function Ps(Ee,w,se){se.push({command:ao.addSource,args:[Ee,w[Ee]]})}function qo(Ee,w,se){w.push({command:ao.removeSource,args:[Ee]}),se[Ee]=!0}function wl(Ee,w,se,it){qo(Ee,se,it),Ps(Ee,w,se)}function yu(Ee,w,se){let it;for(it in Ee[se])if(Ee[se].hasOwnProperty(it)&&it!=="data"&&!G(Ee[se][it],w[se][it]))return!1;for(it in w[se])if(w[se].hasOwnProperty(it)&&it!=="data"&&!G(Ee[se][it],w[se][it]))return!1;return!0}function po(Ee,w,se,it,xt,Dt){let Ot;for(Ot in w=w||{},Ee=Ee||{})Ee.hasOwnProperty(Ot)&&(G(Ee[Ot],w[Ot])||se.push({command:Dt,args:[it,Ot,w[Ot],xt]}));for(Ot in w)w.hasOwnProperty(Ot)&&!Ee.hasOwnProperty(Ot)&&(G(Ee[Ot],w[Ot])||se.push({command:Dt,args:[it,Ot,w[Ot],xt]}))}function Zs(Ee){return Ee.id}function Es(Ee,w){return Ee[w.id]=w,Ee}class Xl{constructor(w,se){this.reset(w,se)}reset(w,se){this.points=w||[],this._distances=[0];for(let it=1;it<this.points.length;it++)this._distances[it]=this._distances[it-1]+this.points[it].dist(this.points[it-1]);this.length=this._distances[this._distances.length-1],this.padding=Math.min(se||0,.5*this.length),this.paddedLength=this.length-2*this.padding}lerp(w){if(this.points.length===1)return this.points[0];w=m.clamp(w,0,1);let se=1,it=this._distances[se];const xt=w*this.paddedLength+this.padding;for(;it<xt&&se<this._distances.length;)it=this._distances[++se];const Dt=se-1,Ot=this._distances[Dt],rn=it-Ot,Tn=rn>0?(xt-Ot)/rn:0;return this.points[Dt].mult(1-Tn).add(this.points[se].mult(Tn))}}class xl{constructor(w,se,it){const xt=this.boxCells=[],Dt=this.circleCells=[];this.xCellCount=Math.ceil(w/it),this.yCellCount=Math.ceil(se/it);for(let Ot=0;Ot<this.xCellCount*this.yCellCount;Ot++)xt.push([]),Dt.push([]);this.circleKeys=[],this.boxKeys=[],this.bboxes=[],this.circles=[],this.width=w,this.height=se,this.xScale=this.xCellCount/w,this.yScale=this.yCellCount/se,this.boxUid=0,this.circleUid=0}keysLength(){return this.boxKeys.length+this.circleKeys.length}insert(w,se,it,xt,Dt){this._forEachCell(se,it,xt,Dt,this._insertBoxCell,this.boxUid++),this.boxKeys.push(w),this.bboxes.push(se),this.bboxes.push(it),this.bboxes.push(xt),this.bboxes.push(Dt)}insertCircle(w,se,it,xt){this._forEachCell(se-xt,it-xt,se+xt,it+xt,this._insertCircleCell,this.circleUid++),this.circleKeys.push(w),this.circles.push(se),this.circles.push(it),this.circles.push(xt)}_insertBoxCell(w,se,it,xt,Dt,Ot){this.boxCells[Dt].push(Ot)}_insertCircleCell(w,se,it,xt,Dt,Ot){this.circleCells[Dt].push(Ot)}_query(w,se,it,xt,Dt,Ot){if(it<0||w>this.width||xt<0||se>this.height)return!Dt&&[];const rn=[];if(w<=0&&se<=0&&this.width<=it&&this.height<=xt){if(Dt)return!0;for(let Tn=0;Tn<this.boxKeys.length;Tn++)rn.push({key:this.boxKeys[Tn],x1:this.bboxes[4*Tn],y1:this.bboxes[4*Tn+1],x2:this.bboxes[4*Tn+2],y2:this.bboxes[4*Tn+3]});for(let Tn=0;Tn<this.circleKeys.length;Tn++){const kn=this.circles[3*Tn],Bn=this.circles[3*Tn+1],Wn=this.circles[3*Tn+2];rn.push({key:this.circleKeys[Tn],x1:kn-Wn,y1:Bn-Wn,x2:kn+Wn,y2:Bn+Wn})}return Ot?rn.filter(Ot):rn}return this._forEachCell(w,se,it,xt,this._queryCell,rn,{hitTest:Dt,seenUids:{box:{},circle:{}}},Ot),Dt?rn.length>0:rn}_queryCircle(w,se,it,xt,Dt){const Ot=w-it,rn=w+it,Tn=se-it,kn=se+it;if(rn<0||Ot>this.width||kn<0||Tn>this.height)return!xt&&[];const Bn=[];return this._forEachCell(Ot,Tn,rn,kn,this._queryCellCircle,Bn,{hitTest:xt,circle:{x:w,y:se,radius:it},seenUids:{box:{},circle:{}}},Dt),xt?Bn.length>0:Bn}query(w,se,it,xt,Dt){return this._query(w,se,it,xt,!1,Dt)}hitTest(w,se,it,xt,Dt){return this._query(w,se,it,xt,!0,Dt)}hitTestCircle(w,se,it,xt){return this._queryCircle(w,se,it,!0,xt)}_queryCell(w,se,it,xt,Dt,Ot,rn,Tn){const kn=rn.seenUids,Bn=this.boxCells[Dt];if(Bn!==null){const Fr=this.bboxes;for(const ri of Bn)if(!kn.box[ri]){kn.box[ri]=!0;const Zr=4*ri;if(w<=Fr[Zr+2]&&se<=Fr[Zr+3]&&it>=Fr[Zr+0]&&xt>=Fr[Zr+1]&&(!Tn||Tn(this.boxKeys[ri]))){if(rn.hitTest)return Ot.push(!0),!0;Ot.push({key:this.boxKeys[ri],x1:Fr[Zr],y1:Fr[Zr+1],x2:Fr[Zr+2],y2:Fr[Zr+3]})}}}const Wn=this.circleCells[Dt];if(Wn!==null){const Fr=this.circles;for(const ri of Wn)if(!kn.circle[ri]){kn.circle[ri]=!0;const Zr=3*ri;if(this._circleAndRectCollide(Fr[Zr],Fr[Zr+1],Fr[Zr+2],w,se,it,xt)&&(!Tn||Tn(this.circleKeys[ri]))){if(rn.hitTest)return Ot.push(!0),!0;{const Sr=Fr[Zr],Di=Fr[Zr+1],di=Fr[Zr+2];Ot.push({key:this.circleKeys[ri],x1:Sr-di,y1:Di-di,x2:Sr+di,y2:Di+di})}}}}}_queryCellCircle(w,se,it,xt,Dt,Ot,rn,Tn){const kn=rn.circle,Bn=rn.seenUids,Wn=this.boxCells[Dt];if(Wn!==null){const ri=this.bboxes;for(const Zr of Wn)if(!Bn.box[Zr]){Bn.box[Zr]=!0;const Sr=4*Zr;if(this._circleAndRectCollide(kn.x,kn.y,kn.radius,ri[Sr+0],ri[Sr+1],ri[Sr+2],ri[Sr+3])&&(!Tn||Tn(this.boxKeys[Zr])))return Ot.push(!0),!0}}const Fr=this.circleCells[Dt];if(Fr!==null){const ri=this.circles;for(const Zr of Fr)if(!Bn.circle[Zr]){Bn.circle[Zr]=!0;const Sr=3*Zr;if(this._circlesCollide(ri[Sr],ri[Sr+1],ri[Sr+2],kn.x,kn.y,kn.radius)&&(!Tn||Tn(this.circleKeys[Zr])))return Ot.push(!0),!0}}}_forEachCell(w,se,it,xt,Dt,Ot,rn,Tn){const kn=this._convertToXCellCoord(w),Bn=this._convertToYCellCoord(se),Wn=this._convertToXCellCoord(it),Fr=this._convertToYCellCoord(xt);for(let ri=kn;ri<=Wn;ri++)for(let Zr=Bn;Zr<=Fr;Zr++)if(Dt.call(this,w,se,it,xt,this.xCellCount*Zr+ri,Ot,rn,Tn))return}_convertToXCellCoord(w){return Math.max(0,Math.min(this.xCellCount-1,Math.floor(w*this.xScale)))}_convertToYCellCoord(w){return Math.max(0,Math.min(this.yCellCount-1,Math.floor(w*this.yScale)))}_circlesCollide(w,se,it,xt,Dt,Ot){const rn=xt-w,Tn=Dt-se,kn=it+Ot;return kn*kn>rn*rn+Tn*Tn}_circleAndRectCollide(w,se,it,xt,Dt,Ot,rn){const Tn=(Ot-xt)/2,kn=Math.abs(w-(xt+Tn));if(kn>Tn+it)return!1;const Bn=(rn-Dt)/2,Wn=Math.abs(se-(Dt+Bn));if(Wn>Bn+it)return!1;if(kn<=Tn||Wn<=Bn)return!0;const Fr=kn-Tn,ri=Wn-Bn;return Fr*Fr+ri*ri<=it*it}}const jo=Math.tan(85*Math.PI/180);function ju(Ee,w,se,it,xt,Dt){const Ot=m.create();if(se){if(xt.projection.name==="globe")m.multiply$1(Ot,Ot,m.calculateGlobeLabelMatrix(xt,w));else{const rn=ue([],Dt);Ot[0]=rn[0],Ot[1]=rn[1],Ot[4]=rn[2],Ot[5]=rn[3]}it||m.rotateZ(Ot,Ot,xt.angle)}else m.multiply$1(Ot,xt.labelPlaneMatrix,Ee);return Ot}function Pl(Ee,w,se,it,xt,Dt){if(se){if(xt.projection.name==="globe"){const Ot=ju(Ee,w,se,it,xt,Dt);return m.invert(Ot,Ot),m.multiply$1(Ot,Ee,Ot),Ot}{const Ot=m.clone(Ee),rn=m.identity([]);return rn[0]=Dt[0],rn[1]=Dt[1],rn[4]=Dt[2],rn[5]=Dt[3],m.multiply$1(Ot,Ot,rn),it||m.rotateZ(Ot,Ot,-xt.angle),Ot}}return xt.glCoordMatrix}function tl(Ee,w,se=0){const it=[Ee.x,Ee.y,se,1];se?m.transformMat4$1(it,it,w):Uo(it,it,w);const xt=it[3];return{point:new m.pointGeometry(it[0]/xt,it[1]/xt),signedDistanceFromCamera:xt}}function zl(Ee,w){const se=[Ee[0],Ee[1],Ee[2],1];m.transformMat4$1(se,se,w);const it=se[3];return{point:new m.pointGeometry(se[0]/it,se[1]/it),signedDistanceFromCamera:it}}function Is(Ee,w){return Math.min(.5+Ee/w*.5,1.5)}function al(Ee,w){const se=Ee[0]/Ee[3],it=Ee[1]/Ee[3];return se>=-w[0]&&se<=w[0]&&it>=-w[1]&&it<=w[1]}function Mn(Ee,w,se,it,xt,Dt,Ot,rn,Tn,kn){const Bn=se.transform,Wn=it?Ee.textSizeData:Ee.iconSizeData,Fr=m.evaluateSizeForZoom(Wn,se.transform.zoom),ri=[256/se.width*2+1,256/se.height*2+1],Zr=it?Ee.text.dynamicLayoutVertexArray:Ee.icon.dynamicLayoutVertexArray;Zr.clear();const Sr=Ee.lineVertexArray,Di=it?Ee.text.placedSymbolArray:Ee.icon.placedSymbolArray,di=se.transform.width/se.transform.height;let wi=!1;for(let Ti=0;Ti<Di.length;Ti++){const Oi=Di.get(Ti);if(Oi.writingMode!==m.WritingMode.vertical||wi||Ti!==0&&Di.get(Ti-1).writingMode===m.WritingMode.horizontal||(wi=!0),(Oi.hidden||Oi.writingMode===m.WritingMode.vertical)&&!wi){Go(Oi.numGlyphs,Zr);continue}wi=!1;const _i=new m.pointGeometry(Oi.tileAnchorX,Oi.tileAnchorY),Fi=Tn?Tn(_i):[0,0,0],Ta=Bn.projection.projectTilePoint(_i.x,_i.y,kn.canonical),Fa=[Ta.x+Fi[0],Ta.y+Fi[1],Ta.z+Fi[2]],qa=[...Fa,1];if(m.transformMat4$1(qa,qa,w),!al(qa,ri)){Go(Oi.numGlyphs,Zr);continue}const ja=Is(se.transform.cameraToCenterDistance,qa[3]),To=m.evaluateSizeForFeature(Wn,Fr,Oi),na=Ot?To/ja:To*ja,Eo=tl(new m.pointGeometry(Fa[0],Fa[1]),xt,Fa[2]);if(Eo.signedDistanceFromCamera<=0){Go(Oi.numGlyphs,Zr);continue}let So={};const Qo=Ot?null:Tn,Za=Qr(Oi,na,!1,rn,w,xt,Dt,Ee.glyphOffsetArray,Sr,Zr,Eo.point,_i,So,di,Qo,Bn.projection,kn);wi=Za.useVertical,Qo&&Za.needsFlipping&&(So={}),(Za.notEnoughRoom||wi||Za.needsFlipping&&Qr(Oi,na,!0,rn,w,xt,Dt,Ee.glyphOffsetArray,Sr,Zr,Eo.point,_i,So,di,Qo,Bn.projection,kn).notEnoughRoom)&&Go(Oi.numGlyphs,Zr)}it?Ee.text.dynamicLayoutVertexBuffer.updateData(Zr):Ee.icon.dynamicLayoutVertexBuffer.updateData(Zr)}function Ur(Ee,w,se,it,xt,Dt,Ot,rn,Tn,kn,Bn,Wn,Fr,ri,Zr){const Sr=rn.glyphStartIndex+rn.numGlyphs,Di=rn.lineStartIndex,di=rn.lineStartIndex+rn.lineLength,wi=w.getoffsetX(rn.glyphStartIndex),Ti=w.getoffsetX(Sr-1),Oi=no(Ee*wi,se,it,xt,Dt,Ot,rn.segment,Di,di,Tn,kn,Bn,Wn,Fr,!0,ri,Zr);if(!Oi)return null;const _i=no(Ee*Ti,se,it,xt,Dt,Ot,rn.segment,Di,di,Tn,kn,Bn,Wn,Fr,!0,ri,Zr);return _i?{first:Oi,last:_i}:null}function Gn(Ee,w,se,it){return Ee.writingMode===m.WritingMode.horizontal&&Math.abs(se.y-w.y)>Math.abs(se.x-w.x)*it?{useVertical:!0}:Ee.writingMode===m.WritingMode.vertical?w.y<se.y?{needsFlipping:!0}:null:Ee.flipState!==0&&function(xt,Dt,Ot){const rn=(Dt.x-xt.x)*Ot;return rn===0||Math.abs((Dt.y-xt.y)/rn)>jo}(w,se,it)?Ee.flipState===1?{needsFlipping:!0}:null:w.x>se.x?{needsFlipping:!0}:null}function Qr(Ee,w,se,it,xt,Dt,Ot,rn,Tn,kn,Bn,Wn,Fr,ri,Zr,Sr,Di){const di=w/24,wi=Ee.lineOffsetX*di,Ti=Ee.lineOffsetY*di;let Oi;if(Ee.numGlyphs>1){const _i=Ee.glyphStartIndex+Ee.numGlyphs,Fi=Ee.lineStartIndex,Ta=Ee.lineStartIndex+Ee.lineLength,Fa=Ur(di,rn,wi,Ti,se,Bn,Wn,Ee,Tn,Dt,Fr,Zr,!1,Sr,Di);if(!Fa)return{notEnoughRoom:!0};const qa=tl(Fa.first.point,Ot).point,ja=tl(Fa.last.point,Ot).point;if(it&&!se){const To=Gn(Ee,qa,ja,ri);if(Ee.flipState=To&&To.needsFlipping?1:2,To)return To}Oi=[Fa.first];for(let To=Ee.glyphStartIndex+1;To<_i-1;To++)Oi.push(no(di*rn.getoffsetX(To),wi,Ti,se,Bn,Wn,Ee.segment,Fi,Ta,Tn,Dt,Fr,Zr,!1,!1,Sr,Di));Oi.push(Fa.last)}else{if(it&&!se){const Fi=tl(Wn,xt).point,Ta=Ee.lineStartIndex+Ee.segment+1,Fa=new m.pointGeometry(Tn.getx(Ta),Tn.gety(Ta)),qa=tl(Fa,xt),ja=Gn(Ee,Fi,qa.signedDistanceFromCamera>0?qa.point:ga(Wn,Fa,Fi,1,xt,void 0,Sr,Di.canonical),ri);if(Ee.flipState=ja&&ja.needsFlipping?1:2,ja)return ja}const _i=no(di*rn.getoffsetX(Ee.glyphStartIndex),wi,Ti,se,Bn,Wn,Ee.segment,Ee.lineStartIndex,Ee.lineStartIndex+Ee.lineLength,Tn,Dt,Fr,Zr,!1,!1,Sr,Di);if(!_i)return{notEnoughRoom:!0};Oi=[_i]}for(const _i of Oi)m.addDynamicAttributes(kn,_i.point,_i.angle);return{}}function qi(Ee,w,se,it,xt){const Dt=it.projectTilePoint(Ee.x,Ee.y,w);if(!xt)return tl(Dt,se,Dt.z);const Ot=xt(Ee);return tl(new m.pointGeometry(Dt.x+Ot[0],Dt.y+Ot[1]),se,Dt.z+Ot[2])}function ga(Ee,w,se,it,xt,Dt,Ot,rn){const Tn=qi(Ee.add(Ee.sub(w)._unit()),rn,xt,Ot,Dt).point,kn=se.sub(Tn);return se.add(kn._mult(it/kn.mag()))}function no(Ee,w,se,it,xt,Dt,Ot,rn,Tn,kn,Bn,Wn,Fr,ri,Zr,Sr,Di){const di=it?Ee-w:Ee+w;let wi=di>0?1:-1,Ti=0;it&&(wi*=-1,Ti=Math.PI),wi<0&&(Ti+=Math.PI);let Oi=wi>0?rn+Ot:rn+Ot+1,_i=xt,Fi=xt,Ta=0,Fa=0;const qa=Math.abs(di),ja=[],To=[];let na=Dt;const Eo=()=>{const hs=Oi-wi;return Ta===0?Dt:new m.pointGeometry(kn.getx(hs),kn.gety(hs))},So=()=>ga(Eo(),na,Fi,qa-Ta+1,Bn,Fr,Sr,Di.canonical);for(;Ta+Fa<=qa;){if(Oi+=wi,Oi<rn||Oi>=Tn)return null;if(Fi=_i,ja.push(_i),ri&&To.push(na||Eo()),_i=Wn[Oi],_i===void 0){na=new m.pointGeometry(kn.getx(Oi),kn.gety(Oi));const hs=qi(na,Di.canonical,Bn,Sr,Fr);_i=hs.signedDistanceFromCamera>0?Wn[Oi]=hs.point:So()}else na=null;Ta+=Fa,Fa=Fi.dist(_i)}Zr&&Fr&&(na=na||new m.pointGeometry(kn.getx(Oi),kn.gety(Oi)),Wn[Oi]=_i=Wn[Oi]===void 0?_i:So(),Fa=Fi.dist(_i));const Qo=(qa-Ta)/Fa,Za=_i.sub(Fi),rs=Za.mult(Qo)._add(Fi);se&&rs._add(Za._unit()._perp()._mult(se*wi));const is=Ti+Math.atan2(_i.y-Fi.y,_i.x-Fi.x);return ja.push(rs),ri&&(na=na||new m.pointGeometry(kn.getx(Oi),kn.gety(Oi)),To.push(function(hs,ps,Js){const fl=1-Js;return new m.pointGeometry(hs.x*fl+ps.x*Js,hs.y*fl+ps.y*Js)}(To.length>0?To[To.length-1]:na,na,Qo))),{point:rs,angle:is,path:ja,tilePath:To}}const mo=new Float32Array([-1/0,-1/0,0,-1/0,-1/0,0,-1/0,-1/0,0,-1/0,-1/0,0]);function Go(Ee,w){for(let se=0;se<Ee;se++){const it=w.length;w.resize(it+4),w.float32.set(mo,3*it)}}function Uo(Ee,w,se){const it=w[0],xt=w[1];return Ee[0]=se[0]*it+se[4]*xt+se[12],Ee[1]=se[1]*it+se[5]*xt+se[13],Ee[3]=se[3]*it+se[7]*xt+se[15],Ee}const Ns=100;class jl{constructor(w,se,it=new xl(w.width+200,w.height+200,25),xt=new xl(w.width+200,w.height+200,25)){this.transform=w,this.grid=it,this.ignoredGrid=xt,this.pitchfactor=Math.cos(w._pitch)*w.cameraToCenterDistance,this.screenRightBoundary=w.width+Ns,this.screenBottomBoundary=w.height+Ns,this.gridRightBoundary=w.width+200,this.gridBottomBoundary=w.height+200,this.fogState=se}placeCollisionBox(w,se,it,xt,Dt,Ot,rn){let Tn=se.projectedAnchorX,kn=se.projectedAnchorY,Bn=se.projectedAnchorZ;const Wn=se.elevation,Fr=se.tileID;if(Wn&&Fr){const Oi=this.transform.projection.upVector(Fr.canonical,se.tileAnchorX,se.tileAnchorY),_i=this.transform.projection.upVectorScale(Fr.canonical,this.transform.center.lat,this.transform.worldSize).metersToTile;Tn+=Oi[0]*Wn*_i,kn+=Oi[1]*Wn*_i,Bn+=Oi[2]*Wn*_i}const ri=this.projectAndGetPerspectiveRatio(Ot,[Tn,kn,Bn],se.tileID,this.transform.projection.name==="globe"||!!Wn||this.transform.pitch>0),Zr=Dt*ri.perspectiveRatio,Sr=(se.x1*w+it.x-se.padding)*Zr+ri.point.x,Di=(se.y1*w+it.y-se.padding)*Zr+ri.point.y,di=(se.x2*w+it.x+se.padding)*Zr+ri.point.x,wi=(se.y2*w+it.y+se.padding)*Zr+ri.point.y,Ti=ri.perspectiveRatio<=.55||ri.occluded;return!this.isInsideGrid(Sr,Di,di,wi)||!xt&&this.grid.hitTest(Sr,Di,di,wi,rn)||Ti?{box:[],offscreen:!1,occluded:ri.occluded}:{box:[Sr,Di,di,wi],offscreen:this.isOffscreen(Sr,Di,di,wi),occluded:!1}}placeCollisionCircles(w,se,it,xt,Dt,Ot,rn,Tn,kn,Bn,Wn,Fr,ri,Zr){const Sr=[],Di=this.transform.elevation,di=Di?Di.getAtTileOffsetFunc(Zr,this.transform.center.lat,this.transform.worldSize,this.transform.projection):So=>[0,0,0],wi=new m.pointGeometry(se.tileAnchorX,se.tileAnchorY),Ti=this.transform.projection.projectTilePoint(se.tileAnchorX,se.tileAnchorY,Zr.canonical),Oi=di(wi),_i=[Ti.x+Oi[0],Ti.y+Oi[1],Ti.z+Oi[2]],Fi=this.projectAndGetPerspectiveRatio(Ot,[_i[0],_i[1],_i[2]],Zr,this.transform.projection.name==="globe"||!!Di||this.transform.pitch>0),{perspectiveRatio:Ta}=Fi,Fa=(Bn?Dt/Ta:Dt*Ta)/m.ONE_EM,qa=tl(new m.pointGeometry(_i[0],_i[1]),rn,_i[2]).point,ja=Fi.signedDistanceFromCamera>0?Ur(Fa,xt,se.lineOffsetX*Fa,se.lineOffsetY*Fa,!1,qa,wi,se,it,rn,{},Di&&!Bn?di:null,Bn&&!!Di,this.transform.projection,Zr):null;let To=!1,na=!1,Eo=!0;if(ja&&!Fi.occluded){const So=.5*Fr*Ta+ri,Qo=new m.pointGeometry(-100,-100),Za=new m.pointGeometry(this.screenRightBoundary,this.screenBottomBoundary),rs=new Xl,is=ja.first,hs=ja.last;let ps=[];for(let as=is.path.length-1;as>=1;as--)ps.push(is.path[as]);for(let as=1;as<hs.path.length;as++)ps.push(hs.path[as]);const Js=2.5*So;if(Tn){const as=ps.map(Di?(ll,Yl)=>{const dc=di(Yl<is.path.length-1?is.tilePath[is.path.length-1-Yl]:hs.tilePath[Yl-is.path.length+2]);return tl(ll,Tn,dc[2])}:ll=>tl(ll,Tn));ps=as.some(ll=>ll.signedDistanceFromCamera<=0)?[]:as.map(ll=>ll.point)}let fl=[];if(ps.length>0){const as=ps[0].clone(),ll=ps[0].clone();for(let Yl=1;Yl<ps.length;Yl++)as.x=Math.min(as.x,ps[Yl].x),as.y=Math.min(as.y,ps[Yl].y),ll.x=Math.max(ll.x,ps[Yl].x),ll.y=Math.max(ll.y,ps[Yl].y);fl=as.x>=Qo.x&&ll.x<=Za.x&&as.y>=Qo.y&&ll.y<=Za.y?[ps]:ll.x<Qo.x||as.x>Za.x||ll.y<Qo.y||as.y>Za.y?[]:m.clipLine([ps],Qo.x,Qo.y,Za.x,Za.y)}for(const as of fl){rs.reset(as,.25*So);let ll=0;ll=rs.length<=.5*So?1:Math.ceil(rs.paddedLength/Js)+1;for(let Yl=0;Yl<ll;Yl++){const dc=Yl/Math.max(ll-1,1),_c=rs.lerp(dc),Bc=_c.x+Ns,Ud=_c.y+Ns;Sr.push(Bc,Ud,So,0);const sh=Bc-So,yh=Ud-So,Bh=Bc+So,Vh=Ud+So;if(Eo=Eo&&this.isOffscreen(sh,yh,Bh,Vh),na=na||this.isInsideGrid(sh,yh,Bh,Vh),!w&&this.grid.hitTestCircle(Bc,Ud,So,Wn)&&(To=!0,!kn))return{circles:[],offscreen:!1,collisionDetected:To,occluded:!1}}}}return{circles:!kn&&To||!na?[]:Sr,offscreen:Eo,collisionDetected:To,occluded:Fi.occluded}}queryRenderedSymbols(w){if(w.length===0||this.grid.keysLength()===0&&this.ignoredGrid.keysLength()===0)return{};const se=[];let it=1/0,xt=1/0,Dt=-1/0,Ot=-1/0;for(const Bn of w){const Wn=new m.pointGeometry(Bn.x+Ns,Bn.y+Ns);it=Math.min(it,Wn.x),xt=Math.min(xt,Wn.y),Dt=Math.max(Dt,Wn.x),Ot=Math.max(Ot,Wn.y),se.push(Wn)}const rn=this.grid.query(it,xt,Dt,Ot).concat(this.ignoredGrid.query(it,xt,Dt,Ot)),Tn={},kn={};for(const Bn of rn){const Wn=Bn.key;if(Tn[Wn.bucketInstanceId]===void 0&&(Tn[Wn.bucketInstanceId]={}),Tn[Wn.bucketInstanceId][Wn.featureIndex])continue;const Fr=[new m.pointGeometry(Bn.x1,Bn.y1),new m.pointGeometry(Bn.x2,Bn.y1),new m.pointGeometry(Bn.x2,Bn.y2),new m.pointGeometry(Bn.x1,Bn.y2)];m.polygonIntersectsPolygon(se,Fr)&&(Tn[Wn.bucketInstanceId][Wn.featureIndex]=!0,kn[Wn.bucketInstanceId]===void 0&&(kn[Wn.bucketInstanceId]=[]),kn[Wn.bucketInstanceId].push(Wn.featureIndex))}return kn}insertCollisionBox(w,se,it,xt,Dt){(se?this.ignoredGrid:this.grid).insert({bucketInstanceId:it,featureIndex:xt,collisionGroupID:Dt},w[0],w[1],w[2],w[3])}insertCollisionCircles(w,se,it,xt,Dt){const Ot=se?this.ignoredGrid:this.grid,rn={bucketInstanceId:it,featureIndex:xt,collisionGroupID:Dt};for(let Tn=0;Tn<w.length;Tn+=4)Ot.insertCircle(rn,w[Tn],w[Tn+1],w[Tn+2])}projectAndGetPerspectiveRatio(w,se,it,xt){const Dt=[se[0],se[1],se[2],1];let Ot=!1;return se[2]||this.transform.pitch>0?(m.transformMat4$1(Dt,Dt,w),this.fogState&&it&&(Ot=function(rn,Tn,kn,Bn,Wn,Fr){const ri=Fr.calculateFogTileMatrix(Wn),Zr=[Tn,kn,Bn];return m.transformMat4(Zr,Zr,ri),_n(rn,Zr,Fr.pitch,Fr._fov)}(this.fogState,se[0],se[1],se[2],it.toUnwrapped(),this.transform)>.9)):Uo(Dt,Dt,w),{point:new m.pointGeometry((Dt[0]/Dt[3]+1)/2*this.transform.width+Ns,(-Dt[1]/Dt[3]+1)/2*this.transform.height+Ns),perspectiveRatio:Math.min(.5+this.transform.cameraToCenterDistance/Dt[3]*.5,1.5),signedDistanceFromCamera:Dt[3],occluded:xt&&Dt[2]>Dt[3]||Ot}}isOffscreen(w,se,it,xt){return it<Ns||w>=this.screenRightBoundary||xt<Ns||se>this.screenBottomBoundary}isInsideGrid(w,se,it,xt){return it>=0&&w<this.gridRightBoundary&&xt>=0&&se<this.gridBottomBoundary}getViewportMatrix(){const w=m.identity([]);return m.translate(w,w,[-100,-100,0]),w}}class Bl{constructor(w,se,it,xt){this.opacity=w?Math.max(0,Math.min(1,w.opacity+(w.placed?se:-se))):xt&&it?1:0,this.placed=it}isHidden(){return this.opacity===0&&!this.placed}}class Jl{constructor(w,se,it,xt,Dt,Ot=!1){this.text=new Bl(w?w.text:null,se,it,Dt),this.icon=new Bl(w?w.icon:null,se,xt,Dt),this.clipped=Ot}isHidden(){return this.text.isHidden()&&this.icon.isHidden()}}class mu{constructor(w,se,it,xt=!1){this.text=w,this.icon=se,this.skipFade=it,this.clipped=xt}}class Ol{constructor(){this.invProjMatrix=m.create(),this.viewportMatrix=m.create(),this.circles=[]}}class bu{constructor(w,se,it,xt,Dt){this.bucketInstanceId=w,this.featureIndex=se,this.sourceLayerIndex=it,this.bucketIndex=xt,this.tileID=Dt}}class Bu{constructor(w){this.crossSourceCollisions=w,this.maxGroupID=0,this.collisionGroups={}}get(w){if(this.crossSourceCollisions)return{ID:0,predicate:null};if(!this.collisionGroups[w]){const se=++this.maxGroupID;this.collisionGroups[w]={ID:se,predicate:it=>it.collisionGroupID===se}}return this.collisionGroups[w]}}function hl(Ee,w,se,it,xt){const{horizontalAlign:Dt,verticalAlign:Ot}=m.getAnchorAlignment(Ee),rn=-(Dt-.5)*w,Tn=-(Ot-.5)*se,kn=m.evaluateVariableOffset(Ee,it);return new m.pointGeometry(rn+kn[0]*xt,Tn+kn[1]*xt)}function vu(Ee,w,se,it,xt){const Dt=new m.pointGeometry(Ee,w);return se&&Dt._rotate(it?xt:-xt),Dt}class Ku{constructor(w,se,it,xt,Dt){this.transform=w.clone(),this.collisionIndex=new jl(this.transform,Dt),this.placements={},this.opacities={},this.variableOffsets={},this.stale=!1,this.commitTime=0,this.fadeDuration=se,this.retainedQueryData={},this.collisionGroups=new Bu(it),this.collisionCircleArrays={},this.prevPlacement=xt,xt&&(xt.prevPlacement=void 0),this.placedOrientations={}}getBucketParts(w,se,it,xt){const Dt=it.getBucket(se),Ot=it.latestFeatureIndex;if(!Dt||!Ot||se.id!==Dt.layerIds[0])return;const rn=Dt.layers[0].layout,Tn=it.collisionBoxArray,kn=Math.pow(2,this.transform.zoom-it.tileID.overscaledZ),Bn=it.tileSize/m.EXTENT,Wn=it.tileID.toUnwrapped(),Fr=this.transform.calculateProjMatrix(Wn),ri=rn.get("text-pitch-alignment")==="map",Zr=rn.get("text-rotation-alignment")==="map";se.compileFilter();const Sr=se.dynamicFilter(),Di=se.dynamicFilterNeedsFeature(),di=this.transform.calculatePixelsToTileUnitsMatrix(it),wi=ju(Fr,it.tileID.canonical,ri,Zr,this.transform,di);let Ti=null;if(ri){const Fi=Pl(Fr,it.tileID.canonical,ri,Zr,this.transform,di);Ti=m.multiply$1([],this.transform.labelPlaneMatrix,Fi)}let Oi=null;Sr&&it.latestFeatureIndex&&(Oi={unwrappedTileID:Wn,dynamicFilter:Sr,dynamicFilterNeedsFeature:Di,featureIndex:it.latestFeatureIndex}),this.retainedQueryData[Dt.bucketInstanceId]=new bu(Dt.bucketInstanceId,Ot,Dt.sourceLayerIndex,Dt.index,it.tileID);const _i={bucket:Dt,layout:rn,posMatrix:Fr,textLabelPlaneMatrix:wi,labelToScreenMatrix:Ti,clippingData:Oi,scale:kn,textPixelRatio:Bn,holdingForFade:it.holdingForFade(),collisionBoxArray:Tn,partiallyEvaluatedTextSize:m.evaluateSizeForZoom(Dt.textSizeData,this.transform.zoom),partiallyEvaluatedIconSize:m.evaluateSizeForZoom(Dt.iconSizeData,this.transform.zoom),collisionGroup:this.collisionGroups.get(Dt.sourceID)};if(xt)for(const Fi of Dt.sortKeyRanges){const{sortKey:Ta,symbolInstanceStart:Fa,symbolInstanceEnd:qa}=Fi;w.push({sortKey:Ta,symbolInstanceStart:Fa,symbolInstanceEnd:qa,parameters:_i})}else w.push({symbolInstanceStart:0,symbolInstanceEnd:Dt.symbolInstances.length,parameters:_i})}attemptAnchorPlacement(w,se,it,xt,Dt,Ot,rn,Tn,kn,Bn,Wn,Fr,ri,Zr,Sr,Di,di,wi){const Ti=[Fr.textOffset0,Fr.textOffset1],Oi=hl(w,it,xt,Ti,Dt),_i=this.collisionIndex.placeCollisionBox(Dt,se,vu(Oi.x,Oi.y,Ot,rn,this.transform.angle),Wn,Tn,kn,Bn.predicate);if((!Di||this.collisionIndex.placeCollisionBox(Zr.getSymbolInstanceIconSize(wi,this.transform.zoom,ri),Di,vu(Oi.x,Oi.y,Ot,rn,this.transform.angle),Wn,Tn,kn,Bn.predicate).box.length!==0)&&_i.box.length>0){let Fi;return this.prevPlacement&&this.prevPlacement.variableOffsets[Fr.crossTileID]&&this.prevPlacement.placements[Fr.crossTileID]&&this.prevPlacement.placements[Fr.crossTileID].text&&(Fi=this.prevPlacement.variableOffsets[Fr.crossTileID].anchor),this.variableOffsets[Fr.crossTileID]={textOffset:Ti,width:it,height:xt,anchor:w,textScale:Dt,prevAnchor:Fi},this.markUsedJustification(Zr,w,Fr,Sr),Zr.allowVerticalPlacement&&(this.markUsedOrientation(Zr,Sr,Fr),this.placedOrientations[Fr.crossTileID]=Sr),{shift:Oi,placedGlyphBoxes:_i}}}placeLayerBucketPart(w,se,it,xt){const{bucket:Dt,layout:Ot,posMatrix:rn,textLabelPlaneMatrix:Tn,labelToScreenMatrix:kn,clippingData:Bn,textPixelRatio:Wn,holdingForFade:Fr,collisionBoxArray:ri,partiallyEvaluatedTextSize:Zr,partiallyEvaluatedIconSize:Sr,collisionGroup:Di}=w.parameters,di=Ot.get("text-optional"),wi=Ot.get("icon-optional"),Ti=Ot.get("text-allow-overlap"),Oi=Ot.get("icon-allow-overlap"),_i=Ot.get("text-rotation-alignment")==="map",Fi=Ot.get("text-pitch-alignment")==="map",Ta=Ot.get("icon-text-fit")!=="none",Fa=Ot.get("symbol-z-order")==="viewport-y";let qa=Ti&&(Oi||!Dt.hasIconData()||wi),ja=Oi&&(Ti||!Dt.hasTextData()||di);!Dt.collisionArrays&&ri&&Dt.deserializeCollisionBoxes(ri),it&&xt&&Dt.updateCollisionDebugBuffers(this.transform.zoom,ri);const To=(na,Eo,So)=>{if(Bn){const Uu={zoom:this.transform.zoom,pitch:this.transform.pitch};let ec=null;if(Bn.dynamicFilterNeedsFeature){const tu=this.retainedQueryData[Dt.bucketInstanceId];ec=Bn.featureIndex.loadFeature({featureIndex:na.featureIndex,bucketIndex:tu.bucketIndex,sourceLayerIndex:tu.sourceLayerIndex,layoutVertexArrayOffset:0})}if(!(0,Bn.dynamicFilter)(Uu,ec,this.retainedQueryData[Dt.bucketInstanceId].tileID.canonical,new m.pointGeometry(na.tileAnchorX,na.tileAnchorY),this.transform.calculateDistanceTileData(Bn.unwrappedTileID)))return this.placements[na.crossTileID]=new mu(!1,!1,!1,!0),void(se[na.crossTileID]=!0)}if(se[na.crossTileID])return;if(Fr)return void(this.placements[na.crossTileID]=new mu(!1,!1,!1));let Qo=!1,Za=!1,rs=!0,is=!1,hs=!1,ps=null,Js={box:null,offscreen:null,occluded:null},fl={box:null,offscreen:null,occluded:null},as=null,ll=null,Yl=null,dc=0,_c=0,Bc=0;So.textFeatureIndex?dc=So.textFeatureIndex:na.useRuntimeCollisionCircles&&(dc=na.featureIndex),So.verticalTextFeatureIndex&&(_c=So.verticalTextFeatureIndex);const Ud=Uu=>{Uu.tileID=this.retainedQueryData[Dt.bucketInstanceId].tileID,(this.transform.elevation||Uu.elevation)&&(Uu.elevation=this.transform.elevation?this.transform.elevation.getAtTileOffset(this.retainedQueryData[Dt.bucketInstanceId].tileID,Uu.tileAnchorX,Uu.tileAnchorY):0)},sh=So.textBox;if(sh){Ud(sh);const Uu=tu=>{let tc=m.WritingMode.horizontal;if(Dt.allowVerticalPlacement&&!tu&&this.prevPlacement){const fd=this.prevPlacement.placedOrientations[na.crossTileID];fd&&(this.placedOrientations[na.crossTileID]=fd,tc=fd,this.markUsedOrientation(Dt,tc,na))}return tc},ec=(tu,tc)=>{if(Dt.allowVerticalPlacement&&na.numVerticalGlyphVertices>0&&So.verticalTextBox){for(const fd of Dt.writingModes)if(fd===m.WritingMode.vertical?(Js=tc(),fl=Js):Js=tu(),Js&&Js.box&&Js.box.length)break}else Js=tu()};if(Ot.get("text-variable-anchor")){let tu=Ot.get("text-variable-anchor");if(this.prevPlacement&&this.prevPlacement.variableOffsets[na.crossTileID]){const Yu=this.prevPlacement.variableOffsets[na.crossTileID];tu.indexOf(Yu.anchor)>0&&(tu=tu.filter(Tc=>Tc!==Yu.anchor),tu.unshift(Yu.anchor))}const tc=(Yu,Tc,$d)=>{const Vc=Dt.getSymbolInstanceTextSize(Zr,na,this.transform.zoom,Eo),lh=(Yu.x2-Yu.x1)*Vc+2*Yu.padding,gp=(Yu.y2-Yu.y1)*Vc+2*Yu.padding,jp=Ta&&!Oi?Tc:null;jp&&Ud(jp);let uh={box:[],offscreen:!1,occluded:!1};const lf=Ti?2*tu.length:tu.length;for(let Hd=0;Hd<lf;++Hd){const tp=this.attemptAnchorPlacement(tu[Hd%tu.length],Yu,lh,gp,Vc,_i,Fi,Wn,rn,Di,Hd>=tu.length,na,Eo,Dt,$d,jp,Zr,Sr);if(tp&&(uh=tp.placedGlyphBoxes,uh&&uh.box&&uh.box.length)){Qo=!0,ps=tp.shift;break}}return uh};ec(()=>tc(sh,So.iconBox,m.WritingMode.horizontal),()=>{const Yu=So.verticalTextBox;return Yu&&Ud(Yu),Dt.allowVerticalPlacement&&!(Js&&Js.box&&Js.box.length)&&na.numVerticalGlyphVertices>0&&Yu?tc(Yu,So.verticalIconBox,m.WritingMode.vertical):{box:null,offscreen:null,occluded:null}}),Js&&(Qo=Js.box,rs=Js.offscreen,is=Js.occluded);const fd=Uu(Js&&Js.box);if(!Qo&&this.prevPlacement){const Yu=this.prevPlacement.variableOffsets[na.crossTileID];Yu&&(this.variableOffsets[na.crossTileID]=Yu,this.markUsedJustification(Dt,Yu.anchor,na,fd))}}else{const tu=(tc,fd)=>{const Yu=Dt.getSymbolInstanceTextSize(Zr,na,this.transform.zoom,Eo),Tc=this.collisionIndex.placeCollisionBox(Yu,tc,new m.pointGeometry(0,0),Ti,Wn,rn,Di.predicate);return Tc&&Tc.box&&Tc.box.length&&(this.markUsedOrientation(Dt,fd,na),this.placedOrientations[na.crossTileID]=fd),Tc};ec(()=>tu(sh,m.WritingMode.horizontal),()=>{const tc=So.verticalTextBox;return Dt.allowVerticalPlacement&&na.numVerticalGlyphVertices>0&&tc?(Ud(tc),tu(tc,m.WritingMode.vertical)):{box:null,offscreen:null,occluded:null}}),Uu(Js&&Js.box&&Js.box.length)}}if(as=Js,Qo=as&&as.box&&as.box.length>0,rs=as&&as.offscreen,is=as&&as.occluded,na.useRuntimeCollisionCircles){const Uu=Dt.text.placedSymbolArray.get(na.centerJustifiedTextSymbolIndex>=0?na.centerJustifiedTextSymbolIndex:na.verticalPlacedTextSymbolIndex),ec=m.evaluateSizeForFeature(Dt.textSizeData,Zr,Uu),tu=Ot.get("text-padding");ll=this.collisionIndex.placeCollisionCircles(Ti,Uu,Dt.lineVertexArray,Dt.glyphOffsetArray,ec,rn,Tn,kn,it,Fi,Di.predicate,na.collisionCircleDiameter*ec/m.ONE_EM,tu,this.retainedQueryData[Dt.bucketInstanceId].tileID),Qo=Ti||ll.circles.length>0&&!ll.collisionDetected,rs=rs&&ll.offscreen,is=ll.occluded}if(So.iconFeatureIndex&&(Bc=So.iconFeatureIndex),So.iconBox){const Uu=ec=>{Ud(ec);const tu=Ta&&ps?vu(ps.x,ps.y,_i,Fi,this.transform.angle):new m.pointGeometry(0,0),tc=Dt.getSymbolInstanceIconSize(Sr,this.transform.zoom,Eo);return this.collisionIndex.placeCollisionBox(tc,ec,tu,Oi,Wn,rn,Di.predicate)};fl&&fl.box&&fl.box.length&&So.verticalIconBox?(Yl=Uu(So.verticalIconBox),Za=Yl.box.length>0):(Yl=Uu(So.iconBox),Za=Yl.box.length>0),rs=rs&&Yl.offscreen,hs=Yl.occluded}const yh=di||na.numHorizontalGlyphVertices===0&&na.numVerticalGlyphVertices===0,Bh=wi||na.numIconVertices===0;if(yh||Bh?Bh?yh||(Za=Za&&Qo):Qo=Za&&Qo:Za=Qo=Za&&Qo,Qo&&as&&as.box&&this.collisionIndex.insertCollisionBox(as.box,Ot.get("text-ignore-placement"),Dt.bucketInstanceId,fl&&fl.box&&_c?_c:dc,Di.ID),Za&&Yl&&this.collisionIndex.insertCollisionBox(Yl.box,Ot.get("icon-ignore-placement"),Dt.bucketInstanceId,Bc,Di.ID),ll&&(Qo&&this.collisionIndex.insertCollisionCircles(ll.circles,Ot.get("text-ignore-placement"),Dt.bucketInstanceId,dc,Di.ID),it)){const Uu=Dt.bucketInstanceId;let ec=this.collisionCircleArrays[Uu];ec===void 0&&(ec=this.collisionCircleArrays[Uu]=new Ol);for(let tu=0;tu<ll.circles.length;tu+=4)ec.circles.push(ll.circles[tu+0]),ec.circles.push(ll.circles[tu+1]),ec.circles.push(ll.circles[tu+2]),ec.circles.push(ll.collisionDetected?1:0)}const Vh=this.transform.projection.name!=="globe";qa=qa&&(Vh||!is),ja=ja&&(Vh||!hs),this.placements[na.crossTileID]=new mu(Qo||qa,Za||ja,rs||Dt.justReloaded),se[na.crossTileID]=!0};if(Fa){const na=Dt.getSortedSymbolIndexes(this.transform.angle);for(let Eo=na.length-1;Eo>=0;--Eo){const So=na[Eo];To(Dt.symbolInstances.get(So),So,Dt.collisionArrays[So])}}else for(let na=w.symbolInstanceStart;na<w.symbolInstanceEnd;na++)To(Dt.symbolInstances.get(na),na,Dt.collisionArrays[na]);if(it&&Dt.bucketInstanceId in this.collisionCircleArrays){const na=this.collisionCircleArrays[Dt.bucketInstanceId];m.invert(na.invProjMatrix,rn),na.viewportMatrix=this.collisionIndex.getViewportMatrix()}Dt.justReloaded=!1}markUsedJustification(w,se,it,xt){let Dt;Dt=xt===m.WritingMode.vertical?it.verticalPlacedTextSymbolIndex:{left:it.leftJustifiedTextSymbolIndex,center:it.centerJustifiedTextSymbolIndex,right:it.rightJustifiedTextSymbolIndex}[m.getAnchorJustification(se)];const Ot=[it.leftJustifiedTextSymbolIndex,it.centerJustifiedTextSymbolIndex,it.rightJustifiedTextSymbolIndex,it.verticalPlacedTextSymbolIndex];for(const rn of Ot)rn>=0&&(w.text.placedSymbolArray.get(rn).crossTileID=Dt>=0&&rn!==Dt?0:it.crossTileID)}markUsedOrientation(w,se,it){const xt=se===m.WritingMode.horizontal||se===m.WritingMode.horizontalOnly?se:0,Dt=se===m.WritingMode.vertical?se:0,Ot=[it.leftJustifiedTextSymbolIndex,it.centerJustifiedTextSymbolIndex,it.rightJustifiedTextSymbolIndex];for(const rn of Ot)w.text.placedSymbolArray.get(rn).placedOrientation=xt;it.verticalPlacedTextSymbolIndex&&(w.text.placedSymbolArray.get(it.verticalPlacedTextSymbolIndex).placedOrientation=Dt)}commit(w){this.commitTime=w,this.zoomAtLastRecencyCheck=this.transform.zoom;const se=this.prevPlacement;let it=!1;this.prevZoomAdjustment=se?se.zoomAdjustment(this.transform.zoom):0;const xt=se?se.symbolFadeChange(w):1,Dt=se?se.opacities:{},Ot=se?se.variableOffsets:{},rn=se?se.placedOrientations:{};for(const Tn in this.placements){const kn=this.placements[Tn],Bn=Dt[Tn];Bn?(this.opacities[Tn]=new Jl(Bn,xt,kn.text,kn.icon,null,kn.clipped),it=it||kn.text!==Bn.text.placed||kn.icon!==Bn.icon.placed):(this.opacities[Tn]=new Jl(null,xt,kn.text,kn.icon,kn.skipFade,kn.clipped),it=it||kn.text||kn.icon)}for(const Tn in Dt){const kn=Dt[Tn];if(!this.opacities[Tn]){const Bn=new Jl(kn,xt,!1,!1);Bn.isHidden()||(this.opacities[Tn]=Bn,it=it||kn.text.placed||kn.icon.placed)}}for(const Tn in Ot)this.variableOffsets[Tn]||!this.opacities[Tn]||this.opacities[Tn].isHidden()||(this.variableOffsets[Tn]=Ot[Tn]);for(const Tn in rn)this.placedOrientations[Tn]||!this.opacities[Tn]||this.opacities[Tn].isHidden()||(this.placedOrientations[Tn]=rn[Tn]);it?this.lastPlacementChangeTime=w:typeof this.lastPlacementChangeTime!="number"&&(this.lastPlacementChangeTime=se?se.lastPlacementChangeTime:w)}updateLayerOpacities(w,se){const it={};for(const xt of se){const Dt=xt.getBucket(w);Dt&&xt.latestFeatureIndex&&w.id===Dt.layerIds[0]&&this.updateBucketOpacities(Dt,it,xt.collisionBoxArray)}}updateBucketOpacities(w,se,it){w.hasTextData()&&w.text.opacityVertexArray.clear(),w.hasIconData()&&w.icon.opacityVertexArray.clear(),w.hasIconCollisionBoxData()&&w.iconCollisionBox.collisionVertexArray.clear(),w.hasTextCollisionBoxData()&&w.textCollisionBox.collisionVertexArray.clear();const xt=w.layers[0].layout,Dt=!!w.layers[0].dynamicFilter(),Ot=new Jl(null,0,!1,!1,!0),rn=xt.get("text-allow-overlap"),Tn=xt.get("icon-allow-overlap"),kn=xt.get("text-variable-anchor"),Bn=xt.get("text-rotation-alignment")==="map",Wn=xt.get("text-pitch-alignment")==="map",Fr=xt.get("icon-text-fit")!=="none",ri=new Jl(null,0,rn&&(Tn||!w.hasIconData()||xt.get("icon-optional")),Tn&&(rn||!w.hasTextData()||xt.get("text-optional")),!0);!w.collisionArrays&&it&&(w.hasIconCollisionBoxData()||w.hasTextCollisionBoxData())&&w.deserializeCollisionBoxes(it);const Zr=(Di,di,wi)=>{for(let Ti=0;Ti<di/4;Ti++)Di.opacityVertexArray.emplaceBack(wi)};let Sr=0;for(let Di=0;Di<w.symbolInstances.length;Di++){const di=w.symbolInstances.get(Di),{numHorizontalGlyphVertices:wi,numVerticalGlyphVertices:Ti,crossTileID:Oi}=di;let _i=this.opacities[Oi];se[Oi]?_i=Ot:_i||(_i=ri,this.opacities[Oi]=_i),se[Oi]=!0;const Fi=wi>0||Ti>0,Ta=di.numIconVertices>0,Fa=this.placedOrientations[di.crossTileID],qa=Fa===m.WritingMode.vertical,ja=Fa===m.WritingMode.horizontal||Fa===m.WritingMode.horizontalOnly;if(!Fi&&!Ta||_i.isHidden()||Sr++,Fi){const To=Ql(_i.text);Zr(w.text,wi,qa?Ll:To),Zr(w.text,Ti,ja?Ll:To);const na=_i.text.isHidden();[di.rightJustifiedTextSymbolIndex,di.centerJustifiedTextSymbolIndex,di.leftJustifiedTextSymbolIndex].forEach(Qo=>{Qo>=0&&(w.text.placedSymbolArray.get(Qo).hidden=na||qa?1:0)}),di.verticalPlacedTextSymbolIndex>=0&&(w.text.placedSymbolArray.get(di.verticalPlacedTextSymbolIndex).hidden=na||ja?1:0);const Eo=this.variableOffsets[di.crossTileID];Eo&&this.markUsedJustification(w,Eo.anchor,di,Fa);const So=this.placedOrientations[di.crossTileID];So&&(this.markUsedJustification(w,"left",di,So),this.markUsedOrientation(w,So,di))}if(Ta){const To=Ql(_i.icon);di.placedIconSymbolIndex>=0&&(Zr(w.icon,di.numIconVertices,qa?Ll:To),w.icon.placedSymbolArray.get(di.placedIconSymbolIndex).hidden=_i.icon.isHidden()),di.verticalPlacedIconSymbolIndex>=0&&(Zr(w.icon,di.numVerticalIconVertices,ja?Ll:To),w.icon.placedSymbolArray.get(di.verticalPlacedIconSymbolIndex).hidden=_i.icon.isHidden())}if(w.hasIconCollisionBoxData()||w.hasTextCollisionBoxData()){const To=w.collisionArrays[Di];if(To){let na=new m.pointGeometry(0,0),Eo=!0;if(To.textBox||To.verticalTextBox){if(kn){const Qo=this.variableOffsets[Oi];Qo?(na=hl(Qo.anchor,Qo.width,Qo.height,Qo.textOffset,Qo.textScale),Bn&&na._rotate(Wn?this.transform.angle:-this.transform.angle)):Eo=!1}Dt&&(Eo=!_i.clipped),To.textBox&&Ul(w.textCollisionBox.collisionVertexArray,_i.text.placed,!Eo||qa,na.x,na.y),To.verticalTextBox&&Ul(w.textCollisionBox.collisionVertexArray,_i.text.placed,!Eo||ja,na.x,na.y)}const So=Eo&&!!(!ja&&To.verticalIconBox);To.iconBox&&Ul(w.iconCollisionBox.collisionVertexArray,_i.icon.placed,So,Fr?na.x:0,Fr?na.y:0),To.verticalIconBox&&Ul(w.iconCollisionBox.collisionVertexArray,_i.icon.placed,!So,Fr?na.x:0,Fr?na.y:0)}}}if(w.fullyClipped=Sr===0,w.sortFeatures(this.transform.angle),this.retainedQueryData[w.bucketInstanceId]&&(this.retainedQueryData[w.bucketInstanceId].featureSortOrder=w.featureSortOrder),w.hasTextData()&&w.text.opacityVertexBuffer&&w.text.opacityVertexBuffer.updateData(w.text.opacityVertexArray),w.hasIconData()&&w.icon.opacityVertexBuffer&&w.icon.opacityVertexBuffer.updateData(w.icon.opacityVertexArray),w.hasIconCollisionBoxData()&&w.iconCollisionBox.collisionVertexBuffer&&w.iconCollisionBox.collisionVertexBuffer.updateData(w.iconCollisionBox.collisionVertexArray),w.hasTextCollisionBoxData()&&w.textCollisionBox.collisionVertexBuffer&&w.textCollisionBox.collisionVertexBuffer.updateData(w.textCollisionBox.collisionVertexArray),w.bucketInstanceId in this.collisionCircleArrays){const Di=this.collisionCircleArrays[w.bucketInstanceId];w.placementInvProjMatrix=Di.invProjMatrix,w.placementViewportMatrix=Di.viewportMatrix,w.collisionCircleArray=Di.circles,delete this.collisionCircleArrays[w.bucketInstanceId]}}symbolFadeChange(w){return this.fadeDuration===0?1:(w-this.commitTime)/this.fadeDuration+this.prevZoomAdjustment}zoomAdjustment(w){return Math.max(0,(this.transform.zoom-w)/1.5)}hasTransitions(w){return this.stale||w-this.lastPlacementChangeTime<this.fadeDuration}stillRecent(w,se){const it=this.zoomAtLastRecencyCheck===se?1-this.zoomAdjustment(se):1;return this.zoomAtLastRecencyCheck=se,this.commitTime+this.fadeDuration*it>w}setStale(){this.stale=!0}}function Ul(Ee,w,se,it,xt){Ee.emplaceBack(w?1:0,se?1:0,it||0,xt||0),Ee.emplaceBack(w?1:0,se?1:0,it||0,xt||0),Ee.emplaceBack(w?1:0,se?1:0,it||0,xt||0),Ee.emplaceBack(w?1:0,se?1:0,it||0,xt||0)}const ad=Math.pow(2,25),jc=Math.pow(2,24),js=Math.pow(2,17),co=Math.pow(2,16),Vl=Math.pow(2,9),Gc=Math.pow(2,8),yd=Math.pow(2,1);function Ql(Ee){if(Ee.opacity===0&&!Ee.placed)return 0;if(Ee.opacity===1&&Ee.placed)return 4294967295;const w=Ee.placed?1:0,se=Math.floor(127*Ee.opacity);return se*ad+w*jc+se*js+w*co+se*Vl+w*Gc+se*yd+w}const Ll=0;class Au{constructor(w){this._sortAcrossTiles=w.layout.get("symbol-z-order")!=="viewport-y"&&w.layout.get("symbol-sort-key").constantOr(1)!==void 0,this._currentTileIndex=0,this._currentPartIndex=0,this._seenCrossTileIDs={},this._bucketParts=[]}continuePlacement(w,se,it,xt,Dt){const Ot=this._bucketParts;for(;this._currentTileIndex<w.length;)if(se.getBucketParts(Ot,xt,w[this._currentTileIndex],this._sortAcrossTiles),this._currentTileIndex++,Dt())return!0;for(this._sortAcrossTiles&&(this._sortAcrossTiles=!1,Ot.sort((rn,Tn)=>rn.sortKey-Tn.sortKey));this._currentPartIndex<Ot.length;){const rn=Ot[this._currentPartIndex];if(se.placeLayerBucketPart(rn,this._seenCrossTileIDs,it,rn.symbolInstanceStart===0),this._currentPartIndex++,Dt())return!0}return!1}}class jd{constructor(w,se,it,xt,Dt,Ot,rn,Tn){this.placement=new Ku(w,Dt,Ot,rn,Tn),this._currentPlacementIndex=se.length-1,this._forceFullPlacement=it,this._showCollisionBoxes=xt,this._done=!1}isDone(){return this._done}continuePlacement(w,se,it){const xt=m.exported.now(),Dt=()=>{const Ot=m.exported.now()-xt;return!this._forceFullPlacement&&Ot>2};for(;this._currentPlacementIndex>=0;){const Ot=se[w[this._currentPlacementIndex]],rn=this.placement.collisionIndex.transform.zoom;if(Ot.type==="symbol"&&(!Ot.minzoom||Ot.minzoom<=rn)&&(!Ot.maxzoom||Ot.maxzoom>rn)){if(this._inProgressLayer||(this._inProgressLayer=new Au(Ot)),this._inProgressLayer.continuePlacement(it[Ot.source],this.placement,this._showCollisionBoxes,Ot,Dt))return;delete this._inProgressLayer}this._currentPlacementIndex--}this._done=!0}commit(w){return this.placement.commit(w),this.placement}}const Wu=512/m.EXTENT/2;class ud{constructor(w,se,it){this.tileID=w,this.indexedSymbolInstances={},this.bucketInstanceId=it;for(let xt=0;xt<se.length;xt++){const Dt=se.get(xt),Ot=Dt.key;this.indexedSymbolInstances[Ot]||(this.indexedSymbolInstances[Ot]=[]),this.indexedSymbolInstances[Ot].push({crossTileID:Dt.crossTileID,coord:this.getScaledCoordinates(Dt,w)})}}getScaledCoordinates(w,se){const it=Wu/Math.pow(2,se.canonical.z-this.tileID.canonical.z);return{x:Math.floor((se.canonical.x*m.EXTENT+w.tileAnchorX)*it),y:Math.floor((se.canonical.y*m.EXTENT+w.tileAnchorY)*it)}}findMatches(w,se,it){const xt=this.tileID.canonical.z<se.canonical.z?1:Math.pow(2,this.tileID.canonical.z-se.canonical.z);for(let Dt=0;Dt<w.length;Dt++){const Ot=w.get(Dt);if(Ot.crossTileID)continue;const rn=this.indexedSymbolInstances[Ot.key];if(!rn)continue;const Tn=this.getScaledCoordinates(Ot,se);for(const kn of rn)if(Math.abs(kn.coord.x-Tn.x)<=xt&&Math.abs(kn.coord.y-Tn.y)<=xt&&!it[kn.crossTileID]){it[kn.crossTileID]=!0,Ot.crossTileID=kn.crossTileID;break}}}}class Xc{constructor(){this.maxCrossTileID=0}generate(){return++this.maxCrossTileID}}class yi{constructor(){this.indexes={},this.usedCrossTileIDs={},this.lng=0}handleWrapJump(w){const se=Math.round((w-this.lng)/360);if(se!==0)for(const it in this.indexes){const xt=this.indexes[it],Dt={};for(const Ot in xt){const rn=xt[Ot];rn.tileID=rn.tileID.unwrapTo(rn.tileID.wrap+se),Dt[rn.tileID.key]=rn}this.indexes[it]=Dt}this.lng=w}addBucket(w,se,it){if(this.indexes[w.overscaledZ]&&this.indexes[w.overscaledZ][w.key]){if(this.indexes[w.overscaledZ][w.key].bucketInstanceId===se.bucketInstanceId)return!1;this.removeBucketCrossTileIDs(w.overscaledZ,this.indexes[w.overscaledZ][w.key])}for(let Dt=0;Dt<se.symbolInstances.length;Dt++)se.symbolInstances.get(Dt).crossTileID=0;this.usedCrossTileIDs[w.overscaledZ]||(this.usedCrossTileIDs[w.overscaledZ]={});const xt=this.usedCrossTileIDs[w.overscaledZ];for(const Dt in this.indexes){const Ot=this.indexes[Dt];if(Number(Dt)>w.overscaledZ)for(const rn in Ot){const Tn=Ot[rn];Tn.tileID.isChildOf(w)&&Tn.findMatches(se.symbolInstances,w,xt)}else{const rn=Ot[w.scaledTo(Number(Dt)).key];rn&&rn.findMatches(se.symbolInstances,w,xt)}}for(let Dt=0;Dt<se.symbolInstances.length;Dt++){const Ot=se.symbolInstances.get(Dt);Ot.crossTileID||(Ot.crossTileID=it.generate(),xt[Ot.crossTileID]=!0)}return this.indexes[w.overscaledZ]===void 0&&(this.indexes[w.overscaledZ]={}),this.indexes[w.overscaledZ][w.key]=new ud(w,se.symbolInstances,se.bucketInstanceId),!0}removeBucketCrossTileIDs(w,se){for(const it in se.indexedSymbolInstances)for(const xt of se.indexedSymbolInstances[it])delete this.usedCrossTileIDs[w][xt.crossTileID]}removeStaleBuckets(w){let se=!1;for(const it in this.indexes){const xt=this.indexes[it];for(const Dt in xt)w[xt[Dt].bucketInstanceId]||(this.removeBucketCrossTileIDs(it,xt[Dt]),delete xt[Dt],se=!0)}return se}}class mc{constructor(){this.layerIndexes={},this.crossTileIDs=new Xc,this.maxBucketInstanceId=0,this.bucketsInCurrentPlacement={}}addLayer(w,se,it,xt){let Dt=this.layerIndexes[w.id];Dt===void 0&&(Dt=this.layerIndexes[w.id]=new yi);let Ot=!1;const rn={};xt.name!=="globe"&&Dt.handleWrapJump(it);for(const Tn of se){const kn=Tn.getBucket(w);kn&&w.id===kn.layerIds[0]&&(kn.bucketInstanceId||(kn.bucketInstanceId=++this.maxBucketInstanceId),Dt.addBucket(Tn.tileID,kn,this.crossTileIDs)&&(Ot=!0),rn[kn.bucketInstanceId]=!0)}return Dt.removeStaleBuckets(rn)&&(Ot=!0),Ot}pruneUnusedLayers(w){const se={};w.forEach(it=>{se[it]=!0});for(const it in this.layerIndexes)se[it]||delete this.layerIndexes[it]}}const Su=(Ee,w)=>m.emitValidationErrors(Ee,w&&w.filter(se=>se.identifier!=="source.canvas")),Yh=m.pick(ao,["addLayer","removeLayer","setPaintProperty","setLayoutProperty","setFilter","addSource","removeSource","setLayerZoomRange","setLight","setTransition","setGeoJSONSourceData","setTerrain","setFog","setProjection"]),ka=m.pick(ao,["setCenter","setZoom","setBearing","setPitch"]),pl={version:8,layers:[],sources:{}},Il={fill:!0,line:!0,background:!0,hillshade:!0,raster:!0};class Ss extends m.Evented{constructor(w,se={}){super(),this.map=w,this.dispatcher=new wn(Wo(),this),this.imageManager=new mt,this.imageManager.setEventedParent(this),this.glyphManager=new m.GlyphManager(w._requestManager,se.localFontFamily?m.LocalGlyphMode.all:se.localIdeographFontFamily?m.LocalGlyphMode.ideographs:m.LocalGlyphMode.none,se.localFontFamily||se.localIdeographFontFamily),this.lineAtlas=new m.LineAtlas(256,512),this.crossTileSymbolIndex=new mc,this._layers={},this._num3DLayers=0,this._numSymbolLayers=0,this._numCircleLayers=0,this._serializedLayers={},this._sourceCaches={},this._otherSourceCaches={},this._symbolSourceCaches={},this.zoomHistory=new m.ZoomHistory,this._loaded=!1,this._availableImages=[],this._order=[],this._drapedFirstOrder=[],this._markersNeedUpdate=!1,this._resetUpdates(),this.dispatcher.broadcast("setReferrer",m.getReferrer());const it=this;this._rtlTextPluginCallback=Ss.registerForPluginStateChange(xt=>{it.dispatcher.broadcast("syncRTLPluginState",{pluginStatus:xt.pluginStatus,pluginURL:xt.pluginURL},(Dt,Ot)=>{if(m.triggerPluginCompletionEvent(Dt),Ot&&Ot.every(rn=>rn))for(const rn in it._sourceCaches){const Tn=it._sourceCaches[rn],kn=Tn.getSource().type;kn!=="vector"&&kn!=="geojson"||Tn.reload()}})}),this.on("data",xt=>{if(xt.dataType!=="source"||xt.sourceDataType!=="metadata")return;const Dt=this.getSource(xt.sourceId);if(Dt&&Dt.vectorLayerIds)for(const Ot in this._layers){const rn=this._layers[Ot];rn.source===Dt.id&&this._validateLayer(rn)}})}loadURL(w,se={}){this.fire(new m.Event("dataloading",{dataType:"style"}));const it=typeof se.validate=="boolean"?se.validate:!m.isMapboxURL(w);w=this.map._requestManager.normalizeStyleURL(w,se.accessToken);const xt=this.map._requestManager.transformRequest(w,m.ResourceType.Style);this._request=m.getJSON(xt,(Dt,Ot)=>{this._request=null,Dt?this.fire(new m.ErrorEvent(Dt)):Ot&&this._load(Ot,it)})}loadJSON(w,se={}){this.fire(new m.Event("dataloading",{dataType:"style"})),this._request=m.exported.frame(()=>{this._request=null,this._load(w,se.validate!==!1)})}loadEmpty(){this.fire(new m.Event("dataloading",{dataType:"style"})),this._load(pl,!1)}_updateLayerCount(w,se){const it=se?1:-1;w.is3D()&&(this._num3DLayers+=it),w.type==="circle"&&(this._numCircleLayers+=it),w.type==="symbol"&&(this._numSymbolLayers+=it)}_load(w,se){if(se&&Su(this,m.validateStyle(w)))return;this._loaded=!0,this.stylesheet=w,this._updateMapProjection();for(const xt in w.sources)this.addSource(xt,w.sources[xt],{validate:!1});this._changed=!1,w.sprite?this._loadSprite(w.sprite):(this.imageManager.setLoaded(!0),this.dispatcher.broadcast("spriteLoaded",!0)),this.glyphManager.setURL(w.glyphs);const it=$s(this.stylesheet.layers);this._order=it.map(xt=>xt.id),this._layers={},this._serializedLayers={};for(let xt of it)xt=m.createStyleLayer(xt),xt.setEventedParent(this,{layer:{id:xt.id}}),this._layers[xt.id]=xt,this._serializedLayers[xt.id]=xt.serialize(),this._updateLayerCount(xt,!0);this.dispatcher.broadcast("setLayers",this._serializeLayers(this._order)),this.light=new It(this.stylesheet.light),this.stylesheet.terrain&&!this.terrainSetForDrapingOnly()&&this._createTerrain(this.stylesheet.terrain,1),this.stylesheet.fog&&this._createFog(this.stylesheet.fog),this._updateDrapeFirstLayers(),this.fire(new m.Event("data",{dataType:"style"})),this.fire(new m.Event("style.load"))}terrainSetForDrapingOnly(){return!!this.terrain&&this.terrain.drapeRenderMode===0}setProjection(w){w?this.stylesheet.projection=w:delete this.stylesheet.projection,this.map._explicitProjection||this.map._updateProjection()}_updateMapProjection(){this.map._explicitProjection?this.applyProjectionUpdate():this.map._updateProjection()}applyProjectionUpdate(){this._loaded&&(this.dispatcher.broadcast("setProjection",this.map.transform.projectionOptions),this.map.transform.projection.requiresDraping?this.getTerrain()||this.stylesheet.terrain||this.setTerrainForDraping():this.terrainSetForDrapingOnly()&&this.setTerrain(null))}_loadSprite(w){this._spriteRequest=function(se,it,xt){let Dt,Ot,rn;const Tn=m.exported.devicePixelRatio>1?"@2x":"";let kn=m.getJSON(it.transformRequest(it.normalizeSpriteURL(se,Tn,".json"),m.ResourceType.SpriteJSON),(Fr,ri)=>{kn=null,rn||(rn=Fr,Dt=ri,Wn())}),Bn=m.getImage(it.transformRequest(it.normalizeSpriteURL(se,Tn,".png"),m.ResourceType.SpriteImage),(Fr,ri)=>{Bn=null,rn||(rn=Fr,Ot=ri,Wn())});function Wn(){if(rn)xt(rn);else if(Dt&&Ot){const Fr=m.exported.getImageData(Ot),ri={};for(const Zr in Dt){const{width:Sr,height:Di,x:di,y:wi,sdf:Ti,pixelRatio:Oi,stretchX:_i,stretchY:Fi,content:Ta}=Dt[Zr],Fa=new m.RGBAImage({width:Sr,height:Di});m.RGBAImage.copy(Fr,Fa,{x:di,y:wi},{x:0,y:0},{width:Sr,height:Di}),ri[Zr]={data:Fa,pixelRatio:Oi,sdf:Ti,stretchX:_i,stretchY:Fi,content:Ta}}xt(null,ri)}}return{cancel(){kn&&(kn.cancel(),kn=null),Bn&&(Bn.cancel(),Bn=null)}}}(w,this.map._requestManager,(se,it)=>{if(this._spriteRequest=null,se)this.fire(new m.ErrorEvent(se));else if(it)for(const xt in it)this.imageManager.addImage(xt,it[xt]);this.imageManager.setLoaded(!0),this._availableImages=this.imageManager.listImages(),this.dispatcher.broadcast("setImages",this._availableImages),this.dispatcher.broadcast("spriteLoaded",!0),this.fire(new m.Event("data",{dataType:"style"}))})}_validateLayer(w){const se=this.getSource(w.source);if(!se)return;const it=w.sourceLayer;it&&(se.type==="geojson"||se.vectorLayerIds&&se.vectorLayerIds.indexOf(it)===-1)&&this.fire(new m.ErrorEvent(new Error(`Source layer "${it}" does not exist on source "${se.id}" as specified by style layer "${w.id}"`)))}loaded(){if(!this._loaded||Object.keys(this._updatedSources).length)return!1;for(const w in this._sourceCaches)if(!this._sourceCaches[w].loaded())return!1;return!!this.imageManager.isLoaded()}_serializeLayers(w){const se=[];for(const it of w){const xt=this._layers[it];xt.type!=="custom"&&se.push(xt.serialize())}return se}hasTransitions(){if(this.light&&this.light.hasTransition()||this.fog&&this.fog.hasTransition())return!0;for(const w in this._sourceCaches)if(this._sourceCaches[w].hasTransition())return!0;for(const w in this._layers)if(this._layers[w].hasTransition())return!0;return!1}get order(){return this.map._optimizeForTerrain&&this.terrain?this._drapedFirstOrder:this._order}isLayerDraped(w){return!!this.terrain&&Il[w.type]}_checkLoaded(){if(!this._loaded)throw new Error("Style is not done loading")}update(w){if(!this._loaded)return;const se=this._changed;if(this._changed){const xt=Object.keys(this._updatedLayers),Dt=Object.keys(this._removedLayers);(xt.length||Dt.length)&&this._updateWorkerLayers(xt,Dt);for(const Ot in this._updatedSources){const rn=this._updatedSources[Ot];rn==="reload"?this._reloadSource(Ot):rn==="clear"&&this._clearSource(Ot)}this._updateTilesForChangedImages();for(const Ot in this._updatedPaintProps)this._layers[Ot].updateTransitions(w);this.light.updateTransitions(w),this.fog&&this.fog.updateTransitions(w),this._resetUpdates()}const it={};for(const xt in this._sourceCaches){const Dt=this._sourceCaches[xt];it[xt]=Dt.used,Dt.used=!1}for(const xt of this._order){const Dt=this._layers[xt];if(Dt.recalculate(w,this._availableImages),!Dt.isHidden(w.zoom)){const rn=this._getLayerSourceCache(Dt);rn&&(rn.used=!0)}const Ot=this.map.painter;if(Ot){const rn=Dt.getProgramIds();if(!rn)continue;const Tn=Dt.getProgramConfiguration(w.zoom);for(const kn of rn)Ot.useProgram(kn,Tn)}}for(const xt in it){const Dt=this._sourceCaches[xt];it[xt]!==Dt.used&&Dt.getSource().fire(new m.Event("data",{sourceDataType:"visibility",dataType:"source",sourceId:Dt.getSource().id}))}this.light.recalculate(w),this.terrain&&this.terrain.recalculate(w),this.fog&&this.fog.recalculate(w),this.z=w.zoom,this._markersNeedUpdate&&(this._updateMarkersOpacity(),this._markersNeedUpdate=!1),se&&this.fire(new m.Event("data",{dataType:"style"}))}_updateTilesForChangedImages(){const w=Object.keys(this._changedImages);if(w.length){for(const se in this._sourceCaches)this._sourceCaches[se].reloadTilesForDependencies(["icons","patterns"],w);this._changedImages={}}}_updateWorkerLayers(w,se){this.dispatcher.broadcast("updateLayers",{layers:this._serializeLayers(w),removedIds:se})}_resetUpdates(){this._changed=!1,this._updatedLayers={},this._removedLayers={},this._updatedSources={},this._updatedPaintProps={},this._changedImages={}}setState(w){if(this._checkLoaded(),Su(this,m.validateStyle(w)))return!1;(w=m.clone$1(w)).layers=$s(w.layers);const se=function(xt,Dt){if(!xt)return[{command:ao.setStyle,args:[Dt]}];let Ot=[];try{if(!G(xt.version,Dt.version))return[{command:ao.setStyle,args:[Dt]}];G(xt.center,Dt.center)||Ot.push({command:ao.setCenter,args:[Dt.center]}),G(xt.zoom,Dt.zoom)||Ot.push({command:ao.setZoom,args:[Dt.zoom]}),G(xt.bearing,Dt.bearing)||Ot.push({command:ao.setBearing,args:[Dt.bearing]}),G(xt.pitch,Dt.pitch)||Ot.push({command:ao.setPitch,args:[Dt.pitch]}),G(xt.sprite,Dt.sprite)||Ot.push({command:ao.setSprite,args:[Dt.sprite]}),G(xt.glyphs,Dt.glyphs)||Ot.push({command:ao.setGlyphs,args:[Dt.glyphs]}),G(xt.transition,Dt.transition)||Ot.push({command:ao.setTransition,args:[Dt.transition]}),G(xt.light,Dt.light)||Ot.push({command:ao.setLight,args:[Dt.light]}),G(xt.fog,Dt.fog)||Ot.push({command:ao.setFog,args:[Dt.fog]}),G(xt.projection,Dt.projection)||Ot.push({command:ao.setProjection,args:[Dt.projection]});const rn={},Tn=[];(function(Wn,Fr,ri,Zr){let Sr;for(Sr in Fr=Fr||{},Wn=Wn||{})Wn.hasOwnProperty(Sr)&&(Fr.hasOwnProperty(Sr)||qo(Sr,ri,Zr));for(Sr in Fr)Fr.hasOwnProperty(Sr)&&(Wn.hasOwnProperty(Sr)?G(Wn[Sr],Fr[Sr])||(Wn[Sr].type==="geojson"&&Fr[Sr].type==="geojson"&&yu(Wn,Fr,Sr)?ri.push({command:ao.setGeoJSONSourceData,args:[Sr,Fr[Sr].data]}):wl(Sr,Fr,ri,Zr)):Ps(Sr,Fr,ri))})(xt.sources,Dt.sources,Tn,rn);const kn=[];xt.layers&&xt.layers.forEach(Wn=>{Wn.source&&rn[Wn.source]?Ot.push({command:ao.removeLayer,args:[Wn.id]}):kn.push(Wn)});let Bn=xt.terrain;Bn&&rn[Bn.source]&&(Ot.push({command:ao.setTerrain,args:[void 0]}),Bn=void 0),Ot=Ot.concat(Tn),G(Bn,Dt.terrain)||Ot.push({command:ao.setTerrain,args:[Dt.terrain]}),function(Wn,Fr,ri){Fr=Fr||[];const Zr=(Wn=Wn||[]).map(Zs),Sr=Fr.map(Zs),Di=Wn.reduce(Es,{}),di=Fr.reduce(Es,{}),wi=Zr.slice(),Ti=Object.create(null);let Oi,_i,Fi,Ta,Fa,qa,ja;for(Oi=0,_i=0;Oi<Zr.length;Oi++)Fi=Zr[Oi],di.hasOwnProperty(Fi)?_i++:(ri.push({command:ao.removeLayer,args:[Fi]}),wi.splice(wi.indexOf(Fi,_i),1));for(Oi=0,_i=0;Oi<Sr.length;Oi++)Fi=Sr[Sr.length-1-Oi],wi[wi.length-1-Oi]!==Fi&&(Di.hasOwnProperty(Fi)?(ri.push({command:ao.removeLayer,args:[Fi]}),wi.splice(wi.lastIndexOf(Fi,wi.length-_i),1)):_i++,qa=wi[wi.length-Oi],ri.push({command:ao.addLayer,args:[di[Fi],qa]}),wi.splice(wi.length-Oi,0,Fi),Ti[Fi]=!0);for(Oi=0;Oi<Sr.length;Oi++)if(Fi=Sr[Oi],Ta=Di[Fi],Fa=di[Fi],!Ti[Fi]&&!G(Ta,Fa))if(G(Ta.source,Fa.source)&&G(Ta["source-layer"],Fa["source-layer"])&&G(Ta.type,Fa.type)){for(ja in po(Ta.layout,Fa.layout,ri,Fi,null,ao.setLayoutProperty),po(Ta.paint,Fa.paint,ri,Fi,null,ao.setPaintProperty),G(Ta.filter,Fa.filter)||ri.push({command:ao.setFilter,args:[Fi,Fa.filter]}),G(Ta.minzoom,Fa.minzoom)&&G(Ta.maxzoom,Fa.maxzoom)||ri.push({command:ao.setLayerZoomRange,args:[Fi,Fa.minzoom,Fa.maxzoom]}),Ta)Ta.hasOwnProperty(ja)&&ja!=="layout"&&ja!=="paint"&&ja!=="filter"&&ja!=="metadata"&&ja!=="minzoom"&&ja!=="maxzoom"&&(ja.indexOf("paint.")===0?po(Ta[ja],Fa[ja],ri,Fi,ja.slice(6),ao.setPaintProperty):G(Ta[ja],Fa[ja])||ri.push({command:ao.setLayerProperty,args:[Fi,ja,Fa[ja]]}));for(ja in Fa)Fa.hasOwnProperty(ja)&&!Ta.hasOwnProperty(ja)&&ja!=="layout"&&ja!=="paint"&&ja!=="filter"&&ja!=="metadata"&&ja!=="minzoom"&&ja!=="maxzoom"&&(ja.indexOf("paint.")===0?po(Ta[ja],Fa[ja],ri,Fi,ja.slice(6),ao.setPaintProperty):G(Ta[ja],Fa[ja])||ri.push({command:ao.setLayerProperty,args:[Fi,ja,Fa[ja]]}))}else ri.push({command:ao.removeLayer,args:[Fi]}),qa=wi[wi.lastIndexOf(Fi)+1],ri.push({command:ao.addLayer,args:[Fa,qa]})}(kn,Dt.layers,Ot)}catch(rn){console.warn("Unable to compute style diff:",rn),Ot=[{command:ao.setStyle,args:[Dt]}]}return Ot}(this.serialize(),w).filter(xt=>!(xt.command in ka));if(se.length===0)return!1;const it=se.filter(xt=>!(xt.command in Yh));if(it.length>0)throw new Error(`Unimplemented: ${it.map(xt=>xt.command).join(", ")}.`);return se.forEach(xt=>{xt.command!=="setTransition"&&this[xt.command].apply(this,xt.args)}),this.stylesheet=w,this._updateMapProjection(),!0}addImage(w,se){return this.getImage(w)?this.fire(new m.ErrorEvent(new Error("An image with this name already exists."))):(this.imageManager.addImage(w,se),this._afterImageUpdated(w),this)}updateImage(w,se){this.imageManager.updateImage(w,se)}getImage(w){return this.imageManager.getImage(w)}removeImage(w){return this.getImage(w)?(this.imageManager.removeImage(w),this._afterImageUpdated(w),this):this.fire(new m.ErrorEvent(new Error("No image with this name exists.")))}_afterImageUpdated(w){this._availableImages=this.imageManager.listImages(),this._changedImages[w]=!0,this._changed=!0,this.dispatcher.broadcast("setImages",this._availableImages),this.fire(new m.Event("data",{dataType:"style"}))}listImages(){return this._checkLoaded(),this._availableImages.slice()}addSource(w,se,it={}){if(this._checkLoaded(),this.getSource(w)!==void 0)throw new Error("There is already a source with this ID");if(!se.type)throw new Error(`The type property must be defined, but only the following properties were given: ${Object.keys(se).join(", ")}.`);if(["vector","raster","geojson","video","image"].indexOf(se.type)>=0&&this._validate(m.validateSource,`sources.${w}`,se,null,it))return;this.map&&this.map._collectResourceTiming&&(se.collectResourceTiming=!0);const xt=ta(w,se,this.dispatcher,this);xt.setEventedParent(this,()=>({isSourceLoaded:this._isSourceCacheLoaded(w),source:xt.serialize(),sourceId:w}));const Dt=Ot=>{const rn=(Ot?"symbol:":"other:")+w,Tn=this._sourceCaches[rn]=new m.SourceCache(rn,xt,Ot);(Ot?this._symbolSourceCaches:this._otherSourceCaches)[w]=Tn,Tn.style=this,Tn.onAdd(this.map)};Dt(!1),se.type!=="vector"&&se.type!=="geojson"||Dt(!0),xt.onAdd&&xt.onAdd(this.map),this._changed=!0}removeSource(w){this._checkLoaded();const se=this.getSource(w);if(!se)throw new Error("There is no source with this ID");for(const xt in this._layers)if(this._layers[xt].source===w)return this.fire(new m.ErrorEvent(new Error(`Source "${w}" cannot be removed while layer "${xt}" is using it.`)));if(this.terrain&&this.terrain.get().source===w)return this.fire(new m.ErrorEvent(new Error(`Source "${w}" cannot be removed while terrain is using it.`)));const it=this._getSourceCaches(w);for(const xt of it)delete this._sourceCaches[xt.id],delete this._updatedSources[xt.id],xt.fire(new m.Event("data",{sourceDataType:"metadata",dataType:"source",sourceId:xt.getSource().id})),xt.setEventedParent(null),xt.clearTiles();return delete this._otherSourceCaches[w],delete this._symbolSourceCaches[w],se.setEventedParent(null),se.onRemove&&se.onRemove(this.map),this._changed=!0,this}setGeoJSONSourceData(w,se){this._checkLoaded(),this.getSource(w).setData(se),this._changed=!0}getSource(w){const se=this._getSourceCache(w);return se&&se.getSource()}addLayer(w,se,it={}){this._checkLoaded();const xt=w.id;if(this.getLayer(xt))return void this.fire(new m.ErrorEvent(new Error(`Layer with id "${xt}" already exists on this map`)));let Dt;if(w.type==="custom"){if(Su(this,m.validateCustomStyleLayer(w)))return;Dt=m.createStyleLayer(w)}else{if(typeof w.source=="object"&&(this.addSource(xt,w.source),w=m.clone$1(w),w=m.extend(w,{source:xt})),this._validate(m.validateLayer,`layers.${xt}`,w,{arrayIndex:-1},it))return;Dt=m.createStyleLayer(w),this._validateLayer(Dt),Dt.setEventedParent(this,{layer:{id:xt}}),this._serializedLayers[Dt.id]=Dt.serialize(),this._updateLayerCount(Dt,!0)}const Ot=se?this._order.indexOf(se):this._order.length;if(se&&Ot===-1)return void this.fire(new m.ErrorEvent(new Error(`Layer with id "${se}" does not exist on this map.`)));this._order.splice(Ot,0,xt),this._layerOrderChanged=!0,this._layers[xt]=Dt;const rn=this._getLayerSourceCache(Dt);if(this._removedLayers[xt]&&Dt.source&&rn&&Dt.type!=="custom"){const Tn=this._removedLayers[xt];delete this._removedLayers[xt],Tn.type!==Dt.type?this._updatedSources[Dt.source]="clear":(this._updatedSources[Dt.source]="reload",rn.pause())}this._updateLayer(Dt),Dt.onAdd&&Dt.onAdd(this.map),this._updateDrapeFirstLayers()}moveLayer(w,se){if(this._checkLoaded(),this._changed=!0,!this._layers[w])return void this.fire(new m.ErrorEvent(new Error(`The layer '${w}' does not exist in the map's style and cannot be moved.`)));if(w===se)return;const it=this._order.indexOf(w);this._order.splice(it,1);const xt=se?this._order.indexOf(se):this._order.length;se&&xt===-1?this.fire(new m.ErrorEvent(new Error(`Layer with id "${se}" does not exist on this map.`))):(this._order.splice(xt,0,w),this._layerOrderChanged=!0,this._updateDrapeFirstLayers())}removeLayer(w){this._checkLoaded();const se=this._layers[w];if(!se)return void this.fire(new m.ErrorEvent(new Error(`The layer '${w}' does not exist in the map's style and cannot be removed.`)));se.setEventedParent(null),this._updateLayerCount(se,!1);const it=this._order.indexOf(w);this._order.splice(it,1),this._layerOrderChanged=!0,this._changed=!0,this._removedLayers[w]=se,delete this._layers[w],delete this._serializedLayers[w],delete this._updatedLayers[w],delete this._updatedPaintProps[w],se.onRemove&&se.onRemove(this.map),this._updateDrapeFirstLayers()}getLayer(w){return this._layers[w]}hasLayer(w){return w in this._layers}hasLayerType(w){for(const se in this._layers)if(this._layers[se].type===w)return!0;return!1}setLayerZoomRange(w,se,it){this._checkLoaded();const xt=this.getLayer(w);xt?xt.minzoom===se&&xt.maxzoom===it||(se!=null&&(xt.minzoom=se),it!=null&&(xt.maxzoom=it),this._updateLayer(xt)):this.fire(new m.ErrorEvent(new Error(`The layer '${w}' does not exist in the map's style and cannot have zoom extent.`)))}setFilter(w,se,it={}){this._checkLoaded();const xt=this.getLayer(w);if(xt){if(!G(xt.filter,se))return se==null?(xt.filter=void 0,void this._updateLayer(xt)):void(this._validate(m.validateFilter,`layers.${xt.id}.filter`,se,{layerType:xt.type},it)||(xt.filter=m.clone$1(se),this._updateLayer(xt)))}else this.fire(new m.ErrorEvent(new Error(`The layer '${w}' does not exist in the map's style and cannot be filtered.`)))}getFilter(w){const se=this.getLayer(w);return se&&m.clone$1(se.filter)}setLayoutProperty(w,se,it,xt={}){this._checkLoaded();const Dt=this.getLayer(w);Dt?G(Dt.getLayoutProperty(se),it)||(Dt.setLayoutProperty(se,it,xt),this._updateLayer(Dt)):this.fire(new m.ErrorEvent(new Error(`The layer '${w}' does not exist in the map's style and cannot be styled.`)))}getLayoutProperty(w,se){const it=this.getLayer(w);if(it)return it.getLayoutProperty(se);this.fire(new m.ErrorEvent(new Error(`The layer '${w}' does not exist in the map's style.`)))}setPaintProperty(w,se,it,xt={}){this._checkLoaded();const Dt=this.getLayer(w);Dt?G(Dt.getPaintProperty(se),it)||(Dt.setPaintProperty(se,it,xt)&&this._updateLayer(Dt),this._changed=!0,this._updatedPaintProps[w]=!0):this.fire(new m.ErrorEvent(new Error(`The layer '${w}' does not exist in the map's style and cannot be styled.`)))}getPaintProperty(w,se){const it=this.getLayer(w);return it&&it.getPaintProperty(se)}setFeatureState(w,se){this._checkLoaded();const it=w.source,xt=w.sourceLayer,Dt=this.getSource(it);if(!Dt)return void this.fire(new m.ErrorEvent(new Error(`The source '${it}' does not exist in the map's style.`)));const Ot=Dt.type;if(Ot==="geojson"&&xt)return void this.fire(new m.ErrorEvent(new Error("GeoJSON sources cannot have a sourceLayer parameter.")));if(Ot==="vector"&&!xt)return void this.fire(new m.ErrorEvent(new Error("The sourceLayer parameter must be provided for vector source types.")));w.id===void 0&&this.fire(new m.ErrorEvent(new Error("The feature id parameter must be provided.")));const rn=this._getSourceCaches(it);for(const Tn of rn)Tn.setFeatureState(xt,w.id,se)}removeFeatureState(w,se){this._checkLoaded();const it=w.source,xt=this.getSource(it);if(!xt)return void this.fire(new m.ErrorEvent(new Error(`The source '${it}' does not exist in the map's style.`)));const Dt=xt.type,Ot=Dt==="vector"?w.sourceLayer:void 0;if(Dt==="vector"&&!Ot)return void this.fire(new m.ErrorEvent(new Error("The sourceLayer parameter must be provided for vector source types.")));if(se&&typeof w.id!="string"&&typeof w.id!="number")return void this.fire(new m.ErrorEvent(new Error("A feature id is required to remove its specific state property.")));const rn=this._getSourceCaches(it);for(const Tn of rn)Tn.removeFeatureState(Ot,w.id,se)}getFeatureState(w){this._checkLoaded();const se=w.source,it=w.sourceLayer,xt=this.getSource(se);if(xt){if(xt.type!=="vector"||it)return w.id===void 0&&this.fire(new m.ErrorEvent(new Error("The feature id parameter must be provided."))),this._getSourceCaches(se)[0].getFeatureState(it,w.id);this.fire(new m.ErrorEvent(new Error("The sourceLayer parameter must be provided for vector source types.")))}else this.fire(new m.ErrorEvent(new Error(`The source '${se}' does not exist in the map's style.`)))}getTransition(){return m.extend({duration:300,delay:0},this.stylesheet&&this.stylesheet.transition)}serialize(){const w={};for(const se in this._sourceCaches){const it=this._sourceCaches[se].getSource();w[it.id]||(w[it.id]=it.serialize())}return m.filterObject({version:this.stylesheet.version,name:this.stylesheet.name,metadata:this.stylesheet.metadata,light:this.stylesheet.light,terrain:this.stylesheet.terrain,fog:this.stylesheet.fog,center:this.stylesheet.center,zoom:this.stylesheet.zoom,bearing:this.stylesheet.bearing,pitch:this.stylesheet.pitch,sprite:this.stylesheet.sprite,glyphs:this.stylesheet.glyphs,transition:this.stylesheet.transition,projection:this.stylesheet.projection,sources:w,layers:this._serializeLayers(this._order)},se=>se!==void 0)}_updateLayer(w){this._updatedLayers[w.id]=!0;const se=this._getLayerSourceCache(w);w.source&&!this._updatedSources[w.source]&&se&&se.getSource().type!=="raster"&&(this._updatedSources[w.source]="reload",se.pause()),this._changed=!0,w.invalidateCompiledFilter()}_flattenAndSortRenderedFeatures(w){const se=Ot=>this._layers[Ot].type==="fill-extrusion",it={},xt=[];for(let Ot=this._order.length-1;Ot>=0;Ot--){const rn=this._order[Ot];if(se(rn)){it[rn]=Ot;for(const Tn of w){const kn=Tn[rn];if(kn)for(const Bn of kn)xt.push(Bn)}}}xt.sort((Ot,rn)=>rn.intersectionZ-Ot.intersectionZ);const Dt=[];for(let Ot=this._order.length-1;Ot>=0;Ot--){const rn=this._order[Ot];if(se(rn))for(let Tn=xt.length-1;Tn>=0;Tn--){const kn=xt[Tn].feature;if(it[kn.layer.id]<Ot)break;Dt.push(kn),xt.pop()}else for(const Tn of w){const kn=Tn[rn];if(kn)for(const Bn of kn)Dt.push(Bn.feature)}}return Dt}queryRenderedFeatures(w,se,it){se&&se.filter&&this._validate(m.validateFilter,"queryRenderedFeatures.filter",se.filter,null,se);const xt={};if(se&&se.layers){if(!Array.isArray(se.layers))return this.fire(new m.ErrorEvent(new Error("parameters.layers must be an Array."))),[];for(const Tn of se.layers){const kn=this._layers[Tn];if(!kn)return this.fire(new m.ErrorEvent(new Error(`The layer '${Tn}' does not exist in the map's style and cannot be queried for features.`))),[];xt[kn.source]=!0}}const Dt=[];se.availableImages=this._availableImages;const Ot=se&&se.layers?se.layers.some(Tn=>{const kn=this.getLayer(Tn);return kn&&kn.is3D()}):this.has3DLayers(),rn=xn.createFromScreenPoints(w,it);for(const Tn in this._sourceCaches){const kn=this._sourceCaches[Tn].getSource().id;se.layers&&!xt[kn]||Dt.push(Ai(this._sourceCaches[Tn],this._layers,this._serializedLayers,rn,se,it,Ot,!!this.map._showQueryGeometry))}return this.placement&&Dt.push(function(Tn,kn,Bn,Wn,Fr,ri,Zr){const Sr={},Di=ri.queryRenderedSymbols(Wn),di=[];for(const wi of Object.keys(Di).map(Number))di.push(Zr[wi]);di.sort(wo);for(const wi of di){const Ti=wi.featureIndex.lookupSymbolFeatures(Di[wi.bucketInstanceId],kn,wi.bucketIndex,wi.sourceLayerIndex,Fr.filter,Fr.layers,Fr.availableImages,Tn);for(const Oi in Ti){const _i=Sr[Oi]=Sr[Oi]||[],Fi=Ti[Oi];Fi.sort((Ta,Fa)=>{const qa=wi.featureSortOrder;if(qa){const ja=qa.indexOf(Ta.featureIndex);return qa.indexOf(Fa.featureIndex)-ja}return Fa.featureIndex-Ta.featureIndex});for(const Ta of Fi)_i.push(Ta)}}for(const wi in Sr)Sr[wi].forEach(Ti=>{const Oi=Ti.feature,_i=Bn(Tn[wi]).getFeatureState(Oi.layer["source-layer"],Oi.id);Oi.source=Oi.layer.source,Oi.layer["source-layer"]&&(Oi.sourceLayer=Oi.layer["source-layer"]),Oi.state=_i});return Sr}(this._layers,this._serializedLayers,this._getLayerSourceCache.bind(this),rn.screenGeometry,se,this.placement.collisionIndex,this.placement.retainedQueryData)),this._flattenAndSortRenderedFeatures(Dt)}querySourceFeatures(w,se){se&&se.filter&&this._validate(m.validateFilter,"querySourceFeatures.filter",se.filter,null,se);const it=this._getSourceCaches(w);let xt=[];for(const Dt of it)xt=xt.concat(Ea(Dt,se));return xt}addSourceType(w,se,it){return Ss.getSourceType(w)?it(new Error(`A source type called "${w}" already exists.`)):(Ss.setSourceType(w,se),se.workerSourceURL?void this.dispatcher.broadcast("loadWorkerSource",{name:w,url:se.workerSourceURL},it):it(null,null))}getLight(){return this.light.getLight()}setLight(w,se={}){this._checkLoaded();const it=this.light.getLight();let xt=!1;for(const Ot in w)if(!G(w[Ot],it[Ot])){xt=!0;break}if(!xt)return;const Dt={now:m.exported.now(),transition:m.extend({duration:300,delay:0},this.stylesheet.transition)};this.light.setLight(w,se),this.light.updateTransitions(Dt)}getTerrain(){return this.terrain&&this.terrain.drapeRenderMode===1?this.terrain.get():null}setTerrainForDraping(){this.setTerrain({source:"",exaggeration:0},0)}setTerrain(w,se=1){if(this._checkLoaded(),!w)return delete this.terrain,delete this.stylesheet.terrain,this.dispatcher.broadcast("enableTerrain",!1),this._force3DLayerUpdate(),void(this._markersNeedUpdate=!0);if(se===1){if(typeof w.source=="object"){const it="terrain-dem-src";this.addSource(it,w.source),w=m.clone$1(w),w=m.extend(w,{source:it})}if(this._validate(m.validateTerrain,"terrain",w))return}if(!this.terrain||this.terrain&&se!==this.terrain.drapeRenderMode)this._createTerrain(w,se);else{const it=this.terrain,xt=it.get();for(const Dt in w)if(!G(w[Dt],xt[Dt])){it.set(w),this.stylesheet.terrain=w;const Ot={now:m.exported.now(),transition:m.extend({duration:0},this.stylesheet.transition)};it.updateTransitions(Ot);break}}this._updateDrapeFirstLayers(),this._markersNeedUpdate=!0}_createFog(w){const se=this.fog=new Lt(w,this.map.transform);this.stylesheet.fog=w;const it={now:m.exported.now(),transition:m.extend({duration:0},this.stylesheet.transition)};se.updateTransitions(it)}_updateMarkersOpacity(){this.map._markers.length!==0&&this.map._requestDomTask(()=>{for(const w of this.map._markers)w._evaluateOpacity()})}getFog(){return this.fog?this.fog.get():null}setFog(w){if(this._checkLoaded(),!w)return delete this.fog,delete this.stylesheet.fog,void(this._markersNeedUpdate=!0);if(this.fog){const se=this.fog,it=se.get();for(const xt in w)if(!G(w[xt],it[xt])){se.set(w),this.stylesheet.fog=w;const Dt={now:m.exported.now(),transition:m.extend({duration:0},this.stylesheet.transition)};se.updateTransitions(Dt);break}}else this._createFog(w);this._markersNeedUpdate=!0}_updateDrapeFirstLayers(){if(!this.map._optimizeForTerrain||!this.terrain)return;const w=this._order.filter(it=>this.isLayerDraped(this._layers[it])),se=this._order.filter(it=>!this.isLayerDraped(this._layers[it]));this._drapedFirstOrder=[],this._drapedFirstOrder.push(...w),this._drapedFirstOrder.push(...se)}_createTerrain(w,se){const it=this.terrain=new pn(w,se);this.stylesheet.terrain=w,this.dispatcher.broadcast("enableTerrain",!this.terrainSetForDrapingOnly()),this._force3DLayerUpdate();const xt={now:m.exported.now(),transition:m.extend({duration:0},this.stylesheet.transition)};it.updateTransitions(xt)}_force3DLayerUpdate(){for(const w in this._layers){const se=this._layers[w];se.type==="fill-extrusion"&&this._updateLayer(se)}}_forceSymbolLayerUpdate(){for(const w in this._layers){const se=this._layers[w];se.type==="symbol"&&this._updateLayer(se)}}_validate(w,se,it,xt,Dt={}){return(!Dt||Dt.validate!==!1)&&Su(this,w.call(m.validateStyle,m.extend({key:se,style:this.serialize(),value:it,styleSpec:m.spec},xt)))}_remove(){this._request&&(this._request.cancel(),this._request=null),this._spriteRequest&&(this._spriteRequest.cancel(),this._spriteRequest=null),m.evented.off("pluginStateChange",this._rtlTextPluginCallback);for(const w in this._layers)this._layers[w].setEventedParent(null);for(const w in this._sourceCaches)this._sourceCaches[w].clearTiles(),this._sourceCaches[w].setEventedParent(null);this.imageManager.setEventedParent(null),this.setEventedParent(null),this.dispatcher.remove()}_clearSource(w){const se=this._getSourceCaches(w);for(const it of se)it.clearTiles()}_reloadSource(w){const se=this._getSourceCaches(w);for(const it of se)it.resume(),it.reload()}_updateSources(w){for(const se in this._sourceCaches)this._sourceCaches[se].update(w)}_generateCollisionBoxes(){for(const w in this._sourceCaches){const se=this._sourceCaches[w];se.resume(),se.reload()}}_updatePlacement(w,se,it,xt,Dt=!1){let Ot=!1,rn=!1;const Tn={};for(const kn of this._order){const Bn=this._layers[kn];if(Bn.type!=="symbol")continue;if(!Tn[Bn.source]){const Fr=this._getLayerSourceCache(Bn);if(!Fr)continue;Tn[Bn.source]=Fr.getRenderableIds(!0).map(ri=>Fr.getTileByID(ri)).sort((ri,Zr)=>Zr.tileID.overscaledZ-ri.tileID.overscaledZ||(ri.tileID.isLessThan(Zr.tileID)?-1:1))}const Wn=this.crossTileSymbolIndex.addLayer(Bn,Tn[Bn.source],w.center.lng,w.projection);Ot=Ot||Wn}if(this.crossTileSymbolIndex.pruneUnusedLayers(this._order),Dt=Dt||this._layerOrderChanged||it===0,this._layerOrderChanged&&this.fire(new m.Event("neworder")),(Dt||!this.pauseablePlacement||this.pauseablePlacement.isDone()&&!this.placement.stillRecent(m.exported.now(),w.zoom))&&(this.pauseablePlacement=new jd(w,this._order,Dt,se,it,xt,this.placement,this.fog&&w.projection.supportsFog?this.fog.state:null),this._layerOrderChanged=!1),this.pauseablePlacement.isDone()?this.placement.setStale():(this.pauseablePlacement.continuePlacement(this._order,this._layers,Tn),this.pauseablePlacement.isDone()&&(this.placement=this.pauseablePlacement.commit(m.exported.now()),rn=!0),Ot&&this.pauseablePlacement.placement.setStale()),rn||Ot)for(const kn of this._order){const Bn=this._layers[kn];Bn.type==="symbol"&&this.placement.updateLayerOpacities(Bn,Tn[Bn.source])}return!this.pauseablePlacement.isDone()||this.placement.hasTransitions(m.exported.now())}_releaseSymbolFadeTiles(){for(const w in this._sourceCaches)this._sourceCaches[w].releaseSymbolFadeTiles()}getImages(w,se,it){this.imageManager.getImages(se.icons,it),this._updateTilesForChangedImages();const xt=Dt=>{Dt&&Dt.setDependencies(se.tileID.key,se.type,se.icons)};xt(this._otherSourceCaches[se.source]),xt(this._symbolSourceCaches[se.source])}getGlyphs(w,se,it){this.glyphManager.getGlyphs(se.stacks,it)}getResource(w,se,it){return m.makeRequest(se,it)}_getSourceCache(w){return this._otherSourceCaches[w]}_getLayerSourceCache(w){return w.type==="symbol"?this._symbolSourceCaches[w.source]:this._otherSourceCaches[w.source]}_getSourceCaches(w){const se=[];return this._otherSourceCaches[w]&&se.push(this._otherSourceCaches[w]),this._symbolSourceCaches[w]&&se.push(this._symbolSourceCaches[w]),se}_isSourceCacheLoaded(w){const se=this._getSourceCaches(w);return se.length===0?(this.fire(new m.ErrorEvent(new Error(`There is no source with ID '${w}'`))),!1):se.every(it=>it.loaded())}has3DLayers(){return this._num3DLayers>0}hasSymbolLayers(){return this._numSymbolLayers>0}hasCircleLayers(){return this._numCircleLayers>0}_clearWorkerCaches(){this.dispatcher.broadcast("clearCaches")}destroy(){this._clearWorkerCaches(),this.terrainSetForDrapingOnly()&&(delete this.terrain,delete this.stylesheet.terrain)}}Ss.getSourceType=function(Ee){return $t[Ee]},Ss.setSourceType=function(Ee,w){$t[Ee]=w},Ss.registerForPluginStateChange=m.registerForPluginStateChange;var Vo=`
- #define EPSILON 0.0000001
- #define PI 3.141592653589793
- #define EXTENT 8192.0
- #define HALF_PI PI/2.0
- #define QUARTER_PI PI/4.0
- #define RAD_TO_DEG 180.0/PI
- #define DEG_TO_RAD PI/180.0
- #define GLOBE_RADIUS EXTENT/PI/2.0
- #ifdef FOG
- uniform mediump vec4 u_fog_color;uniform mediump vec2 u_fog_range;uniform mediump float u_fog_horizon_blend;varying vec3 v_fog_pos;float fog_range(float depth) {return (depth-u_fog_range[0])/(u_fog_range[1]-u_fog_range[0]);}float fog_horizon_blending(vec3 camera_dir) {float t=max(0.0,camera_dir.z/u_fog_horizon_blend);return u_fog_color.a*exp(-3.0*t*t);}float fog_opacity(float t) {const float decay=6.0;float falloff=1.0-min(1.0,exp(-decay*t));falloff*=falloff*falloff;return u_fog_color.a*min(1.0,1.00747*falloff);}
- #endif`,iu="attribute highp vec3 a_pos_3f;uniform lowp mat4 u_matrix;varying highp vec3 v_uv;void main() {const mat3 half_neg_pi_around_x=mat3(1.0,0.0, 0.0,0.0,0.0,-1.0,0.0,1.0, 0.0);v_uv=half_neg_pi_around_x*a_pos_3f;vec4 pos=u_matrix*vec4(a_pos_3f,1.0);gl_Position=pos.xyww;}";let Tu={},wt={};Tu=Qe("",`
- #define ELEVATION_SCALE 7.0
- #define ELEVATION_OFFSET 450.0
- #ifdef PROJECTION_GLOBE_VIEW
- uniform vec3 u_tile_tl_up;uniform vec3 u_tile_tr_up;uniform vec3 u_tile_br_up;uniform vec3 u_tile_bl_up;uniform float u_tile_up_scale;vec3 elevationVector(vec2 pos) {vec2 uv=pos/EXTENT;vec3 up=normalize(mix(
- mix(u_tile_tl_up,u_tile_tr_up,uv.xxx),mix(u_tile_bl_up,u_tile_br_up,uv.xxx),uv.yyy));return up*u_tile_up_scale;}
- #else
- vec3 elevationVector(vec2 pos) { return vec3(0,0,1); }
- #endif
- #ifdef TERRAIN
- #ifdef TERRAIN_DEM_FLOAT_FORMAT
- uniform highp sampler2D u_dem;uniform highp sampler2D u_dem_prev;
- #else
- uniform sampler2D u_dem;uniform sampler2D u_dem_prev;
- #endif
- uniform vec4 u_dem_unpack;uniform vec2 u_dem_tl;uniform vec2 u_dem_tl_prev;uniform float u_dem_scale;uniform float u_dem_scale_prev;uniform float u_dem_size;uniform float u_dem_lerp;uniform float u_exaggeration;uniform float u_meter_to_dem;uniform mat4 u_label_plane_matrix_inv;uniform sampler2D u_depth;uniform vec2 u_depth_size_inv;vec4 tileUvToDemSample(vec2 uv,float dem_size,float dem_scale,vec2 dem_tl) {vec2 pos=dem_size*(uv*dem_scale+dem_tl)+1.0;vec2 f=fract(pos);return vec4((pos-f+0.5)/(dem_size+2.0),f);}float decodeElevation(vec4 v) {return dot(vec4(v.xyz*255.0,-1.0),u_dem_unpack);}float currentElevation(vec2 apos) {
- #ifdef TERRAIN_DEM_FLOAT_FORMAT
- vec2 pos=(u_dem_size*(apos/8192.0*u_dem_scale+u_dem_tl)+1.5)/(u_dem_size+2.0);return u_exaggeration*texture2D(u_dem,pos).a;
- #else
- float dd=1.0/(u_dem_size+2.0);vec4 r=tileUvToDemSample(apos/8192.0,u_dem_size,u_dem_scale,u_dem_tl);vec2 pos=r.xy;vec2 f=r.zw;float tl=decodeElevation(texture2D(u_dem,pos));
- #ifdef TERRAIN_DEM_NEAREST_FILTER
- return u_exaggeration*tl;
- #endif
- float tr=decodeElevation(texture2D(u_dem,pos+vec2(dd,0.0)));float bl=decodeElevation(texture2D(u_dem,pos+vec2(0.0,dd)));float br=decodeElevation(texture2D(u_dem,pos+vec2(dd,dd)));return u_exaggeration*mix(mix(tl,tr,f.x),mix(bl,br,f.x),f.y);
- #endif
- }float prevElevation(vec2 apos) {
- #ifdef TERRAIN_DEM_FLOAT_FORMAT
- vec2 pos=(u_dem_size*(apos/8192.0*u_dem_scale_prev+u_dem_tl_prev)+1.5)/(u_dem_size+2.0);return u_exaggeration*texture2D(u_dem_prev,pos).a;
- #else
- float dd=1.0/(u_dem_size+2.0);vec4 r=tileUvToDemSample(apos/8192.0,u_dem_size,u_dem_scale_prev,u_dem_tl_prev);vec2 pos=r.xy;vec2 f=r.zw;float tl=decodeElevation(texture2D(u_dem_prev,pos));float tr=decodeElevation(texture2D(u_dem_prev,pos+vec2(dd,0.0)));float bl=decodeElevation(texture2D(u_dem_prev,pos+vec2(0.0,dd)));float br=decodeElevation(texture2D(u_dem_prev,pos+vec2(dd,dd)));return u_exaggeration*mix(mix(tl,tr,f.x),mix(bl,br,f.x),f.y);
- #endif
- }
- #ifdef TERRAIN_VERTEX_MORPHING
- float elevation(vec2 apos) {float nextElevation=currentElevation(apos);float prevElevation=prevElevation(apos);return mix(prevElevation,nextElevation,u_dem_lerp);}
- #else
- float elevation(vec2 apos) {return currentElevation(apos);}
- #endif
- float unpack_depth(vec4 rgba_depth)
- {const vec4 bit_shift=vec4(1.0/(256.0*256.0*256.0),1.0/(256.0*256.0),1.0/256.0,1.0);return dot(rgba_depth,bit_shift)*2.0-1.0;}bool isOccluded(vec4 frag) {vec3 coord=frag.xyz/frag.w;float depth=unpack_depth(texture2D(u_depth,(coord.xy+1.0)*0.5));return coord.z > depth+0.0005;}float occlusionFade(vec4 frag) {vec3 coord=frag.xyz/frag.w;vec3 df=vec3(5.0*u_depth_size_inv,0.0);vec2 uv=0.5*coord.xy+0.5;vec4 depth=vec4(
- unpack_depth(texture2D(u_depth,uv-df.xz)),unpack_depth(texture2D(u_depth,uv+df.xz)),unpack_depth(texture2D(u_depth,uv-df.zy)),unpack_depth(texture2D(u_depth,uv+df.zy))
- );return dot(vec4(0.25),vec4(1.0)-clamp(300.0*(vec4(coord.z-0.001)-depth),0.0,1.0));}vec4 fourSample(vec2 pos,vec2 off) {
- #ifdef TERRAIN_DEM_FLOAT_FORMAT
- float tl=texture2D(u_dem,pos).a;float tr=texture2D(u_dem,pos+vec2(off.x,0.0)).a;float bl=texture2D(u_dem,pos+vec2(0.0,off.y)).a;float br=texture2D(u_dem,pos+off).a;
- #else
- vec4 demtl=vec4(texture2D(u_dem,pos).xyz*255.0,-1.0);float tl=dot(demtl,u_dem_unpack);vec4 demtr=vec4(texture2D(u_dem,pos+vec2(off.x,0.0)).xyz*255.0,-1.0);float tr=dot(demtr,u_dem_unpack);vec4 dembl=vec4(texture2D(u_dem,pos+vec2(0.0,off.y)).xyz*255.0,-1.0);float bl=dot(dembl,u_dem_unpack);vec4 dembr=vec4(texture2D(u_dem,pos+off).xyz*255.0,-1.0);float br=dot(dembr,u_dem_unpack);
- #endif
- return vec4(tl,tr,bl,br);}float flatElevation(vec2 pack) {vec2 apos=floor(pack/8.0);vec2 span=10.0*(pack-apos*8.0);vec2 uvTex=(apos-vec2(1.0,1.0))/8190.0;float size=u_dem_size+2.0;float dd=1.0/size;vec2 pos=u_dem_size*(uvTex*u_dem_scale+u_dem_tl)+1.0;vec2 f=fract(pos);pos=(pos-f+0.5)*dd;vec4 h=fourSample(pos,vec2(dd));float z=mix(mix(h.x,h.y,f.x),mix(h.z,h.w,f.x),f.y);vec2 w=floor(0.5*(span*u_meter_to_dem-1.0));vec2 d=dd*w;vec4 bounds=vec4(d,vec2(1.0)-d);h=fourSample(pos-d,2.0*d+vec2(dd));vec4 diff=abs(h.xzxy-h.ywzw);vec2 slope=min(vec2(0.25),u_meter_to_dem*0.5*(diff.xz+diff.yw)/(2.0*w+vec2(1.0)));vec2 fix=slope*span;float base=z+max(fix.x,fix.y);return u_exaggeration*base;}float elevationFromUint16(float word) {return u_exaggeration*(word/ELEVATION_SCALE-ELEVATION_OFFSET);}
- #else
- float elevation(vec2 pos) { return 0.0; }bool isOccluded(vec4 frag) { return false; }float occlusionFade(vec4 frag) { return 1.0; }
- #endif`,!0),wt=Qe(`#ifdef FOG
- uniform float u_fog_temporal_offset;float fog_opacity(vec3 pos) {float depth=length(pos);return fog_opacity(fog_range(depth));}vec3 fog_apply(vec3 color,vec3 pos) {float depth=length(pos);float opacity=fog_opacity(fog_range(depth));opacity*=fog_horizon_blending(pos/depth);return mix(color,u_fog_color.rgb,opacity);}vec4 fog_apply_from_vert(vec4 color,float fog_opac) {float alpha=EPSILON+color.a;color.rgb=mix(color.rgb/alpha,u_fog_color.rgb,fog_opac)*alpha;return color;}vec3 fog_apply_sky_gradient(vec3 camera_ray,vec3 sky_color) {float horizon_blend=fog_horizon_blending(normalize(camera_ray));return mix(sky_color,u_fog_color.rgb,horizon_blend);}vec4 fog_apply_premultiplied(vec4 color,vec3 pos) {float alpha=EPSILON+color.a;color.rgb=fog_apply(color.rgb/alpha,pos)*alpha;return color;}vec3 fog_dither(vec3 color) {vec2 dither_seed=gl_FragCoord.xy+u_fog_temporal_offset;return dither(color,dither_seed);}vec4 fog_dither(vec4 color) {return vec4(fog_dither(color.rgb),color.a);}
- #endif`,`#ifdef FOG
- uniform mat4 u_fog_matrix;vec3 fog_position(vec3 pos) {return (u_fog_matrix*vec4(pos,1.0)).xyz;}vec3 fog_position(vec2 pos) {return fog_position(vec3(pos,0.0));}float fog(vec3 pos) {float depth=length(pos);float opacity=fog_opacity(fog_range(depth));return opacity*fog_horizon_blending(pos/depth);}
- #endif`,!0);const qt=Qe(`
- highp vec3 hash(highp vec2 p) {highp vec3 p3=fract(p.xyx*vec3(443.8975,397.2973,491.1871));p3+=dot(p3,p3.yxz+19.19);return fract((p3.xxy+p3.yzz)*p3.zyx);}vec3 dither(vec3 color,highp vec2 seed) {vec3 rnd=hash(seed)+hash(seed+0.59374)-0.5;return color+rnd/255.0;}
- #ifdef TERRAIN
- highp vec4 pack_depth(highp float ndc_z) {highp float depth=ndc_z*0.5+0.5;const highp vec4 bit_shift=vec4(256.0*256.0*256.0,256.0*256.0,256.0,1.0);const highp vec4 bit_mask =vec4(0.0,1.0/256.0,1.0/256.0,1.0/256.0);highp vec4 res=fract(depth*bit_shift);res-=res.xxyz*bit_mask;return res;}
- #endif`,`
- float wrap(float n,float min,float max) {float d=max-min;float w=mod(mod(n-min,d)+d,d)+min;return (w==min) ? max : w;}
- #ifdef PROJECTION_GLOBE_VIEW
- vec3 mercator_tile_position(mat4 matrix,vec2 tile_anchor,vec3 tile_id,vec2 mercator_center) {
- #ifndef PROJECTED_POS_ON_VIEWPORT
- float tiles=tile_id.z;vec2 mercator=(tile_anchor/EXTENT+tile_id.xy)/tiles;mercator-=mercator_center;mercator.x=wrap(mercator.x,-0.5,0.5);vec4 mercator_tile=vec4(mercator.xy*EXTENT,EXTENT/(2.0*PI),1.0);mercator_tile=matrix*mercator_tile;return mercator_tile.xyz;
- #else
- return vec3(0.0);
- #endif
- }vec3 mix_globe_mercator(vec3 globe,vec3 mercator,float t) {return mix(globe,mercator,t);}mat3 globe_mercator_surface_vectors(vec3 pos_normal,vec3 up_dir,float zoom_transition) {vec3 normal=zoom_transition==0.0 ? pos_normal : normalize(mix(pos_normal,up_dir,zoom_transition));vec3 xAxis=normalize(vec3(normal.z,0.0,-normal.x));vec3 yAxis=normalize(cross(normal,xAxis));return mat3(xAxis,yAxis,normal);}
- #endif
- vec2 unpack_float(const float packedValue) {int packedIntValue=int(packedValue);int v0=packedIntValue/256;return vec2(v0,packedIntValue-v0*256);}vec2 unpack_opacity(const float packedOpacity) {int intOpacity=int(packedOpacity)/2;return vec2(float(intOpacity)/127.0,mod(packedOpacity,2.0));}vec4 decode_color(const vec2 encodedColor) {return vec4(
- unpack_float(encodedColor[0])/255.0,unpack_float(encodedColor[1])/255.0
- );}float unpack_mix_vec2(const vec2 packedValue,const float t) {return mix(packedValue[0],packedValue[1],t);}vec4 unpack_mix_color(const vec4 packedColors,const float t) {vec4 minColor=decode_color(vec2(packedColors[0],packedColors[1]));vec4 maxColor=decode_color(vec2(packedColors[2],packedColors[3]));return mix(minColor,maxColor,t);}vec2 get_pattern_pos(const vec2 pixel_coord_upper,const vec2 pixel_coord_lower,const vec2 pattern_size,const float tile_units_to_pixels,const vec2 pos) {vec2 offset=mod(mod(mod(pixel_coord_upper,pattern_size)*256.0,pattern_size)*256.0+pixel_coord_lower,pattern_size);return (tile_units_to_pixels*pos+offset)/pattern_size;}const vec4 AWAY=vec4(-1000.0,-1000.0,-1000.0,1);//Normalized device coordinate that is not rendered.`),Cn=Vo;var Pn={background:Qe(`uniform vec4 u_color;uniform float u_opacity;void main() {vec4 out_color=u_color;
- #ifdef FOG
- out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
- #endif
- gl_FragColor=out_color*u_opacity;
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`attribute vec2 a_pos;uniform mat4 u_matrix;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);
- #ifdef FOG
- v_fog_pos=fog_position(a_pos);
- #endif
- }`),backgroundPattern:Qe(`uniform vec2 u_pattern_tl_a;uniform vec2 u_pattern_br_a;uniform vec2 u_pattern_tl_b;uniform vec2 u_pattern_br_b;uniform vec2 u_texsize;uniform float u_mix;uniform float u_opacity;uniform sampler2D u_image;varying vec2 v_pos_a;varying vec2 v_pos_b;void main() {vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(u_pattern_tl_a/u_texsize,u_pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(u_pattern_tl_b/u_texsize,u_pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture2D(u_image,pos2);vec4 out_color=mix(color1,color2,u_mix);
- #ifdef FOG
- out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
- #endif
- gl_FragColor=out_color*u_opacity;
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`uniform mat4 u_matrix;uniform vec2 u_pattern_size_a;uniform vec2 u_pattern_size_b;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform float u_scale_a;uniform float u_scale_b;uniform float u_tile_units_to_pixels;attribute vec2 a_pos;varying vec2 v_pos_a;varying vec2 v_pos_b;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,u_scale_a*u_pattern_size_a,u_tile_units_to_pixels,a_pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,u_scale_b*u_pattern_size_b,u_tile_units_to_pixels,a_pos);
- #ifdef FOG
- v_fog_pos=fog_position(a_pos);
- #endif
- }`),circle:Qe(`varying vec3 v_data;varying float v_visibility;
- #pragma mapbox: define highp vec4 color
- #pragma mapbox: define mediump float radius
- #pragma mapbox: define lowp float blur
- #pragma mapbox: define lowp float opacity
- #pragma mapbox: define highp vec4 stroke_color
- #pragma mapbox: define mediump float stroke_width
- #pragma mapbox: define lowp float stroke_opacity
- void main() {
- #pragma mapbox: initialize highp vec4 color
- #pragma mapbox: initialize mediump float radius
- #pragma mapbox: initialize lowp float blur
- #pragma mapbox: initialize lowp float opacity
- #pragma mapbox: initialize highp vec4 stroke_color
- #pragma mapbox: initialize mediump float stroke_width
- #pragma mapbox: initialize lowp float stroke_opacity
- vec2 extrude=v_data.xy;float extrude_length=length(extrude);lowp float antialiasblur=v_data.z;float antialiased_blur=-max(blur,antialiasblur);float opacity_t=smoothstep(0.0,antialiased_blur,extrude_length-1.0);float color_t=stroke_width < 0.01 ? 0.0 : smoothstep(
- antialiased_blur,0.0,extrude_length-radius/(radius+stroke_width)
- );vec4 out_color=mix(color*opacity,stroke_color*stroke_opacity,color_t);
- #ifdef FOG
- out_color=fog_apply_premultiplied(out_color,v_fog_pos);
- #endif
- gl_FragColor=out_color*(v_visibility*opacity_t);
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`#define NUM_VISIBILITY_RINGS 2
- #define INV_SQRT2 0.70710678
- #define ELEVATION_BIAS 0.0001
- #define NUM_SAMPLES_PER_RING 16
- uniform mat4 u_matrix;uniform mat2 u_extrude_scale;uniform lowp float u_device_pixel_ratio;uniform highp float u_camera_to_center_distance;attribute vec2 a_pos;
- #ifdef PROJECTION_GLOBE_VIEW
- attribute vec3 a_pos_3;attribute vec3 a_pos_normal_3;attribute float a_scale;uniform mat4 u_inv_rot_matrix;uniform vec2 u_merc_center;uniform vec3 u_tile_id;uniform float u_zoom_transition;uniform vec3 u_up_dir;
- #endif
- varying vec3 v_data;varying float v_visibility;
- #pragma mapbox: define highp vec4 color
- #pragma mapbox: define mediump float radius
- #pragma mapbox: define lowp float blur
- #pragma mapbox: define lowp float opacity
- #pragma mapbox: define highp vec4 stroke_color
- #pragma mapbox: define mediump float stroke_width
- #pragma mapbox: define lowp float stroke_opacity
- vec2 calc_offset(vec2 extrusion,float radius,float stroke_width, float view_scale) {return extrusion*(radius+stroke_width)*u_extrude_scale*view_scale;}float cantilevered_elevation(vec2 pos,float radius,float stroke_width,float view_scale) {vec2 c1=pos+calc_offset(vec2(-1,-1),radius,stroke_width,view_scale);vec2 c2=pos+calc_offset(vec2(1,-1),radius,stroke_width,view_scale);vec2 c3=pos+calc_offset(vec2(1,1),radius,stroke_width,view_scale);vec2 c4=pos+calc_offset(vec2(-1,1),radius,stroke_width,view_scale);float h1=elevation(c1)+ELEVATION_BIAS;float h2=elevation(c2)+ELEVATION_BIAS;float h3=elevation(c3)+ELEVATION_BIAS;float h4=elevation(c4)+ELEVATION_BIAS;return max(h4,max(h3,max(h1,h2)));}float circle_elevation(vec2 pos) {
- #if defined(TERRAIN)
- return elevation(pos)+ELEVATION_BIAS;
- #else
- return 0.0;
- #endif
- }vec4 project_vertex(vec2 extrusion,vec4 world_center,vec4 projected_center,float radius,float stroke_width, float view_scale,mat3 surface_vectors) {vec2 sample_offset=calc_offset(extrusion,radius,stroke_width,view_scale);
- #ifdef PITCH_WITH_MAP
- #ifdef PROJECTION_GLOBE_VIEW
- return u_matrix*( world_center+vec4(sample_offset.x*surface_vectors[0]+sample_offset.y*surface_vectors[1],0) );
- #else
- return u_matrix*( world_center+vec4(sample_offset,0,0) );
- #endif
- #else
- return projected_center+vec4(sample_offset,0,0);
- #endif
- }float get_sample_step() {
- #ifdef PITCH_WITH_MAP
- return 2.0*PI/float(NUM_SAMPLES_PER_RING);
- #else
- return PI/float(NUM_SAMPLES_PER_RING);
- #endif
- }void main(void) {
- #pragma mapbox: initialize highp vec4 color
- #pragma mapbox: initialize mediump float radius
- #pragma mapbox: initialize lowp float blur
- #pragma mapbox: initialize lowp float opacity
- #pragma mapbox: initialize highp vec4 stroke_color
- #pragma mapbox: initialize mediump float stroke_width
- #pragma mapbox: initialize lowp float stroke_opacity
- vec2 extrude=vec2(mod(a_pos,2.0)*2.0-1.0);vec2 circle_center=floor(a_pos*0.5);
- #ifdef PROJECTION_GLOBE_VIEW
- vec2 scaled_extrude=extrude*a_scale;vec3 pos_normal_3=a_pos_normal_3/16384.0;mat3 surface_vectors=globe_mercator_surface_vectors(pos_normal_3,u_up_dir,u_zoom_transition);vec3 surface_extrusion=scaled_extrude.x*surface_vectors[0]+scaled_extrude.y*surface_vectors[1];vec3 globe_elevation=elevationVector(circle_center)*circle_elevation(circle_center);vec3 globe_pos=a_pos_3+surface_extrusion+globe_elevation;vec3 mercator_elevation=u_up_dir*u_tile_up_scale*circle_elevation(circle_center);vec3 merc_pos=mercator_tile_position(u_inv_rot_matrix,circle_center,u_tile_id,u_merc_center)+surface_extrusion+mercator_elevation;vec3 pos=mix_globe_mercator(globe_pos,merc_pos,u_zoom_transition);vec4 world_center=vec4(pos,1);
- #else
- mat3 surface_vectors=mat3(1.0);float height=circle_elevation(circle_center);vec4 world_center=vec4(circle_center,height,1);
- #endif
- vec4 projected_center=u_matrix*world_center;float view_scale=0.0;
- #ifdef PITCH_WITH_MAP
- #ifdef SCALE_WITH_MAP
- view_scale=1.0;
- #else
- view_scale=projected_center.w/u_camera_to_center_distance;
- #endif
- #else
- #ifdef SCALE_WITH_MAP
- view_scale=u_camera_to_center_distance;
- #else
- view_scale=projected_center.w;
- #endif
- #endif
- #if defined(SCALE_WITH_MAP) && defined(PROJECTION_GLOBE_VIEW)
- view_scale*=a_scale;
- #endif
- gl_Position=project_vertex(extrude,world_center,projected_center,radius,stroke_width,view_scale,surface_vectors);float visibility=0.0;
- #ifdef TERRAIN
- float step=get_sample_step();
- #ifdef PITCH_WITH_MAP
- float cantilevered_height=cantilevered_elevation(circle_center,radius,stroke_width,view_scale);vec4 occlusion_world_center=vec4(circle_center,cantilevered_height,1);vec4 occlusion_projected_center=u_matrix*occlusion_world_center;
- #else
- vec4 occlusion_world_center=world_center;vec4 occlusion_projected_center=projected_center;
- #endif
- for(int ring=0; ring < NUM_VISIBILITY_RINGS; ring++) {float scale=(float(ring)+1.0)/float(NUM_VISIBILITY_RINGS);for(int i=0; i < NUM_SAMPLES_PER_RING; i++) {vec2 extrusion=vec2(cos(step*float(i)),-sin(step*float(i)))*scale;vec4 frag_pos=project_vertex(extrusion,occlusion_world_center,occlusion_projected_center,radius,stroke_width,view_scale,surface_vectors);visibility+=float(!isOccluded(frag_pos));}}visibility/=float(NUM_VISIBILITY_RINGS)*float(NUM_SAMPLES_PER_RING);
- #else
- visibility=1.0;
- #endif
- #ifdef PROJECTION_GLOBE_VIEW
- visibility=1.0;
- #endif
- v_visibility=visibility;lowp float antialiasblur=1.0/u_device_pixel_ratio/(radius+stroke_width);v_data=vec3(extrude.x,extrude.y,antialiasblur);
- #ifdef FOG
- v_fog_pos=fog_position(world_center.xyz);
- #endif
- }`),clippingMask:Qe("void main() {gl_FragColor=vec4(1.0);}","attribute vec2 a_pos;uniform mat4 u_matrix;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);}"),heatmap:Qe(`uniform highp float u_intensity;varying vec2 v_extrude;
- #pragma mapbox: define highp float weight
- #define GAUSS_COEF 0.3989422804014327
- void main() {
- #pragma mapbox: initialize highp float weight
- float d=-0.5*3.0*3.0*dot(v_extrude,v_extrude);float val=weight*u_intensity*GAUSS_COEF*exp(d);gl_FragColor=vec4(val,1.0,1.0,1.0);
- #ifdef FOG
- gl_FragColor.r*=pow(1.0-fog_opacity(v_fog_pos),2.0);
- #endif
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`uniform mat4 u_matrix;uniform float u_extrude_scale;uniform float u_opacity;uniform float u_intensity;attribute vec2 a_pos;
- #ifdef PROJECTION_GLOBE_VIEW
- attribute vec3 a_pos_3;attribute vec3 a_pos_normal_3;attribute float a_scale;uniform mat4 u_inv_rot_matrix;uniform vec2 u_merc_center;uniform vec3 u_tile_id;uniform float u_zoom_transition;uniform vec3 u_up_dir;
- #endif
- varying vec2 v_extrude;
- #pragma mapbox: define highp float weight
- #pragma mapbox: define mediump float radius
- const highp float ZERO=1.0/255.0/16.0;
- #define GAUSS_COEF 0.3989422804014327
- void main(void) {
- #pragma mapbox: initialize highp float weight
- #pragma mapbox: initialize mediump float radius
- vec2 unscaled_extrude=vec2(mod(a_pos,2.0)*2.0-1.0);float S=sqrt(-2.0*log(ZERO/weight/u_intensity/GAUSS_COEF))/3.0;v_extrude=S*unscaled_extrude;vec2 extrude=v_extrude*radius*u_extrude_scale;vec2 tilePos=floor(a_pos*0.5);
- #ifdef PROJECTION_GLOBE_VIEW
- extrude*=a_scale;vec3 pos_normal_3=a_pos_normal_3/16384.0;mat3 surface_vectors=globe_mercator_surface_vectors(pos_normal_3,u_up_dir,u_zoom_transition);vec3 surface_extrusion=extrude.x*surface_vectors[0]+extrude.y*surface_vectors[1];vec3 globe_elevation=elevationVector(tilePos)*elevation(tilePos);vec3 globe_pos=a_pos_3+surface_extrusion+globe_elevation;vec3 mercator_elevation=u_up_dir*u_tile_up_scale*elevation(tilePos);vec3 merc_pos=mercator_tile_position(u_inv_rot_matrix,tilePos,u_tile_id,u_merc_center)+surface_extrusion+mercator_elevation;vec3 pos=mix_globe_mercator(globe_pos,merc_pos,u_zoom_transition);
- #else
- vec3 pos=vec3(tilePos+extrude,elevation(tilePos));
- #endif
- gl_Position=u_matrix*vec4(pos,1);
- #ifdef FOG
- v_fog_pos=fog_position(pos);
- #endif
- }`),heatmapTexture:Qe(`uniform sampler2D u_image;uniform sampler2D u_color_ramp;uniform float u_opacity;varying vec2 v_pos;void main() {float t=texture2D(u_image,v_pos).r;vec4 color=texture2D(u_color_ramp,vec2(t,0.5));gl_FragColor=color*u_opacity;
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(0.0);
- #endif
- }`,"attribute vec2 a_pos;varying vec2 v_pos;void main() {gl_Position=vec4(a_pos,0,1);v_pos=a_pos*0.5+0.5;}"),collisionBox:Qe("varying float v_placed;varying float v_notUsed;void main() {vec4 red =vec4(1.0,0.0,0.0,1.0);vec4 blue=vec4(0.0,0.0,1.0,0.5);gl_FragColor =mix(red,blue,step(0.5,v_placed))*0.5;gl_FragColor*=mix(1.0,0.1,step(0.5,v_notUsed));}",`attribute vec3 a_pos;attribute vec2 a_anchor_pos;attribute vec2 a_extrude;attribute vec2 a_placed;attribute vec2 a_shift;attribute float a_size_scale;attribute vec2 a_padding;uniform mat4 u_matrix;uniform vec2 u_extrude_scale;uniform float u_camera_to_center_distance;varying float v_placed;varying float v_notUsed;void main() {vec4 projectedPoint=u_matrix*vec4(a_pos+elevationVector(a_anchor_pos)*elevation(a_anchor_pos),1);highp float camera_to_anchor_distance=projectedPoint.w;highp float collision_perspective_ratio=clamp(
- 0.5+0.5*(u_camera_to_center_distance/camera_to_anchor_distance),0.0,1.5);gl_Position=projectedPoint;gl_Position.xy+=(a_extrude*a_size_scale+a_shift+a_padding)*u_extrude_scale*gl_Position.w*collision_perspective_ratio;v_placed=a_placed.x;v_notUsed=a_placed.y;}`),collisionCircle:Qe("varying float v_radius;varying vec2 v_extrude;varying float v_perspective_ratio;varying float v_collision;void main() {float alpha=0.5*min(v_perspective_ratio,1.0);float stroke_radius=0.9*max(v_perspective_ratio,1.0);float distance_to_center=length(v_extrude);float distance_to_edge=abs(distance_to_center-v_radius);float opacity_t=smoothstep(-stroke_radius,0.0,-distance_to_edge);vec4 color=mix(vec4(0.0,0.0,1.0,0.5),vec4(1.0,0.0,0.0,1.0),v_collision);gl_FragColor=color*alpha*opacity_t;}",`attribute vec2 a_pos_2f;attribute float a_radius;attribute vec2 a_flags;uniform mat4 u_matrix;uniform mat4 u_inv_matrix;uniform vec2 u_viewport_size;uniform float u_camera_to_center_distance;varying float v_radius;varying vec2 v_extrude;varying float v_perspective_ratio;varying float v_collision;vec3 toTilePosition(vec2 screenPos) {vec4 rayStart=u_inv_matrix*vec4(screenPos,-1.0,1.0);vec4 rayEnd =u_inv_matrix*vec4(screenPos, 1.0,1.0);rayStart.xyz/=rayStart.w;rayEnd.xyz /=rayEnd.w;highp float t=(0.0-rayStart.z)/(rayEnd.z-rayStart.z);return mix(rayStart.xyz,rayEnd.xyz,t);}void main() {vec2 quadCenterPos=a_pos_2f;float radius=a_radius;float collision=a_flags.x;float vertexIdx=a_flags.y;vec2 quadVertexOffset=vec2(
- mix(-1.0,1.0,float(vertexIdx >=2.0)),mix(-1.0,1.0,float(vertexIdx >=1.0 && vertexIdx <=2.0)));vec2 quadVertexExtent=quadVertexOffset*radius;vec3 tilePos=toTilePosition(quadCenterPos);vec4 clipPos=u_matrix*vec4(tilePos,1.0);highp float camera_to_anchor_distance=clipPos.w;highp float collision_perspective_ratio=clamp(
- 0.5+0.5*(u_camera_to_center_distance/camera_to_anchor_distance),0.0,4.0);float padding_factor=1.2;v_radius=radius;v_extrude=quadVertexExtent*padding_factor;v_perspective_ratio=collision_perspective_ratio;v_collision=collision;gl_Position=vec4(clipPos.xyz/clipPos.w,1.0)+vec4(quadVertexExtent*padding_factor/u_viewport_size*2.0,0.0,0.0);}`),debug:Qe("uniform highp vec4 u_color;uniform sampler2D u_overlay;varying vec2 v_uv;void main() {vec4 overlay_color=texture2D(u_overlay,v_uv);gl_FragColor=mix(u_color,overlay_color,overlay_color.a);}",`attribute vec2 a_pos;
- #ifdef PROJECTION_GLOBE_VIEW
- attribute vec3 a_pos_3;
- #endif
- varying vec2 v_uv;uniform mat4 u_matrix;uniform float u_overlay_scale;void main() {float h=elevation(a_pos);v_uv=a_pos/8192.0;
- #ifdef PROJECTION_GLOBE_VIEW
- gl_Position=u_matrix*vec4(a_pos_3+elevationVector(a_pos)*h,1);
- #else
- gl_Position=u_matrix*vec4(a_pos*u_overlay_scale,h,1);
- #endif
- }`),fill:Qe(`#pragma mapbox: define highp vec4 color
- #pragma mapbox: define lowp float opacity
- void main() {
- #pragma mapbox: initialize highp vec4 color
- #pragma mapbox: initialize lowp float opacity
- vec4 out_color=color;
- #ifdef FOG
- out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
- #endif
- gl_FragColor=out_color*opacity;
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`attribute vec2 a_pos;uniform mat4 u_matrix;
- #pragma mapbox: define highp vec4 color
- #pragma mapbox: define lowp float opacity
- void main() {
- #pragma mapbox: initialize highp vec4 color
- #pragma mapbox: initialize lowp float opacity
- gl_Position=u_matrix*vec4(a_pos,0,1);
- #ifdef FOG
- v_fog_pos=fog_position(a_pos);
- #endif
- }`),fillOutline:Qe(`varying vec2 v_pos;
- #pragma mapbox: define highp vec4 outline_color
- #pragma mapbox: define lowp float opacity
- void main() {
- #pragma mapbox: initialize highp vec4 outline_color
- #pragma mapbox: initialize lowp float opacity
- float dist=length(v_pos-gl_FragCoord.xy);float alpha=1.0-smoothstep(0.0,1.0,dist);vec4 out_color=outline_color;
- #ifdef FOG
- out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
- #endif
- gl_FragColor=out_color*(alpha*opacity);
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`attribute vec2 a_pos;uniform mat4 u_matrix;uniform vec2 u_world;varying vec2 v_pos;
- #pragma mapbox: define highp vec4 outline_color
- #pragma mapbox: define lowp float opacity
- void main() {
- #pragma mapbox: initialize highp vec4 outline_color
- #pragma mapbox: initialize lowp float opacity
- gl_Position=u_matrix*vec4(a_pos,0,1);v_pos=(gl_Position.xy/gl_Position.w+1.0)/2.0*u_world;
- #ifdef FOG
- v_fog_pos=fog_position(a_pos);
- #endif
- }`),fillOutlinePattern:Qe(`uniform vec2 u_texsize;uniform sampler2D u_image;uniform float u_fade;varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec2 v_pos;
- #pragma mapbox: define lowp float opacity
- #pragma mapbox: define lowp vec4 pattern_from
- #pragma mapbox: define lowp vec4 pattern_to
- void main() {
- #pragma mapbox: initialize lowp float opacity
- #pragma mapbox: initialize mediump vec4 pattern_from
- #pragma mapbox: initialize mediump vec4 pattern_to
- vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(pattern_tl_b/u_texsize,pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture2D(u_image,pos2);float dist=length(v_pos-gl_FragCoord.xy);float alpha=1.0-smoothstep(0.0,1.0,dist);vec4 out_color=mix(color1,color2,u_fade);
- #ifdef FOG
- out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
- #endif
- gl_FragColor=out_color*(alpha*opacity);
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`uniform mat4 u_matrix;uniform vec2 u_world;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform vec3 u_scale;attribute vec2 a_pos;varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec2 v_pos;
- #pragma mapbox: define lowp float opacity
- #pragma mapbox: define lowp vec4 pattern_from
- #pragma mapbox: define lowp vec4 pattern_to
- #pragma mapbox: define lowp float pixel_ratio_from
- #pragma mapbox: define lowp float pixel_ratio_to
- void main() {
- #pragma mapbox: initialize lowp float opacity
- #pragma mapbox: initialize mediump vec4 pattern_from
- #pragma mapbox: initialize mediump vec4 pattern_to
- #pragma mapbox: initialize lowp float pixel_ratio_from
- #pragma mapbox: initialize lowp float pixel_ratio_to
- vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;gl_Position=u_matrix*vec4(a_pos,0,1);vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,fromScale*display_size_a,tileRatio,a_pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,toScale*display_size_b,tileRatio,a_pos);v_pos=(gl_Position.xy/gl_Position.w+1.0)/2.0*u_world;
- #ifdef FOG
- v_fog_pos=fog_position(a_pos);
- #endif
- }`),fillPattern:Qe(`uniform vec2 u_texsize;uniform float u_fade;uniform sampler2D u_image;varying vec2 v_pos_a;varying vec2 v_pos_b;
- #pragma mapbox: define lowp float opacity
- #pragma mapbox: define lowp vec4 pattern_from
- #pragma mapbox: define lowp vec4 pattern_to
- void main() {
- #pragma mapbox: initialize lowp float opacity
- #pragma mapbox: initialize mediump vec4 pattern_from
- #pragma mapbox: initialize mediump vec4 pattern_to
- vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(pattern_tl_b/u_texsize,pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture2D(u_image,pos2);vec4 out_color=mix(color1,color2,u_fade);
- #ifdef FOG
- out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
- #endif
- gl_FragColor=out_color*opacity;
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`uniform mat4 u_matrix;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform vec3 u_scale;attribute vec2 a_pos;varying vec2 v_pos_a;varying vec2 v_pos_b;
- #pragma mapbox: define lowp float opacity
- #pragma mapbox: define lowp vec4 pattern_from
- #pragma mapbox: define lowp vec4 pattern_to
- #pragma mapbox: define lowp float pixel_ratio_from
- #pragma mapbox: define lowp float pixel_ratio_to
- void main() {
- #pragma mapbox: initialize lowp float opacity
- #pragma mapbox: initialize mediump vec4 pattern_from
- #pragma mapbox: initialize mediump vec4 pattern_to
- #pragma mapbox: initialize lowp float pixel_ratio_from
- #pragma mapbox: initialize lowp float pixel_ratio_to
- vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileZoomRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;gl_Position=u_matrix*vec4(a_pos,0,1);v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,fromScale*display_size_a,tileZoomRatio,a_pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,toScale*display_size_b,tileZoomRatio,a_pos);
- #ifdef FOG
- v_fog_pos=fog_position(a_pos);
- #endif
- }`),fillExtrusion:Qe(`varying vec4 v_color;void main() {vec4 color=v_color;
- #ifdef FOG
- color=fog_dither(fog_apply_premultiplied(color,v_fog_pos));
- #endif
- gl_FragColor=color;
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`uniform mat4 u_matrix;uniform vec3 u_lightcolor;uniform lowp vec3 u_lightpos;uniform lowp float u_lightintensity;uniform float u_vertical_gradient;uniform lowp float u_opacity;attribute vec4 a_pos_normal_ed;attribute vec2 a_centroid_pos;
- #ifdef PROJECTION_GLOBE_VIEW
- attribute vec3 a_pos_3;attribute vec3 a_pos_normal_3;uniform mat4 u_inv_rot_matrix;uniform vec2 u_merc_center;uniform vec3 u_tile_id;uniform float u_zoom_transition;uniform vec3 u_up_dir;uniform float u_height_lift;
- #endif
- varying vec4 v_color;
- #pragma mapbox: define highp float base
- #pragma mapbox: define highp float height
- #pragma mapbox: define highp vec4 color
- void main() {
- #pragma mapbox: initialize highp float base
- #pragma mapbox: initialize highp float height
- #pragma mapbox: initialize highp vec4 color
- vec3 pos_nx=floor(a_pos_normal_ed.xyz*0.5);mediump vec3 top_up_ny=a_pos_normal_ed.xyz-2.0*pos_nx;float x_normal=pos_nx.z/8192.0;vec3 normal=top_up_ny.y==1.0 ? vec3(0.0,0.0,1.0) : normalize(vec3(x_normal,(2.0*top_up_ny.z-1.0)*(1.0-abs(x_normal)),0.0));base=max(0.0,base);height=max(0.0,height);float t=top_up_ny.x;vec2 centroid_pos=vec2(0.0);
- #if defined(HAS_CENTROID) || defined(TERRAIN)
- centroid_pos=a_centroid_pos;
- #endif
- #ifdef TERRAIN
- bool flat_roof=centroid_pos.x !=0.0 && t > 0.0;float ele=elevation(pos_nx.xy);float c_ele=flat_roof ? centroid_pos.y==0.0 ? elevationFromUint16(centroid_pos.x) : flatElevation(centroid_pos) : ele;float h=flat_roof ? max(c_ele+height,ele+base+2.0) : ele+(t > 0.0 ? height : base==0.0 ?-5.0 : base);vec3 pos=vec3(pos_nx.xy,h);
- #else
- vec3 pos=vec3(pos_nx.xy,t > 0.0 ? height : base);
- #endif
- #ifdef PROJECTION_GLOBE_VIEW
- float lift=float((t+base) > 0.0)*u_height_lift;vec3 globe_normal=normalize(mix(a_pos_normal_3/16384.0,u_up_dir,u_zoom_transition));vec3 globe_pos=a_pos_3+globe_normal*(u_tile_up_scale*(pos.z+lift));vec3 merc_pos=mercator_tile_position(u_inv_rot_matrix,pos.xy,u_tile_id,u_merc_center)+u_up_dir*u_tile_up_scale*pos.z;pos=mix_globe_mercator(globe_pos,merc_pos,u_zoom_transition);
- #endif
- float hidden=float(centroid_pos.x==0.0 && centroid_pos.y==1.0);gl_Position=mix(u_matrix*vec4(pos,1),AWAY,hidden);float colorvalue=color.r*0.2126+color.g*0.7152+color.b*0.0722;v_color=vec4(0.0,0.0,0.0,1.0);vec4 ambientlight=vec4(0.03,0.03,0.03,1.0);color+=ambientlight;float directional=clamp(dot(normal,u_lightpos),0.0,1.0);directional=mix((1.0-u_lightintensity),max((1.0-colorvalue+u_lightintensity),1.0),directional);if (normal.y !=0.0) {directional*=(
- (1.0-u_vertical_gradient)+(u_vertical_gradient*clamp((t+base)*pow(height/150.0,0.5),mix(0.7,0.98,1.0-u_lightintensity),1.0)));}v_color.rgb+=clamp(color.rgb*directional*u_lightcolor,mix(vec3(0.0),vec3(0.3),1.0-u_lightcolor),vec3(1.0));v_color*=u_opacity;
- #ifdef FOG
- v_fog_pos=fog_position(pos);
- #endif
- }`),fillExtrusionPattern:Qe(`uniform vec2 u_texsize;uniform float u_fade;uniform sampler2D u_image;varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec4 v_lighting;
- #pragma mapbox: define lowp float base
- #pragma mapbox: define lowp float height
- #pragma mapbox: define lowp vec4 pattern_from
- #pragma mapbox: define lowp vec4 pattern_to
- #pragma mapbox: define lowp float pixel_ratio_from
- #pragma mapbox: define lowp float pixel_ratio_to
- void main() {
- #pragma mapbox: initialize lowp float base
- #pragma mapbox: initialize lowp float height
- #pragma mapbox: initialize mediump vec4 pattern_from
- #pragma mapbox: initialize mediump vec4 pattern_to
- #pragma mapbox: initialize lowp float pixel_ratio_from
- #pragma mapbox: initialize lowp float pixel_ratio_to
- vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(pattern_tl_b/u_texsize,pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture2D(u_image,pos2);vec4 out_color=mix(color1,color2,u_fade);out_color=out_color*v_lighting;
- #ifdef FOG
- out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
- #endif
- gl_FragColor=out_color;
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`uniform mat4 u_matrix;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform float u_height_factor;uniform vec3 u_scale;uniform float u_vertical_gradient;uniform lowp float u_opacity;uniform vec3 u_lightcolor;uniform lowp vec3 u_lightpos;uniform lowp float u_lightintensity;attribute vec4 a_pos_normal_ed;attribute vec2 a_centroid_pos;
- #ifdef PROJECTION_GLOBE_VIEW
- attribute vec3 a_pos_3;attribute vec3 a_pos_normal_3;uniform mat4 u_inv_rot_matrix;uniform vec2 u_merc_center;uniform vec3 u_tile_id;uniform float u_zoom_transition;uniform vec3 u_up_dir;uniform float u_height_lift;
- #endif
- varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec4 v_lighting;
- #pragma mapbox: define lowp float base
- #pragma mapbox: define lowp float height
- #pragma mapbox: define lowp vec4 pattern_from
- #pragma mapbox: define lowp vec4 pattern_to
- #pragma mapbox: define lowp float pixel_ratio_from
- #pragma mapbox: define lowp float pixel_ratio_to
- void main() {
- #pragma mapbox: initialize lowp float base
- #pragma mapbox: initialize lowp float height
- #pragma mapbox: initialize mediump vec4 pattern_from
- #pragma mapbox: initialize mediump vec4 pattern_to
- #pragma mapbox: initialize lowp float pixel_ratio_from
- #pragma mapbox: initialize lowp float pixel_ratio_to
- vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;vec3 pos_nx=floor(a_pos_normal_ed.xyz*0.5);mediump vec3 top_up_ny=a_pos_normal_ed.xyz-2.0*pos_nx;float x_normal=pos_nx.z/8192.0;vec3 normal=top_up_ny.y==1.0 ? vec3(0.0,0.0,1.0) : normalize(vec3(x_normal,(2.0*top_up_ny.z-1.0)*(1.0-abs(x_normal)),0.0));float edgedistance=a_pos_normal_ed.w;vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;base=max(0.0,base);height=max(0.0,height);float t=top_up_ny.x;float z=t > 0.0 ? height : base;vec2 centroid_pos=vec2(0.0);
- #if defined(HAS_CENTROID) || defined(TERRAIN)
- centroid_pos=a_centroid_pos;
- #endif
- #ifdef TERRAIN
- bool flat_roof=centroid_pos.x !=0.0 && t > 0.0;float ele=elevation(pos_nx.xy);float c_ele=flat_roof ? centroid_pos.y==0.0 ? elevationFromUint16(centroid_pos.x) : flatElevation(centroid_pos) : ele;float h=flat_roof ? max(c_ele+height,ele+base+2.0) : ele+(t > 0.0 ? height : base==0.0 ?-5.0 : base);vec3 p=vec3(pos_nx.xy,h);
- #else
- vec3 p=vec3(pos_nx.xy,z);
- #endif
- #ifdef PROJECTION_GLOBE_VIEW
- float lift=float((t+base) > 0.0)*u_height_lift;vec3 globe_normal=normalize(mix(a_pos_normal_3/16384.0,u_up_dir,u_zoom_transition));vec3 globe_pos=a_pos_3+globe_normal*(u_tile_up_scale*(p.z+lift));vec3 merc_pos=mercator_tile_position(u_inv_rot_matrix,p.xy,u_tile_id,u_merc_center)+u_up_dir*u_tile_up_scale*p.z;p=mix_globe_mercator(globe_pos,merc_pos,u_zoom_transition);
- #endif
- float hidden=float(centroid_pos.x==0.0 && centroid_pos.y==1.0);gl_Position=mix(u_matrix*vec4(p,1),AWAY,hidden);vec2 pos=normal.z==1.0
- ? pos_nx.xy
- : vec2(edgedistance,z*u_height_factor);v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,fromScale*display_size_a,tileRatio,pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,toScale*display_size_b,tileRatio,pos);v_lighting=vec4(0.0,0.0,0.0,1.0);float directional=clamp(dot(normal,u_lightpos),0.0,1.0);directional=mix((1.0-u_lightintensity),max((0.5+u_lightintensity),1.0),directional);if (normal.y !=0.0) {directional*=(
- (1.0-u_vertical_gradient)+(u_vertical_gradient*clamp((t+base)*pow(height/150.0,0.5),mix(0.7,0.98,1.0-u_lightintensity),1.0)));}v_lighting.rgb+=clamp(directional*u_lightcolor,mix(vec3(0.0),vec3(0.3),1.0-u_lightcolor),vec3(1.0));v_lighting*=u_opacity;
- #ifdef FOG
- v_fog_pos=fog_position(p);
- #endif
- }`),hillshadePrepare:Qe(`#ifdef GL_ES
- precision highp float;
- #endif
- uniform sampler2D u_image;varying vec2 v_pos;uniform vec2 u_dimension;uniform float u_zoom;uniform vec4 u_unpack;float getElevation(vec2 coord) {
- #ifdef TERRAIN_DEM_FLOAT_FORMAT
- return texture2D(u_image,coord).a/4.0;
- #else
- vec4 data=texture2D(u_image,coord)*255.0;data.a=-1.0;return dot(data,u_unpack)/4.0;
- #endif
- }void main() {vec2 epsilon=1.0/u_dimension;float a=getElevation(v_pos+vec2(-epsilon.x,-epsilon.y));float b=getElevation(v_pos+vec2(0,-epsilon.y));float c=getElevation(v_pos+vec2(epsilon.x,-epsilon.y));float d=getElevation(v_pos+vec2(-epsilon.x,0));float e=getElevation(v_pos);float f=getElevation(v_pos+vec2(epsilon.x,0));float g=getElevation(v_pos+vec2(-epsilon.x,epsilon.y));float h=getElevation(v_pos+vec2(0,epsilon.y));float i=getElevation(v_pos+vec2(epsilon.x,epsilon.y));float exaggerationFactor=u_zoom < 2.0 ? 0.4 : u_zoom < 4.5 ? 0.35 : 0.3;float exaggeration=u_zoom < 15.0 ? (u_zoom-15.0)*exaggerationFactor : 0.0;vec2 deriv=vec2(
- (c+f+f+i)-(a+d+d+g),(g+h+h+i)-(a+b+b+c)
- )/pow(2.0,exaggeration+(19.2562-u_zoom));gl_FragColor=clamp(vec4(
- deriv.x/2.0+0.5,deriv.y/2.0+0.5,1.0,1.0),0.0,1.0);
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,"uniform mat4 u_matrix;uniform vec2 u_dimension;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);highp vec2 epsilon=1.0/u_dimension;float scale=(u_dimension.x-2.0)/u_dimension.x;v_pos=(a_texture_pos/8192.0)*scale+epsilon;}"),hillshade:Qe(`uniform sampler2D u_image;varying vec2 v_pos;uniform vec2 u_latrange;uniform vec2 u_light;uniform vec4 u_shadow;uniform vec4 u_highlight;uniform vec4 u_accent;void main() {vec4 pixel=texture2D(u_image,v_pos);vec2 deriv=((pixel.rg*2.0)-1.0);float scaleFactor=cos(radians((u_latrange[0]-u_latrange[1])*(1.0-v_pos.y)+u_latrange[1]));float slope=atan(1.25*length(deriv)/scaleFactor);float aspect=deriv.x !=0.0 ? atan(deriv.y,-deriv.x) : PI/2.0*(deriv.y > 0.0 ? 1.0 :-1.0);float intensity=u_light.x;float azimuth=u_light.y+PI;float base=1.875-intensity*1.75;float maxValue=0.5*PI;float scaledSlope=intensity !=0.5 ? ((pow(base,slope)-1.0)/(pow(base,maxValue)-1.0))*maxValue : slope;float accent=cos(scaledSlope);vec4 accent_color=(1.0-accent)*u_accent*clamp(intensity*2.0,0.0,1.0);float shade=abs(mod((aspect+azimuth)/PI+0.5,2.0)-1.0);vec4 shade_color=mix(u_shadow,u_highlight,shade)*sin(scaledSlope)*clamp(intensity*2.0,0.0,1.0);gl_FragColor=accent_color*(1.0-shade_color.a)+shade_color;
- #ifdef FOG
- gl_FragColor=fog_dither(fog_apply_premultiplied(gl_FragColor,v_fog_pos));
- #endif
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`uniform mat4 u_matrix;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);v_pos=a_texture_pos/8192.0;
- #ifdef FOG
- v_fog_pos=fog_position(a_pos);
- #endif
- }`),line:Qe(`uniform lowp float u_device_pixel_ratio;uniform float u_alpha_discard_threshold;varying vec2 v_width2;varying vec2 v_normal;varying float v_gamma_scale;
- #ifdef RENDER_LINE_DASH
- uniform sampler2D u_dash_image;uniform float u_mix;uniform vec3 u_scale;varying vec2 v_tex_a;varying vec2 v_tex_b;
- #endif
- #ifdef RENDER_LINE_GRADIENT
- uniform sampler2D u_gradient_image;varying highp vec2 v_uv;
- #endif
- #pragma mapbox: define highp vec4 color
- #pragma mapbox: define lowp float floorwidth
- #pragma mapbox: define lowp vec4 dash_from
- #pragma mapbox: define lowp vec4 dash_to
- #pragma mapbox: define lowp float blur
- #pragma mapbox: define lowp float opacity
- void main() {
- #pragma mapbox: initialize highp vec4 color
- #pragma mapbox: initialize lowp float floorwidth
- #pragma mapbox: initialize lowp vec4 dash_from
- #pragma mapbox: initialize lowp vec4 dash_to
- #pragma mapbox: initialize lowp float blur
- #pragma mapbox: initialize lowp float opacity
- float dist=length(v_normal)*v_width2.s;float blur2=(blur+1.0/u_device_pixel_ratio)*v_gamma_scale;float alpha=clamp(min(dist-(v_width2.t-blur2),v_width2.s-dist)/blur2,0.0,1.0);
- #ifdef RENDER_LINE_DASH
- float sdfdist_a=texture2D(u_dash_image,v_tex_a).a;float sdfdist_b=texture2D(u_dash_image,v_tex_b).a;float sdfdist=mix(sdfdist_a,sdfdist_b,u_mix);float sdfwidth=min(dash_from.z*u_scale.y,dash_to.z*u_scale.z);float sdfgamma=1.0/(2.0*u_device_pixel_ratio)/sdfwidth;alpha*=smoothstep(0.5-sdfgamma/floorwidth,0.5+sdfgamma/floorwidth,sdfdist);
- #endif
- #ifdef RENDER_LINE_GRADIENT
- vec4 out_color=texture2D(u_gradient_image,v_uv);
- #else
- vec4 out_color=color;
- #endif
- #ifdef FOG
- out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
- #endif
- #ifdef RENDER_LINE_ALPHA_DISCARD
- if (alpha < u_alpha_discard_threshold) {discard;}
- #endif
- gl_FragColor=out_color*(alpha*opacity);
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`
- #define EXTRUDE_SCALE 0.015873016
- attribute vec2 a_pos_normal;attribute vec4 a_data;
- #ifdef RENDER_LINE_GRADIENT
- attribute vec3 a_packed;
- #else
- attribute float a_linesofar;
- #endif
- uniform mat4 u_matrix;uniform mat2 u_pixels_to_tile_units;uniform vec2 u_units_to_pixels;uniform lowp float u_device_pixel_ratio;varying vec2 v_normal;varying vec2 v_width2;varying float v_gamma_scale;
- #ifdef RENDER_LINE_DASH
- uniform vec2 u_texsize;uniform mediump vec3 u_scale;varying vec2 v_tex_a;varying vec2 v_tex_b;
- #endif
- #ifdef RENDER_LINE_GRADIENT
- uniform float u_image_height;varying highp vec2 v_uv;
- #endif
- #pragma mapbox: define highp vec4 color
- #pragma mapbox: define lowp float floorwidth
- #pragma mapbox: define lowp vec4 dash_from
- #pragma mapbox: define lowp vec4 dash_to
- #pragma mapbox: define lowp float blur
- #pragma mapbox: define lowp float opacity
- #pragma mapbox: define mediump float gapwidth
- #pragma mapbox: define lowp float offset
- #pragma mapbox: define mediump float width
- void main() {
- #pragma mapbox: initialize highp vec4 color
- #pragma mapbox: initialize lowp float floorwidth
- #pragma mapbox: initialize lowp vec4 dash_from
- #pragma mapbox: initialize lowp vec4 dash_to
- #pragma mapbox: initialize lowp float blur
- #pragma mapbox: initialize lowp float opacity
- #pragma mapbox: initialize mediump float gapwidth
- #pragma mapbox: initialize lowp float offset
- #pragma mapbox: initialize mediump float width
- float ANTIALIASING=1.0/u_device_pixel_ratio/2.0;vec2 a_extrude=a_data.xy-128.0;float a_direction=mod(a_data.z,4.0)-1.0;vec2 pos=floor(a_pos_normal*0.5);mediump vec2 normal=a_pos_normal-2.0*pos;normal.y=normal.y*2.0-1.0;v_normal=normal;gapwidth=gapwidth/2.0;float halfwidth=width/2.0;offset=-1.0*offset;float inset=gapwidth+(gapwidth > 0.0 ? ANTIALIASING : 0.0);float outset=gapwidth+halfwidth*(gapwidth > 0.0 ? 2.0 : 1.0)+(halfwidth==0.0 ? 0.0 : ANTIALIASING);mediump vec2 dist=outset*a_extrude*EXTRUDE_SCALE;mediump float u=0.5*a_direction;mediump float t=1.0-abs(u);mediump vec2 offset2=offset*a_extrude*EXTRUDE_SCALE*normal.y*mat2(t,-u,u,t);vec4 projected_extrude=u_matrix*vec4(dist*u_pixels_to_tile_units,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2*u_pixels_to_tile_units,0.0,1.0)+projected_extrude;
- #ifndef RENDER_TO_TEXTURE
- float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;
- #else
- v_gamma_scale=1.0;
- #endif
- #ifdef RENDER_LINE_GRADIENT
- float a_uv_x=a_packed[0];float a_split_index=a_packed[1];float a_linesofar=a_packed[2];highp float texel_height=1.0/u_image_height;highp float half_texel_height=0.5*texel_height;v_uv=vec2(a_uv_x,a_split_index*texel_height-half_texel_height);
- #endif
- #ifdef RENDER_LINE_DASH
- float tileZoomRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;float scaleA=dash_from.z==0.0 ? 0.0 : tileZoomRatio/(dash_from.z*fromScale);float scaleB=dash_to.z==0.0 ? 0.0 : tileZoomRatio/(dash_to.z*toScale);float heightA=dash_from.y;float heightB=dash_to.y;v_tex_a=vec2(a_linesofar*scaleA/floorwidth,(-normal.y*heightA+dash_from.x+0.5)/u_texsize.y);v_tex_b=vec2(a_linesofar*scaleB/floorwidth,(-normal.y*heightB+dash_to.x+0.5)/u_texsize.y);
- #endif
- v_width2=vec2(outset,inset);
- #ifdef FOG
- v_fog_pos=fog_position(pos);
- #endif
- }`),linePattern:Qe(`uniform lowp float u_device_pixel_ratio;uniform vec2 u_texsize;uniform float u_fade;uniform mediump vec3 u_scale;uniform sampler2D u_image;varying vec2 v_normal;varying vec2 v_width2;varying float v_linesofar;varying float v_gamma_scale;varying float v_width;
- #pragma mapbox: define lowp vec4 pattern_from
- #pragma mapbox: define lowp vec4 pattern_to
- #pragma mapbox: define lowp float pixel_ratio_from
- #pragma mapbox: define lowp float pixel_ratio_to
- #pragma mapbox: define lowp float blur
- #pragma mapbox: define lowp float opacity
- void main() {
- #pragma mapbox: initialize mediump vec4 pattern_from
- #pragma mapbox: initialize mediump vec4 pattern_to
- #pragma mapbox: initialize lowp float pixel_ratio_from
- #pragma mapbox: initialize lowp float pixel_ratio_to
- #pragma mapbox: initialize lowp float blur
- #pragma mapbox: initialize lowp float opacity
- vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileZoomRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;vec2 pattern_size_a=vec2(display_size_a.x*fromScale/tileZoomRatio,display_size_a.y);vec2 pattern_size_b=vec2(display_size_b.x*toScale/tileZoomRatio,display_size_b.y);float aspect_a=display_size_a.y/v_width;float aspect_b=display_size_b.y/v_width;float dist=length(v_normal)*v_width2.s;float blur2=(blur+1.0/u_device_pixel_ratio)*v_gamma_scale;float alpha=clamp(min(dist-(v_width2.t-blur2),v_width2.s-dist)/blur2,0.0,1.0);float x_a=mod(v_linesofar/pattern_size_a.x*aspect_a,1.0);float x_b=mod(v_linesofar/pattern_size_b.x*aspect_b,1.0);float y=0.5*v_normal.y+0.5;vec2 texel_size=1.0/u_texsize;vec2 pos_a=mix(pattern_tl_a*texel_size-texel_size,pattern_br_a*texel_size+texel_size,vec2(x_a,y));vec2 pos_b=mix(pattern_tl_b*texel_size-texel_size,pattern_br_b*texel_size+texel_size,vec2(x_b,y));vec4 color=mix(texture2D(u_image,pos_a),texture2D(u_image,pos_b),u_fade);
- #ifdef FOG
- color=fog_dither(fog_apply_premultiplied(color,v_fog_pos));
- #endif
- gl_FragColor=color*(alpha*opacity);
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`
- #define scale 0.015873016
- attribute vec2 a_pos_normal;attribute vec4 a_data;attribute float a_linesofar;uniform mat4 u_matrix;uniform vec2 u_units_to_pixels;uniform mat2 u_pixels_to_tile_units;uniform lowp float u_device_pixel_ratio;varying vec2 v_normal;varying vec2 v_width2;varying float v_linesofar;varying float v_gamma_scale;varying float v_width;
- #pragma mapbox: define lowp float blur
- #pragma mapbox: define lowp float opacity
- #pragma mapbox: define lowp float offset
- #pragma mapbox: define mediump float gapwidth
- #pragma mapbox: define mediump float width
- #pragma mapbox: define lowp float floorwidth
- #pragma mapbox: define lowp vec4 pattern_from
- #pragma mapbox: define lowp vec4 pattern_to
- #pragma mapbox: define lowp float pixel_ratio_from
- #pragma mapbox: define lowp float pixel_ratio_to
- void main() {
- #pragma mapbox: initialize lowp float blur
- #pragma mapbox: initialize lowp float opacity
- #pragma mapbox: initialize lowp float offset
- #pragma mapbox: initialize mediump float gapwidth
- #pragma mapbox: initialize mediump float width
- #pragma mapbox: initialize lowp float floorwidth
- #pragma mapbox: initialize mediump vec4 pattern_from
- #pragma mapbox: initialize mediump vec4 pattern_to
- #pragma mapbox: initialize lowp float pixel_ratio_from
- #pragma mapbox: initialize lowp float pixel_ratio_to
- float ANTIALIASING=1.0/u_device_pixel_ratio/2.0;vec2 a_extrude=a_data.xy-128.0;float a_direction=mod(a_data.z,4.0)-1.0;vec2 pos=floor(a_pos_normal*0.5);mediump vec2 normal=a_pos_normal-2.0*pos;normal.y=normal.y*2.0-1.0;v_normal=normal;gapwidth=gapwidth/2.0;float halfwidth=width/2.0;offset=-1.0*offset;float inset=gapwidth+(gapwidth > 0.0 ? ANTIALIASING : 0.0);float outset=gapwidth+halfwidth*(gapwidth > 0.0 ? 2.0 : 1.0)+(halfwidth==0.0 ? 0.0 : ANTIALIASING);mediump vec2 dist=outset*a_extrude*scale;mediump float u=0.5*a_direction;mediump float t=1.0-abs(u);mediump vec2 offset2=offset*a_extrude*scale*normal.y*mat2(t,-u,u,t);vec4 projected_extrude=u_matrix*vec4(dist*u_pixels_to_tile_units,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2*u_pixels_to_tile_units,0.0,1.0)+projected_extrude;
- #ifndef RENDER_TO_TEXTURE
- float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;
- #else
- v_gamma_scale=1.0;
- #endif
- v_linesofar=a_linesofar;v_width2=vec2(outset,inset);v_width=floorwidth;
- #ifdef FOG
- v_fog_pos=fog_position(pos);
- #endif
- }`),raster:Qe(`uniform float u_fade_t;uniform float u_opacity;uniform sampler2D u_image0;uniform sampler2D u_image1;varying vec2 v_pos0;varying vec2 v_pos1;uniform float u_brightness_low;uniform float u_brightness_high;uniform float u_saturation_factor;uniform float u_contrast_factor;uniform vec3 u_spin_weights;void main() {vec4 color0=texture2D(u_image0,v_pos0);vec4 color1=texture2D(u_image1,v_pos1);if (color0.a > 0.0) {color0.rgb=color0.rgb/color0.a;}if (color1.a > 0.0) {color1.rgb=color1.rgb/color1.a;}vec4 color=mix(color0,color1,u_fade_t);color.a*=u_opacity;vec3 rgb=color.rgb;rgb=vec3(
- dot(rgb,u_spin_weights.xyz),dot(rgb,u_spin_weights.zxy),dot(rgb,u_spin_weights.yzx));float average=(color.r+color.g+color.b)/3.0;rgb+=(average-rgb)*u_saturation_factor;rgb=(rgb-0.5)*u_contrast_factor+0.5;vec3 u_high_vec=vec3(u_brightness_low,u_brightness_low,u_brightness_low);vec3 u_low_vec=vec3(u_brightness_high,u_brightness_high,u_brightness_high);vec3 out_color=mix(u_high_vec,u_low_vec,rgb);
- #ifdef FOG
- out_color=fog_dither(fog_apply(out_color,v_fog_pos));
- #endif
- gl_FragColor=vec4(out_color*color.a,color.a);
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`uniform mat4 u_matrix;uniform vec2 u_tl_parent;uniform float u_scale_parent;uniform vec2 u_perspective_transform;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos0;varying vec2 v_pos1;void main() {float w=1.0+dot(a_texture_pos,u_perspective_transform);gl_Position=u_matrix*vec4(a_pos*w,0,w);v_pos0=a_texture_pos/8192.0;v_pos1=(v_pos0*u_scale_parent)+u_tl_parent;
- #ifdef FOG
- v_fog_pos=fog_position(a_pos);
- #endif
- }`),symbolIcon:Qe(`uniform sampler2D u_texture;varying vec2 v_tex;varying float v_fade_opacity;
- #pragma mapbox: define lowp float opacity
- void main() {
- #pragma mapbox: initialize lowp float opacity
- lowp float alpha=opacity*v_fade_opacity;gl_FragColor=texture2D(u_texture,v_tex)*alpha;
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`attribute vec4 a_pos_offset;attribute vec4 a_tex_size;attribute vec4 a_pixeloffset;attribute vec4 a_z_tile_anchor;attribute vec3 a_projected_pos;attribute float a_fade_opacity;uniform bool u_is_size_zoom_constant;uniform bool u_is_size_feature_constant;uniform highp float u_size_t;uniform highp float u_size;uniform highp float u_camera_to_center_distance;uniform bool u_rotate_symbol;uniform highp float u_aspect_ratio;uniform float u_fade_change;uniform mat4 u_matrix;uniform mat4 u_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform vec2 u_texsize;
- #ifdef PROJECTION_GLOBE_VIEW
- uniform vec3 u_tile_id;uniform mat4 u_inv_rot_matrix;uniform vec2 u_merc_center;uniform vec3 u_camera_forward;uniform float u_zoom_transition;uniform vec3 u_ecef_origin;uniform mat4 u_tile_matrix;
- #endif
- varying vec2 v_tex;varying float v_fade_opacity;
- #pragma mapbox: define lowp float opacity
- void main() {
- #pragma mapbox: initialize lowp float opacity
- vec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_tex_size.xy;vec2 a_size=a_tex_size.zw;float a_size_min=floor(a_size[0]*0.5);vec2 a_pxoffset=a_pixeloffset.xy;vec2 a_min_font_scale=a_pixeloffset.zw/256.0;highp float segment_angle=-a_projected_pos[2];float size;if (!u_is_size_zoom_constant && !u_is_size_feature_constant) {size=mix(a_size_min,a_size[1],u_size_t)/128.0;} else if (u_is_size_zoom_constant && !u_is_size_feature_constant) {size=a_size_min/128.0;} else {size=u_size;}float anchor_z=a_z_tile_anchor.x;vec2 tile_anchor=a_z_tile_anchor.yz;vec3 h=elevationVector(tile_anchor)*elevation(tile_anchor);
- #ifdef PROJECTION_GLOBE_VIEW
- vec3 mercator_pos=mercator_tile_position(u_inv_rot_matrix,tile_anchor,u_tile_id,u_merc_center);vec3 world_pos=mix_globe_mercator(vec3(a_pos,anchor_z)+h,mercator_pos,u_zoom_transition);vec4 ecef_point=u_tile_matrix*vec4(world_pos,1.0);vec3 origin_to_point=ecef_point.xyz-u_ecef_origin;float globe_occlusion_fade=dot(origin_to_point,u_camera_forward) >=0.0 ? 0.0 : 1.0;
- #else
- vec3 world_pos=vec3(a_pos,anchor_z)+h;float globe_occlusion_fade=1.0;
- #endif
- vec4 projected_point=u_matrix*vec4(world_pos,1);highp float camera_to_anchor_distance=projected_point.w;highp float distance_ratio=u_pitch_with_map ?
- camera_to_anchor_distance/u_camera_to_center_distance :
- u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(
- 0.5+0.5*distance_ratio,0.0,1.5);size*=perspective_ratio;float font_scale=u_is_text ? size/24.0 : size;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetProjected_point=u_matrix*vec4(a_pos+vec2(1,0),anchor_z,1);vec2 a=projected_point.xy/projected_point.w;vec2 b=offsetProjected_point.xy/offsetProjected_point.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}
- #ifdef PROJECTION_GLOBE_VIEW
- vec3 proj_pos=mix_globe_mercator(vec3(a_projected_pos.xy,anchor_z),mercator_pos,u_zoom_transition);
- #else
- vec3 proj_pos=vec3(a_projected_pos.xy,anchor_z);
- #endif
- #ifdef PROJECTED_POS_ON_VIEWPORT
- vec4 projected_pos=u_label_plane_matrix*vec4(proj_pos.xy,0.0,1.0);
- #else
- vec4 projected_pos=u_label_plane_matrix*vec4(proj_pos.xyz+h,1.0);
- #endif
- highp float angle_sin=sin(segment_angle+symbol_rotation);highp float angle_cos=cos(segment_angle+symbol_rotation);mat2 rotation_matrix=mat2(angle_cos,-1.0*angle_sin,angle_sin,angle_cos);float z=0.0;vec2 offset=rotation_matrix*(a_offset/32.0*max(a_min_font_scale,font_scale)+a_pxoffset/16.0);
- #ifdef PITCH_WITH_MAP_TERRAIN
- vec4 tile_pos=u_label_plane_matrix_inv*vec4(a_projected_pos.xy+offset,0.0,1.0);z=elevation(tile_pos.xy);
- #endif
- float occlusion_fade=occlusionFade(projected_point)*globe_occlusion_fade;gl_Position=mix(u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+offset,z,1.0),AWAY,float(projected_point.w <=0.0 || occlusion_fade==0.0));float projection_transition_fade=1.0;
- #if defined(PROJECTED_POS_ON_VIEWPORT) && defined(PROJECTION_GLOBE_VIEW)
- projection_transition_fade=1.0-step(EPSILON,u_zoom_transition);
- #endif
- v_tex=a_tex/u_texsize;vec2 fade_opacity=unpack_opacity(a_fade_opacity);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;v_fade_opacity=max(0.0,min(occlusion_fade,fade_opacity[0]+fade_change))*projection_transition_fade;}`),symbolSDF:Qe(`#define SDF_PX 8.0
- uniform bool u_is_halo;uniform sampler2D u_texture;uniform highp float u_gamma_scale;uniform lowp float u_device_pixel_ratio;uniform bool u_is_text;varying vec2 v_data0;varying vec3 v_data1;
- #pragma mapbox: define highp vec4 fill_color
- #pragma mapbox: define highp vec4 halo_color
- #pragma mapbox: define lowp float opacity
- #pragma mapbox: define lowp float halo_width
- #pragma mapbox: define lowp float halo_blur
- void main() {
- #pragma mapbox: initialize highp vec4 fill_color
- #pragma mapbox: initialize highp vec4 halo_color
- #pragma mapbox: initialize lowp float opacity
- #pragma mapbox: initialize lowp float halo_width
- #pragma mapbox: initialize lowp float halo_blur
- float EDGE_GAMMA=0.105/u_device_pixel_ratio;vec2 tex=v_data0.xy;float gamma_scale=v_data1.x;float size=v_data1.y;float fade_opacity=v_data1[2];float fontScale=u_is_text ? size/24.0 : size;lowp vec4 color=fill_color;highp float gamma=EDGE_GAMMA/(fontScale*u_gamma_scale);lowp float buff=(256.0-64.0)/256.0;if (u_is_halo) {color=halo_color;gamma=(halo_blur*1.19/SDF_PX+EDGE_GAMMA)/(fontScale*u_gamma_scale);buff=(6.0-halo_width/fontScale)/SDF_PX;}lowp float dist=texture2D(u_texture,tex).a;highp float gamma_scaled=gamma*gamma_scale;highp float alpha=smoothstep(buff-gamma_scaled,buff+gamma_scaled,dist);gl_FragColor=color*(alpha*opacity*fade_opacity);
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`attribute vec4 a_pos_offset;attribute vec4 a_tex_size;attribute vec4 a_pixeloffset;attribute vec4 a_z_tile_anchor;attribute vec3 a_projected_pos;attribute float a_fade_opacity;uniform bool u_is_size_zoom_constant;uniform bool u_is_size_feature_constant;uniform highp float u_size_t;uniform highp float u_size;uniform mat4 u_matrix;uniform mat4 u_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform bool u_rotate_symbol;uniform highp float u_aspect_ratio;uniform highp float u_camera_to_center_distance;uniform float u_fade_change;uniform vec2 u_texsize;
- #ifdef PROJECTION_GLOBE_VIEW
- uniform vec3 u_tile_id;uniform mat4 u_inv_rot_matrix;uniform vec2 u_merc_center;uniform vec3 u_camera_forward;uniform float u_zoom_transition;uniform vec3 u_ecef_origin;uniform mat4 u_tile_matrix;
- #endif
- varying vec2 v_data0;varying vec3 v_data1;
- #pragma mapbox: define highp vec4 fill_color
- #pragma mapbox: define highp vec4 halo_color
- #pragma mapbox: define lowp float opacity
- #pragma mapbox: define lowp float halo_width
- #pragma mapbox: define lowp float halo_blur
- void main() {
- #pragma mapbox: initialize highp vec4 fill_color
- #pragma mapbox: initialize highp vec4 halo_color
- #pragma mapbox: initialize lowp float opacity
- #pragma mapbox: initialize lowp float halo_width
- #pragma mapbox: initialize lowp float halo_blur
- vec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_tex_size.xy;vec2 a_size=a_tex_size.zw;float a_size_min=floor(a_size[0]*0.5);vec2 a_pxoffset=a_pixeloffset.xy;highp float segment_angle=-a_projected_pos[2];float size;if (!u_is_size_zoom_constant && !u_is_size_feature_constant) {size=mix(a_size_min,a_size[1],u_size_t)/128.0;} else if (u_is_size_zoom_constant && !u_is_size_feature_constant) {size=a_size_min/128.0;} else {size=u_size;}float anchor_z=a_z_tile_anchor.x;vec2 tile_anchor=a_z_tile_anchor.yz;vec3 h=elevationVector(tile_anchor)*elevation(tile_anchor);
- #ifdef PROJECTION_GLOBE_VIEW
- vec3 mercator_pos=mercator_tile_position(u_inv_rot_matrix,tile_anchor,u_tile_id,u_merc_center);vec3 world_pos=mix_globe_mercator(vec3(a_pos,anchor_z)+h,mercator_pos,u_zoom_transition);vec4 ecef_point=u_tile_matrix*vec4(world_pos,1.0);vec3 origin_to_point=ecef_point.xyz-u_ecef_origin;float globe_occlusion_fade=dot(origin_to_point,u_camera_forward) >=0.0 ? 0.0 : 1.0;
- #else
- vec3 world_pos=vec3(a_pos,anchor_z)+h;float globe_occlusion_fade=1.0;
- #endif
- vec4 projected_point=u_matrix*vec4(world_pos,1);highp float camera_to_anchor_distance=projected_point.w;highp float distance_ratio=u_pitch_with_map ?
- camera_to_anchor_distance/u_camera_to_center_distance :
- u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(
- 0.5+0.5*distance_ratio,0.0,1.5);size*=perspective_ratio;float fontScale=u_is_text ? size/24.0 : size;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetprojected_point=u_matrix*vec4(a_pos+vec2(1,0),anchor_z,1);vec2 a=projected_point.xy/projected_point.w;vec2 b=offsetprojected_point.xy/offsetprojected_point.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}
- #ifdef PROJECTION_GLOBE_VIEW
- vec3 proj_pos=mix_globe_mercator(vec3(a_projected_pos.xy,anchor_z),mercator_pos,u_zoom_transition);
- #else
- vec3 proj_pos=vec3(a_projected_pos.xy,anchor_z);
- #endif
- #ifdef PROJECTED_POS_ON_VIEWPORT
- vec4 projected_pos=u_label_plane_matrix*vec4(proj_pos.xy,0.0,1.0);
- #else
- vec4 projected_pos=u_label_plane_matrix*vec4(proj_pos.xyz+h,1.0);
- #endif
- highp float angle_sin=sin(segment_angle+symbol_rotation);highp float angle_cos=cos(segment_angle+symbol_rotation);mat2 rotation_matrix=mat2(angle_cos,-1.0*angle_sin,angle_sin,angle_cos);float z=0.0;vec2 offset=rotation_matrix*(a_offset/32.0*fontScale+a_pxoffset);
- #ifdef PITCH_WITH_MAP_TERRAIN
- vec4 tile_pos=u_label_plane_matrix_inv*vec4(a_projected_pos.xy+offset,0.0,1.0);z=elevation(tile_pos.xy);
- #endif
- float occlusion_fade=occlusionFade(projected_point)*globe_occlusion_fade;gl_Position=mix(u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+offset,z,1.0),AWAY,float(projected_point.w <=0.0 || occlusion_fade==0.0));float gamma_scale=gl_Position.w;float projection_transition_fade=1.0;
- #if defined(PROJECTED_POS_ON_VIEWPORT) && defined(PROJECTION_GLOBE_VIEW)
- projection_transition_fade=1.0-step(EPSILON,u_zoom_transition);
- #endif
- vec2 fade_opacity=unpack_opacity(a_fade_opacity);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;float interpolated_fade_opacity=max(0.0,min(occlusion_fade,fade_opacity[0]+fade_change));v_data0=a_tex/u_texsize;v_data1=vec3(gamma_scale,size,interpolated_fade_opacity*projection_transition_fade);}`),symbolTextAndIcon:Qe(`#define SDF_PX 8.0
- #define SDF 1.0
- #define ICON 0.0
- uniform bool u_is_halo;uniform sampler2D u_texture;uniform sampler2D u_texture_icon;uniform highp float u_gamma_scale;uniform lowp float u_device_pixel_ratio;varying vec4 v_data0;varying vec4 v_data1;
- #pragma mapbox: define highp vec4 fill_color
- #pragma mapbox: define highp vec4 halo_color
- #pragma mapbox: define lowp float opacity
- #pragma mapbox: define lowp float halo_width
- #pragma mapbox: define lowp float halo_blur
- void main() {
- #pragma mapbox: initialize highp vec4 fill_color
- #pragma mapbox: initialize highp vec4 halo_color
- #pragma mapbox: initialize lowp float opacity
- #pragma mapbox: initialize lowp float halo_width
- #pragma mapbox: initialize lowp float halo_blur
- float fade_opacity=v_data1[2];if (v_data1.w==ICON) {vec2 tex_icon=v_data0.zw;lowp float alpha=opacity*fade_opacity;gl_FragColor=texture2D(u_texture_icon,tex_icon)*alpha;
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- return;}vec2 tex=v_data0.xy;float EDGE_GAMMA=0.105/u_device_pixel_ratio;float gamma_scale=v_data1.x;float size=v_data1.y;float fontScale=size/24.0;lowp vec4 color=fill_color;highp float gamma=EDGE_GAMMA/(fontScale*u_gamma_scale);lowp float buff=(256.0-64.0)/256.0;if (u_is_halo) {color=halo_color;gamma=(halo_blur*1.19/SDF_PX+EDGE_GAMMA)/(fontScale*u_gamma_scale);buff=(6.0-halo_width/fontScale)/SDF_PX;}lowp float dist=texture2D(u_texture,tex).a;highp float gamma_scaled=gamma*gamma_scale;highp float alpha=smoothstep(buff-gamma_scaled,buff+gamma_scaled,dist);gl_FragColor=color*(alpha*opacity*fade_opacity);
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`attribute vec4 a_pos_offset;attribute vec4 a_tex_size;attribute vec4 a_z_tile_anchor;attribute vec3 a_projected_pos;attribute float a_fade_opacity;uniform bool u_is_size_zoom_constant;uniform bool u_is_size_feature_constant;uniform highp float u_size_t;uniform highp float u_size;uniform mat4 u_matrix;uniform mat4 u_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform bool u_rotate_symbol;uniform highp float u_aspect_ratio;uniform highp float u_camera_to_center_distance;uniform float u_fade_change;uniform vec2 u_texsize;uniform vec2 u_texsize_icon;
- #ifdef PROJECTION_GLOBE_VIEW
- uniform vec3 u_tile_id;uniform mat4 u_inv_rot_matrix;uniform vec2 u_merc_center;uniform vec3 u_camera_forward;uniform float u_zoom_transition;uniform vec3 u_ecef_origin;uniform mat4 u_tile_matrix;
- #endif
- varying vec4 v_data0;varying vec4 v_data1;
- #pragma mapbox: define highp vec4 fill_color
- #pragma mapbox: define highp vec4 halo_color
- #pragma mapbox: define lowp float opacity
- #pragma mapbox: define lowp float halo_width
- #pragma mapbox: define lowp float halo_blur
- void main() {
- #pragma mapbox: initialize highp vec4 fill_color
- #pragma mapbox: initialize highp vec4 halo_color
- #pragma mapbox: initialize lowp float opacity
- #pragma mapbox: initialize lowp float halo_width
- #pragma mapbox: initialize lowp float halo_blur
- vec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_tex_size.xy;vec2 a_size=a_tex_size.zw;float a_size_min=floor(a_size[0]*0.5);float is_sdf=a_size[0]-2.0*a_size_min;highp float segment_angle=-a_projected_pos[2];float size;if (!u_is_size_zoom_constant && !u_is_size_feature_constant) {size=mix(a_size_min,a_size[1],u_size_t)/128.0;} else if (u_is_size_zoom_constant && !u_is_size_feature_constant) {size=a_size_min/128.0;} else {size=u_size;}float anchor_z=a_z_tile_anchor.x;vec2 tile_anchor=a_z_tile_anchor.yz;vec3 h=elevationVector(tile_anchor)*elevation(tile_anchor);
- #ifdef PROJECTION_GLOBE_VIEW
- vec3 mercator_pos=mercator_tile_position(u_inv_rot_matrix,tile_anchor,u_tile_id,u_merc_center);vec3 world_pos=mix_globe_mercator(vec3(a_pos,anchor_z)+h,mercator_pos,u_zoom_transition);vec4 ecef_point=u_tile_matrix*vec4(world_pos,1.0);vec3 origin_to_point=ecef_point.xyz-u_ecef_origin;float globe_occlusion_fade=dot(origin_to_point,u_camera_forward) >=0.0 ? 0.0 : 1.0;
- #else
- vec3 world_pos=vec3(a_pos,anchor_z)+h;float globe_occlusion_fade=1.0;
- #endif
- vec4 projected_point=u_matrix*vec4(world_pos,1);highp float camera_to_anchor_distance=projected_point.w;highp float distance_ratio=u_pitch_with_map ?
- camera_to_anchor_distance/u_camera_to_center_distance :
- u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(
- 0.5+0.5*distance_ratio,0.0,1.5);size*=perspective_ratio;float font_scale=size/24.0;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offset_projected_point=u_matrix*vec4(a_pos+vec2(1,0),anchor_z,1);vec2 a=projected_point.xy/projected_point.w;vec2 b=offset_projected_point.xy/offset_projected_point.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}
- #ifdef PROJECTION_GLOBE_VIEW
- vec3 proj_pos=mix_globe_mercator(vec3(a_projected_pos.xy,anchor_z),mercator_pos,u_zoom_transition);
- #else
- vec3 proj_pos=vec3(a_projected_pos.xy,anchor_z);
- #endif
- #ifdef PROJECTED_POS_ON_VIEWPORT
- vec4 projected_pos=u_label_plane_matrix*vec4(proj_pos.xy,0.0,1.0);
- #else
- vec4 projected_pos=u_label_plane_matrix*vec4(proj_pos.xyz+h,1.0);
- #endif
- highp float angle_sin=sin(segment_angle+symbol_rotation);highp float angle_cos=cos(segment_angle+symbol_rotation);mat2 rotation_matrix=mat2(angle_cos,-1.0*angle_sin,angle_sin,angle_cos);float z=0.0;vec2 offset=rotation_matrix*(a_offset/32.0*font_scale);
- #ifdef PITCH_WITH_MAP_TERRAIN
- vec4 tile_pos=u_label_plane_matrix_inv*vec4(a_projected_pos.xy+offset,0.0,1.0);z=elevation(tile_pos.xy);
- #endif
- float occlusion_fade=occlusionFade(projected_point)*globe_occlusion_fade;gl_Position=mix(u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+offset,z,1.0),AWAY,float(projected_point.w <=0.0 || occlusion_fade==0.0));float gamma_scale=gl_Position.w;vec2 fade_opacity=unpack_opacity(a_fade_opacity);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;float interpolated_fade_opacity=max(0.0,min(occlusion_fade,fade_opacity[0]+fade_change));float projection_transition_fade=1.0;
- #if defined(PROJECTED_POS_ON_VIEWPORT) && defined(PROJECTION_GLOBE_VIEW)
- projection_transition_fade=1.0-step(EPSILON,u_zoom_transition);
- #endif
- v_data0.xy=a_tex/u_texsize;v_data0.zw=a_tex/u_texsize_icon;v_data1=vec4(gamma_scale,size,interpolated_fade_opacity*projection_transition_fade,is_sdf);}`),terrainRaster:Qe(`uniform sampler2D u_image0;varying vec2 v_pos0;
- #ifdef FOG
- varying float v_fog_opacity;
- #endif
- void main() {vec4 color=texture2D(u_image0,v_pos0);
- #ifdef FOG
- color=fog_dither(fog_apply_from_vert(color,v_fog_opacity));
- #endif
- gl_FragColor=color;
- #ifdef TERRAIN_WIREFRAME
- gl_FragColor=vec4(1.0,0.0,0.0,0.8);
- #endif
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`uniform mat4 u_matrix;uniform float u_skirt_height;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos0;
- #ifdef FOG
- varying float v_fog_opacity;
- #endif
- const float skirtOffset=24575.0;const float wireframeOffset=0.00015;void main() {v_pos0=a_texture_pos/8192.0;float skirt=float(a_pos.x >=skirtOffset);float elevation=elevation(a_texture_pos)-skirt*u_skirt_height;
- #ifdef TERRAIN_WIREFRAME
- elevation+=u_skirt_height*u_skirt_height*wireframeOffset;
- #endif
- vec2 decodedPos=a_pos-vec2(skirt*skirtOffset,0.0);gl_Position=u_matrix*vec4(decodedPos,elevation,1.0);
- #ifdef FOG
- v_fog_opacity=fog(fog_position(vec3(decodedPos,elevation)));
- #endif
- }`),terrainDepth:Qe(`#ifdef GL_ES
- precision highp float;
- #endif
- varying float v_depth;void main() {gl_FragColor=pack_depth(v_depth);}`,"uniform mat4 u_matrix;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying float v_depth;void main() {float elevation=elevation(a_texture_pos);gl_Position=u_matrix*vec4(a_pos,elevation,1.0);v_depth=gl_Position.z/gl_Position.w;}"),skybox:Qe(`
- varying lowp vec3 v_uv;uniform lowp samplerCube u_cubemap;uniform lowp float u_opacity;uniform highp float u_temporal_offset;uniform highp vec3 u_sun_direction;float sun_disk(highp vec3 ray_direction,highp vec3 sun_direction) {highp float cos_angle=dot(normalize(ray_direction),sun_direction);const highp float cos_sun_angular_diameter=0.99996192306;const highp float smoothstep_delta=1e-5;return smoothstep(
- cos_sun_angular_diameter-smoothstep_delta,cos_sun_angular_diameter+smoothstep_delta,cos_angle);}float map(float value,float start,float end,float new_start,float new_end) {return ((value-start)*(new_end-new_start))/(end-start)+new_start;}void main() {vec3 uv=v_uv;const float y_bias=0.015;uv.y+=y_bias;uv.y=pow(abs(uv.y),1.0/5.0);uv.y=map(uv.y,0.0,1.0,-1.0,1.0);vec3 sky_color=textureCube(u_cubemap,uv).rgb;
- #ifdef FOG
- sky_color=fog_apply_sky_gradient(v_uv.xzy,sky_color);
- #endif
- sky_color.rgb=dither(sky_color.rgb,gl_FragCoord.xy+u_temporal_offset);sky_color+=0.1*sun_disk(v_uv,u_sun_direction);gl_FragColor=vec4(sky_color*u_opacity,u_opacity);
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,iu),skyboxGradient:Qe(`varying highp vec3 v_uv;uniform lowp sampler2D u_color_ramp;uniform highp vec3 u_center_direction;uniform lowp float u_radius;uniform lowp float u_opacity;uniform highp float u_temporal_offset;void main() {float progress=acos(dot(normalize(v_uv),u_center_direction))/u_radius;vec4 color=texture2D(u_color_ramp,vec2(progress,0.5));
- #ifdef FOG
- color.rgb=fog_apply_sky_gradient(v_uv.xzy,color.rgb/color.a)*color.a;
- #endif
- color*=u_opacity;color.rgb=dither(color.rgb,gl_FragCoord.xy+u_temporal_offset);gl_FragColor=color;
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,iu),skyboxCapture:Qe(`
- varying highp vec3 v_position;uniform highp float u_sun_intensity;uniform highp float u_luminance;uniform lowp vec3 u_sun_direction;uniform highp vec4 u_color_tint_r;uniform highp vec4 u_color_tint_m;
- #ifdef GL_ES
- precision highp float;
- #endif
- #define BETA_R vec3(5.5e-6,13.0e-6,22.4e-6)
- #define BETA_M vec3(21e-6,21e-6,21e-6)
- #define MIE_G 0.76
- #define DENSITY_HEIGHT_SCALE_R 8000.0
- #define DENSITY_HEIGHT_SCALE_M 1200.0
- #define PLANET_RADIUS 6360e3
- #define ATMOSPHERE_RADIUS 6420e3
- #define SAMPLE_STEPS 10
- #define DENSITY_STEPS 4
- float ray_sphere_exit(vec3 orig,vec3 dir,float radius) {float a=dot(dir,dir);float b=2.0*dot(dir,orig);float c=dot(orig,orig)-radius*radius;float d=sqrt(b*b-4.0*a*c);return (-b+d)/(2.0*a);}vec3 extinction(vec2 density) {return exp(-vec3(BETA_R*u_color_tint_r.a*density.x+BETA_M*u_color_tint_m.a*density.y));}vec2 local_density(vec3 point) {float height=max(length(point)-PLANET_RADIUS,0.0);float exp_r=exp(-height/DENSITY_HEIGHT_SCALE_R);float exp_m=exp(-height/DENSITY_HEIGHT_SCALE_M);return vec2(exp_r,exp_m);}float phase_ray(float cos_angle) {return (3.0/(16.0*PI))*(1.0+cos_angle*cos_angle);}float phase_mie(float cos_angle) {return (3.0/(8.0*PI))*((1.0-MIE_G*MIE_G)*(1.0+cos_angle*cos_angle))/((2.0+MIE_G*MIE_G)*pow(1.0+MIE_G*MIE_G-2.0*MIE_G*cos_angle,1.5));}vec2 density_to_atmosphere(vec3 point,vec3 light_dir) {float ray_len=ray_sphere_exit(point,light_dir,ATMOSPHERE_RADIUS);float step_len=ray_len/float(DENSITY_STEPS);vec2 density_point_to_atmosphere=vec2(0.0);for (int i=0; i < DENSITY_STEPS;++i) {vec3 point_on_ray=point+light_dir*((float(i)+0.5)*step_len);density_point_to_atmosphere+=local_density(point_on_ray)*step_len;;}return density_point_to_atmosphere;}vec3 atmosphere(vec3 ray_dir,vec3 sun_direction,float sun_intensity) {vec2 density_orig_to_point=vec2(0.0);vec3 scatter_r=vec3(0.0);vec3 scatter_m=vec3(0.0);vec3 origin=vec3(0.0,PLANET_RADIUS,0.0);float ray_len=ray_sphere_exit(origin,ray_dir,ATMOSPHERE_RADIUS);float step_len=ray_len/float(SAMPLE_STEPS);for (int i=0; i < SAMPLE_STEPS;++i) {vec3 point_on_ray=origin+ray_dir*((float(i)+0.5)*step_len);vec2 density=local_density(point_on_ray)*step_len;density_orig_to_point+=density;vec2 density_point_to_atmosphere=density_to_atmosphere(point_on_ray,sun_direction);vec2 density_orig_to_atmosphere=density_orig_to_point+density_point_to_atmosphere;vec3 extinction=extinction(density_orig_to_atmosphere);scatter_r+=density.x*extinction;scatter_m+=density.y*extinction;}float cos_angle=dot(ray_dir,sun_direction);float phase_r=phase_ray(cos_angle);float phase_m=phase_mie(cos_angle);vec3 beta_r=BETA_R*u_color_tint_r.rgb*u_color_tint_r.a;vec3 beta_m=BETA_M*u_color_tint_m.rgb*u_color_tint_m.a;return (scatter_r*phase_r*beta_r+scatter_m*phase_m*beta_m)*sun_intensity;}const float A=0.15;const float B=0.50;const float C=0.10;const float D=0.20;const float E=0.02;const float F=0.30;vec3 uncharted2_tonemap(vec3 x) {return ((x*(A*x+C*B)+D*E)/(x*(A*x+B)+D*F))-E/F;}void main() {vec3 ray_direction=v_position;ray_direction.y=pow(ray_direction.y,5.0);const float y_bias=0.015;ray_direction.y+=y_bias;vec3 color=atmosphere(normalize(ray_direction),u_sun_direction,u_sun_intensity);float white_scale=1.0748724675633854;color=uncharted2_tonemap((log2(2.0/pow(u_luminance,4.0)))*color)*white_scale;gl_FragColor=vec4(color,1.0);}`,"attribute highp vec3 a_pos_3f;uniform mat3 u_matrix_3f;varying highp vec3 v_position;float map(float value,float start,float end,float new_start,float new_end) {return ((value-start)*(new_end-new_start))/(end-start)+new_start;}void main() {vec4 pos=vec4(u_matrix_3f*a_pos_3f,1.0);v_position=pos.xyz;v_position.y*=-1.0;v_position.y=map(v_position.y,-1.0,1.0,0.0,1.0);gl_Position=vec4(a_pos_3f.xy,0.0,1.0);}"),globeRaster:Qe(`uniform sampler2D u_image0;varying vec2 v_pos0;void main() {gl_FragColor=texture2D(u_image0,v_pos0);
- #ifdef TERRAIN_WIREFRAME
- gl_FragColor=vec4(1.0,0.0,0.0,0.8);
- #endif
- #ifdef OVERDRAW_INSPECTOR
- gl_FragColor=vec4(1.0);
- #endif
- }`,`uniform mat4 u_proj_matrix;uniform mat4 u_globe_matrix;uniform mat4 u_merc_matrix;uniform float u_zoom_transition;uniform vec2 u_merc_center;uniform mat3 u_grid_matrix;
- #ifdef GLOBE_POLES
- attribute vec3 a_globe_pos;attribute vec2 a_merc_pos;attribute vec2 a_uv;
- #else
- attribute vec2 a_pos;
- #endif
- varying vec2 v_pos0;const float wireframeOffset=1e3;float mercatorXfromLng(float lng) {return (180.0+lng)/360.0;}float mercatorYfromLat(float lat) {return (180.0-(RAD_TO_DEG*log(tan(QUARTER_PI+lat/2.0*DEG_TO_RAD))))/360.0;}vec3 latLngToECEF(vec2 latLng) {latLng=DEG_TO_RAD*latLng;float cosLat=cos(latLng[0]);float sinLat=sin(latLng[0]);float cosLng=cos(latLng[1]);float sinLng=sin(latLng[1]);float sx=cosLat*sinLng*GLOBE_RADIUS;float sy=-sinLat*GLOBE_RADIUS;float sz=cosLat*cosLng*GLOBE_RADIUS;return vec3(sx,sy,sz);}void main() {
- #ifdef GLOBE_POLES
- vec3 globe_pos=a_globe_pos;vec2 merc_pos=a_merc_pos;vec2 uv=a_uv;
- #else
- float tiles=u_grid_matrix[0][2];float idy=u_grid_matrix[1][2];float S=u_grid_matrix[2][2];vec3 latLng=u_grid_matrix*vec3(a_pos,1.0);float mercatorY=mercatorYfromLat(latLng[0]);float uvY=mercatorY*tiles-idy;float mercatorX=mercatorXfromLng(latLng[1]);float uvX=a_pos[0]*S;vec3 globe_pos=latLngToECEF(latLng.xy);vec2 merc_pos=vec2(mercatorX,mercatorY);vec2 uv=vec2(uvX,uvY);
- #endif
- v_pos0=uv;uv=uv*EXTENT;vec4 up_vector=vec4(elevationVector(uv),1.0);float height=elevation(uv);
- #ifdef TERRAIN_WIREFRAME
- height+=wireframeOffset;
- #endif
- vec4 globe=u_globe_matrix*vec4(globe_pos+up_vector.xyz*height,1.0);vec4 mercator=vec4(0.0);if (u_zoom_transition > 0.0) {mercator=vec4(merc_pos,height,1.0);mercator.xy-=u_merc_center;mercator.x=wrap(mercator.x,-0.5,0.5);mercator=u_merc_matrix*mercator;}vec3 position=mix(globe.xyz,mercator.xyz,u_zoom_transition);gl_Position=u_proj_matrix*vec4(position,1.0);}`),globeAtmosphere:Qe(`uniform float u_opacity;uniform highp float u_fadeout_range;uniform vec3 u_start_color;uniform vec3 u_end_color;uniform highp vec3 u_globe_pos;uniform highp float u_globe_radius;varying highp vec3 v_ray_dir;void main() {highp vec3 dir=normalize(v_ray_dir);highp vec3 closest_point=abs(dot(u_globe_pos,dir))*dir;float norm_dist_from_center=length(closest_point-u_globe_pos)/u_globe_radius;if (norm_dist_from_center < 1.0)
- discard;float t=clamp(1.0-sqrt(norm_dist_from_center-1.0)/u_fadeout_range,0.0,1.0);vec3 color=mix(u_start_color,u_end_color,1.0-t);gl_FragColor=vec4(color*t*u_opacity,u_opacity);}`,"attribute vec3 a_pos;attribute vec2 a_uv;uniform vec3 u_frustum_tl;uniform vec3 u_frustum_tr;uniform vec3 u_frustum_br;uniform vec3 u_frustum_bl;varying highp vec3 v_ray_dir;void main() {v_ray_dir=mix(mix(u_frustum_tl,u_frustum_tr,a_uv.x),mix(u_frustum_bl,u_frustum_br,a_uv.x),a_uv.y);gl_Position=vec4(a_pos,1.0);}")};function Qe(Ee,w,se){const it=/#pragma mapbox: ([\w]+) ([\w]+) ([\w]+) ([\w]+)/g,xt=/uniform (highp |mediump |lowp )?([\w]+) ([\w]+)([\s]*)([\w]*)/g,Dt=w.match(/attribute (highp |mediump |lowp )?([\w]+) ([\w]+)/g),Ot=Ee.match(xt),rn=w.match(xt),Tn=Vo.match(xt);let kn=rn?rn.concat(Ot):Ot;se||(Tu.staticUniforms&&(kn=Tu.staticUniforms.concat(kn)),wt.staticUniforms&&(kn=wt.staticUniforms.concat(kn))),kn&&(kn=kn.concat(Tn));const Bn={};return{fragmentSource:Ee=Ee.replace(it,(Wn,Fr,ri,Zr,Sr)=>(Bn[Sr]=!0,Fr==="define"?`
- #ifndef HAS_UNIFORM_u_${Sr}
- varying ${ri} ${Zr} ${Sr};
- #else
- uniform ${ri} ${Zr} u_${Sr};
- #endif
- `:`
- #ifdef HAS_UNIFORM_u_${Sr}
- ${ri} ${Zr} ${Sr} = u_${Sr};
- #endif
- `)),vertexSource:w=w.replace(it,(Wn,Fr,ri,Zr,Sr)=>{const Di=Zr==="float"?"vec2":"vec4",di=Sr.match(/color/)?"color":Di;return Bn[Sr]?Fr==="define"?`
- #ifndef HAS_UNIFORM_u_${Sr}
- uniform lowp float u_${Sr}_t;
- attribute ${ri} ${Di} a_${Sr};
- varying ${ri} ${Zr} ${Sr};
- #else
- uniform ${ri} ${Zr} u_${Sr};
- #endif
- `:di==="vec4"?`
- #ifndef HAS_UNIFORM_u_${Sr}
- ${Sr} = a_${Sr};
- #else
- ${ri} ${Zr} ${Sr} = u_${Sr};
- #endif
- `:`
- #ifndef HAS_UNIFORM_u_${Sr}
- ${Sr} = unpack_mix_${di}(a_${Sr}, u_${Sr}_t);
- #else
- ${ri} ${Zr} ${Sr} = u_${Sr};
- #endif
- `:Fr==="define"?`
- #ifndef HAS_UNIFORM_u_${Sr}
- uniform lowp float u_${Sr}_t;
- attribute ${ri} ${Di} a_${Sr};
- #else
- uniform ${ri} ${Zr} u_${Sr};
- #endif
- `:di==="vec4"?`
- #ifndef HAS_UNIFORM_u_${Sr}
- ${ri} ${Zr} ${Sr} = a_${Sr};
- #else
- ${ri} ${Zr} ${Sr} = u_${Sr};
- #endif
- `:`
- #ifndef HAS_UNIFORM_u_${Sr}
- ${ri} ${Zr} ${Sr} = unpack_mix_${di}(a_${Sr}, u_${Sr}_t);
- #else
- ${ri} ${Zr} ${Sr} = u_${Sr};
- #endif
- `}),staticAttributes:Dt,staticUniforms:kn}}class yt{constructor(){this.boundProgram=null,this.boundLayoutVertexBuffer=null,this.boundPaintVertexBuffers=[],this.boundIndexBuffer=null,this.boundVertexOffset=null,this.boundDynamicVertexBuffer=null,this.vao=null}bind(w,se,it,xt,Dt,Ot,rn,Tn){this.context=w;let kn=this.boundPaintVertexBuffers.length!==xt.length;for(let Bn=0;!kn&&Bn<xt.length;Bn++)this.boundPaintVertexBuffers[Bn]!==xt[Bn]&&(kn=!0);w.extVertexArrayObject&&this.vao&&this.boundProgram===se&&this.boundLayoutVertexBuffer===it&&!kn&&this.boundIndexBuffer===Dt&&this.boundVertexOffset===Ot&&this.boundDynamicVertexBuffer===rn&&this.boundDynamicVertexBuffer2===Tn?(w.bindVertexArrayOES.set(this.vao),rn&&rn.bind(),Dt&&Dt.dynamicDraw&&Dt.bind(),Tn&&Tn.bind()):this.freshBind(se,it,xt,Dt,Ot,rn,Tn)}freshBind(w,se,it,xt,Dt,Ot,rn){let Tn;const kn=w.numAttributes,Bn=this.context,Wn=Bn.gl;if(Bn.extVertexArrayObject)this.vao&&this.destroy(),this.vao=Bn.extVertexArrayObject.createVertexArrayOES(),Bn.bindVertexArrayOES.set(this.vao),Tn=0,this.boundProgram=w,this.boundLayoutVertexBuffer=se,this.boundPaintVertexBuffers=it,this.boundIndexBuffer=xt,this.boundVertexOffset=Dt,this.boundDynamicVertexBuffer=Ot,this.boundDynamicVertexBuffer2=rn;else{Tn=Bn.currentNumAttributes||0;for(let Fr=kn;Fr<Tn;Fr++)Wn.disableVertexAttribArray(Fr)}se.enableAttributes(Wn,w);for(const Fr of it)Fr.enableAttributes(Wn,w);Ot&&Ot.enableAttributes(Wn,w),rn&&rn.enableAttributes(Wn,w),se.bind(),se.setVertexAttribPointers(Wn,w,Dt);for(const Fr of it)Fr.bind(),Fr.setVertexAttribPointers(Wn,w,Dt);Ot&&(Ot.bind(),Ot.setVertexAttribPointers(Wn,w,Dt)),xt&&xt.bind(),rn&&(rn.bind(),rn.setVertexAttribPointers(Wn,w,Dt)),Bn.currentNumAttributes=kn}destroy(){this.vao&&(this.context.extVertexArrayObject.deleteVertexArrayOES(this.vao),this.vao=null)}}function Rt(Ee,w){const se=Math.pow(2,w.canonical.z),it=w.canonical.y;return[new m.MercatorCoordinate(0,it/se).toLngLat().lat,new m.MercatorCoordinate(0,(it+1)/se).toLngLat().lat]}function jt(Ee,w,se,it,xt,Dt,Ot){const rn=Ee.context,Tn=rn.gl,kn=se.fbo;if(!kn)return;Ee.prepareDrawTile();const Bn=Ee.useProgram("hillshade");rn.activeTexture.set(Tn.TEXTURE0),Tn.bindTexture(Tn.TEXTURE_2D,kn.colorAttachment.get());const Wn=((Sr,Di,di,wi)=>{const Ti=di.paint.get("hillshade-shadow-color"),Oi=di.paint.get("hillshade-highlight-color"),_i=di.paint.get("hillshade-accent-color");let Fi=di.paint.get("hillshade-illumination-direction")*(Math.PI/180);di.paint.get("hillshade-illumination-anchor")==="viewport"&&(Fi-=Sr.transform.angle);const Ta=!Sr.options.moving;return{u_matrix:wi||Sr.transform.calculateProjMatrix(Di.tileID.toUnwrapped(),Ta),u_image:0,u_latrange:Rt(0,Di.tileID),u_light:[di.paint.get("hillshade-exaggeration"),Fi],u_shadow:Ti,u_highlight:Oi,u_accent:_i}})(Ee,se,it,Ee.terrain?w.projMatrix:null);Ee.prepareDrawProgram(rn,Bn,w.toUnwrapped());const{tileBoundsBuffer:Fr,tileBoundsIndexBuffer:ri,tileBoundsSegments:Zr}=Ee.getTileBoundsBuffers(se);Bn.draw(rn,Tn.TRIANGLES,xt,Dt,Ot,m.CullFaceMode.disabled,Wn,it.id,Fr,ri,Zr)}function dn(Ee,w,se){if(!w.needsDEMTextureUpload)return;const it=Ee.context,xt=it.gl;it.pixelStoreUnpackPremultiplyAlpha.set(!1),w.demTexture=w.demTexture||Ee.getTileTexture(se.stride);const Dt=se.getPixels();w.demTexture?w.demTexture.update(Dt,{premultiply:!1}):w.demTexture=new m.Texture(it,Dt,xt.RGBA,{premultiply:!1}),w.needsDEMTextureUpload=!1}function yn(Ee,w,se,it,xt,Dt){const Ot=Ee.context,rn=Ot.gl;if(!w.dem)return;const Tn=w.dem;if(Ot.activeTexture.set(rn.TEXTURE1),dn(Ee,w,Tn),!w.demTexture)return;w.demTexture.bind(rn.NEAREST,rn.CLAMP_TO_EDGE);const kn=Tn.dim;Ot.activeTexture.set(rn.TEXTURE0);let Bn=w.fbo;if(!Bn){const Zr=new m.Texture(Ot,{width:kn,height:kn,data:null},rn.RGBA);Zr.bind(rn.LINEAR,rn.CLAMP_TO_EDGE),Bn=w.fbo=Ot.createFramebuffer(kn,kn,!0),Bn.colorAttachment.set(Zr.texture)}Ot.bindFramebuffer.set(Bn.framebuffer),Ot.viewport.set([0,0,kn,kn]);const{tileBoundsBuffer:Wn,tileBoundsIndexBuffer:Fr,tileBoundsSegments:ri}=Ee.getMercatorTileBoundsBuffers();Ee.useProgram("hillshadePrepare").draw(Ot,rn.TRIANGLES,it,xt,Dt,m.CullFaceMode.disabled,((Zr,Sr)=>{const Di=Sr.stride,di=m.create();return m.ortho(di,0,m.EXTENT,-m.EXTENT,0,0,1),m.translate(di,di,[0,-m.EXTENT,0]),{u_matrix:di,u_image:1,u_dimension:[Di,Di],u_zoom:Zr.overscaledZ,u_unpack:Sr.unpackVector}})(w.tileID,Tn),se.id,Wn,Fr,ri),w.needsHillshadePrepare=!1}const In=(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_image0:new m.Uniform1i(Ee,w.u_image0),u_skirt_height:new m.Uniform1f(Ee,w.u_skirt_height)}),vr=(Ee,w)=>({u_matrix:Ee,u_image0:0,u_skirt_height:w}),Jn=(Ee,w,se,it,xt,Dt)=>({u_proj_matrix:Float32Array.from(Ee),u_globe_matrix:w,u_merc_matrix:se,u_zoom_transition:it,u_merc_center:xt,u_image0:0,u_grid_matrix:Dt?Float32Array.from(Dt):new Float32Array(9)});function li(Ee,w){return Ee!=null&&w!=null&&!(!Ee.hasData()||!w.hasData())&&Ee.demTexture!=null&&w.demTexture!=null&&Ee.tileID.key!==w.tileID.key}const xa=new class{constructor(){this.operations={}}newMorphing(Ee,w,se,it,xt){if(Ee in this.operations){const Dt=this.operations[Ee];Dt.to.tileID.key!==se.tileID.key&&(Dt.queued=se)}else this.operations[Ee]={startTime:it,phase:0,duration:xt,from:w,to:se,queued:null}}getMorphValuesForProxy(Ee){if(!(Ee in this.operations))return null;const w=this.operations[Ee];return{from:w.from,to:w.to,phase:w.phase}}update(Ee){for(const w in this.operations){const se=this.operations[w];for(se.phase=(Ee-se.startTime)/se.duration;se.phase>=1||!this._validOp(se);)if(!this._nextOp(se,Ee)){delete this.operations[w];break}}}_nextOp(Ee,w){return!!Ee.queued&&(Ee.from=Ee.to,Ee.to=Ee.queued,Ee.queued=null,Ee.phase=0,Ee.startTime=w,!0)}_validOp(Ee){return Ee.from.hasData()&&Ee.to.hasData()}},Ri={0:null,1:"TERRAIN_VERTEX_MORPHING",2:"TERRAIN_WIREFRAME"};function fa(Ee,w){const se=1<<Ee.z;return!w&&(Ee.x===0||Ee.x===se-1)||Ee.y===0||Ee.y===se-1}const oo=Ee=>({u_matrix:Ee});function ts(Ee,w,se,it,xt){if(xt>0){const Dt=m.exported.now(),Ot=(Dt-Ee.timeAdded)/xt,rn=w?(Dt-w.timeAdded)/xt:-1,Tn=se.getSource(),kn=it.coveringZoomLevel({tileSize:Tn.tileSize,roundZoom:Tn.roundZoom}),Bn=!w||Math.abs(w.tileID.overscaledZ-kn)>Math.abs(Ee.tileID.overscaledZ-kn),Wn=Bn&&Ee.refreshedUponExpiration?1:m.clamp(Bn?Ot:1-rn,0,1);return Ee.refreshedUponExpiration&&Ot>=1&&(Ee.refreshedUponExpiration=!1),w?{opacity:1,mix:1-Wn}:{opacity:Wn,mix:0}}return{opacity:1,mix:0}}const bl=2*m.mercatorZfromAltitude(1,0)*m.GLOBE_RADIUS*Math.PI;class nl extends m.SourceCache{constructor(w){const se={type:"raster-dem",maxzoom:w.transform.maxZoom},it=new wn(Wo(),null),xt=ta("mock-dem",se,it,w.style);super("mock-dem",xt,!1),xt.setEventedParent(this),this._sourceLoaded=!0}_loadTile(w,se){w.state="loaded",se(null)}}class Fs extends m.SourceCache{constructor(w){const se=ta("proxy",{type:"geojson",maxzoom:w.transform.maxZoom},new wn(Wo(),null),w.style);super("proxy",se,!1),se.setEventedParent(this),this.map=this.getSource().map=w,this.used=this._sourceLoaded=!0,this.renderCache=[],this.renderCachePool=[],this.proxyCachedFBO={}}update(w,se,it){if(w.freezeTileCoverage)return;this.transform=w;const xt=w.coveringTiles({tileSize:this._source.tileSize,minzoom:this._source.minzoom,maxzoom:this._source.maxzoom,roundZoom:this._source.roundZoom,reparseOverscaled:this._source.reparseOverscaled}).reduce((Dt,Ot)=>{if(Dt[Ot.key]="",!this._tiles[Ot.key]){const rn=new m.Tile(Ot,this._source.tileSize*Ot.overscaleFactor(),w.tileZoom);rn.state="loaded",this._tiles[Ot.key]=rn}return Dt},{});for(const Dt in this._tiles)Dt in xt||(this.freeFBO(Dt),this._tiles[Dt].unloadVectorData(),delete this._tiles[Dt])}freeFBO(w){const se=this.proxyCachedFBO[w];if(se!==void 0){const it=Object.values(se);this.renderCachePool.push(...it),delete this.proxyCachedFBO[w]}}deallocRenderCache(){this.renderCache.forEach(w=>w.fb.destroy()),this.renderCache=[],this.renderCachePool=[],this.proxyCachedFBO={}}}class eu extends m.OverscaledTileID{constructor(w,se,it){super(w.overscaledZ,w.wrap,w.canonical.z,w.canonical.x,w.canonical.y),this.proxyTileKey=se,this.projMatrix=it}}class Gs extends m.Elevation{constructor(w,se){super(),this.painter=w,this.terrainTileForTile={},this.prevTerrainTileForTile={};const[it,xt,Dt]=function(Tn){const kn=new m.StructArrayLayout4i8,Bn=new m.StructArrayLayout3ui6,Wn=131;kn.reserve(17161),Bn.reserve(33800);const Fr=m.EXTENT/128,ri=m.EXTENT+Fr/2,Zr=ri+Fr;for(let Di=-Fr;Di<Zr;Di+=Fr)for(let di=-Fr;di<Zr;di+=Fr){const wi=di<0||di>ri||Di<0||Di>ri?24575:0,Ti=m.clamp(Math.round(di),0,m.EXTENT),Oi=m.clamp(Math.round(Di),0,m.EXTENT);kn.emplaceBack(Ti+wi,Oi,Ti,Oi)}const Sr=(Di,di)=>{const wi=di*Wn+Di;Bn.emplaceBack(wi+1,wi,wi+Wn),Bn.emplaceBack(wi+Wn,wi+Wn+1,wi+1)};for(let Di=1;Di<129;Di++)for(let di=1;di<129;di++)Sr(di,Di);return[0,129].forEach(Di=>{for(let di=0;di<130;di++)Sr(di,Di),Sr(Di,di)}),[kn,Bn,32768]}(),Ot=w.context;this.gridBuffer=Ot.createVertexBuffer(it,m.boundsAttributes.members),this.gridIndexBuffer=Ot.createIndexBuffer(xt),this.gridSegments=m.SegmentVector.simpleSegment(0,0,it.length,xt.length),this.gridNoSkirtSegments=m.SegmentVector.simpleSegment(0,0,it.length,Dt),this.proxyCoords=[],this.proxiedCoords={},this._visibleDemTiles=[],this._drapedRenderBatches=[],this._sourceTilesOverlap={},this.proxySourceCache=new Fs(se.map),this.orthoMatrix=m.create(),m.ortho(this.orthoMatrix,0,m.EXTENT,0,m.EXTENT,0,1);const rn=Ot.gl;this._overlapStencilMode=new m.StencilMode({func:rn.GEQUAL,mask:255},0,255,rn.KEEP,rn.KEEP,rn.REPLACE),this._previousZoom=w.transform.zoom,this.pool=[],this._findCoveringTileCache={},this._tilesDirty={},this.style=se,this._useVertexMorphing=!0,this._exaggeration=1,this._mockSourceCache=new nl(se.map)}set style(w){w.on("data",this._onStyleDataEvent.bind(this)),w.on("neworder",this._checkRenderCacheEfficiency.bind(this)),this._style=w,this._checkRenderCacheEfficiency()}update(w,se,it){if(w&&w.terrain){this._style!==w&&(this.style=w),this.enabled=!0;const xt=w.terrain.properties;this.sourceCache=w.terrain.drapeRenderMode===0?this._mockSourceCache:w._getSourceCache(xt.get("source")),this._exaggeration=xt.get("exaggeration");const Dt=()=>{this.sourceCache.used&&m.warnOnce(`Raster DEM source '${this.sourceCache.id}' is used both for terrain and as layer source.
- This leads to lower resolution of hillshade. For full hillshade resolution but higher memory consumption, define another raster DEM source.`);const Ot=this.getScaledDemTileSize();this.sourceCache.update(se,Ot,!0),this.resetTileLookupCache(this.sourceCache.id)};this.sourceCache.usedForTerrain||(this.resetTileLookupCache(this.sourceCache.id),this.sourceCache.usedForTerrain=!0,Dt(),this._initializing=!0),Dt(),se.updateElevation(!it),this.resetTileLookupCache(this.proxySourceCache.id),this.proxySourceCache.update(se),this._emptyDEMTextureDirty=!0}else this._disable()}resetTileLookupCache(w){this._findCoveringTileCache[w]={}}getScaledDemTileSize(){return this.sourceCache.getSource().tileSize/128*this.proxySourceCache.getSource().tileSize}_checkRenderCacheEfficiency(){const w=this.renderCacheEfficiency(this._style);this._style.map._optimizeForTerrain||w.efficiency!==100&&m.warnOnce(`Terrain render cache efficiency is not optimal (${w.efficiency}%) and performance
- may be affected negatively, consider placing all background, fill and line layers before layer
- with id '${w.firstUndrapedLayer}' or create a map using optimizeForTerrain: true option.`)}_onStyleDataEvent(w){w.coord&&w.dataType==="source"?this._clearRenderCacheForTile(w.sourceCacheId,w.coord):w.dataType==="style"&&(this._invalidateRenderCache=!0)}_disable(){if(this.enabled&&(this.enabled=!1,this._sharedDepthStencil=void 0,this.proxySourceCache.deallocRenderCache(),this._style))for(const w in this._style._sourceCaches)this._style._sourceCaches[w].usedForTerrain=!1}destroy(){this._disable(),this._emptyDEMTexture&&this._emptyDEMTexture.destroy(),this._emptyDepthBufferTexture&&this._emptyDepthBufferTexture.destroy(),this.pool.forEach(w=>w.fb.destroy()),this.pool=[],this._depthFBO&&(this._depthFBO.destroy(),this._depthFBO=void 0,this._depthTexture=void 0)}_source(){return this.enabled?this.sourceCache:null}exaggeration(){return this._exaggeration}get visibleDemTiles(){return this._visibleDemTiles}get drapeBufferSize(){const w=2*this.proxySourceCache.getSource().tileSize;return[w,w]}set useVertexMorphing(w){this._useVertexMorphing=w}updateTileBinding(w){if(!this.enabled)return;this.prevTerrainTileForTile=this.terrainTileForTile;const se=this.proxySourceCache,it=this.painter.transform;this._initializing&&(this._initializing=it._centerAltitude===0&&this.getAtPointOrZero(m.MercatorCoordinate.fromLngLat(it.center),-1)===-1,this._emptyDEMTextureDirty=!this._initializing);const xt=this.proxyCoords=se.getIds().map(Tn=>{const kn=se.getTileByID(Tn).tileID;return kn.projMatrix=it.calculateProjMatrix(kn.toUnwrapped()),kn});(function(Tn,kn){const Bn=kn.transform.pointCoordinate(kn.transform.getCameraPoint()),Wn=new m.pointGeometry(Bn.x,Bn.y);Tn.sort((Fr,ri)=>{if(ri.overscaledZ-Fr.overscaledZ)return ri.overscaledZ-Fr.overscaledZ;const Zr=new m.pointGeometry(Fr.canonical.x+(1<<Fr.canonical.z)*Fr.wrap,Fr.canonical.y),Sr=new m.pointGeometry(ri.canonical.x+(1<<ri.canonical.z)*ri.wrap,ri.canonical.y),Di=Wn.mult(1<<Fr.canonical.z);return Di.x-=.5,Di.y-=.5,Di.distSqr(Zr)-Di.distSqr(Sr)})})(xt,this.painter),this._previousZoom=it.zoom;const Dt=this.proxyToSource||{};this.proxyToSource={},xt.forEach(Tn=>{this.proxyToSource[Tn.key]={}}),this.terrainTileForTile={};const Ot=this._style._sourceCaches;for(const Tn in Ot){const kn=Ot[Tn];if(!kn.used||(kn!==this.sourceCache&&this.resetTileLookupCache(kn.id),this._setupProxiedCoordsForOrtho(kn,w[Tn],Dt),kn.usedForTerrain))continue;const Bn=w[Tn];kn.getSource().reparseOverscaled&&this._assignTerrainTiles(Bn)}this.proxiedCoords[se.id]=xt.map(Tn=>new eu(Tn,Tn.key,this.orthoMatrix)),this._assignTerrainTiles(xt),this._prepareDEMTextures(),this._setupDrapedRenderBatches(),this._initFBOPool(),this._setupRenderCache(Dt),this.renderingToTexture=!1,this._updateTimestamp=m.exported.now();const rn={};this._visibleDemTiles=[];for(const Tn of this.proxyCoords){const kn=this.terrainTileForTile[Tn.key];if(!kn)continue;const Bn=kn.tileID.key;Bn in rn||(this._visibleDemTiles.push(kn),rn[Bn]=Bn)}}_assignTerrainTiles(w){this._initializing||w.forEach(se=>{if(this.terrainTileForTile[se.key])return;const it=this._findTileCoveringTileID(se,this.sourceCache);it&&(this.terrainTileForTile[se.key]=it)})}_prepareDEMTextures(){const w=this.painter.context,se=w.gl;for(const it in this.terrainTileForTile){const xt=this.terrainTileForTile[it],Dt=xt.dem;!Dt||xt.demTexture&&!xt.needsDEMTextureUpload||(w.activeTexture.set(se.TEXTURE1),dn(this.painter,xt,Dt))}}_prepareDemTileUniforms(w,se,it,xt){if(!se||se.demTexture==null)return!1;const Dt=w.tileID.canonical,Ot=Math.pow(2,se.tileID.canonical.z-Dt.z),rn=xt||"";return it[`u_dem_tl${rn}`]=[Dt.x*Ot%1,Dt.y*Ot%1],it[`u_dem_scale${rn}`]=Ot,!0}get emptyDEMTexture(){return!this._emptyDEMTextureDirty&&this._emptyDEMTexture?this._emptyDEMTexture:this._updateEmptyDEMTexture()}get emptyDepthBufferTexture(){const w=this.painter.context,se=w.gl;if(!this._emptyDepthBufferTexture){const it=new m.RGBAImage({width:1,height:1},Uint8Array.of(255,255,255,255));this._emptyDepthBufferTexture=new m.Texture(w,it,se.RGBA,{premultiply:!1})}return this._emptyDepthBufferTexture}_getLoadedAreaMinimum(){let w=0;const se=this._visibleDemTiles.reduce((it,xt)=>{if(!xt.dem)return it;const Dt=xt.dem.tree.minimums[0];return Dt>0&&w++,it+Dt},0);return w?se/w:0}_updateEmptyDEMTexture(){const w=this.painter.context,se=w.gl;w.activeTexture.set(se.TEXTURE2);const it=this._getLoadedAreaMinimum(),xt=new m.RGBAImage({width:1,height:1},new Uint8Array(m.DEMData.pack(it,this.sourceCache.getSource().encoding)));this._emptyDEMTextureDirty=!1;let Dt=this._emptyDEMTexture;return Dt?Dt.update(xt,{premultiply:!1}):Dt=this._emptyDEMTexture=new m.Texture(w,xt,se.RGBA,{premultiply:!1}),Dt}setupElevationDraw(w,se,it){const xt=this.painter.context,Dt=xt.gl,Ot=(rn=this.sourceCache.getSource().encoding,{u_dem:2,u_dem_prev:4,u_dem_unpack:m.DEMData.getUnpackVector(rn),u_dem_tl:[0,0],u_dem_tl_prev:[0,0],u_dem_scale:0,u_dem_scale_prev:0,u_dem_size:0,u_dem_lerp:1,u_depth:3,u_depth_size_inv:[0,0],u_exaggeration:0,u_tile_tl_up:[0,0,1],u_tile_tr_up:[0,0,1],u_tile_br_up:[0,0,1],u_tile_bl_up:[0,0,1],u_tile_up_scale:1});var rn;Ot.u_dem_size=this.sourceCache.getSource().tileSize,Ot.u_exaggeration=this.exaggeration();const Tn=this.painter.transform,kn=Tn.projection,Bn=w.tileID.canonical;Ot.u_tile_tl_up=kn.upVector(Bn,0,0),Ot.u_tile_tr_up=kn.upVector(Bn,m.EXTENT,0),Ot.u_tile_br_up=kn.upVector(Bn,m.EXTENT,m.EXTENT),Ot.u_tile_bl_up=kn.upVector(Bn,0,m.EXTENT),Ot.u_tile_up_scale=it&&it.useDenormalizedUpVectorScale?bl:kn.upVectorScale(Bn,Tn.center.lat,Tn.worldSize).metersToTile;let Wn=null,Fr=null,ri=1;if(it&&it.morphing&&this._useVertexMorphing){const Zr=it.morphing.srcDemTile,Sr=it.morphing.dstDemTile;ri=it.morphing.phase,Zr&&Sr&&(this._prepareDemTileUniforms(w,Zr,Ot,"_prev")&&(Fr=Zr),this._prepareDemTileUniforms(w,Sr,Ot)&&(Wn=Sr))}if(Fr&&Wn?(xt.activeTexture.set(Dt.TEXTURE2),Wn.demTexture.bind(Dt.NEAREST,Dt.CLAMP_TO_EDGE,Dt.NEAREST),xt.activeTexture.set(Dt.TEXTURE4),Fr.demTexture.bind(Dt.NEAREST,Dt.CLAMP_TO_EDGE,Dt.NEAREST),Ot.u_dem_lerp=ri):(Wn=this.terrainTileForTile[w.tileID.key],xt.activeTexture.set(Dt.TEXTURE2),(this._prepareDemTileUniforms(w,Wn,Ot)?Wn.demTexture:this.emptyDEMTexture).bind(Dt.NEAREST,Dt.CLAMP_TO_EDGE)),xt.activeTexture.set(Dt.TEXTURE3),it&&it.useDepthForOcclusion?(this._depthTexture&&this._depthTexture.bind(Dt.NEAREST,Dt.CLAMP_TO_EDGE),this._depthFBO&&(Ot.u_depth_size_inv=[1/this._depthFBO.width,1/this._depthFBO.height])):(this.emptyDepthBufferTexture.bind(Dt.NEAREST,Dt.CLAMP_TO_EDGE),Ot.u_depth_size_inv=[1,1]),it&&it.useMeterToDem&&Wn){const Zr=(1<<Wn.tileID.canonical.z)*m.mercatorZfromAltitude(1,this.painter.transform.center.lat)*this.sourceCache.getSource().tileSize;Ot.u_meter_to_dem=Zr}it&&it.labelPlaneMatrixInv&&(Ot.u_label_plane_matrix_inv=it.labelPlaneMatrixInv),se.setTerrainUniformValues(xt,Ot)}renderToBackBuffer(w){const se=this.painter,it=this.painter.context;w.length!==0&&(it.bindFramebuffer.set(null),it.viewport.set([0,0,se.width,se.height]),this.renderingToTexture=!1,function(xt,Dt,Ot,rn,Tn){if(xt.transform.projection.name==="globe")(function(kn,Bn,Wn,Fr,ri){const Zr=kn.context,Sr=Zr.gl;let Di,di;const wi=kn.options.showTerrainWireframe?2:0,Ti=(ja,To)=>{if(di===ja)return;const na=[Ri[ja],"PROJECTION_GLOBE_VIEW"];To&&na.push(Ri[wi]),Di=kn.useProgram("globeRaster",null,na),di=ja},Oi=kn.colorModeForRenderPass(),_i=new m.DepthMode(Sr.LEQUAL,m.DepthMode.ReadWrite,kn.depthRangeFor3D);xa.update(ri);const Fi=kn.transform,Ta=m.calculateGlobeMercatorMatrix(Fi),Fa=[m.mercatorXfromLng(Fi.center.lng),m.mercatorYfromLat(Fi.center.lat)],qa=kn.globeSharedBuffers;if((wi?[!1,!0]:[!1]).forEach(ja=>{di=-1;const To=ja?Sr.LINES:Sr.TRIANGLES;for(const na of Fr){const Eo=Wn.getTile(na),So=m.StencilMode.disabled,Qo=Bn.prevTerrainTileForTile[na.key],Za=Bn.terrainTileForTile[na.key];li(Qo,Za)&&xa.newMorphing(na.key,Qo,Za,ri,250),Zr.activeTexture.set(Sr.TEXTURE0),Eo.texture.bind(Sr.LINEAR,Sr.CLAMP_TO_EDGE);const rs=xa.getMorphValuesForProxy(na.key),is=rs?1:0,hs={useDenormalizedUpVectorScale:!0};rs&&m.extend$1(hs,{morphing:{srcDemTile:rs.from,dstDemTile:rs.to,phase:m.easeCubicInOut(rs.phase)}});const ps=Float32Array.from(Fi.globeMatrix),Js=m.globeTileLatLngCorners(na.canonical),fl=m.getGridMatrix(na.canonical,Js),as=Jn(Fi.projMatrix,ps,Ta,m.globeToMercatorTransition(Fi.zoom),Fa,fl);if(Ti(is,ja),Bn.setupElevationDraw(Eo,Di,hs),kn.prepareDrawProgram(Zr,Di,na.toUnwrapped()),qa){const[ll,Yl,dc]=ja?qa.getWirefameBuffers(kn.context):qa.getGridBuffers();Di.draw(Zr,To,_i,So,Oi,m.CullFaceMode.backCCW,as,"globe_raster",ll,Yl,dc)}}}),qa){Di=kn.useProgram("globeRaster",null,["GLOBE_POLES","PROJECTION_GLOBE_VIEW"]);for(const ja of Fr){const{x:To,y:na,z:Eo}=ja.canonical,So=na===0,Qo=na===(1<<Eo)-1,[Za,rs,is,hs]=qa.getPoleBuffers(Eo);if(hs&&(So||Qo)){const ps=Wn.getTile(ja);Zr.activeTexture.set(Sr.TEXTURE0),ps.texture.bind(Sr.LINEAR,Sr.CLAMP_TO_EDGE);let Js=m.globePoleMatrixForTile(Eo,To,Fi);const fl=(as,ll)=>as.draw(Zr,Sr.TRIANGLES,_i,m.StencilMode.disabled,Oi,m.CullFaceMode.disabled,Jn(Fi.projMatrix,Js,Js,0,Fa),"globe_pole_raster",ll,is,hs);Bn.setupElevationDraw(ps,Di,{}),kn.prepareDrawProgram(Zr,Di,ja.toUnwrapped()),So&&fl(Di,Za),Qo&&(Js=m.scale(m.create(),Js,[1,-1,1]),fl(Di,rs))}}}})(xt,Dt,Ot,rn,Tn);else{const kn=xt.context,Bn=kn.gl;let Wn,Fr;const ri=xt.options.showTerrainWireframe?2:0,Zr=(Ti,Oi)=>{if(Fr===Ti)return;const _i=[Ri[Ti]];Oi&&_i.push(Ri[ri]),Wn=xt.useProgram("terrainRaster",null,_i),Fr=Ti},Sr=xt.colorModeForRenderPass(),Di=new m.DepthMode(Bn.LEQUAL,m.DepthMode.ReadWrite,xt.depthRangeFor3D);xa.update(Tn);const di=xt.transform,wi=6*Math.pow(1.5,22-di.zoom)*Dt.exaggeration();(ri?[!1,!0]:[!1]).forEach(Ti=>{Fr=-1;const Oi=Ti?Bn.LINES:Bn.TRIANGLES,[_i,Fi]=Ti?Dt.getWirefameBuffer():[Dt.gridIndexBuffer,Dt.gridSegments];for(const Ta of rn){const Fa=Ot.getTile(Ta),qa=m.StencilMode.disabled,ja=Dt.prevTerrainTileForTile[Ta.key],To=Dt.terrainTileForTile[Ta.key];li(ja,To)&&xa.newMorphing(Ta.key,ja,To,Tn,250),kn.activeTexture.set(Bn.TEXTURE0),Fa.texture.bind(Bn.LINEAR,Bn.CLAMP_TO_EDGE,Bn.LINEAR_MIPMAP_NEAREST);const na=xa.getMorphValuesForProxy(Ta.key),Eo=na?1:0;let So;na&&(So={morphing:{srcDemTile:na.from,dstDemTile:na.to,phase:m.easeCubicInOut(na.phase)}});const Qo=vr(Ta.projMatrix,fa(Ta.canonical,di.renderWorldCopies)?wi/10:wi);Zr(Eo,Ti),Dt.setupElevationDraw(Fa,Wn,So),xt.prepareDrawProgram(kn,Wn,Ta.toUnwrapped()),Wn.draw(kn,Oi,Di,qa,Sr,m.CullFaceMode.backCCW,Qo,"terrain_raster",Dt.gridBuffer,_i,Fi)}})}}(se,this,this.proxySourceCache,w,this._updateTimestamp),this.renderingToTexture=!0,w.splice(0,w.length))}renderBatch(w){if(this._drapedRenderBatches.length===0)return w+1;this.renderingToTexture=!0;const se=this.painter,it=this.painter.context,xt=this.proxySourceCache,Dt=this.proxiedCoords[xt.id],Ot=this._drapedRenderBatches.shift(),rn=[],Tn=se.style.order;let kn=0;for(const Bn of Dt){const Wn=xt.getTileByID(Bn.proxyTileKey),Fr=xt.proxyCachedFBO[Bn.key]?xt.proxyCachedFBO[Bn.key][w]:void 0,ri=Fr!==void 0?xt.renderCache[Fr]:this.pool[kn++],Zr=Fr!==void 0;if(Wn.texture=ri.tex,Zr&&!ri.dirty){rn.push(Wn.tileID);continue}let Sr;it.bindFramebuffer.set(ri.fb.framebuffer),this.renderedToTile=!1,ri.dirty&&(it.clear({color:m.Color.transparent,stencil:0}),ri.dirty=!1);for(let Di=Ot.start;Di<=Ot.end;++Di){const di=se.style._layers[Tn[Di]];if(di.isHidden(se.transform.zoom))continue;const wi=se.style._getLayerSourceCache(di),Ti=wi?this.proxyToSource[Bn.key][wi.id]:[Bn];if(!Ti)continue;const Oi=Ti;it.viewport.set([0,0,ri.fb.width,ri.fb.height]),Sr!==(wi?wi.id:null)&&(this._setupStencil(ri,Ti,di,wi),Sr=wi?wi.id:null),se.renderLayer(se,wi,di,Oi)}this.renderedToTile?(ri.dirty=!0,rn.push(Wn.tileID)):Zr||--kn,kn===5&&(kn=0,this.renderToBackBuffer(rn))}return this.renderToBackBuffer(rn),this.renderingToTexture=!1,it.bindFramebuffer.set(null),it.viewport.set([0,0,se.width,se.height]),Ot.end+1}postRender(){}renderCacheEfficiency(w){const se=w.order.length;if(se===0)return{efficiency:100};let it,xt=0,Dt=0,Ot=!1;for(let rn=0;rn<se;++rn){const Tn=w._layers[w.order[rn]];this._style.isLayerDraped(Tn)?(Ot&&++xt,++Dt):Ot||(Ot=!0,it=Tn.id)}return Dt===0?{efficiency:100}:{efficiency:100*(1-xt/Dt),firstUndrapedLayer:it}}getMinElevationBelowMSL(){let w=0;return this._visibleDemTiles.filter(se=>se.dem).forEach(se=>{w=Math.min(w,se.dem.tree.minimums[0])}),w===0?w:(w-30)*this._exaggeration}raycast(w,se,it){if(!this._visibleDemTiles)return null;const xt=this._visibleDemTiles.filter(Dt=>Dt.dem).map(Dt=>{const Ot=Dt.tileID,rn=Math.pow(2,Ot.overscaledZ),{x:Tn,y:kn}=Ot.canonical,Bn=Tn/rn,Wn=(Tn+1)/rn,Fr=kn/rn,ri=(kn+1)/rn;return{minx:Bn,miny:Fr,maxx:Wn,maxy:ri,t:Dt.dem.tree.raycastRoot(Bn,Fr,Wn,ri,w,se,it),tile:Dt}});xt.sort((Dt,Ot)=>(Dt.t!==null?Dt.t:Number.MAX_VALUE)-(Ot.t!==null?Ot.t:Number.MAX_VALUE));for(const Dt of xt){if(Dt.t==null)return null;const Ot=Dt.tile.dem.tree.raycast(Dt.minx,Dt.miny,Dt.maxx,Dt.maxy,w,se,it);if(Ot!=null)return Ot}return null}_createFBO(){const w=this.painter.context,se=w.gl,it=this.drapeBufferSize;w.activeTexture.set(se.TEXTURE0);const xt=new m.Texture(w,{width:it[0],height:it[1],data:null},se.RGBA);xt.bind(se.LINEAR,se.CLAMP_TO_EDGE);const Dt=w.createFramebuffer(it[0],it[1],!1);return Dt.colorAttachment.set(xt.texture),Dt.depthAttachment=new il(w,Dt.framebuffer),this._sharedDepthStencil===void 0?(this._sharedDepthStencil=w.createRenderbuffer(w.gl.DEPTH_STENCIL,it[0],it[1]),this._stencilRef=0,Dt.depthAttachment.set(this._sharedDepthStencil),w.clear({stencil:0})):Dt.depthAttachment.set(this._sharedDepthStencil),w.extTextureFilterAnisotropic&&!w.extTextureFilterAnisotropicForceOff&&se.texParameterf(se.TEXTURE_2D,w.extTextureFilterAnisotropic.TEXTURE_MAX_ANISOTROPY_EXT,w.extTextureFilterAnisotropicMax),{fb:Dt,tex:xt,dirty:!1}}_initFBOPool(){for(;this.pool.length<Math.min(5,this.proxyCoords.length);)this.pool.push(this._createFBO())}_shouldDisableRenderCache(){if(this._style.light&&this._style.light.hasTransition())return!0;for(const w in this._style._sourceCaches)if(this._style._sourceCaches[w].hasTransition())return!0;return this._style.order.some(w=>{const se=this._style._layers[w],it=se.isHidden(this.painter.transform.zoom),xt=se.getCrossfadeParameters(),Dt=!!xt&&xt.t!==1,Ot=se.hasTransition();return se.type!=="custom"&&!it&&(Dt||Ot)})}_clearRasterFadeFromRenderCache(){let w=!1;for(const se in this._style._sourceCaches)if(this._style._sourceCaches[se]._source instanceof Un){w=!0;break}if(w)for(let se=0;se<this._style.order.length;++se){const it=this._style._layers[this._style.order[se]],xt=it.isHidden(this.painter.transform.zoom),Dt=this._style._getLayerSourceCache(it);if(it.type!=="raster"||xt||!Dt)continue;const Ot=it.paint.get("raster-fade-duration");for(const rn of this.proxyCoords){const Tn=this.proxyToSource[rn.key][Dt.id];if(Tn)for(const kn of Tn){const Bn=ts(Dt.getTile(kn),Dt.findLoadedParent(kn,0),Dt,this.painter.transform,Ot);(Bn.opacity!==1||Bn.mix!==0)&&this._clearRenderCacheForTile(Dt.id,kn)}}}}_setupDrapedRenderBatches(){const w=this._style.order,se=w.length;if(se===0)return;const it=[];let xt,Dt=0,Ot=this._style._layers[w[Dt]];for(;!this._style.isLayerDraped(Ot)&&Ot.isHidden(this.painter.transform.zoom)&&++Dt<se;)Ot=this._style._layers[w[Dt]];for(;Dt<se;++Dt){const rn=this._style._layers[w[Dt]];rn.isHidden(this.painter.transform.zoom)||(this._style.isLayerDraped(rn)?xt===void 0&&(xt=Dt):xt!==void 0&&(it.push({start:xt,end:Dt-1}),xt=void 0))}xt!==void 0&&it.push({start:xt,end:Dt-1}),this._drapedRenderBatches=it}_setupRenderCache(w){const se=this.proxySourceCache;if(this._shouldDisableRenderCache()||this._invalidateRenderCache){if(this._invalidateRenderCache=!1,se.renderCache.length>se.renderCachePool.length){const Ot=Object.values(se.proxyCachedFBO);se.proxyCachedFBO={};for(let rn=0;rn<Ot.length;++rn){const Tn=Object.values(Ot[rn]);se.renderCachePool.push(...Tn)}}return}this._clearRasterFadeFromRenderCache();const it=this.proxyCoords,xt=this._tilesDirty;for(let Ot=it.length-1;Ot>=0;Ot--){const rn=it[Ot];if(se.getTileByID(rn.key),se.proxyCachedFBO[rn.key]!==void 0){const Tn=w[rn.key],kn=this.proxyToSource[rn.key];let Bn=0;for(const Wn in kn){const Fr=kn[Wn],ri=Tn[Wn];if(!ri||ri.length!==Fr.length||Fr.some((Zr,Sr)=>Zr!==ri[Sr]||xt[Wn]&&xt[Wn].hasOwnProperty(Zr.key))){Bn=-1;break}++Bn}for(const Wn in se.proxyCachedFBO[rn.key])se.renderCache[se.proxyCachedFBO[rn.key][Wn]].dirty=Bn<0||Bn!==Object.values(Tn).length}}const Dt=[...this._drapedRenderBatches];Dt.sort((Ot,rn)=>rn.end-rn.start-(Ot.end-Ot.start));for(const Ot of Dt)for(const rn of it){if(se.proxyCachedFBO[rn.key])continue;let Tn=se.renderCachePool.pop();Tn===void 0&&se.renderCache.length<50&&(Tn=se.renderCache.length,se.renderCache.push(this._createFBO())),Tn!==void 0&&(se.proxyCachedFBO[rn.key]={},se.proxyCachedFBO[rn.key][Ot.start]=Tn,se.renderCache[Tn].dirty=!0)}this._tilesDirty={}}_setupStencil(w,se,it,xt){if(!xt||!this._sourceTilesOverlap[xt.id])return void(this._overlapStencilType&&(this._overlapStencilType=!1));const Dt=this.painter.context,Ot=Dt.gl;if(se.length<=1)return void(this._overlapStencilType=!1);let rn;if(it.isTileClipped())rn=se.length,this._overlapStencilMode.test={func:Ot.EQUAL,mask:255},this._overlapStencilType="Clip";else{if(!(se[0].overscaledZ>se[se.length-1].overscaledZ))return void(this._overlapStencilType=!1);rn=1,this._overlapStencilMode.test={func:Ot.GREATER,mask:255},this._overlapStencilType="Mask"}this._stencilRef+rn>255&&(Dt.clear({stencil:0}),this._stencilRef=0),this._stencilRef+=rn,this._overlapStencilMode.ref=this._stencilRef,it.isTileClipped()&&this._renderTileClippingMasks(se,this._overlapStencilMode.ref)}clipOrMaskOverlapStencilType(){return this._overlapStencilType==="Clip"||this._overlapStencilType==="Mask"}stencilModeForRTTOverlap(w){return this.renderingToTexture&&this._overlapStencilType?(this._overlapStencilType==="Clip"&&(this._overlapStencilMode.ref=this.painter._tileClippingMaskIDs.get(w.key)||0),this._overlapStencilMode):m.StencilMode.disabled}_renderTileClippingMasks(w,se){const it=this.painter,xt=this.painter.context,Dt=xt.gl;it._tileClippingMaskIDs.clear(),xt.setColorMode(m.ColorMode.disabled),xt.setDepthMode(m.DepthMode.disabled);const Ot=it.useProgram("clippingMask");for(const rn of w){const Tn=--se;it._tileClippingMaskIDs.set(rn.key,Tn),Ot.draw(xt,Dt.TRIANGLES,m.DepthMode.disabled,new m.StencilMode({func:Dt.ALWAYS,mask:0},Tn,255,Dt.KEEP,Dt.KEEP,Dt.REPLACE),m.ColorMode.disabled,m.CullFaceMode.disabled,oo(rn.projMatrix),"$clipping",it.tileExtentBuffer,it.quadTriangleIndexBuffer,it.tileExtentSegments)}}pointCoordinate(w){const se=this.painter.transform;if(w.x<0||w.x>se.width||w.y<0||w.y>se.height)return null;const it=[w.x,w.y,1,1];m.transformMat4$1(it,it,se.pixelMatrixInverse),m.scale$1(it,it,1/it[3]),it[0]/=se.worldSize,it[1]/=se.worldSize;const xt=se._camera.position,Dt=m.mercatorZfromAltitude(1,se.center.lat),Ot=[xt[0],xt[1],xt[2]/Dt,0],rn=m.subtract([],it.slice(0,3),Ot);m.normalize(rn,rn);const Tn=this.raycast(Ot,rn,this._exaggeration);return Tn!==null&&Tn?(m.scaleAndAdd(Ot,Ot,rn,Tn),Ot[3]=Ot[2],Ot[2]*=Dt,Ot):null}drawDepth(){const w=this.painter,se=w.context,it=this.proxySourceCache,xt=Math.ceil(w.width),Dt=Math.ceil(w.height);if(!this._depthFBO||this._depthFBO.width===xt&&this._depthFBO.height===Dt||(this._depthFBO.destroy(),this._depthFBO=void 0,this._depthTexture=void 0),!this._depthFBO){const Ot=se.gl,rn=se.createFramebuffer(xt,Dt,!0);se.activeTexture.set(Ot.TEXTURE0);const Tn=new m.Texture(se,{width:xt,height:Dt,data:null},Ot.RGBA);Tn.bind(Ot.NEAREST,Ot.CLAMP_TO_EDGE),rn.colorAttachment.set(Tn.texture);const kn=se.createRenderbuffer(se.gl.DEPTH_COMPONENT16,xt,Dt);rn.depthAttachment.set(kn),this._depthFBO=rn,this._depthTexture=Tn}se.bindFramebuffer.set(this._depthFBO.framebuffer),se.viewport.set([0,0,xt,Dt]),function(Ot,rn,Tn,kn){if(Ot.transform.projection.name==="globe")return;const Bn=Ot.context,Wn=Bn.gl;Bn.clear({depth:1});const Fr=Ot.useProgram("terrainDepth"),ri=new m.DepthMode(Wn.LESS,m.DepthMode.ReadWrite,Ot.depthRangeFor3D);for(const Zr of kn){const Sr=Tn.getTile(Zr),Di=vr(Zr.projMatrix,0);rn.setupElevationDraw(Sr,Fr),Fr.draw(Bn,Wn.TRIANGLES,ri,m.StencilMode.disabled,m.ColorMode.unblended,m.CullFaceMode.backCCW,Di,"terrain_depth",rn.gridBuffer,rn.gridIndexBuffer,rn.gridNoSkirtSegments)}}(w,this,it,this.proxyCoords)}_setupProxiedCoordsForOrtho(w,se,it){if(w.getSource()instanceof Ei)return this._setupProxiedCoordsForImageSource(w,se,it);this._findCoveringTileCache[w.id]=this._findCoveringTileCache[w.id]||{};const xt=this.proxiedCoords[w.id]=[],Dt=this.proxyCoords;for(let rn=0;rn<Dt.length;rn++){const Tn=Dt[rn],kn=this._findTileCoveringTileID(Tn,w);if(kn){const Bn=this._createProxiedId(Tn,kn,it[Tn.key]&&it[Tn.key][w.id]);xt.push(Bn),this.proxyToSource[Tn.key][w.id]=[Bn]}}let Ot=!1;for(let rn=0;rn<se.length;rn++){const Tn=w.getTile(se[rn]);if(!Tn||!Tn.hasData())continue;const kn=this._findTileCoveringTileID(Tn.tileID,this.proxySourceCache);if(kn&&kn.tileID.canonical.z!==Tn.tileID.canonical.z){const Bn=this.proxyToSource[kn.tileID.key][w.id],Wn=this._createProxiedId(kn.tileID,Tn,it[kn.tileID.key]&&it[kn.tileID.key][w.id]);Bn?Bn.splice(Bn.length-1,0,Wn):this.proxyToSource[kn.tileID.key][w.id]=[Wn],xt.push(Wn),Ot=!0}}this._sourceTilesOverlap[w.id]=Ot}_setupProxiedCoordsForImageSource(w,se,it){if(!w.getSource().loaded())return;const xt=this.proxiedCoords[w.id]=[],Dt=this.proxyCoords,Ot=w.getSource(),rn=new m.pointGeometry(Ot.tileID.x,Ot.tileID.y)._div(1<<Ot.tileID.z),Tn=Ot.coordinates.map(m.MercatorCoordinate.fromLngLat).reduce((Bn,Wn)=>(Bn.min.x=Math.min(Bn.min.x,Wn.x-rn.x),Bn.min.y=Math.min(Bn.min.y,Wn.y-rn.y),Bn.max.x=Math.max(Bn.max.x,Wn.x-rn.x),Bn.max.y=Math.max(Bn.max.y,Wn.y-rn.y),Bn),{min:new m.pointGeometry(Number.MAX_VALUE,Number.MAX_VALUE),max:new m.pointGeometry(-Number.MAX_VALUE,-Number.MAX_VALUE)}),kn=(Bn,Wn)=>{const Fr=Bn.wrap+Bn.canonical.x/(1<<Bn.canonical.z),ri=Bn.canonical.y/(1<<Bn.canonical.z),Zr=m.EXTENT/(1<<Bn.canonical.z),Sr=Wn.wrap+Wn.canonical.x/(1<<Wn.canonical.z),Di=Wn.canonical.y/(1<<Wn.canonical.z);return Fr+Zr<Sr+Tn.min.x||Fr>Sr+Tn.max.x||ri+Zr<Di+Tn.min.y||ri>Di+Tn.max.y};for(let Bn=0;Bn<Dt.length;Bn++){const Wn=Dt[Bn];for(let Fr=0;Fr<se.length;Fr++){const ri=w.getTile(se[Fr]);if(!ri||!ri.hasData()||kn(Wn,ri.tileID))continue;const Zr=this._createProxiedId(Wn,ri,it[Wn.key]&&it[Wn.key][w.id]),Sr=this.proxyToSource[Wn.key][w.id];Sr?Sr.push(Zr):this.proxyToSource[Wn.key][w.id]=[Zr],xt.push(Zr)}}}_createProxiedId(w,se,it){let xt=this.orthoMatrix;if(it){const Dt=it.find(Ot=>Ot.key===se.tileID.key);if(Dt)return Dt}if(se.tileID.key!==w.key){const Dt=w.canonical.z-se.tileID.canonical.z;let Ot,rn,Tn;xt=m.create();const kn=se.tileID.wrap-w.wrap<<w.overscaledZ;Dt>0?(Ot=m.EXTENT>>Dt,rn=Ot*((se.tileID.canonical.x<<Dt)-w.canonical.x+kn),Tn=Ot*((se.tileID.canonical.y<<Dt)-w.canonical.y)):(Ot=m.EXTENT<<-Dt,rn=m.EXTENT*(se.tileID.canonical.x-(w.canonical.x+kn<<-Dt)),Tn=m.EXTENT*(se.tileID.canonical.y-(w.canonical.y<<-Dt))),m.ortho(xt,0,Ot,0,Ot,0,1),m.translate(xt,xt,[rn,Tn,0])}return new eu(se.tileID,w.key,xt)}_findTileCoveringTileID(w,se){let it=se.getTile(w);if(it&&it.hasData())return it;const xt=this._findCoveringTileCache[se.id],Dt=xt[w.key];if(it=Dt?se.getTileByID(Dt):null,it&&it.hasData()||Dt===null)return it;let Ot=it?it.tileID:w,rn=Ot.overscaledZ;const Tn=se.getSource().minzoom,kn=[];if(!Dt){const Wn=se.getSource().maxzoom;if(w.canonical.z>=Wn){const Fr=w.canonical.z-Wn;se.getSource().reparseOverscaled?(rn=Math.max(w.canonical.z+2,se.transform.tileZoom),Ot=new m.OverscaledTileID(rn,w.wrap,Wn,w.canonical.x>>Fr,w.canonical.y>>Fr)):Fr!==0&&(rn=Wn,Ot=new m.OverscaledTileID(rn,w.wrap,Wn,w.canonical.x>>Fr,w.canonical.y>>Fr))}Ot.key!==w.key&&(kn.push(Ot.key),it=se.getTile(Ot))}const Bn=Wn=>{kn.forEach(Fr=>{xt[Fr]=Wn}),kn.length=0};for(rn-=1;rn>=Tn&&(!it||!it.hasData());rn--){it&&Bn(it.tileID.key);const Wn=Ot.calculateScaledKey(rn);if(it=se.getTileByID(Wn),it&&it.hasData())break;const Fr=xt[Wn];if(Fr===null)break;Fr===void 0?kn.push(Wn):it=se.getTileByID(Fr)}return Bn(it?it.tileID.key:null),it&&it.hasData()?it:null}findDEMTileFor(w){return this.enabled?this._findTileCoveringTileID(w,this.sourceCache):null}prepareDrawTile(){this.renderedToTile=!0}_clearRenderCacheForTile(w,se){let it=this._tilesDirty[w];it||(it=this._tilesDirty[w]={}),it[se.key]=!0}getWirefameBuffer(){if(!this.wireframeSegments){const w=function(se){let it=0;const xt=new m.StructArrayLayout2ui4,Dt=131;for(let Ot=1;Ot<129;Ot++){for(let rn=1;rn<129;rn++)it=Ot*Dt+rn,xt.emplaceBack(it,it+1),xt.emplaceBack(it,it+Dt),xt.emplaceBack(it+1,it+Dt),Ot===128&&xt.emplaceBack(it+Dt,it+Dt+1);xt.emplaceBack(it+1,it+1+Dt)}return xt}();this.wireframeIndexBuffer=this.painter.context.createIndexBuffer(w),this.wireframeSegments=m.SegmentVector.simpleSegment(0,0,this.gridBuffer.length,w.length)}return[this.wireframeIndexBuffer,this.wireframeSegments]}}function As(Ee){const w=[];for(let se=0;se<Ee.length;se++){if(Ee[se]===null)continue;const it=Ee[se].split(" ");w.push(it.pop())}return w}class yl{static cacheKey(w,se,it){let xt=`${w}${it?it.cacheKey:""}`;for(const Dt of se)xt+=`/${Dt}`;return xt}constructor(w,se,it,xt,Dt,Ot){const rn=w.gl;this.program=rn.createProgram();const Tn=As(it.staticAttributes),kn=xt?xt.getBinderAttributes():[],Bn=Tn.concat(kn),Wn=it.staticUniforms?As(it.staticUniforms):[],Fr=xt?xt.getBinderUniforms():[],ri=Wn.concat(Fr),Zr=[];for(const _i of ri)Zr.indexOf(_i)<0&&Zr.push(_i);let Sr=xt?xt.defines():[];Sr=Sr.concat(Ot.map(_i=>`#define ${_i}`));const Di=Sr.concat(`
- #ifdef GL_ES
- precision mediump float;
- #else
- #if !defined(lowp)
- #define lowp
- #endif
- #if !defined(mediump)
- #define mediump
- #endif
- #if !defined(highp)
- #define highp
- #endif
- #endif`,Cn,qt.fragmentSource,wt.fragmentSource,it.fragmentSource).join(`
- `),di=Sr.concat(`
- #ifdef GL_ES
- precision highp float;
- #else
- #if !defined(lowp)
- #define lowp
- #endif
- #if !defined(mediump)
- #define mediump
- #endif
- #if !defined(highp)
- #define highp
- #endif
- #endif`,Cn,qt.vertexSource,wt.vertexSource,Tu.vertexSource,it.vertexSource).join(`
- `),wi=rn.createShader(rn.FRAGMENT_SHADER);if(rn.isContextLost())return void(this.failedToCreate=!0);rn.shaderSource(wi,Di),rn.compileShader(wi),rn.attachShader(this.program,wi);const Ti=rn.createShader(rn.VERTEX_SHADER);if(rn.isContextLost())return void(this.failedToCreate=!0);rn.shaderSource(Ti,di),rn.compileShader(Ti),rn.attachShader(this.program,Ti),this.attributes={};const Oi={};this.numAttributes=Bn.length;for(let _i=0;_i<this.numAttributes;_i++)Bn[_i]&&(rn.bindAttribLocation(this.program,_i,Bn[_i]),this.attributes[Bn[_i]]=_i);rn.linkProgram(this.program),rn.deleteShader(Ti),rn.deleteShader(wi);for(let _i=0;_i<Zr.length;_i++){const Fi=Zr[_i];if(Fi&&!Oi[Fi]){const Ta=rn.getUniformLocation(this.program,Fi);Ta&&(Oi[Fi]=Ta)}}this.fixedUniforms=Dt(w,Oi),this.binderUniforms=xt?xt.getUniforms(w,Oi):[],Ot.indexOf("TERRAIN")!==-1&&(this.terrainUniforms=((_i,Fi)=>({u_dem:new m.Uniform1i(_i,Fi.u_dem),u_dem_prev:new m.Uniform1i(_i,Fi.u_dem_prev),u_dem_unpack:new m.Uniform4f(_i,Fi.u_dem_unpack),u_dem_tl:new m.Uniform2f(_i,Fi.u_dem_tl),u_dem_scale:new m.Uniform1f(_i,Fi.u_dem_scale),u_dem_tl_prev:new m.Uniform2f(_i,Fi.u_dem_tl_prev),u_dem_scale_prev:new m.Uniform1f(_i,Fi.u_dem_scale_prev),u_dem_size:new m.Uniform1f(_i,Fi.u_dem_size),u_dem_lerp:new m.Uniform1f(_i,Fi.u_dem_lerp),u_exaggeration:new m.Uniform1f(_i,Fi.u_exaggeration),u_depth:new m.Uniform1i(_i,Fi.u_depth),u_depth_size_inv:new m.Uniform2f(_i,Fi.u_depth_size_inv),u_meter_to_dem:new m.Uniform1f(_i,Fi.u_meter_to_dem),u_label_plane_matrix_inv:new m.UniformMatrix4f(_i,Fi.u_label_plane_matrix_inv),u_tile_tl_up:new m.Uniform3f(_i,Fi.u_tile_tl_up),u_tile_tr_up:new m.Uniform3f(_i,Fi.u_tile_tr_up),u_tile_br_up:new m.Uniform3f(_i,Fi.u_tile_br_up),u_tile_bl_up:new m.Uniform3f(_i,Fi.u_tile_bl_up),u_tile_up_scale:new m.Uniform1f(_i,Fi.u_tile_up_scale)}))(w,Oi)),Ot.indexOf("FOG")!==-1&&(this.fogUniforms=((_i,Fi)=>({u_fog_matrix:new m.UniformMatrix4f(_i,Fi.u_fog_matrix),u_fog_range:new m.Uniform2f(_i,Fi.u_fog_range),u_fog_color:new m.Uniform4f(_i,Fi.u_fog_color),u_fog_horizon_blend:new m.Uniform1f(_i,Fi.u_fog_horizon_blend),u_fog_temporal_offset:new m.Uniform1f(_i,Fi.u_fog_temporal_offset)}))(w,Oi))}setTerrainUniformValues(w,se){if(!this.terrainUniforms)return;const it=this.terrainUniforms;if(!this.failedToCreate){w.program.set(this.program);for(const xt in se)it[xt].set(se[xt])}}setFogUniformValues(w,se){if(!this.fogUniforms)return;const it=this.fogUniforms;if(!this.failedToCreate){w.program.set(this.program);for(const xt in se)it[xt].location&&it[xt].set(se[xt])}}draw(w,se,it,xt,Dt,Ot,rn,Tn,kn,Bn,Wn,Fr,ri,Zr,Sr,Di){const di=w.gl;if(this.failedToCreate)return;w.program.set(this.program),w.setDepthMode(it),w.setStencilMode(xt),w.setColorMode(Dt),w.setCullFace(Ot);for(const Ti of Object.keys(this.fixedUniforms))this.fixedUniforms[Ti].set(rn[Ti]);Zr&&Zr.setUniforms(w,this.binderUniforms,Fr,{zoom:ri});const wi={[di.LINES]:2,[di.TRIANGLES]:3,[di.LINE_STRIP]:1}[se];for(const Ti of Wn.get()){const Oi=Ti.vaos||(Ti.vaos={});(Oi[Tn]||(Oi[Tn]=new yt)).bind(w,this,kn,Zr?Zr.getPaintVertexBuffers():[],Bn,Ti.vertexOffset,Sr,Di),di.drawElements(se,Ti.primitiveLength*wi,di.UNSIGNED_SHORT,Ti.primitiveOffset*wi*2)}}}function Lc(Ee,w,se){const it=1/hn(se,1,w.transform.tileZoom),xt=Math.pow(2,se.tileID.overscaledZ),Dt=se.tileSize*Math.pow(2,w.transform.tileZoom)/xt,Ot=Dt*(se.tileID.canonical.x+se.tileID.wrap*xt),rn=Dt*se.tileID.canonical.y;return{u_image:0,u_texsize:se.imageAtlasTexture.size,u_scale:[it,Ee.fromScale,Ee.toScale],u_fade:Ee.t,u_pixel_coord_upper:[Ot>>16,rn>>16],u_pixel_coord_lower:[65535&Ot,65535&rn]}}const vl=m.create(),du=(Ee,w,se,it,xt,Dt,Ot,rn,Tn)=>{const kn=w.style.light,Bn=kn.properties.get("position"),Wn=[Bn.x,Bn.y,Bn.z],Fr=m.create$1();kn.properties.get("anchor")==="viewport"&&(m.fromRotation(Fr,-w.transform.angle),m.transformMat3(Wn,Wn,Fr));const ri=kn.properties.get("color"),Zr=w.transform,Sr={u_matrix:Ee,u_lightpos:Wn,u_lightintensity:kn.properties.get("intensity"),u_lightcolor:[ri.r,ri.g,ri.b],u_vertical_gradient:+se,u_opacity:it,u_tile_id:[0,0,0],u_zoom_transition:0,u_inv_rot_matrix:vl,u_merc_center:[0,0],u_up_dir:[0,0,0],u_height_lift:0};return Zr.projection.name==="globe"&&(Sr.u_tile_id=[xt.canonical.x,xt.canonical.y,1<<xt.canonical.z],Sr.u_zoom_transition=Ot,Sr.u_inv_rot_matrix=Tn,Sr.u_merc_center=rn,Sr.u_up_dir=Zr.projection.upVector(new m.CanonicalTileID(0,0,0),rn[0]*m.EXTENT,rn[1]*m.EXTENT),Sr.u_height_lift=Dt),Sr},ac=(Ee,w,se,it,xt,Dt,Ot,rn,Tn,kn,Bn)=>{const Wn=du(Ee,w,se,it,xt,rn,Tn,kn,Bn),Fr={u_height_factor:-Math.pow(2,xt.overscaledZ)/Ot.tileSize/8};return m.extend(Wn,Lc(Dt,w,Ot),Fr)},Xu=Ee=>({u_matrix:Ee}),Ju=(Ee,w,se,it)=>m.extend(Xu(Ee),Lc(se,w,it)),Vu=(Ee,w)=>({u_matrix:Ee,u_world:w}),Nl=(Ee,w,se,it,xt)=>m.extend(Ju(Ee,w,se,it),{u_world:xt}),$l=m.create(),hu=(Ee,w,se,it,xt,Dt)=>{const Ot=Ee.transform,rn=Ot.projection.name==="globe";let Tn;if(Dt.paint.get("circle-pitch-alignment")==="map")if(rn){const Bn=m.globePixelsToTileUnits(Ot.zoom,w.canonical);Tn=Float32Array.from([Bn,0,0,Bn])}else Tn=Ot.calculatePixelsToTileUnitsMatrix(se);else Tn=new Float32Array([Ot.pixelsToGLUnits[0],0,0,Ot.pixelsToGLUnits[1]]);const kn={u_camera_to_center_distance:Ot.cameraToCenterDistance,u_matrix:Ee.translatePosMatrix(w.projMatrix,se,Dt.paint.get("circle-translate"),Dt.paint.get("circle-translate-anchor")),u_device_pixel_ratio:m.exported.devicePixelRatio,u_extrude_scale:Tn,u_inv_rot_matrix:$l,u_merc_center:[0,0],u_tile_id:[0,0,0],u_zoom_transition:0,u_up_dir:[0,0,0]};return rn&&(kn.u_inv_rot_matrix=it,kn.u_merc_center=xt,kn.u_tile_id=[w.canonical.x,w.canonical.y,1<<w.canonical.z],kn.u_zoom_transition=m.globeToMercatorTransition(Ot.zoom),kn.u_up_dir=Ot.projection.upVector(w.canonical,xt[0],xt[1])),kn},Qu=Ee=>{const w=[];return Ee.paint.get("circle-pitch-alignment")==="map"&&w.push("PITCH_WITH_MAP"),Ee.paint.get("circle-pitch-scale")==="map"&&w.push("SCALE_WITH_MAP"),w},Gu=(Ee,w,se)=>{const it=m.EXTENT/se.tileSize;return{u_matrix:Ee,u_camera_to_center_distance:w.cameraToCenterDistance,u_extrude_scale:[w.pixelsToGLUnits[0]/it,w.pixelsToGLUnits[1]/it]}},Bs=(Ee,w,se=1)=>({u_matrix:Ee,u_color:w,u_overlay:0,u_overlay_scale:se}),su=m.create(),ku=(Ee,w,se,it,xt,Dt,Ot)=>{const rn=Ee.transform,Tn=rn.projection.name==="globe",kn=Tn?m.globePixelsToTileUnits(rn.zoom,w.canonical):hn(se,1,Dt),Bn={u_matrix:w.projMatrix,u_extrude_scale:kn,u_intensity:Ot,u_inv_rot_matrix:su,u_merc_center:[0,0],u_tile_id:[0,0,0],u_zoom_transition:0,u_up_dir:[0,0,0]};return Tn&&(Bn.u_inv_rot_matrix=it,Bn.u_merc_center=xt,Bn.u_tile_id=[w.canonical.x,w.canonical.y,1<<w.canonical.z],Bn.u_zoom_transition=m.globeToMercatorTransition(rn.zoom),Bn.u_up_dir=rn.projection.upVector(w.canonical,xt[0],xt[1])),Bn},Hl=(Ee,w,se,it,xt,Dt,Ot)=>{const rn=Ee.transform,Tn=rn.calculatePixelsToTileUnitsMatrix(w),kn={u_matrix:cd(Ee,w,se,xt),u_pixels_to_tile_units:Tn,u_device_pixel_ratio:Ot,u_units_to_pixels:[1/rn.pixelsToGLUnits[0],1/rn.pixelsToGLUnits[1]],u_dash_image:0,u_gradient_image:1,u_image_height:Dt,u_texsize:[0,0],u_scale:[0,0,0],u_mix:0,u_alpha_discard_threshold:0};if(wu(se)){const Bn=Wl(w,Ee.transform);kn.u_texsize=w.lineAtlasTexture.size,kn.u_scale=[Bn,it.fromScale,it.toScale],kn.u_mix=it.t}return kn},Uc=(Ee,w,se,it,xt,Dt)=>{const Ot=Ee.transform,rn=Wl(w,Ot);return{u_matrix:cd(Ee,w,se,xt),u_texsize:w.imageAtlasTexture.size,u_pixels_to_tile_units:Ot.calculatePixelsToTileUnitsMatrix(w),u_device_pixel_ratio:Dt,u_image:0,u_scale:[rn,it.fromScale,it.toScale],u_fade:it.t,u_units_to_pixels:[1/Ot.pixelsToGLUnits[0],1/Ot.pixelsToGLUnits[1]],u_alpha_discard_threshold:0}};function Wl(Ee,w){return 1/hn(Ee,1,w.tileZoom)}function cd(Ee,w,se,it){return Ee.translatePosMatrix(it||w.tileID.projMatrix,w,se.paint.get("line-translate"),se.paint.get("line-translate-anchor"))}function wu(Ee){const w=Ee.paint.get("line-dasharray").value;return w.value||w.kind!=="constant"}const oc=(Ee,w,se,it,xt,Dt)=>{return{u_matrix:Ee,u_tl_parent:w,u_scale_parent:se,u_fade_t:it.mix,u_opacity:it.opacity*xt.paint.get("raster-opacity"),u_image0:0,u_image1:1,u_brightness_low:xt.paint.get("raster-brightness-min"),u_brightness_high:xt.paint.get("raster-brightness-max"),u_saturation_factor:(rn=xt.paint.get("raster-saturation"),rn>0?1-1/(1.001-rn):-rn),u_contrast_factor:(Ot=xt.paint.get("raster-contrast"),Ot>0?1/(1-Ot):1+Ot),u_spin_weights:gc(xt.paint.get("raster-hue-rotate")),u_perspective_transform:Dt};var Ot,rn};function gc(Ee){Ee*=Math.PI/180;const w=Math.sin(Ee),se=Math.cos(Ee);return[(2*se+1)/3,(-Math.sqrt(3)*w-se+1)/3,(Math.sqrt(3)*w-se+1)/3]}const dd=m.create(),Jc=(Ee,w,se,it,xt,Dt,Ot,rn,Tn,kn,Bn,Wn,Fr,ri)=>{const Zr=xt.transform,Sr={u_is_size_zoom_constant:+(Ee==="constant"||Ee==="source"),u_is_size_feature_constant:+(Ee==="constant"||Ee==="camera"),u_size_t:w?w.uSizeT:0,u_size:w?w.uSize:0,u_camera_to_center_distance:Zr.cameraToCenterDistance,u_rotate_symbol:+se,u_aspect_ratio:Zr.width/Zr.height,u_fade_change:xt.options.fadeDuration?xt.symbolFadeChange:1,u_matrix:Dt,u_label_plane_matrix:Ot,u_coord_matrix:rn,u_is_text:+Tn,u_pitch_with_map:+it,u_texsize:kn,u_texture:0,u_tile_id:[0,0,0],u_zoom_transition:0,u_inv_rot_matrix:dd,u_merc_center:[0,0],u_camera_forward:[0,0,0],u_ecef_origin:[0,0,0],u_tile_matrix:dd};return Zr.projection.name==="globe"&&(Sr.u_tile_id=[Bn.canonical.x,Bn.canonical.y,1<<Bn.canonical.z],Sr.u_zoom_transition=Wn,Sr.u_inv_rot_matrix=ri,Sr.u_merc_center=Fr,Sr.u_camera_forward=Zr._camera.forward(),Sr.u_ecef_origin=m.globeECEFOrigin(Zr.globeMatrix,Bn.toUnwrapped()),Sr.u_tile_matrix=Float32Array.from(Zr.globeMatrix)),Sr},sc=(Ee,w,se,it,xt,Dt,Ot,rn,Tn,kn,Bn,Wn,Fr,ri,Zr)=>{const{cameraToCenterDistance:Sr,_pitch:Di}=xt.transform;return m.extend(Jc(Ee,w,se,it,xt,Dt,Ot,rn,Tn,kn,Wn,Fr,ri,Zr),{u_gamma_scale:it?Sr*Math.cos(xt.terrain?0:Di):1,u_device_pixel_ratio:m.exported.devicePixelRatio,u_is_halo:+Bn})},qc=(Ee,w,se,it,xt,Dt,Ot,rn,Tn,kn,Bn,Wn,Fr,ri)=>m.extend(sc(Ee,w,se,it,xt,Dt,Ot,rn,!0,Tn,!0,Bn,Wn,Fr,ri),{u_texsize_icon:kn,u_texture_icon:1}),vd=(Ee,w,se)=>({u_matrix:Ee,u_opacity:w,u_color:se}),Pu=(Ee,w,se,it,xt,Dt)=>m.extend(function(Ot,rn,Tn,kn){const Bn=Tn.imageManager.getPattern(Ot.from.toString()),Wn=Tn.imageManager.getPattern(Ot.to.toString()),{width:Fr,height:ri}=Tn.imageManager.getPixelSize(),Zr=Math.pow(2,kn.tileID.overscaledZ),Sr=kn.tileSize*Math.pow(2,Tn.transform.tileZoom)/Zr,Di=Sr*(kn.tileID.canonical.x+kn.tileID.wrap*Zr),di=Sr*kn.tileID.canonical.y;return{u_image:0,u_pattern_tl_a:Bn.tl,u_pattern_br_a:Bn.br,u_pattern_tl_b:Wn.tl,u_pattern_br_b:Wn.br,u_texsize:[Fr,ri],u_mix:rn.t,u_pattern_size_a:Bn.displaySize,u_pattern_size_b:Wn.displaySize,u_scale_a:rn.fromScale,u_scale_b:rn.toScale,u_tile_units_to_pixels:1/hn(kn,1,Tn.transform.tileZoom),u_pixel_coord_upper:[Di>>16,di>>16],u_pixel_coord_lower:[65535&Di,65535&di]}}(it,Dt,se,xt),{u_matrix:Ee,u_opacity:w}),ol={fillExtrusion:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_lightpos:new m.Uniform3f(Ee,w.u_lightpos),u_lightintensity:new m.Uniform1f(Ee,w.u_lightintensity),u_lightcolor:new m.Uniform3f(Ee,w.u_lightcolor),u_vertical_gradient:new m.Uniform1f(Ee,w.u_vertical_gradient),u_opacity:new m.Uniform1f(Ee,w.u_opacity),u_tile_id:new m.Uniform3f(Ee,w.u_tile_id),u_zoom_transition:new m.Uniform1f(Ee,w.u_zoom_transition),u_inv_rot_matrix:new m.UniformMatrix4f(Ee,w.u_inv_rot_matrix),u_merc_center:new m.Uniform2f(Ee,w.u_merc_center),u_up_dir:new m.Uniform3f(Ee,w.u_up_dir),u_height_lift:new m.Uniform1f(Ee,w.u_height_lift)}),fillExtrusionPattern:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_lightpos:new m.Uniform3f(Ee,w.u_lightpos),u_lightintensity:new m.Uniform1f(Ee,w.u_lightintensity),u_lightcolor:new m.Uniform3f(Ee,w.u_lightcolor),u_vertical_gradient:new m.Uniform1f(Ee,w.u_vertical_gradient),u_height_factor:new m.Uniform1f(Ee,w.u_height_factor),u_tile_id:new m.Uniform3f(Ee,w.u_tile_id),u_zoom_transition:new m.Uniform1f(Ee,w.u_zoom_transition),u_inv_rot_matrix:new m.UniformMatrix4f(Ee,w.u_inv_rot_matrix),u_merc_center:new m.Uniform2f(Ee,w.u_merc_center),u_up_dir:new m.Uniform3f(Ee,w.u_up_dir),u_height_lift:new m.Uniform1f(Ee,w.u_height_lift),u_image:new m.Uniform1i(Ee,w.u_image),u_texsize:new m.Uniform2f(Ee,w.u_texsize),u_pixel_coord_upper:new m.Uniform2f(Ee,w.u_pixel_coord_upper),u_pixel_coord_lower:new m.Uniform2f(Ee,w.u_pixel_coord_lower),u_scale:new m.Uniform3f(Ee,w.u_scale),u_fade:new m.Uniform1f(Ee,w.u_fade),u_opacity:new m.Uniform1f(Ee,w.u_opacity)}),fill:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix)}),fillPattern:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_image:new m.Uniform1i(Ee,w.u_image),u_texsize:new m.Uniform2f(Ee,w.u_texsize),u_pixel_coord_upper:new m.Uniform2f(Ee,w.u_pixel_coord_upper),u_pixel_coord_lower:new m.Uniform2f(Ee,w.u_pixel_coord_lower),u_scale:new m.Uniform3f(Ee,w.u_scale),u_fade:new m.Uniform1f(Ee,w.u_fade)}),fillOutline:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_world:new m.Uniform2f(Ee,w.u_world)}),fillOutlinePattern:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_world:new m.Uniform2f(Ee,w.u_world),u_image:new m.Uniform1i(Ee,w.u_image),u_texsize:new m.Uniform2f(Ee,w.u_texsize),u_pixel_coord_upper:new m.Uniform2f(Ee,w.u_pixel_coord_upper),u_pixel_coord_lower:new m.Uniform2f(Ee,w.u_pixel_coord_lower),u_scale:new m.Uniform3f(Ee,w.u_scale),u_fade:new m.Uniform1f(Ee,w.u_fade)}),circle:(Ee,w)=>({u_camera_to_center_distance:new m.Uniform1f(Ee,w.u_camera_to_center_distance),u_extrude_scale:new m.UniformMatrix2f(Ee,w.u_extrude_scale),u_device_pixel_ratio:new m.Uniform1f(Ee,w.u_device_pixel_ratio),u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_inv_rot_matrix:new m.UniformMatrix4f(Ee,w.u_inv_rot_matrix),u_merc_center:new m.Uniform2f(Ee,w.u_merc_center),u_tile_id:new m.Uniform3f(Ee,w.u_tile_id),u_zoom_transition:new m.Uniform1f(Ee,w.u_zoom_transition),u_up_dir:new m.Uniform3f(Ee,w.u_up_dir)}),collisionBox:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_camera_to_center_distance:new m.Uniform1f(Ee,w.u_camera_to_center_distance),u_extrude_scale:new m.Uniform2f(Ee,w.u_extrude_scale)}),collisionCircle:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_inv_matrix:new m.UniformMatrix4f(Ee,w.u_inv_matrix),u_camera_to_center_distance:new m.Uniform1f(Ee,w.u_camera_to_center_distance),u_viewport_size:new m.Uniform2f(Ee,w.u_viewport_size)}),debug:(Ee,w)=>({u_color:new m.UniformColor(Ee,w.u_color),u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_overlay:new m.Uniform1i(Ee,w.u_overlay),u_overlay_scale:new m.Uniform1f(Ee,w.u_overlay_scale)}),clippingMask:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix)}),heatmap:(Ee,w)=>({u_extrude_scale:new m.Uniform1f(Ee,w.u_extrude_scale),u_intensity:new m.Uniform1f(Ee,w.u_intensity),u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_inv_rot_matrix:new m.UniformMatrix4f(Ee,w.u_inv_rot_matrix),u_merc_center:new m.Uniform2f(Ee,w.u_merc_center),u_tile_id:new m.Uniform3f(Ee,w.u_tile_id),u_zoom_transition:new m.Uniform1f(Ee,w.u_zoom_transition),u_up_dir:new m.Uniform3f(Ee,w.u_up_dir)}),heatmapTexture:(Ee,w)=>({u_image:new m.Uniform1i(Ee,w.u_image),u_color_ramp:new m.Uniform1i(Ee,w.u_color_ramp),u_opacity:new m.Uniform1f(Ee,w.u_opacity)}),hillshade:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_image:new m.Uniform1i(Ee,w.u_image),u_latrange:new m.Uniform2f(Ee,w.u_latrange),u_light:new m.Uniform2f(Ee,w.u_light),u_shadow:new m.UniformColor(Ee,w.u_shadow),u_highlight:new m.UniformColor(Ee,w.u_highlight),u_accent:new m.UniformColor(Ee,w.u_accent)}),hillshadePrepare:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_image:new m.Uniform1i(Ee,w.u_image),u_dimension:new m.Uniform2f(Ee,w.u_dimension),u_zoom:new m.Uniform1f(Ee,w.u_zoom),u_unpack:new m.Uniform4f(Ee,w.u_unpack)}),line:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_pixels_to_tile_units:new m.UniformMatrix2f(Ee,w.u_pixels_to_tile_units),u_device_pixel_ratio:new m.Uniform1f(Ee,w.u_device_pixel_ratio),u_units_to_pixels:new m.Uniform2f(Ee,w.u_units_to_pixels),u_dash_image:new m.Uniform1i(Ee,w.u_dash_image),u_gradient_image:new m.Uniform1i(Ee,w.u_gradient_image),u_image_height:new m.Uniform1f(Ee,w.u_image_height),u_texsize:new m.Uniform2f(Ee,w.u_texsize),u_scale:new m.Uniform3f(Ee,w.u_scale),u_mix:new m.Uniform1f(Ee,w.u_mix),u_alpha_discard_threshold:new m.Uniform1f(Ee,w.u_alpha_discard_threshold)}),linePattern:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_texsize:new m.Uniform2f(Ee,w.u_texsize),u_pixels_to_tile_units:new m.UniformMatrix2f(Ee,w.u_pixels_to_tile_units),u_device_pixel_ratio:new m.Uniform1f(Ee,w.u_device_pixel_ratio),u_image:new m.Uniform1i(Ee,w.u_image),u_units_to_pixels:new m.Uniform2f(Ee,w.u_units_to_pixels),u_scale:new m.Uniform3f(Ee,w.u_scale),u_fade:new m.Uniform1f(Ee,w.u_fade),u_alpha_discard_threshold:new m.Uniform1f(Ee,w.u_alpha_discard_threshold)}),raster:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_tl_parent:new m.Uniform2f(Ee,w.u_tl_parent),u_scale_parent:new m.Uniform1f(Ee,w.u_scale_parent),u_fade_t:new m.Uniform1f(Ee,w.u_fade_t),u_opacity:new m.Uniform1f(Ee,w.u_opacity),u_image0:new m.Uniform1i(Ee,w.u_image0),u_image1:new m.Uniform1i(Ee,w.u_image1),u_brightness_low:new m.Uniform1f(Ee,w.u_brightness_low),u_brightness_high:new m.Uniform1f(Ee,w.u_brightness_high),u_saturation_factor:new m.Uniform1f(Ee,w.u_saturation_factor),u_contrast_factor:new m.Uniform1f(Ee,w.u_contrast_factor),u_spin_weights:new m.Uniform3f(Ee,w.u_spin_weights),u_perspective_transform:new m.Uniform2f(Ee,w.u_perspective_transform)}),symbolIcon:(Ee,w)=>({u_is_size_zoom_constant:new m.Uniform1i(Ee,w.u_is_size_zoom_constant),u_is_size_feature_constant:new m.Uniform1i(Ee,w.u_is_size_feature_constant),u_size_t:new m.Uniform1f(Ee,w.u_size_t),u_size:new m.Uniform1f(Ee,w.u_size),u_camera_to_center_distance:new m.Uniform1f(Ee,w.u_camera_to_center_distance),u_rotate_symbol:new m.Uniform1i(Ee,w.u_rotate_symbol),u_aspect_ratio:new m.Uniform1f(Ee,w.u_aspect_ratio),u_fade_change:new m.Uniform1f(Ee,w.u_fade_change),u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_label_plane_matrix:new m.UniformMatrix4f(Ee,w.u_label_plane_matrix),u_coord_matrix:new m.UniformMatrix4f(Ee,w.u_coord_matrix),u_is_text:new m.Uniform1i(Ee,w.u_is_text),u_pitch_with_map:new m.Uniform1i(Ee,w.u_pitch_with_map),u_texsize:new m.Uniform2f(Ee,w.u_texsize),u_tile_id:new m.Uniform3f(Ee,w.u_tile_id),u_zoom_transition:new m.Uniform1f(Ee,w.u_zoom_transition),u_inv_rot_matrix:new m.UniformMatrix4f(Ee,w.u_inv_rot_matrix),u_merc_center:new m.Uniform2f(Ee,w.u_merc_center),u_camera_forward:new m.Uniform3f(Ee,w.u_camera_forward),u_tile_matrix:new m.UniformMatrix4f(Ee,w.u_tile_matrix),u_ecef_origin:new m.Uniform3f(Ee,w.u_ecef_origin),u_texture:new m.Uniform1i(Ee,w.u_texture)}),symbolSDF:(Ee,w)=>({u_is_size_zoom_constant:new m.Uniform1i(Ee,w.u_is_size_zoom_constant),u_is_size_feature_constant:new m.Uniform1i(Ee,w.u_is_size_feature_constant),u_size_t:new m.Uniform1f(Ee,w.u_size_t),u_size:new m.Uniform1f(Ee,w.u_size),u_camera_to_center_distance:new m.Uniform1f(Ee,w.u_camera_to_center_distance),u_rotate_symbol:new m.Uniform1i(Ee,w.u_rotate_symbol),u_aspect_ratio:new m.Uniform1f(Ee,w.u_aspect_ratio),u_fade_change:new m.Uniform1f(Ee,w.u_fade_change),u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_label_plane_matrix:new m.UniformMatrix4f(Ee,w.u_label_plane_matrix),u_coord_matrix:new m.UniformMatrix4f(Ee,w.u_coord_matrix),u_is_text:new m.Uniform1i(Ee,w.u_is_text),u_pitch_with_map:new m.Uniform1i(Ee,w.u_pitch_with_map),u_texsize:new m.Uniform2f(Ee,w.u_texsize),u_texture:new m.Uniform1i(Ee,w.u_texture),u_gamma_scale:new m.Uniform1f(Ee,w.u_gamma_scale),u_device_pixel_ratio:new m.Uniform1f(Ee,w.u_device_pixel_ratio),u_tile_id:new m.Uniform3f(Ee,w.u_tile_id),u_zoom_transition:new m.Uniform1f(Ee,w.u_zoom_transition),u_inv_rot_matrix:new m.UniformMatrix4f(Ee,w.u_inv_rot_matrix),u_merc_center:new m.Uniform2f(Ee,w.u_merc_center),u_camera_forward:new m.Uniform3f(Ee,w.u_camera_forward),u_tile_matrix:new m.UniformMatrix4f(Ee,w.u_tile_matrix),u_ecef_origin:new m.Uniform3f(Ee,w.u_ecef_origin),u_is_halo:new m.Uniform1i(Ee,w.u_is_halo)}),symbolTextAndIcon:(Ee,w)=>({u_is_size_zoom_constant:new m.Uniform1i(Ee,w.u_is_size_zoom_constant),u_is_size_feature_constant:new m.Uniform1i(Ee,w.u_is_size_feature_constant),u_size_t:new m.Uniform1f(Ee,w.u_size_t),u_size:new m.Uniform1f(Ee,w.u_size),u_camera_to_center_distance:new m.Uniform1f(Ee,w.u_camera_to_center_distance),u_rotate_symbol:new m.Uniform1i(Ee,w.u_rotate_symbol),u_aspect_ratio:new m.Uniform1f(Ee,w.u_aspect_ratio),u_fade_change:new m.Uniform1f(Ee,w.u_fade_change),u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_label_plane_matrix:new m.UniformMatrix4f(Ee,w.u_label_plane_matrix),u_coord_matrix:new m.UniformMatrix4f(Ee,w.u_coord_matrix),u_is_text:new m.Uniform1i(Ee,w.u_is_text),u_pitch_with_map:new m.Uniform1i(Ee,w.u_pitch_with_map),u_texsize:new m.Uniform2f(Ee,w.u_texsize),u_texsize_icon:new m.Uniform2f(Ee,w.u_texsize_icon),u_texture:new m.Uniform1i(Ee,w.u_texture),u_texture_icon:new m.Uniform1i(Ee,w.u_texture_icon),u_gamma_scale:new m.Uniform1f(Ee,w.u_gamma_scale),u_device_pixel_ratio:new m.Uniform1f(Ee,w.u_device_pixel_ratio),u_is_halo:new m.Uniform1i(Ee,w.u_is_halo)}),background:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_opacity:new m.Uniform1f(Ee,w.u_opacity),u_color:new m.UniformColor(Ee,w.u_color)}),backgroundPattern:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_opacity:new m.Uniform1f(Ee,w.u_opacity),u_image:new m.Uniform1i(Ee,w.u_image),u_pattern_tl_a:new m.Uniform2f(Ee,w.u_pattern_tl_a),u_pattern_br_a:new m.Uniform2f(Ee,w.u_pattern_br_a),u_pattern_tl_b:new m.Uniform2f(Ee,w.u_pattern_tl_b),u_pattern_br_b:new m.Uniform2f(Ee,w.u_pattern_br_b),u_texsize:new m.Uniform2f(Ee,w.u_texsize),u_mix:new m.Uniform1f(Ee,w.u_mix),u_pattern_size_a:new m.Uniform2f(Ee,w.u_pattern_size_a),u_pattern_size_b:new m.Uniform2f(Ee,w.u_pattern_size_b),u_scale_a:new m.Uniform1f(Ee,w.u_scale_a),u_scale_b:new m.Uniform1f(Ee,w.u_scale_b),u_pixel_coord_upper:new m.Uniform2f(Ee,w.u_pixel_coord_upper),u_pixel_coord_lower:new m.Uniform2f(Ee,w.u_pixel_coord_lower),u_tile_units_to_pixels:new m.Uniform1f(Ee,w.u_tile_units_to_pixels)}),terrainRaster:In,terrainDepth:In,skybox:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_sun_direction:new m.Uniform3f(Ee,w.u_sun_direction),u_cubemap:new m.Uniform1i(Ee,w.u_cubemap),u_opacity:new m.Uniform1f(Ee,w.u_opacity),u_temporal_offset:new m.Uniform1f(Ee,w.u_temporal_offset)}),skyboxGradient:(Ee,w)=>({u_matrix:new m.UniformMatrix4f(Ee,w.u_matrix),u_color_ramp:new m.Uniform1i(Ee,w.u_color_ramp),u_center_direction:new m.Uniform3f(Ee,w.u_center_direction),u_radius:new m.Uniform1f(Ee,w.u_radius),u_opacity:new m.Uniform1f(Ee,w.u_opacity),u_temporal_offset:new m.Uniform1f(Ee,w.u_temporal_offset)}),skyboxCapture:(Ee,w)=>({u_matrix_3f:new m.UniformMatrix3f(Ee,w.u_matrix_3f),u_sun_direction:new m.Uniform3f(Ee,w.u_sun_direction),u_sun_intensity:new m.Uniform1f(Ee,w.u_sun_intensity),u_color_tint_r:new m.Uniform4f(Ee,w.u_color_tint_r),u_color_tint_m:new m.Uniform4f(Ee,w.u_color_tint_m),u_luminance:new m.Uniform1f(Ee,w.u_luminance)}),globeRaster:(Ee,w)=>({u_proj_matrix:new m.UniformMatrix4f(Ee,w.u_proj_matrix),u_globe_matrix:new m.UniformMatrix4f(Ee,w.u_globe_matrix),u_merc_matrix:new m.UniformMatrix4f(Ee,w.u_merc_matrix),u_zoom_transition:new m.Uniform1f(Ee,w.u_zoom_transition),u_merc_center:new m.Uniform2f(Ee,w.u_merc_center),u_image0:new m.Uniform1i(Ee,w.u_image0),u_grid_matrix:new m.UniformMatrix3f(Ee,w.u_grid_matrix)}),globeAtmosphere:(Ee,w)=>({u_frustum_tl:new m.Uniform3f(Ee,w.u_frustum_tl),u_frustum_tr:new m.Uniform3f(Ee,w.u_frustum_tr),u_frustum_br:new m.Uniform3f(Ee,w.u_frustum_br),u_frustum_bl:new m.Uniform3f(Ee,w.u_frustum_bl),u_globe_pos:new m.Uniform3f(Ee,w.u_globe_pos),u_globe_radius:new m.Uniform1f(Ee,w.u_globe_radius),u_opacity:new m.Uniform1f(Ee,w.u_opacity),u_fadeout_range:new m.Uniform1f(Ee,w.u_fadeout_range),u_start_color:new m.Uniform3f(Ee,w.u_start_color),u_end_color:new m.Uniform3f(Ee,w.u_end_color)})};let od;function qu(Ee,w,se,it,xt,Dt,Ot){const rn=Ee.context,Tn=rn.gl,kn=Ee.useProgram("collisionBox"),Bn=[];let Wn=0,Fr=0;for(let Ti=0;Ti<it.length;Ti++){const Oi=it[Ti],_i=w.getTile(Oi),Fi=_i.getBucket(se);if(!Fi)continue;let Ta=Oi.projMatrix;xt[0]===0&&xt[1]===0||(Ta=Ee.translatePosMatrix(Oi.projMatrix,_i,xt,Dt));const Fa=Ot?Fi.textCollisionBox:Fi.iconCollisionBox,qa=Fi.collisionCircleArray;if(qa.length>0){const ja=m.create(),To=Ta;m.mul(ja,Fi.placementInvProjMatrix,Ee.transform.glCoordMatrix),m.mul(ja,ja,Fi.placementViewportMatrix),Bn.push({circleArray:qa,circleOffset:Fr,transform:To,invTransform:ja}),Wn+=qa.length/4,Fr=Wn}Fa&&(Ee.terrain&&Ee.terrain.setupElevationDraw(_i,kn),kn.draw(rn,Tn.LINES,m.DepthMode.disabled,m.StencilMode.disabled,Ee.colorModeForRenderPass(),m.CullFaceMode.disabled,Gu(Ta,Ee.transform,_i),se.id,Fa.layoutVertexBuffer,Fa.indexBuffer,Fa.segments,null,Ee.transform.zoom,null,Fa.collisionVertexBuffer,Fa.collisionVertexBufferExt))}if(!Ot||!Bn.length)return;const ri=Ee.useProgram("collisionCircle"),Zr=new m.StructArrayLayout2f1f2i16;Zr.resize(4*Wn),Zr._trim();let Sr=0;for(const Ti of Bn)for(let Oi=0;Oi<Ti.circleArray.length/4;Oi++){const _i=4*Oi,Fi=Ti.circleArray[_i+0],Ta=Ti.circleArray[_i+1],Fa=Ti.circleArray[_i+2],qa=Ti.circleArray[_i+3];Zr.emplace(Sr++,Fi,Ta,Fa,qa,0),Zr.emplace(Sr++,Fi,Ta,Fa,qa,1),Zr.emplace(Sr++,Fi,Ta,Fa,qa,2),Zr.emplace(Sr++,Fi,Ta,Fa,qa,3)}(!od||od.length<2*Wn)&&(od=function(Ti){const Oi=2*Ti,_i=new m.StructArrayLayout3ui6;_i.resize(Oi),_i._trim();for(let Fi=0;Fi<Oi;Fi++){const Ta=6*Fi;_i.uint16[Ta+0]=4*Fi+0,_i.uint16[Ta+1]=4*Fi+1,_i.uint16[Ta+2]=4*Fi+2,_i.uint16[Ta+3]=4*Fi+2,_i.uint16[Ta+4]=4*Fi+3,_i.uint16[Ta+5]=4*Fi+0}return _i}(Wn));const Di=rn.createIndexBuffer(od,!0),di=rn.createVertexBuffer(Zr,m.collisionCircleLayout.members,!0);for(const Ti of Bn){const Oi={u_matrix:Ti.transform,u_inv_matrix:Ti.invTransform,u_camera_to_center_distance:(wi=Ee.transform).cameraToCenterDistance,u_viewport_size:[wi.width,wi.height]};ri.draw(rn,Tn.TRIANGLES,m.DepthMode.disabled,m.StencilMode.disabled,Ee.colorModeForRenderPass(),m.CullFaceMode.disabled,Oi,se.id,di,Di,m.SegmentVector.simpleSegment(0,2*Ti.circleOffset,Ti.circleArray.length,Ti.circleArray.length/2),null,Ee.transform.zoom,null,null,null)}var wi;di.destroy(),Di.destroy()}const ah=m.create();function Mi(Ee,w,se,it,xt,Dt){const{horizontalAlign:Ot,verticalAlign:rn}=m.getAnchorAlignment(Ee),Tn=-(Ot-.5)*w,kn=-(rn-.5)*se,Bn=m.evaluateVariableOffset(Ee,it);return new m.pointGeometry((Tn/xt+Bn[0])*Dt,(kn/xt+Bn[1])*Dt)}function wa(Ee,w,se,it,xt,Dt,Ot,rn,Tn,kn,Bn,Wn){const Fr=Ee.text.placedSymbolArray,ri=Ee.text.dynamicLayoutVertexArray,Zr=Ee.icon.dynamicLayoutVertexArray,Sr={},Di=rn.projMatrix,di=Dt.elevation,wi=Wn.upVectorScale(rn.canonical,Dt.center.lat,Dt.worldSize);ri.clear();for(let Ti=0;Ti<Fr.length;Ti++){const Oi=Fr.get(Ti),_i=Ee.allowVerticalPlacement&&!Oi.placedOrientation,Fi=Oi.hidden||!Oi.crossTileID||_i?null:it[Oi.crossTileID];if(Fi){const Ta=new m.pointGeometry(Oi.tileAnchorX,Oi.tileAnchorY),Fa=Wn.upVector(rn.canonical,Ta.x,Ta.y),qa=di?di.getAtTileOffset(rn,Ta.x,Ta.y):0,ja=zl([Oi.projectedAnchorX+qa*Fa[0]*wi.metersToTile,Oi.projectedAnchorY+qa*Fa[1]*wi.metersToTile,Oi.projectedAnchorZ+qa*Fa[2]*wi.metersToTile],se?Di:Ot),To=Is(Dt.cameraToCenterDistance,ja.signedDistanceFromCamera);let na=xt.evaluateSizeForFeature(Ee.textSizeData,kn,Oi)*To/m.ONE_EM;se&&(na*=Ee.tilePixelRatio/Tn);const{width:Eo,height:So,anchor:Qo,textOffset:Za,textScale:rs}=Fi,is=Mi(Qo,Eo,So,Za,rs,na),hs=se?tl(Ta.add(is),Ot,qa*wi.metersToLabelSpace).point:ja.point.add(w?is.rotate(-Dt.angle):is),ps=Ee.allowVerticalPlacement&&Oi.placedOrientation===m.WritingMode.vertical?Math.PI/2:0;for(let Js=0;Js<Oi.numGlyphs;Js++)m.addDynamicAttributes(ri,hs,ps);Bn&&Oi.associatedIconIndex>=0&&(Sr[Oi.associatedIconIndex]={shiftedAnchor:hs,angle:ps})}else Go(Oi.numGlyphs,ri)}if(Bn){Zr.clear();const Ti=Ee.icon.placedSymbolArray;for(let Oi=0;Oi<Ti.length;Oi++){const _i=Ti.get(Oi);if(_i.hidden)Go(_i.numGlyphs,Zr);else{const Fi=Sr[Oi];if(Fi)for(let Ta=0;Ta<_i.numGlyphs;Ta++)m.addDynamicAttributes(Zr,Fi.shiftedAnchor,Fi.angle);else Go(_i.numGlyphs,Zr)}}Ee.icon.dynamicLayoutVertexBuffer.updateData(Zr)}Ee.text.dynamicLayoutVertexBuffer.updateData(ri)}function la(Ee,w,se){return se.iconsInText&&w?"symbolTextAndIcon":Ee?"symbolSDF":"symbolIcon"}function Wa(Ee,w,se,it,xt,Dt,Ot,rn,Tn,kn,Bn,Wn){const Fr=Ee.context,ri=Fr.gl,Zr=Ee.transform,Sr=rn==="map",Di=Tn==="map",di=Sr&&se.layout.get("symbol-placement")!=="point",wi=Sr&&!Di&&!di,Ti=se.layout.get("symbol-sort-key").constantOr(1)!==void 0;let Oi=!1;const _i=Ee.depthModeForSublayer(0,m.DepthMode.ReadOnly),Fi=[m.mercatorXfromLng(Zr.center.lng),m.mercatorYfromLat(Zr.center.lat)],Ta=se.layout.get("text-variable-anchor"),Fa=Zr.projection.name==="globe",qa=Fa?m.globeToMercatorTransition(Zr.zoom):0,ja=[],To=[];Ee.terrain&&Di&&To.push("PITCH_WITH_MAP_TERRAIN"),Fa&&To.push("PROJECTION_GLOBE_VIEW");for(const na of it){const Eo=w.getTile(na),So=Eo.getBucket(se);if(!So||So.projection!==Zr.projection.name)continue;const Qo=xt?So.text:So.icon;if(!Qo||So.fullyClipped||!Qo.segments.get().length)continue;const Za=Qo.programConfigurations.get(se.id),rs=xt||So.sdfIcons,is=xt?So.textSizeData:So.iconSizeData,hs=Di||Zr.pitch!==0,ps=m.evaluateSizeForZoom(is,Zr.zoom);let Js,fl,as,ll,Yl=[0,0],dc=null;if(xt){if(fl=Eo.glyphAtlasTexture,as=ri.LINEAR,Js=Eo.glyphAtlasTexture.size,So.iconsInText){Yl=Eo.imageAtlasTexture.size,dc=Eo.imageAtlasTexture;const Vc=is.kind==="composite"||is.kind==="camera";ll=hs||Ee.options.rotating||Ee.options.zooming||Vc?ri.LINEAR:ri.NEAREST}}else{const Vc=se.layout.get("icon-size").constantOr(0)!==1||So.iconsNeedLinear;fl=Eo.imageAtlasTexture,as=rs||Ee.options.rotating||Ee.options.zooming||Vc||hs?ri.LINEAR:ri.NEAREST,Js=Eo.imageAtlasTexture.size}const _c=Ee.transform.calculatePixelsToTileUnitsMatrix(Eo),Bc=ju(na.projMatrix,Eo.tileID.canonical,Di,Sr,Ee.transform,_c),Ud=Ee.terrain&&Di&&di?m.invert(m.create(),Bc):ah,sh=Pl(na.projMatrix,Eo.tileID.canonical,Di,Sr,Ee.transform,_c),yh=Ta&&So.hasTextData(),Bh=se.layout.get("icon-text-fit")!=="none"&&yh&&So.hasIconData();if(di){const Vc=Zr.elevation,lh=Vc?Vc.getAtTileOffsetFunc(na,Zr.center.lat,Zr.worldSize,Zr.projection):gp=>[0,0,0];Mn(So,na.projMatrix,Ee,xt,Bc,sh,Di,kn,lh,na)}const Vh=di||xt&&Ta||Bh,Uu=Ee.translatePosMatrix(na.projMatrix,Eo,Dt,Ot),ec=Vh?ah:Bc,tu=Ee.translatePosMatrix(sh,Eo,Dt,Ot,!0),tc=Zr.projection.createInversionMatrix(Zr,na.canonical),fd=Vh?To.concat(["PROJECTED_POS_ON_VIEWPORT"]):To,Yu=rs&&se.paint.get(xt?"text-halo-width":"icon-halo-width").constantOr(1)!==0;let Tc;Tc=rs?So.iconsInText?qc(is.kind,ps,wi,Di,Ee,Uu,ec,tu,Js,Yl,na,qa,Fi,tc):sc(is.kind,ps,wi,Di,Ee,Uu,ec,tu,xt,Js,!0,na,qa,Fi,tc):Jc(is.kind,ps,wi,Di,Ee,Uu,ec,tu,xt,Js,na,qa,Fi,tc);const $d={program:Ee.useProgram(la(rs,xt,So),Za,fd),buffers:Qo,uniformValues:Tc,atlasTexture:fl,atlasTextureIcon:dc,atlasInterpolation:as,atlasInterpolationIcon:ll,isSDF:rs,hasHalo:Yu,tile:Eo,labelPlaneMatrixInv:Ud};if(Ti&&So.canOverlap){Oi=!0;const Vc=Qo.segments.get();for(const lh of Vc)ja.push({segments:new m.SegmentVector([lh]),sortKey:lh.sortKey,state:$d})}else ja.push({segments:Qo.segments,sortKey:0,state:$d})}Oi&&ja.sort((na,Eo)=>na.sortKey-Eo.sortKey);for(const na of ja){const Eo=na.state;if(Ee.terrain&&Ee.terrain.setupElevationDraw(Eo.tile,Eo.program,{useDepthForOcclusion:!Fa,labelPlaneMatrixInv:Eo.labelPlaneMatrixInv}),Fr.activeTexture.set(ri.TEXTURE0),Eo.atlasTexture.bind(Eo.atlasInterpolation,ri.CLAMP_TO_EDGE),Eo.atlasTextureIcon&&(Fr.activeTexture.set(ri.TEXTURE1),Eo.atlasTextureIcon&&Eo.atlasTextureIcon.bind(Eo.atlasInterpolationIcon,ri.CLAMP_TO_EDGE)),Eo.isSDF){const So=Eo.uniformValues;Eo.hasHalo&&(So.u_is_halo=1,lo(Eo.buffers,na.segments,se,Ee,Eo.program,_i,Bn,Wn,So)),So.u_is_halo=0}lo(Eo.buffers,na.segments,se,Ee,Eo.program,_i,Bn,Wn,Eo.uniformValues)}}function lo(Ee,w,se,it,xt,Dt,Ot,rn,Tn){const kn=it.context;xt.draw(kn,kn.gl.TRIANGLES,Dt,Ot,rn,m.CullFaceMode.disabled,Tn,se.id,Ee.layoutVertexBuffer,Ee.indexBuffer,w,se.paint,it.transform.zoom,Ee.programConfigurations.get(se.id),Ee.dynamicLayoutVertexBuffer,Ee.opacityVertexBuffer)}function Jo(Ee,w,se,it,xt,Dt,Ot){const rn=Ee.context.gl,Tn=se.paint.get("fill-pattern"),kn=Tn&&Tn.constantOr(1),Bn=se.getCrossfadeParameters();let Wn,Fr,ri,Zr,Sr;Ot?(Fr=kn&&!se.getPaintProperty("fill-outline-color")?"fillOutlinePattern":"fillOutline",Wn=rn.LINES):(Fr=kn?"fillPattern":"fill",Wn=rn.TRIANGLES);for(const Di of it){const di=w.getTile(Di);if(kn&&!di.patternsLoaded())continue;const wi=di.getBucket(se);if(!wi)continue;Ee.prepareDrawTile();const Ti=wi.programConfigurations.get(se.id),Oi=Ee.useProgram(Fr,Ti);kn&&(Ee.context.activeTexture.set(rn.TEXTURE0),di.imageAtlasTexture.bind(rn.LINEAR,rn.CLAMP_TO_EDGE),Ti.updatePaintBuffers(Bn));const _i=Tn.constantOr(null);if(_i&&di.imageAtlas){const Ta=di.imageAtlas,Fa=Ta.patternPositions[_i.to.toString()],qa=Ta.patternPositions[_i.from.toString()];Fa&&qa&&Ti.setConstantPatternPositions(Fa,qa)}const Fi=Ee.translatePosMatrix(Di.projMatrix,di,se.paint.get("fill-translate"),se.paint.get("fill-translate-anchor"));if(Ot){Zr=wi.indexBuffer2,Sr=wi.segments2;const Ta=Ee.terrain&&Ee.terrain.renderingToTexture?Ee.terrain.drapeBufferSize:[rn.drawingBufferWidth,rn.drawingBufferHeight];ri=Fr==="fillOutlinePattern"&&kn?Nl(Fi,Ee,Bn,di,Ta):Vu(Fi,Ta)}else Zr=wi.indexBuffer,Sr=wi.segments,ri=kn?Ju(Fi,Ee,Bn,di):Xu(Fi);Ee.prepareDrawProgram(Ee.context,Oi,Di.toUnwrapped()),Oi.draw(Ee.context,Wn,xt,Ee.stencilModeForClipping(Di),Dt,m.CullFaceMode.disabled,ri,se.id,wi.layoutVertexBuffer,Zr,Sr,se.paint,Ee.transform.zoom,Ti)}}function Xo(Ee,w,se,it,xt,Dt,Ot){const rn=Ee.context,Tn=rn.gl,kn=Ee.transform,Bn=se.paint.get("fill-extrusion-pattern"),Wn=Bn.constantOr(1),Fr=se.getCrossfadeParameters(),ri=se.paint.get("fill-extrusion-opacity"),Zr=function(Ti){if(Ti.projection.name!=="globe")return 0;const Oi=Math.PI/32,_i=Math.tan(Oi),Fi=m.earthRadius;return Fi*Math.sqrt(1+2*_i*_i)-Fi}(kn),Sr=kn.projection.name==="globe",Di=Sr?m.globeToMercatorTransition(kn.zoom):0,di=[m.mercatorXfromLng(kn.center.lng),m.mercatorYfromLat(kn.center.lat)],wi=[];Sr&&wi.push("PROJECTION_GLOBE_VIEW");for(const Ti of it){const Oi=w.getTile(Ti),_i=Oi.getBucket(se);if(!_i||_i.projection!==kn.projection.name)continue;const Fi=_i.programConfigurations.get(se.id),Ta=Ee.useProgram(Wn?"fillExtrusionPattern":"fillExtrusion",Fi,wi);if(Ee.terrain){const Eo=Ee.terrain;if(Ee.style.terrainSetForDrapingOnly())Eo.setupElevationDraw(Oi,Ta,{useMeterToDem:!0});else{if(!_i.enableTerrain)continue;if(Eo.setupElevationDraw(Oi,Ta,{useMeterToDem:!0}),ei(rn,w,Ti,_i,se,Eo),!_i.centroidVertexBuffer){const So=Ta.attributes.a_centroid_pos;So!==void 0&&Tn.vertexAttrib2f(So,0,0)}}}Wn&&(Ee.context.activeTexture.set(Tn.TEXTURE0),Oi.imageAtlasTexture.bind(Tn.LINEAR,Tn.CLAMP_TO_EDGE),Fi.updatePaintBuffers(Fr));const Fa=Bn.constantOr(null);if(Fa&&Oi.imageAtlas){const Eo=Oi.imageAtlas,So=Eo.patternPositions[Fa.to.toString()],Qo=Eo.patternPositions[Fa.from.toString()];So&&Qo&&Fi.setConstantPatternPositions(So,Qo)}const qa=Ee.translatePosMatrix(Ti.projMatrix,Oi,se.paint.get("fill-extrusion-translate"),se.paint.get("fill-extrusion-translate-anchor")),ja=kn.projection.createInversionMatrix(kn,Ti.canonical),To=se.paint.get("fill-extrusion-vertical-gradient"),na=Wn?ac(qa,Ee,To,ri,Ti,Fr,Oi,Zr,Di,di,ja):du(qa,Ee,To,ri,Ti,Zr,Di,di,ja);Ee.prepareDrawProgram(rn,Ta,Ti.toUnwrapped()),Ta.draw(rn,rn.gl.TRIANGLES,xt,Dt,Ot,m.CullFaceMode.backCCW,na,se.id,_i.layoutVertexBuffer,_i.indexBuffer,_i.segments,se.paint,Ee.transform.zoom,Fi,Ee.terrain?_i.centroidVertexBuffer:null,Sr?_i.layoutVertexExtBuffer:null)}}function ei(Ee,w,se,it,xt,Dt){const Ot=[di=>{let wi=di.canonical.x-1,Ti=di.wrap;return wi<0&&(wi=(1<<di.canonical.z)-1,Ti--),new m.OverscaledTileID(di.overscaledZ,Ti,di.canonical.z,wi,di.canonical.y)},di=>{let wi=di.canonical.x+1,Ti=di.wrap;return wi===1<<di.canonical.z&&(wi=0,Ti++),new m.OverscaledTileID(di.overscaledZ,Ti,di.canonical.z,wi,di.canonical.y)},di=>new m.OverscaledTileID(di.overscaledZ,di.wrap,di.canonical.z,di.canonical.x,(di.canonical.y===0?1<<di.canonical.z:di.canonical.y)-1),di=>new m.OverscaledTileID(di.overscaledZ,di.wrap,di.canonical.z,di.canonical.x,di.canonical.y===(1<<di.canonical.z)-1?0:di.canonical.y+1)],rn=di=>{const wi=w.getSource().minzoom,Ti=_i=>{const Fi=w.getTileByID(_i);if(Fi&&Fi.hasData())return Fi.getBucket(xt)},Oi=[0,-1,1];for(const _i of Oi){if(di.overscaledZ+_i<wi)continue;const Fi=Ti(di.calculateScaledKey(di.overscaledZ+_i));if(Fi)return Fi}},Tn=[0,0,0],kn=(di,wi)=>(Tn[0]=Math.min(di.min.y,wi.min.y),Tn[1]=Math.max(di.max.y,wi.max.y),Tn[2]=m.EXTENT-wi.min.x>di.max.x?wi.min.x-m.EXTENT:di.max.x,Tn),Bn=(di,wi)=>(Tn[0]=Math.min(di.min.x,wi.min.x),Tn[1]=Math.max(di.max.x,wi.max.x),Tn[2]=m.EXTENT-wi.min.y>di.max.y?wi.min.y-m.EXTENT:di.max.y,Tn),Wn=[(di,wi)=>kn(di,wi),(di,wi)=>kn(wi,di),(di,wi)=>Bn(di,wi),(di,wi)=>Bn(wi,di)],Fr=new m.pointGeometry(0,0);let ri,Zr,Sr;const Di=(di,wi,Ti,Oi,_i)=>{const Fi=[[Oi?Ti:di,Oi?di:Ti,0],[Oi?Ti:wi,Oi?wi:Ti,0]],Ta=_i<0?m.EXTENT+_i:_i,Fa=[Oi?Ta:(di+wi)/2,Oi?(di+wi)/2:Ta,0];return Ti===0&&_i<0||Ti!==0&&_i>0?Dt.getForTilePoints(Sr,[Fa],!0,Zr):Fi.push(Fa),Dt.getForTilePoints(se,Fi,!0,ri),Math.max(Fi[0][2],Fi[1][2],Fa[2])/Dt.exaggeration()};for(let di=0;di<4;di++){const wi=(di<2?1:5)-di,Ti=it.borders[di];if(Ti.length===0)continue;const Oi=Sr=Ot[di](se),_i=rn(Oi);if(!(_i&&_i instanceof m.FillExtrusionBucket&&_i.enableTerrain)||it.borderDoneWithNeighborZ[di]===_i.canonical.z&&_i.borderDoneWithNeighborZ[wi]===it.canonical.z||(Zr=Dt.findDEMTileFor(Oi),!Zr||!Zr.dem))continue;if(!ri){const qa=Dt.findDEMTileFor(se);if(!qa||!qa.dem)return;ri=qa}const Fi=_i.borders[wi];let Ta=0;const Fa=_i.borderDoneWithNeighborZ[wi]!==it.canonical.z;if(it.canonical.z===_i.canonical.z){for(let qa=0;qa<Ti.length;qa++){const ja=it.featuresOnBorder[Ti[qa]],To=ja.borders[di];let na;for(;Ta<Fi.length&&(na=_i.featuresOnBorder[Fi[Ta]],!(na.borders[wi][1]>To[0]+3));)Fa&&_i.encodeCentroid(void 0,na,!1),Ta++;if(na&&Ta<Fi.length){const Eo=Ta;let So=0;for(;!(na.borders[wi][0]>To[1]-3)&&(So++,++Ta!==Fi.length);)na=_i.featuresOnBorder[Fi[Ta]];if(na=_i.featuresOnBorder[Fi[Eo]],ja.intersectsCount()>1||na.intersectsCount()>1||So!==1){So!==1&&(Ta=Eo),it.encodeCentroid(void 0,ja,!1),Fa&&_i.encodeCentroid(void 0,na,!1);continue}const Qo=Wn[di](ja,na),Za=di%2?m.EXTENT-1:0;Fr.x=Di(Qo[0],Math.min(m.EXTENT-1,Qo[1]),Za,di<2,Qo[2]),Fr.y=0,it.encodeCentroid(Fr,ja,!1),Fa&&_i.encodeCentroid(Fr,na,!1)}else it.encodeCentroid(void 0,ja,!1)}it.borderDoneWithNeighborZ[di]=_i.canonical.z,it.needsCentroidUpdate=!0,Fa&&(_i.borderDoneWithNeighborZ[wi]=it.canonical.z,_i.needsCentroidUpdate=!0)}else{for(const qa of Ti)it.encodeCentroid(void 0,it.featuresOnBorder[qa],!1);if(Fa){for(const qa of Fi)_i.encodeCentroid(void 0,_i.featuresOnBorder[qa],!1);_i.borderDoneWithNeighborZ[wi]=it.canonical.z,_i.needsCentroidUpdate=!0}it.borderDoneWithNeighborZ[di]=_i.canonical.z,it.needsCentroidUpdate=!0}}(it.needsCentroidUpdate||!it.centroidVertexBuffer&&it.centroidVertexArray.length!==0)&&it.uploadCentroid(Ee)}const ii=new m.Color(1,0,0,1),Ma=new m.Color(0,1,0,1),pa=new m.Color(0,0,1,1),ca=new m.Color(1,0,1,1),uo=new m.Color(0,1,1,1);function ya(Ee,w,se,it){Io(Ee,0,w+se/2,Ee.transform.width,se,it)}function Oo(Ee,w,se,it){Io(Ee,w-se/2,0,se,Ee.transform.height,it)}function Io(Ee,w,se,it,xt,Dt){const Ot=Ee.context,rn=Ot.gl;rn.enable(rn.SCISSOR_TEST),rn.scissor(w*m.exported.devicePixelRatio,se*m.exported.devicePixelRatio,it*m.exported.devicePixelRatio,xt*m.exported.devicePixelRatio),Ot.clear({color:Dt}),rn.disable(rn.SCISSOR_TEST)}function Ws(Ee,w,se){const it=Ee.context,xt=it.gl,Dt=Ee.transform.projection.name==="globe",Ot=se.projMatrix,rn=Ee.useProgram("debug",null,Dt?["PROJECTION_GLOBE_VIEW"]:null),Tn=w.getTileByID(se.key);Ee.terrain&&Ee.terrain.setupElevationDraw(Tn,rn);const kn=m.DepthMode.disabled,Bn=m.StencilMode.disabled,Wn=Ee.colorModeForRenderPass(),Fr="$debug";it.activeTexture.set(xt.TEXTURE0),Ee.emptyTexture.bind(xt.LINEAR,xt.CLAMP_TO_EDGE),Dt?Tn._makeGlobeTileDebugBuffers(Ee.context,Ee.transform.projection):Tn._makeDebugTileBoundsBuffers(Ee.context,Ee.transform.projection);const ri=Tn._tileDebugBuffer||Ee.debugBuffer,Zr=Tn._tileDebugIndexBuffer||Ee.debugIndexBuffer,Sr=Tn._tileDebugSegments||Ee.debugSegments;rn.draw(it,xt.LINE_STRIP,kn,Bn,Wn,m.CullFaceMode.disabled,Bs(Ot,m.Color.red),Fr,ri,Zr,Sr,null,null,null,Tn._globeTileDebugBorderBuffer);const Di=Tn.latestRawTileData,di=Math.floor((Di&&Di.byteLength||0)/1024),wi=w.getTile(se).tileSize,Ti=512/Math.min(wi,512)*(se.overscaledZ/Ee.transform.zoom)*.5;let Oi=se.canonical.toString();se.overscaledZ!==se.canonical.z&&(Oi+=` => ${se.overscaledZ}`),function(Fa,qa){Fa.initDebugOverlayCanvas();const ja=Fa.debugOverlayCanvas,To=Fa.context.gl,na=Fa.debugOverlayCanvas.getContext("2d");na.clearRect(0,0,ja.width,ja.height),na.shadowColor="white",na.shadowBlur=2,na.lineWidth=1.5,na.strokeStyle="white",na.textBaseline="top",na.font="bold 36px Open Sans, sans-serif",na.fillText(qa,5,5),na.strokeText(qa,5,5),Fa.debugOverlayTexture.update(ja),Fa.debugOverlayTexture.bind(To.LINEAR,To.CLAMP_TO_EDGE)}(Ee,`${Oi} ${di}kb`);const _i=Tn._tileDebugTextBuffer||Ee.debugBuffer,Fi=Tn._tileDebugTextIndexBuffer||Ee.quadTriangleIndexBuffer,Ta=Tn._tileDebugTextSegments||Ee.debugSegments;rn.draw(it,xt.TRIANGLES,kn,Bn,m.ColorMode.alphaBlended,m.CullFaceMode.disabled,Bs(Ot,m.Color.transparent,Ti),Fr,_i,Fi,Ta,null,null,null,Tn._globeTileDebugTextBuffer)}const gr=m.createLayout([{name:"a_pos_3f",components:3,type:"Float32"}]),{members:ws}=gr;function io(Ee,w,se,it){Ee.emplaceBack(w,se,it)}class Fo{constructor(w){this.vertexArray=new m.StructArrayLayout3f12,this.indices=new m.StructArrayLayout3ui6,io(this.vertexArray,-1,-1,1),io(this.vertexArray,1,-1,1),io(this.vertexArray,-1,1,1),io(this.vertexArray,1,1,1),io(this.vertexArray,-1,-1,-1),io(this.vertexArray,1,-1,-1),io(this.vertexArray,-1,1,-1),io(this.vertexArray,1,1,-1),this.indices.emplaceBack(5,1,3),this.indices.emplaceBack(3,7,5),this.indices.emplaceBack(6,2,0),this.indices.emplaceBack(0,4,6),this.indices.emplaceBack(2,6,7),this.indices.emplaceBack(7,3,2),this.indices.emplaceBack(5,4,0),this.indices.emplaceBack(0,1,5),this.indices.emplaceBack(0,2,3),this.indices.emplaceBack(3,1,0),this.indices.emplaceBack(7,6,4),this.indices.emplaceBack(4,5,7),this.vertexBuffer=w.createVertexBuffer(this.vertexArray,ws),this.indexBuffer=w.createIndexBuffer(this.indices),this.segment=m.SegmentVector.simpleSegment(0,0,36,12)}}function vs(Ee,w,se,it,xt,Dt){const Ot=Ee.gl,rn=w.paint.get("sky-atmosphere-color"),Tn=w.paint.get("sky-atmosphere-halo-color"),kn=w.paint.get("sky-atmosphere-sun-intensity"),Bn=((Wn,Fr,ri,Zr,Sr)=>({u_matrix_3f:Wn,u_sun_direction:Fr,u_sun_intensity:ri,u_color_tint_r:[Zr.r,Zr.g,Zr.b,Zr.a],u_color_tint_m:[Sr.r,Sr.g,Sr.b,Sr.a],u_luminance:5e-5}))(m.fromMat4(m.create$1(),it),xt,kn,rn,Tn);Ot.framebufferTexture2D(Ot.FRAMEBUFFER,Ot.COLOR_ATTACHMENT0,Ot.TEXTURE_CUBE_MAP_POSITIVE_X+Dt,w.skyboxTexture,0),se.draw(Ee,Ot.TRIANGLES,m.DepthMode.disabled,m.StencilMode.disabled,m.ColorMode.unblended,m.CullFaceMode.frontCW,Bn,"skyboxCapture",w.skyboxGeometry.vertexBuffer,w.skyboxGeometry.indexBuffer,w.skyboxGeometry.segment)}function Gl(Ee,w){return m.transformMat4(Ee,Ee,w)}const Mu={symbol:function(Ee,w,se,it,xt){if(Ee.renderPass!=="translucent")return;const Dt=m.StencilMode.disabled,Ot=Ee.colorModeForRenderPass();se.layout.get("text-variable-anchor")&&function(rn,Tn,kn,Bn,Wn,Fr,ri){const Zr=Tn.transform,Sr=Wn==="map",Di=Fr==="map";for(const di of rn){const wi=Bn.getTile(di),Ti=wi.getBucket(kn);if(!Ti||Ti.projection!==Zr.projection.name||!Ti.text||!Ti.text.segments.get().length)continue;const Oi=m.evaluateSizeForZoom(Ti.textSizeData,Zr.zoom),_i=Tn.transform.calculatePixelsToTileUnitsMatrix(wi),Fi=ju(di.projMatrix,wi.tileID.canonical,Di,Sr,Tn.transform,_i),Ta=kn.layout.get("icon-text-fit")!=="none"&&Ti.hasIconData();if(Oi){const Fa=Math.pow(2,Zr.zoom-wi.tileID.overscaledZ);wa(Ti,Sr,Di,ri,m.symbolSize,Zr,Fi,di,Fa,Oi,Ta,Zr.projection)}}}(it,Ee,se,w,se.layout.get("text-rotation-alignment"),se.layout.get("text-pitch-alignment"),xt),se.paint.get("icon-opacity").constantOr(1)!==0&&Wa(Ee,w,se,it,!1,se.paint.get("icon-translate"),se.paint.get("icon-translate-anchor"),se.layout.get("icon-rotation-alignment"),se.layout.get("icon-pitch-alignment"),se.layout.get("icon-keep-upright"),Dt,Ot),se.paint.get("text-opacity").constantOr(1)!==0&&Wa(Ee,w,se,it,!0,se.paint.get("text-translate"),se.paint.get("text-translate-anchor"),se.layout.get("text-rotation-alignment"),se.layout.get("text-pitch-alignment"),se.layout.get("text-keep-upright"),Dt,Ot),w.map.showCollisionBoxes&&(qu(Ee,w,se,it,se.paint.get("text-translate"),se.paint.get("text-translate-anchor"),!0),qu(Ee,w,se,it,se.paint.get("icon-translate"),se.paint.get("icon-translate-anchor"),!1))},circle:function(Ee,w,se,it){if(Ee.renderPass!=="translucent")return;const xt=se.paint.get("circle-opacity"),Dt=se.paint.get("circle-stroke-width"),Ot=se.paint.get("circle-stroke-opacity"),rn=se.layout.get("circle-sort-key").constantOr(1)!==void 0;if(xt.constantOr(1)===0&&(Dt.constantOr(1)===0||Ot.constantOr(1)===0))return;const Tn=Ee.context,kn=Tn.gl,Bn=Ee.transform,Wn=Ee.depthModeForSublayer(0,m.DepthMode.ReadOnly),Fr=m.StencilMode.disabled,ri=Ee.colorModeForRenderPass(),Zr=Bn.projection.name==="globe",Sr=[m.mercatorXfromLng(Bn.center.lng),m.mercatorYfromLat(Bn.center.lat)],Di=[];for(let wi=0;wi<it.length;wi++){const Ti=it[wi],Oi=w.getTile(Ti),_i=Oi.getBucket(se);if(!_i)continue;const Fi=_i.programConfigurations.get(se.id),Ta=Qu(se);Zr&&Ta.push("PROJECTION_GLOBE_VIEW");const Fa=Ee.useProgram("circle",Fi,Ta),qa=_i.layoutVertexBuffer,ja=_i.globeExtVertexBuffer,To=_i.indexBuffer,na=Bn.projection.createInversionMatrix(Bn,Ti.canonical),Eo={programConfiguration:Fi,program:Fa,layoutVertexBuffer:qa,globeExtVertexBuffer:ja,indexBuffer:To,uniformValues:hu(Ee,Ti,Oi,na,Sr,se),tile:Oi};if(rn){const So=_i.segments.get();for(const Qo of So)Di.push({segments:new m.SegmentVector([Qo]),sortKey:Qo.sortKey,state:Eo})}else Di.push({segments:_i.segments,sortKey:0,state:Eo})}rn&&Di.sort((wi,Ti)=>wi.sortKey-Ti.sortKey);const di={useDepthForOcclusion:!Zr};for(const wi of Di){const{programConfiguration:Ti,program:Oi,layoutVertexBuffer:_i,globeExtVertexBuffer:Fi,indexBuffer:Ta,uniformValues:Fa,tile:qa}=wi.state,ja=wi.segments;Ee.terrain&&Ee.terrain.setupElevationDraw(qa,Oi,di),Ee.prepareDrawProgram(Tn,Oi,qa.tileID.toUnwrapped()),Oi.draw(Tn,kn.TRIANGLES,Wn,Fr,ri,m.CullFaceMode.disabled,Fa,se.id,_i,Ta,ja,se.paint,Bn.zoom,Ti,Zr?Fi:null)}},heatmap:function(Ee,w,se,it){if(se.paint.get("heatmap-opacity")!==0)if(Ee.renderPass==="offscreen"){const xt=Ee.context,Dt=xt.gl,Ot=m.StencilMode.disabled,rn=new m.ColorMode([Dt.ONE,Dt.ONE],m.Color.transparent,[!0,!0,!0,!0]);(function(Fr,ri,Zr){const Sr=Fr.gl;Fr.activeTexture.set(Sr.TEXTURE1),Fr.viewport.set([0,0,ri.width/4,ri.height/4]);let Di=Zr.heatmapFbo;if(Di)Sr.bindTexture(Sr.TEXTURE_2D,Di.colorAttachment.get()),Fr.bindFramebuffer.set(Di.framebuffer);else{const di=Sr.createTexture();Sr.bindTexture(Sr.TEXTURE_2D,di),Sr.texParameteri(Sr.TEXTURE_2D,Sr.TEXTURE_WRAP_S,Sr.CLAMP_TO_EDGE),Sr.texParameteri(Sr.TEXTURE_2D,Sr.TEXTURE_WRAP_T,Sr.CLAMP_TO_EDGE),Sr.texParameteri(Sr.TEXTURE_2D,Sr.TEXTURE_MIN_FILTER,Sr.LINEAR),Sr.texParameteri(Sr.TEXTURE_2D,Sr.TEXTURE_MAG_FILTER,Sr.LINEAR),Di=Zr.heatmapFbo=Fr.createFramebuffer(ri.width/4,ri.height/4,!1),function(wi,Ti,Oi,_i){const Fi=wi.gl;Fi.texImage2D(Fi.TEXTURE_2D,0,Fi.RGBA,Ti.width/4,Ti.height/4,0,Fi.RGBA,wi.extRenderToTextureHalfFloat?wi.extTextureHalfFloat.HALF_FLOAT_OES:Fi.UNSIGNED_BYTE,null),_i.colorAttachment.set(Oi)}(Fr,ri,di,Di)}})(xt,Ee,se),xt.clear({color:m.Color.transparent});const Tn=Ee.transform,kn=Tn.projection.name==="globe",Bn=kn?["PROJECTION_GLOBE_VIEW"]:null,Wn=[m.mercatorXfromLng(Tn.center.lng),m.mercatorYfromLat(Tn.center.lat)];for(let Fr=0;Fr<it.length;Fr++){const ri=it[Fr];if(w.hasRenderableParent(ri))continue;const Zr=w.getTile(ri),Sr=Zr.getBucket(se);if(!Sr)continue;const Di=Sr.programConfigurations.get(se.id),di=Ee.useProgram("heatmap",Di,Bn),{zoom:wi}=Ee.transform;Ee.terrain&&Ee.terrain.setupElevationDraw(Zr,di),Ee.prepareDrawProgram(xt,di,ri.toUnwrapped());const Ti=Tn.projection.createInversionMatrix(Tn,ri.canonical);di.draw(xt,Dt.TRIANGLES,m.DepthMode.disabled,Ot,rn,m.CullFaceMode.disabled,ku(Ee,ri,Zr,Ti,Wn,wi,se.paint.get("heatmap-intensity")),se.id,Sr.layoutVertexBuffer,Sr.indexBuffer,Sr.segments,se.paint,Ee.transform.zoom,Di,kn?Sr.globeExtVertexBuffer:null)}xt.viewport.set([0,0,Ee.width,Ee.height])}else Ee.renderPass==="translucent"&&(Ee.context.setColorMode(Ee.colorModeForRenderPass()),function(xt,Dt){const Ot=xt.context,rn=Ot.gl,Tn=Dt.heatmapFbo;if(!Tn)return;Ot.activeTexture.set(rn.TEXTURE0),rn.bindTexture(rn.TEXTURE_2D,Tn.colorAttachment.get()),Ot.activeTexture.set(rn.TEXTURE1);let kn=Dt.colorRampTexture;kn||(kn=Dt.colorRampTexture=new m.Texture(Ot,Dt.colorRamp,rn.RGBA)),kn.bind(rn.LINEAR,rn.CLAMP_TO_EDGE),xt.useProgram("heatmapTexture").draw(Ot,rn.TRIANGLES,m.DepthMode.disabled,m.StencilMode.disabled,xt.colorModeForRenderPass(),m.CullFaceMode.disabled,((Bn,Wn,Fr,ri)=>({u_image:0,u_color_ramp:1,u_opacity:Wn.paint.get("heatmap-opacity")}))(0,Dt),Dt.id,xt.viewportBuffer,xt.quadTriangleIndexBuffer,xt.viewportSegments,Dt.paint,xt.transform.zoom)}(Ee,se))},line:function(Ee,w,se,it){if(Ee.renderPass!=="translucent")return;const xt=se.paint.get("line-opacity"),Dt=se.paint.get("line-width");if(xt.constantOr(1)===0||Dt.constantOr(1)===0)return;const Ot=Ee.depthModeForSublayer(0,m.DepthMode.ReadOnly),rn=Ee.colorModeForRenderPass(),Tn=Ee.terrain&&Ee.terrain.renderingToTexture?1:m.exported.devicePixelRatio,kn=se.paint.get("line-dasharray"),Bn=kn.constantOr(1),Wn=se.layout.get("line-cap"),Fr=se.paint.get("line-pattern"),ri=Fr.constantOr(1),Zr=se.paint.get("line-gradient"),Sr=se.getCrossfadeParameters(),Di=ri?"linePattern":"line",di=Ee.context,wi=di.gl,Ti=(_i=>{const Fi=[];wu(_i)&&Fi.push("RENDER_LINE_DASH"),_i.paint.get("line-gradient")&&Fi.push("RENDER_LINE_GRADIENT");const Ta=_i.paint.get("line-pattern").constantOr(1),Fa=_i.paint.get("line-opacity").constantOr(1)!==1;return!Ta&&Fa&&Fi.push("RENDER_LINE_ALPHA_DISCARD"),Fi})(se);let Oi=Ti.includes("RENDER_LINE_ALPHA_DISCARD");Ee.terrain&&Ee.terrain.clipOrMaskOverlapStencilType()&&(Oi=!1);for(const _i of it){const Fi=w.getTile(_i);if(ri&&!Fi.patternsLoaded())continue;const Ta=Fi.getBucket(se);if(!Ta)continue;Ee.prepareDrawTile();const Fa=Ta.programConfigurations.get(se.id),qa=Ee.useProgram(Di,Fa,Ti),ja=Fr.constantOr(null);if(ja&&Fi.imageAtlas){const Za=Fi.imageAtlas,rs=Za.patternPositions[ja.to.toString()],is=Za.patternPositions[ja.from.toString()];rs&&is&&Fa.setConstantPatternPositions(rs,is)}const To=kn.constantOr(null),na=Wn.constantOr(null);if(!ri&&To&&na&&Fi.lineAtlas){const Za=Fi.lineAtlas,rs=Za.getDash(To.to,na),is=Za.getDash(To.from,na);rs&&is&&Fa.setConstantPatternPositions(rs,is)}const Eo=Ee.terrain?_i.projMatrix:null,So=ri?Uc(Ee,Fi,se,Sr,Eo,Tn):Hl(Ee,Fi,se,Sr,Eo,Ta.lineClipsArray.length,Tn);if(Zr){const Za=Ta.gradients[se.id];let rs=Za.texture;if(se.gradientVersion!==Za.version){let is=256;if(se.stepInterpolant){const hs=w.getSource().maxzoom,ps=_i.canonical.z===hs?Math.ceil(1<<Ee.transform.maxZoom-_i.canonical.z):1;is=m.clamp(m.nextPowerOfTwo(Ta.maxLineLength/m.EXTENT*1024*ps),256,di.maxTextureSize)}Za.gradient=m.renderColorRamp({expression:se.gradientExpression(),evaluationKey:"lineProgress",resolution:is,image:Za.gradient||void 0,clips:Ta.lineClipsArray}),Za.texture?Za.texture.update(Za.gradient):Za.texture=new m.Texture(di,Za.gradient,wi.RGBA),Za.version=se.gradientVersion,rs=Za.texture}di.activeTexture.set(wi.TEXTURE1),rs.bind(se.stepInterpolant?wi.NEAREST:wi.LINEAR,wi.CLAMP_TO_EDGE)}Bn&&(di.activeTexture.set(wi.TEXTURE0),Fi.lineAtlasTexture.bind(wi.LINEAR,wi.REPEAT),Fa.updatePaintBuffers(Sr)),ri&&(di.activeTexture.set(wi.TEXTURE0),Fi.imageAtlasTexture.bind(wi.LINEAR,wi.CLAMP_TO_EDGE),Fa.updatePaintBuffers(Sr)),Ee.prepareDrawProgram(di,qa,_i.toUnwrapped());const Qo=Za=>{qa.draw(di,wi.TRIANGLES,Ot,Za,rn,m.CullFaceMode.disabled,So,se.id,Ta.layoutVertexBuffer,Ta.indexBuffer,Ta.segments,se.paint,Ee.transform.zoom,Fa,Ta.layoutVertexBuffer2)};if(Oi){const Za=Ee.stencilModeForClipping(_i).ref;Za===0&&Ee.terrain&&di.clear({stencil:0});const rs={func:wi.EQUAL,mask:255};So.u_alpha_discard_threshold=.8,Qo(new m.StencilMode(rs,Za,255,wi.KEEP,wi.KEEP,wi.INVERT)),So.u_alpha_discard_threshold=0,Qo(new m.StencilMode(rs,Za,255,wi.KEEP,wi.KEEP,wi.KEEP))}else Qo(Ee.stencilModeForClipping(_i))}Oi&&(Ee.resetStencilClippingMasks(),Ee.terrain&&di.clear({stencil:0}))},fill:function(Ee,w,se,it){const xt=se.paint.get("fill-color"),Dt=se.paint.get("fill-opacity");if(Dt.constantOr(1)===0)return;const Ot=Ee.colorModeForRenderPass(),rn=se.paint.get("fill-pattern"),Tn=Ee.opaquePassEnabledForLayer()&&!rn.constantOr(1)&&xt.constantOr(m.Color.transparent).a===1&&Dt.constantOr(0)===1?"opaque":"translucent";if(Ee.renderPass===Tn){const kn=Ee.depthModeForSublayer(1,Ee.renderPass==="opaque"?m.DepthMode.ReadWrite:m.DepthMode.ReadOnly);Jo(Ee,w,se,it,kn,Ot,!1)}if(Ee.renderPass==="translucent"&&se.paint.get("fill-antialias")){const kn=Ee.depthModeForSublayer(se.getPaintProperty("fill-outline-color")?2:0,m.DepthMode.ReadOnly);Jo(Ee,w,se,it,kn,Ot,!0)}},"fill-extrusion":function(Ee,w,se,it){const xt=se.paint.get("fill-extrusion-opacity");if(xt!==0&&Ee.renderPass==="translucent"){const Dt=new m.DepthMode(Ee.context.gl.LEQUAL,m.DepthMode.ReadWrite,Ee.depthRangeFor3D);if(xt!==1||se.paint.get("fill-extrusion-pattern").constantOr(1))Xo(Ee,w,se,it,Dt,m.StencilMode.disabled,m.ColorMode.disabled),Xo(Ee,w,se,it,Dt,Ee.stencilModeFor3D(),Ee.colorModeForRenderPass()),Ee.resetStencilClippingMasks();else{const Ot=Ee.colorModeForRenderPass();Xo(Ee,w,se,it,Dt,m.StencilMode.disabled,Ot)}}},hillshade:function(Ee,w,se,it){if(Ee.renderPass!=="offscreen"&&Ee.renderPass!=="translucent")return;const xt=Ee.context,Dt=Ee.depthModeForSublayer(0,m.DepthMode.ReadOnly),Ot=Ee.colorModeForRenderPass(),rn=Ee.terrain&&Ee.terrain.renderingToTexture,[Tn,kn]=Ee.renderPass!=="translucent"||rn?[{},it]:Ee.stencilConfigForOverlap(it);for(const Bn of kn){const Wn=w.getTile(Bn);if(Wn.needsHillshadePrepare&&Ee.renderPass==="offscreen")yn(Ee,Wn,se,Dt,m.StencilMode.disabled,Ot);else if(Ee.renderPass==="translucent"){const Fr=rn&&Ee.terrain?Ee.terrain.stencilModeForRTTOverlap(Bn):Tn[Bn.overscaledZ];jt(Ee,Bn,Wn,se,Dt,Fr,Ot)}}xt.viewport.set([0,0,Ee.width,Ee.height]),Ee.resetStencilClippingMasks()},raster:function(Ee,w,se,it,xt,Dt){if(Ee.renderPass!=="translucent"||se.paint.get("raster-opacity")===0||!it.length)return;const Ot=Ee.context,rn=Ot.gl,Tn=w.getSource(),kn=Ee.useProgram("raster"),Bn=Ee.colorModeForRenderPass(),Wn=Ee.terrain&&Ee.terrain.renderingToTexture,[Fr,ri]=Tn instanceof Ei||Wn?[{},it]:Ee.stencilConfigForOverlap(it),Zr=ri[ri.length-1].overscaledZ,Sr=!Ee.options.moving;for(const Di of ri){const di=Wn?m.DepthMode.disabled:Ee.depthModeForSublayer(Di.overscaledZ-Zr,se.paint.get("raster-opacity")===1?m.DepthMode.ReadWrite:m.DepthMode.ReadOnly,rn.LESS),wi=Di.toUnwrapped(),Ti=w.getTile(Di);if(Wn&&(!Ti||!Ti.hasData()))continue;const Oi=Wn?Di.projMatrix:Ee.transform.calculateProjMatrix(wi,Sr),_i=Ee.terrain&&Wn?Ee.terrain.stencilModeForRTTOverlap(Di):Fr[Di.overscaledZ],Fi=Dt?0:se.paint.get("raster-fade-duration");Ti.registerFadeDuration(Fi);const Ta=w.findLoadedParent(Di,0),Fa=ts(Ti,Ta,w,Ee.transform,Fi);let qa,ja;Ee.terrain&&Ee.terrain.prepareDrawTile();const To=se.paint.get("raster-resampling")==="nearest"?rn.NEAREST:rn.LINEAR;Ot.activeTexture.set(rn.TEXTURE0),Ti.texture.bind(To,rn.CLAMP_TO_EDGE),Ot.activeTexture.set(rn.TEXTURE1),Ta?(Ta.texture.bind(To,rn.CLAMP_TO_EDGE),qa=Math.pow(2,Ta.tileID.overscaledZ-Ti.tileID.overscaledZ),ja=[Ti.tileID.canonical.x*qa%1,Ti.tileID.canonical.y*qa%1]):Ti.texture.bind(To,rn.CLAMP_TO_EDGE);const na=oc(Oi,ja||[0,0],qa||1,Fa,se,Tn instanceof Ei?Tn.perspectiveTransform:[0,0]);if(Ee.prepareDrawProgram(Ot,kn,wi),Tn instanceof Ei)Tn.boundsBuffer&&Tn.boundsSegments&&kn.draw(Ot,rn.TRIANGLES,di,m.StencilMode.disabled,Bn,m.CullFaceMode.disabled,na,se.id,Tn.boundsBuffer,Ee.quadTriangleIndexBuffer,Tn.boundsSegments);else{const{tileBoundsBuffer:Eo,tileBoundsIndexBuffer:So,tileBoundsSegments:Qo}=Ee.getTileBoundsBuffers(Ti);kn.draw(Ot,rn.TRIANGLES,di,_i,Bn,m.CullFaceMode.disabled,na,se.id,Eo,So,Qo)}}Ee.resetStencilClippingMasks()},background:function(Ee,w,se,it){const xt=se.paint.get("background-color"),Dt=se.paint.get("background-opacity");if(Dt===0)return;const Ot=Ee.context,rn=Ot.gl,Tn=Ee.transform,kn=Tn.tileSize,Bn=se.paint.get("background-pattern");if(Ee.isPatternMissing(Bn))return;const Wn=!Bn&&xt.a===1&&Dt===1&&Ee.opaquePassEnabledForLayer()?"opaque":"translucent";if(Ee.renderPass!==Wn)return;const Fr=m.StencilMode.disabled,ri=Ee.depthModeForSublayer(0,Wn==="opaque"?m.DepthMode.ReadWrite:m.DepthMode.ReadOnly),Zr=Ee.colorModeForRenderPass(),Sr=Ee.useProgram(Bn?"backgroundPattern":"background");let Di,di=it;di||(Di=Ee.getBackgroundTiles(),di=Object.values(Di).map(Ti=>Ti.tileID)),Bn&&(Ot.activeTexture.set(rn.TEXTURE0),Ee.imageManager.bind(Ee.context));const wi=se.getCrossfadeParameters();for(const Ti of di){const Oi=Ti.toUnwrapped(),_i=it?Ti.projMatrix:Ee.transform.calculateProjMatrix(Oi);Ee.prepareDrawTile();const Fi=w?w.getTile(Ti):Di?Di[Ti.key]:new m.Tile(Ti,kn,Tn.zoom,Ee),Ta=Bn?Pu(_i,Dt,Ee,Bn,{tileID:Ti,tileSize:kn},wi):vd(_i,Dt,xt);Ee.prepareDrawProgram(Ot,Sr,Oi);const{tileBoundsBuffer:Fa,tileBoundsIndexBuffer:qa,tileBoundsSegments:ja}=Ee.getTileBoundsBuffers(Fi);Sr.draw(Ot,rn.TRIANGLES,ri,Fr,Zr,m.CullFaceMode.disabled,Ta,se.id,Fa,qa,ja)}},sky:function(Ee,w,se){const it=Ee.transform,xt=it.projection.name==="mercator"||it.projection.name==="globe"?1:m.smoothstep(7,8,it.zoom),Dt=se.paint.get("sky-opacity")*xt;if(Dt===0)return;const Ot=Ee.context,rn=se.paint.get("sky-type"),Tn=new m.DepthMode(Ot.gl.LEQUAL,m.DepthMode.ReadOnly,[0,1]),kn=Ee.frameCounter/1e3%1;rn==="atmosphere"?Ee.renderPass==="offscreen"?se.needsSkyboxCapture(Ee)&&(function(Bn,Wn,Fr,ri){const Zr=Bn.context,Sr=Zr.gl;let Di=Wn.skyboxFbo;if(!Di){Di=Wn.skyboxFbo=Zr.createFramebuffer(32,32,!1),Wn.skyboxGeometry=new Fo(Zr),Wn.skyboxTexture=Zr.gl.createTexture(),Sr.bindTexture(Sr.TEXTURE_CUBE_MAP,Wn.skyboxTexture),Sr.texParameteri(Sr.TEXTURE_CUBE_MAP,Sr.TEXTURE_WRAP_S,Sr.CLAMP_TO_EDGE),Sr.texParameteri(Sr.TEXTURE_CUBE_MAP,Sr.TEXTURE_WRAP_T,Sr.CLAMP_TO_EDGE),Sr.texParameteri(Sr.TEXTURE_CUBE_MAP,Sr.TEXTURE_MIN_FILTER,Sr.LINEAR),Sr.texParameteri(Sr.TEXTURE_CUBE_MAP,Sr.TEXTURE_MAG_FILTER,Sr.LINEAR);for(let Oi=0;Oi<6;++Oi)Sr.texImage2D(Sr.TEXTURE_CUBE_MAP_POSITIVE_X+Oi,0,Sr.RGBA,32,32,0,Sr.RGBA,Sr.UNSIGNED_BYTE,null)}Zr.bindFramebuffer.set(Di.framebuffer),Zr.viewport.set([0,0,32,32]);const di=Wn.getCenter(Bn,!0),wi=Bn.useProgram("skyboxCapture"),Ti=new Float64Array(16);m.identity(Ti),m.rotateY(Ti,Ti,.5*-Math.PI),vs(Zr,Wn,wi,Ti,di,0),m.identity(Ti),m.rotateY(Ti,Ti,.5*Math.PI),vs(Zr,Wn,wi,Ti,di,1),m.identity(Ti),m.rotateX(Ti,Ti,.5*-Math.PI),vs(Zr,Wn,wi,Ti,di,2),m.identity(Ti),m.rotateX(Ti,Ti,.5*Math.PI),vs(Zr,Wn,wi,Ti,di,3),m.identity(Ti),vs(Zr,Wn,wi,Ti,di,4),m.identity(Ti),m.rotateY(Ti,Ti,Math.PI),vs(Zr,Wn,wi,Ti,di,5),Zr.viewport.set([0,0,Bn.width,Bn.height])}(Ee,se),se.markSkyboxValid(Ee)):Ee.renderPass==="sky"&&function(Bn,Wn,Fr,ri,Zr){const Sr=Bn.context,Di=Sr.gl,di=Bn.transform,wi=Bn.useProgram("skybox");Sr.activeTexture.set(Di.TEXTURE0),Di.bindTexture(Di.TEXTURE_CUBE_MAP,Wn.skyboxTexture);const Ti=((Oi,_i,Fi,Ta,Fa)=>({u_matrix:Oi,u_sun_direction:_i,u_cubemap:0,u_opacity:Ta,u_temporal_offset:Fa}))(di.skyboxMatrix,Wn.getCenter(Bn,!1),0,ri,Zr);Bn.prepareDrawProgram(Sr,wi),wi.draw(Sr,Di.TRIANGLES,Fr,m.StencilMode.disabled,Bn.colorModeForRenderPass(),m.CullFaceMode.backCW,Ti,"skybox",Wn.skyboxGeometry.vertexBuffer,Wn.skyboxGeometry.indexBuffer,Wn.skyboxGeometry.segment)}(Ee,se,Tn,Dt,kn):rn==="gradient"&&Ee.renderPass==="sky"&&function(Bn,Wn,Fr,ri,Zr){const Sr=Bn.context,Di=Sr.gl,di=Bn.transform,wi=Bn.useProgram("skyboxGradient");Wn.skyboxGeometry||(Wn.skyboxGeometry=new Fo(Sr)),Sr.activeTexture.set(Di.TEXTURE0);let Ti=Wn.colorRampTexture;Ti||(Ti=Wn.colorRampTexture=new m.Texture(Sr,Wn.colorRamp,Di.RGBA)),Ti.bind(Di.LINEAR,Di.CLAMP_TO_EDGE);const Oi=((_i,Fi,Ta,Fa,qa)=>({u_matrix:_i,u_color_ramp:0,u_center_direction:Fi,u_radius:m.degToRad(Ta),u_opacity:Fa,u_temporal_offset:qa}))(di.skyboxMatrix,Wn.getCenter(Bn,!1),Wn.paint.get("sky-gradient-radius"),ri,Zr);Bn.prepareDrawProgram(Sr,wi),wi.draw(Sr,Di.TRIANGLES,Fr,m.StencilMode.disabled,Bn.colorModeForRenderPass(),m.CullFaceMode.backCW,Oi,"skyboxGradient",Wn.skyboxGeometry.vertexBuffer,Wn.skyboxGeometry.indexBuffer,Wn.skyboxGeometry.segment)}(Ee,se,Tn,Dt,kn)},debug:function(Ee,w,se){for(let it=0;it<se.length;it++)Ws(Ee,w,se[it])},custom:function(Ee,w,se){const it=Ee.context,xt=se.implementation;if(Ee.transform.projection.unsupportedLayers&&Ee.transform.projection.unsupportedLayers.includes("custom"))m.warnOnce("Custom layers are not yet supported with non-mercator projections. Use mercator to enable custom layers.");else if(Ee.renderPass==="offscreen"){const Dt=xt.prerender;Dt&&(Ee.setCustomLayerDefaults(),it.setColorMode(Ee.colorModeForRenderPass()),Dt.call(xt,it.gl,Ee.transform.customLayerMatrix()),it.setDirty(),Ee.setBaseState())}else if(Ee.renderPass==="translucent"){Ee.setCustomLayerDefaults(),it.setColorMode(Ee.colorModeForRenderPass()),it.setStencilMode(m.StencilMode.disabled);const Dt=xt.renderingMode==="3d"?new m.DepthMode(Ee.context.gl.LEQUAL,m.DepthMode.ReadWrite,Ee.depthRangeFor3D):Ee.depthModeForSublayer(0,m.DepthMode.ReadOnly);it.setDepthMode(Dt),xt.render(it.gl,Ee.transform.customLayerMatrix()),it.setDirty(),Ee.setBaseState(),it.bindFramebuffer.set(null)}}};class gu{constructor(w,se){this.context=new zn(w),this.transform=se,this._tileTextures={},this.frameCopies=[],this.loadTimeStamps=[],this.setup(),this.numSublayers=m.SourceCache.maxUnderzooming+m.SourceCache.maxOverzooming+1,this.depthEpsilon=1/Math.pow(2,16),this.crossTileSymbolIndex=new mc,this.gpuTimers={},this.frameCounter=0,this._backgroundTiles={},this._tileClippingMaskIDs=new Map,this._skippedStencilTileIDs=new Set}updateTerrain(w,se){const it=!!w&&!!w.terrain&&this.transform.projection.supportsTerrain;if(!(it||this._terrain&&this._terrain.enabled))return;this._terrain||(this._terrain=new Gs(this,w));const xt=this._terrain;this.transform.elevation=it?xt:null,xt.update(w,this.transform,se)}_updateFog(w){const se=w.fog;if(!se||se.getOpacity(this.transform.pitch)<1||se.properties.get("horizon-blend")<.03)return void(this.transform.fogCullDistSq=null);const[it,xt]=se.getFovAdjustedRange(this.transform._fov);if(it>xt)return void(this.transform.fogCullDistSq=null);const Dt=it+.78*(xt-it);this.transform.fogCullDistSq=Dt*Dt}get terrain(){return this.transform._terrainEnabled()&&this._terrain&&this._terrain.enabled?this._terrain:null}resize(w,se){if(this.width=w*m.exported.devicePixelRatio,this.height=se*m.exported.devicePixelRatio,this.context.viewport.set([0,0,this.width,this.height]),this.style)for(const it of this.style.order)this.style._layers[it].resize()}setup(){const w=this.context,se=new m.StructArrayLayout2i4;se.emplaceBack(0,0),se.emplaceBack(m.EXTENT,0),se.emplaceBack(0,m.EXTENT),se.emplaceBack(m.EXTENT,m.EXTENT),this.tileExtentBuffer=w.createVertexBuffer(se,m.posAttributes.members),this.tileExtentSegments=m.SegmentVector.simpleSegment(0,0,4,2);const it=new m.StructArrayLayout2i4;it.emplaceBack(0,0),it.emplaceBack(m.EXTENT,0),it.emplaceBack(0,m.EXTENT),it.emplaceBack(m.EXTENT,m.EXTENT),this.debugBuffer=w.createVertexBuffer(it,m.posAttributes.members),this.debugSegments=m.SegmentVector.simpleSegment(0,0,4,5);const xt=new m.StructArrayLayout2i4;xt.emplaceBack(-1,-1),xt.emplaceBack(1,-1),xt.emplaceBack(-1,1),xt.emplaceBack(1,1),this.viewportBuffer=w.createVertexBuffer(xt,m.posAttributes.members),this.viewportSegments=m.SegmentVector.simpleSegment(0,0,4,2);const Dt=new m.StructArrayLayout4i8;Dt.emplaceBack(0,0,0,0),Dt.emplaceBack(m.EXTENT,0,m.EXTENT,0),Dt.emplaceBack(0,m.EXTENT,0,m.EXTENT),Dt.emplaceBack(m.EXTENT,m.EXTENT,m.EXTENT,m.EXTENT),this.mercatorBoundsBuffer=w.createVertexBuffer(Dt,m.boundsAttributes.members),this.mercatorBoundsSegments=m.SegmentVector.simpleSegment(0,0,4,2);const Ot=new m.StructArrayLayout3ui6;Ot.emplaceBack(0,1,2),Ot.emplaceBack(2,1,3),this.quadTriangleIndexBuffer=w.createIndexBuffer(Ot);const rn=new m.StructArrayLayout1ui2;for(const kn of[0,1,3,2,0])rn.emplaceBack(kn);this.debugIndexBuffer=w.createIndexBuffer(rn),this.emptyTexture=new m.Texture(w,new m.RGBAImage({width:1,height:1},Uint8Array.of(0,0,0,0)),w.gl.RGBA),this.identityMat=m.create();const Tn=this.context.gl;this.stencilClearMode=new m.StencilMode({func:Tn.ALWAYS,mask:0},0,255,Tn.ZERO,Tn.ZERO,Tn.ZERO),this.loadTimeStamps.push(m.window.performance.now())}getMercatorTileBoundsBuffers(){return{tileBoundsBuffer:this.mercatorBoundsBuffer,tileBoundsIndexBuffer:this.quadTriangleIndexBuffer,tileBoundsSegments:this.mercatorBoundsSegments}}getTileBoundsBuffers(w){return w._makeTileBoundsBuffers(this.context,this.transform.projection),w._tileBoundsBuffer?{tileBoundsBuffer:w._tileBoundsBuffer,tileBoundsIndexBuffer:w._tileBoundsIndexBuffer,tileBoundsSegments:w._tileBoundsSegments}:this.getMercatorTileBoundsBuffers()}clearStencil(){const w=this.context,se=w.gl;this.nextStencilID=1,this.currentStencilSource=void 0,this._tileClippingMaskIDs.clear(),this._skippedStencilTileIDs.clear(),this.useProgram("clippingMask").draw(w,se.TRIANGLES,m.DepthMode.disabled,this.stencilClearMode,m.ColorMode.disabled,m.CullFaceMode.disabled,oo(this.identityMat),"$clipping",this.viewportBuffer,this.quadTriangleIndexBuffer,this.viewportSegments)}resetStencilClippingMasks(){this.terrain||(this.currentStencilSource=void 0,this._tileClippingMaskIDs.clear(),this._skippedStencilTileIDs.clear())}_renderTileClippingMasks(w,se,it){if(!se||this.currentStencilSource===se.id||!w.isTileClipped()||!it||it.length===0)return;const xt=[];let Dt=!1;if(this._tileClippingMaskIDs&&!this.terrain){for(const Bn of it)if(this._tileClippingMaskIDs.has(Bn.key)||(Dt=!0),this._skippedStencilTileIDs.has(Bn.key)){if(!se.getTile(Bn).getBucket(w))continue;this._skippedStencilTileIDs.delete(Bn.key),xt.push(Bn)}if(!Dt&&xt.length===0)return}const Ot=this.context,rn=Ot.gl;Ot.setColorMode(m.ColorMode.disabled),Ot.setDepthMode(m.DepthMode.disabled);const Tn=this.useProgram("clippingMask"),kn=Bn=>{const Wn=se.getTile(Bn),{tileBoundsBuffer:Fr,tileBoundsIndexBuffer:ri,tileBoundsSegments:Zr}=this.getTileBoundsBuffers(Wn);Tn.draw(Ot,rn.TRIANGLES,m.DepthMode.disabled,new m.StencilMode({func:rn.GREATER,mask:255},this._tileClippingMaskIDs.get(Bn.key)||0,255,rn.KEEP,rn.KEEP,rn.REPLACE),m.ColorMode.disabled,m.CullFaceMode.disabled,oo(Bn.projMatrix),"$clipping",Fr,ri,Zr)};if(!Dt&&xt.length>0)for(const Bn of xt)kn(Bn);else{(this._tileClippingMaskIDs.size===0||this.nextStencilID+it.length>256)&&this.clearStencil(),this._tileClippingMaskIDs.clear(),this._skippedStencilTileIDs.clear();for(const Bn of it)this._tileClippingMaskIDs.set(Bn.key,this.nextStencilID++),se.getTile(Bn).getBucket(w)?kn(Bn):this._skippedStencilTileIDs.add(Bn.key)}this._skippedStencilTileIDs.size===0&&(this.currentStencilSource=se.id)}stencilModeFor3D(){this.currentStencilSource=void 0,this.nextStencilID+1>256&&this.clearStencil();const w=this.nextStencilID++,se=this.context.gl;return new m.StencilMode({func:se.NOTEQUAL,mask:255},w,255,se.KEEP,se.KEEP,se.REPLACE)}stencilModeForClipping(w){if(this.terrain)return this.terrain.stencilModeForRTTOverlap(w);const se=this.context.gl;return new m.StencilMode({func:se.EQUAL,mask:255},this._tileClippingMaskIDs.get(w.key)||0,0,se.KEEP,se.KEEP,se.REPLACE)}stencilConfigForOverlap(w){const se=this.context.gl,it=w.sort((Ot,rn)=>rn.overscaledZ-Ot.overscaledZ),xt=it[it.length-1].overscaledZ,Dt=it[0].overscaledZ-xt+1;if(Dt>1){this.currentStencilSource=void 0,this.nextStencilID+Dt>256&&this.clearStencil();const Ot={};for(let rn=0;rn<Dt;rn++)Ot[rn+xt]=new m.StencilMode({func:se.GEQUAL,mask:255},rn+this.nextStencilID,255,se.KEEP,se.KEEP,se.REPLACE);return this.nextStencilID+=Dt,[Ot,it]}return[{[xt]:m.StencilMode.disabled},it]}colorModeForRenderPass(){const w=this.context.gl;return this._showOverdrawInspector?new m.ColorMode([w.CONSTANT_COLOR,w.ONE],new m.Color(.125,.125,.125,0),[!0,!0,!0,!0]):this.renderPass==="opaque"?m.ColorMode.unblended:m.ColorMode.alphaBlended}depthModeForSublayer(w,se,it){if(!this.opaquePassEnabledForLayer())return m.DepthMode.disabled;const xt=1-((1+this.currentLayer)*this.numSublayers+w)*this.depthEpsilon;return new m.DepthMode(it||this.context.gl.LEQUAL,se,[xt,xt])}opaquePassEnabledForLayer(){return this.currentLayer<this.opaquePassCutoff}render(w,se){this.style=w,this.options=se,this.lineAtlas=w.lineAtlas,this.imageManager=w.imageManager,this.glyphManager=w.glyphManager,this.symbolFadeChange=w.placement.symbolFadeChange(m.exported.now()),this.imageManager.beginFrame();const it=this.style.order,xt=this.style._sourceCaches;for(const kn in xt){const Bn=xt[kn];Bn.used&&Bn.prepare(this.context)}const Dt={},Ot={},rn={};for(const kn in xt){const Bn=xt[kn];Dt[kn]=Bn.getVisibleCoordinates(),Ot[kn]=Dt[kn].slice().reverse(),rn[kn]=Bn.getVisibleCoordinates(!0).reverse()}this.opaquePassCutoff=1/0;for(let kn=0;kn<it.length;kn++)if(this.style._layers[it[kn]].is3D()){this.opaquePassCutoff=kn;break}if(this.terrain&&(this.terrain.updateTileBinding(rn),this.opaquePassCutoff=0),this.transform.projection.name!=="globe"||this.globeSharedBuffers||(this.globeSharedBuffers=new m.GlobeSharedBuffers(this.context)),!m.isMapAuthenticated(this.context.gl))return;this.renderPass="offscreen";for(const kn of it){const Bn=this.style._layers[kn],Wn=w._getLayerSourceCache(Bn);if(!Bn.hasOffscreenPass()||Bn.isHidden(this.transform.zoom))continue;const Fr=Wn?Ot[Wn.id]:void 0;(Bn.type==="custom"||Bn.isSky()||Fr&&Fr.length)&&this.renderLayer(this,Wn,Bn,Fr)}this.depthRangeFor3D=[0,1-(w.order.length+2)*this.numSublayers*this.depthEpsilon],this.terrain&&(this.style.hasSymbolLayers()||this.style.hasCircleLayers())&&this.terrain.drawDepth(),this.context.bindFramebuffer.set(null),this.context.viewport.set([0,0,this.width,this.height]);let Tn=m.Color.transparent;if(this.style.fog&&this.style.fog.getOpacity(this.transform.pitch)&&(Tn=this.style.fog.properties.get("color")),this.context.clear({color:se.showOverdrawInspector?m.Color.black:Tn,depth:1}),this.clearStencil(),this._showOverdrawInspector=se.showOverdrawInspector,this.renderPass="opaque",!this.terrain)for(this.currentLayer=it.length-1;this.currentLayer>=0;this.currentLayer--){const kn=this.style._layers[it[this.currentLayer]],Bn=w._getLayerSourceCache(kn);if(kn.isSky())continue;const Wn=Bn?Ot[Bn.id]:void 0;this._renderTileClippingMasks(kn,Bn,Wn),this.renderLayer(this,Bn,kn,Wn)}if(this.renderPass="sky",(m.globeToMercatorTransition(this.transform.zoom)>0||this.transform.projection.name!=="globe")&&this.transform.isHorizonVisible())for(this.currentLayer=0;this.currentLayer<it.length;this.currentLayer++){const kn=this.style._layers[it[this.currentLayer]],Bn=w._getLayerSourceCache(kn);kn.isSky()&&this.renderLayer(this,Bn,kn,Bn?Ot[Bn.id]:void 0)}for(this.transform.projection.name==="globe"&&function(kn){const Bn=kn.context,Wn=Bn.gl,Fr=kn.transform,ri=new m.DepthMode(Wn.LEQUAL,m.DepthMode.ReadOnly,[0,1]),Zr=kn.useProgram("globeAtmosphere"),Sr=Fr.centerOffset,Di=Fr._camera.getCameraToClipPerspective(Fr._fov,Fr.width/Fr.height,Fr._nearZ,Fr._farZ);Di[8]=2*-Sr.x/Fr.width,Di[9]=2*Sr.y/Fr.height;const di=m.invert([],Di),wi=m.mul([],di,Fr.projMatrix),Ti={u_frustum_tl:Gl([-1,1,1],di),u_frustum_tr:Gl([1,1,1],di),u_frustum_br:Gl([1,-1,1],di),u_frustum_bl:Gl([-1,-1,1],di),u_globe_pos:Gl([Fr.globeMatrix[12],Fr.globeMatrix[13],Fr.globeMatrix[14]],wi),u_globe_radius:Fr.worldSize/2/Math.PI-1,u_opacity:1-m.globeToMercatorTransition(Fr.zoom),u_fadeout_range:2,u_start_color:[1,1,1],u_end_color:[.0118,.7451,.9882]};kn.prepareDrawProgram(Bn,Zr);const Oi=kn.globeSharedBuffers;Oi&&Zr.draw(Bn,Wn.TRIANGLES,ri,m.StencilMode.disabled,m.ColorMode.alphaBlended,m.CullFaceMode.backCW,Ti,"skybox",Oi.atmosphereVertexBuffer,Oi.atmosphereIndexBuffer,Oi.atmosphereSegments)}(this),this.renderPass="translucent",this.currentLayer=0;this.currentLayer<it.length;){const kn=this.style._layers[it[this.currentLayer]],Bn=w._getLayerSourceCache(kn);if(kn.isSky()){++this.currentLayer;continue}if(this.terrain&&this.style.isLayerDraped(kn)){if(kn.isHidden(this.transform.zoom)){++this.currentLayer;continue}this.currentLayer=this.terrain.renderBatch(this.currentLayer);continue}const Wn=Bn?(kn.type==="symbol"?rn:Ot)[Bn.id]:void 0;this._renderTileClippingMasks(kn,Bn,Bn?Dt[Bn.id]:void 0),this.renderLayer(this,Bn,kn,Wn),++this.currentLayer}if(this.terrain&&this.terrain.postRender(),this.options.showTileBoundaries||this.options.showQueryGeometry){let kn=null;m.values(this.style._layers).forEach(Bn=>{const Wn=w._getLayerSourceCache(Bn);Wn&&!Bn.isHidden(this.transform.zoom)&&(!kn||kn.getSource().maxzoom<Wn.getSource().maxzoom)&&(kn=Wn)}),kn&&this.options.showTileBoundaries&&Mu.debug(this,kn,kn.getVisibleCoordinates())}this.options.showPadding&&function(kn){const Bn=kn.transform.padding;ya(kn,kn.transform.height-(Bn.top||0),3,ii),ya(kn,Bn.bottom||0,3,Ma),Oo(kn,Bn.left||0,3,pa),Oo(kn,kn.transform.width-(Bn.right||0),3,ca);const Wn=kn.transform.centerPoint;(function(Fr,ri,Zr,Sr){Io(Fr,ri-1,Zr-10,2,20,Sr),Io(Fr,ri-10,Zr-1,20,2,Sr)})(kn,Wn.x,kn.transform.height-Wn.y,uo)}(this),this.context.setDefault(),this.frameCounter=(this.frameCounter+1)%Number.MAX_SAFE_INTEGER,this.tileLoaded&&this.options.speedIndexTiming&&(this.loadTimeStamps.push(m.window.performance.now()),this.saveCanvasCopy())}renderLayer(w,se,it,xt){it.isHidden(this.transform.zoom)||(it.type==="background"||it.type==="sky"||it.type==="custom"||xt&&xt.length)&&(this.id=it.id,this.gpuTimingStart(it),w.transform.projection.unsupportedLayers&&w.transform.projection.unsupportedLayers.includes(it.type)||Mu[it.type](w,se,it,xt,this.style.placement.variableOffsets,this.options.isInitialLoad),this.gpuTimingEnd())}gpuTimingStart(w){if(!this.options.gpuTiming)return;const se=this.context.extTimerQuery;let it=this.gpuTimers[w.id];it||(it=this.gpuTimers[w.id]={calls:0,cpuTime:0,query:se.createQueryEXT()}),it.calls++,se.beginQueryEXT(se.TIME_ELAPSED_EXT,it.query)}gpuTimingEnd(){if(!this.options.gpuTiming)return;const w=this.context.extTimerQuery;w.endQueryEXT(w.TIME_ELAPSED_EXT)}collectGpuTimers(){const w=this.gpuTimers;return this.gpuTimers={},w}queryGpuTimers(w){const se={};for(const it in w){const xt=w[it],Dt=this.context.extTimerQuery,Ot=Dt.getQueryObjectEXT(xt.query,Dt.QUERY_RESULT_EXT)/1e6;Dt.deleteQueryEXT(xt.query),se[it]=Ot}return se}translatePosMatrix(w,se,it,xt,Dt){if(!it[0]&&!it[1])return w;const Ot=Dt?xt==="map"?this.transform.angle:0:xt==="viewport"?-this.transform.angle:0;if(Ot){const kn=Math.sin(Ot),Bn=Math.cos(Ot);it=[it[0]*Bn-it[1]*kn,it[0]*kn+it[1]*Bn]}const rn=[Dt?it[0]:hn(se,it[0],this.transform.zoom),Dt?it[1]:hn(se,it[1],this.transform.zoom),0],Tn=new Float32Array(16);return m.translate(Tn,w,rn),Tn}saveTileTexture(w){const se=this._tileTextures[w.size[0]];se?se.push(w):this._tileTextures[w.size[0]]=[w]}getTileTexture(w){const se=this._tileTextures[w];return se&&se.length>0?se.pop():null}isPatternMissing(w){if(!w)return!1;if(!w.from||!w.to)return!0;const se=this.imageManager.getPattern(w.from.toString()),it=this.imageManager.getPattern(w.to.toString());return!se||!it}currentGlobalDefines(){const w=this.terrain&&this.terrain.renderingToTexture,se=this.style&&this.style.fog,it=[];return this.terrain&&!this.terrain.renderingToTexture&&it.push("TERRAIN"),se&&!w&&se.getOpacity(this.transform.pitch)!==0&&it.push("FOG"),w&&it.push("RENDER_TO_TEXTURE"),this._showOverdrawInspector&&it.push("OVERDRAW_INSPECTOR"),it}useProgram(w,se,it){this.cache=this.cache||{};const xt=it||[],Dt=this.currentGlobalDefines().concat(xt),Ot=yl.cacheKey(w,Dt,se);return this.cache[Ot]||(this.cache[Ot]=new yl(this.context,w,Pn[w],se,ol[w],Dt)),this.cache[Ot]}setCustomLayerDefaults(){this.context.unbindVAO(),this.context.cullFace.setDefault(),this.context.frontFace.setDefault(),this.context.cullFaceSide.setDefault(),this.context.activeTexture.setDefault(),this.context.pixelStoreUnpack.setDefault(),this.context.pixelStoreUnpackPremultiplyAlpha.setDefault(),this.context.pixelStoreUnpackFlipY.setDefault()}setBaseState(){const w=this.context.gl;this.context.cullFace.set(!1),this.context.viewport.set([0,0,this.width,this.height]),this.context.blendEquation.set(w.FUNC_ADD)}initDebugOverlayCanvas(){this.debugOverlayCanvas==null&&(this.debugOverlayCanvas=m.window.document.createElement("canvas"),this.debugOverlayCanvas.width=512,this.debugOverlayCanvas.height=512,this.debugOverlayTexture=new m.Texture(this.context,this.debugOverlayCanvas,this.context.gl.RGBA))}destroy(){this._terrain&&this._terrain.destroy(),this.globeSharedBuffers&&this.globeSharedBuffers.destroy(),this.emptyTexture.destroy(),this.debugOverlayTexture&&this.debugOverlayTexture.destroy()}prepareDrawTile(){this.terrain&&this.terrain.prepareDrawTile()}prepareDrawProgram(w,se,it){if(this.terrain&&this.terrain.renderingToTexture)return;const xt=this.style.fog;if(xt){const Dt=xt.getOpacity(this.transform.pitch);Dt!==0&&se.setFogUniformValues(w,((Ot,rn,Tn,kn)=>{const Bn=rn.properties.get("color"),Wn=Ot.frameCounter/1e3%1,Fr=[Bn.r/Bn.a,Bn.g/Bn.a,Bn.b/Bn.a,kn];return{u_fog_matrix:Tn?Ot.transform.calculateFogTileMatrix(Tn):Ot.identityMat,u_fog_range:rn.getFovAdjustedRange(Ot.transform._fov),u_fog_color:Fr,u_fog_horizon_blend:rn.properties.get("horizon-blend"),u_fog_temporal_offset:Wn}})(this,xt,it,Dt))}}setTileLoadedFlag(w){this.tileLoaded=w}saveCanvasCopy(){this.frameCopies.push(this.canvasCopy()),this.tileLoaded=!1}canvasCopy(){const w=this.context.gl,se=w.createTexture();return w.bindTexture(w.TEXTURE_2D,se),w.copyTexImage2D(w.TEXTURE_2D,0,w.RGBA,0,0,w.drawingBufferWidth,w.drawingBufferHeight,0),se}getCanvasCopiesAndTimestamps(){return{canvasCopies:this.frameCopies,timeStamps:this.loadTimeStamps}}averageElevationNeedsEasing(){if(!this.transform._elevation)return!1;const w=this.style&&this.style.fog;return!!w&&w.getOpacity(this.transform.pitch)!==0}getBackgroundTiles(){const w=this._backgroundTiles,se=this._backgroundTiles={},it=this.transform.coveringTiles({tileSize:512});for(const xt of it)se[xt.key]=w[xt.key]||new m.Tile(xt,512,this.transform.tileZoom,this);return se}clearBackgroundTiles(){this._backgroundTiles={}}}class Nu{constructor(w=0,se=0,it=0,xt=0){if(isNaN(w)||w<0||isNaN(se)||se<0||isNaN(it)||it<0||isNaN(xt)||xt<0)throw new Error("Invalid value for edge-insets, top, bottom, left and right must all be numbers");this.top=w,this.bottom=se,this.left=it,this.right=xt}interpolate(w,se,it){return se.top!=null&&w.top!=null&&(this.top=m.number(w.top,se.top,it)),se.bottom!=null&&w.bottom!=null&&(this.bottom=m.number(w.bottom,se.bottom,it)),se.left!=null&&w.left!=null&&(this.left=m.number(w.left,se.left,it)),se.right!=null&&w.right!=null&&(this.right=m.number(w.right,se.right,it)),this}getCenter(w,se){const it=m.clamp((this.left+w-this.right)/2,0,w),xt=m.clamp((this.top+se-this.bottom)/2,0,se);return new m.pointGeometry(it,xt)}equals(w){return this.top===w.top&&this.bottom===w.bottom&&this.left===w.left&&this.right===w.right}clone(){return new Nu(this.top,this.bottom,this.left,this.right)}toJSON(){return{top:this.top,bottom:this.bottom,left:this.left,right:this.right}}}function lc(Ee,w){const se=m.getColumn(Ee,3);m.fromQuat(Ee,w),m.setColumn(Ee,3,se)}function Du(Ee,w){const se=m.identity$1([]);return m.rotateZ$1(se,se,-w),m.rotateX$1(se,se,-Ee),se}function Zh(Ee,w){const se=[Ee[0],Ee[1],0],it=[w[0],w[1],0];if(m.length(se)>=1e-15){const Ot=m.normalize([],se);m.scale$2(it,Ot,m.dot(it,Ot)),w[0]=it[0],w[1]=it[1]}const xt=m.cross([],w,Ee);if(m.len(xt)<1e-15)return null;const Dt=Math.atan2(-xt[1],xt[0]);return Du(Math.atan2(Math.sqrt(Ee[0]*Ee[0]+Ee[1]*Ee[1]),-Ee[2]),Dt)}class uc{constructor(w,se){this.position=w,this.orientation=se}get position(){return this._position}set position(w){if(w){const se=w instanceof m.MercatorCoordinate?w:new m.MercatorCoordinate(w[0],w[1],w[2]);this._renderWorldCopies&&(se.x=m.wrap(se.x,0,1)),this._position=se}else this._position=null}lookAtPoint(w,se){if(this.orientation=null,!this.position)return;const it=this._elevation?this._elevation.getAtPointOrZero(m.MercatorCoordinate.fromLngLat(w)):0,xt=this.position,Dt=m.MercatorCoordinate.fromLngLat(w,it),Ot=[Dt.x-xt.x,Dt.y-xt.y,Dt.z-xt.z];se||(se=[0,0,1]),se[2]=Math.abs(se[2]),this.orientation=Zh(Ot,se)}setPitchBearing(w,se){this.orientation=Du(m.degToRad(w),m.degToRad(-se))}}class Ds{constructor(w,se){this._transform=m.identity([]),this.orientation=se,this.position=w}get mercatorPosition(){const w=this.position;return new m.MercatorCoordinate(w[0],w[1],w[2])}get position(){const w=m.getColumn(this._transform,3);return[w[0],w[1],w[2]]}set position(w){var se;w&&m.setColumn(this._transform,3,[(se=w)[0],se[1],se[2],1])}get orientation(){return this._orientation}set orientation(w){this._orientation=w||m.identity$1([]),w&&lc(this._transform,this._orientation)}getPitchBearing(){const w=this.forward(),se=this.right();return{bearing:Math.atan2(-se[1],se[0]),pitch:Math.atan2(Math.sqrt(w[0]*w[0]+w[1]*w[1]),-w[2])}}setPitchBearing(w,se){this._orientation=Du(w,se),lc(this._transform,this._orientation)}forward(){const w=m.getColumn(this._transform,2);return[-w[0],-w[1],-w[2]]}up(){const w=m.getColumn(this._transform,1);return[-w[0],-w[1],-w[2]]}right(){const w=m.getColumn(this._transform,0);return[w[0],w[1],w[2]]}getCameraToWorld(w,se){const it=new Float64Array(16);return m.invert(it,this.getWorldToCamera(w,se)),it}getWorldToCameraPosition(w,se,it){const xt=this.position;m.scale$2(xt,xt,-w);const Dt=new Float64Array(16);return m.fromScaling(Dt,[it,it,it]),m.translate(Dt,Dt,xt),Dt[10]*=se,Dt}getWorldToCamera(w,se){const it=new Float64Array(16),xt=new Float64Array(4),Dt=this.position;return m.conjugate(xt,this._orientation),m.scale$2(Dt,Dt,-w),m.fromQuat(it,xt),m.translate(it,it,Dt),it[1]*=-1,it[5]*=-1,it[9]*=-1,it[13]*=-1,it[8]*=se,it[9]*=se,it[10]*=se,it[11]*=se,it}getCameraToClipPerspective(w,se,it,xt){const Dt=new Float64Array(16);return m.perspective(Dt,w,se,it,xt),Dt}getDistanceToElevation(w){const se=w===0?0:m.mercatorZfromAltitude(w,this.position[1]),it=this.forward();return(se-this.position[2])/it[2]}clone(){return new Ds([...this.position],[...this.orientation])}}function Op(Ee,w){const se=up(Ee),it=function(Dt,Ot,rn,Tn,kn){const Bn=new m.LngLat(rn.lng-180*Fc,rn.lat),Wn=new m.LngLat(rn.lng+180*Fc,rn.lat),Fr=Dt.project(Bn.lng,Bn.lat),ri=Dt.project(Wn.lng,Wn.lat),Zr=-Math.atan2(ri.y-Fr.y,ri.x-Fr.x),Sr=m.MercatorCoordinate.fromLngLat(rn);Sr.y=m.clamp(Sr.y,-.999975,.999975);const Di=Sr.toLngLat(),di=Dt.project(Di.lng,Di.lat),wi=m.MercatorCoordinate.fromLngLat(Di);wi.x+=Fc;const Ti=wi.toLngLat(),Oi=Dt.project(Ti.lng,Ti.lat),_i=Rd(Oi.x-di.x,Oi.y-di.y,Zr),Fi=m.MercatorCoordinate.fromLngLat(Di);Fi.y+=Fc;const Ta=Fi.toLngLat(),Fa=Dt.project(Ta.lng,Ta.lat),qa=Rd(Fa.x-di.x,Fa.y-di.y,Zr),ja=Math.abs(_i.x)/Math.abs(qa.y),To=m.identity([]);m.rotateZ(To,To,-Zr*(1-(kn?0:Tn)));const na=m.identity([]);return m.scale(na,na,[1,1-(1-ja)*Tn,1]),na[4]=-qa.x/qa.y*Tn,m.rotateZ(na,na,Zr),m.multiply$1(na,To,na),na}(Ee.projection,0,Ee.center,se,w),xt=Kh(Ee);return m.scale(it,it,[xt,xt,1]),it}function Kh(Ee){const w=Ee.projection,se=up(Ee),it=fh(w,Ee.center),xt=fh(w,m.LngLat.convert(w.center));return Math.pow(2,it*se+(1-se)*xt)}function up(Ee){const w=Ee.projection.range;if(!w)return 0;const se=Math.max(Ee.width,Ee.height),it=Math.log(se/1024)/Math.LN2;return m.smoothstep(w[0]+it,w[1]+it,Ee.zoom)}const Fc=1/4e4;function fh(Ee,w){const se=m.clamp(w.lat,-m.MAX_MERCATOR_LATITUDE,m.MAX_MERCATOR_LATITUDE),it=new m.LngLat(w.lng-180*Fc,se),xt=new m.LngLat(w.lng+180*Fc,se),Dt=Ee.project(it.lng,se),Ot=Ee.project(xt.lng,se),rn=m.MercatorCoordinate.fromLngLat(it),Tn=m.MercatorCoordinate.fromLngLat(xt),kn=Ot.x-Dt.x,Bn=Ot.y-Dt.y,Wn=Tn.x-rn.x,Fr=Tn.y-rn.y,ri=Math.sqrt((Wn*Wn+Fr*Fr)/(kn*kn+Bn*Bn));return Math.log(ri)/Math.LN2}function Rd(Ee,w,se){const it=Math.cos(se),xt=Math.sin(se);return{x:Ee*it-w*xt,y:Ee*xt+w*it}}class hd{constructor(w,se,it,xt,Dt,Ot,rn){this.tileSize=512,this._renderWorldCopies=Dt===void 0||Dt,this._minZoom=w||0,this._maxZoom=se||22,this._minPitch=it??0,this._maxPitch=xt??60,this.setProjection(Ot),this.setMaxBounds(rn),this.width=0,this.height=0,this._center=new m.LngLat(0,0),this.zoom=0,this.angle=0,this._fov=.6435011087932844,this._pitch=0,this._nearZ=0,this._farZ=0,this._unmodified=!0,this._edgeInsets=new Nu,this._projMatrixCache={},this._alignedProjMatrixCache={},this._fogTileMatrixCache={},this._distanceTileDataCache={},this._camera=new Ds,this._centerAltitude=0,this._centerAltitudeValidForExaggeration=0,this._averageElevation=0,this.cameraElevationReference="ground",this._projectionScaler=1,this._horizonShift=.1}clone(){const w=new hd(this._minZoom,this._maxZoom,this._minPitch,this.maxPitch,this._renderWorldCopies,this.getProjection());return w._elevation=this._elevation,w._centerAltitude=this._centerAltitude,w._centerAltitudeValidForExaggeration=this._centerAltitudeValidForExaggeration,w.tileSize=this.tileSize,w.width=this.width,w.height=this.height,w.cameraElevationReference=this.cameraElevationReference,w._center=this._center,w._setZoom(this.zoom),w._seaLevelZoom=this._seaLevelZoom,w.angle=this.angle,w._fov=this._fov,w._pitch=this._pitch,w._nearZ=this._nearZ,w._farZ=this._farZ,w._averageElevation=this._averageElevation,w._unmodified=this._unmodified,w._edgeInsets=this._edgeInsets.clone(),w._camera=this._camera.clone(),w._calcMatrices(),w.freezeTileCoverage=this.freezeTileCoverage,w}get elevation(){return this._elevation}set elevation(w){this._elevation!==w&&(this._elevation=w,this._updateCameraOnTerrain(),this._calcMatrices())}updateElevation(w){const se=this._elevation&&this._elevation.exaggeration()!==this._centerAltitudeValidForExaggeration;(this._seaLevelZoom==null||se)&&this._updateCameraOnTerrain(),(w||se)&&this._constrainCameraAltitude(),this._calcMatrices()}getProjection(){return m.pick(this.projection,["name","center","parallels"])}setProjection(w){w==null&&(w={name:"mercator"}),this.projectionOptions=w;const se=this.projection?this.getProjection():void 0;this.projection=m.getProjection(w);const it=this.getProjection();return G(se,it)?null:(this._calcMatrices(),it)}get minZoom(){return this._minZoom}set minZoom(w){this._minZoom!==w&&(this._minZoom=w,this.zoom=Math.max(this.zoom,w))}get maxZoom(){return this._maxZoom}set maxZoom(w){this._maxZoom!==w&&(this._maxZoom=w,this.zoom=Math.min(this.zoom,w))}get minPitch(){return this._minPitch}set minPitch(w){this._minPitch!==w&&(this._minPitch=w,this.pitch=Math.max(this.pitch,w))}get maxPitch(){return this._maxPitch}set maxPitch(w){this._maxPitch!==w&&(this._maxPitch=w,this.pitch=Math.min(this.pitch,w))}get renderWorldCopies(){return this._renderWorldCopies&&this.projection.supportsWorldCopies===!0}set renderWorldCopies(w){w===void 0?w=!0:w===null&&(w=!1),this._renderWorldCopies=w}get worldSize(){return this.tileSize*this.scale}get cameraWorldSize(){const w=Math.max(this._camera.getDistanceToElevation(this._averageElevation),Number.EPSILON);return this._worldSizeFromZoom(this._zoomFromMercatorZ(w))}get pixelsPerMeter(){return this.projection.pixelsPerMeter(this.center.lat,this.worldSize)}get cameraPixelsPerMeter(){return this.projection.pixelsPerMeter(this.center.lat,this.cameraWorldSize)}get centerOffset(){return this.centerPoint._sub(this.size._div(2))}get size(){return new m.pointGeometry(this.width,this.height)}get bearing(){return m.wrap(this.rotation,-180,180)}set bearing(w){this.rotation=w}get rotation(){return-this.angle/Math.PI*180}set rotation(w){const se=-w*Math.PI/180;var it;this.angle!==se&&(this._unmodified=!1,this.angle=se,this._calcMatrices(),this.rotationMatrix=(it=new m.ARRAY_TYPE(4),m.ARRAY_TYPE!=Float32Array&&(it[1]=0,it[2]=0),it[0]=1,it[3]=1,it),function(xt,Dt,Ot){var rn=Dt[0],Tn=Dt[1],kn=Dt[2],Bn=Dt[3],Wn=Math.sin(Ot),Fr=Math.cos(Ot);xt[0]=rn*Fr+kn*Wn,xt[1]=Tn*Fr+Bn*Wn,xt[2]=rn*-Wn+kn*Fr,xt[3]=Tn*-Wn+Bn*Fr}(this.rotationMatrix,this.rotationMatrix,this.angle))}get pitch(){return this._pitch/Math.PI*180}set pitch(w){const se=m.clamp(w,this.minPitch,this.maxPitch)/180*Math.PI;this._pitch!==se&&(this._unmodified=!1,this._pitch=se,this._calcMatrices())}get fov(){return this._fov/Math.PI*180}set fov(w){w=Math.max(.01,Math.min(60,w)),this._fov!==w&&(this._unmodified=!1,this._fov=w/180*Math.PI,this._calcMatrices())}get averageElevation(){return this._averageElevation}set averageElevation(w){this._averageElevation=w,this._calcFogMatrices(),this._distanceTileDataCache={}}get zoom(){return this._zoom}set zoom(w){const se=Math.min(Math.max(w,this.minZoom),this.maxZoom);this._zoom!==se&&(this._unmodified=!1,this._setZoom(se),this._updateSeaLevelZoom(),this._constrain(),this._calcMatrices())}_setZoom(w){this._zoom=w,this.scale=this.zoomScale(w),this.tileZoom=Math.floor(w),this.zoomFraction=w-this.tileZoom}_updateCameraOnTerrain(){if(!this._elevation||!this._elevation.isDataAvailableAtPoint(this.locationCoordinate(this.center)))return this._centerAltitude=0,this._seaLevelZoom=null,void(this._centerAltitudeValidForExaggeration=0);const w=this._elevation;this._centerAltitude=w.getAtPointOrZero(this.locationCoordinate(this.center)),this._centerAltitudeValidForExaggeration=w.exaggeration(),this._updateSeaLevelZoom()}_updateSeaLevelZoom(){this._centerAltitudeValidForExaggeration!==0&&(this._seaLevelZoom=this._zoomFromMercatorZ((this.pixelsPerMeter*this._centerAltitude+this.cameraToCenterDistance)/this.worldSize))}sampleAverageElevation(){if(!this._elevation)return 0;const w=this._elevation,se=[[.5,.2],[.3,.5],[.5,.5],[.7,.5],[.5,.8]],it=this.horizonLineFromTop();let xt=0,Dt=0;for(let Ot=0;Ot<se.length;Ot++){const rn=new m.pointGeometry(se[Ot][0]*this.width,it+se[Ot][1]*(this.height-it)),Tn=w.pointCoordinate(rn);if(!Tn)continue;const kn=1/Math.hypot(Tn[0]-this._camera.position[0],Tn[1]-this._camera.position[1]);xt+=Tn[3]*kn,Dt+=kn}return Dt===0?NaN:xt/Dt}get center(){return this._center}set center(w){w.lat===this._center.lat&&w.lng===this._center.lng||(this._unmodified=!1,this._center=w,this._terrainEnabled()&&(this.cameraElevationReference==="ground"?this._updateCameraOnTerrain():this._updateZoomFromElevation()),this._constrain(),this._calcMatrices())}_updateZoomFromElevation(){if(this._seaLevelZoom==null||!this._elevation)return;const w=this._seaLevelZoom,se=this._elevation.getAtPointOrZero(this.locationCoordinate(this.center)),it=this.pixelsPerMeter/this.worldSize*se,xt=this._mercatorZfromZoom(w),Dt=this._mercatorZfromZoom(this._maxZoom),Ot=Math.max(xt-it,Dt);this._setZoom(this._zoomFromMercatorZ(Ot))}get padding(){return this._edgeInsets.toJSON()}set padding(w){this._edgeInsets.equals(w)||(this._unmodified=!1,this._edgeInsets.interpolate(this._edgeInsets,w,1),this._calcMatrices())}computeZoomRelativeTo(w){const se=this.rayIntersectionCoordinate(this.pointRayIntersection(this.centerPoint,w.toAltitude()));let it;it=w.z<this._camera.position[2]?[se.x,se.y,se.z]:[w.x,w.y,w.z];const xt=m.length(m.sub([],this._camera.position,it));return m.clamp(this._zoomFromMercatorZ(xt),this._minZoom,this._maxZoom)}setFreeCameraOptions(w){if(!this.height||!w.position&&!w.orientation)return;this._updateCameraState();let se=!1;if(w.orientation&&!m.exactEquals(w.orientation,this._camera.orientation)&&(se=this._setCameraOrientation(w.orientation)),w.position){const it=[w.position.x,w.position.y,w.position.z];m.exactEquals$1(it,this._camera.position)||(this._setCameraPosition(it),se=!0)}se&&(this._updateStateFromCamera(),this.recenterOnTerrain())}getFreeCameraOptions(){this._updateCameraState();const w=this._camera.position,se=new uc;return se.position=new m.MercatorCoordinate(w[0],w[1],w[2]),se.orientation=this._camera.orientation,se._elevation=this.elevation,se._renderWorldCopies=this.renderWorldCopies,se}_setCameraOrientation(w){if(!m.length$1(w))return!1;m.normalize$1(w,w);const se=m.transformQuat([],[0,0,-1],w),it=m.transformQuat([],[0,-1,0],w);if(it[2]<0)return!1;const xt=Zh(se,it);return!!xt&&(this._camera.orientation=xt,!0)}_setCameraPosition(w){const se=this.zoomScale(this.minZoom)*this.tileSize,it=this.zoomScale(this.maxZoom)*this.tileSize,xt=this.cameraToCenterDistance;w[2]=m.clamp(w[2],xt/it,xt/se),this._camera.position=w}get centerPoint(){return this._edgeInsets.getCenter(this.width,this.height)}get fovAboveCenter(){return this._fov*(.5+this.centerOffset.y/this.height)}isPaddingEqual(w){return this._edgeInsets.equals(w)}interpolatePadding(w,se,it){this._unmodified=!1,this._edgeInsets.interpolate(w,se,it),this._constrain(),this._calcMatrices()}coveringZoomLevel(w){const se=(w.roundZoom?Math.round:Math.floor)(this.zoom+this.scaleZoom(this.tileSize/w.tileSize));return Math.max(0,se)}getVisibleUnwrappedCoordinates(w){const se=[new m.UnwrappedTileID(0,w)];if(this.renderWorldCopies){const it=this.pointCoordinate(new m.pointGeometry(0,0)),xt=this.pointCoordinate(new m.pointGeometry(this.width,0)),Dt=this.pointCoordinate(new m.pointGeometry(this.width,this.height)),Ot=this.pointCoordinate(new m.pointGeometry(0,this.height)),rn=Math.floor(Math.min(it.x,xt.x,Dt.x,Ot.x)),Tn=Math.floor(Math.max(it.x,xt.x,Dt.x,Ot.x)),kn=1;for(let Bn=rn-kn;Bn<=Tn+kn;Bn++)Bn!==0&&se.push(new m.UnwrappedTileID(Bn,w))}return se}coveringTiles(w){let se=this.coveringZoomLevel(w);const it=se,xt=this.elevation&&!w.isTerrainDEM,Dt=this.projection.name==="mercator";if(w.minzoom!==void 0&&se<w.minzoom)return[];w.maxzoom!==void 0&&se>w.maxzoom&&(se=w.maxzoom);const Ot=this.locationCoordinate(this.center),rn=this.center.lat,Tn=1<<se,kn=[Tn*Ot.x,Tn*Ot.y,0],Bn=this.projection.name==="globe",Wn=!Bn,Fr=m.Frustum.fromInvProjectionMatrix(this.invProjMatrix,this.worldSize,se,Wn),ri=Bn?this._camera.mercatorPosition:this.pointCoordinate(this.getCameraPoint()),Zr=Tn*m.mercatorZfromAltitude(1,this.center.lat),Sr=this._camera.position[2]/m.mercatorZfromAltitude(1,this.center.lat),Di=[Tn*ri.x,Tn*ri.y,Sr*(Wn?1:Zr)],di=this.cameraToCenterDistance/w.tileSize*(w.roundZoom?1:.502),wi=this.pitch<=60&&this._edgeInsets.top<=this._edgeInsets.bottom&&!this._elevation&&!this.projection.isReprojectedInTileSpace?se:0,Ti=w.isTerrainDEM&&this._elevation?1e4*this._elevation.exaggeration():this._centerAltitude,Oi=w.isTerrainDEM?-Ti:this._elevation?this._elevation.getMinElevationBelowMSL():0,_i=this.projection.isReprojectedInTileSpace?Kh(this):1,Fi=Za=>{const is=new m.MercatorCoordinate(Za.x+25e-6,Za.y,Za.z),hs=new m.MercatorCoordinate(Za.x,Za.y+25e-6,Za.z),ps=Za.toLngLat(),Js=is.toLngLat(),fl=hs.toLngLat(),as=this.locationCoordinate(ps),ll=this.locationCoordinate(Js),Yl=this.locationCoordinate(fl),dc=Math.hypot(ll.x-as.x,ll.y-as.y),_c=Math.hypot(Yl.x-as.x,Yl.y-as.y);return Math.sqrt(dc*_c)*_i/25e-6},Ta=Za=>{const rs=Ti,is=Oi;return{aabb:m.tileAABB(this,Tn,0,0,0,Za,is,rs,this.projection),zoom:0,x:0,y:0,minZ:is,maxZ:rs,wrap:Za,fullyVisible:!1}},Fa=[];let qa=[];const ja=se,To=w.reparseOverscaled?it:se,na=Za=>Za*Za,Eo=na((Sr-this._centerAltitude)*Zr),So=Za=>{if(!this._elevation||!Za.tileID||!Dt)return;const rs=this._elevation.getMinMaxForTile(Za.tileID),is=Za.aabb;rs?(is.min[2]=rs.min,is.max[2]=rs.max,is.center[2]=(is.min[2]+is.max[2])/2):(Za.shouldSplit=Qo(Za),Za.shouldSplit||(is.min[2]=is.max[2]=is.center[2]=this._centerAltitude))},Qo=Za=>{if(Za.zoom<wi)return!0;if(Za.zoom===ja)return!1;if(Za.shouldSplit!=null)return Za.shouldSplit;const rs=Za.aabb.distanceX(Di),is=Za.aabb.distanceY(Di);let hs=Eo,ps=1;if(Bn){hs=na(Za.aabb.distanceZ(Di));const fl=Math.pow(2,Za.zoom),as=m.latFromMercatorY((Za.y+1)/fl),ll=m.latFromMercatorY(Za.y/fl),Yl=Math.min(Math.max(rn,as),ll),dc=m.circumferenceAtLatitude(Yl)/m.circumferenceAtLatitude(rn);ps=Math.min(dc,1)}else if(xt&&(hs=na(Za.aabb.distanceZ(Di)*Zr)),this.projection.isReprojectedInTileSpace&&it<=5){const fl=Math.pow(2,Za.zoom),as=Fi(new m.MercatorCoordinate((Za.x+.5)/fl,(Za.y+.5)/fl));ps=as>.85?1:as}const Js=rs*rs+is*is+hs;return Js<na((1<<ja-Za.zoom)*di*ps*((fl,as)=>{if(as*na(.707)<fl)return 1;const ll=Math.sqrt(as/fl);return ll/(1.4144271570014144+(Math.pow(1.1,ll-1.4144271570014144+1)-1)/(1.1-1)-1)})(Math.max(hs,Eo),Js))};if(this.renderWorldCopies)for(let Za=1;Za<=3;Za++)Fa.push(Ta(-Za)),Fa.push(Ta(Za));for(Fa.push(Ta(0));Fa.length>0;){const Za=Fa.pop(),rs=Za.x,is=Za.y;let hs=Za.fullyVisible;if(!hs){const ps=Za.aabb.intersects(Fr);if(ps===0)continue;hs=ps===2}if(Za.zoom!==ja&&Qo(Za))for(let ps=0;ps<4;ps++){const Js=(rs<<1)+ps%2,fl=(is<<1)+(ps>>1),as={aabb:Dt?Za.aabb.quadrant(ps):m.tileAABB(this,Tn,Za.zoom+1,Js,fl,Za.wrap,Za.minZ,Za.maxZ,this.projection),zoom:Za.zoom+1,x:Js,y:fl,wrap:Za.wrap,fullyVisible:hs,tileID:void 0,shouldSplit:void 0,minZ:Za.minZ,maxZ:Za.maxZ};xt&&!Bn&&(as.tileID=new m.OverscaledTileID(Za.zoom+1===ja?To:Za.zoom+1,Za.wrap,Za.zoom+1,Js,fl),So(as)),Fa.push(as)}else{const ps=Za.zoom===ja?To:Za.zoom;if(w.minzoom&&w.minzoom>ps)continue;const Js=kn[0]-(.5+rs+(Za.wrap<<Za.zoom))*(1<<se-Za.zoom),fl=kn[1]-.5-is,as=Za.tileID?Za.tileID:new m.OverscaledTileID(ps,Za.wrap,Za.zoom,rs,is);qa.push({tileID:as,distanceSq:Js*Js+fl*fl})}}if(this.fogCullDistSq){const Za=this.fogCullDistSq,rs=this.horizonLineFromTop();qa=qa.filter(is=>{const hs=[0,0,0,1],ps=[m.EXTENT,m.EXTENT,0,1],Js=this.calculateFogTileMatrix(is.tileID.toUnwrapped());m.transformMat4$1(hs,hs,Js),m.transformMat4$1(ps,ps,Js);const fl=m.getAABBPointSquareDist(hs,ps);if(fl===0)return!0;let as=!1;const ll=this._elevation;if(ll&&fl>Za&&rs!==0){const Yl=this.calculateProjMatrix(is.tileID.toUnwrapped());let dc;w.isTerrainDEM||(dc=ll.getMinMaxForTile(is.tileID)),dc||(dc={min:Oi,max:Ti});const _c=m.furthestTileCorner(this.rotation),Bc=[_c[0]*m.EXTENT,_c[1]*m.EXTENT,dc.max];m.transformMat4(Bc,Bc,Yl),as=(1-Bc[1])*this.height*.5<rs}return fl<Za||as})}return qa.sort((Za,rs)=>Za.distanceSq-rs.distanceSq).map(Za=>Za.tileID)}resize(w,se){this.width=w,this.height=se,this.pixelsToGLUnits=[2/w,-2/se],this._constrain(),this._calcMatrices()}get unmodified(){return this._unmodified}zoomScale(w){return Math.pow(2,w)}scaleZoom(w){return Math.log(w)/Math.LN2}project(w){const se=m.clamp(w.lat,-m.MAX_MERCATOR_LATITUDE,m.MAX_MERCATOR_LATITUDE),it=this.projection.project(w.lng,se);return new m.pointGeometry(it.x*this.worldSize,it.y*this.worldSize)}unproject(w){return this.projection.unproject(w.x/this.worldSize,w.y/this.worldSize)}get point(){return this.project(this.center)}setLocationAtPoint(w,se){let it,xt;const Dt=this.centerPoint;if(this.projection.name==="globe"){const rn=this.worldSize;it=(se.x-Dt.x)/rn,xt=(se.y-Dt.y)/rn}else{const rn=this.pointCoordinate(se),Tn=this.pointCoordinate(Dt);it=rn.x-Tn.x,xt=rn.y-Tn.y}const Ot=this.locationCoordinate(w);this.setLocation(new m.MercatorCoordinate(Ot.x-it,Ot.y-xt))}setLocation(w){this.center=this.coordinateLocation(w),this.projection.wrap&&(this.center=this.center.wrap())}locationPoint(w){return this.projection.locationPoint(this,w)}locationPoint3D(w){return this._coordinatePoint(this.locationCoordinate(w),!0)}pointLocation(w){return this.coordinateLocation(this.pointCoordinate(w))}pointLocation3D(w){return this.coordinateLocation(this.pointCoordinate3D(w))}locationCoordinate(w,se){const it=se?m.mercatorZfromAltitude(se,w.lat):void 0,xt=this.projection.project(w.lng,w.lat);return new m.MercatorCoordinate(xt.x,xt.y,it)}coordinateLocation(w){return this.projection.unproject(w.x,w.y)}pointRayIntersection(w,se){const it=se??this._centerAltitude,xt=[w.x,w.y,0,1],Dt=[w.x,w.y,1,1];m.transformMat4$1(xt,xt,this.pixelMatrixInverse),m.transformMat4$1(Dt,Dt,this.pixelMatrixInverse);const Ot=Dt[3];m.scale$1(xt,xt,1/xt[3]),m.scale$1(Dt,Dt,1/Ot);const rn=xt[2],Tn=Dt[2];return{p0:xt,p1:Dt,t:rn===Tn?0:(it-rn)/(Tn-rn)}}screenPointToMercatorRay(w){const se=[w.x,w.y,0,1],it=[w.x,w.y,1,1];return m.transformMat4$1(se,se,this.pixelMatrixInverse),m.transformMat4$1(it,it,this.pixelMatrixInverse),m.scale$1(se,se,1/se[3]),m.scale$1(it,it,1/it[3]),se[2]=m.mercatorZfromAltitude(se[2],this._center.lat)*this.worldSize,it[2]=m.mercatorZfromAltitude(it[2],this._center.lat)*this.worldSize,m.scale$1(se,se,1/this.worldSize),m.scale$1(it,it,1/this.worldSize),new m.Ray([se[0],se[1],se[2]],m.normalize([],m.sub([],it,se)))}rayIntersectionCoordinate(w){const{p0:se,p1:it,t:xt}=w,Dt=m.mercatorZfromAltitude(se[2],this._center.lat),Ot=m.mercatorZfromAltitude(it[2],this._center.lat);return new m.MercatorCoordinate(m.number(se[0],it[0],xt)/this.worldSize,m.number(se[1],it[1],xt)/this.worldSize,m.number(Dt,Ot,xt))}pointCoordinate(w,se=this._centerAltitude){return this.projection.pointCoordinate(this,w.x,w.y,se)}pointCoordinate3D(w){if(!this.elevation)return this.pointCoordinate(w);const se=this.elevation;let it=this.elevation.pointCoordinate(w);if(it)return new m.MercatorCoordinate(it[0],it[1],it[2]);let xt=0,Dt=this.horizonLineFromTop();if(w.y>Dt)return this.pointCoordinate(w);const Ot=.02*Dt,rn=w.clone();for(let Tn=0;Tn<10&&Dt-xt>Ot;Tn++){rn.y=m.number(xt,Dt,.66);const kn=se.pointCoordinate(rn);kn?(Dt=rn.y,it=kn):xt=rn.y}return it?new m.MercatorCoordinate(it[0],it[1],it[2]):this.pointCoordinate(w)}isPointAboveHorizon(w){if(this.elevation)return!this.elevation.pointCoordinate(w);{const se=this.horizonLineFromTop();return w.y<se}}_coordinatePoint(w,se){const it=se&&this.elevation?this.elevation.getAtPointOrZero(w,this._centerAltitude):this._centerAltitude,xt=[w.x*this.worldSize,w.y*this.worldSize,it+w.toAltitude(),1];return m.transformMat4$1(xt,xt,this.pixelMatrix),xt[3]>0?new m.pointGeometry(xt[0]/xt[3],xt[1]/xt[3]):new m.pointGeometry(Number.MAX_VALUE,Number.MAX_VALUE)}_getBounds(w,se){const it=new m.pointGeometry(this._edgeInsets.left,this._edgeInsets.top),xt=new m.pointGeometry(this.width-this._edgeInsets.right,this._edgeInsets.top),Dt=new m.pointGeometry(this.width-this._edgeInsets.right,this.height-this._edgeInsets.bottom),Ot=new m.pointGeometry(this._edgeInsets.left,this.height-this._edgeInsets.bottom);let rn=this.pointCoordinate(it,w),Tn=this.pointCoordinate(xt,w);const kn=this.pointCoordinate(Dt,se),Bn=this.pointCoordinate(Ot,se),Wn=(Fr,ri)=>(ri.y-Fr.y)/(ri.x-Fr.x);return rn.y>1&&Tn.y>=0?rn=new m.MercatorCoordinate((1-Bn.y)/Wn(Bn,rn)+Bn.x,1):rn.y<0&&Tn.y<=1&&(rn=new m.MercatorCoordinate(-Bn.y/Wn(Bn,rn)+Bn.x,0)),Tn.y>1&&rn.y>=0?Tn=new m.MercatorCoordinate((1-kn.y)/Wn(kn,Tn)+kn.x,1):Tn.y<0&&rn.y<=1&&(Tn=new m.MercatorCoordinate(-kn.y/Wn(kn,Tn)+kn.x,0)),new m.LngLatBounds().extend(this.coordinateLocation(rn)).extend(this.coordinateLocation(Tn)).extend(this.coordinateLocation(Bn)).extend(this.coordinateLocation(kn))}_getBounds3D(){const w=this.elevation;if(!w.visibleDemTiles.length)return this._getBounds(0,0);const se=w.visibleDemTiles.reduce((it,xt)=>{if(xt.dem){const Dt=xt.dem.tree;it.min=Math.min(it.min,Dt.minimums[0]),it.max=Math.max(it.max,Dt.maximums[0])}return it},{min:Number.MAX_VALUE,max:0});return this._getBounds(se.min*w.exaggeration(),se.max*w.exaggeration())}getBounds(){return this._terrainEnabled()?this._getBounds3D():this._getBounds(0,0)}horizonLineFromTop(w=!0){const se=this.height/2/Math.tan(this._fov/2)/Math.tan(Math.max(this._pitch,.1))+this.centerOffset.y,it=this.height/2-se*(1-this._horizonShift);return w?Math.max(0,it):it}getMaxBounds(){return this.maxBounds}setMaxBounds(w){this.maxBounds=w,this.minLat=-m.MAX_MERCATOR_LATITUDE,this.maxLat=m.MAX_MERCATOR_LATITUDE,this.minLng=-180,this.maxLng=180,w&&(this.minLat=w.getSouth(),this.maxLat=w.getNorth(),this.minLng=w.getWest(),this.maxLng=w.getEast(),this.maxLng<this.minLng&&(this.maxLng+=360)),this.worldMinX=m.mercatorXfromLng(this.minLng)*this.tileSize,this.worldMaxX=m.mercatorXfromLng(this.maxLng)*this.tileSize,this.worldMinY=m.mercatorYfromLat(this.maxLat)*this.tileSize,this.worldMaxY=m.mercatorYfromLat(this.minLat)*this.tileSize,this._constrain()}calculatePosMatrix(w,se){return this.projection.createTileMatrix(this,se,w)}calculateDistanceTileData(w){const se=w.key,it=this._distanceTileDataCache;if(it[se])return it[se];const xt=w.canonical,Dt=1/this.height,Ot=this.cameraWorldSize/this.zoomScale(xt.z),rn=(xt.x+Math.pow(2,xt.z)*w.wrap)*Ot,Tn=xt.y*Ot,kn=this.point,Bn=this.angle,Wn=Math.sin(-Bn),Fr=-Math.cos(-Bn);return it[se]={bearing:[Wn,Fr],center:[(kn.x-rn)*Dt,(kn.y-Tn)*Dt],scale:Ot/m.EXTENT*Dt},it[se]}calculateFogTileMatrix(w){const se=w.key,it=this._fogTileMatrixCache;if(it[se])return it[se];const xt=this.calculatePosMatrix(w,this.cameraWorldSize);return m.multiply$1(xt,this.worldToFogMatrix,xt),it[se]=new Float32Array(xt),it[se]}calculateProjMatrix(w,se=!1){const it=w.key,xt=se?this._alignedProjMatrixCache:this._projMatrixCache;if(xt[it])return xt[it];const Dt=this.calculatePosMatrix(w,this.worldSize);return m.multiply$1(Dt,this.projection.isReprojectedInTileSpace?this.mercatorMatrix:se?this.alignedProjMatrix:this.projMatrix,Dt),xt[it]=new Float32Array(Dt),xt[it]}calculatePixelsToTileUnitsMatrix(w){const se=w.tileID.key,it=this._pixelsToTileUnitsCache;if(it[se])return it[se];const xt=function(Dt,Ot){const{scale:rn}=Dt.tileTransform,Tn=rn*m.EXTENT/(Dt.tileSize*Math.pow(2,Ot.zoom-Dt.tileID.overscaledZ+Dt.tileID.canonical.z));return kn=new Float32Array(4),Fr=(Bn=Ot.inverseAdjustmentMatrix)[1],ri=Bn[2],Zr=Bn[3],Di=(Wn=[Tn,Tn])[1],kn[0]=Bn[0]*(Sr=Wn[0]),kn[1]=Fr*Sr,kn[2]=ri*Di,kn[3]=Zr*Di,kn;var kn,Bn,Wn,Fr,ri,Zr,Sr,Di}(w,this);return it[se]=xt,it[se]}customLayerMatrix(){return this.mercatorMatrix.slice()}recenterOnTerrain(){if(!this._elevation)return;const w=this._elevation;this._updateCameraState();const se=m.mercatorZfromAltitude(1,this._center.lat)*this.worldSize,it=this._computeCameraPosition(se),xt=this._camera.forward(),Dt=m.mercatorZfromAltitude(1,this._center.lat);it[2]/=Dt,xt[2]/=Dt,m.normalize(xt,xt);const Ot=w.raycast(it,xt,w.exaggeration());if(Ot){const rn=m.scaleAndAdd([],it,xt,Ot),Tn=new m.MercatorCoordinate(rn[0],rn[1],m.mercatorZfromAltitude(rn[2],m.latFromMercatorY(rn[1]))),kn=(Tn.z+m.length([Tn.x-it[0],Tn.y-it[1],Tn.z-it[2]*Dt]))*this._projectionScaler;this._seaLevelZoom=this._zoomFromMercatorZ(kn),this._centerAltitude=Tn.toAltitude(),this._center=this.coordinateLocation(Tn),this._updateZoomFromElevation(),this._constrain(),this._calcMatrices()}}_constrainCameraAltitude(){if(!this._elevation)return;const w=this._elevation;this._updateCameraState();const se=m.mercatorZfromAltitude(1,this._center.lat)*this.worldSize,it=this._computeCameraPosition(se),xt=w.getAtPointOrZero(new m.MercatorCoordinate(...it)),Dt=this._minimumHeightOverTerrain()*Math.cos(m.degToRad(this._maxPitch)),Ot=this._camera.position[2]-this.pixelsPerMeter/this.worldSize*xt;if(Ot<Dt){const rn=this.locationCoordinate(this._center,this._centerAltitude),Tn=[rn.x-it[0],rn.y-it[1],rn.z-it[2]],kn=m.length(Tn);Tn[2]-=(Dt-Ot)/this._projectionScaler;const Bn=m.length(Tn);if(Bn===0)return;m.scale$2(Tn,Tn,kn/Bn*this._projectionScaler),this._camera.position=[rn.x-Tn[0],rn.y-Tn[1],rn.z*this._projectionScaler-Tn[2]],this._camera.orientation=Zh(Tn,this._camera.up()),this._updateStateFromCamera()}}_constrain(){if(!this.center||!this.width||!this.height||this._constraining)return;if(this._constraining=!0,this.projection.isReprojectedInTileSpace){const Wn=this.center;return Wn.lat=m.clamp(Wn.lat,this.minLat,this.maxLat),!this.maxBounds&&this.renderWorldCopies||(Wn.lng=m.clamp(Wn.lng,this.minLng,this.maxLng)),this.center=Wn,void(this._constraining=!1)}const w=this._unmodified,{x:se,y:it}=this.point;let xt=0,Dt=se,Ot=it;const rn=this.width/2,Tn=this.height/2,kn=this.worldMinY*this.scale,Bn=this.worldMaxY*this.scale;if(it-Tn<kn&&(Ot=kn+Tn),it+Tn>Bn&&(Ot=Bn-Tn),Bn-kn<this.height&&(xt=Math.max(xt,this.height/(Bn-kn)),Ot=(Bn+kn)/2),this.maxBounds||!this._renderWorldCopies||!this.projection.wrap){const Wn=this.worldMinX*this.scale,Fr=this.worldMaxX*this.scale,ri=this.worldSize/2-(Wn+Fr)/2;Dt=(se+ri+this.worldSize)%this.worldSize-ri,Dt-rn<Wn&&(Dt=Wn+rn),Dt+rn>Fr&&(Dt=Fr-rn),Fr-Wn<this.width&&(xt=Math.max(xt,this.width/(Fr-Wn)),Dt=(Fr+Wn)/2)}Dt===se&&Ot===it||(this.center=this.unproject(new m.pointGeometry(Dt,Ot))),xt&&(this.zoom+=this.scaleZoom(xt)),this._constrainCameraAltitude(),this._unmodified=w,this._constraining=!1}_minZoomForBounds(){let w=Math.max(0,this.scaleZoom(this.height/(this.worldMaxY-this.worldMinY)));return this.maxBounds&&(w=Math.max(w,this.scaleZoom(this.width/(this.worldMaxX-this.worldMinX)))),w}_maxCameraBoundsDistance(){return this._mercatorZfromZoom(this._minZoomForBounds())}_calcMatrices(){if(!this.height)return;const w=this._fov/2,se=this.centerOffset,it=this.pixelsPerMeter;this._projectionScaler=it/(m.mercatorZfromAltitude(1,this.center.lat)*this.worldSize),this.cameraToCenterDistance=.5/Math.tan(w)*this.height*this._projectionScaler,this._updateCameraState(),this._farZ=this.projection.farthestPixelDistance(this),this._nearZ=this.height/50;const xt=this._camera.getWorldToCamera(this.worldSize,this.projection.zAxisUnit==="meters"?it:1),Dt=this._camera.getCameraToClipPerspective(this._fov,this.width/this.height,this._nearZ,this._farZ);Dt[8]=2*-se.x/this.width,Dt[9]=2*se.y/this.height;let Ot=m.mul([],Dt,xt);if(this.projection.isReprojectedInTileSpace){const Oi=this.locationCoordinate(this.center),_i=m.identity([]);m.translate(_i,_i,[Oi.x*this.worldSize,Oi.y*this.worldSize,0]),m.multiply$1(_i,_i,Op(this)),m.translate(_i,_i,[-Oi.x*this.worldSize,-Oi.y*this.worldSize,0]),m.multiply$1(Ot,Ot,_i),this.inverseAdjustmentMatrix=function(Fi){const Ta=Op(Fi,!0);return ue([],[Ta[0],Ta[1],Ta[4],Ta[5]])}(this)}else this.inverseAdjustmentMatrix=[1,0,0,1];this.mercatorMatrix=m.scale([],Ot,[this.worldSize,this.worldSize,this.worldSize/it,1]),this.projMatrix=Ot,this.invProjMatrix=m.invert(new Float64Array(16),this.projMatrix);const rn=new Float32Array(16);m.identity(rn),m.scale(rn,rn,[1,-1,1]),m.rotateX(rn,rn,this._pitch),m.rotateZ(rn,rn,this.angle);const Tn=m.perspective(new Float32Array(16),this._fov,this.width/this.height,this._nearZ,this._farZ),kn=(Math.PI/2-this._pitch)*(this.height/this._fov)*this._horizonShift;Tn[8]=2*-se.x/this.width,Tn[9]=2*(se.y+kn)/this.height,this.skyboxMatrix=m.multiply$1(rn,Tn,rn);const Bn=this.point,Wn=Bn.x,Fr=Bn.y,ri=this.width%2/2,Zr=this.height%2/2,Sr=Math.cos(this.angle),Di=Math.sin(this.angle),di=Wn-Math.round(Wn)+Sr*ri+Di*Zr,wi=Fr-Math.round(Fr)+Sr*Zr+Di*ri,Ti=new Float64Array(Ot);if(m.translate(Ti,Ti,[di>.5?di-1:di,wi>.5?wi-1:wi,0]),this.alignedProjMatrix=Ti,Ot=m.create(),m.scale(Ot,Ot,[this.width/2,-this.height/2,1]),m.translate(Ot,Ot,[1,-1,0]),this.labelPlaneMatrix=Ot,Ot=m.create(),m.scale(Ot,Ot,[1,-1,1]),m.translate(Ot,Ot,[-1,-1,0]),m.scale(Ot,Ot,[2/this.width,2/this.height,1]),this.glCoordMatrix=Ot,this.pixelMatrix=m.multiply$1(new Float64Array(16),this.labelPlaneMatrix,this.projMatrix),this._calcFogMatrices(),this._distanceTileDataCache={},Ot=m.invert(new Float64Array(16),this.pixelMatrix),!Ot)throw new Error("failed to invert matrix");this.pixelMatrixInverse=Ot,this.globeMatrix=this.projection.name==="globe"?m.calculateGlobeMatrix(this):Ot,this._projMatrixCache={},this._alignedProjMatrixCache={},this._pixelsToTileUnitsCache={}}_calcFogMatrices(){this._fogTileMatrixCache={};const w=this.cameraWorldSize,se=this.cameraPixelsPerMeter,it=this._camera.position,xt=1/this.height,Dt=[w,w,se];m.scale$2(Dt,Dt,xt),m.scale$2(it,it,-1),m.multiply$2(it,it,Dt);const Ot=m.create();m.translate(Ot,Ot,it),m.scale(Ot,Ot,Dt),this.mercatorFogMatrix=Ot,this.worldToFogMatrix=this._camera.getWorldToCameraPosition(w,se,xt)}_computeCameraPosition(w){const se=(w=w||this.pixelsPerMeter)/this.pixelsPerMeter,it=this._camera.forward(),xt=this.point,Dt=this._mercatorZfromZoom(this._seaLevelZoom?this._seaLevelZoom:this._zoom)*se-w/this.worldSize*this._centerAltitude;return[xt.x/this.worldSize-it[0]*Dt,xt.y/this.worldSize-it[1]*Dt,w/this.worldSize*this._centerAltitude-it[2]*Dt]}_updateCameraState(){this.height&&(this._camera.setPitchBearing(this._pitch,this.angle),this._camera.position=this._computeCameraPosition())}_translateCameraConstrained(w){const se=this._maxCameraBoundsDistance()*Math.cos(this._pitch),it=w[2];let xt=1;it>0&&(xt=Math.min((se-this._camera.position[2])/it,1)),this._camera.position=m.scaleAndAdd([],this._camera.position,w,xt),this._updateStateFromCamera(),this.projection.wrap&&(this.center=this.center.wrap())}_updateStateFromCamera(){const w=this._camera.position,se=this._camera.forward(),{pitch:it,bearing:xt}=this._camera.getPitchBearing(),Dt=m.mercatorZfromAltitude(this._centerAltitude,this.center.lat)*this._projectionScaler,Ot=this._mercatorZfromZoom(this._maxZoom)*Math.cos(m.degToRad(this._maxPitch)),rn=Math.max((w[2]-Dt)/Math.cos(it),Ot),Tn=this._zoomFromMercatorZ(rn);m.scaleAndAdd(w,w,se,rn),this._pitch=m.clamp(it,m.degToRad(this.minPitch),m.degToRad(this.maxPitch)),this.angle=m.wrap(xt,-Math.PI,Math.PI),this._setZoom(m.clamp(Tn,this._minZoom,this._maxZoom)),this._updateSeaLevelZoom(),this._center=this.coordinateLocation(new m.MercatorCoordinate(w[0],w[1],w[2])),this._unmodified=!1,this._constrain(),this._calcMatrices()}_worldSizeFromZoom(w){return Math.pow(2,w)*this.tileSize}_mercatorZfromZoom(w){return this.cameraToCenterDistance/this._worldSizeFromZoom(w)}_minimumHeightOverTerrain(){const w=Math.min((this._seaLevelZoom!=null?this._seaLevelZoom:this._zoom)+2,this._maxZoom);return this._mercatorZfromZoom(w)}_zoomFromMercatorZ(w){return this.scaleZoom(this.cameraToCenterDistance/(w*this.tileSize))}_terrainEnabled(){return!(!this._elevation||!this.projection.supportsTerrain&&(m.warnOnce("Terrain is not yet supported with alternate projections. Use mercator to enable terrain."),1))}anyCornerOffEdge(w,se){const it=Math.min(w.x,se.x),xt=Math.max(w.x,se.x),Dt=Math.min(w.y,se.y),Ot=Math.max(w.y,se.y);if(Dt<this.horizonLineFromTop(!1))return!0;if(this.projection.name!=="mercator")return!1;const rn=[new m.pointGeometry(it,Dt),new m.pointGeometry(xt,Ot),new m.pointGeometry(it,Ot),new m.pointGeometry(xt,Dt)],Tn=this.renderWorldCopies?-3:0,kn=this.renderWorldCopies?4:1;for(const Bn of rn){const Wn=this.pointRayIntersection(Bn);if(Wn.t<0)return!0;const Fr=this.rayIntersectionCoordinate(Wn);if(Fr.x<Tn||Fr.y<0||Fr.x>kn||Fr.y>1)return!0}return!1}isHorizonVisible(){return this.pitch+m.radToDeg(this.fovAboveCenter)>88||this.anyCornerOffEdge(new m.pointGeometry(0,0),new m.pointGeometry(this.width,this.height))}zoomDeltaToMovement(w,se){const it=m.length(m.sub([],this._camera.position,w)),xt=this._zoomFromMercatorZ(it)+se;return it-this._mercatorZfromZoom(xt)}getCameraPoint(){const w=Math.tan(this._pitch)*(this.cameraToCenterDistance||1);return this.centerPoint.add(new m.pointGeometry(0,w))}}function ef(Ee,w){let se=!1,it=null;const xt=()=>{it=null,se&&(Ee(),it=setTimeout(xt,w),se=!1)};return()=>(se=!0,it||xt(),it)}class Cf{constructor(w){this._hashName=w&&encodeURIComponent(w),m.bindAll(["_getCurrentHash","_onHashChange","_updateHash"],this),this._updateHash=ef(this._updateHashUnthrottled.bind(this),300)}addTo(w){return this._map=w,m.window.addEventListener("hashchange",this._onHashChange,!1),w.on("moveend",this._updateHash),this}remove(){return this._map?(this._map.off("moveend",this._updateHash),m.window.removeEventListener("hashchange",this._onHashChange,!1),clearTimeout(this._updateHash()),this._map=void 0,this):this}getHashString(w){const se=this._map;if(!se)return"";const it=se.getCenter(),xt=Math.round(100*se.getZoom())/100,Dt=Math.ceil((xt*Math.LN2+Math.log(512/360/.5))/Math.LN10),Ot=Math.pow(10,Dt),rn=Math.round(it.lng*Ot)/Ot,Tn=Math.round(it.lat*Ot)/Ot,kn=se.getBearing(),Bn=se.getPitch();let Wn="";if(Wn+=w?`/${rn}/${Tn}/${xt}`:`${xt}/${Tn}/${rn}`,(kn||Bn)&&(Wn+="/"+Math.round(10*kn)/10),Bn&&(Wn+=`/${Math.round(Bn)}`),this._hashName){const Fr=this._hashName;let ri=!1;const Zr=m.window.location.hash.slice(1).split("&").map(Sr=>{const Di=Sr.split("=")[0];return Di===Fr?(ri=!0,`${Di}=${Wn}`):Sr}).filter(Sr=>Sr);return ri||Zr.push(`${Fr}=${Wn}`),`#${Zr.join("&")}`}return`#${Wn}`}_getCurrentHash(){const w=m.window.location.hash.replace("#","");if(this._hashName){let se;return w.split("&").map(it=>it.split("=")).forEach(it=>{it[0]===this._hashName&&(se=it)}),(se&&se[1]||"").split("/")}return w.split("/")}_onHashChange(){const w=this._map;if(!w)return!1;const se=this._getCurrentHash();if(se.length>=3&&!se.some(it=>isNaN(it))){const it=w.dragRotate.isEnabled()&&w.touchZoomRotate.isEnabled()?+(se[3]||0):w.getBearing();return w.jumpTo({center:[+se[2],+se[1]],zoom:+se[0],bearing:it,pitch:+(se[4]||0)}),!0}return!1}_updateHashUnthrottled(){const w=m.window.location.href.replace(/(#.+)?$/,this.getHashString());m.window.history.replaceState(m.window.history.state,null,w)}}const _d={linearity:.3,easing:m.bezier(0,0,.3,1)},oh=m.extend({deceleration:2500,maxSpeed:1400},_d),tf=m.extend({deceleration:20,maxSpeed:1400},_d),Lp=m.extend({deceleration:1e3,maxSpeed:360},_d),Ah=m.extend({deceleration:1e3,maxSpeed:90},_d);class cp{constructor(w){this._map=w,this.clear()}clear(){this._inertiaBuffer=[]}record(w){this._drainInertiaBuffer(),this._inertiaBuffer.push({time:m.exported.now(),settings:w})}_drainInertiaBuffer(){const w=this._inertiaBuffer,se=m.exported.now();for(;w.length>0&&se-w[0].time>160;)w.shift()}_onMoveEnd(w){if(this._drainInertiaBuffer(),this._inertiaBuffer.length<2)return;const se={zoom:0,bearing:0,pitch:0,pan:new m.pointGeometry(0,0),pinchAround:void 0,around:void 0};for(const{settings:Dt}of this._inertiaBuffer)se.zoom+=Dt.zoomDelta||0,se.bearing+=Dt.bearingDelta||0,se.pitch+=Dt.pitchDelta||0,Dt.panDelta&&se.pan._add(Dt.panDelta),Dt.around&&(se.around=Dt.around),Dt.pinchAround&&(se.pinchAround=Dt.pinchAround);const it=this._inertiaBuffer[this._inertiaBuffer.length-1].time-this._inertiaBuffer[0].time,xt={};if(se.pan.mag()){const Dt=Cc(se.pan.mag(),it,m.extend({},oh,w||{}));xt.offset=se.pan.mult(Dt.amount/se.pan.mag()),xt.center=this._map.transform.center,yc(xt,Dt)}if(se.zoom){const Dt=Cc(se.zoom,it,tf);xt.zoom=this._map.transform.zoom+Dt.amount,yc(xt,Dt)}if(se.bearing){const Dt=Cc(se.bearing,it,Lp);xt.bearing=this._map.transform.bearing+m.clamp(Dt.amount,-179,179),yc(xt,Dt)}if(se.pitch){const Dt=Cc(se.pitch,it,Ah);xt.pitch=this._map.transform.pitch+Dt.amount,yc(xt,Dt)}if(xt.zoom||xt.bearing){const Dt=se.pinchAround===void 0?se.around:se.pinchAround;xt.around=Dt?this._map.unproject(Dt):this._map.getCenter()}return this.clear(),xt.noMoveStart=!0,xt}}function yc(Ee,w){(!Ee.duration||Ee.duration<w.duration)&&(Ee.duration=w.duration,Ee.easing=w.easing)}function Cc(Ee,w,se){const{maxSpeed:it,linearity:xt,deceleration:Dt}=se,Ot=m.clamp(Ee*xt/(w/1e3),-it,it),rn=Math.abs(Ot)/(Dt*xt);return{easing:se.easing,duration:1e3*rn,amount:Ot*(rn/2)}}class lu extends m.Event{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(w,se,it,xt={}){const Dt=Ae(se.getCanvasContainer(),it),Ot=se.unproject(Dt);super(w,m.extend({point:Dt,lngLat:Ot,originalEvent:it},xt)),this._defaultPrevented=!1,this.target=se}}class Od extends m.Event{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(w,se,it){const xt=w==="touchend"?it.changedTouches:it.touches,Dt=Te(se.getCanvasContainer(),xt),Ot=Dt.map(Tn=>se.unproject(Tn)),rn=Dt.reduce((Tn,kn,Bn,Wn)=>Tn.add(kn.div(Wn.length)),new m.pointGeometry(0,0));super(w,{points:Dt,point:rn,lngLats:Ot,lngLat:se.unproject(rn),originalEvent:it}),this._defaultPrevented=!1}}class nf extends m.Event{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(w,se,it){super(w,{originalEvent:it}),this._defaultPrevented=!1}}class Wf{constructor(w,se){this._map=w,this._clickTolerance=se.clickTolerance}reset(){this._mousedownPos=void 0}wheel(w){return this._firePreventable(new nf(w.type,this._map,w))}mousedown(w,se){return this._mousedownPos=se,this._firePreventable(new lu(w.type,this._map,w))}mouseup(w){this._map.fire(new lu(w.type,this._map,w))}preclick(w){const se=m.extend({},w);se.type="preclick",this._map.fire(new lu(se.type,this._map,se))}click(w,se){this._mousedownPos&&this._mousedownPos.dist(se)>=this._clickTolerance||(this.preclick(w),this._map.fire(new lu(w.type,this._map,w)))}dblclick(w){return this._firePreventable(new lu(w.type,this._map,w))}mouseover(w){this._map.fire(new lu(w.type,this._map,w))}mouseout(w){this._map.fire(new lu(w.type,this._map,w))}touchstart(w){return this._firePreventable(new Od(w.type,this._map,w))}touchmove(w){this._map.fire(new Od(w.type,this._map,w))}touchend(w){this._map.fire(new Od(w.type,this._map,w))}touchcancel(w){this._map.fire(new Od(w.type,this._map,w))}_firePreventable(w){if(this._map.fire(w),w.defaultPrevented)return{}}isEnabled(){return!0}isActive(){return!1}enable(){}disable(){}}class Sc{constructor(w){this._map=w}reset(){this._delayContextMenu=!1,this._contextMenuEvent=void 0}mousemove(w){this._map.fire(new lu(w.type,this._map,w))}mousedown(){this._delayContextMenu=!0}mouseup(){this._delayContextMenu=!1,this._contextMenuEvent&&(this._map.fire(new lu("contextmenu",this._map,this._contextMenuEvent)),delete this._contextMenuEvent)}contextmenu(w){this._delayContextMenu?this._contextMenuEvent=w:this._map.fire(new lu(w.type,this._map,w)),this._map.listens("contextmenu")&&w.preventDefault()}isEnabled(){return!0}isActive(){return!1}enable(){}disable(){}}class Sf{constructor(w,se){this._map=w,this._el=w.getCanvasContainer(),this._container=w.getContainer(),this._clickTolerance=se.clickTolerance||1}isEnabled(){return!!this._enabled}isActive(){return!!this._active}enable(){this.isEnabled()||(this._enabled=!0)}disable(){this.isEnabled()&&(this._enabled=!1)}mousedown(w,se){this.isEnabled()&&w.shiftKey&&w.button===0&&(Ue(),this._startPos=this._lastPos=se,this._active=!0)}mousemoveWindow(w,se){if(!this._active)return;const it=se;if(this._lastPos.equals(it)||!this._box&&it.dist(this._startPos)<this._clickTolerance)return;const xt=this._startPos;this._lastPos=it,this._box||(this._box=q("div","mapboxgl-boxzoom",this._container),this._container.classList.add("mapboxgl-crosshair"),this._fireEvent("boxzoomstart",w));const Dt=Math.min(xt.x,it.x),Ot=Math.max(xt.x,it.x),rn=Math.min(xt.y,it.y),Tn=Math.max(xt.y,it.y);this._map._requestDomTask(()=>{this._box&&(this._box.style.transform=`translate(${Dt}px,${rn}px)`,this._box.style.width=Ot-Dt+"px",this._box.style.height=Tn-rn+"px")})}mouseupWindow(w,se){if(!this._active||w.button!==0)return;const it=this._startPos,xt=se;if(this.reset(),rt(),it.x!==xt.x||it.y!==xt.y)return this._map.fire(new m.Event("boxzoomend",{originalEvent:w})),{cameraAnimation:Dt=>Dt.fitScreenCoordinates(it,xt,this._map.getBearing(),{linear:!1})};this._fireEvent("boxzoomcancel",w)}keydown(w){this._active&&w.keyCode===27&&(this.reset(),this._fireEvent("boxzoomcancel",w))}blur(){this.reset()}reset(){this._active=!1,this._container.classList.remove("mapboxgl-crosshair"),this._box&&(this._box.remove(),this._box=null),De(),delete this._startPos,delete this._lastPos}_fireEvent(w,se){return this._map.fire(new m.Event(w,{originalEvent:se}))}}function vc(Ee,w){const se={};for(let it=0;it<Ee.length;it++)se[Ee[it].identifier]=w[it];return se}class ul{constructor(w){this.reset(),this.numTouches=w.numTouches}reset(){this.centroid=void 0,this.startTime=0,this.touches={},this.aborted=!1}touchstart(w,se,it){(this.centroid||it.length>this.numTouches)&&(this.aborted=!0),this.aborted||(this.startTime===0&&(this.startTime=w.timeStamp),it.length===this.numTouches&&(this.centroid=function(xt){const Dt=new m.pointGeometry(0,0);for(const Ot of xt)Dt._add(Ot);return Dt.div(xt.length)}(se),this.touches=vc(it,se)))}touchmove(w,se,it){if(this.aborted||!this.centroid)return;const xt=vc(it,se);for(const Dt in this.touches){const Ot=this.touches[Dt],rn=xt[Dt];(!rn||rn.dist(Ot)>30)&&(this.aborted=!0)}}touchend(w,se,it){if((!this.centroid||w.timeStamp-this.startTime>500)&&(this.aborted=!0),it.length===0){const xt=!this.aborted&&this.centroid;if(this.reset(),xt)return xt}}}class dp{constructor(w){this.singleTap=new ul(w),this.numTaps=w.numTaps,this.reset()}reset(){this.lastTime=1/0,this.lastTap=void 0,this.count=0,this.singleTap.reset()}touchstart(w,se,it){this.singleTap.touchstart(w,se,it)}touchmove(w,se,it){this.singleTap.touchmove(w,se,it)}touchend(w,se,it){const xt=this.singleTap.touchend(w,se,it);if(xt){const Dt=w.timeStamp-this.lastTime<500,Ot=!this.lastTap||this.lastTap.dist(xt)<30;if(Dt&&Ot||this.reset(),this.count++,this.lastTime=w.timeStamp,this.lastTap=xt,this.count===this.numTaps)return this.reset(),xt}}}class Zo{constructor(){this._zoomIn=new dp({numTouches:1,numTaps:2}),this._zoomOut=new dp({numTouches:2,numTaps:1}),this.reset()}reset(){this._active=!1,this._zoomIn.reset(),this._zoomOut.reset()}touchstart(w,se,it){this._zoomIn.touchstart(w,se,it),this._zoomOut.touchstart(w,se,it)}touchmove(w,se,it){this._zoomIn.touchmove(w,se,it),this._zoomOut.touchmove(w,se,it)}touchend(w,se,it){const xt=this._zoomIn.touchend(w,se,it),Dt=this._zoomOut.touchend(w,se,it);return xt?(this._active=!0,w.preventDefault(),setTimeout(()=>this.reset(),0),{cameraAnimation:Ot=>Ot.easeTo({duration:300,zoom:Ot.getZoom()+1,around:Ot.unproject(xt)},{originalEvent:w})}):Dt?(this._active=!0,w.preventDefault(),setTimeout(()=>this.reset(),0),{cameraAnimation:Ot=>Ot.easeTo({duration:300,zoom:Ot.getZoom()-1,around:Ot.unproject(Dt)},{originalEvent:w})}):void 0}touchcancel(){this.reset()}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}const Xh={0:1,2:2,1:4};class kc{constructor(w){this.reset(),this._clickTolerance=w.clickTolerance||1}blur(){this.reset()}reset(){this._active=!1,this._moved=!1,this._lastPoint=void 0,this._eventButton=void 0}_correctButton(w,se){return!1}_move(w,se){return{}}mousedown(w,se){if(this._lastPoint)return;const it=Xe(w);this._correctButton(w,it)&&(this._lastPoint=se,this._eventButton=it)}mousemoveWindow(w,se){const it=this._lastPoint;if(it){if(w.preventDefault(),this._eventButton!=null&&function(xt,Dt){const Ot=Xh[Dt];return xt.buttons===void 0||(xt.buttons&Ot)!==Ot}(w,this._eventButton))this.reset();else if(this._moved||!(se.dist(it)<this._clickTolerance))return this._moved=!0,this._lastPoint=se,this._move(it,se)}}mouseupWindow(w){this._lastPoint&&Xe(w)===this._eventButton&&(this._moved&&rt(),this.reset())}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}class Fp extends kc{useMiddle(w){let se=this._middle;return this._middle=w,se}mousedown(w,se){super.mousedown(w,se),this._lastPoint&&(this._active=!0)}_correctButton(w,se){return this._middle?se===1&&!w.ctrlKey:se===0&&!w.ctrlKey}_move(w,se){return{around:se,panDelta:se.sub(w)}}}class kh extends kc{_correctButton(w,se){return se===0&&w.ctrlKey||se===2}_move(w,se){const it=.8*(se.x-w.x);if(it)return this._active=!0,{bearingDelta:it}}contextmenu(w){w.preventDefault()}}class Tf extends kc{_correctButton(w,se){return se===0&&w.ctrlKey||se===2}_move(w,se){const it=-.5*(se.y-w.y);if(it)return this._active=!0,{pitchDelta:it}}contextmenu(w){w.preventDefault()}}class Ld{constructor(w,se){this._map=w,this._el=w.getCanvasContainer(),this._minTouches=1,this._clickTolerance=se.clickTolerance||1,this.reset(),m.bindAll(["_addTouchPanBlocker","_showTouchPanBlockerAlert"],this)}reset(){this._active=!1,this._touches={},this._sum=new m.pointGeometry(0,0)}touchstart(w,se,it){return this._calculateTransform(w,se,it)}touchmove(w,se,it){if(this._active&&!(it.length<this._minTouches)){if(this._map._cooperativeGestures&&!this._map.isMoving()){if(it.length===1)return void this._showTouchPanBlockerAlert();this._alertContainer.style.visibility!=="hidden"&&(this._alertContainer.style.visibility="hidden",clearTimeout(this._alertTimer))}return w.preventDefault(),this._calculateTransform(w,se,it)}}touchend(w,se,it){this._calculateTransform(w,se,it),this._active&&it.length<this._minTouches&&this.reset()}touchcancel(){this.reset()}_calculateTransform(w,se,it){it.length>0&&(this._active=!0);const xt=vc(it,se),Dt=new m.pointGeometry(0,0),Ot=new m.pointGeometry(0,0);let rn=0;for(const kn in xt){const Bn=xt[kn],Wn=this._touches[kn];Wn&&(Dt._add(Bn),Ot._add(Bn.sub(Wn)),rn++,xt[kn]=Bn)}if(this._touches=xt,rn<this._minTouches||!Ot.mag())return;const Tn=Ot.div(rn);return this._sum._add(Tn),this._sum.mag()<this._clickTolerance?void 0:{around:Dt.div(rn),panDelta:Tn}}enable(){this._enabled=!0,this._map._cooperativeGestures&&(this._addTouchPanBlocker(),this._el.classList.add("mapboxgl-touch-pan-blocker-override","mapboxgl-scrollable-page"))}disable(){this._enabled=!1,this._map._cooperativeGestures&&(clearTimeout(this._alertTimer),this._alertContainer.remove(),this._el.classList.remove("mapboxgl-touch-pan-blocker-override","mapboxgl-scrollable-page")),this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}_addTouchPanBlocker(){this._map&&!this._alertContainer&&(this._alertContainer=q("div","mapboxgl-touch-pan-blocker",this._map._container),this._alertContainer.textContent=this._map._getUIString("TouchPanBlocker.Message"),this._alertContainer.style.fontSize=`${Math.max(10,Math.min(24,Math.floor(.05*this._el.clientWidth)))}px`)}_showTouchPanBlockerAlert(){this._alertContainer.style.visibility==="hidden"&&(this._alertContainer.style.visibility="visible"),this._alertContainer.classList.add("mapboxgl-touch-pan-blocker-show"),clearTimeout(this._alertTimer),this._alertTimer=setTimeout(()=>{this._alertContainer.classList.remove("mapboxgl-touch-pan-blocker-show")},500)}}class Gd{constructor(){this.reset()}reset(){this._active=!1,this._firstTwoTouches=void 0}_start(w){}_move(w,se,it){return{}}touchstart(w,se,it){this._firstTwoTouches||it.length<2||(this._firstTwoTouches=[it[0].identifier,it[1].identifier],this._start([se[0],se[1]]))}touchmove(w,se,it){const xt=this._firstTwoTouches;if(!xt)return;w.preventDefault();const[Dt,Ot]=xt,rn=cc(it,se,Dt),Tn=cc(it,se,Ot);if(!rn||!Tn)return;const kn=this._aroundCenter?null:rn.add(Tn).div(2);return this._move([rn,Tn],kn,w)}touchend(w,se,it){if(!this._firstTwoTouches)return;const[xt,Dt]=this._firstTwoTouches,Ot=cc(it,se,xt),rn=cc(it,se,Dt);Ot&&rn||(this._active&&rt(),this.reset())}touchcancel(){this.reset()}enable(w){this._enabled=!0,this._aroundCenter=!!w&&w.around==="center"}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}function cc(Ee,w,se){for(let it=0;it<Ee.length;it++)if(Ee[it].identifier===se)return w[it]}function Jh(Ee,w){return Math.log(Ee/w)/Math.LN2}class hp extends Gd{reset(){super.reset(),this._distance=0,this._startDistance=0}_start(w){this._startDistance=this._distance=w[0].dist(w[1])}_move(w,se){const it=this._distance;if(this._distance=w[0].dist(w[1]),this._active||!(Math.abs(Jh(this._distance,this._startDistance))<.1))return this._active=!0,{zoomDelta:Jh(this._distance,it),pinchAround:se}}}function pp(Ee,w){return 180*Ee.angleWith(w)/Math.PI}class Ph extends Gd{reset(){super.reset(),this._minDiameter=0,this._startVector=void 0,this._vector=void 0}_start(w){this._startVector=this._vector=w[0].sub(w[1]),this._minDiameter=w[0].dist(w[1])}_move(w,se){const it=this._vector;if(this._vector=w[0].sub(w[1]),this._active||!this._isBelowThreshold(this._vector))return this._active=!0,{bearingDelta:pp(this._vector,it),pinchAround:se}}_isBelowThreshold(w){this._minDiameter=Math.min(this._minDiameter,w.mag());const se=25/(Math.PI*this._minDiameter)*360,it=pp(w,this._startVector);return Math.abs(it)<se}}function mh(Ee){return Math.abs(Ee.y)>Math.abs(Ee.x)}class Ih extends Gd{constructor(w){super(),this._map=w}reset(){super.reset(),this._valid=void 0,this._firstMove=void 0,this._lastPoints=void 0}_start(w){this._lastPoints=w,mh(w[0].sub(w[1]))&&(this._valid=!1)}_move(w,se,it){const xt=this._lastPoints;if(!xt)return;const Dt=w[0].sub(xt[0]),Ot=w[1].sub(xt[1]);return this._map._cooperativeGestures&&it.touches.length<3||(this._valid=this.gestureBeginsVertically(Dt,Ot,it.timeStamp),!this._valid)?void 0:(this._lastPoints=w,this._active=!0,{pitchDelta:(Dt.y+Ot.y)/2*-.5})}gestureBeginsVertically(w,se,it){if(this._valid!==void 0)return this._valid;const xt=w.mag()>=2,Dt=se.mag()>=2;if(!xt&&!Dt)return;if(!xt||!Dt)return this._firstMove==null&&(this._firstMove=it),it-this._firstMove<100&&void 0;const Ot=w.y>0==se.y>0;return mh(w)&&mh(se)&&Ot}}const Ts={panStep:100,bearingStep:15,pitchStep:10};class qf{constructor(){const w=Ts;this._panStep=w.panStep,this._bearingStep=w.bearingStep,this._pitchStep=w.pitchStep,this._rotationDisabled=!1}blur(){this.reset()}reset(){this._active=!1}keydown(w){if(w.altKey||w.ctrlKey||w.metaKey)return;let se=0,it=0,xt=0,Dt=0,Ot=0;switch(w.keyCode){case 61:case 107:case 171:case 187:se=1;break;case 189:case 109:case 173:se=-1;break;case 37:w.shiftKey?it=-1:(w.preventDefault(),Dt=-1);break;case 39:w.shiftKey?it=1:(w.preventDefault(),Dt=1);break;case 38:w.shiftKey?xt=1:(w.preventDefault(),Ot=-1);break;case 40:w.shiftKey?xt=-1:(w.preventDefault(),Ot=1);break;default:return}return this._rotationDisabled&&(it=0,xt=0),{cameraAnimation:rn=>{const Tn=rn.getZoom();rn.easeTo({duration:300,easeId:"keyboardHandler",easing:Bp,zoom:se?Math.round(Tn)+se*(w.shiftKey?2:1):Tn,bearing:rn.getBearing()+it*this._bearingStep,pitch:rn.getPitch()+xt*this._pitchStep,offset:[-Dt*this._panStep,-Ot*this._panStep],center:rn.getCenter()},{originalEvent:w})}}}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}disableRotation(){this._rotationDisabled=!0}enableRotation(){this._rotationDisabled=!1}}function Bp(Ee){return Ee*(2-Ee)}const Qh=4.000244140625;class ql{constructor(w,se){this._map=w,this._el=w.getCanvasContainer(),this._handler=se,this._delta=0,this._defaultZoomRate=.01,this._wheelZoomRate=.0022222222222222222,m.bindAll(["_onTimeout","_addScrollZoomBlocker","_showBlockerAlert","_isFullscreen"],this)}setZoomRate(w){this._defaultZoomRate=w}setWheelZoomRate(w){this._wheelZoomRate=w}isEnabled(){return!!this._enabled}isActive(){return!!this._active||this._finishTimeout!==void 0}isZooming(){return!!this._zooming}enable(w){this.isEnabled()||(this._enabled=!0,this._aroundCenter=!!w&&w.around==="center",this._map._cooperativeGestures&&this._addScrollZoomBlocker())}disable(){this.isEnabled()&&(this._enabled=!1,this._map._cooperativeGestures&&(clearTimeout(this._alertTimer),this._alertContainer.remove()))}wheel(w){if(!this.isEnabled())return;if(this._map._cooperativeGestures){if(!(w.ctrlKey||w.metaKey||this.isZooming()||this._isFullscreen()))return void this._showBlockerAlert();this._alertContainer.style.visibility!=="hidden"&&(this._alertContainer.style.visibility="hidden",clearTimeout(this._alertTimer))}let se=w.deltaMode===m.window.WheelEvent.DOM_DELTA_LINE?40*w.deltaY:w.deltaY;const it=m.exported.now(),xt=it-(this._lastWheelEventTime||0);this._lastWheelEventTime=it,se!==0&&se%Qh==0?this._type="wheel":se!==0&&Math.abs(se)<4?this._type="trackpad":xt>400?(this._type=null,this._lastValue=se,this._timeout=setTimeout(this._onTimeout,40,w)):this._type||(this._type=Math.abs(xt*se)<200?"trackpad":"wheel",this._timeout&&(clearTimeout(this._timeout),this._timeout=null,se+=this._lastValue)),w.shiftKey&&se&&(se/=4),this._type&&(this._lastWheelEvent=w,this._delta-=se,this._active||this._start(w)),w.preventDefault()}_onTimeout(w){this._type="wheel",this._delta-=this._lastValue,this._active||this._start(w)}_start(w){if(!this._delta)return;this._frameId&&(this._frameId=null),this._active=!0,this.isZooming()||(this._zooming=!0),this._finishTimeout&&(clearTimeout(this._finishTimeout),delete this._finishTimeout);const se=Ae(this._el,w);this._aroundPoint=this._aroundCenter?this._map.transform.centerPoint:se,this._aroundCoord=this._map.transform.pointCoordinate3D(this._aroundPoint),this._targetZoom=void 0,this._frameId||(this._frameId=!0,this._handler._triggerRenderFrame())}renderFrame(){if(!this._frameId||(this._frameId=null,!this.isActive()))return;const w=this._map.transform,se=()=>w._terrainEnabled()&&this._aroundCoord?w.computeZoomRelativeTo(this._aroundCoord):w.zoom;if(this._delta!==0){const Tn=this._type==="wheel"&&Math.abs(this._delta)>Qh?this._wheelZoomRate:this._defaultZoomRate;let kn=2/(1+Math.exp(-Math.abs(this._delta*Tn)));this._delta<0&&kn!==0&&(kn=1/kn);const Bn=se(),Wn=Math.pow(2,Bn),Fr=typeof this._targetZoom=="number"?w.zoomScale(this._targetZoom):Wn;this._targetZoom=Math.min(w.maxZoom,Math.max(w.minZoom,w.scaleZoom(Fr*kn))),this._type==="wheel"&&(this._startZoom=se(),this._easing=this._smoothOutEasing(200)),this._delta=0}const it=typeof this._targetZoom=="number"?this._targetZoom:se(),xt=this._startZoom,Dt=this._easing;let Ot,rn=!1;if(this._type==="wheel"&&xt&&Dt){const Tn=Math.min((m.exported.now()-this._lastWheelEventTime)/200,1),kn=Dt(Tn);Ot=m.number(xt,it,kn),Tn<1?this._frameId||(this._frameId=!0):rn=!0}else Ot=it,rn=!0;return this._active=!0,rn&&(this._active=!1,this._finishTimeout=setTimeout(()=>{this._zooming=!1,this._handler._triggerRenderFrame(),delete this._targetZoom,delete this._finishTimeout},200)),{noInertia:!0,needsRenderFrame:!rn,zoomDelta:Ot-se(),around:this._aroundPoint,aroundCoord:this._aroundCoord,originalEvent:this._lastWheelEvent}}_smoothOutEasing(w){let se=m.ease;if(this._prevEase){const it=this._prevEase,xt=(m.exported.now()-it.start)/it.duration,Dt=it.easing(xt+.01)-it.easing(xt),Ot=.27/Math.sqrt(Dt*Dt+1e-4)*.01,rn=Math.sqrt(.0729-Ot*Ot);se=m.bezier(Ot,rn,.25,1)}return this._prevEase={start:m.exported.now(),duration:w,easing:se},se}blur(){this.reset()}reset(){this._active=!1}_addScrollZoomBlocker(){this._map&&!this._alertContainer&&(this._alertContainer=q("div","mapboxgl-scroll-zoom-blocker",this._map._container),this._alertContainer.textContent=/(Mac|iPad)/i.test(m.window.navigator.userAgent)?this._map._getUIString("ScrollZoomBlocker.CmdMessage"):this._map._getUIString("ScrollZoomBlocker.CtrlMessage"),this._alertContainer.style.fontSize=`${Math.max(10,Math.min(24,Math.floor(.05*this._el.clientWidth)))}px`)}_isFullscreen(){return!!m.window.document.fullscreenElement||!!m.window.document.webkitFullscreenElement}_showBlockerAlert(){this._alertContainer.style.visibility==="hidden"&&(this._alertContainer.style.visibility="visible"),this._alertContainer.classList.add("mapboxgl-scroll-zoom-blocker-show"),clearTimeout(this._alertTimer),this._alertTimer=setTimeout(()=>{this._alertContainer.classList.remove("mapboxgl-scroll-zoom-blocker-show")},200)}}class Xd{constructor(w,se){this._clickZoom=w,this._tapZoom=se}enable(){this._clickZoom.enable(),this._tapZoom.enable()}disable(){this._clickZoom.disable(),this._tapZoom.disable()}isEnabled(){return this._clickZoom.isEnabled()&&this._tapZoom.isEnabled()}isActive(){return this._clickZoom.isActive()||this._tapZoom.isActive()}}class Kl{constructor(){this.reset()}reset(){this._active=!1}blur(){this.reset()}dblclick(w,se){return w.preventDefault(),{cameraAnimation:it=>{it.easeTo({duration:300,zoom:it.getZoom()+(w.shiftKey?-1:1),around:it.unproject(se)},{originalEvent:w})}}}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}class Vp{constructor(){this._tap=new dp({numTouches:1,numTaps:1}),this.reset()}reset(){this._active=!1,this._swipePoint=void 0,this._swipeTouch=0,this._tapTime=0,this._tap.reset()}touchstart(w,se,it){this._swipePoint||(this._tapTime&&w.timeStamp-this._tapTime>500&&this.reset(),this._tapTime?it.length>0&&(this._swipePoint=se[0],this._swipeTouch=it[0].identifier):this._tap.touchstart(w,se,it))}touchmove(w,se,it){if(this._tapTime){if(this._swipePoint){if(it[0].identifier!==this._swipeTouch)return;const xt=se[0],Dt=xt.y-this._swipePoint.y;return this._swipePoint=xt,w.preventDefault(),this._active=!0,{zoomDelta:Dt/128}}}else this._tap.touchmove(w,se,it)}touchend(w,se,it){this._tapTime?this._swipePoint&&it.length===0&&this.reset():this._tap.touchend(w,se,it)&&(this._tapTime=w.timeStamp)}touchcancel(){this.reset()}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}class ep{constructor(w,se,it){this._el=w,this._mousePan=se,this._touchPan=it}enable(w){this._inertiaOptions=w||{},this._mousePan.enable(),this._touchPan.enable(),this._el.classList.add("mapboxgl-touch-drag-pan")}disable(){this._mousePan.disable(),this._touchPan.disable(),this._el.classList.remove("mapboxgl-touch-drag-pan")}isEnabled(){return this._mousePan.isEnabled()&&this._touchPan.isEnabled()}isActive(){return this._mousePan.isActive()||this._touchPan.isActive()}useMouseMiddle(w){return this._mousePan.useMiddle(w)}}class Df{constructor(w,se,it){this._pitchWithRotate=w.pitchWithRotate,this._mouseRotate=se,this._mousePitch=it}enable(){this._mouseRotate.enable(),this._pitchWithRotate&&this._mousePitch.enable()}disable(){this._mouseRotate.disable(),this._mousePitch.disable()}isEnabled(){return this._mouseRotate.isEnabled()&&(!this._pitchWithRotate||this._mousePitch.isEnabled())}isActive(){return this._mouseRotate.isActive()||this._mousePitch.isActive()}}class xd{constructor(w,se,it,xt){this._el=w,this._touchZoom=se,this._touchRotate=it,this._tapDragZoom=xt,this._rotationDisabled=!1,this._enabled=!0}enable(w){this._touchZoom.enable(w),this._rotationDisabled||this._touchRotate.enable(w),this._tapDragZoom.enable(),this._el.classList.add("mapboxgl-touch-zoom-rotate")}disable(){this._touchZoom.disable(),this._touchRotate.disable(),this._tapDragZoom.disable(),this._el.classList.remove("mapboxgl-touch-zoom-rotate")}isEnabled(){return this._touchZoom.isEnabled()&&(this._rotationDisabled||this._touchRotate.isEnabled())&&this._tapDragZoom.isEnabled()}isActive(){return this._touchZoom.isActive()||this._touchRotate.isActive()||this._tapDragZoom.isActive()}disableRotation(){this._rotationDisabled=!0,this._touchRotate.disable()}enableRotation(){this._rotationDisabled=!1,this._touchZoom.isEnabled()&&this._touchRotate.enable()}}const rf=Ee=>Ee.zoom||Ee.drag||Ee.pitch||Ee.rotate;class af extends m.Event{}class Yf{constructor(){this.constants=[1,1,.01],this.radius=0}setup(w,se){const it=m.sub([],se,w);this.radius=m.length(it[2]<0?m.div([],it,this.constants):[it[0],it[1],0])}projectRay(w){m.div(w,w,this.constants),m.normalize(w,w),m.mul$1(w,w,this.constants);const se=m.scale$2([],w,this.radius);if(se[2]>0){const it=m.scale$2([],[0,0,1],m.dot(se,[0,0,1])),xt=m.scale$2([],m.normalize([],[se[0],se[1],0]),this.radius),Dt=m.add([],se,m.scale$2([],m.sub([],m.add([],xt,it),se),2));se[0]=Dt[0],se[1]=Dt[1]}return se}}function fp(Ee){return Ee.panDelta&&Ee.panDelta.mag()||Ee.zoomDelta||Ee.bearingDelta||Ee.pitchDelta}class Zf{constructor(w,se){this._map=w,this._el=this._map.getCanvasContainer(),this._handlers=[],this._handlersById={},this._changes=[],this._inertia=new cp(w),this._bearingSnap=se.bearingSnap,this._previousActiveHandlers={},this._trackingEllipsoid=new Yf,this._dragOrigin=null,this._eventsInProgress={},this._addDefaultHandlers(se),m.bindAll(["handleEvent","handleWindowEvent"],this);const it=this._el;this._listeners=[[it,"touchstart",{passive:!0}],[it,"touchmove",{passive:!1}],[it,"touchend",void 0],[it,"touchcancel",void 0],[it,"mousedown",void 0],[it,"mousemove",void 0],[it,"mouseup",void 0],[m.window.document,"mousemove",{capture:!0}],[m.window.document,"mouseup",void 0],[it,"mouseover",void 0],[it,"mouseout",void 0],[it,"dblclick",void 0],[it,"click",void 0],[it,"keydown",{capture:!1}],[it,"keyup",void 0],[it,"wheel",{passive:!1}],[it,"contextmenu",void 0],[m.window,"blur",void 0]];for(const[xt,Dt,Ot]of this._listeners)xt.addEventListener(Dt,xt===m.window.document?this.handleWindowEvent:this.handleEvent,Ot)}destroy(){for(const[w,se,it]of this._listeners)w.removeEventListener(se,w===m.window.document?this.handleWindowEvent:this.handleEvent,it)}_addDefaultHandlers(w){const se=this._map,it=se.getCanvasContainer();this._add("mapEvent",new Wf(se,w));const xt=se.boxZoom=new Sf(se,w);this._add("boxZoom",xt);const Dt=new Zo,Ot=new Kl;se.doubleClickZoom=new Xd(Ot,Dt),this._add("tapZoom",Dt),this._add("clickZoom",Ot);const rn=new Vp;this._add("tapDragZoom",rn);const Tn=se.touchPitch=new Ih(se);this._add("touchPitch",Tn);const kn=new kh(w),Bn=new Tf(w);se.dragRotate=new Df(w,kn,Bn),this._add("mouseRotate",kn,["mousePitch"]),this._add("mousePitch",Bn,["mouseRotate"]);const Wn=new Fp(w),Fr=new Ld(se,w);se.dragPan=new ep(it,Wn,Fr),this._add("mousePan",Wn),this._add("touchPan",Fr,["touchZoom","touchRotate"]);const ri=new Ph,Zr=new hp;se.touchZoomRotate=new xd(it,Zr,ri,rn),this._add("touchRotate",ri,["touchPan","touchZoom"]),this._add("touchZoom",Zr,["touchPan","touchRotate"]),this._add("blockableMapEvent",new Sc(se));const Sr=se.scrollZoom=new ql(se,this);this._add("scrollZoom",Sr,["mousePan"]);const Di=se.keyboard=new qf;this._add("keyboard",Di);for(const di of["boxZoom","doubleClickZoom","tapDragZoom","touchPitch","dragRotate","dragPan","touchZoomRotate","scrollZoom","keyboard"])w.interactive&&w[di]&&se[di].enable(w[di])}_add(w,se,it){this._handlers.push({handlerName:w,handler:se,allowed:it}),this._handlersById[w]=se}stop(w){if(!this._updatingCamera){for(const{handler:se}of this._handlers)se.reset();this._inertia.clear(),this._fireEvents({},{},w),this._changes=[]}}isActive(){for(const{handler:w}of this._handlers)if(w.isActive())return!0;return!1}isZooming(){return!!this._eventsInProgress.zoom||this._map.scrollZoom.isZooming()}isRotating(){return!!this._eventsInProgress.rotate}isMoving(){return!!rf(this._eventsInProgress)||this.isZooming()}_blockedByActive(w,se,it){for(const xt in w)if(xt!==it&&(!se||se.indexOf(xt)<0))return!0;return!1}handleWindowEvent(w){this.handleEvent(w,`${w.type}Window`)}_getMapTouches(w){const se=[];for(const it of w)this._el.contains(it.target)&&se.push(it);return se}handleEvent(w,se){this._updatingCamera=!0;const it=w.type==="renderFrame",xt=it?void 0:w,Dt={needsRenderFrame:!1},Ot={},rn={},Tn=w.touches?this._getMapTouches(w.touches):void 0,kn=Tn?Te(this._el,Tn):it?void 0:Ae(this._el,w);for(const{handlerName:Fr,handler:ri,allowed:Zr}of this._handlers){if(!ri.isEnabled())continue;let Sr;this._blockedByActive(rn,Zr,Fr)?ri.reset():ri[se||w.type]&&(Sr=ri[se||w.type](w,kn,Tn),this.mergeHandlerResult(Dt,Ot,Sr,Fr,xt),Sr&&Sr.needsRenderFrame&&this._triggerRenderFrame()),(Sr||ri.isActive())&&(rn[Fr]=ri)}const Bn={};for(const Fr in this._previousActiveHandlers)rn[Fr]||(Bn[Fr]=xt);this._previousActiveHandlers=rn,(Object.keys(Bn).length||fp(Dt))&&(this._changes.push([Dt,Ot,Bn]),this._triggerRenderFrame()),(Object.keys(rn).length||fp(Dt))&&this._map._stop(!0),this._updatingCamera=!1;const{cameraAnimation:Wn}=Dt;Wn&&(this._inertia.clear(),this._fireEvents({},{},!0),this._changes=[],Wn(this._map))}mergeHandlerResult(w,se,it,xt,Dt){if(!it)return;m.extend(w,it);const Ot={handlerName:xt,originalEvent:it.originalEvent||Dt};it.zoomDelta!==void 0&&(se.zoom=Ot),it.panDelta!==void 0&&(se.drag=Ot),it.pitchDelta!==void 0&&(se.pitch=Ot),it.bearingDelta!==void 0&&(se.rotate=Ot)}_applyChanges(){const w={},se={},it={};for(const[xt,Dt,Ot]of this._changes)xt.panDelta&&(w.panDelta=(w.panDelta||new m.pointGeometry(0,0))._add(xt.panDelta)),xt.zoomDelta&&(w.zoomDelta=(w.zoomDelta||0)+xt.zoomDelta),xt.bearingDelta&&(w.bearingDelta=(w.bearingDelta||0)+xt.bearingDelta),xt.pitchDelta&&(w.pitchDelta=(w.pitchDelta||0)+xt.pitchDelta),xt.around!==void 0&&(w.around=xt.around),xt.aroundCoord!==void 0&&(w.aroundCoord=xt.aroundCoord),xt.pinchAround!==void 0&&(w.pinchAround=xt.pinchAround),xt.noInertia&&(w.noInertia=xt.noInertia),m.extend(se,Dt),m.extend(it,Ot);this._updateMapTransform(w,se,it),this._changes=[]}_updateMapTransform(w,se,it){const xt=this._map,Dt=xt.transform,Ot=wi=>[wi.x,wi.y,wi.z];if((wi=>{const Ti=this._eventsInProgress.drag;return Ti&&!this._handlersById[Ti.handlerName].isActive()})()&&!fp(w)){const wi=Dt.zoom;Dt.cameraElevationReference="sea",Dt.recenterOnTerrain(),Dt.cameraElevationReference="ground",wi!==Dt.zoom&&this._map._update(!0)}if(!fp(w))return void this._fireEvents(se,it,!0);let{panDelta:rn,zoomDelta:Tn,bearingDelta:kn,pitchDelta:Bn,around:Wn,aroundCoord:Fr,pinchAround:ri}=w;ri!==void 0&&(Wn=ri),(wi=>se.drag&&!this._eventsInProgress.drag)()&&Wn&&(this._dragOrigin=Ot(Dt.pointCoordinate3D(Wn)),this._trackingEllipsoid.setup(Dt._camera.position,this._dragOrigin)),Dt.cameraElevationReference="sea",xt._stop(!0),Wn=Wn||xt.transform.centerPoint,kn&&(Dt.bearing+=kn),Bn&&(Dt.pitch+=Bn),Dt._updateCameraState();const Zr=[0,0,0];if(rn){const wi=Dt.pointCoordinate(Wn);if(Dt.projection.name==="globe"){const Ti=m.latFromMercatorY(wi.y),Oi=Dt.center.lat,_i=Math.min(m.mercatorZfromAltitude(1,Ti)/m.mercatorZfromAltitude(1,Oi),2);rn=rn.rotate(-Dt.angle),Zr[0]=-rn.x/Dt.worldSize*_i,Zr[1]=-rn.y/Dt.worldSize*_i}else{const Ti=Dt.pointCoordinate(Wn.sub(rn));wi&&Ti&&(Zr[0]=Ti.x-wi.x,Zr[1]=Ti.y-wi.y)}}const Sr=Dt.zoom,Di=[0,0,0];if(Tn){const wi=Ot(Fr||Dt.pointCoordinate3D(Wn)),Ti={dir:m.normalize([],m.sub([],wi,Dt._camera.position))};if(Ti.dir[2]<0){const Oi=Dt.zoomDeltaToMovement(wi,Tn);m.scale$2(Di,Ti.dir,Oi)}}const di=m.add(Zr,Zr,Di);Dt._translateCameraConstrained(di),Tn&&Math.abs(Dt.zoom-Sr)>1e-4&&Dt.recenterOnTerrain(),Dt.cameraElevationReference="ground",this._map._update(),w.noInertia||this._inertia.record(w),this._fireEvents(se,it,!0)}_fireEvents(w,se,it){const xt=rf(this._eventsInProgress),Dt=rf(w),Ot={};for(const Bn in w){const{originalEvent:Wn}=w[Bn];this._eventsInProgress[Bn]||(Ot[`${Bn}start`]=Wn),this._eventsInProgress[Bn]=w[Bn]}!xt&&Dt&&this._fireEvent("movestart",Dt.originalEvent);for(const Bn in Ot)this._fireEvent(Bn,Ot[Bn]);Dt&&this._fireEvent("move",Dt.originalEvent);for(const Bn in w){const{originalEvent:Wn}=w[Bn];this._fireEvent(Bn,Wn)}const rn={};let Tn;for(const Bn in this._eventsInProgress){const{handlerName:Wn,originalEvent:Fr}=this._eventsInProgress[Bn];this._handlersById[Wn].isActive()||(delete this._eventsInProgress[Bn],Tn=se[Wn]||Fr,rn[`${Bn}end`]=Tn)}for(const Bn in rn)this._fireEvent(Bn,rn[Bn]);const kn=rf(this._eventsInProgress);if(it&&(xt||Dt)&&!kn){this._updatingCamera=!0;const Bn=this._inertia._onMoveEnd(this._map.dragPan._inertiaOptions),Wn=Fr=>Fr!==0&&-this._bearingSnap<Fr&&Fr<this._bearingSnap;Bn?(Wn(Bn.bearing||this._map.getBearing())&&(Bn.bearing=0),this._map.easeTo(Bn,{originalEvent:Tn})):(this._map.fire(new m.Event("moveend",{originalEvent:Tn})),Wn(this._map.getBearing())&&this._map.resetNorth()),this._updatingCamera=!1}}_fireEvent(w,se){this._map.fire(new m.Event(w,se?{originalEvent:se}:{}))}_requestFrame(){return this._map.triggerRepaint(),this._map._renderTaskQueue.add(w=>{this._frameId=void 0,this.handleEvent(new af("renderFrame",{timeStamp:w})),this._applyChanges()})}_triggerRenderFrame(){this._frameId===void 0&&(this._frameId=this._requestFrame())}}const pd="map.setFreeCameraOptions(...) and map.getFreeCameraOptions() are not yet supported for non-mercator projections.";class gh extends m.Evented{constructor(w,se){super(),this._moving=!1,this._zooming=!1,this.transform=w,this._bearingSnap=se.bearingSnap,m.bindAll(["_renderFrameCallback"],this)}getCenter(){return new m.LngLat(this.transform.center.lng,this.transform.center.lat)}setCenter(w,se){return this.jumpTo({center:w},se)}panBy(w,se,it){return w=m.pointGeometry.convert(w).mult(-1),this.panTo(this.transform.center,m.extend({offset:w},se),it)}panTo(w,se,it){return this.easeTo(m.extend({center:w},se),it)}getZoom(){return this.transform.zoom}setZoom(w,se){return this.jumpTo({zoom:w},se),this}zoomTo(w,se,it){return this.easeTo(m.extend({zoom:w},se),it)}zoomIn(w,se){return this.zoomTo(this.getZoom()+1,w,se),this}zoomOut(w,se){return this.zoomTo(this.getZoom()-1,w,se),this}getBearing(){return this.transform.bearing}setBearing(w,se){return this.jumpTo({bearing:w},se),this}getPadding(){return this.transform.padding}setPadding(w,se){return this.jumpTo({padding:w},se),this}rotateTo(w,se,it){return this.easeTo(m.extend({bearing:w},se),it)}resetNorth(w,se){return this.rotateTo(0,m.extend({duration:1e3},w),se),this}resetNorthPitch(w,se){return this.easeTo(m.extend({bearing:0,pitch:0,duration:1e3},w),se),this}snapToNorth(w,se){return Math.abs(this.getBearing())<this._bearingSnap?this.resetNorth(w,se):this}getPitch(){return this.transform.pitch}setPitch(w,se){return this.jumpTo({pitch:w},se),this}cameraForBounds(w,se){w=m.LngLatBounds.convert(w);const it=se&&se.bearing||0;return this._cameraForBoxAndBearing(w.getNorthWest(),w.getSouthEast(),it,se)}_extendCameraOptions(w){const se={top:0,bottom:0,right:0,left:0};if(typeof(w=m.extend({padding:se,offset:[0,0],maxZoom:this.transform.maxZoom},w)).padding=="number"){const it=w.padding;w.padding={top:it,bottom:it,right:it,left:it}}return w.padding=m.extend(se,w.padding),w}_cameraForBoxAndBearing(w,se,it,xt){const Dt=this._extendCameraOptions(xt),Ot=this.transform,rn=Ot.padding,Tn=Ot.project(m.LngLat.convert(w)),kn=Ot.project(m.LngLat.convert(se)),Bn=new m.pointGeometry(Tn.x,kn.y),Wn=new m.pointGeometry(kn.x,Tn.y),Fr=-m.degToRad(it),ri=Tn.rotate(Fr),Zr=kn.rotate(Fr),Sr=Bn.rotate(Fr),Di=Wn.rotate(Fr),di=new m.pointGeometry(Math.max(ri.x,Zr.x,Sr.x,Di.x),Math.max(ri.y,Zr.y,Sr.y,Di.y)),wi=new m.pointGeometry(Math.min(ri.x,Zr.x,Sr.x,Di.x),Math.min(ri.y,Zr.y,Sr.y,Di.y)),Ti=di.sub(wi),Oi=(Ot.width-((rn.left||0)+(rn.right||0)+Dt.padding.left+Dt.padding.right))/Ti.x,_i=(Ot.height-((rn.top||0)+(rn.bottom||0)+Dt.padding.top+Dt.padding.bottom))/Ti.y;if(_i<0||Oi<0)return void m.warnOnce("Map cannot fit within canvas with the given bounds, padding, and/or offset.");const Fi=Math.min(Ot.scaleZoom(Ot.scale*Math.min(Oi,_i)),Dt.maxZoom),Ta=typeof Dt.offset.x=="number"&&typeof Dt.offset.y=="number"?new m.pointGeometry(Dt.offset.x,Dt.offset.y):m.pointGeometry.convert(Dt.offset),Fa=new m.pointGeometry((Dt.padding.left-Dt.padding.right)/2,(Dt.padding.top-Dt.padding.bottom)/2).rotate(it*Math.PI/180),qa=Ta.add(Fa).mult(Ot.scale/Ot.zoomScale(Fi));return{center:Ot.unproject(Tn.add(kn).div(2).sub(qa)),zoom:Fi,bearing:it}}_cameraForBox(w,se,it,xt,Dt){const Ot=this._extendCameraOptions(Dt);it=it||0,xt=xt||0,w=m.LngLat.convert(w),se=m.LngLat.convert(se);const rn=this.transform.clone();rn.padding=Ot.padding;const Tn=this.getFreeCameraOptions(),kn=new m.LngLat(.5*(w.lng+se.lng),.5*(w.lat+se.lat)),Bn=.5*(it+xt);if(rn._camera.position[2]<m.mercatorZfromAltitude(Bn,kn.lat))return void m.warnOnce("Map cannot fit within canvas with the given bounds, padding, and/or offset.");Tn.lookAtPoint(kn),rn.setFreeCameraOptions(Tn);const Wn=m.MercatorCoordinate.fromLngLat(w),Fr=m.MercatorCoordinate.fromLngLat(se),ri=rn.pointRayIntersection(rn.centerPoint,Bn),Zr=[(Sr=rn.rayIntersectionCoordinate(ri)).x,Sr.y,Sr.z];var Sr;const Di=rn.screenPointToMercatorRay(rn.centerPoint),di=rn.projection.name!=="globe";let wi,Ti=0;do{const Oi=Math.floor(rn.zoom),_i=1<<Oi,Fi=Math.min(_i*Wn.x,_i*Fr.x),Ta=Math.min(_i*Wn.y,_i*Fr.y),Fa=Math.max(_i*Wn.x,_i*Fr.x),qa=Math.max(_i*Wn.y,_i*Fr.y),ja=new m.Aabb([Fi,Ta,it],[Fa,qa,xt]),To=m.Frustum.fromInvProjectionMatrix(rn.invProjMatrix,rn.worldSize,Oi,di);if(ja.intersects(To)!==2){wi&&(rn._camera.position=m.scaleAndAdd([],rn._camera.position,Di.dir,-wi),rn._updateStateFromCamera());break}const na=m.sub([],rn._camera.position,Zr);wi=.5*m.length(na),rn._camera.position=m.scaleAndAdd([],rn._camera.position,Di.dir,wi);try{rn._updateStateFromCamera()}catch{return void m.warnOnce("Map cannot fit within canvas with the given bounds, padding, and/or offset.")}}while(++Ti<10);return{center:rn.center,zoom:rn.zoom,bearing:rn.bearing,pitch:rn.pitch}}fitBounds(w,se,it){return this._fitInternal(this.cameraForBounds(w,se),se,it)}_raycastElevationBox(w,se){const it=this.transform.elevation;if(!it)return;const xt=new m.pointGeometry(w.x,se.y),Dt=new m.pointGeometry(se.x,w.y),Ot=it.pointCoordinate(w);if(!Ot)return;const rn=it.pointCoordinate(se);if(!rn)return;const Tn=it.pointCoordinate(xt);if(!Tn)return;const kn=it.pointCoordinate(Dt);if(!kn)return;const Bn=new m.MercatorCoordinate(Ot[0],Ot[1]).toLngLat(),Wn=new m.MercatorCoordinate(rn[0],rn[1]).toLngLat(),Fr=new m.MercatorCoordinate(Tn[0],Tn[1]).toLngLat(),ri=new m.MercatorCoordinate(kn[0],kn[1]).toLngLat(),Zr=Math.min(Bn.lng,Math.min(Wn.lng,Math.min(Fr.lng,ri.lng))),Sr=Math.min(Bn.lat,Math.min(Wn.lat,Math.min(Fr.lat,ri.lat))),Di=Math.max(Bn.lng,Math.max(Wn.lng,Math.max(Fr.lng,ri.lng))),di=Math.max(Bn.lat,Math.max(Wn.lat,Math.max(Fr.lat,ri.lat))),wi=Math.min(Ot[3],Math.min(rn[3],Math.min(Tn[3],kn[3]))),Ti=Math.max(Ot[3],Math.max(rn[3],Math.max(Tn[3],kn[3])));return{minLngLat:new m.LngLat(Zr,Sr),maxLngLat:new m.LngLat(Di,di),minAltitude:wi,maxAltitude:Ti}}fitScreenCoordinates(w,se,it,xt,Dt){let Ot,rn,Tn,kn;const Bn=m.pointGeometry.convert(w),Wn=m.pointGeometry.convert(se),Fr=this._raycastElevationBox(Bn,Wn);if(Fr)Ot=Fr.minLngLat,rn=Fr.maxLngLat,Tn=Fr.minAltitude,kn=Fr.maxAltitude;else{if(this.transform.anyCornerOffEdge(Bn,Wn))return this;Ot=this.transform.pointLocation(Bn),rn=this.transform.pointLocation(Wn)}return this._fitInternal(this.transform.pitch===0?this._cameraForBoxAndBearing(this.transform.pointLocation(m.pointGeometry.convert(w)),this.transform.pointLocation(m.pointGeometry.convert(se)),it,xt):this._cameraForBox(Ot,rn,Tn,kn,xt),xt,Dt)}_fitInternal(w,se,it){return w?(delete(se=m.extend(w,se)).padding,se.linear?this.easeTo(se,it):this.flyTo(se,it)):this}jumpTo(w,se){this.stop();const it=w.preloadOnly?this.transform.clone():this.transform;let xt=!1,Dt=!1,Ot=!1;return"zoom"in w&&it.zoom!==+w.zoom&&(xt=!0,it.zoom=+w.zoom),w.center!==void 0&&(it.center=m.LngLat.convert(w.center)),"bearing"in w&&it.bearing!==+w.bearing&&(Dt=!0,it.bearing=+w.bearing),"pitch"in w&&it.pitch!==+w.pitch&&(Ot=!0,it.pitch=+w.pitch),w.padding==null||it.isPaddingEqual(w.padding)||(it.padding=w.padding),w.preloadOnly?(this._preloadTiles(it),this):(this.fire(new m.Event("movestart",se)).fire(new m.Event("move",se)),xt&&this.fire(new m.Event("zoomstart",se)).fire(new m.Event("zoom",se)).fire(new m.Event("zoomend",se)),Dt&&this.fire(new m.Event("rotatestart",se)).fire(new m.Event("rotate",se)).fire(new m.Event("rotateend",se)),Ot&&this.fire(new m.Event("pitchstart",se)).fire(new m.Event("pitch",se)).fire(new m.Event("pitchend",se)),this.fire(new m.Event("moveend",se)))}getFreeCameraOptions(){return this.transform.projection.supportsFreeCamera||m.warnOnce(pd),this.transform.getFreeCameraOptions()}setFreeCameraOptions(w,se){const it=this.transform;if(!it.projection.supportsFreeCamera)return m.warnOnce(pd),this;this.stop();const xt=it.zoom,Dt=it.pitch,Ot=it.bearing;it.setFreeCameraOptions(w);const rn=xt!==it.zoom,Tn=Dt!==it.pitch,kn=Ot!==it.bearing;return this.fire(new m.Event("movestart",se)).fire(new m.Event("move",se)),rn&&this.fire(new m.Event("zoomstart",se)).fire(new m.Event("zoom",se)).fire(new m.Event("zoomend",se)),kn&&this.fire(new m.Event("rotatestart",se)).fire(new m.Event("rotate",se)).fire(new m.Event("rotateend",se)),Tn&&this.fire(new m.Event("pitchstart",se)).fire(new m.Event("pitch",se)).fire(new m.Event("pitchend",se)),this.fire(new m.Event("moveend",se)),this}easeTo(w,se){this._stop(!1,w.easeId),((w=m.extend({offset:[0,0],duration:500,easing:m.ease},w)).animate===!1||!w.essential&&m.exported.prefersReducedMotion)&&(w.duration=0);const it=this.transform,xt=this.getZoom(),Dt=this.getBearing(),Ot=this.getPitch(),rn=this.getPadding(),Tn="zoom"in w?+w.zoom:xt,kn="bearing"in w?this._normalizeBearing(w.bearing,Dt):Dt,Bn="pitch"in w?+w.pitch:Ot,Wn="padding"in w?w.padding:it.padding,Fr=m.pointGeometry.convert(w.offset);let ri,Zr,Sr;if(it.projection.name==="globe"){const qa=m.MercatorCoordinate.fromLngLat(it.center),ja=Fr.rotate(-it.angle);qa.x+=ja.x/it.worldSize,qa.y+=ja.y/it.worldSize;const To=qa.toLngLat(),na=m.LngLat.convert(w.center||To);this._normalizeCenter(na),ri=it.centerPoint.add(ja),Zr=new m.pointGeometry(qa.x,qa.y).mult(it.worldSize),Sr=new m.pointGeometry(m.mercatorXfromLng(na.lng),m.mercatorYfromLat(na.lat)).mult(it.worldSize).sub(Zr)}else{ri=it.centerPoint.add(Fr);const qa=it.pointLocation(ri),ja=m.LngLat.convert(w.center||qa);this._normalizeCenter(ja),Zr=it.project(qa),Sr=it.project(ja).sub(Zr)}const Di=it.zoomScale(Tn-xt);let di,wi;w.around&&(di=m.LngLat.convert(w.around),wi=it.locationPoint(di));const Ti=this._zooming||Tn!==xt,Oi=this._rotating||Dt!==kn,_i=this._pitching||Bn!==Ot,Fi=!it.isPaddingEqual(Wn),Ta=qa=>ja=>{if(Ti&&(qa.zoom=m.number(xt,Tn,ja)),Oi&&(qa.bearing=m.number(Dt,kn,ja)),_i&&(qa.pitch=m.number(Ot,Bn,ja)),Fi&&(qa.interpolatePadding(rn,Wn,ja),ri=qa.centerPoint.add(Fr)),di)qa.setLocationAtPoint(di,wi);else{const To=qa.zoomScale(qa.zoom-xt),na=Tn>xt?Math.min(2,Di):Math.max(.5,Di),Eo=Math.pow(na,1-ja),So=qa.unproject(Zr.add(Sr.mult(ja*Eo)).mult(To));qa.setLocationAtPoint(qa.renderWorldCopies?So.wrap():So,ri)}return w.preloadOnly||this._fireMoveEvents(se),qa};if(w.preloadOnly){const qa=this._emulate(Ta,w.duration,it);return this._preloadTiles(qa),this}const Fa={moving:this._moving,zooming:this._zooming,rotating:this._rotating,pitching:this._pitching};return this._zooming=Ti,this._rotating=Oi,this._pitching=_i,this._padding=Fi,this._easeId=w.easeId,this._prepareEase(se,w.noMoveStart,Fa),this._ease(Ta(it),qa=>{it.recenterOnTerrain(),this._afterEase(se,qa)},w),this}_prepareEase(w,se,it={}){this._moving=!0,this.transform.cameraElevationReference="sea",se||it.moving||this.fire(new m.Event("movestart",w)),this._zooming&&!it.zooming&&this.fire(new m.Event("zoomstart",w)),this._rotating&&!it.rotating&&this.fire(new m.Event("rotatestart",w)),this._pitching&&!it.pitching&&this.fire(new m.Event("pitchstart",w))}_fireMoveEvents(w){this.fire(new m.Event("move",w)),this._zooming&&this.fire(new m.Event("zoom",w)),this._rotating&&this.fire(new m.Event("rotate",w)),this._pitching&&this.fire(new m.Event("pitch",w))}_afterEase(w,se){if(this._easeId&&se&&this._easeId===se)return;this._easeId=void 0,this.transform.cameraElevationReference="ground";const it=this._zooming,xt=this._rotating,Dt=this._pitching;this._moving=!1,this._zooming=!1,this._rotating=!1,this._pitching=!1,this._padding=!1,it&&this.fire(new m.Event("zoomend",w)),xt&&this.fire(new m.Event("rotateend",w)),Dt&&this.fire(new m.Event("pitchend",w)),this.fire(new m.Event("moveend",w))}flyTo(w,se){if(!w.essential&&m.exported.prefersReducedMotion){const hs=m.pick(w,["center","zoom","bearing","pitch","around"]);return this.jumpTo(hs,se)}this.stop(),w=m.extend({offset:[0,0],speed:1.2,curve:1.42,easing:m.ease},w);const it=this.transform,xt=this.getZoom(),Dt=this.getBearing(),Ot=this.getPitch(),rn=this.getPadding(),Tn="zoom"in w?m.clamp(+w.zoom,it.minZoom,it.maxZoom):xt,kn="bearing"in w?this._normalizeBearing(w.bearing,Dt):Dt,Bn="pitch"in w?+w.pitch:Ot,Wn="padding"in w?w.padding:it.padding,Fr=it.zoomScale(Tn-xt),ri=m.pointGeometry.convert(w.offset);let Zr=it.centerPoint.add(ri);const Sr=it.pointLocation(Zr),Di=m.LngLat.convert(w.center||Sr);this._normalizeCenter(Di);const di=it.project(Sr),wi=it.project(Di).sub(di);let Ti=w.curve;const Oi=Math.max(it.width,it.height),_i=Oi/Fr,Fi=wi.mag();if("minZoom"in w){const hs=m.clamp(Math.min(w.minZoom,xt,Tn),it.minZoom,it.maxZoom),ps=Oi/it.zoomScale(hs-xt);Ti=Math.sqrt(ps/Fi*2)}const Ta=Ti*Ti;function Fa(hs){const ps=(_i*_i-Oi*Oi+(hs?-1:1)*Ta*Ta*Fi*Fi)/(2*(hs?_i:Oi)*Ta*Fi);return Math.log(Math.sqrt(ps*ps+1)-ps)}function qa(hs){return(Math.exp(hs)-Math.exp(-hs))/2}function ja(hs){return(Math.exp(hs)+Math.exp(-hs))/2}const To=Fa(0);let na=function(hs){return ja(To)/ja(To+Ti*hs)},Eo=function(hs){return Oi*((ja(To)*(qa(ps=To+Ti*hs)/ja(ps))-qa(To))/Ta)/Fi;var ps},So=(Fa(1)-To)/Ti;if(Math.abs(Fi)<1e-6||!isFinite(So)){if(Math.abs(Oi-_i)<1e-6)return this.easeTo(w,se);const hs=_i<Oi?-1:1;So=Math.abs(Math.log(_i/Oi))/Ti,Eo=function(){return 0},na=function(ps){return Math.exp(hs*Ti*ps)}}w.duration="duration"in w?+w.duration:1e3*So/("screenSpeed"in w?+w.screenSpeed/Ti:+w.speed),w.maxDuration&&w.duration>w.maxDuration&&(w.duration=0);const Qo=Dt!==kn,Za=Bn!==Ot,rs=!it.isPaddingEqual(Wn),is=hs=>ps=>{const Js=ps*So,fl=1/na(Js);hs.zoom=ps===1?Tn:xt+hs.scaleZoom(fl),Qo&&(hs.bearing=m.number(Dt,kn,ps)),Za&&(hs.pitch=m.number(Ot,Bn,ps)),rs&&(hs.interpolatePadding(rn,Wn,ps),Zr=hs.centerPoint.add(ri));const as=ps===1?Di:hs.unproject(di.add(wi.mult(Eo(Js))).mult(fl));return hs.setLocationAtPoint(hs.renderWorldCopies?as.wrap():as,Zr),hs._updateCameraOnTerrain(),w.preloadOnly||this._fireMoveEvents(se),hs};if(w.preloadOnly){const hs=this._emulate(is,w.duration,it);return this._preloadTiles(hs),this}return this._zooming=!0,this._rotating=Qo,this._pitching=Za,this._padding=rs,this._prepareEase(se,!1),this._ease(is(it),()=>this._afterEase(se),w),this}isEasing(){return!!this._easeFrameId}stop(){return this._stop()}_stop(w,se){if(this._easeFrameId&&(this._cancelRenderFrame(this._easeFrameId),this._easeFrameId=void 0,this._onEaseFrame=void 0),this._onEaseEnd){const it=this._onEaseEnd;this._onEaseEnd=void 0,it.call(this,se)}if(!w){const it=this.handlers;it&&it.stop(!1)}return this}_ease(w,se,it){it.animate===!1||it.duration===0?(w(1),se()):(this._easeStart=m.exported.now(),this._easeOptions=it,this._onEaseFrame=w,this._onEaseEnd=se,this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback))}_renderFrameCallback(){const w=Math.min((m.exported.now()-this._easeStart)/this._easeOptions.duration,1),se=this._onEaseFrame;se&&se(this._easeOptions.easing(w)),w<1?this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback):this.stop()}_normalizeBearing(w,se){w=m.wrap(w,-180,180);const it=Math.abs(w-se);return Math.abs(w-360-se)<it&&(w-=360),Math.abs(w+360-se)<it&&(w+=360),w}_normalizeCenter(w){const se=this.transform;if(!se.renderWorldCopies||se.maxBounds)return;const it=w.lng-se.center.lng;w.lng+=it>180?-360:it<-180?360:0}_emulate(w,se,it){const xt=Math.ceil(15*se/1e3),Dt=[],Ot=w(it.clone());for(let rn=0;rn<=xt;rn++){const Tn=Ot(rn/xt);Dt.push(Tn.clone())}return Dt}}class Np{constructor(w={}){this.options=w,m.bindAll(["_toggleAttribution","_updateEditLink","_updateData","_updateCompact"],this)}getDefaultPosition(){return"bottom-right"}onAdd(w){const se=this.options&&this.options.compact;return this._map=w,this._container=q("div","mapboxgl-ctrl mapboxgl-ctrl-attrib"),this._compactButton=q("button","mapboxgl-ctrl-attrib-button",this._container),q("span","mapboxgl-ctrl-icon",this._compactButton).setAttribute("aria-hidden","true"),this._compactButton.type="button",this._compactButton.addEventListener("click",this._toggleAttribution),this._setElementTitle(this._compactButton,"ToggleAttribution"),this._innerContainer=q("div","mapboxgl-ctrl-attrib-inner",this._container),this._innerContainer.setAttribute("role","list"),se&&this._container.classList.add("mapboxgl-compact"),this._updateAttributions(),this._updateEditLink(),this._map.on("styledata",this._updateData),this._map.on("sourcedata",this._updateData),this._map.on("moveend",this._updateEditLink),se===void 0&&(this._map.on("resize",this._updateCompact),this._updateCompact()),this._container}onRemove(){this._container.remove(),this._map.off("styledata",this._updateData),this._map.off("sourcedata",this._updateData),this._map.off("moveend",this._updateEditLink),this._map.off("resize",this._updateCompact),this._map=void 0,this._attribHTML=void 0}_setElementTitle(w,se){const it=this._map._getUIString(`AttributionControl.${se}`);w.setAttribute("aria-label",it),w.removeAttribute("title"),w.firstElementChild&&w.firstElementChild.setAttribute("title",it)}_toggleAttribution(){this._container.classList.contains("mapboxgl-compact-show")?(this._container.classList.remove("mapboxgl-compact-show"),this._compactButton.setAttribute("aria-expanded","false")):(this._container.classList.add("mapboxgl-compact-show"),this._compactButton.setAttribute("aria-expanded","true"))}_updateEditLink(){let w=this._editLink;w||(w=this._editLink=this._container.querySelector(".mapbox-improve-map"));const se=[{key:"owner",value:this.styleOwner},{key:"id",value:this.styleId},{key:"access_token",value:this._map._requestManager._customAccessToken||m.config.ACCESS_TOKEN}];if(w){const it=se.reduce((xt,Dt,Ot)=>(Dt.value&&(xt+=`${Dt.key}=${Dt.value}${Ot<se.length-1?"&":""}`),xt),"?");w.href=`${m.config.FEEDBACK_URL}/${it}${this._map._hash?this._map._hash.getHashString(!0):""}`,w.rel="noopener nofollow",this._setElementTitle(w,"MapFeedback")}}_updateData(w){!w||w.sourceDataType!=="metadata"&&w.sourceDataType!=="visibility"&&w.dataType!=="style"||(this._updateAttributions(),this._updateEditLink())}_updateAttributions(){if(!this._map.style)return;let w=[];if(this._map.style.stylesheet){const xt=this._map.style.stylesheet;this.styleOwner=xt.owner,this.styleId=xt.id}const se=this._map.style._sourceCaches;for(const xt in se){const Dt=se[xt];if(Dt.used){const Ot=Dt.getSource();Ot.attribution&&w.indexOf(Ot.attribution)<0&&w.push(Ot.attribution)}}w.sort((xt,Dt)=>xt.length-Dt.length),w=w.filter((xt,Dt)=>{for(let Ot=Dt+1;Ot<w.length;Ot++)if(w[Ot].indexOf(xt)>=0)return!1;return!0}),this.options.customAttribution&&(Array.isArray(this.options.customAttribution)?w=[...this.options.customAttribution,...w]:w.unshift(this.options.customAttribution));const it=w.join(" | ");it!==this._attribHTML&&(this._attribHTML=it,w.length?(this._innerContainer.innerHTML=it,this._container.classList.remove("mapboxgl-attrib-empty")):this._container.classList.add("mapboxgl-attrib-empty"),this._editLink=null)}_updateCompact(){this._map.getCanvasContainer().offsetWidth<=640?this._container.classList.add("mapboxgl-compact"):this._container.classList.remove("mapboxgl-compact","mapboxgl-compact-show")}}class Im{constructor(){m.bindAll(["_updateLogo","_updateCompact"],this)}onAdd(w){this._map=w,this._container=q("div","mapboxgl-ctrl");const se=q("a","mapboxgl-ctrl-logo");return se.target="_blank",se.rel="noopener nofollow",se.href="https://www.mapbox.com/",se.setAttribute("aria-label",this._map._getUIString("LogoControl.Title")),se.setAttribute("rel","noopener nofollow"),this._container.appendChild(se),this._container.style.display="none",this._map.on("sourcedata",this._updateLogo),this._updateLogo(),this._map.on("resize",this._updateCompact),this._updateCompact(),this._container}onRemove(){this._container.remove(),this._map.off("sourcedata",this._updateLogo),this._map.off("resize",this._updateCompact)}getDefaultPosition(){return"bottom-left"}_updateLogo(w){w&&w.sourceDataType!=="metadata"||(this._container.style.display=this._logoRequired()?"block":"none")}_logoRequired(){if(!this._map.style)return!0;const w=this._map.style._sourceCaches;if(Object.entries(w).length===0)return!0;for(const se in w){const it=w[se].getSource();if(it.hasOwnProperty("mapbox_logo")&&!it.mapbox_logo)return!1}return!0}_updateCompact(){const w=this._container.children;if(w.length){const se=w[0];this._map.getCanvasContainer().offsetWidth<250?se.classList.add("mapboxgl-compact"):se.classList.remove("mapboxgl-compact")}}}class Rh{constructor(){this._queue=[],this._id=0,this._cleared=!1,this._currentlyRunning=!1}add(w){const se=++this._id;return this._queue.push({callback:w,id:se,cancelled:!1}),se}remove(w){const se=this._currentlyRunning,it=se?this._queue.concat(se):this._queue;for(const xt of it)if(xt.id===w)return void(xt.cancelled=!0)}run(w=0){const se=this._currentlyRunning=this._queue;this._queue=[];for(const it of se)if(!it.cancelled&&(it.callback(w),this._cleared))break;this._cleared=!1,this._currentlyRunning=!1}clear(){this._currentlyRunning&&(this._cleared=!0),this._queue=[]}}function bd(Ee,w,se){if(Ee=new m.LngLat(Ee.lng,Ee.lat),w){const it=new m.LngLat(Ee.lng-360,Ee.lat),xt=new m.LngLat(Ee.lng+360,Ee.lat),Dt=360*Math.ceil(Math.abs(Ee.lng-se.center.lng)/360),Ot=se.locationPoint(Ee).distSqr(w),rn=w.x<0||w.y<0||w.x>se.width||w.y>se.height;se.locationPoint(it).distSqr(w)<Ot&&(rn||Math.abs(it.lng-se.center.lng)<Dt)?Ee=it:se.locationPoint(xt).distSqr(w)<Ot&&(rn||Math.abs(xt.lng-se.center.lng)<Dt)&&(Ee=xt)}for(;Math.abs(Ee.lng-se.center.lng)>180;){const it=se.locationPoint(Ee);if(it.x>=0&&it.y>=0&&it.x<=se.width&&it.y<=se.height)break;Ee.lng>se.center.lng?Ee.lng-=360:Ee.lng+=360}return Ee}const sd={center:"translate(-50%,-50%)",top:"translate(-50%,0)","top-left":"translate(0,0)","top-right":"translate(-100%,0)",bottom:"translate(-50%,-100%)","bottom-left":"translate(0,-100%)","bottom-right":"translate(-100%,-100%)",left:"translate(0,-50%)",right:"translate(-100%,-50%)"};class of extends m.Evented{constructor(w,se){if(super(),(w instanceof m.window.HTMLElement||se)&&(w=m.extend({element:w},se)),m.bindAll(["_update","_onMove","_onUp","_addDragHandler","_onMapClick","_onKeyPress","_clearFadeTimer"],this),this._anchor=w&&w.anchor||"center",this._color=w&&w.color||"#3FB1CE",this._scale=w&&w.scale||1,this._draggable=w&&w.draggable||!1,this._clickTolerance=w&&w.clickTolerance||0,this._isDragging=!1,this._state="inactive",this._rotation=w&&w.rotation||0,this._rotationAlignment=w&&w.rotationAlignment||"auto",this._pitchAlignment=w&&w.pitchAlignment&&w.pitchAlignment!=="auto"?w.pitchAlignment:this._rotationAlignment,this._updateMoving=()=>this._update(!0),w&&w.element)this._element=w.element,this._offset=m.pointGeometry.convert(w&&w.offset||[0,0]);else{this._defaultMarker=!0,this._element=q("div");const xt=41,Dt=27,Ot=J("svg",{display:"block",height:xt*this._scale+"px",width:Dt*this._scale+"px",viewBox:`0 0 ${Dt} ${xt}`},this._element),rn=J("radialGradient",{id:"shadowGradient"},J("defs",{},Ot));J("stop",{offset:"10%","stop-opacity":.4},rn),J("stop",{offset:"100%","stop-opacity":.05},rn),J("ellipse",{cx:13.5,cy:34.8,rx:10.5,ry:5.25,fill:"url(#shadowGradient)"},Ot),J("path",{fill:this._color,d:"M27,13.5C27,19.07 20.25,27 14.75,34.5C14.02,35.5 12.98,35.5 12.25,34.5C6.75,27 0,19.22 0,13.5C0,6.04 6.04,0 13.5,0C20.96,0 27,6.04 27,13.5Z"},Ot),J("path",{opacity:.25,d:"M13.5,0C6.04,0 0,6.04 0,13.5C0,19.22 6.75,27 12.25,34.5C13,35.52 14.02,35.5 14.75,34.5C20.25,27 27,19.07 27,13.5C27,6.04 20.96,0 13.5,0ZM13.5,1C20.42,1 26,6.58 26,13.5C26,15.9 24.5,19.18 22.22,22.74C19.95,26.3 16.71,30.14 13.94,33.91C13.74,34.18 13.61,34.32 13.5,34.44C13.39,34.32 13.26,34.18 13.06,33.91C10.28,30.13 7.41,26.31 5.02,22.77C2.62,19.23 1,15.95 1,13.5C1,6.58 6.58,1 13.5,1Z"},Ot),J("circle",{fill:"white",cx:13.5,cy:13.5,r:5.5},Ot),this._offset=m.pointGeometry.convert(w&&w.offset||[0,-14])}this._element.hasAttribute("aria-label")||this._element.setAttribute("aria-label","Map marker"),this._element.classList.add("mapboxgl-marker"),this._element.addEventListener("dragstart",xt=>{xt.preventDefault()}),this._element.addEventListener("mousedown",xt=>{xt.preventDefault()});const it=this._element.classList;for(const xt in sd)it.remove(`mapboxgl-marker-anchor-${xt}`);it.add(`mapboxgl-marker-anchor-${this._anchor}`),this._popup=null}addTo(w){return w===this._map||(this.remove(),this._map=w,w.getCanvasContainer().appendChild(this._element),w.on("move",this._updateMoving),w.on("moveend",this._update),w.on("remove",this._clearFadeTimer),w._addMarker(this),this.setDraggable(this._draggable),this._update(),w.on("click",this._onMapClick)),this}remove(){const w=this._map;return w&&(w.off("click",this._onMapClick),w.off("move",this._updateMoving),w.off("moveend",this._update),w.off("mousedown",this._addDragHandler),w.off("touchstart",this._addDragHandler),w.off("mouseup",this._onUp),w.off("touchend",this._onUp),w.off("mousemove",this._onMove),w.off("touchmove",this._onMove),w.off("remove",this._clearFadeTimer),w._removeMarker(this),this._map=void 0),this._clearFadeTimer(),this._element.remove(),this._popup&&this._popup.remove(),this}getLngLat(){return this._lngLat}setLngLat(w){return this._lngLat=m.LngLat.convert(w),this._pos=null,this._popup&&this._popup.setLngLat(this._lngLat),this._update(!0),this}getElement(){return this._element}setPopup(w){if(this._popup&&(this._popup.remove(),this._popup=null,this._element.removeAttribute("role"),this._element.removeEventListener("keypress",this._onKeyPress),this._originalTabIndex||this._element.removeAttribute("tabindex")),w){if(!("offset"in w.options)){const xt=Math.sqrt(Math.pow(13.5,2)/2);w.options.offset=this._defaultMarker?{top:[0,0],"top-left":[0,0],"top-right":[0,0],bottom:[0,-38.1],"bottom-left":[xt,-1*(38.1-13.5+xt)],"bottom-right":[-xt,-1*(38.1-13.5+xt)],left:[13.5,-1*(38.1-13.5)],right:[-13.5,-1*(38.1-13.5)]}:this._offset}this._popup=w,this._lngLat&&this._popup.setLngLat(this._lngLat),this._element.setAttribute("role","button"),this._originalTabIndex=this._element.getAttribute("tabindex"),this._originalTabIndex||this._element.setAttribute("tabindex","0"),this._element.addEventListener("keypress",this._onKeyPress),this._element.setAttribute("aria-expanded","false")}return this}_onKeyPress(w){const se=w.code,it=w.charCode||w.keyCode;se!=="Space"&&se!=="Enter"&&it!==32&&it!==13||this.togglePopup()}_onMapClick(w){const se=w.originalEvent.target,it=this._element;this._popup&&(se===it||it.contains(se))&&this.togglePopup()}getPopup(){return this._popup}togglePopup(){const w=this._popup;return w?(w.isOpen()?(w.remove(),this._element.setAttribute("aria-expanded","false")):this._map&&(w.addTo(this._map),this._element.setAttribute("aria-expanded","true")),this):this}_evaluateOpacity(){const w=this._map;if(!w)return;const se=this._pos;if(!se||se.x<0||se.x>w.transform.width||se.y<0||se.y>w.transform.height)return void this._clearFadeTimer();const it=w.unproject(se);let xt=!1;if(w.transform._terrainEnabled()&&w.getTerrain()){const Ot=w.getFreeCameraOptions();if(Ot.position){const rn=Ot.position.toLngLat();xt=rn.distanceTo(it)<.9*rn.distanceTo(this._lngLat)}}const Dt=(1-w._queryFogOpacity(it))*(xt?.2:1);this._element.style.opacity=`${Dt}`,this._popup&&this._popup._setOpacity(`${Dt}`),this._fadeTimer=null}_clearFadeTimer(){this._fadeTimer&&(clearTimeout(this._fadeTimer),this._fadeTimer=null)}_updateDOM(){const w=this._pos;if(!w)return;const se=this._offset.mult(this._scale),it=this._calculatePitch(),xt=this._calculateRotation();this._element.style.transform=`
- translate(${w.x}px, ${w.y}px) ${sd[this._anchor]}
- rotateX(${it}deg) rotateZ(${xt}deg)
- translate(${se.x}px, ${se.y}px)
- `}_calculatePitch(){return this._pitchAlignment==="viewport"||this._pitchAlignment==="auto"?0:this._map&&this._pitchAlignment==="map"?this._map.getPitch():0}_calculateRotation(){return this._rotationAlignment==="viewport"||this._rotationAlignment==="auto"?this._rotation:this._map&&this._rotationAlignment==="map"?this._rotation-this._map.getBearing():0}_update(w){m.window.cancelAnimationFrame(this._updateFrameId);const se=this._map;se&&(se.transform.renderWorldCopies&&(this._lngLat=bd(this._lngLat,this._pos,se.transform)),this._pos=se.project(this._lngLat),w===!0?this._updateFrameId=m.window.requestAnimationFrame(()=>{this._element&&this._pos&&this._anchor&&(this._pos=this._pos.round(),this._updateDOM())}):this._pos=this._pos.round(),se._requestDomTask(()=>{this._map&&(this._element&&this._pos&&this._anchor&&this._updateDOM(),!se.getTerrain()&&!se.getFog()||this._fadeTimer||(this._fadeTimer=setTimeout(this._evaluateOpacity.bind(this),60)))}))}getOffset(){return this._offset}setOffset(w){return this._offset=m.pointGeometry.convert(w),this._update(),this}_onMove(w){const se=this._map;if(se){if(!this._isDragging){const it=this._clickTolerance||se._clickTolerance;this._isDragging=w.point.dist(this._pointerdownPos)>=it}this._isDragging&&(this._pos=w.point.sub(this._positionDelta),this._lngLat=se.unproject(this._pos),this.setLngLat(this._lngLat),this._element.style.pointerEvents="none",this._state==="pending"&&(this._state="active",this.fire(new m.Event("dragstart"))),this.fire(new m.Event("drag")))}}_onUp(){this._element.style.pointerEvents="auto",this._positionDelta=null,this._pointerdownPos=null,this._isDragging=!1;const w=this._map;w&&(w.off("mousemove",this._onMove),w.off("touchmove",this._onMove)),this._state==="active"&&this.fire(new m.Event("dragend")),this._state="inactive"}_addDragHandler(w){const se=this._map;se&&this._element.contains(w.originalEvent.target)&&(w.preventDefault(),this._positionDelta=w.point.sub(this._pos),this._pointerdownPos=w.point,this._state="pending",se.on("mousemove",this._onMove),se.on("touchmove",this._onMove),se.once("mouseup",this._onUp),se.once("touchend",this._onUp))}setDraggable(w){this._draggable=!!w;const se=this._map;return se&&(w?(se.on("mousedown",this._addDragHandler),se.on("touchstart",this._addDragHandler)):(se.off("mousedown",this._addDragHandler),se.off("touchstart",this._addDragHandler))),this}isDraggable(){return this._draggable}setRotation(w){return this._rotation=w||0,this._update(),this}getRotation(){return this._rotation}setRotationAlignment(w){return this._rotationAlignment=w||"auto",this._update(),this}getRotationAlignment(){return this._rotationAlignment}setPitchAlignment(w){return this._pitchAlignment=w&&w!=="auto"?w:this._rotationAlignment,this._update(),this}getPitchAlignment(){return this._pitchAlignment}}class Rm{constructor(w){this.jumpTo(w)}getValue(w){if(w<=this._startTime)return this._start;if(w>=this._endTime)return this._end;const se=m.easeCubicInOut((w-this._startTime)/(this._endTime-this._startTime));return this._start*(1-se)+this._end*se}isEasing(w){return w>=this._startTime&&w<=this._endTime}jumpTo(w){this._startTime=-1/0,this._endTime=-1/0,this._start=w,this._end=w}easeTo(w,se,it){this._start=this.getValue(se),this._end=w,this._startTime=se,this._endTime=se+it}}const Om={"AttributionControl.ToggleAttribution":"Toggle attribution","AttributionControl.MapFeedback":"Map feedback","FullscreenControl.Enter":"Enter fullscreen","FullscreenControl.Exit":"Exit fullscreen","GeolocateControl.FindMyLocation":"Find my location","GeolocateControl.LocationNotAvailable":"Location not available","LogoControl.Title":"Mapbox logo","NavigationControl.ResetBearing":"Reset bearing to north","NavigationControl.ZoomIn":"Zoom in","NavigationControl.ZoomOut":"Zoom out","ScaleControl.Feet":"ft","ScaleControl.Meters":"m","ScaleControl.Kilometers":"km","ScaleControl.Miles":"mi","ScaleControl.NauticalMiles":"nm","ScrollZoomBlocker.CtrlMessage":"Use ctrl + scroll to zoom the map","ScrollZoomBlocker.CmdMessage":"Use ⌘ + scroll to zoom the map","TouchPanBlocker.Message":"Use two fingers to move the map"},Oh={center:[0,0],zoom:0,bearing:0,pitch:0,minZoom:-2,maxZoom:22,minPitch:0,maxPitch:85,interactive:!0,scrollZoom:!0,boxZoom:!0,dragRotate:!0,dragPan:!0,keyboard:!0,doubleClickZoom:!0,touchZoomRotate:!0,touchPitch:!0,cooperativeGestures:!1,bearingSnap:7,clickTolerance:3,pitchWithRotate:!0,hash:!1,attributionControl:!0,failIfMajorPerformanceCaveat:!1,preserveDrawingBuffer:!1,trackResize:!0,optimizeForTerrain:!0,renderWorldCopies:!0,refreshExpiredTiles:!0,minTileCacheSize:null,maxTileCacheSize:null,localIdeographFontFamily:"sans-serif",localFontFamily:null,transformRequest:null,accessToken:null,fadeDuration:300,crossSourceCollisions:!0};function Ef(Ee){Ee.parentNode&&Ee.parentNode.removeChild(Ee)}const Lh={showCompass:!0,showZoom:!0,visualizePitch:!1};class Kf{constructor(w,se,it=!1){this._clickTolerance=10,this.element=se,this.mouseRotate=new kh({clickTolerance:w.dragRotate._mouseRotate._clickTolerance}),this.map=w,it&&(this.mousePitch=new Tf({clickTolerance:w.dragRotate._mousePitch._clickTolerance})),m.bindAll(["mousedown","mousemove","mouseup","touchstart","touchmove","touchend","reset"],this),se.addEventListener("mousedown",this.mousedown),se.addEventListener("touchstart",this.touchstart,{passive:!1}),se.addEventListener("touchmove",this.touchmove),se.addEventListener("touchend",this.touchend),se.addEventListener("touchcancel",this.reset)}down(w,se){this.mouseRotate.mousedown(w,se),this.mousePitch&&this.mousePitch.mousedown(w,se),Ue()}move(w,se){const it=this.map,xt=this.mouseRotate.mousemoveWindow(w,se),Dt=xt&&xt.bearingDelta;if(Dt&&it.setBearing(it.getBearing()+Dt),this.mousePitch){const Ot=this.mousePitch.mousemoveWindow(w,se),rn=Ot&&Ot.pitchDelta;rn&&it.setPitch(it.getPitch()+rn)}}off(){const w=this.element;w.removeEventListener("mousedown",this.mousedown),w.removeEventListener("touchstart",this.touchstart,{passive:!1}),w.removeEventListener("touchmove",this.touchmove),w.removeEventListener("touchend",this.touchend),w.removeEventListener("touchcancel",this.reset),this.offTemp()}offTemp(){De(),m.window.removeEventListener("mousemove",this.mousemove),m.window.removeEventListener("mouseup",this.mouseup)}mousedown(w){this.down(m.extend({},w,{ctrlKey:!0,preventDefault:()=>w.preventDefault()}),Ae(this.element,w)),m.window.addEventListener("mousemove",this.mousemove),m.window.addEventListener("mouseup",this.mouseup)}mousemove(w){this.move(w,Ae(this.element,w))}mouseup(w){this.mouseRotate.mouseupWindow(w),this.mousePitch&&this.mousePitch.mouseupWindow(w),this.offTemp()}touchstart(w){w.targetTouches.length!==1?this.reset():(this._startPos=this._lastPos=Te(this.element,w.targetTouches)[0],this.down({type:"mousedown",button:0,ctrlKey:!0,preventDefault:()=>w.preventDefault()},this._startPos))}touchmove(w){w.targetTouches.length!==1?this.reset():(this._lastPos=Te(this.element,w.targetTouches)[0],this.move({preventDefault:()=>w.preventDefault()},this._lastPos))}touchend(w){w.targetTouches.length===0&&this._startPos&&this._lastPos&&this._startPos.dist(this._lastPos)<this._clickTolerance&&this.element.click(),this.reset()}reset(){this.mouseRotate.reset(),this.mousePitch&&this.mousePitch.reset(),delete this._startPos,delete this._lastPos,this.offTemp()}}const Fd={positionOptions:{enableHighAccuracy:!1,maximumAge:0,timeout:6e3},fitBoundsOptions:{maxZoom:15},trackUserLocation:!1,showAccuracyCircle:!0,showUserLocation:!0,showUserHeading:!1};let Bd,sf=0,mp=!1;const Xf={maxWidth:100,unit:"metric"};function Af(Ee,w,se){const it=se&&se.maxWidth||100,xt=Ee._containerHeight/2,Dt=Ee._containerWidth/2-it/2,Ot=Ee.unproject([Dt,xt]),rn=Ee.unproject([Dt+it,xt]),Tn=Ot.distanceTo(rn);if(se&&se.unit==="imperial"){const kn=3.2808*Tn;kn>5280?Qc(w,it,kn/5280,Ee._getUIString("ScaleControl.Miles"),Ee):Qc(w,it,kn,Ee._getUIString("ScaleControl.Feet"),Ee)}else se&&se.unit==="nautical"?Qc(w,it,Tn/1852,Ee._getUIString("ScaleControl.NauticalMiles"),Ee):Tn>=1e3?Qc(w,it,Tn/1e3,Ee._getUIString("ScaleControl.Kilometers"),Ee):Qc(w,it,Tn,Ee._getUIString("ScaleControl.Meters"),Ee)}function Qc(Ee,w,se,it,xt){const Dt=function(rn){const Tn=Math.pow(10,`${Math.floor(rn)}`.length-1);let kn=rn/Tn;return kn=kn>=10?10:kn>=5?5:kn>=3?3:kn>=2?2:kn>=1?1:function(Bn){const Wn=Math.pow(10,Math.ceil(-Math.log(Bn)/Math.LN10));return Math.round(Bn*Wn)/Wn}(kn),Tn*kn}(se),Ot=Dt/se;xt._requestDomTask(()=>{Ee.style.width=w*Ot+"px",Ee.innerHTML=`${Dt} ${it}`})}const $c={closeButton:!0,closeOnClick:!0,focusAfterOpen:!0,className:"",maxWidth:"240px"},Iu=["a[href]","[tabindex]:not([tabindex='-1'])","[contenteditable]:not([contenteditable='false'])","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].join(", ");function Fh(Ee=new m.pointGeometry(0,0),w="bottom"){if(typeof Ee=="number"){const se=Math.round(Math.sqrt(.5*Math.pow(Ee,2)));switch(w){case"top":return new m.pointGeometry(0,Ee);case"top-left":return new m.pointGeometry(se,se);case"top-right":return new m.pointGeometry(-se,se);case"bottom":return new m.pointGeometry(0,-Ee);case"bottom-left":return new m.pointGeometry(se,-se);case"bottom-right":return new m.pointGeometry(-se,-se);case"left":return new m.pointGeometry(Ee,0);case"right":return new m.pointGeometry(-Ee,0)}return new m.pointGeometry(0,0)}return Ee instanceof m.pointGeometry||Array.isArray(Ee)?m.pointGeometry.convert(Ee):m.pointGeometry.convert(Ee[w]||[0,0])}const zp={version:m.version,supported:O,setRTLTextPlugin:m.setRTLTextPlugin,getRTLTextPluginStatus:m.getRTLTextPluginStatus,Map:class extends gh{constructor(Ee){if((Ee=m.extend({},Oh,Ee)).minZoom!=null&&Ee.maxZoom!=null&&Ee.minZoom>Ee.maxZoom)throw new Error("maxZoom must be greater than or equal to minZoom");if(Ee.minPitch!=null&&Ee.maxPitch!=null&&Ee.minPitch>Ee.maxPitch)throw new Error("maxPitch must be greater than or equal to minPitch");if(Ee.minPitch!=null&&Ee.minPitch<0)throw new Error("minPitch must be greater than or equal to 0");if(Ee.maxPitch!=null&&Ee.maxPitch>85)throw new Error("maxPitch must be less than or equal to 85");if(Ee.antialias&&m.isSafariWithAntialiasingBug(m.window)&&(Ee.antialias=!1,m.warnOnce("Antialiasing is disabled for this WebGL context to avoid browser bug: https://github.com/mapbox/mapbox-gl-js/issues/11609")),super(new hd(Ee.minZoom,Ee.maxZoom,Ee.minPitch,Ee.maxPitch,Ee.renderWorldCopies),Ee),this._interactive=Ee.interactive,this._minTileCacheSize=Ee.minTileCacheSize,this._maxTileCacheSize=Ee.maxTileCacheSize,this._failIfMajorPerformanceCaveat=Ee.failIfMajorPerformanceCaveat,this._preserveDrawingBuffer=Ee.preserveDrawingBuffer,this._antialias=Ee.antialias,this._trackResize=Ee.trackResize,this._bearingSnap=Ee.bearingSnap,this._refreshExpiredTiles=Ee.refreshExpiredTiles,this._fadeDuration=Ee.fadeDuration,this._isInitialLoad=!0,this._crossSourceCollisions=Ee.crossSourceCollisions,this._crossFadingFactor=1,this._collectResourceTiming=Ee.collectResourceTiming,this._optimizeForTerrain=Ee.optimizeForTerrain,this._renderTaskQueue=new Rh,this._domRenderTaskQueue=new Rh,this._controls=[],this._markers=[],this._mapId=m.uniqueId(),this._locale=m.extend({},Om,Ee.locale),this._clickTolerance=Ee.clickTolerance,this._cooperativeGestures=Ee.cooperativeGestures,this._containerWidth=0,this._containerHeight=0,this._averageElevationLastSampledAt=-1/0,this._averageElevationExaggeration=0,this._averageElevation=new Rm(0),this._explicitProjection=null,this._requestManager=new m.RequestManager(Ee.transformRequest,Ee.accessToken,Ee.testMode),this._silenceAuthErrors=!!Ee.testMode,typeof Ee.container=="string"){if(this._container=m.window.document.getElementById(Ee.container),!this._container)throw new Error(`Container '${Ee.container}' not found.`)}else{if(!(Ee.container instanceof m.window.HTMLElement))throw new Error("Invalid type: 'container' must be a String or HTMLElement.");this._container=Ee.container}if(this._container.childNodes.length>0&&m.warnOnce("The map container element should be empty, otherwise the map's interactivity will be negatively impacted. If you want to display a message when WebGL is not supported, use the Mapbox GL Supported plugin instead."),Ee.maxBounds&&this.setMaxBounds(Ee.maxBounds),m.bindAll(["_onWindowOnline","_onWindowResize","_onMapScroll","_contextLost","_contextRestored"],this),this._setupContainer(),this._setupPainter(),this.painter===void 0)throw new Error("Failed to initialize WebGL.");this.on("move",()=>this._update(!1)),this.on("moveend",()=>this._update(!1)),this.on("zoom",()=>this._update(!0)),m.window!==void 0&&(m.window.addEventListener("online",this._onWindowOnline,!1),m.window.addEventListener("resize",this._onWindowResize,!1),m.window.addEventListener("orientationchange",this._onWindowResize,!1),m.window.addEventListener("webkitfullscreenchange",this._onWindowResize,!1)),this.handlers=new Zf(this,Ee),this._localFontFamily=Ee.localFontFamily,this._localIdeographFontFamily=Ee.localIdeographFontFamily,Ee.style&&this.setStyle(Ee.style,{localFontFamily:this._localFontFamily,localIdeographFontFamily:this._localIdeographFontFamily}),Ee.projection&&this.setProjection(Ee.projection),this._hash=Ee.hash&&new Cf(typeof Ee.hash=="string"&&Ee.hash||void 0).addTo(this),this._hash&&this._hash._onHashChange()||(this.jumpTo({center:Ee.center,zoom:Ee.zoom,bearing:Ee.bearing,pitch:Ee.pitch}),Ee.bounds&&(this.resize(),this.fitBounds(Ee.bounds,m.extend({},Ee.fitBoundsOptions,{duration:0})))),this.resize(),Ee.attributionControl&&this.addControl(new Np({customAttribution:Ee.customAttribution})),this._logoControl=new Im,this.addControl(this._logoControl,Ee.logoPosition),this.on("style.load",()=>{this.transform.unmodified&&this.jumpTo(this.style.stylesheet)}),this.on("data",w=>{this._update(w.dataType==="style"),this.fire(new m.Event(`${w.dataType}data`,w))}),this.on("dataloading",w=>{this.fire(new m.Event(`${w.dataType}dataloading`,w))})}_getMapId(){return this._mapId}addControl(Ee,w){if(w===void 0&&(w=Ee.getDefaultPosition?Ee.getDefaultPosition():"top-right"),!Ee||!Ee.onAdd)return this.fire(new m.ErrorEvent(new Error("Invalid argument to map.addControl(). Argument must be a control with onAdd and onRemove methods.")));const se=Ee.onAdd(this);this._controls.push(Ee);const it=this._controlPositions[w];return w.indexOf("bottom")!==-1?it.insertBefore(se,it.firstChild):it.appendChild(se),this}removeControl(Ee){if(!Ee||!Ee.onRemove)return this.fire(new m.ErrorEvent(new Error("Invalid argument to map.removeControl(). Argument must be a control with onAdd and onRemove methods.")));const w=this._controls.indexOf(Ee);return w>-1&&this._controls.splice(w,1),Ee.onRemove(this),this}hasControl(Ee){return this._controls.indexOf(Ee)>-1}getContainer(){return this._container}getCanvasContainer(){return this._canvasContainer}getCanvas(){return this._canvas}resize(Ee){if(this._updateContainerDimensions(),this._containerWidth===this.transform.width&&this._containerHeight===this.transform.height)return this;this._resizeCanvas(this._containerWidth,this._containerHeight),this.transform.resize(this._containerWidth,this._containerHeight),this.painter.resize(Math.ceil(this._containerWidth),Math.ceil(this._containerHeight));const w=!this._moving;return w&&this.fire(new m.Event("movestart",Ee)).fire(new m.Event("move",Ee)),this.fire(new m.Event("resize",Ee)),w&&this.fire(new m.Event("moveend",Ee)),this}getBounds(){return this.transform.getBounds()}getMaxBounds(){return this.transform.getMaxBounds()||null}setMaxBounds(Ee){return this.transform.setMaxBounds(m.LngLatBounds.convert(Ee)),this._update()}setMinZoom(Ee){if((Ee=Ee??-2)>=-2&&Ee<=this.transform.maxZoom)return this.transform.minZoom=Ee,this._update(),this.getZoom()<Ee?this.setZoom(Ee):this.fire(new m.Event("zoomstart")).fire(new m.Event("zoom")).fire(new m.Event("zoomend")),this;throw new Error("minZoom must be between -2 and the current maxZoom, inclusive")}getMinZoom(){return this.transform.minZoom}setMaxZoom(Ee){if((Ee=Ee??22)>=this.transform.minZoom)return this.transform.maxZoom=Ee,this._update(),this.getZoom()>Ee?this.setZoom(Ee):this.fire(new m.Event("zoomstart")).fire(new m.Event("zoom")).fire(new m.Event("zoomend")),this;throw new Error("maxZoom must be greater than the current minZoom")}getMaxZoom(){return this.transform.maxZoom}setMinPitch(Ee){if((Ee=Ee??0)<0)throw new Error("minPitch must be greater than or equal to 0");if(Ee>=0&&Ee<=this.transform.maxPitch)return this.transform.minPitch=Ee,this._update(),this.getPitch()<Ee?this.setPitch(Ee):this.fire(new m.Event("pitchstart")).fire(new m.Event("pitch")).fire(new m.Event("pitchend")),this;throw new Error("minPitch must be between 0 and the current maxPitch, inclusive")}getMinPitch(){return this.transform.minPitch}setMaxPitch(Ee){if((Ee=Ee??85)>85)throw new Error("maxPitch must be less than or equal to 85");if(Ee>=this.transform.minPitch)return this.transform.maxPitch=Ee,this._update(),this.getPitch()>Ee?this.setPitch(Ee):this.fire(new m.Event("pitchstart")).fire(new m.Event("pitch")).fire(new m.Event("pitchend")),this;throw new Error("maxPitch must be greater than the current minPitch")}getMaxPitch(){return this.transform.maxPitch}getRenderWorldCopies(){return this.transform.renderWorldCopies}setRenderWorldCopies(Ee){return this.transform.renderWorldCopies=Ee,this._update()}getProjection(){return this._explicitProjection?this._explicitProjection:this.style&&this.style.stylesheet&&this.style.stylesheet.projection?this.style.stylesheet.projection:{name:"mercator",center:[0,0]}}setProjection(Ee){return this._lazyInitEmptyStyle(),Ee?typeof Ee=="string"&&(Ee={name:Ee}):Ee=null,this._updateProjection(Ee)}_updateProjection(Ee){Ee===null&&(this._explicitProjection=null);const w=Ee||this.getProjection(),se=this.transform.setProjection(w);if(Ee&&(this._explicitProjection=this.transform.getProjection()),se){this.painter.clearBackgroundTiles();for(const it in this.style._sourceCaches)this.style._sourceCaches[it].clearTiles();this.style.applyProjectionUpdate(),this._update(!0)}return this}project(Ee){return this.transform.locationPoint3D(m.LngLat.convert(Ee))}unproject(Ee){return this.transform.pointLocation3D(m.pointGeometry.convert(Ee))}isMoving(){return this._moving||this.handlers&&this.handlers.isMoving()||!1}isZooming(){return this._zooming||this.handlers&&this.handlers.isZooming()||!1}isRotating(){return this._rotating||this.handlers&&this.handlers.isRotating()||!1}_createDelegatedListener(Ee,w,se){if(Ee==="mouseenter"||Ee==="mouseover"){let it=!1;const xt=Ot=>{const rn=w.filter(kn=>this.getLayer(kn)),Tn=rn.length?this.queryRenderedFeatures(Ot.point,{layers:rn}):[];Tn.length?it||(it=!0,se.call(this,new lu(Ee,this,Ot.originalEvent,{features:Tn}))):it=!1},Dt=()=>{it=!1};return{layers:new Set(w),listener:se,delegates:{mousemove:xt,mouseout:Dt}}}if(Ee==="mouseleave"||Ee==="mouseout"){let it=!1;const xt=Ot=>{const rn=w.filter(Tn=>this.getLayer(Tn));(rn.length?this.queryRenderedFeatures(Ot.point,{layers:rn}):[]).length?it=!0:it&&(it=!1,se.call(this,new lu(Ee,this,Ot.originalEvent)))},Dt=Ot=>{it&&(it=!1,se.call(this,new lu(Ee,this,Ot.originalEvent)))};return{layers:new Set(w),listener:se,delegates:{mousemove:xt,mouseout:Dt}}}{const it=xt=>{const Dt=w.filter(rn=>this.getLayer(rn)),Ot=Dt.length?this.queryRenderedFeatures(xt.point,{layers:Dt}):[];Ot.length&&(xt.features=Ot,se.call(this,xt),delete xt.features)};return{layers:new Set(w),listener:se,delegates:{[Ee]:it}}}}on(Ee,w,se){if(se===void 0)return super.on(Ee,w);Array.isArray(w)||(w=[w]);const it=this._createDelegatedListener(Ee,w,se);this._delegatedListeners=this._delegatedListeners||{},this._delegatedListeners[Ee]=this._delegatedListeners[Ee]||[],this._delegatedListeners[Ee].push(it);for(const xt in it.delegates)this.on(xt,it.delegates[xt]);return this}once(Ee,w,se){if(se===void 0)return super.once(Ee,w);Array.isArray(w)||(w=[w]);const it=this._createDelegatedListener(Ee,w,se);for(const xt in it.delegates)this.once(xt,it.delegates[xt]);return this}off(Ee,w,se){if(se===void 0)return super.off(Ee,w);w=new Set(Array.isArray(w)?w:[w]);const it=(Dt,Ot)=>{if(Dt.size!==Ot.size)return!1;for(const rn of Dt)if(!Ot.has(rn))return!1;return!0},xt=this._delegatedListeners?this._delegatedListeners[Ee]:void 0;return xt&&(Dt=>{for(let Ot=0;Ot<Dt.length;Ot++){const rn=Dt[Ot];if(rn.listener===se&&it(rn.layers,w)){for(const Tn in rn.delegates)this.off(Tn,rn.delegates[Tn]);return Dt.splice(Ot,1),this}}})(xt),this}queryRenderedFeatures(Ee,w){return this.style?(w!==void 0||Ee===void 0||Ee instanceof m.pointGeometry||Array.isArray(Ee)||(w=Ee,Ee=void 0),this.style.queryRenderedFeatures(Ee=Ee||[[0,0],[this.transform.width,this.transform.height]],w=w||{},this.transform)):[]}querySourceFeatures(Ee,w){return this.style.querySourceFeatures(Ee,w)}queryTerrainElevation(Ee,w){const se=this.transform.elevation;return se?(w=m.extend({},{exaggerated:!0},w),se.getAtPoint(m.MercatorCoordinate.fromLngLat(Ee),null,w.exaggerated)):null}setStyle(Ee,w){return(w=m.extend({},{localIdeographFontFamily:this._localIdeographFontFamily,localFontFamily:this._localFontFamily},w)).diff!==!1&&w.localIdeographFontFamily===this._localIdeographFontFamily&&w.localFontFamily===this._localFontFamily&&this.style&&Ee?(this._diffStyle(Ee,w),this):(this._localIdeographFontFamily=w.localIdeographFontFamily,this._localFontFamily=w.localFontFamily,this._updateStyle(Ee,w))}_getUIString(Ee){const w=this._locale[Ee];if(w==null)throw new Error(`Missing UI string '${Ee}'`);return w}_updateStyle(Ee,w){return this.style&&(this.style.setEventedParent(null),this.style._remove(),this.style=void 0),Ee&&(this.style=new Ss(this,w||{}),this.style.setEventedParent(this,{style:this.style}),typeof Ee=="string"?this.style.loadURL(Ee):this.style.loadJSON(Ee)),this._updateTerrain(),this}_lazyInitEmptyStyle(){this.style||(this.style=new Ss(this,{}),this.style.setEventedParent(this,{style:this.style}),this.style.loadEmpty())}_diffStyle(Ee,w){if(typeof Ee=="string"){const se=this._requestManager.normalizeStyleURL(Ee),it=this._requestManager.transformRequest(se,m.ResourceType.Style);m.getJSON(it,(xt,Dt)=>{xt?this.fire(new m.ErrorEvent(xt)):Dt&&this._updateDiff(Dt,w)})}else typeof Ee=="object"&&this._updateDiff(Ee,w)}_updateDiff(Ee,w){try{this.style.setState(Ee)&&this._update(!0)}catch(se){m.warnOnce(`Unable to perform style diff: ${se.message||se.error||se}. Rebuilding the style from scratch.`),this._updateStyle(Ee,w)}}getStyle(){if(this.style)return this.style.serialize()}isStyleLoaded(){return this.style?this.style.loaded():(m.warnOnce("There is no style added to the map."),!1)}addSource(Ee,w){return this._lazyInitEmptyStyle(),this.style.addSource(Ee,w),this._update(!0)}isSourceLoaded(Ee){return!!this.style&&this.style._isSourceCacheLoaded(Ee)}areTilesLoaded(){const Ee=this.style&&this.style._sourceCaches;for(const w in Ee){const se=Ee[w]._tiles;for(const it in se){const xt=se[it];if(xt.state!=="loaded"&&xt.state!=="errored")return!1}}return!0}addSourceType(Ee,w,se){this._lazyInitEmptyStyle(),this.style.addSourceType(Ee,w,se)}removeSource(Ee){return this.style.removeSource(Ee),this._updateTerrain(),this._update(!0)}getSource(Ee){return this.style.getSource(Ee)}addImage(Ee,w,{pixelRatio:se=1,sdf:it=!1,stretchX:xt,stretchY:Dt,content:Ot}={}){if(this._lazyInitEmptyStyle(),w instanceof m.window.HTMLImageElement||m.window.ImageBitmap&&w instanceof m.window.ImageBitmap){const{width:rn,height:Tn,data:kn}=m.exported.getImageData(w);this.style.addImage(Ee,{data:new m.RGBAImage({width:rn,height:Tn},kn),pixelRatio:se,stretchX:xt,stretchY:Dt,content:Ot,sdf:it,version:0})}else if(w.width===void 0||w.height===void 0)this.fire(new m.ErrorEvent(new Error("Invalid arguments to map.addImage(). The second argument must be an `HTMLImageElement`, `ImageData`, `ImageBitmap`, or object with `width`, `height`, and `data` properties with the same format as `ImageData`")));else{const{width:rn,height:Tn}=w,kn=w;this.style.addImage(Ee,{data:new m.RGBAImage({width:rn,height:Tn},new Uint8Array(kn.data)),pixelRatio:se,stretchX:xt,stretchY:Dt,content:Ot,sdf:it,version:0,userImage:kn}),kn.onAdd&&kn.onAdd(this,Ee)}}updateImage(Ee,w){const se=this.style.getImage(Ee);if(!se)return void this.fire(new m.ErrorEvent(new Error("The map has no image with that id. If you are adding a new image use `map.addImage(...)` instead.")));const it=w instanceof m.window.HTMLImageElement||m.window.ImageBitmap&&w instanceof m.window.ImageBitmap?m.exported.getImageData(w):w,{width:xt,height:Dt}=it;xt!==void 0&&Dt!==void 0?xt===se.data.width&&Dt===se.data.height?(se.data.replace(it.data,!(w instanceof m.window.HTMLImageElement||m.window.ImageBitmap&&w instanceof m.window.ImageBitmap)),this.style.updateImage(Ee,se)):this.fire(new m.ErrorEvent(new Error("The width and height of the updated image must be that same as the previous version of the image"))):this.fire(new m.ErrorEvent(new Error("Invalid arguments to map.updateImage(). The second argument must be an `HTMLImageElement`, `ImageData`, `ImageBitmap`, or object with `width`, `height`, and `data` properties with the same format as `ImageData`")))}hasImage(Ee){return Ee?!!this.style.getImage(Ee):(this.fire(new m.ErrorEvent(new Error("Missing required image id"))),!1)}removeImage(Ee){this.style.removeImage(Ee)}loadImage(Ee,w){m.getImage(this._requestManager.transformRequest(Ee,m.ResourceType.Image),(se,it)=>{w(se,it instanceof m.window.HTMLImageElement?m.exported.getImageData(it):it)})}listImages(){return this.style.listImages()}addLayer(Ee,w){return this._lazyInitEmptyStyle(),this.style.addLayer(Ee,w),this._update(!0)}moveLayer(Ee,w){return this.style.moveLayer(Ee,w),this._update(!0)}removeLayer(Ee){return this.style.removeLayer(Ee),this._update(!0)}getLayer(Ee){return this.style.getLayer(Ee)}setLayerZoomRange(Ee,w,se){return this.style.setLayerZoomRange(Ee,w,se),this._update(!0)}setFilter(Ee,w,se={}){return this.style.setFilter(Ee,w,se),this._update(!0)}getFilter(Ee){return this.style.getFilter(Ee)}setPaintProperty(Ee,w,se,it={}){return this.style.setPaintProperty(Ee,w,se,it),this._update(!0)}getPaintProperty(Ee,w){return this.style.getPaintProperty(Ee,w)}setLayoutProperty(Ee,w,se,it={}){return this.style.setLayoutProperty(Ee,w,se,it),this._update(!0)}getLayoutProperty(Ee,w){return this.style.getLayoutProperty(Ee,w)}setLight(Ee,w={}){return this._lazyInitEmptyStyle(),this.style.setLight(Ee,w),this._update(!0)}getLight(){return this.style.getLight()}setTerrain(Ee){return this._lazyInitEmptyStyle(),!Ee&&this.transform.projection.requiresDraping?this.style.setTerrainForDraping():this.style.setTerrain(Ee),this._averageElevationLastSampledAt=-1/0,this._update(!0)}getTerrain(){return this.style?this.style.getTerrain():null}setFog(Ee){return this._lazyInitEmptyStyle(),this.style.setFog(Ee),this._update(!0)}getFog(){return this.style?this.style.getFog():null}_queryFogOpacity(Ee){return this.style&&this.style.fog?this.style.fog.getOpacityAtLatLng(m.LngLat.convert(Ee),this.transform):0}setFeatureState(Ee,w){return this.style.setFeatureState(Ee,w),this._update()}removeFeatureState(Ee,w){return this.style.removeFeatureState(Ee,w),this._update()}getFeatureState(Ee){return this.style.getFeatureState(Ee)}_updateContainerDimensions(){if(!this._container)return;const Ee=this._container.getBoundingClientRect().width||400,w=this._container.getBoundingClientRect().height||300;let se,it,xt,Dt=this._container;for(;Dt&&(!it||!xt);){const Ot=m.window.getComputedStyle(Dt).transform;Ot&&Ot!=="none"&&(se=Ot.match(/matrix.*\((.+)\)/)[1].split(", "),se[0]&&se[0]!=="0"&&se[0]!=="1"&&(it=se[0]),se[3]&&se[3]!=="0"&&se[3]!=="1"&&(xt=se[3])),Dt=Dt.parentElement}this._containerWidth=it?Math.abs(Ee/it):Ee,this._containerHeight=xt?Math.abs(w/xt):w}_detectMissingCSS(){m.window.getComputedStyle(this._missingCSSCanary).getPropertyValue("background-color")!=="rgb(250, 128, 114)"&&m.warnOnce("This page appears to be missing CSS declarations for Mapbox GL JS, which may cause the map to display incorrectly. Please ensure your page includes mapbox-gl.css, as described in https://www.mapbox.com/mapbox-gl-js/api/.")}_setupContainer(){const Ee=this._container;Ee.classList.add("mapboxgl-map"),(this._missingCSSCanary=q("div","mapboxgl-canary",Ee)).style.visibility="hidden",this._detectMissingCSS();const w=this._canvasContainer=q("div","mapboxgl-canvas-container",Ee);this._interactive&&w.classList.add("mapboxgl-interactive"),this._canvas=q("canvas","mapboxgl-canvas",w),this._canvas.addEventListener("webglcontextlost",this._contextLost,!1),this._canvas.addEventListener("webglcontextrestored",this._contextRestored,!1),this._canvas.setAttribute("tabindex","0"),this._canvas.setAttribute("aria-label","Map"),this._canvas.setAttribute("role","region"),this._canvas.setAttribute("id","mxcanvas"),console.log("mapbox use webgl2"),this._updateContainerDimensions(),this._resizeCanvas(this._containerWidth,this._containerHeight);const se=this._controlContainer=q("div","mapboxgl-control-container",Ee),it=this._controlPositions={};["top-left","top-right","bottom-left","bottom-right"].forEach(xt=>{it[xt]=q("div",`mapboxgl-ctrl-${xt}`,se)}),this._container.addEventListener("scroll",this._onMapScroll,!1)}_resizeCanvas(Ee,w){const se=m.exported.devicePixelRatio||1;this._canvas.width=se*Math.ceil(Ee),this._canvas.height=se*Math.ceil(w),this._canvas.style.width=`${Ee}px`,this._canvas.style.height=`${w}px`}_addMarker(Ee){this._markers.push(Ee)}_removeMarker(Ee){const w=this._markers.indexOf(Ee);w!==-1&&this._markers.splice(w,1)}_setupPainter(){const Ee=m.extend({},O.webGLContextAttributes,{failIfMajorPerformanceCaveat:this._failIfMajorPerformanceCaveat,preserveDrawingBuffer:this._preserveDrawingBuffer,antialias:this._antialias||!1}),w=this._canvas.getContext("webgl2",Ee)||this._canvas.getContext("experimental-webgl",Ee);w?(m.storeAuthState(w,!0),this.painter=new gu(w,this.transform),this.on("data",se=>{se.dataType==="source"&&this.painter.setTileLoadedFlag(!0)}),m.exported$1.testSupport(w)):this.fire(new m.ErrorEvent(new Error("Failed to initialize WebGL")))}_contextLost(Ee){Ee.preventDefault(),this._frame&&(this._frame.cancel(),this._frame=null),this.fire(new m.Event("webglcontextlost",{originalEvent:Ee}))}_contextRestored(Ee){this._setupPainter(),this.resize(),this._update(),this.fire(new m.Event("webglcontextrestored",{originalEvent:Ee}))}_onMapScroll(Ee){if(Ee.target===this._container)return this._container.scrollTop=0,this._container.scrollLeft=0,!1}loaded(){return!this._styleDirty&&!this._sourcesDirty&&!!this.style&&this.style.loaded()}_update(Ee){return this.style?(this._styleDirty=this._styleDirty||Ee,this._sourcesDirty=!0,this.triggerRepaint(),this):this}_requestRenderFrame(Ee){return this._update(),this._renderTaskQueue.add(Ee)}_cancelRenderFrame(Ee){this._renderTaskQueue.remove(Ee)}_requestDomTask(Ee){!this.loaded()||this.loaded()&&!this.isMoving()?Ee():this._domRenderTaskQueue.add(Ee)}_render(Ee){let w;const se=this.painter.context.extTimerQuery,it=m.exported.now();if(this.listens("gpu-timing-frame")&&(w=se.createQueryEXT(),se.beginQueryEXT(se.TIME_ELAPSED_EXT,w)),this.painter.context.setDirty(),this.painter.setBaseState(),this._renderTaskQueue.run(Ee),this._domRenderTaskQueue.run(Ee),this._removed)return;let xt=!1;const Dt=this._isInitialLoad?0:this._fadeDuration;if(this.style&&this._styleDirty){this._styleDirty=!1;const Tn=this.transform.zoom,kn=this.transform.pitch,Bn=m.exported.now();this.style.zoomHistory.update(Tn,Bn);const Wn=new m.EvaluationParameters(Tn,{now:Bn,fadeDuration:Dt,pitch:kn,zoomHistory:this.style.zoomHistory,transition:this.style.getTransition()}),Fr=Wn.crossFadingFactor();Fr===1&&Fr===this._crossFadingFactor||(xt=!0,this._crossFadingFactor=Fr),this.style.update(Wn)}this.style&&this.style.fog&&this.style.fog.hasTransition()&&(this.style._markersNeedUpdate=!0,this._sourcesDirty=!0);let Ot=!1;if(this.style&&this._sourcesDirty?(this._sourcesDirty=!1,this.painter._updateFog(this.style),this._updateTerrain(),Ot=this._updateAverageElevation(it),this.style._updateSources(this.transform),this._forceMarkerUpdate()):Ot=this._updateAverageElevation(it),this._placementDirty=this.style&&this.style._updatePlacement(this.painter.transform,this.showCollisionBoxes,Dt,this._crossSourceCollisions),this.style&&this.painter.render(this.style,{showTileBoundaries:this.showTileBoundaries,showTerrainWireframe:this.showTerrainWireframe,showOverdrawInspector:this._showOverdrawInspector,showQueryGeometry:!!this._showQueryGeometry,rotating:this.isRotating(),zooming:this.isZooming(),moving:this.isMoving(),fadeDuration:Dt,isInitialLoad:this._isInitialLoad,showPadding:this.showPadding,gpuTiming:!!this.listens("gpu-timing-layer"),speedIndexTiming:this.speedIndexTiming}),this.fire(new m.Event("render")),this.loaded()&&!this._loaded&&(this._loaded=!0,this.fire(new m.Event("load"))),this.style&&(this.style.hasTransitions()||xt)&&(this._styleDirty=!0),this.style&&!this._placementDirty&&this.style._releaseSymbolFadeTiles(),this.listens("gpu-timing-frame")){const Tn=m.exported.now()-it;se.endQueryEXT(se.TIME_ELAPSED_EXT,w),setTimeout(()=>{const kn=se.getQueryObjectEXT(w,se.QUERY_RESULT_EXT)/1e6;se.deleteQueryEXT(w),this.fire(new m.Event("gpu-timing-frame",{cpuTime:Tn,gpuTime:kn}))},50)}if(this.listens("gpu-timing-layer")){const Tn=this.painter.collectGpuTimers();setTimeout(()=>{const kn=this.painter.queryGpuTimers(Tn);this.fire(new m.Event("gpu-timing-layer",{layerTimes:kn}))},50)}const rn=this._sourcesDirty||this._styleDirty||this._placementDirty||Ot;if(rn||this._repaint)this.triggerRepaint();else{const Tn=!this.isMoving()&&this.loaded();if(Tn&&(Ot=this._updateAverageElevation(it,!0)),Ot)this.triggerRepaint();else if(this._triggerFrame(!1),Tn&&(this.fire(new m.Event("idle")),this._isInitialLoad=!1,this.speedIndexTiming)){const kn=this._calculateSpeedIndex();this.fire(new m.Event("speedindexcompleted",{speedIndex:kn})),this.speedIndexTiming=!1}}!this._loaded||this._fullyLoaded||rn||(this._fullyLoaded=!0,this._authenticate())}_forceMarkerUpdate(){for(const Ee of this._markers)Ee._update()}_updateAverageElevation(Ee,w=!1){const se=it=>(this.transform.averageElevation=it,this._update(!1),!0);if(!this.painter.averageElevationNeedsEasing())return this.transform.averageElevation!==0&&se(0);if((w||Ee-this._averageElevationLastSampledAt>500)&&!this._averageElevation.isEasing(Ee)){const it=this.transform.averageElevation;let xt=this.transform.sampleAverageElevation(),Dt=!1;this.transform.elevation&&(Dt=this.transform.elevation.exaggeration()!==this._averageElevationExaggeration,this._averageElevationExaggeration=this.transform.elevation.exaggeration()),isNaN(xt)?xt=0:this._averageElevationLastSampledAt=Ee;const Ot=Math.abs(it-xt);if(Ot>1){if(this._isInitialLoad||Dt)return this._averageElevation.jumpTo(xt),se(xt);this._averageElevation.easeTo(xt,Ee,300)}else if(Ot>1e-4)return this._averageElevation.jumpTo(xt),se(xt)}return!!this._averageElevation.isEasing(Ee)&&se(this._averageElevation.getValue(Ee))}_authenticate(){m.getMapSessionAPI(this._getMapId(),this._requestManager._skuToken,this._requestManager._customAccessToken,Ee=>{}),m.postMapLoadEvent(this._getMapId(),this._requestManager._skuToken,this._requestManager._customAccessToken,()=>{})}_updateTerrain(){this.painter.updateTerrain(this.style,this.isMoving()||this.isRotating()||this.isZooming())}_calculateSpeedIndex(){const Ee=this.painter.canvasCopy(),w=this.painter.getCanvasCopiesAndTimestamps();w.timeStamps.push(performance.now());const se=this.painter.context.gl,it=se.createFramebuffer();function xt(Dt){se.framebufferTexture2D(se.FRAMEBUFFER,se.COLOR_ATTACHMENT0,se.TEXTURE_2D,Dt,0);const Ot=new Uint8Array(se.drawingBufferWidth*se.drawingBufferHeight*4);return se.readPixels(0,0,se.drawingBufferWidth,se.drawingBufferHeight,se.RGBA,se.UNSIGNED_BYTE,Ot),Ot}return se.bindFramebuffer(se.FRAMEBUFFER,it),this._canvasPixelComparison(xt(Ee),w.canvasCopies.map(xt),w.timeStamps)}_canvasPixelComparison(Ee,w,se){let it=se[1]-se[0];const xt=Ee.length/4;for(let Dt=0;Dt<w.length;Dt++){const Ot=w[Dt];let rn=0;for(let Tn=0;Tn<Ot.length;Tn+=4)Ot[Tn]===Ee[Tn]&&Ot[Tn+1]===Ee[Tn+1]&&Ot[Tn+2]===Ee[Tn+2]&&Ot[Tn+3]===Ee[Tn+3]&&(rn+=1);it+=(se[Dt+2]-se[Dt+1])*(1-rn/xt)}return it}remove(){this._hash&&this._hash.remove();for(const w of this._controls)w.onRemove(this);this._controls=[],this._frame&&(this._frame.cancel(),this._frame=null),this._renderTaskQueue.clear(),this._domRenderTaskQueue.clear(),this.style&&this.style.destroy(),this.painter.destroy(),this.handlers&&this.handlers.destroy(),this.handlers=void 0,this.setStyle(null),m.window!==void 0&&(m.window.removeEventListener("resize",this._onWindowResize,!1),m.window.removeEventListener("orientationchange",this._onWindowResize,!1),m.window.removeEventListener("webkitfullscreenchange",this._onWindowResize,!1),m.window.removeEventListener("online",this._onWindowOnline,!1));const Ee=this.painter.context.gl.getExtension("WEBGL_lose_context");Ee&&Ee.loseContext(),Ef(this._canvasContainer),Ef(this._controlContainer),Ef(this._missingCSSCanary),this._container.classList.remove("mapboxgl-map"),m.removeAuthState(this.painter.context.gl),this._removed=!0,this.fire(new m.Event("remove"))}triggerRepaint(){this._triggerFrame(!0)}_triggerFrame(Ee){this._renderNextFrame=this._renderNextFrame||Ee,this.style&&!this._frame&&(this._frame=m.exported.frame(w=>{const se=!!this._renderNextFrame;this._frame=null,this._renderNextFrame=null,se&&this._render(w)}))}_preloadTiles(Ee){const w=this.style?Object.values(this.style._sourceCaches):[];return m.asyncAll(w,(se,it)=>se._preloadTiles(Ee,it),()=>{this.triggerRepaint()}),this}_onWindowOnline(){this._update()}_onWindowResize(Ee){this._trackResize&&this.resize({originalEvent:Ee})._update()}get showTileBoundaries(){return!!this._showTileBoundaries}set showTileBoundaries(Ee){this._showTileBoundaries!==Ee&&(this._showTileBoundaries=Ee,this._update())}get showTerrainWireframe(){return!!this._showTerrainWireframe}set showTerrainWireframe(Ee){this._showTerrainWireframe!==Ee&&(this._showTerrainWireframe=Ee,this._update())}get speedIndexTiming(){return!!this._speedIndexTiming}set speedIndexTiming(Ee){this._speedIndexTiming!==Ee&&(this._speedIndexTiming=Ee,this._update())}get showPadding(){return!!this._showPadding}set showPadding(Ee){this._showPadding!==Ee&&(this._showPadding=Ee,this._update())}get showCollisionBoxes(){return!!this._showCollisionBoxes}set showCollisionBoxes(Ee){this._showCollisionBoxes!==Ee&&(this._showCollisionBoxes=Ee,Ee?this.style._generateCollisionBoxes():this._update())}get showOverdrawInspector(){return!!this._showOverdrawInspector}set showOverdrawInspector(Ee){this._showOverdrawInspector!==Ee&&(this._showOverdrawInspector=Ee,this._update())}get repaint(){return!!this._repaint}set repaint(Ee){this._repaint!==Ee&&(this._repaint=Ee,this.triggerRepaint())}get vertices(){return!!this._vertices}set vertices(Ee){this._vertices=Ee,this._update()}_setCacheLimits(Ee,w){m.setCacheLimits(Ee,w)}get version(){return m.version}},NavigationControl:class{constructor(Ee){this.options=m.extend({},Lh,Ee),this._container=q("div","mapboxgl-ctrl mapboxgl-ctrl-group"),this._container.addEventListener("contextmenu",w=>w.preventDefault()),this.options.showZoom&&(m.bindAll(["_setButtonTitle","_updateZoomButtons"],this),this._zoomInButton=this._createButton("mapboxgl-ctrl-zoom-in",w=>{this._map&&this._map.zoomIn({},{originalEvent:w})}),q("span","mapboxgl-ctrl-icon",this._zoomInButton).setAttribute("aria-hidden","true"),this._zoomOutButton=this._createButton("mapboxgl-ctrl-zoom-out",w=>{this._map&&this._map.zoomOut({},{originalEvent:w})}),q("span","mapboxgl-ctrl-icon",this._zoomOutButton).setAttribute("aria-hidden","true")),this.options.showCompass&&(m.bindAll(["_rotateCompassArrow"],this),this._compass=this._createButton("mapboxgl-ctrl-compass",w=>{const se=this._map;se&&(this.options.visualizePitch?se.resetNorthPitch({},{originalEvent:w}):se.resetNorth({},{originalEvent:w}))}),this._compassIcon=q("span","mapboxgl-ctrl-icon",this._compass),this._compassIcon.setAttribute("aria-hidden","true"))}_updateZoomButtons(){const Ee=this._map;if(!Ee)return;const w=Ee.getZoom(),se=w===Ee.getMaxZoom(),it=w===Ee.getMinZoom();this._zoomInButton.disabled=se,this._zoomOutButton.disabled=it,this._zoomInButton.setAttribute("aria-disabled",se.toString()),this._zoomOutButton.setAttribute("aria-disabled",it.toString())}_rotateCompassArrow(){const Ee=this._map;if(!Ee)return;const w=this.options.visualizePitch?`scale(${1/Math.pow(Math.cos(Ee.transform.pitch*(Math.PI/180)),.5)}) rotateX(${Ee.transform.pitch}deg) rotateZ(${Ee.transform.angle*(180/Math.PI)}deg)`:`rotate(${Ee.transform.angle*(180/Math.PI)}deg)`;Ee._requestDomTask(()=>{this._compassIcon&&(this._compassIcon.style.transform=w)})}onAdd(Ee){return this._map=Ee,this.options.showZoom&&(this._setButtonTitle(this._zoomInButton,"ZoomIn"),this._setButtonTitle(this._zoomOutButton,"ZoomOut"),Ee.on("zoom",this._updateZoomButtons),this._updateZoomButtons()),this.options.showCompass&&(this._setButtonTitle(this._compass,"ResetBearing"),this.options.visualizePitch&&Ee.on("pitch",this._rotateCompassArrow),Ee.on("rotate",this._rotateCompassArrow),this._rotateCompassArrow(),this._handler=new Kf(Ee,this._compass,this.options.visualizePitch)),this._container}onRemove(){const Ee=this._map;Ee&&(this._container.remove(),this.options.showZoom&&Ee.off("zoom",this._updateZoomButtons),this.options.showCompass&&(this.options.visualizePitch&&Ee.off("pitch",this._rotateCompassArrow),Ee.off("rotate",this._rotateCompassArrow),this._handler&&this._handler.off(),this._handler=void 0),this._map=void 0)}_createButton(Ee,w){const se=q("button",Ee,this._container);return se.type="button",se.addEventListener("click",w),se}_setButtonTitle(Ee,w){if(!this._map)return;const se=this._map._getUIString(`NavigationControl.${w}`);Ee.setAttribute("aria-label",se),Ee.firstElementChild&&Ee.firstElementChild.setAttribute("title",se)}},GeolocateControl:class extends m.Evented{constructor(Ee){super(),this.options=m.extend({},Fd,Ee),m.bindAll(["_onSuccess","_onError","_onZoom","_finish","_setupUI","_updateCamera","_updateMarker","_updateMarkerRotation","_onDeviceOrientation"],this),this._updateMarkerRotationThrottled=ef(this._updateMarkerRotation,20)}onAdd(Ee){var w;return this._map=Ee,this._container=q("div","mapboxgl-ctrl mapboxgl-ctrl-group"),w=this._setupUI,Bd!==void 0?w(Bd):m.window.navigator.permissions!==void 0?m.window.navigator.permissions.query({name:"geolocation"}).then(se=>{Bd=se.state!=="denied",w(Bd)}):(Bd=!!m.window.navigator.geolocation,w(Bd)),this._container}onRemove(){this._geolocationWatchID!==void 0&&(m.window.navigator.geolocation.clearWatch(this._geolocationWatchID),this._geolocationWatchID=void 0),this.options.showUserLocation&&this._userLocationDotMarker&&this._userLocationDotMarker.remove(),this.options.showAccuracyCircle&&this._accuracyCircleMarker&&this._accuracyCircleMarker.remove(),this._container.remove(),this._map.off("zoom",this._onZoom),this._map=void 0,sf=0,mp=!1}_isOutOfMapMaxBounds(Ee){const w=this._map.getMaxBounds(),se=Ee.coords;return!!w&&(se.longitude<w.getWest()||se.longitude>w.getEast()||se.latitude<w.getSouth()||se.latitude>w.getNorth())}_setErrorState(){switch(this._watchState){case"WAITING_ACTIVE":this._watchState="ACTIVE_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error");break;case"ACTIVE_LOCK":this._watchState="ACTIVE_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting");break;case"BACKGROUND":this._watchState="BACKGROUND_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting")}}_onSuccess(Ee){if(this._map){if(this._isOutOfMapMaxBounds(Ee))return this._setErrorState(),this.fire(new m.Event("outofmaxbounds",Ee)),this._updateMarker(),void this._finish();if(this.options.trackUserLocation)switch(this._lastKnownPosition=Ee,this._watchState){case"WAITING_ACTIVE":case"ACTIVE_LOCK":case"ACTIVE_ERROR":this._watchState="ACTIVE_LOCK",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"BACKGROUND":case"BACKGROUND_ERROR":this._watchState="BACKGROUND",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background")}this.options.showUserLocation&&this._watchState!=="OFF"&&this._updateMarker(Ee),this.options.trackUserLocation&&this._watchState!=="ACTIVE_LOCK"||this._updateCamera(Ee),this.options.showUserLocation&&this._dotElement.classList.remove("mapboxgl-user-location-dot-stale"),this.fire(new m.Event("geolocate",Ee)),this._finish()}}_updateCamera(Ee){const w=new m.LngLat(Ee.coords.longitude,Ee.coords.latitude),se=Ee.coords.accuracy,it=this._map.getBearing(),xt=m.extend({bearing:it},this.options.fitBoundsOptions);this._map.fitBounds(w.toBounds(se),xt,{geolocateSource:!0})}_updateMarker(Ee){if(Ee){const w=new m.LngLat(Ee.coords.longitude,Ee.coords.latitude);this._accuracyCircleMarker.setLngLat(w).addTo(this._map),this._userLocationDotMarker.setLngLat(w).addTo(this._map),this._accuracy=Ee.coords.accuracy,this.options.showUserLocation&&this.options.showAccuracyCircle&&this._updateCircleRadius()}else this._userLocationDotMarker.remove(),this._accuracyCircleMarker.remove()}_updateCircleRadius(){const Ee=this._map._containerHeight/2,w=this._map.unproject([0,Ee]),se=this._map.unproject([100,Ee]),it=w.distanceTo(se)/100,xt=Math.ceil(2*this._accuracy/it);this._circleElement.style.width=`${xt}px`,this._circleElement.style.height=`${xt}px`}_onZoom(){this.options.showUserLocation&&this.options.showAccuracyCircle&&this._updateCircleRadius()}_updateMarkerRotation(){this._userLocationDotMarker&&typeof this._heading=="number"?(this._userLocationDotMarker.setRotation(this._heading),this._dotElement.classList.add("mapboxgl-user-location-show-heading")):(this._dotElement.classList.remove("mapboxgl-user-location-show-heading"),this._userLocationDotMarker.setRotation(0))}_onError(Ee){if(this._map){if(this.options.trackUserLocation)if(Ee.code===1){this._watchState="OFF",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.disabled=!0;const w=this._map._getUIString("GeolocateControl.LocationNotAvailable");this._geolocateButton.setAttribute("aria-label",w),this._geolocateButton.firstElementChild&&this._geolocateButton.firstElementChild.setAttribute("title",w),this._geolocationWatchID!==void 0&&this._clearWatch()}else{if(Ee.code===3&&mp)return;this._setErrorState()}this._watchState!=="OFF"&&this.options.showUserLocation&&this._dotElement.classList.add("mapboxgl-user-location-dot-stale"),this.fire(new m.Event("error",Ee)),this._finish()}}_finish(){this._timeoutId&&clearTimeout(this._timeoutId),this._timeoutId=void 0}_setupUI(Ee){if(this._container.addEventListener("contextmenu",w=>w.preventDefault()),this._geolocateButton=q("button","mapboxgl-ctrl-geolocate",this._container),q("span","mapboxgl-ctrl-icon",this._geolocateButton).setAttribute("aria-hidden","true"),this._geolocateButton.type="button",Ee===!1){m.warnOnce("Geolocation support is not available so the GeolocateControl will be disabled.");const w=this._map._getUIString("GeolocateControl.LocationNotAvailable");this._geolocateButton.disabled=!0,this._geolocateButton.setAttribute("aria-label",w),this._geolocateButton.firstElementChild&&this._geolocateButton.firstElementChild.setAttribute("title",w)}else{const w=this._map._getUIString("GeolocateControl.FindMyLocation");this._geolocateButton.setAttribute("aria-label",w),this._geolocateButton.firstElementChild&&this._geolocateButton.firstElementChild.setAttribute("title",w)}this.options.trackUserLocation&&(this._geolocateButton.setAttribute("aria-pressed","false"),this._watchState="OFF"),this.options.showUserLocation&&(this._dotElement=q("div","mapboxgl-user-location"),this._dotElement.appendChild(q("div","mapboxgl-user-location-dot")),this._dotElement.appendChild(q("div","mapboxgl-user-location-heading")),this._userLocationDotMarker=new of({element:this._dotElement,rotationAlignment:"map",pitchAlignment:"map"}),this._circleElement=q("div","mapboxgl-user-location-accuracy-circle"),this._accuracyCircleMarker=new of({element:this._circleElement,pitchAlignment:"map"}),this.options.trackUserLocation&&(this._watchState="OFF"),this._map.on("zoom",this._onZoom)),this._geolocateButton.addEventListener("click",this.trigger.bind(this)),this._setup=!0,this.options.trackUserLocation&&this._map.on("movestart",w=>{w.geolocateSource||this._watchState!=="ACTIVE_LOCK"||w.originalEvent&&w.originalEvent.type==="resize"||(this._watchState="BACKGROUND",this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this.fire(new m.Event("trackuserlocationend")))})}_onDeviceOrientation(Ee){this._userLocationDotMarker&&(Ee.webkitCompassHeading?this._heading=Ee.webkitCompassHeading:Ee.absolute===!0&&(this._heading=-1*Ee.alpha),this._updateMarkerRotationThrottled())}trigger(){if(!this._setup)return m.warnOnce("Geolocate control triggered before added to a map"),!1;if(this.options.trackUserLocation){switch(this._watchState){case"OFF":this._watchState="WAITING_ACTIVE",this.fire(new m.Event("trackuserlocationstart"));break;case"WAITING_ACTIVE":case"ACTIVE_LOCK":case"ACTIVE_ERROR":case"BACKGROUND_ERROR":sf--,mp=!1,this._watchState="OFF",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this.fire(new m.Event("trackuserlocationend"));break;case"BACKGROUND":this._watchState="ACTIVE_LOCK",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._lastKnownPosition&&this._updateCamera(this._lastKnownPosition),this.fire(new m.Event("trackuserlocationstart"))}switch(this._watchState){case"WAITING_ACTIVE":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"ACTIVE_LOCK":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"ACTIVE_ERROR":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error");break;case"BACKGROUND":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background");break;case"BACKGROUND_ERROR":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background-error")}if(this._watchState==="OFF"&&this._geolocationWatchID!==void 0)this._clearWatch();else if(this._geolocationWatchID===void 0){let Ee;this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.setAttribute("aria-pressed","true"),sf++,sf>1?(Ee={maximumAge:6e5,timeout:0},mp=!0):(Ee=this.options.positionOptions,mp=!1),this._geolocationWatchID=m.window.navigator.geolocation.watchPosition(this._onSuccess,this._onError,Ee),this.options.showUserHeading&&this._addDeviceOrientationListener()}}else m.window.navigator.geolocation.getCurrentPosition(this._onSuccess,this._onError,this.options.positionOptions),this._timeoutId=setTimeout(this._finish,1e4);return!0}_addDeviceOrientationListener(){const Ee=()=>{m.window.addEventListener("ondeviceorientationabsolute"in m.window?"deviceorientationabsolute":"deviceorientation",this._onDeviceOrientation)};m.window.DeviceMotionEvent!==void 0&&typeof m.window.DeviceMotionEvent.requestPermission=="function"?DeviceOrientationEvent.requestPermission().then(w=>{w==="granted"&&Ee()}).catch(console.error):Ee()}_clearWatch(){m.window.navigator.geolocation.clearWatch(this._geolocationWatchID),m.window.removeEventListener("deviceorientation",this._onDeviceOrientation),m.window.removeEventListener("deviceorientationabsolute",this._onDeviceOrientation),this._geolocationWatchID=void 0,this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.setAttribute("aria-pressed","false"),this.options.showUserLocation&&this._updateMarker(null)}},AttributionControl:Np,ScaleControl:class{constructor(Ee){this.options=m.extend({},Xf,Ee),m.bindAll(["_onMove","setUnit"],this)}getDefaultPosition(){return"bottom-left"}_onMove(){Af(this._map,this._container,this.options)}onAdd(Ee){return this._map=Ee,this._container=q("div","mapboxgl-ctrl mapboxgl-ctrl-scale",Ee.getContainer()),this._map.on("move",this._onMove),this._onMove(),this._container}onRemove(){this._container.remove(),this._map.off("move",this._onMove),this._map=void 0}setUnit(Ee){this.options.unit=Ee,Af(this._map,this._container,this.options)}},FullscreenControl:class{constructor(Ee){this._fullscreen=!1,Ee&&Ee.container&&(Ee.container instanceof m.window.HTMLElement?this._container=Ee.container:m.warnOnce("Full screen control 'container' must be a DOM element.")),m.bindAll(["_onClickFullscreen","_changeIcon"],this),"onfullscreenchange"in m.window.document?this._fullscreenchange="fullscreenchange":"onwebkitfullscreenchange"in m.window.document&&(this._fullscreenchange="webkitfullscreenchange")}onAdd(Ee){return this._map=Ee,this._container||(this._container=this._map.getContainer()),this._controlContainer=q("div","mapboxgl-ctrl mapboxgl-ctrl-group"),this._checkFullscreenSupport()?this._setupUI():(this._controlContainer.style.display="none",m.warnOnce("This device does not support fullscreen mode.")),this._controlContainer}onRemove(){this._controlContainer.remove(),this._map=null,m.window.document.removeEventListener(this._fullscreenchange,this._changeIcon)}_checkFullscreenSupport(){return!(!m.window.document.fullscreenEnabled&&!m.window.document.webkitFullscreenEnabled)}_setupUI(){const Ee=this._fullscreenButton=q("button","mapboxgl-ctrl-fullscreen",this._controlContainer);q("span","mapboxgl-ctrl-icon",Ee).setAttribute("aria-hidden","true"),Ee.type="button",this._updateTitle(),this._fullscreenButton.addEventListener("click",this._onClickFullscreen),m.window.document.addEventListener(this._fullscreenchange,this._changeIcon)}_updateTitle(){const Ee=this._getTitle();this._fullscreenButton.setAttribute("aria-label",Ee),this._fullscreenButton.firstElementChild&&this._fullscreenButton.firstElementChild.setAttribute("title",Ee)}_getTitle(){return this._map._getUIString(this._isFullscreen()?"FullscreenControl.Exit":"FullscreenControl.Enter")}_isFullscreen(){return this._fullscreen}_changeIcon(){(m.window.document.fullscreenElement||m.window.document.webkitFullscreenElement)===this._container!==this._fullscreen&&(this._fullscreen=!this._fullscreen,this._fullscreenButton.classList.toggle("mapboxgl-ctrl-shrink"),this._fullscreenButton.classList.toggle("mapboxgl-ctrl-fullscreen"),this._updateTitle())}_onClickFullscreen(){this._isFullscreen()?m.window.document.exitFullscreen?m.window.document.exitFullscreen():m.window.document.webkitCancelFullScreen&&m.window.document.webkitCancelFullScreen():this._container.requestFullscreen?this._container.requestFullscreen():this._container.webkitRequestFullscreen&&this._container.webkitRequestFullscreen()}},Popup:class extends m.Evented{constructor(Ee){super(),this.options=m.extend(Object.create($c),Ee),m.bindAll(["_update","_onClose","remove","_onMouseEvent"],this),this._classList=new Set(Ee&&Ee.className?Ee.className.trim().split(/\s+/):[])}addTo(Ee){return this._map&&this.remove(),this._map=Ee,this.options.closeOnClick&&Ee.on("preclick",this._onClose),this.options.closeOnMove&&Ee.on("move",this._onClose),Ee.on("remove",this.remove),this._update(),this._focusFirstElement(),this._trackPointer?(Ee.on("mousemove",this._onMouseEvent),Ee.on("mouseup",this._onMouseEvent),Ee._canvasContainer.classList.add("mapboxgl-track-pointer")):Ee.on("move",this._update),this.fire(new m.Event("open")),this}isOpen(){return!!this._map}remove(){this._content&&this._content.remove(),this._container&&(this._container.remove(),this._container=void 0);const Ee=this._map;return Ee&&(Ee.off("move",this._update),Ee.off("move",this._onClose),Ee.off("preclick",this._onClose),Ee.off("click",this._onClose),Ee.off("remove",this.remove),Ee.off("mousemove",this._onMouseEvent),Ee.off("mouseup",this._onMouseEvent),Ee.off("drag",this._onMouseEvent),this._map=void 0),this.fire(new m.Event("close")),this}getLngLat(){return this._lngLat}setLngLat(Ee){this._lngLat=m.LngLat.convert(Ee),this._pos=null,this._trackPointer=!1,this._update();const w=this._map;return w&&(w.on("move",this._update),w.off("mousemove",this._onMouseEvent),w._canvasContainer.classList.remove("mapboxgl-track-pointer")),this}trackPointer(){this._trackPointer=!0,this._pos=null,this._update();const Ee=this._map;return Ee&&(Ee.off("move",this._update),Ee.on("mousemove",this._onMouseEvent),Ee.on("drag",this._onMouseEvent),Ee._canvasContainer.classList.add("mapboxgl-track-pointer")),this}getElement(){return this._container}setText(Ee){return this.setDOMContent(m.window.document.createTextNode(Ee))}setHTML(Ee){const w=m.window.document.createDocumentFragment(),se=m.window.document.createElement("body");let it;for(se.innerHTML=Ee;it=se.firstChild,it;)w.appendChild(it);return this.setDOMContent(w)}getMaxWidth(){return this._container&&this._container.style.maxWidth}setMaxWidth(Ee){return this.options.maxWidth=Ee,this._update(),this}setDOMContent(Ee){let w=this._content;if(w)for(;w.hasChildNodes();)w.firstChild&&w.removeChild(w.firstChild);else w=this._content=q("div","mapboxgl-popup-content",this._container||void 0);if(w.appendChild(Ee),this.options.closeButton){const se=this._closeButton=q("button","mapboxgl-popup-close-button",w);se.type="button",se.setAttribute("aria-label","Close popup"),se.setAttribute("aria-hidden","true"),se.innerHTML="×",se.addEventListener("click",this._onClose)}return this._update(),this._focusFirstElement(),this}addClassName(Ee){return this._classList.add(Ee),this._updateClassList(),this}removeClassName(Ee){return this._classList.delete(Ee),this._updateClassList(),this}setOffset(Ee){return this.options.offset=Ee,this._update(),this}toggleClassName(Ee){let w;return this._classList.delete(Ee)?w=!1:(this._classList.add(Ee),w=!0),this._updateClassList(),w}_onMouseEvent(Ee){this._update(Ee.point)}_getAnchor(Ee){if(this.options.anchor)return this.options.anchor;const w=this._map,se=this._container,it=this._pos;if(!w||!se||!it)return"bottom";const xt=se.offsetWidth,Dt=se.offsetHeight,Ot=it.x<xt/2,rn=it.x>w.transform.width-xt/2;if(it.y+Ee<Dt)return Ot?"top-left":rn?"top-right":"top";if(it.y>w.transform.height-Dt){if(Ot)return"bottom-left";if(rn)return"bottom-right"}return Ot?"left":rn?"right":"bottom"}_updateClassList(){const Ee=this._container;if(!Ee)return;const w=[...this._classList];w.push("mapboxgl-popup"),this._anchor&&w.push(`mapboxgl-popup-anchor-${this._anchor}`),this._trackPointer&&w.push("mapboxgl-popup-track-pointer"),Ee.className=w.join(" ")}_update(Ee){const w=this._map,se=this._content;if(!w||!this._lngLat&&!this._trackPointer||!se)return;let it=this._container;if(it||(it=this._container=q("div","mapboxgl-popup",w.getContainer()),this._tip=q("div","mapboxgl-popup-tip",it),it.appendChild(se)),this.options.maxWidth&&it.style.maxWidth!==this.options.maxWidth&&(it.style.maxWidth=this.options.maxWidth),w.transform.renderWorldCopies&&!this._trackPointer&&(this._lngLat=bd(this._lngLat,this._pos,w.transform)),!this._trackPointer||Ee){const xt=this._pos=this._trackPointer&&Ee?Ee:w.project(this._lngLat),Dt=Fh(this.options.offset),Ot=this._anchor=this._getAnchor(Dt.y),rn=Fh(this.options.offset,Ot),Tn=xt.add(rn).round();w._requestDomTask(()=>{this._container&&Ot&&(this._container.style.transform=`${sd[Ot]} translate(${Tn.x}px,${Tn.y}px)`)})}this._updateClassList()}_focusFirstElement(){if(!this.options.focusAfterOpen||!this._container)return;const Ee=this._container.querySelector(Iu);Ee&&Ee.focus()}_onClose(){this.remove()}_setOpacity(Ee){this._content&&(this._content.style.opacity=Ee),this._tip&&(this._tip.style.opacity=Ee)}},Marker:of,Style:Ss,LngLat:m.LngLat,LngLatBounds:m.LngLatBounds,Point:m.pointGeometry,MercatorCoordinate:m.MercatorCoordinate,FreeCameraOptions:uc,Evented:m.Evented,config:m.config,prewarm:function(){Wo().acquire(zo)},clearPrewarmedResources:function(){const Ee=Lo;Ee&&(Ee.isPreloaded()&&Ee.numActive()===1?(Ee.release(zo),Lo=null):console.warn("Could not clear WebWorkers since there are active Map instances that still reference it. The pre-warmed WebWorker pool can only be cleared when all map instances have been removed with map.remove()"))},get accessToken(){return m.config.ACCESS_TOKEN},set accessToken(Ee){m.config.ACCESS_TOKEN=Ee},get baseApiUrl(){return m.config.API_URL},set baseApiUrl(Ee){m.config.API_URL=Ee},get workerCount(){return Po.workerCount},set workerCount(Ee){Po.workerCount=Ee},get maxParallelImageRequests(){return m.config.MAX_PARALLEL_IMAGE_REQUESTS},set maxParallelImageRequests(Ee){m.config.MAX_PARALLEL_IMAGE_REQUESTS=Ee},clearStorage(Ee){m.clearTileCache(Ee)},workerUrl:"",workerClass:null,setNow:m.exported.setNow,restoreNow:m.exported.restoreNow};return zp});var b=c;return b})})(mapboxGl);var mapboxGlExports=mapboxGl.exports;const mapboxgl=getDefaultExportFromCjs(mapboxGlExports);var ARRAY_TYPE=typeof Float32Array<"u"?Float32Array:Array;Math.hypot||(Math.hypot=function(){for(var t=0,e=arguments.length;e--;)t+=arguments[e]*arguments[e];return Math.sqrt(t)});function create(){var t=new ARRAY_TYPE(4);return ARRAY_TYPE!=Float32Array&&(t[0]=0,t[1]=0,t[2]=0,t[3]=0),t}function transformMat4(t,e,l){var n=e[0],u=e[1],c=e[2],y=e[3];return t[0]=l[0]*n+l[4]*u+l[8]*c+l[12]*y,t[1]=l[1]*n+l[5]*u+l[9]*c+l[13]*y,t[2]=l[2]*n+l[6]*u+l[10]*c+l[14]*y,t[3]=l[3]*n+l[7]*u+l[11]*c+l[15]*y,t}(function(){var t=create();return function(e,l,n,u,c,y){var b,m;for(l||(l=4),n||(n=0),u?m=Math.min(u*l+n,e.length):m=e.length,b=n;b<m;b+=l)t[0]=e[b],t[1]=e[b+1],t[2]=e[b+2],t[3]=e[b+3],c(t,t,y),e[b]=t[0],e[b+1]=t[1],e[b+2]=t[2],e[b+3]=t[3];return e}})();const _project=mapboxGlExports.Map.prototype.project;let Map$1=class extends mapboxGlExports.Map{dom_mousePos(e){return this.dom_mousePos_imp(this.getCanvasContainer(),e)}lnglat_to_mercator(e,l){return mapboxgl.MercatorCoordinate.fromLngLat([e,l],0)}mercator_to_lnglat(e,l,n){return new mapboxgl.MercatorCoordinate(e,l,n).toLngLat()}addRasterTileLayer(e,l,n){return MxMapAddRasterTileLayer(this,e,l,n)}mercatorCoordinate_from_LngLat(e,l){return mapboxgl.MercatorCoordinate.fromLngLat(e,l)}getScaledPoint(e,l,n){const u=e.offsetWidth===l.width?1:e.offsetWidth/l.width;return new mapboxGlExports.Point((n.clientX-l.left)*u,(n.clientY-l.top)*u)}dom_mousePos_imp(e,l){const n=e.getBoundingClientRect();return this.getScaledPoint(e,n,l)}createCavans(e,l){const n=document.createElement("canvas");return n.width=e,n.height=l,n}projectEx(e,l){const n=this,u=n.transform.locationCoordinate(mapboxGlExports.LngLat.convert(e)),c=[u.x*n.transform.worldSize,u.y*n.transform.worldSize,l??u.toAltitude(),1];return transformMat4(c,c,n.transform.pixelMatrix),new mapboxGlExports.Point(c[0]/c[3],c[1]/c[3])}project(e){const l=_project.bind(this);return arguments.length>=1&&typeof arguments[0]=="object"&&arguments[0].alt?this.projectEx(arguments[0],arguments[0].alt):l(e)}addLayer(e,l){return e.metadata||(e.metadata={isBaseMap:!1}),super.addLayer(e,l),this}changeBaseMap(e,l){let n=Object.assign(l,{isBaseMap:!0});this._removeBaseStyle(),this.addMapStyle(e,n)}_removeBaseStyle(){let{layers:e}=this.getStyle();for(let l of e)(!l.metadata||l.metadata&&l.metadata.isBaseMap==!0)&&this.removeLayer(l.id)}addMapStyle(e,l){let{styleid:n,isBaseMap:u}=l;if(typeof e!="object")throw new TypeError("addMapStyle需要传入对象类型参数");let{zoom:c,center:y,pitch:b}=e;Object.keys(e.sources).forEach(O=>{this.getSource(O)||this.addSource(O,e.sources[O])}),e.sprite&&this._addImages(e.sprite);const m={isBaseMap:u||!1,aid:`${n}`};for(const O of e.layers){let N=O.id;if(O.metadata=m,!this.getLayer(N)){let L=this._findFirstSpeLayer();u&&L?this.addLayer(O,L.id):this.addLayer(O)}}c&&this.setZoom(c),b&&this.setPitch(b),y&&this.setCenter(y)}_findFirstSpeLayer(){let{layers:e}=this.getStyle();for(let l of e)if(l.metadata&&l.metadata.isBaseMap==!1)return l;return null}addGroupLayer(){this.addLayer({id:"mx.layer.fill",type:"fill",source:{type:"geojson",data:{type:"Feature",geometry:{type:"Polygon",coordinates:[[]]},properties:{}}}}),this.addLayer({id:"mx.layer.line",type:"line",source:{type:"geojson",data:{type:"Feature",geometry:{type:"LineString",coordinates:[]},properties:{}}}}),this.addLayer({id:"mx.layer.symbol",type:"symbol",source:{type:"geojson",data:{type:"Feature",geometry:{type:"Point",coordinates:[]},properties:{}}}})}createDashArraySeq(e,l=1){let n=[e];for(let u=l,c=e[0]+e[1];u<c;u+=l){const y=[];if(u<=c-e[0])y.push(0,u,e[0],e[1]-u);else{const b=u-(c-e[0]);y.push(b,e[1],e[0]-b,0)}n.push(y)}return n}_addImages(e){let l=this;fetch(`${e}.json`).then(n=>n.json()).then(n=>{const u=new Image;u.onload=function(){Object.keys(n).forEach(c=>{const y=n[c],{x:b,y:m,width:O,height:N}=y,L=l.createCavans(O,N);L.getContext("2d").drawImage(u,b,m,O,N,0,0,O,N);const q=L.toDataURL("image/png");l.loadImage(q,(J,fe)=>{if(J){console.error(J);return}l.hasImage(c)&&l.removeImage(c),fe&&l.addImage(c,fe)})})},u.crossOrigin="anonymous",u.src=`${e}.png`})}};function createResizeObserver(t){return typeof ResizeObserver=="function"?new ResizeObserver(t):null}function addResizeListener(t,e){const l=()=>requestAnimationFrame(e);let n=createResizeObserver(l);if(n){n.observe(t);return}if(MutationObserver){new MutationObserver(l).observe(t,{attributes:!0});return}}const MxElectronAPI=window.MxElectronAPI;MxElectronAPI&&(window.prompt=MxElectronAPI.prompt,MxElectronAPI.onGetSaveMxWebUrl(()=>new Promise(t=>{const e=MxCpp.App.getCurrentMxCAD(),l=e.getCurrentFileName();e.saveFile(l,n=>{let u;/^((?!chrome|android).)*safari/i.test(navigator.userAgent)?u=new Blob([n.buffer],{type:"application/octet-stream"}):u=new Blob([n.buffer],{type:"application/octet-binary"});const y=URL.createObjectURL(u);setTimeout(()=>{URL.revokeObjectURL(y)},5e3),t(y)},!1,!1)})));function getParamsFromUrl(){let t={};const e=window.location.href,l=e.indexOf("?");if(l!==-1){const n=e.substring(l+1);t=decodeParams(parseParamString(n))}return t}function parseParamString(t){const e={},l=t.split("&");for(let n=0;n<l.length;n++){const u=l[n].split("=");e[decodeURIComponent(u[0])]=decodeURIComponent(u[1]||"")}return e}function decodeParams(t){const e={};for(const l in t)e[decodeURIComponent(l)]=decodeURIComponent(t[l]);return e}const offset=60,iconCache={error:{icon:"class:iconfont error",color:"rgb(203,49,49)"},info:{icon:"class:iconfont info",color:"rgb(47,144,207)"},success:{icon:"class:iconfont success",color:"rgb(139,216,118)"},warning:{icon:"class:iconfont warning",color:"rgb(230,140,34)"}},messages$1=ref([]),addMessage=t=>{const e={id:new Date().getTime(),...t,top:offset*messages$1.value.length};messages$1.value.push(e);const l=()=>{removeMessage(e)};return setTimeout(l,e.duration||2e3),l},removeMessage=t=>{messages$1.value.indexOf(t)>=0&&(messages$1.value.splice(messages$1.value.indexOf(t),1),messages$1.value.map(l=>{l.top-=offset}))},success=(t,e)=>addMessage({message:t,type:"success",duration:e}),warning=(t,e)=>addMessage({message:t,type:"warning",duration:e}),info=(t,e)=>addMessage({message:t,type:"info",duration:e}),error=(t,e)=>addMessage({message:t,type:"error",duration:e}),message=info;message.success=success;message.warning=warning;message.info=info;message.error=error;const useMessage=()=>message,useMessageData=()=>({addMessage,removeMessage,messages:messages$1});MxElectronAPI?.onShowMessage((t,e="success")=>{useMessage()[e](t)});const isShow=ref(!1),abort=ref(),text=ref("停止"),showLoading$2=t=>{t?.abort&&(abort.value=t.abort),text.value=t?.text||"停止",isShow.value=!0,document.body.style.pointerEvents="none"},hideLoading$2=()=>{isShow.value=!1,document.body.style.pointerEvents=""},useLoadingData=()=>({isShow,abort,text,showLoading:showLoading$2,hideLoading:hideLoading$2}),useLoading=()=>({showLoading:showLoading$2,hideLoading:hideLoading$2}),defaultColor={color:"#fff",name:"#fff",index:-1,method:ColorMethod$1.kByColor,n:0},useColor$1=defineStore("color",()=>{const t=(m={})=>({...defaultColor,...m});let e=[];const l=computed(()=>e),n=ref([]),u=ref();watch(u,m=>{if(m){if(m.index!==-1||m.method===ColorMethod$1.kByACI)getDatabase().setCurrentlyColorIndex(m.index);else if(m.method===ColorMethod$1.kByColor){const{red:O,green:N,blue:L}=b(m),G=new McCmColor(O,N,L);G.method=ColorMethod$1.kByColor,getDatabase().setCurrentlyTrueColor(G)}}});const c=()=>{const m=createMxColor(),O=[];for(let L=0;L<257;L++){m.setColorIndex(L);const G=toRGBCss(m),q=t({color:G,index:L,name:getColorName(L)||G,method:ColorMethod$1.kByACI});L===0&&(q.method=ColorMethod$1.kByBlock,q.color="#fff"),L===256&&(q.method=ColorMethod$1.kByLayer,q.color="#ffffff"),O.push(q)}e=O,n.value=[...e.slice(1,8),e[e.length-1],e[0]];const N=getDatabase().getCurrentlyColorIndex();u.value=n.value.find(({index:L})=>N===L)},y=m=>{const O=createMxColor(m),{colorIndex:N,method:L}=O,G=toRGBCss(O);return t({method:L,color:G,name:getColorName(N)||G})},b=m=>{const{method:O}=m,N=Color$1(m.color),L=N.red(),G=N.green(),q=N.blue();return{red:L,green:G,blue:q,method:O}};return{colorIndexList:l,colorSelectList:n,currentSelectColor:u,initColorIndexList:c,createColor:t,parseJSONColor:y,stringifyJSONColor:b}});function useToggleScope(t,e){let l;function n(){l=effectScope(),l.run(()=>e.length?e(()=>{l?.stop(),n()}):e())}watch(t,u=>{u&&!l?n():u||(l?.stop(),l=void 0)},{immediate:!0}),onScopeDispose(()=>{l?.stop()})}const IN_BROWSER=typeof window<"u",SUPPORTS_INTERSECTION=IN_BROWSER&&"IntersectionObserver"in window,SUPPORTS_TOUCH=IN_BROWSER&&("ontouchstart"in window||window.navigator.maxTouchPoints>0),SUPPORTS_EYE_DROPPER=IN_BROWSER&&"EyeDropper"in window;function _classPrivateFieldInitSpec(t,e,l){_checkPrivateRedeclaration(t,e),e.set(t,l)}function _checkPrivateRedeclaration(t,e){if(e.has(t))throw new TypeError("Cannot initialize the same private elements twice on an object")}function _classPrivateFieldSet(t,e,l){return t.set(_assertClassBrand(t,e),l),l}function _classPrivateFieldGet(t,e){return t.get(_assertClassBrand(t,e))}function _assertClassBrand(t,e,l){if(typeof t=="function"?t===e:t.has(e))return arguments.length<3?e:l;throw new TypeError("Private element is not present on this object")}function getNestedValue(t,e,l){const n=e.length-1;if(n<0)return t===void 0?l:t;for(let u=0;u<n;u++){if(t==null)return l;t=t[e[u]]}return t==null||t[e[n]]===void 0?l:t[e[n]]}function deepEqual(t,e){if(t===e)return!0;if(t instanceof Date&&e instanceof Date&&t.getTime()!==e.getTime()||t!==Object(t)||e!==Object(e))return!1;const l=Object.keys(t);return l.length!==Object.keys(e).length?!1:l.every(n=>deepEqual(t[n],e[n]))}function getObjectValueByPath(t,e,l){return t==null||!e||typeof e!="string"?l:t[e]!==void 0?t[e]:(e=e.replace(/\[(\w+)\]/g,".$1"),e=e.replace(/^\./,""),getNestedValue(t,e.split("."),l))}function getPropertyFromItem(t,e,l){if(e===!0)return t===void 0?l:t;if(e==null||typeof e=="boolean")return l;if(t!==Object(t)){if(typeof e!="function")return l;const u=e(t,l);return typeof u>"u"?l:u}if(typeof e=="string")return getObjectValueByPath(t,e,l);if(Array.isArray(e))return getNestedValue(t,e,l);if(typeof e!="function")return l;const n=e(t,l);return typeof n>"u"?l:n}function createRange(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return Array.from({length:t},(l,n)=>e+n)}function convertToUnit(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"px";if(!(t==null||t===""))return isNaN(+t)?String(t):isFinite(+t)?`${Number(t)}${e}`:void 0}function isObject$1(t){return t!==null&&typeof t=="object"&&!Array.isArray(t)}function isPlainObject$1(t){let e;return t!==null&&typeof t=="object"&&((e=Object.getPrototypeOf(t))===Object.prototype||e===null)}function refElement(t){if(t&&"$el"in t){const e=t.$el;return e?.nodeType===Node.TEXT_NODE?e.nextElementSibling:e}return t}const keyCodes=Object.freeze({enter:13,tab:9,delete:46,esc:27,space:32,up:38,down:40,left:37,right:39,end:35,home:36,del:46,backspace:8,insert:45,pageup:33,pagedown:34,shift:16}),keyValues=Object.freeze({enter:"Enter",tab:"Tab",delete:"Delete",esc:"Escape",space:"Space",up:"ArrowUp",down:"ArrowDown",left:"ArrowLeft",right:"ArrowRight",end:"End",home:"Home",del:"Delete",backspace:"Backspace",insert:"Insert",pageup:"PageUp",pagedown:"PageDown",shift:"Shift"});function keys(t){return Object.keys(t)}function has(t,e){return e.every(l=>t.hasOwnProperty(l))}function pick(t,e){const l={},n=new Set(Object.keys(t));for(const u of e)n.has(u)&&(l[u]=t[u]);return l}function pickWithRest(t,e,l){const n=Object.create(null),u=Object.create(null);for(const c in t)e.some(y=>y instanceof RegExp?y.test(c):y===c)&&!l?.some(y=>y===c)?n[c]=t[c]:u[c]=t[c];return[n,u]}function omit(t,e){const l={...t};return e.forEach(n=>delete l[n]),l}function only(t,e){const l={};return e.forEach(n=>l[n]=t[n]),l}const onRE=/^on[^a-z]/,isOn=t=>onRE.test(t),bubblingEvents=["onAfterscriptexecute","onAnimationcancel","onAnimationend","onAnimationiteration","onAnimationstart","onAuxclick","onBeforeinput","onBeforescriptexecute","onChange","onClick","onCompositionend","onCompositionstart","onCompositionupdate","onContextmenu","onCopy","onCut","onDblclick","onFocusin","onFocusout","onFullscreenchange","onFullscreenerror","onGesturechange","onGestureend","onGesturestart","onGotpointercapture","onInput","onKeydown","onKeypress","onKeyup","onLostpointercapture","onMousedown","onMousemove","onMouseout","onMouseover","onMouseup","onMousewheel","onPaste","onPointercancel","onPointerdown","onPointerenter","onPointerleave","onPointermove","onPointerout","onPointerover","onPointerup","onReset","onSelect","onSubmit","onTouchcancel","onTouchend","onTouchmove","onTouchstart","onTransitioncancel","onTransitionend","onTransitionrun","onTransitionstart","onWheel"],compositionIgnoreKeys=["ArrowUp","ArrowDown","ArrowRight","ArrowLeft","Enter","Escape","Tab"," "];function isComposingIgnoreKey(t){return t.isComposing&&compositionIgnoreKeys.includes(t.key)}function filterInputAttrs(t){const[e,l]=pickWithRest(t,[onRE]),n=omit(e,bubblingEvents),[u,c]=pickWithRest(l,["class","style","id",/^data-/]);return Object.assign(u,e),Object.assign(c,n),[u,c]}function wrapInArray(t){return t==null?[]:Array.isArray(t)?t:[t]}function debounce(t,e){let l=0;const n=function(){for(var u=arguments.length,c=new Array(u),y=0;y<u;y++)c[y]=arguments[y];clearTimeout(l),l=setTimeout(()=>t(...c),unref(e))};return n.clear=()=>{clearTimeout(l)},n.immediate=t,n}function clamp(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;return Math.max(e,Math.min(l,t))}function getDecimals(t){const e=t.toString().trim();return e.includes(".")?e.length-e.indexOf(".")-1:0}function padEnd(t,e){let l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0";return t+l.repeat(Math.max(0,e-t.length))}function padStart(t,e){return(arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0").repeat(Math.max(0,e-t.length))+t}function chunk(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;const l=[];let n=0;for(;n<t.length;)l.push(t.substr(n,e)),n+=e;return l}function humanReadableFileSize(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1e3;if(t<e)return`${t} B`;const l=e===1024?["Ki","Mi","Gi"]:["k","M","G"];let n=-1;for(;Math.abs(t)>=e&&n<l.length-1;)t/=e,++n;return`${t.toFixed(1)} ${l[n]}B`}function mergeDeep(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},l=arguments.length>2?arguments[2]:void 0;const n={};for(const u in t)n[u]=t[u];for(const u in e){const c=t[u],y=e[u];if(isPlainObject$1(c)&&isPlainObject$1(y)){n[u]=mergeDeep(c,y,l);continue}if(l&&Array.isArray(c)&&Array.isArray(y)){n[u]=l(c,y);continue}n[u]=y}return n}function flattenFragments(t){return t.map(e=>e.type===Fragment?flattenFragments(e.children):e).flat()}function toKebabCase(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";if(toKebabCase.cache.has(t))return toKebabCase.cache.get(t);const e=t.replace(/[^a-z]/gi,"-").replace(/\B([A-Z])/g,"-$1").toLowerCase();return toKebabCase.cache.set(t,e),e}toKebabCase.cache=new Map;function findChildrenWithProvide(t,e){if(!e||typeof e!="object")return[];if(Array.isArray(e))return e.map(l=>findChildrenWithProvide(t,l)).flat(1);if(e.suspense)return findChildrenWithProvide(t,e.ssContent);if(Array.isArray(e.children))return e.children.map(l=>findChildrenWithProvide(t,l)).flat(1);if(e.component){if(Object.getOwnPropertySymbols(e.component.provides).includes(t))return[e.component];if(e.component.subTree)return findChildrenWithProvide(t,e.component.subTree).flat(1)}return[]}var _arr=new WeakMap,_pointer=new WeakMap;class CircularBuffer{constructor(e){_classPrivateFieldInitSpec(this,_arr,[]),_classPrivateFieldInitSpec(this,_pointer,0),this.size=e}push(e){_classPrivateFieldGet(_arr,this)[_classPrivateFieldGet(_pointer,this)]=e,_classPrivateFieldSet(_pointer,this,(_classPrivateFieldGet(_pointer,this)+1)%this.size)}values(){return _classPrivateFieldGet(_arr,this).slice(_classPrivateFieldGet(_pointer,this)).concat(_classPrivateFieldGet(_arr,this).slice(0,_classPrivateFieldGet(_pointer,this)))}}function getEventCoordinates(t){return"touches"in t?{clientX:t.touches[0].clientX,clientY:t.touches[0].clientY}:{clientX:t.clientX,clientY:t.clientY}}function destructComputed(t){const e=reactive({}),l=computed(t);return watchEffect(()=>{for(const n in l.value)e[n]=l.value[n]},{flush:"sync"}),toRefs(e)}function includes(t,e){return t.includes(e)}function eventName(t){return t[2].toLowerCase()+t.slice(3)}const EventProp=()=>[Function,Array];function hasEvent(t,e){return e="on"+capitalize(e),!!(t[e]||t[`${e}Once`]||t[`${e}Capture`]||t[`${e}OnceCapture`]||t[`${e}CaptureOnce`])}function callEvent(t){for(var e=arguments.length,l=new Array(e>1?e-1:0),n=1;n<e;n++)l[n-1]=arguments[n];if(Array.isArray(t))for(const u of t)u(...l);else typeof t=="function"&&t(...l)}function focusableChildren(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;const l=["button","[href]",'input:not([type="hidden"])',"select","textarea","[tabindex]"].map(n=>`${n}${e?':not([tabindex="-1"])':""}:not([disabled])`).join(", ");return[...t.querySelectorAll(l)]}function getNextElement(t,e,l){let n,u=t.indexOf(document.activeElement);const c=e==="next"?1:-1;do u+=c,n=t[u];while((!n||n.offsetParent==null||!(l?.(n)??!0))&&u<t.length&&u>=0);return n}function focusChild(t,e){const l=focusableChildren(t);if(!e)(t===document.activeElement||!t.contains(document.activeElement))&&l[0]?.focus();else if(e==="first")l[0]?.focus();else if(e==="last")l.at(-1)?.focus();else if(typeof e=="number")l[e]?.focus();else{const n=getNextElement(l,e);n?n.focus():focusChild(t,e==="next"?"first":"last")}}function isEmpty(t){return t==null||typeof t=="string"&&t.trim()===""}function noop$1(){}function matchesSelector(t,e){if(!(IN_BROWSER&&typeof CSS<"u"&&typeof CSS.supports<"u"&&CSS.supports(`selector(${e})`)))return null;try{return!!t&&t.matches(e)}catch{return null}}function ensureValidVNode(t){return t.some(e=>isVNode(e)?e.type===Comment?!1:e.type!==Fragment||ensureValidVNode(e.children):!0)?t:null}function defer(t,e){if(!IN_BROWSER||t===0)return e(),()=>{};const l=window.setTimeout(e,t);return()=>window.clearTimeout(l)}function isClickInsideElement(t,e){const l=t.clientX,n=t.clientY,u=e.getBoundingClientRect(),c=u.left,y=u.top,b=u.right,m=u.bottom;return l>=c&&l<=b&&n>=y&&n<=m}function templateRef(){const t=shallowRef(),e=l=>{t.value=l};return Object.defineProperty(e,"value",{enumerable:!0,get:()=>t.value,set:l=>t.value=l}),Object.defineProperty(e,"el",{enumerable:!0,get:()=>refElement(t.value)}),e}function checkPrintable(t){const e=t.key.length===1,l=!t.ctrlKey&&!t.metaKey&&!t.altKey;return e&&l}const block=["top","bottom"],inline=["start","end","left","right"];function parseAnchor(t,e){let[l,n]=t.split(" ");return n||(n=includes(block,l)?"start":includes(inline,l)?"top":"center"),{side:toPhysical(l,e),align:toPhysical(n,e)}}function toPhysical(t,e){return t==="start"?e?"right":"left":t==="end"?e?"left":"right":t}function flipSide(t){return{side:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[t.side],align:t.align}}function flipAlign(t){return{side:t.side,align:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[t.align]}}function flipCorner(t){return{side:t.align,align:t.side}}function getAxis(t){return includes(block,t.side)?"y":"x"}class Box{constructor(e){let{x:l,y:n,width:u,height:c}=e;this.x=l,this.y=n,this.width=u,this.height=c}get top(){return this.y}get bottom(){return this.y+this.height}get left(){return this.x}get right(){return this.x+this.width}}function getOverflow(t,e){return{x:{before:Math.max(0,e.left-t.left),after:Math.max(0,t.right-e.right)},y:{before:Math.max(0,e.top-t.top),after:Math.max(0,t.bottom-e.bottom)}}}function getTargetBox(t){return Array.isArray(t)?new Box({x:t[0],y:t[1],width:0,height:0}):t.getBoundingClientRect()}function nullifyTransforms(t){const e=t.getBoundingClientRect(),l=getComputedStyle(t),n=l.transform;if(n){let u,c,y,b,m;if(n.startsWith("matrix3d("))u=n.slice(9,-1).split(/, /),c=+u[0],y=+u[5],b=+u[12],m=+u[13];else if(n.startsWith("matrix("))u=n.slice(7,-1).split(/, /),c=+u[0],y=+u[3],b=+u[4],m=+u[5];else return new Box(e);const O=l.transformOrigin,N=e.x-b-(1-c)*parseFloat(O),L=e.y-m-(1-y)*parseFloat(O.slice(O.indexOf(" ")+1)),G=c?e.width/c:t.offsetWidth+1,q=y?e.height/y:t.offsetHeight+1;return new Box({x:N,y:L,width:G,height:q})}else return new Box(e)}function animate(t,e,l){if(typeof t.animate>"u")return{finished:Promise.resolve()};let n;try{n=t.animate(e,l)}catch{return{finished:Promise.resolve()}}return typeof n.finished>"u"&&(n.finished=new Promise(u=>{n.onfinish=()=>{u(n)}})),n}const handlers=new WeakMap;function bindProps(t,e){Object.keys(e).forEach(l=>{if(isOn(l)){const n=eventName(l),u=handlers.get(t);if(e[l]==null)u?.forEach(c=>{const[y,b]=c;y===n&&(t.removeEventListener(n,b),u.delete(c))});else if(!u||![...u].some(c=>c[0]===n&&c[1]===e[l])){t.addEventListener(n,e[l]);const c=u||new Set;c.add([n,e[l]]),handlers.has(t)||handlers.set(t,c)}}else e[l]==null?t.removeAttribute(l):t.setAttribute(l,e[l])})}function unbindProps(t,e){Object.keys(e).forEach(l=>{if(isOn(l)){const n=eventName(l),u=handlers.get(t);u?.forEach(c=>{const[y,b]=c;y===n&&(t.removeEventListener(n,b),u.delete(c))})}else t.removeAttribute(l)})}const mainTRC=2.4,Rco=.2126729,Gco=.7151522,Bco=.072175,normBG=.55,normTXT=.58,revTXT=.57,revBG=.62,blkThrs=.03,blkClmp=1.45,deltaYmin=5e-4,scaleBoW=1.25,scaleWoB=1.25,loConThresh=.078,loConFactor=12.82051282051282,loConOffset=.06,loClip=.001;function APCAcontrast(t,e){const l=(t.r/255)**mainTRC,n=(t.g/255)**mainTRC,u=(t.b/255)**mainTRC,c=(e.r/255)**mainTRC,y=(e.g/255)**mainTRC,b=(e.b/255)**mainTRC;let m=l*Rco+n*Gco+u*Bco,O=c*Rco+y*Gco+b*Bco;if(m<=blkThrs&&(m+=(blkThrs-m)**blkClmp),O<=blkThrs&&(O+=(blkThrs-O)**blkClmp),Math.abs(O-m)<deltaYmin)return 0;let N;if(O>m){const L=(O**normBG-m**normTXT)*scaleBoW;N=L<loClip?0:L<loConThresh?L-L*loConFactor*loConOffset:L-loConOffset}else{const L=(O**revBG-m**revTXT)*scaleWoB;N=L>-loClip?0:L>-loConThresh?L-L*loConFactor*loConOffset:L+loConOffset}return N*100}function consoleWarn(t){}function consoleError(t){}function deprecate(t,e){e=Array.isArray(e)?e.slice(0,-1).map(l=>`'${l}'`).join(", ")+` or '${e.at(-1)}'`:`'${e}'`}const delta=.20689655172413793,cielabForwardTransform=t=>t>delta**3?Math.cbrt(t):t/(3*delta**2)+4/29,cielabReverseTransform=t=>t>delta?t**3:3*delta**2*(t-4/29);function fromXYZ$1(t){const e=cielabForwardTransform,l=e(t[1]);return[116*l-16,500*(e(t[0]/.95047)-l),200*(l-e(t[2]/1.08883))]}function toXYZ$1(t){const e=cielabReverseTransform,l=(t[0]+16)/116;return[e(l+t[1]/500)*.95047,e(l),e(l-t[2]/200)*1.08883]}const srgbForwardMatrix=[[3.2406,-1.5372,-.4986],[-.9689,1.8758,.0415],[.0557,-.204,1.057]],srgbForwardTransform=t=>t<=.0031308?t*12.92:1.055*t**(1/2.4)-.055,srgbReverseMatrix=[[.4124,.3576,.1805],[.2126,.7152,.0722],[.0193,.1192,.9505]],srgbReverseTransform=t=>t<=.04045?t/12.92:((t+.055)/1.055)**2.4;function fromXYZ(t){const e=Array(3),l=srgbForwardTransform,n=srgbForwardMatrix;for(let u=0;u<3;++u)e[u]=Math.round(clamp(l(n[u][0]*t[0]+n[u][1]*t[1]+n[u][2]*t[2]))*255);return{r:e[0],g:e[1],b:e[2]}}function toXYZ(t){let{r:e,g:l,b:n}=t;const u=[0,0,0],c=srgbReverseTransform,y=srgbReverseMatrix;e=c(e/255),l=c(l/255),n=c(n/255);for(let b=0;b<3;++b)u[b]=y[b][0]*e+y[b][1]*l+y[b][2]*n;return u}function isCssColor(t){return!!t&&/^(#|var\(--|(rgb|hsl)a?\()/.test(t)}function isParsableColor(t){return isCssColor(t)&&!/^((rgb|hsl)a?\()?var\(--/.test(t)}const cssColorRe=/^(?<fn>(?:rgb|hsl)a?)\((?<values>.+)\)/,mappers={rgb:(t,e,l,n)=>({r:t,g:e,b:l,a:n}),rgba:(t,e,l,n)=>({r:t,g:e,b:l,a:n}),hsl:(t,e,l,n)=>HSLtoRGB({h:t,s:e,l,a:n}),hsla:(t,e,l,n)=>HSLtoRGB({h:t,s:e,l,a:n}),hsv:(t,e,l,n)=>HSVtoRGB({h:t,s:e,v:l,a:n}),hsva:(t,e,l,n)=>HSVtoRGB({h:t,s:e,v:l,a:n})};function parseColor(t){if(typeof t=="number")return{r:(t&16711680)>>16,g:(t&65280)>>8,b:t&255};if(typeof t=="string"&&cssColorRe.test(t)){const{groups:e}=t.match(cssColorRe),{fn:l,values:n}=e,u=n.split(/,\s*/).map(c=>c.endsWith("%")&&["hsl","hsla","hsv","hsva"].includes(l)?parseFloat(c)/100:parseFloat(c));return mappers[l](...u)}else if(typeof t=="string"){let e=t.startsWith("#")?t.slice(1):t;return[3,4].includes(e.length)?e=e.split("").map(l=>l+l).join(""):[6,8].includes(e.length),HexToRGB(e)}else if(typeof t=="object"){if(has(t,["r","g","b"]))return t;if(has(t,["h","s","l"]))return HSVtoRGB(HSLtoHSV(t));if(has(t,["h","s","v"]))return HSVtoRGB(t)}throw new TypeError(`Invalid color: ${t==null?t:String(t)||t.constructor.name}
- Expected #hex, #hexa, rgb(), rgba(), hsl(), hsla(), object or number`)}function HSVtoRGB(t){const{h:e,s:l,v:n,a:u}=t,c=b=>{const m=(b+e/60)%6;return n-n*l*Math.max(Math.min(m,4-m,1),0)},y=[c(5),c(3),c(1)].map(b=>Math.round(b*255));return{r:y[0],g:y[1],b:y[2],a:u}}function HSLtoRGB(t){return HSVtoRGB(HSLtoHSV(t))}function RGBtoHSV(t){if(!t)return{h:0,s:1,v:1,a:1};const e=t.r/255,l=t.g/255,n=t.b/255,u=Math.max(e,l,n),c=Math.min(e,l,n);let y=0;u!==c&&(u===e?y=60*(0+(l-n)/(u-c)):u===l?y=60*(2+(n-e)/(u-c)):u===n&&(y=60*(4+(e-l)/(u-c)))),y<0&&(y=y+360);const b=u===0?0:(u-c)/u,m=[y,b,u];return{h:m[0],s:m[1],v:m[2],a:t.a}}function HSVtoHSL(t){const{h:e,s:l,v:n,a:u}=t,c=n-n*l/2,y=c===1||c===0?0:(n-c)/Math.min(c,1-c);return{h:e,s:y,l:c,a:u}}function HSLtoHSV(t){const{h:e,s:l,l:n,a:u}=t,c=n+l*Math.min(n,1-n),y=c===0?0:2-2*n/c;return{h:e,s:y,v:c,a:u}}function RGBtoCSS(t){let{r:e,g:l,b:n,a:u}=t;return u===void 0?`rgb(${e}, ${l}, ${n})`:`rgba(${e}, ${l}, ${n}, ${u})`}function HSVtoCSS(t){return RGBtoCSS(HSVtoRGB(t))}function toHex(t){const e=Math.round(t).toString(16);return("00".substr(0,2-e.length)+e).toUpperCase()}function RGBtoHex(t){let{r:e,g:l,b:n,a:u}=t;return`#${[toHex(e),toHex(l),toHex(n),u!==void 0?toHex(Math.round(u*255)):""].join("")}`}function HexToRGB(t){t=parseHex(t);let[e,l,n,u]=chunk(t,2).map(c=>parseInt(c,16));return u=u===void 0?u:u/255,{r:e,g:l,b:n,a:u}}function HexToHSV(t){const e=HexToRGB(t);return RGBtoHSV(e)}function HSVtoHex(t){return RGBtoHex(HSVtoRGB(t))}function parseHex(t){return t.startsWith("#")&&(t=t.slice(1)),t=t.replace(/([^0-9a-f])/gi,"F"),(t.length===3||t.length===4)&&(t=t.split("").map(e=>e+e).join("")),t.length!==6&&(t=padEnd(padEnd(t,6),8,"F")),t}function lighten(t,e){const l=fromXYZ$1(toXYZ(t));return l[0]=l[0]+e*10,fromXYZ(toXYZ$1(l))}function darken(t,e){const l=fromXYZ$1(toXYZ(t));return l[0]=l[0]-e*10,fromXYZ(toXYZ$1(l))}function getLuma(t){const e=parseColor(t);return toXYZ(e)[1]}function getContrast(t,e){const l=getLuma(t),n=getLuma(e),u=Math.max(l,n),c=Math.min(l,n);return(u+.05)/(c+.05)}function getForeground(t){const e=Math.abs(APCAcontrast(parseColor(0),parseColor(t)));return Math.abs(APCAcontrast(parseColor(16777215),parseColor(t)))>Math.min(e,50)?"#fff":"#000"}function propsFactory$1(t,e){return l=>Object.keys(t).reduce((n,u)=>{const y=typeof t[u]=="object"&&t[u]!=null&&!Array.isArray(t[u])?t[u]:{type:t[u]};return l&&u in l?n[u]={...y,default:l[u]}:n[u]=y,e&&!n[u].source&&(n[u].source=e),n},{})}const makeComponentProps=propsFactory$1({class:[String,Array,Object],style:{type:[String,Array,Object],default:null}},"component");function getCurrentInstance(t,e){const l=getCurrentInstance$1();if(!l)throw new Error(`[Vuetify] ${t} must be called from inside a setup function`);return l}function getCurrentInstanceName(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"composables";const e=getCurrentInstance(t).type;return toKebabCase(e?.aliasName||e?.name)}let _uid=0,_map=new WeakMap;function getUid(){const t=getCurrentInstance("getUid");if(_map.has(t))return _map.get(t);{const e=_uid++;return _map.set(t,e),e}}getUid.reset=()=>{_uid=0,_map=new WeakMap};function injectSelf(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:getCurrentInstance("injectSelf");const{provides:l}=e;if(l&&t in l)return l[t]}const DefaultsSymbol=Symbol.for("vuetify:defaults");function createDefaults(t){return ref(t)}function injectDefaults(){const t=inject$1(DefaultsSymbol);if(!t)throw new Error("[Vuetify] Could not find defaults instance");return t}function provideDefaults(t,e){const l=injectDefaults(),n=ref(t),u=computed(()=>{if(unref(e?.disabled))return l.value;const y=unref(e?.scoped),b=unref(e?.reset),m=unref(e?.root);if(n.value==null&&!(y||b||m))return l.value;let O=mergeDeep(n.value,{prev:l.value});if(y)return O;if(b||m){const N=Number(b||1/0);for(let L=0;L<=N&&!(!O||!("prev"in O));L++)O=O.prev;return O&&typeof m=="string"&&m in O&&(O=mergeDeep(mergeDeep(O,{prev:O}),O[m])),O}return O.prev?mergeDeep(O.prev,O):O});return provide(DefaultsSymbol,u),u}function propIsDefined(t,e){return typeof t.props?.[e]<"u"||typeof t.props?.[toKebabCase(e)]<"u"}function internalUseDefaults(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=arguments.length>1?arguments[1]:void 0,l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:injectDefaults();const n=getCurrentInstance("useDefaults");if(e=e??n.type.name??n.type.__name,!e)throw new Error("[Vuetify] Could not determine component name");const u=computed(()=>l.value?.[t._as??e]),c=new Proxy(t,{get(m,O){const N=Reflect.get(m,O);return O==="class"||O==="style"?[u.value?.[O],N].filter(L=>L!=null):typeof O=="string"&&!propIsDefined(n.vnode,O)?u.value?.[O]!==void 0?u.value?.[O]:l.value?.global?.[O]!==void 0?l.value?.global?.[O]:N:N}}),y=shallowRef();watchEffect(()=>{if(u.value){const m=Object.entries(u.value).filter(O=>{let[N]=O;return N.startsWith(N[0].toUpperCase())});y.value=m.length?Object.fromEntries(m):void 0}else y.value=void 0});function b(){const m=injectSelf(DefaultsSymbol,n);provide(DefaultsSymbol,computed(()=>y.value?mergeDeep(m?.value??{},y.value):m?.value))}return{props:c,provideSubDefaults:b}}function useDefaults(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=arguments.length>1?arguments[1]:void 0;const{props:l,provideSubDefaults:n}=internalUseDefaults(t,e);return n(),l}function defineComponent(t){if(t._setup=t._setup??t.setup,!t.name)return t;if(t._setup){t.props=propsFactory$1(t.props??{},t.name)();const e=Object.keys(t.props).filter(l=>l!=="class"&&l!=="style");t.filterProps=function(n){return pick(n,e)},t.props._as=String,t.setup=function(n,u){const c=injectDefaults();if(!c.value)return t._setup(n,u);const{props:y,provideSubDefaults:b}=internalUseDefaults(n,n._as??t.name,c),m=t._setup(y,u);return b(),m}}return t}function genericComponent(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return e=>(t?defineComponent:defineComponent$1)(e)}function defineFunctionalComponent(t,e){return e.props=t,e}function createSimpleFunctional(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"div",l=arguments.length>2?arguments[2]:void 0;return genericComponent()({name:l??capitalize(camelize(t.replace(/__/g,"-"))),props:{tag:{type:String,default:e},...makeComponentProps()},setup(n,u){let{slots:c}=u;return()=>h(n.tag,{class:[t,n.class],style:n.style},c.default?.())}})}function attachedRoot(t){if(typeof t.getRootNode!="function"){for(;t.parentNode;)t=t.parentNode;return t!==document?null:document}const e=t.getRootNode();return e!==document&&e.getRootNode({composed:!0})!==document?null:e}const standardEasing="cubic-bezier(0.4, 0, 0.2, 1)",deceleratedEasing="cubic-bezier(0.0, 0, 0.2, 1)",acceleratedEasing="cubic-bezier(0.4, 0, 1, 1)";function getScrollParent(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;for(;t;){if(e?isPotentiallyScrollable(t):hasScrollbar(t))return t;t=t.parentElement}return document.scrollingElement}function getScrollParents(t,e){const l=[];if(e&&t&&!e.contains(t))return l;for(;t&&(hasScrollbar(t)&&l.push(t),t!==e);)t=t.parentElement;return l}function hasScrollbar(t){if(!t||t.nodeType!==Node.ELEMENT_NODE)return!1;const e=window.getComputedStyle(t);return e.overflowY==="scroll"||e.overflowY==="auto"&&t.scrollHeight>t.clientHeight}function isPotentiallyScrollable(t){if(!t||t.nodeType!==Node.ELEMENT_NODE)return!1;const e=window.getComputedStyle(t);return["scroll","auto"].includes(e.overflowY)}function isFixedPosition(t){for(;t;){if(window.getComputedStyle(t).position==="fixed")return!0;t=t.offsetParent}return!1}function useRender(t){const e=getCurrentInstance("useRender");e.render=t}function useProxiedModel(t,e,l){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:L=>L,u=arguments.length>4&&arguments[4]!==void 0?arguments[4]:L=>L;const c=getCurrentInstance("useProxiedModel"),y=ref(t[e]!==void 0?t[e]:l),b=toKebabCase(e),O=computed(b!==e?()=>(t[e],!!((c.vnode.props?.hasOwnProperty(e)||c.vnode.props?.hasOwnProperty(b))&&(c.vnode.props?.hasOwnProperty(`onUpdate:${e}`)||c.vnode.props?.hasOwnProperty(`onUpdate:${b}`)))):()=>(t[e],!!(c.vnode.props?.hasOwnProperty(e)&&c.vnode.props?.hasOwnProperty(`onUpdate:${e}`))));useToggleScope(()=>!O.value,()=>{watch(()=>t[e],L=>{y.value=L})});const N=computed({get(){const L=t[e];return n(O.value?L:y.value)},set(L){const G=u(L),q=toRaw(O.value?t[e]:y.value);q===G||n(q)===L||(y.value=G,c?.emit(`update:${e}`,G))}});return Object.defineProperty(N,"externalValue",{get:()=>O.value?t[e]:y.value}),N}const en={badge:"Badge",open:"Open",close:"Close",dismiss:"Dismiss",confirmEdit:{ok:"OK",cancel:"Cancel"},dataIterator:{noResultsText:"No matching records found",loadingText:"Loading items..."},dataTable:{itemsPerPageText:"Rows per page:",ariaLabel:{sortDescending:"Sorted descending.",sortAscending:"Sorted ascending.",sortNone:"Not sorted.",activateNone:"Activate to remove sorting.",activateDescending:"Activate to sort descending.",activateAscending:"Activate to sort ascending."},sortBy:"Sort by"},dataFooter:{itemsPerPageText:"Items per page:",itemsPerPageAll:"All",nextPage:"Next page",prevPage:"Previous page",firstPage:"First page",lastPage:"Last page",pageText:"{0}-{1} of {2}"},dateRangeInput:{divider:"to"},datePicker:{itemsSelected:"{0} selected",range:{title:"Select dates",header:"Enter dates"},title:"Select date",header:"Enter date",input:{placeholder:"Enter date"}},noDataText:"No data available",carousel:{prev:"Previous visual",next:"Next visual",ariaLabel:{delimiter:"Carousel slide {0} of {1}"}},calendar:{moreEvents:"{0} more",today:"Today"},input:{clear:"Clear {0}",prependAction:"{0} prepended action",appendAction:"{0} appended action",otp:"Please enter OTP character {0}"},fileInput:{counter:"{0} files",counterSize:"{0} files ({1} in total)"},timePicker:{am:"AM",pm:"PM",title:"Select Time"},pagination:{ariaLabel:{root:"Pagination Navigation",next:"Next page",previous:"Previous page",page:"Go to page {0}",currentPage:"Page {0}, Current page",first:"First page",last:"Last page"}},stepper:{next:"Next",prev:"Previous"},rating:{ariaLabel:{item:"Rating {0} of {1}"}},loading:"Loading...",infiniteScroll:{loadMore:"Load more",empty:"No more"}},LANG_PREFIX="$vuetify.",replace=(t,e)=>t.replace(/\{(\d+)\}/g,(l,n)=>String(e[+n])),createTranslateFunction=(t,e,l)=>function(n){for(var u=arguments.length,c=new Array(u>1?u-1:0),y=1;y<u;y++)c[y-1]=arguments[y];if(!n.startsWith(LANG_PREFIX))return replace(n,c);const b=n.replace(LANG_PREFIX,""),m=t.value&&l.value[t.value],O=e.value&&l.value[e.value];let N=getObjectValueByPath(m,b,null);return N||(`${n}${t.value}`,N=getObjectValueByPath(O,b,null)),N||(N=n),typeof N!="string"&&(N=n),replace(N,c)};function createNumberFunction(t,e){return(l,n)=>new Intl.NumberFormat([t.value,e.value],n).format(l)}function useProvided(t,e,l){const n=useProxiedModel(t,e,t[e]??l.value);return n.value=t[e]??l.value,watch(l,u=>{t[e]==null&&(n.value=l.value)}),n}function createProvideFunction(t){return e=>{const l=useProvided(e,"locale",t.current),n=useProvided(e,"fallback",t.fallback),u=useProvided(e,"messages",t.messages);return{name:"vuetify",current:l,fallback:n,messages:u,t:createTranslateFunction(l,n,u),n:createNumberFunction(l,n),provide:createProvideFunction({current:l,fallback:n,messages:u})}}}function createVuetifyAdapter(t){const e=shallowRef(t?.locale??"en"),l=shallowRef(t?.fallback??"en"),n=ref({en,...t?.messages});return{name:"vuetify",current:e,fallback:l,messages:n,t:createTranslateFunction(e,l,n),n:createNumberFunction(e,l),provide:createProvideFunction({current:e,fallback:l,messages:n})}}const LocaleSymbol=Symbol.for("vuetify:locale");function isLocaleInstance(t){return t.name!=null}function createLocale(t){const e=t?.adapter&&isLocaleInstance(t?.adapter)?t?.adapter:createVuetifyAdapter(t),l=createRtl(e,t);return{...e,...l}}function useLocale(){const t=inject$1(LocaleSymbol);if(!t)throw new Error("[Vuetify] Could not find injected locale instance");return t}function provideLocale(t){const e=inject$1(LocaleSymbol);if(!e)throw new Error("[Vuetify] Could not find injected locale instance");const l=e.provide(t),n=provideRtl(l,e.rtl,t),u={...l,...n};return provide(LocaleSymbol,u),u}function genDefaults$3(){return{af:!1,ar:!0,bg:!1,ca:!1,ckb:!1,cs:!1,de:!1,el:!1,en:!1,es:!1,et:!1,fa:!0,fi:!1,fr:!1,hr:!1,hu:!1,he:!0,id:!1,it:!1,ja:!1,km:!1,ko:!1,lv:!1,lt:!1,nl:!1,no:!1,pl:!1,pt:!1,ro:!1,ru:!1,sk:!1,sl:!1,srCyrl:!1,srLatn:!1,sv:!1,th:!1,tr:!1,az:!1,uk:!1,vi:!1,zhHans:!1,zhHant:!1}}function createRtl(t,e){const l=ref(e?.rtl??genDefaults$3()),n=computed(()=>l.value[t.current.value]??!1);return{isRtl:n,rtl:l,rtlClasses:computed(()=>`v-locale--is-${n.value?"rtl":"ltr"}`)}}function provideRtl(t,e,l){const n=computed(()=>l.rtl??e.value[t.current.value]??!1);return{isRtl:n,rtl:e,rtlClasses:computed(()=>`v-locale--is-${n.value?"rtl":"ltr"}`)}}function useRtl(){const t=inject$1(LocaleSymbol);if(!t)throw new Error("[Vuetify] Could not find injected rtl instance");return{isRtl:t.isRtl,rtlClasses:t.rtlClasses}}const firstDay={"001":1,AD:1,AE:6,AF:6,AG:0,AI:1,AL:1,AM:1,AN:1,AR:1,AS:0,AT:1,AU:1,AX:1,AZ:1,BA:1,BD:0,BE:1,BG:1,BH:6,BM:1,BN:1,BR:0,BS:0,BT:0,BW:0,BY:1,BZ:0,CA:0,CH:1,CL:1,CM:1,CN:1,CO:0,CR:1,CY:1,CZ:1,DE:1,DJ:6,DK:1,DM:0,DO:0,DZ:6,EC:1,EE:1,EG:6,ES:1,ET:0,FI:1,FJ:1,FO:1,FR:1,GB:1,"GB-alt-variant":0,GE:1,GF:1,GP:1,GR:1,GT:0,GU:0,HK:0,HN:0,HR:1,HU:1,ID:0,IE:1,IL:0,IN:0,IQ:6,IR:6,IS:1,IT:1,JM:0,JO:6,JP:0,KE:0,KG:1,KH:0,KR:0,KW:6,KZ:1,LA:0,LB:1,LI:1,LK:1,LT:1,LU:1,LV:1,LY:6,MC:1,MD:1,ME:1,MH:0,MK:1,MM:0,MN:1,MO:0,MQ:1,MT:0,MV:5,MX:0,MY:1,MZ:0,NI:0,NL:1,NO:1,NP:0,NZ:1,OM:6,PA:0,PE:0,PH:0,PK:0,PL:1,PR:0,PT:0,PY:0,QA:6,RE:1,RO:1,RS:1,RU:1,SA:0,SD:6,SE:1,SG:0,SI:1,SK:1,SM:1,SV:0,SY:6,TH:0,TJ:1,TM:1,TR:1,TT:0,TW:0,UA:1,UM:0,US:0,UY:1,UZ:1,VA:1,VE:0,VI:0,VN:1,WS:0,XK:1,YE:0,ZA:0,ZW:0};function getWeekArray(t,e,l){const n=[];let u=[];const c=startOfMonth(t),y=endOfMonth(t),b=l??firstDay[e.slice(-2).toUpperCase()]??0,m=(c.getDay()-b+7)%7,O=(y.getDay()-b+7)%7;for(let N=0;N<m;N++){const L=new Date(c);L.setDate(L.getDate()-(m-N)),u.push(L)}for(let N=1;N<=y.getDate();N++){const L=new Date(t.getFullYear(),t.getMonth(),N);u.push(L),u.length===7&&(n.push(u),u=[])}for(let N=1;N<7-O;N++){const L=new Date(y);L.setDate(L.getDate()+N),u.push(L)}return u.length>0&&n.push(u),n}function startOfWeek(t,e,l){const n=l??firstDay[e.slice(-2).toUpperCase()]??0,u=new Date(t);for(;u.getDay()!==n;)u.setDate(u.getDate()-1);return u}function endOfWeek(t,e){const l=new Date(t),n=((firstDay[e.slice(-2).toUpperCase()]??0)+6)%7;for(;l.getDay()!==n;)l.setDate(l.getDate()+1);return l}function startOfMonth(t){return new Date(t.getFullYear(),t.getMonth(),1)}function endOfMonth(t){return new Date(t.getFullYear(),t.getMonth()+1,0)}function parseLocalDate(t){const e=t.split("-").map(Number);return new Date(e[0],e[1]-1,e[2])}const _YYYMMDD=/^([12]\d{3}-([1-9]|0[1-9]|1[0-2])-([1-9]|0[1-9]|[12]\d|3[01]))$/;function date(t){if(t==null)return new Date;if(t instanceof Date)return t;if(typeof t=="string"){let e;if(_YYYMMDD.test(t))return parseLocalDate(t);if(e=Date.parse(t),!isNaN(e))return new Date(e)}return null}const sundayJanuarySecond2000=new Date(2e3,0,2);function getWeekdays(t,e){const l=e??firstDay[t.slice(-2).toUpperCase()]??0;return createRange(7).map(n=>{const u=new Date(sundayJanuarySecond2000);return u.setDate(sundayJanuarySecond2000.getDate()+l+n),new Intl.DateTimeFormat(t,{weekday:"narrow"}).format(u)})}function format(t,e,l,n){const u=date(t)??new Date,c=n?.[e];if(typeof c=="function")return c(u,e,l);let y={};switch(e){case"fullDate":y={year:"numeric",month:"long",day:"numeric"};break;case"fullDateWithWeekday":y={weekday:"long",year:"numeric",month:"long",day:"numeric"};break;case"normalDate":const b=u.getDate(),m=new Intl.DateTimeFormat(l,{month:"long"}).format(u);return`${b} ${m}`;case"normalDateWithWeekday":y={weekday:"short",day:"numeric",month:"short"};break;case"shortDate":y={month:"short",day:"numeric"};break;case"year":y={year:"numeric"};break;case"month":y={month:"long"};break;case"monthShort":y={month:"short"};break;case"monthAndYear":y={month:"long",year:"numeric"};break;case"monthAndDate":y={month:"long",day:"numeric"};break;case"weekday":y={weekday:"long"};break;case"weekdayShort":y={weekday:"short"};break;case"dayOfMonth":return new Intl.NumberFormat(l).format(u.getDate());case"hours12h":y={hour:"numeric",hour12:!0};break;case"hours24h":y={hour:"numeric",hour12:!1};break;case"minutes":y={minute:"numeric"};break;case"seconds":y={second:"numeric"};break;case"fullTime":y={hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullTime12h":y={hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullTime24h":y={hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;case"fullDateTime":y={year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullDateTime12h":y={year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullDateTime24h":y={year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;case"keyboardDate":y={year:"numeric",month:"2-digit",day:"2-digit"};break;case"keyboardDateTime":y={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;case"keyboardDateTime12h":y={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"keyboardDateTime24h":y={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;default:y=c??{timeZone:"UTC",timeZoneName:"short"}}return new Intl.DateTimeFormat(l,y).format(u)}function toISO(t,e){const l=t.toJsDate(e),n=l.getFullYear(),u=padStart(String(l.getMonth()+1),2,"0"),c=padStart(String(l.getDate()),2,"0");return`${n}-${u}-${c}`}function parseISO(t){const[e,l,n]=t.split("-").map(Number);return new Date(e,l-1,n)}function addMinutes(t,e){const l=new Date(t);return l.setMinutes(l.getMinutes()+e),l}function addHours(t,e){const l=new Date(t);return l.setHours(l.getHours()+e),l}function addDays(t,e){const l=new Date(t);return l.setDate(l.getDate()+e),l}function addWeeks(t,e){const l=new Date(t);return l.setDate(l.getDate()+e*7),l}function addMonths(t,e){const l=new Date(t);return l.setDate(1),l.setMonth(l.getMonth()+e),l}function getYear(t){return t.getFullYear()}function getMonth(t){return t.getMonth()}function getDate(t){return t.getDate()}function getNextMonth(t){return new Date(t.getFullYear(),t.getMonth()+1,1)}function getPreviousMonth(t){return new Date(t.getFullYear(),t.getMonth()-1,1)}function getHours(t){return t.getHours()}function getMinutes(t){return t.getMinutes()}function startOfYear(t){return new Date(t.getFullYear(),0,1)}function endOfYear(t){return new Date(t.getFullYear(),11,31)}function isWithinRange(t,e){return isAfter(t,e[0])&&isBefore(t,e[1])}function isValid(t){const e=new Date(t);return e instanceof Date&&!isNaN(e.getTime())}function isAfter(t,e){return t.getTime()>e.getTime()}function isAfterDay(t,e){return isAfter(startOfDay(t),startOfDay(e))}function isBefore(t,e){return t.getTime()<e.getTime()}function isEqual(t,e){return t.getTime()===e.getTime()}function isSameDay(t,e){return t.getDate()===e.getDate()&&t.getMonth()===e.getMonth()&&t.getFullYear()===e.getFullYear()}function isSameMonth(t,e){return t.getMonth()===e.getMonth()&&t.getFullYear()===e.getFullYear()}function isSameYear(t,e){return t.getFullYear()===e.getFullYear()}function getDiff(t,e,l){const n=new Date(t),u=new Date(e);switch(l){case"years":return n.getFullYear()-u.getFullYear();case"quarters":return Math.floor((n.getMonth()-u.getMonth()+(n.getFullYear()-u.getFullYear())*12)/4);case"months":return n.getMonth()-u.getMonth()+(n.getFullYear()-u.getFullYear())*12;case"weeks":return Math.floor((n.getTime()-u.getTime())/(1e3*60*60*24*7));case"days":return Math.floor((n.getTime()-u.getTime())/(1e3*60*60*24));case"hours":return Math.floor((n.getTime()-u.getTime())/(1e3*60*60));case"minutes":return Math.floor((n.getTime()-u.getTime())/(1e3*60));case"seconds":return Math.floor((n.getTime()-u.getTime())/1e3);default:return n.getTime()-u.getTime()}}function setHours(t,e){const l=new Date(t);return l.setHours(e),l}function setMinutes(t,e){const l=new Date(t);return l.setMinutes(e),l}function setMonth(t,e){const l=new Date(t);return l.setMonth(e),l}function setDate(t,e){const l=new Date(t);return l.setDate(e),l}function setYear(t,e){const l=new Date(t);return l.setFullYear(e),l}function startOfDay(t){return new Date(t.getFullYear(),t.getMonth(),t.getDate(),0,0,0,0)}function endOfDay(t){return new Date(t.getFullYear(),t.getMonth(),t.getDate(),23,59,59,999)}class VuetifyDateAdapter{constructor(e){this.locale=e.locale,this.formats=e.formats}date(e){return date(e)}toJsDate(e){return e}toISO(e){return toISO(this,e)}parseISO(e){return parseISO(e)}addMinutes(e,l){return addMinutes(e,l)}addHours(e,l){return addHours(e,l)}addDays(e,l){return addDays(e,l)}addWeeks(e,l){return addWeeks(e,l)}addMonths(e,l){return addMonths(e,l)}getWeekArray(e,l){return getWeekArray(e,this.locale,l?Number(l):void 0)}startOfWeek(e,l){return startOfWeek(e,this.locale,l?Number(l):void 0)}endOfWeek(e){return endOfWeek(e,this.locale)}startOfMonth(e){return startOfMonth(e)}endOfMonth(e){return endOfMonth(e)}format(e,l){return format(e,l,this.locale,this.formats)}isEqual(e,l){return isEqual(e,l)}isValid(e){return isValid(e)}isWithinRange(e,l){return isWithinRange(e,l)}isAfter(e,l){return isAfter(e,l)}isAfterDay(e,l){return isAfterDay(e,l)}isBefore(e,l){return!isAfter(e,l)&&!isEqual(e,l)}isSameDay(e,l){return isSameDay(e,l)}isSameMonth(e,l){return isSameMonth(e,l)}isSameYear(e,l){return isSameYear(e,l)}setMinutes(e,l){return setMinutes(e,l)}setHours(e,l){return setHours(e,l)}setMonth(e,l){return setMonth(e,l)}setDate(e,l){return setDate(e,l)}setYear(e,l){return setYear(e,l)}getDiff(e,l,n){return getDiff(e,l,n)}getWeekdays(e){return getWeekdays(this.locale,e?Number(e):void 0)}getYear(e){return getYear(e)}getMonth(e){return getMonth(e)}getDate(e){return getDate(e)}getNextMonth(e){return getNextMonth(e)}getPreviousMonth(e){return getPreviousMonth(e)}getHours(e){return getHours(e)}getMinutes(e){return getMinutes(e)}startOfDay(e){return startOfDay(e)}endOfDay(e){return endOfDay(e)}startOfYear(e){return startOfYear(e)}endOfYear(e){return endOfYear(e)}}const DateOptionsSymbol=Symbol.for("vuetify:date-options"),DateAdapterSymbol=Symbol.for("vuetify:date-adapter");function createDate(t,e){const l=mergeDeep({adapter:VuetifyDateAdapter,locale:{af:"af-ZA",bg:"bg-BG",ca:"ca-ES",ckb:"",cs:"cs-CZ",de:"de-DE",el:"el-GR",en:"en-US",et:"et-EE",fa:"fa-IR",fi:"fi-FI",hr:"hr-HR",hu:"hu-HU",he:"he-IL",id:"id-ID",it:"it-IT",ja:"ja-JP",ko:"ko-KR",lv:"lv-LV",lt:"lt-LT",nl:"nl-NL",no:"no-NO",pl:"pl-PL",pt:"pt-PT",ro:"ro-RO",ru:"ru-RU",sk:"sk-SK",sl:"sl-SI",srCyrl:"sr-SP",srLatn:"sr-SP",sv:"sv-SE",th:"th-TH",tr:"tr-TR",az:"az-AZ",uk:"uk-UA",vi:"vi-VN",zhHans:"zh-CN",zhHant:"zh-TW"}},t);return{options:l,instance:createInstance$1(l,e)}}function createInstance$1(t,e){const l=reactive(typeof t.adapter=="function"?new t.adapter({locale:t.locale[e.current.value]??e.current.value,formats:t.formats}):t.adapter);return watch(e.current,n=>{l.locale=t.locale[n]??n??l.locale}),l}function useDate(){const t=inject$1(DateOptionsSymbol);if(!t)throw new Error("[Vuetify] Could not find injected date options");const e=useLocale();return createInstance$1(t,e)}function getWeek(t,e){const l=t.toJsDate(e);let n=l.getFullYear(),u=new Date(n,0,1);if(l<u)n=n-1,u=new Date(n,0,1);else{const b=new Date(n+1,0,1);l>=b&&(n=n+1,u=b)}const c=Math.abs(l.getTime()-u.getTime()),y=Math.ceil(c/(1e3*60*60*24));return Math.floor(y/7)+1}const breakpoints=["sm","md","lg","xl","xxl"],DisplaySymbol=Symbol.for("vuetify:display"),defaultDisplayOptions={mobileBreakpoint:"lg",thresholds:{xs:0,sm:600,md:960,lg:1280,xl:1920,xxl:2560}},parseDisplayOptions=function(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:defaultDisplayOptions;return mergeDeep(defaultDisplayOptions,t)};function getClientWidth(t){return IN_BROWSER&&!t?window.innerWidth:typeof t=="object"&&t.clientWidth||0}function getClientHeight(t){return IN_BROWSER&&!t?window.innerHeight:typeof t=="object"&&t.clientHeight||0}function getPlatform(t){const e=IN_BROWSER&&!t?window.navigator.userAgent:"ssr";function l(J){return!!e.match(J)}const n=l(/android/i),u=l(/iphone|ipad|ipod/i),c=l(/cordova/i),y=l(/electron/i),b=l(/chrome/i),m=l(/edge/i),O=l(/firefox/i),N=l(/opera/i),L=l(/win/i),G=l(/mac/i),q=l(/linux/i);return{android:n,ios:u,cordova:c,electron:y,chrome:b,edge:m,firefox:O,opera:N,win:L,mac:G,linux:q,touch:SUPPORTS_TOUCH,ssr:e==="ssr"}}function createDisplay(t,e){const{thresholds:l,mobileBreakpoint:n}=parseDisplayOptions(t),u=shallowRef(getClientHeight(e)),c=shallowRef(getPlatform(e)),y=reactive({}),b=shallowRef(getClientWidth(e));function m(){u.value=getClientHeight(),b.value=getClientWidth()}function O(){m(),c.value=getPlatform()}return watchEffect(()=>{const N=b.value<l.sm,L=b.value<l.md&&!N,G=b.value<l.lg&&!(L||N),q=b.value<l.xl&&!(G||L||N),J=b.value<l.xxl&&!(q||G||L||N),fe=b.value>=l.xxl,ve=N?"xs":L?"sm":G?"md":q?"lg":J?"xl":"xxl",ne=typeof n=="number"?n:l[n],Ue=b.value<ne;y.xs=N,y.sm=L,y.md=G,y.lg=q,y.xl=J,y.xxl=fe,y.smAndUp=!N,y.mdAndUp=!(N||L),y.lgAndUp=!(N||L||G),y.xlAndUp=!(N||L||G||q),y.smAndDown=!(G||q||J||fe),y.mdAndDown=!(q||J||fe),y.lgAndDown=!(J||fe),y.xlAndDown=!fe,y.name=ve,y.height=u.value,y.width=b.value,y.mobile=Ue,y.mobileBreakpoint=n,y.platform=c.value,y.thresholds=l}),IN_BROWSER&&window.addEventListener("resize",m,{passive:!0}),{...toRefs(y),update:O,ssr:!!e}}const makeDisplayProps=propsFactory$1({mobile:{type:Boolean,default:!1},mobileBreakpoint:[Number,String]},"display");function useDisplay(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:getCurrentInstanceName();const l=inject$1(DisplaySymbol);if(!l)throw new Error("Could not find Vuetify display injection");const n=computed(()=>{if(t.mobile!=null)return t.mobile;if(!t.mobileBreakpoint)return l.mobile.value;const c=typeof t.mobileBreakpoint=="number"?t.mobileBreakpoint:l.thresholds.value[t.mobileBreakpoint];return l.width.value<c}),u=computed(()=>e?{[`${e}--mobile`]:n.value}:{});return{...l,displayClasses:u,mobile:n}}const GoToSymbol=Symbol.for("vuetify:goto");function genDefaults$2(){return{container:void 0,duration:300,layout:!1,offset:0,easing:"easeInOutCubic",patterns:{linear:t=>t,easeInQuad:t=>t**2,easeOutQuad:t=>t*(2-t),easeInOutQuad:t=>t<.5?2*t**2:-1+(4-2*t)*t,easeInCubic:t=>t**3,easeOutCubic:t=>--t**3+1,easeInOutCubic:t=>t<.5?4*t**3:(t-1)*(2*t-2)*(2*t-2)+1,easeInQuart:t=>t**4,easeOutQuart:t=>1- --t**4,easeInOutQuart:t=>t<.5?8*t**4:1-8*--t**4,easeInQuint:t=>t**5,easeOutQuint:t=>1+--t**5,easeInOutQuint:t=>t<.5?16*t**5:1+16*--t**5}}}function getContainer(t){return getTarget$1(t)??(document.scrollingElement||document.body)}function getTarget$1(t){return typeof t=="string"?document.querySelector(t):refElement(t)}function getOffset$1(t,e,l){if(typeof t=="number")return e&&l?-t:t;let n=getTarget$1(t),u=0;for(;n;)u+=e?n.offsetLeft:n.offsetTop,n=n.offsetParent;return u}function createGoTo(t,e){return{rtl:e.isRtl,options:mergeDeep(genDefaults$2(),t)}}async function scrollTo(t,e,l,n){const u=l?"scrollLeft":"scrollTop",c=mergeDeep(n?.options??genDefaults$2(),e),y=n?.rtl.value,b=(typeof t=="number"?t:getTarget$1(t))??0,m=c.container==="parent"&&b instanceof HTMLElement?b.parentElement:getContainer(c.container),O=typeof c.easing=="function"?c.easing:c.patterns[c.easing];if(!O)throw new TypeError(`Easing function "${c.easing}" not found.`);let N;if(typeof b=="number")N=getOffset$1(b,l,y);else if(N=getOffset$1(b,l,y)-getOffset$1(m,l,y),c.layout){const J=window.getComputedStyle(b).getPropertyValue("--v-layout-top");J&&(N-=parseInt(J,10))}N+=c.offset,N=clampTarget(m,N,!!y,!!l);const L=m[u]??0;if(N===L)return Promise.resolve(N);const G=performance.now();return new Promise(q=>requestAnimationFrame(function J(fe){const ne=(fe-G)/c.duration,Ue=Math.floor(L+(N-L)*O(clamp(ne,0,1)));if(m[u]=Ue,ne>=1&&Math.abs(Ue-m[u])<10)return q(N);if(ne>2)return q(m[u]);requestAnimationFrame(J)}))}function useGoTo(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const e=inject$1(GoToSymbol),{isRtl:l}=useRtl();if(!e)throw new Error("[Vuetify] Could not find injected goto instance");const n={...e,rtl:computed(()=>e.rtl.value||l.value)};async function u(c,y){return scrollTo(c,mergeDeep(t,y),!1,n)}return u.horizontal=async(c,y)=>scrollTo(c,mergeDeep(t,y),!0,n),u}function clampTarget(t,e,l,n){const{scrollWidth:u,scrollHeight:c}=t,[y,b]=t===document.scrollingElement?[window.innerWidth,window.innerHeight]:[t.offsetWidth,t.offsetHeight];let m,O;return n?l?(m=-(u-y),O=0):(m=0,O=u-y):(m=0,O=c+-b),Math.max(Math.min(e,O),m)}const aliases$2={collapse:"mdi-chevron-up",complete:"mdi-check",cancel:"mdi-close-circle",close:"mdi-close",delete:"mdi-close-circle",clear:"mdi-close-circle",success:"mdi-check-circle",info:"mdi-information",warning:"mdi-alert-circle",error:"mdi-close-circle",prev:"mdi-chevron-left",next:"mdi-chevron-right",checkboxOn:"mdi-checkbox-marked",checkboxOff:"mdi-checkbox-blank-outline",checkboxIndeterminate:"mdi-minus-box",delimiter:"mdi-circle",sortAsc:"mdi-arrow-up",sortDesc:"mdi-arrow-down",expand:"mdi-chevron-down",menu:"mdi-menu",subgroup:"mdi-menu-down",dropdown:"mdi-menu-down",radioOn:"mdi-radiobox-marked",radioOff:"mdi-radiobox-blank",edit:"mdi-pencil",ratingEmpty:"mdi-star-outline",ratingFull:"mdi-star",ratingHalf:"mdi-star-half-full",loading:"mdi-cached",first:"mdi-page-first",last:"mdi-page-last",unfold:"mdi-unfold-more-horizontal",file:"mdi-paperclip",plus:"mdi-plus",minus:"mdi-minus",calendar:"mdi-calendar",treeviewCollapse:"mdi-menu-down",treeviewExpand:"mdi-menu-right",eyeDropper:"mdi-eyedropper"},mdi$1={component:t=>h(VClassIcon,{...t,class:"mdi"})},IconValue$1=[String,Function,Object,Array],IconSymbol=Symbol.for("vuetify:icons"),makeIconProps$1=propsFactory$1({icon:{type:IconValue$1},tag:{type:String,required:!0}},"icon"),VComponentIcon=genericComponent()({name:"VComponentIcon",props:makeIconProps$1(),setup(t,e){let{slots:l}=e;return()=>{const n=t.icon;return createVNode(t.tag,null,{default:()=>[t.icon?createVNode(n,null,null):l.default?.()]})}}}),VSvgIcon=defineComponent({name:"VSvgIcon",inheritAttrs:!1,props:makeIconProps$1(),setup(t,e){let{attrs:l}=e;return()=>createVNode(t.tag,mergeProps(l,{style:null}),{default:()=>[createVNode("svg",{class:"v-icon__svg",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",role:"img","aria-hidden":"true"},[Array.isArray(t.icon)?t.icon.map(n=>Array.isArray(n)?createVNode("path",{d:n[0],"fill-opacity":n[1]},null):createVNode("path",{d:n},null)):createVNode("path",{d:t.icon},null)])]})}}),VLigatureIcon=defineComponent({name:"VLigatureIcon",props:makeIconProps$1(),setup(t){return()=>createVNode(t.tag,null,{default:()=>[t.icon]})}}),VClassIcon=defineComponent({name:"VClassIcon",props:makeIconProps$1(),setup(t){return()=>createVNode(t.tag,{class:t.icon},null)}});function genDefaults$1(){return{svg:{component:VSvgIcon},class:{component:VClassIcon}}}function createIcons(t){const e=genDefaults$1(),l=t?.defaultSet??"mdi";return l==="mdi"&&!e.mdi&&(e.mdi=mdi$1),mergeDeep({defaultSet:l,sets:e,aliases:{...aliases$2,vuetify:["M8.2241 14.2009L12 21L22 3H14.4459L8.2241 14.2009Z",["M7.26303 12.4733L7.00113 12L2 3H12.5261C12.5261 3 12.5261 3 12.5261 3L7.26303 12.4733Z",.6]],"vuetify-outline":"svg:M7.26 12.47 12.53 3H2L7.26 12.47ZM14.45 3 8.22 14.2 12 21 22 3H14.45ZM18.6 5 12 16.88 10.51 14.2 15.62 5ZM7.26 8.35 5.4 5H9.13L7.26 8.35Z","vuetify-play":["m6.376 13.184-4.11-7.192C1.505 4.66 2.467 3 4.003 3h8.532l-.953 1.576-.006.01-.396.677c-.429.732-.214 1.507.194 2.015.404.503 1.092.878 1.869.806a3.72 3.72 0 0 1 1.005.022c.276.053.434.143.523.237.138.146.38.635-.25 2.09-.893 1.63-1.553 1.722-1.847 1.677-.213-.033-.468-.158-.756-.406a4.95 4.95 0 0 1-.8-.927c-.39-.564-1.04-.84-1.66-.846-.625-.006-1.316.27-1.693.921l-.478.826-.911 1.506Z",["M9.093 11.552c.046-.079.144-.15.32-.148a.53.53 0 0 1 .43.207c.285.414.636.847 1.046 1.2.405.35.914.662 1.516.754 1.334.205 2.502-.698 3.48-2.495l.014-.028.013-.03c.687-1.574.774-2.852-.005-3.675-.37-.391-.861-.586-1.333-.676a5.243 5.243 0 0 0-1.447-.044c-.173.016-.393-.073-.54-.257-.145-.18-.127-.316-.082-.392l.393-.672L14.287 3h5.71c1.536 0 2.499 1.659 1.737 2.992l-7.997 13.996c-.768 1.344-2.706 1.344-3.473 0l-3.037-5.314 1.377-2.278.004-.006.004-.007.481-.831Z",.6]]}},t)}const useIcon=t=>{const e=inject$1(IconSymbol);if(!e)throw new Error("Missing Vuetify Icons provide!");return{iconData:computed(()=>{const n=unref(t);if(!n)return{component:VComponentIcon};let u=n;if(typeof u=="string"&&(u=u.trim(),u.startsWith("$")&&(u=e.aliases?.[u.slice(1)])),Array.isArray(u))return{component:VSvgIcon,icon:u};if(typeof u!="string")return{component:VComponentIcon,icon:u};const c=Object.keys(e.sets).find(m=>typeof u=="string"&&u.startsWith(`${m}:`)),y=c?u.slice(c.length+1):u;return{component:e.sets[c??e.defaultSet].component,icon:y}})}},ThemeSymbol=Symbol.for("vuetify:theme"),makeThemeProps=propsFactory$1({theme:String},"theme");function genDefaults(){return{defaultTheme:"light",variations:{colors:[],lighten:0,darken:0},themes:{light:{dark:!1,colors:{background:"#FFFFFF",surface:"#FFFFFF","surface-bright":"#FFFFFF","surface-light":"#EEEEEE","surface-variant":"#424242","on-surface-variant":"#EEEEEE",primary:"#1867C0","primary-darken-1":"#1F5592",secondary:"#48A9A6","secondary-darken-1":"#018786",error:"#B00020",info:"#2196F3",success:"#4CAF50",warning:"#FB8C00"},variables:{"border-color":"#000000","border-opacity":.12,"high-emphasis-opacity":.87,"medium-emphasis-opacity":.6,"disabled-opacity":.38,"idle-opacity":.04,"hover-opacity":.04,"focus-opacity":.12,"selected-opacity":.08,"activated-opacity":.12,"pressed-opacity":.12,"dragged-opacity":.08,"theme-kbd":"#212529","theme-on-kbd":"#FFFFFF","theme-code":"#F5F5F5","theme-on-code":"#000000"}},dark:{dark:!0,colors:{background:"#121212",surface:"#212121","surface-bright":"#ccbfd6","surface-light":"#424242","surface-variant":"#a3a3a3","on-surface-variant":"#424242",primary:"#2196F3","primary-darken-1":"#277CC1",secondary:"#54B6B2","secondary-darken-1":"#48A9A6",error:"#CF6679",info:"#2196F3",success:"#4CAF50",warning:"#FB8C00"},variables:{"border-color":"#FFFFFF","border-opacity":.12,"high-emphasis-opacity":1,"medium-emphasis-opacity":.7,"disabled-opacity":.5,"idle-opacity":.1,"hover-opacity":.04,"focus-opacity":.12,"selected-opacity":.08,"activated-opacity":.12,"pressed-opacity":.16,"dragged-opacity":.08,"theme-kbd":"#212529","theme-on-kbd":"#FFFFFF","theme-code":"#343434","theme-on-code":"#CCCCCC"}}}}}function parseThemeOptions(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:genDefaults();const e=genDefaults();if(!t)return{...e,isDisabled:!0};const l={};for(const[n,u]of Object.entries(t.themes??{})){const c=u.dark||n==="dark"?e.themes?.dark:e.themes?.light;l[n]=mergeDeep(c,u)}return mergeDeep(e,{...t,themes:l})}function createTheme(t){const e=parseThemeOptions(t),l=ref(e.defaultTheme),n=ref(e.themes),u=computed(()=>{const N={};for(const[L,G]of Object.entries(n.value)){const q=N[L]={...G,colors:{...G.colors}};if(e.variations)for(const J of e.variations.colors){const fe=q.colors[J];if(fe)for(const ve of["lighten","darken"]){const ne=ve==="lighten"?lighten:darken;for(const Ue of createRange(e.variations[ve],1))q.colors[`${J}-${ve}-${Ue}`]=RGBtoHex(ne(parseColor(fe),Ue))}}for(const J of Object.keys(q.colors)){if(/^on-[a-z]/.test(J)||q.colors[`on-${J}`])continue;const fe=`on-${J}`,ve=parseColor(q.colors[J]);q.colors[fe]=getForeground(ve)}}return N}),c=computed(()=>u.value[l.value]),y=computed(()=>{const N=[];c.value?.dark&&createCssClass(N,":root",["color-scheme: dark"]),createCssClass(N,":root",genCssVariables(c.value));for(const[J,fe]of Object.entries(u.value))createCssClass(N,`.v-theme--${J}`,[`color-scheme: ${fe.dark?"dark":"normal"}`,...genCssVariables(fe)]);const L=[],G=[],q=new Set(Object.values(u.value).flatMap(J=>Object.keys(J.colors)));for(const J of q)/^on-[a-z]/.test(J)?createCssClass(G,`.${J}`,[`color: rgb(var(--v-theme-${J})) !important`]):(createCssClass(L,`.bg-${J}`,[`--v-theme-overlay-multiplier: var(--v-theme-${J}-overlay-multiplier)`,`background-color: rgb(var(--v-theme-${J})) !important`,`color: rgb(var(--v-theme-on-${J})) !important`]),createCssClass(G,`.text-${J}`,[`color: rgb(var(--v-theme-${J})) !important`]),createCssClass(G,`.border-${J}`,[`--v-border-color: var(--v-theme-${J})`]));return N.push(...L,...G),N.map((J,fe)=>fe===0?J:` ${J}`).join("")});function b(){return{style:[{children:y.value,id:"vuetify-theme-stylesheet",nonce:e.cspNonce||!1}]}}function m(N){if(e.isDisabled)return;const L=N._context.provides.usehead;if(L)if(L.push){const G=L.push(b);IN_BROWSER&&watch(y,()=>{G.patch(b)})}else IN_BROWSER?(L.addHeadObjs(computed(b)),watchEffect(()=>L.updateDOM())):L.addHeadObjs(b());else{let q=function(){if(typeof document<"u"&&!G){const J=document.createElement("style");J.type="text/css",J.id="vuetify-theme-stylesheet",e.cspNonce&&J.setAttribute("nonce",e.cspNonce),G=J,document.head.appendChild(G)}G&&(G.innerHTML=y.value)},G=IN_BROWSER?document.getElementById("vuetify-theme-stylesheet"):null;IN_BROWSER?watch(y,q,{immediate:!0}):q()}}const O=computed(()=>e.isDisabled?void 0:`v-theme--${l.value}`);return{install:m,isDisabled:e.isDisabled,name:l,themes:n,current:c,computedThemes:u,themeClasses:O,styles:y,global:{name:l,current:c}}}function provideTheme(t){getCurrentInstance("provideTheme");const e=inject$1(ThemeSymbol,null);if(!e)throw new Error("Could not find Vuetify theme injection");const l=computed(()=>t.theme??e.name.value),n=computed(()=>e.themes.value[l.value]),u=computed(()=>e.isDisabled?void 0:`v-theme--${l.value}`),c={...e,name:l,current:n,themeClasses:u};return provide(ThemeSymbol,c),c}function useTheme$1(){getCurrentInstance("useTheme");const t=inject$1(ThemeSymbol,null);if(!t)throw new Error("Could not find Vuetify theme injection");return t}function createCssClass(t,e,l){t.push(`${e} {
- `,...l.map(n=>` ${n};
- `),`}
- `)}function genCssVariables(t){const e=t.dark?2:1,l=t.dark?1:2,n=[];for(const[u,c]of Object.entries(t.colors)){const y=parseColor(c);n.push(`--v-theme-${u}: ${y.r},${y.g},${y.b}`),u.startsWith("on-")||n.push(`--v-theme-${u}-overlay-multiplier: ${getLuma(c)>.18?e:l}`)}for(const[u,c]of Object.entries(t.variables)){const y=typeof c=="string"&&c.startsWith("#")?parseColor(c):void 0,b=y?`${y.r}, ${y.g}, ${y.b}`:void 0;n.push(`--v-${u}: ${b??c}`)}return n}function useResizeObserver(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"content";const l=templateRef(),n=ref();if(IN_BROWSER){const u=new ResizeObserver(c=>{t?.(c,u),c.length&&(e==="content"?n.value=c[0].contentRect:n.value=c[0].target.getBoundingClientRect())});onBeforeUnmount(()=>{u.disconnect()}),watch(()=>l.el,(c,y)=>{y&&(u.unobserve(y),n.value=void 0),c&&u.observe(c)},{flush:"post"})}return{resizeRef:l,contentRect:readonly(n)}}const VuetifyLayoutKey=Symbol.for("vuetify:layout"),VuetifyLayoutItemKey=Symbol.for("vuetify:layout-item"),ROOT_ZINDEX=1e3,makeLayoutProps=propsFactory$1({overlaps:{type:Array,default:()=>[]},fullHeight:Boolean},"layout"),makeLayoutItemProps=propsFactory$1({name:{type:String},order:{type:[Number,String],default:0},absolute:Boolean},"layout-item");function useLayout(){const t=inject$1(VuetifyLayoutKey);if(!t)throw new Error("[Vuetify] Could not find injected layout");return{getLayoutItem:t.getLayoutItem,mainRect:t.mainRect,mainStyles:t.mainStyles}}function useLayoutItem(t){const e=inject$1(VuetifyLayoutKey);if(!e)throw new Error("[Vuetify] Could not find injected layout");const l=t.id??`layout-item-${getUid()}`,n=getCurrentInstance("useLayoutItem");provide(VuetifyLayoutItemKey,{id:l});const u=shallowRef(!1);onDeactivated(()=>u.value=!0),onActivated(()=>u.value=!1);const{layoutItemStyles:c,layoutItemScrimStyles:y}=e.register(n,{...t,active:computed(()=>u.value?!1:t.active.value),id:l});return onBeforeUnmount(()=>e.unregister(l)),{layoutItemStyles:c,layoutRect:e.layoutRect,layoutItemScrimStyles:y}}const generateLayers=(t,e,l,n)=>{let u={top:0,left:0,right:0,bottom:0};const c=[{id:"",layer:{...u}}];for(const y of t){const b=e.get(y),m=l.get(y),O=n.get(y);if(!b||!m||!O)continue;const N={...u,[b.value]:parseInt(u[b.value],10)+(O.value?parseInt(m.value,10):0)};c.push({id:y,layer:N}),u=N}return c};function createLayout(t){const e=inject$1(VuetifyLayoutKey,null),l=computed(()=>e?e.rootZIndex.value-100:ROOT_ZINDEX),n=ref([]),u=reactive(new Map),c=reactive(new Map),y=reactive(new Map),b=reactive(new Map),m=reactive(new Map),{resizeRef:O,contentRect:N}=useResizeObserver(),L=computed(()=>{const Ae=new Map,Te=t.overlaps??[];for(const Xe of Te.filter(ie=>ie.includes(":"))){const[ie,ue]=Xe.split(":");if(!n.value.includes(ie)||!n.value.includes(ue))continue;const pt=u.get(ie),mt=u.get(ue),Tt=c.get(ie),kt=c.get(ue);!pt||!mt||!Tt||!kt||(Ae.set(ue,{position:pt.value,amount:parseInt(Tt.value,10)}),Ae.set(ie,{position:mt.value,amount:-parseInt(kt.value,10)}))}return Ae}),G=computed(()=>{const Ae=[...new Set([...y.values()].map(Xe=>Xe.value))].sort((Xe,ie)=>Xe-ie),Te=[];for(const Xe of Ae){const ie=n.value.filter(ue=>y.get(ue)?.value===Xe);Te.push(...ie)}return generateLayers(Te,u,c,b)}),q=computed(()=>!Array.from(m.values()).some(Ae=>Ae.value)),J=computed(()=>G.value[G.value.length-1].layer),fe=computed(()=>({"--v-layout-left":convertToUnit(J.value.left),"--v-layout-right":convertToUnit(J.value.right),"--v-layout-top":convertToUnit(J.value.top),"--v-layout-bottom":convertToUnit(J.value.bottom),...q.value?void 0:{transition:"none"}})),ve=computed(()=>G.value.slice(1).map((Ae,Te)=>{let{id:Xe}=Ae;const{layer:ie}=G.value[Te],ue=c.get(Xe),pt=u.get(Xe);return{id:Xe,...ie,size:Number(ue.value),position:pt.value}})),ne=Ae=>ve.value.find(Te=>Te.id===Ae),Ue=getCurrentInstance("createLayout"),De=shallowRef(!1);onMounted(()=>{De.value=!0}),provide(VuetifyLayoutKey,{register:(Ae,Te)=>{let{id:Xe,order:ie,position:ue,layoutSize:pt,elementSize:mt,active:Tt,disableTransitions:kt,absolute:It}=Te;y.set(Xe,ie),u.set(Xe,ue),c.set(Xe,pt),b.set(Xe,Tt),kt&&m.set(Xe,kt);const tn=findChildrenWithProvide(VuetifyLayoutItemKey,Ue?.vnode).indexOf(Ae);tn>-1?n.value.splice(tn,0,Xe):n.value.push(Xe);const pn=computed(()=>ve.value.findIndex(Rn=>Rn.id===Xe)),_n=computed(()=>l.value+G.value.length*2-pn.value*2),Dn=computed(()=>{const Rn=ue.value==="left"||ue.value==="right",Lt=ue.value==="right",wn=ue.value==="bottom",hn=mt.value??pt.value,xn=hn===0?"%":"px",$n={[ue.value]:0,zIndex:_n.value,transform:`translate${Rn?"X":"Y"}(${(Tt.value?0:-(hn===0?100:hn))*(Lt||wn?-1:1)}${xn})`,position:It.value||l.value!==ROOT_ZINDEX?"absolute":"fixed",...q.value?void 0:{transition:"none"}};if(!De.value)return $n;const Xr=ve.value[pn.value];if(!Xr)throw new Error(`[Vuetify] Could not find layout item "${Xe}"`);const ti=L.value.get(Xe);return ti&&(Xr[ti.position]+=ti.amount),{...$n,height:Rn?`calc(100% - ${Xr.top}px - ${Xr.bottom}px)`:mt.value?`${mt.value}px`:void 0,left:Lt?void 0:`${Xr.left}px`,right:Lt?`${Xr.right}px`:void 0,top:ue.value!=="bottom"?`${Xr.top}px`:void 0,bottom:ue.value!=="top"?`${Xr.bottom}px`:void 0,width:Rn?mt.value?`${mt.value}px`:void 0:`calc(100% - ${Xr.left}px - ${Xr.right}px)`}}),an=computed(()=>({zIndex:_n.value-1}));return{layoutItemStyles:Dn,layoutItemScrimStyles:an,zIndex:_n}},unregister:Ae=>{y.delete(Ae),u.delete(Ae),c.delete(Ae),b.delete(Ae),m.delete(Ae),n.value=n.value.filter(Te=>Te!==Ae)},mainRect:J,mainStyles:fe,getLayoutItem:ne,items:ve,layoutRect:N,rootZIndex:l});const Ve=computed(()=>["v-layout",{"v-layout--full-height":t.fullHeight}]),rt=computed(()=>({zIndex:e?l.value:void 0,position:e?"relative":void 0,overflow:e?"hidden":void 0}));return{layoutClasses:Ve,layoutStyles:rt,getLayoutItem:ne,items:ve,layoutRect:N,layoutRef:O}}function createVuetify(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const{blueprint:e,...l}=t,n=mergeDeep(e,l),{aliases:u={},components:c={},directives:y={}}=n,b=createDefaults(n.defaults),m=createDisplay(n.display,n.ssr),O=createTheme(n.theme),N=createIcons(n.icons),L=createLocale(n.locale),G=createDate(n.date,L),q=createGoTo(n.goTo,L);return{install:fe=>{for(const ve in y)fe.directive(ve,y[ve]);for(const ve in c)fe.component(ve,c[ve]);for(const ve in u)fe.component(ve,defineComponent({...u[ve],name:ve,aliasName:u[ve].name}));if(O.install(fe),fe.provide(DefaultsSymbol,b),fe.provide(DisplaySymbol,m),fe.provide(ThemeSymbol,O),fe.provide(IconSymbol,N),fe.provide(LocaleSymbol,L),fe.provide(DateOptionsSymbol,G.options),fe.provide(DateAdapterSymbol,G.instance),fe.provide(GoToSymbol,q),IN_BROWSER&&n.ssr)if(fe.$nuxt)fe.$nuxt.hook("app:suspense:resolve",()=>{m.update()});else{const{mount:ve}=fe;fe.mount=function(){const ne=ve(...arguments);return nextTick(()=>m.update()),fe.mount=ve,ne}}getUid.reset(),fe.mixin({computed:{$vuetify(){return reactive({defaults:inject.call(this,DefaultsSymbol),display:inject.call(this,DisplaySymbol),theme:inject.call(this,ThemeSymbol),icons:inject.call(this,IconSymbol),locale:inject.call(this,LocaleSymbol),date:inject.call(this,DateAdapterSymbol)})}}})},defaults:b,display:m,theme:O,icons:N,locale:L,date:G,goTo:q}}const version="3.7.2";createVuetify.version=version;function inject(t){const e=this.$,l=e.parent?.provides??e.vnode.appContext?.provides;if(l&&t in l)return l[t]}const vuetify$1=Object.freeze(Object.defineProperty({__proto__:null,createVuetify,useDate,useDefaults,useDisplay,useGoTo,useLayout,useLocale,useRtl,useTheme:useTheme$1,version},Symbol.toStringTag,{value:"Module"}));var PointDotStyleStatus=(t=>(t.PDMODE="PDMODE",t.PDSIZE="PDSIZE",t))(PointDotStyleStatus||{});const pointDotStyleStatus=reactive({}),pointDotModeValues=[0,1,2,3,4,32,33,34,35,36,64,65,66,67,68,96,97,98,99,100],preservePointDotStyleStatus=()=>{const{PDMODE:t,PDSIZE:e}=unref(pointDotStyleStatus);typeof t<"u"&&setSysVarLog("PDMODE",Number(t)),typeof e<"u"&&setSysVarDouble("PDSIZE",Number(e))},initPointDotStyleStatus=()=>{Object.keys(PointDotStyleStatus).forEach(t=>t=="PDSIZE"?pointDotStyleStatus[t]=getSysVarDouble(t):pointDotStyleStatus[t]=getSysVarLong(t))};var SysVarLongSketchSettings=(t=>(t.GRIDMODE="栅格",t.ORTHOMODE="正交",t.AUTOSNAP="极轴",t.OSMODE="对象捕捉",t.DYNTRACE="对象追踪",t.DYNINPUT="DYN",t.LWDISPLAY="线宽",t))(SysVarLongSketchSettings||{}),SysVarLongSketchSettingsOsMode=(t=>(t[t.End=1]="End",t[t.Mid=2]="Mid",t[t.Cen=4]="Cen",t[t.Node=8]="Node",t[t.Quad=16]="Quad",t[t.Int=32]="Int",t[t.Ins=64]="Ins",t[t.Perp=128]="Perp",t[t.Tan=256]="Tan",t[t.Near=512]="Near",t[t.App=2048]="App",t[t.Ext=4096]="Ext",t[t.Par=8192]="Par",t[t.Off=16384]="Off",t))(SysVarLongSketchSettingsOsMode||{});const sysVarLongSketchSettingsKeys=Object.keys(SysVarLongSketchSettings),getSysVarLongSketchSettings=t=>{const e=getMxCadObj().getSysVarLong(t);return SysVarLongSketchSettings[t]==="对象捕捉"?(e&16384)===Status.Off?Status.On:Status.Off:SysVarLongSketchSettings[t]==="极轴"?e===8?Status.On:Status.Off:e},sysVarLongSketchSettings=reactive({}),setSysVarLongSketchSettings=(t,e)=>{let l=!1;if(SysVarLongSketchSettings[t]==="对象捕捉"){const n=getSysVarLongSketchSettingsOsMode();if(typeof n>"u")return;const u=e===Status.Off?n|16384:n&-16385;l=getMxCadObj().setSysVarLong(t,u)}else t=="AUTOSNAP"?e===Status.On?l=getMxCadObj().setSysVarLong(t,8):l=getMxCadObj().setSysVarLong(t,0):l=getMxCadObj().setSysVarLong(t,e);return l&&(sysVarLongSketchSettings[t]=e),t=="GRIDMODE"&&getMxCadObj().updateDisplay(),l},getSysVarLongSketchSettingsOsMode=t=>{try{const e=getMxCadObj().getSysVarLong("OSMODE");return typeof t>"u"?e:(e&t)===Status.Off?Status.Off:Status.On}catch{return}},setSysVarLongSketchSettingsOsMode=t=>getMxCadObj().setSysVarLong("OSMODE",t),countSysVarLongSketchSettingsOsMode=(t,e,l=getSysVarLongSketchSettingsOsMode())=>{if(!(typeof l>"u"))return l=e?l|t:l&~t};function osModeRef(t){return customRef((e,l)=>{let n;return{get(){e();const u=getSysVarLongSketchSettingsOsMode(t);return typeof u===void 0||typeof n>"u"&&(n=u!==Status.Off),n},set(u){n=u,l()}}})}const initSysVarLongSketchSettings=()=>{sysVarLongSketchSettingsKeys.forEach(t=>{sysVarLongSketchSettings[t]=getSysVarLongSketchSettings(t)})};({...SysVarLongSketchSettings,...PointDotStyleStatus});const setSysVarLog=(t,e)=>{getMxCadObj().setSysVarLong(t,e)},getSysVarLong=t=>getMxCadObj().getSysVarLong(t),setSysVarDouble=(t,e)=>{getMxCadObj().setSysVarDouble(t,e)},getSysVarDouble=t=>getMxCadObj().getSysVarDouble(t),initSysVarLong=()=>{initSysVarLongSketchSettings(),initPointDotStyleStatus()};function fileToBlob(t){let e=new FileReader;return new Promise(l=>{e.addEventListener("load",n=>{let u;if(n.target){if(typeof n.target.result=="object"){if(!n.target.result)return;u=new Blob([n.target.result])}else u=n.target.result;l(u)}}),e.readAsArrayBuffer(t)})}const readPatFileText=t=>new Promise(e=>{let l=new FileReader;l.onload=()=>{const n=l.result;e(n)},l.readAsText(t,"GBK")}),getFileSize=t=>new Promise(async e=>{if(t.startsWith("blob:"))return e(-1);fetch(t,{method:"HEAD"}).then(l=>{const n=Number(l.headers.get("content-length"));if(n===null)return e(Number.MAX_VALUE);e(n)}).catch(()=>e(Number.MAX_VALUE))});ref([]);ref("");ref();ref([]);ref();let onOpenFileCompleteCalls=[],isOpenFileComplete=!1;const onOpenFileComplete=t=>{if(onOpenFileCompleteCalls.push(t),isOpenFileComplete)return t(MxCpp.getCurrentMxCAD())};let isLoadComplete=!1,onLoadCompleteCalls=[];const onLoadComplete=t=>{if(isLoadComplete)return t(MxCpp.getCurrentMxCAD());onLoadCompleteCalls.push(t)},{showLoading:showLoading$1,hideLoading:hideLoading$1}=useLoading();window.onerror=()=>{hideLoading$1()};const useMxCad=(t,e)=>{const{mainRect:l}=useLayout(),{initLayerList:n}=useLayer(),{initColorIndexList:u}=useColor$1(),{initLineTypeList:c}=useLineType();return onMounted(async()=>{let y=MxCheckTheBrowser();y.ok||(console.log(y),alert("CAD梦想在线画图提示:"+y.error));const b=(m,O)=>{m.on("loadComplete",()=>{if(isLoadComplete=!0,onLoadCompleteCalls.forEach(async G=>{G&&await G(MxCpp.getCurrentMxCAD())}),O)return;const{file:N,viewRange:L}=getParamsFromUrl()||{};requestIdleCallback(()=>{let G="test3.mxweb",q=MxFun.callEvent("mxcadApplicationDefaultOpen");q&&q.openFile!==void 0&&(G=q.openFile,G.length==0&&(G="empty_template.mxweb"));const J=mxcadObj.openWebFile(N||G,fe=>{if(hideLoading$1(),fe!==0){console.log("openWebFile error",fe),useMessage().error("打开文件失败!");return}},!0,L?JSON.parse(L):void 0,0);getFileSize(N||G).then(fe=>{fe/(1024*1024)>1&&J&&showLoading$1()})})}),m.on("databaseModify",()=>{}),m.on("openFileComplete",async()=>{hideLoading$1(),n(),u(),c(),initSysVarLong(),onOpenFileCompleteCalls.forEach(N=>{N&&N(mxcadObj)}),isOpenFileComplete=!0})};e?createMxCADMap((m,O)=>{b(m,O)}):createMxCAD({canvasId:t,isCPPMxCAD:!0},(m,O)=>{b(m,O)})}),{mainRect:l}},fileName=ref("");let _name="";const setFileName=t=>{_name=" - "+t};onOpenFileComplete(()=>{fileName.value=_name});const useFileName=()=>({fileName,setFileName});var jquery={exports:{}};/*!
- * jQuery JavaScript Library v3.7.1
- * https://jquery.com/
- *
- * Copyright OpenJS Foundation and other contributors
- * Released under the MIT license
- * https://jquery.org/license
- *
- * Date: 2023-08-28T13:37Z
- */(function(t){(function(e,l){t.exports=e.document?l(e,!0):function(n){if(!n.document)throw new Error("jQuery requires a window with a document");return l(n)}})(typeof window<"u"?window:commonjsGlobal$1,function(e,l){var n=[],u=Object.getPrototypeOf,c=n.slice,y=n.flat?function(Qe){return n.flat.call(Qe)}:function(Qe){return n.concat.apply([],Qe)},b=n.push,m=n.indexOf,O={},N=O.toString,L=O.hasOwnProperty,G=L.toString,q=G.call(Object),J={},fe=function(yt){return typeof yt=="function"&&typeof yt.nodeType!="number"&&typeof yt.item!="function"},ve=function(yt){return yt!=null&&yt===yt.window},ne=e.document,Ue={type:!0,src:!0,nonce:!0,noModule:!0};function De(Qe,yt,Rt){Rt=Rt||ne;var jt,dn,yn=Rt.createElement("script");if(yn.text=Qe,yt)for(jt in Ue)dn=yt[jt]||yt.getAttribute&&yt.getAttribute(jt),dn&&yn.setAttribute(jt,dn);Rt.head.appendChild(yn).parentNode.removeChild(yn)}function Ve(Qe){return Qe==null?Qe+"":typeof Qe=="object"||typeof Qe=="function"?O[N.call(Qe)]||"object":typeof Qe}var rt="3.7.1",Ae=/HTML$/i,Te=function(Qe,yt){return new Te.fn.init(Qe,yt)};Te.fn=Te.prototype={jquery:rt,constructor:Te,length:0,toArray:function(){return c.call(this)},get:function(Qe){return Qe==null?c.call(this):Qe<0?this[Qe+this.length]:this[Qe]},pushStack:function(Qe){var yt=Te.merge(this.constructor(),Qe);return yt.prevObject=this,yt},each:function(Qe){return Te.each(this,Qe)},map:function(Qe){return this.pushStack(Te.map(this,function(yt,Rt){return Qe.call(yt,Rt,yt)}))},slice:function(){return this.pushStack(c.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(Te.grep(this,function(Qe,yt){return(yt+1)%2}))},odd:function(){return this.pushStack(Te.grep(this,function(Qe,yt){return yt%2}))},eq:function(Qe){var yt=this.length,Rt=+Qe+(Qe<0?yt:0);return this.pushStack(Rt>=0&&Rt<yt?[this[Rt]]:[])},end:function(){return this.prevObject||this.constructor()},push:b,sort:n.sort,splice:n.splice},Te.extend=Te.fn.extend=function(){var Qe,yt,Rt,jt,dn,yn,In=arguments[0]||{},vr=1,Jn=arguments.length,li=!1;for(typeof In=="boolean"&&(li=In,In=arguments[vr]||{},vr++),typeof In!="object"&&!fe(In)&&(In={}),vr===Jn&&(In=this,vr--);vr<Jn;vr++)if((Qe=arguments[vr])!=null)for(yt in Qe)jt=Qe[yt],!(yt==="__proto__"||In===jt)&&(li&&jt&&(Te.isPlainObject(jt)||(dn=Array.isArray(jt)))?(Rt=In[yt],dn&&!Array.isArray(Rt)?yn=[]:!dn&&!Te.isPlainObject(Rt)?yn={}:yn=Rt,dn=!1,In[yt]=Te.extend(li,yn,jt)):jt!==void 0&&(In[yt]=jt));return In},Te.extend({expando:"jQuery"+(rt+Math.random()).replace(/\D/g,""),isReady:!0,error:function(Qe){throw new Error(Qe)},noop:function(){},isPlainObject:function(Qe){var yt,Rt;return!Qe||N.call(Qe)!=="[object Object]"?!1:(yt=u(Qe),yt?(Rt=L.call(yt,"constructor")&&yt.constructor,typeof Rt=="function"&&G.call(Rt)===q):!0)},isEmptyObject:function(Qe){var yt;for(yt in Qe)return!1;return!0},globalEval:function(Qe,yt,Rt){De(Qe,{nonce:yt&&yt.nonce},Rt)},each:function(Qe,yt){var Rt,jt=0;if(Xe(Qe))for(Rt=Qe.length;jt<Rt&&yt.call(Qe[jt],jt,Qe[jt])!==!1;jt++);else for(jt in Qe)if(yt.call(Qe[jt],jt,Qe[jt])===!1)break;return Qe},text:function(Qe){var yt,Rt="",jt=0,dn=Qe.nodeType;if(!dn)for(;yt=Qe[jt++];)Rt+=Te.text(yt);return dn===1||dn===11?Qe.textContent:dn===9?Qe.documentElement.textContent:dn===3||dn===4?Qe.nodeValue:Rt},makeArray:function(Qe,yt){var Rt=yt||[];return Qe!=null&&(Xe(Object(Qe))?Te.merge(Rt,typeof Qe=="string"?[Qe]:Qe):b.call(Rt,Qe)),Rt},inArray:function(Qe,yt,Rt){return yt==null?-1:m.call(yt,Qe,Rt)},isXMLDoc:function(Qe){var yt=Qe&&Qe.namespaceURI,Rt=Qe&&(Qe.ownerDocument||Qe).documentElement;return!Ae.test(yt||Rt&&Rt.nodeName||"HTML")},merge:function(Qe,yt){for(var Rt=+yt.length,jt=0,dn=Qe.length;jt<Rt;jt++)Qe[dn++]=yt[jt];return Qe.length=dn,Qe},grep:function(Qe,yt,Rt){for(var jt,dn=[],yn=0,In=Qe.length,vr=!Rt;yn<In;yn++)jt=!yt(Qe[yn],yn),jt!==vr&&dn.push(Qe[yn]);return dn},map:function(Qe,yt,Rt){var jt,dn,yn=0,In=[];if(Xe(Qe))for(jt=Qe.length;yn<jt;yn++)dn=yt(Qe[yn],yn,Rt),dn!=null&&In.push(dn);else for(yn in Qe)dn=yt(Qe[yn],yn,Rt),dn!=null&&In.push(dn);return y(In)},guid:1,support:J}),typeof Symbol=="function"&&(Te.fn[Symbol.iterator]=n[Symbol.iterator]),Te.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(Qe,yt){O["[object "+yt+"]"]=yt.toLowerCase()});function Xe(Qe){var yt=!!Qe&&"length"in Qe&&Qe.length,Rt=Ve(Qe);return fe(Qe)||ve(Qe)?!1:Rt==="array"||yt===0||typeof yt=="number"&&yt>0&&yt-1 in Qe}function ie(Qe,yt){return Qe.nodeName&&Qe.nodeName.toLowerCase()===yt.toLowerCase()}var ue=n.pop,pt=n.sort,mt=n.splice,Tt="[\\x20\\t\\r\\n\\f]",kt=new RegExp("^"+Tt+"+|((?:^|[^\\\\])(?:\\\\.)*)"+Tt+"+$","g");Te.contains=function(Qe,yt){var Rt=yt&&yt.parentNode;return Qe===Rt||!!(Rt&&Rt.nodeType===1&&(Qe.contains?Qe.contains(Rt):Qe.compareDocumentPosition&&Qe.compareDocumentPosition(Rt)&16))};var It=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\x80-\uFFFF\w-]/g;function nn(Qe,yt){return yt?Qe==="\0"?"�":Qe.slice(0,-1)+"\\"+Qe.charCodeAt(Qe.length-1).toString(16)+" ":"\\"+Qe}Te.escapeSelector=function(Qe){return(Qe+"").replace(It,nn)};var tn=ne,pn=b;(function(){var Qe,yt,Rt,jt,dn,yn=pn,In,vr,Jn,li,xa,Ri=Te.expando,fa=0,oo=0,ts=cd(),bl=cd(),nl=cd(),Fs=cd(),eu=function(ei,ii){return ei===ii&&(dn=!0),0},Gs="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",As="(?:\\\\[\\da-fA-F]{1,6}"+Tt+"?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+",yl="\\["+Tt+"*("+As+")(?:"+Tt+"*([*^$|!~]?=)"+Tt+`*(?:'((?:\\\\.|[^\\\\'])*)'|"((?:\\\\.|[^\\\\"])*)"|(`+As+"))|)"+Tt+"*\\]",Lc=":("+As+`)(?:\\((('((?:\\\\.|[^\\\\'])*)'|"((?:\\\\.|[^\\\\"])*)")|((?:\\\\.|[^\\\\()[\\]]|`+yl+")*)|.*)\\)|)",vl=new RegExp(Tt+"+","g"),du=new RegExp("^"+Tt+"*,"+Tt+"*"),ac=new RegExp("^"+Tt+"*([>+~]|"+Tt+")"+Tt+"*"),Xu=new RegExp(Tt+"|>"),Ju=new RegExp(Lc),Vu=new RegExp("^"+As+"$"),Nl={ID:new RegExp("^#("+As+")"),CLASS:new RegExp("^\\.("+As+")"),TAG:new RegExp("^("+As+"|[*])"),ATTR:new RegExp("^"+yl),PSEUDO:new RegExp("^"+Lc),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+Tt+"*(even|odd|(([+-]|)(\\d*)n|)"+Tt+"*(?:([+-]|)"+Tt+"*(\\d+)|))"+Tt+"*\\)|)","i"),bool:new RegExp("^(?:"+Gs+")$","i"),needsContext:new RegExp("^"+Tt+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+Tt+"*((?:-\\d)?\\d*)"+Tt+"*\\)|)(?=[^-]|$)","i")},$l=/^(?:input|select|textarea|button)$/i,hu=/^h\d$/i,Qu=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,Gu=/[+~]/,Bs=new RegExp("\\\\[\\da-fA-F]{1,6}"+Tt+"?|\\\\([^\\r\\n\\f])","g"),su=function(ei,ii){var Ma="0x"+ei.slice(1)-65536;return ii||(Ma<0?String.fromCharCode(Ma+65536):String.fromCharCode(Ma>>10|55296,Ma&1023|56320))},ku=function(){vd()},Hl=qu(function(ei){return ei.disabled===!0&&ie(ei,"fieldset")},{dir:"parentNode",next:"legend"});function Uc(){try{return In.activeElement}catch{}}try{yn.apply(n=c.call(tn.childNodes),tn.childNodes),n[tn.childNodes.length].nodeType}catch{yn={apply:function(ii,Ma){pn.apply(ii,c.call(Ma))},call:function(ii){pn.apply(ii,c.call(arguments,1))}}}function Wl(ei,ii,Ma,pa){var ca,uo,ya,Oo,Io,Ws,gr,ws=ii&&ii.ownerDocument,io=ii?ii.nodeType:9;if(Ma=Ma||[],typeof ei!="string"||!ei||io!==1&&io!==9&&io!==11)return Ma;if(!pa&&(vd(ii),ii=ii||In,Jn)){if(io!==11&&(Io=Qu.exec(ei)))if(ca=Io[1]){if(io===9)if(ya=ii.getElementById(ca)){if(ya.id===ca)return yn.call(Ma,ya),Ma}else return Ma;else if(ws&&(ya=ws.getElementById(ca))&&Wl.contains(ii,ya)&&ya.id===ca)return yn.call(Ma,ya),Ma}else{if(Io[2])return yn.apply(Ma,ii.getElementsByTagName(ei)),Ma;if((ca=Io[3])&&ii.getElementsByClassName)return yn.apply(Ma,ii.getElementsByClassName(ca)),Ma}if(!Fs[ei+" "]&&(!li||!li.test(ei))){if(gr=ei,ws=ii,io===1&&(Xu.test(ei)||ac.test(ei))){for(ws=Gu.test(ei)&&qc(ii.parentNode)||ii,(ws!=ii||!J.scope)&&((Oo=ii.getAttribute("id"))?Oo=Te.escapeSelector(Oo):ii.setAttribute("id",Oo=Ri)),Ws=ol(ei),uo=Ws.length;uo--;)Ws[uo]=(Oo?"#"+Oo:":scope")+" "+od(Ws[uo]);gr=Ws.join(",")}try{return yn.apply(Ma,ws.querySelectorAll(gr)),Ma}catch{Fs(ei,!0)}finally{Oo===Ri&&ii.removeAttribute("id")}}}return Xo(ei.replace(kt,"$1"),ii,Ma,pa)}function cd(){var ei=[];function ii(Ma,pa){return ei.push(Ma+" ")>yt.cacheLength&&delete ii[ei.shift()],ii[Ma+" "]=pa}return ii}function wu(ei){return ei[Ri]=!0,ei}function oc(ei){var ii=In.createElement("fieldset");try{return!!ei(ii)}catch{return!1}finally{ii.parentNode&&ii.parentNode.removeChild(ii),ii=null}}function gc(ei){return function(ii){return ie(ii,"input")&&ii.type===ei}}function dd(ei){return function(ii){return(ie(ii,"input")||ie(ii,"button"))&&ii.type===ei}}function Jc(ei){return function(ii){return"form"in ii?ii.parentNode&&ii.disabled===!1?"label"in ii?"label"in ii.parentNode?ii.parentNode.disabled===ei:ii.disabled===ei:ii.isDisabled===ei||ii.isDisabled!==!ei&&Hl(ii)===ei:ii.disabled===ei:"label"in ii?ii.disabled===ei:!1}}function sc(ei){return wu(function(ii){return ii=+ii,wu(function(Ma,pa){for(var ca,uo=ei([],Ma.length,ii),ya=uo.length;ya--;)Ma[ca=uo[ya]]&&(Ma[ca]=!(pa[ca]=Ma[ca]))})})}function qc(ei){return ei&&typeof ei.getElementsByTagName<"u"&&ei}function vd(ei){var ii,Ma=ei?ei.ownerDocument||ei:tn;return Ma==In||Ma.nodeType!==9||!Ma.documentElement||(In=Ma,vr=In.documentElement,Jn=!Te.isXMLDoc(In),xa=vr.matches||vr.webkitMatchesSelector||vr.msMatchesSelector,vr.msMatchesSelector&&tn!=In&&(ii=In.defaultView)&&ii.top!==ii&&ii.addEventListener("unload",ku),J.getById=oc(function(pa){return vr.appendChild(pa).id=Te.expando,!In.getElementsByName||!In.getElementsByName(Te.expando).length}),J.disconnectedMatch=oc(function(pa){return xa.call(pa,"*")}),J.scope=oc(function(){return In.querySelectorAll(":scope")}),J.cssHas=oc(function(){try{return In.querySelector(":has(*,:jqfake)"),!1}catch{return!0}}),J.getById?(yt.filter.ID=function(pa){var ca=pa.replace(Bs,su);return function(uo){return uo.getAttribute("id")===ca}},yt.find.ID=function(pa,ca){if(typeof ca.getElementById<"u"&&Jn){var uo=ca.getElementById(pa);return uo?[uo]:[]}}):(yt.filter.ID=function(pa){var ca=pa.replace(Bs,su);return function(uo){var ya=typeof uo.getAttributeNode<"u"&&uo.getAttributeNode("id");return ya&&ya.value===ca}},yt.find.ID=function(pa,ca){if(typeof ca.getElementById<"u"&&Jn){var uo,ya,Oo,Io=ca.getElementById(pa);if(Io){if(uo=Io.getAttributeNode("id"),uo&&uo.value===pa)return[Io];for(Oo=ca.getElementsByName(pa),ya=0;Io=Oo[ya++];)if(uo=Io.getAttributeNode("id"),uo&&uo.value===pa)return[Io]}return[]}}),yt.find.TAG=function(pa,ca){return typeof ca.getElementsByTagName<"u"?ca.getElementsByTagName(pa):ca.querySelectorAll(pa)},yt.find.CLASS=function(pa,ca){if(typeof ca.getElementsByClassName<"u"&&Jn)return ca.getElementsByClassName(pa)},li=[],oc(function(pa){var ca;vr.appendChild(pa).innerHTML="<a id='"+Ri+"' href='' disabled='disabled'></a><select id='"+Ri+"-\r\\' disabled='disabled'><option selected=''></option></select>",pa.querySelectorAll("[selected]").length||li.push("\\["+Tt+"*(?:value|"+Gs+")"),pa.querySelectorAll("[id~="+Ri+"-]").length||li.push("~="),pa.querySelectorAll("a#"+Ri+"+*").length||li.push(".#.+[+~]"),pa.querySelectorAll(":checked").length||li.push(":checked"),ca=In.createElement("input"),ca.setAttribute("type","hidden"),pa.appendChild(ca).setAttribute("name","D"),vr.appendChild(pa).disabled=!0,pa.querySelectorAll(":disabled").length!==2&&li.push(":enabled",":disabled"),ca=In.createElement("input"),ca.setAttribute("name",""),pa.appendChild(ca),pa.querySelectorAll("[name='']").length||li.push("\\["+Tt+"*name"+Tt+"*="+Tt+`*(?:''|"")`)}),J.cssHas||li.push(":has"),li=li.length&&new RegExp(li.join("|")),eu=function(pa,ca){if(pa===ca)return dn=!0,0;var uo=!pa.compareDocumentPosition-!ca.compareDocumentPosition;return uo||(uo=(pa.ownerDocument||pa)==(ca.ownerDocument||ca)?pa.compareDocumentPosition(ca):1,uo&1||!J.sortDetached&&ca.compareDocumentPosition(pa)===uo?pa===In||pa.ownerDocument==tn&&Wl.contains(tn,pa)?-1:ca===In||ca.ownerDocument==tn&&Wl.contains(tn,ca)?1:jt?m.call(jt,pa)-m.call(jt,ca):0:uo&4?-1:1)}),In}Wl.matches=function(ei,ii){return Wl(ei,null,null,ii)},Wl.matchesSelector=function(ei,ii){if(vd(ei),Jn&&!Fs[ii+" "]&&(!li||!li.test(ii)))try{var Ma=xa.call(ei,ii);if(Ma||J.disconnectedMatch||ei.document&&ei.document.nodeType!==11)return Ma}catch{Fs(ii,!0)}return Wl(ii,In,null,[ei]).length>0},Wl.contains=function(ei,ii){return(ei.ownerDocument||ei)!=In&&vd(ei),Te.contains(ei,ii)},Wl.attr=function(ei,ii){(ei.ownerDocument||ei)!=In&&vd(ei);var Ma=yt.attrHandle[ii.toLowerCase()],pa=Ma&&L.call(yt.attrHandle,ii.toLowerCase())?Ma(ei,ii,!Jn):void 0;return pa!==void 0?pa:ei.getAttribute(ii)},Wl.error=function(ei){throw new Error("Syntax error, unrecognized expression: "+ei)},Te.uniqueSort=function(ei){var ii,Ma=[],pa=0,ca=0;if(dn=!J.sortStable,jt=!J.sortStable&&c.call(ei,0),pt.call(ei,eu),dn){for(;ii=ei[ca++];)ii===ei[ca]&&(pa=Ma.push(ca));for(;pa--;)mt.call(ei,Ma[pa],1)}return jt=null,ei},Te.fn.uniqueSort=function(){return this.pushStack(Te.uniqueSort(c.apply(this)))},yt=Te.expr={cacheLength:50,createPseudo:wu,match:Nl,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(ei){return ei[1]=ei[1].replace(Bs,su),ei[3]=(ei[3]||ei[4]||ei[5]||"").replace(Bs,su),ei[2]==="~="&&(ei[3]=" "+ei[3]+" "),ei.slice(0,4)},CHILD:function(ei){return ei[1]=ei[1].toLowerCase(),ei[1].slice(0,3)==="nth"?(ei[3]||Wl.error(ei[0]),ei[4]=+(ei[4]?ei[5]+(ei[6]||1):2*(ei[3]==="even"||ei[3]==="odd")),ei[5]=+(ei[7]+ei[8]||ei[3]==="odd")):ei[3]&&Wl.error(ei[0]),ei},PSEUDO:function(ei){var ii,Ma=!ei[6]&&ei[2];return Nl.CHILD.test(ei[0])?null:(ei[3]?ei[2]=ei[4]||ei[5]||"":Ma&&Ju.test(Ma)&&(ii=ol(Ma,!0))&&(ii=Ma.indexOf(")",Ma.length-ii)-Ma.length)&&(ei[0]=ei[0].slice(0,ii),ei[2]=Ma.slice(0,ii)),ei.slice(0,3))}},filter:{TAG:function(ei){var ii=ei.replace(Bs,su).toLowerCase();return ei==="*"?function(){return!0}:function(Ma){return ie(Ma,ii)}},CLASS:function(ei){var ii=ts[ei+" "];return ii||(ii=new RegExp("(^|"+Tt+")"+ei+"("+Tt+"|$)"))&&ts(ei,function(Ma){return ii.test(typeof Ma.className=="string"&&Ma.className||typeof Ma.getAttribute<"u"&&Ma.getAttribute("class")||"")})},ATTR:function(ei,ii,Ma){return function(pa){var ca=Wl.attr(pa,ei);return ca==null?ii==="!=":ii?(ca+="",ii==="="?ca===Ma:ii==="!="?ca!==Ma:ii==="^="?Ma&&ca.indexOf(Ma)===0:ii==="*="?Ma&&ca.indexOf(Ma)>-1:ii==="$="?Ma&&ca.slice(-Ma.length)===Ma:ii==="~="?(" "+ca.replace(vl," ")+" ").indexOf(Ma)>-1:ii==="|="?ca===Ma||ca.slice(0,Ma.length+1)===Ma+"-":!1):!0}},CHILD:function(ei,ii,Ma,pa,ca){var uo=ei.slice(0,3)!=="nth",ya=ei.slice(-4)!=="last",Oo=ii==="of-type";return pa===1&&ca===0?function(Io){return!!Io.parentNode}:function(Io,Ws,gr){var ws,io,Fo,vs,Gl,Mu=uo!==ya?"nextSibling":"previousSibling",gu=Io.parentNode,Nu=Oo&&Io.nodeName.toLowerCase(),lc=!gr&&!Oo,Du=!1;if(gu){if(uo){for(;Mu;){for(Fo=Io;Fo=Fo[Mu];)if(Oo?ie(Fo,Nu):Fo.nodeType===1)return!1;Gl=Mu=ei==="only"&&!Gl&&"nextSibling"}return!0}if(Gl=[ya?gu.firstChild:gu.lastChild],ya&&lc){for(io=gu[Ri]||(gu[Ri]={}),ws=io[ei]||[],vs=ws[0]===fa&&ws[1],Du=vs&&ws[2],Fo=vs&&gu.childNodes[vs];Fo=++vs&&Fo&&Fo[Mu]||(Du=vs=0)||Gl.pop();)if(Fo.nodeType===1&&++Du&&Fo===Io){io[ei]=[fa,vs,Du];break}}else if(lc&&(io=Io[Ri]||(Io[Ri]={}),ws=io[ei]||[],vs=ws[0]===fa&&ws[1],Du=vs),Du===!1)for(;(Fo=++vs&&Fo&&Fo[Mu]||(Du=vs=0)||Gl.pop())&&!((Oo?ie(Fo,Nu):Fo.nodeType===1)&&++Du&&(lc&&(io=Fo[Ri]||(Fo[Ri]={}),io[ei]=[fa,Du]),Fo===Io)););return Du-=ca,Du===pa||Du%pa===0&&Du/pa>=0}}},PSEUDO:function(ei,ii){var Ma,pa=yt.pseudos[ei]||yt.setFilters[ei.toLowerCase()]||Wl.error("unsupported pseudo: "+ei);return pa[Ri]?pa(ii):pa.length>1?(Ma=[ei,ei,"",ii],yt.setFilters.hasOwnProperty(ei.toLowerCase())?wu(function(ca,uo){for(var ya,Oo=pa(ca,ii),Io=Oo.length;Io--;)ya=m.call(ca,Oo[Io]),ca[ya]=!(uo[ya]=Oo[Io])}):function(ca){return pa(ca,0,Ma)}):pa}},pseudos:{not:wu(function(ei){var ii=[],Ma=[],pa=Jo(ei.replace(kt,"$1"));return pa[Ri]?wu(function(ca,uo,ya,Oo){for(var Io,Ws=pa(ca,null,Oo,[]),gr=ca.length;gr--;)(Io=Ws[gr])&&(ca[gr]=!(uo[gr]=Io))}):function(ca,uo,ya){return ii[0]=ca,pa(ii,null,ya,Ma),ii[0]=null,!Ma.pop()}}),has:wu(function(ei){return function(ii){return Wl(ei,ii).length>0}}),contains:wu(function(ei){return ei=ei.replace(Bs,su),function(ii){return(ii.textContent||Te.text(ii)).indexOf(ei)>-1}}),lang:wu(function(ei){return Vu.test(ei||"")||Wl.error("unsupported lang: "+ei),ei=ei.replace(Bs,su).toLowerCase(),function(ii){var Ma;do if(Ma=Jn?ii.lang:ii.getAttribute("xml:lang")||ii.getAttribute("lang"))return Ma=Ma.toLowerCase(),Ma===ei||Ma.indexOf(ei+"-")===0;while((ii=ii.parentNode)&&ii.nodeType===1);return!1}}),target:function(ei){var ii=e.location&&e.location.hash;return ii&&ii.slice(1)===ei.id},root:function(ei){return ei===vr},focus:function(ei){return ei===Uc()&&In.hasFocus()&&!!(ei.type||ei.href||~ei.tabIndex)},enabled:Jc(!1),disabled:Jc(!0),checked:function(ei){return ie(ei,"input")&&!!ei.checked||ie(ei,"option")&&!!ei.selected},selected:function(ei){return ei.parentNode&&ei.parentNode.selectedIndex,ei.selected===!0},empty:function(ei){for(ei=ei.firstChild;ei;ei=ei.nextSibling)if(ei.nodeType<6)return!1;return!0},parent:function(ei){return!yt.pseudos.empty(ei)},header:function(ei){return hu.test(ei.nodeName)},input:function(ei){return $l.test(ei.nodeName)},button:function(ei){return ie(ei,"input")&&ei.type==="button"||ie(ei,"button")},text:function(ei){var ii;return ie(ei,"input")&&ei.type==="text"&&((ii=ei.getAttribute("type"))==null||ii.toLowerCase()==="text")},first:sc(function(){return[0]}),last:sc(function(ei,ii){return[ii-1]}),eq:sc(function(ei,ii,Ma){return[Ma<0?Ma+ii:Ma]}),even:sc(function(ei,ii){for(var Ma=0;Ma<ii;Ma+=2)ei.push(Ma);return ei}),odd:sc(function(ei,ii){for(var Ma=1;Ma<ii;Ma+=2)ei.push(Ma);return ei}),lt:sc(function(ei,ii,Ma){var pa;for(Ma<0?pa=Ma+ii:Ma>ii?pa=ii:pa=Ma;--pa>=0;)ei.push(pa);return ei}),gt:sc(function(ei,ii,Ma){for(var pa=Ma<0?Ma+ii:Ma;++pa<ii;)ei.push(pa);return ei})}},yt.pseudos.nth=yt.pseudos.eq;for(Qe in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})yt.pseudos[Qe]=gc(Qe);for(Qe in{submit:!0,reset:!0})yt.pseudos[Qe]=dd(Qe);function Pu(){}Pu.prototype=yt.filters=yt.pseudos,yt.setFilters=new Pu;function ol(ei,ii){var Ma,pa,ca,uo,ya,Oo,Io,Ws=bl[ei+" "];if(Ws)return ii?0:Ws.slice(0);for(ya=ei,Oo=[],Io=yt.preFilter;ya;){(!Ma||(pa=du.exec(ya)))&&(pa&&(ya=ya.slice(pa[0].length)||ya),Oo.push(ca=[])),Ma=!1,(pa=ac.exec(ya))&&(Ma=pa.shift(),ca.push({value:Ma,type:pa[0].replace(kt," ")}),ya=ya.slice(Ma.length));for(uo in yt.filter)(pa=Nl[uo].exec(ya))&&(!Io[uo]||(pa=Io[uo](pa)))&&(Ma=pa.shift(),ca.push({value:Ma,type:uo,matches:pa}),ya=ya.slice(Ma.length));if(!Ma)break}return ii?ya.length:ya?Wl.error(ei):bl(ei,Oo).slice(0)}function od(ei){for(var ii=0,Ma=ei.length,pa="";ii<Ma;ii++)pa+=ei[ii].value;return pa}function qu(ei,ii,Ma){var pa=ii.dir,ca=ii.next,uo=ca||pa,ya=Ma&&uo==="parentNode",Oo=oo++;return ii.first?function(Io,Ws,gr){for(;Io=Io[pa];)if(Io.nodeType===1||ya)return ei(Io,Ws,gr);return!1}:function(Io,Ws,gr){var ws,io,Fo=[fa,Oo];if(gr){for(;Io=Io[pa];)if((Io.nodeType===1||ya)&&ei(Io,Ws,gr))return!0}else for(;Io=Io[pa];)if(Io.nodeType===1||ya)if(io=Io[Ri]||(Io[Ri]={}),ca&&ie(Io,ca))Io=Io[pa]||Io;else{if((ws=io[uo])&&ws[0]===fa&&ws[1]===Oo)return Fo[2]=ws[2];if(io[uo]=Fo,Fo[2]=ei(Io,Ws,gr))return!0}return!1}}function ah(ei){return ei.length>1?function(ii,Ma,pa){for(var ca=ei.length;ca--;)if(!ei[ca](ii,Ma,pa))return!1;return!0}:ei[0]}function Mi(ei,ii,Ma){for(var pa=0,ca=ii.length;pa<ca;pa++)Wl(ei,ii[pa],Ma);return Ma}function wa(ei,ii,Ma,pa,ca){for(var uo,ya=[],Oo=0,Io=ei.length,Ws=ii!=null;Oo<Io;Oo++)(uo=ei[Oo])&&(!Ma||Ma(uo,pa,ca))&&(ya.push(uo),Ws&&ii.push(Oo));return ya}function la(ei,ii,Ma,pa,ca,uo){return pa&&!pa[Ri]&&(pa=la(pa)),ca&&!ca[Ri]&&(ca=la(ca,uo)),wu(function(ya,Oo,Io,Ws){var gr,ws,io,Fo,vs=[],Gl=[],Mu=Oo.length,gu=ya||Mi(ii||"*",Io.nodeType?[Io]:Io,[]),Nu=ei&&(ya||!ii)?wa(gu,vs,ei,Io,Ws):gu;if(Ma?(Fo=ca||(ya?ei:Mu||pa)?[]:Oo,Ma(Nu,Fo,Io,Ws)):Fo=Nu,pa)for(gr=wa(Fo,Gl),pa(gr,[],Io,Ws),ws=gr.length;ws--;)(io=gr[ws])&&(Fo[Gl[ws]]=!(Nu[Gl[ws]]=io));if(ya){if(ca||ei){if(ca){for(gr=[],ws=Fo.length;ws--;)(io=Fo[ws])&&gr.push(Nu[ws]=io);ca(null,Fo=[],gr,Ws)}for(ws=Fo.length;ws--;)(io=Fo[ws])&&(gr=ca?m.call(ya,io):vs[ws])>-1&&(ya[gr]=!(Oo[gr]=io))}}else Fo=wa(Fo===Oo?Fo.splice(Mu,Fo.length):Fo),ca?ca(null,Oo,Fo,Ws):yn.apply(Oo,Fo)})}function Wa(ei){for(var ii,Ma,pa,ca=ei.length,uo=yt.relative[ei[0].type],ya=uo||yt.relative[" "],Oo=uo?1:0,Io=qu(function(ws){return ws===ii},ya,!0),Ws=qu(function(ws){return m.call(ii,ws)>-1},ya,!0),gr=[function(ws,io,Fo){var vs=!uo&&(Fo||io!=Rt)||((ii=io).nodeType?Io(ws,io,Fo):Ws(ws,io,Fo));return ii=null,vs}];Oo<ca;Oo++)if(Ma=yt.relative[ei[Oo].type])gr=[qu(ah(gr),Ma)];else{if(Ma=yt.filter[ei[Oo].type].apply(null,ei[Oo].matches),Ma[Ri]){for(pa=++Oo;pa<ca&&!yt.relative[ei[pa].type];pa++);return la(Oo>1&&ah(gr),Oo>1&&od(ei.slice(0,Oo-1).concat({value:ei[Oo-2].type===" "?"*":""})).replace(kt,"$1"),Ma,Oo<pa&&Wa(ei.slice(Oo,pa)),pa<ca&&Wa(ei=ei.slice(pa)),pa<ca&&od(ei))}gr.push(Ma)}return ah(gr)}function lo(ei,ii){var Ma=ii.length>0,pa=ei.length>0,ca=function(uo,ya,Oo,Io,Ws){var gr,ws,io,Fo=0,vs="0",Gl=uo&&[],Mu=[],gu=Rt,Nu=uo||pa&&yt.find.TAG("*",Ws),lc=fa+=gu==null?1:Math.random()||.1,Du=Nu.length;for(Ws&&(Rt=ya==In||ya||Ws);vs!==Du&&(gr=Nu[vs])!=null;vs++){if(pa&&gr){for(ws=0,!ya&&gr.ownerDocument!=In&&(vd(gr),Oo=!Jn);io=ei[ws++];)if(io(gr,ya||In,Oo)){yn.call(Io,gr);break}Ws&&(fa=lc)}Ma&&((gr=!io&&gr)&&Fo--,uo&&Gl.push(gr))}if(Fo+=vs,Ma&&vs!==Fo){for(ws=0;io=ii[ws++];)io(Gl,Mu,ya,Oo);if(uo){if(Fo>0)for(;vs--;)Gl[vs]||Mu[vs]||(Mu[vs]=ue.call(Io));Mu=wa(Mu)}yn.apply(Io,Mu),Ws&&!uo&&Mu.length>0&&Fo+ii.length>1&&Te.uniqueSort(Io)}return Ws&&(fa=lc,Rt=gu),Gl};return Ma?wu(ca):ca}function Jo(ei,ii){var Ma,pa=[],ca=[],uo=nl[ei+" "];if(!uo){for(ii||(ii=ol(ei)),Ma=ii.length;Ma--;)uo=Wa(ii[Ma]),uo[Ri]?pa.push(uo):ca.push(uo);uo=nl(ei,lo(ca,pa)),uo.selector=ei}return uo}function Xo(ei,ii,Ma,pa){var ca,uo,ya,Oo,Io,Ws=typeof ei=="function"&&ei,gr=!pa&&ol(ei=Ws.selector||ei);if(Ma=Ma||[],gr.length===1){if(uo=gr[0]=gr[0].slice(0),uo.length>2&&(ya=uo[0]).type==="ID"&&ii.nodeType===9&&Jn&&yt.relative[uo[1].type]){if(ii=(yt.find.ID(ya.matches[0].replace(Bs,su),ii)||[])[0],ii)Ws&&(ii=ii.parentNode);else return Ma;ei=ei.slice(uo.shift().value.length)}for(ca=Nl.needsContext.test(ei)?0:uo.length;ca--&&(ya=uo[ca],!yt.relative[Oo=ya.type]);)if((Io=yt.find[Oo])&&(pa=Io(ya.matches[0].replace(Bs,su),Gu.test(uo[0].type)&&qc(ii.parentNode)||ii))){if(uo.splice(ca,1),ei=pa.length&&od(uo),!ei)return yn.apply(Ma,pa),Ma;break}}return(Ws||Jo(ei,gr))(pa,ii,!Jn,Ma,!ii||Gu.test(ei)&&qc(ii.parentNode)||ii),Ma}J.sortStable=Ri.split("").sort(eu).join("")===Ri,vd(),J.sortDetached=oc(function(ei){return ei.compareDocumentPosition(In.createElement("fieldset"))&1}),Te.find=Wl,Te.expr[":"]=Te.expr.pseudos,Te.unique=Te.uniqueSort,Wl.compile=Jo,Wl.select=Xo,Wl.setDocument=vd,Wl.tokenize=ol,Wl.escape=Te.escapeSelector,Wl.getText=Te.text,Wl.isXML=Te.isXMLDoc,Wl.selectors=Te.expr,Wl.support=Te.support,Wl.uniqueSort=Te.uniqueSort})();var _n=function(Qe,yt,Rt){for(var jt=[],dn=Rt!==void 0;(Qe=Qe[yt])&&Qe.nodeType!==9;)if(Qe.nodeType===1){if(dn&&Te(Qe).is(Rt))break;jt.push(Qe)}return jt},Dn=function(Qe,yt){for(var Rt=[];Qe;Qe=Qe.nextSibling)Qe.nodeType===1&&Qe!==yt&&Rt.push(Qe);return Rt},an=Te.expr.match.needsContext,Rn=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function Lt(Qe,yt,Rt){return fe(yt)?Te.grep(Qe,function(jt,dn){return!!yt.call(jt,dn,jt)!==Rt}):yt.nodeType?Te.grep(Qe,function(jt){return jt===yt!==Rt}):typeof yt!="string"?Te.grep(Qe,function(jt){return m.call(yt,jt)>-1!==Rt}):Te.filter(yt,Qe,Rt)}Te.filter=function(Qe,yt,Rt){var jt=yt[0];return Rt&&(Qe=":not("+Qe+")"),yt.length===1&&jt.nodeType===1?Te.find.matchesSelector(jt,Qe)?[jt]:[]:Te.find.matches(Qe,Te.grep(yt,function(dn){return dn.nodeType===1}))},Te.fn.extend({find:function(Qe){var yt,Rt,jt=this.length,dn=this;if(typeof Qe!="string")return this.pushStack(Te(Qe).filter(function(){for(yt=0;yt<jt;yt++)if(Te.contains(dn[yt],this))return!0}));for(Rt=this.pushStack([]),yt=0;yt<jt;yt++)Te.find(Qe,dn[yt],Rt);return jt>1?Te.uniqueSort(Rt):Rt},filter:function(Qe){return this.pushStack(Lt(this,Qe||[],!1))},not:function(Qe){return this.pushStack(Lt(this,Qe||[],!0))},is:function(Qe){return!!Lt(this,typeof Qe=="string"&&an.test(Qe)?Te(Qe):Qe||[],!1).length}});var wn,hn=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/,xn=Te.fn.init=function(Qe,yt,Rt){var jt,dn;if(!Qe)return this;if(Rt=Rt||wn,typeof Qe=="string")if(Qe[0]==="<"&&Qe[Qe.length-1]===">"&&Qe.length>=3?jt=[null,Qe,null]:jt=hn.exec(Qe),jt&&(jt[1]||!yt))if(jt[1]){if(yt=yt instanceof Te?yt[0]:yt,Te.merge(this,Te.parseHTML(jt[1],yt&&yt.nodeType?yt.ownerDocument||yt:ne,!0)),Rn.test(jt[1])&&Te.isPlainObject(yt))for(jt in yt)fe(this[jt])?this[jt](yt[jt]):this.attr(jt,yt[jt]);return this}else return dn=ne.getElementById(jt[2]),dn&&(this[0]=dn,this.length=1),this;else return!yt||yt.jquery?(yt||Rt).find(Qe):this.constructor(yt).find(Qe);else{if(Qe.nodeType)return this[0]=Qe,this.length=1,this;if(fe(Qe))return Rt.ready!==void 0?Rt.ready(Qe):Qe(Te)}return Te.makeArray(Qe,this)};xn.prototype=Te.fn,wn=Te(ne);var $n=/^(?:parents|prev(?:Until|All))/,Xr={children:!0,contents:!0,next:!0,prev:!0};Te.fn.extend({has:function(Qe){var yt=Te(Qe,this),Rt=yt.length;return this.filter(function(){for(var jt=0;jt<Rt;jt++)if(Te.contains(this,yt[jt]))return!0})},closest:function(Qe,yt){var Rt,jt=0,dn=this.length,yn=[],In=typeof Qe!="string"&&Te(Qe);if(!an.test(Qe)){for(;jt<dn;jt++)for(Rt=this[jt];Rt&&Rt!==yt;Rt=Rt.parentNode)if(Rt.nodeType<11&&(In?In.index(Rt)>-1:Rt.nodeType===1&&Te.find.matchesSelector(Rt,Qe))){yn.push(Rt);break}}return this.pushStack(yn.length>1?Te.uniqueSort(yn):yn)},index:function(Qe){return Qe?typeof Qe=="string"?m.call(Te(Qe),this[0]):m.call(this,Qe.jquery?Qe[0]:Qe):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(Qe,yt){return this.pushStack(Te.uniqueSort(Te.merge(this.get(),Te(Qe,yt))))},addBack:function(Qe){return this.add(Qe==null?this.prevObject:this.prevObject.filter(Qe))}});function ti(Qe,yt){for(;(Qe=Qe[yt])&&Qe.nodeType!==1;);return Qe}Te.each({parent:function(Qe){var yt=Qe.parentNode;return yt&&yt.nodeType!==11?yt:null},parents:function(Qe){return _n(Qe,"parentNode")},parentsUntil:function(Qe,yt,Rt){return _n(Qe,"parentNode",Rt)},next:function(Qe){return ti(Qe,"nextSibling")},prev:function(Qe){return ti(Qe,"previousSibling")},nextAll:function(Qe){return _n(Qe,"nextSibling")},prevAll:function(Qe){return _n(Qe,"previousSibling")},nextUntil:function(Qe,yt,Rt){return _n(Qe,"nextSibling",Rt)},prevUntil:function(Qe,yt,Rt){return _n(Qe,"previousSibling",Rt)},siblings:function(Qe){return Dn((Qe.parentNode||{}).firstChild,Qe)},children:function(Qe){return Dn(Qe.firstChild)},contents:function(Qe){return Qe.contentDocument!=null&&u(Qe.contentDocument)?Qe.contentDocument:(ie(Qe,"template")&&(Qe=Qe.content||Qe),Te.merge([],Qe.childNodes))}},function(Qe,yt){Te.fn[Qe]=function(Rt,jt){var dn=Te.map(this,yt,Rt);return Qe.slice(-5)!=="Until"&&(jt=Rt),jt&&typeof jt=="string"&&(dn=Te.filter(jt,dn)),this.length>1&&(Xr[Qe]||Te.uniqueSort(dn),$n.test(Qe)&&dn.reverse()),this.pushStack(dn)}});var gn=/[^\x20\t\r\n\f]+/g;function Xn(Qe){var yt={};return Te.each(Qe.match(gn)||[],function(Rt,jt){yt[jt]=!0}),yt}Te.Callbacks=function(Qe){Qe=typeof Qe=="string"?Xn(Qe):Te.extend({},Qe);var yt,Rt,jt,dn,yn=[],In=[],vr=-1,Jn=function(){for(dn=dn||Qe.once,jt=yt=!0;In.length;vr=-1)for(Rt=In.shift();++vr<yn.length;)yn[vr].apply(Rt[0],Rt[1])===!1&&Qe.stopOnFalse&&(vr=yn.length,Rt=!1);Qe.memory||(Rt=!1),yt=!1,dn&&(Rt?yn=[]:yn="")},li={add:function(){return yn&&(Rt&&!yt&&(vr=yn.length-1,In.push(Rt)),function xa(Ri){Te.each(Ri,function(fa,oo){fe(oo)?(!Qe.unique||!li.has(oo))&&yn.push(oo):oo&&oo.length&&Ve(oo)!=="string"&&xa(oo)})}(arguments),Rt&&!yt&&Jn()),this},remove:function(){return Te.each(arguments,function(xa,Ri){for(var fa;(fa=Te.inArray(Ri,yn,fa))>-1;)yn.splice(fa,1),fa<=vr&&vr--}),this},has:function(xa){return xa?Te.inArray(xa,yn)>-1:yn.length>0},empty:function(){return yn&&(yn=[]),this},disable:function(){return dn=In=[],yn=Rt="",this},disabled:function(){return!yn},lock:function(){return dn=In=[],!Rt&&!yt&&(yn=Rt=""),this},locked:function(){return!!dn},fireWith:function(xa,Ri){return dn||(Ri=Ri||[],Ri=[xa,Ri.slice?Ri.slice():Ri],In.push(Ri),yt||Jn()),this},fire:function(){return li.fireWith(this,arguments),this},fired:function(){return!!jt}};return li};function Kn(Qe){return Qe}function Vn(Qe){throw Qe}function Yn(Qe,yt,Rt,jt){var dn;try{Qe&&fe(dn=Qe.promise)?dn.call(Qe).done(yt).fail(Rt):Qe&&fe(dn=Qe.then)?dn.call(Qe,yt,Rt):yt.apply(void 0,[Qe].slice(jt))}catch(yn){Rt.apply(void 0,[yn])}}Te.extend({Deferred:function(Qe){var yt=[["notify","progress",Te.Callbacks("memory"),Te.Callbacks("memory"),2],["resolve","done",Te.Callbacks("once memory"),Te.Callbacks("once memory"),0,"resolved"],["reject","fail",Te.Callbacks("once memory"),Te.Callbacks("once memory"),1,"rejected"]],Rt="pending",jt={state:function(){return Rt},always:function(){return dn.done(arguments).fail(arguments),this},catch:function(yn){return jt.then(null,yn)},pipe:function(){var yn=arguments;return Te.Deferred(function(In){Te.each(yt,function(vr,Jn){var li=fe(yn[Jn[4]])&&yn[Jn[4]];dn[Jn[1]](function(){var xa=li&&li.apply(this,arguments);xa&&fe(xa.promise)?xa.promise().progress(In.notify).done(In.resolve).fail(In.reject):In[Jn[0]+"With"](this,li?[xa]:arguments)})}),yn=null}).promise()},then:function(yn,In,vr){var Jn=0;function li(xa,Ri,fa,oo){return function(){var ts=this,bl=arguments,nl=function(){var eu,Gs;if(!(xa<Jn)){if(eu=fa.apply(ts,bl),eu===Ri.promise())throw new TypeError("Thenable self-resolution");Gs=eu&&(typeof eu=="object"||typeof eu=="function")&&eu.then,fe(Gs)?oo?Gs.call(eu,li(Jn,Ri,Kn,oo),li(Jn,Ri,Vn,oo)):(Jn++,Gs.call(eu,li(Jn,Ri,Kn,oo),li(Jn,Ri,Vn,oo),li(Jn,Ri,Kn,Ri.notifyWith))):(fa!==Kn&&(ts=void 0,bl=[eu]),(oo||Ri.resolveWith)(ts,bl))}},Fs=oo?nl:function(){try{nl()}catch(eu){Te.Deferred.exceptionHook&&Te.Deferred.exceptionHook(eu,Fs.error),xa+1>=Jn&&(fa!==Vn&&(ts=void 0,bl=[eu]),Ri.rejectWith(ts,bl))}};xa?Fs():(Te.Deferred.getErrorHook?Fs.error=Te.Deferred.getErrorHook():Te.Deferred.getStackHook&&(Fs.error=Te.Deferred.getStackHook()),e.setTimeout(Fs))}}return Te.Deferred(function(xa){yt[0][3].add(li(0,xa,fe(vr)?vr:Kn,xa.notifyWith)),yt[1][3].add(li(0,xa,fe(yn)?yn:Kn)),yt[2][3].add(li(0,xa,fe(In)?In:Vn))}).promise()},promise:function(yn){return yn!=null?Te.extend(yn,jt):jt}},dn={};return Te.each(yt,function(yn,In){var vr=In[2],Jn=In[5];jt[In[1]]=vr.add,Jn&&vr.add(function(){Rt=Jn},yt[3-yn][2].disable,yt[3-yn][3].disable,yt[0][2].lock,yt[0][3].lock),vr.add(In[3].fire),dn[In[0]]=function(){return dn[In[0]+"With"](this===dn?void 0:this,arguments),this},dn[In[0]+"With"]=vr.fireWith}),jt.promise(dn),Qe&&Qe.call(dn,dn),dn},when:function(Qe){var yt=arguments.length,Rt=yt,jt=Array(Rt),dn=c.call(arguments),yn=Te.Deferred(),In=function(vr){return function(Jn){jt[vr]=this,dn[vr]=arguments.length>1?c.call(arguments):Jn,--yt||yn.resolveWith(jt,dn)}};if(yt<=1&&(Yn(Qe,yn.done(In(Rt)).resolve,yn.reject,!yt),yn.state()==="pending"||fe(dn[Rt]&&dn[Rt].then)))return yn.then();for(;Rt--;)Yn(dn[Rt],In(Rt),yn.reject);return yn.promise()}});var Vr=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;Te.Deferred.exceptionHook=function(Qe,yt){e.console&&e.console.warn&&Qe&&Vr.test(Qe.name)&&e.console.warn("jQuery.Deferred exception: "+Qe.message,Qe.stack,yt)},Te.readyException=function(Qe){e.setTimeout(function(){throw Qe})};var xi=Te.Deferred();Te.fn.ready=function(Qe){return xi.then(Qe).catch(function(yt){Te.readyException(yt)}),this},Te.extend({isReady:!1,readyWait:1,ready:function(Qe){(Qe===!0?--Te.readyWait:Te.isReady)||(Te.isReady=!0,!(Qe!==!0&&--Te.readyWait>0)&&xi.resolveWith(ne,[Te]))}}),Te.ready.then=xi.then;function Si(){ne.removeEventListener("DOMContentLoaded",Si),e.removeEventListener("load",Si),Te.ready()}ne.readyState==="complete"||ne.readyState!=="loading"&&!ne.documentElement.doScroll?e.setTimeout(Te.ready):(ne.addEventListener("DOMContentLoaded",Si),e.addEventListener("load",Si));var qn=function(Qe,yt,Rt,jt,dn,yn,In){var vr=0,Jn=Qe.length,li=Rt==null;if(Ve(Rt)==="object"){dn=!0;for(vr in Rt)qn(Qe,yt,vr,Rt[vr],!0,yn,In)}else if(jt!==void 0&&(dn=!0,fe(jt)||(In=!0),li&&(In?(yt.call(Qe,jt),yt=null):(li=yt,yt=function(xa,Ri,fa){return li.call(Te(xa),fa)})),yt))for(;vr<Jn;vr++)yt(Qe[vr],Rt,In?jt:jt.call(Qe[vr],vr,yt(Qe[vr],Rt)));return dn?Qe:li?yt.call(Qe):Jn?yt(Qe[0],Rt):yn},ia=/^-ms-/,Wi=/-([a-z])/g;function ha(Qe,yt){return yt.toUpperCase()}function ai(Qe){return Qe.replace(ia,"ms-").replace(Wi,ha)}var Ia=function(Qe){return Qe.nodeType===1||Qe.nodeType===9||!+Qe.nodeType};function fi(){this.expando=Te.expando+fi.uid++}fi.uid=1,fi.prototype={cache:function(Qe){var yt=Qe[this.expando];return yt||(yt={},Ia(Qe)&&(Qe.nodeType?Qe[this.expando]=yt:Object.defineProperty(Qe,this.expando,{value:yt,configurable:!0}))),yt},set:function(Qe,yt,Rt){var jt,dn=this.cache(Qe);if(typeof yt=="string")dn[ai(yt)]=Rt;else for(jt in yt)dn[ai(jt)]=yt[jt];return dn},get:function(Qe,yt){return yt===void 0?this.cache(Qe):Qe[this.expando]&&Qe[this.expando][ai(yt)]},access:function(Qe,yt,Rt){return yt===void 0||yt&&typeof yt=="string"&&Rt===void 0?this.get(Qe,yt):(this.set(Qe,yt,Rt),Rt!==void 0?Rt:yt)},remove:function(Qe,yt){var Rt,jt=Qe[this.expando];if(jt!==void 0){if(yt!==void 0)for(Array.isArray(yt)?yt=yt.map(ai):(yt=ai(yt),yt=yt in jt?[yt]:yt.match(gn)||[]),Rt=yt.length;Rt--;)delete jt[yt[Rt]];(yt===void 0||Te.isEmptyObject(jt))&&(Qe.nodeType?Qe[this.expando]=void 0:delete Qe[this.expando])}},hasData:function(Qe){var yt=Qe[this.expando];return yt!==void 0&&!Te.isEmptyObject(yt)}};var An=new fi,sa=new fi,Nn=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,fn=/[A-Z]/g;function un(Qe){return Qe==="true"?!0:Qe==="false"?!1:Qe==="null"?null:Qe===+Qe+""?+Qe:Nn.test(Qe)?JSON.parse(Qe):Qe}function Ln(Qe,yt,Rt){var jt;if(Rt===void 0&&Qe.nodeType===1)if(jt="data-"+yt.replace(fn,"-$&").toLowerCase(),Rt=Qe.getAttribute(jt),typeof Rt=="string"){try{Rt=un(Rt)}catch{}sa.set(Qe,yt,Rt)}else Rt=void 0;return Rt}Te.extend({hasData:function(Qe){return sa.hasData(Qe)||An.hasData(Qe)},data:function(Qe,yt,Rt){return sa.access(Qe,yt,Rt)},removeData:function(Qe,yt){sa.remove(Qe,yt)},_data:function(Qe,yt,Rt){return An.access(Qe,yt,Rt)},_removeData:function(Qe,yt){An.remove(Qe,yt)}}),Te.fn.extend({data:function(Qe,yt){var Rt,jt,dn,yn=this[0],In=yn&&yn.attributes;if(Qe===void 0){if(this.length&&(dn=sa.get(yn),yn.nodeType===1&&!An.get(yn,"hasDataAttrs"))){for(Rt=In.length;Rt--;)In[Rt]&&(jt=In[Rt].name,jt.indexOf("data-")===0&&(jt=ai(jt.slice(5)),Ln(yn,jt,dn[jt])));An.set(yn,"hasDataAttrs",!0)}return dn}return typeof Qe=="object"?this.each(function(){sa.set(this,Qe)}):qn(this,function(vr){var Jn;if(yn&&vr===void 0)return Jn=sa.get(yn,Qe),Jn!==void 0||(Jn=Ln(yn,Qe),Jn!==void 0)?Jn:void 0;this.each(function(){sa.set(this,Qe,vr)})},null,yt,arguments.length>1,null,!0)},removeData:function(Qe){return this.each(function(){sa.remove(this,Qe)})}}),Te.extend({queue:function(Qe,yt,Rt){var jt;if(Qe)return yt=(yt||"fx")+"queue",jt=An.get(Qe,yt),Rt&&(!jt||Array.isArray(Rt)?jt=An.access(Qe,yt,Te.makeArray(Rt)):jt.push(Rt)),jt||[]},dequeue:function(Qe,yt){yt=yt||"fx";var Rt=Te.queue(Qe,yt),jt=Rt.length,dn=Rt.shift(),yn=Te._queueHooks(Qe,yt),In=function(){Te.dequeue(Qe,yt)};dn==="inprogress"&&(dn=Rt.shift(),jt--),dn&&(yt==="fx"&&Rt.unshift("inprogress"),delete yn.stop,dn.call(Qe,In,yn)),!jt&&yn&&yn.empty.fire()},_queueHooks:function(Qe,yt){var Rt=yt+"queueHooks";return An.get(Qe,Rt)||An.access(Qe,Rt,{empty:Te.Callbacks("once memory").add(function(){An.remove(Qe,[yt+"queue",Rt])})})}}),Te.fn.extend({queue:function(Qe,yt){var Rt=2;return typeof Qe!="string"&&(yt=Qe,Qe="fx",Rt--),arguments.length<Rt?Te.queue(this[0],Qe):yt===void 0?this:this.each(function(){var jt=Te.queue(this,Qe,yt);Te._queueHooks(this,Qe),Qe==="fx"&&jt[0]!=="inprogress"&&Te.dequeue(this,Qe)})},dequeue:function(Qe){return this.each(function(){Te.dequeue(this,Qe)})},clearQueue:function(Qe){return this.queue(Qe||"fx",[])},promise:function(Qe,yt){var Rt,jt=1,dn=Te.Deferred(),yn=this,In=this.length,vr=function(){--jt||dn.resolveWith(yn,[yn])};for(typeof Qe!="string"&&(yt=Qe,Qe=void 0),Qe=Qe||"fx";In--;)Rt=An.get(yn[In],Qe+"queueHooks"),Rt&&Rt.empty&&(jt++,Rt.empty.add(vr));return vr(),dn.promise(yt)}});var hr=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,hi=new RegExp("^(?:([+-])=|)("+hr+")([a-z%]*)$","i"),bi=["Top","Right","Bottom","Left"],Ra=ne.documentElement,so=function(Qe){return Te.contains(Qe.ownerDocument,Qe)},Pi={composed:!0};Ra.getRootNode&&(so=function(Qe){return Te.contains(Qe.ownerDocument,Qe)||Qe.getRootNode(Pi)===Qe.ownerDocument});var oi=function(Qe,yt){return Qe=yt||Qe,Qe.style.display==="none"||Qe.style.display===""&&so(Qe)&&Te.css(Qe,"display")==="none"};function Ni(Qe,yt,Rt,jt){var dn,yn,In=20,vr=jt?function(){return jt.cur()}:function(){return Te.css(Qe,yt,"")},Jn=vr(),li=Rt&&Rt[3]||(Te.cssNumber[yt]?"":"px"),xa=Qe.nodeType&&(Te.cssNumber[yt]||li!=="px"&&+Jn)&&hi.exec(Te.css(Qe,yt));if(xa&&xa[3]!==li){for(Jn=Jn/2,li=li||xa[3],xa=+Jn||1;In--;)Te.style(Qe,yt,xa+li),(1-yn)*(1-(yn=vr()/Jn||.5))<=0&&(In=0),xa=xa/yn;xa=xa*2,Te.style(Qe,yt,xa+li),Rt=Rt||[]}return Rt&&(xa=+xa||+Jn||0,dn=Rt[1]?xa+(Rt[1]+1)*Rt[2]:+Rt[2],jt&&(jt.unit=li,jt.start=xa,jt.end=dn)),dn}var za={};function ki(Qe){var yt,Rt=Qe.ownerDocument,jt=Qe.nodeName,dn=za[jt];return dn||(yt=Rt.body.appendChild(Rt.createElement(jt)),dn=Te.css(yt,"display"),yt.parentNode.removeChild(yt),dn==="none"&&(dn="block"),za[jt]=dn,dn)}function Aa(Qe,yt){for(var Rt,jt,dn=[],yn=0,In=Qe.length;yn<In;yn++)jt=Qe[yn],jt.style&&(Rt=jt.style.display,yt?(Rt==="none"&&(dn[yn]=An.get(jt,"display")||null,dn[yn]||(jt.style.display="")),jt.style.display===""&&oi(jt)&&(dn[yn]=ki(jt))):Rt!=="none"&&(dn[yn]="none",An.set(jt,"display",Rt)));for(yn=0;yn<In;yn++)dn[yn]!=null&&(Qe[yn].style.display=dn[yn]);return Qe}Te.fn.extend({show:function(){return Aa(this,!0)},hide:function(){return Aa(this)},toggle:function(Qe){return typeof Qe=="boolean"?Qe?this.show():this.hide():this.each(function(){oi(this)?Te(this).show():Te(this).hide()})}});var Ja=/^(?:checkbox|radio)$/i,yo=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,ls=/^$|^module$|\/(?:java|ecma)script/i;(function(){var Qe=ne.createDocumentFragment(),yt=Qe.appendChild(ne.createElement("div")),Rt=ne.createElement("input");Rt.setAttribute("type","radio"),Rt.setAttribute("checked","checked"),Rt.setAttribute("name","t"),yt.appendChild(Rt),J.checkClone=yt.cloneNode(!0).cloneNode(!0).lastChild.checked,yt.innerHTML="<textarea>x</textarea>",J.noCloneChecked=!!yt.cloneNode(!0).lastChild.defaultValue,yt.innerHTML="<option></option>",J.option=!!yt.lastChild})();var xo={thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};xo.tbody=xo.tfoot=xo.colgroup=xo.caption=xo.thead,xo.th=xo.td,J.option||(xo.optgroup=xo.option=[1,"<select multiple='multiple'>","</select>"]);function _o(Qe,yt){var Rt;return typeof Qe.getElementsByTagName<"u"?Rt=Qe.getElementsByTagName(yt||"*"):typeof Qe.querySelectorAll<"u"?Rt=Qe.querySelectorAll(yt||"*"):Rt=[],yt===void 0||yt&&ie(Qe,yt)?Te.merge([Qe],Rt):Rt}function Ao(Qe,yt){for(var Rt=0,jt=Qe.length;Rt<jt;Rt++)An.set(Qe[Rt],"globalEval",!yt||An.get(yt[Rt],"globalEval"))}var il=/<|&#?\w+;/;function zr(Qe,yt,Rt,jt,dn){for(var yn,In,vr,Jn,li,xa,Ri=yt.createDocumentFragment(),fa=[],oo=0,ts=Qe.length;oo<ts;oo++)if(yn=Qe[oo],yn||yn===0)if(Ve(yn)==="object")Te.merge(fa,yn.nodeType?[yn]:yn);else if(!il.test(yn))fa.push(yt.createTextNode(yn));else{for(In=In||Ri.appendChild(yt.createElement("div")),vr=(yo.exec(yn)||["",""])[1].toLowerCase(),Jn=xo[vr]||xo._default,In.innerHTML=Jn[1]+Te.htmlPrefilter(yn)+Jn[2],xa=Jn[0];xa--;)In=In.lastChild;Te.merge(fa,In.childNodes),In=Ri.firstChild,In.textContent=""}for(Ri.textContent="",oo=0;yn=fa[oo++];){if(jt&&Te.inArray(yn,jt)>-1){dn&&dn.push(yn);continue}if(li=so(yn),In=_o(Ri.appendChild(yn),"script"),li&&Ao(In),Rt)for(xa=0;yn=In[xa++];)ls.test(yn.type||"")&&Rt.push(yn)}return Ri}var zn=/^([^.]*)(?:\.(.+)|)/;function Un(){return!0}function Gr(){return!1}function ni(Qe,yt,Rt,jt,dn,yn){var In,vr;if(typeof yt=="object"){typeof Rt!="string"&&(jt=jt||Rt,Rt=void 0);for(vr in yt)ni(Qe,vr,Rt,jt,yt[vr],yn);return Qe}if(jt==null&&dn==null?(dn=Rt,jt=Rt=void 0):dn==null&&(typeof Rt=="string"?(dn=jt,jt=void 0):(dn=jt,jt=Rt,Rt=void 0)),dn===!1)dn=Gr;else if(!dn)return Qe;return yn===1&&(In=dn,dn=function(Jn){return Te().off(Jn),In.apply(this,arguments)},dn.guid=In.guid||(In.guid=Te.guid++)),Qe.each(function(){Te.event.add(this,yt,dn,jt,Rt)})}Te.event={global:{},add:function(Qe,yt,Rt,jt,dn){var yn,In,vr,Jn,li,xa,Ri,fa,oo,ts,bl,nl=An.get(Qe);if(Ia(Qe))for(Rt.handler&&(yn=Rt,Rt=yn.handler,dn=yn.selector),dn&&Te.find.matchesSelector(Ra,dn),Rt.guid||(Rt.guid=Te.guid++),(Jn=nl.events)||(Jn=nl.events=Object.create(null)),(In=nl.handle)||(In=nl.handle=function(Fs){return typeof Te<"u"&&Te.event.triggered!==Fs.type?Te.event.dispatch.apply(Qe,arguments):void 0}),yt=(yt||"").match(gn)||[""],li=yt.length;li--;)vr=zn.exec(yt[li])||[],oo=bl=vr[1],ts=(vr[2]||"").split(".").sort(),oo&&(Ri=Te.event.special[oo]||{},oo=(dn?Ri.delegateType:Ri.bindType)||oo,Ri=Te.event.special[oo]||{},xa=Te.extend({type:oo,origType:bl,data:jt,handler:Rt,guid:Rt.guid,selector:dn,needsContext:dn&&Te.expr.match.needsContext.test(dn),namespace:ts.join(".")},yn),(fa=Jn[oo])||(fa=Jn[oo]=[],fa.delegateCount=0,(!Ri.setup||Ri.setup.call(Qe,jt,ts,In)===!1)&&Qe.addEventListener&&Qe.addEventListener(oo,In)),Ri.add&&(Ri.add.call(Qe,xa),xa.handler.guid||(xa.handler.guid=Rt.guid)),dn?fa.splice(fa.delegateCount++,0,xa):fa.push(xa),Te.event.global[oo]=!0)},remove:function(Qe,yt,Rt,jt,dn){var yn,In,vr,Jn,li,xa,Ri,fa,oo,ts,bl,nl=An.hasData(Qe)&&An.get(Qe);if(!(!nl||!(Jn=nl.events))){for(yt=(yt||"").match(gn)||[""],li=yt.length;li--;){if(vr=zn.exec(yt[li])||[],oo=bl=vr[1],ts=(vr[2]||"").split(".").sort(),!oo){for(oo in Jn)Te.event.remove(Qe,oo+yt[li],Rt,jt,!0);continue}for(Ri=Te.event.special[oo]||{},oo=(jt?Ri.delegateType:Ri.bindType)||oo,fa=Jn[oo]||[],vr=vr[2]&&new RegExp("(^|\\.)"+ts.join("\\.(?:.*\\.|)")+"(\\.|$)"),In=yn=fa.length;yn--;)xa=fa[yn],(dn||bl===xa.origType)&&(!Rt||Rt.guid===xa.guid)&&(!vr||vr.test(xa.namespace))&&(!jt||jt===xa.selector||jt==="**"&&xa.selector)&&(fa.splice(yn,1),xa.selector&&fa.delegateCount--,Ri.remove&&Ri.remove.call(Qe,xa));In&&!fa.length&&((!Ri.teardown||Ri.teardown.call(Qe,ts,nl.handle)===!1)&&Te.removeEvent(Qe,oo,nl.handle),delete Jn[oo])}Te.isEmptyObject(Jn)&&An.remove(Qe,"handle events")}},dispatch:function(Qe){var yt,Rt,jt,dn,yn,In,vr=new Array(arguments.length),Jn=Te.event.fix(Qe),li=(An.get(this,"events")||Object.create(null))[Jn.type]||[],xa=Te.event.special[Jn.type]||{};for(vr[0]=Jn,yt=1;yt<arguments.length;yt++)vr[yt]=arguments[yt];if(Jn.delegateTarget=this,!(xa.preDispatch&&xa.preDispatch.call(this,Jn)===!1)){for(In=Te.event.handlers.call(this,Jn,li),yt=0;(dn=In[yt++])&&!Jn.isPropagationStopped();)for(Jn.currentTarget=dn.elem,Rt=0;(yn=dn.handlers[Rt++])&&!Jn.isImmediatePropagationStopped();)(!Jn.rnamespace||yn.namespace===!1||Jn.rnamespace.test(yn.namespace))&&(Jn.handleObj=yn,Jn.data=yn.data,jt=((Te.event.special[yn.origType]||{}).handle||yn.handler).apply(dn.elem,vr),jt!==void 0&&(Jn.result=jt)===!1&&(Jn.preventDefault(),Jn.stopPropagation()));return xa.postDispatch&&xa.postDispatch.call(this,Jn),Jn.result}},handlers:function(Qe,yt){var Rt,jt,dn,yn,In,vr=[],Jn=yt.delegateCount,li=Qe.target;if(Jn&&li.nodeType&&!(Qe.type==="click"&&Qe.button>=1)){for(;li!==this;li=li.parentNode||this)if(li.nodeType===1&&!(Qe.type==="click"&&li.disabled===!0)){for(yn=[],In={},Rt=0;Rt<Jn;Rt++)jt=yt[Rt],dn=jt.selector+" ",In[dn]===void 0&&(In[dn]=jt.needsContext?Te(dn,this).index(li)>-1:Te.find(dn,this,null,[li]).length),In[dn]&&yn.push(jt);yn.length&&vr.push({elem:li,handlers:yn})}}return li=this,Jn<yt.length&&vr.push({elem:li,handlers:yt.slice(Jn)}),vr},addProp:function(Qe,yt){Object.defineProperty(Te.Event.prototype,Qe,{enumerable:!0,configurable:!0,get:fe(yt)?function(){if(this.originalEvent)return yt(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[Qe]},set:function(Rt){Object.defineProperty(this,Qe,{enumerable:!0,configurable:!0,writable:!0,value:Rt})}})},fix:function(Qe){return Qe[Te.expando]?Qe:new Te.Event(Qe)},special:{load:{noBubble:!0},click:{setup:function(Qe){var yt=this||Qe;return Ja.test(yt.type)&&yt.click&&ie(yt,"input")&&Ei(yt,"click",!0),!1},trigger:function(Qe){var yt=this||Qe;return Ja.test(yt.type)&&yt.click&&ie(yt,"input")&&Ei(yt,"click"),!0},_default:function(Qe){var yt=Qe.target;return Ja.test(yt.type)&&yt.click&&ie(yt,"input")&&An.get(yt,"click")||ie(yt,"a")}},beforeunload:{postDispatch:function(Qe){Qe.result!==void 0&&Qe.originalEvent&&(Qe.originalEvent.returnValue=Qe.result)}}}};function Ei(Qe,yt,Rt){if(!Rt){An.get(Qe,yt)===void 0&&Te.event.add(Qe,yt,Un);return}An.set(Qe,yt,!1),Te.event.add(Qe,yt,{namespace:!1,handler:function(jt){var dn,yn=An.get(this,yt);if(jt.isTrigger&1&&this[yt]){if(yn)(Te.event.special[yt]||{}).delegateType&&jt.stopPropagation();else if(yn=c.call(arguments),An.set(this,yt,yn),this[yt](),dn=An.get(this,yt),An.set(this,yt,!1),yn!==dn)return jt.stopImmediatePropagation(),jt.preventDefault(),dn}else yn&&(An.set(this,yt,Te.event.trigger(yn[0],yn.slice(1),this)),jt.stopPropagation(),jt.isImmediatePropagationStopped=Un)}})}Te.removeEvent=function(Qe,yt,Rt){Qe.removeEventListener&&Qe.removeEventListener(yt,Rt)},Te.Event=function(Qe,yt){if(!(this instanceof Te.Event))return new Te.Event(Qe,yt);Qe&&Qe.type?(this.originalEvent=Qe,this.type=Qe.type,this.isDefaultPrevented=Qe.defaultPrevented||Qe.defaultPrevented===void 0&&Qe.returnValue===!1?Un:Gr,this.target=Qe.target&&Qe.target.nodeType===3?Qe.target.parentNode:Qe.target,this.currentTarget=Qe.currentTarget,this.relatedTarget=Qe.relatedTarget):this.type=Qe,yt&&Te.extend(this,yt),this.timeStamp=Qe&&Qe.timeStamp||Date.now(),this[Te.expando]=!0},Te.Event.prototype={constructor:Te.Event,isDefaultPrevented:Gr,isPropagationStopped:Gr,isImmediatePropagationStopped:Gr,isSimulated:!1,preventDefault:function(){var Qe=this.originalEvent;this.isDefaultPrevented=Un,Qe&&!this.isSimulated&&Qe.preventDefault()},stopPropagation:function(){var Qe=this.originalEvent;this.isPropagationStopped=Un,Qe&&!this.isSimulated&&Qe.stopPropagation()},stopImmediatePropagation:function(){var Qe=this.originalEvent;this.isImmediatePropagationStopped=Un,Qe&&!this.isSimulated&&Qe.stopImmediatePropagation(),this.stopPropagation()}},Te.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,char:!0,code:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:!0},Te.event.addProp),Te.each({focus:"focusin",blur:"focusout"},function(Qe,yt){function Rt(jt){if(ne.documentMode){var dn=An.get(this,"handle"),yn=Te.event.fix(jt);yn.type=jt.type==="focusin"?"focus":"blur",yn.isSimulated=!0,dn(jt),yn.target===yn.currentTarget&&dn(yn)}else Te.event.simulate(yt,jt.target,Te.event.fix(jt))}Te.event.special[Qe]={setup:function(){var jt;if(Ei(this,Qe,!0),ne.documentMode)jt=An.get(this,yt),jt||this.addEventListener(yt,Rt),An.set(this,yt,(jt||0)+1);else return!1},trigger:function(){return Ei(this,Qe),!0},teardown:function(){var jt;if(ne.documentMode)jt=An.get(this,yt)-1,jt?An.set(this,yt,jt):(this.removeEventListener(yt,Rt),An.remove(this,yt));else return!1},_default:function(jt){return An.get(jt.target,Qe)},delegateType:yt},Te.event.special[yt]={setup:function(){var jt=this.ownerDocument||this.document||this,dn=ne.documentMode?this:jt,yn=An.get(dn,yt);yn||(ne.documentMode?this.addEventListener(yt,Rt):jt.addEventListener(Qe,Rt,!0)),An.set(dn,yt,(yn||0)+1)},teardown:function(){var jt=this.ownerDocument||this.document||this,dn=ne.documentMode?this:jt,yn=An.get(dn,yt)-1;yn?An.set(dn,yt,yn):(ne.documentMode?this.removeEventListener(yt,Rt):jt.removeEventListener(Qe,Rt,!0),An.remove(dn,yt))}}}),Te.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(Qe,yt){Te.event.special[Qe]={delegateType:yt,bindType:yt,handle:function(Rt){var jt,dn=this,yn=Rt.relatedTarget,In=Rt.handleObj;return(!yn||yn!==dn&&!Te.contains(dn,yn))&&(Rt.type=In.origType,jt=In.handler.apply(this,arguments),Rt.type=yt),jt}}}),Te.fn.extend({on:function(Qe,yt,Rt,jt){return ni(this,Qe,yt,Rt,jt)},one:function(Qe,yt,Rt,jt){return ni(this,Qe,yt,Rt,jt,1)},off:function(Qe,yt,Rt){var jt,dn;if(Qe&&Qe.preventDefault&&Qe.handleObj)return jt=Qe.handleObj,Te(Qe.delegateTarget).off(jt.namespace?jt.origType+"."+jt.namespace:jt.origType,jt.selector,jt.handler),this;if(typeof Qe=="object"){for(dn in Qe)this.off(dn,yt,Qe[dn]);return this}return(yt===!1||typeof yt=="function")&&(Rt=yt,yt=void 0),Rt===!1&&(Rt=Gr),this.each(function(){Te.event.remove(this,Qe,Rt,yt)})}});var $t=/<script|<style|<link/i,ta=/checked\s*(?:[^=]|=\s*.checked.)/i,Hi=/^\s*<!\[CDATA\[|\]\]>\s*$/g;function Ai(Qe,yt){return ie(Qe,"table")&&ie(yt.nodeType!==11?yt:yt.firstChild,"tr")&&Te(Qe).children("tbody")[0]||Qe}function Ea(Qe){return Qe.type=(Qe.getAttribute("type")!==null)+"/"+Qe.type,Qe}function wo(Qe){return(Qe.type||"").slice(0,5)==="true/"?Qe.type=Qe.type.slice(5):Qe.removeAttribute("type"),Qe}function to(Qe,yt){var Rt,jt,dn,yn,In,vr,Jn;if(yt.nodeType===1){if(An.hasData(Qe)&&(yn=An.get(Qe),Jn=yn.events,Jn)){An.remove(yt,"handle events");for(dn in Jn)for(Rt=0,jt=Jn[dn].length;Rt<jt;Rt++)Te.event.add(yt,dn,Jn[dn][Rt])}sa.hasData(Qe)&&(In=sa.access(Qe),vr=Te.extend({},In),sa.set(yt,vr))}}function zo(Qe,yt){var Rt=yt.nodeName.toLowerCase();Rt==="input"&&Ja.test(Qe.type)?yt.checked=Qe.checked:(Rt==="input"||Rt==="textarea")&&(yt.defaultValue=Qe.defaultValue)}function Po(Qe,yt,Rt,jt){yt=y(yt);var dn,yn,In,vr,Jn,li,xa=0,Ri=Qe.length,fa=Ri-1,oo=yt[0],ts=fe(oo);if(ts||Ri>1&&typeof oo=="string"&&!J.checkClone&&ta.test(oo))return Qe.each(function(bl){var nl=Qe.eq(bl);ts&&(yt[0]=oo.call(this,bl,nl.html())),Po(nl,yt,Rt,jt)});if(Ri&&(dn=zr(yt,Qe[0].ownerDocument,!1,Qe,jt),yn=dn.firstChild,dn.childNodes.length===1&&(dn=yn),yn||jt)){for(In=Te.map(_o(dn,"script"),Ea),vr=In.length;xa<Ri;xa++)Jn=dn,xa!==fa&&(Jn=Te.clone(Jn,!0,!0),vr&&Te.merge(In,_o(Jn,"script"))),Rt.call(Qe[xa],Jn,xa);if(vr)for(li=In[In.length-1].ownerDocument,Te.map(In,wo),xa=0;xa<vr;xa++)Jn=In[xa],ls.test(Jn.type||"")&&!An.access(Jn,"globalEval")&&Te.contains(li,Jn)&&(Jn.src&&(Jn.type||"").toLowerCase()!=="module"?Te._evalUrl&&!Jn.noModule&&Te._evalUrl(Jn.src,{nonce:Jn.nonce||Jn.getAttribute("nonce")},li):De(Jn.textContent.replace(Hi,""),Jn,li))}return Qe}function Lo(Qe,yt,Rt){for(var jt,dn=yt?Te.filter(yt,Qe):Qe,yn=0;(jt=dn[yn])!=null;yn++)!Rt&&jt.nodeType===1&&Te.cleanData(_o(jt)),jt.parentNode&&(Rt&&so(jt)&&Ao(_o(jt,"script")),jt.parentNode.removeChild(jt));return Qe}Te.extend({htmlPrefilter:function(Qe){return Qe},clone:function(Qe,yt,Rt){var jt,dn,yn,In,vr=Qe.cloneNode(!0),Jn=so(Qe);if(!J.noCloneChecked&&(Qe.nodeType===1||Qe.nodeType===11)&&!Te.isXMLDoc(Qe))for(In=_o(vr),yn=_o(Qe),jt=0,dn=yn.length;jt<dn;jt++)zo(yn[jt],In[jt]);if(yt)if(Rt)for(yn=yn||_o(Qe),In=In||_o(vr),jt=0,dn=yn.length;jt<dn;jt++)to(yn[jt],In[jt]);else to(Qe,vr);return In=_o(vr,"script"),In.length>0&&Ao(In,!Jn&&_o(Qe,"script")),vr},cleanData:function(Qe){for(var yt,Rt,jt,dn=Te.event.special,yn=0;(Rt=Qe[yn])!==void 0;yn++)if(Ia(Rt)){if(yt=Rt[An.expando]){if(yt.events)for(jt in yt.events)dn[jt]?Te.event.remove(Rt,jt):Te.removeEvent(Rt,jt,yt.handle);Rt[An.expando]=void 0}Rt[sa.expando]&&(Rt[sa.expando]=void 0)}}}),Te.fn.extend({detach:function(Qe){return Lo(this,Qe,!0)},remove:function(Qe){return Lo(this,Qe)},text:function(Qe){return qn(this,function(yt){return yt===void 0?Te.text(this):this.empty().each(function(){(this.nodeType===1||this.nodeType===11||this.nodeType===9)&&(this.textContent=yt)})},null,Qe,arguments.length)},append:function(){return Po(this,arguments,function(Qe){if(this.nodeType===1||this.nodeType===11||this.nodeType===9){var yt=Ai(this,Qe);yt.appendChild(Qe)}})},prepend:function(){return Po(this,arguments,function(Qe){if(this.nodeType===1||this.nodeType===11||this.nodeType===9){var yt=Ai(this,Qe);yt.insertBefore(Qe,yt.firstChild)}})},before:function(){return Po(this,arguments,function(Qe){this.parentNode&&this.parentNode.insertBefore(Qe,this)})},after:function(){return Po(this,arguments,function(Qe){this.parentNode&&this.parentNode.insertBefore(Qe,this.nextSibling)})},empty:function(){for(var Qe,yt=0;(Qe=this[yt])!=null;yt++)Qe.nodeType===1&&(Te.cleanData(_o(Qe,!1)),Qe.textContent="");return this},clone:function(Qe,yt){return Qe=Qe??!1,yt=yt??Qe,this.map(function(){return Te.clone(this,Qe,yt)})},html:function(Qe){return qn(this,function(yt){var Rt=this[0]||{},jt=0,dn=this.length;if(yt===void 0&&Rt.nodeType===1)return Rt.innerHTML;if(typeof yt=="string"&&!$t.test(yt)&&!xo[(yo.exec(yt)||["",""])[1].toLowerCase()]){yt=Te.htmlPrefilter(yt);try{for(;jt<dn;jt++)Rt=this[jt]||{},Rt.nodeType===1&&(Te.cleanData(_o(Rt,!1)),Rt.innerHTML=yt);Rt=0}catch{}}Rt&&this.empty().append(yt)},null,Qe,arguments.length)},replaceWith:function(){var Qe=[];return Po(this,arguments,function(yt){var Rt=this.parentNode;Te.inArray(this,Qe)<0&&(Te.cleanData(_o(this)),Rt&&Rt.replaceChild(yt,this))},Qe)}}),Te.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(Qe,yt){Te.fn[Qe]=function(Rt){for(var jt,dn=[],yn=Te(Rt),In=yn.length-1,vr=0;vr<=In;vr++)jt=vr===In?this:this.clone(!0),Te(yn[vr])[yt](jt),b.apply(dn,jt.get());return this.pushStack(dn)}});var Wo=new RegExp("^("+hr+")(?!px)[a-z%]+$","i"),ma=/^--/,$s=function(Qe){var yt=Qe.ownerDocument.defaultView;return(!yt||!yt.opener)&&(yt=e),yt.getComputedStyle(Qe)},ao=function(Qe,yt,Rt){var jt,dn,yn={};for(dn in yt)yn[dn]=Qe.style[dn],Qe.style[dn]=yt[dn];jt=Rt.call(Qe);for(dn in yt)Qe.style[dn]=yn[dn];return jt},Ps=new RegExp(bi.join("|"),"i");(function(){function Qe(){if(li){Jn.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",li.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",Ra.appendChild(Jn).appendChild(li);var xa=e.getComputedStyle(li);Rt=xa.top!=="1%",vr=yt(xa.marginLeft)===12,li.style.right="60%",yn=yt(xa.right)===36,jt=yt(xa.width)===36,li.style.position="absolute",dn=yt(li.offsetWidth/3)===12,Ra.removeChild(Jn),li=null}}function yt(xa){return Math.round(parseFloat(xa))}var Rt,jt,dn,yn,In,vr,Jn=ne.createElement("div"),li=ne.createElement("div");li.style&&(li.style.backgroundClip="content-box",li.cloneNode(!0).style.backgroundClip="",J.clearCloneStyle=li.style.backgroundClip==="content-box",Te.extend(J,{boxSizingReliable:function(){return Qe(),jt},pixelBoxStyles:function(){return Qe(),yn},pixelPosition:function(){return Qe(),Rt},reliableMarginLeft:function(){return Qe(),vr},scrollboxSize:function(){return Qe(),dn},reliableTrDimensions:function(){var xa,Ri,fa,oo;return In==null&&(xa=ne.createElement("table"),Ri=ne.createElement("tr"),fa=ne.createElement("div"),xa.style.cssText="position:absolute;left:-11111px;border-collapse:separate",Ri.style.cssText="box-sizing:content-box;border:1px solid",Ri.style.height="1px",fa.style.height="9px",fa.style.display="block",Ra.appendChild(xa).appendChild(Ri).appendChild(fa),oo=e.getComputedStyle(Ri),In=parseInt(oo.height,10)+parseInt(oo.borderTopWidth,10)+parseInt(oo.borderBottomWidth,10)===Ri.offsetHeight,Ra.removeChild(xa)),In}}))})();function qo(Qe,yt,Rt){var jt,dn,yn,In,vr=ma.test(yt),Jn=Qe.style;return Rt=Rt||$s(Qe),Rt&&(In=Rt.getPropertyValue(yt)||Rt[yt],vr&&In&&(In=In.replace(kt,"$1")||void 0),In===""&&!so(Qe)&&(In=Te.style(Qe,yt)),!J.pixelBoxStyles()&&Wo.test(In)&&Ps.test(yt)&&(jt=Jn.width,dn=Jn.minWidth,yn=Jn.maxWidth,Jn.minWidth=Jn.maxWidth=Jn.width=In,In=Rt.width,Jn.width=jt,Jn.minWidth=dn,Jn.maxWidth=yn)),In!==void 0?In+"":In}function wl(Qe,yt){return{get:function(){if(Qe()){delete this.get;return}return(this.get=yt).apply(this,arguments)}}}var yu=["Webkit","Moz","ms"],po=ne.createElement("div").style,Zs={};function Es(Qe){for(var yt=Qe[0].toUpperCase()+Qe.slice(1),Rt=yu.length;Rt--;)if(Qe=yu[Rt]+yt,Qe in po)return Qe}function Xl(Qe){var yt=Te.cssProps[Qe]||Zs[Qe];return yt||(Qe in po?Qe:Zs[Qe]=Es(Qe)||Qe)}var xl=/^(none|table(?!-c[ea]).+)/,jo={position:"absolute",visibility:"hidden",display:"block"},ju={letterSpacing:"0",fontWeight:"400"};function Pl(Qe,yt,Rt){var jt=hi.exec(yt);return jt?Math.max(0,jt[2]-(Rt||0))+(jt[3]||"px"):yt}function tl(Qe,yt,Rt,jt,dn,yn){var In=yt==="width"?1:0,vr=0,Jn=0,li=0;if(Rt===(jt?"border":"content"))return 0;for(;In<4;In+=2)Rt==="margin"&&(li+=Te.css(Qe,Rt+bi[In],!0,dn)),jt?(Rt==="content"&&(Jn-=Te.css(Qe,"padding"+bi[In],!0,dn)),Rt!=="margin"&&(Jn-=Te.css(Qe,"border"+bi[In]+"Width",!0,dn))):(Jn+=Te.css(Qe,"padding"+bi[In],!0,dn),Rt!=="padding"?Jn+=Te.css(Qe,"border"+bi[In]+"Width",!0,dn):vr+=Te.css(Qe,"border"+bi[In]+"Width",!0,dn));return!jt&&yn>=0&&(Jn+=Math.max(0,Math.ceil(Qe["offset"+yt[0].toUpperCase()+yt.slice(1)]-yn-Jn-vr-.5))||0),Jn+li}function zl(Qe,yt,Rt){var jt=$s(Qe),dn=!J.boxSizingReliable()||Rt,yn=dn&&Te.css(Qe,"boxSizing",!1,jt)==="border-box",In=yn,vr=qo(Qe,yt,jt),Jn="offset"+yt[0].toUpperCase()+yt.slice(1);if(Wo.test(vr)){if(!Rt)return vr;vr="auto"}return(!J.boxSizingReliable()&&yn||!J.reliableTrDimensions()&&ie(Qe,"tr")||vr==="auto"||!parseFloat(vr)&&Te.css(Qe,"display",!1,jt)==="inline")&&Qe.getClientRects().length&&(yn=Te.css(Qe,"boxSizing",!1,jt)==="border-box",In=Jn in Qe,In&&(vr=Qe[Jn])),vr=parseFloat(vr)||0,vr+tl(Qe,yt,Rt||(yn?"border":"content"),In,jt,vr)+"px"}Te.extend({cssHooks:{opacity:{get:function(Qe,yt){if(yt){var Rt=qo(Qe,"opacity");return Rt===""?"1":Rt}}}},cssNumber:{animationIterationCount:!0,aspectRatio:!0,borderImageSlice:!0,columnCount:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,scale:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeMiterlimit:!0,strokeOpacity:!0},cssProps:{},style:function(Qe,yt,Rt,jt){if(!(!Qe||Qe.nodeType===3||Qe.nodeType===8||!Qe.style)){var dn,yn,In,vr=ai(yt),Jn=ma.test(yt),li=Qe.style;if(Jn||(yt=Xl(vr)),In=Te.cssHooks[yt]||Te.cssHooks[vr],Rt!==void 0){if(yn=typeof Rt,yn==="string"&&(dn=hi.exec(Rt))&&dn[1]&&(Rt=Ni(Qe,yt,dn),yn="number"),Rt==null||Rt!==Rt)return;yn==="number"&&!Jn&&(Rt+=dn&&dn[3]||(Te.cssNumber[vr]?"":"px")),!J.clearCloneStyle&&Rt===""&&yt.indexOf("background")===0&&(li[yt]="inherit"),(!In||!("set"in In)||(Rt=In.set(Qe,Rt,jt))!==void 0)&&(Jn?li.setProperty(yt,Rt):li[yt]=Rt)}else return In&&"get"in In&&(dn=In.get(Qe,!1,jt))!==void 0?dn:li[yt]}},css:function(Qe,yt,Rt,jt){var dn,yn,In,vr=ai(yt),Jn=ma.test(yt);return Jn||(yt=Xl(vr)),In=Te.cssHooks[yt]||Te.cssHooks[vr],In&&"get"in In&&(dn=In.get(Qe,!0,Rt)),dn===void 0&&(dn=qo(Qe,yt,jt)),dn==="normal"&&yt in ju&&(dn=ju[yt]),Rt===""||Rt?(yn=parseFloat(dn),Rt===!0||isFinite(yn)?yn||0:dn):dn}}),Te.each(["height","width"],function(Qe,yt){Te.cssHooks[yt]={get:function(Rt,jt,dn){if(jt)return xl.test(Te.css(Rt,"display"))&&(!Rt.getClientRects().length||!Rt.getBoundingClientRect().width)?ao(Rt,jo,function(){return zl(Rt,yt,dn)}):zl(Rt,yt,dn)},set:function(Rt,jt,dn){var yn,In=$s(Rt),vr=!J.scrollboxSize()&&In.position==="absolute",Jn=vr||dn,li=Jn&&Te.css(Rt,"boxSizing",!1,In)==="border-box",xa=dn?tl(Rt,yt,dn,li,In):0;return li&&vr&&(xa-=Math.ceil(Rt["offset"+yt[0].toUpperCase()+yt.slice(1)]-parseFloat(In[yt])-tl(Rt,yt,"border",!1,In)-.5)),xa&&(yn=hi.exec(jt))&&(yn[3]||"px")!=="px"&&(Rt.style[yt]=jt,jt=Te.css(Rt,yt)),Pl(Rt,jt,xa)}}}),Te.cssHooks.marginLeft=wl(J.reliableMarginLeft,function(Qe,yt){if(yt)return(parseFloat(qo(Qe,"marginLeft"))||Qe.getBoundingClientRect().left-ao(Qe,{marginLeft:0},function(){return Qe.getBoundingClientRect().left}))+"px"}),Te.each({margin:"",padding:"",border:"Width"},function(Qe,yt){Te.cssHooks[Qe+yt]={expand:function(Rt){for(var jt=0,dn={},yn=typeof Rt=="string"?Rt.split(" "):[Rt];jt<4;jt++)dn[Qe+bi[jt]+yt]=yn[jt]||yn[jt-2]||yn[0];return dn}},Qe!=="margin"&&(Te.cssHooks[Qe+yt].set=Pl)}),Te.fn.extend({css:function(Qe,yt){return qn(this,function(Rt,jt,dn){var yn,In,vr={},Jn=0;if(Array.isArray(jt)){for(yn=$s(Rt),In=jt.length;Jn<In;Jn++)vr[jt[Jn]]=Te.css(Rt,jt[Jn],!1,yn);return vr}return dn!==void 0?Te.style(Rt,jt,dn):Te.css(Rt,jt)},Qe,yt,arguments.length>1)}});function Is(Qe,yt,Rt,jt,dn){return new Is.prototype.init(Qe,yt,Rt,jt,dn)}Te.Tween=Is,Is.prototype={constructor:Is,init:function(Qe,yt,Rt,jt,dn,yn){this.elem=Qe,this.prop=Rt,this.easing=dn||Te.easing._default,this.options=yt,this.start=this.now=this.cur(),this.end=jt,this.unit=yn||(Te.cssNumber[Rt]?"":"px")},cur:function(){var Qe=Is.propHooks[this.prop];return Qe&&Qe.get?Qe.get(this):Is.propHooks._default.get(this)},run:function(Qe){var yt,Rt=Is.propHooks[this.prop];return this.options.duration?this.pos=yt=Te.easing[this.easing](Qe,this.options.duration*Qe,0,1,this.options.duration):this.pos=yt=Qe,this.now=(this.end-this.start)*yt+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),Rt&&Rt.set?Rt.set(this):Is.propHooks._default.set(this),this}},Is.prototype.init.prototype=Is.prototype,Is.propHooks={_default:{get:function(Qe){var yt;return Qe.elem.nodeType!==1||Qe.elem[Qe.prop]!=null&&Qe.elem.style[Qe.prop]==null?Qe.elem[Qe.prop]:(yt=Te.css(Qe.elem,Qe.prop,""),!yt||yt==="auto"?0:yt)},set:function(Qe){Te.fx.step[Qe.prop]?Te.fx.step[Qe.prop](Qe):Qe.elem.nodeType===1&&(Te.cssHooks[Qe.prop]||Qe.elem.style[Xl(Qe.prop)]!=null)?Te.style(Qe.elem,Qe.prop,Qe.now+Qe.unit):Qe.elem[Qe.prop]=Qe.now}}},Is.propHooks.scrollTop=Is.propHooks.scrollLeft={set:function(Qe){Qe.elem.nodeType&&Qe.elem.parentNode&&(Qe.elem[Qe.prop]=Qe.now)}},Te.easing={linear:function(Qe){return Qe},swing:function(Qe){return .5-Math.cos(Qe*Math.PI)/2},_default:"swing"},Te.fx=Is.prototype.init,Te.fx.step={};var al,Mn,Ur=/^(?:toggle|show|hide)$/,Gn=/queueHooks$/;function Qr(){Mn&&(ne.hidden===!1&&e.requestAnimationFrame?e.requestAnimationFrame(Qr):e.setTimeout(Qr,Te.fx.interval),Te.fx.tick())}function qi(){return e.setTimeout(function(){al=void 0}),al=Date.now()}function ga(Qe,yt){var Rt,jt=0,dn={height:Qe};for(yt=yt?1:0;jt<4;jt+=2-yt)Rt=bi[jt],dn["margin"+Rt]=dn["padding"+Rt]=Qe;return yt&&(dn.opacity=dn.width=Qe),dn}function no(Qe,yt,Rt){for(var jt,dn=(Uo.tweeners[yt]||[]).concat(Uo.tweeners["*"]),yn=0,In=dn.length;yn<In;yn++)if(jt=dn[yn].call(Rt,yt,Qe))return jt}function mo(Qe,yt,Rt){var jt,dn,yn,In,vr,Jn,li,xa,Ri="width"in yt||"height"in yt,fa=this,oo={},ts=Qe.style,bl=Qe.nodeType&&oi(Qe),nl=An.get(Qe,"fxshow");Rt.queue||(In=Te._queueHooks(Qe,"fx"),In.unqueued==null&&(In.unqueued=0,vr=In.empty.fire,In.empty.fire=function(){In.unqueued||vr()}),In.unqueued++,fa.always(function(){fa.always(function(){In.unqueued--,Te.queue(Qe,"fx").length||In.empty.fire()})}));for(jt in yt)if(dn=yt[jt],Ur.test(dn)){if(delete yt[jt],yn=yn||dn==="toggle",dn===(bl?"hide":"show"))if(dn==="show"&&nl&&nl[jt]!==void 0)bl=!0;else continue;oo[jt]=nl&&nl[jt]||Te.style(Qe,jt)}if(Jn=!Te.isEmptyObject(yt),!(!Jn&&Te.isEmptyObject(oo))){Ri&&Qe.nodeType===1&&(Rt.overflow=[ts.overflow,ts.overflowX,ts.overflowY],li=nl&&nl.display,li==null&&(li=An.get(Qe,"display")),xa=Te.css(Qe,"display"),xa==="none"&&(li?xa=li:(Aa([Qe],!0),li=Qe.style.display||li,xa=Te.css(Qe,"display"),Aa([Qe]))),(xa==="inline"||xa==="inline-block"&&li!=null)&&Te.css(Qe,"float")==="none"&&(Jn||(fa.done(function(){ts.display=li}),li==null&&(xa=ts.display,li=xa==="none"?"":xa)),ts.display="inline-block")),Rt.overflow&&(ts.overflow="hidden",fa.always(function(){ts.overflow=Rt.overflow[0],ts.overflowX=Rt.overflow[1],ts.overflowY=Rt.overflow[2]})),Jn=!1;for(jt in oo)Jn||(nl?"hidden"in nl&&(bl=nl.hidden):nl=An.access(Qe,"fxshow",{display:li}),yn&&(nl.hidden=!bl),bl&&Aa([Qe],!0),fa.done(function(){bl||Aa([Qe]),An.remove(Qe,"fxshow");for(jt in oo)Te.style(Qe,jt,oo[jt])})),Jn=no(bl?nl[jt]:0,jt,fa),jt in nl||(nl[jt]=Jn.start,bl&&(Jn.end=Jn.start,Jn.start=0))}}function Go(Qe,yt){var Rt,jt,dn,yn,In;for(Rt in Qe)if(jt=ai(Rt),dn=yt[jt],yn=Qe[Rt],Array.isArray(yn)&&(dn=yn[1],yn=Qe[Rt]=yn[0]),Rt!==jt&&(Qe[jt]=yn,delete Qe[Rt]),In=Te.cssHooks[jt],In&&"expand"in In){yn=In.expand(yn),delete Qe[jt];for(Rt in yn)Rt in Qe||(Qe[Rt]=yn[Rt],yt[Rt]=dn)}else yt[jt]=dn}function Uo(Qe,yt,Rt){var jt,dn,yn=0,In=Uo.prefilters.length,vr=Te.Deferred().always(function(){delete Jn.elem}),Jn=function(){if(dn)return!1;for(var Ri=al||qi(),fa=Math.max(0,li.startTime+li.duration-Ri),oo=fa/li.duration||0,ts=1-oo,bl=0,nl=li.tweens.length;bl<nl;bl++)li.tweens[bl].run(ts);return vr.notifyWith(Qe,[li,ts,fa]),ts<1&&nl?fa:(nl||vr.notifyWith(Qe,[li,1,0]),vr.resolveWith(Qe,[li]),!1)},li=vr.promise({elem:Qe,props:Te.extend({},yt),opts:Te.extend(!0,{specialEasing:{},easing:Te.easing._default},Rt),originalProperties:yt,originalOptions:Rt,startTime:al||qi(),duration:Rt.duration,tweens:[],createTween:function(Ri,fa){var oo=Te.Tween(Qe,li.opts,Ri,fa,li.opts.specialEasing[Ri]||li.opts.easing);return li.tweens.push(oo),oo},stop:function(Ri){var fa=0,oo=Ri?li.tweens.length:0;if(dn)return this;for(dn=!0;fa<oo;fa++)li.tweens[fa].run(1);return Ri?(vr.notifyWith(Qe,[li,1,0]),vr.resolveWith(Qe,[li,Ri])):vr.rejectWith(Qe,[li,Ri]),this}}),xa=li.props;for(Go(xa,li.opts.specialEasing);yn<In;yn++)if(jt=Uo.prefilters[yn].call(li,Qe,xa,li.opts),jt)return fe(jt.stop)&&(Te._queueHooks(li.elem,li.opts.queue).stop=jt.stop.bind(jt)),jt;return Te.map(xa,no,li),fe(li.opts.start)&&li.opts.start.call(Qe,li),li.progress(li.opts.progress).done(li.opts.done,li.opts.complete).fail(li.opts.fail).always(li.opts.always),Te.fx.timer(Te.extend(Jn,{elem:Qe,anim:li,queue:li.opts.queue})),li}Te.Animation=Te.extend(Uo,{tweeners:{"*":[function(Qe,yt){var Rt=this.createTween(Qe,yt);return Ni(Rt.elem,Qe,hi.exec(yt),Rt),Rt}]},tweener:function(Qe,yt){fe(Qe)?(yt=Qe,Qe=["*"]):Qe=Qe.match(gn);for(var Rt,jt=0,dn=Qe.length;jt<dn;jt++)Rt=Qe[jt],Uo.tweeners[Rt]=Uo.tweeners[Rt]||[],Uo.tweeners[Rt].unshift(yt)},prefilters:[mo],prefilter:function(Qe,yt){yt?Uo.prefilters.unshift(Qe):Uo.prefilters.push(Qe)}}),Te.speed=function(Qe,yt,Rt){var jt=Qe&&typeof Qe=="object"?Te.extend({},Qe):{complete:Rt||!Rt&&yt||fe(Qe)&&Qe,duration:Qe,easing:Rt&&yt||yt&&!fe(yt)&&yt};return Te.fx.off?jt.duration=0:typeof jt.duration!="number"&&(jt.duration in Te.fx.speeds?jt.duration=Te.fx.speeds[jt.duration]:jt.duration=Te.fx.speeds._default),(jt.queue==null||jt.queue===!0)&&(jt.queue="fx"),jt.old=jt.complete,jt.complete=function(){fe(jt.old)&&jt.old.call(this),jt.queue&&Te.dequeue(this,jt.queue)},jt},Te.fn.extend({fadeTo:function(Qe,yt,Rt,jt){return this.filter(oi).css("opacity",0).show().end().animate({opacity:yt},Qe,Rt,jt)},animate:function(Qe,yt,Rt,jt){var dn=Te.isEmptyObject(Qe),yn=Te.speed(yt,Rt,jt),In=function(){var vr=Uo(this,Te.extend({},Qe),yn);(dn||An.get(this,"finish"))&&vr.stop(!0)};return In.finish=In,dn||yn.queue===!1?this.each(In):this.queue(yn.queue,In)},stop:function(Qe,yt,Rt){var jt=function(dn){var yn=dn.stop;delete dn.stop,yn(Rt)};return typeof Qe!="string"&&(Rt=yt,yt=Qe,Qe=void 0),yt&&this.queue(Qe||"fx",[]),this.each(function(){var dn=!0,yn=Qe!=null&&Qe+"queueHooks",In=Te.timers,vr=An.get(this);if(yn)vr[yn]&&vr[yn].stop&&jt(vr[yn]);else for(yn in vr)vr[yn]&&vr[yn].stop&&Gn.test(yn)&&jt(vr[yn]);for(yn=In.length;yn--;)In[yn].elem===this&&(Qe==null||In[yn].queue===Qe)&&(In[yn].anim.stop(Rt),dn=!1,In.splice(yn,1));(dn||!Rt)&&Te.dequeue(this,Qe)})},finish:function(Qe){return Qe!==!1&&(Qe=Qe||"fx"),this.each(function(){var yt,Rt=An.get(this),jt=Rt[Qe+"queue"],dn=Rt[Qe+"queueHooks"],yn=Te.timers,In=jt?jt.length:0;for(Rt.finish=!0,Te.queue(this,Qe,[]),dn&&dn.stop&&dn.stop.call(this,!0),yt=yn.length;yt--;)yn[yt].elem===this&&yn[yt].queue===Qe&&(yn[yt].anim.stop(!0),yn.splice(yt,1));for(yt=0;yt<In;yt++)jt[yt]&&jt[yt].finish&&jt[yt].finish.call(this);delete Rt.finish})}}),Te.each(["toggle","show","hide"],function(Qe,yt){var Rt=Te.fn[yt];Te.fn[yt]=function(jt,dn,yn){return jt==null||typeof jt=="boolean"?Rt.apply(this,arguments):this.animate(ga(yt,!0),jt,dn,yn)}}),Te.each({slideDown:ga("show"),slideUp:ga("hide"),slideToggle:ga("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(Qe,yt){Te.fn[Qe]=function(Rt,jt,dn){return this.animate(yt,Rt,jt,dn)}}),Te.timers=[],Te.fx.tick=function(){var Qe,yt=0,Rt=Te.timers;for(al=Date.now();yt<Rt.length;yt++)Qe=Rt[yt],!Qe()&&Rt[yt]===Qe&&Rt.splice(yt--,1);Rt.length||Te.fx.stop(),al=void 0},Te.fx.timer=function(Qe){Te.timers.push(Qe),Te.fx.start()},Te.fx.interval=13,Te.fx.start=function(){Mn||(Mn=!0,Qr())},Te.fx.stop=function(){Mn=null},Te.fx.speeds={slow:600,fast:200,_default:400},Te.fn.delay=function(Qe,yt){return Qe=Te.fx&&Te.fx.speeds[Qe]||Qe,yt=yt||"fx",this.queue(yt,function(Rt,jt){var dn=e.setTimeout(Rt,Qe);jt.stop=function(){e.clearTimeout(dn)}})},function(){var Qe=ne.createElement("input"),yt=ne.createElement("select"),Rt=yt.appendChild(ne.createElement("option"));Qe.type="checkbox",J.checkOn=Qe.value!=="",J.optSelected=Rt.selected,Qe=ne.createElement("input"),Qe.value="t",Qe.type="radio",J.radioValue=Qe.value==="t"}();var Ns,jl=Te.expr.attrHandle;Te.fn.extend({attr:function(Qe,yt){return qn(this,Te.attr,Qe,yt,arguments.length>1)},removeAttr:function(Qe){return this.each(function(){Te.removeAttr(this,Qe)})}}),Te.extend({attr:function(Qe,yt,Rt){var jt,dn,yn=Qe.nodeType;if(!(yn===3||yn===8||yn===2)){if(typeof Qe.getAttribute>"u")return Te.prop(Qe,yt,Rt);if((yn!==1||!Te.isXMLDoc(Qe))&&(dn=Te.attrHooks[yt.toLowerCase()]||(Te.expr.match.bool.test(yt)?Ns:void 0)),Rt!==void 0){if(Rt===null){Te.removeAttr(Qe,yt);return}return dn&&"set"in dn&&(jt=dn.set(Qe,Rt,yt))!==void 0?jt:(Qe.setAttribute(yt,Rt+""),Rt)}return dn&&"get"in dn&&(jt=dn.get(Qe,yt))!==null?jt:(jt=Te.find.attr(Qe,yt),jt??void 0)}},attrHooks:{type:{set:function(Qe,yt){if(!J.radioValue&&yt==="radio"&&ie(Qe,"input")){var Rt=Qe.value;return Qe.setAttribute("type",yt),Rt&&(Qe.value=Rt),yt}}}},removeAttr:function(Qe,yt){var Rt,jt=0,dn=yt&&yt.match(gn);if(dn&&Qe.nodeType===1)for(;Rt=dn[jt++];)Qe.removeAttribute(Rt)}}),Ns={set:function(Qe,yt,Rt){return yt===!1?Te.removeAttr(Qe,Rt):Qe.setAttribute(Rt,Rt),Rt}},Te.each(Te.expr.match.bool.source.match(/\w+/g),function(Qe,yt){var Rt=jl[yt]||Te.find.attr;jl[yt]=function(jt,dn,yn){var In,vr,Jn=dn.toLowerCase();return yn||(vr=jl[Jn],jl[Jn]=In,In=Rt(jt,dn,yn)!=null?Jn:null,jl[Jn]=vr),In}});var Bl=/^(?:input|select|textarea|button)$/i,Jl=/^(?:a|area)$/i;Te.fn.extend({prop:function(Qe,yt){return qn(this,Te.prop,Qe,yt,arguments.length>1)},removeProp:function(Qe){return this.each(function(){delete this[Te.propFix[Qe]||Qe]})}}),Te.extend({prop:function(Qe,yt,Rt){var jt,dn,yn=Qe.nodeType;if(!(yn===3||yn===8||yn===2))return(yn!==1||!Te.isXMLDoc(Qe))&&(yt=Te.propFix[yt]||yt,dn=Te.propHooks[yt]),Rt!==void 0?dn&&"set"in dn&&(jt=dn.set(Qe,Rt,yt))!==void 0?jt:Qe[yt]=Rt:dn&&"get"in dn&&(jt=dn.get(Qe,yt))!==null?jt:Qe[yt]},propHooks:{tabIndex:{get:function(Qe){var yt=Te.find.attr(Qe,"tabindex");return yt?parseInt(yt,10):Bl.test(Qe.nodeName)||Jl.test(Qe.nodeName)&&Qe.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),J.optSelected||(Te.propHooks.selected={get:function(Qe){var yt=Qe.parentNode;return yt&&yt.parentNode&&yt.parentNode.selectedIndex,null},set:function(Qe){var yt=Qe.parentNode;yt&&(yt.selectedIndex,yt.parentNode&&yt.parentNode.selectedIndex)}}),Te.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){Te.propFix[this.toLowerCase()]=this});function mu(Qe){var yt=Qe.match(gn)||[];return yt.join(" ")}function Ol(Qe){return Qe.getAttribute&&Qe.getAttribute("class")||""}function bu(Qe){return Array.isArray(Qe)?Qe:typeof Qe=="string"?Qe.match(gn)||[]:[]}Te.fn.extend({addClass:function(Qe){var yt,Rt,jt,dn,yn,In;return fe(Qe)?this.each(function(vr){Te(this).addClass(Qe.call(this,vr,Ol(this)))}):(yt=bu(Qe),yt.length?this.each(function(){if(jt=Ol(this),Rt=this.nodeType===1&&" "+mu(jt)+" ",Rt){for(yn=0;yn<yt.length;yn++)dn=yt[yn],Rt.indexOf(" "+dn+" ")<0&&(Rt+=dn+" ");In=mu(Rt),jt!==In&&this.setAttribute("class",In)}}):this)},removeClass:function(Qe){var yt,Rt,jt,dn,yn,In;return fe(Qe)?this.each(function(vr){Te(this).removeClass(Qe.call(this,vr,Ol(this)))}):arguments.length?(yt=bu(Qe),yt.length?this.each(function(){if(jt=Ol(this),Rt=this.nodeType===1&&" "+mu(jt)+" ",Rt){for(yn=0;yn<yt.length;yn++)for(dn=yt[yn];Rt.indexOf(" "+dn+" ")>-1;)Rt=Rt.replace(" "+dn+" "," ");In=mu(Rt),jt!==In&&this.setAttribute("class",In)}}):this):this.attr("class","")},toggleClass:function(Qe,yt){var Rt,jt,dn,yn,In=typeof Qe,vr=In==="string"||Array.isArray(Qe);return fe(Qe)?this.each(function(Jn){Te(this).toggleClass(Qe.call(this,Jn,Ol(this),yt),yt)}):typeof yt=="boolean"&&vr?yt?this.addClass(Qe):this.removeClass(Qe):(Rt=bu(Qe),this.each(function(){if(vr)for(yn=Te(this),dn=0;dn<Rt.length;dn++)jt=Rt[dn],yn.hasClass(jt)?yn.removeClass(jt):yn.addClass(jt);else(Qe===void 0||In==="boolean")&&(jt=Ol(this),jt&&An.set(this,"__className__",jt),this.setAttribute&&this.setAttribute("class",jt||Qe===!1?"":An.get(this,"__className__")||""))}))},hasClass:function(Qe){var yt,Rt,jt=0;for(yt=" "+Qe+" ";Rt=this[jt++];)if(Rt.nodeType===1&&(" "+mu(Ol(Rt))+" ").indexOf(yt)>-1)return!0;return!1}});var Bu=/\r/g;Te.fn.extend({val:function(Qe){var yt,Rt,jt,dn=this[0];return arguments.length?(jt=fe(Qe),this.each(function(yn){var In;this.nodeType===1&&(jt?In=Qe.call(this,yn,Te(this).val()):In=Qe,In==null?In="":typeof In=="number"?In+="":Array.isArray(In)&&(In=Te.map(In,function(vr){return vr==null?"":vr+""})),yt=Te.valHooks[this.type]||Te.valHooks[this.nodeName.toLowerCase()],(!yt||!("set"in yt)||yt.set(this,In,"value")===void 0)&&(this.value=In))})):dn?(yt=Te.valHooks[dn.type]||Te.valHooks[dn.nodeName.toLowerCase()],yt&&"get"in yt&&(Rt=yt.get(dn,"value"))!==void 0?Rt:(Rt=dn.value,typeof Rt=="string"?Rt.replace(Bu,""):Rt??"")):void 0}}),Te.extend({valHooks:{option:{get:function(Qe){var yt=Te.find.attr(Qe,"value");return yt??mu(Te.text(Qe))}},select:{get:function(Qe){var yt,Rt,jt,dn=Qe.options,yn=Qe.selectedIndex,In=Qe.type==="select-one",vr=In?null:[],Jn=In?yn+1:dn.length;for(yn<0?jt=Jn:jt=In?yn:0;jt<Jn;jt++)if(Rt=dn[jt],(Rt.selected||jt===yn)&&!Rt.disabled&&(!Rt.parentNode.disabled||!ie(Rt.parentNode,"optgroup"))){if(yt=Te(Rt).val(),In)return yt;vr.push(yt)}return vr},set:function(Qe,yt){for(var Rt,jt,dn=Qe.options,yn=Te.makeArray(yt),In=dn.length;In--;)jt=dn[In],(jt.selected=Te.inArray(Te.valHooks.option.get(jt),yn)>-1)&&(Rt=!0);return Rt||(Qe.selectedIndex=-1),yn}}}}),Te.each(["radio","checkbox"],function(){Te.valHooks[this]={set:function(Qe,yt){if(Array.isArray(yt))return Qe.checked=Te.inArray(Te(Qe).val(),yt)>-1}},J.checkOn||(Te.valHooks[this].get=function(Qe){return Qe.getAttribute("value")===null?"on":Qe.value})});var hl=e.location,vu={guid:Date.now()},Ku=/\?/;Te.parseXML=function(Qe){var yt,Rt;if(!Qe||typeof Qe!="string")return null;try{yt=new e.DOMParser().parseFromString(Qe,"text/xml")}catch{}return Rt=yt&&yt.getElementsByTagName("parsererror")[0],(!yt||Rt)&&Te.error("Invalid XML: "+(Rt?Te.map(Rt.childNodes,function(jt){return jt.textContent}).join(`
- `):Qe)),yt};var Ul=/^(?:focusinfocus|focusoutblur)$/,ad=function(Qe){Qe.stopPropagation()};Te.extend(Te.event,{trigger:function(Qe,yt,Rt,jt){var dn,yn,In,vr,Jn,li,xa,Ri,fa=[Rt||ne],oo=L.call(Qe,"type")?Qe.type:Qe,ts=L.call(Qe,"namespace")?Qe.namespace.split("."):[];if(yn=Ri=In=Rt=Rt||ne,!(Rt.nodeType===3||Rt.nodeType===8)&&!Ul.test(oo+Te.event.triggered)&&(oo.indexOf(".")>-1&&(ts=oo.split("."),oo=ts.shift(),ts.sort()),Jn=oo.indexOf(":")<0&&"on"+oo,Qe=Qe[Te.expando]?Qe:new Te.Event(oo,typeof Qe=="object"&&Qe),Qe.isTrigger=jt?2:3,Qe.namespace=ts.join("."),Qe.rnamespace=Qe.namespace?new RegExp("(^|\\.)"+ts.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,Qe.result=void 0,Qe.target||(Qe.target=Rt),yt=yt==null?[Qe]:Te.makeArray(yt,[Qe]),xa=Te.event.special[oo]||{},!(!jt&&xa.trigger&&xa.trigger.apply(Rt,yt)===!1))){if(!jt&&!xa.noBubble&&!ve(Rt)){for(vr=xa.delegateType||oo,Ul.test(vr+oo)||(yn=yn.parentNode);yn;yn=yn.parentNode)fa.push(yn),In=yn;In===(Rt.ownerDocument||ne)&&fa.push(In.defaultView||In.parentWindow||e)}for(dn=0;(yn=fa[dn++])&&!Qe.isPropagationStopped();)Ri=yn,Qe.type=dn>1?vr:xa.bindType||oo,li=(An.get(yn,"events")||Object.create(null))[Qe.type]&&An.get(yn,"handle"),li&&li.apply(yn,yt),li=Jn&&yn[Jn],li&&li.apply&&Ia(yn)&&(Qe.result=li.apply(yn,yt),Qe.result===!1&&Qe.preventDefault());return Qe.type=oo,!jt&&!Qe.isDefaultPrevented()&&(!xa._default||xa._default.apply(fa.pop(),yt)===!1)&&Ia(Rt)&&Jn&&fe(Rt[oo])&&!ve(Rt)&&(In=Rt[Jn],In&&(Rt[Jn]=null),Te.event.triggered=oo,Qe.isPropagationStopped()&&Ri.addEventListener(oo,ad),Rt[oo](),Qe.isPropagationStopped()&&Ri.removeEventListener(oo,ad),Te.event.triggered=void 0,In&&(Rt[Jn]=In)),Qe.result}},simulate:function(Qe,yt,Rt){var jt=Te.extend(new Te.Event,Rt,{type:Qe,isSimulated:!0});Te.event.trigger(jt,null,yt)}}),Te.fn.extend({trigger:function(Qe,yt){return this.each(function(){Te.event.trigger(Qe,yt,this)})},triggerHandler:function(Qe,yt){var Rt=this[0];if(Rt)return Te.event.trigger(Qe,yt,Rt,!0)}});var jc=/\[\]$/,js=/\r?\n/g,co=/^(?:submit|button|image|reset|file)$/i,Vl=/^(?:input|select|textarea|keygen)/i;function Gc(Qe,yt,Rt,jt){var dn;if(Array.isArray(yt))Te.each(yt,function(yn,In){Rt||jc.test(Qe)?jt(Qe,In):Gc(Qe+"["+(typeof In=="object"&&In!=null?yn:"")+"]",In,Rt,jt)});else if(!Rt&&Ve(yt)==="object")for(dn in yt)Gc(Qe+"["+dn+"]",yt[dn],Rt,jt);else jt(Qe,yt)}Te.param=function(Qe,yt){var Rt,jt=[],dn=function(yn,In){var vr=fe(In)?In():In;jt[jt.length]=encodeURIComponent(yn)+"="+encodeURIComponent(vr??"")};if(Qe==null)return"";if(Array.isArray(Qe)||Qe.jquery&&!Te.isPlainObject(Qe))Te.each(Qe,function(){dn(this.name,this.value)});else for(Rt in Qe)Gc(Rt,Qe[Rt],yt,dn);return jt.join("&")},Te.fn.extend({serialize:function(){return Te.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var Qe=Te.prop(this,"elements");return Qe?Te.makeArray(Qe):this}).filter(function(){var Qe=this.type;return this.name&&!Te(this).is(":disabled")&&Vl.test(this.nodeName)&&!co.test(Qe)&&(this.checked||!Ja.test(Qe))}).map(function(Qe,yt){var Rt=Te(this).val();return Rt==null?null:Array.isArray(Rt)?Te.map(Rt,function(jt){return{name:yt.name,value:jt.replace(js,`\r
- `)}}):{name:yt.name,value:Rt.replace(js,`\r
- `)}}).get()}});var yd=/%20/g,Ql=/#.*$/,Ll=/([?&])_=[^&]*/,Au=/^(.*?):[ \t]*([^\r\n]*)$/mg,jd=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Wu=/^(?:GET|HEAD)$/,ud=/^\/\//,Xc={},yi={},mc="*/".concat("*"),Su=ne.createElement("a");Su.href=hl.href;function Yh(Qe){return function(yt,Rt){typeof yt!="string"&&(Rt=yt,yt="*");var jt,dn=0,yn=yt.toLowerCase().match(gn)||[];if(fe(Rt))for(;jt=yn[dn++];)jt[0]==="+"?(jt=jt.slice(1)||"*",(Qe[jt]=Qe[jt]||[]).unshift(Rt)):(Qe[jt]=Qe[jt]||[]).push(Rt)}}function ka(Qe,yt,Rt,jt){var dn={},yn=Qe===yi;function In(vr){var Jn;return dn[vr]=!0,Te.each(Qe[vr]||[],function(li,xa){var Ri=xa(yt,Rt,jt);if(typeof Ri=="string"&&!yn&&!dn[Ri])return yt.dataTypes.unshift(Ri),In(Ri),!1;if(yn)return!(Jn=Ri)}),Jn}return In(yt.dataTypes[0])||!dn["*"]&&In("*")}function pl(Qe,yt){var Rt,jt,dn=Te.ajaxSettings.flatOptions||{};for(Rt in yt)yt[Rt]!==void 0&&((dn[Rt]?Qe:jt||(jt={}))[Rt]=yt[Rt]);return jt&&Te.extend(!0,Qe,jt),Qe}function Il(Qe,yt,Rt){for(var jt,dn,yn,In,vr=Qe.contents,Jn=Qe.dataTypes;Jn[0]==="*";)Jn.shift(),jt===void 0&&(jt=Qe.mimeType||yt.getResponseHeader("Content-Type"));if(jt){for(dn in vr)if(vr[dn]&&vr[dn].test(jt)){Jn.unshift(dn);break}}if(Jn[0]in Rt)yn=Jn[0];else{for(dn in Rt){if(!Jn[0]||Qe.converters[dn+" "+Jn[0]]){yn=dn;break}In||(In=dn)}yn=yn||In}if(yn)return yn!==Jn[0]&&Jn.unshift(yn),Rt[yn]}function Ss(Qe,yt,Rt,jt){var dn,yn,In,vr,Jn,li={},xa=Qe.dataTypes.slice();if(xa[1])for(In in Qe.converters)li[In.toLowerCase()]=Qe.converters[In];for(yn=xa.shift();yn;)if(Qe.responseFields[yn]&&(Rt[Qe.responseFields[yn]]=yt),!Jn&&jt&&Qe.dataFilter&&(yt=Qe.dataFilter(yt,Qe.dataType)),Jn=yn,yn=xa.shift(),yn){if(yn==="*")yn=Jn;else if(Jn!=="*"&&Jn!==yn){if(In=li[Jn+" "+yn]||li["* "+yn],!In){for(dn in li)if(vr=dn.split(" "),vr[1]===yn&&(In=li[Jn+" "+vr[0]]||li["* "+vr[0]],In)){In===!0?In=li[dn]:li[dn]!==!0&&(yn=vr[0],xa.unshift(vr[1]));break}}if(In!==!0)if(In&&Qe.throws)yt=In(yt);else try{yt=In(yt)}catch(Ri){return{state:"parsererror",error:In?Ri:"No conversion from "+Jn+" to "+yn}}}}return{state:"success",data:yt}}Te.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:hl.href,type:"GET",isLocal:jd.test(hl.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":mc,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":Te.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(Qe,yt){return yt?pl(pl(Qe,Te.ajaxSettings),yt):pl(Te.ajaxSettings,Qe)},ajaxPrefilter:Yh(Xc),ajaxTransport:Yh(yi),ajax:function(Qe,yt){typeof Qe=="object"&&(yt=Qe,Qe=void 0),yt=yt||{};var Rt,jt,dn,yn,In,vr,Jn,li,xa,Ri,fa=Te.ajaxSetup({},yt),oo=fa.context||fa,ts=fa.context&&(oo.nodeType||oo.jquery)?Te(oo):Te.event,bl=Te.Deferred(),nl=Te.Callbacks("once memory"),Fs=fa.statusCode||{},eu={},Gs={},As="canceled",yl={readyState:0,getResponseHeader:function(vl){var du;if(Jn){if(!yn)for(yn={};du=Au.exec(dn);)yn[du[1].toLowerCase()+" "]=(yn[du[1].toLowerCase()+" "]||[]).concat(du[2]);du=yn[vl.toLowerCase()+" "]}return du==null?null:du.join(", ")},getAllResponseHeaders:function(){return Jn?dn:null},setRequestHeader:function(vl,du){return Jn==null&&(vl=Gs[vl.toLowerCase()]=Gs[vl.toLowerCase()]||vl,eu[vl]=du),this},overrideMimeType:function(vl){return Jn==null&&(fa.mimeType=vl),this},statusCode:function(vl){var du;if(vl)if(Jn)yl.always(vl[yl.status]);else for(du in vl)Fs[du]=[Fs[du],vl[du]];return this},abort:function(vl){var du=vl||As;return Rt&&Rt.abort(du),Lc(0,du),this}};if(bl.promise(yl),fa.url=((Qe||fa.url||hl.href)+"").replace(ud,hl.protocol+"//"),fa.type=yt.method||yt.type||fa.method||fa.type,fa.dataTypes=(fa.dataType||"*").toLowerCase().match(gn)||[""],fa.crossDomain==null){vr=ne.createElement("a");try{vr.href=fa.url,vr.href=vr.href,fa.crossDomain=Su.protocol+"//"+Su.host!=vr.protocol+"//"+vr.host}catch{fa.crossDomain=!0}}if(fa.data&&fa.processData&&typeof fa.data!="string"&&(fa.data=Te.param(fa.data,fa.traditional)),ka(Xc,fa,yt,yl),Jn)return yl;li=Te.event&&fa.global,li&&Te.active++===0&&Te.event.trigger("ajaxStart"),fa.type=fa.type.toUpperCase(),fa.hasContent=!Wu.test(fa.type),jt=fa.url.replace(Ql,""),fa.hasContent?fa.data&&fa.processData&&(fa.contentType||"").indexOf("application/x-www-form-urlencoded")===0&&(fa.data=fa.data.replace(yd,"+")):(Ri=fa.url.slice(jt.length),fa.data&&(fa.processData||typeof fa.data=="string")&&(jt+=(Ku.test(jt)?"&":"?")+fa.data,delete fa.data),fa.cache===!1&&(jt=jt.replace(Ll,"$1"),Ri=(Ku.test(jt)?"&":"?")+"_="+vu.guid+++Ri),fa.url=jt+Ri),fa.ifModified&&(Te.lastModified[jt]&&yl.setRequestHeader("If-Modified-Since",Te.lastModified[jt]),Te.etag[jt]&&yl.setRequestHeader("If-None-Match",Te.etag[jt])),(fa.data&&fa.hasContent&&fa.contentType!==!1||yt.contentType)&&yl.setRequestHeader("Content-Type",fa.contentType),yl.setRequestHeader("Accept",fa.dataTypes[0]&&fa.accepts[fa.dataTypes[0]]?fa.accepts[fa.dataTypes[0]]+(fa.dataTypes[0]!=="*"?", "+mc+"; q=0.01":""):fa.accepts["*"]);for(xa in fa.headers)yl.setRequestHeader(xa,fa.headers[xa]);if(fa.beforeSend&&(fa.beforeSend.call(oo,yl,fa)===!1||Jn))return yl.abort();if(As="abort",nl.add(fa.complete),yl.done(fa.success),yl.fail(fa.error),Rt=ka(yi,fa,yt,yl),!Rt)Lc(-1,"No Transport");else{if(yl.readyState=1,li&&ts.trigger("ajaxSend",[yl,fa]),Jn)return yl;fa.async&&fa.timeout>0&&(In=e.setTimeout(function(){yl.abort("timeout")},fa.timeout));try{Jn=!1,Rt.send(eu,Lc)}catch(vl){if(Jn)throw vl;Lc(-1,vl)}}function Lc(vl,du,ac,Xu){var Ju,Vu,Nl,$l,hu,Qu=du;Jn||(Jn=!0,In&&e.clearTimeout(In),Rt=void 0,dn=Xu||"",yl.readyState=vl>0?4:0,Ju=vl>=200&&vl<300||vl===304,ac&&($l=Il(fa,yl,ac)),!Ju&&Te.inArray("script",fa.dataTypes)>-1&&Te.inArray("json",fa.dataTypes)<0&&(fa.converters["text script"]=function(){}),$l=Ss(fa,$l,yl,Ju),Ju?(fa.ifModified&&(hu=yl.getResponseHeader("Last-Modified"),hu&&(Te.lastModified[jt]=hu),hu=yl.getResponseHeader("etag"),hu&&(Te.etag[jt]=hu)),vl===204||fa.type==="HEAD"?Qu="nocontent":vl===304?Qu="notmodified":(Qu=$l.state,Vu=$l.data,Nl=$l.error,Ju=!Nl)):(Nl=Qu,(vl||!Qu)&&(Qu="error",vl<0&&(vl=0))),yl.status=vl,yl.statusText=(du||Qu)+"",Ju?bl.resolveWith(oo,[Vu,Qu,yl]):bl.rejectWith(oo,[yl,Qu,Nl]),yl.statusCode(Fs),Fs=void 0,li&&ts.trigger(Ju?"ajaxSuccess":"ajaxError",[yl,fa,Ju?Vu:Nl]),nl.fireWith(oo,[yl,Qu]),li&&(ts.trigger("ajaxComplete",[yl,fa]),--Te.active||Te.event.trigger("ajaxStop")))}return yl},getJSON:function(Qe,yt,Rt){return Te.get(Qe,yt,Rt,"json")},getScript:function(Qe,yt){return Te.get(Qe,void 0,yt,"script")}}),Te.each(["get","post"],function(Qe,yt){Te[yt]=function(Rt,jt,dn,yn){return fe(jt)&&(yn=yn||dn,dn=jt,jt=void 0),Te.ajax(Te.extend({url:Rt,type:yt,dataType:yn,data:jt,success:dn},Te.isPlainObject(Rt)&&Rt))}}),Te.ajaxPrefilter(function(Qe){var yt;for(yt in Qe.headers)yt.toLowerCase()==="content-type"&&(Qe.contentType=Qe.headers[yt]||"")}),Te._evalUrl=function(Qe,yt,Rt){return Te.ajax({url:Qe,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(jt){Te.globalEval(jt,yt,Rt)}})},Te.fn.extend({wrapAll:function(Qe){var yt;return this[0]&&(fe(Qe)&&(Qe=Qe.call(this[0])),yt=Te(Qe,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&yt.insertBefore(this[0]),yt.map(function(){for(var Rt=this;Rt.firstElementChild;)Rt=Rt.firstElementChild;return Rt}).append(this)),this},wrapInner:function(Qe){return fe(Qe)?this.each(function(yt){Te(this).wrapInner(Qe.call(this,yt))}):this.each(function(){var yt=Te(this),Rt=yt.contents();Rt.length?Rt.wrapAll(Qe):yt.append(Qe)})},wrap:function(Qe){var yt=fe(Qe);return this.each(function(Rt){Te(this).wrapAll(yt?Qe.call(this,Rt):Qe)})},unwrap:function(Qe){return this.parent(Qe).not("body").each(function(){Te(this).replaceWith(this.childNodes)}),this}}),Te.expr.pseudos.hidden=function(Qe){return!Te.expr.pseudos.visible(Qe)},Te.expr.pseudos.visible=function(Qe){return!!(Qe.offsetWidth||Qe.offsetHeight||Qe.getClientRects().length)},Te.ajaxSettings.xhr=function(){try{return new e.XMLHttpRequest}catch{}};var Vo={0:200,1223:204},iu=Te.ajaxSettings.xhr();J.cors=!!iu&&"withCredentials"in iu,J.ajax=iu=!!iu,Te.ajaxTransport(function(Qe){var yt,Rt;if(J.cors||iu&&!Qe.crossDomain)return{send:function(jt,dn){var yn,In=Qe.xhr();if(In.open(Qe.type,Qe.url,Qe.async,Qe.username,Qe.password),Qe.xhrFields)for(yn in Qe.xhrFields)In[yn]=Qe.xhrFields[yn];Qe.mimeType&&In.overrideMimeType&&In.overrideMimeType(Qe.mimeType),!Qe.crossDomain&&!jt["X-Requested-With"]&&(jt["X-Requested-With"]="XMLHttpRequest");for(yn in jt)In.setRequestHeader(yn,jt[yn]);yt=function(vr){return function(){yt&&(yt=Rt=In.onload=In.onerror=In.onabort=In.ontimeout=In.onreadystatechange=null,vr==="abort"?In.abort():vr==="error"?typeof In.status!="number"?dn(0,"error"):dn(In.status,In.statusText):dn(Vo[In.status]||In.status,In.statusText,(In.responseType||"text")!=="text"||typeof In.responseText!="string"?{binary:In.response}:{text:In.responseText},In.getAllResponseHeaders()))}},In.onload=yt(),Rt=In.onerror=In.ontimeout=yt("error"),In.onabort!==void 0?In.onabort=Rt:In.onreadystatechange=function(){In.readyState===4&&e.setTimeout(function(){yt&&Rt()})},yt=yt("abort");try{In.send(Qe.hasContent&&Qe.data||null)}catch(vr){if(yt)throw vr}},abort:function(){yt&&yt()}}}),Te.ajaxPrefilter(function(Qe){Qe.crossDomain&&(Qe.contents.script=!1)}),Te.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(Qe){return Te.globalEval(Qe),Qe}}}),Te.ajaxPrefilter("script",function(Qe){Qe.cache===void 0&&(Qe.cache=!1),Qe.crossDomain&&(Qe.type="GET")}),Te.ajaxTransport("script",function(Qe){if(Qe.crossDomain||Qe.scriptAttrs){var yt,Rt;return{send:function(jt,dn){yt=Te("<script>").attr(Qe.scriptAttrs||{}).prop({charset:Qe.scriptCharset,src:Qe.url}).on("load error",Rt=function(yn){yt.remove(),Rt=null,yn&&dn(yn.type==="error"?404:200,yn.type)}),ne.head.appendChild(yt[0])},abort:function(){Rt&&Rt()}}}});var Tu=[],wt=/(=)\?(?=&|$)|\?\?/;Te.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var Qe=Tu.pop()||Te.expando+"_"+vu.guid++;return this[Qe]=!0,Qe}}),Te.ajaxPrefilter("json jsonp",function(Qe,yt,Rt){var jt,dn,yn,In=Qe.jsonp!==!1&&(wt.test(Qe.url)?"url":typeof Qe.data=="string"&&(Qe.contentType||"").indexOf("application/x-www-form-urlencoded")===0&&wt.test(Qe.data)&&"data");if(In||Qe.dataTypes[0]==="jsonp")return jt=Qe.jsonpCallback=fe(Qe.jsonpCallback)?Qe.jsonpCallback():Qe.jsonpCallback,In?Qe[In]=Qe[In].replace(wt,"$1"+jt):Qe.jsonp!==!1&&(Qe.url+=(Ku.test(Qe.url)?"&":"?")+Qe.jsonp+"="+jt),Qe.converters["script json"]=function(){return yn||Te.error(jt+" was not called"),yn[0]},Qe.dataTypes[0]="json",dn=e[jt],e[jt]=function(){yn=arguments},Rt.always(function(){dn===void 0?Te(e).removeProp(jt):e[jt]=dn,Qe[jt]&&(Qe.jsonpCallback=yt.jsonpCallback,Tu.push(jt)),yn&&fe(dn)&&dn(yn[0]),yn=dn=void 0}),"script"}),J.createHTMLDocument=function(){var Qe=ne.implementation.createHTMLDocument("").body;return Qe.innerHTML="<form></form><form></form>",Qe.childNodes.length===2}(),Te.parseHTML=function(Qe,yt,Rt){if(typeof Qe!="string")return[];typeof yt=="boolean"&&(Rt=yt,yt=!1);var jt,dn,yn;return yt||(J.createHTMLDocument?(yt=ne.implementation.createHTMLDocument(""),jt=yt.createElement("base"),jt.href=ne.location.href,yt.head.appendChild(jt)):yt=ne),dn=Rn.exec(Qe),yn=!Rt&&[],dn?[yt.createElement(dn[1])]:(dn=zr([Qe],yt,yn),yn&&yn.length&&Te(yn).remove(),Te.merge([],dn.childNodes))},Te.fn.load=function(Qe,yt,Rt){var jt,dn,yn,In=this,vr=Qe.indexOf(" ");return vr>-1&&(jt=mu(Qe.slice(vr)),Qe=Qe.slice(0,vr)),fe(yt)?(Rt=yt,yt=void 0):yt&&typeof yt=="object"&&(dn="POST"),In.length>0&&Te.ajax({url:Qe,type:dn||"GET",dataType:"html",data:yt}).done(function(Jn){yn=arguments,In.html(jt?Te("<div>").append(Te.parseHTML(Jn)).find(jt):Jn)}).always(Rt&&function(Jn,li){In.each(function(){Rt.apply(this,yn||[Jn.responseText,li,Jn])})}),this},Te.expr.pseudos.animated=function(Qe){return Te.grep(Te.timers,function(yt){return Qe===yt.elem}).length},Te.offset={setOffset:function(Qe,yt,Rt){var jt,dn,yn,In,vr,Jn,li,xa=Te.css(Qe,"position"),Ri=Te(Qe),fa={};xa==="static"&&(Qe.style.position="relative"),vr=Ri.offset(),yn=Te.css(Qe,"top"),Jn=Te.css(Qe,"left"),li=(xa==="absolute"||xa==="fixed")&&(yn+Jn).indexOf("auto")>-1,li?(jt=Ri.position(),In=jt.top,dn=jt.left):(In=parseFloat(yn)||0,dn=parseFloat(Jn)||0),fe(yt)&&(yt=yt.call(Qe,Rt,Te.extend({},vr))),yt.top!=null&&(fa.top=yt.top-vr.top+In),yt.left!=null&&(fa.left=yt.left-vr.left+dn),"using"in yt?yt.using.call(Qe,fa):Ri.css(fa)}},Te.fn.extend({offset:function(Qe){if(arguments.length)return Qe===void 0?this:this.each(function(dn){Te.offset.setOffset(this,Qe,dn)});var yt,Rt,jt=this[0];if(jt)return jt.getClientRects().length?(yt=jt.getBoundingClientRect(),Rt=jt.ownerDocument.defaultView,{top:yt.top+Rt.pageYOffset,left:yt.left+Rt.pageXOffset}):{top:0,left:0}},position:function(){if(this[0]){var Qe,yt,Rt,jt=this[0],dn={top:0,left:0};if(Te.css(jt,"position")==="fixed")yt=jt.getBoundingClientRect();else{for(yt=this.offset(),Rt=jt.ownerDocument,Qe=jt.offsetParent||Rt.documentElement;Qe&&(Qe===Rt.body||Qe===Rt.documentElement)&&Te.css(Qe,"position")==="static";)Qe=Qe.parentNode;Qe&&Qe!==jt&&Qe.nodeType===1&&(dn=Te(Qe).offset(),dn.top+=Te.css(Qe,"borderTopWidth",!0),dn.left+=Te.css(Qe,"borderLeftWidth",!0))}return{top:yt.top-dn.top-Te.css(jt,"marginTop",!0),left:yt.left-dn.left-Te.css(jt,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var Qe=this.offsetParent;Qe&&Te.css(Qe,"position")==="static";)Qe=Qe.offsetParent;return Qe||Ra})}}),Te.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(Qe,yt){var Rt=yt==="pageYOffset";Te.fn[Qe]=function(jt){return qn(this,function(dn,yn,In){var vr;if(ve(dn)?vr=dn:dn.nodeType===9&&(vr=dn.defaultView),In===void 0)return vr?vr[yt]:dn[yn];vr?vr.scrollTo(Rt?vr.pageXOffset:In,Rt?In:vr.pageYOffset):dn[yn]=In},Qe,jt,arguments.length)}}),Te.each(["top","left"],function(Qe,yt){Te.cssHooks[yt]=wl(J.pixelPosition,function(Rt,jt){if(jt)return jt=qo(Rt,yt),Wo.test(jt)?Te(Rt).position()[yt]+"px":jt})}),Te.each({Height:"height",Width:"width"},function(Qe,yt){Te.each({padding:"inner"+Qe,content:yt,"":"outer"+Qe},function(Rt,jt){Te.fn[jt]=function(dn,yn){var In=arguments.length&&(Rt||typeof dn!="boolean"),vr=Rt||(dn===!0||yn===!0?"margin":"border");return qn(this,function(Jn,li,xa){var Ri;return ve(Jn)?jt.indexOf("outer")===0?Jn["inner"+Qe]:Jn.document.documentElement["client"+Qe]:Jn.nodeType===9?(Ri=Jn.documentElement,Math.max(Jn.body["scroll"+Qe],Ri["scroll"+Qe],Jn.body["offset"+Qe],Ri["offset"+Qe],Ri["client"+Qe])):xa===void 0?Te.css(Jn,li,vr):Te.style(Jn,li,xa,vr)},yt,In?dn:void 0,In)}})}),Te.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(Qe,yt){Te.fn[yt]=function(Rt){return this.on(yt,Rt)}}),Te.fn.extend({bind:function(Qe,yt,Rt){return this.on(Qe,null,yt,Rt)},unbind:function(Qe,yt){return this.off(Qe,null,yt)},delegate:function(Qe,yt,Rt,jt){return this.on(yt,Qe,Rt,jt)},undelegate:function(Qe,yt,Rt){return arguments.length===1?this.off(Qe,"**"):this.off(yt,Qe||"**",Rt)},hover:function(Qe,yt){return this.on("mouseenter",Qe).on("mouseleave",yt||Qe)}}),Te.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(Qe,yt){Te.fn[yt]=function(Rt,jt){return arguments.length>0?this.on(yt,null,Rt,jt):this.trigger(yt)}});var qt=/^[\s\uFEFF\xA0]+|([^\s\uFEFF\xA0])[\s\uFEFF\xA0]+$/g;Te.proxy=function(Qe,yt){var Rt,jt,dn;if(typeof yt=="string"&&(Rt=Qe[yt],yt=Qe,Qe=Rt),!!fe(Qe))return jt=c.call(arguments,2),dn=function(){return Qe.apply(yt||this,jt.concat(c.call(arguments)))},dn.guid=Qe.guid=Qe.guid||Te.guid++,dn},Te.holdReady=function(Qe){Qe?Te.readyWait++:Te.ready(!0)},Te.isArray=Array.isArray,Te.parseJSON=JSON.parse,Te.nodeName=ie,Te.isFunction=fe,Te.isWindow=ve,Te.camelCase=ai,Te.type=Ve,Te.now=Date.now,Te.isNumeric=function(Qe){var yt=Te.type(Qe);return(yt==="number"||yt==="string")&&!isNaN(Qe-parseFloat(Qe))},Te.trim=function(Qe){return Qe==null?"":(Qe+"").replace(qt,"$1")};var Cn=e.jQuery,Pn=e.$;return Te.noConflict=function(Qe){return e.$===Te&&(e.$=Pn),Qe&&e.jQuery===Te&&(e.jQuery=Cn),Te},typeof l>"u"&&(e.jQuery=e.$=Te),Te})})(jquery);var jqueryExports=jquery.exports;/*! WebUploader 0.1.6 */var jQuery$1=jqueryExports,webuploader_fis=function(t,e){var l={},n=function(O,N){var L,G,q;if(typeof O=="string")return y(O);for(L=[],G=O.length,q=0;q<G;q++)L.push(y(O[q]));return N.apply(null,L)},u=function(O,N,L){arguments.length===2&&(L=N,N=null),n(N||[],function(){c(O,L,arguments)})},c=function(O,N,L){var G={exports:N},q;typeof N=="function"&&(L.length||(L=[n,G.exports,G]),q=N.apply(null,L),q!==void 0&&(G.exports=q)),l[O]=G.exports},y=function(O){var N=l[O]||t[O];if(!N)throw new Error("`"+O+"` is undefined");return N},b=function(O){var N,L,G,q,J,fe;fe=function(ve){return ve&&ve.charAt(0).toUpperCase()+ve.substr(1)};for(N in l)if(L=O,!!l.hasOwnProperty(N)){for(G=N.split("/"),J=fe(G.pop());q=fe(G.shift());)L[q]=L[q]||{},L=L[q];L[J]=l[N]}return O},m=function(O){return t.__dollar=O,b(e(t,u,n))};return m(jQuery$1)}(window,function(t,e,l){e("dollar-third",[],function(){var u=t.require,c=t.__dollar||t.jQuery||t.Zepto||u("jquery")||u("zepto");if(!c)throw new Error("jQuery or Zepto not found!");return c}),e("dollar",["dollar-third"],function(u){return u}),e("promise-third",["dollar"],function(u){return{Deferred:u.Deferred,when:u.when,isPromise:function(c){return c&&typeof c.then=="function"}}}),e("promise",["promise-third"],function(u){return u}),e("base",["dollar","promise"],function(u,c){var y=function(){},b=Function.call;function m(L){return function(){return b.apply(L,arguments)}}function O(L,G){return function(){return L.apply(G,arguments)}}function N(L){var G;return Object.create?Object.create(L):(G=function(){},G.prototype=L,new G)}return{version:"0.1.6",$:u,Deferred:c.Deferred,isPromise:c.isPromise,when:c.when,browser:function(L){var G={},q=L.match(/WebKit\/([\d.]+)/),J=L.match(/Chrome\/([\d.]+)/)||L.match(/CriOS\/([\d.]+)/),fe=L.match(/MSIE\s([\d\.]+)/)||L.match(/(?:trident)(?:.*rv:([\w.]+))?/i),ve=L.match(/Firefox\/([\d.]+)/),ne=L.match(/Safari\/([\d.]+)/),Ue=L.match(/OPR\/([\d.]+)/);return q&&(G.webkit=parseFloat(q[1])),J&&(G.chrome=parseFloat(J[1])),fe&&(G.ie=parseFloat(fe[1])),ve&&(G.firefox=parseFloat(ve[1])),ne&&(G.safari=parseFloat(ne[1])),Ue&&(G.opera=parseFloat(Ue[1])),G}(navigator.userAgent),os:function(L){var G={},q=L.match(/(?:Android);?[\s\/]+([\d.]+)?/),J=L.match(/(?:iPad|iPod|iPhone).*OS\s([\d_]+)/);return q&&(G.android=parseFloat(q[1])),J&&(G.ios=parseFloat(J[1].replace(/_/g,"."))),G}(navigator.userAgent),inherits:function(L,G,q){var J;return typeof G=="function"?(J=G,G=null):G&&G.hasOwnProperty("constructor")?J=G.constructor:J=function(){return L.apply(this,arguments)},u.extend(!0,J,L,q||{}),J.__super__=L.prototype,J.prototype=N(L.prototype),G&&u.extend(!0,J.prototype,G),J},noop:y,bindFn:O,log:function(){return t.console?O(console.log,console):y}(),nextTick:function(){return function(L){setTimeout(L,1)}}(),slice:m([].slice),guid:function(){var L=0;return function(G){for(var q=(+new Date).toString(32),J=0;J<5;J++)q+=Math.floor(Math.random()*65535).toString(32);return(G||"wu_")+q+(L++).toString(32)}}(),formatSize:function(L,G,q){var J;for(q=q||["B","K","M","G","TB"];(J=q.shift())&&L>1024;)L=L/1024;return(J==="B"?L:L.toFixed(G||2))+J}}}),e("mediator",["base"],function(u){var c=u.$,y=[].slice,b=/\s+/,m;function O(G,q,J,fe){return c.grep(G,function(ve){return ve&&(!q||ve.e===q)&&(!J||ve.cb===J||ve.cb._cb===J)&&(!fe||ve.ctx===fe)})}function N(G,q,J){c.each((G||"").split(b),function(fe,ve){J(ve,q)})}function L(G,q){for(var J=!1,fe=-1,ve=G.length,ne;++fe<ve;)if(ne=G[fe],ne.cb.apply(ne.ctx2,q)===!1){J=!0;break}return!J}return m={on:function(G,q,J){var fe=this,ve;return q?(ve=this._events||(this._events=[]),N(G,q,function(ne,Ue){var De={e:ne};De.cb=Ue,De.ctx=J,De.ctx2=J||fe,De.id=ve.length,ve.push(De)}),this):this},once:function(G,q,J){var fe=this;return q&&N(G,q,function(ve,ne){var Ue=function(){return fe.off(ve,Ue),ne.apply(J||fe,arguments)};Ue._cb=ne,fe.on(ve,Ue,J)}),fe},off:function(G,q,J){var fe=this._events;return fe?!G&&!q&&!J?(this._events=[],this):(N(G,q,function(ve,ne){c.each(O(fe,ve,ne,J),function(){delete fe[this.id]})}),this):this},trigger:function(G){var q,J,fe;return!this._events||!G?this:(q=y.call(arguments,1),J=O(this._events,G),fe=O(this._events,"all"),L(J,q)&&L(fe,arguments))}},c.extend({installTo:function(G){return c.extend(G,m)}},m)}),e("uploader",["base","mediator"],function(u,c){var y=u.$;function b(m){this.options=y.extend(!0,{},b.options,m),this._init(this.options)}return b.options={},c.installTo(b.prototype),y.each({upload:"start-upload",stop:"stop-upload",getFile:"get-file",getFiles:"get-files",addFile:"add-file",addFiles:"add-file",sort:"sort-files",removeFile:"remove-file",cancelFile:"cancel-file",skipFile:"skip-file",retry:"retry",isInProgress:"is-in-progress",makeThumb:"make-thumb",md5File:"md5-file",getDimension:"get-dimension",addButton:"add-btn",predictRuntimeType:"predict-runtime-type",refresh:"refresh",disable:"disable",enable:"enable",reset:"reset"},function(m,O){b.prototype[m]=function(){return this.request(O,arguments)}}),y.extend(b.prototype,{state:"pending",_init:function(m){var O=this;O.request("init",m,function(){O.state="ready",O.trigger("ready")})},option:function(m,O){var N=this.options;if(arguments.length>1)y.isPlainObject(O)&&y.isPlainObject(N[m])?y.extend(N[m],O):N[m]=O;else return m?N[m]:N},getStats:function(){var m=this.request("get-stats");return m?{successNum:m.numOfSuccess,progressNum:m.numOfProgress,cancelNum:m.numOfCancel,invalidNum:m.numOfInvalid,uploadFailNum:m.numOfUploadFailed,queueNum:m.numOfQueue,interruptNum:m.numofInterrupt}:{}},trigger:function(m){var O=[].slice.call(arguments,1),N=this.options,L="on"+m.substring(0,1).toUpperCase()+m.substring(1);return!(c.trigger.apply(this,arguments)===!1||y.isFunction(N[L])&&N[L].apply(this,O)===!1||y.isFunction(this[L])&&this[L].apply(this,O)===!1||c.trigger.apply(c,[this,m].concat(O))===!1)},destroy:function(){this.request("destroy",arguments),this.off()},request:u.noop}),u.create=b.create=function(m){return new b(m)},u.Uploader=b,b}),e("runtime/runtime",["base","mediator"],function(u,c){var y=u.$,b={},m=function(N){for(var L in N)if(N.hasOwnProperty(L))return L;return null};function O(N){this.options=y.extend({container:document.body},N),this.uid=u.guid("rt_")}return y.extend(O.prototype,{getContainer:function(){var N=this.options,L,G;return this._container?this._container:(L=y(N.container||document.body),G=y(document.createElement("div")),G.attr("id","rt_"+this.uid),G.css({position:"absolute",top:"0px",left:"0px",width:"1px",height:"1px",overflow:"hidden"}),L.append(G),L.addClass("webuploader-container"),this._container=G,this._parent=L,G)},init:u.noop,exec:u.noop,destroy:function(){this._container&&this._container.remove(),this._parent&&this._parent.removeClass("webuploader-container"),this.off()}}),O.orders="html5,flash",O.addRuntime=function(N,L){b[N]=L},O.hasRuntime=function(N){return!!(N?b[N]:m(b))},O.create=function(N,L){var G,q;if(L=L||O.orders,y.each(L.split(/\s*,\s*/g),function(){if(b[this])return G=this,!1}),G=G||m(b),!G)throw new Error("Runtime Error");return q=new b[G](N),q},c.installTo(O.prototype),O}),e("runtime/client",["base","mediator","runtime/runtime"],function(u,c,y){var b;b=function(){var O={};return{add:function(N){O[N.uid]=N},get:function(N,L){var G;if(N)return O[N];for(G in O)if(!(L&&O[G].__standalone))return O[G];return null},remove:function(N){delete O[N.uid]}}}();function m(O,N){var L=u.Deferred(),G;this.uid=u.guid("client_"),this.runtimeReady=function(q){return L.done(q)},this.connectRuntime=function(q,J){if(G)throw new Error("already connected!");return L.done(J),typeof q=="string"&&b.get(q)&&(G=b.get(q)),G=G||b.get(null,N),G?(u.$.extend(G.options,q),G.__promise.then(L.resolve),G.__client++):(G=y.create(q,q.runtimeOrder),G.__promise=L.promise(),G.once("ready",L.resolve),G.init(),b.add(G),G.__client=1),N&&(G.__standalone=N),G},this.getRuntime=function(){return G},this.disconnectRuntime=function(){G&&(G.__client--,G.__client<=0&&(b.remove(G),delete G.__promise,G.destroy()),G=null)},this.exec=function(){if(G){var q=u.slice(arguments);return O&&q.unshift(O),G.exec.apply(this,q)}},this.getRuid=function(){return G&&G.uid},this.destroy=function(q){return function(){q&&q.apply(this,arguments),this.trigger("destroy"),this.off(),this.exec("destroy"),this.disconnectRuntime()}}(this.destroy)}return c.installTo(m.prototype),m}),e("lib/dnd",["base","mediator","runtime/client"],function(u,c,y){var b=u.$;function m(O){O=this.options=b.extend({},m.options,O),O.container=b(O.container),O.container.length&&y.call(this,"DragAndDrop")}return m.options={accept:null,disableGlobalDnd:!1},u.inherits(y,{constructor:m,init:function(){var O=this;O.connectRuntime(O.options,function(){O.exec("init"),O.trigger("ready")})}}),c.installTo(m.prototype),m}),e("widgets/widget",["base","uploader"],function(u,c){var y=u.$,b=c.prototype._init,m=c.prototype.destroy,O={},N=[];function L(q){if(!q)return!1;var J=q.length,fe=y.type(q);return q.nodeType===1&&J?!0:fe==="array"||fe!=="function"&&fe!=="string"&&(J===0||typeof J=="number"&&J>0&&J-1 in q)}function G(q){this.owner=q,this.options=q.options}return y.extend(G.prototype,{init:u.noop,invoke:function(q,J){var fe=this.responseMap;return!fe||!(q in fe)||!(fe[q]in this)||!y.isFunction(this[fe[q]])?O:this[fe[q]].apply(this,J)},request:function(){return this.owner.request.apply(this.owner,arguments)}}),y.extend(c.prototype,{_init:function(){var q=this,J=q._widgets=[],fe=q.options.disableWidgets||"";return y.each(N,function(ve,ne){(!fe||!~fe.indexOf(ne._name))&&J.push(new ne(q))}),b.apply(q,arguments)},request:function(q,J,fe){var ve=0,ne=this._widgets,Ue=ne&&ne.length,De=[],Ve=[],rt,Ae,Te,Xe;for(J=L(J)?J:[J];ve<Ue;ve++)rt=ne[ve],Ae=rt.invoke(q,J),Ae!==O&&(u.isPromise(Ae)?Ve.push(Ae):De.push(Ae));return fe||Ve.length?(Te=u.when.apply(u,Ve),Xe=Te.pipe?"pipe":"then",Te[Xe](function(){var ie=u.Deferred(),ue=arguments;return ue.length===1&&(ue=ue[0]),setTimeout(function(){ie.resolve(ue)},1),ie.promise()})[fe?Xe:"done"](fe||u.noop)):De[0]},destroy:function(){m.apply(this,arguments),this._widgets=null}}),c.register=G.register=function(q,J){var fe={init:"init",destroy:"destroy",name:"anonymous"},ve;return arguments.length===1?(J=q,y.each(J,function(ne){if(ne[0]==="_"||ne==="name"){ne==="name"&&(fe.name=J.name);return}fe[ne.replace(/[A-Z]/g,"-$&").toLowerCase()]=ne})):fe=y.extend(fe,q),J.responseMap=fe,ve=u.inherits(G,J),ve._name=fe.name,N.push(ve),ve},c.unRegister=G.unRegister=function(q){if(!(!q||q==="anonymous"))for(var J=N.length;J--;)N[J]._name===q&&N.splice(J,1)},G}),e("widgets/filednd",["base","uploader","lib/dnd","widgets/widget"],function(u,c,y){var b=u.$;return c.options.dnd="",c.register({name:"dnd",init:function(m){if(!(!m.dnd||this.request("predict-runtime-type")!=="html5")){var O=this,N=u.Deferred(),L=b.extend({},{disableGlobalDnd:m.disableGlobalDnd,container:m.dnd,accept:m.accept}),G;return this.dnd=G=new y(L),G.once("ready",N.resolve),G.on("drop",function(q){O.request("add-file",[q])}),G.on("accept",function(q){return O.owner.trigger("dndAccept",q)}),G.init(),N.promise()}},destroy:function(){this.dnd&&this.dnd.destroy()}})}),e("lib/filepaste",["base","mediator","runtime/client"],function(u,c,y){var b=u.$;function m(O){O=this.options=b.extend({},O),O.container=b(O.container||document.body),y.call(this,"FilePaste")}return u.inherits(y,{constructor:m,init:function(){var O=this;O.connectRuntime(O.options,function(){O.exec("init"),O.trigger("ready")})}}),c.installTo(m.prototype),m}),e("widgets/filepaste",["base","uploader","lib/filepaste","widgets/widget"],function(u,c,y){var b=u.$;return c.register({name:"paste",init:function(m){if(!(!m.paste||this.request("predict-runtime-type")!=="html5")){var O=this,N=u.Deferred(),L=b.extend({},{container:m.paste,accept:m.accept}),G;return this.paste=G=new y(L),G.once("ready",N.resolve),G.on("paste",function(q){O.owner.request("add-file",[q])}),G.init(),N.promise()}},destroy:function(){this.paste&&this.paste.destroy()}})}),e("lib/blob",["base","runtime/client"],function(u,c){function y(b,m){var O=this;O.source=m,O.ruid=b,this.size=m.size||0,!m.type&&this.ext&&~"jpg,jpeg,png,gif,bmp".indexOf(this.ext)?this.type="image/"+(this.ext==="jpg"?"jpeg":this.ext):this.type=m.type||"application/octet-stream",c.call(O,"Blob"),this.uid=m.uid||this.uid,b&&O.connectRuntime(b)}return u.inherits(c,{constructor:y,slice:function(b,m){return this.exec("slice",b,m)},getSource:function(){return this.source}}),y}),e("lib/file",["base","lib/blob"],function(u,c){var y=1,b=/\.([^.]+)$/;function m(O,N){var L;this.name=N.name||"untitled"+y++,L=b.exec(N.name)?RegExp.$1.toLowerCase():"",!L&&N.type&&(L=/\/(jpg|jpeg|png|gif|bmp)$/i.exec(N.type)?RegExp.$1.toLowerCase():"",this.name+="."+L),this.ext=L,this.lastModifiedDate=N.lastModifiedDate||new Date().toLocaleString(),c.apply(this,arguments)}return u.inherits(c,m)}),e("lib/filepicker",["base","runtime/client","lib/file"],function(u,c,y){var b=u.$;function m(O){if(O=this.options=b.extend({},m.options,O),O.container=b(O.id),!O.container.length)throw new Error("按钮指定错误");O.innerHTML=O.innerHTML||O.label||O.container.html()||"",O.button=b(O.button||document.createElement("div")),O.button.html(O.innerHTML),O.container.html(O.button),c.call(this,"FilePicker",!0)}return m.options={button:null,container:null,label:null,innerHTML:null,multiple:!0,accept:null,name:"file",style:"webuploader-pick"},u.inherits(c,{constructor:m,init:function(){var O=this,N=O.options,L=N.button,G=N.style;G&&L.addClass("webuploader-pick"),O.on("all",function(q){var J;switch(q){case"mouseenter":G&&L.addClass("webuploader-pick-hover");break;case"mouseleave":G&&L.removeClass("webuploader-pick-hover");break;case"change":J=O.exec("getFiles"),O.trigger("select",b.map(J,function(fe){return fe=new y(O.getRuid(),fe),fe._refer=N.container,fe}),N.container);break}}),O.connectRuntime(N,function(){O.refresh(),O.exec("init",N),O.trigger("ready")}),this._resizeHandler=u.bindFn(this.refresh,this),b(t).on("resize",this._resizeHandler)},refresh:function(){var O=this.getRuntime().getContainer(),N=this.options.button,L=N.outerWidth?N.outerWidth():N.width(),G=N.outerHeight?N.outerHeight():N.height(),q=N.offset();L&&G&&O.css({bottom:"auto",right:"auto",width:L+"px",height:G+"px"}).offset(q)},enable:function(){var O=this.options.button;O.removeClass("webuploader-pick-disable"),this.refresh()},disable:function(){var O=this.options.button;this.getRuntime().getContainer().css({top:"-99999px"}),O.addClass("webuploader-pick-disable")},destroy:function(){var O=this.options.button;b(t).off("resize",this._resizeHandler),O.removeClass("webuploader-pick-disable webuploader-pick-hover webuploader-pick")}}),m}),e("widgets/filepicker",["base","uploader","lib/filepicker","widgets/widget"],function(u,c,y){var b=u.$;return b.extend(c.options,{pick:null,accept:null}),c.register({name:"picker",init:function(m){return this.pickers=[],m.pick&&this.addBtn(m.pick)},refresh:function(){b.each(this.pickers,function(){this.refresh()})},addBtn:function(m){var O=this,N=O.options,L=N.accept,G=[];if(m)return b.isPlainObject(m)||(m={id:m}),b(m.id).each(function(){var q,J,fe;fe=u.Deferred(),q=b.extend({},m,{accept:b.isPlainObject(L)?[L]:L,swf:N.swf,runtimeOrder:N.runtimeOrder,id:this}),J=new y(q),J.once("ready",fe.resolve),J.on("select",function(ve){O.owner.request("add-file",[ve])}),J.on("dialogopen",function(){O.owner.trigger("dialogOpen",J.button)}),J.init(),O.pickers.push(J),G.push(fe.promise())}),u.when.apply(u,G)},disable:function(){b.each(this.pickers,function(){this.disable()})},enable:function(){b.each(this.pickers,function(){this.enable()})},destroy:function(){b.each(this.pickers,function(){this.destroy()}),this.pickers=null}})}),e("lib/image",["base","runtime/client","lib/blob"],function(u,c,y){var b=u.$;function m(O){this.options=b.extend({},m.options,O),c.call(this,"Image"),this.on("load",function(){this._info=this.exec("info"),this._meta=this.exec("meta")})}return m.options={quality:90,crop:!1,preserveHeaders:!1,allowMagnify:!1},u.inherits(c,{constructor:m,info:function(O){return O?(this._info=O,this):this._info},meta:function(O){return O?(this._meta=O,this):this._meta},loadFromBlob:function(O){var N=this,L=O.getRuid();this.connectRuntime(L,function(){N.exec("init",N.options),N.exec("loadFromBlob",O)})},resize:function(){var O=u.slice(arguments);return this.exec.apply(this,["resize"].concat(O))},crop:function(){var O=u.slice(arguments);return this.exec.apply(this,["crop"].concat(O))},getAsDataUrl:function(O){return this.exec("getAsDataUrl",O)},getAsBlob:function(O){var N=this.exec("getAsBlob",O);return new y(this.getRuid(),N)}}),m}),e("widgets/image",["base","uploader","lib/image","widgets/widget"],function(u,c,y){var b=u.$,m;return m=function(O){var N=0,L=[],G=function(){for(var q;L.length&&N<O;)q=L.shift(),N+=q[0],q[1]()};return function(q,J,fe){L.push([J,fe]),q.once("destroy",function(){N-=J,setTimeout(G,1)}),setTimeout(G,1)}}(5*1024*1024),b.extend(c.options,{thumb:{width:110,height:110,quality:70,allowMagnify:!0,crop:!0,preserveHeaders:!1,type:"image/jpeg"},compress:{width:1600,height:1600,quality:90,allowMagnify:!1,crop:!1,preserveHeaders:!0}}),c.register({name:"image",makeThumb:function(O,N,L,G){var q,J;if(O=this.request("get-file",O),!O.type.match(/^image/)){N(!0);return}q=b.extend({},this.options.thumb),b.isPlainObject(L)&&(q=b.extend(q,L),L=null),L=L||q.width,G=G||q.height,J=new y(q),J.once("load",function(){O._info=O._info||J.info(),O._meta=O._meta||J.meta(),L<=1&&L>0&&(L=O._info.width*L),G<=1&&G>0&&(G=O._info.height*G),J.resize(L,G)}),J.once("complete",function(){N(!1,J.getAsDataUrl(q.type)),J.destroy()}),J.once("error",function(fe){N(fe||!0),J.destroy()}),m(J,O.source.size,function(){O._info&&J.info(O._info),O._meta&&J.meta(O._meta),J.loadFromBlob(O.source)})},beforeSendFile:function(O){var N=this.options.compress||this.options.resize,L=N&&N.compressSize||0,G=N&&N.noCompressIfLarger||!1,q,J;if(O=this.request("get-file",O),!(!N||!~"image/jpeg,image/jpg".indexOf(O.type)||O.size<L||O._compressed))return N=b.extend({},N),J=u.Deferred(),q=new y(N),J.always(function(){q.destroy(),q=null}),q.once("error",J.reject),q.once("load",function(){var fe=N.width,ve=N.height;O._info=O._info||q.info(),O._meta=O._meta||q.meta(),fe<=1&&fe>0&&(fe=O._info.width*fe),ve<=1&&ve>0&&(ve=O._info.height*ve),q.resize(fe,ve)}),q.once("complete",function(){var fe,ve;try{fe=q.getAsBlob(N.type),ve=O.size,(!G||fe.size<ve)&&(O.source=fe,O.size=fe.size,O.trigger("resize",fe.size,ve)),O._compressed=!0,J.resolve()}catch{J.resolve()}}),O._info&&q.info(O._info),O._meta&&q.meta(O._meta),q.loadFromBlob(O.source),J.promise()}})}),e("file",["base","mediator"],function(u,c){var y=u.$,b="WU_FILE_",m=0,O=/\.([^.]+)$/,N={};function L(){return b+m++}function G(q){this.name=q.name||"Untitled",this.size=q.size||0,this.type=q.type||"application/octet-stream",this.lastModifiedDate=q.lastModifiedDate||new Date*1,this.id=L(),this.ext=O.exec(this.name)?RegExp.$1:"",this.statusText="",N[this.id]=G.Status.INITED,this.source=q,this.loaded=0,this.on("error",function(J){this.setStatus(G.Status.ERROR,J)})}return y.extend(G.prototype,{setStatus:function(q,J){var fe=N[this.id];typeof J<"u"&&(this.statusText=J),q!==fe&&(N[this.id]=q,this.trigger("statuschange",q,fe))},getStatus:function(){return N[this.id]},getSource:function(){return this.source},destroy:function(){this.off(),delete N[this.id]}}),c.installTo(G.prototype),G.Status={INITED:"inited",QUEUED:"queued",PROGRESS:"progress",ERROR:"error",COMPLETE:"complete",CANCELLED:"cancelled",INTERRUPT:"interrupt",INVALID:"invalid"},G}),e("queue",["base","mediator","file"],function(u,c,y){var b=u.$,m=y.Status;function O(){this.stats={numOfQueue:0,numOfSuccess:0,numOfCancel:0,numOfProgress:0,numOfUploadFailed:0,numOfInvalid:0,numofDeleted:0,numofInterrupt:0},this._queue=[],this._map={}}return b.extend(O.prototype,{append:function(N){return this._queue.push(N),this._fileAdded(N),this},prepend:function(N){return this._queue.unshift(N),this._fileAdded(N),this},getFile:function(N){return typeof N!="string"?N:this._map[N]},fetch:function(N){var L=this._queue.length,G,q;for(N=N||m.QUEUED,G=0;G<L;G++)if(q=this._queue[G],N===q.getStatus())return q;return null},sort:function(N){typeof N=="function"&&this._queue.sort(N)},getFiles:function(){for(var N=[].slice.call(arguments,0),L=[],G=0,q=this._queue.length,J;G<q;G++)J=this._queue[G],!(N.length&&!~b.inArray(J.getStatus(),N))&&L.push(J);return L},removeFile:function(N){var L=this._map[N.id];L&&(delete this._map[N.id],N.destroy(),this.stats.numofDeleted++)},_fileAdded:function(N){var L=this,G=this._map[N.id];G||(this._map[N.id]=N,N.on("statuschange",function(q,J){L._onFileStatusChange(q,J)}))},_onFileStatusChange:function(N,L){var G=this.stats;switch(L){case m.PROGRESS:G.numOfProgress--;break;case m.QUEUED:G.numOfQueue--;break;case m.ERROR:G.numOfUploadFailed--;break;case m.INVALID:G.numOfInvalid--;break;case m.INTERRUPT:G.numofInterrupt--;break}switch(N){case m.QUEUED:G.numOfQueue++;break;case m.PROGRESS:G.numOfProgress++;break;case m.ERROR:G.numOfUploadFailed++;break;case m.COMPLETE:G.numOfSuccess++;break;case m.CANCELLED:G.numOfCancel++;break;case m.INVALID:G.numOfInvalid++;break;case m.INTERRUPT:G.numofInterrupt++;break}}}),c.installTo(O.prototype),O}),e("widgets/queue",["base","uploader","queue","file","lib/file","runtime/client","widgets/widget"],function(u,c,y,b,m,O){var N=u.$,L=/\.\w+$/,G=b.Status;return c.register({name:"queue",init:function(q){var J=this,fe,ve,ne,Ue,De,Ve,rt;if(N.isPlainObject(q.accept)&&(q.accept=[q.accept]),q.accept){for(De=[],ne=0,ve=q.accept.length;ne<ve;ne++)Ue=q.accept[ne].extensions,Ue&&De.push(Ue);De.length&&(Ve="\\."+De.join(",").replace(/,/g,"$|\\.").replace(/\*/g,".*")+"$"),J.accept=new RegExp(Ve,"i")}if(J.queue=new y,J.stats=J.queue.stats,this.request("predict-runtime-type")==="html5")return fe=u.Deferred(),this.placeholder=rt=new O("Placeholder"),rt.connectRuntime({runtimeOrder:"html5"},function(){J._ruid=rt.getRuid(),fe.resolve()}),fe.promise()},_wrapFile:function(q){if(!(q instanceof b)){if(!(q instanceof m)){if(!this._ruid)throw new Error("Can't add external files.");q=new m(this._ruid,q)}q=new b(q)}return q},acceptFile:function(q){var J=!q||!q.size||this.accept&&L.exec(q.name)&&!this.accept.test(q.name);return!J},_addFile:function(q){var J=this;if(q=J._wrapFile(q),!!J.owner.trigger("beforeFileQueued",q)){if(!J.acceptFile(q)){J.owner.trigger("error","Q_TYPE_DENIED",q);return}return J.queue.append(q),J.owner.trigger("fileQueued",q),q}},getFile:function(q){return this.queue.getFile(q)},addFile:function(q){var J=this;q.length||(q=[q]),q=N.map(q,function(fe){return J._addFile(fe)}),q.length&&(J.owner.trigger("filesQueued",q),J.options.auto&&setTimeout(function(){J.request("start-upload")},20))},getStats:function(){return this.stats},removeFile:function(q,J){var fe=this;q=q.id?q:fe.queue.getFile(q),this.request("cancel-file",q),J&&this.queue.removeFile(q)},getFiles:function(){return this.queue.getFiles.apply(this.queue,arguments)},fetchFile:function(){return this.queue.fetch.apply(this.queue,arguments)},retry:function(q,J){var fe=this,ve,ne,Ue;if(q){q=q.id?q:fe.queue.getFile(q),q.setStatus(G.QUEUED),J||fe.request("start-upload");return}for(ve=fe.queue.getFiles(G.ERROR),ne=0,Ue=ve.length;ne<Ue;ne++)q=ve[ne],q.setStatus(G.QUEUED);fe.request("start-upload")},sortFiles:function(){return this.queue.sort.apply(this.queue,arguments)},reset:function(){this.owner.trigger("reset"),this.queue=new y,this.stats=this.queue.stats},destroy:function(){this.reset(),this.placeholder&&this.placeholder.destroy()}})}),e("widgets/runtime",["uploader","runtime/runtime","widgets/widget"],function(u,c){return u.support=function(){return c.hasRuntime.apply(c,arguments)},u.register({name:"runtime",init:function(){if(!this.predictRuntimeType())throw Error("Runtime Error")},predictRuntimeType:function(){var y=this.options.runtimeOrder||c.orders,b=this.type,m,O;if(!b){for(y=y.split(/\s*,\s*/g),m=0,O=y.length;m<O;m++)if(c.hasRuntime(y[m])){this.type=b=y[m];break}}return b}})}),e("lib/transport",["base","runtime/client","mediator"],function(u,c,y){var b=u.$;function m(O){var N=this;O=N.options=b.extend(!0,{},m.options,O||{}),c.call(this,"Transport"),this._blob=null,this._formData=O.formData||{},this._headers=O.headers||{},this.on("progress",this._timeout),this.on("load error",function(){N.trigger("progress",1),clearTimeout(N._timer)})}return m.options={server:"",method:"POST",withCredentials:!1,fileVal:"file",timeout:2*60*1e3,formData:{},headers:{},sendAsBinary:!1},b.extend(m.prototype,{appendBlob:function(O,N,L){var G=this,q=G.options;G.getRuid()&&G.disconnectRuntime(),G.connectRuntime(N.ruid,function(){G.exec("init")}),G._blob=N,q.fileVal=O||q.fileVal,q.filename=L||q.filename},append:function(O,N){typeof O=="object"?b.extend(this._formData,O):this._formData[O]=N},setRequestHeader:function(O,N){typeof O=="object"?b.extend(this._headers,O):this._headers[O]=N},send:function(O){this.exec("send",O),this._timeout()},abort:function(){return clearTimeout(this._timer),this.exec("abort")},destroy:function(){this.trigger("destroy"),this.off(),this.exec("destroy"),this.disconnectRuntime()},getResponse:function(){return this.exec("getResponse")},getResponseAsJson:function(){return this.exec("getResponseAsJson")},getStatus:function(){return this.exec("getStatus")},_timeout:function(){var O=this,N=O.options.timeout;N&&(clearTimeout(O._timer),O._timer=setTimeout(function(){O.abort(),O.trigger("error","timeout")},N))}}),y.installTo(m.prototype),m}),e("widgets/upload",["base","uploader","file","lib/transport","widgets/widget"],function(u,c,y,b){var m=u.$,O=u.isPromise,N=y.Status;m.extend(c.options,{prepareNextFile:!1,chunked:!1,chunkSize:5*1024*1024,chunkRetry:2,threads:3,formData:{}});function L(G,q){var J=[],fe=G.source,ve=fe.size,ne=q?Math.ceil(ve/q):1,Ue=0,De=0,Ve,rt;for(rt={file:G,has:function(){return!!J.length},shift:function(){return J.shift()},unshift:function(Ae){J.unshift(Ae)}};De<ne;)Ve=Math.min(q,ve-Ue),J.push({file:G,start:Ue,end:q?Ue+Ve:ve,total:ve,chunks:ne,chunk:De++,cuted:rt}),Ue+=Ve;return G.blocks=J.concat(),G.remaning=J.length,rt}c.register({name:"upload",init:function(){var G=this.owner,q=this;this.runing=!1,this.progress=!1,G.on("startUpload",function(){q.progress=!0}).on("uploadFinished",function(){q.progress=!1}),this.pool=[],this.stack=[],this.pending=[],this.remaning=0,this.__tick=u.bindFn(this._tick,this),G.on("uploadComplete",function(J){J.blocks&&m.each(J.blocks,function(fe,ve){ve.transport&&(ve.transport.abort(),ve.transport.destroy()),delete ve.transport}),delete J.blocks,delete J.remaning})},reset:function(){this.request("stop-upload",!0),this.runing=!1,this.pool=[],this.stack=[],this.pending=[],this.remaning=0,this._trigged=!1,this._promise=null},startUpload:function(G){var q=this;if(m.each(q.request("get-files",N.INVALID),function(){q.request("remove-file",this)}),G?(G=G.id?G:q.request("get-file",G),G.getStatus()===N.INTERRUPT?(G.setStatus(N.QUEUED),m.each(q.pool,function(fe,ve){ve.file===G&&(ve.transport&&ve.transport.send(),G.setStatus(N.PROGRESS))})):G.getStatus()!==N.PROGRESS&&G.setStatus(N.QUEUED)):m.each(q.request("get-files",[N.INITED]),function(){this.setStatus(N.QUEUED)}),q.runing)return u.nextTick(q.__tick);q.runing=!0;var J=[];G||m.each(q.pool,function(fe,ve){var ne=ve.file;ne.getStatus()===N.INTERRUPT&&(q._trigged=!1,J.push(ne),ve.transport&&ve.transport.send())}),m.each(J,function(){this.setStatus(N.PROGRESS)}),G||m.each(q.request("get-files",N.INTERRUPT),function(){this.setStatus(N.PROGRESS)}),q._trigged=!1,u.nextTick(q.__tick),q.owner.trigger("startUpload")},stopUpload:function(G,q){var J=this,fe;if(G===!0&&(q=G,G=null),J.runing!==!1){if(G)return G=G.id?G:J.request("get-file",G),G.getStatus()!==N.PROGRESS&&G.getStatus()!==N.QUEUED?void 0:(G.setStatus(N.INTERRUPT),m.each(J.pool,function(ve,ne){if(ne.file===G)return fe=ne,!1}),fe.transport&&fe.transport.abort(),q&&(J._putback(fe),J._popBlock(fe)),u.nextTick(J.__tick));J.runing=!1,this._promise&&this._promise.file&&this._promise.file.setStatus(N.INTERRUPT),q&&m.each(J.pool,function(ve,ne){ne.transport&&ne.transport.abort(),ne.file.setStatus(N.INTERRUPT)}),J.owner.trigger("stopUpload")}},cancelFile:function(G){G=G.id?G:this.request("get-file",G),G.blocks&&m.each(G.blocks,function(q,J){var fe=J.transport;fe&&(fe.abort(),fe.destroy(),delete J.transport)}),G.setStatus(N.CANCELLED),this.owner.trigger("fileDequeued",G)},isInProgress:function(){return!!this.progress},_getStats:function(){return this.request("get-stats")},skipFile:function(G,q){G=G.id?G:this.request("get-file",G),G.setStatus(q||N.COMPLETE),G.skipped=!0,G.blocks&&m.each(G.blocks,function(J,fe){var ve=fe.transport;ve&&(ve.abort(),ve.destroy(),delete fe.transport)}),this.owner.trigger("uploadSkip",G)},_tick:function(){var G=this,q=G.options,J,fe;if(G._promise)return G._promise.always(G.__tick);G.pool.length<q.threads&&(fe=G._nextBlock())?(G._trigged=!1,J=function(ve){G._promise=null,ve&&ve.file&&G._startSend(ve),u.nextTick(G.__tick)},G._promise=O(fe)?fe.always(J):J(fe)):!G.remaning&&!G._getStats().numOfQueue&&!G._getStats().numofInterrupt&&(G.runing=!1,G._trigged||u.nextTick(function(){G.owner.trigger("uploadFinished")}),G._trigged=!0)},_putback:function(G){var q;G.cuted.unshift(G),q=this.stack.indexOf(G.cuted),~q||this.stack.unshift(G.cuted)},_getStack:function(){for(var G=0,q;q=this.stack[G++];){if(q.has()&&q.file.getStatus()===N.PROGRESS)return q;(!q.has()||q.file.getStatus()!==N.PROGRESS&&q.file.getStatus()!==N.INTERRUPT)&&this.stack.splice(--G,1)}return null},_nextBlock:function(){var G=this,q=G.options,J,fe,ve,ne;if(J=this._getStack())return q.prepareNextFile&&!G.pending.length&&G._prepareNextFile(),J.shift();if(G.runing)return!G.pending.length&&G._getStats().numOfQueue&&G._prepareNextFile(),fe=G.pending.shift(),ve=function(Ue){return Ue?(J=L(Ue,q.chunked?q.chunkSize:0),G.stack.push(J),J.shift()):null},O(fe)?(ne=fe.file,fe=fe[fe.pipe?"pipe":"then"](ve),fe.file=ne,fe):ve(fe)},_prepareNextFile:function(){var G=this,q=G.request("fetch-file"),J=G.pending,fe;q&&(fe=G.request("before-send-file",q,function(){return q.getStatus()===N.PROGRESS||q.getStatus()===N.INTERRUPT?q:G._finishFile(q)}),G.owner.trigger("uploadStart",q),q.setStatus(N.PROGRESS),fe.file=q,fe.done(function(){var ve=m.inArray(fe,J);~ve&&J.splice(ve,1,q)}),fe.fail(function(ve){q.setStatus(N.ERROR,ve),G.owner.trigger("uploadError",q,ve),G.owner.trigger("uploadComplete",q)}),J.push(fe))},_popBlock:function(G){var q=m.inArray(G,this.pool);this.pool.splice(q,1),G.file.remaning--,this.remaning--},_startSend:function(G){var q=this,J=G.file,fe;if(J.getStatus()!==N.PROGRESS){J.getStatus()===N.INTERRUPT&&q._putback(G);return}q.pool.push(G),q.remaning++,G.blob=G.chunks===1?J.source:J.source.slice(G.start,G.end),fe=q.request("before-send",G,function(){J.getStatus()===N.PROGRESS?q._doSend(G):(q._popBlock(G),u.nextTick(q.__tick))}),fe.fail(function(){J.remaning===1?q._finishFile(J).always(function(){G.percentage=1,q._popBlock(G),q.owner.trigger("uploadComplete",J),u.nextTick(q.__tick)}):(G.percentage=1,q.updateFileProgress(J),q._popBlock(G),u.nextTick(q.__tick))})},_doSend:function(G){var q=this,J=q.owner,fe=q.options,ve=G.file,ne=new b(fe),Ue=m.extend({},fe.formData),De=m.extend({},fe.headers),Ve,rt;G.transport=ne,ne.on("destroy",function(){delete G.transport,q._popBlock(G),u.nextTick(q.__tick)}),ne.on("progress",function(Ae){G.percentage=Ae,q.updateFileProgress(ve)}),Ve=function(Ae){var Te;return rt=ne.getResponseAsJson()||{},rt._raw=ne.getResponse(),Te=function(Xe){Ae=Xe},J.trigger("uploadAccept",G,rt,Te)||(Ae=Ae||"server"),Ae},ne.on("error",function(Ae,Te){G.retried=G.retried||0,G.chunks>1&&~"http,abort".indexOf(Ae)&&G.retried<fe.chunkRetry?(G.retried++,ne.send()):(!Te&&Ae==="server"&&(Ae=Ve(Ae)),ve.setStatus(N.ERROR,Ae),J.trigger("uploadError",ve,Ae),J.trigger("uploadComplete",ve))}),ne.on("load",function(){var Ae;if(Ae=Ve()){ne.trigger("error",Ae,!0);return}ve.remaning===1?q._finishFile(ve,rt):ne.destroy()}),Ue=m.extend(Ue,{id:ve.id,name:ve.name,type:ve.type,lastModifiedDate:ve.lastModifiedDate,size:ve.size}),G.chunks>1&&m.extend(Ue,{chunks:G.chunks,chunk:G.chunk}),J.trigger("uploadBeforeSend",G,Ue,De),ne.appendBlob(fe.fileVal,G.blob,ve.name),ne.append(Ue),ne.setRequestHeader(De),ne.send()},_finishFile:function(G,q,J){var fe=this.owner;return fe.request("after-send-file",arguments,function(){G.setStatus(N.COMPLETE),fe.trigger("uploadSuccess",G,q,J)}).fail(function(ve){G.getStatus()===N.PROGRESS&&G.setStatus(N.ERROR,ve),fe.trigger("uploadError",G,ve)}).always(function(){fe.trigger("uploadComplete",G)})},updateFileProgress:function(G){var q=0,J=0;G.blocks&&(m.each(G.blocks,function(fe,ve){J+=(ve.percentage||0)*(ve.end-ve.start)}),q=J/G.size,this.owner.trigger("uploadProgress",G,q||0))}})}),e("widgets/validator",["base","uploader","file","widgets/widget"],function(u,c,y){var b=u.$,m={},O;return O={addValidator:function(N,L){m[N]=L},removeValidator:function(N){delete m[N]}},c.register({name:"validator",init:function(){var N=this;u.nextTick(function(){b.each(m,function(){this.call(N.owner)})})}}),O.addValidator("fileNumLimit",function(){var N=this,L=N.options,G=0,q=parseInt(L.fileNumLimit,10),J=!0;q&&(N.on("beforeFileQueued",function(fe){return G>=q&&J&&(J=!1,this.trigger("error","Q_EXCEED_NUM_LIMIT",q,fe),setTimeout(function(){J=!0},1)),!(G>=q)}),N.on("fileQueued",function(){G++}),N.on("fileDequeued",function(){G--}),N.on("reset",function(){G=0}))}),O.addValidator("fileSizeLimit",function(){var N=this,L=N.options,G=0,q=parseInt(L.fileSizeLimit,10),J=!0;q&&(N.on("beforeFileQueued",function(fe){var ve=G+fe.size>q;return ve&&J&&(J=!1,this.trigger("error","Q_EXCEED_SIZE_LIMIT",q,fe),setTimeout(function(){J=!0},1)),!ve}),N.on("fileQueued",function(fe){G+=fe.size}),N.on("fileDequeued",function(fe){G-=fe.size}),N.on("reset",function(){G=0}))}),O.addValidator("fileSingleSizeLimit",function(){var N=this,L=N.options,G=L.fileSingleSizeLimit;G&&N.on("beforeFileQueued",function(q){if(q.size>G)return q.setStatus(y.Status.INVALID,"exceed_size"),this.trigger("error","F_EXCEED_SIZE",G,q),!1})}),O.addValidator("duplicate",function(){var N=this,L=N.options,G={};if(L.duplicate)return;function q(J){for(var fe=0,ve=0,ne=J.length,Ue;ve<ne;ve++)Ue=J.charCodeAt(ve),fe=Ue+(fe<<6)+(fe<<16)-fe;return fe}N.on("beforeFileQueued",function(J){var fe=J.__hash||(J.__hash=q(J.name+J.size+J.lastModifiedDate));if(G[fe])return this.trigger("error","F_DUPLICATE",J),!1}),N.on("fileQueued",function(J){var fe=J.__hash;fe&&(G[fe]=!0)}),N.on("fileDequeued",function(J){var fe=J.__hash;fe&&delete G[fe]}),N.on("reset",function(){G={}})}),O}),e("lib/md5",["runtime/client","mediator"],function(u,c){function y(){u.call(this,"Md5")}return c.installTo(y.prototype),y.prototype.loadFromBlob=function(b){var m=this;m.getRuid()&&m.disconnectRuntime(),m.connectRuntime(b.ruid,function(){m.exec("init"),m.exec("loadFromBlob",b)})},y.prototype.getResult=function(){return this.exec("getResult")},y}),e("widgets/md5",["base","uploader","lib/md5","lib/blob","widgets/widget"],function(u,c,y,b){return c.register({name:"md5",md5File:function(m,O,N){var L=new y,G=u.Deferred(),q=m instanceof b?m:this.request("get-file",m).source;return L.on("progress load",function(J){J=J||{},G.notify(J.total?J.loaded/J.total:1)}),L.on("complete",function(){G.resolve(L.getResult())}),L.on("error",function(J){G.reject(J)}),arguments.length>1&&(O=O||0,N=N||0,O<0&&(O=q.size+O),N<0&&(N=q.size+N),N=Math.min(N,q.size),q=q.slice(O,N)),L.loadFromBlob(q),G.promise()}})}),e("runtime/compbase",[],function(){function u(c,y){this.owner=c,this.options=c.options,this.getRuntime=function(){return y},this.getRuid=function(){return y.uid},this.trigger=function(){return c.trigger.apply(c,arguments)}}return u}),e("runtime/html5/runtime",["base","runtime/runtime","runtime/compbase"],function(u,c,y){var b="html5",m={};function O(){var N={},L=this,G=this.destroy;c.apply(L,arguments),L.type=b,L.exec=function(q,J){var fe=this,ve=fe.uid,ne=u.slice(arguments,2),Ue;if(m[q]&&(Ue=N[ve]=N[ve]||new m[q](fe,L),Ue[J]))return Ue[J].apply(Ue,ne)},L.destroy=function(){return G&&G.apply(this,arguments)}}return u.inherits(c,{constructor:O,init:function(){var N=this;setTimeout(function(){N.trigger("ready")},1)}}),O.register=function(N,L){var G=m[N]=u.inherits(y,L);return G},t.Blob&&t.FileReader&&t.DataView&&c.addRuntime(b,O),O}),e("runtime/html5/blob",["runtime/html5/runtime","lib/blob"],function(u,c){return u.register("Blob",{slice:function(y,b){var m=this.owner.source,O=m.slice||m.webkitSlice||m.mozSlice;return m=O.call(m,y,b),new c(this.getRuid(),m)}})}),e("runtime/html5/dnd",["base","runtime/html5/runtime","lib/file"],function(u,c,y){var b=u.$,m="webuploader-dnd-";return c.register("DragAndDrop",{init:function(){var O=this.elem=this.options.container;this.dragEnterHandler=u.bindFn(this._dragEnterHandler,this),this.dragOverHandler=u.bindFn(this._dragOverHandler,this),this.dragLeaveHandler=u.bindFn(this._dragLeaveHandler,this),this.dropHandler=u.bindFn(this._dropHandler,this),this.dndOver=!1,O.on("dragenter",this.dragEnterHandler),O.on("dragover",this.dragOverHandler),O.on("dragleave",this.dragLeaveHandler),O.on("drop",this.dropHandler),this.options.disableGlobalDnd&&(b(document).on("dragover",this.dragOverHandler),b(document).on("drop",this.dropHandler))},_dragEnterHandler:function(O){var N=this,L=N._denied||!1,G;return O=O.originalEvent||O,N.dndOver||(N.dndOver=!0,G=O.dataTransfer.items,G&&G.length&&(N._denied=L=!N.trigger("accept",G)),N.elem.addClass(m+"over"),N.elem[L?"addClass":"removeClass"](m+"denied")),O.dataTransfer.dropEffect=L?"none":"copy",!1},_dragOverHandler:function(O){var N=this.elem.parent().get(0);return N&&!b.contains(N,O.currentTarget)||(clearTimeout(this._leaveTimer),this._dragEnterHandler.call(this,O)),!1},_dragLeaveHandler:function(){var O=this,N;return N=function(){O.dndOver=!1,O.elem.removeClass(m+"over "+m+"denied")},clearTimeout(O._leaveTimer),O._leaveTimer=setTimeout(N,100),!1},_dropHandler:function(O){var N=this,L=N.getRuid(),G=N.elem.parent().get(0),q,J;if(G&&!b.contains(G,O.currentTarget))return!1;O=O.originalEvent||O,q=O.dataTransfer;try{J=q.getData("text/html")}catch{}if(N.dndOver=!1,N.elem.removeClass(m+"over"),!J)return N._getTansferFiles(q,function(fe){N.trigger("drop",b.map(fe,function(ve){return new y(L,ve)}))}),!1},_getTansferFiles:function(O,N){var L=[],G=[],q,J,fe,ve,ne,Ue,De;for(q=O.items,J=O.files,De=!!(q&&q[0].webkitGetAsEntry),ne=0,Ue=J.length;ne<Ue;ne++)fe=J[ne],ve=q&&q[ne],De&&ve.webkitGetAsEntry().isDirectory?G.push(this._traverseDirectoryTree(ve.webkitGetAsEntry(),L)):L.push(fe);u.when.apply(u,G).done(function(){L.length&&N(L)})},_traverseDirectoryTree:function(O,N){var L=u.Deferred(),G=this;return O.isFile?O.file(function(q){N.push(q),L.resolve()}):O.isDirectory&&O.createReader().readEntries(function(q){var J=q.length,fe=[],ve=[],ne;for(ne=0;ne<J;ne++)fe.push(G._traverseDirectoryTree(q[ne],ve));u.when.apply(u,fe).then(function(){N.push.apply(N,ve),L.resolve()},L.reject)}),L.promise()},destroy:function(){var O=this.elem;O&&(O.off("dragenter",this.dragEnterHandler),O.off("dragover",this.dragOverHandler),O.off("dragleave",this.dragLeaveHandler),O.off("drop",this.dropHandler),this.options.disableGlobalDnd&&(b(document).off("dragover",this.dragOverHandler),b(document).off("drop",this.dropHandler)))}})}),e("runtime/html5/filepaste",["base","runtime/html5/runtime","lib/file"],function(u,c,y){return c.register("FilePaste",{init:function(){var b=this.options,m=this.elem=b.container,O=".*",N,L,G,q;if(b.accept){for(N=[],L=0,G=b.accept.length;L<G;L++)q=b.accept[L].mimeTypes,q&&N.push(q);N.length&&(O=N.join(","),O=O.replace(/,/g,"|").replace(/\*/g,".*"))}this.accept=O=new RegExp(O,"i"),this.hander=u.bindFn(this._pasteHander,this),m.on("paste",this.hander)},_pasteHander:function(b){var m=[],O=this.getRuid(),N,L,G,q,J;for(b=b.originalEvent||b,N=b.clipboardData.items,q=0,J=N.length;q<J;q++)L=N[q],!(L.kind!=="file"||!(G=L.getAsFile()))&&m.push(new y(O,G));m.length&&(b.preventDefault(),b.stopPropagation(),this.trigger("paste",m))},destroy:function(){this.elem.off("paste",this.hander)}})}),e("runtime/html5/filepicker",["base","runtime/html5/runtime"],function(u,c){var y=u.$;return c.register("FilePicker",{init:function(){var b=this.getRuntime().getContainer(),m=this,O=m.owner,N=m.options,L=this.label=y(document.createElement("label")),G=this.input=y(document.createElement("input")),q,J,fe,ve;if(G.attr("type","file"),G.attr("capture","camera"),G.attr("name",N.name),G.addClass("webuploader-element-invisible"),L.on("click",function(Ue){G.trigger("click"),Ue.stopPropagation(),O.trigger("dialogopen")}),L.css({opacity:0,width:"100%",height:"100%",display:"block",cursor:"pointer",background:"#ffffff"}),N.multiple&&G.attr("multiple","multiple"),N.accept&&N.accept.length>0){for(q=[],J=0,fe=N.accept.length;J<fe;J++)q.push(N.accept[J].mimeTypes);G.attr("accept",q.join(","))}b.append(G),b.append(L),ve=function(Ue){O.trigger(Ue.type)};function ne(Ue){var De=ne,Ve;m.files=Ue.target.files,Ve=this.cloneNode(!0),Ve.value=null,this.parentNode.replaceChild(Ve,this),G.off(),G=y(Ve).on("change",De).on("mouseenter mouseleave",ve),O.trigger("change")}G.on("change",ne),L.on("mouseenter mouseleave",ve)},getFiles:function(){return this.files},destroy:function(){this.input.off(),this.label.off()}})}),e("runtime/html5/util",["base"],function(u){var c=t.createObjectURL&&t||t.URL&&URL.revokeObjectURL&&URL||t.webkitURL,y=u.noop,b=y;return c&&(y=function(){return c.createObjectURL.apply(c,arguments)},b=function(){return c.revokeObjectURL.apply(c,arguments)}),{createObjectURL:y,revokeObjectURL:b,dataURL2Blob:function(m){var O,N,L,G,q,J;for(J=m.split(","),~J[0].indexOf("base64")?O=atob(J[1]):O=decodeURIComponent(J[1]),L=new ArrayBuffer(O.length),N=new Uint8Array(L),G=0;G<O.length;G++)N[G]=O.charCodeAt(G);return q=J[0].split(":")[1].split(";")[0],this.arrayBufferToBlob(L,q)},dataURL2ArrayBuffer:function(m){var O,N,L,G;for(G=m.split(","),~G[0].indexOf("base64")?O=atob(G[1]):O=decodeURIComponent(G[1]),N=new Uint8Array(O.length),L=0;L<O.length;L++)N[L]=O.charCodeAt(L);return N.buffer},arrayBufferToBlob:function(m,O){var N=t.BlobBuilder||t.WebKitBlobBuilder,L;return N?(L=new N,L.append(m),L.getBlob(O)):new Blob([m],O?{type:O}:{})},canvasToDataUrl:function(m,O,N){return m.toDataURL(O,N/100)},parseMeta:function(m,O){O(!1,{})},updateImageHead:function(m){return m}}}),e("runtime/html5/imagemeta",["runtime/html5/util"],function(u){var c;return c={parsers:{65505:[]},maxMetaDataSize:262144,parse:function(y,b){var m=this,O=new FileReader;O.onload=function(){b(!1,m._parse(this.result)),O=O.onload=O.onerror=null},O.onerror=function(N){b(N.message),O=O.onload=O.onerror=null},y=y.slice(0,m.maxMetaDataSize),O.readAsArrayBuffer(y.getSource())},_parse:function(y,b){if(!(y.byteLength<6)){var m=new DataView(y),O=2,N=m.byteLength-4,L=O,G={},q,J,fe,ve;if(m.getUint16(0)===65496){for(;O<N&&(q=m.getUint16(O),q>=65504&&q<=65519||q===65534);){if(J=m.getUint16(O+2)+2,O+J>m.byteLength)break;if(fe=c.parsers[q],!b&&fe)for(ve=0;ve<fe.length;ve+=1)fe[ve].call(c,m,O,J,G);O+=J,L=O}L>6&&(y.slice?G.imageHead=y.slice(2,L):G.imageHead=new Uint8Array(y).subarray(2,L))}return G}},updateImageHead:function(y,b){var m=this._parse(y,!0),O,N,L;return L=2,m.imageHead&&(L=2+m.imageHead.byteLength),y.slice?N=y.slice(L):N=new Uint8Array(y).subarray(L),O=new Uint8Array(b.byteLength+2+N.byteLength),O[0]=255,O[1]=216,O.set(new Uint8Array(b),2),O.set(new Uint8Array(N),b.byteLength+2),O.buffer}},u.parseMeta=function(){return c.parse.apply(c,arguments)},u.updateImageHead=function(){return c.updateImageHead.apply(c,arguments)},c}),e("runtime/html5/imagemeta/exif",["base","runtime/html5/imagemeta"],function(u,c){var y={};return y.ExifMap=function(){return this},y.ExifMap.prototype.map={Orientation:274},y.ExifMap.prototype.get=function(b){return this[b]||this[this.map[b]]},y.exifTagTypes={1:{getValue:function(b,m){return b.getUint8(m)},size:1},2:{getValue:function(b,m){return String.fromCharCode(b.getUint8(m))},size:1,ascii:!0},3:{getValue:function(b,m,O){return b.getUint16(m,O)},size:2},4:{getValue:function(b,m,O){return b.getUint32(m,O)},size:4},5:{getValue:function(b,m,O){return b.getUint32(m,O)/b.getUint32(m+4,O)},size:8},9:{getValue:function(b,m,O){return b.getInt32(m,O)},size:4},10:{getValue:function(b,m,O){return b.getInt32(m,O)/b.getInt32(m+4,O)},size:8}},y.exifTagTypes[7]=y.exifTagTypes[1],y.getExifValue=function(b,m,O,N,L,G){var q=y.exifTagTypes[N],J,fe,ve,ne,Ue,De;if(!q){u.log("Invalid Exif data: Invalid tag type.");return}if(J=q.size*L,fe=J>4?m+b.getUint32(O+8,G):O+8,fe+J>b.byteLength){u.log("Invalid Exif data: Invalid data offset.");return}if(L===1)return q.getValue(b,fe,G);for(ve=[],ne=0;ne<L;ne+=1)ve[ne]=q.getValue(b,fe+ne*q.size,G);if(q.ascii){for(Ue="",ne=0;ne<ve.length&&(De=ve[ne],De!=="\0");ne+=1)Ue+=De;return Ue}return ve},y.parseExifTag=function(b,m,O,N,L){var G=b.getUint16(O,N);L.exif[G]=y.getExifValue(b,m,O,b.getUint16(O+2,N),b.getUint32(O+4,N),N)},y.parseExifTags=function(b,m,O,N,L){var G,q,J;if(O+6>b.byteLength){u.log("Invalid Exif data: Invalid directory offset.");return}if(G=b.getUint16(O,N),q=O+2+12*G,q+4>b.byteLength){u.log("Invalid Exif data: Invalid directory size.");return}for(J=0;J<G;J+=1)this.parseExifTag(b,m,O+2+12*J,N,L);return b.getUint32(q,N)},y.parseExifData=function(b,m,O,N){var L=m+10,G,q;if(b.getUint32(m+4)===1165519206){if(L+8>b.byteLength){u.log("Invalid Exif data: Invalid segment size.");return}if(b.getUint16(m+8)!==0){u.log("Invalid Exif data: Missing byte alignment offset.");return}switch(b.getUint16(L)){case 18761:G=!0;break;case 19789:G=!1;break;default:u.log("Invalid Exif data: Invalid byte alignment marker.");return}if(b.getUint16(L+2,G)!==42){u.log("Invalid Exif data: Missing TIFF marker.");return}q=b.getUint32(L+4,G),N.exif=new y.ExifMap,q=y.parseExifTags(b,L,L+q,G,N)}},c.parsers[65505].push(y.parseExifData),y}),e("runtime/html5/jpegencoder",[],function(u,c,y){function b(m){var O=Math.floor,N=new Array(64),L=new Array(64),G=new Array(64),q=new Array(64),J,fe,ve,ne,Ue=new Array(65535),De=new Array(65535),Ve=new Array(64),rt=new Array(64),Ae=[],Te=0,Xe=7,ie=new Array(64),ue=new Array(64),pt=new Array(64),mt=new Array(256),Tt=new Array(2048),kt,It=[0,1,5,6,14,15,27,28,2,4,7,13,16,26,29,42,3,8,12,17,25,30,41,43,9,11,18,24,31,40,44,53,10,19,23,32,39,45,52,54,20,22,33,38,46,51,55,60,21,34,37,47,50,56,59,61,35,36,48,49,57,58,62,63],nn=[0,0,1,5,1,1,1,1,1,1,0,0,0,0,0,0,0],tn=[0,1,2,3,4,5,6,7,8,9,10,11],pn=[0,0,2,1,3,3,2,4,3,5,5,4,4,0,0,1,125],_n=[1,2,3,0,4,17,5,18,33,49,65,6,19,81,97,7,34,113,20,50,129,145,161,8,35,66,177,193,21,82,209,240,36,51,98,114,130,9,10,22,23,24,25,26,37,38,39,40,41,42,52,53,54,55,56,57,58,67,68,69,70,71,72,73,74,83,84,85,86,87,88,89,90,99,100,101,102,103,104,105,106,115,116,117,118,119,120,121,122,131,132,133,134,135,136,137,138,146,147,148,149,150,151,152,153,154,162,163,164,165,166,167,168,169,170,178,179,180,181,182,183,184,185,186,194,195,196,197,198,199,200,201,202,210,211,212,213,214,215,216,217,218,225,226,227,228,229,230,231,232,233,234,241,242,243,244,245,246,247,248,249,250],Dn=[0,0,3,1,1,1,1,1,1,1,1,1,0,0,0,0,0],an=[0,1,2,3,4,5,6,7,8,9,10,11],Rn=[0,0,2,1,2,4,4,3,4,7,5,4,4,0,1,2,119],Lt=[0,1,2,3,17,4,5,33,49,6,18,65,81,7,97,113,19,34,50,129,8,20,66,145,161,177,193,9,35,51,82,240,21,98,114,209,10,22,36,52,225,37,241,23,24,25,26,38,39,40,41,42,53,54,55,56,57,58,67,68,69,70,71,72,73,74,83,84,85,86,87,88,89,90,99,100,101,102,103,104,105,106,115,116,117,118,119,120,121,122,130,131,132,133,134,135,136,137,138,146,147,148,149,150,151,152,153,154,162,163,164,165,166,167,168,169,170,178,179,180,181,182,183,184,185,186,194,195,196,197,198,199,200,201,202,210,211,212,213,214,215,216,217,218,226,227,228,229,230,231,232,233,234,242,243,244,245,246,247,248,249,250];function wn(ai){for(var Ia=[16,11,10,16,24,40,51,61,12,12,14,19,26,58,60,55,14,13,16,24,40,57,69,56,14,17,22,29,51,87,80,62,18,22,37,56,68,109,103,77,24,35,55,64,81,104,113,92,49,64,78,87,103,121,120,101,72,92,95,98,112,100,103,99],fi=0;fi<64;fi++){var An=O((Ia[fi]*ai+50)/100);An<1?An=1:An>255&&(An=255),N[It[fi]]=An}for(var sa=[17,18,24,47,99,99,99,99,18,21,26,66,99,99,99,99,24,26,56,99,99,99,99,99,47,66,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99],Nn=0;Nn<64;Nn++){var fn=O((sa[Nn]*ai+50)/100);fn<1?fn=1:fn>255&&(fn=255),L[It[Nn]]=fn}for(var un=[1,1.387039845,1.306562965,1.175875602,1,.785694958,.5411961,.275899379],Ln=0,hr=0;hr<8;hr++)for(var hi=0;hi<8;hi++)G[Ln]=1/(N[It[Ln]]*un[hr]*un[hi]*8),q[Ln]=1/(L[It[Ln]]*un[hr]*un[hi]*8),Ln++}function hn(ai,Ia){for(var fi=0,An=0,sa=new Array,Nn=1;Nn<=16;Nn++){for(var fn=1;fn<=ai[Nn];fn++)sa[Ia[An]]=[],sa[Ia[An]][0]=fi,sa[Ia[An]][1]=Nn,An++,fi++;fi*=2}return sa}function xn(){J=hn(nn,tn),fe=hn(Dn,an),ve=hn(pn,_n),ne=hn(Rn,Lt)}function $n(){for(var ai=1,Ia=2,fi=1;fi<=15;fi++){for(var An=ai;An<Ia;An++)De[32767+An]=fi,Ue[32767+An]=[],Ue[32767+An][1]=fi,Ue[32767+An][0]=An;for(var sa=-(Ia-1);sa<=-ai;sa++)De[32767+sa]=fi,Ue[32767+sa]=[],Ue[32767+sa][1]=fi,Ue[32767+sa][0]=Ia-1+sa;ai<<=1,Ia<<=1}}function Xr(){for(var ai=0;ai<256;ai++)Tt[ai]=19595*ai,Tt[ai+256>>0]=38470*ai,Tt[ai+512>>0]=7471*ai+32768,Tt[ai+768>>0]=-11059*ai,Tt[ai+1024>>0]=-21709*ai,Tt[ai+1280>>0]=32768*ai+8421375,Tt[ai+1536>>0]=-27439*ai,Tt[ai+1792>>0]=-5329*ai}function ti(ai){for(var Ia=ai[0],fi=ai[1]-1;fi>=0;)Ia&1<<fi&&(Te|=1<<Xe),fi--,Xe--,Xe<0&&(Te==255?(gn(255),gn(0)):gn(Te),Xe=7,Te=0)}function gn(ai){Ae.push(mt[ai])}function Xn(ai){gn(ai>>8&255),gn(ai&255)}function Kn(ai,Ia){var fi,An,sa,Nn,fn,un,Ln,hr,hi=0,bi,Ra=8,so=64;for(bi=0;bi<Ra;++bi){fi=ai[hi],An=ai[hi+1],sa=ai[hi+2],Nn=ai[hi+3],fn=ai[hi+4],un=ai[hi+5],Ln=ai[hi+6],hr=ai[hi+7];var Pi=fi+hr,oi=fi-hr,Ni=An+Ln,za=An-Ln,ki=sa+un,Aa=sa-un,Ja=Nn+fn,yo=Nn-fn,ls=Pi+Ja,xo=Pi-Ja,_o=Ni+ki,Ao=Ni-ki;ai[hi]=ls+_o,ai[hi+4]=ls-_o;var il=(Ao+xo)*.707106781;ai[hi+2]=xo+il,ai[hi+6]=xo-il,ls=yo+Aa,_o=Aa+za,Ao=za+oi;var zr=(ls-Ao)*.382683433,zn=.5411961*ls+zr,Un=1.306562965*Ao+zr,Gr=_o*.707106781,ni=oi+Gr,Ei=oi-Gr;ai[hi+5]=Ei+zn,ai[hi+3]=Ei-zn,ai[hi+1]=ni+Un,ai[hi+7]=ni-Un,hi+=8}for(hi=0,bi=0;bi<Ra;++bi){fi=ai[hi],An=ai[hi+8],sa=ai[hi+16],Nn=ai[hi+24],fn=ai[hi+32],un=ai[hi+40],Ln=ai[hi+48],hr=ai[hi+56];var $t=fi+hr,ta=fi-hr,Hi=An+Ln,Ai=An-Ln,Ea=sa+un,wo=sa-un,to=Nn+fn,zo=Nn-fn,Po=$t+to,Lo=$t-to,Wo=Hi+Ea,ma=Hi-Ea;ai[hi]=Po+Wo,ai[hi+32]=Po-Wo;var $s=(ma+Lo)*.707106781;ai[hi+16]=Lo+$s,ai[hi+48]=Lo-$s,Po=zo+wo,Wo=wo+Ai,ma=Ai+ta;var ao=(Po-ma)*.382683433,Ps=.5411961*Po+ao,qo=1.306562965*ma+ao,wl=Wo*.707106781,yu=ta+wl,po=ta-wl;ai[hi+40]=po+Ps,ai[hi+24]=po-Ps,ai[hi+8]=yu+qo,ai[hi+56]=yu-qo,hi++}var Zs;for(bi=0;bi<so;++bi)Zs=ai[bi]*Ia[bi],Ve[bi]=Zs>0?Zs+.5|0:Zs-.5|0;return Ve}function Vn(){Xn(65504),Xn(16),gn(74),gn(70),gn(73),gn(70),gn(0),gn(1),gn(1),gn(0),Xn(1),Xn(1),gn(0),gn(0)}function Yn(ai,Ia){Xn(65472),Xn(17),gn(8),Xn(Ia),Xn(ai),gn(3),gn(1),gn(17),gn(0),gn(2),gn(17),gn(1),gn(3),gn(17),gn(1)}function Vr(){Xn(65499),Xn(132),gn(0);for(var ai=0;ai<64;ai++)gn(N[ai]);gn(1);for(var Ia=0;Ia<64;Ia++)gn(L[Ia])}function xi(){Xn(65476),Xn(418),gn(0);for(var ai=0;ai<16;ai++)gn(nn[ai+1]);for(var Ia=0;Ia<=11;Ia++)gn(tn[Ia]);gn(16);for(var fi=0;fi<16;fi++)gn(pn[fi+1]);for(var An=0;An<=161;An++)gn(_n[An]);gn(1);for(var sa=0;sa<16;sa++)gn(Dn[sa+1]);for(var Nn=0;Nn<=11;Nn++)gn(an[Nn]);gn(17);for(var fn=0;fn<16;fn++)gn(Rn[fn+1]);for(var un=0;un<=161;un++)gn(Lt[un])}function Si(){Xn(65498),Xn(12),gn(3),gn(1),gn(0),gn(2),gn(17),gn(3),gn(17),gn(0),gn(63),gn(0)}function qn(ai,Ia,fi,An,sa){for(var Nn=sa[0],fn=sa[240],un,Ln=16,hr=63,hi=64,bi=Kn(ai,Ia),Ra=0;Ra<hi;++Ra)rt[It[Ra]]=bi[Ra];var so=rt[0]-fi;fi=rt[0],so==0?ti(An[0]):(un=32767+so,ti(An[De[un]]),ti(Ue[un]));for(var Pi=63;Pi>0&&rt[Pi]==0;Pi--);if(Pi==0)return ti(Nn),fi;for(var oi=1,Ni;oi<=Pi;){for(var za=oi;rt[oi]==0&&oi<=Pi;++oi);var ki=oi-za;if(ki>=Ln){Ni=ki>>4;for(var Aa=1;Aa<=Ni;++Aa)ti(fn);ki=ki&15}un=32767+rt[oi],ti(sa[(ki<<4)+De[un]]),ti(Ue[un]),oi++}return Pi!=hr&&ti(Nn),fi}function ia(){for(var ai=String.fromCharCode,Ia=0;Ia<256;Ia++)mt[Ia]=ai(Ia)}this.encode=function(ai,Ia){Ia&&Wi(Ia),Ae=new Array,Te=0,Xe=7,Xn(65496),Vn(),Vr(),Yn(ai.width,ai.height),xi(),Si();var fi=0,An=0,sa=0;Te=0,Xe=7,this.encode.displayName="_encode_";for(var Nn=ai.data,fn=ai.width,un=ai.height,Ln=fn*4,hr,hi=0,bi,Ra,so,Pi,oi,Ni,za,ki;hi<un;){for(hr=0;hr<Ln;){for(Pi=Ln*hi+hr,oi=Pi,Ni=-1,za=0,ki=0;ki<64;ki++)za=ki>>3,Ni=(ki&7)*4,oi=Pi+za*Ln+Ni,hi+za>=un&&(oi-=Ln*(hi+1+za-un)),hr+Ni>=Ln&&(oi-=hr+Ni-Ln+4),bi=Nn[oi++],Ra=Nn[oi++],so=Nn[oi++],ie[ki]=(Tt[bi]+Tt[Ra+256>>0]+Tt[so+512>>0]>>16)-128,ue[ki]=(Tt[bi+768>>0]+Tt[Ra+1024>>0]+Tt[so+1280>>0]>>16)-128,pt[ki]=(Tt[bi+1280>>0]+Tt[Ra+1536>>0]+Tt[so+1792>>0]>>16)-128;fi=qn(ie,G,fi,J,ve),An=qn(ue,q,An,fe,ne),sa=qn(pt,q,sa,fe,ne),hr+=32}hi+=8}if(Xe>=0){var Aa=[];Aa[1]=Xe+1,Aa[0]=(1<<Xe+1)-1,ti(Aa)}Xn(65497);var Ja="data:image/jpeg;base64,"+btoa(Ae.join(""));return Ae=[],Ja};function Wi(ai){if(ai<=0&&(ai=1),ai>100&&(ai=100),kt!=ai){var Ia=0;ai<50?Ia=Math.floor(5e3/ai):Ia=Math.floor(200-ai*2),wn(Ia),kt=ai}}function ha(){m||(m=50),ia(),xn(),$n(),Xr(),Wi(m)}ha()}return b.encode=function(m,O){var N=new b(O);return N.encode(m)},b}),e("runtime/html5/androidpatch",["runtime/html5/util","runtime/html5/jpegencoder","base"],function(u,c,y){var b=u.canvasToDataUrl,m;u.canvasToDataUrl=function(O,N,L){var G,q,J,fe,ve;return y.os.android?(N==="image/jpeg"&&typeof m>"u"&&(fe=b.apply(null,arguments),ve=fe.split(","),~ve[0].indexOf("base64")?fe=atob(ve[1]):fe=decodeURIComponent(ve[1]),fe=fe.substring(0,2),m=fe.charCodeAt(0)===255&&fe.charCodeAt(1)===216),N==="image/jpeg"&&!m?(q=O.width,J=O.height,G=O.getContext("2d"),c.encode(G.getImageData(0,0,q,J),L)):b.apply(null,arguments)):b.apply(null,arguments)}}),e("runtime/html5/image",["base","runtime/html5/runtime","runtime/html5/util"],function(u,c,y){var b="data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs%3D";return c.register("Image",{modified:!1,init:function(){var m=this,O=new Image;O.onload=function(){m._info={type:m.type,width:this.width,height:this.height},!m._metas&&m.type==="image/jpeg"?y.parseMeta(m._blob,function(N,L){m._metas=L,m.owner.trigger("load")}):m.owner.trigger("load")},O.onerror=function(){m.owner.trigger("error")},m._img=O},loadFromBlob:function(m){var O=this,N=O._img;O._blob=m,O.type=m.type,N.src=y.createObjectURL(m.getSource()),O.owner.once("load",function(){y.revokeObjectURL(N.src)})},resize:function(m,O){var N=this._canvas||(this._canvas=document.createElement("canvas"));this._resize(this._img,N,m,O),this._blob=null,this.modified=!0,this.owner.trigger("complete","resize")},crop:function(m,O,N,L,G){var q=this._canvas||(this._canvas=document.createElement("canvas")),J=this.options,fe=this._img,ve=fe.naturalWidth,ne=fe.naturalHeight,Ue=this.getOrientation();G=G||1,q.width=N,q.height=L,J.preserveHeaders||this._rotate2Orientaion(q,Ue),this._renderImageToCanvas(q,fe,-m,-O,ve*G,ne*G),this._blob=null,this.modified=!0,this.owner.trigger("complete","crop")},getAsBlob:function(m){var O=this._blob,N=this.options,L;if(m=m||this.type,this.modified||this.type!==m){if(L=this._canvas,m==="image/jpeg"){if(O=y.canvasToDataUrl(L,m,N.quality),N.preserveHeaders&&this._metas&&this._metas.imageHead)return O=y.dataURL2ArrayBuffer(O),O=y.updateImageHead(O,this._metas.imageHead),O=y.arrayBufferToBlob(O,m),O}else O=y.canvasToDataUrl(L,m);O=y.dataURL2Blob(O)}return O},getAsDataUrl:function(m){var O=this.options;return m=m||this.type,m==="image/jpeg"?y.canvasToDataUrl(this._canvas,m,O.quality):this._canvas.toDataURL(m)},getOrientation:function(){return this._metas&&this._metas.exif&&this._metas.exif.get("Orientation")||1},info:function(m){return m?(this._info=m,this):this._info},meta:function(m){return m?(this._metas=m,this):this._metas},destroy:function(){var m=this._canvas;this._img.onload=null,m&&(m.getContext("2d").clearRect(0,0,m.width,m.height),m.width=m.height=0,this._canvas=null),this._img.src=b,this._img=this._blob=null},_resize:function(m,O,N,L){var G=this.options,q=m.width,J=m.height,fe=this.getOrientation(),ve,ne,Ue,De,Ve;~[5,6,7,8].indexOf(fe)&&(N^=L,L^=N,N^=L),ve=Math[G.crop?"max":"min"](N/q,L/J),G.allowMagnify||(ve=Math.min(1,ve)),ne=q*ve,Ue=J*ve,G.crop?(O.width=N,O.height=L):(O.width=ne,O.height=Ue),De=(O.width-ne)/2,Ve=(O.height-Ue)/2,G.preserveHeaders||this._rotate2Orientaion(O,fe),this._renderImageToCanvas(O,m,De,Ve,ne,Ue)},_rotate2Orientaion:function(m,O){var N=m.width,L=m.height,G=m.getContext("2d");switch(O){case 5:case 6:case 7:case 8:m.width=L,m.height=N;break}switch(O){case 2:G.translate(N,0),G.scale(-1,1);break;case 3:G.translate(N,L),G.rotate(Math.PI);break;case 4:G.translate(0,L),G.scale(1,-1);break;case 5:G.rotate(.5*Math.PI),G.scale(1,-1);break;case 6:G.rotate(.5*Math.PI),G.translate(0,-L);break;case 7:G.rotate(.5*Math.PI),G.translate(N,-L),G.scale(-1,1);break;case 8:G.rotate(-.5*Math.PI),G.translate(-N,0);break}},_renderImageToCanvas:function(){if(!u.os.ios)return function(N){var L=u.slice(arguments,1),G=N.getContext("2d");G.drawImage.apply(G,L)};function m(N,L,G){var q=document.createElement("canvas"),J=q.getContext("2d"),fe=0,ve=G,ne=G,Ue,De,Ve;for(q.width=1,q.height=G,J.drawImage(N,0,0),Ue=J.getImageData(0,0,1,G).data;ne>fe;)De=Ue[(ne-1)*4+3],De===0?ve=ne:fe=ne,ne=ve+fe>>1;return Ve=ne/G,Ve===0?1:Ve}if(u.os.ios>=7)return function(N,L,G,q,J,fe){var ve=L.naturalWidth,ne=L.naturalHeight,Ue=m(L,ve,ne);return N.getContext("2d").drawImage(L,0,0,ve*Ue,ne*Ue,G,q,J,fe)};function O(N){var L=N.naturalWidth,G=N.naturalHeight,q,J;return L*G>1024*1024?(q=document.createElement("canvas"),q.width=q.height=1,J=q.getContext("2d"),J.drawImage(N,-L+1,0),J.getImageData(0,0,1,1).data[3]===0):!1}return function(N,L,G,q,J,fe){var ve=L.naturalWidth,ne=L.naturalHeight,Ue=N.getContext("2d"),De=O(L),Ve=this.type==="image/jpeg",rt=1024,Ae=0,Te=0,Xe,ie,ue,pt,mt,Tt,kt;for(De&&(ve/=2,ne/=2),Ue.save(),Xe=document.createElement("canvas"),Xe.width=Xe.height=rt,ie=Xe.getContext("2d"),ue=Ve?m(L,ve,ne):1,pt=Math.ceil(rt*J/ve),mt=Math.ceil(rt*fe/ne/ue);Ae<ne;){for(Tt=0,kt=0;Tt<ve;)ie.clearRect(0,0,rt,rt),ie.drawImage(L,-Tt,-Ae),Ue.drawImage(Xe,0,0,rt,rt,G+kt,q+Te,pt,mt),Tt+=rt,kt+=pt;Ae+=rt,Te+=mt}Ue.restore(),Xe=ie=null}}()})}),e("runtime/html5/transport",["base","runtime/html5/runtime"],function(u,c){var y=u.noop,b=u.$;return c.register("Transport",{init:function(){this._status=0,this._response=null},send:function(){var m=this.owner,O=this.options,N=this._initAjax(),L=m._blob,G=O.server,q,J,fe;O.sendAsBinary?(G+=(/\?/.test(G)?"&":"?")+b.param(m._formData),J=L.getSource()):(q=new FormData,b.each(m._formData,function(ve,ne){q.append(ve,ne)}),q.append(O.fileVal,L.getSource(),O.filename||m._formData.name||"")),O.withCredentials&&"withCredentials"in N?(N.open(O.method,G,!0),N.withCredentials=!0):N.open(O.method,G),this._setRequestHeader(N,O.headers),J?(N.overrideMimeType&&N.overrideMimeType("application/octet-stream"),u.os.android?(fe=new FileReader,fe.onload=function(){N.send(this.result),fe=fe.onload=null},fe.readAsArrayBuffer(J)):N.send(J)):N.send(q)},getResponse:function(){return this._response},getResponseAsJson:function(){return this._parseJson(this._response)},getStatus:function(){return this._status},abort:function(){var m=this._xhr;m&&(m.upload.onprogress=y,m.onreadystatechange=y,m.abort(),this._xhr=m=null)},destroy:function(){this.abort()},_initAjax:function(){var m=this,O=new XMLHttpRequest,N=this.options;return N.withCredentials&&!("withCredentials"in O)&&typeof XDomainRequest<"u"&&(O=new XDomainRequest),O.upload.onprogress=function(L){var G=0;return L.lengthComputable&&(G=L.loaded/L.total),m.trigger("progress",G)},O.onreadystatechange=function(){if(O.readyState===4)return O.upload.onprogress=y,O.onreadystatechange=y,m._xhr=null,m._status=O.status,O.status>=200&&O.status<300?(m._response=O.responseText,m.trigger("load")):O.status>=500&&O.status<600?(m._response=O.responseText,m.trigger("error","server")):m.trigger("error",m._status?"http":"abort")},m._xhr=O,O},_setRequestHeader:function(m,O){b.each(O,function(N,L){m.setRequestHeader(N,L)})},_parseJson:function(m){var O;try{O=JSON.parse(m)}catch{O={}}return O}})}),e("runtime/html5/md5",["runtime/html5/runtime"],function(u){var c=function(rt,Ae){return rt+Ae&4294967295},y=function(rt,Ae,Te,Xe,ie,ue){return Ae=c(c(Ae,rt),c(Xe,ue)),c(Ae<<ie|Ae>>>32-ie,Te)},b=function(rt,Ae,Te,Xe,ie,ue,pt){return y(Ae&Te|~Ae&Xe,rt,Ae,ie,ue,pt)},m=function(rt,Ae,Te,Xe,ie,ue,pt){return y(Ae&Xe|Te&~Xe,rt,Ae,ie,ue,pt)},O=function(rt,Ae,Te,Xe,ie,ue,pt){return y(Ae^Te^Xe,rt,Ae,ie,ue,pt)},N=function(rt,Ae,Te,Xe,ie,ue,pt){return y(Te^(Ae|~Xe),rt,Ae,ie,ue,pt)},L=function(rt,Ae){var Te=rt[0],Xe=rt[1],ie=rt[2],ue=rt[3];Te=b(Te,Xe,ie,ue,Ae[0],7,-680876936),ue=b(ue,Te,Xe,ie,Ae[1],12,-389564586),ie=b(ie,ue,Te,Xe,Ae[2],17,606105819),Xe=b(Xe,ie,ue,Te,Ae[3],22,-1044525330),Te=b(Te,Xe,ie,ue,Ae[4],7,-176418897),ue=b(ue,Te,Xe,ie,Ae[5],12,1200080426),ie=b(ie,ue,Te,Xe,Ae[6],17,-1473231341),Xe=b(Xe,ie,ue,Te,Ae[7],22,-45705983),Te=b(Te,Xe,ie,ue,Ae[8],7,1770035416),ue=b(ue,Te,Xe,ie,Ae[9],12,-1958414417),ie=b(ie,ue,Te,Xe,Ae[10],17,-42063),Xe=b(Xe,ie,ue,Te,Ae[11],22,-1990404162),Te=b(Te,Xe,ie,ue,Ae[12],7,1804603682),ue=b(ue,Te,Xe,ie,Ae[13],12,-40341101),ie=b(ie,ue,Te,Xe,Ae[14],17,-1502002290),Xe=b(Xe,ie,ue,Te,Ae[15],22,1236535329),Te=m(Te,Xe,ie,ue,Ae[1],5,-165796510),ue=m(ue,Te,Xe,ie,Ae[6],9,-1069501632),ie=m(ie,ue,Te,Xe,Ae[11],14,643717713),Xe=m(Xe,ie,ue,Te,Ae[0],20,-373897302),Te=m(Te,Xe,ie,ue,Ae[5],5,-701558691),ue=m(ue,Te,Xe,ie,Ae[10],9,38016083),ie=m(ie,ue,Te,Xe,Ae[15],14,-660478335),Xe=m(Xe,ie,ue,Te,Ae[4],20,-405537848),Te=m(Te,Xe,ie,ue,Ae[9],5,568446438),ue=m(ue,Te,Xe,ie,Ae[14],9,-1019803690),ie=m(ie,ue,Te,Xe,Ae[3],14,-187363961),Xe=m(Xe,ie,ue,Te,Ae[8],20,1163531501),Te=m(Te,Xe,ie,ue,Ae[13],5,-1444681467),ue=m(ue,Te,Xe,ie,Ae[2],9,-51403784),ie=m(ie,ue,Te,Xe,Ae[7],14,1735328473),Xe=m(Xe,ie,ue,Te,Ae[12],20,-1926607734),Te=O(Te,Xe,ie,ue,Ae[5],4,-378558),ue=O(ue,Te,Xe,ie,Ae[8],11,-2022574463),ie=O(ie,ue,Te,Xe,Ae[11],16,1839030562),Xe=O(Xe,ie,ue,Te,Ae[14],23,-35309556),Te=O(Te,Xe,ie,ue,Ae[1],4,-1530992060),ue=O(ue,Te,Xe,ie,Ae[4],11,1272893353),ie=O(ie,ue,Te,Xe,Ae[7],16,-155497632),Xe=O(Xe,ie,ue,Te,Ae[10],23,-1094730640),Te=O(Te,Xe,ie,ue,Ae[13],4,681279174),ue=O(ue,Te,Xe,ie,Ae[0],11,-358537222),ie=O(ie,ue,Te,Xe,Ae[3],16,-722521979),Xe=O(Xe,ie,ue,Te,Ae[6],23,76029189),Te=O(Te,Xe,ie,ue,Ae[9],4,-640364487),ue=O(ue,Te,Xe,ie,Ae[12],11,-421815835),ie=O(ie,ue,Te,Xe,Ae[15],16,530742520),Xe=O(Xe,ie,ue,Te,Ae[2],23,-995338651),Te=N(Te,Xe,ie,ue,Ae[0],6,-198630844),ue=N(ue,Te,Xe,ie,Ae[7],10,1126891415),ie=N(ie,ue,Te,Xe,Ae[14],15,-1416354905),Xe=N(Xe,ie,ue,Te,Ae[5],21,-57434055),Te=N(Te,Xe,ie,ue,Ae[12],6,1700485571),ue=N(ue,Te,Xe,ie,Ae[3],10,-1894986606),ie=N(ie,ue,Te,Xe,Ae[10],15,-1051523),Xe=N(Xe,ie,ue,Te,Ae[1],21,-2054922799),Te=N(Te,Xe,ie,ue,Ae[8],6,1873313359),ue=N(ue,Te,Xe,ie,Ae[15],10,-30611744),ie=N(ie,ue,Te,Xe,Ae[6],15,-1560198380),Xe=N(Xe,ie,ue,Te,Ae[13],21,1309151649),Te=N(Te,Xe,ie,ue,Ae[4],6,-145523070),ue=N(ue,Te,Xe,ie,Ae[11],10,-1120210379),ie=N(ie,ue,Te,Xe,Ae[2],15,718787259),Xe=N(Xe,ie,ue,Te,Ae[9],21,-343485551),rt[0]=c(Te,rt[0]),rt[1]=c(Xe,rt[1]),rt[2]=c(ie,rt[2]),rt[3]=c(ue,rt[3])},G=function(rt){var Ae=[],Te;for(Te=0;Te<64;Te+=4)Ae[Te>>2]=rt.charCodeAt(Te)+(rt.charCodeAt(Te+1)<<8)+(rt.charCodeAt(Te+2)<<16)+(rt.charCodeAt(Te+3)<<24);return Ae},q=function(rt){var Ae=[],Te;for(Te=0;Te<64;Te+=4)Ae[Te>>2]=rt[Te]+(rt[Te+1]<<8)+(rt[Te+2]<<16)+(rt[Te+3]<<24);return Ae},J=function(rt){var Ae=rt.length,Te=[1732584193,-271733879,-1732584194,271733878],Xe,ie,ue,pt,mt,Tt;for(Xe=64;Xe<=Ae;Xe+=64)L(Te,G(rt.substring(Xe-64,Xe)));for(rt=rt.substring(Xe-64),ie=rt.length,ue=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],Xe=0;Xe<ie;Xe+=1)ue[Xe>>2]|=rt.charCodeAt(Xe)<<(Xe%4<<3);if(ue[Xe>>2]|=128<<(Xe%4<<3),Xe>55)for(L(Te,ue),Xe=0;Xe<16;Xe+=1)ue[Xe]=0;return pt=Ae*8,pt=pt.toString(16).match(/(.*?)(.{0,8})$/),mt=parseInt(pt[2],16),Tt=parseInt(pt[1],16)||0,ue[14]=mt,ue[15]=Tt,L(Te,ue),Te},fe=function(rt){var Ae=rt.length,Te=[1732584193,-271733879,-1732584194,271733878],Xe,ie,ue,pt,mt,Tt;for(Xe=64;Xe<=Ae;Xe+=64)L(Te,q(rt.subarray(Xe-64,Xe)));for(rt=Xe-64<Ae?rt.subarray(Xe-64):new Uint8Array(0),ie=rt.length,ue=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],Xe=0;Xe<ie;Xe+=1)ue[Xe>>2]|=rt[Xe]<<(Xe%4<<3);if(ue[Xe>>2]|=128<<(Xe%4<<3),Xe>55)for(L(Te,ue),Xe=0;Xe<16;Xe+=1)ue[Xe]=0;return pt=Ae*8,pt=pt.toString(16).match(/(.*?)(.{0,8})$/),mt=parseInt(pt[2],16),Tt=parseInt(pt[1],16)||0,ue[14]=mt,ue[15]=Tt,L(Te,ue),Te},ve=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],ne=function(rt){var Ae="",Te;for(Te=0;Te<4;Te+=1)Ae+=ve[rt>>Te*8+4&15]+ve[rt>>Te*8&15];return Ae},Ue=function(rt){var Ae;for(Ae=0;Ae<rt.length;Ae+=1)rt[Ae]=ne(rt[Ae]);return rt.join("")},De=function(rt){return Ue(J(rt))},Ve=function(){this.reset()};return De("hello")!=="5d41402abc4b2a76b9719d911017c592"&&(c=function(rt,Ae){var Te=(rt&65535)+(Ae&65535),Xe=(rt>>16)+(Ae>>16)+(Te>>16);return Xe<<16|Te&65535}),Ve.prototype.append=function(rt){return/[\u0080-\uFFFF]/.test(rt)&&(rt=unescape(encodeURIComponent(rt))),this.appendBinary(rt),this},Ve.prototype.appendBinary=function(rt){this._buff+=rt,this._length+=rt.length;var Ae=this._buff.length,Te;for(Te=64;Te<=Ae;Te+=64)L(this._state,G(this._buff.substring(Te-64,Te)));return this._buff=this._buff.substr(Te-64),this},Ve.prototype.end=function(rt){var Ae=this._buff,Te=Ae.length,Xe,ie=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],ue;for(Xe=0;Xe<Te;Xe+=1)ie[Xe>>2]|=Ae.charCodeAt(Xe)<<(Xe%4<<3);return this._finish(ie,Te),ue=rt?this._state:Ue(this._state),this.reset(),ue},Ve.prototype._finish=function(rt,Ae){var Te=Ae,Xe,ie,ue;if(rt[Te>>2]|=128<<(Te%4<<3),Te>55)for(L(this._state,rt),Te=0;Te<16;Te+=1)rt[Te]=0;Xe=this._length*8,Xe=Xe.toString(16).match(/(.*?)(.{0,8})$/),ie=parseInt(Xe[2],16),ue=parseInt(Xe[1],16)||0,rt[14]=ie,rt[15]=ue,L(this._state,rt)},Ve.prototype.reset=function(){return this._buff="",this._length=0,this._state=[1732584193,-271733879,-1732584194,271733878],this},Ve.prototype.destroy=function(){delete this._state,delete this._buff,delete this._length},Ve.hash=function(rt,Ae){/[\u0080-\uFFFF]/.test(rt)&&(rt=unescape(encodeURIComponent(rt)));var Te=J(rt);return Ae?Te:Ue(Te)},Ve.hashBinary=function(rt,Ae){var Te=J(rt);return Ae?Te:Ue(Te)},Ve.ArrayBuffer=function(){this.reset()},Ve.ArrayBuffer.prototype.append=function(rt){var Ae=this._concatArrayBuffer(this._buff,rt),Te=Ae.length,Xe;for(this._length+=rt.byteLength,Xe=64;Xe<=Te;Xe+=64)L(this._state,q(Ae.subarray(Xe-64,Xe)));return this._buff=Xe-64<Te?Ae.subarray(Xe-64):new Uint8Array(0),this},Ve.ArrayBuffer.prototype.end=function(rt){var Ae=this._buff,Te=Ae.length,Xe=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],ie,ue;for(ie=0;ie<Te;ie+=1)Xe[ie>>2]|=Ae[ie]<<(ie%4<<3);return this._finish(Xe,Te),ue=rt?this._state:Ue(this._state),this.reset(),ue},Ve.ArrayBuffer.prototype._finish=Ve.prototype._finish,Ve.ArrayBuffer.prototype.reset=function(){return this._buff=new Uint8Array(0),this._length=0,this._state=[1732584193,-271733879,-1732584194,271733878],this},Ve.ArrayBuffer.prototype.destroy=Ve.prototype.destroy,Ve.ArrayBuffer.prototype._concatArrayBuffer=function(rt,Ae){var Te=rt.length,Xe=new Uint8Array(Te+Ae.byteLength);return Xe.set(rt),Xe.set(new Uint8Array(Ae),Te),Xe},Ve.ArrayBuffer.hash=function(rt,Ae){var Te=fe(new Uint8Array(rt));return Ae?Te:Ue(Te)},u.register("Md5",{init:function(){},loadFromBlob:function(rt){var Ae=rt.getSource(),Te=2*1024*1024,Xe=Math.ceil(Ae.size/Te),ie=0,ue=this.owner,pt=new Ve.ArrayBuffer,mt=this,Tt=Ae.mozSlice||Ae.webkitSlice||Ae.slice,kt,It;It=new FileReader,kt=function(){var nn,tn;nn=ie*Te,tn=Math.min(nn+Te,Ae.size),It.onload=function(pn){pt.append(pn.target.result),ue.trigger("progress",{total:rt.size,loaded:tn})},It.onloadend=function(){It.onloadend=It.onload=null,++ie<Xe?setTimeout(kt,1):setTimeout(function(){ue.trigger("load"),mt.result=pt.end(),kt=rt=Ae=pt=null,ue.trigger("complete")},50)},It.readAsArrayBuffer(Tt.call(Ae,nn,tn))},kt()},getResult:function(){return this.result}})}),e("runtime/flash/runtime",["base","runtime/runtime","runtime/compbase"],function(u,c,y){var b=u.$,m="flash",O={};function N(){var G;try{G=navigator.plugins["Shockwave Flash"],G=G.description}catch{try{G=new ActiveXObject("ShockwaveFlash.ShockwaveFlash").GetVariable("$version")}catch{G="0.0"}}return G=G.match(/\d+/g),parseFloat(G[0]+"."+G[1],10)}function L(){var G={},q={},J=this.destroy,fe=this,ve=u.guid("webuploader_");c.apply(fe,arguments),fe.type=m,fe.exec=function(Ue,De){var Ve=this,rt=Ve.uid,Ae=u.slice(arguments,2),Te;return q[rt]=Ve,O[Ue]&&(G[rt]||(G[rt]=new O[Ue](Ve,fe)),Te=G[rt],Te[De])?Te[De].apply(Te,Ae):fe.flashExec.apply(Ve,arguments)};function ne(Ue,De){var Ve=Ue.type||Ue,rt,Ae;rt=Ve.split("::"),Ae=rt[0],Ve=rt[1],Ve==="Ready"&&Ae===fe.uid?fe.trigger("ready"):q[Ae]&&q[Ae].trigger(Ve.toLowerCase(),Ue,De)}t[ve]=function(){var Ue=arguments;setTimeout(function(){ne.apply(null,Ue)},1)},this.jsreciver=ve,this.destroy=function(){return J&&J.apply(this,arguments)},this.flashExec=function(Ue,De){var Ve=fe.getFlash(),rt=u.slice(arguments,2);return Ve.exec(this.uid,Ue,De,rt)}}return u.inherits(c,{constructor:L,init:function(){var G=this.getContainer(),q=this.options,J;G.css({position:"absolute",top:"-8px",left:"-8px",width:"9px",height:"9px",overflow:"hidden"}),J='<object id="'+this.uid+'" type="application/x-shockwave-flash" data="'+q.swf+'" ',u.browser.ie&&(J+='classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" '),J+='width="100%" height="100%" style="outline:0"><param name="movie" value="'+q.swf+'" /><param name="flashvars" value="uid='+this.uid+"&jsreciver="+this.jsreciver+'" /><param name="wmode" value="transparent" /><param name="allowscriptaccess" value="always" /></object>',G.html(J)},getFlash:function(){return this._flash?this._flash:(this._flash=b("#"+this.uid).get(0),this._flash)}}),L.register=function(G,q){return q=O[G]=u.inherits(y,b.extend({flashExec:function(){var J=this.owner,fe=this.getRuntime();return fe.flashExec.apply(J,arguments)}},q)),q},N()>=11.4&&c.addRuntime(m,L),L}),e("runtime/flash/filepicker",["base","runtime/flash/runtime"],function(u,c){var y=u.$;return c.register("FilePicker",{init:function(b){var m=y.extend({},b),O,N;for(O=m.accept&&m.accept.length,N=0;N<O;N++)m.accept[N].title||(m.accept[N].title="Files");delete m.button,delete m.id,delete m.container,this.flashExec("FilePicker","init",m)},destroy:function(){this.flashExec("FilePicker","destroy")}})}),e("runtime/flash/image",["runtime/flash/runtime"],function(u){return u.register("Image",{loadFromBlob:function(c){var y=this.owner;y.info()&&this.flashExec("Image","info",y.info()),y.meta()&&this.flashExec("Image","meta",y.meta()),this.flashExec("Image","loadFromBlob",c.uid)}})}),e("runtime/flash/transport",["base","runtime/flash/runtime","runtime/client"],function(u,c,y){var b=u.$;return c.register("Transport",{init:function(){this._status=0,this._response=null,this._responseJson=null},send:function(){var m=this.owner,O=this.options,N=this._initAjax(),L=m._blob,G=O.server,q;N.connectRuntime(L.ruid),O.sendAsBinary?(G+=(/\?/.test(G)?"&":"?")+b.param(m._formData),q=L.uid):(b.each(m._formData,function(J,fe){N.exec("append",J,fe)}),N.exec("appendBlob",O.fileVal,L.uid,O.filename||m._formData.name||"")),this._setRequestHeader(N,O.headers),N.exec("send",{method:O.method,url:G,forceURLStream:O.forceURLStream,mimeType:"application/octet-stream"},q)},getStatus:function(){return this._status},getResponse:function(){return this._response||""},getResponseAsJson:function(){return this._responseJson},abort:function(){var m=this._xhr;m&&(m.exec("abort"),m.destroy(),this._xhr=m=null)},destroy:function(){this.abort()},_initAjax:function(){var m=this,O=new y("XMLHttpRequest");return O.on("uploadprogress progress",function(N){var L=N.loaded/N.total;return L=Math.min(1,Math.max(0,L)),m.trigger("progress",L)}),O.on("load",function(){var N=O.exec("getStatus"),L=!1,G="",q;return O.off(),m._xhr=null,N>=200&&N<300?L=!0:N>=500&&N<600?(L=!0,G="server"):G="http",L&&(m._response=O.exec("getResponse"),m._response=decodeURIComponent(m._response),q=function(J){try{return t.JSON&&t.JSON.parse?JSON.parse(J):new Function("return "+J).call()}catch{return{}}},m._responseJson=m._response?q(m._response):{}),O.destroy(),O=null,G?m.trigger("error",G):m.trigger("load")}),O.on("error",function(){O.off(),m._xhr=null,m.trigger("error","http")}),m._xhr=O,O},_setRequestHeader:function(m,O){b.each(O,function(N,L){m.exec("setRequestHeader",N,L)})}})}),e("runtime/flash/blob",["runtime/flash/runtime","lib/blob"],function(u,c){return u.register("Blob",{slice:function(y,b){var m=this.flashExec("Blob","slice",y,b);return new c(this.getRuid(),m)}})}),e("runtime/flash/md5",["runtime/flash/runtime"],function(u){return u.register("Md5",{init:function(){},loadFromBlob:function(c){return this.flashExec("Md5","loadFromBlob",c.uid)}})}),e("preset/all",["base","widgets/filednd","widgets/filepaste","widgets/filepicker","widgets/image","widgets/queue","widgets/runtime","widgets/upload","widgets/validator","widgets/md5","runtime/html5/blob","runtime/html5/dnd","runtime/html5/filepaste","runtime/html5/filepicker","runtime/html5/imagemeta/exif","runtime/html5/androidpatch","runtime/html5/image","runtime/html5/transport","runtime/html5/md5","runtime/flash/filepicker","runtime/flash/image","runtime/flash/transport","runtime/flash/blob","runtime/flash/md5"],function(u){return u}),e("widgets/log",["base","uploader","widgets/widget"],function(u,c){var y=u.$,b=" http://static.tieba.baidu.com/tb/pms/img/st.gif??",m=(location.hostname||location.host||"protected").toLowerCase(),O=m&&/baidu/i.exec(m),N;if(!O)return;N={dv:3,master:"webuploader",online:/test/.exec(m)?0:1,module:"",product:m,type:0};function L(G){var q=y.extend({},N,G),J=b.replace(/^(.*)\?/,"$1"+y.param(q)),fe=new Image;fe.src=J}return c.register({name:"log",init:function(){var G=this.owner,q=0,J=0;G.on("error",function(fe){L({type:2,c_error_code:fe})}).on("uploadError",function(fe,ve){L({type:2,c_error_code:"UPLOAD_ERROR",c_reason:""+ve})}).on("uploadComplete",function(fe){q++,J+=fe.size}).on("uploadFinished",function(){L({c_count:q,c_size:J}),q=J=0}),L({c_usage:1})}})}),e("webuploader",["preset/all","widgets/log"],function(u){return u});var n=l;return n("webuploader")});const WebUploader=getDefaultExportFromCjs(webuploader_fis);function bind(t,e){return function(){return t.apply(e,arguments)}}const{toString}=Object.prototype,{getPrototypeOf}=Object,kindOf=(t=>e=>{const l=toString.call(e);return t[l]||(t[l]=l.slice(8,-1).toLowerCase())})(Object.create(null)),kindOfTest=t=>(t=t.toLowerCase(),e=>kindOf(e)===t),typeOfTest=t=>e=>typeof e===t,{isArray:isArray$1}=Array,isUndefined=typeOfTest("undefined");function isBuffer(t){return t!==null&&!isUndefined(t)&&t.constructor!==null&&!isUndefined(t.constructor)&&isFunction(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const isArrayBuffer=kindOfTest("ArrayBuffer");function isArrayBufferView(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&isArrayBuffer(t.buffer),e}const isString=typeOfTest("string"),isFunction=typeOfTest("function"),isNumber=typeOfTest("number"),isObject=t=>t!==null&&typeof t=="object",isBoolean=t=>t===!0||t===!1,isPlainObject=t=>{if(kindOf(t)!=="object")return!1;const e=getPrototypeOf(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in t)&&!(Symbol.iterator in t)},isDate=kindOfTest("Date"),isFile=kindOfTest("File"),isBlob=kindOfTest("Blob"),isFileList=kindOfTest("FileList"),isStream=t=>isObject(t)&&isFunction(t.pipe),isFormData=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||isFunction(t.append)&&((e=kindOf(t))==="formdata"||e==="object"&&isFunction(t.toString)&&t.toString()==="[object FormData]"))},isURLSearchParams=kindOfTest("URLSearchParams"),[isReadableStream,isRequest,isResponse,isHeaders]=["ReadableStream","Request","Response","Headers"].map(kindOfTest),trim=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function forEach(t,e,{allOwnKeys:l=!1}={}){if(t===null||typeof t>"u")return;let n,u;if(typeof t!="object"&&(t=[t]),isArray$1(t))for(n=0,u=t.length;n<u;n++)e.call(null,t[n],n,t);else{const c=l?Object.getOwnPropertyNames(t):Object.keys(t),y=c.length;let b;for(n=0;n<y;n++)b=c[n],e.call(null,t[b],b,t)}}function findKey(t,e){e=e.toLowerCase();const l=Object.keys(t);let n=l.length,u;for(;n-- >0;)if(u=l[n],e===u.toLowerCase())return u;return null}const _global=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,isContextDefined=t=>!isUndefined(t)&&t!==_global;function merge(){const{caseless:t}=isContextDefined(this)&&this||{},e={},l=(n,u)=>{const c=t&&findKey(e,u)||u;isPlainObject(e[c])&&isPlainObject(n)?e[c]=merge(e[c],n):isPlainObject(n)?e[c]=merge({},n):isArray$1(n)?e[c]=n.slice():e[c]=n};for(let n=0,u=arguments.length;n<u;n++)arguments[n]&&forEach(arguments[n],l);return e}const extend=(t,e,l,{allOwnKeys:n}={})=>(forEach(e,(u,c)=>{l&&isFunction(u)?t[c]=bind(u,l):t[c]=u},{allOwnKeys:n}),t),stripBOM=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),inherits=(t,e,l,n)=>{t.prototype=Object.create(e.prototype,n),t.prototype.constructor=t,Object.defineProperty(t,"super",{value:e.prototype}),l&&Object.assign(t.prototype,l)},toFlatObject=(t,e,l,n)=>{let u,c,y;const b={};if(e=e||{},t==null)return e;do{for(u=Object.getOwnPropertyNames(t),c=u.length;c-- >0;)y=u[c],(!n||n(y,t,e))&&!b[y]&&(e[y]=t[y],b[y]=!0);t=l!==!1&&getPrototypeOf(t)}while(t&&(!l||l(t,e))&&t!==Object.prototype);return e},endsWith=(t,e,l)=>{t=String(t),(l===void 0||l>t.length)&&(l=t.length),l-=e.length;const n=t.indexOf(e,l);return n!==-1&&n===l},toArray=t=>{if(!t)return null;if(isArray$1(t))return t;let e=t.length;if(!isNumber(e))return null;const l=new Array(e);for(;e-- >0;)l[e]=t[e];return l},isTypedArray=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&getPrototypeOf(Uint8Array)),forEachEntry=(t,e)=>{const n=(t&&t[Symbol.iterator]).call(t);let u;for(;(u=n.next())&&!u.done;){const c=u.value;e.call(t,c[0],c[1])}},matchAll=(t,e)=>{let l;const n=[];for(;(l=t.exec(e))!==null;)n.push(l);return n},isHTMLForm=kindOfTest("HTMLFormElement"),toCamelCase=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(l,n,u){return n.toUpperCase()+u}),hasOwnProperty=(({hasOwnProperty:t})=>(e,l)=>t.call(e,l))(Object.prototype),isRegExp=kindOfTest("RegExp"),reduceDescriptors=(t,e)=>{const l=Object.getOwnPropertyDescriptors(t),n={};forEach(l,(u,c)=>{let y;(y=e(u,c,t))!==!1&&(n[c]=y||u)}),Object.defineProperties(t,n)},freezeMethods=t=>{reduceDescriptors(t,(e,l)=>{if(isFunction(t)&&["arguments","caller","callee"].indexOf(l)!==-1)return!1;const n=t[l];if(isFunction(n)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+l+"'")})}})},toObjectSet=(t,e)=>{const l={},n=u=>{u.forEach(c=>{l[c]=!0})};return isArray$1(t)?n(t):n(String(t).split(e)),l},noop=()=>{},toFiniteNumber=(t,e)=>t!=null&&Number.isFinite(t=+t)?t:e,ALPHA="abcdefghijklmnopqrstuvwxyz",DIGIT="0123456789",ALPHABET={DIGIT,ALPHA,ALPHA_DIGIT:ALPHA+ALPHA.toUpperCase()+DIGIT},generateString=(t=16,e=ALPHABET.ALPHA_DIGIT)=>{let l="";const{length:n}=e;for(;t--;)l+=e[Math.random()*n|0];return l};function isSpecCompliantForm(t){return!!(t&&isFunction(t.append)&&t[Symbol.toStringTag]==="FormData"&&t[Symbol.iterator])}const toJSONObject=t=>{const e=new Array(10),l=(n,u)=>{if(isObject(n)){if(e.indexOf(n)>=0)return;if(!("toJSON"in n)){e[u]=n;const c=isArray$1(n)?[]:{};return forEach(n,(y,b)=>{const m=l(y,u+1);!isUndefined(m)&&(c[b]=m)}),e[u]=void 0,c}}return n};return l(t,0)},isAsyncFn=kindOfTest("AsyncFunction"),isThenable=t=>t&&(isObject(t)||isFunction(t))&&isFunction(t.then)&&isFunction(t.catch),utils$1={isArray:isArray$1,isArrayBuffer,isBuffer,isFormData,isArrayBufferView,isString,isNumber,isBoolean,isObject,isPlainObject,isReadableStream,isRequest,isResponse,isHeaders,isUndefined,isDate,isFile,isBlob,isRegExp,isFunction,isStream,isURLSearchParams,isTypedArray,isFileList,forEach,merge,extend,trim,stripBOM,inherits,toFlatObject,kindOf,kindOfTest,endsWith,toArray,forEachEntry,matchAll,isHTMLForm,hasOwnProperty,hasOwnProp:hasOwnProperty,reduceDescriptors,freezeMethods,toObjectSet,toCamelCase,noop,toFiniteNumber,findKey,global:_global,isContextDefined,ALPHABET,generateString,isSpecCompliantForm,toJSONObject,isAsyncFn,isThenable};function AxiosError(t,e,l,n,u){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=t,this.name="AxiosError",e&&(this.code=e),l&&(this.config=l),n&&(this.request=n),u&&(this.response=u)}utils$1.inherits(AxiosError,Error,{toJSON:function t(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:utils$1.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const prototype$1=AxiosError.prototype,descriptors={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(t=>{descriptors[t]={value:t}});Object.defineProperties(AxiosError,descriptors);Object.defineProperty(prototype$1,"isAxiosError",{value:!0});AxiosError.from=(t,e,l,n,u,c)=>{const y=Object.create(prototype$1);return utils$1.toFlatObject(t,y,function(m){return m!==Error.prototype},b=>b!=="isAxiosError"),AxiosError.call(y,t.message,e,l,n,u),y.cause=t,y.name=t.name,c&&Object.assign(y,c),y};const httpAdapter=null;function isVisitable(t){return utils$1.isPlainObject(t)||utils$1.isArray(t)}function removeBrackets(t){return utils$1.endsWith(t,"[]")?t.slice(0,-2):t}function renderKey(t,e,l){return t?t.concat(e).map(function(u,c){return u=removeBrackets(u),!l&&c?"["+u+"]":u}).join(l?".":""):e}function isFlatArray(t){return utils$1.isArray(t)&&!t.some(isVisitable)}const predicates=utils$1.toFlatObject(utils$1,{},null,function t(e){return/^is[A-Z]/.test(e)});function toFormData(t,e,l){if(!utils$1.isObject(t))throw new TypeError("target must be an object");e=e||new FormData,l=utils$1.toFlatObject(l,{metaTokens:!0,dots:!1,indexes:!1},!1,function(fe,ve){return!utils$1.isUndefined(ve[fe])});const n=l.metaTokens,u=l.visitor||N,c=l.dots,y=l.indexes,m=(l.Blob||typeof Blob<"u"&&Blob)&&utils$1.isSpecCompliantForm(e);if(!utils$1.isFunction(u))throw new TypeError("visitor must be a function");function O(J){if(J===null)return"";if(utils$1.isDate(J))return J.toISOString();if(!m&&utils$1.isBlob(J))throw new AxiosError("Blob is not supported. Use a Buffer instead.");return utils$1.isArrayBuffer(J)||utils$1.isTypedArray(J)?m&&typeof Blob=="function"?new Blob([J]):Buffer.from(J):J}function N(J,fe,ve){let ne=J;if(J&&!ve&&typeof J=="object"){if(utils$1.endsWith(fe,"{}"))fe=n?fe:fe.slice(0,-2),J=JSON.stringify(J);else if(utils$1.isArray(J)&&isFlatArray(J)||(utils$1.isFileList(J)||utils$1.endsWith(fe,"[]"))&&(ne=utils$1.toArray(J)))return fe=removeBrackets(fe),ne.forEach(function(De,Ve){!(utils$1.isUndefined(De)||De===null)&&e.append(y===!0?renderKey([fe],Ve,c):y===null?fe:fe+"[]",O(De))}),!1}return isVisitable(J)?!0:(e.append(renderKey(ve,fe,c),O(J)),!1)}const L=[],G=Object.assign(predicates,{defaultVisitor:N,convertValue:O,isVisitable});function q(J,fe){if(!utils$1.isUndefined(J)){if(L.indexOf(J)!==-1)throw Error("Circular reference detected in "+fe.join("."));L.push(J),utils$1.forEach(J,function(ne,Ue){(!(utils$1.isUndefined(ne)||ne===null)&&u.call(e,ne,utils$1.isString(Ue)?Ue.trim():Ue,fe,G))===!0&&q(ne,fe?fe.concat(Ue):[Ue])}),L.pop()}}if(!utils$1.isObject(t))throw new TypeError("data must be an object");return q(t),e}function encode$1(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(n){return e[n]})}function AxiosURLSearchParams(t,e){this._pairs=[],t&&toFormData(t,this,e)}const prototype=AxiosURLSearchParams.prototype;prototype.append=function t(e,l){this._pairs.push([e,l])};prototype.toString=function t(e){const l=e?function(n){return e.call(this,n,encode$1)}:encode$1;return this._pairs.map(function(u){return l(u[0])+"="+l(u[1])},"").join("&")};function encode(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function buildURL(t,e,l){if(!e)return t;const n=l&&l.encode||encode,u=l&&l.serialize;let c;if(u?c=u(e,l):c=utils$1.isURLSearchParams(e)?e.toString():new AxiosURLSearchParams(e,l).toString(n),c){const y=t.indexOf("#");y!==-1&&(t=t.slice(0,y)),t+=(t.indexOf("?")===-1?"?":"&")+c}return t}class InterceptorManager{constructor(){this.handlers=[]}use(e,l,n){return this.handlers.push({fulfilled:e,rejected:l,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){utils$1.forEach(this.handlers,function(n){n!==null&&e(n)})}}const transitionalDefaults={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},URLSearchParams$1=typeof URLSearchParams<"u"?URLSearchParams:AxiosURLSearchParams,FormData$1=typeof FormData<"u"?FormData:null,Blob$1=typeof Blob<"u"?Blob:null,platform$1={isBrowser:!0,classes:{URLSearchParams:URLSearchParams$1,FormData:FormData$1,Blob:Blob$1},protocols:["http","https","file","blob","url","data"]},hasBrowserEnv=typeof window<"u"&&typeof document<"u",hasStandardBrowserEnv=(t=>hasBrowserEnv&&["ReactNative","NativeScript","NS"].indexOf(t)<0)(typeof navigator<"u"&&navigator.product),hasStandardBrowserWebWorkerEnv=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",origin=hasBrowserEnv&&window.location.href||"http://localhost",utils=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv,hasStandardBrowserEnv,hasStandardBrowserWebWorkerEnv,origin},Symbol.toStringTag,{value:"Module"})),platform={...utils,...platform$1};function toURLEncodedForm(t,e){return toFormData(t,new platform.classes.URLSearchParams,Object.assign({visitor:function(l,n,u,c){return platform.isNode&&utils$1.isBuffer(l)?(this.append(n,l.toString("base64")),!1):c.defaultVisitor.apply(this,arguments)}},e))}function parsePropPath(t){return utils$1.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function arrayToObject(t){const e={},l=Object.keys(t);let n;const u=l.length;let c;for(n=0;n<u;n++)c=l[n],e[c]=t[c];return e}function formDataToJSON(t){function e(l,n,u,c){let y=l[c++];if(y==="__proto__")return!0;const b=Number.isFinite(+y),m=c>=l.length;return y=!y&&utils$1.isArray(u)?u.length:y,m?(utils$1.hasOwnProp(u,y)?u[y]=[u[y],n]:u[y]=n,!b):((!u[y]||!utils$1.isObject(u[y]))&&(u[y]=[]),e(l,n,u[y],c)&&utils$1.isArray(u[y])&&(u[y]=arrayToObject(u[y])),!b)}if(utils$1.isFormData(t)&&utils$1.isFunction(t.entries)){const l={};return utils$1.forEachEntry(t,(n,u)=>{e(parsePropPath(n),u,l,0)}),l}return null}function stringifySafely(t,e,l){if(utils$1.isString(t))try{return(e||JSON.parse)(t),utils$1.trim(t)}catch(n){if(n.name!=="SyntaxError")throw n}return(0,JSON.stringify)(t)}const defaults={transitional:transitionalDefaults,adapter:["xhr","http","fetch"],transformRequest:[function t(e,l){const n=l.getContentType()||"",u=n.indexOf("application/json")>-1,c=utils$1.isObject(e);if(c&&utils$1.isHTMLForm(e)&&(e=new FormData(e)),utils$1.isFormData(e))return u?JSON.stringify(formDataToJSON(e)):e;if(utils$1.isArrayBuffer(e)||utils$1.isBuffer(e)||utils$1.isStream(e)||utils$1.isFile(e)||utils$1.isBlob(e)||utils$1.isReadableStream(e))return e;if(utils$1.isArrayBufferView(e))return e.buffer;if(utils$1.isURLSearchParams(e))return l.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let b;if(c){if(n.indexOf("application/x-www-form-urlencoded")>-1)return toURLEncodedForm(e,this.formSerializer).toString();if((b=utils$1.isFileList(e))||n.indexOf("multipart/form-data")>-1){const m=this.env&&this.env.FormData;return toFormData(b?{"files[]":e}:e,m&&new m,this.formSerializer)}}return c||u?(l.setContentType("application/json",!1),stringifySafely(e)):e}],transformResponse:[function t(e){const l=this.transitional||defaults.transitional,n=l&&l.forcedJSONParsing,u=this.responseType==="json";if(utils$1.isResponse(e)||utils$1.isReadableStream(e))return e;if(e&&utils$1.isString(e)&&(n&&!this.responseType||u)){const y=!(l&&l.silentJSONParsing)&&u;try{return JSON.parse(e)}catch(b){if(y)throw b.name==="SyntaxError"?AxiosError.from(b,AxiosError.ERR_BAD_RESPONSE,this,null,this.response):b}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:platform.classes.FormData,Blob:platform.classes.Blob},validateStatus:function t(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};utils$1.forEach(["delete","get","head","post","put","patch"],t=>{defaults.headers[t]={}});const ignoreDuplicateOf=utils$1.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),parseHeaders=t=>{const e={};let l,n,u;return t&&t.split(`
- `).forEach(function(y){u=y.indexOf(":"),l=y.substring(0,u).trim().toLowerCase(),n=y.substring(u+1).trim(),!(!l||e[l]&&ignoreDuplicateOf[l])&&(l==="set-cookie"?e[l]?e[l].push(n):e[l]=[n]:e[l]=e[l]?e[l]+", "+n:n)}),e},$internals=Symbol("internals");function normalizeHeader(t){return t&&String(t).trim().toLowerCase()}function normalizeValue(t){return t===!1||t==null?t:utils$1.isArray(t)?t.map(normalizeValue):String(t)}function parseTokens(t){const e=Object.create(null),l=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=l.exec(t);)e[n[1]]=n[2];return e}const isValidHeaderName=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function matchHeaderValue(t,e,l,n,u){if(utils$1.isFunction(n))return n.call(this,e,l);if(u&&(e=l),!!utils$1.isString(e)){if(utils$1.isString(n))return e.indexOf(n)!==-1;if(utils$1.isRegExp(n))return n.test(e)}}function formatHeader(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,l,n)=>l.toUpperCase()+n)}function buildAccessors(t,e){const l=utils$1.toCamelCase(" "+e);["get","set","has"].forEach(n=>{Object.defineProperty(t,n+l,{value:function(u,c,y){return this[n].call(this,e,u,c,y)},configurable:!0})})}class AxiosHeaders{constructor(e){e&&this.set(e)}set(e,l,n){const u=this;function c(b,m,O){const N=normalizeHeader(m);if(!N)throw new Error("header name must be a non-empty string");const L=utils$1.findKey(u,N);(!L||u[L]===void 0||O===!0||O===void 0&&u[L]!==!1)&&(u[L||m]=normalizeValue(b))}const y=(b,m)=>utils$1.forEach(b,(O,N)=>c(O,N,m));if(utils$1.isPlainObject(e)||e instanceof this.constructor)y(e,l);else if(utils$1.isString(e)&&(e=e.trim())&&!isValidHeaderName(e))y(parseHeaders(e),l);else if(utils$1.isHeaders(e))for(const[b,m]of e.entries())c(m,b,n);else e!=null&&c(l,e,n);return this}get(e,l){if(e=normalizeHeader(e),e){const n=utils$1.findKey(this,e);if(n){const u=this[n];if(!l)return u;if(l===!0)return parseTokens(u);if(utils$1.isFunction(l))return l.call(this,u,n);if(utils$1.isRegExp(l))return l.exec(u);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,l){if(e=normalizeHeader(e),e){const n=utils$1.findKey(this,e);return!!(n&&this[n]!==void 0&&(!l||matchHeaderValue(this,this[n],n,l)))}return!1}delete(e,l){const n=this;let u=!1;function c(y){if(y=normalizeHeader(y),y){const b=utils$1.findKey(n,y);b&&(!l||matchHeaderValue(n,n[b],b,l))&&(delete n[b],u=!0)}}return utils$1.isArray(e)?e.forEach(c):c(e),u}clear(e){const l=Object.keys(this);let n=l.length,u=!1;for(;n--;){const c=l[n];(!e||matchHeaderValue(this,this[c],c,e,!0))&&(delete this[c],u=!0)}return u}normalize(e){const l=this,n={};return utils$1.forEach(this,(u,c)=>{const y=utils$1.findKey(n,c);if(y){l[y]=normalizeValue(u),delete l[c];return}const b=e?formatHeader(c):String(c).trim();b!==c&&delete l[c],l[b]=normalizeValue(u),n[b]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const l=Object.create(null);return utils$1.forEach(this,(n,u)=>{n!=null&&n!==!1&&(l[u]=e&&utils$1.isArray(n)?n.join(", "):n)}),l}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,l])=>e+": "+l).join(`
- `)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...l){const n=new this(e);return l.forEach(u=>n.set(u)),n}static accessor(e){const n=(this[$internals]=this[$internals]={accessors:{}}).accessors,u=this.prototype;function c(y){const b=normalizeHeader(y);n[b]||(buildAccessors(u,y),n[b]=!0)}return utils$1.isArray(e)?e.forEach(c):c(e),this}}AxiosHeaders.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);utils$1.reduceDescriptors(AxiosHeaders.prototype,({value:t},e)=>{let l=e[0].toUpperCase()+e.slice(1);return{get:()=>t,set(n){this[l]=n}}});utils$1.freezeMethods(AxiosHeaders);function transformData(t,e){const l=this||defaults,n=e||l,u=AxiosHeaders.from(n.headers);let c=n.data;return utils$1.forEach(t,function(b){c=b.call(l,c,u.normalize(),e?e.status:void 0)}),u.normalize(),c}function isCancel(t){return!!(t&&t.__CANCEL__)}function CanceledError(t,e,l){AxiosError.call(this,t??"canceled",AxiosError.ERR_CANCELED,e,l),this.name="CanceledError"}utils$1.inherits(CanceledError,AxiosError,{__CANCEL__:!0});function settle(t,e,l){const n=l.config.validateStatus;!l.status||!n||n(l.status)?t(l):e(new AxiosError("Request failed with status code "+l.status,[AxiosError.ERR_BAD_REQUEST,AxiosError.ERR_BAD_RESPONSE][Math.floor(l.status/100)-4],l.config,l.request,l))}function parseProtocol(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function speedometer(t,e){t=t||10;const l=new Array(t),n=new Array(t);let u=0,c=0,y;return e=e!==void 0?e:1e3,function(m){const O=Date.now(),N=n[c];y||(y=O),l[u]=m,n[u]=O;let L=c,G=0;for(;L!==u;)G+=l[L++],L=L%t;if(u=(u+1)%t,u===c&&(c=(c+1)%t),O-y<e)return;const q=N&&O-N;return q?Math.round(G*1e3/q):void 0}}function throttle(t,e){let l=0;const n=1e3/e;let u=null;return function(){const y=this===!0,b=Date.now();if(y||b-l>n)return u&&(clearTimeout(u),u=null),l=b,t.apply(null,arguments);u||(u=setTimeout(()=>(u=null,l=Date.now(),t.apply(null,arguments)),n-(b-l)))}}const progressEventReducer=(t,e,l=3)=>{let n=0;const u=speedometer(50,250);return throttle(c=>{const y=c.loaded,b=c.lengthComputable?c.total:void 0,m=y-n,O=u(m),N=y<=b;n=y;const L={loaded:y,total:b,progress:b?y/b:void 0,bytes:m,rate:O||void 0,estimated:O&&b&&N?(b-y)/O:void 0,event:c,lengthComputable:b!=null};L[e?"download":"upload"]=!0,t(L)},l)},isURLSameOrigin=platform.hasStandardBrowserEnv?function t(){const e=/(msie|trident)/i.test(navigator.userAgent),l=document.createElement("a");let n;function u(c){let y=c;return e&&(l.setAttribute("href",y),y=l.href),l.setAttribute("href",y),{href:l.href,protocol:l.protocol?l.protocol.replace(/:$/,""):"",host:l.host,search:l.search?l.search.replace(/^\?/,""):"",hash:l.hash?l.hash.replace(/^#/,""):"",hostname:l.hostname,port:l.port,pathname:l.pathname.charAt(0)==="/"?l.pathname:"/"+l.pathname}}return n=u(window.location.href),function(y){const b=utils$1.isString(y)?u(y):y;return b.protocol===n.protocol&&b.host===n.host}}():function t(){return function(){return!0}}(),cookies=platform.hasStandardBrowserEnv?{write(t,e,l,n,u,c){const y=[t+"="+encodeURIComponent(e)];utils$1.isNumber(l)&&y.push("expires="+new Date(l).toGMTString()),utils$1.isString(n)&&y.push("path="+n),utils$1.isString(u)&&y.push("domain="+u),c===!0&&y.push("secure"),document.cookie=y.join("; ")},read(t){const e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove(t){this.write(t,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function isAbsoluteURL(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function combineURLs(t,e){return e?t.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):t}function buildFullPath(t,e){return t&&!isAbsoluteURL(e)?combineURLs(t,e):e}const headersToObject=t=>t instanceof AxiosHeaders?{...t}:t;function mergeConfig(t,e){e=e||{};const l={};function n(O,N,L){return utils$1.isPlainObject(O)&&utils$1.isPlainObject(N)?utils$1.merge.call({caseless:L},O,N):utils$1.isPlainObject(N)?utils$1.merge({},N):utils$1.isArray(N)?N.slice():N}function u(O,N,L){if(utils$1.isUndefined(N)){if(!utils$1.isUndefined(O))return n(void 0,O,L)}else return n(O,N,L)}function c(O,N){if(!utils$1.isUndefined(N))return n(void 0,N)}function y(O,N){if(utils$1.isUndefined(N)){if(!utils$1.isUndefined(O))return n(void 0,O)}else return n(void 0,N)}function b(O,N,L){if(L in e)return n(O,N);if(L in t)return n(void 0,O)}const m={url:c,method:c,data:c,baseURL:y,transformRequest:y,transformResponse:y,paramsSerializer:y,timeout:y,timeoutMessage:y,withCredentials:y,withXSRFToken:y,adapter:y,responseType:y,xsrfCookieName:y,xsrfHeaderName:y,onUploadProgress:y,onDownloadProgress:y,decompress:y,maxContentLength:y,maxBodyLength:y,beforeRedirect:y,transport:y,httpAgent:y,httpsAgent:y,cancelToken:y,socketPath:y,responseEncoding:y,validateStatus:b,headers:(O,N)=>u(headersToObject(O),headersToObject(N),!0)};return utils$1.forEach(Object.keys(Object.assign({},t,e)),function(N){const L=m[N]||u,G=L(t[N],e[N],N);utils$1.isUndefined(G)&&L!==b||(l[N]=G)}),l}const resolveConfig=t=>{const e=mergeConfig({},t);let{data:l,withXSRFToken:n,xsrfHeaderName:u,xsrfCookieName:c,headers:y,auth:b}=e;e.headers=y=AxiosHeaders.from(y),e.url=buildURL(buildFullPath(e.baseURL,e.url),t.params,t.paramsSerializer),b&&y.set("Authorization","Basic "+btoa((b.username||"")+":"+(b.password?unescape(encodeURIComponent(b.password)):"")));let m;if(utils$1.isFormData(l)){if(platform.hasStandardBrowserEnv||platform.hasStandardBrowserWebWorkerEnv)y.setContentType(void 0);else if((m=y.getContentType())!==!1){const[O,...N]=m?m.split(";").map(L=>L.trim()).filter(Boolean):[];y.setContentType([O||"multipart/form-data",...N].join("; "))}}if(platform.hasStandardBrowserEnv&&(n&&utils$1.isFunction(n)&&(n=n(e)),n||n!==!1&&isURLSameOrigin(e.url))){const O=u&&c&&cookies.read(c);O&&y.set(u,O)}return e},isXHRAdapterSupported=typeof XMLHttpRequest<"u",xhrAdapter=isXHRAdapterSupported&&function(t){return new Promise(function(l,n){const u=resolveConfig(t);let c=u.data;const y=AxiosHeaders.from(u.headers).normalize();let{responseType:b}=u,m;function O(){u.cancelToken&&u.cancelToken.unsubscribe(m),u.signal&&u.signal.removeEventListener("abort",m)}let N=new XMLHttpRequest;N.open(u.method.toUpperCase(),u.url,!0),N.timeout=u.timeout;function L(){if(!N)return;const q=AxiosHeaders.from("getAllResponseHeaders"in N&&N.getAllResponseHeaders()),fe={data:!b||b==="text"||b==="json"?N.responseText:N.response,status:N.status,statusText:N.statusText,headers:q,config:t,request:N};settle(function(ne){l(ne),O()},function(ne){n(ne),O()},fe),N=null}"onloadend"in N?N.onloadend=L:N.onreadystatechange=function(){!N||N.readyState!==4||N.status===0&&!(N.responseURL&&N.responseURL.indexOf("file:")===0)||setTimeout(L)},N.onabort=function(){N&&(n(new AxiosError("Request aborted",AxiosError.ECONNABORTED,u,N)),N=null)},N.onerror=function(){n(new AxiosError("Network Error",AxiosError.ERR_NETWORK,u,N)),N=null},N.ontimeout=function(){let J=u.timeout?"timeout of "+u.timeout+"ms exceeded":"timeout exceeded";const fe=u.transitional||transitionalDefaults;u.timeoutErrorMessage&&(J=u.timeoutErrorMessage),n(new AxiosError(J,fe.clarifyTimeoutError?AxiosError.ETIMEDOUT:AxiosError.ECONNABORTED,u,N)),N=null},c===void 0&&y.setContentType(null),"setRequestHeader"in N&&utils$1.forEach(y.toJSON(),function(J,fe){N.setRequestHeader(fe,J)}),utils$1.isUndefined(u.withCredentials)||(N.withCredentials=!!u.withCredentials),b&&b!=="json"&&(N.responseType=u.responseType),typeof u.onDownloadProgress=="function"&&N.addEventListener("progress",progressEventReducer(u.onDownloadProgress,!0)),typeof u.onUploadProgress=="function"&&N.upload&&N.upload.addEventListener("progress",progressEventReducer(u.onUploadProgress)),(u.cancelToken||u.signal)&&(m=q=>{N&&(n(!q||q.type?new CanceledError(null,t,N):q),N.abort(),N=null)},u.cancelToken&&u.cancelToken.subscribe(m),u.signal&&(u.signal.aborted?m():u.signal.addEventListener("abort",m)));const G=parseProtocol(u.url);if(G&&platform.protocols.indexOf(G)===-1){n(new AxiosError("Unsupported protocol "+G+":",AxiosError.ERR_BAD_REQUEST,t));return}N.send(c||null)})},composeSignals=(t,e)=>{let l=new AbortController,n;const u=function(m){if(!n){n=!0,y();const O=m instanceof Error?m:this.reason;l.abort(O instanceof AxiosError?O:new CanceledError(O instanceof Error?O.message:O))}};let c=e&&setTimeout(()=>{u(new AxiosError(`timeout ${e} of ms exceeded`,AxiosError.ETIMEDOUT))},e);const y=()=>{t&&(c&&clearTimeout(c),c=null,t.forEach(m=>{m&&(m.removeEventListener?m.removeEventListener("abort",u):m.unsubscribe(u))}),t=null)};t.forEach(m=>m&&m.addEventListener&&m.addEventListener("abort",u));const{signal:b}=l;return b.unsubscribe=y,[b,()=>{c&&clearTimeout(c),c=null}]},streamChunk=function*(t,e){let l=t.byteLength;if(l<e){yield t;return}let n=0,u;for(;n<l;)u=n+e,yield t.slice(n,u),n=u},readBytes=async function*(t,e,l){for await(const n of t)yield*streamChunk(ArrayBuffer.isView(n)?n:await l(String(n)),e)},trackStream=(t,e,l,n,u)=>{const c=readBytes(t,e,u);let y=0;return new ReadableStream({type:"bytes",async pull(b){const{done:m,value:O}=await c.next();if(m){b.close(),n();return}let N=O.byteLength;l&&l(y+=N),b.enqueue(new Uint8Array(O))},cancel(b){return n(b),c.return()}},{highWaterMark:2})},fetchProgressDecorator=(t,e)=>{const l=t!=null;return n=>setTimeout(()=>e({lengthComputable:l,total:t,loaded:n}))},isFetchSupported=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",isReadableStreamSupported=isFetchSupported&&typeof ReadableStream=="function",encodeText=isFetchSupported&&(typeof TextEncoder=="function"?(t=>e=>t.encode(e))(new TextEncoder):async t=>new Uint8Array(await new Response(t).arrayBuffer())),supportsRequestStream=isReadableStreamSupported&&(()=>{let t=!1;const e=new Request(platform.origin,{body:new ReadableStream,method:"POST",get duplex(){return t=!0,"half"}}).headers.has("Content-Type");return t&&!e})(),DEFAULT_CHUNK_SIZE=64*1024,supportsResponseStream=isReadableStreamSupported&&!!(()=>{try{return utils$1.isReadableStream(new Response("").body)}catch{}})(),resolvers={stream:supportsResponseStream&&(t=>t.body)};isFetchSupported&&(t=>{["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!resolvers[e]&&(resolvers[e]=utils$1.isFunction(t[e])?l=>l[e]():(l,n)=>{throw new AxiosError(`Response type '${e}' is not supported`,AxiosError.ERR_NOT_SUPPORT,n)})})})(new Response);const getBodyLength=async t=>{if(t==null)return 0;if(utils$1.isBlob(t))return t.size;if(utils$1.isSpecCompliantForm(t))return(await new Request(t).arrayBuffer()).byteLength;if(utils$1.isArrayBufferView(t))return t.byteLength;if(utils$1.isURLSearchParams(t)&&(t=t+""),utils$1.isString(t))return(await encodeText(t)).byteLength},resolveBodyLength=async(t,e)=>{const l=utils$1.toFiniteNumber(t.getContentLength());return l??getBodyLength(e)},fetchAdapter=isFetchSupported&&(async t=>{let{url:e,method:l,data:n,signal:u,cancelToken:c,timeout:y,onDownloadProgress:b,onUploadProgress:m,responseType:O,headers:N,withCredentials:L="same-origin",fetchOptions:G}=resolveConfig(t);O=O?(O+"").toLowerCase():"text";let[q,J]=u||c||y?composeSignals([u,c],y):[],fe,ve;const ne=()=>{!fe&&setTimeout(()=>{q&&q.unsubscribe()}),fe=!0};let Ue;try{if(m&&supportsRequestStream&&l!=="get"&&l!=="head"&&(Ue=await resolveBodyLength(N,n))!==0){let Ae=new Request(e,{method:"POST",body:n,duplex:"half"}),Te;utils$1.isFormData(n)&&(Te=Ae.headers.get("content-type"))&&N.setContentType(Te),Ae.body&&(n=trackStream(Ae.body,DEFAULT_CHUNK_SIZE,fetchProgressDecorator(Ue,progressEventReducer(m)),null,encodeText))}utils$1.isString(L)||(L=L?"cors":"omit"),ve=new Request(e,{...G,signal:q,method:l.toUpperCase(),headers:N.normalize().toJSON(),body:n,duplex:"half",withCredentials:L});let De=await fetch(ve);const Ve=supportsResponseStream&&(O==="stream"||O==="response");if(supportsResponseStream&&(b||Ve)){const Ae={};["status","statusText","headers"].forEach(Xe=>{Ae[Xe]=De[Xe]});const Te=utils$1.toFiniteNumber(De.headers.get("content-length"));De=new Response(trackStream(De.body,DEFAULT_CHUNK_SIZE,b&&fetchProgressDecorator(Te,progressEventReducer(b,!0)),Ve&&ne,encodeText),Ae)}O=O||"text";let rt=await resolvers[utils$1.findKey(resolvers,O)||"text"](De,t);return!Ve&&ne(),J&&J(),await new Promise((Ae,Te)=>{settle(Ae,Te,{data:rt,headers:AxiosHeaders.from(De.headers),status:De.status,statusText:De.statusText,config:t,request:ve})})}catch(De){throw ne(),De&&De.name==="TypeError"&&/fetch/i.test(De.message)?Object.assign(new AxiosError("Network Error",AxiosError.ERR_NETWORK,t,ve),{cause:De.cause||De}):AxiosError.from(De,De&&De.code,t,ve)}}),knownAdapters={http:httpAdapter,xhr:xhrAdapter,fetch:fetchAdapter};utils$1.forEach(knownAdapters,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const renderReason=t=>`- ${t}`,isResolvedHandle=t=>utils$1.isFunction(t)||t===null||t===!1,adapters={getAdapter:t=>{t=utils$1.isArray(t)?t:[t];const{length:e}=t;let l,n;const u={};for(let c=0;c<e;c++){l=t[c];let y;if(n=l,!isResolvedHandle(l)&&(n=knownAdapters[(y=String(l)).toLowerCase()],n===void 0))throw new AxiosError(`Unknown adapter '${y}'`);if(n)break;u[y||"#"+c]=n}if(!n){const c=Object.entries(u).map(([b,m])=>`adapter ${b} `+(m===!1?"is not supported by the environment":"is not available in the build"));let y=e?c.length>1?`since :
- `+c.map(renderReason).join(`
- `):" "+renderReason(c[0]):"as no adapter specified";throw new AxiosError("There is no suitable adapter to dispatch the request "+y,"ERR_NOT_SUPPORT")}return n},adapters:knownAdapters};function throwIfCancellationRequested(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new CanceledError(null,t)}function dispatchRequest(t){return throwIfCancellationRequested(t),t.headers=AxiosHeaders.from(t.headers),t.data=transformData.call(t,t.transformRequest),["post","put","patch"].indexOf(t.method)!==-1&&t.headers.setContentType("application/x-www-form-urlencoded",!1),adapters.getAdapter(t.adapter||defaults.adapter)(t).then(function(n){return throwIfCancellationRequested(t),n.data=transformData.call(t,t.transformResponse,n),n.headers=AxiosHeaders.from(n.headers),n},function(n){return isCancel(n)||(throwIfCancellationRequested(t),n&&n.response&&(n.response.data=transformData.call(t,t.transformResponse,n.response),n.response.headers=AxiosHeaders.from(n.response.headers))),Promise.reject(n)})}const VERSION="1.7.2",validators$1={};["object","boolean","number","function","string","symbol"].forEach((t,e)=>{validators$1[t]=function(n){return typeof n===t||"a"+(e<1?"n ":" ")+t}});const deprecatedWarnings={};validators$1.transitional=function t(e,l,n){function u(c,y){return"[Axios v"+VERSION+"] Transitional option '"+c+"'"+y+(n?". "+n:"")}return(c,y,b)=>{if(e===!1)throw new AxiosError(u(y," has been removed"+(l?" in "+l:"")),AxiosError.ERR_DEPRECATED);return l&&!deprecatedWarnings[y]&&(deprecatedWarnings[y]=!0,console.warn(u(y," has been deprecated since v"+l+" and will be removed in the near future"))),e?e(c,y,b):!0}};function assertOptions(t,e,l){if(typeof t!="object")throw new AxiosError("options must be an object",AxiosError.ERR_BAD_OPTION_VALUE);const n=Object.keys(t);let u=n.length;for(;u-- >0;){const c=n[u],y=e[c];if(y){const b=t[c],m=b===void 0||y(b,c,t);if(m!==!0)throw new AxiosError("option "+c+" must be "+m,AxiosError.ERR_BAD_OPTION_VALUE);continue}if(l!==!0)throw new AxiosError("Unknown option "+c,AxiosError.ERR_BAD_OPTION)}}const validator={assertOptions,validators:validators$1},validators=validator.validators;class Axios{constructor(e){this.defaults=e,this.interceptors={request:new InterceptorManager,response:new InterceptorManager}}async request(e,l){try{return await this._request(e,l)}catch(n){if(n instanceof Error){let u;Error.captureStackTrace?Error.captureStackTrace(u={}):u=new Error;const c=u.stack?u.stack.replace(/^.+\n/,""):"";try{n.stack?c&&!String(n.stack).endsWith(c.replace(/^.+\n.+\n/,""))&&(n.stack+=`
- `+c):n.stack=c}catch{}}throw n}}_request(e,l){typeof e=="string"?(l=l||{},l.url=e):l=e||{},l=mergeConfig(this.defaults,l);const{transitional:n,paramsSerializer:u,headers:c}=l;n!==void 0&&validator.assertOptions(n,{silentJSONParsing:validators.transitional(validators.boolean),forcedJSONParsing:validators.transitional(validators.boolean),clarifyTimeoutError:validators.transitional(validators.boolean)},!1),u!=null&&(utils$1.isFunction(u)?l.paramsSerializer={serialize:u}:validator.assertOptions(u,{encode:validators.function,serialize:validators.function},!0)),l.method=(l.method||this.defaults.method||"get").toLowerCase();let y=c&&utils$1.merge(c.common,c[l.method]);c&&utils$1.forEach(["delete","get","head","post","put","patch","common"],J=>{delete c[J]}),l.headers=AxiosHeaders.concat(y,c);const b=[];let m=!0;this.interceptors.request.forEach(function(fe){typeof fe.runWhen=="function"&&fe.runWhen(l)===!1||(m=m&&fe.synchronous,b.unshift(fe.fulfilled,fe.rejected))});const O=[];this.interceptors.response.forEach(function(fe){O.push(fe.fulfilled,fe.rejected)});let N,L=0,G;if(!m){const J=[dispatchRequest.bind(this),void 0];for(J.unshift.apply(J,b),J.push.apply(J,O),G=J.length,N=Promise.resolve(l);L<G;)N=N.then(J[L++],J[L++]);return N}G=b.length;let q=l;for(L=0;L<G;){const J=b[L++],fe=b[L++];try{q=J(q)}catch(ve){fe.call(this,ve);break}}try{N=dispatchRequest.call(this,q)}catch(J){return Promise.reject(J)}for(L=0,G=O.length;L<G;)N=N.then(O[L++],O[L++]);return N}getUri(e){e=mergeConfig(this.defaults,e);const l=buildFullPath(e.baseURL,e.url);return buildURL(l,e.params,e.paramsSerializer)}}utils$1.forEach(["delete","get","head","options"],function t(e){Axios.prototype[e]=function(l,n){return this.request(mergeConfig(n||{},{method:e,url:l,data:(n||{}).data}))}});utils$1.forEach(["post","put","patch"],function t(e){function l(n){return function(c,y,b){return this.request(mergeConfig(b||{},{method:e,headers:n?{"Content-Type":"multipart/form-data"}:{},url:c,data:y}))}}Axios.prototype[e]=l(),Axios.prototype[e+"Form"]=l(!0)});class CancelToken{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let l;this.promise=new Promise(function(c){l=c});const n=this;this.promise.then(u=>{if(!n._listeners)return;let c=n._listeners.length;for(;c-- >0;)n._listeners[c](u);n._listeners=null}),this.promise.then=u=>{let c;const y=new Promise(b=>{n.subscribe(b),c=b}).then(u);return y.cancel=function(){n.unsubscribe(c)},y},e(function(c,y,b){n.reason||(n.reason=new CanceledError(c,y,b),l(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const l=this._listeners.indexOf(e);l!==-1&&this._listeners.splice(l,1)}static source(){let e;return{token:new CancelToken(function(u){e=u}),cancel:e}}}function spread(t){return function(l){return t.apply(null,l)}}function isAxiosError(t){return utils$1.isObject(t)&&t.isAxiosError===!0}const HttpStatusCode={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(HttpStatusCode).forEach(([t,e])=>{HttpStatusCode[e]=t});function createInstance(t){const e=new Axios(t),l=bind(Axios.prototype.request,e);return utils$1.extend(l,Axios.prototype,e,{allOwnKeys:!0}),utils$1.extend(l,e,null,{allOwnKeys:!0}),l.create=function(u){return createInstance(mergeConfig(t,u))},l}const axios=createInstance(defaults);axios.Axios=Axios;axios.CanceledError=CanceledError;axios.CancelToken=CancelToken;axios.isCancel=isCancel;axios.VERSION=VERSION;axios.toFormData=toFormData;axios.AxiosError=AxiosError;axios.Cancel=axios.CanceledError;axios.all=function t(e){return Promise.all(e)};axios.spread=spread;axios.isAxiosError=isAxiosError;axios.mergeConfig=mergeConfig;axios.AxiosHeaders=AxiosHeaders;axios.formToJSON=t=>formDataToJSON(utils$1.isHTMLForm(t)?new FormData(t):t);axios.getAdapter=adapters.getAdapter;axios.HttpStatusCode=HttpStatusCode;axios.default=axios;axios.defaults.baseURL="";axios.defaults.headers.post["Content-Type"]="application/json";axios.defaults.withCredentials=!0;function getHostUrl(){let t=window.location.hostname;return t.substring(0,4)!="http"&&(t=document.location.protocol+"//"+t),t}let isReloadFile=!1;function setReloadFile(t){isReloadFile=t}let uploader;function createDwgFileUploader(t){let{create:e,baseUrl:l="",fileisExist:n,chunkisExist:u,chunked:c}=getUploadFileConfig()||{};l.substring(0,16)=="http://localhost"&&(l=getHostUrl()+l.substring(16));const{pick:y,serverURL:b,onError:m,onFileQueued:O,onCreateHashProgress:N,onProgress:L,onBeginUpload:G,onSecondTransmission:q,onUploadSuccess:J,onUploadFinished:fe,accept:ve}=t;let ne="";WebUploader.Uploader.register({"before-send":"beforeSend"},{beforeSend:Te=>{const Xe=WebUploader.Deferred();return axios.post(l+u,{chunk:Te.chunk,chunks:Te.chunks,fileName:Te.file.name,fileHash:ne,size:Te.blob.size}).then(ie=>{ie.data.ret=="chunkAlreadyExist"?Xe.reject():Xe.resolve()},()=>{console.log("MxTip:post chunk is Exits error"),m&&m()}),Xe.promise()}});let{swf:Ue,server:De="",accept:Ve,dnd:rt,...Ae}=e||{};return uploader=WebUploader.create({dnd:rt,preserveHeaders:!0,withCredentials:!0,auto:!1,swf:Ue,server:b||l+De,pick:y,resize:!1,duplicate:!0,threads:3,chunked:c,fileNumLimit:2,timeout:2601e3,accept:Ve||ve||{extensions:"dwg,DWG,dxf,DXF,mxweb",mimeTypes:".dwg,.DwG,.dxf,.DXF,.mxweb"},...Ae}),uploader.on("fileQueued",async Te=>{O&&await O(Te)||uploader.md5File(Te).progress(Xe=>{N&&N(Xe)}).then(Xe=>{ne=Xe,isReloadFile?(G&&G(),uploader.upload()):Te.ext==="mxweb"?(uploader.skipFile(Te),uploader.reset()):axios.post(l+n,{fileHash:Xe,filename:Te.name}).then(ie=>{G&&G(),ie.data.ret=="fileAlreadyExist"?(q&&q(),uploader.skipFile(Te),uploader.reset(),J&&J(Te,ne,!0)):uploader.upload()},()=>{console.log("MxTip:post file is Exits error:1"),m&&m()})})}),uploader.on("uploadBeforeSend",(Te,Xe,ie)=>{Xe.hash=ne}),uploader.on("uploadProgress",(Te,Xe)=>{L&&L(Xe*100)}),uploader.on("uploadSuccess",Te=>{axios.post(l+n,{fileHash:ne,filename:Te.name}).then(Xe=>{Xe.data.ret=="fileAlreadyExist"?J&&J(Te,ne,!1):(console.log("MxTip:post file is no exits error:2"),m&&m())})}),uploader.on("uploadFinished",function(Te){fe&&fe(),uploader.reset()}),uploader.on("uploadError",(Te,Xe)=>{console.log("MxTip:uploadError error:1"),console.group(Xe),m&&m()}),uploader.on("error",Te=>{uploader.reset(),console.log("MxTip:uploadError error:2"),console.log("err",Te),m&&m()}),uploader}const idMap={白色:1,红色:2,黄色:3,绿色:4,青色:5,洋红色:6,蓝色:7,随层:8,随块:9,索引颜色:10,真彩色:11,所有样式:12,正在使用样式:13,开始转换:14,线:15,符号与箭头:16,调整:17,主单位:18,生成打印PDF:19,批量下载:20,所有图元:21,选择文件:22,继续打开文件:23,数据库:24,数据库显示:25,标注样式:26,全局字典:27,类型:28,线型比例:29,渲染顺序:30,法向坐标:31,其他信息:32,顶点:33,顶点起始宽度:34,顶点中止宽度:35,全局宽度:36,曲线参数:37,几何图形:38,开始点:39,结束点:40,是否填充:41,填充透明度:42,位置坐标:43,缩放比例:44,圆心坐标:45,弧心坐标:46,CAD图形:47,批注图形:48,无选择:49,多段线:50,对齐尺寸:51,长度测量:52,面积测量:53,角度测量:54,坐标测试:55,引线标注:56,审图标注:57,云线批注:58,形状批注:59,新增图层:60,删除图层:61,关闭所有图层:62,搜索图层:63,顶点起始线宽:64,顶点中止线宽:65,全局线宽:66,当前线宽为:67,半宽:68,倒角:69,指定第一个倒角距离:70,指定第二个倒角距离:71,指定矩形的标高:72,指定矩形的圆角半径:73,指定矩形的厚度:74,指定矩形的宽度:75,输入当前单位计算的矩形面积:76,计算矩形标注时的依据:77,输入矩形的长度:78,标高:79,圆角:80,厚角:81,指定另一个角:82,指定圆弧的起点:83,指定圆弧的第二个点:84,按住:85,键取相反方向:86,弦长:87,修改半径:88,指定椭圆的轴端点:89,指定椭圆的另一个轴端点:90,指定另一条半轴长度:91,指定圆的圆心:92,三点:93,两点:94,指定圆的半径:95,指定圆的直径:96,指定圆弧夹角:97,指定椭圆弧的轴端点:98,指定椭圆弧的中心点:99,指定椭圆弧轴的端点:100,指定绕主轴旋转的角度:101,指定起点角度:102,指定端点角度:103,夹角:104,指定椭圆弧轴的另一个端点:105,指定圆弧的夹角:106,不使用缓存:107,输入比例因子:108,指定另一个角点:109,梦想在线画图:110,选择更多颜色:111,线宽:112,AI:113,登录:114,语言:115,主题:116,图层:117,矩形阵列:118,环形阵列:119,行数:120,列数:121,行偏移:122,列偏移:123,阵列角度:124,提示:125,"默认情况下,如何行偏移为负值,则行添加在下面。如果列偏移为负值,则列添加在左边":126,中心点:127,方法:128,项目总数:129,填充角度:130,项目间角度:131,"对于填充角度,正值指定逆时针旋转,负值指定顺时针旋转":132,复制时旋转项目:133,选择对象:134,已选择:135,个:136,对象:137,名称:138,浏览:139,是:140,否:141,创建块:142,基点:143,在屏幕上指定:144,拾取点:145,保留:146,转换为块:147,删除:148,未选定对象:149,已选择对象:150,说明:151,可见:152,锁定:153,打印:154,颜色:155,线性:156,反选:157,确定:158,关闭:159,图纸:160,界限:161,显示:162,区域:163,上次:164,范围:165,自由:166,选择:167,固定:168,比例:169,大小:170,左下:171,角:172,坐标:173,右上:174,尺寸:175,方向:176,参数:177,毫米:178,绘图:179,单位:180,添加新图纸:181,已加载的线型:182,线型:183,外观:184,查找:185,内容:186,方式:187,全局:188,矩形:189,异形:190,全字:191,匹配:192,替换:193,全部:194,基础:195,版本号:196,打开文件:197,视区平移:198,回退:199,重做:200,圆:201,前置:202,文件:203,新建:204,编辑:205,剪切:206,复制:207,带基点复制:208,粘贴:209,全部选择:210,查找文字:211,插入:212,视图:213,重画:214,窗口缩放:215,上一个:216,视区旋转:217,自定义旋转角度:218,格式:219,将对象的图层置为当前:220,恢复上一个图层状态:221,图层漫游:222,对象修改图层匹配:223,选择关闭图层:224,打开所有图层:225,图层锁定:226,图层解锁:227,图层合并:228,图层删除:229,文字样式:230,点样式:231,工具:232,距离:233,半径:234,角度:235,面积:236,点坐标:237,直线:238,多线段:239,正多边形:240,圆弧:241,样条线:242,椭圆:243,椭圆弧:244,点:245,文字:246,填充:247,图片:248,标注:249,修改:250,批注:251,测试:252,地图:253,帮助:254,关于:255,CAD梦想在线画图:256,另存为mxweb文件:257,重画命令:258,窗口缩放命令:259,显示全部:260,视区旋转90度:261,全屏模式:262,对象特性:263,图块库:264,图纸库:265,数据库展示:266,绘线命令:267,绘多线段命令:268,绘正多边形命令:269,绘矩形框命令:270,绘圆弧命令:271,绘样条线命令:272,绘椭圆命令:273,绘椭圆弧命令:274,插入图块命令:275,创建块命令:276,绘点命令:277,写文字命令:278,插入图片命令:279,绘多行文本:280,绘填充命令:281,云线:282,表格:283,圆环:284,删除命令:285,复制命令:286,移动命令:287,旋转命令:288,缩放命令:289,偏移:290,阵列:291,镜像命令:292,离散曲线命令:293,导角命令:294,导圆角命令:295,剪切命令:296,延伸命令:297,拉伸命令:298,分解命令:299,打断命令:300,合并命令:301,线性标注:302,对齐标注:303,角度标注:304,半径标注:305,直径标注:306,后置:307,置于对象之上:308,置于对象之下:309,另存为dwg文件:310,插入图片:311,插入图块:312,插入表格:313,顺时针旋转90度:314,逆时针旋转90度:315,视区背景色:316,图层工具:317,对象修改设置为当前层:318,对象复制到新图层:319,编辑文字:320,查找替换文字:321,快速选择:322,图纸比对:323,查询:324,图形识别:325,查看已识别图形列表:326,铅笔命令:327,面积标注:328,坐标标注:329,箭头标注:330,保存批注:331,恢复批注:332,插件测试:333,扩展工具:334,谷歌地图:335,高德矢量:336,高德影像:337,天地图地图:338,百度地图:339,OSM地图:340,地图下载:341,"绘GIS Point":342,"绘GIS MultPoint":343,"绘GIS LineString":344,"绘GIS MultiLineString":345,"绘GIS DrawPolygon":346,输出geojson:347,设置:348,打开:349,使用缓存:350,快速打开:351,忽略缓存:352,重新转换:353,另存为:354,MxWeb格式:355,梦想在线CAD文件:356,Dwg格式:357,AutoCad图纸:358,栅格:359,正交:360,极轴:361,对象捕捉:362,对象追踪:363,全屏显示:364,正在打开文件中:365,更新显示:366,打开图纸失败:367,点取文字插入点:368,当前浏览器不支持部分全屏:369,输入选项:370,当前:371,世界:372,相对角度:373,输入视区旋转角度:374,输入视区旋转相对角度:375,请框选范围打印:376,指定输出范围第一点:377,按比例打印:378,图纸横向:379,输入图纸大小:380,自定义:381,输入打印比例:382,图纸上一个毫米对应的CAD绘图单位:383,输入的比例不对:384,指定指定打印中心位置:385,指定输出范围第二点:386,或:387,指定顶点:388,指定角顶点:389,指定角的第一个端点:390,指定角的第二个端点:391,选择第二条直线:392,所选对象不是直线:393,指定标注弧线位置:394,象限点:395,输入:396,标注文字:397,指定标注文字的角度:398,指定圆环的内径:399,指定圆环的外径:400,指定圆环的中心点:401,指定第一条尺寸界线原点:402,选择标注对象:403,"所选对象不是直线、圆弧或圆":404,指定第二条尺寸界线原点:405,指定尺寸线位置:406,文本:407,输入标注文字:408,选择圆弧或者圆:409,指定对角点:410,所选对象不是圆弧或圆:411,水平:412,垂直:413,旋转:414,指定尺寸线的角度:415,第一点:416,指定第一个角点:417,指定起点:418,弧长:419,多边形:420,徒手画:421,样式:422,反转方向:423,请输入最小弧长:424,指定最小弧度长度过小:425,指定最大弧长:426,指定最大弧度长度过小:427,"指定最大弧度比最小弧度还小,无效":428,选择圆弧样式:429,普通:430,手绘:431,指定下一点:432,放弃:433,沿云线路径引导十字光标:434,选择需要离散的实体:435,选择要做成块的对象:436,指定基点:437,位移:438,指定位移:439,指定第二个点:440,使用第一个点作为位移:441,水印:442,新建图层:443,当前选中样式已被修改:444,是否保存:445,'样式)"+ "0':446,样式名称重复:447,偏移距离:448,陈列对象:449,超出最大阵列对象个数:450,限制:451,mxweb文件保存失败:452,点取缩放区域:453,没有保存的上一个视图:454,命令:455,指定第一点:456,指定下一个点:457,闭合:458,总计:459,已放弃所有线段:460,指定圆弧的端点:461,"按住 Ctrl 键以切换方向":462,圆心:463,第二个点:464,指定夹角:465,指定圆弧的圆心:466,指定圆弧半径:467,指定圆弧的弦方向:468,"按住 Ctrl 键切换方向":469,长度:470,指定弦长:471,弦长不能大于直径:472,无效:473,指定圆弧的半径:474,指定圆弧起点切向:475,端点:476,指定点:477,指定角的顶点:478,直线是平行的:479,指定第二个端点:480,加模式:481,减模式:482,增加面积:483,减少面积:484,退出:485,选定的对象没有面积:486,周长:487,总面积:488,选择圆弧或圆:489,直径:490,移动光标:491,快速:492,模式:493,指定第二点:494,多个点:495,平面中的倾角:496,与:497,平面的夹角:498,打开页面失败:499,关闭标签:500,隐藏:501,"正在打开图纸,请耐心等待":502,打开图纸成功:503,"上传中断:服务器程序异常":504,"上传中断,请稍后重试":505,文件预处理中:506,上传图纸:507,图纸处理中:508,选择复制对象:509,无法清空剪贴板:510,选择剪切对象:511,指定插入点:512,指定缩放比例:513,指定旋转角度:514,开:515,关:516,对象捕捉追踪:517,指定文字起点:518,指定文字高度:519,选择要编辑的文字:520,移动:521,缩放:522,取消选择:523,选择陈列对象:524,指定整列角度:525,未选择需要阵列对象:526,指定插入基点:527,识别图框的范围:528,没有历史记录:529,已选择上次范围:530,指定输出范围成功:531,指定打印范围第一点:532,指定打印范围第二点:533,打印成功:534,打印失败:535,图框:536,偏移距离和方向:537,方法和值:538,附着图片:539,预览:540,插入点:541,图像高度:542,宽度:543,高度:544,旋转角度:545,输入文件:546,转换当前打开的图纸:547,输出文件:548,图纸标题:549,图纸宽度:550,图纸高度:551,图纸高度自适应:552,是否导出布局:553,使用黑白色导出:554,导出区域:555,图纸界限:556,显示区域:557,选择区域:558,区域坐标:559,批量把一个目录下所有DWG文件转换成PDF:560,"选择DWG所在目录,开始批量转换PD":561,选择颜色:562,颜色索引:563,色调:564,饱和度:565,亮度:566,红:567,绿:568,蓝:569,的:570,标注样式管理器:571,当前标注样式:572,列出:573,置为当前:574,创建新标注样式:575,新样式名:576,基础样式:577,继续:578,取消:579,启动栅格捕捉:580,极轴角设置:581,增量角:582,捕捉X轴间距:583,捕捉Y轴间距:584,草图设置:585,启动对象捕捉:586,对象捕捉模式:587,全部取消:588,启动极轴追踪:589,DWG剪切:590,存储路径:591,选取路径:592,插入块:593,路径:594,统一比例:595,分解:596,自动计算原点:597,图层特性管理器:598,线宽设置:599,列出单位:600,显示线宽:601,调整显示比例:602,最小:603,最大:604,当前线宽:605,线型加载或重载:606,可用线型:607,调整选项:608,"如果尺寸线之间没有足够的空间来放置文字和箭头,那么首先从尺寸界限中移出":609,文字或箭头:610,最佳效果:611,箭头:612,文字和箭头:613,文字你始终保持在尺寸界限之间:614,"若箭头不能放置在尺寸界限内,则将其消除":615,文字位置:616,"文字不在默认位置上时,将其放置在":617,标注特征比例:618,将标注缩放到布局:619,使用全局比例:620,优化:621,手动放置文字:622,在尺寸界限之间绘制尺寸线:623,修改标注样式:624,尺寸线:625,基线间距:626,尺寸界限:627,超出尺寸线:628,起点偏移量:629,固定长度的尺寸界限:630,单位格式:631,精度:632,小数分割符:633,舍入:634,前缀:635,后缀:636,测量单位比例:637,比例因子:638,仅应用到布局标注:639,消零:640,前导:641,后续:642,第一个:643,第二个:644,引线:645,箭头大小:646,圆心标记:647,无:648,标记:649,弧长符号:650,标注文字的前缀:651,标注文字的上方:652,文字外观:653,文字颜色:654,文字高度:655,绘制文字边框:656,从尺寸线偏移:657,文字对齐:658,与尺寸线对齐:659,标准:660,多行文字:661,字体:662,文字内容:663,填充图案选择:664,其他预定义:665,图案填充:666,型和图案:667,样例:668,角度和比例:669,边界:670,添加:671,点大小:672,相对于屏幕设置大小:673,按绝对单位设置大小:674,图框识别批量打印:675,操作:676,定位:677,打印区域:678,图框识别:679,批量打印:680,应用到:681,整个图形:682,对象类型:683,特性:684,运算符:685,值:686,包括在新选择集中:687,排除在新选择集之外:688,附加到当前选择集:689,目标图层:690,光标位置:691,图纸坐标:692,左下角:693,十字光标大小:694,靶框大小:695,背景颜色:696,视图背景色:697,布局背景色:698,标注小数位:699,标注文字大小:700,像素:701,日志保存路径:702,启动时默认打开上次打开的文件:703,清除缓存:704,控制台:705,选择上传外部参照文件:706,状态:707,文件名:708,单行文字:709,文字参数:710,导入表格:711,行:712,列:713,新建表格:714,预览编辑:715,文字查找:716,查找内容:717,替换内容:718,查找方式:719,全局查找:720,矩形区域查找:721,异性区域查找:722,全字匹配:723,区域选择:724,单击列表文字图上定位:725,标记所有结果:726,当前文字样式:727,SHX字体:728,字体名:729,大字体:730,字体样式:731,使用大字体:732,效果:733,宽度因子:734,倾斜角度:735,删除文字样式:736,新建文字样式:737,样式名:738,过滤器:739,退出时恢复:740,清除:741,线型管理器:742,取消收藏:743,收藏:744,前往:745,页:746,属性:747,无属性:748,选择比较文件:749,开始比较:750,比较结果:751,修改说明:752,被比较图纸预览:753,获取扩展数据:754,对象无扩展数据:755,对象扩展数据如下:756,获取扩展字典数据:757,对象无扩展字典数据:758,对象扩展字典数据如下:759,"*多种*":760,缺省:761,在图形中拾取点:762,未知:763,已加载:764,是否重载:765,加载失败:766,"{}":767,图纸比较:768,云图库:769,文字搜索:770,符号标注:771,箭头引注:772,引出标注:773};var Pr=Object.create,ae=Object.defineProperty,Cr=Object.getOwnPropertyDescriptor,Rr=Object.getOwnPropertyNames,Yr=Object.getPrototypeOf,Hr=Object.prototype.hasOwnProperty,Wr=(t,e,l)=>e in t?ae(t,e,{enumerable:!0,configurable:!0,writable:!0,value:l}):t[e]=l,o=(t,e)=>ae(t,"name",{value:e,configurable:!0}),A=(t=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(t,{get:(e,l)=>(typeof require<"u"?require:e)[l]}):t)(function(t){if(typeof require<"u")return require.apply(this,arguments);throw new Error('Dynamic require of "'+t+'" is not supported')}),g=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Kr=(t,e,l,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let u of Rr(e))!Hr.call(t,u)&&u!==l&&ae(t,u,{get:()=>e[u],enumerable:!(n=Cr(e,u))||n.enumerable});return t},p=(t,e,l)=>(l=t!=null?Pr(Yr(t)):{},Kr(!t||!t.__esModule?ae(l,"default",{value:t,enumerable:!0}):l,t)),d=(t,e,l)=>(Wr(t,typeof e!="symbol"?e+"":e,l),l),oe=g(t=>{function e(l){return l&&typeof l=="function"}o(e,"t"),t.a=e}),F=g(t=>{var e=Object.defineProperty,l=Object.defineProperties,n=Object.getOwnPropertyDescriptors,u=Object.getOwnPropertySymbols,c=Object.prototype.hasOwnProperty,y=Object.prototype.propertyIsEnumerable,b=o((ve,ne,Ue)=>ne in ve?e(ve,ne,{enumerable:!0,configurable:!0,writable:!0,value:Ue}):ve[ne]=Ue,"j"),m=o((ve,ne)=>{for(var Ue in ne||(ne={}))c.call(ne,Ue)&&b(ve,Ue,ne[Ue]);if(u)for(var Ue of u(ne))y.call(ne,Ue)&&b(ve,Ue,ne[Ue]);return ve},"s"),O=o((ve,ne)=>l(ve,n(ne)),"t"),N=(ve=>typeof A<"u"?A:typeof Proxy<"u"?new Proxy(ve,{get:(ne,Ue)=>(typeof A<"u"?A:ne)[Ue]}):ve)(function(ve){if(typeof A<"u")return A.apply(this,arguments);throw new Error('Dynamic require of "'+ve+'" is not supported')}),L=o((ve,ne,Ue)=>{if(!ne.has(ve))throw TypeError("Cannot "+Ue)},"k"),G=o((ve,ne,Ue)=>(L(ve,ne,"read from private field"),Ue?Ue.call(ve):ne.get(ve)),"v"),q=o((ve,ne,Ue)=>{if(ne.has(ve))throw TypeError("Cannot add the same private member more than once");ne instanceof WeakSet?ne.add(ve):ne.set(ve,Ue)},"w"),J=o((ve,ne,Ue,De)=>(L(ve,ne,"write to private field"),De?De.call(ve,Ue):ne.set(ve,Ue),Ue),"x"),fe=o((ve,ne,Ue)=>new Promise((De,Ve)=>{var rt=o(Xe=>{try{Te(Ue.next(Xe))}catch(ie){Ve(ie)}},"l"),Ae=o(Xe=>{try{Te(Ue.throw(Xe))}catch(ie){Ve(ie)}},"m"),Te=o(Xe=>Xe.done?De(Xe.value):Promise.resolve(Xe.value).then(rt,Ae),"f");Te((Ue=Ue.apply(ve,ne)).next())}),"y");t.a=m,t.b=O,t.c=N,t.d=G,t.e=q,t.f=J,t.g=fe}),I=g(t=>{var e=oe();F(),Object.defineProperty(t,"isFunction",{enumerable:!0,get:function(){return e.a}})}),v$1=g(t=>{function e(l){if(typeof l!="object"||l===null)return!1;var n=Object.getPrototypeOf(l);if(n===null)return!0;for(var u=n;Object.getPrototypeOf(u)!==null;)u=Object.getPrototypeOf(u);return n===u}o(e,"o"),t.a=e}),x=g(t=>{var e=v$1(),l=Symbol("EXCLUDE"),n=Symbol("INCLUDE");function u(c,...y){let b=y.map(O=>{if(!e.a(O))return O;let N=Object.entries(O);return N.some(([L,G])=>G===void 0)?N.reduce((L,[G,q])=>(q!==void 0&&(L[G]=q),L),{}):O}),m=Object.assign(c,...b);if(n in m){let O=typeof m[n]=="string"?m[n].split(","):Array.isArray(m[n])?m[n]:[m[n]];Object.keys(m).forEach(N=>{O.includes(N)||delete m[N]}),delete m[n]}return l in m&&((typeof m[l]=="string"?m[l].split(","):Array.isArray(m[l])?m[l]:[m[l]]).forEach(O=>delete m[O]),delete m[l]),m}o(u,"y"),t.a=l,t.b=n,t.c=u}),et=g(t=>{var e=x(),l=v$1();function n(c){return l.a(c)?["$merge","$ignoreUndefined"].some(y=>y in c):!1}o(n,"p");function u(...c){if(c.length<2)throw new Error("deepMerge函数至少需要两个参数");let y=c.length>0?n(c[c.length-1]):!1,{$merge:b,$ignoreUndefined:m,skipKeys:O}=e.c({skipKeys:[],$ignoreUndefined:!0,$merge:"replace"},y?c[c.length-1]:{});function N(L,G){l.a(L)&&Object.entries(L).forEach(([q,J])=>{let fe;q in G?Array.isArray(J)&&Array.isArray(G[q])?(b==="replace"?fe=J:b==="append"?fe=[...G[q],...J]:b==="append"?fe=[...new Set([...G[q],...J])]:typeof b=="function"&&(fe=b(G[q],J,{key:q,from:L,to:G})),G[q]=m&&J===void 0?G[q]:fe):l.a(J)&&l.a(G[q])?N(J,G[q]):G[q]=m&&J===void 0?G[q]:J:G[q]=J})}return o(N,"l"),c.reduce((L,G,q)=>q==0?L||{}:(!l.a(G)||y&&q===c.length-1||N(G,L||{}),L),c[0])}o(u,"h"),t.a=u}),Fe=g(t=>{var e=et();x(),v$1(),F(),Object.defineProperty(t,"deepMerge",{enumerable:!0,get:function(){return e.a}})}),K=g(t=>{function e(l,n=!1){if(typeof l=="number")return!0;if(typeof l!="string"||n)return!1;try{if(l.includes(".")){let u=parseFloat(l);return l.endsWith(".")?!isNaN(u)&&String(u).length===l.length-1:!isNaN(u)&&String(u).length===l.length}else{let u=parseInt(l);return!isNaN(u)&&String(u).length===l.length}}catch{return!1}}o(e,"r"),t.a=e}),B=g(t=>{var e=K();F(),Object.defineProperty(t,"isNumber",{enumerable:!0,get:function(){return e.a}})}),ht=g(t=>{var e=x(),l={en:{month:{long:["January","February","March","April","May","June","July","August","September","October","November","December"],short:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sept","Oct","Nov","Dec"]},weekday:{long:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],short:["Sun","Mon","Tues","Wed","Thur","Fri","Sat"]}},cn:{month:{long:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],short:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"]},weekday:{long:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],short:["周日","周一","周二","周三","周四","周五","周六"]}}},n={en:{slots:[12],names:["AM","PM"]},cn:{slots:[6,9,11,13,18],names:["凌晨","早上","上午","中午","下午","晚上"]}},u="YYYY-MM-DD HH:mm:ss";function c(b){b<0&&b>23&&(b=0);let m=[0,...n[this.language].slots,24].findIndex(O=>O>b)-1;return n[this.language].names[m]}o(c,"h");function y(b,m,O){let N=e.c({language:"cn"},O),L=b instanceof Date?b:new Date(b||Date.now()),G=L.getHours(),q=String(G).padStart(2,"0"),J=G>12?G-12:G,fe=String(J).padStart(2,"0"),ve=String(L.getMinutes()),ne=String(L.getSeconds()),Ue=String(L.getMilliseconds()),De=String(L.getFullYear()),Ve=L.getMonth(),rt=L.getDay(),Ae=String(L.getDate()),Te=[["HH",q],["H",G],["hh",fe],["h",J],["mm",ve.padStart(2,"0")],["m",ve],["ss",ne.padStart(2,"0")],["s",ne],["SSS",Ue.padStart(3,"0")],["A",G>12?"PM":"AM"],["a",G>12?"pm":"am"],["t",c.call(N,G)],["T",c.call(N,G)],["YYYY",De],["yyyy",De],["YY",De.substring(2)],["MMM",l[N.language].month.short[Ve]],["MM",String(Ve+1).padStart(2,"0")],["M",Ve+1],["DD",Ae.padStart(2,"0")],["D",Ae],["d",rt],["dd",l[N.language].weekday.short[rt]],["ddd",l[N.language].weekday.short[rt]],["dddd",l[N.language].weekday.long[rt]]],Xe=m||u;return Te.forEach(([ie,ue])=>Xe=Xe.replaceAll(ie,ue)),Xe}o(y,"H"),t.a=y}),dt=g(t=>{function e(l,n,u){if(typeof n=="string")for(;l.indexOf(n)>-1;){let c=typeof u=="function"?u(n):u;l=l.replace(n,c)}else{let c;if(!n.global)throw new Error("The search parameter must be enabled '/g' option");for(;(c=n.exec(l))!==null;){c.index===n.lastIndex&&n.lastIndex++;let y=typeof u=="function"?u(c[0],...c):u;l=l.replace(c[0],y)}}return l}o(e,"g"),String.prototype.replaceAll||(String.prototype.replaceAll=function(l,n){return e(this,l,n)}),t.a=e}),bt=g(t=>{var e=ht();dt(),x(),v$1(),F(),Object.defineProperty(t,"formatDateTime",{enumerable:!0,get:function(){return e.a}})}),Ft=g(t=>{var e=x(),l=[1e3,6e4,36e5,864e5,6048e5,2592e6,31536e6,Number.MAX_SAFE_INTEGER];function n(u,c,y){let{units:b,now:m,before:O,after:N}=e.c({units:["秒","分钟","小时","天","周","个月","年"],now:"刚刚",before:"{value}{unit}前",after:"{value}{unit}后"},y),L=typeof u=="number"?new Date(u).getTime():u.getTime(),G=(c instanceof Date?c:typeof c=="number"?new Date(c):new Date).getTime(),q=L-G,J=l.findIndex(fe=>Math.abs(q)<fe)-1;if(J<0&&(J=0),J>l.length-1&&(J=l.length-1),q<1e3&&q>-1e3)return m;if(q<=-1e3){let fe=parseInt(String(Math.abs(q)/l[J]));return O.replace("{value}",fe).replace("{unit}",b[J])}else{let fe=parseInt(String(Math.abs(q)/l[J]));return N.replace("{value}",fe).replace("{unit}",b[J])}}o(n,"b"),t.a=n}),Et=g(t=>{var e=Ft();x(),v$1(),F(),Object.defineProperty(t,"relativeTime",{enumerable:!0,get:function(){return e.a}})}),P=g(t=>{var e=x();v$1(),F(),Object.defineProperty(t,"EXCLUDE",{enumerable:!0,get:function(){return e.a}}),Object.defineProperty(t,"INCLUDE",{enumerable:!0,get:function(){return e.b}}),Object.defineProperty(t,"assignObject",{enumerable:!0,get:function(){return e.c}})}),V=g(t=>{function e(l){return l!=null&&typeof l[Symbol.iterator]=="function"&&typeof l!="string"}o(e,"t"),t.a=e}),Mt=g(t=>{var e=V(),l=x(),n=new RegExp("(?<name>\\w*)\\[\\s*(?<index>\\d)\\s*\\]"),u=o(class extends Error{},"c");function c(b){let m=b.match(n);if(m){let{name:O,index:N}=m.groups;return[O,parseInt(N)]}}o(c,"P");function y(b,m,O){let{defaultValue:N,matched:L,ignoreInvalidPath:G}=l.c({ignoreInvalidPath:!0,defaultValue:void 0},O);for(;m.includes("][");)m=m.replace("][","].[");let q=m.split("."),J=b,fe=null,ve=-1,ne=!1;for(let Ue=0;Ue<q.length;Ue++){let De=q[Ue];if(De in J)fe=J,ve=De,J=J[De];else if(De.trim().endsWith("]")){let Ve=c(De);if(Ve){let[rt,Ae]=Ve;if(rt in J&&(J=J[rt]),Array.isArray(J))fe=J,ve=Ae,J=J[Ae];else if(e.a(J)&&typeof Ae=="number")fe=J,ve=Ae,J=[...J][Ae];else{ne=!0;break}continue}ne=!0;break}else ne=!0}if(ne)if(G)J=N;else throw new u;return typeof L=="function"&&!ne&&L({value:J,parent:fe,indexOrKey:ve}),J}o(y,"I"),t.a=u,t.b=y}),Se=g(()=>{}),xe=g(t=>{var e=V(),l=K(),n=v$1();function u(c){if(l.a(c)||typeof c=="boolean"||typeof c=="function"||c instanceof Error)return!1;if(c==null||c==null||Array.isArray(c)&&c.length==0||n.a(c)&&Object.keys(c).length==0||typeof c=="string"&&c.trim()=="")return!0;try{if(e.a(c)&&c.size==0)return!0}catch{}return!1}o(u,"c"),t.a=u}),Me=g(t=>{function e(l){if(typeof l!="function")return!1;if(Object.prototype.toString.call(l)==="[object GeneratorFunction]"||Object.getPrototypeOf(l)===Object.getPrototypeOf(function*(){})||l.constructor.name==="GeneratorFunction")return!0;let n=l.toString();return!!/^\s*(?:function)?\*/gm.test(n)}o(e,"r"),t.a=e}),Le=g(t=>{function e(l){if(typeof l!="object")return!1;try{return l.constructor.toString().startsWith("class")}catch{return!1}}o(e,"n"),t.a=e}),Oe=g(t=>{function e(l){if(!l)return!1;if(typeof l=="number")return!0;if(typeof l!="string")return!1;try{let n=parseInt(l);return!isNaN(n)&&String(n).length===l.length}catch{return!1}}o(e,"e"),t.a=e}),je=g(t=>{function e(l){try{return typeof l=="object"&&l.constructor===Object}catch{return!1}}o(e,"c"),t.a=e}),we=g(t=>{function e(l,n){if(l===void 0)return!1;if(l===n)return!0;if(!("__proto__"in l))return!1;let u=l.__proto__;for(;u!=null;){if(u===n||u.name===n.name)return!0;u=u.__proto__}return!1}o(e,"t"),t.a=e}),Ie=g(t=>{var e=v$1();function l(n){let u=typeof n;if(n==="undefined"||n===null||u==="string"||u==="boolean"||u==="number")return!0;if(u.includes("function"))return!1;if(Array.isArray(n)){if(n.some(c=>!l(c)))return!1}else if(e.a(n)&&Object.values(n).some(c=>!l(c)))return!1;return!0}o(l,"t"),t.a=l}),he=g(t=>{var e=v$1();function l(n){return n?!!(Array.isArray(n)||n instanceof Set||n instanceof Map||e.a(n)):!1}o(l,"e"),t.a=l}),qe=g(t=>{function e(l){return typeof l=="function"&&(l.$$isAsync||Object.prototype.toString.call(l)==="[object AsyncFunction]"||l.constructor&&l.constructor.name==="AsyncFunction")}o(e,"n"),t.a=e}),$e=g(t=>{function e(l){let n=!1;if(typeof l=="function"&&l.prototype)try{l.arguments&&l.caller}catch{n=!0}return n}o(e,"n"),t.a=e}),pe=g(t=>{var e=Mt();Se(),xe(),Me(),Le(),Oe(),je(),V(),we(),Ie(),he(),qe(),K(),$e(),x(),v$1(),F(),Object.defineProperty(t,"InvalidPathError",{enumerable:!0,get:function(){return e.a}}),Object.defineProperty(t,"get",{enumerable:!0,get:function(){return e.b}})}),C=g(t=>{var e=v$1();F(),Object.defineProperty(t,"isPlainObject",{enumerable:!0,get:function(){return e.a}})}),Ct=g(t=>{var e=/(\s*[\w\u4e00-\u9fa5]+\s*:)|(:\s*\'.*?\')|(\'.*?\'\s*:)/gm;function l(n){let u;for(;(u=e.exec(n))!==null;){u.index===e.lastIndex&&e.lastIndex++;let c=u[0].trim(),y=u[0].length,b=c.endsWith(":");c.startsWith(":")&&(c=c.substring(1)),c.endsWith(":")&&(c=c.substring(0,c.length-1)),c.startsWith("'")&&c.endsWith("'")&&(c=c.substring(1,c.length-1)),c='"'+c+'"';let m=b?c+": ":" :"+c;n=`${n.substring(0,u.index)}${m}${n.substring(u.index+y)}`}return JSON.parse(n)}o(l,"g"),t.a=l}),Yt=g(t=>{var e=Ct();F(),Object.defineProperty(t,"safeParseJson",{enumerable:!0,get:function(){return e.a}})}),or=g(t=>{var e=["年","季度","月","周","日","小时","分钟","秒","毫秒","微秒"],l=["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],n=["周日","周一","周二","周三","周四","周五","周六"],u=["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],c=["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],y=["零","一","二","三","四","五","六","七","八","九"],b=["","十","百","千","万","十","百","千","亿","十","百","千","兆","十","百","千","京","十","百","千","垓"],m=["零","壹","贰","叁","肆","伍","陆","柒","捌","玖"],O=["","拾","佰","仟","万","拾","佰","仟","亿","拾","佰","仟","兆","拾","佰","仟","京","拾","佰","仟","垓"];t.a=e,t.b=l,t.c=n,t.d=u,t.e=c,t.f=y,t.g=b,t.h=m,t.i=O}),ur=g(t=>{var e=or();F(),Object.defineProperty(t,"CN_DATETIME_UNITS",{enumerable:!0,get:function(){return e.a}}),Object.defineProperty(t,"CN_MONTH_NAMES",{enumerable:!0,get:function(){return e.d}}),Object.defineProperty(t,"CN_NUMBER_BIG_DIGITS",{enumerable:!0,get:function(){return e.h}}),Object.defineProperty(t,"CN_NUMBER_BIG_UNITS",{enumerable:!0,get:function(){return e.i}}),Object.defineProperty(t,"CN_NUMBER_DIGITS",{enumerable:!0,get:function(){return e.f}}),Object.defineProperty(t,"CN_NUMBER_UNITS",{enumerable:!0,get:function(){return e.g}}),Object.defineProperty(t,"CN_SHORT_MONTH_NAMES",{enumerable:!0,get:function(){return e.e}}),Object.defineProperty(t,"CN_SHORT_WEEK_DAYS",{enumerable:!0,get:function(){return e.c}}),Object.defineProperty(t,"CN_WEEK_DAYS",{enumerable:!0,get:function(){return e.b}})}),Ye=g(t=>{function e(l){return l==null||l==null||typeof l=="string"||typeof l=="number"||typeof l=="boolean"||typeof l=="symbol"||typeof l=="bigint"}o(e,"t"),t.a=e}),pr=g(t=>{var e=Ye(),l=oe(),n=he(),u=x();function c(y,b){let{deep:m}=u.c({deep:!0},b);if(y==null||e.a(y)||l.a(y))return y;if(Array.isArray(y))return y.map(O=>m&&n.a(O)?c(O,{deep:m}):O);if(y instanceof Set){let O=new Set;for(let N of y.values())m&&n.a(N)?O.add(c(N,{deep:m})):O.add(N);return O}else if(y instanceof Map){let O=new Map;for(let[N,L]of y.entries())m&&n.a(L)?O.set(N,c(L,{deep:m})):O.set(N,L);return O}else if(typeof y=="object"){let O={};return Object.entries(y).forEach(([N,L])=>{m&&n.a(L)?O[N]=c(L):O[N]=L}),O}else return y}o(c,"f"),t.a=c}),dr=g(t=>{var e=pr();Ye(),oe(),Se(),xe(),Me(),Le(),Oe(),je(),V(),we(),Ie(),he(),qe(),K(),$e(),x(),v$1(),F(),Object.defineProperty(t,"deepClone",{enumerable:!0,get:function(){return e.a}})}),Er=g(t=>{var e=F(),l,n,u=o(class{constructor(){e.e(this,l,new Map),e.e(this,n,{})}get listeners(){return e.d(this,l)}on(y,b,m){let{objectify:O=!1,count:N=-1}=Object.assign({},m);e.d(this,l).has(y)||e.d(this,l).set(y,new Map);let L=++u.listenerSeqId,G=e.d(this,l).get(y);return G?.set(L,[b,N]),this.emitRetainEvent(y,L,G),O?{off:()=>{G?.delete(L),G?.size==0&&e.d(this,l).delete(y)}}:L}emitRetainEvent(y,b,m){y in e.d(this,n)&&this.executeListener(b,m,e.d(this,n)[y])}once(y,b,m){return this.on(y,b,Object.assign({},m,{count:1}))}forEachListeners(y){let b=!1;for(let[m,O]of e.d(this,l).entries()){if(b)break;for(let[N,[L,G]]of O.entries()){if(b)break;b=y({event:m,listenerId:N,listener:L,count:G,eventListeners:O})===!1}}}forEachEventListeners(y,b){let m=!1,O=[[y,e.d(this,l).get(y)]];for(let[N,L]of O)if(L)for(let[G,[q,J]]of L){if(m)break;m=b({event:N,listenerId:G,listener:q,count:J,eventListeners:L})===!1}}off(){if(arguments.length==1){if(typeof arguments[0]=="number")this.forEachListeners(({listenerId:y,eventListeners:b,event:m})=>{var O;if(y==arguments[0])return b.delete(y),((O=e.d(this,l).get(m))==null?void 0:O.size)==0&&e.d(this,l).delete(m),!1});else if(typeof arguments[0]=="function"){let y=arguments[0];this.forEachListeners(({listenerId:b,listener:m,eventListeners:O,event:N})=>{var L;m==y&&(O.delete(b),((L=e.d(this,l).get(N))==null?void 0:L.size)==0&&e.d(this,l).delete(N))})}}else arguments.length==2&&typeof arguments[0]=="string"&&typeof arguments[1]=="function"&&this.forEachEventListeners(arguments[0],({event:y,listenerId:b,listener:m,eventListeners:O})=>{var N;y==arguments[0]&&m==arguments[1]&&(O.delete(b),((N=e.d(this,l).get(y))==null?void 0:N.size)==0&&e.d(this,l).delete(y))})}waitFor(y,b=0){return new Promise((m,O)=>{let N,L=!1,G;b>0&&(N=setTimeout(()=>{L=!0,this.off(G),O(new Error("Timeout"))},b)),G=this.once(y,q=>{L||(clearTimeout(N),m(q))})})}offAll(y){y?e.d(this,l).delete(y):e.d(this,l).clear()}executeListener(y,b,m){if(!b)return;let O=b.get(y);if(O)try{return O[0](m)}catch{}finally{O[1]>-1&&(O[1]=O[1]-1,O[1]==0&&b.delete(y))}}executeListeners(y,b,m){let O=[];return this.forEachEventListeners(y,({event:N,listenerId:L,eventListeners:G})=>{O.push(this.executeListener(L,G,b)),typeof m=="function"&&m(L),G.size==0&&e.d(this,l).delete(N)}),O}emit(y,b,m){return m&&(e.d(this,n)[y]=b),this.executeListeners(y,b)}},"c"),c=u;l=new WeakMap,n=new WeakMap,c.listenerSeqId=0,t.a=c}),xr=g(t=>{var e=Er();F(),Object.defineProperty(t,"LiteEvent",{enumerable:!0,get:function(){return e.a}})}),Z=p(I()),jr=p(Fe()),st=p(B());function nt(t){return t===null?"Null":t===void 0?"Undefined":typeof t=="function"?"Function":t.constructor&&t.constructor.name}o(nt,"getDataTypeName");async function at(t,e){let l=await e.call(t);return"__esModule"in l||Symbol.toStringTag in l?l.default:l}o(at,"loadAsyncModule");function ot(t,e,l){for(;t.indexOf(e)>-1;)t=t.replace(e,l);return t}o(ot,"replaceAll");function z(t){return t.replace(/([.?*+^$[\]\\(){}|-])/g,"\\$1")}o(z,"escapeRegexpStr");var ut=["String","Number","Boolean","Object","Array","Function","Error","Symbol","RegExp","Date","Null","Undefined","Set","Map","WeakSet","WeakMap"];function le(t){try{return(0,st.isNumber)(t)?parseFloat(t):0}catch{return t}}o(le,"toNumber");function ce(t){try{return t instanceof Date?t:new Date(t)}catch{return parseInt(t)}}o(ce,"toDate");function ks(t){return!!t}o(ks,"toBoolean");function lt(){return Date.now().toString()+parseInt(String(Math.random()*1e3))}o(lt,"randomId");var Ce=p(bt()),Jt=p(Et()),Vt=p(P()),Qt=p(I()),Ne=p(pe()),Ht=p(B()),Pe=p(I()),Wt=p(C()),Kt=p(Yt()),me=p(P());function Bt(t){return t?t.trim().substring(1).trim().split("|").map(e=>e.trim()).map(e=>{if(e=="")return null;let l=e.indexOf("("),n=e.lastIndexOf(")");if(l!==-1&&n!==-1){let u=e.substring(l+1,n).trim(),c=Qi(u);return[e.substring(0,l),c]}else return[e,[]]}).filter(e=>Array.isArray(e)):[]}o(Bt,"parseFormatters");function Ki(...t){t.length==0&&(t.push(["{","}"]),t.push(["[","]"]));let e=t.map(([l,n])=>`(${z(l)}1%.*?%1${z(n)})`);return Vi.replace("__TAG_REGEXP__",e.length>0?e.join("|")+"|":"")}o(Ki,"getNestingParamsRegex");function Bi(t,e="{",l="}"){let n=0,u=0;for(;n<t.length;){let c=t.slice(n,n+e.length),y=t.slice(n,n+l.length);if(c==e){u++,t=t.substring(0,n+e.length)+`${u}%`+t.substring(n+e.length),n+=e.length+String(u).length+1;continue}if(y==l){u>0&&(t=t.substring(0,n)+`%${u}`+t.substring(n)),n+=l.length+String(u).length+1,u--;continue}n++}return t}o(Bi,"addTagFlags");function zi(t,...e){return e.length==0&&(e.push(["{","}"]),e.push(["[","]"])),e.forEach(l=>{t.includes(l[0])&&t.includes(l[1])&&(t=Bi(t,...l))}),t}o(zi,"addTagHelperFlags");function Ji(t,e,l){return[[e,new RegExp(z(e)+"\\d+%")],[l,new RegExp("%\\d+"+z(l))]].forEach(([n,u])=>{let c;for(;(c=u.exec(t))!==null;)c.index===u.lastIndex&&u.lastIndex++,t=t.replace(u,n)}),t}o(Ji,"removeTagFlags");function ke(t,...e){return e.length==0&&(e.push(["{","}"]),e.push(["[","]"])),e.forEach(([l,n])=>{t.includes(l)&&t.includes(n)&&(t=Ji(t,l,n))}),t}o(ke,"removeTagHelperFlags");var Vi=String.raw`((([\'\"])(.*?)\3))|__TAG_REGEXP__([\d]+\.?[\d]?)|((true|false|null)(?=[,\b\s]))|([\w\.]+)|((?<=,)\s*(?=,))(?<=\s*[,\)]?\s*)`;function Qi(t){let e=[],l;t=zi(t);try{let n=new RegExp(Ki(),"g");for(;(l=n.exec(t))!==null;){l.index===n.lastIndex&&n.lastIndex++;let u=l[0];if(u.trim()=="")u=null;else if(u.startsWith("'")&&u.endsWith("'")||u.startsWith('"')&&u.endsWith('"'))u=u.substring(1,u.length-1),u=ke(u);else if(u.startsWith("{")&&u.endsWith("}")||u.startsWith("[")&&u.endsWith("]"))try{u=ke(u),u=(0,Kt.safeParseJson)(u)}catch{}else["true","false","null"].includes(u)?u=JSON.parse(u):(0,Ht.isNumber)(u)?u=parseFloat(u):u=ke(String(u));e.push(u)}}catch{}return e}o(Qi,"parseFormaterParams");function Gi(t,e,l){let n=(0,me.assignObject)({normalize:null,params:null,configKey:null},e),u=o(function(c,y,b){let m=c;if((0,Pe.isFunction)(n.normalize))try{m=n.normalize(m)}catch{}let O=(0,me.assignObject)({},l,(0,Ne.get)(b,n.configKey,{defaultValue:{}})),N;if(n.params==null)N=y;else{N=n.params.map(L=>{let G=(0,Ne.get)(O,L,void 0);return(0,Pe.isFunction)(G)?G(m):G});for(let L=0;L<N.length;L++)y[L]!==void 0&&(N[L]=y[L])}return t.call(this,m,N,O)},"$formatter");return u.$name=e?.configKey,u.configurable=!0,u}o(Gi,"createFormatter");var Ui=o(function(t,e,l){let n=(0,me.assignObject)({params:{}},e);return R(function(u,c,y){let b=(e.params||{}).reduce((m,O)=>(m[O]=y[O]==null?(l||{})[O]:y[O],m),{});if(c.length==1&&(0,Wt.isPlainObject)(c[0]))Object.assign(b,c[0]);else for(let m=0;m<c.length;m++)c[m]!==void 0&&(b[n.params[m]]=c[m]);return t.call(this,u,b,y)},{...e,params:null})},"createFlexFormatter"),R=Gi,zt=Ui;function Xi(t,e="HH:mm:ss"){return(0,Ce.formatDateTime)(t,e,{})}o(Xi,"formatTime");function Q(t={},e){let l=(0,Vt.assignObject)({presets:{}},t);return R(function(n,[u],c){if(u in l.presets&&(0,Qt.isFunction)(l.presets[u]))return l.presets[u](n);if(u in c)u=c[u];else if(u=="number")return n;try{return u==null?n:e.call(this,n,u)}catch{return n}},l)}o(Q,"createDateTimeFormatter");var Gt=Q({normalize:ce,params:["format"],configKey:"datetime.date",presets:{local:t=>t.toLocaleString(),iso:t=>t.toISOString(),utc:t=>t.toUTCString(),gmt:t=>t.toGMTString()}},Ce.formatDateTime),Ut=Q({normalize:t=>{let e=t.getMonth()+1;return Math.floor(e%3==0?e/3:e/3+1)},params:["format"],configKey:"datetime.quarter"},(t,e)=>e[t-1]),Xt=Q({normalize:t=>t.getMonth()+1,params:["format"],configKey:"datetime.month"},(t,e)=>e[t-1]),Zt=Q({normalize:t=>t.getDay(),params:["format"],configKey:"datetime.weekday"},(t,e)=>e[t]),er=Q({normalize:ce,params:["format"],configKey:"datetime.time",presets:{local:t=>t.toLocaleTimeString(),timestamp:t=>t.getTime()}},Xi),tr=R((t,[e],l)=>(0,Jt.relativeTime)(t,e,l),{normalize:ce,params:["base"],configKey:"datetime.relativeTime"}),rr=p(pe()),ir=p(B());function Zi(t,e=3){let l=new RegExp(String.raw`(?!^)(?=(\d{${e}})+$)`,"g"),n=t.replace(l,",");return n.startsWith(",")&&(n=n.substring(1)),n.endsWith(",")&&(n=n.substring(0,n.length-2)),n}o(Zi,"addSplitChars");function Re(t,e={},l={}){let{symbol:n="",division:u=3,prefix:c="",precision:y=2,suffix:b="",unit:m=0,radix:O=3,format:N="{symbol}{value}{unit}"}=e,[L,G]=String(t).split(".");m>0&&O>0&&(L.length<O*m&&(L=new Array(O*m-L.length+1).fill(0).join("")+L),G=L.substring(Number(L),L.length-O*m)+G,L=L.substring(0,L.length-O*m),L==""&&(L="0"));let q=[];q.push(Zi(L,u)),G&&(0,ir.isNumber)(y)&&y!=0&&y!=0&&(y==-1?q.push(`.${G}`):y>0&&(G.length,y<0?G=String(parseFloat(`0.${G}`)):G=String(parseFloat(`0.${G}`).toFixed(y)).split(".")[1],q.push(`.${G}`)));let J=(0,rr.get)(l,"units",{defaultValue:[]})[m]||"";return N.replace("{value}",q.join("")).replace("{symbol}",n).replace("{prefix}",c).replace("{suffix}",b).replace("{unit}",J)}o(Re,"toCurrency");var sr=zt((t,e={},l)=>(e.format in l&&(e.format=l[e.format]),e.unit=parseInt(e.unit)||0,e.unit>l.units.length-1&&(e.unit=l.units.length-1),e.unit<0&&(e.unit=0),e.unit>0&&e.precision==2&&(e.precision=-1),Re(t,e,l)),{normalize:t=>le(t),params:["format","unit","precision","prefix","suffix","division","symbol","radix"],configKey:"currency"},{format:"default",unit:0}),nr=R(function(t,[e,l],n){return Re(t,{division:l,precision:e},n)},{normalize:le,params:["precision","division"],configKey:"number"}),ar={$config:{datetime:{units:["Year","Quarter","Month","Week","Day","Hour","Minute","Second","Millisecond","Microsecond"],date:{long:"YYYY/MM/DD HH:mm:ss",short:"YYYY/MM/DD",format:"local"},quarter:{long:["First Quarter","Second Quarter","Third Quarter","Fourth Quarter"],short:["Q1","Q2","Q3","Q4"],format:"short"},month:{long:["January","February","March","April","May","June","July","August","September","October","November","December"],short:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sept","Oct","Nov","Dec"],format:"long"},weekday:{long:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],short:["Sun","Mon","Tues","Wed","Thur","Fri","Sat"],format:"long"},time:{long:"HH:mm:ss",short:"HH:mm:ss",format:"local"},timeSlots:{slots:[12],lowerCases:["am","pm"],upperCases:["AM","PM"]},relativeTime:{units:["seconds","minutes","hours","days","weeks","months","years"],now:"Just now",before:"{value} {unit} ago",after:"after {value} {unit}"}},currency:{default:"{symbol}{value}{unit}",long:"{prefix} {symbol}{value}{unit}{suffix}",short:"{symbol}{value}{unit}",custom:"{prefix} {symbol}{value}{unit}{suffix}",format:"default",units:[""," thousands"," millions"," billions"," trillions"],radix:3,symbol:"$",prefix:"USD",suffix:"",division:3,precision:2},number:{division:3,precision:-1}},$types:{Null:t=>"",Undefined:t=>"",Error:t=>"ERROR",Boolean:t=>t?"True":"False"},date:Gt,quarter:Ut,month:Xt,weekday:Zt,time:er,relativeTime:tr,currency:sr,number:nr},j=p(ur()),lr={$config:{datetime:{units:j.CN_DATETIME_UNITS,date:{long:"YYYY年M月D日 HH点mm分ss秒",short:"YYYY年M月D日",format:"local"},quarter:{long:["一季度","二季度","三季度","四季度"],short:["Q1","Q2","Q3","Q4"],format:"short"},month:{long:j.CN_MONTH_NAMES,short:j.CN_SHORT_MONTH_NAMES,format:"long"},weekday:{long:j.CN_WEEK_DAYS,short:j.CN_SHORT_WEEK_DAYS,format:"long"},time:{long:"HH点mm分ss秒",short:"HH:mm:ss",format:"local"},timeSlots:{slots:[6,9,11,13,18],lowerCases:["凌晨","早上","上午","中午","下午","晚上"],upperCases:["凌晨","早上","上午","中午","下午","晚上"]},relativeTime:{units:["秒","分钟","小时","天","周","个月","年"],now:"刚刚",before:"{value}{unit}前",after:"{value}{unit}后"}},currency:{units:["","万","亿","万亿","万万亿"],radix:4,symbol:"¥",prefix:"RMB",suffix:"元",division:4,precision:2},number:{division:4,precision:-1}},$types:{Null:t=>"",Undefined:t=>"",Boolean:t=>t?"是":"否"}},cr={"*":{},en:ar,zh:lr},He=p(C()),ye=p(pe()),be=p(I()),yr=p(Fe()),We=p(P()),M="en",fr=[{name:"zh",title:"中文",default:!0,active:!0},{name:"en",title:"英文"}],br=p(dr()),T=class{constructor(t){d(this,"_formatters",{}),d(this,"_activeFormatters",{}),d(this,"_activeFormattersConfigs",{}),d(this,"_scope"),d(this,"_language"),d(this,"_formatterCache",{typedFormatters:{},formatters:{}}),this._scope=t}get activeLanguage(){var t;return this._language||(this._language=((t=this._scope)==null?void 0:t.activeLanguage)||"zh"),this._language}get scope(){return this._scope}async change(t){var e,l,n,u,c,y,b;try{let m=t;if(t in this.formatters||(m=((l=(e=this.scope)==null?void 0:e.getLanguage(t))==null?void 0:l.fallback)||"zh",(n=this.scope)==null||n.logger.warn(`没有配置<${t}>格式化器,使用后退语言<${m}>替代.`)),m){let O=this.formatters[m];(0,be.isFunction)(O)?this._activeFormatters=await at(this,O):this._activeFormatters=O,this._formatterCache={typedFormatters:{},formatters:{}},this.generateFormattersConfigs(m),this._language=t}else(c=this.scope)==null||c.logger.warn(`未指定<${t}>格式化器配置(scope=${(u=this.scope)==null?void 0:u.id})`)}catch(m){(b=this.scope)==null||b.logger.error(`当加载<${t}>格式化器时出错(scope=${(y=this.scope)==null?void 0:y.id}): ${m.stack}`)}}generateFormattersConfigs(t){var e,l,n,u;try{let c=[],y=(l=(e=this.scope)==null?void 0:e.getLanguage(t))==null?void 0:l.fallback;this.scope&&(y&&c.push(this.scope.global.formatters.getConfig(y)),c.push(this.scope.global.formatters.getConfig("en")),c.push(this.scope.global.formatters.getConfig(t))),c.push(this.getConfig("en")),y&&c.push(this.getConfig(y)),c.push(this.getConfig(t)),this._activeFormattersConfigs=c.reduce((b,m)=>((0,He.isPlainObject)(m)&&(b=(0,yr.deepMerge)(b,(0,br.deepClone)(m),{$merge:"replace"})),b),{})}catch(c){(n=this.scope)!=null&&n.debug&&console.error(`当生成<${t}>格式化器配置时出错(scope=${(u=this.scope)==null?void 0:u.id}):${c.stack}`),this._activeFormattersConfigs={}}}updateConfig(t,e){if(t in this._formatters){let l=this._formatters[t];"$config"in l||(l.$config={}),(0,We.assignObject)(l.$config,e)}t===this._language&&this.generateFormattersConfigs(t)}registerLanguageFormatters(t,e){this._formatters[t]=e}loadInitials(t){this._formatters=t}register(t,e,l){let{language:n="*"}=l||{};if(!(0,be.isFunction)(e)||typeof t!="string")throw new TypeError("格式化器必须是一个函数");(Array.isArray(n)?n:n?n.split(","):[]).forEach(u=>{if(u in this._formatters||(this._formatters[u]={}),typeof this._formatters[u]!="function"){this._formatters[u]||(this._formatters[u]={});let c=this._formatters[u];ut.includes(t)?(c.$types||(c.$types={}),c.$types[t]=e):c[t]=e}})}getConfig(t){return t?(0,ye.get)(this._formatters,`${t}.$config`,{defaultValue:{}}):{}}getTypes(t){return t?(0,ye.get)(this._formatters,`${t}.$types`,{defaultValue:{}}):{}}getFormatters(t){return t?(0,ye.get)(this._formatters,t,{defaultValue:{}}):{}}get formatters(){return this._formatters}get activeFormatters(){return this._activeFormatters}get config(){return this._activeFormattersConfigs}get types(){return this._activeFormatters.$types}get(t,e){var l,n,u,c,y,b,m,O,N,L,G,q;let{on:J,inGlobal:fe}=(0,We.assignObject)({on:"scope",inGlobal:!0},e);if(J=="types"&&t in this._formatterCache.typedFormatters)return this._formatterCache.typedFormatters[t];if(J=="scope"&&t in this._formatterCache.formatters)return this._formatterCache.formatters[t];let ve=(n=(l=this.scope)==null?void 0:l.getLanguage(this.activeLanguage))==null?void 0:n.fallback,ne=[];J=="types"?(ne.push(this.types),ve&&ne.push(this.getTypes(ve)),ve!=M&&ne.push(this.getTypes(M)),ne.push(this.getTypes("*")),fe&&(ne.push((u=this.scope)==null?void 0:u.global.formatters.types),ve&&ne.push((c=this.scope)==null?void 0:c.global.formatters.getTypes(ve)),ve!=M&&ne.push((y=this.scope)==null?void 0:y.global.formatters.getTypes(M)),ne.push((b=this.scope)==null?void 0:b.global.formatters.getTypes("*")),ne.push((m=this.scope)==null?void 0:m.global.formatters.getTypes("en")))):J=="scope"&&(ne.push(this._activeFormatters),ve&&ne.push(this.getFormatters(ve)),ve!=M&&ne.push(this.getFormatters(M)),ne.push(this.getFormatters("*")),ne.push(this.getFormatters("en")),fe&&(ne.push((O=this.scope)==null?void 0:O.global.formatters.activeFormatters),ve&&ne.push((N=this.scope)==null?void 0:N.global.formatters.getFormatters(ve)),ve!=M&&ne.push((L=this.scope)==null?void 0:L.global.formatters.getFormatters(M)),ne.push((G=this.scope)==null?void 0:G.global.formatters.getFormatters("*")),ne.push((q=this.scope)==null?void 0:q.global.formatters.getFormatters("en"))));for(let Ue of ne)if(Ue&&(0,He.isPlainObject)(Ue)&&t in Ue){let De=Ue[t];if((0,be.isFunction)(De))return J=="types"?this._formatterCache.typedFormatters[t]=De:this._formatterCache.formatters[t]=De,De}}};o(T,"VoerkaI18nFormatterRegistry");var U=class extends Error{};o(U,"InvalidLanguageError");var wr=p(xr()),Mr={get(t){if(globalThis.localStorage)return globalThis.localStorage.getItem(t)},set(t,e){globalThis.localStorage&&globalThis.localStorage.setItem(t,e)},remove(t){globalThis.localStorage&&globalThis.localStorage.removeItem(t)}},Dr=p(P()),Lr={warn:console.warn,error:console.error,info:console.info,debug:console.debug};function Or(t){return Object.keys(Lr).reduce((e,l)=>(e[l]=function(...n){t&&Lr[l]("[VoerkaI18n]",...n)},e),{})}o(Or,"createLogger");var ms={debug:!0,defaultLanguage:"zh",activeLanguage:"zh",storage:Mr,languages:[{name:"zh",title:"中文",default:!0},{name:"en",title:"英文"}]},ee=class extends wr.LiteEvent{constructor(t){if(super(),d(this,"_scopes",[]),d(this,"_defaultMessageLoader"),d(this,"_formatters",new T),d(this,"_appScopeId"),d(this,"_options"),d(this,"_logger"),d(this,"_appInitilized",!1),ee.instance)return ee.instance;this._options=(0,jr.deepMerge)({},ms,t),this._logger=Or(this.options.debug),ee.instance=this,this.loadInitialFormatters().then(()=>{this.loadOptionsFromStorage()})}get debug(){return this.options.debug}get options(){return this._options}get logger(){return this._logger}get scopes(){return this._scopes}get appScopeId(){return this._appScopeId}get activeLanguage(){return this.options.activeLanguage}get defaultLanguage(){return this.options.defaultLanguage}get languages(){return this.options.languages}get defaultMessageLoader(){return this._defaultMessageLoader}get formatters(){return this._formatters}get storage(){return this.options.storage}initApp(t){if(this._appInitilized){this.logger.warn("VoerkaI18n只允许注册一个library=false的i18nScope,请检查是否正确配置了library参数");return}(0,Dr.assignObject)(this.options,t),this.loadOptionsFromStorage(),this._appInitilized=!0}loadOptionsFromStorage(){if(this.options.storage){let t=this.options.storage.get("language");t&&!this.hasLanguage(t)&&this.logger.warn("从存储中读取到未配置的语言名称参数:",t),t&&this.logger.info("从存储中读取到当前语言名称参数:",t),t&&t!=="undefined"&&(this.options.activeLanguage=t,this.logger.debug("当前语言设置为:",t))}}saveOptionsToStorage(){if(this.options.storage){let t=this.options.storage;if(!this.options.activeLanguage)return;t.set("language",this.activeLanguage),this.logger.debug("当前语言设置已保存到存储:",this.activeLanguage)}}async loadInitialFormatters(){this._formatters.loadInitials(cr),this._formatters.change(this.options.activeLanguage)}async loadMessagesFromDefaultLoader(t,e){if(this._defaultMessageLoader&&(0,Z.isFunction)(this._defaultMessageLoader))try{return await this._defaultMessageLoader.call(e,t,e)}catch(l){return this.logger.debug(`从远程加载语言包${t}文件出错:${l.stack}`),{}}}async change(t){if(this.languages.findIndex(e=>e.name===t)!==-1||(0,Z.isFunction)(this._defaultMessageLoader))return this._formatters.change(t),await this._refreshScopes(t),this.options.activeLanguage=t,this.emit("change",t),this.saveOptionsToStorage(),this.logger.info("语言已切换为:",t),t;throw new U(t)}async _refreshScopes(t){try{let e=this._scopes.map(l=>l.refresh(t));Promise.allSettled?await Promise.allSettled(e):await Promise.all(e)}catch(e){this.logger.error("刷新语言作用域时出错:",e.stack)}}async register(t){let e=this._scopes.length===0&&!t.options.library;this._scopes.push(t),this._scopes.length===1&&(this._appScopeId=t.id),t.options.library===!1&&(this._appScopeId=t.id),await t.refresh(this.activeLanguage),e&&this.emit("ready",{language:this.activeLanguage,scope:t.id},!0)}async ready(){return await this.waitFor("ready")}registerFormatter(t,e,l){let{language:n="*"}=l||{};if(!(0,Z.isFunction)(e)||typeof t!="string")throw new TypeError("格式化器必须是一个函数");this._formatters.register(t,e,{language:n})}registerDefaultLoader(t){if(!(0,Z.isFunction)(t))throw new Error("默认语言加载器必须是一个函数");this._defaultMessageLoader=t}async refresh(){return this._refreshScopes(this.activeLanguage)}clearPatchedMessages(){this._scopes.forEach(t=>t.clearPatchedMessages())}hasLanguage(t){return this.languages.findIndex(e=>e.name==t)!=-1}},Y=ee;o(Y,"VoerkaI18nManager"),d(Y,"instance");var H=p(C()),re=p(I()),Be=p(B()),Tr=p(C()),Ke=p(I()),$r=p(C()),_e=p(I()),te=/\{\s*(\w+)?((\s*\|\s*\w*(\(.*\)){0,1}\s*)*)\s*\}/g;function Ir(t,e,l={}){let n=t,u,c=Object.assign({replaceAll:!0},l);for(te.lastIndex=0;(u=te.exec(n))!==null;){u.index===te.lastIndex&&te.lastIndex++;let y=u[1]||"",b=Bt(u[2]||"");if((0,_e.isFunction)(e))try{let m=e(y,b,u[0]);c.replaceAll?n=ot(n,u[0],m):n=n.replace(u[0],m)}catch{break}te.lastIndex=0}return n}o(Ir,"forEachInterpolatedVars");function ds(t,e,l,n){if(e.length===0)return t;let u=t;for(let c of e)try{u=c(u,l.formatters.config)}catch(y){y.formatter=c.$name,l.logger.error(`当执行格式化器<${c.$name}>时出错: ${n},${y.stack}`)}return u}o(ds,"executeFormatter");function ys(t,e,l){let n=[];for(let[u,c]of l){let y=t.formatters.get(u,{on:"scope"}),b;(0,_e.isFunction)(y)?b=o((m,O)=>y.call(t.formatters.config,m,c,O),"formatter"):b=o(m=>(0,_e.isFunction)(m[u])?String(m[u](...c)):String(m),"formatter"),b.$name=u,n.push(b)}return n}o(ys,"wrapperFormatters");function qr(t,e,l,n,u){let c=n,y=ys(t,e,l),b=t.formatters.get(nt(n),{on:"types"});return b&&y.splice(0,0,(m,O)=>b.call(O,m,[],O)),ds(c,y,t,u)}o(qr,"getFormattedValue");function Ar(t,...e){let l=this,n=l.global.activeLanguage;if(e.length===1&&(0,$r.isPlainObject)(e[0])){let u=e[0];return Ir(t,(c,y,b)=>{let m=c in u?u[c]:"";return qr(l,n,y,m,t)})}else{let u=e.length===1&&Array.isArray(e[0])?[...e[0]]:e,c=0;return Ir(t,(y,b,m)=>qr(l,n,b,u.length>c?u[c++]:void 0,t),{replaceAll:!1})}}o(Ar,"replaceInterpolatedVars");function bs(t){return(0,Be.isNumber)(t)}o(bs,"isMessageId");function _s(t,e){try{return Array.isArray(t)?t.length>e?t[e]:t[t.length-1]:t}catch{return Array.isArray(t)?t[0]:t}}o(_s,"getPluraMessage");function kr(t,...e){var l;let n=this,u=t,c=[],y=null;if(typeof t!="string")return t;try{if(arguments.length===2&&(0,Tr.isPlainObject)(arguments[1])){let b=arguments[1];for(let[m,O]of Object.entries(b)){if((0,Ke.isFunction)(O))try{b[m]=O()}catch{b[m]=O}let N=typeof b[m]=="number";(y==null&&N||m.startsWith("$")&&N)&&(y=b[m])}c=[b]}else arguments.length>=2&&(c=[...arguments].splice(1).map((b,m)=>{try{b=(0,Ke.isFunction)(b)?b():b,(0,Be.isNumber)(b)&&(y=parseInt(b))}catch{return String(b)}return b}));if(bs(t))u=n.current[t]||t;else{let b=n.idMap[t];u=(l=b?n.current[b]:n.current[t])!=null?l:t}return Array.isArray(u)&&u.length>0&&(y!==null?u=_s(u,y):u=u[0]),e.length===0?u:Ar.call(n,u,...c)}catch{return u}}o(kr,"translate");var Nr=p(P()),ze=class{constructor(t){d(this,"_options"),d(this,"_global"),d(this,"_refreshing",!1),d(this,"_t"),d(this,"_formatterRegistry"),d(this,"_defaultLanguage"),d(this,"_activeLanguage"),d(this,"_currentMessages",{}),d(this,"_patchedMessages",{}),this._options=(0,Nr.assignObject)({id:lt(),library:!1,debug:!1,languages:[],messages:{},idMap:{},formatters:{}},t),this.init(),this._global=this.registerToManager(),this._t=kr.bind(this)}get options(){return this._options}get id(){return this._options.id}get logger(){return this._global.logger}get debug(){return this._options.debug}get defaultLanguage(){return this._global.defaultLanguage}get activeLanguage(){return this._global.activeLanguage}get default(){return this._options.messages[this._defaultLanguage]}get current(){return this._currentMessages}get messages(){return this._options.messages}get idMap(){return this._options.idMap}get languages(){return this._options.languages}get global(){return this._global}get formatters(){return this._formatterRegistry}get activeFormatters(){return this._formatterRegistry.formatters}get t(){return this._t}init(){if(!Array.isArray(this.languages))this.logger.warn("无效的语言配置,将使用默认语言配置"),this._options.languages=Object.assign([],fr);else if(this.languages.length==0)throw new Error("[VoerkaI18n]无效的语言配置,必须提供有效的默认语言和活动语言");let t,e;this.languages.forEach(n=>{n.fallback||(n.fallback=M),n.default&&(e=n.name),n.active&&(t=n.name)});let l=this._options.messages;if(e in l||(e=Object.keys(l)[0]),t in l||(t=e),!(e in l))throw new Error("[VoerkaI18n]无效的语言配置,必须提供有效的默认语言和活动语言.");if(this._activeLanguage=t,this._defaultLanguage=e,(0,re.isFunction)(this.messages[this._defaultLanguage]))throw new Error("[VoerkaI18n] 默认语言包必须是静态内容,不能使用异步加载的方式.");this._currentMessages=this.messages[this._activeLanguage],this.loadInitialFormatters()}registerToManager(t){return globalThis.VoerkaI18n||(globalThis.VoerkaI18n=new Y({debug:this._options.debug,defaultLanguage:this._defaultLanguage,activeLanguage:this._activeLanguage,languages:this._options.languages,storage:this._options.storage})),this._options.library||globalThis.VoerkaI18n.initApp({defaultLanguage:this._defaultLanguage,activeLanguage:this._activeLanguage,languages:this._options.languages,storage:this._options.storage,debug:this._options.debug}),this._global=globalThis.VoerkaI18n,this._global.register(this).then(()=>{this.onRegisterSuccess.call(this),t?.call(this)}).catch(e=>{this.onRegisterFail.call(this,e)}),this._global}onRegisterSuccess(){typeof this._options.ready=="function"&&this._options.ready.call(this),this.global.emit("registered",{language:this.activeLanguage,scope:this.id}),this._restorePatchedMessages(this._currentMessages,this.activeLanguage),this._patch(this._currentMessages,this.activeLanguage)}onRegisterFail(t){typeof this._options.ready=="function"&&this._options.ready.call(this,t)}registerFormatter(t,e,l){let{language:n="*",asGlobal:u=!0}=l||{};u?this.global.registerFormatter(t,e,{language:n}):this.formatters.register(t,e,{language:n})}loadInitialFormatters(){this._formatterRegistry=new T(this),this.formatters.loadInitials(this._options.formatters),delete this._options.formatters}registerDefaultLoader(t){this.global.registerDefaultLoader(t)}getLanguage(t){let e=this.languages.findIndex(l=>l.name==t);if(e!==-1)return this.languages[e]}hasLanguage(t){return this.languages.findIndex(e=>e.name==t)!=-1}fallbackToDefault(){this._currentMessages=this.default,this._activeLanguage=this._defaultLanguage}async loadLanguageMessages(t){this.logger.debug(`准备加载语言包:${t}`);let e=this.messages[t],l={};if((0,H.isPlainObject)(e))l=e;else if((0,re.isFunction)(e)){let n=await e.call(this);"__esModule"in n||Symbol.toStringTag in n?l=n.default:l=n}else if((0,re.isFunction)(this.global.defaultMessageLoader)){let n=await this.global.loadMessagesFromDefaultLoader(t,this);(0,H.isPlainObject)(n)&&((0,H.isPlainObject)(n.$config)&&(this.formatters.updateConfig(t,n.$config),delete n.$config),l=Object.assign({$remote:!0},this.default,n))}else throw new Error(`没有为<${t}>指定语言包加载器`);return l}async refresh(t){if(this._refreshing=!0,t||(t=this.activeLanguage),t===this.defaultLanguage){this._currentMessages=this.default,this._restorePatchedMessages(this._currentMessages,t),await this._patch(this._currentMessages,t),await this.formatters.change(t),this._refreshing=!1;return}else try{let e=await this.loadLanguageMessages(t);e?(this._currentMessages=e,this._activeLanguage=t,this._restorePatchedMessages(this._currentMessages,t),e.$remote||await this._patch(this._currentMessages,t),await this.formatters.change(t)):(this.logger.warn(`无法加载语言包<${t}>(scope=${this.id}),将回退到默认语言`),this.fallbackToDefault())}catch(e){this.logger.warn(`当加载语言包<${t}>时出错(scope=${this.id}): ${e.message}`),this.fallbackToDefault()}finally{this._refreshing=!1}}async _patch(t,e){if((0,re.isFunction)(this.global.loadMessagesFromDefaultLoader))try{let l=await this.global.loadMessagesFromDefaultLoader(e,this);(0,H.isPlainObject)(l)&&(Object.assign(t,l),this._savePatchedMessages(l,e),this._global.emit("patched",{language:e,scope:this.id}),this.logger.debug(`已更新了语言补丁包<${e}>(scope=${this.id}),共${Object.keys(l).length}条`))}catch(l){this.logger.error(`当从远程加载语言补丁包<${e}>时出错:${l.stack}(scope=${this})`)}}_restorePatchedMessages(t,e){let l=this._getPatchedMessages(e);(0,H.isPlainObject)(l)&&(Object.assign(t,l),this._global.emit("restore",{language:e,scope:this.id}),this.logger.debug(`成功恢复补丁语言包<${e}>(scope=${this.id})`))}_savePatchedMessages(t,e){if(this.global.storage)try{this.global.storage.set(`voerkai18n_${this.id}_${e}_patched_messages`,JSON.stringify(t))}catch(l){this.logger.error(`保存语言包补丁(${e})时出错:${l.stack}(scope=${this.id})`)}}clearPatchedMessages(t){if(this.global.storage){let e=t?[t]:this.languages.map(l=>l.name);for(let l of e)this.global.storage.remove(`voerkai18n_${this.id}_${l}_patched_messages`)}}_getPatchedMessages(t){try{return this.global.storage?this.global.storage.get(`voerkai18n_${this.id}_${t}_patched_messages`):{}}catch(e){return this.logger.error(`读取语言包补丁(${t})时出错:${e.stack}(scope=${this.id})`),{}}}on(t,e){return this._global.on(t,e)}once(t,e){return this._global.once(t,e)}off(t,e){return this._global.off(t,e)}async change(t){return await this._global.change(t)}ready(t){return this._global.ready().then(t)}};o(ze,"VoerkaI18nScope");const defaultFormatters={},defaultMessages={1:"白色",2:"红色",3:"黄色",4:"绿色",5:"青色",6:"洋红色",7:"蓝色",8:"随层",9:"随块",10:"索引颜色",11:"真彩色",12:"所有样式",13:"正在使用样式",14:"开始转换",15:"线",16:"符号与箭头",17:"调整",18:"主单位",19:"生成打印PDF",20:"批量下载",21:"所有图元",22:"选择文件",23:"继续打开文件",24:"数据库",25:"数据库显示",26:"标注样式",27:"全局字典",28:"类型",29:"线型比例",30:"渲染顺序",31:"法向坐标",32:"其他信息",33:"顶点",34:"顶点起始宽度",35:"顶点中止宽度",36:"全局宽度",37:"曲线参数",38:"几何图形",39:"开始点",40:"结束点",41:"是否填充",42:"填充透明度",43:"位置坐标",44:"缩放比例",45:"圆心坐标",46:"弧心坐标",47:"CAD图形",48:"批注图形",49:"无选择",50:"多段线",51:"对齐尺寸",52:"长度测量",53:"面积测量",54:"角度测量",55:"坐标测试",56:"引线标注",57:"审图标注",58:"云线批注",59:"形状批注",60:"新增图层",61:"删除图层",62:"关闭所有图层",63:"搜索图层",64:"顶点起始线宽",65:"顶点中止线宽",66:"全局线宽",67:"当前线宽为",68:"半宽",69:"倒角",70:"指定第一个倒角距离",71:"指定第二个倒角距离",72:"指定矩形的标高",73:"指定矩形的圆角半径",74:"指定矩形的厚度",75:"指定矩形的宽度",76:"输入当前单位计算的矩形面积",77:"计算矩形标注时的依据",78:"输入矩形的长度",79:"标高",80:"圆角",81:"厚角",82:"指定另一个角",83:"指定圆弧的起点",84:"指定圆弧的第二个点",85:"按住",86:"键取相反方向",87:"弦长",88:"修改半径",89:"指定椭圆的轴端点",90:"指定椭圆的另一个轴端点",91:"指定另一条半轴长度",92:"指定圆的圆心",93:"三点",94:"两点",95:"指定圆的半径",96:"指定圆的直径",97:"指定圆弧夹角",98:"指定椭圆弧的轴端点",99:"指定椭圆弧的中心点",100:"指定椭圆弧轴的端点",101:"指定绕主轴旋转的角度",102:"指定起点角度",103:"指定端点角度",104:"夹角",105:"指定椭圆弧轴的另一个端点",106:"指定圆弧的夹角",107:"不使用缓存",108:"输入比例因子",109:"指定另一个角点",110:"梦想在线画图",111:"选择更多颜色",112:"线宽",113:"AI",114:"登录",115:"语言",116:"主题",117:"图层",118:"矩形阵列",119:"环形阵列",120:"行数",121:"列数",122:"行偏移",123:"列偏移",124:"阵列角度",125:"提示",126:"默认情况下,如何行偏移为负值,则行添加在下面。如果列偏移为负值,则列添加在左边",127:"中心点",128:"方法",129:"项目总数",130:"填充角度",131:"项目间角度",132:"对于填充角度,正值指定逆时针旋转,负值指定顺时针旋转",133:"复制时旋转项目",134:"选择对象",135:"已选择",136:"个",137:"对象",138:"名称",139:"浏览",140:"是",141:"否",142:"创建块",143:"基点",144:"在屏幕上指定",145:"拾取点",146:"保留",147:"转换为块",148:"删除",149:"未选定对象",150:"已选择对象",151:"说明",152:"可见",153:"锁定",154:"打印",155:"颜色",156:"线性",157:"反选",158:"确定",159:"关闭",160:"图纸",161:"界限",162:"显示",163:"区域",164:"上次",165:"范围",166:"自由",167:"选择",168:"固定",169:"比例",170:"大小",171:"左下",172:"角",173:"坐标",174:"右上",175:"尺寸",176:"方向",177:"参数",178:"毫米",179:"绘图",180:"单位",181:"添加新图纸",182:"已加载的线型",183:"线型",184:"外观",185:"查找",186:"内容",187:"方式",188:"全局",189:"矩形",190:"异形",191:"全字",192:"匹配",193:"替换",194:"全部",195:"基础",196:"版本号",197:"打开文件",198:"视区平移",199:"回退",200:"重做",201:"圆",202:"前置",203:"文件",204:"新建",205:"编辑",206:"剪切",207:"复制",208:"带基点复制",209:"粘贴",210:"全部选择",211:"查找文字",212:"插入",213:"视图",214:"重画",215:"窗口缩放",216:"上一个",217:"视区旋转",218:"自定义旋转角度",219:"格式",220:"将对象的图层置为当前",221:"恢复上一个图层状态",222:"图层漫游",223:"对象修改图层匹配",224:"选择关闭图层",225:"打开所有图层",226:"图层锁定",227:"图层解锁",228:"图层合并",229:"图层删除",230:"文字样式",231:"点样式",232:"工具",233:"距离",234:"半径",235:"角度",236:"面积",237:"点坐标",238:"直线",239:"多线段",240:"正多边形",241:"圆弧",242:"样条线",243:"椭圆",244:"椭圆弧",245:"点",246:"文字",247:"填充",248:"图片",249:"标注",250:"修改",251:"批注",252:"测试",253:"地图",254:"帮助",255:"关于",256:"CAD梦想在线画图",257:"另存为mxweb文件",258:"重画命令",259:"窗口缩放命令",260:"显示全部",261:"视区旋转90度",262:"全屏模式",263:"对象特性",264:"图块库",265:"图纸库",266:"数据库展示",267:"绘线命令",268:"绘多线段命令",269:"绘正多边形命令",270:"绘矩形框命令",271:"绘圆弧命令",272:"绘样条线命令",273:"绘椭圆命令",274:"绘椭圆弧命令",275:"插入图块命令",276:"创建块命令",277:"绘点命令",278:"写文字命令",279:"插入图片命令",280:"绘多行文本",281:"绘填充命令",282:"云线",283:"表格",284:"圆环",285:"删除命令",286:"复制命令",287:"移动命令",288:"旋转命令",289:"缩放命令",290:"偏移",291:"阵列",292:"镜像命令",293:"离散曲线命令",294:"导角命令",295:"导圆角命令",296:"剪切命令",297:"延伸命令",298:"拉伸命令",299:"分解命令",300:"打断命令",301:"合并命令",302:"线性标注",303:"对齐标注",304:"角度标注",305:"半径标注",306:"直径标注",307:"后置",308:"置于对象之上",309:"置于对象之下",310:"另存为dwg文件",311:"插入图片",312:"插入图块",313:"插入表格",314:"顺时针旋转90度",315:"逆时针旋转90度",316:"视区背景色",317:"图层工具",318:"对象修改设置为当前层",319:"对象复制到新图层",320:"编辑文字",321:"查找替换文字",322:"快速选择",323:"图纸比对",324:"查询",325:"图形识别",326:"查看已识别图形列表",327:"铅笔命令",328:"面积标注",329:"坐标标注",330:"箭头标注",331:"保存批注",332:"恢复批注",333:"插件测试",334:"扩展工具",335:"谷歌地图",336:"高德矢量",337:"高德影像",338:"天地图地图",339:"百度地图",340:"OSM地图",341:"地图下载",342:"绘GIS Point",343:"绘GIS MultPoint",344:"绘GIS LineString",345:"绘GIS MultiLineString",346:"绘GIS DrawPolygon",347:"输出geojson",348:"设置",349:"打开",350:"使用缓存",351:"快速打开",352:"忽略缓存",353:"重新转换",354:"另存为",355:"MxWeb格式",356:"梦想在线CAD文件",357:"Dwg格式",358:"AutoCad图纸",359:"栅格",360:"正交",361:"极轴",362:"对象捕捉",363:"对象追踪",364:"全屏显示",365:"正在打开文件中",366:"更新显示",367:"打开图纸失败",368:"点取文字插入点",369:"当前浏览器不支持部分全屏",370:"输入选项",371:"当前",372:"世界",373:"相对角度",374:"输入视区旋转角度",375:"输入视区旋转相对角度",376:"请框选范围打印",377:"指定输出范围第一点",378:"按比例打印",379:"图纸横向",380:"输入图纸大小",381:"自定义",382:"输入打印比例",383:"图纸上一个毫米对应的CAD绘图单位",384:"输入的比例不对",385:"指定指定打印中心位置",386:"指定输出范围第二点",387:"或",388:"指定顶点",389:"指定角顶点",390:"指定角的第一个端点",391:"指定角的第二个端点",392:"选择第二条直线",393:"所选对象不是直线",394:"指定标注弧线位置",395:"象限点",396:"输入",397:"标注文字",398:"指定标注文字的角度",399:"指定圆环的内径",400:"指定圆环的外径",401:"指定圆环的中心点",402:"指定第一条尺寸界线原点",403:"选择标注对象",404:"所选对象不是直线、圆弧或圆",405:"指定第二条尺寸界线原点",406:"指定尺寸线位置",407:"文本",408:"输入标注文字",409:"选择圆弧或者圆",410:"指定对角点",411:"所选对象不是圆弧或圆",412:"水平",413:"垂直",414:"旋转",415:"指定尺寸线的角度",416:"第一点",417:"指定第一个角点",418:"指定起点",419:"弧长",420:"多边形",421:"徒手画",422:"样式",423:"反转方向",424:"请输入最小弧长",425:"指定最小弧度长度过小",426:"指定最大弧长",427:"指定最大弧度长度过小",428:"指定最大弧度比最小弧度还小,无效",429:"选择圆弧样式",430:"普通",431:"手绘",432:"指定下一点",433:"放弃",434:"沿云线路径引导十字光标",435:"选择需要离散的实体",436:"选择要做成块的对象",437:"指定基点",438:"位移",439:"指定位移",440:"指定第二个点",441:"使用第一个点作为位移",442:"水印",443:"新建图层",444:"当前选中样式已被修改",445:"是否保存",446:'样式)"+ "0',447:"样式名称重复",448:"偏移距离",449:"陈列对象",450:"超出最大阵列对象个数",451:"限制",452:"mxweb文件保存失败",453:"点取缩放区域",454:"没有保存的上一个视图",455:"命令",456:"指定第一点",457:"指定下一个点",458:"闭合",459:"总计",460:"已放弃所有线段",461:"指定圆弧的端点",462:"按住 Ctrl 键以切换方向",463:"圆心",464:"第二个点",465:"指定夹角",466:"指定圆弧的圆心",467:"指定圆弧半径",468:"指定圆弧的弦方向",469:"按住 Ctrl 键切换方向",470:"长度",471:"指定弦长",472:"弦长不能大于直径",473:"无效",474:"指定圆弧的半径",475:"指定圆弧起点切向",476:"端点",477:"指定点",478:"指定角的顶点",479:"直线是平行的",480:"指定第二个端点",481:"加模式",482:"减模式",483:"增加面积",484:"减少面积",485:"退出",486:"选定的对象没有面积",487:"周长",488:"总面积",489:"选择圆弧或圆",490:"直径",491:"移动光标",492:"快速",493:"模式",494:"指定第二点",495:"多个点",496:"平面中的倾角",497:"与",498:"平面的夹角",499:"打开页面失败",500:"关闭标签",501:"隐藏",502:"正在打开图纸,请耐心等待",503:"打开图纸成功",504:"上传中断:服务器程序异常",505:"上传中断,请稍后重试",506:"文件预处理中",507:"上传图纸",508:"图纸处理中",509:"选择复制对象",510:"无法清空剪贴板",511:"选择剪切对象",512:"指定插入点",513:"指定缩放比例",514:"指定旋转角度",515:"开",516:"关",517:"对象捕捉追踪",518:"指定文字起点",519:"指定文字高度",520:"选择要编辑的文字",521:"移动",522:"缩放",523:"取消选择",524:"选择陈列对象",525:"指定整列角度",526:"未选择需要阵列对象",527:"指定插入基点",528:"识别图框的范围",529:"没有历史记录",530:"已选择上次范围",531:"指定输出范围成功",532:"指定打印范围第一点",533:"指定打印范围第二点",534:"打印成功",535:"打印失败",536:"图框",537:"偏移距离和方向",538:"方法和值",539:"附着图片",540:"预览",541:"插入点",542:"图像高度",543:"宽度",544:"高度",545:"旋转角度",546:"输入文件",547:"转换当前打开的图纸",548:"输出文件",549:"图纸标题",550:"图纸宽度",551:"图纸高度",552:"图纸高度自适应",553:"是否导出布局",554:"使用黑白色导出",555:"导出区域",556:"图纸界限",557:"显示区域",558:"选择区域",559:"区域坐标",560:"批量把一个目录下所有DWG文件转换成PDF",561:"选择DWG所在目录,开始批量转换PD",562:"选择颜色",563:"颜色索引",564:"色调",565:"饱和度",566:"亮度",567:"红",568:"绿",569:"蓝",570:"的",571:"标注样式管理器",572:"当前标注样式",573:"列出",574:"置为当前",575:"创建新标注样式",576:"新样式名",577:"基础样式",578:"继续",579:"取消",580:"启动栅格捕捉",581:"极轴角设置",582:"增量角",583:"捕捉X轴间距",584:"捕捉Y轴间距",585:"草图设置",586:"启动对象捕捉",587:"对象捕捉模式",588:"全部取消",589:"启动极轴追踪",590:"DWG剪切",591:"存储路径",592:"选取路径",593:"插入块",594:"路径",595:"统一比例",596:"分解",597:"自动计算原点",598:"图层特性管理器",599:"线宽设置",600:"列出单位",601:"显示线宽",602:"调整显示比例",603:"最小",604:"最大",605:"当前线宽",606:"线型加载或重载",607:"可用线型",608:"调整选项",609:"如果尺寸线之间没有足够的空间来放置文字和箭头,那么首先从尺寸界限中移出",610:"文字或箭头",611:"最佳效果",612:"箭头",613:"文字和箭头",614:"文字你始终保持在尺寸界限之间",615:"若箭头不能放置在尺寸界限内,则将其消除",616:"文字位置",617:"文字不在默认位置上时,将其放置在",618:"标注特征比例",619:"将标注缩放到布局",620:"使用全局比例",621:"优化",622:"手动放置文字",623:"在尺寸界限之间绘制尺寸线",624:"修改标注样式",625:"尺寸线",626:"基线间距",627:"尺寸界限",628:"超出尺寸线",629:"起点偏移量",630:"固定长度的尺寸界限",631:"单位格式",632:"精度",633:"小数分割符",634:"舍入",635:"前缀",636:"后缀",637:"测量单位比例",638:"比例因子",639:"仅应用到布局标注",640:"消零",641:"前导",642:"后续",643:"第一个",644:"第二个",645:"引线",646:"箭头大小",647:"圆心标记",648:"无",649:"标记",650:"弧长符号",651:"标注文字的前缀",652:"标注文字的上方",653:"文字外观",654:"文字颜色",655:"文字高度",656:"绘制文字边框",657:"从尺寸线偏移",658:"文字对齐",659:"与尺寸线对齐",660:"标准",661:"多行文字",662:"字体",663:"文字内容",664:"填充图案选择",665:"其他预定义",666:"图案填充",667:"型和图案",668:"样例",669:"角度和比例",670:"边界",671:"添加",672:"点大小",673:"相对于屏幕设置大小",674:"按绝对单位设置大小",675:"图框识别批量打印",676:"操作",677:"定位",678:"打印区域",679:"图框识别",680:"批量打印",681:"应用到",682:"整个图形",683:"对象类型",684:"特性",685:"运算符",686:"值",687:"包括在新选择集中",688:"排除在新选择集之外",689:"附加到当前选择集",690:"目标图层",691:"光标位置",692:"图纸坐标",693:"左下角",694:"十字光标大小",695:"靶框大小",696:"背景颜色",697:"视图背景色",698:"布局背景色",699:"标注小数位",700:"标注文字大小",701:"像素",702:"日志保存路径",703:"启动时默认打开上次打开的文件",704:"清除缓存",705:"控制台",706:"选择上传外部参照文件",707:"状态",708:"文件名",709:"单行文字",710:"文字参数",711:"导入表格",712:"行",713:"列",714:"新建表格",715:"预览编辑",716:"文字查找",717:"查找内容",718:"替换内容",719:"查找方式",720:"全局查找",721:"矩形区域查找",722:"异性区域查找",723:"全字匹配",724:"区域选择",725:"单击列表文字图上定位",726:"标记所有结果",727:"当前文字样式",728:"SHX字体",729:"字体名",730:"大字体",731:"字体样式",732:"使用大字体",733:"效果",734:"宽度因子",735:"倾斜角度",736:"删除文字样式",737:"新建文字样式",738:"样式名",739:"过滤器",740:"退出时恢复",741:"清除",742:"线型管理器",743:"取消收藏",744:"收藏",745:"前往",746:"页",747:"属性",748:"无属性",749:"选择比较文件",750:"开始比较",751:"比较结果",752:"修改说明",753:"被比较图纸预览",754:"获取扩展数据",755:"对象无扩展数据",756:"对象扩展数据如下",757:"获取扩展字典数据",758:"对象无扩展字典数据",759:"对象扩展字典数据如下",760:"*多种*",761:"缺省",762:"在图形中拾取点",763:"未知",764:"已加载",765:"是否重载",766:"加载失败",767:"{}",768:"图纸比较",769:"云图库",770:"文字搜索",771:"符号标注",772:"箭头引注",773:"引出标注"},storage={get(t){if(globalThis.localStorage)return globalThis.localStorage.getItem(t)},set(t,e){globalThis.localStorage&&globalThis.localStorage.setItem(t,e)},remove(t){globalThis.localStorage&&globalThis.localStorage.removeItem(t)}},messages={zh:defaultMessages,cht:()=>__vitePreload(()=>import("./cht-DDQ07g_r.js"),[],import.meta.url),en:()=>__vitePreload(()=>import("./en-CaoSBUa0.js"),[],import.meta.url)},formatters={zh:defaultFormatters,cht:()=>__vitePreload(()=>import("./cht-FmFgRqLi.js"),[],import.meta.url),en:()=>__vitePreload(()=>import("./en-BIHI7g3E.js"),[],import.meta.url)},scopeSettings={languages:[{name:"zh",title:"中文",default:!0,active:!0},{name:"cht",title:"繁体中文"},{name:"en",title:"英语"}],namespaces:{}},scope=new ze({id:"mx-cad-app-vuetify3",debug:!1,idMap,library:!1,messages,formatters,storage,...scopeSettings}),scopedTtranslate=kr.bind(scope),createEl=()=>{const t=document.createElement("div");return t.id="picker",document.body.appendChild(t),t},el=createEl();let upload;const tipsShow=ref(!1),fileTips=ref(""),progress=ref(0);let sCmd="OpenDwgImp",uploadFile_call;function do_uploadFile_call(t,e){if(!t)return;if(!e){t(e);return}const l=e.type,n=e.hash,u=e.file;let c="";if(n){let{mxfilepath:y=""}=getUploadFileConfig()||{};c=getBaseUrl()+y+n+"."+l+".mxweb"}else l==="mxweb"&&(c=URL.createObjectURL(u.source.source),setTimeout(()=>{URL.revokeObjectURL(c)},5e3));e.file_path=c,t(e)}const uploadFile=async(t,e,l=void 0)=>new Promise(n=>{setReloadFile(t),e&&e.length>0?(sCmd=e,uploadFile_call=void 0):l?(sCmd="",uploadFile_call=l):n(),el.getElementsByTagName("label")[0].click(),el.click(),window.addEventListener("focus",()=>{setTimeout(()=>{n()},50)},{once:!0})}),timeoutHideTip=()=>{setTimeout(()=>{tipsShow.value=!1},100)},setFileTips=t=>{fileTips.value=t},setTipsShow=t=>{tipsShow.value=t},useDwgUpload=()=>(onMounted(()=>{const t=useMessage();upload||(upload=createDwgFileUploader({pick:el,onError:()=>{tipsShow.value=!0,setFileTips(scopedTtranslate("504")+"!"),t.error(scopedTtranslate("505")+"!"),timeoutHideTip(),do_uploadFile_call(uploadFile_call,null),sCmd="OpenDwgImp",uploadFile_call=void 0},onFileQueued:e=>{if(e.ext==="mxweb"||isElectron()){upload.stop(),upload.reset(),setTipsShow(!1),timeoutHideTip();const l={type:e.ext,file:e,isUseServerExistingFile:!1};return sCmd&&sCmd.length>0?MxFun.sendStringToExecute(sCmd,l):uploadFile_call!=null&&do_uploadFile_call(uploadFile_call,l),sCmd="OpenDwgImp",uploadFile_call=void 0,!1}setFileTips(scopedTtranslate("506")+"..."),setTipsShow(!0)},onBeginUpload:()=>{setFileTips(scopedTtranslate("507")+"...")},onProgress:e=>{e<100?setFileTips(scopedTtranslate("507")+e+"%.."):setFileTips(scopedTtranslate("508")+"..."),setTipsShow(!0),progress.value=e},onUploadSuccess:(e,l,n)=>{setTipsShow(!1),timeoutHideTip();const u={hash:l,type:e.ext,file:e,isUseServerExistingFile:n};sCmd&&sCmd.length>0?MxFun.sendStringToExecute(sCmd,u):uploadFile_call!=null&&do_uploadFile_call(uploadFile_call,u),sCmd="OpenDwgImp",uploadFile_call=void 0}}))}),{uploadFile,upload,tipsShow,fileTips,progress}),useRightClickMenuOptions=(t={})=>{const{menuItemCss:e={},params:l={},menuWrapperCss:n={},...u}=t;return{params:{...l},customClass:"mx_right_menu",menuWidth:120,menuWrapperCss:{background:"rgb(var(--v-theme-surface))",boxShadow:"0px 5px 5px -3px var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, 0.2)), 0px 8px 10px 1px var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, 0.14)), 0px 3px 14px 2px var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, 0.12))",borderRadius:"4px",color:"rgba(var(--v-theme-on-surface), var(--v-high-emphasis-opacity))",...n},menuItemCss:{height:"30px",hoverBackground:"rgb(var(--v-theme-btn-hover))",background:"currentColor",borderRadius:"inherit",transition:"opacity 0.2s ease-in-out",labelColor:"rgba(var(--v-theme-on-surface), var(--v-high-emphasis-opacity))",labelFontSize:"12px",...e},menuList:[],...u}},isFullscreen=()=>!!(document.fullScreen||document.mozFullScreen||document.webkitIsFullScreen||document.fullscreenElement),tabs=ref([{title:"Drawing1",url:"",active:!1,isDatabaseModify:!1},{title:"Drawing2",url:"",active:!1,isDatabaseModify:!1}]),close=async t=>{await MxElectronAPI.viewTab.close(t)},isNeedToSava=t=>!tabs.value[t]?.isDatabaseModify,useTabs=()=>({tabs,add(){},close(){},active(){}}),getDataIndex=t=>Number(t?.getAttribute("data-index")),useTabRightClickMenu=()=>({rightMenuOptions:useRightClickMenuOptions({menuList:[{label:"关闭当前文件",fn:(e,l)=>{close(getDataIndex(l))}},{label:"关闭非当前文件",fn:(e,l)=>MxElectronAPI.viewTab.closeNonCurrentTab(getDataIndex(l))},{label:"关闭所有",fn:()=>MxElectronAPI.viewTab.closeAll()},{label:"关闭右边所有",fn:(e,l)=>MxElectronAPI.viewTab.closeRightAll(getDataIndex(l))},{label:"关闭左边所有",fn:(e,l)=>MxElectronAPI.viewTab.closeLeftAll(getDataIndex(l))},{label:"关闭所有未修改",fn:()=>MxElectronAPI.viewTab.closeNoModifyAll()},{label:"保存",fn:(e,l)=>MxElectronAPI.viewTab.saveFile(getDataIndex(l)),disabled:(e,l)=>isNeedToSava(getDataIndex(l))},{label:"另存为",fn:(e,l)=>MxElectronAPI.viewTab.saveAsFile(getDataIndex(l))},{label:"打开所在文件夹",fn:(e,l)=>MxElectronAPI.viewTab.openCurrentFolder(getDataIndex(l))},{label:"重新载入",fn:(e,l)=>MxElectronAPI.viewTab.reload(getDataIndex(l))}]})}),{showLoading,hideLoading}=useLoading();async function getMxreleaseidId(){return(await(await load()).get()).visitorId}class MxCADUIImplement{constructor(e){Pm(this,"plugin",new MxCADPluginBase);Pm(this,"mxcad");Pm(this,"mxmap");this.mxcad=e}getUploadFileConfig(){return getUrlConfig()}getServerConfig(){return serverConfig||{}}init(e){this.plugin=e,this.plugin.mxcadui=this}async uploadFile(e,l=!1){await uploadFile(l,"",e)}}let mxcadObj;const getMxCadObj=()=>mxcadObj;let mxcadCallInit=!0;const createMxCAD=(t,e)=>{createMxCAD_New(t,e)},doOpenFile=t=>{const{file:e,viewRange:l}=getParamsFromUrl()||{};let n="test3.mxweb";t!==void 0&&(n=t,n.length==0&&(n="empty_template.mxweb"));let u=e||n;u=u.replace(/#/g,"%23");const c=mxcadObj.openWebFile(u,b=>{if(hideLoading(),b!==0){console.log("openWebFile error",b),useMessage().error(scopedTtranslate("499")+"!");return}},!0,l?JSON.parse(l):void 0,0);setFileName(u);const y={};getFileSize(u).then(b=>{b/(1024*1024)>1&&c&&showLoading(y)})},databaseInitializationEvent=[],onDatabaseInitialization=t=>{databaseInitializationEvent.push(t)};let mxCADUIImplement;const getMxCADUIImplement=()=>mxCADUIImplement,createMxCAD_New=async(t,e)=>{let l=new McObject;if(l.on("databaseInitialization",()=>{databaseInitializationEvent.forEach(u=>[u()])}),l.on("layerChanged",()=>{const{initLayerList:u}=useLayer();u()}),l.on("lineTypeChanged",()=>{const{initLineTypeList:u}=useLineType();u()}),mxCADUIImplement=new MxCADUIImplement(l),mxcadCallInit){store.state.MxFun||await loadCoreCode(),mxcadCallInit=!1;let u=await fetchQuickCommand();MxFun.initQuickCommand(u),registerCommand(),await registerPlugins$1(),await MxFun.callSyncInitialization(),MxFun.callEvent("mxcadApplicationStart",mxCADUIImplement)}l.on("init",async()=>{{let{aiUrl:u}=getAiConfig()||{};u&&MxCpp.Ai.init(u)}}),l.on("init_before_mxdraw",u=>{MxFun.callEvent("mxcadApplicationStartCreatingMxCADObject",{mxdraw:u}),e(u,!0)}),l.on("init_mxdraw",u=>{}),l.on("init_mxcad",async u=>{let c=isSupportTruetypeFont();MxCpp.App.IniSet({SupportTruetypeFont:c}),mxcadObj=u;let y=MxCpp.App.getImp().getCodeVersion();if(y!=1&&y!=2)if(mxCADUIImplement.plugin.sRegistData.length>0)mxcadObj.initRegist(mxCADUIImplement.plugin.sRegistData);else{let m=await getJsonFromUrl("mxkey.json.frontpage.json");m&&m.registdata?mxcadObj.initRegist(m.registdata):console.log("MxTip:empty regist data")}if(y==3){let b=localStorage.getItem("_mx_tmp_id_");if(!b||b.length==0){let m=window;m.__fpjs_d_m=!0,b=(await(await load()).get()).visitorId,localStorage.setItem("_mx_tmp_id_",b)}MxCpp.App.getImp().addFontsLoadOnInitialization(b,-121)}MxFun.callEvent("mxcadApplicationCreatedMxCADObject",{mxcad:mxcadObj}),y==3&&getMxreleaseidId().then(b=>{mxcadObj.getImp().SetAppId(b)}),doOpenFile(mxCADUIImplement.plugin.openFile)}),l.create({canvas:"myCanvas",...t,locateFile:getFileWasm,multipleSelect:!0,enableUndo:!0,webgl1:isWebgl1()})},createMxCADMap=async t=>{const e=new MxMap;mxcadObj=e.mxcad;let l=new MxCADUIImplement(e.mxcad);if(l.mxmap=e,mxcadCallInit){store.state.MxFun||await loadCoreCode(),mxcadCallInit=!1;let L=await fetchQuickCommand();MxFun.initQuickCommand(L),registerCommand(),await registerPlugins$1(),await MxFun.callSyncInitialization(),MxFun.callEvent("mxcadApplicationStart",l)}MxFun.callEvent("mxcadApplicationStart",l);let n=new URL(""+new URL("../demo/road.dwg.mxweb",import.meta.url).href,import.meta.url).href;l.plugin.map_default_data&&l.plugin.map_default_data.openFile&&(n=l.plugin.map_default_data.openFile);let u=[114.06825863001939,22.54283198132819],c=[116275.977014,19273.279085],y=1;mapboxgl.accessToken="";let b;l.plugin.map_default_data&&(u=l.plugin.map_default_data.mapOrigin,c=l.plugin.map_default_data.cadOrigin,y=l.plugin.map_default_data.meterInCADUnits,mapboxgl.accessToken=l.plugin.map_default_data.mapbox_accessToken,b=l.plugin.map_default_data.viewColor);const m=getParamsFromUrl()||{};if(typeof m.mapOrigin=="string"&&(u=m.mapOrigin.split(",").map(L=>Number(L)),console.log(u)),typeof m.cadOrigin=="string"&&(c=m.cadOrigin.split(",").map(L=>Number(L)),console.log(c)),m.meterInCADUnits){const L=Number(m.meterInCADUnits);L&&(y=L)}const O={version:8,sources:{},glyphs:"mapbox://fonts/mapbox/{fontstack}/{range}.pbf",layers:[]},N=new Map$1({container:"mx_map",minZoom:0,maxZoom:24,center:u,zoom:16,style:O});addResizeListener(N.getContainer(),()=>N.resize()),e.setCoordinatePointAlignment(u,c,y),e.initMapbox(N),await(async()=>new Promise(L=>{N.on("remove",()=>{}),N.on("style.load",async function(){N.addGroupLayer(),l.plugin.map_default_data&&l.plugin.map_default_data.rasterTileLayerList.length>0&&N.addRasterTileLayer(l.plugin.map_default_data.rasterTileLayerList,l.plugin.map_default_data.rasterTileKey?l.plugin.map_default_data.rasterTileKey:void 0,l.plugin.map_default_data.providers),MxFun.callEvent("mxcadApplicationInitMap"),e.mxcad.on("init",async()=>{{let{aiUrl:G}=getAiConfig()||{};G&&MxCpp.Ai.init(G)}}),e.mxcad.on("init_before_mxdraw",G=>{MxFun.callEvent("mxcadApplicationStartCreatingMxCADObject",{mxdraw:G}),t(G,!0)}),e.mxcad.on("init_mxdraw",G=>{}),e.mxcad.on("init_mxcad",async G=>{mxcadObj=G;let q=mxcadObj.getImp().getCodeVersion();if(q==3&&getMxreleaseidId().then(J=>{mxcadObj.getImp().SetAppId(J)}),q!=1&&q!=2)if(l.plugin.sRegistData.length>0)mxcadObj.initRegist(l.plugin.sRegistData);else{let fe=await getJsonFromUrl("mxkey.json.frontpage.json");fe&&fe.registdata?mxcadObj.initRegist(fe.registdata):console.log("MxTip:empty regist data")}if(q==3){let J=localStorage.getItem("_mx_tmp_id_");if(!J||J.length==0){let fe=window;fe.__fpjs_d_m=!0,J=(await(await load()).get()).visitorId,localStorage.setItem("_mx_tmp_id_",J)}MxCpp.App.getImp().addFontsLoadOnInitialization(J,-121)}MxFun.callEvent("mxcadApplicationCreatedMxCADObject",{mxcad:mxcadObj})}),e.create(N,{locateFile:getFileWasm,middlePan:!0,multipleSelect:!0,viewBackgroundColor:b}),e.mxcad.on("init_mxcad",()=>{doOpenFile(n)}),L()})}))()};function getFileWasm(t){let{url:e,type:l}=getWasmConfig()||{},n=MxFun.getQueryString("wasmtype");if(n=="st"?l="2d-st":n||"SharedArrayBuffer"in window||(l="2d-st"),typeof e<"u"&&e!==""){if(/^(https?|http):\/\//.test(e))return e+(e[length-1]==="/"?"":"/")+t;console.warn(`mxServerConfig.json wasmConfig 配置项url:${e} 格式不匹配, 请输入包含mxcad相关wasm目录的网络路径地址例如: https://unpkg.com/mxcad/dist/wasm/2d-st/`)}const u=new URL(Object.assign({"/node_modules/mxcad/dist/wasm/2d/mxdrawassembly_min.js":__vite_glob_0_0,"/node_modules/mxcad/dist/wasm/2d/mxdrawassembly_min.wasm":__vite_glob_0_1,"/node_modules/mxcad/dist/wasm/2d/mxdrawassembly_min.worker.js":__vite_glob_0_2})[`/node_modules/mxcad/dist/wasm/2d/${t}`],import.meta.url).href;if(typeof l<"u"&&l!==""){if(l==="2d")return u;if(l==="2d-st")return new URL(Object.assign({"/node_modules/mxcad/dist/wasm/2d-st/mxdrawassembly_min.js":__vite_glob_1_0,"/node_modules/mxcad/dist/wasm/2d-st/mxdrawassembly_minst.wasm":__vite_glob_1_1})[`/node_modules/mxcad/dist/wasm/2d-st/${t}`],import.meta.url).href;console.warn(`mxServerConfig.json wasmConfig 配置项type:${l} 输入不正确, 目前支持的输入: 2d和2d-st`)}return u}const updateDisplay=()=>{MxFun.updateDisplay()},getBlockNames=()=>{const l=MxCpp.getCurrentMxCAD().getDatabase().getBlockTable().getAllRecordId().map(u=>u.getMcDbBlockTableRecord()),n=[];return l.forEach(u=>{u?.name&&!u.name.startsWith("*")&&n.push(u.name)}),n},setProp=(t,e,l)=>(t[e]=l,t[e]),defaultLineType={name:"ByLayer",explain:"",appearance:"",id:-1},useLineType=defineStore("lineType",()=>{const t=(y={})=>({...defaultLineType,...y}),e=ref([]),l=ref();watch(l,y=>{y&&getDatabase().setCurrentlyLineTypeName(y.name)});const n=y=>{const{name:b,comments:m,id:O}=y;return t({name:b,explain:m,appearance:m,id:O})};return{initLineTypeList:()=>{const b=getDatabase().getLinetypeTable().getJson(),m=JSON.parse(b),O=getDatabase().getCurrentlyLineTypeName(),N=["ByLayer","ByBlock","Continuous"];e.value=m.sort((L,G)=>{const q=N.indexOf(L.name),J=N.indexOf(G.name);return q!==-1&&J!==-1?q-J:q!==-1?-1:J!==-1?1:0}).map(L=>{const G=n(L);return O===L.name&&(l.value=G),G})},createLineType:t,parseJSONLineType:n,stringifyJSONLineType:y=>{},lineTypeList:e,currentLineType:l}}),useLayerInfo=(t,e,l=n=>{getDatabase().setCurrentlyLayerName(n)})=>{const{createColor:n,stringifyJSONColor:u,parseJSONColor:c}=useColor$1(),{createLineType:y}=useLineType(),b={id:0,name:"0",visible:!0,freeze:!1,lock:!1,print:!0,status:!1,isSelect:!1,color:n(),lineType:y()};let m=0;const O=Tt=>({...b,name:`${scopedTtranslate("443")}${m++}`,id:0,...Tt}),N=ref([]),L=ref(0),G=[],q=ref(),J=computed(()=>N.value[0].id),fe=Tt=>new Promise((kt,It)=>{const nn=getLayerJson();setLayerJson(Tt)?(G.push({layerJSONDataString:nn}),kt()):It()}),ve=(Tt,kt,It=L,nn)=>{const tn=unref(It||L),pn=unref(kt),Dn=(Array.isArray(tn)?tn.map(an=>N.value[unref(an)]):[N.value[unref(tn)]]).map((an,Rn)=>setProp(an,Tt,unref(Array.isArray(pn)?pn[Rn]||pn[0]:pn)));return nn&&fe(ue()),Dn},ne=(Tt=L)=>{const kt=unref(Tt),It=nn=>typeof nn=="object"?N.value.indexOf(nn):nn;return Array.isArray(kt)?kt.map(nn=>It(nn)):It(kt)},Ue=Tt=>{L.value=unref(Tt),ve("isSelect",!1,N.value.map((kt,It)=>It)),ve("isSelect",!0)},De=Tt=>{if(!(Tt<0)){if(N.value[Tt])return Ue(Tt);De(Tt-1)}},Ve=Tt=>{const kt=Tt||O();return N.value.push(kt),Ue(N.value.length-1),kt},rt=(Tt=L,kt="index")=>{const It=[],nn=unref(Tt),tn=_n=>{N.value=N.value.filter((an,Rn)=>{if(an.id===J.value||an.status||an.lock)return!0;const Lt=kt==="this"?an:kt==="id"?an.id:Rn;return!_n.includes(Lt)||It.push(an),!_n.includes(Lt)});const Dn=ne(_n[_n.length-1]);typeof Dn=="number"&&De(Dn)},pn=_n=>{if(kt==="id")tn([_n]);else{let Dn=ne(_n);if(typeof Dn!="number"||Dn<0)return;const an=N.value[Dn];if(an.id===J.value||an.status||an.lock)return;const Rn=N.value.splice(Dn,1);It.push(...Rn)}};if(nn)if(Array.isArray(nn))tn(nn);else{pn(nn);const _n=ne(nn);if(typeof _n!="number")return;De(_n)}return It},Ae=(Tt,kt=L)=>{let It=unref(kt);const nn=tn=>{let pn=unref(tn);if(!(Tt==="freeze"&&N.value[pn].id===J.value))return N.value[pn][Tt]=!N.value[pn][Tt],N.value[pn][Tt]};return Array.isArray(It)?It.map(tn=>nn(tn)):nn(It)},Te=(Tt,kt=!1)=>{const It=Tt?ne(Tt):L.value;Array.isArray(It)&&(It.length>1||It.length===0)||(q.value&&G.push({layerCurrentName:q.value.name}),ve("status",!1,N.value.map((nn,tn)=>tn)),q.value=unref(N.value[Array.isArray(It)?It[0]:It]),q.value.status=!0,kt&&fe(ue()),l(q.value.name))},Xe=(Tt=getDatabase().getCurrentlyLayerName())=>{Te(N.value.find(({name:kt})=>Tt===kt))},ie=(Tt=getLayerJson())=>{try{const kt=JSON.parse(Tt);if(!Array.isArray(kt))return;N.value=kt.map(({name:It,color:nn,off:tn,linetypename:pn,locked:_n,plottable:Dn,id:an})=>O({name:It,id:an,color:c(nn),lock:_n===Status.On,lineType:y({name:pn}),print:Dn===Status.On,visible:tn===Status.Off}))}catch(kt){console.error(kt)}},ue=()=>JSON.stringify(N.value.map(Tt=>{const{name:kt,color:It,visible:nn,id:tn,lineType:pn,print:_n,lock:Dn}=Tt;return{name:kt,id:tn,off:nn?Status.Off:Status.On,color:u(It),linetypename:pn.name,plottable:_n?Status.On:Status.Off,locked:Dn?Status.On:Status.Off}}));return{list:N,index:L,currentLayer:q,rootId:J,setIndex:Ue,getIndex:ne,add:Ve,create:O,remove:rt,toggle:Ae,setValue:ve,putCurrent:Te,parseJSON:ie,stringifyJSON:ue,initLayerList:()=>{ie(t),Xe(e)},initCurrentLayer:Xe,setLayerList:fe,recoveryLayerStateHistory:()=>{const Tt=G.pop();Tt?.layerCurrentName&&Xe(Tt.layerCurrentName),Tt?.layerJSONDataString&&(ie(Tt.layerJSONDataString),setLayerJson(Tt.layerJSONDataString))}}},useLayer=defineStore("layer",useLayerInfo),regex=/\(([a-zA-Z])\)/g;function extractLetter(t){const e=t.match(regex);if(e)return e[e.length-1].match(/[a-zA-Z]/)[0]}function replaceI18n(t,e){const l=/^(.*?)(\([^\(\)]*\))?$/,n=t.match(l);if(n){const[u,c,y]=n;return e==="start"?scopedTtranslate(c):e==="end"?y||"":scopedTtranslate(c)+(y||"")}return scopedTtranslate(t)}function translateOnlyChinese(t,e=scopedTtranslate){const l=/[\u4e00-\u9fa5]+/g,n=t.match(l);if(!n)return t;const u=n.map(b=>e(b));let c=t,y=0;return n.forEach((b,m)=>{const O=c.indexOf(b,y);O!==-1&&(c=c.slice(0,O)+u[m]+c.slice(O+b.length),y=O+u[m].length)}),c}function useColor(t){return destructComputed(()=>{const e=[],l={};if(t.value.background)if(isCssColor(t.value.background)){if(l.backgroundColor=t.value.background,!t.value.text&&isParsableColor(t.value.background)){const n=parseColor(t.value.background);if(n.a==null||n.a===1){const u=getForeground(n);l.color=u,l.caretColor=u}}}else e.push(`bg-${t.value.background}`);return t.value.text&&(isCssColor(t.value.text)?(l.color=t.value.text,l.caretColor=t.value.text):e.push(`text-${t.value.text}`)),{colorClasses:e,colorStyles:l}})}function useTextColor(t,e){const l=computed(()=>({text:isRef(t)?t.value:e?t[e]:null})),{colorClasses:n,colorStyles:u}=useColor(l);return{textColorClasses:n,textColorStyles:u}}function useBackgroundColor(t,e){const l=computed(()=>({background:isRef(t)?t.value:e?t[e]:null})),{colorClasses:n,colorStyles:u}=useColor(l);return{backgroundColorClasses:n,backgroundColorStyles:u}}const predefinedSizes=["x-small","small","default","large","x-large"],makeSizeProps=propsFactory$1({size:{type:[String,Number],default:"default"}},"size");function useSize(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:getCurrentInstanceName();return destructComputed(()=>{let l,n;return includes(predefinedSizes,t.size)?l=`${e}--size-${t.size}`:t.size&&(n={width:convertToUnit(t.size),height:convertToUnit(t.size)}),{sizeClasses:l,sizeStyles:n}})}const makeTagProps=propsFactory$1({tag:{type:String,default:"div"}},"tag"),makeVIconProps=propsFactory$1({color:String,disabled:Boolean,start:Boolean,end:Boolean,icon:IconValue$1,...makeComponentProps(),...makeSizeProps(),...makeTagProps({tag:"i"}),...makeThemeProps()},"VIcon"),VIcon=genericComponent()({name:"VIcon",props:makeVIconProps(),setup(t,e){let{attrs:l,slots:n}=e;const u=ref(),{themeClasses:c}=provideTheme(t),{iconData:y}=useIcon(computed(()=>u.value||t.icon)),{sizeClasses:b}=useSize(t),{textColorClasses:m,textColorStyles:O}=useTextColor(toRef(t,"color"));return useRender(()=>{const N=n.default?.();N&&(u.value=flattenFragments(N).filter(G=>G.type===Text&&G.children&&typeof G.children=="string")[0]?.children);const L=!!(l.onClick||l.onClickOnce);return createVNode(y.value.component,{tag:t.tag,icon:y.value.icon,class:["v-icon","notranslate",c.value,b.value,m.value,{"v-icon--clickable":L,"v-icon--disabled":t.disabled,"v-icon--start":t.start,"v-icon--end":t.end},t.class],style:[b.value?void 0:{fontSize:convertToUnit(t.size),height:convertToUnit(t.size),width:convertToUnit(t.size)},O.value,t.style],role:L?"button":void 0,"aria-hidden":!L,tabindex:L?t.disabled?-1:0:void 0},{default:()=>[N]})}),{}}}),makeTransitionProps$1=propsFactory$1({disabled:Boolean,group:Boolean,hideOnLeave:Boolean,leaveAbsolute:Boolean,mode:String,origin:String},"transition");function createCssTransition(t,e,l){return genericComponent()({name:t,props:makeTransitionProps$1({mode:l,origin:e}),setup(n,u){let{slots:c}=u;const y={onBeforeEnter(b){n.origin&&(b.style.transformOrigin=n.origin)},onLeave(b){if(n.leaveAbsolute){const{offsetTop:m,offsetLeft:O,offsetWidth:N,offsetHeight:L}=b;b._transitionInitialStyles={position:b.style.position,top:b.style.top,left:b.style.left,width:b.style.width,height:b.style.height},b.style.position="absolute",b.style.top=`${m}px`,b.style.left=`${O}px`,b.style.width=`${N}px`,b.style.height=`${L}px`}n.hideOnLeave&&b.style.setProperty("display","none","important")},onAfterLeave(b){if(n.leaveAbsolute&&b?._transitionInitialStyles){const{position:m,top:O,left:N,width:L,height:G}=b._transitionInitialStyles;delete b._transitionInitialStyles,b.style.position=m||"",b.style.top=O||"",b.style.left=N||"",b.style.width=L||"",b.style.height=G||""}}};return()=>{const b=n.group?TransitionGroup:Transition;return h(b,{name:n.disabled?"":t,css:!n.disabled,...n.group?void 0:{mode:n.mode},...n.disabled?{}:y},c.default)}}})}function createJavascriptTransition(t,e){let l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"in-out";return genericComponent()({name:t,props:{mode:{type:String,default:l},disabled:Boolean,group:Boolean},setup(n,u){let{slots:c}=u;const y=n.group?TransitionGroup:Transition;return()=>h(y,{name:n.disabled?"":t,css:!n.disabled,...n.disabled?{}:e},c.default)}})}function ExpandTransitionGenerator(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";const l=(arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1)?"width":"height",n=camelize(`offset-${l}`);return{onBeforeEnter(y){y._parent=y.parentNode,y._initialStyle={transition:y.style.transition,overflow:y.style.overflow,[l]:y.style[l]}},onEnter(y){const b=y._initialStyle;y.style.setProperty("transition","none","important"),y.style.overflow="hidden";const m=`${y[n]}px`;y.style[l]="0",y.offsetHeight,y.style.transition=b.transition,t&&y._parent&&y._parent.classList.add(t),requestAnimationFrame(()=>{y.style[l]=m})},onAfterEnter:c,onEnterCancelled:c,onLeave(y){y._initialStyle={transition:"",overflow:y.style.overflow,[l]:y.style[l]},y.style.overflow="hidden",y.style[l]=`${y[n]}px`,y.offsetHeight,requestAnimationFrame(()=>y.style[l]="0")},onAfterLeave:u,onLeaveCancelled:u};function u(y){t&&y._parent&&y._parent.classList.remove(t),c(y)}function c(y){const b=y._initialStyle[l];y.style.overflow=y._initialStyle.overflow,b!=null&&(y.style[l]=b),delete y._initialStyle}}const makeVDialogTransitionProps=propsFactory$1({target:[Object,Array]},"v-dialog-transition"),VDialogTransition=genericComponent()({name:"VDialogTransition",props:makeVDialogTransitionProps(),setup(t,e){let{slots:l}=e;const n={onBeforeEnter(u){u.style.pointerEvents="none",u.style.visibility="hidden"},async onEnter(u,c){await new Promise(G=>requestAnimationFrame(G)),await new Promise(G=>requestAnimationFrame(G)),u.style.visibility="";const{x:y,y:b,sx:m,sy:O,speed:N}=getDimensions(t.target,u),L=animate(u,[{transform:`translate(${y}px, ${b}px) scale(${m}, ${O})`,opacity:0},{}],{duration:225*N,easing:deceleratedEasing});getChildren(u)?.forEach(G=>{animate(G,[{opacity:0},{opacity:0,offset:.33},{}],{duration:225*2*N,easing:standardEasing})}),L.finished.then(()=>c())},onAfterEnter(u){u.style.removeProperty("pointer-events")},onBeforeLeave(u){u.style.pointerEvents="none"},async onLeave(u,c){await new Promise(G=>requestAnimationFrame(G));const{x:y,y:b,sx:m,sy:O,speed:N}=getDimensions(t.target,u);animate(u,[{},{transform:`translate(${y}px, ${b}px) scale(${m}, ${O})`,opacity:0}],{duration:125*N,easing:acceleratedEasing}).finished.then(()=>c()),getChildren(u)?.forEach(G=>{animate(G,[{},{opacity:0,offset:.2},{opacity:0}],{duration:125*2*N,easing:standardEasing})})},onAfterLeave(u){u.style.removeProperty("pointer-events")}};return()=>t.target?createVNode(Transition,mergeProps({name:"dialog-transition"},n,{css:!1}),l):createVNode(Transition,{name:"dialog-transition"},l)}});function getChildren(t){const e=t.querySelector(":scope > .v-card, :scope > .v-sheet, :scope > .v-list")?.children;return e&&[...e]}function getDimensions(t,e){const l=getTargetBox(t),n=nullifyTransforms(e),[u,c]=getComputedStyle(e).transformOrigin.split(" ").map(ne=>parseFloat(ne)),[y,b]=getComputedStyle(e).getPropertyValue("--v-overlay-anchor-origin").split(" ");let m=l.left+l.width/2;y==="left"||b==="left"?m-=l.width/2:(y==="right"||b==="right")&&(m+=l.width/2);let O=l.top+l.height/2;y==="top"||b==="top"?O-=l.height/2:(y==="bottom"||b==="bottom")&&(O+=l.height/2);const N=l.width/n.width,L=l.height/n.height,G=Math.max(1,N,L),q=N/G||0,J=L/G||0,fe=n.width*n.height/(window.innerWidth*window.innerHeight),ve=fe>.12?Math.min(1.5,(fe-.12)*10+1):1;return{x:m-(u+n.left),y:O-(c+n.top),sx:q,sy:J,speed:ve}}const VFabTransition=createCssTransition("fab-transition","center center","out-in"),VDialogBottomTransition=createCssTransition("dialog-bottom-transition"),VDialogTopTransition=createCssTransition("dialog-top-transition"),VFadeTransition=createCssTransition("fade-transition"),VScaleTransition=createCssTransition("scale-transition"),VScrollXTransition=createCssTransition("scroll-x-transition"),VScrollXReverseTransition=createCssTransition("scroll-x-reverse-transition"),VScrollYTransition=createCssTransition("scroll-y-transition"),VScrollYReverseTransition=createCssTransition("scroll-y-reverse-transition"),VSlideXTransition=createCssTransition("slide-x-transition"),VSlideXReverseTransition=createCssTransition("slide-x-reverse-transition"),VSlideYTransition=createCssTransition("slide-y-transition"),VSlideYReverseTransition=createCssTransition("slide-y-reverse-transition"),VExpandTransition=createJavascriptTransition("expand-transition",ExpandTransitionGenerator()),VExpandXTransition=createJavascriptTransition("expand-x-transition",ExpandTransitionGenerator("",!0)),makeVDefaultsProviderProps=propsFactory$1({defaults:Object,disabled:Boolean,reset:[Number,String],root:[Boolean,String],scoped:Boolean},"VDefaultsProvider"),VDefaultsProvider=genericComponent(!1)({name:"VDefaultsProvider",props:makeVDefaultsProviderProps(),setup(t,e){let{slots:l}=e;const{defaults:n,disabled:u,reset:c,root:y,scoped:b}=toRefs(t);return provideDefaults(n,{reset:c,root:y,scoped:b,disabled:u}),()=>l.default?.()}}),ListKey=Symbol.for("vuetify:list");function createList(){const t=inject$1(ListKey,{hasPrepend:shallowRef(!1),updateHasPrepend:()=>null}),e={hasPrepend:shallowRef(!1),updateHasPrepend:l=>{l&&(e.hasPrepend.value=l)}};return provide(ListKey,e),t}function useList(){return inject$1(ListKey,null)}const independentActiveStrategy=t=>{const e={activate:l=>{let{id:n,value:u,activated:c}=l;return n=toRaw(n),t&&!u&&c.size===1&&c.has(n)||(u?c.add(n):c.delete(n)),c},in:(l,n,u)=>{let c=new Set;if(l!=null)for(const y of wrapInArray(l))c=e.activate({id:y,value:!0,activated:new Set(c),children:n,parents:u});return c},out:l=>Array.from(l)};return e},independentSingleActiveStrategy=t=>{const e=independentActiveStrategy(t);return{activate:n=>{let{activated:u,id:c,...y}=n;c=toRaw(c);const b=u.has(c)?new Set([c]):new Set;return e.activate({...y,id:c,activated:b})},in:(n,u,c)=>{let y=new Set;if(n!=null){const b=wrapInArray(n);b.length&&(y=e.in(b.slice(0,1),u,c))}return y},out:(n,u,c)=>e.out(n,u,c)}},leafActiveStrategy=t=>{const e=independentActiveStrategy(t);return{activate:n=>{let{id:u,activated:c,children:y,...b}=n;return u=toRaw(u),y.has(u)?c:e.activate({id:u,activated:c,children:y,...b})},in:e.in,out:e.out}},leafSingleActiveStrategy=t=>{const e=independentSingleActiveStrategy(t);return{activate:n=>{let{id:u,activated:c,children:y,...b}=n;return u=toRaw(u),y.has(u)?c:e.activate({id:u,activated:c,children:y,...b})},in:e.in,out:e.out}},singleOpenStrategy={open:t=>{let{id:e,value:l,opened:n,parents:u}=t;if(l){const c=new Set;c.add(e);let y=u.get(e);for(;y!=null;)c.add(y),y=u.get(y);return c}else return n.delete(e),n},select:()=>null},multipleOpenStrategy={open:t=>{let{id:e,value:l,opened:n,parents:u}=t;if(l){let c=u.get(e);for(n.add(e);c!=null&&c!==e;)n.add(c),c=u.get(c);return n}else n.delete(e);return n},select:()=>null},listOpenStrategy={open:multipleOpenStrategy.open,select:t=>{let{id:e,value:l,opened:n,parents:u}=t;if(!l)return n;const c=[];let y=u.get(e);for(;y!=null;)c.push(y),y=u.get(y);return new Set(c)}},independentSelectStrategy=t=>{const e={select:l=>{let{id:n,value:u,selected:c}=l;if(n=toRaw(n),t&&!u){const y=Array.from(c.entries()).reduce((b,m)=>{let[O,N]=m;return N==="on"&&b.push(O),b},[]);if(y.length===1&&y[0]===n)return c}return c.set(n,u?"on":"off"),c},in:(l,n,u)=>{let c=new Map;for(const y of l||[])c=e.select({id:y,value:!0,selected:new Map(c),children:n,parents:u});return c},out:l=>{const n=[];for(const[u,c]of l.entries())c==="on"&&n.push(u);return n}};return e},independentSingleSelectStrategy=t=>{const e=independentSelectStrategy(t);return{select:n=>{let{selected:u,id:c,...y}=n;c=toRaw(c);const b=u.has(c)?new Map([[c,u.get(c)]]):new Map;return e.select({...y,id:c,selected:b})},in:(n,u,c)=>{let y=new Map;return n?.length&&(y=e.in(n.slice(0,1),u,c)),y},out:(n,u,c)=>e.out(n,u,c)}},leafSelectStrategy=t=>{const e=independentSelectStrategy(t);return{select:n=>{let{id:u,selected:c,children:y,...b}=n;return u=toRaw(u),y.has(u)?c:e.select({id:u,selected:c,children:y,...b})},in:e.in,out:e.out}},leafSingleSelectStrategy=t=>{const e=independentSingleSelectStrategy(t);return{select:n=>{let{id:u,selected:c,children:y,...b}=n;return u=toRaw(u),y.has(u)?c:e.select({id:u,selected:c,children:y,...b})},in:e.in,out:e.out}},classicSelectStrategy=t=>{const e={select:l=>{let{id:n,value:u,selected:c,children:y,parents:b}=l;n=toRaw(n);const m=new Map(c),O=[n];for(;O.length;){const L=O.shift();c.set(toRaw(L),u?"on":"off"),y.has(L)&&O.push(...y.get(L))}let N=toRaw(b.get(n));for(;N;){const L=y.get(N),G=L.every(J=>c.get(toRaw(J))==="on"),q=L.every(J=>!c.has(toRaw(J))||c.get(toRaw(J))==="off");c.set(N,G?"on":q?"off":"indeterminate"),N=toRaw(b.get(N))}return t&&!u&&Array.from(c.entries()).reduce((G,q)=>{let[J,fe]=q;return fe==="on"&&G.push(J),G},[]).length===0?m:c},in:(l,n,u)=>{let c=new Map;for(const y of l||[])c=e.select({id:y,value:!0,selected:new Map(c),children:n,parents:u});return c},out:(l,n)=>{const u=[];for(const[c,y]of l.entries())y==="on"&&!n.has(c)&&u.push(c);return u}};return e},VNestedSymbol=Symbol.for("vuetify:nested"),emptyNested={id:shallowRef(),root:{register:()=>null,unregister:()=>null,parents:ref(new Map),children:ref(new Map),open:()=>null,openOnSelect:()=>null,activate:()=>null,select:()=>null,activatable:ref(!1),selectable:ref(!1),opened:ref(new Set),activated:ref(new Set),selected:ref(new Map),selectedValues:ref([]),getPath:()=>[]}},makeNestedProps=propsFactory$1({activatable:Boolean,selectable:Boolean,activeStrategy:[String,Function,Object],selectStrategy:[String,Function,Object],openStrategy:[String,Object],opened:null,activated:null,selected:null,mandatory:Boolean},"nested"),useNested=t=>{let e=!1;const l=ref(new Map),n=ref(new Map),u=useProxiedModel(t,"opened",t.opened,J=>new Set(J),J=>[...J.values()]),c=computed(()=>{if(typeof t.activeStrategy=="object")return t.activeStrategy;if(typeof t.activeStrategy=="function")return t.activeStrategy(t.mandatory);switch(t.activeStrategy){case"leaf":return leafActiveStrategy(t.mandatory);case"single-leaf":return leafSingleActiveStrategy(t.mandatory);case"independent":return independentActiveStrategy(t.mandatory);case"single-independent":default:return independentSingleActiveStrategy(t.mandatory)}}),y=computed(()=>{if(typeof t.selectStrategy=="object")return t.selectStrategy;if(typeof t.selectStrategy=="function")return t.selectStrategy(t.mandatory);switch(t.selectStrategy){case"single-leaf":return leafSingleSelectStrategy(t.mandatory);case"leaf":return leafSelectStrategy(t.mandatory);case"independent":return independentSelectStrategy(t.mandatory);case"single-independent":return independentSingleSelectStrategy(t.mandatory);case"classic":default:return classicSelectStrategy(t.mandatory)}}),b=computed(()=>{if(typeof t.openStrategy=="object")return t.openStrategy;switch(t.openStrategy){case"list":return listOpenStrategy;case"single":return singleOpenStrategy;case"multiple":default:return multipleOpenStrategy}}),m=useProxiedModel(t,"activated",t.activated,J=>c.value.in(J,l.value,n.value),J=>c.value.out(J,l.value,n.value)),O=useProxiedModel(t,"selected",t.selected,J=>y.value.in(J,l.value,n.value),J=>y.value.out(J,l.value,n.value));onBeforeUnmount(()=>{e=!0});function N(J){const fe=[];let ve=J;for(;ve!=null;)fe.unshift(ve),ve=n.value.get(ve);return fe}const L=getCurrentInstance("nested"),G=new Set,q={id:shallowRef(),root:{opened:u,activatable:toRef(t,"activatable"),selectable:toRef(t,"selectable"),activated:m,selected:O,selectedValues:computed(()=>{const J=[];for(const[fe,ve]of O.value.entries())ve==="on"&&J.push(fe);return J}),register:(J,fe,ve)=>{if(G.has(J)){N(J).join(" -> "),N(fe).concat(J).join(" -> ");return}else G.add(J);fe&&J!==fe&&n.value.set(J,fe),ve&&l.value.set(J,[]),fe!=null&&l.value.set(fe,[...l.value.get(fe)||[],J])},unregister:J=>{if(e)return;G.delete(J),l.value.delete(J);const fe=n.value.get(J);if(fe){const ve=l.value.get(fe)??[];l.value.set(fe,ve.filter(ne=>ne!==J))}n.value.delete(J)},open:(J,fe,ve)=>{L.emit("click:open",{id:J,value:fe,path:N(J),event:ve});const ne=b.value.open({id:J,value:fe,opened:new Set(u.value),children:l.value,parents:n.value,event:ve});ne&&(u.value=ne)},openOnSelect:(J,fe,ve)=>{const ne=b.value.select({id:J,value:fe,selected:new Map(O.value),opened:new Set(u.value),children:l.value,parents:n.value,event:ve});ne&&(u.value=ne)},select:(J,fe,ve)=>{L.emit("click:select",{id:J,value:fe,path:N(J),event:ve});const ne=y.value.select({id:J,value:fe,selected:new Map(O.value),children:l.value,parents:n.value,event:ve});ne&&(O.value=ne),q.root.openOnSelect(J,fe,ve)},activate:(J,fe,ve)=>{if(!t.activatable)return q.root.select(J,!0,ve);L.emit("click:activate",{id:J,value:fe,path:N(J),event:ve});const ne=c.value.activate({id:J,value:fe,activated:new Set(m.value),children:l.value,parents:n.value,event:ve});ne&&(m.value=ne)},children:l,parents:n,getPath:N}};return provide(VNestedSymbol,q),q.root},useNestedItem=(t,e)=>{const l=inject$1(VNestedSymbol,emptyNested),n=Symbol(getUid()),u=computed(()=>t.value!==void 0?t.value:n),c={...l,id:u,open:(y,b)=>l.root.open(u.value,y,b),openOnSelect:(y,b)=>l.root.openOnSelect(u.value,y,b),isOpen:computed(()=>l.root.opened.value.has(u.value)),parent:computed(()=>l.root.parents.value.get(u.value)),activate:(y,b)=>l.root.activate(u.value,y,b),isActivated:computed(()=>l.root.activated.value.has(toRaw(u.value))),select:(y,b)=>l.root.select(u.value,y,b),isSelected:computed(()=>l.root.selected.value.get(toRaw(u.value))==="on"),isIndeterminate:computed(()=>l.root.selected.value.get(u.value)==="indeterminate"),isLeaf:computed(()=>!l.root.children.value.get(u.value)),isGroupActivator:l.isGroupActivator};return!l.isGroupActivator&&l.root.register(u.value,l.id.value,e),onBeforeUnmount(()=>{!l.isGroupActivator&&l.root.unregister(u.value)}),e&&provide(VNestedSymbol,c),c},useNestedGroupActivator=()=>{const t=inject$1(VNestedSymbol,emptyNested);provide(VNestedSymbol,{...t,isGroupActivator:!0})};function useSsrBoot(){const t=shallowRef(!1);return onMounted(()=>{window.requestAnimationFrame(()=>{t.value=!0})}),{ssrBootStyles:computed(()=>t.value?void 0:{transition:"none !important"}),isBooted:readonly(t)}}const makeTransitionProps=propsFactory$1({transition:{type:[Boolean,String,Object],default:"fade-transition",validator:t=>t!==!0}},"transition"),MaybeTransition=(t,e)=>{let{slots:l}=e;const{transition:n,disabled:u,group:c,...y}=t,{component:b=c?TransitionGroup:Transition,...m}=typeof n=="object"?n:{};return h(b,mergeProps(typeof n=="string"?{name:u?"":n}:m,typeof n=="string"?{}:Object.fromEntries(Object.entries({disabled:u,group:c}).filter(O=>{let[N,L]=O;return L!==void 0})),y),l)},VListGroupActivator=defineComponent({name:"VListGroupActivator",setup(t,e){let{slots:l}=e;return useNestedGroupActivator(),()=>l.default?.()}}),makeVListGroupProps=propsFactory$1({activeColor:String,baseColor:String,color:String,collapseIcon:{type:IconValue$1,default:"$collapse"},expandIcon:{type:IconValue$1,default:"$expand"},prependIcon:IconValue$1,appendIcon:IconValue$1,fluid:Boolean,subgroup:Boolean,title:String,value:null,...makeComponentProps(),...makeTagProps()},"VListGroup"),VListGroup=genericComponent()({name:"VListGroup",props:makeVListGroupProps(),setup(t,e){let{slots:l}=e;const{isOpen:n,open:u,id:c}=useNestedItem(toRef(t,"value"),!0),y=computed(()=>`v-list-group--id-${String(c.value)}`),b=useList(),{isBooted:m}=useSsrBoot();function O(q){q.stopPropagation(),u(!n.value,q)}const N=computed(()=>({onClick:O,class:"v-list-group__header",id:y.value})),L=computed(()=>n.value?t.collapseIcon:t.expandIcon),G=computed(()=>({VListItem:{active:n.value,activeColor:t.activeColor,baseColor:t.baseColor,color:t.color,prependIcon:t.prependIcon||t.subgroup&&L.value,appendIcon:t.appendIcon||!t.subgroup&&L.value,title:t.title,value:t.value}}));return useRender(()=>createVNode(t.tag,{class:["v-list-group",{"v-list-group--prepend":b?.hasPrepend.value,"v-list-group--fluid":t.fluid,"v-list-group--subgroup":t.subgroup,"v-list-group--open":n.value},t.class],style:t.style},{default:()=>[l.activator&&createVNode(VDefaultsProvider,{defaults:G.value},{default:()=>[createVNode(VListGroupActivator,null,{default:()=>[l.activator({props:N.value,isOpen:n.value})]})]}),createVNode(MaybeTransition,{transition:{component:VExpandTransition},disabled:!m.value},{default:()=>[withDirectives(createVNode("div",{class:"v-list-group__items",role:"group","aria-labelledby":y.value},[l.default?.()]),[[vShow,n.value]])]})]})),{isOpen:n}}}),makeVListItemSubtitleProps=propsFactory$1({opacity:[Number,String],...makeComponentProps(),...makeTagProps()},"VListItemSubtitle"),VListItemSubtitle=genericComponent()({name:"VListItemSubtitle",props:makeVListItemSubtitleProps(),setup(t,e){let{slots:l}=e;return useRender(()=>createVNode(t.tag,{class:["v-list-item-subtitle",t.class],style:[{"--v-list-item-subtitle-opacity":t.opacity},t.style]},l)),{}}}),VListItemTitle=createSimpleFunctional("v-list-item-title"),makeDimensionProps=propsFactory$1({height:[Number,String],maxHeight:[Number,String],maxWidth:[Number,String],minHeight:[Number,String],minWidth:[Number,String],width:[Number,String]},"dimension");function useDimension(t){return{dimensionStyles:computed(()=>{const l={},n=convertToUnit(t.height),u=convertToUnit(t.maxHeight),c=convertToUnit(t.maxWidth),y=convertToUnit(t.minHeight),b=convertToUnit(t.minWidth),m=convertToUnit(t.width);return n!=null&&(l.height=n),u!=null&&(l.maxHeight=u),c!=null&&(l.maxWidth=c),y!=null&&(l.minHeight=y),b!=null&&(l.minWidth=b),m!=null&&(l.width=m),l})}}function useAspectStyles(t){return{aspectStyles:computed(()=>{const e=Number(t.aspectRatio);return e?{paddingBottom:String(1/e*100)+"%"}:void 0})}}const makeVResponsiveProps=propsFactory$1({aspectRatio:[String,Number],contentClass:null,inline:Boolean,...makeComponentProps(),...makeDimensionProps()},"VResponsive"),VResponsive=genericComponent()({name:"VResponsive",props:makeVResponsiveProps(),setup(t,e){let{slots:l}=e;const{aspectStyles:n}=useAspectStyles(t),{dimensionStyles:u}=useDimension(t);return useRender(()=>createVNode("div",{class:["v-responsive",{"v-responsive--inline":t.inline},t.class],style:[u.value,t.style]},[createVNode("div",{class:"v-responsive__sizer",style:n.value},null),l.additional?.(),l.default&&createVNode("div",{class:["v-responsive__content",t.contentClass]},[l.default()])])),{}}}),makeRoundedProps=propsFactory$1({rounded:{type:[Boolean,Number,String],default:void 0},tile:Boolean},"rounded");function useRounded(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:getCurrentInstanceName();return{roundedClasses:computed(()=>{const n=isRef(t)?t.value:t.rounded,u=isRef(t)?t.value:t.tile,c=[];if(n===!0||n==="")c.push(`${e}--rounded`);else if(typeof n=="string"||n===0)for(const y of String(n).split(" "))c.push(`rounded-${y}`);else(u||n===!1)&&c.push("rounded-0");return c})}}function mounted$5(t,e){if(!SUPPORTS_INTERSECTION)return;const l=e.modifiers||{},n=e.value,{handler:u,options:c}=typeof n=="object"?n:{handler:n,options:{}},y=new IntersectionObserver(function(){let b=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],m=arguments.length>1?arguments[1]:void 0;const O=t._observe?.[e.instance.$.uid];if(!O)return;const N=b.some(L=>L.isIntersecting);u&&(!l.quiet||O.init)&&(!l.once||N||O.init)&&u(N,b,m),N&&l.once?unmounted$3(t,e):O.init=!0},c);t._observe=Object(t._observe),t._observe[e.instance.$.uid]={init:!1,observer:y},y.observe(t)}function unmounted$3(t,e){const l=t._observe?.[e.instance.$.uid];l&&(l.observer.unobserve(t),delete t._observe[e.instance.$.uid])}const Intersect={mounted:mounted$5,unmounted:unmounted$3},makeVImgProps=propsFactory$1({absolute:Boolean,alt:String,cover:Boolean,color:String,draggable:{type:[Boolean,String],default:void 0},eager:Boolean,gradient:String,lazySrc:String,options:{type:Object,default:()=>({root:void 0,rootMargin:void 0,threshold:void 0})},sizes:String,src:{type:[String,Object],default:""},crossorigin:String,referrerpolicy:String,srcset:String,position:String,...makeVResponsiveProps(),...makeComponentProps(),...makeRoundedProps(),...makeTransitionProps()},"VImg"),VImg=genericComponent()({name:"VImg",directives:{intersect:Intersect},props:makeVImgProps(),emits:{loadstart:t=>!0,load:t=>!0,error:t=>!0},setup(t,e){let{emit:l,slots:n}=e;const{backgroundColorClasses:u,backgroundColorStyles:c}=useBackgroundColor(toRef(t,"color")),{roundedClasses:y}=useRounded(t),b=getCurrentInstance("VImg"),m=shallowRef(""),O=ref(),N=shallowRef(t.eager?"loading":"idle"),L=shallowRef(),G=shallowRef(),q=computed(()=>t.src&&typeof t.src=="object"?{src:t.src.src,srcset:t.srcset||t.src.srcset,lazySrc:t.lazySrc||t.src.lazySrc,aspect:Number(t.aspectRatio||t.src.aspect||0)}:{src:t.src,srcset:t.srcset,lazySrc:t.lazySrc,aspect:Number(t.aspectRatio||0)}),J=computed(()=>q.value.aspect||L.value/G.value||0);watch(()=>t.src,()=>{fe(N.value!=="idle")}),watch(J,(mt,Tt)=>{!mt&&Tt&&O.value&&Ve(O.value)}),onBeforeMount(()=>fe());function fe(mt){if(!(t.eager&&mt)&&!(SUPPORTS_INTERSECTION&&!mt&&!t.eager)){if(N.value="loading",q.value.lazySrc){const Tt=new Image;Tt.src=q.value.lazySrc,Ve(Tt,null)}q.value.src&&nextTick(()=>{l("loadstart",O.value?.currentSrc||q.value.src),setTimeout(()=>{if(!b.isUnmounted)if(O.value?.complete){if(O.value.naturalWidth||ne(),N.value==="error")return;J.value||Ve(O.value,null),N.value==="loading"&&ve()}else J.value||Ve(O.value),Ue()})})}}function ve(){b.isUnmounted||(Ue(),Ve(O.value),N.value="loaded",l("load",O.value?.currentSrc||q.value.src))}function ne(){b.isUnmounted||(N.value="error",l("error",O.value?.currentSrc||q.value.src))}function Ue(){const mt=O.value;mt&&(m.value=mt.currentSrc||mt.src)}let De=-1;onBeforeUnmount(()=>{clearTimeout(De)});function Ve(mt){let Tt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:100;const kt=()=>{if(clearTimeout(De),b.isUnmounted)return;const{naturalHeight:It,naturalWidth:nn}=mt;It||nn?(L.value=nn,G.value=It):!mt.complete&&N.value==="loading"&&Tt!=null?De=window.setTimeout(kt,Tt):(mt.currentSrc.endsWith(".svg")||mt.currentSrc.startsWith("data:image/svg+xml"))&&(L.value=1,G.value=1)};kt()}const rt=computed(()=>({"v-img__img--cover":t.cover,"v-img__img--contain":!t.cover})),Ae=()=>{if(!q.value.src||N.value==="idle")return null;const mt=createVNode("img",{class:["v-img__img",rt.value],style:{objectPosition:t.position},src:q.value.src,srcset:q.value.srcset,alt:t.alt,crossorigin:t.crossorigin,referrerpolicy:t.referrerpolicy,draggable:t.draggable,sizes:t.sizes,ref:O,onLoad:ve,onError:ne},null),Tt=n.sources?.();return createVNode(MaybeTransition,{transition:t.transition,appear:!0},{default:()=>[withDirectives(Tt?createVNode("picture",{class:"v-img__picture"},[Tt,mt]):mt,[[vShow,N.value==="loaded"]])]})},Te=()=>createVNode(MaybeTransition,{transition:t.transition},{default:()=>[q.value.lazySrc&&N.value!=="loaded"&&createVNode("img",{class:["v-img__img","v-img__img--preload",rt.value],style:{objectPosition:t.position},src:q.value.lazySrc,alt:t.alt,crossorigin:t.crossorigin,referrerpolicy:t.referrerpolicy,draggable:t.draggable},null)]}),Xe=()=>n.placeholder?createVNode(MaybeTransition,{transition:t.transition,appear:!0},{default:()=>[(N.value==="loading"||N.value==="error"&&!n.error)&&createVNode("div",{class:"v-img__placeholder"},[n.placeholder()])]}):null,ie=()=>n.error?createVNode(MaybeTransition,{transition:t.transition,appear:!0},{default:()=>[N.value==="error"&&createVNode("div",{class:"v-img__error"},[n.error()])]}):null,ue=()=>t.gradient?createVNode("div",{class:"v-img__gradient",style:{backgroundImage:`linear-gradient(${t.gradient})`}},null):null,pt=shallowRef(!1);{const mt=watch(J,Tt=>{Tt&&(requestAnimationFrame(()=>{requestAnimationFrame(()=>{pt.value=!0})}),mt())})}return useRender(()=>{const mt=VResponsive.filterProps(t);return withDirectives(createVNode(VResponsive,mergeProps({class:["v-img",{"v-img--absolute":t.absolute,"v-img--booting":!pt.value},u.value,y.value,t.class],style:[{width:convertToUnit(t.width==="auto"?L.value:t.width)},c.value,t.style]},mt,{aspectRatio:J.value,"aria-label":t.alt,role:t.alt?"img":void 0}),{additional:()=>createVNode(Fragment,null,[createVNode(Ae,null,null),createVNode(Te,null,null),createVNode(ue,null,null),createVNode(Xe,null,null),createVNode(ie,null,null)]),default:n.default}),[[resolveDirective("intersect"),{handler:fe,options:t.options},null,{once:!0}]])}),{currentSrc:m,image:O,state:N,naturalWidth:L,naturalHeight:G}}}),makeBorderProps=propsFactory$1({border:[Boolean,Number,String]},"border");function useBorder(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:getCurrentInstanceName();return{borderClasses:computed(()=>{const n=isRef(t)?t.value:t.border,u=[];if(n===!0||n==="")u.push(`${e}--border`);else if(typeof n=="string"||n===0)for(const c of String(n).split(" "))u.push(`border-${c}`);return u})}}const allowedDensities$1=[null,"default","comfortable","compact"],makeDensityProps=propsFactory$1({density:{type:String,default:"default",validator:t=>allowedDensities$1.includes(t)}},"density");function useDensity(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:getCurrentInstanceName();return{densityClasses:computed(()=>`${e}--density-${t.density}`)}}const allowedVariants$2=["elevated","flat","tonal","outlined","text","plain"];function genOverlays(t,e){return createVNode(Fragment,null,[t&&createVNode("span",{key:"overlay",class:`${e}__overlay`},null),createVNode("span",{key:"underlay",class:`${e}__underlay`},null)])}const makeVariantProps=propsFactory$1({color:String,variant:{type:String,default:"elevated",validator:t=>allowedVariants$2.includes(t)}},"variant");function useVariant(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:getCurrentInstanceName();const l=computed(()=>{const{variant:c}=unref(t);return`${e}--variant-${c}`}),{colorClasses:n,colorStyles:u}=useColor(computed(()=>{const{variant:c,color:y}=unref(t);return{[["elevated","flat"].includes(c)?"background":"text"]:y}}));return{colorClasses:n,colorStyles:u,variantClasses:l}}const makeVAvatarProps=propsFactory$1({start:Boolean,end:Boolean,icon:IconValue$1,image:String,text:String,...makeBorderProps(),...makeComponentProps(),...makeDensityProps(),...makeRoundedProps(),...makeSizeProps(),...makeTagProps(),...makeThemeProps(),...makeVariantProps({variant:"flat"})},"VAvatar"),VAvatar=genericComponent()({name:"VAvatar",props:makeVAvatarProps(),setup(t,e){let{slots:l}=e;const{themeClasses:n}=provideTheme(t),{borderClasses:u}=useBorder(t),{colorClasses:c,colorStyles:y,variantClasses:b}=useVariant(t),{densityClasses:m}=useDensity(t),{roundedClasses:O}=useRounded(t),{sizeClasses:N,sizeStyles:L}=useSize(t);return useRender(()=>createVNode(t.tag,{class:["v-avatar",{"v-avatar--start":t.start,"v-avatar--end":t.end},n.value,u.value,c.value,m.value,O.value,N.value,b.value,t.class],style:[y.value,L.value,t.style]},{default:()=>[l.default?createVNode(VDefaultsProvider,{key:"content-defaults",defaults:{VImg:{cover:!0,src:t.image},VIcon:{icon:t.icon}}},{default:()=>[l.default()]}):t.image?createVNode(VImg,{key:"image",src:t.image,alt:"",cover:!0},null):t.icon?createVNode(VIcon,{key:"icon",icon:t.icon},null):t.text,genOverlays(!1,"v-avatar")]})),{}}}),makeElevationProps=propsFactory$1({elevation:{type:[Number,String],validator(t){const e=parseInt(t);return!isNaN(e)&&e>=0&&e<=24}}},"elevation");function useElevation(t){return{elevationClasses:computed(()=>{const l=isRef(t)?t.value:t.elevation,n=[];return l==null||n.push(`elevation-${l}`),n})}}function useRoute(){const t=getCurrentInstance("useRoute");return computed(()=>t?.proxy?.$route)}function useRouter(){return getCurrentInstance("useRouter")?.proxy?.$router}function useLink(t,e){const l=resolveDynamicComponent("RouterLink"),n=computed(()=>!!(t.href||t.to)),u=computed(()=>n?.value||hasEvent(e,"click")||hasEvent(t,"click"));if(typeof l=="string"||!("useLink"in l)){const L=toRef(t,"href");return{isLink:n,isClickable:u,href:L,linkProps:reactive({href:L})}}const c=computed(()=>({...t,to:toRef(()=>t.to||"")})),y=l.useLink(c.value),b=computed(()=>t.to?y:void 0),m=useRoute(),O=computed(()=>b.value?t.exact?m.value?b.value.isExactActive?.value&&deepEqual(b.value.route.value.query,m.value.query):b.value.isExactActive?.value??!1:b.value.isActive?.value??!1:!1),N=computed(()=>t.to?b.value?.route.value.href:t.href);return{isLink:n,isClickable:u,isActive:O,route:b.value?.route,navigate:b.value?.navigate,href:N,linkProps:reactive({href:N,"aria-current":computed(()=>O.value?"page":void 0)})}}const makeRouterProps=propsFactory$1({href:String,replace:Boolean,to:[String,Object],exact:Boolean},"router");let inTransition=!1;function useBackButton(t,e){let l=!1,n,u;IN_BROWSER&&(nextTick(()=>{window.addEventListener("popstate",c),n=t?.beforeEach((y,b,m)=>{inTransition?l?e(m):m():setTimeout(()=>l?e(m):m()),inTransition=!0}),u=t?.afterEach(()=>{inTransition=!1})}),onScopeDispose(()=>{window.removeEventListener("popstate",c),n?.(),u?.()}));function c(y){y.state?.replaced||(l=!0,setTimeout(()=>l=!1))}}const stopSymbol=Symbol("rippleStop"),DELAY_RIPPLE=80;function transform(t,e){t.style.transform=e,t.style.webkitTransform=e}function isTouchEvent(t){return t.constructor.name==="TouchEvent"}function isKeyboardEvent(t){return t.constructor.name==="KeyboardEvent"}const calculate=function(t,e){let l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=0,u=0;if(!isKeyboardEvent(t)){const L=e.getBoundingClientRect(),G=isTouchEvent(t)?t.touches[t.touches.length-1]:t;n=G.clientX-L.left,u=G.clientY-L.top}let c=0,y=.3;e._ripple?.circle?(y=.15,c=e.clientWidth/2,c=l.center?c:c+Math.sqrt((n-c)**2+(u-c)**2)/4):c=Math.sqrt(e.clientWidth**2+e.clientHeight**2)/2;const b=`${(e.clientWidth-c*2)/2}px`,m=`${(e.clientHeight-c*2)/2}px`,O=l.center?b:`${n-c}px`,N=l.center?m:`${u-c}px`;return{radius:c,scale:y,x:O,y:N,centerX:b,centerY:m}},ripples={show(t,e){let l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(!e?._ripple?.enabled)return;const n=document.createElement("span"),u=document.createElement("span");n.appendChild(u),n.className="v-ripple__container",l.class&&(n.className+=` ${l.class}`);const{radius:c,scale:y,x:b,y:m,centerX:O,centerY:N}=calculate(t,e,l),L=`${c*2}px`;u.className="v-ripple__animation",u.style.width=L,u.style.height=L,e.appendChild(n);const G=window.getComputedStyle(e);G&&G.position==="static"&&(e.style.position="relative",e.dataset.previousPosition="static"),u.classList.add("v-ripple__animation--enter"),u.classList.add("v-ripple__animation--visible"),transform(u,`translate(${b}, ${m}) scale3d(${y},${y},${y})`),u.dataset.activated=String(performance.now()),setTimeout(()=>{u.classList.remove("v-ripple__animation--enter"),u.classList.add("v-ripple__animation--in"),transform(u,`translate(${O}, ${N}) scale3d(1,1,1)`)},0)},hide(t){if(!t?._ripple?.enabled)return;const e=t.getElementsByClassName("v-ripple__animation");if(e.length===0)return;const l=e[e.length-1];if(l.dataset.isHiding)return;l.dataset.isHiding="true";const n=performance.now()-Number(l.dataset.activated),u=Math.max(250-n,0);setTimeout(()=>{l.classList.remove("v-ripple__animation--in"),l.classList.add("v-ripple__animation--out"),setTimeout(()=>{t.getElementsByClassName("v-ripple__animation").length===1&&t.dataset.previousPosition&&(t.style.position=t.dataset.previousPosition,delete t.dataset.previousPosition),l.parentNode?.parentNode===t&&t.removeChild(l.parentNode)},300)},u)}};function isRippleEnabled(t){return typeof t>"u"||!!t}function rippleShow(t){const e={},l=t.currentTarget;if(!(!l?._ripple||l._ripple.touched||t[stopSymbol])){if(t[stopSymbol]=!0,isTouchEvent(t))l._ripple.touched=!0,l._ripple.isTouch=!0;else if(l._ripple.isTouch)return;if(e.center=l._ripple.centered||isKeyboardEvent(t),l._ripple.class&&(e.class=l._ripple.class),isTouchEvent(t)){if(l._ripple.showTimerCommit)return;l._ripple.showTimerCommit=()=>{ripples.show(t,l,e)},l._ripple.showTimer=window.setTimeout(()=>{l?._ripple?.showTimerCommit&&(l._ripple.showTimerCommit(),l._ripple.showTimerCommit=null)},DELAY_RIPPLE)}else ripples.show(t,l,e)}}function rippleStop(t){t[stopSymbol]=!0}function rippleHide(t){const e=t.currentTarget;if(e?._ripple){if(window.clearTimeout(e._ripple.showTimer),t.type==="touchend"&&e._ripple.showTimerCommit){e._ripple.showTimerCommit(),e._ripple.showTimerCommit=null,e._ripple.showTimer=window.setTimeout(()=>{rippleHide(t)});return}window.setTimeout(()=>{e._ripple&&(e._ripple.touched=!1)}),ripples.hide(e)}}function rippleCancelShow(t){const e=t.currentTarget;e?._ripple&&(e._ripple.showTimerCommit&&(e._ripple.showTimerCommit=null),window.clearTimeout(e._ripple.showTimer))}let keyboardRipple=!1;function keyboardRippleShow(t){!keyboardRipple&&(t.keyCode===keyCodes.enter||t.keyCode===keyCodes.space)&&(keyboardRipple=!0,rippleShow(t))}function keyboardRippleHide(t){keyboardRipple=!1,rippleHide(t)}function focusRippleHide(t){keyboardRipple&&(keyboardRipple=!1,rippleHide(t))}function updateRipple(t,e,l){const{value:n,modifiers:u}=e,c=isRippleEnabled(n);if(c||ripples.hide(t),t._ripple=t._ripple??{},t._ripple.enabled=c,t._ripple.centered=u.center,t._ripple.circle=u.circle,isObject$1(n)&&n.class&&(t._ripple.class=n.class),c&&!l){if(u.stop){t.addEventListener("touchstart",rippleStop,{passive:!0}),t.addEventListener("mousedown",rippleStop);return}t.addEventListener("touchstart",rippleShow,{passive:!0}),t.addEventListener("touchend",rippleHide,{passive:!0}),t.addEventListener("touchmove",rippleCancelShow,{passive:!0}),t.addEventListener("touchcancel",rippleHide),t.addEventListener("mousedown",rippleShow),t.addEventListener("mouseup",rippleHide),t.addEventListener("mouseleave",rippleHide),t.addEventListener("keydown",keyboardRippleShow),t.addEventListener("keyup",keyboardRippleHide),t.addEventListener("blur",focusRippleHide),t.addEventListener("dragstart",rippleHide,{passive:!0})}else!c&&l&&removeListeners(t)}function removeListeners(t){t.removeEventListener("mousedown",rippleShow),t.removeEventListener("touchstart",rippleShow),t.removeEventListener("touchend",rippleHide),t.removeEventListener("touchmove",rippleCancelShow),t.removeEventListener("touchcancel",rippleHide),t.removeEventListener("mouseup",rippleHide),t.removeEventListener("mouseleave",rippleHide),t.removeEventListener("keydown",keyboardRippleShow),t.removeEventListener("keyup",keyboardRippleHide),t.removeEventListener("dragstart",rippleHide),t.removeEventListener("blur",focusRippleHide)}function mounted$4(t,e){updateRipple(t,e,!1)}function unmounted$2(t){delete t._ripple,removeListeners(t)}function updated(t,e){if(e.value===e.oldValue)return;const l=isRippleEnabled(e.oldValue);updateRipple(t,e,l)}const Ripple={mounted:mounted$4,unmounted:unmounted$2,updated},makeVListItemProps=propsFactory$1({active:{type:Boolean,default:void 0},activeClass:String,activeColor:String,appendAvatar:String,appendIcon:IconValue$1,baseColor:String,disabled:Boolean,lines:[Boolean,String],link:{type:Boolean,default:void 0},nav:Boolean,prependAvatar:String,prependIcon:IconValue$1,ripple:{type:[Boolean,Object],default:!0},slim:Boolean,subtitle:[String,Number],title:[String,Number],value:null,onClick:EventProp(),onClickOnce:EventProp(),...makeBorderProps(),...makeComponentProps(),...makeDensityProps(),...makeDimensionProps(),...makeElevationProps(),...makeRoundedProps(),...makeRouterProps(),...makeTagProps(),...makeThemeProps(),...makeVariantProps({variant:"text"})},"VListItem"),VListItem=genericComponent()({name:"VListItem",directives:{Ripple},props:makeVListItemProps(),emits:{click:t=>!0},setup(t,e){let{attrs:l,slots:n,emit:u}=e;const c=useLink(t,l),y=computed(()=>t.value===void 0?c.href.value:t.value),{activate:b,isActivated:m,select:O,isOpen:N,isSelected:L,isIndeterminate:G,isGroupActivator:q,root:J,parent:fe,openOnSelect:ve,id:ne}=useNestedItem(y,!1),Ue=useList(),De=computed(()=>t.active!==!1&&(t.active||c.isActive?.value||(J.activatable.value?m.value:L.value))),Ve=computed(()=>t.link!==!1&&c.isLink.value),rt=computed(()=>!t.disabled&&t.link!==!1&&(t.link||c.isClickable.value||!!Ue&&(J.selectable.value||J.activatable.value||t.value!=null))),Ae=computed(()=>t.rounded||t.nav),Te=computed(()=>t.color??t.activeColor),Xe=computed(()=>({color:De.value?Te.value??t.baseColor:t.baseColor,variant:t.variant}));watch(()=>c.isActive?.value,Rn=>{Rn&&fe.value!=null&&J.open(fe.value,!0),Rn&&ve(Rn)},{immediate:!0});const{themeClasses:ie}=provideTheme(t),{borderClasses:ue}=useBorder(t),{colorClasses:pt,colorStyles:mt,variantClasses:Tt}=useVariant(Xe),{densityClasses:kt}=useDensity(t),{dimensionStyles:It}=useDimension(t),{elevationClasses:nn}=useElevation(t),{roundedClasses:tn}=useRounded(Ae),pn=computed(()=>t.lines?`v-list-item--${t.lines}-line`:void 0),_n=computed(()=>({isActive:De.value,select:O,isOpen:N.value,isSelected:L.value,isIndeterminate:G.value}));function Dn(Rn){u("click",Rn),rt.value&&(c.navigate?.(Rn),!q&&(J.activatable.value?b(!m.value,Rn):(J.selectable.value||t.value!=null)&&O(!L.value,Rn)))}function an(Rn){(Rn.key==="Enter"||Rn.key===" ")&&(Rn.preventDefault(),Rn.target.dispatchEvent(new MouseEvent("click",Rn)))}return useRender(()=>{const Rn=Ve.value?"a":t.tag,Lt=n.title||t.title!=null,wn=n.subtitle||t.subtitle!=null,hn=!!(t.appendAvatar||t.appendIcon),xn=!!(hn||n.append),$n=!!(t.prependAvatar||t.prependIcon),Xr=!!($n||n.prepend);return Ue?.updateHasPrepend(Xr),t.activeColor&&deprecate("active-color",["color","base-color"]),withDirectives(createVNode(Rn,mergeProps({class:["v-list-item",{"v-list-item--active":De.value,"v-list-item--disabled":t.disabled,"v-list-item--link":rt.value,"v-list-item--nav":t.nav,"v-list-item--prepend":!Xr&&Ue?.hasPrepend.value,"v-list-item--slim":t.slim,[`${t.activeClass}`]:t.activeClass&&De.value},ie.value,ue.value,pt.value,kt.value,nn.value,pn.value,tn.value,Tt.value,t.class],style:[mt.value,It.value,t.style],tabindex:rt.value?Ue?-2:0:void 0,onClick:Dn,onKeydown:rt.value&&!Ve.value&&an},c.linkProps),{default:()=>[genOverlays(rt.value||De.value,"v-list-item"),Xr&&createVNode("div",{key:"prepend",class:"v-list-item__prepend"},[n.prepend?createVNode(VDefaultsProvider,{key:"prepend-defaults",disabled:!$n,defaults:{VAvatar:{density:t.density,image:t.prependAvatar},VIcon:{density:t.density,icon:t.prependIcon},VListItemAction:{start:!0}}},{default:()=>[n.prepend?.(_n.value)]}):createVNode(Fragment,null,[t.prependAvatar&&createVNode(VAvatar,{key:"prepend-avatar",density:t.density,image:t.prependAvatar},null),t.prependIcon&&createVNode(VIcon,{key:"prepend-icon",density:t.density,icon:t.prependIcon},null)]),createVNode("div",{class:"v-list-item__spacer"},null)]),createVNode("div",{class:"v-list-item__content","data-no-activator":""},[Lt&&createVNode(VListItemTitle,{key:"title"},{default:()=>[n.title?.({title:t.title})??t.title]}),wn&&createVNode(VListItemSubtitle,{key:"subtitle"},{default:()=>[n.subtitle?.({subtitle:t.subtitle})??t.subtitle]}),n.default?.(_n.value)]),xn&&createVNode("div",{key:"append",class:"v-list-item__append"},[n.append?createVNode(VDefaultsProvider,{key:"append-defaults",disabled:!hn,defaults:{VAvatar:{density:t.density,image:t.appendAvatar},VIcon:{density:t.density,icon:t.appendIcon},VListItemAction:{end:!0}}},{default:()=>[n.append?.(_n.value)]}):createVNode(Fragment,null,[t.appendIcon&&createVNode(VIcon,{key:"append-icon",density:t.density,icon:t.appendIcon},null),t.appendAvatar&&createVNode(VAvatar,{key:"append-avatar",density:t.density,image:t.appendAvatar},null)]),createVNode("div",{class:"v-list-item__spacer"},null)])]}),[[resolveDirective("ripple"),rt.value&&t.ripple]])}),{activate:b,isActivated:m,isGroupActivator:q,isSelected:L,list:Ue,select:O,root:J,id:ne}}}),makeVListSubheaderProps=propsFactory$1({color:String,inset:Boolean,sticky:Boolean,title:String,...makeComponentProps(),...makeTagProps()},"VListSubheader"),VListSubheader=genericComponent()({name:"VListSubheader",props:makeVListSubheaderProps(),setup(t,e){let{slots:l}=e;const{textColorClasses:n,textColorStyles:u}=useTextColor(toRef(t,"color"));return useRender(()=>{const c=!!(l.default||t.title);return createVNode(t.tag,{class:["v-list-subheader",{"v-list-subheader--inset":t.inset,"v-list-subheader--sticky":t.sticky},n.value,t.class],style:[{textColorStyles:u},t.style]},{default:()=>[c&&createVNode("div",{class:"v-list-subheader__text"},[l.default?.()??t.title])]})}),{}}}),makeVDividerProps=propsFactory$1({color:String,inset:Boolean,length:[Number,String],opacity:[Number,String],thickness:[Number,String],vertical:Boolean,...makeComponentProps(),...makeThemeProps()},"VDivider"),VDivider=genericComponent()({name:"VDivider",props:makeVDividerProps(),setup(t,e){let{attrs:l,slots:n}=e;const{themeClasses:u}=provideTheme(t),{textColorClasses:c,textColorStyles:y}=useTextColor(toRef(t,"color")),b=computed(()=>{const m={};return t.length&&(m[t.vertical?"height":"width"]=convertToUnit(t.length)),t.thickness&&(m[t.vertical?"borderRightWidth":"borderTopWidth"]=convertToUnit(t.thickness)),m});return useRender(()=>{const m=createVNode("hr",{class:[{"v-divider":!0,"v-divider--inset":t.inset,"v-divider--vertical":t.vertical},u.value,c.value,t.class],style:[b.value,y.value,{"--v-border-opacity":t.opacity},t.style],"aria-orientation":!l.role||l.role==="separator"?t.vertical?"vertical":"horizontal":void 0,role:`${l.role||"separator"}`},null);return n.default?createVNode("div",{class:["v-divider__wrapper",{"v-divider__wrapper--vertical":t.vertical,"v-divider__wrapper--inset":t.inset}]},[m,createVNode("div",{class:"v-divider__content"},[n.default()]),m]):m}),{}}}),makeVListChildrenProps=propsFactory$1({items:Array,returnObject:Boolean},"VListChildren"),VListChildren=genericComponent()({name:"VListChildren",props:makeVListChildrenProps(),setup(t,e){let{slots:l}=e;return createList(),()=>l.default?.()??t.items?.map(n=>{let{children:u,props:c,type:y,raw:b}=n;if(y==="divider")return l.divider?.({props:c})??createVNode(VDivider,c,null);if(y==="subheader")return l.subheader?.({props:c})??createVNode(VListSubheader,c,null);const m={subtitle:l.subtitle?N=>l.subtitle?.({...N,item:b}):void 0,prepend:l.prepend?N=>l.prepend?.({...N,item:b}):void 0,append:l.append?N=>l.append?.({...N,item:b}):void 0,title:l.title?N=>l.title?.({...N,item:b}):void 0},O=VListGroup.filterProps(c);return u?createVNode(VListGroup,mergeProps({value:c?.value},O),{activator:N=>{let{props:L}=N;const G={...c,...L,value:t.returnObject?b:c.value};return l.header?l.header({props:G}):createVNode(VListItem,G,m)},default:()=>createVNode(VListChildren,{items:u,returnObject:t.returnObject},l)}):l.item?l.item({props:c}):createVNode(VListItem,mergeProps(c,{value:t.returnObject?b:c.value}),m)})}}),makeItemsProps=propsFactory$1({items:{type:Array,default:()=>[]},itemTitle:{type:[String,Array,Function],default:"title"},itemValue:{type:[String,Array,Function],default:"value"},itemChildren:{type:[Boolean,String,Array,Function],default:"children"},itemProps:{type:[Boolean,String,Array,Function],default:"props"},returnObject:Boolean,valueComparator:{type:Function,default:deepEqual}},"list-items");function transformItem$1(t,e){const l=getPropertyFromItem(e,t.itemTitle,e),n=getPropertyFromItem(e,t.itemValue,l),u=getPropertyFromItem(e,t.itemChildren),c=t.itemProps===!0?typeof e=="object"&&e!=null&&!Array.isArray(e)?"children"in e?omit(e,["children"]):e:void 0:getPropertyFromItem(e,t.itemProps),y={title:l,value:n,...c};return{title:String(y.title??""),value:y.value,props:y,children:Array.isArray(u)?transformItems$1(t,u):void 0,raw:e}}function transformItems$1(t,e){const l=[];for(const n of e)l.push(transformItem$1(t,n));return l}function useItems(t){const e=computed(()=>transformItems$1(t,t.items)),l=computed(()=>e.value.some(c=>c.value===null));function n(c){return l.value||(c=c.filter(y=>y!==null)),c.map(y=>t.returnObject&&typeof y=="string"?transformItem$1(t,y):e.value.find(b=>t.valueComparator(y,b.value))||transformItem$1(t,y))}function u(c){return t.returnObject?c.map(y=>{let{raw:b}=y;return b}):c.map(y=>{let{value:b}=y;return b})}return{items:e,transformIn:n,transformOut:u}}function isPrimitive(t){return typeof t=="string"||typeof t=="number"||typeof t=="boolean"}function transformItem(t,e){const l=getPropertyFromItem(e,t.itemType,"item"),n=isPrimitive(e)?e:getPropertyFromItem(e,t.itemTitle),u=getPropertyFromItem(e,t.itemValue,void 0),c=getPropertyFromItem(e,t.itemChildren),y=t.itemProps===!0?omit(e,["children"]):getPropertyFromItem(e,t.itemProps),b={title:n,value:u,...y};return{type:l,title:b.title,value:b.value,props:b,children:l==="item"&&c?transformItems(t,c):void 0,raw:e}}function transformItems(t,e){const l=[];for(const n of e)l.push(transformItem(t,n));return l}function useListItems(t){return{items:computed(()=>transformItems(t,t.items))}}const makeVListProps=propsFactory$1({baseColor:String,activeColor:String,activeClass:String,bgColor:String,disabled:Boolean,expandIcon:String,collapseIcon:String,lines:{type:[Boolean,String],default:"one"},slim:Boolean,nav:Boolean,"onClick:open":EventProp(),"onClick:select":EventProp(),"onUpdate:opened":EventProp(),...makeNestedProps({selectStrategy:"single-leaf",openStrategy:"list"}),...makeBorderProps(),...makeComponentProps(),...makeDensityProps(),...makeDimensionProps(),...makeElevationProps(),itemType:{type:String,default:"type"},...makeItemsProps(),...makeRoundedProps(),...makeTagProps(),...makeThemeProps(),...makeVariantProps({variant:"text"})},"VList"),VList=genericComponent()({name:"VList",props:makeVListProps(),emits:{"update:selected":t=>!0,"update:activated":t=>!0,"update:opened":t=>!0,"click:open":t=>!0,"click:activate":t=>!0,"click:select":t=>!0},setup(t,e){let{slots:l}=e;const{items:n}=useListItems(t),{themeClasses:u}=provideTheme(t),{backgroundColorClasses:c,backgroundColorStyles:y}=useBackgroundColor(toRef(t,"bgColor")),{borderClasses:b}=useBorder(t),{densityClasses:m}=useDensity(t),{dimensionStyles:O}=useDimension(t),{elevationClasses:N}=useElevation(t),{roundedClasses:L}=useRounded(t),{children:G,open:q,parents:J,select:fe,getPath:ve}=useNested(t),ne=computed(()=>t.lines?`v-list--${t.lines}-line`:void 0),Ue=toRef(t,"activeColor"),De=toRef(t,"baseColor"),Ve=toRef(t,"color");createList(),provideDefaults({VListGroup:{activeColor:Ue,baseColor:De,color:Ve,expandIcon:toRef(t,"expandIcon"),collapseIcon:toRef(t,"collapseIcon")},VListItem:{activeClass:toRef(t,"activeClass"),activeColor:Ue,baseColor:De,color:Ve,density:toRef(t,"density"),disabled:toRef(t,"disabled"),lines:toRef(t,"lines"),nav:toRef(t,"nav"),slim:toRef(t,"slim"),variant:toRef(t,"variant")}});const rt=shallowRef(!1),Ae=ref();function Te(Tt){rt.value=!0}function Xe(Tt){rt.value=!1}function ie(Tt){!rt.value&&!(Tt.relatedTarget&&Ae.value?.contains(Tt.relatedTarget))&&mt()}function ue(Tt){const kt=Tt.target;if(!(!Ae.value||["INPUT","TEXTAREA"].includes(kt.tagName))){if(Tt.key==="ArrowDown")mt("next");else if(Tt.key==="ArrowUp")mt("prev");else if(Tt.key==="Home")mt("first");else if(Tt.key==="End")mt("last");else return;Tt.preventDefault()}}function pt(Tt){rt.value=!0}function mt(Tt){if(Ae.value)return focusChild(Ae.value,Tt)}return useRender(()=>createVNode(t.tag,{ref:Ae,class:["v-list",{"v-list--disabled":t.disabled,"v-list--nav":t.nav,"v-list--slim":t.slim},u.value,c.value,b.value,m.value,N.value,ne.value,L.value,t.class],style:[y.value,O.value,t.style],tabindex:t.disabled||rt.value?-1:0,role:"listbox","aria-activedescendant":void 0,onFocusin:Te,onFocusout:Xe,onFocus:ie,onKeydown:ue,onMousedown:pt},{default:()=>[createVNode(VListChildren,{items:n.value,returnObject:t.returnObject},l)]})),{open:q,select:fe,focus:mt,children:G,parents:J,getPath:ve}}}),makeVLabelProps=propsFactory$1({text:String,onClick:EventProp(),...makeComponentProps(),...makeThemeProps()},"VLabel"),VLabel=genericComponent()({name:"VLabel",props:makeVLabelProps(),setup(t,e){let{slots:l}=e;return useRender(()=>createVNode("label",{class:["v-label",{"v-label--clickable":!!t.onClick},t.class],style:t.style,onClick:t.onClick},[t.text,l.default?.()])),{}}}),VSelectionControlGroupSymbol=Symbol.for("vuetify:selection-control-group"),makeSelectionControlGroupProps=propsFactory$1({color:String,disabled:{type:Boolean,default:null},defaultsTarget:String,error:Boolean,id:String,inline:Boolean,falseIcon:IconValue$1,trueIcon:IconValue$1,ripple:{type:[Boolean,Object],default:!0},multiple:{type:Boolean,default:null},name:String,readonly:{type:Boolean,default:null},modelValue:null,type:String,valueComparator:{type:Function,default:deepEqual},...makeComponentProps(),...makeDensityProps(),...makeThemeProps()},"SelectionControlGroup"),makeVSelectionControlGroupProps=propsFactory$1({...makeSelectionControlGroupProps({defaultsTarget:"VSelectionControl"})},"VSelectionControlGroup"),VSelectionControlGroup=genericComponent()({name:"VSelectionControlGroup",props:makeVSelectionControlGroupProps(),emits:{"update:modelValue":t=>!0},setup(t,e){let{slots:l}=e;const n=useProxiedModel(t,"modelValue"),u=getUid(),c=computed(()=>t.id||`v-selection-control-group-${u}`),y=computed(()=>t.name||c.value),b=new Set;return provide(VSelectionControlGroupSymbol,{modelValue:n,forceUpdate:()=>{b.forEach(m=>m())},onForceUpdate:m=>{b.add(m),onScopeDispose(()=>{b.delete(m)})}}),provideDefaults({[t.defaultsTarget]:{color:toRef(t,"color"),disabled:toRef(t,"disabled"),density:toRef(t,"density"),error:toRef(t,"error"),inline:toRef(t,"inline"),modelValue:n,multiple:computed(()=>!!t.multiple||t.multiple==null&&Array.isArray(n.value)),name:y,falseIcon:toRef(t,"falseIcon"),trueIcon:toRef(t,"trueIcon"),readonly:toRef(t,"readonly"),ripple:toRef(t,"ripple"),type:toRef(t,"type"),valueComparator:toRef(t,"valueComparator")}}),useRender(()=>createVNode("div",{class:["v-selection-control-group",{"v-selection-control-group--inline":t.inline},t.class],style:t.style,role:t.type==="radio"?"radiogroup":void 0},[l.default?.()])),{}}}),makeVSelectionControlProps=propsFactory$1({label:String,baseColor:String,trueValue:null,falseValue:null,value:null,...makeComponentProps(),...makeSelectionControlGroupProps()},"VSelectionControl");function useSelectionControl(t){const e=inject$1(VSelectionControlGroupSymbol,void 0),{densityClasses:l}=useDensity(t),n=useProxiedModel(t,"modelValue"),u=computed(()=>t.trueValue!==void 0?t.trueValue:t.value!==void 0?t.value:!0),c=computed(()=>t.falseValue!==void 0?t.falseValue:!1),y=computed(()=>!!t.multiple||t.multiple==null&&Array.isArray(n.value)),b=computed({get(){const q=e?e.modelValue.value:n.value;return y.value?wrapInArray(q).some(J=>t.valueComparator(J,u.value)):t.valueComparator(q,u.value)},set(q){if(t.readonly)return;const J=q?u.value:c.value;let fe=J;y.value&&(fe=q?[...wrapInArray(n.value),J]:wrapInArray(n.value).filter(ve=>!t.valueComparator(ve,u.value))),e?e.modelValue.value=fe:n.value=fe}}),{textColorClasses:m,textColorStyles:O}=useTextColor(computed(()=>{if(!(t.error||t.disabled))return b.value?t.color:t.baseColor})),{backgroundColorClasses:N,backgroundColorStyles:L}=useBackgroundColor(computed(()=>b.value&&!t.error&&!t.disabled?t.color:t.baseColor)),G=computed(()=>b.value?t.trueIcon:t.falseIcon);return{group:e,densityClasses:l,trueValue:u,falseValue:c,model:b,textColorClasses:m,textColorStyles:O,backgroundColorClasses:N,backgroundColorStyles:L,icon:G}}const VSelectionControl=genericComponent()({name:"VSelectionControl",directives:{Ripple},inheritAttrs:!1,props:makeVSelectionControlProps(),emits:{"update:modelValue":t=>!0},setup(t,e){let{attrs:l,slots:n}=e;const{group:u,densityClasses:c,icon:y,model:b,textColorClasses:m,textColorStyles:O,backgroundColorClasses:N,backgroundColorStyles:L,trueValue:G}=useSelectionControl(t),q=getUid(),J=shallowRef(!1),fe=shallowRef(!1),ve=ref(),ne=computed(()=>t.id||`input-${q}`),Ue=computed(()=>!t.disabled&&!t.readonly);u?.onForceUpdate(()=>{ve.value&&(ve.value.checked=b.value)});function De(Te){Ue.value&&(J.value=!0,matchesSelector(Te.target,":focus-visible")!==!1&&(fe.value=!0))}function Ve(){J.value=!1,fe.value=!1}function rt(Te){Te.stopPropagation()}function Ae(Te){if(!Ue.value){ve.value&&(ve.value.checked=b.value);return}t.readonly&&u&&nextTick(()=>u.forceUpdate()),b.value=Te.target.checked}return useRender(()=>{const Te=n.label?n.label({label:t.label,props:{for:ne.value}}):t.label,[Xe,ie]=filterInputAttrs(l),ue=createVNode("input",mergeProps({ref:ve,checked:b.value,disabled:!!t.disabled,id:ne.value,onBlur:Ve,onFocus:De,onInput:Ae,"aria-disabled":!!t.disabled,"aria-label":t.label,type:t.type,value:G.value,name:t.name,"aria-checked":t.type==="checkbox"?b.value:void 0},ie),null);return createVNode("div",mergeProps({class:["v-selection-control",{"v-selection-control--dirty":b.value,"v-selection-control--disabled":t.disabled,"v-selection-control--error":t.error,"v-selection-control--focused":J.value,"v-selection-control--focus-visible":fe.value,"v-selection-control--inline":t.inline},c.value,t.class]},Xe,{style:t.style}),[createVNode("div",{class:["v-selection-control__wrapper",m.value],style:O.value},[n.default?.({backgroundColorClasses:N,backgroundColorStyles:L}),withDirectives(createVNode("div",{class:["v-selection-control__input"]},[n.input?.({model:b,textColorClasses:m,textColorStyles:O,backgroundColorClasses:N,backgroundColorStyles:L,inputNode:ue,icon:y.value,props:{onFocus:De,onBlur:Ve,id:ne.value}})??createVNode(Fragment,null,[y.value&&createVNode(VIcon,{key:"icon",icon:y.value},null),ue])]),[[resolveDirective("ripple"),t.ripple&&[!t.disabled&&!t.readonly,null,["center","circle"]]]])]),Te&&createVNode(VLabel,{for:ne.value,onClick:rt},{default:()=>[Te]})])}),{isFocused:J,input:ve}}}),makeVCheckboxBtnProps=propsFactory$1({indeterminate:Boolean,indeterminateIcon:{type:IconValue$1,default:"$checkboxIndeterminate"},...makeVSelectionControlProps({falseIcon:"$checkboxOff",trueIcon:"$checkboxOn"})},"VCheckboxBtn"),VCheckboxBtn=genericComponent()({name:"VCheckboxBtn",props:makeVCheckboxBtnProps(),emits:{"update:modelValue":t=>!0,"update:indeterminate":t=>!0},setup(t,e){let{slots:l}=e;const n=useProxiedModel(t,"indeterminate"),u=useProxiedModel(t,"modelValue");function c(m){n.value&&(n.value=!1)}const y=computed(()=>n.value?t.indeterminateIcon:t.falseIcon),b=computed(()=>n.value?t.indeterminateIcon:t.trueIcon);return useRender(()=>{const m=omit(VSelectionControl.filterProps(t),["modelValue"]);return createVNode(VSelectionControl,mergeProps(m,{modelValue:u.value,"onUpdate:modelValue":[O=>u.value=O,c],class:["v-checkbox-btn",t.class],style:t.style,type:"checkbox",falseIcon:y.value,trueIcon:b.value,"aria-checked":n.value?"mixed":void 0}),l)}),{}}});function useInputIcon(t){const{t:e}=useLocale();function l(n){let{name:u}=n;const c={prepend:"prependAction",prependInner:"prependAction",append:"appendAction",appendInner:"appendAction",clear:"clear"}[u],y=t[`onClick:${u}`],b=y&&c?e(`$vuetify.input.${c}`,t.label??""):void 0;return createVNode(VIcon,{icon:t[`${u}Icon`],"aria-label":b,onClick:y},null)}return{InputIcon:l}}const makeVMessagesProps=propsFactory$1({active:Boolean,color:String,messages:{type:[Array,String],default:()=>[]},...makeComponentProps(),...makeTransitionProps({transition:{component:VSlideYTransition,leaveAbsolute:!0,group:!0}})},"VMessages"),VMessages=genericComponent()({name:"VMessages",props:makeVMessagesProps(),setup(t,e){let{slots:l}=e;const n=computed(()=>wrapInArray(t.messages)),{textColorClasses:u,textColorStyles:c}=useTextColor(computed(()=>t.color));return useRender(()=>createVNode(MaybeTransition,{transition:t.transition,tag:"div",class:["v-messages",u.value,t.class],style:[c.value,t.style],role:"alert","aria-live":"polite"},{default:()=>[t.active&&n.value.map((y,b)=>createVNode("div",{class:"v-messages__message",key:`${b}-${n.value}`},[l.message?l.message({message:y}):y]))]})),{}}}),makeFocusProps=propsFactory$1({focused:Boolean,"onUpdate:focused":EventProp()},"focus");function useFocus(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:getCurrentInstanceName();const l=useProxiedModel(t,"focused"),n=computed(()=>({[`${e}--focused`]:l.value}));function u(){l.value=!0}function c(){l.value=!1}return{focusClasses:n,isFocused:l,focus:u,blur:c}}const FormKey=Symbol.for("vuetify:form"),makeFormProps=propsFactory$1({disabled:Boolean,fastFail:Boolean,readonly:Boolean,modelValue:{type:Boolean,default:null},validateOn:{type:String,default:"input"}},"form");function createForm(t){const e=useProxiedModel(t,"modelValue"),l=computed(()=>t.disabled),n=computed(()=>t.readonly),u=shallowRef(!1),c=ref([]),y=ref([]);async function b(){const N=[];let L=!0;y.value=[],u.value=!0;for(const G of c.value){const q=await G.validate();if(q.length>0&&(L=!1,N.push({id:G.id,errorMessages:q})),!L&&t.fastFail)break}return y.value=N,u.value=!1,{valid:L,errors:y.value}}function m(){c.value.forEach(N=>N.reset())}function O(){c.value.forEach(N=>N.resetValidation())}return watch(c,()=>{let N=0,L=0;const G=[];for(const q of c.value)q.isValid===!1?(L++,G.push({id:q.id,errorMessages:q.errorMessages})):q.isValid===!0&&N++;y.value=G,e.value=L>0?!1:N===c.value.length?!0:null},{deep:!0,flush:"post"}),provide(FormKey,{register:N=>{let{id:L,vm:G,validate:q,reset:J,resetValidation:fe}=N;c.value.some(ve=>ve.id===L),c.value.push({id:L,validate:q,reset:J,resetValidation:fe,vm:markRaw(G),isValid:null,errorMessages:[]})},unregister:N=>{c.value=c.value.filter(L=>L.id!==N)},update:(N,L,G)=>{const q=c.value.find(J=>J.id===N);q&&(q.isValid=L,q.errorMessages=G)},isDisabled:l,isReadonly:n,isValidating:u,isValid:e,items:c,validateOn:toRef(t,"validateOn")}),{errors:y,isDisabled:l,isReadonly:n,isValidating:u,isValid:e,items:c,validate:b,reset:m,resetValidation:O}}function useForm(){return inject$1(FormKey,null)}const makeValidationProps=propsFactory$1({disabled:{type:Boolean,default:null},error:Boolean,errorMessages:{type:[Array,String],default:()=>[]},maxErrors:{type:[Number,String],default:1},name:String,label:String,readonly:{type:Boolean,default:null},rules:{type:Array,default:()=>[]},modelValue:null,validateOn:String,validationValue:null,...makeFocusProps()},"validation");function useValidation(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:getCurrentInstanceName(),l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:getUid();const n=useProxiedModel(t,"modelValue"),u=computed(()=>t.validationValue===void 0?n.value:t.validationValue),c=useForm(),y=ref([]),b=shallowRef(!0),m=computed(()=>!!(wrapInArray(n.value===""?null:n.value).length||wrapInArray(u.value===""?null:u.value).length)),O=computed(()=>!!(t.disabled??c?.isDisabled.value)),N=computed(()=>!!(t.readonly??c?.isReadonly.value)),L=computed(()=>t.errorMessages?.length?wrapInArray(t.errorMessages).concat(y.value).slice(0,Math.max(0,+t.maxErrors)):y.value),G=computed(()=>{let rt=(t.validateOn??c?.validateOn.value)||"input";rt==="lazy"&&(rt="input lazy"),rt==="eager"&&(rt="input eager");const Ae=new Set(rt?.split(" ")??[]);return{input:Ae.has("input"),blur:Ae.has("blur")||Ae.has("input")||Ae.has("invalid-input"),invalidInput:Ae.has("invalid-input"),lazy:Ae.has("lazy"),eager:Ae.has("eager")}}),q=computed(()=>t.error||t.errorMessages?.length?!1:t.rules.length?b.value?y.value.length||G.value.lazy?null:!0:!y.value.length:!0),J=shallowRef(!1),fe=computed(()=>({[`${e}--error`]:q.value===!1,[`${e}--dirty`]:m.value,[`${e}--disabled`]:O.value,[`${e}--readonly`]:N.value})),ve=getCurrentInstance("validation"),ne=computed(()=>t.name??unref(l));onBeforeMount(()=>{c?.register({id:ne.value,vm:ve,validate:Ve,reset:Ue,resetValidation:De})}),onBeforeUnmount(()=>{c?.unregister(ne.value)}),onMounted(async()=>{G.value.lazy||await Ve(!G.value.eager),c?.update(ne.value,q.value,L.value)}),useToggleScope(()=>G.value.input||G.value.invalidInput&&q.value===!1,()=>{watch(u,()=>{if(u.value!=null)Ve();else if(t.focused){const rt=watch(()=>t.focused,Ae=>{Ae||Ve(),rt()})}})}),useToggleScope(()=>G.value.blur,()=>{watch(()=>t.focused,rt=>{rt||Ve()})}),watch([q,L],()=>{c?.update(ne.value,q.value,L.value)});async function Ue(){n.value=null,await nextTick(),await De()}async function De(){b.value=!0,G.value.lazy?y.value=[]:await Ve(!G.value.eager)}async function Ve(){let rt=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;const Ae=[];J.value=!0;for(const Te of t.rules){if(Ae.length>=+(t.maxErrors??1))break;const ie=await(typeof Te=="function"?Te:()=>Te)(u.value);if(ie!==!0){if(ie!==!1&&typeof ie!="string"){console.warn(`${ie} is not a valid value. Rule functions must return boolean true or a string.`);continue}Ae.push(ie||"")}}return y.value=Ae,J.value=!1,b.value=rt,y.value}return{errorMessages:L,isDirty:m,isDisabled:O,isReadonly:N,isPristine:b,isValid:q,isValidating:J,reset:Ue,resetValidation:De,validate:Ve,validationClasses:fe}}const makeVInputProps=propsFactory$1({id:String,appendIcon:IconValue$1,centerAffix:{type:Boolean,default:!0},prependIcon:IconValue$1,hideDetails:[Boolean,String],hideSpinButtons:Boolean,hint:String,persistentHint:Boolean,messages:{type:[Array,String],default:()=>[]},direction:{type:String,default:"horizontal",validator:t=>["horizontal","vertical"].includes(t)},"onClick:prepend":EventProp(),"onClick:append":EventProp(),...makeComponentProps(),...makeDensityProps(),...only(makeDimensionProps(),["maxWidth","minWidth","width"]),...makeThemeProps(),...makeValidationProps()},"VInput"),VInput=genericComponent()({name:"VInput",props:{...makeVInputProps()},emits:{"update:modelValue":t=>!0},setup(t,e){let{attrs:l,slots:n,emit:u}=e;const{densityClasses:c}=useDensity(t),{dimensionStyles:y}=useDimension(t),{themeClasses:b}=provideTheme(t),{rtlClasses:m}=useRtl(),{InputIcon:O}=useInputIcon(t),N=getUid(),L=computed(()=>t.id||`input-${N}`),G=computed(()=>`${L.value}-messages`),{errorMessages:q,isDirty:J,isDisabled:fe,isReadonly:ve,isPristine:ne,isValid:Ue,isValidating:De,reset:Ve,resetValidation:rt,validate:Ae,validationClasses:Te}=useValidation(t,"v-input",L),Xe=computed(()=>({id:L,messagesId:G,isDirty:J,isDisabled:fe,isReadonly:ve,isPristine:ne,isValid:Ue,isValidating:De,reset:Ve,resetValidation:rt,validate:Ae})),ie=computed(()=>t.errorMessages?.length||!ne.value&&q.value.length?q.value:t.hint&&(t.persistentHint||t.focused)?t.hint:t.messages);return useRender(()=>{const ue=!!(n.prepend||t.prependIcon),pt=!!(n.append||t.appendIcon),mt=ie.value.length>0,Tt=!t.hideDetails||t.hideDetails==="auto"&&(mt||!!n.details);return createVNode("div",{class:["v-input",`v-input--${t.direction}`,{"v-input--center-affix":t.centerAffix,"v-input--hide-spin-buttons":t.hideSpinButtons},c.value,b.value,m.value,Te.value,t.class],style:[y.value,t.style]},[ue&&createVNode("div",{key:"prepend",class:"v-input__prepend"},[n.prepend?.(Xe.value),t.prependIcon&&createVNode(O,{key:"prepend-icon",name:"prepend"},null)]),n.default&&createVNode("div",{class:"v-input__control"},[n.default?.(Xe.value)]),pt&&createVNode("div",{key:"append",class:"v-input__append"},[t.appendIcon&&createVNode(O,{key:"append-icon",name:"append"},null),n.append?.(Xe.value)]),Tt&&createVNode("div",{class:"v-input__details"},[createVNode(VMessages,{id:G.value,active:mt,messages:ie.value},{message:n.message}),n.details?.(Xe.value)])])}),{reset:Ve,resetValidation:rt,validate:Ae,isValid:Ue,errorMessages:q}}}),makeVCheckboxProps=propsFactory$1({...makeVInputProps(),...omit(makeVCheckboxBtnProps(),["inline"])},"VCheckbox"),VCheckbox=genericComponent()({name:"VCheckbox",inheritAttrs:!1,props:makeVCheckboxProps(),emits:{"update:modelValue":t=>!0,"update:focused":t=>!0},setup(t,e){let{attrs:l,slots:n}=e;const u=useProxiedModel(t,"modelValue"),{isFocused:c,focus:y,blur:b}=useFocus(t),m=getUid(),O=computed(()=>t.id||`checkbox-${m}`);return useRender(()=>{const[N,L]=filterInputAttrs(l),G=VInput.filterProps(t),q=VCheckboxBtn.filterProps(t);return createVNode(VInput,mergeProps({class:["v-checkbox",t.class]},N,G,{modelValue:u.value,"onUpdate:modelValue":J=>u.value=J,id:O.value,focused:c.value,style:t.style}),{...n,default:J=>{let{id:fe,messagesId:ve,isDisabled:ne,isReadonly:Ue,isValid:De}=J;return createVNode(VCheckboxBtn,mergeProps(q,{id:fe.value,"aria-describedby":ve.value,disabled:ne.value,readonly:Ue.value},L,{error:De.value===!1,modelValue:u.value,"onUpdate:modelValue":Ve=>u.value=Ve,onFocus:y,onBlur:b}),n)}})}),{}}}),makeGroupProps=propsFactory$1({modelValue:{type:null,default:void 0},multiple:Boolean,mandatory:[Boolean,String],max:Number,selectedClass:String,disabled:Boolean},"group"),makeGroupItemProps=propsFactory$1({value:null,disabled:Boolean,selectedClass:String},"group-item");function useGroupItem(t,e){let l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;const n=getCurrentInstance("useGroupItem");if(!n)throw new Error("[Vuetify] useGroupItem composable must be used inside a component setup function");const u=getUid();provide(Symbol.for(`${e.description}:id`),u);const c=inject$1(e,null);if(!c){if(!l)return c;throw new Error(`[Vuetify] Could not find useGroup injection with symbol ${e.description}`)}const y=toRef(t,"value"),b=computed(()=>!!(c.disabled.value||t.disabled));c.register({id:u,value:y,disabled:b},n),onBeforeUnmount(()=>{c.unregister(u)});const m=computed(()=>c.isSelected(u)),O=computed(()=>c.items.value[0].id===u),N=computed(()=>c.items.value[c.items.value.length-1].id===u),L=computed(()=>m.value&&[c.selectedClass.value,t.selectedClass]);return watch(m,G=>{n.emit("group:selected",{value:G})},{flush:"sync"}),{id:u,isSelected:m,isFirst:O,isLast:N,toggle:()=>c.select(u,!m.value),select:G=>c.select(u,G),selectedClass:L,value:y,disabled:b,group:c}}function useGroup(t,e){let l=!1;const n=reactive([]),u=useProxiedModel(t,"modelValue",[],G=>G==null?[]:getIds(n,wrapInArray(G)),G=>{const q=getValues(n,G);return t.multiple?q:q[0]}),c=getCurrentInstance("useGroup");function y(G,q){const J=G,fe=Symbol.for(`${e.description}:id`),ne=findChildrenWithProvide(fe,c?.vnode).indexOf(q);unref(J.value)==null&&(J.value=ne,J.useIndexAsValue=!0),ne>-1?n.splice(ne,0,J):n.push(J)}function b(G){if(l)return;m();const q=n.findIndex(J=>J.id===G);n.splice(q,1)}function m(){const G=n.find(q=>!q.disabled);G&&t.mandatory==="force"&&!u.value.length&&(u.value=[G.id])}onMounted(()=>{m()}),onBeforeUnmount(()=>{l=!0}),onUpdated(()=>{for(let G=0;G<n.length;G++)n[G].useIndexAsValue&&(n[G].value=G)});function O(G,q){const J=n.find(fe=>fe.id===G);if(!(q&&J?.disabled))if(t.multiple){const fe=u.value.slice(),ve=fe.findIndex(Ue=>Ue===G),ne=~ve;if(q=q??!ne,ne&&t.mandatory&&fe.length<=1||!ne&&t.max!=null&&fe.length+1>t.max)return;ve<0&&q?fe.push(G):ve>=0&&!q&&fe.splice(ve,1),u.value=fe}else{const fe=u.value.includes(G);if(t.mandatory&&fe)return;u.value=q??!fe?[G]:[]}}function N(G){if(t.multiple,u.value.length){const q=u.value[0],J=n.findIndex(ne=>ne.id===q);let fe=(J+G)%n.length,ve=n[fe];for(;ve.disabled&&fe!==J;)fe=(fe+G)%n.length,ve=n[fe];if(ve.disabled)return;u.value=[n[fe].id]}else{const q=n.find(J=>!J.disabled);q&&(u.value=[q.id])}}const L={register:y,unregister:b,selected:u,select:O,disabled:toRef(t,"disabled"),prev:()=>N(n.length-1),next:()=>N(1),isSelected:G=>u.value.includes(G),selectedClass:computed(()=>t.selectedClass),items:computed(()=>n),getItemIndex:G=>getItemIndex(n,G)};return provide(e,L),L}function getItemIndex(t,e){const l=getIds(t,[e]);return l.length?t.findIndex(n=>n.id===l[0]):-1}function getIds(t,e){const l=[];return e.forEach(n=>{const u=t.find(y=>deepEqual(n,y.value)),c=t[n];u?.value!=null?l.push(u.id):c!=null&&l.push(c.id)}),l}function getValues(t,e){const l=[];return e.forEach(n=>{const u=t.findIndex(c=>c.id===n);if(~u){const c=t[u];l.push(c.value!=null?c.value:u)}}),l}function calculateUpdatedTarget(t){let{selectedElement:e,containerElement:l,isRtl:n,isHorizontal:u}=t;const c=getOffsetSize(u,l),y=getScrollPosition(u,n,l),b=getOffsetSize(u,e),m=getOffsetPosition(u,e),O=b*.4;return y>m?m-O:y+c<m+b?m-c+b+O:y}function calculateCenteredTarget(t){let{selectedElement:e,containerElement:l,isHorizontal:n}=t;const u=getOffsetSize(n,l),c=getOffsetPosition(n,e),y=getOffsetSize(n,e);return c-u/2+y/2}function getScrollSize(t,e){return e?.[t?"scrollWidth":"scrollHeight"]||0}function getClientSize(t,e){return e?.[t?"clientWidth":"clientHeight"]||0}function getScrollPosition(t,e,l){if(!l)return 0;const{scrollLeft:n,offsetWidth:u,scrollWidth:c}=l;return t?e?c-u+n:n:l.scrollTop}function getOffsetSize(t,e){return e?.[t?"offsetWidth":"offsetHeight"]||0}function getOffsetPosition(t,e){return e?.[t?"offsetLeft":"offsetTop"]||0}const VSlideGroupSymbol=Symbol.for("vuetify:v-slide-group"),makeVSlideGroupProps=propsFactory$1({centerActive:Boolean,direction:{type:String,default:"horizontal"},symbol:{type:null,default:VSlideGroupSymbol},nextIcon:{type:IconValue$1,default:"$next"},prevIcon:{type:IconValue$1,default:"$prev"},showArrows:{type:[Boolean,String],validator:t=>typeof t=="boolean"||["always","desktop","mobile"].includes(t)},...makeComponentProps(),...makeDisplayProps({mobile:null}),...makeTagProps(),...makeGroupProps({selectedClass:"v-slide-group-item--active"})},"VSlideGroup"),VSlideGroup=genericComponent()({name:"VSlideGroup",props:makeVSlideGroupProps(),emits:{"update:modelValue":t=>!0},setup(t,e){let{slots:l}=e;const{isRtl:n}=useRtl(),{displayClasses:u,mobile:c}=useDisplay(t),y=useGroup(t,t.symbol),b=shallowRef(!1),m=shallowRef(0),O=shallowRef(0),N=shallowRef(0),L=computed(()=>t.direction==="horizontal"),{resizeRef:G,contentRect:q}=useResizeObserver(),{resizeRef:J,contentRect:fe}=useResizeObserver(),ve=useGoTo(),ne=computed(()=>({container:G.el,duration:200,easing:"easeOutQuart"})),Ue=computed(()=>y.selected.value.length?y.items.value.findIndex(Dn=>Dn.id===y.selected.value[0]):-1),De=computed(()=>y.selected.value.length?y.items.value.findIndex(Dn=>Dn.id===y.selected.value[y.selected.value.length-1]):-1);if(IN_BROWSER){let Dn=-1;watch(()=>[y.selected.value,q.value,fe.value,L.value],()=>{cancelAnimationFrame(Dn),Dn=requestAnimationFrame(()=>{if(q.value&&fe.value){const an=L.value?"width":"height";O.value=q.value[an],N.value=fe.value[an],b.value=O.value+1<N.value}if(Ue.value>=0&&J.el){const an=J.el.children[De.value];rt(an,t.centerActive)}})})}const Ve=shallowRef(!1);function rt(Dn,an){let Rn=0;an?Rn=calculateCenteredTarget({containerElement:G.el,isHorizontal:L.value,selectedElement:Dn}):Rn=calculateUpdatedTarget({containerElement:G.el,isHorizontal:L.value,isRtl:n.value,selectedElement:Dn}),Ae(Rn)}function Ae(Dn){if(!IN_BROWSER||!G.el)return;const an=getOffsetSize(L.value,G.el),Rn=getScrollPosition(L.value,n.value,G.el);if(!(getScrollSize(L.value,G.el)<=an||Math.abs(Dn-Rn)<16)){if(L.value&&n.value&&G.el){const{scrollWidth:wn,offsetWidth:hn}=G.el;Dn=wn-hn-Dn}L.value?ve.horizontal(Dn,ne.value):ve(Dn,ne.value)}}function Te(Dn){const{scrollTop:an,scrollLeft:Rn}=Dn.target;m.value=L.value?Rn:an}function Xe(Dn){if(Ve.value=!0,!(!b.value||!J.el)){for(const an of Dn.composedPath())for(const Rn of J.el.children)if(Rn===an){rt(Rn);return}}}function ie(Dn){Ve.value=!1}let ue=!1;function pt(Dn){!ue&&!Ve.value&&!(Dn.relatedTarget&&J.el?.contains(Dn.relatedTarget))&&kt(),ue=!1}function mt(){ue=!0}function Tt(Dn){if(!J.el)return;function an(Rn){Dn.preventDefault(),kt(Rn)}L.value?Dn.key==="ArrowRight"?an(n.value?"prev":"next"):Dn.key==="ArrowLeft"&&an(n.value?"next":"prev"):Dn.key==="ArrowDown"?an("next"):Dn.key==="ArrowUp"&&an("prev"),Dn.key==="Home"?an("first"):Dn.key==="End"&&an("last")}function kt(Dn){if(!J.el)return;let an;if(!Dn)an=focusableChildren(J.el)[0];else if(Dn==="next"){if(an=J.el.querySelector(":focus")?.nextElementSibling,!an)return kt("first")}else if(Dn==="prev"){if(an=J.el.querySelector(":focus")?.previousElementSibling,!an)return kt("last")}else Dn==="first"?an=J.el.firstElementChild:Dn==="last"&&(an=J.el.lastElementChild);an&&an.focus({preventScroll:!0})}function It(Dn){const an=L.value&&n.value?-1:1,Rn=(Dn==="prev"?-an:an)*O.value;let Lt=m.value+Rn;if(L.value&&n.value&&G.el){const{scrollWidth:wn,offsetWidth:hn}=G.el;Lt+=wn-hn}Ae(Lt)}const nn=computed(()=>({next:y.next,prev:y.prev,select:y.select,isSelected:y.isSelected})),tn=computed(()=>{switch(t.showArrows){case"always":return!0;case"desktop":return!c.value;case!0:return b.value||Math.abs(m.value)>0;case"mobile":return c.value||b.value||Math.abs(m.value)>0;default:return!c.value&&(b.value||Math.abs(m.value)>0)}}),pn=computed(()=>Math.abs(m.value)>1),_n=computed(()=>{if(!G.value)return!1;const Dn=getScrollSize(L.value,G.el),an=getClientSize(L.value,G.el);return Dn-an-Math.abs(m.value)>1});return useRender(()=>createVNode(t.tag,{class:["v-slide-group",{"v-slide-group--vertical":!L.value,"v-slide-group--has-affixes":tn.value,"v-slide-group--is-overflowing":b.value},u.value,t.class],style:t.style,tabindex:Ve.value||y.selected.value.length?-1:0,onFocus:pt},{default:()=>[tn.value&&createVNode("div",{key:"prev",class:["v-slide-group__prev",{"v-slide-group__prev--disabled":!pn.value}],onMousedown:mt,onClick:()=>pn.value&&It("prev")},[l.prev?.(nn.value)??createVNode(VFadeTransition,null,{default:()=>[createVNode(VIcon,{icon:n.value?t.nextIcon:t.prevIcon},null)]})]),createVNode("div",{key:"container",ref:G,class:"v-slide-group__container",onScroll:Te},[createVNode("div",{ref:J,class:"v-slide-group__content",onFocusin:Xe,onFocusout:ie,onKeydown:Tt},[l.default?.(nn.value)])]),tn.value&&createVNode("div",{key:"next",class:["v-slide-group__next",{"v-slide-group__next--disabled":!_n.value}],onMousedown:mt,onClick:()=>_n.value&&It("next")},[l.next?.(nn.value)??createVNode(VFadeTransition,null,{default:()=>[createVNode(VIcon,{icon:n.value?t.prevIcon:t.nextIcon},null)]})])]})),{selected:y.selected,scrollTo:It,scrollOffset:m,focus:kt,hasPrev:pn,hasNext:_n}}}),VChipGroupSymbol=Symbol.for("vuetify:v-chip-group"),makeVChipGroupProps=propsFactory$1({column:Boolean,filter:Boolean,valueComparator:{type:Function,default:deepEqual},...makeVSlideGroupProps(),...makeComponentProps(),...makeGroupProps({selectedClass:"v-chip--selected"}),...makeTagProps(),...makeThemeProps(),...makeVariantProps({variant:"tonal"})},"VChipGroup"),VChipGroup=genericComponent()({name:"VChipGroup",props:makeVChipGroupProps(),emits:{"update:modelValue":t=>!0},setup(t,e){let{slots:l}=e;const{themeClasses:n}=provideTheme(t),{isSelected:u,select:c,next:y,prev:b,selected:m}=useGroup(t,VChipGroupSymbol);return provideDefaults({VChip:{color:toRef(t,"color"),disabled:toRef(t,"disabled"),filter:toRef(t,"filter"),variant:toRef(t,"variant")}}),useRender(()=>{const O=VSlideGroup.filterProps(t);return createVNode(VSlideGroup,mergeProps(O,{class:["v-chip-group",{"v-chip-group--column":t.column},n.value,t.class],style:t.style}),{default:()=>[l.default?.({isSelected:u,select:c,next:y,prev:b,selected:m.value})]})}),{}}}),makeVChipProps=propsFactory$1({activeClass:String,appendAvatar:String,appendIcon:IconValue$1,closable:Boolean,closeIcon:{type:IconValue$1,default:"$delete"},closeLabel:{type:String,default:"$vuetify.close"},draggable:Boolean,filter:Boolean,filterIcon:{type:String,default:"$complete"},label:Boolean,link:{type:Boolean,default:void 0},pill:Boolean,prependAvatar:String,prependIcon:IconValue$1,ripple:{type:[Boolean,Object],default:!0},text:String,modelValue:{type:Boolean,default:!0},onClick:EventProp(),onClickOnce:EventProp(),...makeBorderProps(),...makeComponentProps(),...makeDensityProps(),...makeElevationProps(),...makeGroupItemProps(),...makeRoundedProps(),...makeRouterProps(),...makeSizeProps(),...makeTagProps({tag:"span"}),...makeThemeProps(),...makeVariantProps({variant:"tonal"})},"VChip"),VChip=genericComponent()({name:"VChip",directives:{Ripple},props:makeVChipProps(),emits:{"click:close":t=>!0,"update:modelValue":t=>!0,"group:selected":t=>!0,click:t=>!0},setup(t,e){let{attrs:l,emit:n,slots:u}=e;const{t:c}=useLocale(),{borderClasses:y}=useBorder(t),{colorClasses:b,colorStyles:m,variantClasses:O}=useVariant(t),{densityClasses:N}=useDensity(t),{elevationClasses:L}=useElevation(t),{roundedClasses:G}=useRounded(t),{sizeClasses:q}=useSize(t),{themeClasses:J}=provideTheme(t),fe=useProxiedModel(t,"modelValue"),ve=useGroupItem(t,VChipGroupSymbol,!1),ne=useLink(t,l),Ue=computed(()=>t.link!==!1&&ne.isLink.value),De=computed(()=>!t.disabled&&t.link!==!1&&(!!ve||t.link||ne.isClickable.value)),Ve=computed(()=>({"aria-label":c(t.closeLabel),onClick(Te){Te.preventDefault(),Te.stopPropagation(),fe.value=!1,n("click:close",Te)}}));function rt(Te){n("click",Te),De.value&&(ne.navigate?.(Te),ve?.toggle())}function Ae(Te){(Te.key==="Enter"||Te.key===" ")&&(Te.preventDefault(),rt(Te))}return()=>{const Te=ne.isLink.value?"a":t.tag,Xe=!!(t.appendIcon||t.appendAvatar),ie=!!(Xe||u.append),ue=!!(u.close||t.closable),pt=!!(u.filter||t.filter)&&ve,mt=!!(t.prependIcon||t.prependAvatar),Tt=!!(mt||u.prepend),kt=!ve||ve.isSelected.value;return fe.value&&withDirectives(createVNode(Te,mergeProps({class:["v-chip",{"v-chip--disabled":t.disabled,"v-chip--label":t.label,"v-chip--link":De.value,"v-chip--filter":pt,"v-chip--pill":t.pill},J.value,y.value,kt?b.value:void 0,N.value,L.value,G.value,q.value,O.value,ve?.selectedClass.value,t.class],style:[kt?m.value:void 0,t.style],disabled:t.disabled||void 0,draggable:t.draggable,tabindex:De.value?0:void 0,onClick:rt,onKeydown:De.value&&!Ue.value&&Ae},ne.linkProps),{default:()=>[genOverlays(De.value,"v-chip"),pt&&createVNode(VExpandXTransition,{key:"filter"},{default:()=>[withDirectives(createVNode("div",{class:"v-chip__filter"},[u.filter?createVNode(VDefaultsProvider,{key:"filter-defaults",disabled:!t.filterIcon,defaults:{VIcon:{icon:t.filterIcon}}},u.filter):createVNode(VIcon,{key:"filter-icon",icon:t.filterIcon},null)]),[[vShow,ve.isSelected.value]])]}),Tt&&createVNode("div",{key:"prepend",class:"v-chip__prepend"},[u.prepend?createVNode(VDefaultsProvider,{key:"prepend-defaults",disabled:!mt,defaults:{VAvatar:{image:t.prependAvatar,start:!0},VIcon:{icon:t.prependIcon,start:!0}}},u.prepend):createVNode(Fragment,null,[t.prependIcon&&createVNode(VIcon,{key:"prepend-icon",icon:t.prependIcon,start:!0},null),t.prependAvatar&&createVNode(VAvatar,{key:"prepend-avatar",image:t.prependAvatar,start:!0},null)])]),createVNode("div",{class:"v-chip__content","data-no-activator":""},[u.default?.({isSelected:ve?.isSelected.value,selectedClass:ve?.selectedClass.value,select:ve?.select,toggle:ve?.toggle,value:ve?.value.value,disabled:t.disabled})??t.text]),ie&&createVNode("div",{key:"append",class:"v-chip__append"},[u.append?createVNode(VDefaultsProvider,{key:"append-defaults",disabled:!Xe,defaults:{VAvatar:{end:!0,image:t.appendAvatar},VIcon:{end:!0,icon:t.appendIcon}}},u.append):createVNode(Fragment,null,[t.appendIcon&&createVNode(VIcon,{key:"append-icon",end:!0,icon:t.appendIcon},null),t.appendAvatar&&createVNode(VAvatar,{key:"append-avatar",end:!0,image:t.appendAvatar},null)])]),ue&&createVNode("button",mergeProps({key:"close",class:"v-chip__close",type:"button"},Ve.value),[u.close?createVNode(VDefaultsProvider,{key:"close-defaults",defaults:{VIcon:{icon:t.closeIcon,size:"x-small"}}},u.close):createVNode(VIcon,{key:"close-icon",icon:t.closeIcon,size:"x-small"},null)])]}),[[resolveDirective("ripple"),De.value&&t.ripple,null]])}}});function elementToViewport(t,e){return{x:t.x+e.x,y:t.y+e.y}}function getOffset(t,e){return{x:t.x-e.x,y:t.y-e.y}}function anchorToPoint(t,e){if(t.side==="top"||t.side==="bottom"){const{side:l,align:n}=t,u=n==="left"?0:n==="center"?e.width/2:n==="right"?e.width:n,c=l==="top"?0:l==="bottom"?e.height:l;return elementToViewport({x:u,y:c},e)}else if(t.side==="left"||t.side==="right"){const{side:l,align:n}=t,u=l==="left"?0:l==="right"?e.width:l,c=n==="top"?0:n==="center"?e.height/2:n==="bottom"?e.height:n;return elementToViewport({x:u,y:c},e)}return elementToViewport({x:e.width/2,y:e.height/2},e)}const locationStrategies={static:staticLocationStrategy,connected:connectedLocationStrategy},makeLocationStrategyProps=propsFactory$1({locationStrategy:{type:[String,Function],default:"static",validator:t=>typeof t=="function"||t in locationStrategies},location:{type:String,default:"bottom"},origin:{type:String,default:"auto"},offset:[Number,String,Array]},"VOverlay-location-strategies");function useLocationStrategies(t,e){const l=ref({}),n=ref();IN_BROWSER&&useToggleScope(()=>!!(e.isActive.value&&t.locationStrategy),c=>{watch(()=>t.locationStrategy,c),onScopeDispose(()=>{window.removeEventListener("resize",u),n.value=void 0}),window.addEventListener("resize",u,{passive:!0}),typeof t.locationStrategy=="function"?n.value=t.locationStrategy(e,t,l)?.updateLocation:n.value=locationStrategies[t.locationStrategy](e,t,l)?.updateLocation});function u(c){n.value?.(c)}return{contentStyles:l,updateLocation:n}}function staticLocationStrategy(){}function getIntrinsicSize(t,e){const l=nullifyTransforms(t);return e?l.x+=parseFloat(t.style.right||0):l.x-=parseFloat(t.style.left||0),l.y-=parseFloat(t.style.top||0),l}function connectedLocationStrategy(t,e,l){(Array.isArray(t.target.value)||isFixedPosition(t.target.value))&&Object.assign(l.value,{position:"fixed",top:0,[t.isRtl.value?"right":"left"]:0});const{preferredAnchor:u,preferredOrigin:c}=destructComputed(()=>{const J=parseAnchor(e.location,t.isRtl.value),fe=e.origin==="overlap"?J:e.origin==="auto"?flipSide(J):parseAnchor(e.origin,t.isRtl.value);return J.side===fe.side&&J.align===flipAlign(fe).align?{preferredAnchor:flipCorner(J),preferredOrigin:flipCorner(fe)}:{preferredAnchor:J,preferredOrigin:fe}}),[y,b,m,O]=["minWidth","minHeight","maxWidth","maxHeight"].map(J=>computed(()=>{const fe=parseFloat(e[J]);return isNaN(fe)?1/0:fe})),N=computed(()=>{if(Array.isArray(e.offset))return e.offset;if(typeof e.offset=="string"){const J=e.offset.split(" ").map(parseFloat);return J.length<2&&J.push(0),J}return typeof e.offset=="number"?[e.offset,0]:[0,0]});let L=!1;const G=new ResizeObserver(()=>{L&&q()});watch([t.target,t.contentEl],(J,fe)=>{let[ve,ne]=J,[Ue,De]=fe;Ue&&!Array.isArray(Ue)&&G.unobserve(Ue),ve&&!Array.isArray(ve)&&G.observe(ve),De&&G.unobserve(De),ne&&G.observe(ne)},{immediate:!0}),onScopeDispose(()=>{G.disconnect()});function q(){if(L=!1,requestAnimationFrame(()=>L=!0),!t.target.value||!t.contentEl.value)return;const J=getTargetBox(t.target.value),fe=getIntrinsicSize(t.contentEl.value,t.isRtl.value),ve=getScrollParents(t.contentEl.value),ne=12;ve.length||(ve.push(document.documentElement),t.contentEl.value.style.top&&t.contentEl.value.style.left||(fe.x-=parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-x")||0),fe.y-=parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-y")||0)));const Ue=ve.reduce((pt,mt)=>{const Tt=mt.getBoundingClientRect(),kt=new Box({x:mt===document.documentElement?0:Tt.x,y:mt===document.documentElement?0:Tt.y,width:mt.clientWidth,height:mt.clientHeight});return pt?new Box({x:Math.max(pt.left,kt.left),y:Math.max(pt.top,kt.top),width:Math.min(pt.right,kt.right)-Math.max(pt.left,kt.left),height:Math.min(pt.bottom,kt.bottom)-Math.max(pt.top,kt.top)}):kt},void 0);Ue.x+=ne,Ue.y+=ne,Ue.width-=ne*2,Ue.height-=ne*2;let De={anchor:u.value,origin:c.value};function Ve(pt){const mt=new Box(fe),Tt=anchorToPoint(pt.anchor,J),kt=anchorToPoint(pt.origin,mt);let{x:It,y:nn}=getOffset(Tt,kt);switch(pt.anchor.side){case"top":nn-=N.value[0];break;case"bottom":nn+=N.value[0];break;case"left":It-=N.value[0];break;case"right":It+=N.value[0];break}switch(pt.anchor.align){case"top":nn-=N.value[1];break;case"bottom":nn+=N.value[1];break;case"left":It-=N.value[1];break;case"right":It+=N.value[1];break}return mt.x+=It,mt.y+=nn,mt.width=Math.min(mt.width,m.value),mt.height=Math.min(mt.height,O.value),{overflows:getOverflow(mt,Ue),x:It,y:nn}}let rt=0,Ae=0;const Te={x:0,y:0},Xe={x:!1,y:!1};let ie=-1;for(;!(ie++>10);){const{x:pt,y:mt,overflows:Tt}=Ve(De);rt+=pt,Ae+=mt,fe.x+=pt,fe.y+=mt;{const kt=getAxis(De.anchor),It=Tt.x.before||Tt.x.after,nn=Tt.y.before||Tt.y.after;let tn=!1;if(["x","y"].forEach(pn=>{if(pn==="x"&&It&&!Xe.x||pn==="y"&&nn&&!Xe.y){const _n={anchor:{...De.anchor},origin:{...De.origin}},Dn=pn==="x"?kt==="y"?flipAlign:flipSide:kt==="y"?flipSide:flipAlign;_n.anchor=Dn(_n.anchor),_n.origin=Dn(_n.origin);const{overflows:an}=Ve(_n);(an[pn].before<=Tt[pn].before&&an[pn].after<=Tt[pn].after||an[pn].before+an[pn].after<(Tt[pn].before+Tt[pn].after)/2)&&(De=_n,tn=Xe[pn]=!0)}}),tn)continue}Tt.x.before&&(rt+=Tt.x.before,fe.x+=Tt.x.before),Tt.x.after&&(rt-=Tt.x.after,fe.x-=Tt.x.after),Tt.y.before&&(Ae+=Tt.y.before,fe.y+=Tt.y.before),Tt.y.after&&(Ae-=Tt.y.after,fe.y-=Tt.y.after);{const kt=getOverflow(fe,Ue);Te.x=Ue.width-kt.x.before-kt.x.after,Te.y=Ue.height-kt.y.before-kt.y.after,rt+=kt.x.before,fe.x+=kt.x.before,Ae+=kt.y.before,fe.y+=kt.y.before}break}const ue=getAxis(De.anchor);return Object.assign(l.value,{"--v-overlay-anchor-origin":`${De.anchor.side} ${De.anchor.align}`,transformOrigin:`${De.origin.side} ${De.origin.align}`,top:convertToUnit(pixelRound(Ae)),left:t.isRtl.value?void 0:convertToUnit(pixelRound(rt)),right:t.isRtl.value?convertToUnit(pixelRound(-rt)):void 0,minWidth:convertToUnit(ue==="y"?Math.min(y.value,J.width):y.value),maxWidth:convertToUnit(pixelCeil(clamp(Te.x,y.value===1/0?0:y.value,m.value))),maxHeight:convertToUnit(pixelCeil(clamp(Te.y,b.value===1/0?0:b.value,O.value)))}),{available:Te,contentBox:fe}}return watch(()=>[u.value,c.value,e.offset,e.minWidth,e.minHeight,e.maxWidth,e.maxHeight],()=>q()),nextTick(()=>{const J=q();if(!J)return;const{available:fe,contentBox:ve}=J;ve.height>fe.y&&requestAnimationFrame(()=>{q(),requestAnimationFrame(()=>{q()})})}),{updateLocation:q}}function pixelRound(t){return Math.round(t*devicePixelRatio)/devicePixelRatio}function pixelCeil(t){return Math.ceil(t*devicePixelRatio)/devicePixelRatio}let clean=!0;const frames=[];function requestNewFrame(t){!clean||frames.length?(frames.push(t),run()):(clean=!1,t(),run())}let raf=-1;function run(){cancelAnimationFrame(raf),raf=requestAnimationFrame(()=>{const t=frames.shift();t&&t(),frames.length?run():clean=!0})}const scrollStrategies={none:null,close:closeScrollStrategy,block:blockScrollStrategy,reposition:repositionScrollStrategy},makeScrollStrategyProps=propsFactory$1({scrollStrategy:{type:[String,Function],default:"block",validator:t=>typeof t=="function"||t in scrollStrategies}},"VOverlay-scroll-strategies");function useScrollStrategies(t,e){if(!IN_BROWSER)return;let l;watchEffect(async()=>{l?.stop(),e.isActive.value&&t.scrollStrategy&&(l=effectScope(),await new Promise(n=>setTimeout(n)),l.active&&l.run(()=>{typeof t.scrollStrategy=="function"?t.scrollStrategy(e,t,l):scrollStrategies[t.scrollStrategy]?.(e,t,l)}))}),onScopeDispose(()=>{l?.stop()})}function closeScrollStrategy(t){function e(l){t.isActive.value=!1}bindScroll(t.targetEl.value??t.contentEl.value,e)}function blockScrollStrategy(t,e){const l=t.root.value?.offsetParent,n=[...new Set([...getScrollParents(t.targetEl.value,e.contained?l:void 0),...getScrollParents(t.contentEl.value,e.contained?l:void 0)])].filter(y=>!y.classList.contains("v-overlay-scroll-blocked")),u=window.innerWidth-document.documentElement.offsetWidth,c=(y=>hasScrollbar(y)&&y)(l||document.documentElement);c&&t.root.value.classList.add("v-overlay--scroll-blocked"),n.forEach((y,b)=>{y.style.setProperty("--v-body-scroll-x",convertToUnit(-y.scrollLeft)),y.style.setProperty("--v-body-scroll-y",convertToUnit(-y.scrollTop)),y!==document.documentElement&&y.style.setProperty("--v-scrollbar-offset",convertToUnit(u)),y.classList.add("v-overlay-scroll-blocked")}),onScopeDispose(()=>{n.forEach((y,b)=>{const m=parseFloat(y.style.getPropertyValue("--v-body-scroll-x")),O=parseFloat(y.style.getPropertyValue("--v-body-scroll-y")),N=y.style.scrollBehavior;y.style.scrollBehavior="auto",y.style.removeProperty("--v-body-scroll-x"),y.style.removeProperty("--v-body-scroll-y"),y.style.removeProperty("--v-scrollbar-offset"),y.classList.remove("v-overlay-scroll-blocked"),y.scrollLeft=-m,y.scrollTop=-O,y.style.scrollBehavior=N}),c&&t.root.value.classList.remove("v-overlay--scroll-blocked")})}function repositionScrollStrategy(t,e,l){let n=!1,u=-1,c=-1;function y(b){requestNewFrame(()=>{const m=performance.now();t.updateLocation.value?.(b),n=(performance.now()-m)/(1e3/60)>2})}c=(typeof requestIdleCallback>"u"?b=>b():requestIdleCallback)(()=>{l.run(()=>{bindScroll(t.targetEl.value??t.contentEl.value,b=>{n?(cancelAnimationFrame(u),u=requestAnimationFrame(()=>{u=requestAnimationFrame(()=>{y(b)})})):y(b)})})}),onScopeDispose(()=>{typeof cancelIdleCallback<"u"&&cancelIdleCallback(c),cancelAnimationFrame(u)})}function bindScroll(t,e){const l=[document,...getScrollParents(t)];l.forEach(n=>{n.addEventListener("scroll",e,{passive:!0})}),onScopeDispose(()=>{l.forEach(n=>{n.removeEventListener("scroll",e)})})}const VMenuSymbol=Symbol.for("vuetify:v-menu"),makeDelayProps=propsFactory$1({closeDelay:[Number,String],openDelay:[Number,String]},"delay");function useDelay(t,e){let l=()=>{};function n(y){l?.();const b=Number(y?t.openDelay:t.closeDelay);return new Promise(m=>{l=defer(b,()=>{e?.(y),m(y)})})}function u(){return n(!0)}function c(){return n(!1)}return{clearDelay:l,runOpenDelay:u,runCloseDelay:c}}const makeActivatorProps=propsFactory$1({target:[String,Object],activator:[String,Object],activatorProps:{type:Object,default:()=>({})},openOnClick:{type:Boolean,default:void 0},openOnHover:Boolean,openOnFocus:{type:Boolean,default:void 0},closeOnContentClick:Boolean,...makeDelayProps()},"VOverlay-activator");function useActivator(t,e){let{isActive:l,isTop:n,contentEl:u}=e;const c=getCurrentInstance("useActivator"),y=ref();let b=!1,m=!1,O=!0;const N=computed(()=>t.openOnFocus||t.openOnFocus==null&&t.openOnHover),L=computed(()=>t.openOnClick||t.openOnClick==null&&!t.openOnHover&&!N.value),{runOpenDelay:G,runCloseDelay:q}=useDelay(t,Xe=>{Xe===(t.openOnHover&&b||N.value&&m)&&!(t.openOnHover&&l.value&&!n.value)&&(l.value!==Xe&&(O=!0),l.value=Xe)}),J=ref(),fe={onClick:Xe=>{Xe.stopPropagation(),y.value=Xe.currentTarget||Xe.target,l.value||(J.value=[Xe.clientX,Xe.clientY]),l.value=!l.value},onMouseenter:Xe=>{Xe.sourceCapabilities?.firesTouchEvents||(b=!0,y.value=Xe.currentTarget||Xe.target,G())},onMouseleave:Xe=>{b=!1,q()},onFocus:Xe=>{matchesSelector(Xe.target,":focus-visible")!==!1&&(m=!0,Xe.stopPropagation(),y.value=Xe.currentTarget||Xe.target,G())},onBlur:Xe=>{m=!1,Xe.stopPropagation(),q()}},ve=computed(()=>{const Xe={};return L.value&&(Xe.onClick=fe.onClick),t.openOnHover&&(Xe.onMouseenter=fe.onMouseenter,Xe.onMouseleave=fe.onMouseleave),N.value&&(Xe.onFocus=fe.onFocus,Xe.onBlur=fe.onBlur),Xe}),ne=computed(()=>{const Xe={};if(t.openOnHover&&(Xe.onMouseenter=()=>{b=!0,G()},Xe.onMouseleave=()=>{b=!1,q()}),N.value&&(Xe.onFocusin=()=>{m=!0,G()},Xe.onFocusout=()=>{m=!1,q()}),t.closeOnContentClick){const ie=inject$1(VMenuSymbol,null);Xe.onClick=()=>{l.value=!1,ie?.closeParents()}}return Xe}),Ue=computed(()=>{const Xe={};return t.openOnHover&&(Xe.onMouseenter=()=>{O&&(b=!0,O=!1,G())},Xe.onMouseleave=()=>{b=!1,q()}),Xe});watch(n,Xe=>{Xe&&(t.openOnHover&&!b&&(!N.value||!m)||N.value&&!m&&(!t.openOnHover||!b))&&!u.value?.contains(document.activeElement)&&(l.value=!1)}),watch(l,Xe=>{Xe||setTimeout(()=>{J.value=void 0})},{flush:"post"});const De=templateRef();watchEffect(()=>{De.value&&nextTick(()=>{y.value=De.el})});const Ve=templateRef(),rt=computed(()=>t.target==="cursor"&&J.value?J.value:Ve.value?Ve.el:getTarget(t.target,c)||y.value),Ae=computed(()=>Array.isArray(rt.value)?void 0:rt.value);let Te;return watch(()=>!!t.activator,Xe=>{Xe&&IN_BROWSER?(Te=effectScope(),Te.run(()=>{_useActivator(t,c,{activatorEl:y,activatorEvents:ve})})):Te&&Te.stop()},{flush:"post",immediate:!0}),onScopeDispose(()=>{Te?.stop()}),{activatorEl:y,activatorRef:De,target:rt,targetEl:Ae,targetRef:Ve,activatorEvents:ve,contentEvents:ne,scrimEvents:Ue}}function _useActivator(t,e,l){let{activatorEl:n,activatorEvents:u}=l;watch(()=>t.activator,(m,O)=>{if(O&&m!==O){const N=b(O);N&&y(N)}m&&nextTick(()=>c())},{immediate:!0}),watch(()=>t.activatorProps,()=>{c()}),onScopeDispose(()=>{y()});function c(){let m=arguments.length>0&&arguments[0]!==void 0?arguments[0]:b(),O=arguments.length>1&&arguments[1]!==void 0?arguments[1]:t.activatorProps;m&&bindProps(m,mergeProps(u.value,O))}function y(){let m=arguments.length>0&&arguments[0]!==void 0?arguments[0]:b(),O=arguments.length>1&&arguments[1]!==void 0?arguments[1]:t.activatorProps;m&&unbindProps(m,mergeProps(u.value,O))}function b(){let m=arguments.length>0&&arguments[0]!==void 0?arguments[0]:t.activator;const O=getTarget(m,e);return n.value=O?.nodeType===Node.ELEMENT_NODE?O:void 0,n.value}}function getTarget(t,e){if(!t)return;let l;if(t==="parent"){let n=e?.proxy?.$el?.parentNode;for(;n?.hasAttribute("data-no-activator");)n=n.parentNode;l=n}else typeof t=="string"?l=document.querySelector(t):"$el"in t?l=t.$el:l=t;return l}function useHydration(){if(!IN_BROWSER)return shallowRef(!1);const{ssr:t}=useDisplay();if(t){const e=shallowRef(!1);return onMounted(()=>{e.value=!0}),e}else return shallowRef(!0)}const makeLazyProps=propsFactory$1({eager:Boolean},"lazy");function useLazy(t,e){const l=shallowRef(!1),n=computed(()=>l.value||t.eager||e.value);watch(e,()=>l.value=!0);function u(){t.eager||(l.value=!1)}return{isBooted:l,hasContent:n,onAfterLeave:u}}function useScopeId(){const e=getCurrentInstance("useScopeId").vnode.scopeId;return{scopeId:e?{[e]:""}:void 0}}const StackSymbol=Symbol.for("vuetify:stack"),globalStack=reactive([]);function useStack$1(t,e,l){const n=getCurrentInstance("useStack"),u=!l,c=inject$1(StackSymbol,void 0),y=reactive({activeChildren:new Set});provide(StackSymbol,y);const b=shallowRef(+e.value);useToggleScope(t,()=>{const N=globalStack.at(-1)?.[1];b.value=N?N+10:+e.value,u&&globalStack.push([n.uid,b.value]),c?.activeChildren.add(n.uid),onScopeDispose(()=>{if(u){const L=toRaw(globalStack).findIndex(G=>G[0]===n.uid);globalStack.splice(L,1)}c?.activeChildren.delete(n.uid)})});const m=shallowRef(!0);u&&watchEffect(()=>{const N=globalStack.at(-1)?.[0]===n.uid;setTimeout(()=>m.value=N)});const O=computed(()=>!y.activeChildren.size);return{globalTop:readonly(m),localTop:O,stackStyles:computed(()=>({zIndex:b.value}))}}function useTeleport(t){return{teleportTarget:computed(()=>{const l=t();if(l===!0||!IN_BROWSER)return;const n=l===!1?document.body:typeof l=="string"?document.querySelector(l):l;if(n==null)return;let u=[...n.children].find(c=>c.matches(".v-overlay-container"));return u||(u=document.createElement("div"),u.className="v-overlay-container",n.appendChild(u)),u})}}function defaultConditional(){return!0}function checkEvent(t,e,l){if(!t||checkIsActive(t,l)===!1)return!1;const n=attachedRoot(e);if(typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&n.host===t.target)return!1;const u=(typeof l.value=="object"&&l.value.include||(()=>[]))();return u.push(e),!u.some(c=>c?.contains(t.target))}function checkIsActive(t,e){return(typeof e.value=="object"&&e.value.closeConditional||defaultConditional)(t)}function directive(t,e,l){const n=typeof l.value=="function"?l.value:l.value.handler;t.shadowTarget=t.target,e._clickOutside.lastMousedownWasOutside&&checkEvent(t,e,l)&&setTimeout(()=>{checkIsActive(t,l)&&n&&n(t)},0)}function handleShadow(t,e){const l=attachedRoot(t);e(document),typeof ShadowRoot<"u"&&l instanceof ShadowRoot&&e(l)}const ClickOutside={mounted(t,e){const l=u=>directive(u,t,e),n=u=>{t._clickOutside.lastMousedownWasOutside=checkEvent(u,t,e)};handleShadow(t,u=>{u.addEventListener("click",l,!0),u.addEventListener("mousedown",n,!0)}),t._clickOutside||(t._clickOutside={lastMousedownWasOutside:!1}),t._clickOutside[e.instance.$.uid]={onClick:l,onMousedown:n}},beforeUnmount(t,e){t._clickOutside&&(handleShadow(t,l=>{if(!l||!t._clickOutside?.[e.instance.$.uid])return;const{onClick:n,onMousedown:u}=t._clickOutside[e.instance.$.uid];l.removeEventListener("click",n,!0),l.removeEventListener("mousedown",u,!0)}),delete t._clickOutside[e.instance.$.uid])}};function Scrim(t){const{modelValue:e,color:l,...n}=t;return createVNode(Transition,{name:"fade-transition",appear:!0},{default:()=>[t.modelValue&&createVNode("div",mergeProps({class:["v-overlay__scrim",t.color.backgroundColorClasses.value],style:t.color.backgroundColorStyles.value},n),null)]})}const makeVOverlayProps=propsFactory$1({absolute:Boolean,attach:[Boolean,String,Object],closeOnBack:{type:Boolean,default:!0},contained:Boolean,contentClass:null,contentProps:null,disabled:Boolean,opacity:[Number,String],noClickAnimation:Boolean,modelValue:Boolean,persistent:Boolean,scrim:{type:[Boolean,String],default:!0},zIndex:{type:[Number,String],default:2e3},...makeActivatorProps(),...makeComponentProps(),...makeDimensionProps(),...makeLazyProps(),...makeLocationStrategyProps(),...makeScrollStrategyProps(),...makeThemeProps(),...makeTransitionProps()},"VOverlay"),VOverlay=genericComponent()({name:"VOverlay",directives:{ClickOutside},inheritAttrs:!1,props:{_disableGlobalStack:Boolean,...makeVOverlayProps()},emits:{"click:outside":t=>!0,"update:modelValue":t=>!0,afterEnter:()=>!0,afterLeave:()=>!0},setup(t,e){let{slots:l,attrs:n,emit:u}=e;const c=getCurrentInstance("VOverlay"),y=ref(),b=ref(),m=ref(),O=useProxiedModel(t,"modelValue"),N=computed({get:()=>O.value,set:xn=>{xn&&t.disabled||(O.value=xn)}}),{themeClasses:L}=provideTheme(t),{rtlClasses:G,isRtl:q}=useRtl(),{hasContent:J,onAfterLeave:fe}=useLazy(t,N),ve=useBackgroundColor(computed(()=>typeof t.scrim=="string"?t.scrim:null)),{globalTop:ne,localTop:Ue,stackStyles:De}=useStack$1(N,toRef(t,"zIndex"),t._disableGlobalStack),{activatorEl:Ve,activatorRef:rt,target:Ae,targetEl:Te,targetRef:Xe,activatorEvents:ie,contentEvents:ue,scrimEvents:pt}=useActivator(t,{isActive:N,isTop:Ue,contentEl:m}),{teleportTarget:mt}=useTeleport(()=>{const xn=t.attach||t.contained;if(xn)return xn;const $n=Ve?.value?.getRootNode()||c.proxy?.$el?.getRootNode();return $n instanceof ShadowRoot?$n:!1}),{dimensionStyles:Tt}=useDimension(t),kt=useHydration(),{scopeId:It}=useScopeId();watch(()=>t.disabled,xn=>{xn&&(N.value=!1)});const{contentStyles:nn,updateLocation:tn}=useLocationStrategies(t,{isRtl:q,contentEl:m,target:Ae,isActive:N});useScrollStrategies(t,{root:y,contentEl:m,targetEl:Te,isActive:N,updateLocation:tn});function pn(xn){u("click:outside",xn),t.persistent?Lt():N.value=!1}function _n(xn){return N.value&&ne.value&&(!t.scrim||xn.target===b.value||xn instanceof MouseEvent&&xn.shadowTarget===b.value)}IN_BROWSER&&watch(N,xn=>{xn?window.addEventListener("keydown",Dn):window.removeEventListener("keydown",Dn)},{immediate:!0}),onBeforeUnmount(()=>{IN_BROWSER&&window.removeEventListener("keydown",Dn)});function Dn(xn){xn.key==="Escape"&&ne.value&&(t.persistent?Lt():(N.value=!1,m.value?.contains(document.activeElement)&&Ve.value?.focus()))}const an=useRouter();useToggleScope(()=>t.closeOnBack,()=>{useBackButton(an,xn=>{ne.value&&N.value?(xn(!1),t.persistent?Lt():N.value=!1):xn()})});const Rn=ref();watch(()=>N.value&&(t.absolute||t.contained)&&mt.value==null,xn=>{if(xn){const $n=getScrollParent(y.value);$n&&$n!==document.scrollingElement&&(Rn.value=$n.scrollTop)}});function Lt(){t.noClickAnimation||m.value&&animate(m.value,[{transformOrigin:"center"},{transform:"scale(1.03)"},{transformOrigin:"center"}],{duration:150,easing:standardEasing})}function wn(){u("afterEnter")}function hn(){fe(),u("afterLeave")}return useRender(()=>createVNode(Fragment,null,[l.activator?.({isActive:N.value,targetRef:Xe,props:mergeProps({ref:rt},ie.value,t.activatorProps)}),kt.value&&J.value&&createVNode(Teleport,{disabled:!mt.value,to:mt.value},{default:()=>[createVNode("div",mergeProps({class:["v-overlay",{"v-overlay--absolute":t.absolute||t.contained,"v-overlay--active":N.value,"v-overlay--contained":t.contained},L.value,G.value,t.class],style:[De.value,{"--v-overlay-opacity":t.opacity,top:convertToUnit(Rn.value)},t.style],ref:y},It,n),[createVNode(Scrim,mergeProps({color:ve,modelValue:N.value&&!!t.scrim,ref:b},pt.value),null),createVNode(MaybeTransition,{appear:!0,persisted:!0,transition:t.transition,target:Ae.value,onAfterEnter:wn,onAfterLeave:hn},{default:()=>[withDirectives(createVNode("div",mergeProps({ref:m,class:["v-overlay__content",t.contentClass],style:[Tt.value,nn.value]},ue.value,t.contentProps),[l.default?.({isActive:N})]),[[vShow,N.value],[resolveDirective("click-outside"),{handler:pn,closeConditional:_n,include:()=>[Ve.value]}]])]})])]})])),{activatorEl:Ve,scrimEl:b,target:Ae,animateClick:Lt,contentEl:m,globalTop:ne,localTop:Ue,updateLocation:tn}}}),Refs=Symbol("Forwarded refs");function getDescriptor(t,e){let l=t;for(;l;){const n=Reflect.getOwnPropertyDescriptor(l,e);if(n)return n;l=Object.getPrototypeOf(l)}}function forwardRefs(t){for(var e=arguments.length,l=new Array(e>1?e-1:0),n=1;n<e;n++)l[n-1]=arguments[n];return t[Refs]=l,new Proxy(t,{get(u,c){if(Reflect.has(u,c))return Reflect.get(u,c);if(!(typeof c=="symbol"||c.startsWith("$")||c.startsWith("__"))){for(const y of l)if(y.value&&Reflect.has(y.value,c)){const b=Reflect.get(y.value,c);return typeof b=="function"?b.bind(y.value):b}}},has(u,c){if(Reflect.has(u,c))return!0;if(typeof c=="symbol"||c.startsWith("$")||c.startsWith("__"))return!1;for(const y of l)if(y.value&&Reflect.has(y.value,c))return!0;return!1},set(u,c,y){if(Reflect.has(u,c))return Reflect.set(u,c,y);if(typeof c=="symbol"||c.startsWith("$")||c.startsWith("__"))return!1;for(const b of l)if(b.value&&Reflect.has(b.value,c))return Reflect.set(b.value,c,y);return!1},getOwnPropertyDescriptor(u,c){const y=Reflect.getOwnPropertyDescriptor(u,c);if(y)return y;if(!(typeof c=="symbol"||c.startsWith("$")||c.startsWith("__"))){for(const b of l){if(!b.value)continue;const m=getDescriptor(b.value,c)??("_"in b.value?getDescriptor(b.value._?.setupState,c):void 0);if(m)return m}for(const b of l){const m=b.value&&b.value[Refs];if(!m)continue;const O=m.slice();for(;O.length;){const N=O.shift(),L=getDescriptor(N.value,c);if(L)return L;const G=N.value&&N.value[Refs];G&&O.push(...G)}}}}})}const makeVMenuProps=propsFactory$1({id:String,submenu:Boolean,...omit(makeVOverlayProps({closeDelay:250,closeOnContentClick:!0,locationStrategy:"connected",location:void 0,openDelay:300,scrim:!1,scrollStrategy:"reposition",transition:{component:VDialogTransition}}),["absolute"])},"VMenu"),VMenu=genericComponent()({name:"VMenu",props:makeVMenuProps(),emits:{"update:modelValue":t=>!0},setup(t,e){let{slots:l}=e;const n=useProxiedModel(t,"modelValue"),{scopeId:u}=useScopeId(),{isRtl:c}=useRtl(),y=getUid(),b=computed(()=>t.id||`v-menu-${y}`),m=ref(),O=inject$1(VMenuSymbol,null),N=shallowRef(new Set);provide(VMenuSymbol,{register(){N.value.add(y)},unregister(){N.value.delete(y)},closeParents(ve){setTimeout(()=>{!N.value.size&&!t.persistent&&(ve==null||m.value?.contentEl&&!isClickInsideElement(ve,m.value.contentEl))&&(n.value=!1,O?.closeParents())},40)}}),onBeforeUnmount(()=>O?.unregister()),onDeactivated(()=>n.value=!1);async function L(ve){const ne=ve.relatedTarget,Ue=ve.target;await nextTick(),n.value&&ne!==Ue&&m.value?.contentEl&&m.value?.globalTop&&![document,m.value.contentEl].includes(Ue)&&!m.value.contentEl.contains(Ue)&&focusableChildren(m.value.contentEl)[0]?.focus()}watch(n,ve=>{ve?(O?.register(),document.addEventListener("focusin",L,{once:!0})):(O?.unregister(),document.removeEventListener("focusin",L))});function G(ve){O?.closeParents(ve)}function q(ve){if(!t.disabled)if(ve.key==="Tab"||ve.key==="Enter"&&!t.closeOnContentClick){if(ve.key==="Enter"&&(ve.target instanceof HTMLTextAreaElement||ve.target instanceof HTMLInputElement&&ve.target.closest("form")))return;ve.key==="Enter"&&ve.preventDefault(),getNextElement(focusableChildren(m.value?.contentEl,!1),ve.shiftKey?"prev":"next",Ue=>Ue.tabIndex>=0)||(n.value=!1,m.value?.activatorEl?.focus())}else t.submenu&&ve.key===(c.value?"ArrowRight":"ArrowLeft")&&(n.value=!1,m.value?.activatorEl?.focus())}function J(ve){if(t.disabled)return;const ne=m.value?.contentEl;ne&&n.value?ve.key==="ArrowDown"?(ve.preventDefault(),ve.stopImmediatePropagation(),focusChild(ne,"next")):ve.key==="ArrowUp"?(ve.preventDefault(),ve.stopImmediatePropagation(),focusChild(ne,"prev")):t.submenu&&(ve.key===(c.value?"ArrowRight":"ArrowLeft")?n.value=!1:ve.key===(c.value?"ArrowLeft":"ArrowRight")&&(ve.preventDefault(),focusChild(ne,"first"))):(t.submenu?ve.key===(c.value?"ArrowLeft":"ArrowRight"):["ArrowDown","ArrowUp"].includes(ve.key))&&(n.value=!0,ve.preventDefault(),setTimeout(()=>setTimeout(()=>J(ve))))}const fe=computed(()=>mergeProps({"aria-haspopup":"menu","aria-expanded":String(n.value),"aria-owns":b.value,onKeydown:J},t.activatorProps));return useRender(()=>{const ve=VOverlay.filterProps(t);return createVNode(VOverlay,mergeProps({ref:m,id:b.value,class:["v-menu",t.class],style:t.style},ve,{modelValue:n.value,"onUpdate:modelValue":ne=>n.value=ne,absolute:!0,activatorProps:fe.value,location:t.location??(t.submenu?"end":"bottom"),"onClick:outside":G,onKeydown:q},u),{activator:l.activator,default:function(){for(var ne=arguments.length,Ue=new Array(ne),De=0;De<ne;De++)Ue[De]=arguments[De];return createVNode(VDefaultsProvider,{root:"VMenu"},{default:()=>[l.default?.(...Ue)]})}})}),forwardRefs({id:b,ΨopenChildren:N},m)}}),makeVCounterProps=propsFactory$1({active:Boolean,disabled:Boolean,max:[Number,String],value:{type:[Number,String],default:0},...makeComponentProps(),...makeTransitionProps({transition:{component:VSlideYTransition}})},"VCounter"),VCounter=genericComponent()({name:"VCounter",functional:!0,props:makeVCounterProps(),setup(t,e){let{slots:l}=e;const n=computed(()=>t.max?`${t.value} / ${t.max}`:String(t.value));return useRender(()=>createVNode(MaybeTransition,{transition:t.transition},{default:()=>[withDirectives(createVNode("div",{class:["v-counter",{"text-error":t.max&&!t.disabled&&parseFloat(t.value)>parseFloat(t.max)},t.class],style:t.style},[l.default?l.default({counter:n.value,max:t.max,value:t.value}):n.value]),[[vShow,t.active]])]})),{}}}),makeVFieldLabelProps=propsFactory$1({floating:Boolean,...makeComponentProps()},"VFieldLabel"),VFieldLabel=genericComponent()({name:"VFieldLabel",props:makeVFieldLabelProps(),setup(t,e){let{slots:l}=e;return useRender(()=>createVNode(VLabel,{class:["v-field-label",{"v-field-label--floating":t.floating},t.class],style:t.style,"aria-hidden":t.floating||void 0},l)),{}}});function useIntersectionObserver(t,e){const l=ref(),n=shallowRef(!1);if(SUPPORTS_INTERSECTION){const u=new IntersectionObserver(c=>{n.value=!!c.find(y=>y.isIntersecting)},e);onBeforeUnmount(()=>{u.disconnect()}),watch(l,(c,y)=>{y&&(u.unobserve(y),n.value=!1),c&&u.observe(c)},{flush:"post"})}return{intersectionRef:l,isIntersecting:n}}const oppositeMap={center:"center",top:"bottom",bottom:"top",left:"right",right:"left"},makeLocationProps=propsFactory$1({location:String},"location");function useLocation(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,l=arguments.length>2?arguments[2]:void 0;const{isRtl:n}=useRtl();return{locationStyles:computed(()=>{if(!t.location)return{};const{side:c,align:y}=parseAnchor(t.location.split(" ").length>1?t.location:`${t.location} center`,n.value);function b(O){return l?l(O):0}const m={};return c!=="center"&&(e?m[oppositeMap[c]]=`calc(100% - ${b(c)}px)`:m[c]=0),y!=="center"?e?m[oppositeMap[y]]=`calc(100% - ${b(y)}px)`:m[y]=0:(c==="center"?m.top=m.left="50%":m[{top:"left",bottom:"left",left:"top",right:"top"}[c]]="50%",m.transform={top:"translateX(-50%)",bottom:"translateX(-50%)",left:"translateY(-50%)",right:"translateY(-50%)",center:"translate(-50%, -50%)"}[c]),m})}}const makeVProgressLinearProps=propsFactory$1({absolute:Boolean,active:{type:Boolean,default:!0},bgColor:String,bgOpacity:[Number,String],bufferValue:{type:[Number,String],default:0},bufferColor:String,bufferOpacity:[Number,String],clickable:Boolean,color:String,height:{type:[Number,String],default:4},indeterminate:Boolean,max:{type:[Number,String],default:100},modelValue:{type:[Number,String],default:0},opacity:[Number,String],reverse:Boolean,stream:Boolean,striped:Boolean,roundedBar:Boolean,...makeComponentProps(),...makeLocationProps({location:"top"}),...makeRoundedProps(),...makeTagProps(),...makeThemeProps()},"VProgressLinear"),VProgressLinear=genericComponent()({name:"VProgressLinear",props:makeVProgressLinearProps(),emits:{"update:modelValue":t=>!0},setup(t,e){let{slots:l}=e;const n=useProxiedModel(t,"modelValue"),{isRtl:u,rtlClasses:c}=useRtl(),{themeClasses:y}=provideTheme(t),{locationStyles:b}=useLocation(t),{textColorClasses:m,textColorStyles:O}=useTextColor(t,"color"),{backgroundColorClasses:N,backgroundColorStyles:L}=useBackgroundColor(computed(()=>t.bgColor||t.color)),{backgroundColorClasses:G,backgroundColorStyles:q}=useBackgroundColor(computed(()=>t.bufferColor||t.bgColor||t.color)),{backgroundColorClasses:J,backgroundColorStyles:fe}=useBackgroundColor(t,"color"),{roundedClasses:ve}=useRounded(t),{intersectionRef:ne,isIntersecting:Ue}=useIntersectionObserver(),De=computed(()=>parseFloat(t.max)),Ve=computed(()=>parseFloat(t.height)),rt=computed(()=>clamp(parseFloat(t.bufferValue)/De.value*100,0,100)),Ae=computed(()=>clamp(parseFloat(n.value)/De.value*100,0,100)),Te=computed(()=>u.value!==t.reverse),Xe=computed(()=>t.indeterminate?"fade-transition":"slide-x-transition"),ie=IN_BROWSER&&window.matchMedia?.("(forced-colors: active)").matches;function ue(pt){if(!ne.value)return;const{left:mt,right:Tt,width:kt}=ne.value.getBoundingClientRect(),It=Te.value?kt-pt.clientX+(Tt-kt):pt.clientX-mt;n.value=Math.round(It/kt*De.value)}return useRender(()=>createVNode(t.tag,{ref:ne,class:["v-progress-linear",{"v-progress-linear--absolute":t.absolute,"v-progress-linear--active":t.active&&Ue.value,"v-progress-linear--reverse":Te.value,"v-progress-linear--rounded":t.rounded,"v-progress-linear--rounded-bar":t.roundedBar,"v-progress-linear--striped":t.striped},ve.value,y.value,c.value,t.class],style:[{bottom:t.location==="bottom"?0:void 0,top:t.location==="top"?0:void 0,height:t.active?convertToUnit(Ve.value):0,"--v-progress-linear-height":convertToUnit(Ve.value),...t.absolute?b.value:{}},t.style],role:"progressbar","aria-hidden":t.active?"false":"true","aria-valuemin":"0","aria-valuemax":t.max,"aria-valuenow":t.indeterminate?void 0:Ae.value,onClick:t.clickable&&ue},{default:()=>[t.stream&&createVNode("div",{key:"stream",class:["v-progress-linear__stream",m.value],style:{...O.value,[Te.value?"left":"right"]:convertToUnit(-Ve.value),borderTop:`${convertToUnit(Ve.value/2)} dotted`,opacity:parseFloat(t.bufferOpacity),top:`calc(50% - ${convertToUnit(Ve.value/4)})`,width:convertToUnit(100-rt.value,"%"),"--v-progress-linear-stream-to":convertToUnit(Ve.value*(Te.value?1:-1))}},null),createVNode("div",{class:["v-progress-linear__background",ie?void 0:N.value],style:[L.value,{opacity:parseFloat(t.bgOpacity),width:t.stream?0:void 0}]},null),createVNode("div",{class:["v-progress-linear__buffer",ie?void 0:G.value],style:[q.value,{opacity:parseFloat(t.bufferOpacity),width:convertToUnit(rt.value,"%")}]},null),createVNode(Transition,{name:Xe.value},{default:()=>[t.indeterminate?createVNode("div",{class:"v-progress-linear__indeterminate"},[["long","short"].map(pt=>createVNode("div",{key:pt,class:["v-progress-linear__indeterminate",pt,ie?void 0:J.value],style:fe.value},null))]):createVNode("div",{class:["v-progress-linear__determinate",ie?void 0:J.value],style:[fe.value,{width:convertToUnit(Ae.value,"%")}]},null)]}),l.default&&createVNode("div",{class:"v-progress-linear__content"},[l.default({value:Ae.value,buffer:rt.value})])]})),{}}}),makeLoaderProps=propsFactory$1({loading:[Boolean,String]},"loader");function useLoader(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:getCurrentInstanceName();return{loaderClasses:computed(()=>({[`${e}--loading`]:t.loading}))}}function LoaderSlot(t,e){let{slots:l}=e;return createVNode("div",{class:`${t.name}__loader`},[l.default?.({color:t.color,isActive:t.active})||createVNode(VProgressLinear,{absolute:t.absolute,active:t.active,color:t.color,height:"2",indeterminate:!0},null)])}const allowedVariants$1=["underlined","outlined","filled","solo","solo-inverted","solo-filled","plain"],makeVFieldProps=propsFactory$1({appendInnerIcon:IconValue$1,bgColor:String,clearable:Boolean,clearIcon:{type:IconValue$1,default:"$clear"},active:Boolean,centerAffix:{type:Boolean,default:void 0},color:String,baseColor:String,dirty:Boolean,disabled:{type:Boolean,default:null},error:Boolean,flat:Boolean,label:String,persistentClear:Boolean,prependInnerIcon:IconValue$1,reverse:Boolean,singleLine:Boolean,variant:{type:String,default:"filled",validator:t=>allowedVariants$1.includes(t)},"onClick:clear":EventProp(),"onClick:appendInner":EventProp(),"onClick:prependInner":EventProp(),...makeComponentProps(),...makeLoaderProps(),...makeRoundedProps(),...makeThemeProps()},"VField"),VField=genericComponent()({name:"VField",inheritAttrs:!1,props:{id:String,...makeFocusProps(),...makeVFieldProps()},emits:{"update:focused":t=>!0,"update:modelValue":t=>!0},setup(t,e){let{attrs:l,emit:n,slots:u}=e;const{themeClasses:c}=provideTheme(t),{loaderClasses:y}=useLoader(t),{focusClasses:b,isFocused:m,focus:O,blur:N}=useFocus(t),{InputIcon:L}=useInputIcon(t),{roundedClasses:G}=useRounded(t),{rtlClasses:q}=useRtl(),J=computed(()=>t.dirty||t.active),fe=computed(()=>!t.singleLine&&!!(t.label||u.label)),ve=getUid(),ne=computed(()=>t.id||`input-${ve}`),Ue=computed(()=>`${ne.value}-messages`),De=ref(),Ve=ref(),rt=ref(),Ae=computed(()=>["plain","underlined"].includes(t.variant)),{backgroundColorClasses:Te,backgroundColorStyles:Xe}=useBackgroundColor(toRef(t,"bgColor")),{textColorClasses:ie,textColorStyles:ue}=useTextColor(computed(()=>t.error||t.disabled?void 0:J.value&&m.value?t.color:t.baseColor));watch(J,kt=>{if(fe.value){const It=De.value.$el,nn=Ve.value.$el;requestAnimationFrame(()=>{const tn=nullifyTransforms(It),pn=nn.getBoundingClientRect(),_n=pn.x-tn.x,Dn=pn.y-tn.y-(tn.height/2-pn.height/2),an=pn.width/.75,Rn=Math.abs(an-tn.width)>1?{maxWidth:convertToUnit(an)}:void 0,Lt=getComputedStyle(It),wn=getComputedStyle(nn),hn=parseFloat(Lt.transitionDuration)*1e3||150,xn=parseFloat(wn.getPropertyValue("--v-field-label-scale")),$n=wn.getPropertyValue("color");It.style.visibility="visible",nn.style.visibility="hidden",animate(It,{transform:`translate(${_n}px, ${Dn}px) scale(${xn})`,color:$n,...Rn},{duration:hn,easing:standardEasing,direction:kt?"normal":"reverse"}).finished.then(()=>{It.style.removeProperty("visibility"),nn.style.removeProperty("visibility")})})}},{flush:"post"});const pt=computed(()=>({isActive:J,isFocused:m,controlRef:rt,blur:N,focus:O}));function mt(kt){kt.target!==document.activeElement&&kt.preventDefault()}function Tt(kt){kt.key!=="Enter"&&kt.key!==" "||(kt.preventDefault(),kt.stopPropagation(),t["onClick:clear"]?.(new MouseEvent("click")))}return useRender(()=>{const kt=t.variant==="outlined",It=!!(u["prepend-inner"]||t.prependInnerIcon),nn=!!(t.clearable||u.clear),tn=!!(u["append-inner"]||t.appendInnerIcon||nn),pn=()=>u.label?u.label({...pt.value,label:t.label,props:{for:ne.value}}):t.label;return createVNode("div",mergeProps({class:["v-field",{"v-field--active":J.value,"v-field--appended":tn,"v-field--center-affix":t.centerAffix??!Ae.value,"v-field--disabled":t.disabled,"v-field--dirty":t.dirty,"v-field--error":t.error,"v-field--flat":t.flat,"v-field--has-background":!!t.bgColor,"v-field--persistent-clear":t.persistentClear,"v-field--prepended":It,"v-field--reverse":t.reverse,"v-field--single-line":t.singleLine,"v-field--no-label":!pn(),[`v-field--variant-${t.variant}`]:!0},c.value,Te.value,b.value,y.value,G.value,q.value,t.class],style:[Xe.value,t.style],onClick:mt},l),[createVNode("div",{class:"v-field__overlay"},null),createVNode(LoaderSlot,{name:"v-field",active:!!t.loading,color:t.error?"error":typeof t.loading=="string"?t.loading:t.color},{default:u.loader}),It&&createVNode("div",{key:"prepend",class:"v-field__prepend-inner"},[t.prependInnerIcon&&createVNode(L,{key:"prepend-icon",name:"prependInner"},null),u["prepend-inner"]?.(pt.value)]),createVNode("div",{class:"v-field__field","data-no-activator":""},[["filled","solo","solo-inverted","solo-filled"].includes(t.variant)&&fe.value&&createVNode(VFieldLabel,{key:"floating-label",ref:Ve,class:[ie.value],floating:!0,for:ne.value,style:ue.value},{default:()=>[pn()]}),createVNode(VFieldLabel,{ref:De,for:ne.value},{default:()=>[pn()]}),u.default?.({...pt.value,props:{id:ne.value,class:"v-field__input","aria-describedby":Ue.value},focus:O,blur:N})]),nn&&createVNode(VExpandXTransition,{key:"clear"},{default:()=>[withDirectives(createVNode("div",{class:"v-field__clearable",onMousedown:_n=>{_n.preventDefault(),_n.stopPropagation()}},[createVNode(VDefaultsProvider,{defaults:{VIcon:{icon:t.clearIcon}}},{default:()=>[u.clear?u.clear({...pt.value,props:{onKeydown:Tt,onFocus:O,onBlur:N,onClick:t["onClick:clear"]}}):createVNode(L,{name:"clear",onKeydown:Tt,onFocus:O,onBlur:N},null)]})]),[[vShow,t.dirty]])]}),tn&&createVNode("div",{key:"append",class:"v-field__append-inner"},[u["append-inner"]?.(pt.value),t.appendInnerIcon&&createVNode(L,{key:"append-icon",name:"appendInner"},null)]),createVNode("div",{class:["v-field__outline",ie.value],style:ue.value},[kt&&createVNode(Fragment,null,[createVNode("div",{class:"v-field__outline__start"},null),fe.value&&createVNode("div",{class:"v-field__outline__notch"},[createVNode(VFieldLabel,{ref:Ve,floating:!0,for:ne.value},{default:()=>[pn()]})]),createVNode("div",{class:"v-field__outline__end"},null)]),Ae.value&&fe.value&&createVNode(VFieldLabel,{ref:Ve,floating:!0,for:ne.value},{default:()=>[pn()]})])])}),{controlRef:rt}}});function filterFieldProps(t){const e=Object.keys(VField.props).filter(l=>!isOn(l)&&l!=="class"&&l!=="style");return pick(t,e)}const activeTypes=["color","file","time","date","datetime-local","week","month"],makeVTextFieldProps=propsFactory$1({autofocus:Boolean,counter:[Boolean,Number,String],counterValue:[Number,Function],prefix:String,placeholder:String,persistentPlaceholder:Boolean,persistentCounter:Boolean,suffix:String,role:String,type:{type:String,default:"text"},modelModifiers:Object,...makeVInputProps(),...makeVFieldProps()},"VTextField"),VTextField=genericComponent()({name:"VTextField",directives:{Intersect},inheritAttrs:!1,props:makeVTextFieldProps(),emits:{"click:control":t=>!0,"mousedown:control":t=>!0,"update:focused":t=>!0,"update:modelValue":t=>!0},setup(t,e){let{attrs:l,emit:n,slots:u}=e;const c=useProxiedModel(t,"modelValue"),{isFocused:y,focus:b,blur:m}=useFocus(t),O=computed(()=>typeof t.counterValue=="function"?t.counterValue(c.value):typeof t.counterValue=="number"?t.counterValue:(c.value??"").toString().length),N=computed(()=>{if(l.maxlength)return l.maxlength;if(!(!t.counter||typeof t.counter!="number"&&typeof t.counter!="string"))return t.counter}),L=computed(()=>["plain","underlined"].includes(t.variant));function G(Ae,Te){!t.autofocus||!Ae||Te[0].target?.focus?.()}const q=ref(),J=ref(),fe=ref(),ve=computed(()=>activeTypes.includes(t.type)||t.persistentPlaceholder||y.value||t.active);function ne(){fe.value!==document.activeElement&&fe.value?.focus(),y.value||b()}function Ue(Ae){n("mousedown:control",Ae),Ae.target!==fe.value&&(ne(),Ae.preventDefault())}function De(Ae){ne(),n("click:control",Ae)}function Ve(Ae){Ae.stopPropagation(),ne(),nextTick(()=>{c.value=null,callEvent(t["onClick:clear"],Ae)})}function rt(Ae){const Te=Ae.target;if(c.value=Te.value,t.modelModifiers?.trim&&["text","search","password","tel","url"].includes(t.type)){const Xe=[Te.selectionStart,Te.selectionEnd];nextTick(()=>{Te.selectionStart=Xe[0],Te.selectionEnd=Xe[1]})}}return useRender(()=>{const Ae=!!(u.counter||t.counter!==!1&&t.counter!=null),Te=!!(Ae||u.details),[Xe,ie]=filterInputAttrs(l),{modelValue:ue,...pt}=VInput.filterProps(t),mt=filterFieldProps(t);return createVNode(VInput,mergeProps({ref:q,modelValue:c.value,"onUpdate:modelValue":Tt=>c.value=Tt,class:["v-text-field",{"v-text-field--prefixed":t.prefix,"v-text-field--suffixed":t.suffix,"v-input--plain-underlined":L.value},t.class],style:t.style},Xe,pt,{centerAffix:!L.value,focused:y.value}),{...u,default:Tt=>{let{id:kt,isDisabled:It,isDirty:nn,isReadonly:tn,isValid:pn}=Tt;return createVNode(VField,mergeProps({ref:J,onMousedown:Ue,onClick:De,"onClick:clear":Ve,"onClick:prependInner":t["onClick:prependInner"],"onClick:appendInner":t["onClick:appendInner"],role:t.role},mt,{id:kt.value,active:ve.value||nn.value,dirty:nn.value||t.dirty,disabled:It.value,focused:y.value,error:pn.value===!1}),{...u,default:_n=>{let{props:{class:Dn,...an}}=_n;const Rn=withDirectives(createVNode("input",mergeProps({ref:fe,value:c.value,onInput:rt,autofocus:t.autofocus,readonly:tn.value,disabled:It.value,name:t.name,placeholder:t.placeholder,size:1,type:t.type,onFocus:ne,onBlur:m},an,ie),null),[[resolveDirective("intersect"),{handler:G},null,{once:!0}]]);return createVNode(Fragment,null,[t.prefix&&createVNode("span",{class:"v-text-field__prefix"},[createVNode("span",{class:"v-text-field__prefix__text"},[t.prefix])]),u.default?createVNode("div",{class:Dn,"data-no-activator":""},[u.default(),Rn]):cloneVNode(Rn,{class:Dn}),t.suffix&&createVNode("span",{class:"v-text-field__suffix"},[createVNode("span",{class:"v-text-field__suffix__text"},[t.suffix])])])}})},details:Te?Tt=>createVNode(Fragment,null,[u.details?.(Tt),Ae&&createVNode(Fragment,null,[createVNode("span",null,null),createVNode(VCounter,{active:t.persistentCounter||y.value,value:O.value,max:N.value,disabled:t.disabled},u.counter)])]):void 0})}),forwardRefs({},q,J,fe)}}),makeVVirtualScrollItemProps=propsFactory$1({renderless:Boolean,...makeComponentProps()},"VVirtualScrollItem"),VVirtualScrollItem=genericComponent()({name:"VVirtualScrollItem",inheritAttrs:!1,props:makeVVirtualScrollItemProps(),emits:{"update:height":t=>!0},setup(t,e){let{attrs:l,emit:n,slots:u}=e;const{resizeRef:c,contentRect:y}=useResizeObserver(void 0,"border");watch(()=>y.value?.height,b=>{b!=null&&n("update:height",b)}),useRender(()=>t.renderless?createVNode(Fragment,null,[u.default?.({itemRef:c})]):createVNode("div",mergeProps({ref:c,class:["v-virtual-scroll__item",t.class],style:t.style},l),[u.default?.()]))}}),UP=-1,DOWN=1,BUFFER_PX=100,makeVirtualProps=propsFactory$1({itemHeight:{type:[Number,String],default:null},height:[Number,String]},"virtual");function useVirtual(t,e){const l=useDisplay(),n=shallowRef(0);watchEffect(()=>{n.value=parseFloat(t.itemHeight||0)});const u=shallowRef(0),c=shallowRef(Math.ceil((parseInt(t.height)||l.height.value)/(n.value||16))||1),y=shallowRef(0),b=shallowRef(0),m=ref(),O=ref();let N=0;const{resizeRef:L,contentRect:G}=useResizeObserver();watchEffect(()=>{L.value=m.value});const q=computed(()=>m.value===document.documentElement?l.height.value:G.value?.height||parseInt(t.height)||0),J=computed(()=>!!(m.value&&O.value&&q.value&&n.value));let fe=Array.from({length:e.value.length}),ve=Array.from({length:e.value.length});const ne=shallowRef(0);let Ue=-1;function De(_n){return fe[_n]||n.value}const Ve=debounce(()=>{const _n=performance.now();ve[0]=0;const Dn=e.value.length;for(let an=1;an<=Dn-1;an++)ve[an]=(ve[an-1]||0)+De(an-1);ne.value=Math.max(ne.value,performance.now()-_n)},ne),rt=watch(J,_n=>{_n&&(rt(),N=O.value.offsetTop,Ve.immediate(),It(),~Ue&&nextTick(()=>{IN_BROWSER&&window.requestAnimationFrame(()=>{tn(Ue),Ue=-1})}))});onScopeDispose(()=>{Ve.clear()});function Ae(_n,Dn){const an=fe[_n],Rn=n.value;n.value=Rn?Math.min(n.value,Dn):Dn,(an!==Dn||Rn!==n.value)&&(fe[_n]=Dn,Ve())}function Te(_n){return _n=clamp(_n,0,e.value.length-1),ve[_n]||0}function Xe(_n){return binaryClosest(ve,_n)}let ie=0,ue=0,pt=0;watch(q,(_n,Dn)=>{Dn&&(It(),_n<Dn&&requestAnimationFrame(()=>{ue=0,It()}))});function mt(){if(!m.value||!O.value)return;const _n=m.value.scrollTop,Dn=performance.now();Dn-pt>500?(ue=Math.sign(_n-ie),N=O.value.offsetTop):ue=_n-ie,ie=_n,pt=Dn,It()}function Tt(){!m.value||!O.value||(ue=0,pt=0,It())}let kt=-1;function It(){cancelAnimationFrame(kt),kt=requestAnimationFrame(nn)}function nn(){if(!m.value||!q.value)return;const _n=ie-N,Dn=Math.sign(ue),an=Math.max(0,_n-BUFFER_PX),Rn=clamp(Xe(an),0,e.value.length),Lt=_n+q.value+BUFFER_PX,wn=clamp(Xe(Lt)+1,Rn+1,e.value.length);if((Dn!==UP||Rn<u.value)&&(Dn!==DOWN||wn>c.value)){const hn=Te(u.value)-Te(Rn),xn=Te(wn)-Te(c.value);Math.max(hn,xn)>BUFFER_PX?(u.value=Rn,c.value=wn):(Rn<=0&&(u.value=Rn),wn>=e.value.length&&(c.value=wn))}y.value=Te(u.value),b.value=Te(e.value.length)-Te(c.value)}function tn(_n){const Dn=Te(_n);!m.value||_n&&!Dn?Ue=_n:m.value.scrollTop=Dn}const pn=computed(()=>e.value.slice(u.value,c.value).map((_n,Dn)=>({raw:_n,index:Dn+u.value})));return watch(e,()=>{fe=Array.from({length:e.value.length}),ve=Array.from({length:e.value.length}),Ve.immediate(),It()},{deep:!0}),{calculateVisibleItems:It,containerRef:m,markerRef:O,computedItems:pn,paddingTop:y,paddingBottom:b,scrollToIndex:tn,handleScroll:mt,handleScrollend:Tt,handleItemResize:Ae}}function binaryClosest(t,e){let l=t.length-1,n=0,u=0,c=null,y=-1;if(t[l]<e)return l;for(;n<=l;)if(u=n+l>>1,c=t[u],c>e)l=u-1;else if(c<e)y=u,n=u+1;else return c===e?u:n;return y}const makeVVirtualScrollProps=propsFactory$1({items:{type:Array,default:()=>[]},renderless:Boolean,...makeVirtualProps(),...makeComponentProps(),...makeDimensionProps()},"VVirtualScroll"),VVirtualScroll=genericComponent()({name:"VVirtualScroll",props:makeVVirtualScrollProps(),setup(t,e){let{slots:l}=e;const n=getCurrentInstance("VVirtualScroll"),{dimensionStyles:u}=useDimension(t),{calculateVisibleItems:c,containerRef:y,markerRef:b,handleScroll:m,handleScrollend:O,handleItemResize:N,scrollToIndex:L,paddingTop:G,paddingBottom:q,computedItems:J}=useVirtual(t,toRef(t,"items"));return useToggleScope(()=>t.renderless,()=>{function fe(){const ne=(arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1)?"addEventListener":"removeEventListener";y.value===document.documentElement?(document[ne]("scroll",m,{passive:!0}),document[ne]("scrollend",O)):(y.value?.[ne]("scroll",m,{passive:!0}),y.value?.[ne]("scrollend",O))}onMounted(()=>{y.value=getScrollParent(n.vnode.el,!0),fe(!0)}),onScopeDispose(fe)}),useRender(()=>{const fe=J.value.map(ve=>createVNode(VVirtualScrollItem,{key:ve.index,renderless:t.renderless,"onUpdate:height":ne=>N(ve.index,ne)},{default:ne=>l.default?.({item:ve.raw,index:ve.index,...ne})}));return t.renderless?createVNode(Fragment,null,[createVNode("div",{ref:b,class:"v-virtual-scroll__spacer",style:{paddingTop:convertToUnit(G.value)}},null),fe,createVNode("div",{class:"v-virtual-scroll__spacer",style:{paddingBottom:convertToUnit(q.value)}},null)]):createVNode("div",{ref:y,class:["v-virtual-scroll",t.class],onScrollPassive:m,onScrollend:O,style:[u.value,t.style]},[createVNode("div",{ref:b,class:"v-virtual-scroll__container",style:{paddingTop:convertToUnit(G.value),paddingBottom:convertToUnit(q.value)}},[fe])])}),{calculateVisibleItems:c,scrollToIndex:L}}});function useScrolling(t,e){const l=shallowRef(!1);let n;function u(b){cancelAnimationFrame(n),l.value=!0,n=requestAnimationFrame(()=>{n=requestAnimationFrame(()=>{l.value=!1})})}async function c(){await new Promise(b=>requestAnimationFrame(b)),await new Promise(b=>requestAnimationFrame(b)),await new Promise(b=>requestAnimationFrame(b)),await new Promise(b=>{if(l.value){const m=watch(l,()=>{m(),b()})}else b()})}async function y(b){if(b.key==="Tab"&&e.value?.focus(),!["PageDown","PageUp","Home","End"].includes(b.key))return;const m=t.value?.$el;if(!m)return;(b.key==="Home"||b.key==="End")&&m.scrollTo({top:b.key==="Home"?0:m.scrollHeight,behavior:"smooth"}),await c();const O=m.querySelectorAll(":scope > :not(.v-virtual-scroll__spacer)");if(b.key==="PageDown"||b.key==="Home"){const N=m.getBoundingClientRect().top;for(const L of O)if(L.getBoundingClientRect().top>=N){L.focus();break}}else{const N=m.getBoundingClientRect().bottom;for(const L of[...O].reverse())if(L.getBoundingClientRect().bottom<=N){L.focus();break}}}return{onScrollPassive:u,onKeydown:y}}const makeSelectProps=propsFactory$1({chips:Boolean,closableChips:Boolean,closeText:{type:String,default:"$vuetify.close"},openText:{type:String,default:"$vuetify.open"},eager:Boolean,hideNoData:Boolean,hideSelected:Boolean,listProps:{type:Object},menu:Boolean,menuIcon:{type:IconValue$1,default:"$dropdown"},menuProps:{type:Object},multiple:Boolean,noDataText:{type:String,default:"$vuetify.noDataText"},openOnClear:Boolean,itemColor:String,...makeItemsProps({itemChildren:!1})},"Select"),makeVSelectProps=propsFactory$1({...makeSelectProps(),...omit(makeVTextFieldProps({modelValue:null,role:"combobox"}),["validationValue","dirty","appendInnerIcon"]),...makeTransitionProps({transition:{component:VDialogTransition}})},"VSelect"),VSelect=genericComponent()({name:"VSelect",props:makeVSelectProps(),emits:{"update:focused":t=>!0,"update:modelValue":t=>!0,"update:menu":t=>!0},setup(t,e){let{slots:l}=e;const{t:n}=useLocale(),u=ref(),c=ref(),y=ref(),b=useProxiedModel(t,"menu"),m=computed({get:()=>b.value,set:_n=>{b.value&&!_n&&c.value?.ΨopenChildren.size||(b.value=_n)}}),{items:O,transformIn:N,transformOut:L}=useItems(t),G=useProxiedModel(t,"modelValue",[],_n=>N(_n===null?[null]:wrapInArray(_n)),_n=>{const Dn=L(_n);return t.multiple?Dn:Dn[0]??null}),q=computed(()=>typeof t.counterValue=="function"?t.counterValue(G.value):typeof t.counterValue=="number"?t.counterValue:G.value.length),J=useForm(),fe=computed(()=>G.value.map(_n=>_n.value)),ve=shallowRef(!1),ne=computed(()=>m.value?t.closeText:t.openText);let Ue="",De;const Ve=computed(()=>t.hideSelected?O.value.filter(_n=>!G.value.some(Dn=>t.valueComparator(Dn,_n))):O.value),rt=computed(()=>t.hideNoData&&!Ve.value.length||t.readonly||J?.isReadonly.value),Ae=computed(()=>({...t.menuProps,activatorProps:{...t.menuProps?.activatorProps||{},"aria-haspopup":"listbox"}})),Te=ref(),Xe=useScrolling(Te,u);function ie(_n){t.openOnClear&&(m.value=!0)}function ue(){rt.value||(m.value=!m.value)}function pt(_n){checkPrintable(_n)&&mt(_n)}function mt(_n){if(!_n.key||t.readonly||J?.isReadonly.value)return;["Enter"," ","ArrowDown","ArrowUp","Home","End"].includes(_n.key)&&_n.preventDefault(),["Enter","ArrowDown"," "].includes(_n.key)&&(m.value=!0),["Escape","Tab"].includes(_n.key)&&(m.value=!1),_n.key==="Home"?Te.value?.focus("first"):_n.key==="End"&&Te.value?.focus("last");const Dn=1e3;if(t.multiple||!checkPrintable(_n))return;const an=performance.now();an-De>Dn&&(Ue=""),Ue+=_n.key.toLowerCase(),De=an;const Rn=O.value.find(Lt=>Lt.title.toLowerCase().startsWith(Ue));if(Rn!==void 0){G.value=[Rn];const Lt=Ve.value.indexOf(Rn);IN_BROWSER&&window.requestAnimationFrame(()=>{Lt>=0&&y.value?.scrollToIndex(Lt)})}}function Tt(_n){let Dn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;if(!_n.props.disabled)if(t.multiple){const an=G.value.findIndex(Lt=>t.valueComparator(Lt.value,_n.value)),Rn=Dn??!~an;if(~an){const Lt=Rn?[...G.value,_n]:[...G.value];Lt.splice(an,1),G.value=Lt}else Rn&&(G.value=[...G.value,_n])}else{const an=Dn!==!1;G.value=an?[_n]:[],nextTick(()=>{m.value=!1})}}function kt(_n){Te.value?.$el.contains(_n.relatedTarget)||(m.value=!1)}function It(){t.eager&&y.value?.calculateVisibleItems()}function nn(){ve.value&&u.value?.focus()}function tn(_n){ve.value=!0}function pn(_n){if(_n==null)G.value=[];else if(matchesSelector(u.value,":autofill")||matchesSelector(u.value,":-webkit-autofill")){const Dn=O.value.find(an=>an.title===_n);Dn&&Tt(Dn)}else u.value&&(u.value.value="")}return watch(m,()=>{if(!t.hideSelected&&m.value&&G.value.length){const _n=Ve.value.findIndex(Dn=>G.value.some(an=>t.valueComparator(an.value,Dn.value)));IN_BROWSER&&window.requestAnimationFrame(()=>{_n>=0&&y.value?.scrollToIndex(_n)})}}),watch(()=>t.items,(_n,Dn)=>{m.value||ve.value&&!Dn.length&&_n.length&&(m.value=!0)}),useRender(()=>{const _n=!!(t.chips||l.chip),Dn=!!(!t.hideNoData||Ve.value.length||l["prepend-item"]||l["append-item"]||l["no-data"]),an=G.value.length>0,Rn=VTextField.filterProps(t),Lt=an||!ve.value&&t.label&&!t.persistentPlaceholder?void 0:t.placeholder;return createVNode(VTextField,mergeProps({ref:u},Rn,{modelValue:G.value.map(wn=>wn.props.value).join(", "),"onUpdate:modelValue":pn,focused:ve.value,"onUpdate:focused":wn=>ve.value=wn,validationValue:G.externalValue,counterValue:q.value,dirty:an,class:["v-select",{"v-select--active-menu":m.value,"v-select--chips":!!t.chips,[`v-select--${t.multiple?"multiple":"single"}`]:!0,"v-select--selected":G.value.length,"v-select--selection-slot":!!l.selection},t.class],style:t.style,inputmode:"none",placeholder:Lt,"onClick:clear":ie,"onMousedown:control":ue,onBlur:kt,onKeydown:mt,"aria-label":n(ne.value),title:n(ne.value)}),{...l,default:()=>createVNode(Fragment,null,[createVNode(VMenu,mergeProps({ref:c,modelValue:m.value,"onUpdate:modelValue":wn=>m.value=wn,activator:"parent",contentClass:"v-select__content",disabled:rt.value,eager:t.eager,maxHeight:310,openOnClick:!1,closeOnContentClick:!1,transition:t.transition,onAfterEnter:It,onAfterLeave:nn},Ae.value),{default:()=>[Dn&&createVNode(VList,mergeProps({ref:Te,selected:fe.value,selectStrategy:t.multiple?"independent":"single-independent",onMousedown:wn=>wn.preventDefault(),onKeydown:pt,onFocusin:tn,tabindex:"-1","aria-live":"polite",color:t.itemColor??t.color},Xe,t.listProps),{default:()=>[l["prepend-item"]?.(),!Ve.value.length&&!t.hideNoData&&(l["no-data"]?.()??createVNode(VListItem,{title:n(t.noDataText)},null)),createVNode(VVirtualScroll,{ref:y,renderless:!0,items:Ve.value},{default:wn=>{let{item:hn,index:xn,itemRef:$n}=wn;const Xr=mergeProps(hn.props,{ref:$n,key:xn,onClick:()=>Tt(hn,null)});return l.item?.({item:hn,index:xn,props:Xr})??createVNode(VListItem,mergeProps(Xr,{role:"option"}),{prepend:ti=>{let{isSelected:gn}=ti;return createVNode(Fragment,null,[t.multiple&&!t.hideSelected?createVNode(VCheckboxBtn,{key:hn.value,modelValue:gn,ripple:!1,tabindex:"-1"},null):void 0,hn.props.prependAvatar&&createVNode(VAvatar,{image:hn.props.prependAvatar},null),hn.props.prependIcon&&createVNode(VIcon,{icon:hn.props.prependIcon},null)])}})}}),l["append-item"]?.()]})]}),G.value.map((wn,hn)=>{function xn(gn){gn.stopPropagation(),gn.preventDefault(),Tt(wn,!1)}const $n={"onClick:close":xn,onKeydown(gn){gn.key!=="Enter"&&gn.key!==" "||(gn.preventDefault(),gn.stopPropagation(),xn(gn))},onMousedown(gn){gn.preventDefault(),gn.stopPropagation()},modelValue:!0,"onUpdate:modelValue":void 0},Xr=_n?!!l.chip:!!l.selection,ti=Xr?ensureValidVNode(_n?l.chip({item:wn,index:hn,props:$n}):l.selection({item:wn,index:hn})):void 0;if(!(Xr&&!ti))return createVNode("div",{key:wn.value,class:"v-select__selection"},[_n?l.chip?createVNode(VDefaultsProvider,{key:"chip-defaults",defaults:{VChip:{closable:t.closableChips,size:"small",text:wn.title}}},{default:()=>[ti]}):createVNode(VChip,mergeProps({key:"chip",closable:t.closableChips,size:"small",text:wn.title,disabled:wn.props.disabled},$n),null):ti??createVNode("span",{class:"v-select__selection-text"},[wn.title,t.multiple&&hn<G.value.length-1&&createVNode("span",{class:"v-select__selection-comma"},[createTextVNode(",")])])])})]),"append-inner":function(){for(var wn=arguments.length,hn=new Array(wn),xn=0;xn<wn;xn++)hn[xn]=arguments[xn];return createVNode(Fragment,null,[l["append-inner"]?.(...hn),t.menuIcon?createVNode(VIcon,{class:"v-select__menu-icon",icon:t.menuIcon},null):void 0])}})}),forwardRefs({isFocused:ve,menu:m,select:Tt},u)}}),_hoisted_1$m={class:"select-box"},_hoisted_2$i={class:"text"},_sfc_main$t=defineComponent$1({__name:"MxColorSelect",props:{isStoreColor:{type:Boolean,default:!1},modelValue:{}},emits:["update:model-value","change"],setup(t,{expose:e,emit:l}){const n=useColor$1(),{colorSelectList:u,currentSelectColor:c}=storeToRefs(n),{createColor:y}=n,b=(q,J)=>{if(!q)return O.value[O.value.length-1];if(typeof q=="object")return q;let fe=y({...countColorInfo(q,J)});const ve=O.value.find(Ue=>fe.name===Ue.name||fe.color===Ue.color);let ne;return ve?ne=ve:(O.value.unshift(fe),ne=fe),ne},m=l,O=t.isStoreColor?u:ref([...u.value]),N=t.isStoreColor?c:ref(t.modelValue?b(t.modelValue):c.value);if(watch(()=>t.modelValue,q=>{N.value=b(q)}),u.value.length===0&&!t.isStoreColor){const q=watch(u,()=>{O.value=[...u.value],q(),N.value=t.modelValue?b(t.modelValue):c.value,N.value&&(m("update:model-value",N.value),m("change",N.value))})}const L=()=>{MxFun.callEvent("openCustomColorDiallog",{color:N.value,call:(q,J)=>{const fe=b(q,J);N.value=fe,m("update:model-value",fe),m("change",fe)}})},G=q=>{N.value=q,m("update:model-value",q),m("change",q)};return e({color:N,colors:O}),(q,J)=>(openBlock(),createBlock(VSelect,{items:unref(O),"bg-color":"background","model-value":unref(N),"onUpdate:modelValue":G,"return-object":"","item-title":"name",class:"mr-2 rounded"},{selection:withCtx(({item:fe})=>[createBaseVNode("div",_hoisted_1$m,[createBaseVNode("span",{class:"colorBox ml-1",style:normalizeStyle(`background:${fe.raw.color}`)},null,4),createBaseVNode("span",_hoisted_2$i,toDisplayString(unref(translateOnlyChinese)(fe.raw.name)),1)])]),item:withCtx(({item:fe,props:ve})=>[createVNode(VListItem,mergeProps(ve,{title:unref(translateOnlyChinese)(fe.title)}),{prepend:withCtx(()=>[createBaseVNode("span",{class:"colorBox ml-1",style:normalizeStyle(`background:${fe.raw.color}`)},null,4)]),_:2},1040,["title"])]),"prepend-item":withCtx(()=>[createVNode(VListItem,{onClick:withModifiers(L,["stop"]),title:q.t("111")},{prepend:withCtx(()=>[createVNode(VIcon,{icon:"yanse",style:{"margin-right":"10px"},class:"ml-1",size:"14"})]),_:1},8,["title"])]),_:1},8,["items","model-value"]))}}),_export_sfc$2=(t,e)=>{const l=t.__vccOpts||t;for(const[n,u]of e)l[n]=u;return l},MxColorSelect=_export_sfc$2(_sfc_main$t,[["__scopeId","data-v-81a7755b"]]),_hoisted_1$l={class:"select-box"},_hoisted_2$h=["onClick"],_sfc_main$s=defineComponent$1({__name:"SelectList",props:{layerList:{},currentLayer:{},lineTypeList:{},currentLineType:{},color:{}},emits:["update:currentLayer","setLayerVisible","setLayerFreeze","setLayerLock","setLayerColor","setLayerPrint","update:color","update:currentLineType"],setup(t,{expose:e,emit:l}){useLayer();const{createColor:n}=useColor$1(),{colorSelectList:u}=storeToRefs(useColor$1()),c=l,y=(m,O,N)=>{callCommand("Mx_Color",{color:O,call:(L,G)=>{const q=n({...countColorInfo(L,G)});c("setLayerColor",m,q,N)}})},b=ref();return e({getColorsList:()=>t.color&&b&&b.value?b.value.colors:u.value,setColor:m=>{b.value&&(b.value.color=m)}}),(m,O)=>(openBlock(),createElementBlock(Fragment,null,[createVNode(VSelect,{items:m.layerList,"item-title":"name","item-value":"id","model-value":m.currentLayer,"onUpdate:modelValue":O[0]||(O[0]=N=>c("update:currentLayer",N)),class:"mx-2 rounded","return-object":""},{selection:withCtx(({item:N,index:L})=>[createBaseVNode("div",_hoisted_1$l,[createVNode(VIcon,{class:"ml-1 text-blue-darken-3",size:"20",icon:N.raw.visible?"yanjing1":"yanjing"},null,8,["icon"]),createVNode(VIcon,{class:"text-orange ml-1",size:"20",icon:N.raw.lock?"suo":"jiesuo1"},null,8,["icon"]),createVNode(VIcon,{class:"ml-1",icon:N.raw.print?"dayin":"budayinbiaoqian",size:"20"},null,8,["icon"]),createBaseVNode("span",{class:"colorBox ml-1",style:normalizeStyle({background:N.raw.color.color})},null,4),(openBlock(),createElementBlock("span",{key:L,class:"text"},toDisplayString(N.title),1))])]),item:withCtx(({item:N,props:L,index:G})=>[createVNode(VListItem,normalizeProps(guardReactiveProps(L)),{prepend:withCtx(()=>[createVNode(VIcon,{class:"ml-1 text-blue-darken-2",size:"20",icon:N.raw.visible?"yanjing1":"yanjing",onClick:withModifiers(q=>c("setLayerVisible",N.raw,!N.raw.visible,G),["stop"])},null,8,["icon","onClick"]),createVNode(VIcon,{class:"text-orange ml-1",size:"20",icon:N.raw.lock?"suo":"jiesuo1",onClick:withModifiers(q=>c("setLayerLock",N.raw,!N.raw.lock,G),["stop"])},null,8,["icon","onClick"]),createVNode(VIcon,{class:"ml-1",icon:N.raw.print?"dayin":"budayinbiaoqian",size:"20",onClick:withModifiers(q=>c("setLayerPrint",N.raw,!N.raw.print,G),["stop"])},null,8,["icon","onClick"]),createBaseVNode("span",{class:"colorBox ml-1",onClick:withModifiers(q=>y(N.raw,N.raw?.color,G),["stop"]),style:normalizeStyle({background:N.raw.color.color})},null,12,_hoisted_2$h)]),_:2},1040)]),_:1},8,["items","model-value"]),m.color?(openBlock(),createBlock(MxColorSelect,{key:1,"model-value":m.color,ref_key:"selectColorList",ref:b,"onUpdate:modelValue":O[1]||(O[1]=N=>c("update:color",N)),"menus-props":{maxHeight:"600"}},null,8,["model-value"])):(openBlock(),createBlock(MxColorSelect,{key:0,"is-store-color":!0,"menus-props":{maxHeight:"600"}})),createVNode(VSelect,{items:m.lineTypeList,"model-value":m.currentLineType,"onUpdate:modelValue":O[2]||(O[2]=N=>c("update:currentLineType",N)),"return-object":"","item-title":"name",class:"rounded mr-2"},null,8,["items","model-value"])],64))}}),SelectList=_export_sfc$2(_sfc_main$s,[["__scopeId","data-v-4839d5e4"]]),useTopButtonBarData=()=>({mTopButtonBarData:markRaw(uiConfig.mTopButtonBarData||[])}),makeVBtnGroupProps=propsFactory$1({baseColor:String,divided:Boolean,...makeBorderProps(),...makeComponentProps(),...makeDensityProps(),...makeElevationProps(),...makeRoundedProps(),...makeTagProps(),...makeThemeProps(),...makeVariantProps()},"VBtnGroup"),VBtnGroup=genericComponent()({name:"VBtnGroup",props:makeVBtnGroupProps(),setup(t,e){let{slots:l}=e;const{themeClasses:n}=provideTheme(t),{densityClasses:u}=useDensity(t),{borderClasses:c}=useBorder(t),{elevationClasses:y}=useElevation(t),{roundedClasses:b}=useRounded(t);provideDefaults({VBtn:{height:"auto",baseColor:toRef(t,"baseColor"),color:toRef(t,"color"),density:toRef(t,"density"),flat:!0,variant:toRef(t,"variant")}}),useRender(()=>createVNode(t.tag,{class:["v-btn-group",{"v-btn-group--divided":t.divided},n.value,c.value,u.value,y.value,b.value,t.class],style:t.style},l))}}),VBtnToggleSymbol=Symbol.for("vuetify:v-btn-toggle"),makeVBtnToggleProps=propsFactory$1({...makeVBtnGroupProps(),...makeGroupProps()},"VBtnToggle"),VBtnToggle=genericComponent()({name:"VBtnToggle",props:makeVBtnToggleProps(),emits:{"update:modelValue":t=>!0},setup(t,e){let{slots:l}=e;const{isSelected:n,next:u,prev:c,select:y,selected:b}=useGroup(t,VBtnToggleSymbol);return useRender(()=>{const m=VBtnGroup.filterProps(t);return createVNode(VBtnGroup,mergeProps({class:["v-btn-toggle",t.class]},m,{style:t.style}),{default:()=>[l.default?.({isSelected:n,next:u,prev:c,select:y,selected:b})]})}),{next:u,prev:c,select:y}}}),makeVProgressCircularProps=propsFactory$1({bgColor:String,color:String,indeterminate:[Boolean,String],modelValue:{type:[Number,String],default:0},rotate:{type:[Number,String],default:0},width:{type:[Number,String],default:4},...makeComponentProps(),...makeSizeProps(),...makeTagProps({tag:"div"}),...makeThemeProps()},"VProgressCircular"),VProgressCircular=genericComponent()({name:"VProgressCircular",props:makeVProgressCircularProps(),setup(t,e){let{slots:l}=e;const n=20,u=2*Math.PI*n,c=ref(),{themeClasses:y}=provideTheme(t),{sizeClasses:b,sizeStyles:m}=useSize(t),{textColorClasses:O,textColorStyles:N}=useTextColor(toRef(t,"color")),{textColorClasses:L,textColorStyles:G}=useTextColor(toRef(t,"bgColor")),{intersectionRef:q,isIntersecting:J}=useIntersectionObserver(),{resizeRef:fe,contentRect:ve}=useResizeObserver(),ne=computed(()=>Math.max(0,Math.min(100,parseFloat(t.modelValue)))),Ue=computed(()=>Number(t.width)),De=computed(()=>m.value?Number(t.size):ve.value?ve.value.width:Math.max(Ue.value,32)),Ve=computed(()=>n/(1-Ue.value/De.value)*2),rt=computed(()=>Ue.value/De.value*Ve.value),Ae=computed(()=>convertToUnit((100-ne.value)/100*u));return watchEffect(()=>{q.value=c.value,fe.value=c.value}),useRender(()=>createVNode(t.tag,{ref:c,class:["v-progress-circular",{"v-progress-circular--indeterminate":!!t.indeterminate,"v-progress-circular--visible":J.value,"v-progress-circular--disable-shrink":t.indeterminate==="disable-shrink"},y.value,b.value,O.value,t.class],style:[m.value,N.value,t.style],role:"progressbar","aria-valuemin":"0","aria-valuemax":"100","aria-valuenow":t.indeterminate?void 0:ne.value},{default:()=>[createVNode("svg",{style:{transform:`rotate(calc(-90deg + ${Number(t.rotate)}deg))`},xmlns:"http://www.w3.org/2000/svg",viewBox:`0 0 ${Ve.value} ${Ve.value}`},[createVNode("circle",{class:["v-progress-circular__underlay",L.value],style:G.value,fill:"transparent",cx:"50%",cy:"50%",r:n,"stroke-width":rt.value,"stroke-dasharray":u,"stroke-dashoffset":0},null),createVNode("circle",{class:"v-progress-circular__overlay",fill:"transparent",cx:"50%",cy:"50%",r:n,"stroke-width":rt.value,"stroke-dasharray":u,"stroke-dashoffset":Ae.value},null)]),l.default&&createVNode("div",{class:"v-progress-circular__content"},[l.default({value:ne.value})])]})),{}}}),positionValues=["static","relative","fixed","absolute","sticky"],makePositionProps=propsFactory$1({position:{type:String,validator:t=>positionValues.includes(t)}},"position");function usePosition(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:getCurrentInstanceName();return{positionClasses:computed(()=>t.position?`${e}--${t.position}`:void 0)}}function useSelectLink(t,e){watch(()=>t.isActive?.value,l=>{t.isLink.value&&l&&e&&nextTick(()=>{e(!0)})},{immediate:!0})}const makeVBtnProps=propsFactory$1({active:{type:Boolean,default:void 0},activeColor:String,baseColor:String,symbol:{type:null,default:VBtnToggleSymbol},flat:Boolean,icon:[Boolean,String,Function,Object],prependIcon:IconValue$1,appendIcon:IconValue$1,block:Boolean,readonly:Boolean,slim:Boolean,stacked:Boolean,ripple:{type:[Boolean,Object],default:!0},text:String,...makeBorderProps(),...makeComponentProps(),...makeDensityProps(),...makeDimensionProps(),...makeElevationProps(),...makeGroupItemProps(),...makeLoaderProps(),...makeLocationProps(),...makePositionProps(),...makeRoundedProps(),...makeRouterProps(),...makeSizeProps(),...makeTagProps({tag:"button"}),...makeThemeProps(),...makeVariantProps({variant:"elevated"})},"VBtn"),VBtn=genericComponent()({name:"VBtn",props:makeVBtnProps(),emits:{"group:selected":t=>!0},setup(t,e){let{attrs:l,slots:n}=e;const{themeClasses:u}=provideTheme(t),{borderClasses:c}=useBorder(t),{densityClasses:y}=useDensity(t),{dimensionStyles:b}=useDimension(t),{elevationClasses:m}=useElevation(t),{loaderClasses:O}=useLoader(t),{locationStyles:N}=useLocation(t),{positionClasses:L}=usePosition(t),{roundedClasses:G}=useRounded(t),{sizeClasses:q,sizeStyles:J}=useSize(t),fe=useGroupItem(t,t.symbol,!1),ve=useLink(t,l),ne=computed(()=>t.active!==void 0?t.active:ve.isLink.value?ve.isActive?.value:fe?.isSelected.value),Ue=computed(()=>ne.value?t.activeColor??t.color:t.color),De=computed(()=>({color:fe?.isSelected.value&&(!ve.isLink.value||ve.isActive?.value)||!fe||ve.isActive?.value?Ue.value??t.baseColor:t.baseColor,variant:t.variant})),{colorClasses:Ve,colorStyles:rt,variantClasses:Ae}=useVariant(De),Te=computed(()=>fe?.disabled.value||t.disabled),Xe=computed(()=>t.variant==="elevated"&&!(t.disabled||t.flat||t.border)),ie=computed(()=>{if(!(t.value===void 0||typeof t.value=="symbol"))return Object(t.value)===t.value?JSON.stringify(t.value,null,0):t.value});function ue(pt){Te.value||ve.isLink.value&&(pt.metaKey||pt.ctrlKey||pt.shiftKey||pt.button!==0||l.target==="_blank")||(ve.navigate?.(pt),fe?.toggle())}return useSelectLink(ve,fe?.select),useRender(()=>{const pt=ve.isLink.value?"a":t.tag,mt=!!(t.prependIcon||n.prepend),Tt=!!(t.appendIcon||n.append),kt=!!(t.icon&&t.icon!==!0);return withDirectives(createVNode(pt,mergeProps({type:pt==="a"?void 0:"button",class:["v-btn",fe?.selectedClass.value,{"v-btn--active":ne.value,"v-btn--block":t.block,"v-btn--disabled":Te.value,"v-btn--elevated":Xe.value,"v-btn--flat":t.flat,"v-btn--icon":!!t.icon,"v-btn--loading":t.loading,"v-btn--readonly":t.readonly,"v-btn--slim":t.slim,"v-btn--stacked":t.stacked},u.value,c.value,Ve.value,y.value,m.value,O.value,L.value,G.value,q.value,Ae.value,t.class],style:[rt.value,b.value,N.value,J.value,t.style],"aria-busy":t.loading?!0:void 0,disabled:Te.value||void 0,tabindex:t.loading||t.readonly?-1:void 0,onClick:ue,value:ie.value},ve.linkProps),{default:()=>[genOverlays(!0,"v-btn"),!t.icon&&mt&&createVNode("span",{key:"prepend",class:"v-btn__prepend"},[n.prepend?createVNode(VDefaultsProvider,{key:"prepend-defaults",disabled:!t.prependIcon,defaults:{VIcon:{icon:t.prependIcon}}},n.prepend):createVNode(VIcon,{key:"prepend-icon",icon:t.prependIcon},null)]),createVNode("span",{class:"v-btn__content","data-no-activator":""},[!n.default&&kt?createVNode(VIcon,{key:"content-icon",icon:t.icon},null):createVNode(VDefaultsProvider,{key:"content-defaults",disabled:!kt,defaults:{VIcon:{icon:t.icon}}},{default:()=>[n.default?.()??t.text]})]),!t.icon&&Tt&&createVNode("span",{key:"append",class:"v-btn__append"},[n.append?createVNode(VDefaultsProvider,{key:"append-defaults",disabled:!t.appendIcon,defaults:{VIcon:{icon:t.appendIcon}}},n.append):createVNode(VIcon,{key:"append-icon",icon:t.appendIcon},null)]),!!t.loading&&createVNode("span",{key:"loader",class:"v-btn__loader"},[n.loader?.()??createVNode(VProgressCircular,{color:typeof t.loading=="boolean"?void 0:t.loading,indeterminate:!0,width:"2"},null)])]}),[[Ripple,!Te.value&&t.ripple,"",{center:!!t.icon}]])}),{group:fe}}}),makeVTooltipProps=propsFactory$1({id:String,text:String,...omit(makeVOverlayProps({closeOnBack:!1,location:"end",locationStrategy:"connected",eager:!0,minWidth:0,offset:10,openOnClick:!1,openOnHover:!0,origin:"auto",scrim:!1,scrollStrategy:"reposition",transition:!1}),["absolute","persistent"])},"VTooltip"),VTooltip=genericComponent()({name:"VTooltip",props:makeVTooltipProps(),emits:{"update:modelValue":t=>!0},setup(t,e){let{slots:l}=e;const n=useProxiedModel(t,"modelValue"),{scopeId:u}=useScopeId(),c=getUid(),y=computed(()=>t.id||`v-tooltip-${c}`),b=ref(),m=computed(()=>t.location.split(" ").length>1?t.location:t.location+" center"),O=computed(()=>t.origin==="auto"||t.origin==="overlap"||t.origin.split(" ").length>1||t.location.split(" ").length>1?t.origin:t.origin+" center"),N=computed(()=>t.transition?t.transition:n.value?"scale-transition":"fade-transition"),L=computed(()=>mergeProps({"aria-describedby":y.value},t.activatorProps));return useRender(()=>{const G=VOverlay.filterProps(t);return createVNode(VOverlay,mergeProps({ref:b,class:["v-tooltip",t.class],style:t.style,id:y.value},G,{modelValue:n.value,"onUpdate:modelValue":q=>n.value=q,transition:N.value,absolute:!0,location:m.value,origin:O.value,persistent:!0,role:"tooltip",activatorProps:L.value,_disableGlobalStack:!0},u),{activator:l.activator,default:function(){for(var q=arguments.length,J=new Array(q),fe=0;fe<q;fe++)J[fe]=arguments[fe];return l.default?.(...J)??t.text}})}),forwardRefs({},b)}}),_hoisted_1$k={key:0,class:"top-btn-list d-flex w-100 align-center py-1 ma-0 px-0 bg-prominent"},_hoisted_2$g={class:"d-flex align-center"},_sfc_main$r=defineComponent$1({__name:"TopBtnList",setup(t){const e=()=>{callCommand("MxLayerManager")},{mTopButtonBarData:l}=useTopButtonBarData(),n=useLayer(),{putCurrent:u,setValue:c,create:y}=n,{list:b,currentLayer:m}=storeToRefs(n),O=useLineType(),{createLineType:N}=O,{lineTypeList:L,currentLineType:G}=storeToRefs(O),q=useColor$1(),{createColor:J}=q,{currentSelectColor:fe,colorSelectList:ve}=storeToRefs(q),ne=(Te,Xe)=>customRef((ie,ue)=>{let pt=[];return MxFun.on("mxcadApplicationCreatedMxCADObject",()=>{MxCpp.getCurrentMxCAD().on("selectChange",Tt=>{pt=Tt,ue()}),onDatabaseInitialization(()=>{pt=[],ue()})}),{get(){return ie(),Te(pt,ie)},set(mt){Xe(mt,pt,ue)}}}),Ue=ne(Te=>{if(Te.length===0)return m.value;const Xe=Te[0].getMcDbEntity();return Xe?Te.length===1||Te.every(ie=>ie.getMcDbEntity()?.layer===Xe?.layer)?b.value.find(({name:ue})=>Xe.layer===ue):y({name:scopedTtranslate("*多种*")}):m.value},(Te,Xe,ie)=>{Xe.length===0?(m.value=Te,u(Te),ie()):(Xe.forEach(ue=>{const pt=ue.getMcDbEntity();pt&&Te&&(pt.layer=Te.name)}),MxCpp.getCurrentMxCAD().updateDisplay(),ie())}),De=ne(Te=>{if(Te.length===0)return G.value;const Xe=Te[0].getMcDbEntity();return Xe?Te.length===1||Te.every(ie=>ie.getMcDbEntity()?.linetype===Xe?.linetype)?L.value.find(({name:ue})=>Xe.linetype===ue):N({name:scopedTtranslate("*多种*")}):G.value},(Te,Xe,ie)=>{Xe.length===0?(G.value=Te,ie()):(Xe.forEach(ue=>{const pt=ue.getMcDbEntity();pt&&Te&&(pt.linetype=Te.name)}),MxCpp.getCurrentMxCAD().updateDisplay(),ie())}),Ve=ref(),rt=ne(Te=>{if(Te.length===0)return;const Xe=Te[0].getMcDbEntity();if(Xe)if(Te.length===1||Te.every(ie=>{const ue=ie.getMcDbEntity();if(!ue)return!1;const pt=getColorName(Xe.colorIndex)||Xe.trueColor.getColorString();return(getColorName(ue.colorIndex)||ue.trueColor.getColorString())===pt})){const ie=Xe.trueColor.method,ue=Xe.trueColor.getColorValue(Xe.layerId).replaceAll("0x","#"),pt=getColorName(Xe.colorIndex)||Xe.trueColor.getColorString(),mt=Xe.colorIndex,Tt=Xe.trueColor.n,It=(Ve.value?.getColorsList()||ve.value).find(nn=>pt===nn.name)||J({color:ue,name:pt,index:mt,method:ie,n:Tt});return Ve.value?.setColor(It),It}else{const ie=J({name:scopedTtranslate("*多种*")});return Ve.value?.setColor(ie),ie}},(Te,Xe,ie)=>{Xe.length===0?Te&&(fe.value=Te,ie()):(Xe.forEach(ue=>{const pt=ue.getMcDbEntity();if(pt&&Te){const mt=Color$1(Te.color),Tt=new McCmColor;Te.method===ColorMethod.kByBlock?Tt.method=ColorMethod.kByBlock:Te.method===ColorMethod.kByLayer?Tt.method=ColorMethod.kByLayer:Te.method===ColorMethod.kByACI?Tt.setColorIndex(Te.index):Tt.setRGB(mt.red(),mt.green(),mt.blue()),pt.trueColor=Tt}}),MxCpp.getCurrentMxCAD().updateDisplay(),Te&&Ve.value?.setColor(Te),ie())}),Ae=Te=>{Te.cmd&&callCommand(Te.cmd,Te)};return(Te,Xe)=>unref(uiConfig).isShowTopButtonBar?(openBlock(),createElementBlock("div",_hoisted_1$k,[createBaseVNode("div",_hoisted_2$g,[createVNode(VTooltip,{link:"",right:"","open-delay":700},{activator:withCtx(({props:ie})=>[createVNode(VBtn,mergeProps({class:"box pa-1 rounded-0 ml-1",size:"large",icon:"",density:"compact","max-width":"45",variant:"text"},ie,{onClick:e}),{default:withCtx(()=>[createVNode(VIcon,{icon:"tuceng",class:"",size:"x-large"})]),_:2},1040)]),default:withCtx(()=>[createBaseVNode("span",null,toDisplayString(Te.t("117")),1)]),_:1}),createVNode(SelectList,{ref_key:"selectListRef",ref:Ve,"layer-list":unref(b),"current-layer":unref(Ue),"onUpdate:currentLayer":Xe[0]||(Xe[0]=ie=>isRef(Ue)?Ue.value=ie:null),"line-type-list":unref(L),color:unref(rt),"onUpdate:color":Xe[1]||(Xe[1]=ie=>isRef(rt)?rt.value=ie:null),"current-line-type":unref(De),"onUpdate:currentLineType":Xe[2]||(Xe[2]=ie=>isRef(De)?De.value=ie:null),onSetLayerColor:Xe[3]||(Xe[3]=(ie,ue,pt)=>{unref(c)("color",ue,pt,!0)}),onSetLayerFreeze:Xe[4]||(Xe[4]=(ie,ue,pt)=>{unref(c)("freeze",ue,pt,!0)}),onSetLayerLock:Xe[5]||(Xe[5]=(ie,ue,pt)=>{unref(c)("lock",ue,pt,!0)}),onSetLayerVisible:Xe[6]||(Xe[6]=(ie,ue,pt)=>{unref(c)("visible",ue,pt,!0)}),onSetLayerPrint:Xe[7]||(Xe[7]=(ie,ue,pt)=>{unref(c)("print",ue,pt,!0)})},null,8,["layer-list","current-layer","line-type-list","color","current-line-type"]),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(l),(ie,ue)=>(openBlock(),createBlock(VTooltip,{key:ue,link:"","open-delay":700,text:Te.t(ie.prompt||"")},{activator:withCtx(({isActive:pt,props:mt})=>[createVNode(VBtn,mergeProps({ref_for:!0},mt,{size:"small",icon:ie.icon,variant:"text",class:"rounded-0",onClick:Tt=>Ae(ie)}),{default:withCtx(()=>[createVNode(VIcon,{size:"x-large"})]),_:2},1040,["icon","onClick"])]),_:2},1032,["text"]))),128))])])):createCommentVNode("",!0)}}),TopBtnList=_export_sfc$2(_sfc_main$r,[["__scopeId","data-v-5885f83f"]]),_sfc_main$q=defineComponent$1({__name:"index",props:{list:{default:()=>[]},location:{default:"left"}},emits:["change"],setup(t,{emit:e}){const l=e;return(n,u)=>(openBlock(),createBlock(VList,{class:"list d-flex"},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(n.list,(c,y)=>(openBlock(),createBlock(VTooltip,{key:y,link:"",location:n.location,"open-delay":"500",text:n.t(c.prompt||"")},{activator:withCtx(({isActive:b,props:m})=>[createVNode(VBtn,mergeProps({ref_for:!0},m,{size:"small",icon:"",variant:"text",class:[n.location+"-item","rounded-0"],onClick:O=>l("change",c)}),{default:withCtx(()=>[createVNode(VIcon,{size:"x-large",icon:c.icon,style:normalizeStyle(c.icon?.startsWith("class:")?"font-size: 22px":"")},null,8,["icon","style"])]),_:2},1040,["class","onClick"])]),_:2},1032,["location","text"]))),128))]),_:1}))}}),MxBtnList=_export_sfc$2(_sfc_main$q,[["__scopeId","data-v-74abcc69"]]),useTitleButtonBarData=()=>({mTitleButtonBarData:markRaw(uiConfig.mTitleButtonBarData||[])}),VCardActions=genericComponent()({name:"VCardActions",props:makeComponentProps(),setup(t,e){let{slots:l}=e;return provideDefaults({VBtn:{slim:!0,variant:"text"}}),useRender(()=>createVNode("div",{class:["v-card-actions",t.class],style:t.style},[l.default?.()])),{}}}),makeVCardSubtitleProps=propsFactory$1({opacity:[Number,String],...makeComponentProps(),...makeTagProps()},"VCardSubtitle"),VCardSubtitle=genericComponent()({name:"VCardSubtitle",props:makeVCardSubtitleProps(),setup(t,e){let{slots:l}=e;return useRender(()=>createVNode(t.tag,{class:["v-card-subtitle",t.class],style:[{"--v-card-subtitle-opacity":t.opacity},t.style]},l)),{}}}),VCardTitle=createSimpleFunctional("v-card-title"),makeCardItemProps=propsFactory$1({appendAvatar:String,appendIcon:IconValue$1,prependAvatar:String,prependIcon:IconValue$1,subtitle:[String,Number],title:[String,Number],...makeComponentProps(),...makeDensityProps()},"VCardItem"),VCardItem=genericComponent()({name:"VCardItem",props:makeCardItemProps(),setup(t,e){let{slots:l}=e;return useRender(()=>{const n=!!(t.prependAvatar||t.prependIcon),u=!!(n||l.prepend),c=!!(t.appendAvatar||t.appendIcon),y=!!(c||l.append),b=!!(t.title!=null||l.title),m=!!(t.subtitle!=null||l.subtitle);return createVNode("div",{class:["v-card-item",t.class],style:t.style},[u&&createVNode("div",{key:"prepend",class:"v-card-item__prepend"},[l.prepend?createVNode(VDefaultsProvider,{key:"prepend-defaults",disabled:!n,defaults:{VAvatar:{density:t.density,image:t.prependAvatar},VIcon:{density:t.density,icon:t.prependIcon}}},l.prepend):createVNode(Fragment,null,[t.prependAvatar&&createVNode(VAvatar,{key:"prepend-avatar",density:t.density,image:t.prependAvatar},null),t.prependIcon&&createVNode(VIcon,{key:"prepend-icon",density:t.density,icon:t.prependIcon},null)])]),createVNode("div",{class:"v-card-item__content"},[b&&createVNode(VCardTitle,{key:"title"},{default:()=>[l.title?.()??t.title]}),m&&createVNode(VCardSubtitle,{key:"subtitle"},{default:()=>[l.subtitle?.()??t.subtitle]}),l.default?.()]),y&&createVNode("div",{key:"append",class:"v-card-item__append"},[l.append?createVNode(VDefaultsProvider,{key:"append-defaults",disabled:!c,defaults:{VAvatar:{density:t.density,image:t.appendAvatar},VIcon:{density:t.density,icon:t.appendIcon}}},l.append):createVNode(Fragment,null,[t.appendIcon&&createVNode(VIcon,{key:"append-icon",density:t.density,icon:t.appendIcon},null),t.appendAvatar&&createVNode(VAvatar,{key:"append-avatar",density:t.density,image:t.appendAvatar},null)])])])}),{}}}),makeVCardTextProps=propsFactory$1({opacity:[Number,String],...makeComponentProps(),...makeTagProps()},"VCardText"),VCardText=genericComponent()({name:"VCardText",props:makeVCardTextProps(),setup(t,e){let{slots:l}=e;return useRender(()=>createVNode(t.tag,{class:["v-card-text",t.class],style:[{"--v-card-text-opacity":t.opacity},t.style]},l)),{}}}),makeVCardProps=propsFactory$1({appendAvatar:String,appendIcon:IconValue$1,disabled:Boolean,flat:Boolean,hover:Boolean,image:String,link:{type:Boolean,default:void 0},prependAvatar:String,prependIcon:IconValue$1,ripple:{type:[Boolean,Object],default:!0},subtitle:[String,Number],text:[String,Number],title:[String,Number],...makeBorderProps(),...makeComponentProps(),...makeDensityProps(),...makeDimensionProps(),...makeElevationProps(),...makeLoaderProps(),...makeLocationProps(),...makePositionProps(),...makeRoundedProps(),...makeRouterProps(),...makeTagProps(),...makeThemeProps(),...makeVariantProps({variant:"elevated"})},"VCard"),VCard=genericComponent()({name:"VCard",directives:{Ripple},props:makeVCardProps(),setup(t,e){let{attrs:l,slots:n}=e;const{themeClasses:u}=provideTheme(t),{borderClasses:c}=useBorder(t),{colorClasses:y,colorStyles:b,variantClasses:m}=useVariant(t),{densityClasses:O}=useDensity(t),{dimensionStyles:N}=useDimension(t),{elevationClasses:L}=useElevation(t),{loaderClasses:G}=useLoader(t),{locationStyles:q}=useLocation(t),{positionClasses:J}=usePosition(t),{roundedClasses:fe}=useRounded(t),ve=useLink(t,l),ne=computed(()=>t.link!==!1&&ve.isLink.value),Ue=computed(()=>!t.disabled&&t.link!==!1&&(t.link||ve.isClickable.value));return useRender(()=>{const De=ne.value?"a":t.tag,Ve=!!(n.title||t.title!=null),rt=!!(n.subtitle||t.subtitle!=null),Ae=Ve||rt,Te=!!(n.append||t.appendAvatar||t.appendIcon),Xe=!!(n.prepend||t.prependAvatar||t.prependIcon),ie=!!(n.image||t.image),ue=Ae||Xe||Te,pt=!!(n.text||t.text!=null);return withDirectives(createVNode(De,mergeProps({class:["v-card",{"v-card--disabled":t.disabled,"v-card--flat":t.flat,"v-card--hover":t.hover&&!(t.disabled||t.flat),"v-card--link":Ue.value},u.value,c.value,y.value,O.value,L.value,G.value,J.value,fe.value,m.value,t.class],style:[b.value,N.value,q.value,t.style],onClick:Ue.value&&ve.navigate,tabindex:t.disabled?-1:void 0},ve.linkProps),{default:()=>[ie&&createVNode("div",{key:"image",class:"v-card__image"},[n.image?createVNode(VDefaultsProvider,{key:"image-defaults",disabled:!t.image,defaults:{VImg:{cover:!0,src:t.image}}},n.image):createVNode(VImg,{key:"image-img",cover:!0,src:t.image},null)]),createVNode(LoaderSlot,{name:"v-card",active:!!t.loading,color:typeof t.loading=="boolean"?void 0:t.loading},{default:n.loader}),ue&&createVNode(VCardItem,{key:"item",prependAvatar:t.prependAvatar,prependIcon:t.prependIcon,title:t.title,subtitle:t.subtitle,appendAvatar:t.appendAvatar,appendIcon:t.appendIcon},{default:n.item,prepend:n.prepend,title:n.title,subtitle:n.subtitle,append:n.append}),pt&&createVNode(VCardText,{key:"text"},{default:()=>[n.text?.()??t.text]}),n.default?.(),n.actions&&createVNode(VCardActions,null,{default:n.actions}),genOverlays(Ue.value,"v-card")]}),[[resolveDirective("ripple"),Ue.value&&t.ripple]])}),{}}}),_hoisted_1$j={class:"w-100"},_hoisted_2$f={class:"d-flex"},_sfc_main$p=defineComponent$1({__name:"TitleButtonBar",emits:["change"],setup(t,{emit:e}){const{mTitleButtonBarData:l}=useTitleButtonBarData(),n=e;return(u,c)=>(openBlock(),createElementBlock("div",_hoisted_1$j,[unref(uiConfig).isShowTitleButtonBar?(openBlock(),createBlock(VCard,{key:0,class:"d-flex justify-space-between align-center pa-0 mb-0 w-100 mx-title-bar",style:{background:"transparent"},height:"40",elevation:"0"},{default:withCtx(()=>[createBaseVNode("div",_hoisted_2$f,[createVNode(MxBtnList,{class:"bg-background w-auto",location:"bottom",onChange:c[0]||(c[0]=y=>n("change",y)),list:unref(l)},null,8,["list"])])]),_:1})):createCommentVNode("",!0)]))}}),isWindows=navigator.platform.toLowerCase().includes("win")||navigator.userAgent.includes("Windows");class KeyBindingManager{constructor(){Pm(this,"keyBindingMap",new Map);Pm(this,"id",0);Pm(this,"isBound",!1);Pm(this,"handAction",async e=>{let l=!1;const n={isRunCommand:MxFun.isRunningCommand(),event:e};for(const u of this.keyBindingMap.values())if(isWindows&&u.winKey?this.isKeyMatch(u.winKey,e)&&(!u.when||await u.when(n))&&(l=!0):this.isKeyMatch(u.key,e)&&(!u.when||await u.when(n))&&(l=!0),l){u.isNoPreventDefault||e.preventDefault(),(u.key instanceof Array?u.key[0]?.keyCode!=="*":u.key.keyCode!=="*")&&console.log("匹配快捷键: ",u.winKey||u.key);try{u.action(e)}catch(c){console.warn(c)}break}});this.bindEvent()}register(e){const l=this.id;return this.keyBindingMap.set(l,e),this.id++,l}unregister(e){return this.keyBindingMap.delete(e)}registerWithHighPrior(e){const l=this.id,n=new Map;n.set(l,e);for(const[u,c]of this.keyBindingMap)n.set(u,c);return this.keyBindingMap=n,this.id++,l}bindEvent(){this.isBound||(this.isBound=!0,document.addEventListener("keydown",this.handAction,!0))}isKeyMatch(e,l){if(Array.isArray(e))return e.some(b=>this.isKeyMatch(b,l));if(e.keyCode=="*")return!0;const{ctrlKey:n=!1,shiftKey:u=!1,altKey:c=!1,metaKey:y=!1}=e;return n==l.ctrlKey&&u==l.shiftKey&&c==l.altKey&&y==l.metaKey&&e.keyCode==l.code}}const keyBindingManager=new KeyBindingManager,categoryToEntityPropMap=new Map;categoryToEntityPropMap.set("基础",[]);const defineRightDrawerUIProp=t=>{let{definePropRef:e,mxPropName:l,mcPropName:n,isShowTypes:u,isShow:c,valRef:y,...b}=t;const m=c||computed(()=>typeof u>"u"?!0:unref(u).some(q=>getIsType(q).value)),O=()=>console.warn("属性栏分栏:"+b.categoryName+"中名为"+b.label+"的属性"+(typeof n=="string"?n:"")+"未定义, 请检查代码!");if(typeof b.order>"u"&&(b.order=100),b.vSelectProps||(b.vSelectProps={}),b.onEvents||(b.onEvents={}),unref(b.type)==="select"&&!unref(b.vSelectProps).items&&(unref(b.vSelectProps).items=ref([])),isRef(b.vSelectProps)?b.vSelectProps.value=Object.assign({bgColor:"background"},b.vSelectProps.value):b.vSelectProps=Object.assign({bgColor:"background"},b.vSelectProps),unref(b.categoryName)||(isRef(b.categoryName)?b.categoryName.value="基础":b.categoryName="基础"),!y){let{defaultVal:q,MxClass:J,McClass:fe,everyMxcadFun:ve,everyMxdrawFun:ne,multipleCall:Ue,mxdrawGet:De,mxcadGet:Ve,mxcadSet:rt,mxdrawSet:Ae}=e||{};b.type==="select"&&(Ue||(Ue=()=>{typeof(isRef(b.vSelectProps.items)?b.vSelectProps.items.value:b.vSelectProps.items)[0]=="object"?y.value={[b.vSelectProps.itemTitle||"title"]:scopedTtranslate("760"),[b.vSelectProps.itemValue||"value"]:void 0}:y.value=scopedTtranslate("760")}));let Te;if(b.type==="color"){const{colorSelectList:Xe}=storeToRefs(useColor$1()),{createColor:ie}=useColor$1();Te=b.vSelectProps.items&&b.vSelectProps.items.length>0?isRef(b.vSelectProps.items)?b.vSelectProps.items:ref(b.vSelectProps.items):ref([...unref(Xe)]),Ue||(Ue=()=>{y.value=ie({name:scopedTtranslate("760")})}),Ve||(Ve=pt=>{const mt=Te.value.find(({index:Tt})=>pt?.colorIndex===Tt);if(mt)y.value=mt;else{const Tt=pt[n||"trueColor"];if(!Tt)return O();y.value=ie({index:Tt.colorIndex,name:Tt.getColorString(),color:Tt?toRGBCss(Tt):void 0})}}),De||(De=pt=>{let mt=pt[l];const Tt=new THREE.Color(mt);mt=Tt.getStyle();const kt=Te.value.find(It=>new THREE.Color(It.color).equals(Tt));kt?y.value=kt:y.value=ie({name:mt,color:mt})}),!rt&&n&&(rt=(pt,mt)=>{mt||(mt=y.value);const Tt=Color$1(mt.color),kt=createMxColor();mt.method===ColorMethod$1.kByBlock?kt.method=ColorMethod$1.kByBlock:mt.method===ColorMethod$1.kByLayer?kt.method=ColorMethod$1.kByLayer:mt.method===ColorMethod$1.kByACI?kt.setColorIndex(mt.index):kt.setRGB(Tt.red(),Tt.green(),Tt.blue()),pt[n]=kt}),!Ae&&l&&(Ae=(pt,mt)=>{mt||(mt=y.value),pt[l]=new THREE.Color(mt.color),pt.setNeedUpdateDisplay(!0)})}if(!ve&&n&&(ve=(Xe,ie)=>{if(n==="trueColor"){const ue=Xe[n],pt=ie[n];return ue.method!==ue.method?!1:ue.method===ColorMethod$1.kByACI?ue.colorIndex===pt.colorIndex:ue.method===ColorMethod$1.kByColor?ue.getColorValue()===pt.getColorValue():ue.method===ue.method}return Xe[n]===ie[n]}),!ne&&l&&(ne=(Xe,ie)=>l==="color"?Xe[l]&&Xe[l].equals&&Xe[l].equals(Xe[l]):Xe[l]===ie[l]),De||(De=Xe=>{const ie=Xe[l];y.value=ie}),!Ae&&l&&(Ae=(Xe,ie)=>{Xe[l]=ie}),Ve||(Ve=Xe=>{const ie=Xe[n];y.value=ie}),!rt&&n&&(rt=(Xe,ie)=>{Xe[n]=ie}),Ue||(Ue=()=>{y.value=scopedTtranslate("760")}),y=defineEntityProp(q||void 0,{MxClass:J,McClass:fe,everyMxcadFun:ve,everyMxdrawFun:ne,multipleCall:Ue,mxcadFun(Xe,ie){return Ve?Ve(Xe,ie):q},mxdrawFun(Xe,ie){return De?De(Xe,ie):q}},{mxcadFun(Xe,ie){rt&&rt(Xe,ie)},mxdrawFun(Xe,ie){Ae&&Ae(Xe,ie)}}),b.type==="color"){const{createColor:Xe}=useColor$1();if(b.vSelectProps||(b.vSelectProps={}),typeof y.value=="string"){const ue=new THREE.Color(y.value),pt=new McCmColor(ue.r,ue.g,ue.b);y.value=Xe(pt)}const ie=isRef(b.onColor)?b.onColor.value.bind({}):b.onColor?.bind({});b.onColor=()=>{callCommand("Mx_Color",{call:(ue,pt)=>{ie&&ie(ue);const mt=Xe({...countColorInfo(ue,pt)});Te.value.unshift(mt),y.value=mt},color:y.value})},b.vSelectProps=Object.assign({items:Te,bgColor:"background",menuProps:{maxHeight:"600"},returnObject:!0,itemTitle:"name",itemValue:"color",class:"rounded"},b.vSelectProps)}}const N=Object.assign(b,{ref:y,isShowRef:m}),L=isRef(b.categoryName)?b.categoryName.value:b.categoryName,G=categoryToEntityPropMap.get(L);if(G)G.push(N);else{const q=[N];categoryToEntityPropMap.set(L,q)}return N},useDefineUIProp=()=>{const t=computed(()=>{const e=Array.from(categoryToEntityPropMap.keys()).filter(n=>{const u=categoryToEntityPropMap.get(n);return u?u.some(c=>c.isShowRef.value):!1}),l=e.indexOf("自定义属性");if(l>=0){const n=e.splice(l,1)[0];e.push(n)}return e});return{defineRightDrawerUIProp,categoryNames:t,categoryToEntityPropMap}},defineCustomData=()=>defineRightDrawerUIProp({type:ref("input"),label:ref(""),disabled:ref(!1),valRef:ref(),getPoint:ref(),onColor:ref(),vSelectProps:{},inputProps:{},categoryName:ref("自定义属性"),order:ref(),isShow:ref(!1)});let customDataList=Array.from({length:5},()=>defineCustomData());const setCustomDataListLength=t=>{if(t<0)return;let e=t-customDataList.length;if(e<=0){for(let l=0;l===e;l--)customDataList.pop();return}for(let l=0;l<e;e++)defineCustomData()},getCustomDataList=()=>customDataList;var IVarType=(t=>(t[t.Number=1]="Number",t[t.Doubel=2]="Doubel",t[t.String=3]="String",t))(IVarType||{});const getVal=(t,e)=>{if(t)switch(e){case"string":return t;case"number":{const l=Number(t);return Number.isNaN(l)?void 0:l}case"boolean":return t==="true";case"undefined":return t;case"object":try{return JSON.parse(t)}catch{return}case"function":return}},getValString=(t,e)=>{switch(e){case"string":case"number":case"boolean":return t.toString();case"undefined":return;case"object":try{return JSON.stringify(t)}catch{return}case"function":return}};function browserCacheRef(t,e){const l=typeof t;return customRef((n,u)=>({get(){n();const c=localStorage.getItem(e),y=getVal(c,l);return typeof y<"u"?y:t},set(c){const y=getValString(c,l);typeof y<"u"&&localStorage.setItem(e,y),t=c,u()}}))}function browserCacheReactive(t,e){const l=typeof t;let n;try{const c=localStorage.getItem(e);c&&(n=JSON.parse(c))}catch{}typeof n=="object"&&(t=n);const u=reactive(t);for(let c in u)watch(()=>u[c],()=>{const y=getValString(u,l);typeof y<"u"&&localStorage.setItem(e,y)});return u}const cadNames={McDbLine:"直线",McDbPolyline:"多段线",McDbText:"单行文字",McDbMText:"多行文字",McDbCircle:"圆",McDbArc:"圆弧",McDbEllipse:"椭圆",McDbPoint:"点",McDbHatch:"填充",McDbBlockReference:"图块",McDbRasterImage:"图片",McDbAlignedDimension:"对齐尺寸",McDbRotatedDimension:"线性标注",McDb2LineAngularDimension:"角度标注"},annotationNames={ns:"长度测量",MxDbArea:"面积测量",MxDb2LineAngularDimension:"角度测量",MxDbCoord:"坐标测试",MxDbLeadComment:"引线标注",MxDbRectBoxLeadComment:"审图标注",MxDbCloudLine:"云线批注",MxDbShape:"形状批注"};let names=Object.assign({},cadNames,annotationNames);const useMcObject=t=>{const{type:e}=t;let l=t.getObjectName();return l=names[l]||l,{name:l,type:e,objId:t}},useSelect=t=>{const e=ref(t),l=ref(t[0]);return{selects:e,selectItem:l}},types=ref(["全部","CAD图形","批注图形"]),type=ref("全部"),isShowCADGraphics=computed(()=>type.value==="CAD图形"),isShowAnnotation=computed(()=>type.value==="批注图形"),isShowAll=computed(()=>type.value==="全部"),{selects:allSelects,selectItem}=useSelect(["全部"]);let selectsAllData={};const getData=t=>{const e=selectsAllData[allSelects.value[0]];if(!e)return{};const l=Object.keys(selectsAllData),n=l.shift();if(!n)return{};const u=Object.assign({},selectsAllData);delete u[n],l.forEach(y=>{const b=u[y][0].objId.getObjectName();typeof t>"u"||(t?cadNames[b]||delete u[y]:annotationNames[b]||delete u[y])});const c=e.filter(({type:y})=>{if(typeof t>"u"||y===McObjectIdType.kMxCAD&&t||y===McObjectIdType.kMxDraw&&!t)return!0;if(y===McObjectIdType.kInvalid)return!1});return c.length>0&&(u["全部("+c.length+")"]=c),u},selectAnnotationData=computed(()=>getData(!1)),selectCADGraphicsData=computed(()=>getData(!0)),selectsAnnotation=computed(()=>{const t=Object.keys(selectAnnotationData.value),e=t.pop();return e?(t.unshift(e),t):["无选择"]}),selectsCADGraphics=computed(()=>{const t=Object.keys(selectCADGraphicsData.value),e=t.pop();return e?(t.unshift(e),t):["无选择"]}),selectData=()=>isShowCADGraphics.value?selectCADGraphicsData.value:isShowAnnotation.value?selectAnnotationData.value:selectsAllData,getFirstSelectData=()=>selectData()[selectItem.value][0],isSelected=ref(!1),callNoSelect=()=>{isSelected.value=!1,allSelects.value=["无选择"],selectItem.value="无选择"};watch(isSelected,t=>{!t&&callNoSelect()});const selects=computed(()=>isShowCADGraphics.value?selectsCADGraphics.value:isShowAnnotation.value?selectsAnnotation.value:allSelects.value),isNotData=computed(()=>selects.value[0]==="无选择"),isMultipleChoices=()=>selects.value.includes("全部")&&selects.value.length>2,callEntityCallback=({type:t,objId:e},l,n,u)=>{const{MxClass:c,McClass:y}=u||{};if(t===McObjectIdType.kMxCAD){const b=e.getMcDbEntity();if(!b||y&&(Array.isArray(y)?y.every(m=>!(b instanceof m)):!(b instanceof y)))return;l.mxcadFun&&l.mxcadFun(b,n)}else{const b=e.getMxDbEntity();if(!b||c&&(Array.isArray(c)?c.every(m=>!(b instanceof m)):!(b instanceof c)))return;l.mxdrawFun&&l.mxdrawFun(b,n),b.setNeedUpdateDisplay()}},selectUpdateFun=(t,e,l)=>{isMultipleChoices()?selectsAllData[selects.value[0]].forEach(n=>{callEntityCallback(n,t,e,l)}):selectsAllData[selectItem.value].forEach(n=>{callEntityCallback(n,t,e,l)})},updateCalls=[];let isNoWatch=!1;const packFunNoWatch=t=>(...e)=>{isNoWatch=!0;const l=t(...e);return setTimeout(()=>{isNoWatch=!1}),l},defineEntityProp=(t,e,l)=>{const n=ref(t),u=e?.McClass,c=e?.MxClass;if(watch(n,(y,b)=>{isNoWatch||y!==b&&(l&&selectUpdateFun(l,y,{McClass:u,MxClass:c}),updateDisplay())}),e){let y=e;for(let b in y){const m=y[b];b!=="McClass"&&b!=="MxClass"&&typeof m=="function"&&(y[b]=packFunNoWatch(m))}updateCalls.push(e)}return n},updateCustomData=t=>{const e=[],l=t.map(({objId:y})=>(e.push(y),MxCpp.PropertiesWindow.getEntityProperties(y))),n=(y,b)=>{const m=[];for(let O=0;O<b.length;O++){const N=b[O];if(!N||N.length===0)return m;for(const L of N){let G=m.find((q,J)=>q.props.iVarType!==L.iVarType||q.props.isOnlyRead!==L.isOnlyRead||q.props.sVarName!==L.sVarName?!1:(q.props.val!==L.val&&q.props.val!==scopedTtranslate("760")&&(q.props.val=scopedTtranslate("760")),!0));G?G.ids.push(y[O]):m.push({props:L,ids:[y[O]]})}}return m.filter(({ids:O})=>O.length===y.length)},u=getCustomDataList(),c=n(e,l);u.forEach((y,b)=>{const m=c[b];if(!m||!m.props){y.isShowRef.value=!1,y.onEvents={};return}y&&((m.props.iVarType===IVarType.String||m.props.iVarType===IVarType.Number||m.props.iVarType===IVarType.Doubel)&&(isRef(y.type)&&(y.type.value="input"),y.onEvents={change(O){const N=O.target.value;m.ids.forEach(L=>{m.props.val=N,MxCpp.PropertiesWindow.setEntityProperties(L,m.props)})}}),isRef(y.label)&&(y.label.value=m.props.sVarName),y.ref.value=m.props.val,y.isShowRef.value=!0,isRef(y.disabled)&&(y.disabled.value=m.props.isOnlyRead))})},update$1=()=>{const t=selectsAllData[selectItem.value];if(!t)return;const e=t[0];e&&(updateCustomData(t),updateCalls.forEach(({mxcadFun:l,mxdrawFun:n,multipleCall:u,everyMxcadFun:c,everyMxdrawFun:y,McClass:b,MxClass:m})=>{requestIdleCallback(()=>{if(t.every(({type:N,objId:L},G)=>{if(N===McObjectIdType.kMxCAD){const q=L.getMcDbEntity();if(!q||b&&(Array.isArray(b)?b.every(J=>!(q instanceof J)):!(q instanceof b)))return!1;if(e.type===McObjectIdType.kMxCAD){const J=e.objId.getMcDbEntity();return J?c&&c(q,J,G):void 0}else if(e.type===McObjectIdType.kMxDraw)return!1}else if(N===McObjectIdType.kMxDraw){const q=L.getMxDbEntity();if(!q||m&&(Array.isArray(m)?m.every(J=>!(q instanceof J)):!(q instanceof m))||e.type===McObjectIdType.kMxCAD)return!1;if(e.type===McObjectIdType.kMxDraw){const J=e.objId.getMxDbEntity();return J?y&&y(q,J,G):void 0}}})||t.length<2){if(e.type===McObjectIdType.kMxCAD){const N=e.objId.getMcDbEntity();if(!N)return;if(b&&(Array.isArray(b)?b.every(L=>!(N instanceof L)):!(N instanceof b)))return!1;l&&l(N,void 0)}else if(e.type===McObjectIdType.kMxDraw){const N=e.objId.getMxDbEntity();if(!N)return;if(m&&(Array.isArray(m)?m.every(L=>!(N instanceof L)):!(N instanceof m)))return!1;n&&n(N,void 0)}}else u&&u()})}))};watch(type,()=>{selectItem.value=selects.value[0]});const name=computed(()=>{try{return selectItem.value.includes("全部")?selects.value.length>2?scopedTtranslate("760"):scopedTtranslate(selects.value[1].replace(/ *\([^)]*\) */g,"")):scopedTtranslate(selectItem.value.replace(/ *\([^)]*\) */g,""))}catch{return selectsAllData&&selectsAllData[selectItem.value]?selectsAllData[selectItem.value]?.length===1?selectsAllData[selectItem.value][0]?.name||scopedTtranslate("763"):selectsAllData[selectItem.value]?.length>1?scopedTtranslate("760"):scopedTtranslate("763"):scopedTtranslate("763")}}),getName=t=>t.split("(")[0],isTypeMap=new Map,getIsType=t=>{if(isTypeMap.has(t))return isTypeMap.get(t);{const e=computed(()=>{const l=getName(selectItem.value);try{return l===t||l==="全部"&&selects.value.length<3&&selects.value[1].split("(")[0]===t}catch{return!1}});return isTypeMap.set(t,e),e}},isText=getIsType("单行文字"),isMText=getIsType("多行文字"),isLine=getIsType("直线"),isPolyline=getIsType("多段线"),isCircle=getIsType("圆"),isArc=getIsType("圆弧"),isEllipse=getIsType("椭圆"),isBlock=getIsType("图块"),isMxcad=computed(()=>typeName.value==="CAD"),isMxdraw=computed(()=>typeName.value==="批注"),isMxDbArea=getIsType("面积测量"),isMxDbLeadComment=getIsType("引线标注"),typeName=defineEntityProp("",{everyMxcadFun(t,e){return t.getObjectID().type===e.getObjectID().type},multipleCall(){typeName.value=scopedTtranslate("760")},mxcadFun(){typeName.value="CAD"},mxdrawFun(){typeName.value="批注"}}),isShape=defineEntityProp(!1,{everyMxcadFun(){return!1},everyMxdrawFun(t,e){return t instanceof MxDbShape==e instanceof MxDbShape},multipleCall(){isShape.value=!1},mxdrawFun(t){isShape.value=t instanceof MxDbShape}}),isCurve=defineEntityProp(!1,{everyMxdrawFun(){return!1},everyMxcadFun(t,e){return t instanceof McDbCurve==e instanceof McDbCurve},multipleCall(){isShape.value=!1},mxcadFun(t){isCurve.value=t instanceof McDbCurve}}),isShowEntityAttribute=browserCacheRef(!1,"Mx_isShowEntityAttribute"),initEntityAttribute=()=>{MxFun.on("mxcadApplicationCreatedMxCADObject",t=>{let e,l,n=t.mxcad;onDatabaseInitialization(()=>{callNoSelect()}),n.on("selectChange",u=>{if(!isShowEntityAttribute.value)if(u.length===1&&u[0].isValid()){const y=u[0].getMcDbEntity(),b=u[0].getMxDbEntity();if(e instanceof McDbEntity&&y?.getHandle()===e.getHandle()||e instanceof MxDbEntity&&e.guid()===b?.guid()){if(e instanceof McDbMText||e instanceof McDbText)return;e=null,clearTimeout(l),isShowEntityAttribute.value=!0}else if(y||b){e=y||b,l&&clearTimeout(l),l=setTimeout(()=>{e=null},300);return}else return}else return;if(u.length===0)return;isSelected.value=!0;const c=u.map(y=>useMcObject(y));allSelects.value=["全部("+c.length+")"],selectsAllData={[selects.value[0]]:c};for(let y in names){const b=c.filter(m=>m.name===names[y]);if(b.length>0){const m=names[y]+`(${b.length})`;selects.value.push(m),selectsAllData[m]=b}}selectItem.value=selects.value[0],nextTick(()=>{update$1()})})})},useRightDrawer=()=>({types,type,isShowCADGraphics,isShowAnnotation,isShowAll,typeName,selectsAnnotation,selectsCADGraphics,isSelected,isNotData,isMxDbArea,isMxDbLeadComment,isShape,selects,selectItem,isMultipleChoices,callEntityCallback,selectUpdateFun,defineEntityProp,name,isText,isMText,isLine,isPolyline,isCircle,isArc,isEllipse,isBlock,isCurve,isMxcad,isMxdraw,update:update$1,packFunNoWatch,getFirstSelectData,getIsType,isShowEntityAttribute});keyBindingManager.register({key:{keyCode:"Delete"},when(t){if(t.isRunCommand)return!1;const e=MxCADUtility.getCurrentSelect();return e&&e.length>0&&e.some(l=>l.isValid())},action(){callCommand("Mx_Erase"),isShowEntityAttribute.value&&isSelected.value&&(isSelected.value=!1)}});const createRangeNaturalNumberArray=(t,e)=>Array.from({length:e-t+1},(l,n)=>t+n),getRetainDecimalPlaces=(t,e)=>Number(Number(t).toFixed(e)),isNoInput=()=>{const{inputEl:t}=storeToRefs(useFocus$1());return t.value===document.activeElement||document.activeElement?.tagName!=="INPUT"&&document.activeElement?.tagName!=="TEXTAREA"&&document.activeElement?.getAttribute("contenteditable")!=="true"},getClipboardVal=async()=>{let t,e,l=[];try{const n=await navigator.clipboard.read();for(const u of n)for(const c of u.types){const y=await u.getType(c);c==="text/plain"&&(t=await y.text()),c==="image/png"&&(e=URL.createObjectURL(y)),l.push({type:c,blob:y})}}catch(n){console.log(n)}return{text:t,imgUrl:e,blobs:l,isNoClipboardVal:l.length===0}};function generateRandomID(t=10){for(var e="",l="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",n=l.length,u=0;u<t;u++)e+=l.charAt(Math.floor(Math.random()*n));return e}const isStartShortcutCtrlCXVKey=ref(!0);addCommand("Mx_CopyClip",async()=>{let t=[];for(;t=MxCADUtility.getCurrentSelect(),!(t.length>0);){let e=new MxCADSelectionSet;if(!await e.userSelect(`
- `+scopedTtranslate("509"))||(t=e.getIds(),t.length==0))return;break}if(t.length>0){update(t);try{await navigator.clipboard.writeText("")}catch(e){useMessage().error(scopedTtranslate("510")),console.error(scopedTtranslate("510"),e)}}});addCommand("Mx_CutClip",async()=>{let t=[];for(;t=MxCADUtility.getCurrentSelect(),!(t.length>0);){let e=new MxCADSelectionSet;if(!await e.userSelect(`
- `+scopedTtranslate("511"))||(t=e.getIds(),t.length==0))return;break}t.length>0&&(update(t),aryId.forEach(e=>{e.erase()}))});addCommand("Mx_CopyBase",async()=>{let t=[];for(;t=MxCADUtility.getCurrentSelect(),!(t.length>0);){let e=new MxCADSelectionSet;if(!await e.userSelect(`
- `+scopedTtranslate("509"))||(t=e.getIds(),t.length==0))return;break}if(t.length>0){emptied();try{await navigator.clipboard.writeText("")}catch(l){useMessage().error(scopedTtranslate("510")),console.error(scopedTtranslate("510"),l)}const e=new MxCADUiPrPoint;e.setMessage(scopedTtranslate("437")),basePt=await e.go(),update(t,basePt)}});const paste=async(t=!1)=>{const e=new MxCADUiPrPoint;let{text:l,imgUrl:n}=await getClipboardVal();const u=MxCpp.getCurrentMxCAD();if(aryId.length>0){e.clearLastInputPoint(),e.setMessage(scopedTtranslate("512"));const{minPt:c,maxPt:y}=MxCADUtility.getMcDbEntitysBoundingBox(aryId)||{};if(!c||!y)return;e.setUserDraw((m,O)=>{if(aryId.length>30){const N=m.toVector3(),L=m.clone().addvec(y.sub(c)).toVector3();O.drawRect(N,L)}else aryId.forEach(N=>{const L=N.clone();L&&(L.move(basePt||c,m),O.drawMcDbEntity(L))})});const b=await e.go();if(!b)return;if(t){const m=u.getDatabase().getBlockTable();if(!blockId){let N=new McDbBlockTableRecord;blockId=m.add(N),N=blockId.getMcDbBlockTableRecord(),aryId.forEach(L=>{const G=L.clone();G&&N.appendAcDbEntity(G)}),N.origin=basePt||c,N.name="A*"+generateRandomID(8)}const O=new McDbBlockReference;O.blockTableRecordId=blockId,O.position=b,u.drawEntity(O),u.updateDisplay()}else aryId.forEach(m=>{const O=m.clone();O&&(O.move(basePt||c,b),u.drawEntity(O))});return}if(l){e.setMessage(scopedTtranslate("512")),e.clearLastInputPoint();const c=MxFun.viewCoordLong2Cad(16);let y=!1;/\r|\n/.test(l)&&(l=l.replaceAll(/\r|\n/g,"\\P"),y=!0);const b=O=>{if(y){const N=new McDbMText;return N.contents=l||"",N.textHeight=c,N.location=O,N.attachment=McDb.AttachmentPoint.kBottomLeft,N}else{const N=new McDbText;return N.textString=l||"",N.height=c,N.position=O,N.alignmentPoint=O,N}};e.setUserDraw((O,N)=>{N.drawMcDbEntity(b(O))});const m=await e.go();if(!m)return;MxCpp.getCurrentMxCAD().drawEntity(b(m))}else if(n){const c=MxCpp.getCurrentMxCAD();setTimeout(()=>{URL.revokeObjectURL(n)},5e3),c.loadImage(n,async y=>{if(!n||!y)return;e.clearLastInputPoint(),e.setMessage(scopedTtranslate("512")),e.setUserDraw((q,J)=>{const fe=q.toVector3();J.drawRect(fe,new THREE.Vector3(fe.x+y.width,fe.y+y.height))});const b=await e.go();if(!b)return;let m=1;e.setBasePt(b),e.setMessage(scopedTtranslate("513")),e.setUserDraw((q,J)=>{const fe=q.distanceTo(b)/y.width,ve=y.width*fe,ne=y.height*fe,Ue=new THREE.Vector3(b.x+ve,b.y+ne);J.drawRect(b.toVector3(),Ue)});const O=await e.go();if(!O)return;m=getRetainDecimalPlaces(O.distanceTo(b)/y.width,3);let N=0;const L=new MxCADUiPrAngle;L.clearLastInputPoint(),L.setMessage(scopedTtranslate("514")),L.setBasePt(b);const G=await L.go();typeof G=="number"&&(L.getDetailedResult()===DetailedResult.kCoordIn?N=getRetainDecimalPlaces(G,3):N=getRetainDecimalPlaces(G/(Math.PI/180),3),c.drawImage(b.x,b.y,y.width*m,y.height*m,N,n))})}};addCommand("Mx_PasteClip",()=>paste());addCommand("Mx_PasteBlock",()=>paste(!0));keyBindingManager.register({key:{keyCode:"KeyV",ctrlKey:!0},async when(){return isNoInput()&&isStartShortcutCtrlCXVKey.value},action(){callCommand("Mx_PasteClip")}});const onCopy=t=>{if(!isStartShortcutCtrlCXVKey.value)return;const e=t.clipboardData||window.clipboardData;e&&(window.getSelection()?.toString()||(t.preventDefault(),e.setData("text/plain","")))};document.addEventListener("copy",onCopy);document.addEventListener("cut",onCopy);keyBindingManager.register({key:{keyCode:"KeyC",ctrlKey:!0},async when(){return isNoInput()&&isStartShortcutCtrlCXVKey.value},action(){callCommand("Mx_CopyClip")}});keyBindingManager.register({key:{keyCode:"KeyX",ctrlKey:!0},async when(){return isNoInput()&&isStartShortcutCtrlCXVKey.value},action(){callCommand("Mx_CutClip")}});let aryId=[],basePt,blockId;const emptied=()=>{aryId=[],basePt=null,blockId=null},update=(t,e=null)=>{basePt=e,blockId=null,aryId=t},isCopyAryId=()=>aryId.length>0;keyBindingManager.register({key:{keyCode:"KeyC",ctrlKey:!0,shiftKey:!0},async when(){return isNoInput()&&isStartShortcutCtrlCXVKey.value},action(){callCommand("Mx_CopyBase")}});keyBindingManager.register({key:{keyCode:"KeyV",ctrlKey:!0,shiftKey:!0},async when(){return isNoInput()&&isStartShortcutCtrlCXVKey.value},action(){callCommand("Mx_PasteBlock")}});keyBindingManager.register({key:{keyCode:"KeyA",ctrlKey:!0},async when(){return isNoInput()},action(){callCommand("Mx_select_all")}});addCommand("Mx_select_all",()=>{const t=MxCpp.getCurrentMxCAD(),e=new MxCADSelectionSet;e.allSelect();const l=[];e.forEach(n=>{l.push(n)}),t.addCurrentSelect(l,l.length<30)});keyBindingManager.register({key:{keyCode:"KeyZ",ctrlKey:!0},async when(){return isNoInput()},action(){callCommand("Mx_Undo")}});keyBindingManager.register({key:{keyCode:"KeyY",ctrlKey:!0},async when(t){return t.isRunCommand?!1:isNoInput()},action(){callCommand("Mx_Redo")}});keyBindingManager.register({key:{keyCode:"KeyO",ctrlKey:!0},async when(){return isFullscreen()},action(){callCommand("OpenDwg")}});keyBindingManager.register({key:{keyCode:"KeyN",ctrlKey:!0},async when(){return isFullscreen()},action(){callCommand("Mx_NewFile")}});keyBindingManager.register({key:{keyCode:"KeyP",ctrlKey:!0},async when(){return isFullscreen()},action(){callCommand("Plot")}});keyBindingManager.register({key:{keyCode:"KeyS",ctrlKey:!0},action(){callCommand("Mx_QSave")}});const callEsc=()=>{if(!MxFun.isRunningCommand())return;const t=new KeyboardEvent("keydown",{bubbles:!0,cancelable:!0,keyCode:27,which:27});document.body?.dispatchEvent(t)};keyBindingManager.register({key:{keyCode:"F8"},action(){const e=getSysVarLongSketchSettings("ORTHOMODE")===Status.Off?Status.On:Status.Off;setSysVarLongSketchSettings("ORTHOMODE",e),MxFun.acutPrintf(`
- <${scopedTtranslate("360")} ${e===Status.On?scopedTtranslate("515"):scopedTtranslate("516")}>`),callEsc()}});keyBindingManager.register({key:{keyCode:"F7"},action(){const e=getSysVarLongSketchSettings("GRIDMODE")===Status.Off?Status.On:Status.Off;setSysVarLongSketchSettings("GRIDMODE",e),MxFun.acutPrintf(`
- <${scopedTtranslate("359")} ${e===Status.On?scopedTtranslate("515"):scopedTtranslate("516")}>`),callEsc()}});keyBindingManager.register({key:{keyCode:"F10"},action(){const e=getSysVarLongSketchSettings("AUTOSNAP")===Status.Off?Status.On:Status.Off;setSysVarLongSketchSettings("AUTOSNAP",e),MxFun.acutPrintf(`
- <${scopedTtranslate("361")} ${e===Status.On?scopedTtranslate("515"):scopedTtranslate("516")}>`),callEsc()}});keyBindingManager.register({key:{keyCode:"F11"},action(){const e=getSysVarLongSketchSettings("DYNTRACE")===Status.Off?Status.On:Status.Off;setSysVarLongSketchSettings("DYNTRACE",e),MxFun.acutPrintf(`
- <${scopedTtranslate("517")} ${e===Status.On?scopedTtranslate("515"):scopedTtranslate("516")}>`),callEsc()}});keyBindingManager.register({key:[{keyCode:"F3"},{keyCode:"F9"}],action(){const e=getSysVarLongSketchSettings("OSMODE")===Status.Off?Status.On:Status.Off;setSysVarLongSketchSettings("OSMODE",e),MxFun.acutPrintf(`
- <${scopedTtranslate("362")} ${e===Status.On?scopedTtranslate("515"):scopedTtranslate("516")}>`),callEsc()}});const keyToCode=t=>t.length===1?"Key"+t.toUpperCase():t.slice(0,1).toUpperCase()+t.slice(1),isAlt=useKeyModifier("Alt"),makeVToolbarTitleProps=propsFactory$1({text:String,...makeComponentProps(),...makeTagProps()},"VToolbarTitle"),VToolbarTitle=genericComponent()({name:"VToolbarTitle",props:makeVToolbarTitleProps(),setup(t,e){let{slots:l}=e;return useRender(()=>{const n=!!(l.default||l.text||t.text);return createVNode(t.tag,{class:["v-toolbar-title",t.class],style:t.style},{default:()=>[n&&createVNode("div",{class:"v-toolbar-title__placeholder"},[l.text?l.text():t.text,l.default?.()])]})}),{}}}),allowedDensities=[null,"prominent","default","comfortable","compact"],makeVToolbarProps=propsFactory$1({absolute:Boolean,collapse:Boolean,color:String,density:{type:String,default:"default",validator:t=>allowedDensities.includes(t)},extended:Boolean,extensionHeight:{type:[Number,String],default:48},flat:Boolean,floating:Boolean,height:{type:[Number,String],default:64},image:String,title:String,...makeBorderProps(),...makeComponentProps(),...makeElevationProps(),...makeRoundedProps(),...makeTagProps({tag:"header"}),...makeThemeProps()},"VToolbar"),VToolbar=genericComponent()({name:"VToolbar",props:makeVToolbarProps(),setup(t,e){let{slots:l}=e;const{backgroundColorClasses:n,backgroundColorStyles:u}=useBackgroundColor(toRef(t,"color")),{borderClasses:c}=useBorder(t),{elevationClasses:y}=useElevation(t),{roundedClasses:b}=useRounded(t),{themeClasses:m}=provideTheme(t),{rtlClasses:O}=useRtl(),N=shallowRef(!!(t.extended||l.extension?.())),L=computed(()=>parseInt(Number(t.height)+(t.density==="prominent"?Number(t.height):0)-(t.density==="comfortable"?8:0)-(t.density==="compact"?16:0),10)),G=computed(()=>N.value?parseInt(Number(t.extensionHeight)+(t.density==="prominent"?Number(t.extensionHeight):0)-(t.density==="comfortable"?4:0)-(t.density==="compact"?8:0),10):0);return provideDefaults({VBtn:{variant:"text"}}),useRender(()=>{const q=!!(t.title||l.title),J=!!(l.image||t.image),fe=l.extension?.();return N.value=!!(t.extended||fe),createVNode(t.tag,{class:["v-toolbar",{"v-toolbar--absolute":t.absolute,"v-toolbar--collapse":t.collapse,"v-toolbar--flat":t.flat,"v-toolbar--floating":t.floating,[`v-toolbar--density-${t.density}`]:!0},n.value,c.value,y.value,b.value,m.value,O.value,t.class],style:[u.value,t.style]},{default:()=>[J&&createVNode("div",{key:"image",class:"v-toolbar__image"},[l.image?createVNode(VDefaultsProvider,{key:"image-defaults",disabled:!t.image,defaults:{VImg:{cover:!0,src:t.image}}},l.image):createVNode(VImg,{key:"image-img",cover:!0,src:t.image},null)]),createVNode(VDefaultsProvider,{defaults:{VTabs:{height:convertToUnit(L.value)}}},{default:()=>[createVNode("div",{class:"v-toolbar__content",style:{height:convertToUnit(L.value)}},[l.prepend&&createVNode("div",{class:"v-toolbar__prepend"},[l.prepend?.()]),q&&createVNode(VToolbarTitle,{key:"title",text:t.title},{text:l.title}),l.default?.(),l.append&&createVNode("div",{class:"v-toolbar__append"},[l.append?.()])])]}),createVNode(VDefaultsProvider,{defaults:{VTabs:{height:convertToUnit(G.value)}}},{default:()=>[createVNode(VExpandTransition,null,{default:()=>[N.value&&createVNode("div",{class:"v-toolbar__extension",style:{height:convertToUnit(G.value)}},[fe])]})]})]})}),{contentHeight:L,extensionHeight:G}}}),makeScrollProps=propsFactory$1({scrollTarget:{type:String},scrollThreshold:{type:[String,Number],default:300}},"scroll");function useScroll(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{canScroll:l}=e;let n=0,u=0;const c=ref(null),y=shallowRef(0),b=shallowRef(0),m=shallowRef(0),O=shallowRef(!1),N=shallowRef(!1),L=computed(()=>Number(t.scrollThreshold)),G=computed(()=>clamp((L.value-y.value)/L.value||0)),q=()=>{const J=c.value;if(!J||l&&!l.value)return;n=y.value,y.value="window"in J?J.pageYOffset:J.scrollTop;const fe=J instanceof Window?document.documentElement.scrollHeight:J.scrollHeight;if(u!==fe){u=fe;return}N.value=y.value<n,m.value=Math.abs(y.value-L.value)};return watch(N,()=>{b.value=b.value||y.value}),watch(O,()=>{b.value=0}),onMounted(()=>{watch(()=>t.scrollTarget,J=>{const fe=J?document.querySelector(J):window;fe&&fe!==c.value&&(c.value?.removeEventListener("scroll",q),c.value=fe,c.value.addEventListener("scroll",q,{passive:!0}))},{immediate:!0})}),onBeforeUnmount(()=>{c.value?.removeEventListener("scroll",q)}),l&&watch(l,q,{immediate:!0}),{scrollThreshold:L,currentScroll:y,currentThreshold:m,isScrollActive:O,scrollRatio:G,isScrollingUp:N,savedScroll:b}}const makeVAppBarProps=propsFactory$1({scrollBehavior:String,modelValue:{type:Boolean,default:!0},location:{type:String,default:"top",validator:t=>["top","bottom"].includes(t)},...makeVToolbarProps(),...makeLayoutItemProps(),...makeScrollProps(),height:{type:[Number,String],default:64}},"VAppBar"),VAppBar=genericComponent()({name:"VAppBar",props:makeVAppBarProps(),emits:{"update:modelValue":t=>!0},setup(t,e){let{slots:l}=e;const n=ref(),u=useProxiedModel(t,"modelValue"),c=computed(()=>{const Ue=new Set(t.scrollBehavior?.split(" ")??[]);return{hide:Ue.has("hide"),fullyHide:Ue.has("fully-hide"),inverted:Ue.has("inverted"),collapse:Ue.has("collapse"),elevate:Ue.has("elevate"),fadeImage:Ue.has("fade-image")}}),y=computed(()=>{const Ue=c.value;return Ue.hide||Ue.fullyHide||Ue.inverted||Ue.collapse||Ue.elevate||Ue.fadeImage||!u.value}),{currentScroll:b,scrollThreshold:m,isScrollingUp:O,scrollRatio:N}=useScroll(t,{canScroll:y}),L=computed(()=>c.value.hide||c.value.fullyHide),G=computed(()=>t.collapse||c.value.collapse&&(c.value.inverted?N.value>0:N.value===0)),q=computed(()=>t.flat||c.value.fullyHide&&!u.value||c.value.elevate&&(c.value.inverted?b.value>0:b.value===0)),J=computed(()=>c.value.fadeImage?c.value.inverted?1-N.value:N.value:void 0),fe=computed(()=>{if(c.value.hide&&c.value.inverted)return 0;const Ue=n.value?.contentHeight??0,De=n.value?.extensionHeight??0;return L.value?b.value<m.value||c.value.fullyHide?Ue+De:Ue:Ue+De});useToggleScope(computed(()=>!!t.scrollBehavior),()=>{watchEffect(()=>{L.value?c.value.inverted?u.value=b.value>m.value:u.value=O.value||b.value<m.value:u.value=!0})});const{ssrBootStyles:ve}=useSsrBoot(),{layoutItemStyles:ne}=useLayoutItem({id:t.name,order:computed(()=>parseInt(t.order,10)),position:toRef(t,"location"),layoutSize:fe,elementSize:shallowRef(void 0),active:u,absolute:toRef(t,"absolute")});return useRender(()=>{const Ue=VToolbar.filterProps(t);return createVNode(VToolbar,mergeProps({ref:n,class:["v-app-bar",{"v-app-bar--bottom":t.location==="bottom"},t.class],style:[{...ne.value,"--v-toolbar-image-opacity":J.value,height:void 0,...ve.value},t.style]},Ue,{collapse:G.value,flat:q.value}),l)}),{}}}),VAlertTitle=createSimpleFunctional("v-alert-title"),allowedTypes=["success","info","warning","error"],makeVAlertProps=propsFactory$1({border:{type:[Boolean,String],validator:t=>typeof t=="boolean"||["top","end","bottom","start"].includes(t)},borderColor:String,closable:Boolean,closeIcon:{type:IconValue$1,default:"$close"},closeLabel:{type:String,default:"$vuetify.close"},icon:{type:[Boolean,String,Function,Object],default:null},modelValue:{type:Boolean,default:!0},prominent:Boolean,title:String,text:String,type:{type:String,validator:t=>allowedTypes.includes(t)},...makeComponentProps(),...makeDensityProps(),...makeDimensionProps(),...makeElevationProps(),...makeLocationProps(),...makePositionProps(),...makeRoundedProps(),...makeTagProps(),...makeThemeProps(),...makeVariantProps({variant:"flat"})},"VAlert"),VAlert=genericComponent()({name:"VAlert",props:makeVAlertProps(),emits:{"click:close":t=>!0,"update:modelValue":t=>!0},setup(t,e){let{emit:l,slots:n}=e;const u=useProxiedModel(t,"modelValue"),c=computed(()=>{if(t.icon!==!1)return t.type?t.icon??`$${t.type}`:t.icon}),y=computed(()=>({color:t.color??t.type,variant:t.variant})),{themeClasses:b}=provideTheme(t),{colorClasses:m,colorStyles:O,variantClasses:N}=useVariant(y),{densityClasses:L}=useDensity(t),{dimensionStyles:G}=useDimension(t),{elevationClasses:q}=useElevation(t),{locationStyles:J}=useLocation(t),{positionClasses:fe}=usePosition(t),{roundedClasses:ve}=useRounded(t),{textColorClasses:ne,textColorStyles:Ue}=useTextColor(toRef(t,"borderColor")),{t:De}=useLocale(),Ve=computed(()=>({"aria-label":De(t.closeLabel),onClick(rt){u.value=!1,l("click:close",rt)}}));return()=>{const rt=!!(n.prepend||c.value),Ae=!!(n.title||t.title),Te=!!(n.close||t.closable);return u.value&&createVNode(t.tag,{class:["v-alert",t.border&&{"v-alert--border":!!t.border,[`v-alert--border-${t.border===!0?"start":t.border}`]:!0},{"v-alert--prominent":t.prominent},b.value,m.value,L.value,q.value,fe.value,ve.value,N.value,t.class],style:[O.value,G.value,J.value,t.style],role:"alert"},{default:()=>[genOverlays(!1,"v-alert"),t.border&&createVNode("div",{key:"border",class:["v-alert__border",ne.value],style:Ue.value},null),rt&&createVNode("div",{key:"prepend",class:"v-alert__prepend"},[n.prepend?createVNode(VDefaultsProvider,{key:"prepend-defaults",disabled:!c.value,defaults:{VIcon:{density:t.density,icon:c.value,size:t.prominent?44:28}}},n.prepend):createVNode(VIcon,{key:"prepend-icon",density:t.density,icon:c.value,size:t.prominent?44:28},null)]),createVNode("div",{class:"v-alert__content"},[Ae&&createVNode(VAlertTitle,{key:"title"},{default:()=>[n.title?.()??t.title]}),n.text?.()??t.text,n.default?.()]),n.append&&createVNode("div",{key:"append",class:"v-alert__append"},[n.append()]),Te&&createVNode("div",{key:"close",class:"v-alert__close"},[n.close?createVNode(VDefaultsProvider,{key:"close-defaults",defaults:{VBtn:{icon:t.closeIcon,size:"x-small",variant:"text"}}},{default:()=>[n.close?.({props:Ve.value})]}):createVNode(VBtn,mergeProps({key:"close-btn",icon:t.closeIcon,size:"x-small",variant:"text"},Ve.value),null)])]})}}}),defaultFilter=(t,e,l)=>t==null||e==null?-1:t.toString().toLocaleLowerCase().indexOf(e.toString().toLocaleLowerCase()),makeFilterProps=propsFactory$1({customFilter:Function,customKeyFilter:Object,filterKeys:[Array,String],filterMode:{type:String,default:"intersection"},noFilter:Boolean},"filter");function filterItems(t,e,l){const n=[],u=l?.default??defaultFilter,c=l?.filterKeys?wrapInArray(l.filterKeys):!1,y=Object.keys(l?.customKeyFilter??{}).length;if(!t?.length)return n;e:for(let b=0;b<t.length;b++){const[m,O=m]=wrapInArray(t[b]),N={},L={};let G=-1;if((e||y>0)&&!l?.noFilter){if(typeof m=="object"){const fe=c||Object.keys(O);for(const ve of fe){const ne=getPropertyFromItem(O,ve),Ue=l?.customKeyFilter?.[ve];if(G=Ue?Ue(ne,e,m):u(ne,e,m),G!==-1&&G!==!1)Ue?N[ve]=G:L[ve]=G;else if(l?.filterMode==="every")continue e}}else G=u(m,e,m),G!==-1&&G!==!1&&(L.title=G);const q=Object.keys(L).length,J=Object.keys(N).length;if(!q&&!J||l?.filterMode==="union"&&J!==y&&!q||l?.filterMode==="intersection"&&(J!==y||!q))continue}n.push({index:b,matches:{...L,...N}})}return n}function useFilter(t,e,l,n){const u=ref([]),c=ref(new Map),y=computed(()=>n?.transform?unref(e).map(m=>[m,n.transform(m)]):unref(e));watchEffect(()=>{const m=typeof l=="function"?l():unref(l),O=typeof m!="string"&&typeof m!="number"?"":String(m),N=filterItems(y.value,O,{customKeyFilter:{...t.customKeyFilter,...unref(n?.customKeyFilter)},default:t.customFilter,filterKeys:t.filterKeys,filterMode:t.filterMode,noFilter:t.noFilter}),L=unref(e),G=[],q=new Map;N.forEach(J=>{let{index:fe,matches:ve}=J;const ne=L[fe];G.push(ne),q.set(ne.value,ve)}),u.value=G,c.value=q});function b(m){return c.value.get(m.value)}return{filteredItems:u,filteredMatches:c,getMatches:b}}const makeVSheetProps=propsFactory$1({color:String,...makeBorderProps(),...makeComponentProps(),...makeDimensionProps(),...makeElevationProps(),...makeLocationProps(),...makePositionProps(),...makeRoundedProps(),...makeTagProps(),...makeThemeProps()},"VSheet"),VSheet=genericComponent()({name:"VSheet",props:makeVSheetProps(),setup(t,e){let{slots:l}=e;const{themeClasses:n}=provideTheme(t),{backgroundColorClasses:u,backgroundColorStyles:c}=useBackgroundColor(toRef(t,"color")),{borderClasses:y}=useBorder(t),{dimensionStyles:b}=useDimension(t),{elevationClasses:m}=useElevation(t),{locationStyles:O}=useLocation(t),{positionClasses:N}=usePosition(t),{roundedClasses:L}=useRounded(t);return useRender(()=>createVNode(t.tag,{class:["v-sheet",n.value,u.value,y.value,m.value,N.value,L.value,t.class],style:[c.value,b.value,O.value,t.style]},l)),{}}});function highlightResult(t,e,l){if(e==null)return t;if(Array.isArray(e))throw new Error("Multiple matches is not implemented");return typeof e=="number"&&~e?createVNode(Fragment,null,[createVNode("span",{class:"v-combobox__unmask"},[t.substr(0,e)]),createVNode("span",{class:"v-combobox__mask"},[t.substr(e,l)]),createVNode("span",{class:"v-combobox__unmask"},[t.substr(e+l)])]):t}const makeVComboboxProps=propsFactory$1({autoSelectFirst:{type:[Boolean,String]},clearOnSelect:{type:Boolean,default:!0},delimiters:Array,...makeFilterProps({filterKeys:["title"]}),...makeSelectProps({hideNoData:!0,returnObject:!0}),...omit(makeVTextFieldProps({modelValue:null,role:"combobox"}),["validationValue","dirty","appendInnerIcon"]),...makeTransitionProps({transition:!1})},"VCombobox"),VCombobox=genericComponent()({name:"VCombobox",props:makeVComboboxProps(),emits:{"update:focused":t=>!0,"update:modelValue":t=>!0,"update:search":t=>!0,"update:menu":t=>!0},setup(t,e){let{emit:l,slots:n}=e;const{t:u}=useLocale(),c=ref(),y=shallowRef(!1),b=shallowRef(!0),m=shallowRef(!1),O=ref(),N=ref(),L=useProxiedModel(t,"menu"),G=computed({get:()=>L.value,set:Kn=>{L.value&&!Kn&&O.value?.ΨopenChildren.size||(L.value=Kn)}}),q=shallowRef(-1);let J=!1;const fe=computed(()=>c.value?.color),ve=computed(()=>G.value?t.closeText:t.openText),{items:ne,transformIn:Ue,transformOut:De}=useItems(t),{textColorClasses:Ve,textColorStyles:rt}=useTextColor(fe),Ae=useProxiedModel(t,"modelValue",[],Kn=>Ue(wrapInArray(Kn)),Kn=>{const Vn=De(Kn);return t.multiple?Vn:Vn[0]??null}),Te=useForm(),Xe=computed(()=>!!(t.chips||n.chip)),ie=computed(()=>Xe.value||!!n.selection),ue=shallowRef(!t.multiple&&!ie.value?Ae.value[0]?.title??"":""),pt=computed({get:()=>ue.value,set:Kn=>{if(ue.value=Kn??"",!t.multiple&&!ie.value&&(Ae.value=[transformItem$1(t,Kn)]),Kn&&t.multiple&&t.delimiters?.length){const Vn=Kn.split(new RegExp(`(?:${t.delimiters.join("|")})+`));Vn.length>1&&(Vn.forEach(Yn=>{Yn=Yn.trim(),Yn&&Xr(transformItem$1(t,Yn))}),ue.value="")}Kn||(q.value=-1),b.value=!Kn}}),mt=computed(()=>typeof t.counterValue=="function"?t.counterValue(Ae.value):typeof t.counterValue=="number"?t.counterValue:t.multiple?Ae.value.length:pt.value.length);watch(ue,Kn=>{J?nextTick(()=>J=!1):y.value&&!G.value&&(G.value=!0),l("update:search",Kn)}),watch(Ae,Kn=>{!t.multiple&&!ie.value&&(ue.value=Kn[0]?.title??"")});const{filteredItems:Tt,getMatches:kt}=useFilter(t,ne,()=>b.value?"":pt.value),It=computed(()=>t.hideSelected?Tt.value.filter(Kn=>!Ae.value.some(Vn=>Vn.value===Kn.value)):Tt.value),nn=computed(()=>Ae.value.map(Kn=>Kn.value)),tn=computed(()=>(t.autoSelectFirst===!0||t.autoSelectFirst==="exact"&&pt.value===It.value[0]?.title)&&It.value.length>0&&!b.value&&!m.value),pn=computed(()=>t.hideNoData&&!It.value.length||t.readonly||Te?.isReadonly.value),_n=ref(),Dn=useScrolling(_n,c);function an(Kn){J=!0,t.openOnClear&&(G.value=!0)}function Rn(){pn.value||(G.value=!0)}function Lt(Kn){pn.value||(y.value&&(Kn.preventDefault(),Kn.stopPropagation()),G.value=!G.value)}function wn(Kn){checkPrintable(Kn)&&c.value?.focus()}function hn(Kn){if(isComposingIgnoreKey(Kn)||t.readonly||Te?.isReadonly.value)return;const Vn=c.value.selectionStart,Yn=Ae.value.length;if((q.value>-1||["Enter","ArrowDown","ArrowUp"].includes(Kn.key))&&Kn.preventDefault(),["Enter","ArrowDown"].includes(Kn.key)&&(G.value=!0),["Escape"].includes(Kn.key)&&(G.value=!1),["Enter","Escape","Tab"].includes(Kn.key)&&(tn.value&&["Enter","Tab"].includes(Kn.key)&&!Ae.value.some(Vr=>{let{value:xi}=Vr;return xi===It.value[0].value})&&Xr(Tt.value[0]),b.value=!0),Kn.key==="ArrowDown"&&tn.value&&_n.value?.focus("next"),Kn.key==="Enter"&&pt.value&&(Xr(transformItem$1(t,pt.value)),ie.value&&(ue.value="")),["Backspace","Delete"].includes(Kn.key)){if(!t.multiple&&ie.value&&Ae.value.length>0&&!pt.value)return Xr(Ae.value[0],!1);if(~q.value){const Vr=q.value;Xr(Ae.value[q.value],!1),q.value=Vr>=Yn-1?Yn-2:Vr}else Kn.key==="Backspace"&&!pt.value&&(q.value=Yn-1)}if(t.multiple){if(Kn.key==="ArrowLeft"){if(q.value<0&&Vn>0)return;const Vr=q.value>-1?q.value-1:Yn-1;Ae.value[Vr]?q.value=Vr:(q.value=-1,c.value.setSelectionRange(pt.value.length,pt.value.length))}if(Kn.key==="ArrowRight"){if(q.value<0)return;const Vr=q.value+1;Ae.value[Vr]?q.value=Vr:(q.value=-1,c.value.setSelectionRange(0,0))}}}function xn(){t.eager&&N.value?.calculateVisibleItems()}function $n(){y.value&&(b.value=!0,c.value?.focus())}function Xr(Kn){let Vn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;if(!(!Kn||Kn.props.disabled))if(t.multiple){const Yn=Ae.value.findIndex(xi=>t.valueComparator(xi.value,Kn.value)),Vr=Vn??!~Yn;if(~Yn){const xi=Vr?[...Ae.value,Kn]:[...Ae.value];xi.splice(Yn,1),Ae.value=xi}else Vr&&(Ae.value=[...Ae.value,Kn]);t.clearOnSelect&&(pt.value="")}else{const Yn=Vn!==!1;Ae.value=Yn?[Kn]:[],ue.value=Yn&&!ie.value?Kn.title:"",nextTick(()=>{G.value=!1,b.value=!0})}}function ti(Kn){y.value=!0,setTimeout(()=>{m.value=!0})}function gn(Kn){m.value=!1}function Xn(Kn){(Kn==null||Kn===""&&!t.multiple&&!ie.value)&&(Ae.value=[])}return watch(y,(Kn,Vn)=>{if(!(Kn||Kn===Vn)&&(q.value=-1,G.value=!1,pt.value)){if(t.multiple){Xr(transformItem$1(t,pt.value));return}if(!ie.value)return;Ae.value.some(Yn=>{let{title:Vr}=Yn;return Vr===pt.value})?ue.value="":Xr(transformItem$1(t,pt.value))}}),watch(G,()=>{if(!t.hideSelected&&G.value&&Ae.value.length){const Kn=It.value.findIndex(Vn=>Ae.value.some(Yn=>t.valueComparator(Yn.value,Vn.value)));IN_BROWSER&&window.requestAnimationFrame(()=>{Kn>=0&&N.value?.scrollToIndex(Kn)})}}),watch(()=>t.items,(Kn,Vn)=>{G.value||y.value&&!Vn.length&&Kn.length&&(G.value=!0)}),useRender(()=>{const Kn=!!(!t.hideNoData||It.value.length||n["prepend-item"]||n["append-item"]||n["no-data"]),Vn=Ae.value.length>0,Yn=VTextField.filterProps(t);return createVNode(VTextField,mergeProps({ref:c},Yn,{modelValue:pt.value,"onUpdate:modelValue":[Vr=>pt.value=Vr,Xn],focused:y.value,"onUpdate:focused":Vr=>y.value=Vr,validationValue:Ae.externalValue,counterValue:mt.value,dirty:Vn,class:["v-combobox",{"v-combobox--active-menu":G.value,"v-combobox--chips":!!t.chips,"v-combobox--selection-slot":!!ie.value,"v-combobox--selecting-index":q.value>-1,[`v-combobox--${t.multiple?"multiple":"single"}`]:!0},t.class],style:t.style,readonly:t.readonly,placeholder:Vn?void 0:t.placeholder,"onClick:clear":an,"onMousedown:control":Rn,onKeydown:hn}),{...n,default:()=>createVNode(Fragment,null,[createVNode(VMenu,mergeProps({ref:O,modelValue:G.value,"onUpdate:modelValue":Vr=>G.value=Vr,activator:"parent",contentClass:"v-combobox__content",disabled:pn.value,eager:t.eager,maxHeight:310,openOnClick:!1,closeOnContentClick:!1,transition:t.transition,onAfterEnter:xn,onAfterLeave:$n},t.menuProps),{default:()=>[Kn&&createVNode(VList,mergeProps({ref:_n,selected:nn.value,selectStrategy:t.multiple?"independent":"single-independent",onMousedown:Vr=>Vr.preventDefault(),onKeydown:wn,onFocusin:ti,onFocusout:gn,tabindex:"-1","aria-live":"polite",color:t.itemColor??t.color},Dn,t.listProps),{default:()=>[n["prepend-item"]?.(),!It.value.length&&!t.hideNoData&&(n["no-data"]?.()??createVNode(VListItem,{title:u(t.noDataText)},null)),createVNode(VVirtualScroll,{ref:N,renderless:!0,items:It.value},{default:Vr=>{let{item:xi,index:Si,itemRef:qn}=Vr;const ia=mergeProps(xi.props,{ref:qn,key:Si,active:tn.value&&Si===0?!0:void 0,onClick:()=>Xr(xi,null)});return n.item?.({item:xi,index:Si,props:ia})??createVNode(VListItem,mergeProps(ia,{role:"option"}),{prepend:Wi=>{let{isSelected:ha}=Wi;return createVNode(Fragment,null,[t.multiple&&!t.hideSelected?createVNode(VCheckboxBtn,{key:xi.value,modelValue:ha,ripple:!1,tabindex:"-1"},null):void 0,xi.props.prependAvatar&&createVNode(VAvatar,{image:xi.props.prependAvatar},null),xi.props.prependIcon&&createVNode(VIcon,{icon:xi.props.prependIcon},null)])},title:()=>b.value?xi.title:highlightResult(xi.title,kt(xi)?.title,pt.value?.length??0)})}}),n["append-item"]?.()]})]}),Ae.value.map((Vr,xi)=>{function Si(ha){ha.stopPropagation(),ha.preventDefault(),Xr(Vr,!1)}const qn={"onClick:close":Si,onKeydown(ha){ha.key!=="Enter"&&ha.key!==" "||(ha.preventDefault(),ha.stopPropagation(),Si(ha))},onMousedown(ha){ha.preventDefault(),ha.stopPropagation()},modelValue:!0,"onUpdate:modelValue":void 0},ia=Xe.value?!!n.chip:!!n.selection,Wi=ia?ensureValidVNode(Xe.value?n.chip({item:Vr,index:xi,props:qn}):n.selection({item:Vr,index:xi})):void 0;if(!(ia&&!Wi))return createVNode("div",{key:Vr.value,class:["v-combobox__selection",xi===q.value&&["v-combobox__selection--selected",Ve.value]],style:xi===q.value?rt.value:{}},[Xe.value?n.chip?createVNode(VDefaultsProvider,{key:"chip-defaults",defaults:{VChip:{closable:t.closableChips,size:"small",text:Vr.title}}},{default:()=>[Wi]}):createVNode(VChip,mergeProps({key:"chip",closable:t.closableChips,size:"small",text:Vr.title,disabled:Vr.props.disabled},qn),null):Wi??createVNode("span",{class:"v-combobox__selection-text"},[Vr.title,t.multiple&&xi<Ae.value.length-1&&createVNode("span",{class:"v-combobox__selection-comma"},[createTextVNode(",")])])])})]),"append-inner":function(){for(var Vr=arguments.length,xi=new Array(Vr),Si=0;Si<Vr;Si++)xi[Si]=arguments[Si];return createVNode(Fragment,null,[n["append-inner"]?.(...xi),(!t.hideNoData||t.items.length)&&t.menuIcon?createVNode(VIcon,{class:"v-combobox__menu-icon",icon:t.menuIcon,onMousedown:Lt,onClick:noop$1,"aria-label":u(ve.value),title:u(ve.value),tabindex:"-1"},null):void 0])}})}),forwardRefs({isFocused:y,isPristine:b,menu:G,search:pt,selectionIndex:q,filteredItems:Tt,select:Xr},c)}});function useRefs(){const t=ref([]);onBeforeUpdate(()=>t.value=[]);function e(l,n){t.value[n]=l}return{refs:t,updateRef:e}}const makeVPaginationProps=propsFactory$1({activeColor:String,start:{type:[Number,String],default:1},modelValue:{type:Number,default:t=>t.start},disabled:Boolean,length:{type:[Number,String],default:1,validator:t=>t%1===0},totalVisible:[Number,String],firstIcon:{type:IconValue$1,default:"$first"},prevIcon:{type:IconValue$1,default:"$prev"},nextIcon:{type:IconValue$1,default:"$next"},lastIcon:{type:IconValue$1,default:"$last"},ariaLabel:{type:String,default:"$vuetify.pagination.ariaLabel.root"},pageAriaLabel:{type:String,default:"$vuetify.pagination.ariaLabel.page"},currentPageAriaLabel:{type:String,default:"$vuetify.pagination.ariaLabel.currentPage"},firstAriaLabel:{type:String,default:"$vuetify.pagination.ariaLabel.first"},previousAriaLabel:{type:String,default:"$vuetify.pagination.ariaLabel.previous"},nextAriaLabel:{type:String,default:"$vuetify.pagination.ariaLabel.next"},lastAriaLabel:{type:String,default:"$vuetify.pagination.ariaLabel.last"},ellipsis:{type:String,default:"..."},showFirstLastPage:Boolean,...makeBorderProps(),...makeComponentProps(),...makeDensityProps(),...makeElevationProps(),...makeRoundedProps(),...makeSizeProps(),...makeTagProps({tag:"nav"}),...makeThemeProps(),...makeVariantProps({variant:"text"})},"VPagination"),VPagination=genericComponent()({name:"VPagination",props:makeVPaginationProps(),emits:{"update:modelValue":t=>!0,first:t=>!0,prev:t=>!0,next:t=>!0,last:t=>!0},setup(t,e){let{slots:l,emit:n}=e;const u=useProxiedModel(t,"modelValue"),{t:c,n:y}=useLocale(),{isRtl:b}=useRtl(),{themeClasses:m}=provideTheme(t),{width:O}=useDisplay(),N=shallowRef(-1);provideDefaults(void 0,{scoped:!0});const{resizeRef:L}=useResizeObserver(Xe=>{if(!Xe.length)return;const{target:ie,contentRect:ue}=Xe[0],pt=ie.querySelector(".v-pagination__list > *");if(!pt)return;const mt=ue.width,Tt=pt.offsetWidth+parseFloat(getComputedStyle(pt).marginRight)*2;N.value=fe(mt,Tt)}),G=computed(()=>parseInt(t.length,10)),q=computed(()=>parseInt(t.start,10)),J=computed(()=>t.totalVisible!=null?parseInt(t.totalVisible,10):N.value>=0?N.value:fe(O.value,58));function fe(Xe,ie){const ue=t.showFirstLastPage?5:3;return Math.max(0,Math.floor(+((Xe-ie*ue)/ie).toFixed(2)))}const ve=computed(()=>{if(G.value<=0||isNaN(G.value)||G.value>Number.MAX_SAFE_INTEGER)return[];if(J.value<=0)return[];if(J.value===1)return[u.value];if(G.value<=J.value)return createRange(G.value,q.value);const Xe=J.value%2===0,ie=Xe?J.value/2:Math.floor(J.value/2),ue=Xe?ie:ie+1,pt=G.value-ie;if(ue-u.value>=0)return[...createRange(Math.max(1,J.value-1),q.value),t.ellipsis,G.value];if(u.value-pt>=(Xe?1:0)){const mt=J.value-1,Tt=G.value-mt+q.value;return[q.value,t.ellipsis,...createRange(mt,Tt)]}else{const mt=Math.max(1,J.value-3),Tt=mt===1?u.value:u.value-Math.ceil(mt/2)+q.value;return[q.value,t.ellipsis,...createRange(mt,Tt),t.ellipsis,G.value]}});function ne(Xe,ie,ue){Xe.preventDefault(),u.value=ie,ue&&n(ue,ie)}const{refs:Ue,updateRef:De}=useRefs();provideDefaults({VPaginationBtn:{color:toRef(t,"color"),border:toRef(t,"border"),density:toRef(t,"density"),size:toRef(t,"size"),variant:toRef(t,"variant"),rounded:toRef(t,"rounded"),elevation:toRef(t,"elevation")}});const Ve=computed(()=>ve.value.map((Xe,ie)=>{const ue=pt=>De(pt,ie);if(typeof Xe=="string")return{isActive:!1,key:`ellipsis-${ie}`,page:Xe,props:{ref:ue,ellipsis:!0,icon:!0,disabled:!0}};{const pt=Xe===u.value;return{isActive:pt,key:Xe,page:y(Xe),props:{ref:ue,ellipsis:!1,icon:!0,disabled:!!t.disabled||+t.length<2,color:pt?t.activeColor:t.color,"aria-current":pt,"aria-label":c(pt?t.currentPageAriaLabel:t.pageAriaLabel,Xe),onClick:mt=>ne(mt,Xe)}}}})),rt=computed(()=>{const Xe=!!t.disabled||u.value<=q.value,ie=!!t.disabled||u.value>=q.value+G.value-1;return{first:t.showFirstLastPage?{icon:b.value?t.lastIcon:t.firstIcon,onClick:ue=>ne(ue,q.value,"first"),disabled:Xe,"aria-label":c(t.firstAriaLabel),"aria-disabled":Xe}:void 0,prev:{icon:b.value?t.nextIcon:t.prevIcon,onClick:ue=>ne(ue,u.value-1,"prev"),disabled:Xe,"aria-label":c(t.previousAriaLabel),"aria-disabled":Xe},next:{icon:b.value?t.prevIcon:t.nextIcon,onClick:ue=>ne(ue,u.value+1,"next"),disabled:ie,"aria-label":c(t.nextAriaLabel),"aria-disabled":ie},last:t.showFirstLastPage?{icon:b.value?t.firstIcon:t.lastIcon,onClick:ue=>ne(ue,q.value+G.value-1,"last"),disabled:ie,"aria-label":c(t.lastAriaLabel),"aria-disabled":ie}:void 0}});function Ae(){const Xe=u.value-q.value;Ue.value[Xe]?.$el.focus()}function Te(Xe){Xe.key===keyValues.left&&!t.disabled&&u.value>+t.start?(u.value=u.value-1,nextTick(Ae)):Xe.key===keyValues.right&&!t.disabled&&u.value<q.value+G.value-1&&(u.value=u.value+1,nextTick(Ae))}return useRender(()=>createVNode(t.tag,{ref:L,class:["v-pagination",m.value,t.class],style:t.style,role:"navigation","aria-label":c(t.ariaLabel),onKeydown:Te,"data-test":"v-pagination-root"},{default:()=>[createVNode("ul",{class:"v-pagination__list"},[t.showFirstLastPage&&createVNode("li",{key:"first",class:"v-pagination__first","data-test":"v-pagination-first"},[l.first?l.first(rt.value.first):createVNode(VBtn,mergeProps({_as:"VPaginationBtn"},rt.value.first),null)]),createVNode("li",{key:"prev",class:"v-pagination__prev","data-test":"v-pagination-prev"},[l.prev?l.prev(rt.value.prev):createVNode(VBtn,mergeProps({_as:"VPaginationBtn"},rt.value.prev),null)]),Ve.value.map((Xe,ie)=>createVNode("li",{key:Xe.key,class:["v-pagination__item",{"v-pagination__item--is-active":Xe.isActive}],"data-test":"v-pagination-item"},[l.item?l.item(Xe):createVNode(VBtn,mergeProps({_as:"VPaginationBtn"},Xe.props),{default:()=>[Xe.page]})])),createVNode("li",{key:"next",class:"v-pagination__next","data-test":"v-pagination-next"},[l.next?l.next(rt.value.next):createVNode(VBtn,mergeProps({_as:"VPaginationBtn"},rt.value.next),null)]),t.showFirstLastPage&&createVNode("li",{key:"last",class:"v-pagination__last","data-test":"v-pagination-last"},[l.last?l.last(rt.value.last):createVNode(VBtn,mergeProps({_as:"VPaginationBtn"},rt.value.last),null)])])]})),{}}}),makeVTableProps=propsFactory$1({fixedHeader:Boolean,fixedFooter:Boolean,height:[Number,String],hover:Boolean,...makeComponentProps(),...makeDensityProps(),...makeTagProps(),...makeThemeProps()},"VTable"),VTable=genericComponent()({name:"VTable",props:makeVTableProps(),setup(t,e){let{slots:l,emit:n}=e;const{themeClasses:u}=provideTheme(t),{densityClasses:c}=useDensity(t);return useRender(()=>createVNode(t.tag,{class:["v-table",{"v-table--fixed-height":!!t.height,"v-table--fixed-header":t.fixedHeader,"v-table--fixed-footer":t.fixedFooter,"v-table--has-top":!!l.top,"v-table--has-bottom":!!l.bottom,"v-table--hover":t.hover},u.value,c.value,t.class],style:t.style},{default:()=>[l.top?.(),l.default?createVNode("div",{class:"v-table__wrapper",style:{height:convertToUnit(t.height)}},[createVNode("table",null,[l.default()])]):l.wrapper?.(),l.bottom?.()]})),{}}}),breakpointProps=breakpoints.reduce((t,e)=>(t[e]={type:[Boolean,String,Number],default:!1},t),{}),offsetProps=breakpoints.reduce((t,e)=>{const l="offset"+capitalize(e);return t[l]={type:[String,Number],default:null},t},{}),orderProps=breakpoints.reduce((t,e)=>{const l="order"+capitalize(e);return t[l]={type:[String,Number],default:null},t},{}),propMap$1={col:Object.keys(breakpointProps),offset:Object.keys(offsetProps),order:Object.keys(orderProps)};function breakpointClass$1(t,e,l){let n=t;if(!(l==null||l===!1)){if(e){const u=e.replace(t,"");n+=`-${u}`}return t==="col"&&(n="v-"+n),t==="col"&&(l===""||l===!0)||(n+=`-${l}`),n.toLowerCase()}}const ALIGN_SELF_VALUES=["auto","start","end","center","baseline","stretch"],makeVColProps=propsFactory$1({cols:{type:[Boolean,String,Number],default:!1},...breakpointProps,offset:{type:[String,Number],default:null},...offsetProps,order:{type:[String,Number],default:null},...orderProps,alignSelf:{type:String,default:null,validator:t=>ALIGN_SELF_VALUES.includes(t)},...makeComponentProps(),...makeTagProps()},"VCol"),VCol=genericComponent()({name:"VCol",props:makeVColProps(),setup(t,e){let{slots:l}=e;const n=computed(()=>{const u=[];let c;for(c in propMap$1)propMap$1[c].forEach(b=>{const m=t[b],O=breakpointClass$1(c,b,m);O&&u.push(O)});const y=u.some(b=>b.startsWith("v-col-"));return u.push({"v-col":!y||!t.cols,[`v-col-${t.cols}`]:t.cols,[`offset-${t.offset}`]:t.offset,[`order-${t.order}`]:t.order,[`align-self-${t.alignSelf}`]:t.alignSelf}),u});return()=>h(t.tag,{class:[n.value,t.class],style:t.style},l.default?.())}}),ALIGNMENT=["start","end","center"],SPACE=["space-between","space-around","space-evenly"];function makeRowProps(t,e){return breakpoints.reduce((l,n)=>{const u=t+capitalize(n);return l[u]=e(),l},{})}const ALIGN_VALUES=[...ALIGNMENT,"baseline","stretch"],alignValidator=t=>ALIGN_VALUES.includes(t),alignProps=makeRowProps("align",()=>({type:String,default:null,validator:alignValidator})),JUSTIFY_VALUES=[...ALIGNMENT,...SPACE],justifyValidator=t=>JUSTIFY_VALUES.includes(t),justifyProps=makeRowProps("justify",()=>({type:String,default:null,validator:justifyValidator})),ALIGN_CONTENT_VALUES=[...ALIGNMENT,...SPACE,"stretch"],alignContentValidator=t=>ALIGN_CONTENT_VALUES.includes(t),alignContentProps=makeRowProps("alignContent",()=>({type:String,default:null,validator:alignContentValidator})),propMap={align:Object.keys(alignProps),justify:Object.keys(justifyProps),alignContent:Object.keys(alignContentProps)},classMap={align:"align",justify:"justify",alignContent:"align-content"};function breakpointClass(t,e,l){let n=classMap[t];if(l!=null){if(e){const u=e.replace(t,"");n+=`-${u}`}return n+=`-${l}`,n.toLowerCase()}}const makeVRowProps=propsFactory$1({dense:Boolean,noGutters:Boolean,align:{type:String,default:null,validator:alignValidator},...alignProps,justify:{type:String,default:null,validator:justifyValidator},...justifyProps,alignContent:{type:String,default:null,validator:alignContentValidator},...alignContentProps,...makeComponentProps(),...makeTagProps()},"VRow"),VRow=genericComponent()({name:"VRow",props:makeVRowProps(),setup(t,e){let{slots:l}=e;const n=computed(()=>{const u=[];let c;for(c in propMap)propMap[c].forEach(y=>{const b=t[y],m=breakpointClass(c,y,b);m&&u.push(m)});return u.push({"v-row--no-gutters":t.noGutters,"v-row--dense":t.dense,[`align-${t.align}`]:t.align,[`justify-${t.justify}`]:t.justify,[`align-content-${t.alignContent}`]:t.alignContent}),u});return()=>h(t.tag,{class:["v-row",n.value,t.class],style:t.style},l.default?.())}}),VSpacer=createSimpleFunctional("v-spacer","div","VSpacer"),VExpansionPanelSymbol=Symbol.for("vuetify:v-expansion-panel"),makeVExpansionPanelTextProps=propsFactory$1({...makeComponentProps(),...makeLazyProps()},"VExpansionPanelText"),VExpansionPanelText=genericComponent()({name:"VExpansionPanelText",props:makeVExpansionPanelTextProps(),setup(t,e){let{slots:l}=e;const n=inject$1(VExpansionPanelSymbol);if(!n)throw new Error("[Vuetify] v-expansion-panel-text needs to be placed inside v-expansion-panel");const{hasContent:u,onAfterLeave:c}=useLazy(t,n.isSelected);return useRender(()=>createVNode(VExpandTransition,{onAfterLeave:c},{default:()=>[withDirectives(createVNode("div",{class:["v-expansion-panel-text",t.class],style:t.style},[l.default&&u.value&&createVNode("div",{class:"v-expansion-panel-text__wrapper"},[l.default?.()])]),[[vShow,n.isSelected.value]])]})),{}}}),makeVExpansionPanelTitleProps=propsFactory$1({color:String,expandIcon:{type:IconValue$1,default:"$expand"},collapseIcon:{type:IconValue$1,default:"$collapse"},hideActions:Boolean,focusable:Boolean,static:Boolean,ripple:{type:[Boolean,Object],default:!1},readonly:Boolean,...makeComponentProps(),...makeDimensionProps()},"VExpansionPanelTitle"),VExpansionPanelTitle=genericComponent()({name:"VExpansionPanelTitle",directives:{Ripple},props:makeVExpansionPanelTitleProps(),setup(t,e){let{slots:l}=e;const n=inject$1(VExpansionPanelSymbol);if(!n)throw new Error("[Vuetify] v-expansion-panel-title needs to be placed inside v-expansion-panel");const{backgroundColorClasses:u,backgroundColorStyles:c}=useBackgroundColor(t,"color"),{dimensionStyles:y}=useDimension(t),b=computed(()=>({collapseIcon:t.collapseIcon,disabled:n.disabled.value,expanded:n.isSelected.value,expandIcon:t.expandIcon,readonly:t.readonly})),m=computed(()=>n.isSelected.value?t.collapseIcon:t.expandIcon);return useRender(()=>withDirectives(createVNode("button",{class:["v-expansion-panel-title",{"v-expansion-panel-title--active":n.isSelected.value,"v-expansion-panel-title--focusable":t.focusable,"v-expansion-panel-title--static":t.static},u.value,t.class],style:[c.value,y.value,t.style],type:"button",tabindex:n.disabled.value?-1:void 0,disabled:n.disabled.value,"aria-expanded":n.isSelected.value,onClick:t.readonly?void 0:n.toggle},[createVNode("span",{class:"v-expansion-panel-title__overlay"},null),l.default?.(b.value),!t.hideActions&&createVNode(VDefaultsProvider,{defaults:{VIcon:{icon:m.value}}},{default:()=>[createVNode("span",{class:"v-expansion-panel-title__icon"},[l.actions?.(b.value)??createVNode(VIcon,null,null)])]})]),[[resolveDirective("ripple"),t.ripple]])),{}}}),makeVExpansionPanelProps=propsFactory$1({title:String,text:String,bgColor:String,...makeElevationProps(),...makeGroupItemProps(),...makeRoundedProps(),...makeTagProps(),...makeVExpansionPanelTitleProps(),...makeVExpansionPanelTextProps()},"VExpansionPanel"),VExpansionPanel=genericComponent()({name:"VExpansionPanel",props:makeVExpansionPanelProps(),emits:{"group:selected":t=>!0},setup(t,e){let{slots:l}=e;const n=useGroupItem(t,VExpansionPanelSymbol),{backgroundColorClasses:u,backgroundColorStyles:c}=useBackgroundColor(t,"bgColor"),{elevationClasses:y}=useElevation(t),{roundedClasses:b}=useRounded(t),m=computed(()=>n?.disabled.value||t.disabled),O=computed(()=>n.group.items.value.reduce((G,q,J)=>(n.group.selected.value.includes(q.id)&&G.push(J),G),[])),N=computed(()=>{const G=n.group.items.value.findIndex(q=>q.id===n.id);return!n.isSelected.value&&O.value.some(q=>q-G===1)}),L=computed(()=>{const G=n.group.items.value.findIndex(q=>q.id===n.id);return!n.isSelected.value&&O.value.some(q=>q-G===-1)});return provide(VExpansionPanelSymbol,n),useRender(()=>{const G=!!(l.text||t.text),q=!!(l.title||t.title),J=VExpansionPanelTitle.filterProps(t),fe=VExpansionPanelText.filterProps(t);return createVNode(t.tag,{class:["v-expansion-panel",{"v-expansion-panel--active":n.isSelected.value,"v-expansion-panel--before-active":N.value,"v-expansion-panel--after-active":L.value,"v-expansion-panel--disabled":m.value},b.value,u.value,t.class],style:[c.value,t.style]},{default:()=>[createVNode("div",{class:["v-expansion-panel__shadow",...y.value]},null),createVNode(VDefaultsProvider,{defaults:{VExpansionPanelTitle:{...J},VExpansionPanelText:{...fe}}},{default:()=>[q&&createVNode(VExpansionPanelTitle,{key:"title"},{default:()=>[l.title?l.title():t.title]}),G&&createVNode(VExpansionPanelText,{key:"text"},{default:()=>[l.text?l.text():t.text]}),l.default?.()]})]})}),{groupItem:n}}}),allowedVariants=["default","accordion","inset","popout"],makeVExpansionPanelsProps=propsFactory$1({flat:Boolean,...makeGroupProps(),...pick(makeVExpansionPanelProps(),["bgColor","collapseIcon","color","eager","elevation","expandIcon","focusable","hideActions","readonly","ripple","rounded","tile","static"]),...makeThemeProps(),...makeComponentProps(),...makeTagProps(),variant:{type:String,default:"default",validator:t=>allowedVariants.includes(t)}},"VExpansionPanels"),VExpansionPanels=genericComponent()({name:"VExpansionPanels",props:makeVExpansionPanelsProps(),emits:{"update:modelValue":t=>!0},setup(t,e){let{slots:l}=e;const{next:n,prev:u}=useGroup(t,VExpansionPanelSymbol),{themeClasses:c}=provideTheme(t),y=computed(()=>t.variant&&`v-expansion-panels--variant-${t.variant}`);return provideDefaults({VExpansionPanel:{bgColor:toRef(t,"bgColor"),collapseIcon:toRef(t,"collapseIcon"),color:toRef(t,"color"),eager:toRef(t,"eager"),elevation:toRef(t,"elevation"),expandIcon:toRef(t,"expandIcon"),focusable:toRef(t,"focusable"),hideActions:toRef(t,"hideActions"),readonly:toRef(t,"readonly"),ripple:toRef(t,"ripple"),rounded:toRef(t,"rounded"),static:toRef(t,"static")}}),useRender(()=>createVNode(t.tag,{class:["v-expansion-panels",{"v-expansion-panels--flat":t.flat,"v-expansion-panels--tile":t.tile},c.value,y.value,t.class],style:t.style},{default:()=>[l.default?.({prev:u,next:n})]})),{next:n,prev:u}}}),makeVFooterProps=propsFactory$1({app:Boolean,color:String,height:{type:[Number,String],default:"auto"},...makeBorderProps(),...makeComponentProps(),...makeElevationProps(),...makeLayoutItemProps(),...makeRoundedProps(),...makeTagProps({tag:"footer"}),...makeThemeProps()},"VFooter"),VFooter=genericComponent()({name:"VFooter",props:makeVFooterProps(),setup(t,e){let{slots:l}=e;const n=ref(),{themeClasses:u}=provideTheme(t),{backgroundColorClasses:c,backgroundColorStyles:y}=useBackgroundColor(toRef(t,"color")),{borderClasses:b}=useBorder(t),{elevationClasses:m}=useElevation(t),{roundedClasses:O}=useRounded(t),N=shallowRef(32),{resizeRef:L}=useResizeObserver(q=>{q.length&&(N.value=q[0].target.clientHeight)}),G=computed(()=>t.height==="auto"?N.value:parseInt(t.height,10));return useToggleScope(()=>t.app,()=>{const q=useLayoutItem({id:t.name,order:computed(()=>parseInt(t.order,10)),position:computed(()=>"bottom"),layoutSize:G,elementSize:computed(()=>t.height==="auto"?void 0:G.value),active:computed(()=>t.app),absolute:toRef(t,"absolute")});watchEffect(()=>{n.value=q.layoutItemStyles.value})}),useRender(()=>createVNode(t.tag,{ref:L,class:["v-footer",u.value,c.value,b.value,m.value,O.value,t.class],style:[y.value,t.app?n.value:{height:convertToUnit(t.height)},t.style]},l)),{}}}),makeVInfiniteScrollProps=propsFactory$1({color:String,direction:{type:String,default:"vertical",validator:t=>["vertical","horizontal"].includes(t)},side:{type:String,default:"end",validator:t=>["start","end","both"].includes(t)},mode:{type:String,default:"intersect",validator:t=>["intersect","manual"].includes(t)},margin:[Number,String],loadMoreText:{type:String,default:"$vuetify.infiniteScroll.loadMore"},emptyText:{type:String,default:"$vuetify.infiniteScroll.empty"},...makeDimensionProps(),...makeTagProps()},"VInfiniteScroll"),VInfiniteScrollIntersect=defineComponent({name:"VInfiniteScrollIntersect",props:{side:{type:String,required:!0},rootMargin:String},emits:{intersect:(t,e)=>!0},setup(t,e){let{emit:l}=e;const{intersectionRef:n,isIntersecting:u}=useIntersectionObserver();return watch(u,async c=>{l("intersect",t.side,c)}),useRender(()=>createVNode("div",{class:"v-infinite-scroll-intersect",style:{"--v-infinite-margin-size":t.rootMargin},ref:n},[createTextVNode(" ")])),{}}}),VInfiniteScroll=genericComponent()({name:"VInfiniteScroll",props:makeVInfiniteScrollProps(),emits:{load:t=>!0},setup(t,e){let{slots:l,emit:n}=e;const u=ref(),c=shallowRef("ok"),y=shallowRef("ok"),b=computed(()=>convertToUnit(t.margin)),m=shallowRef(!1);function O(rt){if(!u.value)return;const Ae=t.direction==="vertical"?"scrollTop":"scrollLeft";u.value[Ae]=rt}function N(){if(!u.value)return 0;const rt=t.direction==="vertical"?"scrollTop":"scrollLeft";return u.value[rt]}function L(){if(!u.value)return 0;const rt=t.direction==="vertical"?"scrollHeight":"scrollWidth";return u.value[rt]}function G(){if(!u.value)return 0;const rt=t.direction==="vertical"?"clientHeight":"clientWidth";return u.value[rt]}onMounted(()=>{u.value&&(t.side==="start"?O(L()):t.side==="both"&&O(L()/2-G()/2))});function q(rt,Ae){rt==="start"?c.value=Ae:rt==="end"&&(y.value=Ae)}function J(rt){return rt==="start"?c.value:y.value}let fe=0;function ve(rt,Ae){m.value=Ae,m.value&&ne(rt)}function ne(rt){if(t.mode!=="manual"&&!m.value)return;const Ae=J(rt);if(!u.value||["empty","loading"].includes(Ae))return;fe=L(),q(rt,"loading");function Te(Xe){q(rt,Xe),nextTick(()=>{Xe==="empty"||Xe==="error"||(Xe==="ok"&&rt==="start"&&O(L()-fe+N()),t.mode!=="manual"&&nextTick(()=>{window.requestAnimationFrame(()=>{window.requestAnimationFrame(()=>{window.requestAnimationFrame(()=>{ne(rt)})})})}))})}n("load",{side:rt,done:Te})}const{t:Ue}=useLocale();function De(rt,Ae){if(t.side!==rt&&t.side!=="both")return;const Te=()=>ne(rt),Xe={side:rt,props:{onClick:Te,color:t.color}};return Ae==="error"?l.error?.(Xe):Ae==="empty"?l.empty?.(Xe)??createVNode("div",null,[Ue(t.emptyText)]):t.mode==="manual"?Ae==="loading"?l.loading?.(Xe)??createVNode(VProgressCircular,{indeterminate:!0,color:t.color},null):l["load-more"]?.(Xe)??createVNode(VBtn,{variant:"outlined",color:t.color,onClick:Te},{default:()=>[Ue(t.loadMoreText)]}):l.loading?.(Xe)??createVNode(VProgressCircular,{indeterminate:!0,color:t.color},null)}const{dimensionStyles:Ve}=useDimension(t);useRender(()=>{const rt=t.tag,Ae=t.side==="start"||t.side==="both",Te=t.side==="end"||t.side==="both",Xe=t.mode==="intersect";return createVNode(rt,{ref:u,class:["v-infinite-scroll",`v-infinite-scroll--${t.direction}`,{"v-infinite-scroll--start":Ae,"v-infinite-scroll--end":Te}],style:Ve.value},{default:()=>[createVNode("div",{class:"v-infinite-scroll__side"},[De("start",c.value)]),Ae&&Xe&&createVNode(VInfiniteScrollIntersect,{key:"start",side:"start",onIntersect:ve,rootMargin:b.value},null),l.default?.(),Te&&Xe&&createVNode(VInfiniteScrollIntersect,{key:"end",side:"end",onIntersect:ve,rootMargin:b.value},null),createVNode("div",{class:"v-infinite-scroll__side"},[De("end",y.value)])]})})}}),makeVLayoutProps=propsFactory$1({...makeComponentProps(),...makeDimensionProps(),...makeLayoutProps()},"VLayout"),VLayout=genericComponent()({name:"VLayout",props:makeVLayoutProps(),setup(t,e){let{slots:l}=e;const{layoutClasses:n,layoutStyles:u,getLayoutItem:c,items:y,layoutRef:b}=createLayout(t),{dimensionStyles:m}=useDimension(t);return useRender(()=>createVNode("div",{ref:b,class:[n.value,t.class],style:[m.value,u.value,t.style]},[l.default?.()])),{getLayoutItem:c,items:y}}}),makeVMainProps=propsFactory$1({scrollable:Boolean,...makeComponentProps(),...makeDimensionProps(),...makeTagProps({tag:"main"})},"VMain"),VMain=genericComponent()({name:"VMain",props:makeVMainProps(),setup(t,e){let{slots:l}=e;const{dimensionStyles:n}=useDimension(t),{mainStyles:u}=useLayout(),{ssrBootStyles:c}=useSsrBoot();return useRender(()=>createVNode(t.tag,{class:["v-main",{"v-main--scrollable":t.scrollable},t.class],style:[u.value,c.value,n.value,t.style]},{default:()=>[t.scrollable?createVNode("div",{class:"v-main__scroller"},[l.default?.()]):l.default?.()]})),{}}});function useSticky(t){let{rootEl:e,isSticky:l,layoutItemStyles:n}=t;const u=shallowRef(!1),c=shallowRef(0),y=computed(()=>{const O=typeof u.value=="boolean"?"top":u.value;return[l.value?{top:"auto",bottom:"auto",height:void 0}:void 0,u.value?{[O]:convertToUnit(c.value)}:{top:n.value.top}]});onMounted(()=>{watch(l,O=>{O?window.addEventListener("scroll",m,{passive:!0}):window.removeEventListener("scroll",m)},{immediate:!0})}),onBeforeUnmount(()=>{window.removeEventListener("scroll",m)});let b=0;function m(){const O=b>window.scrollY?"up":"down",N=e.value.getBoundingClientRect(),L=parseFloat(n.value.top??0),G=window.scrollY-Math.max(0,c.value-L),q=N.height+Math.max(c.value,L)-window.scrollY-window.innerHeight,J=parseFloat(getComputedStyle(e.value).getPropertyValue("--v-body-scroll-y"))||0;N.height<window.innerHeight-L?(u.value="top",c.value=L):O==="up"&&u.value==="bottom"||O==="down"&&u.value==="top"?(c.value=window.scrollY+N.top-J,u.value=!0):O==="down"&&q<=0?(c.value=0,u.value="bottom"):O==="up"&&G<=0&&(J?u.value!=="top"&&(c.value=-G+J+L,u.value="top"):(c.value=N.top+G,u.value="top")),b=window.scrollY}return{isStuck:u,stickyStyles:y}}const HORIZON=100,HISTORY=20;function kineticEnergyToVelocity(t){return(t<0?-1:1)*Math.sqrt(Math.abs(t))*1.41421356237}function calculateImpulseVelocity(t){if(t.length<2)return 0;if(t.length===2)return t[1].t===t[0].t?0:(t[1].d-t[0].d)/(t[1].t-t[0].t);let e=0;for(let l=t.length-1;l>0;l--){if(t[l].t===t[l-1].t)continue;const n=kineticEnergyToVelocity(e),u=(t[l].d-t[l-1].d)/(t[l].t-t[l-1].t);e+=(u-n)*Math.abs(u),l===t.length-1&&(e*=.5)}return kineticEnergyToVelocity(e)*1e3}function useVelocity(){const t={};function e(u){Array.from(u.changedTouches).forEach(c=>{(t[c.identifier]??(t[c.identifier]=new CircularBuffer(HISTORY))).push([u.timeStamp,c])})}function l(u){Array.from(u.changedTouches).forEach(c=>{delete t[c.identifier]})}function n(u){const c=t[u]?.values().reverse();if(!c)throw new Error(`No samples for touch id ${u}`);const y=c[0],b=[],m=[];for(const O of c){if(y[0]-O[0]>HORIZON)break;b.push({t:O[0],d:O[1].clientX}),m.push({t:O[0],d:O[1].clientY})}return{x:calculateImpulseVelocity(b),y:calculateImpulseVelocity(m),get direction(){const{x:O,y:N}=this,[L,G]=[Math.abs(O),Math.abs(N)];return L>G&&O>=0?"right":L>G&&O<=0?"left":G>L&&N>=0?"down":G>L&&N<=0?"up":oops$1()}}}return{addMovement:e,endTouch:l,getVelocity:n}}function oops$1(){throw new Error}function useTouch(t){let{el:e,isActive:l,isTemporary:n,width:u,touchless:c,position:y}=t;onMounted(()=>{window.addEventListener("touchstart",Ue,{passive:!0}),window.addEventListener("touchmove",De,{passive:!1}),window.addEventListener("touchend",Ve,{passive:!0})}),onBeforeUnmount(()=>{window.removeEventListener("touchstart",Ue),window.removeEventListener("touchmove",De),window.removeEventListener("touchend",Ve)});const b=computed(()=>["left","right"].includes(y.value)),{addMovement:m,endTouch:O,getVelocity:N}=useVelocity();let L=!1;const G=shallowRef(!1),q=shallowRef(0),J=shallowRef(0);let fe;function ve(Ae,Te){return(y.value==="left"?Ae:y.value==="right"?document.documentElement.clientWidth-Ae:y.value==="top"?Ae:y.value==="bottom"?document.documentElement.clientHeight-Ae:oops())-(Te?u.value:0)}function ne(Ae){let Te=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;const Xe=y.value==="left"?(Ae-J.value)/u.value:y.value==="right"?(document.documentElement.clientWidth-Ae-J.value)/u.value:y.value==="top"?(Ae-J.value)/u.value:y.value==="bottom"?(document.documentElement.clientHeight-Ae-J.value)/u.value:oops();return Te?Math.max(0,Math.min(1,Xe)):Xe}function Ue(Ae){if(c.value)return;const Te=Ae.changedTouches[0].clientX,Xe=Ae.changedTouches[0].clientY,ie=25,ue=y.value==="left"?Te<ie:y.value==="right"?Te>document.documentElement.clientWidth-ie:y.value==="top"?Xe<ie:y.value==="bottom"?Xe>document.documentElement.clientHeight-ie:oops(),pt=l.value&&(y.value==="left"?Te<u.value:y.value==="right"?Te>document.documentElement.clientWidth-u.value:y.value==="top"?Xe<u.value:y.value==="bottom"?Xe>document.documentElement.clientHeight-u.value:oops());(ue||pt||l.value&&n.value)&&(fe=[Te,Xe],J.value=ve(b.value?Te:Xe,l.value),q.value=ne(b.value?Te:Xe),L=J.value>-20&&J.value<80,O(Ae),m(Ae))}function De(Ae){const Te=Ae.changedTouches[0].clientX,Xe=Ae.changedTouches[0].clientY;if(L){if(!Ae.cancelable){L=!1;return}const ue=Math.abs(Te-fe[0]),pt=Math.abs(Xe-fe[1]);(b.value?ue>pt&&ue>3:pt>ue&&pt>3)?(G.value=!0,L=!1):(b.value?pt:ue)>3&&(L=!1)}if(!G.value)return;Ae.preventDefault(),m(Ae);const ie=ne(b.value?Te:Xe,!1);q.value=Math.max(0,Math.min(1,ie)),ie>1?J.value=ve(b.value?Te:Xe,!0):ie<0&&(J.value=ve(b.value?Te:Xe,!1))}function Ve(Ae){if(L=!1,!G.value)return;m(Ae),G.value=!1;const Te=N(Ae.changedTouches[0].identifier),Xe=Math.abs(Te.x),ie=Math.abs(Te.y);(b.value?Xe>ie&&Xe>400:ie>Xe&&ie>3)?l.value=Te.direction===({left:"right",right:"left",top:"down",bottom:"up"}[y.value]||oops()):l.value=q.value>.5}const rt=computed(()=>G.value?{transform:y.value==="left"?`translateX(calc(-100% + ${q.value*u.value}px))`:y.value==="right"?`translateX(calc(100% - ${q.value*u.value}px))`:y.value==="top"?`translateY(calc(-100% + ${q.value*u.value}px))`:y.value==="bottom"?`translateY(calc(100% - ${q.value*u.value}px))`:oops(),transition:"none"}:void 0);return useToggleScope(G,()=>{const Ae=e.value?.style.transform??null,Te=e.value?.style.transition??null;watchEffect(()=>{e.value?.style.setProperty("transform",rt.value?.transform||"none"),e.value?.style.setProperty("transition",rt.value?.transition||null)}),onScopeDispose(()=>{e.value?.style.setProperty("transform",Ae),e.value?.style.setProperty("transition",Te)})}),{isDragging:G,dragProgress:q,dragStyles:rt}}function oops(){throw new Error}const locations=["start","end","left","right","top","bottom"],makeVNavigationDrawerProps=propsFactory$1({color:String,disableResizeWatcher:Boolean,disableRouteWatcher:Boolean,expandOnHover:Boolean,floating:Boolean,modelValue:{type:Boolean,default:null},permanent:Boolean,rail:{type:Boolean,default:null},railWidth:{type:[Number,String],default:56},scrim:{type:[Boolean,String],default:!0},image:String,temporary:Boolean,persistent:Boolean,touchless:Boolean,width:{type:[Number,String],default:256},location:{type:String,default:"start",validator:t=>locations.includes(t)},sticky:Boolean,...makeBorderProps(),...makeComponentProps(),...makeDelayProps(),...makeDisplayProps({mobile:null}),...makeElevationProps(),...makeLayoutItemProps(),...makeRoundedProps(),...makeTagProps({tag:"nav"}),...makeThemeProps()},"VNavigationDrawer"),VNavigationDrawer=genericComponent()({name:"VNavigationDrawer",props:makeVNavigationDrawerProps(),emits:{"update:modelValue":t=>!0,"update:rail":t=>!0},setup(t,e){let{attrs:l,emit:n,slots:u}=e;const{isRtl:c}=useRtl(),{themeClasses:y}=provideTheme(t),{borderClasses:b}=useBorder(t),{backgroundColorClasses:m,backgroundColorStyles:O}=useBackgroundColor(toRef(t,"color")),{elevationClasses:N}=useElevation(t),{displayClasses:L,mobile:G}=useDisplay(t),{roundedClasses:q}=useRounded(t),J=useRouter(),fe=useProxiedModel(t,"modelValue",null,an=>!!an),{ssrBootStyles:ve}=useSsrBoot(),{scopeId:ne}=useScopeId(),Ue=ref(),De=shallowRef(!1),{runOpenDelay:Ve,runCloseDelay:rt}=useDelay(t,an=>{De.value=an}),Ae=computed(()=>t.rail&&t.expandOnHover&&De.value?Number(t.width):Number(t.rail?t.railWidth:t.width)),Te=computed(()=>toPhysical(t.location,c.value)),Xe=computed(()=>t.persistent),ie=computed(()=>!t.permanent&&(G.value||t.temporary)),ue=computed(()=>t.sticky&&!ie.value&&Te.value!=="bottom");useToggleScope(()=>t.expandOnHover&&t.rail!=null,()=>{watch(De,an=>n("update:rail",!an))}),useToggleScope(()=>!t.disableResizeWatcher,()=>{watch(ie,an=>!t.permanent&&nextTick(()=>fe.value=!an))}),useToggleScope(()=>!t.disableRouteWatcher&&!!J,()=>{watch(J.currentRoute,()=>ie.value&&(fe.value=!1))}),watch(()=>t.permanent,an=>{an&&(fe.value=!0)}),t.modelValue==null&&!ie.value&&(fe.value=t.permanent||!G.value);const{isDragging:pt,dragProgress:mt}=useTouch({el:Ue,isActive:fe,isTemporary:ie,width:Ae,touchless:toRef(t,"touchless"),position:Te}),Tt=computed(()=>{const an=ie.value?0:t.rail&&t.expandOnHover?Number(t.railWidth):Ae.value;return pt.value?an*mt.value:an}),kt=computed(()=>["top","bottom"].includes(t.location)?0:Ae.value),{layoutItemStyles:It,layoutItemScrimStyles:nn}=useLayoutItem({id:t.name,order:computed(()=>parseInt(t.order,10)),position:Te,layoutSize:Tt,elementSize:kt,active:computed(()=>fe.value||pt.value),disableTransitions:computed(()=>pt.value),absolute:computed(()=>t.absolute||ue.value&&typeof tn.value!="string")}),{isStuck:tn,stickyStyles:pn}=useSticky({rootEl:Ue,isSticky:ue,layoutItemStyles:It}),_n=useBackgroundColor(computed(()=>typeof t.scrim=="string"?t.scrim:null)),Dn=computed(()=>({...pt.value?{opacity:mt.value*.2,transition:"none"}:void 0,...nn.value}));return provideDefaults({VList:{bgColor:"transparent"}}),useRender(()=>{const an=u.image||t.image;return createVNode(Fragment,null,[createVNode(t.tag,mergeProps({ref:Ue,onMouseenter:Ve,onMouseleave:rt,class:["v-navigation-drawer",`v-navigation-drawer--${Te.value}`,{"v-navigation-drawer--expand-on-hover":t.expandOnHover,"v-navigation-drawer--floating":t.floating,"v-navigation-drawer--is-hovering":De.value,"v-navigation-drawer--rail":t.rail,"v-navigation-drawer--temporary":ie.value,"v-navigation-drawer--persistent":Xe.value,"v-navigation-drawer--active":fe.value,"v-navigation-drawer--sticky":ue.value},y.value,m.value,b.value,L.value,N.value,q.value,t.class],style:[O.value,It.value,ve.value,pn.value,t.style,["top","bottom"].includes(Te.value)?{height:"auto"}:{}]},ne,l),{default:()=>[an&&createVNode("div",{key:"image",class:"v-navigation-drawer__img"},[u.image?createVNode(VDefaultsProvider,{key:"image-defaults",disabled:!t.image,defaults:{VImg:{alt:"",cover:!0,height:"inherit",src:t.image}}},u.image):createVNode(VImg,{key:"image-img",alt:"",cover:!0,height:"inherit",src:t.image},null)]),u.prepend&&createVNode("div",{class:"v-navigation-drawer__prepend"},[u.prepend?.()]),createVNode("div",{class:"v-navigation-drawer__content"},[u.default?.()]),u.append&&createVNode("div",{class:"v-navigation-drawer__append"},[u.append?.()])]}),createVNode(Transition,{name:"fade-transition"},{default:()=>[ie.value&&(pt.value||fe.value)&&!!t.scrim&&createVNode("div",mergeProps({class:["v-navigation-drawer__scrim",_n.backgroundColorClasses.value],style:[Dn.value,_n.backgroundColorStyles.value],onClick:()=>{Xe.value||(fe.value=!1)}},ne),null)]})])}),{isStuck:tn}}}),makeVRadioProps=propsFactory$1({...makeVSelectionControlProps({falseIcon:"$radioOff",trueIcon:"$radioOn"})},"VRadio"),VRadio=genericComponent()({name:"VRadio",props:makeVRadioProps(),setup(t,e){let{slots:l}=e;return useRender(()=>{const n=VSelectionControl.filterProps(t);return createVNode(VSelectionControl,mergeProps(n,{class:["v-radio",t.class],style:t.style,type:"radio"}),l)}),{}}}),makeVRadioGroupProps=propsFactory$1({height:{type:[Number,String],default:"auto"},...makeVInputProps(),...omit(makeSelectionControlGroupProps(),["multiple"]),trueIcon:{type:IconValue$1,default:"$radioOn"},falseIcon:{type:IconValue$1,default:"$radioOff"},type:{type:String,default:"radio"}},"VRadioGroup"),VRadioGroup=genericComponent()({name:"VRadioGroup",inheritAttrs:!1,props:makeVRadioGroupProps(),emits:{"update:modelValue":t=>!0},setup(t,e){let{attrs:l,slots:n}=e;const u=getUid(),c=computed(()=>t.id||`radio-group-${u}`),y=useProxiedModel(t,"modelValue");return useRender(()=>{const[b,m]=filterInputAttrs(l),O=VInput.filterProps(t),N=VSelectionControl.filterProps(t),L=n.label?n.label({label:t.label,props:{for:c.value}}):t.label;return createVNode(VInput,mergeProps({class:["v-radio-group",t.class],style:t.style},b,O,{modelValue:y.value,"onUpdate:modelValue":G=>y.value=G,id:c.value}),{...n,default:G=>{let{id:q,messagesId:J,isDisabled:fe,isReadonly:ve}=G;return createVNode(Fragment,null,[L&&createVNode(VLabel,{id:q.value},{default:()=>[L]}),createVNode(VSelectionControlGroup,mergeProps(N,{id:q.value,"aria-describedby":J.value,defaultsTarget:"VRadio",trueIcon:t.trueIcon,falseIcon:t.falseIcon,type:t.type,disabled:fe.value,readonly:ve.value,"aria-labelledby":L?q.value:void 0,multiple:!1},m,{modelValue:y.value,"onUpdate:modelValue":ne=>y.value=ne}),n)])}})}),{}}}),rootTypes={actions:"button@2",article:"heading, paragraph",avatar:"avatar",button:"button",card:"image, heading","card-avatar":"image, list-item-avatar",chip:"chip","date-picker":"list-item, heading, divider, date-picker-options, date-picker-days, actions","date-picker-options":"text, avatar@2","date-picker-days":"avatar@28",divider:"divider",heading:"heading",image:"image","list-item":"text","list-item-avatar":"avatar, text","list-item-two-line":"sentences","list-item-avatar-two-line":"avatar, sentences","list-item-three-line":"paragraph","list-item-avatar-three-line":"avatar, paragraph",ossein:"ossein",paragraph:"text@3",sentences:"text@2",subtitle:"text",table:"table-heading, table-thead, table-tbody, table-tfoot","table-heading":"chip, text","table-thead":"heading@6","table-tbody":"table-row-divider@6","table-row-divider":"table-row, divider","table-row":"text@6","table-tfoot":"text@2, avatar@2",text:"text"};function genBone(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return createVNode("div",{class:["v-skeleton-loader__bone",`v-skeleton-loader__${t}`]},[e])}function genBones(t){const[e,l]=t.split("@");return Array.from({length:l}).map(()=>genStructure(e))}function genStructure(t){let e=[];if(!t)return e;const l=rootTypes[t];if(t!==l){if(t.includes(","))return mapBones(t);if(t.includes("@"))return genBones(t);l.includes(",")?e=mapBones(l):l.includes("@")?e=genBones(l):l&&e.push(genStructure(l))}return[genBone(t,e)]}function mapBones(t){return t.replace(/\s/g,"").split(",").map(genStructure)}const makeVSkeletonLoaderProps=propsFactory$1({boilerplate:Boolean,color:String,loading:Boolean,loadingText:{type:String,default:"$vuetify.loading"},type:{type:[String,Array],default:"ossein"},...makeDimensionProps(),...makeElevationProps(),...makeThemeProps()},"VSkeletonLoader"),VSkeletonLoader=genericComponent()({name:"VSkeletonLoader",props:makeVSkeletonLoaderProps(),setup(t,e){let{slots:l}=e;const{backgroundColorClasses:n,backgroundColorStyles:u}=useBackgroundColor(toRef(t,"color")),{dimensionStyles:c}=useDimension(t),{elevationClasses:y}=useElevation(t),{themeClasses:b}=provideTheme(t),{t:m}=useLocale(),O=computed(()=>genStructure(wrapInArray(t.type).join(",")));return useRender(()=>{const N=!l.default||t.loading,L=t.boilerplate||!N?{}:{ariaLive:"polite",ariaLabel:m(t.loadingText),role:"alert"};return createVNode("div",mergeProps({class:["v-skeleton-loader",{"v-skeleton-loader--boilerplate":t.boilerplate},b.value,n.value,y.value],style:[u.value,N?c.value:{}]},L),[N?O.value:l.default?.()])}),{}}}),_hoisted_1$i={class:"text-decoration-underline"},_hoisted_2$e={class:"ellipsis-prefix"},_hoisted_3$a={class:"ellipsis-suffix"},_hoisted_4$8={class:"ellipsis-prefix"},_hoisted_5$7={class:"ellipsis-suffix"},__default__={name:"MxMenu"},_sfc_main$o=defineComponent$1({...__default__,props:{list:{default:()=>[]},title:{},isChildren:{type:Boolean,default:!1},cmd:{},icon:{}},emits:["change","onKeyShowMenu"],setup(t,{expose:e,emit:l}){const n=l,u=(N,L)=>{L&&(L.list&&L.list.length>0&&!L.cmd&&(N.stopImmediatePropagation(),N.preventDefault()),L.cmd&&(callCommand(L.cmd,L),L.commandOptions&&L.commandOptions.forEach(G=>{MxFun.setCommandLineInputData(G,13)})))},c={prefix:5,suffix:21,max:34},y=ref(!1),b=N=>{let L=extractLetter(N);if(L)return L=keyToCode(L),L};if(!t.isChildren&&t.title){const N=b(t.title);N&&keyBindingManager.register({key:[{keyCode:N,altKey:!0}],when(){return!0},action(){y.value=!y.value,y.value&&(n("onKeyShowMenu"),nextTick(()=>{m.value?.$el?.children[0]?.focus()}))}}),watch(y,L=>{const{setCommandFocus:G}=useFocus$1();G(!L)})}const m=ref();let O=[];return t.list.forEach(({list:N,cmd:L,tab:G,commandOptions:q})=>{if(!G||N)return;const J=b(G);if(!J)return;const fe=keyBindingManager.register({key:[{keyCode:J}],when(ve){return ve.isRunCommand?!1:y.value},action(){L&&callCommand(L),q&&q.forEach(ve=>{MxFun.setCommandLineInputData(ve,13)}),y.value=!1,keyBindingManager.unregister(fe)}});O.push(fe)}),onBeforeUnmount(()=>{O.forEach(N=>{keyBindingManager.unregister(N)})}),keyBindingManager.register({key:[{keyCode:"Enter"}],when(){return y.value},action(){y.value=!1}}),e({isShowMenu:y}),(N,L)=>{const G=resolveComponent("MxMenu");return openBlock(),createBlock(VMenu,{class:"mx-menu","offset-y":"",modelValue:y.value,"onUpdate:modelValue":L[1]||(L[1]=q=>y.value=q),"open-on-focus":!1},{activator:withCtx(({props:q})=>[N.title?renderSlot(N.$slots,"activator",normalizeProps(mergeProps({key:0},q)),()=>[N.isChildren?(openBlock(),createBlock(VListItem,mergeProps({key:1},q,{onClick:J=>u(J,q),variant:"outlined"}),{prepend:withCtx(()=>[createVNode(VIcon,{icon:q.icon,size:"x-small"},null,8,["icon"])]),append:withCtx(()=>[createVNode(VIcon,{icon:"$next",size:"20"})]),default:withCtx(()=>[q.tab&&q.tab.length>c.max?(openBlock(),createBlock(VListItemTitle,{key:0,class:"ellipsis-container"},{default:withCtx(()=>[createBaseVNode("span",_hoisted_2$e,toDisplayString(q.tab.slice(0,c.prefix)),1),L[2]||(L[2]=createBaseVNode("span",{class:"ellipsis-middle"},"...",-1)),createBaseVNode("span",_hoisted_3$a,toDisplayString(q.tab.slice(q.tab.length-c.suffix,q.tab.length)),1)]),_:2},1024)):(openBlock(),createBlock(VListItemTitle,{key:1},{default:withCtx(()=>[createTextVNode(toDisplayString(N.t("767",()=>unref(translateOnlyChinese)(q.tab))),1)]),_:2},1024))]),_:2},1040,["onClick"])):(openBlock(),createBlock(VChip,mergeProps({key:0,onClick:L[0]||(L[0]=J=>u(J,{cmd:N.cmd,list:N.list})),class:"px-4 mx-1",color:"accent",size:"x-small",variant:"elevated",label:""},q,{"prepend-icon":N.icon}),{default:withCtx(()=>[unref(isAlt)?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode("span",null,toDisplayString(unref(replaceI18n)(N.title,"start")),1),createBaseVNode("span",_hoisted_1$i,toDisplayString(unref(replaceI18n)(N.title,"end")),1)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(unref(translateOnlyChinese)(N.title)),1)],64))]),_:2},1040,["prepend-icon"]))],!0):createCommentVNode("",!0)]),default:withCtx(()=>[createVNode(unref(VList),{"min-width":"10",nav:"",class:"list",ref_key:"menuList",ref:m},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(N.list,(q,J)=>(openBlock(),createElementBlock(Fragment,{key:J},[q.type==="divider"?(openBlock(),createBlock(VDivider,{key:0,class:"border-opacity-25"})):q.list?(openBlock(),createBlock(G,{key:J,list:q.list,title:q.tab,isChildren:!0,submenu:"","open-on-hover":"","open-delay":0,location:"right center","activator-props":q},null,8,["list","title","activator-props"])):(openBlock(),createBlock(VListItem,{key:2,onClick:fe=>u(fe,q)},{prepend:withCtx(()=>[createVNode(VIcon,{icon:q.icon,size:"x-small"},null,8,["icon"])]),append:withCtx(()=>[createVNode(VIcon,{icon:q.endIcon,size:"x-small"},null,8,["icon"])]),default:withCtx(()=>[q.tab&&q.tab.length>c.max?(openBlock(),createBlock(VListItemTitle,{key:0,class:"ellipsis-container"},{default:withCtx(()=>[createBaseVNode("span",_hoisted_4$8,toDisplayString(q.tab.slice(0,c.prefix)),1),L[3]||(L[3]=createBaseVNode("span",{class:"ellipsis-middle"},"...",-1)),createBaseVNode("span",_hoisted_5$7,toDisplayString(q.tab.slice(q.tab.length-c.suffix,q.tab.length)),1)]),_:2},1024)):(openBlock(),createBlock(VListItemTitle,{key:1},{default:withCtx(()=>[createTextVNode(toDisplayString(N.t("767",()=>unref(translateOnlyChinese)(q.tab||""))),1)]),_:2},1024))]),_:2},1032,["onClick"]))],64))),128))]),_:1},512)]),_:3},8,["modelValue"])}}}),MxMenu=_export_sfc$2(_sfc_main$o,[["__scopeId","data-v-9eb7ac48"]]);let theme$1,isDark;const toggleTheme=()=>{const t=theme$1.global.current.value.dark?"light":"dark";theme$1.global.name.value=t,isDark.value=theme$1.global.name.value==="dark"},setIsDark=t=>theme$1.global.name.value=t?"dark":"light",useTheme=()=>(theme$1||(theme$1=useTheme$1()),isDark=useLocalStorage("mx-user-dark",!!localStorage.getItem("mx-user-dark")||!0),setIsDark(isDark.value),{toggleTheme,setIsDark,isDark}),height$1=computed(()=>{let t=120;return uiConfig.isShowHeader?(uiConfig.isShowHeaderTopBar||(t-=80),uiConfig.isShowTopButtonBar||(t-=52),uiConfig.isShowMenuBar||(t-=30),t):0}),useHeaderHeight=()=>height$1;let url;const getLogoImgSrc=()=>(url||(url=typeof uiConfig.logoImg=="string"?uiConfig.logoImg:new URL(""+new URL("logo-old-Bg387N4p.png",import.meta.url).href,import.meta.url).href),url),_hoisted_1$h={class:"tabs"},_hoisted_2$d=["onClick","data-index"],_hoisted_3$9=["data-index"],_hoisted_4$7=["data-index"],_hoisted_5$6=["data-index"],nameLength=5,_sfc_main$n=defineComponent$1({__name:"Tabs",setup(t){const{tabs:e,add:l,close:n,active:u}=useTabs(),{rightMenuOptions:c}=useTabRightClickMenu(),y=ref(),b=m=>{if(!y.value)return;const O=y.value,{scrollLeft:N,scrollWidth:L,clientWidth:G}=O,{deltaY:q}=m,J=L-G,fe=N+m.deltaY;(q<0&&fe>=0||q>0&&fe<=J)&&m.preventDefault(),O.scrollLeft=fe};return(m,O)=>{const N=resolveDirective("right-click-menu"),L=resolveDirective("scroll-bottom");return withDirectives((openBlock(),createElementBlock("div",{class:"tabs_box d-flex bg-background",onWheel:b,ref_key:"tabsBox",ref:y},[withDirectives((openBlock(),createElementBlock("ul",_hoisted_1$h,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(e),(G,q)=>(openBlock(),createBlock(VTooltip,{key:q,text:G.title,"data-index":q,location:"bottom","open-delay":"500"},{activator:withCtx(({props:J})=>[createBaseVNode("li",mergeProps({ref_for:!0},J,{class:["tab",G.active?"tab-active":""],onClick:fe=>unref(u)(q),"data-index":q}),[createBaseVNode("div",{class:"tab-title","data-index":q},[createBaseVNode("span",{class:"filename-base","data-index":q},toDisplayString(G.title.slice(0,G.title.length-nameLength)),9,_hoisted_4$7),createBaseVNode("span",{class:"filename-extension","data-index":q},toDisplayString(G.title.slice(G.title.length-nameLength,G.title.length)),9,_hoisted_5$6),createBaseVNode("span",null,toDisplayString(G.isDatabaseModify?"*":""),1)],8,_hoisted_3$9),createVNode(VBtn,{"data-index":q,icon:"",size:"16px",onClick:withModifiers(fe=>unref(n)(q),["stop"]),class:"tab-close-btn"},{default:withCtx(()=>[createVNode(VIcon,{icon:"$mdi-close",size:"x-small","data-index":q},null,8,["data-index"])]),_:2},1032,["data-index","onClick"])],16,_hoisted_2$d)]),_:2},1032,["text","data-index"]))),128))])),[[N,unref(c)]]),createVNode(VTooltip,{text:m.t("181"),location:"top","open-delay":"500"},{activator:withCtx(({props:G})=>[createVNode(VBtn,mergeProps(G,{size:"20px",class:"tab-add",onClick:O[0]||(O[0]=withModifiers(q=>unref(l)(),["stop"]))}),{default:withCtx(()=>[createVNode(VIcon,{icon:"$mdi-plus"})]),_:2},1040)]),_:1},8,["text"])],32)),[[L]])}}}),Tabs=_export_sfc$2(_sfc_main$n,[["__scopeId","data-v-94d7e823"]]);addCommand("Mx_open_file_options",async t=>{});addCommand("Mx_openRecordsFile",t=>{});const useMenusData=()=>({menuListData:uiConfig.mMenuBarData});var r=Symbol("VoerkaI18nVueProvider");function s(){return inject$1(r,{activeLanguage:"",defaultLanguage:"",languages:{}})}var v={install:(t,e)=>{let l=e.i18nScope;l===null&&console.warn("@voerkai18n/vue: i18nScope is not provided, use default i18nScope");let n=ref(l.global.activeLanguage);t.mixin({computed:{$activeLanguage:{get:()=>n.value,set:u=>{l.change(u).then(c=>n.value=c)}}}}),t.config.globalProperties.t=function(u,...c){return this.$activeLanguage,l.t(u,...c)},t.provide(r,reactive({activeLanguage:computed({get:()=>n.value,set:u=>l.global.change(u).then(()=>{n.value=u})}),languages:l.global.languages,defaultLanguage:l.global.defaultLanguage}))}};const _hoisted_1$g={class:"d-flex w-100 flex-column py-1 ma-0 px-0"},_hoisted_2$c={key:0,class:"d-flex align-center pa-1 bg-background mx-herder-top-box"},_hoisted_3$8={class:"mx-title mt-1 text-no-wrap text-truncate"},_hoisted_4$6={key:0,class:"text-truncate"},_hoisted_5$5={class:"d-flex align-center justify-center fill-height"},_hoisted_6$4={class:"w-100 mx-app-drag pa-0"},_hoisted_7$3={class:"d-flex",style:{height:"38px"}},_hoisted_8$3={key:0,class:"d-flex",style:{"z-index":"100000000"}},_hoisted_9$2={key:0,class:"d-flex mx-app-no-drag"},_hoisted_10$2={key:0,class:"d-flex px-1 align-center mb-1",style:{"flex-shrink":"0"}},_sfc_main$m=defineComponent$1({__name:"index",props:{show:{type:Boolean}},setup(t){const e=s();useMenusData();let l;const{toggleTheme:n,isDark:u}=useTheme(),c=rt=>{rt&&rt.cmd&&callCommand(rt.cmd,rt)},y=useHeaderHeight(),b=ref(uiConfig.headerTitle||"在线CAD梦想画图 "+getLargeVersion()),{fileName:m}=useFileName(),O=()=>{window.MxElectronAPI&&window.MxElectronAPI.winMainCose()},N=ref(!1);onMounted(async()=>{N.value=window.MxElectronAPI&&await window.MxElectronAPI.winIsMaximized()});const L=()=>{window.MxElectronAPI&&window.MxElectronAPI.winMainMax(),N.value=!N.value},G=()=>{window.MxElectronAPI&&window.MxElectronAPI.winMainMin(),N.value=!N.value},q=rt=>{rt.cmd&&callCommand(rt.cmd,rt)},J=ref(!1),fe=ref(),ve=()=>{fe.value?.$el.scrollWidth>fe.value?.$el.clientWidth?J.value=!0:J.value=!1};useEventListener("resize",ve);const ne=()=>fe.value?.$el.scrollBy(-100,0),Ue=()=>fe.value?.$el.scrollBy(100,0),De=ref();onMounted(()=>{ve()});const Ve=rt=>{De.value?.forEach((Ae,Te)=>{rt!==Te&&(Ae.isShowMenu=!1)})};return(rt,Ae)=>unref(uiConfig).isShowHeader?(openBlock(),createBlock(VAppBar,{key:0,height:unref(y),flat:"","clipped-left":"","clipped-right":"",class:"px-0",order:-1},{default:withCtx(()=>[createVNode(VSkeletonLoader,{type:"paragraph",class:"w-100",height:unref(y),loading:!rt.show},{default:withCtx(()=>[createBaseVNode("div",_hoisted_1$g,[unref(uiConfig).isShowHeaderTopBar?(openBlock(),createElementBlock("div",_hoisted_2$c,[createBaseVNode("h1",_hoisted_3$8,[createTextVNode(toDisplayString(rt.t("767",()=>unref(translateOnlyChinese)(b.value)))+" ",1),unref(uiConfig).isShowNameOCurrentlyOpenDrawing?(openBlock(),createElementBlock("span",_hoisted_4$6,toDisplayString(unref(m)),1)):createCommentVNode("",!0)]),unref(uiConfig).logoImg!==!1?(openBlock(),createBlock(VImg,{key:0,width:unref(y)<60||!unref(uiConfig).isShowMenuBar?30:60,transition:"false",height:unref(y)<60||!unref(uiConfig).isShowMenuBar?30:60,class:"mx-app-drag mr-2",src:unref(getLogoImgSrc)()},{placeholder:withCtx(()=>[createBaseVNode("div",_hoisted_5$5,[createVNode(VProgressCircular,{color:"grey-lighten-4",indeterminate:""})])]),_:1},8,["width","height","src"])):createCommentVNode("",!0),createBaseVNode("div",_hoisted_6$4,[createBaseVNode("div",_hoisted_7$3,[createVNode(_sfc_main$p,{class:"bg-background mx-app-drag",onChange:c}),unref(uiConfig).isShowHeaderTopBarRightBtns?(openBlock(),createElementBlock("div",_hoisted_8$3,[unref(uiConfig).headerTopBarRightBtns?.includes("ai")?(openBlock(),createBlock(VTooltip,{key:0,link:"",text:rt.t("113"),"open-delay":700},{activator:withCtx(({props:Te})=>[createVNode(VBtn,mergeProps(Te,{size:"38px",class:"text-medium-emphasis",theme:unref(u)?"dark":"light",icon:"class:iconfont AI",onClick:Ae[0]||(Ae[0]=Xe=>unref(callCommand)("Mx_Ai"))}),null,16,["theme"])]),_:1},8,["text"])):createCommentVNode("",!0),unref(isElectron)()?(openBlock(),createBlock(VTooltip,{key:1,link:"",text:rt.t("114"),"open-delay":700},{activator:withCtx(({props:Te})=>[createVNode(VBtn,mergeProps(Te,{size:"38px",class:"text-medium-emphasis",icon:"class:iconfont denglu",theme:unref(u)?"dark":"light",id:"mx_login_btn"}),null,16,["theme"])]),_:1},8,["text"])):createCommentVNode("",!0),unref(uiConfig).headerTopBarRightBtns?.includes("language")?(openBlock(),createBlock(VMenu,{key:2},{activator:withCtx(({props:Te})=>[createVNode(VTooltip,{link:"",text:rt.t("115"),"open-delay":700},{activator:withCtx(({props:Xe})=>[createVNode(VBtn,mergeProps({...Xe,...Te},{size:"38px",class:"text-medium-emphasis",theme:unref(u)?"dark":"light",icon:"$mdi-language"}),null,16,["theme"])]),_:2},1032,["text"])]),default:withCtx(()=>[createVNode(VList,null,{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(e).languages,Te=>(openBlock(),createBlock(VListItem,{onClick:Xe=>{unref(e).activeLanguage=Te.name,unref(l)&&unref(l)(Te.name)},active:unref(e).activeLanguage===Te.name},{default:withCtx(()=>[createVNode(VListItemTitle,null,{default:withCtx(()=>[createTextVNode(toDisplayString(Te.title),1)]),_:2},1024)]),_:2},1032,["onClick","active"]))),256))]),_:1})]),_:1})):createCommentVNode("",!0),unref(uiConfig).headerTopBarRightBtns?.includes("theme")?(openBlock(),createBlock(VTooltip,{key:3,link:"",text:rt.t("116"),"open-delay":700},{activator:withCtx(({props:Te})=>[createVNode(VBtn,mergeProps(Te,{class:"text-medium-emphasis",size:"38px",theme:unref(u)?"dark":"light",icon:unref(u)?"$mdi-weather-night":"$mdi-weather-sunny",onClick:unref(n)}),null,16,["theme","icon","onClick"])]),_:1},8,["text"])):createCommentVNode("",!0),unref(isElectron)()?(openBlock(),createElementBlock(Fragment,{key:4},[createVNode(VBtn,{icon:"$mdi-window-minimize",size:"38px",onClick:G}),createVNode(VBtn,{icon:N.value?"$mdi-window-restore":"$mdi-window-maximize",size:"38px",onClick:L},null,8,["icon"]),createVNode(VBtn,{icon:"$mdi-window-close",class:"window-close",onClick:O,size:"38px"})],64)):createCommentVNode("",!0)])):createCommentVNode("",!0)]),unref(uiConfig).isShowMenuBar?(openBlock(),createElementBlock("div",_hoisted_9$2,[createVNode(unref(VCard),{style:{background:"transparent","white-space":"nowrap",flex:"1 1 auto","scroll-behavior":"smooth"},width:"0",height:"30",class:"px-0 mb-0",elevation:"0",onScroll:ve,ref_key:"mxMenuBox",ref:fe},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(uiConfig).mMenuBarData||[],(Te,Xe)=>(openBlock(),createBlock(MxMenu,{key:Xe,cmd:Te.cmd,onClick:ie=>q(Te),onOnKeyShowMenu:()=>{Ve(Xe)},list:Te.list,title:Te.tab,icon:Te.icon,ref_for:!0,ref_key:"menus",ref:De},null,8,["cmd","onClick","onOnKeyShowMenu","list","title","icon"]))),128))]),_:1},512),J.value?(openBlock(),createElementBlock("div",_hoisted_10$2,[createVNode(VChip,{class:"scroll_bnt mr-1",onClick:ne},{default:withCtx(()=>Ae[1]||(Ae[1]=[createTextVNode("<")])),_:1}),createVNode(VChip,{class:"scroll_bnt",onClick:Ue},{default:withCtx(()=>Ae[2]||(Ae[2]=[createTextVNode(">")])),_:1})])):createCommentVNode("",!0)])):createCommentVNode("",!0)])])):createCommentVNode("",!0),unref(isElectron)()?(openBlock(),createBlock(Tabs,{key:1})):createCommentVNode("",!0),createVNode(TopBtnList)])]),_:1},8,["height","loading"])]),_:1},8,["height"])):createCommentVNode("",!0)}}),Header=_export_sfc$2(_sfc_main$m,[["__scopeId","data-v-a0467523"]]),isFirstTimeOpen=customRef((t,e)=>({get(){return t(),uiConfig?.isPriorityLoadingUi?!0:!uiConfig?.isShowSkeletonLoader},set(l){uiConfig.isShowSkeletonLoader=!l,e()}})),isLoadOpenDrawing=ref(!1);let calls=[];onOpenFileComplete(async()=>{isLoadOpenDrawing.value===!1&&(await registerPlugins$1(!0),calls.forEach(t=>{t()})),isFirstTimeOpen.value=!0,isLoadOpenDrawing.value=!0});const onFirstTimeOpenComplete=t=>{calls.push(t)},useFirstTimeOpenDwg=()=>({isLoadOpenDrawing,isFirstTimeOpen,onFirstTimeOpenComplete}),commandText=ref(""),consoleText=ref(""),cmdTip=ref("命令:"),coordinates=ref("0, 0, 0");function parseCmdTip(t){const e=/(.+)\[(.+)\]/,l=t.match(e);if(l){const n=l[1].trim(),c=l[2].split("/").map(b=>b.trim());return{msg:n,keys:c.map(b=>({label:b.substring(0,b.indexOf("(")),key:b.substring(b.indexOf("(")+1,b.indexOf(")"))})),endMsg:":"}}return{msg:t}}const useCommandLine=t=>{const{onFirstTimeOpenComplete:e}=useFirstTimeOpenDwg(),{setInputEl:l,setCommandFocus:n}=useFocus$1(),u=J=>{MxFun.setCommandLineInputData(commandText.value,J.keyCode)},c=J=>{MxFun.setCommandLineInputData(J,13)},y=watch(t,J=>{if(!J)return;const fe=t.value.$el.getElementsByTagName("input")[0];fe&&(l(fe),fe.focus()),MxFun.listenForCommandLineInput(({msCmdTip:ve,msCmdDisplay:ne,msCmdText:Ue})=>{commandText.value=Ue,consoleText.value=translateOnlyChinese(ne),cmdTip.value=ve}),MxFun.listenForCoordTip(ve=>{coordinates.value=ve}),y()}),b=computed(()=>parseCmdTip(cmdTip.value)),m=ref(!1),O=J=>{m.value&&c(J)},N=J=>{J=J.replaceAll(" ",""),comboboxItems.value.includes(J)||MxFun.isRunningCommand()||J===""?m.value=!1:m.value=!!J},L=J=>{MxFun.isRunningCommand()&&(m.value=!1),(!(J.code==="ArrowDown"||J.code==="ArrowUp")||!m.value)&&u(J),(J.code==="Enter"||J.code==="Escape"||J.code==="Space")&&((J.code==="Enter"||J.code==="Space")&&nextTick(()=>{commandText.value=""}),m.value=!1),comboboxItems.value.includes(commandText.value)&&(m.value=!1)},G={},q=J=>{const fe=G[J];return fe?J+"("+scopedTtranslate(fe)+")":J};return e(async()=>{let J=await fetchUiConfig()||{};J.mLeftButtonBarData&&J.mLeftButtonBarData.buttonBarData&&J.mLeftButtonBarData.buttonBarData.forEach(({cmd:ve,prompt:ne})=>{ve&&(G[ve]=ne,addCmdRecord(ve))}),J.mMenuBarData&&J.mMenuBarData.forEach(({cmd:ve,tab:ne})=>{ve&&(G[ve]=ne,addCmdRecord(ve))}),J.mRightButtonBarData&&J.mRightButtonBarData.buttonBarData&&J.mRightButtonBarData.buttonBarData.forEach(({cmd:ve,prompt:ne})=>{ve&&(G[ve]=ne,addCmdRecord(ve))}),J.mTitleButtonBarData&&J.mTitleButtonBarData.forEach(({cmd:ve,prompt:ne})=>{ve&&(G[ve]=ne,addCmdRecord(ve))}),J.mTopButtonBarData&&J.mTopButtonBarData.forEach(({cmd:ve,prompt:ne})=>{ve&&(G[ve]=ne,addCmdRecord(ve))});let fe=await fetchQuickCommand();fe&&(fe.forEach(ve=>{let ne;ve.forEach(Ue=>{addCmdRecord(Ue),ne||(ne=G[Ue])}),ne&&ve.forEach(Ue=>{G[Ue]=ne})}),registerCmdRecord())}),{handleKeydownCmd:u,commandText,consoleText,cmdTip,cmdTipObj:b,coordinates,setCommandFocus:n,sendInputCmd:c,isShowMenu:m,onSearch:N,getItemTitle:q,handleKeydown:L,comboboxItems,selectCmd:O}},clone=function(t){let e=Array.isArray(t)?[]:{};if(t&&typeof t=="object")for(let l in t)t.hasOwnProperty(l)&&(t[l]&&typeof t[l]=="object"?e[l]=clone(t[l]):e[l]=t[l]);return e};var script=defineComponent$1({name:"MouseMenu",props:{appendToBody:{type:Boolean,default:!0},menuWidth:{type:Number,default:200},menuList:{type:Array,required:!0},menuHiddenFn:{type:Function},hasIcon:{type:Boolean,default:!1},iconType:{type:String,default:"font-icon"},menuWrapperCss:Object,menuItemCss:Object,el:{type:Object,required:!0},params:{type:[String,Number,Array,Object]},useLongPressInMobile:Boolean,longPressDuration:Number,longPressPreventDefault:[Function,Boolean],injectCloseListener:{type:Boolean,default:!0},customClass:String,disabled:{type:Function}},emits:["open","close"],setup(t,{emit:e}){const l=ref(0),n=ref(0),u=ref(!1),c=ref(0),y=ref(0),b=ref(!1),m=ref(null),O=ref([]),N=computed(()=>t.menuList.some(rt=>rt.children&&rt.children.length>0)),L=ref(10),G=ref();watch(b,async rt=>{if(rt){await nextTick();let Ae=G.value;t.menuWrapperCss&&Object.keys(t.menuWrapperCss).map(Xe=>{Ae.style.setProperty(`--menu-${Xe}`,t.menuWrapperCss&&t.menuWrapperCss[Xe])}),t.menuItemCss&&Object.keys(t.menuItemCss).map(Xe=>{Ae.style.setProperty(`--menu-item-${Xe}`,t.menuItemCss&&t.menuItemCss[Xe])});let Te=t.menuItemCss?.arrowSize?.match(/\d+/);Te?L.value=~~Te[0]||10:L.value=10,Ae.style.setProperty("--menu-item-arrowRealSize",L.value/2+"px"),e("open",t.params,m.value,t.el)}else e("close",t.params,m.value,t.el)});const q=(rt,Ae)=>{rt.disabled||(rt.fn&&typeof rt.fn=="function"&&rt.fn(t.params,m.value,t.el,Ae),b.value=!1)},J=(rt,Ae)=>{rt.disabled||(rt.fn&&typeof rt.fn=="function"&&!rt.disabled&&(rt.fn(t.params,m.value,t.el,Ae),u.value=!1),b.value=!1)},fe=(rt,Ae)=>{if(Ae.children&&!Ae.disabled){u.value=!0;const Te=rt.currentTarget;if(!Te)return;const{offsetWidth:Xe}=Te,ie=Te.querySelector(".__menu__sub__wrapper");if(!ie)return;const{offsetWidth:ue,offsetHeight:pt}=ie,{innerWidth:mt,innerHeight:Tt}=window,{top:kt,left:It}=Te.getBoundingClientRect();It+Xe+ue>mt-5?l.value=It-ue+5:l.value=It+Xe,kt+pt>Tt-5?n.value=Tt-pt:n.value=kt+5}},ve=(rt,Ae,Te,Xe)=>rt.map(ie=>(ie.children&&(ie.children=ve(ie.children,Ae,Te,Xe)),ie.label&&typeof ie.label=="function"&&(ie.label=ie.label(Xe,Ae,Te)),ie.tips&&typeof ie.tips=="function"&&(ie.tips=ie.tips(Xe,Ae,Te)),ie.icon&&typeof ie.icon=="function"&&(ie.icon=ie.icon(Xe,Ae,Te)),ie.hidden&&typeof ie.hidden=="function"&&(ie.hidden=ie.hidden(Xe,Ae,Te)),ie.disabled&&typeof ie.disabled=="function"&&(ie.disabled=ie.disabled(Xe,Ae,Te)),ie)),ne=async(rt=0,Ae=0)=>{if(m.value=document.elementFromPoint(rt-1,Ae-1),t.menuHiddenFn?b.value=!t.menuHiddenFn(t.params,m.value,t.el):b.value=!0,!b.value)return;O.value=clone(t.menuList),O.value=ve(O.value,m.value,t.el,t.params),await nextTick();const{innerWidth:Te,innerHeight:Xe}=window,ue=G.value.offsetHeight,pt=t.menuWidth||200;y.value=rt+pt+1>Te?Te-pt-5:rt+1,c.value=Ae+ue+1>Xe?Xe-ue-5:Ae+1},Ue=()=>{b.value=!1},De=computed(()=>t.useLongPressInMobile&&"ontouchstart"in window?"touchstart":"mousedown"),Ve=rt=>{G.value&&!G.value.contains(rt.currentTarget)&&(b.value=!1,document.oncontextmenu=null)};return watch(()=>t.injectCloseListener,rt=>{rt?document.addEventListener(De.value,Ve):document.removeEventListener(De.value,Ve)},{immediate:!0}),onUnmounted(()=>{document.removeEventListener(De.value,Ve)}),{subLeft:l,subTop:n,hoverFlag:u,menuTop:c,menuLeft:y,showMenu:b,clickDomEl:m,calcMenuList:O,arrowSize:L,hasSubMenu:N,MenuWrapper:G,handleMenuItemClick:q,handleSubMenuItemClick:J,handleMenuMouseEnter:fe,show:ne,close:Ue,clickEventKey:De}}});const _hoisted_1$f=["onMouseenter"],_hoisted_2$b={key:0,class:"__menu__item-icon"},_hoisted_3$7=["innerHTML"],_hoisted_4$5={class:"__menu__item-label"},_hoisted_5$4={class:"__menu__item-tips"},_hoisted_6$3={class:"__menu__item-arrow-after"},_hoisted_7$2={class:"__menu__sub__item-label"},_hoisted_8$2={class:"__menu__sub__item-tips"};function render(t,e,l,n,u,c){return openBlock(),createBlock(Teleport,{to:"body",disabled:!t.appendToBody},[t.showMenu?(openBlock(),createElementBlock("div",{key:0,ref:"MenuWrapper",class:normalizeClass(["__menu__wrapper",t.customClass]),style:normalizeStyle({width:`${t.menuWidth}px`,top:`${t.menuTop}px`,left:`${t.menuLeft}px`})},[(openBlock(!0),createElementBlock(Fragment,null,renderList(t.calcMenuList,(y,b)=>(openBlock(),createElementBlock(Fragment,null,[!y.hidden&&!y.line?(openBlock(),createElementBlock("div",mergeProps({key:b,class:["__menu__item",y.disabled&&"disabled",y.customClass]},{[toHandlerKey(t.clickEventKey)]:withModifiers(m=>t.handleMenuItemClick(y,m),["stop"])},{onMouseenter:m=>t.handleMenuMouseEnter(m,y)}),[t.hasIcon?(openBlock(),createElementBlock("div",_hoisted_2$b,[t.iconType==="font-icon"?withDirectives((openBlock(),createElementBlock("i",{key:0,class:normalizeClass(y.icon)},null,2)),[[vShow,y.icon]]):t.iconType==="svg-icon"?withDirectives((openBlock(),createElementBlock("div",{key:1,class:"__menu__item-icon-svg",innerHTML:y.icon},null,8,_hoisted_3$7)),[[vShow,y.icon]]):t.iconType==="vnode-icon"?(openBlock(),createBlock(resolveDynamicComponent(y.icon),{key:2})):createCommentVNode("v-if",!0)])):createCommentVNode("v-if",!0),createBaseVNode("span",_hoisted_4$5,toDisplayString(y.label),1),createBaseVNode("span",_hoisted_5$4,toDisplayString(y.tips||""),1),t.hasSubMenu?(openBlock(),createElementBlock("span",{key:1,class:normalizeClass(["__menu__item-arrow",{show:t.hasSubMenu&&y.children}]),style:normalizeStyle({width:t.arrowSize+"px",height:t.arrowSize+"px"})},[withDirectives(createBaseVNode("span",_hoisted_6$3,null,512),[[vShow,t.hasSubMenu&&y.children]])],6)):createCommentVNode("v-if",!0),y.children&&y.children.length>0?withDirectives((openBlock(),createElementBlock("div",{key:2,class:"__menu__sub__wrapper",style:normalizeStyle({top:`${t.subTop}px`,left:`${t.subLeft}px`})},[(openBlock(!0),createElementBlock(Fragment,null,renderList(y.children,(m,O)=>(openBlock(),createElementBlock(Fragment,null,[!m.hidden&&!m.line?(openBlock(),createElementBlock("div",mergeProps({key:O,class:["__menu__sub__item",m.disabled&&"disabled",m.customClass]},{[toHandlerKey(t.clickEventKey)]:withModifiers(N=>t.handleSubMenuItemClick(m,N),["stop"])}),[createBaseVNode("span",_hoisted_7$2,toDisplayString(m.label),1),createBaseVNode("span",_hoisted_8$2,toDisplayString(m.tips||""),1)],16)):createCommentVNode("v-if",!0),m.line?(openBlock(),createElementBlock("div",{key:O,class:"__menu__line"})):createCommentVNode("v-if",!0)],64))),256))],4)),[[vShow,t.hoverFlag]]):createCommentVNode("v-if",!0)],16,_hoisted_1$f)):createCommentVNode("v-if",!0),!y.hidden&&y.line?(openBlock(),createElementBlock("div",{key:b,class:"__menu__line"})):createCommentVNode("v-if",!0)],64))),256))],6)):createCommentVNode("v-if",!0)],8,["disabled"])}function styleInject(t,e){e===void 0&&(e={});var l=e.insertAt;if(!(typeof document>"u")){var n=document.head||document.getElementsByTagName("head")[0],u=document.createElement("style");u.type="text/css",l==="top"&&n.firstChild?n.insertBefore(u,n.firstChild):n.appendChild(u),u.styleSheet?u.styleSheet.cssText=t:u.appendChild(document.createTextNode(t))}}var css_248z=`.__menu__mask[data-v-3d21bc0a] {
- position: fixed;
- top: 0;
- left: 0;
- bottom: 0;
- right: 0;
- z-index: 999;
- }
- .__menu__wrapper[data-v-3d21bc0a] {
- --menu-background: #c8f2f0;
- --menu-boxShadow: 0 1px 5px #888;
- --menu-padding: 5px 0;
- --menu-borderRadius: 0;
- --menu-item-height: 30px;
- --menu-item-padding: 0 10px;
- --menu-item-iconSize: 20px;
- --menu-item-iconFontSize: 14px;
- --menu-item-iconColor: #484852;
- --menu-item-labelColor: #484852;
- --menu-item-labelFontSize: 14px;
- --menu-item-tipsColor: #889;
- --menu-item-tipsFontSize: 12px;
- --menu-item-arrowColor: #484852;
- --menu-item-disabledColor: #bcc;
- --menu-item-hoverBackground: rgba(255, 255, 255, 0.8);
- --menu-item-hoverIconColor: inherit;
- --menu-item-hoverLabelColor: inherit;
- --menu-item-hoverTipsColor: inherit;
- --menu-item-hoverArrowColor: inherit;
- --menu-lineColor: #ccc;
- --menu-lineMargin: 5px 0;
- }
- .__menu__wrapper[data-v-3d21bc0a] {
- position: fixed;
- width: 200px;
- background: var(--menu-background);
- box-shadow: var(--menu-boxShadow);
- padding: var(--menu-padding);
- border-radius: var(--menu-borderRadius);
- z-index: 99999;
- }
- .__menu__line[data-v-3d21bc0a],
- .__menu__sub__line[data-v-3d21bc0a] {
- border-top: 1px solid var(--menu-lineColor);
- margin: var(--menu-lineMargin);
- }
- .__menu__item[data-v-3d21bc0a],
- .__menu__sub__item[data-v-3d21bc0a] {
- display: flex;
- height: var(--menu-item-height);
- align-items: center;
- cursor: pointer;
- padding: var(--menu-item-padding);
- }
- .__menu__item .__menu__item-icon[data-v-3d21bc0a],
- .__menu__sub__item .__menu__item-icon[data-v-3d21bc0a] {
- display: flex;
- align-items: center;
- justify-content: center;
- color: var(--menu-item-iconColor);
- width: var(--menu-item-iconSize);
- height: var(--menu-item-iconSize);
- }
- .__menu__item .__menu__item-icon i[data-v-3d21bc0a],
- .__menu__sub__item .__menu__item-icon i[data-v-3d21bc0a] {
- font-size: var(--menu-item-iconFontSize);
- }
- .__menu__item .__menu__item-icon .__menu__item-icon-svg[data-v-3d21bc0a],
- .__menu__sub__item .__menu__item-icon .__menu__item-icon-svg[data-v-3d21bc0a] {
- display: flex;
- align-items: center;
- justify-content: center;
- width: 100%;
- height: 100%;
- }
- .__menu__item .__menu__item-label[data-v-3d21bc0a],
- .__menu__item .__menu__sub__item-label[data-v-3d21bc0a],
- .__menu__sub__item .__menu__item-label[data-v-3d21bc0a],
- .__menu__sub__item .__menu__sub__item-label[data-v-3d21bc0a] {
- width: 100%;
- max-height: 100%;
- text-overflow: ellipsis;
- white-space: nowrap;
- flex: 1;
- font-size: var(--menu-item-labelFontSize);
- color: var(--menu-item-labelColor);
- margin-right: 5px;
- overflow: hidden;
- }
- .__menu__item .__menu__item-tips[data-v-3d21bc0a],
- .__menu__item .__menu__sub__item-tips[data-v-3d21bc0a],
- .__menu__sub__item .__menu__item-tips[data-v-3d21bc0a],
- .__menu__sub__item .__menu__sub__item-tips[data-v-3d21bc0a] {
- font-size: var(--menu-item-tipsFontSize);
- color: var(--menu-item-tipsColor);
- }
- .__menu__item .__menu__item-arrow[data-v-3d21bc0a],
- .__menu__sub__item .__menu__item-arrow[data-v-3d21bc0a] {
- width: 10px;
- height: 10px;
- margin-left: 5px;
- position: relative;
- }
- .__menu__item.disabled[data-v-3d21bc0a],
- .__menu__sub__item.disabled[data-v-3d21bc0a] {
- cursor: not-allowed;
- }
- .__menu__item.disabled .__menu__item-icon[data-v-3d21bc0a],
- .__menu__item.disabled .__menu__item-label[data-v-3d21bc0a],
- .__menu__item.disabled .__menu__sub__item-label[data-v-3d21bc0a],
- .__menu__item.disabled .__menu__item-tips[data-v-3d21bc0a],
- .__menu__item.disabled .__menu__sub__item-tips[data-v-3d21bc0a],
- .__menu__sub__item.disabled .__menu__item-icon[data-v-3d21bc0a],
- .__menu__sub__item.disabled .__menu__item-label[data-v-3d21bc0a],
- .__menu__sub__item.disabled .__menu__sub__item-label[data-v-3d21bc0a],
- .__menu__sub__item.disabled .__menu__item-tips[data-v-3d21bc0a],
- .__menu__sub__item.disabled .__menu__sub__item-tips[data-v-3d21bc0a] {
- color: var(--menu-item-disabledColor);
- }
- .__menu__item.disabled .__menu__item-arrow .__menu__item-arrow-after[data-v-3d21bc0a],
- .__menu__sub__item.disabled .__menu__item-arrow .__menu__item-arrow-after[data-v-3d21bc0a] {
- border-left: var(--menu-item-arrowRealSize) solid var(--menu-item-disabledColor);
- }
- .__menu__item[data-v-3d21bc0a]:not(.disabled):hover {
- background: var(--menu-item-hoverBackground);
- }
- .__menu__item:not(.disabled):hover .__menu__item-icon[data-v-3d21bc0a] {
- color: var(--menu-item-hoverIconColor);
- }
- .__menu__item:not(.disabled):hover .__menu__item-label[data-v-3d21bc0a] {
- color: var(--menu-item-hoverLabelColor);
- }
- .__menu__item:not(.disabled):hover .__menu__item-tips[data-v-3d21bc0a] {
- color: var(--menu-item-hoverTipsColor);
- }
- .__menu__item:not(.disabled):hover .__menu__item-arrow[data-v-3d21bc0a] {
- color: var(--menu-item-hoverArrowColor);
- }
- .__menu__sub__item[data-v-3d21bc0a]:not(.disabled):hover {
- background: var(--menu-item-hoverBackground);
- }
- .__menu__sub__item:not(.disabled):hover .__menu__sub__item-label[data-v-3d21bc0a] {
- color: var(--menu-item-hoverLabelColor);
- }
- .__menu__sub__item:not(.disabled):hover .__menu__sub__item-tips[data-v-3d21bc0a] {
- color: var(--menu-item-hoverTipsColor);
- }
- .__menu__item-icon[data-v-3d21bc0a] {
- width: 20px;
- height: 20px;
- text-align: center;
- line-height: 20px;
- margin-right: 4px;
- }
- .__menu__item-arrow.show .__menu__item-arrow-after[data-v-3d21bc0a] {
- position: absolute;
- width: 0;
- height: 0;
- left: 8px;
- border-left: var(--menu-item-arrowRealSize) solid var(--menu-item-arrowColor);
- border-top: var(--menu-item-arrowRealSize) solid transparent;
- border-bottom: var(--menu-item-arrowRealSize) solid transparent;
- }
- .__menu__sub__wrapper[data-v-3d21bc0a] {
- position: fixed;
- visibility: hidden;
- width: 200px;
- background: var(--menu-background);
- box-shadow: var(--menu-boxShadow);
- padding: var(--menu-padding);
- border-radius: var(--menu-borderRadius);
- }
- .__menu__item:hover .__menu__sub__wrapper[data-v-3d21bc0a] {
- visibility: visible;
- }`;styleInject(css_248z);script.render=render;script.__scopeId="data-v-3d21bc0a";script.__file="packages/mouse-menu/mouse-menu.vue";function createClassDom(t,e,l){let n=document.createElement(t);return n.setAttribute("class",e),n}script.install=t=>{t.component(script.name,script)};function CustomMouseMenu(t){const e="__mouse__menu__container";let l;document.querySelector(`.${e}`)?l=document.querySelector(`.${e}`):l=createClassDom("div",e);const n=createVNode(script,t);return render$1(n,l),document.body.appendChild(l),n.component?.proxy}var __defProp$3=Object.defineProperty,__defNormalProp$3=(t,e,l)=>e in t?__defProp$3(t,e,{enumerable:!0,configurable:!0,writable:!0,value:l}):t[e]=l,__publicField$2=(t,e,l)=>(__defNormalProp$3(t,typeof e!="symbol"?e+"":e,l),l);function getComputedStyleList(t,e,l=!1){const n={},u=window.getComputedStyle(t);return e.map(c=>{let y=u[c];if(l){const b=y.match(/\d+/);b&&(y=~~b[0])}n[c]=y}),n}class ToDrag{constructor({el:e,options:l}){__publicField$2(this,"el"),__publicField$2(this,"isTouch"),__publicField$2(this,"isDrag"),__publicField$2(this,"parent"),__publicField$2(this,"left",0),__publicField$2(this,"top",0),__publicField$2(this,"right",0),__publicField$2(this,"bottom",0),__publicField$2(this,"width",0),__publicField$2(this,"height",0),__publicField$2(this,"maxX",0),__publicField$2(this,"maxY",0),__publicField$2(this,"options"),__publicField$2(this,"scrollbarWidth"),__publicField$2(this,"startX",0),__publicField$2(this,"startY",0),__publicField$2(this,"getScrollbarWidth",()=>{const n=document.createElement("div");n.style.cssText="width:100px;height:100px;overflow-y:scroll",document.body.appendChild(n);const u=n.offsetWidth-n.clientWidth;return document.body.removeChild(n),u}),__publicField$2(this,"setBetween",(n,u,c)=>n<u?u:n>c?c:n),__publicField$2(this,"borderInfo",[0,0,0,0]),this.el=e instanceof HTMLElement?e:document.querySelector(e),this.scrollbarWidth=this.getScrollbarWidth(),this.isTouch="ontouchstart"in document.documentElement,this.isDrag=!1,this.options={moveCursor:!0,adsorb:0,adsorbOffset:0,transitionDuration:400,transitionTimingFunction:"ease-in-out",forbidBodyScroll:!0,isAbsolute:!1,positionMode:1,needComputeBorder:!0,...l},this.parent=this.options.parentSelector&&document.querySelector(this.options.parentSelector)||this.el.parentNode,this.options.transitionDuration&&(this.options.transitionDuration=this.options.transitionDuration/1e3),this.handleTouchStart=this.handleTouchStart.bind(this),this.handleMousedown=this.handleMousedown.bind(this),this.moveEvent=this.moveEvent.bind(this),this.endEvent=this.endEvent.bind(this),this.init()}init(){this.isTouch?this.el.addEventListener("touchstart",this.handleTouchStart):this.el.addEventListener("mousedown",this.handleMousedown),this.options.moveCursor&&(this.el.style.cursor="move"),this.setPosition(),this.setLimit(),this.handleAdsorb(),this.handlePositionMode(),setTimeout(()=>{this.emitEvent("todraginit")})}handleMousedown(e){if(typeof this.options.disabled=="function"&&this.options.disabled())return;const{x:l,y:n}=e;this.setStartInfo(l,n),document.addEventListener("mousemove",this.moveEvent),document.addEventListener("mouseup",this.endEvent)}handleTouchStart(e){if(typeof this.options.disabled=="function"&&this.options.disabled())return;const l=this.isTouch?e.changedTouches[0].clientX:e.x,n=this.isTouch?e.changedTouches[0].clientY:e.y;this.setStartInfo(l,n),document.addEventListener("touchmove",this.moveEvent,{passive:!1}),document.addEventListener("touchend",this.endEvent)}setPosition(){const{left:e,top:l,width:n,height:u}=this.el.getBoundingClientRect();this.left=e,this.top=l,this.width=n,this.height=u,this.options.isAbsolute?(this.maxX=this.parent.offsetWidth-this.width,this.maxY=this.parent.offsetHeight-this.height):(this.maxX=document.body.scrollWidth>window.innerWidth?window.innerWidth-this.width-this.scrollbarWidth:window.innerWidth-this.width,this.maxY=document.body.scrollHeight>window.innerHeight?window.innerHeight-this.height-this.scrollbarWidth:window.innerHeight-this.height)}setStartInfo(e,l){this.setPosition(),this.setLimit(),this.startX=e-this.left,this.startY=l-this.top,this.isDrag=!0,this.el.style.transition="",document.body.style.userSelect="none",this.options.forbidBodyScroll&&(document.body.style.overflow="hidden"),this.emitEvent("todragstart")}moveEvent(e){if(!this.isDrag)return;e.preventDefault();let l,n;const u=this.isTouch?e.changedTouches[0].clientX:e.x,c=this.isTouch?e.changedTouches[0].clientY:e.y;if(!this.options.isAbsolute)l=u-this.startX,n=c-this.startY;else{const y=this.parent.getClientRects()[0];l=u-y.x-this.startX-this.borderInfo[1],n=c-y.y-this.startY-this.borderInfo[2]}this.left=this.setBetween(l,0,this.maxX-this.borderInfo[1]-this.borderInfo[3]),this.top=this.setBetween(n,0,this.maxY-this.borderInfo[2]-this.borderInfo[0]),this.el.style.left=this.left+"px",this.el.style.top=this.top+"px",this.emitEvent("todragmove")}endEvent(){this.isDrag=!1,document.removeEventListener("mousemove",this.moveEvent),document.removeEventListener("mouseup",this.endEvent),document.removeEventListener("touchmove",this.moveEvent),document.removeEventListener("touchend",this.endEvent),document.body.style.userSelect="auto",this.options.forbidBodyScroll&&(document.body.style.overflow="visible"),this.handleAdsorb(),this.handlePositionMode(),this.emitEvent("todragend")}handleAdsorb(){if(this.options.isAbsolute)return;const e=[this.left+this.width/2,this.top+this.height/2],l=[window.innerWidth,window.innerHeight];if(this.el.style.transition=`left ${this.options.transitionDuration}s ${this.options.transitionTimingFunction},
- top ${this.options.transitionDuration}s ${this.options.transitionTimingFunction}`,this.options.adsorb===1)e[0]<=window.innerWidth/2?this.left=this.options.adsorbOffset:this.left=this.maxX-this.options.adsorbOffset;else if(this.options.adsorb===2){const n=l[1]/l[0],u=l[1]/-l[0],c=e[1]/e[0],y=e[1]/(e[0]-l[0]);n>=c&&u<y?this.top=this.options.adsorbOffset:n>=c&&u>=y?this.left=this.maxX-this.options.adsorbOffset:n<c&&u>=y?this.top=this.maxY-this.options.adsorbOffset:this.left=this.options.adsorbOffset,this.options.adsorbOffset&&(this.top===0&&(this.top=this.options.adsorbOffset),this.top===this.maxY&&(this.top=this.maxY-this.options.adsorbOffset),this.left===0&&(this.left=this.options.adsorbOffset),this.left===this.maxX&&(this.left=this.maxX-this.options.adsorbOffset))}this.el.style.left=this.left+"px",this.el.style.top=this.top+"px"}handlePositionMode(){if(this.options.adsorb)return;const e=this.options.isAbsolute?this.el.offsetLeft:this.left,l=this.options.isAbsolute?this.el.offsetTop:this.top;this.right=this.maxX-e-this.borderInfo[1]-this.borderInfo[3],this.bottom=this.maxY-l-this.borderInfo[2]-this.borderInfo[0],this.options.positionMode===2?(this.el.style.left="auto",this.el.style.right=this.right+"px"):this.options.positionMode===3?(this.el.style.top="auto",this.el.style.bottom=this.bottom+"px"):this.options.positionMode===4&&(this.el.style.left="auto",this.el.style.top="auto",this.el.style.right=this.right+"px",this.el.style.bottom=this.bottom+"px")}emitEvent(e){const l=document.createEvent("HTMLEvents");l.initEvent(e,!1,!1);const{left:n,top:u,right:c,bottom:y,width:b,height:m,maxX:O,maxY:N}=this;l.left=n,l.top=u,l.width=b,l.height=m,l.maxX=O,l.maxY=N,l.right=c,l.bottom=y,this.el.dispatchEvent(l)}destroy(){this.isTouch?this.el.removeEventListener("touchstart",this.handleTouchStart):this.el.removeEventListener("mousedown",this.handleMousedown)}setLimit(){if(!this.options.isAbsolute||!this.options.needComputeBorder)return;const e=["top","right","bottom","left"],l=getComputedStyleList(this.parent,[...e.map(n=>`border-${n}-width`)],!0);this.borderInfo=e.map(n=>l[`border-${n}-width`])}}var __defProp$2=Object.defineProperty,__defNormalProp$2=(t,e,l)=>e in t?__defProp$2(t,e,{enumerable:!0,configurable:!0,writable:!0,value:l}):t[e]=l,__publicField$1=(t,e,l)=>(__defNormalProp$2(t,typeof e!="symbol"?e+"":e,l),l);class ToControl extends ToDrag{constructor({el:e,options:l}){super({el:e,options:{adsorb:0,adsorbOffset:0,isAbsolute:!1,positionMode:1,...l}}),__publicField$1(this,"arrowCtx",null),__publicField$1(this,"controlOptions"),__publicField$1(this,"arrowStartX",0),__publicField$1(this,"arrowStartY",0),__publicField$1(this,"elWidth",0),__publicField$1(this,"elHeight",0),__publicField$1(this,"resizeFlag",!1),__publicField$1(this,"arrowMouseDownEvent",n=>{if(typeof this.controlOptions.disabled=="function"&&this.controlOptions.disabled())return;const u=this.isTouch?n.changedTouches[0].clientX:n.x,c=this.isTouch?n.changedTouches[0].clientY:n.y,{width:y,height:b,left:m,top:O}=this.el.getBoundingClientRect(),{width:N,height:L}=this.parent.getBoundingClientRect();this.arrowStartX=u,this.arrowStartY=c,this.elWidth=y,this.elHeight=b,this.resizeFlag=!0;let G,q;this.controlOptions.isAbsolute?(G=N-this.el.offsetLeft-this.borderInfo[1]-this.borderInfo[3],q=L-this.el.offsetTop-this.borderInfo[0]-this.borderInfo[2]):(G=window.innerWidth-m,q=window.innerHeight-O),setTimeout(()=>{this.isDrag=!1}),this.el.style.left=`${this.controlOptions.isAbsolute?this.el.offsetLeft:m}px`,this.el.style.top=`${this.controlOptions.isAbsolute?this.el.offsetTop:O}px`,this.el.style.right="auto",this.el.style.bottom="auto",this.emitControlEvent("tocontrolstart"),this.isTouch?(document.ontouchmove=J=>{if(!this.resizeFlag||!J.changedTouches)return;const{clientX:fe,clientY:ve}=J.changedTouches[0];this.el.style.width=`${Math.min(this.elWidth+fe-this.arrowStartX,G)}px`,this.el.style.height=`${Math.min(this.elHeight+ve-this.arrowStartY,q)}px`,this.emitControlEvent("tocontrolmove")},document.ontouchend=()=>{this.setPosition(),this.resizeFlag=!1,document.ontouchmove=null,document.ontouchend=null,this.emitControlEvent("tocontrolend")}):(document.onmousemove=J=>{if(!this.resizeFlag)return;const{x:fe,y:ve}=J;this.el.style.width=`${Math.min(this.elWidth+fe-this.arrowStartX,G)}px`,this.el.style.height=`${Math.min(this.elHeight+ve-this.arrowStartY,q)}px`,this.emitControlEvent("tocontrolmove")},document.onmouseup=()=>{this.setPosition(),this.resizeFlag=!1,document.onmousemove=null,document.onmouseup=null,this.emitControlEvent("tocontrolend")})}),this.controlOptions=l||{},this.initControl()}initControl(){this.arrowCtx=this.createResizeArrow(this.controlOptions?.arrowOptions),this.el.appendChild(this.arrowCtx)}updateArrow(){this.arrowCtx&&this.el.contains(this.arrowCtx)&&this.el.removeChild(this.arrowCtx),this.arrowCtx=this.createResizeArrow(this.controlOptions?.arrowOptions),this.el.appendChild(this.arrowCtx)}createResizeArrow(e){const l=typeof this.controlOptions.disabled=="function"&&this.controlOptions.disabled(),n={size:8,lineWidth:2,lineColor:"#9a9a9a",padding:2,...e},u=document.createElement("div");u.style.cssText=`
- position: absolute;
- right: 0;
- bottom: 0;
- padding: ${n.padding}px;
- cursor: se-resize;
- background: ${n.background||"none"};
- display: ${l?"none":"block"}
- `,u.className="to-control-arrow";const c=document.createElement("div");return c.style.cssText=`
- width: ${n.size}px;
- height: ${n.size}px;
- border-bottom: ${n.lineWidth}px solid ${n.lineColor};
- border-right: ${n.lineWidth}px solid ${n.lineColor};
- `,c.className="to-control-arrow-inner",u.appendChild(c),this.isTouch?u.addEventListener("touchstart",this.arrowMouseDownEvent):u.addEventListener("mousedown",this.arrowMouseDownEvent),u}destroyControl(){this.destroy(),this.isTouch?this.arrowCtx?.removeEventListener("touchstart",this.arrowMouseDownEvent):this.arrowCtx?.removeEventListener("mousedown",this.arrowMouseDownEvent)}emitControlEvent(e){const l=document.createEvent("HTMLEvents");l.initEvent(e,!1,!1);const{left:n,top:u,right:c,bottom:y,width:b,height:m,maxX:O,maxY:N}=this;l.left=n,l.top=u,l.width=b,l.height=m,l.maxX=O,l.maxY=N,l.right=c,l.bottom=y,this.el.dispatchEvent(l)}}const mounted$3=(t,e,l)=>{const{value:n}=e,c={...l||{},...n};t.$toControl=new ToControl({el:t,options:c})},beforeUpdate=t=>{t.$toControl&&t.$toControl.updateArrow()},unmounted$1=t=>{t.$toControl&&t.$toControl.destroy()},ToControlDirective={mounted:(t,e)=>mounted$3(t,e),unmounted:unmounted$1,beforeUpdate,inserted:(t,e)=>mounted$3(t,e),unbind:unmounted$1,update:beforeUpdate,install:(t,e)=>{t.directive("to-control",{mounted:(l,n)=>mounted$3(l,n,e),unmounted:unmounted$1,beforeUpdate,inserted:(l,n)=>mounted$3(l,n,e),unbind:unmounted$1,update:beforeUpdate})}};var __defProp$1=Object.defineProperty,__defNormalProp$1=(t,e,l)=>e in t?__defProp$1(t,e,{enumerable:!0,configurable:!0,writable:!0,value:l}):t[e]=l,__publicField=(t,e,l)=>(__defNormalProp$1(t,typeof e!="symbol"?e+"":e,l),l);class CustomResize{constructor({el:e,options:l}){__publicField(this,"el"),__publicField(this,"options"),__publicField(this,"directionArr"),e instanceof HTMLElement?this.el=e:this.el=document.querySelector(e),this.options={immediate:!1,direction:["right"],scrollElSelector:null,lineColor:"#aab",lineWidth:2,lineHoverColor:"#88f",lineHoverWidth:4,tipLineColor:"#262626",tipLineWidth:1,tipLineStyle:"dashed",zIndex:999,needParentNodeOffset:!0,...l},this.directionArr=this.options.direction||["right"],this.el.$resize=this}init(){const{position:e}=getComputedStyle(this.el),{position:l}=getComputedStyle(this.el.parentNode);e==="static"&&(this.el.style.position="relative"),l==="static"&&console.warn("[@howdyjs/resize] Element parentNode position can not be static!"),this.directionArr.map(n=>{if(this.options.immediate){const u=this.createLineEl(n);this.el.appendChild(u)}else{const u=this.createDashedLineEl(n),c=this.createLineEl(n,u);this.el.appendChild(u),this.el.appendChild(c)}})}createDashedLineEl(e){const{tipLineColor:l,tipLineWidth:n,tipLineStyle:u,zIndex:c}=this.options,y=document.createElement("div"),b=`position:absolute;z-index: ${c};visibility: hidden;`,m=e==="left"||e==="right";return y.style.cssText=m?`${b};top:0;bottom: 0;${e}:0;border-${e}:${n}px ${u} ${l}`:`${b};left:0;right: 0;${e}:0;border-${e}:${n}px ${u} ${l}`,y.setAttribute("class","resize__dashed-line"),y}createLineEl(e,l){const{immediate:n,lineColor:u,lineWidth:c,lineHoverColor:y,lineHoverWidth:b,zIndex:m}=this.options,O=document.createElement("div"),N=`position: absolute;background: ${u};z-index: ${m}`,L=e==="left"||e==="right",G=e==="right"||e==="bottom";O.style.cssText=L?`${N};width: ${c}px;top:0;bottom: 0;${e}: -${c/2}px;cursor: col-resize;`:`${N};height: ${c}px;left:0;right: 0;${e}: -${c/2}px;cursor: row-resize;`,O.mouseoverEvent=function(){O.style.background=y,O.style[L?"width":"height"]=`${b}px`,O.style[e]=`-${b/2}px`},O.mouseoutEvent=function(){O.style.background=u,O.style[L?"width":"height"]=`${c}px`,O.style[e]=`-${c/2}px`};const q=this.el;return O.mousedownEvent=function(J){const ve=(q||J.target.parentNode).parentNode;let ne;const Ue=L?ve.offsetWidth:ve.offsetHeight;document.body.style.userSelect="none";let De=!0;const Ve=()=>{const rt=L?q.offsetWidth:q.offsetHeight,Ae=L?q.offsetLeft:q.offsetTop,Te=G?Ae+rt+ne:Ae+ne,Xe=G?rt+ne:rt-ne,ie=document.createEvent("HTMLEvents");ie.initEvent("resize",!1,!1),ie.direction=e,ie.moveOffset=Te,ie.moveOffsetPercent=Te/Ue*100,ie[L?"resizeWidth":"resizeHeight"]=Xe,ie[L?"resizeWidthPercent":"resizeHeightPercent"]=Xe/Ue*100,q.dispatchEvent(ie)};document.onmousemove=function(rt){rt.preventDefault();const{x:Ae,y:Te}=q.getBoundingClientRect(),Xe=L?q.offsetWidth:q.offsetHeight,ie=L?q.offsetLeft:q.offsetTop;ne=G?L?rt.clientX-Ae-Xe:rt.clientY-Te-Xe:L?rt.clientX-Ae:rt.clientY-Te,De=G?-ne<=Xe&&ie+Xe+ne<=Ue:ne<=Xe&&ie+ne>=0,De&&(n?Ve():l&&(l.style.visibility="visible",l.style[e]=`${G?-ne:ne}px`))},document.onmouseup=function(){document.onmousemove=null,document.onmouseup=null,document.body.style.userSelect="auto",n||(l&&(l.style.visibility="hidden"),De&&(Ve(),l&&(l.style[e]="0px")))}},O.setAttribute("class","resize__line"),O.addEventListener("mousemove",O.mouseoverEvent),O.addEventListener("mouseout",O.mouseoutEvent),O.addEventListener("mousedown",O.mousedownEvent),O}destroy(){Array.prototype.slice.call(this.el.querySelectorAll(".resize__line")).forEach(l=>{l.mouseoverEvent&&l.removeEventListener("mousemove",l.mouseoverEvent),l.mouseoutEvent&&l.removeEventListener("mouseout",l.mouseoutEvent),l.mousedownEvent&&l.removeEventListener("mousedown",l.mousedownEvent),l.parentNode&&l.parentNode.removeChild(l)}),this.el.querySelectorAll(".resize__dashed-line").forEach(l=>{l.parentNode&&l.parentNode.removeChild(l)})}}const mounted$2=(t,e,l)=>{const{arg:n,value:u}=e,c=l||{};let y,b;n&&(n==="all"?y=["top","left","bottom","right"]:y=[n]),y?b={...c,...u,direction:y}:b={...c,...u},new CustomResize({el:t,options:b}).init()},unmounted=t=>{t.$resize&&t.$resize.destroy()},ResizeDirective={mounted:(t,e)=>mounted$2(t,e),unmounted,inserted:(t,e)=>mounted$2(t,e),unbind:unmounted,install:(t,e)=>{t.directive("resize",{mounted:(l,n)=>mounted$2(l,n,e),unmounted,inserted:(l,n)=>mounted$2(l,n,e),unbind:unmounted})}},useResize=(t={})=>({resizeOptions:reactive({immediate:!1,lineWidth:3,lineColor:"",lineHoverWidth:6,lineHoverColor:"#70A8E0",tipLineColor:"#70A8E0",tipLineWidth:3,...t}),vResize:ResizeDirective,CustomResize});let MouseMenuCtx,contextMenuEvent,longPressTimer,longPressTouchStart,longPressTouchEnd,longPressEvent;function addLongPressListener(t,e,l=500,n){longPressTouchStart=u=>{MouseMenuCtx&&MouseMenuCtx.close(),typeof n=="function"?n(u,t)&&u.preventDefault():typeof n=="boolean"&&n&&u.preventDefault(),longPressTimer&&clearTimeout(longPressTimer),longPressTimer=window.setTimeout(()=>{e(u)},l)},longPressTouchEnd=()=>{clearTimeout(longPressTimer)},t.addEventListener("touchstart",longPressTouchStart),t.addEventListener("touchmove",longPressTouchEnd),t.addEventListener("touchend",longPressTouchEnd),t.addEventListener("touchcancel",longPressTouchEnd)}function removeLongPressListener(t){t.removeEventListener("touchstart",longPressTouchStart),t.removeEventListener("touchmove",longPressTouchEnd),t.removeEventListener("touchend",longPressTouchEnd),t.removeEventListener("touchcancel",longPressTouchEnd)}const onKeydown=t=>{t.code=="Escape"&&MouseMenuCtx&&(MouseMenuCtx.showMenu=!1)},mounted$1=(t,e)=>{const{value:l}=e;l.menuList.length>0&&(contextMenuEvent=n=>{if(n.button===2){if(n.preventDefault(),typeof l.disabled=="function"&&l.disabled(l.params))return;l.injectCloseListener=!1,MouseMenuCtx=CustomMouseMenu({el:t,...l});const{x:u,y:c}=n;MouseMenuCtx.show(u,c)}else MouseMenuCtx&&(MouseMenuCtx.showMenu=!1)},t.removeEventListener("mousedown",contextMenuEvent),t.addEventListener("mousedown",contextMenuEvent),window.addEventListener("keydown",onKeydown),t.oncontextmenu=n=>{n.preventDefault()},l.useLongPressInMobile&&"ontouchstart"in window&&(longPressEvent=n=>{if(typeof l.disabled=="function"&&l.disabled(l.params))return;MouseMenuCtx=CustomMouseMenu({el:t,...l});const{touches:u}=n,{clientX:c,clientY:y}=u[0];MouseMenuCtx.show(c,y),document.onmousedown=null,t.onmousedown=null,setTimeout(()=>{document.onmousedown=()=>MouseMenuCtx.close(),t.onmousedown=()=>MouseMenuCtx.close()},500)},removeLongPressListener(t),addLongPressListener(t,longPressEvent,l.longPressDuration||500,l.longPressPreventDefault)))},MyMouseMenuDirective={mounted:mounted$1,unmounted(t){t.removeEventListener("mousedown",contextMenuEvent),window.removeEventListener("keydown",onKeydown),t.oncontextmenu=null}},mouseMenu={install(t){t.directive("right-click-menu",MyMouseMenuDirective),t.directive("to-control",ToControlDirective)}},TextAreaWrap={MaxHeight:800,MinHeight:20},key="Mx_consoleHeight",_localHeight=localStorage.getItem(key),localHeight=_localHeight?Number(_localHeight):68,height=ref(localHeight),useConsoleResize=()=>{const{vResize:t,resizeOptions:e}=useResize({direction:["top"]}),{mainRect:l}=useLayout();return{vResize:t,resizeOptions:e,height,handleResize:u=>{u.resizeHeight&&(height.value+=u.resizeHeight-l.value.bottom,height.value>TextAreaWrap.MaxHeight&&(height.value=TextAreaWrap.MaxHeight),height.value<TextAreaWrap.MinHeight&&(height.value=TextAreaWrap.MinHeight),localStorage.setItem(key,height.value.toString()))}}},useSysVarLongSketchSettings=()=>{const t=ref([]),e=ref(sysVarLongSketchSettingsKeys.map((l,n)=>{const u=SysVarLongSketchSettings[l],c=SysVarLongSketchSettings.GRIDMODE===u||SysVarLongSketchSettings.AUTOSNAP===u||SysVarLongSketchSettings.OSMODE===u;return{name:u,isMenu:c,menuOptions:c?useRightClickMenuOptions({hasIcon:!0,menuList:[{label:"设置",fn:()=>{switch(u){case SysVarLongSketchSettings.GRIDMODE:callCommand("showDraftingSettingsDialog",{tab:2});return;case SysVarLongSketchSettings.AUTOSNAP:callCommand("showDraftingSettingsDialog",{tab:1});return;case SysVarLongSketchSettings.OSMODE:callCommand("showDraftingSettingsDialog",{tab:3});return}}},{label:"开",fn:()=>{setSysVarLongSketchSettings(l,Status.On)},icon:()=>t.value.includes(n)?"iconfont gou":""},{label:"关",fn:()=>{setSysVarLongSketchSettings(l,Status.Off)},icon:()=>t.value.includes(n)?"":"iconfont gou"}]}):null}}).filter(({name:l})=>(uiConfig.footerRightBtnSwitchData||[]).includes(l)));return watch(t,(l,n)=>{sysVarLongSketchSettingsKeys.forEach((u,c)=>{let y=n.includes(c),b=l.includes(c);y&&!b&&setSysVarLongSketchSettings(u,Status.Off),!y&&b&&setSysVarLongSketchSettings(u,Status.On)})}),watch(sysVarLongSketchSettings,l=>{const n=[];sysVarLongSketchSettingsKeys.forEach((u,c)=>{l[u]===Status.On&&n.push(c)}),t.value=n}),{items:e,actives:t}},_hoisted_1$e={key:0,class:"d-flex w-100 flex-column pa-0 ma-0"},_hoisted_2$a={key:1},_hoisted_3$6={key:0,class:"footer_btn_box"},_sfc_main$l=defineComponent$1({__name:"index",props:{show:{type:Boolean}},setup(t){const{items:e,actives:l}=useSysVarLongSketchSettings();ref();const n=ref(),{handleKeydown:u,isShowMenu:c,comboboxItems:y,getItemTitle:b,selectCmd:m,onSearch:O,commandText:N,consoleText:L,cmdTipObj:G,coordinates:q,sendInputCmd:J}=useCommandLine(n),{resizeOptions:fe,vResize:ve,height:ne,handleResize:Ue}=useConsoleResize(),{tipsShow:De,progress:Ve,fileTips:rt}=useDwgUpload(),Ae=kt=>{if(!kt){const It=window.getSelection();if(!It)return;kt=It.toString()}if(kt!=="")if(navigator.clipboard){const It=kt.replace(/\n/g,`\r
- `);navigator.clipboard.writeText(It)}else{const It=document.createElement("input");It.setAttribute("value",kt),It.setAttribute("type","text"),document.body.appendChild(It),It.select(),document.execCommand("copy"),document.body.removeChild(It)}},Te=useRightClickMenuOptions({hasIcon:!0,menuWidth:150,menuList:[{label:"复制",fn:()=>Ae()},{label:"复制历史记录",fn:()=>{Ae(L.value)}},{label:"粘贴",fn:async(kt,It,nn,tn)=>{N.value=await navigator.clipboard.readText(),n.value?.focus(),c.value=!1}}]});function Xe(){if(window.getSelection){var kt=window.getSelection();return kt.toString().length>0}else if(document.selection&&document.selection.type!=="None"){var It=document.selection.createRange();return It.text.length>0}return!1}let ie=!1;const ue=()=>{isStartShortcutCtrlCXVKey.value=!1,ie=!0},pt=kt=>{kt||(ie=!1,isStartShortcutCtrlCXVKey.value=!0)},mt=kt=>{if(kt.code==="Enter"&&(ie=!1,isStartShortcutCtrlCXVKey.value=!0),(kt.code==="Backspace"||kt.code==="Delete")&&!N.value&&(ie=!1,isStartShortcutCtrlCXVKey.value=!0),!kt.ctrlKey)return;const It=kt.code==="KeyC"&&Xe(),nn=kt.code==="KeyV"&&ie,tn=kt.code==="KeyA"&&ie,pn=kt.code==="KeyX"&&ie;(It||nn||tn||pn)&&kt.stopPropagation()},Tt=ref(!1);return watch(Tt,kt=>{MxCpp.getCurrentMxCAD().showLineWeight(kt)}),(kt,It)=>{const nn=resolveDirective("scroll-bottom"),tn=resolveDirective("right-click-menu");return withDirectives((openBlock(),createBlock(VFooter,{app:"",height:"auto",class:"pa-0 mx-footer",onKeydown:mt,onClick:ue,onResize:unref(Ue)},{default:withCtx(()=>[createVNode(VSkeletonLoader,{type:"paragraph",class:"w-100",height:unref(ne)+40,loading:!kt.show},{default:withCtx(()=>[kt.show?(openBlock(),createElementBlock("div",_hoisted_1$e,[withDirectives((openBlock(),createElementBlock("div",null,[unref(uiConfig).isShowCommandLinePanel?(openBlock(),createElementBlock("div",{key:0,class:"console-box",style:normalizeStyle({height:unref(ne)+"px"})},[withDirectives(createBaseVNode("textarea",{"onUpdate:modelValue":It[0]||(It[0]=pn=>isRef(L)?L.value=pn:null),id:"mx_footer_console_text",readonly:"",class:"console d-flex"},null,512),[[vModelText,unref(L)],[nn]])],4)):createCommentVNode("",!0),unref(uiConfig).isShowCommandInput?(openBlock(),createBlock(VCombobox,{key:1,tabindex:"-1",onKeydown:unref(u),"no-click-animation":"",contained:"","onUpdate:focused":pt,"menu-icon":"","menu-props":{modelValue:unref(c),maxHeight:200,location:"top"},items:unref(y),ref_key:"input",ref:n,prefix:"",modelValue:unref(N),"onUpdate:modelValue":It[1]||(It[1]=pn=>isRef(N)?N.value=pn:null),autofocus:"",autocomplete:"off",light:"","onUpdate:search":unref(O)},{prepend:withCtx(()=>[createVNode(VIcon,{icon:"cloudshellyunminglinghang",style:{color:"#7ABDE9"}}),createBaseVNode("span",null,toDisplayString(kt.t("767",()=>unref(translateOnlyChinese)(unref(G).msg.replace(":","").replace(/^\s+|\s+$/g,""))))+":",1),unref(G).keys?(openBlock(),createElementBlock(Fragment,{key:0},[It[6]||(It[6]=createTextVNode(" [ ")),(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(G).keys,({key:pn,label:_n})=>withDirectives((openBlock(),createBlock(VBtn,{onClick:Dn=>unref(J)(pn),variant:"tonal",class:"px-1 ml-1",label:"",size:"x-small"},{default:withCtx(()=>[createTextVNode(toDisplayString(kt.t(_n))+"("+toDisplayString(pn)+") ",1)]),_:2},1032,["onClick"])),[[Ripple]])),256)),It[7]||(It[7]=createTextVNode(" ] "))],64)):createCommentVNode("",!0),unref(G).endMsg?(openBlock(),createElementBlock("span",_hoisted_2$a,toDisplayString(kt.t("767",()=>unref(translateOnlyChinese)(unref(G).endMsg||""))),1)):createCommentVNode("",!0)]),_:1},8,["onKeydown","menu-props","items","modelValue","onUpdate:search"])):createCommentVNode("",!0)])),[[tn,unref(Te)]]),unref(uiConfig).isShowFooterStatusBar?(openBlock(),createElementBlock("div",_hoisted_3$6,[unref(De)?createCommentVNode("",!0):(openBlock(),createBlock(VCard,{key:0,class:"d-flex align-center"},{default:withCtx(()=>[createVNode(VChip,{size:"x-small",class:"ml-1 me-auto bg-accent"},{default:withCtx(()=>[createTextVNode(toDisplayString(unref(q)),1)]),_:1}),createVNode(VBtnToggle,{modelValue:unref(l),"onUpdate:modelValue":It[4]||(It[4]=pn=>isRef(l)?l.value=pn:null),density:"compact",variant:"text",class:"px-2",style:{height:"20px"},multiple:""},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(e),(pn,_n)=>(openBlock(),createElementBlock(Fragment,{key:_n},[pn.isMenu?withDirectives((openBlock(),createBlock(VBtn,{key:0,value:_n,class:"mx-1 rounded",height:"20",size:"x-small"},{default:withCtx(()=>[createTextVNode(toDisplayString(kt.t(pn.name)),1)]),_:2},1032,["value"])),[[tn,pn.menuOptions]]):(openBlock(),createBlock(VBtn,{key:1,value:_n,class:"mx-1 rounded",height:"20",size:"x-small",onContextmenu:It[2]||(It[2]=withModifiers(()=>{},["prevent","stop"]))},{default:withCtx(()=>[createTextVNode(toDisplayString(kt.t(pn.name)),1)]),_:2},1032,["value"]))],64))),128)),createVNode(VBtn,{class:"mx-1 rounded",size:"x-small",height:"20",onClick:It[3]||(It[3]=pn=>Tt.value=!Tt.value)},{default:withCtx(()=>[createTextVNode(toDisplayString(kt.t("112")),1)]),_:1})]),_:1},8,["modelValue"])]),_:1})),unref(De)?(openBlock(),createBlock(VProgressLinear,{key:1,modelValue:unref(Ve),"onUpdate:modelValue":It[5]||(It[5]=pn=>isRef(Ve)?Ve.value=pn:null),color:"cyan",rounded:"",indeterminate:""},null,8,["modelValue"])):createCommentVNode("",!0),withDirectives(createBaseVNode("div",{class:"w-100 text-center file-tip"},toDisplayString(kt.t(unref(rt))),513),[[vShow,unref(De)]])])):createCommentVNode("",!0)])):createCommentVNode("",!0)]),_:1},8,["height","loading"])]),_:1},8,["onResize"])),[[unref(ve),unref(fe)]])}}}),Footer=_export_sfc$2(_sfc_main$l,[["__scopeId","data-v-3fcd74ac"]]);let uiData;const getUiData=()=>MxFun.getUIData(),useUIData=()=>(uiData||(uiData=getUiData()),uiData);let dynamicInputData,misShow=ref();const onMountedDynInputUpDisplay=t=>{useUIData().mountMxEvent("dynInputUpDisplay",()=>{const l=dynamicInputData.getData();t&&t(l)})},onMountedDynInputSetFocus=t=>{useUIData().mountMxEvent("dynInputSetFocus",l=>{t&&t(l)})},onMountedDynInputReSet=t=>{useUIData().mountMxEvent("dynInputReSet",()=>{t&&t()})},useDynamicInputData=()=>{const t=useUIData();return dynamicInputData||(dynamicInputData=t.getDynamicInput()),{...{misShow},onMountedDynInputUpDisplay,onMountedDynInputSetFocus,onMountedDynInputReSet,dynamicInputData}},selectText=t=>{const e=document,l=window;if(e.selection){const n=e.body.createTextRange();n.moveToElementText(t),n.select()}else if(l.getSelection){const n=e.createRange();l.getSelection().removeAllRanges(),n.selectNodeContents(t),l.getSelection().addRange(n)}},leftWidth=ref(40),rightWidth=ref(40);let _mainRect;const getMainRect=()=>_mainRect,useSideBtnListUIData=t=>{const{mainRect:e}=useLayout();_mainRect=e;const l=ref(uiConfig.mLeftButtonBarData?.isShow),n=ref(uiConfig.mRightButtonBarData?.isShow),u=markRaw(uiConfig.mLeftButtonBarData?.buttonBarData||[]),c=markRaw(uiConfig.mRightButtonBarData?.buttonBarData||[]),y=m=>{const N=(document.body.clientHeight-e.value.top-e.value.bottom)/t;return Math.ceil(m/N)*t},b=m=>{leftWidth.value=l.value?y(u.length):0,rightWidth.value=n.value?y(c.length):0};return onMounted(()=>{b(),watch([()=>e.value.top,()=>e.value.bottom],()=>b()),window.addEventListener("resize",b)}),{isShowLeftBtnList:l,isShowRightBtnList:n,leftBtnListUIData:u,rightBtnListUIData:c,leftWidth,rightWidth}},useDynamicInputBox=(t,e)=>{const{misShow:l,dynamicInputData:n,onMountedDynInputUpDisplay:u,onMountedDynInputSetFocus:c,onMountedDynInputReSet:y}=useDynamicInputData();let b=ref(!1);const m=ref(0),O=ref(0),N=ref(0),L=ref([{isShow:!0,value:"",top:0,left:0,readonly:!0},{isShow:!0,value:"",top:0,left:0,readonly:!1},{isShow:!0,value:"",top:0,left:0,readonly:!1}]),G=ref(0),q=unref(e),J=()=>t.value?.getElementsByClassName(q),fe=ie=>{ie.focus(),selectText(ie)},ve=()=>{const ie=J();G.value>=ie.length-1?(G.value=0,fe(ie[0])):(G.value+=1,fe(ie[G.value]))},ne=ie=>{l.value=ie},Ue=(ie=!0)=>{const ue=J();ue&&(ie?setTimeout(()=>{l.value&&fe(ue[G.value])},200):l.value&&fe(ue[G.value]))};let De=!1;n.getFocusValue=()=>{const ue=J()[G.value];return ue.textContent??ue.innerText},n.getValue1=()=>{const ie=J();return ie[0].textContent??ie[0].innerText},n.getValue2=()=>{const ie=J();return ie[1].textContent??ie[1].innerText},n.getFocusIndex=()=>G.value;const Ve=ie=>{if(n.onKeydown(ie.keyCode),ie.keyCode==32||ie.keyCode==13){const ue=J();if(!ue)return;const pt=ue[G.value];fe(pt)}else De=!0};onMounted(()=>{const{x:ie,y:ue}=useMouse();u(pt=>{if(!pt){l.value&&ne(!1);return}l.value||(G.value=0,ne(!0),Ue(!0)),De&&(Ue(!0),b.value=!b.value,De=!1);const mt=t.value.getElementsByClassName("input_box"),Tt=(tn,pn,_n=0,Dn)=>{let an;typeof Dn=="number"&&t.value&&(an=mt[Dn]?.getBoundingClientRect());const Rn=an?an.width:t.value?.clientWidth??0,Lt=an?an.height:t.value?.clientHeight??0;let wn=tn+_n,hn=pn+_n;const xn=document.getElementById("mxdiv")?.getBoundingClientRect(),$n=xn?.width??0,Xr=xn?.height??0,ti=$n-Rn;wn>ti&&(wn=ti);const gn=Xr-Lt;return hn>gn&&(hn=gn),wn<0&&(wn=0),hn<0&&(hn=0),[wn,hn]},{list:kt}=pt;N.value=pt.postype;const[It,nn]=Tt(pt.pos[0],pt.pos[1],22,pt.postype===1?0:void 0);m.value=It,O.value=nn,L.value.forEach((tn,pn)=>{tn.isShow=kt[pn].show,tn.value=kt[pn].value,tn.readonly=kt[pn].readonly;const _n=kt[pn].pos;if(_n){const Dn=mt[pn]?.getBoundingClientRect();let an=0,Rn=0;an=Dn?.width/2||0,Rn=Dn?.height/2||0;let Lt=_n[0]-an,wn=_n[1]-Rn;const hn=getMainRect()?.value?.top??0,xn=getMainRect()?.value?.bottom??0,$n=getMainRect()?.value?.left??0,Xr=ie.value-leftWidth.value-$n,ti=ue.value-hn,gn=Xr-Lt,Xn=ti-wn,Kn=25,Vn=gn<0?Math.abs(gn)<Kn:gn<Kn+Dn.width,Yn=Xn<0||ti>Kn?Math.abs(Xn)<Kn:Xn<Kn+Dn.height;if(Vn&&Yn){const Si=Xr<leftWidth.value+Kn,qn=ti<hn+Kn,ia=Xr<document.body.clientWidth-leftWidth.value,Wi=ti>document.body.clientHeight-hn-xn-Dn.height-Kn;wn=ti<Kn?wn+Kn*2:wn-Kn*2,Math.abs(Xn)<Kn&&Math.abs(gn)>Dn.width&&(N.value=0,Si&&(m.value+=mt[1]?.getBoundingClientRect().width,m.value+=mt[2]?.getBoundingClientRect().width),ia&&(m.value-=mt[1]?.getBoundingClientRect().width,m.value-=mt[2]?.getBoundingClientRect().width),qn&&(O.value+=mt[1]?.getBoundingClientRect().height,O.value+=mt[2]?.getBoundingClientRect().height),Wi&&(O.value-=mt[1]?.getBoundingClientRect().height,O.value-=mt[2]?.getBoundingClientRect().height))}const[Vr,xi]=Tt(Lt,wn,0,N.value===0?void 0:pn);tn.left=Vr,tn.top=xi}})}),c(pt=>{const{isFocus:mt}=pt??{};mt&&Ue(!1)}),y(()=>{Ue(!0)})});const rt=ie=>{ie.code==="Tab"&&(ie.preventDefault(),ve())},Ae=ie=>{const ue=ie.button;ue==2?Ue(!0):ue==0||(ue==1,Ue(!0))},{setCommandFocus:Te}=useFocus$1(),Xe=()=>L.value.some(ie=>!ie.readonly&&ie.isShow);return keyBindingManager.register({key:{keyCode:"Tab"},when(ie){return!!(ie.isRunCommand&&l.value&&Xe())},action:rt}),watch(l,ie=>{const ue=MxFun.getCurrentDraw().getCanvas();ie&&Xe()?(ue.addEventListener("mouseover",Ae),ue.addEventListener("mousedown",Ae),Te(!1)):(ue.removeEventListener("mouseover",Ae),ue.removeEventListener("mousedown",Ae),Te(!0))}),onUnmounted(()=>{const ie=MxFun.getCurrentDraw().getCanvas();ie.removeEventListener("mouseover",Ae),ie.removeEventListener("mousedown",Ae)}),{isShow:l,posType:N,x:m,y:O,coordinateInputBoxData:L,inputClass:e,focusNextInput:ve,onKeydown:Ve,makeFocus:Ue,updateKey:b,dynamicInputData:n}},_hoisted_1$d=["tabIndex","onInput","contenteditable"],_sfc_main$k=defineComponent$1({__name:"index",setup(t,{expose:e}){const l=ref(),{posType:n,isShow:u,coordinateInputBoxData:c,x:y,y:b,focusNextInput:m,onKeydown:O,makeFocus:N,updateKey:L}=useDynamicInputBox(l,"coordinate"),G=(q,J)=>{const fe=q.target,ve=n.value===0?l.value?.getBoundingClientRect():fe.getBoundingClientRect();if(ve){const ne=document.body.clientWidth-leftWidth.value;n.value===0?fe.style.maxWidth=fe.clientWidth+(ne-ve.right)+"px":fe.style.maxWidth=ne-ve.left+"px"}};return e({makeFocus:N}),(q,J)=>{const fe=resolveDirective("focus-select");return withDirectives((openBlock(),createElementBlock("div",{ref_key:"DynamicInputBox",ref:l,style:normalizeStyle({left:unref(n)===0?unref(y)+"px":"0",top:unref(n)===0?unref(b)+"px":"0",position:"absolute"}),class:normalizeClass(unref(n)===0?"box":"")},[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(c),(ve,ne)=>withDirectives((openBlock(),createElementBlock("span",{class:normalizeClass(["input_box",ve.readonly?"coordinate_text":"coordinate"]),key:ne+unref(L).toString(),tabIndex:ve.readonly?-1:ne+1,onInput:Ue=>G(Ue),onKeydown:[J[0]||(J[0]=withKeys(withModifiers((...Ue)=>unref(m)&&unref(m)(...Ue),["stop","prevent"]),["tab"])),J[1]||(J[1]=(...Ue)=>unref(O)&&unref(O)(...Ue))],style:normalizeStyle({position:unref(n)===0?void 0:"absolute",left:ne===0?unref(y)+"px":ve.left+"px",top:ne===0?unref(b)+"px":ve.top+"px"}),contenteditable:ve.readonly?"false":"true"},[createTextVNode(toDisplayString(q.t("767",()=>unref(translateOnlyChinese)(ve.value))),1)],46,_hoisted_1$d)),[[vShow,ve.isShow],[fe,!ve.readonly]])),128))],6)),[[vShow,unref(u)]])}}}),DynamicInputBox=_export_sfc$2(_sfc_main$k,[["__scopeId","data-v-e3983be3"]]),_sfc_main$j=defineComponent$1({setup(){const{messages:t,removeMessage:e,addMessage:l}=useMessageData();return{messages:t,removeMessage:e,iconCache}}});function _sfc_render$3(t,e,l,n,u,c){return openBlock(!0),createElementBlock(Fragment,null,renderList(t.messages,(y,b)=>(openBlock(),createBlock(VAlert,{key:y.id,width:"auto",position:"absolute",class:"message-alert",location:"top center",style:normalizeStyle({zIndex:1e6,top:y.top+"px"}),"max-height":"55","min-width":"300",type:y.type,"onClick:close":m=>t.removeMessage(y)},{prepend:withCtx(()=>[createVNode(VIcon,{icon:t.iconCache[y.type].icon,class:"rounded-circle mt-1",color:t.iconCache[y.type].color},null,8,["icon","color"])]),default:withCtx(()=>[createTextVNode(toDisplayString(y.message)+" ",1)]),_:2},1032,["style","type","onClick:close"]))),128)}const Message=_export_sfc$2(_sfc_main$j,[["render",_sfc_render$3],["__scopeId","data-v-fc2d9726"]]),cursorType=ref("Normal"),updateCursor=t=>{cursorType.value=t},targetFrameSize=browserCacheRef(10,"Mx_targetFrameSize"),cursorSize=browserCacheRef(128,"Mx_cursorSize");let color;const getCursorStyles=()=>MxTools.createCursor(cursorSize.value,targetFrameSize.value,color),_cursorStyles=getCursorStyles();let cursorStyles=ref(_cursorStyles);const updateCursorStyles=()=>{cursorStyles.value=getCursorStyles()};function getContrast50(t,e,l){return .213*t+.715*e+.072*l>255/2?"#000000":"#ffffff"}const cursor=computed(()=>cursorStyles.value[cursorType.value]);MxFun.on("updateBackgroundColor",t=>{const e=getContrast50(t.red,t.green,t.blue);MxCpp.getCurrentMxCAD().updateDisplay(),color!==e&&(color=e,updateCursorStyles(),updateCursor(cursorType.value))});const mountAutoUpdateCursor=()=>{MxFun.getUIData().mountUpdateCursorFun(t=>{updateCursor(t)})},useCursorStyle=()=>({cursor,mountAutoUpdateCursor,updateCursor,type:cursorType,size:cursorSize,targetFrameSize,cursorStyles}),layouts=ref([{name:"Model"}]),index=ref(0);onOpenFileComplete(()=>{let t=[];MxCpp.App.getCurrentMxCAD().getAllLayoutName().forEach(e=>{e==="Model"?t.unshift({name:e}):t.push({name:e})}),layouts.value=t,index.value=0});const setLayout=t=>{if(typeof t=="number"){MxCpp.App.getCurrentMxCAD().setCurrentLayout(layouts.value[t].name),MxFun.getCurrentDraw().updateDisplay(),index.value=t;return}MxCpp.App.getCurrentMxCAD().setCurrentLayout(t),MxFun.getCurrentDraw().updateDisplay();const e=layouts.value.findIndex(l=>t===l.name);e>=0&&(index.value=e)},useDrawingModelLayer=()=>({layouts,index,setLayout}),_hoisted_1$c={key:0,class:"modelNav"},_hoisted_2$9=["onClick"],_sfc_main$i=defineComponent$1({__name:"ModelNav",setup(t){const{layouts:e,index:l,setLayout:n}=useDrawingModelLayer();return(u,c)=>unref(uiConfig).isShowModelNav?(openBlock(),createElementBlock("div",_hoisted_1$c,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(e),(y,b)=>(openBlock(),createElementBlock("span",{class:normalizeClass(["nav",b===unref(l)?"nav-active":""]),onClick:m=>unref(n)(b)},toDisplayString(y.name),11,_hoisted_2$9))),256))])):createCommentVNode("",!0)}}),ModelNav=_export_sfc$2(_sfc_main$i,[["__scopeId","data-v-ff21fe72"]]),getDefaultMenuList=()=>[{label:scopedTtranslate("204"),tips:"New",fn(){callCommand("Mx_NewFile")}},{label:scopedTtranslate("349"),tips:"Open",fn:function(){callCommand("OpenDwg")},children:[{label:scopedTtranslate("350"),tips:scopedTtranslate("351"),fn(){callCommand("OpenDwg")}},{label:scopedTtranslate("352"),tips:scopedTtranslate("353"),fn(){callCommand("OpenDwg_DoNotUseCache")}}]},{label:scopedTtranslate("354"),tips:"CAD",fn(){callCommand("Mx_SaveAs")},children:[{label:"MxWeb"+scopedTtranslate("219"),tips:scopedTtranslate("356"),fn(){callCommand("Mx_SaveAs")}},{label:"Dwg"+scopedTtranslate("219"),tips:"AutoCad"+scopedTtranslate("160"),fn(){callCommand("Mx_Export_DWG")}}]},{label:scopedTtranslate("154"),tips:"Print",fn(){callCommand("Mx_PrintDialog")}}],events=[];let _mRightMenuData;const getDefaultRightMenu=()=>_mRightMenuData||(_mRightMenuData=uiConfig?.mRightMenuData?.map(({cmd:t,...e})=>(e.children&&(e.children=e.children.map(({cmd:l,...n})=>({...n,fn(){l&&callCommand(l)}}))),{...e,fn(){t&&callCommand(t)}})),_mRightMenuData||getDefaultMenuList()),rightMenuOptions=useRightClickMenuOptions({menuList:getDefaultRightMenu(),disabled:()=>{const t=[];return events.forEach(e=>{t.push(...e())}),t.length===0&&t.push(...getDefaultRightMenu()),setRightMenuListData(t),MxFun.isRunningCommand()}}),onAddRightMenuListData=t=>(events.push(t),()=>{const e=events.indexOf(t);e>=0&&events.splice(e,1)}),setRightMenuListData=t=>{rightMenuOptions.menuList=t};onAddRightMenuListData(()=>MxCADUtility.getCurrentSelect().length>0?[{label:scopedTtranslate("148"),tips:"Delete",fn(){callCommand("Mx_Erase")}},{label:scopedTtranslate("207"),tips:"Copy",fn(){callCommand("Mx_CopyClip")}},{label:scopedTtranslate("206"),tips:"Cut",fn(){callCommand("Mx_CutClip")}},{label:scopedTtranslate("209"),tips:"Paste",fn(){callCommand("Mx_PasteClip")},disabled:()=>!isCopyAryId()},{label:scopedTtranslate("521"),tips:"Move",fn(){callCommand("Mx_Move")}},{label:scopedTtranslate("522"),tips:"Scale",fn(){callCommand("Mx_Scale")}},{label:scopedTtranslate("414"),tips:"Rotate",fn(){callCommand("Mx_Rotate")}},{label:scopedTtranslate("523"),tips:"Esc",fn(){const e=MxCpp.getCurrentMxCAD();e.mxdraw.clearMxCurrentSelect(),e.updateDisplay()}}]:getDefaultMenuList());const useMainRightClickMenu=()=>({rightMenuOptions}),_hoisted_1$b={key:1,id:"mx_map"},_hoisted_2$8={key:2,id:"myCanvas"},_sfc_main$h=defineComponent$1({__name:"index",setup(t){const{isFirstTimeOpen:e}=useFirstTimeOpenDwg(),{cursor:l,mountAutoUpdateCursor:n}=useCursorStyle(),{map:u}=getParamsFromUrl(),c=u==="true",{mainRect:y}=useMxCad("myCanvas",c),{isShowLeftBtnList:b,isShowRightBtnList:m,leftBtnListUIData:O,rightBtnListUIData:N,leftWidth:L,rightWidth:G}=useSideBtnListUIData(44),{rightMenuOptions:q}=useMainRightClickMenu(),J=computed(()=>`calc(100% - ${L.value+G.value}px)`),fe=computed(()=>`calc(100vh - ${y.value.bottom+y.value.top}px)`);onMounted(()=>{n()});const ve=ne=>{ne?.cmd&&callCommand(ne?.cmd)};return(ne,Ue)=>{const De=resolveDirective("right-click-menu");return openBlock(),createBlock(unref(VMain),null,{default:withCtx(()=>[createBaseVNode("div",{class:"d-flex",style:normalizeStyle({height:fe.value})},[unref(e)?createCommentVNode("",!0):(openBlock(),createBlock(VSkeletonLoader,{key:0,type:"paragraph",class:"h-100",width:unref(L)},null,8,["width"])),unref(b)&&unref(e)?(openBlock(),createBlock(MxBtnList,{key:1,style:{"z-index":"2"},width:unref(L),"bg-color":"prominent",class:"flex-column flex-wrap-reverse",onChange:ve,list:unref(O)},null,8,["width","list"])):createCommentVNode("",!0),withDirectives((openBlock(),createElementBlock("div",{class:"mxbox",style:normalizeStyle({width:J.value})},[createBaseVNode("div",{id:"mxdiv",class:"pa-0 overflow-hidden",style:normalizeStyle({cursor:unref(l)}),ref:"canvasBox"},[unref(e)?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(DynamicInputBox,{ref:"dynamicInputBox"},null,512),createVNode(Message)],64)):createCommentVNode("",!0),c?(openBlock(),createElementBlock("div",_hoisted_1$b)):(openBlock(),createElementBlock("canvas",_hoisted_2$8))],4),createVNode(VSkeletonLoader,{loading:!unref(e),type:"heading",class:"w-100",height:20},{default:withCtx(()=>[createVNode(ModelNav)]),_:1},8,["loading"])],4)),[[De,unref(q)]]),unref(e)?createCommentVNode("",!0):(openBlock(),createBlock(VSkeletonLoader,{key:2,type:"paragraph",class:"h-100",width:unref(G)},null,8,["width"])),unref(m)&&unref(e)?(openBlock(),createBlock(MxBtnList,{key:3,style:{"z-index":"2"},width:unref(G),"bg-color":"prominent",class:"flex-column flex-wrap-reverse",onChange:ve,list:unref(N),location:"right"},null,8,["width","list"])):createCommentVNode("",!0)],4)]),_:1})}}}),useDrawer=(t,e)=>{const n=browserCacheRef(0,"Mx_"+t.join("_")+"drawer_width"),u=computed(()=>n.value>0),{vResize:c,resizeOptions:y}=useResize({direction:t});return{width:n,isShow:u,resizeOptions:y,handleResize:N=>{if(N.resizeWidth&&N.resizeWidth){const L=160-N.resizeWidth>0?160-N.resizeWidth:0;n.value=N.resizeWidth+L,n.value>800&&(n.value=800),e&&e(n.value)}},vResize:c,handleClose:()=>{n.value=0},handleOpen:(N=300)=>{n.value<=0&&(n.value=N),e&&e(n.value)}}},_hoisted_1$a={class:"w-100 d-flex px-1 align-center justify-space-between bg-background rounded-t drawer_title"},_sfc_main$g=defineComponent$1({__name:"Drawer",props:{location:{},title:{},components:{}},emits:["close"],setup(t,{expose:e,emit:l}){const n=computed(()=>t.location==="left"?"right":"left"),u=[],{width:c,isShow:y,resizeOptions:b,handleResize:m,vResize:O,handleClose:N,handleOpen:L}=useDrawer([n.value],ne=>{u.forEach(Ue=>{Ue(ne)})}),G=ne=>{typeof ne=="function"&&(ne(c.value),u.push(ne))},{mainRect:q}=useLayout(),J=computed(()=>`width: ${c.value}px; height: calc(100% - ${q.value.top}px); top: ${q.value.top}px; ${t.location}: 0;`);watch(t.components.map(({isShow:ne})=>ne),ne=>{ne.every(Ue=>!Ue)&&(N(),fe("close"))}),e({isShow:y,handleOpen:L,handleClose:N});const fe=l,{isFirstTimeOpen:ve}=useFirstTimeOpenDwg();return(ne,Ue)=>(openBlock(),createElementBlock(Fragment,null,[withDirectives(createBaseVNode("div",{class:"resize-line",style:normalizeStyle(J.value),onResize:Ue[0]||(Ue[0]=(...De)=>unref(m)&&unref(m)(...De))},null,36),[[vShow,unref(y)],[unref(O),unref(b)]]),createVNode(VNavigationDrawer,{"model-value":unref(y),"onUpdate:modelValue":Ue[2]||(Ue[2]=De=>isRef(y)?y.value=De:null),permanent:"",width:unref(c),location:ne.location,class:"pa-1 bg-prominent drawer"},{default:withCtx(()=>[unref(ve)?(openBlock(),createElementBlock(Fragment,{key:0},[createBaseVNode("div",_hoisted_1$a,[createBaseVNode("span",null,toDisplayString(ne.title?ne.t(ne.title):""),1),createVNode(VBtn,{size:"x-small",icon:"",variant:"plain",onClick:Ue[1]||(Ue[1]=De=>fe("close",!0))},{default:withCtx(()=>[createVNode(VIcon,{icon:"cha",size:"x-small"})]),_:1})]),(openBlock(),createBlock(KeepAlive,null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(ne.components,(De,Ve)=>(openBlock(),createBlock(resolveDynamicComponent(De.component),{key:De.cmd||De.component.name||Ve,onResize:G},null,32))),128))],1024))],64)):createCommentVNode("",!0)]),_:1},8,["model-value","width","location"])],64))}}),Drawer=_export_sfc$2(_sfc_main$g,[["__scopeId","data-v-73120510"]]),isShowDrawingComparison=browserCacheRef(!1,"Mx_isShowDrawingComparison"),useDrawingComparison=()=>({isShowDrawingComparison}),_hoisted_1$9={class:"mx_drawing_comparison_box"},_hoisted_2$7={class:"w-100 ma-0 mt-1 bg-background text-left pl-2"},_hoisted_3$5={class:"w-100"},_hoisted_4$4={class:"w-100"},_hoisted_5$3={class:"w-100"},_hoisted_6$2={class:"text-left pa-1 w-50 disabled"},_hoisted_7$1={class:"text-left pa-1 w-50 disabled"},_hoisted_8$1={class:"w-100"},_hoisted_9$1={class:"pa-1 w-50"},_hoisted_10$1={class:"w-100 ma-0 mt-2 bg-background text-left pl-2"},_sfc_main$f=defineComponent$1({__name:"DrawingComparison",setup(t){const{isShowDrawingComparison:e}=useDrawingComparison();return(l,n)=>withDirectives((openBlock(),createElementBlock("div",_hoisted_1$9,[createVNode(VBtn,{class:"w-100 mt-1 bg-depth border",variant:"text",size:"small"},{default:withCtx(()=>[createTextVNode(toDisplayString(l.t("749")),1)]),_:1}),createVNode(VBtn,{class:"w-100 mt-1 bg-undertint border",variant:"text",size:"small"},{default:withCtx(()=>[createTextVNode(toDisplayString(l.t("750")),1)]),_:1}),createBaseVNode("div",_hoisted_2$7,toDisplayString(l.t("751")),1),createBaseVNode("table",_hoisted_3$5,[createBaseVNode("thead",_hoisted_4$4,[createBaseVNode("tr",_hoisted_5$3,[createBaseVNode("th",_hoisted_6$2,toDisplayString(l.t("173")),1),createBaseVNode("th",_hoisted_7$1,toDisplayString(l.t("752")),1)])]),createBaseVNode("tbody",_hoisted_8$1,[createBaseVNode("tr",null,[n[0]||(n[0]=createBaseVNode("td",{class:"pa-1 w-50"},[createBaseVNode("span",{class:"w-100"},"(-1515,1212)")],-1)),createBaseVNode("td",_hoisted_9$1,toDisplayString(l.t("148")),1)])])]),createBaseVNode("div",_hoisted_10$1,toDisplayString(l.t("753")),1),n[1]||(n[1]=createBaseVNode("div",{style:{background:"#000",width:"100%",height:"300px"}},null,-1))],512)),[[vShow,unref(e)]])}}),DrawingComparison=_export_sfc$2(_sfc_main$f,[["__scopeId","data-v-036c9aa8"]]),_sfc_main$e=defineComponent$1({__name:"MxGetPointBtn",props:{disabled:{type:Boolean,default:!1},size:{default:24},text:{default:"取点"},icon:{default:"a-zu20"}},setup(t){const e=useAttrs();return(l,n)=>(openBlock(),createBlock(VTooltip,{theme:"light",link:"","open-delay":0,text:l.text},{activator:withCtx(({props:u})=>[createVNode(VBtn,mergeProps({...unref(e),...u},{size:l.size,disabled:l.disabled,rounded:"sm",icon:"",variant:"plain",class:"box-shadow mx-1"}),{default:withCtx(()=>[createVNode(VIcon,{icon:l.icon,color:"#fff"},null,8,["icon"])]),_:2},1040,["size","disabled"])]),_:1},8,["text"]))}}),MxGetPointBtn=_export_sfc$2(_sfc_main$e,[["__scopeId","data-v-af3ec40c"]]),_hoisted_1$8={class:"w-100"},_hoisted_2$6={class:"w-100"},_hoisted_3$4={class:"pa-1 w-25",style:{"min-width":"100px"}},_hoisted_4$3=["for"],_hoisted_5$2={class:"pa-1 w-75"},_hoisted_6$1={class:"d-flex"},_hoisted_7=["type","id","disabled","onUpdate:modelValue"],_hoisted_8=["id","disabled","onUpdate:modelValue"],_hoisted_9={class:"select-box"},_hoisted_10={class:"text"},_hoisted_11={key:3,class:"getPointBtn"},_hoisted_12={class:"w-100"},_hoisted_13={class:"w-100"},_hoisted_14={class:"w-100"},_hoisted_15={class:"pa-1"},_hoisted_16={class:"w-100"},_sfc_main$d=defineComponent$1({__name:"EntityAttribute",setup(t){const e=useRightDrawer(),{selects:l,selectItem:n,isSelected:u,types:c,type:y,isNotData:b,isShowEntityAttribute:m,update:O}=e,{setCommandFocus:N}=useFocus$1(),L=()=>{N(!1)},G=()=>{N(!0)},{categoryNames:q,categoryToEntityPropMap:J}=useDefineUIProp(),fe=computed(()=>u.value&&!b.value);return keyBindingManager.register({key:{keyCode:"Escape"},when(){return u.value},action(){u.value=!1}}),(ve,ne)=>withDirectives((openBlock(),createElementBlock("div",null,[createVNode(VRow,null,{default:withCtx(()=>[createVNode(VCol,{cols:"3"},{default:withCtx(()=>[createVNode(VSelect,{items:unref(c),modelValue:unref(y),"onUpdate:modelValue":[ne[0]||(ne[0]=Ue=>isRef(y)?y.value=Ue:null),unref(O)],modelModifiers:{lazy:!0},class:"mt-2 mb-2"},{selection:withCtx(({item:Ue})=>[createTextVNode(toDisplayString(ve.t(Ue.title)),1)]),item:withCtx(({item:Ue,props:De})=>[createVNode(VListItem,mergeProps(De,{title:ve.t(Ue.title)}),null,16,["title"])]),_:1},8,["items","modelValue","onUpdate:modelValue"])]),_:1}),createVNode(VCol,{cols:"9"},{default:withCtx(()=>[createVNode(VSelect,{items:unref(l),modelValue:unref(n),"onUpdate:modelValue":[ne[1]||(ne[1]=Ue=>isRef(n)?n.value=Ue:null),unref(O)],modelModifiers:{lazy:!0},class:"mt-2 mb-2"},{selection:withCtx(({item:Ue})=>[createTextVNode(toDisplayString(ve.t("767",()=>unref(translateOnlyChinese)(Ue.title))),1)]),item:withCtx(({item:Ue,props:De})=>[createVNode(VListItem,mergeProps(De,{title:ve.t("767",()=>unref(translateOnlyChinese)(Ue.title))}),null,16,["title"])]),_:1},8,["items","modelValue","onUpdate:modelValue"])]),_:1})]),_:1}),createBaseVNode("div",{class:"overflow-auto",style:normalizeStyle(`max-height: calc(100vh - ${unref(isElectron)()?"218":"200"} px)`)},[fe.value?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(unref(q),Ue=>(openBlock(),createBlock(VExpansionPanels,{static:"",variant:"accordion",class:"w-100","model-value":[Ue],key:Ue},{default:withCtx(()=>[createVNode(VExpansionPanel,{class:"item",eager:"",value:Ue},{default:withCtx(()=>[createVNode(VExpansionPanelTitle,{class:"bg-background"},{default:withCtx(()=>[createTextVNode(toDisplayString(ve.t(Ue)),1)]),_:2},1024),createVNode(VExpansionPanelText,{eager:""},{default:withCtx(()=>[createBaseVNode("table",_hoisted_1$8,[createBaseVNode("tbody",_hoisted_2$6,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(J).get(Ue)?.sort((De,Ve)=>unref(De.order||0)-unref(Ve.order||0)),(De,Ve)=>(openBlock(),createElementBlock(Fragment,null,[De.isShowRef.value?(openBlock(),createElementBlock("tr",{key:0,class:normalizeClass(["w-100",unref(De.disabled)?"disabled":""])},[createBaseVNode("td",_hoisted_3$4,[createBaseVNode("label",{for:unref(De.type)==="input"||unref(De.type)==="string"?Ue+"input__id__"+Ve:""},toDisplayString(ve.t("767",()=>unref(translateOnlyChinese)(unref(De.label)))),9,_hoisted_4$3)]),createBaseVNode("td",_hoisted_5$2,[createBaseVNode("div",_hoisted_6$1,[unref(De.type)==="input"||unref(De.type)==="string"?(openBlock(),createElementBlock(Fragment,{key:0},[unref(De.disabled)?(openBlock(),createBlock(VTooltip,{key:0,"open-delay":"500",text:String(De.ref.value)},{activator:withCtx(({props:rt})=>[withDirectives(createBaseVNode("input",mergeProps({type:unref(De.type)==="string"?"text":typeof De.ref.value,class:"w-100",id:Ue+"input__id__"+Ve},toHandlers(De.onEvents,!0),{disabled:unref(De.disabled),ref_for:!0},{...rt,...De.inputProps},{"onUpdate:modelValue":Ae=>De.ref.value=Ae,onFocus:L,onBlur:G}),null,16,_hoisted_7),[[vModelDynamic,De.ref.value,void 0,{lazy:!0}]])]),_:2},1032,["text"])):withDirectives((openBlock(),createElementBlock("input",mergeProps({key:1,class:"w-100",id:Ue+"input__id__"+Ve},toHandlers(De.onEvents,!0),{disabled:unref(De.disabled),ref_for:!0},De.inputProps,{"onUpdate:modelValue":rt=>De.ref.value=rt,onFocus:L,onBlur:G}),null,16,_hoisted_8)),[[vModelDynamic,De.ref.value,void 0,{lazy:!0}]])],64)):createCommentVNode("",!0),unref(De.type)==="color"?(openBlock(),createBlock(VSelect,mergeProps({key:1,ref_for:!0},De.vSelectProps,toHandlers(De.onEvents),{items:isRef(De.vSelectProps.items)?De.vSelectProps.items.value:De.vSelectProps.items,modelValue:De.ref.value,"onUpdate:modelValue":rt=>De.ref.value=rt,modelModifiers:{lazy:!0},disabled:unref(De.disabled)}),{selection:withCtx(({item:rt})=>[createBaseVNode("div",_hoisted_9,[createBaseVNode("span",{class:"colorBox",style:normalizeStyle(`background:${rt.raw[De.vSelectProps?De.vSelectProps.itemValue:"color"]}`)},null,4),createBaseVNode("span",_hoisted_10,toDisplayString(ve.t(rt.raw[De.vSelectProps?De.vSelectProps.itemTitle:"name"])),1)])]),item:withCtx(({item:rt,props:Ae})=>[createVNode(VListItem,mergeProps({ref_for:!0},Ae,{title:ve.t(rt.title)}),{prepend:withCtx(()=>[createBaseVNode("span",{class:"colorBox ml-1",style:normalizeStyle(`background:${rt.raw[De.vSelectProps?De.vSelectProps.itemValue:"color"]}`)},null,4)]),_:2},1040,["title"])]),"prepend-item":withCtx(()=>[createVNode(VListItem,{onClick:withModifiers(rt=>De.onColor||void 0,["stop"]),title:ve.t("111")},{prepend:withCtx(()=>[createVNode(VIcon,{icon:"yanse",style:{"margin-right":"10px"},class:"ml-1",size:"14"})]),_:2},1032,["onClick","title"])]),_:2},1040,["items","modelValue","onUpdate:modelValue","disabled"])):createCommentVNode("",!0),De.type==="select"?(openBlock(),createBlock(VSelect,mergeProps({key:2,ref_for:!0},De.vSelectProps,toHandlers(De.onEvents),{items:isRef(De.vSelectProps.items)?De.vSelectProps.items.value:De.vSelectProps.items,disabled:unref(De.disabled),modelValue:De.ref.value,"onUpdate:modelValue":rt=>De.ref.value=rt,modelModifiers:{lazy:!0}}),{selection:withCtx(({item:rt})=>[createTextVNode(toDisplayString(De.isTranslationVSelectTitle?ve.t("767",()=>unref(translateOnlyChinese)(rt.title)):rt.title),1)]),item:withCtx(({item:rt,props:Ae})=>[createVNode(VListItem,mergeProps({ref_for:!0},Ae,{title:De.isTranslationVSelectTitle?ve.t("767",()=>unref(translateOnlyChinese)(rt.title)):rt.title}),null,16,["title"])]),_:2},1040,["items","disabled","modelValue","onUpdate:modelValue"])):createCommentVNode("",!0),unref(De.getPoint)?(openBlock(),createElementBlock("div",_hoisted_11,[createVNode(MxGetPointBtn,{size:"18",onClick:()=>{isRef(De.getPoint)?De.getPoint.value():De&&De.getPoint&&De.getPoint()},icon:De.getPointIcon,text:De.getPointTip},null,8,["onClick","icon","text"])])):createCommentVNode("",!0)])])],2)):createCommentVNode("",!0)],64))),256))])])]),_:2},1024)]),_:2},1032,["value"])]),_:2},1032,["model-value"]))),128)):(openBlock(),createBlock(VExpansionPanels,{key:1,variant:"accordion",multiple:"",class:"w-100","model-value":0},{default:withCtx(()=>[createVNode(VExpansionPanel,{class:"item"},{default:withCtx(()=>[createVNode(VExpansionPanelTitle,{class:"bg-background"},{default:withCtx(()=>[createTextVNode(toDisplayString(ve.t("195")),1)]),_:1}),createVNode(VExpansionPanelText,{eager:"",class:"ml-2"},{default:withCtx(()=>[createBaseVNode("table",_hoisted_12,[createBaseVNode("tbody",_hoisted_13,[createBaseVNode("tr",_hoisted_14,[createBaseVNode("td",_hoisted_15,[createBaseVNode("span",_hoisted_16,toDisplayString(ve.t("196")),1)]),ne[2]||(ne[2]=createBaseVNode("td",{class:"pa-1"},[createBaseVNode("input",{class:"w-100",value:"1.0",disabled:!0})],-1))])])])]),_:1})]),_:1})]),_:1}))],4)],512)),[[vShow,unref(m)]])}}),EntityAttribute=_export_sfc$2(_sfc_main$d,[["__scopeId","data-v-2dfa7500"]]),_sfc_main$c=defineComponent$1({__name:"MxDialogBtn",props:{primary:{type:Boolean},isAction:{type:Boolean}},setup(t){return(e,l)=>(openBlock(),createBlock(VBtn,{size:e.isAction?void 0:"30",style:normalizeStyle(e.isAction?void 0:"width: auto"),class:normalizeClass(["dialog-btn",e.primary?"bg-light-blue-darken-1":"bg-undertint-bg"]),"min-width":"76",variant:"text",rounded:"sm"},{default:withCtx(()=>[renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},8,["size","style","class"]))}}),MxDialogBtn=_export_sfc$2(_sfc_main$c,[["__scopeId","data-v-bd9fbcba"]]),_sfc_main$b=defineComponent$1({__name:"MxFieldset",props:{title:{default:""}},setup(t){return(e,l)=>(openBlock(),createElementBlock("fieldset",null,[createBaseVNode("legend",null,toDisplayString(e.t(e.title)),1),renderSlot(e.$slots,"default",{},void 0,!0)]))}}),MxFieldset=_export_sfc$2(_sfc_main$b,[["__scopeId","data-v-f6ce167b"]]),_hoisted_1$7={key:1},_sfc_main$a=defineComponent$1({__name:"MxLabel",props:{keyName:{},colon:{type:Boolean},noTextCaption:{type:Boolean}},setup(t){return(e,l)=>(openBlock(),createElementBlock("span",{class:normalizeClass((e.noTextCaption,""))},[renderSlot(e.$slots,"default"),e.keyName?(openBlock(),createElementBlock(Fragment,{key:0},[l[0]||(l[0]=createTextVNode("(")),createBaseVNode("span",null,toDisplayString(e.keyName),1),l[1]||(l[1]=createTextVNode(")"))],64)):createCommentVNode("",!0),e.colon?(openBlock(),createElementBlock("span",_hoisted_1$7,":")):createCommentVNode("",!0)],2))}}),isShowTextSearch=browserCacheRef(!1,"Mx_isShowTextSearch"),useTextSearch=()=>({isShowTextSearch}),_hoisted_1$6={class:"mx_text_search_box"},_hoisted_2$5={class:"d-flex align-center"},_hoisted_3$3={class:"d-flex justify-space-between align-center mt-2"},_hoisted_4$2={class:"d-flex align-center"},_hoisted_5$1={class:"ml-1"},_sfc_main$9=defineComponent$1({__name:"TextSearch",setup(t){const{isShowTextSearch:e}=useTextSearch(),{setCommandFocus:l}=useFocus$1(),n=()=>{l(!1)},u=()=>{l(!0)},c=ref(!1),y=ref(!1),b=ref([]),m=ref([]),O=(Xe,ie,ue=16711680)=>{const pt=Xe.toVector3(),mt=ie.toVector3(),Tt=new THREE.Vector3(pt.x,mt.y),kt=new THREE.Vector3(mt.x,pt.y);return MxThreeJS.createLines([pt,Tt,mt,kt,pt],ue)},N=ref(""),L=ref(""),G=ref(0);let q;const J=async(Xe=!1)=>{const ie=new MxCADResbuf;ie.AddMcDbEntityTypes("TEXT,MTEXT");const ue=Xe||!q;ue&&(q=new MxCADSelectionSet),G.value===0&&q.allSelect(ie);const pt=MxCpp.App.getCurrentMxCAD();if(G.value===1){q.isWhileSelect=!0,ue&&await q.userSelect("选取区域:",ie);const{pt1:mt,pt2:Tt}=q.getSelectPoint(),kt=O(Tt,mt,65280);pt.mxdraw.getTempMarkDraw().clear(),pt.mxdraw.getTempMarkDraw().drawEntity(kt),updateDisplay()}return G.value,q},fe=async()=>{const Xe=await J(),ie=[];return Xe.forEach(ue=>{const pt=ue.getMcDbEntity();ie.push(pt)}),ie};let ve=[];const ne=ref([]),Ue=async()=>{if(N.value==="")return;b.value.includes(N.value)||b.value.unshift(N.value),ve=(await fe()).filter(ue=>ue instanceof McDbMText?y.value?N.value===ue.contents:ue.contents.includes(N.value):ue instanceof McDbText?y.value?N.value===ue.textString:ue.textString.includes(N.value):!1);const ie=[];ve.forEach((ue,pt)=>{ue instanceof McDbMText&&ie.push({text:ue.contents,index:pt}),ue instanceof McDbText&&ie.push({text:ue.textString,index:pt})}),ne.value=ie},De=ref(-1),Ve=Xe=>{De.value=Xe;const ie=MxCpp.App.getCurrentMxCAD(),ue=ve[Xe],{minPt:pt,maxPt:mt}=ue.getBoundingBox(),Tt=ie.mxdraw.getTempMarkDraw();Tt.clear();const kt=pt.distanceTo(mt),It=pt.clone(),nn=mt.clone(),tn=(ue instanceof McDbText?ue.height:ue.textHeight)/2;It.x-=tn,It.y-=tn,nn.x+=tn*3,nn.y+=tn;const pn=O(It,nn,16711680);Tt.drawCircleMark(new McGePoint3d((It.x+nn.x)/2,(It.y+nn.y)/2).toVector3(),kt,16711680),Tt.drawEntity(pn);const _n=(ue instanceof McDbText?ue.height:ue.textHeight)*10;pt.x-=_n,pt.y-=_n,mt.x+=_n,mt.y+=_n,ie.zoomW(pt,mt)};watch(y,Ue),watch(e,()=>{N.value=""});const rt=Xe=>{if(Xe instanceof McDbMText){Xe.contents=Xe.contents.replaceAll(N.value,L.value);return}if(Xe instanceof McDbText){Xe.textString=Xe.textString.replaceAll(N.value,L.value);return}},Ae=()=>{if(De.value>=0){const Xe=ve[De.value];rt(Xe),Ue(),updateDisplay()}},Te=async()=>{ve.length>0&&(ve.forEach((Xe,ie)=>{rt(Xe)}),await Ue(),updateDisplay())};return(Xe,ie)=>withDirectives((openBlock(),createElementBlock("div",_hoisted_1$6,[createVNode(_sfc_main$a,{colon:""},{default:withCtx(()=>[createTextVNode(toDisplayString(Xe.t("185")+Xe.t("186")),1)]),_:1}),createBaseVNode("div",_hoisted_2$5,[createVNode(VCombobox,{class:"mb-1",items:b.value,"onUpdate:focused":n,onBlur:u,modelValue:N.value,"onUpdate:modelValue":ie[0]||(ie[0]=ue=>N.value=ue),onKeyup:withKeys(Ue,["enter"])},null,8,["items","modelValue"]),createVNode(MxDialogBtn,{onClick:Ue,class:"ml-5"},{default:withCtx(()=>[createTextVNode(toDisplayString(Xe.t("185")),1)]),_:1})]),createVNode(MxFieldset,{title:Xe.t("185")+Xe.t("187"),class:"mb-1"},{default:withCtx(()=>[createVNode(VRadioGroup,{modelValue:G.value,"onUpdate:modelValue":ie[1]||(ie[1]=ue=>G.value=ue)},{default:withCtx(()=>[createVNode(VRadio,{label:Xe.t("188")+Xe.t("185"),value:0,class:"ml-1"},null,8,["label"]),createVNode(VRadio,{label:Xe.t("189")+Xe.t("163")+Xe.t("185"),value:1,class:"ml-1"},null,8,["label"])]),_:1},8,["modelValue"]),createBaseVNode("div",_hoisted_3$3,[createVNode(VCheckbox,{class:"ml-1",modelValue:y.value,"onUpdate:modelValue":ie[2]||(ie[2]=ue=>y.value=ue)},{label:withCtx(()=>[createTextVNode(toDisplayString(Xe.t("191")+Xe.t("192")),1)]),_:1},8,["modelValue"]),createVNode(VCheckbox,{class:"ml-1",modelValue:c.value,"onUpdate:modelValue":ie[3]||(ie[3]=ue=>c.value=ue)},{label:withCtx(()=>[createTextVNode(toDisplayString(Xe.t("193")+Xe.t("186")),1)]),_:1},8,["modelValue"]),createVNode(MxDialogBtn,{disabled:G.value===0,onClick:ie[4]||(ie[4]=ue=>{J(!0)})},{default:withCtx(()=>[createTextVNode(toDisplayString(Xe.t("163")+Xe.t("167")),1)]),_:1},8,["disabled"])])]),_:1},8,["title"]),c.value?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(_sfc_main$a,{colon:""},{default:withCtx(()=>[createTextVNode(toDisplayString(Xe.t("193")+Xe.t("186")),1)]),_:1}),createBaseVNode("div",_hoisted_4$2,[createVNode(VCombobox,{items:m.value,modelValue:L.value,"onUpdate:modelValue":ie[5]||(ie[5]=ue=>L.value=ue),"onUpdate:focused":n,onBlur:u},null,8,["items","modelValue"]),createBaseVNode("div",_hoisted_5$1,[createVNode(MxDialogBtn,{onClick:Te,class:"mr-1"},{default:withCtx(()=>[createTextVNode(toDisplayString(Xe.t("194")+Xe.t("193")),1)]),_:1}),createVNode(MxDialogBtn,{onClick:Ae},{default:withCtx(()=>[createTextVNode(toDisplayString(Xe.t("193")),1)]),_:1})])])],64)):createCommentVNode("",!0),createVNode(VVirtualScroll,{items:ne.value,height:`calc(100vh - ${c.value?unref(isElectron)()?400:414:unref(isElectron)()?364:345}px)`,class:"search_list"},{default:withCtx(({item:ue})=>[createVNode(VListItem,{title:ue.text,active:ue.index===De.value,onClick:pt=>Ve(ue.index)},null,8,["title","active","onClick"])]),_:1},8,["items","height"])],512)),[[vShow,unref(e)]])}}),TextSearch=_export_sfc$2(_sfc_main$9,[["__scopeId","data-v-fc27bf5a"]]),isShowBlockLibrary=browserCacheRef(!1,"Mx_isShowBlockLibrary");var GalleryType=(t=>(t[t.Drawings=0]="Drawings",t[t.Blocks=1]="Blocks",t))(GalleryType||{});const galleryType=browserCacheRef(1,"Mx_useBlockLibrary_galleryType"),galleryTypes=[{title:"图纸库",value:0},{title:"图块库",value:1}],useBlockLibrary=()=>{const t=ref(0),e=ref([]),l=50,n=ref(15),u=ref(""),c=ref("intersect"),y=()=>{c.value="manual",nextTick(()=>{c.value="intersect"})},b=()=>galleryType.value===1?"blocks":galleryType.value===0?"drawings":"",m=ref(),O=ref(),N=ref(-1),L=computed(()=>O.value?.list||[]),G=ref(0);let q=0,J=0;const fe=()=>{J=q=t.value=0,e.value=[],Ve.value="全部",G.value++},ve=async()=>{J=q=t.value,G.value++,e.value=[],Ve.value="全部"};watch(O,async()=>{fe(),y(),N.value=O.value?.list[0].id||-1}),watch(N,async()=>{fe(),y(),Te("end",await Ue(),()=>{})});const ne=new Map,Ue=async(pt=t.value-1)=>{const mt=getBaseUrl(),Tt=N.value===-1?void 0:N.value,kt=galleryType.value.toString()+(O.value?.pid?.toString()||"")+N.value?.toString()+Ve.value.toString()+pt.toString()+l.toString()+u.value+Tt;if(ne.has(kt))return ne.get(kt);const It=await axios.post(mt+`/gallery/${b()}/filelist`,{pageIndex:pt,pageSize:l,keywords:u.value,firstType:Tt});return ne.set(kt,It),It};let De={};const Ve=ref("全部"),rt=ref(["全部",...Object.keys(De)]),Ae=computed(()=>Ve.value==="全部"?e.value:De[Ve.value]||[]),Te=(pt="end",mt,Tt)=>{if(mt.status===200){const{data:kt}=mt,{sharedwgs:It,page:nn}=kt||{};if(n.value=nn.max,It){const tn=It.map(pn=>(pn.filename&&(pn.filename=pn.filename.replace(/\.[^/.]+$/,"")),pn));e.value=pt==="end"?[...e.value,...tn]:[...tn,...e.value],De={},e.value.forEach(pn=>{if(pn.filename.indexOf("_")>=0){const Dn=pn.filename.split("_"),an=Dn[0],Rn=Dn[1];De[an]||(De[an]=[]),De[an].push({...pn,filename:Rn})}}),rt.value=["全部",...Object.keys(De)],Tt("ok")}else Tt("error")}else Tt("error")};watch(galleryType,async(pt,mt)=>{pt!==mt&&(ue(),N.value!==-1?N.value=-1:(fe(),y(),Te("end",await Ue(),()=>{})))});const Xe=async({side:pt,done:mt})=>{try{if(pt==="end"){if(J>n.value)return mt("empty");t.value=J++}if(pt==="start"){if(q<1)return mt("empty");t.value=q--}await nextTick(),Te(pt,await Ue(),mt)}catch{mt("error")}},ie=async()=>{fe(),y(),Te("end",await Ue(),()=>{})},ue=()=>new Promise((pt,mt)=>{const Tt=getBaseUrl();axios.post(Tt+`/gallery/${b()}/types`).then(kt=>{if(kt.data&&kt.data.code==="success"&&kt.data.result){const{allblocks:It=[]}=kt.data.result||{};O.value={pname:"全部",pid:-1,list:[{id:-1,name:"全部",pid:-1,pname:"全部",status:0},...It]},m.value=[O.value],It.forEach(nn=>{const tn=m.value?.find(({pid:pn})=>pn===nn.pid);tn?tn.list.push(nn):m.value?.push({pname:nn.pname,pid:nn.pid,list:[nn]})}),pt()}else mt()},mt)});return onLoadComplete(()=>{isShowBlockLibrary.value&&ue()}),watch(isShowBlockLibrary,(pt,mt)=>{pt&&ue()}),{galleryType,galleryTypes,searchKeyword:u,isShowBlockLibrary,blocksData:e,requestBlockLibraryData:Xe,onSearch:ie,blockTypes:m,blockType:O,typeId:N,getBlockTypesData:ue,secondaryBlockTypes:L,threeLevelClassifiedType:Ve,threeLevelClassifiedTypes:rt,currentData:Ae,pageIndex:t,updatePageIndex:ve,countPageSize:n,mode:c,updateKey:G}},_hoisted_1$5={class:"d-flex align-center justify-center fill-height"},_sfc_main$8=defineComponent$1({__name:"Block",props:{data:{},width:{},height:{default:150},isCollect:{type:Boolean},type:{default:()=>GalleryType.Blocks}},emits:["collection"],setup(t,{emit:e}){const l=e,n=computed(()=>{const u=getBaseUrl();let c="";return t.type===GalleryType.Blocks?c="blocks":t.type===GalleryType.Drawings&&(c="drawings"),u+"/"+c+"/"+t.data.secondType+"/"+t.data.firstType+"/"+t.data.filehash+".jpg"});return(u,c)=>(openBlock(),createBlock(VCard,{hover:"",variant:"tonal",class:"pa-2 my-2 block mx-1",height:u.height},{default:withCtx(()=>[createVNode(VImg,{width:u.width||100,cover:"",src:n.value,crossorigin:"anonymous"},{placeholder:withCtx(()=>[createBaseVNode("div",_hoisted_1$5,[createVNode(VProgressCircular,{color:"grey-lighten-4",indeterminate:""})])]),_:1},8,["width","src"]),u.isCollect?(openBlock(),createBlock(VTooltip,{key:0,text:u.data.collect?u.t("743"):u.t("744")},{activator:withCtx(({props:y})=>[createVNode(VBtn,mergeProps(y,{class:"collection",icon:u.data.collect?"class:iconfont shoucang1":"class:iconfont shoucang",size:"22px",onClick:c[0]||(c[0]=withModifiers(b=>l("collection",u.data),["stop"])),variant:"tonal"}),null,16,["icon"])]),_:1},8,["text"])):createCommentVNode("",!0),createBaseVNode("span",{class:"mt-2 mx-font-size d-inline-block text-truncate",style:normalizeStyle({width:(u.width||100)+"px"})},toDisplayString(u.data.filename),5)]),_:1},8,["height"]))}}),Block=_export_sfc$2(_sfc_main$8,[["__scopeId","data-v-79ea84c7"]]),instance=axios.create({baseURL:"",headers:{},withCredentials:!0,timeout:15e3});instance.interceptors.request.use(t=>(t.method==="post"&&(t.data||(t.data={}),t.data.token="yjd0VY6sWG6B4pLuQ5eZ5Q=="),t),t=>Promise.reject(t));const post=instance.post.bind(instance),useBlockCollect=()=>{const t=ref([]),e=ref(),l=ref(-1),n=async b=>{const m=await post("/api/app/blocks/CollectBlock",{});if(m.data.code==="success")return b.collect=!b.collect,!0;useMessage().error(m.data.msg)},u=async()=>{const b=await post("/api/app/blocks/MyCollect");b.data.code==="success"&&(e.value=b.data.result.filter(m=>typeof m.id=="number"),e.value&&e.value[0]&&(l.value=e.value[0].id))};watch(l,()=>{t.value=[],y({side:"end",done:()=>{}})});const c=()=>{u().then(()=>{y({side:"end",done:()=>{}})})},y=({side:b,done:m})=>{post("/api/app/blocks/CollectList",{typeId:l.value}).then(O=>{O.data.code==="success"?t.value=[...t.value,...O.data.result.blocksList]:m("error")},()=>m("error"))};return{collectionList:t,collectionTypes:e,collectionTypeId:l,collection:n,requestCollectData:c}},_hoisted_1$4={class:"d-flex flex-column h-100"},_hoisted_2$4={class:"d-flex mt-1"},_hoisted_3$2={class:"d-flex flex-column mt-1 mb-2"},_hoisted_4$1={class:"d-flex align-center"},_hoisted_5={class:"d-flex align-center"},_hoisted_6={class:"d-flex flex-wrap justify-space-around"},_sfc_main$7=defineComponent$1({__name:"BlockLibrary",props:{onResize:{type:Function}},setup(t){const{isShowBlockLibrary:e,galleryTypes:l,galleryType:n,searchKeyword:u,requestBlockLibraryData:c,onSearch:y,blockTypes:b,secondaryBlockTypes:m,typeId:O,blockType:N,threeLevelClassifiedType:L,threeLevelClassifiedTypes:G,pageIndex:q,updatePageIndex:J,countPageSize:fe,mode:ve,updateKey:ne,currentData:Ue}=useBlockLibrary(),{collection:De,collectionList:Ve,collectionTypes:rt,collectionTypeId:Ae}=useBlockCollect(),{setCommandFocus:Te}=useFocus$1(),Xe=an=>{Te(!an)};let ie=!1,ue=null;const pt=an=>{const Rn=getBaseUrl();n.value===GalleryType.Drawings?ue||(ue=setTimeout(()=>{ie||(useMessage().info(scopedTtranslate("请双击打开图纸")),ie=!1)},500)):n.value===GalleryType.Blocks&&callCommand("Mx_Insert",{filePath:`${Rn}/blocks/${an.secondType}/${an.firstType}/${an.filehash}.mxweb`,name:an.filename,hash:an.filehash,isBlockLibrary:!0})},mt=async an=>{ue!==null&&(clearTimeout(ue),ue=null);const Rn=getBaseUrl();n.value===GalleryType.Drawings&&(MxFun.sendStringToExecute("_openMxweb",`${Rn}/drawings/${an.secondType}/${an.firstType}/${an.filehash}.mxweb`),setFileName(an.filename))},Tt=an=>{const Rn=m.value.find(Lt=>Lt.id===an);Rn&&b.value&&(N.value=b.value.find(({pid:Lt})=>Lt===Rn.pid))},kt=an=>{an.list.some(Rn=>Rn.id===O.value)||(O.value=an.list[0].id)},It=ref(),nn=ref(!1),tn=ref(0),pn=computed(()=>nn.value?parseInt(((tn.value-150)/40).toString()):void 0);t.onResize&&t.onResize(an=>{tn.value=an,nn.value=an>450}),onMounted(()=>{nn.value=It.value&&It.value?.clientWidth>450});const _n=an=>{an.target?.select()},Dn=an=>{const Rn=Number(an);q.value=Rn>=fe.value?fe.value:Rn};return(an,Rn)=>withDirectives((openBlock(),createElementBlock("div",{class:"mx_block_library_box",ref_key:"libraryBox",ref:It},[createBaseVNode("div",_hoisted_1$4,[createVNode(VRadioGroup,{modelValue:unref(n),"onUpdate:modelValue":Rn[0]||(Rn[0]=Lt=>isRef(n)?n.value=Lt:null)},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(l),Lt=>(openBlock(),createBlock(VRadio,{value:Lt.value},{label:withCtx(()=>[createVNode(_sfc_main$a,null,{default:withCtx(()=>[createTextVNode(toDisplayString(an.t(Lt.title)),1)]),_:2},1024)]),_:2},1032,["value"]))),256))]),_:1},8,["modelValue"]),createBaseVNode("div",_hoisted_2$4,[createVNode(VTextField,{modelValue:unref(u),"onUpdate:modelValue":Rn[1]||(Rn[1]=Lt=>isRef(u)?u.value=Lt:null),"onUpdate:focused":Xe,onChange:unref(y),class:"w-75","append-inner-icon":"class:iconfont sousuo"},null,8,["modelValue","onChange"])]),createBaseVNode("div",_hoisted_3$2,[nn.value?(openBlock(),createElementBlock(Fragment,{key:0},[createVNode(VChipGroup,{"selected-class":"text-primary",mandatory:"",column:"",modelValue:unref(N),"onUpdate:modelValue":Rn[2]||(Rn[2]=Lt=>isRef(N)?N.value=Lt:null)},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(b),(Lt,wn)=>(openBlock(),createBlock(VChip,{key:wn,border:"",tile:"",rounded:"sm",size:"small",value:Lt},{default:withCtx(()=>[createTextVNode(toDisplayString(an.t(Lt.pname)),1)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"]),createVNode(VSheet,{color:"background"},{default:withCtx(()=>[createBaseVNode("div",_hoisted_4$1,[createVNode(VChipGroup,{"selected-class":"text-primary",mandatory:"",modelValue:unref(O),"onUpdate:modelValue":Rn[3]||(Rn[3]=Lt=>isRef(O)?O.value=Lt:null)},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(m),(Lt,wn)=>(openBlock(),createBlock(VChip,{key:wn,border:"",tile:"",rounded:"sm",size:"small",value:Lt.id},{default:withCtx(()=>[createTextVNode(toDisplayString(an.t(Lt.name)),1)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])]),createBaseVNode("div",_hoisted_5,[createVNode(VChipGroup,{"selected-class":"text-primary",mandatory:"",modelValue:unref(L),"onUpdate:modelValue":Rn[4]||(Rn[4]=Lt=>isRef(L)?L.value=Lt:null)},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(G),(Lt,wn)=>(openBlock(),createBlock(VChip,{key:wn,border:"",tile:"",rounded:"sm",size:"small",value:Lt},{default:withCtx(()=>[createTextVNode(toDisplayString(an.t(Lt)),1)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])])]),_:1})],64)):(openBlock(),createElementBlock(Fragment,{key:1},[createVNode(VSelect,{items:unref(b),modelValue:unref(N),"onUpdate:modelValue":[Rn[5]||(Rn[5]=Lt=>isRef(N)?N.value=Lt:null),kt],class:"mt-1","item-title":"pname","return-object":""},{selection:withCtx(({item:Lt})=>[createTextVNode(toDisplayString(an.t(Lt.title)),1)]),item:withCtx(({item:Lt,props:wn})=>[createVNode(VListItem,mergeProps(wn,{title:an.t(Lt.title)}),null,16,["title"])]),_:1},8,["items","modelValue"]),createVNode(VSelect,{items:unref(m),modelValue:unref(O),"onUpdate:modelValue":[Rn[6]||(Rn[6]=Lt=>isRef(O)?O.value=Lt:null),Tt],"item-title":"name",class:"mt-1","item-value":"id"},{selection:withCtx(({item:Lt})=>[createTextVNode(toDisplayString(an.t(Lt.title)),1)]),item:withCtx(({item:Lt,props:wn})=>[createVNode(VListItem,mergeProps(wn,{title:an.t(Lt.title)}),null,16,["title"])]),_:1},8,["items","modelValue"]),createVNode(VSelect,{items:unref(G),modelValue:unref(L),"onUpdate:modelValue":Rn[7]||(Rn[7]=Lt=>isRef(L)?L.value=Lt:null),"return-object":!1,class:"mt-1"},{selection:withCtx(({item:Lt})=>[createTextVNode(toDisplayString(an.t(Lt.title)),1)]),item:withCtx(({item:Lt,props:wn})=>[createVNode(VListItem,mergeProps(wn,{title:an.t(Lt.title)}),null,16,["title"])]),_:1},8,["items","modelValue"])],64))]),(openBlock(),createBlock(VInfiniteScroll,{height:`calc(100vh - ${unref(useHeaderHeight)().value+(nn.value?300:244)}px)`,mode:unref(ve),key:unref(ne),side:"both",onLoad:unref(c)},{empty:withCtx(()=>[createVNode(VAlert,{type:"warning"},{default:withCtx(()=>Rn[10]||(Rn[10]=[createTextVNode("No more items!")])),_:1})]),default:withCtx(()=>[createBaseVNode("div",_hoisted_6,[(openBlock(!0),createElementBlock(Fragment,null,renderList(unref(Ue),(Lt,wn)=>(openBlock(),createBlock(Block,{type:unref(n),data:Lt,key:Lt.filename+wn,onDblclick:withModifiers(hn=>mt(Lt),["stop"]),onClick:hn=>pt(Lt),onCollection:unref(De)},null,8,["type","data","onDblclick","onClick","onCollection"]))),128))])]),_:1},8,["height","mode","onLoad"])),createVNode(VRow,{"no-gutters":""},{default:withCtx(()=>[createVNode(VCol,{cols:nn.value?"auto":12},{default:withCtx(()=>[createVNode(VPagination,{modelValue:unref(q),"onUpdate:modelValue":[Rn[8]||(Rn[8]=Lt=>isRef(q)?q.value=Lt:null),unref(J)],"total-visible":pn.value,length:unref(fe),density:"compact",size:"small"},{first:withCtx(()=>Rn[11]||(Rn[11]=[])),default:withCtx(()=>[Rn[12]||(Rn[12]=createTextVNode("> "))]),_:1},8,["modelValue","onUpdate:modelValue","total-visible","length"])]),_:1},8,["cols"]),createVNode(VSpacer),createVNode(VCol,{cols:"auto"},{default:withCtx(()=>[createVNode(VTextField,{type:"number","model-value":unref(q),"onUpdate:modelValue":Dn,"onUpdate:focused":Rn[9]||(Rn[9]=Lt=>{unref(Te)(!Lt),!Lt&&unref(J)()}),"onClick:control":_n,max:unref(fe),"max-width":105,width:"105",min:"1",variant:"outlined"},{prepend:withCtx(()=>[createTextVNode(toDisplayString(an.t("745")),1)]),append:withCtx(()=>[createTextVNode(toDisplayString(an.t("746")),1)]),_:1},8,["model-value","max"])]),_:1})]),_:1})])],512)),[[vShow,unref(e)]])}}),BlockLibrary=_export_sfc$2(_sfc_main$7,[["__scopeId","data-v-6974e534"]]);function keepDecimal(t,e){const l=Number(t);if(isNaN(l))return t;const n=Number(l.toFixed(e));return isNaN(n)?0:n}function clampNumber(t,e,l){return Math.min(Math.max(t,e),l)}const useLine=({getFirstSelectData:t,update:e,selectUpdateFun:l})=>{const n={categoryName:"几何图形",isShowTypes:["直线"]},u=async()=>{const ve=t();if(ve.type===McObjectIdType.kMxCAD){const ne=new MxCADUiPrPoint;ne.setMessage(`
- 在图形中拾取点:`);let Ue=Number(y.ref.value),De=Number(b.ref.value),Ve=Number(m.ref.value);if(isNaN(Ue)||isNaN(De)||isNaN(Ve)){const Te=ve.objId.getMcDbEntity();if(!Te)return;Ue=Te.startPoint.x,De=Te.startPoint.y,Ve=Te.startPoint.z}let rt=new McGePoint3d(Ue,De,Ve);ne.setBasePt(rt);let Ae=await ne.go();if(!Ae)return;l({mxcadFun:(Te,Xe)=>{Te.startPoint=Xe}},Ae)}e()},c=async()=>{const ve=t();if(ve.type===McObjectIdType.kMxCAD){const ne=new MxCADUiPrPoint;ne.setMessage(`
- 在图形中拾取点:`);let Ue=Number(O.ref.value),De=Number(N.ref.value),Ve=Number(L.ref.value);if(isNaN(Ue)||isNaN(De)||isNaN(Ve)){const Te=ve.objId.getMcDbEntity();if(!Te)return;Ue=Te.endPoint.x,De=Te.endPoint.y,Ve=Te.endPoint.z}let rt=new McGePoint3d(Ue,De,Ve);ne.setBasePt(rt);let Ae=await ne.go();if(!Ae)return;l({mxcadFun:(Te,Xe)=>{Te.endPoint=Xe}},Ae)}e()},y=defineRightDrawerUIProp({...n,type:"input",label:"开始点X",definePropRef:{everyMxcadFun(ve,ne){return ve.startPoint?.x===ne.startPoint?.x},mxcadGet(ve){y.ref.value=keepDecimal(ve.startPoint.x,3)},McClass:McDbLine,mxcadSet(ve,ne){ne=Number(ne),!isNaN(ne)&&(ve.startPoint.x=ne,ve.startPoint=new McGePoint3d(ne,ve.startPoint.y,ve.startPoint.z))}},getPoint:u}),b=defineRightDrawerUIProp({...n,type:"input",label:"开始点Y",definePropRef:{everyMxcadFun(ve,ne){return ve.startPoint?.y===ne.startPoint?.y},mxcadGet(ve){b.ref.value=keepDecimal(ve.startPoint.y,3)},McClass:McDbLine,mxcadSet(ve,ne){ne=Number(ne),!isNaN(ne)&&(ve.startPoint.y=ne,ve.startPoint=new McGePoint3d(ve.startPoint.x,ne,ve.startPoint.z))}},getPoint:u}),m=defineRightDrawerUIProp({...n,type:"input",label:"开始点Z",definePropRef:{everyMxcadFun(ve,ne){return ve.startPoint?.z===ne.startPoint?.z},mxcadGet(ve){m.ref.value=keepDecimal(ve.startPoint.z,3)},McClass:McDbLine,mxcadSet(ve,ne){ne=Number(ne),!isNaN(ne)&&(ve.startPoint.z=ne,ve.startPoint=new McGePoint3d(ve.startPoint.x,ve.startPoint.y,ne))}},getPoint:u}),O=defineRightDrawerUIProp({...n,type:"input",label:"结束点X",getPoint:c,definePropRef:{everyMxcadFun(ve,ne){return ve.endPoint?.x===ne.endPoint?.x},mxcadGet(ve){O.ref.value=keepDecimal(ve.endPoint.x,3)},McClass:McDbLine,mxcadSet(ve,ne){ne=Number(ne),!isNaN(ne)&&(ve.endPoint.x=ne,ve.startPoint=new McGePoint3d(ne,ve.endPoint.y,ve.endPoint.z))}}}),N=defineRightDrawerUIProp({...n,type:"input",label:"结束点Y",getPoint:c,definePropRef:{everyMxcadFun(ve,ne){return ve.endPoint?.y===ne.endPoint?.y},mxcadGet(ve){N.ref.value=keepDecimal(ve.endPoint.y,3)},McClass:McDbLine,mxcadSet(ve,ne){ne=Number(ne),!isNaN(ne)&&(ve.endPoint.y=ne,ve.startPoint=new McGePoint3d(ve.endPoint.x,ne,ve.endPoint.z))}}}),L=defineRightDrawerUIProp({...n,type:"input",label:"结束点Z",getPoint:c,definePropRef:{everyMxcadFun(ve,ne){return ve.endPoint?.z===ne.endPoint?.z},mxcadGet(ve){L.ref.value=keepDecimal(ve.endPoint.z,3)},McClass:McDbLine,mxcadSet(ve,ne){ne=Number(ne),!isNaN(ne)&&(ve.endPoint.y=ne,ve.startPoint=new McGePoint3d(ve.endPoint.x,ve.endPoint.y,ne))}}}),G=computed(()=>{const ve=Number(O.ref.value)-Number(y.ref.value);return isNaN(ve)?scopedTtranslate("760"):keepDecimal(ve,3)});defineRightDrawerUIProp({...n,type:"string",label:"增量X",valRef:G,disabled:!0});const q=computed(()=>{const ve=Number(N.ref.value)-Number(b.ref.value);return isNaN(ve)?scopedTtranslate("760"):keepDecimal(ve,3)});defineRightDrawerUIProp({...n,type:"string",label:"增量Y",valRef:q,disabled:!0});const J=computed(()=>{const ve=Number(L.ref.value)-Number(m.ref.value);return isNaN(ve)?scopedTtranslate("760"):keepDecimal(ve,3)});defineRightDrawerUIProp({...n,type:"string",label:"增量Z",valRef:J,disabled:!0});const fe=computed(()=>{if(typeof G.value=="string"||typeof q.value=="string")return scopedTtranslate("760");const ve=keepDecimal(Math.atan2(q.value,G.value)*180/Math.PI,3);return keepDecimal(ve,3)});return defineRightDrawerUIProp({...n,type:"string",label:"角度",valRef:fe,disabled:!0}),{startX:y,startY:b,startZ:m,endX:O,endY:N,endZ:L,getStartPoint:u,getEndPoint:c,incrementX:G,incrementY:q,incrementZ:J,angle:fe}},usePolyLine=({defineEntityProp:t,isPolyline:e,getFirstSelectData:l,update:n,selectUpdateFun:u})=>{const c=t(!1,{everyMxcadFun(ne,Ue,De){return De===0},multipleCall(){c.value=!1},mxcadFun(){c.value=!0},McClass:McDbPolyline}),y=t(1,{McClass:McDbPolyline},{mxcadFun(){n()}}),b=t([1],{everyMxcadFun(){return e.value},mxcadFun(ne){b.value=[];for(let Ue=1;Ue<=ne.numVerts();Ue++)b.value.push(Ue)},McClass:McDbPolyline}),m={categoryName:"几何图形",isShow:c};defineRightDrawerUIProp({...m,label:"顶点",type:"select",valRef:y,vSelectProps:{items:b,menuProps:{maxHeight:"600"}},isShow:e});const O=async()=>{const ne=l();if(ne.type===McObjectIdType.kMxCAD){const Ue=new MxCADUiPrPoint;Ue.setMessage(`
- 在图形中拾取点:`);const Ve=ne.objId.getMcDbEntity().getPointAt(y.value-1).val;Ue.setBasePt(Ve);let rt=await Ue.go();if(!rt)return;u({mxcadFun:(Ae,Te)=>{Ae.setPointAt(y.value-1,Te)}},rt)}n()},N=t(0,{everyMxcadFun(){return e.value},mxcadFun(ne){N.value=keepDecimal(ne.getPointAt(y.value-1).val.x,3)},McClass:McDbPolyline},{mxcadFun(ne,Ue){const De=ne.getPointAt(y.value-1).val;De.x=Ue,ne.setPointAt(y.value-1,De)}}),L=t(0,{everyMxcadFun(){return e.value},mxcadFun(ne){L.value=keepDecimal(ne.getPointAt(y.value-1).val.y,3)},McClass:McDbPolyline},{mxcadFun(ne,Ue){const De=ne.getPointAt(y.value-1).val;De.y=Ue,ne.setPointAt(y.value-1,De)}}),G=t(0,{everyMxcadFun(){return e.value},mxcadFun(ne){G.value=keepDecimal(ne.getPointAt(y.value-1).val.z,3)},McClass:McDbPolyline},{mxcadFun(ne,Ue){const De=ne.getPointAt(y.value-1).val;De.z=Ue,ne.setPointAt(y.value-1,De)}});defineRightDrawerUIProp({...m,label:"顶点X",type:"input",valRef:N,getPoint:O,isShow:e}),defineRightDrawerUIProp({...m,label:"顶点Y",type:"input",valRef:L,getPoint:O,isShow:e}),defineRightDrawerUIProp({...m,label:"顶点Z",type:"input",valRef:G,getPoint:O,isShow:e});const q=t(0,{everyMxcadFun(){return e.value},mxcadFun(ne){const{val1:Ue}=ne.getWidthsAt(y.value-1);q.value=keepDecimal(Ue,3)},McClass:McDbPolyline},{mxcadFun(ne,Ue){ne.setWidthsAt(y.value-1,Ue,J.value)}});defineRightDrawerUIProp({...m,label:"顶点起始线宽",type:"input",valRef:q,isShow:e});const J=t(0,{everyMxcadFun(){return e.value},mxcadFun(ne){const{val2:Ue}=ne.getWidthsAt(y.value-1);J.value=keepDecimal(Ue,3)},McClass:McDbPolyline},{mxcadFun(ne,Ue){ne.setWidthsAt(y.value-1,q.value,Ue)}});defineRightDrawerUIProp({...m,label:"顶点中止线宽",type:"input",valRef:J,isShow:e});const fe=t(0,{everyMxcadFun(ne,Ue){return e.value&&ne.constantWidth===Ue.constantWidth},multipleCall(){fe.value=scopedTtranslate("760")},mxcadFun(ne){fe.value=keepDecimal(ne.constantWidth,3)},McClass:McDbPolyline},{mxcadFun(ne,Ue){Ue=Number(Ue),!isNaN(Ue)&&(ne.constantWidth=Ue,J.value=q.value=Ue)}});defineRightDrawerUIProp({categoryName:"几何图形",isShowTypes:["多段线"],label:"全局线宽",type:"input",valRef:fe,isShow:e});const ve=t(!1,{everyMxcadFun(ne,Ue){return e.value&&ne.isClosed===Ue.isClosed},multipleCall(){ve.value=scopedTtranslate("760")},mxcadFun(ne){ve.value=ne.isClosed},McClass:McDbPolyline},{mxcadFun(ne,Ue){typeof Ue!="string"&&(ne.isClosed=Ue)}});return defineRightDrawerUIProp({categoryName:"几何图形",isShowTypes:["多段线"],label:"闭合",type:"select",vSelectProps:{items:ref([{value:!0,title:"是"},{value:!1,title:"否"}]),menuProps:{maxHeight:"600"}},isTranslationVSelectTitle:!0,isShow:e,valRef:ve}),{isNoMultiple:c,index:y,indexs:b,getVertexPoint:O,vertexX:N,vertexY:L,vertexZ:G,vertexLineStartWidth:q,vertexLineEndWidth:J,width:fe,isClosed:ve}},useCircularArc=({defineEntityProp:t,getFirstSelectData:e,selectUpdateFun:l,update:n})=>{const u={categoryName:"几何图形",isShowTypes:["圆弧"]},c=async()=>{const L=e();if(L.type===McObjectIdType.kMxCAD){const G=new MxCADUiPrPoint;G.setMessage(`
- 在图形中拾取点:`);const J=L.objId.getMcDbEntity().center;G.setBasePt(J);let fe=await G.go();if(!fe)return;l({mxcadFun:(ve,ne)=>{ve.center=ne}},fe)}n()},y=t(0,{everyMxcadFun(L,G){return L.center.x===G.center.x},multipleCall(){y.value=scopedTtranslate("760")},mxcadFun(L){y.value=keepDecimal(L.center.x,3)},McClass:McDbArc},{mxcadFun(L,G){if(G=Number(G),isNaN(G))return;const q=L.center.clone();q.x=G,L.center=q}}),b=t(0,{everyMxcadFun(L,G){return L.center.y===G.center.y},multipleCall(){b.value=scopedTtranslate("760")},mxcadFun(L){b.value=keepDecimal(L.center.y,3)},McClass:McDbArc},{mxcadFun(L,G){if(G=Number(G),isNaN(G))return;const q=L.center.clone();q.y=G,L.center=q}}),m=t(0,{everyMxcadFun(L,G){return L.center.z===G.center.z},multipleCall(){m.value=scopedTtranslate("760")},mxcadFun(L){m.value=keepDecimal(L.center.z,3)},McClass:McDbArc},{mxcadFun(L,G){if(G=Number(G),isNaN(G))return;const q=L.center.clone();q.z=G,L.center=q}});defineRightDrawerUIProp({...u,type:"input",label:"弧心坐标X",getPoint:c,valRef:y}),defineRightDrawerUIProp({...u,type:"input",label:"弧心坐标Y",getPoint:c,valRef:b}),defineRightDrawerUIProp({...u,type:"input",label:"弧心坐标Z",getPoint:c,valRef:m});const O=t(0,{everyMxcadFun(L,G){return L.radius===G.radius},multipleCall(){O.value=scopedTtranslate("760")},mxcadFun(L){O.value=keepDecimal(L.radius,3)},McClass:McDbArc},{mxcadFun(L,G){G=Number(G),!isNaN(G)&&(L.radius=G,N.value=G*2)}});defineRightDrawerUIProp({...u,type:"input",label:"半径",valRef:O});const N=t(0,{everyMxcadFun(L,G){return L.center.x===G.center.x},multipleCall(){N.value=scopedTtranslate("760")},mxcadFun(L){N.value=keepDecimal(L.radius*2,3)},McClass:McDbArc},{mxcadFun(L,G){G=Number(G),!isNaN(G)&&(O.value=L.radius=G/2)}});return defineRightDrawerUIProp({...u,type:"input",label:"直径",valRef:N}),{arcCenterX:y,arcCenterY:b,arcCenterZ:m,arcRadius:O,arcDiameter:N,getArcCenterPoint:c}},useCircle=({defineEntityProp:t,getFirstSelectData:e,selectUpdateFun:l,update:n,packFunNoWatch:u},c,y)=>{const b={categoryName:"几何图形",isShowTypes:["圆"]},m=t(0,{everyMxcadFun(ne,Ue){return ne.center.x===Ue.center.x},multipleCall(){m.value=scopedTtranslate("760")},mxcadFun(ne){m.value=keepDecimal(ne.center.x,3)},McClass:McDbCircle},{mxcadFun(ne,Ue){if(Ue=Number(Ue),isNaN(Ue))return;const De=ne.center.clone();De.x=Ue,ne.center=De}}),O=t(0,{everyMxcadFun(ne,Ue){return ne.center.y===Ue.center.y},multipleCall(){O.value=scopedTtranslate("760")},mxcadFun(ne){O.value=keepDecimal(ne.center.y,3)},McClass:McDbCircle},{mxcadFun(ne,Ue){if(Ue=Number(Ue),isNaN(Ue))return;const De=ne.center.clone();De.y=Ue,ne.center=De}}),N=t(0,{everyMxcadFun(ne,Ue){return ne.center.z===Ue.center.z},multipleCall(){N.value=scopedTtranslate("760")},mxcadFun(ne){N.value=keepDecimal(ne.center.z,3)},McClass:McDbCircle},{mxcadFun(ne,Ue){if(Ue=Number(Ue),isNaN(Ue))return;const De=ne.center.clone();De.z=Ue,ne.center=De}}),L=async()=>{const ne=e();if(ne.type===McObjectIdType.kMxCAD){const Ue=new MxCADUiPrPoint;Ue.setMessage(`
- `+scopedTtranslate("762")+":");const Ve=ne.objId.getMcDbEntity().center;Ue.setBasePt(Ve);let rt=await Ue.go();if(!rt)return;l({mxcadFun:(Ae,Te)=>{Ae.center=Te}},rt)}n()};defineRightDrawerUIProp({...b,type:"input",valRef:m,label:"圆心坐标X",getPoint:L}),defineRightDrawerUIProp({...b,type:"input",valRef:O,label:"圆心坐标Y",getPoint:L}),defineRightDrawerUIProp({...b,type:"input",valRef:N,label:"圆心坐标Z",getPoint:L});const G=u(ne=>{q.value=ne,J.value=ne*2,fe.value=Math.PI*ne*ne,ve.value=2*Math.PI*ne,c.value=ve.value,y.value=fe.value}),q=t(0,{everyMxcadFun(ne,Ue){return ne.radius===Ue.radius},multipleCall(){q.value=scopedTtranslate("760")},mxcadFun(ne){q.value=keepDecimal(ne.radius,3)},McClass:McDbCircle},{mxcadFun(ne,Ue){Ue=Number(Ue),!isNaN(Ue)&&(ne.radius=Ue,G(Ue))}});defineRightDrawerUIProp({...b,type:"input",valRef:q,label:"半径"});const J=t(0,{everyMxcadFun(ne,Ue){return ne.center.x===Ue.center.x},multipleCall(){J.value=scopedTtranslate("760")},mxcadFun(ne){J.value=keepDecimal(ne.radius*2,3)},McClass:McDbCircle},{mxcadFun(ne,Ue){Ue=Number(Ue),!isNaN(Ue)&&(ne.radius=Ue/2,G(ne.radius))}});defineRightDrawerUIProp({...b,type:"input",valRef:J,label:"直径"});const fe=t(0,{everyMxcadFun(ne,Ue){return ne.center.x===Ue.center.x},multipleCall(){fe.value=scopedTtranslate("760")},mxcadFun(ne){fe.value=keepDecimal(Math.PI*ne.radius*ne.radius,3)},McClass:McDbCircle},{mxcadFun(ne,Ue){Ue=Number(Ue),!isNaN(Ue)&&(ne.radius=Ue/Math.PI/ne.radius,G(ne.radius))}});defineRightDrawerUIProp({...b,type:"input",valRef:fe,label:"面积"});const ve=t(0,{everyMxcadFun(ne,Ue){return ne.center.x===Ue.center.x},multipleCall(){ve.value=scopedTtranslate("760")},mxcadFun(ne){ve.value=keepDecimal(2*Math.PI*ne.radius,3)},McClass:McDbCircle},{mxcadFun(ne,Ue){Ue=Number(Ue),!isNaN(Ue)&&(ne.radius=Ue/Math.PI/2,G(ne.radius))}});return defineRightDrawerUIProp({...b,type:"input",valRef:ve,label:"周长"}),{circleCenterX:m,circleCenterY:O,circleCenterZ:N,circleRadius:q,circleDiameter:J,circleArea:fe,circlePerimeter:ve,getCircleCenterPoint:L}},useBlock=({defineEntityProp:t,getFirstSelectData:e,selectUpdateFun:l,update:n})=>{const u={categoryName:"几何图形",isShowTypes:["图块"]},c=t(0,{everyMxcadFun(q,J){return q.position.x===J.position.x},multipleCall(){return c.value=scopedTtranslate("760")},mxcadFun(q){c.value=keepDecimal(q.position.x,3)},McClass:McDbBlockReference},{mxcadFun(q,J){if(J=Number(J),isNaN(J))return;const fe=q.position.clone();fe.x=J,q.position=fe}}),y=t(0,{everyMxcadFun(q,J){return q.position.y===J.position.y},multipleCall(){return y.value=scopedTtranslate("760")},mxcadFun(q){y.value=keepDecimal(q.position.y,3)},McClass:McDbBlockReference},{mxcadFun(q,J){if(J=Number(J),isNaN(J))return;const fe=q.position.clone();fe.y=J,q.position=fe}}),b=t(0,{everyMxcadFun(q,J){return q.position.z===J.position.z},multipleCall(){return b.value=scopedTtranslate("760")},mxcadFun(q){b.value=keepDecimal(q.position.z,3)},McClass:McDbBlockReference},{mxcadFun(q,J){if(J=Number(J),isNaN(J))return;const fe=q.position.clone();fe.z=J,q.position=fe}}),m=async()=>{const q=e();if(q.type===McObjectIdType.kMxCAD){const J=new MxCADUiPrPoint;J.setMessage(`
- `+scopedTtranslate("762")+":");const ve=q.objId.getMcDbEntity().position;J.setBasePt(ve);let ne=await J.go();if(!ne)return;l({mxcadFun:(Ue,De)=>{Ue.position=De}},ne)}n()};defineRightDrawerUIProp({...u,type:"input",label:"位置坐标X",valRef:c,getPoint:m}),defineRightDrawerUIProp({...u,type:"input",label:"位置坐标Y",valRef:y,getPoint:m}),defineRightDrawerUIProp({...u,type:"input",label:"位置坐标Z",valRef:b,getPoint:m});const O=t(0,{everyMxcadFun(q,J){return q.rotation===J.rotation},multipleCall(){return O.value=scopedTtranslate("760")},mxcadFun(q){O.value=keepDecimal(q.rotation,3)},McClass:McDbBlockReference},{mxcadFun(q,J){J=Number(J),!isNaN(J)&&(q.rotation=J)}});defineRightDrawerUIProp({...u,type:"input",label:"旋转角度",valRef:O});const N=t(0,{everyMxcadFun(q,J){return q.scaleFactors.x===J.scaleFactors.x},multipleCall(){return N.value=scopedTtranslate("760")},mxcadFun(q){N.value=keepDecimal(q.scaleFactors.x,3)},McClass:McDbBlockReference},{mxcadFun(q,J){if(J=Number(J),isNaN(J))return;const fe=q.scaleFactors.clone();fe.x=J,q.scaleFactors=fe}});defineRightDrawerUIProp({...u,type:"input",label:"缩放比例X",valRef:N});const L=t(0,{everyMxcadFun(q,J){return q.scaleFactors.y===J.scaleFactors.y},multipleCall(){return L.value=scopedTtranslate("760")},mxcadFun(q){L.value=keepDecimal(q.scaleFactors.y,3)},McClass:McDbBlockReference},{mxcadFun(q,J){if(J=Number(J),isNaN(J))return;const fe=q.scaleFactors.clone();fe.y=J,q.scaleFactors=fe}});defineRightDrawerUIProp({...u,type:"input",label:"缩放比例Y",valRef:L});const G=t("",{mxcadFun(q){G.value=q.blockName},McClass:McDbBlockReference});return defineRightDrawerUIProp({...u,type:"string",label:"图块名",valRef:G,disabled:!0}),{positionX:c,positionY:y,positionZ:b,rotation:O,scaleX:N,scaleY:L,name:G,getCircleCenterPoint:m}},useMxDbShape=({defineEntityProp:t,isShape:e})=>{const l={isShow:e,categoryName:"形状"},n=t("",{everyMxdrawFun(m,O){return m.closed===O.closed},multipleCall(){n.value=scopedTtranslate("760")},mxdrawFun(m){n.value=m.closed?"是":"否"},MxClass:MxDbShape},{mxdrawFun(m,O){m.closed=O==="是"}});defineRightDrawerUIProp({...l,type:"select",label:"是否闭合",valRef:n,vSelectProps:{items:ref(["是","否"])},isTranslationVSelectTitle:!0});const u=t(0,{everyMxdrawFun(m,O){return m.curveSegments===O.curveSegments},multipleCall(){u.value=scopedTtranslate("760")},mxdrawFun(m){u.value=m.curveSegments},MxClass:MxDbShape},{mxdrawFun(m,O){O=Number(O),!isNaN(O)&&(m.curveSegments=O)}});defineRightDrawerUIProp({...l,type:"input",label:"曲线细分程度",valRef:u});const c=t("",{everyMxdrawFun(m,O){return m.isFill===O.isFill},multipleCall(){c.value=scopedTtranslate("760")},mxdrawFun(m){c.value=m.isFill?scopedTtranslate("140"):scopedTtranslate("141")}},{mxdrawFun(m,O){m.isFill=O===scopedTtranslate("140")}});defineRightDrawerUIProp({...l,type:"select",label:"是否填充",valRef:c,vSelectProps:{items:ref(["是","否"])},isTranslationVSelectTitle:!0});const y=computed(()=>c.value==="是");onLoadComplete(()=>{defineRightDrawerUIProp({categoryName:"形状填充",type:"color",label:"描边颜色",isShow:y,mxPropName:"stroke",definePropRef:{MxClass:MxDbShape}})});const b=t(0,{everyMxdrawFun(m,O){return m.strokeLineWidth===O.strokeLineWidth},multipleCall(){b.value=scopedTtranslate("760")},mxdrawFun(m){b.value=m.strokeLineWidth},MxClass:MxDbShape},{mxdrawFun(m,O){O=Number(O),!isNaN(O)&&(m.strokeLineWidth=O)}});return defineRightDrawerUIProp({categoryName:"形状填充",type:"input",label:"描边线段宽度",isShow:y,valRef:b}),{closed:n,curveSegments:u,isFill:c,strokeLineWidth:b}},useCurveParameter=({isMultipleChoices:t,isMxcad:e,isCurve:l})=>{const n=defineRightDrawerUIProp({type:"string",disabled:!0,categoryName:"曲线参数",label:"面积",definePropRef:{everyMxdrawFun(c,y,b){return!t()&&b===0},mxcadGet(c){n.ref.value=keepDecimal(c.getArea().val,3)},multipleCall(){n.ref.value=scopedTtranslate("*多种*")},McClass:McDbCurve},isShow:l}),u=defineRightDrawerUIProp({type:"string",disabled:!0,categoryName:"曲线参数",label:"长度",definePropRef:{everyMxcadFun(c,y,b){return!t()&&b===0},mxcadGet(c){u.ref.value=keepDecimal(c.getLength().val,3)},multipleCall(){u.ref.value=scopedTtranslate("*多种*")},McClass:McDbCurve},isShow:l});return{area:n,length:u}},useMxDbLeadComment=()=>{const t={categoryName:"文字",isShowTypes:["引线标注","审图标注"]},e=defineRightDrawerUIProp({...t,label:"内容",type:"input",mxPropName:"text",definePropRef:{MxClass:[MxDbLeadComment,MxDbRectBoxLeadComment]}}),l=defineRightDrawerUIProp({...t,label:"取屏幕像素绘图单位",type:"select",mxPropName:"fixedSize",vSelectProps:{items:ref(["是","否"])},isTranslationVSelectTitle:!0,definePropRef:{MxClass:[MxDbLeadComment,MxDbRectBoxLeadComment],mxdrawGet(c){l.ref.value=c.fixedSize?scopedTtranslate("是"):scopedTtranslate("否")},mxdrawSet(c,y){c.fixedSize=y==="是"}}}),n=defineRightDrawerUIProp({...t,label:"宽度",type:"input",mxPropName:"textWidth",definePropRef:{MxClass:[MxDbLeadComment,MxDbRectBoxLeadComment],mxdrawSet(c,y){y=Number(y),!isNaN(y)&&(c.textWidth=y)}}}),u=defineRightDrawerUIProp({...t,label:"高度",type:"input",mxPropName:"textHeight",definePropRef:{MxClass:[MxDbLeadComment,MxDbRectBoxLeadComment]}});return{text:e,fixedSize:l,textHeight:u,textWidth:n}};let isInit=!1;const useBaseProps=({name:t,isMxcad:e,isMxdraw:l})=>{onOpenFileComplete(()=>{if(isInit)return;isInit=!0;const n=defineRightDrawerUIProp({type:"string",label:"类型",disabled:!0,definePropRef:{defaultVal:"",everyMxcadFun:(rt,Ae)=>rt.getObjectID().type===Ae.getObjectID().type,multipleCall(){n.ref.value=scopedTtranslate("760")},mxdrawGet(){n.ref.value=scopedTtranslate("251")},mxcadGet(){n.ref.value="CAD"}}}),u=defineRightDrawerUIProp({type:"string",label:"名称",disabled:!0,definePropRef:{defaultVal:"",everyMxcadFun(){return!0},everyMxdrawFun(){return!0},mxdrawGet(){u.ref.value=t.value},mxcadGet(){u.ref.value=t.value}}});defineRightDrawerUIProp({type:"color",label:"颜色",mcPropName:"trueColor",mxPropName:"color",definePropRef:{}});const c=defineRightDrawerUIProp({type:"select",label:"是否填充",mxPropName:"isFill",vSelectProps:{items:ref(["是","否"])},isTranslationVSelectTitle:!0,definePropRef:{MxClass:MxDbArea,mxdrawGet(rt){c.ref.value=rt.isFill?"是":"否"},mxdrawSet(rt,Ae){rt.isFill=Ae==="是"}},isShowTypes:["面积测量"]});defineRightDrawerUIProp({type:"color",label:"填充颜色",mxPropName:"fillColor",definePropRef:{},isShow:c.isShowRef}),defineRightDrawerUIProp({type:"input",label:"填充透明度",mxPropName:"fillOpacity",inputProps:{min:0,step:.01},definePropRef:{MxClass:MxDbArea,mxdrawSet(rt,Ae){Ae=Number(Ae),!isNaN(Ae)&&(rt.fillOpacity=Ae)}},isShow:c.isShowRef});const y=useLayer(),{create:b}=y,{list:m}=storeToRefs(y),O=defineRightDrawerUIProp({type:"select",label:"图层",vSelectProps:{items:m,itemTitle:"name",itemValue:"id",returnObject:!0},definePropRef:{everyMxcadFun(rt,Ae){return rt.layer===Ae.layer},everyMxdrawFun(rt,Ae){return rt.layer===Ae.layer},defaultVal:m.value[0],multipleCall(){O.ref.value=b({name:scopedTtranslate("760")})},mxdrawGet(rt){const Ae=m.value.find(({name:Te})=>Te===rt.layer);Ae&&(O.ref.value=Ae)},mxcadGet(rt){const Ae=m.value.find(({name:Te})=>Te===rt.layer);O&&(O.ref.value=Ae)},mxcadSet(rt,Ae){rt.layer=Ae.name},mxdrawSet(rt,Ae){rt.layer=Ae.name}},isShow:e}),{createLineType:N}=useLineType(),{lineTypeList:L}=storeToRefs(useLineType()),G=defineRightDrawerUIProp({type:"select",label:"线型",mcPropName:"linetype",vSelectProps:{items:L,itemTitle:"name",returnObject:!0},definePropRef:{multipleCall(){G.ref.value=N({name:scopedTtranslate("760")})},mxcadGet(rt){const Ae=L.value.find(({name:Te})=>Te===rt.linetype);Ae&&(G.ref.value=Ae)},mxcadSet(rt,Ae){Ae&&(rt.linetype=Ae.name)}},isShow:e}),q=defineRightDrawerUIProp({type:"input",label:"线型比例",mcPropName:"linetypeScale",inputProps:{min:0,step:.001},definePropRef:{defaultVal:0,mxcadGet(rt){q.ref.value=keepDecimal(rt.linetypeScale,3)},mxcadSet(rt,Ae){Ae=Number(Ae),!isNaN(Ae)&&(rt.linetypeScale=Ae)}},isShow:e});defineRightDrawerUIProp({type:"input",label:"透明度",mxPropName:"opacity",inputProps:{min:0,step:.01},definePropRef:{defaultVal:0,mxdrawSet(rt,Ae){Ae=Number(Ae),!isNaN(Ae)&&(rt.opacity=Ae)}},isShow:l});const J=defineRightDrawerUIProp({type:"input",label:"渲染顺序",definePropRef:{defaultVal:0,everyMxcadFun(rt,Ae){return rt.drawOrder===Ae.drawOrder},everyMxdrawFun(rt,Ae){return rt.renderOrder===Ae.renderOrder},multipleCall(){J.ref.value=scopedTtranslate("760")},mxdrawSet(rt,Ae){Ae=Number(Ae),!isNaN(Ae)&&(rt.renderOrder=Ae)},mxdrawGet(rt){J.ref.value=rt.renderOrder},mxcadGet(rt){J.ref.value=rt.drawOrder},mxcadSet(rt,Ae){Ae=Number(Ae),!isNaN(Ae)&&(rt.drawOrder=Ae)}}});defineRightDrawerUIProp({type:"input",label:"虚线长度间距",mxPropName:"dDashArray",inputProps:{min:0,step:.01},definePropRef:{defaultVal:0,mxdrawSet(rt,Ae){Ae=Number(Ae),!isNaN(Ae)&&(rt.dDashArray=Ae)}},isShow:l}),defineRightDrawerUIProp({type:"input",label:"虚实线长比例",mxPropName:"dDashRatio",inputProps:{min:0,step:.01},definePropRef:{defaultVal:0,mxdrawSet(rt,Ae){Ae=Number(Ae),!isNaN(Ae)&&(rt.dDashRatio=Ae)}},isShow:l});const fe=defineRightDrawerUIProp({type:"select",label:"线宽像素单位转换",vSelectProps:{items:ref(["是","否"])},isTranslationVSelectTitle:!0,definePropRef:{mxdrawGet(rt){fe.ref.value=rt.lineWidthByPixels?"是":"否"},mxdrawSet(rt,Ae){rt.lineWidthByPixels=Ae==="是"}},isShow:l}),ve=defineRightDrawerUIProp({type:"select",label:"可见",mxPropName:"visible",vSelectProps:{items:ref(["是","否"])},isTranslationVSelectTitle:!0,definePropRef:{multipleCall(){ve.ref.value=scopedTtranslate("760")},mxcadGet(rt){ve.ref.value=rt.visible?"是":"否"},mxcadSet(rt,Ae){rt.visible=Ae==="是"},mxdrawGet(rt){ve.ref.value=rt.visible?"是":"否"},mxdrawSet(rt,Ae){rt.visible=Ae==="是"}}});let ne=Object.keys(McDb.LineWeight).filter(rt=>isNaN(Number(rt))).map(rt=>{const Ae=McDb.LineWeight[rt];let Te=(Ae/100).toFixed(2)+scopedTtranslate("178");return rt==="kLnWtByBlock"&&(Te="随块"),rt==="kLnWtByLayer"&&(Te="随层"),rt==="kLnWtByLwDefault"&&(Te="缺省"),{value:Ae,name:Te}});const Ue=defineRightDrawerUIProp({type:"select",label:"线宽",mcPropName:"lineweight",mxPropName:"dLineWidth",vSelectProps:{items:ref(ne),itemTitle:"name"},isTranslationVSelectTitle:!0,inputProps:{min:1},definePropRef:{defaultVal:ne[0],multipleCall(){Ue.type==="input"&&(Ue.ref.value=scopedTtranslate("760")),Ue.type==="select"&&(Ue.ref.value={value:void 0,name:scopedTtranslate("760")})},mxcadGet(rt){Ue.type="select";const Ae=ne.find(({value:Te})=>Te===rt.lineweight);Ae&&(Ue.ref.value=Ae)},mxdrawGet(rt){Ue.type="input",Ue.ref.value=rt.dLineWidth},mxcadSet(rt,Ae){if(typeof Ae=="string")return;const Te=ne.find(({value:Xe})=>Xe===(typeof Ae=="object"?Ae.value:Ae));Te?.value&&(rt.lineweight=Te.value)},mxdrawSet(rt,Ae){typeof Ae=="number"&&rt.setLineWidth(Ae)}}}),De=defineRightDrawerUIProp({type:"string",label:"法向坐标",disabled:!0,definePropRef:{defaultVal:"(0,0,1)",everyMxcadFun(rt,Ae){return rt.normal.isEqualTo(Ae.normal)},multipleCall(){De.ref.value=scopedTtranslate("760")},mxcadGet(rt){De.ref.value="("+rt.normal.toVector3().toArray().toString()+")"}},isShow:e}),Ve=defineRightDrawerUIProp({type:"string",label:"其他信息",disabled:!0,definePropRef:{defaultVal:"",mxcadGet(rt){Ve.ref.value=`(id:${rt.getObjectID().id},handle:${rt.getHandle()})`}},isShow:e})})};class Stack{constructor(){Pm(this,"items",{});Pm(this,"count",0)}push(e){this.items[this.count++]=e}peek(){return this.items[this.count-1]}pop(){if(this.isEmpty())return;const e=this.items[--this.count];return delete this.items[this.count],e}isEmpty(){return this.count===0}size(){return this.count}clear(){this.items={},this.count=0}toString(){if(this.isEmpty())return"";let e=`${this.items[0]}`;for(let l=1;l<this.count;l++)e+=` ${this.items[l]}`;return e}}const useStack=()=>new Stack;function getStyle(t,e){return typeof window.getComputedStyle<"u"?window.getComputedStyle(t,null)[e]:typeof t.currentStyle<"u"?t.currentStyle[e]:""}const matrix3dReg=/^matrix3d\((?:[-\d.]+,\s*){12}([-\d.]+),\s*([-\d.]+)(?:,\s*[-\d.]+){2}\)/,matrixReg=/^matrix\((?:[-\d.]+,\s*){4}([-\d.]+),\s*([-\d.]+)\)$/,mountedDrag=(t,e)=>{let l=0,n=0;const u=()=>l,c=()=>n,y=t;y.style.position="absolute",y.style.transform="translate3d(0, 0, 1px)";const b=N=>{const L={clientX:0,clientY:0,targetX:0,targetY:0,distX:0,distY:0},G=getStyle(y,"transform"),q=G.match(matrix3dReg)||G.match(matrixReg);L.clientX=N.clientX,L.clientY=N.clientY,L.targetX=q[1],L.targetY=q[2],L.distX=L.clientX-L.targetX,L.distY=L.clientY-L.targetY;const J=N.pageX-y.offsetLeft,fe=N.pageY-y.offsetTop,ve=function(ne){ne.stopPropagation(),ne.preventDefault(),l=ne.clientX-L.distX,n=ne.clientY-L.distY,Math.abs(n)>=Math.abs(L.clientY-fe)&&(n>0?n=L.clientY-fe:n=-(L.clientY-fe)),Math.abs(l)>=Math.abs(L.clientX-J)&&(l>0?l=L.clientX-J:l=-(L.clientX-J)),y.style.transform=`translate3d(${l}px, ${n}px, 1px)`};document.onmousemove=ve,document.onmouseup=function(){document.onmousemove=document.onmouseup=null}},m=e||t;return m.addEventListener("mousedown",b),{destroy:()=>{m.removeEventListener("mousedown",b)},getMoveX:u,getMoveY:c}},stack=useStack(),useDialogIsShow=(t=!1,e,l)=>{const{setCommandFocus:n}=useFocus$1(),u=ref(t),c=useConfirmDialog(u);t&&(stack.push(u),n(!1));const y=async(b,m)=>{if(b===void 0?u.value=!u.value:isBoolean$1(b)&&(u.value=b),u.value)return await c.reveal(m)};return watch(u,b=>{b?(stack.push(u),n(!1)):(stack.pop(),stack.isEmpty()&&n(!0),c.cancel())}),e&&addCommand(e,l||(b=>y(!0,b))),{isShow:u,showDialog:y,...c}},closeDialog=()=>{stack.isEmpty()||(stack.peek().value=!1)},useMxDialogDrag=()=>{let t;const e=ref(),l=ref();let n;const u=()=>{t=e.value?.contentEl,n&&n()};let c=()=>-423,y=()=>-370;const b=()=>c()===0?-370:c(),m=()=>y()===0?-360:y();return onUpdated(()=>{if(t=e.value?.contentEl,t){u();const{getMoveX:O,getMoveY:N,destroy:L}=mountedDrag(t,l.value?.$el);n=L,c=O,y=O}}),onUnmounted(u),{dialog:e,dialogTitleEl:l,closeDialog,getMoveX:b,getMoveY:m}},usePopup=defineStore("popup",()=>{const{isShow:t,showDialog:e}=useDialogIsShow(),l=ref({title:"MxCAD警告",text:"",cancelTitle:"取消",defineTitle:"确定"});return{open(n){e(!0),l.value={...l.value,...n}},isShow:t,showDialog:e,options:l}}),useBigFont=(t,e)=>{const l=ref([]),n=ref([]),u=ref([]);onLoadComplete(()=>{l.value=MxCpp.App.getShxFonts(),u.value=MxCpp.App.getShxBigFonts(),n.value=MxCpp.App.getTrueTypeFonts().map(({zhname:N,name:L})=>N||L)});const c=ref(["常规"]),y=computed(()=>t.value[e.value].isBigFont?l.value:n.value),b=computed(()=>t.value[e.value].isBigFont?u.value:c.value);return{fontNames:y,fontStyles:b,getFontName:(N=e.value)=>y.value.find(L=>{t.value[N].fileName}),getFontStyle:(N=e.value)=>b.value.find(L=>{t.value[N].bigFontFileName}),txtFontNames:l,trueTypeFontNames:n,bigFontNames:u}},useStyleCurrent=t=>{const e=ref({bigFontFileName:"",fileName:"",id:-1,name:"",obliquingAngle:0,textSize:0,typeFace:"",xScale:0,isBigFont:!0}),l=ref(!1);return watch(t,(c,y)=>{y.length!==0&&(l.value=!0)},{deep:!0}),{current:e,isUpdate:l,initCurrent:c=>{c=c||getDatabase().getCurrentlyTextStyleName();const y=t.value.find(b=>b.name===c)||t.value[0];e.value=y},closeUpdate:()=>{nextTick(()=>{l.value=!1})}}},useStyleList=()=>{const t=ref([]),e=ref(0),{fontNames:l,fontStyles:n,txtFontNames:u,trueTypeFontNames:c,bigFontNames:y}=useBigFont(t,e),{current:b,isUpdate:m,initCurrent:O,closeUpdate:N}=useStyleCurrent(t),L=Te=>{function Xe(kt){return Number(kt.toFixed(3))}let{obliquingAngle:ie,textSize:ue,xScale:pt,...mt}=Te;ie&&(ie=Xe(ie)),ue&&(ue=Xe(ue)),pt&&(pt=Xe(pt));const Tt=!mt.typeFace||mt.typeFace==="";return{fileName:"txt.shx",bigFontFileName:"hztxt.shx",id:0,name:"",obliquingAngle:ie||0,textSize:ue||0,typeFace:"",xScale:pt||.8,...mt,isBigFont:Tt}},G=()=>{const Te=getDatabase().getTextStyleTable();t.value=JSON.parse(Te.getJson()).map(Xe=>L(Xe))},q=()=>{G(),O(),e.value=t.value.indexOf(b.value),nextTick(()=>{m.value=!1})};onOpenFileComplete(q);const J=(Te,Xe)=>{Te.bigFontFileName=Xe.bigFontFileName,Te.fileName=Xe.fileName,Te.name=Xe.name,Te.obliquingAngle=Xe.obliquingAngle,Te.textSize=Xe.textSize;const ie=Te.font();Te.setFont(Xe.typeFace,ie.bold,ie.italic,ie.charset,ie.pitchAndFamily)},fe=()=>{const Te=getDatabase().getTextStyleTable(),Xe=t.value[e.value];if(Te.has(Xe.name,!1)){const ie=Te.get(Xe.name);if(!ie.isValid())return;const ue=ie.getMcDbTextStyleTableRecord();if(!ue)return;J(ue,Xe),ie.erase(!1)}getDatabase().setCurrentlyTextStyle(b.value.name),m.value=!1},ve=Te=>{const{open:Xe}=usePopup(),ie=()=>{e.value=Te};return m.value?Xe({text:scopedTtranslate("444")+`
- `+scopedTtranslate("445")+"?",cancelTitle:scopedTtranslate("141"),defineTitle:scopedTtranslate("140"),define:()=>{fe(),ie(),N()},cancel:()=>{G(),ie(),N()}}):ie()},ne=()=>{b.value=t.value[e.value],getDatabase().setCurrentlyTextStyle(b.value.name)};let Ue=0;const De=ref(scopedTtranslate("样式)0")),Ve=()=>{const Te=getDatabase().getTextStyleTable();if(Te.has(De.value,!1)){const ue=Te.get(De.value),pt=useMessage();if(ue.isValid()){pt.error(scopedTtranslate("447")),ue.erase(!1),Ue++,De.value=scopedTtranslate("422")+Ue;return}}const Xe=L({name:De.value}),ie=new McDbTextStyleTableRecord;if(J(ie,Xe),Te.add(ie).isValid())return t.value.push(Xe),e.value=t.value.length-1,nextTick(()=>{m.value=!1}),Ue++,De.value=scopedTtranslate("422")+Ue,!0},rt=()=>{const Te=t.value[e.value].name,ie=getDatabase().getTextStyleTable().get(Te),ue=ie.isValid();ue&&ie.erase(),t.value.splice(e.value,1),t.value[e.value+1]?e.value++:t.value[e.value-1]?e.value--:e.value=0,nextTick(()=>{ue&&(m.value=!1)})},Ae=computed(()=>t.value.map(({name:Te})=>Te));return{list:t,current:b,index:e,fontNames:l,fontStyles:n,newStyleName:De,isUpdate:m,init:q,setIndex:ve,putCurrent:ne,add:Ve,remove:rt,apply:fe,textStyles:Ae,txtFontNames:u,trueTypeFontNames:c,bigFontNames:y}},useTextStyle=defineStore("textStyle",()=>useStyleList());let dialog;const open=t=>new Promise(async e=>{dialog.onConfirm(({text:l})=>{e(l)}),dialog.cancel(()=>{e(!1)}),dialog.showDialog(!0,t)}),useMultilineTextDialog=()=>(dialog||(dialog=useDialogIsShow(!1)),{dialog,open});let isLoad$1=!1;const useMText=({defineEntityProp:t,getFirstSelectData:e,selectUpdateFun:l})=>{if(isLoad$1)return;isLoad$1=!0;const u={categoryName:"文字",isShow:getIsType("多行文字")},c=defineRightDrawerUIProp({...u,type:"input",inputProps:{},label:"内容",mcPropName:"contents",getPoint:async()=>{const{open:Ve}=useMultilineTextDialog(),rt=new McDbMText;rt.contents=c.ref.value,rt.attachment=McDb.AttachmentPoint.kTopLeft,typeof y.ref.value=="number"&&(rt.textHeight=y.ref.value),rt.textStyle=fe.ref.value;const Ae=await Ve(rt);typeof Ae=="string"&&(c.ref.value=Ae)},getPointIcon:"duohangwenben",getPointTip:"编辑",definePropRef:{everyMxcadFun(Ve,rt){return Ve.contents===rt.contents},multipleCall(){c.ref.value=scopedTtranslate("760")},McClass:McDbMText,mxcadGet(Ve){c.ref.value=Ve.contents},mxcadSet(Ve,rt){Ve.contents=rt}}}),y=defineRightDrawerUIProp({...u,type:"input",label:"高度",mcPropName:"textHeight",definePropRef:{McClass:McDbMText,everyMxcadFun(Ve,rt){return Ve.textHeight===rt.textHeight},multipleCall(){y.ref.value=scopedTtranslate("760")},mxcadGet(Ve){y.ref.value=keepDecimal(Ve.textHeight,3)},mxcadSet(Ve,rt){rt=Number(rt),!isNaN(rt)&&(Ve.textHeight=rt)}}}),b=defineRightDrawerUIProp({...u,type:"input",label:"旋转角度",mcPropName:"rotation",definePropRef:{everyMxcadFun(Ve,rt){return Ve.rotation===rt.rotation},multipleCall(){b.ref.value=scopedTtranslate("760")},mxcadGet(Ve){b.ref.value=keepDecimal(THREE.MathUtils.radToDeg(Ve.rotation),3)},McClass:McDbMText,mxcadSet(Ve,rt){rt=Number(rt),!isNaN(rt)&&(Ve.rotation=THREE.MathUtils.degToRad(rt))}}}),m=defineRightDrawerUIProp({...u,type:"input",label:"文字宽度",mcPropName:"width",definePropRef:{everyMxcadFun(Ve,rt){return Ve.width===rt.width},mxcadGet(Ve){m.ref.value=keepDecimal(Ve.width,3)},multipleCall(){m.ref.value=scopedTtranslate("760")},McClass:McDbMText,mxcadSet(Ve,rt){rt=Number(rt),!isNaN(rt)&&(Ve.width=rt)}}}),O={Top:"上",Middle:"中",Bottom:"下",Base:"基",Left:"左",Center:"中",Right:"右",Align:"对齐",Fit:"适应",Mid:"中"},N=Ve=>Ve.replace(/k(\w+)/g,function(rt,Ae){return Ae.replace(/([A-Z])/g,"-$1").split("-").reduce((ue,pt)=>O[pt]?ue+scopedTtranslate(O[pt]):"")}),L=Object.keys(McDb.AttachmentPoint).filter(Ve=>isNaN(Number(Ve))&&McDb.AttachmentPoint[Ve]<10).map(Ve=>{const rt=N(Ve),Ae=McDb.AttachmentPoint[Ve];return{name:rt,value:Ae}}),G=defineRightDrawerUIProp({...u,type:"select",label:"文字对齐方式",vSelectProps:{items:ref(L),itemTitle:"name"},definePropRef:{everyMxcadFun(Ve,rt){return Ve.attachment===rt.attachment},defaultVal:L[0],multipleCall(){G.ref.value={name:scopedTtranslate("760"),value:McDb.AttachmentPoint.kBaseAlign}},McClass:McDbMText,mxcadGet(Ve){const rt=L.find(({value:Ae})=>Ve.attachment===Ae);rt&&(G.ref.value=rt)},mxcadSet(Ve,rt){rt&&(Ve.attachment=rt)}}}),q=useTextStyle(),{textStyles:J}=storeToRefs(q),fe=defineRightDrawerUIProp({...u,type:"select",label:"样式",mcPropName:"textStyle",vSelectProps:{items:J},definePropRef:{multipleCall(){fe.ref.value=scopedTtranslate("760")},mxcadGet(Ve){const rt=J.value.find(Ae=>Ve.textStyle===Ae);rt&&(fe.ref.value=rt)},McClass:McDbMText,mxcadSet(Ve,rt){const Ae=J.value.find(Te=>rt===Te);Ae&&(Ve.textStyle=Ae)}}}),ve=async()=>{const Ve=e();if(Ve.type===McObjectIdType.kMxCAD){const rt=new MxCADUiPrPoint;rt.setMessage(`
- `+scopedTtranslate("762")+":");const Te=Ve.objId.getMcDbEntity().location;rt.setBasePt(Te);let Xe=await rt.go();if(!Xe)return;l({mxcadFun:(ie,ue)=>{ie.location=ue}},Xe)}},ne=defineRightDrawerUIProp({...u,type:"input",label:"位置坐标X",getPoint:ve,definePropRef:{everyMxcadFun(Ve,rt){return Ve.location.x===rt.location.x},multipleCall(){ne.ref.value=scopedTtranslate("760")},mxcadGet(Ve){ne.ref.value=keepDecimal(Ve.location.x,3)},McClass:McDbMText,mxcadSet(Ve,rt){if(rt=Number(rt),isNaN(rt))return;const Ae=Ve.location.clone();Ae.x=rt,Ve.location=Ae}}}),Ue=defineRightDrawerUIProp({...u,type:"input",label:"位置坐标Y",getPoint:ve,definePropRef:{everyMxcadFun(Ve,rt){return Ve.location.y===rt.location.y},multipleCall(){Ue.ref.value=scopedTtranslate("760")},mxcadGet(Ve){Ue.ref.value=keepDecimal(Ve.location.y,3)},McClass:McDbMText,mxcadSet(Ve,rt){if(rt=Number(rt),isNaN(rt))return;const Ae=Ve.location.clone();Ae.y=rt,Ve.location=Ae}}}),De=defineRightDrawerUIProp({...u,type:"input",label:"位置坐标Z",getPoint:ve,definePropRef:{everyMxcadFun(Ve,rt){return Ve.location.z===rt.location.z},multipleCall(){De.ref.value=scopedTtranslate("760")},mxcadGet(Ve){De.ref.value=keepDecimal(Ve.location.z,3)},McClass:McDbMText,mxcadSet(Ve,rt){if(rt=Number(rt),isNaN(rt))return;const Ae=Ve.location.clone();Ae.z=rt,Ve.location=Ae}}});return{mText:c,textHeight:y,textRotation:b,textWidthFactor:m,locationX:ne,locationY:Ue,locationZ:De,getTextLocation:ve,attachments:L,attachment:G,textStyle:fe}};let isLoad=!1;const useText=({defineEntityProp:t,getFirstSelectData:e,selectUpdateFun:l,update:n})=>{if(isLoad)return;isLoad=!0;const u=useTextStyle(),{textStyles:c}=storeToRefs(u),y=getIsType("单行文字"),b={categoryName:"文字"},m=defineRightDrawerUIProp({...b,type:"input",label:"内容",mcPropName:"textString",mxPropName:"text",definePropRef:{McClass:McDbText,MxClass:MxDbText},isShow:y}),O=defineRightDrawerUIProp({...b,type:"select",label:"样式",mcPropName:"textStyle",vSelectProps:{items:c},definePropRef:{mxcadGet(ne){const Ue=c.value.find(De=>ne.textStyle===De);Ue&&(O.ref.value=Ue)},mxcadSet(ne,Ue){const De=c.value.find(Ve=>Ue===Ve);De&&(ne.textStyle=De)},McClass:McDbText},isShow:y}),N=defineRightDrawerUIProp({...b,type:"input",label:"高度",mcPropName:"height",mxPropName:"height",definePropRef:{mxcadGet(ne){N.ref.value=keepDecimal(ne.height,3)},mxdrawGet(ne){N.ref.value=keepDecimal(ne.height,3)},mxcadSet(ne,Ue){Ue=Number(Ue),!isNaN(Ue)&&(ne.height=Ue)},mxdrawSet(ne,Ue){Ue=Number(Ue),!isNaN(Ue)&&(ne.height=Ue)},McClass:McDbText,MxClass:MxDbText},isShow:y}),L=defineRightDrawerUIProp({...b,type:"input",label:"旋转角度",mcPropName:"rotation",definePropRef:{mxcadGet(ne){L.ref.value=keepDecimal(THREE.MathUtils.radToDeg(ne.rotation),3)},mxcadSet(ne,Ue){Ue=Number(Ue),!isNaN(Ue)&&(ne.rotation=THREE.MathUtils.degToRad(Ue))},McClass:McDbText,MxClass:MxDbText},isShow:y}),G=defineRightDrawerUIProp({...b,type:"input",label:"宽度因子",mcPropName:"widthFactor",definePropRef:{mxcadGet(ne){G.ref.value=keepDecimal(ne.widthFactor,3)},McClass:McDbText,MxClass:MxDbText,mxcadSet(ne,Ue){Ue=Number(Ue),!isNaN(Ue)&&(ne.widthFactor=Ue)}},isShow:y}),q=async()=>{const ne=e();if(ne.type===McObjectIdType.kMxCAD){const Ue=new MxCADUiPrPoint;Ue.setMessage(`
- 在图形中拾取点:`);const Ve=ne.objId.getMcDbEntity().position;Ue.setBasePt(Ve);let rt=await Ue.go();if(!rt)return;l({mxcadFun:(Ae,Te)=>{Ae.position=Te,Ae.alignmentPoint=Te}},rt)}},J=defineRightDrawerUIProp({...b,type:"input",label:"位置坐标X",getPoint:q,definePropRef:{everyMxcadFun(ne,Ue){return ne.position.x===Ue.position.x},mxcadGet(ne){J.ref.value=keepDecimal(ne.position.x,3)},McClass:McDbText,mxcadSet(ne,Ue){if(Ue=Number(Ue),isNaN(Ue))return;const De=ne.position.clone();De.x=Ue,ne.position=De,ne.alignmentPoint=De}},isShow:y}),fe=defineRightDrawerUIProp({...b,type:"input",label:"位置坐标Y",getPoint:q,definePropRef:{everyMxcadFun(ne,Ue){return ne.position.y===Ue.position.y},mxcadGet(ne){fe.ref.value=keepDecimal(ne.position.y,3)},McClass:McDbText,mxcadSet(ne,Ue){if(Ue=Number(Ue),isNaN(Ue))return;const De=ne.position.clone();De.y=Ue,ne.position=De,ne.alignmentPoint=De}},isShow:y}),ve=defineRightDrawerUIProp({...b,type:"input",label:"位置坐标Z",getPoint:q,definePropRef:{everyMxcadFun(ne,Ue){return ne.position.z===Ue.position.z},mxcadGet(ne){ve.ref.value=keepDecimal(ne.position.z,3)},McClass:McDbText,mxcadSet(ne,Ue){if(Ue=Number(Ue),isNaN(Ue))return;const De=ne.position.clone();De.z=Ue,ne.position=De,ne.alignmentPoint=De}},isShow:y});return{text:m,textHeight:N,textRotation:L,textWidthFactor:G,textLocationX:J,textLocationY:fe,textLocationZ:ve,getTextLocation:q,textStyles:c,textStyle:O}};initEntityAttribute();const rightDrawerData=useRightDrawer();useBaseProps(rightDrawerData);const{length:length$1,area}=useCurveParameter(rightDrawerData);useMxDbLeadComment();useLine(rightDrawerData);usePolyLine(rightDrawerData);useCircularArc(rightDrawerData);useCircle(rightDrawerData,length$1.ref,area.ref);useBlock(rightDrawerData);useMxDbShape(rightDrawerData);onOpenFileComplete(()=>{useMText(rightDrawerData),useText(rightDrawerData)});const isShowDatabaseDisplay=browserCacheRef(!1,"Mx_isShowDatabaseDisplay"),useDatabaseDisplay=()=>({isShowDatabaseDisplay});function _typeof(t){"@babel/helpers - typeof";return _typeof=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(t)}function toPrimitive(t,e){if(_typeof(t)!="object"||!t)return t;var l=t[Symbol.toPrimitive];if(l!==void 0){var n=l.call(t,e||"default");if(_typeof(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function toPropertyKey(t){var e=toPrimitive(t,"string");return _typeof(e)=="symbol"?e:e+""}function _defineProperty(t,e,l){return(e=toPropertyKey(e))in t?Object.defineProperty(t,e,{value:l,enumerable:!0,configurable:!0,writable:!0}):t[e]=l,t}/*!
- * helper-js v3.1.5
- * Author: phphe <phphe@outlook.com> (https://github.com/phphe)
- * Homepage: null
- * Released under the MIT License.
- */function isArray(t){return Object.prototype.toString.call(t)==="[object Array]"}function notGreaterThan(t,e){return t<e?t:e}function arrayRemove(t,e){let l,n=0;for(;(l=t.indexOf(e))>-1;)t.splice(l,1),n++;return n}function arrayLast(t){return t[t.length-1]}function objectOnly(t,e){let l=new Set(e);const n={};return l.forEach(u=>{n[u]=t[u]}),n}function assignIfNoKey(t,e,l){t.hasOwnProperty(e)||(t[e]=l)}function objectAssignIfNoKey(t,e){return Object.keys(e).forEach(l=>{assignIfNoKey(t,l,e[l])}),t}function withoutUndefined(t){const e={};return Object.keys(t).forEach(l=>{t[l]!==void 0&&(e[l]=t[l])}),e}function walkTreeData(t,e){let l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};l=objectAssignIfNoKey({...l},{childrenKey:"children"});const{childrenKey:n}=l,u=isArray(t)?t:[t];class c{}const y=(b,m,O)=>{l.reverse&&(b=b.slice(),b.reverse());const N=b.length;for(let L=0;L<N;L++){const G=b[L],q=l.reverse?N-L-1:L,J=O?[...O,q]:[];l.childFirst&&G[n]!=null&&y(G[n],G,J);const fe=e(G,q,m,J);if(fe===!1)throw new c;if(fe==="skip children")continue;if(fe==="skip siblings")break;l.childFirst||G[n]!=null&&y(G[n],G,J)}};try{y(u,null,isArray(t)?[]:null)}catch(b){if(!(b instanceof c))throw b}}function cloneTreeData(t,e){const l={childrenKey:"children"},{childrenKey:n,nodeHandler:u}=l,c=new TreeData;return c.childrenKey=n,walkTreeData(t,(y,b,m,O)=>{let N=Object.assign({},y);N[n]&&(N[n]=[]),u&&(N=u(N,{oldNode:y,index:b,parent:m,path:O})),c.set(O,N)},{childrenKey:n}),c.data}class TreeData{constructor(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];_defineProperty(this,"data",void 0),_defineProperty(this,"childrenKey","children"),this.data=e}get rootChildren(){const{childrenKey:e}=this,{data:l}=this;return isArray(l)?l:l[e]}*iteratePath(e){let l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{childrenKey:n,rootChildren:u}=this;if(l.reverse){const c=[...this.iteratePath(e,{...l,reverse:!1})];c.reverse();for(const{path:y,node:b}of c)yield{path:y,node:b}}else{let c=[],y=u;for(const b of e){const m=[...c,b],O=y[b];yield{path:m,node:O},c=m,y=O[n]}}}getFamily(e){const l=[];for(const{node:n}of this.iteratePath(e))l.push(n);return l}get(e){return arrayLast(this.getFamily(e))}getParentAndIndex(e){const l=e.slice(),n=l.pop();return{parent:this.get(l),index:n,parentPath:l}}getParent(e){return this.getParentAndIndex(e).parent}set(e,l){if(e==null||e.length===0)this.data=l;else{const{childrenKey:n}=this;let{rootChildren:u}=this;const{parent:c,index:y}=this.getParentAndIndex(e);let b;e.length===1?(u||(this.data?this.data[n]=[]:this.data=[]),b=u):(c[n]||(c[n]=[]),b=c[n]),b[y]=l}}delete(e){const{childrenKey:l,rootChildren:n}=this,{parent:u,index:c}=this.getParentAndIndex(e),y=e.length===1?n:u[l],b=y[c];return y.splice(c,1),b}walk(e,l){const{childrenKey:n,data:u}=this;return walkTreeData(u,e,n,l)}clone(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return cloneTreeData(this.data),withoutUndefined({childrenKey:this.childrenKey,nodeHandler:e.nodeHandler||void 0})}}function hasClass(t,e){return t.classList?t.classList.contains(e):new RegExp("(^| )"+e+"( |$)","gi").test(t.className)}function css(t,e){return getComputedStyle(t)[e]}function binarySearch(t,e){let l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};l={start:0,end:t.length-1,maxTimes:1e3,...l};let{start:n,end:u}=l;const{returnNearestIfNoHit:c,maxTimes:y}=l;let b,m;n==null&&(n=0,u=t.length-1);let O=0,N;for(;n>=0&&n<=u;){if(O>=y)throw Error("binarySearch: loop times is over ".concat(y,", you can increase the limit."));b=Math.floor((u-n)/2+n),m=t[b];const L=O+1;if(N=e(m,b,L),N>0)u=b-1;else if(N<0)n=b+1;else return{index:b,value:m,count:L,hit:!0};O++}return c?{index:b,value:m,count:O+1,hit:!1,greater:N>0}:null}/*!
- * @virtual-list/vue
- * Author: phphe <phphe@outlook.com> (https://github.com/phphe)
- * Homepage: https://virtual-list.phphe.com
- * Released under the MIT License.
- */var _export_sfc$1=(t,e)=>{const l=t.__vccOpts||t;for(const[n,u]of e)l[n]=u;return l};const _sfc_main$1$2=defineComponent$1({props:{table:Boolean}}),_hoisted_1$3={key:0},_hoisted_2$3={key:1};function _sfc_render$1$1(t,e,l,n,u,c){return t.table?(openBlock(),createElementBlock("table",_hoisted_1$3,[renderSlot(t.$slots,"prepend"),createBaseVNode("tbody",null,[renderSlot(t.$slots,"default")]),renderSlot(t.$slots,"append")])):(openBlock(),createElementBlock("div",_hoisted_2$3,[renderSlot(t.$slots,"prepend"),renderSlot(t.$slots,"default"),renderSlot(t.$slots,"append")]))}var VirtualListTable=_export_sfc$1(_sfc_main$1$2,[["render",_sfc_render$1$1]]);const cpt=defineComponent$1({components:{VirtualListTable},props:{items:Array,disabled:Boolean,horizontal:Boolean,firstRender:{type:Number,default:10},buffer:{type:Number,default:100},itemKey:{type:[String,Function]},itemSize:{type:Function},table:Boolean},setup(t){const e=ref(0),l=ref(t.firstRender-1),n=computed(()=>{var mt;return notGreaterThan(l.value,(((mt=t.items)==null?void 0:mt.length)||1)-1)}),u=ref(0),c=computed(()=>G.value[e.value]?ie(e.value):0),y=computed(()=>G.value.length>0?ie(G.value.length-1)+arrayLast(L.value):0),b=computed(()=>G.value[n.value]?y.value-ie(n.value)-L.value[n.value]:0),m=computed(()=>t.disabled?{}:{overflow:"auto"}),O=computed(()=>{const mt={display:"flex"};return t.disabled||(t.horizontal?Object.assign(mt,{"margin-left":c.value+"px","margin-right":b.value+"px",width:y.value-b.value-c.value+"px"}):Object.assign(mt,{"margin-top":c.value+"px","margin-bottom":b.value+"px"})),mt["flex-direction"]=t.horizontal?"row":"column",t.table&&(delete mt.display,delete mt["flex-direction"]),mt}),N=computed(()=>reactive((t.items||[]).map(()=>null))),L=computed(()=>(t.items||[]).map((mt,Tt)=>{var kt;if(N[Tt]!=null)return N[Tt];let It=(kt=t.itemSize)==null?void 0:kt.call(t,mt,Tt);return It==null&&(It=u.value),It})),G=computed(()=>{const mt=[];return L.value.reduce((Tt,kt)=>(mt.push(Tt),Tt+kt),0),mt});watch(()=>t.items,Ve);const q=computed(()=>{if(!t.items||t.disabled)return;const mt=[];for(let Tt=e.value;Tt<=n.value;Tt++){const kt=t.items[Tt];if(!kt)break;mt.push({item:kt,index:Tt})}return mt}),J=ref(),fe=ref();onMounted(async()=>{Ve();try{ue()}catch{await nextTick(),Ve()}});let ve;function ne(){const mt=J.value;if(!mt)return;const Tt=Te(mt);ve!=null&&t.buffer-Math.abs(Tt-ve)>=10||(ve=Tt,Ve())}let Ue=!1,De=!1;async function Ve(){var mt;if(Ue){De=!0;return}if(!t.items||t.disabled)return;Ue=!0;const Tt=J.value,kt=(mt=fe.value)==null?void 0:mt.$el;if(!Tt||!kt)return;u.value||(u.value=an()),e.value=_n(),l.value=Dn(),await nextTick();let It,nn=0;const tn={},pn=t.table?kt.querySelector("tbody").children:kt.children;for(let Rn=0;Rn<pn.length;Rn++){const Lt=pn[Rn],wn=css(Lt,"position");if(wn&&["absolute","fixed"].includes(wn))continue;const hn=css(Lt,"display")!=="none"?Ae(Lt):0,xn=Lt.getAttribute("vt-index"),$n=xn?parseInt(xn):e.value+nn;tn[$n]=(tn[$n]||0)+hn,nn++}for(const Rn of Object.keys(tn)){const Lt=parseInt(Rn);N.value[Lt]!==tn[Lt]&&(N.value[Lt]=tn[Lt],It=!0)}It&&await nextTick(),Ue=!1,De&&(De=!1,Ve());function _n(){const Rn=Te(Tt)-Xe(Tt)-t.buffer;return binarySearch(G.value,wn=>wn-Rn,{returnNearestIfNoHit:!0}).index}function Dn(){const Rn=Te(Tt)-Xe(Tt)+rt(Tt)+t.buffer;return binarySearch(G.value,wn=>wn-Rn,{returnNearestIfNoHit:!0}).index}function an(){const Lt=[],wn=t.table?kt.querySelector("tbody").children:kt.children;for(let hn=0;hn<wn.length;hn++){const xn=wn[hn],$n=getComputedStyle(xn);if(["absolute","fixed"].includes($n.position))continue;const Xr=Ae(xn);if(Lt.push(Xr),Lt.length>=10)break}return Lt.length===0?0:Lt.reduce((hn,xn)=>hn+xn,0)/Lt.length}}function rt(mt){const Tt=getComputedStyle(mt);let kt=parseFloat(t.horizontal?Tt.width:Tt.height);return Tt.boxSizing==="border-box"&&(t.horizontal?kt=kt-parseFloat(Tt.borderLeftWidth)-parseFloat(Tt.borderRightWidth):kt=kt-parseFloat(Tt.borderTopWidth)-parseFloat(Tt.borderBottomWidth)),kt}function Ae(mt){let Tt=rt(mt);const kt=getComputedStyle(mt);return t.horizontal?Tt+=parseFloat(kt.borderLeftWidth)+parseFloat(kt.borderRightWidth)+parseFloat(kt.marginLeft)+parseFloat(kt.marginRight):Tt+=parseFloat(kt.borderTopWidth)+parseFloat(kt.borderBottomWidth)+parseFloat(kt.marginTop)+parseFloat(kt.marginBottom),Tt=Number.isNaN(Tt)?0:Tt,Tt}function Te(mt){return t.horizontal?mt.scrollLeft:mt.scrollTop}function Xe(mt){const Tt=getComputedStyle(mt);return t.horizontal?parseFloat(Tt.paddingLeft):parseFloat(Tt.paddingTop)}function ie(mt){return G.value[mt]}function ue(){const mt=J.value;new ResizeObserver(kt=>{for(let It of kt)if(hasClass(It.target,"vtlist")){Ve();break}}).observe(mt)}function pt(mt,Tt){if(t.itemKey){if(typeof t.itemKey=="string"&&t.itemKey==="index")return Tt;if(typeof t.itemKey=="function")return t.itemKey(mt,Tt)}}return{listElRef:J,listInnerRef:fe,onscroll:ne,listStyle:m,listInnerStyle:O,visibleItemsInfo:q,getItemKey:pt,update:Ve,sizes:L,positions:G,runtimeSizes:N}}}),_sfc_main$6=cpt;function _sfc_render(t,e,l,n,u,c){const y=resolveComponent("VirtualListTable");return openBlock(),createElementBlock("div",{class:"vtlist",ref:"listElRef",style:normalizeStyle(t.listStyle),onScrollPassive:e[0]||(e[0]=(...b)=>t.onscroll&&t.onscroll(...b))},[createVNode(y,{class:"vtlist-inner",ref:"listInnerRef",style:normalizeStyle(t.listInnerStyle),table:t.table},{prepend:withCtx(()=>[renderSlot(t.$slots,"prepend")]),append:withCtx(()=>[renderSlot(t.$slots,"append")]),default:withCtx(()=>[t.disabled?(openBlock(!0),createElementBlock(Fragment,{key:0},renderList(t.items,(b,m)=>renderSlot(t.$slots,"default",{key:t.getItemKey(b,m),item:b,index:m})),128)):(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(t.visibleItemsInfo,({item:b,index:m})=>renderSlot(t.$slots,"default",{key:t.getItemKey(b,m),item:b,index:m})),128))]),_:3},8,["style","table"])],36)}var VirtualList=_export_sfc$1(_sfc_main$6,[["render",_sfc_render]]);/*!
- * @he-tree/tree-utils v0.1.0-alpha.4
- * Author: phphe <phphe@outlook.com> (https://github.com/phphe)
- * Homepage: null
- * Released under the MIT License.
- */const CHILDREN="children";function makeTreeProcessor(t){const l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n={...defaultOptions,...l,data:t,stats:null,statsFlat:null,_statsMap:null,initialized:!1,init(){const{data:c,childrenKey:y}=this,b=new TreeData([]);this._statsMap=new Map,walkTreeData(c,(O,N,L,G)=>{const q=this.statHandler({...statDefault(),data:O,open:!!this.defaultOpen,parent:b.getParent(G),children:[],level:G.length});this._statsMap.set(O,q),b.set(G,q)},{childrenKey:y});const m=[];b.walk(O=>{m.push(O)}),this.stats=this.statsHandler(b.rootChildren),this.statsFlat=this.statsFlatHandler(m),this.initialized=!0},getStat(c){let y=this._statsMap.get(c);if(!y)throw new StatNotFoundError("Stat not found");return y},has(c){if(c.isStat)return this.statsFlat.indexOf(c)>-1;try{return!!this.getStat(c)}catch(y){if(y instanceof StatNotFoundError)return!1;throw y}},_getPathByStat(c){if(c==null)return[];const b=this.getSiblings(c).indexOf(c);return[...c.parent?this._getPathByStat(c.parent):[],b]},afterOneCheckChanged(c){const{checked:y}=c;if(c._ignoreCheckedOnce)return delete c._ignoreCheckedOnce,!1;const b=m=>{const{parent:O}=m;if(O){let N,L;for(const q of O.children)if(q.checked||q.checked===0)N=!0;else if(L=!0,N&&L)break;const G=L?N?0:!1:!0;O.checked!==G&&(this._ignoreCheckedOnce(O),O.checked=G),b(O)}};return b(c),walkTreeData(c.children,m=>{m.checked!==y&&(this._ignoreCheckedOnce(m),m.checked=y)},{childrenKey:CHILDREN}),!0},_ignoreCheckedOnce(c){c._ignoreCheckedOnce=!0,setTimeout(()=>{c._ignoreCheckedOnce&&(c._ignoreCheckedOnce=!1)},100)},isVisible(c){const y=c.isStat?c:this.getStat(c),b=m=>!m||!m.hidden&&m.open&&b(m.parent);return!!(!y.hidden&&b(y.parent))},updateCheck(){walkTreeData(this.stats,c=>{if(c.children&&c.children.length>0){const y=c.children.every(b=>b.checked);c.checked!==y&&(this._ignoreCheckedOnce(c),c.checked=y)}},{childFirst:!0,childrenKey:CHILDREN})},getChecked(){let c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return this.statsFlat.filter(y=>y.checked||c&&y.checked===0)},getUnchecked(){let c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return this.statsFlat.filter(y=>c?!y.checked:y.checked===!1)},openAll(){for(const c of this.statsFlat)c.open=!0},closeAll(){for(const c of this.statsFlat)c.open=!1},openNodeAndParents(c){const y=c.isStat?c:this.getStat(c);for(const b of this.iterateParent(y,{withSelf:!0}))b.open=!0},_calcFlatIndex(c,y){let b=c?this.statsFlat.indexOf(c)+1:0;const m=c?c.children:this.stats;for(let O=0;O<y;O++)b+=this._count(m[O]);return b},add(c,y,b){if(this.has(c))throw"Can't add because data exists in tree";const m=y?y.children:this.stats;b==null&&(b=m.length);const O=this.statHandler({...statDefault(),open:!!this.defaultOpen,data:c,parent:y||null,children:[],level:y?y.level+1:1});this._setPosition(O,y||null,b);const N=c[this.childrenKey];if(N){const L=N.slice();for(const G of L)this.add(G,O)}},remove(c){const y=this.getSiblings(c);if(y.includes(c)){arrayRemove(y,c);const b=this._flat(c);this.statsFlat.splice(this.statsFlat.indexOf(c),b.length);for(const m of b)this._statsMap.delete(m.data);return this.afterRemoveStat(c),!0}return!1},getSiblings(c){const{parent:y}=c;return y?y.children:this.stats},_setPosition(c,y,b){(y?y.children:this.stats).splice(b,0,c),c.parent=y,c.level=y?y.level+1:1;const O=this._calcFlatIndex(y,b),N=this._flat(c);this.statsFlat.splice(O,0,...N);for(const L of N)this._statsMap.has(L.data)||this._statsMap.set(L.data,L);walkTreeData(c,(L,G,q)=>{q&&(L.level=q.level+1)},{childrenKey:CHILDREN}),this.afterSetStat(c,y,b)},*iterateParent(c,y){let b=y!=null&&y.withSelf?c:c.parent;for(;b;)yield b,b=b.parent},move(c,y,b){if(this.has(c)){if(c.parent===y&&this.getSiblings(c).indexOf(c)===b)return!1;if(c===y)throw new Error("Can't move node to it self");if(y&&c.level<y.level){let m;for(const O of this.iterateParent(y))if(O.level===c.level){m=O;break}if(c===m)throw new Error("Can't move node to its descendant")}this.remove(c)}return this._setPosition(c,y,b),!0},_flat(c){const y=[];return walkTreeData(c,b=>{y.push(b)},{childrenKey:CHILDREN}),y},_count(c){return this._flat(c).length},getData(c,y){const{childrenKey:b}=this,m=new TreeData([]);return m.childrenKey=b,walkTreeData(y||this.stats,(O,N,L,G)=>{let q={...O.data,[b]:[]};c&&(q=c(q)),m.set(G,q)},{childrenKey:CHILDREN}),m.data}},u=n;return n.noInitialization||u.init(),u}const defaultOptions={childrenKey:"children",defaultOpen:!1,statsHandler(t){return t},statsFlatHandler(t){return t},afterSetStat(t,e,l){},afterRemoveStat(t){},statHandler(t){return t}};function statDefault(){return{isStat:!0,hidden:!1,checked:!1,style:null,class:null,draggable:null,droppable:null}}class StatNotFoundError extends Error{constructor(e){super(e),this.name="StatNotFoundError"}}var __defProp=Object.defineProperty,__defProps=Object.defineProperties,__getOwnPropDescs=Object.getOwnPropertyDescriptors,__getOwnPropSymbols=Object.getOwnPropertySymbols,__hasOwnProp=Object.prototype.hasOwnProperty,__propIsEnum=Object.prototype.propertyIsEnumerable,__defNormalProp=(t,e,l)=>e in t?__defProp(t,e,{enumerable:!0,configurable:!0,writable:!0,value:l}):t[e]=l,__spreadValues=(t,e)=>{for(var l in e||(e={}))__hasOwnProp.call(e,l)&&__defNormalProp(t,l,e[l]);if(__getOwnPropSymbols)for(var l of __getOwnPropSymbols(e))__propIsEnum.call(e,l)&&__defNormalProp(t,l,e[l]);return t},__spreadProps=(t,e)=>__defProps(t,__getOwnPropDescs(e)),_export_sfc=(t,e)=>{const l=t.__vccOpts||t;for(const[n,u]of e)l[n]=u;return l};let justToggleOpen=!1;const afterToggleOpen=()=>{justToggleOpen=!0,setTimeout(()=>{justToggleOpen=!1},100)},cpt$2=defineComponent$1({props:["stat","rtl","btt","indent","table","treeLine","treeLineOffset","processor"],emits:["open","close","check"],setup(t,{emit:e}){const l=computed(()=>({[t.rtl?"paddingRight":"paddingLeft"]:t.indent*(t.stat.level-1)+"px"}));watch(()=>t.stat.checked,c=>{justToggleOpen||t.processor.afterOneCheckChanged(t.stat)&&e("check",t.stat)}),watch(()=>t.stat.open,c=>{justToggleOpen||(e(c?"open":"close",t.stat),afterToggleOpen())});const n=computed(()=>{const c=[],y=N=>{var L;if(N.parent){let G=(L=N.parent)==null?void 0:L.children.indexOf(N);do{G++;let q=N.parent.children[G];if(q){if(!q.hidden)return!0}else break}while(!0)}return!1},b=t.rtl?"right":"left",m=t.btt?"top":"bottom";let O=t.stat;for(;O;){let N=(O.level-2)*t.indent+t.treeLineOffset;const L=y(O),G=()=>{c.push({style:{[b]:N+"px",[m]:L?0:"50%"}})};O===t.stat?O.level>1&&G():L&&G(),O=O.parent}return c}),u=computed(()=>{let c=(t.stat.level-2)*t.indent+t.treeLineOffset;return{[t.rtl?"right":"left"]:c+"px"}});return{indentStyle:l,vLines:n,hLineStyle:u}}}),_sfc_main$2$1=cpt$2,_hoisted_1$2={class:"tree-node-inner"},_hoisted_2$2={key:1,class:"tree-node",ref:"el"};function _sfc_render$2(t,e,l,n,u,c){return t.table?(openBlock(),createElementBlock("tr",_hoisted_2$2,[renderSlot(t.$slots,"default",{indentStyle:t.indentStyle})],512)):(openBlock(),createElementBlock("div",{key:0,class:normalizeClass(["tree-node",{"tree-node--with-tree-line":t.treeLine}]),style:normalizeStyle(t.indentStyle),ref:"el"},[t.treeLine?(openBlock(),createElementBlock(Fragment,{key:0},[(openBlock(!0),createElementBlock(Fragment,null,renderList(t.vLines,y=>(openBlock(),createElementBlock("div",{class:"tree-line tree-vline",style:normalizeStyle(y.style)},null,4))),256)),t.stat.level>1?(openBlock(),createElementBlock("div",{key:0,class:"tree-line tree-hline",style:normalizeStyle(t.hLineStyle)},null,4)):createCommentVNode("",!0)],64)):createCommentVNode("",!0),createBaseVNode("div",_hoisted_1$2,[renderSlot(t.$slots,"default",{indentStyle:t.indentStyle})])],6))}var TreeNode=_export_sfc(_sfc_main$2$1,[["render",_sfc_render$2]]);function vueMakeTreeProcessor(t,e={}){const l=__spreadProps(__spreadValues({},e),{statHandler(n){return this._statHandler2&&(n=this._statHandler2(n)),filter(e.statHandler,reactive(n))},statsHandler(n){return filter(e.statsHandler,reactive(n))},statsFlatHandler(n){return filter(e.statsFlatHandler,reactive(n))}});return makeTreeProcessor(t,l)}function filter(t,e){return t?t(e):e}const cpt$1=defineComponent$1({components:{VirtualList,TreeNode},props:{value:{required:isVue2,type:Array},modelValue:{required:isVue3,type:Array},updateBehavior:{type:String,default:"modify"},processor:{type:Object,default:()=>vueMakeTreeProcessor([],{noInitialization:!0})},childrenKey:{type:String,default:"children"},textKey:{type:String,default:"text"},indent:{type:Number,default:20},virtualization:{type:Boolean,default:!1},virtualizationPrerenderCount:{type:Number,default:20},defaultOpen:{type:Boolean,default:!0},statHandler:{type:Function},rtl:{type:Boolean,default:!1},btt:{type:Boolean,default:!1},table:{type:Boolean,default:!1},watermark:{type:Boolean,default:!1},nodeKey:{type:[String,Function],default:"index"},treeLine:{type:Boolean,default:!1},treeLineOffset:{type:Number,default:8}},emits:["update:modelValue","click:node","open:node","close:node","check:node","beforeDragStart","before-drag-start","after-drop","change","enter","leave"],data(){return{stats:[],statsFlat:[],dragNode:null,dragOvering:!1,placeholderData:{},placeholderColspan:1,batchUpdateWaiting:!1,self:this,_ignoreValueChangeOnce:!1}},computed:{valueComputed(){return this.modelValue||[]},visibleStats(){const{statsFlat:t,isVisible:e}=this;let l=t;return this.btt&&(l=l.slice(),l.reverse()),l.filter(n=>e(n))},rootChildren(){return this.stats}},methods:{_emitValue(t){this.$emit("update:modelValue",t)},_updateValue(t){return this.updateBehavior==="disabled"?!1:(t!==this.valueComputed&&(this._ignoreValueChangeOnce=!0),this._emitValue(t),!0)},getStat:reactiveFirstArg(processorMethodProxy("getStat")),has:reactiveFirstArg(processorMethodProxy("has")),updateCheck:processorMethodProxy("updateCheck"),getChecked:processorMethodProxy("getChecked"),getUnchecked:processorMethodProxy("getUnchecked"),openAll:processorMethodProxy("openAll"),closeAll:processorMethodProxy("closeAll"),openNodeAndParents:processorMethodProxy("openNodeAndParents"),isVisible:processorMethodProxy("isVisible"),move:processorMethodProxyWithBatchUpdate("move"),add:reactiveFirstArg(processorMethodProxyWithBatchUpdate("add")),addMulti(t,e,l){this.batchUpdate(()=>{let n=l;for(const u of t)this.add(u,e,n),n!=null&&n++})},remove:processorMethodProxy("remove"),removeMulti(t){this.batchUpdate(()=>{for(const e of t)this.remove(e)})},iterateParent:processorMethodProxy("iterateParent"),getSiblings:processorMethodProxy("getSiblings"),getData:processorMethodProxy("getData"),getRootEl(){return this.$refs.vtlist.listElRef},batchUpdate(t){const e=this.ignoreUpdate(t);return this.batchUpdateWaiting||this._updateValue(this.updateBehavior==="new"?this.getData():this.valueComputed),e},ignoreUpdate(t){const e=this.batchUpdateWaiting;this.batchUpdateWaiting=!0;const l=t();return this.batchUpdateWaiting=e,l}},watch:{processor:{immediate:!0,handler(t){if(t){const e=l=>{if(l){const{childrenKey:n}=this;return l[n]||(l[n]=[]),l[n]}else return this.valueComputed};t._statHandler2=this.statHandler?l=>l.data===this.placeholderData?l:this.statHandler(l):null,t.afterSetStat=(l,n,u)=>{const{childrenKey:c,updateBehavior:y}=this;let b=this.valueComputed;if(y==="new"){if(this.batchUpdateWaiting)return;b=this.getData()}else if(y==="modify"){const m=e(n?.data);m.includes(l.data)||m.splice(u,0,l.data)}this.batchUpdateWaiting||this._updateValue(b)},t.afterRemoveStat=l=>{var n;const{childrenKey:u,updateBehavior:c}=this;let y=this.valueComputed;if(c==="new"){if(this.batchUpdateWaiting)return;y=this.getData()}else if(c==="modify"){const b=e((n=l.parent)==null?void 0:n.data);arrayRemove(b,l.data)}this.batchUpdateWaiting||this._updateValue(y)}}t.initialized||(t.data=this.valueComputed,Object.assign(t,objectOnly(this,["childrenKey","defaultOpen"])),t.init(),t.updateCheck()),this.stats=t.stats,this.statsFlat=t.statsFlat,t.data!==this.valueComputed&&this._updateValue(t.data)}},valueComputed:{handler(t){if(this.dragOvering||this.dragNode||this._ignoreValueChangeOnce)this._ignoreValueChangeOnce=!1;else{const{processor:l}=this;l.data=t,l.init(),this.stats=l.stats,this.statsFlat=l.statsFlat}}}},created(){},mounted(){this.watermark===!1&&(window._heTreeWatermarkDisabled=!0),this.watermark&&!window._heTreeWatermarkDisabled&&(window._heTreeWatermark||(window._heTreeWatermark=!0,console.log("%c[he-tree] Vue tree component: https://hetree.phphe.com","color:#0075ff; font-size:14px;")))}}),_sfc_main$1$1=cpt$1;function processorMethodProxy(t){return function(...e){return this.processor[t](...e)}}function processorMethodProxyWithBatchUpdate(t){return function(...e){return this.batchUpdate(()=>this.processor[t](...e))}}function reactiveFirstArg(t){return function(e,...l){return e&&(e=reactive(e)),t.call(this,e,...l)}}const _hoisted_1$1={key:0,class:"drag-placeholder he-tree-drag-placeholder"},_hoisted_2$1=["colspan"],_hoisted_3$1={class:"drag-placeholder he-tree-drag-placeholder"};function _sfc_render$1(t,e,l,n,u,c){const y=resolveComponent("TreeNode"),b=resolveComponent("VirtualList");return openBlock(),createBlock(b,{class:normalizeClass(["he-tree",{"he-tree--rtl rtl":t.rtl,"he-tree--drag-overing drag-overing":t.dragOvering}]),ref:"vtlist",items:t.visibleStats,disabled:!t.virtualization,table:t.table,itemKey:t.nodeKey},{prepend:withCtx(()=>[renderSlot(t.$slots,"prepend",{tree:t.self})]),default:withCtx(({item:m,index:O})=>[createVNode(y,{"vt-index":O,class:normalizeClass([m.class,{"drag-placeholder-wrapper":m.data===t.placeholderData,"dragging-node":m===t.dragNode}]),style:normalizeStyle(m.style),stat:m,rtl:t.rtl,btt:t.btt,indent:t.indent,table:t.table,treeLine:t.treeLine,treeLineOffset:t.treeLineOffset,processor:t.processor,onClick:N=>t.$emit("click:node",m),onOpen:e[0]||(e[0]=N=>t.$emit("open:node",N)),onClose:e[1]||(e[1]=N=>t.$emit("close:node",N)),onCheck:e[2]||(e[2]=N=>t.$emit("check:node",N))},{default:withCtx(({indentStyle:N})=>[m.data===t.placeholderData?(openBlock(),createElementBlock(Fragment,{key:0},[t.table?(openBlock(),createElementBlock("td",{key:1,style:normalizeStyle(N),colspan:t.placeholderColspan},[createBaseVNode("div",_hoisted_3$1,[renderSlot(t.$slots,"placeholder",{tree:t.self})])],12,_hoisted_2$1)):(openBlock(),createElementBlock("div",_hoisted_1$1,[renderSlot(t.$slots,"placeholder",{tree:t.self})]))],64)):renderSlot(t.$slots,"default",{key:1,node:m.data,stat:m,indentStyle:N,tree:t.self},()=>[createTextVNode(toDisplayString(m.data[t.textKey]),1)])]),_:2},1032,["vt-index","class","style","stat","rtl","btt","indent","table","treeLine","treeLineOffset","processor","onClick"])]),append:withCtx(()=>[renderSlot(t.$slots,"append",{tree:t.self})]),_:3},8,["class","items","disabled","table","itemKey"])}var BaseTree=_export_sfc(_sfc_main$1$1,[["render",_sfc_render$1]]);const McDbDimensionAttribute={textPosition(t){return t.textPosition.toVector3().toArray().join(",")},isUsingDefaultTextPosition(t){return t.isUsingDefaultTextPosition},elevation(t){return t.elevation},dimensionText(t){return t.dimensionText},textAttachment(t){return t.textAttachment},horizontalRotation(t){return t.horizontalRotation},textRotation(t){return t.textRotation}},McDbEntityAttributeName={McDbLine:{startPoint(t){return t.startPoint.toVector3().toArray().join(",")},endPoint(t){return t.endPoint.toVector3().toArray().join(",")}},McDbCircle:{center(t){return t.center.toVector3().toArray().join(",")},radius(t){return t.radius}},McDbPolyline:{constantWidth(t){return t.constantWidth},isClosed(t){return t.isClosed},vertexInfos(t){const e=t.numVerts(),l=[];for(let n=0;n<e;n++){const{val1:u,val2:c}=t.getWidthsAt(n);l.push(JSON.stringify({index:n,vertex:t.getPointAt(n).val.toVector3().toArray(),bulge:t.getBulgeAt(n),startWidth:u,endWidth:c}))}return l.join(",")},numVerts(t){return t.numVerts()}},McDbArc:{center(t){return t.center.toVector3().toArray().join(",")},radius(t){return t.radius},startAngle(t){return t.startAngle},endAngle(t){return t.endAngle}},McDbEllipse:{center(t){return t.center.toVector3().toArray().join(",")},majorAxis(t){return t.majorAxis.toVector3().toArray().join(",")},minorAxis(t){return t.minorAxis.toVector3().toArray().join(",")},radiusRatio(t){return t.radiusRatio},startAngle(t){return t.startAngle},endAngle(t){return t.endAngle}},McDbText:{position(t){return t.position.toVector3().toArray().join(",")},alignmentPoint(t){return t.alignmentPoint.toVector3().toArray().join(",")},oblique(t){return t.oblique},rotation(t){return t.rotation},height(t){return t.height},widthFactor(t){return t.widthFactor},textString(t){return t.textString},horizontalMode(t){return t.horizontalMode},verticalMode(t){return t.verticalMode}},McDbMText:{location(t){return t.location.toVector3().toArray().join(",")},rotation(t){return t.rotation},width(t){return t.width},textHeight(t){return t.textHeight},attachment(t){return t.attachment},contents(t){return t.contents}},McDbAlignedDimension:{...McDbDimensionAttribute,xLine1Point(t){return t.xLine1Point.toVector3().toArray().join(",")},xLine2Point(t){return t.xLine2Point.toVector3().toArray().join(",")},dimLinePoint(t){return t.dimLinePoint.toVector3().toArray().join(",")},oblique(t){return t.oblique}},McDbRotatedDimension:{...McDbDimensionAttribute,xLine1Point(t){return t.xLine1Point.toVector3().toArray().join(",")},xLine2Point(t){return t.xLine2Point.toVector3().toArray().join(",")},dimLinePoint(t){return t.dimLinePoint.toVector3().toArray().join(",")},oblique(t){return t.oblique},rotation(t){return t.rotation}},McDb2LineAngularDimension:{...McDbDimensionAttribute,rotation(t){return t.arcPoint.toVector3().toArray().join(",")},xLine1Start(t){return t.xLine1Start.toVector3().toArray().join(",")},xLine1End(t){return t.xLine1End.toVector3().toArray().join(",")},xLine2Start(t){return t.xLine2Start.toVector3().toArray().join(",")},xLine2End(t){return t.xLine2End.toVector3().toArray().join(",")}},McDbPoint:{position(t){return t.position.toVector3().toArray().join(",")}},McDbHatch:{numLoops(t){return t.numLoops},patternType(t){return t.patternType},patternName(t){return t.patternName},patternAngle(t){return t.patternAngle},patternScale(t){return t.patternScale},patternSpace(t){return t.patternSpace},patternDouble(t){return t.patternDouble},numPatternDefinitions(t){return t.numPatternDefinitions},hatchStyle(t){return t.hatchStyle},evaluateHatch(t){return t.evaluateHatch}}},useGetDataAttribute=()=>{const t=n=>({id:n.getObjectID().id,visible:n.visible,color:n.trueColor.getColorValue(),colorIndex:n.colorIndex,drawOrder:n.drawOrder,dxf0:n.dxf0,layer:n.layer,lineweight:n.lineweight,linetype:n.linetype,objectName:n.objectName,textStyle:n.textStyle}),e=n=>{const u=McDbEntityAttributeName[n.objectName];if(!u)return{};const c={};return Object.keys(u).forEach(y=>{c[y]=u[y](n)}),c};return{getDataAttr:n=>{const u=t(n),c=e(n);return{...u,...c}}}},_hoisted_1={key:0,class:"d-flex"},_hoisted_2={class:"database_menu"},_hoisted_3=["onDblclick","onMousedown"],_hoisted_4={class:"database_attribute"},_sfc_main$5=defineComponent$1({__name:"DatabaseDisplay",setup(t){const{isShowDatabaseDisplay:e}=useDatabaseDisplay(),{getDataAttr:l}=useGetDataAttribute(),n=ref();function u(J,fe=500){let ve=[];for(let ne=0;ne<J.length;ne+=fe)ve.push(J.slice(ne,ne+fe));return ve}const c=ref([{text:"数据库",children:[{text:"图块",children:[],onClick:(J,fe,ve)=>{if(J.data.children.length>0)return;const De=MxCpp.getCurrentMxCAD().getDatabase().blockTable.getAllRecordId(),Ve=rt=>{const Ae=rt.getMcDbBlockTableRecord();return Ae?{text:`${Ae?.getHandle()}: <${Ae?.name}>`,children:[],props:{name:Ae.name,origin:Ae.origin.toVector3().toArray().join(",")},onClick:(Xe,ie,ue)=>{if(ie.children&&ie.children.length>0)return;const pt=Ae?.getAllEntityId();if(!pt)return;const mt=[],Tt={};pt.forEach(kt=>{const It=kt.getMcDbEntity();if(!It)return;const nn={text:It.getHandle()+": <"+It.objectName+">",props:l(It)};Tt[It.objectName]?Tt[It.objectName].push(nn):Tt[It.objectName]=[nn]}),Object.keys(Tt).forEach(kt=>{const It=Tt[kt];It.length>500?u(It).forEach(tn=>{const pn={text:kt+`(${tn.length})`,children:[],onClick:(_n,Dn,an)=>{_n.data.children.length>0||u(tn,50).forEach(Rn=>{setTimeout(()=>{an.addMulti(Rn,_n,Dn.children.length-1)})})}};mt.push(pn)}):mt.push({text:kt+`(${It.length})`,children:[],onClick:(nn,tn,pn)=>{tn.children.length>0||u(It,50).forEach(_n=>{setTimeout(()=>{pn.addMulti(_n,nn,tn.children.length-1)})})}})}),ie.children=mt,ue.addMulti(mt,Xe,0)}}:void 0};u(De,50).forEach(rt=>{setTimeout(()=>{const Ae=[];for(let Te=0;Te<rt.length;Te++){const Xe=rt[Te],ie=Ve(Xe);ie&&Ae.push(ie)}ve.addMulti(Ae,J,fe.children.length-1)})})}},{text:"图层",children:[],onClick:(J,fe,ve)=>{if(J.data.children.length>0)return;const De=MxCpp.getCurrentMxCAD().getDatabase().getLayerTable().getAllRecordId();u(De,50).forEach(Ve=>{setTimeout(()=>{const rt=[];for(let Ae=0;Ae<Ve.length;Ae++){const Xe=Ve[Ae].getMcDbLayerTableRecord();if(!Xe)continue;const ie={text:Xe.getHandle()+`: <${Xe.name}>`,props:{name:Xe.name,color:Xe.color.getColorValue(),isLocked:Xe.isLocked,isFrozen:Xe.isFrozen,isOff:Xe.isOff,lineWeight:Xe.lineWeight}};rt.push(ie)}ve.addMulti(rt,J,fe.children.length-1)})})}},{text:"文字样式",children:[],onClick:(J,fe,ve)=>{if(J.data.children.length>0)return;const De=MxCpp.getCurrentMxCAD().getDatabase().textStyleTable.getAllRecordId();u(De,50).forEach(Ve=>{setTimeout(()=>{const rt=[];for(let Ae=0;Ae<Ve.length;Ae++){const Xe=Ve[Ae].getMcDbTextStyleTableRecord();if(!Xe)return;const ie={text:`${Xe.getHandle()}: <${Xe.name}>`,props:{name:Xe.name,obliquingAngle:Xe.obliquingAngle,bigFontFileName:Xe.bigFontFileName,fileName:Xe.fileName,flagBits:Xe.flagBits,isShapeFile:Xe.isShapeFile,isVertical:Xe.isVertical,textSize:Xe.textSize,xScale:Xe.xScale}};rt.push(ie)}ve.addMulti(rt,J,fe.children.length-1)})})}},{text:"线型",children:[],onClick:(J,fe,ve)=>{if(J.data.children.length>0)return;const De=MxCpp.getCurrentMxCAD().getDatabase().linetypeTable.getAllRecordId();u(De,50).forEach(Ve=>{setTimeout(()=>{const rt=[];for(let Ae=0;Ae<Ve.length;Ae++){const Xe=Ve[Ae].getMcDbLinetypeTableRecord();if(!Xe)continue;const ie={text:`${Xe.getHandle()}: <${Xe.name}>`,props:{name:Xe.name,comments:Xe.comments,isScaledToFit:Xe.isScaledToFit,numDashes:Xe.numDashes}};rt.push(ie)}ve.addMulti(rt,J,fe.children.length-1)})})}},{text:"标注样式",children:[],onClick:(J,fe,ve)=>{if(J.data.children.length>0)return;const De=MxCpp.getCurrentMxCAD().getDatabase().dimStyleTable.getAllRecordId();u(De,50).forEach(Ve=>{setTimeout(()=>{const rt=[];for(let Ae=0;Ae<Ve.length;Ae++){const Xe=Ve[Ae].getMcDbDimStyleTableRecord();if(!Xe)continue;const ie={text:`${Xe.getHandle()}: <${Xe.name}>`,props:{name:Xe.name}};rt.push(ie)}ve.addMulti(rt,J,fe.children.length-1)})})}},{text:"全局字典",children:[],onClick:(J,fe,ve)=>{if(J.data.children.length>0)return;const De=MxCpp.getCurrentMxCAD().getDatabase().getNamedObjectsDictionary(),Ve=[];De.getAllObjectName().forEach((rt,Ae)=>{const Xe=De.getAt(rt).getMcDbDictionary();if(!Xe)return;const ie={text:`${Xe.getHandle()}: <${rt}>`,props:{name:rt}};Ve.push(ie)}),fe.children=Ve,ve.addMulti(Ve,J,0)}}]}]),y=ref(0);onOpenFileComplete(()=>{c.value[0].children&&(c.value[0].children.forEach(J=>{J.children=[]}),y.value++)});const b=ref(),m=useHeaderHeight(),O=[{label:scope.t("754"),fn(){const J=b.value?.props?.id;if(typeof J>"u")return;const ve=new McObjectId(Number(J),McObjectIdType.kMxCAD).getMcDbEntity();if(!ve)return;const ne=ve.getxData();if(ne.GetCount()===0)return console.log("id: "+J+scope.t("755"));console.log("id: "+J+scope.t("756")+":"),ne.forEach(Ue=>{console.log(Ue)})}},{label:scope.t("757"),fn(){const J=b.value?.props?.id;if(typeof J>"u")return;const ve=new McObjectId(Number(J),McObjectIdType.kMxCAD).getMcDbEntity();if(!ve)return;const ne=ve.getExtensionDictionary();let Ue=ne.getAllObjectName();function De(Ve){Ve.getAllObjectName().forEach(Ae=>{console.log(Ae);let Xe=Ve.getAt(Ae).getMcDbObject();if(Xe instanceof McDbDictionary){let ie=Xe;console.log(ie),De(ie)}else Xe instanceof McDbXrecord&&Xe.getData().PrintData()})}if(Ue.length()===0)return console.log("id: "+J+scope.t("758"));console.log("id: "+J+scope.t("759")+":"),Ue.forEach(Ve=>{console.log(Ve);let Ae=ne.getAt(Ve).getMcDbObject();if(Ae instanceof McDbDictionary){let Te=Ae;console.log(Te),De(Te)}})}}],N=useRightClickMenuOptions({menuList:O,disabled(){return typeof b.value?.props?.id>"u"}}),L=J=>(J.parent||(J.open=!0),J.checked=!0,J),G=(J,fe,ve=16711680)=>{const ne=J.toVector3(),Ue=fe.toVector3(),De=new THREE.Vector3(ne.x,Ue.y),Ve=new THREE.Vector3(Ue.x,ne.y);return MxThreeJS.createLines([ne,De,Ue,Ve,ne],ve)},q=(J,fe,ve)=>{if(J.open=!J.open,fe.onClick&&fe.onClick(J,fe,ve),fe?.props&&fe.props?.id){const ne=MxCpp.getCurrentMxCAD(),Ue=ne.getDatabase().currentSpace,De=Ue.getHandle()+": <"+Ue.name+">",Ve=Te=>Te.data.text===De?!0:Te.parent?Ve(Te.parent):!1;if(!Ve(J))return;const Ae=new McObjectId(fe.props.id).getMcDbEntity();if(Ae){const Te=ne.mxdraw,{minPt:Xe,maxPt:ie}=Ae.getBoundingBox(),ue=Te.getTempMarkDraw();ue.clear();const pt=Xe.distanceTo(new McGePoint3d(Xe.x,ie.y)),mt=Xe.distanceTo(new McGePoint3d(Xe.x,ie.x)),Tt=Math.max(pt,mt),kt=Xe.clone(),It=ie.clone(),nn=Tt/10;kt.x-=nn,kt.y-=nn,It.x+=nn,It.y+=nn;const tn=G(kt,It,16711680);ue.drawCircleMark(new McGePoint3d((kt.x+It.x)/2,(kt.y+It.y)/2).toVector3(),Tt,16711680),ue.drawEntity(tn);const pn=Tt*10;Xe.x-=pn,Xe.y-=pn,ie.x+=pn,ie.y+=pn,ne.zoomW(Xe.clone(),ie.clone())}}};return(J,fe)=>{const ve=resolveDirective("right-click-menu");return unref(e)?(openBlock(),createElementBlock("div",_hoisted_1,[withDirectives((openBlock(),createElementBlock("div",_hoisted_2,[(openBlock(),createBlock(unref(BaseTree),{ref_key:"tree",ref:n,key:y.value,treeLine:"",statHandler:L,virtualization:"",style:normalizeStyle({height:`calc(100vh - ${unref(m)+44}px)`,width:"max-content",minWidth:"140px"}),defaultOpen:!1,modelValue:c.value,"onUpdate:modelValue":fe[0]||(fe[0]=ne=>c.value=ne),updateBehavior:"modify"},{default:withCtx(({node:ne,stat:Ue,tree:De})=>[ne.children?(openBlock(),createBlock(VBtn,{key:0,onClick:Ve=>{Ue.open=!Ue.open,ne.onClick&&ne.onClick(Ue,ne,De)},size:"16",rounded:"0",variant:"text"},{default:withCtx(()=>[createTextVNode(toDisplayString(Ue.open?"-":"+"),1)]),_:2},1032,["onClick"])):createCommentVNode("",!0),createBaseVNode("span",{class:normalizeClass(["mtl-ml",b.value===ne?"bg-primary":""]),onDblclick:Ve=>q(Ue,ne,De),style:{display:"inline-block",height:"100%"},onMousedown:Ve=>b.value=ne},toDisplayString(c.value[0].children?.includes(ne)||c.value.includes(ne)?J.t(ne.text):ne.text),43,_hoisted_3)]),_:1},8,["style","modelValue"]))])),[[ve,unref(N)]]),createBaseVNode("div",_hoisted_4,[b.value?.props?(openBlock(),createBlock(VTable,{key:0,density:"compact","fixed-header":"",height:`calc(100vh - ${unref(m)+44}px)`,class:"attribute_table",style:{"table-layout":"fixed"}},{default:withCtx(()=>[createBaseVNode("thead",null,[createBaseVNode("tr",null,[createBaseVNode("th",null,toDisplayString(J.t("747")),1),createBaseVNode("th",null,toDisplayString(J.t("686")),1)])]),createBaseVNode("tbody",null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(Object.keys(b.value.props),(ne,Ue)=>(openBlock(),createElementBlock("tr",{key:Ue},[createBaseVNode("td",null,toDisplayString(ne),1),createBaseVNode("td",null,toDisplayString(b.value.props[ne]),1)]))),128))])]),_:1},8,["height"])):(openBlock(),createElementBlock(Fragment,{key:1},[createTextVNode(toDisplayString(J.t("748")),1)],64))])])):createCommentVNode("",!0)}}}),DatabaseDisplay=_export_sfc$2(_sfc_main$5,[["__scopeId","data-v-ad0604f6"]]),drawerComponents={DrawingComparison:{isShow:isShowDrawingComparison,component:DrawingComparison,title:scopedTtranslate("768"),cmd:"",width:200},BlockLibrary:{isShow:isShowBlockLibrary,component:BlockLibrary,title:scopedTtranslate("769"),width:520,cmd:[{cmd:"Mx_BlockLibrary",call:async t=>{galleryType.value=GalleryType.Blocks,await nextTick(),t(520)}},{cmd:"Mx_DrawingsLibrary",call:async t=>{galleryType.value=GalleryType.Drawings,await nextTick(),t(520)}}]},TextSearch:{isShow:isShowTextSearch,component:TextSearch,title:scopedTtranslate("770"),cmd:[{cmd:"Mx_FindText",call:async t=>{drawerComponents.TextSearch.isShow.value?drawerComponents.TextSearch.isShow.value=!1:t(400)}}]},EntityAttribute:{isShow:isShowEntityAttribute,component:EntityAttribute,title:scopedTtranslate("684"),width:300,onClose:(t,e,l)=>{l&&(t(),e.value?.handleClose()),isSelected.value=!1},keyWhen(){return isSelected.value},cmd:[{cmd:"Mx_Properties",call:(t,e)=>{drawerComponents.EntityAttribute.isShow.value?drawerComponents.EntityAttribute.isShow.value=!1:t(300)}}]},DatabaseDisplay:{isShow:isShowDatabaseDisplay,component:DatabaseDisplay,width:600,title:scopedTtranslate("25"),cmd:[{cmd:"Mx_DatabaseDisplay",call:async t=>{drawerComponents.DatabaseDisplay.isShow.value?drawerComponents.DatabaseDisplay.isShow.value=!1:t(600)}}]}},addDrawerComponent=(t,e)=>{drawerComponents[t]?console.warn("侧边栏组件名:"+t+"已存在,无法添加"):drawerComponents[t]=e},useDrawerComponents=(t,e)=>{const l=[];t.forEach(c=>{const y=drawerComponents[c];if(!y)return;const b=m=>{n(),y.isShow.value=!0,e.value?.handleOpen(m)};return typeof y.cmd=="string"&&addCommand(y.cmd,b),Array.isArray(y.cmd)&&y.cmd.forEach(({cmd:m,call:O})=>{addCommand(m,()=>{O(b,e)})}),l.push(y),y});const n=()=>{l?.forEach(c=>{c.isShow.value=!1})};return{title:computed(()=>{if(!l)return"";for(let c=0;c<l.length;c++){const y=l[c];if(y.isShow.value)return y.title}}),closeAll:n,components:l}},_sfc_main$4=defineComponent$1({__name:"LeftDrawer",setup(t){const e=ref(),{title:l,closeAll:n,components:u}=useDrawerComponents(uiConfig.leftDrawerComponents||[],e),c=y=>{n(),u.forEach(b=>{b.onClose?b.onClose(n,e,y):e.value.handleClose()})};return(y,b)=>(openBlock(),createBlock(Drawer,{location:"left",title:unref(l),ref_key:"leftDrawer",ref:e,onClose:c,components:unref(u)},null,8,["title","components"]))}}),LeftDrawer=_export_sfc$2(_sfc_main$4,[["__scopeId","data-v-c1fe9c40"]]),_sfc_main$3=defineComponent$1({__name:"RightDrawer",setup(t){const e=ref(),{components:l,title:n,closeAll:u}=useDrawerComponents(uiConfig.rightDrawerComponents||[],e),c=y=>{l.forEach(b=>{b.onClose?b.onClose(u,e,y):e.value.handleClose()})};return(y,b)=>(openBlock(),createBlock(Drawer,{location:"right",title:unref(n),ref_key:"rightDrawer",ref:e,onClose:c,components:unref(l)},null,8,["title","components"]))}}),_sfc_main$2=defineComponent$1({__name:"index",setup(t){const{isFirstTimeOpen:e,isLoadOpenDrawing:l}=useFirstTimeOpenDwg(),n=Number(localStorage.getItem("Mx_rightdrawer_width"))||0,u=Number(localStorage.getItem("Mx_leftdrawer_width"))||0;return(c,y)=>unref(e)&&unref(l)?(openBlock(),createElementBlock(Fragment,{key:0},[unref(uiConfig).isShowLeftDrawer?(openBlock(),createBlock(LeftDrawer,{key:0})):createCommentVNode("",!0),unref(uiConfig).isShowRightDrawer?(openBlock(),createBlock(_sfc_main$3,{key:1})):createCommentVNode("",!0)],64)):(openBlock(),createElementBlock(Fragment,{key:1},[unref(u)!==0?(openBlock(),createBlock(VNavigationDrawer,{key:0,"model-value":!0,permanent:"",width:unref(u),location:"right",class:"pa-1 bg-prominent"},{default:withCtx(()=>[createVNode(VSkeletonLoader,{type:"paragraph",class:"w-100 h-100"})]),_:1},8,["width"])):createCommentVNode("",!0),unref(n)!==0?(openBlock(),createBlock(VNavigationDrawer,{key:1,"model-value":!0,permanent:"",width:unref(n),location:"left",class:"pa-1 bg-prominent"},{default:withCtx(()=>[createVNode(VSkeletonLoader,{type:"paragraph",class:"w-100 h-100"})]),_:1},8,["width"])):createCommentVNode("",!0)],64))}}),requireModules=Object.assign({"./AboutDialog/index.vue":()=>__vitePreload(()=>import("./index-BH2u6Mtr.js"),__vite__mapDeps([16,3,4,17]),import.meta.url),"./ArrayDialog/index.vue":()=>__vitePreload(()=>import("./index-iVKLIIPr.js"),__vite__mapDeps([18,3,4,19,20]),import.meta.url),"./AttachPictureDialog/index.vue":()=>__vitePreload(()=>import("./index-CRFMH-eq.js"),__vite__mapDeps([21,3,4]),import.meta.url),"./CADToPDFDialog/index.vue":()=>__vitePreload(()=>import("./index-ShAoptWN.js"),__vite__mapDeps([22,3,4]),import.meta.url),"./ColorSelectDialog/index.vue":()=>__vitePreload(()=>import("./index-DGgDsdLN.js"),__vite__mapDeps([23,3,4,5,6,7,8,9,10,24]),import.meta.url),"./CreateBlocksDialog/index.vue":()=>__vitePreload(()=>import("./index-Cz6Ec37f.js"),__vite__mapDeps([25,3,4,26]),import.meta.url),"./DWGCutDialog/index.vue":()=>__vitePreload(()=>import("./index-D1XXAW7v.js"),__vite__mapDeps([27,3,4,1,2,28]),import.meta.url),"./DimensionStyleManagerDialog/index.vue":()=>__vitePreload(()=>import("./index-Bk1fV-OO.js"),__vite__mapDeps([29,3,4,30]),import.meta.url),"./DraftingSettingsDialog/index.vue":()=>__vitePreload(()=>import("./index-CWQ67CZx.js"),__vite__mapDeps([31,3,4,5,6]),import.meta.url),"./InsertDialog/index.vue":()=>__vitePreload(()=>import("./index-DGIlKyM9.js"),__vite__mapDeps([32,3,4,1,2]),import.meta.url),"./LayerManagementDialog/LinearManagerDialog/index.vue":()=>__vitePreload(()=>import("./index-zOzy80IM.js"),__vite__mapDeps([33,3,4,34]),import.meta.url),"./LayerManagementDialog/index.vue":()=>__vitePreload(()=>import("./index-DQl_2X1i.js"),__vite__mapDeps([35,3,4,33,34,36,37]),import.meta.url),"./LineWeightSettingsDialog/index.vue":()=>__vitePreload(()=>import("./index-DhMIQvXp.js"),__vite__mapDeps([38,3,4,8,9,39]),import.meta.url),"./LinearManagerDialog/index.vue":()=>__vitePreload(()=>import("./index-CZjiVl8-.js"),__vite__mapDeps([40,3,4,41]),import.meta.url),"./MessageBoxDialogs/index.vue":()=>__vitePreload(()=>import("./index-Cho1JviK.js"),__vite__mapDeps([42,3,4]),import.meta.url),"./ModifyDimensionStylesDialog/index.vue":()=>__vitePreload(()=>import("./index-nJNJkaz0.js"),__vite__mapDeps([43,3,4,5,6,44]),import.meta.url),"./MultilineTextDialog/index.vue":()=>__vitePreload(()=>import("./index-q238DTSs.js"),__vite__mapDeps([45,3,4,46,47]),import.meta.url),"./PatternFillingDialog/index.vue":()=>__vitePreload(()=>import("./index-BqOFji3O.js"),__vite__mapDeps([48,3,4,49]),import.meta.url),"./PointStyleDialog/index.vue":()=>__vitePreload(()=>import("./index-C6Jlbm68.js"),__vite__mapDeps([50,3,4,51]),import.meta.url),"./PopupDialog/index.vue":()=>__vitePreload(()=>import("./index-CmrbCn_y.js"),__vite__mapDeps([52,3,4]),import.meta.url),"./PrintDialog/index.vue":()=>__vitePreload(()=>import("./index-zgJSgbIM.js"),__vite__mapDeps([53,3,4,54]),import.meta.url),"./QuickSelectionDialog/index.vue":()=>__vitePreload(()=>import("./index-BP7v9n-Z.js"),__vite__mapDeps([55,3,4,56]),import.meta.url),"./SelectLayerDialog/index.vue":()=>__vitePreload(()=>import("./index-C-IrQJDk.js"),__vite__mapDeps([57,3,4,36]),import.meta.url),"./SelectUploadXRefFileDialog/index.vue":()=>__vitePreload(()=>import("./index-B4IIMmzb.js"),__vite__mapDeps([58,3,4,59,13,14,60]),import.meta.url),"./SetUpDialog/index.vue":()=>__vitePreload(()=>import("./index-DlZg7BZu.js"),__vite__mapDeps([61,3,4,8,9,62]),import.meta.url),"./ShortcutKeySettingsDialog/index.vue":()=>__vitePreload(()=>import("./index-BC6zIT-j.js"),__vite__mapDeps([63,3,4,64]),import.meta.url),"./SingleLineTextDialog/index.vue":()=>__vitePreload(()=>import("./index-D-b_Xqbw.js"),__vite__mapDeps([65,3,4,46]),import.meta.url),"./TableDialog/index.vue":()=>__vitePreload(()=>import("./index-n0gERvBg.js"),__vite__mapDeps([66,3,4,67]),import.meta.url),"./TextFindDialog/index.vue":()=>__vitePreload(()=>import("./index-tfq16h0w.js"),__vite__mapDeps([68,3,4,1,2,11,12]),import.meta.url),"./TextStyleDialog/index.vue":()=>__vitePreload(()=>import("./index-BTYP6yHp.js"),__vite__mapDeps([69,3,4,70]),import.meta.url),"./WalkThroughLayersDialog/index.vue":()=>__vitePreload(()=>import("./index-RAYsk0uq.js"),__vite__mapDeps([71,3,4]),import.meta.url)});let components=[];for(const t in requireModules){const e=requireModules[t];components.push(defineAsyncComponent(e))}const _sfc_main$1=defineComponent$1({__name:"index",setup(t){const{isShow:e,abort:l,hideLoading:n,text:u}=useLoadingData(),c=()=>{n(),l.value&&(l.value(),l.value=void 0)};return(y,b)=>(openBlock(),createBlock(VOverlay,{modelValue:unref(e),"onUpdate:modelValue":b[0]||(b[0]=m=>isRef(e)?e.value=m:null),absolute:"","z-index":99999,class:"align-center justify-center",persistent:""},{default:withCtx(()=>[createVNode(VProgressCircular,{indeterminate:"",size:"64",color:"primary"}),withDirectives(createVNode(VBtn,{onClick:c,text:y.t(unref(u))},null,8,["text"]),[[vShow,unref(l)]])]),_:1},8,["modelValue"]))}}),_sfc_main=defineComponent$1({__name:"App",setup(t){const{isFirstTimeOpen:e,isLoadOpenDrawing:l}=useFirstTimeOpenDwg();return(n,u)=>(openBlock(),createBlock(VLayout,null,{default:withCtx(()=>[createVNode(_sfc_main$h),createVNode(_sfc_main$1),createVNode(Header,{show:unref(e)},null,8,["show"]),unref(e)?(openBlock(),createBlock(_sfc_main$2,{key:0})):createCommentVNode("",!0),unref(e)&&unref(l)?(openBlock(!0),createElementBlock(Fragment,{key:1},renderList(unref(components),c=>(openBlock(),createBlock(resolveDynamicComponent(c)))),256)):createCommentVNode("",!0),unref(uiConfig).isShowFooter?(openBlock(),createBlock(Footer,{key:2,show:unref(e)},null,8,["show"])):createCommentVNode("",!0)]),_:1}))}}),i18n={install:t=>{t.use(v,{i18nScope:scope})}};function registerPlugins(t){return t.use(i18n).use(createPinia()).use(mouseMenu)}const ScrollBottom={updated(t,e){(typeof e.value>"u"?!0:unref(e.value))&&t.scrollTo(t.scrollWidth,t.scrollHeight)}},CURSORTYPE={top:"n-resize",bottom:"s-resize",left:"w-resize",right:"e-resize",right_top:"ne-resize",left_top:"nw-resize",left_bottom:"sw-resize",right_bottom:"se-resize",default:"default"},mounted=(t,e)=>{const l=e.modifiers,{onmouseup:n,onmousemove:u}=e.value,c=t,y=c.currentStyle||window.getComputedStyle(c,null),b=O=>{const{x:N,y:L,left:G,top:q,width:J,height:fe}=O;let ve="default";return N>G+J-5&&t.scrollTop+L<=q+fe-5&&q+5<=L?ve="right":G+5>N&&t.scrollTop+L<=q+fe-5&&q+5<=L?ve="left":t.scrollTop+L>q+fe-5&&N<=G+J-5&&G+5<=N?ve="bottom":q+5>L&&N<=G+J-5&&G+5<=N?ve="top":N>G+J-5&&t.scrollTop+L>q+fe-5?ve="right_bottom":G+5>N&&t.scrollTop+L>q+fe-5?ve="left_bottom":q+5>L&&N>G+J-5?ve="right_top":q+5>L&&G+5>N&&(ve="left_top"),l?l[ve]?ve:"default":ve},m=O=>{const{left:N,top:L,width:G,height:q,diffX:J,diffY:fe,screenHeight:ve,screenWidth:ne,arr:Ue}=O,De=()=>{G+J>ne-N?c.style.width=ne-N+"px":c.style.width=G+J+"px"},Ve=()=>{G-J>G+N?(c.style.width=G+N+"px",c.style.left=-parseInt(y.marginLeft)+"px"):(c.style.width=G-J+"px",c.style.left=N+J-parseInt(y.marginLeft)+"px")},rt=()=>{q-fe>q+L?(c.style.height=q+L+"px",c.style.top=-parseInt(y.marginTop)+"px"):(c.style.height=q-fe+"px",c.style.top=L+fe-parseInt(y.marginTop)+"px")},Ae=()=>{q+fe>ve-L?c.style.height=ve-L+"px":c.style.height=q-fe+"px"};(Ue[0]=="right"||Ue[1]=="right")&&De(),(Ue[0]=="left"||Ue[1]=="left")&&Ve(),(Ue[0]=="top"||Ue[1]=="top")&&rt(),(Ue[0]=="bottom"||Ue[1]=="bottom")&&Ae()};c.onmousemove=function(O){const N=O.clientX,L=O.clientY,G=c.offsetLeft,q=c.offsetTop,J=c.clientWidth,fe=c.clientHeight;let ve=b({x:N,y:L,left:G,top:q,width:J,height:fe});c.style.cursor=CURSORTYPE[ve]||"default"},c.onmousedown=O=>{const N=O.clientX,L=O.clientY,G=c.clientWidth,q=c.clientHeight,J=c.offsetLeft,fe=c.offsetTop,ve=document.documentElement.clientWidth||document.body.clientWidth,ne=document.documentElement.clientHeight||document.body.clientHeight;let Ue=b({x:N,y:L,left:J,top:fe,width:G,height:q});document.onmousemove=function(De){De.preventDefault();let Ve=De.clientX,rt=De.clientY,Ae=Ve-N,Te=rt-L,Xe;Ue.indexOf("_")==-1?Xe=[Ue,""]:Xe=Ue.split("_"),m({left:J,top:fe,width:G,height:q,diffX:Ae,diffY:Te,screenHeight:ne,screenWidth:ve,arr:Xe}),u&&u()},document.onmouseup=function(){n&&n(),document.onmousemove=null,document.onmouseup=null}}},Draw={mounted},FocusSelect={mounted(t,e){const l=typeof e.value>"u"?!0:unref(e.value),n=(u,c=!0)=>{c?(u.style.background="#fff",u.style.color="#000"):(u.style.background="",u.style.color="")};t.onfocus=()=>{l&&n(t,!0)},t.onblur=()=>{n(t,!1)}},unmounted(t){t.onfocus=null,t.onblur=null}},Draggable={mounted:function(t,e){const l=t;let n=null;const u=l.parentNode;u.style.width="100%",u.style.height="100%",u.style.display="flex",u.style.justifyContent="center",u.style.alignItems="center";const{downEl:c}=e.value||{};typeof c=="string"&&(n=t.querySelector(e.value.downEl)),isRef(c)&&(n=unref(c)),n||(n=t);function y(b){function m(ne,Ue){return typeof window.getComputedStyle<"u"?window.getComputedStyle(ne,null)[Ue]:typeof ne.currentStyle<"u"?ne.currentStyle[Ue]:""}const O=/^matrix3d\((?:[-\d.]+,\s*){12}([-\d.]+),\s*([-\d.]+)(?:,\s*[-\d.]+){2}\)/,N=/^matrix\((?:[-\d.]+,\s*){4}([-\d.]+),\s*([-\d.]+)\)$/;l.className.indexOf("drag_box_translate3d")<0&&(l.className+=" drag_box_translate3d");const L={},G=m(l,"transform"),q=G.match(O)||G.match(N);L.clientX=b.clientX,L.clientY=b.clientY,L.targetX=q[1],L.targetY=q[2],L.distX=L.clientX-L.targetX,L.distY=L.clientY-L.targetY,l.style.position="absolute";const J=b.pageX-l.offsetLeft,fe=b.pageY-l.offsetTop,ve=function(ne){ne.stopPropagation(),ne.preventDefault();let Ue=ne.clientX-L.distX,De=ne.clientY-L.distY;Math.abs(De)>=Math.abs(L.clientY-fe)&&(De>0?De=L.clientY-fe:De=-(L.clientY-fe)),Math.abs(Ue)>=Math.abs(L.clientX-J)&&(Ue>0?Ue=L.clientX-J:Ue=-(L.clientX-J));const Ve=l.style;Ve.transform=Ve.mozTransform=Ve.webkitTransform=`translate3d(${Ue}px, ${De}px, 1px)`};document.onmousemove=ve,document.onmouseup=function(){document.onmousemove=document.onmouseup=null}}n.onmousedown=y}},BoxSelection={mounted(t,e){const l=e.value,n=document.createElement("div");t.style.position="relative";let u=0,c=0;t.onmousedown=y=>{t.onselectstart=()=>!1,n.style.cssText="width: 0; height: 0; border:2px solid#0696D7; opacity: 0.4; position: absolute; display: none;",t.appendChild(n);const b=t.getBoundingClientRect();u=y.clientX-b.left+t.scrollLeft,c=y.clientY-b.top+t.scrollTop,n.style.left=u+"px",n.style.top=c+"px",t.onmousemove=function(O){if(O.buttons==1||O.which==1){n.style.display="block";const N=O.clientX-b.left+t.scrollLeft,L=O.clientY-b.top+t.scrollTop,G=Math.abs(N-u),q=Math.abs(L-c);n.style.width=G+"px",n.style.height=q+"px",N<u&&(n.style.left=u-G+"px"),L<c&&(n.style.top=c-q+"px"),l&&l((J,fe=()=>{})=>{let ve=[];const ne=n.offsetLeft,Ue=n.offsetWidth,De=n.offsetTop,Ve=n.offsetHeight;for(var rt=0;rt<J.length;rt++){var Ae=J[rt].offsetWidth+J[rt].offsetLeft,Te=J[rt].offsetHeight+J[rt].offsetTop;Ae>ne&&Te>De&&J[rt].offsetLeft<ne+Ue&&J[rt].offsetTop<De+Ve&&(m.push(J[rt]),fe&&ve.push(fe(J[rt],rt)))}return{nodes:m,map:ve}})}};let m=[];document.onmouseup=function(O){l&&l((N,L=()=>{})=>{let G=[];const q=n.offsetLeft,J=n.offsetWidth,fe=n.offsetTop,ve=n.offsetHeight;for(var ne=0;ne<N.length;ne++){var Ue=N[ne].offsetWidth+N[ne].offsetLeft,De=N[ne].offsetHeight+N[ne].offsetTop;Ue>q&&De>fe&&N[ne].offsetLeft<q+J&&N[ne].offsetTop<fe+ve&&(m.push(N[ne]),L&&G.push(L(N[ne],ne)))}return{nodes:m,map:G}}),n.style.display="none",t.onselectstart=null},t.ondragstart=()=>!1}},unmounted(t){t.onmousedown=null,t.onmousemove=null,t.ondragstart=null,document.onmouseup=null}},Directives={install(t){t.directive("scroll-bottom",ScrollBottom),t.directive("draw",Draw),t.directive("focus-select",FocusSelect),t.directive("draggable",Draggable),t.directive("box-selection",BoxSelection)}},initConfig=async()=>{await fetchUiConfig(),await fetchServerConfig()};function propsFactory(t,e){return l=>Object.keys(t).reduce((n,u)=>{const y=typeof t[u]=="object"&&t[u]!=null&&!Array.isArray(t[u])?t[u]:{type:t[u]};return l&&u in l?n[u]={...y,default:l[u]}:n[u]=y,n[u].source||(n[u].source=e),n},{})}const IconValue=[String,Function,Object],makeIconProps=propsFactory({icon:{type:IconValue},tag:{type:String,required:!0},fill:{type:String}},"icon"),MxAliSymbolIcon=defineComponent$1({name:"MxAliSymbolIcon",inheritAttrs:!1,props:makeIconProps(),setup(t,{attrs:e}){const{style:l,...n}=e;return l.fill=t.fill,()=>h(t.tag,{style:l,...n},[h("svg",{role:"img","aria-hidden":!0,class:"ali-icon"},[h("use",{"xlink:href":"#"+t.icon})])])}}),getMxAliSymbolIconHTML=t=>`<svg role="img" aria-hidden=true class="ali-icon">
- <use xlink:href="#${t}"/>
- </svg>`,aliases$1={"mdi-weather-night":"mdi-svg:M17.75,4.09L15.22,6.03L16.13,9.09L13.5,7.28L10.87,9.09L11.78,6.03L9.25,4.09L12.44,4L13.5,1L14.56,4L17.75,4.09M21.25,11L19.61,12.25L20.2,14.23L18.5,13.06L16.8,14.23L17.39,12.25L15.75,11L17.81,10.95L18.5,9L19.19,10.95L21.25,11M18.97,15.95C19.8,15.87 20.69,17.05 20.16,17.8C19.84,18.25 19.5,18.67 19.08,19.07C15.17,23 8.84,23 4.94,19.07C1.03,15.17 1.03,8.83 4.94,4.93C5.34,4.53 5.76,4.17 6.21,3.85C6.96,3.32 8.14,4.21 8.06,5.04C7.79,7.9 8.75,10.87 10.95,13.06C13.14,15.26 16.1,16.22 18.97,15.95M17.33,17.97C14.5,17.81 11.7,16.64 9.53,14.5C7.36,12.31 6.2,9.5 6.04,6.68C3.23,9.82 3.34,14.64 6.35,17.66C9.37,20.67 14.19,20.78 17.33,17.97Z","mdi-weather-sunny":"mdi-svg:M12,7A5,5 0 0,1 17,12A5,5 0 0,1 12,17A5,5 0 0,1 7,12A5,5 0 0,1 12,7M12,9A3,3 0 0,0 9,12A3,3 0 0,0 12,15A3,3 0 0,0 15,12A3,3 0 0,0 12,9M12,2L14.39,5.42C13.65,5.15 12.84,5 12,5C11.16,5 10.35,5.15 9.61,5.42L12,2M3.34,7L7.5,6.65C6.9,7.16 6.36,7.78 5.94,8.5C5.5,9.24 5.25,10 5.11,10.79L3.34,7M3.36,17L5.12,13.23C5.26,14 5.53,14.78 5.95,15.5C6.37,16.24 6.91,16.86 7.5,17.37L3.36,17M20.65,7L18.88,10.79C18.74,10 18.47,9.23 18.05,8.5C17.63,7.78 17.1,7.15 16.5,6.64L20.65,7M20.64,17L16.5,17.36C17.09,16.85 17.62,16.22 18.04,15.5C18.46,14.77 18.73,14 18.87,13.21L20.64,17M12,22L9.59,18.56C10.33,18.83 11.14,19 12,19C12.82,19 13.63,18.83 14.37,18.56L12,22Z","mdi-window-minimize":"mdi-svg:M20,14H4V10H20","mdi-window-restore":"mdi-svg:M4,8H8V4H20V16H16V20H4V8M16,8V14H18V6H10V8H16M6,12V18H14V12H6Z","mdi-window-maximize":"mdi-svg:M4,4H20V20H4V4M6,8V18H18V8H6Z","mdi-window-close":"mdi-svg:M13.46,12L19,17.54V19H17.54L12,13.46L6.46,19H5V17.54L10.54,12L5,6.46V5H6.46L12,10.54L17.54,5H19V6.46L13.46,12Z","mdi-plus":"mdi-svg:M19,13H13V19H11V13H5V11H11V5H13V11H19V13Z","mdi-close":"mdi-svg:M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z","mdi-language":"mdi-svg:M12.87,15.07L10.33,12.56L10.36,12.53C12.1,10.59 13.34,8.36 14.07,6H17V4H10V2H8V4H1V6H12.17C11.5,7.92 10.44,9.75 9,11.35C8.07,10.32 7.3,9.19 6.69,8H4.69C5.42,9.63 6.42,11.17 7.67,12.56L2.58,17.58L4,19L9,14L12.11,17.11L12.87,15.07M18.5,10H16.5L12,22H14L15.12,19H19.87L21,22H23L18.5,10M15.88,17L17.5,12.67L19.12,17H15.88Z","mdi-magnify":"mdi-svg:M9.5,3A6.5,6.5 0 0,1 16,9.5C16,11.11 15.41,12.59 14.44,13.73L14.71,14H15.5L20.5,19L19,20.5L14,15.5V14.71L13.73,14.44C12.59,15.41 11.11,16 9.5,16A6.5,6.5 0 0,1 3,9.5A6.5,6.5 0 0,1 9.5,3M9.5,5C7,5 5,7 5,9.5C5,12 7,14 9.5,14C12,14 14,12 14,9.5C14,7 12,5 9.5,5Z"},aliSymbol={component:MxAliSymbolIcon},aliases={collapse:"svg:M7.41,15.41L12,10.83L16.59,15.41L18,14L12,8L6,14L7.41,15.41Z",complete:"svg:M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z",cancel:"svg:M12,2C17.53,2 22,6.47 22,12C22,17.53 17.53,22 12,22C6.47,22 2,17.53 2,12C2,6.47 6.47,2 12,2M15.59,7L12,10.59L8.41,7L7,8.41L10.59,12L7,15.59L8.41,17L12,13.41L15.59,17L17,15.59L13.41,12L17,8.41L15.59,7Z",close:"svg:M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z",delete:"svg:M12,2C17.53,2 22,6.47 22,12C22,17.53 17.53,22 12,22C6.47,22 2,17.53 2,12C2,6.47 6.47,2 12,2M15.59,7L12,10.59L8.41,7L7,8.41L10.59,12L7,15.59L8.41,17L12,13.41L15.59,17L17,15.59L13.41,12L17,8.41L15.59,7Z",clear:"svg:M12,2C17.53,2 22,6.47 22,12C22,17.53 17.53,22 12,22C6.47,22 2,17.53 2,12C2,6.47 6.47,2 12,2M15.59,7L12,10.59L8.41,7L7,8.41L10.59,12L7,15.59L8.41,17L12,13.41L15.59,17L17,15.59L13.41,12L17,8.41L15.59,7Z",success:"svg:M12,2C17.52,2 22,6.48 22,12C22,17.52 17.52,22 12,22C6.48,22 2,17.52 2,12C2,6.48 6.48,2 12,2M11,16.5L18,9.5L16.59,8.09L11,13.67L7.91,10.59L6.5,12L11,16.5Z",info:"svg:M13,9H11V7H13M13,17H11V11H13M12,2C6.48,2 2,6.48 2,12C2,17.52 6.48,22 12,22C17.52,22 22,17.52 22,12C22,6.48 17.52,2 12,2Z",warning:"svg:M13,13H11V7H13M13,17H11V15H13M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2Z",error:"svg:M12,2C17.53,2 22,6.47 22,12C22,17.53 17.53,22 12,22C6.47,22 2,17.53 2,12C2,6.47 6.47,2 12,2M15.59,7L12,10.59L8.41,7L7,8.41L10.59,12L7,15.59L8.41,17L12,13.41L15.59,17L17,15.59L13.41,12L17,8.41L15.59,7Z",prev:"svg:M15.41,16.58L10.83,12L15.41,7.41L14,6L8,12L14,18L15.41,16.58Z",next:"svg:M8.59,16.58L13.17,12L8.59,7.41L10,6L16,12L10,18L8.59,16.58Z",checkboxOn:"svg:M10,17L5,12L6.41,10.58L10,14.17L17.59,6.58L19,8M19,3H5C3.89,3 3,3.89 3,5V19C3,20.1 3.9,21 5,21H19C20.1,21 21,20.1 21,19V5C21,3.89 20.1,3 19,3Z",checkboxOff:"svg:M19,3H5C3.89,3 3,3.89 3,5V19C3,20.1 3.9,21 5,21H19C20.1,21 21,20.1 21,19V5C21,3.89 20.1,3 19,3M19,5V19H5V5H19Z",checkboxIndeterminate:"svg:M17,13H7V11H17M19,3H5C3.89,3 3,3.89 3,5V19C3,20.1 3.9,21 5,21H19C20.1,21 21,20.1 21,19V5C21,3.89 20.1,3 19,3Z",delimiter:"svg:M12,2C6.48,2 2,6.48 2,12C2,17.52 6.48,22 12,22C17.52,22 22,17.52 22,12C22,6.48 17.52,2 12,2Z",sortAsc:"svg:M13,20H11V8L5.5,13.5L4.08,12.08L12,4.16L19.92,12.08L18.5,13.5L13,8V20Z",sortDesc:"svg:M11,4H13V16L18.5,10.5L19.92,11.92L12,19.84L4.08,11.92L5.5,10.5L11,16V4Z",expand:"svg:M7.41,8.58L12,13.17L16.59,8.58L18,10L12,16L6,10L7.41,8.58Z",menu:"svg:M3,6H21V8H3V6M3,11H21V13H3V11M3,16H21V18H3V16Z",subgroup:"svg:M7,10L12,15L17,10H7Z",dropdown:"svg:M7,10L12,15L17,10H7Z",radioOn:"svg:M12,20C7.58,20 4,16.42 4,12C4,7.58 7.58,4 12,4C16.42,4 20,7.58 20,12C20,16.42 16.42,20 12,20M12,2C6.48,2 2,6.48 2,12C2,17.52 6.48,22 12,22C17.52,22 22,17.52 22,12C22,6.48 17.52,2 12,2M12,7C9.24,7 7,9.24 7,12C7,14.76 9.24,17 12,17C14.76,17 17,14.76 17,12C17,9.24 14.76,7 12,7Z",radioOff:"svg:M12,20C7.58,20 4,16.42 4,12C4,7.58 7.58,4 12,4C16.42,4 20,7.58 20,12C20,16.42 16.42,20 12,20M12,2C6.48,2 2,6.48 2,12C2,17.52 6.48,22 12,22C17.52,22 22,17.52 22,12C22,6.48 17.52,2 12,2Z",edit:"svg:M20.71,7.04C21.1,6.65 21.1,6 20.71,5.63L18.37,3.29C18,2.9 17.35,2.9 16.96,3.29L15.12,5.12L18.87,8.87M3,17.25V21H6.75L17.81,9.93L14.06,6.18L3,17.25Z",ratingEmpty:"svg:M12,15.39L8.24,17.66L9.23,13.38L5.91,10.5L10.29,10.13L12,6.09L13.71,10.13L18.09,10.5L14.77,13.38L15.76,17.66M22,9.24L14.81,8.63L12,2L9.19,8.63L2,9.24L7.45,13.97L5.82,21L12,17.27L18.18,21L16.54,13.97L22,9.24Z",ratingFull:"svg:M12,17.27L18.18,21L16.54,13.97L22,9.24L14.81,8.62L12,2L9.19,8.62L2,9.24L7.45,13.97L5.82,21L12,17.27Z",ratingHalf:"svg:M12,15.4V6.1L13.71,10.13L18.09,10.5L14.77,13.39L15.76,17.67M22,9.24L14.81,8.63L12,2L9.19,8.63L2,9.24L7.45,13.97L5.82,21L12,17.27L18.18,21L16.54,13.97L22,9.24Z",loading:"svg:M19,8L15,12H18C18,15.31 15.31,18 12,18C11,18 10.03,17.75 9.2,17.3L7.74,18.76C8.97,19.54 10.43,20 12,20C16.42,20 20,16.42 20,12H23M6,12C6,8.69 8.69,6 12,6C13,6 13.97,6.25 14.8,6.7L16.26,5.24C15.03,4.46 13.57,4 12,4C7.58,4 4,7.58 4,12H1L5,16L9,12",first:"svg:M18.41,16.59L13.82,12L18.41,7.41L17,6L11,12L17,18L18.41,16.59M6,6H8V18H6V6Z",last:"svg:M5.59,7.41L10.18,12L5.59,16.59L7,18L13,12L7,6L5.59,7.41M16,6H18V18H16V6Z",unfold:"svg:M12,18.17L8.83,15L7.42,16.41L12,21L16.59,16.41L15.17,15M12,5.83L15.17,9L16.58,7.59L12,3L7.41,7.59L8.83,9L12,5.83Z",file:"svg:M16.5,6V17.5C16.5,19.71 14.71,21.5 12.5,21.5C10.29,21.5 8.5,19.71 8.5,17.5V5C8.5,3.62 9.62,2.5 11,2.5C12.38,2.5 13.5,3.62 13.5,5V15.5C13.5,16.05 13.05,16.5 12.5,16.5C11.95,16.5 11.5,16.05 11.5,15.5V6H10V15.5C10,16.88 11.12,18 12.5,18C13.88,18 15,16.88 15,15.5V5C15,2.79 13.21,1 11,1C8.79,1 7,2.79 7,5V17.5C7,20.54 9.46,23 12.5,23C15.54,23 18,20.54 18,17.5V6H16.5Z",plus:"svg:M19,13H13V19H11V13H5V11H11V5H13V11H19V13Z",minus:"svg:M19,13H5V11H19V13Z",calendar:"svg:M19,19H5V8H19M16,1V3H8V1H6V3H5C3.89,3 3,3.89 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5C21,3.89 20.1,3 19,3H18V1M17,12H12V17H17V12Z",treeviewCollapse:"svg:M7,10L12,15L17,10H7Z",treeviewExpand:"svg:M10,17L15,12L10,7V17Z",eyeDropper:"svg:M19.35,11.72L17.22,13.85L15.81,12.43L8.1,20.14L3.5,22L2,20.5L3.86,15.9L11.57,8.19L10.15,6.78L12.28,4.65L19.35,11.72M16.76,3C17.93,1.83 19.83,1.83 21,3C22.17,4.17 22.17,6.07 21,7.24L19.08,9.16L14.84,4.92L16.76,3M5.56,17.03L4.5,19.5L6.97,18.44L14.4,11L13,9.6L5.56,17.03Z"},mdi={component:VSvgIcon};let theme;const vuetify={async install(t){try{theme=await getConfig(new URL(""+new URL("../vuetifyThemeConfig.json",import.meta.url).href,import.meta.url).href)}catch{theme={defaultTheme:"dark",themes:{light:{colors:{surface:"#FFFFFF",background:"#E0E0E0",accent:"#545555",prominent:"#FFFFFF",modification:"#FFFFFF",transition:"#EFEFEF",undertint:"#3A4352",depth:"#D3D1D1","on-undertint-bg":"#000","undertint-bg":"#CDCDCD","depth-bg":"#EBE9E9",inverse:"#000000",inverse1:"#FFFFFF"},variables:{"border-color":"#000000","border-opacity":.12,"high-emphasis-opacity":.87,"medium-emphasis-opacity":1,"disabled-opacity":.38,"idle-opacity":.04,"hover-opacity":.2,"focus-opacity":.12,"selected-opacity":.08,"activated-opacity":.1,"pressed-opacity":.12,"dragged-opacity":.08,"theme-kbd":"#212529","theme-on-kbd":"#FFFFFF","theme-code":"#F5F5F5","theme-on-code":"#000000","theme-tbody":"#f3f3f3"}},dark:{colors:{surface:"#212832",background:"#212832",accent:"#545555",prominent:"#3A4352",modification:"#1E252F",transition:"#5D6675",undertint:"#AEABAB","on-undertint":"#fff",depth:"#5D6675","on-depth":"#fff","undertint-bg":"#2E3440","depth-bg":"#454F61",inverse:"#FFFFFF",inverse1:"#000000"},variables:{"border-color":"#FFFFFF","border-opacity":.12,"high-emphasis-opacity":.87,"medium-emphasis-opacity":1,"disabled-opacity":.38,"idle-opacity":.1,"hover-opacity":.2,"focus-opacity":.12,"selected-opacity":.08,"activated-opacity":.1,"pressed-opacity":.16,"dragged-opacity":.08,"theme-kbd":"#212529","theme-on-kbd":"#FFFFFF","theme-code":"#343434","theme-on-code":"#CCCCCC","theme-tbody":"#343b48"}}}}}const e=createVuetify({defaults:{VSelect:{density:"compact",variant:"solo",bgColor:"background",hideDetails:!0,class:"rounded",menuProps:{maxHeight:400},transition:"slide-y-transition"},VCombobox:{density:"compact",variant:"solo",bgColor:"background",hideDetails:!0,menuProps:{maxWidth:"100%"},style:{height:"20px"}},VMenu:{maxHeight:800,transition:"slide-y-transition"},VList:{dense:!0,light:!0,nav:!0},VListItem:{minHeight:"25px",density:"compact",link:!0,rounded:0},VTextField:{density:"compact",variant:"solo",hideDetails:!0,inline:!0},VField:{style:{borderRadius:"2px"},bgColor:"undertint-bg"},VAutocomplete:{density:"compact",variant:"solo",hideDetails:!0,menuProps:{maxWidth:"100%"},style:{height:"20px"}},VTooltip:{},VBtn:{size:"small"},VCheckbox:{density:"compact",hideDetails:!0},VRadioGroup:{inline:!0,hideDetails:!0},VRow:{alignContent:"center",justify:"center",dense:!0},VCol:{cols:12,alignSelf:"center"},VTabs:{density:"compact",hideSlider:!0},VTable:{density:"density",fixedHeader:!0,hover:!0},VAlert:{closable:!0,closeLabel:"关闭",density:"compact"}},icons:{defaultSet:"aliSymbol",aliases:{...aliases,...aliases$1},sets:{aliSymbol,"mdi-svg":mdi}},theme});return t.use(e),e}};window._iconfont_svg_string_4507478='<svg shape-rendering="geometricPrecision"><symbol id="jiantouyinzhu" viewBox="0 0 1024 1024"><path d="M280.94230732 312.86538455c15.57692276 1.29807724 27.25961545-10.38461545 27.25961543-24.66346179v-67.49999999c0-23.36538455 19.47115366-42.83653821 42.83653904-42.83653822h85.67307642c23.36538455 0 42.83653821 19.47115366 42.83653903 42.83653822v385.52884635c0 23.36538455-19.47115366 42.83653821-42.83653903 42.83653819h-44.13461546c-14.27884634 0-25.96153821 10.38461545-28.55769186 23.36538537-1.29807724 15.57692276 10.38461545 29.85576911 25.96153821 29.85576912h225.86538456c14.27884634 0 25.96153821-10.38461545 28.55769268-23.36538456 1.29807724-15.57692276-10.38461545-29.85576911-25.96153902-29.85576993h-44.13461463c-23.36538455 0-42.83653821-19.47115366-42.83653903-42.8365382V220.70192276c0-23.36538455 19.47115366-42.83653821 42.83653903-42.83653821H661.27884634c23.36538455 0 42.83653821 19.47115366 42.83653821 42.83653822v66.20192357c0 12.9807691 9.08653821 24.66346179 22.06730814 25.96153821 15.57692276 1.29807724 27.25961545-10.38461545 27.25961462-24.66346178V172.67307725c0-24.66346179-20.76923089-45.43269268-45.43269186-45.4326927H304.30769268c-25.96153821 0-45.43269268 20.76923089-45.43269268 45.43269269v114.2307691c0 12.9807691 9.08653821 24.66346179 22.06730731 25.96153821z" fill="currentColor" ></path><path d="M906.33846125 779.32307656l-155.0769225-90.09230719c-14.76923062-8.86153875-32.49230813-2.95384594-41.35384688 10.33846125-2.95384594 4.43076938-4.43076938 10.33846125-4.43076843 14.76923063 0 10.33846125 5.90769188 20.67692344 14.76923062 26.58461531l26.58461531 16.24615406c8.86153875 4.43076938 4.43076938 17.72307656-4.43076937 17.7230775l-571.56923063-1.47692343c-16.24615406 0-29.53846125 13.29230812-29.53846125 29.53846125s13.29230812 29.53846125 29.53846125 29.53846218l574.52307657 1.4769225c10.33846125 0 13.29230812 13.29230812 4.43076937 17.7230775l-28.06153875 16.24615313c-11.81538469 7.38461531-19.2 22.15384594-14.76923062 35.44615406 4.43076938 13.29230812 16.24615406 20.67692344 28.06153875 20.67692344 4.43076938 0 10.33846125-1.47692344 14.76923062-4.43076938L906.33846125 829.53846125c10.33846125-5.90769188 16.24615406-17.72307656 14.76923062-29.53846125 1.47692344-7.38461531-5.90769188-14.76923062-14.76923062-20.67692344z" fill="currentColor" ></path></symbol><symbol id="yinchu" viewBox="0 0 1024 1024"><path d="M869.40307925 111.63642267c-1.35506512-17.67476253-2.47446676-29.3401058-3.35820486-34.99602983-5.83267163-0.11783174-10.01569877-0.23566351-12.49016555-0.2356635-6.48074626 0-14.72896878 0.29457937-24.8035834 0.82482225-28.22070418 1.53181276-54.08477335 2.29771913-77.59220753 2.29771914-30.98975031 0-78.71160916-0.94265401-143.28340831-2.88687789-2.00313975 11.19401627-3.770616 25.21599454-5.30242875 42.12485071s-2.35663501 25.98190093-2.35663501 27.21913432c0 4.12411126 2.1209715 6.1861669 6.36291452 6.18616688 2.71013025 0 5.18459701-2.59229851 7.24665264-7.89472727 5.36134464-13.2560719 12.25450203-24.03767705 20.67947216-32.4037313 8.42497013-8.36605427 17.26235139-13.4917354 26.39431205-15.31812755s23.97876117-2.76904613 44.48148573-2.76904612c3.24037312 36.88133781 4.83110176 84.66211254 4.83110174 143.34232415 0 37.17591719-0.64807461 61.27251012-1.94422388 72.40761053-1.29614927 11.13510039-4.77218589 19.20657529-10.36919402 24.33225642-5.59700814 5.12568113-13.90414653 7.65906378-24.98033105 7.65906377-4.71327001 0-7.06990501 2.00313975-7.06990502 6.00941927 0 2.76904613 1.41398101 4.47760652 4.30085891 5.184597 5.83267163 0.29457937 9.72111939 0.41241113 11.54751152 0.41241113l23.50743416-1.06048576c6.48074626-0.29457937 24.74466755-0.41241113 54.85067974-0.41241113l38.64881409 1.06048576 5.24351286 0.2356635c4.24194301 0 6.36291451-1.94422388 6.36291452-5.77375576 0-3.47603662-2.41555087-5.36134464-7.24665264-5.77375576-14.31655765-1.11940163-23.38960242-3.12254139-27.2191343-6.00941927-3.82953187-2.88687789-6.59857803-7.48231614-8.18930665-13.66848302s-3.00470964-24.3911723-4.12411124-54.55610037c-1.11940163-30.16492806-1.6496445-61.50817362-1.64964452-93.91190493 0-31.75565669 1.00156989-58.20888462 3.00470963-79.30076791 22.50586431 0 38.64881408 1.29614927 48.42884936 3.94736362 9.78003527 2.65121438 18.32283716 7.95364315 25.74623741 15.96620218 7.42340027 8.01255901 13.4917354 17.61584667 18.20500541 28.80986293 2.88687789 6.59857803 5.83267163 9.9567829 8.95521303 9.95678288 4.06519538 0 6.127251-2.71013025 6.12725101-8.07147489l-2.94579376-32.93397418z" ></path><path d="M93.7528889 935.1054222l-27.89831112-23.43822221 408.18915555-485.92213334H935.25333333v36.40888889h-444.23395555z" fill="currentColor" ></path></symbol><symbol id="tucengpipei" viewBox="0 0 1024 1024"><path d="M907.5078125 335.99902344L512 116.4921875 116.4921875 335.99902344l395.5078125 219.01245117 395.5078125-219.01245117zM522.87646484 815.05786133l-10.87646484 5.93261719-316.40625-176.00097657-79.1015625 43.01147461L512 907.5078125l66.24755859-36.58447266a220.0012207 220.0012207 0 0 1-55.37109375-55.86547851zM487.77514648 698.87744141a197.75390625 197.75390625 0 0 1 10.38208008-61.79809571L195.59375 468.98852539 116.4921875 512l373.26049805 207.1472168c-0.49438477-6.92138672-1.97753906-13.34838867-1.97753907-20.26977539zM709.75390625 496.67407227a193.30444336 193.30444336 0 1 0 192.81005859 192.81005859 193.30444336 193.30444336 0 0 0-192.81005859-192.81005859z m0 341.12548828a148.31542969 148.31542969 0 1 1 148.31542969-148.31542969 148.31542969 148.31542969 0 0 1-148.31542969 148.31542969z" fill="currentColor" ></path><path d="M686.51782227 710.74267578l-41.52832032-44.00024414-45.48339843 45.48339844 84.53979492 90.47241211 143.86596679-152.76489258-43.01147461-43.50585938-98.38256835 104.31518555z" ></path></symbol><symbol id="dangqiantucengpipei" viewBox="0 0 1033 1024"><path d="M526.3371582 813.57470703l-316.40625-176.00097656-79.1015625 43.01147461 395.5078125 219.50683594 62.29248047-34.6069336a208.63037109 208.63037109 0 0 1-22.24731445-74.15771484zM907.5078125 335.99902344L512 116.4921875 116.4921875 335.99902344l395.5078125 219.01245117zM518.42700195 194.1105957l255.59692383 141.88842774L518.42700195 477.39306641 264.80761719 335.99902344zM854.60864258 639.55126953a71.19140625 71.19140625 0 0 1 0-63.28125 165.12451172 165.12451172 0 0 0-65.75317383-41.03393555 63.28125 63.28125 0 0 1-55.86547852 30.65185547 64.27001953 64.27001953 0 0 1-53.39355468-30.65185547 238.29345703 238.29345703 0 0 0-68.71948242 38.06762696 75.64086914 75.64086914 0 0 1 0 66.24755859 63.28125 63.28125 0 0 1-49.43847657 35.59570313 197.75390625 197.75390625 0 0 0 0 38.06762695 247.19238281 247.19238281 0 0 0 4.94384766 43.01147461 62.29248047 62.29248047 0 0 1 49.43847656 33.1237793 73.16894531 73.16894531 0 0 1 4.94384766 60.80932617 191.3269043 191.3269043 0 0 0 68.71948242 41.03393554 66.24755859 66.24755859 0 0 1 49.43847656-25.70800781 65.25878906 65.25878906 0 0 1 49.43847656 25.70800781 123.10180664 123.10180664 0 0 0 66.2475586-45.9777832 67.73071289 67.73071289 0 0 1 4.94384765-58.33740234 66.24755859 66.24755859 0 0 1 49.43847657-33.1237793 178.96728516 178.96728516 0 0 0 2.47192383-81.07910156 66.24755859 66.24755859 0 0 1-56.85424805-33.1237793z m-53.39355469 104.31518555a77.6184082 77.6184082 0 0 1-70.69702148 45.48339844 75.14648438 75.14648438 0 0 1-76.62963868-76.13525391A77.12402344 77.12402344 0 0 1 786.38354492 660.31542969a78.60717773 78.60717773 0 0 1 14.83154297 83.55102539z" fill="currentColor" ></path></symbol><symbol id="quanpingxianshi" viewBox="0 0 1024 1024"><path d="M192 394.7V192h202.7c17.7 0 32-14.3 32-32s-14.3-32-32-32h-224c-23.6 0-42.7 19.1-42.7 42.7v224c0 17.7 14.3 32 32 32s32-14.4 32-32zM832 629.3V832H629.3c-17.7 0-32 14.3-32 32s14.3 32 32 32h224c23.6 0 42.7-19.1 42.7-42.7v-224c0-17.7-14.3-32-32-32s-32 14.4-32 32z" ></path><path d="M394.7 832H237.3L384 685.3c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 786.8V629.3c0-17.7-14.3-32-32-32s-32 14.3-32 32v224c0 23.6 19.1 42.7 42.7 42.7h224c17.7 0 32-14.3 32-32s-14.4-32-32-32zM853.3 128h-224c-17.7 0-32 14.3-32 32s14.3 32 32 32h157.4L640 338.8c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L832 237.3v157.4c0 17.7 14.3 32 32 32s32-14.3 32-32v-224c0-23.6-19.1-42.7-42.7-42.7z" fill="currentColor" ></path></symbol><symbol id="quanbuxuanze" viewBox="0 0 1024 1024"><path d="M170.666667 179.2v-51.2h51.2v32.494933h-18.705067v18.705067H170.666667z m97.450666 0v-51.2h64.955734v51.2H268.117333z m129.9456 0v-51.2h64.955734v51.2h-64.955734z m129.9456 0v-51.2h64.955734v51.2h-64.955734z m129.911467 0v-51.2h64.989867v51.2h-64.989867z m111.240533-18.705067V128h51.2v51.2h-32.494933v-18.705067h-18.705067z m0 64.955734h51.2v64.955733h-51.2V225.450667zM221.866667 290.4064H170.666667V225.450667h51.2v64.955733z m495.9232-59.835733H375.808V572.5184h153.9072v-204.0832l188.040533 133.973333V230.570667z m67.242666 319.726933l-15.872-11.298133v-53.6576h51.2v64.955733h-35.328z m-67.242666-26.965333l-171.008-121.787734v171.008h171.008v-49.220266z m-188.074667 83.387733h-188.074667V333.141333H273.237333v341.947734h256.477867v-68.4032z m17.066667 68.4032v-68.4032h68.4032v68.4032H546.816z m-17.066667 51.370667h-1.706667v51.2h1.706667v-51.2z m17.066667 51.2v-51.2h46.1824v43.008l-8.3968 8.192H546.816z m111.138133-9.216v9.216h4.983467l-4.983467-9.216z m24.3712 9.216l-24.3712-45.124267v-6.075733h64.989867v51.2h-40.618667z m128.034133 0h10.0352v-51.2h-32.494933v12.5952l22.459733 38.570666z m-38.638933-32.494934l18.909867 32.494934h-21.435734v-32.494934h2.525867z m-2.525867-90.658133v-39.253333h51.2v26.112l-51.2 13.141333z m0 17.6128l51.2-13.141333v21.230933h-51.2v-8.0896z m0-316.757333h51.2v64.955733h-51.2v-64.955733zM221.866667 420.352H170.666667v-64.955733h51.2v64.955733z m0 129.9456H170.666667v-64.955733h51.2v64.955733z m0 129.9456H170.666667v-64.989867h51.2v64.989867z m0 64.955733v32.494934H170.666667v-51.2h32.494933v18.705066H221.866667z m111.2064-18.705066v51.2H268.117333v-51.2h64.955734z m129.9456 0v51.2h-64.955734v-51.2h64.955734z" ></path><path d="M725.469867 665.770667l105.130666 180.701866-84.411733 49.527467-97.5872-180.701867-101.7856 99.191467V401.544533l319.931733 227.908267-141.277866 36.317867z" fill="currentColor" ></path></symbol><symbol id="niantie" viewBox="0 0 1024 1024"><path d="M452.1 426.1h180.8v217.1H452.1z" fill="#A5CEEE" ></path><path d="M632.8 374V202H191.6v441.2H400V374h52.1z" ></path><path d="M632.8 426.1H452.1v388.4h389.1V426.1z" fill="currentColor" ></path></symbol><symbol id="bidui" viewBox="0 0 1024 1024"><path d="M549.51875 174.5a37.51875 37.51875 0 1 0-75.0375 0v675a37.51875 37.51875 0 1 0 75.0375 0V174.5z m-339.58125 37.51875H399.5A37.51875 37.51875 0 1 1 399.5 287H212.01875c-18.7875 0-29.025 0.05625-36.16875 1.0125l-0.28125 0.05625v0.28125c-1.0125 7.14375-1.125 17.4375-1.125 36.16875v374.9625c0 18.73125 0.1125 29.025 1.125 36.16875v0.28125h0.28125c7.14375 1.0125 17.4375 1.06875 36.16875 1.06875H399.5a37.51875 37.51875 0 0 1 0 74.98125H209.9375c-15.8625 0-31.33125 0-44.1-1.6875-14.34375-1.9125-30.76875-6.6375-44.38125-20.25s-18.3375-30.0375-20.25-44.4375a352.74375 352.74375 0 0 1-1.6875-44.04375V322.4375c0-15.8625 0-31.33125 1.6875-44.1 1.9125-14.34375 6.6375-30.76875 20.25-44.38125s30.0375-18.3375 44.4375-20.25c12.7125-1.6875 28.125-1.6875 44.04375-1.6875z m638.2125 75.99375A318.375 318.375 0 0 0 811.98125 287H624.5a37.51875 37.51875 0 0 1 0-74.98125h189.5625c15.8625 0 31.33125 0 44.1 1.6875 14.34375 1.9125 30.76875 6.6375 44.38125 20.25s18.3375 30.0375 20.25 44.4375c1.6875 12.7125 1.6875 28.125 1.6875 44.04375v379.125c0 15.8625 0 31.33125-1.6875 44.1-1.9125 14.34375-6.6375 30.76875-20.25 44.38125s-30.0375 18.3375-44.4375 20.25c-12.7125 1.6875-28.125 1.6875-44.1 1.6875H624.5A37.51875 37.51875 0 0 1 624.5 737h187.48125c18.73125 0 29.025-0.05625 36.16875-1.0125l0.28125-0.05625v-0.28125c1.0125-7.14375 1.06875-17.4375 1.06875-36.16875V324.51875c0-18.73125-0.1125-29.025-1.0125-36.16875l-0.05625-0.28125h-0.28125z" fill="currentColor" ></path></symbol><symbol id="xianzhong" viewBox="0 0 1024 1024"><path d="M64 64h896v25H64zM64 319.3h896v25H64z" fill="currentColor" ></path><path d="M64 76.5h448v120H64zM64 331.8h448v180H64zM64 685.5h896v25H64z" fill="currentColor" ></path><path d="M64 698h448v262H64z" fill="currentColor" ></path></symbol><symbol id="tuzhiku" viewBox="0 0 1024 1024"><path d="M860.16 307.2v550.7072c0 35.2256-28.4672 63.6928-63.6928 63.6928H268.4928C233.2672 921.6 204.8 893.1328 204.8 857.9072V166.0928C204.8 130.8672 233.2672 102.4 268.4928 102.4H655.36l204.8 204.8z" fill="#5971D3" ></path><path d="M655.36 102.4v153.6a51.2 51.2 0 0 0 51.2 51.2H860.16L655.36 102.4z" fill="#8596E0" ></path><path d="M163.84 609.0752m15.5648 0l460.3904 0q15.5648 0 15.5648 15.5648l0 173.6704q0 15.5648-15.5648 15.5648l-460.3904 0q-15.5648 0-15.5648-15.5648l0-173.6704q0-15.5648 15.5648-15.5648Z" fill="#8596E0" ></path><path d="M312.5248 747.1104c4.3008-3.072 7.5776-7.3728 10.0352-12.6976l19.8656 11.4688c-2.8672 7.9872-8.3968 14.7456-16.1792 19.8656s-17.2032 7.7824-28.2624 7.7824-20.2752-2.4576-29.0816-7.7824-15.7696-12.4928-20.8896-21.9136c-5.12-9.4208-7.7824-20.2752-7.7824-32.5632s2.4576-22.9376 7.5776-32.3584c5.12-9.4208 12.0832-16.5888 20.8896-21.7088 8.8064-5.12 18.432-7.7824 29.0816-7.7824s20.2752 2.6624 28.2624 7.7824 13.312 11.8784 16.1792 19.8656l-19.8656 11.4688a31.5392 31.5392 0 0 0-10.0352-12.6976c-4.3008-3.072-9.216-4.5056-14.9504-4.5056-6.144 0-11.6736 1.6384-16.384 4.9152-4.7104 3.2768-8.6016 7.9872-11.4688 13.9264-2.8672 6.144-4.096 13.1072-4.096 21.2992s1.4336 15.1552 4.096 21.2992c2.8672 6.144 6.5536 10.8544 11.4688 14.1312 4.7104 3.2768 10.24 4.9152 16.384 4.9152 5.7344 0 10.8544-1.6384 14.9504-4.5056zM414.1056 651.6736l48.5376 120.0128h-25.1904l-10.4448-27.4432h-46.6944l-10.24 27.4432h-23.7568l47.104-120.0128h20.8896z m5.12 72.2944l-15.9744-42.1888-15.5648 42.1888h31.5392zM516.3008 651.6736c11.6736 0 22.3232 2.4576 31.744 6.9632 9.4208 4.7104 16.9984 11.4688 22.3232 20.48 5.5296 9.0112 8.192 19.6608 8.192 32.1536s-2.6624 23.1424-8.192 32.3584-12.9024 15.9744-22.3232 20.6848c-9.4208 4.7104-20.0704 7.168-31.744 7.168h-39.936v-120.0128h39.936z m-2.8672 99.5328c12.9024 0 22.7328-3.4816 29.696-10.24s10.24-16.7936 10.24-29.4912-3.4816-22.3232-10.4448-29.2864-16.7936-10.4448-29.4912-10.4448h-13.5168v79.4624h13.5168z" fill="currentColor" ></path><path d="M440.32 225.28c1.8432 0 3.4816 0.4096 5.12 1.4336l102.4 58.9824c3.072 1.8432 5.12 5.3248 5.12 8.8064v118.1696c0 3.6864-2.048 7.168-5.12 8.8064l-102.4 58.9824c-1.6384 0.8192-3.2768 1.4336-5.12 1.4336s-3.4816-0.4096-5.12-1.4336l-102.4-58.9824a10.58816 10.58816 0 0 1-5.12-8.8064v-118.1696c0-3.6864 2.048-7.168 5.12-8.8064l102.4-58.9824c1.6384-0.8192 3.2768-1.4336 5.12-1.4336m0-20.48c-5.3248 0-10.6496 1.4336-15.36 4.096l-102.4 58.9824c-9.4208 5.5296-15.36 15.5648-15.36 26.624v118.1696c0 11.0592 5.9392 21.0944 15.36 26.624l102.4 58.9824c4.7104 2.6624 10.0352 4.096 15.36 4.096s10.6496-1.4336 15.36-4.096l102.4-58.9824c9.4208-5.5296 15.36-15.5648 15.36-26.624v-118.1696c0-11.0592-5.9392-21.0944-15.36-26.624l-102.4-58.9824c-4.7104-2.6624-10.0352-4.096-15.36-4.096z" fill="currentColor" ></path><path d="M430.08 220.5696m10.24 0l0 0q10.24 0 10.24 10.24l0 61.44q0 10.24-10.24 10.24l0 0q-10.24 0-10.24-10.24l0-61.44q0-10.24 10.24-10.24Z" fill="currentColor" ></path><path d="M440.32 343.4496c-5.7344 0-10.24 4.5056-10.24 10.24v122.88c0 5.7344 4.5056 10.24 10.24 10.24s10.24-4.5056 10.24-10.24v-122.88c0-5.7344-4.5056-10.24-10.24-10.24z" fill="currentColor" ></path><path d="M319.911735 412.042347m8.8681-5.12l46.114121-26.624q8.8681-5.12 13.9881 3.748101l0 0q5.12 8.8681-3.7481 13.9881l-46.114121 26.624q-8.8681 5.12-13.9881-3.7481l0 0q-5.12-8.8681 3.7481-13.988101Z" fill="currentColor" ></path><path d="M491.39151 392.932284m5.12-8.8681l0 0q5.12-8.8681 13.9881-3.7481l46.114121 26.624q8.8681 5.12 3.7481 13.9881l0 0q-5.12 8.8681-13.9881 3.7481l-46.114121-26.624q-8.8681-5.12-3.7481-13.9881Z" fill="currentColor" ></path><path d="M334.0288 281.1904c-3.4816 0-6.9632 1.8432-8.8064 5.12-2.8672 4.9152-1.2288 11.0592 3.6864 13.9264l109.9776 63.488a10.1376 10.1376 0 0 0 13.9264-3.6864c2.8672-4.9152 1.2288-11.0592-3.6864-13.9264l-109.9776-63.488a9.23648 9.23648 0 0 0-5.12-1.4336z" fill="currentColor" ></path><path d="M553.984 281.1904c-1.6384 0-3.4816 0.4096-5.12 1.4336l-109.9776 63.488c-4.9152 2.8672-6.5536 9.0112-3.6864 13.9264a10.1376 10.1376 0 0 0 13.9264 3.6864l109.9776-63.488c4.9152-2.8672 6.5536-9.0112 3.6864-13.9264a10.1376 10.1376 0 0 0-8.8064-5.12z" fill="currentColor" ></path></symbol><symbol id="banjingbiaozhu" viewBox="0 0 1024 1024"><path d="M512 960c-60.5 0-119.1-11.8-174.4-35.2-53.3-22.6-101.3-54.9-142.4-96s-73.4-89-96-142.4C75.8 631.1 64 572.5 64 512s11.8-119.1 35.2-174.4c22.6-53.3 54.9-101.3 96-142.4s89-73.4 142.4-96C392.9 75.8 451.5 64 512 64s119.1 11.8 174.4 35.2c53.3 22.6 101.3 54.9 142.4 96s73.4 89 96 142.4C948.2 392.9 960 451.5 960 512s-11.8 119.1-35.2 174.4c-22.6 53.3-54.9 101.3-96 142.4s-89 73.4-142.4 96C631.1 948.2 572.5 960 512 960z m0-866C281.5 94 94 281.5 94 512s187.5 418 418 418 418-187.5 418-418S742.5 94 512 94z" fill="currentColor" ></path><path d="M512.5 522.7c-3.8 0-7.7-1.5-10.6-4.4L310.2 326.6c-5.9-5.9-5.9-15.4 0-21.2 5.9-5.9 15.4-5.9 21.2 0l191.7 191.7c5.9 5.9 5.9 15.4 0 21.2-2.9 3-6.8 4.4-10.6 4.4z" ></path><path d="M265 389.1l128.9-128.9-128.9 0.1z" ></path></symbol><symbol id="zhijingbiaozhu" viewBox="0 0 1024 1024"><path d="M512 960c-60.5 0-119.1-11.8-174.4-35.2-53.3-22.6-101.3-54.9-142.4-96s-73.4-89-96-142.4C75.8 631.1 64 572.5 64 512s11.8-119.1 35.2-174.4c22.6-53.3 54.9-101.3 96-142.4s89-73.4 142.4-96C392.9 75.8 451.5 64 512 64s119.1 11.8 174.4 35.2c53.3 22.6 101.3 54.9 142.4 96s73.4 89 96 142.4C948.2 392.9 960 451.5 960 512s-11.8 119.1-35.2 174.4c-22.6 53.3-54.9 101.3-96 142.4s-89 73.4-142.4 96C631.1 948.2 572.5 960 512 960z m0-866C281.5 94 94 281.5 94 512s187.5 418 418 418 418-187.5 418-418S742.5 94 512 94z" fill="currentColor" ></path><path d="M703.7 718.7c-3.8 0-7.7-1.5-10.6-4.4L309.7 330.9c-5.9-5.9-5.9-15.4 0-21.2 5.9-5.9 15.4-5.9 21.2 0l383.4 383.4c5.9 5.9 5.9 15.4 0 21.2-2.9 2.9-6.7 4.4-10.6 4.4z" ></path><path d="M630.6 759.5l128.9-128.9v128.9zM264.5 393.4l128.9-128.9H264.5z" ></path></symbol><symbol id="lashenshezhi" viewBox="0 0 1024 1024"><path d="M96 352m64 0l704 0q64 0 64 64l0 160q0 64-64 64l-704 0q-64 0-64-64l0-160q0-64 64-64Z" fill="currentColor" ></path><path d="M128 352h768a32 32 0 0 1 32 32v224a32 32 0 0 1-32 32H128a32 32 0 0 1-32-32v-224a32 32 0 0 1 32-32z m0 32v224h768v-224H128z" fill="#808FA1" ></path><path d="M528 133.12V272.064a16 16 0 1 1-32 0V133.696l-51.072 52.544a16 16 0 0 1-22.944-22.304L511.904 71.424l91.616 92.416a16 16 0 0 1-22.72 22.528L528 133.12z m0 725.856l52.8-53.248a16 16 0 0 1 22.72 22.528l-91.648 92.416-89.92-92.512a16 16 0 0 1 22.976-22.304l51.072 52.544v-138.4a16 16 0 1 1 32 0v138.976z" fill="#57B8FF" ></path></symbol><symbol id="a-17xianxingfuben" viewBox="0 0 1024 1024"><path d="M732.586667 533.333333H307.626667a21.333333 21.333333 0 1 1 0-42.666666h424.96a21.333333 21.333333 0 0 1 0 42.666666z" fill="#57B8FF" ></path><path d="M321.493333 407.253333v207.36l-103.466666-103.68 103.466666-103.68zM718.72 407.253333v207.36l103.68-103.68-103.68-103.68z" fill="#57B8FF" ></path><path d="M157.866667 853.333333a21.333333 21.333333 0 0 1-21.333334-21.333333V192a21.333333 21.333333 0 0 1 42.666667 0v640a21.333333 21.333333 0 0 1-21.333333 21.333333zM883.2 853.333333a21.333333 21.333333 0 0 1-21.333333-21.333333V192a21.333333 21.333333 0 0 1 42.666666 0v640a21.333333 21.333333 0 0 1-21.333333 21.333333z" fill="currentColor" ></path></symbol><symbol id="dayin" viewBox="0 0 1024 1024"><path d="M723.63650672 682.90045731h-29.21538544v-25.46003089h29.21538544c26.54208219 0 48.0558083-20.17707447 48.05580829-45.00060459V410.28717661c0-24.82353011-21.57737618-45.00060459-48.05580829-45.00060458h-423.27301345c-26.54208219 0-48.0558083 20.17707447-48.05580828 45.00060458v202.08899516c0 24.82353011 21.57737618 45.00060459 48.05580828 45.00060457h29.21538545v25.4600309h-29.21538545C259.8183941 682.90045731 226.8476541 651.26636893 226.8476541 612.43982183V410.28717661c0-38.89019718 32.97073999-70.46063547 73.51583918-70.46063547h423.20936336c40.54509919 0 73.51583918 31.63408838 73.51583918 70.46063547v202.08899516c0.06365008 38.89019718-32.90708992 70.52428554-73.4521891 70.52428553z" fill="currentColor" ></path><path d="M639.30015442 252.30768499c21.06817557 0 38.19004631 17.12187077 38.19004633 38.19004632v46.52820645H346.50979925V290.49773131c0-21.06817557 17.12187077-38.19004631 38.19004633-38.19004632h254.60030883m1e-8-25.46003089H384.69984558c-35.13484262 0-63.65007721 28.51523459-63.6500772 63.65007721v71.98823733h381.90046324V290.49773131c0-35.13484262-28.51523459-63.65007721-63.6500772-63.65007721zM639.30015442 536.82353011c21.06817557 0 38.19004631 17.12187077 38.19004633 38.19004632v159.12519302c0 21.06817557-17.12187077 38.19004631-38.19004633 38.19004633H384.69984558c-21.06817557 0-38.19004631-17.12187077-38.19004633-38.19004633V575.01357643c0-21.06817557 17.12187077-38.19004631 38.19004633-38.19004632h254.60030883m1e-8-25.46003089H384.69984558c-35.13484262 0-63.65007721 28.51523459-63.6500772 63.65007721v159.12519302c0 35.13484262 28.51523459 63.65007721 63.6500772 63.65007721h254.60030884c35.13484262 0 63.65007721-28.51523459 63.6500772-63.65007721V575.01357643c0-35.13484262-28.51523459-63.65007721-63.6500772-63.65007721zM715.68024706 443.25791661H552.7360494c-7.0015085 0-12.73001544-5.72850695-12.73001543-12.73001543s5.72850695-12.73001544 12.73001543-12.73001545h162.94419766c7.0015085 0 12.73001544 5.72850695 12.73001546 12.73001545s-5.72850695 12.73001544-12.73001546 12.73001543z" fill="currentColor" ></path></symbol><symbol id="jiesuo1" viewBox="0 0 1055 1024"><path d="M374.55451349 243.47623678C300.33283245 243.47623678 239.95572897 303.85334027 239.95572897 378.0750213l0 94.63149207 54.73330668 0 0-94.63149207c0-44.03312982 35.83234801-79.86547784 79.86547784-79.86547782s79.86547784 35.82082981 79.86547784 79.86547782l0 94.63149207 54.74482491 0 0-94.63149207C509.16481623 303.85334027 448.77619507 243.47623678 374.55451349 243.47623678z" fill="currentColor" ></path><path d="M749.52143422 488.65887659L435.91064257 488.65887659c-23.83064222 0-43.15776545 19.31560501-43.15776544 43.14624723l0 205.56088552c0 23.84216044 19.31560501 43.15776545 43.15776544 43.15776543l313.61079111 0c23.81912455 0 43.13472954-19.31560501 43.13472958-43.15776543L792.65616325 531.79360615C792.65616325 507.9744816 773.35207644 488.65887659 749.52143422 488.65887659zM679.67657409 653.51532049l-42.7546368 1e-8c-7.3484533 17.15023043-24.36046793 29.16345389-44.20589917 29.16345389s-36.85744586-12.01322345-44.21741683-29.16345389l-42.7546368 0 0-37.85950733 42.7546368 0c7.35997098-17.13871223 24.37198613-29.15193622 44.21741683-29.15193621s36.85744586 12.01322345 44.20589917 29.15193621l42.7546368 0L679.67657409 653.51532049z" fill="currentColor" ></path></symbol><symbol id="yanjing1" viewBox="0 0 1764 1024"><path d="M810.3174103 734.08587615C804.96157574 734.08587615 799.48214404 733.05590804 794.20870709 730.78997779 709.71011026 694.90588371 655.03939531 612.17883284 655.03939531 520.09967073 655.03939531 393.94915788 757.33584297 291.32312044 883.07436847 291.32312044 1008.77169513 291.32312044 1111.02694399 393.94915788 1111.02694399 520.09967073 1111.02694399 610.77807617 1058.99294715 693.29913298 978.40823086 730.2955935 957.6852695 739.8125 933.21322359 730.74877897 923.73751519 710.06701644 914.2618075 689.42645271 923.32552779 664.95440682 944.00729108 655.43750032 995.42330646 631.83062727 1028.62948288 578.72546354 1028.62948288 520.09967073 1028.62948288 439.39135726 963.32949502 373.72058082 883.07436847 373.72058082 802.77804237 373.72058082 737.43685641 439.39135726 737.43685641 520.09967073 737.43685641 579.05505403 772.37337927 631.99542253 826.46731304 654.98431412 847.39626772 663.88323991 857.16036708 688.06689486 848.26144131 708.99584953 841.58724696 724.65136726 826.34371661 734.08587615 810.3174103 734.08587615" fill="currentColor" ></path><path d="M883.70058908 874.66006454C623.77779855 874.66006454 404.47695595 695.93997177 296.86587253 589.40005526 274.70095497 567.44113175 262.46493203 538.51962295 262.46493203 507.95016463 262.46493203 477.33950822 274.70095497 448.41799946 296.86587253 426.45907593 404.47695595 319.91915869 623.77779855 141.19906592 883.70058908 141.19906592 1143.62337962 141.19906592 1362.92422222 319.91915869 1470.49410682 426.45907593 1492.65902439 448.41799946 1504.89504732 477.33950822 1504.89504732 507.95016463 1504.89504732 538.51962295 1492.65902439 567.44113175 1470.49410682 589.40005526 1450.47152382 609.25784302 1432.75606987 626.43771386 1402.68099654 651.73373381 1385.25393357 666.35928345 1359.25753455 664.134552 1344.63198566 646.70748901 1330.00643602 629.28042602 1332.23116747 603.28402702 1349.65823046 588.65847811 1377.42617471 565.29879793 1393.20528888 549.97286996 1412.52749353 530.85665861 1418.95449502 524.47085595 1422.49758625 516.35470614 1422.49758625 507.95016463 1422.49758625 499.54562386 1418.95449502 491.38827522 1412.52749353 485.04367065 1333.13753985 406.43649292 1122.73562304 223.59652701 883.70058908 223.59652701 644.66555513 223.59652701 434.2224395 406.43649292 354.87368463 485.04367065 348.44668316 491.38827522 344.86239311 499.54562386 344.86239311 507.95016463 344.86239311 516.35470614 348.44668316 524.47085595 354.87368463 530.81546053 434.2224395 609.46383634 644.66555513 792.26260345 883.70058908 792.26260345 1006.67879929 792.26260345 1114.24868462 756.46090698 1232.44784217 676.2057797 1251.31686139 663.35177605 1276.94247109 668.29562393 1289.67287903 687.12344361 1302.48568463 705.95126327 1297.58303555 731.53567489 1278.75521588 744.34848046 1147.86684918 833.25534066 1022.29311822 874.66006454 883.70058908 874.66006454" fill="currentColor" ></path></symbol><symbol id="gou" viewBox="0 0 1397 1024"><path d="M1396.363636 121.018182c0 0-223.418182 74.472727-484.072727 372.363636-242.036364 269.963636-297.890909 381.672727-390.981818 530.618182C512 1014.690909 372.363636 744.727273 0 549.236364l195.490909-186.181818c0 0 176.872727 121.018182 297.890909 344.436364 0 0 307.2-474.763636 902.981818-707.490909L1396.363636 121.018182 1396.363636 121.018182zM1396.363636 121.018182" fill="currentColor" ></path></symbol><symbol id="yanjing" viewBox="0 0 1024 1024"><path d="M512 334.37167391c-14.48135344 0-28.38592497 1.0299681-41.73431364 2.98690763-16.89147917 2.43072477-32.62939453-8.7547303-35.1631167-25.00762971-2.55432121-16.2528994 9.06372103-31.41403214 25.9552002-33.84475692 16.37649513-2.38952669 33.37097168-3.64608788 50.94223014-3.64608716 127.01568571 0 219.69223023 65.91796858 279.03900114 128.74603215a551.15661653 551.15661653 0 0 1 83.18023707 115.27404776c1.85394287 3.52249146 3.66668693 7.06558195 5.41763312 10.64987199l0.30899072 0.6797793 0.12359572 0.24719213v0.06179859l0.02059977 0.02059904-28.22113046 12.11242652 28.26232926 12.11242724-0.06179857 0.08239689-0.06179784 0.16479525-0.24719216 0.53558382a452.15606722 452.15606722 0 0 1-16.37649584 30.15747021 557.91320777 557.91320777 0 0 1-49.12948608 69.68765292 31.72302214 31.72302214 0 0 1-43.15567008 4.44946289 29.02450545 29.02450545 0 0 1-5.21163909-41.48712151 497.14508041 497.14508041 0 0 0 51.53961182-75.70266771 491.70684822 491.70684822 0 0 0-72.09777865-98.97994956C692.2856447 387.47683692 614.9556272 334.37167391 512 334.37167391z m339.88952613 208.28018132l28.22113045 12.11242724a28.83911116 28.83911116 0 0 0 0-24.22485376l-28.22113045 12.11242652zM276.61105323 401.62860132c6.07681267 5.31463647 9.68170174 12.73040796 10.07309007 20.59936491 0.37078857 7.88955671-2.5131224 15.59371915-8.03375291 21.42333969a491.8510437 491.8510437 0 0 0-72.09777793 99.00054931 491.99523918 491.99523918 0 0 0 72.09777793 99.00054931C331.75555412 697.80627449 409.0443728 750.93203727 512 750.93203727a285.91918953 285.91918953 0 0 0 97.33200073-16.82968131c15.86151106-5.35583529 33.24737525 2.5131224 39.13879362 17.67425513 5.87081933 15.16113274-1.89514167 32.05261263-17.50945988 38.04702766A349.92141741 349.92141741 0 0 1 512 810.44360345c-127.01568571 0-219.69223023-65.91796858-279.03900114-128.74603289a551.05361915 551.05361915 0 0 1-83.18023707-115.27404778c-1.85394287-3.50189242-3.66668693-7.06558195-5.41763312-10.64987199l-0.30899072-0.67977856-0.12359572-0.24719287-0.02059977-0.04119808v-0.04119881l28.22113046-12.11242724L143.84814461 530.53942873l0.04119882-0.02059906 0.02059904-0.06179858 0.10299664-0.24719214 0.30899074-0.67977929 1.17416357-2.30712908c6.38580339-12.64801033 13.38958748-25.00762972 20.8877566-37.05825765a552.92816178 552.92816178 0 0 1 66.53595002-86.55853303 31.39343238 31.39343238 0 0 1 21.42333969-9.68170175c8.17794767-0.39138761 16.19110084 2.38952669 22.24731445 7.70416317zM172.11047387 542.65185523L143.88934343 530.53942873a28.83911116 28.83911116 0 0 0 0 24.22485374l28.22113044-12.11242724z" fill="currentColor" ></path><path d="M481.45114144 405.21289062c0-16.50009156 13.76037606-29.88967903 30.73425285-29.88967903 92.77954118 0 166.01028459 75.59967033 166.01028458 166.5046696 0 10.67047103-5.87081933 20.53756706-15.3671268 25.8934016a31.51702881 31.51702881 0 0 1-30.75485189 0 29.74548356 29.74548356 0 0 1-15.36712678-25.8934016c0-60.04714999-47.89352393-106.72531151-104.52117911-106.72531153-16.97387678 0-30.73425285-13.38958748-30.73425285-29.88967904z m-94.81887833 77.49481201c16.60308821 3.48129264 27.14996355 19.36340347 23.58627327 35.51330551a109.3826294 109.3826294 0 0 0-2.55432121 23.60687305c0 60.04714999 47.89352393 106.72531151 104.52117912 106.72531079 8.11614983 0 15.9851075-0.92697143 23.52447542-2.67791765 16.47949252-3.89328003 33.10317977 5.973816 37.07885742 22.02072209 4.01687646 16.04690535-6.13861052 32.1968081-22.6387028 36.06948836a165.88668816 165.88668816 0 0 1-37.96463004 4.32586646c-92.77954118 0-166.01028459-75.59967033-166.01028458-166.50466887 0-12.35961937 1.35955787-24.51324471 3.93447884-36.15188599 1.70974739-7.74536125 6.52999886-14.52255225 13.38958747-18.82782039 6.83898958-4.32586646 15.16113274-5.78842171 23.13308709-4.1198724v0.02059904zM213.78298966 221.81674186a31.37283333 31.37283333 0 0 1 43.46466081 0L810.58779891 759.81036401c11.65924103 11.74163795 11.4944458 30.38406405-0.37078858 41.89910888a31.37283333 31.37283333 0 0 1-43.09387223 0.37078858L213.78298966 264.08663933a29.31289641 29.31289641 0 0 1 0-42.26989747z" fill="currentColor" ></path></symbol><symbol id="cha" viewBox="0 0 1024 1024"><path d="M168.38 208.632l42.426-42.426 633.561 633.561-42.426 42.426z" fill="currentColor" ></path><path d="M168.38 799.775L801.94 166.214l42.426 42.426L210.806 842.2z" fill="currentColor" ></path></symbol><symbol id="budayinbiaoqian" viewBox="0 0 1024 1024"><path d="M281.78700628 377.76113871L443.15607649 539.15736648 376.21316883 539.15736648v190.10156352h145.07465044c7.14238713 20.25939503 18.19543561 38.67208938 32.23579356 54.31473297H321.89843586v-135.7868318H240.42633703V430.52790117a54.31473234 54.31473234 0 0 1 41.36066925-52.76676246z m4.99695498-129.37769294l488.83259296 488.83259297-19.22741531 19.17310017L756.41629648 783.57366297l-17.70660301-9.50507862-1.49365473 1.54796987-488.83259297-488.83259296 38.40051549-38.40051549zM593.47209883 689.47338882l61.34849041 61.37564736L593.47209883 783.57366297v-94.10027415zM662.28886477 566.31473234L756.41629648 566.31473234v94.10027414L662.28886477 566.31473234z m-190.1287211-190.10156351L729.25893 376.21316883a54.31473234 54.31473234 0 0 1 54.31473297 54.31473234v122.99571166A162.34673539 162.34673539 0 0 0 674.94419766 512c-19.96066421 0-39.10660744 3.58477236-56.75889531 10.15685478L472.1329861 376.21316883zM702.10156414 430.52790117a27.15736648 27.15736648 0 1 0 0 54.31473235 27.15736648 27.15736648 0 0 0 0-54.31473235z m0-190.10156414v108.62946531H445.00277719l-108.62946469-108.62946531H702.10156414z" fill="currentColor" ></path></symbol><symbol id="ziyuan" viewBox="0 0 1024 1024"><path d="M770.30775499 535.50654286h65.59120971a25.18233922 25.18233922 0 1 0 0-49.77904322h-66.76248156l83.74591991-83.74591991a24.596704 24.596704 0 0 0-35.13814784-35.13814857l-117.12716072 117.12716071H555.37941492L625.65571135 360.9870733 789.63373635 317.65002387a25.18233922 25.18233922 0 0 0 17.56907427-31.0386978 24.596704 24.596704 0 0 0-30.45306184-17.56907428l-114.19898179 30.45306187 33.38124079-58.56358a25.18233922 25.18233922 0 0 0-43.92268536-25.18233993l-32.79560486 58.5635807L588.17501978 161.28526452a24.596704 24.596704 0 0 0-48.02213543 12.88398756l43.33704943 162.22111721-71.44756829 124.15479043-72.03320422-124.74042636 43.33705015-162.2211172a25.76797515 25.76797515 0 0 0-17.56907428-31.62433373 25.18233922 25.18233922 0 0 0-30.45306186 18.15471023l-31.03869779 117.12716072-32.79560486-58.56358073a24.596704 24.596704 0 0 0-33.96687671-8.78453678 24.01106807 24.01106807 0 0 0-9.37017271 33.96687672l33.38124079 58.56357999-114.19898179-32.79560485a25.18233922 25.18233922 0 0 0-12.88398757 48.02213615l162.22111721 43.33704942 72.03320421 124.74042634H327.56708728l-117.12716071-117.1271607a24.596704 24.596704 0 0 0-35.13814785 0 24.596704 24.596704 0 0 0 0 35.13814785l81.98901212 81.98901285H182.32940771a25.18233922 25.18233922 0 1 0 0 49.77904322h73.79011128L172.95923499 619.25246279a25.18233922 25.18233922 0 0 0 0 35.72378379 24.596704 24.596704 0 0 0 17.5690743 7.02762972 24.596704 24.596704 0 0 0 17.56907428-7.02762972l117.12716072-117.12716071h143.48077177l-70.27629642 120.05533963-162.80675314 43.33704943a24.596704 24.596704 0 1 0 12.88398756 48.02213615l114.19898179-30.45306185L325.22454428 786.15866672a25.18233922 25.18233922 0 0 0 21.66852436 37.48069157 25.76797515 25.76797515 0 0 0 21.66852507-12.29835236l37.48069157-64.41993784 30.45306186 117.12716071a25.18233922 25.18233922 0 0 0 24.01106734 18.74034542h6.44199379a24.596704 24.596704 0 0 0 17.56907429-30.45306185l-43.33704943-169.24874693 70.86193236-122.39788336 70.27629643 121.81224743L538.9816125 844.72224672a24.596704 24.596704 0 0 0 17.56907427 30.45306185h6.44199379a25.18233922 25.18233922 0 0 0 24.01106807-18.74034543l30.45306114-117.12716071 37.48069157 65.00557379a26.35361107 26.35361107 0 0 0 21.66852508 12.29835235 25.18233922 25.18233922 0 0 0 12.88398756-3.51381485 24.596704 24.596704 0 0 0 8.78453679-26.939247l-36.89505564-64.41993857 117.12716071 31.03869778a25.18233922 25.18233922 0 0 0 12.88398758-48.60777207L625.65571135 658.49006143l-70.27629642-122.98351857h144.0664077l117.12716071 117.12716072a25.18233922 25.18233922 0 0 0 35.13814785 0 25.18233922 25.18233922 0 0 0 0-35.7237845z" fill="currentColor" ></path></symbol><symbol id="cloudshellyunminglinghang" viewBox="0 0 1024 1024"><path d="M917.504 835.584H106.496V188.416h810.496l0.512 647.168zM186.88 755.2h650.752v-486.4H186.88v486.4z" fill="currentColor" ></path><path d="M343.04 648.704l-56.32-56.32 88.064-88.064L286.72 415.744l56.32-56.832 144.896 144.896L343.04 648.704z m163.84-63.488h230.4v79.872H506.88v-79.872z" fill="currentColor" ></path></symbol><symbol id="suo" viewBox="0 0 1024 1024"><path d="M699.63238224 436.42830294L324.36048895 436.42830294c-32.41326715 0-58.68649143 26.21904532-58.68649143 58.57029185l0 248.4525261c0 32.35195941 26.27322427 58.57029185 58.68649143 58.57029184l375.27260617 0c32.41398004 0 58.69433313-26.21833245 58.69433312-58.57029184L758.32742824 494.99859479C758.32671536 462.64734826 732.04636228 436.42830294 699.63238224 436.42830294zM536.71272806 617.54424119l0 65.21362864c0 13.64453976-11.05749509 24.71771823-24.71629246 24.71771822-13.65095568 0-24.71629247-11.07317848-24.71629246-24.71771822l0-65.21362863c-14.75877254-8.54886733-24.71700533-24.4838933-24.71700536-42.77356477 0-27.30333712 22.12996069-49.43401068 49.43329782-49.43401068s49.4411395 22.13067357 49.44113949 49.43401068C561.43757509 593.0603479 551.48718397 608.99537387 536.71272806 617.54424119zM511.9964356 201.58894983c-95.55954127 0-173.03186925 76.38019449-173.03186926 176.73314671l1e-8 76.75231829 346.07229306 16.47752832L685.03685941 378.32209654C685.03685941 277.96914432 607.56453145 201.58894983 511.9964356 201.58894983zM388.42851802 450.73796054L388.42851802 376.60334078c0-68.23410486 55.32525815-123.56791757 123.56720469-123.56791759 68.24978823 0 123.56791757 55.33381272 123.56791758 123.56791759l0 75.8690589L388.42851802 450.73796054z" fill="currentColor" ></path></symbol><symbol id="taiyang" viewBox="0 0 1024 1024"><path d="M507.47829852 315.02083306c-6.7282375 0-12.17328942-5.45863062-12.17328944-12.18686812V229.73312427c0-6.7282375 5.44505195-12.18007878 12.17328945-12.18007877 6.74181618 0 12.18686812 5.45184128 12.1868681 12.18007877v73.10084067c0 6.7282375-5.44505195 12.18686812-12.1868681 12.18686812zM507.47829852 802.35977088s0.01357868 0 1e-8 0c-6.70786947 0-12.17328942-5.45184128-12.17328946-12.18007877V717.07885143c0-6.7282375 5.45863062-12.18686812 12.18686812-12.18686811s12.17328942 5.45863062 12.17328944 12.1868681v73.10084069c0 6.7282375-5.44505195 12.18007878-12.18686811 12.18007877z" fill="currentColor" ></path><path d="M369.64108599 372.11240631c-4.76611778 4.75932844-12.47202046 4.75932844-17.22455956 0l-51.70083606-51.6940467c-4.74574975-4.7525391-4.74574975-12.46523112 0-17.22455956 4.76611778-4.76611778 12.47202046-4.76611778 17.23813825 0l51.68725737 51.68725736c4.76611778 4.75932844 4.76611778 12.47880982 0 17.2313489zM714.25448534 716.71222699c-4.76611778 4.76611778-12.47880982 4.76611778-17.23813825 0l-51.68725736-51.68725737c-4.76611778-4.75932844-4.76611778-12.47880982 1e-8-17.2313489 4.76611778-4.75932844 12.47202046-4.75932844 17.23813823 0l51.68725737 51.69404671c4.74574975 4.7525391 4.74574975 12.46523112-1e-8 17.22455956z" fill="currentColor" ></path><path d="M312.54951273 509.95640818c0 6.7282375-5.45863062 12.18007878-12.18686811 12.18007878H227.26180393c-6.7282375 0-12.17328942-5.45184128-12.18686811-12.18007878 0-6.7282375 5.45863062-12.18007878 12.18686811-12.18007877h73.10084069c6.7282375 0 12.18686812 5.44505195 12.18686811 12.18007877zM799.8816612 509.95640818c0 6.7282375-5.44505195 12.18007878-12.17328943 12.18007878H714.6075311c-6.7282375 0-12.18686812-5.45184128-12.18686812-12.18007878 0-6.7282375 5.45863062-12.18007878 12.18686812-12.18007877h73.10084067c6.7282375 0 12.17328942 5.44505195 12.17328943 12.18007877z" fill="currentColor" ></path><path d="M369.64108599 647.79362072c4.76611778 4.7525391 4.76611778 12.47202046 0 17.2313489l-51.68725737 51.68725737c-4.76611778 4.76611778-12.47202046 4.76611778-17.23813825 0-4.74574975-4.75932844-4.74574975-12.46523112 0-17.22455956l51.70083606-51.69404671c4.7525391-4.75932844 12.46523112-4.75932844 17.22455956 0zM714.25448534 303.1870107c0 0.00678934 0 0-1e-8 0 4.74574975 4.76611778 4.74574975 12.47880982 0 17.23134891l-51.70083603 51.6940467c-4.74574975 4.75932844-12.45844178 4.75932844-17.22455957 0-4.76611778-4.7525391-4.76611778-12.47202046 0-17.23134891l51.68725736-51.6940467c4.75932844-4.7525391 12.47202046-4.7525391 17.23813824 0z" fill="currentColor" ></path><path d="M507.47829852 668.33816831c-87.32451127 0-158.37497078-71.05045952-158.37497078-158.38176013S420.15378725 351.56785872 507.47829852 351.56785872c87.34487928 0 158.38854946 71.05045952 158.38854946 158.38176013S594.81638847 668.33816831 507.47829852 668.33816831z" fill="currentColor" ></path><path d="M507.47829852 339.38099062c-94.19532493 0-170.56183889 76.36651397-170.5618389 170.57541756S413.28297358 680.52503642 507.47829852 680.52503642c94.21569295 0 170.58220691-76.36651397 170.58220692-170.56862824S601.68720212 339.38099062 507.47829852 339.38099062z m103.38130407 273.9499323c-27.60546282 27.61904151-64.32222203 42.82716662-103.38809342 42.82716662-39.0522927 0-75.76226257-15.20812511-103.36772538-42.82716662C376.49832096 585.7254601 361.27661716 549.00191157 361.27661716 509.95640818s15.22170381-75.76905191 42.83395596-103.37451472c27.60546282-27.61904151 64.32222203-42.82716662 103.36772541-42.82716662 39.06587139 0 75.77584125 15.20812511 103.3880934 42.82716662 27.61225217 27.60546282 42.81358793 64.32901136 42.81358793 103.37451472s-15.20812511 75.76905191-42.82037727 103.37451474z" fill="currentColor" ></path></symbol><symbol id="jinggao" viewBox="0 0 1155 1024"><path d="M513.239709 49.588378C533.075061 14.876513 580.184019 2.479419 614.895884 22.31477c12.397094 7.438257 19.835351 14.876513 27.273608 27.273608l490.924939 850.440678c19.835351 34.711864 7.438257 81.820823-27.273608 101.656174-12.397094 7.438257-24.794189 9.917676-37.191283 9.917676H86.779661c-42.150121 0-74.382567-32.232446-74.382567-74.382567 0-12.397094 2.479419-24.794189 9.917676-37.191283L513.239709 49.588378z" fill="#FFBA00" ></path><path d="M86.779661 1024c-47.108959 0-86.779661-39.670702-86.779661-86.779661 0-14.876513 4.958838-29.753027 12.397094-44.62954L503.322034 44.62954c24.794189-42.150121 76.861985-54.547215 119.012106-32.232446 12.397094 7.438257 24.794189 19.835351 32.232446 32.232446L1143.012107 892.590799c12.397094 19.835351 14.876513 44.62954 7.438256 66.94431-4.958838 22.31477-19.835351 42.150121-39.670702 52.067797-12.397094 7.438257-27.273608 12.397094-44.62954 12.397094H86.779661zM577.7046 24.794189c-22.31477 0-42.150121 9.917676-54.547215 32.232445L32.232446 904.987893c-4.958838 9.917676-7.438257 19.835351-7.438257 32.232446 0 34.711864 27.273608 61.985472 61.985472 61.985472h981.849879c9.917676 0 22.31477-2.479419 32.232445-7.438257 29.753027-17.355932 39.670702-54.547215 22.31477-84.300242L632.251816 54.547215c-4.958838-9.917676-12.397094-17.355932-22.31477-22.314769-9.917676-4.958838-22.31477-7.438257-32.232446-7.438257z m-64.464891 24.794189z" ></path><path d="M505.801453 825.646489c0-34.711864 27.273608-57.026634 59.506053-57.026634 32.232446 0 59.506053 22.31477 59.506053 57.026634 0 37.191283-27.273608 59.506053-59.506053 59.506053-32.232446 0-59.506053-22.31477-59.506053-59.506053z m17.355932-414.062954l-2.479419-86.779661h89.25908l-2.479419 86.779661-19.835351 287.612591h-49.588378l-14.876513-287.612591z" ></path></symbol><symbol id="a-zu20" viewBox="0 0 1024 1024"><path d="M95.936884 10.098619h565.522682v706.903353H95.936884V10.098619z" fill="#82BF82" ></path><path d="M661.459566 727.100592H95.936884c-6.059172 0-10.098619-4.039448-10.09862-10.09862V10.098619C85.838264 4.039448 89.877712 0 95.936884 0h565.522682c6.059172 0 10.098619 4.039448 10.098619 10.098619v706.903353c0 6.059172-4.039448 10.098619-10.098619 10.09862zM106.035503 706.903353h545.325444V20.197239H106.035503v686.706114z" fill="#016601" ></path><path d="M909.885602 941.191321l-201.972387-298.919132 153.499014-16.157791-375.668639-228.228796 74.729783 440.299802 68.670611-141.38067 201.972387 298.919132 78.769231-54.532545z" fill="currentColor" ></path><path d="M827.076923 1024l-193.893491-286.800789-80.788955 165.617357-92.907298-545.325444 464.53649 280.741618-179.755424 20.197238 193.893491 288.820513-111.084813 76.749507z m-199.952663-367.589744l210.051282 311.037476 44.433925-32.315582L671.558185 624.094675l127.242604-14.138068-286.800789-173.696252L570.571992 771.534517l56.552268-115.124261z" fill="#232323" ></path></symbol><symbol id="jiaodubiaozhu" viewBox="0 0 1024 1024"><path d="M922.026667 848.853333H158.933333a21.333333 21.333333 0 1 1 0-42.666666h763.093334a21.333333 21.333333 0 1 1 0 42.666666zM665.386667 167.253333L170.666667 661.333333a21.333333 21.333333 0 0 1-30.293334 0 21.333333 21.333333 0 0 1 0-30.506666l494.933334-493.866667a21.333333 21.333333 0 1 1 30.08 30.293333z" fill="currentColor" ></path><path d="M779.306667 708.053333l-42.666667-6.186666c13.013333-88.96-4.693333-209.28-162.773333-277.333334l17.066666-39.04c192.853333 83.84 200.746667 237.653333 188.373334 322.56z" fill="#57B8FF" ></path><path d="M683.093333 677.12l151.68 34.56-93.013333 58.453333-58.666667-93.013333zM564.906667 481.493333l54.186666-145.706666-99.84 45.653333 45.653334 100.053333z" fill="#57B8FF" ></path></symbol><symbol id="duoxianduan" viewBox="0 0 1024 1024"><path d="M137.386667 826.666667H672c3.626667 0 245.333333-16 245.333333-323.2 0-100.693333-26.666667-179.2-80.853333-234.666667a274.986667 274.986667 0 0 0-187.733333-76.16l1.28 42.666667v-21.333334 21.333334a236.586667 236.586667 0 0 1 158.08 64c45.653333 46.08 68.48 114.133333 68.053333 202.666666 0 265.386667-197.546667 280.533333-205.866667 280.96h-533.333333z" fill="currentColor" ></path><path d="M231.466667 869.333333m-20.053334 0l-83.84 0q-20.053333 0-20.053333-20.053333l0-87.253333q0-20.053333 20.053333-20.053334l83.84 0q20.053333 0 20.053334 20.053334l0 87.253333q0 20.053333-20.053334 20.053333Z" fill="#57B8FF" ></path><path d="M677.333333 869.333333m-20.053333 0l-83.84 0q-20.053333 0-20.053333-20.053333l0-87.253333q0-20.053333 20.053333-20.053334l83.84 0q20.053333 0 20.053333 20.053334l0 87.253333q0 20.053333-20.053333 20.053333Z" fill="#57B8FF" ></path><path d="M683.946667 271.36m-20.053334 0l-83.84 0q-20.053333 0-20.053333-20.053333l0-87.253334q0-20.053333 20.053333-20.053333l83.84 0q20.053333 0 20.053334 20.053333l0 87.253334q0 20.053333-20.053334 20.053333Z" fill="#57B8FF" ></path></symbol><symbol id="yangtiaoxian" viewBox="0 0 1024 1024"><path d="M142.72 773.12a21.333333 21.333333 0 0 1-21.333333-21.333333c0-10.453333-4.266667-253.226667 93.226666-352.64a135.253333 135.253333 0 0 1 100.053334-42.666667c104.96 0 152.96 69.333333 195.2 130.56 38.186667 55.466667 71.253333 103.253333 139.733333 109.226667 118.186667 10.88 197.12-234.666667 217.386667-330.666667a21.333333 21.333333 0 0 1 25.173333-16.426667 21.333333 21.333333 0 0 1 16.64 25.386667c-3.413333 15.146667-79.146667 364.8-251.306667 364.8h-11.52c-88.533333-7.893333-132.48-71.466667-170.666666-128-41.6-60.16-77.44-112.213333-160-112.213333a93.653333 93.653333 0 0 0-69.546667 30.293333c-85.333333 86.826667-81.066667 320-81.066667 321.92a21.333333 21.333333 0 0 1-21.333333 21.333333z" fill="currentColor" ></path><path d="M89.386667 703.573333m17.706666 0l71.253334 0q17.706667 0 17.706666 17.706667l0 71.253333q0 17.706667-17.706666 17.706667l-71.253334 0q-17.706667 0-17.706666-17.706667l0-71.253333q0-17.706667 17.706666-17.706667Z" fill="#57B8FF" ></path><path d="M829.866667 213.76m17.706666 0l71.253334 0q17.706667 0 17.706666 17.706667l0 71.253333q0 17.706667-17.706666 17.706667l-71.253334 0q-17.706667 0-17.706666-17.706667l0-71.253333q0-17.706667 17.706666-17.706667Z" fill="#57B8FF" ></path></symbol><symbol id="juxing" viewBox="0 0 1024 1024"><path d="M824.533333 814.08H203.946667a62.72 62.72 0 0 1-61.013334-64V266.88a62.72 62.72 0 0 1 61.013334-64h620.586666a62.72 62.72 0 0 1 61.013334 64v482.986667a62.72 62.72 0 0 1-61.013334 64.213333zM203.946667 244.693333a21.333333 21.333333 0 0 0-21.333334 21.333334v483.84a21.333333 21.333333 0 0 0 21.333334 22.4h620.586666a21.333333 21.333333 0 0 0 21.333334-22.4V266.88a21.333333 21.333333 0 0 0-21.333334-21.333333z" fill="currentColor" ></path><path d="M105.6 726.4m19.413333 0l80.853334 0q19.413333 0 19.413333 19.413333l0 86.826667q0 19.413333-19.413333 19.413333l-80.853334 0q-19.413333 0-19.413333-19.413333l0-86.826667q0-19.413333 19.413333-19.413333Z" fill="#57B8FF" ></path><path d="M796.8 169.386667m19.413333 0l80.853334 0q19.413333 0 19.413333 19.413333l0 86.826667q0 19.413333-19.413333 19.413333l-80.853334 0q-19.413333 0-19.413333-19.413333l0-86.826667q0-19.413333 19.413333-19.413333Z" fill="#57B8FF" ></path></symbol><symbol id="zhixian" viewBox="0 0 1024 1024"><path d="M204.373333 809.173333a21.333333 21.333333 0 0 1-13.866666-5.546666 17.066667 17.066667 0 0 1 0-25.6L806.4 208.853333a21.333333 21.333333 0 0 1 27.946667 0 17.28 17.28 0 0 1 0 25.813334L218.453333 803.626667a21.333333 21.333333 0 0 1-14.08 5.546666z" fill="currentColor" ></path><path d="M734.72 157.013333m23.68 0l101.12 0q23.68 0 23.68 23.68l0 101.12q0 23.68-23.68 23.68l-101.12 0q-23.68 0-23.68-23.68l0-101.12q0-23.68 23.68-23.68Z" fill="#57B8FF" ></path><path d="M127.573333 726.826667m23.68 0l101.12 0q23.68 0 23.68 23.68l0 101.12q0 23.68-23.68 23.68l-101.12 0q-23.68 0-23.68-23.68l0-101.12q0-23.68 23.68-23.68Z" fill="#57B8FF" ></path></symbol><symbol id="yuanhu" viewBox="0 0 1024 1024"><path d="M146.346667 842.026667l-45.44-3.413334c0-10.026667 1.28-21.333333 1.706666-36.48 4.053333-101.12 9.813333-290.133333 147.2-446.72 153.173333-174.933333 400.853333-174.506667 599.253334-174.506666h21.333333v45.44h-21.333333c-189.866667 0-425.386667 0-565.12 159.146666-126.506667 144.64-132.693333 322.56-135.893334 418.346667-0.426667 14.72-1.066667 28.16-1.706666 38.186667z" fill="currentColor" ></path><path d="M63.573333 788.48m21.546667 0l93.226667 0q21.546667 0 21.546666 21.546667l0 93.226666q0 21.546667-21.546666 21.546667l-93.226667 0q-21.546667 0-21.546667-21.546667l0-93.226666q0-21.546667 21.546667-21.546667Z" fill="#57B8FF" ></path><path d="M256.426667 256.213333m21.546666 0l93.226667 0q21.546667 0 21.546667 21.546667l0 93.226667q0 21.546667-21.546667 21.546666l-93.226667 0q-21.546667 0-21.546666-21.546666l0-93.226667q0-21.546667 21.546666-21.546667Z" fill="#57B8FF" ></path><path d="M823.253333 135.466667m21.546667 0l93.226667 0q21.546667 0 21.546666 21.546666l0 93.226667q0 21.546667-21.546666 21.546667l-93.226667 0q-21.546667 0-21.546667-21.546667l0-93.226667q0-21.546667 21.546667-21.546666Z" fill="#57B8FF" ></path></symbol><symbol id="yidong" viewBox="0 0 1024 1024"><path d="M847.786667 533.333333H174.08a21.333333 21.333333 0 1 1 0-42.666666h673.706667a21.333333 21.333333 0 0 1 0 42.666666z" fill="currentColor" ></path><path d="M187.946667 408.32v207.36L84.266667 512l103.68-103.68zM833.92 408.32v207.36L937.6 512l-103.68-103.68z" fill="currentColor" ></path><path d="M512 870.186667a21.333333 21.333333 0 0 1-21.333333-21.333334V175.146667a21.333333 21.333333 0 0 1 42.666666 0v673.706666a21.333333 21.333333 0 0 1-21.333333 21.333334z" fill="currentColor" ></path><path d="M407.253333 834.986667h207.36L510.933333 938.666667l-103.68-103.68zM407.253333 189.013333h207.36L510.933333 85.333333l-103.68 103.68z" fill="currentColor" ></path></symbol><symbol id="suofang" viewBox="0 0 1024 1024"><path d="M868.693333 926.08H604.373333a21.333333 21.333333 0 0 1 0-42.666667h264.32A26.666667 26.666667 0 0 0 896 856.746667V184.746667a26.666667 26.666667 0 0 0-26.666667-26.666667H196.693333A26.88 26.88 0 0 0 170.666667 184.746667v266.453333a21.333333 21.333333 0 0 1-42.666667 0V184.746667a69.546667 69.546667 0 0 1 68.693333-69.333334h672A69.333333 69.333333 0 0 1 938.666667 184.746667v672a69.333333 69.333333 0 0 1-69.973334 69.333333z" fill="currentColor" ></path><path d="M487.68 926.08H170.666667a43.946667 43.946667 0 0 1-42.666667-43.946667V565.973333a43.946667 43.946667 0 0 1 42.666667-43.946666h317.013333a43.946667 43.946667 0 0 1 43.946667 43.946666v316.16a43.946667 43.946667 0 0 1-43.946667 43.946667zM170.666667 564.693333v317.44l317.653333 1.28a1.28 1.28 0 0 0 1.28-1.28V565.973333z" fill="#57B8FF" ></path></symbol><symbol id="fuzhi" viewBox="0 0 1024 1024"><path d="M241.92 307.626667m-149.333333 0a149.333333 149.333333 0 1 0 298.666666 0 149.333333 149.333333 0 1 0-298.666666 0Z" fill="currentColor" ></path><path d="M578.56 746.666667a149.333333 149.333333 0 0 1 36.053333-97.066667 149.333333 149.333333 0 1 0 0 194.133333A149.333333 149.333333 0 0 1 578.56 746.666667z" fill="#57B8FF" ></path><path d="M763.946667 746.88m-149.333334 0a149.333333 149.333333 0 1 0 298.666667 0 149.333333 149.333333 0 1 0-298.666667 0Z" fill="#57B8FF" ></path><path d="M725.333333 452.693333a23.893333 23.893333 0 0 1-23.893333-23.893333v-72.96c0-19.413333-28.373333-40.96-68.906667-40.96H490.666667a23.893333 23.893333 0 1 1 0-47.573333h141.44c65.28 0 116.48 38.826667 116.48 88.533333v72.96A23.893333 23.893333 0 0 1 725.333333 452.693333z" fill="currentColor" ></path><path d="M630.186667 401.066667l94.933333 164.266666 94.72-164.266666h-189.653333z" fill="currentColor" ></path></symbol><symbol id="qianjin" viewBox="0 0 1024 1024"><path d="M528.426667 578.346667v170.666666L917.333333 478.293333 528.64 213.333333v170.666667S143.146667 373.76 106.666667 810.666667c24.106667-62.293333 100.693333-274.773333 421.76-232.32z" fill="currentColor" ></path></symbol><symbol id="houtui" viewBox="0 0 1024 1024"><path d="M495.573333 578.346667v170.666666L106.666667 478.293333 495.36 213.333333v170.666667S880.853333 373.76 917.333333 810.666667c-24.106667-62.293333-100.693333-274.773333-421.76-232.32z" fill="currentColor" ></path></symbol><symbol id="charukuai1" viewBox="0 0 1024 1024"><path d="M889.813333 579.413333L819.413333 618.666667M793.429333 572.330667l70.357334-39.402667 52.117333 93.056-70.357333 39.402667z" fill="#57B8FF" ></path><path d="M896 623.146667V326.4l-125.653333-13.013333V180.693333H519.04a26.24 26.24 0 0 0-25.173333 26.88v167.253334" fill="#57B8FF" ></path><path d="M917.333333 623.146667h-42.666666v-277.333334l-125.866667-13.013333V202.24H519.04c-1.493333 0-3.626667 2.133333-3.626667 5.333333v167.253334h-42.666666V207.573333a47.573333 47.573333 0 0 1 46.72-48.426666h272.853333v134.613333l125.866667 13.226667z" fill="#57B8FF" ></path><path d="M915.84 303.786667l-123.946667-145.066667H765.866667v174.293333h149.973333v-29.226666z" ></path><path d="M549.76 686.506667H189.653333A46.933333 46.933333 0 0 1 142.72 640V411.52a46.933333 46.933333 0 0 1 46.933333-46.72h360.106667A46.933333 46.933333 0 0 1 597.333333 411.52V640a46.933333 46.933333 0 0 1-47.573333 46.506667zM189.653333 407.466667a4.266667 4.266667 0 0 0-4.266666 4.053333V640a4.053333 4.053333 0 0 0 4.266666 4.053333h360.106667A4.053333 4.053333 0 0 0 554.666667 640V411.52a4.266667 4.266667 0 0 0-4.266667-4.053333z" fill="currentColor" ></path><path d="M107.306667 592m20.693333 0l84.266667 0q20.693333 0 20.693333 20.693333l0 80.213334q0 20.693333-20.693333 20.693333l-84.266667 0q-20.693333 0-20.693333-20.693333l0-80.213334q0-20.693333 20.693333-20.693333Z" fill="currentColor" ></path><path d="M610.133333 884.053333A227.626667 227.626667 0 0 1 379.306667 661.333333 227.626667 227.626667 0 0 1 610.133333 436.266667 227.626667 227.626667 0 0 1 840.746667 661.333333 227.626667 227.626667 0 0 1 610.133333 884.053333z m0-405.333333A184.96 184.96 0 0 0 421.973333 661.333333a184.96 184.96 0 0 0 188.16 181.12A184.746667 184.746667 0 0 0 798.08 661.333333a184.96 184.96 0 0 0-187.946667-182.4z" fill="currentColor" ></path><path d="M899.413333 869.12h-133.973333a16.426667 16.426667 0 0 1-16.64-15.786667l150.613333-145.706666a16.426667 16.426667 0 0 1 16.853334 16.213333V853.333333a16.426667 16.426667 0 0 1-16.853334 15.786667z" fill="#57B8FF" ></path></symbol><symbol id="a-5-15qianbi" viewBox="0 0 1024 1024"><path d="M205.696 634.581333l359.616-359.637333 181.930667 181.930667L387.626667 816.512zM792.746667 414.933333l-181.973334-181.973333 82.56-82.56a56.96 56.96 0 0 1 80.853334 0L874.666667 251.52a56.96 56.96 0 0 1 0 80.853333z" fill="currentColor" ></path><path d="M217.173333 682.666667L277.333333 744.32l61.013334 60.8-95.146667 31.786667-81.706667 27.093333a5.973333 5.973333 0 0 1-3.2-3.2l27.093334-81.706667L217.173333 682.666667m-11.52-48.426667l-45.226666 136.533333L133.12 853.333333a30.506667 30.506667 0 0 0 28.373333 37.12 21.333333 21.333333 0 0 0 7.466667-1.28l82.56-27.306666 136.106667-45.226667L296.533333 725.333333l-90.88-90.453333z" fill="currentColor" ></path><path d="M164.053333 791.210667l17.493334-17.493334 70.762666 70.741334-17.493333 17.493333z" fill="currentColor" ></path></symbol><symbol id="yuan" viewBox="0 0 1024 1024"><path d="M512 151.68A366.293333 366.293333 0 1 1 146.133333 517.973333 366.72 366.72 0 0 1 512 151.68M512 106.666667a411.946667 411.946667 0 1 0 412.16 411.306666A411.946667 411.946667 0 0 0 512 106.666667z" fill="currentColor" ></path><path d="M458.88 869.333333m20.266667 0l87.466666 0q20.266667 0 20.266667 20.266667l0 87.466667q0 20.266667-20.266667 20.266666l-87.466666 0q-20.266667 0-20.266667-20.266666l0-87.466667q0-20.266667 20.266667-20.266667Z" fill="#57B8FF" ></path><path d="M453.546667 68.053333m18.773333 0l80.213333 0q18.773333 0 18.773334 18.773334l0 80.213333q0 18.773333-18.773334 18.773333l-80.213333 0q-18.773333 0-18.773333-18.773333l0-80.213333q0-18.773333 18.773333-18.773334Z" fill="#57B8FF" ></path><path d="M836.053333 459.093333m18.773334 0l80.213333 0q18.773333 0 18.773333 18.773334l0 80.213333q0 18.773333-18.773333 18.773333l-80.213333 0q-18.773333 0-18.773334-18.773333l0-80.213333q0-18.773333 18.773334-18.773334Z" fill="#57B8FF" ></path><path d="M68.053333 464.426667m18.773334 0l80.213333 0q18.773333 0 18.773333 18.773333l0 80.213333q0 18.773333-18.773333 18.773334l-80.213333 0q-18.773333 0-18.773334-18.773334l0-80.213333q0-18.773333 18.773334-18.773333Z" fill="#57B8FF" ></path></symbol><symbol id="danhangwenzi" viewBox="0 0 1024 1024"><path d="M896 900.48H128a21.333333 21.333333 0 0 1 0-42.666667h768a21.333333 21.333333 0 0 1 0 42.666667z" fill="#57B8FF" ></path><path d="M810.666667 772.693333h-94.72l-67.626667-177.92h-277.333333l-64 177.92H213.333333L466.133333 123.093333h91.733334z m-189.013334-251.306666l-100.266666-269.866667A289.706667 289.706667 0 0 1 512 206.08h-2.133333a267.306667 267.306667 0 0 1-10.666667 45.44l-100.266667 269.866667z" fill="currentColor" ></path></symbol><symbol id="zhengduobianxing" viewBox="0 0 1024 1024"><path d="M758.4 866.133333H283.733333a21.333333 21.333333 0 0 1-20.053333-14.506666L116.906667 415.146667a21.333333 21.333333 0 0 1 7.893333-24.32l384-269.653334a21.333333 21.333333 0 0 1 24.533333 0l384 269.653334a21.333333 21.333333 0 0 1 8.106667 24.32L778.666667 851.626667a21.333333 21.333333 0 0 1-20.266667 14.506666zM298.666667 823.466667h444.373333l136.746667-406.826667L521.173333 164.693333 162.346667 416.64z" fill="currentColor" ></path><path d="M456.746667 445.653333m20.053333 0l88.533333 0q20.053333 0 20.053334 20.053334l0 84.266666q0 20.053333-20.053334 20.053334l-88.533333 0q-20.053333 0-20.053333-20.053334l0-84.266666q0-20.053333 20.053333-20.053334Z" fill="#57B8FF" ></path><path d="M193.92 760.96m20.053333 0l88.533334 0q20.053333 0 20.053333 20.053333l0 84.266667q0 20.053333-20.053333 20.053333l-88.533334 0q-20.053333 0-20.053333-20.053333l0-84.266667q0-20.053333 20.053333-20.053333Z" fill="#57B8FF" ></path></symbol><symbol id="tianchong" viewBox="0 0 1024 1024"><path d="M894.506667 880.213333H131.2a22.613333 22.613333 0 0 1 0-45.013333h763.306667a22.613333 22.613333 0 0 1 0 45.013333zM892.16 204.586667H128a22.613333 22.613333 0 1 1 0-45.013334h764.16a22.613333 22.613333 0 0 1 0 45.013334z" fill="currentColor" ></path><path d="M176.426667 923.52a22.4 22.4 0 0 1-21.333334-22.613333V135.466667a22.4 22.4 0 1 1 44.8 0v765.44a22.4 22.4 0 0 1-23.466666 22.613333zM849.92 923.52a22.4 22.4 0 0 1-22.4-22.613333V135.466667a22.4 22.4 0 1 1 44.8 0v765.44a22.4 22.4 0 0 1-22.4 22.613333z" fill="currentColor" ></path><path d="M271.146667 415.786667a22.613333 22.613333 0 0 1-16-38.4l123.733333-124.16a22.4 22.4 0 1 1 31.786667 31.786666l-123.733334 124.16a21.333333 21.333333 0 0 1-15.786666 6.613334zM275.626667 776.32a22.4 22.4 0 0 1-15.786667-6.613333 22.826667 22.826667 0 0 1 0-32l469.333333-471.04a22.613333 22.613333 0 0 1 31.786667 0 22.826667 22.826667 0 0 1 0 32l-469.333333 471.04a22.4 22.4 0 0 1-16 6.613333zM472.533333 756.48a23.466667 23.466667 0 0 1-16-6.613333 22.613333 22.613333 0 0 1 0-31.786667l263.253334-264.106667a22.4 22.4 0 1 1 31.786666 31.786667L488.32 749.866667a23.253333 23.253333 0 0 1-15.786667 6.613333zM287.146667 580.693333a22.613333 22.613333 0 0 1-16-38.4L534.613333 277.333333a21.333333 21.333333 0 0 1 31.573334 0 22.826667 22.826667 0 0 1 0 32L302.933333 574.08a21.333333 21.333333 0 0 1-15.786666 6.613333zM641.92 787.626667a21.333333 21.333333 0 0 1-15.786667-6.613334 21.333333 21.333333 0 0 1 0-31.786666l123.52-124.16a22.613333 22.613333 0 0 1 31.786667 0 22.826667 22.826667 0 0 1 0 32l-123.733333 123.946666a21.333333 21.333333 0 0 1-15.786667 6.613334z" fill="#57B8FF" ></path></symbol><symbol id="tuoyuanhu" viewBox="0 0 1024 1024"><path d="M514.986667 865.706667c-220.8 0-399.573333-155.733333-399.573334-347.733334S294.186667 170.666667 514.986667 170.666667l23.04 20.053333-45.653334 24.32c-186.666667 10.026667-334.933333 142.08-334.933333 303.36 0 167.893333 160.426667 304.426667 357.546667 304.426667s357.333333-136.533333 357.333333-304.426667l-1.92 1.706667c1.706667-10.88 2.986667-21.333333 4.053333-33.066667l1.28-2.346667 38.826667 33.706667c0 191.573333-178.986667 347.306667-399.573333 347.306667z" fill="currentColor" ></path><path d="M519.68 539.946667a21.333333 21.333333 0 0 1-21.333333-21.333334V186.666667a21.333333 21.333333 0 0 1 43.946666 0v331.306666a21.333333 21.333333 0 0 1-22.613333 21.973334z" fill="currentColor" ></path><path d="M884.266667 549.12H519.68a21.333333 21.333333 0 1 1 0-43.946667h364.586667a21.333333 21.333333 0 0 1 0 43.946667z" fill="currentColor" ></path><path d="M447.786667 461.866667m20.266666 0l85.546667 0q20.266667 0 20.266667 20.266666l0 89.813334q0 20.266667-20.266667 20.266666l-85.546667 0q-20.266667 0-20.266666-20.266666l0-89.813334q0-20.266667 20.266666-20.266666Z" fill="#57B8FF" ></path><path d="M821.12 461.866667m20.266667 0l85.546666 0q20.266667 0 20.266667 20.266666l0 89.813334q0 20.266667-20.266667 20.266666l-85.546666 0q-20.266667 0-20.266667-20.266666l0-89.813334q0-20.266667 20.266667-20.266666Z" fill="#57B8FF" ></path><path d="M447.786667 121.386667m20.266666 0l85.546667 0q20.266667 0 20.266667 20.266666l0 89.813334q0 20.266667-20.266667 20.266666l-85.546667 0q-20.266667 0-20.266666-20.266666l0-89.813334q0-20.266667 20.266666-20.266666Z" fill="#57B8FF" ></path></symbol><symbol id="tuoyuan" viewBox="0 0 1024 1024"><path d="M512 228.48c186.453333 0 337.92 129.706667 337.92 289.28S698.026667 807.04 512 807.04 173.44 677.12 173.44 517.76 325.12 228.48 512 228.48m0-41.386667c-208.64 0-377.813333 148.053333-377.813333 330.666667S302.933333 848.213333 512 848.213333s377.813333-147.84 377.813333-330.453333S720.213333 187.093333 512 187.093333z" fill="currentColor" ></path><path d="M92.373333 456.106667m19.413334 0l80.426666 0q19.413333 0 19.413334 19.413333l0 85.12q0 19.413333-19.413334 19.413333l-80.426666 0q-19.413333 0-19.413334-19.413333l0-85.12q0-19.413333 19.413334-19.413333Z" fill="#57B8FF" ></path><path d="M804.906667 455.68m19.413333 0l80.426667 0q19.413333 0 19.413333 19.413333l0 85.12q0 19.413333-19.413333 19.413334l-80.426667 0q-19.413333 0-19.413333-19.413334l0-85.12q0-19.413333 19.413333-19.413333Z" fill="#57B8FF" ></path><path d="M452.053333 763.946667m19.413334 0l80.426666 0q19.413333 0 19.413334 19.413333l0 85.12q0 19.413333-19.413334 19.413333l-80.426666 0q-19.413333 0-19.413334-19.413333l0-85.12q0-19.413333 19.413334-19.413333Z" fill="#57B8FF" ></path></symbol><symbol id="dian" viewBox="0 0 1024 1024"><path d="M402.133333 384m40.746667 0l174.506667 0q40.746667 0 40.746666 40.746667l0 174.506666q0 40.746667-40.746666 40.746667l-174.506667 0q-40.746667 0-40.746667-40.746667l0-174.506666q0-40.746667 40.746667-40.746667Z" fill="#57B8FF" ></path></symbol><symbol id="yunxianpizhu" viewBox="0 0 1024 1024"><path d="M748.586667 396.586667H746.666667a21.333333 21.333333 0 0 1-19.413334-24.746667 207.146667 207.146667 0 0 0 1.706667-26.453333 215.466667 215.466667 0 0 0-430.933333 0c0 7.893333 0 15.573333 1.28 23.04a21.333333 21.333333 0 1 1-44.16 4.693333c0-8.96-1.493333-18.346667-1.493334-27.733333a259.84 259.84 0 0 1 519.68 0 293.546667 293.546667 0 0 1-1.92 31.786666 22.4 22.4 0 0 1-22.826666 19.413334z" fill="currentColor" ></path><path d="M267.52 695.04a216.746667 216.746667 0 0 1-105.386667-24.746667 164.266667 164.266667 0 0 1-85.333333-97.493333 174.506667 174.506667 0 0 1 203.946667-224.213333 21.333333 21.333333 0 1 1-10.88 42.666666 128 128 0 0 0-144 69.76 130.133333 130.133333 0 0 0-6.4 97.92 119.253333 119.253333 0 0 0 61.866666 71.253334 180.48 180.48 0 0 0 98.986667 20.266666 21.333333 21.333333 0 0 1 22.826667 21.333334 22.4 22.4 0 0 1-21.333334 22.826666zM756.48 698.666667h-14.08a21.333333 21.333333 0 0 1 1.28-44.373334 181.546667 181.546667 0 0 0 98.986667-20.053333 120.533333 120.533333 0 0 0 61.866666-71.253333 130.56 130.56 0 0 0-6.826666-97.706667 128 128 0 0 0-144-69.76 21.333333 21.333333 0 0 1-10.88-42.666667A170.666667 170.666667 0 0 1 938.666667 445.866667a174.08 174.08 0 0 1 8.106666 130.133333 163.84 163.84 0 0 1-85.333333 97.28 216.746667 216.746667 0 0 1-104.96 25.386667z" fill="currentColor" ></path><path d="M522.24 797.226667a58.026667 58.026667 0 0 1-14.72-1.92A57.6 57.6 0 0 1 472.746667 768l-121.813334-211.2a56.96 56.96 0 0 1 21.333334-77.866667l83.2-48.213333a57.6 57.6 0 0 1 78.08 21.333333l121.813333 211.2a56.96 56.96 0 0 1 5.76 42.666667 57.6 57.6 0 0 1-26.666667 34.773333L550.826667 789.333333a56.96 56.96 0 0 1-28.586667 7.893334z m-38.613333-330.666667a14.72 14.72 0 0 0-7.253334 1.92l-83.2 48a14.293333 14.293333 0 0 0-5.333333 19.626667L509.866667 746.666667a13.226667 13.226667 0 0 0 8.533333 6.613333 14.293333 14.293333 0 0 0 11.093333-1.28l83.2-48a14.08 14.08 0 0 0 6.826667-8.746667 14.933333 14.933333 0 0 0-0.853333-10.453333l-122.026667-211.2a14.506667 14.506667 0 0 0-8.746667-6.613333 10.026667 10.026667 0 0 0-4.266666-0.426667z m139.733333 256z" fill="#57B8FF" ></path><path d="M688.853333 935.68a21.333333 21.333333 0 0 1-18.133333-10.026667l-99.413333-162.346666a21.333333 21.333333 0 0 1 36.48-22.4l99.2 162.346666a21.333333 21.333333 0 0 1-7.04 29.44 21.333333 21.333333 0 0 1-11.093334 2.986667z" fill="#57B8FF" ></path></symbol><symbol id="yinxianbiaozhu" viewBox="0 0 1024 1024"><path d="M873.386667 899.84a21.333333 21.333333 0 0 1-14.933334-6.4L551.893333 586.88a21.333333 21.333333 0 0 1 30.08-30.08l306.56 306.56a21.333333 21.333333 0 0 1 0 30.08 21.333333 21.333333 0 0 1-15.146666 6.4z" fill="currentColor" ></path><path d="M874.666667 897.92a21.333333 21.333333 0 0 1-21.333334-21.333333V693.333333a21.333333 21.333333 0 0 1 42.666667 0v183.253334a21.333333 21.333333 0 0 1-21.333333 21.333333z" fill="currentColor" ></path><path d="M113.493333 124.16m42.666667 0l384 0q42.666667 0 42.666667 42.666667l0 384q0 42.666667-42.666667 42.666666l-384 0q-42.666667 0-42.666667-42.666666l0-384q0-42.666667 42.666667-42.666667Z" fill="#57B8FF" ></path></symbol><symbol id="shentubiaozhu" viewBox="0 0 1024 1024"><path d="M877.013333 898.56a21.333333 21.333333 0 0 1-15.146666-6.186667L554.666667 585.813333A21.333333 21.333333 0 0 1 585.6 554.666667l306.56 307.413333a21.333333 21.333333 0 0 1 0 30.293333 21.333333 21.333333 0 0 1-15.146667 6.186667z" fill="currentColor" ></path><path d="M878.08 896a21.333333 21.333333 0 0 1-21.333333-21.333333v-182.4a21.333333 21.333333 0 1 1 42.666666 0V874.666667a21.333333 21.333333 0 0 1-21.333333 21.333333z" fill="currentColor" ></path><path d="M124.586667 125.44m42.666666 0l384 0q42.666667 0 42.666667 42.666667l0 384q0 42.666667-42.666667 42.666666l-384 0q-42.666667 0-42.666666-42.666666l0-384q0-42.666667 42.666666-42.666667Z" fill="#57B8FF" ></path><path d="M314.453333 252.373333H190.08a21.333333 21.333333 0 0 1 0-42.666666h124.373333a21.333333 21.333333 0 0 1 0 42.666666zM403.413333 364.373333h-213.333333a21.333333 21.333333 0 0 1 0-42.666666h213.333333a21.333333 21.333333 0 1 1 0 42.666666zM520.746667 490.666667H190.08a21.333333 21.333333 0 0 1 0-42.666667h330.666667a21.333333 21.333333 0 0 1 0 42.666667z" fill="currentColor" ></path></symbol><symbol id="shanchu" viewBox="0 0 1024 1024"><path d="M905.813333 902.4H141.653333a21.333333 21.333333 0 0 1 0-42.666667h764.16a21.333333 21.333333 0 0 1 0 42.666667z" fill="#57B8FF" ></path><path d="M918.4 403.84L648.32 132.266667a42.666667 42.666667 0 0 0-60.16 0L167.893333 554.666667a42.666667 42.666667 0 0 0 0 60.373333l163.2 164.053333a193.066667 193.066667 0 0 0 273.92 0l313.386667-314.88a42.666667 42.666667 0 0 0 0-60.373333z m-296.106667 275.2l-70.826666 71.04a117.12 117.12 0 0 1-166.4 0l-159.786667-160.64a25.813333 25.813333 0 0 1 0-36.48l135.68-136.533333a25.813333 25.813333 0 0 1 36.48 0l224.853333 225.92a26.24 26.24 0 0 1 0 36.693333z" fill="currentColor" ></path></symbol><symbol id="yuanjiao" viewBox="0 0 1024 1024"><path d="M137.6 224a21.333333 21.333333 0 0 1-21.333333-21.333333V192a21.333333 21.333333 0 0 1 42.666666 0v10.666667a21.333333 21.333333 0 0 1-21.333333 21.333333zM137.6 845.226667a21.333333 21.333333 0 0 1-21.333333-21.333334v-21.333333a21.333333 21.333333 0 0 1 42.666666 0v21.333333a21.333333 21.333333 0 0 1-21.333333 21.333334z m0-103.466667a21.333333 21.333333 0 0 1-21.333333-21.333333v-21.333334a21.333333 21.333333 0 1 1 42.666666 0v21.333334a21.333333 21.333333 0 0 1-21.333333 21.333333z m0-103.466667a21.333333 21.333333 0 0 1-21.333333-21.333333v-21.333333a21.333333 21.333333 0 0 1 42.666666 0v21.333333a21.333333 21.333333 0 0 1-21.333333 21.333333z m0-103.68a21.333333 21.333333 0 0 1-21.333333-21.333333v-21.333333a21.333333 21.333333 0 0 1 42.666666 0v21.333333a21.333333 21.333333 0 0 1-21.333333 21.333333z m0-103.466666a21.333333 21.333333 0 0 1-21.333333-21.333334v-21.333333a21.333333 21.333333 0 0 1 42.666666 0v21.333333a21.333333 21.333333 0 0 1-21.333333 21.333334z m0-103.466667a21.333333 21.333333 0 0 1-21.333333-21.333333v-21.333334a21.333333 21.333333 0 0 1 42.666666 0v21.333334a21.333333 21.333333 0 0 1-21.333333 21.333333zM137.6 938.666667a21.333333 21.333333 0 0 1-21.333333-21.333334v-10.666666a21.333333 21.333333 0 0 1 42.666666 0v10.666666a21.333333 21.333333 0 0 1-21.333333 21.333334z" fill="#57B8FF" ></path><path d="M149.333333 213.333333h-10.666666a21.333333 21.333333 0 1 1 0-42.666666H149.333333a21.333333 21.333333 0 0 1 0 42.666666zM805.333333 213.333333h-21.333333a21.333333 21.333333 0 0 1 0-42.666666h21.333333a21.333333 21.333333 0 0 1 0 42.666666z m-109.44 0h-21.333333a21.333333 21.333333 0 0 1 0-42.666666h21.333333a21.333333 21.333333 0 0 1 0 42.666666z m-109.653333 0h-21.333333a21.333333 21.333333 0 0 1 0-42.666666h21.333333a21.333333 21.333333 0 1 1 0 42.666666z m-109.44 0h-21.333333a21.333333 21.333333 0 0 1 0-42.666666h21.333333a21.333333 21.333333 0 0 1 0 42.666666z m-109.44 0h-21.333333a21.333333 21.333333 0 1 1 0-42.666666h21.333333a21.333333 21.333333 0 0 1 0 42.666666z m-109.653333 0h-21.333334a21.333333 21.333333 0 0 1 0-42.666666h21.333334a21.333333 21.333333 0 0 1 0 42.666666zM903.68 213.333333h-10.666667a21.333333 21.333333 0 0 1 0-42.666666h10.666667a21.333333 21.333333 0 0 1 0 42.666666z" fill="#57B8FF" ></path><path d="M141.653333 817.066667a21.333333 21.333333 0 0 1-21.333333-21.333334C120.32 451.2 421.973333 170.666667 792.533333 170.666667a21.333333 21.333333 0 0 1 0 42.666666C445.44 213.333333 162.986667 474.666667 162.986667 795.733333a21.333333 21.333333 0 0 1-21.333334 21.333334z" fill="#57B8FF" ></path><path d="M137.6 938.666667a21.333333 21.333333 0 0 1-21.333333-21.333334V441.386667a21.333333 21.333333 0 0 1 42.666666 0V917.333333a21.333333 21.333333 0 0 1-21.333333 21.333334zM905.6 213.333333H402.773333a21.333333 21.333333 0 0 1 0-42.666666h502.826667a21.333333 21.333333 0 0 1 0 42.666666z" fill="currentColor" ></path></symbol><symbol id="zhiyuduixiangzhixia" viewBox="0 0 1024 1024"><path d="M544.213333 423.04v71.253333h-172.8v348.16h544.853334V423.04H544.213333z" fill="#57B8FF" ></path><path d="M105.6 181.546667H524.8v293.546666H105.6z" fill="currentColor" ></path></symbol><symbol id="daojiao" viewBox="0 0 1024 1024"><path d="M136.32 216.32a21.333333 21.333333 0 0 1-21.333333-21.333333v-10.666667a21.333333 21.333333 0 1 1 42.666666 0v10.666667a21.333333 21.333333 0 0 1-21.333333 21.333333zM136.32 837.546667a21.333333 21.333333 0 0 1-21.333333-21.333334v-21.333333a21.333333 21.333333 0 0 1 42.666666 0v21.333333a21.333333 21.333333 0 0 1-21.333333 21.333334z m0-103.466667a21.333333 21.333333 0 0 1-21.333333-21.333333v-21.333334a21.333333 21.333333 0 1 1 42.666666 0v21.333334a21.333333 21.333333 0 0 1-21.333333 21.333333z m0-103.466667a21.333333 21.333333 0 0 1-21.333333-21.333333v-21.333333a21.333333 21.333333 0 1 1 42.666666 0v21.333333a21.333333 21.333333 0 0 1-21.333333 21.333333z m0-103.68a21.333333 21.333333 0 0 1-21.333333-21.333333v-21.333333a21.333333 21.333333 0 0 1 42.666666 0v21.333333a21.333333 21.333333 0 0 1-21.333333 21.333333z m0-103.466666a21.333333 21.333333 0 0 1-21.333333-21.333334v-21.333333a21.333333 21.333333 0 0 1 42.666666 0v21.333333a21.333333 21.333333 0 0 1-21.333333 21.333334z m0-103.466667a21.333333 21.333333 0 0 1-21.333333-21.333333v-21.333334a21.333333 21.333333 0 0 1 42.666666 0v21.333334a21.333333 21.333333 0 0 1-21.333333 21.333333zM136.32 930.986667a21.333333 21.333333 0 0 1-21.333333-21.333334v-10.666666a21.333333 21.333333 0 0 1 42.666666 0v10.666666a21.333333 21.333333 0 0 1-21.333333 21.333334z" fill="#57B8FF" ></path><path d="M146.986667 205.653333h-10.666667a21.333333 21.333333 0 0 1 0-42.666666h10.666667a21.333333 21.333333 0 0 1 0 42.666666zM802.346667 205.653333h-21.333334a21.333333 21.333333 0 1 1 0-42.666666h21.333334a21.333333 21.333333 0 0 1 0 42.666666z m-109.226667 0h-21.333333a21.333333 21.333333 0 1 1 0-42.666666h21.333333a21.333333 21.333333 0 0 1 0 42.666666z m-109.226667 0h-21.333333a21.333333 21.333333 0 1 1 0-42.666666h21.333333a21.333333 21.333333 0 0 1 0 42.666666z m-109.226666 0h-21.333334a21.333333 21.333333 0 1 1 0-42.666666h21.333334a21.333333 21.333333 0 0 1 0 42.666666z m-109.226667 0h-21.333333a21.333333 21.333333 0 0 1 0-42.666666h21.333333a21.333333 21.333333 0 0 1 0 42.666666z m-109.44 0h-21.333333a21.333333 21.333333 0 0 1 0-42.666666h21.333333a21.333333 21.333333 0 0 1 0 42.666666zM900.48 205.653333h-10.666667a21.333333 21.333333 0 1 1 0-42.666666h10.666667a21.333333 21.333333 0 0 1 0 42.666666z" fill="#57B8FF" ></path><path d="M134.4 686.293333a21.333333 21.333333 0 0 1-14.72-36.693333L621.226667 173.226667a21.333333 21.333333 0 1 1 29.44 31.146666L149.333333 680.533333a21.333333 21.333333 0 0 1-14.933333 5.76z" fill="#57B8FF" ></path><path d="M136.32 930.986667a21.333333 21.333333 0 0 1-21.333333-21.333334V433.706667a21.333333 21.333333 0 0 1 42.666666 0v475.946666a21.333333 21.333333 0 0 1-21.333333 21.333334zM902.4 205.653333H400.853333a21.333333 21.333333 0 1 1 0-42.666666H902.4a21.333333 21.333333 0 0 1 0 42.666666z" fill="currentColor" ></path></symbol><symbol id="qianzhi" viewBox="0 0 1024 1024"><path d="M790.186667 554.88v197.973333H477.013333v94.293334h417.706667v-292.266667h-104.533333zM188.373333 278.186667h313.173334v-102.4H84.053333v292.266666h104.32v-189.866666z" fill="currentColor" ></path><path d="M217.813333 303.146667h542.72v417.493333H217.813333z" fill="#57B8FF" ></path></symbol><symbol id="houzhi" viewBox="0 0 1024 1024"><path d="M541.653333 303.573333v184.106667H238.933333V721.066667h240v-185.813334h302.72V303.573333H541.653333z" fill="#57B8FF" ></path><path d="M498.133333 554.88h417.493334v292.693333H498.133333zM104.96 176h417.493333v292.693333H104.96z" fill="currentColor" ></path></symbol><symbol id="daduan" viewBox="0 0 1024 1024"><path d="M857.173333 842.88H166.826667A57.813333 57.813333 0 0 1 106.666667 789.333333V342.826667a57.173333 57.173333 0 0 1 58.24-54.613334h232.32v42.666667H164.906667c-7.893333 0-15.573333 5.76-15.573334 11.946667V789.333333c0 5.76 7.253333 11.946667 17.493334 11.946667h690.346666c10.24 0 17.493333-6.186667 17.493334-11.946667V342.826667c0-5.546667-7.253333-11.946667-17.493334-11.946667h-228.266666v-42.666667h228.266666A57.813333 57.813333 0 0 1 917.333333 342.826667V789.333333a57.813333 57.813333 0 0 1-60.16 53.546667z" fill="currentColor" ></path><path d="M376.746667 438.186667a21.333333 21.333333 0 0 1-21.333334-21.333334v-213.333333a21.333333 21.333333 0 1 1 42.666667 0v213.333333a21.333333 21.333333 0 0 1-21.333333 21.333334zM650.24 438.186667a21.333333 21.333333 0 0 1-21.333333-21.333334v-213.333333a21.333333 21.333333 0 1 1 42.666666 0v213.333333a21.333333 21.333333 0 0 1-21.333333 21.333334z" fill="#57B8FF" ></path></symbol><symbol id="fenjie" viewBox="0 0 1024 1024"><path d="M490.666667 505.813333a74.24 74.24 0 0 1-31.36-6.186666l-326.4-155.733334a34.346667 34.346667 0 0 1-21.333334-30.08 35.626667 35.626667 0 0 1 21.333334-31.573333l337.92-169.6a82.133333 82.133333 0 0 1 66.133333 0l327.04 155.733333a33.493333 33.493333 0 0 1 21.333333 30.08 35.2 35.2 0 0 1-21.333333 31.36l-337.28 170.666667a78.506667 78.506667 0 0 1-36.053333 5.333333z m-13.013334-44.8a39.68 39.68 0 0 0 28.8 0L829.653333 298.666667 518.613333 149.333333a40.106667 40.106667 0 0 0-28.586666 0L167.466667 312.96z" fill="currentColor" ></path><path d="M469.333333 891.093333a39.253333 39.253333 0 0 1-17.066666-4.053333l-314.24-149.333333A58.026667 58.026667 0 0 1 106.666667 688V341.333333a33.92 33.92 0 0 1 50.133333-31.573333l314.453333 149.333333a59.093333 59.093333 0 0 1 31.786667 50.346667V855.466667a34.986667 34.986667 0 0 1-15.573333 30.506666 32.213333 32.213333 0 0 1-18.133334 5.12z m1.28-42.666666l-9.173333 19.2 9.386667-19.2zM149.333333 353.28v334.72a16.426667 16.426667 0 0 0 7.466667 11.52l303.573333 143.786667V508.8a16.426667 16.426667 0 0 0-7.466666-11.733333z" fill="currentColor" ></path><path d="M588.16 918.826667a31.36 31.36 0 0 1-16.853333-4.693334 33.92 33.92 0 0 1-15.146667-29.44V572.586667a55.04 55.04 0 0 1 29.866667-47.146667l283.093333-133.973333a33.706667 33.706667 0 0 1 33.066667 0 34.133333 34.133333 0 0 1 14.933333 29.44V733.866667a54.4 54.4 0 0 1-29.866667 47.146666L604.373333 915.2a40.533333 40.533333 0 0 1-16.213333 3.626667z m-2.133333-42.666667l9.173333 19.2zM874.666667 436.053333l-270.08 128a13.013333 13.013333 0 0 0-5.546667 8.533334v298.666666l270.293333-128a14.506667 14.506667 0 0 0 5.333334-9.386666z" fill="#57B8FF" ></path></symbol><symbol id="hebing" viewBox="0 0 1024 1024"><path d="M380.8 554.666667H128a21.333333 21.333333 0 1 1 0-42.666667h252.8a21.333333 21.333333 0 0 1 0 42.666667z" fill="currentColor" ></path><path d="M366.933333 429.653333v207.36L470.4 533.333333l-103.466667-103.68z" fill="currentColor" ></path><path d="M896 554.666667H644.906667a21.333333 21.333333 0 0 1 0-42.666667H896a21.333333 21.333333 0 0 1 0 42.666667z" fill="currentColor" ></path><path d="M658.773333 637.013333v-207.36L555.093333 533.333333l103.68 103.68z" fill="currentColor" ></path></symbol><symbol id="jingxiang" viewBox="0 0 1024 1024"><path d="M428.373333 139.52v745.173333H95.146667L428.373333 139.52z" fill="#57B8FF" ></path><path d="M572.373333 139.52v745.173333h333.44L572.373333 139.52z" fill="currentColor" ></path></symbol><symbol id="yanshen" viewBox="0 0 1024 1024"><path d="M836.693333 638.72h-42.666666a21.333333 21.333333 0 0 1 0-42.666667h42.666666a21.333333 21.333333 0 0 1 0 42.666667z m-128 0h-42.666666a21.333333 21.333333 0 0 1 0-42.666667h42.666666a21.333333 21.333333 0 0 1 0 42.666667z m-128 0h-42.666666a21.333333 21.333333 0 0 1 0-42.666667h42.666666a21.333333 21.333333 0 0 1 0 42.666667z m-128 0h-42.666666a21.333333 21.333333 0 0 1 0-42.666667h42.666666a21.333333 21.333333 0 0 1 0 42.666667z m-128 0h-42.666666a21.333333 21.333333 0 0 1 0-42.666667h42.666666a21.333333 21.333333 0 0 1 0 42.666667z m-128 0h-42.666666a21.333333 21.333333 0 0 1 0-42.666667h42.666666a21.333333 21.333333 0 1 1 0 42.666667z" fill="#57B8FF" ></path><path d="M671.146667 435.413333H359.893333a21.333333 21.333333 0 0 1 0-42.666666h311.253334a21.333333 21.333333 0 0 1 0 42.666666z" fill="currentColor" ></path><path d="M657.28 310.4v207.36l103.466667-103.68-103.466667-103.68zM230.4 638.72H110.72a21.333333 21.333333 0 0 1 0-42.666667h119.68a21.333333 21.333333 0 0 1 0 42.666667zM878.72 917.333333a21.333333 21.333333 0 0 1-21.333333-21.333333V128a21.333333 21.333333 0 0 1 42.666666 0v768a21.333333 21.333333 0 0 1-21.333333 21.333333z" fill="currentColor" ></path></symbol><symbol id="jianqie" viewBox="0 0 1024 1024"><path d="M568.106667 534.613333H554.666667a21.333333 21.333333 0 0 1 0-42.666666h13.653333a21.333333 21.333333 0 0 1 0 42.666666z m-98.986667 0H448a21.333333 21.333333 0 0 1 0-42.666666h21.333333a21.333333 21.333333 0 0 1 0 42.666666z m-106.666667 0H341.333333a21.333333 21.333333 0 1 1 0-42.666666h21.333334a21.333333 21.333333 0 0 1 0 42.666666z m-106.666666 0H234.666667a21.333333 21.333333 0 1 1 0-42.666666h21.333333a21.333333 21.333333 0 0 1 0 42.666666z m-106.666667 0H128a21.333333 21.333333 0 1 1 0-42.666666h21.333333a21.333333 21.333333 0 0 1 0 42.666666z" fill="#57B8FF" ></path><path d="M872.96 534.613333h-42.666667a21.333333 21.333333 0 0 1 0-42.666666h42.666667a21.333333 21.333333 0 0 1 0 42.666666z m-85.333333 0h-42.666667a21.333333 21.333333 0 0 1 0-42.666666h42.666667a21.333333 21.333333 0 0 1 0 42.666666z m-85.333334 0h-42.666666a21.333333 21.333333 0 0 1 0-42.666666h42.666666a21.333333 21.333333 0 0 1 0 42.666666zM362.666667 917.333333a21.333333 21.333333 0 0 1-10.88-2.986666 21.333333 21.333333 0 0 1-7.466667-29.226667l451.626667-768a21.333333 21.333333 0 0 1 36.906666 21.333333l-451.84 768A21.333333 21.333333 0 0 1 362.666667 917.333333z" fill="currentColor" ></path></symbol><symbol id="zhenlie" viewBox="0 0 1024 1024"><path d="M442.026667 618.666667a2.346667 2.346667 0 0 1 2.346666 2.133333v271.146667a2.346667 2.346667 0 0 1-2.346666 2.133333H173.866667a2.346667 2.346667 0 0 1-2.346667-2.133333V620.8a2.346667 2.346667 0 0 1 2.346667-2.133333h268.16m0-42.666667H173.866667A45.013333 45.013333 0 0 0 128 620.8v271.146667a45.013333 45.013333 0 0 0 45.013333 44.8h269.013334a44.8 44.8 0 0 0 45.013333-44.8V620.8a44.8 44.8 0 0 0-45.013333-44.8z" fill="#57B8FF" ></path><path d="M442.026667 168.746667a2.346667 2.346667 0 0 1 2.346666 2.346666v270.933334a2.346667 2.346667 0 0 1-2.346666 2.346666H173.866667a2.346667 2.346667 0 0 1-3.2-2.346666V170.666667a2.346667 2.346667 0 0 1 2.346666-2.346667h269.013334m0-42.666667H173.866667A45.226667 45.226667 0 0 0 128 170.666667v270.933333a45.226667 45.226667 0 0 0 45.013333 45.013333h269.013334a45.013333 45.013333 0 0 0 45.013333-45.013333V170.666667a45.013333 45.013333 0 0 0-45.013333-45.013334z" fill="currentColor" ></path><path d="M894.72 168.746667A2.133333 2.133333 0 0 1 896 170.666667v270.933333a2.133333 2.133333 0 0 1-2.133333 2.346667H626.346667a2.346667 2.346667 0 0 1-2.133334-2.346667V170.666667a2.346667 2.346667 0 0 1 2.133334-2.346667h268.373333m0-42.666667H626.346667A45.013333 45.013333 0 0 0 581.546667 170.666667v270.933333a45.013333 45.013333 0 0 0 44.8 45.013333h268.373333A45.013333 45.013333 0 0 0 938.666667 442.026667V170.666667a45.013333 45.013333 0 0 0-44.8-45.013334zM889.6 618.666667a2.346667 2.346667 0 0 1 2.346667 2.133333v271.146667a2.346667 2.346667 0 0 1-2.346667 2.133333H621.44a2.133333 2.133333 0 0 1-2.133333-2.133333V620.8a2.133333 2.133333 0 0 1 2.133333-2.133333H889.6m0-42.666667H621.44A44.8 44.8 0 0 0 576 620.8v271.146667a44.8 44.8 0 0 0 44.8 44.8h268.8a44.8 44.8 0 0 0 45.013333-44.8V620.8A44.8 44.8 0 0 0 889.6 576z" fill="#57B8FF" ></path></symbol><symbol id="pianyi" viewBox="0 0 1024 1024"><path d="M849.706667 929.066667H177.706667a69.333333 69.333333 0 0 1-69.333334-69.333334V187.733333a69.546667 69.546667 0 0 1 69.333334-69.333333h672a69.333333 69.333333 0 0 1 69.333333 69.333333v672a69.12 69.12 0 0 1-69.333333 69.333334z m-672-768A26.88 26.88 0 0 0 151.04 187.733333v672a26.666667 26.666667 0 0 0 26.666667 26.666667h672a26.666667 26.666667 0 0 0 26.666666-26.666667V187.733333a26.88 26.88 0 0 0-26.666666-26.666666z" fill="currentColor" ></path><path d="M738.773333 793.6h-95.573333a21.333333 21.333333 0 1 1 0-42.666667h95.573333v1.28a21.333333 21.333333 0 0 1 0 40.106667z m-183.466666 0h-87.893334a21.333333 21.333333 0 1 1 0-42.666667H554.666667a21.333333 21.333333 0 0 1 0 42.666667z m-175.786667 0h-83.2a51.84 51.84 0 0 1-8.106667 0 21.333333 21.333333 0 1 1 6.826667-42.666667h85.333333a21.333333 21.333333 0 0 1 0 42.666667z m382.72-70.4a21.333333 21.333333 0 0 1-21.333333-21.333333v-87.893334a21.333333 21.333333 0 1 1 42.666666 0v87.893334a21.333333 21.333333 0 0 1-21.333333 21.333333z m-496.853333-4.48a21.333333 21.333333 0 0 1-21.333334-21.333333v-87.893334a21.333333 21.333333 0 0 1 42.666667 0v87.893334a21.333333 21.333333 0 0 1-21.333333 21.333333z m496.853333-170.666667a21.333333 21.333333 0 0 1-21.333333-21.333333v-88.746667a21.333333 21.333333 0 0 1 42.666666 0v87.893334a21.333333 21.333333 0 0 1-21.333333 21.333333z m-496.853333-4.266666a21.333333 21.333333 0 0 1-21.333334-21.333334v-88.746666a21.333333 21.333333 0 0 1 42.666667 0v87.893333a21.333333 21.333333 0 0 1-21.333333 21.333333z m496.853333-170.666667a21.333333 21.333333 0 0 1-21.333333-21.333333v-45.44a10.026667 10.026667 0 0 0-8.32-9.6 21.333333 21.333333 0 0 1-17.92-24.106667 21.333333 21.333333 0 0 1 24.106666-18.133333 52.906667 52.906667 0 0 1 44.8 51.84v43.733333a21.333333 21.333333 0 0 1-21.333333 21.333333z m-496.853333-4.266667a21.333333 21.333333 0 0 1-21.333334-21.333333v-41.173333a52.48 52.48 0 0 1 52.053334-52.266667 21.333333 21.333333 0 0 1 0 42.666667 9.6 9.6 0 0 0-9.6 9.6v39.466666a21.333333 21.333333 0 0 1-21.12 21.333334z m382.506666-70.4h-87.893333a21.333333 21.333333 0 0 1 0-42.666666h87.893333a21.333333 21.333333 0 0 1 0 42.666666z m-175.786666 0H384a21.333333 21.333333 0 0 1 0-42.666666h88.106667a21.333333 21.333333 0 0 1 0 42.666666z" fill="#57B8FF" ></path></symbol><symbol id="xuanzhuan" viewBox="0 0 1024 1024"><path d="M512 912a380.586667 380.586667 0 0 1-12.8-760.96 21.333333 21.333333 0 0 1 0 42.666667A337.92 337.92 0 1 0 853.333333 531.413333a334.08 334.08 0 0 0-42.666666-162.346666 21.333333 21.333333 0 0 1 8.32-29.013334 21.333333 21.333333 0 0 1 29.013333 8.32A378.026667 378.026667 0 0 1 896 531.413333a384 384 0 0 1-384 380.586667z" fill="currentColor" ></path><path d="M493.013333 69.333333l-15.146666 206.933334 110.933333-96-95.786667-110.933334z" fill="currentColor" ></path></symbol><symbol id="guanyu" viewBox="0 0 1024 1024"><path d="M512 928.64A416.64 416.64 0 1 1 928 512 416.853333 416.853333 0 0 1 512 928.64z m0-790.613333A373.973333 373.973333 0 1 0 885.333333 512 373.973333 373.973333 0 0 0 512 138.026667z" fill="currentColor" ></path><path d="M459.733333 780.8a49.066667 49.066667 0 0 1 15.36-36.906667 51.626667 51.626667 0 0 1 37.12-14.933333 51.2 51.2 0 0 1 36.906667 87.466667 47.786667 47.786667 0 0 1-34.986667 15.573333 52.693333 52.693333 0 0 1-39.253333-15.146667 48.853333 48.853333 0 0 1-15.146667-36.053333zM552.96 192l-9.386667 451.413333h-65.066666L469.333333 192z" fill="#57B8FF" ></path></symbol><symbol id="shezhi" viewBox="0 0 1024 1024"><path d="M928 559.573333v-95.146666L818.986667 426.666667 789.333333 356.053333l49.706667-104.533333-66.56-67.413333-104.533333 50.56-69.546667-29.653334-38.826667-109.013333h-95.146666L426.666667 205.013333 356.053333 234.666667l-104.533333-49.706667-67.413333 66.56 50.56 104.533333L205.013333 426.666667 96 464.426667v95.146666l109.013333 38.826667L234.666667 667.946667l-49.706667 104.533333 67.413333 67.413333L356.053333 789.333333 426.666667 818.986667l38.826666 109.013333h95.146667l38.826667-109.013333L667.946667 789.333333l104.533333 49.706667 67.413333-67.413333L789.333333 667.946667l28.8-69.546667zM512 681.386667A169.386667 169.386667 0 1 1 681.386667 512 169.6 169.6 0 0 1 512 681.386667z" fill="currentColor" ></path></symbol><symbol id="a-9-10huiGISLineString" viewBox="0 0 1024 1024"><path d="M381.226667 538.773333L665.386667 254.570667l143.786666 143.765333-284.224 284.202667zM845.013333 365.226667l-143.573333-143.786667 64-65.28a45.653333 45.653333 0 0 1 64 0l79.786667 80a45.013333 45.013333 0 0 1 0 64z" fill="currentColor" ></path><path d="M390.186667 577.28l48.213333 48.213333 48.213333 48.213334-75.733333 24.96-64 21.333333s-2.56-1.92-2.986667-1.92l21.333334-65.28 24.96-75.733333m-8.96-38.4l-35.626667 106.666666-21.333333 65.28a23.893333 23.893333 0 0 0 22.613333 29.226667 17.92 17.92 0 0 0 5.76 0l64-21.333333 106.666667-35.626667-71.68-71.893333-71.893334-71.893334z" fill="currentColor" ></path><path d="M348.224 662.549333l13.738667-13.717333 55.978666 55.957333-13.738666 13.717334z" fill="currentColor" ></path><path d="M482.346667 486.186667a27.52 27.52 0 0 0-21.333334 8.32 31.786667 31.786667 0 0 0-4.693333 32A115.84 115.84 0 0 0 490.666667 576a141.866667 141.866667 0 0 0 42.666666 29.013333 31.146667 31.146667 0 0 0 37.76-4.266666 27.946667 27.946667 0 0 0 8.533334-14.72 17.493333 17.493333 0 0 0-3.84-14.08l-22.826667-22.613334a11.093333 11.093333 0 0 0-7.893333-4.053333 11.306667 11.306667 0 0 0-8.106667 4.053333l-4.053333 3.84-4.053334-3.84 33.493334-33.493333 4.053333 4.053333-3.413333 3.413334a9.386667 9.386667 0 0 0 0 14.506666l33.493333 33.493334-3.413333 1.28a10.666667 10.666667 0 0 0-2.773334 2.133333 18.133333 18.133333 0 0 0-2.346666 2.986667 8.533333 8.533333 0 0 0 0 4.266666 35.626667 35.626667 0 0 1-3.626667 13.013334 49.92 49.92 0 0 1-8.533333 11.093333 42.666667 42.666667 0 0 1-46.933334 11.52 115.2 115.2 0 0 1-48.426666-29.653333 110.933333 110.933333 0 0 1-31.36-53.333334 45.013333 45.013333 0 0 1 7.68-43.946666 33.28 33.28 0 0 1 11.306666-7.253334 59.52 59.52 0 0 0 8.746667-4.693333 13.44 13.44 0 0 0 2.986667-5.12 12.8 12.8 0 0 0 0-6.4l35.626666 23.466667-2.56 5.333333a70.826667 70.826667 0 0 0-30.506666-9.813333zM535.466667 421.76l-15.36 15.36-4.053334-4.053333 53.546667-53.546667 3.84 4.053333-15.36 15.36a10.666667 10.666667 0 0 0-3.413333 6.4 6.826667 6.826667 0 0 0 2.346666 5.546667l95.573334 95.573333a6.826667 6.826667 0 0 0 5.546666 2.346667 9.6 9.6 0 0 0 5.76-2.986667l15.36-15.36 4.053334 4.053334-53.546667 53.333333-3.84-4.053333 15.36-15.36a8.746667 8.746667 0 0 0 3.2-5.973334 8.32 8.32 0 0 0-2.56-5.333333l-95.573333-95.36a7.04 7.04 0 0 0-5.333334-2.773333 8.746667 8.746667 0 0 0-5.546666 2.773333zM717.013333 375.68a94.933333 94.933333 0 0 0-32 7.253333 144.64 144.64 0 0 1-38.613333 10.666667 33.28 33.28 0 0 1-25.386667-11.946667 38.4 38.4 0 0 1-10.666666-27.306666 42.666667 42.666667 0 0 1 14.506666-32.853334 47.573333 47.573333 0 0 1 15.146667-10.24 42.666667 42.666667 0 0 0 10.88-6.4 8.96 8.96 0 0 0 2.773333-4.693333 12.373333 12.373333 0 0 0 0-6.613333L682.666667 318.293333l-2.133334 4.48a68.906667 68.906667 0 0 0-31.36-6.613333 36.266667 36.266667 0 0 0-21.333333 11.306667A26.88 26.88 0 0 0 618.666667 352a37.12 37.12 0 0 0 10.24 19.626667 21.333333 21.333333 0 0 0 16 7.253333 132.906667 132.906667 0 0 0 36.693333-10.666667 85.333333 85.333333 0 0 1 38.186667-7.893333 42.666667 42.666667 0 0 1 26.666666 12.586667 42.666667 42.666667 0 0 1-1.92 64 46.72 46.72 0 0 1-14.72 9.813333 38.826667 38.826667 0 0 0-11.52 6.826667 9.6 9.6 0 0 0-2.56 5.333333c0 2.133333 0 4.906667-1.28 7.893333L676.266667 439.466667l2.773333-5.333334a59.946667 59.946667 0 0 0 36.053333 10.026667 42.666667 42.666667 0 0 0 25.386667-12.8 29.866667 29.866667 0 0 0 10.24-23.68 40.96 40.96 0 0 0-13.653333-24.96 26.24 26.24 0 0 0-20.053334-7.04z" fill="#FF9800" ></path><path d="M632.106667 909.013333l-448-128a21.333333 21.333333 0 1 1 11.733333-40.96l428.586667 121.6L768 760.96a21.333333 21.333333 0 0 1 24.533333 34.773333z" fill="#57B8FF" ></path><path d="M843.093333 733.866667A389.76 389.76 0 0 0 789.333333 846.72l-17.066666-62.506667L718.72 746.666667a388.053333 388.053333 0 0 0 124.373333-12.8z" fill="#57B8FF" ></path></symbol><symbol id="a-9-6OSMditu" viewBox="0 0 1024 1024"><path d="M358.826667 786.773333c0 74.24-42.666667 139.946667-128 139.946667-79.786667 0-124.16-61.44-124.16-138.666667s45.866667-138.453333 128-138.453333c76.373333 0 124.16 56.533333 124.16 137.173333zM149.333333 786.986667c0 57.173333 28.373333 106.666667 85.333334 106.666666 60.586667 0 84.266667-49.92 84.266666-106.666666S290.346667 682.666667 232.746667 682.666667 149.333333 730.453333 149.333333 786.986667zM434.133333 847.146667a59.733333 59.733333 0 0 0 66.346667 47.573333c39.893333 0 55.893333-18.346667 55.893333-42.666667s-13.226667-40.106667-65.706666-52.693333c-65.28-15.786667-86.613333-38.4-86.613334-75.946667 0-41.386667 30.506667-73.813333 91.52-73.813333 65.493333 0 92.373333 37.333333 96 73.386667h-40.746666c-4.266667-21.333333-18.133333-42.666667-56.746667-42.666667-30.933333 0-48.64 13.866667-48.64 38.186667s14.506667 33.493333 61.013333 44.8c77.226667 18.56 91.306667 48.426667 91.306667 83.626666 0 44.373333-33.066667 78.506667-100.053333 78.506667s-98.346667-36.48-104.106667-79.146667zM878.506667 810.666667c0-49.28 0-100.266667 1.706666-129.066667h-1.706666c-11.733333 45.866667-52.053333 156.586667-82.133334 241.28h-35.2c-22.826667-69.973333-64-194.346667-76.586666-241.706667H682.666667c2.133333 31.146667 3.2 90.026667 3.2 136.32v105.386667h-36.906667V653.44h59.52c28.8 81.066667 64 185.173333 72.746667 220.586667 6.4-27.733333 48-141.44 77.866666-220.586667H917.333333v269.44h-38.826666z" fill="currentColor" ></path><path d="M680.533333 246.613333A164.266667 164.266667 0 0 0 512 87.04a164.266667 164.266667 0 0 0-168.533333 159.573333A153.813333 153.813333 0 0 0 384 349.866667l50.346667 80.853333L512 554.666667l78.08-123.946667L640 350.506667a153.813333 153.813333 0 0 0 40.533333-103.893334z" fill="#57B8FF" ></path><path d="M418.346667 238.72a94.933333 90.666667 0 1 0 189.866666 0 94.933333 90.666667 0 1 0-189.866666 0Z" fill="currentColor" ></path></symbol><symbol id="a-9-4tiandituditu" viewBox="0 0 1024 1024"><path d="M512 932.906667A420.906667 420.906667 0 1 1 932.906667 512 421.333333 421.333333 0 0 1 512 932.906667z m0-816.426667A395.52 395.52 0 1 0 907.52 512 395.946667 395.946667 0 0 0 512 116.48z" fill="currentColor" ></path><path d="M502.826667 407.04a533.333333 533.333333 0 0 1-342.613334-128l17.706667-18.133333c11.733333 11.306667 288.853333 272 668.373333-1.28l14.72 21.333333c-132.693333 94.08-254.506667 126.08-358.186666 126.08zM175.573333 765.653333l-14.933333-21.333333c397.013333-285.866667 697.813333-1.706667 700.8 1.28l-17.706667 18.133333C832 753.28 554.666667 492.373333 175.573333 765.653333z" fill="currentColor" ></path><path d="M312.533333 864l-11.733333-16.213333c238.506667-171.946667 419.626667 0 421.333333 0l-13.866666 14.506666c-7.04-5.76-171.093333-160-395.733334 1.706667zM527.573333 246.186667A364.8 364.8 0 0 1 312.32 170.666667l11.733333-16.426667c224.853333 161.92 388.906667 7.68 395.733334 1.066667l14.08 14.293333a320 320 0 0 1-206.293334 76.586667z" fill="currentColor" ></path><path d="M380.373333 908.8C256 792.96 193.28 664.96 192 528.426667c0-233.386667 179.84-406.613333 187.52-413.866667l17.066667 17.92c-1.706667 1.706667-180.48 173.653333-179.626667 396.16 0 129.28 60.8 251.093333 179.626667 362.666667zM642.986667 908.8l-17.066667-18.133333c118.826667-110.933333 179.2-232.746667 179.84-362.666667 0-222.506667-178.133333-394.453333-179.84-396.16l17.066667-17.92c7.68 7.253333 188.373333 180.48 187.52 413.866667-0.426667 137.173333-62.506667 265.173333-187.52 381.013333z" fill="currentColor" ></path><path d="M528.213333 925.226667l-17.706666-18.773334c123.306667-115.2 186.24-241.706667 186.666666-376.106666C698.026667 298.666667 512 120.96 510.506667 119.253333l17.706666-18.773333c7.893333 7.466667 195.626667 187.52 194.773334 429.866667-0.426667 141.866667-65.92 274.773333-194.773334 394.88z" fill="currentColor" ></path><path d="M507.093333 923.946667c-128-120.32-194.56-253.226667-194.986666-395.093334C311.466667 286.506667 498.986667 106.666667 506.88 98.986667l17.92 18.773333c-1.92 1.706667-187.52 180.266667-186.88 411.306667 0 134.4 64 260.906667 186.666667 375.893333z" fill="currentColor" ></path><path d="M203.733333 576v-5.546667c11.52-1.28 12.16-2.346667 12.16-16v-58.88L181.973333 576h-5.12c-9.813333-24.746667-21.333333-52.906667-31.573333-79.573333-1.92 47.786667-1.92 57.173333-1.92 62.506666s3.2 10.453333 14.506667 11.52V576H120.32v-5.546667c8.533333 0 12.586667-2.56 13.653333-11.52 0-4.693333 1.28-13.226667 4.906667-64 0-7.466667 0-11.52-13.866667-12.8v-5.546666H157.866667l29.44 66.986666 29.44-66.986666h32v5.546666c-12.16 1.28-13.44 2.56-13.226667 14.72L236.8 554.666667c0 13.653333 0 14.293333 13.013333 16V576z" fill="#57B8FF" ></path><path d="M296.106667 578.346667a14.506667 14.506667 0 0 1-9.386667-3.2 17.92 17.92 0 0 1-4.053333-5.76 57.6 57.6 0 0 1-16 8.96 20.053333 20.053333 0 0 1-21.333334-19.626667c0-8.106667 3.626667-11.733333 11.733334-14.933333a141.653333 141.653333 0 0 0 25.173333-10.453334v-6.613333c0-7.893333-2.986667-12.373333-9.6-12.373333a7.466667 7.466667 0 0 0-5.973333 2.986666 26.026667 26.026667 0 0 0-3.626667 10.026667 6.186667 6.186667 0 0 1-7.04 5.973333 9.386667 9.386667 0 0 1-8.96-7.893333c0-2.56 1.92-4.693333 5.333333-7.04a78.506667 78.506667 0 0 1 24.96-11.306667 26.88 26.88 0 0 1 15.573334 4.48 21.333333 21.333333 0 0 1 8.533333 18.773334v26.24c0 7.253333 2.346667 9.173333 4.693333 9.173333a12.8 12.8 0 0 0 4.693334-1.28l1.706666 5.12z m-13.866667-38.4l-8.533333 4.693333c-4.906667 2.56-7.466667 5.12-7.466667 10.453333a10.24 10.24 0 0 0 9.173333 11.52 8.96 8.96 0 0 0 6.826667-2.56z" fill="#57B8FF" ></path><path d="M305.066667 512a251.306667 251.306667 0 0 0 27.946666-6.826667v10.88s10.24-5.973333 10.666667-6.186666a21.333333 21.333333 0 0 1 9.813333-3.2 28.16 28.16 0 0 1 26.453334 30.08 42.666667 42.666667 0 0 1-37.333334 41.173333 24.533333 24.533333 0 0 1-9.6-1.493333v18.346666c0 8.533333 0 9.386667 11.306667 10.666667v5.12h-40.746667v-4.693333c9.173333 0 9.813333-2.133333 9.813334-10.453334v-67.84c0-8.32 0-9.173333-8.32-10.026666z m27.946666 52.906667a21.333333 21.333333 0 0 0 12.586667 5.76c7.893333 0 13.866667-10.026667 13.866667-26.453334s-9.173333-25.813333-16.853334-25.813333a15.786667 15.786667 0 0 0-9.6 3.413333z" fill="#57B8FF" ></path><path d="M480 514.133333c-7.253333 1.28-8.32 2.133333-11.52 10.24-5.546667 14.08-12.16 32.64-19.413333 53.76h-6.4c-5.546667-14.08-11.946667-28.8-17.706667-42.666666-5.76 14.293333-11.306667 27.733333-16.853333 42.666666h-6.186667c-5.973333-18.773333-12.586667-37.546667-18.133333-54.613333-2.773333-7.253333-3.413333-8.533333-10.666667-9.386667v-5.12h38.4v5.12c-8.746667 1.28-9.813333 2.773333-8.106667 7.68 2.986667 9.813333 5.973333 20.053333 8.96 29.226667 5.546667-13.226667 11.093333-28.16 15.786667-41.386667h6.4c5.12 13.653333 11.093333 28.16 17.066667 42.666667 2.56-7.466667 7.68-21.333333 9.173333-28.8s0-7.68-11.093333-8.746667v-5.12h30.293333z" fill="#57B8FF" ></path><path d="M507.946667 507.093333a33.706667 33.706667 0 0 1 34.986666 34.346667 35.84 35.84 0 1 1-71.466666 1.706667 35.84 35.84 0 0 1 36.48-36.053334z m-1.706667 6.186667c-6.613333 0-13.013333 6.826667-13.013333 25.386667s6.4 33.493333 15.786666 33.493333c5.973333 0 12.16-4.053333 12.16-26.24s-5.546667-32.64-14.933333-32.64z" fill="#57B8FF" ></path><path d="M581.12 576h-40.32v-5.12c8.106667 0 8.96-1.706667 8.96-10.88v-32.853333c0-7.466667 0-8.32-7.893333-9.813334V512a154.026667 154.026667 0 0 0 27.52-5.76v16.426667c6.826667-10.453333 12.16-16.213333 18.56-16.213334a9.173333 9.173333 0 0 1 9.813333 9.173334 15.146667 15.146667 0 0 1-7.68 13.013333 4.266667 4.266667 0 0 1-4.693333 0c-2.773333-2.133333-4.693333-4.48-7.253334-4.48s-5.973333 1.92-8.746666 7.68v28.8c0 9.173333 0 9.6 11.733333 10.88z" fill="#57B8FF" ></path><path d="M669.44 572.586667a264.32 264.32 0 0 0-29.653333 5.76v-8.746667l-9.386667 5.973333a13.866667 13.866667 0 0 1-7.68 2.773334 32.64 32.64 0 0 1-31.146667-33.706667 39.68 39.68 0 0 1 42.666667-37.546667 38.4 38.4 0 0 1 6.186667 0V490.666667c0-7.893333 0-8.746667-10.24-10.026667v-4.906667a205.866667 205.866667 0 0 0 29.866666-5.12v87.253334c0 8.32 1.066667 8.96 6.826667 9.813333h3.2zM640 521.6a12.16 12.16 0 0 0-11.52-7.68c-4.693333 0-14.933333 3.2-14.933333 25.386667s11.093333 27.093333 17.92 27.306666a14.506667 14.506667 0 0 0 8.533333-2.56zM789.333333 534.826667c-8.533333 1.493333-9.6 2.133333-9.6 12.373333v11.733333a77.013333 77.013333 0 0 0 0 14.72 216.533333 216.533333 0 0 1-36.906666 5.12 50.56 50.56 0 0 1-56.106667-51.84c0-34.133333 27.733333-51.413333 60.16-51.413333a252.373333 252.373333 0 0 1 30.72 3.413333c0 6.826667 1.493333 18.346667 2.56 26.666667l-5.973333 1.066667a28.8 28.8 0 0 0-18.56-22.613334 44.8 44.8 0 0 0-13.013334-1.92c-18.346667 0-32.213333 16-32.213333 42.666667s9.386667 47.786667 34.346667 47.786667a19.84 19.84 0 0 0 9.813333-2.133334c2.133333-1.28 3.413333-3.84 3.413333-8.533333v-13.44c0-10.666667-2.133333-11.733333-14.933333-13.226667v-5.546666H789.333333zM789.333333 576v-5.546667c11.52-1.066667 12.8-1.92 12.8-14.72v-57.6c0-12.8-1.493333-13.866667-12.8-14.933333v-5.546667h46.933334v5.546667c-11.52 1.066667-13.013333 2.133333-13.013334 14.933333v58.026667c0 12.586667 1.493333 13.44 13.013334 14.72V576zM894.08 502.826667c-2.986667-9.813333-7.253333-21.333333-21.333333-21.333334a13.866667 13.866667 0 0 0-14.506667 14.72c0 8.32 5.546667 13.44 18.986667 20.053334s26.453333 16 26.453333 31.146666a32.64 32.64 0 0 1-36.48 30.933334 87.04 87.04 0 0 1-25.6-4.693334c0-3.626667-3.413333-19.413333-4.48-26.453333l5.76-1.493333c3.2 9.6 11.733333 26.24 26.453333 26.24a14.08 14.08 0 0 0 14.933334-15.573334c0-8.746667-5.333333-13.866667-18.133334-21.333333s-26.24-16.213333-26.24-32 13.44-27.52 34.773334-27.52a110.293333 110.293333 0 0 1 21.333333 2.773333c0 5.546667 1.706667 13.44 2.986667 23.04z" fill="#57B8FF" ></path><path d="M513.706667 180.053333a103.466667 103.466667 0 0 0-106.666667 100.48 97.493333 97.493333 0 0 0 25.386667 64l31.573333 50.773334 48.64 78.293333 49.066667-78.08 31.786666-50.56a97.28 97.28 0 0 0 25.6-65.493333 103.253333 103.253333 0 0 0-105.386666-99.413334zM512 331.946667a50.346667 50.346667 0 1 1 52.48-50.346667A51.413333 51.413333 0 0 1 512 331.946667z" fill="#57B8FF" ></path></symbol><symbol id="a-9-5baiduditu" viewBox="0 0 1024 1024"><path d="M572.8 105.386667h-1.493333a119.253333 119.253333 0 0 1-28.586667-3.413334h-42.666667A116.266667 116.266667 0 0 1 469.333333 106.666667a129.706667 129.706667 0 0 1-13.013333 0 109.653333 109.653333 0 0 1-36.906667 5.973333 102.826667 102.826667 0 0 1-46.293333 14.08 92.8 92.8 0 0 1-16 4.48 90.026667 90.026667 0 0 1-40.533333 21.333333 93.226667 93.226667 0 0 1-38.4 20.053334 92.586667 92.586667 0 0 1-36.48 26.666666 38.4 38.4 0 0 1-4.266667 4.053334A93.866667 93.866667 0 0 1 211.2 230.4a99.84 99.84 0 0 1-24.746667 27.093333A103.68 103.68 0 0 1 170.666667 277.333333a102.826667 102.826667 0 0 1-21.333334 32.213334 102.613333 102.613333 0 0 1-11.52 21.333333 103.04 103.04 0 0 1-21.333333 39.893333 117.333333 117.333333 0 0 1-12.373333 41.6 133.76 133.76 0 0 1-6.186667 22.4 129.92 129.92 0 0 1-4.693333 21.333334 111.573333 111.573333 0 0 1-2.133334 27.946666v54.826667a121.813333 121.813333 0 0 1 2.133334 30.506667 117.973333 117.973333 0 0 1 2.346666 19.2 121.386667 121.386667 0 0 1 2.56 21.333333c0 2.56 1.706667 4.906667 2.346667 7.466667L606.506667 112.853333a104.106667 104.106667 0 0 1-33.706667-7.466666zM922.88 445.013333c-2.133333-11.52-3.84-23.253333-5.12-34.986666v-2.773334a117.76 117.76 0 0 1-14.08-50.133333l-1.28-2.986667-183.466667 54.613334L565.333333 256 334.293333 486.186667l234.666667 234.666666 160.426667 160.426667a90.666667 90.666667 0 0 1 29.866666-21.333333 95.36 95.36 0 0 1 27.733334-23.253334l1.493333-1.28a93.866667 93.866667 0 0 1 13.013333-11.093333 94.293333 94.293333 0 0 1 38.4-39.68h1.706667a98.986667 98.986667 0 0 1 19.84-30.506667 98.773333 98.773333 0 0 1 6.613333-10.88 100.906667 100.906667 0 0 1 14.506667-23.68 94.293333 94.293333 0 0 1 7.253333-11.52 42.666667 42.666667 0 0 1 1.706667-4.693333 124.586667 124.586667 0 0 1 4.266667-12.586667 111.786667 111.786667 0 0 1 16.426666-38.826666 143.146667 143.146667 0 0 1 2.773334-21.333334 128 128 0 0 1 4.266666-14.72 213.333333 213.333333 0 0 0 6.4-28.586666c0-3.84 0-7.893333 1.493334-11.946667a164.693333 164.693333 0 0 1 3.626666-21.333333V469.333333a85.333333 85.333333 0 0 1-7.893333-24.32zM545.066667 941.013333a112.426667 112.426667 0 0 1 23.253333-4.053333 109.013333 109.013333 0 0 1 40.533333-7.466667h7.893334a95.786667 95.786667 0 0 1 42.666666-14.72L284.586667 540.373333l-155.306667 155.306667a96.853333 96.853333 0 0 1 4.48 9.6 108.373333 108.373333 0 0 1 12.8 26.453333 110.293333 110.293333 0 0 1 15.786667 23.466667 97.92 97.92 0 0 1 18.346666 26.453333 94.08 94.08 0 0 1 29.653334 33.28 94.293333 94.293333 0 0 1 25.6 24.746667 92.586667 92.586667 0 0 1 33.92 26.24 92.586667 92.586667 0 0 1 42.666666 25.386667 94.72 94.72 0 0 1 39.04 19.413333 98.56 98.56 0 0 1 31.36 10.24 110.933333 110.933333 0 0 1 32.64 7.893333h2.986667a106.666667 106.666667 0 0 1 46.08 9.813334 119.253333 119.253333 0 0 1 21.333333 2.56z" fill="currentColor" ></path><path d="M512 942.293333a420.906667 420.906667 0 1 1 420.906667-420.906666A421.333333 421.333333 0 0 1 512 942.293333zM512 106.666667a415.573333 415.573333 0 1 0 415.36 414.72A415.786667 415.786667 0 0 0 512 106.666667z" fill="currentColor" ></path><path d="M241.92 233.173333l11.733333 30.08 11.946667 30.08 19.84-23.466666 19.84-23.68-31.573333-6.613334-31.786667-6.4zM351.36 324.693333l-31.786667-6.826666-31.573333-6.826667 20.266667-23.466667 20.053333-23.253333 11.52 30.08 11.52 30.293333z" fill="currentColor" ></path><path d="M927.146667 280.106667a206.08 206.08 0 0 0-211.2-200.32 205.866667 205.866667 0 0 0-210.986667 200.32A193.28 193.28 0 0 0 554.666667 409.6l64 102.4 97.066666 155.946667L812.8 512l64-100.906667a193.28 193.28 0 0 0 50.346667-130.986666z" fill="#DF1200" ></path><path d="M552.533333 277.76a160.853333 153.813333 0 1 0 321.706667 0 160.853333 153.813333 0 1 0-321.706667 0Z" fill="#DF1200" ></path><path d="M198.4 258.986667l13.44 34.133333 13.226667 34.133333 22.4-26.666666 22.613333-26.666667-35.84-7.466667-35.84-7.466666z" fill="#57B8FF" ></path><path d="M321.92 362.666667l-35.626667-7.68-35.84-7.893334 22.826667-26.453333 22.613333-26.24 13.013334 34.133333 13.013333 34.133334z" fill="#28C259" ></path><path d="M716.586667 126.293333V366.933333h-40.96c0-4.906667-1.706667-15.146667-1.92-19.84a54.613333 54.613333 0 0 1-52.266667 23.68c-45.013333 0-73.6-34.56-73.6-87.04s30.506667-90.24 80.426667-90.24c27.306667 0 41.173333 9.813333 45.44 18.133334v-85.333334z m-124.373334 156.8c0 35.626667 15.786667 54.826667 41.173334 54.826667 36.266667 0 42.666667-27.52 42.666666-56.32s-5.76-54.4-40.533333-54.4c-28.16 0-43.306667 20.693333-43.306667 55.893333zM880 318.08v49.28h-42.666667c0-4.48 0-14.08-1.28-21.333333a51.626667 51.626667 0 0 1-50.56 25.386666 55.04 55.04 0 0 1-59.093333-62.506666v-110.933334h42.666667v102.4c0 19.84 6.613333 36.906667 30.506666 36.906667s36.266667-13.226667 36.266667-49.706667v-89.6h42.666667z" fill="currentColor" ></path></symbol><symbol id="a-9-12huiGISDrawPolygon" viewBox="0 0 1024 1024"><path d="M336.64 899.626667L106.666667 645.546667l656.213333-95.786667 99.626667 136.32-160.213334 200.96zM177.706667 671.146667l174.293333 192 332.586667-11.306667 132.906666-166.826667L746.666667 588.16z" fill="#57B8FF" ></path><path d="M348.224 522.666667L632.426667 238.506667l143.765333 143.744L491.989333 666.453333zM811.946667 349.013333l-143.786667-143.573333 65.28-65.28a45.013333 45.013333 0 0 1 64 0l80 79.786667a45.653333 45.653333 0 0 1 0 64zM357.12 561.28L405.333333 609.28l48 48.213333L377.6 682.666667l-64 21.333333a8.96 8.96 0 0 1-2.986667-2.133333l21.333334-64 25.173333-75.733334m-9.173333-38.4l-35.626667 106.666667-21.333333 65.28a23.893333 23.893333 0 0 0 21.333333 29.226667 21.333333 21.333333 0 0 0 5.973333 0l65.066667-21.333334 106.666667-35.626666-71.893334-71.893334-71.893333-71.893333z" fill="currentColor" ></path><path d="M315.072 646.442667l13.717333-13.738667 55.957334 55.978667-13.717334 13.717333z" fill="currentColor" ></path><path d="M449.28 469.333333a27.733333 27.733333 0 0 0-21.333333 8.32 33.493333 33.493333 0 0 0-4.693334 32.213334 114.986667 114.986667 0 0 0 33.493334 49.92 138.88 138.88 0 0 0 41.6 29.226666 31.146667 31.146667 0 0 0 37.76-4.48 28.373333 28.373333 0 0 0 8.746666-14.72 16.426667 16.426667 0 0 0-4.053333-13.866666L518.4 533.333333a12.373333 12.373333 0 0 0-8.106667-4.053333 11.946667 11.946667 0 0 0-7.893333 4.053333l-4.053333 4.053334-4.053334-4.053334 33.493334-33.28 3.84 3.84-3.2 3.413334a10.026667 10.026667 0 0 0-3.413334 7.466666 9.6 9.6 0 0 0 3.413334 7.253334l33.28 33.28-3.2 1.493333a8.106667 8.106667 0 0 0-2.773334 1.92 16.213333 16.213333 0 0 0-2.346666 2.986667 9.173333 9.173333 0 0 0-1.066667 4.48 31.786667 31.786667 0 0 1-3.626667 13.013333 42.666667 42.666667 0 0 1-8.32 10.88 43.946667 43.946667 0 0 1-47.146666 11.733333 116.693333 116.693333 0 0 1-48.426667-29.653333 111.573333 111.573333 0 0 1-31.36-53.546667 45.866667 45.866667 0 0 1 10.026667-45.44 45.013333 45.013333 0 0 1 11.306666-7.253333 37.76 37.76 0 0 0 8.746667-4.693333 12.586667 12.586667 0 0 0 2.986667-4.906667 13.013333 13.013333 0 0 0 0-6.4l35.413333 24.746667-2.773333 5.333333a68.266667 68.266667 0 0 0-29.866667-10.666667zM502.4 405.333333l-15.36 15.36-4.053333-4.053333 53.333333-53.333333 4.053333 4.053333-15.36 15.36a9.6 9.6 0 0 0-2.986666 5.546667 7.04 7.04 0 0 0 2.346666 5.76L619.733333 490.666667a7.466667 7.466667 0 0 0 5.76 2.346666 9.813333 9.813333 0 0 0 5.76-3.2l15.36-15.36 3.84 4.053334L597.333333 531.2l-4.053333-4.053333 15.36-15.36a9.173333 9.173333 0 0 0 3.413333-5.973334 7.04 7.04 0 0 0-2.773333-5.333333L513.706667 405.333333a8.32 8.32 0 0 0-5.333334-2.56 8.746667 8.746667 0 0 0-5.973333 2.56zM683.946667 359.466667a93.866667 93.866667 0 0 0-32 7.466666 145.706667 145.706667 0 0 1-38.826667 10.666667 33.92 33.92 0 0 1-25.386667-12.16 39.253333 39.253333 0 0 1-10.666666-27.306667 42.666667 42.666667 0 0 1 14.72-32.64 51.2 51.2 0 0 1 14.933333-10.453333 31.786667 31.786667 0 0 0 11.093333-6.4 12.16 12.16 0 0 0 2.773334-4.48 11.52 11.52 0 0 0 0-6.826667l30.08 24.746667-1.92 4.693333a69.973333 69.973333 0 0 0-31.36-6.613333 35.626667 35.626667 0 0 0-21.333334 11.306667 27.52 27.52 0 0 0-10.453333 24.32 36.693333 36.693333 0 0 0 10.453333 19.626666 22.4 22.4 0 0 0 16 7.466667 143.786667 143.786667 0 0 0 36.693334-10.666667 85.333333 85.333333 0 0 1 37.973333-8.106666 42.666667 42.666667 0 0 1 26.88 12.8 45.226667 45.226667 0 0 1 11.733333 29.653333 50.56 50.56 0 0 1-29.866666 43.733333 34.773333 34.773333 0 0 0-11.306667 6.613334 11.306667 11.306667 0 0 0-2.56 5.333333c0 2.346667 0 4.906667-1.493333 8.106667l-37.973334-27.306667 2.56-5.333333a59.52 59.52 0 0 0 36.053334 9.813333 42.666667 42.666667 0 0 0 25.386666-12.586667 29.44 29.44 0 0 0 10.453334-23.68 40.96 40.96 0 0 0-12.586667-24.96 26.24 26.24 0 0 0-20.053333-6.826666z" fill="#FF9800" ></path></symbol><symbol id="a-9-11huiGISMultLineString" viewBox="0 0 1024 1024"><path d="M366.72 525.589333l284.202667-284.202666 143.765333 143.786666-284.202667 284.181334zM830.506667 351.786667l-143.786667-143.786667 65.28-64a45.013333 45.013333 0 0 1 64 0L896 222.72a45.653333 45.653333 0 0 1 0 64zM375.68 564.053333l48.213333 48L471.893333 661.333333l-75.52 25.173334-64 21.333333c-1.066667 0-2.773333-1.706667-2.986666-1.92l21.333333-65.28 25.173333-75.52m-9.173333-38.4l-35.626667 106.666667-21.333333 64a23.893333 23.893333 0 0 0 22.4 29.226666 19.2 19.2 0 0 0 5.973333 0l64-21.333333 106.666667-35.626667-70.4-72.32-71.893333-71.893333z" fill="currentColor" ></path><path d="M333.738667 649.258667l13.738666-13.717334 55.786667 55.829334-13.717333 13.717333z" fill="currentColor" ></path><path d="M467.84 472.746667a27.733333 27.733333 0 0 0-21.333333 8.32 33.066667 33.066667 0 0 0-4.693334 32 115.413333 115.413333 0 0 0 33.493334 50.133333 135.253333 135.253333 0 0 0 42.666666 29.013333 30.506667 30.506667 0 0 0 37.546667-4.266666 28.373333 28.373333 0 0 0 8.746667-14.72 17.066667 17.066667 0 0 0-4.053334-14.08l-22.613333-22.613334a11.306667 11.306667 0 0 0-8.106667-4.053333 11.093333 11.093333 0 0 0-7.893333 4.053333l-4.053333 4.053334-5.546667-4.053334 33.493333-33.493333 3.84 4.053333-3.2 3.413334a9.6 9.6 0 0 0-3.413333 7.253333 10.026667 10.026667 0 0 0 3.413333 7.466667l33.28 33.28a11.093333 11.093333 0 0 0-3.2 1.493333 10.88 10.88 0 0 0-2.773333 1.92 16.213333 16.213333 0 0 0-2.346667 2.986667 8.32 8.32 0 0 0 0 4.266666 30.933333 30.933333 0 0 1-3.626666 13.013334 42.666667 42.666667 0 0 1-8.32 11.093333 43.733333 43.733333 0 0 1-47.146667 11.733333A116.693333 116.693333 0 0 1 463.573333 576a111.36 111.36 0 0 1-31.573333-53.546667 46.08 46.08 0 0 1 10.026667-45.44 41.173333 41.173333 0 0 1 11.52-7.253333 43.946667 43.946667 0 0 0 8.533333-4.693333 13.226667 13.226667 0 0 0 3.413333-11.306667l35.413334 24.746667-2.773334 5.333333a67.413333 67.413333 0 0 0-30.293333-11.093333zM520.96 408.32l-15.36 15.36-4.053333-4.053333 53.333333-53.333334 4.053333 4.053334-15.36 15.36a9.6 9.6 0 0 0-2.986666 5.546666 7.04 7.04 0 0 0 2.346666 5.76l95.573334 95.36a6.186667 6.186667 0 0 0 5.546666 2.346667 8.96 8.96 0 0 0 5.76-2.986667l15.36-15.36 4.053334 4.053334L615.68 533.333333l-4.053333-3.84 15.36-15.36a9.173333 9.173333 0 0 0 3.413333-5.973333 8.32 8.32 0 0 0-2.56-5.546667L533.333333 407.68a8.106667 8.106667 0 0 0-6.4-2.346667 9.6 9.6 0 0 0-5.973333 2.986667zM702.506667 362.666667a98.133333 98.133333 0 0 0-32 7.253333 140.16 140.16 0 0 1-38.826667 10.88 34.133333 34.133333 0 0 1-25.386667-12.16 39.253333 39.253333 0 0 1-10.666666-27.306667 42.666667 42.666667 0 0 1 14.72-32.64 52.053333 52.053333 0 0 1 15.146666-10.453333 32.426667 32.426667 0 0 0 10.88-6.4 9.6 9.6 0 0 0 2.773334-4.693333 12.586667 12.586667 0 0 0 0-6.613334l29.866666 24.746667-1.92 4.693333a70.826667 70.826667 0 0 0-31.36-6.826666 36.053333 36.053333 0 0 0-21.333333 11.52 27.093333 27.093333 0 0 0-10.453333 24.32 39.04 39.04 0 0 0 10.453333 19.626666 22.4 22.4 0 0 0 16 7.466667 143.786667 143.786667 0 0 0 36.693333-10.666667 83.2 83.2 0 0 1 36.906667-8.533333 42.666667 42.666667 0 0 1 26.88 12.8 46.72 46.72 0 0 1-16.853333 73.386667 37.333333 37.333333 0 0 0-11.306667 6.613333 10.453333 10.453333 0 0 0-2.56 5.333333c0 2.346667-1.066667 4.906667-1.493333 8.106667L661.333333 426.666667l2.773334-5.333334a58.026667 58.026667 0 0 0 36.053333 10.026667 42.666667 42.666667 0 0 0 25.173333-13.653333 30.506667 30.506667 0 0 0 10.24-23.68 40.96 40.96 0 0 0-13.653333-25.173334 27.093333 27.093333 0 0 0-19.413333-6.186666z" fill="#FF9800" ></path><path d="M471.466667 923.946667l-320-129.28 74.24-250.88a21.333333 21.333333 0 0 1 26.666666-14.293334 21.333333 21.333333 0 0 1 14.293334 26.453334l-64 213.333333 268.8 108.586667 349.653333-141.013334a21.333333 21.333333 0 0 1 16 39.466667z" fill="#57B8FF" ></path><path d="M900.693333 727.68a392.533333 392.533333 0 0 0-78.72 97.493333l-2.346666-64-42.666667-48.213333a386.133333 386.133333 0 0 0 123.733333 14.72z" fill="#57B8FF" ></path><path d="M183.466667 779.946667m-34.133334 0a34.133333 34.133333 0 1 0 68.266667 0 34.133333 34.133333 0 1 0-68.266667 0Z" fill="currentColor" ></path><path d="M475.093333 900.053333m-34.133333 0a34.133333 34.133333 0 1 0 68.266667 0 34.133333 34.133333 0 1 0-68.266667 0Z" fill="currentColor" ></path></symbol><symbol id="a-9-13shuchugeojson" viewBox="0 0 1024 1024"><path d="M708.693333 896H202.026667a69.76 69.76 0 0 1-71.253334-67.84V194.986667A69.76 69.76 0 0 1 202.026667 128h506.666666a69.546667 69.546667 0 0 1 71.04 67.84v339.2a21.333333 21.333333 0 1 1-40.746666 0V194.986667a28.8 28.8 0 0 0-30.293334-27.093334H202.026667A29.013333 29.013333 0 0 0 170.666667 194.986667v634.026666a29.013333 29.013333 0 0 0 30.506666 27.093334h507.52a21.333333 21.333333 0 0 1 0 40.746666z" fill="currentColor" ></path><path d="M796.373333 742.826667h-311.466666a21.333333 21.333333 0 1 1 0-42.666667h311.466666a21.333333 21.333333 0 0 1 0 42.666667z" fill="currentColor" ></path><path d="M765.44 827.733333l184.106667-106.24-184.106667-106.453333v212.693333z" fill="currentColor" ></path><path d="M264.746667 392.533333v155.52c0 42.666667-9.6 59.093333-44.373334 59.093334h-10.666666v-25.173334h5.333333c17.493333 0 20.266667-8.533333 20.266667-28.8V392.533333zM234.666667 359.253333v-33.92h29.44v33.92zM308.053333 500.693333a32.853333 32.853333 0 0 0 35.626667 24.96c21.333333 0 29.226667-8.96 29.226667-21.333333s-6.826667-19.413333-34.56-26.24c-44.586667-10.88-53.546667-24.533333-53.546667-45.44s15.786667-42.666667 56.32-42.666667 56.533333 23.253333 58.453333 44.16H371.2a27.946667 27.946667 0 0 0-31.36-21.333333c-19.84 0-25.813333 9.386667-25.813333 18.773333s5.76 15.786667 33.066666 22.4c47.146667 11.093333 55.893333 26.88 55.893334 49.493334 0 26.24-21.333333 46.506667-60.16 46.506666s-60.16-21.333333-64-47.573333zM554.666667 469.333333c0 44.16-25.6 80-72.533334 80s-71.466667-34.773333-71.466666-80 26.24-79.786667 72.533333-79.786666C526.08 388.906667 554.666667 420.48 554.666667 469.333333z m-113.28 0c0 32.64 15.786667 55.68 42.666666 55.68s41.386667-21.333333 41.386667-55.466666-14.933333-55.68-42.666667-55.68-42.026667 20.48-42.026666 55.466666zM571.946667 430.72V392.533333h28.586666c0 4.266667 1.066667 19.2 1.066667 23.893334a47.573333 47.573333 0 0 1 47.146667-27.52c29.013333 0 50.773333 18.133333 50.773333 58.026666v97.706667H669.866667v-94.08c0-21.333333-8.32-36.693333-30.506667-36.693333-26.666667 0-37.973333 19.413333-37.973333 49.28v81.493333h-29.44z" fill="#57B8FF" ></path></symbol><symbol id="a-9-9huiGISMultPoint" viewBox="0 0 1024 1024"><path d="M170.666667 666.453333m41.6 0l0 0q41.6 0 41.6 41.6l0 0q0 41.6-41.6 41.6l0 0q-41.6 0-41.6-41.6l0 0q0-41.6 41.6-41.6Z" fill="currentColor" ></path><path d="M470.4 664.746667m41.6 0l0 0q41.6 0 41.6 41.6l0 0q0 41.6-41.6 41.6l0 0q-41.6 0-41.6-41.6l0 0q0-41.6 41.6-41.6Z" fill="currentColor" ></path><path d="M770.133333 663.04m41.6 0l0 0q41.6 0 41.6 41.6l0 0q0 41.6-41.6 41.6l0 0q-41.6 0-41.6-41.6l0 0q0-41.6 41.6-41.6Z" fill="currentColor" ></path><path d="M170.666667 832.853333m41.6 0l0 0q41.6 0 41.6 41.6l0 0q0 41.6-41.6 41.6l0 0q-41.6 0-41.6-41.6l0 0q0-41.6 41.6-41.6Z" fill="currentColor" ></path><path d="M470.4 831.146667m41.6 0l0 0q41.6 0 41.6 41.6l0 0q0 41.6-41.6 41.6l0 0q-41.6 0-41.6-41.6l0 0q0-41.6 41.6-41.6Z" fill="currentColor" ></path><path d="M770.133333 829.226667m41.6 0l0 0q41.6 0 41.6 41.6l0 0q0 41.6-41.6 41.6l0 0q-41.6 0-41.6-41.6l0 0q0-41.6 41.6-41.6Z" fill="currentColor" ></path><path d="M512 145.706667c-145.706667 0-263.68 112-263.68 250.026666a240.853333 240.853333 0 0 0 62.72 161.493334l78.72 126.506666 120.96 194.56 122.026667-193.92 79.36-126.08a241.92 241.92 0 0 0 64-162.56C775.68 257.706667 657.706667 145.706667 512 145.706667z m-3.626667 375.68a145.066667 145.066667 0 1 1 144.64-145.066667 145.066667 145.066667 0 0 1-144.64 145.066667z" fill="#57B8FF" ></path></symbol><symbol id="a-9-2gaodeshiliang" viewBox="0 0 1024 1024"><path d="M542.293333 941.866667a149.333333 149.333333 0 0 1-69.973333-16.213334l-4.266667-2.986666-99.626666-89.6a55.04 55.04 0 0 0-45.013334-10.666667l-9.6 1.28-116.906666 48C150.613333 875.733333 106.666667 860.586667 85.333333 834.346667a50.986667 50.986667 0 0 1-8.32-49.706667l78.08-213.333333c11.52-31.36 52.693333-52.48 102.826667-53.12l443.093333-4.693334c48.213333 0 90.453333 18.986667 104.533334 48.64L938.666667 784.426667A51.413333 51.413333 0 0 1 938.666667 832a97.066667 97.066667 0 0 1-70.4 42.666667l-293.973334 64a161.28 161.28 0 0 1-32 3.2z m-47.573333-52.693334a117.76 117.76 0 0 0 71.253333 7.68l293.76-64a56.96 56.96 0 0 0 40.746667-21.333333 7.253333 7.253333 0 0 0 0-7.466667L768 582.4c-6.4-13.866667-32-26.026667-64-26.026667h-2.133333l-443.093334 4.693334c-33.493333 0-58.88 13.226667-64 24.96l-78.08 213.333333c0 1.493333-1.493333 4.266667 2.133334 8.96a87.466667 87.466667 0 0 0 70.4 21.333333l116.48-47.786666 11.306666-1.28a97.28 97.28 0 0 1 74.24 17.28l3.413334 2.346666z" fill="currentColor" ></path><path d="M878.293333 77.44L131.2 406.613333l168.32 104.533334L863.573333 97.92l6.826667-5.76-476.8 465.493333-42.24 144.64 131.413333-87.04 233.386667 146.346667 171.093333-688.213333-8.96 4.053333z" fill="#57B8FF" ></path></symbol><symbol id="a-9-8huiGISPoint" viewBox="0 0 1024 1024"><path d="M470.4 812.16m41.6 0l0 0q41.6 0 41.6 41.6l0 0q0 41.6-41.6 41.6l0 0q-41.6 0-41.6-41.6l0 0q0-41.6 41.6-41.6Z" fill="currentColor" ></path><path d="M512 128c-145.706667 0-263.68 111.786667-263.68 249.813333a241.92 241.92 0 0 0 62.72 161.706667l78.72 126.506667 120.96 194.56 122.026667-194.133334 79.36-125.866666a242.133333 242.133333 0 0 0 64-162.773334C775.68 238.72 657.706667 128 512 128z m-3.626667 375.466667a145.066667 145.066667 0 1 1 144.64-144.853334 144.853333 144.853333 0 0 1-144.64 143.786667z" fill="#57B8FF" ></path></symbol><symbol id="a-9-3gaodeyingxiang" viewBox="0 0 1024 1024"><path d="M512 938.666667a405.333333 405.333333 0 0 1-45.44-2.346667A426.666667 426.666667 0 0 1 243.413333 180.48a426.666667 426.666667 0 0 1 537.173334 663.04A424.106667 424.106667 0 0 1 512 938.666667z m0-810.666667a384 384 0 1 0 241.706667 682.666667 384 384 0 0 0-201.6-680.533334A375.253333 375.253333 0 0 0 512 128z" fill="currentColor" ></path><path d="M130.773333 664.533333l-6.826666-42.666666c2.346667 0 58.24-10.666667 59.733333-60.8 0-17.706667-5.333333-21.333333-30.933333-31.146667s-58.453333-21.333333-59.52-68.266667c-1.706667-67.84 72.106667-92.586667 111.36-96.213333h4.053333l3.84 1.066667A170.666667 170.666667 0 0 0 367.573333 320c73.386667-67.413333 42.666667-190.08 42.666667-192l41.386667-10.666667c1.493333 5.973333 36.693333 149.333333-55.466667 233.173334a216.533333 216.533333 0 0 1-192 56.746666c-14.08 2.133333-70.4 12.8-69.333333 52.48 0 16 6.613333 20.053333 31.36 29.226667s60.8 21.333333 59.093333 72.32c-1.066667 70.186667-62.293333 98.133333-94.506667 103.253333zM448 790.826667a92.586667 92.586667 0 0 1-52.053333-21.333334c-95.573333-73.386667-37.546667-232.96-34.986667-239.786666l2.986667-5.546667c8.32-10.666667 82.773333-105.386667 149.333333-112.213333a66.773333 66.773333 0 0 1 19.626667 0 119.893333 119.893333 0 0 1 1.28-11.946667 121.813333 121.813333 0 0 1 59.733333-77.44L597.333333 320h4.266667c3.84 0 96.213333-17.493333 155.306667 37.76 37.333333 34.773333 51.84 88.746667 42.666666 160.64-10.026667 86.613333-37.76 143.36-81.92 168.32a112.213333 112.213333 0 0 1-96 4.906667l-8.106666-3.626667-2.986667-8.533333c-3.413333-8.746667-16.426667-34.986667-32.853333-39.253334a35.84 35.84 0 0 0-30.506667 12.586667 175.146667 175.146667 0 0 0-40.746667 72.32c-10.88 29.653333-21.333333 57.386667-47.573333 65.066667a42.666667 42.666667 0 0 1-10.88 0.64z m-48.426667-244.48c-6.826667 20.053333-42.666667 138.453333 21.333334 188.16 19.84 15.36 26.666667 13.653333 26.666666 13.653333 5.76-1.706667 14.293333-24.96 19.413334-38.826667a211.626667 211.626667 0 0 1 52.693333-89.6 73.813333 73.813333 0 0 1 69.12-21.333333 98.56 98.56 0 0 1 58.24 56.106667 67.413333 67.413333 0 0 0 50.773333-5.973334c30.933333-17.706667 51.626667-64 59.946667-135.68 6.826667-57.6-3.413333-99.413333-30.08-124.373333-37.333333-35.2-98.346667-29.866667-114.56-27.733333A78.506667 78.506667 0 0 0 576 407.04a52.053333 52.053333 0 0 0 10.24 39.04l11.52 16-29.44 26.24-13.653333-14.72c-1.706667-1.706667-6.4-6.186667-16-14.506667a24.96 24.96 0 0 0-20.266667-5.76c-36.48 3.626667-91.733333 58.666667-118.826667 93.013334zM446.08 932.906667l-25.386667-34.133334c11.946667-8.96 72.533333-52.906667 103.68-57.386666a230.186667 230.186667 0 0 1 87.253334 17.066666 692.48 692.48 0 0 1 98.133333-94.933333c32.213333-26.026667 62.293333-36.48 89.386667-30.933333a69.12 69.12 0 0 1 46.08 33.28l-37.546667 20.053333 18.773333-10.026667-18.56 10.453334a28.16 28.16 0 0 0-17.706666-12.16 74.666667 74.666667 0 0 0-53.546667 22.613333A585.386667 585.386667 0 0 0 636.16 896l-9.6 13.653333-15.573333-6.186666a250.026667 250.026667 0 0 0-80.426667-20.053334 335.146667 335.146667 0 0 0-84.48 49.493334z" fill="currentColor" ></path><path d="M421.546667 136.106667l-117.973334 24.32-119.68 132.266666-37.76 96.853334 129.706667-10.88 131.2-73.386667 25.6-100.906667-11.093333-68.266666zM123.093333 504.106667L138.666667 640l59.52-54.613333-8.32-67.626667-66.773334-13.653333zM539.52 861.44l-66.56 39.253333 116.266667 12.16-49.706667-51.413333zM652.586667 878.293333l70.613333-98.133333 89.6-17.28-48.853333 72.746667-111.36 42.666666zM592.64 336.213333l145.706667 32 45.866666 138.24-32 113.92-103.68 52.48-47.786666-45.866666-48-23.253334-39.466667 47.146667-39.466667 78.933333-31.36 29.44-67.2-42.026666 13.653334-183.253334 96.64-92.586666 77.013333-20.053334 30.08-85.12z" fill="currentColor" ></path><path d="M881.28 80.213333L231.253333 366.72l146.346667 90.88L868.48 97.92l5.973333-4.906667-415.146666 405.12-36.693334 125.866667 114.346667-75.733333 203.306667 127.36L889.173333 76.8l-7.893333 3.413333z" fill="#57B8FF" ></path></symbol><symbol id="a-9-1gugeditu" viewBox="0 0 1024 1024"><path d="M571.946667 104.746667h-1.493334a119.253333 119.253333 0 0 1-28.586666-3.413334h-42.666667a116.266667 116.266667 0 0 1-29.866667 4.053334 129.706667 129.706667 0 0 1-13.013333 0 110.72 110.72 0 0 1-36.906667 5.973333 103.68 103.68 0 0 1-46.293333 14.08 95.146667 95.146667 0 0 1-16.213333 4.48 87.893333 87.893333 0 0 1-40.533334 21.333333A91.093333 91.093333 0 0 1 277.333333 170.666667a94.293333 94.293333 0 0 1-36.266666 26.453333 38.4 38.4 0 0 1-4.266667 4.053333 94.506667 94.506667 0 0 1-26.666667 28.586667A93.44 93.44 0 0 1 185.386667 256a95.786667 95.786667 0 0 1-16.64 21.333333A102.826667 102.826667 0 0 1 149.333333 308.906667a102.613333 102.613333 0 0 1-11.52 21.333333 106.666667 106.666667 0 0 1-21.333333 39.893333 117.12 117.12 0 0 1-12.16 42.666667 116.693333 116.693333 0 0 1-6.4 21.333333 109.44 109.44 0 0 1-4.48 21.333334 122.666667 122.666667 0 0 1-2.133333 27.946666v54.826667a121.813333 121.813333 0 0 1 1.92 30.506667 115.413333 115.413333 0 0 1 2.56 19.2 121.386667 121.386667 0 0 1 2.56 21.333333c0 2.56 1.706667 4.906667 2.133333 7.466667L605.653333 112.213333a108.586667 108.586667 0 0 1-33.706666-7.466666z" fill="#DD4E41" ></path><path d="M922.026667 444.373333c-2.133333-11.52-3.84-23.253333-5.12-34.986666v-2.773334a119.253333 119.253333 0 0 1-13.866667-50.133333l-1.28-2.986667-183.466667 54.613334-153.173333-153.173334-231.68 230.4 234.666667 234.666667 160.426666 160.64a91.946667 91.946667 0 0 1 29.653334-21.333333 99.2 99.2 0 0 1 27.946666-23.253334l1.493334-1.28a93.866667 93.866667 0 0 1 13.013333-11.093333 94.293333 94.293333 0 0 1 38.4-39.68h1.493333a100.266667 100.266667 0 0 1 19.84-30.506667c2.133333-3.626667 4.266667-7.253333 6.613334-10.88a103.893333 103.893333 0 0 1 14.506666-23.68 130.133333 130.133333 0 0 1 7.253334-11.52l1.92-4.693333a67.413333 67.413333 0 0 1 4.266666-12.586667 111.36 111.36 0 0 1 16.213334-38.826666 143.786667 143.786667 0 0 1 2.986666-21.333334 95.573333 95.573333 0 0 1 4.266667-14.72 252.373333 252.373333 0 0 0 6.4-28.586666c0-3.84 0-7.893333 1.493333-11.946667a213.333333 213.333333 0 0 1 3.413334-21.333333v-85.333334a80 80 0 0 1-7.68-23.68z" fill="#FFCD41" ></path><path d="M544.213333 940.373333a110.08 110.08 0 0 1 23.253334-4.053333 108.16 108.16 0 0 1 40.533333-7.466667h7.68a96.64 96.64 0 0 1 42.666667-14.72L283.733333 539.733333 128 695.04a96.853333 96.853333 0 0 1 4.48 9.6 100.48 100.48 0 0 1 12.586667 26.453333 99.413333 99.413333 0 0 1 15.786666 23.253334 99.84 99.84 0 0 1 18.56 26.666666 96.213333 96.213333 0 0 1 29.653334 33.28 94.293333 94.293333 0 0 1 25.6 24.746667 93.653333 93.653333 0 0 1 33.706666 26.026667 93.653333 93.653333 0 0 1 42.666667 25.6 93.44 93.44 0 0 1 39.04 19.413333 95.146667 95.146667 0 0 1 31.36 10.24 114.56 114.56 0 0 1 32.64 7.68h3.2a106.666667 106.666667 0 0 1 46.08 9.813333 116.906667 116.906667 0 0 1 21.333333 2.56z" fill="#1DA362" ></path><path d="M512 941.653333a420.906667 420.906667 0 1 1 420.053333-420.906666A421.333333 421.333333 0 0 1 512 941.653333z m0-836.266666a415.573333 415.573333 0 1 0 414.506667 415.36A416 416 0 0 0 512 105.386667z" fill="currentColor" ></path><path d="M933.76 280.533333a203.733333 203.733333 0 0 0-407.253333 0 194.346667 194.346667 0 0 0 48.426666 128l60.8 100.266667 93.44 154.24 94.293334-153.813333 61.013333-99.84a193.493333 193.493333 0 0 0 49.28-128.853334z" fill="currentColor" ></path><path d="M572.373333 278.186667a155.306667 152.32 0 1 0 310.613334 0 155.306667 152.32 0 1 0-310.613334 0Z" fill="#57B8FF" ></path><path d="M241.066667 232.533333l11.733333 30.08 11.733333 30.08 20.053334-23.466666 19.84-23.68-31.573334-6.613334-31.786666-6.4zM350.506667 324.053333l-31.786667-6.826666-31.573333-6.826667 20.053333-23.466667 20.266667-23.253333 11.306666 30.08 11.733334 30.293333z" fill="currentColor" ></path></symbol><symbol id="a-9-7dituxiazai" viewBox="0 0 1024 1024"><path d="M448 84.053333h128v593.706667h-128z" fill="currentColor" ></path><path d="M512 800l-138.666667-152.96-138.666666-152.96h554.666666l-138.666666 152.96L512 800zM896 898.346667H128a21.333333 21.333333 0 0 1 0-42.666667h768a21.333333 21.333333 0 0 1 0 42.666667z" fill="currentColor" ></path></symbol><symbol id="a-8-2kuozhangongju" viewBox="0 0 1024 1024"><path d="M705.28 151.466667v192H318.72v-192h386.56m2.56-51.413334H316.16A49.066667 49.066667 0 0 0 267.306667 149.333333v195.626667a49.066667 49.066667 0 0 0 48.853333 49.066667h391.68a49.066667 49.066667 0 0 0 48.853333-49.066667V149.333333a49.066667 49.066667 0 0 0-48.853333-49.066666z" fill="currentColor" ></path><path d="M215.893333 402.773333h102.826667v85.333334h386.56v-90.88h102.826667v91.093333h119.893333v-102.826667a49.066667 49.066667 0 0 0-48.853333-48.853333H144.853333a49.066667 49.066667 0 0 0-48.853333 48.853333v102.826667h119.893333zM808.106667 539.733333V618.666667h-102.826667v-78.933334H318.72v83.2h-102.826667v-83.2H96V874.666667a49.066667 49.066667 0 0 0 48.853333 49.066666h734.293334A49.066667 49.066667 0 0 0 928 874.666667V539.733333z" fill="currentColor" ></path><path d="M144.853333 277.333333h734.293334a48.853333 48.853333 0 0 1 48.853333 48.853334v65.706666h-832v-65.28A48.853333 48.853333 0 0 1 144.853333 277.333333z" fill="currentColor" ></path><path d="M631.68 714.666667l-67.626667-73.173334 72.533334-68.48 49.28 13.653334a101.333333 101.333333 0 0 0-159.36-10.666667 101.546667 101.546667 0 0 0 6.826666 144.213333 101.76 101.76 0 0 0 152.106667-16.213333zM487.466667 721.28l-130.346667 142.933333a14.506667 14.506667 0 0 0 0 21.333334l28.373333 25.6a14.506667 14.506667 0 0 0 21.333334-1.28l130.346666-142.933334a14.506667 14.506667 0 0 0 0-21.333333l-28.373333-25.6a14.293333 14.293333 0 0 0-21.333333 1.28z m-97.066667 155.946667a16.426667 16.426667 0 0 1 0-23.253334 16.64 16.64 0 0 1 22.4-0.64 16.213333 16.213333 0 0 1 0 23.04 16.64 16.64 0 0 1-22.4 0.853334z" fill="#57B8FF" ></path><path d="M649.813333 900.266667l-6.186666 6.4a23.253333 23.253333 0 0 1-32.64 1.493333l-78.933334-78.506667a22.613333 22.613333 0 0 1 1.28-32.213333l6.4-6.4a23.04 23.04 0 0 1 32.426667-1.706667l79.146667 78.506667a22.826667 22.826667 0 0 1-1.493334 32.426667zM479.573333 718.506667l-19.413333 19.413333a14.72 14.72 0 0 1-21.333333 0l-4.266667-4.48a14.506667 14.506667 0 0 1 0-21.333333l19.2-19.2a14.933333 14.933333 0 0 1 21.333333 0l4.48 4.48a14.506667 14.506667 0 0 1 0 21.12z" fill="#FF9800" ></path><path d="M397.44 643.413333l-12.586667 12.8a13.226667 13.226667 0 0 1-18.346666 0L341.333333 631.68a13.013333 13.013333 0 0 1 0-18.133333l12.8-12.586667a13.013333 13.013333 0 0 1 18.346667 0l24.533333 24.533333a12.586667 12.586667 0 0 1 0.426667 17.92z" fill="#57B8FF" ></path><path d="M451.413333 702.72l-5.76 5.76a7.253333 7.253333 0 0 1-10.24 0l-56.96-56.533333a7.04 7.04 0 0 1 0-10.026667l5.76-5.76a7.04 7.04 0 0 1 10.026667 0l57.173333 56.533333a7.04 7.04 0 0 1 0 10.026667z" fill="#57B8FF" ></path></symbol><symbol id="chajianceshi1" viewBox="0 0 1024 1024"><path d="M881.066667 156.586667v725.333333h-725.333334v-725.333333h725.333334m0-42.666667h-725.333334a42.666667 42.666667 0 0 0-42.666666 42.666667v725.333333a42.666667 42.666667 0 0 0 42.666666 42.666667h725.333334a42.666667 42.666667 0 0 0 42.666666-42.666667v-725.333333a42.666667 42.666667 0 0 0-42.666666-42.666667z" fill="#57B8FF" ></path><path d="M377.386667 343.04a21.333333 21.333333 0 0 1-21.333334-21.333333V213.333333a21.333333 21.333333 0 0 1 42.666667 0v107.946667a21.333333 21.333333 0 0 1-21.333333 21.76zM377.386667 848.426667a21.333333 21.333333 0 0 1-21.333334-21.333334v-266.666666a21.333333 21.333333 0 0 1 42.666667 0v266.666666a21.333333 21.333333 0 0 1-21.333333 21.333334z" fill="currentColor" ></path><path d="M377.386667 354.986667a85.333333 85.333333 0 1 1-85.333334 85.333333 85.333333 85.333333 0 0 1 85.333334-85.333333m0-42.666667a128 128 0 1 0 128 128 128 128 0 0 0-128-128zM664.96 853.333333a21.333333 21.333333 0 0 1-21.333333-21.333333v-108.586667a21.333333 21.333333 0 0 1 42.666666 0V832a21.333333 21.333333 0 0 1-21.333333 21.333333zM664.96 506.026667a21.333333 21.333333 0 0 1-21.333333-21.333334v-266.666666a21.333333 21.333333 0 1 1 42.666666 0v266.666666a21.333333 21.333333 0 0 1-21.333333 21.333334z" fill="currentColor" ></path><path d="M664.96 519.253333a85.333333 85.333333 0 1 1-85.333333 85.333334 85.333333 85.333333 0 0 1 85.333333-85.333334m0-42.666666a128 128 0 1 0 128 128 128 128 0 0 0-128-128z" fill="currentColor" ></path></symbol><symbol id="huifupizhu" viewBox="0 0 1024 1024"><path d="M719.786667 893.44H158.293333a21.333333 21.333333 0 0 1 0-42.666667h561.493334a21.333333 21.333333 0 0 1 0 42.666667z" fill="currentColor" ></path><path d="M145.28 887.893333a21.333333 21.333333 0 0 1-21.333333-21.333333V234.666667a21.333333 21.333333 0 0 1 42.666666 0v631.893333a21.333333 21.333333 0 0 1-21.333333 21.333333z" fill="currentColor" ></path><path d="M880.426667 248.106667H151.68a21.333333 21.333333 0 0 1 0-42.666667h728.746667a21.333333 21.333333 0 0 1 0 42.666667z" fill="currentColor" ></path><path d="M776.533333 352a21.333333 21.333333 0 0 1-14.933333-6.4 21.333333 21.333333 0 0 1 0-30.08l103.893333-103.893333A21.333333 21.333333 0 0 1 896 241.706667l-104.32 103.893333a21.333333 21.333333 0 0 1-15.146667 6.4z" fill="currentColor" ></path><path d="M877.013333 244.906667a21.333333 21.333333 0 0 1-15.146666-6.186667l-103.893334-103.893333A21.333333 21.333333 0 0 1 789.333333 104.533333l103.893334 103.893334a21.333333 21.333333 0 0 1 0 30.293333 21.333333 21.333333 0 0 1-16.213334 6.186667z" fill="currentColor" ></path><path d="M529.493333 422.826667H281.386667a21.333333 21.333333 0 1 1 0-42.666667h248.106666a21.333333 21.333333 0 0 1 0 42.666667zM659.626667 574.506667H281.386667a21.333333 21.333333 0 1 1 0-42.666667h378.24a21.333333 21.333333 0 0 1 0 42.666667zM828.16 729.386667H281.386667a21.333333 21.333333 0 1 1 0-42.666667h546.773333a21.333333 21.333333 0 0 1 0 42.666667z" fill="#57B8FF" ></path></symbol><symbol id="baocunpizhu" viewBox="0 0 1024 1024"><path d="M661.333333 143.786667v42.666666H320v-42.666666h341.333333m0-42.666667H320a42.666667 42.666667 0 0 0-42.666667 42.666667v42.026666a42.666667 42.666667 0 0 0 42.666667 42.666667h341.333333a42.666667 42.666667 0 0 0 42.666667-42.666667V144.426667a42.666667 42.666667 0 0 0-42.666667-42.666667zM200.96 186.453333H154.666667a21.333333 21.333333 0 0 1 0-42.666666h46.293333a21.333333 21.333333 0 0 1 0 42.666666z" fill="currentColor" ></path><path d="M149.333333 877.226667a21.333333 21.333333 0 0 1-21.333333-21.333334V165.12a21.333333 21.333333 0 0 1 42.666667 0v690.773333a21.333333 21.333333 0 0 1-21.333334 21.333334z" fill="currentColor" ></path><path d="M423.04 893.44H149.333333a21.333333 21.333333 0 0 1 0-42.666667h273.706667a21.333333 21.333333 0 0 1 0 42.666667zM828.586667 486.4a21.333333 21.333333 0 0 1-21.333334-21.333333V165.12a21.333333 21.333333 0 0 1 42.666667 0V465.066667a21.333333 21.333333 0 0 1-21.333333 21.333333z" fill="currentColor" ></path><path d="M828.586667 186.453333h-41.173334a21.333333 21.333333 0 0 1 0-42.666666h41.173334a21.333333 21.333333 0 0 1 0 42.666666zM704 938.666667a192 192 0 1 1 192-192 192 192 0 0 1-192 192z m0-341.333334a149.333333 149.333333 0 1 0 149.333333 149.333334 149.333333 149.333333 0 0 0-149.333333-149.333334z" fill="currentColor" ></path><path d="M675.413333 839.253333a21.333333 21.333333 0 0 1-15.146666-6.186666l-79.36-79.573334a21.333333 21.333333 0 1 1 30.08-30.08l79.573333 79.36a21.333333 21.333333 0 0 1 0 30.293334 21.333333 21.333333 0 0 1-15.146667 6.186666z" fill="#57B8FF" ></path><path d="M682.666667 842.24a21.333333 21.333333 0 0 1-14.933334-36.48l129.706667-129.706667a21.333333 21.333333 0 0 1 30.293333 0 21.333333 21.333333 0 0 1 0 30.08l-130.133333 129.92a21.333333 21.333333 0 0 1-14.933333 6.186667zM717.866667 384H277.333333a21.333333 21.333333 0 0 1 0-42.666667h440.533334a21.333333 21.333333 0 0 1 0 42.666667zM611.413333 535.893333H277.333333a21.333333 21.333333 0 0 1 0-42.666666h334.08a21.333333 21.333333 0 0 1 0 42.666666zM467.413333 690.773333H277.333333a21.333333 21.333333 0 1 1 0-42.666666h189.866667a21.333333 21.333333 0 0 1 0 42.666666z" fill="#57B8FF" ></path></symbol><symbol id="jiantoubiaozhu" viewBox="0 0 1024 1024"><path d="M284.586667 563.2a21.333333 21.333333 0 0 1-18.346667-10.026667 21.333333 21.333333 0 0 1 7.253333-29.44L512 378.026667a21.333333 21.333333 0 1 1 21.333333 36.266666l-238.933333 145.92a21.333333 21.333333 0 0 1-9.813333 2.986667z" fill="#57B8FF" ></path><path d="M780.586667 239.146667L508.586667 608.426667l-4.266667-200.533334-176.426667-95.573333 452.693334-73.173333z" fill="#57B8FF" ></path><path d="M853.333333 173.226667v682.666666H170.666667v-682.666666h682.666666m0-42.666667H170.666667a42.666667 42.666667 0 0 0-42.666667 42.666667v682.666666a42.666667 42.666667 0 0 0 42.666667 42.666667h682.666666a42.666667 42.666667 0 0 0 42.666667-42.666667v-682.666666a42.666667 42.666667 0 0 0-42.666667-42.666667z" fill="currentColor" ></path><path d="M556.586667 697.813333h-190.293334a21.333333 21.333333 0 0 1 0-42.666666h190.293334a21.333333 21.333333 0 0 1 0 42.666666zM669.226667 802.773333H354.56a21.333333 21.333333 0 1 1 0-42.666666h314.666667a21.333333 21.333333 0 0 1 0 42.666666z" fill="currentColor" ></path></symbol><symbol id="dashujukeshihuaico-" viewBox="0 0 1024 1024"><path d="M512 106.666667a405.333333 405.333333 0 1 0 405.333333 405.333333A405.333333 405.333333 0 0 0 512 106.666667z m0 615.466666a213.333333 213.333333 0 1 1 213.333333-213.333333 213.333333 213.333333 0 0 1-213.333333 213.333333z" fill="currentColor" ></path></symbol><symbol id="a-17biaogefuben" viewBox="0 0 1024 1024"><path d="M146.133333 152.533333h736V341.333333H146.133333z" fill="#57B8FF" ></path><path d="M374.826667 901.973333a21.333333 21.333333 0 0 1-21.333334-21.333333V341.333333a21.333333 21.333333 0 0 1 42.666667 0v539.306667a21.333333 21.333333 0 0 1-21.333333 21.333333zM633.386667 896a21.333333 21.333333 0 0 1-21.333334-21.333333V341.333333a21.333333 21.333333 0 1 1 42.666667 0v533.333334a21.333333 21.333333 0 0 1-21.333333 21.333333z" fill="currentColor" ></path><path d="M871.466667 362.666667h-725.333334a21.333333 21.333333 0 0 1 0-42.666667h725.333334a21.333333 21.333333 0 0 1 0 42.666667zM871.466667 560.64h-725.333334a21.333333 21.333333 0 0 1 0-42.666667h725.333334a21.333333 21.333333 0 0 1 0 42.666667zM874.666667 731.306667H149.333333a21.333333 21.333333 0 0 1 0-42.666667h725.333334a21.333333 21.333333 0 0 1 0 42.666667z" fill="currentColor" ></path><path d="M853.333333 917.333333H170.666667a64 64 0 0 1-64-64V170.666667a64 64 0 0 1 64-64h682.666666a64 64 0 0 1 64 64v682.666666a64 64 0 0 1-64 64zM170.666667 149.333333a21.333333 21.333333 0 0 0-21.333334 21.333334v682.666666a21.333333 21.333333 0 0 0 21.333334 21.333334h682.666666a21.333333 21.333333 0 0 0 21.333334-21.333334V170.666667a21.333333 21.333333 0 0 0-21.333334-21.333334z" fill="currentColor" ></path></symbol><symbol id="chuangjiankuai1" viewBox="0 0 1024 1024"><path d="M559.146667 664.106667H199.04a46.933333 46.933333 0 0 1-46.72-46.933334V389.12A46.933333 46.933333 0 0 1 199.04 341.333333h360.106667a46.933333 46.933333 0 0 1 46.933333 46.933334v228.906666a46.933333 46.933333 0 0 1-46.933333 46.933334zM199.04 384a4.266667 4.266667 0 0 0-4.053333 4.266667v228.906666a4.266667 4.266667 0 0 0 4.053333 4.266667h360.106667a4.266667 4.266667 0 0 0 4.266666-4.266667V389.12a4.266667 4.266667 0 0 0-4.266666-4.266667z" fill="currentColor" ></path><path d="M116.906667 569.386667m20.693333 0l84.266667 0q20.693333 0 20.693333 20.693333l0 80.213333q0 20.693333-20.693333 20.693334l-84.266667 0q-20.693333 0-20.693333-20.693334l0-80.213333q0-20.693333 20.693333-20.693333Z" fill="currentColor" ></path><path d="M618.666667 861.653333a227.626667 227.626667 0 0 1-230.613334-224 230.613333 230.613333 0 0 1 461.226667 0A227.626667 227.626667 0 0 1 618.666667 861.653333z m0-405.333333a184.746667 184.746667 0 0 0-187.946667 181.12A184.96 184.96 0 0 0 618.666667 818.986667a184.96 184.96 0 0 0 187.946666-181.333334A184.746667 184.746667 0 0 0 618.666667 456.533333z" fill="currentColor" ></path><path d="M906.24 306.986667h-341.333333a21.333333 21.333333 0 0 1 0-42.666667h341.333333a21.333333 21.333333 0 0 1 0 42.666667z" fill="#FF9800" ></path><path d="M742.186667 477.653333a21.333333 21.333333 0 0 1-21.333334-21.333333v-341.333333a21.333333 21.333333 0 0 1 42.666667 0v341.333333a21.333333 21.333333 0 0 1-21.333333 21.333333z" fill="#FF9800" ></path></symbol><symbol id="duohangwenben" viewBox="0 0 1024 1024"><path d="M853.333333 244.906667H591.786667a21.333333 21.333333 0 0 1 0-42.666667H853.333333a21.333333 21.333333 0 0 1 0 42.666667zM884.693333 365.013333H623.786667a21.333333 21.333333 0 1 1 0-42.666666h260.906666a21.333333 21.333333 0 0 1 0 42.666666zM884.693333 515.2H623.786667a21.333333 21.333333 0 0 1 0-42.666667h260.906666a21.333333 21.333333 0 0 1 0 42.666667zM885.12 787.2h-768a21.333333 21.333333 0 0 1 0-42.666667h768a21.333333 21.333333 0 0 1 0 42.666667zM885.12 898.773333h-768a21.333333 21.333333 0 0 1 0-42.666666h768a21.333333 21.333333 0 0 1 0 42.666666z" fill="#57B8FF" ></path><path d="M682.666667 685.013333h-90.666667l-64-149.333333h-264.533333l-60.8 149.333333H112.213333L353.493333 135.466667h87.68z m-180.266667-213.333333l-96-227.626667a216.96 216.96 0 0 1-9.813333-38.186666h-2.133334a186.026667 186.026667 0 0 1-10.453333 38.186666l-94.72 228.48z" fill="currentColor" ></path></symbol><symbol id="tupian" viewBox="0 0 1024 1024"><path d="M207.786667 810.666667a23.893333 23.893333 0 0 1-6.613334 0 21.333333 21.333333 0 0 1-13.653333-26.666667 445.226667 445.226667 0 0 1 49.706667-92.16A262.613333 262.613333 0 0 1 277.333333 636.8l6.4-7.04c23.253333-24.533333 81.28-37.76 122.026667-27.733333l175.786667 50.773333c32.853333 6.826667 130.773333 19.2 170.666666-8.746667a206.08 206.08 0 0 0 71.04-84.053333 21.333333 21.333333 0 0 1 39.893334 15.36 249.386667 249.386667 0 0 1-86.613334 103.68c-62.293333 42.666667-190.933333 18.346667-205.44 15.146667l-176.64-50.986667a106.666667 106.666667 0 0 0-79.786666 16l-6.826667 7.04a221.653333 221.653333 0 0 0-35.413333 47.36 440.32 440.32 0 0 0-45.013334 81.92 21.333333 21.333333 0 0 1-19.626666 15.146667z" fill="#57B8FF" ></path><path d="M855.466667 896H168.533333A61.866667 61.866667 0 0 1 106.666667 834.133333V265.386667a61.866667 61.866667 0 0 1 61.866666-61.866667h686.933334a61.866667 61.866667 0 0 1 61.866666 61.866667V834.133333a61.866667 61.866667 0 0 1-61.866666 61.866667zM168.533333 246.186667a19.2 19.2 0 0 0-19.413333 19.2V834.133333a19.413333 19.413333 0 0 0 19.413333 19.2h686.933334a19.413333 19.413333 0 0 0 19.2-19.2V265.386667a19.2 19.2 0 0 0-19.413334-19.2z" fill="currentColor" ></path><path d="M290.773333 528.426667a85.333333 85.333333 0 1 1 85.333334-86.4 85.333333 85.333333 0 0 1-85.333334 86.4z m0-129.92a42.666667 42.666667 0 1 0 42.666667 42.666666 42.666667 42.666667 0 0 0-42.666667-42.666666z" fill="#57B8FF" ></path><path d="M705.493333 389.12H640a42.666667 42.666667 0 0 1-42.666667-42.666667V170.666667a42.666667 42.666667 0 0 1 42.666667-42.666667h66.56a42.666667 42.666667 0 0 1 42.666667 42.666667v175.36a42.666667 42.666667 0 0 1-43.733334 43.093333zM640 170.666667v175.573333h66.986667V170.666667z" fill="currentColor" ></path></symbol><symbol id="lisanquxian" viewBox="0 0 1024 1024"><path d="M136.96 487.893333a21.333333 21.333333 0 0 1-15.146667-25.813333 350.506667 350.506667 0 0 1 163.2-189.44 144.213333 144.213333 0 0 1 107.946667-15.573333c101.12 27.306667 136.106667 160 161.066667 230.186666 22.4 64 42.666667 118.186667 106.666666 141.866667 111.573333 42.666667 143.573333-45.013333 158.506667-57.173333 8.96-7.466667 18.133333-14.72 28.586667-9.173334s15.146667 13.226667 9.386666 28.586667-59.093333 123.306667-200.106666 81.28l-11.093334-3.413333c-83.413333-30.72-109.226667-103.466667-132.053333-167.68C489.386667 432.426667 461.44 320 381.866667 298.666667a93.866667 93.866667 0 0 0-75.306667 11.093333 353.493333 353.493333 0 0 0-143.36 162.986667 21.333333 21.333333 0 0 1-25.813333 15.573333z" fill="currentColor" ></path><path d="M92.8 693.973333h-4.693333a21.333333 21.333333 0 0 1-16.213334-25.6l27.946667-124.16a21.333333 21.333333 0 0 1 25.6-16 21.333333 21.333333 0 0 1 16 25.386667l-27.946667 123.733333a21.333333 21.333333 0 0 1-20.693333 16.64zM882.986667 533.333333a21.333333 21.333333 0 0 1-8.106667-1.493333 21.333333 21.333333 0 0 1-11.52-27.946667l48.213333-117.76a21.333333 21.333333 0 0 1 39.466667 16.213334l-48.213333 117.76a21.333333 21.333333 0 0 1-19.84 13.226666z" fill="#57B8FF" ></path></symbol><symbol id="a-23zhiyuduixiangzhixiafuben" viewBox="0 0 1024 1024"><path d="M544.213333 423.04v71.253333h-172.8v348.16h544.853334V423.04H544.213333z" fill="#57B8FF" ></path><path d="M105.6 181.546667H524.8v293.546666H105.6z" fill="currentColor" ></path></symbol><symbol id="zhiyuduixiangzhishang" viewBox="0 0 1024 1024"><path d="M381.226667 431.573333h536.96v413.013334H381.226667z" fill="#57B8FF" ></path><path d="M352.853333 407.68h167.68V193.706667H107.52v289.066666h245.333333v-75.093333z" fill="currentColor" ></path></symbol><symbol id="duiqibiaozhu" viewBox="0 0 1024 1024"><path d="M644.053333 670.293333a21.333333 21.333333 0 0 1-15.146666-6.186666L362.666667 398.72a21.333333 21.333333 0 0 1 0-30.08 21.333333 21.333333 0 0 1 30.293333 0l266.026667 265.386667a21.333333 21.333333 0 0 1 0 30.08 21.333333 21.333333 0 0 1-14.933334 6.186666z" fill="#57B8FF" ></path><path d="M461.866667 320.213333l-146.56 146.56v-146.56h146.56zM707.413333 565.76l-146.56 146.773333h146.56v-146.773333z" fill="#57B8FF" ></path><path d="M128 467.2a21.333333 21.333333 0 0 1-14.933333-36.48L419.2 124.16a21.333333 21.333333 0 0 1 30.08 0 21.333333 21.333333 0 0 1 0 30.293333L142.72 461.013333a21.333333 21.333333 0 0 1-14.72 6.186667zM586.453333 906.026667a21.333333 21.333333 0 0 1-15.146666-6.186667 21.333333 21.333333 0 0 1 0-30.293333l309.333333-309.12a21.333333 21.333333 0 0 1 30.08 30.08L601.6 899.84a21.333333 21.333333 0 0 1-15.146667 6.186667z" fill="currentColor" ></path></symbol><symbol id="quanping" viewBox="0 0 1024 1024"><path d="M832 917.333333H192a85.333333 85.333333 0 0 1-85.333333-85.333333V192a85.333333 85.333333 0 0 1 85.333333-85.333333h640a85.333333 85.333333 0 0 1 85.333333 85.333333v640a85.333333 85.333333 0 0 1-85.333333 85.333333zM192 149.333333a42.666667 42.666667 0 0 0-42.666667 42.666667v640a42.666667 42.666667 0 0 0 42.666667 42.666667h640a42.666667 42.666667 0 0 0 42.666667-42.666667V192a42.666667 42.666667 0 0 0-42.666667-42.666667z" fill="currentColor" ></path><path d="M610.773333 439.04a21.333333 21.333333 0 0 1-15.786666-6.4 22.613333 22.613333 0 0 1 0-31.786667l141.013333-141.013333a22.613333 22.613333 0 0 1 31.786667 0 21.333333 21.333333 0 0 1 0 31.573333l-141.226667 141.226667a21.333333 21.333333 0 0 1-15.786667 6.4z" fill="#57B8FF" ></path><path d="M686.933333 226.346667l114.133334 114.133333v-114.133333H686.933333z" fill="#57B8FF" ></path><path d="M277.333333 769.493333a21.333333 21.333333 0 0 1-15.786666-6.4 22.613333 22.613333 0 0 1 0-31.786666l138.88-138.88a21.333333 21.333333 0 0 1 31.573333 0 22.613333 22.613333 0 0 1 0 31.786666l-138.88 138.88a21.333333 21.333333 0 0 1-15.786667 6.4z" fill="#57B8FF" ></path><path d="M342.826667 796.373333l-114.133334-114.133333v114.133333h114.133334z" fill="#57B8FF" ></path></symbol><symbol id="shunshizhenxuanzhuan90du" viewBox="0 0 1024 1024"><path d="M492.8 690.56l-26.453333 13.44a52.053333 52.053333 0 0 1-23.68 5.76 69.973333 69.973333 0 0 1-70.826667-73.6A81.066667 81.066667 0 0 1 452.48 554.666667c50.773333 0 79.146667 44.8 79.146667 98.346666a156.8 156.8 0 0 1-99.626667 147.413334 182.186667 182.186667 0 0 1-46.933333 10.24l-2.986667-11.52a133.333333 133.333333 0 0 0 110.72-108.586667zM448 568.32c-30.72 0-41.386667 29.226667-41.386667 56.746667 0 34.773333 19.413333 64 52.48 64a59.946667 59.946667 0 0 0 35.413334-11.52 182.186667 182.186667 0 0 0 1.493333-25.6c-0.213333-35.413333-10.026667-83.626667-48-83.626667zM643.626667 554.666667c59.093333 0 81.066667 66.133333 81.066666 128 0 57.6-21.333333 128-81.066666 128s-82.346667-64-82.346667-128c0-58.026667 22.4-128 82.346667-128z m0 13.653333c-36.693333 0-45.653333 58.026667-45.653334 113.066667s11.093333 114.346667 45.653334 114.346666 45.013333-58.666667 45.013333-113.92-10.026667-113.493333-45.013333-113.493333zM784.853333 586.666667A47.36 47.36 0 1 1 832 539.52a47.146667 47.146667 0 0 1-47.146667 47.146667z m0-73.173334A26.026667 26.026667 0 1 0 810.666667 539.52a26.026667 26.026667 0 0 0-25.813334-26.026667z" fill="currentColor" ></path><path d="M854.826667 458.24a21.333333 21.333333 0 0 1 21.333333 21.333333v384a21.333333 21.333333 0 0 1-21.333333 21.333334H311.893333a21.333333 21.333333 0 0 1-21.333333-21.333334v-384a21.333333 21.333333 0 0 1 21.333333-21.333333h542.933334m0-42.666667H311.893333a64 64 0 0 0-64 64v384a64 64 0 0 0 64 64h542.933334a64 64 0 0 0 64-64v-384a64 64 0 0 0-64-64z" fill="currentColor" ></path><path d="M126.506667 681.173333a21.333333 21.333333 0 0 1-21.333334-21.333333V370.986667c0-61.866667 10.026667-97.28 34.773334-121.813334 43.733333-42.666667 128-42.666667 294.4-42.666666h87.893333a21.333333 21.333333 0 0 1 0 42.666666h-88.106667c-149.333333 0-232.96-1.28-264.106666 29.653334-15.573333 15.36-21.333333 42.666667-21.333334 91.52v289.493333a21.333333 21.333333 0 0 1-22.186666 21.333333z" fill="#57B8FF" ></path><path d="M486.4 368.426667l-0.64-136.106667-0.853333-135.893333 87.04 67.626666 86.826666 67.413334-86.186666 68.48-86.186667 68.48z" fill="#57B8FF" ></path></symbol><symbol id="baocun" viewBox="0 0 1024 1024"><path d="M482.773333 930.773333H198.826667a62.293333 62.293333 0 0 1-57.813334-66.133333V146.346667a62.293333 62.293333 0 0 1 57.813334-66.133334h565.76a62.293333 62.293333 0 0 1 57.6 66.133334v356.693333a20.053333 20.053333 0 1 1-39.68 0V146.346667a18.56 18.56 0 0 0-17.92-18.346667H198.826667a18.56 18.56 0 0 0-18.133334 18.986667v717.653333a18.56 18.56 0 0 0 18.133334 18.986667h283.946666a23.893333 23.893333 0 0 1 0 47.146666z" fill="currentColor" ></path><path d="M651.946667 128v207.36h-341.333334V128h341.333334m0-42.666667h-341.333334a42.666667 42.666667 0 0 0-42.666666 42.666667v208.213333a42.666667 42.666667 0 0 0 42.666666 42.666667h341.333334a42.666667 42.666667 0 0 0 42.666666-42.666667V128a42.666667 42.666667 0 0 0-42.666666-42.666667z" fill="currentColor" ></path><path d="M561.28 309.333333a21.333333 21.333333 0 0 1-21.333333-21.333333V163.2a21.333333 21.333333 0 0 1 42.666666 0v124.8a21.333333 21.333333 0 0 1-21.333333 21.333333zM881.92 828.16H417.066667a21.333333 21.333333 0 1 1 0-42.666667h464.853333a21.333333 21.333333 0 1 1 0 42.666667z" fill="currentColor" ></path><path d="M881.92 828.16a21.333333 21.333333 0 0 1-13.013333-4.48l-130.133334-100.693333a21.333333 21.333333 0 0 1 26.026667-33.706667L896 789.333333a21.333333 21.333333 0 0 1-13.013333 37.973334z" fill="currentColor" ></path><path d="M757.546667 933.546667A21.333333 21.333333 0 0 1 744.533333 896l130.133334-101.333333a21.333333 21.333333 0 1 1 26.026666 33.706666l-130.133333 100.693334a21.333333 21.333333 0 0 1-13.013333 4.48z" fill="currentColor" ></path><path d="M437.546667 510.72l-47.36 163.413333h-50.133334L314.88 576a92.586667 92.586667 0 0 1-2.56-20.266667h-1.066667a104.533333 104.533333 0 0 1-3.2 19.626667l-26.88 98.773333h-49.706666l-46.506667-163.413333H234.666667L257.493333 618.666667a118.613333 118.613333 0 0 1 2.56 17.92 99.413333 99.413333 0 0 1 2.986667-18.56l29.226667-106.666667h45.226666L364.373333 618.666667a132.053333 132.053333 0 0 1 2.346667 17.92 180.053333 180.053333 0 0 1 2.56-17.92l22.826667-108.586667zM605.866667 605.866667h-106.666667c1.706667 25.173333 17.066667 37.973333 45.866667 37.973333a85.333333 85.333333 0 0 0 47.786666-13.44v34.986667a117.333333 117.333333 0 0 1-58.666666 12.586666 80.64 80.64 0 0 1-60.586667-21.333333 83.2 83.2 0 0 1-21.333333-61.226667 88.96 88.96 0 0 1 23.04-64A77.226667 77.226667 0 0 1 533.333333 506.88a70.4 70.4 0 0 1 54.4 21.333333 81.706667 81.706667 0 0 1 19.626667 57.813334zM561.28 576c0-24.32-9.813333-36.693333-29.653333-36.693333a29.013333 29.013333 0 0 0-21.333334 10.026666 48.213333 48.213333 0 0 0-12.373333 26.666667zM684.586667 654.506667v19.626666h-47.786667V432.426667h47.786667v103.253333a60.373333 60.373333 0 0 1 53.546666-29.013333 59.52 59.52 0 0 1 48.426667 21.333333 93.226667 93.226667 0 0 1 17.493333 59.52 102.186667 102.186667 0 0 1-20.053333 65.493333 65.28 65.28 0 0 1-53.546667 24.746667 51.413333 51.413333 0 0 1-45.866666-23.466667z m0-50.986667a39.253333 39.253333 0 0 0 9.6 26.88 30.506667 30.506667 0 0 0 24.32 11.093333 32.853333 32.853333 0 0 0 28.16-13.866666 67.413333 67.413333 0 0 0 9.813333-39.466667A53.12 53.12 0 0 0 746.666667 554.666667a31.146667 31.146667 0 0 0-26.026667-11.946667 33.92 33.92 0 0 0-26.453333 11.946667 45.226667 45.226667 0 0 0-10.24 30.72z" fill="#57B8FF" ></path></symbol><symbol id="a-5pingyi" viewBox="0 0 1024 1024"><path d="M130.133333 258.56h295.04v41.6H130.133333z" fill="#57B8FF" ></path><path d="M136.746667 229.546667v101.973333L85.333333 279.466667l51.413334-49.92zM418.986667 229.546667v101.973333l51.2-52.053333-51.2-49.92zM260.693333 139.733333h42.666667v287.786667h-42.666667z" fill="#57B8FF" ></path><path d="M228.693333 421.333333h104.746667l-51.413333 49.92-53.333334-49.92zM228.693333 146.133333h104.746667L282.026667 96l-53.333334 50.133333z" fill="#57B8FF" ></path><path d="M673.493333 928h-72.746666c-106.666667 0-166.826667-93.866667-194.56-183.466667v-56.32c0-75.093333 100.48-185.6 143.146666-135.466666h277.333334A46.72 46.72 0 0 1 874.666667 598.613333v139.733334c-34.346667 112.426667-90.026667 189.653333-201.173334 189.653333z" fill="currentColor" ></path><path d="M469.333333 830.08a50.56 50.56 0 0 1-38.4-27.093333l-138.24-302.506667c-12.8-29.226667 25.813333-54.186667 68.48-43.733333a50.56 50.56 0 0 1 38.613334 27.093333l138.88 302.293333c12.8 29.226667-25.6 54.186667-69.333334 43.946667zM534.4 621.44A42.666667 42.666667 0 0 1 490.666667 586.026667l-35.413334-333.653334a40.533333 40.533333 0 0 1 38.613334-43.733333 42.666667 42.666667 0 0 1 44.8 35.413333l34.346666 333.653334a40.746667 40.746667 0 0 1-38.613333 43.733333zM626.346667 621.44a40.106667 40.106667 0 0 1-40.533334-39.68l-6.4-421.12a40.533333 40.533333 0 0 1 42.666667-39.68 40.32 40.32 0 0 1 40.746667 39.68l6.4 421.12a40.746667 40.746667 0 0 1-42.88 39.68zM725.333333 615.253333a42.666667 42.666667 0 0 1-38.4-42.666666l21.333334-352.426667a40.746667 40.746667 0 0 1 45.013333-37.333333 42.666667 42.666667 0 0 1 38.4 42.666666l-21.333333 352.426667A39.893333 39.893333 0 0 1 725.333333 615.253333zM829.44 621.44a44.373333 44.373333 0 0 1-36.266667-48l19.2-204.373333a44.586667 44.586667 0 0 1 47.146667-42.666667A44.373333 44.373333 0 0 1 896 375.466667l-19.2 204.373333a47.36 47.36 0 0 1-47.36 41.6z" fill="currentColor" ></path><path d="M405.973333 700.8a231.04 208.426667 0 1 0 462.08 0 231.04 208.426667 0 1 0-462.08 0Z" fill="currentColor" ></path></symbol><symbol id="chuangkousuofang" viewBox="0 0 1024 1024"><path d="M896 911.786667a21.333333 21.333333 0 0 1-15.573333-6.4l-201.6-194.986667a22.613333 22.613333 0 0 1 0-31.786667 21.333333 21.333333 0 0 1 31.573333 0l201.173333 194.986667a22.4 22.4 0 0 1-15.573333 38.186667z" fill="currentColor" ></path><path d="M513.28 782.293333a274.133333 274.133333 0 1 1 273.066667-274.133333 273.92 273.92 0 0 1-273.066667 274.133333z m0-493.44A219.306667 219.306667 0 1 0 731.733333 508.16a219.306667 219.306667 0 0 0-218.453333-219.306667z" fill="currentColor" ></path><path d="M397.013333 143.36H128a21.333333 21.333333 0 0 1 0-41.6h269.013333a21.333333 21.333333 0 0 1 0 42.666667zM897.706667 143.36H629.546667a21.333333 21.333333 0 1 1 0-41.6h268.16a21.333333 21.333333 0 1 1 0 42.666667z" fill="#57B8FF" ></path><path d="M897.706667 412.373333a21.333333 21.333333 0 0 1-21.333334-21.333333V122.453333a21.333333 21.333333 0 0 1 42.666667 0v269.226667a21.333333 21.333333 0 0 1-21.333333 20.693333zM896 912.426667a21.333333 21.333333 0 0 1-21.333333-21.333334V622.506667a21.333333 21.333333 0 1 1 42.666666 0v269.013333a21.333333 21.333333 0 0 1-21.333333 20.906667z" fill="#57B8FF" ></path><path d="M896 912.426667H627.2a21.333333 21.333333 0 0 1 0-42.666667H896a21.333333 21.333333 0 0 1 0 42.666667zM399.146667 910.08H130.986667a21.333333 21.333333 0 1 1 0-41.6h268.16a21.333333 21.333333 0 1 1 0 41.6z" fill="#57B8FF" ></path><path d="M130.986667 907.946667a21.333333 21.333333 0 0 1-21.333334-21.333334V618.666667a21.333333 21.333333 0 1 1 42.666667 0v268.373333a21.333333 21.333333 0 0 1-21.333333 20.906667zM128 416.853333a21.333333 21.333333 0 0 1-21.333333-21.333333V128a21.333333 21.333333 0 0 1 42.666666 0v268.16a21.333333 21.333333 0 0 1-21.333333 20.693333z" fill="#57B8FF" ></path></symbol><symbol id="dakaidwg" viewBox="0 0 1024 1024"><path d="M853.333333 362.666667h-40.533333v-98.133334a19.626667 19.626667 0 0 0-18.773333-21.333333H586.666667v-42.666667h207.36a61.653333 61.653333 0 0 1 60.16 64zM706.986667 887.04H159.573333a61.226667 61.226667 0 0 1-58.24-64V198.613333a61.226667 61.226667 0 0 1 58.24-64h323.413334v42.666667H159.573333a19.413333 19.413333 0 0 0-16.64 21.333333v624.64a19.413333 19.413333 0 0 0 16.64 21.333334h547.413334z" fill="currentColor" ></path><path d="M721.493333 889.173333H120.106667c-22.826667 0-29.013333-18.986667-16.64-44.586666L306.773333 448a80.64 80.64 0 0 1 62.08-44.8h601.386667c22.826667 0 29.013333 19.2 16.64 44.8l-203.306667 396.586667a81.92 81.92 0 0 1-62.08 44.586666z" fill="#57B8FF" ></path><path d="M482.986667 134.826667l124.373333 72.32-20.693333 36.266666-114.133334-66.133333" fill="currentColor" ></path></symbol><symbol id="fanweisuofang" viewBox="0 0 1024 1024"><path d="M705.706667 320a21.333333 21.333333 0 0 1-15.786667-6.4 22.613333 22.613333 0 0 1 0-31.786667L832 140.16a21.333333 21.333333 0 0 1 31.573333 31.573333l-141.013333 141.226667a22.613333 22.613333 0 0 1-16.853333 7.04z" fill="#57B8FF" ></path><path d="M781.866667 106.666667L896 220.8V106.666667h-114.133333zM273.493333 320a22.826667 22.826667 0 0 1-16.64-7.04L120.106667 174.506667a23.466667 23.466667 0 0 1 0-33.066667 23.68 23.68 0 0 1 33.28 0l136.533333 138.88a23.253333 23.253333 0 0 1 0 33.066667 22.826667 22.826667 0 0 1-16.426667 6.613333z" fill="#57B8FF" ></path><path d="M85.333333 227.626667L203.946667 106.666667H85.333333v120.96z" fill="#57B8FF" ></path><path d="M871.466667 917.333333a22.613333 22.613333 0 0 1-15.786667-6.4l-199.253333-194.773333a22.4 22.4 0 1 1 31.36-32l199.253333 194.773333a21.333333 21.333333 0 0 1-15.573333 38.4z" fill="currentColor" ></path><path d="M134.613333 890.453333a21.333333 21.333333 0 0 1-15.786666-6.613333 21.333333 21.333333 0 0 1 0-31.573333l138.88-138.88a21.333333 21.333333 0 0 1 31.573333 31.573333l-138.88 138.88a21.333333 21.333333 0 0 1-15.786667 6.613333z" fill="#57B8FF" ></path><path d="M199.466667 917.333333L85.333333 803.2V917.333333h114.133334z" fill="#57B8FF" ></path><path d="M490.666667 785.706667A273.706667 273.706667 0 1 1 764.373333 512 274.133333 274.133333 0 0 1 490.666667 785.706667z m0-492.586667A218.88 218.88 0 1 0 709.546667 512 219.093333 219.093333 0 0 0 490.666667 293.12z" fill="currentColor" ></path></symbol><symbol id="zhonghua" viewBox="0 0 1024 1024"><path d="M446.08 508.586667H129.28a23.04 23.04 0 0 1 0-45.866667h316.8a23.04 23.04 0 0 1 0 45.866667zM810.666667 832H132.48a23.04 23.04 0 0 1 0-45.866667H810.666667A23.04 23.04 0 0 1 810.666667 832z" fill="currentColor" ></path><path d="M132.48 828.8a22.4 22.4 0 0 1-16-6.613333 23.253333 23.253333 0 0 1 0-32.64L426.666667 474.24a22.4 22.4 0 0 1 32 0 23.253333 23.253333 0 0 1 0 32.426667L149.333333 822.186667a22.4 22.4 0 0 1-16.853333 6.613333z" fill="currentColor" ></path><path d="M841.813333 384L516.266667 715.306667 405.333333 602.453333l325.546667-330.666666a22.4 22.4 0 0 1 32 0l79.146667 80.426666a23.253333 23.253333 0 0 1-0.213334 31.786667z" fill="#FF9800" ></path><path d="M844.16 345.173333l-77.653333-78.933333a23.253333 23.253333 0 0 1 0-32.426667l24.32-24.746666a51.2 51.2 0 0 1 72.746666-3.413334l40.32 40.96a52.693333 52.693333 0 0 1-3.413333 73.386667l-24.32 24.746667a22.4 22.4 0 0 1-32 0.426666z" fill="#E74F40" ></path><path d="M405.333333 602.453333l-24.746666 104.106667A22.826667 22.826667 0 0 0 405.333333 734.72l110.08-19.413333z" fill="#FF9800" ></path></symbol><symbol id="lingcunweiDWG" viewBox="0 0 1024 1024"><path d="M482.346667 934.613333H196.48a62.506667 62.506667 0 0 1-58.026667-65.92V149.333333a62.506667 62.506667 0 0 1 58.026667-64h569.6a62.72 62.72 0 0 1 58.24 64v357.546667a21.333333 21.333333 0 1 1-40.106667 0V149.333333a18.346667 18.346667 0 0 0-18.133333-18.773333H196.48a18.346667 18.346667 0 0 0-18.133333 18.773333v719.36a18.56 18.56 0 0 0 18.133333 18.773334h285.866667a23.893333 23.893333 0 0 1 0 47.146666z" fill="currentColor" ></path><path d="M641.92 137.6v207.36h-343.466667V137.6h343.466667m0-42.666667H298.666667a42.666667 42.666667 0 0 0-42.666667 42.666667v208.213333a42.666667 42.666667 0 0 0 42.666667 42.666667h343.68a42.666667 42.666667 0 0 0 42.666666-42.666667V137.173333a42.666667 42.666667 0 0 0-42.666666-42.666666z" fill="currentColor" ></path><path d="M541.226667 320a21.333333 21.333333 0 0 1-21.333334-21.333333V174.08a21.333333 21.333333 0 0 1 42.666667 0V298.666667a21.333333 21.333333 0 0 1-21.333333 21.333333zM879.146667 832H411.093333a21.333333 21.333333 0 1 1 0-42.666667h468.053334a21.333333 21.333333 0 1 1 0 42.666667z" fill="currentColor" ></path><path d="M879.146667 832a21.333333 21.333333 0 0 1-13.226667-4.48l-130.986667-100.906667a21.333333 21.333333 0 0 1-3.84-29.653333 21.333333 21.333333 0 0 1 30.08-3.84l130.986667 100.906667a21.333333 21.333333 0 0 1-13.013333 37.973333z" fill="currentColor" ></path><path d="M753.92 938.666667a21.333333 21.333333 0 0 1-16.853333-8.32 21.333333 21.333333 0 0 1 3.84-29.866667l130.986666-100.693333a21.333333 21.333333 0 0 1 30.08 3.626666A21.333333 21.333333 0 0 1 898.133333 832L768 933.12a21.333333 21.333333 0 0 1-14.08 5.546667z" fill="currentColor" ></path><path d="M188.373333 680.96v-184.96h64c66.133333 0 99.413333 30.08 99.413334 90.24a89.813333 89.813333 0 0 1-27.946667 68.906667 100.906667 100.906667 0 0 1-71.68 25.813333z m39.68-152.746667v120.533334h21.333334a58.88 58.88 0 0 0 44.373333-16.64 62.72 62.72 0 0 0 16.213333-45.226667 55.68 55.68 0 0 0-16.853333-42.666667 64 64 0 0 0-43.946667-15.573333zM618.666667 496l-49.706667 184.96H524.8l-31.786667-120.533333a107.733333 107.733333 0 0 1-2.986666-21.333334 128 128 0 0 1-3.413334 21.333334l-32.426666 120.533333h-46.293334l-49.706666-184.96h42.666666l27.733334 125.44a188.16 188.16 0 0 1 2.56 21.333333 93.013333 93.013333 0 0 1 3.626666-21.333333l34.773334-124.8h42.666666l31.573334 126.506667a145.28 145.28 0 0 1 2.986666 19.413333 108.16 108.16 0 0 1 2.986667-20.266667l26.88-125.653333zM789.333333 668.586667a133.76 133.76 0 0 1-67.2 15.786666 97.28 97.28 0 0 1-70.4-24.96 90.453333 90.453333 0 0 1-25.813333-67.84 95.36 95.36 0 0 1 28.373333-71.253333 103.04 103.04 0 0 1 74.88-27.306667 149.333333 149.333333 0 0 1 52.053334 8.32v37.333334a104.96 104.96 0 0 0-52.906667-12.586667 57.173333 57.173333 0 0 0-43.733333 17.493333 64 64 0 0 0-16.853334 46.08 64 64 0 0 0 14.933334 45.226667 53.333333 53.333333 0 0 0 41.173333 16.213333 60.586667 60.586667 0 0 0 25.386667-4.693333v-38.186667h-38.4V576H789.333333z" fill="#57B8FF" ></path></symbol><symbol id="dayin1" viewBox="0 0 1024 1024"><path d="M718.293333 138.453333v87.466667H303.786667v-87.466667h414.506666m8.106667-36.693333H295.68a27.946667 27.946667 0 0 0-28.586667 28.373333V234.666667a27.946667 27.946667 0 0 0 28.586667 28.586666h430.72A27.733333 27.733333 0 0 0 754.773333 234.666667V130.133333a27.733333 27.733333 0 0 0-28.373333-28.373333z" fill="currentColor" ></path><path d="M878.72 260.48l2.133333 452.266667a2.133333 2.133333 0 0 1-2.133333 2.133333H145.28a2.133333 2.133333 0 0 1-2.133333-2.133333v-450.133334a2.133333 2.133333 0 0 1 2.133333-2.133333h733.44m0-36.48H145.28A38.613333 38.613333 0 0 0 106.666667 262.613333v450.133334a38.613333 38.613333 0 0 0 38.613333 38.613333h733.44A38.4 38.4 0 0 0 917.333333 712.746667v-450.133334a38.613333 38.613333 0 0 0-38.613333-38.613333z" fill="currentColor" ></path><path d="M307.84 890.026667a18.133333 18.133333 0 0 1-18.346667-18.346667V627.2a18.133333 18.133333 0 0 1 18.346667-18.346667h405.333333a18.133333 18.133333 0 0 1 18.133334 18.346667v244.48a18.133333 18.133333 0 0 1-18.133334 18.346667z" fill="#57B8FF" ></path><path d="M712.106667 629.333333v238.293334H309.76V627.2h402.346667m2.133333-40.746667h-405.333333a40.96 40.96 0 0 0-40.746667 40.746667v244.48a40.96 40.96 0 0 0 40.746667 40.746667h405.333333a40.746667 40.746667 0 0 0 40.533333-40.746667V627.2a40.746667 40.746667 0 0 0-40.533333-40.746667z" fill="currentColor" ></path><path d="M653.226667 712.746667H368.853333a19.2 19.2 0 0 1-21.333333-20.266667 19.2 19.2 0 0 1 21.333333-21.333333h284.373334a19.2 19.2 0 0 1 20.266666 21.333333 19.2 19.2 0 0 1-20.266666 20.266667z" fill="#57B8FF" ></path><path d="M653.226667 672H368.853333a21.333333 21.333333 0 1 0 0 40.746667h284.373334a21.333333 21.333333 0 0 0 0-40.746667z" fill="currentColor" ></path><path d="M571.946667 814.506667h-203.093334a19.2 19.2 0 0 1-21.333333-21.333334 19.2 19.2 0 0 1 21.333333-20.266666h203.093334a19.2 19.2 0 0 1 21.333333 20.266666 21.333333 21.333333 0 0 1-21.333333 21.333334z" fill="#57B8FF" ></path><path d="M571.946667 773.973333h-203.093334a19.2 19.2 0 0 0-21.333333 20.266667 19.2 19.2 0 0 0 21.333333 21.333333h203.093334a19.2 19.2 0 0 0 21.333333-21.333333 21.333333 21.333333 0 0 0-21.333333-20.266667z" fill="currentColor" ></path></symbol><symbol id="xinjian" viewBox="0 0 1024 1024"><path d="M776.746667 580.906667H248.746667a21.333333 21.333333 0 0 1-23.893334-21.333334 21.333333 21.333333 0 0 1 23.893334-21.333333h528a21.333333 21.333333 0 0 1 24.106666 21.333333 22.826667 22.826667 0 0 1-24.106666 21.333334z" fill="#57B8FF" ></path><path d="M536.746667 324.906667v469.333333a21.333333 21.333333 0 0 1-23.893334 21.333333 21.333333 21.333333 0 0 1-24.106666-21.333333v-469.333333a21.333333 21.333333 0 0 1 24.106666-21.333334 21.333333 21.333333 0 0 1 23.893334 21.333334z" fill="#57B8FF" ></path><path d="M608.853333 124.373333v168.533334a45.653333 45.653333 0 0 0 48 42.666666h192v556.8H176.853333v-768h432m48-42.666666H176.853333a45.653333 45.653333 0 0 0-48.853333 42.666666v768a45.653333 45.653333 0 0 0 48 42.666667h672a45.653333 45.653333 0 0 0 48-42.666667v-599.466666H656.853333v-211.2z" fill="currentColor" ></path><path d="M896.853333 295.04l-240-213.333333h-50.346666v256h290.346666v-42.666667z" fill="#57B8FF" ></path></symbol><symbol id="celiangmianji" viewBox="0 0 1024 1024"><path d="M909.44 658.133333H114.56a28.16 28.16 0 0 0-28.16 28.16V853.333333a28.16 28.16 0 0 0 28.16 28.16h794.88A28.16 28.16 0 0 0 938.666667 853.333333v-167.04a28.16 28.16 0 0 0-29.226667-28.16z m-688.64 177.28h-44.8v-134.4h44.8z m130.773333-44.8h-44.8v-89.6h44.8z m124.16 21.333334h-44.8v-110.933334h44.8z m115.84 21.333333h-44.8v-134.4h44.8z m122.026667-44.8h-44.8v-89.6h44.8z m134.4 21.333333h-44.8v-108.8h44.8z" fill="currentColor" ></path><path d="M351.936 468.522667L618.346667 202.133333l15.829333 15.829334L367.786667 484.373333zM264.512 463.36l310.613333-310.613333 15.829334 15.850666-310.613334 310.613334zM214.336 437.589333L483.306667 168.64l15.850666 15.829333L230.186667 453.44zM226.602667 350.528l94.592-94.570667 15.850666 15.829334-94.592 94.592zM423.893333 485.696l226.56-226.581333 15.829334 15.829333-226.56 226.581333zM526.613333 475.946667l160.042667-160.042667 15.850667 15.850667-160.064 160.042666zM605.013333 479.573333l120.234667-120.213333 15.850667 15.850667-120.234667 120.213333z" fill="#57B8FF" ></path><path d="M828.8 498.986667H214.613333v-202.026667l362.666667-176.426667z m-569.386667-44.8h485.973334L562.56 177.92l-303.146667 147.2z" fill="currentColor" ></path></symbol><symbol id="a-4-9tukuaiku" viewBox="0 0 1024 1024"><path d="M102.826667 452.266667a25.386667 25.386667 0 0 1-15.786667-45.226667L496 82.986667a25.386667 25.386667 0 0 1 31.573333 39.68L118.613333 446.72a24.533333 24.533333 0 0 1-15.786666 5.546667z" fill="currentColor" ></path><path d="M921.173333 452.053333a25.6 25.6 0 0 1-15.786666-5.333333L496.426667 122.666667a25.386667 25.386667 0 0 1 31.573333-39.893334l408.96 324.053334a25.386667 25.386667 0 0 1-15.786667 45.226666zM865.28 884.906667H158.72V462.933333a22.613333 22.613333 0 0 1 45.226667 0v376.746667h616.106666V462.933333a22.613333 22.613333 0 0 1 45.226667 0z" fill="currentColor" ></path><path d="M556.16 673.066667H279.893333a37.12 37.12 0 0 1-37.12-37.12v-186.026667a37.12 37.12 0 0 1 37.12-37.12h277.333334a37.12 37.12 0 0 1 37.12 37.12v186.026667a37.12 37.12 0 0 1-38.186667 37.12zM279.893333 446.506667a3.413333 3.413333 0 0 0-3.413333 3.413333v186.026667a3.413333 3.413333 0 0 0 3.413333 3.413333h277.333334a3.413333 3.413333 0 0 0 3.413333-3.413333v-186.026667a3.413333 3.413333 0 0 0-3.413333-3.413333z" fill="#57B8FF" ></path><path d="M603.093333 833.28a181.12 181.12 0 1 1 178.133334-181.12 179.84 179.84 0 0 1-178.133334 181.12z m0-328.533333A147.413333 147.413333 0 1 0 746.666667 652.16a146.133333 146.133333 0 0 0-143.573334-147.413333z" fill="#57B8FF" ></path><path d="M573.013333 346.026667h-122.026666a21.333333 21.333333 0 0 1 0-42.666667h122.026666a21.333333 21.333333 0 0 1 0 42.666667z" fill="currentColor" ></path></symbol><symbol id="a-4-6chazhaotihuanwenzi" viewBox="0 0 1024 1024"><path d="M526.293333 846.506667c-73.6 0-141.44-17.706667-164.053333-34.133334a21.333333 21.333333 0 0 1 25.173333-34.56c27.306667 19.84 171.946667 47.786667 263.893334 0 124.16-64 160.853333-154.24 170.666666-219.52a21.333333 21.333333 0 0 1 24.106667-18.346666 21.333333 21.333333 0 0 1 18.133333 24.106666c-14.506667 106.666667-82.986667 195.84-192 251.733334a321.493333 321.493333 0 0 1-145.92 30.72z" fill="currentColor" ></path><path d="M775.253333 580.053333l64.853334-109.866666 62.933333 110.933333-127.786667-1.066667zM172.373333 458.026667a21.333333 21.333333 0 0 1-21.333333-21.333334C149.333333 341.333333 219.52 227.626667 320 161.493333c110.506667-72.533333 295.893333-72.533333 396.586667 0a21.333333 21.333333 0 0 1-24.96 34.56c-86.613333-62.506667-252.586667-62.293333-348.16 0-87.466667 57.6-149.333333 158.293333-149.333334 239.36a21.333333 21.333333 0 0 1-21.333333 21.333334z" fill="currentColor" ></path><path d="M233.813333 401.706667l-34.773333 122.88-88.96-91.52 123.733333-31.36zM838.613333 904.96a21.333333 21.333333 0 0 1-17.066666-8.533333L725.333333 766.506667a21.333333 21.333333 0 0 1 34.133334-25.6l97.28 129.92a21.333333 21.333333 0 0 1-4.266667 29.866666 21.333333 21.333333 0 0 1-13.866667 4.266667z" fill="currentColor" ></path><path d="M769.706667 359.253333l-26.24 71.466667h-32L798.08 192h39.68l90.24 238.72h-34.346667l-26.88-71.466667z m88.746666-26.88c-23.253333-62.72-36.053333-96-41.173333-114.133333-5.973333 20.266667-20.053333 60.586667-38.826667 114.133333zM146.346667 571.093333h94.293333c51.84 0 75.946667 24.533333 75.946667 55.466667a48.853333 48.853333 0 0 1-35.2 48.213333 55.893333 55.893333 0 0 1 42.666666 53.12c0 42.666667-35.2 65.066667-81.706666 65.066667h-96zM234.666667 663.253333c35.413333 0 49.28-12.586667 49.28-34.346666s-15.36-33.493333-44.373334-33.493334H178.346667v67.84zM178.346667 768h60.586666c30.933333 0 52.266667-13.226667 52.266667-40.746667 0-24.106667-17.066667-40.32-58.453333-40.32H178.346667z" fill="#57B8FF" ></path></symbol><symbol id="xianxingbiaozhu" viewBox="0 0 1024 1024"><path d="M909.44 659.2H114.56a28.16 28.16 0 0 0-28.16 28.16v167.68a28.16 28.16 0 0 0 28.16 28.16h794.88A28.16 28.16 0 0 0 938.666667 855.04v-167.68a28.16 28.16 0 0 0-29.226667-28.16z m-688.64 177.28h-44.8v-134.4h44.8z m130.773333-44.8h-44.8v-89.6h44.8z m124.16 21.333333h-44.8v-110.933333h44.8z m115.84 22.4h-44.8v-134.4h44.8z m122.026667-44.8h-44.8v-89.6h44.8z m134.4 21.333334h-44.8v-109.866667h44.8zM190.08 253.44h627.2v44.8H190.08zM839.68 414.506667a21.333333 21.333333 0 0 1-21.333333-22.4V159.573333a21.333333 21.333333 0 1 1 44.8 0v232.533334a21.333333 21.333333 0 0 1-23.466667 22.4z" fill="currentColor" ></path><path d="M176 414.506667a21.333333 21.333333 0 0 1-21.333333-22.4V159.573333a21.333333 21.333333 0 0 1 44.8 0v232.533334a21.333333 21.333333 0 0 1-23.466667 22.4z" fill="currentColor" ></path></symbol><symbol id="zuobiaoceliang" viewBox="0 0 1024 1024"><path d="M909.44 658.986667H114.56a28.16 28.16 0 0 0-28.16 28.16v167.68a28.16 28.16 0 0 0 28.16 28.16h794.88A28.16 28.16 0 0 0 938.666667 854.826667v-167.68a28.16 28.16 0 0 0-29.226667-28.16zM220.8 836.266667h-44.8v-134.4h44.8z m130.773333-44.8h-44.8v-89.6h44.8z m124.16 21.333333h-44.8v-110.933333h44.8z m115.84 22.4h-44.8V701.866667h44.8z m122.026667-44.8h-44.8V701.866667h44.8z m134.4 21.333333h-44.8V701.866667h44.8z" fill="currentColor" ></path><path d="M501.973333 497.706667a21.333333 21.333333 0 0 1-22.4-21.333334V224.853333a21.333333 21.333333 0 1 1 44.8 0v250.453334a21.333333 21.333333 0 0 1-22.4 22.4z" fill="#57B8FF" ></path><path d="M609.066667 348.373333H216.96a21.333333 21.333333 0 0 1 0-44.8h392.106667a22.4 22.4 0 1 1 0 44.8z" fill="#57B8FF" ></path><path d="M198.4 507.093333a21.333333 21.333333 0 0 1-22.4-22.4V144.426667a21.333333 21.333333 0 1 1 44.8 0v341.333333a21.333333 21.333333 0 0 1-22.4 21.333333z" fill="currentColor" ></path><path d="M825.6 507.093333H199.466667a22.4 22.4 0 1 1 0-44.8H825.6a21.333333 21.333333 0 1 1 0 44.8z" fill="currentColor" ></path><path d="M431.146667 263.253333H396.8l-24.32-45.013333a47.36 47.36 0 0 1-2.773333-8.746667 52.266667 52.266667 0 0 1-3.2 8.96L341.333333 263.253333h-33.92l42.666667-67.84L311.04 128h35.2l20.266667 41.6a75.093333 75.093333 0 0 1 4.266666 11.093333q1.92-5.333333 4.48-11.52l21.333334-41.173333h32.213333l-39.68 66.773333zM807.466667 272.853333l-55.253334 108.8v60.586667h-36.053333v-59.946667L661.333333 272.853333h42.666667l28.373333 64a137.813333 137.813333 0 0 1 4.053334 13.44 56.533333 56.533333 0 0 1 3.626666-13.013333l29.226667-65.066667z" fill="#FF9800" ></path></symbol><symbol id="yanse" viewBox="0 0 1024 1024"><path d="M779.306667 813.44l-112-93.44s112.853333-164.48 95.36-204.373333a1129.386667 1129.386667 0 0 1 141.653333 2.56 518.826667 518.826667 0 0 1-125.013333 295.253333z" fill="#D8A3E2" ></path><path d="M664.96 691.626667l-142.293333-174.293334-13.013334-5.333333L768 499.413333s-39.04 204.586667-103.04 192.213334z" fill="#9D25BA" ></path><path d="M254.293333 208l113.28 95.146667s-113.066667 187.52-92.16 225.28c-36.906667-1.066667-158.08-11.093333-158.08-11.093334a452.48 452.48 0 0 1 136.96-309.333333z" fill="#86C4BC" ></path><path d="M360.96 330.666667l149.333333 133.12-6.186666 48.213333-228.053334 8.746667s5.76-169.386667 84.906667-190.08z" fill="#23AF9E" ></path><path d="M508.586667 900.266667v-145.92S352 725.333333 336 685.226667c-24.96 28.586667-99.413333 99.84-99.413333 99.84s120.96 118.826667 272 115.2z" fill="#9D87E0" ></path><path d="M508.373333 736.64l-5.546666-200.96 3.626666-12.373333-170.666666 161.92s144.213333 104.106667 172.586666 51.413333z" fill="#5F4A9E" ></path><path d="M510.293333 115.626667v145.706666s156.373333 30.293333 172.373334 69.333334c24.96-28.373333 99.626667-99.626667 99.626666-99.626667S661.333333 112 510.293333 115.626667z" fill="#0091FF" ></path><path d="M510.293333 279.04l5.333334 200.96-3.626667 12.373333 170.666667-161.706666s-144-103.04-172.373334-51.626667z" fill="#0064B5" ></path><path d="M510.08 900.266667v-145.92s141.013333-18.346667 157.013333-57.386667l96 110.08a384 384 0 0 1-253.013333 93.226667z" fill="#9EEBFF" ></path><path d="M510.293333 736.64l5.546667-200.96-3.84-12.373333 155.093333 173.653333s-128.426667 92.373333-156.8 39.68z" fill="#31C4FF" ></path><path d="M512 112.64v148.053333s-144 30.293333-158.72 69.973334c-22.826667-29.013333-85.333333-129.28-85.333333-129.28S373.12 108.8 512 112.64z" fill="#FFA426" ></path><path d="M513.92 279.466667l-5.76 200.96-3.2 21.333333-152.96-169.813333s133.546667-104.106667 161.92-52.48z" fill="#FE8205" ></path><path d="M231.04 795.52l103.68-107.946667s-90.026667-129.706667-73.6-169.6c-37.973333 4.053333-141.866667 5.546667-141.866667 5.546667s1.493333 171.093333 111.786667 272z" fill="#FF636E" ></path><path d="M344.32 677.546667l135.253333-149.333334 11.306667-6.613333-234.666667-1.493333s31.786667 174.933333 88.106667 157.44z" fill="#F03049" ></path><path d="M778.666667 229.333333l-106.666667 119.04s102.186667 135.68 86.4 178.986667c40.533333-5.546667 151.68-10.666667 151.68-10.666667s-8.96-183.04-131.413333-287.36z" fill="#6ED678" ></path><path d="M662.4 344.746667l-128 152.96-11.093333 6.613333 247.253333 5.12s-50.773333-181.973333-108.16-164.693333z" fill="#37D346" ></path><path d="M512 917.333333a405.333333 405.333333 0 1 1 405.333333-405.333333 405.333333 405.333333 0 0 1-405.333333 405.333333z m0-789.333333a384 384 0 1 0 384 384A384 384 0 0 0 512 128z" fill="currentColor" ></path><path d="M113.706667 506.026667h798.72v21.333333H113.706667z" fill="currentColor" ></path><path d="M498.986667 118.613333h21.333333v794.026667h-21.333333z" fill="currentColor" ></path><path d="M225.941333 773.632L779.413333 220.16l15.082667 15.082667-553.472 553.472z" fill="currentColor" ></path><path d="M250.176 215.466667l16.32-13.738667 514.432 611.562667-16.32 13.738666z" fill="currentColor" ></path><path d="M512 768a256 256 0 1 1 256-256 256 256 0 0 1-256 256z m0-490.666667a234.666667 234.666667 0 1 0 234.666667 234.666667 234.666667 234.666667 0 0 0-234.666667-234.666667z" fill="currentColor" ></path></symbol><symbol id="dakaiquanbutuceng" viewBox="0 0 1024 1024"><path d="M830.506667 763.52h-64a23.253333 23.253333 0 0 0-22.613334 28.586667L768 894.72a23.04 23.04 0 0 0 22.613333 18.133333h16.853334a23.253333 23.253333 0 0 0 22.826666-18.346666L853.333333 791.893333a23.04 23.04 0 0 0-22.826666-28.373333z" fill="currentColor" ></path><path d="M726.613333 735.573333a149.333333 149.333333 0 1 1 153.386667 0" fill="#FF9800" ></path><path d="M730.88 202.026667l-205.013333-99.2a34.133333 34.133333 0 0 0-23.04 0l-206.08 96.64-180.266667 86.826666a20.053333 20.053333 0 0 0 0 36.266667l179.2 88.746667 205.013333 99.413333a35.413333 35.413333 0 0 0 23.04 0l205.866667-96.853333 180.266667-86.826667a19.84 19.84 0 0 0 0-36.053333z" fill="currentColor" ></path><path d="M587.093333 628.693333a200.746667 200.746667 0 0 1 39.466667-119.68l-103.253333 48.213334a35.413333 35.413333 0 0 1-23.04 0l-135.893334-65.493334-69.12-33.92-53.76-26.24L115.2 490.666667a20.053333 20.053333 0 0 0 0 36.266666l179.2 88.746667 204.8 99.413333a37.546667 37.546667 0 0 0 23.253333 0l71.466667-33.706666a203.52 203.52 0 0 1-6.826667-52.693334z" fill="currentColor" ></path><path d="M667.306667 791.893333a211.413333 211.413333 0 0 1-59.093334-68.266666l-85.333333 40.32a36.906667 36.906667 0 0 1-23.04 0L362.666667 698.453333l-69.12-34.133333-53.973334-26.026667-125.44 58.666667a19.84 19.84 0 0 0 0 36.053333l179.2 88.96 205.013334 99.2a34.133333 34.133333 0 0 0 23.04 0l158.933333-74.666666z" fill="currentColor" ></path></symbol><symbol id="xuanzeguanbituceng" viewBox="0 0 1024 1024"><path d="M719.146667 202.026667L514.133333 102.826667a34.133333 34.133333 0 0 0-23.04 0l-206.08 96.64-180.266666 86.826666a20.053333 20.053333 0 0 0 0 36.266667l179.413333 88.746667 204.8 99.413333a35.626667 35.626667 0 0 0 23.04 0l206.08-96.853333 180.266667-86.826667a19.84 19.84 0 0 0 0-36.053333zM807.893333 770.56h-64a23.253333 23.253333 0 0 0-22.826666 28.586667l24.106666 102.826666a23.466667 23.466667 0 0 0 22.826667 17.92h16.853333a23.68 23.68 0 0 0 22.826667-18.346666l22.826667-102.613334a23.466667 23.466667 0 0 0-22.613334-28.373333z" fill="currentColor" ></path><path d="M704 742.613333a149.333333 149.333333 0 1 1 153.6 0" fill="#57B8FF" ></path></symbol><symbol id="a-3-5xianxing" viewBox="0 0 1024 1024"><path d="M128.213333 153.386667h21.333334v42.666666h-21.333334zM832 196.053333h-42.666667v-42.666666h42.666667z m-85.333333 0h-42.666667v-42.666666h42.666667z m-85.333334 0h-42.666666v-42.666666h42.666666z m-85.333333 0h-42.666667v-42.666666h42.666667z m-85.333333 0h-42.666667v-42.666666h42.666667z m-85.333334 0h-42.666666v-42.666666h42.666666z m-85.333333 0h-42.666667v-42.666666h42.666667z m-85.333333 0H192v-42.666666h42.666667zM874.666667 153.386667h21.333333v42.666666h-21.333333zM128.213333 322.986667h42.666667v42.666666h-42.666667zM777.6 365.653333h-75.946667v-42.666666h75.946667z m-151.68 0h-75.946667v-42.666666h75.946667z m-151.68 0h-75.946667v-42.666666h75.946667z m-151.68 0h-75.946667v-42.666666h75.946667zM853.333333 322.986667h42.666667v42.666666h-42.666667zM128.213333 491.733333H896v42.666667H128.213333z" fill="currentColor" ></path><path d="M128 658.773333h64v42.666667H128zM704 701.44h-128v-42.666667h128z m-256 0h-128v-42.666667h128zM831.786667 658.773333h64v42.666667h-64z" fill="currentColor" ></path><path d="M128 836.053333h85.333333v42.666667H128zM412.373333 836.053333h199.04v42.666667h-199.04zM810.453333 836.053333h85.333334v42.666667h-85.333334z" fill="currentColor" ></path></symbol><symbol id="dianyangshi" viewBox="0 0 1024 1024"><path d="M408.96 229.973333m-85.333333 0a85.333333 85.333333 0 1 0 170.666666 0 85.333333 85.333333 0 1 0-170.666666 0Z" fill="currentColor" ></path><path d="M205.226667 431.786667m-85.333334 0a85.333333 85.333333 0 1 0 170.666667 0 85.333333 85.333333 0 1 0-170.666667 0Z" fill="currentColor" ></path><path d="M620.8 427.093333m-85.333333 0a85.333333 85.333333 0 1 0 170.666666 0 85.333333 85.333333 0 1 0-170.666666 0Z" fill="currentColor" ></path><path d="M408.96 628.693333m-85.333333 0a85.333333 85.333333 0 1 0 170.666666 0 85.333333 85.333333 0 1 0-170.666666 0Z" fill="currentColor" ></path><path d="M545.066667 874.666667c-45.866667 21.333333-145.706667-24.746667-109.44-23.253334 58.666667 1.92 38.4-40.746667 76.373333-71.253333s74.88-35.626667 89.6-2.56S590.933333 853.333333 545.066667 874.666667z" fill="currentColor" ></path><path d="M664.32 746.666667l240.426667-239.36a33.92 33.92 0 0 0 9.6-22.4 34.133333 34.133333 0 0 0 21.333333-9.813334 34.56 34.56 0 0 0 0-48.853333 34.56 34.56 0 0 0-48.853333 0 34.346667 34.346667 0 0 0-8.533334 21.76 33.706667 33.706667 0 0 0-22.4 9.813333L615.466667 698.666667a53.546667 53.546667 0 0 0-40.746667 15.146666A52.693333 52.693333 0 0 0 649.173333 789.333333a51.413333 51.413333 0 0 0 15.146667-42.666666z" fill="#FF9800" ></path></symbol><symbol id="wenziyangshi" viewBox="0 0 1024 1024"><path d="M688.426667 817.92H597.333333l-65.92-184.32H264.32l-61.866667 184.32H110.933333L355.413333 144.213333h88.746667z m-182.613334-260.48L408.96 277.333333a307.84 307.84 0 0 1-10.026667-46.933333h-2.133333a271.146667 271.146667 0 0 1-10.24 46.933333l-96.213333 280.106667z" fill="currentColor" ></path><path d="M553.386667 874.666667c-45.866667 20.266667-145.706667-24.746667-109.653334-23.253334 58.88 2.133333 38.613333-41.173333 76.586667-70.613333s75.093333-35.84 89.6-2.773333-10.666667 75.306667-56.533333 96.64z" fill="currentColor" ></path><path d="M672.853333 747.733333l240.64-240.64a33.92 33.92 0 0 0 9.6-22.4 33.493333 33.493333 0 0 0 21.333334-9.6 34.346667 34.346667 0 0 0 0-48.853333A34.346667 34.346667 0 0 0 896 426.666667a34.56 34.56 0 0 0-9.813333 21.333333 34.56 34.56 0 0 0-21.333334 9.813333l-240.853333 241.066667a52.053333 52.053333 0 0 0-40.96 15.146667 52.693333 52.693333 0 1 0 89.813333 33.706666z" fill="#FF9800" ></path></symbol><symbol id="tuceng" viewBox="0 0 1024 1024"><path d="M730.453333 202.026667l-204.8-99.2a34.773333 34.773333 0 0 0-23.253333 0l-206.08 96.64-180.266667 86.826666a20.053333 20.053333 0 0 0 0 36.266667l179.413334 88.746667 204.8 99.413333a35.413333 35.413333 0 0 0 23.04 0l206.08-96.853333 180.266666-86.826667a19.84 19.84 0 0 0 0-36.053333z" fill="currentColor" ></path><path d="M908.586667 494.933333l-125.44-60.16-54.186667 25.6-69.546667 33.066667-136.533333 64a35.413333 35.413333 0 0 1-23.04 0l-135.68-65.493333-69.333333-33.92-53.76-26.453334L114.986667 490.666667a20.053333 20.053333 0 0 0 0 36.266666l179.2 88.746667 205.013333 99.413333a36.906667 36.906667 0 0 0 23.04 0L728.106667 618.666667l180.266666-86.613334a18.986667 18.986667 0 0 0 0.213334-37.12z" fill="currentColor" ></path><path d="M907.306667 701.44l-125.44-59.946667-54.186667 25.386667-69.546667 33.28-136.32 64a37.546667 37.546667 0 0 1-23.253333 0L362.666667 698.453333l-69.12-34.133333-53.76-26.026667-126.08 58.666667a19.84 19.84 0 0 0 0 36.053333l179.2 88.96 205.013333 99.2a34.133333 34.133333 0 0 0 23.04 0l206.08-96.853333 180.266667-86.826667a18.986667 18.986667 0 0 0 0-36.053333z" fill="currentColor" ></path></symbol><symbol id="shiqubeijingse" viewBox="0 0 1024 1024"><path d="M395.733333 149.333333H128a21.333333 21.333333 0 0 1 0-42.666666h267.733333a21.333333 21.333333 0 0 1 0 42.666666zM896 149.333333H628.266667a21.333333 21.333333 0 0 1 0-41.6H896a21.333333 21.333333 0 0 1 0 42.666667zM894.293333 917.333333H625.92a21.333333 21.333333 0 0 1 0-42.666666h268.373333a21.333333 21.333333 0 0 1 0 42.666666zM398.08 915.2H129.706667a21.333333 21.333333 0 0 1 0-42.666667h268.373333a21.333333 21.333333 0 0 1 0 42.666667z" fill="currentColor" ></path><path d="M896 417.28a21.333333 21.333333 0 0 1-21.333333-21.333333V128a21.333333 21.333333 0 1 1 42.666666 0v268.586667a21.333333 21.333333 0 0 1-21.333333 20.693333zM894.293333 917.333333a21.333333 21.333333 0 0 1-21.333333-21.333333V627.413333a21.333333 21.333333 0 1 1 41.386667 0V896a21.333333 21.333333 0 0 1-20.053334 21.333333zM129.706667 912.853333a21.333333 21.333333 0 0 1-21.333334-21.333333V622.933333a21.333333 21.333333 0 1 1 41.386667 0v269.013334a21.333333 21.333333 0 0 1-20.053333 20.906666zM128 421.973333a21.333333 21.333333 0 0 1-21.333333-21.333333V132.053333a21.333333 21.333333 0 1 1 42.666666 0V401.066667a21.333333 21.333333 0 0 1-21.333333 20.906666z" fill="currentColor" ></path><path d="M236.586667 227.626667h170.666666v298.666666h-170.666666z" fill="#DD4CE5" ></path><path d="M443.733333 227.626667h341.333334v298.666666h-341.333334z" fill="#5BD84E" ></path><path d="M236.586667 583.04h170.666666v213.333333h-170.666666z" fill="#AF58ED" ></path><path d="M446.08 580.693333h341.333333v213.333334h-341.333333z" fill="#EFBF3A" ></path></symbol><symbol id="a-2-5shiquxuanzhuan" viewBox="0 0 1024 1024"><path d="M251.733333 389.76m64 0l542.72 0q64 0 64 64l0 384q0 64-64 64l-542.72 0q-64 0-64-64l0-384q0-64 64-64Z" fill="currentColor" ></path><path d="M130.346667 655.36a21.333333 21.333333 0 0 1-21.333334-21.333333V345.173333c0-61.866667 10.026667-97.28 34.56-121.813333 42.666667-42.666667 128-42.666667 294.613334-42.666667h87.68a21.333333 21.333333 0 0 1 0 42.666667h-87.893334c-149.333333 0-233.173333-1.28-264.106666 29.653333-15.573333 15.573333-21.333333 42.666667-21.333334 91.52v289.493334a21.333333 21.333333 0 0 1-22.186666 21.333333z" fill="#57B8FF" ></path><path d="M490.24 342.613333l-0.853333-135.893333-0.64-136.106667 86.826666 67.626667 87.04 67.413333-86.186666 68.48-86.186667 68.48z" fill="#57B8FF" ></path></symbol><symbol id="a-2-5-3zidingyi" viewBox="0 0 1024 1024"><path d="M701.44 709.973333a210.773333 210.773333 0 0 1 28.8-55.893333 588.16 588.16 0 0 1 42.666667-49.493333c12.586667-13.013333 22.613333-23.893333 29.653333-32.64a116.053333 116.053333 0 0 0 17.28-29.013334 86.826667 86.826667 0 0 0 7.04-35.413333 67.2 67.2 0 0 0-23.253333-54.613333 101.546667 101.546667 0 0 0-65.493334-18.986667 91.733333 91.733333 0 0 0-69.76 24.106667 101.76 101.76 0 0 0-23.893333 72.106666h-91.733333a170.666667 170.666667 0 0 1 21.333333-85.333333 129.28 129.28 0 0 1 61.653333-51.413333 256 256 0 0 1 100.693334-17.28 282.666667 282.666667 0 0 1 98.986666 15.573333 133.546667 133.546667 0 0 1 62.293334 45.226667 119.466667 119.466667 0 0 1 21.333333 71.893333 124.373333 124.373333 0 0 1-8.533333 48 152.746667 152.746667 0 0 1-21.333334 35.84c-8.32 10.026667-19.626667 21.333333-33.706666 36.266667a565.546667 565.546667 0 0 0-40.32 42.666666A162.346667 162.346667 0 0 0 789.333333 719.573333a202.666667 202.666667 0 0 0-9.813333 69.76h-89.813333a234.666667 234.666667 0 0 1 11.733333-79.36z m-15.573333 141.013334h97.706666v68.48h-97.706666z" fill="currentColor" ></path><path d="M125.226667 689.066667a21.333333 21.333333 0 0 1-21.333334-21.333334V378.88c0-61.866667 10.24-97.066667 34.773334-121.6 43.733333-42.666667 128-42.666667 294.613333-42.666667h87.68a21.333333 21.333333 0 0 1 0 42.666667h-88.106667c-149.333333 0-232.96-1.28-264.106666 29.653333-15.36 15.36-21.333333 42.666667-21.333334 91.306667V667.733333a21.333333 21.333333 0 0 1-22.186666 21.333334z" fill="#57B8FF" ></path><path d="M485.333333 376.32l-0.853333-135.893333-0.64-135.893334 86.826667 67.413334 87.04 67.413333-86.186667 68.48-86.186667 68.48z" fill="#57B8FF" ></path></symbol><symbol id="a-2-5-2nishizhen" viewBox="0 0 1024 1024"><path d="M899.626667 854.826667a21.333333 21.333333 0 0 1-21.333334-21.333334v-341.333333c0-52.906667-8.32-83.626667-27.733333-103.04-45.226667-45.226667-167.68-44.586667-411.306667-42.666667h-131.626666a21.333333 21.333333 0 0 1 0-42.666666h131.413333c263.466667-1.066667 384-1.706667 441.6 55.893333 28.373333 28.16 40.32 68.053333 40.32 133.333333v341.333334a21.333333 21.333333 0 0 1-21.333333 20.48z" fill="currentColor" ></path><path d="M360.96 489.813333l1.28-160.426666 1.066667-160.213334-130.133334 79.573334-130.133333 79.573333 129.066667 80.853333 128.853333 80.64z" fill="currentColor" ></path></symbol><symbol id="a-2-5-1shunshizhen" viewBox="0 0 1024 1024"><path d="M124.373333 854.826667a21.333333 21.333333 0 0 1-21.333333-21.333334v-341.333333c0-65.28 11.946667-105.173333 40.32-133.333333 57.813333-57.6 178.346667-57.173333 441.6-55.893334h131.413333a21.333333 21.333333 0 0 1 0 42.666667h-131.626666c-243.413333-1.066667-366.08-1.706667-411.306667 42.666667-19.413333 19.413333-27.733333 50.133333-27.733333 103.04v341.333333a21.333333 21.333333 0 0 1-21.333334 22.186667z" fill="currentColor" ></path><path d="M663.04 489.813333l-1.28-160.426666-1.066667-160.213334 130.133334 79.573334 130.133333 79.573333-129.066667 80.853333-128.853333 80.64z" fill="currentColor" ></path></symbol><symbol id="a-4-8duixiangtexing" viewBox="0 0 1024 1024"><path d="M710.613333 892.8a21.333333 21.333333 0 0 1-21.333333-21.333333 280.32 280.32 0 0 0-561.28 0 21.333333 21.333333 0 0 1-42.666667 0 322.986667 322.986667 0 0 1 645.973334 0 21.333333 21.333333 0 0 1-20.693334 21.333333z" fill="currentColor" ></path><path d="M401.706667 565.76A238.293333 238.293333 0 1 1 640 327.68a238.506667 238.506667 0 0 1-238.293333 238.08z m0-433.706667A195.626667 195.626667 0 1 0 597.333333 327.68a195.84 195.84 0 0 0-195.626666-195.626667z" fill="currentColor" ></path><path d="M561.706667 513.066667m44.16 0l288.213333 0q44.16 0 44.16 44.16l0 333.44q0 44.16-44.16 44.16l-288.213333 0q-44.16 0-44.16-44.16l0-333.44q0-44.16 44.16-44.16Z" fill="#57B8FF" ></path><path d="M658.986667 607.146667m-21.546667 0a21.546667 21.546667 0 1 0 43.093333 0 21.546667 21.546667 0 1 0-43.093333 0Z" fill="currentColor" ></path><path d="M700.8 586.24m20.053333 0l98.346667 0q20.053333 0 20.053333 20.053333l0 2.986667q0 20.053333-20.053333 20.053333l-98.346667 0q-20.053333 0-20.053333-20.053333l0-2.986667q0-20.053333 20.053333-20.053333Z" fill="currentColor" ></path><path d="M659.413333 715.52m-21.546666 0a21.546667 21.546667 0 1 0 43.093333 0 21.546667 21.546667 0 1 0-43.093333 0Z" fill="currentColor" ></path><path d="M701.44 694.826667m21.546667 0l133.76 0q21.546667 0 21.546666 21.546666l0 0q0 21.546667-21.546666 21.546667l-133.76 0q-21.546667 0-21.546667-21.546667l0 0q0-21.546667 21.546667-21.546666Z" fill="currentColor" ></path><path d="M660.053333 824.106667m-21.546666 0a21.546667 21.546667 0 1 0 43.093333 0 21.546667 21.546667 0 1 0-43.093333 0Z" fill="currentColor" ></path><path d="M702.08 803.2m21.546667 0l152.96 0q21.546667 0 21.546666 21.546667l0 0q0 21.546667-21.546666 21.546666l-152.96 0q-21.546667 0-21.546667-21.546666l0 0q0-21.546667 21.546667-21.546667Z" fill="currentColor" ></path></symbol><symbol id="a-4-7kuaisuxuanze" viewBox="0 0 1024 1024"><path d="M194.346667 884.693333h-64a21.333333 21.333333 0 1 1 0-42.666666h64a21.333333 21.333333 0 0 1 0 42.666666z" fill="currentColor" ></path><path d="M173.013333 863.573333a21.333333 21.333333 0 0 1 21.333334-21.333333 21.333333 21.333333 0 0 1 21.333333 21.333333 21.333333 21.333333 0 0 1-21.333333 21.333334 21.333333 21.333333 0 0 1-21.333334-21.333334zM672.213333 884.693333h-119.466666a21.333333 21.333333 0 1 1 0-42.666666h119.466666a21.333333 21.333333 0 0 1 0 42.666666z m-238.933333 0h-119.466667a21.333333 21.333333 0 0 1 0-42.666666h119.466667a21.333333 21.333333 0 1 1 0 42.666666zM855.68 884.693333h-64a21.333333 21.333333 0 0 1 0-42.666666h64a21.333333 21.333333 0 0 1 0 42.666666z" fill="currentColor" ></path><path d="M194.56 154.24h-64a21.333333 21.333333 0 0 1 0-42.666667h64a21.333333 21.333333 0 0 1 0 42.666667z" fill="currentColor" ></path><path d="M173.226667 133.12a21.333333 21.333333 0 0 1 21.333333-21.333333 21.333333 21.333333 0 0 1 21.333333 21.333333 21.333333 21.333333 0 0 1-21.333333 21.333333 21.333333 21.333333 0 0 1-21.333333-21.333333zM672.426667 154.453333h-119.466667a21.333333 21.333333 0 0 1 0-42.666666h119.466667a21.333333 21.333333 0 1 1 0 42.666666z m-238.933334 0h-119.253333a21.333333 21.333333 0 1 1 0-42.666666h119.253333a21.333333 21.333333 0 0 1 0 42.666666zM855.893333 154.24h-64a21.333333 21.333333 0 0 1 0-42.666667h64a21.333333 21.333333 0 0 1 0 42.666667z" fill="currentColor" ></path><path d="M130.346667 878.933333a21.333333 21.333333 0 0 1-21.333334-21.333333v-64a21.333333 21.333333 0 0 1 42.666667 0v64a21.333333 21.333333 0 0 1-21.333333 21.333333z" fill="currentColor" ></path><path d="M109.013333 793.813333a21.333333 21.333333 0 0 1 21.333334-21.333333 21.333333 21.333333 0 0 1 21.333333 21.333333 21.333333 21.333333 0 0 1-21.333333 21.333334 21.333333 21.333333 0 0 1-21.333334-21.333334zM130.346667 695.466667a21.333333 21.333333 0 0 1-21.333334-21.333334V554.666667a21.333333 21.333333 0 0 1 42.666667 0v119.466666a21.333333 21.333333 0 0 1-21.333333 21.333334z m0-238.933334a21.333333 21.333333 0 0 1-21.333334-21.333333v-119.466667a21.333333 21.333333 0 0 1 42.666667 0v119.466667a21.333333 21.333333 0 0 1-21.333333 21.333333zM130.346667 217.6a21.333333 21.333333 0 0 1-21.333334-21.333333v-64a21.333333 21.333333 0 0 1 42.666667 0v64a21.333333 21.333333 0 0 1-21.333333 21.333333z" fill="currentColor" ></path><path d="M855.893333 878.933333a21.333333 21.333333 0 0 1-21.333333-21.333333v-64a21.333333 21.333333 0 0 1 42.666667 0v64a21.333333 21.333333 0 0 1-21.333334 21.333333z" fill="currentColor" ></path><path d="M834.56 793.813333a21.333333 21.333333 0 0 1 21.333333-21.333333 21.333333 21.333333 0 0 1 21.333334 21.333333 21.333333 21.333333 0 0 1-21.333334 21.333334 21.333333 21.333333 0 0 1-21.333333-21.333334zM855.893333 695.466667a21.333333 21.333333 0 0 1-21.333333-21.333334V554.666667a21.333333 21.333333 0 1 1 42.666667 0v119.466666a21.333333 21.333333 0 0 1-21.333334 21.333334z m0-238.933334a21.333333 21.333333 0 0 1-21.333333-21.333333v-119.466667a21.333333 21.333333 0 0 1 42.666667 0v119.68a21.333333 21.333333 0 0 1-21.333334 21.12zM855.893333 217.6a21.333333 21.333333 0 0 1-21.333333-21.333333v-64a21.333333 21.333333 0 0 1 42.666667 0v64a21.333333 21.333333 0 0 1-21.333334 21.333333z" fill="currentColor" ></path><path d="M260.48 262.826667m21.333333 0l426.666667 0q21.333333 0 21.333333 21.333333l0 426.666667q0 21.333333-21.333333 21.333333l-426.666667 0q-21.333333 0-21.333333-21.333333l0-426.666667q0-21.333333 21.333333-21.333333Z" fill="currentColor" ></path><path d="M782.72 802.133333a21.333333 21.333333 0 0 1-15.146667-6.4l-124.16-124.16a21.333333 21.333333 0 0 1 30.08-30.08l124.16 124.16a21.333333 21.333333 0 0 1 0 30.08 21.333333 21.333333 0 0 1-14.933333 6.4z" fill="#57B8FF" ></path><path d="M445.44 443.52c137.386667 62.933333 325.12 123.946667 469.333333 133.76l-228.693333 106.666667-106.666667 228.693333c-10.026667-144.64-71.04-331.733333-133.973333-469.12z" fill="#57B8FF" ></path><path d="M697.386667 174.72l-152.32 152.32 140.16 38.186667-120.32 119.68 227.2-135.253334-129.493334-44.16 34.773334-130.773333z" fill="#FF9800" ></path></symbol><symbol id="celiangjiaodu" viewBox="0 0 1024 1024"><path d="M909.44 658.986667H114.56a28.16 28.16 0 0 0-28.16 28.16v167.68a28.16 28.16 0 0 0 28.16 28.16h794.88A28.16 28.16 0 0 0 938.666667 854.826667v-167.68a28.16 28.16 0 0 0-29.226667-28.16zM220.8 836.266667h-44.8v-134.4h44.8z m130.773333-44.8h-44.8v-89.6h44.8z m124.16 21.333333h-44.8v-110.933333h44.8z m115.84 22.4h-44.8V701.866667h44.8z m122.026667-44.8h-44.8V701.866667h44.8z m134.4 21.333333h-44.8V701.866667h44.8zM198.4 506.88a21.333333 21.333333 0 0 1-22.4-22.4V144.426667a21.333333 21.333333 0 1 1 44.8 0v340.053333a21.333333 21.333333 0 0 1-22.4 22.4z" fill="currentColor" ></path><path d="M825.6 506.88H199.466667a21.333333 21.333333 0 1 1 0-44.586667H825.6a21.333333 21.333333 0 1 1 0 44.586667z" fill="currentColor" ></path><path d="M624.64 352.853333c-57.813333-134.186667-173.653333-138.026667-260.906667-117.333333l-10.24-42.666667c85.333333-20.053333 238.72-27.946667 312.32 143.36z" fill="#57B8FF" ></path><path d="M391.466667 263.68l-109.013334-24.106667 75.306667-82.346666 33.706667 106.453333zM585.6 346.453333l83.413333 74.453334 22.613334-109.44-106.026667 34.986666z" fill="#57B8FF" ></path></symbol><symbol id="bianjiwenzi" viewBox="0 0 1024 1024"><path d="M832 877.013333h-85.333333v-42.666666h85.333333z m-170.666667 0h-85.333333v-42.666666h85.333333z m-170.666666 0h-85.333334v-42.666666h85.333334z m-170.666667 0h-85.333333v-42.666666h85.333333z m-128-51.84H149.333333v-85.333333h42.666667z m682.666667-6.186666h-42.666667v-85.333334h42.666667zM192 654.506667H149.333333v-85.333334h42.666667z m682.666667-6.186667h-42.666667v-85.333333h42.666667zM192 483.84H149.333333v-85.333333h42.666667z m682.666667-6.186667h-42.666667v-85.333333h42.666667zM192 313.173333H149.333333v-85.333333h42.666667z m682.666667-6.186666h-42.666667v-85.333334h42.666667z m-67.2-112.64h-85.333334v-42.666667h85.333334z m-170.666667 0h-85.333333v-42.666667h85.333333z m-170.666667 0h-85.333333v-42.666667h85.333333z m-170.666666 0h-85.333334v-42.666667h85.333334z" fill="currentColor" ></path><path d="M106.453333 128.64m21.333334 0l85.333333 0q21.333333 0 21.333333 21.333333l0 85.333334q0 21.333333-21.333333 21.333333l-85.333333 0q-21.333333 0-21.333334-21.333333l0-85.333334q0-21.333333 21.333334-21.333333Z" fill="#57B8FF" ></path><path d="M106.453333 778.026667m21.333334 0l85.333333 0q21.333333 0 21.333333 21.333333l0 85.333333q0 21.333333-21.333333 21.333334l-85.333333 0q-21.333333 0-21.333334-21.333334l0-85.333333q0-21.333333 21.333334-21.333333Z" fill="#57B8FF" ></path><path d="M789.12 778.026667m21.333333 0l85.333334 0q21.333333 0 21.333333 21.333333l0 85.333333q0 21.333333-21.333333 21.333334l-85.333334 0q-21.333333 0-21.333333-21.333334l0-85.333333q0-21.333333 21.333333-21.333333Z" fill="#57B8FF" ></path><path d="M789.12 117.973333m21.333333 0l85.333334 0q21.333333 0 21.333333 21.333334l0 85.333333q0 21.333333-21.333333 21.333333l-85.333334 0q-21.333333 0-21.333333-21.333333l0-85.333333q0-21.333333 21.333333-21.333334Z" fill="#57B8FF" ></path><path d="M432.64 759.466667a55.68 55.68 0 0 1-3.2-24.746667 83.84 83.84 0 0 0 53.333333-61.866667V327.893333a2.986667 2.986667 0 0 0-2.346666-2.346666 190.72 190.72 0 0 0-28.373334-2.346667 101.546667 101.546667 0 0 0-104.106666 89.386667h-47.36v-123.733334h422.826666v123.733334h-47.36a101.546667 101.546667 0 0 0-104.106666-89.386667 190.72 190.72 0 0 0-28.373334 2.346667 2.986667 2.986667 0 0 0-2.346666 2.346666v349.013334a85.333333 85.333333 0 0 0 51.413333 57.6c3.413333 2.133333 1.92 13.44-1.28 24.96z" fill="#57B8FF" ></path><path d="M720.853333 291.413333v118.4h-42.666666a104.106667 104.106667 0 0 0-106.666667-89.386666 173.653333 173.653333 0 0 0-28.8 2.56 5.333333 5.333333 0 0 0-4.48 4.693333c-1.066667 8.96 0 292.48 0 349.226667a2.773333 2.773333 0 0 0 0 1.28 87.893333 87.893333 0 0 0 53.333333 58.88 81.706667 81.706667 0 0 1-3.2 19.626666h-153.6a106.666667 106.666667 0 0 1-3.626666-19.626666 88.32 88.32 0 0 0 54.186666-64c0-78.933333 1.066667-336.64 0-345.173334a5.333333 5.333333 0 0 0-4.48-4.693333 173.653333 173.653333 0 0 0-28.8-3.2 104.106667 104.106667 0 0 0-106.666666 89.386667h-42.666667v-117.973334h418.133333m5.333334-5.333333H298.666667v129.066667h52.48a99.2 99.2 0 0 1 101.76-89.386667 167.893333 167.893333 0 0 1 27.946666 2.56c1.066667 8.533333 0 294.826667 0 344.533333A83.413333 83.413333 0 0 1 426.666667 732.8c-4.266667 4.266667 3.2 29.44 3.2 29.44h162.56s7.466667-25.173333 3.2-29.44h-2.986667a82.346667 82.346667 0 0 1-49.493333-55.04c0-35.626667-1.066667-339.84 0-348.586667a167.893333 167.893333 0 0 1 27.946666-2.56 99.2 99.2 0 0 1 101.76 89.386667H725.333333v-129.92z" fill="#57B8FF" ></path></symbol></svg>',(t=>{var e=(l=(l=document.getElementsByTagName("script"))[l.length-1]).getAttribute("data-injectcss"),l=l.getAttribute("data-disable-injectsvg");if(!l){var n,u,c,y,b,m=function(L,G){G.parentNode.insertBefore(L,G)};if(e&&!t.__iconfont__svg__cssinject__){t.__iconfont__svg__cssinject__=!0;try{document.write("<style>.svgfont {display: inline-block;width: 1em;height: 1em;fill: currentColor;vertical-align: -0.1em;font-size:16px;}</style>")}catch(L){console&&console.log(L)}}n=function(){var L,G=document.createElement("div");G.innerHTML=t._iconfont_svg_string_4507478,(G=G.getElementsByTagName("svg")[0])&&(G.setAttribute("aria-hidden","true"),G.style.position="absolute",G.style.width=0,G.style.height=0,G.style.overflow="hidden",G=G,(L=document.body).firstChild?m(G,L.firstChild):L.appendChild(G))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(n,0):(u=function(){document.removeEventListener("DOMContentLoaded",u,!1),n()},document.addEventListener("DOMContentLoaded",u,!1)):document.attachEvent&&(c=n,y=t.document,b=!1,N(),y.onreadystatechange=function(){y.readyState=="complete"&&(y.onreadystatechange=null,O())})}function O(){b||(b=!0,c())}function N(){try{y.documentElement.doScroll("left")}catch{return void setTimeout(N,50)}O()}})(window);function isMobileOrTablet(){const t=navigator.userAgent.toLowerCase(),e="ontouchstart"in window||navigator.maxTouchPoints>0,l=window.innerWidth,n=window.innerHeight,u=l<=768||l<=1024&&n<=768,c=/mobi|android|ios|iphone|ipad|ipod|windows phone|iemobile|blackberry|opera mini|mobile|silk/i.test(t),y=e&&l>1024&&n>768;return(c||e&&u)&&!y}const app=createApp(_sfc_main);initConfig().then(async()=>{console.log("加载配置成功");function t(l){l.forEach(n=>{const u=new Image;u.src=n})}t([getLogoImgSrc()]),serverConfig.isAutomaticJumpToMobilePage&&isMobileOrTablet()&&(window.location.href="https://demo.mxdraw3d.com:3000/mxcad_mobile/"),console.log("注册内部插件中..."),await vuetify.install(app),registerPlugins(app).use(Directives).mount("#app"),console.log("注册内部插件成功");const{onFirstTimeOpenComplete:e}=useFirstTimeOpenDwg();e(async()=>{console.log("正在注册命令中..."),await __vitePreload(()=>import("./index-CL_f6Mbr.js"),__vite__mapDeps([72,19,59,54]),import.meta.url),console.log("注册命令成功")})});export{MxCursorType as $,MxCADUiPrKeyWord as A,useColor$1 as B,Color$1 as C,DetailedResult as D,MxCADUiPrDist as E,MxThreeJS as F,DynamicInputType as G,getUrlConfig as H,keyBindingManager as I,useMessage as J,McDb as K,McDb2LineAngularDimension as L,MxElectronAPI as M,browserCacheRef as N,MxCADSelectionSet as O,McDbEllipse as P,getFileSize as Q,useLoadingData as R,onOpenFileComplete as S,MxCoordConvert as T,MxDbLine as U,McGiWorldDrawType$1 as V,MxDbText as W,MxDbEntity as X,keepDecimal as Y,MrxDbgUiPrPoint as Z,_ML_String as _,isFullscreen as a,watch as a$,DxfCode as a0,McDbBlockReference as a1,uploadFile as a2,getHostUrl$1 as a3,useMultilineTextDialog as a4,McDbMText as a5,getUploadFileConfig as a6,getBaseUrl as a7,setFileTips as a8,setTipsShow as a9,withDirectives as aA,vShow as aB,MxFieldset as aC,MxGetPointBtn as aD,VImg as aE,VSelect as aF,VCheckbox as aG,MxCADUiPrInt as aH,UserInputControls as aI,McGeMatrix3d as aJ,updateDisplay as aK,reactive as aL,getRetainDecimalPlaces as aM,VCombobox as aN,VIcon as aO,MxDialogBtn as aP,storeToRefs as aQ,computed as aR,onMounted as aS,indexOfMxColor as aT,ColorNameType as aU,ColorMethod as aV,createElementBlock as aW,Fragment as aX,renderList as aY,normalizeClass as aZ,normalizeStyle as a_,FetchAttributes as aa,timeoutHideTip as ab,axios as ac,setFileName as ad,defineComponent$1 as ae,useDialogIsShow as af,ref as ag,createBlock as ah,withCtx as ai,unref as aj,isRef as ak,openBlock as al,createBaseVNode as am,createVNode as an,VCol as ao,toDisplayString as ap,getVersion as aq,VDivider as ar,VRow as as,createTextVNode as at,VTextField as au,createCommentVNode as av,_export_sfc$2 as aw,VRadioGroup as ax,VRadio as ay,_sfc_main$a as az,MxCpp as b,getDefaultExportFromCjs as b$,h as b0,countColorInfo as b1,getBlockNames as b2,McDbBlockTableRecord as b3,usePopup as b4,VProgressLinear as b5,VBtn as b6,VList as b7,VListItemTitle as b8,VListItem as b9,Ripple as bA,VTable as bB,useDebounceFn as bC,readPatFileText as bD,fileToBlob as bE,iconCache as bF,shallowRef as bG,onBeforeUnmount as bH,markRaw as bI,watchEffect as bJ,Teleport as bK,customRef as bL,getCurrentInstance$1 as bM,useTextStyle as bN,getColorName as bO,ColorMethod$1 as bP,clampNumber as bQ,MxColorSelect as bR,McDbText as bS,McDbHatch as bT,preservePointDotStyleStatus as bU,initPointDotStyleStatus as bV,pointDotStyleStatus as bW,pointDotModeValues as bX,resolveDynamicComponent as bY,getFilterImp as bZ,MxDbRect as b_,onLoadComplete as ba,Status as bb,sysVarLongSketchSettings as bc,getSysVarLongSketchSettings as bd,getMxCadObj as be,countSysVarLongSketchSettingsOsMode as bf,setSysVarLongSketchSettingsOsMode as bg,setSysVarLongSketchSettings as bh,osModeRef as bi,SysVarLongSketchSettingsOsMode as bj,browserCacheReactive as bk,useLoading as bl,VTooltip as bm,mergeProps as bn,useLayer as bo,useKeyModifier as bp,useRightClickMenuOptions as bq,getMxAliSymbolIconHTML as br,useLineType as bs,McObjectIdType as bt,getDatabase as bu,createRangeNaturalNumberArray as bv,nextTick as bw,resolveDirective as bx,withModifiers as by,vModelText as bz,callCommand as c,has as c$,cadNames as c0,VProgressCircular as c1,cursorSize as c2,targetFrameSize as c3,updateCursorStyles as c4,commonjsGlobal$1 as c5,commonjsRequire as c6,renderSlot as c7,isStartShortcutCtrlCXVKey as c8,propsFactory$1 as c9,provide as cA,makeGroupItemProps as cB,makeLazyProps as cC,inject$1 as cD,useGroupItem as cE,useSsrBoot as cF,useLazy as cG,MaybeTransition as cH,convertToUnit as cI,omit as cJ,makeVBtnProps as cK,useTextColor as cL,animate as cM,standardEasing as cN,makeVSlideGroupProps as cO,makeDensityProps as cP,useDensity as cQ,useBackgroundColor as cR,toRef as cS,provideDefaults as cT,VSlideGroup as cU,isObject$1 as cV,defineComponent as cW,clamp as cX,useResizeObserver as cY,getEventCoordinates as cZ,HSVtoHex as c_,makeVOverlayProps as ca,VDialogTransition as cb,genericComponent as cc,useProxiedModel as cd,useScopeId as ce,IN_BROWSER as cf,useRender as cg,forwardRefs as ch,focusableChildren as ci,VOverlay as cj,VDefaultsProvider as ck,useMxDialogDrag as cl,keyToCode as cm,VCardTitle as cn,getLogoImgSrc as co,VCardText as cp,VCardActions as cq,VCard as cr,keys as cs,makeComponentProps as ct,makeTagProps as cu,makeThemeProps as cv,provideTheme as cw,useRtl as cx,useLocale as cy,useGroup as cz,scopedTtranslate as d,Transition as d$,HSVtoRGB as d0,HSVtoHSL as d1,RGBtoHSV as d2,HSLtoHSV as d3,HexToHSV as d4,onUnmounted as d5,SUPPORTS_EYE_DROPPER as d6,HSVtoCSS as d7,parseColor as d8,RGBtoCSS as d9,VMenu as dA,VVirtualScroll as dB,VCheckboxBtn as dC,VAvatar as dD,ensureValidVNode as dE,VChip as dF,noop$1 as dG,wrapInArray as dH,checkPrintable as dI,matchesSelector as dJ,makeGroupProps as dK,getLayerJson as dL,setLayerJson as dM,withKeys as dN,BaseTransition as dO,BaseTransitionPropsValidators as dP,Comment as dQ,DeprecationTypes as dR,EffectScope as dS,ErrorCodes as dT,ErrorTypeStrings as dU,KeepAlive as dV,ReactiveEffect as dW,Static as dX,Suspense as dY,Text as dZ,TrackOpTypes as d_,deepEqual as da,getContrast as db,makeVSheetProps as dc,VSheet as dd,makeRoundedProps as de,makeElevationProps as df,getDecimals as dg,createRange as dh,useElevation as di,VScaleTransition as dj,keyValues as dk,useRounded as dl,makeFocusProps as dm,makeVInputProps as dn,useFocus as dp,VInput as dq,VLabel as dr,makeFilterProps as ds,makeSelectProps as dt,makeVTextFieldProps as du,makeTransitionProps as dv,useItems as dw,useForm as dx,useFilter as dy,useScrolling as dz,addCommand as e,popScopeId as e$,TransitionGroup as e0,TriggerOpTypes as e1,VueElement as e2,assertNumber as e3,callWithAsyncErrorHandling as e4,callWithErrorHandling as e5,camelize as e6,capitalize as e7,cloneVNode as e8,compatUtils as e9,hydrateOnIdle as eA,hydrateOnInteraction as eB,hydrateOnMediaQuery as eC,hydrateOnVisible as eD,initCustomFormatter as eE,initDirectivesForSSR as eF,isMemoSame as eG,isProxy as eH,isReactive as eI,isReadonly as eJ,isRuntimeOnly as eK,isShallow as eL,isVNode as eM,mergeDefaults as eN,mergeModels as eO,normalizeProps as eP,onActivated as eQ,onBeforeMount as eR,onBeforeUpdate as eS,onDeactivated as eT,onErrorCaptured as eU,onRenderTracked as eV,onRenderTriggered as eW,onScopeDispose as eX,onServerPrefetch as eY,onUpdated as eZ,onWatcherCleanup as e_,createApp as ea,createHydrationRenderer as eb,createPropsRestProxy as ec,createRenderer as ed,createSSRApp as ee,createSlots as ef,createStaticVNode as eg,defineAsyncComponent as eh,defineCustomElement as ei,defineEmits as ej,defineExpose as ek,defineModel as el,defineOptions as em,defineProps as en,defineSSRCustomElement as eo,defineSlots as ep,devtools as eq,effect as er,effectScope as es,getCurrentScope as et,getCurrentWatcher as eu,getTransitionRawChildren as ev,guardReactiveProps as ew,handleError as ex,hasInjectionContext as ey,hydrate as ez,MxDbSplineCurve as f,useDisplay as f$,proxyRefs as f0,pushScopeId as f1,queuePostFlushCb as f2,readonly as f3,registerRuntimeCompiler as f4,render$1 as f5,resolveComponent as f6,resolveFilter as f7,resolveTransitionHooks as f8,setBlockTracking as f9,vModelDynamic as fA,vModelRadio as fB,vModelSelect as fC,version$4 as fD,warn as fE,watchPostEffect as fF,watchSyncEffect as fG,withAsyncContext as fH,withDefaults as fI,withMemo as fJ,withScopeId as fK,isOn as fL,createSimpleFunctional as fM,makeLayoutProps as fN,createLayout as fO,makeVToolbarTitleProps as fP,VToolbarTitle as fQ,IconValue$1 as fR,makeLocationProps as fS,useTheme$1 as fT,useLocation as fU,pickWithRest as fV,makeBorderProps as fW,makeDimensionProps as fX,makeDisplayProps as fY,makePositionProps as fZ,useBorder as f_,setDevtoolsHook as fa,setTransitionHooks as fb,shallowReactive as fc,shallowReadonly as fd,ssrContextKey as fe,ssrUtils as ff,stop as fg,toHandlerKey as fh,toHandlers as fi,toRaw as fj,toRefs as fk,toValue as fl,transformVNodeArgs as fm,triggerRef as fn,useAttrs as fo,useCssModule as fp,useCssVars as fq,useHost as fr,useId as fs,useModel as ft,useSSRContext as fu,useShadowRoot as fv,useSlots as fw,useTemplateRef as fx,useTransitionState as fy,vModelCheckbox as fz,MxTools as g,VAlertTitle as g$,useDimension as g0,usePosition as g1,makeLayoutItemProps as g2,useLayoutItem as g3,VBtnToggleSymbol as g4,makeRouterProps as g5,useLink as g6,makeVImgProps as g7,getObjectValueByPath as g8,getCurrentInstance as g9,callEvent as gA,makeFormProps as gB,createForm as gC,makeDelayProps as gD,useDelay as gE,Intersect as gF,provideLocale as gG,useHydration as gH,only as gI,focusChild as gJ,useIntersectionObserver as gK,getScrollParent as gL,getUid as gM,VSlideGroupSymbol as gN,makeVariantProps as gO,useVariant as gP,VuetifyLayoutKey as gQ,useLayout as gR,refElement as gS,genOverlays as gT,makeVMenuProps as gU,makeVSelectionControlProps as gV,VSelectionControl as gW,useSize as gX,makeValidationProps as gY,useValidation as gZ,VAlert as g_,isEmpty as ga,getPropertyFromItem as gb,VFadeTransition as gc,LoaderSlot as gd,VPagination as ge,defineFunctionalComponent as gf,consoleError as gg,makeLoaderProps as gh,useLoader as gi,EventProp as gj,makeVTableProps as gk,makeVirtualProps as gl,useVirtual as gm,VVirtualScrollItem as gn,VSpacer as go,useDate as gp,getWeek as gq,templateRef as gr,makeSizeProps as gs,useToggleScope as gt,makeVFieldProps as gu,humanReadableFileSize as gv,filterInputAttrs as gw,filterFieldProps as gx,VField as gy,VCounter as gz,MxCADUiPrEntity as h,VAppBar as h0,VBtnGroup as h1,VBtnToggle as h2,VCardItem as h3,VCardSubtitle as h4,VChipGroup as h5,VClassIcon as h6,VComponentIcon as h7,VDialogBottomTransition as h8,VDialogTopTransition as h9,VSlideXTransition as hA,VSlideYReverseTransition as hB,VSlideYTransition as hC,VSvgIcon as hD,VToolbar as hE,MxBtnList as hF,MxMenu as hG,app as hH,setCustomDataListLength as hI,useFocus$1 as hJ,fetchUiConfig as hK,useTheme as hL,useFileName as hM,getMxCADUIImplement as hN,Mx$1 as hO,MxCAD as hP,vuetify$1 as hQ,addDrawerComponent as hR,VExpandTransition as ha,VExpandXTransition as hb,VExpansionPanel as hc,VExpansionPanelText as hd,VExpansionPanelTitle as he,VExpansionPanels as hf,VFabTransition as hg,VFieldLabel as hh,VFooter as hi,VInfiniteScroll as hj,VLayout as hk,VLigatureIcon as hl,VListGroup as hm,VListItemSubtitle as hn,VListSubheader as ho,VMain as hp,VMessages as hq,VNavigationDrawer as hr,VResponsive as hs,VScrollXReverseTransition as ht,VScrollXTransition as hu,VScrollYReverseTransition as hv,VScrollYTransition as hw,VSelectionControlGroup as hx,VSkeletonLoader as hy,VSlideXReverseTransition as hz,isElectron as i,McDbCurve as j,MxCADUiPrPoint as k,McDbPolyline as l,McGeLongArray as m,McGePoint3d as n,McDbLine as o,MrxDbgUiPrBaseReturn$1 as p,MxCADResbuf as q,McDbArc as r,saveAsFileDialog as s,McGeVector3d as t,McDbCircle as u,MxFun as v,McCmColor as w,MxCADUiPrString as x,MxCADUiPrAngle as y,MxCADUtility as z};
|