12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023602460256026602760286029603060316032603360346035603660376038603960406041604260436044604560466047604860496050605160526053605460556056605760586059606060616062606360646065606660676068606960706071607260736074607560766077607860796080608160826083608460856086608760886089609060916092609360946095609660976098609961006101610261036104610561066107610861096110611161126113611461156116611761186119612061216122612361246125612661276128612961306131613261336134613561366137613861396140614161426143614461456146614761486149615061516152615361546155615661576158615961606161616261636164616561666167616861696170617161726173617461756176617761786179618061816182618361846185618661876188618961906191619261936194619561966197619861996200620162026203620462056206620762086209621062116212621362146215621662176218621962206221622262236224622562266227622862296230623162326233623462356236623762386239624062416242624362446245624662476248624962506251625262536254625562566257625862596260626162626263626462656266626762686269627062716272627362746275627662776278627962806281628262836284628562866287628862896290629162926293629462956296629762986299630063016302630363046305630663076308630963106311631263136314631563166317631863196320632163226323632463256326632763286329633063316332633363346335633663376338633963406341634263436344634563466347634863496350635163526353635463556356635763586359636063616362636363646365636663676368636963706371637263736374637563766377637863796380638163826383638463856386638763886389639063916392639363946395639663976398639964006401640264036404640564066407640864096410641164126413641464156416641764186419642064216422642364246425642664276428642964306431643264336434643564366437643864396440644164426443644464456446644764486449645064516452645364546455645664576458645964606461646264636464646564666467646864696470647164726473647464756476647764786479648064816482648364846485648664876488648964906491649264936494649564966497649864996500650165026503650465056506650765086509651065116512651365146515651665176518651965206521652265236524652565266527652865296530653165326533653465356536653765386539654065416542654365446545654665476548654965506551655265536554655565566557655865596560656165626563656465656566656765686569657065716572657365746575657665776578657965806581658265836584658565866587658865896590659165926593659465956596659765986599660066016602660366046605660666076608660966106611661266136614661566166617661866196620662166226623662466256626662766286629663066316632663366346635663666376638663966406641664266436644664566466647664866496650665166526653665466556656665766586659666066616662666366646665666666676668666966706671667266736674667566766677667866796680668166826683668466856686668766886689669066916692669366946695669666976698669967006701670267036704670567066707670867096710671167126713671467156716671767186719672067216722672367246725672667276728672967306731673267336734673567366737673867396740674167426743674467456746674767486749675067516752675367546755675667576758675967606761676267636764676567666767676867696770677167726773677467756776677767786779678067816782678367846785678667876788678967906791679267936794679567966797679867996800680168026803680468056806680768086809681068116812681368146815681668176818681968206821682268236824682568266827682868296830683168326833683468356836683768386839684068416842684368446845684668476848684968506851685268536854685568566857685868596860686168626863686468656866686768686869687068716872687368746875687668776878687968806881688268836884688568866887688868896890689168926893689468956896689768986899690069016902690369046905690669076908690969106911691269136914691569166917691869196920692169226923692469256926692769286929693069316932693369346935693669376938693969406941694269436944694569466947694869496950695169526953695469556956695769586959696069616962696369646965696669676968696969706971697269736974697569766977697869796980698169826983698469856986698769886989699069916992699369946995699669976998699970007001700270037004700570067007700870097010701170127013701470157016701770187019702070217022702370247025702670277028702970307031703270337034703570367037703870397040704170427043704470457046704770487049705070517052705370547055705670577058705970607061706270637064706570667067706870697070707170727073707470757076707770787079708070817082708370847085708670877088708970907091709270937094709570967097709870997100710171027103710471057106710771087109711071117112711371147115711671177118711971207121712271237124712571267127712871297130713171327133713471357136713771387139714071417142714371447145714671477148714971507151715271537154715571567157715871597160716171627163716471657166716771687169717071717172717371747175717671777178717971807181718271837184718571867187718871897190719171927193719471957196719771987199720072017202720372047205720672077208720972107211721272137214721572167217721872197220722172227223722472257226722772287229723072317232723372347235723672377238723972407241724272437244724572467247724872497250725172527253725472557256725772587259726072617262726372647265726672677268726972707271727272737274727572767277727872797280728172827283728472857286728772887289729072917292729372947295729672977298729973007301730273037304730573067307730873097310731173127313731473157316731773187319732073217322732373247325732673277328732973307331733273337334733573367337733873397340734173427343734473457346734773487349735073517352735373547355735673577358735973607361736273637364736573667367736873697370737173727373737473757376737773787379738073817382738373847385738673877388738973907391739273937394739573967397739873997400740174027403740474057406740774087409741074117412741374147415741674177418741974207421742274237424742574267427742874297430743174327433743474357436743774387439744074417442744374447445744674477448744974507451745274537454745574567457745874597460746174627463746474657466746774687469747074717472747374747475747674777478747974807481748274837484748574867487748874897490749174927493749474957496749774987499750075017502750375047505750675077508750975107511751275137514751575167517751875197520752175227523752475257526752775287529753075317532753375347535753675377538753975407541754275437544754575467547754875497550755175527553755475557556755775587559756075617562756375647565756675677568756975707571757275737574757575767577757875797580758175827583758475857586758775887589759075917592759375947595759675977598759976007601760276037604760576067607760876097610761176127613761476157616761776187619762076217622762376247625762676277628762976307631763276337634763576367637763876397640764176427643764476457646764776487649765076517652765376547655765676577658765976607661766276637664766576667667766876697670767176727673767476757676767776787679768076817682768376847685768676877688768976907691769276937694769576967697769876997700770177027703770477057706770777087709771077117712771377147715771677177718771977207721772277237724772577267727772877297730773177327733773477357736773777387739774077417742774377447745774677477748774977507751775277537754775577567757775877597760776177627763776477657766776777687769777077717772777377747775777677777778777977807781778277837784778577867787778877897790779177927793779477957796779777987799780078017802780378047805780678077808780978107811781278137814781578167817781878197820782178227823782478257826782778287829783078317832783378347835783678377838783978407841784278437844784578467847784878497850785178527853785478557856785778587859786078617862786378647865786678677868786978707871787278737874787578767877787878797880788178827883788478857886788778887889789078917892789378947895789678977898789979007901790279037904790579067907790879097910791179127913791479157916791779187919792079217922792379247925792679277928792979307931793279337934793579367937793879397940794179427943794479457946794779487949795079517952795379547955795679577958795979607961796279637964796579667967796879697970797179727973797479757976797779787979798079817982798379847985798679877988798979907991799279937994799579967997799879998000800180028003800480058006800780088009801080118012801380148015801680178018801980208021802280238024802580268027802880298030803180328033803480358036803780388039804080418042804380448045804680478048804980508051805280538054805580568057805880598060806180628063806480658066806780688069807080718072807380748075807680778078807980808081808280838084808580868087808880898090809180928093809480958096809780988099810081018102810381048105810681078108810981108111811281138114811581168117811881198120812181228123812481258126812781288129813081318132813381348135813681378138813981408141814281438144814581468147814881498150815181528153815481558156815781588159816081618162816381648165816681678168816981708171817281738174817581768177817881798180818181828183818481858186818781888189819081918192819381948195819681978198819982008201820282038204820582068207820882098210821182128213821482158216821782188219822082218222822382248225822682278228822982308231823282338234823582368237823882398240824182428243824482458246824782488249825082518252825382548255825682578258825982608261826282638264826582668267826882698270827182728273827482758276827782788279828082818282828382848285828682878288828982908291829282938294829582968297829882998300830183028303830483058306830783088309831083118312831383148315831683178318831983208321832283238324832583268327832883298330833183328333833483358336833783388339834083418342834383448345834683478348834983508351835283538354835583568357835883598360836183628363836483658366836783688369837083718372837383748375837683778378837983808381838283838384838583868387838883898390839183928393839483958396839783988399840084018402840384048405840684078408840984108411841284138414841584168417841884198420842184228423842484258426842784288429843084318432843384348435843684378438843984408441844284438444844584468447844884498450845184528453845484558456845784588459846084618462846384648465846684678468846984708471847284738474847584768477847884798480848184828483848484858486848784888489849084918492849384948495849684978498849985008501850285038504850585068507850885098510851185128513851485158516851785188519852085218522852385248525852685278528852985308531853285338534853585368537853885398540854185428543854485458546854785488549855085518552855385548555855685578558855985608561856285638564856585668567856885698570857185728573857485758576857785788579858085818582858385848585858685878588858985908591859285938594859585968597859885998600860186028603860486058606860786088609861086118612861386148615861686178618861986208621862286238624862586268627862886298630863186328633863486358636863786388639864086418642864386448645864686478648864986508651865286538654865586568657865886598660866186628663866486658666866786688669867086718672867386748675867686778678867986808681868286838684868586868687868886898690869186928693869486958696869786988699870087018702870387048705870687078708870987108711871287138714871587168717871887198720872187228723872487258726872787288729873087318732873387348735873687378738873987408741874287438744874587468747874887498750875187528753875487558756875787588759876087618762876387648765876687678768876987708771877287738774877587768777877887798780878187828783878487858786878787888789879087918792879387948795879687978798879988008801880288038804880588068807880888098810881188128813881488158816881788188819882088218822882388248825882688278828882988308831883288338834883588368837883888398840884188428843884488458846884788488849885088518852885388548855885688578858885988608861886288638864886588668867886888698870887188728873887488758876887788788879888088818882888388848885888688878888888988908891889288938894889588968897889888998900890189028903890489058906890789088909891089118912891389148915891689178918891989208921892289238924892589268927892889298930893189328933893489358936893789388939894089418942894389448945894689478948894989508951895289538954895589568957895889598960896189628963896489658966896789688969897089718972897389748975897689778978897989808981898289838984898589868987898889898990899189928993899489958996899789988999900090019002900390049005900690079008900990109011901290139014901590169017901890199020902190229023902490259026902790289029903090319032903390349035903690379038903990409041904290439044904590469047904890499050905190529053905490559056905790589059906090619062906390649065906690679068906990709071907290739074907590769077907890799080908190829083908490859086908790889089909090919092909390949095909690979098909991009101910291039104910591069107910891099110911191129113911491159116911791189119912091219122912391249125912691279128912991309131913291339134913591369137913891399140914191429143914491459146914791489149915091519152915391549155915691579158915991609161916291639164916591669167916891699170917191729173917491759176917791789179918091819182918391849185918691879188918991909191919291939194919591969197919891999200920192029203920492059206920792089209921092119212921392149215921692179218921992209221922292239224922592269227922892299230923192329233923492359236923792389239924092419242924392449245924692479248924992509251925292539254925592569257925892599260926192629263926492659266926792689269927092719272927392749275927692779278927992809281928292839284928592869287928892899290929192929293929492959296929792989299930093019302930393049305930693079308930993109311931293139314931593169317931893199320932193229323932493259326932793289329933093319332933393349335933693379338933993409341934293439344934593469347934893499350935193529353935493559356935793589359936093619362936393649365936693679368936993709371937293739374937593769377937893799380938193829383938493859386938793889389939093919392939393949395939693979398939994009401940294039404940594069407940894099410941194129413941494159416941794189419942094219422942394249425942694279428942994309431943294339434943594369437943894399440944194429443944494459446944794489449945094519452945394549455945694579458945994609461946294639464946594669467946894699470947194729473947494759476947794789479948094819482948394849485948694879488948994909491949294939494949594969497949894999500950195029503950495059506950795089509951095119512951395149515951695179518951995209521952295239524952595269527952895299530953195329533953495359536953795389539954095419542954395449545954695479548954995509551955295539554955595569557955895599560956195629563956495659566956795689569957095719572957395749575957695779578957995809581958295839584958595869587958895899590959195929593959495959596959795989599960096019602960396049605960696079608960996109611961296139614961596169617961896199620962196229623962496259626962796289629963096319632963396349635963696379638963996409641964296439644964596469647964896499650965196529653965496559656965796589659966096619662966396649665966696679668966996709671967296739674967596769677967896799680968196829683968496859686968796889689969096919692969396949695969696979698969997009701970297039704970597069707970897099710971197129713971497159716971797189719972097219722972397249725972697279728972997309731973297339734973597369737973897399740974197429743974497459746974797489749975097519752975397549755975697579758975997609761976297639764976597669767976897699770977197729773977497759776977797789779978097819782978397849785978697879788978997909791979297939794979597969797979897999800980198029803980498059806980798089809981098119812981398149815981698179818981998209821982298239824982598269827982898299830983198329833983498359836983798389839984098419842984398449845984698479848984998509851985298539854985598569857985898599860986198629863986498659866986798689869987098719872987398749875987698779878987998809881988298839884988598869887988898899890989198929893989498959896989798989899990099019902990399049905990699079908990999109911991299139914991599169917991899199920992199229923992499259926992799289929993099319932993399349935993699379938993999409941994299439944994599469947994899499950995199529953995499559956995799589959996099619962996399649965996699679968996999709971997299739974997599769977997899799980998199829983998499859986998799889989999099919992999399949995999699979998999910000100011000210003100041000510006100071000810009100101001110012100131001410015100161001710018100191002010021100221002310024100251002610027100281002910030100311003210033100341003510036100371003810039100401004110042100431004410045100461004710048100491005010051100521005310054100551005610057100581005910060100611006210063100641006510066100671006810069100701007110072100731007410075100761007710078100791008010081100821008310084100851008610087100881008910090100911009210093100941009510096100971009810099101001010110102101031010410105101061010710108101091011010111101121011310114101151011610117101181011910120101211012210123101241012510126101271012810129101301013110132101331013410135101361013710138101391014010141101421014310144101451014610147101481014910150101511015210153101541015510156101571015810159101601016110162101631016410165101661016710168101691017010171101721017310174101751017610177101781017910180101811018210183101841018510186101871018810189101901019110192101931019410195101961019710198101991020010201102021020310204102051020610207102081020910210102111021210213102141021510216102171021810219102201022110222102231022410225102261022710228102291023010231102321023310234102351023610237102381023910240102411024210243102441024510246102471024810249102501025110252102531025410255102561025710258102591026010261102621026310264102651026610267102681026910270102711027210273102741027510276102771027810279102801028110282102831028410285102861028710288102891029010291102921029310294102951029610297102981029910300103011030210303103041030510306103071030810309103101031110312103131031410315103161031710318103191032010321103221032310324103251032610327103281032910330103311033210333103341033510336103371033810339103401034110342103431034410345103461034710348103491035010351103521035310354103551035610357103581035910360103611036210363103641036510366103671036810369103701037110372103731037410375103761037710378103791038010381103821038310384103851038610387103881038910390103911039210393103941039510396103971039810399104001040110402104031040410405104061040710408104091041010411104121041310414104151041610417104181041910420104211042210423104241042510426104271042810429104301043110432104331043410435104361043710438104391044010441104421044310444104451044610447104481044910450104511045210453104541045510456104571045810459104601046110462104631046410465104661046710468104691047010471104721047310474104751047610477104781047910480104811048210483104841048510486104871048810489104901049110492104931049410495104961049710498104991050010501105021050310504105051050610507105081050910510105111051210513105141051510516105171051810519105201052110522105231052410525105261052710528105291053010531105321053310534105351053610537105381053910540105411054210543105441054510546105471054810549105501055110552105531055410555105561055710558105591056010561105621056310564105651056610567105681056910570105711057210573105741057510576105771057810579105801058110582105831058410585105861058710588105891059010591105921059310594105951059610597105981059910600106011060210603106041060510606106071060810609106101061110612106131061410615106161061710618106191062010621106221062310624106251062610627106281062910630106311063210633106341063510636106371063810639106401064110642106431064410645106461064710648106491065010651106521065310654106551065610657106581065910660106611066210663106641066510666106671066810669106701067110672106731067410675106761067710678106791068010681106821068310684106851068610687106881068910690106911069210693106941069510696106971069810699107001070110702107031070410705107061070710708107091071010711107121071310714107151071610717107181071910720107211072210723107241072510726107271072810729107301073110732107331073410735107361073710738107391074010741107421074310744107451074610747107481074910750107511075210753107541075510756107571075810759107601076110762107631076410765107661076710768107691077010771107721077310774107751077610777107781077910780107811078210783107841078510786107871078810789107901079110792107931079410795107961079710798107991080010801108021080310804108051080610807108081080910810108111081210813108141081510816108171081810819108201082110822108231082410825108261082710828108291083010831108321083310834108351083610837108381083910840108411084210843108441084510846108471084810849108501085110852108531085410855108561085710858108591086010861108621086310864108651086610867108681086910870108711087210873108741087510876108771087810879108801088110882108831088410885108861088710888108891089010891108921089310894108951089610897108981089910900109011090210903109041090510906109071090810909109101091110912109131091410915109161091710918109191092010921109221092310924109251092610927109281092910930109311093210933109341093510936109371093810939109401094110942109431094410945109461094710948109491095010951109521095310954109551095610957109581095910960109611096210963109641096510966109671096810969109701097110972109731097410975109761097710978109791098010981109821098310984109851098610987109881098910990109911099210993109941099510996109971099810999110001100111002110031100411005110061100711008110091101011011110121101311014110151101611017110181101911020110211102211023110241102511026110271102811029110301103111032110331103411035110361103711038110391104011041110421104311044110451104611047110481104911050110511105211053110541105511056110571105811059110601106111062110631106411065110661106711068110691107011071110721107311074110751107611077110781107911080110811108211083110841108511086110871108811089110901109111092110931109411095110961109711098110991110011101111021110311104111051110611107111081110911110111111111211113111141111511116111171111811119111201112111122111231112411125111261112711128111291113011131111321113311134111351113611137111381113911140111411114211143111441114511146111471114811149111501115111152111531115411155111561115711158111591116011161111621116311164111651116611167111681116911170111711117211173111741117511176111771117811179111801118111182111831118411185111861118711188111891119011191111921119311194111951119611197111981119911200112011120211203112041120511206112071120811209112101121111212112131121411215112161121711218112191122011221112221122311224112251122611227112281122911230112311123211233112341123511236112371123811239112401124111242112431124411245112461124711248112491125011251112521125311254112551125611257112581125911260112611126211263112641126511266112671126811269112701127111272112731127411275112761127711278112791128011281112821128311284112851128611287112881128911290112911129211293112941129511296112971129811299113001130111302113031130411305113061130711308113091131011311113121131311314113151131611317113181131911320113211132211323113241132511326113271132811329113301133111332113331133411335113361133711338113391134011341113421134311344113451134611347113481134911350113511135211353113541135511356113571135811359113601136111362113631136411365113661136711368113691137011371113721137311374113751137611377113781137911380113811138211383113841138511386113871138811389113901139111392113931139411395113961139711398113991140011401114021140311404114051140611407114081140911410114111141211413114141141511416114171141811419114201142111422114231142411425114261142711428114291143011431114321143311434114351143611437114381143911440114411144211443114441144511446114471144811449114501145111452114531145411455114561145711458114591146011461114621146311464114651146611467114681146911470114711147211473114741147511476114771147811479114801148111482114831148411485114861148711488114891149011491114921149311494114951149611497114981149911500115011150211503115041150511506115071150811509115101151111512115131151411515115161151711518115191152011521115221152311524115251152611527115281152911530115311153211533115341153511536115371153811539115401154111542115431154411545115461154711548115491155011551115521155311554115551155611557115581155911560115611156211563115641156511566115671156811569115701157111572115731157411575115761157711578115791158011581115821158311584115851158611587115881158911590115911159211593115941159511596115971159811599116001160111602116031160411605116061160711608116091161011611116121161311614116151161611617116181161911620116211162211623116241162511626116271162811629116301163111632116331163411635116361163711638116391164011641116421164311644116451164611647116481164911650116511165211653116541165511656116571165811659116601166111662116631166411665116661166711668116691167011671116721167311674116751167611677116781167911680116811168211683116841168511686116871168811689116901169111692116931169411695116961169711698116991170011701117021170311704117051170611707117081170911710117111171211713117141171511716117171171811719117201172111722117231172411725117261172711728117291173011731117321173311734117351173611737117381173911740117411174211743117441174511746117471174811749117501175111752117531175411755117561175711758117591176011761117621176311764117651176611767117681176911770117711177211773117741177511776117771177811779117801178111782117831178411785117861178711788117891179011791117921179311794117951179611797117981179911800118011180211803118041180511806118071180811809118101181111812118131181411815118161181711818118191182011821118221182311824118251182611827118281182911830118311183211833118341183511836118371183811839118401184111842118431184411845118461184711848118491185011851118521185311854118551185611857118581185911860118611186211863118641186511866118671186811869118701187111872118731187411875118761187711878118791188011881118821188311884118851188611887118881188911890118911189211893118941189511896118971189811899119001190111902119031190411905119061190711908119091191011911119121191311914119151191611917119181191911920119211192211923119241192511926119271192811929119301193111932119331193411935119361193711938119391194011941119421194311944119451194611947119481194911950119511195211953119541195511956119571195811959119601196111962119631196411965119661196711968119691197011971119721197311974119751197611977119781197911980119811198211983119841198511986119871198811989119901199111992119931199411995119961199711998119991200012001120021200312004120051200612007120081200912010120111201212013120141201512016120171201812019120201202112022120231202412025120261202712028120291203012031120321203312034120351203612037120381203912040120411204212043120441204512046120471204812049120501205112052120531205412055120561205712058120591206012061120621206312064120651206612067120681206912070120711207212073120741207512076120771207812079120801208112082120831208412085120861208712088120891209012091120921209312094120951209612097120981209912100121011210212103121041210512106121071210812109121101211112112121131211412115121161211712118121191212012121121221212312124121251212612127121281212912130121311213212133121341213512136121371213812139121401214112142121431214412145121461214712148121491215012151121521215312154121551215612157121581215912160121611216212163121641216512166121671216812169121701217112172121731217412175121761217712178121791218012181121821218312184121851218612187121881218912190121911219212193121941219512196121971219812199122001220112202122031220412205122061220712208122091221012211122121221312214122151221612217122181221912220122211222212223122241222512226122271222812229122301223112232122331223412235122361223712238122391224012241122421224312244122451224612247122481224912250122511225212253122541225512256122571225812259122601226112262122631226412265122661226712268122691227012271122721227312274122751227612277122781227912280122811228212283122841228512286122871228812289122901229112292122931229412295122961229712298122991230012301123021230312304123051230612307123081230912310123111231212313123141231512316123171231812319123201232112322123231232412325123261232712328123291233012331123321233312334123351233612337123381233912340123411234212343123441234512346123471234812349123501235112352123531235412355123561235712358123591236012361123621236312364123651236612367123681236912370123711237212373123741237512376123771237812379123801238112382123831238412385123861238712388123891239012391123921239312394123951239612397123981239912400124011240212403124041240512406124071240812409124101241112412124131241412415124161241712418124191242012421124221242312424124251242612427124281242912430124311243212433124341243512436124371243812439124401244112442124431244412445124461244712448124491245012451124521245312454124551245612457124581245912460124611246212463124641246512466124671246812469124701247112472124731247412475124761247712478124791248012481124821248312484124851248612487124881248912490124911249212493124941249512496124971249812499125001250112502125031250412505125061250712508125091251012511125121251312514125151251612517125181251912520125211252212523125241252512526125271252812529125301253112532125331253412535125361253712538125391254012541125421254312544125451254612547125481254912550125511255212553125541255512556125571255812559125601256112562125631256412565125661256712568125691257012571125721257312574125751257612577125781257912580125811258212583125841258512586125871258812589125901259112592125931259412595125961259712598125991260012601126021260312604126051260612607126081260912610126111261212613126141261512616126171261812619126201262112622126231262412625126261262712628126291263012631126321263312634126351263612637126381263912640126411264212643126441264512646126471264812649126501265112652126531265412655126561265712658126591266012661126621266312664126651266612667126681266912670126711267212673126741267512676126771267812679126801268112682126831268412685126861268712688126891269012691126921269312694126951269612697126981269912700127011270212703127041270512706127071270812709127101271112712127131271412715127161271712718127191272012721127221272312724127251272612727127281272912730127311273212733127341273512736127371273812739127401274112742127431274412745127461274712748127491275012751127521275312754127551275612757127581275912760127611276212763127641276512766127671276812769127701277112772127731277412775127761277712778127791278012781127821278312784127851278612787127881278912790127911279212793127941279512796127971279812799128001280112802128031280412805128061280712808128091281012811128121281312814128151281612817128181281912820128211282212823128241282512826128271282812829128301283112832128331283412835128361283712838128391284012841128421284312844128451284612847128481284912850128511285212853128541285512856128571285812859128601286112862128631286412865128661286712868128691287012871128721287312874128751287612877128781287912880128811288212883128841288512886128871288812889128901289112892128931289412895128961289712898128991290012901129021290312904129051290612907129081290912910129111291212913129141291512916129171291812919129201292112922129231292412925129261292712928129291293012931129321293312934129351293612937129381293912940129411294212943129441294512946129471294812949129501295112952129531295412955129561295712958129591296012961129621296312964129651296612967129681296912970129711297212973129741297512976129771297812979129801298112982129831298412985129861298712988129891299012991129921299312994129951299612997129981299913000130011300213003130041300513006130071300813009130101301113012130131301413015130161301713018130191302013021130221302313024130251302613027130281302913030130311303213033130341303513036130371303813039130401304113042130431304413045130461304713048130491305013051130521305313054130551305613057130581305913060130611306213063130641306513066130671306813069130701307113072130731307413075130761307713078130791308013081130821308313084130851308613087130881308913090130911309213093130941309513096130971309813099131001310113102131031310413105131061310713108131091311013111131121311313114131151311613117131181311913120131211312213123131241312513126131271312813129131301313113132131331313413135131361313713138131391314013141131421314313144131451314613147131481314913150131511315213153131541315513156131571315813159131601316113162131631316413165131661316713168131691317013171131721317313174131751317613177131781317913180131811318213183131841318513186131871318813189131901319113192131931319413195131961319713198131991320013201132021320313204132051320613207132081320913210132111321213213132141321513216132171321813219132201322113222132231322413225132261322713228132291323013231132321323313234132351323613237132381323913240132411324213243132441324513246132471324813249132501325113252132531325413255132561325713258132591326013261132621326313264132651326613267132681326913270132711327213273132741327513276132771327813279132801328113282132831328413285132861328713288132891329013291132921329313294132951329613297132981329913300133011330213303133041330513306133071330813309133101331113312133131331413315133161331713318133191332013321133221332313324133251332613327133281332913330133311333213333133341333513336133371333813339133401334113342133431334413345133461334713348133491335013351133521335313354133551335613357133581335913360133611336213363133641336513366133671336813369133701337113372133731337413375133761337713378133791338013381133821338313384133851338613387133881338913390133911339213393133941339513396133971339813399134001340113402134031340413405134061340713408134091341013411134121341313414134151341613417134181341913420134211342213423134241342513426134271342813429134301343113432134331343413435134361343713438134391344013441134421344313444134451344613447134481344913450134511345213453134541345513456134571345813459134601346113462134631346413465134661346713468134691347013471134721347313474134751347613477134781347913480134811348213483134841348513486134871348813489134901349113492134931349413495134961349713498134991350013501135021350313504135051350613507135081350913510135111351213513135141351513516135171351813519135201352113522135231352413525135261352713528135291353013531135321353313534135351353613537135381353913540135411354213543135441354513546135471354813549135501355113552135531355413555135561355713558135591356013561135621356313564135651356613567135681356913570135711357213573135741357513576135771357813579135801358113582135831358413585135861358713588135891359013591135921359313594135951359613597135981359913600136011360213603136041360513606136071360813609136101361113612136131361413615136161361713618136191362013621136221362313624136251362613627136281362913630136311363213633136341363513636136371363813639136401364113642136431364413645136461364713648136491365013651136521365313654136551365613657136581365913660136611366213663136641366513666136671366813669136701367113672136731367413675136761367713678136791368013681136821368313684136851368613687136881368913690136911369213693136941369513696136971369813699137001370113702137031370413705137061370713708137091371013711137121371313714137151371613717137181371913720137211372213723137241372513726137271372813729137301373113732137331373413735137361373713738137391374013741137421374313744137451374613747137481374913750137511375213753137541375513756137571375813759137601376113762137631376413765137661376713768137691377013771137721377313774137751377613777137781377913780137811378213783137841378513786137871378813789137901379113792137931379413795137961379713798137991380013801138021380313804138051380613807138081380913810138111381213813138141381513816138171381813819138201382113822138231382413825138261382713828138291383013831138321383313834138351383613837138381383913840138411384213843138441384513846138471384813849138501385113852138531385413855138561385713858138591386013861138621386313864138651386613867138681386913870138711387213873138741387513876138771387813879138801388113882138831388413885138861388713888138891389013891138921389313894138951389613897138981389913900139011390213903139041390513906139071390813909139101391113912139131391413915139161391713918139191392013921139221392313924139251392613927139281392913930139311393213933139341393513936139371393813939139401394113942139431394413945139461394713948139491395013951139521395313954139551395613957139581395913960139611396213963139641396513966139671396813969139701397113972139731397413975139761397713978139791398013981139821398313984139851398613987139881398913990139911399213993139941399513996139971399813999140001400114002140031400414005140061400714008140091401014011140121401314014140151401614017140181401914020140211402214023140241402514026140271402814029140301403114032140331403414035140361403714038140391404014041140421404314044140451404614047140481404914050140511405214053140541405514056140571405814059140601406114062140631406414065140661406714068140691407014071140721407314074140751407614077140781407914080140811408214083140841408514086140871408814089140901409114092140931409414095140961409714098140991410014101141021410314104141051410614107141081410914110141111411214113141141411514116141171411814119141201412114122141231412414125141261412714128141291413014131141321413314134141351413614137141381413914140141411414214143141441414514146141471414814149141501415114152141531415414155141561415714158141591416014161141621416314164141651416614167141681416914170141711417214173141741417514176141771417814179141801418114182141831418414185141861418714188141891419014191141921419314194141951419614197141981419914200142011420214203142041420514206142071420814209142101421114212142131421414215142161421714218142191422014221142221422314224142251422614227142281422914230142311423214233142341423514236142371423814239142401424114242142431424414245142461424714248142491425014251142521425314254142551425614257142581425914260142611426214263142641426514266142671426814269142701427114272142731427414275142761427714278142791428014281142821428314284142851428614287142881428914290142911429214293142941429514296142971429814299143001430114302143031430414305143061430714308143091431014311143121431314314143151431614317143181431914320143211432214323143241432514326143271432814329143301433114332143331433414335143361433714338143391434014341143421434314344143451434614347143481434914350143511435214353143541435514356143571435814359143601436114362143631436414365143661436714368143691437014371143721437314374143751437614377143781437914380143811438214383143841438514386143871438814389143901439114392143931439414395143961439714398143991440014401144021440314404144051440614407144081440914410144111441214413144141441514416144171441814419144201442114422144231442414425144261442714428144291443014431144321443314434144351443614437144381443914440144411444214443144441444514446144471444814449144501445114452144531445414455144561445714458144591446014461144621446314464144651446614467144681446914470144711447214473144741447514476144771447814479144801448114482144831448414485144861448714488144891449014491144921449314494144951449614497144981449914500145011450214503145041450514506145071450814509145101451114512145131451414515145161451714518145191452014521145221452314524145251452614527145281452914530145311453214533145341453514536145371453814539145401454114542145431454414545145461454714548145491455014551145521455314554145551455614557145581455914560145611456214563145641456514566145671456814569145701457114572145731457414575145761457714578145791458014581145821458314584145851458614587145881458914590145911459214593145941459514596145971459814599146001460114602146031460414605146061460714608146091461014611146121461314614146151461614617146181461914620146211462214623146241462514626146271462814629146301463114632146331463414635146361463714638146391464014641146421464314644146451464614647146481464914650146511465214653146541465514656146571465814659146601466114662146631466414665146661466714668146691467014671146721467314674146751467614677146781467914680146811468214683146841468514686146871468814689146901469114692146931469414695146961469714698146991470014701147021470314704147051470614707147081470914710147111471214713147141471514716147171471814719147201472114722147231472414725147261472714728147291473014731147321473314734147351473614737147381473914740147411474214743147441474514746147471474814749147501475114752147531475414755147561475714758147591476014761147621476314764147651476614767147681476914770147711477214773147741477514776147771477814779147801478114782147831478414785147861478714788147891479014791147921479314794147951479614797147981479914800148011480214803148041480514806148071480814809148101481114812148131481414815148161481714818148191482014821148221482314824148251482614827148281482914830148311483214833148341483514836148371483814839148401484114842148431484414845148461484714848148491485014851148521485314854148551485614857148581485914860148611486214863148641486514866148671486814869148701487114872148731487414875148761487714878148791488014881148821488314884148851488614887148881488914890148911489214893148941489514896148971489814899149001490114902149031490414905149061490714908149091491014911149121491314914149151491614917149181491914920149211492214923149241492514926149271492814929149301493114932149331493414935149361493714938149391494014941149421494314944149451494614947149481494914950149511495214953149541495514956149571495814959149601496114962149631496414965149661496714968149691497014971149721497314974149751497614977149781497914980149811498214983149841498514986149871498814989149901499114992149931499414995149961499714998149991500015001150021500315004150051500615007150081500915010150111501215013150141501515016150171501815019150201502115022150231502415025150261502715028150291503015031150321503315034150351503615037150381503915040150411504215043150441504515046150471504815049150501505115052150531505415055150561505715058150591506015061150621506315064150651506615067150681506915070150711507215073150741507515076150771507815079150801508115082150831508415085150861508715088150891509015091150921509315094150951509615097150981509915100151011510215103151041510515106151071510815109151101511115112151131511415115151161511715118151191512015121151221512315124151251512615127151281512915130151311513215133151341513515136151371513815139151401514115142151431514415145151461514715148151491515015151151521515315154151551515615157151581515915160151611516215163151641516515166151671516815169151701517115172151731517415175151761517715178151791518015181151821518315184151851518615187151881518915190151911519215193151941519515196151971519815199152001520115202152031520415205152061520715208152091521015211152121521315214152151521615217152181521915220152211522215223152241522515226152271522815229152301523115232152331523415235152361523715238152391524015241152421524315244152451524615247152481524915250152511525215253152541525515256152571525815259152601526115262152631526415265152661526715268152691527015271152721527315274152751527615277152781527915280152811528215283152841528515286152871528815289152901529115292152931529415295152961529715298152991530015301153021530315304153051530615307153081530915310153111531215313153141531515316153171531815319153201532115322153231532415325153261532715328153291533015331153321533315334153351533615337153381533915340153411534215343153441534515346153471534815349153501535115352153531535415355153561535715358153591536015361153621536315364153651536615367153681536915370153711537215373153741537515376153771537815379153801538115382153831538415385153861538715388153891539015391153921539315394153951539615397153981539915400154011540215403154041540515406154071540815409154101541115412154131541415415154161541715418154191542015421154221542315424154251542615427154281542915430154311543215433154341543515436154371543815439154401544115442154431544415445154461544715448154491545015451154521545315454154551545615457154581545915460154611546215463154641546515466154671546815469154701547115472154731547415475154761547715478154791548015481154821548315484154851548615487154881548915490154911549215493154941549515496154971549815499155001550115502155031550415505155061550715508155091551015511155121551315514155151551615517155181551915520155211552215523155241552515526155271552815529155301553115532155331553415535155361553715538155391554015541155421554315544155451554615547155481554915550155511555215553155541555515556155571555815559155601556115562155631556415565155661556715568155691557015571155721557315574155751557615577155781557915580155811558215583155841558515586155871558815589155901559115592155931559415595155961559715598155991560015601156021560315604156051560615607156081560915610156111561215613156141561515616156171561815619156201562115622156231562415625156261562715628156291563015631156321563315634156351563615637156381563915640156411564215643156441564515646156471564815649156501565115652156531565415655156561565715658156591566015661156621566315664156651566615667156681566915670156711567215673156741567515676156771567815679156801568115682156831568415685156861568715688156891569015691156921569315694156951569615697156981569915700157011570215703157041570515706157071570815709157101571115712157131571415715157161571715718157191572015721157221572315724157251572615727157281572915730157311573215733157341573515736157371573815739157401574115742157431574415745157461574715748157491575015751157521575315754157551575615757157581575915760157611576215763157641576515766157671576815769157701577115772157731577415775157761577715778157791578015781157821578315784157851578615787157881578915790157911579215793157941579515796157971579815799158001580115802158031580415805158061580715808158091581015811158121581315814158151581615817158181581915820158211582215823158241582515826158271582815829158301583115832158331583415835158361583715838158391584015841158421584315844158451584615847158481584915850158511585215853158541585515856158571585815859158601586115862158631586415865158661586715868158691587015871158721587315874158751587615877158781587915880158811588215883158841588515886158871588815889158901589115892158931589415895158961589715898158991590015901159021590315904159051590615907159081590915910159111591215913159141591515916159171591815919159201592115922159231592415925159261592715928159291593015931159321593315934159351593615937159381593915940159411594215943159441594515946159471594815949159501595115952159531595415955159561595715958159591596015961159621596315964159651596615967159681596915970159711597215973159741597515976159771597815979159801598115982159831598415985159861598715988159891599015991159921599315994159951599615997159981599916000160011600216003160041600516006160071600816009160101601116012160131601416015160161601716018160191602016021160221602316024160251602616027160281602916030160311603216033160341603516036160371603816039160401604116042160431604416045160461604716048160491605016051160521605316054160551605616057160581605916060160611606216063160641606516066160671606816069160701607116072160731607416075160761607716078160791608016081160821608316084160851608616087160881608916090160911609216093160941609516096160971609816099161001610116102161031610416105161061610716108161091611016111161121611316114161151611616117161181611916120161211612216123161241612516126161271612816129161301613116132161331613416135161361613716138161391614016141161421614316144161451614616147161481614916150161511615216153161541615516156161571615816159161601616116162161631616416165161661616716168161691617016171161721617316174161751617616177161781617916180161811618216183161841618516186161871618816189161901619116192161931619416195161961619716198161991620016201162021620316204162051620616207162081620916210162111621216213162141621516216162171621816219162201622116222162231622416225162261622716228162291623016231162321623316234162351623616237162381623916240162411624216243162441624516246162471624816249162501625116252162531625416255162561625716258162591626016261162621626316264162651626616267162681626916270162711627216273162741627516276162771627816279162801628116282162831628416285162861628716288162891629016291162921629316294162951629616297162981629916300163011630216303163041630516306163071630816309163101631116312163131631416315163161631716318163191632016321163221632316324163251632616327163281632916330163311633216333163341633516336163371633816339163401634116342163431634416345163461634716348163491635016351163521635316354163551635616357163581635916360163611636216363163641636516366163671636816369163701637116372163731637416375163761637716378163791638016381163821638316384163851638616387163881638916390163911639216393163941639516396163971639816399164001640116402164031640416405164061640716408164091641016411164121641316414164151641616417164181641916420164211642216423164241642516426164271642816429164301643116432164331643416435164361643716438164391644016441164421644316444164451644616447164481644916450164511645216453164541645516456164571645816459164601646116462164631646416465164661646716468164691647016471164721647316474164751647616477164781647916480164811648216483164841648516486164871648816489164901649116492164931649416495164961649716498164991650016501165021650316504165051650616507165081650916510165111651216513165141651516516165171651816519165201652116522165231652416525165261652716528165291653016531165321653316534165351653616537165381653916540165411654216543165441654516546165471654816549165501655116552165531655416555165561655716558165591656016561165621656316564165651656616567165681656916570165711657216573165741657516576165771657816579165801658116582165831658416585165861658716588165891659016591165921659316594165951659616597165981659916600166011660216603166041660516606166071660816609166101661116612166131661416615166161661716618166191662016621166221662316624166251662616627166281662916630166311663216633166341663516636166371663816639166401664116642166431664416645166461664716648166491665016651166521665316654166551665616657166581665916660166611666216663166641666516666166671666816669166701667116672166731667416675166761667716678166791668016681166821668316684166851668616687166881668916690166911669216693166941669516696166971669816699167001670116702167031670416705167061670716708167091671016711167121671316714167151671616717167181671916720167211672216723167241672516726167271672816729167301673116732167331673416735167361673716738167391674016741167421674316744167451674616747167481674916750167511675216753167541675516756167571675816759167601676116762167631676416765167661676716768167691677016771167721677316774167751677616777167781677916780167811678216783167841678516786167871678816789167901679116792167931679416795167961679716798167991680016801168021680316804168051680616807168081680916810168111681216813168141681516816168171681816819168201682116822168231682416825168261682716828168291683016831168321683316834168351683616837168381683916840168411684216843168441684516846168471684816849168501685116852168531685416855168561685716858168591686016861168621686316864168651686616867168681686916870168711687216873168741687516876168771687816879168801688116882168831688416885168861688716888168891689016891168921689316894168951689616897168981689916900169011690216903169041690516906169071690816909169101691116912169131691416915169161691716918169191692016921169221692316924169251692616927169281692916930169311693216933169341693516936169371693816939169401694116942169431694416945169461694716948169491695016951169521695316954169551695616957169581695916960169611696216963169641696516966169671696816969169701697116972169731697416975169761697716978169791698016981169821698316984169851698616987169881698916990169911699216993169941699516996169971699816999170001700117002170031700417005170061700717008170091701017011170121701317014170151701617017170181701917020170211702217023170241702517026170271702817029170301703117032170331703417035170361703717038170391704017041170421704317044170451704617047170481704917050170511705217053170541705517056170571705817059170601706117062170631706417065170661706717068170691707017071170721707317074170751707617077170781707917080170811708217083170841708517086170871708817089170901709117092170931709417095170961709717098170991710017101171021710317104171051710617107171081710917110171111711217113171141711517116171171711817119171201712117122171231712417125171261712717128171291713017131171321713317134171351713617137171381713917140171411714217143171441714517146171471714817149171501715117152171531715417155171561715717158171591716017161171621716317164171651716617167171681716917170171711717217173171741717517176171771717817179171801718117182171831718417185171861718717188171891719017191171921719317194171951719617197171981719917200172011720217203172041720517206172071720817209172101721117212172131721417215172161721717218172191722017221172221722317224172251722617227172281722917230172311723217233172341723517236172371723817239172401724117242172431724417245172461724717248172491725017251172521725317254172551725617257172581725917260172611726217263172641726517266172671726817269172701727117272172731727417275172761727717278172791728017281172821728317284172851728617287172881728917290172911729217293172941729517296172971729817299173001730117302173031730417305173061730717308173091731017311173121731317314173151731617317173181731917320173211732217323173241732517326173271732817329173301733117332173331733417335173361733717338173391734017341173421734317344173451734617347173481734917350173511735217353173541735517356173571735817359173601736117362173631736417365173661736717368173691737017371173721737317374173751737617377173781737917380173811738217383173841738517386173871738817389173901739117392173931739417395173961739717398173991740017401174021740317404174051740617407174081740917410174111741217413174141741517416174171741817419174201742117422174231742417425174261742717428174291743017431174321743317434174351743617437174381743917440174411744217443174441744517446174471744817449174501745117452174531745417455174561745717458174591746017461174621746317464174651746617467174681746917470174711747217473174741747517476174771747817479174801748117482174831748417485174861748717488174891749017491174921749317494174951749617497174981749917500175011750217503175041750517506175071750817509175101751117512175131751417515175161751717518175191752017521175221752317524175251752617527175281752917530175311753217533175341753517536175371753817539175401754117542175431754417545175461754717548175491755017551175521755317554175551755617557175581755917560175611756217563175641756517566175671756817569175701757117572175731757417575175761757717578175791758017581175821758317584175851758617587175881758917590175911759217593175941759517596175971759817599176001760117602176031760417605176061760717608176091761017611176121761317614176151761617617176181761917620176211762217623176241762517626176271762817629176301763117632176331763417635176361763717638176391764017641176421764317644176451764617647176481764917650176511765217653176541765517656176571765817659176601766117662176631766417665176661766717668176691767017671176721767317674176751767617677176781767917680176811768217683176841768517686176871768817689176901769117692176931769417695176961769717698176991770017701177021770317704177051770617707177081770917710177111771217713177141771517716177171771817719177201772117722177231772417725177261772717728177291773017731177321773317734177351773617737177381773917740177411774217743177441774517746177471774817749177501775117752177531775417755177561775717758177591776017761177621776317764177651776617767177681776917770177711777217773177741777517776177771777817779177801778117782177831778417785177861778717788177891779017791177921779317794177951779617797177981779917800178011780217803178041780517806178071780817809178101781117812178131781417815178161781717818178191782017821178221782317824178251782617827178281782917830178311783217833178341783517836178371783817839178401784117842178431784417845178461784717848178491785017851178521785317854178551785617857178581785917860178611786217863178641786517866178671786817869178701787117872178731787417875178761787717878178791788017881178821788317884178851788617887178881788917890178911789217893178941789517896178971789817899179001790117902179031790417905179061790717908179091791017911179121791317914179151791617917179181791917920179211792217923179241792517926179271792817929179301793117932179331793417935179361793717938179391794017941179421794317944179451794617947179481794917950179511795217953179541795517956179571795817959179601796117962179631796417965179661796717968179691797017971179721797317974179751797617977179781797917980179811798217983179841798517986179871798817989179901799117992179931799417995179961799717998179991800018001180021800318004180051800618007180081800918010180111801218013180141801518016180171801818019180201802118022180231802418025180261802718028180291803018031180321803318034180351803618037180381803918040180411804218043180441804518046180471804818049180501805118052180531805418055180561805718058180591806018061180621806318064180651806618067180681806918070180711807218073180741807518076180771807818079180801808118082180831808418085180861808718088180891809018091180921809318094180951809618097180981809918100181011810218103181041810518106181071810818109181101811118112181131811418115181161811718118181191812018121181221812318124181251812618127181281812918130181311813218133181341813518136181371813818139181401814118142181431814418145181461814718148181491815018151181521815318154181551815618157181581815918160181611816218163181641816518166181671816818169181701817118172181731817418175181761817718178181791818018181181821818318184181851818618187181881818918190181911819218193181941819518196181971819818199182001820118202182031820418205182061820718208182091821018211182121821318214182151821618217182181821918220182211822218223182241822518226182271822818229182301823118232182331823418235182361823718238182391824018241182421824318244182451824618247182481824918250182511825218253182541825518256182571825818259182601826118262182631826418265182661826718268182691827018271182721827318274182751827618277182781827918280182811828218283182841828518286182871828818289182901829118292182931829418295182961829718298182991830018301183021830318304183051830618307183081830918310183111831218313183141831518316183171831818319183201832118322183231832418325183261832718328183291833018331183321833318334183351833618337183381833918340183411834218343183441834518346183471834818349183501835118352183531835418355183561835718358183591836018361183621836318364183651836618367183681836918370183711837218373183741837518376183771837818379183801838118382183831838418385183861838718388183891839018391183921839318394183951839618397183981839918400184011840218403184041840518406184071840818409184101841118412184131841418415184161841718418184191842018421184221842318424184251842618427184281842918430184311843218433184341843518436184371843818439184401844118442184431844418445184461844718448184491845018451184521845318454184551845618457184581845918460184611846218463184641846518466184671846818469184701847118472184731847418475184761847718478184791848018481184821848318484184851848618487184881848918490184911849218493184941849518496184971849818499185001850118502185031850418505185061850718508185091851018511185121851318514185151851618517185181851918520185211852218523185241852518526185271852818529185301853118532185331853418535185361853718538185391854018541185421854318544185451854618547185481854918550185511855218553185541855518556185571855818559185601856118562185631856418565185661856718568185691857018571185721857318574185751857618577185781857918580185811858218583185841858518586185871858818589185901859118592185931859418595185961859718598185991860018601186021860318604186051860618607186081860918610186111861218613186141861518616186171861818619186201862118622186231862418625186261862718628186291863018631186321863318634186351863618637186381863918640186411864218643186441864518646186471864818649186501865118652186531865418655186561865718658186591866018661186621866318664186651866618667186681866918670186711867218673186741867518676186771867818679186801868118682186831868418685186861868718688186891869018691186921869318694186951869618697186981869918700187011870218703187041870518706187071870818709187101871118712187131871418715187161871718718187191872018721187221872318724187251872618727187281872918730187311873218733187341873518736187371873818739187401874118742187431874418745187461874718748187491875018751187521875318754187551875618757187581875918760187611876218763187641876518766187671876818769187701877118772187731877418775187761877718778187791878018781187821878318784187851878618787187881878918790187911879218793187941879518796187971879818799188001880118802188031880418805188061880718808188091881018811188121881318814188151881618817188181881918820188211882218823188241882518826188271882818829188301883118832188331883418835188361883718838188391884018841188421884318844188451884618847188481884918850188511885218853188541885518856188571885818859188601886118862188631886418865188661886718868188691887018871188721887318874188751887618877188781887918880188811888218883188841888518886188871888818889188901889118892188931889418895188961889718898188991890018901189021890318904189051890618907189081890918910189111891218913189141891518916189171891818919189201892118922189231892418925189261892718928189291893018931189321893318934189351893618937189381893918940189411894218943189441894518946189471894818949189501895118952189531895418955189561895718958189591896018961189621896318964189651896618967189681896918970189711897218973189741897518976189771897818979189801898118982189831898418985189861898718988189891899018991189921899318994189951899618997189981899919000190011900219003190041900519006190071900819009190101901119012190131901419015190161901719018190191902019021190221902319024190251902619027190281902919030190311903219033190341903519036190371903819039190401904119042190431904419045190461904719048190491905019051190521905319054190551905619057190581905919060190611906219063190641906519066190671906819069190701907119072190731907419075190761907719078190791908019081190821908319084190851908619087190881908919090190911909219093190941909519096190971909819099191001910119102191031910419105191061910719108191091911019111191121911319114191151911619117191181911919120191211912219123191241912519126191271912819129191301913119132191331913419135191361913719138191391914019141191421914319144191451914619147191481914919150191511915219153191541915519156191571915819159191601916119162191631916419165191661916719168191691917019171191721917319174191751917619177191781917919180191811918219183191841918519186191871918819189191901919119192191931919419195191961919719198191991920019201192021920319204192051920619207192081920919210192111921219213192141921519216192171921819219192201922119222192231922419225192261922719228192291923019231192321923319234192351923619237192381923919240192411924219243192441924519246192471924819249192501925119252192531925419255192561925719258192591926019261192621926319264192651926619267192681926919270192711927219273192741927519276192771927819279192801928119282192831928419285192861928719288192891929019291192921929319294192951929619297192981929919300193011930219303193041930519306193071930819309193101931119312193131931419315193161931719318193191932019321193221932319324193251932619327193281932919330193311933219333193341933519336193371933819339193401934119342193431934419345193461934719348193491935019351193521935319354193551935619357193581935919360193611936219363193641936519366193671936819369193701937119372193731937419375193761937719378193791938019381193821938319384193851938619387193881938919390193911939219393193941939519396193971939819399194001940119402194031940419405194061940719408194091941019411194121941319414194151941619417194181941919420194211942219423194241942519426194271942819429194301943119432194331943419435194361943719438194391944019441194421944319444194451944619447194481944919450194511945219453194541945519456194571945819459194601946119462194631946419465194661946719468194691947019471194721947319474194751947619477194781947919480194811948219483194841948519486194871948819489194901949119492194931949419495194961949719498194991950019501195021950319504195051950619507195081950919510195111951219513195141951519516195171951819519195201952119522195231952419525195261952719528195291953019531195321953319534195351953619537195381953919540195411954219543195441954519546195471954819549195501955119552195531955419555195561955719558195591956019561195621956319564195651956619567195681956919570195711957219573195741957519576195771957819579195801958119582195831958419585195861958719588195891959019591195921959319594195951959619597195981959919600196011960219603196041960519606196071960819609196101961119612196131961419615196161961719618196191962019621196221962319624196251962619627196281962919630196311963219633196341963519636196371963819639196401964119642196431964419645196461964719648196491965019651196521965319654196551965619657196581965919660196611966219663196641966519666196671966819669196701967119672196731967419675196761967719678196791968019681196821968319684196851968619687196881968919690196911969219693196941969519696196971969819699197001970119702197031970419705197061970719708197091971019711197121971319714197151971619717197181971919720197211972219723197241972519726197271972819729197301973119732197331973419735197361973719738197391974019741197421974319744197451974619747197481974919750197511975219753197541975519756197571975819759197601976119762197631976419765197661976719768197691977019771197721977319774197751977619777197781977919780197811978219783197841978519786197871978819789197901979119792197931979419795197961979719798197991980019801198021980319804198051980619807198081980919810198111981219813198141981519816198171981819819198201982119822198231982419825198261982719828198291983019831198321983319834198351983619837198381983919840198411984219843198441984519846198471984819849198501985119852198531985419855198561985719858198591986019861198621986319864198651986619867198681986919870198711987219873198741987519876198771987819879198801988119882198831988419885198861988719888198891989019891198921989319894198951989619897198981989919900199011990219903199041990519906199071990819909199101991119912199131991419915199161991719918199191992019921199221992319924199251992619927199281992919930199311993219933199341993519936199371993819939199401994119942199431994419945199461994719948199491995019951199521995319954199551995619957199581995919960199611996219963199641996519966199671996819969199701997119972199731997419975199761997719978199791998019981199821998319984199851998619987199881998919990199911999219993199941999519996199971999819999200002000120002200032000420005200062000720008200092001020011200122001320014200152001620017200182001920020200212002220023200242002520026200272002820029200302003120032200332003420035200362003720038200392004020041200422004320044200452004620047200482004920050200512005220053200542005520056200572005820059200602006120062200632006420065200662006720068200692007020071200722007320074200752007620077200782007920080200812008220083200842008520086200872008820089200902009120092200932009420095200962009720098200992010020101201022010320104201052010620107201082010920110201112011220113201142011520116201172011820119201202012120122201232012420125201262012720128201292013020131201322013320134201352013620137201382013920140201412014220143201442014520146201472014820149201502015120152201532015420155201562015720158201592016020161201622016320164201652016620167201682016920170201712017220173201742017520176201772017820179201802018120182201832018420185201862018720188201892019020191201922019320194201952019620197201982019920200202012020220203202042020520206202072020820209202102021120212202132021420215202162021720218202192022020221202222022320224202252022620227202282022920230202312023220233202342023520236202372023820239202402024120242202432024420245202462024720248202492025020251202522025320254202552025620257202582025920260202612026220263202642026520266202672026820269202702027120272202732027420275202762027720278202792028020281202822028320284202852028620287202882028920290202912029220293202942029520296202972029820299203002030120302203032030420305203062030720308203092031020311203122031320314203152031620317203182031920320203212032220323203242032520326203272032820329203302033120332203332033420335203362033720338203392034020341203422034320344203452034620347203482034920350203512035220353203542035520356203572035820359203602036120362203632036420365203662036720368203692037020371203722037320374203752037620377203782037920380203812038220383203842038520386203872038820389203902039120392203932039420395203962039720398203992040020401204022040320404204052040620407204082040920410204112041220413204142041520416204172041820419204202042120422204232042420425204262042720428204292043020431204322043320434204352043620437204382043920440204412044220443204442044520446204472044820449204502045120452204532045420455204562045720458204592046020461204622046320464204652046620467204682046920470204712047220473204742047520476204772047820479204802048120482204832048420485204862048720488204892049020491204922049320494204952049620497204982049920500205012050220503205042050520506205072050820509205102051120512205132051420515205162051720518205192052020521205222052320524205252052620527205282052920530205312053220533205342053520536205372053820539205402054120542205432054420545205462054720548205492055020551205522055320554205552055620557205582055920560205612056220563205642056520566205672056820569205702057120572205732057420575205762057720578205792058020581205822058320584205852058620587205882058920590205912059220593205942059520596205972059820599206002060120602206032060420605206062060720608206092061020611206122061320614206152061620617206182061920620206212062220623206242062520626206272062820629206302063120632206332063420635206362063720638206392064020641206422064320644206452064620647206482064920650206512065220653206542065520656206572065820659206602066120662206632066420665206662066720668206692067020671206722067320674206752067620677206782067920680206812068220683206842068520686206872068820689206902069120692206932069420695206962069720698206992070020701207022070320704207052070620707207082070920710207112071220713207142071520716207172071820719207202072120722207232072420725207262072720728207292073020731207322073320734207352073620737207382073920740207412074220743207442074520746207472074820749207502075120752207532075420755207562075720758207592076020761207622076320764207652076620767207682076920770207712077220773207742077520776207772077820779207802078120782207832078420785207862078720788207892079020791207922079320794207952079620797207982079920800208012080220803208042080520806208072080820809208102081120812208132081420815208162081720818208192082020821208222082320824208252082620827208282082920830208312083220833208342083520836208372083820839208402084120842208432084420845208462084720848208492085020851208522085320854208552085620857208582085920860208612086220863208642086520866208672086820869208702087120872208732087420875208762087720878208792088020881208822088320884208852088620887208882088920890208912089220893208942089520896208972089820899209002090120902209032090420905209062090720908209092091020911209122091320914209152091620917209182091920920209212092220923209242092520926209272092820929209302093120932209332093420935209362093720938209392094020941209422094320944209452094620947209482094920950209512095220953209542095520956209572095820959209602096120962209632096420965209662096720968209692097020971209722097320974209752097620977209782097920980209812098220983209842098520986209872098820989209902099120992209932099420995209962099720998209992100021001210022100321004210052100621007210082100921010210112101221013210142101521016210172101821019210202102121022210232102421025210262102721028210292103021031210322103321034210352103621037210382103921040210412104221043210442104521046210472104821049210502105121052210532105421055210562105721058210592106021061210622106321064210652106621067210682106921070210712107221073210742107521076210772107821079210802108121082210832108421085210862108721088210892109021091210922109321094210952109621097210982109921100211012110221103211042110521106211072110821109211102111121112211132111421115211162111721118211192112021121211222112321124211252112621127211282112921130211312113221133211342113521136211372113821139211402114121142211432114421145211462114721148211492115021151211522115321154211552115621157211582115921160211612116221163211642116521166211672116821169211702117121172211732117421175211762117721178211792118021181211822118321184211852118621187211882118921190211912119221193211942119521196211972119821199212002120121202212032120421205212062120721208212092121021211212122121321214212152121621217212182121921220212212122221223212242122521226212272122821229212302123121232212332123421235212362123721238212392124021241212422124321244212452124621247212482124921250212512125221253212542125521256212572125821259212602126121262212632126421265212662126721268212692127021271212722127321274212752127621277212782127921280212812128221283212842128521286212872128821289212902129121292212932129421295212962129721298212992130021301213022130321304213052130621307213082130921310213112131221313213142131521316213172131821319213202132121322213232132421325213262132721328213292133021331213322133321334213352133621337213382133921340213412134221343213442134521346213472134821349213502135121352213532135421355213562135721358213592136021361213622136321364213652136621367213682136921370213712137221373213742137521376213772137821379213802138121382213832138421385213862138721388213892139021391213922139321394213952139621397213982139921400214012140221403214042140521406214072140821409214102141121412214132141421415214162141721418214192142021421214222142321424214252142621427214282142921430214312143221433214342143521436214372143821439214402144121442214432144421445214462144721448214492145021451214522145321454214552145621457214582145921460214612146221463214642146521466214672146821469214702147121472214732147421475214762147721478214792148021481214822148321484214852148621487214882148921490214912149221493214942149521496214972149821499215002150121502215032150421505215062150721508215092151021511215122151321514215152151621517215182151921520215212152221523215242152521526215272152821529215302153121532215332153421535215362153721538215392154021541215422154321544215452154621547215482154921550215512155221553215542155521556215572155821559215602156121562215632156421565215662156721568215692157021571215722157321574215752157621577215782157921580215812158221583215842158521586215872158821589215902159121592215932159421595215962159721598215992160021601216022160321604216052160621607216082160921610216112161221613216142161521616216172161821619216202162121622216232162421625216262162721628216292163021631216322163321634216352163621637216382163921640216412164221643216442164521646216472164821649216502165121652216532165421655216562165721658216592166021661216622166321664216652166621667216682166921670216712167221673216742167521676216772167821679216802168121682216832168421685216862168721688216892169021691216922169321694216952169621697216982169921700217012170221703217042170521706217072170821709217102171121712217132171421715217162171721718217192172021721217222172321724217252172621727217282172921730217312173221733217342173521736217372173821739217402174121742217432174421745217462174721748217492175021751217522175321754217552175621757217582175921760217612176221763217642176521766217672176821769217702177121772217732177421775217762177721778217792178021781217822178321784217852178621787217882178921790217912179221793217942179521796217972179821799218002180121802218032180421805218062180721808218092181021811218122181321814218152181621817218182181921820218212182221823218242182521826218272182821829218302183121832218332183421835218362183721838218392184021841218422184321844218452184621847218482184921850218512185221853218542185521856218572185821859218602186121862218632186421865218662186721868218692187021871218722187321874218752187621877218782187921880218812188221883218842188521886218872188821889218902189121892218932189421895218962189721898218992190021901219022190321904219052190621907219082190921910219112191221913219142191521916219172191821919219202192121922219232192421925219262192721928219292193021931219322193321934219352193621937219382193921940219412194221943219442194521946219472194821949219502195121952219532195421955219562195721958219592196021961219622196321964219652196621967219682196921970219712197221973219742197521976219772197821979219802198121982219832198421985219862198721988219892199021991219922199321994219952199621997219982199922000220012200222003220042200522006220072200822009220102201122012220132201422015220162201722018220192202022021220222202322024220252202622027220282202922030220312203222033220342203522036220372203822039220402204122042220432204422045220462204722048220492205022051220522205322054220552205622057220582205922060220612206222063220642206522066220672206822069220702207122072220732207422075220762207722078220792208022081220822208322084220852208622087220882208922090220912209222093220942209522096220972209822099221002210122102221032210422105221062210722108221092211022111221122211322114221152211622117221182211922120221212212222123221242212522126221272212822129221302213122132221332213422135221362213722138221392214022141221422214322144221452214622147221482214922150221512215222153221542215522156221572215822159221602216122162221632216422165221662216722168221692217022171221722217322174221752217622177221782217922180221812218222183221842218522186221872218822189221902219122192221932219422195221962219722198221992220022201222022220322204222052220622207222082220922210222112221222213222142221522216222172221822219222202222122222222232222422225222262222722228222292223022231222322223322234222352223622237222382223922240222412224222243222442224522246222472224822249222502225122252222532225422255222562225722258222592226022261222622226322264222652226622267222682226922270222712227222273222742227522276222772227822279222802228122282222832228422285222862228722288222892229022291222922229322294222952229622297222982229922300223012230222303223042230522306223072230822309223102231122312223132231422315223162231722318223192232022321223222232322324223252232622327223282232922330223312233222333223342233522336223372233822339223402234122342223432234422345223462234722348223492235022351223522235322354223552235622357223582235922360223612236222363223642236522366223672236822369223702237122372223732237422375223762237722378223792238022381223822238322384223852238622387223882238922390223912239222393223942239522396223972239822399224002240122402224032240422405224062240722408224092241022411224122241322414224152241622417224182241922420224212242222423224242242522426224272242822429224302243122432224332243422435224362243722438224392244022441224422244322444224452244622447224482244922450224512245222453224542245522456224572245822459224602246122462224632246422465224662246722468224692247022471224722247322474224752247622477224782247922480224812248222483224842248522486224872248822489224902249122492224932249422495224962249722498224992250022501225022250322504225052250622507225082250922510225112251222513225142251522516225172251822519225202252122522225232252422525225262252722528225292253022531225322253322534225352253622537225382253922540225412254222543225442254522546225472254822549225502255122552225532255422555225562255722558225592256022561225622256322564225652256622567225682256922570225712257222573225742257522576225772257822579225802258122582225832258422585225862258722588225892259022591225922259322594225952259622597225982259922600226012260222603226042260522606226072260822609226102261122612226132261422615226162261722618226192262022621226222262322624226252262622627226282262922630226312263222633226342263522636226372263822639226402264122642226432264422645226462264722648226492265022651226522265322654226552265622657226582265922660226612266222663226642266522666226672266822669226702267122672226732267422675226762267722678226792268022681226822268322684226852268622687226882268922690226912269222693226942269522696226972269822699227002270122702227032270422705227062270722708227092271022711227122271322714227152271622717227182271922720227212272222723227242272522726227272272822729227302273122732227332273422735227362273722738227392274022741227422274322744227452274622747227482274922750227512275222753227542275522756227572275822759227602276122762227632276422765227662276722768227692277022771227722277322774227752277622777227782277922780227812278222783227842278522786227872278822789227902279122792227932279422795227962279722798227992280022801228022280322804228052280622807228082280922810228112281222813228142281522816228172281822819228202282122822228232282422825228262282722828228292283022831228322283322834228352283622837228382283922840228412284222843228442284522846228472284822849228502285122852228532285422855228562285722858228592286022861228622286322864228652286622867228682286922870228712287222873228742287522876228772287822879228802288122882228832288422885228862288722888228892289022891228922289322894228952289622897228982289922900229012290222903229042290522906229072290822909229102291122912229132291422915229162291722918229192292022921229222292322924229252292622927229282292922930229312293222933229342293522936229372293822939229402294122942229432294422945229462294722948229492295022951229522295322954229552295622957229582295922960229612296222963229642296522966229672296822969229702297122972229732297422975229762297722978229792298022981229822298322984229852298622987229882298922990229912299222993229942299522996229972299822999230002300123002230032300423005230062300723008230092301023011230122301323014230152301623017230182301923020230212302223023230242302523026230272302823029230302303123032230332303423035230362303723038230392304023041230422304323044230452304623047230482304923050230512305223053230542305523056230572305823059230602306123062230632306423065230662306723068230692307023071230722307323074230752307623077230782307923080230812308223083230842308523086230872308823089230902309123092230932309423095230962309723098230992310023101231022310323104231052310623107231082310923110231112311223113231142311523116231172311823119231202312123122231232312423125231262312723128231292313023131231322313323134231352313623137231382313923140231412314223143231442314523146231472314823149231502315123152231532315423155231562315723158231592316023161231622316323164231652316623167231682316923170231712317223173231742317523176231772317823179231802318123182231832318423185231862318723188231892319023191231922319323194231952319623197231982319923200232012320223203232042320523206232072320823209232102321123212232132321423215232162321723218232192322023221232222322323224232252322623227232282322923230232312323223233232342323523236232372323823239232402324123242232432324423245232462324723248232492325023251232522325323254232552325623257232582325923260232612326223263232642326523266232672326823269232702327123272232732327423275232762327723278232792328023281232822328323284232852328623287232882328923290232912329223293232942329523296232972329823299233002330123302233032330423305233062330723308233092331023311233122331323314233152331623317233182331923320233212332223323233242332523326233272332823329233302333123332233332333423335233362333723338233392334023341233422334323344233452334623347233482334923350233512335223353233542335523356233572335823359233602336123362233632336423365233662336723368233692337023371233722337323374233752337623377233782337923380233812338223383233842338523386233872338823389233902339123392233932339423395233962339723398233992340023401234022340323404234052340623407234082340923410234112341223413234142341523416234172341823419234202342123422234232342423425234262342723428234292343023431234322343323434234352343623437234382343923440234412344223443234442344523446234472344823449234502345123452234532345423455234562345723458234592346023461234622346323464234652346623467234682346923470234712347223473234742347523476234772347823479234802348123482234832348423485234862348723488234892349023491234922349323494234952349623497234982349923500235012350223503235042350523506235072350823509235102351123512235132351423515235162351723518235192352023521235222352323524235252352623527235282352923530235312353223533235342353523536235372353823539235402354123542235432354423545235462354723548235492355023551235522355323554235552355623557235582355923560235612356223563235642356523566235672356823569235702357123572235732357423575235762357723578235792358023581235822358323584235852358623587235882358923590235912359223593235942359523596235972359823599236002360123602236032360423605236062360723608236092361023611236122361323614236152361623617236182361923620236212362223623236242362523626236272362823629236302363123632236332363423635236362363723638236392364023641236422364323644236452364623647236482364923650236512365223653236542365523656236572365823659236602366123662236632366423665236662366723668236692367023671236722367323674236752367623677236782367923680236812368223683236842368523686236872368823689236902369123692236932369423695236962369723698236992370023701237022370323704237052370623707237082370923710237112371223713237142371523716237172371823719237202372123722237232372423725237262372723728237292373023731237322373323734237352373623737237382373923740237412374223743237442374523746237472374823749237502375123752237532375423755237562375723758237592376023761237622376323764237652376623767237682376923770237712377223773237742377523776237772377823779237802378123782237832378423785237862378723788237892379023791237922379323794237952379623797237982379923800238012380223803238042380523806238072380823809238102381123812238132381423815238162381723818238192382023821238222382323824238252382623827238282382923830238312383223833238342383523836238372383823839238402384123842238432384423845238462384723848238492385023851238522385323854238552385623857238582385923860238612386223863238642386523866238672386823869238702387123872238732387423875238762387723878238792388023881238822388323884238852388623887238882388923890238912389223893238942389523896238972389823899239002390123902239032390423905239062390723908239092391023911239122391323914239152391623917239182391923920239212392223923239242392523926239272392823929239302393123932239332393423935239362393723938239392394023941239422394323944239452394623947239482394923950239512395223953239542395523956239572395823959239602396123962239632396423965239662396723968239692397023971239722397323974239752397623977239782397923980239812398223983239842398523986239872398823989239902399123992239932399423995239962399723998239992400024001240022400324004240052400624007240082400924010240112401224013240142401524016240172401824019240202402124022240232402424025240262402724028240292403024031240322403324034240352403624037240382403924040240412404224043240442404524046240472404824049240502405124052240532405424055240562405724058240592406024061240622406324064240652406624067240682406924070240712407224073240742407524076240772407824079240802408124082240832408424085240862408724088240892409024091240922409324094240952409624097240982409924100241012410224103241042410524106241072410824109241102411124112241132411424115241162411724118241192412024121241222412324124241252412624127241282412924130241312413224133241342413524136241372413824139241402414124142241432414424145241462414724148241492415024151241522415324154241552415624157241582415924160241612416224163241642416524166241672416824169241702417124172241732417424175241762417724178241792418024181241822418324184241852418624187241882418924190241912419224193241942419524196241972419824199242002420124202242032420424205242062420724208242092421024211242122421324214242152421624217242182421924220242212422224223242242422524226242272422824229242302423124232242332423424235242362423724238242392424024241242422424324244242452424624247242482424924250242512425224253242542425524256242572425824259242602426124262242632426424265242662426724268242692427024271242722427324274242752427624277242782427924280242812428224283242842428524286242872428824289242902429124292242932429424295242962429724298242992430024301243022430324304243052430624307243082430924310243112431224313243142431524316243172431824319243202432124322243232432424325243262432724328243292433024331243322433324334243352433624337243382433924340243412434224343243442434524346243472434824349243502435124352243532435424355243562435724358243592436024361243622436324364243652436624367243682436924370243712437224373243742437524376243772437824379243802438124382243832438424385243862438724388243892439024391243922439324394243952439624397243982439924400244012440224403244042440524406244072440824409244102441124412244132441424415244162441724418244192442024421244222442324424244252442624427244282442924430244312443224433244342443524436244372443824439244402444124442244432444424445244462444724448244492445024451244522445324454244552445624457244582445924460244612446224463244642446524466244672446824469244702447124472244732447424475244762447724478244792448024481244822448324484244852448624487244882448924490244912449224493244942449524496244972449824499245002450124502245032450424505245062450724508245092451024511245122451324514245152451624517245182451924520245212452224523245242452524526245272452824529245302453124532245332453424535245362453724538245392454024541245422454324544245452454624547245482454924550245512455224553245542455524556245572455824559245602456124562245632456424565245662456724568245692457024571245722457324574245752457624577245782457924580245812458224583245842458524586245872458824589245902459124592245932459424595245962459724598245992460024601246022460324604246052460624607246082460924610246112461224613246142461524616246172461824619246202462124622246232462424625246262462724628246292463024631246322463324634246352463624637246382463924640246412464224643246442464524646246472464824649246502465124652246532465424655246562465724658246592466024661246622466324664246652466624667246682466924670246712467224673246742467524676246772467824679246802468124682246832468424685246862468724688246892469024691246922469324694246952469624697246982469924700247012470224703247042470524706247072470824709247102471124712247132471424715247162471724718247192472024721247222472324724247252472624727247282472924730247312473224733247342473524736247372473824739247402474124742247432474424745247462474724748247492475024751247522475324754247552475624757247582475924760247612476224763247642476524766247672476824769247702477124772247732477424775247762477724778247792478024781247822478324784247852478624787247882478924790247912479224793247942479524796247972479824799248002480124802248032480424805248062480724808248092481024811248122481324814248152481624817248182481924820248212482224823248242482524826248272482824829248302483124832248332483424835248362483724838248392484024841248422484324844248452484624847248482484924850248512485224853248542485524856248572485824859248602486124862248632486424865248662486724868248692487024871248722487324874248752487624877248782487924880248812488224883248842488524886248872488824889248902489124892248932489424895248962489724898248992490024901249022490324904249052490624907249082490924910249112491224913249142491524916249172491824919249202492124922249232492424925249262492724928249292493024931249322493324934249352493624937249382493924940249412494224943249442494524946249472494824949249502495124952249532495424955249562495724958249592496024961249622496324964249652496624967249682496924970249712497224973249742497524976249772497824979249802498124982249832498424985249862498724988249892499024991249922499324994249952499624997249982499925000250012500225003250042500525006250072500825009250102501125012250132501425015250162501725018250192502025021250222502325024250252502625027250282502925030250312503225033250342503525036250372503825039250402504125042250432504425045250462504725048250492505025051250522505325054250552505625057250582505925060250612506225063250642506525066250672506825069250702507125072250732507425075250762507725078250792508025081250822508325084250852508625087250882508925090250912509225093250942509525096250972509825099251002510125102251032510425105251062510725108251092511025111251122511325114251152511625117251182511925120251212512225123251242512525126251272512825129251302513125132251332513425135251362513725138251392514025141251422514325144251452514625147251482514925150251512515225153251542515525156251572515825159251602516125162251632516425165251662516725168251692517025171251722517325174251752517625177251782517925180251812518225183251842518525186251872518825189251902519125192251932519425195251962519725198251992520025201252022520325204252052520625207252082520925210252112521225213252142521525216252172521825219252202522125222252232522425225252262522725228252292523025231252322523325234252352523625237252382523925240252412524225243252442524525246252472524825249252502525125252252532525425255252562525725258252592526025261252622526325264252652526625267252682526925270252712527225273252742527525276252772527825279252802528125282252832528425285252862528725288252892529025291252922529325294252952529625297252982529925300253012530225303253042530525306253072530825309253102531125312253132531425315253162531725318253192532025321253222532325324253252532625327253282532925330253312533225333253342533525336253372533825339253402534125342253432534425345253462534725348253492535025351253522535325354253552535625357253582535925360253612536225363253642536525366253672536825369253702537125372253732537425375253762537725378253792538025381253822538325384253852538625387253882538925390253912539225393253942539525396253972539825399254002540125402254032540425405254062540725408254092541025411254122541325414254152541625417254182541925420254212542225423254242542525426254272542825429254302543125432254332543425435254362543725438254392544025441254422544325444254452544625447254482544925450254512545225453254542545525456254572545825459254602546125462254632546425465254662546725468254692547025471254722547325474254752547625477254782547925480254812548225483254842548525486254872548825489254902549125492254932549425495254962549725498254992550025501255022550325504255052550625507255082550925510255112551225513255142551525516255172551825519255202552125522255232552425525255262552725528255292553025531255322553325534255352553625537255382553925540255412554225543255442554525546255472554825549255502555125552255532555425555255562555725558255592556025561255622556325564255652556625567255682556925570255712557225573255742557525576255772557825579255802558125582255832558425585255862558725588255892559025591255922559325594255952559625597255982559925600256012560225603256042560525606256072560825609256102561125612256132561425615256162561725618256192562025621256222562325624256252562625627256282562925630256312563225633256342563525636256372563825639256402564125642256432564425645256462564725648256492565025651256522565325654256552565625657256582565925660256612566225663256642566525666256672566825669256702567125672256732567425675256762567725678256792568025681256822568325684256852568625687256882568925690256912569225693256942569525696256972569825699257002570125702257032570425705257062570725708257092571025711257122571325714257152571625717257182571925720257212572225723257242572525726257272572825729257302573125732257332573425735257362573725738257392574025741257422574325744257452574625747257482574925750257512575225753257542575525756257572575825759257602576125762257632576425765257662576725768257692577025771257722577325774257752577625777257782577925780257812578225783257842578525786257872578825789257902579125792257932579425795257962579725798257992580025801258022580325804258052580625807258082580925810258112581225813258142581525816258172581825819258202582125822258232582425825258262582725828258292583025831258322583325834258352583625837258382583925840258412584225843258442584525846258472584825849258502585125852258532585425855258562585725858258592586025861258622586325864258652586625867258682586925870258712587225873258742587525876258772587825879258802588125882258832588425885258862588725888258892589025891258922589325894258952589625897258982589925900259012590225903259042590525906259072590825909259102591125912259132591425915259162591725918259192592025921259222592325924259252592625927259282592925930259312593225933259342593525936259372593825939259402594125942259432594425945259462594725948259492595025951259522595325954259552595625957259582595925960259612596225963259642596525966259672596825969259702597125972259732597425975259762597725978259792598025981259822598325984259852598625987259882598925990259912599225993259942599525996259972599825999260002600126002260032600426005260062600726008260092601026011260122601326014260152601626017260182601926020260212602226023260242602526026260272602826029260302603126032260332603426035260362603726038260392604026041260422604326044260452604626047260482604926050260512605226053260542605526056260572605826059260602606126062260632606426065260662606726068260692607026071260722607326074260752607626077260782607926080260812608226083260842608526086260872608826089260902609126092260932609426095260962609726098260992610026101261022610326104261052610626107261082610926110261112611226113261142611526116261172611826119261202612126122261232612426125261262612726128261292613026131261322613326134261352613626137261382613926140261412614226143261442614526146261472614826149261502615126152261532615426155261562615726158261592616026161261622616326164261652616626167261682616926170261712617226173261742617526176261772617826179261802618126182261832618426185261862618726188261892619026191261922619326194261952619626197261982619926200262012620226203262042620526206262072620826209262102621126212262132621426215262162621726218262192622026221262222622326224262252622626227262282622926230262312623226233262342623526236262372623826239262402624126242262432624426245262462624726248262492625026251262522625326254262552625626257262582625926260262612626226263262642626526266262672626826269262702627126272262732627426275262762627726278262792628026281262822628326284262852628626287262882628926290262912629226293262942629526296262972629826299263002630126302263032630426305263062630726308263092631026311263122631326314263152631626317263182631926320263212632226323263242632526326263272632826329263302633126332263332633426335263362633726338263392634026341263422634326344263452634626347263482634926350263512635226353263542635526356263572635826359263602636126362263632636426365263662636726368263692637026371263722637326374263752637626377263782637926380263812638226383263842638526386263872638826389263902639126392263932639426395263962639726398263992640026401264022640326404264052640626407264082640926410264112641226413264142641526416264172641826419264202642126422264232642426425264262642726428264292643026431264322643326434264352643626437264382643926440264412644226443264442644526446264472644826449264502645126452264532645426455264562645726458264592646026461264622646326464264652646626467264682646926470264712647226473264742647526476264772647826479264802648126482264832648426485264862648726488264892649026491264922649326494264952649626497264982649926500265012650226503265042650526506265072650826509265102651126512265132651426515265162651726518265192652026521265222652326524265252652626527265282652926530265312653226533265342653526536265372653826539265402654126542265432654426545265462654726548265492655026551265522655326554265552655626557265582655926560265612656226563265642656526566265672656826569265702657126572265732657426575265762657726578265792658026581265822658326584265852658626587265882658926590265912659226593265942659526596265972659826599266002660126602266032660426605266062660726608266092661026611266122661326614266152661626617266182661926620266212662226623266242662526626266272662826629266302663126632266332663426635266362663726638266392664026641266422664326644266452664626647266482664926650266512665226653266542665526656266572665826659266602666126662266632666426665266662666726668266692667026671266722667326674266752667626677266782667926680266812668226683266842668526686266872668826689266902669126692266932669426695266962669726698266992670026701267022670326704267052670626707267082670926710267112671226713267142671526716267172671826719267202672126722267232672426725267262672726728267292673026731267322673326734267352673626737267382673926740267412674226743267442674526746267472674826749267502675126752267532675426755267562675726758267592676026761267622676326764267652676626767267682676926770267712677226773267742677526776267772677826779267802678126782267832678426785267862678726788267892679026791267922679326794267952679626797267982679926800268012680226803268042680526806268072680826809268102681126812268132681426815268162681726818268192682026821268222682326824268252682626827268282682926830268312683226833268342683526836268372683826839268402684126842268432684426845268462684726848268492685026851268522685326854268552685626857268582685926860268612686226863268642686526866268672686826869268702687126872268732687426875268762687726878268792688026881268822688326884268852688626887268882688926890268912689226893268942689526896268972689826899269002690126902269032690426905269062690726908269092691026911269122691326914269152691626917269182691926920269212692226923269242692526926269272692826929269302693126932269332693426935269362693726938269392694026941269422694326944269452694626947269482694926950269512695226953269542695526956269572695826959269602696126962269632696426965269662696726968269692697026971269722697326974269752697626977269782697926980269812698226983269842698526986269872698826989269902699126992269932699426995269962699726998269992700027001270022700327004270052700627007270082700927010270112701227013270142701527016270172701827019270202702127022270232702427025270262702727028270292703027031270322703327034270352703627037270382703927040270412704227043270442704527046270472704827049270502705127052270532705427055270562705727058270592706027061270622706327064270652706627067270682706927070270712707227073270742707527076270772707827079270802708127082270832708427085270862708727088270892709027091270922709327094270952709627097270982709927100271012710227103271042710527106271072710827109271102711127112271132711427115271162711727118271192712027121271222712327124271252712627127271282712927130271312713227133271342713527136271372713827139271402714127142271432714427145271462714727148271492715027151271522715327154271552715627157271582715927160271612716227163271642716527166271672716827169271702717127172271732717427175271762717727178271792718027181271822718327184271852718627187271882718927190271912719227193271942719527196271972719827199272002720127202272032720427205272062720727208272092721027211272122721327214272152721627217272182721927220272212722227223272242722527226272272722827229272302723127232272332723427235272362723727238272392724027241272422724327244272452724627247272482724927250272512725227253272542725527256272572725827259272602726127262272632726427265272662726727268272692727027271272722727327274272752727627277272782727927280272812728227283272842728527286272872728827289272902729127292272932729427295272962729727298272992730027301273022730327304273052730627307273082730927310273112731227313273142731527316273172731827319273202732127322273232732427325273262732727328273292733027331273322733327334273352733627337273382733927340273412734227343273442734527346273472734827349273502735127352273532735427355273562735727358273592736027361273622736327364273652736627367273682736927370273712737227373273742737527376273772737827379273802738127382273832738427385273862738727388273892739027391273922739327394273952739627397273982739927400274012740227403274042740527406274072740827409274102741127412274132741427415274162741727418274192742027421274222742327424274252742627427274282742927430274312743227433274342743527436274372743827439274402744127442274432744427445274462744727448274492745027451274522745327454274552745627457274582745927460274612746227463274642746527466274672746827469274702747127472274732747427475274762747727478274792748027481274822748327484274852748627487274882748927490274912749227493274942749527496274972749827499275002750127502275032750427505275062750727508275092751027511275122751327514275152751627517275182751927520275212752227523275242752527526275272752827529275302753127532275332753427535275362753727538275392754027541275422754327544275452754627547275482754927550275512755227553275542755527556275572755827559275602756127562275632756427565275662756727568275692757027571275722757327574275752757627577275782757927580275812758227583275842758527586275872758827589275902759127592275932759427595275962759727598275992760027601276022760327604276052760627607276082760927610276112761227613276142761527616276172761827619276202762127622276232762427625276262762727628276292763027631276322763327634276352763627637276382763927640276412764227643276442764527646276472764827649276502765127652276532765427655276562765727658276592766027661276622766327664276652766627667276682766927670276712767227673276742767527676276772767827679276802768127682276832768427685276862768727688276892769027691276922769327694276952769627697276982769927700277012770227703277042770527706277072770827709277102771127712277132771427715277162771727718277192772027721277222772327724277252772627727277282772927730277312773227733277342773527736277372773827739277402774127742277432774427745277462774727748277492775027751277522775327754277552775627757277582775927760277612776227763277642776527766277672776827769277702777127772277732777427775277762777727778277792778027781277822778327784277852778627787277882778927790277912779227793277942779527796277972779827799278002780127802278032780427805278062780727808278092781027811278122781327814278152781627817278182781927820278212782227823278242782527826278272782827829278302783127832278332783427835278362783727838278392784027841278422784327844278452784627847278482784927850278512785227853278542785527856278572785827859278602786127862278632786427865278662786727868278692787027871278722787327874278752787627877278782787927880278812788227883278842788527886278872788827889278902789127892278932789427895278962789727898278992790027901279022790327904279052790627907279082790927910279112791227913279142791527916279172791827919279202792127922279232792427925279262792727928279292793027931279322793327934279352793627937279382793927940279412794227943279442794527946279472794827949279502795127952279532795427955279562795727958279592796027961279622796327964279652796627967279682796927970279712797227973279742797527976279772797827979279802798127982279832798427985279862798727988279892799027991279922799327994279952799627997279982799928000280012800228003280042800528006280072800828009280102801128012280132801428015280162801728018280192802028021280222802328024280252802628027280282802928030280312803228033280342803528036280372803828039280402804128042280432804428045280462804728048280492805028051280522805328054280552805628057280582805928060280612806228063280642806528066280672806828069280702807128072280732807428075280762807728078280792808028081280822808328084280852808628087280882808928090280912809228093280942809528096280972809828099281002810128102281032810428105281062810728108281092811028111281122811328114281152811628117281182811928120281212812228123281242812528126281272812828129281302813128132281332813428135281362813728138281392814028141281422814328144281452814628147281482814928150281512815228153281542815528156281572815828159281602816128162281632816428165281662816728168281692817028171281722817328174281752817628177281782817928180281812818228183281842818528186281872818828189281902819128192281932819428195281962819728198281992820028201282022820328204282052820628207282082820928210282112821228213282142821528216282172821828219282202822128222282232822428225282262822728228282292823028231282322823328234282352823628237282382823928240282412824228243282442824528246282472824828249282502825128252282532825428255282562825728258282592826028261282622826328264282652826628267282682826928270282712827228273282742827528276282772827828279282802828128282282832828428285282862828728288282892829028291282922829328294282952829628297282982829928300283012830228303283042830528306283072830828309283102831128312283132831428315283162831728318283192832028321283222832328324283252832628327283282832928330283312833228333283342833528336283372833828339283402834128342283432834428345283462834728348283492835028351283522835328354283552835628357283582835928360283612836228363283642836528366283672836828369283702837128372283732837428375283762837728378283792838028381283822838328384283852838628387283882838928390283912839228393283942839528396283972839828399284002840128402284032840428405284062840728408284092841028411284122841328414284152841628417284182841928420284212842228423284242842528426284272842828429284302843128432284332843428435284362843728438284392844028441284422844328444284452844628447284482844928450284512845228453284542845528456284572845828459284602846128462284632846428465284662846728468284692847028471284722847328474284752847628477284782847928480284812848228483284842848528486284872848828489284902849128492284932849428495284962849728498284992850028501285022850328504285052850628507285082850928510285112851228513285142851528516285172851828519285202852128522285232852428525285262852728528285292853028531285322853328534285352853628537285382853928540285412854228543285442854528546285472854828549285502855128552285532855428555285562855728558285592856028561285622856328564285652856628567285682856928570285712857228573285742857528576285772857828579285802858128582285832858428585285862858728588285892859028591285922859328594285952859628597285982859928600286012860228603286042860528606286072860828609286102861128612286132861428615286162861728618286192862028621286222862328624286252862628627286282862928630286312863228633286342863528636286372863828639286402864128642286432864428645286462864728648286492865028651286522865328654286552865628657286582865928660286612866228663286642866528666286672866828669286702867128672286732867428675286762867728678286792868028681286822868328684286852868628687286882868928690286912869228693286942869528696286972869828699287002870128702287032870428705287062870728708287092871028711287122871328714287152871628717287182871928720287212872228723287242872528726287272872828729287302873128732287332873428735287362873728738287392874028741287422874328744287452874628747287482874928750287512875228753287542875528756287572875828759287602876128762287632876428765287662876728768287692877028771287722877328774287752877628777287782877928780287812878228783287842878528786287872878828789287902879128792287932879428795287962879728798287992880028801288022880328804288052880628807288082880928810288112881228813288142881528816288172881828819288202882128822288232882428825288262882728828288292883028831288322883328834288352883628837288382883928840288412884228843288442884528846288472884828849288502885128852288532885428855288562885728858288592886028861288622886328864288652886628867288682886928870288712887228873288742887528876288772887828879288802888128882288832888428885288862888728888288892889028891288922889328894288952889628897288982889928900289012890228903289042890528906289072890828909289102891128912289132891428915289162891728918289192892028921289222892328924289252892628927289282892928930289312893228933289342893528936289372893828939289402894128942289432894428945289462894728948289492895028951289522895328954289552895628957289582895928960289612896228963289642896528966289672896828969289702897128972289732897428975289762897728978289792898028981289822898328984289852898628987289882898928990289912899228993289942899528996289972899828999290002900129002290032900429005290062900729008290092901029011290122901329014290152901629017290182901929020290212902229023290242902529026290272902829029290302903129032290332903429035290362903729038290392904029041290422904329044290452904629047290482904929050290512905229053290542905529056290572905829059290602906129062290632906429065290662906729068290692907029071290722907329074290752907629077290782907929080290812908229083290842908529086290872908829089290902909129092290932909429095290962909729098290992910029101291022910329104291052910629107291082910929110291112911229113291142911529116291172911829119291202912129122291232912429125291262912729128291292913029131291322913329134291352913629137291382913929140291412914229143291442914529146291472914829149291502915129152291532915429155291562915729158291592916029161291622916329164291652916629167291682916929170291712917229173291742917529176291772917829179291802918129182291832918429185291862918729188291892919029191291922919329194291952919629197291982919929200292012920229203292042920529206292072920829209292102921129212292132921429215292162921729218292192922029221292222922329224292252922629227292282922929230292312923229233292342923529236292372923829239292402924129242292432924429245292462924729248292492925029251292522925329254292552925629257292582925929260292612926229263292642926529266292672926829269292702927129272292732927429275292762927729278292792928029281292822928329284292852928629287292882928929290292912929229293292942929529296292972929829299293002930129302293032930429305293062930729308293092931029311293122931329314293152931629317293182931929320293212932229323293242932529326293272932829329293302933129332293332933429335293362933729338293392934029341293422934329344293452934629347293482934929350293512935229353293542935529356293572935829359293602936129362293632936429365293662936729368293692937029371293722937329374293752937629377293782937929380293812938229383293842938529386293872938829389293902939129392293932939429395293962939729398293992940029401294022940329404294052940629407294082940929410294112941229413294142941529416294172941829419294202942129422294232942429425294262942729428294292943029431294322943329434294352943629437294382943929440294412944229443294442944529446294472944829449294502945129452294532945429455294562945729458294592946029461294622946329464294652946629467294682946929470294712947229473294742947529476294772947829479294802948129482294832948429485294862948729488294892949029491294922949329494294952949629497294982949929500295012950229503295042950529506295072950829509295102951129512295132951429515295162951729518295192952029521295222952329524295252952629527295282952929530295312953229533295342953529536295372953829539295402954129542295432954429545295462954729548295492955029551295522955329554295552955629557295582955929560295612956229563295642956529566295672956829569295702957129572295732957429575295762957729578295792958029581295822958329584295852958629587295882958929590295912959229593295942959529596295972959829599296002960129602296032960429605296062960729608296092961029611296122961329614296152961629617296182961929620296212962229623296242962529626296272962829629296302963129632296332963429635296362963729638296392964029641296422964329644296452964629647296482964929650296512965229653296542965529656296572965829659296602966129662296632966429665296662966729668296692967029671296722967329674296752967629677296782967929680296812968229683296842968529686296872968829689296902969129692296932969429695296962969729698296992970029701297022970329704297052970629707297082970929710297112971229713297142971529716297172971829719297202972129722297232972429725297262972729728297292973029731297322973329734297352973629737297382973929740297412974229743297442974529746297472974829749297502975129752297532975429755297562975729758297592976029761297622976329764297652976629767297682976929770297712977229773297742977529776297772977829779297802978129782297832978429785297862978729788297892979029791297922979329794297952979629797297982979929800298012980229803298042980529806298072980829809298102981129812298132981429815298162981729818298192982029821298222982329824298252982629827298282982929830298312983229833298342983529836298372983829839298402984129842298432984429845298462984729848298492985029851298522985329854298552985629857298582985929860298612986229863298642986529866298672986829869298702987129872298732987429875298762987729878298792988029881298822988329884298852988629887298882988929890298912989229893298942989529896298972989829899299002990129902299032990429905299062990729908299092991029911299122991329914299152991629917299182991929920299212992229923299242992529926299272992829929299302993129932299332993429935299362993729938299392994029941299422994329944299452994629947299482994929950299512995229953299542995529956299572995829959299602996129962299632996429965299662996729968299692997029971299722997329974299752997629977299782997929980299812998229983299842998529986299872998829989299902999129992299932999429995299962999729998299993000030001300023000330004300053000630007300083000930010300113001230013300143001530016300173001830019300203002130022300233002430025300263002730028300293003030031300323003330034300353003630037300383003930040300413004230043300443004530046300473004830049300503005130052300533005430055300563005730058300593006030061300623006330064300653006630067300683006930070300713007230073300743007530076300773007830079300803008130082300833008430085300863008730088300893009030091300923009330094300953009630097300983009930100301013010230103301043010530106301073010830109301103011130112301133011430115301163011730118301193012030121301223012330124301253012630127301283012930130301313013230133301343013530136301373013830139301403014130142301433014430145301463014730148301493015030151301523015330154301553015630157301583015930160301613016230163301643016530166301673016830169301703017130172301733017430175301763017730178301793018030181301823018330184301853018630187301883018930190301913019230193301943019530196301973019830199302003020130202302033020430205302063020730208302093021030211302123021330214302153021630217302183021930220302213022230223302243022530226302273022830229302303023130232302333023430235302363023730238302393024030241302423024330244302453024630247302483024930250302513025230253302543025530256302573025830259302603026130262302633026430265302663026730268302693027030271302723027330274302753027630277302783027930280302813028230283302843028530286302873028830289302903029130292302933029430295302963029730298302993030030301303023030330304303053030630307303083030930310303113031230313303143031530316303173031830319303203032130322303233032430325303263032730328303293033030331303323033330334303353033630337303383033930340303413034230343303443034530346303473034830349303503035130352303533035430355303563035730358303593036030361303623036330364303653036630367303683036930370303713037230373303743037530376303773037830379303803038130382303833038430385303863038730388303893039030391303923039330394303953039630397303983039930400304013040230403304043040530406304073040830409304103041130412304133041430415304163041730418304193042030421304223042330424304253042630427304283042930430304313043230433304343043530436304373043830439304403044130442304433044430445304463044730448304493045030451304523045330454304553045630457304583045930460304613046230463304643046530466304673046830469304703047130472304733047430475304763047730478304793048030481304823048330484304853048630487304883048930490304913049230493304943049530496304973049830499305003050130502305033050430505305063050730508305093051030511305123051330514305153051630517305183051930520305213052230523305243052530526305273052830529305303053130532305333053430535305363053730538305393054030541305423054330544305453054630547305483054930550305513055230553305543055530556305573055830559305603056130562305633056430565305663056730568305693057030571305723057330574305753057630577305783057930580305813058230583305843058530586305873058830589305903059130592305933059430595305963059730598305993060030601306023060330604306053060630607306083060930610306113061230613306143061530616306173061830619306203062130622306233062430625306263062730628306293063030631306323063330634306353063630637306383063930640306413064230643306443064530646306473064830649306503065130652306533065430655306563065730658306593066030661306623066330664306653066630667306683066930670306713067230673306743067530676306773067830679306803068130682306833068430685306863068730688306893069030691306923069330694306953069630697306983069930700307013070230703307043070530706307073070830709307103071130712307133071430715307163071730718307193072030721307223072330724307253072630727307283072930730307313073230733307343073530736307373073830739307403074130742307433074430745307463074730748307493075030751307523075330754307553075630757307583075930760307613076230763307643076530766307673076830769307703077130772307733077430775307763077730778307793078030781307823078330784307853078630787307883078930790307913079230793307943079530796307973079830799308003080130802308033080430805308063080730808308093081030811308123081330814308153081630817308183081930820308213082230823308243082530826308273082830829308303083130832308333083430835308363083730838308393084030841308423084330844308453084630847308483084930850308513085230853308543085530856308573085830859308603086130862308633086430865308663086730868308693087030871308723087330874308753087630877308783087930880308813088230883308843088530886308873088830889308903089130892308933089430895308963089730898308993090030901309023090330904309053090630907309083090930910309113091230913309143091530916309173091830919309203092130922309233092430925309263092730928309293093030931309323093330934309353093630937309383093930940309413094230943309443094530946309473094830949309503095130952309533095430955309563095730958309593096030961309623096330964309653096630967309683096930970309713097230973309743097530976309773097830979309803098130982309833098430985309863098730988309893099030991309923099330994309953099630997309983099931000310013100231003310043100531006310073100831009310103101131012310133101431015310163101731018310193102031021310223102331024310253102631027310283102931030310313103231033310343103531036310373103831039310403104131042310433104431045310463104731048310493105031051310523105331054310553105631057310583105931060310613106231063310643106531066310673106831069310703107131072310733107431075310763107731078310793108031081310823108331084310853108631087310883108931090310913109231093310943109531096310973109831099311003110131102311033110431105311063110731108311093111031111311123111331114311153111631117311183111931120311213112231123311243112531126311273112831129311303113131132311333113431135311363113731138311393114031141311423114331144311453114631147311483114931150311513115231153311543115531156311573115831159311603116131162311633116431165311663116731168311693117031171311723117331174311753117631177311783117931180311813118231183311843118531186311873118831189311903119131192311933119431195311963119731198311993120031201312023120331204312053120631207312083120931210312113121231213312143121531216312173121831219312203122131222312233122431225312263122731228312293123031231312323123331234312353123631237312383123931240312413124231243312443124531246312473124831249312503125131252312533125431255312563125731258312593126031261312623126331264312653126631267312683126931270312713127231273312743127531276312773127831279312803128131282312833128431285312863128731288312893129031291312923129331294312953129631297312983129931300313013130231303313043130531306313073130831309313103131131312313133131431315313163131731318313193132031321313223132331324313253132631327313283132931330313313133231333313343133531336313373133831339313403134131342313433134431345313463134731348313493135031351313523135331354313553135631357313583135931360313613136231363313643136531366313673136831369313703137131372313733137431375313763137731378313793138031381313823138331384313853138631387313883138931390313913139231393313943139531396313973139831399314003140131402314033140431405314063140731408314093141031411314123141331414314153141631417314183141931420314213142231423314243142531426314273142831429314303143131432314333143431435314363143731438314393144031441314423144331444314453144631447314483144931450314513145231453314543145531456314573145831459314603146131462314633146431465314663146731468314693147031471314723147331474314753147631477314783147931480314813148231483314843148531486314873148831489314903149131492314933149431495314963149731498314993150031501315023150331504315053150631507315083150931510315113151231513315143151531516315173151831519315203152131522315233152431525315263152731528315293153031531315323153331534315353153631537315383153931540315413154231543315443154531546315473154831549315503155131552315533155431555315563155731558315593156031561315623156331564315653156631567315683156931570315713157231573315743157531576315773157831579315803158131582315833158431585315863158731588315893159031591315923159331594315953159631597315983159931600316013160231603316043160531606316073160831609316103161131612316133161431615316163161731618316193162031621316223162331624316253162631627316283162931630316313163231633316343163531636316373163831639316403164131642316433164431645316463164731648316493165031651316523165331654316553165631657316583165931660316613166231663316643166531666316673166831669316703167131672316733167431675316763167731678316793168031681316823168331684316853168631687316883168931690316913169231693316943169531696316973169831699317003170131702317033170431705317063170731708317093171031711317123171331714317153171631717317183171931720317213172231723317243172531726317273172831729317303173131732317333173431735317363173731738317393174031741317423174331744317453174631747317483174931750317513175231753317543175531756317573175831759317603176131762317633176431765317663176731768317693177031771317723177331774317753177631777317783177931780317813178231783317843178531786317873178831789317903179131792317933179431795317963179731798317993180031801318023180331804318053180631807318083180931810318113181231813318143181531816318173181831819318203182131822318233182431825318263182731828318293183031831318323183331834318353183631837318383183931840318413184231843318443184531846318473184831849318503185131852318533185431855318563185731858318593186031861318623186331864318653186631867318683186931870318713187231873318743187531876318773187831879318803188131882318833188431885318863188731888318893189031891318923189331894318953189631897318983189931900319013190231903319043190531906319073190831909319103191131912319133191431915319163191731918319193192031921319223192331924319253192631927319283192931930319313193231933319343193531936319373193831939319403194131942319433194431945319463194731948319493195031951319523195331954319553195631957319583195931960319613196231963319643196531966319673196831969319703197131972319733197431975319763197731978319793198031981319823198331984319853198631987319883198931990319913199231993319943199531996319973199831999320003200132002320033200432005320063200732008320093201032011320123201332014320153201632017320183201932020320213202232023320243202532026320273202832029320303203132032320333203432035320363203732038320393204032041320423204332044320453204632047320483204932050320513205232053320543205532056320573205832059320603206132062320633206432065320663206732068320693207032071320723207332074320753207632077320783207932080320813208232083320843208532086320873208832089320903209132092320933209432095320963209732098320993210032101321023210332104321053210632107321083210932110321113211232113321143211532116321173211832119321203212132122321233212432125321263212732128321293213032131321323213332134321353213632137321383213932140321413214232143321443214532146321473214832149321503215132152321533215432155321563215732158321593216032161321623216332164321653216632167321683216932170321713217232173321743217532176321773217832179321803218132182321833218432185321863218732188321893219032191321923219332194321953219632197321983219932200322013220232203322043220532206322073220832209322103221132212322133221432215322163221732218322193222032221322223222332224322253222632227322283222932230322313223232233322343223532236322373223832239322403224132242322433224432245322463224732248322493225032251322523225332254322553225632257322583225932260322613226232263322643226532266322673226832269322703227132272322733227432275322763227732278322793228032281322823228332284322853228632287322883228932290322913229232293322943229532296322973229832299323003230132302323033230432305323063230732308323093231032311323123231332314323153231632317323183231932320323213232232323323243232532326323273232832329323303233132332323333233432335323363233732338323393234032341323423234332344323453234632347323483234932350323513235232353323543235532356323573235832359323603236132362323633236432365323663236732368323693237032371323723237332374323753237632377323783237932380323813238232383323843238532386323873238832389323903239132392323933239432395323963239732398323993240032401324023240332404324053240632407324083240932410324113241232413324143241532416324173241832419324203242132422324233242432425324263242732428324293243032431324323243332434324353243632437324383243932440324413244232443324443244532446324473244832449324503245132452324533245432455324563245732458324593246032461324623246332464324653246632467324683246932470324713247232473324743247532476324773247832479324803248132482324833248432485324863248732488324893249032491324923249332494324953249632497324983249932500325013250232503325043250532506325073250832509325103251132512325133251432515325163251732518325193252032521325223252332524325253252632527325283252932530325313253232533325343253532536325373253832539325403254132542325433254432545325463254732548325493255032551325523255332554325553255632557325583255932560325613256232563325643256532566325673256832569325703257132572325733257432575325763257732578325793258032581325823258332584325853258632587325883258932590325913259232593325943259532596325973259832599326003260132602326033260432605326063260732608326093261032611326123261332614326153261632617326183261932620326213262232623326243262532626326273262832629326303263132632326333263432635326363263732638326393264032641326423264332644326453264632647326483264932650326513265232653326543265532656326573265832659326603266132662326633266432665326663266732668326693267032671326723267332674326753267632677326783267932680326813268232683326843268532686326873268832689326903269132692326933269432695326963269732698326993270032701327023270332704327053270632707327083270932710327113271232713327143271532716327173271832719327203272132722327233272432725327263272732728327293273032731327323273332734327353273632737327383273932740327413274232743327443274532746327473274832749327503275132752327533275432755327563275732758327593276032761327623276332764327653276632767327683276932770327713277232773327743277532776327773277832779327803278132782327833278432785327863278732788327893279032791327923279332794327953279632797327983279932800328013280232803328043280532806328073280832809328103281132812328133281432815328163281732818328193282032821328223282332824328253282632827328283282932830328313283232833328343283532836328373283832839328403284132842328433284432845328463284732848328493285032851328523285332854328553285632857328583285932860328613286232863328643286532866328673286832869328703287132872328733287432875328763287732878328793288032881328823288332884328853288632887328883288932890328913289232893328943289532896328973289832899329003290132902329033290432905329063290732908329093291032911329123291332914329153291632917329183291932920329213292232923329243292532926329273292832929329303293132932329333293432935329363293732938329393294032941329423294332944329453294632947329483294932950329513295232953329543295532956329573295832959329603296132962329633296432965329663296732968329693297032971329723297332974329753297632977329783297932980329813298232983329843298532986329873298832989329903299132992329933299432995329963299732998329993300033001330023300333004330053300633007330083300933010330113301233013330143301533016330173301833019330203302133022330233302433025330263302733028330293303033031330323303333034330353303633037330383303933040330413304233043330443304533046330473304833049330503305133052330533305433055330563305733058330593306033061330623306333064330653306633067330683306933070330713307233073330743307533076330773307833079330803308133082330833308433085330863308733088330893309033091330923309333094330953309633097330983309933100331013310233103331043310533106331073310833109331103311133112331133311433115331163311733118331193312033121331223312333124331253312633127331283312933130331313313233133331343313533136331373313833139331403314133142331433314433145331463314733148331493315033151331523315333154331553315633157331583315933160331613316233163331643316533166331673316833169331703317133172331733317433175331763317733178331793318033181331823318333184331853318633187331883318933190331913319233193331943319533196331973319833199332003320133202332033320433205332063320733208332093321033211332123321333214332153321633217332183321933220332213322233223332243322533226332273322833229332303323133232332333323433235332363323733238332393324033241332423324333244332453324633247332483324933250332513325233253332543325533256332573325833259332603326133262332633326433265332663326733268332693327033271332723327333274332753327633277332783327933280332813328233283332843328533286332873328833289332903329133292332933329433295332963329733298332993330033301333023330333304333053330633307333083330933310333113331233313333143331533316333173331833319333203332133322333233332433325333263332733328333293333033331333323333333334333353333633337333383333933340333413334233343333443334533346333473334833349333503335133352333533335433355333563335733358333593336033361333623336333364333653336633367333683336933370333713337233373333743337533376333773337833379333803338133382333833338433385333863338733388333893339033391333923339333394333953339633397333983339933400334013340233403334043340533406334073340833409334103341133412334133341433415334163341733418334193342033421334223342333424334253342633427334283342933430334313343233433334343343533436334373343833439334403344133442334433344433445334463344733448334493345033451334523345333454334553345633457334583345933460334613346233463334643346533466334673346833469334703347133472334733347433475334763347733478334793348033481334823348333484334853348633487334883348933490334913349233493334943349533496334973349833499335003350133502335033350433505335063350733508335093351033511335123351333514335153351633517335183351933520335213352233523335243352533526335273352833529335303353133532335333353433535335363353733538335393354033541335423354333544335453354633547335483354933550335513355233553335543355533556335573355833559335603356133562335633356433565335663356733568335693357033571335723357333574335753357633577335783357933580335813358233583335843358533586335873358833589335903359133592335933359433595335963359733598335993360033601336023360333604336053360633607336083360933610336113361233613336143361533616336173361833619336203362133622336233362433625336263362733628336293363033631336323363333634336353363633637336383363933640336413364233643336443364533646336473364833649336503365133652336533365433655336563365733658336593366033661336623366333664336653366633667336683366933670336713367233673336743367533676336773367833679336803368133682336833368433685336863368733688336893369033691336923369333694336953369633697336983369933700337013370233703337043370533706337073370833709337103371133712337133371433715337163371733718337193372033721337223372333724337253372633727337283372933730337313373233733337343373533736337373373833739337403374133742337433374433745337463374733748337493375033751337523375333754337553375633757337583375933760337613376233763337643376533766337673376833769337703377133772337733377433775337763377733778337793378033781337823378333784337853378633787337883378933790337913379233793337943379533796337973379833799338003380133802338033380433805338063380733808338093381033811338123381333814338153381633817338183381933820338213382233823338243382533826338273382833829338303383133832338333383433835338363383733838338393384033841338423384333844338453384633847338483384933850338513385233853338543385533856338573385833859338603386133862338633386433865338663386733868338693387033871338723387333874338753387633877338783387933880338813388233883338843388533886338873388833889338903389133892338933389433895338963389733898338993390033901339023390333904339053390633907339083390933910339113391233913339143391533916339173391833919339203392133922339233392433925339263392733928339293393033931339323393333934339353393633937339383393933940339413394233943339443394533946339473394833949339503395133952339533395433955339563395733958339593396033961339623396333964339653396633967339683396933970339713397233973339743397533976339773397833979339803398133982339833398433985339863398733988339893399033991339923399333994339953399633997339983399934000340013400234003340043400534006340073400834009340103401134012340133401434015340163401734018340193402034021340223402334024340253402634027340283402934030340313403234033340343403534036340373403834039340403404134042340433404434045340463404734048340493405034051340523405334054340553405634057340583405934060340613406234063340643406534066340673406834069340703407134072340733407434075340763407734078340793408034081340823408334084340853408634087340883408934090340913409234093340943409534096340973409834099341003410134102341033410434105341063410734108341093411034111341123411334114341153411634117341183411934120341213412234123341243412534126341273412834129341303413134132341333413434135341363413734138341393414034141341423414334144341453414634147341483414934150341513415234153341543415534156341573415834159341603416134162341633416434165341663416734168341693417034171341723417334174341753417634177341783417934180341813418234183341843418534186341873418834189341903419134192341933419434195341963419734198341993420034201342023420334204342053420634207342083420934210342113421234213342143421534216342173421834219342203422134222342233422434225342263422734228342293423034231342323423334234342353423634237342383423934240342413424234243342443424534246342473424834249342503425134252342533425434255342563425734258342593426034261342623426334264342653426634267342683426934270342713427234273342743427534276342773427834279342803428134282342833428434285342863428734288342893429034291342923429334294342953429634297342983429934300343013430234303343043430534306343073430834309343103431134312343133431434315343163431734318343193432034321343223432334324343253432634327343283432934330343313433234333343343433534336343373433834339343403434134342343433434434345343463434734348343493435034351343523435334354343553435634357343583435934360343613436234363343643436534366343673436834369343703437134372343733437434375343763437734378343793438034381343823438334384343853438634387343883438934390343913439234393343943439534396343973439834399344003440134402344033440434405344063440734408344093441034411344123441334414344153441634417344183441934420344213442234423344243442534426344273442834429344303443134432344333443434435344363443734438344393444034441344423444334444344453444634447344483444934450344513445234453344543445534456344573445834459344603446134462344633446434465344663446734468344693447034471344723447334474344753447634477344783447934480344813448234483344843448534486344873448834489344903449134492344933449434495344963449734498344993450034501345023450334504345053450634507345083450934510345113451234513345143451534516345173451834519345203452134522345233452434525345263452734528345293453034531345323453334534345353453634537345383453934540345413454234543345443454534546345473454834549345503455134552345533455434555345563455734558345593456034561345623456334564345653456634567345683456934570345713457234573345743457534576345773457834579345803458134582345833458434585345863458734588345893459034591345923459334594345953459634597345983459934600346013460234603346043460534606346073460834609346103461134612346133461434615346163461734618346193462034621346223462334624346253462634627346283462934630346313463234633346343463534636346373463834639346403464134642346433464434645346463464734648346493465034651346523465334654346553465634657346583465934660346613466234663346643466534666346673466834669346703467134672346733467434675346763467734678346793468034681346823468334684346853468634687346883468934690346913469234693346943469534696346973469834699347003470134702347033470434705347063470734708347093471034711347123471334714347153471634717347183471934720347213472234723347243472534726347273472834729347303473134732347333473434735347363473734738347393474034741347423474334744347453474634747347483474934750347513475234753347543475534756347573475834759347603476134762347633476434765347663476734768347693477034771347723477334774347753477634777347783477934780347813478234783347843478534786347873478834789347903479134792347933479434795347963479734798347993480034801348023480334804348053480634807348083480934810348113481234813348143481534816348173481834819348203482134822348233482434825348263482734828348293483034831348323483334834348353483634837348383483934840348413484234843348443484534846348473484834849348503485134852348533485434855348563485734858348593486034861348623486334864348653486634867348683486934870348713487234873348743487534876348773487834879348803488134882348833488434885348863488734888348893489034891348923489334894348953489634897348983489934900349013490234903349043490534906349073490834909349103491134912349133491434915349163491734918349193492034921349223492334924349253492634927349283492934930349313493234933349343493534936349373493834939349403494134942349433494434945349463494734948349493495034951349523495334954349553495634957349583495934960349613496234963349643496534966349673496834969349703497134972349733497434975349763497734978349793498034981349823498334984349853498634987349883498934990349913499234993349943499534996349973499834999350003500135002350033500435005350063500735008350093501035011350123501335014350153501635017350183501935020350213502235023350243502535026350273502835029350303503135032350333503435035350363503735038350393504035041350423504335044350453504635047350483504935050350513505235053350543505535056350573505835059350603506135062350633506435065350663506735068350693507035071350723507335074350753507635077350783507935080350813508235083350843508535086350873508835089350903509135092350933509435095350963509735098350993510035101351023510335104351053510635107351083510935110351113511235113351143511535116351173511835119351203512135122351233512435125351263512735128351293513035131351323513335134351353513635137351383513935140351413514235143351443514535146351473514835149351503515135152351533515435155351563515735158351593516035161351623516335164351653516635167351683516935170351713517235173351743517535176351773517835179351803518135182351833518435185351863518735188351893519035191351923519335194351953519635197351983519935200352013520235203352043520535206352073520835209352103521135212352133521435215352163521735218352193522035221352223522335224352253522635227352283522935230352313523235233352343523535236352373523835239352403524135242352433524435245352463524735248352493525035251352523525335254352553525635257352583525935260352613526235263352643526535266352673526835269352703527135272352733527435275352763527735278352793528035281352823528335284352853528635287352883528935290352913529235293352943529535296352973529835299353003530135302353033530435305353063530735308353093531035311353123531335314353153531635317353183531935320353213532235323353243532535326353273532835329353303533135332353333533435335353363533735338353393534035341353423534335344353453534635347353483534935350353513535235353353543535535356353573535835359353603536135362353633536435365353663536735368353693537035371353723537335374353753537635377353783537935380353813538235383353843538535386353873538835389353903539135392353933539435395353963539735398353993540035401354023540335404354053540635407354083540935410354113541235413354143541535416354173541835419354203542135422354233542435425354263542735428354293543035431354323543335434354353543635437354383543935440354413544235443354443544535446354473544835449354503545135452354533545435455354563545735458354593546035461354623546335464354653546635467354683546935470354713547235473354743547535476354773547835479354803548135482354833548435485354863548735488354893549035491354923549335494354953549635497354983549935500355013550235503355043550535506355073550835509355103551135512355133551435515355163551735518355193552035521355223552335524355253552635527355283552935530355313553235533355343553535536355373553835539355403554135542355433554435545355463554735548355493555035551355523555335554355553555635557355583555935560355613556235563355643556535566355673556835569355703557135572355733557435575355763557735578355793558035581355823558335584355853558635587355883558935590355913559235593355943559535596355973559835599356003560135602356033560435605356063560735608356093561035611356123561335614356153561635617356183561935620356213562235623356243562535626356273562835629356303563135632356333563435635356363563735638356393564035641356423564335644356453564635647356483564935650356513565235653356543565535656356573565835659356603566135662356633566435665356663566735668356693567035671356723567335674356753567635677356783567935680356813568235683356843568535686356873568835689356903569135692356933569435695356963569735698356993570035701357023570335704357053570635707357083570935710357113571235713357143571535716357173571835719357203572135722357233572435725357263572735728357293573035731357323573335734357353573635737357383573935740357413574235743357443574535746357473574835749357503575135752357533575435755357563575735758357593576035761357623576335764357653576635767357683576935770357713577235773357743577535776357773577835779357803578135782357833578435785357863578735788357893579035791357923579335794357953579635797357983579935800358013580235803358043580535806358073580835809358103581135812358133581435815358163581735818358193582035821358223582335824358253582635827358283582935830358313583235833358343583535836358373583835839358403584135842358433584435845358463584735848358493585035851358523585335854358553585635857358583585935860358613586235863358643586535866358673586835869358703587135872358733587435875358763587735878358793588035881358823588335884358853588635887358883588935890358913589235893358943589535896358973589835899359003590135902359033590435905359063590735908359093591035911359123591335914359153591635917359183591935920359213592235923359243592535926359273592835929359303593135932359333593435935359363593735938359393594035941359423594335944359453594635947359483594935950359513595235953359543595535956359573595835959359603596135962359633596435965359663596735968359693597035971359723597335974359753597635977359783597935980359813598235983359843598535986359873598835989359903599135992359933599435995359963599735998359993600036001360023600336004360053600636007360083600936010360113601236013360143601536016360173601836019360203602136022360233602436025360263602736028360293603036031360323603336034360353603636037360383603936040360413604236043360443604536046360473604836049360503605136052360533605436055360563605736058360593606036061360623606336064360653606636067360683606936070360713607236073360743607536076360773607836079360803608136082360833608436085360863608736088360893609036091360923609336094360953609636097360983609936100361013610236103361043610536106361073610836109361103611136112361133611436115361163611736118361193612036121361223612336124361253612636127361283612936130361313613236133361343613536136361373613836139361403614136142361433614436145361463614736148361493615036151361523615336154361553615636157361583615936160361613616236163361643616536166361673616836169361703617136172361733617436175361763617736178361793618036181361823618336184361853618636187361883618936190361913619236193361943619536196361973619836199362003620136202362033620436205362063620736208362093621036211362123621336214362153621636217362183621936220362213622236223362243622536226362273622836229362303623136232362333623436235362363623736238362393624036241362423624336244362453624636247362483624936250362513625236253362543625536256362573625836259362603626136262362633626436265362663626736268362693627036271362723627336274362753627636277362783627936280362813628236283362843628536286362873628836289362903629136292362933629436295362963629736298362993630036301363023630336304363053630636307363083630936310363113631236313363143631536316363173631836319363203632136322363233632436325363263632736328363293633036331363323633336334363353633636337363383633936340363413634236343363443634536346363473634836349363503635136352363533635436355363563635736358363593636036361363623636336364363653636636367363683636936370363713637236373363743637536376363773637836379363803638136382363833638436385363863638736388363893639036391363923639336394363953639636397363983639936400364013640236403364043640536406364073640836409364103641136412364133641436415364163641736418364193642036421364223642336424364253642636427364283642936430364313643236433364343643536436364373643836439364403644136442364433644436445364463644736448364493645036451364523645336454364553645636457364583645936460364613646236463364643646536466364673646836469364703647136472364733647436475364763647736478364793648036481364823648336484364853648636487364883648936490364913649236493364943649536496364973649836499365003650136502365033650436505365063650736508365093651036511365123651336514365153651636517365183651936520365213652236523365243652536526365273652836529365303653136532365333653436535365363653736538365393654036541365423654336544365453654636547365483654936550365513655236553365543655536556365573655836559365603656136562365633656436565365663656736568365693657036571365723657336574365753657636577365783657936580365813658236583365843658536586365873658836589365903659136592365933659436595365963659736598365993660036601366023660336604366053660636607366083660936610366113661236613366143661536616366173661836619366203662136622366233662436625366263662736628366293663036631366323663336634366353663636637366383663936640366413664236643366443664536646366473664836649366503665136652366533665436655366563665736658366593666036661366623666336664366653666636667366683666936670366713667236673366743667536676366773667836679366803668136682366833668436685366863668736688366893669036691366923669336694366953669636697366983669936700367013670236703367043670536706367073670836709367103671136712367133671436715367163671736718367193672036721367223672336724367253672636727367283672936730367313673236733367343673536736367373673836739367403674136742367433674436745367463674736748367493675036751367523675336754367553675636757367583675936760367613676236763367643676536766367673676836769367703677136772367733677436775367763677736778367793678036781367823678336784367853678636787367883678936790367913679236793367943679536796367973679836799368003680136802368033680436805368063680736808368093681036811368123681336814368153681636817368183681936820368213682236823368243682536826368273682836829368303683136832368333683436835368363683736838368393684036841368423684336844368453684636847368483684936850368513685236853368543685536856368573685836859368603686136862368633686436865368663686736868368693687036871368723687336874368753687636877368783687936880368813688236883368843688536886368873688836889368903689136892368933689436895368963689736898368993690036901369023690336904369053690636907369083690936910369113691236913369143691536916369173691836919369203692136922369233692436925369263692736928369293693036931369323693336934369353693636937369383693936940369413694236943369443694536946369473694836949369503695136952369533695436955369563695736958369593696036961369623696336964369653696636967369683696936970369713697236973369743697536976369773697836979369803698136982369833698436985369863698736988369893699036991369923699336994369953699636997369983699937000370013700237003370043700537006370073700837009370103701137012370133701437015370163701737018370193702037021370223702337024370253702637027370283702937030370313703237033370343703537036370373703837039370403704137042370433704437045370463704737048370493705037051370523705337054370553705637057370583705937060370613706237063370643706537066370673706837069370703707137072370733707437075370763707737078370793708037081370823708337084370853708637087370883708937090370913709237093370943709537096370973709837099371003710137102371033710437105371063710737108371093711037111371123711337114371153711637117371183711937120371213712237123371243712537126371273712837129371303713137132371333713437135371363713737138371393714037141371423714337144371453714637147371483714937150371513715237153371543715537156371573715837159371603716137162371633716437165371663716737168371693717037171371723717337174371753717637177371783717937180371813718237183371843718537186371873718837189371903719137192371933719437195371963719737198371993720037201372023720337204372053720637207372083720937210372113721237213372143721537216372173721837219372203722137222372233722437225372263722737228372293723037231372323723337234372353723637237372383723937240372413724237243372443724537246372473724837249372503725137252372533725437255372563725737258372593726037261372623726337264372653726637267372683726937270372713727237273372743727537276372773727837279372803728137282372833728437285372863728737288372893729037291372923729337294372953729637297372983729937300373013730237303373043730537306373073730837309373103731137312373133731437315373163731737318373193732037321373223732337324373253732637327373283732937330373313733237333373343733537336373373733837339373403734137342373433734437345373463734737348373493735037351373523735337354373553735637357373583735937360373613736237363373643736537366373673736837369373703737137372373733737437375373763737737378373793738037381373823738337384373853738637387373883738937390373913739237393373943739537396373973739837399374003740137402374033740437405374063740737408374093741037411374123741337414374153741637417374183741937420374213742237423374243742537426374273742837429374303743137432374333743437435374363743737438374393744037441374423744337444374453744637447374483744937450374513745237453374543745537456374573745837459374603746137462374633746437465374663746737468374693747037471374723747337474374753747637477374783747937480374813748237483374843748537486374873748837489374903749137492374933749437495374963749737498374993750037501375023750337504375053750637507375083750937510375113751237513375143751537516375173751837519375203752137522375233752437525375263752737528375293753037531375323753337534375353753637537375383753937540375413754237543375443754537546375473754837549375503755137552375533755437555375563755737558375593756037561375623756337564375653756637567375683756937570375713757237573375743757537576375773757837579375803758137582375833758437585375863758737588375893759037591375923759337594375953759637597375983759937600376013760237603376043760537606376073760837609376103761137612376133761437615376163761737618376193762037621376223762337624376253762637627376283762937630376313763237633376343763537636376373763837639376403764137642376433764437645376463764737648376493765037651376523765337654376553765637657376583765937660376613766237663376643766537666376673766837669376703767137672376733767437675376763767737678376793768037681376823768337684376853768637687376883768937690376913769237693376943769537696376973769837699377003770137702377033770437705377063770737708377093771037711377123771337714377153771637717377183771937720377213772237723377243772537726377273772837729377303773137732377333773437735377363773737738377393774037741377423774337744377453774637747377483774937750377513775237753377543775537756377573775837759377603776137762377633776437765377663776737768377693777037771377723777337774377753777637777377783777937780377813778237783377843778537786377873778837789377903779137792377933779437795377963779737798377993780037801378023780337804378053780637807378083780937810378113781237813378143781537816378173781837819378203782137822378233782437825378263782737828378293783037831378323783337834378353783637837378383783937840378413784237843378443784537846378473784837849378503785137852378533785437855378563785737858378593786037861378623786337864378653786637867378683786937870378713787237873378743787537876378773787837879378803788137882378833788437885378863788737888378893789037891378923789337894378953789637897378983789937900379013790237903379043790537906379073790837909379103791137912379133791437915379163791737918379193792037921379223792337924379253792637927379283792937930379313793237933379343793537936379373793837939379403794137942379433794437945379463794737948379493795037951379523795337954379553795637957379583795937960379613796237963379643796537966379673796837969379703797137972379733797437975379763797737978379793798037981379823798337984379853798637987379883798937990379913799237993379943799537996379973799837999380003800138002380033800438005380063800738008380093801038011380123801338014380153801638017380183801938020380213802238023380243802538026380273802838029380303803138032380333803438035380363803738038380393804038041380423804338044380453804638047380483804938050380513805238053380543805538056380573805838059380603806138062380633806438065380663806738068380693807038071380723807338074380753807638077380783807938080380813808238083380843808538086380873808838089380903809138092380933809438095380963809738098380993810038101381023810338104381053810638107381083810938110381113811238113381143811538116381173811838119381203812138122381233812438125381263812738128381293813038131381323813338134381353813638137381383813938140381413814238143381443814538146381473814838149381503815138152381533815438155381563815738158381593816038161381623816338164381653816638167381683816938170381713817238173381743817538176381773817838179381803818138182381833818438185381863818738188381893819038191381923819338194381953819638197381983819938200382013820238203382043820538206382073820838209382103821138212382133821438215382163821738218382193822038221382223822338224382253822638227382283822938230382313823238233382343823538236382373823838239382403824138242382433824438245382463824738248382493825038251382523825338254382553825638257382583825938260382613826238263382643826538266382673826838269382703827138272382733827438275382763827738278382793828038281382823828338284382853828638287382883828938290382913829238293382943829538296382973829838299383003830138302383033830438305383063830738308383093831038311383123831338314383153831638317383183831938320383213832238323383243832538326383273832838329383303833138332383333833438335383363833738338383393834038341383423834338344383453834638347383483834938350383513835238353383543835538356383573835838359383603836138362383633836438365383663836738368383693837038371383723837338374383753837638377383783837938380383813838238383383843838538386383873838838389383903839138392383933839438395383963839738398383993840038401384023840338404384053840638407384083840938410384113841238413384143841538416384173841838419384203842138422384233842438425384263842738428384293843038431384323843338434384353843638437384383843938440384413844238443384443844538446384473844838449384503845138452384533845438455384563845738458384593846038461384623846338464384653846638467384683846938470384713847238473384743847538476384773847838479384803848138482384833848438485384863848738488384893849038491384923849338494384953849638497384983849938500385013850238503385043850538506385073850838509385103851138512385133851438515385163851738518385193852038521385223852338524385253852638527385283852938530385313853238533385343853538536385373853838539385403854138542385433854438545385463854738548385493855038551385523855338554385553855638557385583855938560385613856238563385643856538566385673856838569385703857138572385733857438575385763857738578385793858038581385823858338584385853858638587385883858938590385913859238593385943859538596385973859838599386003860138602386033860438605386063860738608386093861038611386123861338614386153861638617386183861938620386213862238623386243862538626386273862838629386303863138632386333863438635386363863738638386393864038641386423864338644386453864638647386483864938650386513865238653386543865538656386573865838659386603866138662386633866438665386663866738668386693867038671386723867338674386753867638677386783867938680386813868238683386843868538686386873868838689386903869138692386933869438695386963869738698386993870038701387023870338704387053870638707387083870938710387113871238713387143871538716387173871838719387203872138722387233872438725387263872738728387293873038731387323873338734387353873638737387383873938740387413874238743387443874538746387473874838749387503875138752387533875438755387563875738758387593876038761387623876338764387653876638767387683876938770387713877238773387743877538776387773877838779387803878138782387833878438785387863878738788387893879038791387923879338794387953879638797387983879938800388013880238803388043880538806388073880838809388103881138812388133881438815388163881738818388193882038821388223882338824388253882638827388283882938830388313883238833388343883538836388373883838839388403884138842388433884438845388463884738848388493885038851388523885338854388553885638857388583885938860388613886238863388643886538866388673886838869388703887138872388733887438875388763887738878388793888038881388823888338884388853888638887388883888938890388913889238893388943889538896388973889838899389003890138902389033890438905389063890738908389093891038911389123891338914389153891638917389183891938920389213892238923389243892538926389273892838929389303893138932389333893438935389363893738938389393894038941389423894338944389453894638947389483894938950389513895238953389543895538956389573895838959389603896138962389633896438965389663896738968389693897038971389723897338974389753897638977389783897938980389813898238983389843898538986389873898838989389903899138992389933899438995389963899738998389993900039001390023900339004390053900639007390083900939010390113901239013390143901539016390173901839019390203902139022390233902439025390263902739028390293903039031390323903339034390353903639037390383903939040390413904239043390443904539046390473904839049390503905139052390533905439055390563905739058390593906039061390623906339064390653906639067390683906939070390713907239073390743907539076390773907839079390803908139082390833908439085390863908739088390893909039091390923909339094390953909639097390983909939100391013910239103391043910539106391073910839109391103911139112391133911439115391163911739118391193912039121391223912339124391253912639127391283912939130391313913239133391343913539136391373913839139391403914139142391433914439145391463914739148391493915039151391523915339154391553915639157391583915939160391613916239163391643916539166391673916839169391703917139172391733917439175391763917739178391793918039181391823918339184391853918639187391883918939190391913919239193391943919539196391973919839199392003920139202392033920439205392063920739208392093921039211392123921339214392153921639217392183921939220392213922239223392243922539226392273922839229392303923139232392333923439235392363923739238392393924039241392423924339244392453924639247392483924939250392513925239253392543925539256392573925839259392603926139262392633926439265392663926739268392693927039271392723927339274392753927639277392783927939280392813928239283392843928539286392873928839289392903929139292392933929439295392963929739298392993930039301393023930339304393053930639307393083930939310393113931239313393143931539316393173931839319393203932139322393233932439325393263932739328393293933039331393323933339334393353933639337393383933939340393413934239343393443934539346393473934839349393503935139352393533935439355393563935739358393593936039361393623936339364393653936639367393683936939370393713937239373393743937539376393773937839379393803938139382393833938439385393863938739388393893939039391393923939339394393953939639397393983939939400394013940239403394043940539406394073940839409394103941139412394133941439415394163941739418394193942039421394223942339424394253942639427394283942939430394313943239433394343943539436394373943839439394403944139442394433944439445394463944739448394493945039451394523945339454394553945639457394583945939460394613946239463394643946539466394673946839469394703947139472394733947439475394763947739478394793948039481394823948339484394853948639487394883948939490394913949239493394943949539496394973949839499395003950139502395033950439505395063950739508395093951039511395123951339514395153951639517395183951939520395213952239523395243952539526395273952839529395303953139532395333953439535395363953739538395393954039541395423954339544395453954639547395483954939550395513955239553395543955539556395573955839559395603956139562395633956439565395663956739568395693957039571395723957339574395753957639577395783957939580395813958239583395843958539586395873958839589395903959139592395933959439595395963959739598395993960039601396023960339604396053960639607396083960939610396113961239613396143961539616396173961839619396203962139622396233962439625396263962739628396293963039631396323963339634396353963639637396383963939640396413964239643396443964539646396473964839649396503965139652396533965439655396563965739658396593966039661396623966339664396653966639667396683966939670396713967239673396743967539676396773967839679396803968139682396833968439685396863968739688396893969039691396923969339694396953969639697396983969939700397013970239703397043970539706397073970839709397103971139712397133971439715397163971739718397193972039721397223972339724397253972639727397283972939730397313973239733397343973539736397373973839739397403974139742397433974439745397463974739748397493975039751397523975339754397553975639757397583975939760397613976239763397643976539766397673976839769397703977139772397733977439775397763977739778397793978039781397823978339784397853978639787397883978939790397913979239793397943979539796397973979839799398003980139802398033980439805398063980739808398093981039811398123981339814398153981639817398183981939820398213982239823398243982539826398273982839829398303983139832398333983439835398363983739838398393984039841398423984339844398453984639847398483984939850398513985239853398543985539856398573985839859398603986139862398633986439865398663986739868398693987039871398723987339874398753987639877398783987939880398813988239883398843988539886398873988839889398903989139892398933989439895398963989739898398993990039901399023990339904399053990639907399083990939910399113991239913399143991539916399173991839919399203992139922399233992439925399263992739928399293993039931399323993339934399353993639937399383993939940399413994239943399443994539946399473994839949399503995139952399533995439955399563995739958399593996039961399623996339964399653996639967399683996939970399713997239973399743997539976399773997839979399803998139982399833998439985399863998739988399893999039991399923999339994399953999639997399983999940000400014000240003400044000540006400074000840009400104001140012400134001440015400164001740018400194002040021400224002340024400254002640027400284002940030400314003240033400344003540036400374003840039400404004140042400434004440045400464004740048400494005040051400524005340054400554005640057400584005940060400614006240063400644006540066400674006840069400704007140072400734007440075400764007740078400794008040081400824008340084400854008640087400884008940090400914009240093400944009540096400974009840099401004010140102401034010440105401064010740108401094011040111401124011340114401154011640117401184011940120401214012240123401244012540126401274012840129401304013140132401334013440135401364013740138401394014040141401424014340144401454014640147401484014940150401514015240153401544015540156401574015840159401604016140162401634016440165401664016740168401694017040171401724017340174401754017640177401784017940180401814018240183401844018540186401874018840189401904019140192401934019440195401964019740198401994020040201402024020340204402054020640207402084020940210402114021240213402144021540216402174021840219402204022140222402234022440225402264022740228402294023040231402324023340234402354023640237402384023940240402414024240243402444024540246402474024840249402504025140252402534025440255402564025740258402594026040261402624026340264402654026640267402684026940270402714027240273402744027540276402774027840279402804028140282402834028440285402864028740288402894029040291402924029340294402954029640297402984029940300403014030240303403044030540306403074030840309403104031140312403134031440315403164031740318403194032040321403224032340324403254032640327403284032940330403314033240333403344033540336403374033840339403404034140342403434034440345403464034740348403494035040351403524035340354403554035640357403584035940360403614036240363403644036540366403674036840369403704037140372403734037440375403764037740378403794038040381403824038340384403854038640387403884038940390403914039240393403944039540396403974039840399404004040140402404034040440405404064040740408404094041040411404124041340414404154041640417404184041940420404214042240423404244042540426404274042840429404304043140432404334043440435404364043740438404394044040441404424044340444404454044640447404484044940450404514045240453404544045540456404574045840459404604046140462404634046440465404664046740468404694047040471404724047340474404754047640477404784047940480404814048240483404844048540486404874048840489404904049140492404934049440495404964049740498404994050040501405024050340504405054050640507405084050940510405114051240513405144051540516405174051840519405204052140522405234052440525405264052740528405294053040531405324053340534405354053640537405384053940540405414054240543405444054540546405474054840549405504055140552405534055440555405564055740558405594056040561405624056340564405654056640567405684056940570405714057240573405744057540576405774057840579405804058140582405834058440585405864058740588405894059040591405924059340594405954059640597405984059940600406014060240603406044060540606406074060840609406104061140612406134061440615406164061740618406194062040621406224062340624406254062640627406284062940630406314063240633406344063540636406374063840639406404064140642406434064440645406464064740648406494065040651406524065340654406554065640657406584065940660406614066240663406644066540666406674066840669406704067140672406734067440675406764067740678406794068040681406824068340684406854068640687406884068940690406914069240693406944069540696406974069840699407004070140702407034070440705407064070740708407094071040711407124071340714407154071640717407184071940720407214072240723407244072540726407274072840729407304073140732407334073440735407364073740738407394074040741407424074340744407454074640747407484074940750407514075240753407544075540756407574075840759407604076140762407634076440765407664076740768407694077040771407724077340774407754077640777407784077940780407814078240783407844078540786407874078840789407904079140792407934079440795407964079740798407994080040801408024080340804408054080640807408084080940810408114081240813408144081540816408174081840819408204082140822408234082440825408264082740828408294083040831408324083340834408354083640837408384083940840408414084240843408444084540846408474084840849408504085140852408534085440855408564085740858408594086040861408624086340864408654086640867408684086940870408714087240873408744087540876408774087840879408804088140882408834088440885408864088740888408894089040891408924089340894408954089640897408984089940900409014090240903409044090540906409074090840909409104091140912409134091440915409164091740918409194092040921409224092340924409254092640927409284092940930409314093240933409344093540936409374093840939409404094140942409434094440945409464094740948409494095040951409524095340954409554095640957409584095940960409614096240963409644096540966409674096840969409704097140972409734097440975409764097740978409794098040981409824098340984409854098640987409884098940990409914099240993409944099540996409974099840999410004100141002410034100441005410064100741008410094101041011410124101341014410154101641017410184101941020410214102241023410244102541026410274102841029410304103141032410334103441035410364103741038410394104041041410424104341044410454104641047410484104941050410514105241053410544105541056410574105841059410604106141062410634106441065410664106741068410694107041071410724107341074410754107641077410784107941080410814108241083410844108541086410874108841089410904109141092410934109441095410964109741098410994110041101411024110341104411054110641107411084110941110411114111241113411144111541116411174111841119411204112141122411234112441125411264112741128411294113041131411324113341134411354113641137411384113941140411414114241143411444114541146411474114841149411504115141152411534115441155411564115741158411594116041161411624116341164411654116641167411684116941170411714117241173411744117541176411774117841179411804118141182411834118441185411864118741188411894119041191411924119341194411954119641197411984119941200412014120241203412044120541206412074120841209412104121141212412134121441215412164121741218412194122041221412224122341224412254122641227412284122941230412314123241233412344123541236412374123841239412404124141242412434124441245412464124741248412494125041251412524125341254412554125641257412584125941260412614126241263412644126541266412674126841269412704127141272412734127441275412764127741278412794128041281412824128341284412854128641287412884128941290412914129241293412944129541296412974129841299413004130141302413034130441305413064130741308413094131041311413124131341314413154131641317413184131941320413214132241323413244132541326413274132841329413304133141332413334133441335413364133741338413394134041341413424134341344413454134641347413484134941350413514135241353413544135541356413574135841359413604136141362413634136441365413664136741368413694137041371413724137341374413754137641377413784137941380413814138241383413844138541386413874138841389413904139141392413934139441395413964139741398413994140041401414024140341404414054140641407414084140941410414114141241413414144141541416414174141841419414204142141422414234142441425414264142741428414294143041431414324143341434414354143641437414384143941440414414144241443414444144541446414474144841449414504145141452414534145441455414564145741458414594146041461414624146341464414654146641467414684146941470414714147241473414744147541476414774147841479414804148141482414834148441485414864148741488414894149041491414924149341494414954149641497414984149941500415014150241503415044150541506415074150841509415104151141512415134151441515415164151741518415194152041521415224152341524415254152641527415284152941530415314153241533415344153541536415374153841539415404154141542415434154441545415464154741548415494155041551415524155341554415554155641557415584155941560415614156241563415644156541566415674156841569415704157141572415734157441575415764157741578415794158041581415824158341584415854158641587415884158941590415914159241593415944159541596415974159841599416004160141602416034160441605416064160741608416094161041611416124161341614416154161641617416184161941620416214162241623416244162541626416274162841629416304163141632416334163441635416364163741638416394164041641416424164341644416454164641647416484164941650416514165241653416544165541656416574165841659416604166141662416634166441665416664166741668416694167041671416724167341674416754167641677416784167941680416814168241683416844168541686416874168841689416904169141692416934169441695416964169741698416994170041701417024170341704417054170641707417084170941710417114171241713417144171541716417174171841719417204172141722417234172441725417264172741728417294173041731417324173341734417354173641737417384173941740417414174241743417444174541746417474174841749417504175141752417534175441755417564175741758417594176041761417624176341764417654176641767417684176941770417714177241773417744177541776417774177841779417804178141782417834178441785417864178741788417894179041791417924179341794417954179641797417984179941800418014180241803418044180541806418074180841809418104181141812418134181441815418164181741818418194182041821418224182341824418254182641827418284182941830418314183241833418344183541836418374183841839418404184141842418434184441845418464184741848418494185041851418524185341854418554185641857418584185941860418614186241863418644186541866418674186841869418704187141872418734187441875418764187741878418794188041881418824188341884418854188641887418884188941890418914189241893418944189541896418974189841899419004190141902419034190441905419064190741908419094191041911419124191341914419154191641917419184191941920419214192241923419244192541926419274192841929419304193141932419334193441935419364193741938419394194041941419424194341944419454194641947419484194941950419514195241953419544195541956419574195841959419604196141962419634196441965419664196741968419694197041971419724197341974419754197641977419784197941980419814198241983419844198541986419874198841989419904199141992419934199441995419964199741998419994200042001420024200342004420054200642007420084200942010420114201242013420144201542016420174201842019420204202142022420234202442025420264202742028420294203042031420324203342034420354203642037420384203942040420414204242043420444204542046420474204842049420504205142052420534205442055420564205742058420594206042061420624206342064420654206642067420684206942070420714207242073420744207542076420774207842079420804208142082420834208442085420864208742088420894209042091420924209342094420954209642097420984209942100421014210242103421044210542106421074210842109421104211142112421134211442115421164211742118421194212042121421224212342124421254212642127421284212942130421314213242133421344213542136421374213842139421404214142142421434214442145421464214742148421494215042151421524215342154421554215642157421584215942160421614216242163421644216542166421674216842169421704217142172421734217442175421764217742178421794218042181421824218342184421854218642187421884218942190421914219242193421944219542196421974219842199422004220142202422034220442205422064220742208422094221042211422124221342214422154221642217422184221942220422214222242223422244222542226422274222842229422304223142232422334223442235422364223742238422394224042241422424224342244422454224642247422484224942250422514225242253422544225542256422574225842259422604226142262422634226442265422664226742268422694227042271422724227342274422754227642277422784227942280422814228242283422844228542286422874228842289422904229142292422934229442295422964229742298422994230042301423024230342304423054230642307423084230942310423114231242313423144231542316423174231842319423204232142322423234232442325423264232742328423294233042331423324233342334423354233642337423384233942340423414234242343423444234542346423474234842349423504235142352423534235442355423564235742358423594236042361423624236342364423654236642367423684236942370423714237242373423744237542376423774237842379423804238142382423834238442385423864238742388423894239042391423924239342394423954239642397423984239942400424014240242403424044240542406424074240842409424104241142412424134241442415424164241742418424194242042421424224242342424424254242642427424284242942430424314243242433424344243542436424374243842439424404244142442424434244442445424464244742448424494245042451424524245342454424554245642457424584245942460424614246242463424644246542466424674246842469424704247142472424734247442475424764247742478424794248042481424824248342484424854248642487424884248942490424914249242493424944249542496424974249842499425004250142502425034250442505425064250742508425094251042511425124251342514425154251642517425184251942520425214252242523425244252542526425274252842529425304253142532425334253442535425364253742538425394254042541425424254342544425454254642547425484254942550425514255242553425544255542556425574255842559425604256142562425634256442565425664256742568425694257042571425724257342574425754257642577425784257942580425814258242583425844258542586425874258842589425904259142592425934259442595425964259742598425994260042601426024260342604426054260642607426084260942610426114261242613426144261542616426174261842619426204262142622426234262442625426264262742628426294263042631426324263342634426354263642637426384263942640426414264242643426444264542646426474264842649426504265142652426534265442655426564265742658426594266042661426624266342664426654266642667426684266942670426714267242673426744267542676426774267842679426804268142682426834268442685426864268742688426894269042691426924269342694426954269642697426984269942700427014270242703427044270542706427074270842709427104271142712427134271442715427164271742718427194272042721427224272342724427254272642727427284272942730427314273242733427344273542736427374273842739427404274142742427434274442745427464274742748427494275042751427524275342754427554275642757427584275942760427614276242763427644276542766427674276842769427704277142772427734277442775427764277742778427794278042781427824278342784427854278642787427884278942790427914279242793427944279542796427974279842799428004280142802428034280442805428064280742808428094281042811428124281342814428154281642817428184281942820428214282242823428244282542826428274282842829428304283142832428334283442835428364283742838428394284042841428424284342844428454284642847428484284942850428514285242853428544285542856428574285842859428604286142862428634286442865428664286742868428694287042871428724287342874428754287642877428784287942880428814288242883428844288542886428874288842889428904289142892428934289442895428964289742898428994290042901429024290342904429054290642907429084290942910429114291242913429144291542916429174291842919429204292142922429234292442925429264292742928429294293042931429324293342934429354293642937429384293942940429414294242943429444294542946429474294842949429504295142952429534295442955429564295742958429594296042961429624296342964429654296642967429684296942970429714297242973429744297542976429774297842979429804298142982429834298442985429864298742988429894299042991429924299342994429954299642997429984299943000430014300243003430044300543006430074300843009430104301143012430134301443015430164301743018430194302043021430224302343024430254302643027430284302943030430314303243033430344303543036430374303843039430404304143042430434304443045430464304743048430494305043051430524305343054430554305643057430584305943060430614306243063430644306543066430674306843069430704307143072430734307443075430764307743078430794308043081430824308343084430854308643087430884308943090430914309243093430944309543096430974309843099431004310143102431034310443105431064310743108431094311043111431124311343114431154311643117431184311943120431214312243123431244312543126431274312843129431304313143132431334313443135431364313743138431394314043141431424314343144431454314643147431484314943150431514315243153431544315543156431574315843159431604316143162431634316443165431664316743168431694317043171431724317343174431754317643177431784317943180431814318243183431844318543186431874318843189431904319143192431934319443195431964319743198431994320043201432024320343204432054320643207432084320943210432114321243213432144321543216432174321843219432204322143222432234322443225432264322743228432294323043231432324323343234432354323643237432384323943240432414324243243432444324543246432474324843249432504325143252432534325443255432564325743258432594326043261432624326343264432654326643267432684326943270432714327243273432744327543276432774327843279432804328143282432834328443285432864328743288432894329043291432924329343294432954329643297432984329943300433014330243303433044330543306433074330843309433104331143312433134331443315433164331743318433194332043321433224332343324433254332643327433284332943330433314333243333433344333543336433374333843339433404334143342433434334443345433464334743348433494335043351433524335343354433554335643357433584335943360433614336243363433644336543366433674336843369433704337143372433734337443375433764337743378433794338043381433824338343384433854338643387433884338943390433914339243393433944339543396433974339843399434004340143402434034340443405434064340743408434094341043411434124341343414434154341643417434184341943420434214342243423434244342543426434274342843429434304343143432434334343443435434364343743438434394344043441434424344343444434454344643447434484344943450434514345243453434544345543456434574345843459434604346143462434634346443465434664346743468434694347043471434724347343474434754347643477434784347943480434814348243483434844348543486434874348843489434904349143492434934349443495434964349743498434994350043501435024350343504435054350643507435084350943510435114351243513435144351543516435174351843519435204352143522435234352443525435264352743528435294353043531435324353343534435354353643537435384353943540435414354243543435444354543546435474354843549435504355143552435534355443555435564355743558435594356043561435624356343564435654356643567435684356943570435714357243573435744357543576435774357843579435804358143582435834358443585435864358743588435894359043591435924359343594435954359643597435984359943600436014360243603436044360543606436074360843609436104361143612436134361443615436164361743618436194362043621436224362343624436254362643627436284362943630436314363243633436344363543636436374363843639436404364143642436434364443645436464364743648436494365043651436524365343654436554365643657436584365943660436614366243663436644366543666436674366843669436704367143672436734367443675436764367743678436794368043681436824368343684436854368643687436884368943690436914369243693436944369543696436974369843699437004370143702437034370443705437064370743708437094371043711437124371343714437154371643717437184371943720437214372243723437244372543726437274372843729437304373143732437334373443735437364373743738437394374043741437424374343744437454374643747437484374943750437514375243753437544375543756437574375843759437604376143762437634376443765437664376743768437694377043771437724377343774437754377643777437784377943780437814378243783437844378543786437874378843789437904379143792437934379443795437964379743798437994380043801438024380343804438054380643807438084380943810438114381243813438144381543816438174381843819438204382143822438234382443825438264382743828438294383043831438324383343834438354383643837438384383943840438414384243843438444384543846438474384843849438504385143852438534385443855438564385743858438594386043861438624386343864438654386643867438684386943870438714387243873438744387543876438774387843879438804388143882438834388443885438864388743888438894389043891438924389343894438954389643897438984389943900439014390243903439044390543906439074390843909439104391143912439134391443915439164391743918439194392043921439224392343924439254392643927439284392943930439314393243933439344393543936439374393843939439404394143942439434394443945439464394743948439494395043951439524395343954439554395643957439584395943960439614396243963439644396543966439674396843969439704397143972439734397443975439764397743978439794398043981439824398343984439854398643987439884398943990439914399243993439944399543996439974399843999440004400144002440034400444005440064400744008440094401044011440124401344014440154401644017440184401944020440214402244023440244402544026440274402844029440304403144032440334403444035440364403744038440394404044041440424404344044440454404644047440484404944050440514405244053440544405544056440574405844059440604406144062440634406444065440664406744068440694407044071440724407344074440754407644077440784407944080440814408244083440844408544086440874408844089440904409144092440934409444095440964409744098440994410044101441024410344104441054410644107441084410944110441114411244113441144411544116441174411844119441204412144122441234412444125441264412744128441294413044131441324413344134441354413644137441384413944140441414414244143441444414544146441474414844149441504415144152441534415444155441564415744158441594416044161441624416344164441654416644167441684416944170441714417244173441744417544176441774417844179441804418144182441834418444185441864418744188441894419044191441924419344194441954419644197441984419944200442014420244203442044420544206442074420844209442104421144212442134421444215442164421744218442194422044221442224422344224442254422644227442284422944230442314423244233442344423544236442374423844239442404424144242442434424444245442464424744248442494425044251442524425344254442554425644257442584425944260442614426244263442644426544266442674426844269442704427144272442734427444275442764427744278442794428044281442824428344284442854428644287442884428944290442914429244293442944429544296442974429844299443004430144302443034430444305443064430744308443094431044311443124431344314443154431644317443184431944320443214432244323443244432544326443274432844329443304433144332443334433444335443364433744338443394434044341443424434344344443454434644347443484434944350443514435244353443544435544356443574435844359443604436144362443634436444365443664436744368443694437044371443724437344374443754437644377443784437944380443814438244383443844438544386443874438844389443904439144392443934439444395443964439744398443994440044401444024440344404444054440644407444084440944410444114441244413444144441544416444174441844419444204442144422444234442444425444264442744428444294443044431444324443344434444354443644437444384443944440444414444244443444444444544446444474444844449444504445144452444534445444455444564445744458444594446044461444624446344464444654446644467444684446944470444714447244473444744447544476444774447844479444804448144482444834448444485444864448744488444894449044491444924449344494444954449644497444984449944500445014450244503445044450544506445074450844509445104451144512445134451444515445164451744518445194452044521445224452344524445254452644527445284452944530445314453244533445344453544536445374453844539445404454144542445434454444545445464454744548445494455044551445524455344554445554455644557445584455944560445614456244563445644456544566445674456844569445704457144572445734457444575445764457744578445794458044581445824458344584445854458644587445884458944590445914459244593445944459544596445974459844599446004460144602446034460444605446064460744608446094461044611446124461344614446154461644617446184461944620446214462244623446244462544626446274462844629446304463144632446334463444635446364463744638446394464044641446424464344644446454464644647446484464944650446514465244653446544465544656446574465844659446604466144662446634466444665446664466744668446694467044671446724467344674446754467644677446784467944680446814468244683446844468544686446874468844689446904469144692446934469444695446964469744698446994470044701447024470344704447054470644707447084470944710447114471244713447144471544716447174471844719447204472144722447234472444725447264472744728447294473044731447324473344734447354473644737447384473944740447414474244743447444474544746447474474844749447504475144752447534475444755447564475744758447594476044761447624476344764447654476644767447684476944770447714477244773447744477544776447774477844779447804478144782447834478444785447864478744788447894479044791447924479344794447954479644797447984479944800448014480244803448044480544806448074480844809448104481144812448134481444815448164481744818448194482044821448224482344824448254482644827448284482944830448314483244833448344483544836448374483844839448404484144842448434484444845448464484744848448494485044851448524485344854448554485644857448584485944860448614486244863448644486544866448674486844869448704487144872448734487444875448764487744878448794488044881448824488344884448854488644887448884488944890448914489244893448944489544896448974489844899449004490144902449034490444905449064490744908449094491044911449124491344914449154491644917449184491944920449214492244923449244492544926449274492844929449304493144932449334493444935449364493744938449394494044941449424494344944449454494644947449484494944950449514495244953449544495544956449574495844959449604496144962449634496444965449664496744968449694497044971449724497344974449754497644977449784497944980449814498244983449844498544986449874498844989449904499144992449934499444995449964499744998449994500045001450024500345004450054500645007450084500945010450114501245013450144501545016450174501845019450204502145022450234502445025450264502745028450294503045031450324503345034450354503645037450384503945040450414504245043450444504545046450474504845049450504505145052450534505445055450564505745058450594506045061450624506345064450654506645067450684506945070450714507245073450744507545076450774507845079450804508145082450834508445085450864508745088450894509045091450924509345094450954509645097450984509945100451014510245103451044510545106451074510845109451104511145112451134511445115451164511745118451194512045121451224512345124451254512645127451284512945130451314513245133451344513545136451374513845139451404514145142451434514445145451464514745148451494515045151451524515345154451554515645157451584515945160451614516245163451644516545166451674516845169451704517145172451734517445175451764517745178451794518045181451824518345184451854518645187451884518945190451914519245193451944519545196451974519845199452004520145202452034520445205452064520745208452094521045211452124521345214452154521645217452184521945220452214522245223452244522545226452274522845229452304523145232452334523445235452364523745238452394524045241452424524345244452454524645247452484524945250452514525245253452544525545256452574525845259452604526145262452634526445265452664526745268452694527045271452724527345274452754527645277452784527945280452814528245283452844528545286452874528845289452904529145292452934529445295452964529745298452994530045301453024530345304453054530645307453084530945310453114531245313453144531545316453174531845319453204532145322453234532445325453264532745328453294533045331453324533345334453354533645337453384533945340453414534245343453444534545346453474534845349453504535145352453534535445355453564535745358453594536045361453624536345364453654536645367453684536945370453714537245373453744537545376453774537845379453804538145382453834538445385453864538745388453894539045391453924539345394453954539645397453984539945400454014540245403454044540545406454074540845409454104541145412454134541445415454164541745418454194542045421454224542345424454254542645427454284542945430454314543245433454344543545436454374543845439454404544145442454434544445445454464544745448454494545045451454524545345454454554545645457454584545945460454614546245463454644546545466454674546845469454704547145472454734547445475454764547745478454794548045481454824548345484454854548645487454884548945490454914549245493454944549545496454974549845499455004550145502455034550445505455064550745508455094551045511455124551345514455154551645517455184551945520455214552245523455244552545526455274552845529455304553145532455334553445535455364553745538455394554045541455424554345544455454554645547455484554945550455514555245553455544555545556455574555845559455604556145562455634556445565455664556745568455694557045571455724557345574455754557645577455784557945580455814558245583455844558545586455874558845589455904559145592455934559445595455964559745598455994560045601456024560345604456054560645607456084560945610456114561245613456144561545616456174561845619456204562145622456234562445625456264562745628456294563045631456324563345634456354563645637456384563945640456414564245643456444564545646456474564845649456504565145652456534565445655456564565745658456594566045661456624566345664456654566645667456684566945670456714567245673456744567545676456774567845679456804568145682456834568445685456864568745688456894569045691456924569345694456954569645697456984569945700457014570245703457044570545706457074570845709457104571145712457134571445715457164571745718457194572045721457224572345724457254572645727457284572945730457314573245733457344573545736457374573845739457404574145742457434574445745457464574745748457494575045751457524575345754457554575645757457584575945760457614576245763457644576545766457674576845769457704577145772457734577445775457764577745778457794578045781457824578345784457854578645787457884578945790457914579245793457944579545796457974579845799458004580145802458034580445805458064580745808458094581045811458124581345814458154581645817458184581945820458214582245823458244582545826458274582845829458304583145832458334583445835458364583745838458394584045841458424584345844458454584645847458484584945850458514585245853458544585545856458574585845859458604586145862458634586445865458664586745868458694587045871458724587345874458754587645877458784587945880458814588245883458844588545886458874588845889458904589145892458934589445895458964589745898458994590045901459024590345904459054590645907459084590945910459114591245913459144591545916459174591845919459204592145922459234592445925459264592745928459294593045931459324593345934459354593645937459384593945940459414594245943459444594545946459474594845949459504595145952459534595445955459564595745958459594596045961459624596345964459654596645967459684596945970459714597245973459744597545976459774597845979459804598145982459834598445985459864598745988459894599045991459924599345994459954599645997459984599946000460014600246003460044600546006460074600846009460104601146012460134601446015460164601746018460194602046021460224602346024460254602646027460284602946030460314603246033460344603546036460374603846039460404604146042460434604446045460464604746048460494605046051460524605346054460554605646057460584605946060460614606246063460644606546066460674606846069460704607146072460734607446075460764607746078460794608046081460824608346084460854608646087460884608946090460914609246093460944609546096460974609846099461004610146102461034610446105461064610746108461094611046111461124611346114461154611646117461184611946120461214612246123461244612546126461274612846129461304613146132461334613446135461364613746138461394614046141461424614346144461454614646147461484614946150461514615246153461544615546156461574615846159461604616146162461634616446165461664616746168461694617046171461724617346174461754617646177461784617946180461814618246183461844618546186461874618846189461904619146192461934619446195461964619746198461994620046201462024620346204462054620646207462084620946210462114621246213462144621546216462174621846219462204622146222462234622446225462264622746228462294623046231462324623346234462354623646237462384623946240462414624246243462444624546246462474624846249462504625146252462534625446255462564625746258462594626046261462624626346264462654626646267462684626946270462714627246273462744627546276462774627846279462804628146282462834628446285462864628746288462894629046291462924629346294462954629646297462984629946300463014630246303463044630546306463074630846309463104631146312463134631446315463164631746318463194632046321463224632346324463254632646327463284632946330463314633246333463344633546336463374633846339463404634146342463434634446345463464634746348463494635046351463524635346354463554635646357463584635946360463614636246363463644636546366463674636846369463704637146372463734637446375463764637746378463794638046381463824638346384463854638646387463884638946390463914639246393463944639546396463974639846399464004640146402464034640446405464064640746408464094641046411464124641346414464154641646417464184641946420464214642246423464244642546426464274642846429464304643146432464334643446435464364643746438464394644046441464424644346444464454644646447464484644946450464514645246453464544645546456464574645846459464604646146462464634646446465464664646746468464694647046471464724647346474464754647646477464784647946480464814648246483464844648546486464874648846489464904649146492464934649446495464964649746498464994650046501465024650346504465054650646507465084650946510465114651246513465144651546516465174651846519465204652146522465234652446525465264652746528465294653046531465324653346534465354653646537465384653946540465414654246543465444654546546465474654846549465504655146552465534655446555465564655746558465594656046561465624656346564465654656646567465684656946570465714657246573465744657546576465774657846579465804658146582465834658446585465864658746588465894659046591465924659346594465954659646597465984659946600466014660246603466044660546606466074660846609466104661146612466134661446615466164661746618466194662046621466224662346624466254662646627466284662946630466314663246633466344663546636466374663846639466404664146642466434664446645466464664746648466494665046651466524665346654466554665646657466584665946660466614666246663466644666546666466674666846669466704667146672466734667446675466764667746678466794668046681466824668346684466854668646687466884668946690466914669246693466944669546696466974669846699467004670146702467034670446705467064670746708467094671046711467124671346714467154671646717467184671946720467214672246723467244672546726467274672846729467304673146732467334673446735467364673746738467394674046741467424674346744467454674646747467484674946750467514675246753467544675546756467574675846759467604676146762467634676446765467664676746768467694677046771467724677346774467754677646777467784677946780467814678246783467844678546786467874678846789467904679146792467934679446795467964679746798467994680046801468024680346804468054680646807468084680946810468114681246813468144681546816468174681846819468204682146822468234682446825468264682746828468294683046831468324683346834468354683646837468384683946840468414684246843468444684546846468474684846849468504685146852468534685446855468564685746858468594686046861468624686346864468654686646867468684686946870468714687246873468744687546876468774687846879468804688146882468834688446885468864688746888468894689046891468924689346894468954689646897468984689946900469014690246903469044690546906469074690846909469104691146912469134691446915469164691746918469194692046921469224692346924469254692646927469284692946930469314693246933469344693546936469374693846939469404694146942469434694446945469464694746948469494695046951469524695346954469554695646957469584695946960469614696246963469644696546966469674696846969469704697146972469734697446975469764697746978469794698046981469824698346984469854698646987469884698946990469914699246993469944699546996469974699846999470004700147002470034700447005470064700747008470094701047011470124701347014470154701647017470184701947020470214702247023470244702547026470274702847029470304703147032470334703447035470364703747038470394704047041470424704347044470454704647047470484704947050470514705247053470544705547056470574705847059470604706147062470634706447065470664706747068470694707047071470724707347074470754707647077470784707947080470814708247083470844708547086470874708847089470904709147092470934709447095470964709747098470994710047101471024710347104471054710647107471084710947110471114711247113471144711547116471174711847119471204712147122471234712447125471264712747128471294713047131471324713347134471354713647137471384713947140471414714247143471444714547146471474714847149471504715147152471534715447155471564715747158471594716047161471624716347164471654716647167471684716947170471714717247173471744717547176471774717847179471804718147182471834718447185471864718747188471894719047191471924719347194471954719647197471984719947200472014720247203472044720547206472074720847209472104721147212472134721447215472164721747218472194722047221472224722347224472254722647227472284722947230472314723247233472344723547236472374723847239472404724147242472434724447245472464724747248472494725047251472524725347254472554725647257472584725947260472614726247263472644726547266472674726847269472704727147272472734727447275472764727747278472794728047281472824728347284472854728647287472884728947290472914729247293472944729547296472974729847299473004730147302473034730447305473064730747308473094731047311473124731347314473154731647317473184731947320473214732247323473244732547326473274732847329473304733147332473334733447335473364733747338473394734047341473424734347344473454734647347473484734947350473514735247353473544735547356473574735847359473604736147362473634736447365473664736747368473694737047371473724737347374473754737647377473784737947380473814738247383473844738547386473874738847389473904739147392473934739447395473964739747398473994740047401474024740347404474054740647407474084740947410474114741247413474144741547416474174741847419474204742147422474234742447425474264742747428474294743047431474324743347434474354743647437474384743947440474414744247443474444744547446474474744847449474504745147452474534745447455474564745747458474594746047461474624746347464474654746647467474684746947470474714747247473474744747547476474774747847479474804748147482474834748447485474864748747488474894749047491474924749347494474954749647497474984749947500475014750247503475044750547506475074750847509475104751147512475134751447515475164751747518475194752047521475224752347524475254752647527475284752947530475314753247533475344753547536475374753847539475404754147542475434754447545475464754747548475494755047551475524755347554475554755647557475584755947560475614756247563475644756547566475674756847569475704757147572475734757447575475764757747578475794758047581475824758347584475854758647587475884758947590475914759247593475944759547596475974759847599476004760147602476034760447605476064760747608476094761047611476124761347614476154761647617476184761947620476214762247623476244762547626476274762847629476304763147632476334763447635476364763747638476394764047641476424764347644476454764647647476484764947650476514765247653476544765547656476574765847659476604766147662476634766447665476664766747668476694767047671476724767347674476754767647677476784767947680476814768247683476844768547686476874768847689476904769147692476934769447695476964769747698476994770047701477024770347704477054770647707477084770947710477114771247713477144771547716477174771847719477204772147722477234772447725477264772747728477294773047731477324773347734477354773647737477384773947740477414774247743477444774547746477474774847749477504775147752477534775447755477564775747758477594776047761477624776347764477654776647767477684776947770477714777247773477744777547776477774777847779477804778147782477834778447785477864778747788477894779047791477924779347794477954779647797477984779947800478014780247803478044780547806478074780847809478104781147812478134781447815478164781747818478194782047821478224782347824478254782647827478284782947830478314783247833478344783547836478374783847839478404784147842478434784447845478464784747848478494785047851478524785347854478554785647857478584785947860478614786247863478644786547866478674786847869478704787147872478734787447875478764787747878478794788047881478824788347884478854788647887478884788947890478914789247893478944789547896478974789847899479004790147902479034790447905479064790747908479094791047911479124791347914479154791647917479184791947920479214792247923479244792547926479274792847929479304793147932479334793447935479364793747938479394794047941479424794347944479454794647947479484794947950479514795247953479544795547956479574795847959479604796147962479634796447965479664796747968479694797047971479724797347974479754797647977479784797947980479814798247983479844798547986479874798847989479904799147992479934799447995479964799747998479994800048001480024800348004480054800648007480084800948010480114801248013480144801548016480174801848019480204802148022480234802448025480264802748028480294803048031480324803348034480354803648037480384803948040480414804248043480444804548046480474804848049480504805148052480534805448055480564805748058480594806048061480624806348064480654806648067480684806948070480714807248073480744807548076480774807848079480804808148082480834808448085480864808748088480894809048091480924809348094480954809648097480984809948100481014810248103481044810548106481074810848109481104811148112481134811448115481164811748118481194812048121481224812348124481254812648127481284812948130481314813248133481344813548136481374813848139481404814148142481434814448145481464814748148481494815048151481524815348154481554815648157481584815948160481614816248163481644816548166481674816848169481704817148172481734817448175481764817748178481794818048181481824818348184481854818648187481884818948190481914819248193481944819548196481974819848199482004820148202482034820448205482064820748208482094821048211482124821348214482154821648217482184821948220482214822248223482244822548226482274822848229482304823148232482334823448235482364823748238482394824048241482424824348244482454824648247482484824948250482514825248253482544825548256482574825848259482604826148262482634826448265482664826748268482694827048271482724827348274482754827648277482784827948280482814828248283482844828548286482874828848289482904829148292482934829448295482964829748298482994830048301483024830348304483054830648307483084830948310483114831248313483144831548316483174831848319483204832148322483234832448325483264832748328483294833048331483324833348334483354833648337483384833948340483414834248343483444834548346483474834848349483504835148352483534835448355483564835748358483594836048361483624836348364483654836648367483684836948370483714837248373483744837548376483774837848379483804838148382483834838448385483864838748388483894839048391483924839348394483954839648397483984839948400484014840248403484044840548406484074840848409484104841148412484134841448415484164841748418484194842048421484224842348424484254842648427484284842948430484314843248433484344843548436484374843848439484404844148442484434844448445484464844748448484494845048451484524845348454484554845648457484584845948460484614846248463484644846548466484674846848469484704847148472484734847448475484764847748478484794848048481484824848348484484854848648487484884848948490484914849248493484944849548496484974849848499485004850148502485034850448505485064850748508485094851048511485124851348514485154851648517485184851948520485214852248523485244852548526485274852848529485304853148532485334853448535485364853748538485394854048541485424854348544485454854648547485484854948550485514855248553485544855548556485574855848559485604856148562485634856448565485664856748568485694857048571485724857348574485754857648577485784857948580485814858248583485844858548586485874858848589485904859148592485934859448595485964859748598485994860048601486024860348604486054860648607486084860948610486114861248613486144861548616486174861848619486204862148622486234862448625486264862748628486294863048631486324863348634486354863648637486384863948640486414864248643486444864548646486474864848649486504865148652486534865448655486564865748658486594866048661486624866348664486654866648667486684866948670486714867248673486744867548676486774867848679486804868148682486834868448685486864868748688486894869048691486924869348694486954869648697486984869948700487014870248703487044870548706487074870848709487104871148712487134871448715487164871748718487194872048721487224872348724487254872648727487284872948730487314873248733487344873548736487374873848739487404874148742487434874448745487464874748748487494875048751487524875348754487554875648757487584875948760487614876248763487644876548766487674876848769487704877148772487734877448775487764877748778487794878048781487824878348784487854878648787487884878948790487914879248793487944879548796487974879848799488004880148802488034880448805488064880748808488094881048811488124881348814488154881648817488184881948820488214882248823488244882548826488274882848829488304883148832488334883448835488364883748838488394884048841488424884348844488454884648847488484884948850488514885248853488544885548856488574885848859488604886148862488634886448865488664886748868488694887048871488724887348874488754887648877488784887948880488814888248883488844888548886488874888848889488904889148892488934889448895488964889748898488994890048901489024890348904489054890648907489084890948910489114891248913489144891548916489174891848919489204892148922489234892448925489264892748928489294893048931489324893348934489354893648937489384893948940489414894248943489444894548946489474894848949489504895148952489534895448955489564895748958489594896048961489624896348964489654896648967489684896948970489714897248973489744897548976489774897848979489804898148982489834898448985489864898748988489894899048991489924899348994489954899648997489984899949000490014900249003490044900549006490074900849009490104901149012490134901449015490164901749018490194902049021490224902349024490254902649027490284902949030490314903249033490344903549036490374903849039490404904149042490434904449045490464904749048490494905049051490524905349054490554905649057490584905949060490614906249063490644906549066490674906849069490704907149072490734907449075490764907749078490794908049081490824908349084490854908649087490884908949090490914909249093490944909549096490974909849099491004910149102491034910449105491064910749108491094911049111491124911349114491154911649117491184911949120491214912249123491244912549126491274912849129491304913149132491334913449135491364913749138491394914049141491424914349144491454914649147491484914949150491514915249153491544915549156491574915849159491604916149162491634916449165491664916749168491694917049171491724917349174491754917649177491784917949180491814918249183491844918549186491874918849189491904919149192491934919449195491964919749198491994920049201492024920349204492054920649207492084920949210492114921249213492144921549216492174921849219492204922149222492234922449225492264922749228492294923049231492324923349234492354923649237492384923949240492414924249243492444924549246492474924849249492504925149252492534925449255492564925749258492594926049261492624926349264492654926649267492684926949270492714927249273492744927549276492774927849279492804928149282492834928449285492864928749288492894929049291492924929349294492954929649297492984929949300493014930249303493044930549306493074930849309493104931149312493134931449315493164931749318493194932049321493224932349324493254932649327493284932949330493314933249333493344933549336493374933849339493404934149342493434934449345493464934749348493494935049351493524935349354493554935649357493584935949360493614936249363493644936549366493674936849369493704937149372493734937449375493764937749378493794938049381493824938349384493854938649387493884938949390493914939249393493944939549396493974939849399494004940149402494034940449405494064940749408494094941049411494124941349414494154941649417494184941949420494214942249423494244942549426494274942849429494304943149432494334943449435494364943749438494394944049441494424944349444494454944649447494484944949450494514945249453494544945549456494574945849459494604946149462494634946449465494664946749468494694947049471494724947349474494754947649477494784947949480494814948249483494844948549486494874948849489494904949149492494934949449495494964949749498494994950049501495024950349504495054950649507495084950949510495114951249513495144951549516495174951849519495204952149522495234952449525495264952749528495294953049531495324953349534495354953649537495384953949540495414954249543495444954549546495474954849549495504955149552495534955449555495564955749558495594956049561495624956349564495654956649567495684956949570495714957249573495744957549576495774957849579495804958149582495834958449585495864958749588495894959049591495924959349594495954959649597495984959949600496014960249603496044960549606496074960849609496104961149612496134961449615496164961749618496194962049621496224962349624496254962649627496284962949630496314963249633496344963549636496374963849639496404964149642496434964449645496464964749648496494965049651496524965349654496554965649657496584965949660496614966249663496644966549666496674966849669496704967149672496734967449675496764967749678496794968049681496824968349684496854968649687496884968949690496914969249693496944969549696496974969849699497004970149702497034970449705497064970749708497094971049711497124971349714497154971649717497184971949720497214972249723497244972549726497274972849729497304973149732497334973449735497364973749738497394974049741497424974349744497454974649747497484974949750497514975249753497544975549756497574975849759497604976149762497634976449765497664976749768497694977049771497724977349774497754977649777497784977949780497814978249783497844978549786497874978849789497904979149792497934979449795497964979749798497994980049801498024980349804498054980649807498084980949810498114981249813498144981549816498174981849819498204982149822498234982449825498264982749828498294983049831498324983349834498354983649837498384983949840498414984249843498444984549846498474984849849498504985149852498534985449855498564985749858498594986049861498624986349864498654986649867498684986949870498714987249873498744987549876498774987849879498804988149882498834988449885498864988749888498894989049891498924989349894498954989649897498984989949900499014990249903499044990549906499074990849909499104991149912499134991449915499164991749918499194992049921499224992349924499254992649927499284992949930499314993249933499344993549936499374993849939499404994149942499434994449945499464994749948499494995049951499524995349954499554995649957499584995949960499614996249963499644996549966499674996849969499704997149972499734997449975499764997749978499794998049981499824998349984499854998649987499884998949990499914999249993499944999549996499974999849999500005000150002500035000450005500065000750008500095001050011500125001350014500155001650017500185001950020500215002250023500245002550026500275002850029500305003150032500335003450035500365003750038500395004050041500425004350044500455004650047500485004950050500515005250053500545005550056500575005850059500605006150062500635006450065500665006750068500695007050071500725007350074500755007650077500785007950080500815008250083500845008550086500875008850089500905009150092500935009450095500965009750098500995010050101501025010350104501055010650107501085010950110501115011250113501145011550116501175011850119501205012150122501235012450125501265012750128501295013050131501325013350134501355013650137501385013950140501415014250143501445014550146501475014850149501505015150152501535015450155501565015750158501595016050161501625016350164501655016650167501685016950170501715017250173501745017550176501775017850179501805018150182501835018450185501865018750188501895019050191501925019350194501955019650197501985019950200502015020250203502045020550206502075020850209502105021150212502135021450215502165021750218502195022050221502225022350224502255022650227502285022950230502315023250233502345023550236502375023850239502405024150242502435024450245502465024750248502495025050251502525025350254502555025650257502585025950260502615026250263502645026550266502675026850269502705027150272502735027450275502765027750278502795028050281502825028350284502855028650287502885028950290502915029250293502945029550296502975029850299503005030150302503035030450305503065030750308503095031050311503125031350314503155031650317503185031950320503215032250323503245032550326503275032850329503305033150332503335033450335503365033750338503395034050341503425034350344503455034650347503485034950350503515035250353503545035550356503575035850359503605036150362503635036450365503665036750368503695037050371503725037350374503755037650377503785037950380503815038250383503845038550386503875038850389503905039150392503935039450395503965039750398503995040050401504025040350404504055040650407504085040950410504115041250413504145041550416504175041850419504205042150422504235042450425504265042750428504295043050431504325043350434504355043650437504385043950440504415044250443504445044550446504475044850449504505045150452504535045450455504565045750458504595046050461504625046350464504655046650467504685046950470504715047250473504745047550476504775047850479504805048150482504835048450485504865048750488504895049050491504925049350494504955049650497504985049950500505015050250503505045050550506505075050850509505105051150512505135051450515505165051750518505195052050521505225052350524505255052650527505285052950530505315053250533505345053550536505375053850539505405054150542505435054450545505465054750548505495055050551505525055350554505555055650557505585055950560505615056250563505645056550566505675056850569505705057150572505735057450575505765057750578505795058050581505825058350584505855058650587505885058950590505915059250593505945059550596505975059850599506005060150602506035060450605506065060750608506095061050611506125061350614506155061650617506185061950620506215062250623506245062550626506275062850629506305063150632506335063450635506365063750638506395064050641506425064350644506455064650647506485064950650506515065250653506545065550656506575065850659506605066150662506635066450665506665066750668506695067050671506725067350674506755067650677506785067950680506815068250683506845068550686506875068850689506905069150692506935069450695506965069750698506995070050701507025070350704507055070650707507085070950710507115071250713507145071550716507175071850719507205072150722507235072450725507265072750728507295073050731507325073350734507355073650737507385073950740507415074250743507445074550746507475074850749507505075150752507535075450755507565075750758507595076050761507625076350764507655076650767507685076950770507715077250773507745077550776507775077850779507805078150782507835078450785507865078750788507895079050791507925079350794507955079650797507985079950800508015080250803508045080550806508075080850809508105081150812508135081450815508165081750818508195082050821508225082350824508255082650827508285082950830508315083250833508345083550836508375083850839508405084150842508435084450845508465084750848508495085050851508525085350854508555085650857508585085950860508615086250863508645086550866508675086850869508705087150872508735087450875508765087750878508795088050881508825088350884508855088650887508885088950890508915089250893508945089550896508975089850899509005090150902509035090450905509065090750908509095091050911509125091350914509155091650917509185091950920509215092250923509245092550926509275092850929509305093150932509335093450935509365093750938509395094050941509425094350944509455094650947509485094950950509515095250953509545095550956509575095850959509605096150962509635096450965509665096750968509695097050971509725097350974509755097650977509785097950980509815098250983509845098550986509875098850989509905099150992509935099450995509965099750998509995100051001510025100351004510055100651007510085100951010510115101251013510145101551016510175101851019510205102151022510235102451025510265102751028510295103051031510325103351034510355103651037510385103951040510415104251043510445104551046510475104851049510505105151052510535105451055510565105751058510595106051061510625106351064510655106651067510685106951070510715107251073510745107551076510775107851079510805108151082510835108451085510865108751088510895109051091510925109351094510955109651097510985109951100511015110251103511045110551106511075110851109511105111151112511135111451115511165111751118511195112051121511225112351124511255112651127511285112951130511315113251133511345113551136511375113851139511405114151142511435114451145511465114751148511495115051151511525115351154511555115651157511585115951160511615116251163511645116551166511675116851169511705117151172511735117451175511765117751178511795118051181511825118351184511855118651187511885118951190511915119251193511945119551196511975119851199512005120151202512035120451205512065120751208512095121051211512125121351214512155121651217512185121951220512215122251223512245122551226512275122851229512305123151232512335123451235512365123751238512395124051241512425124351244512455124651247512485124951250512515125251253512545125551256512575125851259512605126151262512635126451265512665126751268512695127051271512725127351274512755127651277512785127951280512815128251283512845128551286512875128851289512905129151292512935129451295512965129751298512995130051301513025130351304513055130651307513085130951310513115131251313513145131551316513175131851319513205132151322513235132451325513265132751328513295133051331513325133351334513355133651337513385133951340513415134251343513445134551346513475134851349513505135151352513535135451355513565135751358513595136051361513625136351364513655136651367513685136951370513715137251373513745137551376513775137851379513805138151382513835138451385513865138751388513895139051391513925139351394513955139651397513985139951400514015140251403514045140551406514075140851409514105141151412514135141451415514165141751418514195142051421514225142351424514255142651427514285142951430514315143251433514345143551436514375143851439514405144151442514435144451445514465144751448514495145051451514525145351454514555145651457514585145951460514615146251463514645146551466514675146851469514705147151472514735147451475514765147751478514795148051481514825148351484514855148651487514885148951490514915149251493514945149551496514975149851499515005150151502515035150451505515065150751508515095151051511515125151351514515155151651517515185151951520515215152251523515245152551526515275152851529515305153151532515335153451535515365153751538515395154051541515425154351544515455154651547515485154951550515515155251553515545155551556515575155851559515605156151562515635156451565515665156751568515695157051571515725157351574515755157651577515785157951580515815158251583515845158551586515875158851589515905159151592515935159451595515965159751598515995160051601516025160351604516055160651607516085160951610516115161251613516145161551616516175161851619516205162151622516235162451625516265162751628516295163051631516325163351634516355163651637516385163951640516415164251643516445164551646516475164851649516505165151652516535165451655516565165751658516595166051661516625166351664516655166651667516685166951670516715167251673516745167551676516775167851679516805168151682516835168451685516865168751688516895169051691516925169351694516955169651697516985169951700517015170251703517045170551706517075170851709517105171151712517135171451715517165171751718517195172051721517225172351724517255172651727517285172951730517315173251733517345173551736517375173851739517405174151742517435174451745517465174751748517495175051751517525175351754517555175651757517585175951760517615176251763517645176551766517675176851769517705177151772517735177451775517765177751778517795178051781517825178351784517855178651787517885178951790517915179251793517945179551796517975179851799518005180151802518035180451805518065180751808518095181051811518125181351814518155181651817518185181951820518215182251823518245182551826518275182851829518305183151832518335183451835518365183751838518395184051841518425184351844518455184651847518485184951850518515185251853518545185551856518575185851859518605186151862518635186451865518665186751868518695187051871518725187351874518755187651877518785187951880518815188251883518845188551886518875188851889518905189151892518935189451895518965189751898518995190051901519025190351904519055190651907519085190951910519115191251913519145191551916519175191851919519205192151922519235192451925519265192751928519295193051931519325193351934519355193651937519385193951940519415194251943519445194551946519475194851949519505195151952519535195451955519565195751958519595196051961519625196351964519655196651967519685196951970519715197251973519745197551976519775197851979519805198151982519835198451985519865198751988519895199051991519925199351994519955199651997519985199952000520015200252003520045200552006520075200852009520105201152012520135201452015520165201752018520195202052021520225202352024520255202652027520285202952030520315203252033520345203552036520375203852039520405204152042520435204452045520465204752048520495205052051520525205352054520555205652057520585205952060520615206252063520645206552066520675206852069520705207152072520735207452075520765207752078520795208052081520825208352084520855208652087520885208952090520915209252093520945209552096520975209852099521005210152102521035210452105521065210752108521095211052111521125211352114521155211652117521185211952120521215212252123521245212552126521275212852129521305213152132521335213452135521365213752138521395214052141521425214352144521455214652147521485214952150521515215252153521545215552156521575215852159521605216152162521635216452165521665216752168521695217052171521725217352174521755217652177521785217952180521815218252183521845218552186521875218852189521905219152192521935219452195521965219752198521995220052201522025220352204522055220652207522085220952210522115221252213522145221552216522175221852219522205222152222522235222452225522265222752228522295223052231522325223352234522355223652237522385223952240522415224252243522445224552246522475224852249522505225152252522535225452255522565225752258522595226052261522625226352264522655226652267522685226952270522715227252273522745227552276522775227852279522805228152282522835228452285522865228752288522895229052291522925229352294522955229652297522985229952300523015230252303523045230552306523075230852309523105231152312523135231452315523165231752318523195232052321523225232352324523255232652327523285232952330523315233252333523345233552336523375233852339523405234152342523435234452345523465234752348523495235052351523525235352354523555235652357523585235952360523615236252363523645236552366523675236852369523705237152372523735237452375523765237752378523795238052381523825238352384523855238652387523885238952390523915239252393523945239552396523975239852399524005240152402524035240452405524065240752408524095241052411524125241352414524155241652417524185241952420524215242252423524245242552426524275242852429524305243152432524335243452435524365243752438524395244052441524425244352444524455244652447524485244952450524515245252453524545245552456524575245852459524605246152462524635246452465524665246752468524695247052471524725247352474524755247652477524785247952480524815248252483524845248552486524875248852489524905249152492524935249452495524965249752498524995250052501525025250352504525055250652507525085250952510525115251252513525145251552516525175251852519525205252152522525235252452525525265252752528525295253052531525325253352534525355253652537525385253952540525415254252543525445254552546525475254852549525505255152552525535255452555525565255752558525595256052561525625256352564525655256652567525685256952570525715257252573525745257552576525775257852579525805258152582525835258452585525865258752588525895259052591525925259352594525955259652597525985259952600526015260252603526045260552606526075260852609526105261152612526135261452615526165261752618526195262052621526225262352624526255262652627526285262952630526315263252633526345263552636526375263852639526405264152642526435264452645526465264752648526495265052651526525265352654526555265652657526585265952660526615266252663526645266552666526675266852669526705267152672526735267452675526765267752678526795268052681526825268352684526855268652687526885268952690526915269252693526945269552696526975269852699527005270152702527035270452705527065270752708527095271052711527125271352714527155271652717527185271952720527215272252723527245272552726527275272852729527305273152732527335273452735527365273752738527395274052741527425274352744527455274652747527485274952750527515275252753527545275552756527575275852759527605276152762527635276452765527665276752768527695277052771527725277352774527755277652777527785277952780527815278252783527845278552786527875278852789527905279152792527935279452795527965279752798527995280052801528025280352804528055280652807528085280952810528115281252813528145281552816528175281852819528205282152822528235282452825528265282752828528295283052831528325283352834528355283652837528385283952840528415284252843528445284552846528475284852849528505285152852528535285452855528565285752858528595286052861528625286352864528655286652867528685286952870528715287252873528745287552876528775287852879528805288152882528835288452885528865288752888528895289052891528925289352894528955289652897528985289952900529015290252903529045290552906529075290852909529105291152912529135291452915529165291752918529195292052921529225292352924529255292652927529285292952930529315293252933529345293552936529375293852939529405294152942529435294452945529465294752948529495295052951529525295352954529555295652957529585295952960529615296252963529645296552966529675296852969529705297152972529735297452975529765297752978529795298052981529825298352984529855298652987529885298952990529915299252993529945299552996529975299852999530005300153002530035300453005530065300753008530095301053011530125301353014530155301653017530185301953020530215302253023530245302553026530275302853029530305303153032530335303453035530365303753038530395304053041530425304353044530455304653047530485304953050530515305253053530545305553056530575305853059530605306153062530635306453065530665306753068530695307053071530725307353074530755307653077530785307953080530815308253083530845308553086530875308853089530905309153092530935309453095530965309753098530995310053101531025310353104531055310653107531085310953110531115311253113531145311553116531175311853119531205312153122531235312453125531265312753128531295313053131531325313353134531355313653137531385313953140531415314253143531445314553146531475314853149531505315153152531535315453155531565315753158531595316053161531625316353164531655316653167531685316953170531715317253173531745317553176531775317853179531805318153182531835318453185531865318753188531895319053191531925319353194531955319653197531985319953200532015320253203532045320553206532075320853209532105321153212532135321453215532165321753218532195322053221532225322353224532255322653227532285322953230532315323253233532345323553236532375323853239532405324153242532435324453245532465324753248532495325053251532525325353254532555325653257532585325953260532615326253263532645326553266532675326853269532705327153272532735327453275532765327753278532795328053281532825328353284532855328653287532885328953290532915329253293532945329553296532975329853299533005330153302533035330453305533065330753308533095331053311533125331353314533155331653317533185331953320533215332253323533245332553326533275332853329533305333153332533335333453335533365333753338533395334053341533425334353344533455334653347533485334953350533515335253353533545335553356533575335853359533605336153362533635336453365533665336753368533695337053371533725337353374533755337653377533785337953380533815338253383533845338553386533875338853389533905339153392533935339453395533965339753398533995340053401534025340353404534055340653407534085340953410534115341253413534145341553416534175341853419534205342153422534235342453425534265342753428534295343053431534325343353434534355343653437534385343953440534415344253443534445344553446534475344853449534505345153452534535345453455534565345753458534595346053461534625346353464534655346653467534685346953470534715347253473534745347553476534775347853479534805348153482534835348453485534865348753488534895349053491534925349353494534955349653497534985349953500535015350253503535045350553506535075350853509535105351153512535135351453515535165351753518535195352053521535225352353524535255352653527535285352953530535315353253533535345353553536535375353853539535405354153542535435354453545535465354753548535495355053551535525355353554535555355653557535585355953560535615356253563535645356553566535675356853569535705357153572535735357453575535765357753578535795358053581535825358353584535855358653587535885358953590535915359253593535945359553596535975359853599536005360153602536035360453605536065360753608536095361053611536125361353614536155361653617536185361953620536215362253623536245362553626536275362853629536305363153632536335363453635536365363753638536395364053641536425364353644536455364653647536485364953650536515365253653536545365553656536575365853659536605366153662536635366453665536665366753668536695367053671536725367353674536755367653677536785367953680536815368253683536845368553686536875368853689536905369153692536935369453695536965369753698536995370053701537025370353704537055370653707537085370953710537115371253713537145371553716537175371853719537205372153722537235372453725537265372753728537295373053731537325373353734537355373653737537385373953740537415374253743537445374553746537475374853749537505375153752537535375453755537565375753758537595376053761537625376353764537655376653767537685376953770537715377253773537745377553776537775377853779537805378153782537835378453785537865378753788537895379053791537925379353794537955379653797537985379953800538015380253803538045380553806538075380853809538105381153812538135381453815538165381753818538195382053821538225382353824538255382653827538285382953830538315383253833538345383553836538375383853839538405384153842538435384453845538465384753848538495385053851538525385353854538555385653857538585385953860538615386253863538645386553866538675386853869538705387153872538735387453875538765387753878538795388053881538825388353884538855388653887538885388953890538915389253893538945389553896538975389853899539005390153902539035390453905539065390753908539095391053911539125391353914539155391653917539185391953920539215392253923539245392553926539275392853929539305393153932539335393453935539365393753938539395394053941539425394353944539455394653947539485394953950539515395253953539545395553956539575395853959539605396153962539635396453965539665396753968539695397053971539725397353974539755397653977539785397953980539815398253983539845398553986539875398853989539905399153992539935399453995539965399753998539995400054001540025400354004540055400654007540085400954010540115401254013540145401554016540175401854019540205402154022540235402454025540265402754028540295403054031540325403354034540355403654037540385403954040540415404254043540445404554046540475404854049540505405154052540535405454055540565405754058540595406054061540625406354064540655406654067540685406954070540715407254073540745407554076540775407854079540805408154082540835408454085540865408754088540895409054091540925409354094540955409654097540985409954100541015410254103541045410554106541075410854109541105411154112541135411454115541165411754118541195412054121541225412354124541255412654127541285412954130541315413254133541345413554136541375413854139541405414154142541435414454145541465414754148541495415054151541525415354154541555415654157541585415954160541615416254163541645416554166541675416854169541705417154172541735417454175541765417754178541795418054181541825418354184541855418654187541885418954190541915419254193541945419554196541975419854199542005420154202542035420454205542065420754208542095421054211542125421354214542155421654217542185421954220542215422254223542245422554226542275422854229542305423154232542335423454235542365423754238542395424054241542425424354244542455424654247542485424954250542515425254253542545425554256542575425854259542605426154262542635426454265542665426754268542695427054271542725427354274542755427654277542785427954280542815428254283542845428554286542875428854289542905429154292542935429454295542965429754298542995430054301543025430354304543055430654307543085430954310543115431254313543145431554316543175431854319543205432154322543235432454325543265432754328543295433054331543325433354334543355433654337543385433954340543415434254343543445434554346543475434854349543505435154352543535435454355543565435754358543595436054361543625436354364543655436654367543685436954370543715437254373543745437554376543775437854379543805438154382543835438454385543865438754388543895439054391543925439354394543955439654397543985439954400544015440254403544045440554406544075440854409544105441154412544135441454415544165441754418544195442054421544225442354424544255442654427544285442954430544315443254433544345443554436544375443854439544405444154442544435444454445544465444754448544495445054451544525445354454544555445654457544585445954460544615446254463544645446554466544675446854469544705447154472544735447454475544765447754478544795448054481544825448354484544855448654487544885448954490544915449254493544945449554496544975449854499545005450154502545035450454505545065450754508545095451054511545125451354514545155451654517545185451954520545215452254523545245452554526545275452854529545305453154532545335453454535545365453754538545395454054541545425454354544545455454654547545485454954550545515455254553545545455554556545575455854559545605456154562545635456454565545665456754568545695457054571545725457354574545755457654577545785457954580545815458254583545845458554586545875458854589545905459154592545935459454595545965459754598545995460054601546025460354604546055460654607546085460954610546115461254613546145461554616546175461854619546205462154622546235462454625546265462754628546295463054631546325463354634546355463654637546385463954640546415464254643546445464554646546475464854649546505465154652546535465454655546565465754658546595466054661546625466354664546655466654667546685466954670546715467254673546745467554676546775467854679546805468154682546835468454685546865468754688546895469054691546925469354694546955469654697546985469954700547015470254703547045470554706547075470854709547105471154712547135471454715547165471754718547195472054721547225472354724547255472654727547285472954730547315473254733547345473554736547375473854739547405474154742547435474454745547465474754748547495475054751547525475354754547555475654757547585475954760547615476254763547645476554766547675476854769547705477154772547735477454775547765477754778547795478054781547825478354784547855478654787547885478954790547915479254793547945479554796547975479854799548005480154802548035480454805548065480754808548095481054811548125481354814548155481654817548185481954820548215482254823548245482554826548275482854829548305483154832548335483454835548365483754838548395484054841548425484354844548455484654847548485484954850548515485254853548545485554856548575485854859548605486154862548635486454865548665486754868548695487054871548725487354874548755487654877548785487954880548815488254883548845488554886548875488854889548905489154892548935489454895548965489754898548995490054901549025490354904549055490654907549085490954910549115491254913549145491554916549175491854919549205492154922549235492454925549265492754928549295493054931549325493354934549355493654937549385493954940549415494254943549445494554946549475494854949549505495154952549535495454955549565495754958549595496054961549625496354964549655496654967549685496954970549715497254973549745497554976549775497854979549805498154982549835498454985549865498754988549895499054991549925499354994549955499654997549985499955000550015500255003550045500555006550075500855009550105501155012550135501455015550165501755018550195502055021550225502355024550255502655027550285502955030550315503255033550345503555036550375503855039550405504155042550435504455045550465504755048550495505055051550525505355054550555505655057550585505955060550615506255063550645506555066550675506855069550705507155072550735507455075550765507755078550795508055081550825508355084550855508655087550885508955090550915509255093550945509555096550975509855099551005510155102551035510455105551065510755108551095511055111551125511355114551155511655117551185511955120551215512255123551245512555126551275512855129551305513155132551335513455135551365513755138551395514055141551425514355144551455514655147551485514955150551515515255153551545515555156551575515855159551605516155162551635516455165551665516755168551695517055171551725517355174551755517655177551785517955180551815518255183551845518555186551875518855189551905519155192551935519455195551965519755198551995520055201552025520355204552055520655207552085520955210552115521255213552145521555216552175521855219552205522155222552235522455225552265522755228552295523055231552325523355234552355523655237552385523955240552415524255243552445524555246552475524855249552505525155252552535525455255552565525755258552595526055261552625526355264552655526655267552685526955270552715527255273552745527555276552775527855279552805528155282552835528455285552865528755288552895529055291552925529355294552955529655297552985529955300553015530255303553045530555306553075530855309553105531155312553135531455315553165531755318553195532055321553225532355324553255532655327553285532955330553315533255333553345533555336553375533855339553405534155342553435534455345553465534755348553495535055351553525535355354553555535655357553585535955360553615536255363553645536555366553675536855369553705537155372553735537455375553765537755378553795538055381553825538355384553855538655387553885538955390553915539255393553945539555396553975539855399554005540155402554035540455405554065540755408554095541055411554125541355414554155541655417554185541955420554215542255423554245542555426554275542855429554305543155432554335543455435554365543755438554395544055441554425544355444554455544655447554485544955450554515545255453554545545555456554575545855459554605546155462554635546455465554665546755468554695547055471554725547355474554755547655477554785547955480554815548255483554845548555486554875548855489554905549155492554935549455495554965549755498554995550055501555025550355504555055550655507555085550955510555115551255513555145551555516555175551855519555205552155522555235552455525555265552755528555295553055531555325553355534555355553655537555385553955540555415554255543555445554555546555475554855549555505555155552555535555455555555565555755558555595556055561555625556355564555655556655567555685556955570555715557255573555745557555576555775557855579555805558155582555835558455585555865558755588555895559055591555925559355594555955559655597555985559955600556015560255603556045560555606556075560855609556105561155612556135561455615556165561755618556195562055621556225562355624556255562655627556285562955630556315563255633556345563555636556375563855639556405564155642556435564455645556465564755648556495565055651556525565355654556555565655657556585565955660556615566255663556645566555666556675566855669556705567155672556735567455675556765567755678556795568055681556825568355684556855568655687556885568955690556915569255693556945569555696556975569855699557005570155702557035570455705557065570755708557095571055711557125571355714557155571655717557185571955720557215572255723557245572555726557275572855729557305573155732557335573455735557365573755738557395574055741557425574355744557455574655747557485574955750557515575255753557545575555756557575575855759557605576155762557635576455765557665576755768557695577055771557725577355774557755577655777557785577955780557815578255783557845578555786557875578855789557905579155792557935579455795557965579755798557995580055801558025580355804558055580655807558085580955810558115581255813558145581555816558175581855819558205582155822558235582455825558265582755828558295583055831558325583355834558355583655837558385583955840558415584255843558445584555846558475584855849558505585155852558535585455855558565585755858558595586055861558625586355864558655586655867558685586955870558715587255873558745587555876558775587855879558805588155882558835588455885558865588755888558895589055891558925589355894558955589655897558985589955900559015590255903559045590555906559075590855909559105591155912559135591455915559165591755918559195592055921559225592355924559255592655927559285592955930559315593255933559345593555936559375593855939559405594155942559435594455945559465594755948559495595055951559525595355954559555595655957559585595955960559615596255963559645596555966559675596855969559705597155972559735597455975559765597755978559795598055981559825598355984559855598655987559885598955990559915599255993559945599555996559975599855999560005600156002560035600456005560065600756008560095601056011560125601356014560155601656017560185601956020560215602256023560245602556026560275602856029560305603156032560335603456035560365603756038560395604056041560425604356044560455604656047560485604956050560515605256053560545605556056560575605856059560605606156062560635606456065560665606756068560695607056071560725607356074560755607656077560785607956080560815608256083560845608556086560875608856089560905609156092560935609456095560965609756098560995610056101561025610356104561055610656107561085610956110561115611256113561145611556116561175611856119561205612156122561235612456125561265612756128561295613056131561325613356134561355613656137561385613956140561415614256143561445614556146561475614856149561505615156152561535615456155561565615756158561595616056161561625616356164561655616656167561685616956170561715617256173561745617556176561775617856179561805618156182561835618456185561865618756188561895619056191561925619356194561955619656197561985619956200562015620256203562045620556206562075620856209562105621156212562135621456215562165621756218562195622056221562225622356224562255622656227562285622956230562315623256233562345623556236562375623856239562405624156242562435624456245562465624756248562495625056251562525625356254562555625656257562585625956260562615626256263562645626556266562675626856269562705627156272562735627456275562765627756278562795628056281562825628356284562855628656287562885628956290562915629256293562945629556296562975629856299563005630156302563035630456305563065630756308563095631056311563125631356314563155631656317563185631956320563215632256323563245632556326563275632856329563305633156332563335633456335563365633756338563395634056341563425634356344563455634656347563485634956350563515635256353563545635556356563575635856359563605636156362563635636456365563665636756368563695637056371563725637356374563755637656377563785637956380563815638256383563845638556386563875638856389563905639156392563935639456395563965639756398563995640056401564025640356404564055640656407564085640956410564115641256413564145641556416564175641856419564205642156422564235642456425564265642756428564295643056431564325643356434564355643656437564385643956440564415644256443564445644556446564475644856449564505645156452564535645456455564565645756458564595646056461564625646356464564655646656467564685646956470564715647256473564745647556476564775647856479564805648156482564835648456485564865648756488564895649056491564925649356494564955649656497564985649956500565015650256503565045650556506565075650856509565105651156512565135651456515565165651756518565195652056521565225652356524565255652656527565285652956530565315653256533565345653556536565375653856539565405654156542565435654456545565465654756548565495655056551565525655356554565555655656557565585655956560565615656256563565645656556566565675656856569565705657156572565735657456575565765657756578565795658056581565825658356584565855658656587565885658956590565915659256593565945659556596565975659856599566005660156602566035660456605566065660756608566095661056611566125661356614566155661656617566185661956620566215662256623566245662556626566275662856629566305663156632566335663456635566365663756638566395664056641566425664356644566455664656647566485664956650566515665256653566545665556656566575665856659566605666156662566635666456665566665666756668566695667056671566725667356674566755667656677566785667956680566815668256683566845668556686566875668856689566905669156692566935669456695566965669756698566995670056701567025670356704567055670656707567085670956710567115671256713567145671556716567175671856719567205672156722567235672456725567265672756728567295673056731567325673356734567355673656737567385673956740567415674256743567445674556746567475674856749567505675156752567535675456755567565675756758567595676056761567625676356764567655676656767567685676956770567715677256773567745677556776567775677856779567805678156782567835678456785567865678756788567895679056791567925679356794567955679656797567985679956800568015680256803568045680556806568075680856809568105681156812568135681456815568165681756818568195682056821568225682356824568255682656827568285682956830568315683256833568345683556836568375683856839568405684156842568435684456845568465684756848568495685056851568525685356854568555685656857568585685956860568615686256863568645686556866568675686856869568705687156872568735687456875568765687756878568795688056881568825688356884568855688656887568885688956890568915689256893568945689556896568975689856899569005690156902569035690456905569065690756908569095691056911569125691356914569155691656917569185691956920569215692256923569245692556926569275692856929569305693156932569335693456935569365693756938569395694056941569425694356944569455694656947569485694956950569515695256953569545695556956569575695856959569605696156962569635696456965569665696756968569695697056971569725697356974569755697656977569785697956980569815698256983569845698556986569875698856989569905699156992569935699456995569965699756998569995700057001570025700357004570055700657007570085700957010570115701257013570145701557016570175701857019570205702157022570235702457025570265702757028570295703057031570325703357034570355703657037570385703957040570415704257043570445704557046570475704857049570505705157052570535705457055570565705757058570595706057061570625706357064570655706657067570685706957070570715707257073570745707557076570775707857079570805708157082570835708457085570865708757088570895709057091570925709357094570955709657097570985709957100571015710257103571045710557106571075710857109571105711157112571135711457115571165711757118571195712057121571225712357124571255712657127571285712957130571315713257133571345713557136571375713857139571405714157142571435714457145571465714757148571495715057151571525715357154571555715657157571585715957160571615716257163571645716557166571675716857169571705717157172571735717457175571765717757178571795718057181571825718357184571855718657187571885718957190571915719257193571945719557196571975719857199572005720157202572035720457205572065720757208572095721057211572125721357214572155721657217572185721957220572215722257223572245722557226572275722857229572305723157232572335723457235572365723757238572395724057241572425724357244572455724657247572485724957250572515725257253572545725557256572575725857259572605726157262572635726457265572665726757268572695727057271572725727357274572755727657277572785727957280572815728257283572845728557286572875728857289572905729157292572935729457295572965729757298572995730057301573025730357304573055730657307573085730957310573115731257313573145731557316573175731857319573205732157322573235732457325573265732757328573295733057331573325733357334573355733657337573385733957340573415734257343573445734557346573475734857349573505735157352573535735457355573565735757358573595736057361573625736357364573655736657367573685736957370573715737257373573745737557376573775737857379573805738157382573835738457385573865738757388573895739057391573925739357394573955739657397573985739957400574015740257403574045740557406574075740857409574105741157412574135741457415574165741757418574195742057421574225742357424574255742657427574285742957430574315743257433574345743557436574375743857439574405744157442574435744457445574465744757448574495745057451574525745357454574555745657457574585745957460574615746257463574645746557466574675746857469574705747157472574735747457475574765747757478574795748057481574825748357484574855748657487574885748957490574915749257493574945749557496574975749857499575005750157502575035750457505575065750757508575095751057511575125751357514575155751657517575185751957520575215752257523575245752557526575275752857529575305753157532575335753457535575365753757538575395754057541575425754357544575455754657547575485754957550575515755257553575545755557556575575755857559575605756157562575635756457565575665756757568575695757057571575725757357574575755757657577575785757957580575815758257583575845758557586575875758857589575905759157592575935759457595575965759757598575995760057601576025760357604576055760657607576085760957610576115761257613576145761557616576175761857619576205762157622576235762457625576265762757628576295763057631576325763357634576355763657637576385763957640576415764257643576445764557646576475764857649576505765157652576535765457655576565765757658576595766057661576625766357664576655766657667576685766957670576715767257673576745767557676576775767857679576805768157682576835768457685576865768757688576895769057691576925769357694576955769657697576985769957700577015770257703577045770557706577075770857709577105771157712577135771457715577165771757718577195772057721577225772357724577255772657727577285772957730577315773257733577345773557736577375773857739577405774157742577435774457745577465774757748577495775057751577525775357754577555775657757577585775957760577615776257763577645776557766577675776857769577705777157772577735777457775577765777757778577795778057781577825778357784577855778657787577885778957790577915779257793577945779557796577975779857799578005780157802578035780457805578065780757808578095781057811578125781357814578155781657817578185781957820578215782257823578245782557826578275782857829578305783157832578335783457835578365783757838578395784057841578425784357844578455784657847578485784957850578515785257853578545785557856578575785857859578605786157862578635786457865578665786757868578695787057871578725787357874578755787657877578785787957880578815788257883578845788557886578875788857889578905789157892578935789457895578965789757898578995790057901579025790357904579055790657907579085790957910579115791257913579145791557916579175791857919579205792157922579235792457925579265792757928579295793057931579325793357934579355793657937579385793957940579415794257943579445794557946579475794857949579505795157952579535795457955579565795757958579595796057961579625796357964579655796657967579685796957970579715797257973579745797557976579775797857979579805798157982579835798457985579865798757988579895799057991579925799357994579955799657997579985799958000580015800258003580045800558006580075800858009580105801158012580135801458015580165801758018580195802058021580225802358024580255802658027580285802958030580315803258033580345803558036580375803858039580405804158042580435804458045580465804758048580495805058051580525805358054580555805658057580585805958060580615806258063580645806558066580675806858069580705807158072580735807458075580765807758078580795808058081580825808358084580855808658087580885808958090580915809258093580945809558096580975809858099581005810158102581035810458105581065810758108581095811058111581125811358114581155811658117581185811958120581215812258123581245812558126581275812858129581305813158132581335813458135581365813758138581395814058141581425814358144581455814658147581485814958150581515815258153581545815558156581575815858159581605816158162581635816458165581665816758168581695817058171581725817358174581755817658177581785817958180581815818258183581845818558186581875818858189581905819158192581935819458195581965819758198581995820058201582025820358204582055820658207582085820958210582115821258213582145821558216582175821858219582205822158222582235822458225582265822758228582295823058231582325823358234582355823658237582385823958240582415824258243582445824558246582475824858249582505825158252582535825458255582565825758258582595826058261582625826358264582655826658267582685826958270582715827258273582745827558276582775827858279582805828158282582835828458285582865828758288582895829058291582925829358294582955829658297582985829958300583015830258303583045830558306583075830858309583105831158312583135831458315583165831758318583195832058321583225832358324583255832658327583285832958330583315833258333583345833558336583375833858339583405834158342583435834458345583465834758348583495835058351583525835358354583555835658357583585835958360583615836258363583645836558366583675836858369583705837158372583735837458375583765837758378583795838058381583825838358384583855838658387583885838958390583915839258393583945839558396583975839858399584005840158402584035840458405584065840758408584095841058411584125841358414584155841658417584185841958420584215842258423584245842558426584275842858429584305843158432584335843458435584365843758438584395844058441584425844358444584455844658447584485844958450584515845258453584545845558456584575845858459584605846158462584635846458465584665846758468584695847058471584725847358474584755847658477584785847958480584815848258483584845848558486584875848858489584905849158492584935849458495584965849758498584995850058501585025850358504585055850658507585085850958510585115851258513585145851558516585175851858519585205852158522585235852458525585265852758528585295853058531585325853358534585355853658537585385853958540585415854258543585445854558546585475854858549585505855158552585535855458555585565855758558585595856058561585625856358564585655856658567585685856958570585715857258573585745857558576585775857858579585805858158582585835858458585585865858758588585895859058591585925859358594585955859658597585985859958600586015860258603586045860558606586075860858609586105861158612586135861458615586165861758618586195862058621586225862358624586255862658627586285862958630586315863258633586345863558636586375863858639586405864158642586435864458645586465864758648586495865058651586525865358654586555865658657586585865958660586615866258663586645866558666586675866858669586705867158672586735867458675586765867758678586795868058681586825868358684586855868658687586885868958690586915869258693586945869558696586975869858699587005870158702587035870458705587065870758708587095871058711587125871358714587155871658717587185871958720587215872258723587245872558726587275872858729587305873158732587335873458735587365873758738587395874058741587425874358744587455874658747587485874958750587515875258753587545875558756587575875858759587605876158762587635876458765587665876758768587695877058771587725877358774587755877658777587785877958780587815878258783587845878558786587875878858789587905879158792587935879458795587965879758798587995880058801588025880358804588055880658807588085880958810588115881258813588145881558816588175881858819588205882158822588235882458825588265882758828588295883058831588325883358834588355883658837588385883958840588415884258843588445884558846588475884858849588505885158852588535885458855588565885758858588595886058861588625886358864588655886658867588685886958870588715887258873588745887558876588775887858879588805888158882588835888458885588865888758888588895889058891588925889358894588955889658897588985889958900589015890258903589045890558906589075890858909589105891158912589135891458915589165891758918589195892058921589225892358924589255892658927589285892958930589315893258933589345893558936589375893858939589405894158942589435894458945589465894758948589495895058951589525895358954589555895658957589585895958960589615896258963589645896558966589675896858969589705897158972589735897458975589765897758978589795898058981589825898358984589855898658987589885898958990589915899258993589945899558996589975899858999590005900159002590035900459005590065900759008590095901059011590125901359014590155901659017590185901959020590215902259023590245902559026590275902859029590305903159032590335903459035590365903759038590395904059041590425904359044590455904659047590485904959050590515905259053590545905559056590575905859059590605906159062590635906459065590665906759068590695907059071590725907359074590755907659077590785907959080590815908259083590845908559086590875908859089590905909159092590935909459095590965909759098590995910059101591025910359104591055910659107591085910959110591115911259113591145911559116591175911859119591205912159122591235912459125591265912759128591295913059131591325913359134591355913659137591385913959140591415914259143591445914559146591475914859149591505915159152591535915459155591565915759158591595916059161591625916359164591655916659167591685916959170591715917259173591745917559176591775917859179591805918159182591835918459185591865918759188591895919059191591925919359194591955919659197591985919959200592015920259203592045920559206592075920859209592105921159212592135921459215592165921759218592195922059221592225922359224592255922659227592285922959230592315923259233592345923559236592375923859239592405924159242592435924459245592465924759248592495925059251592525925359254592555925659257592585925959260592615926259263592645926559266592675926859269592705927159272592735927459275592765927759278592795928059281592825928359284592855928659287592885928959290592915929259293592945929559296592975929859299593005930159302593035930459305593065930759308593095931059311593125931359314593155931659317593185931959320593215932259323593245932559326593275932859329593305933159332593335933459335593365933759338593395934059341593425934359344593455934659347593485934959350593515935259353593545935559356593575935859359593605936159362593635936459365593665936759368593695937059371593725937359374593755937659377593785937959380593815938259383593845938559386593875938859389593905939159392593935939459395593965939759398593995940059401594025940359404594055940659407594085940959410594115941259413594145941559416594175941859419594205942159422594235942459425594265942759428594295943059431594325943359434594355943659437594385943959440594415944259443594445944559446594475944859449594505945159452594535945459455594565945759458594595946059461594625946359464594655946659467594685946959470594715947259473594745947559476594775947859479594805948159482594835948459485594865948759488594895949059491594925949359494594955949659497594985949959500595015950259503595045950559506595075950859509595105951159512595135951459515595165951759518595195952059521595225952359524595255952659527595285952959530595315953259533595345953559536595375953859539595405954159542595435954459545595465954759548595495955059551595525955359554595555955659557595585955959560595615956259563595645956559566595675956859569595705957159572595735957459575595765957759578595795958059581595825958359584595855958659587595885958959590595915959259593595945959559596595975959859599596005960159602596035960459605596065960759608596095961059611596125961359614596155961659617596185961959620596215962259623596245962559626596275962859629596305963159632596335963459635596365963759638596395964059641596425964359644596455964659647596485964959650596515965259653596545965559656596575965859659596605966159662596635966459665596665966759668596695967059671596725967359674596755967659677596785967959680596815968259683596845968559686596875968859689596905969159692596935969459695596965969759698596995970059701597025970359704597055970659707597085970959710597115971259713597145971559716597175971859719597205972159722597235972459725597265972759728597295973059731597325973359734597355973659737597385973959740597415974259743597445974559746597475974859749597505975159752597535975459755597565975759758597595976059761597625976359764597655976659767597685976959770597715977259773597745977559776597775977859779597805978159782597835978459785597865978759788597895979059791597925979359794597955979659797597985979959800598015980259803598045980559806598075980859809598105981159812598135981459815598165981759818598195982059821598225982359824598255982659827598285982959830598315983259833598345983559836598375983859839598405984159842598435984459845598465984759848598495985059851598525985359854598555985659857598585985959860598615986259863598645986559866598675986859869598705987159872598735987459875598765987759878598795988059881598825988359884598855988659887598885988959890598915989259893598945989559896598975989859899599005990159902599035990459905599065990759908599095991059911599125991359914599155991659917599185991959920599215992259923599245992559926599275992859929599305993159932599335993459935599365993759938599395994059941599425994359944599455994659947599485994959950599515995259953599545995559956599575995859959599605996159962599635996459965599665996759968599695997059971599725997359974599755997659977599785997959980599815998259983599845998559986599875998859989599905999159992599935999459995599965999759998599996000060001600026000360004600056000660007600086000960010600116001260013600146001560016600176001860019600206002160022600236002460025600266002760028600296003060031600326003360034600356003660037600386003960040600416004260043600446004560046600476004860049600506005160052600536005460055600566005760058600596006060061600626006360064600656006660067600686006960070600716007260073600746007560076600776007860079600806008160082600836008460085600866008760088600896009060091600926009360094600956009660097600986009960100601016010260103601046010560106601076010860109601106011160112601136011460115601166011760118601196012060121601226012360124601256012660127601286012960130601316013260133601346013560136601376013860139601406014160142601436014460145601466014760148601496015060151601526015360154601556015660157601586015960160601616016260163601646016560166601676016860169601706017160172601736017460175601766017760178601796018060181601826018360184601856018660187601886018960190601916019260193601946019560196601976019860199602006020160202602036020460205602066020760208602096021060211602126021360214602156021660217602186021960220602216022260223602246022560226602276022860229602306023160232602336023460235602366023760238602396024060241602426024360244602456024660247602486024960250602516025260253602546025560256602576025860259602606026160262602636026460265602666026760268602696027060271602726027360274602756027660277602786027960280602816028260283602846028560286602876028860289602906029160292602936029460295602966029760298602996030060301603026030360304603056030660307603086030960310603116031260313603146031560316603176031860319603206032160322603236032460325603266032760328603296033060331603326033360334603356033660337603386033960340603416034260343603446034560346603476034860349603506035160352603536035460355603566035760358603596036060361603626036360364603656036660367603686036960370603716037260373603746037560376603776037860379603806038160382603836038460385603866038760388603896039060391603926039360394603956039660397603986039960400604016040260403604046040560406604076040860409604106041160412604136041460415604166041760418604196042060421604226042360424604256042660427604286042960430604316043260433604346043560436604376043860439604406044160442604436044460445604466044760448604496045060451604526045360454604556045660457604586045960460604616046260463604646046560466604676046860469604706047160472604736047460475604766047760478604796048060481604826048360484604856048660487604886048960490604916049260493604946049560496604976049860499605006050160502605036050460505605066050760508605096051060511605126051360514605156051660517605186051960520605216052260523605246052560526605276052860529605306053160532605336053460535605366053760538605396054060541605426054360544605456054660547605486054960550605516055260553605546055560556605576055860559605606056160562605636056460565605666056760568605696057060571605726057360574605756057660577605786057960580605816058260583605846058560586605876058860589605906059160592605936059460595605966059760598605996060060601606026060360604606056060660607606086060960610606116061260613606146061560616606176061860619606206062160622606236062460625606266062760628606296063060631606326063360634606356063660637606386063960640606416064260643606446064560646606476064860649606506065160652606536065460655606566065760658606596066060661606626066360664606656066660667606686066960670606716067260673606746067560676606776067860679606806068160682606836068460685606866068760688606896069060691606926069360694606956069660697606986069960700607016070260703607046070560706607076070860709607106071160712607136071460715607166071760718607196072060721607226072360724607256072660727607286072960730607316073260733607346073560736607376073860739607406074160742607436074460745607466074760748607496075060751607526075360754607556075660757607586075960760607616076260763607646076560766607676076860769607706077160772607736077460775607766077760778607796078060781607826078360784607856078660787607886078960790607916079260793607946079560796607976079860799608006080160802608036080460805608066080760808608096081060811608126081360814608156081660817608186081960820608216082260823608246082560826608276082860829608306083160832608336083460835608366083760838608396084060841608426084360844608456084660847608486084960850608516085260853608546085560856608576085860859608606086160862608636086460865608666086760868608696087060871608726087360874608756087660877608786087960880608816088260883608846088560886608876088860889608906089160892608936089460895608966089760898608996090060901609026090360904609056090660907609086090960910609116091260913609146091560916609176091860919609206092160922609236092460925609266092760928609296093060931609326093360934609356093660937609386093960940609416094260943609446094560946609476094860949609506095160952609536095460955609566095760958609596096060961609626096360964609656096660967609686096960970609716097260973609746097560976609776097860979609806098160982609836098460985609866098760988609896099060991609926099360994609956099660997609986099961000610016100261003610046100561006610076100861009610106101161012610136101461015610166101761018610196102061021610226102361024610256102661027610286102961030610316103261033610346103561036610376103861039610406104161042610436104461045610466104761048610496105061051610526105361054610556105661057610586105961060610616106261063610646106561066610676106861069610706107161072610736107461075610766107761078610796108061081610826108361084610856108661087610886108961090610916109261093610946109561096610976109861099611006110161102611036110461105611066110761108611096111061111611126111361114611156111661117611186111961120611216112261123611246112561126611276112861129611306113161132611336113461135611366113761138611396114061141611426114361144611456114661147611486114961150611516115261153611546115561156611576115861159611606116161162611636116461165611666116761168611696117061171611726117361174611756117661177611786117961180611816118261183611846118561186611876118861189611906119161192611936119461195611966119761198611996120061201612026120361204612056120661207612086120961210612116121261213612146121561216612176121861219612206122161222612236122461225612266122761228612296123061231612326123361234612356123661237612386123961240612416124261243612446124561246612476124861249612506125161252612536125461255612566125761258612596126061261612626126361264612656126661267612686126961270612716127261273612746127561276612776127861279612806128161282612836128461285612866128761288612896129061291612926129361294612956129661297612986129961300613016130261303613046130561306613076130861309613106131161312613136131461315613166131761318613196132061321613226132361324613256132661327613286132961330613316133261333613346133561336613376133861339613406134161342613436134461345613466134761348613496135061351613526135361354613556135661357613586135961360613616136261363613646136561366613676136861369613706137161372613736137461375613766137761378613796138061381613826138361384613856138661387613886138961390613916139261393613946139561396613976139861399614006140161402614036140461405614066140761408614096141061411614126141361414614156141661417614186141961420614216142261423614246142561426614276142861429614306143161432614336143461435614366143761438614396144061441614426144361444614456144661447614486144961450614516145261453614546145561456614576145861459614606146161462614636146461465614666146761468614696147061471614726147361474614756147661477614786147961480614816148261483614846148561486614876148861489614906149161492614936149461495614966149761498614996150061501615026150361504615056150661507615086150961510615116151261513615146151561516615176151861519615206152161522615236152461525615266152761528615296153061531615326153361534615356153661537615386153961540615416154261543615446154561546615476154861549615506155161552615536155461555615566155761558615596156061561615626156361564615656156661567615686156961570615716157261573615746157561576615776157861579615806158161582615836158461585615866158761588615896159061591615926159361594615956159661597615986159961600616016160261603616046160561606616076160861609616106161161612616136161461615616166161761618616196162061621616226162361624616256162661627616286162961630616316163261633616346163561636616376163861639616406164161642616436164461645616466164761648616496165061651616526165361654616556165661657616586165961660616616166261663616646166561666616676166861669616706167161672616736167461675616766167761678616796168061681616826168361684616856168661687616886168961690616916169261693616946169561696616976169861699617006170161702617036170461705617066170761708617096171061711617126171361714617156171661717617186171961720617216172261723617246172561726617276172861729617306173161732617336173461735617366173761738617396174061741617426174361744617456174661747617486174961750617516175261753617546175561756617576175861759617606176161762617636176461765617666176761768617696177061771617726177361774617756177661777617786177961780617816178261783617846178561786617876178861789617906179161792617936179461795617966179761798617996180061801618026180361804618056180661807618086180961810618116181261813618146181561816618176181861819618206182161822618236182461825618266182761828618296183061831618326183361834618356183661837618386183961840618416184261843618446184561846618476184861849618506185161852618536185461855618566185761858618596186061861618626186361864618656186661867618686186961870618716187261873618746187561876618776187861879618806188161882618836188461885618866188761888618896189061891618926189361894618956189661897618986189961900619016190261903619046190561906619076190861909619106191161912619136191461915619166191761918619196192061921619226192361924619256192661927619286192961930619316193261933619346193561936619376193861939619406194161942619436194461945619466194761948619496195061951619526195361954619556195661957619586195961960619616196261963619646196561966619676196861969619706197161972619736197461975619766197761978619796198061981619826198361984619856198661987619886198961990619916199261993619946199561996619976199861999620006200162002620036200462005620066200762008620096201062011620126201362014620156201662017620186201962020620216202262023620246202562026620276202862029620306203162032620336203462035620366203762038620396204062041620426204362044620456204662047620486204962050620516205262053620546205562056620576205862059620606206162062620636206462065620666206762068620696207062071620726207362074620756207662077620786207962080620816208262083620846208562086620876208862089620906209162092620936209462095620966209762098620996210062101621026210362104621056210662107621086210962110621116211262113621146211562116621176211862119621206212162122621236212462125621266212762128621296213062131621326213362134621356213662137621386213962140621416214262143621446214562146621476214862149621506215162152621536215462155621566215762158621596216062161621626216362164621656216662167621686216962170621716217262173621746217562176621776217862179621806218162182621836218462185621866218762188621896219062191621926219362194621956219662197621986219962200622016220262203622046220562206622076220862209622106221162212622136221462215622166221762218622196222062221622226222362224622256222662227622286222962230622316223262233622346223562236622376223862239622406224162242622436224462245622466224762248622496225062251622526225362254622556225662257622586225962260622616226262263622646226562266622676226862269622706227162272622736227462275622766227762278622796228062281622826228362284622856228662287622886228962290622916229262293622946229562296622976229862299623006230162302623036230462305623066230762308623096231062311623126231362314623156231662317623186231962320623216232262323623246232562326623276232862329623306233162332623336233462335623366233762338623396234062341623426234362344623456234662347623486234962350623516235262353623546235562356623576235862359623606236162362623636236462365623666236762368623696237062371623726237362374623756237662377623786237962380623816238262383623846238562386623876238862389623906239162392623936239462395623966239762398623996240062401624026240362404624056240662407624086240962410624116241262413624146241562416624176241862419624206242162422624236242462425624266242762428624296243062431624326243362434624356243662437624386243962440624416244262443624446244562446624476244862449624506245162452624536245462455624566245762458624596246062461624626246362464624656246662467624686246962470624716247262473624746247562476624776247862479624806248162482624836248462485624866248762488624896249062491624926249362494624956249662497624986249962500625016250262503625046250562506625076250862509625106251162512625136251462515625166251762518625196252062521625226252362524625256252662527625286252962530625316253262533625346253562536625376253862539625406254162542625436254462545625466254762548625496255062551625526255362554625556255662557625586255962560625616256262563625646256562566625676256862569625706257162572625736257462575625766257762578625796258062581625826258362584625856258662587625886258962590625916259262593625946259562596625976259862599626006260162602626036260462605626066260762608626096261062611626126261362614626156261662617626186261962620626216262262623626246262562626626276262862629626306263162632626336263462635626366263762638626396264062641626426264362644626456264662647626486264962650626516265262653626546265562656626576265862659626606266162662626636266462665626666266762668626696267062671626726267362674626756267662677626786267962680626816268262683626846268562686626876268862689626906269162692626936269462695626966269762698626996270062701627026270362704627056270662707627086270962710627116271262713627146271562716627176271862719627206272162722627236272462725627266272762728627296273062731627326273362734627356273662737627386273962740627416274262743627446274562746627476274862749627506275162752627536275462755627566275762758627596276062761627626276362764627656276662767627686276962770627716277262773627746277562776627776277862779627806278162782627836278462785627866278762788627896279062791627926279362794627956279662797627986279962800628016280262803628046280562806628076280862809628106281162812628136281462815628166281762818628196282062821628226282362824628256282662827628286282962830628316283262833628346283562836628376283862839628406284162842628436284462845628466284762848628496285062851628526285362854628556285662857628586285962860628616286262863628646286562866628676286862869628706287162872628736287462875628766287762878628796288062881628826288362884628856288662887628886288962890628916289262893628946289562896628976289862899629006290162902629036290462905629066290762908629096291062911629126291362914629156291662917629186291962920629216292262923629246292562926629276292862929629306293162932629336293462935629366293762938629396294062941629426294362944629456294662947629486294962950629516295262953629546295562956629576295862959629606296162962629636296462965629666296762968629696297062971629726297362974629756297662977629786297962980629816298262983629846298562986629876298862989629906299162992629936299462995629966299762998629996300063001630026300363004630056300663007630086300963010630116301263013630146301563016630176301863019630206302163022630236302463025630266302763028630296303063031630326303363034630356303663037630386303963040630416304263043630446304563046630476304863049630506305163052630536305463055630566305763058630596306063061630626306363064630656306663067630686306963070630716307263073630746307563076630776307863079630806308163082630836308463085630866308763088630896309063091630926309363094630956309663097630986309963100631016310263103631046310563106631076310863109631106311163112631136311463115631166311763118631196312063121631226312363124631256312663127631286312963130631316313263133631346313563136631376313863139631406314163142631436314463145631466314763148631496315063151631526315363154631556315663157631586315963160631616316263163631646316563166631676316863169631706317163172631736317463175631766317763178631796318063181631826318363184631856318663187631886318963190631916319263193631946319563196631976319863199632006320163202632036320463205632066320763208632096321063211632126321363214632156321663217632186321963220632216322263223632246322563226632276322863229632306323163232632336323463235632366323763238632396324063241632426324363244632456324663247632486324963250632516325263253632546325563256632576325863259632606326163262632636326463265632666326763268632696327063271632726327363274632756327663277632786327963280632816328263283632846328563286632876328863289632906329163292632936329463295632966329763298632996330063301633026330363304633056330663307633086330963310633116331263313633146331563316633176331863319633206332163322633236332463325633266332763328633296333063331633326333363334633356333663337633386333963340633416334263343633446334563346633476334863349633506335163352633536335463355633566335763358633596336063361633626336363364633656336663367633686336963370633716337263373633746337563376633776337863379633806338163382633836338463385633866338763388633896339063391633926339363394633956339663397633986339963400634016340263403634046340563406634076340863409634106341163412634136341463415634166341763418634196342063421634226342363424634256342663427634286342963430634316343263433634346343563436634376343863439634406344163442634436344463445634466344763448634496345063451634526345363454634556345663457634586345963460634616346263463634646346563466634676346863469634706347163472634736347463475634766347763478634796348063481634826348363484634856348663487634886348963490634916349263493634946349563496634976349863499635006350163502635036350463505635066350763508635096351063511635126351363514635156351663517635186351963520635216352263523635246352563526635276352863529635306353163532635336353463535635366353763538635396354063541635426354363544635456354663547635486354963550635516355263553635546355563556635576355863559635606356163562635636356463565635666356763568635696357063571635726357363574635756357663577635786357963580635816358263583635846358563586635876358863589635906359163592635936359463595635966359763598635996360063601636026360363604636056360663607636086360963610636116361263613636146361563616636176361863619636206362163622636236362463625636266362763628636296363063631636326363363634636356363663637636386363963640636416364263643636446364563646636476364863649636506365163652636536365463655636566365763658636596366063661636626366363664636656366663667636686366963670636716367263673636746367563676636776367863679636806368163682636836368463685636866368763688636896369063691636926369363694636956369663697636986369963700637016370263703637046370563706637076370863709637106371163712637136371463715637166371763718637196372063721637226372363724637256372663727637286372963730637316373263733637346373563736637376373863739637406374163742637436374463745637466374763748637496375063751637526375363754637556375663757637586375963760637616376263763637646376563766637676376863769637706377163772637736377463775637766377763778637796378063781637826378363784637856378663787637886378963790637916379263793637946379563796637976379863799638006380163802638036380463805638066380763808638096381063811638126381363814638156381663817638186381963820638216382263823638246382563826638276382863829638306383163832638336383463835638366383763838638396384063841638426384363844638456384663847638486384963850638516385263853638546385563856638576385863859638606386163862638636386463865638666386763868638696387063871638726387363874638756387663877638786387963880638816388263883638846388563886638876388863889638906389163892638936389463895638966389763898638996390063901639026390363904639056390663907639086390963910639116391263913639146391563916639176391863919639206392163922639236392463925639266392763928639296393063931639326393363934639356393663937639386393963940639416394263943639446394563946639476394863949639506395163952639536395463955639566395763958639596396063961639626396363964639656396663967639686396963970639716397263973639746397563976639776397863979639806398163982639836398463985639866398763988639896399063991639926399363994639956399663997639986399964000640016400264003640046400564006640076400864009640106401164012640136401464015640166401764018640196402064021640226402364024640256402664027640286402964030640316403264033640346403564036640376403864039640406404164042640436404464045640466404764048640496405064051640526405364054640556405664057640586405964060640616406264063640646406564066640676406864069640706407164072640736407464075640766407764078640796408064081640826408364084640856408664087640886408964090640916409264093640946409564096640976409864099641006410164102641036410464105641066410764108641096411064111641126411364114641156411664117641186411964120641216412264123641246412564126641276412864129641306413164132641336413464135641366413764138641396414064141641426414364144641456414664147641486414964150641516415264153641546415564156641576415864159641606416164162641636416464165641666416764168641696417064171641726417364174641756417664177641786417964180641816418264183641846418564186641876418864189641906419164192641936419464195641966419764198641996420064201642026420364204642056420664207642086420964210642116421264213642146421564216642176421864219642206422164222642236422464225642266422764228642296423064231642326423364234642356423664237642386423964240642416424264243642446424564246642476424864249642506425164252642536425464255642566425764258642596426064261642626426364264642656426664267642686426964270642716427264273642746427564276642776427864279642806428164282642836428464285642866428764288642896429064291642926429364294642956429664297642986429964300643016430264303643046430564306643076430864309643106431164312643136431464315643166431764318643196432064321643226432364324643256432664327643286432964330643316433264333643346433564336643376433864339643406434164342643436434464345643466434764348643496435064351643526435364354643556435664357643586435964360643616436264363643646436564366643676436864369643706437164372643736437464375643766437764378643796438064381643826438364384643856438664387643886438964390643916439264393643946439564396643976439864399644006440164402644036440464405644066440764408644096441064411644126441364414644156441664417644186441964420644216442264423644246442564426644276442864429644306443164432644336443464435644366443764438644396444064441644426444364444644456444664447644486444964450644516445264453644546445564456644576445864459644606446164462644636446464465644666446764468644696447064471644726447364474644756447664477644786447964480644816448264483644846448564486644876448864489644906449164492644936449464495644966449764498644996450064501645026450364504645056450664507645086450964510645116451264513645146451564516645176451864519645206452164522645236452464525645266452764528645296453064531645326453364534645356453664537645386453964540645416454264543645446454564546645476454864549645506455164552645536455464555645566455764558645596456064561645626456364564645656456664567645686456964570645716457264573645746457564576645776457864579645806458164582645836458464585645866458764588645896459064591645926459364594645956459664597645986459964600646016460264603646046460564606646076460864609646106461164612646136461464615646166461764618646196462064621646226462364624646256462664627646286462964630646316463264633646346463564636646376463864639646406464164642646436464464645646466464764648646496465064651646526465364654646556465664657646586465964660646616466264663646646466564666646676466864669646706467164672646736467464675646766467764678646796468064681646826468364684646856468664687646886468964690646916469264693646946469564696646976469864699647006470164702647036470464705647066470764708647096471064711647126471364714647156471664717647186471964720647216472264723647246472564726647276472864729647306473164732647336473464735647366473764738647396474064741647426474364744647456474664747647486474964750647516475264753647546475564756647576475864759647606476164762647636476464765647666476764768647696477064771647726477364774647756477664777647786477964780647816478264783647846478564786647876478864789647906479164792647936479464795647966479764798647996480064801648026480364804648056480664807648086480964810648116481264813648146481564816648176481864819648206482164822648236482464825648266482764828648296483064831648326483364834648356483664837648386483964840648416484264843648446484564846648476484864849648506485164852648536485464855648566485764858648596486064861648626486364864648656486664867648686486964870648716487264873648746487564876648776487864879648806488164882648836488464885648866488764888648896489064891648926489364894648956489664897648986489964900649016490264903649046490564906649076490864909649106491164912649136491464915649166491764918649196492064921649226492364924649256492664927649286492964930649316493264933649346493564936649376493864939649406494164942649436494464945649466494764948649496495064951649526495364954649556495664957649586495964960649616496264963649646496564966649676496864969649706497164972649736497464975649766497764978649796498064981649826498364984649856498664987649886498964990649916499264993649946499564996649976499864999650006500165002650036500465005650066500765008650096501065011650126501365014650156501665017650186501965020650216502265023650246502565026650276502865029650306503165032650336503465035650366503765038650396504065041650426504365044650456504665047650486504965050650516505265053650546505565056650576505865059650606506165062650636506465065650666506765068650696507065071650726507365074650756507665077650786507965080650816508265083650846508565086650876508865089650906509165092650936509465095650966509765098650996510065101651026510365104651056510665107651086510965110651116511265113651146511565116651176511865119651206512165122651236512465125651266512765128651296513065131651326513365134651356513665137651386513965140651416514265143651446514565146651476514865149651506515165152651536515465155651566515765158651596516065161651626516365164651656516665167651686516965170651716517265173651746517565176651776517865179651806518165182651836518465185651866518765188651896519065191651926519365194651956519665197651986519965200652016520265203652046520565206652076520865209652106521165212652136521465215652166521765218652196522065221652226522365224652256522665227652286522965230652316523265233652346523565236652376523865239652406524165242652436524465245652466524765248652496525065251652526525365254652556525665257652586525965260652616526265263652646526565266652676526865269652706527165272652736527465275652766527765278652796528065281652826528365284652856528665287652886528965290652916529265293652946529565296652976529865299653006530165302653036530465305653066530765308653096531065311653126531365314653156531665317653186531965320653216532265323653246532565326653276532865329653306533165332653336533465335653366533765338653396534065341653426534365344653456534665347653486534965350653516535265353653546535565356653576535865359653606536165362653636536465365653666536765368653696537065371653726537365374653756537665377653786537965380653816538265383653846538565386653876538865389653906539165392653936539465395653966539765398653996540065401654026540365404654056540665407654086540965410654116541265413654146541565416654176541865419654206542165422654236542465425654266542765428654296543065431654326543365434654356543665437654386543965440654416544265443654446544565446654476544865449654506545165452654536545465455654566545765458654596546065461654626546365464654656546665467654686546965470654716547265473654746547565476654776547865479654806548165482654836548465485654866548765488654896549065491654926549365494654956549665497654986549965500655016550265503655046550565506655076550865509655106551165512655136551465515655166551765518655196552065521655226552365524655256552665527655286552965530655316553265533655346553565536655376553865539655406554165542655436554465545655466554765548655496555065551655526555365554655556555665557655586555965560655616556265563655646556565566655676556865569655706557165572655736557465575655766557765578655796558065581655826558365584655856558665587655886558965590655916559265593655946559565596655976559865599656006560165602656036560465605656066560765608656096561065611656126561365614656156561665617656186561965620656216562265623656246562565626656276562865629656306563165632656336563465635656366563765638656396564065641656426564365644656456564665647656486564965650656516565265653656546565565656656576565865659656606566165662656636566465665656666566765668656696567065671656726567365674656756567665677656786567965680656816568265683656846568565686656876568865689656906569165692656936569465695656966569765698656996570065701657026570365704657056570665707657086570965710657116571265713657146571565716657176571865719657206572165722657236572465725657266572765728657296573065731657326573365734657356573665737657386573965740657416574265743657446574565746657476574865749657506575165752657536575465755657566575765758657596576065761657626576365764657656576665767657686576965770657716577265773657746577565776657776577865779657806578165782657836578465785657866578765788657896579065791657926579365794657956579665797657986579965800658016580265803658046580565806658076580865809658106581165812658136581465815658166581765818658196582065821658226582365824658256582665827658286582965830658316583265833658346583565836658376583865839658406584165842658436584465845658466584765848658496585065851658526585365854658556585665857658586585965860658616586265863658646586565866658676586865869658706587165872658736587465875658766587765878658796588065881658826588365884658856588665887658886588965890658916589265893658946589565896658976589865899659006590165902659036590465905659066590765908659096591065911659126591365914659156591665917659186591965920659216592265923659246592565926659276592865929659306593165932659336593465935659366593765938659396594065941659426594365944659456594665947659486594965950659516595265953659546595565956659576595865959659606596165962659636596465965659666596765968659696597065971659726597365974659756597665977659786597965980659816598265983659846598565986659876598865989659906599165992659936599465995659966599765998659996600066001660026600366004660056600666007660086600966010660116601266013660146601566016660176601866019660206602166022660236602466025660266602766028660296603066031660326603366034660356603666037660386603966040660416604266043660446604566046660476604866049660506605166052660536605466055660566605766058660596606066061660626606366064660656606666067660686606966070660716607266073660746607566076660776607866079660806608166082660836608466085660866608766088660896609066091660926609366094660956609666097660986609966100661016610266103661046610566106661076610866109661106611166112661136611466115661166611766118661196612066121661226612366124661256612666127661286612966130661316613266133661346613566136661376613866139661406614166142661436614466145661466614766148661496615066151661526615366154661556615666157661586615966160661616616266163661646616566166661676616866169661706617166172661736617466175661766617766178661796618066181661826618366184661856618666187661886618966190661916619266193661946619566196661976619866199662006620166202662036620466205662066620766208662096621066211662126621366214662156621666217662186621966220662216622266223662246622566226662276622866229662306623166232662336623466235662366623766238662396624066241662426624366244662456624666247662486624966250662516625266253662546625566256662576625866259662606626166262662636626466265662666626766268662696627066271662726627366274662756627666277662786627966280662816628266283662846628566286662876628866289662906629166292662936629466295662966629766298662996630066301663026630366304663056630666307663086630966310663116631266313663146631566316663176631866319663206632166322663236632466325663266632766328663296633066331663326633366334663356633666337663386633966340663416634266343663446634566346663476634866349663506635166352663536635466355663566635766358663596636066361663626636366364663656636666367663686636966370663716637266373663746637566376663776637866379663806638166382663836638466385663866638766388663896639066391663926639366394663956639666397663986639966400664016640266403664046640566406664076640866409664106641166412664136641466415664166641766418664196642066421664226642366424664256642666427664286642966430664316643266433664346643566436664376643866439664406644166442664436644466445664466644766448664496645066451664526645366454664556645666457664586645966460664616646266463664646646566466664676646866469664706647166472664736647466475664766647766478664796648066481664826648366484664856648666487664886648966490664916649266493664946649566496664976649866499665006650166502665036650466505665066650766508665096651066511665126651366514665156651666517665186651966520665216652266523665246652566526665276652866529665306653166532665336653466535665366653766538665396654066541665426654366544665456654666547665486654966550665516655266553665546655566556665576655866559665606656166562665636656466565665666656766568665696657066571665726657366574665756657666577665786657966580665816658266583665846658566586665876658866589665906659166592665936659466595665966659766598665996660066601666026660366604666056660666607666086660966610666116661266613666146661566616666176661866619666206662166622666236662466625666266662766628666296663066631666326663366634666356663666637666386663966640666416664266643666446664566646666476664866649666506665166652666536665466655666566665766658666596666066661666626666366664666656666666667666686666966670666716667266673666746667566676666776667866679666806668166682666836668466685666866668766688666896669066691666926669366694666956669666697666986669966700667016670266703667046670566706667076670866709667106671166712667136671466715667166671766718667196672066721667226672366724667256672666727667286672966730667316673266733667346673566736667376673866739667406674166742667436674466745667466674766748667496675066751667526675366754667556675666757667586675966760667616676266763667646676566766667676676866769667706677166772667736677466775667766677766778667796678066781667826678366784667856678666787667886678966790667916679266793667946679566796667976679866799668006680166802668036680466805668066680766808668096681066811668126681366814668156681666817668186681966820668216682266823668246682566826668276682866829668306683166832668336683466835668366683766838668396684066841668426684366844668456684666847668486684966850668516685266853668546685566856668576685866859668606686166862668636686466865668666686766868668696687066871668726687366874668756687666877668786687966880668816688266883668846688566886668876688866889668906689166892668936689466895668966689766898668996690066901669026690366904669056690666907669086690966910669116691266913669146691566916669176691866919669206692166922669236692466925669266692766928669296693066931669326693366934669356693666937669386693966940669416694266943669446694566946669476694866949669506695166952669536695466955669566695766958669596696066961669626696366964669656696666967669686696966970669716697266973669746697566976669776697866979669806698166982669836698466985669866698766988669896699066991669926699366994669956699666997669986699967000670016700267003670046700567006670076700867009670106701167012670136701467015670166701767018670196702067021670226702367024670256702667027670286702967030670316703267033670346703567036670376703867039670406704167042670436704467045670466704767048670496705067051670526705367054670556705667057670586705967060670616706267063670646706567066670676706867069670706707167072670736707467075670766707767078670796708067081670826708367084670856708667087670886708967090670916709267093670946709567096670976709867099671006710167102671036710467105671066710767108671096711067111671126711367114671156711667117671186711967120671216712267123671246712567126671276712867129671306713167132671336713467135671366713767138671396714067141671426714367144671456714667147671486714967150671516715267153671546715567156671576715867159671606716167162671636716467165671666716767168671696717067171671726717367174671756717667177671786717967180671816718267183671846718567186671876718867189671906719167192671936719467195671966719767198671996720067201672026720367204672056720667207672086720967210672116721267213672146721567216672176721867219672206722167222672236722467225672266722767228672296723067231672326723367234672356723667237672386723967240672416724267243672446724567246672476724867249672506725167252672536725467255672566725767258672596726067261672626726367264672656726667267672686726967270672716727267273672746727567276672776727867279672806728167282672836728467285672866728767288672896729067291672926729367294672956729667297672986729967300673016730267303673046730567306673076730867309673106731167312673136731467315673166731767318673196732067321673226732367324673256732667327673286732967330673316733267333673346733567336673376733867339673406734167342673436734467345673466734767348673496735067351673526735367354673556735667357673586735967360673616736267363673646736567366673676736867369673706737167372673736737467375673766737767378673796738067381673826738367384673856738667387673886738967390673916739267393673946739567396673976739867399674006740167402674036740467405674066740767408674096741067411674126741367414674156741667417674186741967420674216742267423674246742567426674276742867429674306743167432674336743467435674366743767438674396744067441674426744367444674456744667447674486744967450674516745267453674546745567456674576745867459674606746167462674636746467465674666746767468674696747067471674726747367474674756747667477674786747967480674816748267483674846748567486674876748867489674906749167492674936749467495674966749767498674996750067501675026750367504675056750667507675086750967510675116751267513675146751567516675176751867519675206752167522675236752467525675266752767528675296753067531675326753367534675356753667537675386753967540675416754267543675446754567546675476754867549675506755167552675536755467555675566755767558675596756067561675626756367564675656756667567675686756967570675716757267573675746757567576675776757867579675806758167582675836758467585675866758767588675896759067591675926759367594675956759667597675986759967600676016760267603676046760567606676076760867609676106761167612676136761467615676166761767618676196762067621676226762367624676256762667627676286762967630676316763267633676346763567636676376763867639676406764167642676436764467645676466764767648676496765067651676526765367654676556765667657676586765967660676616766267663676646766567666676676766867669676706767167672676736767467675676766767767678676796768067681676826768367684676856768667687676886768967690676916769267693676946769567696676976769867699677006770167702677036770467705677066770767708677096771067711677126771367714677156771667717677186771967720677216772267723677246772567726677276772867729677306773167732677336773467735677366773767738677396774067741677426774367744677456774667747677486774967750677516775267753677546775567756677576775867759677606776167762677636776467765677666776767768677696777067771677726777367774677756777667777677786777967780677816778267783677846778567786677876778867789677906779167792677936779467795677966779767798677996780067801678026780367804678056780667807678086780967810678116781267813678146781567816678176781867819678206782167822678236782467825678266782767828678296783067831678326783367834678356783667837678386783967840678416784267843678446784567846678476784867849678506785167852678536785467855678566785767858678596786067861678626786367864678656786667867678686786967870678716787267873678746787567876678776787867879678806788167882678836788467885678866788767888678896789067891678926789367894678956789667897678986789967900679016790267903679046790567906679076790867909679106791167912679136791467915679166791767918679196792067921679226792367924679256792667927679286792967930679316793267933679346793567936679376793867939679406794167942679436794467945679466794767948679496795067951679526795367954679556795667957679586795967960679616796267963679646796567966679676796867969679706797167972679736797467975679766797767978679796798067981679826798367984679856798667987679886798967990679916799267993679946799567996679976799867999680006800168002680036800468005680066800768008680096801068011680126801368014680156801668017680186801968020680216802268023680246802568026680276802868029680306803168032680336803468035680366803768038680396804068041680426804368044680456804668047680486804968050680516805268053680546805568056680576805868059680606806168062680636806468065680666806768068680696807068071680726807368074680756807668077680786807968080680816808268083680846808568086680876808868089680906809168092680936809468095680966809768098680996810068101681026810368104681056810668107681086810968110681116811268113681146811568116681176811868119681206812168122681236812468125681266812768128681296813068131681326813368134681356813668137681386813968140681416814268143681446814568146681476814868149681506815168152681536815468155681566815768158681596816068161681626816368164681656816668167681686816968170681716817268173681746817568176681776817868179681806818168182681836818468185681866818768188681896819068191681926819368194681956819668197681986819968200682016820268203682046820568206682076820868209682106821168212682136821468215682166821768218682196822068221682226822368224682256822668227682286822968230682316823268233682346823568236682376823868239682406824168242682436824468245682466824768248682496825068251682526825368254682556825668257682586825968260682616826268263682646826568266682676826868269682706827168272682736827468275682766827768278682796828068281682826828368284682856828668287682886828968290682916829268293682946829568296682976829868299683006830168302683036830468305683066830768308683096831068311683126831368314683156831668317683186831968320683216832268323683246832568326683276832868329683306833168332683336833468335683366833768338683396834068341683426834368344683456834668347683486834968350683516835268353683546835568356683576835868359683606836168362683636836468365683666836768368683696837068371683726837368374683756837668377683786837968380683816838268383683846838568386683876838868389683906839168392683936839468395683966839768398683996840068401684026840368404684056840668407684086840968410684116841268413684146841568416684176841868419684206842168422684236842468425684266842768428684296843068431684326843368434684356843668437684386843968440684416844268443684446844568446684476844868449684506845168452684536845468455684566845768458684596846068461684626846368464684656846668467684686846968470684716847268473684746847568476684776847868479684806848168482684836848468485684866848768488684896849068491684926849368494684956849668497684986849968500685016850268503685046850568506685076850868509685106851168512685136851468515685166851768518685196852068521685226852368524685256852668527685286852968530685316853268533685346853568536685376853868539685406854168542685436854468545685466854768548685496855068551685526855368554685556855668557685586855968560685616856268563685646856568566685676856868569685706857168572685736857468575685766857768578685796858068581685826858368584685856858668587685886858968590685916859268593685946859568596685976859868599686006860168602686036860468605686066860768608686096861068611686126861368614686156861668617686186861968620686216862268623686246862568626686276862868629686306863168632686336863468635686366863768638686396864068641686426864368644686456864668647686486864968650686516865268653686546865568656686576865868659686606866168662686636866468665686666866768668686696867068671686726867368674686756867668677686786867968680686816868268683686846868568686686876868868689686906869168692686936869468695686966869768698686996870068701687026870368704687056870668707687086870968710687116871268713687146871568716687176871868719687206872168722687236872468725687266872768728687296873068731687326873368734687356873668737687386873968740687416874268743687446874568746687476874868749687506875168752687536875468755687566875768758687596876068761687626876368764687656876668767687686876968770687716877268773687746877568776687776877868779687806878168782687836878468785687866878768788687896879068791687926879368794687956879668797687986879968800688016880268803688046880568806688076880868809688106881168812688136881468815688166881768818688196882068821688226882368824688256882668827688286882968830688316883268833688346883568836688376883868839688406884168842688436884468845688466884768848688496885068851688526885368854688556885668857688586885968860688616886268863688646886568866688676886868869688706887168872688736887468875688766887768878688796888068881688826888368884688856888668887688886888968890688916889268893688946889568896688976889868899689006890168902689036890468905689066890768908689096891068911689126891368914689156891668917689186891968920689216892268923689246892568926689276892868929689306893168932689336893468935689366893768938689396894068941689426894368944689456894668947689486894968950689516895268953689546895568956689576895868959689606896168962689636896468965689666896768968689696897068971689726897368974689756897668977689786897968980689816898268983689846898568986689876898868989689906899168992689936899468995689966899768998689996900069001690026900369004690056900669007690086900969010690116901269013690146901569016690176901869019690206902169022690236902469025690266902769028690296903069031690326903369034690356903669037690386903969040690416904269043690446904569046690476904869049690506905169052690536905469055690566905769058690596906069061690626906369064690656906669067690686906969070690716907269073690746907569076690776907869079690806908169082690836908469085690866908769088690896909069091690926909369094690956909669097690986909969100691016910269103691046910569106691076910869109691106911169112691136911469115691166911769118691196912069121691226912369124691256912669127691286912969130691316913269133691346913569136691376913869139691406914169142691436914469145691466914769148691496915069151691526915369154691556915669157691586915969160691616916269163691646916569166691676916869169691706917169172691736917469175691766917769178691796918069181691826918369184691856918669187691886918969190691916919269193691946919569196691976919869199692006920169202692036920469205692066920769208692096921069211692126921369214692156921669217692186921969220692216922269223692246922569226692276922869229692306923169232692336923469235692366923769238692396924069241692426924369244692456924669247692486924969250692516925269253692546925569256692576925869259692606926169262692636926469265692666926769268692696927069271692726927369274692756927669277692786927969280692816928269283692846928569286692876928869289692906929169292692936929469295692966929769298692996930069301693026930369304693056930669307693086930969310693116931269313693146931569316693176931869319693206932169322693236932469325693266932769328693296933069331693326933369334693356933669337693386933969340693416934269343693446934569346693476934869349693506935169352693536935469355693566935769358693596936069361693626936369364693656936669367693686936969370693716937269373693746937569376693776937869379693806938169382693836938469385693866938769388693896939069391693926939369394693956939669397693986939969400694016940269403694046940569406694076940869409694106941169412694136941469415694166941769418694196942069421694226942369424694256942669427694286942969430694316943269433694346943569436694376943869439694406944169442694436944469445694466944769448694496945069451694526945369454694556945669457694586945969460694616946269463694646946569466694676946869469694706947169472694736947469475694766947769478694796948069481694826948369484694856948669487694886948969490694916949269493694946949569496694976949869499695006950169502695036950469505695066950769508695096951069511695126951369514695156951669517695186951969520695216952269523695246952569526695276952869529695306953169532695336953469535695366953769538695396954069541695426954369544695456954669547695486954969550695516955269553695546955569556695576955869559695606956169562695636956469565695666956769568695696957069571695726957369574695756957669577695786957969580695816958269583695846958569586695876958869589695906959169592695936959469595695966959769598695996960069601696026960369604696056960669607696086960969610696116961269613696146961569616696176961869619696206962169622696236962469625696266962769628696296963069631696326963369634696356963669637696386963969640696416964269643696446964569646696476964869649696506965169652696536965469655696566965769658696596966069661696626966369664696656966669667696686966969670696716967269673696746967569676696776967869679696806968169682696836968469685696866968769688696896969069691696926969369694696956969669697696986969969700697016970269703697046970569706697076970869709697106971169712697136971469715697166971769718697196972069721697226972369724697256972669727697286972969730697316973269733697346973569736697376973869739697406974169742697436974469745697466974769748697496975069751697526975369754697556975669757697586975969760697616976269763697646976569766697676976869769697706977169772697736977469775697766977769778697796978069781697826978369784697856978669787697886978969790697916979269793697946979569796697976979869799698006980169802698036980469805698066980769808698096981069811698126981369814698156981669817698186981969820698216982269823698246982569826698276982869829698306983169832698336983469835698366983769838698396984069841698426984369844698456984669847698486984969850698516985269853698546985569856698576985869859698606986169862698636986469865698666986769868698696987069871698726987369874698756987669877698786987969880698816988269883698846988569886698876988869889698906989169892698936989469895698966989769898698996990069901699026990369904699056990669907699086990969910699116991269913699146991569916699176991869919699206992169922699236992469925699266992769928699296993069931699326993369934699356993669937699386993969940699416994269943699446994569946699476994869949699506995169952699536995469955699566995769958699596996069961699626996369964699656996669967699686996969970699716997269973699746997569976699776997869979699806998169982699836998469985699866998769988699896999069991699926999369994699956999669997699986999970000700017000270003700047000570006700077000870009700107001170012700137001470015700167001770018700197002070021700227002370024700257002670027700287002970030700317003270033700347003570036700377003870039700407004170042700437004470045700467004770048700497005070051700527005370054700557005670057700587005970060700617006270063700647006570066700677006870069700707007170072700737007470075700767007770078700797008070081700827008370084700857008670087700887008970090700917009270093700947009570096700977009870099701007010170102701037010470105701067010770108701097011070111701127011370114701157011670117701187011970120701217012270123701247012570126701277012870129701307013170132701337013470135701367013770138701397014070141701427014370144701457014670147701487014970150701517015270153701547015570156701577015870159701607016170162701637016470165701667016770168701697017070171701727017370174701757017670177701787017970180701817018270183701847018570186701877018870189701907019170192701937019470195701967019770198701997020070201702027020370204702057020670207702087020970210702117021270213702147021570216702177021870219702207022170222702237022470225702267022770228702297023070231702327023370234702357023670237702387023970240702417024270243702447024570246702477024870249702507025170252702537025470255702567025770258702597026070261702627026370264702657026670267702687026970270702717027270273702747027570276702777027870279702807028170282702837028470285702867028770288702897029070291702927029370294702957029670297702987029970300703017030270303703047030570306703077030870309703107031170312703137031470315703167031770318703197032070321703227032370324703257032670327703287032970330703317033270333703347033570336703377033870339703407034170342703437034470345703467034770348703497035070351703527035370354703557035670357703587035970360703617036270363703647036570366703677036870369703707037170372703737037470375703767037770378703797038070381703827038370384703857038670387703887038970390703917039270393703947039570396703977039870399704007040170402704037040470405704067040770408704097041070411704127041370414704157041670417704187041970420704217042270423704247042570426704277042870429704307043170432704337043470435704367043770438704397044070441704427044370444704457044670447704487044970450704517045270453704547045570456704577045870459704607046170462704637046470465704667046770468704697047070471704727047370474704757047670477704787047970480704817048270483704847048570486704877048870489704907049170492704937049470495704967049770498704997050070501705027050370504705057050670507705087050970510705117051270513705147051570516705177051870519705207052170522705237052470525705267052770528705297053070531705327053370534705357053670537705387053970540705417054270543705447054570546705477054870549705507055170552705537055470555705567055770558705597056070561705627056370564705657056670567705687056970570705717057270573705747057570576705777057870579705807058170582705837058470585705867058770588705897059070591705927059370594705957059670597705987059970600706017060270603706047060570606706077060870609706107061170612706137061470615706167061770618706197062070621706227062370624706257062670627706287062970630706317063270633706347063570636706377063870639706407064170642706437064470645706467064770648706497065070651706527065370654706557065670657706587065970660706617066270663706647066570666706677066870669706707067170672706737067470675706767067770678706797068070681706827068370684706857068670687706887068970690706917069270693706947069570696706977069870699707007070170702707037070470705707067070770708707097071070711707127071370714707157071670717707187071970720707217072270723707247072570726707277072870729707307073170732707337073470735707367073770738707397074070741707427074370744707457074670747707487074970750707517075270753707547075570756707577075870759707607076170762707637076470765707667076770768707697077070771707727077370774707757077670777707787077970780707817078270783707847078570786707877078870789707907079170792707937079470795707967079770798707997080070801708027080370804708057080670807708087080970810708117081270813708147081570816708177081870819708207082170822708237082470825708267082770828708297083070831708327083370834708357083670837708387083970840708417084270843708447084570846708477084870849708507085170852708537085470855708567085770858708597086070861708627086370864708657086670867708687086970870708717087270873708747087570876708777087870879708807088170882708837088470885708867088770888708897089070891708927089370894708957089670897708987089970900709017090270903709047090570906709077090870909709107091170912709137091470915709167091770918709197092070921709227092370924709257092670927709287092970930709317093270933709347093570936709377093870939709407094170942709437094470945709467094770948709497095070951709527095370954709557095670957709587095970960709617096270963709647096570966709677096870969709707097170972709737097470975709767097770978709797098070981709827098370984709857098670987709887098970990709917099270993709947099570996709977099870999710007100171002710037100471005710067100771008710097101071011710127101371014710157101671017710187101971020710217102271023710247102571026710277102871029710307103171032710337103471035710367103771038710397104071041710427104371044710457104671047710487104971050710517105271053710547105571056710577105871059710607106171062710637106471065710667106771068710697107071071710727107371074710757107671077710787107971080710817108271083710847108571086710877108871089710907109171092710937109471095710967109771098710997110071101711027110371104711057110671107711087110971110711117111271113711147111571116711177111871119711207112171122711237112471125711267112771128711297113071131711327113371134711357113671137711387113971140711417114271143711447114571146711477114871149711507115171152711537115471155711567115771158711597116071161711627116371164711657116671167711687116971170711717117271173711747117571176711777117871179711807118171182711837118471185711867118771188711897119071191711927119371194711957119671197711987119971200712017120271203712047120571206712077120871209712107121171212712137121471215712167121771218712197122071221712227122371224712257122671227712287122971230712317123271233712347123571236712377123871239712407124171242712437124471245712467124771248712497125071251712527125371254712557125671257712587125971260712617126271263712647126571266712677126871269712707127171272712737127471275712767127771278712797128071281712827128371284712857128671287712887128971290712917129271293712947129571296712977129871299713007130171302713037130471305713067130771308713097131071311713127131371314713157131671317713187131971320713217132271323713247132571326713277132871329713307133171332713337133471335713367133771338713397134071341713427134371344713457134671347713487134971350713517135271353713547135571356713577135871359713607136171362713637136471365713667136771368713697137071371713727137371374713757137671377713787137971380713817138271383713847138571386713877138871389713907139171392713937139471395713967139771398713997140071401714027140371404714057140671407714087140971410714117141271413714147141571416714177141871419714207142171422714237142471425714267142771428714297143071431714327143371434714357143671437714387143971440714417144271443714447144571446714477144871449714507145171452714537145471455714567145771458714597146071461714627146371464714657146671467714687146971470714717147271473714747147571476714777147871479714807148171482714837148471485714867148771488714897149071491714927149371494714957149671497714987149971500715017150271503715047150571506715077150871509715107151171512715137151471515715167151771518715197152071521715227152371524715257152671527715287152971530715317153271533715347153571536715377153871539715407154171542715437154471545715467154771548715497155071551715527155371554715557155671557715587155971560715617156271563715647156571566715677156871569715707157171572715737157471575715767157771578715797158071581715827158371584715857158671587715887158971590715917159271593715947159571596715977159871599716007160171602716037160471605716067160771608716097161071611716127161371614716157161671617716187161971620716217162271623716247162571626716277162871629716307163171632716337163471635716367163771638716397164071641716427164371644716457164671647716487164971650716517165271653716547165571656716577165871659716607166171662716637166471665716667166771668716697167071671716727167371674716757167671677716787167971680716817168271683716847168571686716877168871689716907169171692716937169471695716967169771698716997170071701717027170371704717057170671707717087170971710717117171271713717147171571716717177171871719717207172171722717237172471725717267172771728717297173071731717327173371734717357173671737717387173971740717417174271743717447174571746717477174871749717507175171752717537175471755717567175771758717597176071761717627176371764717657176671767717687176971770717717177271773717747177571776717777177871779717807178171782717837178471785717867178771788717897179071791717927179371794717957179671797717987179971800718017180271803718047180571806718077180871809718107181171812718137181471815718167181771818718197182071821718227182371824718257182671827718287182971830718317183271833718347183571836718377183871839718407184171842718437184471845718467184771848718497185071851718527185371854718557185671857718587185971860718617186271863718647186571866718677186871869718707187171872718737187471875718767187771878718797188071881718827188371884718857188671887718887188971890718917189271893718947189571896718977189871899719007190171902719037190471905719067190771908719097191071911719127191371914719157191671917719187191971920719217192271923719247192571926719277192871929719307193171932719337193471935719367193771938719397194071941719427194371944719457194671947719487194971950719517195271953719547195571956719577195871959719607196171962719637196471965719667196771968719697197071971719727197371974719757197671977719787197971980719817198271983719847198571986719877198871989719907199171992719937199471995719967199771998719997200072001720027200372004720057200672007720087200972010720117201272013720147201572016720177201872019720207202172022720237202472025720267202772028720297203072031720327203372034720357203672037720387203972040720417204272043720447204572046720477204872049720507205172052720537205472055720567205772058720597206072061720627206372064720657206672067720687206972070720717207272073720747207572076720777207872079720807208172082720837208472085720867208772088720897209072091720927209372094720957209672097720987209972100721017210272103721047210572106721077210872109721107211172112721137211472115721167211772118721197212072121721227212372124721257212672127721287212972130721317213272133721347213572136721377213872139721407214172142721437214472145721467214772148721497215072151721527215372154721557215672157721587215972160721617216272163721647216572166721677216872169721707217172172721737217472175721767217772178721797218072181721827218372184721857218672187721887218972190721917219272193721947219572196721977219872199722007220172202722037220472205722067220772208722097221072211722127221372214722157221672217722187221972220722217222272223722247222572226722277222872229722307223172232722337223472235722367223772238722397224072241722427224372244722457224672247722487224972250722517225272253722547225572256722577225872259722607226172262722637226472265722667226772268722697227072271722727227372274722757227672277722787227972280722817228272283722847228572286722877228872289722907229172292722937229472295722967229772298 |
- /*! For license information please see swagger-ui-bundle.js.LICENSE.txt */
- !(function webpackUniversalModuleDefinition(s, o) {
- 'object' == typeof exports && 'object' == typeof module
- ? (module.exports = o())
- : 'function' == typeof define && define.amd
- ? define([], o)
- : 'object' == typeof exports
- ? (exports.SwaggerUIBundle = o())
- : (s.SwaggerUIBundle = o());
- })(this, () =>
- (() => {
- var s,
- o,
- i = {
- 69119: (s, o) => {
- 'use strict';
- Object.defineProperty(o, '__esModule', { value: !0 }),
- (o.BLANK_URL =
- o.relativeFirstCharacters =
- o.whitespaceEscapeCharsRegex =
- o.urlSchemeRegex =
- o.ctrlCharactersRegex =
- o.htmlCtrlEntityRegex =
- o.htmlEntitiesRegex =
- o.invalidProtocolRegex =
- void 0),
- (o.invalidProtocolRegex = /^([^\w]*)(javascript|data|vbscript)/im),
- (o.htmlEntitiesRegex = /&#(\w+)(^\w|;)?/g),
- (o.htmlCtrlEntityRegex = /&(newline|tab);/gi),
- (o.ctrlCharactersRegex = /[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim),
- (o.urlSchemeRegex = /^.+(:|:)/gim),
- (o.whitespaceEscapeCharsRegex = /(\\|%5[cC])((%(6[eE]|72|74))|[nrt])/g),
- (o.relativeFirstCharacters = ['.', '/']),
- (o.BLANK_URL = 'about:blank');
- },
- 16750: (s, o, i) => {
- 'use strict';
- o.J = void 0;
- var u = i(69119);
- function decodeURI(s) {
- try {
- return decodeURIComponent(s);
- } catch (o) {
- return s;
- }
- }
- o.J = function sanitizeUrl(s) {
- if (!s) return u.BLANK_URL;
- var o,
- i,
- _ = decodeURI(s);
- do {
- o =
- (_ = decodeURI(
- (_ = ((i = _),
- i
- .replace(u.ctrlCharactersRegex, '')
- .replace(u.htmlEntitiesRegex, function (s, o) {
- return String.fromCharCode(o);
- }))
- .replace(u.htmlCtrlEntityRegex, '')
- .replace(u.ctrlCharactersRegex, '')
- .replace(u.whitespaceEscapeCharsRegex, '')
- .trim())
- )).match(u.ctrlCharactersRegex) ||
- _.match(u.htmlEntitiesRegex) ||
- _.match(u.htmlCtrlEntityRegex) ||
- _.match(u.whitespaceEscapeCharsRegex);
- } while (o && o.length > 0);
- var w = _;
- if (!w) return u.BLANK_URL;
- if (
- (function isRelativeUrlWithoutProtocol(s) {
- return u.relativeFirstCharacters.indexOf(s[0]) > -1;
- })(w)
- )
- return w;
- var x = w.match(u.urlSchemeRegex);
- if (!x) return w;
- var C = x[0];
- return u.invalidProtocolRegex.test(C) ? u.BLANK_URL : w;
- };
- },
- 67526: (s, o) => {
- 'use strict';
- (o.byteLength = function byteLength(s) {
- var o = getLens(s),
- i = o[0],
- u = o[1];
- return (3 * (i + u)) / 4 - u;
- }),
- (o.toByteArray = function toByteArray(s) {
- var o,
- i,
- w = getLens(s),
- x = w[0],
- C = w[1],
- j = new _(
- (function _byteLength(s, o, i) {
- return (3 * (o + i)) / 4 - i;
- })(0, x, C)
- ),
- L = 0,
- B = C > 0 ? x - 4 : x;
- for (i = 0; i < B; i += 4)
- (o =
- (u[s.charCodeAt(i)] << 18) |
- (u[s.charCodeAt(i + 1)] << 12) |
- (u[s.charCodeAt(i + 2)] << 6) |
- u[s.charCodeAt(i + 3)]),
- (j[L++] = (o >> 16) & 255),
- (j[L++] = (o >> 8) & 255),
- (j[L++] = 255 & o);
- 2 === C &&
- ((o = (u[s.charCodeAt(i)] << 2) | (u[s.charCodeAt(i + 1)] >> 4)),
- (j[L++] = 255 & o));
- 1 === C &&
- ((o =
- (u[s.charCodeAt(i)] << 10) |
- (u[s.charCodeAt(i + 1)] << 4) |
- (u[s.charCodeAt(i + 2)] >> 2)),
- (j[L++] = (o >> 8) & 255),
- (j[L++] = 255 & o));
- return j;
- }),
- (o.fromByteArray = function fromByteArray(s) {
- for (
- var o, u = s.length, _ = u % 3, w = [], x = 16383, C = 0, j = u - _;
- C < j;
- C += x
- )
- w.push(encodeChunk(s, C, C + x > j ? j : C + x));
- 1 === _
- ? ((o = s[u - 1]), w.push(i[o >> 2] + i[(o << 4) & 63] + '=='))
- : 2 === _ &&
- ((o = (s[u - 2] << 8) + s[u - 1]),
- w.push(i[o >> 10] + i[(o >> 4) & 63] + i[(o << 2) & 63] + '='));
- return w.join('');
- });
- for (
- var i = [],
- u = [],
- _ = 'undefined' != typeof Uint8Array ? Uint8Array : Array,
- w = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/',
- x = 0;
- x < 64;
- ++x
- )
- (i[x] = w[x]), (u[w.charCodeAt(x)] = x);
- function getLens(s) {
- var o = s.length;
- if (o % 4 > 0) throw new Error('Invalid string. Length must be a multiple of 4');
- var i = s.indexOf('=');
- return -1 === i && (i = o), [i, i === o ? 0 : 4 - (i % 4)];
- }
- function encodeChunk(s, o, u) {
- for (var _, w, x = [], C = o; C < u; C += 3)
- (_ = ((s[C] << 16) & 16711680) + ((s[C + 1] << 8) & 65280) + (255 & s[C + 2])),
- x.push(i[((w = _) >> 18) & 63] + i[(w >> 12) & 63] + i[(w >> 6) & 63] + i[63 & w]);
- return x.join('');
- }
- (u['-'.charCodeAt(0)] = 62), (u['_'.charCodeAt(0)] = 63);
- },
- 48287: (s, o, i) => {
- 'use strict';
- const u = i(67526),
- _ = i(251),
- w =
- 'function' == typeof Symbol && 'function' == typeof Symbol.for
- ? Symbol.for('nodejs.util.inspect.custom')
- : null;
- (o.Buffer = Buffer),
- (o.SlowBuffer = function SlowBuffer(s) {
- +s != s && (s = 0);
- return Buffer.alloc(+s);
- }),
- (o.INSPECT_MAX_BYTES = 50);
- const x = 2147483647;
- function createBuffer(s) {
- if (s > x) throw new RangeError('The value "' + s + '" is invalid for option "size"');
- const o = new Uint8Array(s);
- return Object.setPrototypeOf(o, Buffer.prototype), o;
- }
- function Buffer(s, o, i) {
- if ('number' == typeof s) {
- if ('string' == typeof o)
- throw new TypeError(
- 'The "string" argument must be of type string. Received type number'
- );
- return allocUnsafe(s);
- }
- return from(s, o, i);
- }
- function from(s, o, i) {
- if ('string' == typeof s)
- return (function fromString(s, o) {
- ('string' == typeof o && '' !== o) || (o = 'utf8');
- if (!Buffer.isEncoding(o)) throw new TypeError('Unknown encoding: ' + o);
- const i = 0 | byteLength(s, o);
- let u = createBuffer(i);
- const _ = u.write(s, o);
- _ !== i && (u = u.slice(0, _));
- return u;
- })(s, o);
- if (ArrayBuffer.isView(s))
- return (function fromArrayView(s) {
- if (isInstance(s, Uint8Array)) {
- const o = new Uint8Array(s);
- return fromArrayBuffer(o.buffer, o.byteOffset, o.byteLength);
- }
- return fromArrayLike(s);
- })(s);
- if (null == s)
- throw new TypeError(
- 'The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type ' +
- typeof s
- );
- if (isInstance(s, ArrayBuffer) || (s && isInstance(s.buffer, ArrayBuffer)))
- return fromArrayBuffer(s, o, i);
- if (
- 'undefined' != typeof SharedArrayBuffer &&
- (isInstance(s, SharedArrayBuffer) || (s && isInstance(s.buffer, SharedArrayBuffer)))
- )
- return fromArrayBuffer(s, o, i);
- if ('number' == typeof s)
- throw new TypeError(
- 'The "value" argument must not be of type number. Received type number'
- );
- const u = s.valueOf && s.valueOf();
- if (null != u && u !== s) return Buffer.from(u, o, i);
- const _ = (function fromObject(s) {
- if (Buffer.isBuffer(s)) {
- const o = 0 | checked(s.length),
- i = createBuffer(o);
- return 0 === i.length || s.copy(i, 0, 0, o), i;
- }
- if (void 0 !== s.length)
- return 'number' != typeof s.length || numberIsNaN(s.length)
- ? createBuffer(0)
- : fromArrayLike(s);
- if ('Buffer' === s.type && Array.isArray(s.data)) return fromArrayLike(s.data);
- })(s);
- if (_) return _;
- if (
- 'undefined' != typeof Symbol &&
- null != Symbol.toPrimitive &&
- 'function' == typeof s[Symbol.toPrimitive]
- )
- return Buffer.from(s[Symbol.toPrimitive]('string'), o, i);
- throw new TypeError(
- 'The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type ' +
- typeof s
- );
- }
- function assertSize(s) {
- if ('number' != typeof s) throw new TypeError('"size" argument must be of type number');
- if (s < 0) throw new RangeError('The value "' + s + '" is invalid for option "size"');
- }
- function allocUnsafe(s) {
- return assertSize(s), createBuffer(s < 0 ? 0 : 0 | checked(s));
- }
- function fromArrayLike(s) {
- const o = s.length < 0 ? 0 : 0 | checked(s.length),
- i = createBuffer(o);
- for (let u = 0; u < o; u += 1) i[u] = 255 & s[u];
- return i;
- }
- function fromArrayBuffer(s, o, i) {
- if (o < 0 || s.byteLength < o)
- throw new RangeError('"offset" is outside of buffer bounds');
- if (s.byteLength < o + (i || 0))
- throw new RangeError('"length" is outside of buffer bounds');
- let u;
- return (
- (u =
- void 0 === o && void 0 === i
- ? new Uint8Array(s)
- : void 0 === i
- ? new Uint8Array(s, o)
- : new Uint8Array(s, o, i)),
- Object.setPrototypeOf(u, Buffer.prototype),
- u
- );
- }
- function checked(s) {
- if (s >= x)
- throw new RangeError(
- 'Attempt to allocate Buffer larger than maximum size: 0x' +
- x.toString(16) +
- ' bytes'
- );
- return 0 | s;
- }
- function byteLength(s, o) {
- if (Buffer.isBuffer(s)) return s.length;
- if (ArrayBuffer.isView(s) || isInstance(s, ArrayBuffer)) return s.byteLength;
- if ('string' != typeof s)
- throw new TypeError(
- 'The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type ' +
- typeof s
- );
- const i = s.length,
- u = arguments.length > 2 && !0 === arguments[2];
- if (!u && 0 === i) return 0;
- let _ = !1;
- for (;;)
- switch (o) {
- case 'ascii':
- case 'latin1':
- case 'binary':
- return i;
- case 'utf8':
- case 'utf-8':
- return utf8ToBytes(s).length;
- case 'ucs2':
- case 'ucs-2':
- case 'utf16le':
- case 'utf-16le':
- return 2 * i;
- case 'hex':
- return i >>> 1;
- case 'base64':
- return base64ToBytes(s).length;
- default:
- if (_) return u ? -1 : utf8ToBytes(s).length;
- (o = ('' + o).toLowerCase()), (_ = !0);
- }
- }
- function slowToString(s, o, i) {
- let u = !1;
- if (((void 0 === o || o < 0) && (o = 0), o > this.length)) return '';
- if (((void 0 === i || i > this.length) && (i = this.length), i <= 0)) return '';
- if ((i >>>= 0) <= (o >>>= 0)) return '';
- for (s || (s = 'utf8'); ; )
- switch (s) {
- case 'hex':
- return hexSlice(this, o, i);
- case 'utf8':
- case 'utf-8':
- return utf8Slice(this, o, i);
- case 'ascii':
- return asciiSlice(this, o, i);
- case 'latin1':
- case 'binary':
- return latin1Slice(this, o, i);
- case 'base64':
- return base64Slice(this, o, i);
- case 'ucs2':
- case 'ucs-2':
- case 'utf16le':
- case 'utf-16le':
- return utf16leSlice(this, o, i);
- default:
- if (u) throw new TypeError('Unknown encoding: ' + s);
- (s = (s + '').toLowerCase()), (u = !0);
- }
- }
- function swap(s, o, i) {
- const u = s[o];
- (s[o] = s[i]), (s[i] = u);
- }
- function bidirectionalIndexOf(s, o, i, u, _) {
- if (0 === s.length) return -1;
- if (
- ('string' == typeof i
- ? ((u = i), (i = 0))
- : i > 2147483647
- ? (i = 2147483647)
- : i < -2147483648 && (i = -2147483648),
- numberIsNaN((i = +i)) && (i = _ ? 0 : s.length - 1),
- i < 0 && (i = s.length + i),
- i >= s.length)
- ) {
- if (_) return -1;
- i = s.length - 1;
- } else if (i < 0) {
- if (!_) return -1;
- i = 0;
- }
- if (('string' == typeof o && (o = Buffer.from(o, u)), Buffer.isBuffer(o)))
- return 0 === o.length ? -1 : arrayIndexOf(s, o, i, u, _);
- if ('number' == typeof o)
- return (
- (o &= 255),
- 'function' == typeof Uint8Array.prototype.indexOf
- ? _
- ? Uint8Array.prototype.indexOf.call(s, o, i)
- : Uint8Array.prototype.lastIndexOf.call(s, o, i)
- : arrayIndexOf(s, [o], i, u, _)
- );
- throw new TypeError('val must be string, number or Buffer');
- }
- function arrayIndexOf(s, o, i, u, _) {
- let w,
- x = 1,
- C = s.length,
- j = o.length;
- if (
- void 0 !== u &&
- ('ucs2' === (u = String(u).toLowerCase()) ||
- 'ucs-2' === u ||
- 'utf16le' === u ||
- 'utf-16le' === u)
- ) {
- if (s.length < 2 || o.length < 2) return -1;
- (x = 2), (C /= 2), (j /= 2), (i /= 2);
- }
- function read(s, o) {
- return 1 === x ? s[o] : s.readUInt16BE(o * x);
- }
- if (_) {
- let u = -1;
- for (w = i; w < C; w++)
- if (read(s, w) === read(o, -1 === u ? 0 : w - u)) {
- if ((-1 === u && (u = w), w - u + 1 === j)) return u * x;
- } else -1 !== u && (w -= w - u), (u = -1);
- } else
- for (i + j > C && (i = C - j), w = i; w >= 0; w--) {
- let i = !0;
- for (let u = 0; u < j; u++)
- if (read(s, w + u) !== read(o, u)) {
- i = !1;
- break;
- }
- if (i) return w;
- }
- return -1;
- }
- function hexWrite(s, o, i, u) {
- i = Number(i) || 0;
- const _ = s.length - i;
- u ? (u = Number(u)) > _ && (u = _) : (u = _);
- const w = o.length;
- let x;
- for (u > w / 2 && (u = w / 2), x = 0; x < u; ++x) {
- const u = parseInt(o.substr(2 * x, 2), 16);
- if (numberIsNaN(u)) return x;
- s[i + x] = u;
- }
- return x;
- }
- function utf8Write(s, o, i, u) {
- return blitBuffer(utf8ToBytes(o, s.length - i), s, i, u);
- }
- function asciiWrite(s, o, i, u) {
- return blitBuffer(
- (function asciiToBytes(s) {
- const o = [];
- for (let i = 0; i < s.length; ++i) o.push(255 & s.charCodeAt(i));
- return o;
- })(o),
- s,
- i,
- u
- );
- }
- function base64Write(s, o, i, u) {
- return blitBuffer(base64ToBytes(o), s, i, u);
- }
- function ucs2Write(s, o, i, u) {
- return blitBuffer(
- (function utf16leToBytes(s, o) {
- let i, u, _;
- const w = [];
- for (let x = 0; x < s.length && !((o -= 2) < 0); ++x)
- (i = s.charCodeAt(x)), (u = i >> 8), (_ = i % 256), w.push(_), w.push(u);
- return w;
- })(o, s.length - i),
- s,
- i,
- u
- );
- }
- function base64Slice(s, o, i) {
- return 0 === o && i === s.length ? u.fromByteArray(s) : u.fromByteArray(s.slice(o, i));
- }
- function utf8Slice(s, o, i) {
- i = Math.min(s.length, i);
- const u = [];
- let _ = o;
- for (; _ < i; ) {
- const o = s[_];
- let w = null,
- x = o > 239 ? 4 : o > 223 ? 3 : o > 191 ? 2 : 1;
- if (_ + x <= i) {
- let i, u, C, j;
- switch (x) {
- case 1:
- o < 128 && (w = o);
- break;
- case 2:
- (i = s[_ + 1]),
- 128 == (192 & i) && ((j = ((31 & o) << 6) | (63 & i)), j > 127 && (w = j));
- break;
- case 3:
- (i = s[_ + 1]),
- (u = s[_ + 2]),
- 128 == (192 & i) &&
- 128 == (192 & u) &&
- ((j = ((15 & o) << 12) | ((63 & i) << 6) | (63 & u)),
- j > 2047 && (j < 55296 || j > 57343) && (w = j));
- break;
- case 4:
- (i = s[_ + 1]),
- (u = s[_ + 2]),
- (C = s[_ + 3]),
- 128 == (192 & i) &&
- 128 == (192 & u) &&
- 128 == (192 & C) &&
- ((j = ((15 & o) << 18) | ((63 & i) << 12) | ((63 & u) << 6) | (63 & C)),
- j > 65535 && j < 1114112 && (w = j));
- }
- }
- null === w
- ? ((w = 65533), (x = 1))
- : w > 65535 &&
- ((w -= 65536), u.push(((w >>> 10) & 1023) | 55296), (w = 56320 | (1023 & w))),
- u.push(w),
- (_ += x);
- }
- return (function decodeCodePointsArray(s) {
- const o = s.length;
- if (o <= C) return String.fromCharCode.apply(String, s);
- let i = '',
- u = 0;
- for (; u < o; ) i += String.fromCharCode.apply(String, s.slice(u, (u += C)));
- return i;
- })(u);
- }
- (o.kMaxLength = x),
- (Buffer.TYPED_ARRAY_SUPPORT = (function typedArraySupport() {
- try {
- const s = new Uint8Array(1),
- o = {
- foo: function () {
- return 42;
- }
- };
- return (
- Object.setPrototypeOf(o, Uint8Array.prototype),
- Object.setPrototypeOf(s, o),
- 42 === s.foo()
- );
- } catch (s) {
- return !1;
- }
- })()),
- Buffer.TYPED_ARRAY_SUPPORT ||
- 'undefined' == typeof console ||
- 'function' != typeof console.error ||
- 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.'
- ),
- Object.defineProperty(Buffer.prototype, 'parent', {
- enumerable: !0,
- get: function () {
- if (Buffer.isBuffer(this)) return this.buffer;
- }
- }),
- Object.defineProperty(Buffer.prototype, 'offset', {
- enumerable: !0,
- get: function () {
- if (Buffer.isBuffer(this)) return this.byteOffset;
- }
- }),
- (Buffer.poolSize = 8192),
- (Buffer.from = function (s, o, i) {
- return from(s, o, i);
- }),
- Object.setPrototypeOf(Buffer.prototype, Uint8Array.prototype),
- Object.setPrototypeOf(Buffer, Uint8Array),
- (Buffer.alloc = function (s, o, i) {
- return (function alloc(s, o, i) {
- return (
- assertSize(s),
- s <= 0
- ? createBuffer(s)
- : void 0 !== o
- ? 'string' == typeof i
- ? createBuffer(s).fill(o, i)
- : createBuffer(s).fill(o)
- : createBuffer(s)
- );
- })(s, o, i);
- }),
- (Buffer.allocUnsafe = function (s) {
- return allocUnsafe(s);
- }),
- (Buffer.allocUnsafeSlow = function (s) {
- return allocUnsafe(s);
- }),
- (Buffer.isBuffer = function isBuffer(s) {
- return null != s && !0 === s._isBuffer && s !== Buffer.prototype;
- }),
- (Buffer.compare = function compare(s, o) {
- if (
- (isInstance(s, Uint8Array) && (s = Buffer.from(s, s.offset, s.byteLength)),
- isInstance(o, Uint8Array) && (o = Buffer.from(o, o.offset, o.byteLength)),
- !Buffer.isBuffer(s) || !Buffer.isBuffer(o))
- )
- throw new TypeError(
- 'The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array'
- );
- if (s === o) return 0;
- let i = s.length,
- u = o.length;
- for (let _ = 0, w = Math.min(i, u); _ < w; ++_)
- if (s[_] !== o[_]) {
- (i = s[_]), (u = o[_]);
- break;
- }
- return i < u ? -1 : u < i ? 1 : 0;
- }),
- (Buffer.isEncoding = function isEncoding(s) {
- switch (String(s).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;
- }
- }),
- (Buffer.concat = function concat(s, o) {
- if (!Array.isArray(s))
- throw new TypeError('"list" argument must be an Array of Buffers');
- if (0 === s.length) return Buffer.alloc(0);
- let i;
- if (void 0 === o) for (o = 0, i = 0; i < s.length; ++i) o += s[i].length;
- const u = Buffer.allocUnsafe(o);
- let _ = 0;
- for (i = 0; i < s.length; ++i) {
- let o = s[i];
- if (isInstance(o, Uint8Array))
- _ + o.length > u.length
- ? (Buffer.isBuffer(o) || (o = Buffer.from(o)), o.copy(u, _))
- : Uint8Array.prototype.set.call(u, o, _);
- else {
- if (!Buffer.isBuffer(o))
- throw new TypeError('"list" argument must be an Array of Buffers');
- o.copy(u, _);
- }
- _ += o.length;
- }
- return u;
- }),
- (Buffer.byteLength = byteLength),
- (Buffer.prototype._isBuffer = !0),
- (Buffer.prototype.swap16 = function swap16() {
- const s = this.length;
- if (s % 2 != 0) throw new RangeError('Buffer size must be a multiple of 16-bits');
- for (let o = 0; o < s; o += 2) swap(this, o, o + 1);
- return this;
- }),
- (Buffer.prototype.swap32 = function swap32() {
- const s = this.length;
- if (s % 4 != 0) throw new RangeError('Buffer size must be a multiple of 32-bits');
- for (let o = 0; o < s; o += 4) swap(this, o, o + 3), swap(this, o + 1, o + 2);
- return this;
- }),
- (Buffer.prototype.swap64 = function swap64() {
- const s = this.length;
- if (s % 8 != 0) throw new RangeError('Buffer size must be a multiple of 64-bits');
- for (let o = 0; o < s; o += 8)
- swap(this, o, o + 7),
- swap(this, o + 1, o + 6),
- swap(this, o + 2, o + 5),
- swap(this, o + 3, o + 4);
- return this;
- }),
- (Buffer.prototype.toString = function toString() {
- const s = this.length;
- return 0 === s
- ? ''
- : 0 === arguments.length
- ? utf8Slice(this, 0, s)
- : slowToString.apply(this, arguments);
- }),
- (Buffer.prototype.toLocaleString = Buffer.prototype.toString),
- (Buffer.prototype.equals = function equals(s) {
- if (!Buffer.isBuffer(s)) throw new TypeError('Argument must be a Buffer');
- return this === s || 0 === Buffer.compare(this, s);
- }),
- (Buffer.prototype.inspect = function inspect() {
- let s = '';
- const i = o.INSPECT_MAX_BYTES;
- return (
- (s = this.toString('hex', 0, i)
- .replace(/(.{2})/g, '$1 ')
- .trim()),
- this.length > i && (s += ' ... '),
- '<Buffer ' + s + '>'
- );
- }),
- w && (Buffer.prototype[w] = Buffer.prototype.inspect),
- (Buffer.prototype.compare = function compare(s, o, i, u, _) {
- if (
- (isInstance(s, Uint8Array) && (s = Buffer.from(s, s.offset, s.byteLength)),
- !Buffer.isBuffer(s))
- )
- throw new TypeError(
- 'The "target" argument must be one of type Buffer or Uint8Array. Received type ' +
- typeof s
- );
- if (
- (void 0 === o && (o = 0),
- void 0 === i && (i = s ? s.length : 0),
- void 0 === u && (u = 0),
- void 0 === _ && (_ = this.length),
- o < 0 || i > s.length || u < 0 || _ > this.length)
- )
- throw new RangeError('out of range index');
- if (u >= _ && o >= i) return 0;
- if (u >= _) return -1;
- if (o >= i) return 1;
- if (this === s) return 0;
- let w = (_ >>>= 0) - (u >>>= 0),
- x = (i >>>= 0) - (o >>>= 0);
- const C = Math.min(w, x),
- j = this.slice(u, _),
- L = s.slice(o, i);
- for (let s = 0; s < C; ++s)
- if (j[s] !== L[s]) {
- (w = j[s]), (x = L[s]);
- break;
- }
- return w < x ? -1 : x < w ? 1 : 0;
- }),
- (Buffer.prototype.includes = function includes(s, o, i) {
- return -1 !== this.indexOf(s, o, i);
- }),
- (Buffer.prototype.indexOf = function indexOf(s, o, i) {
- return bidirectionalIndexOf(this, s, o, i, !0);
- }),
- (Buffer.prototype.lastIndexOf = function lastIndexOf(s, o, i) {
- return bidirectionalIndexOf(this, s, o, i, !1);
- }),
- (Buffer.prototype.write = function write(s, o, i, u) {
- if (void 0 === o) (u = 'utf8'), (i = this.length), (o = 0);
- else if (void 0 === i && 'string' == typeof o) (u = o), (i = this.length), (o = 0);
- else {
- if (!isFinite(o))
- throw new Error(
- 'Buffer.write(string, encoding, offset[, length]) is no longer supported'
- );
- (o >>>= 0),
- isFinite(i)
- ? ((i >>>= 0), void 0 === u && (u = 'utf8'))
- : ((u = i), (i = void 0));
- }
- const _ = this.length - o;
- if (
- ((void 0 === i || i > _) && (i = _),
- (s.length > 0 && (i < 0 || o < 0)) || o > this.length)
- )
- throw new RangeError('Attempt to write outside buffer bounds');
- u || (u = 'utf8');
- let w = !1;
- for (;;)
- switch (u) {
- case 'hex':
- return hexWrite(this, s, o, i);
- case 'utf8':
- case 'utf-8':
- return utf8Write(this, s, o, i);
- case 'ascii':
- case 'latin1':
- case 'binary':
- return asciiWrite(this, s, o, i);
- case 'base64':
- return base64Write(this, s, o, i);
- case 'ucs2':
- case 'ucs-2':
- case 'utf16le':
- case 'utf-16le':
- return ucs2Write(this, s, o, i);
- default:
- if (w) throw new TypeError('Unknown encoding: ' + u);
- (u = ('' + u).toLowerCase()), (w = !0);
- }
- }),
- (Buffer.prototype.toJSON = function toJSON() {
- return { type: 'Buffer', data: Array.prototype.slice.call(this._arr || this, 0) };
- });
- const C = 4096;
- function asciiSlice(s, o, i) {
- let u = '';
- i = Math.min(s.length, i);
- for (let _ = o; _ < i; ++_) u += String.fromCharCode(127 & s[_]);
- return u;
- }
- function latin1Slice(s, o, i) {
- let u = '';
- i = Math.min(s.length, i);
- for (let _ = o; _ < i; ++_) u += String.fromCharCode(s[_]);
- return u;
- }
- function hexSlice(s, o, i) {
- const u = s.length;
- (!o || o < 0) && (o = 0), (!i || i < 0 || i > u) && (i = u);
- let _ = '';
- for (let u = o; u < i; ++u) _ += B[s[u]];
- return _;
- }
- function utf16leSlice(s, o, i) {
- const u = s.slice(o, i);
- let _ = '';
- for (let s = 0; s < u.length - 1; s += 2)
- _ += String.fromCharCode(u[s] + 256 * u[s + 1]);
- return _;
- }
- function checkOffset(s, o, i) {
- if (s % 1 != 0 || s < 0) throw new RangeError('offset is not uint');
- if (s + o > i) throw new RangeError('Trying to access beyond buffer length');
- }
- function checkInt(s, o, i, u, _, w) {
- if (!Buffer.isBuffer(s))
- throw new TypeError('"buffer" argument must be a Buffer instance');
- if (o > _ || o < w) throw new RangeError('"value" argument is out of bounds');
- if (i + u > s.length) throw new RangeError('Index out of range');
- }
- function wrtBigUInt64LE(s, o, i, u, _) {
- checkIntBI(o, u, _, s, i, 7);
- let w = Number(o & BigInt(4294967295));
- (s[i++] = w), (w >>= 8), (s[i++] = w), (w >>= 8), (s[i++] = w), (w >>= 8), (s[i++] = w);
- let x = Number((o >> BigInt(32)) & BigInt(4294967295));
- return (
- (s[i++] = x),
- (x >>= 8),
- (s[i++] = x),
- (x >>= 8),
- (s[i++] = x),
- (x >>= 8),
- (s[i++] = x),
- i
- );
- }
- function wrtBigUInt64BE(s, o, i, u, _) {
- checkIntBI(o, u, _, s, i, 7);
- let w = Number(o & BigInt(4294967295));
- (s[i + 7] = w),
- (w >>= 8),
- (s[i + 6] = w),
- (w >>= 8),
- (s[i + 5] = w),
- (w >>= 8),
- (s[i + 4] = w);
- let x = Number((o >> BigInt(32)) & BigInt(4294967295));
- return (
- (s[i + 3] = x),
- (x >>= 8),
- (s[i + 2] = x),
- (x >>= 8),
- (s[i + 1] = x),
- (x >>= 8),
- (s[i] = x),
- i + 8
- );
- }
- function checkIEEE754(s, o, i, u, _, w) {
- if (i + u > s.length) throw new RangeError('Index out of range');
- if (i < 0) throw new RangeError('Index out of range');
- }
- function writeFloat(s, o, i, u, w) {
- return (
- (o = +o), (i >>>= 0), w || checkIEEE754(s, 0, i, 4), _.write(s, o, i, u, 23, 4), i + 4
- );
- }
- function writeDouble(s, o, i, u, w) {
- return (
- (o = +o), (i >>>= 0), w || checkIEEE754(s, 0, i, 8), _.write(s, o, i, u, 52, 8), i + 8
- );
- }
- (Buffer.prototype.slice = function slice(s, o) {
- const i = this.length;
- (s = ~~s) < 0 ? (s += i) < 0 && (s = 0) : s > i && (s = i),
- (o = void 0 === o ? i : ~~o) < 0 ? (o += i) < 0 && (o = 0) : o > i && (o = i),
- o < s && (o = s);
- const u = this.subarray(s, o);
- return Object.setPrototypeOf(u, Buffer.prototype), u;
- }),
- (Buffer.prototype.readUintLE = Buffer.prototype.readUIntLE =
- function readUIntLE(s, o, i) {
- (s >>>= 0), (o >>>= 0), i || checkOffset(s, o, this.length);
- let u = this[s],
- _ = 1,
- w = 0;
- for (; ++w < o && (_ *= 256); ) u += this[s + w] * _;
- return u;
- }),
- (Buffer.prototype.readUintBE = Buffer.prototype.readUIntBE =
- function readUIntBE(s, o, i) {
- (s >>>= 0), (o >>>= 0), i || checkOffset(s, o, this.length);
- let u = this[s + --o],
- _ = 1;
- for (; o > 0 && (_ *= 256); ) u += this[s + --o] * _;
- return u;
- }),
- (Buffer.prototype.readUint8 = Buffer.prototype.readUInt8 =
- function readUInt8(s, o) {
- return (s >>>= 0), o || checkOffset(s, 1, this.length), this[s];
- }),
- (Buffer.prototype.readUint16LE = Buffer.prototype.readUInt16LE =
- function readUInt16LE(s, o) {
- return (
- (s >>>= 0), o || checkOffset(s, 2, this.length), this[s] | (this[s + 1] << 8)
- );
- }),
- (Buffer.prototype.readUint16BE = Buffer.prototype.readUInt16BE =
- function readUInt16BE(s, o) {
- return (
- (s >>>= 0), o || checkOffset(s, 2, this.length), (this[s] << 8) | this[s + 1]
- );
- }),
- (Buffer.prototype.readUint32LE = Buffer.prototype.readUInt32LE =
- function readUInt32LE(s, o) {
- return (
- (s >>>= 0),
- o || checkOffset(s, 4, this.length),
- (this[s] | (this[s + 1] << 8) | (this[s + 2] << 16)) + 16777216 * this[s + 3]
- );
- }),
- (Buffer.prototype.readUint32BE = Buffer.prototype.readUInt32BE =
- function readUInt32BE(s, o) {
- return (
- (s >>>= 0),
- o || checkOffset(s, 4, this.length),
- 16777216 * this[s] + ((this[s + 1] << 16) | (this[s + 2] << 8) | this[s + 3])
- );
- }),
- (Buffer.prototype.readBigUInt64LE = defineBigIntMethod(function readBigUInt64LE(s) {
- validateNumber((s >>>= 0), 'offset');
- const o = this[s],
- i = this[s + 7];
- (void 0 !== o && void 0 !== i) || boundsError(s, this.length - 8);
- const u = o + 256 * this[++s] + 65536 * this[++s] + this[++s] * 2 ** 24,
- _ = this[++s] + 256 * this[++s] + 65536 * this[++s] + i * 2 ** 24;
- return BigInt(u) + (BigInt(_) << BigInt(32));
- })),
- (Buffer.prototype.readBigUInt64BE = defineBigIntMethod(function readBigUInt64BE(s) {
- validateNumber((s >>>= 0), 'offset');
- const o = this[s],
- i = this[s + 7];
- (void 0 !== o && void 0 !== i) || boundsError(s, this.length - 8);
- const u = o * 2 ** 24 + 65536 * this[++s] + 256 * this[++s] + this[++s],
- _ = this[++s] * 2 ** 24 + 65536 * this[++s] + 256 * this[++s] + i;
- return (BigInt(u) << BigInt(32)) + BigInt(_);
- })),
- (Buffer.prototype.readIntLE = function readIntLE(s, o, i) {
- (s >>>= 0), (o >>>= 0), i || checkOffset(s, o, this.length);
- let u = this[s],
- _ = 1,
- w = 0;
- for (; ++w < o && (_ *= 256); ) u += this[s + w] * _;
- return (_ *= 128), u >= _ && (u -= Math.pow(2, 8 * o)), u;
- }),
- (Buffer.prototype.readIntBE = function readIntBE(s, o, i) {
- (s >>>= 0), (o >>>= 0), i || checkOffset(s, o, this.length);
- let u = o,
- _ = 1,
- w = this[s + --u];
- for (; u > 0 && (_ *= 256); ) w += this[s + --u] * _;
- return (_ *= 128), w >= _ && (w -= Math.pow(2, 8 * o)), w;
- }),
- (Buffer.prototype.readInt8 = function readInt8(s, o) {
- return (
- (s >>>= 0),
- o || checkOffset(s, 1, this.length),
- 128 & this[s] ? -1 * (255 - this[s] + 1) : this[s]
- );
- }),
- (Buffer.prototype.readInt16LE = function readInt16LE(s, o) {
- (s >>>= 0), o || checkOffset(s, 2, this.length);
- const i = this[s] | (this[s + 1] << 8);
- return 32768 & i ? 4294901760 | i : i;
- }),
- (Buffer.prototype.readInt16BE = function readInt16BE(s, o) {
- (s >>>= 0), o || checkOffset(s, 2, this.length);
- const i = this[s + 1] | (this[s] << 8);
- return 32768 & i ? 4294901760 | i : i;
- }),
- (Buffer.prototype.readInt32LE = function readInt32LE(s, o) {
- return (
- (s >>>= 0),
- o || checkOffset(s, 4, this.length),
- this[s] | (this[s + 1] << 8) | (this[s + 2] << 16) | (this[s + 3] << 24)
- );
- }),
- (Buffer.prototype.readInt32BE = function readInt32BE(s, o) {
- return (
- (s >>>= 0),
- o || checkOffset(s, 4, this.length),
- (this[s] << 24) | (this[s + 1] << 16) | (this[s + 2] << 8) | this[s + 3]
- );
- }),
- (Buffer.prototype.readBigInt64LE = defineBigIntMethod(function readBigInt64LE(s) {
- validateNumber((s >>>= 0), 'offset');
- const o = this[s],
- i = this[s + 7];
- (void 0 !== o && void 0 !== i) || boundsError(s, this.length - 8);
- const u = this[s + 4] + 256 * this[s + 5] + 65536 * this[s + 6] + (i << 24);
- return (
- (BigInt(u) << BigInt(32)) +
- BigInt(o + 256 * this[++s] + 65536 * this[++s] + this[++s] * 2 ** 24)
- );
- })),
- (Buffer.prototype.readBigInt64BE = defineBigIntMethod(function readBigInt64BE(s) {
- validateNumber((s >>>= 0), 'offset');
- const o = this[s],
- i = this[s + 7];
- (void 0 !== o && void 0 !== i) || boundsError(s, this.length - 8);
- const u = (o << 24) + 65536 * this[++s] + 256 * this[++s] + this[++s];
- return (
- (BigInt(u) << BigInt(32)) +
- BigInt(this[++s] * 2 ** 24 + 65536 * this[++s] + 256 * this[++s] + i)
- );
- })),
- (Buffer.prototype.readFloatLE = function readFloatLE(s, o) {
- return (s >>>= 0), o || checkOffset(s, 4, this.length), _.read(this, s, !0, 23, 4);
- }),
- (Buffer.prototype.readFloatBE = function readFloatBE(s, o) {
- return (s >>>= 0), o || checkOffset(s, 4, this.length), _.read(this, s, !1, 23, 4);
- }),
- (Buffer.prototype.readDoubleLE = function readDoubleLE(s, o) {
- return (s >>>= 0), o || checkOffset(s, 8, this.length), _.read(this, s, !0, 52, 8);
- }),
- (Buffer.prototype.readDoubleBE = function readDoubleBE(s, o) {
- return (s >>>= 0), o || checkOffset(s, 8, this.length), _.read(this, s, !1, 52, 8);
- }),
- (Buffer.prototype.writeUintLE = Buffer.prototype.writeUIntLE =
- function writeUIntLE(s, o, i, u) {
- if (((s = +s), (o >>>= 0), (i >>>= 0), !u)) {
- checkInt(this, s, o, i, Math.pow(2, 8 * i) - 1, 0);
- }
- let _ = 1,
- w = 0;
- for (this[o] = 255 & s; ++w < i && (_ *= 256); ) this[o + w] = (s / _) & 255;
- return o + i;
- }),
- (Buffer.prototype.writeUintBE = Buffer.prototype.writeUIntBE =
- function writeUIntBE(s, o, i, u) {
- if (((s = +s), (o >>>= 0), (i >>>= 0), !u)) {
- checkInt(this, s, o, i, Math.pow(2, 8 * i) - 1, 0);
- }
- let _ = i - 1,
- w = 1;
- for (this[o + _] = 255 & s; --_ >= 0 && (w *= 256); ) this[o + _] = (s / w) & 255;
- return o + i;
- }),
- (Buffer.prototype.writeUint8 = Buffer.prototype.writeUInt8 =
- function writeUInt8(s, o, i) {
- return (
- (s = +s),
- (o >>>= 0),
- i || checkInt(this, s, o, 1, 255, 0),
- (this[o] = 255 & s),
- o + 1
- );
- }),
- (Buffer.prototype.writeUint16LE = Buffer.prototype.writeUInt16LE =
- function writeUInt16LE(s, o, i) {
- return (
- (s = +s),
- (o >>>= 0),
- i || checkInt(this, s, o, 2, 65535, 0),
- (this[o] = 255 & s),
- (this[o + 1] = s >>> 8),
- o + 2
- );
- }),
- (Buffer.prototype.writeUint16BE = Buffer.prototype.writeUInt16BE =
- function writeUInt16BE(s, o, i) {
- return (
- (s = +s),
- (o >>>= 0),
- i || checkInt(this, s, o, 2, 65535, 0),
- (this[o] = s >>> 8),
- (this[o + 1] = 255 & s),
- o + 2
- );
- }),
- (Buffer.prototype.writeUint32LE = Buffer.prototype.writeUInt32LE =
- function writeUInt32LE(s, o, i) {
- return (
- (s = +s),
- (o >>>= 0),
- i || checkInt(this, s, o, 4, 4294967295, 0),
- (this[o + 3] = s >>> 24),
- (this[o + 2] = s >>> 16),
- (this[o + 1] = s >>> 8),
- (this[o] = 255 & s),
- o + 4
- );
- }),
- (Buffer.prototype.writeUint32BE = Buffer.prototype.writeUInt32BE =
- function writeUInt32BE(s, o, i) {
- return (
- (s = +s),
- (o >>>= 0),
- i || checkInt(this, s, o, 4, 4294967295, 0),
- (this[o] = s >>> 24),
- (this[o + 1] = s >>> 16),
- (this[o + 2] = s >>> 8),
- (this[o + 3] = 255 & s),
- o + 4
- );
- }),
- (Buffer.prototype.writeBigUInt64LE = defineBigIntMethod(function writeBigUInt64LE(
- s,
- o = 0
- ) {
- return wrtBigUInt64LE(this, s, o, BigInt(0), BigInt('0xffffffffffffffff'));
- })),
- (Buffer.prototype.writeBigUInt64BE = defineBigIntMethod(function writeBigUInt64BE(
- s,
- o = 0
- ) {
- return wrtBigUInt64BE(this, s, o, BigInt(0), BigInt('0xffffffffffffffff'));
- })),
- (Buffer.prototype.writeIntLE = function writeIntLE(s, o, i, u) {
- if (((s = +s), (o >>>= 0), !u)) {
- const u = Math.pow(2, 8 * i - 1);
- checkInt(this, s, o, i, u - 1, -u);
- }
- let _ = 0,
- w = 1,
- x = 0;
- for (this[o] = 255 & s; ++_ < i && (w *= 256); )
- s < 0 && 0 === x && 0 !== this[o + _ - 1] && (x = 1),
- (this[o + _] = (((s / w) | 0) - x) & 255);
- return o + i;
- }),
- (Buffer.prototype.writeIntBE = function writeIntBE(s, o, i, u) {
- if (((s = +s), (o >>>= 0), !u)) {
- const u = Math.pow(2, 8 * i - 1);
- checkInt(this, s, o, i, u - 1, -u);
- }
- let _ = i - 1,
- w = 1,
- x = 0;
- for (this[o + _] = 255 & s; --_ >= 0 && (w *= 256); )
- s < 0 && 0 === x && 0 !== this[o + _ + 1] && (x = 1),
- (this[o + _] = (((s / w) | 0) - x) & 255);
- return o + i;
- }),
- (Buffer.prototype.writeInt8 = function writeInt8(s, o, i) {
- return (
- (s = +s),
- (o >>>= 0),
- i || checkInt(this, s, o, 1, 127, -128),
- s < 0 && (s = 255 + s + 1),
- (this[o] = 255 & s),
- o + 1
- );
- }),
- (Buffer.prototype.writeInt16LE = function writeInt16LE(s, o, i) {
- return (
- (s = +s),
- (o >>>= 0),
- i || checkInt(this, s, o, 2, 32767, -32768),
- (this[o] = 255 & s),
- (this[o + 1] = s >>> 8),
- o + 2
- );
- }),
- (Buffer.prototype.writeInt16BE = function writeInt16BE(s, o, i) {
- return (
- (s = +s),
- (o >>>= 0),
- i || checkInt(this, s, o, 2, 32767, -32768),
- (this[o] = s >>> 8),
- (this[o + 1] = 255 & s),
- o + 2
- );
- }),
- (Buffer.prototype.writeInt32LE = function writeInt32LE(s, o, i) {
- return (
- (s = +s),
- (o >>>= 0),
- i || checkInt(this, s, o, 4, 2147483647, -2147483648),
- (this[o] = 255 & s),
- (this[o + 1] = s >>> 8),
- (this[o + 2] = s >>> 16),
- (this[o + 3] = s >>> 24),
- o + 4
- );
- }),
- (Buffer.prototype.writeInt32BE = function writeInt32BE(s, o, i) {
- return (
- (s = +s),
- (o >>>= 0),
- i || checkInt(this, s, o, 4, 2147483647, -2147483648),
- s < 0 && (s = 4294967295 + s + 1),
- (this[o] = s >>> 24),
- (this[o + 1] = s >>> 16),
- (this[o + 2] = s >>> 8),
- (this[o + 3] = 255 & s),
- o + 4
- );
- }),
- (Buffer.prototype.writeBigInt64LE = defineBigIntMethod(function writeBigInt64LE(
- s,
- o = 0
- ) {
- return wrtBigUInt64LE(
- this,
- s,
- o,
- -BigInt('0x8000000000000000'),
- BigInt('0x7fffffffffffffff')
- );
- })),
- (Buffer.prototype.writeBigInt64BE = defineBigIntMethod(function writeBigInt64BE(
- s,
- o = 0
- ) {
- return wrtBigUInt64BE(
- this,
- s,
- o,
- -BigInt('0x8000000000000000'),
- BigInt('0x7fffffffffffffff')
- );
- })),
- (Buffer.prototype.writeFloatLE = function writeFloatLE(s, o, i) {
- return writeFloat(this, s, o, !0, i);
- }),
- (Buffer.prototype.writeFloatBE = function writeFloatBE(s, o, i) {
- return writeFloat(this, s, o, !1, i);
- }),
- (Buffer.prototype.writeDoubleLE = function writeDoubleLE(s, o, i) {
- return writeDouble(this, s, o, !0, i);
- }),
- (Buffer.prototype.writeDoubleBE = function writeDoubleBE(s, o, i) {
- return writeDouble(this, s, o, !1, i);
- }),
- (Buffer.prototype.copy = function copy(s, o, i, u) {
- if (!Buffer.isBuffer(s)) throw new TypeError('argument should be a Buffer');
- if (
- (i || (i = 0),
- u || 0 === u || (u = this.length),
- o >= s.length && (o = s.length),
- o || (o = 0),
- u > 0 && u < i && (u = i),
- u === i)
- )
- return 0;
- if (0 === s.length || 0 === this.length) return 0;
- if (o < 0) throw new RangeError('targetStart out of bounds');
- if (i < 0 || i >= this.length) throw new RangeError('Index out of range');
- if (u < 0) throw new RangeError('sourceEnd out of bounds');
- u > this.length && (u = this.length), s.length - o < u - i && (u = s.length - o + i);
- const _ = u - i;
- return (
- this === s && 'function' == typeof Uint8Array.prototype.copyWithin
- ? this.copyWithin(o, i, u)
- : Uint8Array.prototype.set.call(s, this.subarray(i, u), o),
- _
- );
- }),
- (Buffer.prototype.fill = function fill(s, o, i, u) {
- if ('string' == typeof s) {
- if (
- ('string' == typeof o
- ? ((u = o), (o = 0), (i = this.length))
- : 'string' == typeof i && ((u = i), (i = this.length)),
- void 0 !== u && 'string' != typeof u)
- )
- throw new TypeError('encoding must be a string');
- if ('string' == typeof u && !Buffer.isEncoding(u))
- throw new TypeError('Unknown encoding: ' + u);
- if (1 === s.length) {
- const o = s.charCodeAt(0);
- (('utf8' === u && o < 128) || 'latin1' === u) && (s = o);
- }
- } else 'number' == typeof s ? (s &= 255) : 'boolean' == typeof s && (s = Number(s));
- if (o < 0 || this.length < o || this.length < i)
- throw new RangeError('Out of range index');
- if (i <= o) return this;
- let _;
- if (
- ((o >>>= 0),
- (i = void 0 === i ? this.length : i >>> 0),
- s || (s = 0),
- 'number' == typeof s)
- )
- for (_ = o; _ < i; ++_) this[_] = s;
- else {
- const w = Buffer.isBuffer(s) ? s : Buffer.from(s, u),
- x = w.length;
- if (0 === x)
- throw new TypeError('The value "' + s + '" is invalid for argument "value"');
- for (_ = 0; _ < i - o; ++_) this[_ + o] = w[_ % x];
- }
- return this;
- });
- const j = {};
- function E(s, o, i) {
- j[s] = class NodeError extends i {
- constructor() {
- super(),
- Object.defineProperty(this, 'message', {
- value: o.apply(this, arguments),
- writable: !0,
- configurable: !0
- }),
- (this.name = `${this.name} [${s}]`),
- this.stack,
- delete this.name;
- }
- get code() {
- return s;
- }
- set code(s) {
- Object.defineProperty(this, 'code', {
- configurable: !0,
- enumerable: !0,
- value: s,
- writable: !0
- });
- }
- toString() {
- return `${this.name} [${s}]: ${this.message}`;
- }
- };
- }
- function addNumericalSeparator(s) {
- let o = '',
- i = s.length;
- const u = '-' === s[0] ? 1 : 0;
- for (; i >= u + 4; i -= 3) o = `_${s.slice(i - 3, i)}${o}`;
- return `${s.slice(0, i)}${o}`;
- }
- function checkIntBI(s, o, i, u, _, w) {
- if (s > i || s < o) {
- const u = 'bigint' == typeof o ? 'n' : '';
- let _;
- throw (
- ((_ =
- w > 3
- ? 0 === o || o === BigInt(0)
- ? `>= 0${u} and < 2${u} ** ${8 * (w + 1)}${u}`
- : `>= -(2${u} ** ${8 * (w + 1) - 1}${u}) and < 2 ** ${8 * (w + 1) - 1}${u}`
- : `>= ${o}${u} and <= ${i}${u}`),
- new j.ERR_OUT_OF_RANGE('value', _, s))
- );
- }
- !(function checkBounds(s, o, i) {
- validateNumber(o, 'offset'),
- (void 0 !== s[o] && void 0 !== s[o + i]) || boundsError(o, s.length - (i + 1));
- })(u, _, w);
- }
- function validateNumber(s, o) {
- if ('number' != typeof s) throw new j.ERR_INVALID_ARG_TYPE(o, 'number', s);
- }
- function boundsError(s, o, i) {
- if (Math.floor(s) !== s)
- throw (validateNumber(s, i), new j.ERR_OUT_OF_RANGE(i || 'offset', 'an integer', s));
- if (o < 0) throw new j.ERR_BUFFER_OUT_OF_BOUNDS();
- throw new j.ERR_OUT_OF_RANGE(i || 'offset', `>= ${i ? 1 : 0} and <= ${o}`, s);
- }
- E(
- 'ERR_BUFFER_OUT_OF_BOUNDS',
- function (s) {
- return s
- ? `${s} is outside of buffer bounds`
- : 'Attempt to access memory outside buffer bounds';
- },
- RangeError
- ),
- E(
- 'ERR_INVALID_ARG_TYPE',
- function (s, o) {
- return `The "${s}" argument must be of type number. Received type ${typeof o}`;
- },
- TypeError
- ),
- E(
- 'ERR_OUT_OF_RANGE',
- function (s, o, i) {
- let u = `The value of "${s}" is out of range.`,
- _ = i;
- return (
- Number.isInteger(i) && Math.abs(i) > 2 ** 32
- ? (_ = addNumericalSeparator(String(i)))
- : 'bigint' == typeof i &&
- ((_ = String(i)),
- (i > BigInt(2) ** BigInt(32) || i < -(BigInt(2) ** BigInt(32))) &&
- (_ = addNumericalSeparator(_)),
- (_ += 'n')),
- (u += ` It must be ${o}. Received ${_}`),
- u
- );
- },
- RangeError
- );
- const L = /[^+/0-9A-Za-z-_]/g;
- function utf8ToBytes(s, o) {
- let i;
- o = o || 1 / 0;
- const u = s.length;
- let _ = null;
- const w = [];
- for (let x = 0; x < u; ++x) {
- if (((i = s.charCodeAt(x)), i > 55295 && i < 57344)) {
- if (!_) {
- if (i > 56319) {
- (o -= 3) > -1 && w.push(239, 191, 189);
- continue;
- }
- if (x + 1 === u) {
- (o -= 3) > -1 && w.push(239, 191, 189);
- continue;
- }
- _ = i;
- continue;
- }
- if (i < 56320) {
- (o -= 3) > -1 && w.push(239, 191, 189), (_ = i);
- continue;
- }
- i = 65536 + (((_ - 55296) << 10) | (i - 56320));
- } else _ && (o -= 3) > -1 && w.push(239, 191, 189);
- if (((_ = null), i < 128)) {
- if ((o -= 1) < 0) break;
- w.push(i);
- } else if (i < 2048) {
- if ((o -= 2) < 0) break;
- w.push((i >> 6) | 192, (63 & i) | 128);
- } else if (i < 65536) {
- if ((o -= 3) < 0) break;
- w.push((i >> 12) | 224, ((i >> 6) & 63) | 128, (63 & i) | 128);
- } else {
- if (!(i < 1114112)) throw new Error('Invalid code point');
- if ((o -= 4) < 0) break;
- w.push(
- (i >> 18) | 240,
- ((i >> 12) & 63) | 128,
- ((i >> 6) & 63) | 128,
- (63 & i) | 128
- );
- }
- }
- return w;
- }
- function base64ToBytes(s) {
- return u.toByteArray(
- (function base64clean(s) {
- if ((s = (s = s.split('=')[0]).trim().replace(L, '')).length < 2) return '';
- for (; s.length % 4 != 0; ) s += '=';
- return s;
- })(s)
- );
- }
- function blitBuffer(s, o, i, u) {
- let _;
- for (_ = 0; _ < u && !(_ + i >= o.length || _ >= s.length); ++_) o[_ + i] = s[_];
- return _;
- }
- function isInstance(s, o) {
- return (
- s instanceof o ||
- (null != s &&
- null != s.constructor &&
- null != s.constructor.name &&
- s.constructor.name === o.name)
- );
- }
- function numberIsNaN(s) {
- return s != s;
- }
- const B = (function () {
- const s = '0123456789abcdef',
- o = new Array(256);
- for (let i = 0; i < 16; ++i) {
- const u = 16 * i;
- for (let _ = 0; _ < 16; ++_) o[u + _] = s[i] + s[_];
- }
- return o;
- })();
- function defineBigIntMethod(s) {
- return 'undefined' == typeof BigInt ? BufferBigIntNotDefined : s;
- }
- function BufferBigIntNotDefined() {
- throw new Error('BigInt not supported');
- }
- },
- 17965: (s, o, i) => {
- 'use strict';
- var u = i(16426),
- _ = { 'text/plain': 'Text', 'text/html': 'Url', default: 'Text' };
- s.exports = function copy(s, o) {
- var i,
- w,
- x,
- C,
- j,
- L,
- B = !1;
- o || (o = {}), (i = o.debug || !1);
- try {
- if (
- ((x = u()),
- (C = document.createRange()),
- (j = document.getSelection()),
- ((L = document.createElement('span')).textContent = s),
- (L.ariaHidden = 'true'),
- (L.style.all = 'unset'),
- (L.style.position = 'fixed'),
- (L.style.top = 0),
- (L.style.clip = 'rect(0, 0, 0, 0)'),
- (L.style.whiteSpace = 'pre'),
- (L.style.webkitUserSelect = 'text'),
- (L.style.MozUserSelect = 'text'),
- (L.style.msUserSelect = 'text'),
- (L.style.userSelect = 'text'),
- L.addEventListener('copy', function (u) {
- if ((u.stopPropagation(), o.format))
- if ((u.preventDefault(), void 0 === u.clipboardData)) {
- i && console.warn('unable to use e.clipboardData'),
- i && console.warn('trying IE specific stuff'),
- window.clipboardData.clearData();
- var w = _[o.format] || _.default;
- window.clipboardData.setData(w, s);
- } else u.clipboardData.clearData(), u.clipboardData.setData(o.format, s);
- o.onCopy && (u.preventDefault(), o.onCopy(u.clipboardData));
- }),
- document.body.appendChild(L),
- C.selectNodeContents(L),
- j.addRange(C),
- !document.execCommand('copy'))
- )
- throw new Error('copy command was unsuccessful');
- B = !0;
- } catch (u) {
- i && console.error('unable to copy using execCommand: ', u),
- i && console.warn('trying IE specific stuff');
- try {
- window.clipboardData.setData(o.format || 'text', s),
- o.onCopy && o.onCopy(window.clipboardData),
- (B = !0);
- } catch (u) {
- i && console.error('unable to copy using clipboardData: ', u),
- i && console.error('falling back to prompt'),
- (w = (function format(s) {
- var o = (/mac os x/i.test(navigator.userAgent) ? '⌘' : 'Ctrl') + '+C';
- return s.replace(/#{\s*key\s*}/g, o);
- })('message' in o ? o.message : 'Copy to clipboard: #{key}, Enter')),
- window.prompt(w, s);
- }
- } finally {
- j && ('function' == typeof j.removeRange ? j.removeRange(C) : j.removeAllRanges()),
- L && document.body.removeChild(L),
- x();
- }
- return B;
- };
- },
- 2205: function (s, o, i) {
- var u;
- (u = void 0 !== i.g ? i.g : this),
- (s.exports = (function (s) {
- if (s.CSS && s.CSS.escape) return s.CSS.escape;
- var cssEscape = function (s) {
- if (0 == arguments.length)
- throw new TypeError('`CSS.escape` requires an argument.');
- for (
- var o, i = String(s), u = i.length, _ = -1, w = '', x = i.charCodeAt(0);
- ++_ < u;
- )
- 0 != (o = i.charCodeAt(_))
- ? (w +=
- (o >= 1 && o <= 31) ||
- 127 == o ||
- (0 == _ && o >= 48 && o <= 57) ||
- (1 == _ && o >= 48 && o <= 57 && 45 == x)
- ? '\\' + o.toString(16) + ' '
- : (0 == _ && 1 == u && 45 == o) ||
- !(
- o >= 128 ||
- 45 == o ||
- 95 == o ||
- (o >= 48 && o <= 57) ||
- (o >= 65 && o <= 90) ||
- (o >= 97 && o <= 122)
- )
- ? '\\' + i.charAt(_)
- : i.charAt(_))
- : (w += '�');
- return w;
- };
- return s.CSS || (s.CSS = {}), (s.CSS.escape = cssEscape), cssEscape;
- })(u));
- },
- 81919: (s, o, i) => {
- 'use strict';
- var u = i(48287).Buffer;
- function isSpecificValue(s) {
- return s instanceof u || s instanceof Date || s instanceof RegExp;
- }
- function cloneSpecificValue(s) {
- if (s instanceof u) {
- var o = u.alloc ? u.alloc(s.length) : new u(s.length);
- return s.copy(o), o;
- }
- if (s instanceof Date) return new Date(s.getTime());
- if (s instanceof RegExp) return new RegExp(s);
- throw new Error('Unexpected situation');
- }
- function deepCloneArray(s) {
- var o = [];
- return (
- s.forEach(function (s, i) {
- 'object' == typeof s && null !== s
- ? Array.isArray(s)
- ? (o[i] = deepCloneArray(s))
- : isSpecificValue(s)
- ? (o[i] = cloneSpecificValue(s))
- : (o[i] = _({}, s))
- : (o[i] = s);
- }),
- o
- );
- }
- function safeGetProperty(s, o) {
- return '__proto__' === o ? void 0 : s[o];
- }
- var _ = (s.exports = function () {
- if (arguments.length < 1 || 'object' != typeof arguments[0]) return !1;
- if (arguments.length < 2) return arguments[0];
- var s,
- o,
- i = arguments[0];
- return (
- Array.prototype.slice.call(arguments, 1).forEach(function (u) {
- 'object' != typeof u ||
- null === u ||
- Array.isArray(u) ||
- Object.keys(u).forEach(function (w) {
- return (
- (o = safeGetProperty(i, w)),
- (s = safeGetProperty(u, w)) === i
- ? void 0
- : 'object' != typeof s || null === s
- ? void (i[w] = s)
- : Array.isArray(s)
- ? void (i[w] = deepCloneArray(s))
- : isSpecificValue(s)
- ? void (i[w] = cloneSpecificValue(s))
- : 'object' != typeof o || null === o || Array.isArray(o)
- ? void (i[w] = _({}, s))
- : void (i[w] = _(o, s))
- );
- });
- }),
- i
- );
- });
- },
- 14744: (s) => {
- 'use strict';
- var o = function isMergeableObject(s) {
- return (
- (function isNonNullObject(s) {
- return !!s && 'object' == typeof s;
- })(s) &&
- !(function isSpecial(s) {
- var o = Object.prototype.toString.call(s);
- return (
- '[object RegExp]' === o ||
- '[object Date]' === o ||
- (function isReactElement(s) {
- return s.$$typeof === i;
- })(s)
- );
- })(s)
- );
- };
- var i = 'function' == typeof Symbol && Symbol.for ? Symbol.for('react.element') : 60103;
- function cloneUnlessOtherwiseSpecified(s, o) {
- return !1 !== o.clone && o.isMergeableObject(s)
- ? deepmerge(
- (function emptyTarget(s) {
- return Array.isArray(s) ? [] : {};
- })(s),
- s,
- o
- )
- : s;
- }
- function defaultArrayMerge(s, o, i) {
- return s.concat(o).map(function (s) {
- return cloneUnlessOtherwiseSpecified(s, i);
- });
- }
- function getKeys(s) {
- return Object.keys(s).concat(
- (function getEnumerableOwnPropertySymbols(s) {
- return Object.getOwnPropertySymbols
- ? Object.getOwnPropertySymbols(s).filter(function (o) {
- return Object.propertyIsEnumerable.call(s, o);
- })
- : [];
- })(s)
- );
- }
- function propertyIsOnObject(s, o) {
- try {
- return o in s;
- } catch (s) {
- return !1;
- }
- }
- function mergeObject(s, o, i) {
- var u = {};
- return (
- i.isMergeableObject(s) &&
- getKeys(s).forEach(function (o) {
- u[o] = cloneUnlessOtherwiseSpecified(s[o], i);
- }),
- getKeys(o).forEach(function (_) {
- (function propertyIsUnsafe(s, o) {
- return (
- propertyIsOnObject(s, o) &&
- !(Object.hasOwnProperty.call(s, o) && Object.propertyIsEnumerable.call(s, o))
- );
- })(s, _) ||
- (propertyIsOnObject(s, _) && i.isMergeableObject(o[_])
- ? (u[_] = (function getMergeFunction(s, o) {
- if (!o.customMerge) return deepmerge;
- var i = o.customMerge(s);
- return 'function' == typeof i ? i : deepmerge;
- })(_, i)(s[_], o[_], i))
- : (u[_] = cloneUnlessOtherwiseSpecified(o[_], i)));
- }),
- u
- );
- }
- function deepmerge(s, i, u) {
- ((u = u || {}).arrayMerge = u.arrayMerge || defaultArrayMerge),
- (u.isMergeableObject = u.isMergeableObject || o),
- (u.cloneUnlessOtherwiseSpecified = cloneUnlessOtherwiseSpecified);
- var _ = Array.isArray(i);
- return _ === Array.isArray(s)
- ? _
- ? u.arrayMerge(s, i, u)
- : mergeObject(s, i, u)
- : cloneUnlessOtherwiseSpecified(i, u);
- }
- deepmerge.all = function deepmergeAll(s, o) {
- if (!Array.isArray(s)) throw new Error('first argument should be an array');
- return s.reduce(function (s, i) {
- return deepmerge(s, i, o);
- }, {});
- };
- var u = deepmerge;
- s.exports = u;
- },
- 42838: function (s) {
- s.exports = (function () {
- 'use strict';
- const {
- entries: s,
- setPrototypeOf: o,
- isFrozen: i,
- getPrototypeOf: u,
- getOwnPropertyDescriptor: _
- } = Object;
- let { freeze: w, seal: x, create: C } = Object,
- { apply: j, construct: L } = 'undefined' != typeof Reflect && Reflect;
- w ||
- (w = function freeze(s) {
- return s;
- }),
- x ||
- (x = function seal(s) {
- return s;
- }),
- j ||
- (j = function apply(s, o, i) {
- return s.apply(o, i);
- }),
- L ||
- (L = function construct(s, o) {
- return new s(...o);
- });
- const B = unapply(Array.prototype.forEach),
- $ = unapply(Array.prototype.pop),
- V = unapply(Array.prototype.push),
- U = unapply(String.prototype.toLowerCase),
- z = unapply(String.prototype.toString),
- Y = unapply(String.prototype.match),
- Z = unapply(String.prototype.replace),
- ee = unapply(String.prototype.indexOf),
- ie = unapply(String.prototype.trim),
- ae = unapply(Object.prototype.hasOwnProperty),
- le = unapply(RegExp.prototype.test),
- ce = unconstruct(TypeError);
- function unapply(s) {
- return function (o) {
- for (var i = arguments.length, u = new Array(i > 1 ? i - 1 : 0), _ = 1; _ < i; _++)
- u[_ - 1] = arguments[_];
- return j(s, o, u);
- };
- }
- function unconstruct(s) {
- return function () {
- for (var o = arguments.length, i = new Array(o), u = 0; u < o; u++)
- i[u] = arguments[u];
- return L(s, i);
- };
- }
- function addToSet(s, u) {
- let _ = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : U;
- o && o(s, null);
- let w = u.length;
- for (; w--; ) {
- let o = u[w];
- if ('string' == typeof o) {
- const s = _(o);
- s !== o && (i(u) || (u[w] = s), (o = s));
- }
- s[o] = !0;
- }
- return s;
- }
- function cleanArray(s) {
- for (let o = 0; o < s.length; o++) ae(s, o) || (s[o] = null);
- return s;
- }
- function clone(o) {
- const i = C(null);
- for (const [u, _] of s(o))
- ae(o, u) &&
- (Array.isArray(_)
- ? (i[u] = cleanArray(_))
- : _ && 'object' == typeof _ && _.constructor === Object
- ? (i[u] = clone(_))
- : (i[u] = _));
- return i;
- }
- function lookupGetter(s, o) {
- for (; null !== s; ) {
- const i = _(s, o);
- if (i) {
- if (i.get) return unapply(i.get);
- if ('function' == typeof i.value) return unapply(i.value);
- }
- s = u(s);
- }
- function fallbackValue() {
- return null;
- }
- return fallbackValue;
- }
- const pe = w([
- 'a',
- 'abbr',
- 'acronym',
- 'address',
- 'area',
- 'article',
- 'aside',
- 'audio',
- 'b',
- 'bdi',
- 'bdo',
- 'big',
- 'blink',
- 'blockquote',
- 'body',
- 'br',
- 'button',
- 'canvas',
- 'caption',
- 'center',
- 'cite',
- 'code',
- 'col',
- 'colgroup',
- 'content',
- 'data',
- 'datalist',
- 'dd',
- 'decorator',
- 'del',
- 'details',
- 'dfn',
- 'dialog',
- 'dir',
- 'div',
- 'dl',
- 'dt',
- 'element',
- 'em',
- 'fieldset',
- 'figcaption',
- 'figure',
- 'font',
- 'footer',
- 'form',
- 'h1',
- 'h2',
- 'h3',
- 'h4',
- 'h5',
- 'h6',
- 'head',
- 'header',
- 'hgroup',
- 'hr',
- 'html',
- 'i',
- 'img',
- 'input',
- 'ins',
- 'kbd',
- 'label',
- 'legend',
- 'li',
- 'main',
- 'map',
- 'mark',
- 'marquee',
- 'menu',
- 'menuitem',
- 'meter',
- 'nav',
- 'nobr',
- 'ol',
- 'optgroup',
- 'option',
- 'output',
- 'p',
- 'picture',
- 'pre',
- 'progress',
- 'q',
- 'rp',
- 'rt',
- 'ruby',
- 's',
- 'samp',
- 'section',
- 'select',
- 'shadow',
- 'small',
- 'source',
- 'spacer',
- 'span',
- 'strike',
- 'strong',
- 'style',
- 'sub',
- 'summary',
- 'sup',
- 'table',
- 'tbody',
- 'td',
- 'template',
- 'textarea',
- 'tfoot',
- 'th',
- 'thead',
- 'time',
- 'tr',
- 'track',
- 'tt',
- 'u',
- 'ul',
- 'var',
- 'video',
- 'wbr'
- ]),
- de = w([
- 'svg',
- 'a',
- 'altglyph',
- 'altglyphdef',
- 'altglyphitem',
- 'animatecolor',
- 'animatemotion',
- 'animatetransform',
- 'circle',
- 'clippath',
- 'defs',
- 'desc',
- 'ellipse',
- 'filter',
- 'font',
- 'g',
- 'glyph',
- 'glyphref',
- 'hkern',
- 'image',
- 'line',
- 'lineargradient',
- 'marker',
- 'mask',
- 'metadata',
- 'mpath',
- 'path',
- 'pattern',
- 'polygon',
- 'polyline',
- 'radialgradient',
- 'rect',
- 'stop',
- 'style',
- 'switch',
- 'symbol',
- 'text',
- 'textpath',
- 'title',
- 'tref',
- 'tspan',
- 'view',
- 'vkern'
- ]),
- fe = w([
- 'feBlend',
- 'feColorMatrix',
- 'feComponentTransfer',
- 'feComposite',
- 'feConvolveMatrix',
- 'feDiffuseLighting',
- 'feDisplacementMap',
- 'feDistantLight',
- 'feDropShadow',
- 'feFlood',
- 'feFuncA',
- 'feFuncB',
- 'feFuncG',
- 'feFuncR',
- 'feGaussianBlur',
- 'feImage',
- 'feMerge',
- 'feMergeNode',
- 'feMorphology',
- 'feOffset',
- 'fePointLight',
- 'feSpecularLighting',
- 'feSpotLight',
- 'feTile',
- 'feTurbulence'
- ]),
- ye = w([
- 'animate',
- 'color-profile',
- 'cursor',
- 'discard',
- 'font-face',
- 'font-face-format',
- 'font-face-name',
- 'font-face-src',
- 'font-face-uri',
- 'foreignobject',
- 'hatch',
- 'hatchpath',
- 'mesh',
- 'meshgradient',
- 'meshpatch',
- 'meshrow',
- 'missing-glyph',
- 'script',
- 'set',
- 'solidcolor',
- 'unknown',
- 'use'
- ]),
- be = w([
- 'math',
- 'menclose',
- 'merror',
- 'mfenced',
- 'mfrac',
- 'mglyph',
- 'mi',
- 'mlabeledtr',
- 'mmultiscripts',
- 'mn',
- 'mo',
- 'mover',
- 'mpadded',
- 'mphantom',
- 'mroot',
- 'mrow',
- 'ms',
- 'mspace',
- 'msqrt',
- 'mstyle',
- 'msub',
- 'msup',
- 'msubsup',
- 'mtable',
- 'mtd',
- 'mtext',
- 'mtr',
- 'munder',
- 'munderover',
- 'mprescripts'
- ]),
- _e = w([
- 'maction',
- 'maligngroup',
- 'malignmark',
- 'mlongdiv',
- 'mscarries',
- 'mscarry',
- 'msgroup',
- 'mstack',
- 'msline',
- 'msrow',
- 'semantics',
- 'annotation',
- 'annotation-xml',
- 'mprescripts',
- 'none'
- ]),
- we = w(['#text']),
- Se = w([
- 'accept',
- 'action',
- 'align',
- 'alt',
- 'autocapitalize',
- 'autocomplete',
- 'autopictureinpicture',
- 'autoplay',
- 'background',
- 'bgcolor',
- 'border',
- 'capture',
- 'cellpadding',
- 'cellspacing',
- 'checked',
- 'cite',
- 'class',
- 'clear',
- 'color',
- 'cols',
- 'colspan',
- 'controls',
- 'controlslist',
- 'coords',
- 'crossorigin',
- 'datetime',
- 'decoding',
- 'default',
- 'dir',
- 'disabled',
- 'disablepictureinpicture',
- 'disableremoteplayback',
- 'download',
- 'draggable',
- 'enctype',
- 'enterkeyhint',
- 'face',
- 'for',
- 'headers',
- 'height',
- 'hidden',
- 'high',
- 'href',
- 'hreflang',
- 'id',
- 'inputmode',
- 'integrity',
- 'ismap',
- 'kind',
- 'label',
- 'lang',
- 'list',
- 'loading',
- 'loop',
- 'low',
- 'max',
- 'maxlength',
- 'media',
- 'method',
- 'min',
- 'minlength',
- 'multiple',
- 'muted',
- 'name',
- 'nonce',
- 'noshade',
- 'novalidate',
- 'nowrap',
- 'open',
- 'optimum',
- 'pattern',
- 'placeholder',
- 'playsinline',
- 'popover',
- 'popovertarget',
- 'popovertargetaction',
- 'poster',
- 'preload',
- 'pubdate',
- 'radiogroup',
- 'readonly',
- 'rel',
- 'required',
- 'rev',
- 'reversed',
- 'role',
- 'rows',
- 'rowspan',
- 'spellcheck',
- 'scope',
- 'selected',
- 'shape',
- 'size',
- 'sizes',
- 'span',
- 'srclang',
- 'start',
- 'src',
- 'srcset',
- 'step',
- 'style',
- 'summary',
- 'tabindex',
- 'title',
- 'translate',
- 'type',
- 'usemap',
- 'valign',
- 'value',
- 'width',
- 'wrap',
- 'xmlns',
- 'slot'
- ]),
- xe = w([
- 'accent-height',
- 'accumulate',
- 'additive',
- 'alignment-baseline',
- 'ascent',
- 'attributename',
- 'attributetype',
- 'azimuth',
- 'basefrequency',
- 'baseline-shift',
- 'begin',
- 'bias',
- 'by',
- 'class',
- 'clip',
- 'clippathunits',
- 'clip-path',
- 'clip-rule',
- 'color',
- 'color-interpolation',
- 'color-interpolation-filters',
- 'color-profile',
- 'color-rendering',
- 'cx',
- 'cy',
- 'd',
- 'dx',
- 'dy',
- 'diffuseconstant',
- 'direction',
- 'display',
- 'divisor',
- 'dur',
- 'edgemode',
- 'elevation',
- 'end',
- 'fill',
- 'fill-opacity',
- 'fill-rule',
- 'filter',
- 'filterunits',
- 'flood-color',
- 'flood-opacity',
- 'font-family',
- 'font-size',
- 'font-size-adjust',
- 'font-stretch',
- 'font-style',
- 'font-variant',
- 'font-weight',
- 'fx',
- 'fy',
- 'g1',
- 'g2',
- 'glyph-name',
- 'glyphref',
- 'gradientunits',
- 'gradienttransform',
- 'height',
- 'href',
- 'id',
- 'image-rendering',
- 'in',
- 'in2',
- 'k',
- 'k1',
- 'k2',
- 'k3',
- 'k4',
- 'kerning',
- 'keypoints',
- 'keysplines',
- 'keytimes',
- 'lang',
- 'lengthadjust',
- 'letter-spacing',
- 'kernelmatrix',
- 'kernelunitlength',
- 'lighting-color',
- 'local',
- 'marker-end',
- 'marker-mid',
- 'marker-start',
- 'markerheight',
- 'markerunits',
- 'markerwidth',
- 'maskcontentunits',
- 'maskunits',
- 'max',
- 'mask',
- 'media',
- 'method',
- 'mode',
- 'min',
- 'name',
- 'numoctaves',
- 'offset',
- 'operator',
- 'opacity',
- 'order',
- 'orient',
- 'orientation',
- 'origin',
- 'overflow',
- 'paint-order',
- 'path',
- 'pathlength',
- 'patterncontentunits',
- 'patterntransform',
- 'patternunits',
- 'points',
- 'preservealpha',
- 'preserveaspectratio',
- 'primitiveunits',
- 'r',
- 'rx',
- 'ry',
- 'radius',
- 'refx',
- 'refy',
- 'repeatcount',
- 'repeatdur',
- 'restart',
- 'result',
- 'rotate',
- 'scale',
- 'seed',
- 'shape-rendering',
- 'specularconstant',
- 'specularexponent',
- 'spreadmethod',
- 'startoffset',
- 'stddeviation',
- 'stitchtiles',
- 'stop-color',
- 'stop-opacity',
- 'stroke-dasharray',
- 'stroke-dashoffset',
- 'stroke-linecap',
- 'stroke-linejoin',
- 'stroke-miterlimit',
- 'stroke-opacity',
- 'stroke',
- 'stroke-width',
- 'style',
- 'surfacescale',
- 'systemlanguage',
- 'tabindex',
- 'targetx',
- 'targety',
- 'transform',
- 'transform-origin',
- 'text-anchor',
- 'text-decoration',
- 'text-rendering',
- 'textlength',
- 'type',
- 'u1',
- 'u2',
- 'unicode',
- 'values',
- 'viewbox',
- 'visibility',
- 'version',
- 'vert-adv-y',
- 'vert-origin-x',
- 'vert-origin-y',
- 'width',
- 'word-spacing',
- 'wrap',
- 'writing-mode',
- 'xchannelselector',
- 'ychannelselector',
- 'x',
- 'x1',
- 'x2',
- 'xmlns',
- 'y',
- 'y1',
- 'y2',
- 'z',
- 'zoomandpan'
- ]),
- Pe = w([
- 'accent',
- 'accentunder',
- 'align',
- 'bevelled',
- 'close',
- 'columnsalign',
- 'columnlines',
- 'columnspan',
- 'denomalign',
- 'depth',
- 'dir',
- 'display',
- 'displaystyle',
- 'encoding',
- 'fence',
- 'frame',
- 'height',
- 'href',
- 'id',
- 'largeop',
- 'length',
- 'linethickness',
- 'lspace',
- 'lquote',
- 'mathbackground',
- 'mathcolor',
- 'mathsize',
- 'mathvariant',
- 'maxsize',
- 'minsize',
- 'movablelimits',
- 'notation',
- 'numalign',
- 'open',
- 'rowalign',
- 'rowlines',
- 'rowspacing',
- 'rowspan',
- 'rspace',
- 'rquote',
- 'scriptlevel',
- 'scriptminsize',
- 'scriptsizemultiplier',
- 'selection',
- 'separator',
- 'separators',
- 'stretchy',
- 'subscriptshift',
- 'supscriptshift',
- 'symmetric',
- 'voffset',
- 'width',
- 'xmlns'
- ]),
- Te = w(['xlink:href', 'xml:id', 'xlink:title', 'xml:space', 'xmlns:xlink']),
- Re = x(/\{\{[\w\W]*|[\w\W]*\}\}/gm),
- qe = x(/<%[\w\W]*|[\w\W]*%>/gm),
- $e = x(/\${[\w\W]*}/gm),
- ze = x(/^data-[\-\w.\u00B7-\uFFFF]/),
- We = x(/^aria-[\-\w]+$/),
- He = x(
- /^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i
- ),
- Ye = x(/^(?:\w+script|data):/i),
- Xe = x(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),
- Qe = x(/^html$/i),
- et = x(/^[a-z][.\w]*(-[.\w]+)+$/i);
- var tt = Object.freeze({
- __proto__: null,
- MUSTACHE_EXPR: Re,
- ERB_EXPR: qe,
- TMPLIT_EXPR: $e,
- DATA_ATTR: ze,
- ARIA_ATTR: We,
- IS_ALLOWED_URI: He,
- IS_SCRIPT_OR_DATA: Ye,
- ATTR_WHITESPACE: Xe,
- DOCTYPE_NAME: Qe,
- CUSTOM_ELEMENT: et
- });
- const rt = {
- element: 1,
- attribute: 2,
- text: 3,
- cdataSection: 4,
- entityReference: 5,
- entityNode: 6,
- progressingInstruction: 7,
- comment: 8,
- document: 9,
- documentType: 10,
- documentFragment: 11,
- notation: 12
- },
- nt = function getGlobal() {
- return 'undefined' == typeof window ? null : window;
- },
- st = function _createTrustedTypesPolicy(s, o) {
- if ('object' != typeof s || 'function' != typeof s.createPolicy) return null;
- let i = null;
- const u = 'data-tt-policy-suffix';
- o && o.hasAttribute(u) && (i = o.getAttribute(u));
- const _ = 'dompurify' + (i ? '#' + i : '');
- try {
- return s.createPolicy(_, { createHTML: (s) => s, createScriptURL: (s) => s });
- } catch (s) {
- return console.warn('TrustedTypes policy ' + _ + ' could not be created.'), null;
- }
- };
- function createDOMPurify() {
- let o = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : nt();
- const DOMPurify = (s) => createDOMPurify(s);
- if (
- ((DOMPurify.version = '3.1.6'),
- (DOMPurify.removed = []),
- !o || !o.document || o.document.nodeType !== rt.document)
- )
- return (DOMPurify.isSupported = !1), DOMPurify;
- let { document: i } = o;
- const u = i,
- _ = u.currentScript,
- {
- DocumentFragment: x,
- HTMLTemplateElement: j,
- Node: L,
- Element: Re,
- NodeFilter: qe,
- NamedNodeMap: $e = o.NamedNodeMap || o.MozNamedAttrMap,
- HTMLFormElement: ze,
- DOMParser: We,
- trustedTypes: Ye
- } = o,
- Xe = Re.prototype,
- et = lookupGetter(Xe, 'cloneNode'),
- ot = lookupGetter(Xe, 'remove'),
- it = lookupGetter(Xe, 'nextSibling'),
- at = lookupGetter(Xe, 'childNodes'),
- lt = lookupGetter(Xe, 'parentNode');
- if ('function' == typeof j) {
- const s = i.createElement('template');
- s.content && s.content.ownerDocument && (i = s.content.ownerDocument);
- }
- let ct,
- ut = '';
- const {
- implementation: pt,
- createNodeIterator: ht,
- createDocumentFragment: dt,
- getElementsByTagName: mt
- } = i,
- { importNode: gt } = u;
- let yt = {};
- DOMPurify.isSupported =
- 'function' == typeof s &&
- 'function' == typeof lt &&
- pt &&
- void 0 !== pt.createHTMLDocument;
- const {
- MUSTACHE_EXPR: vt,
- ERB_EXPR: bt,
- TMPLIT_EXPR: _t,
- DATA_ATTR: Et,
- ARIA_ATTR: wt,
- IS_SCRIPT_OR_DATA: St,
- ATTR_WHITESPACE: xt,
- CUSTOM_ELEMENT: kt
- } = tt;
- let { IS_ALLOWED_URI: Ct } = tt,
- Ot = null;
- const At = addToSet({}, [...pe, ...de, ...fe, ...be, ...we]);
- let jt = null;
- const It = addToSet({}, [...Se, ...xe, ...Pe, ...Te]);
- let Pt = Object.seal(
- C(null, {
- tagNameCheck: { writable: !0, configurable: !1, enumerable: !0, value: null },
- attributeNameCheck: {
- writable: !0,
- configurable: !1,
- enumerable: !0,
- value: null
- },
- allowCustomizedBuiltInElements: {
- writable: !0,
- configurable: !1,
- enumerable: !0,
- value: !1
- }
- })
- ),
- Mt = null,
- Tt = null,
- Nt = !0,
- Rt = !0,
- Dt = !1,
- Lt = !0,
- Bt = !1,
- Ft = !0,
- qt = !1,
- $t = !1,
- Vt = !1,
- Ut = !1,
- zt = !1,
- Wt = !1,
- Kt = !0,
- Ht = !1;
- const Jt = 'user-content-';
- let Gt = !0,
- Yt = !1,
- Xt = {},
- Zt = null;
- const Qt = addToSet({}, [
- 'annotation-xml',
- 'audio',
- 'colgroup',
- 'desc',
- 'foreignobject',
- 'head',
- 'iframe',
- 'math',
- 'mi',
- 'mn',
- 'mo',
- 'ms',
- 'mtext',
- 'noembed',
- 'noframes',
- 'noscript',
- 'plaintext',
- 'script',
- 'style',
- 'svg',
- 'template',
- 'thead',
- 'title',
- 'video',
- 'xmp'
- ]);
- let er = null;
- const tr = addToSet({}, ['audio', 'video', 'img', 'source', 'image', 'track']);
- let rr = null;
- const nr = addToSet({}, [
- 'alt',
- 'class',
- 'for',
- 'id',
- 'label',
- 'name',
- 'pattern',
- 'placeholder',
- 'role',
- 'summary',
- 'title',
- 'value',
- 'style',
- 'xmlns'
- ]),
- sr = 'http://www.w3.org/1998/Math/MathML',
- ir = 'http://www.w3.org/2000/svg',
- ar = 'http://www.w3.org/1999/xhtml';
- let lr = ar,
- cr = !1,
- ur = null;
- const pr = addToSet({}, [sr, ir, ar], z);
- let dr = null;
- const fr = ['application/xhtml+xml', 'text/html'],
- mr = 'text/html';
- let gr = null,
- yr = null;
- const vr = i.createElement('form'),
- br = function isRegexOrFunction(s) {
- return s instanceof RegExp || s instanceof Function;
- },
- _r = function _parseConfig() {
- let s = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {};
- if (!yr || yr !== s) {
- if (
- ((s && 'object' == typeof s) || (s = {}),
- (s = clone(s)),
- (dr = -1 === fr.indexOf(s.PARSER_MEDIA_TYPE) ? mr : s.PARSER_MEDIA_TYPE),
- (gr = 'application/xhtml+xml' === dr ? z : U),
- (Ot = ae(s, 'ALLOWED_TAGS') ? addToSet({}, s.ALLOWED_TAGS, gr) : At),
- (jt = ae(s, 'ALLOWED_ATTR') ? addToSet({}, s.ALLOWED_ATTR, gr) : It),
- (ur = ae(s, 'ALLOWED_NAMESPACES')
- ? addToSet({}, s.ALLOWED_NAMESPACES, z)
- : pr),
- (rr = ae(s, 'ADD_URI_SAFE_ATTR')
- ? addToSet(clone(nr), s.ADD_URI_SAFE_ATTR, gr)
- : nr),
- (er = ae(s, 'ADD_DATA_URI_TAGS')
- ? addToSet(clone(tr), s.ADD_DATA_URI_TAGS, gr)
- : tr),
- (Zt = ae(s, 'FORBID_CONTENTS') ? addToSet({}, s.FORBID_CONTENTS, gr) : Qt),
- (Mt = ae(s, 'FORBID_TAGS') ? addToSet({}, s.FORBID_TAGS, gr) : {}),
- (Tt = ae(s, 'FORBID_ATTR') ? addToSet({}, s.FORBID_ATTR, gr) : {}),
- (Xt = !!ae(s, 'USE_PROFILES') && s.USE_PROFILES),
- (Nt = !1 !== s.ALLOW_ARIA_ATTR),
- (Rt = !1 !== s.ALLOW_DATA_ATTR),
- (Dt = s.ALLOW_UNKNOWN_PROTOCOLS || !1),
- (Lt = !1 !== s.ALLOW_SELF_CLOSE_IN_ATTR),
- (Bt = s.SAFE_FOR_TEMPLATES || !1),
- (Ft = !1 !== s.SAFE_FOR_XML),
- (qt = s.WHOLE_DOCUMENT || !1),
- (Ut = s.RETURN_DOM || !1),
- (zt = s.RETURN_DOM_FRAGMENT || !1),
- (Wt = s.RETURN_TRUSTED_TYPE || !1),
- (Vt = s.FORCE_BODY || !1),
- (Kt = !1 !== s.SANITIZE_DOM),
- (Ht = s.SANITIZE_NAMED_PROPS || !1),
- (Gt = !1 !== s.KEEP_CONTENT),
- (Yt = s.IN_PLACE || !1),
- (Ct = s.ALLOWED_URI_REGEXP || He),
- (lr = s.NAMESPACE || ar),
- (Pt = s.CUSTOM_ELEMENT_HANDLING || {}),
- s.CUSTOM_ELEMENT_HANDLING &&
- br(s.CUSTOM_ELEMENT_HANDLING.tagNameCheck) &&
- (Pt.tagNameCheck = s.CUSTOM_ELEMENT_HANDLING.tagNameCheck),
- s.CUSTOM_ELEMENT_HANDLING &&
- br(s.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) &&
- (Pt.attributeNameCheck = s.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),
- s.CUSTOM_ELEMENT_HANDLING &&
- 'boolean' ==
- typeof s.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements &&
- (Pt.allowCustomizedBuiltInElements =
- s.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),
- Bt && (Rt = !1),
- zt && (Ut = !0),
- Xt &&
- ((Ot = addToSet({}, we)),
- (jt = []),
- !0 === Xt.html && (addToSet(Ot, pe), addToSet(jt, Se)),
- !0 === Xt.svg && (addToSet(Ot, de), addToSet(jt, xe), addToSet(jt, Te)),
- !0 === Xt.svgFilters &&
- (addToSet(Ot, fe), addToSet(jt, xe), addToSet(jt, Te)),
- !0 === Xt.mathMl && (addToSet(Ot, be), addToSet(jt, Pe), addToSet(jt, Te))),
- s.ADD_TAGS && (Ot === At && (Ot = clone(Ot)), addToSet(Ot, s.ADD_TAGS, gr)),
- s.ADD_ATTR && (jt === It && (jt = clone(jt)), addToSet(jt, s.ADD_ATTR, gr)),
- s.ADD_URI_SAFE_ATTR && addToSet(rr, s.ADD_URI_SAFE_ATTR, gr),
- s.FORBID_CONTENTS &&
- (Zt === Qt && (Zt = clone(Zt)), addToSet(Zt, s.FORBID_CONTENTS, gr)),
- Gt && (Ot['#text'] = !0),
- qt && addToSet(Ot, ['html', 'head', 'body']),
- Ot.table && (addToSet(Ot, ['tbody']), delete Mt.tbody),
- s.TRUSTED_TYPES_POLICY)
- ) {
- if ('function' != typeof s.TRUSTED_TYPES_POLICY.createHTML)
- throw ce(
- 'TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.'
- );
- if ('function' != typeof s.TRUSTED_TYPES_POLICY.createScriptURL)
- throw ce(
- 'TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.'
- );
- (ct = s.TRUSTED_TYPES_POLICY), (ut = ct.createHTML(''));
- } else
- void 0 === ct && (ct = st(Ye, _)),
- null !== ct && 'string' == typeof ut && (ut = ct.createHTML(''));
- w && w(s), (yr = s);
- }
- },
- Er = addToSet({}, ['mi', 'mo', 'mn', 'ms', 'mtext']),
- wr = addToSet({}, ['foreignobject', 'annotation-xml']),
- Sr = addToSet({}, ['title', 'style', 'font', 'a', 'script']),
- xr = addToSet({}, [...de, ...fe, ...ye]),
- kr = addToSet({}, [...be, ..._e]),
- Cr = function _checkValidNamespace(s) {
- let o = lt(s);
- (o && o.tagName) || (o = { namespaceURI: lr, tagName: 'template' });
- const i = U(s.tagName),
- u = U(o.tagName);
- return (
- !!ur[s.namespaceURI] &&
- (s.namespaceURI === ir
- ? o.namespaceURI === ar
- ? 'svg' === i
- : o.namespaceURI === sr
- ? 'svg' === i && ('annotation-xml' === u || Er[u])
- : Boolean(xr[i])
- : s.namespaceURI === sr
- ? o.namespaceURI === ar
- ? 'math' === i
- : o.namespaceURI === ir
- ? 'math' === i && wr[u]
- : Boolean(kr[i])
- : s.namespaceURI === ar
- ? !(o.namespaceURI === ir && !wr[u]) &&
- !(o.namespaceURI === sr && !Er[u]) &&
- !kr[i] &&
- (Sr[i] || !xr[i])
- : !('application/xhtml+xml' !== dr || !ur[s.namespaceURI]))
- );
- },
- Or = function _forceRemove(s) {
- V(DOMPurify.removed, { element: s });
- try {
- lt(s).removeChild(s);
- } catch (o) {
- ot(s);
- }
- },
- Ar = function _removeAttribute(s, o) {
- try {
- V(DOMPurify.removed, { attribute: o.getAttributeNode(s), from: o });
- } catch (s) {
- V(DOMPurify.removed, { attribute: null, from: o });
- }
- if ((o.removeAttribute(s), 'is' === s && !jt[s]))
- if (Ut || zt)
- try {
- Or(o);
- } catch (s) {}
- else
- try {
- o.setAttribute(s, '');
- } catch (s) {}
- },
- jr = function _initDocument(s) {
- let o = null,
- u = null;
- if (Vt) s = '<remove></remove>' + s;
- else {
- const o = Y(s, /^[\r\n\t ]+/);
- u = o && o[0];
- }
- 'application/xhtml+xml' === dr &&
- lr === ar &&
- (s =
- '<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>' +
- s +
- '</body></html>');
- const _ = ct ? ct.createHTML(s) : s;
- if (lr === ar)
- try {
- o = new We().parseFromString(_, dr);
- } catch (s) {}
- if (!o || !o.documentElement) {
- o = pt.createDocument(lr, 'template', null);
- try {
- o.documentElement.innerHTML = cr ? ut : _;
- } catch (s) {}
- }
- const w = o.body || o.documentElement;
- return (
- s && u && w.insertBefore(i.createTextNode(u), w.childNodes[0] || null),
- lr === ar ? mt.call(o, qt ? 'html' : 'body')[0] : qt ? o.documentElement : w
- );
- },
- Ir = function _createNodeIterator(s) {
- return ht.call(
- s.ownerDocument || s,
- s,
- qe.SHOW_ELEMENT |
- qe.SHOW_COMMENT |
- qe.SHOW_TEXT |
- qe.SHOW_PROCESSING_INSTRUCTION |
- qe.SHOW_CDATA_SECTION,
- null
- );
- },
- Pr = function _isClobbered(s) {
- return (
- s instanceof ze &&
- ('string' != typeof s.nodeName ||
- 'string' != typeof s.textContent ||
- 'function' != typeof s.removeChild ||
- !(s.attributes instanceof $e) ||
- 'function' != typeof s.removeAttribute ||
- 'function' != typeof s.setAttribute ||
- 'string' != typeof s.namespaceURI ||
- 'function' != typeof s.insertBefore ||
- 'function' != typeof s.hasChildNodes)
- );
- },
- Mr = function _isNode(s) {
- return 'function' == typeof L && s instanceof L;
- },
- Tr = function _executeHook(s, o, i) {
- yt[s] &&
- B(yt[s], (s) => {
- s.call(DOMPurify, o, i, yr);
- });
- },
- Nr = function _sanitizeElements(s) {
- let o = null;
- if ((Tr('beforeSanitizeElements', s, null), Pr(s))) return Or(s), !0;
- const i = gr(s.nodeName);
- if (
- (Tr('uponSanitizeElement', s, { tagName: i, allowedTags: Ot }),
- s.hasChildNodes() &&
- !Mr(s.firstElementChild) &&
- le(/<[/\w]/g, s.innerHTML) &&
- le(/<[/\w]/g, s.textContent))
- )
- return Or(s), !0;
- if (s.nodeType === rt.progressingInstruction) return Or(s), !0;
- if (Ft && s.nodeType === rt.comment && le(/<[/\w]/g, s.data)) return Or(s), !0;
- if (!Ot[i] || Mt[i]) {
- if (!Mt[i] && Dr(i)) {
- if (Pt.tagNameCheck instanceof RegExp && le(Pt.tagNameCheck, i)) return !1;
- if (Pt.tagNameCheck instanceof Function && Pt.tagNameCheck(i)) return !1;
- }
- if (Gt && !Zt[i]) {
- const o = lt(s) || s.parentNode,
- i = at(s) || s.childNodes;
- if (i && o)
- for (let u = i.length - 1; u >= 0; --u) {
- const _ = et(i[u], !0);
- (_.__removalCount = (s.__removalCount || 0) + 1),
- o.insertBefore(_, it(s));
- }
- }
- return Or(s), !0;
- }
- return s instanceof Re && !Cr(s)
- ? (Or(s), !0)
- : ('noscript' !== i && 'noembed' !== i && 'noframes' !== i) ||
- !le(/<\/no(script|embed|frames)/i, s.innerHTML)
- ? (Bt &&
- s.nodeType === rt.text &&
- ((o = s.textContent),
- B([vt, bt, _t], (s) => {
- o = Z(o, s, ' ');
- }),
- s.textContent !== o &&
- (V(DOMPurify.removed, { element: s.cloneNode() }),
- (s.textContent = o))),
- Tr('afterSanitizeElements', s, null),
- !1)
- : (Or(s), !0);
- },
- Rr = function _isValidAttribute(s, o, u) {
- if (Kt && ('id' === o || 'name' === o) && (u in i || u in vr)) return !1;
- if (Rt && !Tt[o] && le(Et, o));
- else if (Nt && le(wt, o));
- else if (!jt[o] || Tt[o]) {
- if (
- !(
- (Dr(s) &&
- ((Pt.tagNameCheck instanceof RegExp && le(Pt.tagNameCheck, s)) ||
- (Pt.tagNameCheck instanceof Function && Pt.tagNameCheck(s))) &&
- ((Pt.attributeNameCheck instanceof RegExp &&
- le(Pt.attributeNameCheck, o)) ||
- (Pt.attributeNameCheck instanceof Function &&
- Pt.attributeNameCheck(o)))) ||
- ('is' === o &&
- Pt.allowCustomizedBuiltInElements &&
- ((Pt.tagNameCheck instanceof RegExp && le(Pt.tagNameCheck, u)) ||
- (Pt.tagNameCheck instanceof Function && Pt.tagNameCheck(u))))
- )
- )
- return !1;
- } else if (rr[o]);
- else if (le(Ct, Z(u, xt, '')));
- else if (
- ('src' !== o && 'xlink:href' !== o && 'href' !== o) ||
- 'script' === s ||
- 0 !== ee(u, 'data:') ||
- !er[s]
- )
- if (Dt && !le(St, Z(u, xt, '')));
- else if (u) return !1;
- return !0;
- },
- Dr = function _isBasicCustomElement(s) {
- return 'annotation-xml' !== s && Y(s, kt);
- },
- Lr = function _sanitizeAttributes(s) {
- Tr('beforeSanitizeAttributes', s, null);
- const { attributes: o } = s;
- if (!o) return;
- const i = { attrName: '', attrValue: '', keepAttr: !0, allowedAttributes: jt };
- let u = o.length;
- for (; u--; ) {
- const _ = o[u],
- { name: w, namespaceURI: x, value: C } = _,
- j = gr(w);
- let L = 'value' === w ? C : ie(C);
- if (
- ((i.attrName = j),
- (i.attrValue = L),
- (i.keepAttr = !0),
- (i.forceKeepAttr = void 0),
- Tr('uponSanitizeAttribute', s, i),
- (L = i.attrValue),
- Ft && le(/((--!?|])>)|<\/(style|title)/i, L))
- ) {
- Ar(w, s);
- continue;
- }
- if (i.forceKeepAttr) continue;
- if ((Ar(w, s), !i.keepAttr)) continue;
- if (!Lt && le(/\/>/i, L)) {
- Ar(w, s);
- continue;
- }
- Bt &&
- B([vt, bt, _t], (s) => {
- L = Z(L, s, ' ');
- });
- const V = gr(s.nodeName);
- if (Rr(V, j, L)) {
- if (
- (!Ht || ('id' !== j && 'name' !== j) || (Ar(w, s), (L = Jt + L)),
- ct && 'object' == typeof Ye && 'function' == typeof Ye.getAttributeType)
- )
- if (x);
- else
- switch (Ye.getAttributeType(V, j)) {
- case 'TrustedHTML':
- L = ct.createHTML(L);
- break;
- case 'TrustedScriptURL':
- L = ct.createScriptURL(L);
- }
- try {
- x ? s.setAttributeNS(x, w, L) : s.setAttribute(w, L),
- Pr(s) ? Or(s) : $(DOMPurify.removed);
- } catch (s) {}
- }
- }
- Tr('afterSanitizeAttributes', s, null);
- },
- Br = function _sanitizeShadowDOM(s) {
- let o = null;
- const i = Ir(s);
- for (Tr('beforeSanitizeShadowDOM', s, null); (o = i.nextNode()); )
- Tr('uponSanitizeShadowNode', o, null),
- Nr(o) || (o.content instanceof x && _sanitizeShadowDOM(o.content), Lr(o));
- Tr('afterSanitizeShadowDOM', s, null);
- };
- return (
- (DOMPurify.sanitize = function (s) {
- let o = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {},
- i = null,
- _ = null,
- w = null,
- C = null;
- if (((cr = !s), cr && (s = '\x3c!--\x3e'), 'string' != typeof s && !Mr(s))) {
- if ('function' != typeof s.toString) throw ce('toString is not a function');
- if ('string' != typeof (s = s.toString()))
- throw ce('dirty is not a string, aborting');
- }
- if (!DOMPurify.isSupported) return s;
- if (
- ($t || _r(o), (DOMPurify.removed = []), 'string' == typeof s && (Yt = !1), Yt)
- ) {
- if (s.nodeName) {
- const o = gr(s.nodeName);
- if (!Ot[o] || Mt[o])
- throw ce('root node is forbidden and cannot be sanitized in-place');
- }
- } else if (s instanceof L)
- (i = jr('\x3c!----\x3e')),
- (_ = i.ownerDocument.importNode(s, !0)),
- (_.nodeType === rt.element && 'BODY' === _.nodeName) || 'HTML' === _.nodeName
- ? (i = _)
- : i.appendChild(_);
- else {
- if (!Ut && !Bt && !qt && -1 === s.indexOf('<'))
- return ct && Wt ? ct.createHTML(s) : s;
- if (((i = jr(s)), !i)) return Ut ? null : Wt ? ut : '';
- }
- i && Vt && Or(i.firstChild);
- const j = Ir(Yt ? s : i);
- for (; (w = j.nextNode()); )
- Nr(w) || (w.content instanceof x && Br(w.content), Lr(w));
- if (Yt) return s;
- if (Ut) {
- if (zt)
- for (C = dt.call(i.ownerDocument); i.firstChild; )
- C.appendChild(i.firstChild);
- else C = i;
- return (jt.shadowroot || jt.shadowrootmode) && (C = gt.call(u, C, !0)), C;
- }
- let $ = qt ? i.outerHTML : i.innerHTML;
- return (
- qt &&
- Ot['!doctype'] &&
- i.ownerDocument &&
- i.ownerDocument.doctype &&
- i.ownerDocument.doctype.name &&
- le(Qe, i.ownerDocument.doctype.name) &&
- ($ = '<!DOCTYPE ' + i.ownerDocument.doctype.name + '>\n' + $),
- Bt &&
- B([vt, bt, _t], (s) => {
- $ = Z($, s, ' ');
- }),
- ct && Wt ? ct.createHTML($) : $
- );
- }),
- (DOMPurify.setConfig = function () {
- _r(arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}),
- ($t = !0);
- }),
- (DOMPurify.clearConfig = function () {
- (yr = null), ($t = !1);
- }),
- (DOMPurify.isValidAttribute = function (s, o, i) {
- yr || _r({});
- const u = gr(s),
- _ = gr(o);
- return Rr(u, _, i);
- }),
- (DOMPurify.addHook = function (s, o) {
- 'function' == typeof o && ((yt[s] = yt[s] || []), V(yt[s], o));
- }),
- (DOMPurify.removeHook = function (s) {
- if (yt[s]) return $(yt[s]);
- }),
- (DOMPurify.removeHooks = function (s) {
- yt[s] && (yt[s] = []);
- }),
- (DOMPurify.removeAllHooks = function () {
- yt = {};
- }),
- DOMPurify
- );
- }
- return createDOMPurify();
- })();
- },
- 78004: (s) => {
- 'use strict';
- class SubRange {
- constructor(s, o) {
- (this.low = s), (this.high = o), (this.length = 1 + o - s);
- }
- overlaps(s) {
- return !(this.high < s.low || this.low > s.high);
- }
- touches(s) {
- return !(this.high + 1 < s.low || this.low - 1 > s.high);
- }
- add(s) {
- return new SubRange(Math.min(this.low, s.low), Math.max(this.high, s.high));
- }
- subtract(s) {
- return s.low <= this.low && s.high >= this.high
- ? []
- : s.low > this.low && s.high < this.high
- ? [new SubRange(this.low, s.low - 1), new SubRange(s.high + 1, this.high)]
- : s.low <= this.low
- ? [new SubRange(s.high + 1, this.high)]
- : [new SubRange(this.low, s.low - 1)];
- }
- toString() {
- return this.low == this.high ? this.low.toString() : this.low + '-' + this.high;
- }
- }
- class DRange {
- constructor(s, o) {
- (this.ranges = []), (this.length = 0), null != s && this.add(s, o);
- }
- _update_length() {
- this.length = this.ranges.reduce((s, o) => s + o.length, 0);
- }
- add(s, o) {
- var _add = (s) => {
- for (var o = 0; o < this.ranges.length && !s.touches(this.ranges[o]); ) o++;
- for (
- var i = this.ranges.slice(0, o);
- o < this.ranges.length && s.touches(this.ranges[o]);
- )
- (s = s.add(this.ranges[o])), o++;
- i.push(s), (this.ranges = i.concat(this.ranges.slice(o))), this._update_length();
- };
- return (
- s instanceof DRange
- ? s.ranges.forEach(_add)
- : (null == o && (o = s), _add(new SubRange(s, o))),
- this
- );
- }
- subtract(s, o) {
- var _subtract = (s) => {
- for (var o = 0; o < this.ranges.length && !s.overlaps(this.ranges[o]); ) o++;
- for (
- var i = this.ranges.slice(0, o);
- o < this.ranges.length && s.overlaps(this.ranges[o]);
- )
- (i = i.concat(this.ranges[o].subtract(s))), o++;
- (this.ranges = i.concat(this.ranges.slice(o))), this._update_length();
- };
- return (
- s instanceof DRange
- ? s.ranges.forEach(_subtract)
- : (null == o && (o = s), _subtract(new SubRange(s, o))),
- this
- );
- }
- intersect(s, o) {
- var i = [],
- _intersect = (s) => {
- for (var o = 0; o < this.ranges.length && !s.overlaps(this.ranges[o]); ) o++;
- for (; o < this.ranges.length && s.overlaps(this.ranges[o]); ) {
- var u = Math.max(this.ranges[o].low, s.low),
- _ = Math.min(this.ranges[o].high, s.high);
- i.push(new SubRange(u, _)), o++;
- }
- };
- return (
- s instanceof DRange
- ? s.ranges.forEach(_intersect)
- : (null == o && (o = s), _intersect(new SubRange(s, o))),
- (this.ranges = i),
- this._update_length(),
- this
- );
- }
- index(s) {
- for (var o = 0; o < this.ranges.length && this.ranges[o].length <= s; )
- (s -= this.ranges[o].length), o++;
- return this.ranges[o].low + s;
- }
- toString() {
- return '[ ' + this.ranges.join(', ') + ' ]';
- }
- clone() {
- return new DRange(this);
- }
- numbers() {
- return this.ranges.reduce((s, o) => {
- for (var i = o.low; i <= o.high; ) s.push(i), i++;
- return s;
- }, []);
- }
- subranges() {
- return this.ranges.map((s) => ({
- low: s.low,
- high: s.high,
- length: 1 + s.high - s.low
- }));
- }
- }
- s.exports = DRange;
- },
- 37007: (s) => {
- 'use strict';
- var o,
- i = 'object' == typeof Reflect ? Reflect : null,
- u =
- i && 'function' == typeof i.apply
- ? i.apply
- : function ReflectApply(s, o, i) {
- return Function.prototype.apply.call(s, o, i);
- };
- o =
- i && 'function' == typeof i.ownKeys
- ? i.ownKeys
- : Object.getOwnPropertySymbols
- ? function ReflectOwnKeys(s) {
- return Object.getOwnPropertyNames(s).concat(Object.getOwnPropertySymbols(s));
- }
- : function ReflectOwnKeys(s) {
- return Object.getOwnPropertyNames(s);
- };
- var _ =
- Number.isNaN ||
- function NumberIsNaN(s) {
- return s != s;
- };
- function EventEmitter() {
- EventEmitter.init.call(this);
- }
- (s.exports = EventEmitter),
- (s.exports.once = function once(s, o) {
- return new Promise(function (i, u) {
- function errorListener(i) {
- s.removeListener(o, resolver), u(i);
- }
- function resolver() {
- 'function' == typeof s.removeListener && s.removeListener('error', errorListener),
- i([].slice.call(arguments));
- }
- eventTargetAgnosticAddListener(s, o, resolver, { once: !0 }),
- 'error' !== o &&
- (function addErrorHandlerIfEventEmitter(s, o, i) {
- 'function' == typeof s.on && eventTargetAgnosticAddListener(s, 'error', o, i);
- })(s, errorListener, { once: !0 });
- });
- }),
- (EventEmitter.EventEmitter = EventEmitter),
- (EventEmitter.prototype._events = void 0),
- (EventEmitter.prototype._eventsCount = 0),
- (EventEmitter.prototype._maxListeners = void 0);
- var w = 10;
- function checkListener(s) {
- if ('function' != typeof s)
- throw new TypeError(
- 'The "listener" argument must be of type Function. Received type ' + typeof s
- );
- }
- function _getMaxListeners(s) {
- return void 0 === s._maxListeners ? EventEmitter.defaultMaxListeners : s._maxListeners;
- }
- function _addListener(s, o, i, u) {
- var _, w, x;
- if (
- (checkListener(i),
- void 0 === (w = s._events)
- ? ((w = s._events = Object.create(null)), (s._eventsCount = 0))
- : (void 0 !== w.newListener &&
- (s.emit('newListener', o, i.listener ? i.listener : i), (w = s._events)),
- (x = w[o])),
- void 0 === x)
- )
- (x = w[o] = i), ++s._eventsCount;
- else if (
- ('function' == typeof x
- ? (x = w[o] = u ? [i, x] : [x, i])
- : u
- ? x.unshift(i)
- : x.push(i),
- (_ = _getMaxListeners(s)) > 0 && x.length > _ && !x.warned)
- ) {
- x.warned = !0;
- var C = new Error(
- 'Possible EventEmitter memory leak detected. ' +
- x.length +
- ' ' +
- String(o) +
- ' listeners added. Use emitter.setMaxListeners() to increase limit'
- );
- (C.name = 'MaxListenersExceededWarning'),
- (C.emitter = s),
- (C.type = o),
- (C.count = x.length),
- (function ProcessEmitWarning(s) {
- console && console.warn && console.warn(s);
- })(C);
- }
- return s;
- }
- function onceWrapper() {
- if (!this.fired)
- return (
- this.target.removeListener(this.type, this.wrapFn),
- (this.fired = !0),
- 0 === arguments.length
- ? this.listener.call(this.target)
- : this.listener.apply(this.target, arguments)
- );
- }
- function _onceWrap(s, o, i) {
- var u = { fired: !1, wrapFn: void 0, target: s, type: o, listener: i },
- _ = onceWrapper.bind(u);
- return (_.listener = i), (u.wrapFn = _), _;
- }
- function _listeners(s, o, i) {
- var u = s._events;
- if (void 0 === u) return [];
- var _ = u[o];
- return void 0 === _
- ? []
- : 'function' == typeof _
- ? i
- ? [_.listener || _]
- : [_]
- : i
- ? (function unwrapListeners(s) {
- for (var o = new Array(s.length), i = 0; i < o.length; ++i)
- o[i] = s[i].listener || s[i];
- return o;
- })(_)
- : arrayClone(_, _.length);
- }
- function listenerCount(s) {
- var o = this._events;
- if (void 0 !== o) {
- var i = o[s];
- if ('function' == typeof i) return 1;
- if (void 0 !== i) return i.length;
- }
- return 0;
- }
- function arrayClone(s, o) {
- for (var i = new Array(o), u = 0; u < o; ++u) i[u] = s[u];
- return i;
- }
- function eventTargetAgnosticAddListener(s, o, i, u) {
- if ('function' == typeof s.on) u.once ? s.once(o, i) : s.on(o, i);
- else {
- if ('function' != typeof s.addEventListener)
- throw new TypeError(
- 'The "emitter" argument must be of type EventEmitter. Received type ' + typeof s
- );
- s.addEventListener(o, function wrapListener(_) {
- u.once && s.removeEventListener(o, wrapListener), i(_);
- });
- }
- }
- Object.defineProperty(EventEmitter, 'defaultMaxListeners', {
- enumerable: !0,
- get: function () {
- return w;
- },
- set: function (s) {
- if ('number' != typeof s || s < 0 || _(s))
- throw new RangeError(
- 'The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received ' +
- s +
- '.'
- );
- w = s;
- }
- }),
- (EventEmitter.init = function () {
- (void 0 !== this._events && this._events !== Object.getPrototypeOf(this)._events) ||
- ((this._events = Object.create(null)), (this._eventsCount = 0)),
- (this._maxListeners = this._maxListeners || void 0);
- }),
- (EventEmitter.prototype.setMaxListeners = function setMaxListeners(s) {
- if ('number' != typeof s || s < 0 || _(s))
- throw new RangeError(
- 'The value of "n" is out of range. It must be a non-negative number. Received ' +
- s +
- '.'
- );
- return (this._maxListeners = s), this;
- }),
- (EventEmitter.prototype.getMaxListeners = function getMaxListeners() {
- return _getMaxListeners(this);
- }),
- (EventEmitter.prototype.emit = function emit(s) {
- for (var o = [], i = 1; i < arguments.length; i++) o.push(arguments[i]);
- var _ = 'error' === s,
- w = this._events;
- if (void 0 !== w) _ = _ && void 0 === w.error;
- else if (!_) return !1;
- if (_) {
- var x;
- if ((o.length > 0 && (x = o[0]), x instanceof Error)) throw x;
- var C = new Error('Unhandled error.' + (x ? ' (' + x.message + ')' : ''));
- throw ((C.context = x), C);
- }
- var j = w[s];
- if (void 0 === j) return !1;
- if ('function' == typeof j) u(j, this, o);
- else {
- var L = j.length,
- B = arrayClone(j, L);
- for (i = 0; i < L; ++i) u(B[i], this, o);
- }
- return !0;
- }),
- (EventEmitter.prototype.addListener = function addListener(s, o) {
- return _addListener(this, s, o, !1);
- }),
- (EventEmitter.prototype.on = EventEmitter.prototype.addListener),
- (EventEmitter.prototype.prependListener = function prependListener(s, o) {
- return _addListener(this, s, o, !0);
- }),
- (EventEmitter.prototype.once = function once(s, o) {
- return checkListener(o), this.on(s, _onceWrap(this, s, o)), this;
- }),
- (EventEmitter.prototype.prependOnceListener = function prependOnceListener(s, o) {
- return checkListener(o), this.prependListener(s, _onceWrap(this, s, o)), this;
- }),
- (EventEmitter.prototype.removeListener = function removeListener(s, o) {
- var i, u, _, w, x;
- if ((checkListener(o), void 0 === (u = this._events))) return this;
- if (void 0 === (i = u[s])) return this;
- if (i === o || i.listener === o)
- 0 == --this._eventsCount
- ? (this._events = Object.create(null))
- : (delete u[s],
- u.removeListener && this.emit('removeListener', s, i.listener || o));
- else if ('function' != typeof i) {
- for (_ = -1, w = i.length - 1; w >= 0; w--)
- if (i[w] === o || i[w].listener === o) {
- (x = i[w].listener), (_ = w);
- break;
- }
- if (_ < 0) return this;
- 0 === _
- ? i.shift()
- : (function spliceOne(s, o) {
- for (; o + 1 < s.length; o++) s[o] = s[o + 1];
- s.pop();
- })(i, _),
- 1 === i.length && (u[s] = i[0]),
- void 0 !== u.removeListener && this.emit('removeListener', s, x || o);
- }
- return this;
- }),
- (EventEmitter.prototype.off = EventEmitter.prototype.removeListener),
- (EventEmitter.prototype.removeAllListeners = function removeAllListeners(s) {
- var o, i, u;
- if (void 0 === (i = this._events)) return this;
- if (void 0 === i.removeListener)
- return (
- 0 === arguments.length
- ? ((this._events = Object.create(null)), (this._eventsCount = 0))
- : void 0 !== i[s] &&
- (0 == --this._eventsCount
- ? (this._events = Object.create(null))
- : delete i[s]),
- this
- );
- if (0 === arguments.length) {
- var _,
- w = Object.keys(i);
- for (u = 0; u < w.length; ++u)
- 'removeListener' !== (_ = w[u]) && this.removeAllListeners(_);
- return (
- this.removeAllListeners('removeListener'),
- (this._events = Object.create(null)),
- (this._eventsCount = 0),
- this
- );
- }
- if ('function' == typeof (o = i[s])) this.removeListener(s, o);
- else if (void 0 !== o)
- for (u = o.length - 1; u >= 0; u--) this.removeListener(s, o[u]);
- return this;
- }),
- (EventEmitter.prototype.listeners = function listeners(s) {
- return _listeners(this, s, !0);
- }),
- (EventEmitter.prototype.rawListeners = function rawListeners(s) {
- return _listeners(this, s, !1);
- }),
- (EventEmitter.listenerCount = function (s, o) {
- return 'function' == typeof s.listenerCount
- ? s.listenerCount(o)
- : listenerCount.call(s, o);
- }),
- (EventEmitter.prototype.listenerCount = listenerCount),
- (EventEmitter.prototype.eventNames = function eventNames() {
- return this._eventsCount > 0 ? o(this._events) : [];
- });
- },
- 85587: (s, o, i) => {
- 'use strict';
- var u = i(26311),
- _ = create(Error);
- function create(s) {
- return (FormattedError.displayName = s.displayName || s.name), FormattedError;
- function FormattedError(o) {
- return o && (o = u.apply(null, arguments)), new s(o);
- }
- }
- (s.exports = _),
- (_.eval = create(EvalError)),
- (_.range = create(RangeError)),
- (_.reference = create(ReferenceError)),
- (_.syntax = create(SyntaxError)),
- (_.type = create(TypeError)),
- (_.uri = create(URIError)),
- (_.create = create);
- },
- 26311: (s) => {
- !(function () {
- var o;
- function format(s) {
- for (
- var o,
- i,
- u,
- _,
- w = 1,
- x = [].slice.call(arguments),
- C = 0,
- j = s.length,
- L = '',
- B = !1,
- $ = !1,
- nextArg = function () {
- return x[w++];
- },
- slurpNumber = function () {
- for (var i = ''; /\d/.test(s[C]); ) (i += s[C++]), (o = s[C]);
- return i.length > 0 ? parseInt(i) : null;
- };
- C < j;
- ++C
- )
- if (((o = s[C]), B))
- switch (
- ((B = !1),
- '.' == o
- ? (($ = !1), (o = s[++C]))
- : '0' == o && '.' == s[C + 1]
- ? (($ = !0), (o = s[(C += 2)]))
- : ($ = !0),
- (_ = slurpNumber()),
- o)
- ) {
- case 'b':
- L += parseInt(nextArg(), 10).toString(2);
- break;
- case 'c':
- L +=
- 'string' == typeof (i = nextArg()) || i instanceof String
- ? i
- : String.fromCharCode(parseInt(i, 10));
- break;
- case 'd':
- L += parseInt(nextArg(), 10);
- break;
- case 'f':
- (u = String(parseFloat(nextArg()).toFixed(_ || 6))),
- (L += $ ? u : u.replace(/^0/, ''));
- break;
- case 'j':
- L += JSON.stringify(nextArg());
- break;
- case 'o':
- L += '0' + parseInt(nextArg(), 10).toString(8);
- break;
- case 's':
- L += nextArg();
- break;
- case 'x':
- L += '0x' + parseInt(nextArg(), 10).toString(16);
- break;
- case 'X':
- L += '0x' + parseInt(nextArg(), 10).toString(16).toUpperCase();
- break;
- default:
- L += o;
- }
- else '%' === o ? (B = !0) : (L += o);
- return L;
- }
- ((o = s.exports = format).format = format),
- (o.vsprintf = function vsprintf(s, o) {
- return format.apply(null, [s].concat(o));
- }),
- 'undefined' != typeof console &&
- 'function' == typeof console.log &&
- (o.printf = function printf() {
- console.log(format.apply(null, arguments));
- });
- })();
- },
- 45981: (s) => {
- function deepFreeze(s) {
- return (
- s instanceof Map
- ? (s.clear =
- s.delete =
- s.set =
- function () {
- throw new Error('map is read-only');
- })
- : s instanceof Set &&
- (s.add =
- s.clear =
- s.delete =
- function () {
- throw new Error('set is read-only');
- }),
- Object.freeze(s),
- Object.getOwnPropertyNames(s).forEach(function (o) {
- var i = s[o];
- 'object' != typeof i || Object.isFrozen(i) || deepFreeze(i);
- }),
- s
- );
- }
- var o = deepFreeze,
- i = deepFreeze;
- o.default = i;
- class Response {
- constructor(s) {
- void 0 === s.data && (s.data = {}), (this.data = s.data), (this.isMatchIgnored = !1);
- }
- ignoreMatch() {
- this.isMatchIgnored = !0;
- }
- }
- function escapeHTML(s) {
- return s
- .replace(/&/g, '&')
- .replace(/</g, '<')
- .replace(/>/g, '>')
- .replace(/"/g, '"')
- .replace(/'/g, ''');
- }
- function inherit(s, ...o) {
- const i = Object.create(null);
- for (const o in s) i[o] = s[o];
- return (
- o.forEach(function (s) {
- for (const o in s) i[o] = s[o];
- }),
- i
- );
- }
- const emitsWrappingTags = (s) => !!s.kind;
- class HTMLRenderer {
- constructor(s, o) {
- (this.buffer = ''), (this.classPrefix = o.classPrefix), s.walk(this);
- }
- addText(s) {
- this.buffer += escapeHTML(s);
- }
- openNode(s) {
- if (!emitsWrappingTags(s)) return;
- let o = s.kind;
- s.sublanguage || (o = `${this.classPrefix}${o}`), this.span(o);
- }
- closeNode(s) {
- emitsWrappingTags(s) && (this.buffer += '</span>');
- }
- value() {
- return this.buffer;
- }
- span(s) {
- this.buffer += `<span class="${s}">`;
- }
- }
- class TokenTree {
- constructor() {
- (this.rootNode = { children: [] }), (this.stack = [this.rootNode]);
- }
- get top() {
- return this.stack[this.stack.length - 1];
- }
- get root() {
- return this.rootNode;
- }
- add(s) {
- this.top.children.push(s);
- }
- openNode(s) {
- const o = { kind: s, children: [] };
- this.add(o), this.stack.push(o);
- }
- closeNode() {
- if (this.stack.length > 1) return this.stack.pop();
- }
- closeAllNodes() {
- for (; this.closeNode(); );
- }
- toJSON() {
- return JSON.stringify(this.rootNode, null, 4);
- }
- walk(s) {
- return this.constructor._walk(s, this.rootNode);
- }
- static _walk(s, o) {
- return (
- 'string' == typeof o
- ? s.addText(o)
- : o.children &&
- (s.openNode(o), o.children.forEach((o) => this._walk(s, o)), s.closeNode(o)),
- s
- );
- }
- static _collapse(s) {
- 'string' != typeof s &&
- s.children &&
- (s.children.every((s) => 'string' == typeof s)
- ? (s.children = [s.children.join('')])
- : s.children.forEach((s) => {
- TokenTree._collapse(s);
- }));
- }
- }
- class TokenTreeEmitter extends TokenTree {
- constructor(s) {
- super(), (this.options = s);
- }
- addKeyword(s, o) {
- '' !== s && (this.openNode(o), this.addText(s), this.closeNode());
- }
- addText(s) {
- '' !== s && this.add(s);
- }
- addSublanguage(s, o) {
- const i = s.root;
- (i.kind = o), (i.sublanguage = !0), this.add(i);
- }
- toHTML() {
- return new HTMLRenderer(this, this.options).value();
- }
- finalize() {
- return !0;
- }
- }
- function source(s) {
- return s ? ('string' == typeof s ? s : s.source) : null;
- }
- const u = /\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;
- const _ = '[a-zA-Z]\\w*',
- w = '[a-zA-Z_]\\w*',
- x = '\\b\\d+(\\.\\d+)?',
- C = '(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)',
- j = '\\b(0b[01]+)',
- L = { begin: '\\\\[\\s\\S]', relevance: 0 },
- B = { className: 'string', begin: "'", end: "'", illegal: '\\n', contains: [L] },
- $ = { className: 'string', begin: '"', end: '"', illegal: '\\n', contains: [L] },
- V = {
- begin:
- /\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/
- },
- COMMENT = function (s, o, i = {}) {
- const u = inherit({ className: 'comment', begin: s, end: o, contains: [] }, i);
- return (
- u.contains.push(V),
- u.contains.push({
- className: 'doctag',
- begin: '(?:TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):',
- relevance: 0
- }),
- u
- );
- },
- U = COMMENT('//', '$'),
- z = COMMENT('/\\*', '\\*/'),
- Y = COMMENT('#', '$'),
- Z = { className: 'number', begin: x, relevance: 0 },
- ee = { className: 'number', begin: C, relevance: 0 },
- ie = { className: 'number', begin: j, relevance: 0 },
- ae = {
- className: 'number',
- begin:
- x +
- '(%|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|px|deg|grad|rad|turn|s|ms|Hz|kHz|dpi|dpcm|dppx)?',
- relevance: 0
- },
- le = {
- begin: /(?=\/[^/\n]*\/)/,
- contains: [
- {
- className: 'regexp',
- begin: /\//,
- end: /\/[gimuy]*/,
- illegal: /\n/,
- contains: [L, { begin: /\[/, end: /\]/, relevance: 0, contains: [L] }]
- }
- ]
- },
- ce = { className: 'title', begin: _, relevance: 0 },
- pe = { className: 'title', begin: w, relevance: 0 },
- de = { begin: '\\.\\s*' + w, relevance: 0 };
- var fe = Object.freeze({
- __proto__: null,
- MATCH_NOTHING_RE: /\b\B/,
- IDENT_RE: _,
- UNDERSCORE_IDENT_RE: w,
- NUMBER_RE: x,
- C_NUMBER_RE: C,
- BINARY_NUMBER_RE: j,
- RE_STARTERS_RE:
- '!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~',
- SHEBANG: (s = {}) => {
- const o = /^#![ ]*\//;
- return (
- s.binary &&
- (s.begin = (function concat(...s) {
- return s.map((s) => source(s)).join('');
- })(o, /.*\b/, s.binary, /\b.*/)),
- inherit(
- {
- className: 'meta',
- begin: o,
- end: /$/,
- relevance: 0,
- 'on:begin': (s, o) => {
- 0 !== s.index && o.ignoreMatch();
- }
- },
- s
- )
- );
- },
- BACKSLASH_ESCAPE: L,
- APOS_STRING_MODE: B,
- QUOTE_STRING_MODE: $,
- PHRASAL_WORDS_MODE: V,
- COMMENT,
- C_LINE_COMMENT_MODE: U,
- C_BLOCK_COMMENT_MODE: z,
- HASH_COMMENT_MODE: Y,
- NUMBER_MODE: Z,
- C_NUMBER_MODE: ee,
- BINARY_NUMBER_MODE: ie,
- CSS_NUMBER_MODE: ae,
- REGEXP_MODE: le,
- TITLE_MODE: ce,
- UNDERSCORE_TITLE_MODE: pe,
- METHOD_GUARD: de,
- END_SAME_AS_BEGIN: function (s) {
- return Object.assign(s, {
- 'on:begin': (s, o) => {
- o.data._beginMatch = s[1];
- },
- 'on:end': (s, o) => {
- o.data._beginMatch !== s[1] && o.ignoreMatch();
- }
- });
- }
- });
- function skipIfhasPrecedingDot(s, o) {
- '.' === s.input[s.index - 1] && o.ignoreMatch();
- }
- function beginKeywords(s, o) {
- o &&
- s.beginKeywords &&
- ((s.begin = '\\b(' + s.beginKeywords.split(' ').join('|') + ')(?!\\.)(?=\\b|\\s)'),
- (s.__beforeBegin = skipIfhasPrecedingDot),
- (s.keywords = s.keywords || s.beginKeywords),
- delete s.beginKeywords,
- void 0 === s.relevance && (s.relevance = 0));
- }
- function compileIllegal(s, o) {
- Array.isArray(s.illegal) &&
- (s.illegal = (function either(...s) {
- return '(' + s.map((s) => source(s)).join('|') + ')';
- })(...s.illegal));
- }
- function compileMatch(s, o) {
- if (s.match) {
- if (s.begin || s.end) throw new Error('begin & end are not supported with match');
- (s.begin = s.match), delete s.match;
- }
- }
- function compileRelevance(s, o) {
- void 0 === s.relevance && (s.relevance = 1);
- }
- const ye = [
- 'of',
- 'and',
- 'for',
- 'in',
- 'not',
- 'or',
- 'if',
- 'then',
- 'parent',
- 'list',
- 'value'
- ];
- function compileKeywords(s, o, i = 'keyword') {
- const u = {};
- return (
- 'string' == typeof s
- ? compileList(i, s.split(' '))
- : Array.isArray(s)
- ? compileList(i, s)
- : Object.keys(s).forEach(function (i) {
- Object.assign(u, compileKeywords(s[i], o, i));
- }),
- u
- );
- function compileList(s, i) {
- o && (i = i.map((s) => s.toLowerCase())),
- i.forEach(function (o) {
- const i = o.split('|');
- u[i[0]] = [s, scoreForKeyword(i[0], i[1])];
- });
- }
- }
- function scoreForKeyword(s, o) {
- return o
- ? Number(o)
- : (function commonKeyword(s) {
- return ye.includes(s.toLowerCase());
- })(s)
- ? 0
- : 1;
- }
- function compileLanguage(s, { plugins: o }) {
- function langRe(o, i) {
- return new RegExp(source(o), 'm' + (s.case_insensitive ? 'i' : '') + (i ? 'g' : ''));
- }
- class MultiRegex {
- constructor() {
- (this.matchIndexes = {}),
- (this.regexes = []),
- (this.matchAt = 1),
- (this.position = 0);
- }
- addRule(s, o) {
- (o.position = this.position++),
- (this.matchIndexes[this.matchAt] = o),
- this.regexes.push([o, s]),
- (this.matchAt +=
- (function countMatchGroups(s) {
- return new RegExp(s.toString() + '|').exec('').length - 1;
- })(s) + 1);
- }
- compile() {
- 0 === this.regexes.length && (this.exec = () => null);
- const s = this.regexes.map((s) => s[1]);
- (this.matcherRe = langRe(
- (function join(s, o = '|') {
- let i = 0;
- return s
- .map((s) => {
- i += 1;
- const o = i;
- let _ = source(s),
- w = '';
- for (; _.length > 0; ) {
- const s = u.exec(_);
- if (!s) {
- w += _;
- break;
- }
- (w += _.substring(0, s.index)),
- (_ = _.substring(s.index + s[0].length)),
- '\\' === s[0][0] && s[1]
- ? (w += '\\' + String(Number(s[1]) + o))
- : ((w += s[0]), '(' === s[0] && i++);
- }
- return w;
- })
- .map((s) => `(${s})`)
- .join(o);
- })(s),
- !0
- )),
- (this.lastIndex = 0);
- }
- exec(s) {
- this.matcherRe.lastIndex = this.lastIndex;
- const o = this.matcherRe.exec(s);
- if (!o) return null;
- const i = o.findIndex((s, o) => o > 0 && void 0 !== s),
- u = this.matchIndexes[i];
- return o.splice(0, i), Object.assign(o, u);
- }
- }
- class ResumableMultiRegex {
- constructor() {
- (this.rules = []),
- (this.multiRegexes = []),
- (this.count = 0),
- (this.lastIndex = 0),
- (this.regexIndex = 0);
- }
- getMatcher(s) {
- if (this.multiRegexes[s]) return this.multiRegexes[s];
- const o = new MultiRegex();
- return (
- this.rules.slice(s).forEach(([s, i]) => o.addRule(s, i)),
- o.compile(),
- (this.multiRegexes[s] = o),
- o
- );
- }
- resumingScanAtSamePosition() {
- return 0 !== this.regexIndex;
- }
- considerAll() {
- this.regexIndex = 0;
- }
- addRule(s, o) {
- this.rules.push([s, o]), 'begin' === o.type && this.count++;
- }
- exec(s) {
- const o = this.getMatcher(this.regexIndex);
- o.lastIndex = this.lastIndex;
- let i = o.exec(s);
- if (this.resumingScanAtSamePosition())
- if (i && i.index === this.lastIndex);
- else {
- const o = this.getMatcher(0);
- (o.lastIndex = this.lastIndex + 1), (i = o.exec(s));
- }
- return (
- i &&
- ((this.regexIndex += i.position + 1),
- this.regexIndex === this.count && this.considerAll()),
- i
- );
- }
- }
- if (
- (s.compilerExtensions || (s.compilerExtensions = []),
- s.contains && s.contains.includes('self'))
- )
- throw new Error(
- 'ERR: contains `self` is not supported at the top-level of a language. See documentation.'
- );
- return (
- (s.classNameAliases = inherit(s.classNameAliases || {})),
- (function compileMode(o, i) {
- const u = o;
- if (o.isCompiled) return u;
- [compileMatch].forEach((s) => s(o, i)),
- s.compilerExtensions.forEach((s) => s(o, i)),
- (o.__beforeBegin = null),
- [beginKeywords, compileIllegal, compileRelevance].forEach((s) => s(o, i)),
- (o.isCompiled = !0);
- let _ = null;
- if (
- ('object' == typeof o.keywords &&
- ((_ = o.keywords.$pattern), delete o.keywords.$pattern),
- o.keywords && (o.keywords = compileKeywords(o.keywords, s.case_insensitive)),
- o.lexemes && _)
- )
- throw new Error(
- 'ERR: Prefer `keywords.$pattern` to `mode.lexemes`, BOTH are not allowed. (see mode reference) '
- );
- return (
- (_ = _ || o.lexemes || /\w+/),
- (u.keywordPatternRe = langRe(_, !0)),
- i &&
- (o.begin || (o.begin = /\B|\b/),
- (u.beginRe = langRe(o.begin)),
- o.endSameAsBegin && (o.end = o.begin),
- o.end || o.endsWithParent || (o.end = /\B|\b/),
- o.end && (u.endRe = langRe(o.end)),
- (u.terminatorEnd = source(o.end) || ''),
- o.endsWithParent &&
- i.terminatorEnd &&
- (u.terminatorEnd += (o.end ? '|' : '') + i.terminatorEnd)),
- o.illegal && (u.illegalRe = langRe(o.illegal)),
- o.contains || (o.contains = []),
- (o.contains = [].concat(
- ...o.contains.map(function (s) {
- return (function expandOrCloneMode(s) {
- s.variants &&
- !s.cachedVariants &&
- (s.cachedVariants = s.variants.map(function (o) {
- return inherit(s, { variants: null }, o);
- }));
- if (s.cachedVariants) return s.cachedVariants;
- if (dependencyOnParent(s))
- return inherit(s, { starts: s.starts ? inherit(s.starts) : null });
- if (Object.isFrozen(s)) return inherit(s);
- return s;
- })('self' === s ? o : s);
- })
- )),
- o.contains.forEach(function (s) {
- compileMode(s, u);
- }),
- o.starts && compileMode(o.starts, i),
- (u.matcher = (function buildModeRegex(s) {
- const o = new ResumableMultiRegex();
- return (
- s.contains.forEach((s) => o.addRule(s.begin, { rule: s, type: 'begin' })),
- s.terminatorEnd && o.addRule(s.terminatorEnd, { type: 'end' }),
- s.illegal && o.addRule(s.illegal, { type: 'illegal' }),
- o
- );
- })(u)),
- u
- );
- })(s)
- );
- }
- function dependencyOnParent(s) {
- return !!s && (s.endsWithParent || dependencyOnParent(s.starts));
- }
- function BuildVuePlugin(s) {
- const o = {
- props: ['language', 'code', 'autodetect'],
- data: function () {
- return { detectedLanguage: '', unknownLanguage: !1 };
- },
- computed: {
- className() {
- return this.unknownLanguage ? '' : 'hljs ' + this.detectedLanguage;
- },
- highlighted() {
- if (!this.autoDetect && !s.getLanguage(this.language))
- return (
- console.warn(
- `The language "${this.language}" you specified could not be found.`
- ),
- (this.unknownLanguage = !0),
- escapeHTML(this.code)
- );
- let o = {};
- return (
- this.autoDetect
- ? ((o = s.highlightAuto(this.code)), (this.detectedLanguage = o.language))
- : ((o = s.highlight(this.language, this.code, this.ignoreIllegals)),
- (this.detectedLanguage = this.language)),
- o.value
- );
- },
- autoDetect() {
- return (
- !this.language ||
- (function hasValueOrEmptyAttribute(s) {
- return Boolean(s || '' === s);
- })(this.autodetect)
- );
- },
- ignoreIllegals: () => !0
- },
- render(s) {
- return s('pre', {}, [
- s('code', { class: this.className, domProps: { innerHTML: this.highlighted } })
- ]);
- }
- };
- return {
- Component: o,
- VuePlugin: {
- install(s) {
- s.component('highlightjs', o);
- }
- }
- };
- }
- const be = {
- 'after:highlightElement': ({ el: s, result: o, text: i }) => {
- const u = nodeStream(s);
- if (!u.length) return;
- const _ = document.createElement('div');
- (_.innerHTML = o.value),
- (o.value = (function mergeStreams(s, o, i) {
- let u = 0,
- _ = '';
- const w = [];
- function selectStream() {
- return s.length && o.length
- ? s[0].offset !== o[0].offset
- ? s[0].offset < o[0].offset
- ? s
- : o
- : 'start' === o[0].event
- ? s
- : o
- : s.length
- ? s
- : o;
- }
- function open(s) {
- function attributeString(s) {
- return ' ' + s.nodeName + '="' + escapeHTML(s.value) + '"';
- }
- _ += '<' + tag(s) + [].map.call(s.attributes, attributeString).join('') + '>';
- }
- function close(s) {
- _ += '</' + tag(s) + '>';
- }
- function render(s) {
- ('start' === s.event ? open : close)(s.node);
- }
- for (; s.length || o.length; ) {
- let o = selectStream();
- if (
- ((_ += escapeHTML(i.substring(u, o[0].offset))), (u = o[0].offset), o === s)
- ) {
- w.reverse().forEach(close);
- do {
- render(o.splice(0, 1)[0]), (o = selectStream());
- } while (o === s && o.length && o[0].offset === u);
- w.reverse().forEach(open);
- } else
- 'start' === o[0].event ? w.push(o[0].node) : w.pop(),
- render(o.splice(0, 1)[0]);
- }
- return _ + escapeHTML(i.substr(u));
- })(u, nodeStream(_), i));
- }
- };
- function tag(s) {
- return s.nodeName.toLowerCase();
- }
- function nodeStream(s) {
- const o = [];
- return (
- (function _nodeStream(s, i) {
- for (let u = s.firstChild; u; u = u.nextSibling)
- 3 === u.nodeType
- ? (i += u.nodeValue.length)
- : 1 === u.nodeType &&
- (o.push({ event: 'start', offset: i, node: u }),
- (i = _nodeStream(u, i)),
- tag(u).match(/br|hr|img|input/) ||
- o.push({ event: 'stop', offset: i, node: u }));
- return i;
- })(s, 0),
- o
- );
- }
- const _e = {},
- error = (s) => {
- console.error(s);
- },
- warn = (s, ...o) => {
- console.log(`WARN: ${s}`, ...o);
- },
- deprecated = (s, o) => {
- _e[`${s}/${o}`] ||
- (console.log(`Deprecated as of ${s}. ${o}`), (_e[`${s}/${o}`] = !0));
- },
- we = escapeHTML,
- Se = inherit,
- xe = Symbol('nomatch');
- var Pe = (function (s) {
- const i = Object.create(null),
- u = Object.create(null),
- _ = [];
- let w = !0;
- const x = /(^(<[^>]+>|\t|)+|\n)/gm,
- C =
- "Could not find the language '{}', did you forget to load/include a language module?",
- j = { disableAutodetect: !0, name: 'Plain text', contains: [] };
- let L = {
- noHighlightRe: /^(no-?highlight)$/i,
- languageDetectRe: /\blang(?:uage)?-([\w-]+)\b/i,
- classPrefix: 'hljs-',
- tabReplace: null,
- useBR: !1,
- languages: null,
- __emitter: TokenTreeEmitter
- };
- function shouldNotHighlight(s) {
- return L.noHighlightRe.test(s);
- }
- function highlight(s, o, i, u) {
- let _ = '',
- w = '';
- 'object' == typeof o
- ? ((_ = s), (i = o.ignoreIllegals), (w = o.language), (u = void 0))
- : (deprecated('10.7.0', 'highlight(lang, code, ...args) has been deprecated.'),
- deprecated(
- '10.7.0',
- 'Please use highlight(code, options) instead.\nhttps://github.com/highlightjs/highlight.js/issues/2277'
- ),
- (w = s),
- (_ = o));
- const x = { code: _, language: w };
- fire('before:highlight', x);
- const C = x.result ? x.result : _highlight(x.language, x.code, i, u);
- return (C.code = x.code), fire('after:highlight', C), C;
- }
- function _highlight(s, o, u, x) {
- function keywordData(s, o) {
- const i = B.case_insensitive ? o[0].toLowerCase() : o[0];
- return Object.prototype.hasOwnProperty.call(s.keywords, i) && s.keywords[i];
- }
- function processBuffer() {
- null != U.subLanguage
- ? (function processSubLanguage() {
- if ('' === Z) return;
- let s = null;
- if ('string' == typeof U.subLanguage) {
- if (!i[U.subLanguage]) return void Y.addText(Z);
- (s = _highlight(U.subLanguage, Z, !0, z[U.subLanguage])),
- (z[U.subLanguage] = s.top);
- } else s = highlightAuto(Z, U.subLanguage.length ? U.subLanguage : null);
- U.relevance > 0 && (ee += s.relevance),
- Y.addSublanguage(s.emitter, s.language);
- })()
- : (function processKeywords() {
- if (!U.keywords) return void Y.addText(Z);
- let s = 0;
- U.keywordPatternRe.lastIndex = 0;
- let o = U.keywordPatternRe.exec(Z),
- i = '';
- for (; o; ) {
- i += Z.substring(s, o.index);
- const u = keywordData(U, o);
- if (u) {
- const [s, _] = u;
- if ((Y.addText(i), (i = ''), (ee += _), s.startsWith('_'))) i += o[0];
- else {
- const i = B.classNameAliases[s] || s;
- Y.addKeyword(o[0], i);
- }
- } else i += o[0];
- (s = U.keywordPatternRe.lastIndex), (o = U.keywordPatternRe.exec(Z));
- }
- (i += Z.substr(s)), Y.addText(i);
- })(),
- (Z = '');
- }
- function startNewMode(s) {
- return (
- s.className && Y.openNode(B.classNameAliases[s.className] || s.className),
- (U = Object.create(s, { parent: { value: U } })),
- U
- );
- }
- function endOfMode(s, o, i) {
- let u = (function startsWith(s, o) {
- const i = s && s.exec(o);
- return i && 0 === i.index;
- })(s.endRe, i);
- if (u) {
- if (s['on:end']) {
- const i = new Response(s);
- s['on:end'](o, i), i.isMatchIgnored && (u = !1);
- }
- if (u) {
- for (; s.endsParent && s.parent; ) s = s.parent;
- return s;
- }
- }
- if (s.endsWithParent) return endOfMode(s.parent, o, i);
- }
- function doIgnore(s) {
- return 0 === U.matcher.regexIndex ? ((Z += s[0]), 1) : ((le = !0), 0);
- }
- function doBeginMatch(s) {
- const o = s[0],
- i = s.rule,
- u = new Response(i),
- _ = [i.__beforeBegin, i['on:begin']];
- for (const i of _) if (i && (i(s, u), u.isMatchIgnored)) return doIgnore(o);
- return (
- i &&
- i.endSameAsBegin &&
- (i.endRe = (function escape(s) {
- return new RegExp(s.replace(/[-/\\^$*+?.()|[\]{}]/g, '\\$&'), 'm');
- })(o)),
- i.skip
- ? (Z += o)
- : (i.excludeBegin && (Z += o),
- processBuffer(),
- i.returnBegin || i.excludeBegin || (Z = o)),
- startNewMode(i),
- i.returnBegin ? 0 : o.length
- );
- }
- function doEndMatch(s) {
- const i = s[0],
- u = o.substr(s.index),
- _ = endOfMode(U, s, u);
- if (!_) return xe;
- const w = U;
- w.skip
- ? (Z += i)
- : (w.returnEnd || w.excludeEnd || (Z += i),
- processBuffer(),
- w.excludeEnd && (Z = i));
- do {
- U.className && Y.closeNode(),
- U.skip || U.subLanguage || (ee += U.relevance),
- (U = U.parent);
- } while (U !== _.parent);
- return (
- _.starts &&
- (_.endSameAsBegin && (_.starts.endRe = _.endRe), startNewMode(_.starts)),
- w.returnEnd ? 0 : i.length
- );
- }
- let j = {};
- function processLexeme(i, _) {
- const x = _ && _[0];
- if (((Z += i), null == x)) return processBuffer(), 0;
- if ('begin' === j.type && 'end' === _.type && j.index === _.index && '' === x) {
- if (((Z += o.slice(_.index, _.index + 1)), !w)) {
- const o = new Error('0 width match regex');
- throw ((o.languageName = s), (o.badRule = j.rule), o);
- }
- return 1;
- }
- if (((j = _), 'begin' === _.type)) return doBeginMatch(_);
- if ('illegal' === _.type && !u) {
- const s = new Error(
- 'Illegal lexeme "' + x + '" for mode "' + (U.className || '<unnamed>') + '"'
- );
- throw ((s.mode = U), s);
- }
- if ('end' === _.type) {
- const s = doEndMatch(_);
- if (s !== xe) return s;
- }
- if ('illegal' === _.type && '' === x) return 1;
- if (ae > 1e5 && ae > 3 * _.index) {
- throw new Error('potential infinite loop, way more iterations than matches');
- }
- return (Z += x), x.length;
- }
- const B = getLanguage(s);
- if (!B) throw (error(C.replace('{}', s)), new Error('Unknown language: "' + s + '"'));
- const $ = compileLanguage(B, { plugins: _ });
- let V = '',
- U = x || $;
- const z = {},
- Y = new L.__emitter(L);
- !(function processContinuations() {
- const s = [];
- for (let o = U; o !== B; o = o.parent) o.className && s.unshift(o.className);
- s.forEach((s) => Y.openNode(s));
- })();
- let Z = '',
- ee = 0,
- ie = 0,
- ae = 0,
- le = !1;
- try {
- for (U.matcher.considerAll(); ; ) {
- ae++, le ? (le = !1) : U.matcher.considerAll(), (U.matcher.lastIndex = ie);
- const s = U.matcher.exec(o);
- if (!s) break;
- const i = processLexeme(o.substring(ie, s.index), s);
- ie = s.index + i;
- }
- return (
- processLexeme(o.substr(ie)),
- Y.closeAllNodes(),
- Y.finalize(),
- (V = Y.toHTML()),
- {
- relevance: Math.floor(ee),
- value: V,
- language: s,
- illegal: !1,
- emitter: Y,
- top: U
- }
- );
- } catch (i) {
- if (i.message && i.message.includes('Illegal'))
- return {
- illegal: !0,
- illegalBy: {
- msg: i.message,
- context: o.slice(ie - 100, ie + 100),
- mode: i.mode
- },
- sofar: V,
- relevance: 0,
- value: we(o),
- emitter: Y
- };
- if (w)
- return {
- illegal: !1,
- relevance: 0,
- value: we(o),
- emitter: Y,
- language: s,
- top: U,
- errorRaised: i
- };
- throw i;
- }
- }
- function highlightAuto(s, o) {
- o = o || L.languages || Object.keys(i);
- const u = (function justTextHighlightResult(s) {
- const o = {
- relevance: 0,
- emitter: new L.__emitter(L),
- value: we(s),
- illegal: !1,
- top: j
- };
- return o.emitter.addText(s), o;
- })(s),
- _ = o
- .filter(getLanguage)
- .filter(autoDetection)
- .map((o) => _highlight(o, s, !1));
- _.unshift(u);
- const w = _.sort((s, o) => {
- if (s.relevance !== o.relevance) return o.relevance - s.relevance;
- if (s.language && o.language) {
- if (getLanguage(s.language).supersetOf === o.language) return 1;
- if (getLanguage(o.language).supersetOf === s.language) return -1;
- }
- return 0;
- }),
- [x, C] = w,
- B = x;
- return (B.second_best = C), B;
- }
- const B = {
- 'before:highlightElement': ({ el: s }) => {
- L.useBR &&
- (s.innerHTML = s.innerHTML.replace(/\n/g, '').replace(/<br[ /]*>/g, '\n'));
- },
- 'after:highlightElement': ({ result: s }) => {
- L.useBR && (s.value = s.value.replace(/\n/g, '<br>'));
- }
- },
- $ = /^(<[^>]+>|\t)+/gm,
- V = {
- 'after:highlightElement': ({ result: s }) => {
- L.tabReplace &&
- (s.value = s.value.replace($, (s) => s.replace(/\t/g, L.tabReplace)));
- }
- };
- function highlightElement(s) {
- let o = null;
- const i = (function blockLanguage(s) {
- let o = s.className + ' ';
- o += s.parentNode ? s.parentNode.className : '';
- const i = L.languageDetectRe.exec(o);
- if (i) {
- const o = getLanguage(i[1]);
- return (
- o ||
- (warn(C.replace('{}', i[1])),
- warn('Falling back to no-highlight mode for this block.', s)),
- o ? i[1] : 'no-highlight'
- );
- }
- return o.split(/\s+/).find((s) => shouldNotHighlight(s) || getLanguage(s));
- })(s);
- if (shouldNotHighlight(i)) return;
- fire('before:highlightElement', { el: s, language: i }), (o = s);
- const _ = o.textContent,
- w = i ? highlight(_, { language: i, ignoreIllegals: !0 }) : highlightAuto(_);
- fire('after:highlightElement', { el: s, result: w, text: _ }),
- (s.innerHTML = w.value),
- (function updateClassName(s, o, i) {
- const _ = o ? u[o] : i;
- s.classList.add('hljs'), _ && s.classList.add(_);
- })(s, i, w.language),
- (s.result = { language: w.language, re: w.relevance, relavance: w.relevance }),
- w.second_best &&
- (s.second_best = {
- language: w.second_best.language,
- re: w.second_best.relevance,
- relavance: w.second_best.relevance
- });
- }
- const initHighlighting = () => {
- if (initHighlighting.called) return;
- (initHighlighting.called = !0),
- deprecated(
- '10.6.0',
- 'initHighlighting() is deprecated. Use highlightAll() instead.'
- );
- document.querySelectorAll('pre code').forEach(highlightElement);
- };
- let U = !1;
- function highlightAll() {
- if ('loading' === document.readyState) return void (U = !0);
- document.querySelectorAll('pre code').forEach(highlightElement);
- }
- function getLanguage(s) {
- return (s = (s || '').toLowerCase()), i[s] || i[u[s]];
- }
- function registerAliases(s, { languageName: o }) {
- 'string' == typeof s && (s = [s]),
- s.forEach((s) => {
- u[s.toLowerCase()] = o;
- });
- }
- function autoDetection(s) {
- const o = getLanguage(s);
- return o && !o.disableAutodetect;
- }
- function fire(s, o) {
- const i = s;
- _.forEach(function (s) {
- s[i] && s[i](o);
- });
- }
- 'undefined' != typeof window &&
- window.addEventListener &&
- window.addEventListener(
- 'DOMContentLoaded',
- function boot() {
- U && highlightAll();
- },
- !1
- ),
- Object.assign(s, {
- highlight,
- highlightAuto,
- highlightAll,
- fixMarkup: function deprecateFixMarkup(s) {
- return (
- deprecated('10.2.0', 'fixMarkup will be removed entirely in v11.0'),
- deprecated(
- '10.2.0',
- 'Please see https://github.com/highlightjs/highlight.js/issues/2534'
- ),
- (function fixMarkup(s) {
- return L.tabReplace || L.useBR
- ? s.replace(x, (s) =>
- '\n' === s
- ? L.useBR
- ? '<br>'
- : s
- : L.tabReplace
- ? s.replace(/\t/g, L.tabReplace)
- : s
- )
- : s;
- })(s)
- );
- },
- highlightElement,
- highlightBlock: function deprecateHighlightBlock(s) {
- return (
- deprecated('10.7.0', 'highlightBlock will be removed entirely in v12.0'),
- deprecated('10.7.0', 'Please use highlightElement now.'),
- highlightElement(s)
- );
- },
- configure: function configure(s) {
- s.useBR &&
- (deprecated('10.3.0', "'useBR' will be removed entirely in v11.0"),
- deprecated(
- '10.3.0',
- 'Please see https://github.com/highlightjs/highlight.js/issues/2559'
- )),
- (L = Se(L, s));
- },
- initHighlighting,
- initHighlightingOnLoad: function initHighlightingOnLoad() {
- deprecated(
- '10.6.0',
- 'initHighlightingOnLoad() is deprecated. Use highlightAll() instead.'
- ),
- (U = !0);
- },
- registerLanguage: function registerLanguage(o, u) {
- let _ = null;
- try {
- _ = u(s);
- } catch (s) {
- if (
- (error(
- "Language definition for '{}' could not be registered.".replace('{}', o)
- ),
- !w)
- )
- throw s;
- error(s), (_ = j);
- }
- _.name || (_.name = o),
- (i[o] = _),
- (_.rawDefinition = u.bind(null, s)),
- _.aliases && registerAliases(_.aliases, { languageName: o });
- },
- unregisterLanguage: function unregisterLanguage(s) {
- delete i[s];
- for (const o of Object.keys(u)) u[o] === s && delete u[o];
- },
- listLanguages: function listLanguages() {
- return Object.keys(i);
- },
- getLanguage,
- registerAliases,
- requireLanguage: function requireLanguage(s) {
- deprecated('10.4.0', 'requireLanguage will be removed entirely in v11.'),
- deprecated(
- '10.4.0',
- 'Please see https://github.com/highlightjs/highlight.js/pull/2844'
- );
- const o = getLanguage(s);
- if (o) return o;
- throw new Error(
- "The '{}' language is required, but not loaded.".replace('{}', s)
- );
- },
- autoDetection,
- inherit: Se,
- addPlugin: function addPlugin(s) {
- !(function upgradePluginAPI(s) {
- s['before:highlightBlock'] &&
- !s['before:highlightElement'] &&
- (s['before:highlightElement'] = (o) => {
- s['before:highlightBlock'](Object.assign({ block: o.el }, o));
- }),
- s['after:highlightBlock'] &&
- !s['after:highlightElement'] &&
- (s['after:highlightElement'] = (o) => {
- s['after:highlightBlock'](Object.assign({ block: o.el }, o));
- });
- })(s),
- _.push(s);
- },
- vuePlugin: BuildVuePlugin(s).VuePlugin
- }),
- (s.debugMode = function () {
- w = !1;
- }),
- (s.safeMode = function () {
- w = !0;
- }),
- (s.versionString = '10.7.3');
- for (const s in fe) 'object' == typeof fe[s] && o(fe[s]);
- return Object.assign(s, fe), s.addPlugin(B), s.addPlugin(be), s.addPlugin(V), s;
- })({});
- s.exports = Pe;
- },
- 35344: (s) => {
- function concat(...s) {
- return s
- .map((s) =>
- (function source(s) {
- return s ? ('string' == typeof s ? s : s.source) : null;
- })(s)
- )
- .join('');
- }
- s.exports = function bash(s) {
- const o = {},
- i = { begin: /\$\{/, end: /\}/, contains: ['self', { begin: /:-/, contains: [o] }] };
- Object.assign(o, {
- className: 'variable',
- variants: [{ begin: concat(/\$[\w\d#@][\w\d_]*/, '(?![\\w\\d])(?![$])') }, i]
- });
- const u = {
- className: 'subst',
- begin: /\$\(/,
- end: /\)/,
- contains: [s.BACKSLASH_ESCAPE]
- },
- _ = {
- begin: /<<-?\s*(?=\w+)/,
- starts: {
- contains: [
- s.END_SAME_AS_BEGIN({ begin: /(\w+)/, end: /(\w+)/, className: 'string' })
- ]
- }
- },
- w = {
- className: 'string',
- begin: /"/,
- end: /"/,
- contains: [s.BACKSLASH_ESCAPE, o, u]
- };
- u.contains.push(w);
- const x = {
- begin: /\$\(\(/,
- end: /\)\)/,
- contains: [{ begin: /\d+#[0-9a-f]+/, className: 'number' }, s.NUMBER_MODE, o]
- },
- C = s.SHEBANG({
- binary: `(${['fish', 'bash', 'zsh', 'sh', 'csh', 'ksh', 'tcsh', 'dash', 'scsh'].join('|')})`,
- relevance: 10
- }),
- j = {
- className: 'function',
- begin: /\w[\w\d_]*\s*\(\s*\)\s*\{/,
- returnBegin: !0,
- contains: [s.inherit(s.TITLE_MODE, { begin: /\w[\w\d_]*/ })],
- relevance: 0
- };
- return {
- name: 'Bash',
- aliases: ['sh', 'zsh'],
- keywords: {
- $pattern: /\b[a-z._-]+\b/,
- keyword: 'if then else elif fi for while in do done case esac function',
- literal: 'true false',
- built_in:
- 'break cd continue eval exec exit export getopts hash pwd readonly return shift test times trap umask unset alias bind builtin caller command declare echo enable help let local logout mapfile printf read readarray source type typeset ulimit unalias set shopt autoload bg bindkey bye cap chdir clone comparguments compcall compctl compdescribe compfiles compgroups compquote comptags comptry compvalues dirs disable disown echotc echoti emulate fc fg float functions getcap getln history integer jobs kill limit log noglob popd print pushd pushln rehash sched setcap setopt stat suspend ttyctl unfunction unhash unlimit unsetopt vared wait whence where which zcompile zformat zftp zle zmodload zparseopts zprof zpty zregexparse zsocket zstyle ztcp'
- },
- contains: [
- C,
- s.SHEBANG(),
- j,
- x,
- s.HASH_COMMENT_MODE,
- _,
- w,
- { className: '', begin: /\\"/ },
- { className: 'string', begin: /'/, end: /'/ },
- o
- ]
- };
- };
- },
- 73402: (s) => {
- function concat(...s) {
- return s
- .map((s) =>
- (function source(s) {
- return s ? ('string' == typeof s ? s : s.source) : null;
- })(s)
- )
- .join('');
- }
- s.exports = function http(s) {
- const o = 'HTTP/(2|1\\.[01])',
- i = {
- className: 'attribute',
- begin: concat('^', /[A-Za-z][A-Za-z0-9-]*/, '(?=\\:\\s)'),
- starts: {
- contains: [
- {
- className: 'punctuation',
- begin: /: /,
- relevance: 0,
- starts: { end: '$', relevance: 0 }
- }
- ]
- }
- },
- u = [i, { begin: '\\n\\n', starts: { subLanguage: [], endsWithParent: !0 } }];
- return {
- name: 'HTTP',
- aliases: ['https'],
- illegal: /\S/,
- contains: [
- {
- begin: '^(?=' + o + ' \\d{3})',
- end: /$/,
- contains: [
- { className: 'meta', begin: o },
- { className: 'number', begin: '\\b\\d{3}\\b' }
- ],
- starts: { end: /\b\B/, illegal: /\S/, contains: u }
- },
- {
- begin: '(?=^[A-Z]+ (.*?) ' + o + '$)',
- end: /$/,
- contains: [
- { className: 'string', begin: ' ', end: ' ', excludeBegin: !0, excludeEnd: !0 },
- { className: 'meta', begin: o },
- { className: 'keyword', begin: '[A-Z]+' }
- ],
- starts: { end: /\b\B/, illegal: /\S/, contains: u }
- },
- s.inherit(i, { relevance: 0 })
- ]
- };
- };
- },
- 95089: (s) => {
- const o = '[A-Za-z$_][0-9A-Za-z$_]*',
- i = [
- 'as',
- 'in',
- 'of',
- 'if',
- 'for',
- 'while',
- 'finally',
- 'var',
- 'new',
- 'function',
- 'do',
- 'return',
- 'void',
- 'else',
- 'break',
- 'catch',
- 'instanceof',
- 'with',
- 'throw',
- 'case',
- 'default',
- 'try',
- 'switch',
- 'continue',
- 'typeof',
- 'delete',
- 'let',
- 'yield',
- 'const',
- 'class',
- 'debugger',
- 'async',
- 'await',
- 'static',
- 'import',
- 'from',
- 'export',
- 'extends'
- ],
- u = ['true', 'false', 'null', 'undefined', 'NaN', 'Infinity'],
- _ = [].concat(
- [
- 'setInterval',
- 'setTimeout',
- 'clearInterval',
- 'clearTimeout',
- 'require',
- 'exports',
- 'eval',
- 'isFinite',
- 'isNaN',
- 'parseFloat',
- 'parseInt',
- 'decodeURI',
- 'decodeURIComponent',
- 'encodeURI',
- 'encodeURIComponent',
- 'escape',
- 'unescape'
- ],
- [
- 'arguments',
- 'this',
- 'super',
- 'console',
- 'window',
- 'document',
- 'localStorage',
- 'module',
- 'global'
- ],
- [
- 'Intl',
- 'DataView',
- 'Number',
- 'Math',
- 'Date',
- 'String',
- 'RegExp',
- 'Object',
- 'Function',
- 'Boolean',
- 'Error',
- 'Symbol',
- 'Set',
- 'Map',
- 'WeakSet',
- 'WeakMap',
- 'Proxy',
- 'Reflect',
- 'JSON',
- 'Promise',
- 'Float64Array',
- 'Int16Array',
- 'Int32Array',
- 'Int8Array',
- 'Uint16Array',
- 'Uint32Array',
- 'Float32Array',
- 'Array',
- 'Uint8Array',
- 'Uint8ClampedArray',
- 'ArrayBuffer',
- 'BigInt64Array',
- 'BigUint64Array',
- 'BigInt'
- ],
- [
- 'EvalError',
- 'InternalError',
- 'RangeError',
- 'ReferenceError',
- 'SyntaxError',
- 'TypeError',
- 'URIError'
- ]
- );
- function lookahead(s) {
- return concat('(?=', s, ')');
- }
- function concat(...s) {
- return s
- .map((s) =>
- (function source(s) {
- return s ? ('string' == typeof s ? s : s.source) : null;
- })(s)
- )
- .join('');
- }
- s.exports = function javascript(s) {
- const w = o,
- x = '<>',
- C = '</>',
- j = {
- begin: /<[A-Za-z0-9\\._:-]+/,
- end: /\/[A-Za-z0-9\\._:-]+>|\/>/,
- isTrulyOpeningTag: (s, o) => {
- const i = s[0].length + s.index,
- u = s.input[i];
- '<' !== u
- ? '>' === u &&
- (((s, { after: o }) => {
- const i = '</' + s[0].slice(1);
- return -1 !== s.input.indexOf(i, o);
- })(s, { after: i }) ||
- o.ignoreMatch())
- : o.ignoreMatch();
- }
- },
- L = { $pattern: o, keyword: i, literal: u, built_in: _ },
- B = '[0-9](_?[0-9])*',
- $ = `\\.(${B})`,
- V = '0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*',
- U = {
- className: 'number',
- variants: [
- { begin: `(\\b(${V})((${$})|\\.)?|(${$}))[eE][+-]?(${B})\\b` },
- { begin: `\\b(${V})\\b((${$})\\b|\\.)?|(${$})\\b` },
- { begin: '\\b(0|[1-9](_?[0-9])*)n\\b' },
- { begin: '\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b' },
- { begin: '\\b0[bB][0-1](_?[0-1])*n?\\b' },
- { begin: '\\b0[oO][0-7](_?[0-7])*n?\\b' },
- { begin: '\\b0[0-7]+n?\\b' }
- ],
- relevance: 0
- },
- z = { className: 'subst', begin: '\\$\\{', end: '\\}', keywords: L, contains: [] },
- Y = {
- begin: 'html`',
- end: '',
- starts: {
- end: '`',
- returnEnd: !1,
- contains: [s.BACKSLASH_ESCAPE, z],
- subLanguage: 'xml'
- }
- },
- Z = {
- begin: 'css`',
- end: '',
- starts: {
- end: '`',
- returnEnd: !1,
- contains: [s.BACKSLASH_ESCAPE, z],
- subLanguage: 'css'
- }
- },
- ee = { className: 'string', begin: '`', end: '`', contains: [s.BACKSLASH_ESCAPE, z] },
- ie = {
- className: 'comment',
- variants: [
- s.COMMENT(/\/\*\*(?!\/)/, '\\*/', {
- relevance: 0,
- contains: [
- {
- className: 'doctag',
- begin: '@[A-Za-z]+',
- contains: [
- { className: 'type', begin: '\\{', end: '\\}', relevance: 0 },
- {
- className: 'variable',
- begin: w + '(?=\\s*(-)|$)',
- endsParent: !0,
- relevance: 0
- },
- { begin: /(?=[^\n])\s/, relevance: 0 }
- ]
- }
- ]
- }),
- s.C_BLOCK_COMMENT_MODE,
- s.C_LINE_COMMENT_MODE
- ]
- },
- ae = [s.APOS_STRING_MODE, s.QUOTE_STRING_MODE, Y, Z, ee, U, s.REGEXP_MODE];
- z.contains = ae.concat({
- begin: /\{/,
- end: /\}/,
- keywords: L,
- contains: ['self'].concat(ae)
- });
- const le = [].concat(ie, z.contains),
- ce = le.concat([
- { begin: /\(/, end: /\)/, keywords: L, contains: ['self'].concat(le) }
- ]),
- pe = {
- className: 'params',
- begin: /\(/,
- end: /\)/,
- excludeBegin: !0,
- excludeEnd: !0,
- keywords: L,
- contains: ce
- };
- return {
- name: 'Javascript',
- aliases: ['js', 'jsx', 'mjs', 'cjs'],
- keywords: L,
- exports: { PARAMS_CONTAINS: ce },
- illegal: /#(?![$_A-z])/,
- contains: [
- s.SHEBANG({ label: 'shebang', binary: 'node', relevance: 5 }),
- {
- label: 'use_strict',
- className: 'meta',
- relevance: 10,
- begin: /^\s*['"]use (strict|asm)['"]/
- },
- s.APOS_STRING_MODE,
- s.QUOTE_STRING_MODE,
- Y,
- Z,
- ee,
- ie,
- U,
- {
- begin: concat(
- /[{,\n]\s*/,
- lookahead(concat(/(((\/\/.*$)|(\/\*(\*[^/]|[^*])*\*\/))\s*)*/, w + '\\s*:'))
- ),
- relevance: 0,
- contains: [{ className: 'attr', begin: w + lookahead('\\s*:'), relevance: 0 }]
- },
- {
- begin: '(' + s.RE_STARTERS_RE + '|\\b(case|return|throw)\\b)\\s*',
- keywords: 'return throw case',
- contains: [
- ie,
- s.REGEXP_MODE,
- {
- className: 'function',
- begin:
- '(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|' +
- s.UNDERSCORE_IDENT_RE +
- ')\\s*=>',
- returnBegin: !0,
- end: '\\s*=>',
- contains: [
- {
- className: 'params',
- variants: [
- { begin: s.UNDERSCORE_IDENT_RE, relevance: 0 },
- { className: null, begin: /\(\s*\)/, skip: !0 },
- {
- begin: /\(/,
- end: /\)/,
- excludeBegin: !0,
- excludeEnd: !0,
- keywords: L,
- contains: ce
- }
- ]
- }
- ]
- },
- { begin: /,/, relevance: 0 },
- { className: '', begin: /\s/, end: /\s*/, skip: !0 },
- {
- variants: [
- { begin: x, end: C },
- { begin: j.begin, 'on:begin': j.isTrulyOpeningTag, end: j.end }
- ],
- subLanguage: 'xml',
- contains: [{ begin: j.begin, end: j.end, skip: !0, contains: ['self'] }]
- }
- ],
- relevance: 0
- },
- {
- className: 'function',
- beginKeywords: 'function',
- end: /[{;]/,
- excludeEnd: !0,
- keywords: L,
- contains: ['self', s.inherit(s.TITLE_MODE, { begin: w }), pe],
- illegal: /%/
- },
- { beginKeywords: 'while if switch catch for' },
- {
- className: 'function',
- begin:
- s.UNDERSCORE_IDENT_RE +
- '\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{',
- returnBegin: !0,
- contains: [pe, s.inherit(s.TITLE_MODE, { begin: w })]
- },
- { variants: [{ begin: '\\.' + w }, { begin: '\\$' + w }], relevance: 0 },
- {
- className: 'class',
- beginKeywords: 'class',
- end: /[{;=]/,
- excludeEnd: !0,
- illegal: /[:"[\]]/,
- contains: [{ beginKeywords: 'extends' }, s.UNDERSCORE_TITLE_MODE]
- },
- {
- begin: /\b(?=constructor)/,
- end: /[{;]/,
- excludeEnd: !0,
- contains: [s.inherit(s.TITLE_MODE, { begin: w }), 'self', pe]
- },
- {
- begin: '(get|set)\\s+(?=' + w + '\\()',
- end: /\{/,
- keywords: 'get set',
- contains: [s.inherit(s.TITLE_MODE, { begin: w }), { begin: /\(\)/ }, pe]
- },
- { begin: /\$[(.]/ }
- ]
- };
- };
- },
- 65772: (s) => {
- s.exports = function json(s) {
- const o = { literal: 'true false null' },
- i = [s.C_LINE_COMMENT_MODE, s.C_BLOCK_COMMENT_MODE],
- u = [s.QUOTE_STRING_MODE, s.C_NUMBER_MODE],
- _ = { end: ',', endsWithParent: !0, excludeEnd: !0, contains: u, keywords: o },
- w = {
- begin: /\{/,
- end: /\}/,
- contains: [
- {
- className: 'attr',
- begin: /"/,
- end: /"/,
- contains: [s.BACKSLASH_ESCAPE],
- illegal: '\\n'
- },
- s.inherit(_, { begin: /:/ })
- ].concat(i),
- illegal: '\\S'
- },
- x = { begin: '\\[', end: '\\]', contains: [s.inherit(_)], illegal: '\\S' };
- return (
- u.push(w, x),
- i.forEach(function (s) {
- u.push(s);
- }),
- { name: 'JSON', contains: u, keywords: o, illegal: '\\S' }
- );
- };
- },
- 26571: (s) => {
- s.exports = function powershell(s) {
- const o = {
- $pattern: /-?[A-z\.\-]+\b/,
- keyword:
- 'if else foreach return do while until elseif begin for trap data dynamicparam end break throw param continue finally in switch exit filter try process catch hidden static parameter',
- built_in:
- 'ac asnp cat cd CFS chdir clc clear clhy cli clp cls clv cnsn compare copy cp cpi cpp curl cvpa dbp del diff dir dnsn ebp echo|0 epal epcsv epsn erase etsn exsn fc fhx fl ft fw gal gbp gc gcb gci gcm gcs gdr gerr ghy gi gin gjb gl gm gmo gp gps gpv group gsn gsnp gsv gtz gu gv gwmi h history icm iex ihy ii ipal ipcsv ipmo ipsn irm ise iwmi iwr kill lp ls man md measure mi mount move mp mv nal ndr ni nmo npssc nsn nv ogv oh popd ps pushd pwd r rbp rcjb rcsn rd rdr ren ri rjb rm rmdir rmo rni rnp rp rsn rsnp rujb rv rvpa rwmi sajb sal saps sasv sbp sc scb select set shcm si sl sleep sls sort sp spjb spps spsv start stz sujb sv swmi tee trcm type wget where wjb write'
- },
- i = { begin: '`[\\s\\S]', relevance: 0 },
- u = {
- className: 'variable',
- variants: [
- { begin: /\$\B/ },
- { className: 'keyword', begin: /\$this/ },
- { begin: /\$[\w\d][\w\d_:]*/ }
- ]
- },
- _ = {
- className: 'string',
- variants: [
- { begin: /"/, end: /"/ },
- { begin: /@"/, end: /^"@/ }
- ],
- contains: [i, u, { className: 'variable', begin: /\$[A-z]/, end: /[^A-z]/ }]
- },
- w = {
- className: 'string',
- variants: [
- { begin: /'/, end: /'/ },
- { begin: /@'/, end: /^'@/ }
- ]
- },
- x = s.inherit(s.COMMENT(null, null), {
- variants: [
- { begin: /#/, end: /$/ },
- { begin: /<#/, end: /#>/ }
- ],
- contains: [
- {
- className: 'doctag',
- variants: [
- {
- begin:
- /\.(synopsis|description|example|inputs|outputs|notes|link|component|role|functionality)/
- },
- {
- begin:
- /\.(parameter|forwardhelptargetname|forwardhelpcategory|remotehelprunspace|externalhelp)\s+\S+/
- }
- ]
- }
- ]
- }),
- C = {
- className: 'built_in',
- variants: [
- {
- begin: '('.concat(
- 'Add|Clear|Close|Copy|Enter|Exit|Find|Format|Get|Hide|Join|Lock|Move|New|Open|Optimize|Pop|Push|Redo|Remove|Rename|Reset|Resize|Search|Select|Set|Show|Skip|Split|Step|Switch|Undo|Unlock|Watch|Backup|Checkpoint|Compare|Compress|Convert|ConvertFrom|ConvertTo|Dismount|Edit|Expand|Export|Group|Import|Initialize|Limit|Merge|Mount|Out|Publish|Restore|Save|Sync|Unpublish|Update|Approve|Assert|Build|Complete|Confirm|Deny|Deploy|Disable|Enable|Install|Invoke|Register|Request|Restart|Resume|Start|Stop|Submit|Suspend|Uninstall|Unregister|Wait|Debug|Measure|Ping|Repair|Resolve|Test|Trace|Connect|Disconnect|Read|Receive|Send|Write|Block|Grant|Protect|Revoke|Unblock|Unprotect|Use|ForEach|Sort|Tee|Where',
- ')+(-)[\\w\\d]+'
- )
- }
- ]
- },
- j = {
- className: 'class',
- beginKeywords: 'class enum',
- end: /\s*[{]/,
- excludeEnd: !0,
- relevance: 0,
- contains: [s.TITLE_MODE]
- },
- L = {
- className: 'function',
- begin: /function\s+/,
- end: /\s*\{|$/,
- excludeEnd: !0,
- returnBegin: !0,
- relevance: 0,
- contains: [
- { begin: 'function', relevance: 0, className: 'keyword' },
- { className: 'title', begin: /\w[\w\d]*((-)[\w\d]+)*/, relevance: 0 },
- { begin: /\(/, end: /\)/, className: 'params', relevance: 0, contains: [u] }
- ]
- },
- B = {
- begin: /using\s/,
- end: /$/,
- returnBegin: !0,
- contains: [
- _,
- w,
- { className: 'keyword', begin: /(using|assembly|command|module|namespace|type)/ }
- ]
- },
- $ = {
- variants: [
- {
- className: 'operator',
- begin: '('.concat(
- '-and|-as|-band|-bnot|-bor|-bxor|-casesensitive|-ccontains|-ceq|-cge|-cgt|-cle|-clike|-clt|-cmatch|-cne|-cnotcontains|-cnotlike|-cnotmatch|-contains|-creplace|-csplit|-eq|-exact|-f|-file|-ge|-gt|-icontains|-ieq|-ige|-igt|-ile|-ilike|-ilt|-imatch|-in|-ine|-inotcontains|-inotlike|-inotmatch|-ireplace|-is|-isnot|-isplit|-join|-le|-like|-lt|-match|-ne|-not|-notcontains|-notin|-notlike|-notmatch|-or|-regex|-replace|-shl|-shr|-split|-wildcard|-xor',
- ')\\b'
- )
- },
- { className: 'literal', begin: /(-)[\w\d]+/, relevance: 0 }
- ]
- },
- V = {
- className: 'function',
- begin: /\[.*\]\s*[\w]+[ ]??\(/,
- end: /$/,
- returnBegin: !0,
- relevance: 0,
- contains: [
- {
- className: 'keyword',
- begin: '('.concat(o.keyword.toString().replace(/\s/g, '|'), ')\\b'),
- endsParent: !0,
- relevance: 0
- },
- s.inherit(s.TITLE_MODE, { endsParent: !0 })
- ]
- },
- U = [
- V,
- x,
- i,
- s.NUMBER_MODE,
- _,
- w,
- C,
- u,
- { className: 'literal', begin: /\$(null|true|false)\b/ },
- { className: 'selector-tag', begin: /@\B/, relevance: 0 }
- ],
- z = {
- begin: /\[/,
- end: /\]/,
- excludeBegin: !0,
- excludeEnd: !0,
- relevance: 0,
- contains: [].concat(
- 'self',
- U,
- {
- begin:
- '(' +
- [
- 'string',
- 'char',
- 'byte',
- 'int',
- 'long',
- 'bool',
- 'decimal',
- 'single',
- 'double',
- 'DateTime',
- 'xml',
- 'array',
- 'hashtable',
- 'void'
- ].join('|') +
- ')',
- className: 'built_in',
- relevance: 0
- },
- { className: 'type', begin: /[\.\w\d]+/, relevance: 0 }
- )
- };
- return (
- V.contains.unshift(z),
- {
- name: 'PowerShell',
- aliases: ['ps', 'ps1'],
- case_insensitive: !0,
- keywords: o,
- contains: U.concat(j, L, B, $, z)
- }
- );
- };
- },
- 17285: (s) => {
- function source(s) {
- return s ? ('string' == typeof s ? s : s.source) : null;
- }
- function lookahead(s) {
- return concat('(?=', s, ')');
- }
- function concat(...s) {
- return s.map((s) => source(s)).join('');
- }
- function either(...s) {
- return '(' + s.map((s) => source(s)).join('|') + ')';
- }
- s.exports = function xml(s) {
- const o = concat(
- /[A-Z_]/,
- (function optional(s) {
- return concat('(', s, ')?');
- })(/[A-Z0-9_.-]*:/),
- /[A-Z0-9_.-]*/
- ),
- i = { className: 'symbol', begin: /&[a-z]+;|&#[0-9]+;|&#x[a-f0-9]+;/ },
- u = {
- begin: /\s/,
- contains: [
- { className: 'meta-keyword', begin: /#?[a-z_][a-z1-9_-]+/, illegal: /\n/ }
- ]
- },
- _ = s.inherit(u, { begin: /\(/, end: /\)/ }),
- w = s.inherit(s.APOS_STRING_MODE, { className: 'meta-string' }),
- x = s.inherit(s.QUOTE_STRING_MODE, { className: 'meta-string' }),
- C = {
- endsWithParent: !0,
- illegal: /</,
- relevance: 0,
- contains: [
- { className: 'attr', begin: /[A-Za-z0-9._:-]+/, relevance: 0 },
- {
- begin: /=\s*/,
- relevance: 0,
- contains: [
- {
- className: 'string',
- endsParent: !0,
- variants: [
- { begin: /"/, end: /"/, contains: [i] },
- { begin: /'/, end: /'/, contains: [i] },
- { begin: /[^\s"'=<>`]+/ }
- ]
- }
- ]
- }
- ]
- };
- return {
- name: 'HTML, XML',
- aliases: ['html', 'xhtml', 'rss', 'atom', 'xjb', 'xsd', 'xsl', 'plist', 'wsf', 'svg'],
- case_insensitive: !0,
- contains: [
- {
- className: 'meta',
- begin: /<![a-z]/,
- end: />/,
- relevance: 10,
- contains: [
- u,
- x,
- w,
- _,
- {
- begin: /\[/,
- end: /\]/,
- contains: [
- { className: 'meta', begin: /<![a-z]/, end: />/, contains: [u, _, x, w] }
- ]
- }
- ]
- },
- s.COMMENT(/<!--/, /-->/, { relevance: 10 }),
- { begin: /<!\[CDATA\[/, end: /\]\]>/, relevance: 10 },
- i,
- { className: 'meta', begin: /<\?xml/, end: /\?>/, relevance: 10 },
- {
- className: 'tag',
- begin: /<style(?=\s|>)/,
- end: />/,
- keywords: { name: 'style' },
- contains: [C],
- starts: { end: /<\/style>/, returnEnd: !0, subLanguage: ['css', 'xml'] }
- },
- {
- className: 'tag',
- begin: /<script(?=\s|>)/,
- end: />/,
- keywords: { name: 'script' },
- contains: [C],
- starts: {
- end: /<\/script>/,
- returnEnd: !0,
- subLanguage: ['javascript', 'handlebars', 'xml']
- }
- },
- { className: 'tag', begin: /<>|<\/>/ },
- {
- className: 'tag',
- begin: concat(/</, lookahead(concat(o, either(/\/>/, />/, /\s/)))),
- end: /\/?>/,
- contains: [{ className: 'name', begin: o, relevance: 0, starts: C }]
- },
- {
- className: 'tag',
- begin: concat(/<\//, lookahead(concat(o, />/))),
- contains: [
- { className: 'name', begin: o, relevance: 0 },
- { begin: />/, relevance: 0, endsParent: !0 }
- ]
- }
- ]
- };
- };
- },
- 17533: (s) => {
- s.exports = function yaml(s) {
- var o = 'true false yes no null',
- i = "[\\w#;/?:@&=+$,.~*'()[\\]]+",
- u = {
- className: 'string',
- relevance: 0,
- variants: [{ begin: /'/, end: /'/ }, { begin: /"/, end: /"/ }, { begin: /\S+/ }],
- contains: [
- s.BACKSLASH_ESCAPE,
- {
- className: 'template-variable',
- variants: [
- { begin: /\{\{/, end: /\}\}/ },
- { begin: /%\{/, end: /\}/ }
- ]
- }
- ]
- },
- _ = s.inherit(u, {
- variants: [
- { begin: /'/, end: /'/ },
- { begin: /"/, end: /"/ },
- { begin: /[^\s,{}[\]]+/ }
- ]
- }),
- w = {
- className: 'number',
- begin:
- '\\b[0-9]{4}(-[0-9][0-9]){0,2}([Tt \\t][0-9][0-9]?(:[0-9][0-9]){2})?(\\.[0-9]*)?([ \\t])*(Z|[-+][0-9][0-9]?(:[0-9][0-9])?)?\\b'
- },
- x = { end: ',', endsWithParent: !0, excludeEnd: !0, keywords: o, relevance: 0 },
- C = { begin: /\{/, end: /\}/, contains: [x], illegal: '\\n', relevance: 0 },
- j = { begin: '\\[', end: '\\]', contains: [x], illegal: '\\n', relevance: 0 },
- L = [
- {
- className: 'attr',
- variants: [
- { begin: '\\w[\\w :\\/.-]*:(?=[ \t]|$)' },
- { begin: '"\\w[\\w :\\/.-]*":(?=[ \t]|$)' },
- { begin: "'\\w[\\w :\\/.-]*':(?=[ \t]|$)" }
- ]
- },
- { className: 'meta', begin: '^---\\s*$', relevance: 10 },
- {
- className: 'string',
- begin: '[\\|>]([1-9]?[+-])?[ ]*\\n( +)[^ ][^\\n]*\\n(\\2[^\\n]+\\n?)*'
- },
- {
- begin: '<%[%=-]?',
- end: '[%-]?%>',
- subLanguage: 'ruby',
- excludeBegin: !0,
- excludeEnd: !0,
- relevance: 0
- },
- { className: 'type', begin: '!\\w+!' + i },
- { className: 'type', begin: '!<' + i + '>' },
- { className: 'type', begin: '!' + i },
- { className: 'type', begin: '!!' + i },
- { className: 'meta', begin: '&' + s.UNDERSCORE_IDENT_RE + '$' },
- { className: 'meta', begin: '\\*' + s.UNDERSCORE_IDENT_RE + '$' },
- { className: 'bullet', begin: '-(?=[ ]|$)', relevance: 0 },
- s.HASH_COMMENT_MODE,
- { beginKeywords: o, keywords: { literal: o } },
- w,
- { className: 'number', begin: s.C_NUMBER_RE + '\\b', relevance: 0 },
- C,
- j,
- u
- ],
- B = [...L];
- return (
- B.pop(),
- B.push(_),
- (x.contains = B),
- { name: 'YAML', case_insensitive: !0, aliases: ['yml'], contains: L }
- );
- };
- },
- 251: (s, o) => {
- (o.read = function (s, o, i, u, _) {
- var w,
- x,
- C = 8 * _ - u - 1,
- j = (1 << C) - 1,
- L = j >> 1,
- B = -7,
- $ = i ? _ - 1 : 0,
- V = i ? -1 : 1,
- U = s[o + $];
- for (
- $ += V, w = U & ((1 << -B) - 1), U >>= -B, B += C;
- B > 0;
- w = 256 * w + s[o + $], $ += V, B -= 8
- );
- for (
- x = w & ((1 << -B) - 1), w >>= -B, B += u;
- B > 0;
- x = 256 * x + s[o + $], $ += V, B -= 8
- );
- if (0 === w) w = 1 - L;
- else {
- if (w === j) return x ? NaN : (1 / 0) * (U ? -1 : 1);
- (x += Math.pow(2, u)), (w -= L);
- }
- return (U ? -1 : 1) * x * Math.pow(2, w - u);
- }),
- (o.write = function (s, o, i, u, _, w) {
- var x,
- C,
- j,
- L = 8 * w - _ - 1,
- B = (1 << L) - 1,
- $ = B >> 1,
- V = 23 === _ ? Math.pow(2, -24) - Math.pow(2, -77) : 0,
- U = u ? 0 : w - 1,
- z = u ? 1 : -1,
- Y = o < 0 || (0 === o && 1 / o < 0) ? 1 : 0;
- for (
- o = Math.abs(o),
- isNaN(o) || o === 1 / 0
- ? ((C = isNaN(o) ? 1 : 0), (x = B))
- : ((x = Math.floor(Math.log(o) / Math.LN2)),
- o * (j = Math.pow(2, -x)) < 1 && (x--, (j *= 2)),
- (o += x + $ >= 1 ? V / j : V * Math.pow(2, 1 - $)) * j >= 2 &&
- (x++, (j /= 2)),
- x + $ >= B
- ? ((C = 0), (x = B))
- : x + $ >= 1
- ? ((C = (o * j - 1) * Math.pow(2, _)), (x += $))
- : ((C = o * Math.pow(2, $ - 1) * Math.pow(2, _)), (x = 0)));
- _ >= 8;
- s[i + U] = 255 & C, U += z, C /= 256, _ -= 8
- );
- for (x = (x << _) | C, L += _; L > 0; s[i + U] = 255 & x, U += z, x /= 256, L -= 8);
- s[i + U - z] |= 128 * Y;
- });
- },
- 9404: function (s) {
- s.exports = (function () {
- 'use strict';
- var s = Array.prototype.slice;
- function createClass(s, o) {
- o && (s.prototype = Object.create(o.prototype)), (s.prototype.constructor = s);
- }
- function Iterable(s) {
- return isIterable(s) ? s : Seq(s);
- }
- function KeyedIterable(s) {
- return isKeyed(s) ? s : KeyedSeq(s);
- }
- function IndexedIterable(s) {
- return isIndexed(s) ? s : IndexedSeq(s);
- }
- function SetIterable(s) {
- return isIterable(s) && !isAssociative(s) ? s : SetSeq(s);
- }
- function isIterable(s) {
- return !(!s || !s[o]);
- }
- function isKeyed(s) {
- return !(!s || !s[i]);
- }
- function isIndexed(s) {
- return !(!s || !s[u]);
- }
- function isAssociative(s) {
- return isKeyed(s) || isIndexed(s);
- }
- function isOrdered(s) {
- return !(!s || !s[_]);
- }
- createClass(KeyedIterable, Iterable),
- createClass(IndexedIterable, Iterable),
- createClass(SetIterable, Iterable),
- (Iterable.isIterable = isIterable),
- (Iterable.isKeyed = isKeyed),
- (Iterable.isIndexed = isIndexed),
- (Iterable.isAssociative = isAssociative),
- (Iterable.isOrdered = isOrdered),
- (Iterable.Keyed = KeyedIterable),
- (Iterable.Indexed = IndexedIterable),
- (Iterable.Set = SetIterable);
- var o = '@@__IMMUTABLE_ITERABLE__@@',
- i = '@@__IMMUTABLE_KEYED__@@',
- u = '@@__IMMUTABLE_INDEXED__@@',
- _ = '@@__IMMUTABLE_ORDERED__@@',
- w = 'delete',
- x = 5,
- C = 1 << x,
- j = C - 1,
- L = {},
- B = { value: !1 },
- $ = { value: !1 };
- function MakeRef(s) {
- return (s.value = !1), s;
- }
- function SetRef(s) {
- s && (s.value = !0);
- }
- function OwnerID() {}
- function arrCopy(s, o) {
- o = o || 0;
- for (var i = Math.max(0, s.length - o), u = new Array(i), _ = 0; _ < i; _++)
- u[_] = s[_ + o];
- return u;
- }
- function ensureSize(s) {
- return void 0 === s.size && (s.size = s.__iterate(returnTrue)), s.size;
- }
- function wrapIndex(s, o) {
- if ('number' != typeof o) {
- var i = o >>> 0;
- if ('' + i !== o || 4294967295 === i) return NaN;
- o = i;
- }
- return o < 0 ? ensureSize(s) + o : o;
- }
- function returnTrue() {
- return !0;
- }
- function wholeSlice(s, o, i) {
- return (
- (0 === s || (void 0 !== i && s <= -i)) && (void 0 === o || (void 0 !== i && o >= i))
- );
- }
- function resolveBegin(s, o) {
- return resolveIndex(s, o, 0);
- }
- function resolveEnd(s, o) {
- return resolveIndex(s, o, o);
- }
- function resolveIndex(s, o, i) {
- return void 0 === s
- ? i
- : s < 0
- ? Math.max(0, o + s)
- : void 0 === o
- ? s
- : Math.min(o, s);
- }
- var V = 0,
- U = 1,
- z = 2,
- Y = 'function' == typeof Symbol && Symbol.iterator,
- Z = '@@iterator',
- ee = Y || Z;
- function Iterator(s) {
- this.next = s;
- }
- function iteratorValue(s, o, i, u) {
- var _ = 0 === s ? o : 1 === s ? i : [o, i];
- return u ? (u.value = _) : (u = { value: _, done: !1 }), u;
- }
- function iteratorDone() {
- return { value: void 0, done: !0 };
- }
- function hasIterator(s) {
- return !!getIteratorFn(s);
- }
- function isIterator(s) {
- return s && 'function' == typeof s.next;
- }
- function getIterator(s) {
- var o = getIteratorFn(s);
- return o && o.call(s);
- }
- function getIteratorFn(s) {
- var o = s && ((Y && s[Y]) || s[Z]);
- if ('function' == typeof o) return o;
- }
- function isArrayLike(s) {
- return s && 'number' == typeof s.length;
- }
- function Seq(s) {
- return null == s ? emptySequence() : isIterable(s) ? s.toSeq() : seqFromValue(s);
- }
- function KeyedSeq(s) {
- return null == s
- ? emptySequence().toKeyedSeq()
- : isIterable(s)
- ? isKeyed(s)
- ? s.toSeq()
- : s.fromEntrySeq()
- : keyedSeqFromValue(s);
- }
- function IndexedSeq(s) {
- return null == s
- ? emptySequence()
- : isIterable(s)
- ? isKeyed(s)
- ? s.entrySeq()
- : s.toIndexedSeq()
- : indexedSeqFromValue(s);
- }
- function SetSeq(s) {
- return (
- null == s
- ? emptySequence()
- : isIterable(s)
- ? isKeyed(s)
- ? s.entrySeq()
- : s
- : indexedSeqFromValue(s)
- ).toSetSeq();
- }
- (Iterator.prototype.toString = function () {
- return '[Iterator]';
- }),
- (Iterator.KEYS = V),
- (Iterator.VALUES = U),
- (Iterator.ENTRIES = z),
- (Iterator.prototype.inspect = Iterator.prototype.toSource =
- function () {
- return this.toString();
- }),
- (Iterator.prototype[ee] = function () {
- return this;
- }),
- createClass(Seq, Iterable),
- (Seq.of = function () {
- return Seq(arguments);
- }),
- (Seq.prototype.toSeq = function () {
- return this;
- }),
- (Seq.prototype.toString = function () {
- return this.__toString('Seq {', '}');
- }),
- (Seq.prototype.cacheResult = function () {
- return (
- !this._cache &&
- this.__iterateUncached &&
- ((this._cache = this.entrySeq().toArray()), (this.size = this._cache.length)),
- this
- );
- }),
- (Seq.prototype.__iterate = function (s, o) {
- return seqIterate(this, s, o, !0);
- }),
- (Seq.prototype.__iterator = function (s, o) {
- return seqIterator(this, s, o, !0);
- }),
- createClass(KeyedSeq, Seq),
- (KeyedSeq.prototype.toKeyedSeq = function () {
- return this;
- }),
- createClass(IndexedSeq, Seq),
- (IndexedSeq.of = function () {
- return IndexedSeq(arguments);
- }),
- (IndexedSeq.prototype.toIndexedSeq = function () {
- return this;
- }),
- (IndexedSeq.prototype.toString = function () {
- return this.__toString('Seq [', ']');
- }),
- (IndexedSeq.prototype.__iterate = function (s, o) {
- return seqIterate(this, s, o, !1);
- }),
- (IndexedSeq.prototype.__iterator = function (s, o) {
- return seqIterator(this, s, o, !1);
- }),
- createClass(SetSeq, Seq),
- (SetSeq.of = function () {
- return SetSeq(arguments);
- }),
- (SetSeq.prototype.toSetSeq = function () {
- return this;
- }),
- (Seq.isSeq = isSeq),
- (Seq.Keyed = KeyedSeq),
- (Seq.Set = SetSeq),
- (Seq.Indexed = IndexedSeq);
- var ie,
- ae,
- le,
- ce = '@@__IMMUTABLE_SEQ__@@';
- function ArraySeq(s) {
- (this._array = s), (this.size = s.length);
- }
- function ObjectSeq(s) {
- var o = Object.keys(s);
- (this._object = s), (this._keys = o), (this.size = o.length);
- }
- function IterableSeq(s) {
- (this._iterable = s), (this.size = s.length || s.size);
- }
- function IteratorSeq(s) {
- (this._iterator = s), (this._iteratorCache = []);
- }
- function isSeq(s) {
- return !(!s || !s[ce]);
- }
- function emptySequence() {
- return ie || (ie = new ArraySeq([]));
- }
- function keyedSeqFromValue(s) {
- var o = Array.isArray(s)
- ? new ArraySeq(s).fromEntrySeq()
- : isIterator(s)
- ? new IteratorSeq(s).fromEntrySeq()
- : hasIterator(s)
- ? new IterableSeq(s).fromEntrySeq()
- : 'object' == typeof s
- ? new ObjectSeq(s)
- : void 0;
- if (!o)
- throw new TypeError(
- 'Expected Array or iterable object of [k, v] entries, or keyed object: ' + s
- );
- return o;
- }
- function indexedSeqFromValue(s) {
- var o = maybeIndexedSeqFromValue(s);
- if (!o) throw new TypeError('Expected Array or iterable object of values: ' + s);
- return o;
- }
- function seqFromValue(s) {
- var o = maybeIndexedSeqFromValue(s) || ('object' == typeof s && new ObjectSeq(s));
- if (!o)
- throw new TypeError(
- 'Expected Array or iterable object of values, or keyed object: ' + s
- );
- return o;
- }
- function maybeIndexedSeqFromValue(s) {
- return isArrayLike(s)
- ? new ArraySeq(s)
- : isIterator(s)
- ? new IteratorSeq(s)
- : hasIterator(s)
- ? new IterableSeq(s)
- : void 0;
- }
- function seqIterate(s, o, i, u) {
- var _ = s._cache;
- if (_) {
- for (var w = _.length - 1, x = 0; x <= w; x++) {
- var C = _[i ? w - x : x];
- if (!1 === o(C[1], u ? C[0] : x, s)) return x + 1;
- }
- return x;
- }
- return s.__iterateUncached(o, i);
- }
- function seqIterator(s, o, i, u) {
- var _ = s._cache;
- if (_) {
- var w = _.length - 1,
- x = 0;
- return new Iterator(function () {
- var s = _[i ? w - x : x];
- return x++ > w ? iteratorDone() : iteratorValue(o, u ? s[0] : x - 1, s[1]);
- });
- }
- return s.__iteratorUncached(o, i);
- }
- function fromJS(s, o) {
- return o ? fromJSWith(o, s, '', { '': s }) : fromJSDefault(s);
- }
- function fromJSWith(s, o, i, u) {
- return Array.isArray(o)
- ? s.call(
- u,
- i,
- IndexedSeq(o).map(function (i, u) {
- return fromJSWith(s, i, u, o);
- })
- )
- : isPlainObj(o)
- ? s.call(
- u,
- i,
- KeyedSeq(o).map(function (i, u) {
- return fromJSWith(s, i, u, o);
- })
- )
- : o;
- }
- function fromJSDefault(s) {
- return Array.isArray(s)
- ? IndexedSeq(s).map(fromJSDefault).toList()
- : isPlainObj(s)
- ? KeyedSeq(s).map(fromJSDefault).toMap()
- : s;
- }
- function isPlainObj(s) {
- return s && (s.constructor === Object || void 0 === s.constructor);
- }
- function is(s, o) {
- if (s === o || (s != s && o != o)) return !0;
- if (!s || !o) return !1;
- if ('function' == typeof s.valueOf && 'function' == typeof o.valueOf) {
- if ((s = s.valueOf()) === (o = o.valueOf()) || (s != s && o != o)) return !0;
- if (!s || !o) return !1;
- }
- return !(
- 'function' != typeof s.equals ||
- 'function' != typeof o.equals ||
- !s.equals(o)
- );
- }
- function deepEqual(s, o) {
- if (s === o) return !0;
- if (
- !isIterable(o) ||
- (void 0 !== s.size && void 0 !== o.size && s.size !== o.size) ||
- (void 0 !== s.__hash && void 0 !== o.__hash && s.__hash !== o.__hash) ||
- isKeyed(s) !== isKeyed(o) ||
- isIndexed(s) !== isIndexed(o) ||
- isOrdered(s) !== isOrdered(o)
- )
- return !1;
- if (0 === s.size && 0 === o.size) return !0;
- var i = !isAssociative(s);
- if (isOrdered(s)) {
- var u = s.entries();
- return (
- o.every(function (s, o) {
- var _ = u.next().value;
- return _ && is(_[1], s) && (i || is(_[0], o));
- }) && u.next().done
- );
- }
- var _ = !1;
- if (void 0 === s.size)
- if (void 0 === o.size) 'function' == typeof s.cacheResult && s.cacheResult();
- else {
- _ = !0;
- var w = s;
- (s = o), (o = w);
- }
- var x = !0,
- C = o.__iterate(function (o, u) {
- if (i ? !s.has(o) : _ ? !is(o, s.get(u, L)) : !is(s.get(u, L), o))
- return (x = !1), !1;
- });
- return x && s.size === C;
- }
- function Repeat(s, o) {
- if (!(this instanceof Repeat)) return new Repeat(s, o);
- if (
- ((this._value = s),
- (this.size = void 0 === o ? 1 / 0 : Math.max(0, o)),
- 0 === this.size)
- ) {
- if (ae) return ae;
- ae = this;
- }
- }
- function invariant(s, o) {
- if (!s) throw new Error(o);
- }
- function Range(s, o, i) {
- if (!(this instanceof Range)) return new Range(s, o, i);
- if (
- (invariant(0 !== i, 'Cannot step a Range by 0'),
- (s = s || 0),
- void 0 === o && (o = 1 / 0),
- (i = void 0 === i ? 1 : Math.abs(i)),
- o < s && (i = -i),
- (this._start = s),
- (this._end = o),
- (this._step = i),
- (this.size = Math.max(0, Math.ceil((o - s) / i - 1) + 1)),
- 0 === this.size)
- ) {
- if (le) return le;
- le = this;
- }
- }
- function Collection() {
- throw TypeError('Abstract');
- }
- function KeyedCollection() {}
- function IndexedCollection() {}
- function SetCollection() {}
- (Seq.prototype[ce] = !0),
- createClass(ArraySeq, IndexedSeq),
- (ArraySeq.prototype.get = function (s, o) {
- return this.has(s) ? this._array[wrapIndex(this, s)] : o;
- }),
- (ArraySeq.prototype.__iterate = function (s, o) {
- for (var i = this._array, u = i.length - 1, _ = 0; _ <= u; _++)
- if (!1 === s(i[o ? u - _ : _], _, this)) return _ + 1;
- return _;
- }),
- (ArraySeq.prototype.__iterator = function (s, o) {
- var i = this._array,
- u = i.length - 1,
- _ = 0;
- return new Iterator(function () {
- return _ > u ? iteratorDone() : iteratorValue(s, _, i[o ? u - _++ : _++]);
- });
- }),
- createClass(ObjectSeq, KeyedSeq),
- (ObjectSeq.prototype.get = function (s, o) {
- return void 0 === o || this.has(s) ? this._object[s] : o;
- }),
- (ObjectSeq.prototype.has = function (s) {
- return this._object.hasOwnProperty(s);
- }),
- (ObjectSeq.prototype.__iterate = function (s, o) {
- for (var i = this._object, u = this._keys, _ = u.length - 1, w = 0; w <= _; w++) {
- var x = u[o ? _ - w : w];
- if (!1 === s(i[x], x, this)) return w + 1;
- }
- return w;
- }),
- (ObjectSeq.prototype.__iterator = function (s, o) {
- var i = this._object,
- u = this._keys,
- _ = u.length - 1,
- w = 0;
- return new Iterator(function () {
- var x = u[o ? _ - w : w];
- return w++ > _ ? iteratorDone() : iteratorValue(s, x, i[x]);
- });
- }),
- (ObjectSeq.prototype[_] = !0),
- createClass(IterableSeq, IndexedSeq),
- (IterableSeq.prototype.__iterateUncached = function (s, o) {
- if (o) return this.cacheResult().__iterate(s, o);
- var i = getIterator(this._iterable),
- u = 0;
- if (isIterator(i))
- for (var _; !(_ = i.next()).done && !1 !== s(_.value, u++, this); );
- return u;
- }),
- (IterableSeq.prototype.__iteratorUncached = function (s, o) {
- if (o) return this.cacheResult().__iterator(s, o);
- var i = getIterator(this._iterable);
- if (!isIterator(i)) return new Iterator(iteratorDone);
- var u = 0;
- return new Iterator(function () {
- var o = i.next();
- return o.done ? o : iteratorValue(s, u++, o.value);
- });
- }),
- createClass(IteratorSeq, IndexedSeq),
- (IteratorSeq.prototype.__iterateUncached = function (s, o) {
- if (o) return this.cacheResult().__iterate(s, o);
- for (var i, u = this._iterator, _ = this._iteratorCache, w = 0; w < _.length; )
- if (!1 === s(_[w], w++, this)) return w;
- for (; !(i = u.next()).done; ) {
- var x = i.value;
- if (((_[w] = x), !1 === s(x, w++, this))) break;
- }
- return w;
- }),
- (IteratorSeq.prototype.__iteratorUncached = function (s, o) {
- if (o) return this.cacheResult().__iterator(s, o);
- var i = this._iterator,
- u = this._iteratorCache,
- _ = 0;
- return new Iterator(function () {
- if (_ >= u.length) {
- var o = i.next();
- if (o.done) return o;
- u[_] = o.value;
- }
- return iteratorValue(s, _, u[_++]);
- });
- }),
- createClass(Repeat, IndexedSeq),
- (Repeat.prototype.toString = function () {
- return 0 === this.size
- ? 'Repeat []'
- : 'Repeat [ ' + this._value + ' ' + this.size + ' times ]';
- }),
- (Repeat.prototype.get = function (s, o) {
- return this.has(s) ? this._value : o;
- }),
- (Repeat.prototype.includes = function (s) {
- return is(this._value, s);
- }),
- (Repeat.prototype.slice = function (s, o) {
- var i = this.size;
- return wholeSlice(s, o, i)
- ? this
- : new Repeat(this._value, resolveEnd(o, i) - resolveBegin(s, i));
- }),
- (Repeat.prototype.reverse = function () {
- return this;
- }),
- (Repeat.prototype.indexOf = function (s) {
- return is(this._value, s) ? 0 : -1;
- }),
- (Repeat.prototype.lastIndexOf = function (s) {
- return is(this._value, s) ? this.size : -1;
- }),
- (Repeat.prototype.__iterate = function (s, o) {
- for (var i = 0; i < this.size; i++)
- if (!1 === s(this._value, i, this)) return i + 1;
- return i;
- }),
- (Repeat.prototype.__iterator = function (s, o) {
- var i = this,
- u = 0;
- return new Iterator(function () {
- return u < i.size ? iteratorValue(s, u++, i._value) : iteratorDone();
- });
- }),
- (Repeat.prototype.equals = function (s) {
- return s instanceof Repeat ? is(this._value, s._value) : deepEqual(s);
- }),
- createClass(Range, IndexedSeq),
- (Range.prototype.toString = function () {
- return 0 === this.size
- ? 'Range []'
- : 'Range [ ' +
- this._start +
- '...' +
- this._end +
- (1 !== this._step ? ' by ' + this._step : '') +
- ' ]';
- }),
- (Range.prototype.get = function (s, o) {
- return this.has(s) ? this._start + wrapIndex(this, s) * this._step : o;
- }),
- (Range.prototype.includes = function (s) {
- var o = (s - this._start) / this._step;
- return o >= 0 && o < this.size && o === Math.floor(o);
- }),
- (Range.prototype.slice = function (s, o) {
- return wholeSlice(s, o, this.size)
- ? this
- : ((s = resolveBegin(s, this.size)),
- (o = resolveEnd(o, this.size)) <= s
- ? new Range(0, 0)
- : new Range(this.get(s, this._end), this.get(o, this._end), this._step));
- }),
- (Range.prototype.indexOf = function (s) {
- var o = s - this._start;
- if (o % this._step == 0) {
- var i = o / this._step;
- if (i >= 0 && i < this.size) return i;
- }
- return -1;
- }),
- (Range.prototype.lastIndexOf = function (s) {
- return this.indexOf(s);
- }),
- (Range.prototype.__iterate = function (s, o) {
- for (
- var i = this.size - 1,
- u = this._step,
- _ = o ? this._start + i * u : this._start,
- w = 0;
- w <= i;
- w++
- ) {
- if (!1 === s(_, w, this)) return w + 1;
- _ += o ? -u : u;
- }
- return w;
- }),
- (Range.prototype.__iterator = function (s, o) {
- var i = this.size - 1,
- u = this._step,
- _ = o ? this._start + i * u : this._start,
- w = 0;
- return new Iterator(function () {
- var x = _;
- return (_ += o ? -u : u), w > i ? iteratorDone() : iteratorValue(s, w++, x);
- });
- }),
- (Range.prototype.equals = function (s) {
- return s instanceof Range
- ? this._start === s._start && this._end === s._end && this._step === s._step
- : deepEqual(this, s);
- }),
- createClass(Collection, Iterable),
- createClass(KeyedCollection, Collection),
- createClass(IndexedCollection, Collection),
- createClass(SetCollection, Collection),
- (Collection.Keyed = KeyedCollection),
- (Collection.Indexed = IndexedCollection),
- (Collection.Set = SetCollection);
- var pe =
- 'function' == typeof Math.imul && -2 === Math.imul(4294967295, 2)
- ? Math.imul
- : function imul(s, o) {
- var i = 65535 & (s |= 0),
- u = 65535 & (o |= 0);
- return (i * u + ((((s >>> 16) * u + i * (o >>> 16)) << 16) >>> 0)) | 0;
- };
- function smi(s) {
- return ((s >>> 1) & 1073741824) | (3221225471 & s);
- }
- function hash(s) {
- if (!1 === s || null == s) return 0;
- if ('function' == typeof s.valueOf && (!1 === (s = s.valueOf()) || null == s))
- return 0;
- if (!0 === s) return 1;
- var o = typeof s;
- if ('number' === o) {
- if (s != s || s === 1 / 0) return 0;
- var i = 0 | s;
- for (i !== s && (i ^= 4294967295 * s); s > 4294967295; ) i ^= s /= 4294967295;
- return smi(i);
- }
- if ('string' === o) return s.length > Se ? cachedHashString(s) : hashString(s);
- if ('function' == typeof s.hashCode) return s.hashCode();
- if ('object' === o) return hashJSObj(s);
- if ('function' == typeof s.toString) return hashString(s.toString());
- throw new Error('Value type ' + o + ' cannot be hashed.');
- }
- function cachedHashString(s) {
- var o = Te[s];
- return (
- void 0 === o &&
- ((o = hashString(s)), Pe === xe && ((Pe = 0), (Te = {})), Pe++, (Te[s] = o)),
- o
- );
- }
- function hashString(s) {
- for (var o = 0, i = 0; i < s.length; i++) o = (31 * o + s.charCodeAt(i)) | 0;
- return smi(o);
- }
- function hashJSObj(s) {
- var o;
- if (be && void 0 !== (o = ye.get(s))) return o;
- if (void 0 !== (o = s[we])) return o;
- if (!fe) {
- if (void 0 !== (o = s.propertyIsEnumerable && s.propertyIsEnumerable[we])) return o;
- if (void 0 !== (o = getIENodeHash(s))) return o;
- }
- if (((o = ++_e), 1073741824 & _e && (_e = 0), be)) ye.set(s, o);
- else {
- if (void 0 !== de && !1 === de(s))
- throw new Error('Non-extensible objects are not allowed as keys.');
- if (fe)
- Object.defineProperty(s, we, {
- enumerable: !1,
- configurable: !1,
- writable: !1,
- value: o
- });
- else if (
- void 0 !== s.propertyIsEnumerable &&
- s.propertyIsEnumerable === s.constructor.prototype.propertyIsEnumerable
- )
- (s.propertyIsEnumerable = function () {
- return this.constructor.prototype.propertyIsEnumerable.apply(this, arguments);
- }),
- (s.propertyIsEnumerable[we] = o);
- else {
- if (void 0 === s.nodeType)
- throw new Error('Unable to set a non-enumerable property on object.');
- s[we] = o;
- }
- }
- return o;
- }
- var de = Object.isExtensible,
- fe = (function () {
- try {
- return Object.defineProperty({}, '@', {}), !0;
- } catch (s) {
- return !1;
- }
- })();
- function getIENodeHash(s) {
- if (s && s.nodeType > 0)
- switch (s.nodeType) {
- case 1:
- return s.uniqueID;
- case 9:
- return s.documentElement && s.documentElement.uniqueID;
- }
- }
- var ye,
- be = 'function' == typeof WeakMap;
- be && (ye = new WeakMap());
- var _e = 0,
- we = '__immutablehash__';
- 'function' == typeof Symbol && (we = Symbol(we));
- var Se = 16,
- xe = 255,
- Pe = 0,
- Te = {};
- function assertNotInfinite(s) {
- invariant(s !== 1 / 0, 'Cannot perform this action with an infinite size.');
- }
- function Map(s) {
- return null == s
- ? emptyMap()
- : isMap(s) && !isOrdered(s)
- ? s
- : emptyMap().withMutations(function (o) {
- var i = KeyedIterable(s);
- assertNotInfinite(i.size),
- i.forEach(function (s, i) {
- return o.set(i, s);
- });
- });
- }
- function isMap(s) {
- return !(!s || !s[qe]);
- }
- createClass(Map, KeyedCollection),
- (Map.of = function () {
- var o = s.call(arguments, 0);
- return emptyMap().withMutations(function (s) {
- for (var i = 0; i < o.length; i += 2) {
- if (i + 1 >= o.length) throw new Error('Missing value for key: ' + o[i]);
- s.set(o[i], o[i + 1]);
- }
- });
- }),
- (Map.prototype.toString = function () {
- return this.__toString('Map {', '}');
- }),
- (Map.prototype.get = function (s, o) {
- return this._root ? this._root.get(0, void 0, s, o) : o;
- }),
- (Map.prototype.set = function (s, o) {
- return updateMap(this, s, o);
- }),
- (Map.prototype.setIn = function (s, o) {
- return this.updateIn(s, L, function () {
- return o;
- });
- }),
- (Map.prototype.remove = function (s) {
- return updateMap(this, s, L);
- }),
- (Map.prototype.deleteIn = function (s) {
- return this.updateIn(s, function () {
- return L;
- });
- }),
- (Map.prototype.update = function (s, o, i) {
- return 1 === arguments.length ? s(this) : this.updateIn([s], o, i);
- }),
- (Map.prototype.updateIn = function (s, o, i) {
- i || ((i = o), (o = void 0));
- var u = updateInDeepMap(this, forceIterator(s), o, i);
- return u === L ? void 0 : u;
- }),
- (Map.prototype.clear = function () {
- return 0 === this.size
- ? this
- : this.__ownerID
- ? ((this.size = 0),
- (this._root = null),
- (this.__hash = void 0),
- (this.__altered = !0),
- this)
- : emptyMap();
- }),
- (Map.prototype.merge = function () {
- return mergeIntoMapWith(this, void 0, arguments);
- }),
- (Map.prototype.mergeWith = function (o) {
- return mergeIntoMapWith(this, o, s.call(arguments, 1));
- }),
- (Map.prototype.mergeIn = function (o) {
- var i = s.call(arguments, 1);
- return this.updateIn(o, emptyMap(), function (s) {
- return 'function' == typeof s.merge ? s.merge.apply(s, i) : i[i.length - 1];
- });
- }),
- (Map.prototype.mergeDeep = function () {
- return mergeIntoMapWith(this, deepMerger, arguments);
- }),
- (Map.prototype.mergeDeepWith = function (o) {
- var i = s.call(arguments, 1);
- return mergeIntoMapWith(this, deepMergerWith(o), i);
- }),
- (Map.prototype.mergeDeepIn = function (o) {
- var i = s.call(arguments, 1);
- return this.updateIn(o, emptyMap(), function (s) {
- return 'function' == typeof s.mergeDeep
- ? s.mergeDeep.apply(s, i)
- : i[i.length - 1];
- });
- }),
- (Map.prototype.sort = function (s) {
- return OrderedMap(sortFactory(this, s));
- }),
- (Map.prototype.sortBy = function (s, o) {
- return OrderedMap(sortFactory(this, o, s));
- }),
- (Map.prototype.withMutations = function (s) {
- var o = this.asMutable();
- return s(o), o.wasAltered() ? o.__ensureOwner(this.__ownerID) : this;
- }),
- (Map.prototype.asMutable = function () {
- return this.__ownerID ? this : this.__ensureOwner(new OwnerID());
- }),
- (Map.prototype.asImmutable = function () {
- return this.__ensureOwner();
- }),
- (Map.prototype.wasAltered = function () {
- return this.__altered;
- }),
- (Map.prototype.__iterator = function (s, o) {
- return new MapIterator(this, s, o);
- }),
- (Map.prototype.__iterate = function (s, o) {
- var i = this,
- u = 0;
- return (
- this._root &&
- this._root.iterate(function (o) {
- return u++, s(o[1], o[0], i);
- }, o),
- u
- );
- }),
- (Map.prototype.__ensureOwner = function (s) {
- return s === this.__ownerID
- ? this
- : s
- ? makeMap(this.size, this._root, s, this.__hash)
- : ((this.__ownerID = s), (this.__altered = !1), this);
- }),
- (Map.isMap = isMap);
- var Re,
- qe = '@@__IMMUTABLE_MAP__@@',
- $e = Map.prototype;
- function ArrayMapNode(s, o) {
- (this.ownerID = s), (this.entries = o);
- }
- function BitmapIndexedNode(s, o, i) {
- (this.ownerID = s), (this.bitmap = o), (this.nodes = i);
- }
- function HashArrayMapNode(s, o, i) {
- (this.ownerID = s), (this.count = o), (this.nodes = i);
- }
- function HashCollisionNode(s, o, i) {
- (this.ownerID = s), (this.keyHash = o), (this.entries = i);
- }
- function ValueNode(s, o, i) {
- (this.ownerID = s), (this.keyHash = o), (this.entry = i);
- }
- function MapIterator(s, o, i) {
- (this._type = o),
- (this._reverse = i),
- (this._stack = s._root && mapIteratorFrame(s._root));
- }
- function mapIteratorValue(s, o) {
- return iteratorValue(s, o[0], o[1]);
- }
- function mapIteratorFrame(s, o) {
- return { node: s, index: 0, __prev: o };
- }
- function makeMap(s, o, i, u) {
- var _ = Object.create($e);
- return (
- (_.size = s),
- (_._root = o),
- (_.__ownerID = i),
- (_.__hash = u),
- (_.__altered = !1),
- _
- );
- }
- function emptyMap() {
- return Re || (Re = makeMap(0));
- }
- function updateMap(s, o, i) {
- var u, _;
- if (s._root) {
- var w = MakeRef(B),
- x = MakeRef($);
- if (((u = updateNode(s._root, s.__ownerID, 0, void 0, o, i, w, x)), !x.value))
- return s;
- _ = s.size + (w.value ? (i === L ? -1 : 1) : 0);
- } else {
- if (i === L) return s;
- (_ = 1), (u = new ArrayMapNode(s.__ownerID, [[o, i]]));
- }
- return s.__ownerID
- ? ((s.size = _), (s._root = u), (s.__hash = void 0), (s.__altered = !0), s)
- : u
- ? makeMap(_, u)
- : emptyMap();
- }
- function updateNode(s, o, i, u, _, w, x, C) {
- return s
- ? s.update(o, i, u, _, w, x, C)
- : w === L
- ? s
- : (SetRef(C), SetRef(x), new ValueNode(o, u, [_, w]));
- }
- function isLeafNode(s) {
- return s.constructor === ValueNode || s.constructor === HashCollisionNode;
- }
- function mergeIntoNode(s, o, i, u, _) {
- if (s.keyHash === u) return new HashCollisionNode(o, u, [s.entry, _]);
- var w,
- C = (0 === i ? s.keyHash : s.keyHash >>> i) & j,
- L = (0 === i ? u : u >>> i) & j;
- return new BitmapIndexedNode(
- o,
- (1 << C) | (1 << L),
- C === L
- ? [mergeIntoNode(s, o, i + x, u, _)]
- : ((w = new ValueNode(o, u, _)), C < L ? [s, w] : [w, s])
- );
- }
- function createNodes(s, o, i, u) {
- s || (s = new OwnerID());
- for (var _ = new ValueNode(s, hash(i), [i, u]), w = 0; w < o.length; w++) {
- var x = o[w];
- _ = _.update(s, 0, void 0, x[0], x[1]);
- }
- return _;
- }
- function packNodes(s, o, i, u) {
- for (
- var _ = 0, w = 0, x = new Array(i), C = 0, j = 1, L = o.length;
- C < L;
- C++, j <<= 1
- ) {
- var B = o[C];
- void 0 !== B && C !== u && ((_ |= j), (x[w++] = B));
- }
- return new BitmapIndexedNode(s, _, x);
- }
- function expandNodes(s, o, i, u, _) {
- for (var w = 0, x = new Array(C), j = 0; 0 !== i; j++, i >>>= 1)
- x[j] = 1 & i ? o[w++] : void 0;
- return (x[u] = _), new HashArrayMapNode(s, w + 1, x);
- }
- function mergeIntoMapWith(s, o, i) {
- for (var u = [], _ = 0; _ < i.length; _++) {
- var w = i[_],
- x = KeyedIterable(w);
- isIterable(w) ||
- (x = x.map(function (s) {
- return fromJS(s);
- })),
- u.push(x);
- }
- return mergeIntoCollectionWith(s, o, u);
- }
- function deepMerger(s, o, i) {
- return s && s.mergeDeep && isIterable(o) ? s.mergeDeep(o) : is(s, o) ? s : o;
- }
- function deepMergerWith(s) {
- return function (o, i, u) {
- if (o && o.mergeDeepWith && isIterable(i)) return o.mergeDeepWith(s, i);
- var _ = s(o, i, u);
- return is(o, _) ? o : _;
- };
- }
- function mergeIntoCollectionWith(s, o, i) {
- return 0 ===
- (i = i.filter(function (s) {
- return 0 !== s.size;
- })).length
- ? s
- : 0 !== s.size || s.__ownerID || 1 !== i.length
- ? s.withMutations(function (s) {
- for (
- var u = o
- ? function (i, u) {
- s.update(u, L, function (s) {
- return s === L ? i : o(s, i, u);
- });
- }
- : function (o, i) {
- s.set(i, o);
- },
- _ = 0;
- _ < i.length;
- _++
- )
- i[_].forEach(u);
- })
- : s.constructor(i[0]);
- }
- function updateInDeepMap(s, o, i, u) {
- var _ = s === L,
- w = o.next();
- if (w.done) {
- var x = _ ? i : s,
- C = u(x);
- return C === x ? s : C;
- }
- invariant(_ || (s && s.set), 'invalid keyPath');
- var j = w.value,
- B = _ ? L : s.get(j, L),
- $ = updateInDeepMap(B, o, i, u);
- return $ === B ? s : $ === L ? s.remove(j) : (_ ? emptyMap() : s).set(j, $);
- }
- function popCount(s) {
- return (
- (s =
- ((s = (858993459 & (s -= (s >> 1) & 1431655765)) + ((s >> 2) & 858993459)) +
- (s >> 4)) &
- 252645135),
- (s += s >> 8),
- 127 & (s += s >> 16)
- );
- }
- function setIn(s, o, i, u) {
- var _ = u ? s : arrCopy(s);
- return (_[o] = i), _;
- }
- function spliceIn(s, o, i, u) {
- var _ = s.length + 1;
- if (u && o + 1 === _) return (s[o] = i), s;
- for (var w = new Array(_), x = 0, C = 0; C < _; C++)
- C === o ? ((w[C] = i), (x = -1)) : (w[C] = s[C + x]);
- return w;
- }
- function spliceOut(s, o, i) {
- var u = s.length - 1;
- if (i && o === u) return s.pop(), s;
- for (var _ = new Array(u), w = 0, x = 0; x < u; x++)
- x === o && (w = 1), (_[x] = s[x + w]);
- return _;
- }
- ($e[qe] = !0),
- ($e[w] = $e.remove),
- ($e.removeIn = $e.deleteIn),
- (ArrayMapNode.prototype.get = function (s, o, i, u) {
- for (var _ = this.entries, w = 0, x = _.length; w < x; w++)
- if (is(i, _[w][0])) return _[w][1];
- return u;
- }),
- (ArrayMapNode.prototype.update = function (s, o, i, u, _, w, x) {
- for (
- var C = _ === L, j = this.entries, B = 0, $ = j.length;
- B < $ && !is(u, j[B][0]);
- B++
- );
- var V = B < $;
- if (V ? j[B][1] === _ : C) return this;
- if ((SetRef(x), (C || !V) && SetRef(w), !C || 1 !== j.length)) {
- if (!V && !C && j.length >= ze) return createNodes(s, j, u, _);
- var U = s && s === this.ownerID,
- z = U ? j : arrCopy(j);
- return (
- V
- ? C
- ? B === $ - 1
- ? z.pop()
- : (z[B] = z.pop())
- : (z[B] = [u, _])
- : z.push([u, _]),
- U ? ((this.entries = z), this) : new ArrayMapNode(s, z)
- );
- }
- }),
- (BitmapIndexedNode.prototype.get = function (s, o, i, u) {
- void 0 === o && (o = hash(i));
- var _ = 1 << ((0 === s ? o : o >>> s) & j),
- w = this.bitmap;
- return w & _ ? this.nodes[popCount(w & (_ - 1))].get(s + x, o, i, u) : u;
- }),
- (BitmapIndexedNode.prototype.update = function (s, o, i, u, _, w, C) {
- void 0 === i && (i = hash(u));
- var B = (0 === o ? i : i >>> o) & j,
- $ = 1 << B,
- V = this.bitmap,
- U = !!(V & $);
- if (!U && _ === L) return this;
- var z = popCount(V & ($ - 1)),
- Y = this.nodes,
- Z = U ? Y[z] : void 0,
- ee = updateNode(Z, s, o + x, i, u, _, w, C);
- if (ee === Z) return this;
- if (!U && ee && Y.length >= We) return expandNodes(s, Y, V, B, ee);
- if (U && !ee && 2 === Y.length && isLeafNode(Y[1 ^ z])) return Y[1 ^ z];
- if (U && ee && 1 === Y.length && isLeafNode(ee)) return ee;
- var ie = s && s === this.ownerID,
- ae = U ? (ee ? V : V ^ $) : V | $,
- le = U
- ? ee
- ? setIn(Y, z, ee, ie)
- : spliceOut(Y, z, ie)
- : spliceIn(Y, z, ee, ie);
- return ie
- ? ((this.bitmap = ae), (this.nodes = le), this)
- : new BitmapIndexedNode(s, ae, le);
- }),
- (HashArrayMapNode.prototype.get = function (s, o, i, u) {
- void 0 === o && (o = hash(i));
- var _ = (0 === s ? o : o >>> s) & j,
- w = this.nodes[_];
- return w ? w.get(s + x, o, i, u) : u;
- }),
- (HashArrayMapNode.prototype.update = function (s, o, i, u, _, w, C) {
- void 0 === i && (i = hash(u));
- var B = (0 === o ? i : i >>> o) & j,
- $ = _ === L,
- V = this.nodes,
- U = V[B];
- if ($ && !U) return this;
- var z = updateNode(U, s, o + x, i, u, _, w, C);
- if (z === U) return this;
- var Y = this.count;
- if (U) {
- if (!z && --Y < He) return packNodes(s, V, Y, B);
- } else Y++;
- var Z = s && s === this.ownerID,
- ee = setIn(V, B, z, Z);
- return Z
- ? ((this.count = Y), (this.nodes = ee), this)
- : new HashArrayMapNode(s, Y, ee);
- }),
- (HashCollisionNode.prototype.get = function (s, o, i, u) {
- for (var _ = this.entries, w = 0, x = _.length; w < x; w++)
- if (is(i, _[w][0])) return _[w][1];
- return u;
- }),
- (HashCollisionNode.prototype.update = function (s, o, i, u, _, w, x) {
- void 0 === i && (i = hash(u));
- var C = _ === L;
- if (i !== this.keyHash)
- return C ? this : (SetRef(x), SetRef(w), mergeIntoNode(this, s, o, i, [u, _]));
- for (var j = this.entries, B = 0, $ = j.length; B < $ && !is(u, j[B][0]); B++);
- var V = B < $;
- if (V ? j[B][1] === _ : C) return this;
- if ((SetRef(x), (C || !V) && SetRef(w), C && 2 === $))
- return new ValueNode(s, this.keyHash, j[1 ^ B]);
- var U = s && s === this.ownerID,
- z = U ? j : arrCopy(j);
- return (
- V
- ? C
- ? B === $ - 1
- ? z.pop()
- : (z[B] = z.pop())
- : (z[B] = [u, _])
- : z.push([u, _]),
- U ? ((this.entries = z), this) : new HashCollisionNode(s, this.keyHash, z)
- );
- }),
- (ValueNode.prototype.get = function (s, o, i, u) {
- return is(i, this.entry[0]) ? this.entry[1] : u;
- }),
- (ValueNode.prototype.update = function (s, o, i, u, _, w, x) {
- var C = _ === L,
- j = is(u, this.entry[0]);
- return (j ? _ === this.entry[1] : C)
- ? this
- : (SetRef(x),
- C
- ? void SetRef(w)
- : j
- ? s && s === this.ownerID
- ? ((this.entry[1] = _), this)
- : new ValueNode(s, this.keyHash, [u, _])
- : (SetRef(w), mergeIntoNode(this, s, o, hash(u), [u, _])));
- }),
- (ArrayMapNode.prototype.iterate = HashCollisionNode.prototype.iterate =
- function (s, o) {
- for (var i = this.entries, u = 0, _ = i.length - 1; u <= _; u++)
- if (!1 === s(i[o ? _ - u : u])) return !1;
- }),
- (BitmapIndexedNode.prototype.iterate = HashArrayMapNode.prototype.iterate =
- function (s, o) {
- for (var i = this.nodes, u = 0, _ = i.length - 1; u <= _; u++) {
- var w = i[o ? _ - u : u];
- if (w && !1 === w.iterate(s, o)) return !1;
- }
- }),
- (ValueNode.prototype.iterate = function (s, o) {
- return s(this.entry);
- }),
- createClass(MapIterator, Iterator),
- (MapIterator.prototype.next = function () {
- for (var s = this._type, o = this._stack; o; ) {
- var i,
- u = o.node,
- _ = o.index++;
- if (u.entry) {
- if (0 === _) return mapIteratorValue(s, u.entry);
- } else if (u.entries) {
- if (_ <= (i = u.entries.length - 1))
- return mapIteratorValue(s, u.entries[this._reverse ? i - _ : _]);
- } else if (_ <= (i = u.nodes.length - 1)) {
- var w = u.nodes[this._reverse ? i - _ : _];
- if (w) {
- if (w.entry) return mapIteratorValue(s, w.entry);
- o = this._stack = mapIteratorFrame(w, o);
- }
- continue;
- }
- o = this._stack = this._stack.__prev;
- }
- return iteratorDone();
- });
- var ze = C / 4,
- We = C / 2,
- He = C / 4;
- function List(s) {
- var o = emptyList();
- if (null == s) return o;
- if (isList(s)) return s;
- var i = IndexedIterable(s),
- u = i.size;
- return 0 === u
- ? o
- : (assertNotInfinite(u),
- u > 0 && u < C
- ? makeList(0, u, x, null, new VNode(i.toArray()))
- : o.withMutations(function (s) {
- s.setSize(u),
- i.forEach(function (o, i) {
- return s.set(i, o);
- });
- }));
- }
- function isList(s) {
- return !(!s || !s[Ye]);
- }
- createClass(List, IndexedCollection),
- (List.of = function () {
- return this(arguments);
- }),
- (List.prototype.toString = function () {
- return this.__toString('List [', ']');
- }),
- (List.prototype.get = function (s, o) {
- if ((s = wrapIndex(this, s)) >= 0 && s < this.size) {
- var i = listNodeFor(this, (s += this._origin));
- return i && i.array[s & j];
- }
- return o;
- }),
- (List.prototype.set = function (s, o) {
- return updateList(this, s, o);
- }),
- (List.prototype.remove = function (s) {
- return this.has(s)
- ? 0 === s
- ? this.shift()
- : s === this.size - 1
- ? this.pop()
- : this.splice(s, 1)
- : this;
- }),
- (List.prototype.insert = function (s, o) {
- return this.splice(s, 0, o);
- }),
- (List.prototype.clear = function () {
- return 0 === this.size
- ? this
- : this.__ownerID
- ? ((this.size = this._origin = this._capacity = 0),
- (this._level = x),
- (this._root = this._tail = null),
- (this.__hash = void 0),
- (this.__altered = !0),
- this)
- : emptyList();
- }),
- (List.prototype.push = function () {
- var s = arguments,
- o = this.size;
- return this.withMutations(function (i) {
- setListBounds(i, 0, o + s.length);
- for (var u = 0; u < s.length; u++) i.set(o + u, s[u]);
- });
- }),
- (List.prototype.pop = function () {
- return setListBounds(this, 0, -1);
- }),
- (List.prototype.unshift = function () {
- var s = arguments;
- return this.withMutations(function (o) {
- setListBounds(o, -s.length);
- for (var i = 0; i < s.length; i++) o.set(i, s[i]);
- });
- }),
- (List.prototype.shift = function () {
- return setListBounds(this, 1);
- }),
- (List.prototype.merge = function () {
- return mergeIntoListWith(this, void 0, arguments);
- }),
- (List.prototype.mergeWith = function (o) {
- return mergeIntoListWith(this, o, s.call(arguments, 1));
- }),
- (List.prototype.mergeDeep = function () {
- return mergeIntoListWith(this, deepMerger, arguments);
- }),
- (List.prototype.mergeDeepWith = function (o) {
- var i = s.call(arguments, 1);
- return mergeIntoListWith(this, deepMergerWith(o), i);
- }),
- (List.prototype.setSize = function (s) {
- return setListBounds(this, 0, s);
- }),
- (List.prototype.slice = function (s, o) {
- var i = this.size;
- return wholeSlice(s, o, i)
- ? this
- : setListBounds(this, resolveBegin(s, i), resolveEnd(o, i));
- }),
- (List.prototype.__iterator = function (s, o) {
- var i = 0,
- u = iterateList(this, o);
- return new Iterator(function () {
- var o = u();
- return o === tt ? iteratorDone() : iteratorValue(s, i++, o);
- });
- }),
- (List.prototype.__iterate = function (s, o) {
- for (
- var i, u = 0, _ = iterateList(this, o);
- (i = _()) !== tt && !1 !== s(i, u++, this);
- );
- return u;
- }),
- (List.prototype.__ensureOwner = function (s) {
- return s === this.__ownerID
- ? this
- : s
- ? makeList(
- this._origin,
- this._capacity,
- this._level,
- this._root,
- this._tail,
- s,
- this.__hash
- )
- : ((this.__ownerID = s), this);
- }),
- (List.isList = isList);
- var Ye = '@@__IMMUTABLE_LIST__@@',
- Xe = List.prototype;
- function VNode(s, o) {
- (this.array = s), (this.ownerID = o);
- }
- (Xe[Ye] = !0),
- (Xe[w] = Xe.remove),
- (Xe.setIn = $e.setIn),
- (Xe.deleteIn = Xe.removeIn = $e.removeIn),
- (Xe.update = $e.update),
- (Xe.updateIn = $e.updateIn),
- (Xe.mergeIn = $e.mergeIn),
- (Xe.mergeDeepIn = $e.mergeDeepIn),
- (Xe.withMutations = $e.withMutations),
- (Xe.asMutable = $e.asMutable),
- (Xe.asImmutable = $e.asImmutable),
- (Xe.wasAltered = $e.wasAltered),
- (VNode.prototype.removeBefore = function (s, o, i) {
- if (i === o ? 1 << o : 0 === this.array.length) return this;
- var u = (i >>> o) & j;
- if (u >= this.array.length) return new VNode([], s);
- var _,
- w = 0 === u;
- if (o > 0) {
- var C = this.array[u];
- if ((_ = C && C.removeBefore(s, o - x, i)) === C && w) return this;
- }
- if (w && !_) return this;
- var L = editableVNode(this, s);
- if (!w) for (var B = 0; B < u; B++) L.array[B] = void 0;
- return _ && (L.array[u] = _), L;
- }),
- (VNode.prototype.removeAfter = function (s, o, i) {
- if (i === (o ? 1 << o : 0) || 0 === this.array.length) return this;
- var u,
- _ = ((i - 1) >>> o) & j;
- if (_ >= this.array.length) return this;
- if (o > 0) {
- var w = this.array[_];
- if ((u = w && w.removeAfter(s, o - x, i)) === w && _ === this.array.length - 1)
- return this;
- }
- var C = editableVNode(this, s);
- return C.array.splice(_ + 1), u && (C.array[_] = u), C;
- });
- var Qe,
- et,
- tt = {};
- function iterateList(s, o) {
- var i = s._origin,
- u = s._capacity,
- _ = getTailOffset(u),
- w = s._tail;
- return iterateNodeOrLeaf(s._root, s._level, 0);
- function iterateNodeOrLeaf(s, o, i) {
- return 0 === o ? iterateLeaf(s, i) : iterateNode(s, o, i);
- }
- function iterateLeaf(s, x) {
- var j = x === _ ? w && w.array : s && s.array,
- L = x > i ? 0 : i - x,
- B = u - x;
- return (
- B > C && (B = C),
- function () {
- if (L === B) return tt;
- var s = o ? --B : L++;
- return j && j[s];
- }
- );
- }
- function iterateNode(s, _, w) {
- var j,
- L = s && s.array,
- B = w > i ? 0 : (i - w) >> _,
- $ = 1 + ((u - w) >> _);
- return (
- $ > C && ($ = C),
- function () {
- for (;;) {
- if (j) {
- var s = j();
- if (s !== tt) return s;
- j = null;
- }
- if (B === $) return tt;
- var i = o ? --$ : B++;
- j = iterateNodeOrLeaf(L && L[i], _ - x, w + (i << _));
- }
- }
- );
- }
- }
- function makeList(s, o, i, u, _, w, x) {
- var C = Object.create(Xe);
- return (
- (C.size = o - s),
- (C._origin = s),
- (C._capacity = o),
- (C._level = i),
- (C._root = u),
- (C._tail = _),
- (C.__ownerID = w),
- (C.__hash = x),
- (C.__altered = !1),
- C
- );
- }
- function emptyList() {
- return Qe || (Qe = makeList(0, 0, x));
- }
- function updateList(s, o, i) {
- if ((o = wrapIndex(s, o)) != o) return s;
- if (o >= s.size || o < 0)
- return s.withMutations(function (s) {
- o < 0 ? setListBounds(s, o).set(0, i) : setListBounds(s, 0, o + 1).set(o, i);
- });
- o += s._origin;
- var u = s._tail,
- _ = s._root,
- w = MakeRef($);
- return (
- o >= getTailOffset(s._capacity)
- ? (u = updateVNode(u, s.__ownerID, 0, o, i, w))
- : (_ = updateVNode(_, s.__ownerID, s._level, o, i, w)),
- w.value
- ? s.__ownerID
- ? ((s._root = _), (s._tail = u), (s.__hash = void 0), (s.__altered = !0), s)
- : makeList(s._origin, s._capacity, s._level, _, u)
- : s
- );
- }
- function updateVNode(s, o, i, u, _, w) {
- var C,
- L = (u >>> i) & j,
- B = s && L < s.array.length;
- if (!B && void 0 === _) return s;
- if (i > 0) {
- var $ = s && s.array[L],
- V = updateVNode($, o, i - x, u, _, w);
- return V === $ ? s : (((C = editableVNode(s, o)).array[L] = V), C);
- }
- return B && s.array[L] === _
- ? s
- : (SetRef(w),
- (C = editableVNode(s, o)),
- void 0 === _ && L === C.array.length - 1 ? C.array.pop() : (C.array[L] = _),
- C);
- }
- function editableVNode(s, o) {
- return o && s && o === s.ownerID ? s : new VNode(s ? s.array.slice() : [], o);
- }
- function listNodeFor(s, o) {
- if (o >= getTailOffset(s._capacity)) return s._tail;
- if (o < 1 << (s._level + x)) {
- for (var i = s._root, u = s._level; i && u > 0; )
- (i = i.array[(o >>> u) & j]), (u -= x);
- return i;
- }
- }
- function setListBounds(s, o, i) {
- void 0 !== o && (o |= 0), void 0 !== i && (i |= 0);
- var u = s.__ownerID || new OwnerID(),
- _ = s._origin,
- w = s._capacity,
- C = _ + o,
- L = void 0 === i ? w : i < 0 ? w + i : _ + i;
- if (C === _ && L === w) return s;
- if (C >= L) return s.clear();
- for (var B = s._level, $ = s._root, V = 0; C + V < 0; )
- ($ = new VNode($ && $.array.length ? [void 0, $] : [], u)), (V += 1 << (B += x));
- V && ((C += V), (_ += V), (L += V), (w += V));
- for (var U = getTailOffset(w), z = getTailOffset(L); z >= 1 << (B + x); )
- ($ = new VNode($ && $.array.length ? [$] : [], u)), (B += x);
- var Y = s._tail,
- Z = z < U ? listNodeFor(s, L - 1) : z > U ? new VNode([], u) : Y;
- if (Y && z > U && C < w && Y.array.length) {
- for (var ee = ($ = editableVNode($, u)), ie = B; ie > x; ie -= x) {
- var ae = (U >>> ie) & j;
- ee = ee.array[ae] = editableVNode(ee.array[ae], u);
- }
- ee.array[(U >>> x) & j] = Y;
- }
- if ((L < w && (Z = Z && Z.removeAfter(u, 0, L)), C >= z))
- (C -= z), (L -= z), (B = x), ($ = null), (Z = Z && Z.removeBefore(u, 0, C));
- else if (C > _ || z < U) {
- for (V = 0; $; ) {
- var le = (C >>> B) & j;
- if ((le !== z >>> B) & j) break;
- le && (V += (1 << B) * le), (B -= x), ($ = $.array[le]);
- }
- $ && C > _ && ($ = $.removeBefore(u, B, C - V)),
- $ && z < U && ($ = $.removeAfter(u, B, z - V)),
- V && ((C -= V), (L -= V));
- }
- return s.__ownerID
- ? ((s.size = L - C),
- (s._origin = C),
- (s._capacity = L),
- (s._level = B),
- (s._root = $),
- (s._tail = Z),
- (s.__hash = void 0),
- (s.__altered = !0),
- s)
- : makeList(C, L, B, $, Z);
- }
- function mergeIntoListWith(s, o, i) {
- for (var u = [], _ = 0, w = 0; w < i.length; w++) {
- var x = i[w],
- C = IndexedIterable(x);
- C.size > _ && (_ = C.size),
- isIterable(x) ||
- (C = C.map(function (s) {
- return fromJS(s);
- })),
- u.push(C);
- }
- return _ > s.size && (s = s.setSize(_)), mergeIntoCollectionWith(s, o, u);
- }
- function getTailOffset(s) {
- return s < C ? 0 : ((s - 1) >>> x) << x;
- }
- function OrderedMap(s) {
- return null == s
- ? emptyOrderedMap()
- : isOrderedMap(s)
- ? s
- : emptyOrderedMap().withMutations(function (o) {
- var i = KeyedIterable(s);
- assertNotInfinite(i.size),
- i.forEach(function (s, i) {
- return o.set(i, s);
- });
- });
- }
- function isOrderedMap(s) {
- return isMap(s) && isOrdered(s);
- }
- function makeOrderedMap(s, o, i, u) {
- var _ = Object.create(OrderedMap.prototype);
- return (
- (_.size = s ? s.size : 0),
- (_._map = s),
- (_._list = o),
- (_.__ownerID = i),
- (_.__hash = u),
- _
- );
- }
- function emptyOrderedMap() {
- return et || (et = makeOrderedMap(emptyMap(), emptyList()));
- }
- function updateOrderedMap(s, o, i) {
- var u,
- _,
- w = s._map,
- x = s._list,
- j = w.get(o),
- B = void 0 !== j;
- if (i === L) {
- if (!B) return s;
- x.size >= C && x.size >= 2 * w.size
- ? ((u = (_ = x.filter(function (s, o) {
- return void 0 !== s && j !== o;
- }))
- .toKeyedSeq()
- .map(function (s) {
- return s[0];
- })
- .flip()
- .toMap()),
- s.__ownerID && (u.__ownerID = _.__ownerID = s.__ownerID))
- : ((u = w.remove(o)), (_ = j === x.size - 1 ? x.pop() : x.set(j, void 0)));
- } else if (B) {
- if (i === x.get(j)[1]) return s;
- (u = w), (_ = x.set(j, [o, i]));
- } else (u = w.set(o, x.size)), (_ = x.set(x.size, [o, i]));
- return s.__ownerID
- ? ((s.size = u.size), (s._map = u), (s._list = _), (s.__hash = void 0), s)
- : makeOrderedMap(u, _);
- }
- function ToKeyedSequence(s, o) {
- (this._iter = s), (this._useKeys = o), (this.size = s.size);
- }
- function ToIndexedSequence(s) {
- (this._iter = s), (this.size = s.size);
- }
- function ToSetSequence(s) {
- (this._iter = s), (this.size = s.size);
- }
- function FromEntriesSequence(s) {
- (this._iter = s), (this.size = s.size);
- }
- function flipFactory(s) {
- var o = makeSequence(s);
- return (
- (o._iter = s),
- (o.size = s.size),
- (o.flip = function () {
- return s;
- }),
- (o.reverse = function () {
- var o = s.reverse.apply(this);
- return (
- (o.flip = function () {
- return s.reverse();
- }),
- o
- );
- }),
- (o.has = function (o) {
- return s.includes(o);
- }),
- (o.includes = function (o) {
- return s.has(o);
- }),
- (o.cacheResult = cacheResultThrough),
- (o.__iterateUncached = function (o, i) {
- var u = this;
- return s.__iterate(function (s, i) {
- return !1 !== o(i, s, u);
- }, i);
- }),
- (o.__iteratorUncached = function (o, i) {
- if (o === z) {
- var u = s.__iterator(o, i);
- return new Iterator(function () {
- var s = u.next();
- if (!s.done) {
- var o = s.value[0];
- (s.value[0] = s.value[1]), (s.value[1] = o);
- }
- return s;
- });
- }
- return s.__iterator(o === U ? V : U, i);
- }),
- o
- );
- }
- function mapFactory(s, o, i) {
- var u = makeSequence(s);
- return (
- (u.size = s.size),
- (u.has = function (o) {
- return s.has(o);
- }),
- (u.get = function (u, _) {
- var w = s.get(u, L);
- return w === L ? _ : o.call(i, w, u, s);
- }),
- (u.__iterateUncached = function (u, _) {
- var w = this;
- return s.__iterate(function (s, _, x) {
- return !1 !== u(o.call(i, s, _, x), _, w);
- }, _);
- }),
- (u.__iteratorUncached = function (u, _) {
- var w = s.__iterator(z, _);
- return new Iterator(function () {
- var _ = w.next();
- if (_.done) return _;
- var x = _.value,
- C = x[0];
- return iteratorValue(u, C, o.call(i, x[1], C, s), _);
- });
- }),
- u
- );
- }
- function reverseFactory(s, o) {
- var i = makeSequence(s);
- return (
- (i._iter = s),
- (i.size = s.size),
- (i.reverse = function () {
- return s;
- }),
- s.flip &&
- (i.flip = function () {
- var o = flipFactory(s);
- return (
- (o.reverse = function () {
- return s.flip();
- }),
- o
- );
- }),
- (i.get = function (i, u) {
- return s.get(o ? i : -1 - i, u);
- }),
- (i.has = function (i) {
- return s.has(o ? i : -1 - i);
- }),
- (i.includes = function (o) {
- return s.includes(o);
- }),
- (i.cacheResult = cacheResultThrough),
- (i.__iterate = function (o, i) {
- var u = this;
- return s.__iterate(function (s, i) {
- return o(s, i, u);
- }, !i);
- }),
- (i.__iterator = function (o, i) {
- return s.__iterator(o, !i);
- }),
- i
- );
- }
- function filterFactory(s, o, i, u) {
- var _ = makeSequence(s);
- return (
- u &&
- ((_.has = function (u) {
- var _ = s.get(u, L);
- return _ !== L && !!o.call(i, _, u, s);
- }),
- (_.get = function (u, _) {
- var w = s.get(u, L);
- return w !== L && o.call(i, w, u, s) ? w : _;
- })),
- (_.__iterateUncached = function (_, w) {
- var x = this,
- C = 0;
- return (
- s.__iterate(function (s, w, j) {
- if (o.call(i, s, w, j)) return C++, _(s, u ? w : C - 1, x);
- }, w),
- C
- );
- }),
- (_.__iteratorUncached = function (_, w) {
- var x = s.__iterator(z, w),
- C = 0;
- return new Iterator(function () {
- for (;;) {
- var w = x.next();
- if (w.done) return w;
- var j = w.value,
- L = j[0],
- B = j[1];
- if (o.call(i, B, L, s)) return iteratorValue(_, u ? L : C++, B, w);
- }
- });
- }),
- _
- );
- }
- function countByFactory(s, o, i) {
- var u = Map().asMutable();
- return (
- s.__iterate(function (_, w) {
- u.update(o.call(i, _, w, s), 0, function (s) {
- return s + 1;
- });
- }),
- u.asImmutable()
- );
- }
- function groupByFactory(s, o, i) {
- var u = isKeyed(s),
- _ = (isOrdered(s) ? OrderedMap() : Map()).asMutable();
- s.__iterate(function (w, x) {
- _.update(o.call(i, w, x, s), function (s) {
- return (s = s || []).push(u ? [x, w] : w), s;
- });
- });
- var w = iterableClass(s);
- return _.map(function (o) {
- return reify(s, w(o));
- });
- }
- function sliceFactory(s, o, i, u) {
- var _ = s.size;
- if (
- (void 0 !== o && (o |= 0),
- void 0 !== i && (i === 1 / 0 ? (i = _) : (i |= 0)),
- wholeSlice(o, i, _))
- )
- return s;
- var w = resolveBegin(o, _),
- x = resolveEnd(i, _);
- if (w != w || x != x) return sliceFactory(s.toSeq().cacheResult(), o, i, u);
- var C,
- j = x - w;
- j == j && (C = j < 0 ? 0 : j);
- var L = makeSequence(s);
- return (
- (L.size = 0 === C ? C : (s.size && C) || void 0),
- !u &&
- isSeq(s) &&
- C >= 0 &&
- (L.get = function (o, i) {
- return (o = wrapIndex(this, o)) >= 0 && o < C ? s.get(o + w, i) : i;
- }),
- (L.__iterateUncached = function (o, i) {
- var _ = this;
- if (0 === C) return 0;
- if (i) return this.cacheResult().__iterate(o, i);
- var x = 0,
- j = !0,
- L = 0;
- return (
- s.__iterate(function (s, i) {
- if (!j || !(j = x++ < w))
- return L++, !1 !== o(s, u ? i : L - 1, _) && L !== C;
- }),
- L
- );
- }),
- (L.__iteratorUncached = function (o, i) {
- if (0 !== C && i) return this.cacheResult().__iterator(o, i);
- var _ = 0 !== C && s.__iterator(o, i),
- x = 0,
- j = 0;
- return new Iterator(function () {
- for (; x++ < w; ) _.next();
- if (++j > C) return iteratorDone();
- var s = _.next();
- return u || o === U
- ? s
- : iteratorValue(o, j - 1, o === V ? void 0 : s.value[1], s);
- });
- }),
- L
- );
- }
- function takeWhileFactory(s, o, i) {
- var u = makeSequence(s);
- return (
- (u.__iterateUncached = function (u, _) {
- var w = this;
- if (_) return this.cacheResult().__iterate(u, _);
- var x = 0;
- return (
- s.__iterate(function (s, _, C) {
- return o.call(i, s, _, C) && ++x && u(s, _, w);
- }),
- x
- );
- }),
- (u.__iteratorUncached = function (u, _) {
- var w = this;
- if (_) return this.cacheResult().__iterator(u, _);
- var x = s.__iterator(z, _),
- C = !0;
- return new Iterator(function () {
- if (!C) return iteratorDone();
- var s = x.next();
- if (s.done) return s;
- var _ = s.value,
- j = _[0],
- L = _[1];
- return o.call(i, L, j, w)
- ? u === z
- ? s
- : iteratorValue(u, j, L, s)
- : ((C = !1), iteratorDone());
- });
- }),
- u
- );
- }
- function skipWhileFactory(s, o, i, u) {
- var _ = makeSequence(s);
- return (
- (_.__iterateUncached = function (_, w) {
- var x = this;
- if (w) return this.cacheResult().__iterate(_, w);
- var C = !0,
- j = 0;
- return (
- s.__iterate(function (s, w, L) {
- if (!C || !(C = o.call(i, s, w, L))) return j++, _(s, u ? w : j - 1, x);
- }),
- j
- );
- }),
- (_.__iteratorUncached = function (_, w) {
- var x = this;
- if (w) return this.cacheResult().__iterator(_, w);
- var C = s.__iterator(z, w),
- j = !0,
- L = 0;
- return new Iterator(function () {
- var s, w, B;
- do {
- if ((s = C.next()).done)
- return u || _ === U
- ? s
- : iteratorValue(_, L++, _ === V ? void 0 : s.value[1], s);
- var $ = s.value;
- (w = $[0]), (B = $[1]), j && (j = o.call(i, B, w, x));
- } while (j);
- return _ === z ? s : iteratorValue(_, w, B, s);
- });
- }),
- _
- );
- }
- function concatFactory(s, o) {
- var i = isKeyed(s),
- u = [s]
- .concat(o)
- .map(function (s) {
- return (
- isIterable(s)
- ? i && (s = KeyedIterable(s))
- : (s = i
- ? keyedSeqFromValue(s)
- : indexedSeqFromValue(Array.isArray(s) ? s : [s])),
- s
- );
- })
- .filter(function (s) {
- return 0 !== s.size;
- });
- if (0 === u.length) return s;
- if (1 === u.length) {
- var _ = u[0];
- if (_ === s || (i && isKeyed(_)) || (isIndexed(s) && isIndexed(_))) return _;
- }
- var w = new ArraySeq(u);
- return (
- i ? (w = w.toKeyedSeq()) : isIndexed(s) || (w = w.toSetSeq()),
- ((w = w.flatten(!0)).size = u.reduce(function (s, o) {
- if (void 0 !== s) {
- var i = o.size;
- if (void 0 !== i) return s + i;
- }
- }, 0)),
- w
- );
- }
- function flattenFactory(s, o, i) {
- var u = makeSequence(s);
- return (
- (u.__iterateUncached = function (u, _) {
- var w = 0,
- x = !1;
- function flatDeep(s, C) {
- var j = this;
- s.__iterate(function (s, _) {
- return (
- (!o || C < o) && isIterable(s)
- ? flatDeep(s, C + 1)
- : !1 === u(s, i ? _ : w++, j) && (x = !0),
- !x
- );
- }, _);
- }
- return flatDeep(s, 0), w;
- }),
- (u.__iteratorUncached = function (u, _) {
- var w = s.__iterator(u, _),
- x = [],
- C = 0;
- return new Iterator(function () {
- for (; w; ) {
- var s = w.next();
- if (!1 === s.done) {
- var j = s.value;
- if ((u === z && (j = j[1]), (o && !(x.length < o)) || !isIterable(j)))
- return i ? s : iteratorValue(u, C++, j, s);
- x.push(w), (w = j.__iterator(u, _));
- } else w = x.pop();
- }
- return iteratorDone();
- });
- }),
- u
- );
- }
- function flatMapFactory(s, o, i) {
- var u = iterableClass(s);
- return s
- .toSeq()
- .map(function (_, w) {
- return u(o.call(i, _, w, s));
- })
- .flatten(!0);
- }
- function interposeFactory(s, o) {
- var i = makeSequence(s);
- return (
- (i.size = s.size && 2 * s.size - 1),
- (i.__iterateUncached = function (i, u) {
- var _ = this,
- w = 0;
- return (
- s.__iterate(function (s, u) {
- return (!w || !1 !== i(o, w++, _)) && !1 !== i(s, w++, _);
- }, u),
- w
- );
- }),
- (i.__iteratorUncached = function (i, u) {
- var _,
- w = s.__iterator(U, u),
- x = 0;
- return new Iterator(function () {
- return (!_ || x % 2) && (_ = w.next()).done
- ? _
- : x % 2
- ? iteratorValue(i, x++, o)
- : iteratorValue(i, x++, _.value, _);
- });
- }),
- i
- );
- }
- function sortFactory(s, o, i) {
- o || (o = defaultComparator);
- var u = isKeyed(s),
- _ = 0,
- w = s
- .toSeq()
- .map(function (o, u) {
- return [u, o, _++, i ? i(o, u, s) : o];
- })
- .toArray();
- return (
- w
- .sort(function (s, i) {
- return o(s[3], i[3]) || s[2] - i[2];
- })
- .forEach(
- u
- ? function (s, o) {
- w[o].length = 2;
- }
- : function (s, o) {
- w[o] = s[1];
- }
- ),
- u ? KeyedSeq(w) : isIndexed(s) ? IndexedSeq(w) : SetSeq(w)
- );
- }
- function maxFactory(s, o, i) {
- if ((o || (o = defaultComparator), i)) {
- var u = s
- .toSeq()
- .map(function (o, u) {
- return [o, i(o, u, s)];
- })
- .reduce(function (s, i) {
- return maxCompare(o, s[1], i[1]) ? i : s;
- });
- return u && u[0];
- }
- return s.reduce(function (s, i) {
- return maxCompare(o, s, i) ? i : s;
- });
- }
- function maxCompare(s, o, i) {
- var u = s(i, o);
- return (0 === u && i !== o && (null == i || i != i)) || u > 0;
- }
- function zipWithFactory(s, o, i) {
- var u = makeSequence(s);
- return (
- (u.size = new ArraySeq(i)
- .map(function (s) {
- return s.size;
- })
- .min()),
- (u.__iterate = function (s, o) {
- for (
- var i, u = this.__iterator(U, o), _ = 0;
- !(i = u.next()).done && !1 !== s(i.value, _++, this);
- );
- return _;
- }),
- (u.__iteratorUncached = function (s, u) {
- var _ = i.map(function (s) {
- return (s = Iterable(s)), getIterator(u ? s.reverse() : s);
- }),
- w = 0,
- x = !1;
- return new Iterator(function () {
- var i;
- return (
- x ||
- ((i = _.map(function (s) {
- return s.next();
- })),
- (x = i.some(function (s) {
- return s.done;
- }))),
- x
- ? iteratorDone()
- : iteratorValue(
- s,
- w++,
- o.apply(
- null,
- i.map(function (s) {
- return s.value;
- })
- )
- )
- );
- });
- }),
- u
- );
- }
- function reify(s, o) {
- return isSeq(s) ? o : s.constructor(o);
- }
- function validateEntry(s) {
- if (s !== Object(s)) throw new TypeError('Expected [K, V] tuple: ' + s);
- }
- function resolveSize(s) {
- return assertNotInfinite(s.size), ensureSize(s);
- }
- function iterableClass(s) {
- return isKeyed(s) ? KeyedIterable : isIndexed(s) ? IndexedIterable : SetIterable;
- }
- function makeSequence(s) {
- return Object.create(
- (isKeyed(s) ? KeyedSeq : isIndexed(s) ? IndexedSeq : SetSeq).prototype
- );
- }
- function cacheResultThrough() {
- return this._iter.cacheResult
- ? (this._iter.cacheResult(), (this.size = this._iter.size), this)
- : Seq.prototype.cacheResult.call(this);
- }
- function defaultComparator(s, o) {
- return s > o ? 1 : s < o ? -1 : 0;
- }
- function forceIterator(s) {
- var o = getIterator(s);
- if (!o) {
- if (!isArrayLike(s)) throw new TypeError('Expected iterable or array-like: ' + s);
- o = getIterator(Iterable(s));
- }
- return o;
- }
- function Record(s, o) {
- var i,
- u = function Record(w) {
- if (w instanceof u) return w;
- if (!(this instanceof u)) return new u(w);
- if (!i) {
- i = !0;
- var x = Object.keys(s);
- setProps(_, x),
- (_.size = x.length),
- (_._name = o),
- (_._keys = x),
- (_._defaultValues = s);
- }
- this._map = Map(w);
- },
- _ = (u.prototype = Object.create(rt));
- return (_.constructor = u), u;
- }
- createClass(OrderedMap, Map),
- (OrderedMap.of = function () {
- return this(arguments);
- }),
- (OrderedMap.prototype.toString = function () {
- return this.__toString('OrderedMap {', '}');
- }),
- (OrderedMap.prototype.get = function (s, o) {
- var i = this._map.get(s);
- return void 0 !== i ? this._list.get(i)[1] : o;
- }),
- (OrderedMap.prototype.clear = function () {
- return 0 === this.size
- ? this
- : this.__ownerID
- ? ((this.size = 0), this._map.clear(), this._list.clear(), this)
- : emptyOrderedMap();
- }),
- (OrderedMap.prototype.set = function (s, o) {
- return updateOrderedMap(this, s, o);
- }),
- (OrderedMap.prototype.remove = function (s) {
- return updateOrderedMap(this, s, L);
- }),
- (OrderedMap.prototype.wasAltered = function () {
- return this._map.wasAltered() || this._list.wasAltered();
- }),
- (OrderedMap.prototype.__iterate = function (s, o) {
- var i = this;
- return this._list.__iterate(function (o) {
- return o && s(o[1], o[0], i);
- }, o);
- }),
- (OrderedMap.prototype.__iterator = function (s, o) {
- return this._list.fromEntrySeq().__iterator(s, o);
- }),
- (OrderedMap.prototype.__ensureOwner = function (s) {
- if (s === this.__ownerID) return this;
- var o = this._map.__ensureOwner(s),
- i = this._list.__ensureOwner(s);
- return s
- ? makeOrderedMap(o, i, s, this.__hash)
- : ((this.__ownerID = s), (this._map = o), (this._list = i), this);
- }),
- (OrderedMap.isOrderedMap = isOrderedMap),
- (OrderedMap.prototype[_] = !0),
- (OrderedMap.prototype[w] = OrderedMap.prototype.remove),
- createClass(ToKeyedSequence, KeyedSeq),
- (ToKeyedSequence.prototype.get = function (s, o) {
- return this._iter.get(s, o);
- }),
- (ToKeyedSequence.prototype.has = function (s) {
- return this._iter.has(s);
- }),
- (ToKeyedSequence.prototype.valueSeq = function () {
- return this._iter.valueSeq();
- }),
- (ToKeyedSequence.prototype.reverse = function () {
- var s = this,
- o = reverseFactory(this, !0);
- return (
- this._useKeys ||
- (o.valueSeq = function () {
- return s._iter.toSeq().reverse();
- }),
- o
- );
- }),
- (ToKeyedSequence.prototype.map = function (s, o) {
- var i = this,
- u = mapFactory(this, s, o);
- return (
- this._useKeys ||
- (u.valueSeq = function () {
- return i._iter.toSeq().map(s, o);
- }),
- u
- );
- }),
- (ToKeyedSequence.prototype.__iterate = function (s, o) {
- var i,
- u = this;
- return this._iter.__iterate(
- this._useKeys
- ? function (o, i) {
- return s(o, i, u);
- }
- : ((i = o ? resolveSize(this) : 0),
- function (_) {
- return s(_, o ? --i : i++, u);
- }),
- o
- );
- }),
- (ToKeyedSequence.prototype.__iterator = function (s, o) {
- if (this._useKeys) return this._iter.__iterator(s, o);
- var i = this._iter.__iterator(U, o),
- u = o ? resolveSize(this) : 0;
- return new Iterator(function () {
- var _ = i.next();
- return _.done ? _ : iteratorValue(s, o ? --u : u++, _.value, _);
- });
- }),
- (ToKeyedSequence.prototype[_] = !0),
- createClass(ToIndexedSequence, IndexedSeq),
- (ToIndexedSequence.prototype.includes = function (s) {
- return this._iter.includes(s);
- }),
- (ToIndexedSequence.prototype.__iterate = function (s, o) {
- var i = this,
- u = 0;
- return this._iter.__iterate(function (o) {
- return s(o, u++, i);
- }, o);
- }),
- (ToIndexedSequence.prototype.__iterator = function (s, o) {
- var i = this._iter.__iterator(U, o),
- u = 0;
- return new Iterator(function () {
- var o = i.next();
- return o.done ? o : iteratorValue(s, u++, o.value, o);
- });
- }),
- createClass(ToSetSequence, SetSeq),
- (ToSetSequence.prototype.has = function (s) {
- return this._iter.includes(s);
- }),
- (ToSetSequence.prototype.__iterate = function (s, o) {
- var i = this;
- return this._iter.__iterate(function (o) {
- return s(o, o, i);
- }, o);
- }),
- (ToSetSequence.prototype.__iterator = function (s, o) {
- var i = this._iter.__iterator(U, o);
- return new Iterator(function () {
- var o = i.next();
- return o.done ? o : iteratorValue(s, o.value, o.value, o);
- });
- }),
- createClass(FromEntriesSequence, KeyedSeq),
- (FromEntriesSequence.prototype.entrySeq = function () {
- return this._iter.toSeq();
- }),
- (FromEntriesSequence.prototype.__iterate = function (s, o) {
- var i = this;
- return this._iter.__iterate(function (o) {
- if (o) {
- validateEntry(o);
- var u = isIterable(o);
- return s(u ? o.get(1) : o[1], u ? o.get(0) : o[0], i);
- }
- }, o);
- }),
- (FromEntriesSequence.prototype.__iterator = function (s, o) {
- var i = this._iter.__iterator(U, o);
- return new Iterator(function () {
- for (;;) {
- var o = i.next();
- if (o.done) return o;
- var u = o.value;
- if (u) {
- validateEntry(u);
- var _ = isIterable(u);
- return iteratorValue(s, _ ? u.get(0) : u[0], _ ? u.get(1) : u[1], o);
- }
- }
- });
- }),
- (ToIndexedSequence.prototype.cacheResult =
- ToKeyedSequence.prototype.cacheResult =
- ToSetSequence.prototype.cacheResult =
- FromEntriesSequence.prototype.cacheResult =
- cacheResultThrough),
- createClass(Record, KeyedCollection),
- (Record.prototype.toString = function () {
- return this.__toString(recordName(this) + ' {', '}');
- }),
- (Record.prototype.has = function (s) {
- return this._defaultValues.hasOwnProperty(s);
- }),
- (Record.prototype.get = function (s, o) {
- if (!this.has(s)) return o;
- var i = this._defaultValues[s];
- return this._map ? this._map.get(s, i) : i;
- }),
- (Record.prototype.clear = function () {
- if (this.__ownerID) return this._map && this._map.clear(), this;
- var s = this.constructor;
- return s._empty || (s._empty = makeRecord(this, emptyMap()));
- }),
- (Record.prototype.set = function (s, o) {
- if (!this.has(s))
- throw new Error('Cannot set unknown key "' + s + '" on ' + recordName(this));
- if (this._map && !this._map.has(s) && o === this._defaultValues[s]) return this;
- var i = this._map && this._map.set(s, o);
- return this.__ownerID || i === this._map ? this : makeRecord(this, i);
- }),
- (Record.prototype.remove = function (s) {
- if (!this.has(s)) return this;
- var o = this._map && this._map.remove(s);
- return this.__ownerID || o === this._map ? this : makeRecord(this, o);
- }),
- (Record.prototype.wasAltered = function () {
- return this._map.wasAltered();
- }),
- (Record.prototype.__iterator = function (s, o) {
- var i = this;
- return KeyedIterable(this._defaultValues)
- .map(function (s, o) {
- return i.get(o);
- })
- .__iterator(s, o);
- }),
- (Record.prototype.__iterate = function (s, o) {
- var i = this;
- return KeyedIterable(this._defaultValues)
- .map(function (s, o) {
- return i.get(o);
- })
- .__iterate(s, o);
- }),
- (Record.prototype.__ensureOwner = function (s) {
- if (s === this.__ownerID) return this;
- var o = this._map && this._map.__ensureOwner(s);
- return s ? makeRecord(this, o, s) : ((this.__ownerID = s), (this._map = o), this);
- });
- var rt = Record.prototype;
- function makeRecord(s, o, i) {
- var u = Object.create(Object.getPrototypeOf(s));
- return (u._map = o), (u.__ownerID = i), u;
- }
- function recordName(s) {
- return s._name || s.constructor.name || 'Record';
- }
- function setProps(s, o) {
- try {
- o.forEach(setProp.bind(void 0, s));
- } catch (s) {}
- }
- function setProp(s, o) {
- Object.defineProperty(s, o, {
- get: function () {
- return this.get(o);
- },
- set: function (s) {
- invariant(this.__ownerID, 'Cannot set on an immutable record.'), this.set(o, s);
- }
- });
- }
- function Set(s) {
- return null == s
- ? emptySet()
- : isSet(s) && !isOrdered(s)
- ? s
- : emptySet().withMutations(function (o) {
- var i = SetIterable(s);
- assertNotInfinite(i.size),
- i.forEach(function (s) {
- return o.add(s);
- });
- });
- }
- function isSet(s) {
- return !(!s || !s[st]);
- }
- (rt[w] = rt.remove),
- (rt.deleteIn = rt.removeIn = $e.removeIn),
- (rt.merge = $e.merge),
- (rt.mergeWith = $e.mergeWith),
- (rt.mergeIn = $e.mergeIn),
- (rt.mergeDeep = $e.mergeDeep),
- (rt.mergeDeepWith = $e.mergeDeepWith),
- (rt.mergeDeepIn = $e.mergeDeepIn),
- (rt.setIn = $e.setIn),
- (rt.update = $e.update),
- (rt.updateIn = $e.updateIn),
- (rt.withMutations = $e.withMutations),
- (rt.asMutable = $e.asMutable),
- (rt.asImmutable = $e.asImmutable),
- createClass(Set, SetCollection),
- (Set.of = function () {
- return this(arguments);
- }),
- (Set.fromKeys = function (s) {
- return this(KeyedIterable(s).keySeq());
- }),
- (Set.prototype.toString = function () {
- return this.__toString('Set {', '}');
- }),
- (Set.prototype.has = function (s) {
- return this._map.has(s);
- }),
- (Set.prototype.add = function (s) {
- return updateSet(this, this._map.set(s, !0));
- }),
- (Set.prototype.remove = function (s) {
- return updateSet(this, this._map.remove(s));
- }),
- (Set.prototype.clear = function () {
- return updateSet(this, this._map.clear());
- }),
- (Set.prototype.union = function () {
- var o = s.call(arguments, 0);
- return 0 ===
- (o = o.filter(function (s) {
- return 0 !== s.size;
- })).length
- ? this
- : 0 !== this.size || this.__ownerID || 1 !== o.length
- ? this.withMutations(function (s) {
- for (var i = 0; i < o.length; i++)
- SetIterable(o[i]).forEach(function (o) {
- return s.add(o);
- });
- })
- : this.constructor(o[0]);
- }),
- (Set.prototype.intersect = function () {
- var o = s.call(arguments, 0);
- if (0 === o.length) return this;
- o = o.map(function (s) {
- return SetIterable(s);
- });
- var i = this;
- return this.withMutations(function (s) {
- i.forEach(function (i) {
- o.every(function (s) {
- return s.includes(i);
- }) || s.remove(i);
- });
- });
- }),
- (Set.prototype.subtract = function () {
- var o = s.call(arguments, 0);
- if (0 === o.length) return this;
- o = o.map(function (s) {
- return SetIterable(s);
- });
- var i = this;
- return this.withMutations(function (s) {
- i.forEach(function (i) {
- o.some(function (s) {
- return s.includes(i);
- }) && s.remove(i);
- });
- });
- }),
- (Set.prototype.merge = function () {
- return this.union.apply(this, arguments);
- }),
- (Set.prototype.mergeWith = function (o) {
- var i = s.call(arguments, 1);
- return this.union.apply(this, i);
- }),
- (Set.prototype.sort = function (s) {
- return OrderedSet(sortFactory(this, s));
- }),
- (Set.prototype.sortBy = function (s, o) {
- return OrderedSet(sortFactory(this, o, s));
- }),
- (Set.prototype.wasAltered = function () {
- return this._map.wasAltered();
- }),
- (Set.prototype.__iterate = function (s, o) {
- var i = this;
- return this._map.__iterate(function (o, u) {
- return s(u, u, i);
- }, o);
- }),
- (Set.prototype.__iterator = function (s, o) {
- return this._map
- .map(function (s, o) {
- return o;
- })
- .__iterator(s, o);
- }),
- (Set.prototype.__ensureOwner = function (s) {
- if (s === this.__ownerID) return this;
- var o = this._map.__ensureOwner(s);
- return s ? this.__make(o, s) : ((this.__ownerID = s), (this._map = o), this);
- }),
- (Set.isSet = isSet);
- var nt,
- st = '@@__IMMUTABLE_SET__@@',
- ot = Set.prototype;
- function updateSet(s, o) {
- return s.__ownerID
- ? ((s.size = o.size), (s._map = o), s)
- : o === s._map
- ? s
- : 0 === o.size
- ? s.__empty()
- : s.__make(o);
- }
- function makeSet(s, o) {
- var i = Object.create(ot);
- return (i.size = s ? s.size : 0), (i._map = s), (i.__ownerID = o), i;
- }
- function emptySet() {
- return nt || (nt = makeSet(emptyMap()));
- }
- function OrderedSet(s) {
- return null == s
- ? emptyOrderedSet()
- : isOrderedSet(s)
- ? s
- : emptyOrderedSet().withMutations(function (o) {
- var i = SetIterable(s);
- assertNotInfinite(i.size),
- i.forEach(function (s) {
- return o.add(s);
- });
- });
- }
- function isOrderedSet(s) {
- return isSet(s) && isOrdered(s);
- }
- (ot[st] = !0),
- (ot[w] = ot.remove),
- (ot.mergeDeep = ot.merge),
- (ot.mergeDeepWith = ot.mergeWith),
- (ot.withMutations = $e.withMutations),
- (ot.asMutable = $e.asMutable),
- (ot.asImmutable = $e.asImmutable),
- (ot.__empty = emptySet),
- (ot.__make = makeSet),
- createClass(OrderedSet, Set),
- (OrderedSet.of = function () {
- return this(arguments);
- }),
- (OrderedSet.fromKeys = function (s) {
- return this(KeyedIterable(s).keySeq());
- }),
- (OrderedSet.prototype.toString = function () {
- return this.__toString('OrderedSet {', '}');
- }),
- (OrderedSet.isOrderedSet = isOrderedSet);
- var it,
- at = OrderedSet.prototype;
- function makeOrderedSet(s, o) {
- var i = Object.create(at);
- return (i.size = s ? s.size : 0), (i._map = s), (i.__ownerID = o), i;
- }
- function emptyOrderedSet() {
- return it || (it = makeOrderedSet(emptyOrderedMap()));
- }
- function Stack(s) {
- return null == s ? emptyStack() : isStack(s) ? s : emptyStack().unshiftAll(s);
- }
- function isStack(s) {
- return !(!s || !s[ct]);
- }
- (at[_] = !0),
- (at.__empty = emptyOrderedSet),
- (at.__make = makeOrderedSet),
- createClass(Stack, IndexedCollection),
- (Stack.of = function () {
- return this(arguments);
- }),
- (Stack.prototype.toString = function () {
- return this.__toString('Stack [', ']');
- }),
- (Stack.prototype.get = function (s, o) {
- var i = this._head;
- for (s = wrapIndex(this, s); i && s--; ) i = i.next;
- return i ? i.value : o;
- }),
- (Stack.prototype.peek = function () {
- return this._head && this._head.value;
- }),
- (Stack.prototype.push = function () {
- if (0 === arguments.length) return this;
- for (
- var s = this.size + arguments.length, o = this._head, i = arguments.length - 1;
- i >= 0;
- i--
- )
- o = { value: arguments[i], next: o };
- return this.__ownerID
- ? ((this.size = s),
- (this._head = o),
- (this.__hash = void 0),
- (this.__altered = !0),
- this)
- : makeStack(s, o);
- }),
- (Stack.prototype.pushAll = function (s) {
- if (0 === (s = IndexedIterable(s)).size) return this;
- assertNotInfinite(s.size);
- var o = this.size,
- i = this._head;
- return (
- s.reverse().forEach(function (s) {
- o++, (i = { value: s, next: i });
- }),
- this.__ownerID
- ? ((this.size = o),
- (this._head = i),
- (this.__hash = void 0),
- (this.__altered = !0),
- this)
- : makeStack(o, i)
- );
- }),
- (Stack.prototype.pop = function () {
- return this.slice(1);
- }),
- (Stack.prototype.unshift = function () {
- return this.push.apply(this, arguments);
- }),
- (Stack.prototype.unshiftAll = function (s) {
- return this.pushAll(s);
- }),
- (Stack.prototype.shift = function () {
- return this.pop.apply(this, arguments);
- }),
- (Stack.prototype.clear = function () {
- return 0 === this.size
- ? this
- : this.__ownerID
- ? ((this.size = 0),
- (this._head = void 0),
- (this.__hash = void 0),
- (this.__altered = !0),
- this)
- : emptyStack();
- }),
- (Stack.prototype.slice = function (s, o) {
- if (wholeSlice(s, o, this.size)) return this;
- var i = resolveBegin(s, this.size);
- if (resolveEnd(o, this.size) !== this.size)
- return IndexedCollection.prototype.slice.call(this, s, o);
- for (var u = this.size - i, _ = this._head; i--; ) _ = _.next;
- return this.__ownerID
- ? ((this.size = u),
- (this._head = _),
- (this.__hash = void 0),
- (this.__altered = !0),
- this)
- : makeStack(u, _);
- }),
- (Stack.prototype.__ensureOwner = function (s) {
- return s === this.__ownerID
- ? this
- : s
- ? makeStack(this.size, this._head, s, this.__hash)
- : ((this.__ownerID = s), (this.__altered = !1), this);
- }),
- (Stack.prototype.__iterate = function (s, o) {
- if (o) return this.reverse().__iterate(s);
- for (var i = 0, u = this._head; u && !1 !== s(u.value, i++, this); ) u = u.next;
- return i;
- }),
- (Stack.prototype.__iterator = function (s, o) {
- if (o) return this.reverse().__iterator(s);
- var i = 0,
- u = this._head;
- return new Iterator(function () {
- if (u) {
- var o = u.value;
- return (u = u.next), iteratorValue(s, i++, o);
- }
- return iteratorDone();
- });
- }),
- (Stack.isStack = isStack);
- var lt,
- ct = '@@__IMMUTABLE_STACK__@@',
- ut = Stack.prototype;
- function makeStack(s, o, i, u) {
- var _ = Object.create(ut);
- return (
- (_.size = s),
- (_._head = o),
- (_.__ownerID = i),
- (_.__hash = u),
- (_.__altered = !1),
- _
- );
- }
- function emptyStack() {
- return lt || (lt = makeStack(0));
- }
- function mixin(s, o) {
- var keyCopier = function (i) {
- s.prototype[i] = o[i];
- };
- return (
- Object.keys(o).forEach(keyCopier),
- Object.getOwnPropertySymbols && Object.getOwnPropertySymbols(o).forEach(keyCopier),
- s
- );
- }
- (ut[ct] = !0),
- (ut.withMutations = $e.withMutations),
- (ut.asMutable = $e.asMutable),
- (ut.asImmutable = $e.asImmutable),
- (ut.wasAltered = $e.wasAltered),
- (Iterable.Iterator = Iterator),
- mixin(Iterable, {
- toArray: function () {
- assertNotInfinite(this.size);
- var s = new Array(this.size || 0);
- return (
- this.valueSeq().__iterate(function (o, i) {
- s[i] = o;
- }),
- s
- );
- },
- toIndexedSeq: function () {
- return new ToIndexedSequence(this);
- },
- toJS: function () {
- return this.toSeq()
- .map(function (s) {
- return s && 'function' == typeof s.toJS ? s.toJS() : s;
- })
- .__toJS();
- },
- toJSON: function () {
- return this.toSeq()
- .map(function (s) {
- return s && 'function' == typeof s.toJSON ? s.toJSON() : s;
- })
- .__toJS();
- },
- toKeyedSeq: function () {
- return new ToKeyedSequence(this, !0);
- },
- toMap: function () {
- return Map(this.toKeyedSeq());
- },
- toObject: function () {
- assertNotInfinite(this.size);
- var s = {};
- return (
- this.__iterate(function (o, i) {
- s[i] = o;
- }),
- s
- );
- },
- toOrderedMap: function () {
- return OrderedMap(this.toKeyedSeq());
- },
- toOrderedSet: function () {
- return OrderedSet(isKeyed(this) ? this.valueSeq() : this);
- },
- toSet: function () {
- return Set(isKeyed(this) ? this.valueSeq() : this);
- },
- toSetSeq: function () {
- return new ToSetSequence(this);
- },
- toSeq: function () {
- return isIndexed(this)
- ? this.toIndexedSeq()
- : isKeyed(this)
- ? this.toKeyedSeq()
- : this.toSetSeq();
- },
- toStack: function () {
- return Stack(isKeyed(this) ? this.valueSeq() : this);
- },
- toList: function () {
- return List(isKeyed(this) ? this.valueSeq() : this);
- },
- toString: function () {
- return '[Iterable]';
- },
- __toString: function (s, o) {
- return 0 === this.size
- ? s + o
- : s + ' ' + this.toSeq().map(this.__toStringMapper).join(', ') + ' ' + o;
- },
- concat: function () {
- return reify(this, concatFactory(this, s.call(arguments, 0)));
- },
- includes: function (s) {
- return this.some(function (o) {
- return is(o, s);
- });
- },
- entries: function () {
- return this.__iterator(z);
- },
- every: function (s, o) {
- assertNotInfinite(this.size);
- var i = !0;
- return (
- this.__iterate(function (u, _, w) {
- if (!s.call(o, u, _, w)) return (i = !1), !1;
- }),
- i
- );
- },
- filter: function (s, o) {
- return reify(this, filterFactory(this, s, o, !0));
- },
- find: function (s, o, i) {
- var u = this.findEntry(s, o);
- return u ? u[1] : i;
- },
- forEach: function (s, o) {
- return assertNotInfinite(this.size), this.__iterate(o ? s.bind(o) : s);
- },
- join: function (s) {
- assertNotInfinite(this.size), (s = void 0 !== s ? '' + s : ',');
- var o = '',
- i = !0;
- return (
- this.__iterate(function (u) {
- i ? (i = !1) : (o += s), (o += null != u ? u.toString() : '');
- }),
- o
- );
- },
- keys: function () {
- return this.__iterator(V);
- },
- map: function (s, o) {
- return reify(this, mapFactory(this, s, o));
- },
- reduce: function (s, o, i) {
- var u, _;
- return (
- assertNotInfinite(this.size),
- arguments.length < 2 ? (_ = !0) : (u = o),
- this.__iterate(function (o, w, x) {
- _ ? ((_ = !1), (u = o)) : (u = s.call(i, u, o, w, x));
- }),
- u
- );
- },
- reduceRight: function (s, o, i) {
- var u = this.toKeyedSeq().reverse();
- return u.reduce.apply(u, arguments);
- },
- reverse: function () {
- return reify(this, reverseFactory(this, !0));
- },
- slice: function (s, o) {
- return reify(this, sliceFactory(this, s, o, !0));
- },
- some: function (s, o) {
- return !this.every(not(s), o);
- },
- sort: function (s) {
- return reify(this, sortFactory(this, s));
- },
- values: function () {
- return this.__iterator(U);
- },
- butLast: function () {
- return this.slice(0, -1);
- },
- isEmpty: function () {
- return void 0 !== this.size
- ? 0 === this.size
- : !this.some(function () {
- return !0;
- });
- },
- count: function (s, o) {
- return ensureSize(s ? this.toSeq().filter(s, o) : this);
- },
- countBy: function (s, o) {
- return countByFactory(this, s, o);
- },
- equals: function (s) {
- return deepEqual(this, s);
- },
- entrySeq: function () {
- var s = this;
- if (s._cache) return new ArraySeq(s._cache);
- var o = s.toSeq().map(entryMapper).toIndexedSeq();
- return (
- (o.fromEntrySeq = function () {
- return s.toSeq();
- }),
- o
- );
- },
- filterNot: function (s, o) {
- return this.filter(not(s), o);
- },
- findEntry: function (s, o, i) {
- var u = i;
- return (
- this.__iterate(function (i, _, w) {
- if (s.call(o, i, _, w)) return (u = [_, i]), !1;
- }),
- u
- );
- },
- findKey: function (s, o) {
- var i = this.findEntry(s, o);
- return i && i[0];
- },
- findLast: function (s, o, i) {
- return this.toKeyedSeq().reverse().find(s, o, i);
- },
- findLastEntry: function (s, o, i) {
- return this.toKeyedSeq().reverse().findEntry(s, o, i);
- },
- findLastKey: function (s, o) {
- return this.toKeyedSeq().reverse().findKey(s, o);
- },
- first: function () {
- return this.find(returnTrue);
- },
- flatMap: function (s, o) {
- return reify(this, flatMapFactory(this, s, o));
- },
- flatten: function (s) {
- return reify(this, flattenFactory(this, s, !0));
- },
- fromEntrySeq: function () {
- return new FromEntriesSequence(this);
- },
- get: function (s, o) {
- return this.find(
- function (o, i) {
- return is(i, s);
- },
- void 0,
- o
- );
- },
- getIn: function (s, o) {
- for (var i, u = this, _ = forceIterator(s); !(i = _.next()).done; ) {
- var w = i.value;
- if ((u = u && u.get ? u.get(w, L) : L) === L) return o;
- }
- return u;
- },
- groupBy: function (s, o) {
- return groupByFactory(this, s, o);
- },
- has: function (s) {
- return this.get(s, L) !== L;
- },
- hasIn: function (s) {
- return this.getIn(s, L) !== L;
- },
- isSubset: function (s) {
- return (
- (s = 'function' == typeof s.includes ? s : Iterable(s)),
- this.every(function (o) {
- return s.includes(o);
- })
- );
- },
- isSuperset: function (s) {
- return (s = 'function' == typeof s.isSubset ? s : Iterable(s)).isSubset(this);
- },
- keyOf: function (s) {
- return this.findKey(function (o) {
- return is(o, s);
- });
- },
- keySeq: function () {
- return this.toSeq().map(keyMapper).toIndexedSeq();
- },
- last: function () {
- return this.toSeq().reverse().first();
- },
- lastKeyOf: function (s) {
- return this.toKeyedSeq().reverse().keyOf(s);
- },
- max: function (s) {
- return maxFactory(this, s);
- },
- maxBy: function (s, o) {
- return maxFactory(this, o, s);
- },
- min: function (s) {
- return maxFactory(this, s ? neg(s) : defaultNegComparator);
- },
- minBy: function (s, o) {
- return maxFactory(this, o ? neg(o) : defaultNegComparator, s);
- },
- rest: function () {
- return this.slice(1);
- },
- skip: function (s) {
- return this.slice(Math.max(0, s));
- },
- skipLast: function (s) {
- return reify(this, this.toSeq().reverse().skip(s).reverse());
- },
- skipWhile: function (s, o) {
- return reify(this, skipWhileFactory(this, s, o, !0));
- },
- skipUntil: function (s, o) {
- return this.skipWhile(not(s), o);
- },
- sortBy: function (s, o) {
- return reify(this, sortFactory(this, o, s));
- },
- take: function (s) {
- return this.slice(0, Math.max(0, s));
- },
- takeLast: function (s) {
- return reify(this, this.toSeq().reverse().take(s).reverse());
- },
- takeWhile: function (s, o) {
- return reify(this, takeWhileFactory(this, s, o));
- },
- takeUntil: function (s, o) {
- return this.takeWhile(not(s), o);
- },
- valueSeq: function () {
- return this.toIndexedSeq();
- },
- hashCode: function () {
- return this.__hash || (this.__hash = hashIterable(this));
- }
- });
- var pt = Iterable.prototype;
- (pt[o] = !0),
- (pt[ee] = pt.values),
- (pt.__toJS = pt.toArray),
- (pt.__toStringMapper = quoteString),
- (pt.inspect = pt.toSource =
- function () {
- return this.toString();
- }),
- (pt.chain = pt.flatMap),
- (pt.contains = pt.includes),
- mixin(KeyedIterable, {
- flip: function () {
- return reify(this, flipFactory(this));
- },
- mapEntries: function (s, o) {
- var i = this,
- u = 0;
- return reify(
- this,
- this.toSeq()
- .map(function (_, w) {
- return s.call(o, [w, _], u++, i);
- })
- .fromEntrySeq()
- );
- },
- mapKeys: function (s, o) {
- var i = this;
- return reify(
- this,
- this.toSeq()
- .flip()
- .map(function (u, _) {
- return s.call(o, u, _, i);
- })
- .flip()
- );
- }
- });
- var ht = KeyedIterable.prototype;
- function keyMapper(s, o) {
- return o;
- }
- function entryMapper(s, o) {
- return [o, s];
- }
- function not(s) {
- return function () {
- return !s.apply(this, arguments);
- };
- }
- function neg(s) {
- return function () {
- return -s.apply(this, arguments);
- };
- }
- function quoteString(s) {
- return 'string' == typeof s ? JSON.stringify(s) : String(s);
- }
- function defaultZipper() {
- return arrCopy(arguments);
- }
- function defaultNegComparator(s, o) {
- return s < o ? 1 : s > o ? -1 : 0;
- }
- function hashIterable(s) {
- if (s.size === 1 / 0) return 0;
- var o = isOrdered(s),
- i = isKeyed(s),
- u = o ? 1 : 0;
- return murmurHashOfSize(
- s.__iterate(
- i
- ? o
- ? function (s, o) {
- u = (31 * u + hashMerge(hash(s), hash(o))) | 0;
- }
- : function (s, o) {
- u = (u + hashMerge(hash(s), hash(o))) | 0;
- }
- : o
- ? function (s) {
- u = (31 * u + hash(s)) | 0;
- }
- : function (s) {
- u = (u + hash(s)) | 0;
- }
- ),
- u
- );
- }
- function murmurHashOfSize(s, o) {
- return (
- (o = pe(o, 3432918353)),
- (o = pe((o << 15) | (o >>> -15), 461845907)),
- (o = pe((o << 13) | (o >>> -13), 5)),
- (o = pe((o = (o + 3864292196) ^ s) ^ (o >>> 16), 2246822507)),
- (o = smi((o = pe(o ^ (o >>> 13), 3266489909)) ^ (o >>> 16)))
- );
- }
- function hashMerge(s, o) {
- return s ^ (o + 2654435769 + (s << 6) + (s >> 2));
- }
- return (
- (ht[i] = !0),
- (ht[ee] = pt.entries),
- (ht.__toJS = pt.toObject),
- (ht.__toStringMapper = function (s, o) {
- return JSON.stringify(o) + ': ' + quoteString(s);
- }),
- mixin(IndexedIterable, {
- toKeyedSeq: function () {
- return new ToKeyedSequence(this, !1);
- },
- filter: function (s, o) {
- return reify(this, filterFactory(this, s, o, !1));
- },
- findIndex: function (s, o) {
- var i = this.findEntry(s, o);
- return i ? i[0] : -1;
- },
- indexOf: function (s) {
- var o = this.keyOf(s);
- return void 0 === o ? -1 : o;
- },
- lastIndexOf: function (s) {
- var o = this.lastKeyOf(s);
- return void 0 === o ? -1 : o;
- },
- reverse: function () {
- return reify(this, reverseFactory(this, !1));
- },
- slice: function (s, o) {
- return reify(this, sliceFactory(this, s, o, !1));
- },
- splice: function (s, o) {
- var i = arguments.length;
- if (((o = Math.max(0 | o, 0)), 0 === i || (2 === i && !o))) return this;
- s = resolveBegin(s, s < 0 ? this.count() : this.size);
- var u = this.slice(0, s);
- return reify(
- this,
- 1 === i ? u : u.concat(arrCopy(arguments, 2), this.slice(s + o))
- );
- },
- findLastIndex: function (s, o) {
- var i = this.findLastEntry(s, o);
- return i ? i[0] : -1;
- },
- first: function () {
- return this.get(0);
- },
- flatten: function (s) {
- return reify(this, flattenFactory(this, s, !1));
- },
- get: function (s, o) {
- return (s = wrapIndex(this, s)) < 0 ||
- this.size === 1 / 0 ||
- (void 0 !== this.size && s > this.size)
- ? o
- : this.find(
- function (o, i) {
- return i === s;
- },
- void 0,
- o
- );
- },
- has: function (s) {
- return (
- (s = wrapIndex(this, s)) >= 0 &&
- (void 0 !== this.size
- ? this.size === 1 / 0 || s < this.size
- : -1 !== this.indexOf(s))
- );
- },
- interpose: function (s) {
- return reify(this, interposeFactory(this, s));
- },
- interleave: function () {
- var s = [this].concat(arrCopy(arguments)),
- o = zipWithFactory(this.toSeq(), IndexedSeq.of, s),
- i = o.flatten(!0);
- return o.size && (i.size = o.size * s.length), reify(this, i);
- },
- keySeq: function () {
- return Range(0, this.size);
- },
- last: function () {
- return this.get(-1);
- },
- skipWhile: function (s, o) {
- return reify(this, skipWhileFactory(this, s, o, !1));
- },
- zip: function () {
- return reify(
- this,
- zipWithFactory(this, defaultZipper, [this].concat(arrCopy(arguments)))
- );
- },
- zipWith: function (s) {
- var o = arrCopy(arguments);
- return (o[0] = this), reify(this, zipWithFactory(this, s, o));
- }
- }),
- (IndexedIterable.prototype[u] = !0),
- (IndexedIterable.prototype[_] = !0),
- mixin(SetIterable, {
- get: function (s, o) {
- return this.has(s) ? s : o;
- },
- includes: function (s) {
- return this.has(s);
- },
- keySeq: function () {
- return this.valueSeq();
- }
- }),
- (SetIterable.prototype.has = pt.includes),
- (SetIterable.prototype.contains = SetIterable.prototype.includes),
- mixin(KeyedSeq, KeyedIterable.prototype),
- mixin(IndexedSeq, IndexedIterable.prototype),
- mixin(SetSeq, SetIterable.prototype),
- mixin(KeyedCollection, KeyedIterable.prototype),
- mixin(IndexedCollection, IndexedIterable.prototype),
- mixin(SetCollection, SetIterable.prototype),
- {
- Iterable,
- Seq,
- Collection,
- Map,
- OrderedMap,
- List,
- Stack,
- Set,
- OrderedSet,
- Record,
- Range,
- Repeat,
- is,
- fromJS
- }
- );
- })();
- },
- 56698: (s) => {
- 'function' == typeof Object.create
- ? (s.exports = function inherits(s, o) {
- o &&
- ((s.super_ = o),
- (s.prototype = Object.create(o.prototype, {
- constructor: { value: s, enumerable: !1, writable: !0, configurable: !0 }
- })));
- })
- : (s.exports = function inherits(s, o) {
- if (o) {
- s.super_ = o;
- var TempCtor = function () {};
- (TempCtor.prototype = o.prototype),
- (s.prototype = new TempCtor()),
- (s.prototype.constructor = s);
- }
- });
- },
- 5419: (s) => {
- s.exports = function (s, o, i, u) {
- var _ = new Blob(void 0 !== u ? [u, s] : [s], {
- type: i || 'application/octet-stream'
- });
- if (void 0 !== window.navigator.msSaveBlob) window.navigator.msSaveBlob(_, o);
- else {
- var w =
- window.URL && window.URL.createObjectURL
- ? window.URL.createObjectURL(_)
- : window.webkitURL.createObjectURL(_),
- x = document.createElement('a');
- (x.style.display = 'none'),
- (x.href = w),
- x.setAttribute('download', o),
- void 0 === x.download && x.setAttribute('target', '_blank'),
- document.body.appendChild(x),
- x.click(),
- setTimeout(function () {
- document.body.removeChild(x), window.URL.revokeObjectURL(w);
- }, 200);
- }
- };
- },
- 20181: (s, o, i) => {
- var u = /^\s+|\s+$/g,
- _ = /^[-+]0x[0-9a-f]+$/i,
- w = /^0b[01]+$/i,
- x = /^0o[0-7]+$/i,
- C = parseInt,
- j = 'object' == typeof i.g && i.g && i.g.Object === Object && i.g,
- L = 'object' == typeof self && self && self.Object === Object && self,
- B = j || L || Function('return this')(),
- $ = Object.prototype.toString,
- V = Math.max,
- U = Math.min,
- now = function () {
- return B.Date.now();
- };
- function isObject(s) {
- var o = typeof s;
- return !!s && ('object' == o || 'function' == o);
- }
- function toNumber(s) {
- if ('number' == typeof s) return s;
- if (
- (function isSymbol(s) {
- return (
- 'symbol' == typeof s ||
- ((function isObjectLike(s) {
- return !!s && 'object' == typeof s;
- })(s) &&
- '[object Symbol]' == $.call(s))
- );
- })(s)
- )
- return NaN;
- if (isObject(s)) {
- var o = 'function' == typeof s.valueOf ? s.valueOf() : s;
- s = isObject(o) ? o + '' : o;
- }
- if ('string' != typeof s) return 0 === s ? s : +s;
- s = s.replace(u, '');
- var i = w.test(s);
- return i || x.test(s) ? C(s.slice(2), i ? 2 : 8) : _.test(s) ? NaN : +s;
- }
- s.exports = function debounce(s, o, i) {
- var u,
- _,
- w,
- x,
- C,
- j,
- L = 0,
- B = !1,
- $ = !1,
- z = !0;
- if ('function' != typeof s) throw new TypeError('Expected a function');
- function invokeFunc(o) {
- var i = u,
- w = _;
- return (u = _ = void 0), (L = o), (x = s.apply(w, i));
- }
- function shouldInvoke(s) {
- var i = s - j;
- return void 0 === j || i >= o || i < 0 || ($ && s - L >= w);
- }
- function timerExpired() {
- var s = now();
- if (shouldInvoke(s)) return trailingEdge(s);
- C = setTimeout(
- timerExpired,
- (function remainingWait(s) {
- var i = o - (s - j);
- return $ ? U(i, w - (s - L)) : i;
- })(s)
- );
- }
- function trailingEdge(s) {
- return (C = void 0), z && u ? invokeFunc(s) : ((u = _ = void 0), x);
- }
- function debounced() {
- var s = now(),
- i = shouldInvoke(s);
- if (((u = arguments), (_ = this), (j = s), i)) {
- if (void 0 === C)
- return (function leadingEdge(s) {
- return (L = s), (C = setTimeout(timerExpired, o)), B ? invokeFunc(s) : x;
- })(j);
- if ($) return (C = setTimeout(timerExpired, o)), invokeFunc(j);
- }
- return void 0 === C && (C = setTimeout(timerExpired, o)), x;
- }
- return (
- (o = toNumber(o) || 0),
- isObject(i) &&
- ((B = !!i.leading),
- (w = ($ = 'maxWait' in i) ? V(toNumber(i.maxWait) || 0, o) : w),
- (z = 'trailing' in i ? !!i.trailing : z)),
- (debounced.cancel = function cancel() {
- void 0 !== C && clearTimeout(C), (L = 0), (u = j = _ = C = void 0);
- }),
- (debounced.flush = function flush() {
- return void 0 === C ? x : trailingEdge(now());
- }),
- debounced
- );
- };
- },
- 55580: (s, o, i) => {
- var u = i(56110)(i(9325), 'DataView');
- s.exports = u;
- },
- 21549: (s, o, i) => {
- var u = i(22032),
- _ = i(63862),
- w = i(66721),
- x = i(12749),
- C = i(35749);
- function Hash(s) {
- var o = -1,
- i = null == s ? 0 : s.length;
- for (this.clear(); ++o < i; ) {
- var u = s[o];
- this.set(u[0], u[1]);
- }
- }
- (Hash.prototype.clear = u),
- (Hash.prototype.delete = _),
- (Hash.prototype.get = w),
- (Hash.prototype.has = x),
- (Hash.prototype.set = C),
- (s.exports = Hash);
- },
- 30980: (s, o, i) => {
- var u = i(39344),
- _ = i(94033);
- function LazyWrapper(s) {
- (this.__wrapped__ = s),
- (this.__actions__ = []),
- (this.__dir__ = 1),
- (this.__filtered__ = !1),
- (this.__iteratees__ = []),
- (this.__takeCount__ = 4294967295),
- (this.__views__ = []);
- }
- (LazyWrapper.prototype = u(_.prototype)),
- (LazyWrapper.prototype.constructor = LazyWrapper),
- (s.exports = LazyWrapper);
- },
- 80079: (s, o, i) => {
- var u = i(63702),
- _ = i(70080),
- w = i(24739),
- x = i(48655),
- C = i(31175);
- function ListCache(s) {
- var o = -1,
- i = null == s ? 0 : s.length;
- for (this.clear(); ++o < i; ) {
- var u = s[o];
- this.set(u[0], u[1]);
- }
- }
- (ListCache.prototype.clear = u),
- (ListCache.prototype.delete = _),
- (ListCache.prototype.get = w),
- (ListCache.prototype.has = x),
- (ListCache.prototype.set = C),
- (s.exports = ListCache);
- },
- 56017: (s, o, i) => {
- var u = i(39344),
- _ = i(94033);
- function LodashWrapper(s, o) {
- (this.__wrapped__ = s),
- (this.__actions__ = []),
- (this.__chain__ = !!o),
- (this.__index__ = 0),
- (this.__values__ = void 0);
- }
- (LodashWrapper.prototype = u(_.prototype)),
- (LodashWrapper.prototype.constructor = LodashWrapper),
- (s.exports = LodashWrapper);
- },
- 68223: (s, o, i) => {
- var u = i(56110)(i(9325), 'Map');
- s.exports = u;
- },
- 53661: (s, o, i) => {
- var u = i(63040),
- _ = i(17670),
- w = i(90289),
- x = i(4509),
- C = i(72949);
- function MapCache(s) {
- var o = -1,
- i = null == s ? 0 : s.length;
- for (this.clear(); ++o < i; ) {
- var u = s[o];
- this.set(u[0], u[1]);
- }
- }
- (MapCache.prototype.clear = u),
- (MapCache.prototype.delete = _),
- (MapCache.prototype.get = w),
- (MapCache.prototype.has = x),
- (MapCache.prototype.set = C),
- (s.exports = MapCache);
- },
- 32804: (s, o, i) => {
- var u = i(56110)(i(9325), 'Promise');
- s.exports = u;
- },
- 76545: (s, o, i) => {
- var u = i(56110)(i(9325), 'Set');
- s.exports = u;
- },
- 38859: (s, o, i) => {
- var u = i(53661),
- _ = i(31380),
- w = i(51459);
- function SetCache(s) {
- var o = -1,
- i = null == s ? 0 : s.length;
- for (this.__data__ = new u(); ++o < i; ) this.add(s[o]);
- }
- (SetCache.prototype.add = SetCache.prototype.push = _),
- (SetCache.prototype.has = w),
- (s.exports = SetCache);
- },
- 37217: (s, o, i) => {
- var u = i(80079),
- _ = i(51420),
- w = i(90938),
- x = i(63605),
- C = i(29817),
- j = i(80945);
- function Stack(s) {
- var o = (this.__data__ = new u(s));
- this.size = o.size;
- }
- (Stack.prototype.clear = _),
- (Stack.prototype.delete = w),
- (Stack.prototype.get = x),
- (Stack.prototype.has = C),
- (Stack.prototype.set = j),
- (s.exports = Stack);
- },
- 51873: (s, o, i) => {
- var u = i(9325).Symbol;
- s.exports = u;
- },
- 37828: (s, o, i) => {
- var u = i(9325).Uint8Array;
- s.exports = u;
- },
- 28303: (s, o, i) => {
- var u = i(56110)(i(9325), 'WeakMap');
- s.exports = u;
- },
- 91033: (s) => {
- s.exports = function apply(s, o, i) {
- switch (i.length) {
- case 0:
- return s.call(o);
- case 1:
- return s.call(o, i[0]);
- case 2:
- return s.call(o, i[0], i[1]);
- case 3:
- return s.call(o, i[0], i[1], i[2]);
- }
- return s.apply(o, i);
- };
- },
- 83729: (s) => {
- s.exports = function arrayEach(s, o) {
- for (var i = -1, u = null == s ? 0 : s.length; ++i < u && !1 !== o(s[i], i, s); );
- return s;
- };
- },
- 79770: (s) => {
- s.exports = function arrayFilter(s, o) {
- for (var i = -1, u = null == s ? 0 : s.length, _ = 0, w = []; ++i < u; ) {
- var x = s[i];
- o(x, i, s) && (w[_++] = x);
- }
- return w;
- };
- },
- 15325: (s, o, i) => {
- var u = i(96131);
- s.exports = function arrayIncludes(s, o) {
- return !!(null == s ? 0 : s.length) && u(s, o, 0) > -1;
- };
- },
- 70695: (s, o, i) => {
- var u = i(78096),
- _ = i(72428),
- w = i(56449),
- x = i(3656),
- C = i(30361),
- j = i(37167),
- L = Object.prototype.hasOwnProperty;
- s.exports = function arrayLikeKeys(s, o) {
- var i = w(s),
- B = !i && _(s),
- $ = !i && !B && x(s),
- V = !i && !B && !$ && j(s),
- U = i || B || $ || V,
- z = U ? u(s.length, String) : [],
- Y = z.length;
- for (var Z in s)
- (!o && !L.call(s, Z)) ||
- (U &&
- ('length' == Z ||
- ($ && ('offset' == Z || 'parent' == Z)) ||
- (V && ('buffer' == Z || 'byteLength' == Z || 'byteOffset' == Z)) ||
- C(Z, Y))) ||
- z.push(Z);
- return z;
- };
- },
- 34932: (s) => {
- s.exports = function arrayMap(s, o) {
- for (var i = -1, u = null == s ? 0 : s.length, _ = Array(u); ++i < u; )
- _[i] = o(s[i], i, s);
- return _;
- };
- },
- 14528: (s) => {
- s.exports = function arrayPush(s, o) {
- for (var i = -1, u = o.length, _ = s.length; ++i < u; ) s[_ + i] = o[i];
- return s;
- };
- },
- 40882: (s) => {
- s.exports = function arrayReduce(s, o, i, u) {
- var _ = -1,
- w = null == s ? 0 : s.length;
- for (u && w && (i = s[++_]); ++_ < w; ) i = o(i, s[_], _, s);
- return i;
- };
- },
- 14248: (s) => {
- s.exports = function arraySome(s, o) {
- for (var i = -1, u = null == s ? 0 : s.length; ++i < u; ) if (o(s[i], i, s)) return !0;
- return !1;
- };
- },
- 61074: (s) => {
- s.exports = function asciiToArray(s) {
- return s.split('');
- };
- },
- 1733: (s) => {
- var o = /[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;
- s.exports = function asciiWords(s) {
- return s.match(o) || [];
- };
- },
- 87805: (s, o, i) => {
- var u = i(43360),
- _ = i(75288);
- s.exports = function assignMergeValue(s, o, i) {
- ((void 0 !== i && !_(s[o], i)) || (void 0 === i && !(o in s))) && u(s, o, i);
- };
- },
- 16547: (s, o, i) => {
- var u = i(43360),
- _ = i(75288),
- w = Object.prototype.hasOwnProperty;
- s.exports = function assignValue(s, o, i) {
- var x = s[o];
- (w.call(s, o) && _(x, i) && (void 0 !== i || o in s)) || u(s, o, i);
- };
- },
- 26025: (s, o, i) => {
- var u = i(75288);
- s.exports = function assocIndexOf(s, o) {
- for (var i = s.length; i--; ) if (u(s[i][0], o)) return i;
- return -1;
- };
- },
- 74733: (s, o, i) => {
- var u = i(21791),
- _ = i(95950);
- s.exports = function baseAssign(s, o) {
- return s && u(o, _(o), s);
- };
- },
- 43838: (s, o, i) => {
- var u = i(21791),
- _ = i(37241);
- s.exports = function baseAssignIn(s, o) {
- return s && u(o, _(o), s);
- };
- },
- 43360: (s, o, i) => {
- var u = i(93243);
- s.exports = function baseAssignValue(s, o, i) {
- '__proto__' == o && u
- ? u(s, o, { configurable: !0, enumerable: !0, value: i, writable: !0 })
- : (s[o] = i);
- };
- },
- 9999: (s, o, i) => {
- var u = i(37217),
- _ = i(83729),
- w = i(16547),
- x = i(74733),
- C = i(43838),
- j = i(93290),
- L = i(23007),
- B = i(92271),
- $ = i(48948),
- V = i(50002),
- U = i(83349),
- z = i(5861),
- Y = i(76189),
- Z = i(77199),
- ee = i(35529),
- ie = i(56449),
- ae = i(3656),
- le = i(87730),
- ce = i(23805),
- pe = i(38440),
- de = i(95950),
- fe = i(37241),
- ye = '[object Arguments]',
- be = '[object Function]',
- _e = '[object Object]',
- we = {};
- (we[ye] =
- we['[object Array]'] =
- we['[object ArrayBuffer]'] =
- we['[object DataView]'] =
- we['[object Boolean]'] =
- we['[object Date]'] =
- we['[object Float32Array]'] =
- we['[object Float64Array]'] =
- we['[object Int8Array]'] =
- we['[object Int16Array]'] =
- we['[object Int32Array]'] =
- we['[object Map]'] =
- we['[object Number]'] =
- we[_e] =
- we['[object RegExp]'] =
- we['[object Set]'] =
- we['[object String]'] =
- we['[object Symbol]'] =
- we['[object Uint8Array]'] =
- we['[object Uint8ClampedArray]'] =
- we['[object Uint16Array]'] =
- we['[object Uint32Array]'] =
- !0),
- (we['[object Error]'] = we[be] = we['[object WeakMap]'] = !1),
- (s.exports = function baseClone(s, o, i, Se, xe, Pe) {
- var Te,
- Re = 1 & o,
- qe = 2 & o,
- $e = 4 & o;
- if ((i && (Te = xe ? i(s, Se, xe, Pe) : i(s)), void 0 !== Te)) return Te;
- if (!ce(s)) return s;
- var ze = ie(s);
- if (ze) {
- if (((Te = Y(s)), !Re)) return L(s, Te);
- } else {
- var We = z(s),
- He = We == be || '[object GeneratorFunction]' == We;
- if (ae(s)) return j(s, Re);
- if (We == _e || We == ye || (He && !xe)) {
- if (((Te = qe || He ? {} : ee(s)), !Re))
- return qe ? $(s, C(Te, s)) : B(s, x(Te, s));
- } else {
- if (!we[We]) return xe ? s : {};
- Te = Z(s, We, Re);
- }
- }
- Pe || (Pe = new u());
- var Ye = Pe.get(s);
- if (Ye) return Ye;
- Pe.set(s, Te),
- pe(s)
- ? s.forEach(function (u) {
- Te.add(baseClone(u, o, i, u, s, Pe));
- })
- : le(s) &&
- s.forEach(function (u, _) {
- Te.set(_, baseClone(u, o, i, _, s, Pe));
- });
- var Xe = ze ? void 0 : ($e ? (qe ? U : V) : qe ? fe : de)(s);
- return (
- _(Xe || s, function (u, _) {
- Xe && (u = s[(_ = u)]), w(Te, _, baseClone(u, o, i, _, s, Pe));
- }),
- Te
- );
- });
- },
- 39344: (s, o, i) => {
- var u = i(23805),
- _ = Object.create,
- w = (function () {
- function object() {}
- return function (s) {
- if (!u(s)) return {};
- if (_) return _(s);
- object.prototype = s;
- var o = new object();
- return (object.prototype = void 0), o;
- };
- })();
- s.exports = w;
- },
- 80909: (s, o, i) => {
- var u = i(30641),
- _ = i(38329)(u);
- s.exports = _;
- },
- 2523: (s) => {
- s.exports = function baseFindIndex(s, o, i, u) {
- for (var _ = s.length, w = i + (u ? 1 : -1); u ? w-- : ++w < _; )
- if (o(s[w], w, s)) return w;
- return -1;
- };
- },
- 83120: (s, o, i) => {
- var u = i(14528),
- _ = i(45891);
- s.exports = function baseFlatten(s, o, i, w, x) {
- var C = -1,
- j = s.length;
- for (i || (i = _), x || (x = []); ++C < j; ) {
- var L = s[C];
- o > 0 && i(L)
- ? o > 1
- ? baseFlatten(L, o - 1, i, w, x)
- : u(x, L)
- : w || (x[x.length] = L);
- }
- return x;
- };
- },
- 86649: (s, o, i) => {
- var u = i(83221)();
- s.exports = u;
- },
- 30641: (s, o, i) => {
- var u = i(86649),
- _ = i(95950);
- s.exports = function baseForOwn(s, o) {
- return s && u(s, o, _);
- };
- },
- 47422: (s, o, i) => {
- var u = i(31769),
- _ = i(77797);
- s.exports = function baseGet(s, o) {
- for (var i = 0, w = (o = u(o, s)).length; null != s && i < w; ) s = s[_(o[i++])];
- return i && i == w ? s : void 0;
- };
- },
- 82199: (s, o, i) => {
- var u = i(14528),
- _ = i(56449);
- s.exports = function baseGetAllKeys(s, o, i) {
- var w = o(s);
- return _(s) ? w : u(w, i(s));
- };
- },
- 72552: (s, o, i) => {
- var u = i(51873),
- _ = i(659),
- w = i(59350),
- x = u ? u.toStringTag : void 0;
- s.exports = function baseGetTag(s) {
- return null == s
- ? void 0 === s
- ? '[object Undefined]'
- : '[object Null]'
- : x && x in Object(s)
- ? _(s)
- : w(s);
- };
- },
- 20426: (s) => {
- var o = Object.prototype.hasOwnProperty;
- s.exports = function baseHas(s, i) {
- return null != s && o.call(s, i);
- };
- },
- 28077: (s) => {
- s.exports = function baseHasIn(s, o) {
- return null != s && o in Object(s);
- };
- },
- 96131: (s, o, i) => {
- var u = i(2523),
- _ = i(85463),
- w = i(76959);
- s.exports = function baseIndexOf(s, o, i) {
- return o == o ? w(s, o, i) : u(s, _, i);
- };
- },
- 27534: (s, o, i) => {
- var u = i(72552),
- _ = i(40346);
- s.exports = function baseIsArguments(s) {
- return _(s) && '[object Arguments]' == u(s);
- };
- },
- 60270: (s, o, i) => {
- var u = i(87068),
- _ = i(40346);
- s.exports = function baseIsEqual(s, o, i, w, x) {
- return (
- s === o ||
- (null == s || null == o || (!_(s) && !_(o))
- ? s != s && o != o
- : u(s, o, i, w, baseIsEqual, x))
- );
- };
- },
- 87068: (s, o, i) => {
- var u = i(37217),
- _ = i(25911),
- w = i(21986),
- x = i(50689),
- C = i(5861),
- j = i(56449),
- L = i(3656),
- B = i(37167),
- $ = '[object Arguments]',
- V = '[object Array]',
- U = '[object Object]',
- z = Object.prototype.hasOwnProperty;
- s.exports = function baseIsEqualDeep(s, o, i, Y, Z, ee) {
- var ie = j(s),
- ae = j(o),
- le = ie ? V : C(s),
- ce = ae ? V : C(o),
- pe = (le = le == $ ? U : le) == U,
- de = (ce = ce == $ ? U : ce) == U,
- fe = le == ce;
- if (fe && L(s)) {
- if (!L(o)) return !1;
- (ie = !0), (pe = !1);
- }
- if (fe && !pe)
- return (
- ee || (ee = new u()), ie || B(s) ? _(s, o, i, Y, Z, ee) : w(s, o, le, i, Y, Z, ee)
- );
- if (!(1 & i)) {
- var ye = pe && z.call(s, '__wrapped__'),
- be = de && z.call(o, '__wrapped__');
- if (ye || be) {
- var _e = ye ? s.value() : s,
- we = be ? o.value() : o;
- return ee || (ee = new u()), Z(_e, we, i, Y, ee);
- }
- }
- return !!fe && (ee || (ee = new u()), x(s, o, i, Y, Z, ee));
- };
- },
- 29172: (s, o, i) => {
- var u = i(5861),
- _ = i(40346);
- s.exports = function baseIsMap(s) {
- return _(s) && '[object Map]' == u(s);
- };
- },
- 41799: (s, o, i) => {
- var u = i(37217),
- _ = i(60270);
- s.exports = function baseIsMatch(s, o, i, w) {
- var x = i.length,
- C = x,
- j = !w;
- if (null == s) return !C;
- for (s = Object(s); x--; ) {
- var L = i[x];
- if (j && L[2] ? L[1] !== s[L[0]] : !(L[0] in s)) return !1;
- }
- for (; ++x < C; ) {
- var B = (L = i[x])[0],
- $ = s[B],
- V = L[1];
- if (j && L[2]) {
- if (void 0 === $ && !(B in s)) return !1;
- } else {
- var U = new u();
- if (w) var z = w($, V, B, s, o, U);
- if (!(void 0 === z ? _(V, $, 3, w, U) : z)) return !1;
- }
- }
- return !0;
- };
- },
- 85463: (s) => {
- s.exports = function baseIsNaN(s) {
- return s != s;
- };
- },
- 45083: (s, o, i) => {
- var u = i(1882),
- _ = i(87296),
- w = i(23805),
- x = i(47473),
- C = /^\[object .+?Constructor\]$/,
- j = Function.prototype,
- L = Object.prototype,
- B = j.toString,
- $ = L.hasOwnProperty,
- V = RegExp(
- '^' +
- B.call($)
- .replace(/[\\^$.*+?()[\]{}|]/g, '\\$&')
- .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') +
- '$'
- );
- s.exports = function baseIsNative(s) {
- return !(!w(s) || _(s)) && (u(s) ? V : C).test(x(s));
- };
- },
- 16038: (s, o, i) => {
- var u = i(5861),
- _ = i(40346);
- s.exports = function baseIsSet(s) {
- return _(s) && '[object Set]' == u(s);
- };
- },
- 4901: (s, o, i) => {
- var u = i(72552),
- _ = i(30294),
- w = i(40346),
- x = {};
- (x['[object Float32Array]'] =
- x['[object Float64Array]'] =
- x['[object Int8Array]'] =
- x['[object Int16Array]'] =
- x['[object Int32Array]'] =
- x['[object Uint8Array]'] =
- x['[object Uint8ClampedArray]'] =
- x['[object Uint16Array]'] =
- x['[object Uint32Array]'] =
- !0),
- (x['[object Arguments]'] =
- x['[object Array]'] =
- x['[object ArrayBuffer]'] =
- x['[object Boolean]'] =
- x['[object DataView]'] =
- x['[object Date]'] =
- x['[object Error]'] =
- x['[object Function]'] =
- x['[object Map]'] =
- x['[object Number]'] =
- x['[object Object]'] =
- x['[object RegExp]'] =
- x['[object Set]'] =
- x['[object String]'] =
- x['[object WeakMap]'] =
- !1),
- (s.exports = function baseIsTypedArray(s) {
- return w(s) && _(s.length) && !!x[u(s)];
- });
- },
- 15389: (s, o, i) => {
- var u = i(93663),
- _ = i(87978),
- w = i(83488),
- x = i(56449),
- C = i(50583);
- s.exports = function baseIteratee(s) {
- return 'function' == typeof s
- ? s
- : null == s
- ? w
- : 'object' == typeof s
- ? x(s)
- ? _(s[0], s[1])
- : u(s)
- : C(s);
- };
- },
- 88984: (s, o, i) => {
- var u = i(55527),
- _ = i(3650),
- w = Object.prototype.hasOwnProperty;
- s.exports = function baseKeys(s) {
- if (!u(s)) return _(s);
- var o = [];
- for (var i in Object(s)) w.call(s, i) && 'constructor' != i && o.push(i);
- return o;
- };
- },
- 72903: (s, o, i) => {
- var u = i(23805),
- _ = i(55527),
- w = i(90181),
- x = Object.prototype.hasOwnProperty;
- s.exports = function baseKeysIn(s) {
- if (!u(s)) return w(s);
- var o = _(s),
- i = [];
- for (var C in s) ('constructor' != C || (!o && x.call(s, C))) && i.push(C);
- return i;
- };
- },
- 94033: (s) => {
- s.exports = function baseLodash() {};
- },
- 93663: (s, o, i) => {
- var u = i(41799),
- _ = i(10776),
- w = i(67197);
- s.exports = function baseMatches(s) {
- var o = _(s);
- return 1 == o.length && o[0][2]
- ? w(o[0][0], o[0][1])
- : function (i) {
- return i === s || u(i, s, o);
- };
- };
- },
- 87978: (s, o, i) => {
- var u = i(60270),
- _ = i(58156),
- w = i(80631),
- x = i(28586),
- C = i(30756),
- j = i(67197),
- L = i(77797);
- s.exports = function baseMatchesProperty(s, o) {
- return x(s) && C(o)
- ? j(L(s), o)
- : function (i) {
- var x = _(i, s);
- return void 0 === x && x === o ? w(i, s) : u(o, x, 3);
- };
- };
- },
- 85250: (s, o, i) => {
- var u = i(37217),
- _ = i(87805),
- w = i(86649),
- x = i(42824),
- C = i(23805),
- j = i(37241),
- L = i(14974);
- s.exports = function baseMerge(s, o, i, B, $) {
- s !== o &&
- w(
- o,
- function (w, j) {
- if (($ || ($ = new u()), C(w))) x(s, o, j, i, baseMerge, B, $);
- else {
- var V = B ? B(L(s, j), w, j + '', s, o, $) : void 0;
- void 0 === V && (V = w), _(s, j, V);
- }
- },
- j
- );
- };
- },
- 42824: (s, o, i) => {
- var u = i(87805),
- _ = i(93290),
- w = i(71961),
- x = i(23007),
- C = i(35529),
- j = i(72428),
- L = i(56449),
- B = i(83693),
- $ = i(3656),
- V = i(1882),
- U = i(23805),
- z = i(11331),
- Y = i(37167),
- Z = i(14974),
- ee = i(69884);
- s.exports = function baseMergeDeep(s, o, i, ie, ae, le, ce) {
- var pe = Z(s, i),
- de = Z(o, i),
- fe = ce.get(de);
- if (fe) u(s, i, fe);
- else {
- var ye = le ? le(pe, de, i + '', s, o, ce) : void 0,
- be = void 0 === ye;
- if (be) {
- var _e = L(de),
- we = !_e && $(de),
- Se = !_e && !we && Y(de);
- (ye = de),
- _e || we || Se
- ? L(pe)
- ? (ye = pe)
- : B(pe)
- ? (ye = x(pe))
- : we
- ? ((be = !1), (ye = _(de, !0)))
- : Se
- ? ((be = !1), (ye = w(de, !0)))
- : (ye = [])
- : z(de) || j(de)
- ? ((ye = pe), j(pe) ? (ye = ee(pe)) : (U(pe) && !V(pe)) || (ye = C(de)))
- : (be = !1);
- }
- be && (ce.set(de, ye), ae(ye, de, ie, le, ce), ce.delete(de)), u(s, i, ye);
- }
- };
- },
- 47237: (s) => {
- s.exports = function baseProperty(s) {
- return function (o) {
- return null == o ? void 0 : o[s];
- };
- };
- },
- 17255: (s, o, i) => {
- var u = i(47422);
- s.exports = function basePropertyDeep(s) {
- return function (o) {
- return u(o, s);
- };
- };
- },
- 54552: (s) => {
- s.exports = function basePropertyOf(s) {
- return function (o) {
- return null == s ? void 0 : s[o];
- };
- };
- },
- 85558: (s) => {
- s.exports = function baseReduce(s, o, i, u, _) {
- return (
- _(s, function (s, _, w) {
- i = u ? ((u = !1), s) : o(i, s, _, w);
- }),
- i
- );
- };
- },
- 69302: (s, o, i) => {
- var u = i(83488),
- _ = i(56757),
- w = i(32865);
- s.exports = function baseRest(s, o) {
- return w(_(s, o, u), s + '');
- };
- },
- 73170: (s, o, i) => {
- var u = i(16547),
- _ = i(31769),
- w = i(30361),
- x = i(23805),
- C = i(77797);
- s.exports = function baseSet(s, o, i, j) {
- if (!x(s)) return s;
- for (var L = -1, B = (o = _(o, s)).length, $ = B - 1, V = s; null != V && ++L < B; ) {
- var U = C(o[L]),
- z = i;
- if ('__proto__' === U || 'constructor' === U || 'prototype' === U) return s;
- if (L != $) {
- var Y = V[U];
- void 0 === (z = j ? j(Y, U, V) : void 0) && (z = x(Y) ? Y : w(o[L + 1]) ? [] : {});
- }
- u(V, U, z), (V = V[U]);
- }
- return s;
- };
- },
- 68882: (s, o, i) => {
- var u = i(83488),
- _ = i(48152),
- w = _
- ? function (s, o) {
- return _.set(s, o), s;
- }
- : u;
- s.exports = w;
- },
- 19570: (s, o, i) => {
- var u = i(37334),
- _ = i(93243),
- w = i(83488),
- x = _
- ? function (s, o) {
- return _(s, 'toString', {
- configurable: !0,
- enumerable: !1,
- value: u(o),
- writable: !0
- });
- }
- : w;
- s.exports = x;
- },
- 25160: (s) => {
- s.exports = function baseSlice(s, o, i) {
- var u = -1,
- _ = s.length;
- o < 0 && (o = -o > _ ? 0 : _ + o),
- (i = i > _ ? _ : i) < 0 && (i += _),
- (_ = o > i ? 0 : (i - o) >>> 0),
- (o >>>= 0);
- for (var w = Array(_); ++u < _; ) w[u] = s[u + o];
- return w;
- };
- },
- 90916: (s, o, i) => {
- var u = i(80909);
- s.exports = function baseSome(s, o) {
- var i;
- return (
- u(s, function (s, u, _) {
- return !(i = o(s, u, _));
- }),
- !!i
- );
- };
- },
- 78096: (s) => {
- s.exports = function baseTimes(s, o) {
- for (var i = -1, u = Array(s); ++i < s; ) u[i] = o(i);
- return u;
- };
- },
- 77556: (s, o, i) => {
- var u = i(51873),
- _ = i(34932),
- w = i(56449),
- x = i(44394),
- C = u ? u.prototype : void 0,
- j = C ? C.toString : void 0;
- s.exports = function baseToString(s) {
- if ('string' == typeof s) return s;
- if (w(s)) return _(s, baseToString) + '';
- if (x(s)) return j ? j.call(s) : '';
- var o = s + '';
- return '0' == o && 1 / s == -1 / 0 ? '-0' : o;
- };
- },
- 54128: (s, o, i) => {
- var u = i(31800),
- _ = /^\s+/;
- s.exports = function baseTrim(s) {
- return s ? s.slice(0, u(s) + 1).replace(_, '') : s;
- };
- },
- 27301: (s) => {
- s.exports = function baseUnary(s) {
- return function (o) {
- return s(o);
- };
- };
- },
- 19931: (s, o, i) => {
- var u = i(31769),
- _ = i(68090),
- w = i(68969),
- x = i(77797);
- s.exports = function baseUnset(s, o) {
- return (o = u(o, s)), null == (s = w(s, o)) || delete s[x(_(o))];
- };
- },
- 51234: (s) => {
- s.exports = function baseZipObject(s, o, i) {
- for (var u = -1, _ = s.length, w = o.length, x = {}; ++u < _; ) {
- var C = u < w ? o[u] : void 0;
- i(x, s[u], C);
- }
- return x;
- };
- },
- 19219: (s) => {
- s.exports = function cacheHas(s, o) {
- return s.has(o);
- };
- },
- 31769: (s, o, i) => {
- var u = i(56449),
- _ = i(28586),
- w = i(61802),
- x = i(13222);
- s.exports = function castPath(s, o) {
- return u(s) ? s : _(s, o) ? [s] : w(x(s));
- };
- },
- 28754: (s, o, i) => {
- var u = i(25160);
- s.exports = function castSlice(s, o, i) {
- var _ = s.length;
- return (i = void 0 === i ? _ : i), !o && i >= _ ? s : u(s, o, i);
- };
- },
- 49653: (s, o, i) => {
- var u = i(37828);
- s.exports = function cloneArrayBuffer(s) {
- var o = new s.constructor(s.byteLength);
- return new u(o).set(new u(s)), o;
- };
- },
- 93290: (s, o, i) => {
- s = i.nmd(s);
- var u = i(9325),
- _ = o && !o.nodeType && o,
- w = _ && s && !s.nodeType && s,
- x = w && w.exports === _ ? u.Buffer : void 0,
- C = x ? x.allocUnsafe : void 0;
- s.exports = function cloneBuffer(s, o) {
- if (o) return s.slice();
- var i = s.length,
- u = C ? C(i) : new s.constructor(i);
- return s.copy(u), u;
- };
- },
- 76169: (s, o, i) => {
- var u = i(49653);
- s.exports = function cloneDataView(s, o) {
- var i = o ? u(s.buffer) : s.buffer;
- return new s.constructor(i, s.byteOffset, s.byteLength);
- };
- },
- 73201: (s) => {
- var o = /\w*$/;
- s.exports = function cloneRegExp(s) {
- var i = new s.constructor(s.source, o.exec(s));
- return (i.lastIndex = s.lastIndex), i;
- };
- },
- 93736: (s, o, i) => {
- var u = i(51873),
- _ = u ? u.prototype : void 0,
- w = _ ? _.valueOf : void 0;
- s.exports = function cloneSymbol(s) {
- return w ? Object(w.call(s)) : {};
- };
- },
- 71961: (s, o, i) => {
- var u = i(49653);
- s.exports = function cloneTypedArray(s, o) {
- var i = o ? u(s.buffer) : s.buffer;
- return new s.constructor(i, s.byteOffset, s.length);
- };
- },
- 91596: (s) => {
- var o = Math.max;
- s.exports = function composeArgs(s, i, u, _) {
- for (
- var w = -1,
- x = s.length,
- C = u.length,
- j = -1,
- L = i.length,
- B = o(x - C, 0),
- $ = Array(L + B),
- V = !_;
- ++j < L;
- )
- $[j] = i[j];
- for (; ++w < C; ) (V || w < x) && ($[u[w]] = s[w]);
- for (; B--; ) $[j++] = s[w++];
- return $;
- };
- },
- 53320: (s) => {
- var o = Math.max;
- s.exports = function composeArgsRight(s, i, u, _) {
- for (
- var w = -1,
- x = s.length,
- C = -1,
- j = u.length,
- L = -1,
- B = i.length,
- $ = o(x - j, 0),
- V = Array($ + B),
- U = !_;
- ++w < $;
- )
- V[w] = s[w];
- for (var z = w; ++L < B; ) V[z + L] = i[L];
- for (; ++C < j; ) (U || w < x) && (V[z + u[C]] = s[w++]);
- return V;
- };
- },
- 23007: (s) => {
- s.exports = function copyArray(s, o) {
- var i = -1,
- u = s.length;
- for (o || (o = Array(u)); ++i < u; ) o[i] = s[i];
- return o;
- };
- },
- 21791: (s, o, i) => {
- var u = i(16547),
- _ = i(43360);
- s.exports = function copyObject(s, o, i, w) {
- var x = !i;
- i || (i = {});
- for (var C = -1, j = o.length; ++C < j; ) {
- var L = o[C],
- B = w ? w(i[L], s[L], L, i, s) : void 0;
- void 0 === B && (B = s[L]), x ? _(i, L, B) : u(i, L, B);
- }
- return i;
- };
- },
- 92271: (s, o, i) => {
- var u = i(21791),
- _ = i(4664);
- s.exports = function copySymbols(s, o) {
- return u(s, _(s), o);
- };
- },
- 48948: (s, o, i) => {
- var u = i(21791),
- _ = i(86375);
- s.exports = function copySymbolsIn(s, o) {
- return u(s, _(s), o);
- };
- },
- 55481: (s, o, i) => {
- var u = i(9325)['__core-js_shared__'];
- s.exports = u;
- },
- 58523: (s) => {
- s.exports = function countHolders(s, o) {
- for (var i = s.length, u = 0; i--; ) s[i] === o && ++u;
- return u;
- };
- },
- 20999: (s, o, i) => {
- var u = i(69302),
- _ = i(36800);
- s.exports = function createAssigner(s) {
- return u(function (o, i) {
- var u = -1,
- w = i.length,
- x = w > 1 ? i[w - 1] : void 0,
- C = w > 2 ? i[2] : void 0;
- for (
- x = s.length > 3 && 'function' == typeof x ? (w--, x) : void 0,
- C && _(i[0], i[1], C) && ((x = w < 3 ? void 0 : x), (w = 1)),
- o = Object(o);
- ++u < w;
- ) {
- var j = i[u];
- j && s(o, j, u, x);
- }
- return o;
- });
- };
- },
- 38329: (s, o, i) => {
- var u = i(64894);
- s.exports = function createBaseEach(s, o) {
- return function (i, _) {
- if (null == i) return i;
- if (!u(i)) return s(i, _);
- for (
- var w = i.length, x = o ? w : -1, C = Object(i);
- (o ? x-- : ++x < w) && !1 !== _(C[x], x, C);
- );
- return i;
- };
- };
- },
- 83221: (s) => {
- s.exports = function createBaseFor(s) {
- return function (o, i, u) {
- for (var _ = -1, w = Object(o), x = u(o), C = x.length; C--; ) {
- var j = x[s ? C : ++_];
- if (!1 === i(w[j], j, w)) break;
- }
- return o;
- };
- };
- },
- 11842: (s, o, i) => {
- var u = i(82819),
- _ = i(9325);
- s.exports = function createBind(s, o, i) {
- var w = 1 & o,
- x = u(s);
- return function wrapper() {
- return (this && this !== _ && this instanceof wrapper ? x : s).apply(
- w ? i : this,
- arguments
- );
- };
- };
- },
- 12507: (s, o, i) => {
- var u = i(28754),
- _ = i(49698),
- w = i(63912),
- x = i(13222);
- s.exports = function createCaseFirst(s) {
- return function (o) {
- o = x(o);
- var i = _(o) ? w(o) : void 0,
- C = i ? i[0] : o.charAt(0),
- j = i ? u(i, 1).join('') : o.slice(1);
- return C[s]() + j;
- };
- };
- },
- 45539: (s, o, i) => {
- var u = i(40882),
- _ = i(50828),
- w = i(66645),
- x = RegExp("['’]", 'g');
- s.exports = function createCompounder(s) {
- return function (o) {
- return u(w(_(o).replace(x, '')), s, '');
- };
- };
- },
- 82819: (s, o, i) => {
- var u = i(39344),
- _ = i(23805);
- s.exports = function createCtor(s) {
- return function () {
- var o = arguments;
- switch (o.length) {
- case 0:
- return new s();
- case 1:
- return new s(o[0]);
- case 2:
- return new s(o[0], o[1]);
- case 3:
- return new s(o[0], o[1], o[2]);
- case 4:
- return new s(o[0], o[1], o[2], o[3]);
- case 5:
- return new s(o[0], o[1], o[2], o[3], o[4]);
- case 6:
- return new s(o[0], o[1], o[2], o[3], o[4], o[5]);
- case 7:
- return new s(o[0], o[1], o[2], o[3], o[4], o[5], o[6]);
- }
- var i = u(s.prototype),
- w = s.apply(i, o);
- return _(w) ? w : i;
- };
- };
- },
- 77078: (s, o, i) => {
- var u = i(91033),
- _ = i(82819),
- w = i(37471),
- x = i(18073),
- C = i(11287),
- j = i(36306),
- L = i(9325);
- s.exports = function createCurry(s, o, i) {
- var B = _(s);
- return function wrapper() {
- for (var _ = arguments.length, $ = Array(_), V = _, U = C(wrapper); V--; )
- $[V] = arguments[V];
- var z = _ < 3 && $[0] !== U && $[_ - 1] !== U ? [] : j($, U);
- return (_ -= z.length) < i
- ? x(s, o, w, wrapper.placeholder, void 0, $, z, void 0, void 0, i - _)
- : u(this && this !== L && this instanceof wrapper ? B : s, this, $);
- };
- };
- },
- 62006: (s, o, i) => {
- var u = i(15389),
- _ = i(64894),
- w = i(95950);
- s.exports = function createFind(s) {
- return function (o, i, x) {
- var C = Object(o);
- if (!_(o)) {
- var j = u(i, 3);
- (o = w(o)),
- (i = function (s) {
- return j(C[s], s, C);
- });
- }
- var L = s(o, i, x);
- return L > -1 ? C[j ? o[L] : L] : void 0;
- };
- };
- },
- 37471: (s, o, i) => {
- var u = i(91596),
- _ = i(53320),
- w = i(58523),
- x = i(82819),
- C = i(18073),
- j = i(11287),
- L = i(68294),
- B = i(36306),
- $ = i(9325);
- s.exports = function createHybrid(s, o, i, V, U, z, Y, Z, ee, ie) {
- var ae = 128 & o,
- le = 1 & o,
- ce = 2 & o,
- pe = 24 & o,
- de = 512 & o,
- fe = ce ? void 0 : x(s);
- return function wrapper() {
- for (var ye = arguments.length, be = Array(ye), _e = ye; _e--; )
- be[_e] = arguments[_e];
- if (pe)
- var we = j(wrapper),
- Se = w(be, we);
- if (
- (V && (be = u(be, V, U, pe)),
- z && (be = _(be, z, Y, pe)),
- (ye -= Se),
- pe && ye < ie)
- ) {
- var xe = B(be, we);
- return C(s, o, createHybrid, wrapper.placeholder, i, be, xe, Z, ee, ie - ye);
- }
- var Pe = le ? i : this,
- Te = ce ? Pe[s] : s;
- return (
- (ye = be.length),
- Z ? (be = L(be, Z)) : de && ye > 1 && be.reverse(),
- ae && ee < ye && (be.length = ee),
- this && this !== $ && this instanceof wrapper && (Te = fe || x(Te)),
- Te.apply(Pe, be)
- );
- };
- };
- },
- 24168: (s, o, i) => {
- var u = i(91033),
- _ = i(82819),
- w = i(9325);
- s.exports = function createPartial(s, o, i, x) {
- var C = 1 & o,
- j = _(s);
- return function wrapper() {
- for (
- var o = -1,
- _ = arguments.length,
- L = -1,
- B = x.length,
- $ = Array(B + _),
- V = this && this !== w && this instanceof wrapper ? j : s;
- ++L < B;
- )
- $[L] = x[L];
- for (; _--; ) $[L++] = arguments[++o];
- return u(V, C ? i : this, $);
- };
- };
- },
- 18073: (s, o, i) => {
- var u = i(85087),
- _ = i(54641),
- w = i(70981);
- s.exports = function createRecurry(s, o, i, x, C, j, L, B, $, V) {
- var U = 8 & o;
- (o |= U ? 32 : 64), 4 & (o &= ~(U ? 64 : 32)) || (o &= -4);
- var z = [
- s,
- o,
- C,
- U ? j : void 0,
- U ? L : void 0,
- U ? void 0 : j,
- U ? void 0 : L,
- B,
- $,
- V
- ],
- Y = i.apply(void 0, z);
- return u(s) && _(Y, z), (Y.placeholder = x), w(Y, s, o);
- };
- },
- 66977: (s, o, i) => {
- var u = i(68882),
- _ = i(11842),
- w = i(77078),
- x = i(37471),
- C = i(24168),
- j = i(37381),
- L = i(3209),
- B = i(54641),
- $ = i(70981),
- V = i(61489),
- U = Math.max;
- s.exports = function createWrap(s, o, i, z, Y, Z, ee, ie) {
- var ae = 2 & o;
- if (!ae && 'function' != typeof s) throw new TypeError('Expected a function');
- var le = z ? z.length : 0;
- if (
- (le || ((o &= -97), (z = Y = void 0)),
- (ee = void 0 === ee ? ee : U(V(ee), 0)),
- (ie = void 0 === ie ? ie : V(ie)),
- (le -= Y ? Y.length : 0),
- 64 & o)
- ) {
- var ce = z,
- pe = Y;
- z = Y = void 0;
- }
- var de = ae ? void 0 : j(s),
- fe = [s, o, i, z, Y, ce, pe, Z, ee, ie];
- if (
- (de && L(fe, de),
- (s = fe[0]),
- (o = fe[1]),
- (i = fe[2]),
- (z = fe[3]),
- (Y = fe[4]),
- !(ie = fe[9] = void 0 === fe[9] ? (ae ? 0 : s.length) : U(fe[9] - le, 0)) &&
- 24 & o &&
- (o &= -25),
- o && 1 != o)
- )
- ye =
- 8 == o || 16 == o
- ? w(s, o, ie)
- : (32 != o && 33 != o) || Y.length
- ? x.apply(void 0, fe)
- : C(s, o, i, z);
- else var ye = _(s, o, i);
- return $((de ? u : B)(ye, fe), s, o);
- };
- },
- 53138: (s, o, i) => {
- var u = i(11331);
- s.exports = function customOmitClone(s) {
- return u(s) ? void 0 : s;
- };
- },
- 24647: (s, o, i) => {
- var u = i(54552)({
- À: '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'
- });
- s.exports = u;
- },
- 93243: (s, o, i) => {
- var u = i(56110),
- _ = (function () {
- try {
- var s = u(Object, 'defineProperty');
- return s({}, '', {}), s;
- } catch (s) {}
- })();
- s.exports = _;
- },
- 25911: (s, o, i) => {
- var u = i(38859),
- _ = i(14248),
- w = i(19219);
- s.exports = function equalArrays(s, o, i, x, C, j) {
- var L = 1 & i,
- B = s.length,
- $ = o.length;
- if (B != $ && !(L && $ > B)) return !1;
- var V = j.get(s),
- U = j.get(o);
- if (V && U) return V == o && U == s;
- var z = -1,
- Y = !0,
- Z = 2 & i ? new u() : void 0;
- for (j.set(s, o), j.set(o, s); ++z < B; ) {
- var ee = s[z],
- ie = o[z];
- if (x) var ae = L ? x(ie, ee, z, o, s, j) : x(ee, ie, z, s, o, j);
- if (void 0 !== ae) {
- if (ae) continue;
- Y = !1;
- break;
- }
- if (Z) {
- if (
- !_(o, function (s, o) {
- if (!w(Z, o) && (ee === s || C(ee, s, i, x, j))) return Z.push(o);
- })
- ) {
- Y = !1;
- break;
- }
- } else if (ee !== ie && !C(ee, ie, i, x, j)) {
- Y = !1;
- break;
- }
- }
- return j.delete(s), j.delete(o), Y;
- };
- },
- 21986: (s, o, i) => {
- var u = i(51873),
- _ = i(37828),
- w = i(75288),
- x = i(25911),
- C = i(20317),
- j = i(84247),
- L = u ? u.prototype : void 0,
- B = L ? L.valueOf : void 0;
- s.exports = function equalByTag(s, o, i, u, L, $, V) {
- switch (i) {
- case '[object DataView]':
- if (s.byteLength != o.byteLength || s.byteOffset != o.byteOffset) return !1;
- (s = s.buffer), (o = o.buffer);
- case '[object ArrayBuffer]':
- return !(s.byteLength != o.byteLength || !$(new _(s), new _(o)));
- case '[object Boolean]':
- case '[object Date]':
- case '[object Number]':
- return w(+s, +o);
- case '[object Error]':
- return s.name == o.name && s.message == o.message;
- case '[object RegExp]':
- case '[object String]':
- return s == o + '';
- case '[object Map]':
- var U = C;
- case '[object Set]':
- var z = 1 & u;
- if ((U || (U = j), s.size != o.size && !z)) return !1;
- var Y = V.get(s);
- if (Y) return Y == o;
- (u |= 2), V.set(s, o);
- var Z = x(U(s), U(o), u, L, $, V);
- return V.delete(s), Z;
- case '[object Symbol]':
- if (B) return B.call(s) == B.call(o);
- }
- return !1;
- };
- },
- 50689: (s, o, i) => {
- var u = i(50002),
- _ = Object.prototype.hasOwnProperty;
- s.exports = function equalObjects(s, o, i, w, x, C) {
- var j = 1 & i,
- L = u(s),
- B = L.length;
- if (B != u(o).length && !j) return !1;
- for (var $ = B; $--; ) {
- var V = L[$];
- if (!(j ? V in o : _.call(o, V))) return !1;
- }
- var U = C.get(s),
- z = C.get(o);
- if (U && z) return U == o && z == s;
- var Y = !0;
- C.set(s, o), C.set(o, s);
- for (var Z = j; ++$ < B; ) {
- var ee = s[(V = L[$])],
- ie = o[V];
- if (w) var ae = j ? w(ie, ee, V, o, s, C) : w(ee, ie, V, s, o, C);
- if (!(void 0 === ae ? ee === ie || x(ee, ie, i, w, C) : ae)) {
- Y = !1;
- break;
- }
- Z || (Z = 'constructor' == V);
- }
- if (Y && !Z) {
- var le = s.constructor,
- ce = o.constructor;
- le == ce ||
- !('constructor' in s) ||
- !('constructor' in o) ||
- ('function' == typeof le &&
- le instanceof le &&
- 'function' == typeof ce &&
- ce instanceof ce) ||
- (Y = !1);
- }
- return C.delete(s), C.delete(o), Y;
- };
- },
- 38816: (s, o, i) => {
- var u = i(35970),
- _ = i(56757),
- w = i(32865);
- s.exports = function flatRest(s) {
- return w(_(s, void 0, u), s + '');
- };
- },
- 34840: (s, o, i) => {
- var u = 'object' == typeof i.g && i.g && i.g.Object === Object && i.g;
- s.exports = u;
- },
- 50002: (s, o, i) => {
- var u = i(82199),
- _ = i(4664),
- w = i(95950);
- s.exports = function getAllKeys(s) {
- return u(s, w, _);
- };
- },
- 83349: (s, o, i) => {
- var u = i(82199),
- _ = i(86375),
- w = i(37241);
- s.exports = function getAllKeysIn(s) {
- return u(s, w, _);
- };
- },
- 37381: (s, o, i) => {
- var u = i(48152),
- _ = i(63950),
- w = u
- ? function (s) {
- return u.get(s);
- }
- : _;
- s.exports = w;
- },
- 62284: (s, o, i) => {
- var u = i(84629),
- _ = Object.prototype.hasOwnProperty;
- s.exports = function getFuncName(s) {
- for (var o = s.name + '', i = u[o], w = _.call(u, o) ? i.length : 0; w--; ) {
- var x = i[w],
- C = x.func;
- if (null == C || C == s) return x.name;
- }
- return o;
- };
- },
- 11287: (s) => {
- s.exports = function getHolder(s) {
- return s.placeholder;
- };
- },
- 12651: (s, o, i) => {
- var u = i(74218);
- s.exports = function getMapData(s, o) {
- var i = s.__data__;
- return u(o) ? i['string' == typeof o ? 'string' : 'hash'] : i.map;
- };
- },
- 10776: (s, o, i) => {
- var u = i(30756),
- _ = i(95950);
- s.exports = function getMatchData(s) {
- for (var o = _(s), i = o.length; i--; ) {
- var w = o[i],
- x = s[w];
- o[i] = [w, x, u(x)];
- }
- return o;
- };
- },
- 56110: (s, o, i) => {
- var u = i(45083),
- _ = i(10392);
- s.exports = function getNative(s, o) {
- var i = _(s, o);
- return u(i) ? i : void 0;
- };
- },
- 28879: (s, o, i) => {
- var u = i(74335)(Object.getPrototypeOf, Object);
- s.exports = u;
- },
- 659: (s, o, i) => {
- var u = i(51873),
- _ = Object.prototype,
- w = _.hasOwnProperty,
- x = _.toString,
- C = u ? u.toStringTag : void 0;
- s.exports = function getRawTag(s) {
- var o = w.call(s, C),
- i = s[C];
- try {
- s[C] = void 0;
- var u = !0;
- } catch (s) {}
- var _ = x.call(s);
- return u && (o ? (s[C] = i) : delete s[C]), _;
- };
- },
- 4664: (s, o, i) => {
- var u = i(79770),
- _ = i(63345),
- w = Object.prototype.propertyIsEnumerable,
- x = Object.getOwnPropertySymbols,
- C = x
- ? function (s) {
- return null == s
- ? []
- : ((s = Object(s)),
- u(x(s), function (o) {
- return w.call(s, o);
- }));
- }
- : _;
- s.exports = C;
- },
- 86375: (s, o, i) => {
- var u = i(14528),
- _ = i(28879),
- w = i(4664),
- x = i(63345),
- C = Object.getOwnPropertySymbols
- ? function (s) {
- for (var o = []; s; ) u(o, w(s)), (s = _(s));
- return o;
- }
- : x;
- s.exports = C;
- },
- 5861: (s, o, i) => {
- var u = i(55580),
- _ = i(68223),
- w = i(32804),
- x = i(76545),
- C = i(28303),
- j = i(72552),
- L = i(47473),
- B = '[object Map]',
- $ = '[object Promise]',
- V = '[object Set]',
- U = '[object WeakMap]',
- z = '[object DataView]',
- Y = L(u),
- Z = L(_),
- ee = L(w),
- ie = L(x),
- ae = L(C),
- le = j;
- ((u && le(new u(new ArrayBuffer(1))) != z) ||
- (_ && le(new _()) != B) ||
- (w && le(w.resolve()) != $) ||
- (x && le(new x()) != V) ||
- (C && le(new C()) != U)) &&
- (le = function (s) {
- var o = j(s),
- i = '[object Object]' == o ? s.constructor : void 0,
- u = i ? L(i) : '';
- if (u)
- switch (u) {
- case Y:
- return z;
- case Z:
- return B;
- case ee:
- return $;
- case ie:
- return V;
- case ae:
- return U;
- }
- return o;
- }),
- (s.exports = le);
- },
- 10392: (s) => {
- s.exports = function getValue(s, o) {
- return null == s ? void 0 : s[o];
- };
- },
- 75251: (s) => {
- var o = /\{\n\/\* \[wrapped with (.+)\] \*/,
- i = /,? & /;
- s.exports = function getWrapDetails(s) {
- var u = s.match(o);
- return u ? u[1].split(i) : [];
- };
- },
- 49326: (s, o, i) => {
- var u = i(31769),
- _ = i(72428),
- w = i(56449),
- x = i(30361),
- C = i(30294),
- j = i(77797);
- s.exports = function hasPath(s, o, i) {
- for (var L = -1, B = (o = u(o, s)).length, $ = !1; ++L < B; ) {
- var V = j(o[L]);
- if (!($ = null != s && i(s, V))) break;
- s = s[V];
- }
- return $ || ++L != B
- ? $
- : !!(B = null == s ? 0 : s.length) && C(B) && x(V, B) && (w(s) || _(s));
- };
- },
- 49698: (s) => {
- var o = RegExp(
- '[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]'
- );
- s.exports = function hasUnicode(s) {
- return o.test(s);
- };
- },
- 45434: (s) => {
- var o = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;
- s.exports = function hasUnicodeWord(s) {
- return o.test(s);
- };
- },
- 22032: (s, o, i) => {
- var u = i(81042);
- s.exports = function hashClear() {
- (this.__data__ = u ? u(null) : {}), (this.size = 0);
- };
- },
- 63862: (s) => {
- s.exports = function hashDelete(s) {
- var o = this.has(s) && delete this.__data__[s];
- return (this.size -= o ? 1 : 0), o;
- };
- },
- 66721: (s, o, i) => {
- var u = i(81042),
- _ = Object.prototype.hasOwnProperty;
- s.exports = function hashGet(s) {
- var o = this.__data__;
- if (u) {
- var i = o[s];
- return '__lodash_hash_undefined__' === i ? void 0 : i;
- }
- return _.call(o, s) ? o[s] : void 0;
- };
- },
- 12749: (s, o, i) => {
- var u = i(81042),
- _ = Object.prototype.hasOwnProperty;
- s.exports = function hashHas(s) {
- var o = this.__data__;
- return u ? void 0 !== o[s] : _.call(o, s);
- };
- },
- 35749: (s, o, i) => {
- var u = i(81042);
- s.exports = function hashSet(s, o) {
- var i = this.__data__;
- return (
- (this.size += this.has(s) ? 0 : 1),
- (i[s] = u && void 0 === o ? '__lodash_hash_undefined__' : o),
- this
- );
- };
- },
- 76189: (s) => {
- var o = Object.prototype.hasOwnProperty;
- s.exports = function initCloneArray(s) {
- var i = s.length,
- u = new s.constructor(i);
- return (
- i &&
- 'string' == typeof s[0] &&
- o.call(s, 'index') &&
- ((u.index = s.index), (u.input = s.input)),
- u
- );
- };
- },
- 77199: (s, o, i) => {
- var u = i(49653),
- _ = i(76169),
- w = i(73201),
- x = i(93736),
- C = i(71961);
- s.exports = function initCloneByTag(s, o, i) {
- var j = s.constructor;
- switch (o) {
- case '[object ArrayBuffer]':
- return u(s);
- case '[object Boolean]':
- case '[object Date]':
- return new j(+s);
- case '[object DataView]':
- return _(s, i);
- case '[object Float32Array]':
- case '[object Float64Array]':
- case '[object Int8Array]':
- case '[object Int16Array]':
- case '[object Int32Array]':
- case '[object Uint8Array]':
- case '[object Uint8ClampedArray]':
- case '[object Uint16Array]':
- case '[object Uint32Array]':
- return C(s, i);
- case '[object Map]':
- case '[object Set]':
- return new j();
- case '[object Number]':
- case '[object String]':
- return new j(s);
- case '[object RegExp]':
- return w(s);
- case '[object Symbol]':
- return x(s);
- }
- };
- },
- 35529: (s, o, i) => {
- var u = i(39344),
- _ = i(28879),
- w = i(55527);
- s.exports = function initCloneObject(s) {
- return 'function' != typeof s.constructor || w(s) ? {} : u(_(s));
- };
- },
- 62060: (s) => {
- var o = /\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;
- s.exports = function insertWrapDetails(s, i) {
- var u = i.length;
- if (!u) return s;
- var _ = u - 1;
- return (
- (i[_] = (u > 1 ? '& ' : '') + i[_]),
- (i = i.join(u > 2 ? ', ' : ' ')),
- s.replace(o, '{\n/* [wrapped with ' + i + '] */\n')
- );
- };
- },
- 45891: (s, o, i) => {
- var u = i(51873),
- _ = i(72428),
- w = i(56449),
- x = u ? u.isConcatSpreadable : void 0;
- s.exports = function isFlattenable(s) {
- return w(s) || _(s) || !!(x && s && s[x]);
- };
- },
- 30361: (s) => {
- var o = /^(?:0|[1-9]\d*)$/;
- s.exports = function isIndex(s, i) {
- var u = typeof s;
- return (
- !!(i = null == i ? 9007199254740991 : i) &&
- ('number' == u || ('symbol' != u && o.test(s))) &&
- s > -1 &&
- s % 1 == 0 &&
- s < i
- );
- };
- },
- 36800: (s, o, i) => {
- var u = i(75288),
- _ = i(64894),
- w = i(30361),
- x = i(23805);
- s.exports = function isIterateeCall(s, o, i) {
- if (!x(i)) return !1;
- var C = typeof o;
- return (
- !!('number' == C ? _(i) && w(o, i.length) : 'string' == C && o in i) && u(i[o], s)
- );
- };
- },
- 28586: (s, o, i) => {
- var u = i(56449),
- _ = i(44394),
- w = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,
- x = /^\w*$/;
- s.exports = function isKey(s, o) {
- if (u(s)) return !1;
- var i = typeof s;
- return (
- !('number' != i && 'symbol' != i && 'boolean' != i && null != s && !_(s)) ||
- x.test(s) ||
- !w.test(s) ||
- (null != o && s in Object(o))
- );
- };
- },
- 74218: (s) => {
- s.exports = function isKeyable(s) {
- var o = typeof s;
- return 'string' == o || 'number' == o || 'symbol' == o || 'boolean' == o
- ? '__proto__' !== s
- : null === s;
- };
- },
- 85087: (s, o, i) => {
- var u = i(30980),
- _ = i(37381),
- w = i(62284),
- x = i(53758);
- s.exports = function isLaziable(s) {
- var o = w(s),
- i = x[o];
- if ('function' != typeof i || !(o in u.prototype)) return !1;
- if (s === i) return !0;
- var C = _(i);
- return !!C && s === C[0];
- };
- },
- 87296: (s, o, i) => {
- var u,
- _ = i(55481),
- w = (u = /[^.]+$/.exec((_ && _.keys && _.keys.IE_PROTO) || ''))
- ? 'Symbol(src)_1.' + u
- : '';
- s.exports = function isMasked(s) {
- return !!w && w in s;
- };
- },
- 55527: (s) => {
- var o = Object.prototype;
- s.exports = function isPrototype(s) {
- var i = s && s.constructor;
- return s === (('function' == typeof i && i.prototype) || o);
- };
- },
- 30756: (s, o, i) => {
- var u = i(23805);
- s.exports = function isStrictComparable(s) {
- return s == s && !u(s);
- };
- },
- 63702: (s) => {
- s.exports = function listCacheClear() {
- (this.__data__ = []), (this.size = 0);
- };
- },
- 70080: (s, o, i) => {
- var u = i(26025),
- _ = Array.prototype.splice;
- s.exports = function listCacheDelete(s) {
- var o = this.__data__,
- i = u(o, s);
- return !(i < 0) && (i == o.length - 1 ? o.pop() : _.call(o, i, 1), --this.size, !0);
- };
- },
- 24739: (s, o, i) => {
- var u = i(26025);
- s.exports = function listCacheGet(s) {
- var o = this.__data__,
- i = u(o, s);
- return i < 0 ? void 0 : o[i][1];
- };
- },
- 48655: (s, o, i) => {
- var u = i(26025);
- s.exports = function listCacheHas(s) {
- return u(this.__data__, s) > -1;
- };
- },
- 31175: (s, o, i) => {
- var u = i(26025);
- s.exports = function listCacheSet(s, o) {
- var i = this.__data__,
- _ = u(i, s);
- return _ < 0 ? (++this.size, i.push([s, o])) : (i[_][1] = o), this;
- };
- },
- 63040: (s, o, i) => {
- var u = i(21549),
- _ = i(80079),
- w = i(68223);
- s.exports = function mapCacheClear() {
- (this.size = 0),
- (this.__data__ = { hash: new u(), map: new (w || _)(), string: new u() });
- };
- },
- 17670: (s, o, i) => {
- var u = i(12651);
- s.exports = function mapCacheDelete(s) {
- var o = u(this, s).delete(s);
- return (this.size -= o ? 1 : 0), o;
- };
- },
- 90289: (s, o, i) => {
- var u = i(12651);
- s.exports = function mapCacheGet(s) {
- return u(this, s).get(s);
- };
- },
- 4509: (s, o, i) => {
- var u = i(12651);
- s.exports = function mapCacheHas(s) {
- return u(this, s).has(s);
- };
- },
- 72949: (s, o, i) => {
- var u = i(12651);
- s.exports = function mapCacheSet(s, o) {
- var i = u(this, s),
- _ = i.size;
- return i.set(s, o), (this.size += i.size == _ ? 0 : 1), this;
- };
- },
- 20317: (s) => {
- s.exports = function mapToArray(s) {
- var o = -1,
- i = Array(s.size);
- return (
- s.forEach(function (s, u) {
- i[++o] = [u, s];
- }),
- i
- );
- };
- },
- 67197: (s) => {
- s.exports = function matchesStrictComparable(s, o) {
- return function (i) {
- return null != i && i[s] === o && (void 0 !== o || s in Object(i));
- };
- };
- },
- 62224: (s, o, i) => {
- var u = i(50104);
- s.exports = function memoizeCapped(s) {
- var o = u(s, function (s) {
- return 500 === i.size && i.clear(), s;
- }),
- i = o.cache;
- return o;
- };
- },
- 3209: (s, o, i) => {
- var u = i(91596),
- _ = i(53320),
- w = i(36306),
- x = '__lodash_placeholder__',
- C = 128,
- j = Math.min;
- s.exports = function mergeData(s, o) {
- var i = s[1],
- L = o[1],
- B = i | L,
- $ = B < 131,
- V =
- (L == C && 8 == i) ||
- (L == C && 256 == i && s[7].length <= o[8]) ||
- (384 == L && o[7].length <= o[8] && 8 == i);
- if (!$ && !V) return s;
- 1 & L && ((s[2] = o[2]), (B |= 1 & i ? 0 : 4));
- var U = o[3];
- if (U) {
- var z = s[3];
- (s[3] = z ? u(z, U, o[4]) : U), (s[4] = z ? w(s[3], x) : o[4]);
- }
- return (
- (U = o[5]) &&
- ((z = s[5]), (s[5] = z ? _(z, U, o[6]) : U), (s[6] = z ? w(s[5], x) : o[6])),
- (U = o[7]) && (s[7] = U),
- L & C && (s[8] = null == s[8] ? o[8] : j(s[8], o[8])),
- null == s[9] && (s[9] = o[9]),
- (s[0] = o[0]),
- (s[1] = B),
- s
- );
- };
- },
- 48152: (s, o, i) => {
- var u = i(28303),
- _ = u && new u();
- s.exports = _;
- },
- 81042: (s, o, i) => {
- var u = i(56110)(Object, 'create');
- s.exports = u;
- },
- 3650: (s, o, i) => {
- var u = i(74335)(Object.keys, Object);
- s.exports = u;
- },
- 90181: (s) => {
- s.exports = function nativeKeysIn(s) {
- var o = [];
- if (null != s) for (var i in Object(s)) o.push(i);
- return o;
- };
- },
- 86009: (s, o, i) => {
- s = i.nmd(s);
- var u = i(34840),
- _ = o && !o.nodeType && o,
- w = _ && s && !s.nodeType && s,
- x = w && w.exports === _ && u.process,
- C = (function () {
- try {
- var s = w && w.require && w.require('util').types;
- return s || (x && x.binding && x.binding('util'));
- } catch (s) {}
- })();
- s.exports = C;
- },
- 59350: (s) => {
- var o = Object.prototype.toString;
- s.exports = function objectToString(s) {
- return o.call(s);
- };
- },
- 74335: (s) => {
- s.exports = function overArg(s, o) {
- return function (i) {
- return s(o(i));
- };
- };
- },
- 56757: (s, o, i) => {
- var u = i(91033),
- _ = Math.max;
- s.exports = function overRest(s, o, i) {
- return (
- (o = _(void 0 === o ? s.length - 1 : o, 0)),
- function () {
- for (var w = arguments, x = -1, C = _(w.length - o, 0), j = Array(C); ++x < C; )
- j[x] = w[o + x];
- x = -1;
- for (var L = Array(o + 1); ++x < o; ) L[x] = w[x];
- return (L[o] = i(j)), u(s, this, L);
- }
- );
- };
- },
- 68969: (s, o, i) => {
- var u = i(47422),
- _ = i(25160);
- s.exports = function parent(s, o) {
- return o.length < 2 ? s : u(s, _(o, 0, -1));
- };
- },
- 84629: (s) => {
- s.exports = {};
- },
- 68294: (s, o, i) => {
- var u = i(23007),
- _ = i(30361),
- w = Math.min;
- s.exports = function reorder(s, o) {
- for (var i = s.length, x = w(o.length, i), C = u(s); x--; ) {
- var j = o[x];
- s[x] = _(j, i) ? C[j] : void 0;
- }
- return s;
- };
- },
- 36306: (s) => {
- var o = '__lodash_placeholder__';
- s.exports = function replaceHolders(s, i) {
- for (var u = -1, _ = s.length, w = 0, x = []; ++u < _; ) {
- var C = s[u];
- (C !== i && C !== o) || ((s[u] = o), (x[w++] = u));
- }
- return x;
- };
- },
- 9325: (s, o, i) => {
- var u = i(34840),
- _ = 'object' == typeof self && self && self.Object === Object && self,
- w = u || _ || Function('return this')();
- s.exports = w;
- },
- 14974: (s) => {
- s.exports = function safeGet(s, o) {
- if (('constructor' !== o || 'function' != typeof s[o]) && '__proto__' != o) return s[o];
- };
- },
- 31380: (s) => {
- s.exports = function setCacheAdd(s) {
- return this.__data__.set(s, '__lodash_hash_undefined__'), this;
- };
- },
- 51459: (s) => {
- s.exports = function setCacheHas(s) {
- return this.__data__.has(s);
- };
- },
- 54641: (s, o, i) => {
- var u = i(68882),
- _ = i(51811)(u);
- s.exports = _;
- },
- 84247: (s) => {
- s.exports = function setToArray(s) {
- var o = -1,
- i = Array(s.size);
- return (
- s.forEach(function (s) {
- i[++o] = s;
- }),
- i
- );
- };
- },
- 32865: (s, o, i) => {
- var u = i(19570),
- _ = i(51811)(u);
- s.exports = _;
- },
- 70981: (s, o, i) => {
- var u = i(75251),
- _ = i(62060),
- w = i(32865),
- x = i(75948);
- s.exports = function setWrapToString(s, o, i) {
- var C = o + '';
- return w(s, _(C, x(u(C), i)));
- };
- },
- 51811: (s) => {
- var o = Date.now;
- s.exports = function shortOut(s) {
- var i = 0,
- u = 0;
- return function () {
- var _ = o(),
- w = 16 - (_ - u);
- if (((u = _), w > 0)) {
- if (++i >= 800) return arguments[0];
- } else i = 0;
- return s.apply(void 0, arguments);
- };
- };
- },
- 51420: (s, o, i) => {
- var u = i(80079);
- s.exports = function stackClear() {
- (this.__data__ = new u()), (this.size = 0);
- };
- },
- 90938: (s) => {
- s.exports = function stackDelete(s) {
- var o = this.__data__,
- i = o.delete(s);
- return (this.size = o.size), i;
- };
- },
- 63605: (s) => {
- s.exports = function stackGet(s) {
- return this.__data__.get(s);
- };
- },
- 29817: (s) => {
- s.exports = function stackHas(s) {
- return this.__data__.has(s);
- };
- },
- 80945: (s, o, i) => {
- var u = i(80079),
- _ = i(68223),
- w = i(53661);
- s.exports = function stackSet(s, o) {
- var i = this.__data__;
- if (i instanceof u) {
- var x = i.__data__;
- if (!_ || x.length < 199) return x.push([s, o]), (this.size = ++i.size), this;
- i = this.__data__ = new w(x);
- }
- return i.set(s, o), (this.size = i.size), this;
- };
- },
- 76959: (s) => {
- s.exports = function strictIndexOf(s, o, i) {
- for (var u = i - 1, _ = s.length; ++u < _; ) if (s[u] === o) return u;
- return -1;
- };
- },
- 63912: (s, o, i) => {
- var u = i(61074),
- _ = i(49698),
- w = i(42054);
- s.exports = function stringToArray(s) {
- return _(s) ? w(s) : u(s);
- };
- },
- 61802: (s, o, i) => {
- var u = i(62224),
- _ =
- /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,
- w = /\\(\\)?/g,
- x = u(function (s) {
- var o = [];
- return (
- 46 === s.charCodeAt(0) && o.push(''),
- s.replace(_, function (s, i, u, _) {
- o.push(u ? _.replace(w, '$1') : i || s);
- }),
- o
- );
- });
- s.exports = x;
- },
- 77797: (s, o, i) => {
- var u = i(44394);
- s.exports = function toKey(s) {
- if ('string' == typeof s || u(s)) return s;
- var o = s + '';
- return '0' == o && 1 / s == -1 / 0 ? '-0' : o;
- };
- },
- 47473: (s) => {
- var o = Function.prototype.toString;
- s.exports = function toSource(s) {
- if (null != s) {
- try {
- return o.call(s);
- } catch (s) {}
- try {
- return s + '';
- } catch (s) {}
- }
- return '';
- };
- },
- 31800: (s) => {
- var o = /\s/;
- s.exports = function trimmedEndIndex(s) {
- for (var i = s.length; i-- && o.test(s.charAt(i)); );
- return i;
- };
- },
- 42054: (s) => {
- var o = '\\ud800-\\udfff',
- i = '[' + o + ']',
- u = '[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]',
- _ = '\\ud83c[\\udffb-\\udfff]',
- w = '[^' + o + ']',
- x = '(?:\\ud83c[\\udde6-\\uddff]){2}',
- C = '[\\ud800-\\udbff][\\udc00-\\udfff]',
- j = '(?:' + u + '|' + _ + ')' + '?',
- L = '[\\ufe0e\\ufe0f]?',
- B = L + j + ('(?:\\u200d(?:' + [w, x, C].join('|') + ')' + L + j + ')*'),
- $ = '(?:' + [w + u + '?', u, x, C, i].join('|') + ')',
- V = RegExp(_ + '(?=' + _ + ')|' + $ + B, 'g');
- s.exports = function unicodeToArray(s) {
- return s.match(V) || [];
- };
- },
- 22225: (s) => {
- var o = '\\ud800-\\udfff',
- i = '\\u2700-\\u27bf',
- u = 'a-z\\xdf-\\xf6\\xf8-\\xff',
- _ = 'A-Z\\xc0-\\xd6\\xd8-\\xde',
- w =
- '\\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',
- x = '[' + w + ']',
- C = '\\d+',
- j = '[' + i + ']',
- L = '[' + u + ']',
- B = '[^' + o + w + C + i + u + _ + ']',
- $ = '(?:\\ud83c[\\udde6-\\uddff]){2}',
- V = '[\\ud800-\\udbff][\\udc00-\\udfff]',
- U = '[' + _ + ']',
- z = '(?:' + L + '|' + B + ')',
- Y = '(?:' + U + '|' + B + ')',
- Z = "(?:['’](?:d|ll|m|re|s|t|ve))?",
- ee = "(?:['’](?:D|LL|M|RE|S|T|VE))?",
- ie = '(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?',
- ae = '[\\ufe0e\\ufe0f]?',
- le =
- ae + ie + ('(?:\\u200d(?:' + ['[^' + o + ']', $, V].join('|') + ')' + ae + ie + ')*'),
- ce = '(?:' + [j, $, V].join('|') + ')' + le,
- pe = RegExp(
- [
- U + '?' + L + '+' + Z + '(?=' + [x, U, '$'].join('|') + ')',
- Y + '+' + ee + '(?=' + [x, U + z, '$'].join('|') + ')',
- U + '?' + z + '+' + Z,
- U + '+' + ee,
- '\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])',
- '\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])',
- C,
- ce
- ].join('|'),
- 'g'
- );
- s.exports = function unicodeWords(s) {
- return s.match(pe) || [];
- };
- },
- 75948: (s, o, i) => {
- var u = i(83729),
- _ = i(15325),
- w = [
- ['ary', 128],
- ['bind', 1],
- ['bindKey', 2],
- ['curry', 8],
- ['curryRight', 16],
- ['flip', 512],
- ['partial', 32],
- ['partialRight', 64],
- ['rearg', 256]
- ];
- s.exports = function updateWrapDetails(s, o) {
- return (
- u(w, function (i) {
- var u = '_.' + i[0];
- o & i[1] && !_(s, u) && s.push(u);
- }),
- s.sort()
- );
- };
- },
- 80257: (s, o, i) => {
- var u = i(30980),
- _ = i(56017),
- w = i(23007);
- s.exports = function wrapperClone(s) {
- if (s instanceof u) return s.clone();
- var o = new _(s.__wrapped__, s.__chain__);
- return (
- (o.__actions__ = w(s.__actions__)),
- (o.__index__ = s.__index__),
- (o.__values__ = s.__values__),
- o
- );
- };
- },
- 64626: (s, o, i) => {
- var u = i(66977);
- s.exports = function ary(s, o, i) {
- return (
- (o = i ? void 0 : o),
- (o = s && null == o ? s.length : o),
- u(s, 128, void 0, void 0, void 0, void 0, o)
- );
- };
- },
- 84058: (s, o, i) => {
- var u = i(14792),
- _ = i(45539)(function (s, o, i) {
- return (o = o.toLowerCase()), s + (i ? u(o) : o);
- });
- s.exports = _;
- },
- 14792: (s, o, i) => {
- var u = i(13222),
- _ = i(55808);
- s.exports = function capitalize(s) {
- return _(u(s).toLowerCase());
- };
- },
- 32629: (s, o, i) => {
- var u = i(9999);
- s.exports = function clone(s) {
- return u(s, 4);
- };
- },
- 37334: (s) => {
- s.exports = function constant(s) {
- return function () {
- return s;
- };
- };
- },
- 49747: (s, o, i) => {
- var u = i(66977);
- function curry(s, o, i) {
- var _ = u(s, 8, void 0, void 0, void 0, void 0, void 0, (o = i ? void 0 : o));
- return (_.placeholder = curry.placeholder), _;
- }
- (curry.placeholder = {}), (s.exports = curry);
- },
- 38221: (s, o, i) => {
- var u = i(23805),
- _ = i(10124),
- w = i(99374),
- x = Math.max,
- C = Math.min;
- s.exports = function debounce(s, o, i) {
- var j,
- L,
- B,
- $,
- V,
- U,
- z = 0,
- Y = !1,
- Z = !1,
- ee = !0;
- if ('function' != typeof s) throw new TypeError('Expected a function');
- function invokeFunc(o) {
- var i = j,
- u = L;
- return (j = L = void 0), (z = o), ($ = s.apply(u, i));
- }
- function shouldInvoke(s) {
- var i = s - U;
- return void 0 === U || i >= o || i < 0 || (Z && s - z >= B);
- }
- function timerExpired() {
- var s = _();
- if (shouldInvoke(s)) return trailingEdge(s);
- V = setTimeout(
- timerExpired,
- (function remainingWait(s) {
- var i = o - (s - U);
- return Z ? C(i, B - (s - z)) : i;
- })(s)
- );
- }
- function trailingEdge(s) {
- return (V = void 0), ee && j ? invokeFunc(s) : ((j = L = void 0), $);
- }
- function debounced() {
- var s = _(),
- i = shouldInvoke(s);
- if (((j = arguments), (L = this), (U = s), i)) {
- if (void 0 === V)
- return (function leadingEdge(s) {
- return (z = s), (V = setTimeout(timerExpired, o)), Y ? invokeFunc(s) : $;
- })(U);
- if (Z) return clearTimeout(V), (V = setTimeout(timerExpired, o)), invokeFunc(U);
- }
- return void 0 === V && (V = setTimeout(timerExpired, o)), $;
- }
- return (
- (o = w(o) || 0),
- u(i) &&
- ((Y = !!i.leading),
- (B = (Z = 'maxWait' in i) ? x(w(i.maxWait) || 0, o) : B),
- (ee = 'trailing' in i ? !!i.trailing : ee)),
- (debounced.cancel = function cancel() {
- void 0 !== V && clearTimeout(V), (z = 0), (j = U = L = V = void 0);
- }),
- (debounced.flush = function flush() {
- return void 0 === V ? $ : trailingEdge(_());
- }),
- debounced
- );
- };
- },
- 50828: (s, o, i) => {
- var u = i(24647),
- _ = i(13222),
- w = /[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,
- x = RegExp('[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]', 'g');
- s.exports = function deburr(s) {
- return (s = _(s)) && s.replace(w, u).replace(x, '');
- };
- },
- 75288: (s) => {
- s.exports = function eq(s, o) {
- return s === o || (s != s && o != o);
- };
- },
- 60680: (s, o, i) => {
- var u = i(13222),
- _ = /[\\^$.*+?()[\]{}|]/g,
- w = RegExp(_.source);
- s.exports = function escapeRegExp(s) {
- return (s = u(s)) && w.test(s) ? s.replace(_, '\\$&') : s;
- };
- },
- 7309: (s, o, i) => {
- var u = i(62006)(i(24713));
- s.exports = u;
- },
- 24713: (s, o, i) => {
- var u = i(2523),
- _ = i(15389),
- w = i(61489),
- x = Math.max;
- s.exports = function findIndex(s, o, i) {
- var C = null == s ? 0 : s.length;
- if (!C) return -1;
- var j = null == i ? 0 : w(i);
- return j < 0 && (j = x(C + j, 0)), u(s, _(o, 3), j);
- };
- },
- 35970: (s, o, i) => {
- var u = i(83120);
- s.exports = function flatten(s) {
- return (null == s ? 0 : s.length) ? u(s, 1) : [];
- };
- },
- 73424: (s, o, i) => {
- var u = i(16962),
- _ = i(2874),
- w = Array.prototype.push;
- function baseAry(s, o) {
- return 2 == o
- ? function (o, i) {
- return s(o, i);
- }
- : function (o) {
- return s(o);
- };
- }
- function cloneArray(s) {
- for (var o = s ? s.length : 0, i = Array(o); o--; ) i[o] = s[o];
- return i;
- }
- function wrapImmutable(s, o) {
- return function () {
- var i = arguments.length;
- if (i) {
- for (var u = Array(i); i--; ) u[i] = arguments[i];
- var _ = (u[0] = o.apply(void 0, u));
- return s.apply(void 0, u), _;
- }
- };
- }
- s.exports = function baseConvert(s, o, i, x) {
- var C = 'function' == typeof o,
- j = o === Object(o);
- if ((j && ((x = i), (i = o), (o = void 0)), null == i)) throw new TypeError();
- x || (x = {});
- var L = !('cap' in x) || x.cap,
- B = !('curry' in x) || x.curry,
- $ = !('fixed' in x) || x.fixed,
- V = !('immutable' in x) || x.immutable,
- U = !('rearg' in x) || x.rearg,
- z = C ? i : _,
- Y = 'curry' in x && x.curry,
- Z = 'fixed' in x && x.fixed,
- ee = 'rearg' in x && x.rearg,
- ie = C ? i.runInContext() : void 0,
- ae = C
- ? i
- : {
- ary: s.ary,
- assign: s.assign,
- clone: s.clone,
- curry: s.curry,
- forEach: s.forEach,
- isArray: s.isArray,
- isError: s.isError,
- isFunction: s.isFunction,
- isWeakMap: s.isWeakMap,
- iteratee: s.iteratee,
- keys: s.keys,
- rearg: s.rearg,
- toInteger: s.toInteger,
- toPath: s.toPath
- },
- le = ae.ary,
- ce = ae.assign,
- pe = ae.clone,
- de = ae.curry,
- fe = ae.forEach,
- ye = ae.isArray,
- be = ae.isError,
- _e = ae.isFunction,
- we = ae.isWeakMap,
- Se = ae.keys,
- xe = ae.rearg,
- Pe = ae.toInteger,
- Te = ae.toPath,
- Re = Se(u.aryMethod),
- qe = {
- castArray: function (s) {
- return function () {
- var o = arguments[0];
- return ye(o) ? s(cloneArray(o)) : s.apply(void 0, arguments);
- };
- },
- iteratee: function (s) {
- return function () {
- var o = arguments[1],
- i = s(arguments[0], o),
- u = i.length;
- return L && 'number' == typeof o
- ? ((o = o > 2 ? o - 2 : 1), u && u <= o ? i : baseAry(i, o))
- : i;
- };
- },
- mixin: function (s) {
- return function (o) {
- var i = this;
- if (!_e(i)) return s(i, Object(o));
- var u = [];
- return (
- fe(Se(o), function (s) {
- _e(o[s]) && u.push([s, i.prototype[s]]);
- }),
- s(i, Object(o)),
- fe(u, function (s) {
- var o = s[1];
- _e(o) ? (i.prototype[s[0]] = o) : delete i.prototype[s[0]];
- }),
- i
- );
- };
- },
- nthArg: function (s) {
- return function (o) {
- var i = o < 0 ? 1 : Pe(o) + 1;
- return de(s(o), i);
- };
- },
- rearg: function (s) {
- return function (o, i) {
- var u = i ? i.length : 0;
- return de(s(o, i), u);
- };
- },
- runInContext: function (o) {
- return function (i) {
- return baseConvert(s, o(i), x);
- };
- }
- };
- function castCap(s, o) {
- if (L) {
- var i = u.iterateeRearg[s];
- if (i)
- return (function iterateeRearg(s, o) {
- return overArg(s, function (s) {
- var i = o.length;
- return (function baseArity(s, o) {
- return 2 == o
- ? function (o, i) {
- return s.apply(void 0, arguments);
- }
- : function (o) {
- return s.apply(void 0, arguments);
- };
- })(xe(baseAry(s, i), o), i);
- });
- })(o, i);
- var _ = !C && u.iterateeAry[s];
- if (_)
- return (function iterateeAry(s, o) {
- return overArg(s, function (s) {
- return 'function' == typeof s ? baseAry(s, o) : s;
- });
- })(o, _);
- }
- return o;
- }
- function castFixed(s, o, i) {
- if ($ && (Z || !u.skipFixed[s])) {
- var _ = u.methodSpread[s],
- x = _ && _.start;
- return void 0 === x
- ? le(o, i)
- : (function flatSpread(s, o) {
- return function () {
- for (var i = arguments.length, u = i - 1, _ = Array(i); i--; )
- _[i] = arguments[i];
- var x = _[o],
- C = _.slice(0, o);
- return (
- x && w.apply(C, x), o != u && w.apply(C, _.slice(o + 1)), s.apply(this, C)
- );
- };
- })(o, x);
- }
- return o;
- }
- function castRearg(s, o, i) {
- return U && i > 1 && (ee || !u.skipRearg[s])
- ? xe(o, u.methodRearg[s] || u.aryRearg[i])
- : o;
- }
- function cloneByPath(s, o) {
- for (
- var i = -1, u = (o = Te(o)).length, _ = u - 1, w = pe(Object(s)), x = w;
- null != x && ++i < u;
- ) {
- var C = o[i],
- j = x[C];
- null == j || _e(j) || be(j) || we(j) || (x[C] = pe(i == _ ? j : Object(j))),
- (x = x[C]);
- }
- return w;
- }
- function createConverter(s, o) {
- var i = u.aliasToReal[s] || s,
- _ = u.remap[i] || i,
- w = x;
- return function (s) {
- var u = C ? ie : ae,
- x = C ? ie[_] : o,
- j = ce(ce({}, w), s);
- return baseConvert(u, i, x, j);
- };
- }
- function overArg(s, o) {
- return function () {
- var i = arguments.length;
- if (!i) return s();
- for (var u = Array(i); i--; ) u[i] = arguments[i];
- var _ = U ? 0 : i - 1;
- return (u[_] = o(u[_])), s.apply(void 0, u);
- };
- }
- function wrap(s, o, i) {
- var _,
- w = u.aliasToReal[s] || s,
- x = o,
- C = qe[w];
- return (
- C
- ? (x = C(o))
- : V &&
- (u.mutate.array[w]
- ? (x = wrapImmutable(o, cloneArray))
- : u.mutate.object[w]
- ? (x = wrapImmutable(
- o,
- (function createCloner(s) {
- return function (o) {
- return s({}, o);
- };
- })(o)
- ))
- : u.mutate.set[w] && (x = wrapImmutable(o, cloneByPath))),
- fe(Re, function (s) {
- return (
- fe(u.aryMethod[s], function (o) {
- if (w == o) {
- var i = u.methodSpread[w],
- C = i && i.afterRearg;
- return (
- (_ = C
- ? castFixed(w, castRearg(w, x, s), s)
- : castRearg(w, castFixed(w, x, s), s)),
- (_ = (function castCurry(s, o, i) {
- return Y || (B && i > 1) ? de(o, i) : o;
- })(0, (_ = castCap(w, _)), s)),
- !1
- );
- }
- }),
- !_
- );
- }),
- _ || (_ = x),
- _ == o &&
- (_ = Y
- ? de(_, 1)
- : function () {
- return o.apply(this, arguments);
- }),
- (_.convert = createConverter(w, o)),
- (_.placeholder = o.placeholder = i),
- _
- );
- }
- if (!j) return wrap(o, i, z);
- var $e = i,
- ze = [];
- return (
- fe(Re, function (s) {
- fe(u.aryMethod[s], function (s) {
- var o = $e[u.remap[s] || s];
- o && ze.push([s, wrap(s, o, $e)]);
- });
- }),
- fe(Se($e), function (s) {
- var o = $e[s];
- if ('function' == typeof o) {
- for (var i = ze.length; i--; ) if (ze[i][0] == s) return;
- (o.convert = createConverter(s, o)), ze.push([s, o]);
- }
- }),
- fe(ze, function (s) {
- $e[s[0]] = s[1];
- }),
- ($e.convert = function convertLib(s) {
- return $e.runInContext.convert(s)(void 0);
- }),
- ($e.placeholder = $e),
- fe(Se($e), function (s) {
- fe(u.realToAlias[s] || [], function (o) {
- $e[o] = $e[s];
- });
- }),
- $e
- );
- };
- },
- 16962: (s, o) => {
- (o.aliasToReal = {
- each: 'forEach',
- eachRight: 'forEachRight',
- entries: 'toPairs',
- entriesIn: 'toPairsIn',
- extend: 'assignIn',
- extendAll: 'assignInAll',
- extendAllWith: 'assignInAllWith',
- extendWith: 'assignInWith',
- first: 'head',
- conforms: 'conformsTo',
- matches: 'isMatch',
- property: 'get',
- __: 'placeholder',
- F: 'stubFalse',
- T: 'stubTrue',
- all: 'every',
- allPass: 'overEvery',
- always: 'constant',
- any: 'some',
- anyPass: 'overSome',
- apply: 'spread',
- assoc: 'set',
- assocPath: 'set',
- complement: 'negate',
- compose: 'flowRight',
- contains: 'includes',
- dissoc: 'unset',
- dissocPath: 'unset',
- dropLast: 'dropRight',
- dropLastWhile: 'dropRightWhile',
- equals: 'isEqual',
- identical: 'eq',
- indexBy: 'keyBy',
- init: 'initial',
- invertObj: 'invert',
- juxt: 'over',
- omitAll: 'omit',
- nAry: 'ary',
- path: 'get',
- pathEq: 'matchesProperty',
- pathOr: 'getOr',
- paths: 'at',
- pickAll: 'pick',
- pipe: 'flow',
- pluck: 'map',
- prop: 'get',
- propEq: 'matchesProperty',
- propOr: 'getOr',
- props: 'at',
- symmetricDifference: 'xor',
- symmetricDifferenceBy: 'xorBy',
- symmetricDifferenceWith: 'xorWith',
- takeLast: 'takeRight',
- takeLastWhile: 'takeRightWhile',
- unapply: 'rest',
- unnest: 'flatten',
- useWith: 'overArgs',
- where: 'conformsTo',
- whereEq: 'isMatch',
- zipObj: 'zipObject'
- }),
- (o.aryMethod = {
- 1: [
- 'assignAll',
- 'assignInAll',
- 'attempt',
- 'castArray',
- 'ceil',
- 'create',
- 'curry',
- 'curryRight',
- 'defaultsAll',
- 'defaultsDeepAll',
- 'floor',
- 'flow',
- 'flowRight',
- 'fromPairs',
- 'invert',
- 'iteratee',
- 'memoize',
- 'method',
- 'mergeAll',
- 'methodOf',
- 'mixin',
- 'nthArg',
- 'over',
- 'overEvery',
- 'overSome',
- 'rest',
- 'reverse',
- 'round',
- 'runInContext',
- 'spread',
- 'template',
- 'trim',
- 'trimEnd',
- 'trimStart',
- 'uniqueId',
- 'words',
- 'zipAll'
- ],
- 2: [
- 'add',
- 'after',
- 'ary',
- 'assign',
- 'assignAllWith',
- 'assignIn',
- 'assignInAllWith',
- 'at',
- 'before',
- 'bind',
- 'bindAll',
- 'bindKey',
- 'chunk',
- 'cloneDeepWith',
- 'cloneWith',
- 'concat',
- 'conformsTo',
- 'countBy',
- 'curryN',
- 'curryRightN',
- 'debounce',
- 'defaults',
- 'defaultsDeep',
- 'defaultTo',
- 'delay',
- 'difference',
- 'divide',
- 'drop',
- 'dropRight',
- 'dropRightWhile',
- 'dropWhile',
- 'endsWith',
- 'eq',
- 'every',
- 'filter',
- 'find',
- 'findIndex',
- 'findKey',
- 'findLast',
- 'findLastIndex',
- 'findLastKey',
- 'flatMap',
- 'flatMapDeep',
- 'flattenDepth',
- 'forEach',
- 'forEachRight',
- 'forIn',
- 'forInRight',
- 'forOwn',
- 'forOwnRight',
- 'get',
- 'groupBy',
- 'gt',
- 'gte',
- 'has',
- 'hasIn',
- 'includes',
- 'indexOf',
- 'intersection',
- 'invertBy',
- 'invoke',
- 'invokeMap',
- 'isEqual',
- 'isMatch',
- 'join',
- 'keyBy',
- 'lastIndexOf',
- 'lt',
- 'lte',
- 'map',
- 'mapKeys',
- 'mapValues',
- 'matchesProperty',
- 'maxBy',
- 'meanBy',
- 'merge',
- 'mergeAllWith',
- 'minBy',
- 'multiply',
- 'nth',
- 'omit',
- 'omitBy',
- 'overArgs',
- 'pad',
- 'padEnd',
- 'padStart',
- 'parseInt',
- 'partial',
- 'partialRight',
- 'partition',
- 'pick',
- 'pickBy',
- 'propertyOf',
- 'pull',
- 'pullAll',
- 'pullAt',
- 'random',
- 'range',
- 'rangeRight',
- 'rearg',
- 'reject',
- 'remove',
- 'repeat',
- 'restFrom',
- 'result',
- 'sampleSize',
- 'some',
- 'sortBy',
- 'sortedIndex',
- 'sortedIndexOf',
- 'sortedLastIndex',
- 'sortedLastIndexOf',
- 'sortedUniqBy',
- 'split',
- 'spreadFrom',
- 'startsWith',
- 'subtract',
- 'sumBy',
- 'take',
- 'takeRight',
- 'takeRightWhile',
- 'takeWhile',
- 'tap',
- 'throttle',
- 'thru',
- 'times',
- 'trimChars',
- 'trimCharsEnd',
- 'trimCharsStart',
- 'truncate',
- 'union',
- 'uniqBy',
- 'uniqWith',
- 'unset',
- 'unzipWith',
- 'without',
- 'wrap',
- 'xor',
- 'zip',
- 'zipObject',
- 'zipObjectDeep'
- ],
- 3: [
- 'assignInWith',
- 'assignWith',
- 'clamp',
- 'differenceBy',
- 'differenceWith',
- 'findFrom',
- 'findIndexFrom',
- 'findLastFrom',
- 'findLastIndexFrom',
- 'getOr',
- 'includesFrom',
- 'indexOfFrom',
- 'inRange',
- 'intersectionBy',
- 'intersectionWith',
- 'invokeArgs',
- 'invokeArgsMap',
- 'isEqualWith',
- 'isMatchWith',
- 'flatMapDepth',
- 'lastIndexOfFrom',
- 'mergeWith',
- 'orderBy',
- 'padChars',
- 'padCharsEnd',
- 'padCharsStart',
- 'pullAllBy',
- 'pullAllWith',
- 'rangeStep',
- 'rangeStepRight',
- 'reduce',
- 'reduceRight',
- 'replace',
- 'set',
- 'slice',
- 'sortedIndexBy',
- 'sortedLastIndexBy',
- 'transform',
- 'unionBy',
- 'unionWith',
- 'update',
- 'xorBy',
- 'xorWith',
- 'zipWith'
- ],
- 4: ['fill', 'setWith', 'updateWith']
- }),
- (o.aryRearg = { 2: [1, 0], 3: [2, 0, 1], 4: [3, 2, 0, 1] }),
- (o.iterateeAry = {
- dropRightWhile: 1,
- dropWhile: 1,
- every: 1,
- filter: 1,
- find: 1,
- findFrom: 1,
- findIndex: 1,
- findIndexFrom: 1,
- findKey: 1,
- findLast: 1,
- findLastFrom: 1,
- findLastIndex: 1,
- findLastIndexFrom: 1,
- findLastKey: 1,
- flatMap: 1,
- flatMapDeep: 1,
- flatMapDepth: 1,
- forEach: 1,
- forEachRight: 1,
- forIn: 1,
- forInRight: 1,
- forOwn: 1,
- forOwnRight: 1,
- map: 1,
- mapKeys: 1,
- mapValues: 1,
- partition: 1,
- reduce: 2,
- reduceRight: 2,
- reject: 1,
- remove: 1,
- some: 1,
- takeRightWhile: 1,
- takeWhile: 1,
- times: 1,
- transform: 2
- }),
- (o.iterateeRearg = { mapKeys: [1], reduceRight: [1, 0] }),
- (o.methodRearg = {
- assignInAllWith: [1, 0],
- assignInWith: [1, 2, 0],
- assignAllWith: [1, 0],
- assignWith: [1, 2, 0],
- differenceBy: [1, 2, 0],
- differenceWith: [1, 2, 0],
- getOr: [2, 1, 0],
- intersectionBy: [1, 2, 0],
- intersectionWith: [1, 2, 0],
- isEqualWith: [1, 2, 0],
- isMatchWith: [2, 1, 0],
- mergeAllWith: [1, 0],
- mergeWith: [1, 2, 0],
- padChars: [2, 1, 0],
- padCharsEnd: [2, 1, 0],
- padCharsStart: [2, 1, 0],
- pullAllBy: [2, 1, 0],
- pullAllWith: [2, 1, 0],
- rangeStep: [1, 2, 0],
- rangeStepRight: [1, 2, 0],
- setWith: [3, 1, 2, 0],
- sortedIndexBy: [2, 1, 0],
- sortedLastIndexBy: [2, 1, 0],
- unionBy: [1, 2, 0],
- unionWith: [1, 2, 0],
- updateWith: [3, 1, 2, 0],
- xorBy: [1, 2, 0],
- xorWith: [1, 2, 0],
- zipWith: [1, 2, 0]
- }),
- (o.methodSpread = {
- assignAll: { start: 0 },
- assignAllWith: { start: 0 },
- assignInAll: { start: 0 },
- assignInAllWith: { start: 0 },
- defaultsAll: { start: 0 },
- defaultsDeepAll: { start: 0 },
- invokeArgs: { start: 2 },
- invokeArgsMap: { start: 2 },
- mergeAll: { start: 0 },
- mergeAllWith: { start: 0 },
- partial: { start: 1 },
- partialRight: { start: 1 },
- without: { start: 1 },
- zipAll: { start: 0 }
- }),
- (o.mutate = {
- array: {
- fill: !0,
- pull: !0,
- pullAll: !0,
- pullAllBy: !0,
- pullAllWith: !0,
- pullAt: !0,
- remove: !0,
- reverse: !0
- },
- object: {
- assign: !0,
- assignAll: !0,
- assignAllWith: !0,
- assignIn: !0,
- assignInAll: !0,
- assignInAllWith: !0,
- assignInWith: !0,
- assignWith: !0,
- defaults: !0,
- defaultsAll: !0,
- defaultsDeep: !0,
- defaultsDeepAll: !0,
- merge: !0,
- mergeAll: !0,
- mergeAllWith: !0,
- mergeWith: !0
- },
- set: { set: !0, setWith: !0, unset: !0, update: !0, updateWith: !0 }
- }),
- (o.realToAlias = (function () {
- var s = Object.prototype.hasOwnProperty,
- i = o.aliasToReal,
- u = {};
- for (var _ in i) {
- var w = i[_];
- s.call(u, w) ? u[w].push(_) : (u[w] = [_]);
- }
- return u;
- })()),
- (o.remap = {
- assignAll: 'assign',
- assignAllWith: 'assignWith',
- assignInAll: 'assignIn',
- assignInAllWith: 'assignInWith',
- curryN: 'curry',
- curryRightN: 'curryRight',
- defaultsAll: 'defaults',
- defaultsDeepAll: 'defaultsDeep',
- findFrom: 'find',
- findIndexFrom: 'findIndex',
- findLastFrom: 'findLast',
- findLastIndexFrom: 'findLastIndex',
- getOr: 'get',
- includesFrom: 'includes',
- indexOfFrom: 'indexOf',
- invokeArgs: 'invoke',
- invokeArgsMap: 'invokeMap',
- lastIndexOfFrom: 'lastIndexOf',
- mergeAll: 'merge',
- mergeAllWith: 'mergeWith',
- padChars: 'pad',
- padCharsEnd: 'padEnd',
- padCharsStart: 'padStart',
- propertyOf: 'get',
- rangeStep: 'range',
- rangeStepRight: 'rangeRight',
- restFrom: 'rest',
- spreadFrom: 'spread',
- trimChars: 'trim',
- trimCharsEnd: 'trimEnd',
- trimCharsStart: 'trimStart',
- zipAll: 'zip'
- }),
- (o.skipFixed = {
- castArray: !0,
- flow: !0,
- flowRight: !0,
- iteratee: !0,
- mixin: !0,
- rearg: !0,
- runInContext: !0
- }),
- (o.skipRearg = {
- add: !0,
- assign: !0,
- assignIn: !0,
- bind: !0,
- bindKey: !0,
- concat: !0,
- difference: !0,
- divide: !0,
- eq: !0,
- gt: !0,
- gte: !0,
- isEqual: !0,
- lt: !0,
- lte: !0,
- matchesProperty: !0,
- merge: !0,
- multiply: !0,
- overArgs: !0,
- partial: !0,
- partialRight: !0,
- propertyOf: !0,
- random: !0,
- range: !0,
- rangeRight: !0,
- subtract: !0,
- zip: !0,
- zipObject: !0,
- zipObjectDeep: !0
- });
- },
- 47934: (s, o, i) => {
- s.exports = {
- ary: i(64626),
- assign: i(74733),
- clone: i(32629),
- curry: i(49747),
- forEach: i(83729),
- isArray: i(56449),
- isError: i(23546),
- isFunction: i(1882),
- isWeakMap: i(47886),
- iteratee: i(33855),
- keys: i(88984),
- rearg: i(84195),
- toInteger: i(61489),
- toPath: i(42072)
- };
- },
- 56367: (s, o, i) => {
- s.exports = i(77731);
- },
- 79920: (s, o, i) => {
- var u = i(73424),
- _ = i(47934);
- s.exports = function convert(s, o, i) {
- return u(_, s, o, i);
- };
- },
- 2874: (s) => {
- s.exports = {};
- },
- 77731: (s, o, i) => {
- var u = i(79920)('set', i(63560));
- (u.placeholder = i(2874)), (s.exports = u);
- },
- 58156: (s, o, i) => {
- var u = i(47422);
- s.exports = function get(s, o, i) {
- var _ = null == s ? void 0 : u(s, o);
- return void 0 === _ ? i : _;
- };
- },
- 61448: (s, o, i) => {
- var u = i(20426),
- _ = i(49326);
- s.exports = function has(s, o) {
- return null != s && _(s, o, u);
- };
- },
- 80631: (s, o, i) => {
- var u = i(28077),
- _ = i(49326);
- s.exports = function hasIn(s, o) {
- return null != s && _(s, o, u);
- };
- },
- 83488: (s) => {
- s.exports = function identity(s) {
- return s;
- };
- },
- 72428: (s, o, i) => {
- var u = i(27534),
- _ = i(40346),
- w = Object.prototype,
- x = w.hasOwnProperty,
- C = w.propertyIsEnumerable,
- j = u(
- (function () {
- return arguments;
- })()
- )
- ? u
- : function (s) {
- return _(s) && x.call(s, 'callee') && !C.call(s, 'callee');
- };
- s.exports = j;
- },
- 56449: (s) => {
- var o = Array.isArray;
- s.exports = o;
- },
- 64894: (s, o, i) => {
- var u = i(1882),
- _ = i(30294);
- s.exports = function isArrayLike(s) {
- return null != s && _(s.length) && !u(s);
- };
- },
- 83693: (s, o, i) => {
- var u = i(64894),
- _ = i(40346);
- s.exports = function isArrayLikeObject(s) {
- return _(s) && u(s);
- };
- },
- 53812: (s, o, i) => {
- var u = i(72552),
- _ = i(40346);
- s.exports = function isBoolean(s) {
- return !0 === s || !1 === s || (_(s) && '[object Boolean]' == u(s));
- };
- },
- 3656: (s, o, i) => {
- s = i.nmd(s);
- var u = i(9325),
- _ = i(89935),
- w = o && !o.nodeType && o,
- x = w && s && !s.nodeType && s,
- C = x && x.exports === w ? u.Buffer : void 0,
- j = (C ? C.isBuffer : void 0) || _;
- s.exports = j;
- },
- 62193: (s, o, i) => {
- var u = i(88984),
- _ = i(5861),
- w = i(72428),
- x = i(56449),
- C = i(64894),
- j = i(3656),
- L = i(55527),
- B = i(37167),
- $ = Object.prototype.hasOwnProperty;
- s.exports = function isEmpty(s) {
- if (null == s) return !0;
- if (
- C(s) &&
- (x(s) ||
- 'string' == typeof s ||
- 'function' == typeof s.splice ||
- j(s) ||
- B(s) ||
- w(s))
- )
- return !s.length;
- var o = _(s);
- if ('[object Map]' == o || '[object Set]' == o) return !s.size;
- if (L(s)) return !u(s).length;
- for (var i in s) if ($.call(s, i)) return !1;
- return !0;
- };
- },
- 2404: (s, o, i) => {
- var u = i(60270);
- s.exports = function isEqual(s, o) {
- return u(s, o);
- };
- },
- 23546: (s, o, i) => {
- var u = i(72552),
- _ = i(40346),
- w = i(11331);
- s.exports = function isError(s) {
- if (!_(s)) return !1;
- var o = u(s);
- return (
- '[object Error]' == o ||
- '[object DOMException]' == o ||
- ('string' == typeof s.message && 'string' == typeof s.name && !w(s))
- );
- };
- },
- 1882: (s, o, i) => {
- var u = i(72552),
- _ = i(23805);
- s.exports = function isFunction(s) {
- if (!_(s)) return !1;
- var o = u(s);
- return (
- '[object Function]' == o ||
- '[object GeneratorFunction]' == o ||
- '[object AsyncFunction]' == o ||
- '[object Proxy]' == o
- );
- };
- },
- 30294: (s) => {
- s.exports = function isLength(s) {
- return 'number' == typeof s && s > -1 && s % 1 == 0 && s <= 9007199254740991;
- };
- },
- 87730: (s, o, i) => {
- var u = i(29172),
- _ = i(27301),
- w = i(86009),
- x = w && w.isMap,
- C = x ? _(x) : u;
- s.exports = C;
- },
- 5187: (s) => {
- s.exports = function isNull(s) {
- return null === s;
- };
- },
- 98023: (s, o, i) => {
- var u = i(72552),
- _ = i(40346);
- s.exports = function isNumber(s) {
- return 'number' == typeof s || (_(s) && '[object Number]' == u(s));
- };
- },
- 23805: (s) => {
- s.exports = function isObject(s) {
- var o = typeof s;
- return null != s && ('object' == o || 'function' == o);
- };
- },
- 40346: (s) => {
- s.exports = function isObjectLike(s) {
- return null != s && 'object' == typeof s;
- };
- },
- 11331: (s, o, i) => {
- var u = i(72552),
- _ = i(28879),
- w = i(40346),
- x = Function.prototype,
- C = Object.prototype,
- j = x.toString,
- L = C.hasOwnProperty,
- B = j.call(Object);
- s.exports = function isPlainObject(s) {
- if (!w(s) || '[object Object]' != u(s)) return !1;
- var o = _(s);
- if (null === o) return !0;
- var i = L.call(o, 'constructor') && o.constructor;
- return 'function' == typeof i && i instanceof i && j.call(i) == B;
- };
- },
- 38440: (s, o, i) => {
- var u = i(16038),
- _ = i(27301),
- w = i(86009),
- x = w && w.isSet,
- C = x ? _(x) : u;
- s.exports = C;
- },
- 85015: (s, o, i) => {
- var u = i(72552),
- _ = i(56449),
- w = i(40346);
- s.exports = function isString(s) {
- return 'string' == typeof s || (!_(s) && w(s) && '[object String]' == u(s));
- };
- },
- 44394: (s, o, i) => {
- var u = i(72552),
- _ = i(40346);
- s.exports = function isSymbol(s) {
- return 'symbol' == typeof s || (_(s) && '[object Symbol]' == u(s));
- };
- },
- 37167: (s, o, i) => {
- var u = i(4901),
- _ = i(27301),
- w = i(86009),
- x = w && w.isTypedArray,
- C = x ? _(x) : u;
- s.exports = C;
- },
- 47886: (s, o, i) => {
- var u = i(5861),
- _ = i(40346);
- s.exports = function isWeakMap(s) {
- return _(s) && '[object WeakMap]' == u(s);
- };
- },
- 33855: (s, o, i) => {
- var u = i(9999),
- _ = i(15389);
- s.exports = function iteratee(s) {
- return _('function' == typeof s ? s : u(s, 1));
- };
- },
- 95950: (s, o, i) => {
- var u = i(70695),
- _ = i(88984),
- w = i(64894);
- s.exports = function keys(s) {
- return w(s) ? u(s) : _(s);
- };
- },
- 37241: (s, o, i) => {
- var u = i(70695),
- _ = i(72903),
- w = i(64894);
- s.exports = function keysIn(s) {
- return w(s) ? u(s, !0) : _(s);
- };
- },
- 68090: (s) => {
- s.exports = function last(s) {
- var o = null == s ? 0 : s.length;
- return o ? s[o - 1] : void 0;
- };
- },
- 50104: (s, o, i) => {
- var u = i(53661);
- function memoize(s, o) {
- if ('function' != typeof s || (null != o && 'function' != typeof o))
- throw new TypeError('Expected a function');
- var memoized = function () {
- var i = arguments,
- u = o ? o.apply(this, i) : i[0],
- _ = memoized.cache;
- if (_.has(u)) return _.get(u);
- var w = s.apply(this, i);
- return (memoized.cache = _.set(u, w) || _), w;
- };
- return (memoized.cache = new (memoize.Cache || u)()), memoized;
- }
- (memoize.Cache = u), (s.exports = memoize);
- },
- 55364: (s, o, i) => {
- var u = i(85250),
- _ = i(20999)(function (s, o, i) {
- u(s, o, i);
- });
- s.exports = _;
- },
- 6048: (s) => {
- s.exports = function negate(s) {
- if ('function' != typeof s) throw new TypeError('Expected a function');
- return function () {
- var o = arguments;
- switch (o.length) {
- case 0:
- return !s.call(this);
- case 1:
- return !s.call(this, o[0]);
- case 2:
- return !s.call(this, o[0], o[1]);
- case 3:
- return !s.call(this, o[0], o[1], o[2]);
- }
- return !s.apply(this, o);
- };
- };
- },
- 63950: (s) => {
- s.exports = function noop() {};
- },
- 10124: (s, o, i) => {
- var u = i(9325);
- s.exports = function () {
- return u.Date.now();
- };
- },
- 90179: (s, o, i) => {
- var u = i(34932),
- _ = i(9999),
- w = i(19931),
- x = i(31769),
- C = i(21791),
- j = i(53138),
- L = i(38816),
- B = i(83349),
- $ = L(function (s, o) {
- var i = {};
- if (null == s) return i;
- var L = !1;
- (o = u(o, function (o) {
- return (o = x(o, s)), L || (L = o.length > 1), o;
- })),
- C(s, B(s), i),
- L && (i = _(i, 7, j));
- for (var $ = o.length; $--; ) w(i, o[$]);
- return i;
- });
- s.exports = $;
- },
- 50583: (s, o, i) => {
- var u = i(47237),
- _ = i(17255),
- w = i(28586),
- x = i(77797);
- s.exports = function property(s) {
- return w(s) ? u(x(s)) : _(s);
- };
- },
- 84195: (s, o, i) => {
- var u = i(66977),
- _ = i(38816),
- w = _(function (s, o) {
- return u(s, 256, void 0, void 0, void 0, o);
- });
- s.exports = w;
- },
- 40860: (s, o, i) => {
- var u = i(40882),
- _ = i(80909),
- w = i(15389),
- x = i(85558),
- C = i(56449);
- s.exports = function reduce(s, o, i) {
- var j = C(s) ? u : x,
- L = arguments.length < 3;
- return j(s, w(o, 4), i, L, _);
- };
- },
- 63560: (s, o, i) => {
- var u = i(73170);
- s.exports = function set(s, o, i) {
- return null == s ? s : u(s, o, i);
- };
- },
- 42426: (s, o, i) => {
- var u = i(14248),
- _ = i(15389),
- w = i(90916),
- x = i(56449),
- C = i(36800);
- s.exports = function some(s, o, i) {
- var j = x(s) ? u : w;
- return i && C(s, o, i) && (o = void 0), j(s, _(o, 3));
- };
- },
- 63345: (s) => {
- s.exports = function stubArray() {
- return [];
- };
- },
- 89935: (s) => {
- s.exports = function stubFalse() {
- return !1;
- };
- },
- 17400: (s, o, i) => {
- var u = i(99374),
- _ = 1 / 0;
- s.exports = function toFinite(s) {
- return s
- ? (s = u(s)) === _ || s === -1 / 0
- ? 17976931348623157e292 * (s < 0 ? -1 : 1)
- : s == s
- ? s
- : 0
- : 0 === s
- ? s
- : 0;
- };
- },
- 61489: (s, o, i) => {
- var u = i(17400);
- s.exports = function toInteger(s) {
- var o = u(s),
- i = o % 1;
- return o == o ? (i ? o - i : o) : 0;
- };
- },
- 80218: (s, o, i) => {
- var u = i(13222);
- s.exports = function toLower(s) {
- return u(s).toLowerCase();
- };
- },
- 99374: (s, o, i) => {
- var u = i(54128),
- _ = i(23805),
- w = i(44394),
- x = /^[-+]0x[0-9a-f]+$/i,
- C = /^0b[01]+$/i,
- j = /^0o[0-7]+$/i,
- L = parseInt;
- s.exports = function toNumber(s) {
- if ('number' == typeof s) return s;
- if (w(s)) return NaN;
- if (_(s)) {
- var o = 'function' == typeof s.valueOf ? s.valueOf() : s;
- s = _(o) ? o + '' : o;
- }
- if ('string' != typeof s) return 0 === s ? s : +s;
- s = u(s);
- var i = C.test(s);
- return i || j.test(s) ? L(s.slice(2), i ? 2 : 8) : x.test(s) ? NaN : +s;
- };
- },
- 42072: (s, o, i) => {
- var u = i(34932),
- _ = i(23007),
- w = i(56449),
- x = i(44394),
- C = i(61802),
- j = i(77797),
- L = i(13222);
- s.exports = function toPath(s) {
- return w(s) ? u(s, j) : x(s) ? [s] : _(C(L(s)));
- };
- },
- 69884: (s, o, i) => {
- var u = i(21791),
- _ = i(37241);
- s.exports = function toPlainObject(s) {
- return u(s, _(s));
- };
- },
- 13222: (s, o, i) => {
- var u = i(77556);
- s.exports = function toString(s) {
- return null == s ? '' : u(s);
- };
- },
- 55808: (s, o, i) => {
- var u = i(12507)('toUpperCase');
- s.exports = u;
- },
- 66645: (s, o, i) => {
- var u = i(1733),
- _ = i(45434),
- w = i(13222),
- x = i(22225);
- s.exports = function words(s, o, i) {
- return (
- (s = w(s)), void 0 === (o = i ? void 0 : o) ? (_(s) ? x(s) : u(s)) : s.match(o) || []
- );
- };
- },
- 53758: (s, o, i) => {
- var u = i(30980),
- _ = i(56017),
- w = i(94033),
- x = i(56449),
- C = i(40346),
- j = i(80257),
- L = Object.prototype.hasOwnProperty;
- function lodash(s) {
- if (C(s) && !x(s) && !(s instanceof u)) {
- if (s instanceof _) return s;
- if (L.call(s, '__wrapped__')) return j(s);
- }
- return new _(s);
- }
- (lodash.prototype = w.prototype),
- (lodash.prototype.constructor = lodash),
- (s.exports = lodash);
- },
- 47248: (s, o, i) => {
- var u = i(16547),
- _ = i(51234);
- s.exports = function zipObject(s, o) {
- return _(s || [], o || [], u);
- };
- },
- 43768: (s, o, i) => {
- 'use strict';
- var u = i(45981),
- _ = i(85587);
- (o.highlight = highlight),
- (o.highlightAuto = function highlightAuto(s, o) {
- var i,
- x,
- C,
- j,
- L = o || {},
- B = L.subset || u.listLanguages(),
- $ = L.prefix,
- V = B.length,
- U = -1;
- null == $ && ($ = w);
- if ('string' != typeof s) throw _('Expected `string` for value, got `%s`', s);
- (x = { relevance: 0, language: null, value: [] }),
- (i = { relevance: 0, language: null, value: [] });
- for (; ++U < V; )
- (j = B[U]),
- u.getLanguage(j) &&
- (((C = highlight(j, s, o)).language = j),
- C.relevance > x.relevance && (x = C),
- C.relevance > i.relevance && ((x = i), (i = C)));
- x.language && (i.secondBest = x);
- return i;
- }),
- (o.registerLanguage = function registerLanguage(s, o) {
- u.registerLanguage(s, o);
- }),
- (o.listLanguages = function listLanguages() {
- return u.listLanguages();
- }),
- (o.registerAlias = function registerAlias(s, o) {
- var i,
- _ = s;
- o && ((_ = {})[s] = o);
- for (i in _) u.registerAliases(_[i], { languageName: i });
- }),
- (Emitter.prototype.addText = function text(s) {
- var o,
- i,
- u = this.stack;
- if ('' === s) return;
- (o = u[u.length - 1]),
- (i = o.children[o.children.length - 1]) && 'text' === i.type
- ? (i.value += s)
- : o.children.push({ type: 'text', value: s });
- }),
- (Emitter.prototype.addKeyword = function addKeyword(s, o) {
- this.openNode(o), this.addText(s), this.closeNode();
- }),
- (Emitter.prototype.addSublanguage = function addSublanguage(s, o) {
- var i = this.stack,
- u = i[i.length - 1],
- _ = s.rootNode.children,
- w = o
- ? {
- type: 'element',
- tagName: 'span',
- properties: { className: [o] },
- children: _
- }
- : _;
- u.children = u.children.concat(w);
- }),
- (Emitter.prototype.openNode = function open(s) {
- var o = this.stack,
- i = this.options.classPrefix + s,
- u = o[o.length - 1],
- _ = {
- type: 'element',
- tagName: 'span',
- properties: { className: [i] },
- children: []
- };
- u.children.push(_), o.push(_);
- }),
- (Emitter.prototype.closeNode = function close() {
- this.stack.pop();
- }),
- (Emitter.prototype.closeAllNodes = noop),
- (Emitter.prototype.finalize = noop),
- (Emitter.prototype.toHTML = function toHtmlNoop() {
- return '';
- });
- var w = 'hljs-';
- function highlight(s, o, i) {
- var x,
- C = u.configure({}),
- j = (i || {}).prefix;
- if ('string' != typeof s) throw _('Expected `string` for name, got `%s`', s);
- if (!u.getLanguage(s)) throw _('Unknown language: `%s` is not registered', s);
- if ('string' != typeof o) throw _('Expected `string` for value, got `%s`', o);
- if (
- (null == j && (j = w),
- u.configure({ __emitter: Emitter, classPrefix: j }),
- (x = u.highlight(o, { language: s, ignoreIllegals: !0 })),
- u.configure(C || {}),
- x.errorRaised)
- )
- throw x.errorRaised;
- return {
- relevance: x.relevance,
- language: x.language,
- value: x.emitter.rootNode.children
- };
- }
- function Emitter(s) {
- (this.options = s), (this.rootNode = { children: [] }), (this.stack = [this.rootNode]);
- }
- function noop() {}
- },
- 92340: (s, o, i) => {
- const u = i(6048);
- function coerceElementMatchingCallback(s) {
- return 'string' == typeof s
- ? (o) => o.element === s
- : s.constructor && s.extend
- ? (o) => o instanceof s
- : s;
- }
- class ArraySlice {
- constructor(s) {
- this.elements = s || [];
- }
- toValue() {
- return this.elements.map((s) => s.toValue());
- }
- map(s, o) {
- return this.elements.map(s, o);
- }
- flatMap(s, o) {
- return this.map(s, o).reduce((s, o) => s.concat(o), []);
- }
- compactMap(s, o) {
- const i = [];
- return (
- this.forEach((u) => {
- const _ = s.bind(o)(u);
- _ && i.push(_);
- }),
- i
- );
- }
- filter(s, o) {
- return (
- (s = coerceElementMatchingCallback(s)), new ArraySlice(this.elements.filter(s, o))
- );
- }
- reject(s, o) {
- return (
- (s = coerceElementMatchingCallback(s)),
- new ArraySlice(this.elements.filter(u(s), o))
- );
- }
- find(s, o) {
- return (s = coerceElementMatchingCallback(s)), this.elements.find(s, o);
- }
- forEach(s, o) {
- this.elements.forEach(s, o);
- }
- reduce(s, o) {
- return this.elements.reduce(s, o);
- }
- includes(s) {
- return this.elements.some((o) => o.equals(s));
- }
- shift() {
- return this.elements.shift();
- }
- unshift(s) {
- this.elements.unshift(this.refract(s));
- }
- push(s) {
- return this.elements.push(this.refract(s)), this;
- }
- add(s) {
- this.push(s);
- }
- get(s) {
- return this.elements[s];
- }
- getValue(s) {
- const o = this.elements[s];
- if (o) return o.toValue();
- }
- get length() {
- return this.elements.length;
- }
- get isEmpty() {
- return 0 === this.elements.length;
- }
- get first() {
- return this.elements[0];
- }
- }
- 'undefined' != typeof Symbol &&
- (ArraySlice.prototype[Symbol.iterator] = function symbol() {
- return this.elements[Symbol.iterator]();
- }),
- (s.exports = ArraySlice);
- },
- 55973: (s) => {
- class KeyValuePair {
- constructor(s, o) {
- (this.key = s), (this.value = o);
- }
- clone() {
- const s = new KeyValuePair();
- return (
- this.key && (s.key = this.key.clone()),
- this.value && (s.value = this.value.clone()),
- s
- );
- }
- }
- s.exports = KeyValuePair;
- },
- 3110: (s, o, i) => {
- const u = i(5187),
- _ = i(85015),
- w = i(98023),
- x = i(53812),
- C = i(23805),
- j = i(85105),
- L = i(86804);
- class Namespace {
- constructor(s) {
- (this.elementMap = {}),
- (this.elementDetection = []),
- (this.Element = L.Element),
- (this.KeyValuePair = L.KeyValuePair),
- (s && s.noDefault) || this.useDefault(),
- (this._attributeElementKeys = []),
- (this._attributeElementArrayKeys = []);
- }
- use(s) {
- return (
- s.namespace && s.namespace({ base: this }), s.load && s.load({ base: this }), this
- );
- }
- useDefault() {
- return (
- this.register('null', L.NullElement)
- .register('string', L.StringElement)
- .register('number', L.NumberElement)
- .register('boolean', L.BooleanElement)
- .register('array', L.ArrayElement)
- .register('object', L.ObjectElement)
- .register('member', L.MemberElement)
- .register('ref', L.RefElement)
- .register('link', L.LinkElement),
- this.detect(u, L.NullElement, !1)
- .detect(_, L.StringElement, !1)
- .detect(w, L.NumberElement, !1)
- .detect(x, L.BooleanElement, !1)
- .detect(Array.isArray, L.ArrayElement, !1)
- .detect(C, L.ObjectElement, !1),
- this
- );
- }
- register(s, o) {
- return (this._elements = void 0), (this.elementMap[s] = o), this;
- }
- unregister(s) {
- return (this._elements = void 0), delete this.elementMap[s], this;
- }
- detect(s, o, i) {
- return (
- void 0 === i || i
- ? this.elementDetection.unshift([s, o])
- : this.elementDetection.push([s, o]),
- this
- );
- }
- toElement(s) {
- if (s instanceof this.Element) return s;
- let o;
- for (let i = 0; i < this.elementDetection.length; i += 1) {
- const u = this.elementDetection[i][0],
- _ = this.elementDetection[i][1];
- if (u(s)) {
- o = new _(s);
- break;
- }
- }
- return o;
- }
- getElementClass(s) {
- const o = this.elementMap[s];
- return void 0 === o ? this.Element : o;
- }
- fromRefract(s) {
- return this.serialiser.deserialise(s);
- }
- toRefract(s) {
- return this.serialiser.serialise(s);
- }
- get elements() {
- return (
- void 0 === this._elements &&
- ((this._elements = { Element: this.Element }),
- Object.keys(this.elementMap).forEach((s) => {
- const o = s[0].toUpperCase() + s.substr(1);
- this._elements[o] = this.elementMap[s];
- })),
- this._elements
- );
- }
- get serialiser() {
- return new j(this);
- }
- }
- (j.prototype.Namespace = Namespace), (s.exports = Namespace);
- },
- 10866: (s, o, i) => {
- const u = i(6048),
- _ = i(92340);
- class ObjectSlice extends _ {
- map(s, o) {
- return this.elements.map((i) => s.bind(o)(i.value, i.key, i));
- }
- filter(s, o) {
- return new ObjectSlice(this.elements.filter((i) => s.bind(o)(i.value, i.key, i)));
- }
- reject(s, o) {
- return this.filter(u(s.bind(o)));
- }
- forEach(s, o) {
- return this.elements.forEach((i, u) => {
- s.bind(o)(i.value, i.key, i, u);
- });
- }
- keys() {
- return this.map((s, o) => o.toValue());
- }
- values() {
- return this.map((s) => s.toValue());
- }
- }
- s.exports = ObjectSlice;
- },
- 86804: (s, o, i) => {
- const u = i(10316),
- _ = i(41067),
- w = i(71167),
- x = i(40239),
- C = i(12242),
- j = i(6233),
- L = i(87726),
- B = i(61045),
- $ = i(86303),
- V = i(14540),
- U = i(92340),
- z = i(10866),
- Y = i(55973);
- function refract(s) {
- if (s instanceof u) return s;
- if ('string' == typeof s) return new w(s);
- if ('number' == typeof s) return new x(s);
- if ('boolean' == typeof s) return new C(s);
- if (null === s) return new _();
- if (Array.isArray(s)) return new j(s.map(refract));
- if ('object' == typeof s) {
- return new B(s);
- }
- return s;
- }
- (u.prototype.ObjectElement = B),
- (u.prototype.RefElement = V),
- (u.prototype.MemberElement = L),
- (u.prototype.refract = refract),
- (U.prototype.refract = refract),
- (s.exports = {
- Element: u,
- NullElement: _,
- StringElement: w,
- NumberElement: x,
- BooleanElement: C,
- ArrayElement: j,
- MemberElement: L,
- ObjectElement: B,
- LinkElement: $,
- RefElement: V,
- refract,
- ArraySlice: U,
- ObjectSlice: z,
- KeyValuePair: Y
- });
- },
- 86303: (s, o, i) => {
- const u = i(10316);
- s.exports = class LinkElement extends u {
- constructor(s, o, i) {
- super(s || [], o, i), (this.element = 'link');
- }
- get relation() {
- return this.attributes.get('relation');
- }
- set relation(s) {
- this.attributes.set('relation', s);
- }
- get href() {
- return this.attributes.get('href');
- }
- set href(s) {
- this.attributes.set('href', s);
- }
- };
- },
- 14540: (s, o, i) => {
- const u = i(10316);
- s.exports = class RefElement extends u {
- constructor(s, o, i) {
- super(s || [], o, i), (this.element = 'ref'), this.path || (this.path = 'element');
- }
- get path() {
- return this.attributes.get('path');
- }
- set path(s) {
- this.attributes.set('path', s);
- }
- };
- },
- 34035: (s, o, i) => {
- const u = i(3110),
- _ = i(86804);
- (o.g$ = u),
- (o.KeyValuePair = i(55973)),
- (o.G6 = _.ArraySlice),
- (o.ot = _.ObjectSlice),
- (o.Hg = _.Element),
- (o.Om = _.StringElement),
- (o.kT = _.NumberElement),
- (o.bd = _.BooleanElement),
- (o.Os = _.NullElement),
- (o.wE = _.ArrayElement),
- (o.Sh = _.ObjectElement),
- (o.Pr = _.MemberElement),
- (o.sI = _.RefElement),
- (o.Ft = _.LinkElement),
- (o.e = _.refract),
- i(85105),
- i(75147);
- },
- 6233: (s, o, i) => {
- const u = i(6048),
- _ = i(10316),
- w = i(92340);
- class ArrayElement extends _ {
- constructor(s, o, i) {
- super(s || [], o, i), (this.element = 'array');
- }
- primitive() {
- return 'array';
- }
- get(s) {
- return this.content[s];
- }
- getValue(s) {
- const o = this.get(s);
- if (o) return o.toValue();
- }
- getIndex(s) {
- return this.content[s];
- }
- set(s, o) {
- return (this.content[s] = this.refract(o)), this;
- }
- remove(s) {
- const o = this.content.splice(s, 1);
- return o.length ? o[0] : null;
- }
- map(s, o) {
- return this.content.map(s, o);
- }
- flatMap(s, o) {
- return this.map(s, o).reduce((s, o) => s.concat(o), []);
- }
- compactMap(s, o) {
- const i = [];
- return (
- this.forEach((u) => {
- const _ = s.bind(o)(u);
- _ && i.push(_);
- }),
- i
- );
- }
- filter(s, o) {
- return new w(this.content.filter(s, o));
- }
- reject(s, o) {
- return this.filter(u(s), o);
- }
- reduce(s, o) {
- let i, u;
- void 0 !== o
- ? ((i = 0), (u = this.refract(o)))
- : ((i = 1), (u = 'object' === this.primitive() ? this.first.value : this.first));
- for (let o = i; o < this.length; o += 1) {
- const i = this.content[o];
- u =
- 'object' === this.primitive()
- ? this.refract(s(u, i.value, i.key, i, this))
- : this.refract(s(u, i, o, this));
- }
- return u;
- }
- forEach(s, o) {
- this.content.forEach((i, u) => {
- s.bind(o)(i, this.refract(u));
- });
- }
- shift() {
- return this.content.shift();
- }
- unshift(s) {
- this.content.unshift(this.refract(s));
- }
- push(s) {
- return this.content.push(this.refract(s)), this;
- }
- add(s) {
- this.push(s);
- }
- findElements(s, o) {
- const i = o || {},
- u = !!i.recursive,
- _ = void 0 === i.results ? [] : i.results;
- return (
- this.forEach((o, i, w) => {
- u && void 0 !== o.findElements && o.findElements(s, { results: _, recursive: u }),
- s(o, i, w) && _.push(o);
- }),
- _
- );
- }
- find(s) {
- return new w(this.findElements(s, { recursive: !0 }));
- }
- findByElement(s) {
- return this.find((o) => o.element === s);
- }
- findByClass(s) {
- return this.find((o) => o.classes.includes(s));
- }
- getById(s) {
- return this.find((o) => o.id.toValue() === s).first;
- }
- includes(s) {
- return this.content.some((o) => o.equals(s));
- }
- contains(s) {
- return this.includes(s);
- }
- empty() {
- return new this.constructor([]);
- }
- 'fantasy-land/empty'() {
- return this.empty();
- }
- concat(s) {
- return new this.constructor(this.content.concat(s.content));
- }
- 'fantasy-land/concat'(s) {
- return this.concat(s);
- }
- 'fantasy-land/map'(s) {
- return new this.constructor(this.map(s));
- }
- 'fantasy-land/chain'(s) {
- return this.map((o) => s(o), this).reduce((s, o) => s.concat(o), this.empty());
- }
- 'fantasy-land/filter'(s) {
- return new this.constructor(this.content.filter(s));
- }
- 'fantasy-land/reduce'(s, o) {
- return this.content.reduce(s, o);
- }
- get length() {
- return this.content.length;
- }
- get isEmpty() {
- return 0 === this.content.length;
- }
- get first() {
- return this.getIndex(0);
- }
- get second() {
- return this.getIndex(1);
- }
- get last() {
- return this.getIndex(this.length - 1);
- }
- }
- (ArrayElement.empty = function empty() {
- return new this();
- }),
- (ArrayElement['fantasy-land/empty'] = ArrayElement.empty),
- 'undefined' != typeof Symbol &&
- (ArrayElement.prototype[Symbol.iterator] = function symbol() {
- return this.content[Symbol.iterator]();
- }),
- (s.exports = ArrayElement);
- },
- 12242: (s, o, i) => {
- const u = i(10316);
- s.exports = class BooleanElement extends u {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'boolean');
- }
- primitive() {
- return 'boolean';
- }
- };
- },
- 10316: (s, o, i) => {
- const u = i(2404),
- _ = i(55973),
- w = i(92340);
- class Element {
- constructor(s, o, i) {
- o && (this.meta = o), i && (this.attributes = i), (this.content = s);
- }
- freeze() {
- Object.isFrozen(this) ||
- (this._meta && ((this.meta.parent = this), this.meta.freeze()),
- this._attributes && ((this.attributes.parent = this), this.attributes.freeze()),
- this.children.forEach((s) => {
- (s.parent = this), s.freeze();
- }, this),
- this.content && Array.isArray(this.content) && Object.freeze(this.content),
- Object.freeze(this));
- }
- primitive() {}
- clone() {
- const s = new this.constructor();
- return (
- (s.element = this.element),
- this.meta.length && (s._meta = this.meta.clone()),
- this.attributes.length && (s._attributes = this.attributes.clone()),
- this.content
- ? this.content.clone
- ? (s.content = this.content.clone())
- : Array.isArray(this.content)
- ? (s.content = this.content.map((s) => s.clone()))
- : (s.content = this.content)
- : (s.content = this.content),
- s
- );
- }
- toValue() {
- return this.content instanceof Element
- ? this.content.toValue()
- : this.content instanceof _
- ? {
- key: this.content.key.toValue(),
- value: this.content.value ? this.content.value.toValue() : void 0
- }
- : this.content && this.content.map
- ? this.content.map((s) => s.toValue(), this)
- : this.content;
- }
- toRef(s) {
- if ('' === this.id.toValue())
- throw Error('Cannot create reference to an element that does not contain an ID');
- const o = new this.RefElement(this.id.toValue());
- return s && (o.path = s), o;
- }
- findRecursive(...s) {
- if (arguments.length > 1 && !this.isFrozen)
- throw new Error(
- 'Cannot find recursive with multiple element names without first freezing the element. Call `element.freeze()`'
- );
- const o = s.pop();
- let i = new w();
- const append = (s, o) => (s.push(o), s),
- checkElement = (s, i) => {
- i.element === o && s.push(i);
- const u = i.findRecursive(o);
- return (
- u && u.reduce(append, s),
- i.content instanceof _ &&
- (i.content.key && checkElement(s, i.content.key),
- i.content.value && checkElement(s, i.content.value)),
- s
- );
- };
- return (
- this.content &&
- (this.content.element && checkElement(i, this.content),
- Array.isArray(this.content) && this.content.reduce(checkElement, i)),
- s.isEmpty ||
- (i = i.filter((o) => {
- let i = o.parents.map((s) => s.element);
- for (const o in s) {
- const u = s[o],
- _ = i.indexOf(u);
- if (-1 === _) return !1;
- i = i.splice(0, _);
- }
- return !0;
- })),
- i
- );
- }
- set(s) {
- return (this.content = s), this;
- }
- equals(s) {
- return u(this.toValue(), s);
- }
- getMetaProperty(s, o) {
- if (!this.meta.hasKey(s)) {
- if (this.isFrozen) {
- const s = this.refract(o);
- return s.freeze(), s;
- }
- this.meta.set(s, o);
- }
- return this.meta.get(s);
- }
- setMetaProperty(s, o) {
- this.meta.set(s, o);
- }
- get element() {
- return this._storedElement || 'element';
- }
- set element(s) {
- this._storedElement = s;
- }
- get content() {
- return this._content;
- }
- set content(s) {
- if (s instanceof Element) this._content = s;
- else if (s instanceof w) this.content = s.elements;
- else if (
- 'string' == typeof s ||
- 'number' == typeof s ||
- 'boolean' == typeof s ||
- 'null' === s ||
- null == s
- )
- this._content = s;
- else if (s instanceof _) this._content = s;
- else if (Array.isArray(s)) this._content = s.map(this.refract);
- else {
- if ('object' != typeof s) throw new Error('Cannot set content to given value');
- this._content = Object.keys(s).map((o) => new this.MemberElement(o, s[o]));
- }
- }
- get meta() {
- if (!this._meta) {
- if (this.isFrozen) {
- const s = new this.ObjectElement();
- return s.freeze(), s;
- }
- this._meta = new this.ObjectElement();
- }
- return this._meta;
- }
- set meta(s) {
- s instanceof this.ObjectElement ? (this._meta = s) : this.meta.set(s || {});
- }
- get attributes() {
- if (!this._attributes) {
- if (this.isFrozen) {
- const s = new this.ObjectElement();
- return s.freeze(), s;
- }
- this._attributes = new this.ObjectElement();
- }
- return this._attributes;
- }
- set attributes(s) {
- s instanceof this.ObjectElement
- ? (this._attributes = s)
- : this.attributes.set(s || {});
- }
- get id() {
- return this.getMetaProperty('id', '');
- }
- set id(s) {
- this.setMetaProperty('id', s);
- }
- get classes() {
- return this.getMetaProperty('classes', []);
- }
- set classes(s) {
- this.setMetaProperty('classes', s);
- }
- get title() {
- return this.getMetaProperty('title', '');
- }
- set title(s) {
- this.setMetaProperty('title', s);
- }
- get description() {
- return this.getMetaProperty('description', '');
- }
- set description(s) {
- this.setMetaProperty('description', s);
- }
- get links() {
- return this.getMetaProperty('links', []);
- }
- set links(s) {
- this.setMetaProperty('links', s);
- }
- get isFrozen() {
- return Object.isFrozen(this);
- }
- get parents() {
- let { parent: s } = this;
- const o = new w();
- for (; s; ) o.push(s), (s = s.parent);
- return o;
- }
- get children() {
- if (Array.isArray(this.content)) return new w(this.content);
- if (this.content instanceof _) {
- const s = new w([this.content.key]);
- return this.content.value && s.push(this.content.value), s;
- }
- return this.content instanceof Element ? new w([this.content]) : new w();
- }
- get recursiveChildren() {
- const s = new w();
- return (
- this.children.forEach((o) => {
- s.push(o),
- o.recursiveChildren.forEach((o) => {
- s.push(o);
- });
- }),
- s
- );
- }
- }
- s.exports = Element;
- },
- 87726: (s, o, i) => {
- const u = i(55973),
- _ = i(10316);
- s.exports = class MemberElement extends _ {
- constructor(s, o, i, _) {
- super(new u(), i, _), (this.element = 'member'), (this.key = s), (this.value = o);
- }
- get key() {
- return this.content.key;
- }
- set key(s) {
- this.content.key = this.refract(s);
- }
- get value() {
- return this.content.value;
- }
- set value(s) {
- this.content.value = this.refract(s);
- }
- };
- },
- 41067: (s, o, i) => {
- const u = i(10316);
- s.exports = class NullElement extends u {
- constructor(s, o, i) {
- super(s || null, o, i), (this.element = 'null');
- }
- primitive() {
- return 'null';
- }
- set() {
- return new Error('Cannot set the value of null');
- }
- };
- },
- 40239: (s, o, i) => {
- const u = i(10316);
- s.exports = class NumberElement extends u {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'number');
- }
- primitive() {
- return 'number';
- }
- };
- },
- 61045: (s, o, i) => {
- const u = i(6048),
- _ = i(23805),
- w = i(6233),
- x = i(87726),
- C = i(10866);
- s.exports = class ObjectElement extends w {
- constructor(s, o, i) {
- super(s || [], o, i), (this.element = 'object');
- }
- primitive() {
- return 'object';
- }
- toValue() {
- return this.content.reduce(
- (s, o) => ((s[o.key.toValue()] = o.value ? o.value.toValue() : void 0), s),
- {}
- );
- }
- get(s) {
- const o = this.getMember(s);
- if (o) return o.value;
- }
- getMember(s) {
- if (void 0 !== s) return this.content.find((o) => o.key.toValue() === s);
- }
- remove(s) {
- let o = null;
- return (
- (this.content = this.content.filter((i) => i.key.toValue() !== s || ((o = i), !1))),
- o
- );
- }
- getKey(s) {
- const o = this.getMember(s);
- if (o) return o.key;
- }
- set(s, o) {
- if (_(s))
- return (
- Object.keys(s).forEach((o) => {
- this.set(o, s[o]);
- }),
- this
- );
- const i = s,
- u = this.getMember(i);
- return u ? (u.value = o) : this.content.push(new x(i, o)), this;
- }
- keys() {
- return this.content.map((s) => s.key.toValue());
- }
- values() {
- return this.content.map((s) => s.value.toValue());
- }
- hasKey(s) {
- return this.content.some((o) => o.key.equals(s));
- }
- items() {
- return this.content.map((s) => [s.key.toValue(), s.value.toValue()]);
- }
- map(s, o) {
- return this.content.map((i) => s.bind(o)(i.value, i.key, i));
- }
- compactMap(s, o) {
- const i = [];
- return (
- this.forEach((u, _, w) => {
- const x = s.bind(o)(u, _, w);
- x && i.push(x);
- }),
- i
- );
- }
- filter(s, o) {
- return new C(this.content).filter(s, o);
- }
- reject(s, o) {
- return this.filter(u(s), o);
- }
- forEach(s, o) {
- return this.content.forEach((i) => s.bind(o)(i.value, i.key, i));
- }
- };
- },
- 71167: (s, o, i) => {
- const u = i(10316);
- s.exports = class StringElement extends u {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'string');
- }
- primitive() {
- return 'string';
- }
- get length() {
- return this.content.length;
- }
- };
- },
- 75147: (s, o, i) => {
- const u = i(85105);
- s.exports = class JSON06Serialiser extends u {
- serialise(s) {
- if (!(s instanceof this.namespace.elements.Element))
- throw new TypeError(`Given element \`${s}\` is not an Element instance`);
- let o;
- s._attributes && s.attributes.get('variable') && (o = s.attributes.get('variable'));
- const i = { element: s.element };
- s._meta && s._meta.length > 0 && (i.meta = this.serialiseObject(s.meta));
- const u = 'enum' === s.element || -1 !== s.attributes.keys().indexOf('enumerations');
- if (u) {
- const o = this.enumSerialiseAttributes(s);
- o && (i.attributes = o);
- } else if (s._attributes && s._attributes.length > 0) {
- let { attributes: u } = s;
- u.get('metadata') &&
- ((u = u.clone()), u.set('meta', u.get('metadata')), u.remove('metadata')),
- 'member' === s.element && o && ((u = u.clone()), u.remove('variable')),
- u.length > 0 && (i.attributes = this.serialiseObject(u));
- }
- if (u) i.content = this.enumSerialiseContent(s, i);
- else if (this[`${s.element}SerialiseContent`])
- i.content = this[`${s.element}SerialiseContent`](s, i);
- else if (void 0 !== s.content) {
- let u;
- o && s.content.key
- ? ((u = s.content.clone()),
- u.key.attributes.set('variable', o),
- (u = this.serialiseContent(u)))
- : (u = this.serialiseContent(s.content)),
- this.shouldSerialiseContent(s, u) && (i.content = u);
- } else
- this.shouldSerialiseContent(s, s.content) &&
- s instanceof this.namespace.elements.Array &&
- (i.content = []);
- return i;
- }
- shouldSerialiseContent(s, o) {
- return (
- 'parseResult' === s.element ||
- 'httpRequest' === s.element ||
- 'httpResponse' === s.element ||
- 'category' === s.element ||
- 'link' === s.element ||
- (void 0 !== o && (!Array.isArray(o) || 0 !== o.length))
- );
- }
- refSerialiseContent(s, o) {
- return delete o.attributes, { href: s.toValue(), path: s.path.toValue() };
- }
- sourceMapSerialiseContent(s) {
- return s.toValue();
- }
- dataStructureSerialiseContent(s) {
- return [this.serialiseContent(s.content)];
- }
- enumSerialiseAttributes(s) {
- const o = s.attributes.clone(),
- i = o.remove('enumerations') || new this.namespace.elements.Array([]),
- u = o.get('default');
- let _ = o.get('samples') || new this.namespace.elements.Array([]);
- if (
- (u &&
- u.content &&
- (u.content.attributes && u.content.attributes.remove('typeAttributes'),
- o.set('default', new this.namespace.elements.Array([u.content]))),
- _.forEach((s) => {
- s.content && s.content.element && s.content.attributes.remove('typeAttributes');
- }),
- s.content && 0 !== i.length && _.unshift(s.content),
- (_ = _.map((s) =>
- s instanceof this.namespace.elements.Array
- ? [s]
- : new this.namespace.elements.Array([s.content])
- )),
- _.length && o.set('samples', _),
- o.length > 0)
- )
- return this.serialiseObject(o);
- }
- enumSerialiseContent(s) {
- if (s._attributes) {
- const o = s.attributes.get('enumerations');
- if (o && o.length > 0)
- return o.content.map((s) => {
- const o = s.clone();
- return o.attributes.remove('typeAttributes'), this.serialise(o);
- });
- }
- if (s.content) {
- const o = s.content.clone();
- return o.attributes.remove('typeAttributes'), [this.serialise(o)];
- }
- return [];
- }
- deserialise(s) {
- if ('string' == typeof s) return new this.namespace.elements.String(s);
- if ('number' == typeof s) return new this.namespace.elements.Number(s);
- if ('boolean' == typeof s) return new this.namespace.elements.Boolean(s);
- if (null === s) return new this.namespace.elements.Null();
- if (Array.isArray(s))
- return new this.namespace.elements.Array(s.map(this.deserialise, this));
- const o = this.namespace.getElementClass(s.element),
- i = new o();
- i.element !== s.element && (i.element = s.element),
- s.meta && this.deserialiseObject(s.meta, i.meta),
- s.attributes && this.deserialiseObject(s.attributes, i.attributes);
- const u = this.deserialiseContent(s.content);
- if (((void 0 === u && null !== i.content) || (i.content = u), 'enum' === i.element)) {
- i.content && i.attributes.set('enumerations', i.content);
- let s = i.attributes.get('samples');
- if ((i.attributes.remove('samples'), s)) {
- const u = s;
- (s = new this.namespace.elements.Array()),
- u.forEach((u) => {
- u.forEach((u) => {
- const _ = new o(u);
- (_.element = i.element), s.push(_);
- });
- });
- const _ = s.shift();
- (i.content = _ ? _.content : void 0), i.attributes.set('samples', s);
- } else i.content = void 0;
- let u = i.attributes.get('default');
- if (u && u.length > 0) {
- u = u.get(0);
- const s = new o(u);
- (s.element = i.element), i.attributes.set('default', s);
- }
- } else if ('dataStructure' === i.element && Array.isArray(i.content))
- [i.content] = i.content;
- else if ('category' === i.element) {
- const s = i.attributes.get('meta');
- s && (i.attributes.set('metadata', s), i.attributes.remove('meta'));
- } else
- 'member' === i.element &&
- i.key &&
- i.key._attributes &&
- i.key._attributes.getValue('variable') &&
- (i.attributes.set('variable', i.key.attributes.get('variable')),
- i.key.attributes.remove('variable'));
- return i;
- }
- serialiseContent(s) {
- if (s instanceof this.namespace.elements.Element) return this.serialise(s);
- if (s instanceof this.namespace.KeyValuePair) {
- const o = { key: this.serialise(s.key) };
- return s.value && (o.value = this.serialise(s.value)), o;
- }
- return s && s.map ? s.map(this.serialise, this) : s;
- }
- deserialiseContent(s) {
- if (s) {
- if (s.element) return this.deserialise(s);
- if (s.key) {
- const o = new this.namespace.KeyValuePair(this.deserialise(s.key));
- return s.value && (o.value = this.deserialise(s.value)), o;
- }
- if (s.map) return s.map(this.deserialise, this);
- }
- return s;
- }
- shouldRefract(s) {
- return (
- !!(
- (s._attributes && s.attributes.keys().length) ||
- (s._meta && s.meta.keys().length)
- ) ||
- ('enum' !== s.element && (s.element !== s.primitive() || 'member' === s.element))
- );
- }
- convertKeyToRefract(s, o) {
- return this.shouldRefract(o)
- ? this.serialise(o)
- : 'enum' === o.element
- ? this.serialiseEnum(o)
- : 'array' === o.element
- ? o.map((o) =>
- this.shouldRefract(o) || 'default' === s
- ? this.serialise(o)
- : 'array' === o.element || 'object' === o.element || 'enum' === o.element
- ? o.children.map((s) => this.serialise(s))
- : o.toValue()
- )
- : 'object' === o.element
- ? (o.content || []).map(this.serialise, this)
- : o.toValue();
- }
- serialiseEnum(s) {
- return s.children.map((s) => this.serialise(s));
- }
- serialiseObject(s) {
- const o = {};
- return (
- s.forEach((s, i) => {
- if (s) {
- const u = i.toValue();
- o[u] = this.convertKeyToRefract(u, s);
- }
- }),
- o
- );
- }
- deserialiseObject(s, o) {
- Object.keys(s).forEach((i) => {
- o.set(i, this.deserialise(s[i]));
- });
- }
- };
- },
- 85105: (s) => {
- s.exports = class JSONSerialiser {
- constructor(s) {
- this.namespace = s || new this.Namespace();
- }
- serialise(s) {
- if (!(s instanceof this.namespace.elements.Element))
- throw new TypeError(`Given element \`${s}\` is not an Element instance`);
- const o = { element: s.element };
- s._meta && s._meta.length > 0 && (o.meta = this.serialiseObject(s.meta)),
- s._attributes &&
- s._attributes.length > 0 &&
- (o.attributes = this.serialiseObject(s.attributes));
- const i = this.serialiseContent(s.content);
- return void 0 !== i && (o.content = i), o;
- }
- deserialise(s) {
- if (!s.element)
- throw new Error('Given value is not an object containing an element name');
- const o = new (this.namespace.getElementClass(s.element))();
- o.element !== s.element && (o.element = s.element),
- s.meta && this.deserialiseObject(s.meta, o.meta),
- s.attributes && this.deserialiseObject(s.attributes, o.attributes);
- const i = this.deserialiseContent(s.content);
- return (void 0 === i && null !== o.content) || (o.content = i), o;
- }
- serialiseContent(s) {
- if (s instanceof this.namespace.elements.Element) return this.serialise(s);
- if (s instanceof this.namespace.KeyValuePair) {
- const o = { key: this.serialise(s.key) };
- return s.value && (o.value = this.serialise(s.value)), o;
- }
- if (s && s.map) {
- if (0 === s.length) return;
- return s.map(this.serialise, this);
- }
- return s;
- }
- deserialiseContent(s) {
- if (s) {
- if (s.element) return this.deserialise(s);
- if (s.key) {
- const o = new this.namespace.KeyValuePair(this.deserialise(s.key));
- return s.value && (o.value = this.deserialise(s.value)), o;
- }
- if (s.map) return s.map(this.deserialise, this);
- }
- return s;
- }
- serialiseObject(s) {
- const o = {};
- if (
- (s.forEach((s, i) => {
- s && (o[i.toValue()] = this.serialise(s));
- }),
- 0 !== Object.keys(o).length)
- )
- return o;
- }
- deserialiseObject(s, o) {
- Object.keys(s).forEach((i) => {
- o.set(i, this.deserialise(s[i]));
- });
- }
- };
- },
- 65606: (s) => {
- var o,
- i,
- u = (s.exports = {});
- function defaultSetTimout() {
- throw new Error('setTimeout has not been defined');
- }
- function defaultClearTimeout() {
- throw new Error('clearTimeout has not been defined');
- }
- function runTimeout(s) {
- if (o === setTimeout) return setTimeout(s, 0);
- if ((o === defaultSetTimout || !o) && setTimeout)
- return (o = setTimeout), setTimeout(s, 0);
- try {
- return o(s, 0);
- } catch (i) {
- try {
- return o.call(null, s, 0);
- } catch (i) {
- return o.call(this, s, 0);
- }
- }
- }
- !(function () {
- try {
- o = 'function' == typeof setTimeout ? setTimeout : defaultSetTimout;
- } catch (s) {
- o = defaultSetTimout;
- }
- try {
- i = 'function' == typeof clearTimeout ? clearTimeout : defaultClearTimeout;
- } catch (s) {
- i = defaultClearTimeout;
- }
- })();
- var _,
- w = [],
- x = !1,
- C = -1;
- function cleanUpNextTick() {
- x && _ && ((x = !1), _.length ? (w = _.concat(w)) : (C = -1), w.length && drainQueue());
- }
- function drainQueue() {
- if (!x) {
- var s = runTimeout(cleanUpNextTick);
- x = !0;
- for (var o = w.length; o; ) {
- for (_ = w, w = []; ++C < o; ) _ && _[C].run();
- (C = -1), (o = w.length);
- }
- (_ = null),
- (x = !1),
- (function runClearTimeout(s) {
- if (i === clearTimeout) return clearTimeout(s);
- if ((i === defaultClearTimeout || !i) && clearTimeout)
- return (i = clearTimeout), clearTimeout(s);
- try {
- return i(s);
- } catch (o) {
- try {
- return i.call(null, s);
- } catch (o) {
- return i.call(this, s);
- }
- }
- })(s);
- }
- }
- function Item(s, o) {
- (this.fun = s), (this.array = o);
- }
- function noop() {}
- (u.nextTick = function (s) {
- var o = new Array(arguments.length - 1);
- if (arguments.length > 1)
- for (var i = 1; i < arguments.length; i++) o[i - 1] = arguments[i];
- w.push(new Item(s, o)), 1 !== w.length || x || runTimeout(drainQueue);
- }),
- (Item.prototype.run = function () {
- this.fun.apply(null, this.array);
- }),
- (u.title = 'browser'),
- (u.browser = !0),
- (u.env = {}),
- (u.argv = []),
- (u.version = ''),
- (u.versions = {}),
- (u.on = noop),
- (u.addListener = noop),
- (u.once = noop),
- (u.off = noop),
- (u.removeListener = noop),
- (u.removeAllListeners = noop),
- (u.emit = noop),
- (u.prependListener = noop),
- (u.prependOnceListener = noop),
- (u.listeners = function (s) {
- return [];
- }),
- (u.binding = function (s) {
- throw new Error('process.binding is not supported');
- }),
- (u.cwd = function () {
- return '/';
- }),
- (u.chdir = function (s) {
- throw new Error('process.chdir is not supported');
- }),
- (u.umask = function () {
- return 0;
- });
- },
- 2694: (s, o, i) => {
- 'use strict';
- var u = i(6925);
- function emptyFunction() {}
- function emptyFunctionWithReset() {}
- (emptyFunctionWithReset.resetWarningCache = emptyFunction),
- (s.exports = function () {
- function shim(s, o, i, _, w, x) {
- if (x !== u) {
- var C = new Error(
- 'Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types'
- );
- throw ((C.name = 'Invariant Violation'), C);
- }
- }
- function getShim() {
- return shim;
- }
- shim.isRequired = shim;
- var s = {
- array: shim,
- bigint: shim,
- bool: shim,
- func: shim,
- number: shim,
- object: shim,
- string: shim,
- symbol: shim,
- any: shim,
- arrayOf: getShim,
- element: shim,
- elementType: shim,
- instanceOf: getShim,
- node: shim,
- objectOf: getShim,
- oneOf: getShim,
- oneOfType: getShim,
- shape: getShim,
- exact: getShim,
- checkPropTypes: emptyFunctionWithReset,
- resetWarningCache: emptyFunction
- };
- return (s.PropTypes = s), s;
- });
- },
- 5556: (s, o, i) => {
- s.exports = i(2694)();
- },
- 6925: (s) => {
- 'use strict';
- s.exports = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';
- },
- 73992: (s, o) => {
- 'use strict';
- var i = Object.prototype.hasOwnProperty;
- function decode(s) {
- try {
- return decodeURIComponent(s.replace(/\+/g, ' '));
- } catch (s) {
- return null;
- }
- }
- function encode(s) {
- try {
- return encodeURIComponent(s);
- } catch (s) {
- return null;
- }
- }
- (o.stringify = function querystringify(s, o) {
- o = o || '';
- var u,
- _,
- w = [];
- for (_ in ('string' != typeof o && (o = '?'), s))
- if (i.call(s, _)) {
- if (
- ((u = s[_]) || (null != u && !isNaN(u)) || (u = ''),
- (_ = encode(_)),
- (u = encode(u)),
- null === _ || null === u)
- )
- continue;
- w.push(_ + '=' + u);
- }
- return w.length ? o + w.join('&') : '';
- }),
- (o.parse = function querystring(s) {
- for (var o, i = /([^=?#&]+)=?([^&]*)/g, u = {}; (o = i.exec(s)); ) {
- var _ = decode(o[1]),
- w = decode(o[2]);
- null === _ || null === w || _ in u || (u[_] = w);
- }
- return u;
- });
- },
- 41859: (s, o, i) => {
- const u = i(27096),
- _ = i(78004),
- w = u.types;
- s.exports = class RandExp {
- constructor(s, o) {
- if ((this._setDefaults(s), s instanceof RegExp))
- (this.ignoreCase = s.ignoreCase), (this.multiline = s.multiline), (s = s.source);
- else {
- if ('string' != typeof s) throw new Error('Expected a regexp or string');
- (this.ignoreCase = o && -1 !== o.indexOf('i')),
- (this.multiline = o && -1 !== o.indexOf('m'));
- }
- this.tokens = u(s);
- }
- _setDefaults(s) {
- (this.max =
- null != s.max
- ? s.max
- : null != RandExp.prototype.max
- ? RandExp.prototype.max
- : 100),
- (this.defaultRange = s.defaultRange ? s.defaultRange : this.defaultRange.clone()),
- s.randInt && (this.randInt = s.randInt);
- }
- gen() {
- return this._gen(this.tokens, []);
- }
- _gen(s, o) {
- var i, u, _, x, C;
- switch (s.type) {
- case w.ROOT:
- case w.GROUP:
- if (s.followedBy || s.notFollowedBy) return '';
- for (
- s.remember && void 0 === s.groupNumber && (s.groupNumber = o.push(null) - 1),
- u = '',
- x = 0,
- C = (i = s.options ? this._randSelect(s.options) : s.stack).length;
- x < C;
- x++
- )
- u += this._gen(i[x], o);
- return s.remember && (o[s.groupNumber] = u), u;
- case w.POSITION:
- return '';
- case w.SET:
- var j = this._expand(s);
- return j.length ? String.fromCharCode(this._randSelect(j)) : '';
- case w.REPETITION:
- for (
- _ = this.randInt(s.min, s.max === 1 / 0 ? s.min + this.max : s.max),
- u = '',
- x = 0;
- x < _;
- x++
- )
- u += this._gen(s.value, o);
- return u;
- case w.REFERENCE:
- return o[s.value - 1] || '';
- case w.CHAR:
- var L =
- this.ignoreCase && this._randBool() ? this._toOtherCase(s.value) : s.value;
- return String.fromCharCode(L);
- }
- }
- _toOtherCase(s) {
- return s + (97 <= s && s <= 122 ? -32 : 65 <= s && s <= 90 ? 32 : 0);
- }
- _randBool() {
- return !this.randInt(0, 1);
- }
- _randSelect(s) {
- return s instanceof _
- ? s.index(this.randInt(0, s.length - 1))
- : s[this.randInt(0, s.length - 1)];
- }
- _expand(s) {
- if (s.type === u.types.CHAR) return new _(s.value);
- if (s.type === u.types.RANGE) return new _(s.from, s.to);
- {
- let o = new _();
- for (let i = 0; i < s.set.length; i++) {
- let u = this._expand(s.set[i]);
- if ((o.add(u), this.ignoreCase))
- for (let s = 0; s < u.length; s++) {
- let i = u.index(s),
- _ = this._toOtherCase(i);
- i !== _ && o.add(_);
- }
- }
- return s.not
- ? this.defaultRange.clone().subtract(o)
- : this.defaultRange.clone().intersect(o);
- }
- }
- randInt(s, o) {
- return s + Math.floor(Math.random() * (1 + o - s));
- }
- get defaultRange() {
- return (this._range = this._range || new _(32, 126));
- }
- set defaultRange(s) {
- this._range = s;
- }
- static randexp(s, o) {
- var i;
- return (
- 'string' == typeof s && (s = new RegExp(s, o)),
- void 0 === s._randexp
- ? ((i = new RandExp(s, o)), (s._randexp = i))
- : (i = s._randexp)._setDefaults(s),
- i.gen()
- );
- }
- static sugar() {
- RegExp.prototype.gen = function () {
- return RandExp.randexp(this);
- };
- }
- };
- },
- 53209: (s, o, i) => {
- 'use strict';
- var u = i(65606),
- _ = 65536,
- w = 4294967295;
- var x = i(92861).Buffer,
- C = i.g.crypto || i.g.msCrypto;
- C && C.getRandomValues
- ? (s.exports = function randomBytes(s, o) {
- if (s > w) throw new RangeError('requested too many random bytes');
- var i = x.allocUnsafe(s);
- if (s > 0)
- if (s > _) for (var j = 0; j < s; j += _) C.getRandomValues(i.slice(j, j + _));
- else C.getRandomValues(i);
- if ('function' == typeof o)
- return u.nextTick(function () {
- o(null, i);
- });
- return i;
- })
- : (s.exports = function oldBrowser() {
- throw new Error(
- 'Secure random number generation is not supported by this browser.\nUse Chrome, Firefox or Internet Explorer 11'
- );
- });
- },
- 25264: (s, o, i) => {
- 'use strict';
- function _typeof(s) {
- return (
- (_typeof =
- 'function' == typeof Symbol && 'symbol' == typeof Symbol.iterator
- ? function (s) {
- return typeof s;
- }
- : function (s) {
- return s &&
- 'function' == typeof Symbol &&
- s.constructor === Symbol &&
- s !== Symbol.prototype
- ? 'symbol'
- : typeof s;
- }),
- _typeof(s)
- );
- }
- Object.defineProperty(o, '__esModule', { value: !0 }), (o.CopyToClipboard = void 0);
- var u = _interopRequireDefault(i(96540)),
- _ = _interopRequireDefault(i(17965)),
- w = ['text', 'onCopy', 'options', 'children'];
- function _interopRequireDefault(s) {
- return s && s.__esModule ? s : { default: s };
- }
- function ownKeys(s, o) {
- var i = Object.keys(s);
- if (Object.getOwnPropertySymbols) {
- var u = Object.getOwnPropertySymbols(s);
- o &&
- (u = u.filter(function (o) {
- return Object.getOwnPropertyDescriptor(s, o).enumerable;
- })),
- i.push.apply(i, u);
- }
- return i;
- }
- function _objectSpread(s) {
- for (var o = 1; o < arguments.length; o++) {
- var i = null != arguments[o] ? arguments[o] : {};
- o % 2
- ? ownKeys(Object(i), !0).forEach(function (o) {
- _defineProperty(s, o, i[o]);
- })
- : Object.getOwnPropertyDescriptors
- ? Object.defineProperties(s, Object.getOwnPropertyDescriptors(i))
- : ownKeys(Object(i)).forEach(function (o) {
- Object.defineProperty(s, o, Object.getOwnPropertyDescriptor(i, o));
- });
- }
- return s;
- }
- function _objectWithoutProperties(s, o) {
- if (null == s) return {};
- var i,
- u,
- _ = (function _objectWithoutPropertiesLoose(s, o) {
- if (null == s) return {};
- var i,
- u,
- _ = {},
- w = Object.keys(s);
- for (u = 0; u < w.length; u++) (i = w[u]), o.indexOf(i) >= 0 || (_[i] = s[i]);
- return _;
- })(s, o);
- if (Object.getOwnPropertySymbols) {
- var w = Object.getOwnPropertySymbols(s);
- for (u = 0; u < w.length; u++)
- (i = w[u]),
- o.indexOf(i) >= 0 ||
- (Object.prototype.propertyIsEnumerable.call(s, i) && (_[i] = s[i]));
- }
- return _;
- }
- function _defineProperties(s, o) {
- for (var i = 0; i < o.length; i++) {
- var u = o[i];
- (u.enumerable = u.enumerable || !1),
- (u.configurable = !0),
- 'value' in u && (u.writable = !0),
- Object.defineProperty(s, u.key, u);
- }
- }
- function _setPrototypeOf(s, o) {
- return (
- (_setPrototypeOf =
- Object.setPrototypeOf ||
- function _setPrototypeOf(s, o) {
- return (s.__proto__ = o), s;
- }),
- _setPrototypeOf(s, o)
- );
- }
- function _createSuper(s) {
- var o = (function _isNativeReflectConstruct() {
- if ('undefined' == typeof Reflect || !Reflect.construct) return !1;
- if (Reflect.construct.sham) return !1;
- if ('function' == typeof Proxy) return !0;
- try {
- return (
- Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})), !0
- );
- } catch (s) {
- return !1;
- }
- })();
- return function _createSuperInternal() {
- var i,
- u = _getPrototypeOf(s);
- if (o) {
- var _ = _getPrototypeOf(this).constructor;
- i = Reflect.construct(u, arguments, _);
- } else i = u.apply(this, arguments);
- return (function _possibleConstructorReturn(s, o) {
- if (o && ('object' === _typeof(o) || 'function' == typeof o)) return o;
- if (void 0 !== o)
- throw new TypeError('Derived constructors may only return object or undefined');
- return _assertThisInitialized(s);
- })(this, i);
- };
- }
- function _assertThisInitialized(s) {
- if (void 0 === s)
- throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
- return s;
- }
- function _getPrototypeOf(s) {
- return (
- (_getPrototypeOf = Object.setPrototypeOf
- ? Object.getPrototypeOf
- : function _getPrototypeOf(s) {
- return s.__proto__ || Object.getPrototypeOf(s);
- }),
- _getPrototypeOf(s)
- );
- }
- function _defineProperty(s, o, i) {
- return (
- o in s
- ? Object.defineProperty(s, o, {
- value: i,
- enumerable: !0,
- configurable: !0,
- writable: !0
- })
- : (s[o] = i),
- s
- );
- }
- var x = (function (s) {
- !(function _inherits(s, o) {
- if ('function' != typeof o && null !== o)
- throw new TypeError('Super expression must either be null or a function');
- (s.prototype = Object.create(o && o.prototype, {
- constructor: { value: s, writable: !0, configurable: !0 }
- })),
- Object.defineProperty(s, 'prototype', { writable: !1 }),
- o && _setPrototypeOf(s, o);
- })(CopyToClipboard, s);
- var o = _createSuper(CopyToClipboard);
- function CopyToClipboard() {
- var s;
- !(function _classCallCheck(s, o) {
- if (!(s instanceof o)) throw new TypeError('Cannot call a class as a function');
- })(this, CopyToClipboard);
- for (var i = arguments.length, w = new Array(i), x = 0; x < i; x++)
- w[x] = arguments[x];
- return (
- _defineProperty(
- _assertThisInitialized((s = o.call.apply(o, [this].concat(w)))),
- 'onClick',
- function (o) {
- var i = s.props,
- w = i.text,
- x = i.onCopy,
- C = i.children,
- j = i.options,
- L = u.default.Children.only(C),
- B = (0, _.default)(w, j);
- x && x(w, B),
- L && L.props && 'function' == typeof L.props.onClick && L.props.onClick(o);
- }
- ),
- s
- );
- }
- return (
- (function _createClass(s, o, i) {
- return (
- o && _defineProperties(s.prototype, o),
- i && _defineProperties(s, i),
- Object.defineProperty(s, 'prototype', { writable: !1 }),
- s
- );
- })(CopyToClipboard, [
- {
- key: 'render',
- value: function render() {
- var s = this.props,
- o = (s.text, s.onCopy, s.options, s.children),
- i = _objectWithoutProperties(s, w),
- _ = u.default.Children.only(o);
- return u.default.cloneElement(
- _,
- _objectSpread(_objectSpread({}, i), {}, { onClick: this.onClick })
- );
- }
- }
- ]),
- CopyToClipboard
- );
- })(u.default.PureComponent);
- (o.CopyToClipboard = x),
- _defineProperty(x, 'defaultProps', { onCopy: void 0, options: void 0 });
- },
- 59399: (s, o, i) => {
- 'use strict';
- var u = i(25264).CopyToClipboard;
- (u.CopyToClipboard = u), (s.exports = u);
- },
- 81214: (s, o, i) => {
- 'use strict';
- function _typeof(s) {
- return (
- (_typeof =
- 'function' == typeof Symbol && 'symbol' == typeof Symbol.iterator
- ? function (s) {
- return typeof s;
- }
- : function (s) {
- return s &&
- 'function' == typeof Symbol &&
- s.constructor === Symbol &&
- s !== Symbol.prototype
- ? 'symbol'
- : typeof s;
- }),
- _typeof(s)
- );
- }
- Object.defineProperty(o, '__esModule', { value: !0 }), (o.DebounceInput = void 0);
- var u = _interopRequireDefault(i(96540)),
- _ = _interopRequireDefault(i(20181)),
- w = [
- 'element',
- 'onChange',
- 'value',
- 'minLength',
- 'debounceTimeout',
- 'forceNotifyByEnter',
- 'forceNotifyOnBlur',
- 'onKeyDown',
- 'onBlur',
- 'inputRef'
- ];
- function _interopRequireDefault(s) {
- return s && s.__esModule ? s : { default: s };
- }
- function _objectWithoutProperties(s, o) {
- if (null == s) return {};
- var i,
- u,
- _ = (function _objectWithoutPropertiesLoose(s, o) {
- if (null == s) return {};
- var i,
- u,
- _ = {},
- w = Object.keys(s);
- for (u = 0; u < w.length; u++) (i = w[u]), o.indexOf(i) >= 0 || (_[i] = s[i]);
- return _;
- })(s, o);
- if (Object.getOwnPropertySymbols) {
- var w = Object.getOwnPropertySymbols(s);
- for (u = 0; u < w.length; u++)
- (i = w[u]),
- o.indexOf(i) >= 0 ||
- (Object.prototype.propertyIsEnumerable.call(s, i) && (_[i] = s[i]));
- }
- return _;
- }
- function ownKeys(s, o) {
- var i = Object.keys(s);
- if (Object.getOwnPropertySymbols) {
- var u = Object.getOwnPropertySymbols(s);
- o &&
- (u = u.filter(function (o) {
- return Object.getOwnPropertyDescriptor(s, o).enumerable;
- })),
- i.push.apply(i, u);
- }
- return i;
- }
- function _objectSpread(s) {
- for (var o = 1; o < arguments.length; o++) {
- var i = null != arguments[o] ? arguments[o] : {};
- o % 2
- ? ownKeys(Object(i), !0).forEach(function (o) {
- _defineProperty(s, o, i[o]);
- })
- : Object.getOwnPropertyDescriptors
- ? Object.defineProperties(s, Object.getOwnPropertyDescriptors(i))
- : ownKeys(Object(i)).forEach(function (o) {
- Object.defineProperty(s, o, Object.getOwnPropertyDescriptor(i, o));
- });
- }
- return s;
- }
- function _defineProperties(s, o) {
- for (var i = 0; i < o.length; i++) {
- var u = o[i];
- (u.enumerable = u.enumerable || !1),
- (u.configurable = !0),
- 'value' in u && (u.writable = !0),
- Object.defineProperty(s, u.key, u);
- }
- }
- function _setPrototypeOf(s, o) {
- return (
- (_setPrototypeOf =
- Object.setPrototypeOf ||
- function _setPrototypeOf(s, o) {
- return (s.__proto__ = o), s;
- }),
- _setPrototypeOf(s, o)
- );
- }
- function _createSuper(s) {
- var o = (function _isNativeReflectConstruct() {
- if ('undefined' == typeof Reflect || !Reflect.construct) return !1;
- if (Reflect.construct.sham) return !1;
- if ('function' == typeof Proxy) return !0;
- try {
- return (
- Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})), !0
- );
- } catch (s) {
- return !1;
- }
- })();
- return function _createSuperInternal() {
- var i,
- u = _getPrototypeOf(s);
- if (o) {
- var _ = _getPrototypeOf(this).constructor;
- i = Reflect.construct(u, arguments, _);
- } else i = u.apply(this, arguments);
- return (function _possibleConstructorReturn(s, o) {
- if (o && ('object' === _typeof(o) || 'function' == typeof o)) return o;
- if (void 0 !== o)
- throw new TypeError('Derived constructors may only return object or undefined');
- return _assertThisInitialized(s);
- })(this, i);
- };
- }
- function _assertThisInitialized(s) {
- if (void 0 === s)
- throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
- return s;
- }
- function _getPrototypeOf(s) {
- return (
- (_getPrototypeOf = Object.setPrototypeOf
- ? Object.getPrototypeOf
- : function _getPrototypeOf(s) {
- return s.__proto__ || Object.getPrototypeOf(s);
- }),
- _getPrototypeOf(s)
- );
- }
- function _defineProperty(s, o, i) {
- return (
- o in s
- ? Object.defineProperty(s, o, {
- value: i,
- enumerable: !0,
- configurable: !0,
- writable: !0
- })
- : (s[o] = i),
- s
- );
- }
- var x = (function (s) {
- !(function _inherits(s, o) {
- if ('function' != typeof o && null !== o)
- throw new TypeError('Super expression must either be null or a function');
- (s.prototype = Object.create(o && o.prototype, {
- constructor: { value: s, writable: !0, configurable: !0 }
- })),
- Object.defineProperty(s, 'prototype', { writable: !1 }),
- o && _setPrototypeOf(s, o);
- })(DebounceInput, s);
- var o = _createSuper(DebounceInput);
- function DebounceInput(s) {
- var i;
- !(function _classCallCheck(s, o) {
- if (!(s instanceof o)) throw new TypeError('Cannot call a class as a function');
- })(this, DebounceInput),
- _defineProperty(
- _assertThisInitialized((i = o.call(this, s))),
- 'onChange',
- function (s) {
- s.persist();
- var o = i.state.value,
- u = i.props.minLength;
- i.setState({ value: s.target.value }, function () {
- var _ = i.state.value;
- _.length >= u
- ? i.notify(s)
- : o.length > _.length &&
- i.notify(
- _objectSpread(
- _objectSpread({}, s),
- {},
- {
- target: _objectSpread(
- _objectSpread({}, s.target),
- {},
- { value: '' }
- )
- }
- )
- );
- });
- }
- ),
- _defineProperty(_assertThisInitialized(i), 'onKeyDown', function (s) {
- 'Enter' === s.key && i.forceNotify(s);
- var o = i.props.onKeyDown;
- o && (s.persist(), o(s));
- }),
- _defineProperty(_assertThisInitialized(i), 'onBlur', function (s) {
- i.forceNotify(s);
- var o = i.props.onBlur;
- o && (s.persist(), o(s));
- }),
- _defineProperty(_assertThisInitialized(i), 'createNotifier', function (s) {
- if (s < 0)
- i.notify = function () {
- return null;
- };
- else if (0 === s) i.notify = i.doNotify;
- else {
- var o = (0, _.default)(function (s) {
- (i.isDebouncing = !1), i.doNotify(s);
- }, s);
- (i.notify = function (s) {
- (i.isDebouncing = !0), o(s);
- }),
- (i.flush = function () {
- return o.flush();
- }),
- (i.cancel = function () {
- (i.isDebouncing = !1), o.cancel();
- });
- }
- }),
- _defineProperty(_assertThisInitialized(i), 'doNotify', function () {
- i.props.onChange.apply(void 0, arguments);
- }),
- _defineProperty(_assertThisInitialized(i), 'forceNotify', function (s) {
- var o = i.props.debounceTimeout;
- if (i.isDebouncing || !(o > 0)) {
- i.cancel && i.cancel();
- var u = i.state.value,
- _ = i.props.minLength;
- u.length >= _
- ? i.doNotify(s)
- : i.doNotify(
- _objectSpread(
- _objectSpread({}, s),
- {},
- { target: _objectSpread(_objectSpread({}, s.target), {}, { value: u }) }
- )
- );
- }
- }),
- (i.isDebouncing = !1),
- (i.state = { value: void 0 === s.value || null === s.value ? '' : s.value });
- var u = i.props.debounceTimeout;
- return i.createNotifier(u), i;
- }
- return (
- (function _createClass(s, o, i) {
- return (
- o && _defineProperties(s.prototype, o),
- i && _defineProperties(s, i),
- Object.defineProperty(s, 'prototype', { writable: !1 }),
- s
- );
- })(DebounceInput, [
- {
- key: 'componentDidUpdate',
- value: function componentDidUpdate(s) {
- if (!this.isDebouncing) {
- var o = this.props,
- i = o.value,
- u = o.debounceTimeout,
- _ = s.debounceTimeout,
- w = s.value,
- x = this.state.value;
- void 0 !== i && w !== i && x !== i && this.setState({ value: i }),
- u !== _ && this.createNotifier(u);
- }
- }
- },
- {
- key: 'componentWillUnmount',
- value: function componentWillUnmount() {
- this.flush && this.flush();
- }
- },
- {
- key: 'render',
- value: function render() {
- var s,
- o,
- i = this.props,
- _ = i.element,
- x =
- (i.onChange, i.value, i.minLength, i.debounceTimeout, i.forceNotifyByEnter),
- C = i.forceNotifyOnBlur,
- j = i.onKeyDown,
- L = i.onBlur,
- B = i.inputRef,
- $ = _objectWithoutProperties(i, w),
- V = this.state.value;
- (s = x ? { onKeyDown: this.onKeyDown } : j ? { onKeyDown: j } : {}),
- (o = C ? { onBlur: this.onBlur } : L ? { onBlur: L } : {});
- var U = B ? { ref: B } : {};
- return u.default.createElement(
- _,
- _objectSpread(
- _objectSpread(
- _objectSpread(
- _objectSpread({}, $),
- {},
- { onChange: this.onChange, value: V },
- s
- ),
- o
- ),
- U
- )
- );
- }
- }
- ]),
- DebounceInput
- );
- })(u.default.PureComponent);
- (o.DebounceInput = x),
- _defineProperty(x, 'defaultProps', {
- element: 'input',
- type: 'text',
- onKeyDown: void 0,
- onBlur: void 0,
- value: void 0,
- minLength: 0,
- debounceTimeout: 100,
- forceNotifyByEnter: !0,
- forceNotifyOnBlur: !0,
- inputRef: void 0
- });
- },
- 24677: (s, o, i) => {
- 'use strict';
- var u = i(81214).DebounceInput;
- (u.DebounceInput = u), (s.exports = u);
- },
- 22551: (s, o, i) => {
- 'use strict';
- var u = i(96540),
- _ = i(69982);
- function p(s) {
- for (
- var o = 'https://reactjs.org/docs/error-decoder.html?invariant=' + s, i = 1;
- i < arguments.length;
- i++
- )
- o += '&args[]=' + encodeURIComponent(arguments[i]);
- return (
- 'Minified React error #' +
- s +
- '; visit ' +
- o +
- ' for the full message or use the non-minified dev environment for full errors and additional helpful warnings.'
- );
- }
- var w = new Set(),
- x = {};
- function fa(s, o) {
- ha(s, o), ha(s + 'Capture', o);
- }
- function ha(s, o) {
- for (x[s] = o, s = 0; s < o.length; s++) w.add(o[s]);
- }
- var C = !(
- 'undefined' == typeof window ||
- void 0 === window.document ||
- void 0 === window.document.createElement
- ),
- j = Object.prototype.hasOwnProperty,
- L =
- /^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,
- B = {},
- $ = {};
- function v(s, o, i, u, _, w, x) {
- (this.acceptsBooleans = 2 === o || 3 === o || 4 === o),
- (this.attributeName = u),
- (this.attributeNamespace = _),
- (this.mustUseProperty = i),
- (this.propertyName = s),
- (this.type = o),
- (this.sanitizeURL = w),
- (this.removeEmptyString = x);
- }
- var V = {};
- 'children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style'
- .split(' ')
- .forEach(function (s) {
- V[s] = new v(s, 0, !1, s, null, !1, !1);
- }),
- [
- ['acceptCharset', 'accept-charset'],
- ['className', 'class'],
- ['htmlFor', 'for'],
- ['httpEquiv', 'http-equiv']
- ].forEach(function (s) {
- var o = s[0];
- V[o] = new v(o, 1, !1, s[1], null, !1, !1);
- }),
- ['contentEditable', 'draggable', 'spellCheck', 'value'].forEach(function (s) {
- V[s] = new v(s, 2, !1, s.toLowerCase(), null, !1, !1);
- }),
- ['autoReverse', 'externalResourcesRequired', 'focusable', 'preserveAlpha'].forEach(
- function (s) {
- V[s] = new v(s, 2, !1, s, null, !1, !1);
- }
- ),
- 'allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope'
- .split(' ')
- .forEach(function (s) {
- V[s] = new v(s, 3, !1, s.toLowerCase(), null, !1, !1);
- }),
- ['checked', 'multiple', 'muted', 'selected'].forEach(function (s) {
- V[s] = new v(s, 3, !0, s, null, !1, !1);
- }),
- ['capture', 'download'].forEach(function (s) {
- V[s] = new v(s, 4, !1, s, null, !1, !1);
- }),
- ['cols', 'rows', 'size', 'span'].forEach(function (s) {
- V[s] = new v(s, 6, !1, s, null, !1, !1);
- }),
- ['rowSpan', 'start'].forEach(function (s) {
- V[s] = new v(s, 5, !1, s.toLowerCase(), null, !1, !1);
- });
- var U = /[\-:]([a-z])/g;
- function sa(s) {
- return s[1].toUpperCase();
- }
- function ta(s, o, i, u) {
- var _ = V.hasOwnProperty(o) ? V[o] : null;
- (null !== _
- ? 0 !== _.type
- : u ||
- !(2 < o.length) ||
- ('o' !== o[0] && 'O' !== o[0]) ||
- ('n' !== o[1] && 'N' !== o[1])) &&
- ((function qa(s, o, i, u) {
- if (
- null == o ||
- (function pa(s, o, i, u) {
- if (null !== i && 0 === i.type) return !1;
- switch (typeof o) {
- case 'function':
- case 'symbol':
- return !0;
- case 'boolean':
- return (
- !u &&
- (null !== i
- ? !i.acceptsBooleans
- : 'data-' !== (s = s.toLowerCase().slice(0, 5)) && 'aria-' !== s)
- );
- default:
- return !1;
- }
- })(s, o, i, u)
- )
- return !0;
- if (u) return !1;
- if (null !== i)
- switch (i.type) {
- case 3:
- return !o;
- case 4:
- return !1 === o;
- case 5:
- return isNaN(o);
- case 6:
- return isNaN(o) || 1 > o;
- }
- return !1;
- })(o, i, _, u) && (i = null),
- u || null === _
- ? (function oa(s) {
- return (
- !!j.call($, s) ||
- (!j.call(B, s) && (L.test(s) ? ($[s] = !0) : ((B[s] = !0), !1)))
- );
- })(o) && (null === i ? s.removeAttribute(o) : s.setAttribute(o, '' + i))
- : _.mustUseProperty
- ? (s[_.propertyName] = null === i ? 3 !== _.type && '' : i)
- : ((o = _.attributeName),
- (u = _.attributeNamespace),
- null === i
- ? s.removeAttribute(o)
- : ((i = 3 === (_ = _.type) || (4 === _ && !0 === i) ? '' : '' + i),
- u ? s.setAttributeNS(u, o, i) : s.setAttribute(o, i))));
- }
- 'accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height'
- .split(' ')
- .forEach(function (s) {
- var o = s.replace(U, sa);
- V[o] = new v(o, 1, !1, s, null, !1, !1);
- }),
- 'xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type'
- .split(' ')
- .forEach(function (s) {
- var o = s.replace(U, sa);
- V[o] = new v(o, 1, !1, s, 'http://www.w3.org/1999/xlink', !1, !1);
- }),
- ['xml:base', 'xml:lang', 'xml:space'].forEach(function (s) {
- var o = s.replace(U, sa);
- V[o] = new v(o, 1, !1, s, 'http://www.w3.org/XML/1998/namespace', !1, !1);
- }),
- ['tabIndex', 'crossOrigin'].forEach(function (s) {
- V[s] = new v(s, 1, !1, s.toLowerCase(), null, !1, !1);
- }),
- (V.xlinkHref = new v(
- 'xlinkHref',
- 1,
- !1,
- 'xlink:href',
- 'http://www.w3.org/1999/xlink',
- !0,
- !1
- )),
- ['src', 'href', 'action', 'formAction'].forEach(function (s) {
- V[s] = new v(s, 1, !1, s.toLowerCase(), null, !0, !0);
- });
- var z = u.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,
- Y = Symbol.for('react.element'),
- Z = Symbol.for('react.portal'),
- ee = Symbol.for('react.fragment'),
- ie = Symbol.for('react.strict_mode'),
- ae = Symbol.for('react.profiler'),
- le = Symbol.for('react.provider'),
- ce = Symbol.for('react.context'),
- pe = Symbol.for('react.forward_ref'),
- de = Symbol.for('react.suspense'),
- fe = Symbol.for('react.suspense_list'),
- ye = Symbol.for('react.memo'),
- be = Symbol.for('react.lazy');
- Symbol.for('react.scope'), Symbol.for('react.debug_trace_mode');
- var _e = Symbol.for('react.offscreen');
- Symbol.for('react.legacy_hidden'),
- Symbol.for('react.cache'),
- Symbol.for('react.tracing_marker');
- var we = Symbol.iterator;
- function Ka(s) {
- return null === s || 'object' != typeof s
- ? null
- : 'function' == typeof (s = (we && s[we]) || s['@@iterator'])
- ? s
- : null;
- }
- var Se,
- xe = Object.assign;
- function Ma(s) {
- if (void 0 === Se)
- try {
- throw Error();
- } catch (s) {
- var o = s.stack.trim().match(/\n( *(at )?)/);
- Se = (o && o[1]) || '';
- }
- return '\n' + Se + s;
- }
- var Pe = !1;
- function Oa(s, o) {
- if (!s || Pe) return '';
- Pe = !0;
- var i = Error.prepareStackTrace;
- Error.prepareStackTrace = void 0;
- try {
- if (o)
- if (
- ((o = function () {
- throw Error();
- }),
- Object.defineProperty(o.prototype, 'props', {
- set: function () {
- throw Error();
- }
- }),
- 'object' == typeof Reflect && Reflect.construct)
- ) {
- try {
- Reflect.construct(o, []);
- } catch (s) {
- var u = s;
- }
- Reflect.construct(s, [], o);
- } else {
- try {
- o.call();
- } catch (s) {
- u = s;
- }
- s.call(o.prototype);
- }
- else {
- try {
- throw Error();
- } catch (s) {
- u = s;
- }
- s();
- }
- } catch (o) {
- if (o && u && 'string' == typeof o.stack) {
- for (
- var _ = o.stack.split('\n'),
- w = u.stack.split('\n'),
- x = _.length - 1,
- C = w.length - 1;
- 1 <= x && 0 <= C && _[x] !== w[C];
- )
- C--;
- for (; 1 <= x && 0 <= C; x--, C--)
- if (_[x] !== w[C]) {
- if (1 !== x || 1 !== C)
- do {
- if ((x--, 0 > --C || _[x] !== w[C])) {
- var j = '\n' + _[x].replace(' at new ', ' at ');
- return (
- s.displayName &&
- j.includes('<anonymous>') &&
- (j = j.replace('<anonymous>', s.displayName)),
- j
- );
- }
- } while (1 <= x && 0 <= C);
- break;
- }
- }
- } finally {
- (Pe = !1), (Error.prepareStackTrace = i);
- }
- return (s = s ? s.displayName || s.name : '') ? Ma(s) : '';
- }
- function Pa(s) {
- switch (s.tag) {
- case 5:
- return Ma(s.type);
- case 16:
- return Ma('Lazy');
- case 13:
- return Ma('Suspense');
- case 19:
- return Ma('SuspenseList');
- case 0:
- case 2:
- case 15:
- return (s = Oa(s.type, !1));
- case 11:
- return (s = Oa(s.type.render, !1));
- case 1:
- return (s = Oa(s.type, !0));
- default:
- return '';
- }
- }
- function Qa(s) {
- if (null == s) return null;
- if ('function' == typeof s) return s.displayName || s.name || null;
- if ('string' == typeof s) return s;
- switch (s) {
- case ee:
- return 'Fragment';
- case Z:
- return 'Portal';
- case ae:
- return 'Profiler';
- case ie:
- return 'StrictMode';
- case de:
- return 'Suspense';
- case fe:
- return 'SuspenseList';
- }
- if ('object' == typeof s)
- switch (s.$$typeof) {
- case ce:
- return (s.displayName || 'Context') + '.Consumer';
- case le:
- return (s._context.displayName || 'Context') + '.Provider';
- case pe:
- var o = s.render;
- return (
- (s = s.displayName) ||
- (s =
- '' !== (s = o.displayName || o.name || '')
- ? 'ForwardRef(' + s + ')'
- : 'ForwardRef'),
- s
- );
- case ye:
- return null !== (o = s.displayName || null) ? o : Qa(s.type) || 'Memo';
- case be:
- (o = s._payload), (s = s._init);
- try {
- return Qa(s(o));
- } catch (s) {}
- }
- return null;
- }
- function Ra(s) {
- var o = s.type;
- switch (s.tag) {
- case 24:
- return 'Cache';
- case 9:
- return (o.displayName || 'Context') + '.Consumer';
- case 10:
- return (o._context.displayName || 'Context') + '.Provider';
- case 18:
- return 'DehydratedFragment';
- case 11:
- return (
- (s = (s = o.render).displayName || s.name || ''),
- o.displayName || ('' !== s ? 'ForwardRef(' + s + ')' : 'ForwardRef')
- );
- case 7:
- return 'Fragment';
- case 5:
- return o;
- case 4:
- return 'Portal';
- case 3:
- return 'Root';
- case 6:
- return 'Text';
- case 16:
- return Qa(o);
- case 8:
- return o === ie ? 'StrictMode' : 'Mode';
- case 22:
- return 'Offscreen';
- case 12:
- return 'Profiler';
- case 21:
- return 'Scope';
- case 13:
- return 'Suspense';
- case 19:
- return 'SuspenseList';
- case 25:
- return 'TracingMarker';
- case 1:
- case 0:
- case 17:
- case 2:
- case 14:
- case 15:
- if ('function' == typeof o) return o.displayName || o.name || null;
- if ('string' == typeof o) return o;
- }
- return null;
- }
- function Sa(s) {
- switch (typeof s) {
- case 'boolean':
- case 'number':
- case 'string':
- case 'undefined':
- case 'object':
- return s;
- default:
- return '';
- }
- }
- function Ta(s) {
- var o = s.type;
- return (
- (s = s.nodeName) && 'input' === s.toLowerCase() && ('checkbox' === o || 'radio' === o)
- );
- }
- function Va(s) {
- s._valueTracker ||
- (s._valueTracker = (function Ua(s) {
- var o = Ta(s) ? 'checked' : 'value',
- i = Object.getOwnPropertyDescriptor(s.constructor.prototype, o),
- u = '' + s[o];
- if (
- !s.hasOwnProperty(o) &&
- void 0 !== i &&
- 'function' == typeof i.get &&
- 'function' == typeof i.set
- ) {
- var _ = i.get,
- w = i.set;
- return (
- Object.defineProperty(s, o, {
- configurable: !0,
- get: function () {
- return _.call(this);
- },
- set: function (s) {
- (u = '' + s), w.call(this, s);
- }
- }),
- Object.defineProperty(s, o, { enumerable: i.enumerable }),
- {
- getValue: function () {
- return u;
- },
- setValue: function (s) {
- u = '' + s;
- },
- stopTracking: function () {
- (s._valueTracker = null), delete s[o];
- }
- }
- );
- }
- })(s));
- }
- function Wa(s) {
- if (!s) return !1;
- var o = s._valueTracker;
- if (!o) return !0;
- var i = o.getValue(),
- u = '';
- return (
- s && (u = Ta(s) ? (s.checked ? 'true' : 'false') : s.value),
- (s = u) !== i && (o.setValue(s), !0)
- );
- }
- function Xa(s) {
- if (void 0 === (s = s || ('undefined' != typeof document ? document : void 0)))
- return null;
- try {
- return s.activeElement || s.body;
- } catch (o) {
- return s.body;
- }
- }
- function Ya(s, o) {
- var i = o.checked;
- return xe({}, o, {
- defaultChecked: void 0,
- defaultValue: void 0,
- value: void 0,
- checked: null != i ? i : s._wrapperState.initialChecked
- });
- }
- function Za(s, o) {
- var i = null == o.defaultValue ? '' : o.defaultValue,
- u = null != o.checked ? o.checked : o.defaultChecked;
- (i = Sa(null != o.value ? o.value : i)),
- (s._wrapperState = {
- initialChecked: u,
- initialValue: i,
- controlled:
- 'checkbox' === o.type || 'radio' === o.type ? null != o.checked : null != o.value
- });
- }
- function ab(s, o) {
- null != (o = o.checked) && ta(s, 'checked', o, !1);
- }
- function bb(s, o) {
- ab(s, o);
- var i = Sa(o.value),
- u = o.type;
- if (null != i)
- 'number' === u
- ? ((0 === i && '' === s.value) || s.value != i) && (s.value = '' + i)
- : s.value !== '' + i && (s.value = '' + i);
- else if ('submit' === u || 'reset' === u) return void s.removeAttribute('value');
- o.hasOwnProperty('value')
- ? cb(s, o.type, i)
- : o.hasOwnProperty('defaultValue') && cb(s, o.type, Sa(o.defaultValue)),
- null == o.checked &&
- null != o.defaultChecked &&
- (s.defaultChecked = !!o.defaultChecked);
- }
- function db(s, o, i) {
- if (o.hasOwnProperty('value') || o.hasOwnProperty('defaultValue')) {
- var u = o.type;
- if (!(('submit' !== u && 'reset' !== u) || (void 0 !== o.value && null !== o.value)))
- return;
- (o = '' + s._wrapperState.initialValue),
- i || o === s.value || (s.value = o),
- (s.defaultValue = o);
- }
- '' !== (i = s.name) && (s.name = ''),
- (s.defaultChecked = !!s._wrapperState.initialChecked),
- '' !== i && (s.name = i);
- }
- function cb(s, o, i) {
- ('number' === o && Xa(s.ownerDocument) === s) ||
- (null == i
- ? (s.defaultValue = '' + s._wrapperState.initialValue)
- : s.defaultValue !== '' + i && (s.defaultValue = '' + i));
- }
- var Te = Array.isArray;
- function fb(s, o, i, u) {
- if (((s = s.options), o)) {
- o = {};
- for (var _ = 0; _ < i.length; _++) o['$' + i[_]] = !0;
- for (i = 0; i < s.length; i++)
- (_ = o.hasOwnProperty('$' + s[i].value)),
- s[i].selected !== _ && (s[i].selected = _),
- _ && u && (s[i].defaultSelected = !0);
- } else {
- for (i = '' + Sa(i), o = null, _ = 0; _ < s.length; _++) {
- if (s[_].value === i)
- return (s[_].selected = !0), void (u && (s[_].defaultSelected = !0));
- null !== o || s[_].disabled || (o = s[_]);
- }
- null !== o && (o.selected = !0);
- }
- }
- function gb(s, o) {
- if (null != o.dangerouslySetInnerHTML) throw Error(p(91));
- return xe({}, o, {
- value: void 0,
- defaultValue: void 0,
- children: '' + s._wrapperState.initialValue
- });
- }
- function hb(s, o) {
- var i = o.value;
- if (null == i) {
- if (((i = o.children), (o = o.defaultValue), null != i)) {
- if (null != o) throw Error(p(92));
- if (Te(i)) {
- if (1 < i.length) throw Error(p(93));
- i = i[0];
- }
- o = i;
- }
- null == o && (o = ''), (i = o);
- }
- s._wrapperState = { initialValue: Sa(i) };
- }
- function ib(s, o) {
- var i = Sa(o.value),
- u = Sa(o.defaultValue);
- null != i &&
- ((i = '' + i) !== s.value && (s.value = i),
- null == o.defaultValue && s.defaultValue !== i && (s.defaultValue = i)),
- null != u && (s.defaultValue = '' + u);
- }
- function jb(s) {
- var o = s.textContent;
- o === s._wrapperState.initialValue && '' !== o && null !== o && (s.value = o);
- }
- function kb(s) {
- switch (s) {
- case 'svg':
- return 'http://www.w3.org/2000/svg';
- case 'math':
- return 'http://www.w3.org/1998/Math/MathML';
- default:
- return 'http://www.w3.org/1999/xhtml';
- }
- }
- function lb(s, o) {
- return null == s || 'http://www.w3.org/1999/xhtml' === s
- ? kb(o)
- : 'http://www.w3.org/2000/svg' === s && 'foreignObject' === o
- ? 'http://www.w3.org/1999/xhtml'
- : s;
- }
- var Re,
- qe,
- $e =
- ((qe = function (s, o) {
- if ('http://www.w3.org/2000/svg' !== s.namespaceURI || 'innerHTML' in s)
- s.innerHTML = o;
- else {
- for (
- (Re = Re || document.createElement('div')).innerHTML =
- '<svg>' + o.valueOf().toString() + '</svg>',
- o = Re.firstChild;
- s.firstChild;
- )
- s.removeChild(s.firstChild);
- for (; o.firstChild; ) s.appendChild(o.firstChild);
- }
- }),
- 'undefined' != typeof MSApp && MSApp.execUnsafeLocalFunction
- ? function (s, o, i, u) {
- MSApp.execUnsafeLocalFunction(function () {
- return qe(s, o);
- });
- }
- : qe);
- function ob(s, o) {
- if (o) {
- var i = s.firstChild;
- if (i && i === s.lastChild && 3 === i.nodeType) return void (i.nodeValue = o);
- }
- s.textContent = o;
- }
- var ze = {
- animationIterationCount: !0,
- aspectRatio: !0,
- borderImageOutset: !0,
- borderImageSlice: !0,
- borderImageWidth: !0,
- boxFlex: !0,
- boxFlexGroup: !0,
- boxOrdinalGroup: !0,
- columnCount: !0,
- columns: !0,
- flex: !0,
- flexGrow: !0,
- flexPositive: !0,
- flexShrink: !0,
- flexNegative: !0,
- flexOrder: !0,
- gridArea: !0,
- gridRow: !0,
- gridRowEnd: !0,
- gridRowSpan: !0,
- gridRowStart: !0,
- gridColumn: !0,
- gridColumnEnd: !0,
- gridColumnSpan: !0,
- gridColumnStart: !0,
- fontWeight: !0,
- lineClamp: !0,
- lineHeight: !0,
- opacity: !0,
- order: !0,
- orphans: !0,
- tabSize: !0,
- widows: !0,
- zIndex: !0,
- zoom: !0,
- fillOpacity: !0,
- floodOpacity: !0,
- stopOpacity: !0,
- strokeDasharray: !0,
- strokeDashoffset: !0,
- strokeMiterlimit: !0,
- strokeOpacity: !0,
- strokeWidth: !0
- },
- We = ['Webkit', 'ms', 'Moz', 'O'];
- function rb(s, o, i) {
- return null == o || 'boolean' == typeof o || '' === o
- ? ''
- : i || 'number' != typeof o || 0 === o || (ze.hasOwnProperty(s) && ze[s])
- ? ('' + o).trim()
- : o + 'px';
- }
- function sb(s, o) {
- for (var i in ((s = s.style), o))
- if (o.hasOwnProperty(i)) {
- var u = 0 === i.indexOf('--'),
- _ = rb(i, o[i], u);
- 'float' === i && (i = 'cssFloat'), u ? s.setProperty(i, _) : (s[i] = _);
- }
- }
- Object.keys(ze).forEach(function (s) {
- We.forEach(function (o) {
- (o = o + s.charAt(0).toUpperCase() + s.substring(1)), (ze[o] = ze[s]);
- });
- });
- var He = xe(
- { menuitem: !0 },
- {
- area: !0,
- base: !0,
- br: !0,
- col: !0,
- embed: !0,
- hr: !0,
- img: !0,
- input: !0,
- keygen: !0,
- link: !0,
- meta: !0,
- param: !0,
- source: !0,
- track: !0,
- wbr: !0
- }
- );
- function ub(s, o) {
- if (o) {
- if (He[s] && (null != o.children || null != o.dangerouslySetInnerHTML))
- throw Error(p(137, s));
- if (null != o.dangerouslySetInnerHTML) {
- if (null != o.children) throw Error(p(60));
- if (
- 'object' != typeof o.dangerouslySetInnerHTML ||
- !('__html' in o.dangerouslySetInnerHTML)
- )
- throw Error(p(61));
- }
- if (null != o.style && 'object' != typeof o.style) throw Error(p(62));
- }
- }
- function vb(s, o) {
- if (-1 === s.indexOf('-')) return 'string' == typeof o.is;
- switch (s) {
- case 'annotation-xml':
- case 'color-profile':
- case 'font-face':
- case 'font-face-src':
- case 'font-face-uri':
- case 'font-face-format':
- case 'font-face-name':
- case 'missing-glyph':
- return !1;
- default:
- return !0;
- }
- }
- var Ye = null;
- function xb(s) {
- return (
- (s = s.target || s.srcElement || window).correspondingUseElement &&
- (s = s.correspondingUseElement),
- 3 === s.nodeType ? s.parentNode : s
- );
- }
- var Xe = null,
- Qe = null,
- et = null;
- function Bb(s) {
- if ((s = Cb(s))) {
- if ('function' != typeof Xe) throw Error(p(280));
- var o = s.stateNode;
- o && ((o = Db(o)), Xe(s.stateNode, s.type, o));
- }
- }
- function Eb(s) {
- Qe ? (et ? et.push(s) : (et = [s])) : (Qe = s);
- }
- function Fb() {
- if (Qe) {
- var s = Qe,
- o = et;
- if (((et = Qe = null), Bb(s), o)) for (s = 0; s < o.length; s++) Bb(o[s]);
- }
- }
- function Gb(s, o) {
- return s(o);
- }
- function Hb() {}
- var tt = !1;
- function Jb(s, o, i) {
- if (tt) return s(o, i);
- tt = !0;
- try {
- return Gb(s, o, i);
- } finally {
- (tt = !1), (null !== Qe || null !== et) && (Hb(), Fb());
- }
- }
- function Kb(s, o) {
- var i = s.stateNode;
- if (null === i) return null;
- var u = Db(i);
- if (null === u) return null;
- i = u[o];
- e: switch (o) {
- case 'onClick':
- case 'onClickCapture':
- case 'onDoubleClick':
- case 'onDoubleClickCapture':
- case 'onMouseDown':
- case 'onMouseDownCapture':
- case 'onMouseMove':
- case 'onMouseMoveCapture':
- case 'onMouseUp':
- case 'onMouseUpCapture':
- case 'onMouseEnter':
- (u = !u.disabled) ||
- (u = !(
- 'button' === (s = s.type) ||
- 'input' === s ||
- 'select' === s ||
- 'textarea' === s
- )),
- (s = !u);
- break e;
- default:
- s = !1;
- }
- if (s) return null;
- if (i && 'function' != typeof i) throw Error(p(231, o, typeof i));
- return i;
- }
- var rt = !1;
- if (C)
- try {
- var nt = {};
- Object.defineProperty(nt, 'passive', {
- get: function () {
- rt = !0;
- }
- }),
- window.addEventListener('test', nt, nt),
- window.removeEventListener('test', nt, nt);
- } catch (qe) {
- rt = !1;
- }
- function Nb(s, o, i, u, _, w, x, C, j) {
- var L = Array.prototype.slice.call(arguments, 3);
- try {
- o.apply(i, L);
- } catch (s) {
- this.onError(s);
- }
- }
- var st = !1,
- ot = null,
- it = !1,
- at = null,
- lt = {
- onError: function (s) {
- (st = !0), (ot = s);
- }
- };
- function Tb(s, o, i, u, _, w, x, C, j) {
- (st = !1), (ot = null), Nb.apply(lt, arguments);
- }
- function Vb(s) {
- var o = s,
- i = s;
- if (s.alternate) for (; o.return; ) o = o.return;
- else {
- s = o;
- do {
- !!(4098 & (o = s).flags) && (i = o.return), (s = o.return);
- } while (s);
- }
- return 3 === o.tag ? i : null;
- }
- function Wb(s) {
- if (13 === s.tag) {
- var o = s.memoizedState;
- if ((null === o && null !== (s = s.alternate) && (o = s.memoizedState), null !== o))
- return o.dehydrated;
- }
- return null;
- }
- function Xb(s) {
- if (Vb(s) !== s) throw Error(p(188));
- }
- function Zb(s) {
- return null !==
- (s = (function Yb(s) {
- var o = s.alternate;
- if (!o) {
- if (null === (o = Vb(s))) throw Error(p(188));
- return o !== s ? null : s;
- }
- for (var i = s, u = o; ; ) {
- var _ = i.return;
- if (null === _) break;
- var w = _.alternate;
- if (null === w) {
- if (null !== (u = _.return)) {
- i = u;
- continue;
- }
- break;
- }
- if (_.child === w.child) {
- for (w = _.child; w; ) {
- if (w === i) return Xb(_), s;
- if (w === u) return Xb(_), o;
- w = w.sibling;
- }
- throw Error(p(188));
- }
- if (i.return !== u.return) (i = _), (u = w);
- else {
- for (var x = !1, C = _.child; C; ) {
- if (C === i) {
- (x = !0), (i = _), (u = w);
- break;
- }
- if (C === u) {
- (x = !0), (u = _), (i = w);
- break;
- }
- C = C.sibling;
- }
- if (!x) {
- for (C = w.child; C; ) {
- if (C === i) {
- (x = !0), (i = w), (u = _);
- break;
- }
- if (C === u) {
- (x = !0), (u = w), (i = _);
- break;
- }
- C = C.sibling;
- }
- if (!x) throw Error(p(189));
- }
- }
- if (i.alternate !== u) throw Error(p(190));
- }
- if (3 !== i.tag) throw Error(p(188));
- return i.stateNode.current === i ? s : o;
- })(s))
- ? $b(s)
- : null;
- }
- function $b(s) {
- if (5 === s.tag || 6 === s.tag) return s;
- for (s = s.child; null !== s; ) {
- var o = $b(s);
- if (null !== o) return o;
- s = s.sibling;
- }
- return null;
- }
- var ct = _.unstable_scheduleCallback,
- ut = _.unstable_cancelCallback,
- pt = _.unstable_shouldYield,
- ht = _.unstable_requestPaint,
- dt = _.unstable_now,
- mt = _.unstable_getCurrentPriorityLevel,
- gt = _.unstable_ImmediatePriority,
- yt = _.unstable_UserBlockingPriority,
- vt = _.unstable_NormalPriority,
- bt = _.unstable_LowPriority,
- _t = _.unstable_IdlePriority,
- Et = null,
- wt = null;
- var St = Math.clz32
- ? Math.clz32
- : function nc(s) {
- return (s >>>= 0), 0 === s ? 32 : (31 - ((xt(s) / kt) | 0)) | 0;
- },
- xt = Math.log,
- kt = Math.LN2;
- var Ct = 64,
- Ot = 4194304;
- function tc(s) {
- switch (s & -s) {
- case 1:
- return 1;
- case 2:
- return 2;
- case 4:
- return 4;
- case 8:
- return 8;
- case 16:
- return 16;
- case 32:
- return 32;
- case 64:
- case 128:
- case 256:
- case 512:
- case 1024:
- case 2048:
- case 4096:
- case 8192:
- case 16384:
- case 32768:
- case 65536:
- case 131072:
- case 262144:
- case 524288:
- case 1048576:
- case 2097152:
- return 4194240 & s;
- case 4194304:
- case 8388608:
- case 16777216:
- case 33554432:
- case 67108864:
- return 130023424 & s;
- case 134217728:
- return 134217728;
- case 268435456:
- return 268435456;
- case 536870912:
- return 536870912;
- case 1073741824:
- return 1073741824;
- default:
- return s;
- }
- }
- function uc(s, o) {
- var i = s.pendingLanes;
- if (0 === i) return 0;
- var u = 0,
- _ = s.suspendedLanes,
- w = s.pingedLanes,
- x = 268435455 & i;
- if (0 !== x) {
- var C = x & ~_;
- 0 !== C ? (u = tc(C)) : 0 !== (w &= x) && (u = tc(w));
- } else 0 !== (x = i & ~_) ? (u = tc(x)) : 0 !== w && (u = tc(w));
- if (0 === u) return 0;
- if (
- 0 !== o &&
- o !== u &&
- !(o & _) &&
- ((_ = u & -u) >= (w = o & -o) || (16 === _ && 4194240 & w))
- )
- return o;
- if ((4 & u && (u |= 16 & i), 0 !== (o = s.entangledLanes)))
- for (s = s.entanglements, o &= u; 0 < o; )
- (_ = 1 << (i = 31 - St(o))), (u |= s[i]), (o &= ~_);
- return u;
- }
- function vc(s, o) {
- switch (s) {
- case 1:
- case 2:
- case 4:
- return o + 250;
- case 8:
- case 16:
- case 32:
- case 64:
- case 128:
- case 256:
- case 512:
- case 1024:
- case 2048:
- case 4096:
- case 8192:
- case 16384:
- case 32768:
- case 65536:
- case 131072:
- case 262144:
- case 524288:
- case 1048576:
- case 2097152:
- return o + 5e3;
- default:
- return -1;
- }
- }
- function xc(s) {
- return 0 !== (s = -1073741825 & s.pendingLanes) ? s : 1073741824 & s ? 1073741824 : 0;
- }
- function yc() {
- var s = Ct;
- return !(4194240 & (Ct <<= 1)) && (Ct = 64), s;
- }
- function zc(s) {
- for (var o = [], i = 0; 31 > i; i++) o.push(s);
- return o;
- }
- function Ac(s, o, i) {
- (s.pendingLanes |= o),
- 536870912 !== o && ((s.suspendedLanes = 0), (s.pingedLanes = 0)),
- ((s = s.eventTimes)[(o = 31 - St(o))] = i);
- }
- function Cc(s, o) {
- var i = (s.entangledLanes |= o);
- for (s = s.entanglements; i; ) {
- var u = 31 - St(i),
- _ = 1 << u;
- (_ & o) | (s[u] & o) && (s[u] |= o), (i &= ~_);
- }
- }
- var At = 0;
- function Dc(s) {
- return 1 < (s &= -s) ? (4 < s ? (268435455 & s ? 16 : 536870912) : 4) : 1;
- }
- var jt,
- It,
- Pt,
- Mt,
- Tt,
- Nt = !1,
- Rt = [],
- Dt = null,
- Lt = null,
- Bt = null,
- Ft = new Map(),
- qt = new Map(),
- $t = [],
- Vt =
- 'mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit'.split(
- ' '
- );
- function Sc(s, o) {
- switch (s) {
- case 'focusin':
- case 'focusout':
- Dt = null;
- break;
- case 'dragenter':
- case 'dragleave':
- Lt = null;
- break;
- case 'mouseover':
- case 'mouseout':
- Bt = null;
- break;
- case 'pointerover':
- case 'pointerout':
- Ft.delete(o.pointerId);
- break;
- case 'gotpointercapture':
- case 'lostpointercapture':
- qt.delete(o.pointerId);
- }
- }
- function Tc(s, o, i, u, _, w) {
- return null === s || s.nativeEvent !== w
- ? ((s = {
- blockedOn: o,
- domEventName: i,
- eventSystemFlags: u,
- nativeEvent: w,
- targetContainers: [_]
- }),
- null !== o && null !== (o = Cb(o)) && It(o),
- s)
- : ((s.eventSystemFlags |= u),
- (o = s.targetContainers),
- null !== _ && -1 === o.indexOf(_) && o.push(_),
- s);
- }
- function Vc(s) {
- var o = Wc(s.target);
- if (null !== o) {
- var i = Vb(o);
- if (null !== i)
- if (13 === (o = i.tag)) {
- if (null !== (o = Wb(i)))
- return (
- (s.blockedOn = o),
- void Tt(s.priority, function () {
- Pt(i);
- })
- );
- } else if (3 === o && i.stateNode.current.memoizedState.isDehydrated)
- return void (s.blockedOn = 3 === i.tag ? i.stateNode.containerInfo : null);
- }
- s.blockedOn = null;
- }
- function Xc(s) {
- if (null !== s.blockedOn) return !1;
- for (var o = s.targetContainers; 0 < o.length; ) {
- var i = Yc(s.domEventName, s.eventSystemFlags, o[0], s.nativeEvent);
- if (null !== i) return null !== (o = Cb(i)) && It(o), (s.blockedOn = i), !1;
- var u = new (i = s.nativeEvent).constructor(i.type, i);
- (Ye = u), i.target.dispatchEvent(u), (Ye = null), o.shift();
- }
- return !0;
- }
- function Zc(s, o, i) {
- Xc(s) && i.delete(o);
- }
- function $c() {
- (Nt = !1),
- null !== Dt && Xc(Dt) && (Dt = null),
- null !== Lt && Xc(Lt) && (Lt = null),
- null !== Bt && Xc(Bt) && (Bt = null),
- Ft.forEach(Zc),
- qt.forEach(Zc);
- }
- function ad(s, o) {
- s.blockedOn === o &&
- ((s.blockedOn = null),
- Nt || ((Nt = !0), _.unstable_scheduleCallback(_.unstable_NormalPriority, $c)));
- }
- function bd(s) {
- function b(o) {
- return ad(o, s);
- }
- if (0 < Rt.length) {
- ad(Rt[0], s);
- for (var o = 1; o < Rt.length; o++) {
- var i = Rt[o];
- i.blockedOn === s && (i.blockedOn = null);
- }
- }
- for (
- null !== Dt && ad(Dt, s),
- null !== Lt && ad(Lt, s),
- null !== Bt && ad(Bt, s),
- Ft.forEach(b),
- qt.forEach(b),
- o = 0;
- o < $t.length;
- o++
- )
- (i = $t[o]).blockedOn === s && (i.blockedOn = null);
- for (; 0 < $t.length && null === (o = $t[0]).blockedOn; )
- Vc(o), null === o.blockedOn && $t.shift();
- }
- var Ut = z.ReactCurrentBatchConfig,
- zt = !0;
- function ed(s, o, i, u) {
- var _ = At,
- w = Ut.transition;
- Ut.transition = null;
- try {
- (At = 1), fd(s, o, i, u);
- } finally {
- (At = _), (Ut.transition = w);
- }
- }
- function gd(s, o, i, u) {
- var _ = At,
- w = Ut.transition;
- Ut.transition = null;
- try {
- (At = 4), fd(s, o, i, u);
- } finally {
- (At = _), (Ut.transition = w);
- }
- }
- function fd(s, o, i, u) {
- if (zt) {
- var _ = Yc(s, o, i, u);
- if (null === _) hd(s, o, u, Wt, i), Sc(s, u);
- else if (
- (function Uc(s, o, i, u, _) {
- switch (o) {
- case 'focusin':
- return (Dt = Tc(Dt, s, o, i, u, _)), !0;
- case 'dragenter':
- return (Lt = Tc(Lt, s, o, i, u, _)), !0;
- case 'mouseover':
- return (Bt = Tc(Bt, s, o, i, u, _)), !0;
- case 'pointerover':
- var w = _.pointerId;
- return Ft.set(w, Tc(Ft.get(w) || null, s, o, i, u, _)), !0;
- case 'gotpointercapture':
- return (w = _.pointerId), qt.set(w, Tc(qt.get(w) || null, s, o, i, u, _)), !0;
- }
- return !1;
- })(_, s, o, i, u)
- )
- u.stopPropagation();
- else if ((Sc(s, u), 4 & o && -1 < Vt.indexOf(s))) {
- for (; null !== _; ) {
- var w = Cb(_);
- if (
- (null !== w && jt(w),
- null === (w = Yc(s, o, i, u)) && hd(s, o, u, Wt, i),
- w === _)
- )
- break;
- _ = w;
- }
- null !== _ && u.stopPropagation();
- } else hd(s, o, u, null, i);
- }
- }
- var Wt = null;
- function Yc(s, o, i, u) {
- if (((Wt = null), null !== (s = Wc((s = xb(u))))))
- if (null === (o = Vb(s))) s = null;
- else if (13 === (i = o.tag)) {
- if (null !== (s = Wb(o))) return s;
- s = null;
- } else if (3 === i) {
- if (o.stateNode.current.memoizedState.isDehydrated)
- return 3 === o.tag ? o.stateNode.containerInfo : null;
- s = null;
- } else o !== s && (s = null);
- return (Wt = s), null;
- }
- function jd(s) {
- switch (s) {
- case 'cancel':
- case 'click':
- case 'close':
- case 'contextmenu':
- case 'copy':
- case 'cut':
- case 'auxclick':
- case 'dblclick':
- case 'dragend':
- case 'dragstart':
- case 'drop':
- case 'focusin':
- case 'focusout':
- case 'input':
- case 'invalid':
- case 'keydown':
- case 'keypress':
- case 'keyup':
- case 'mousedown':
- case 'mouseup':
- case 'paste':
- case 'pause':
- case 'play':
- case 'pointercancel':
- case 'pointerdown':
- case 'pointerup':
- case 'ratechange':
- case 'reset':
- case 'resize':
- case 'seeked':
- case 'submit':
- case 'touchcancel':
- case 'touchend':
- case 'touchstart':
- case 'volumechange':
- case 'change':
- case 'selectionchange':
- case 'textInput':
- case 'compositionstart':
- case 'compositionend':
- case 'compositionupdate':
- case 'beforeblur':
- case 'afterblur':
- case 'beforeinput':
- case 'blur':
- case 'fullscreenchange':
- case 'focus':
- case 'hashchange':
- case 'popstate':
- case 'select':
- case 'selectstart':
- return 1;
- case 'drag':
- case 'dragenter':
- case 'dragexit':
- case 'dragleave':
- case 'dragover':
- case 'mousemove':
- case 'mouseout':
- case 'mouseover':
- case 'pointermove':
- case 'pointerout':
- case 'pointerover':
- case 'scroll':
- case 'toggle':
- case 'touchmove':
- case 'wheel':
- case 'mouseenter':
- case 'mouseleave':
- case 'pointerenter':
- case 'pointerleave':
- return 4;
- case 'message':
- switch (mt()) {
- case gt:
- return 1;
- case yt:
- return 4;
- case vt:
- case bt:
- return 16;
- case _t:
- return 536870912;
- default:
- return 16;
- }
- default:
- return 16;
- }
- }
- var Kt = null,
- Ht = null,
- Jt = null;
- function nd() {
- if (Jt) return Jt;
- var s,
- o,
- i = Ht,
- u = i.length,
- _ = 'value' in Kt ? Kt.value : Kt.textContent,
- w = _.length;
- for (s = 0; s < u && i[s] === _[s]; s++);
- var x = u - s;
- for (o = 1; o <= x && i[u - o] === _[w - o]; o++);
- return (Jt = _.slice(s, 1 < o ? 1 - o : void 0));
- }
- function od(s) {
- var o = s.keyCode;
- return (
- 'charCode' in s ? 0 === (s = s.charCode) && 13 === o && (s = 13) : (s = o),
- 10 === s && (s = 13),
- 32 <= s || 13 === s ? s : 0
- );
- }
- function pd() {
- return !0;
- }
- function qd() {
- return !1;
- }
- function rd(s) {
- function b(o, i, u, _, w) {
- for (var x in ((this._reactName = o),
- (this._targetInst = u),
- (this.type = i),
- (this.nativeEvent = _),
- (this.target = w),
- (this.currentTarget = null),
- s))
- s.hasOwnProperty(x) && ((o = s[x]), (this[x] = o ? o(_) : _[x]));
- return (
- (this.isDefaultPrevented = (
- null != _.defaultPrevented ? _.defaultPrevented : !1 === _.returnValue
- )
- ? pd
- : qd),
- (this.isPropagationStopped = qd),
- this
- );
- }
- return (
- xe(b.prototype, {
- preventDefault: function () {
- this.defaultPrevented = !0;
- var s = this.nativeEvent;
- s &&
- (s.preventDefault
- ? s.preventDefault()
- : 'unknown' != typeof s.returnValue && (s.returnValue = !1),
- (this.isDefaultPrevented = pd));
- },
- stopPropagation: function () {
- var s = this.nativeEvent;
- s &&
- (s.stopPropagation
- ? s.stopPropagation()
- : 'unknown' != typeof s.cancelBubble && (s.cancelBubble = !0),
- (this.isPropagationStopped = pd));
- },
- persist: function () {},
- isPersistent: pd
- }),
- b
- );
- }
- var Gt,
- Yt,
- Xt,
- Zt = {
- eventPhase: 0,
- bubbles: 0,
- cancelable: 0,
- timeStamp: function (s) {
- return s.timeStamp || Date.now();
- },
- defaultPrevented: 0,
- isTrusted: 0
- },
- Qt = rd(Zt),
- er = xe({}, Zt, { view: 0, detail: 0 }),
- tr = rd(er),
- rr = xe({}, er, {
- screenX: 0,
- screenY: 0,
- clientX: 0,
- clientY: 0,
- pageX: 0,
- pageY: 0,
- ctrlKey: 0,
- shiftKey: 0,
- altKey: 0,
- metaKey: 0,
- getModifierState: zd,
- button: 0,
- buttons: 0,
- relatedTarget: function (s) {
- return void 0 === s.relatedTarget
- ? s.fromElement === s.srcElement
- ? s.toElement
- : s.fromElement
- : s.relatedTarget;
- },
- movementX: function (s) {
- return 'movementX' in s
- ? s.movementX
- : (s !== Xt &&
- (Xt && 'mousemove' === s.type
- ? ((Gt = s.screenX - Xt.screenX), (Yt = s.screenY - Xt.screenY))
- : (Yt = Gt = 0),
- (Xt = s)),
- Gt);
- },
- movementY: function (s) {
- return 'movementY' in s ? s.movementY : Yt;
- }
- }),
- nr = rd(rr),
- sr = rd(xe({}, rr, { dataTransfer: 0 })),
- ir = rd(xe({}, er, { relatedTarget: 0 })),
- ar = rd(xe({}, Zt, { animationName: 0, elapsedTime: 0, pseudoElement: 0 })),
- lr = xe({}, Zt, {
- clipboardData: function (s) {
- return 'clipboardData' in s ? s.clipboardData : window.clipboardData;
- }
- }),
- cr = rd(lr),
- ur = rd(xe({}, Zt, { data: 0 })),
- pr = {
- Esc: 'Escape',
- Spacebar: ' ',
- Left: 'ArrowLeft',
- Up: 'ArrowUp',
- Right: 'ArrowRight',
- Down: 'ArrowDown',
- Del: 'Delete',
- Win: 'OS',
- Menu: 'ContextMenu',
- Apps: 'ContextMenu',
- Scroll: 'ScrollLock',
- MozPrintableKey: 'Unidentified'
- },
- dr = {
- 8: 'Backspace',
- 9: 'Tab',
- 12: 'Clear',
- 13: 'Enter',
- 16: 'Shift',
- 17: 'Control',
- 18: 'Alt',
- 19: 'Pause',
- 20: 'CapsLock',
- 27: 'Escape',
- 32: ' ',
- 33: 'PageUp',
- 34: 'PageDown',
- 35: 'End',
- 36: 'Home',
- 37: 'ArrowLeft',
- 38: 'ArrowUp',
- 39: 'ArrowRight',
- 40: 'ArrowDown',
- 45: 'Insert',
- 46: 'Delete',
- 112: 'F1',
- 113: 'F2',
- 114: 'F3',
- 115: 'F4',
- 116: 'F5',
- 117: 'F6',
- 118: 'F7',
- 119: 'F8',
- 120: 'F9',
- 121: 'F10',
- 122: 'F11',
- 123: 'F12',
- 144: 'NumLock',
- 145: 'ScrollLock',
- 224: 'Meta'
- },
- fr = { Alt: 'altKey', Control: 'ctrlKey', Meta: 'metaKey', Shift: 'shiftKey' };
- function Pd(s) {
- var o = this.nativeEvent;
- return o.getModifierState ? o.getModifierState(s) : !!(s = fr[s]) && !!o[s];
- }
- function zd() {
- return Pd;
- }
- var mr = xe({}, er, {
- key: function (s) {
- if (s.key) {
- var o = pr[s.key] || s.key;
- if ('Unidentified' !== o) return o;
- }
- return 'keypress' === s.type
- ? 13 === (s = od(s))
- ? 'Enter'
- : String.fromCharCode(s)
- : 'keydown' === s.type || 'keyup' === s.type
- ? dr[s.keyCode] || 'Unidentified'
- : '';
- },
- code: 0,
- location: 0,
- ctrlKey: 0,
- shiftKey: 0,
- altKey: 0,
- metaKey: 0,
- repeat: 0,
- locale: 0,
- getModifierState: zd,
- charCode: function (s) {
- return 'keypress' === s.type ? od(s) : 0;
- },
- keyCode: function (s) {
- return 'keydown' === s.type || 'keyup' === s.type ? s.keyCode : 0;
- },
- which: function (s) {
- return 'keypress' === s.type
- ? od(s)
- : 'keydown' === s.type || 'keyup' === s.type
- ? s.keyCode
- : 0;
- }
- }),
- gr = rd(mr),
- yr = rd(
- xe({}, rr, {
- pointerId: 0,
- width: 0,
- height: 0,
- pressure: 0,
- tangentialPressure: 0,
- tiltX: 0,
- tiltY: 0,
- twist: 0,
- pointerType: 0,
- isPrimary: 0
- })
- ),
- vr = rd(
- xe({}, er, {
- touches: 0,
- targetTouches: 0,
- changedTouches: 0,
- altKey: 0,
- metaKey: 0,
- ctrlKey: 0,
- shiftKey: 0,
- getModifierState: zd
- })
- ),
- br = rd(xe({}, Zt, { propertyName: 0, elapsedTime: 0, pseudoElement: 0 })),
- _r = xe({}, rr, {
- deltaX: function (s) {
- return 'deltaX' in s ? s.deltaX : 'wheelDeltaX' in s ? -s.wheelDeltaX : 0;
- },
- deltaY: function (s) {
- return 'deltaY' in s
- ? s.deltaY
- : 'wheelDeltaY' in s
- ? -s.wheelDeltaY
- : 'wheelDelta' in s
- ? -s.wheelDelta
- : 0;
- },
- deltaZ: 0,
- deltaMode: 0
- }),
- Er = rd(_r),
- wr = [9, 13, 27, 32],
- Sr = C && 'CompositionEvent' in window,
- xr = null;
- C && 'documentMode' in document && (xr = document.documentMode);
- var kr = C && 'TextEvent' in window && !xr,
- Cr = C && (!Sr || (xr && 8 < xr && 11 >= xr)),
- Or = String.fromCharCode(32),
- Ar = !1;
- function ge(s, o) {
- switch (s) {
- case 'keyup':
- return -1 !== wr.indexOf(o.keyCode);
- case 'keydown':
- return 229 !== o.keyCode;
- case 'keypress':
- case 'mousedown':
- case 'focusout':
- return !0;
- default:
- return !1;
- }
- }
- function he(s) {
- return 'object' == typeof (s = s.detail) && 'data' in s ? s.data : null;
- }
- var jr = !1;
- var Ir = {
- color: !0,
- date: !0,
- datetime: !0,
- 'datetime-local': !0,
- email: !0,
- month: !0,
- number: !0,
- password: !0,
- range: !0,
- search: !0,
- tel: !0,
- text: !0,
- time: !0,
- url: !0,
- week: !0
- };
- function me(s) {
- var o = s && s.nodeName && s.nodeName.toLowerCase();
- return 'input' === o ? !!Ir[s.type] : 'textarea' === o;
- }
- function ne(s, o, i, u) {
- Eb(u),
- 0 < (o = oe(o, 'onChange')).length &&
- ((i = new Qt('onChange', 'change', null, i, u)),
- s.push({ event: i, listeners: o }));
- }
- var Pr = null,
- Mr = null;
- function re(s) {
- se(s, 0);
- }
- function te(s) {
- if (Wa(ue(s))) return s;
- }
- function ve(s, o) {
- if ('change' === s) return o;
- }
- var Tr = !1;
- if (C) {
- var Nr;
- if (C) {
- var Rr = 'oninput' in document;
- if (!Rr) {
- var Dr = document.createElement('div');
- Dr.setAttribute('oninput', 'return;'), (Rr = 'function' == typeof Dr.oninput);
- }
- Nr = Rr;
- } else Nr = !1;
- Tr = Nr && (!document.documentMode || 9 < document.documentMode);
- }
- function Ae() {
- Pr && (Pr.detachEvent('onpropertychange', Be), (Mr = Pr = null));
- }
- function Be(s) {
- if ('value' === s.propertyName && te(Mr)) {
- var o = [];
- ne(o, Mr, s, xb(s)), Jb(re, o);
- }
- }
- function Ce(s, o, i) {
- 'focusin' === s
- ? (Ae(), (Mr = i), (Pr = o).attachEvent('onpropertychange', Be))
- : 'focusout' === s && Ae();
- }
- function De(s) {
- if ('selectionchange' === s || 'keyup' === s || 'keydown' === s) return te(Mr);
- }
- function Ee(s, o) {
- if ('click' === s) return te(o);
- }
- function Fe(s, o) {
- if ('input' === s || 'change' === s) return te(o);
- }
- var Lr =
- 'function' == typeof Object.is
- ? Object.is
- : function Ge(s, o) {
- return (s === o && (0 !== s || 1 / s == 1 / o)) || (s != s && o != o);
- };
- function Ie(s, o) {
- if (Lr(s, o)) return !0;
- if ('object' != typeof s || null === s || 'object' != typeof o || null === o) return !1;
- var i = Object.keys(s),
- u = Object.keys(o);
- if (i.length !== u.length) return !1;
- for (u = 0; u < i.length; u++) {
- var _ = i[u];
- if (!j.call(o, _) || !Lr(s[_], o[_])) return !1;
- }
- return !0;
- }
- function Je(s) {
- for (; s && s.firstChild; ) s = s.firstChild;
- return s;
- }
- function Ke(s, o) {
- var i,
- u = Je(s);
- for (s = 0; u; ) {
- if (3 === u.nodeType) {
- if (((i = s + u.textContent.length), s <= o && i >= o))
- return { node: u, offset: o - s };
- s = i;
- }
- e: {
- for (; u; ) {
- if (u.nextSibling) {
- u = u.nextSibling;
- break e;
- }
- u = u.parentNode;
- }
- u = void 0;
- }
- u = Je(u);
- }
- }
- function Le(s, o) {
- return (
- !(!s || !o) &&
- (s === o ||
- ((!s || 3 !== s.nodeType) &&
- (o && 3 === o.nodeType
- ? Le(s, o.parentNode)
- : 'contains' in s
- ? s.contains(o)
- : !!s.compareDocumentPosition && !!(16 & s.compareDocumentPosition(o)))))
- );
- }
- function Me() {
- for (var s = window, o = Xa(); o instanceof s.HTMLIFrameElement; ) {
- try {
- var i = 'string' == typeof o.contentWindow.location.href;
- } catch (s) {
- i = !1;
- }
- if (!i) break;
- o = Xa((s = o.contentWindow).document);
- }
- return o;
- }
- function Ne(s) {
- var o = s && s.nodeName && s.nodeName.toLowerCase();
- return (
- o &&
- (('input' === o &&
- ('text' === s.type ||
- 'search' === s.type ||
- 'tel' === s.type ||
- 'url' === s.type ||
- 'password' === s.type)) ||
- 'textarea' === o ||
- 'true' === s.contentEditable)
- );
- }
- function Oe(s) {
- var o = Me(),
- i = s.focusedElem,
- u = s.selectionRange;
- if (o !== i && i && i.ownerDocument && Le(i.ownerDocument.documentElement, i)) {
- if (null !== u && Ne(i))
- if (((o = u.start), void 0 === (s = u.end) && (s = o), 'selectionStart' in i))
- (i.selectionStart = o), (i.selectionEnd = Math.min(s, i.value.length));
- else if (
- (s = ((o = i.ownerDocument || document) && o.defaultView) || window).getSelection
- ) {
- s = s.getSelection();
- var _ = i.textContent.length,
- w = Math.min(u.start, _);
- (u = void 0 === u.end ? w : Math.min(u.end, _)),
- !s.extend && w > u && ((_ = u), (u = w), (w = _)),
- (_ = Ke(i, w));
- var x = Ke(i, u);
- _ &&
- x &&
- (1 !== s.rangeCount ||
- s.anchorNode !== _.node ||
- s.anchorOffset !== _.offset ||
- s.focusNode !== x.node ||
- s.focusOffset !== x.offset) &&
- ((o = o.createRange()).setStart(_.node, _.offset),
- s.removeAllRanges(),
- w > u
- ? (s.addRange(o), s.extend(x.node, x.offset))
- : (o.setEnd(x.node, x.offset), s.addRange(o)));
- }
- for (o = [], s = i; (s = s.parentNode); )
- 1 === s.nodeType && o.push({ element: s, left: s.scrollLeft, top: s.scrollTop });
- for ('function' == typeof i.focus && i.focus(), i = 0; i < o.length; i++)
- ((s = o[i]).element.scrollLeft = s.left), (s.element.scrollTop = s.top);
- }
- }
- var Br = C && 'documentMode' in document && 11 >= document.documentMode,
- Fr = null,
- qr = null,
- $r = null,
- Vr = !1;
- function Ue(s, o, i) {
- var u = i.window === i ? i.document : 9 === i.nodeType ? i : i.ownerDocument;
- Vr ||
- null == Fr ||
- Fr !== Xa(u) ||
- ('selectionStart' in (u = Fr) && Ne(u)
- ? (u = { start: u.selectionStart, end: u.selectionEnd })
- : (u = {
- anchorNode: (u = (
- (u.ownerDocument && u.ownerDocument.defaultView) ||
- window
- ).getSelection()).anchorNode,
- anchorOffset: u.anchorOffset,
- focusNode: u.focusNode,
- focusOffset: u.focusOffset
- }),
- ($r && Ie($r, u)) ||
- (($r = u),
- 0 < (u = oe(qr, 'onSelect')).length &&
- ((o = new Qt('onSelect', 'select', null, o, i)),
- s.push({ event: o, listeners: u }),
- (o.target = Fr))));
- }
- function Ve(s, o) {
- var i = {};
- return (
- (i[s.toLowerCase()] = o.toLowerCase()),
- (i['Webkit' + s] = 'webkit' + o),
- (i['Moz' + s] = 'moz' + o),
- i
- );
- }
- var Ur = {
- animationend: Ve('Animation', 'AnimationEnd'),
- animationiteration: Ve('Animation', 'AnimationIteration'),
- animationstart: Ve('Animation', 'AnimationStart'),
- transitionend: Ve('Transition', 'TransitionEnd')
- },
- zr = {},
- Wr = {};
- function Ze(s) {
- if (zr[s]) return zr[s];
- if (!Ur[s]) return s;
- var o,
- i = Ur[s];
- for (o in i) if (i.hasOwnProperty(o) && o in Wr) return (zr[s] = i[o]);
- return s;
- }
- C &&
- ((Wr = document.createElement('div').style),
- 'AnimationEvent' in window ||
- (delete Ur.animationend.animation,
- delete Ur.animationiteration.animation,
- delete Ur.animationstart.animation),
- 'TransitionEvent' in window || delete Ur.transitionend.transition);
- var Kr = Ze('animationend'),
- Hr = Ze('animationiteration'),
- Jr = Ze('animationstart'),
- Gr = Ze('transitionend'),
- Yr = new Map(),
- Xr =
- 'abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel'.split(
- ' '
- );
- function ff(s, o) {
- Yr.set(s, o), fa(o, [s]);
- }
- for (var Zr = 0; Zr < Xr.length; Zr++) {
- var Qr = Xr[Zr];
- ff(Qr.toLowerCase(), 'on' + (Qr[0].toUpperCase() + Qr.slice(1)));
- }
- ff(Kr, 'onAnimationEnd'),
- ff(Hr, 'onAnimationIteration'),
- ff(Jr, 'onAnimationStart'),
- ff('dblclick', 'onDoubleClick'),
- ff('focusin', 'onFocus'),
- ff('focusout', 'onBlur'),
- ff(Gr, 'onTransitionEnd'),
- ha('onMouseEnter', ['mouseout', 'mouseover']),
- ha('onMouseLeave', ['mouseout', 'mouseover']),
- ha('onPointerEnter', ['pointerout', 'pointerover']),
- ha('onPointerLeave', ['pointerout', 'pointerover']),
- fa(
- 'onChange',
- 'change click focusin focusout input keydown keyup selectionchange'.split(' ')
- ),
- fa(
- 'onSelect',
- 'focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange'.split(
- ' '
- )
- ),
- fa('onBeforeInput', ['compositionend', 'keypress', 'textInput', 'paste']),
- fa(
- 'onCompositionEnd',
- 'compositionend focusout keydown keypress keyup mousedown'.split(' ')
- ),
- fa(
- 'onCompositionStart',
- 'compositionstart focusout keydown keypress keyup mousedown'.split(' ')
- ),
- fa(
- 'onCompositionUpdate',
- 'compositionupdate focusout keydown keypress keyup mousedown'.split(' ')
- );
- var en =
- 'abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting'.split(
- ' '
- ),
- tn = new Set('cancel close invalid load scroll toggle'.split(' ').concat(en));
- function nf(s, o, i) {
- var u = s.type || 'unknown-event';
- (s.currentTarget = i),
- (function Ub(s, o, i, u, _, w, x, C, j) {
- if ((Tb.apply(this, arguments), st)) {
- if (!st) throw Error(p(198));
- var L = ot;
- (st = !1), (ot = null), it || ((it = !0), (at = L));
- }
- })(u, o, void 0, s),
- (s.currentTarget = null);
- }
- function se(s, o) {
- o = !!(4 & o);
- for (var i = 0; i < s.length; i++) {
- var u = s[i],
- _ = u.event;
- u = u.listeners;
- e: {
- var w = void 0;
- if (o)
- for (var x = u.length - 1; 0 <= x; x--) {
- var C = u[x],
- j = C.instance,
- L = C.currentTarget;
- if (((C = C.listener), j !== w && _.isPropagationStopped())) break e;
- nf(_, C, L), (w = j);
- }
- else
- for (x = 0; x < u.length; x++) {
- if (
- ((j = (C = u[x]).instance),
- (L = C.currentTarget),
- (C = C.listener),
- j !== w && _.isPropagationStopped())
- )
- break e;
- nf(_, C, L), (w = j);
- }
- }
- }
- if (it) throw ((s = at), (it = !1), (at = null), s);
- }
- function D(s, o) {
- var i = o[gn];
- void 0 === i && (i = o[gn] = new Set());
- var u = s + '__bubble';
- i.has(u) || (pf(o, s, 2, !1), i.add(u));
- }
- function qf(s, o, i) {
- var u = 0;
- o && (u |= 4), pf(i, s, u, o);
- }
- var rn = '_reactListening' + Math.random().toString(36).slice(2);
- function sf(s) {
- if (!s[rn]) {
- (s[rn] = !0),
- w.forEach(function (o) {
- 'selectionchange' !== o && (tn.has(o) || qf(o, !1, s), qf(o, !0, s));
- });
- var o = 9 === s.nodeType ? s : s.ownerDocument;
- null === o || o[rn] || ((o[rn] = !0), qf('selectionchange', !1, o));
- }
- }
- function pf(s, o, i, u) {
- switch (jd(o)) {
- case 1:
- var _ = ed;
- break;
- case 4:
- _ = gd;
- break;
- default:
- _ = fd;
- }
- (i = _.bind(null, o, i, s)),
- (_ = void 0),
- !rt || ('touchstart' !== o && 'touchmove' !== o && 'wheel' !== o) || (_ = !0),
- u
- ? void 0 !== _
- ? s.addEventListener(o, i, { capture: !0, passive: _ })
- : s.addEventListener(o, i, !0)
- : void 0 !== _
- ? s.addEventListener(o, i, { passive: _ })
- : s.addEventListener(o, i, !1);
- }
- function hd(s, o, i, u, _) {
- var w = u;
- if (!(1 & o || 2 & o || null === u))
- e: for (;;) {
- if (null === u) return;
- var x = u.tag;
- if (3 === x || 4 === x) {
- var C = u.stateNode.containerInfo;
- if (C === _ || (8 === C.nodeType && C.parentNode === _)) break;
- if (4 === x)
- for (x = u.return; null !== x; ) {
- var j = x.tag;
- if (
- (3 === j || 4 === j) &&
- ((j = x.stateNode.containerInfo) === _ ||
- (8 === j.nodeType && j.parentNode === _))
- )
- return;
- x = x.return;
- }
- for (; null !== C; ) {
- if (null === (x = Wc(C))) return;
- if (5 === (j = x.tag) || 6 === j) {
- u = w = x;
- continue e;
- }
- C = C.parentNode;
- }
- }
- u = u.return;
- }
- Jb(function () {
- var u = w,
- _ = xb(i),
- x = [];
- e: {
- var C = Yr.get(s);
- if (void 0 !== C) {
- var j = Qt,
- L = s;
- switch (s) {
- case 'keypress':
- if (0 === od(i)) break e;
- case 'keydown':
- case 'keyup':
- j = gr;
- break;
- case 'focusin':
- (L = 'focus'), (j = ir);
- break;
- case 'focusout':
- (L = 'blur'), (j = ir);
- break;
- case 'beforeblur':
- case 'afterblur':
- j = ir;
- break;
- case 'click':
- if (2 === i.button) break e;
- case 'auxclick':
- case 'dblclick':
- case 'mousedown':
- case 'mousemove':
- case 'mouseup':
- case 'mouseout':
- case 'mouseover':
- case 'contextmenu':
- j = nr;
- break;
- case 'drag':
- case 'dragend':
- case 'dragenter':
- case 'dragexit':
- case 'dragleave':
- case 'dragover':
- case 'dragstart':
- case 'drop':
- j = sr;
- break;
- case 'touchcancel':
- case 'touchend':
- case 'touchmove':
- case 'touchstart':
- j = vr;
- break;
- case Kr:
- case Hr:
- case Jr:
- j = ar;
- break;
- case Gr:
- j = br;
- break;
- case 'scroll':
- j = tr;
- break;
- case 'wheel':
- j = Er;
- break;
- case 'copy':
- case 'cut':
- case 'paste':
- j = cr;
- break;
- case 'gotpointercapture':
- case 'lostpointercapture':
- case 'pointercancel':
- case 'pointerdown':
- case 'pointermove':
- case 'pointerout':
- case 'pointerover':
- case 'pointerup':
- j = yr;
- }
- var B = !!(4 & o),
- $ = !B && 'scroll' === s,
- V = B ? (null !== C ? C + 'Capture' : null) : C;
- B = [];
- for (var U, z = u; null !== z; ) {
- var Y = (U = z).stateNode;
- if (
- (5 === U.tag &&
- null !== Y &&
- ((U = Y), null !== V && null != (Y = Kb(z, V)) && B.push(tf(z, Y, U))),
- $)
- )
- break;
- z = z.return;
- }
- 0 < B.length &&
- ((C = new j(C, L, null, i, _)), x.push({ event: C, listeners: B }));
- }
- }
- if (!(7 & o)) {
- if (
- ((j = 'mouseout' === s || 'pointerout' === s),
- (!(C = 'mouseover' === s || 'pointerover' === s) ||
- i === Ye ||
- !(L = i.relatedTarget || i.fromElement) ||
- (!Wc(L) && !L[mn])) &&
- (j || C) &&
- ((C =
- _.window === _
- ? _
- : (C = _.ownerDocument)
- ? C.defaultView || C.parentWindow
- : window),
- j
- ? ((j = u),
- null !== (L = (L = i.relatedTarget || i.toElement) ? Wc(L) : null) &&
- (L !== ($ = Vb(L)) || (5 !== L.tag && 6 !== L.tag)) &&
- (L = null))
- : ((j = null), (L = u)),
- j !== L))
- ) {
- if (
- ((B = nr),
- (Y = 'onMouseLeave'),
- (V = 'onMouseEnter'),
- (z = 'mouse'),
- ('pointerout' !== s && 'pointerover' !== s) ||
- ((B = yr), (Y = 'onPointerLeave'), (V = 'onPointerEnter'), (z = 'pointer')),
- ($ = null == j ? C : ue(j)),
- (U = null == L ? C : ue(L)),
- ((C = new B(Y, z + 'leave', j, i, _)).target = $),
- (C.relatedTarget = U),
- (Y = null),
- Wc(_) === u &&
- (((B = new B(V, z + 'enter', L, i, _)).target = U),
- (B.relatedTarget = $),
- (Y = B)),
- ($ = Y),
- j && L)
- )
- e: {
- for (V = L, z = 0, U = B = j; U; U = vf(U)) z++;
- for (U = 0, Y = V; Y; Y = vf(Y)) U++;
- for (; 0 < z - U; ) (B = vf(B)), z--;
- for (; 0 < U - z; ) (V = vf(V)), U--;
- for (; z--; ) {
- if (B === V || (null !== V && B === V.alternate)) break e;
- (B = vf(B)), (V = vf(V));
- }
- B = null;
- }
- else B = null;
- null !== j && wf(x, C, j, B, !1), null !== L && null !== $ && wf(x, $, L, B, !0);
- }
- if (
- 'select' ===
- (j = (C = u ? ue(u) : window).nodeName && C.nodeName.toLowerCase()) ||
- ('input' === j && 'file' === C.type)
- )
- var Z = ve;
- else if (me(C))
- if (Tr) Z = Fe;
- else {
- Z = De;
- var ee = Ce;
- }
- else
- (j = C.nodeName) &&
- 'input' === j.toLowerCase() &&
- ('checkbox' === C.type || 'radio' === C.type) &&
- (Z = Ee);
- switch (
- (Z && (Z = Z(s, u))
- ? ne(x, Z, i, _)
- : (ee && ee(s, C, u),
- 'focusout' === s &&
- (ee = C._wrapperState) &&
- ee.controlled &&
- 'number' === C.type &&
- cb(C, 'number', C.value)),
- (ee = u ? ue(u) : window),
- s)
- ) {
- case 'focusin':
- (me(ee) || 'true' === ee.contentEditable) && ((Fr = ee), (qr = u), ($r = null));
- break;
- case 'focusout':
- $r = qr = Fr = null;
- break;
- case 'mousedown':
- Vr = !0;
- break;
- case 'contextmenu':
- case 'mouseup':
- case 'dragend':
- (Vr = !1), Ue(x, i, _);
- break;
- case 'selectionchange':
- if (Br) break;
- case 'keydown':
- case 'keyup':
- Ue(x, i, _);
- }
- var ie;
- if (Sr)
- e: {
- switch (s) {
- case 'compositionstart':
- var ae = 'onCompositionStart';
- break e;
- case 'compositionend':
- ae = 'onCompositionEnd';
- break e;
- case 'compositionupdate':
- ae = 'onCompositionUpdate';
- break e;
- }
- ae = void 0;
- }
- else
- jr
- ? ge(s, i) && (ae = 'onCompositionEnd')
- : 'keydown' === s && 229 === i.keyCode && (ae = 'onCompositionStart');
- ae &&
- (Cr &&
- 'ko' !== i.locale &&
- (jr || 'onCompositionStart' !== ae
- ? 'onCompositionEnd' === ae && jr && (ie = nd())
- : ((Ht = 'value' in (Kt = _) ? Kt.value : Kt.textContent), (jr = !0))),
- 0 < (ee = oe(u, ae)).length &&
- ((ae = new ur(ae, s, null, i, _)),
- x.push({ event: ae, listeners: ee }),
- ie ? (ae.data = ie) : null !== (ie = he(i)) && (ae.data = ie))),
- (ie = kr
- ? (function je(s, o) {
- switch (s) {
- case 'compositionend':
- return he(o);
- case 'keypress':
- return 32 !== o.which ? null : ((Ar = !0), Or);
- case 'textInput':
- return (s = o.data) === Or && Ar ? null : s;
- default:
- return null;
- }
- })(s, i)
- : (function ke(s, o) {
- if (jr)
- return 'compositionend' === s || (!Sr && ge(s, o))
- ? ((s = nd()), (Jt = Ht = Kt = null), (jr = !1), s)
- : null;
- switch (s) {
- case 'paste':
- default:
- return null;
- case 'keypress':
- if (!(o.ctrlKey || o.altKey || o.metaKey) || (o.ctrlKey && o.altKey)) {
- if (o.char && 1 < o.char.length) return o.char;
- if (o.which) return String.fromCharCode(o.which);
- }
- return null;
- case 'compositionend':
- return Cr && 'ko' !== o.locale ? null : o.data;
- }
- })(s, i)) &&
- 0 < (u = oe(u, 'onBeforeInput')).length &&
- ((_ = new ur('onBeforeInput', 'beforeinput', null, i, _)),
- x.push({ event: _, listeners: u }),
- (_.data = ie));
- }
- se(x, o);
- });
- }
- function tf(s, o, i) {
- return { instance: s, listener: o, currentTarget: i };
- }
- function oe(s, o) {
- for (var i = o + 'Capture', u = []; null !== s; ) {
- var _ = s,
- w = _.stateNode;
- 5 === _.tag &&
- null !== w &&
- ((_ = w),
- null != (w = Kb(s, i)) && u.unshift(tf(s, w, _)),
- null != (w = Kb(s, o)) && u.push(tf(s, w, _))),
- (s = s.return);
- }
- return u;
- }
- function vf(s) {
- if (null === s) return null;
- do {
- s = s.return;
- } while (s && 5 !== s.tag);
- return s || null;
- }
- function wf(s, o, i, u, _) {
- for (var w = o._reactName, x = []; null !== i && i !== u; ) {
- var C = i,
- j = C.alternate,
- L = C.stateNode;
- if (null !== j && j === u) break;
- 5 === C.tag &&
- null !== L &&
- ((C = L),
- _
- ? null != (j = Kb(i, w)) && x.unshift(tf(i, j, C))
- : _ || (null != (j = Kb(i, w)) && x.push(tf(i, j, C)))),
- (i = i.return);
- }
- 0 !== x.length && s.push({ event: o, listeners: x });
- }
- var nn = /\r\n?/g,
- sn = /\u0000|\uFFFD/g;
- function zf(s) {
- return ('string' == typeof s ? s : '' + s).replace(nn, '\n').replace(sn, '');
- }
- function Af(s, o, i) {
- if (((o = zf(o)), zf(s) !== o && i)) throw Error(p(425));
- }
- function Bf() {}
- var on = null,
- an = null;
- function Ef(s, o) {
- return (
- 'textarea' === s ||
- 'noscript' === s ||
- 'string' == typeof o.children ||
- 'number' == typeof o.children ||
- ('object' == typeof o.dangerouslySetInnerHTML &&
- null !== o.dangerouslySetInnerHTML &&
- null != o.dangerouslySetInnerHTML.__html)
- );
- }
- var ln = 'function' == typeof setTimeout ? setTimeout : void 0,
- cn = 'function' == typeof clearTimeout ? clearTimeout : void 0,
- un = 'function' == typeof Promise ? Promise : void 0,
- pn =
- 'function' == typeof queueMicrotask
- ? queueMicrotask
- : void 0 !== un
- ? function (s) {
- return un.resolve(null).then(s).catch(If);
- }
- : ln;
- function If(s) {
- setTimeout(function () {
- throw s;
- });
- }
- function Kf(s, o) {
- var i = o,
- u = 0;
- do {
- var _ = i.nextSibling;
- if ((s.removeChild(i), _ && 8 === _.nodeType))
- if ('/$' === (i = _.data)) {
- if (0 === u) return s.removeChild(_), void bd(o);
- u--;
- } else ('$' !== i && '$?' !== i && '$!' !== i) || u++;
- i = _;
- } while (i);
- bd(o);
- }
- function Lf(s) {
- for (; null != s; s = s.nextSibling) {
- var o = s.nodeType;
- if (1 === o || 3 === o) break;
- if (8 === o) {
- if ('$' === (o = s.data) || '$!' === o || '$?' === o) break;
- if ('/$' === o) return null;
- }
- }
- return s;
- }
- function Mf(s) {
- s = s.previousSibling;
- for (var o = 0; s; ) {
- if (8 === s.nodeType) {
- var i = s.data;
- if ('$' === i || '$!' === i || '$?' === i) {
- if (0 === o) return s;
- o--;
- } else '/$' === i && o++;
- }
- s = s.previousSibling;
- }
- return null;
- }
- var hn = Math.random().toString(36).slice(2),
- dn = '__reactFiber$' + hn,
- fn = '__reactProps$' + hn,
- mn = '__reactContainer$' + hn,
- gn = '__reactEvents$' + hn,
- yn = '__reactListeners$' + hn,
- vn = '__reactHandles$' + hn;
- function Wc(s) {
- var o = s[dn];
- if (o) return o;
- for (var i = s.parentNode; i; ) {
- if ((o = i[mn] || i[dn])) {
- if (((i = o.alternate), null !== o.child || (null !== i && null !== i.child)))
- for (s = Mf(s); null !== s; ) {
- if ((i = s[dn])) return i;
- s = Mf(s);
- }
- return o;
- }
- i = (s = i).parentNode;
- }
- return null;
- }
- function Cb(s) {
- return !(s = s[dn] || s[mn]) ||
- (5 !== s.tag && 6 !== s.tag && 13 !== s.tag && 3 !== s.tag)
- ? null
- : s;
- }
- function ue(s) {
- if (5 === s.tag || 6 === s.tag) return s.stateNode;
- throw Error(p(33));
- }
- function Db(s) {
- return s[fn] || null;
- }
- var bn = [],
- _n = -1;
- function Uf(s) {
- return { current: s };
- }
- function E(s) {
- 0 > _n || ((s.current = bn[_n]), (bn[_n] = null), _n--);
- }
- function G(s, o) {
- _n++, (bn[_n] = s.current), (s.current = o);
- }
- var En = {},
- wn = Uf(En),
- Sn = Uf(!1),
- xn = En;
- function Yf(s, o) {
- var i = s.type.contextTypes;
- if (!i) return En;
- var u = s.stateNode;
- if (u && u.__reactInternalMemoizedUnmaskedChildContext === o)
- return u.__reactInternalMemoizedMaskedChildContext;
- var _,
- w = {};
- for (_ in i) w[_] = o[_];
- return (
- u &&
- (((s = s.stateNode).__reactInternalMemoizedUnmaskedChildContext = o),
- (s.__reactInternalMemoizedMaskedChildContext = w)),
- w
- );
- }
- function Zf(s) {
- return null != (s = s.childContextTypes);
- }
- function $f() {
- E(Sn), E(wn);
- }
- function ag(s, o, i) {
- if (wn.current !== En) throw Error(p(168));
- G(wn, o), G(Sn, i);
- }
- function bg(s, o, i) {
- var u = s.stateNode;
- if (((o = o.childContextTypes), 'function' != typeof u.getChildContext)) return i;
- for (var _ in (u = u.getChildContext()))
- if (!(_ in o)) throw Error(p(108, Ra(s) || 'Unknown', _));
- return xe({}, i, u);
- }
- function cg(s) {
- return (
- (s = ((s = s.stateNode) && s.__reactInternalMemoizedMergedChildContext) || En),
- (xn = wn.current),
- G(wn, s),
- G(Sn, Sn.current),
- !0
- );
- }
- function dg(s, o, i) {
- var u = s.stateNode;
- if (!u) throw Error(p(169));
- i
- ? ((s = bg(s, o, xn)),
- (u.__reactInternalMemoizedMergedChildContext = s),
- E(Sn),
- E(wn),
- G(wn, s))
- : E(Sn),
- G(Sn, i);
- }
- var kn = null,
- Cn = !1,
- On = !1;
- function hg(s) {
- null === kn ? (kn = [s]) : kn.push(s);
- }
- function jg() {
- if (!On && null !== kn) {
- On = !0;
- var s = 0,
- o = At;
- try {
- var i = kn;
- for (At = 1; s < i.length; s++) {
- var u = i[s];
- do {
- u = u(!0);
- } while (null !== u);
- }
- (kn = null), (Cn = !1);
- } catch (o) {
- throw (null !== kn && (kn = kn.slice(s + 1)), ct(gt, jg), o);
- } finally {
- (At = o), (On = !1);
- }
- }
- return null;
- }
- var An = [],
- jn = 0,
- In = null,
- Pn = 0,
- Mn = [],
- Tn = 0,
- Nn = null,
- Rn = 1,
- Dn = '';
- function tg(s, o) {
- (An[jn++] = Pn), (An[jn++] = In), (In = s), (Pn = o);
- }
- function ug(s, o, i) {
- (Mn[Tn++] = Rn), (Mn[Tn++] = Dn), (Mn[Tn++] = Nn), (Nn = s);
- var u = Rn;
- s = Dn;
- var _ = 32 - St(u) - 1;
- (u &= ~(1 << _)), (i += 1);
- var w = 32 - St(o) + _;
- if (30 < w) {
- var x = _ - (_ % 5);
- (w = (u & ((1 << x) - 1)).toString(32)),
- (u >>= x),
- (_ -= x),
- (Rn = (1 << (32 - St(o) + _)) | (i << _) | u),
- (Dn = w + s);
- } else (Rn = (1 << w) | (i << _) | u), (Dn = s);
- }
- function vg(s) {
- null !== s.return && (tg(s, 1), ug(s, 1, 0));
- }
- function wg(s) {
- for (; s === In; ) (In = An[--jn]), (An[jn] = null), (Pn = An[--jn]), (An[jn] = null);
- for (; s === Nn; )
- (Nn = Mn[--Tn]),
- (Mn[Tn] = null),
- (Dn = Mn[--Tn]),
- (Mn[Tn] = null),
- (Rn = Mn[--Tn]),
- (Mn[Tn] = null);
- }
- var Ln = null,
- Bn = null,
- Fn = !1,
- qn = null;
- function Ag(s, o) {
- var i = Bg(5, null, null, 0);
- (i.elementType = 'DELETED'),
- (i.stateNode = o),
- (i.return = s),
- null === (o = s.deletions) ? ((s.deletions = [i]), (s.flags |= 16)) : o.push(i);
- }
- function Cg(s, o) {
- switch (s.tag) {
- case 5:
- var i = s.type;
- return (
- null !==
- (o =
- 1 !== o.nodeType || i.toLowerCase() !== o.nodeName.toLowerCase()
- ? null
- : o) && ((s.stateNode = o), (Ln = s), (Bn = Lf(o.firstChild)), !0)
- );
- case 6:
- return (
- null !== (o = '' === s.pendingProps || 3 !== o.nodeType ? null : o) &&
- ((s.stateNode = o), (Ln = s), (Bn = null), !0)
- );
- case 13:
- return (
- null !== (o = 8 !== o.nodeType ? null : o) &&
- ((i = null !== Nn ? { id: Rn, overflow: Dn } : null),
- (s.memoizedState = { dehydrated: o, treeContext: i, retryLane: 1073741824 }),
- ((i = Bg(18, null, null, 0)).stateNode = o),
- (i.return = s),
- (s.child = i),
- (Ln = s),
- (Bn = null),
- !0)
- );
- default:
- return !1;
- }
- }
- function Dg(s) {
- return !(!(1 & s.mode) || 128 & s.flags);
- }
- function Eg(s) {
- if (Fn) {
- var o = Bn;
- if (o) {
- var i = o;
- if (!Cg(s, o)) {
- if (Dg(s)) throw Error(p(418));
- o = Lf(i.nextSibling);
- var u = Ln;
- o && Cg(s, o)
- ? Ag(u, i)
- : ((s.flags = (-4097 & s.flags) | 2), (Fn = !1), (Ln = s));
- }
- } else {
- if (Dg(s)) throw Error(p(418));
- (s.flags = (-4097 & s.flags) | 2), (Fn = !1), (Ln = s);
- }
- }
- }
- function Fg(s) {
- for (s = s.return; null !== s && 5 !== s.tag && 3 !== s.tag && 13 !== s.tag; )
- s = s.return;
- Ln = s;
- }
- function Gg(s) {
- if (s !== Ln) return !1;
- if (!Fn) return Fg(s), (Fn = !0), !1;
- var o;
- if (
- ((o = 3 !== s.tag) &&
- !(o = 5 !== s.tag) &&
- (o = 'head' !== (o = s.type) && 'body' !== o && !Ef(s.type, s.memoizedProps)),
- o && (o = Bn))
- ) {
- if (Dg(s)) throw (Hg(), Error(p(418)));
- for (; o; ) Ag(s, o), (o = Lf(o.nextSibling));
- }
- if ((Fg(s), 13 === s.tag)) {
- if (!(s = null !== (s = s.memoizedState) ? s.dehydrated : null)) throw Error(p(317));
- e: {
- for (s = s.nextSibling, o = 0; s; ) {
- if (8 === s.nodeType) {
- var i = s.data;
- if ('/$' === i) {
- if (0 === o) {
- Bn = Lf(s.nextSibling);
- break e;
- }
- o--;
- } else ('$' !== i && '$!' !== i && '$?' !== i) || o++;
- }
- s = s.nextSibling;
- }
- Bn = null;
- }
- } else Bn = Ln ? Lf(s.stateNode.nextSibling) : null;
- return !0;
- }
- function Hg() {
- for (var s = Bn; s; ) s = Lf(s.nextSibling);
- }
- function Ig() {
- (Bn = Ln = null), (Fn = !1);
- }
- function Jg(s) {
- null === qn ? (qn = [s]) : qn.push(s);
- }
- var $n = z.ReactCurrentBatchConfig;
- function Lg(s, o, i) {
- if (null !== (s = i.ref) && 'function' != typeof s && 'object' != typeof s) {
- if (i._owner) {
- if ((i = i._owner)) {
- if (1 !== i.tag) throw Error(p(309));
- var u = i.stateNode;
- }
- if (!u) throw Error(p(147, s));
- var _ = u,
- w = '' + s;
- return null !== o &&
- null !== o.ref &&
- 'function' == typeof o.ref &&
- o.ref._stringRef === w
- ? o.ref
- : ((o = function (s) {
- var o = _.refs;
- null === s ? delete o[w] : (o[w] = s);
- }),
- (o._stringRef = w),
- o);
- }
- if ('string' != typeof s) throw Error(p(284));
- if (!i._owner) throw Error(p(290, s));
- }
- return s;
- }
- function Mg(s, o) {
- throw (
- ((s = Object.prototype.toString.call(o)),
- Error(
- p(
- 31,
- '[object Object]' === s
- ? 'object with keys {' + Object.keys(o).join(', ') + '}'
- : s
- )
- ))
- );
- }
- function Ng(s) {
- return (0, s._init)(s._payload);
- }
- function Og(s) {
- function b(o, i) {
- if (s) {
- var u = o.deletions;
- null === u ? ((o.deletions = [i]), (o.flags |= 16)) : u.push(i);
- }
- }
- function c(o, i) {
- if (!s) return null;
- for (; null !== i; ) b(o, i), (i = i.sibling);
- return null;
- }
- function d(s, o) {
- for (s = new Map(); null !== o; )
- null !== o.key ? s.set(o.key, o) : s.set(o.index, o), (o = o.sibling);
- return s;
- }
- function e(s, o) {
- return ((s = Pg(s, o)).index = 0), (s.sibling = null), s;
- }
- function f(o, i, u) {
- return (
- (o.index = u),
- s
- ? null !== (u = o.alternate)
- ? (u = u.index) < i
- ? ((o.flags |= 2), i)
- : u
- : ((o.flags |= 2), i)
- : ((o.flags |= 1048576), i)
- );
- }
- function g(o) {
- return s && null === o.alternate && (o.flags |= 2), o;
- }
- function h(s, o, i, u) {
- return null === o || 6 !== o.tag
- ? (((o = Qg(i, s.mode, u)).return = s), o)
- : (((o = e(o, i)).return = s), o);
- }
- function k(s, o, i, u) {
- var _ = i.type;
- return _ === ee
- ? m(s, o, i.props.children, u, i.key)
- : null !== o &&
- (o.elementType === _ ||
- ('object' == typeof _ && null !== _ && _.$$typeof === be && Ng(_) === o.type))
- ? (((u = e(o, i.props)).ref = Lg(s, o, i)), (u.return = s), u)
- : (((u = Rg(i.type, i.key, i.props, null, s.mode, u)).ref = Lg(s, o, i)),
- (u.return = s),
- u);
- }
- function l(s, o, i, u) {
- return null === o ||
- 4 !== o.tag ||
- o.stateNode.containerInfo !== i.containerInfo ||
- o.stateNode.implementation !== i.implementation
- ? (((o = Sg(i, s.mode, u)).return = s), o)
- : (((o = e(o, i.children || [])).return = s), o);
- }
- function m(s, o, i, u, _) {
- return null === o || 7 !== o.tag
- ? (((o = Tg(i, s.mode, u, _)).return = s), o)
- : (((o = e(o, i)).return = s), o);
- }
- function q(s, o, i) {
- if (('string' == typeof o && '' !== o) || 'number' == typeof o)
- return ((o = Qg('' + o, s.mode, i)).return = s), o;
- if ('object' == typeof o && null !== o) {
- switch (o.$$typeof) {
- case Y:
- return (
- ((i = Rg(o.type, o.key, o.props, null, s.mode, i)).ref = Lg(s, null, o)),
- (i.return = s),
- i
- );
- case Z:
- return ((o = Sg(o, s.mode, i)).return = s), o;
- case be:
- return q(s, (0, o._init)(o._payload), i);
- }
- if (Te(o) || Ka(o)) return ((o = Tg(o, s.mode, i, null)).return = s), o;
- Mg(s, o);
- }
- return null;
- }
- function r(s, o, i, u) {
- var _ = null !== o ? o.key : null;
- if (('string' == typeof i && '' !== i) || 'number' == typeof i)
- return null !== _ ? null : h(s, o, '' + i, u);
- if ('object' == typeof i && null !== i) {
- switch (i.$$typeof) {
- case Y:
- return i.key === _ ? k(s, o, i, u) : null;
- case Z:
- return i.key === _ ? l(s, o, i, u) : null;
- case be:
- return r(s, o, (_ = i._init)(i._payload), u);
- }
- if (Te(i) || Ka(i)) return null !== _ ? null : m(s, o, i, u, null);
- Mg(s, i);
- }
- return null;
- }
- function y(s, o, i, u, _) {
- if (('string' == typeof u && '' !== u) || 'number' == typeof u)
- return h(o, (s = s.get(i) || null), '' + u, _);
- if ('object' == typeof u && null !== u) {
- switch (u.$$typeof) {
- case Y:
- return k(o, (s = s.get(null === u.key ? i : u.key) || null), u, _);
- case Z:
- return l(o, (s = s.get(null === u.key ? i : u.key) || null), u, _);
- case be:
- return y(s, o, i, (0, u._init)(u._payload), _);
- }
- if (Te(u) || Ka(u)) return m(o, (s = s.get(i) || null), u, _, null);
- Mg(o, u);
- }
- return null;
- }
- function n(o, i, u, _) {
- for (
- var w = null, x = null, C = i, j = (i = 0), L = null;
- null !== C && j < u.length;
- j++
- ) {
- C.index > j ? ((L = C), (C = null)) : (L = C.sibling);
- var B = r(o, C, u[j], _);
- if (null === B) {
- null === C && (C = L);
- break;
- }
- s && C && null === B.alternate && b(o, C),
- (i = f(B, i, j)),
- null === x ? (w = B) : (x.sibling = B),
- (x = B),
- (C = L);
- }
- if (j === u.length) return c(o, C), Fn && tg(o, j), w;
- if (null === C) {
- for (; j < u.length; j++)
- null !== (C = q(o, u[j], _)) &&
- ((i = f(C, i, j)), null === x ? (w = C) : (x.sibling = C), (x = C));
- return Fn && tg(o, j), w;
- }
- for (C = d(o, C); j < u.length; j++)
- null !== (L = y(C, o, j, u[j], _)) &&
- (s && null !== L.alternate && C.delete(null === L.key ? j : L.key),
- (i = f(L, i, j)),
- null === x ? (w = L) : (x.sibling = L),
- (x = L));
- return (
- s &&
- C.forEach(function (s) {
- return b(o, s);
- }),
- Fn && tg(o, j),
- w
- );
- }
- function t(o, i, u, _) {
- var w = Ka(u);
- if ('function' != typeof w) throw Error(p(150));
- if (null == (u = w.call(u))) throw Error(p(151));
- for (
- var x = (w = null), C = i, j = (i = 0), L = null, B = u.next();
- null !== C && !B.done;
- j++, B = u.next()
- ) {
- C.index > j ? ((L = C), (C = null)) : (L = C.sibling);
- var $ = r(o, C, B.value, _);
- if (null === $) {
- null === C && (C = L);
- break;
- }
- s && C && null === $.alternate && b(o, C),
- (i = f($, i, j)),
- null === x ? (w = $) : (x.sibling = $),
- (x = $),
- (C = L);
- }
- if (B.done) return c(o, C), Fn && tg(o, j), w;
- if (null === C) {
- for (; !B.done; j++, B = u.next())
- null !== (B = q(o, B.value, _)) &&
- ((i = f(B, i, j)), null === x ? (w = B) : (x.sibling = B), (x = B));
- return Fn && tg(o, j), w;
- }
- for (C = d(o, C); !B.done; j++, B = u.next())
- null !== (B = y(C, o, j, B.value, _)) &&
- (s && null !== B.alternate && C.delete(null === B.key ? j : B.key),
- (i = f(B, i, j)),
- null === x ? (w = B) : (x.sibling = B),
- (x = B));
- return (
- s &&
- C.forEach(function (s) {
- return b(o, s);
- }),
- Fn && tg(o, j),
- w
- );
- }
- return function J(s, o, i, u) {
- if (
- ('object' == typeof i &&
- null !== i &&
- i.type === ee &&
- null === i.key &&
- (i = i.props.children),
- 'object' == typeof i && null !== i)
- ) {
- switch (i.$$typeof) {
- case Y:
- e: {
- for (var _ = i.key, w = o; null !== w; ) {
- if (w.key === _) {
- if ((_ = i.type) === ee) {
- if (7 === w.tag) {
- c(s, w.sibling), ((o = e(w, i.props.children)).return = s), (s = o);
- break e;
- }
- } else if (
- w.elementType === _ ||
- ('object' == typeof _ &&
- null !== _ &&
- _.$$typeof === be &&
- Ng(_) === w.type)
- ) {
- c(s, w.sibling),
- ((o = e(w, i.props)).ref = Lg(s, w, i)),
- (o.return = s),
- (s = o);
- break e;
- }
- c(s, w);
- break;
- }
- b(s, w), (w = w.sibling);
- }
- i.type === ee
- ? (((o = Tg(i.props.children, s.mode, u, i.key)).return = s), (s = o))
- : (((u = Rg(i.type, i.key, i.props, null, s.mode, u)).ref = Lg(s, o, i)),
- (u.return = s),
- (s = u));
- }
- return g(s);
- case Z:
- e: {
- for (w = i.key; null !== o; ) {
- if (o.key === w) {
- if (
- 4 === o.tag &&
- o.stateNode.containerInfo === i.containerInfo &&
- o.stateNode.implementation === i.implementation
- ) {
- c(s, o.sibling), ((o = e(o, i.children || [])).return = s), (s = o);
- break e;
- }
- c(s, o);
- break;
- }
- b(s, o), (o = o.sibling);
- }
- ((o = Sg(i, s.mode, u)).return = s), (s = o);
- }
- return g(s);
- case be:
- return J(s, o, (w = i._init)(i._payload), u);
- }
- if (Te(i)) return n(s, o, i, u);
- if (Ka(i)) return t(s, o, i, u);
- Mg(s, i);
- }
- return ('string' == typeof i && '' !== i) || 'number' == typeof i
- ? ((i = '' + i),
- null !== o && 6 === o.tag
- ? (c(s, o.sibling), ((o = e(o, i)).return = s), (s = o))
- : (c(s, o), ((o = Qg(i, s.mode, u)).return = s), (s = o)),
- g(s))
- : c(s, o);
- };
- }
- var Vn = Og(!0),
- Un = Og(!1),
- zn = Uf(null),
- Wn = null,
- Kn = null,
- Hn = null;
- function $g() {
- Hn = Kn = Wn = null;
- }
- function ah(s) {
- var o = zn.current;
- E(zn), (s._currentValue = o);
- }
- function bh(s, o, i) {
- for (; null !== s; ) {
- var u = s.alternate;
- if (
- ((s.childLanes & o) !== o
- ? ((s.childLanes |= o), null !== u && (u.childLanes |= o))
- : null !== u && (u.childLanes & o) !== o && (u.childLanes |= o),
- s === i)
- )
- break;
- s = s.return;
- }
- }
- function ch(s, o) {
- (Wn = s),
- (Hn = Kn = null),
- null !== (s = s.dependencies) &&
- null !== s.firstContext &&
- (!!(s.lanes & o) && (_s = !0), (s.firstContext = null));
- }
- function eh(s) {
- var o = s._currentValue;
- if (Hn !== s)
- if (((s = { context: s, memoizedValue: o, next: null }), null === Kn)) {
- if (null === Wn) throw Error(p(308));
- (Kn = s), (Wn.dependencies = { lanes: 0, firstContext: s });
- } else Kn = Kn.next = s;
- return o;
- }
- var Jn = null;
- function gh(s) {
- null === Jn ? (Jn = [s]) : Jn.push(s);
- }
- function hh(s, o, i, u) {
- var _ = o.interleaved;
- return (
- null === _ ? ((i.next = i), gh(o)) : ((i.next = _.next), (_.next = i)),
- (o.interleaved = i),
- ih(s, u)
- );
- }
- function ih(s, o) {
- s.lanes |= o;
- var i = s.alternate;
- for (null !== i && (i.lanes |= o), i = s, s = s.return; null !== s; )
- (s.childLanes |= o),
- null !== (i = s.alternate) && (i.childLanes |= o),
- (i = s),
- (s = s.return);
- return 3 === i.tag ? i.stateNode : null;
- }
- var Gn = !1;
- function kh(s) {
- s.updateQueue = {
- baseState: s.memoizedState,
- firstBaseUpdate: null,
- lastBaseUpdate: null,
- shared: { pending: null, interleaved: null, lanes: 0 },
- effects: null
- };
- }
- function lh(s, o) {
- (s = s.updateQueue),
- o.updateQueue === s &&
- (o.updateQueue = {
- baseState: s.baseState,
- firstBaseUpdate: s.firstBaseUpdate,
- lastBaseUpdate: s.lastBaseUpdate,
- shared: s.shared,
- effects: s.effects
- });
- }
- function mh(s, o) {
- return { eventTime: s, lane: o, tag: 0, payload: null, callback: null, next: null };
- }
- function nh(s, o, i) {
- var u = s.updateQueue;
- if (null === u) return null;
- if (((u = u.shared), 2 & Bs)) {
- var _ = u.pending;
- return (
- null === _ ? (o.next = o) : ((o.next = _.next), (_.next = o)),
- (u.pending = o),
- ih(s, i)
- );
- }
- return (
- null === (_ = u.interleaved)
- ? ((o.next = o), gh(u))
- : ((o.next = _.next), (_.next = o)),
- (u.interleaved = o),
- ih(s, i)
- );
- }
- function oh(s, o, i) {
- if (null !== (o = o.updateQueue) && ((o = o.shared), 4194240 & i)) {
- var u = o.lanes;
- (i |= u &= s.pendingLanes), (o.lanes = i), Cc(s, i);
- }
- }
- function ph(s, o) {
- var i = s.updateQueue,
- u = s.alternate;
- if (null !== u && i === (u = u.updateQueue)) {
- var _ = null,
- w = null;
- if (null !== (i = i.firstBaseUpdate)) {
- do {
- var x = {
- eventTime: i.eventTime,
- lane: i.lane,
- tag: i.tag,
- payload: i.payload,
- callback: i.callback,
- next: null
- };
- null === w ? (_ = w = x) : (w = w.next = x), (i = i.next);
- } while (null !== i);
- null === w ? (_ = w = o) : (w = w.next = o);
- } else _ = w = o;
- return (
- (i = {
- baseState: u.baseState,
- firstBaseUpdate: _,
- lastBaseUpdate: w,
- shared: u.shared,
- effects: u.effects
- }),
- void (s.updateQueue = i)
- );
- }
- null === (s = i.lastBaseUpdate) ? (i.firstBaseUpdate = o) : (s.next = o),
- (i.lastBaseUpdate = o);
- }
- function qh(s, o, i, u) {
- var _ = s.updateQueue;
- Gn = !1;
- var w = _.firstBaseUpdate,
- x = _.lastBaseUpdate,
- C = _.shared.pending;
- if (null !== C) {
- _.shared.pending = null;
- var j = C,
- L = j.next;
- (j.next = null), null === x ? (w = L) : (x.next = L), (x = j);
- var B = s.alternate;
- null !== B &&
- (C = (B = B.updateQueue).lastBaseUpdate) !== x &&
- (null === C ? (B.firstBaseUpdate = L) : (C.next = L), (B.lastBaseUpdate = j));
- }
- if (null !== w) {
- var $ = _.baseState;
- for (x = 0, B = L = j = null, C = w; ; ) {
- var V = C.lane,
- U = C.eventTime;
- if ((u & V) === V) {
- null !== B &&
- (B = B.next =
- {
- eventTime: U,
- lane: 0,
- tag: C.tag,
- payload: C.payload,
- callback: C.callback,
- next: null
- });
- e: {
- var z = s,
- Y = C;
- switch (((V = o), (U = i), Y.tag)) {
- case 1:
- if ('function' == typeof (z = Y.payload)) {
- $ = z.call(U, $, V);
- break e;
- }
- $ = z;
- break e;
- case 3:
- z.flags = (-65537 & z.flags) | 128;
- case 0:
- if (
- null == (V = 'function' == typeof (z = Y.payload) ? z.call(U, $, V) : z)
- )
- break e;
- $ = xe({}, $, V);
- break e;
- case 2:
- Gn = !0;
- }
- }
- null !== C.callback &&
- 0 !== C.lane &&
- ((s.flags |= 64), null === (V = _.effects) ? (_.effects = [C]) : V.push(C));
- } else
- (U = {
- eventTime: U,
- lane: V,
- tag: C.tag,
- payload: C.payload,
- callback: C.callback,
- next: null
- }),
- null === B ? ((L = B = U), (j = $)) : (B = B.next = U),
- (x |= V);
- if (null === (C = C.next)) {
- if (null === (C = _.shared.pending)) break;
- (C = (V = C).next),
- (V.next = null),
- (_.lastBaseUpdate = V),
- (_.shared.pending = null);
- }
- }
- if (
- (null === B && (j = $),
- (_.baseState = j),
- (_.firstBaseUpdate = L),
- (_.lastBaseUpdate = B),
- null !== (o = _.shared.interleaved))
- ) {
- _ = o;
- do {
- (x |= _.lane), (_ = _.next);
- } while (_ !== o);
- } else null === w && (_.shared.lanes = 0);
- (Ks |= x), (s.lanes = x), (s.memoizedState = $);
- }
- }
- function sh(s, o, i) {
- if (((s = o.effects), (o.effects = null), null !== s))
- for (o = 0; o < s.length; o++) {
- var u = s[o],
- _ = u.callback;
- if (null !== _) {
- if (((u.callback = null), (u = i), 'function' != typeof _))
- throw Error(p(191, _));
- _.call(u);
- }
- }
- }
- var Yn = {},
- Xn = Uf(Yn),
- Zn = Uf(Yn),
- Qn = Uf(Yn);
- function xh(s) {
- if (s === Yn) throw Error(p(174));
- return s;
- }
- function yh(s, o) {
- switch ((G(Qn, o), G(Zn, s), G(Xn, Yn), (s = o.nodeType))) {
- case 9:
- case 11:
- o = (o = o.documentElement) ? o.namespaceURI : lb(null, '');
- break;
- default:
- o = lb(
- (o = (s = 8 === s ? o.parentNode : o).namespaceURI || null),
- (s = s.tagName)
- );
- }
- E(Xn), G(Xn, o);
- }
- function zh() {
- E(Xn), E(Zn), E(Qn);
- }
- function Ah(s) {
- xh(Qn.current);
- var o = xh(Xn.current),
- i = lb(o, s.type);
- o !== i && (G(Zn, s), G(Xn, i));
- }
- function Bh(s) {
- Zn.current === s && (E(Xn), E(Zn));
- }
- var es = Uf(0);
- function Ch(s) {
- for (var o = s; null !== o; ) {
- if (13 === o.tag) {
- var i = o.memoizedState;
- if (
- null !== i &&
- (null === (i = i.dehydrated) || '$?' === i.data || '$!' === i.data)
- )
- return o;
- } else if (19 === o.tag && void 0 !== o.memoizedProps.revealOrder) {
- if (128 & o.flags) return o;
- } else if (null !== o.child) {
- (o.child.return = o), (o = o.child);
- continue;
- }
- if (o === s) break;
- for (; null === o.sibling; ) {
- if (null === o.return || o.return === s) return null;
- o = o.return;
- }
- (o.sibling.return = o.return), (o = o.sibling);
- }
- return null;
- }
- var ts = [];
- function Eh() {
- for (var s = 0; s < ts.length; s++) ts[s]._workInProgressVersionPrimary = null;
- ts.length = 0;
- }
- var rs = z.ReactCurrentDispatcher,
- ns = z.ReactCurrentBatchConfig,
- ss = 0,
- os = null,
- as = null,
- ls = null,
- cs = !1,
- us = !1,
- ps = 0,
- hs = 0;
- function P() {
- throw Error(p(321));
- }
- function Mh(s, o) {
- if (null === o) return !1;
- for (var i = 0; i < o.length && i < s.length; i++) if (!Lr(s[i], o[i])) return !1;
- return !0;
- }
- function Nh(s, o, i, u, _, w) {
- if (
- ((ss = w),
- (os = o),
- (o.memoizedState = null),
- (o.updateQueue = null),
- (o.lanes = 0),
- (rs.current = null === s || null === s.memoizedState ? fs : ms),
- (s = i(u, _)),
- us)
- ) {
- w = 0;
- do {
- if (((us = !1), (ps = 0), 25 <= w)) throw Error(p(301));
- (w += 1),
- (ls = as = null),
- (o.updateQueue = null),
- (rs.current = gs),
- (s = i(u, _));
- } while (us);
- }
- if (
- ((rs.current = ds),
- (o = null !== as && null !== as.next),
- (ss = 0),
- (ls = as = os = null),
- (cs = !1),
- o)
- )
- throw Error(p(300));
- return s;
- }
- function Sh() {
- var s = 0 !== ps;
- return (ps = 0), s;
- }
- function Th() {
- var s = {
- memoizedState: null,
- baseState: null,
- baseQueue: null,
- queue: null,
- next: null
- };
- return null === ls ? (os.memoizedState = ls = s) : (ls = ls.next = s), ls;
- }
- function Uh() {
- if (null === as) {
- var s = os.alternate;
- s = null !== s ? s.memoizedState : null;
- } else s = as.next;
- var o = null === ls ? os.memoizedState : ls.next;
- if (null !== o) (ls = o), (as = s);
- else {
- if (null === s) throw Error(p(310));
- (s = {
- memoizedState: (as = s).memoizedState,
- baseState: as.baseState,
- baseQueue: as.baseQueue,
- queue: as.queue,
- next: null
- }),
- null === ls ? (os.memoizedState = ls = s) : (ls = ls.next = s);
- }
- return ls;
- }
- function Vh(s, o) {
- return 'function' == typeof o ? o(s) : o;
- }
- function Wh(s) {
- var o = Uh(),
- i = o.queue;
- if (null === i) throw Error(p(311));
- i.lastRenderedReducer = s;
- var u = as,
- _ = u.baseQueue,
- w = i.pending;
- if (null !== w) {
- if (null !== _) {
- var x = _.next;
- (_.next = w.next), (w.next = x);
- }
- (u.baseQueue = _ = w), (i.pending = null);
- }
- if (null !== _) {
- (w = _.next), (u = u.baseState);
- var C = (x = null),
- j = null,
- L = w;
- do {
- var B = L.lane;
- if ((ss & B) === B)
- null !== j &&
- (j = j.next =
- {
- lane: 0,
- action: L.action,
- hasEagerState: L.hasEagerState,
- eagerState: L.eagerState,
- next: null
- }),
- (u = L.hasEagerState ? L.eagerState : s(u, L.action));
- else {
- var $ = {
- lane: B,
- action: L.action,
- hasEagerState: L.hasEagerState,
- eagerState: L.eagerState,
- next: null
- };
- null === j ? ((C = j = $), (x = u)) : (j = j.next = $),
- (os.lanes |= B),
- (Ks |= B);
- }
- L = L.next;
- } while (null !== L && L !== w);
- null === j ? (x = u) : (j.next = C),
- Lr(u, o.memoizedState) || (_s = !0),
- (o.memoizedState = u),
- (o.baseState = x),
- (o.baseQueue = j),
- (i.lastRenderedState = u);
- }
- if (null !== (s = i.interleaved)) {
- _ = s;
- do {
- (w = _.lane), (os.lanes |= w), (Ks |= w), (_ = _.next);
- } while (_ !== s);
- } else null === _ && (i.lanes = 0);
- return [o.memoizedState, i.dispatch];
- }
- function Xh(s) {
- var o = Uh(),
- i = o.queue;
- if (null === i) throw Error(p(311));
- i.lastRenderedReducer = s;
- var u = i.dispatch,
- _ = i.pending,
- w = o.memoizedState;
- if (null !== _) {
- i.pending = null;
- var x = (_ = _.next);
- do {
- (w = s(w, x.action)), (x = x.next);
- } while (x !== _);
- Lr(w, o.memoizedState) || (_s = !0),
- (o.memoizedState = w),
- null === o.baseQueue && (o.baseState = w),
- (i.lastRenderedState = w);
- }
- return [w, u];
- }
- function Yh() {}
- function Zh(s, o) {
- var i = os,
- u = Uh(),
- _ = o(),
- w = !Lr(u.memoizedState, _);
- if (
- (w && ((u.memoizedState = _), (_s = !0)),
- (u = u.queue),
- $h(ai.bind(null, i, u, s), [s]),
- u.getSnapshot !== o || w || (null !== ls && 1 & ls.memoizedState.tag))
- ) {
- if (((i.flags |= 2048), bi(9, ci.bind(null, i, u, _, o), void 0, null), null === Fs))
- throw Error(p(349));
- 30 & ss || di(i, o, _);
- }
- return _;
- }
- function di(s, o, i) {
- (s.flags |= 16384),
- (s = { getSnapshot: o, value: i }),
- null === (o = os.updateQueue)
- ? ((o = { lastEffect: null, stores: null }), (os.updateQueue = o), (o.stores = [s]))
- : null === (i = o.stores)
- ? (o.stores = [s])
- : i.push(s);
- }
- function ci(s, o, i, u) {
- (o.value = i), (o.getSnapshot = u), ei(o) && fi(s);
- }
- function ai(s, o, i) {
- return i(function () {
- ei(o) && fi(s);
- });
- }
- function ei(s) {
- var o = s.getSnapshot;
- s = s.value;
- try {
- var i = o();
- return !Lr(s, i);
- } catch (s) {
- return !0;
- }
- }
- function fi(s) {
- var o = ih(s, 1);
- null !== o && gi(o, s, 1, -1);
- }
- function hi(s) {
- var o = Th();
- return (
- 'function' == typeof s && (s = s()),
- (o.memoizedState = o.baseState = s),
- (s = {
- pending: null,
- interleaved: null,
- lanes: 0,
- dispatch: null,
- lastRenderedReducer: Vh,
- lastRenderedState: s
- }),
- (o.queue = s),
- (s = s.dispatch = ii.bind(null, os, s)),
- [o.memoizedState, s]
- );
- }
- function bi(s, o, i, u) {
- return (
- (s = { tag: s, create: o, destroy: i, deps: u, next: null }),
- null === (o = os.updateQueue)
- ? ((o = { lastEffect: null, stores: null }),
- (os.updateQueue = o),
- (o.lastEffect = s.next = s))
- : null === (i = o.lastEffect)
- ? (o.lastEffect = s.next = s)
- : ((u = i.next), (i.next = s), (s.next = u), (o.lastEffect = s)),
- s
- );
- }
- function ji() {
- return Uh().memoizedState;
- }
- function ki(s, o, i, u) {
- var _ = Th();
- (os.flags |= s), (_.memoizedState = bi(1 | o, i, void 0, void 0 === u ? null : u));
- }
- function li(s, o, i, u) {
- var _ = Uh();
- u = void 0 === u ? null : u;
- var w = void 0;
- if (null !== as) {
- var x = as.memoizedState;
- if (((w = x.destroy), null !== u && Mh(u, x.deps)))
- return void (_.memoizedState = bi(o, i, w, u));
- }
- (os.flags |= s), (_.memoizedState = bi(1 | o, i, w, u));
- }
- function mi(s, o) {
- return ki(8390656, 8, s, o);
- }
- function $h(s, o) {
- return li(2048, 8, s, o);
- }
- function ni(s, o) {
- return li(4, 2, s, o);
- }
- function oi(s, o) {
- return li(4, 4, s, o);
- }
- function pi(s, o) {
- return 'function' == typeof o
- ? ((s = s()),
- o(s),
- function () {
- o(null);
- })
- : null != o
- ? ((s = s()),
- (o.current = s),
- function () {
- o.current = null;
- })
- : void 0;
- }
- function qi(s, o, i) {
- return (i = null != i ? i.concat([s]) : null), li(4, 4, pi.bind(null, o, s), i);
- }
- function ri() {}
- function si(s, o) {
- var i = Uh();
- o = void 0 === o ? null : o;
- var u = i.memoizedState;
- return null !== u && null !== o && Mh(o, u[1]) ? u[0] : ((i.memoizedState = [s, o]), s);
- }
- function ti(s, o) {
- var i = Uh();
- o = void 0 === o ? null : o;
- var u = i.memoizedState;
- return null !== u && null !== o && Mh(o, u[1])
- ? u[0]
- : ((s = s()), (i.memoizedState = [s, o]), s);
- }
- function ui(s, o, i) {
- return 21 & ss
- ? (Lr(i, o) || ((i = yc()), (os.lanes |= i), (Ks |= i), (s.baseState = !0)), o)
- : (s.baseState && ((s.baseState = !1), (_s = !0)), (s.memoizedState = i));
- }
- function vi(s, o) {
- var i = At;
- (At = 0 !== i && 4 > i ? i : 4), s(!0);
- var u = ns.transition;
- ns.transition = {};
- try {
- s(!1), o();
- } finally {
- (At = i), (ns.transition = u);
- }
- }
- function wi() {
- return Uh().memoizedState;
- }
- function xi(s, o, i) {
- var u = yi(s);
- if (
- ((i = { lane: u, action: i, hasEagerState: !1, eagerState: null, next: null }), zi(s))
- )
- Ai(o, i);
- else if (null !== (i = hh(s, o, i, u))) {
- gi(i, s, u, R()), Bi(i, o, u);
- }
- }
- function ii(s, o, i) {
- var u = yi(s),
- _ = { lane: u, action: i, hasEagerState: !1, eagerState: null, next: null };
- if (zi(s)) Ai(o, _);
- else {
- var w = s.alternate;
- if (
- 0 === s.lanes &&
- (null === w || 0 === w.lanes) &&
- null !== (w = o.lastRenderedReducer)
- )
- try {
- var x = o.lastRenderedState,
- C = w(x, i);
- if (((_.hasEagerState = !0), (_.eagerState = C), Lr(C, x))) {
- var j = o.interleaved;
- return (
- null === j ? ((_.next = _), gh(o)) : ((_.next = j.next), (j.next = _)),
- void (o.interleaved = _)
- );
- }
- } catch (s) {}
- null !== (i = hh(s, o, _, u)) && (gi(i, s, u, (_ = R())), Bi(i, o, u));
- }
- }
- function zi(s) {
- var o = s.alternate;
- return s === os || (null !== o && o === os);
- }
- function Ai(s, o) {
- us = cs = !0;
- var i = s.pending;
- null === i ? (o.next = o) : ((o.next = i.next), (i.next = o)), (s.pending = o);
- }
- function Bi(s, o, i) {
- if (4194240 & i) {
- var u = o.lanes;
- (i |= u &= s.pendingLanes), (o.lanes = i), Cc(s, i);
- }
- }
- var ds = {
- readContext: eh,
- useCallback: P,
- useContext: P,
- useEffect: P,
- useImperativeHandle: P,
- useInsertionEffect: P,
- useLayoutEffect: P,
- useMemo: P,
- useReducer: P,
- useRef: P,
- useState: P,
- useDebugValue: P,
- useDeferredValue: P,
- useTransition: P,
- useMutableSource: P,
- useSyncExternalStore: P,
- useId: P,
- unstable_isNewReconciler: !1
- },
- fs = {
- readContext: eh,
- useCallback: function (s, o) {
- return (Th().memoizedState = [s, void 0 === o ? null : o]), s;
- },
- useContext: eh,
- useEffect: mi,
- useImperativeHandle: function (s, o, i) {
- return (
- (i = null != i ? i.concat([s]) : null), ki(4194308, 4, pi.bind(null, o, s), i)
- );
- },
- useLayoutEffect: function (s, o) {
- return ki(4194308, 4, s, o);
- },
- useInsertionEffect: function (s, o) {
- return ki(4, 2, s, o);
- },
- useMemo: function (s, o) {
- var i = Th();
- return (o = void 0 === o ? null : o), (s = s()), (i.memoizedState = [s, o]), s;
- },
- useReducer: function (s, o, i) {
- var u = Th();
- return (
- (o = void 0 !== i ? i(o) : o),
- (u.memoizedState = u.baseState = o),
- (s = {
- pending: null,
- interleaved: null,
- lanes: 0,
- dispatch: null,
- lastRenderedReducer: s,
- lastRenderedState: o
- }),
- (u.queue = s),
- (s = s.dispatch = xi.bind(null, os, s)),
- [u.memoizedState, s]
- );
- },
- useRef: function (s) {
- return (s = { current: s }), (Th().memoizedState = s);
- },
- useState: hi,
- useDebugValue: ri,
- useDeferredValue: function (s) {
- return (Th().memoizedState = s);
- },
- useTransition: function () {
- var s = hi(!1),
- o = s[0];
- return (s = vi.bind(null, s[1])), (Th().memoizedState = s), [o, s];
- },
- useMutableSource: function () {},
- useSyncExternalStore: function (s, o, i) {
- var u = os,
- _ = Th();
- if (Fn) {
- if (void 0 === i) throw Error(p(407));
- i = i();
- } else {
- if (((i = o()), null === Fs)) throw Error(p(349));
- 30 & ss || di(u, o, i);
- }
- _.memoizedState = i;
- var w = { value: i, getSnapshot: o };
- return (
- (_.queue = w),
- mi(ai.bind(null, u, w, s), [s]),
- (u.flags |= 2048),
- bi(9, ci.bind(null, u, w, i, o), void 0, null),
- i
- );
- },
- useId: function () {
- var s = Th(),
- o = Fs.identifierPrefix;
- if (Fn) {
- var i = Dn;
- (o = ':' + o + 'R' + (i = (Rn & ~(1 << (32 - St(Rn) - 1))).toString(32) + i)),
- 0 < (i = ps++) && (o += 'H' + i.toString(32)),
- (o += ':');
- } else o = ':' + o + 'r' + (i = hs++).toString(32) + ':';
- return (s.memoizedState = o);
- },
- unstable_isNewReconciler: !1
- },
- ms = {
- readContext: eh,
- useCallback: si,
- useContext: eh,
- useEffect: $h,
- useImperativeHandle: qi,
- useInsertionEffect: ni,
- useLayoutEffect: oi,
- useMemo: ti,
- useReducer: Wh,
- useRef: ji,
- useState: function () {
- return Wh(Vh);
- },
- useDebugValue: ri,
- useDeferredValue: function (s) {
- return ui(Uh(), as.memoizedState, s);
- },
- useTransition: function () {
- return [Wh(Vh)[0], Uh().memoizedState];
- },
- useMutableSource: Yh,
- useSyncExternalStore: Zh,
- useId: wi,
- unstable_isNewReconciler: !1
- },
- gs = {
- readContext: eh,
- useCallback: si,
- useContext: eh,
- useEffect: $h,
- useImperativeHandle: qi,
- useInsertionEffect: ni,
- useLayoutEffect: oi,
- useMemo: ti,
- useReducer: Xh,
- useRef: ji,
- useState: function () {
- return Xh(Vh);
- },
- useDebugValue: ri,
- useDeferredValue: function (s) {
- var o = Uh();
- return null === as ? (o.memoizedState = s) : ui(o, as.memoizedState, s);
- },
- useTransition: function () {
- return [Xh(Vh)[0], Uh().memoizedState];
- },
- useMutableSource: Yh,
- useSyncExternalStore: Zh,
- useId: wi,
- unstable_isNewReconciler: !1
- };
- function Ci(s, o) {
- if (s && s.defaultProps) {
- for (var i in ((o = xe({}, o)), (s = s.defaultProps)))
- void 0 === o[i] && (o[i] = s[i]);
- return o;
- }
- return o;
- }
- function Di(s, o, i, u) {
- (i = null == (i = i(u, (o = s.memoizedState))) ? o : xe({}, o, i)),
- (s.memoizedState = i),
- 0 === s.lanes && (s.updateQueue.baseState = i);
- }
- var ys = {
- isMounted: function (s) {
- return !!(s = s._reactInternals) && Vb(s) === s;
- },
- enqueueSetState: function (s, o, i) {
- s = s._reactInternals;
- var u = R(),
- _ = yi(s),
- w = mh(u, _);
- (w.payload = o),
- null != i && (w.callback = i),
- null !== (o = nh(s, w, _)) && (gi(o, s, _, u), oh(o, s, _));
- },
- enqueueReplaceState: function (s, o, i) {
- s = s._reactInternals;
- var u = R(),
- _ = yi(s),
- w = mh(u, _);
- (w.tag = 1),
- (w.payload = o),
- null != i && (w.callback = i),
- null !== (o = nh(s, w, _)) && (gi(o, s, _, u), oh(o, s, _));
- },
- enqueueForceUpdate: function (s, o) {
- s = s._reactInternals;
- var i = R(),
- u = yi(s),
- _ = mh(i, u);
- (_.tag = 2),
- null != o && (_.callback = o),
- null !== (o = nh(s, _, u)) && (gi(o, s, u, i), oh(o, s, u));
- }
- };
- function Fi(s, o, i, u, _, w, x) {
- return 'function' == typeof (s = s.stateNode).shouldComponentUpdate
- ? s.shouldComponentUpdate(u, w, x)
- : !o.prototype || !o.prototype.isPureReactComponent || !Ie(i, u) || !Ie(_, w);
- }
- function Gi(s, o, i) {
- var u = !1,
- _ = En,
- w = o.contextType;
- return (
- 'object' == typeof w && null !== w
- ? (w = eh(w))
- : ((_ = Zf(o) ? xn : wn.current),
- (w = (u = null != (u = o.contextTypes)) ? Yf(s, _) : En)),
- (o = new o(i, w)),
- (s.memoizedState = null !== o.state && void 0 !== o.state ? o.state : null),
- (o.updater = ys),
- (s.stateNode = o),
- (o._reactInternals = s),
- u &&
- (((s = s.stateNode).__reactInternalMemoizedUnmaskedChildContext = _),
- (s.__reactInternalMemoizedMaskedChildContext = w)),
- o
- );
- }
- function Hi(s, o, i, u) {
- (s = o.state),
- 'function' == typeof o.componentWillReceiveProps && o.componentWillReceiveProps(i, u),
- 'function' == typeof o.UNSAFE_componentWillReceiveProps &&
- o.UNSAFE_componentWillReceiveProps(i, u),
- o.state !== s && ys.enqueueReplaceState(o, o.state, null);
- }
- function Ii(s, o, i, u) {
- var _ = s.stateNode;
- (_.props = i), (_.state = s.memoizedState), (_.refs = {}), kh(s);
- var w = o.contextType;
- 'object' == typeof w && null !== w
- ? (_.context = eh(w))
- : ((w = Zf(o) ? xn : wn.current), (_.context = Yf(s, w))),
- (_.state = s.memoizedState),
- 'function' == typeof (w = o.getDerivedStateFromProps) &&
- (Di(s, o, w, i), (_.state = s.memoizedState)),
- 'function' == typeof o.getDerivedStateFromProps ||
- 'function' == typeof _.getSnapshotBeforeUpdate ||
- ('function' != typeof _.UNSAFE_componentWillMount &&
- 'function' != typeof _.componentWillMount) ||
- ((o = _.state),
- 'function' == typeof _.componentWillMount && _.componentWillMount(),
- 'function' == typeof _.UNSAFE_componentWillMount && _.UNSAFE_componentWillMount(),
- o !== _.state && ys.enqueueReplaceState(_, _.state, null),
- qh(s, i, _, u),
- (_.state = s.memoizedState)),
- 'function' == typeof _.componentDidMount && (s.flags |= 4194308);
- }
- function Ji(s, o) {
- try {
- var i = '',
- u = o;
- do {
- (i += Pa(u)), (u = u.return);
- } while (u);
- var _ = i;
- } catch (s) {
- _ = '\nError generating stack: ' + s.message + '\n' + s.stack;
- }
- return { value: s, source: o, stack: _, digest: null };
- }
- function Ki(s, o, i) {
- return {
- value: s,
- source: null,
- stack: null != i ? i : null,
- digest: null != o ? o : null
- };
- }
- function Li(s, o) {
- try {
- console.error(o.value);
- } catch (s) {
- setTimeout(function () {
- throw s;
- });
- }
- }
- var vs = 'function' == typeof WeakMap ? WeakMap : Map;
- function Ni(s, o, i) {
- ((i = mh(-1, i)).tag = 3), (i.payload = { element: null });
- var u = o.value;
- return (
- (i.callback = function () {
- eo || ((eo = !0), (to = u)), Li(0, o);
- }),
- i
- );
- }
- function Qi(s, o, i) {
- (i = mh(-1, i)).tag = 3;
- var u = s.type.getDerivedStateFromError;
- if ('function' == typeof u) {
- var _ = o.value;
- (i.payload = function () {
- return u(_);
- }),
- (i.callback = function () {
- Li(0, o);
- });
- }
- var w = s.stateNode;
- return (
- null !== w &&
- 'function' == typeof w.componentDidCatch &&
- (i.callback = function () {
- Li(0, o),
- 'function' != typeof u && (null === ro ? (ro = new Set([this])) : ro.add(this));
- var s = o.stack;
- this.componentDidCatch(o.value, { componentStack: null !== s ? s : '' });
- }),
- i
- );
- }
- function Si(s, o, i) {
- var u = s.pingCache;
- if (null === u) {
- u = s.pingCache = new vs();
- var _ = new Set();
- u.set(o, _);
- } else void 0 === (_ = u.get(o)) && ((_ = new Set()), u.set(o, _));
- _.has(i) || (_.add(i), (s = Ti.bind(null, s, o, i)), o.then(s, s));
- }
- function Ui(s) {
- do {
- var o;
- if (
- ((o = 13 === s.tag) &&
- (o = null === (o = s.memoizedState) || null !== o.dehydrated),
- o)
- )
- return s;
- s = s.return;
- } while (null !== s);
- return null;
- }
- function Vi(s, o, i, u, _) {
- return 1 & s.mode
- ? ((s.flags |= 65536), (s.lanes = _), s)
- : (s === o
- ? (s.flags |= 65536)
- : ((s.flags |= 128),
- (i.flags |= 131072),
- (i.flags &= -52805),
- 1 === i.tag &&
- (null === i.alternate
- ? (i.tag = 17)
- : (((o = mh(-1, 1)).tag = 2), nh(i, o, 1))),
- (i.lanes |= 1)),
- s);
- }
- var bs = z.ReactCurrentOwner,
- _s = !1;
- function Xi(s, o, i, u) {
- o.child = null === s ? Un(o, null, i, u) : Vn(o, s.child, i, u);
- }
- function Yi(s, o, i, u, _) {
- i = i.render;
- var w = o.ref;
- return (
- ch(o, _),
- (u = Nh(s, o, i, u, w, _)),
- (i = Sh()),
- null === s || _s
- ? (Fn && i && vg(o), (o.flags |= 1), Xi(s, o, u, _), o.child)
- : ((o.updateQueue = s.updateQueue),
- (o.flags &= -2053),
- (s.lanes &= ~_),
- Zi(s, o, _))
- );
- }
- function $i(s, o, i, u, _) {
- if (null === s) {
- var w = i.type;
- return 'function' != typeof w ||
- aj(w) ||
- void 0 !== w.defaultProps ||
- null !== i.compare ||
- void 0 !== i.defaultProps
- ? (((s = Rg(i.type, null, u, o, o.mode, _)).ref = o.ref),
- (s.return = o),
- (o.child = s))
- : ((o.tag = 15), (o.type = w), bj(s, o, w, u, _));
- }
- if (((w = s.child), !(s.lanes & _))) {
- var x = w.memoizedProps;
- if ((i = null !== (i = i.compare) ? i : Ie)(x, u) && s.ref === o.ref)
- return Zi(s, o, _);
- }
- return (o.flags |= 1), ((s = Pg(w, u)).ref = o.ref), (s.return = o), (o.child = s);
- }
- function bj(s, o, i, u, _) {
- if (null !== s) {
- var w = s.memoizedProps;
- if (Ie(w, u) && s.ref === o.ref) {
- if (((_s = !1), (o.pendingProps = u = w), !(s.lanes & _)))
- return (o.lanes = s.lanes), Zi(s, o, _);
- 131072 & s.flags && (_s = !0);
- }
- }
- return cj(s, o, i, u, _);
- }
- function dj(s, o, i) {
- var u = o.pendingProps,
- _ = u.children,
- w = null !== s ? s.memoizedState : null;
- if ('hidden' === u.mode)
- if (1 & o.mode) {
- if (!(1073741824 & i))
- return (
- (s = null !== w ? w.baseLanes | i : i),
- (o.lanes = o.childLanes = 1073741824),
- (o.memoizedState = { baseLanes: s, cachePool: null, transitions: null }),
- (o.updateQueue = null),
- G(Us, Vs),
- (Vs |= s),
- null
- );
- (o.memoizedState = { baseLanes: 0, cachePool: null, transitions: null }),
- (u = null !== w ? w.baseLanes : i),
- G(Us, Vs),
- (Vs |= u);
- } else
- (o.memoizedState = { baseLanes: 0, cachePool: null, transitions: null }),
- G(Us, Vs),
- (Vs |= i);
- else
- null !== w ? ((u = w.baseLanes | i), (o.memoizedState = null)) : (u = i),
- G(Us, Vs),
- (Vs |= u);
- return Xi(s, o, _, i), o.child;
- }
- function gj(s, o) {
- var i = o.ref;
- ((null === s && null !== i) || (null !== s && s.ref !== i)) &&
- ((o.flags |= 512), (o.flags |= 2097152));
- }
- function cj(s, o, i, u, _) {
- var w = Zf(i) ? xn : wn.current;
- return (
- (w = Yf(o, w)),
- ch(o, _),
- (i = Nh(s, o, i, u, w, _)),
- (u = Sh()),
- null === s || _s
- ? (Fn && u && vg(o), (o.flags |= 1), Xi(s, o, i, _), o.child)
- : ((o.updateQueue = s.updateQueue),
- (o.flags &= -2053),
- (s.lanes &= ~_),
- Zi(s, o, _))
- );
- }
- function hj(s, o, i, u, _) {
- if (Zf(i)) {
- var w = !0;
- cg(o);
- } else w = !1;
- if ((ch(o, _), null === o.stateNode)) ij(s, o), Gi(o, i, u), Ii(o, i, u, _), (u = !0);
- else if (null === s) {
- var x = o.stateNode,
- C = o.memoizedProps;
- x.props = C;
- var j = x.context,
- L = i.contextType;
- 'object' == typeof L && null !== L
- ? (L = eh(L))
- : (L = Yf(o, (L = Zf(i) ? xn : wn.current)));
- var B = i.getDerivedStateFromProps,
- $ = 'function' == typeof B || 'function' == typeof x.getSnapshotBeforeUpdate;
- $ ||
- ('function' != typeof x.UNSAFE_componentWillReceiveProps &&
- 'function' != typeof x.componentWillReceiveProps) ||
- ((C !== u || j !== L) && Hi(o, x, u, L)),
- (Gn = !1);
- var V = o.memoizedState;
- (x.state = V),
- qh(o, u, x, _),
- (j = o.memoizedState),
- C !== u || V !== j || Sn.current || Gn
- ? ('function' == typeof B && (Di(o, i, B, u), (j = o.memoizedState)),
- (C = Gn || Fi(o, i, C, u, V, j, L))
- ? ($ ||
- ('function' != typeof x.UNSAFE_componentWillMount &&
- 'function' != typeof x.componentWillMount) ||
- ('function' == typeof x.componentWillMount && x.componentWillMount(),
- 'function' == typeof x.UNSAFE_componentWillMount &&
- x.UNSAFE_componentWillMount()),
- 'function' == typeof x.componentDidMount && (o.flags |= 4194308))
- : ('function' == typeof x.componentDidMount && (o.flags |= 4194308),
- (o.memoizedProps = u),
- (o.memoizedState = j)),
- (x.props = u),
- (x.state = j),
- (x.context = L),
- (u = C))
- : ('function' == typeof x.componentDidMount && (o.flags |= 4194308), (u = !1));
- } else {
- (x = o.stateNode),
- lh(s, o),
- (C = o.memoizedProps),
- (L = o.type === o.elementType ? C : Ci(o.type, C)),
- (x.props = L),
- ($ = o.pendingProps),
- (V = x.context),
- 'object' == typeof (j = i.contextType) && null !== j
- ? (j = eh(j))
- : (j = Yf(o, (j = Zf(i) ? xn : wn.current)));
- var U = i.getDerivedStateFromProps;
- (B = 'function' == typeof U || 'function' == typeof x.getSnapshotBeforeUpdate) ||
- ('function' != typeof x.UNSAFE_componentWillReceiveProps &&
- 'function' != typeof x.componentWillReceiveProps) ||
- ((C !== $ || V !== j) && Hi(o, x, u, j)),
- (Gn = !1),
- (V = o.memoizedState),
- (x.state = V),
- qh(o, u, x, _);
- var z = o.memoizedState;
- C !== $ || V !== z || Sn.current || Gn
- ? ('function' == typeof U && (Di(o, i, U, u), (z = o.memoizedState)),
- (L = Gn || Fi(o, i, L, u, V, z, j) || !1)
- ? (B ||
- ('function' != typeof x.UNSAFE_componentWillUpdate &&
- 'function' != typeof x.componentWillUpdate) ||
- ('function' == typeof x.componentWillUpdate &&
- x.componentWillUpdate(u, z, j),
- 'function' == typeof x.UNSAFE_componentWillUpdate &&
- x.UNSAFE_componentWillUpdate(u, z, j)),
- 'function' == typeof x.componentDidUpdate && (o.flags |= 4),
- 'function' == typeof x.getSnapshotBeforeUpdate && (o.flags |= 1024))
- : ('function' != typeof x.componentDidUpdate ||
- (C === s.memoizedProps && V === s.memoizedState) ||
- (o.flags |= 4),
- 'function' != typeof x.getSnapshotBeforeUpdate ||
- (C === s.memoizedProps && V === s.memoizedState) ||
- (o.flags |= 1024),
- (o.memoizedProps = u),
- (o.memoizedState = z)),
- (x.props = u),
- (x.state = z),
- (x.context = j),
- (u = L))
- : ('function' != typeof x.componentDidUpdate ||
- (C === s.memoizedProps && V === s.memoizedState) ||
- (o.flags |= 4),
- 'function' != typeof x.getSnapshotBeforeUpdate ||
- (C === s.memoizedProps && V === s.memoizedState) ||
- (o.flags |= 1024),
- (u = !1));
- }
- return jj(s, o, i, u, w, _);
- }
- function jj(s, o, i, u, _, w) {
- gj(s, o);
- var x = !!(128 & o.flags);
- if (!u && !x) return _ && dg(o, i, !1), Zi(s, o, w);
- (u = o.stateNode), (bs.current = o);
- var C = x && 'function' != typeof i.getDerivedStateFromError ? null : u.render();
- return (
- (o.flags |= 1),
- null !== s && x
- ? ((o.child = Vn(o, s.child, null, w)), (o.child = Vn(o, null, C, w)))
- : Xi(s, o, C, w),
- (o.memoizedState = u.state),
- _ && dg(o, i, !0),
- o.child
- );
- }
- function kj(s) {
- var o = s.stateNode;
- o.pendingContext
- ? ag(0, o.pendingContext, o.pendingContext !== o.context)
- : o.context && ag(0, o.context, !1),
- yh(s, o.containerInfo);
- }
- function lj(s, o, i, u, _) {
- return Ig(), Jg(_), (o.flags |= 256), Xi(s, o, i, u), o.child;
- }
- var Es,
- ws,
- Ss,
- xs,
- ks = { dehydrated: null, treeContext: null, retryLane: 0 };
- function nj(s) {
- return { baseLanes: s, cachePool: null, transitions: null };
- }
- function oj(s, o, i) {
- var u,
- _ = o.pendingProps,
- w = es.current,
- x = !1,
- C = !!(128 & o.flags);
- if (
- ((u = C) || (u = (null === s || null !== s.memoizedState) && !!(2 & w)),
- u
- ? ((x = !0), (o.flags &= -129))
- : (null !== s && null === s.memoizedState) || (w |= 1),
- G(es, 1 & w),
- null === s)
- )
- return (
- Eg(o),
- null !== (s = o.memoizedState) && null !== (s = s.dehydrated)
- ? (1 & o.mode
- ? '$!' === s.data
- ? (o.lanes = 8)
- : (o.lanes = 1073741824)
- : (o.lanes = 1),
- null)
- : ((C = _.children),
- (s = _.fallback),
- x
- ? ((_ = o.mode),
- (x = o.child),
- (C = { mode: 'hidden', children: C }),
- 1 & _ || null === x
- ? (x = pj(C, _, 0, null))
- : ((x.childLanes = 0), (x.pendingProps = C)),
- (s = Tg(s, _, i, null)),
- (x.return = o),
- (s.return = o),
- (x.sibling = s),
- (o.child = x),
- (o.child.memoizedState = nj(i)),
- (o.memoizedState = ks),
- s)
- : qj(o, C))
- );
- if (null !== (w = s.memoizedState) && null !== (u = w.dehydrated))
- return (function rj(s, o, i, u, _, w, x) {
- if (i)
- return 256 & o.flags
- ? ((o.flags &= -257), sj(s, o, x, (u = Ki(Error(p(422))))))
- : null !== o.memoizedState
- ? ((o.child = s.child), (o.flags |= 128), null)
- : ((w = u.fallback),
- (_ = o.mode),
- (u = pj({ mode: 'visible', children: u.children }, _, 0, null)),
- ((w = Tg(w, _, x, null)).flags |= 2),
- (u.return = o),
- (w.return = o),
- (u.sibling = w),
- (o.child = u),
- 1 & o.mode && Vn(o, s.child, null, x),
- (o.child.memoizedState = nj(x)),
- (o.memoizedState = ks),
- w);
- if (!(1 & o.mode)) return sj(s, o, x, null);
- if ('$!' === _.data) {
- if ((u = _.nextSibling && _.nextSibling.dataset)) var C = u.dgst;
- return (u = C), sj(s, o, x, (u = Ki((w = Error(p(419))), u, void 0)));
- }
- if (((C = !!(x & s.childLanes)), _s || C)) {
- if (null !== (u = Fs)) {
- switch (x & -x) {
- case 4:
- _ = 2;
- break;
- case 16:
- _ = 8;
- break;
- case 64:
- case 128:
- case 256:
- case 512:
- case 1024:
- case 2048:
- case 4096:
- case 8192:
- case 16384:
- case 32768:
- case 65536:
- case 131072:
- case 262144:
- case 524288:
- case 1048576:
- case 2097152:
- case 4194304:
- case 8388608:
- case 16777216:
- case 33554432:
- case 67108864:
- _ = 32;
- break;
- case 536870912:
- _ = 268435456;
- break;
- default:
- _ = 0;
- }
- 0 !== (_ = _ & (u.suspendedLanes | x) ? 0 : _) &&
- _ !== w.retryLane &&
- ((w.retryLane = _), ih(s, _), gi(u, s, _, -1));
- }
- return tj(), sj(s, o, x, (u = Ki(Error(p(421)))));
- }
- return '$?' === _.data
- ? ((o.flags |= 128),
- (o.child = s.child),
- (o = uj.bind(null, s)),
- (_._reactRetry = o),
- null)
- : ((s = w.treeContext),
- (Bn = Lf(_.nextSibling)),
- (Ln = o),
- (Fn = !0),
- (qn = null),
- null !== s &&
- ((Mn[Tn++] = Rn),
- (Mn[Tn++] = Dn),
- (Mn[Tn++] = Nn),
- (Rn = s.id),
- (Dn = s.overflow),
- (Nn = o)),
- (o = qj(o, u.children)),
- (o.flags |= 4096),
- o);
- })(s, o, C, _, u, w, i);
- if (x) {
- (x = _.fallback), (C = o.mode), (u = (w = s.child).sibling);
- var j = { mode: 'hidden', children: _.children };
- return (
- 1 & C || o.child === w
- ? ((_ = Pg(w, j)).subtreeFlags = 14680064 & w.subtreeFlags)
- : (((_ = o.child).childLanes = 0), (_.pendingProps = j), (o.deletions = null)),
- null !== u ? (x = Pg(u, x)) : ((x = Tg(x, C, i, null)).flags |= 2),
- (x.return = o),
- (_.return = o),
- (_.sibling = x),
- (o.child = _),
- (_ = x),
- (x = o.child),
- (C =
- null === (C = s.child.memoizedState)
- ? nj(i)
- : { baseLanes: C.baseLanes | i, cachePool: null, transitions: C.transitions }),
- (x.memoizedState = C),
- (x.childLanes = s.childLanes & ~i),
- (o.memoizedState = ks),
- _
- );
- }
- return (
- (s = (x = s.child).sibling),
- (_ = Pg(x, { mode: 'visible', children: _.children })),
- !(1 & o.mode) && (_.lanes = i),
- (_.return = o),
- (_.sibling = null),
- null !== s &&
- (null === (i = o.deletions) ? ((o.deletions = [s]), (o.flags |= 16)) : i.push(s)),
- (o.child = _),
- (o.memoizedState = null),
- _
- );
- }
- function qj(s, o) {
- return (
- ((o = pj({ mode: 'visible', children: o }, s.mode, 0, null)).return = s),
- (s.child = o)
- );
- }
- function sj(s, o, i, u) {
- return (
- null !== u && Jg(u),
- Vn(o, s.child, null, i),
- ((s = qj(o, o.pendingProps.children)).flags |= 2),
- (o.memoizedState = null),
- s
- );
- }
- function vj(s, o, i) {
- s.lanes |= o;
- var u = s.alternate;
- null !== u && (u.lanes |= o), bh(s.return, o, i);
- }
- function wj(s, o, i, u, _) {
- var w = s.memoizedState;
- null === w
- ? (s.memoizedState = {
- isBackwards: o,
- rendering: null,
- renderingStartTime: 0,
- last: u,
- tail: i,
- tailMode: _
- })
- : ((w.isBackwards = o),
- (w.rendering = null),
- (w.renderingStartTime = 0),
- (w.last = u),
- (w.tail = i),
- (w.tailMode = _));
- }
- function xj(s, o, i) {
- var u = o.pendingProps,
- _ = u.revealOrder,
- w = u.tail;
- if ((Xi(s, o, u.children, i), 2 & (u = es.current)))
- (u = (1 & u) | 2), (o.flags |= 128);
- else {
- if (null !== s && 128 & s.flags)
- e: for (s = o.child; null !== s; ) {
- if (13 === s.tag) null !== s.memoizedState && vj(s, i, o);
- else if (19 === s.tag) vj(s, i, o);
- else if (null !== s.child) {
- (s.child.return = s), (s = s.child);
- continue;
- }
- if (s === o) break e;
- for (; null === s.sibling; ) {
- if (null === s.return || s.return === o) break e;
- s = s.return;
- }
- (s.sibling.return = s.return), (s = s.sibling);
- }
- u &= 1;
- }
- if ((G(es, u), 1 & o.mode))
- switch (_) {
- case 'forwards':
- for (i = o.child, _ = null; null !== i; )
- null !== (s = i.alternate) && null === Ch(s) && (_ = i), (i = i.sibling);
- null === (i = _)
- ? ((_ = o.child), (o.child = null))
- : ((_ = i.sibling), (i.sibling = null)),
- wj(o, !1, _, i, w);
- break;
- case 'backwards':
- for (i = null, _ = o.child, o.child = null; null !== _; ) {
- if (null !== (s = _.alternate) && null === Ch(s)) {
- o.child = _;
- break;
- }
- (s = _.sibling), (_.sibling = i), (i = _), (_ = s);
- }
- wj(o, !0, i, null, w);
- break;
- case 'together':
- wj(o, !1, null, null, void 0);
- break;
- default:
- o.memoizedState = null;
- }
- else o.memoizedState = null;
- return o.child;
- }
- function ij(s, o) {
- !(1 & o.mode) &&
- null !== s &&
- ((s.alternate = null), (o.alternate = null), (o.flags |= 2));
- }
- function Zi(s, o, i) {
- if (
- (null !== s && (o.dependencies = s.dependencies),
- (Ks |= o.lanes),
- !(i & o.childLanes))
- )
- return null;
- if (null !== s && o.child !== s.child) throw Error(p(153));
- if (null !== o.child) {
- for (
- i = Pg((s = o.child), s.pendingProps), o.child = i, i.return = o;
- null !== s.sibling;
- )
- (s = s.sibling), ((i = i.sibling = Pg(s, s.pendingProps)).return = o);
- i.sibling = null;
- }
- return o.child;
- }
- function Dj(s, o) {
- if (!Fn)
- switch (s.tailMode) {
- case 'hidden':
- o = s.tail;
- for (var i = null; null !== o; ) null !== o.alternate && (i = o), (o = o.sibling);
- null === i ? (s.tail = null) : (i.sibling = null);
- break;
- case 'collapsed':
- i = s.tail;
- for (var u = null; null !== i; ) null !== i.alternate && (u = i), (i = i.sibling);
- null === u
- ? o || null === s.tail
- ? (s.tail = null)
- : (s.tail.sibling = null)
- : (u.sibling = null);
- }
- }
- function S(s) {
- var o = null !== s.alternate && s.alternate.child === s.child,
- i = 0,
- u = 0;
- if (o)
- for (var _ = s.child; null !== _; )
- (i |= _.lanes | _.childLanes),
- (u |= 14680064 & _.subtreeFlags),
- (u |= 14680064 & _.flags),
- (_.return = s),
- (_ = _.sibling);
- else
- for (_ = s.child; null !== _; )
- (i |= _.lanes | _.childLanes),
- (u |= _.subtreeFlags),
- (u |= _.flags),
- (_.return = s),
- (_ = _.sibling);
- return (s.subtreeFlags |= u), (s.childLanes = i), o;
- }
- function Ej(s, o, i) {
- var u = o.pendingProps;
- switch ((wg(o), o.tag)) {
- case 2:
- case 16:
- case 15:
- case 0:
- case 11:
- case 7:
- case 8:
- case 12:
- case 9:
- case 14:
- return S(o), null;
- case 1:
- case 17:
- return Zf(o.type) && $f(), S(o), null;
- case 3:
- return (
- (u = o.stateNode),
- zh(),
- E(Sn),
- E(wn),
- Eh(),
- u.pendingContext && ((u.context = u.pendingContext), (u.pendingContext = null)),
- (null !== s && null !== s.child) ||
- (Gg(o)
- ? (o.flags |= 4)
- : null === s ||
- (s.memoizedState.isDehydrated && !(256 & o.flags)) ||
- ((o.flags |= 1024), null !== qn && (Fj(qn), (qn = null)))),
- ws(s, o),
- S(o),
- null
- );
- case 5:
- Bh(o);
- var _ = xh(Qn.current);
- if (((i = o.type), null !== s && null != o.stateNode))
- Ss(s, o, i, u, _), s.ref !== o.ref && ((o.flags |= 512), (o.flags |= 2097152));
- else {
- if (!u) {
- if (null === o.stateNode) throw Error(p(166));
- return S(o), null;
- }
- if (((s = xh(Xn.current)), Gg(o))) {
- (u = o.stateNode), (i = o.type);
- var w = o.memoizedProps;
- switch (((u[dn] = o), (u[fn] = w), (s = !!(1 & o.mode)), i)) {
- case 'dialog':
- D('cancel', u), D('close', u);
- break;
- case 'iframe':
- case 'object':
- case 'embed':
- D('load', u);
- break;
- case 'video':
- case 'audio':
- for (_ = 0; _ < en.length; _++) D(en[_], u);
- break;
- case 'source':
- D('error', u);
- break;
- case 'img':
- case 'image':
- case 'link':
- D('error', u), D('load', u);
- break;
- case 'details':
- D('toggle', u);
- break;
- case 'input':
- Za(u, w), D('invalid', u);
- break;
- case 'select':
- (u._wrapperState = { wasMultiple: !!w.multiple }), D('invalid', u);
- break;
- case 'textarea':
- hb(u, w), D('invalid', u);
- }
- for (var C in (ub(i, w), (_ = null), w))
- if (w.hasOwnProperty(C)) {
- var j = w[C];
- 'children' === C
- ? 'string' == typeof j
- ? u.textContent !== j &&
- (!0 !== w.suppressHydrationWarning && Af(u.textContent, j, s),
- (_ = ['children', j]))
- : 'number' == typeof j &&
- u.textContent !== '' + j &&
- (!0 !== w.suppressHydrationWarning && Af(u.textContent, j, s),
- (_ = ['children', '' + j]))
- : x.hasOwnProperty(C) && null != j && 'onScroll' === C && D('scroll', u);
- }
- switch (i) {
- case 'input':
- Va(u), db(u, w, !0);
- break;
- case 'textarea':
- Va(u), jb(u);
- break;
- case 'select':
- case 'option':
- break;
- default:
- 'function' == typeof w.onClick && (u.onclick = Bf);
- }
- (u = _), (o.updateQueue = u), null !== u && (o.flags |= 4);
- } else {
- (C = 9 === _.nodeType ? _ : _.ownerDocument),
- 'http://www.w3.org/1999/xhtml' === s && (s = kb(i)),
- 'http://www.w3.org/1999/xhtml' === s
- ? 'script' === i
- ? (((s = C.createElement('div')).innerHTML = '<script></script>'),
- (s = s.removeChild(s.firstChild)))
- : 'string' == typeof u.is
- ? (s = C.createElement(i, { is: u.is }))
- : ((s = C.createElement(i)),
- 'select' === i &&
- ((C = s),
- u.multiple ? (C.multiple = !0) : u.size && (C.size = u.size)))
- : (s = C.createElementNS(s, i)),
- (s[dn] = o),
- (s[fn] = u),
- Es(s, o, !1, !1),
- (o.stateNode = s);
- e: {
- switch (((C = vb(i, u)), i)) {
- case 'dialog':
- D('cancel', s), D('close', s), (_ = u);
- break;
- case 'iframe':
- case 'object':
- case 'embed':
- D('load', s), (_ = u);
- break;
- case 'video':
- case 'audio':
- for (_ = 0; _ < en.length; _++) D(en[_], s);
- _ = u;
- break;
- case 'source':
- D('error', s), (_ = u);
- break;
- case 'img':
- case 'image':
- case 'link':
- D('error', s), D('load', s), (_ = u);
- break;
- case 'details':
- D('toggle', s), (_ = u);
- break;
- case 'input':
- Za(s, u), (_ = Ya(s, u)), D('invalid', s);
- break;
- case 'option':
- default:
- _ = u;
- break;
- case 'select':
- (s._wrapperState = { wasMultiple: !!u.multiple }),
- (_ = xe({}, u, { value: void 0 })),
- D('invalid', s);
- break;
- case 'textarea':
- hb(s, u), (_ = gb(s, u)), D('invalid', s);
- }
- for (w in (ub(i, _), (j = _)))
- if (j.hasOwnProperty(w)) {
- var L = j[w];
- 'style' === w
- ? sb(s, L)
- : 'dangerouslySetInnerHTML' === w
- ? null != (L = L ? L.__html : void 0) && $e(s, L)
- : 'children' === w
- ? 'string' == typeof L
- ? ('textarea' !== i || '' !== L) && ob(s, L)
- : 'number' == typeof L && ob(s, '' + L)
- : 'suppressContentEditableWarning' !== w &&
- 'suppressHydrationWarning' !== w &&
- 'autoFocus' !== w &&
- (x.hasOwnProperty(w)
- ? null != L && 'onScroll' === w && D('scroll', s)
- : null != L && ta(s, w, L, C));
- }
- switch (i) {
- case 'input':
- Va(s), db(s, u, !1);
- break;
- case 'textarea':
- Va(s), jb(s);
- break;
- case 'option':
- null != u.value && s.setAttribute('value', '' + Sa(u.value));
- break;
- case 'select':
- (s.multiple = !!u.multiple),
- null != (w = u.value)
- ? fb(s, !!u.multiple, w, !1)
- : null != u.defaultValue && fb(s, !!u.multiple, u.defaultValue, !0);
- break;
- default:
- 'function' == typeof _.onClick && (s.onclick = Bf);
- }
- switch (i) {
- case 'button':
- case 'input':
- case 'select':
- case 'textarea':
- u = !!u.autoFocus;
- break e;
- case 'img':
- u = !0;
- break e;
- default:
- u = !1;
- }
- }
- u && (o.flags |= 4);
- }
- null !== o.ref && ((o.flags |= 512), (o.flags |= 2097152));
- }
- return S(o), null;
- case 6:
- if (s && null != o.stateNode) xs(s, o, s.memoizedProps, u);
- else {
- if ('string' != typeof u && null === o.stateNode) throw Error(p(166));
- if (((i = xh(Qn.current)), xh(Xn.current), Gg(o))) {
- if (
- ((u = o.stateNode),
- (i = o.memoizedProps),
- (u[dn] = o),
- (w = u.nodeValue !== i) && null !== (s = Ln))
- )
- switch (s.tag) {
- case 3:
- Af(u.nodeValue, i, !!(1 & s.mode));
- break;
- case 5:
- !0 !== s.memoizedProps.suppressHydrationWarning &&
- Af(u.nodeValue, i, !!(1 & s.mode));
- }
- w && (o.flags |= 4);
- } else
- ((u = (9 === i.nodeType ? i : i.ownerDocument).createTextNode(u))[dn] = o),
- (o.stateNode = u);
- }
- return S(o), null;
- case 13:
- if (
- (E(es),
- (u = o.memoizedState),
- null === s || (null !== s.memoizedState && null !== s.memoizedState.dehydrated))
- ) {
- if (Fn && null !== Bn && 1 & o.mode && !(128 & o.flags))
- Hg(), Ig(), (o.flags |= 98560), (w = !1);
- else if (((w = Gg(o)), null !== u && null !== u.dehydrated)) {
- if (null === s) {
- if (!w) throw Error(p(318));
- if (!(w = null !== (w = o.memoizedState) ? w.dehydrated : null))
- throw Error(p(317));
- w[dn] = o;
- } else Ig(), !(128 & o.flags) && (o.memoizedState = null), (o.flags |= 4);
- S(o), (w = !1);
- } else null !== qn && (Fj(qn), (qn = null)), (w = !0);
- if (!w) return 65536 & o.flags ? o : null;
- }
- return 128 & o.flags
- ? ((o.lanes = i), o)
- : ((u = null !== u) !== (null !== s && null !== s.memoizedState) &&
- u &&
- ((o.child.flags |= 8192),
- 1 & o.mode && (null === s || 1 & es.current ? 0 === zs && (zs = 3) : tj())),
- null !== o.updateQueue && (o.flags |= 4),
- S(o),
- null);
- case 4:
- return zh(), ws(s, o), null === s && sf(o.stateNode.containerInfo), S(o), null;
- case 10:
- return ah(o.type._context), S(o), null;
- case 19:
- if ((E(es), null === (w = o.memoizedState))) return S(o), null;
- if (((u = !!(128 & o.flags)), null === (C = w.rendering)))
- if (u) Dj(w, !1);
- else {
- if (0 !== zs || (null !== s && 128 & s.flags))
- for (s = o.child; null !== s; ) {
- if (null !== (C = Ch(s))) {
- for (
- o.flags |= 128,
- Dj(w, !1),
- null !== (u = C.updateQueue) && ((o.updateQueue = u), (o.flags |= 4)),
- o.subtreeFlags = 0,
- u = i,
- i = o.child;
- null !== i;
- )
- (s = u),
- ((w = i).flags &= 14680066),
- null === (C = w.alternate)
- ? ((w.childLanes = 0),
- (w.lanes = s),
- (w.child = null),
- (w.subtreeFlags = 0),
- (w.memoizedProps = null),
- (w.memoizedState = null),
- (w.updateQueue = null),
- (w.dependencies = null),
- (w.stateNode = null))
- : ((w.childLanes = C.childLanes),
- (w.lanes = C.lanes),
- (w.child = C.child),
- (w.subtreeFlags = 0),
- (w.deletions = null),
- (w.memoizedProps = C.memoizedProps),
- (w.memoizedState = C.memoizedState),
- (w.updateQueue = C.updateQueue),
- (w.type = C.type),
- (s = C.dependencies),
- (w.dependencies =
- null === s
- ? null
- : { lanes: s.lanes, firstContext: s.firstContext })),
- (i = i.sibling);
- return G(es, (1 & es.current) | 2), o.child;
- }
- s = s.sibling;
- }
- null !== w.tail &&
- dt() > Zs &&
- ((o.flags |= 128), (u = !0), Dj(w, !1), (o.lanes = 4194304));
- }
- else {
- if (!u)
- if (null !== (s = Ch(C))) {
- if (
- ((o.flags |= 128),
- (u = !0),
- null !== (i = s.updateQueue) && ((o.updateQueue = i), (o.flags |= 4)),
- Dj(w, !0),
- null === w.tail && 'hidden' === w.tailMode && !C.alternate && !Fn)
- )
- return S(o), null;
- } else
- 2 * dt() - w.renderingStartTime > Zs &&
- 1073741824 !== i &&
- ((o.flags |= 128), (u = !0), Dj(w, !1), (o.lanes = 4194304));
- w.isBackwards
- ? ((C.sibling = o.child), (o.child = C))
- : (null !== (i = w.last) ? (i.sibling = C) : (o.child = C), (w.last = C));
- }
- return null !== w.tail
- ? ((o = w.tail),
- (w.rendering = o),
- (w.tail = o.sibling),
- (w.renderingStartTime = dt()),
- (o.sibling = null),
- (i = es.current),
- G(es, u ? (1 & i) | 2 : 1 & i),
- o)
- : (S(o), null);
- case 22:
- case 23:
- return (
- Hj(),
- (u = null !== o.memoizedState),
- null !== s && (null !== s.memoizedState) !== u && (o.flags |= 8192),
- u && 1 & o.mode
- ? !!(1073741824 & Vs) && (S(o), 6 & o.subtreeFlags && (o.flags |= 8192))
- : S(o),
- null
- );
- case 24:
- case 25:
- return null;
- }
- throw Error(p(156, o.tag));
- }
- function Ij(s, o) {
- switch ((wg(o), o.tag)) {
- case 1:
- return (
- Zf(o.type) && $f(),
- 65536 & (s = o.flags) ? ((o.flags = (-65537 & s) | 128), o) : null
- );
- case 3:
- return (
- zh(),
- E(Sn),
- E(wn),
- Eh(),
- 65536 & (s = o.flags) && !(128 & s) ? ((o.flags = (-65537 & s) | 128), o) : null
- );
- case 5:
- return Bh(o), null;
- case 13:
- if ((E(es), null !== (s = o.memoizedState) && null !== s.dehydrated)) {
- if (null === o.alternate) throw Error(p(340));
- Ig();
- }
- return 65536 & (s = o.flags) ? ((o.flags = (-65537 & s) | 128), o) : null;
- case 19:
- return E(es), null;
- case 4:
- return zh(), null;
- case 10:
- return ah(o.type._context), null;
- case 22:
- case 23:
- return Hj(), null;
- default:
- return null;
- }
- }
- (Es = function (s, o) {
- for (var i = o.child; null !== i; ) {
- if (5 === i.tag || 6 === i.tag) s.appendChild(i.stateNode);
- else if (4 !== i.tag && null !== i.child) {
- (i.child.return = i), (i = i.child);
- continue;
- }
- if (i === o) break;
- for (; null === i.sibling; ) {
- if (null === i.return || i.return === o) return;
- i = i.return;
- }
- (i.sibling.return = i.return), (i = i.sibling);
- }
- }),
- (ws = function () {}),
- (Ss = function (s, o, i, u) {
- var _ = s.memoizedProps;
- if (_ !== u) {
- (s = o.stateNode), xh(Xn.current);
- var w,
- C = null;
- switch (i) {
- case 'input':
- (_ = Ya(s, _)), (u = Ya(s, u)), (C = []);
- break;
- case 'select':
- (_ = xe({}, _, { value: void 0 })),
- (u = xe({}, u, { value: void 0 })),
- (C = []);
- break;
- case 'textarea':
- (_ = gb(s, _)), (u = gb(s, u)), (C = []);
- break;
- default:
- 'function' != typeof _.onClick &&
- 'function' == typeof u.onClick &&
- (s.onclick = Bf);
- }
- for (B in (ub(i, u), (i = null), _))
- if (!u.hasOwnProperty(B) && _.hasOwnProperty(B) && null != _[B])
- if ('style' === B) {
- var j = _[B];
- for (w in j) j.hasOwnProperty(w) && (i || (i = {}), (i[w] = ''));
- } else
- 'dangerouslySetInnerHTML' !== B &&
- 'children' !== B &&
- 'suppressContentEditableWarning' !== B &&
- 'suppressHydrationWarning' !== B &&
- 'autoFocus' !== B &&
- (x.hasOwnProperty(B) ? C || (C = []) : (C = C || []).push(B, null));
- for (B in u) {
- var L = u[B];
- if (
- ((j = null != _ ? _[B] : void 0),
- u.hasOwnProperty(B) && L !== j && (null != L || null != j))
- )
- if ('style' === B)
- if (j) {
- for (w in j)
- !j.hasOwnProperty(w) ||
- (L && L.hasOwnProperty(w)) ||
- (i || (i = {}), (i[w] = ''));
- for (w in L)
- L.hasOwnProperty(w) && j[w] !== L[w] && (i || (i = {}), (i[w] = L[w]));
- } else i || (C || (C = []), C.push(B, i)), (i = L);
- else
- 'dangerouslySetInnerHTML' === B
- ? ((L = L ? L.__html : void 0),
- (j = j ? j.__html : void 0),
- null != L && j !== L && (C = C || []).push(B, L))
- : 'children' === B
- ? ('string' != typeof L && 'number' != typeof L) ||
- (C = C || []).push(B, '' + L)
- : 'suppressContentEditableWarning' !== B &&
- 'suppressHydrationWarning' !== B &&
- (x.hasOwnProperty(B)
- ? (null != L && 'onScroll' === B && D('scroll', s),
- C || j === L || (C = []))
- : (C = C || []).push(B, L));
- }
- i && (C = C || []).push('style', i);
- var B = C;
- (o.updateQueue = B) && (o.flags |= 4);
- }
- }),
- (xs = function (s, o, i, u) {
- i !== u && (o.flags |= 4);
- });
- var Cs = !1,
- Os = !1,
- As = 'function' == typeof WeakSet ? WeakSet : Set,
- js = null;
- function Lj(s, o) {
- var i = s.ref;
- if (null !== i)
- if ('function' == typeof i)
- try {
- i(null);
- } catch (i) {
- W(s, o, i);
- }
- else i.current = null;
- }
- function Mj(s, o, i) {
- try {
- i();
- } catch (i) {
- W(s, o, i);
- }
- }
- var Is = !1;
- function Pj(s, o, i) {
- var u = o.updateQueue;
- if (null !== (u = null !== u ? u.lastEffect : null)) {
- var _ = (u = u.next);
- do {
- if ((_.tag & s) === s) {
- var w = _.destroy;
- (_.destroy = void 0), void 0 !== w && Mj(o, i, w);
- }
- _ = _.next;
- } while (_ !== u);
- }
- }
- function Qj(s, o) {
- if (null !== (o = null !== (o = o.updateQueue) ? o.lastEffect : null)) {
- var i = (o = o.next);
- do {
- if ((i.tag & s) === s) {
- var u = i.create;
- i.destroy = u();
- }
- i = i.next;
- } while (i !== o);
- }
- }
- function Rj(s) {
- var o = s.ref;
- if (null !== o) {
- var i = s.stateNode;
- s.tag, (s = i), 'function' == typeof o ? o(s) : (o.current = s);
- }
- }
- function Sj(s) {
- var o = s.alternate;
- null !== o && ((s.alternate = null), Sj(o)),
- (s.child = null),
- (s.deletions = null),
- (s.sibling = null),
- 5 === s.tag &&
- null !== (o = s.stateNode) &&
- (delete o[dn], delete o[fn], delete o[gn], delete o[yn], delete o[vn]),
- (s.stateNode = null),
- (s.return = null),
- (s.dependencies = null),
- (s.memoizedProps = null),
- (s.memoizedState = null),
- (s.pendingProps = null),
- (s.stateNode = null),
- (s.updateQueue = null);
- }
- function Tj(s) {
- return 5 === s.tag || 3 === s.tag || 4 === s.tag;
- }
- function Uj(s) {
- e: for (;;) {
- for (; null === s.sibling; ) {
- if (null === s.return || Tj(s.return)) return null;
- s = s.return;
- }
- for (
- s.sibling.return = s.return, s = s.sibling;
- 5 !== s.tag && 6 !== s.tag && 18 !== s.tag;
- ) {
- if (2 & s.flags) continue e;
- if (null === s.child || 4 === s.tag) continue e;
- (s.child.return = s), (s = s.child);
- }
- if (!(2 & s.flags)) return s.stateNode;
- }
- }
- function Vj(s, o, i) {
- var u = s.tag;
- if (5 === u || 6 === u)
- (s = s.stateNode),
- o
- ? 8 === i.nodeType
- ? i.parentNode.insertBefore(s, o)
- : i.insertBefore(s, o)
- : (8 === i.nodeType
- ? (o = i.parentNode).insertBefore(s, i)
- : (o = i).appendChild(s),
- null != (i = i._reactRootContainer) || null !== o.onclick || (o.onclick = Bf));
- else if (4 !== u && null !== (s = s.child))
- for (Vj(s, o, i), s = s.sibling; null !== s; ) Vj(s, o, i), (s = s.sibling);
- }
- function Wj(s, o, i) {
- var u = s.tag;
- if (5 === u || 6 === u) (s = s.stateNode), o ? i.insertBefore(s, o) : i.appendChild(s);
- else if (4 !== u && null !== (s = s.child))
- for (Wj(s, o, i), s = s.sibling; null !== s; ) Wj(s, o, i), (s = s.sibling);
- }
- var Ps = null,
- Ms = !1;
- function Yj(s, o, i) {
- for (i = i.child; null !== i; ) Zj(s, o, i), (i = i.sibling);
- }
- function Zj(s, o, i) {
- if (wt && 'function' == typeof wt.onCommitFiberUnmount)
- try {
- wt.onCommitFiberUnmount(Et, i);
- } catch (s) {}
- switch (i.tag) {
- case 5:
- Os || Lj(i, o);
- case 6:
- var u = Ps,
- _ = Ms;
- (Ps = null),
- Yj(s, o, i),
- (Ms = _),
- null !== (Ps = u) &&
- (Ms
- ? ((s = Ps),
- (i = i.stateNode),
- 8 === s.nodeType ? s.parentNode.removeChild(i) : s.removeChild(i))
- : Ps.removeChild(i.stateNode));
- break;
- case 18:
- null !== Ps &&
- (Ms
- ? ((s = Ps),
- (i = i.stateNode),
- 8 === s.nodeType ? Kf(s.parentNode, i) : 1 === s.nodeType && Kf(s, i),
- bd(s))
- : Kf(Ps, i.stateNode));
- break;
- case 4:
- (u = Ps),
- (_ = Ms),
- (Ps = i.stateNode.containerInfo),
- (Ms = !0),
- Yj(s, o, i),
- (Ps = u),
- (Ms = _);
- break;
- case 0:
- case 11:
- case 14:
- case 15:
- if (!Os && null !== (u = i.updateQueue) && null !== (u = u.lastEffect)) {
- _ = u = u.next;
- do {
- var w = _,
- x = w.destroy;
- (w = w.tag), void 0 !== x && (2 & w || 4 & w) && Mj(i, o, x), (_ = _.next);
- } while (_ !== u);
- }
- Yj(s, o, i);
- break;
- case 1:
- if (!Os && (Lj(i, o), 'function' == typeof (u = i.stateNode).componentWillUnmount))
- try {
- (u.props = i.memoizedProps),
- (u.state = i.memoizedState),
- u.componentWillUnmount();
- } catch (s) {
- W(i, o, s);
- }
- Yj(s, o, i);
- break;
- case 21:
- Yj(s, o, i);
- break;
- case 22:
- 1 & i.mode
- ? ((Os = (u = Os) || null !== i.memoizedState), Yj(s, o, i), (Os = u))
- : Yj(s, o, i);
- break;
- default:
- Yj(s, o, i);
- }
- }
- function ak(s) {
- var o = s.updateQueue;
- if (null !== o) {
- s.updateQueue = null;
- var i = s.stateNode;
- null === i && (i = s.stateNode = new As()),
- o.forEach(function (o) {
- var u = bk.bind(null, s, o);
- i.has(o) || (i.add(o), o.then(u, u));
- });
- }
- }
- function ck(s, o) {
- var i = o.deletions;
- if (null !== i)
- for (var u = 0; u < i.length; u++) {
- var _ = i[u];
- try {
- var w = s,
- x = o,
- C = x;
- e: for (; null !== C; ) {
- switch (C.tag) {
- case 5:
- (Ps = C.stateNode), (Ms = !1);
- break e;
- case 3:
- case 4:
- (Ps = C.stateNode.containerInfo), (Ms = !0);
- break e;
- }
- C = C.return;
- }
- if (null === Ps) throw Error(p(160));
- Zj(w, x, _), (Ps = null), (Ms = !1);
- var j = _.alternate;
- null !== j && (j.return = null), (_.return = null);
- } catch (s) {
- W(_, o, s);
- }
- }
- if (12854 & o.subtreeFlags) for (o = o.child; null !== o; ) dk(o, s), (o = o.sibling);
- }
- function dk(s, o) {
- var i = s.alternate,
- u = s.flags;
- switch (s.tag) {
- case 0:
- case 11:
- case 14:
- case 15:
- if ((ck(o, s), ek(s), 4 & u)) {
- try {
- Pj(3, s, s.return), Qj(3, s);
- } catch (o) {
- W(s, s.return, o);
- }
- try {
- Pj(5, s, s.return);
- } catch (o) {
- W(s, s.return, o);
- }
- }
- break;
- case 1:
- ck(o, s), ek(s), 512 & u && null !== i && Lj(i, i.return);
- break;
- case 5:
- if ((ck(o, s), ek(s), 512 & u && null !== i && Lj(i, i.return), 32 & s.flags)) {
- var _ = s.stateNode;
- try {
- ob(_, '');
- } catch (o) {
- W(s, s.return, o);
- }
- }
- if (4 & u && null != (_ = s.stateNode)) {
- var w = s.memoizedProps,
- x = null !== i ? i.memoizedProps : w,
- C = s.type,
- j = s.updateQueue;
- if (((s.updateQueue = null), null !== j))
- try {
- 'input' === C && 'radio' === w.type && null != w.name && ab(_, w), vb(C, x);
- var L = vb(C, w);
- for (x = 0; x < j.length; x += 2) {
- var B = j[x],
- $ = j[x + 1];
- 'style' === B
- ? sb(_, $)
- : 'dangerouslySetInnerHTML' === B
- ? $e(_, $)
- : 'children' === B
- ? ob(_, $)
- : ta(_, B, $, L);
- }
- switch (C) {
- case 'input':
- bb(_, w);
- break;
- case 'textarea':
- ib(_, w);
- break;
- case 'select':
- var V = _._wrapperState.wasMultiple;
- _._wrapperState.wasMultiple = !!w.multiple;
- var U = w.value;
- null != U
- ? fb(_, !!w.multiple, U, !1)
- : V !== !!w.multiple &&
- (null != w.defaultValue
- ? fb(_, !!w.multiple, w.defaultValue, !0)
- : fb(_, !!w.multiple, w.multiple ? [] : '', !1));
- }
- _[fn] = w;
- } catch (o) {
- W(s, s.return, o);
- }
- }
- break;
- case 6:
- if ((ck(o, s), ek(s), 4 & u)) {
- if (null === s.stateNode) throw Error(p(162));
- (_ = s.stateNode), (w = s.memoizedProps);
- try {
- _.nodeValue = w;
- } catch (o) {
- W(s, s.return, o);
- }
- }
- break;
- case 3:
- if ((ck(o, s), ek(s), 4 & u && null !== i && i.memoizedState.isDehydrated))
- try {
- bd(o.containerInfo);
- } catch (o) {
- W(s, s.return, o);
- }
- break;
- case 4:
- default:
- ck(o, s), ek(s);
- break;
- case 13:
- ck(o, s),
- ek(s),
- 8192 & (_ = s.child).flags &&
- ((w = null !== _.memoizedState),
- (_.stateNode.isHidden = w),
- !w ||
- (null !== _.alternate && null !== _.alternate.memoizedState) ||
- (Xs = dt())),
- 4 & u && ak(s);
- break;
- case 22:
- if (
- ((B = null !== i && null !== i.memoizedState),
- 1 & s.mode ? ((Os = (L = Os) || B), ck(o, s), (Os = L)) : ck(o, s),
- ek(s),
- 8192 & u)
- ) {
- if (
- ((L = null !== s.memoizedState), (s.stateNode.isHidden = L) && !B && 1 & s.mode)
- )
- for (js = s, B = s.child; null !== B; ) {
- for ($ = js = B; null !== js; ) {
- switch (((U = (V = js).child), V.tag)) {
- case 0:
- case 11:
- case 14:
- case 15:
- Pj(4, V, V.return);
- break;
- case 1:
- Lj(V, V.return);
- var z = V.stateNode;
- if ('function' == typeof z.componentWillUnmount) {
- (u = V), (i = V.return);
- try {
- (o = u),
- (z.props = o.memoizedProps),
- (z.state = o.memoizedState),
- z.componentWillUnmount();
- } catch (s) {
- W(u, i, s);
- }
- }
- break;
- case 5:
- Lj(V, V.return);
- break;
- case 22:
- if (null !== V.memoizedState) {
- gk($);
- continue;
- }
- }
- null !== U ? ((U.return = V), (js = U)) : gk($);
- }
- B = B.sibling;
- }
- e: for (B = null, $ = s; ; ) {
- if (5 === $.tag) {
- if (null === B) {
- B = $;
- try {
- (_ = $.stateNode),
- L
- ? 'function' == typeof (w = _.style).setProperty
- ? w.setProperty('display', 'none', 'important')
- : (w.display = 'none')
- : ((C = $.stateNode),
- (x =
- null != (j = $.memoizedProps.style) && j.hasOwnProperty('display')
- ? j.display
- : null),
- (C.style.display = rb('display', x)));
- } catch (o) {
- W(s, s.return, o);
- }
- }
- } else if (6 === $.tag) {
- if (null === B)
- try {
- $.stateNode.nodeValue = L ? '' : $.memoizedProps;
- } catch (o) {
- W(s, s.return, o);
- }
- } else if (
- ((22 !== $.tag && 23 !== $.tag) || null === $.memoizedState || $ === s) &&
- null !== $.child
- ) {
- ($.child.return = $), ($ = $.child);
- continue;
- }
- if ($ === s) break e;
- for (; null === $.sibling; ) {
- if (null === $.return || $.return === s) break e;
- B === $ && (B = null), ($ = $.return);
- }
- B === $ && (B = null), ($.sibling.return = $.return), ($ = $.sibling);
- }
- }
- break;
- case 19:
- ck(o, s), ek(s), 4 & u && ak(s);
- case 21:
- }
- }
- function ek(s) {
- var o = s.flags;
- if (2 & o) {
- try {
- e: {
- for (var i = s.return; null !== i; ) {
- if (Tj(i)) {
- var u = i;
- break e;
- }
- i = i.return;
- }
- throw Error(p(160));
- }
- switch (u.tag) {
- case 5:
- var _ = u.stateNode;
- 32 & u.flags && (ob(_, ''), (u.flags &= -33)), Wj(s, Uj(s), _);
- break;
- case 3:
- case 4:
- var w = u.stateNode.containerInfo;
- Vj(s, Uj(s), w);
- break;
- default:
- throw Error(p(161));
- }
- } catch (o) {
- W(s, s.return, o);
- }
- s.flags &= -3;
- }
- 4096 & o && (s.flags &= -4097);
- }
- function hk(s, o, i) {
- (js = s), ik(s, o, i);
- }
- function ik(s, o, i) {
- for (var u = !!(1 & s.mode); null !== js; ) {
- var _ = js,
- w = _.child;
- if (22 === _.tag && u) {
- var x = null !== _.memoizedState || Cs;
- if (!x) {
- var C = _.alternate,
- j = (null !== C && null !== C.memoizedState) || Os;
- C = Cs;
- var L = Os;
- if (((Cs = x), (Os = j) && !L))
- for (js = _; null !== js; )
- (j = (x = js).child),
- 22 === x.tag && null !== x.memoizedState
- ? jk(_)
- : null !== j
- ? ((j.return = x), (js = j))
- : jk(_);
- for (; null !== w; ) (js = w), ik(w, o, i), (w = w.sibling);
- (js = _), (Cs = C), (Os = L);
- }
- kk(s);
- } else 8772 & _.subtreeFlags && null !== w ? ((w.return = _), (js = w)) : kk(s);
- }
- }
- function kk(s) {
- for (; null !== js; ) {
- var o = js;
- if (8772 & o.flags) {
- var i = o.alternate;
- try {
- if (8772 & o.flags)
- switch (o.tag) {
- case 0:
- case 11:
- case 15:
- Os || Qj(5, o);
- break;
- case 1:
- var u = o.stateNode;
- if (4 & o.flags && !Os)
- if (null === i) u.componentDidMount();
- else {
- var _ =
- o.elementType === o.type
- ? i.memoizedProps
- : Ci(o.type, i.memoizedProps);
- u.componentDidUpdate(
- _,
- i.memoizedState,
- u.__reactInternalSnapshotBeforeUpdate
- );
- }
- var w = o.updateQueue;
- null !== w && sh(o, w, u);
- break;
- case 3:
- var x = o.updateQueue;
- if (null !== x) {
- if (((i = null), null !== o.child))
- switch (o.child.tag) {
- case 5:
- case 1:
- i = o.child.stateNode;
- }
- sh(o, x, i);
- }
- break;
- case 5:
- var C = o.stateNode;
- if (null === i && 4 & o.flags) {
- i = C;
- var j = o.memoizedProps;
- switch (o.type) {
- case 'button':
- case 'input':
- case 'select':
- case 'textarea':
- j.autoFocus && i.focus();
- break;
- case 'img':
- j.src && (i.src = j.src);
- }
- }
- break;
- case 6:
- case 4:
- case 12:
- case 19:
- case 17:
- case 21:
- case 22:
- case 23:
- case 25:
- break;
- case 13:
- if (null === o.memoizedState) {
- var L = o.alternate;
- if (null !== L) {
- var B = L.memoizedState;
- if (null !== B) {
- var $ = B.dehydrated;
- null !== $ && bd($);
- }
- }
- }
- break;
- default:
- throw Error(p(163));
- }
- Os || (512 & o.flags && Rj(o));
- } catch (s) {
- W(o, o.return, s);
- }
- }
- if (o === s) {
- js = null;
- break;
- }
- if (null !== (i = o.sibling)) {
- (i.return = o.return), (js = i);
- break;
- }
- js = o.return;
- }
- }
- function gk(s) {
- for (; null !== js; ) {
- var o = js;
- if (o === s) {
- js = null;
- break;
- }
- var i = o.sibling;
- if (null !== i) {
- (i.return = o.return), (js = i);
- break;
- }
- js = o.return;
- }
- }
- function jk(s) {
- for (; null !== js; ) {
- var o = js;
- try {
- switch (o.tag) {
- case 0:
- case 11:
- case 15:
- var i = o.return;
- try {
- Qj(4, o);
- } catch (s) {
- W(o, i, s);
- }
- break;
- case 1:
- var u = o.stateNode;
- if ('function' == typeof u.componentDidMount) {
- var _ = o.return;
- try {
- u.componentDidMount();
- } catch (s) {
- W(o, _, s);
- }
- }
- var w = o.return;
- try {
- Rj(o);
- } catch (s) {
- W(o, w, s);
- }
- break;
- case 5:
- var x = o.return;
- try {
- Rj(o);
- } catch (s) {
- W(o, x, s);
- }
- }
- } catch (s) {
- W(o, o.return, s);
- }
- if (o === s) {
- js = null;
- break;
- }
- var C = o.sibling;
- if (null !== C) {
- (C.return = o.return), (js = C);
- break;
- }
- js = o.return;
- }
- }
- var Ts,
- Ns = Math.ceil,
- Rs = z.ReactCurrentDispatcher,
- Ds = z.ReactCurrentOwner,
- Ls = z.ReactCurrentBatchConfig,
- Bs = 0,
- Fs = null,
- qs = null,
- $s = 0,
- Vs = 0,
- Us = Uf(0),
- zs = 0,
- Ws = null,
- Ks = 0,
- Hs = 0,
- Js = 0,
- Gs = null,
- Ys = null,
- Xs = 0,
- Zs = 1 / 0,
- Qs = null,
- eo = !1,
- to = null,
- ro = null,
- no = !1,
- so = null,
- oo = 0,
- io = 0,
- ao = null,
- lo = -1,
- co = 0;
- function R() {
- return 6 & Bs ? dt() : -1 !== lo ? lo : (lo = dt());
- }
- function yi(s) {
- return 1 & s.mode
- ? 2 & Bs && 0 !== $s
- ? $s & -$s
- : null !== $n.transition
- ? (0 === co && (co = yc()), co)
- : 0 !== (s = At)
- ? s
- : (s = void 0 === (s = window.event) ? 16 : jd(s.type))
- : 1;
- }
- function gi(s, o, i, u) {
- if (50 < io) throw ((io = 0), (ao = null), Error(p(185)));
- Ac(s, i, u),
- (2 & Bs && s === Fs) ||
- (s === Fs && (!(2 & Bs) && (Hs |= i), 4 === zs && Ck(s, $s)),
- Dk(s, u),
- 1 === i && 0 === Bs && !(1 & o.mode) && ((Zs = dt() + 500), Cn && jg()));
- }
- function Dk(s, o) {
- var i = s.callbackNode;
- !(function wc(s, o) {
- for (
- var i = s.suspendedLanes,
- u = s.pingedLanes,
- _ = s.expirationTimes,
- w = s.pendingLanes;
- 0 < w;
- ) {
- var x = 31 - St(w),
- C = 1 << x,
- j = _[x];
- -1 === j
- ? (C & i && !(C & u)) || (_[x] = vc(C, o))
- : j <= o && (s.expiredLanes |= C),
- (w &= ~C);
- }
- })(s, o);
- var u = uc(s, s === Fs ? $s : 0);
- if (0 === u) null !== i && ut(i), (s.callbackNode = null), (s.callbackPriority = 0);
- else if (((o = u & -u), s.callbackPriority !== o)) {
- if ((null != i && ut(i), 1 === o))
- 0 === s.tag
- ? (function ig(s) {
- (Cn = !0), hg(s);
- })(Ek.bind(null, s))
- : hg(Ek.bind(null, s)),
- pn(function () {
- !(6 & Bs) && jg();
- }),
- (i = null);
- else {
- switch (Dc(u)) {
- case 1:
- i = gt;
- break;
- case 4:
- i = yt;
- break;
- case 16:
- default:
- i = vt;
- break;
- case 536870912:
- i = _t;
- }
- i = Fk(i, Gk.bind(null, s));
- }
- (s.callbackPriority = o), (s.callbackNode = i);
- }
- }
- function Gk(s, o) {
- if (((lo = -1), (co = 0), 6 & Bs)) throw Error(p(327));
- var i = s.callbackNode;
- if (Hk() && s.callbackNode !== i) return null;
- var u = uc(s, s === Fs ? $s : 0);
- if (0 === u) return null;
- if (30 & u || u & s.expiredLanes || o) o = Ik(s, u);
- else {
- o = u;
- var _ = Bs;
- Bs |= 2;
- var w = Jk();
- for ((Fs === s && $s === o) || ((Qs = null), (Zs = dt() + 500), Kk(s, o)); ; )
- try {
- Lk();
- break;
- } catch (o) {
- Mk(s, o);
- }
- $g(),
- (Rs.current = w),
- (Bs = _),
- null !== qs ? (o = 0) : ((Fs = null), ($s = 0), (o = zs));
- }
- if (0 !== o) {
- if ((2 === o && 0 !== (_ = xc(s)) && ((u = _), (o = Nk(s, _))), 1 === o))
- throw ((i = Ws), Kk(s, 0), Ck(s, u), Dk(s, dt()), i);
- if (6 === o) Ck(s, u);
- else {
- if (
- ((_ = s.current.alternate),
- !(
- 30 & u ||
- (function Ok(s) {
- for (var o = s; ; ) {
- if (16384 & o.flags) {
- var i = o.updateQueue;
- if (null !== i && null !== (i = i.stores))
- for (var u = 0; u < i.length; u++) {
- var _ = i[u],
- w = _.getSnapshot;
- _ = _.value;
- try {
- if (!Lr(w(), _)) return !1;
- } catch (s) {
- return !1;
- }
- }
- }
- if (((i = o.child), 16384 & o.subtreeFlags && null !== i))
- (i.return = o), (o = i);
- else {
- if (o === s) break;
- for (; null === o.sibling; ) {
- if (null === o.return || o.return === s) return !0;
- o = o.return;
- }
- (o.sibling.return = o.return), (o = o.sibling);
- }
- }
- return !0;
- })(_) ||
- ((o = Ik(s, u)),
- 2 === o && ((w = xc(s)), 0 !== w && ((u = w), (o = Nk(s, w)))),
- 1 !== o)
- ))
- )
- throw ((i = Ws), Kk(s, 0), Ck(s, u), Dk(s, dt()), i);
- switch (((s.finishedWork = _), (s.finishedLanes = u), o)) {
- case 0:
- case 1:
- throw Error(p(345));
- case 2:
- case 5:
- Pk(s, Ys, Qs);
- break;
- case 3:
- if ((Ck(s, u), (130023424 & u) === u && 10 < (o = Xs + 500 - dt()))) {
- if (0 !== uc(s, 0)) break;
- if (((_ = s.suspendedLanes) & u) !== u) {
- R(), (s.pingedLanes |= s.suspendedLanes & _);
- break;
- }
- s.timeoutHandle = ln(Pk.bind(null, s, Ys, Qs), o);
- break;
- }
- Pk(s, Ys, Qs);
- break;
- case 4:
- if ((Ck(s, u), (4194240 & u) === u)) break;
- for (o = s.eventTimes, _ = -1; 0 < u; ) {
- var x = 31 - St(u);
- (w = 1 << x), (x = o[x]) > _ && (_ = x), (u &= ~w);
- }
- if (
- ((u = _),
- 10 <
- (u =
- (120 > (u = dt() - u)
- ? 120
- : 480 > u
- ? 480
- : 1080 > u
- ? 1080
- : 1920 > u
- ? 1920
- : 3e3 > u
- ? 3e3
- : 4320 > u
- ? 4320
- : 1960 * Ns(u / 1960)) - u))
- ) {
- s.timeoutHandle = ln(Pk.bind(null, s, Ys, Qs), u);
- break;
- }
- Pk(s, Ys, Qs);
- break;
- default:
- throw Error(p(329));
- }
- }
- }
- return Dk(s, dt()), s.callbackNode === i ? Gk.bind(null, s) : null;
- }
- function Nk(s, o) {
- var i = Gs;
- return (
- s.current.memoizedState.isDehydrated && (Kk(s, o).flags |= 256),
- 2 !== (s = Ik(s, o)) && ((o = Ys), (Ys = i), null !== o && Fj(o)),
- s
- );
- }
- function Fj(s) {
- null === Ys ? (Ys = s) : Ys.push.apply(Ys, s);
- }
- function Ck(s, o) {
- for (
- o &= ~Js, o &= ~Hs, s.suspendedLanes |= o, s.pingedLanes &= ~o, s = s.expirationTimes;
- 0 < o;
- ) {
- var i = 31 - St(o),
- u = 1 << i;
- (s[i] = -1), (o &= ~u);
- }
- }
- function Ek(s) {
- if (6 & Bs) throw Error(p(327));
- Hk();
- var o = uc(s, 0);
- if (!(1 & o)) return Dk(s, dt()), null;
- var i = Ik(s, o);
- if (0 !== s.tag && 2 === i) {
- var u = xc(s);
- 0 !== u && ((o = u), (i = Nk(s, u)));
- }
- if (1 === i) throw ((i = Ws), Kk(s, 0), Ck(s, o), Dk(s, dt()), i);
- if (6 === i) throw Error(p(345));
- return (
- (s.finishedWork = s.current.alternate),
- (s.finishedLanes = o),
- Pk(s, Ys, Qs),
- Dk(s, dt()),
- null
- );
- }
- function Qk(s, o) {
- var i = Bs;
- Bs |= 1;
- try {
- return s(o);
- } finally {
- 0 === (Bs = i) && ((Zs = dt() + 500), Cn && jg());
- }
- }
- function Rk(s) {
- null !== so && 0 === so.tag && !(6 & Bs) && Hk();
- var o = Bs;
- Bs |= 1;
- var i = Ls.transition,
- u = At;
- try {
- if (((Ls.transition = null), (At = 1), s)) return s();
- } finally {
- (At = u), (Ls.transition = i), !(6 & (Bs = o)) && jg();
- }
- }
- function Hj() {
- (Vs = Us.current), E(Us);
- }
- function Kk(s, o) {
- (s.finishedWork = null), (s.finishedLanes = 0);
- var i = s.timeoutHandle;
- if ((-1 !== i && ((s.timeoutHandle = -1), cn(i)), null !== qs))
- for (i = qs.return; null !== i; ) {
- var u = i;
- switch ((wg(u), u.tag)) {
- case 1:
- null != (u = u.type.childContextTypes) && $f();
- break;
- case 3:
- zh(), E(Sn), E(wn), Eh();
- break;
- case 5:
- Bh(u);
- break;
- case 4:
- zh();
- break;
- case 13:
- case 19:
- E(es);
- break;
- case 10:
- ah(u.type._context);
- break;
- case 22:
- case 23:
- Hj();
- }
- i = i.return;
- }
- if (
- ((Fs = s),
- (qs = s = Pg(s.current, null)),
- ($s = Vs = o),
- (zs = 0),
- (Ws = null),
- (Js = Hs = Ks = 0),
- (Ys = Gs = null),
- null !== Jn)
- ) {
- for (o = 0; o < Jn.length; o++)
- if (null !== (u = (i = Jn[o]).interleaved)) {
- i.interleaved = null;
- var _ = u.next,
- w = i.pending;
- if (null !== w) {
- var x = w.next;
- (w.next = _), (u.next = x);
- }
- i.pending = u;
- }
- Jn = null;
- }
- return s;
- }
- function Mk(s, o) {
- for (;;) {
- var i = qs;
- try {
- if (($g(), (rs.current = ds), cs)) {
- for (var u = os.memoizedState; null !== u; ) {
- var _ = u.queue;
- null !== _ && (_.pending = null), (u = u.next);
- }
- cs = !1;
- }
- if (
- ((ss = 0),
- (ls = as = os = null),
- (us = !1),
- (ps = 0),
- (Ds.current = null),
- null === i || null === i.return)
- ) {
- (zs = 1), (Ws = o), (qs = null);
- break;
- }
- e: {
- var w = s,
- x = i.return,
- C = i,
- j = o;
- if (
- ((o = $s),
- (C.flags |= 32768),
- null !== j && 'object' == typeof j && 'function' == typeof j.then)
- ) {
- var L = j,
- B = C,
- $ = B.tag;
- if (!(1 & B.mode || (0 !== $ && 11 !== $ && 15 !== $))) {
- var V = B.alternate;
- V
- ? ((B.updateQueue = V.updateQueue),
- (B.memoizedState = V.memoizedState),
- (B.lanes = V.lanes))
- : ((B.updateQueue = null), (B.memoizedState = null));
- }
- var U = Ui(x);
- if (null !== U) {
- (U.flags &= -257), Vi(U, x, C, 0, o), 1 & U.mode && Si(w, L, o), (j = L);
- var z = (o = U).updateQueue;
- if (null === z) {
- var Y = new Set();
- Y.add(j), (o.updateQueue = Y);
- } else z.add(j);
- break e;
- }
- if (!(1 & o)) {
- Si(w, L, o), tj();
- break e;
- }
- j = Error(p(426));
- } else if (Fn && 1 & C.mode) {
- var Z = Ui(x);
- if (null !== Z) {
- !(65536 & Z.flags) && (Z.flags |= 256), Vi(Z, x, C, 0, o), Jg(Ji(j, C));
- break e;
- }
- }
- (w = j = Ji(j, C)),
- 4 !== zs && (zs = 2),
- null === Gs ? (Gs = [w]) : Gs.push(w),
- (w = x);
- do {
- switch (w.tag) {
- case 3:
- (w.flags |= 65536), (o &= -o), (w.lanes |= o), ph(w, Ni(0, j, o));
- break e;
- case 1:
- C = j;
- var ee = w.type,
- ie = w.stateNode;
- if (
- !(
- 128 & w.flags ||
- ('function' != typeof ee.getDerivedStateFromError &&
- (null === ie ||
- 'function' != typeof ie.componentDidCatch ||
- (null !== ro && ro.has(ie))))
- )
- ) {
- (w.flags |= 65536), (o &= -o), (w.lanes |= o), ph(w, Qi(w, C, o));
- break e;
- }
- }
- w = w.return;
- } while (null !== w);
- }
- Sk(i);
- } catch (s) {
- (o = s), qs === i && null !== i && (qs = i = i.return);
- continue;
- }
- break;
- }
- }
- function Jk() {
- var s = Rs.current;
- return (Rs.current = ds), null === s ? ds : s;
- }
- function tj() {
- (0 !== zs && 3 !== zs && 2 !== zs) || (zs = 4),
- null === Fs || (!(268435455 & Ks) && !(268435455 & Hs)) || Ck(Fs, $s);
- }
- function Ik(s, o) {
- var i = Bs;
- Bs |= 2;
- var u = Jk();
- for ((Fs === s && $s === o) || ((Qs = null), Kk(s, o)); ; )
- try {
- Tk();
- break;
- } catch (o) {
- Mk(s, o);
- }
- if (($g(), (Bs = i), (Rs.current = u), null !== qs)) throw Error(p(261));
- return (Fs = null), ($s = 0), zs;
- }
- function Tk() {
- for (; null !== qs; ) Uk(qs);
- }
- function Lk() {
- for (; null !== qs && !pt(); ) Uk(qs);
- }
- function Uk(s) {
- var o = Ts(s.alternate, s, Vs);
- (s.memoizedProps = s.pendingProps), null === o ? Sk(s) : (qs = o), (Ds.current = null);
- }
- function Sk(s) {
- var o = s;
- do {
- var i = o.alternate;
- if (((s = o.return), 32768 & o.flags)) {
- if (null !== (i = Ij(i, o))) return (i.flags &= 32767), void (qs = i);
- if (null === s) return (zs = 6), void (qs = null);
- (s.flags |= 32768), (s.subtreeFlags = 0), (s.deletions = null);
- } else if (null !== (i = Ej(i, o, Vs))) return void (qs = i);
- if (null !== (o = o.sibling)) return void (qs = o);
- qs = o = s;
- } while (null !== o);
- 0 === zs && (zs = 5);
- }
- function Pk(s, o, i) {
- var u = At,
- _ = Ls.transition;
- try {
- (Ls.transition = null),
- (At = 1),
- (function Wk(s, o, i, u) {
- do {
- Hk();
- } while (null !== so);
- if (6 & Bs) throw Error(p(327));
- i = s.finishedWork;
- var _ = s.finishedLanes;
- if (null === i) return null;
- if (((s.finishedWork = null), (s.finishedLanes = 0), i === s.current))
- throw Error(p(177));
- (s.callbackNode = null), (s.callbackPriority = 0);
- var w = i.lanes | i.childLanes;
- if (
- ((function Bc(s, o) {
- var i = s.pendingLanes & ~o;
- (s.pendingLanes = o),
- (s.suspendedLanes = 0),
- (s.pingedLanes = 0),
- (s.expiredLanes &= o),
- (s.mutableReadLanes &= o),
- (s.entangledLanes &= o),
- (o = s.entanglements);
- var u = s.eventTimes;
- for (s = s.expirationTimes; 0 < i; ) {
- var _ = 31 - St(i),
- w = 1 << _;
- (o[_] = 0), (u[_] = -1), (s[_] = -1), (i &= ~w);
- }
- })(s, w),
- s === Fs && ((qs = Fs = null), ($s = 0)),
- (!(2064 & i.subtreeFlags) && !(2064 & i.flags)) ||
- no ||
- ((no = !0),
- Fk(vt, function () {
- return Hk(), null;
- })),
- (w = !!(15990 & i.flags)),
- !!(15990 & i.subtreeFlags) || w)
- ) {
- (w = Ls.transition), (Ls.transition = null);
- var x = At;
- At = 1;
- var C = Bs;
- (Bs |= 4),
- (Ds.current = null),
- (function Oj(s, o) {
- if (((on = zt), Ne((s = Me())))) {
- if ('selectionStart' in s)
- var i = { start: s.selectionStart, end: s.selectionEnd };
- else
- e: {
- var u =
- (i = ((i = s.ownerDocument) && i.defaultView) || window)
- .getSelection && i.getSelection();
- if (u && 0 !== u.rangeCount) {
- i = u.anchorNode;
- var _ = u.anchorOffset,
- w = u.focusNode;
- u = u.focusOffset;
- try {
- i.nodeType, w.nodeType;
- } catch (s) {
- i = null;
- break e;
- }
- var x = 0,
- C = -1,
- j = -1,
- L = 0,
- B = 0,
- $ = s,
- V = null;
- t: for (;;) {
- for (
- var U;
- $ !== i || (0 !== _ && 3 !== $.nodeType) || (C = x + _),
- $ !== w || (0 !== u && 3 !== $.nodeType) || (j = x + u),
- 3 === $.nodeType && (x += $.nodeValue.length),
- null !== (U = $.firstChild);
- )
- (V = $), ($ = U);
- for (;;) {
- if ($ === s) break t;
- if (
- (V === i && ++L === _ && (C = x),
- V === w && ++B === u && (j = x),
- null !== (U = $.nextSibling))
- )
- break;
- V = ($ = V).parentNode;
- }
- $ = U;
- }
- i = -1 === C || -1 === j ? null : { start: C, end: j };
- } else i = null;
- }
- i = i || { start: 0, end: 0 };
- } else i = null;
- for (
- an = { focusedElem: s, selectionRange: i }, zt = !1, js = o;
- null !== js;
- )
- if (((s = (o = js).child), 1028 & o.subtreeFlags && null !== s))
- (s.return = o), (js = s);
- else
- for (; null !== js; ) {
- o = js;
- try {
- var z = o.alternate;
- if (1024 & o.flags)
- switch (o.tag) {
- case 0:
- case 11:
- case 15:
- case 5:
- case 6:
- case 4:
- case 17:
- break;
- case 1:
- if (null !== z) {
- var Y = z.memoizedProps,
- Z = z.memoizedState,
- ee = o.stateNode,
- ie = ee.getSnapshotBeforeUpdate(
- o.elementType === o.type ? Y : Ci(o.type, Y),
- Z
- );
- ee.__reactInternalSnapshotBeforeUpdate = ie;
- }
- break;
- case 3:
- var ae = o.stateNode.containerInfo;
- 1 === ae.nodeType
- ? (ae.textContent = '')
- : 9 === ae.nodeType &&
- ae.documentElement &&
- ae.removeChild(ae.documentElement);
- break;
- default:
- throw Error(p(163));
- }
- } catch (s) {
- W(o, o.return, s);
- }
- if (null !== (s = o.sibling)) {
- (s.return = o.return), (js = s);
- break;
- }
- js = o.return;
- }
- return (z = Is), (Is = !1), z;
- })(s, i),
- dk(i, s),
- Oe(an),
- (zt = !!on),
- (an = on = null),
- (s.current = i),
- hk(i, s, _),
- ht(),
- (Bs = C),
- (At = x),
- (Ls.transition = w);
- } else s.current = i;
- if (
- (no && ((no = !1), (so = s), (oo = _)),
- (w = s.pendingLanes),
- 0 === w && (ro = null),
- (function mc(s) {
- if (wt && 'function' == typeof wt.onCommitFiberRoot)
- try {
- wt.onCommitFiberRoot(Et, s, void 0, !(128 & ~s.current.flags));
- } catch (s) {}
- })(i.stateNode),
- Dk(s, dt()),
- null !== o)
- )
- for (u = s.onRecoverableError, i = 0; i < o.length; i++)
- (_ = o[i]), u(_.value, { componentStack: _.stack, digest: _.digest });
- if (eo) throw ((eo = !1), (s = to), (to = null), s);
- return (
- !!(1 & oo) && 0 !== s.tag && Hk(),
- (w = s.pendingLanes),
- 1 & w ? (s === ao ? io++ : ((io = 0), (ao = s))) : (io = 0),
- jg(),
- null
- );
- })(s, o, i, u);
- } finally {
- (Ls.transition = _), (At = u);
- }
- return null;
- }
- function Hk() {
- if (null !== so) {
- var s = Dc(oo),
- o = Ls.transition,
- i = At;
- try {
- if (((Ls.transition = null), (At = 16 > s ? 16 : s), null === so)) var u = !1;
- else {
- if (((s = so), (so = null), (oo = 0), 6 & Bs)) throw Error(p(331));
- var _ = Bs;
- for (Bs |= 4, js = s.current; null !== js; ) {
- var w = js,
- x = w.child;
- if (16 & js.flags) {
- var C = w.deletions;
- if (null !== C) {
- for (var j = 0; j < C.length; j++) {
- var L = C[j];
- for (js = L; null !== js; ) {
- var B = js;
- switch (B.tag) {
- case 0:
- case 11:
- case 15:
- Pj(8, B, w);
- }
- var $ = B.child;
- if (null !== $) ($.return = B), (js = $);
- else
- for (; null !== js; ) {
- var V = (B = js).sibling,
- U = B.return;
- if ((Sj(B), B === L)) {
- js = null;
- break;
- }
- if (null !== V) {
- (V.return = U), (js = V);
- break;
- }
- js = U;
- }
- }
- }
- var z = w.alternate;
- if (null !== z) {
- var Y = z.child;
- if (null !== Y) {
- z.child = null;
- do {
- var Z = Y.sibling;
- (Y.sibling = null), (Y = Z);
- } while (null !== Y);
- }
- }
- js = w;
- }
- }
- if (2064 & w.subtreeFlags && null !== x) (x.return = w), (js = x);
- else
- e: for (; null !== js; ) {
- if (2048 & (w = js).flags)
- switch (w.tag) {
- case 0:
- case 11:
- case 15:
- Pj(9, w, w.return);
- }
- var ee = w.sibling;
- if (null !== ee) {
- (ee.return = w.return), (js = ee);
- break e;
- }
- js = w.return;
- }
- }
- var ie = s.current;
- for (js = ie; null !== js; ) {
- var ae = (x = js).child;
- if (2064 & x.subtreeFlags && null !== ae) (ae.return = x), (js = ae);
- else
- e: for (x = ie; null !== js; ) {
- if (2048 & (C = js).flags)
- try {
- switch (C.tag) {
- case 0:
- case 11:
- case 15:
- Qj(9, C);
- }
- } catch (s) {
- W(C, C.return, s);
- }
- if (C === x) {
- js = null;
- break e;
- }
- var le = C.sibling;
- if (null !== le) {
- (le.return = C.return), (js = le);
- break e;
- }
- js = C.return;
- }
- }
- if (((Bs = _), jg(), wt && 'function' == typeof wt.onPostCommitFiberRoot))
- try {
- wt.onPostCommitFiberRoot(Et, s);
- } catch (s) {}
- u = !0;
- }
- return u;
- } finally {
- (At = i), (Ls.transition = o);
- }
- }
- return !1;
- }
- function Xk(s, o, i) {
- (s = nh(s, (o = Ni(0, (o = Ji(i, o)), 1)), 1)),
- (o = R()),
- null !== s && (Ac(s, 1, o), Dk(s, o));
- }
- function W(s, o, i) {
- if (3 === s.tag) Xk(s, s, i);
- else
- for (; null !== o; ) {
- if (3 === o.tag) {
- Xk(o, s, i);
- break;
- }
- if (1 === o.tag) {
- var u = o.stateNode;
- if (
- 'function' == typeof o.type.getDerivedStateFromError ||
- ('function' == typeof u.componentDidCatch && (null === ro || !ro.has(u)))
- ) {
- (o = nh(o, (s = Qi(o, (s = Ji(i, s)), 1)), 1)),
- (s = R()),
- null !== o && (Ac(o, 1, s), Dk(o, s));
- break;
- }
- }
- o = o.return;
- }
- }
- function Ti(s, o, i) {
- var u = s.pingCache;
- null !== u && u.delete(o),
- (o = R()),
- (s.pingedLanes |= s.suspendedLanes & i),
- Fs === s &&
- ($s & i) === i &&
- (4 === zs || (3 === zs && (130023424 & $s) === $s && 500 > dt() - Xs)
- ? Kk(s, 0)
- : (Js |= i)),
- Dk(s, o);
- }
- function Yk(s, o) {
- 0 === o &&
- (1 & s.mode ? ((o = Ot), !(130023424 & (Ot <<= 1)) && (Ot = 4194304)) : (o = 1));
- var i = R();
- null !== (s = ih(s, o)) && (Ac(s, o, i), Dk(s, i));
- }
- function uj(s) {
- var o = s.memoizedState,
- i = 0;
- null !== o && (i = o.retryLane), Yk(s, i);
- }
- function bk(s, o) {
- var i = 0;
- switch (s.tag) {
- case 13:
- var u = s.stateNode,
- _ = s.memoizedState;
- null !== _ && (i = _.retryLane);
- break;
- case 19:
- u = s.stateNode;
- break;
- default:
- throw Error(p(314));
- }
- null !== u && u.delete(o), Yk(s, i);
- }
- function Fk(s, o) {
- return ct(s, o);
- }
- function $k(s, o, i, u) {
- (this.tag = s),
- (this.key = i),
- (this.sibling =
- this.child =
- this.return =
- this.stateNode =
- this.type =
- this.elementType =
- null),
- (this.index = 0),
- (this.ref = null),
- (this.pendingProps = o),
- (this.dependencies =
- this.memoizedState =
- this.updateQueue =
- this.memoizedProps =
- null),
- (this.mode = u),
- (this.subtreeFlags = this.flags = 0),
- (this.deletions = null),
- (this.childLanes = this.lanes = 0),
- (this.alternate = null);
- }
- function Bg(s, o, i, u) {
- return new $k(s, o, i, u);
- }
- function aj(s) {
- return !(!(s = s.prototype) || !s.isReactComponent);
- }
- function Pg(s, o) {
- var i = s.alternate;
- return (
- null === i
- ? (((i = Bg(s.tag, o, s.key, s.mode)).elementType = s.elementType),
- (i.type = s.type),
- (i.stateNode = s.stateNode),
- (i.alternate = s),
- (s.alternate = i))
- : ((i.pendingProps = o),
- (i.type = s.type),
- (i.flags = 0),
- (i.subtreeFlags = 0),
- (i.deletions = null)),
- (i.flags = 14680064 & s.flags),
- (i.childLanes = s.childLanes),
- (i.lanes = s.lanes),
- (i.child = s.child),
- (i.memoizedProps = s.memoizedProps),
- (i.memoizedState = s.memoizedState),
- (i.updateQueue = s.updateQueue),
- (o = s.dependencies),
- (i.dependencies =
- null === o ? null : { lanes: o.lanes, firstContext: o.firstContext }),
- (i.sibling = s.sibling),
- (i.index = s.index),
- (i.ref = s.ref),
- i
- );
- }
- function Rg(s, o, i, u, _, w) {
- var x = 2;
- if (((u = s), 'function' == typeof s)) aj(s) && (x = 1);
- else if ('string' == typeof s) x = 5;
- else
- e: switch (s) {
- case ee:
- return Tg(i.children, _, w, o);
- case ie:
- (x = 8), (_ |= 8);
- break;
- case ae:
- return ((s = Bg(12, i, o, 2 | _)).elementType = ae), (s.lanes = w), s;
- case de:
- return ((s = Bg(13, i, o, _)).elementType = de), (s.lanes = w), s;
- case fe:
- return ((s = Bg(19, i, o, _)).elementType = fe), (s.lanes = w), s;
- case _e:
- return pj(i, _, w, o);
- default:
- if ('object' == typeof s && null !== s)
- switch (s.$$typeof) {
- case le:
- x = 10;
- break e;
- case ce:
- x = 9;
- break e;
- case pe:
- x = 11;
- break e;
- case ye:
- x = 14;
- break e;
- case be:
- (x = 16), (u = null);
- break e;
- }
- throw Error(p(130, null == s ? s : typeof s, ''));
- }
- return ((o = Bg(x, i, o, _)).elementType = s), (o.type = u), (o.lanes = w), o;
- }
- function Tg(s, o, i, u) {
- return ((s = Bg(7, s, u, o)).lanes = i), s;
- }
- function pj(s, o, i, u) {
- return (
- ((s = Bg(22, s, u, o)).elementType = _e),
- (s.lanes = i),
- (s.stateNode = { isHidden: !1 }),
- s
- );
- }
- function Qg(s, o, i) {
- return ((s = Bg(6, s, null, o)).lanes = i), s;
- }
- function Sg(s, o, i) {
- return (
- ((o = Bg(4, null !== s.children ? s.children : [], s.key, o)).lanes = i),
- (o.stateNode = {
- containerInfo: s.containerInfo,
- pendingChildren: null,
- implementation: s.implementation
- }),
- o
- );
- }
- function al(s, o, i, u, _) {
- (this.tag = o),
- (this.containerInfo = s),
- (this.finishedWork = this.pingCache = this.current = this.pendingChildren = null),
- (this.timeoutHandle = -1),
- (this.callbackNode = this.pendingContext = this.context = null),
- (this.callbackPriority = 0),
- (this.eventTimes = zc(0)),
- (this.expirationTimes = zc(-1)),
- (this.entangledLanes =
- this.finishedLanes =
- this.mutableReadLanes =
- this.expiredLanes =
- this.pingedLanes =
- this.suspendedLanes =
- this.pendingLanes =
- 0),
- (this.entanglements = zc(0)),
- (this.identifierPrefix = u),
- (this.onRecoverableError = _),
- (this.mutableSourceEagerHydrationData = null);
- }
- function bl(s, o, i, u, _, w, x, C, j) {
- return (
- (s = new al(s, o, i, C, j)),
- 1 === o ? ((o = 1), !0 === w && (o |= 8)) : (o = 0),
- (w = Bg(3, null, null, o)),
- (s.current = w),
- (w.stateNode = s),
- (w.memoizedState = {
- element: u,
- isDehydrated: i,
- cache: null,
- transitions: null,
- pendingSuspenseBoundaries: null
- }),
- kh(w),
- s
- );
- }
- function dl(s) {
- if (!s) return En;
- e: {
- if (Vb((s = s._reactInternals)) !== s || 1 !== s.tag) throw Error(p(170));
- var o = s;
- do {
- switch (o.tag) {
- case 3:
- o = o.stateNode.context;
- break e;
- case 1:
- if (Zf(o.type)) {
- o = o.stateNode.__reactInternalMemoizedMergedChildContext;
- break e;
- }
- }
- o = o.return;
- } while (null !== o);
- throw Error(p(171));
- }
- if (1 === s.tag) {
- var i = s.type;
- if (Zf(i)) return bg(s, i, o);
- }
- return o;
- }
- function el(s, o, i, u, _, w, x, C, j) {
- return (
- ((s = bl(i, u, !0, s, 0, w, 0, C, j)).context = dl(null)),
- (i = s.current),
- ((w = mh((u = R()), (_ = yi(i)))).callback = null != o ? o : null),
- nh(i, w, _),
- (s.current.lanes = _),
- Ac(s, _, u),
- Dk(s, u),
- s
- );
- }
- function fl(s, o, i, u) {
- var _ = o.current,
- w = R(),
- x = yi(_);
- return (
- (i = dl(i)),
- null === o.context ? (o.context = i) : (o.pendingContext = i),
- ((o = mh(w, x)).payload = { element: s }),
- null !== (u = void 0 === u ? null : u) && (o.callback = u),
- null !== (s = nh(_, o, x)) && (gi(s, _, x, w), oh(s, _, x)),
- x
- );
- }
- function gl(s) {
- return (s = s.current).child ? (s.child.tag, s.child.stateNode) : null;
- }
- function hl(s, o) {
- if (null !== (s = s.memoizedState) && null !== s.dehydrated) {
- var i = s.retryLane;
- s.retryLane = 0 !== i && i < o ? i : o;
- }
- }
- function il(s, o) {
- hl(s, o), (s = s.alternate) && hl(s, o);
- }
- Ts = function (s, o, i) {
- if (null !== s)
- if (s.memoizedProps !== o.pendingProps || Sn.current) _s = !0;
- else {
- if (!(s.lanes & i || 128 & o.flags))
- return (
- (_s = !1),
- (function yj(s, o, i) {
- switch (o.tag) {
- case 3:
- kj(o), Ig();
- break;
- case 5:
- Ah(o);
- break;
- case 1:
- Zf(o.type) && cg(o);
- break;
- case 4:
- yh(o, o.stateNode.containerInfo);
- break;
- case 10:
- var u = o.type._context,
- _ = o.memoizedProps.value;
- G(zn, u._currentValue), (u._currentValue = _);
- break;
- case 13:
- if (null !== (u = o.memoizedState))
- return null !== u.dehydrated
- ? (G(es, 1 & es.current), (o.flags |= 128), null)
- : i & o.child.childLanes
- ? oj(s, o, i)
- : (G(es, 1 & es.current),
- null !== (s = Zi(s, o, i)) ? s.sibling : null);
- G(es, 1 & es.current);
- break;
- case 19:
- if (((u = !!(i & o.childLanes)), 128 & s.flags)) {
- if (u) return xj(s, o, i);
- o.flags |= 128;
- }
- if (
- (null !== (_ = o.memoizedState) &&
- ((_.rendering = null), (_.tail = null), (_.lastEffect = null)),
- G(es, es.current),
- u)
- )
- break;
- return null;
- case 22:
- case 23:
- return (o.lanes = 0), dj(s, o, i);
- }
- return Zi(s, o, i);
- })(s, o, i)
- );
- _s = !!(131072 & s.flags);
- }
- else (_s = !1), Fn && 1048576 & o.flags && ug(o, Pn, o.index);
- switch (((o.lanes = 0), o.tag)) {
- case 2:
- var u = o.type;
- ij(s, o), (s = o.pendingProps);
- var _ = Yf(o, wn.current);
- ch(o, i), (_ = Nh(null, o, u, s, _, i));
- var w = Sh();
- return (
- (o.flags |= 1),
- 'object' == typeof _ &&
- null !== _ &&
- 'function' == typeof _.render &&
- void 0 === _.$$typeof
- ? ((o.tag = 1),
- (o.memoizedState = null),
- (o.updateQueue = null),
- Zf(u) ? ((w = !0), cg(o)) : (w = !1),
- (o.memoizedState = null !== _.state && void 0 !== _.state ? _.state : null),
- kh(o),
- (_.updater = ys),
- (o.stateNode = _),
- (_._reactInternals = o),
- Ii(o, u, s, i),
- (o = jj(null, o, u, !0, w, i)))
- : ((o.tag = 0), Fn && w && vg(o), Xi(null, o, _, i), (o = o.child)),
- o
- );
- case 16:
- u = o.elementType;
- e: {
- switch (
- (ij(s, o),
- (s = o.pendingProps),
- (u = (_ = u._init)(u._payload)),
- (o.type = u),
- (_ = o.tag =
- (function Zk(s) {
- if ('function' == typeof s) return aj(s) ? 1 : 0;
- if (null != s) {
- if ((s = s.$$typeof) === pe) return 11;
- if (s === ye) return 14;
- }
- return 2;
- })(u)),
- (s = Ci(u, s)),
- _)
- ) {
- case 0:
- o = cj(null, o, u, s, i);
- break e;
- case 1:
- o = hj(null, o, u, s, i);
- break e;
- case 11:
- o = Yi(null, o, u, s, i);
- break e;
- case 14:
- o = $i(null, o, u, Ci(u.type, s), i);
- break e;
- }
- throw Error(p(306, u, ''));
- }
- return o;
- case 0:
- return (
- (u = o.type),
- (_ = o.pendingProps),
- cj(s, o, u, (_ = o.elementType === u ? _ : Ci(u, _)), i)
- );
- case 1:
- return (
- (u = o.type),
- (_ = o.pendingProps),
- hj(s, o, u, (_ = o.elementType === u ? _ : Ci(u, _)), i)
- );
- case 3:
- e: {
- if ((kj(o), null === s)) throw Error(p(387));
- (u = o.pendingProps),
- (_ = (w = o.memoizedState).element),
- lh(s, o),
- qh(o, u, null, i);
- var x = o.memoizedState;
- if (((u = x.element), w.isDehydrated)) {
- if (
- ((w = {
- element: u,
- isDehydrated: !1,
- cache: x.cache,
- pendingSuspenseBoundaries: x.pendingSuspenseBoundaries,
- transitions: x.transitions
- }),
- (o.updateQueue.baseState = w),
- (o.memoizedState = w),
- 256 & o.flags)
- ) {
- o = lj(s, o, u, i, (_ = Ji(Error(p(423)), o)));
- break e;
- }
- if (u !== _) {
- o = lj(s, o, u, i, (_ = Ji(Error(p(424)), o)));
- break e;
- }
- for (
- Bn = Lf(o.stateNode.containerInfo.firstChild),
- Ln = o,
- Fn = !0,
- qn = null,
- i = Un(o, null, u, i),
- o.child = i;
- i;
- )
- (i.flags = (-3 & i.flags) | 4096), (i = i.sibling);
- } else {
- if ((Ig(), u === _)) {
- o = Zi(s, o, i);
- break e;
- }
- Xi(s, o, u, i);
- }
- o = o.child;
- }
- return o;
- case 5:
- return (
- Ah(o),
- null === s && Eg(o),
- (u = o.type),
- (_ = o.pendingProps),
- (w = null !== s ? s.memoizedProps : null),
- (x = _.children),
- Ef(u, _) ? (x = null) : null !== w && Ef(u, w) && (o.flags |= 32),
- gj(s, o),
- Xi(s, o, x, i),
- o.child
- );
- case 6:
- return null === s && Eg(o), null;
- case 13:
- return oj(s, o, i);
- case 4:
- return (
- yh(o, o.stateNode.containerInfo),
- (u = o.pendingProps),
- null === s ? (o.child = Vn(o, null, u, i)) : Xi(s, o, u, i),
- o.child
- );
- case 11:
- return (
- (u = o.type),
- (_ = o.pendingProps),
- Yi(s, o, u, (_ = o.elementType === u ? _ : Ci(u, _)), i)
- );
- case 7:
- return Xi(s, o, o.pendingProps, i), o.child;
- case 8:
- case 12:
- return Xi(s, o, o.pendingProps.children, i), o.child;
- case 10:
- e: {
- if (
- ((u = o.type._context),
- (_ = o.pendingProps),
- (w = o.memoizedProps),
- (x = _.value),
- G(zn, u._currentValue),
- (u._currentValue = x),
- null !== w)
- )
- if (Lr(w.value, x)) {
- if (w.children === _.children && !Sn.current) {
- o = Zi(s, o, i);
- break e;
- }
- } else
- for (null !== (w = o.child) && (w.return = o); null !== w; ) {
- var C = w.dependencies;
- if (null !== C) {
- x = w.child;
- for (var j = C.firstContext; null !== j; ) {
- if (j.context === u) {
- if (1 === w.tag) {
- (j = mh(-1, i & -i)).tag = 2;
- var L = w.updateQueue;
- if (null !== L) {
- var B = (L = L.shared).pending;
- null === B ? (j.next = j) : ((j.next = B.next), (B.next = j)),
- (L.pending = j);
- }
- }
- (w.lanes |= i),
- null !== (j = w.alternate) && (j.lanes |= i),
- bh(w.return, i, o),
- (C.lanes |= i);
- break;
- }
- j = j.next;
- }
- } else if (10 === w.tag) x = w.type === o.type ? null : w.child;
- else if (18 === w.tag) {
- if (null === (x = w.return)) throw Error(p(341));
- (x.lanes |= i),
- null !== (C = x.alternate) && (C.lanes |= i),
- bh(x, i, o),
- (x = w.sibling);
- } else x = w.child;
- if (null !== x) x.return = w;
- else
- for (x = w; null !== x; ) {
- if (x === o) {
- x = null;
- break;
- }
- if (null !== (w = x.sibling)) {
- (w.return = x.return), (x = w);
- break;
- }
- x = x.return;
- }
- w = x;
- }
- Xi(s, o, _.children, i), (o = o.child);
- }
- return o;
- case 9:
- return (
- (_ = o.type),
- (u = o.pendingProps.children),
- ch(o, i),
- (u = u((_ = eh(_)))),
- (o.flags |= 1),
- Xi(s, o, u, i),
- o.child
- );
- case 14:
- return (_ = Ci((u = o.type), o.pendingProps)), $i(s, o, u, (_ = Ci(u.type, _)), i);
- case 15:
- return bj(s, o, o.type, o.pendingProps, i);
- case 17:
- return (
- (u = o.type),
- (_ = o.pendingProps),
- (_ = o.elementType === u ? _ : Ci(u, _)),
- ij(s, o),
- (o.tag = 1),
- Zf(u) ? ((s = !0), cg(o)) : (s = !1),
- ch(o, i),
- Gi(o, u, _),
- Ii(o, u, _, i),
- jj(null, o, u, !0, s, i)
- );
- case 19:
- return xj(s, o, i);
- case 22:
- return dj(s, o, i);
- }
- throw Error(p(156, o.tag));
- };
- var uo =
- 'function' == typeof reportError
- ? reportError
- : function (s) {
- console.error(s);
- };
- function ll(s) {
- this._internalRoot = s;
- }
- function ml(s) {
- this._internalRoot = s;
- }
- function nl(s) {
- return !(!s || (1 !== s.nodeType && 9 !== s.nodeType && 11 !== s.nodeType));
- }
- function ol(s) {
- return !(
- !s ||
- (1 !== s.nodeType &&
- 9 !== s.nodeType &&
- 11 !== s.nodeType &&
- (8 !== s.nodeType || ' react-mount-point-unstable ' !== s.nodeValue))
- );
- }
- function pl() {}
- function rl(s, o, i, u, _) {
- var w = i._reactRootContainer;
- if (w) {
- var x = w;
- if ('function' == typeof _) {
- var C = _;
- _ = function () {
- var s = gl(x);
- C.call(s);
- };
- }
- fl(o, x, s, _);
- } else
- x = (function ql(s, o, i, u, _) {
- if (_) {
- if ('function' == typeof u) {
- var w = u;
- u = function () {
- var s = gl(x);
- w.call(s);
- };
- }
- var x = el(o, u, s, 0, null, !1, 0, '', pl);
- return (
- (s._reactRootContainer = x),
- (s[mn] = x.current),
- sf(8 === s.nodeType ? s.parentNode : s),
- Rk(),
- x
- );
- }
- for (; (_ = s.lastChild); ) s.removeChild(_);
- if ('function' == typeof u) {
- var C = u;
- u = function () {
- var s = gl(j);
- C.call(s);
- };
- }
- var j = bl(s, 0, !1, null, 0, !1, 0, '', pl);
- return (
- (s._reactRootContainer = j),
- (s[mn] = j.current),
- sf(8 === s.nodeType ? s.parentNode : s),
- Rk(function () {
- fl(o, j, i, u);
- }),
- j
- );
- })(i, o, s, _, u);
- return gl(x);
- }
- (ml.prototype.render = ll.prototype.render =
- function (s) {
- var o = this._internalRoot;
- if (null === o) throw Error(p(409));
- fl(s, o, null, null);
- }),
- (ml.prototype.unmount = ll.prototype.unmount =
- function () {
- var s = this._internalRoot;
- if (null !== s) {
- this._internalRoot = null;
- var o = s.containerInfo;
- Rk(function () {
- fl(null, s, null, null);
- }),
- (o[mn] = null);
- }
- }),
- (ml.prototype.unstable_scheduleHydration = function (s) {
- if (s) {
- var o = Mt();
- s = { blockedOn: null, target: s, priority: o };
- for (var i = 0; i < $t.length && 0 !== o && o < $t[i].priority; i++);
- $t.splice(i, 0, s), 0 === i && Vc(s);
- }
- }),
- (jt = function (s) {
- switch (s.tag) {
- case 3:
- var o = s.stateNode;
- if (o.current.memoizedState.isDehydrated) {
- var i = tc(o.pendingLanes);
- 0 !== i && (Cc(o, 1 | i), Dk(o, dt()), !(6 & Bs) && ((Zs = dt() + 500), jg()));
- }
- break;
- case 13:
- Rk(function () {
- var o = ih(s, 1);
- if (null !== o) {
- var i = R();
- gi(o, s, 1, i);
- }
- }),
- il(s, 1);
- }
- }),
- (It = function (s) {
- if (13 === s.tag) {
- var o = ih(s, 134217728);
- if (null !== o) gi(o, s, 134217728, R());
- il(s, 134217728);
- }
- }),
- (Pt = function (s) {
- if (13 === s.tag) {
- var o = yi(s),
- i = ih(s, o);
- if (null !== i) gi(i, s, o, R());
- il(s, o);
- }
- }),
- (Mt = function () {
- return At;
- }),
- (Tt = function (s, o) {
- var i = At;
- try {
- return (At = s), o();
- } finally {
- At = i;
- }
- }),
- (Xe = function (s, o, i) {
- switch (o) {
- case 'input':
- if ((bb(s, i), (o = i.name), 'radio' === i.type && null != o)) {
- for (i = s; i.parentNode; ) i = i.parentNode;
- for (
- i = i.querySelectorAll(
- 'input[name=' + JSON.stringify('' + o) + '][type="radio"]'
- ),
- o = 0;
- o < i.length;
- o++
- ) {
- var u = i[o];
- if (u !== s && u.form === s.form) {
- var _ = Db(u);
- if (!_) throw Error(p(90));
- Wa(u), bb(u, _);
- }
- }
- }
- break;
- case 'textarea':
- ib(s, i);
- break;
- case 'select':
- null != (o = i.value) && fb(s, !!i.multiple, o, !1);
- }
- }),
- (Gb = Qk),
- (Hb = Rk);
- var po = { usingClientEntryPoint: !1, Events: [Cb, ue, Db, Eb, Fb, Qk] },
- ho = {
- findFiberByHostInstance: Wc,
- bundleType: 0,
- version: '18.3.1',
- rendererPackageName: 'react-dom'
- },
- fo = {
- bundleType: ho.bundleType,
- version: ho.version,
- rendererPackageName: ho.rendererPackageName,
- rendererConfig: ho.rendererConfig,
- overrideHookState: null,
- overrideHookStateDeletePath: null,
- overrideHookStateRenamePath: null,
- overrideProps: null,
- overridePropsDeletePath: null,
- overridePropsRenamePath: null,
- setErrorHandler: null,
- setSuspenseHandler: null,
- scheduleUpdate: null,
- currentDispatcherRef: z.ReactCurrentDispatcher,
- findHostInstanceByFiber: function (s) {
- return null === (s = Zb(s)) ? null : s.stateNode;
- },
- findFiberByHostInstance:
- ho.findFiberByHostInstance ||
- function jl() {
- return null;
- },
- findHostInstancesForRefresh: null,
- scheduleRefresh: null,
- scheduleRoot: null,
- setRefreshHandler: null,
- getCurrentFiber: null,
- reconcilerVersion: '18.3.1-next-f1338f8080-20240426'
- };
- if ('undefined' != typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
- var mo = __REACT_DEVTOOLS_GLOBAL_HOOK__;
- if (!mo.isDisabled && mo.supportsFiber)
- try {
- (Et = mo.inject(fo)), (wt = mo);
- } catch (qe) {}
- }
- (o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = po),
- (o.createPortal = function (s, o) {
- var i = 2 < arguments.length && void 0 !== arguments[2] ? arguments[2] : null;
- if (!nl(o)) throw Error(p(200));
- return (function cl(s, o, i) {
- var u = 3 < arguments.length && void 0 !== arguments[3] ? arguments[3] : null;
- return {
- $$typeof: Z,
- key: null == u ? null : '' + u,
- children: s,
- containerInfo: o,
- implementation: i
- };
- })(s, o, null, i);
- }),
- (o.createRoot = function (s, o) {
- if (!nl(s)) throw Error(p(299));
- var i = !1,
- u = '',
- _ = uo;
- return (
- null != o &&
- (!0 === o.unstable_strictMode && (i = !0),
- void 0 !== o.identifierPrefix && (u = o.identifierPrefix),
- void 0 !== o.onRecoverableError && (_ = o.onRecoverableError)),
- (o = bl(s, 1, !1, null, 0, i, 0, u, _)),
- (s[mn] = o.current),
- sf(8 === s.nodeType ? s.parentNode : s),
- new ll(o)
- );
- }),
- (o.findDOMNode = function (s) {
- if (null == s) return null;
- if (1 === s.nodeType) return s;
- var o = s._reactInternals;
- if (void 0 === o) {
- if ('function' == typeof s.render) throw Error(p(188));
- throw ((s = Object.keys(s).join(',')), Error(p(268, s)));
- }
- return (s = null === (s = Zb(o)) ? null : s.stateNode);
- }),
- (o.flushSync = function (s) {
- return Rk(s);
- }),
- (o.hydrate = function (s, o, i) {
- if (!ol(o)) throw Error(p(200));
- return rl(null, s, o, !0, i);
- }),
- (o.hydrateRoot = function (s, o, i) {
- if (!nl(s)) throw Error(p(405));
- var u = (null != i && i.hydratedSources) || null,
- _ = !1,
- w = '',
- x = uo;
- if (
- (null != i &&
- (!0 === i.unstable_strictMode && (_ = !0),
- void 0 !== i.identifierPrefix && (w = i.identifierPrefix),
- void 0 !== i.onRecoverableError && (x = i.onRecoverableError)),
- (o = el(o, null, s, 1, null != i ? i : null, _, 0, w, x)),
- (s[mn] = o.current),
- sf(s),
- u)
- )
- for (s = 0; s < u.length; s++)
- (_ = (_ = (i = u[s])._getVersion)(i._source)),
- null == o.mutableSourceEagerHydrationData
- ? (o.mutableSourceEagerHydrationData = [i, _])
- : o.mutableSourceEagerHydrationData.push(i, _);
- return new ml(o);
- }),
- (o.render = function (s, o, i) {
- if (!ol(o)) throw Error(p(200));
- return rl(null, s, o, !1, i);
- }),
- (o.unmountComponentAtNode = function (s) {
- if (!ol(s)) throw Error(p(40));
- return (
- !!s._reactRootContainer &&
- (Rk(function () {
- rl(null, null, s, !1, function () {
- (s._reactRootContainer = null), (s[mn] = null);
- });
- }),
- !0)
- );
- }),
- (o.unstable_batchedUpdates = Qk),
- (o.unstable_renderSubtreeIntoContainer = function (s, o, i, u) {
- if (!ol(i)) throw Error(p(200));
- if (null == s || void 0 === s._reactInternals) throw Error(p(38));
- return rl(s, o, i, !1, u);
- }),
- (o.version = '18.3.1-next-f1338f8080-20240426');
- },
- 40961: (s, o, i) => {
- 'use strict';
- !(function checkDCE() {
- if (
- 'undefined' != typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
- 'function' == typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE
- )
- try {
- __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(checkDCE);
- } catch (s) {
- console.error(s);
- }
- })(),
- (s.exports = i(22551));
- },
- 2209: (s, o, i) => {
- 'use strict';
- var u,
- _ = i(9404),
- w = function productionTypeChecker() {
- invariant(!1, 'ImmutablePropTypes type checking code is stripped in production.');
- };
- w.isRequired = w;
- var x = function getProductionTypeChecker() {
- return w;
- };
- function getPropType(s) {
- var o = typeof s;
- return Array.isArray(s)
- ? 'array'
- : s instanceof RegExp
- ? 'object'
- : s instanceof _.Iterable
- ? 'Immutable.' + s.toSource().split(' ')[0]
- : o;
- }
- function createChainableTypeChecker(s) {
- function checkType(o, i, u, _, w, x) {
- for (var C = arguments.length, j = Array(C > 6 ? C - 6 : 0), L = 6; L < C; L++)
- j[L - 6] = arguments[L];
- return (
- (x = x || u),
- (_ = _ || '<<anonymous>>'),
- null != i[u]
- ? s.apply(void 0, [i, u, _, w, x].concat(j))
- : o
- ? new Error('Required ' + w + ' `' + x + '` was not specified in `' + _ + '`.')
- : void 0
- );
- }
- var o = checkType.bind(null, !1);
- return (o.isRequired = checkType.bind(null, !0)), o;
- }
- function createIterableSubclassTypeChecker(s, o) {
- return (function createImmutableTypeChecker(s, o) {
- return createChainableTypeChecker(function validate(i, u, _, w, x) {
- var C = i[u];
- if (!o(C)) {
- var j = getPropType(C);
- return new Error(
- 'Invalid ' +
- w +
- ' `' +
- x +
- '` of type `' +
- j +
- '` supplied to `' +
- _ +
- '`, expected `' +
- s +
- '`.'
- );
- }
- return null;
- });
- })('Iterable.' + s, function (s) {
- return _.Iterable.isIterable(s) && o(s);
- });
- }
- ((u = {
- listOf: x,
- mapOf: x,
- orderedMapOf: x,
- setOf: x,
- orderedSetOf: x,
- stackOf: x,
- iterableOf: x,
- recordOf: x,
- shape: x,
- contains: x,
- mapContains: x,
- orderedMapContains: x,
- list: w,
- map: w,
- orderedMap: w,
- set: w,
- orderedSet: w,
- stack: w,
- seq: w,
- record: w,
- iterable: w
- }).iterable.indexed = createIterableSubclassTypeChecker('Indexed', _.Iterable.isIndexed)),
- (u.iterable.keyed = createIterableSubclassTypeChecker('Keyed', _.Iterable.isKeyed)),
- (s.exports = u);
- },
- 15287: (s, o) => {
- 'use strict';
- var i = Symbol.for('react.element'),
- u = Symbol.for('react.portal'),
- _ = Symbol.for('react.fragment'),
- w = Symbol.for('react.strict_mode'),
- x = Symbol.for('react.profiler'),
- C = Symbol.for('react.provider'),
- j = Symbol.for('react.context'),
- L = Symbol.for('react.forward_ref'),
- B = Symbol.for('react.suspense'),
- $ = Symbol.for('react.memo'),
- V = Symbol.for('react.lazy'),
- U = Symbol.iterator;
- var z = {
- isMounted: function () {
- return !1;
- },
- enqueueForceUpdate: function () {},
- enqueueReplaceState: function () {},
- enqueueSetState: function () {}
- },
- Y = Object.assign,
- Z = {};
- function E(s, o, i) {
- (this.props = s), (this.context = o), (this.refs = Z), (this.updater = i || z);
- }
- function F() {}
- function G(s, o, i) {
- (this.props = s), (this.context = o), (this.refs = Z), (this.updater = i || z);
- }
- (E.prototype.isReactComponent = {}),
- (E.prototype.setState = function (s, o) {
- if ('object' != typeof s && 'function' != typeof s && null != s)
- throw Error(
- 'setState(...): takes an object of state variables to update or a function which returns an object of state variables.'
- );
- this.updater.enqueueSetState(this, s, o, 'setState');
- }),
- (E.prototype.forceUpdate = function (s) {
- this.updater.enqueueForceUpdate(this, s, 'forceUpdate');
- }),
- (F.prototype = E.prototype);
- var ee = (G.prototype = new F());
- (ee.constructor = G), Y(ee, E.prototype), (ee.isPureReactComponent = !0);
- var ie = Array.isArray,
- ae = Object.prototype.hasOwnProperty,
- le = { current: null },
- ce = { key: !0, ref: !0, __self: !0, __source: !0 };
- function M(s, o, u) {
- var _,
- w = {},
- x = null,
- C = null;
- if (null != o)
- for (_ in (void 0 !== o.ref && (C = o.ref), void 0 !== o.key && (x = '' + o.key), o))
- ae.call(o, _) && !ce.hasOwnProperty(_) && (w[_] = o[_]);
- var j = arguments.length - 2;
- if (1 === j) w.children = u;
- else if (1 < j) {
- for (var L = Array(j), B = 0; B < j; B++) L[B] = arguments[B + 2];
- w.children = L;
- }
- if (s && s.defaultProps)
- for (_ in (j = s.defaultProps)) void 0 === w[_] && (w[_] = j[_]);
- return { $$typeof: i, type: s, key: x, ref: C, props: w, _owner: le.current };
- }
- function O(s) {
- return 'object' == typeof s && null !== s && s.$$typeof === i;
- }
- var pe = /\/+/g;
- function Q(s, o) {
- return 'object' == typeof s && null !== s && null != s.key
- ? (function escape(s) {
- var o = { '=': '=0', ':': '=2' };
- return (
- '$' +
- s.replace(/[=:]/g, function (s) {
- return o[s];
- })
- );
- })('' + s.key)
- : o.toString(36);
- }
- function R(s, o, _, w, x) {
- var C = typeof s;
- ('undefined' !== C && 'boolean' !== C) || (s = null);
- var j = !1;
- if (null === s) j = !0;
- else
- switch (C) {
- case 'string':
- case 'number':
- j = !0;
- break;
- case 'object':
- switch (s.$$typeof) {
- case i:
- case u:
- j = !0;
- }
- }
- if (j)
- return (
- (x = x((j = s))),
- (s = '' === w ? '.' + Q(j, 0) : w),
- ie(x)
- ? ((_ = ''),
- null != s && (_ = s.replace(pe, '$&/') + '/'),
- R(x, o, _, '', function (s) {
- return s;
- }))
- : null != x &&
- (O(x) &&
- (x = (function N(s, o) {
- return {
- $$typeof: i,
- type: s.type,
- key: o,
- ref: s.ref,
- props: s.props,
- _owner: s._owner
- };
- })(
- x,
- _ +
- (!x.key || (j && j.key === x.key)
- ? ''
- : ('' + x.key).replace(pe, '$&/') + '/') +
- s
- )),
- o.push(x)),
- 1
- );
- if (((j = 0), (w = '' === w ? '.' : w + ':'), ie(s)))
- for (var L = 0; L < s.length; L++) {
- var B = w + Q((C = s[L]), L);
- j += R(C, o, _, B, x);
- }
- else if (
- ((B = (function A(s) {
- return null === s || 'object' != typeof s
- ? null
- : 'function' == typeof (s = (U && s[U]) || s['@@iterator'])
- ? s
- : null;
- })(s)),
- 'function' == typeof B)
- )
- for (s = B.call(s), L = 0; !(C = s.next()).done; )
- j += R((C = C.value), o, _, (B = w + Q(C, L++)), x);
- else if ('object' === C)
- throw (
- ((o = String(s)),
- Error(
- 'Objects are not valid as a React child (found: ' +
- ('[object Object]' === o
- ? 'object with keys {' + Object.keys(s).join(', ') + '}'
- : o) +
- '). If you meant to render a collection of children, use an array instead.'
- ))
- );
- return j;
- }
- function S(s, o, i) {
- if (null == s) return s;
- var u = [],
- _ = 0;
- return (
- R(s, u, '', '', function (s) {
- return o.call(i, s, _++);
- }),
- u
- );
- }
- function T(s) {
- if (-1 === s._status) {
- var o = s._result;
- (o = o()).then(
- function (o) {
- (0 !== s._status && -1 !== s._status) || ((s._status = 1), (s._result = o));
- },
- function (o) {
- (0 !== s._status && -1 !== s._status) || ((s._status = 2), (s._result = o));
- }
- ),
- -1 === s._status && ((s._status = 0), (s._result = o));
- }
- if (1 === s._status) return s._result.default;
- throw s._result;
- }
- var de = { current: null },
- fe = { transition: null },
- ye = { ReactCurrentDispatcher: de, ReactCurrentBatchConfig: fe, ReactCurrentOwner: le };
- function X() {
- throw Error('act(...) is not supported in production builds of React.');
- }
- (o.Children = {
- map: S,
- forEach: function (s, o, i) {
- S(
- s,
- function () {
- o.apply(this, arguments);
- },
- i
- );
- },
- count: function (s) {
- var o = 0;
- return (
- S(s, function () {
- o++;
- }),
- o
- );
- },
- toArray: function (s) {
- return (
- S(s, function (s) {
- return s;
- }) || []
- );
- },
- only: function (s) {
- if (!O(s))
- throw Error(
- 'React.Children.only expected to receive a single React element child.'
- );
- return s;
- }
- }),
- (o.Component = E),
- (o.Fragment = _),
- (o.Profiler = x),
- (o.PureComponent = G),
- (o.StrictMode = w),
- (o.Suspense = B),
- (o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = ye),
- (o.act = X),
- (o.cloneElement = function (s, o, u) {
- if (null == s)
- throw Error(
- 'React.cloneElement(...): The argument must be a React element, but you passed ' +
- s +
- '.'
- );
- var _ = Y({}, s.props),
- w = s.key,
- x = s.ref,
- C = s._owner;
- if (null != o) {
- if (
- (void 0 !== o.ref && ((x = o.ref), (C = le.current)),
- void 0 !== o.key && (w = '' + o.key),
- s.type && s.type.defaultProps)
- )
- var j = s.type.defaultProps;
- for (L in o)
- ae.call(o, L) &&
- !ce.hasOwnProperty(L) &&
- (_[L] = void 0 === o[L] && void 0 !== j ? j[L] : o[L]);
- }
- var L = arguments.length - 2;
- if (1 === L) _.children = u;
- else if (1 < L) {
- j = Array(L);
- for (var B = 0; B < L; B++) j[B] = arguments[B + 2];
- _.children = j;
- }
- return { $$typeof: i, type: s.type, key: w, ref: x, props: _, _owner: C };
- }),
- (o.createContext = function (s) {
- return (
- ((s = {
- $$typeof: j,
- _currentValue: s,
- _currentValue2: s,
- _threadCount: 0,
- Provider: null,
- Consumer: null,
- _defaultValue: null,
- _globalName: null
- }).Provider = { $$typeof: C, _context: s }),
- (s.Consumer = s)
- );
- }),
- (o.createElement = M),
- (o.createFactory = function (s) {
- var o = M.bind(null, s);
- return (o.type = s), o;
- }),
- (o.createRef = function () {
- return { current: null };
- }),
- (o.forwardRef = function (s) {
- return { $$typeof: L, render: s };
- }),
- (o.isValidElement = O),
- (o.lazy = function (s) {
- return { $$typeof: V, _payload: { _status: -1, _result: s }, _init: T };
- }),
- (o.memo = function (s, o) {
- return { $$typeof: $, type: s, compare: void 0 === o ? null : o };
- }),
- (o.startTransition = function (s) {
- var o = fe.transition;
- fe.transition = {};
- try {
- s();
- } finally {
- fe.transition = o;
- }
- }),
- (o.unstable_act = X),
- (o.useCallback = function (s, o) {
- return de.current.useCallback(s, o);
- }),
- (o.useContext = function (s) {
- return de.current.useContext(s);
- }),
- (o.useDebugValue = function () {}),
- (o.useDeferredValue = function (s) {
- return de.current.useDeferredValue(s);
- }),
- (o.useEffect = function (s, o) {
- return de.current.useEffect(s, o);
- }),
- (o.useId = function () {
- return de.current.useId();
- }),
- (o.useImperativeHandle = function (s, o, i) {
- return de.current.useImperativeHandle(s, o, i);
- }),
- (o.useInsertionEffect = function (s, o) {
- return de.current.useInsertionEffect(s, o);
- }),
- (o.useLayoutEffect = function (s, o) {
- return de.current.useLayoutEffect(s, o);
- }),
- (o.useMemo = function (s, o) {
- return de.current.useMemo(s, o);
- }),
- (o.useReducer = function (s, o, i) {
- return de.current.useReducer(s, o, i);
- }),
- (o.useRef = function (s) {
- return de.current.useRef(s);
- }),
- (o.useState = function (s) {
- return de.current.useState(s);
- }),
- (o.useSyncExternalStore = function (s, o, i) {
- return de.current.useSyncExternalStore(s, o, i);
- }),
- (o.useTransition = function () {
- return de.current.useTransition();
- }),
- (o.version = '18.3.1');
- },
- 96540: (s, o, i) => {
- 'use strict';
- s.exports = i(15287);
- },
- 86048: (s) => {
- 'use strict';
- var o = {};
- function createErrorType(s, i, u) {
- u || (u = Error);
- var _ = (function (s) {
- function NodeError(o, u, _) {
- return (
- s.call(
- this,
- (function getMessage(s, o, u) {
- return 'string' == typeof i ? i : i(s, o, u);
- })(o, u, _)
- ) || this
- );
- }
- return (
- (function _inheritsLoose(s, o) {
- (s.prototype = Object.create(o.prototype)),
- (s.prototype.constructor = s),
- (s.__proto__ = o);
- })(NodeError, s),
- NodeError
- );
- })(u);
- (_.prototype.name = u.name), (_.prototype.code = s), (o[s] = _);
- }
- function oneOf(s, o) {
- if (Array.isArray(s)) {
- var i = s.length;
- return (
- (s = s.map(function (s) {
- return String(s);
- })),
- i > 2
- ? 'one of '.concat(o, ' ').concat(s.slice(0, i - 1).join(', '), ', or ') +
- s[i - 1]
- : 2 === i
- ? 'one of '.concat(o, ' ').concat(s[0], ' or ').concat(s[1])
- : 'of '.concat(o, ' ').concat(s[0])
- );
- }
- return 'of '.concat(o, ' ').concat(String(s));
- }
- createErrorType(
- 'ERR_INVALID_OPT_VALUE',
- function (s, o) {
- return 'The value "' + o + '" is invalid for option "' + s + '"';
- },
- TypeError
- ),
- createErrorType(
- 'ERR_INVALID_ARG_TYPE',
- function (s, o, i) {
- var u, _;
- if (
- ('string' == typeof o &&
- (function startsWith(s, o, i) {
- return s.substr(!i || i < 0 ? 0 : +i, o.length) === o;
- })(o, 'not ')
- ? ((u = 'must not be'), (o = o.replace(/^not /, '')))
- : (u = 'must be'),
- (function endsWith(s, o, i) {
- return (
- (void 0 === i || i > s.length) && (i = s.length),
- s.substring(i - o.length, i) === o
- );
- })(s, ' argument'))
- )
- _ = 'The '.concat(s, ' ').concat(u, ' ').concat(oneOf(o, 'type'));
- else {
- var w = (function includes(s, o, i) {
- return (
- 'number' != typeof i && (i = 0),
- !(i + o.length > s.length) && -1 !== s.indexOf(o, i)
- );
- })(s, '.')
- ? 'property'
- : 'argument';
- _ = 'The "'
- .concat(s, '" ')
- .concat(w, ' ')
- .concat(u, ' ')
- .concat(oneOf(o, 'type'));
- }
- return (_ += '. Received type '.concat(typeof i));
- },
- TypeError
- ),
- createErrorType('ERR_STREAM_PUSH_AFTER_EOF', 'stream.push() after EOF'),
- createErrorType('ERR_METHOD_NOT_IMPLEMENTED', function (s) {
- return 'The ' + s + ' method is not implemented';
- }),
- createErrorType('ERR_STREAM_PREMATURE_CLOSE', 'Premature close'),
- createErrorType('ERR_STREAM_DESTROYED', function (s) {
- return 'Cannot call ' + s + ' after a stream was destroyed';
- }),
- createErrorType('ERR_MULTIPLE_CALLBACK', 'Callback called multiple times'),
- createErrorType('ERR_STREAM_CANNOT_PIPE', 'Cannot pipe, not readable'),
- createErrorType('ERR_STREAM_WRITE_AFTER_END', 'write after end'),
- createErrorType(
- 'ERR_STREAM_NULL_VALUES',
- 'May not write null values to stream',
- TypeError
- ),
- createErrorType(
- 'ERR_UNKNOWN_ENCODING',
- function (s) {
- return 'Unknown encoding: ' + s;
- },
- TypeError
- ),
- createErrorType(
- 'ERR_STREAM_UNSHIFT_AFTER_END_EVENT',
- 'stream.unshift() after end event'
- ),
- (s.exports.F = o);
- },
- 25382: (s, o, i) => {
- 'use strict';
- var u = i(65606),
- _ =
- Object.keys ||
- function (s) {
- var o = [];
- for (var i in s) o.push(i);
- return o;
- };
- s.exports = Duplex;
- var w = i(45412),
- x = i(16708);
- i(56698)(Duplex, w);
- for (var C = _(x.prototype), j = 0; j < C.length; j++) {
- var L = C[j];
- Duplex.prototype[L] || (Duplex.prototype[L] = x.prototype[L]);
- }
- function Duplex(s) {
- if (!(this instanceof Duplex)) return new Duplex(s);
- w.call(this, s),
- x.call(this, s),
- (this.allowHalfOpen = !0),
- s &&
- (!1 === s.readable && (this.readable = !1),
- !1 === s.writable && (this.writable = !1),
- !1 === s.allowHalfOpen && ((this.allowHalfOpen = !1), this.once('end', onend)));
- }
- function onend() {
- this._writableState.ended || u.nextTick(onEndNT, this);
- }
- function onEndNT(s) {
- s.end();
- }
- Object.defineProperty(Duplex.prototype, 'writableHighWaterMark', {
- enumerable: !1,
- get: function get() {
- return this._writableState.highWaterMark;
- }
- }),
- Object.defineProperty(Duplex.prototype, 'writableBuffer', {
- enumerable: !1,
- get: function get() {
- return this._writableState && this._writableState.getBuffer();
- }
- }),
- Object.defineProperty(Duplex.prototype, 'writableLength', {
- enumerable: !1,
- get: function get() {
- return this._writableState.length;
- }
- }),
- Object.defineProperty(Duplex.prototype, 'destroyed', {
- enumerable: !1,
- get: function get() {
- return (
- void 0 !== this._readableState &&
- void 0 !== this._writableState &&
- this._readableState.destroyed &&
- this._writableState.destroyed
- );
- },
- set: function set(s) {
- void 0 !== this._readableState &&
- void 0 !== this._writableState &&
- ((this._readableState.destroyed = s), (this._writableState.destroyed = s));
- }
- });
- },
- 63600: (s, o, i) => {
- 'use strict';
- s.exports = PassThrough;
- var u = i(74610);
- function PassThrough(s) {
- if (!(this instanceof PassThrough)) return new PassThrough(s);
- u.call(this, s);
- }
- i(56698)(PassThrough, u),
- (PassThrough.prototype._transform = function (s, o, i) {
- i(null, s);
- });
- },
- 45412: (s, o, i) => {
- 'use strict';
- var u,
- _ = i(65606);
- (s.exports = Readable), (Readable.ReadableState = ReadableState);
- i(37007).EventEmitter;
- var w = function EElistenerCount(s, o) {
- return s.listeners(o).length;
- },
- x = i(40345),
- C = i(48287).Buffer,
- j =
- (void 0 !== i.g
- ? i.g
- : 'undefined' != typeof window
- ? window
- : 'undefined' != typeof self
- ? self
- : {}
- ).Uint8Array || function () {};
- var L,
- B = i(79838);
- L = B && B.debuglog ? B.debuglog('stream') : function debug() {};
- var $,
- V,
- U,
- z = i(80345),
- Y = i(75896),
- Z = i(65291).getHighWaterMark,
- ee = i(86048).F,
- ie = ee.ERR_INVALID_ARG_TYPE,
- ae = ee.ERR_STREAM_PUSH_AFTER_EOF,
- le = ee.ERR_METHOD_NOT_IMPLEMENTED,
- ce = ee.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;
- i(56698)(Readable, x);
- var pe = Y.errorOrDestroy,
- de = ['error', 'close', 'destroy', 'pause', 'resume'];
- function ReadableState(s, o, _) {
- (u = u || i(25382)),
- (s = s || {}),
- 'boolean' != typeof _ && (_ = o instanceof u),
- (this.objectMode = !!s.objectMode),
- _ && (this.objectMode = this.objectMode || !!s.readableObjectMode),
- (this.highWaterMark = Z(this, s, 'readableHighWaterMark', _)),
- (this.buffer = new z()),
- (this.length = 0),
- (this.pipes = null),
- (this.pipesCount = 0),
- (this.flowing = null),
- (this.ended = !1),
- (this.endEmitted = !1),
- (this.reading = !1),
- (this.sync = !0),
- (this.needReadable = !1),
- (this.emittedReadable = !1),
- (this.readableListening = !1),
- (this.resumeScheduled = !1),
- (this.paused = !0),
- (this.emitClose = !1 !== s.emitClose),
- (this.autoDestroy = !!s.autoDestroy),
- (this.destroyed = !1),
- (this.defaultEncoding = s.defaultEncoding || 'utf8'),
- (this.awaitDrain = 0),
- (this.readingMore = !1),
- (this.decoder = null),
- (this.encoding = null),
- s.encoding &&
- ($ || ($ = i(83141).I),
- (this.decoder = new $(s.encoding)),
- (this.encoding = s.encoding));
- }
- function Readable(s) {
- if (((u = u || i(25382)), !(this instanceof Readable))) return new Readable(s);
- var o = this instanceof u;
- (this._readableState = new ReadableState(s, this, o)),
- (this.readable = !0),
- s &&
- ('function' == typeof s.read && (this._read = s.read),
- 'function' == typeof s.destroy && (this._destroy = s.destroy)),
- x.call(this);
- }
- function readableAddChunk(s, o, i, u, _) {
- L('readableAddChunk', o);
- var w,
- x = s._readableState;
- if (null === o)
- (x.reading = !1),
- (function onEofChunk(s, o) {
- if ((L('onEofChunk'), o.ended)) return;
- if (o.decoder) {
- var i = o.decoder.end();
- i && i.length && (o.buffer.push(i), (o.length += o.objectMode ? 1 : i.length));
- }
- (o.ended = !0),
- o.sync
- ? emitReadable(s)
- : ((o.needReadable = !1),
- o.emittedReadable || ((o.emittedReadable = !0), emitReadable_(s)));
- })(s, x);
- else if (
- (_ ||
- (w = (function chunkInvalid(s, o) {
- var i;
- (function _isUint8Array(s) {
- return C.isBuffer(s) || s instanceof j;
- })(o) ||
- 'string' == typeof o ||
- void 0 === o ||
- s.objectMode ||
- (i = new ie('chunk', ['string', 'Buffer', 'Uint8Array'], o));
- return i;
- })(x, o)),
- w)
- )
- pe(s, w);
- else if (x.objectMode || (o && o.length > 0))
- if (
- ('string' == typeof o ||
- x.objectMode ||
- Object.getPrototypeOf(o) === C.prototype ||
- (o = (function _uint8ArrayToBuffer(s) {
- return C.from(s);
- })(o)),
- u)
- )
- x.endEmitted ? pe(s, new ce()) : addChunk(s, x, o, !0);
- else if (x.ended) pe(s, new ae());
- else {
- if (x.destroyed) return !1;
- (x.reading = !1),
- x.decoder && !i
- ? ((o = x.decoder.write(o)),
- x.objectMode || 0 !== o.length ? addChunk(s, x, o, !1) : maybeReadMore(s, x))
- : addChunk(s, x, o, !1);
- }
- else u || ((x.reading = !1), maybeReadMore(s, x));
- return !x.ended && (x.length < x.highWaterMark || 0 === x.length);
- }
- function addChunk(s, o, i, u) {
- o.flowing && 0 === o.length && !o.sync
- ? ((o.awaitDrain = 0), s.emit('data', i))
- : ((o.length += o.objectMode ? 1 : i.length),
- u ? o.buffer.unshift(i) : o.buffer.push(i),
- o.needReadable && emitReadable(s)),
- maybeReadMore(s, o);
- }
- Object.defineProperty(Readable.prototype, 'destroyed', {
- enumerable: !1,
- get: function get() {
- return void 0 !== this._readableState && this._readableState.destroyed;
- },
- set: function set(s) {
- this._readableState && (this._readableState.destroyed = s);
- }
- }),
- (Readable.prototype.destroy = Y.destroy),
- (Readable.prototype._undestroy = Y.undestroy),
- (Readable.prototype._destroy = function (s, o) {
- o(s);
- }),
- (Readable.prototype.push = function (s, o) {
- var i,
- u = this._readableState;
- return (
- u.objectMode
- ? (i = !0)
- : 'string' == typeof s &&
- ((o = o || u.defaultEncoding) !== u.encoding && ((s = C.from(s, o)), (o = '')),
- (i = !0)),
- readableAddChunk(this, s, o, !1, i)
- );
- }),
- (Readable.prototype.unshift = function (s) {
- return readableAddChunk(this, s, null, !0, !1);
- }),
- (Readable.prototype.isPaused = function () {
- return !1 === this._readableState.flowing;
- }),
- (Readable.prototype.setEncoding = function (s) {
- $ || ($ = i(83141).I);
- var o = new $(s);
- (this._readableState.decoder = o),
- (this._readableState.encoding = this._readableState.decoder.encoding);
- for (var u = this._readableState.buffer.head, _ = ''; null !== u; )
- (_ += o.write(u.data)), (u = u.next);
- return (
- this._readableState.buffer.clear(),
- '' !== _ && this._readableState.buffer.push(_),
- (this._readableState.length = _.length),
- this
- );
- });
- var fe = 1073741824;
- function howMuchToRead(s, o) {
- return s <= 0 || (0 === o.length && o.ended)
- ? 0
- : o.objectMode
- ? 1
- : s != s
- ? o.flowing && o.length
- ? o.buffer.head.data.length
- : o.length
- : (s > o.highWaterMark &&
- (o.highWaterMark = (function computeNewHighWaterMark(s) {
- return (
- s >= fe
- ? (s = fe)
- : (s--,
- (s |= s >>> 1),
- (s |= s >>> 2),
- (s |= s >>> 4),
- (s |= s >>> 8),
- (s |= s >>> 16),
- s++),
- s
- );
- })(s)),
- s <= o.length ? s : o.ended ? o.length : ((o.needReadable = !0), 0));
- }
- function emitReadable(s) {
- var o = s._readableState;
- L('emitReadable', o.needReadable, o.emittedReadable),
- (o.needReadable = !1),
- o.emittedReadable ||
- (L('emitReadable', o.flowing),
- (o.emittedReadable = !0),
- _.nextTick(emitReadable_, s));
- }
- function emitReadable_(s) {
- var o = s._readableState;
- L('emitReadable_', o.destroyed, o.length, o.ended),
- o.destroyed ||
- (!o.length && !o.ended) ||
- (s.emit('readable'), (o.emittedReadable = !1)),
- (o.needReadable = !o.flowing && !o.ended && o.length <= o.highWaterMark),
- flow(s);
- }
- function maybeReadMore(s, o) {
- o.readingMore || ((o.readingMore = !0), _.nextTick(maybeReadMore_, s, o));
- }
- function maybeReadMore_(s, o) {
- for (
- ;
- !o.reading &&
- !o.ended &&
- (o.length < o.highWaterMark || (o.flowing && 0 === o.length));
- ) {
- var i = o.length;
- if ((L('maybeReadMore read 0'), s.read(0), i === o.length)) break;
- }
- o.readingMore = !1;
- }
- function updateReadableListening(s) {
- var o = s._readableState;
- (o.readableListening = s.listenerCount('readable') > 0),
- o.resumeScheduled && !o.paused
- ? (o.flowing = !0)
- : s.listenerCount('data') > 0 && s.resume();
- }
- function nReadingNextTick(s) {
- L('readable nexttick read 0'), s.read(0);
- }
- function resume_(s, o) {
- L('resume', o.reading),
- o.reading || s.read(0),
- (o.resumeScheduled = !1),
- s.emit('resume'),
- flow(s),
- o.flowing && !o.reading && s.read(0);
- }
- function flow(s) {
- var o = s._readableState;
- for (L('flow', o.flowing); o.flowing && null !== s.read(); );
- }
- function fromList(s, o) {
- return 0 === o.length
- ? null
- : (o.objectMode
- ? (i = o.buffer.shift())
- : !s || s >= o.length
- ? ((i = o.decoder
- ? o.buffer.join('')
- : 1 === o.buffer.length
- ? o.buffer.first()
- : o.buffer.concat(o.length)),
- o.buffer.clear())
- : (i = o.buffer.consume(s, o.decoder)),
- i);
- var i;
- }
- function endReadable(s) {
- var o = s._readableState;
- L('endReadable', o.endEmitted),
- o.endEmitted || ((o.ended = !0), _.nextTick(endReadableNT, o, s));
- }
- function endReadableNT(s, o) {
- if (
- (L('endReadableNT', s.endEmitted, s.length),
- !s.endEmitted &&
- 0 === s.length &&
- ((s.endEmitted = !0), (o.readable = !1), o.emit('end'), s.autoDestroy))
- ) {
- var i = o._writableState;
- (!i || (i.autoDestroy && i.finished)) && o.destroy();
- }
- }
- function indexOf(s, o) {
- for (var i = 0, u = s.length; i < u; i++) if (s[i] === o) return i;
- return -1;
- }
- (Readable.prototype.read = function (s) {
- L('read', s), (s = parseInt(s, 10));
- var o = this._readableState,
- i = s;
- if (
- (0 !== s && (o.emittedReadable = !1),
- 0 === s &&
- o.needReadable &&
- ((0 !== o.highWaterMark ? o.length >= o.highWaterMark : o.length > 0) || o.ended))
- )
- return (
- L('read: emitReadable', o.length, o.ended),
- 0 === o.length && o.ended ? endReadable(this) : emitReadable(this),
- null
- );
- if (0 === (s = howMuchToRead(s, o)) && o.ended)
- return 0 === o.length && endReadable(this), null;
- var u,
- _ = o.needReadable;
- return (
- L('need readable', _),
- (0 === o.length || o.length - s < o.highWaterMark) &&
- L('length less than watermark', (_ = !0)),
- o.ended || o.reading
- ? L('reading or ended', (_ = !1))
- : _ &&
- (L('do read'),
- (o.reading = !0),
- (o.sync = !0),
- 0 === o.length && (o.needReadable = !0),
- this._read(o.highWaterMark),
- (o.sync = !1),
- o.reading || (s = howMuchToRead(i, o))),
- null === (u = s > 0 ? fromList(s, o) : null)
- ? ((o.needReadable = o.length <= o.highWaterMark), (s = 0))
- : ((o.length -= s), (o.awaitDrain = 0)),
- 0 === o.length &&
- (o.ended || (o.needReadable = !0), i !== s && o.ended && endReadable(this)),
- null !== u && this.emit('data', u),
- u
- );
- }),
- (Readable.prototype._read = function (s) {
- pe(this, new le('_read()'));
- }),
- (Readable.prototype.pipe = function (s, o) {
- var i = this,
- u = this._readableState;
- switch (u.pipesCount) {
- case 0:
- u.pipes = s;
- break;
- case 1:
- u.pipes = [u.pipes, s];
- break;
- default:
- u.pipes.push(s);
- }
- (u.pipesCount += 1), L('pipe count=%d opts=%j', u.pipesCount, o);
- var x = (!o || !1 !== o.end) && s !== _.stdout && s !== _.stderr ? onend : unpipe;
- function onunpipe(o, _) {
- L('onunpipe'),
- o === i &&
- _ &&
- !1 === _.hasUnpiped &&
- ((_.hasUnpiped = !0),
- (function cleanup() {
- L('cleanup'),
- s.removeListener('close', onclose),
- s.removeListener('finish', onfinish),
- s.removeListener('drain', C),
- s.removeListener('error', onerror),
- s.removeListener('unpipe', onunpipe),
- i.removeListener('end', onend),
- i.removeListener('end', unpipe),
- i.removeListener('data', ondata),
- (j = !0),
- !u.awaitDrain || (s._writableState && !s._writableState.needDrain) || C();
- })());
- }
- function onend() {
- L('onend'), s.end();
- }
- u.endEmitted ? _.nextTick(x) : i.once('end', x), s.on('unpipe', onunpipe);
- var C = (function pipeOnDrain(s) {
- return function pipeOnDrainFunctionResult() {
- var o = s._readableState;
- L('pipeOnDrain', o.awaitDrain),
- o.awaitDrain && o.awaitDrain--,
- 0 === o.awaitDrain && w(s, 'data') && ((o.flowing = !0), flow(s));
- };
- })(i);
- s.on('drain', C);
- var j = !1;
- function ondata(o) {
- L('ondata');
- var _ = s.write(o);
- L('dest.write', _),
- !1 === _ &&
- (((1 === u.pipesCount && u.pipes === s) ||
- (u.pipesCount > 1 && -1 !== indexOf(u.pipes, s))) &&
- !j &&
- (L('false write response, pause', u.awaitDrain), u.awaitDrain++),
- i.pause());
- }
- function onerror(o) {
- L('onerror', o),
- unpipe(),
- s.removeListener('error', onerror),
- 0 === w(s, 'error') && pe(s, o);
- }
- function onclose() {
- s.removeListener('finish', onfinish), unpipe();
- }
- function onfinish() {
- L('onfinish'), s.removeListener('close', onclose), unpipe();
- }
- function unpipe() {
- L('unpipe'), i.unpipe(s);
- }
- return (
- i.on('data', ondata),
- (function prependListener(s, o, i) {
- if ('function' == typeof s.prependListener) return s.prependListener(o, i);
- s._events && s._events[o]
- ? Array.isArray(s._events[o])
- ? s._events[o].unshift(i)
- : (s._events[o] = [i, s._events[o]])
- : s.on(o, i);
- })(s, 'error', onerror),
- s.once('close', onclose),
- s.once('finish', onfinish),
- s.emit('pipe', i),
- u.flowing || (L('pipe resume'), i.resume()),
- s
- );
- }),
- (Readable.prototype.unpipe = function (s) {
- var o = this._readableState,
- i = { hasUnpiped: !1 };
- if (0 === o.pipesCount) return this;
- if (1 === o.pipesCount)
- return (
- (s && s !== o.pipes) ||
- (s || (s = o.pipes),
- (o.pipes = null),
- (o.pipesCount = 0),
- (o.flowing = !1),
- s && s.emit('unpipe', this, i)),
- this
- );
- if (!s) {
- var u = o.pipes,
- _ = o.pipesCount;
- (o.pipes = null), (o.pipesCount = 0), (o.flowing = !1);
- for (var w = 0; w < _; w++) u[w].emit('unpipe', this, { hasUnpiped: !1 });
- return this;
- }
- var x = indexOf(o.pipes, s);
- return (
- -1 === x ||
- (o.pipes.splice(x, 1),
- (o.pipesCount -= 1),
- 1 === o.pipesCount && (o.pipes = o.pipes[0]),
- s.emit('unpipe', this, i)),
- this
- );
- }),
- (Readable.prototype.on = function (s, o) {
- var i = x.prototype.on.call(this, s, o),
- u = this._readableState;
- return (
- 'data' === s
- ? ((u.readableListening = this.listenerCount('readable') > 0),
- !1 !== u.flowing && this.resume())
- : 'readable' === s &&
- (u.endEmitted ||
- u.readableListening ||
- ((u.readableListening = u.needReadable = !0),
- (u.flowing = !1),
- (u.emittedReadable = !1),
- L('on readable', u.length, u.reading),
- u.length
- ? emitReadable(this)
- : u.reading || _.nextTick(nReadingNextTick, this))),
- i
- );
- }),
- (Readable.prototype.addListener = Readable.prototype.on),
- (Readable.prototype.removeListener = function (s, o) {
- var i = x.prototype.removeListener.call(this, s, o);
- return 'readable' === s && _.nextTick(updateReadableListening, this), i;
- }),
- (Readable.prototype.removeAllListeners = function (s) {
- var o = x.prototype.removeAllListeners.apply(this, arguments);
- return (
- ('readable' !== s && void 0 !== s) || _.nextTick(updateReadableListening, this), o
- );
- }),
- (Readable.prototype.resume = function () {
- var s = this._readableState;
- return (
- s.flowing ||
- (L('resume'),
- (s.flowing = !s.readableListening),
- (function resume(s, o) {
- o.resumeScheduled || ((o.resumeScheduled = !0), _.nextTick(resume_, s, o));
- })(this, s)),
- (s.paused = !1),
- this
- );
- }),
- (Readable.prototype.pause = function () {
- return (
- L('call pause flowing=%j', this._readableState.flowing),
- !1 !== this._readableState.flowing &&
- (L('pause'), (this._readableState.flowing = !1), this.emit('pause')),
- (this._readableState.paused = !0),
- this
- );
- }),
- (Readable.prototype.wrap = function (s) {
- var o = this,
- i = this._readableState,
- u = !1;
- for (var _ in (s.on('end', function () {
- if ((L('wrapped end'), i.decoder && !i.ended)) {
- var s = i.decoder.end();
- s && s.length && o.push(s);
- }
- o.push(null);
- }),
- s.on('data', function (_) {
- (L('wrapped data'),
- i.decoder && (_ = i.decoder.write(_)),
- i.objectMode && null == _) ||
- ((i.objectMode || (_ && _.length)) && (o.push(_) || ((u = !0), s.pause())));
- }),
- s))
- void 0 === this[_] &&
- 'function' == typeof s[_] &&
- (this[_] = (function methodWrap(o) {
- return function methodWrapReturnFunction() {
- return s[o].apply(s, arguments);
- };
- })(_));
- for (var w = 0; w < de.length; w++) s.on(de[w], this.emit.bind(this, de[w]));
- return (
- (this._read = function (o) {
- L('wrapped _read', o), u && ((u = !1), s.resume());
- }),
- this
- );
- }),
- 'function' == typeof Symbol &&
- (Readable.prototype[Symbol.asyncIterator] = function () {
- return void 0 === V && (V = i(2955)), V(this);
- }),
- Object.defineProperty(Readable.prototype, 'readableHighWaterMark', {
- enumerable: !1,
- get: function get() {
- return this._readableState.highWaterMark;
- }
- }),
- Object.defineProperty(Readable.prototype, 'readableBuffer', {
- enumerable: !1,
- get: function get() {
- return this._readableState && this._readableState.buffer;
- }
- }),
- Object.defineProperty(Readable.prototype, 'readableFlowing', {
- enumerable: !1,
- get: function get() {
- return this._readableState.flowing;
- },
- set: function set(s) {
- this._readableState && (this._readableState.flowing = s);
- }
- }),
- (Readable._fromList = fromList),
- Object.defineProperty(Readable.prototype, 'readableLength', {
- enumerable: !1,
- get: function get() {
- return this._readableState.length;
- }
- }),
- 'function' == typeof Symbol &&
- (Readable.from = function (s, o) {
- return void 0 === U && (U = i(55157)), U(Readable, s, o);
- });
- },
- 74610: (s, o, i) => {
- 'use strict';
- s.exports = Transform;
- var u = i(86048).F,
- _ = u.ERR_METHOD_NOT_IMPLEMENTED,
- w = u.ERR_MULTIPLE_CALLBACK,
- x = u.ERR_TRANSFORM_ALREADY_TRANSFORMING,
- C = u.ERR_TRANSFORM_WITH_LENGTH_0,
- j = i(25382);
- function afterTransform(s, o) {
- var i = this._transformState;
- i.transforming = !1;
- var u = i.writecb;
- if (null === u) return this.emit('error', new w());
- (i.writechunk = null), (i.writecb = null), null != o && this.push(o), u(s);
- var _ = this._readableState;
- (_.reading = !1),
- (_.needReadable || _.length < _.highWaterMark) && this._read(_.highWaterMark);
- }
- function Transform(s) {
- if (!(this instanceof Transform)) return new Transform(s);
- j.call(this, s),
- (this._transformState = {
- afterTransform: afterTransform.bind(this),
- needTransform: !1,
- transforming: !1,
- writecb: null,
- writechunk: null,
- writeencoding: null
- }),
- (this._readableState.needReadable = !0),
- (this._readableState.sync = !1),
- s &&
- ('function' == typeof s.transform && (this._transform = s.transform),
- 'function' == typeof s.flush && (this._flush = s.flush)),
- this.on('prefinish', prefinish);
- }
- function prefinish() {
- var s = this;
- 'function' != typeof this._flush || this._readableState.destroyed
- ? done(this, null, null)
- : this._flush(function (o, i) {
- done(s, o, i);
- });
- }
- function done(s, o, i) {
- if (o) return s.emit('error', o);
- if ((null != i && s.push(i), s._writableState.length)) throw new C();
- if (s._transformState.transforming) throw new x();
- return s.push(null);
- }
- i(56698)(Transform, j),
- (Transform.prototype.push = function (s, o) {
- return (this._transformState.needTransform = !1), j.prototype.push.call(this, s, o);
- }),
- (Transform.prototype._transform = function (s, o, i) {
- i(new _('_transform()'));
- }),
- (Transform.prototype._write = function (s, o, i) {
- var u = this._transformState;
- if (((u.writecb = i), (u.writechunk = s), (u.writeencoding = o), !u.transforming)) {
- var _ = this._readableState;
- (u.needTransform || _.needReadable || _.length < _.highWaterMark) &&
- this._read(_.highWaterMark);
- }
- }),
- (Transform.prototype._read = function (s) {
- var o = this._transformState;
- null === o.writechunk || o.transforming
- ? (o.needTransform = !0)
- : ((o.transforming = !0),
- this._transform(o.writechunk, o.writeencoding, o.afterTransform));
- }),
- (Transform.prototype._destroy = function (s, o) {
- j.prototype._destroy.call(this, s, function (s) {
- o(s);
- });
- });
- },
- 16708: (s, o, i) => {
- 'use strict';
- var u,
- _ = i(65606);
- function CorkedRequest(s) {
- var o = this;
- (this.next = null),
- (this.entry = null),
- (this.finish = function () {
- !(function onCorkedFinish(s, o, i) {
- var u = s.entry;
- s.entry = null;
- for (; u; ) {
- var _ = u.callback;
- o.pendingcb--, _(i), (u = u.next);
- }
- o.corkedRequestsFree.next = s;
- })(o, s);
- });
- }
- (s.exports = Writable), (Writable.WritableState = WritableState);
- var w = { deprecate: i(94643) },
- x = i(40345),
- C = i(48287).Buffer,
- j =
- (void 0 !== i.g
- ? i.g
- : 'undefined' != typeof window
- ? window
- : 'undefined' != typeof self
- ? self
- : {}
- ).Uint8Array || function () {};
- var L,
- B = i(75896),
- $ = i(65291).getHighWaterMark,
- V = i(86048).F,
- U = V.ERR_INVALID_ARG_TYPE,
- z = V.ERR_METHOD_NOT_IMPLEMENTED,
- Y = V.ERR_MULTIPLE_CALLBACK,
- Z = V.ERR_STREAM_CANNOT_PIPE,
- ee = V.ERR_STREAM_DESTROYED,
- ie = V.ERR_STREAM_NULL_VALUES,
- ae = V.ERR_STREAM_WRITE_AFTER_END,
- le = V.ERR_UNKNOWN_ENCODING,
- ce = B.errorOrDestroy;
- function nop() {}
- function WritableState(s, o, w) {
- (u = u || i(25382)),
- (s = s || {}),
- 'boolean' != typeof w && (w = o instanceof u),
- (this.objectMode = !!s.objectMode),
- w && (this.objectMode = this.objectMode || !!s.writableObjectMode),
- (this.highWaterMark = $(this, s, 'writableHighWaterMark', w)),
- (this.finalCalled = !1),
- (this.needDrain = !1),
- (this.ending = !1),
- (this.ended = !1),
- (this.finished = !1),
- (this.destroyed = !1);
- var x = !1 === s.decodeStrings;
- (this.decodeStrings = !x),
- (this.defaultEncoding = s.defaultEncoding || 'utf8'),
- (this.length = 0),
- (this.writing = !1),
- (this.corked = 0),
- (this.sync = !0),
- (this.bufferProcessing = !1),
- (this.onwrite = function (s) {
- !(function onwrite(s, o) {
- var i = s._writableState,
- u = i.sync,
- w = i.writecb;
- if ('function' != typeof w) throw new Y();
- if (
- ((function onwriteStateUpdate(s) {
- (s.writing = !1),
- (s.writecb = null),
- (s.length -= s.writelen),
- (s.writelen = 0);
- })(i),
- o)
- )
- !(function onwriteError(s, o, i, u, w) {
- --o.pendingcb,
- i
- ? (_.nextTick(w, u),
- _.nextTick(finishMaybe, s, o),
- (s._writableState.errorEmitted = !0),
- ce(s, u))
- : (w(u),
- (s._writableState.errorEmitted = !0),
- ce(s, u),
- finishMaybe(s, o));
- })(s, i, u, o, w);
- else {
- var x = needFinish(i) || s.destroyed;
- x || i.corked || i.bufferProcessing || !i.bufferedRequest || clearBuffer(s, i),
- u ? _.nextTick(afterWrite, s, i, x, w) : afterWrite(s, i, x, w);
- }
- })(o, s);
- }),
- (this.writecb = null),
- (this.writelen = 0),
- (this.bufferedRequest = null),
- (this.lastBufferedRequest = null),
- (this.pendingcb = 0),
- (this.prefinished = !1),
- (this.errorEmitted = !1),
- (this.emitClose = !1 !== s.emitClose),
- (this.autoDestroy = !!s.autoDestroy),
- (this.bufferedRequestCount = 0),
- (this.corkedRequestsFree = new CorkedRequest(this));
- }
- function Writable(s) {
- var o = this instanceof (u = u || i(25382));
- if (!o && !L.call(Writable, this)) return new Writable(s);
- (this._writableState = new WritableState(s, this, o)),
- (this.writable = !0),
- s &&
- ('function' == typeof s.write && (this._write = s.write),
- 'function' == typeof s.writev && (this._writev = s.writev),
- 'function' == typeof s.destroy && (this._destroy = s.destroy),
- 'function' == typeof s.final && (this._final = s.final)),
- x.call(this);
- }
- function doWrite(s, o, i, u, _, w, x) {
- (o.writelen = u),
- (o.writecb = x),
- (o.writing = !0),
- (o.sync = !0),
- o.destroyed
- ? o.onwrite(new ee('write'))
- : i
- ? s._writev(_, o.onwrite)
- : s._write(_, w, o.onwrite),
- (o.sync = !1);
- }
- function afterWrite(s, o, i, u) {
- i ||
- (function onwriteDrain(s, o) {
- 0 === o.length && o.needDrain && ((o.needDrain = !1), s.emit('drain'));
- })(s, o),
- o.pendingcb--,
- u(),
- finishMaybe(s, o);
- }
- function clearBuffer(s, o) {
- o.bufferProcessing = !0;
- var i = o.bufferedRequest;
- if (s._writev && i && i.next) {
- var u = o.bufferedRequestCount,
- _ = new Array(u),
- w = o.corkedRequestsFree;
- w.entry = i;
- for (var x = 0, C = !0; i; ) (_[x] = i), i.isBuf || (C = !1), (i = i.next), (x += 1);
- (_.allBuffers = C),
- doWrite(s, o, !0, o.length, _, '', w.finish),
- o.pendingcb++,
- (o.lastBufferedRequest = null),
- w.next
- ? ((o.corkedRequestsFree = w.next), (w.next = null))
- : (o.corkedRequestsFree = new CorkedRequest(o)),
- (o.bufferedRequestCount = 0);
- } else {
- for (; i; ) {
- var j = i.chunk,
- L = i.encoding,
- B = i.callback;
- if (
- (doWrite(s, o, !1, o.objectMode ? 1 : j.length, j, L, B),
- (i = i.next),
- o.bufferedRequestCount--,
- o.writing)
- )
- break;
- }
- null === i && (o.lastBufferedRequest = null);
- }
- (o.bufferedRequest = i), (o.bufferProcessing = !1);
- }
- function needFinish(s) {
- return (
- s.ending && 0 === s.length && null === s.bufferedRequest && !s.finished && !s.writing
- );
- }
- function callFinal(s, o) {
- s._final(function (i) {
- o.pendingcb--,
- i && ce(s, i),
- (o.prefinished = !0),
- s.emit('prefinish'),
- finishMaybe(s, o);
- });
- }
- function finishMaybe(s, o) {
- var i = needFinish(o);
- if (
- i &&
- ((function prefinish(s, o) {
- o.prefinished ||
- o.finalCalled ||
- ('function' != typeof s._final || o.destroyed
- ? ((o.prefinished = !0), s.emit('prefinish'))
- : (o.pendingcb++, (o.finalCalled = !0), _.nextTick(callFinal, s, o)));
- })(s, o),
- 0 === o.pendingcb && ((o.finished = !0), s.emit('finish'), o.autoDestroy))
- ) {
- var u = s._readableState;
- (!u || (u.autoDestroy && u.endEmitted)) && s.destroy();
- }
- return i;
- }
- i(56698)(Writable, x),
- (WritableState.prototype.getBuffer = function getBuffer() {
- for (var s = this.bufferedRequest, o = []; s; ) o.push(s), (s = s.next);
- return o;
- }),
- (function () {
- try {
- Object.defineProperty(WritableState.prototype, 'buffer', {
- get: w.deprecate(
- function writableStateBufferGetter() {
- return this.getBuffer();
- },
- '_writableState.buffer is deprecated. Use _writableState.getBuffer instead.',
- 'DEP0003'
- )
- });
- } catch (s) {}
- })(),
- 'function' == typeof Symbol &&
- Symbol.hasInstance &&
- 'function' == typeof Function.prototype[Symbol.hasInstance]
- ? ((L = Function.prototype[Symbol.hasInstance]),
- Object.defineProperty(Writable, Symbol.hasInstance, {
- value: function value(s) {
- return (
- !!L.call(this, s) ||
- (this === Writable && s && s._writableState instanceof WritableState)
- );
- }
- }))
- : (L = function realHasInstance(s) {
- return s instanceof this;
- }),
- (Writable.prototype.pipe = function () {
- ce(this, new Z());
- }),
- (Writable.prototype.write = function (s, o, i) {
- var u = this._writableState,
- w = !1,
- x =
- !u.objectMode &&
- (function _isUint8Array(s) {
- return C.isBuffer(s) || s instanceof j;
- })(s);
- return (
- x &&
- !C.isBuffer(s) &&
- (s = (function _uint8ArrayToBuffer(s) {
- return C.from(s);
- })(s)),
- 'function' == typeof o && ((i = o), (o = null)),
- x ? (o = 'buffer') : o || (o = u.defaultEncoding),
- 'function' != typeof i && (i = nop),
- u.ending
- ? (function writeAfterEnd(s, o) {
- var i = new ae();
- ce(s, i), _.nextTick(o, i);
- })(this, i)
- : (x ||
- (function validChunk(s, o, i, u) {
- var w;
- return (
- null === i
- ? (w = new ie())
- : 'string' == typeof i ||
- o.objectMode ||
- (w = new U('chunk', ['string', 'Buffer'], i)),
- !w || (ce(s, w), _.nextTick(u, w), !1)
- );
- })(this, u, s, i)) &&
- (u.pendingcb++,
- (w = (function writeOrBuffer(s, o, i, u, _, w) {
- if (!i) {
- var x = (function decodeChunk(s, o, i) {
- s.objectMode ||
- !1 === s.decodeStrings ||
- 'string' != typeof o ||
- (o = C.from(o, i));
- return o;
- })(o, u, _);
- u !== x && ((i = !0), (_ = 'buffer'), (u = x));
- }
- var j = o.objectMode ? 1 : u.length;
- o.length += j;
- var L = o.length < o.highWaterMark;
- L || (o.needDrain = !0);
- if (o.writing || o.corked) {
- var B = o.lastBufferedRequest;
- (o.lastBufferedRequest = {
- chunk: u,
- encoding: _,
- isBuf: i,
- callback: w,
- next: null
- }),
- B
- ? (B.next = o.lastBufferedRequest)
- : (o.bufferedRequest = o.lastBufferedRequest),
- (o.bufferedRequestCount += 1);
- } else doWrite(s, o, !1, j, u, _, w);
- return L;
- })(this, u, x, s, o, i))),
- w
- );
- }),
- (Writable.prototype.cork = function () {
- this._writableState.corked++;
- }),
- (Writable.prototype.uncork = function () {
- var s = this._writableState;
- s.corked &&
- (s.corked--,
- s.writing ||
- s.corked ||
- s.bufferProcessing ||
- !s.bufferedRequest ||
- clearBuffer(this, s));
- }),
- (Writable.prototype.setDefaultEncoding = function setDefaultEncoding(s) {
- if (
- ('string' == typeof s && (s = s.toLowerCase()),
- !(
- [
- 'hex',
- 'utf8',
- 'utf-8',
- 'ascii',
- 'binary',
- 'base64',
- 'ucs2',
- 'ucs-2',
- 'utf16le',
- 'utf-16le',
- 'raw'
- ].indexOf((s + '').toLowerCase()) > -1
- ))
- )
- throw new le(s);
- return (this._writableState.defaultEncoding = s), this;
- }),
- Object.defineProperty(Writable.prototype, 'writableBuffer', {
- enumerable: !1,
- get: function get() {
- return this._writableState && this._writableState.getBuffer();
- }
- }),
- Object.defineProperty(Writable.prototype, 'writableHighWaterMark', {
- enumerable: !1,
- get: function get() {
- return this._writableState.highWaterMark;
- }
- }),
- (Writable.prototype._write = function (s, o, i) {
- i(new z('_write()'));
- }),
- (Writable.prototype._writev = null),
- (Writable.prototype.end = function (s, o, i) {
- var u = this._writableState;
- return (
- 'function' == typeof s
- ? ((i = s), (s = null), (o = null))
- : 'function' == typeof o && ((i = o), (o = null)),
- null != s && this.write(s, o),
- u.corked && ((u.corked = 1), this.uncork()),
- u.ending ||
- (function endWritable(s, o, i) {
- (o.ending = !0),
- finishMaybe(s, o),
- i && (o.finished ? _.nextTick(i) : s.once('finish', i));
- (o.ended = !0), (s.writable = !1);
- })(this, u, i),
- this
- );
- }),
- Object.defineProperty(Writable.prototype, 'writableLength', {
- enumerable: !1,
- get: function get() {
- return this._writableState.length;
- }
- }),
- Object.defineProperty(Writable.prototype, 'destroyed', {
- enumerable: !1,
- get: function get() {
- return void 0 !== this._writableState && this._writableState.destroyed;
- },
- set: function set(s) {
- this._writableState && (this._writableState.destroyed = s);
- }
- }),
- (Writable.prototype.destroy = B.destroy),
- (Writable.prototype._undestroy = B.undestroy),
- (Writable.prototype._destroy = function (s, o) {
- o(s);
- });
- },
- 2955: (s, o, i) => {
- 'use strict';
- var u,
- _ = i(65606);
- function _defineProperty(s, o, i) {
- return (
- (o = (function _toPropertyKey(s) {
- var o = (function _toPrimitive(s, o) {
- if ('object' != typeof s || null === s) return s;
- var i = s[Symbol.toPrimitive];
- if (void 0 !== i) {
- var u = i.call(s, o || 'default');
- if ('object' != typeof u) return u;
- throw new TypeError('@@toPrimitive must return a primitive value.');
- }
- return ('string' === o ? String : Number)(s);
- })(s, 'string');
- return 'symbol' == typeof o ? o : String(o);
- })(o)) in s
- ? Object.defineProperty(s, o, {
- value: i,
- enumerable: !0,
- configurable: !0,
- writable: !0
- })
- : (s[o] = i),
- s
- );
- }
- var w = i(86238),
- x = Symbol('lastResolve'),
- C = Symbol('lastReject'),
- j = Symbol('error'),
- L = Symbol('ended'),
- B = Symbol('lastPromise'),
- $ = Symbol('handlePromise'),
- V = Symbol('stream');
- function createIterResult(s, o) {
- return { value: s, done: o };
- }
- function readAndResolve(s) {
- var o = s[x];
- if (null !== o) {
- var i = s[V].read();
- null !== i &&
- ((s[B] = null), (s[x] = null), (s[C] = null), o(createIterResult(i, !1)));
- }
- }
- function onReadable(s) {
- _.nextTick(readAndResolve, s);
- }
- var U = Object.getPrototypeOf(function () {}),
- z = Object.setPrototypeOf(
- (_defineProperty(
- (u = {
- get stream() {
- return this[V];
- },
- next: function next() {
- var s = this,
- o = this[j];
- if (null !== o) return Promise.reject(o);
- if (this[L]) return Promise.resolve(createIterResult(void 0, !0));
- if (this[V].destroyed)
- return new Promise(function (o, i) {
- _.nextTick(function () {
- s[j] ? i(s[j]) : o(createIterResult(void 0, !0));
- });
- });
- var i,
- u = this[B];
- if (u)
- i = new Promise(
- (function wrapForNext(s, o) {
- return function (i, u) {
- s.then(function () {
- o[L] ? i(createIterResult(void 0, !0)) : o[$](i, u);
- }, u);
- };
- })(u, this)
- );
- else {
- var w = this[V].read();
- if (null !== w) return Promise.resolve(createIterResult(w, !1));
- i = new Promise(this[$]);
- }
- return (this[B] = i), i;
- }
- }),
- Symbol.asyncIterator,
- function () {
- return this;
- }
- ),
- _defineProperty(u, 'return', function _return() {
- var s = this;
- return new Promise(function (o, i) {
- s[V].destroy(null, function (s) {
- s ? i(s) : o(createIterResult(void 0, !0));
- });
- });
- }),
- u),
- U
- );
- s.exports = function createReadableStreamAsyncIterator(s) {
- var o,
- i = Object.create(
- z,
- (_defineProperty((o = {}), V, { value: s, writable: !0 }),
- _defineProperty(o, x, { value: null, writable: !0 }),
- _defineProperty(o, C, { value: null, writable: !0 }),
- _defineProperty(o, j, { value: null, writable: !0 }),
- _defineProperty(o, L, { value: s._readableState.endEmitted, writable: !0 }),
- _defineProperty(o, $, {
- value: function value(s, o) {
- var u = i[V].read();
- u
- ? ((i[B] = null), (i[x] = null), (i[C] = null), s(createIterResult(u, !1)))
- : ((i[x] = s), (i[C] = o));
- },
- writable: !0
- }),
- o)
- );
- return (
- (i[B] = null),
- w(s, function (s) {
- if (s && 'ERR_STREAM_PREMATURE_CLOSE' !== s.code) {
- var o = i[C];
- return (
- null !== o && ((i[B] = null), (i[x] = null), (i[C] = null), o(s)),
- void (i[j] = s)
- );
- }
- var u = i[x];
- null !== u &&
- ((i[B] = null), (i[x] = null), (i[C] = null), u(createIterResult(void 0, !0))),
- (i[L] = !0);
- }),
- s.on('readable', onReadable.bind(null, i)),
- i
- );
- };
- },
- 80345: (s, o, i) => {
- 'use strict';
- function ownKeys(s, o) {
- var i = Object.keys(s);
- if (Object.getOwnPropertySymbols) {
- var u = Object.getOwnPropertySymbols(s);
- o &&
- (u = u.filter(function (o) {
- return Object.getOwnPropertyDescriptor(s, o).enumerable;
- })),
- i.push.apply(i, u);
- }
- return i;
- }
- function _objectSpread(s) {
- for (var o = 1; o < arguments.length; o++) {
- var i = null != arguments[o] ? arguments[o] : {};
- o % 2
- ? ownKeys(Object(i), !0).forEach(function (o) {
- _defineProperty(s, o, i[o]);
- })
- : Object.getOwnPropertyDescriptors
- ? Object.defineProperties(s, Object.getOwnPropertyDescriptors(i))
- : ownKeys(Object(i)).forEach(function (o) {
- Object.defineProperty(s, o, Object.getOwnPropertyDescriptor(i, o));
- });
- }
- return s;
- }
- function _defineProperty(s, o, i) {
- return (
- (o = _toPropertyKey(o)) in s
- ? Object.defineProperty(s, o, {
- value: i,
- enumerable: !0,
- configurable: !0,
- writable: !0
- })
- : (s[o] = i),
- s
- );
- }
- function _defineProperties(s, o) {
- for (var i = 0; i < o.length; i++) {
- var u = o[i];
- (u.enumerable = u.enumerable || !1),
- (u.configurable = !0),
- 'value' in u && (u.writable = !0),
- Object.defineProperty(s, _toPropertyKey(u.key), u);
- }
- }
- function _toPropertyKey(s) {
- var o = (function _toPrimitive(s, o) {
- if ('object' != typeof s || null === s) return s;
- var i = s[Symbol.toPrimitive];
- if (void 0 !== i) {
- var u = i.call(s, o || 'default');
- if ('object' != typeof u) return u;
- throw new TypeError('@@toPrimitive must return a primitive value.');
- }
- return ('string' === o ? String : Number)(s);
- })(s, 'string');
- return 'symbol' == typeof o ? o : String(o);
- }
- var u = i(48287).Buffer,
- _ = i(15340).inspect,
- w = (_ && _.custom) || 'inspect';
- s.exports = (function () {
- function BufferList() {
- !(function _classCallCheck(s, o) {
- if (!(s instanceof o)) throw new TypeError('Cannot call a class as a function');
- })(this, BufferList),
- (this.head = null),
- (this.tail = null),
- (this.length = 0);
- }
- return (
- (function _createClass(s, o, i) {
- return (
- o && _defineProperties(s.prototype, o),
- i && _defineProperties(s, i),
- Object.defineProperty(s, 'prototype', { writable: !1 }),
- s
- );
- })(BufferList, [
- {
- key: 'push',
- value: function push(s) {
- var o = { data: s, next: null };
- this.length > 0 ? (this.tail.next = o) : (this.head = o),
- (this.tail = o),
- ++this.length;
- }
- },
- {
- key: 'unshift',
- value: function unshift(s) {
- var o = { data: s, next: this.head };
- 0 === this.length && (this.tail = o), (this.head = o), ++this.length;
- }
- },
- {
- key: 'shift',
- value: function shift() {
- if (0 !== this.length) {
- var s = this.head.data;
- return (
- 1 === this.length
- ? (this.head = this.tail = null)
- : (this.head = this.head.next),
- --this.length,
- s
- );
- }
- }
- },
- {
- key: 'clear',
- value: function clear() {
- (this.head = this.tail = null), (this.length = 0);
- }
- },
- {
- key: 'join',
- value: function join(s) {
- if (0 === this.length) return '';
- for (var o = this.head, i = '' + o.data; (o = o.next); ) i += s + o.data;
- return i;
- }
- },
- {
- key: 'concat',
- value: function concat(s) {
- if (0 === this.length) return u.alloc(0);
- for (var o, i, _, w = u.allocUnsafe(s >>> 0), x = this.head, C = 0; x; )
- (o = x.data),
- (i = w),
- (_ = C),
- u.prototype.copy.call(o, i, _),
- (C += x.data.length),
- (x = x.next);
- return w;
- }
- },
- {
- key: 'consume',
- value: function consume(s, o) {
- var i;
- return (
- s < this.head.data.length
- ? ((i = this.head.data.slice(0, s)),
- (this.head.data = this.head.data.slice(s)))
- : (i =
- s === this.head.data.length
- ? this.shift()
- : o
- ? this._getString(s)
- : this._getBuffer(s)),
- i
- );
- }
- },
- {
- key: 'first',
- value: function first() {
- return this.head.data;
- }
- },
- {
- key: '_getString',
- value: function _getString(s) {
- var o = this.head,
- i = 1,
- u = o.data;
- for (s -= u.length; (o = o.next); ) {
- var _ = o.data,
- w = s > _.length ? _.length : s;
- if ((w === _.length ? (u += _) : (u += _.slice(0, s)), 0 === (s -= w))) {
- w === _.length
- ? (++i, o.next ? (this.head = o.next) : (this.head = this.tail = null))
- : ((this.head = o), (o.data = _.slice(w)));
- break;
- }
- ++i;
- }
- return (this.length -= i), u;
- }
- },
- {
- key: '_getBuffer',
- value: function _getBuffer(s) {
- var o = u.allocUnsafe(s),
- i = this.head,
- _ = 1;
- for (i.data.copy(o), s -= i.data.length; (i = i.next); ) {
- var w = i.data,
- x = s > w.length ? w.length : s;
- if ((w.copy(o, o.length - s, 0, x), 0 === (s -= x))) {
- x === w.length
- ? (++_, i.next ? (this.head = i.next) : (this.head = this.tail = null))
- : ((this.head = i), (i.data = w.slice(x)));
- break;
- }
- ++_;
- }
- return (this.length -= _), o;
- }
- },
- {
- key: w,
- value: function value(s, o) {
- return _(
- this,
- _objectSpread(_objectSpread({}, o), {}, { depth: 0, customInspect: !1 })
- );
- }
- }
- ]),
- BufferList
- );
- })();
- },
- 75896: (s, o, i) => {
- 'use strict';
- var u = i(65606);
- function emitErrorAndCloseNT(s, o) {
- emitErrorNT(s, o), emitCloseNT(s);
- }
- function emitCloseNT(s) {
- (s._writableState && !s._writableState.emitClose) ||
- (s._readableState && !s._readableState.emitClose) ||
- s.emit('close');
- }
- function emitErrorNT(s, o) {
- s.emit('error', o);
- }
- s.exports = {
- destroy: function destroy(s, o) {
- var i = this,
- _ = this._readableState && this._readableState.destroyed,
- w = this._writableState && this._writableState.destroyed;
- return _ || w
- ? (o
- ? o(s)
- : s &&
- (this._writableState
- ? this._writableState.errorEmitted ||
- ((this._writableState.errorEmitted = !0),
- u.nextTick(emitErrorNT, this, s))
- : u.nextTick(emitErrorNT, this, s)),
- this)
- : (this._readableState && (this._readableState.destroyed = !0),
- this._writableState && (this._writableState.destroyed = !0),
- this._destroy(s || null, function (s) {
- !o && s
- ? i._writableState
- ? i._writableState.errorEmitted
- ? u.nextTick(emitCloseNT, i)
- : ((i._writableState.errorEmitted = !0),
- u.nextTick(emitErrorAndCloseNT, i, s))
- : u.nextTick(emitErrorAndCloseNT, i, s)
- : o
- ? (u.nextTick(emitCloseNT, i), o(s))
- : u.nextTick(emitCloseNT, i);
- }),
- this);
- },
- undestroy: function undestroy() {
- this._readableState &&
- ((this._readableState.destroyed = !1),
- (this._readableState.reading = !1),
- (this._readableState.ended = !1),
- (this._readableState.endEmitted = !1)),
- this._writableState &&
- ((this._writableState.destroyed = !1),
- (this._writableState.ended = !1),
- (this._writableState.ending = !1),
- (this._writableState.finalCalled = !1),
- (this._writableState.prefinished = !1),
- (this._writableState.finished = !1),
- (this._writableState.errorEmitted = !1));
- },
- errorOrDestroy: function errorOrDestroy(s, o) {
- var i = s._readableState,
- u = s._writableState;
- (i && i.autoDestroy) || (u && u.autoDestroy) ? s.destroy(o) : s.emit('error', o);
- }
- };
- },
- 86238: (s, o, i) => {
- 'use strict';
- var u = i(86048).F.ERR_STREAM_PREMATURE_CLOSE;
- function noop() {}
- s.exports = function eos(s, o, i) {
- if ('function' == typeof o) return eos(s, null, o);
- o || (o = {}),
- (i = (function once(s) {
- var o = !1;
- return function () {
- if (!o) {
- o = !0;
- for (var i = arguments.length, u = new Array(i), _ = 0; _ < i; _++)
- u[_] = arguments[_];
- s.apply(this, u);
- }
- };
- })(i || noop));
- var _ = o.readable || (!1 !== o.readable && s.readable),
- w = o.writable || (!1 !== o.writable && s.writable),
- x = function onlegacyfinish() {
- s.writable || j();
- },
- C = s._writableState && s._writableState.finished,
- j = function onfinish() {
- (w = !1), (C = !0), _ || i.call(s);
- },
- L = s._readableState && s._readableState.endEmitted,
- B = function onend() {
- (_ = !1), (L = !0), w || i.call(s);
- },
- $ = function onerror(o) {
- i.call(s, o);
- },
- V = function onclose() {
- var o;
- return _ && !L
- ? ((s._readableState && s._readableState.ended) || (o = new u()), i.call(s, o))
- : w && !C
- ? ((s._writableState && s._writableState.ended) || (o = new u()), i.call(s, o))
- : void 0;
- },
- U = function onrequest() {
- s.req.on('finish', j);
- };
- return (
- !(function isRequest(s) {
- return s.setHeader && 'function' == typeof s.abort;
- })(s)
- ? w && !s._writableState && (s.on('end', x), s.on('close', x))
- : (s.on('complete', j), s.on('abort', V), s.req ? U() : s.on('request', U)),
- s.on('end', B),
- s.on('finish', j),
- !1 !== o.error && s.on('error', $),
- s.on('close', V),
- function () {
- s.removeListener('complete', j),
- s.removeListener('abort', V),
- s.removeListener('request', U),
- s.req && s.req.removeListener('finish', j),
- s.removeListener('end', x),
- s.removeListener('close', x),
- s.removeListener('finish', j),
- s.removeListener('end', B),
- s.removeListener('error', $),
- s.removeListener('close', V);
- }
- );
- };
- },
- 55157: (s) => {
- s.exports = function () {
- throw new Error('Readable.from is not available in the browser');
- };
- },
- 57758: (s, o, i) => {
- 'use strict';
- var u;
- var _ = i(86048).F,
- w = _.ERR_MISSING_ARGS,
- x = _.ERR_STREAM_DESTROYED;
- function noop(s) {
- if (s) throw s;
- }
- function call(s) {
- s();
- }
- function pipe(s, o) {
- return s.pipe(o);
- }
- s.exports = function pipeline() {
- for (var s = arguments.length, o = new Array(s), _ = 0; _ < s; _++) o[_] = arguments[_];
- var C,
- j = (function popCallback(s) {
- return s.length ? ('function' != typeof s[s.length - 1] ? noop : s.pop()) : noop;
- })(o);
- if ((Array.isArray(o[0]) && (o = o[0]), o.length < 2)) throw new w('streams');
- var L = o.map(function (s, _) {
- var w = _ < o.length - 1;
- return (function destroyer(s, o, _, w) {
- w = (function once(s) {
- var o = !1;
- return function () {
- o || ((o = !0), s.apply(void 0, arguments));
- };
- })(w);
- var C = !1;
- s.on('close', function () {
- C = !0;
- }),
- void 0 === u && (u = i(86238)),
- u(s, { readable: o, writable: _ }, function (s) {
- if (s) return w(s);
- (C = !0), w();
- });
- var j = !1;
- return function (o) {
- if (!C && !j)
- return (
- (j = !0),
- (function isRequest(s) {
- return s.setHeader && 'function' == typeof s.abort;
- })(s)
- ? s.abort()
- : 'function' == typeof s.destroy
- ? s.destroy()
- : void w(o || new x('pipe'))
- );
- };
- })(s, w, _ > 0, function (s) {
- C || (C = s), s && L.forEach(call), w || (L.forEach(call), j(C));
- });
- });
- return o.reduce(pipe);
- };
- },
- 65291: (s, o, i) => {
- 'use strict';
- var u = i(86048).F.ERR_INVALID_OPT_VALUE;
- s.exports = {
- getHighWaterMark: function getHighWaterMark(s, o, i, _) {
- var w = (function highWaterMarkFrom(s, o, i) {
- return null != s.highWaterMark ? s.highWaterMark : o ? s[i] : null;
- })(o, _, i);
- if (null != w) {
- if (!isFinite(w) || Math.floor(w) !== w || w < 0)
- throw new u(_ ? i : 'highWaterMark', w);
- return Math.floor(w);
- }
- return s.objectMode ? 16 : 16384;
- }
- };
- },
- 40345: (s, o, i) => {
- s.exports = i(37007).EventEmitter;
- },
- 84977: (s, o, i) => {
- 'use strict';
- Object.defineProperty(o, '__esModule', { value: !0 });
- var u = (function _interopRequireDefault(s) {
- return s && s.__esModule ? s : { default: s };
- })(i(9404)),
- _ = i(55674);
- (o.default = function (s) {
- var o = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : u.default.Map,
- i = Object.keys(s);
- return function () {
- var u = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : o(),
- w = arguments[1];
- return u.withMutations(function (o) {
- i.forEach(function (i) {
- var u = (0, s[i])(o.get(i), w);
- (0, _.validateNextState)(u, i, w), o.set(i, u);
- });
- });
- };
- }),
- (s.exports = o.default);
- },
- 89593: (s, o, i) => {
- 'use strict';
- o.H = void 0;
- var u = (function _interopRequireDefault(s) {
- return s && s.__esModule ? s : { default: s };
- })(i(84977));
- o.H = u.default;
- },
- 48590: (s, o) => {
- 'use strict';
- Object.defineProperty(o, '__esModule', { value: !0 }),
- (o.default = function (s) {
- return s && '@@redux/INIT' === s.type
- ? 'initialState argument passed to createStore'
- : 'previous state received by the reducer';
- }),
- (s.exports = o.default);
- },
- 82261: (s, o, i) => {
- 'use strict';
- Object.defineProperty(o, '__esModule', { value: !0 });
- var u = _interopRequireDefault(i(9404)),
- _ = _interopRequireDefault(i(48590));
- function _interopRequireDefault(s) {
- return s && s.__esModule ? s : { default: s };
- }
- (o.default = function (s, o, i) {
- var w = Object.keys(o);
- if (!w.length)
- return 'Store does not have a valid reducer. Make sure the argument passed to combineReducers is an object whose values are reducers.';
- var x = (0, _.default)(i);
- if (
- u.default.isImmutable ? !u.default.isImmutable(s) : !u.default.Iterable.isIterable(s)
- )
- return (
- 'The ' +
- x +
- ' is of unexpected type. Expected argument to be an instance of Immutable.Collection or Immutable.Record with the following properties: "' +
- w.join('", "') +
- '".'
- );
- var C = s
- .toSeq()
- .keySeq()
- .toArray()
- .filter(function (s) {
- return !o.hasOwnProperty(s);
- });
- return C.length > 0
- ? 'Unexpected ' +
- (1 === C.length ? 'property' : 'properties') +
- ' "' +
- C.join('", "') +
- '" found in ' +
- x +
- '. Expected to find one of the known reducer property names instead: "' +
- w.join('", "') +
- '". Unexpected properties will be ignored.'
- : null;
- }),
- (s.exports = o.default);
- },
- 55674: (s, o, i) => {
- 'use strict';
- Object.defineProperty(o, '__esModule', { value: !0 }),
- (o.validateNextState =
- o.getUnexpectedInvocationParameterMessage =
- o.getStateName =
- void 0);
- var u = _interopRequireDefault(i(48590)),
- _ = _interopRequireDefault(i(82261)),
- w = _interopRequireDefault(i(27374));
- function _interopRequireDefault(s) {
- return s && s.__esModule ? s : { default: s };
- }
- (o.getStateName = u.default),
- (o.getUnexpectedInvocationParameterMessage = _.default),
- (o.validateNextState = w.default);
- },
- 27374: (s, o) => {
- 'use strict';
- Object.defineProperty(o, '__esModule', { value: !0 }),
- (o.default = function (s, o, i) {
- if (void 0 === s)
- throw new Error(
- 'Reducer "' +
- o +
- '" returned undefined when handling "' +
- i.type +
- '" action. To ignore an action, you must explicitly return the previous state.'
- );
- }),
- (s.exports = o.default);
- },
- 75208: (s) => {
- 'use strict';
- var o,
- i = '';
- s.exports = function repeat(s, u) {
- if ('string' != typeof s) throw new TypeError('expected a string');
- if (1 === u) return s;
- if (2 === u) return s + s;
- var _ = s.length * u;
- if (o !== s || void 0 === o) (o = s), (i = '');
- else if (i.length >= _) return i.substr(0, _);
- for (; _ > i.length && u > 1; ) 1 & u && (i += s), (u >>= 1), (s += s);
- return (i = (i += s).substr(0, _));
- };
- },
- 92063: (s) => {
- 'use strict';
- s.exports = function required(s, o) {
- if (((o = o.split(':')[0]), !(s = +s))) return !1;
- switch (o) {
- case 'http':
- case 'ws':
- return 80 !== s;
- case 'https':
- case 'wss':
- return 443 !== s;
- case 'ftp':
- return 21 !== s;
- case 'gopher':
- return 70 !== s;
- case 'file':
- return !1;
- }
- return 0 !== s;
- };
- },
- 27096: (s, o, i) => {
- const u = i(87586),
- _ = i(6205),
- w = i(10023),
- x = i(8048);
- (s.exports = (s) => {
- var o,
- i,
- C = 0,
- j = { type: _.ROOT, stack: [] },
- L = j,
- B = j.stack,
- $ = [],
- repeatErr = (o) => {
- u.error(s, 'Nothing to repeat at column ' + (o - 1));
- },
- V = u.strToChars(s);
- for (o = V.length; C < o; )
- switch ((i = V[C++])) {
- case '\\':
- switch ((i = V[C++])) {
- case 'b':
- B.push(x.wordBoundary());
- break;
- case 'B':
- B.push(x.nonWordBoundary());
- break;
- case 'w':
- B.push(w.words());
- break;
- case 'W':
- B.push(w.notWords());
- break;
- case 'd':
- B.push(w.ints());
- break;
- case 'D':
- B.push(w.notInts());
- break;
- case 's':
- B.push(w.whitespace());
- break;
- case 'S':
- B.push(w.notWhitespace());
- break;
- default:
- /\d/.test(i)
- ? B.push({ type: _.REFERENCE, value: parseInt(i, 10) })
- : B.push({ type: _.CHAR, value: i.charCodeAt(0) });
- }
- break;
- case '^':
- B.push(x.begin());
- break;
- case '$':
- B.push(x.end());
- break;
- case '[':
- var U;
- '^' === V[C] ? ((U = !0), C++) : (U = !1);
- var z = u.tokenizeClass(V.slice(C), s);
- (C += z[1]), B.push({ type: _.SET, set: z[0], not: U });
- break;
- case '.':
- B.push(w.anyChar());
- break;
- case '(':
- var Y = { type: _.GROUP, stack: [], remember: !0 };
- '?' === (i = V[C]) &&
- ((i = V[C + 1]),
- (C += 2),
- '=' === i
- ? (Y.followedBy = !0)
- : '!' === i
- ? (Y.notFollowedBy = !0)
- : ':' !== i &&
- u.error(
- s,
- `Invalid group, character '${i}' after '?' at column ` + (C - 1)
- ),
- (Y.remember = !1)),
- B.push(Y),
- $.push(L),
- (L = Y),
- (B = Y.stack);
- break;
- case ')':
- 0 === $.length && u.error(s, 'Unmatched ) at column ' + (C - 1)),
- (B = (L = $.pop()).options ? L.options[L.options.length - 1] : L.stack);
- break;
- case '|':
- L.options || ((L.options = [L.stack]), delete L.stack);
- var Z = [];
- L.options.push(Z), (B = Z);
- break;
- case '{':
- var ee,
- ie,
- ae = /^(\d+)(,(\d+)?)?\}/.exec(V.slice(C));
- null !== ae
- ? (0 === B.length && repeatErr(C),
- (ee = parseInt(ae[1], 10)),
- (ie = ae[2] ? (ae[3] ? parseInt(ae[3], 10) : 1 / 0) : ee),
- (C += ae[0].length),
- B.push({ type: _.REPETITION, min: ee, max: ie, value: B.pop() }))
- : B.push({ type: _.CHAR, value: 123 });
- break;
- case '?':
- 0 === B.length && repeatErr(C),
- B.push({ type: _.REPETITION, min: 0, max: 1, value: B.pop() });
- break;
- case '+':
- 0 === B.length && repeatErr(C),
- B.push({ type: _.REPETITION, min: 1, max: 1 / 0, value: B.pop() });
- break;
- case '*':
- 0 === B.length && repeatErr(C),
- B.push({ type: _.REPETITION, min: 0, max: 1 / 0, value: B.pop() });
- break;
- default:
- B.push({ type: _.CHAR, value: i.charCodeAt(0) });
- }
- return 0 !== $.length && u.error(s, 'Unterminated group'), j;
- }),
- (s.exports.types = _);
- },
- 8048: (s, o, i) => {
- const u = i(6205);
- (o.wordBoundary = () => ({ type: u.POSITION, value: 'b' })),
- (o.nonWordBoundary = () => ({ type: u.POSITION, value: 'B' })),
- (o.begin = () => ({ type: u.POSITION, value: '^' })),
- (o.end = () => ({ type: u.POSITION, value: '$' }));
- },
- 10023: (s, o, i) => {
- const u = i(6205),
- INTS = () => [{ type: u.RANGE, from: 48, to: 57 }],
- WORDS = () =>
- [
- { type: u.CHAR, value: 95 },
- { type: u.RANGE, from: 97, to: 122 },
- { type: u.RANGE, from: 65, to: 90 }
- ].concat(INTS()),
- WHITESPACE = () => [
- { type: u.CHAR, value: 9 },
- { type: u.CHAR, value: 10 },
- { type: u.CHAR, value: 11 },
- { type: u.CHAR, value: 12 },
- { type: u.CHAR, value: 13 },
- { type: u.CHAR, value: 32 },
- { type: u.CHAR, value: 160 },
- { type: u.CHAR, value: 5760 },
- { type: u.RANGE, from: 8192, to: 8202 },
- { type: u.CHAR, value: 8232 },
- { type: u.CHAR, value: 8233 },
- { type: u.CHAR, value: 8239 },
- { type: u.CHAR, value: 8287 },
- { type: u.CHAR, value: 12288 },
- { type: u.CHAR, value: 65279 }
- ];
- (o.words = () => ({ type: u.SET, set: WORDS(), not: !1 })),
- (o.notWords = () => ({ type: u.SET, set: WORDS(), not: !0 })),
- (o.ints = () => ({ type: u.SET, set: INTS(), not: !1 })),
- (o.notInts = () => ({ type: u.SET, set: INTS(), not: !0 })),
- (o.whitespace = () => ({ type: u.SET, set: WHITESPACE(), not: !1 })),
- (o.notWhitespace = () => ({ type: u.SET, set: WHITESPACE(), not: !0 })),
- (o.anyChar = () => ({
- type: u.SET,
- set: [
- { type: u.CHAR, value: 10 },
- { type: u.CHAR, value: 13 },
- { type: u.CHAR, value: 8232 },
- { type: u.CHAR, value: 8233 }
- ],
- not: !0
- }));
- },
- 6205: (s) => {
- s.exports = {
- ROOT: 0,
- GROUP: 1,
- POSITION: 2,
- SET: 3,
- RANGE: 4,
- REPETITION: 5,
- REFERENCE: 6,
- CHAR: 7
- };
- },
- 87586: (s, o, i) => {
- const u = i(6205),
- _ = i(10023),
- w = { 0: 0, t: 9, n: 10, v: 11, f: 12, r: 13 };
- (o.strToChars = function (s) {
- return (s = s.replace(
- /(\[\\b\])|(\\)?\\(?:u([A-F0-9]{4})|x([A-F0-9]{2})|(0?[0-7]{2})|c([@A-Z[\\\]^?])|([0tnvfr]))/g,
- function (s, o, i, u, _, x, C, j) {
- if (i) return s;
- var L = o
- ? 8
- : u
- ? parseInt(u, 16)
- : _
- ? parseInt(_, 16)
- : x
- ? parseInt(x, 8)
- : C
- ? '@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^ ?'.indexOf(C)
- : w[j],
- B = String.fromCharCode(L);
- return /[[\]{}^$.|?*+()]/.test(B) && (B = '\\' + B), B;
- }
- ));
- }),
- (o.tokenizeClass = (s, i) => {
- for (
- var w,
- x,
- C = [],
- j =
- /\\(?:(w)|(d)|(s)|(W)|(D)|(S))|((?:(?:\\)(.)|([^\]\\]))-(?:\\)?([^\]]))|(\])|(?:\\)?([^])/g;
- null != (w = j.exec(s));
- )
- if (w[1]) C.push(_.words());
- else if (w[2]) C.push(_.ints());
- else if (w[3]) C.push(_.whitespace());
- else if (w[4]) C.push(_.notWords());
- else if (w[5]) C.push(_.notInts());
- else if (w[6]) C.push(_.notWhitespace());
- else if (w[7])
- C.push({
- type: u.RANGE,
- from: (w[8] || w[9]).charCodeAt(0),
- to: w[10].charCodeAt(0)
- });
- else {
- if (!(x = w[12])) return [C, j.lastIndex];
- C.push({ type: u.CHAR, value: x.charCodeAt(0) });
- }
- o.error(i, 'Unterminated character class');
- }),
- (o.error = (s, o) => {
- throw new SyntaxError('Invalid regular expression: /' + s + '/: ' + o);
- });
- },
- 92861: (s, o, i) => {
- var u = i(48287),
- _ = u.Buffer;
- function copyProps(s, o) {
- for (var i in s) o[i] = s[i];
- }
- function SafeBuffer(s, o, i) {
- return _(s, o, i);
- }
- _.from && _.alloc && _.allocUnsafe && _.allocUnsafeSlow
- ? (s.exports = u)
- : (copyProps(u, o), (o.Buffer = SafeBuffer)),
- (SafeBuffer.prototype = Object.create(_.prototype)),
- copyProps(_, SafeBuffer),
- (SafeBuffer.from = function (s, o, i) {
- if ('number' == typeof s) throw new TypeError('Argument must not be a number');
- return _(s, o, i);
- }),
- (SafeBuffer.alloc = function (s, o, i) {
- if ('number' != typeof s) throw new TypeError('Argument must be a number');
- var u = _(s);
- return (
- void 0 !== o ? ('string' == typeof i ? u.fill(o, i) : u.fill(o)) : u.fill(0), u
- );
- }),
- (SafeBuffer.allocUnsafe = function (s) {
- if ('number' != typeof s) throw new TypeError('Argument must be a number');
- return _(s);
- }),
- (SafeBuffer.allocUnsafeSlow = function (s) {
- if ('number' != typeof s) throw new TypeError('Argument must be a number');
- return u.SlowBuffer(s);
- });
- },
- 29844: (s, o) => {
- 'use strict';
- function f(s, o) {
- var i = s.length;
- s.push(o);
- e: for (; 0 < i; ) {
- var u = (i - 1) >>> 1,
- _ = s[u];
- if (!(0 < g(_, o))) break e;
- (s[u] = o), (s[i] = _), (i = u);
- }
- }
- function h(s) {
- return 0 === s.length ? null : s[0];
- }
- function k(s) {
- if (0 === s.length) return null;
- var o = s[0],
- i = s.pop();
- if (i !== o) {
- s[0] = i;
- e: for (var u = 0, _ = s.length, w = _ >>> 1; u < w; ) {
- var x = 2 * (u + 1) - 1,
- C = s[x],
- j = x + 1,
- L = s[j];
- if (0 > g(C, i))
- j < _ && 0 > g(L, C)
- ? ((s[u] = L), (s[j] = i), (u = j))
- : ((s[u] = C), (s[x] = i), (u = x));
- else {
- if (!(j < _ && 0 > g(L, i))) break e;
- (s[u] = L), (s[j] = i), (u = j);
- }
- }
- }
- return o;
- }
- function g(s, o) {
- var i = s.sortIndex - o.sortIndex;
- return 0 !== i ? i : s.id - o.id;
- }
- if ('object' == typeof performance && 'function' == typeof performance.now) {
- var i = performance;
- o.unstable_now = function () {
- return i.now();
- };
- } else {
- var u = Date,
- _ = u.now();
- o.unstable_now = function () {
- return u.now() - _;
- };
- }
- var w = [],
- x = [],
- C = 1,
- j = null,
- L = 3,
- B = !1,
- $ = !1,
- V = !1,
- U = 'function' == typeof setTimeout ? setTimeout : null,
- z = 'function' == typeof clearTimeout ? clearTimeout : null,
- Y = 'undefined' != typeof setImmediate ? setImmediate : null;
- function G(s) {
- for (var o = h(x); null !== o; ) {
- if (null === o.callback) k(x);
- else {
- if (!(o.startTime <= s)) break;
- k(x), (o.sortIndex = o.expirationTime), f(w, o);
- }
- o = h(x);
- }
- }
- function H(s) {
- if (((V = !1), G(s), !$))
- if (null !== h(w)) ($ = !0), I(J);
- else {
- var o = h(x);
- null !== o && K(H, o.startTime - s);
- }
- }
- function J(s, i) {
- ($ = !1), V && ((V = !1), z(ae), (ae = -1)), (B = !0);
- var u = L;
- try {
- for (G(i), j = h(w); null !== j && (!(j.expirationTime > i) || (s && !M())); ) {
- var _ = j.callback;
- if ('function' == typeof _) {
- (j.callback = null), (L = j.priorityLevel);
- var C = _(j.expirationTime <= i);
- (i = o.unstable_now()),
- 'function' == typeof C ? (j.callback = C) : j === h(w) && k(w),
- G(i);
- } else k(w);
- j = h(w);
- }
- if (null !== j) var U = !0;
- else {
- var Y = h(x);
- null !== Y && K(H, Y.startTime - i), (U = !1);
- }
- return U;
- } finally {
- (j = null), (L = u), (B = !1);
- }
- }
- 'undefined' != typeof navigator &&
- void 0 !== navigator.scheduling &&
- void 0 !== navigator.scheduling.isInputPending &&
- navigator.scheduling.isInputPending.bind(navigator.scheduling);
- var Z,
- ee = !1,
- ie = null,
- ae = -1,
- le = 5,
- ce = -1;
- function M() {
- return !(o.unstable_now() - ce < le);
- }
- function R() {
- if (null !== ie) {
- var s = o.unstable_now();
- ce = s;
- var i = !0;
- try {
- i = ie(!0, s);
- } finally {
- i ? Z() : ((ee = !1), (ie = null));
- }
- } else ee = !1;
- }
- if ('function' == typeof Y)
- Z = function () {
- Y(R);
- };
- else if ('undefined' != typeof MessageChannel) {
- var pe = new MessageChannel(),
- de = pe.port2;
- (pe.port1.onmessage = R),
- (Z = function () {
- de.postMessage(null);
- });
- } else
- Z = function () {
- U(R, 0);
- };
- function I(s) {
- (ie = s), ee || ((ee = !0), Z());
- }
- function K(s, i) {
- ae = U(function () {
- s(o.unstable_now());
- }, i);
- }
- (o.unstable_IdlePriority = 5),
- (o.unstable_ImmediatePriority = 1),
- (o.unstable_LowPriority = 4),
- (o.unstable_NormalPriority = 3),
- (o.unstable_Profiling = null),
- (o.unstable_UserBlockingPriority = 2),
- (o.unstable_cancelCallback = function (s) {
- s.callback = null;
- }),
- (o.unstable_continueExecution = function () {
- $ || B || (($ = !0), I(J));
- }),
- (o.unstable_forceFrameRate = function (s) {
- 0 > s || 125 < s
- ? console.error(
- 'forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported'
- )
- : (le = 0 < s ? Math.floor(1e3 / s) : 5);
- }),
- (o.unstable_getCurrentPriorityLevel = function () {
- return L;
- }),
- (o.unstable_getFirstCallbackNode = function () {
- return h(w);
- }),
- (o.unstable_next = function (s) {
- switch (L) {
- case 1:
- case 2:
- case 3:
- var o = 3;
- break;
- default:
- o = L;
- }
- var i = L;
- L = o;
- try {
- return s();
- } finally {
- L = i;
- }
- }),
- (o.unstable_pauseExecution = function () {}),
- (o.unstable_requestPaint = function () {}),
- (o.unstable_runWithPriority = function (s, o) {
- switch (s) {
- case 1:
- case 2:
- case 3:
- case 4:
- case 5:
- break;
- default:
- s = 3;
- }
- var i = L;
- L = s;
- try {
- return o();
- } finally {
- L = i;
- }
- }),
- (o.unstable_scheduleCallback = function (s, i, u) {
- var _ = o.unstable_now();
- switch (
- ('object' == typeof u && null !== u
- ? (u = 'number' == typeof (u = u.delay) && 0 < u ? _ + u : _)
- : (u = _),
- s)
- ) {
- case 1:
- var j = -1;
- break;
- case 2:
- j = 250;
- break;
- case 5:
- j = 1073741823;
- break;
- case 4:
- j = 1e4;
- break;
- default:
- j = 5e3;
- }
- return (
- (s = {
- id: C++,
- callback: i,
- priorityLevel: s,
- startTime: u,
- expirationTime: (j = u + j),
- sortIndex: -1
- }),
- u > _
- ? ((s.sortIndex = u),
- f(x, s),
- null === h(w) && s === h(x) && (V ? (z(ae), (ae = -1)) : (V = !0), K(H, u - _)))
- : ((s.sortIndex = j), f(w, s), $ || B || (($ = !0), I(J))),
- s
- );
- }),
- (o.unstable_shouldYield = M),
- (o.unstable_wrapCallback = function (s) {
- var o = L;
- return function () {
- var i = L;
- L = o;
- try {
- return s.apply(this, arguments);
- } finally {
- L = i;
- }
- };
- });
- },
- 69982: (s, o, i) => {
- 'use strict';
- s.exports = i(29844);
- },
- 20334: (s, o, i) => {
- 'use strict';
- var u = i(48287).Buffer;
- class NonError extends Error {
- constructor(s) {
- super(NonError._prepareSuperMessage(s)),
- Object.defineProperty(this, 'name', {
- value: 'NonError',
- configurable: !0,
- writable: !0
- }),
- Error.captureStackTrace && Error.captureStackTrace(this, NonError);
- }
- static _prepareSuperMessage(s) {
- try {
- return JSON.stringify(s);
- } catch {
- return String(s);
- }
- }
- }
- const _ = [
- { property: 'name', enumerable: !1 },
- { property: 'message', enumerable: !1 },
- { property: 'stack', enumerable: !1 },
- { property: 'code', enumerable: !0 }
- ],
- w = Symbol('.toJSON called'),
- destroyCircular = ({
- from: s,
- seen: o,
- to_: i,
- forceEnumerable: x,
- maxDepth: C,
- depth: j
- }) => {
- const L = i || (Array.isArray(s) ? [] : {});
- if ((o.push(s), j >= C)) return L;
- if ('function' == typeof s.toJSON && !0 !== s[w])
- return ((s) => {
- s[w] = !0;
- const o = s.toJSON();
- return delete s[w], o;
- })(s);
- for (const [i, _] of Object.entries(s))
- 'function' == typeof u && u.isBuffer(_)
- ? (L[i] = '[object Buffer]')
- : 'function' != typeof _ &&
- (_ && 'object' == typeof _
- ? o.includes(s[i])
- ? (L[i] = '[Circular]')
- : (j++,
- (L[i] = destroyCircular({
- from: s[i],
- seen: o.slice(),
- forceEnumerable: x,
- maxDepth: C,
- depth: j
- })))
- : (L[i] = _));
- for (const { property: o, enumerable: i } of _)
- 'string' == typeof s[o] &&
- Object.defineProperty(L, o, {
- value: s[o],
- enumerable: !!x || i,
- configurable: !0,
- writable: !0
- });
- return L;
- };
- s.exports = {
- serializeError: (s, o = {}) => {
- const { maxDepth: i = Number.POSITIVE_INFINITY } = o;
- return 'object' == typeof s && null !== s
- ? destroyCircular({ from: s, seen: [], forceEnumerable: !0, maxDepth: i, depth: 0 })
- : 'function' == typeof s
- ? `[Function: ${s.name || 'anonymous'}]`
- : s;
- },
- deserializeError: (s, o = {}) => {
- const { maxDepth: i = Number.POSITIVE_INFINITY } = o;
- if (s instanceof Error) return s;
- if ('object' == typeof s && null !== s && !Array.isArray(s)) {
- const o = new Error();
- return destroyCircular({ from: s, seen: [], to_: o, maxDepth: i, depth: 0 }), o;
- }
- return new NonError(s);
- }
- };
- },
- 90392: (s, o, i) => {
- var u = i(92861).Buffer;
- function Hash(s, o) {
- (this._block = u.alloc(s)),
- (this._finalSize = o),
- (this._blockSize = s),
- (this._len = 0);
- }
- (Hash.prototype.update = function (s, o) {
- 'string' == typeof s && ((o = o || 'utf8'), (s = u.from(s, o)));
- for (
- var i = this._block, _ = this._blockSize, w = s.length, x = this._len, C = 0;
- C < w;
- ) {
- for (var j = x % _, L = Math.min(w - C, _ - j), B = 0; B < L; B++)
- i[j + B] = s[C + B];
- (C += L), (x += L) % _ == 0 && this._update(i);
- }
- return (this._len += w), this;
- }),
- (Hash.prototype.digest = function (s) {
- var o = this._len % this._blockSize;
- (this._block[o] = 128),
- this._block.fill(0, o + 1),
- o >= this._finalSize && (this._update(this._block), this._block.fill(0));
- var i = 8 * this._len;
- if (i <= 4294967295) this._block.writeUInt32BE(i, this._blockSize - 4);
- else {
- var u = (4294967295 & i) >>> 0,
- _ = (i - u) / 4294967296;
- this._block.writeUInt32BE(_, this._blockSize - 8),
- this._block.writeUInt32BE(u, this._blockSize - 4);
- }
- this._update(this._block);
- var w = this._hash();
- return s ? w.toString(s) : w;
- }),
- (Hash.prototype._update = function () {
- throw new Error('_update must be implemented by subclass');
- }),
- (s.exports = Hash);
- },
- 62802: (s, o, i) => {
- var u = (s.exports = function SHA(s) {
- s = s.toLowerCase();
- var o = u[s];
- if (!o) throw new Error(s + ' is not supported (we accept pull requests)');
- return new o();
- });
- (u.sha = i(27816)),
- (u.sha1 = i(63737)),
- (u.sha224 = i(26710)),
- (u.sha256 = i(24107)),
- (u.sha384 = i(32827)),
- (u.sha512 = i(82890));
- },
- 27816: (s, o, i) => {
- var u = i(56698),
- _ = i(90392),
- w = i(92861).Buffer,
- x = [1518500249, 1859775393, -1894007588, -899497514],
- C = new Array(80);
- function Sha() {
- this.init(), (this._w = C), _.call(this, 64, 56);
- }
- function rotl30(s) {
- return (s << 30) | (s >>> 2);
- }
- function ft(s, o, i, u) {
- return 0 === s ? (o & i) | (~o & u) : 2 === s ? (o & i) | (o & u) | (i & u) : o ^ i ^ u;
- }
- u(Sha, _),
- (Sha.prototype.init = function () {
- return (
- (this._a = 1732584193),
- (this._b = 4023233417),
- (this._c = 2562383102),
- (this._d = 271733878),
- (this._e = 3285377520),
- this
- );
- }),
- (Sha.prototype._update = function (s) {
- for (
- var o,
- i = this._w,
- u = 0 | this._a,
- _ = 0 | this._b,
- w = 0 | this._c,
- C = 0 | this._d,
- j = 0 | this._e,
- L = 0;
- L < 16;
- ++L
- )
- i[L] = s.readInt32BE(4 * L);
- for (; L < 80; ++L) i[L] = i[L - 3] ^ i[L - 8] ^ i[L - 14] ^ i[L - 16];
- for (var B = 0; B < 80; ++B) {
- var $ = ~~(B / 20),
- V = 0 | ((((o = u) << 5) | (o >>> 27)) + ft($, _, w, C) + j + i[B] + x[$]);
- (j = C), (C = w), (w = rotl30(_)), (_ = u), (u = V);
- }
- (this._a = (u + this._a) | 0),
- (this._b = (_ + this._b) | 0),
- (this._c = (w + this._c) | 0),
- (this._d = (C + this._d) | 0),
- (this._e = (j + this._e) | 0);
- }),
- (Sha.prototype._hash = function () {
- var s = w.allocUnsafe(20);
- return (
- s.writeInt32BE(0 | this._a, 0),
- s.writeInt32BE(0 | this._b, 4),
- s.writeInt32BE(0 | this._c, 8),
- s.writeInt32BE(0 | this._d, 12),
- s.writeInt32BE(0 | this._e, 16),
- s
- );
- }),
- (s.exports = Sha);
- },
- 63737: (s, o, i) => {
- var u = i(56698),
- _ = i(90392),
- w = i(92861).Buffer,
- x = [1518500249, 1859775393, -1894007588, -899497514],
- C = new Array(80);
- function Sha1() {
- this.init(), (this._w = C), _.call(this, 64, 56);
- }
- function rotl5(s) {
- return (s << 5) | (s >>> 27);
- }
- function rotl30(s) {
- return (s << 30) | (s >>> 2);
- }
- function ft(s, o, i, u) {
- return 0 === s ? (o & i) | (~o & u) : 2 === s ? (o & i) | (o & u) | (i & u) : o ^ i ^ u;
- }
- u(Sha1, _),
- (Sha1.prototype.init = function () {
- return (
- (this._a = 1732584193),
- (this._b = 4023233417),
- (this._c = 2562383102),
- (this._d = 271733878),
- (this._e = 3285377520),
- this
- );
- }),
- (Sha1.prototype._update = function (s) {
- for (
- var o,
- i = this._w,
- u = 0 | this._a,
- _ = 0 | this._b,
- w = 0 | this._c,
- C = 0 | this._d,
- j = 0 | this._e,
- L = 0;
- L < 16;
- ++L
- )
- i[L] = s.readInt32BE(4 * L);
- for (; L < 80; ++L)
- i[L] = ((o = i[L - 3] ^ i[L - 8] ^ i[L - 14] ^ i[L - 16]) << 1) | (o >>> 31);
- for (var B = 0; B < 80; ++B) {
- var $ = ~~(B / 20),
- V = (rotl5(u) + ft($, _, w, C) + j + i[B] + x[$]) | 0;
- (j = C), (C = w), (w = rotl30(_)), (_ = u), (u = V);
- }
- (this._a = (u + this._a) | 0),
- (this._b = (_ + this._b) | 0),
- (this._c = (w + this._c) | 0),
- (this._d = (C + this._d) | 0),
- (this._e = (j + this._e) | 0);
- }),
- (Sha1.prototype._hash = function () {
- var s = w.allocUnsafe(20);
- return (
- s.writeInt32BE(0 | this._a, 0),
- s.writeInt32BE(0 | this._b, 4),
- s.writeInt32BE(0 | this._c, 8),
- s.writeInt32BE(0 | this._d, 12),
- s.writeInt32BE(0 | this._e, 16),
- s
- );
- }),
- (s.exports = Sha1);
- },
- 26710: (s, o, i) => {
- var u = i(56698),
- _ = i(24107),
- w = i(90392),
- x = i(92861).Buffer,
- C = new Array(64);
- function Sha224() {
- this.init(), (this._w = C), w.call(this, 64, 56);
- }
- u(Sha224, _),
- (Sha224.prototype.init = function () {
- return (
- (this._a = 3238371032),
- (this._b = 914150663),
- (this._c = 812702999),
- (this._d = 4144912697),
- (this._e = 4290775857),
- (this._f = 1750603025),
- (this._g = 1694076839),
- (this._h = 3204075428),
- this
- );
- }),
- (Sha224.prototype._hash = function () {
- var s = x.allocUnsafe(28);
- return (
- s.writeInt32BE(this._a, 0),
- s.writeInt32BE(this._b, 4),
- s.writeInt32BE(this._c, 8),
- s.writeInt32BE(this._d, 12),
- s.writeInt32BE(this._e, 16),
- s.writeInt32BE(this._f, 20),
- s.writeInt32BE(this._g, 24),
- s
- );
- }),
- (s.exports = Sha224);
- },
- 24107: (s, o, i) => {
- var u = i(56698),
- _ = i(90392),
- w = i(92861).Buffer,
- x = [
- 1116352408, 1899447441, 3049323471, 3921009573, 961987163, 1508970993, 2453635748,
- 2870763221, 3624381080, 310598401, 607225278, 1426881987, 1925078388, 2162078206,
- 2614888103, 3248222580, 3835390401, 4022224774, 264347078, 604807628, 770255983,
- 1249150122, 1555081692, 1996064986, 2554220882, 2821834349, 2952996808, 3210313671,
- 3336571891, 3584528711, 113926993, 338241895, 666307205, 773529912, 1294757372,
- 1396182291, 1695183700, 1986661051, 2177026350, 2456956037, 2730485921, 2820302411,
- 3259730800, 3345764771, 3516065817, 3600352804, 4094571909, 275423344, 430227734,
- 506948616, 659060556, 883997877, 958139571, 1322822218, 1537002063, 1747873779,
- 1955562222, 2024104815, 2227730452, 2361852424, 2428436474, 2756734187, 3204031479,
- 3329325298
- ],
- C = new Array(64);
- function Sha256() {
- this.init(), (this._w = C), _.call(this, 64, 56);
- }
- function ch(s, o, i) {
- return i ^ (s & (o ^ i));
- }
- function maj(s, o, i) {
- return (s & o) | (i & (s | o));
- }
- function sigma0(s) {
- return ((s >>> 2) | (s << 30)) ^ ((s >>> 13) | (s << 19)) ^ ((s >>> 22) | (s << 10));
- }
- function sigma1(s) {
- return ((s >>> 6) | (s << 26)) ^ ((s >>> 11) | (s << 21)) ^ ((s >>> 25) | (s << 7));
- }
- function gamma0(s) {
- return ((s >>> 7) | (s << 25)) ^ ((s >>> 18) | (s << 14)) ^ (s >>> 3);
- }
- u(Sha256, _),
- (Sha256.prototype.init = function () {
- return (
- (this._a = 1779033703),
- (this._b = 3144134277),
- (this._c = 1013904242),
- (this._d = 2773480762),
- (this._e = 1359893119),
- (this._f = 2600822924),
- (this._g = 528734635),
- (this._h = 1541459225),
- this
- );
- }),
- (Sha256.prototype._update = function (s) {
- for (
- var o,
- i = this._w,
- u = 0 | this._a,
- _ = 0 | this._b,
- w = 0 | this._c,
- C = 0 | this._d,
- j = 0 | this._e,
- L = 0 | this._f,
- B = 0 | this._g,
- $ = 0 | this._h,
- V = 0;
- V < 16;
- ++V
- )
- i[V] = s.readInt32BE(4 * V);
- for (; V < 64; ++V)
- i[V] =
- 0 |
- (((((o = i[V - 2]) >>> 17) | (o << 15)) ^ ((o >>> 19) | (o << 13)) ^ (o >>> 10)) +
- i[V - 7] +
- gamma0(i[V - 15]) +
- i[V - 16]);
- for (var U = 0; U < 64; ++U) {
- var z = ($ + sigma1(j) + ch(j, L, B) + x[U] + i[U]) | 0,
- Y = (sigma0(u) + maj(u, _, w)) | 0;
- ($ = B),
- (B = L),
- (L = j),
- (j = (C + z) | 0),
- (C = w),
- (w = _),
- (_ = u),
- (u = (z + Y) | 0);
- }
- (this._a = (u + this._a) | 0),
- (this._b = (_ + this._b) | 0),
- (this._c = (w + this._c) | 0),
- (this._d = (C + this._d) | 0),
- (this._e = (j + this._e) | 0),
- (this._f = (L + this._f) | 0),
- (this._g = (B + this._g) | 0),
- (this._h = ($ + this._h) | 0);
- }),
- (Sha256.prototype._hash = function () {
- var s = w.allocUnsafe(32);
- return (
- s.writeInt32BE(this._a, 0),
- s.writeInt32BE(this._b, 4),
- s.writeInt32BE(this._c, 8),
- s.writeInt32BE(this._d, 12),
- s.writeInt32BE(this._e, 16),
- s.writeInt32BE(this._f, 20),
- s.writeInt32BE(this._g, 24),
- s.writeInt32BE(this._h, 28),
- s
- );
- }),
- (s.exports = Sha256);
- },
- 32827: (s, o, i) => {
- var u = i(56698),
- _ = i(82890),
- w = i(90392),
- x = i(92861).Buffer,
- C = new Array(160);
- function Sha384() {
- this.init(), (this._w = C), w.call(this, 128, 112);
- }
- u(Sha384, _),
- (Sha384.prototype.init = function () {
- return (
- (this._ah = 3418070365),
- (this._bh = 1654270250),
- (this._ch = 2438529370),
- (this._dh = 355462360),
- (this._eh = 1731405415),
- (this._fh = 2394180231),
- (this._gh = 3675008525),
- (this._hh = 1203062813),
- (this._al = 3238371032),
- (this._bl = 914150663),
- (this._cl = 812702999),
- (this._dl = 4144912697),
- (this._el = 4290775857),
- (this._fl = 1750603025),
- (this._gl = 1694076839),
- (this._hl = 3204075428),
- this
- );
- }),
- (Sha384.prototype._hash = function () {
- var s = x.allocUnsafe(48);
- function writeInt64BE(o, i, u) {
- s.writeInt32BE(o, u), s.writeInt32BE(i, u + 4);
- }
- return (
- writeInt64BE(this._ah, this._al, 0),
- writeInt64BE(this._bh, this._bl, 8),
- writeInt64BE(this._ch, this._cl, 16),
- writeInt64BE(this._dh, this._dl, 24),
- writeInt64BE(this._eh, this._el, 32),
- writeInt64BE(this._fh, this._fl, 40),
- s
- );
- }),
- (s.exports = Sha384);
- },
- 82890: (s, o, i) => {
- var u = i(56698),
- _ = i(90392),
- w = i(92861).Buffer,
- x = [
- 1116352408, 3609767458, 1899447441, 602891725, 3049323471, 3964484399, 3921009573,
- 2173295548, 961987163, 4081628472, 1508970993, 3053834265, 2453635748, 2937671579,
- 2870763221, 3664609560, 3624381080, 2734883394, 310598401, 1164996542, 607225278,
- 1323610764, 1426881987, 3590304994, 1925078388, 4068182383, 2162078206, 991336113,
- 2614888103, 633803317, 3248222580, 3479774868, 3835390401, 2666613458, 4022224774,
- 944711139, 264347078, 2341262773, 604807628, 2007800933, 770255983, 1495990901,
- 1249150122, 1856431235, 1555081692, 3175218132, 1996064986, 2198950837, 2554220882,
- 3999719339, 2821834349, 766784016, 2952996808, 2566594879, 3210313671, 3203337956,
- 3336571891, 1034457026, 3584528711, 2466948901, 113926993, 3758326383, 338241895,
- 168717936, 666307205, 1188179964, 773529912, 1546045734, 1294757372, 1522805485,
- 1396182291, 2643833823, 1695183700, 2343527390, 1986661051, 1014477480, 2177026350,
- 1206759142, 2456956037, 344077627, 2730485921, 1290863460, 2820302411, 3158454273,
- 3259730800, 3505952657, 3345764771, 106217008, 3516065817, 3606008344, 3600352804,
- 1432725776, 4094571909, 1467031594, 275423344, 851169720, 430227734, 3100823752,
- 506948616, 1363258195, 659060556, 3750685593, 883997877, 3785050280, 958139571,
- 3318307427, 1322822218, 3812723403, 1537002063, 2003034995, 1747873779, 3602036899,
- 1955562222, 1575990012, 2024104815, 1125592928, 2227730452, 2716904306, 2361852424,
- 442776044, 2428436474, 593698344, 2756734187, 3733110249, 3204031479, 2999351573,
- 3329325298, 3815920427, 3391569614, 3928383900, 3515267271, 566280711, 3940187606,
- 3454069534, 4118630271, 4000239992, 116418474, 1914138554, 174292421, 2731055270,
- 289380356, 3203993006, 460393269, 320620315, 685471733, 587496836, 852142971,
- 1086792851, 1017036298, 365543100, 1126000580, 2618297676, 1288033470, 3409855158,
- 1501505948, 4234509866, 1607167915, 987167468, 1816402316, 1246189591
- ],
- C = new Array(160);
- function Sha512() {
- this.init(), (this._w = C), _.call(this, 128, 112);
- }
- function Ch(s, o, i) {
- return i ^ (s & (o ^ i));
- }
- function maj(s, o, i) {
- return (s & o) | (i & (s | o));
- }
- function sigma0(s, o) {
- return ((s >>> 28) | (o << 4)) ^ ((o >>> 2) | (s << 30)) ^ ((o >>> 7) | (s << 25));
- }
- function sigma1(s, o) {
- return ((s >>> 14) | (o << 18)) ^ ((s >>> 18) | (o << 14)) ^ ((o >>> 9) | (s << 23));
- }
- function Gamma0(s, o) {
- return ((s >>> 1) | (o << 31)) ^ ((s >>> 8) | (o << 24)) ^ (s >>> 7);
- }
- function Gamma0l(s, o) {
- return ((s >>> 1) | (o << 31)) ^ ((s >>> 8) | (o << 24)) ^ ((s >>> 7) | (o << 25));
- }
- function Gamma1(s, o) {
- return ((s >>> 19) | (o << 13)) ^ ((o >>> 29) | (s << 3)) ^ (s >>> 6);
- }
- function Gamma1l(s, o) {
- return ((s >>> 19) | (o << 13)) ^ ((o >>> 29) | (s << 3)) ^ ((s >>> 6) | (o << 26));
- }
- function getCarry(s, o) {
- return s >>> 0 < o >>> 0 ? 1 : 0;
- }
- u(Sha512, _),
- (Sha512.prototype.init = function () {
- return (
- (this._ah = 1779033703),
- (this._bh = 3144134277),
- (this._ch = 1013904242),
- (this._dh = 2773480762),
- (this._eh = 1359893119),
- (this._fh = 2600822924),
- (this._gh = 528734635),
- (this._hh = 1541459225),
- (this._al = 4089235720),
- (this._bl = 2227873595),
- (this._cl = 4271175723),
- (this._dl = 1595750129),
- (this._el = 2917565137),
- (this._fl = 725511199),
- (this._gl = 4215389547),
- (this._hl = 327033209),
- this
- );
- }),
- (Sha512.prototype._update = function (s) {
- for (
- var o = this._w,
- i = 0 | this._ah,
- u = 0 | this._bh,
- _ = 0 | this._ch,
- w = 0 | this._dh,
- C = 0 | this._eh,
- j = 0 | this._fh,
- L = 0 | this._gh,
- B = 0 | this._hh,
- $ = 0 | this._al,
- V = 0 | this._bl,
- U = 0 | this._cl,
- z = 0 | this._dl,
- Y = 0 | this._el,
- Z = 0 | this._fl,
- ee = 0 | this._gl,
- ie = 0 | this._hl,
- ae = 0;
- ae < 32;
- ae += 2
- )
- (o[ae] = s.readInt32BE(4 * ae)), (o[ae + 1] = s.readInt32BE(4 * ae + 4));
- for (; ae < 160; ae += 2) {
- var le = o[ae - 30],
- ce = o[ae - 30 + 1],
- pe = Gamma0(le, ce),
- de = Gamma0l(ce, le),
- fe = Gamma1((le = o[ae - 4]), (ce = o[ae - 4 + 1])),
- ye = Gamma1l(ce, le),
- be = o[ae - 14],
- _e = o[ae - 14 + 1],
- we = o[ae - 32],
- Se = o[ae - 32 + 1],
- xe = (de + _e) | 0,
- Pe = (pe + be + getCarry(xe, de)) | 0;
- (Pe =
- ((Pe = (Pe + fe + getCarry((xe = (xe + ye) | 0), ye)) | 0) +
- we +
- getCarry((xe = (xe + Se) | 0), Se)) |
- 0),
- (o[ae] = Pe),
- (o[ae + 1] = xe);
- }
- for (var Te = 0; Te < 160; Te += 2) {
- (Pe = o[Te]), (xe = o[Te + 1]);
- var Re = maj(i, u, _),
- qe = maj($, V, U),
- $e = sigma0(i, $),
- ze = sigma0($, i),
- We = sigma1(C, Y),
- He = sigma1(Y, C),
- Ye = x[Te],
- Xe = x[Te + 1],
- Qe = Ch(C, j, L),
- et = Ch(Y, Z, ee),
- tt = (ie + He) | 0,
- rt = (B + We + getCarry(tt, ie)) | 0;
- rt =
- ((rt =
- ((rt = (rt + Qe + getCarry((tt = (tt + et) | 0), et)) | 0) +
- Ye +
- getCarry((tt = (tt + Xe) | 0), Xe)) |
- 0) +
- Pe +
- getCarry((tt = (tt + xe) | 0), xe)) |
- 0;
- var nt = (ze + qe) | 0,
- st = ($e + Re + getCarry(nt, ze)) | 0;
- (B = L),
- (ie = ee),
- (L = j),
- (ee = Z),
- (j = C),
- (Z = Y),
- (C = (w + rt + getCarry((Y = (z + tt) | 0), z)) | 0),
- (w = _),
- (z = U),
- (_ = u),
- (U = V),
- (u = i),
- (V = $),
- (i = (rt + st + getCarry(($ = (tt + nt) | 0), tt)) | 0);
- }
- (this._al = (this._al + $) | 0),
- (this._bl = (this._bl + V) | 0),
- (this._cl = (this._cl + U) | 0),
- (this._dl = (this._dl + z) | 0),
- (this._el = (this._el + Y) | 0),
- (this._fl = (this._fl + Z) | 0),
- (this._gl = (this._gl + ee) | 0),
- (this._hl = (this._hl + ie) | 0),
- (this._ah = (this._ah + i + getCarry(this._al, $)) | 0),
- (this._bh = (this._bh + u + getCarry(this._bl, V)) | 0),
- (this._ch = (this._ch + _ + getCarry(this._cl, U)) | 0),
- (this._dh = (this._dh + w + getCarry(this._dl, z)) | 0),
- (this._eh = (this._eh + C + getCarry(this._el, Y)) | 0),
- (this._fh = (this._fh + j + getCarry(this._fl, Z)) | 0),
- (this._gh = (this._gh + L + getCarry(this._gl, ee)) | 0),
- (this._hh = (this._hh + B + getCarry(this._hl, ie)) | 0);
- }),
- (Sha512.prototype._hash = function () {
- var s = w.allocUnsafe(64);
- function writeInt64BE(o, i, u) {
- s.writeInt32BE(o, u), s.writeInt32BE(i, u + 4);
- }
- return (
- writeInt64BE(this._ah, this._al, 0),
- writeInt64BE(this._bh, this._bl, 8),
- writeInt64BE(this._ch, this._cl, 16),
- writeInt64BE(this._dh, this._dl, 24),
- writeInt64BE(this._eh, this._el, 32),
- writeInt64BE(this._fh, this._fl, 40),
- writeInt64BE(this._gh, this._gl, 48),
- writeInt64BE(this._hh, this._hl, 56),
- s
- );
- }),
- (s.exports = Sha512);
- },
- 8068: (s) => {
- 'use strict';
- var o = (() => {
- var s = Object.defineProperty,
- o = Object.getOwnPropertyDescriptor,
- i = Object.getOwnPropertyNames,
- u = Object.getOwnPropertySymbols,
- _ = Object.prototype.hasOwnProperty,
- w = Object.prototype.propertyIsEnumerable,
- __defNormalProp = (o, i, u) =>
- i in o
- ? s(o, i, { enumerable: !0, configurable: !0, writable: !0, value: u })
- : (o[i] = u),
- __spreadValues = (s, o) => {
- for (var i in o || (o = {})) _.call(o, i) && __defNormalProp(s, i, o[i]);
- if (u) for (var i of u(o)) w.call(o, i) && __defNormalProp(s, i, o[i]);
- return s;
- },
- __publicField = (s, o, i) => (
- __defNormalProp(s, 'symbol' != typeof o ? o + '' : o, i), i
- ),
- x = {};
- ((o, i) => {
- for (var u in i) s(o, u, { get: i[u], enumerable: !0 });
- })(x, { DEFAULT_OPTIONS: () => j, DEFAULT_UUID_LENGTH: () => C, default: () => $ });
- var C = 6,
- j = { dictionary: 'alphanum', shuffle: !0, debug: !1, length: C, counter: 0 },
- L = class _ShortUniqueId {
- constructor(s = {}) {
- __publicField(this, 'counter'),
- __publicField(this, 'debug'),
- __publicField(this, 'dict'),
- __publicField(this, 'version'),
- __publicField(this, 'dictIndex', 0),
- __publicField(this, 'dictRange', []),
- __publicField(this, 'lowerBound', 0),
- __publicField(this, 'upperBound', 0),
- __publicField(this, 'dictLength', 0),
- __publicField(this, 'uuidLength'),
- __publicField(this, '_digit_first_ascii', 48),
- __publicField(this, '_digit_last_ascii', 58),
- __publicField(this, '_alpha_lower_first_ascii', 97),
- __publicField(this, '_alpha_lower_last_ascii', 123),
- __publicField(this, '_hex_last_ascii', 103),
- __publicField(this, '_alpha_upper_first_ascii', 65),
- __publicField(this, '_alpha_upper_last_ascii', 91),
- __publicField(this, '_number_dict_ranges', {
- digits: [this._digit_first_ascii, this._digit_last_ascii]
- }),
- __publicField(this, '_alpha_dict_ranges', {
- lowerCase: [this._alpha_lower_first_ascii, this._alpha_lower_last_ascii],
- upperCase: [this._alpha_upper_first_ascii, this._alpha_upper_last_ascii]
- }),
- __publicField(this, '_alpha_lower_dict_ranges', {
- lowerCase: [this._alpha_lower_first_ascii, this._alpha_lower_last_ascii]
- }),
- __publicField(this, '_alpha_upper_dict_ranges', {
- upperCase: [this._alpha_upper_first_ascii, this._alpha_upper_last_ascii]
- }),
- __publicField(this, '_alphanum_dict_ranges', {
- digits: [this._digit_first_ascii, this._digit_last_ascii],
- lowerCase: [this._alpha_lower_first_ascii, this._alpha_lower_last_ascii],
- upperCase: [this._alpha_upper_first_ascii, this._alpha_upper_last_ascii]
- }),
- __publicField(this, '_alphanum_lower_dict_ranges', {
- digits: [this._digit_first_ascii, this._digit_last_ascii],
- lowerCase: [this._alpha_lower_first_ascii, this._alpha_lower_last_ascii]
- }),
- __publicField(this, '_alphanum_upper_dict_ranges', {
- digits: [this._digit_first_ascii, this._digit_last_ascii],
- upperCase: [this._alpha_upper_first_ascii, this._alpha_upper_last_ascii]
- }),
- __publicField(this, '_hex_dict_ranges', {
- decDigits: [this._digit_first_ascii, this._digit_last_ascii],
- alphaDigits: [this._alpha_lower_first_ascii, this._hex_last_ascii]
- }),
- __publicField(this, '_dict_ranges', {
- _number_dict_ranges: this._number_dict_ranges,
- _alpha_dict_ranges: this._alpha_dict_ranges,
- _alpha_lower_dict_ranges: this._alpha_lower_dict_ranges,
- _alpha_upper_dict_ranges: this._alpha_upper_dict_ranges,
- _alphanum_dict_ranges: this._alphanum_dict_ranges,
- _alphanum_lower_dict_ranges: this._alphanum_lower_dict_ranges,
- _alphanum_upper_dict_ranges: this._alphanum_upper_dict_ranges,
- _hex_dict_ranges: this._hex_dict_ranges
- }),
- __publicField(this, 'log', (...s) => {
- const o = [...s];
- if (
- ((o[0] = `[short-unique-id] ${s[0]}`),
- !0 === this.debug && 'undefined' != typeof console && null !== console)
- )
- return console.log(...o);
- }),
- __publicField(this, '_normalizeDictionary', (s, o) => {
- let i;
- if (s && Array.isArray(s) && s.length > 1) i = s;
- else {
- let o;
- (i = []), (this.dictIndex = o = 0);
- const u = `_${s}_dict_ranges`,
- _ = this._dict_ranges[u];
- Object.keys(_).forEach((s) => {
- const u = s;
- for (
- this.dictRange = _[u],
- this.lowerBound = this.dictRange[0],
- this.upperBound = this.dictRange[1],
- this.dictIndex = o = this.lowerBound;
- this.lowerBound <= this.upperBound
- ? o < this.upperBound
- : o > this.upperBound;
- this.dictIndex =
- this.lowerBound <= this.upperBound ? (o += 1) : (o -= 1)
- )
- i.push(String.fromCharCode(this.dictIndex));
- });
- }
- if (o) {
- const s = 0.5;
- i = i.sort(() => Math.random() - s);
- }
- return i;
- }),
- __publicField(this, 'setDictionary', (s, o) => {
- (this.dict = this._normalizeDictionary(s, o)),
- (this.dictLength = this.dict.length),
- this.setCounter(0);
- }),
- __publicField(this, 'seq', () => this.sequentialUUID()),
- __publicField(this, 'sequentialUUID', () => {
- let s,
- o,
- i = '';
- s = this.counter;
- do {
- (o = s % this.dictLength),
- (s = Math.trunc(s / this.dictLength)),
- (i += this.dict[o]);
- } while (0 !== s);
- return (this.counter += 1), i;
- }),
- __publicField(this, 'rnd', (s = this.uuidLength || C) => this.randomUUID(s)),
- __publicField(this, 'randomUUID', (s = this.uuidLength || C) => {
- let o, i, u;
- if (null == s || s < 1) throw new Error('Invalid UUID Length Provided');
- for (o = '', u = 0; u < s; u += 1)
- (i =
- parseInt((Math.random() * this.dictLength).toFixed(0), 10) %
- this.dictLength),
- (o += this.dict[i]);
- return o;
- }),
- __publicField(this, 'fmt', (s, o) => this.formattedUUID(s, o)),
- __publicField(this, 'formattedUUID', (s, o) => {
- const i = { $r: this.randomUUID, $s: this.sequentialUUID, $t: this.stamp };
- return s.replace(/\$[rs]\d{0,}|\$t0|\$t[1-9]\d{1,}/g, (s) => {
- const u = s.slice(0, 2),
- _ = parseInt(s.slice(2), 10);
- return '$s' === u
- ? i[u]().padStart(_, '0')
- : '$t' === u && o
- ? i[u](_, o)
- : i[u](_);
- });
- }),
- __publicField(this, 'availableUUIDs', (s = this.uuidLength) =>
- parseFloat(Math.pow([...new Set(this.dict)].length, s).toFixed(0))
- ),
- __publicField(
- this,
- 'approxMaxBeforeCollision',
- (s = this.availableUUIDs(this.uuidLength)) =>
- parseFloat(Math.sqrt((Math.PI / 2) * s).toFixed(20))
- ),
- __publicField(
- this,
- 'collisionProbability',
- (s = this.availableUUIDs(this.uuidLength), o = this.uuidLength) =>
- parseFloat(
- (this.approxMaxBeforeCollision(s) / this.availableUUIDs(o)).toFixed(20)
- )
- ),
- __publicField(
- this,
- 'uniqueness',
- (s = this.availableUUIDs(this.uuidLength)) => {
- const o = parseFloat(
- (1 - this.approxMaxBeforeCollision(s) / s).toFixed(20)
- );
- return o > 1 ? 1 : o < 0 ? 0 : o;
- }
- ),
- __publicField(this, 'getVersion', () => this.version),
- __publicField(this, 'stamp', (s, o) => {
- const i = Math.floor(+(o || new Date()) / 1e3).toString(16);
- if ('number' == typeof s && 0 === s) return i;
- if ('number' != typeof s || s < 10)
- throw new Error(
- [
- 'Param finalLength must be a number greater than or equal to 10,',
- 'or 0 if you want the raw hexadecimal timestamp'
- ].join('\n')
- );
- const u = s - 9,
- _ = Math.round(Math.random() * (u > 15 ? 15 : u)),
- w = this.randomUUID(u);
- return `${w.substring(0, _)}${i}${w.substring(_)}${_.toString(16)}`;
- }),
- __publicField(this, 'parseStamp', (s, o) => {
- if (o && !/t0|t[1-9]\d{1,}/.test(o))
- throw new Error(
- 'Cannot extract date from a formated UUID with no timestamp in the format'
- );
- const i = o
- ? o
- .replace(/\$[rs]\d{0,}|\$t0|\$t[1-9]\d{1,}/g, (s) => {
- const o = {
- $r: (s) => [...Array(s)].map(() => 'r').join(''),
- $s: (s) => [...Array(s)].map(() => 's').join(''),
- $t: (s) => [...Array(s)].map(() => 't').join('')
- },
- i = s.slice(0, 2),
- u = parseInt(s.slice(2), 10);
- return o[i](u);
- })
- .replace(/^(.*?)(t{8,})(.*)$/g, (o, i, u) =>
- s.substring(i.length, i.length + u.length)
- )
- : s;
- if (8 === i.length) return new Date(1e3 * parseInt(i, 16));
- if (i.length < 10) throw new Error('Stamp length invalid');
- const u = parseInt(i.substring(i.length - 1), 16);
- return new Date(1e3 * parseInt(i.substring(u, u + 8), 16));
- }),
- __publicField(this, 'setCounter', (s) => {
- this.counter = s;
- }),
- __publicField(this, 'validate', (s, o) => {
- const i = o ? this._normalizeDictionary(o) : this.dict;
- return s.split('').every((s) => i.includes(s));
- });
- const o = __spreadValues(__spreadValues({}, j), s);
- (this.counter = 0), (this.debug = !1), (this.dict = []), (this.version = '5.2.0');
- const { dictionary: i, shuffle: u, length: _, counter: w } = o;
- return (
- (this.uuidLength = _),
- this.setDictionary(i, u),
- this.setCounter(w),
- (this.debug = o.debug),
- this.log(this.dict),
- this.log(
- `Generator instantiated with Dictionary Size ${this.dictLength} and counter set to ${this.counter}`
- ),
- (this.log = this.log.bind(this)),
- (this.setDictionary = this.setDictionary.bind(this)),
- (this.setCounter = this.setCounter.bind(this)),
- (this.seq = this.seq.bind(this)),
- (this.sequentialUUID = this.sequentialUUID.bind(this)),
- (this.rnd = this.rnd.bind(this)),
- (this.randomUUID = this.randomUUID.bind(this)),
- (this.fmt = this.fmt.bind(this)),
- (this.formattedUUID = this.formattedUUID.bind(this)),
- (this.availableUUIDs = this.availableUUIDs.bind(this)),
- (this.approxMaxBeforeCollision = this.approxMaxBeforeCollision.bind(this)),
- (this.collisionProbability = this.collisionProbability.bind(this)),
- (this.uniqueness = this.uniqueness.bind(this)),
- (this.getVersion = this.getVersion.bind(this)),
- (this.stamp = this.stamp.bind(this)),
- (this.parseStamp = this.parseStamp.bind(this)),
- this
- );
- }
- };
- __publicField(L, 'default', L);
- var B,
- $ = L;
- return (
- (B = x),
- ((u, w, x, C) => {
- if ((w && 'object' == typeof w) || 'function' == typeof w)
- for (let j of i(w))
- _.call(u, j) ||
- j === x ||
- s(u, j, { get: () => w[j], enumerable: !(C = o(w, j)) || C.enumerable });
- return u;
- })(s({}, '__esModule', { value: !0 }), B)
- );
- })();
- (s.exports = o.default), 'undefined' != typeof window && (o = o.default);
- },
- 88310: (s, o, i) => {
- s.exports = Stream;
- var u = i(37007).EventEmitter;
- function Stream() {
- u.call(this);
- }
- i(56698)(Stream, u),
- (Stream.Readable = i(45412)),
- (Stream.Writable = i(16708)),
- (Stream.Duplex = i(25382)),
- (Stream.Transform = i(74610)),
- (Stream.PassThrough = i(63600)),
- (Stream.finished = i(86238)),
- (Stream.pipeline = i(57758)),
- (Stream.Stream = Stream),
- (Stream.prototype.pipe = function (s, o) {
- var i = this;
- function ondata(o) {
- s.writable && !1 === s.write(o) && i.pause && i.pause();
- }
- function ondrain() {
- i.readable && i.resume && i.resume();
- }
- i.on('data', ondata),
- s.on('drain', ondrain),
- s._isStdio || (o && !1 === o.end) || (i.on('end', onend), i.on('close', onclose));
- var _ = !1;
- function onend() {
- _ || ((_ = !0), s.end());
- }
- function onclose() {
- _ || ((_ = !0), 'function' == typeof s.destroy && s.destroy());
- }
- function onerror(s) {
- if ((cleanup(), 0 === u.listenerCount(this, 'error'))) throw s;
- }
- function cleanup() {
- i.removeListener('data', ondata),
- s.removeListener('drain', ondrain),
- i.removeListener('end', onend),
- i.removeListener('close', onclose),
- i.removeListener('error', onerror),
- s.removeListener('error', onerror),
- i.removeListener('end', cleanup),
- i.removeListener('close', cleanup),
- s.removeListener('close', cleanup);
- }
- return (
- i.on('error', onerror),
- s.on('error', onerror),
- i.on('end', cleanup),
- i.on('close', cleanup),
- s.on('close', cleanup),
- s.emit('pipe', i),
- s
- );
- });
- },
- 83141: (s, o, i) => {
- 'use strict';
- var u = i(92861).Buffer,
- _ =
- u.isEncoding ||
- function (s) {
- switch ((s = '' + s) && s.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 StringDecoder(s) {
- var o;
- switch (
- ((this.encoding = (function normalizeEncoding(s) {
- var o = (function _normalizeEncoding(s) {
- if (!s) return 'utf8';
- for (var o; ; )
- switch (s) {
- 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 s;
- default:
- if (o) return;
- (s = ('' + s).toLowerCase()), (o = !0);
- }
- })(s);
- if ('string' != typeof o && (u.isEncoding === _ || !_(s)))
- throw new Error('Unknown encoding: ' + s);
- return o || s;
- })(s)),
- this.encoding)
- ) {
- case 'utf16le':
- (this.text = utf16Text), (this.end = utf16End), (o = 4);
- break;
- case 'utf8':
- (this.fillLast = utf8FillLast), (o = 4);
- break;
- case 'base64':
- (this.text = base64Text), (this.end = base64End), (o = 3);
- break;
- default:
- return (this.write = simpleWrite), void (this.end = simpleEnd);
- }
- (this.lastNeed = 0), (this.lastTotal = 0), (this.lastChar = u.allocUnsafe(o));
- }
- function utf8CheckByte(s) {
- return s <= 127
- ? 0
- : s >> 5 == 6
- ? 2
- : s >> 4 == 14
- ? 3
- : s >> 3 == 30
- ? 4
- : s >> 6 == 2
- ? -1
- : -2;
- }
- function utf8FillLast(s) {
- var o = this.lastTotal - this.lastNeed,
- i = (function utf8CheckExtraBytes(s, o, i) {
- if (128 != (192 & o[0])) return (s.lastNeed = 0), '�';
- if (s.lastNeed > 1 && o.length > 1) {
- if (128 != (192 & o[1])) return (s.lastNeed = 1), '�';
- if (s.lastNeed > 2 && o.length > 2 && 128 != (192 & o[2]))
- return (s.lastNeed = 2), '�';
- }
- })(this, s);
- return void 0 !== i
- ? i
- : this.lastNeed <= s.length
- ? (s.copy(this.lastChar, o, 0, this.lastNeed),
- this.lastChar.toString(this.encoding, 0, this.lastTotal))
- : (s.copy(this.lastChar, o, 0, s.length), void (this.lastNeed -= s.length));
- }
- function utf16Text(s, o) {
- if ((s.length - o) % 2 == 0) {
- var i = s.toString('utf16le', o);
- if (i) {
- var u = i.charCodeAt(i.length - 1);
- if (u >= 55296 && u <= 56319)
- return (
- (this.lastNeed = 2),
- (this.lastTotal = 4),
- (this.lastChar[0] = s[s.length - 2]),
- (this.lastChar[1] = s[s.length - 1]),
- i.slice(0, -1)
- );
- }
- return i;
- }
- return (
- (this.lastNeed = 1),
- (this.lastTotal = 2),
- (this.lastChar[0] = s[s.length - 1]),
- s.toString('utf16le', o, s.length - 1)
- );
- }
- function utf16End(s) {
- var o = s && s.length ? this.write(s) : '';
- if (this.lastNeed) {
- var i = this.lastTotal - this.lastNeed;
- return o + this.lastChar.toString('utf16le', 0, i);
- }
- return o;
- }
- function base64Text(s, o) {
- var i = (s.length - o) % 3;
- return 0 === i
- ? s.toString('base64', o)
- : ((this.lastNeed = 3 - i),
- (this.lastTotal = 3),
- 1 === i
- ? (this.lastChar[0] = s[s.length - 1])
- : ((this.lastChar[0] = s[s.length - 2]), (this.lastChar[1] = s[s.length - 1])),
- s.toString('base64', o, s.length - i));
- }
- function base64End(s) {
- var o = s && s.length ? this.write(s) : '';
- return this.lastNeed ? o + this.lastChar.toString('base64', 0, 3 - this.lastNeed) : o;
- }
- function simpleWrite(s) {
- return s.toString(this.encoding);
- }
- function simpleEnd(s) {
- return s && s.length ? this.write(s) : '';
- }
- (o.I = StringDecoder),
- (StringDecoder.prototype.write = function (s) {
- if (0 === s.length) return '';
- var o, i;
- if (this.lastNeed) {
- if (void 0 === (o = this.fillLast(s))) return '';
- (i = this.lastNeed), (this.lastNeed = 0);
- } else i = 0;
- return i < s.length ? (o ? o + this.text(s, i) : this.text(s, i)) : o || '';
- }),
- (StringDecoder.prototype.end = function utf8End(s) {
- var o = s && s.length ? this.write(s) : '';
- return this.lastNeed ? o + '�' : o;
- }),
- (StringDecoder.prototype.text = function utf8Text(s, o) {
- var i = (function utf8CheckIncomplete(s, o, i) {
- var u = o.length - 1;
- if (u < i) return 0;
- var _ = utf8CheckByte(o[u]);
- if (_ >= 0) return _ > 0 && (s.lastNeed = _ - 1), _;
- if (--u < i || -2 === _) return 0;
- if (((_ = utf8CheckByte(o[u])), _ >= 0)) return _ > 0 && (s.lastNeed = _ - 2), _;
- if (--u < i || -2 === _) return 0;
- if (((_ = utf8CheckByte(o[u])), _ >= 0))
- return _ > 0 && (2 === _ ? (_ = 0) : (s.lastNeed = _ - 3)), _;
- return 0;
- })(this, s, o);
- if (!this.lastNeed) return s.toString('utf8', o);
- this.lastTotal = i;
- var u = s.length - (i - this.lastNeed);
- return s.copy(this.lastChar, 0, u), s.toString('utf8', o, u);
- }),
- (StringDecoder.prototype.fillLast = function (s) {
- if (this.lastNeed <= s.length)
- return (
- s.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, this.lastNeed),
- this.lastChar.toString(this.encoding, 0, this.lastTotal)
- );
- s.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, s.length),
- (this.lastNeed -= s.length);
- });
- },
- 69883: (s, o) => {
- 'use strict';
- (o.parse = function parse(s, o) {
- if ('string' != typeof s) throw new TypeError('argument str must be a string');
- var i = {},
- _ = s.length;
- if (_ < 2) return i;
- var w = (o && o.decode) || decode,
- x = 0,
- C = 0,
- j = 0;
- do {
- if (-1 === (C = s.indexOf('=', x))) break;
- if (-1 === (j = s.indexOf(';', x))) j = _;
- else if (C > j) {
- x = s.lastIndexOf(';', C - 1) + 1;
- continue;
- }
- var L = startIndex(s, x, C),
- B = endIndex(s, C, L),
- $ = s.slice(L, B);
- if (!u.call(i, $)) {
- var V = startIndex(s, C + 1, j),
- U = endIndex(s, j, V);
- 34 === s.charCodeAt(V) && 34 === s.charCodeAt(U - 1) && (V++, U--);
- var z = s.slice(V, U);
- i[$] = tryDecode(z, w);
- }
- x = j + 1;
- } while (x < _);
- return i;
- }),
- (o.serialize = function serialize(s, o, u) {
- var j = (u && u.encode) || encodeURIComponent;
- if ('function' != typeof j) throw new TypeError('option encode is invalid');
- if (!_.test(s)) throw new TypeError('argument name is invalid');
- var L = j(o);
- if (!w.test(L)) throw new TypeError('argument val is invalid');
- var B = s + '=' + L;
- if (!u) return B;
- if (null != u.maxAge) {
- var $ = Math.floor(u.maxAge);
- if (!isFinite($)) throw new TypeError('option maxAge is invalid');
- B += '; Max-Age=' + $;
- }
- if (u.domain) {
- if (!x.test(u.domain)) throw new TypeError('option domain is invalid');
- B += '; Domain=' + u.domain;
- }
- if (u.path) {
- if (!C.test(u.path)) throw new TypeError('option path is invalid');
- B += '; Path=' + u.path;
- }
- if (u.expires) {
- var V = u.expires;
- if (
- !(function isDate(s) {
- return '[object Date]' === i.call(s);
- })(V) ||
- isNaN(V.valueOf())
- )
- throw new TypeError('option expires is invalid');
- B += '; Expires=' + V.toUTCString();
- }
- u.httpOnly && (B += '; HttpOnly');
- u.secure && (B += '; Secure');
- u.partitioned && (B += '; Partitioned');
- if (u.priority) {
- switch ('string' == typeof u.priority ? u.priority.toLowerCase() : u.priority) {
- case 'low':
- B += '; Priority=Low';
- break;
- case 'medium':
- B += '; Priority=Medium';
- break;
- case 'high':
- B += '; Priority=High';
- break;
- default:
- throw new TypeError('option priority is invalid');
- }
- }
- if (u.sameSite) {
- switch ('string' == typeof u.sameSite ? u.sameSite.toLowerCase() : u.sameSite) {
- case !0:
- B += '; SameSite=Strict';
- break;
- case 'lax':
- B += '; SameSite=Lax';
- break;
- case 'strict':
- B += '; SameSite=Strict';
- break;
- case 'none':
- B += '; SameSite=None';
- break;
- default:
- throw new TypeError('option sameSite is invalid');
- }
- }
- return B;
- });
- var i = Object.prototype.toString,
- u = Object.prototype.hasOwnProperty,
- _ = /^[!#$%&'*+\-.^_`|~0-9A-Za-z]+$/,
- w = /^("?)[\u0021\u0023-\u002B\u002D-\u003A\u003C-\u005B\u005D-\u007E]*\1$/,
- x =
- /^([.]?[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)([.][a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)*$/i,
- C = /^[\u0020-\u003A\u003D-\u007E]*$/;
- function startIndex(s, o, i) {
- do {
- var u = s.charCodeAt(o);
- if (32 !== u && 9 !== u) return o;
- } while (++o < i);
- return i;
- }
- function endIndex(s, o, i) {
- for (; o > i; ) {
- var u = s.charCodeAt(--o);
- if (32 !== u && 9 !== u) return o + 1;
- }
- return i;
- }
- function decode(s) {
- return -1 !== s.indexOf('%') ? decodeURIComponent(s) : s;
- }
- function tryDecode(s, o) {
- try {
- return o(s);
- } catch (o) {
- return s;
- }
- }
- },
- 16426: (s) => {
- s.exports = function () {
- var s = document.getSelection();
- if (!s.rangeCount) return function () {};
- for (var o = document.activeElement, i = [], u = 0; u < s.rangeCount; u++)
- i.push(s.getRangeAt(u));
- switch (o.tagName.toUpperCase()) {
- case 'INPUT':
- case 'TEXTAREA':
- o.blur();
- break;
- default:
- o = null;
- }
- return (
- s.removeAllRanges(),
- function () {
- 'Caret' === s.type && s.removeAllRanges(),
- s.rangeCount ||
- i.forEach(function (o) {
- s.addRange(o);
- }),
- o && o.focus();
- }
- );
- };
- },
- 61160: (s, o, i) => {
- 'use strict';
- var u = i(92063),
- _ = i(73992),
- w = /^[\x00-\x20\u00a0\u1680\u2000-\u200a\u2028\u2029\u202f\u205f\u3000\ufeff]+/,
- x = /[\n\r\t]/g,
- C = /^[A-Za-z][A-Za-z0-9+-.]*:\/\//,
- j = /:\d+$/,
- L = /^([a-z][a-z0-9.+-]*:)?(\/\/)?([\\/]+)?([\S\s]*)/i,
- B = /^[a-zA-Z]:/;
- function trimLeft(s) {
- return (s || '').toString().replace(w, '');
- }
- var $ = [
- ['#', 'hash'],
- ['?', 'query'],
- function sanitize(s, o) {
- return isSpecial(o.protocol) ? s.replace(/\\/g, '/') : s;
- },
- ['/', 'pathname'],
- ['@', 'auth', 1],
- [NaN, 'host', void 0, 1, 1],
- [/:(\d*)$/, 'port', void 0, 1],
- [NaN, 'hostname', void 0, 1, 1]
- ],
- V = { hash: 1, query: 1 };
- function lolcation(s) {
- var o,
- u =
- ('undefined' != typeof window
- ? window
- : void 0 !== i.g
- ? i.g
- : 'undefined' != typeof self
- ? self
- : {}
- ).location || {},
- _ = {},
- w = typeof (s = s || u);
- if ('blob:' === s.protocol) _ = new Url(unescape(s.pathname), {});
- else if ('string' === w) for (o in ((_ = new Url(s, {})), V)) delete _[o];
- else if ('object' === w) {
- for (o in s) o in V || (_[o] = s[o]);
- void 0 === _.slashes && (_.slashes = C.test(s.href));
- }
- return _;
- }
- function isSpecial(s) {
- return (
- 'file:' === s ||
- 'ftp:' === s ||
- 'http:' === s ||
- 'https:' === s ||
- 'ws:' === s ||
- 'wss:' === s
- );
- }
- function extractProtocol(s, o) {
- (s = (s = trimLeft(s)).replace(x, '')), (o = o || {});
- var i,
- u = L.exec(s),
- _ = u[1] ? u[1].toLowerCase() : '',
- w = !!u[2],
- C = !!u[3],
- j = 0;
- return (
- w
- ? C
- ? ((i = u[2] + u[3] + u[4]), (j = u[2].length + u[3].length))
- : ((i = u[2] + u[4]), (j = u[2].length))
- : C
- ? ((i = u[3] + u[4]), (j = u[3].length))
- : (i = u[4]),
- 'file:' === _
- ? j >= 2 && (i = i.slice(2))
- : isSpecial(_)
- ? (i = u[4])
- : _
- ? w && (i = i.slice(2))
- : j >= 2 && isSpecial(o.protocol) && (i = u[4]),
- { protocol: _, slashes: w || isSpecial(_), slashesCount: j, rest: i }
- );
- }
- function Url(s, o, i) {
- if (((s = (s = trimLeft(s)).replace(x, '')), !(this instanceof Url)))
- return new Url(s, o, i);
- var w,
- C,
- j,
- L,
- V,
- U,
- z = $.slice(),
- Y = typeof o,
- Z = this,
- ee = 0;
- for (
- 'object' !== Y && 'string' !== Y && ((i = o), (o = null)),
- i && 'function' != typeof i && (i = _.parse),
- w = !(C = extractProtocol(s || '', (o = lolcation(o)))).protocol && !C.slashes,
- Z.slashes = C.slashes || (w && o.slashes),
- Z.protocol = C.protocol || o.protocol || '',
- s = C.rest,
- (('file:' === C.protocol && (2 !== C.slashesCount || B.test(s))) ||
- (!C.slashes && (C.protocol || C.slashesCount < 2 || !isSpecial(Z.protocol)))) &&
- (z[3] = [/(.*)/, 'pathname']);
- ee < z.length;
- ee++
- )
- 'function' != typeof (L = z[ee])
- ? ((j = L[0]),
- (U = L[1]),
- j != j
- ? (Z[U] = s)
- : 'string' == typeof j
- ? ~(V = '@' === j ? s.lastIndexOf(j) : s.indexOf(j)) &&
- ('number' == typeof L[2]
- ? ((Z[U] = s.slice(0, V)), (s = s.slice(V + L[2])))
- : ((Z[U] = s.slice(V)), (s = s.slice(0, V))))
- : (V = j.exec(s)) && ((Z[U] = V[1]), (s = s.slice(0, V.index))),
- (Z[U] = Z[U] || (w && L[3] && o[U]) || ''),
- L[4] && (Z[U] = Z[U].toLowerCase()))
- : (s = L(s, Z));
- i && (Z.query = i(Z.query)),
- w &&
- o.slashes &&
- '/' !== Z.pathname.charAt(0) &&
- ('' !== Z.pathname || '' !== o.pathname) &&
- (Z.pathname = (function resolve(s, o) {
- if ('' === s) return o;
- for (
- var i = (o || '/').split('/').slice(0, -1).concat(s.split('/')),
- u = i.length,
- _ = i[u - 1],
- w = !1,
- x = 0;
- u--;
- )
- '.' === i[u]
- ? i.splice(u, 1)
- : '..' === i[u]
- ? (i.splice(u, 1), x++)
- : x && (0 === u && (w = !0), i.splice(u, 1), x--);
- return w && i.unshift(''), ('.' !== _ && '..' !== _) || i.push(''), i.join('/');
- })(Z.pathname, o.pathname)),
- '/' !== Z.pathname.charAt(0) &&
- isSpecial(Z.protocol) &&
- (Z.pathname = '/' + Z.pathname),
- u(Z.port, Z.protocol) || ((Z.host = Z.hostname), (Z.port = '')),
- (Z.username = Z.password = ''),
- Z.auth &&
- (~(V = Z.auth.indexOf(':'))
- ? ((Z.username = Z.auth.slice(0, V)),
- (Z.username = encodeURIComponent(decodeURIComponent(Z.username))),
- (Z.password = Z.auth.slice(V + 1)),
- (Z.password = encodeURIComponent(decodeURIComponent(Z.password))))
- : (Z.username = encodeURIComponent(decodeURIComponent(Z.auth))),
- (Z.auth = Z.password ? Z.username + ':' + Z.password : Z.username)),
- (Z.origin =
- 'file:' !== Z.protocol && isSpecial(Z.protocol) && Z.host
- ? Z.protocol + '//' + Z.host
- : 'null'),
- (Z.href = Z.toString());
- }
- (Url.prototype = {
- set: function set(s, o, i) {
- var w = this;
- switch (s) {
- case 'query':
- 'string' == typeof o && o.length && (o = (i || _.parse)(o)), (w[s] = o);
- break;
- case 'port':
- (w[s] = o),
- u(o, w.protocol)
- ? o && (w.host = w.hostname + ':' + o)
- : ((w.host = w.hostname), (w[s] = ''));
- break;
- case 'hostname':
- (w[s] = o), w.port && (o += ':' + w.port), (w.host = o);
- break;
- case 'host':
- (w[s] = o),
- j.test(o)
- ? ((o = o.split(':')), (w.port = o.pop()), (w.hostname = o.join(':')))
- : ((w.hostname = o), (w.port = ''));
- break;
- case 'protocol':
- (w.protocol = o.toLowerCase()), (w.slashes = !i);
- break;
- case 'pathname':
- case 'hash':
- if (o) {
- var x = 'pathname' === s ? '/' : '#';
- w[s] = o.charAt(0) !== x ? x + o : o;
- } else w[s] = o;
- break;
- case 'username':
- case 'password':
- w[s] = encodeURIComponent(o);
- break;
- case 'auth':
- var C = o.indexOf(':');
- ~C
- ? ((w.username = o.slice(0, C)),
- (w.username = encodeURIComponent(decodeURIComponent(w.username))),
- (w.password = o.slice(C + 1)),
- (w.password = encodeURIComponent(decodeURIComponent(w.password))))
- : (w.username = encodeURIComponent(decodeURIComponent(o)));
- }
- for (var L = 0; L < $.length; L++) {
- var B = $[L];
- B[4] && (w[B[1]] = w[B[1]].toLowerCase());
- }
- return (
- (w.auth = w.password ? w.username + ':' + w.password : w.username),
- (w.origin =
- 'file:' !== w.protocol && isSpecial(w.protocol) && w.host
- ? w.protocol + '//' + w.host
- : 'null'),
- (w.href = w.toString()),
- w
- );
- },
- toString: function toString(s) {
- (s && 'function' == typeof s) || (s = _.stringify);
- var o,
- i = this,
- u = i.host,
- w = i.protocol;
- w && ':' !== w.charAt(w.length - 1) && (w += ':');
- var x = w + ((i.protocol && i.slashes) || isSpecial(i.protocol) ? '//' : '');
- return (
- i.username
- ? ((x += i.username), i.password && (x += ':' + i.password), (x += '@'))
- : i.password
- ? ((x += ':' + i.password), (x += '@'))
- : 'file:' !== i.protocol &&
- isSpecial(i.protocol) &&
- !u &&
- '/' !== i.pathname &&
- (x += '@'),
- (':' === u[u.length - 1] || (j.test(i.hostname) && !i.port)) && (u += ':'),
- (x += u + i.pathname),
- (o = 'object' == typeof i.query ? s(i.query) : i.query) &&
- (x += '?' !== o.charAt(0) ? '?' + o : o),
- i.hash && (x += i.hash),
- x
- );
- }
- }),
- (Url.extractProtocol = extractProtocol),
- (Url.location = lolcation),
- (Url.trimLeft = trimLeft),
- (Url.qs = _),
- (s.exports = Url);
- },
- 77154: (s, o, i) => {
- 'use strict';
- var u = i(96540);
- var _ =
- 'function' == typeof Object.is
- ? Object.is
- : function n(s, o) {
- return (s === o && (0 !== s || 1 / s == 1 / o)) || (s != s && o != o);
- },
- w = u.useSyncExternalStore,
- x = u.useRef,
- C = u.useEffect,
- j = u.useMemo,
- L = u.useDebugValue;
- o.useSyncExternalStoreWithSelector = function (s, o, i, u, B) {
- var $ = x(null);
- if (null === $.current) {
- var V = { hasValue: !1, value: null };
- $.current = V;
- } else V = $.current;
- $ = j(
- function () {
- function a(o) {
- if (!x) {
- if (((x = !0), (s = o), (o = u(o)), void 0 !== B && V.hasValue)) {
- var i = V.value;
- if (B(i, o)) return (w = i);
- }
- return (w = o);
- }
- if (((i = w), _(s, o))) return i;
- var C = u(o);
- return void 0 !== B && B(i, C) ? i : ((s = o), (w = C));
- }
- var s,
- w,
- x = !1,
- C = void 0 === i ? null : i;
- return [
- function () {
- return a(o());
- },
- null === C
- ? void 0
- : function () {
- return a(C());
- }
- ];
- },
- [o, i, u, B]
- );
- var U = w(s, $[0], $[1]);
- return (
- C(
- function () {
- (V.hasValue = !0), (V.value = U);
- },
- [U]
- ),
- L(U),
- U
- );
- };
- },
- 78418: (s, o, i) => {
- 'use strict';
- s.exports = i(77154);
- },
- 94643: (s, o, i) => {
- function config(s) {
- try {
- if (!i.g.localStorage) return !1;
- } catch (s) {
- return !1;
- }
- var o = i.g.localStorage[s];
- return null != o && 'true' === String(o).toLowerCase();
- }
- s.exports = function deprecate(s, o) {
- if (config('noDeprecation')) return s;
- var i = !1;
- return function deprecated() {
- if (!i) {
- if (config('throwDeprecation')) throw new Error(o);
- config('traceDeprecation') ? console.trace(o) : console.warn(o), (i = !0);
- }
- return s.apply(this, arguments);
- };
- };
- },
- 26657: (s, o, i) => {
- 'use strict';
- var u = i(75208),
- _ = function isClosingTag(s) {
- return /<\/+[^>]+>/.test(s);
- },
- w = function isSelfClosingTag(s) {
- return /<[^>]+\/>/.test(s);
- };
- function getType(s) {
- return _(s)
- ? 'ClosingTag'
- : (function isOpeningTag(s) {
- return (
- (function isTag(s) {
- return /<[^>!]+>/.test(s);
- })(s) &&
- !_(s) &&
- !w(s)
- );
- })(s)
- ? 'OpeningTag'
- : w(s)
- ? 'SelfClosingTag'
- : 'Text';
- }
- s.exports = function (s) {
- var o = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {},
- i = o.indentor,
- _ = o.textNodesOnSameLine,
- w = 0,
- x = [];
- i = i || ' ';
- var C = (function lexer(s) {
- return (function splitOnTags(s) {
- return s.split(/(<\/?[^>]+>)/g).filter(function (s) {
- return '' !== s.trim();
- });
- })(s).map(function (s) {
- return { value: s, type: getType(s) };
- });
- })(s).map(function (s, o, C) {
- var j = s.value,
- L = s.type;
- 'ClosingTag' === L && w--;
- var B = u(i, w),
- $ = B + j;
- if (('OpeningTag' === L && w++, _)) {
- var V = C[o - 1],
- U = C[o - 2];
- 'ClosingTag' === L &&
- 'Text' === V.type &&
- 'OpeningTag' === U.type &&
- (($ = '' + B + U.value + V.value + j), x.push(o - 2, o - 1));
- }
- return $;
- });
- return (
- x.forEach(function (s) {
- return (C[s] = null);
- }),
- C.filter(function (s) {
- return !!s;
- }).join('\n')
- );
- };
- },
- 31499: (s) => {
- var o = { '&': '&', '"': '"', "'": ''', '<': '<', '>': '>' };
- s.exports = function escapeForXML(s) {
- return s && s.replace
- ? s.replace(/([&"<>'])/g, function (s, i) {
- return o[i];
- })
- : s;
- };
- },
- 19123: (s, o, i) => {
- var u = i(65606),
- _ = i(31499),
- w = i(88310).Stream;
- function resolve(s, o, i) {
- var u,
- w = (function create_indent(s, o) {
- return new Array(o || 0).join(s || '');
- })(o, (i = i || 0)),
- x = s;
- if ('object' == typeof s && (x = s[(u = Object.keys(s)[0])]) && x._elem)
- return (
- (x._elem.name = u),
- (x._elem.icount = i),
- (x._elem.indent = o),
- (x._elem.indents = w),
- (x._elem.interrupt = x),
- x._elem
- );
- var C,
- j = [],
- L = [];
- function get_attributes(s) {
- Object.keys(s).forEach(function (o) {
- j.push(
- (function attribute(s, o) {
- return s + '="' + _(o) + '"';
- })(o, s[o])
- );
- });
- }
- switch (typeof x) {
- case 'object':
- if (null === x) break;
- x._attr && get_attributes(x._attr),
- x._cdata &&
- L.push(('<![CDATA[' + x._cdata).replace(/\]\]>/g, ']]]]><![CDATA[>') + ']]>'),
- x.forEach &&
- ((C = !1),
- L.push(''),
- x.forEach(function (s) {
- 'object' == typeof s
- ? '_attr' == Object.keys(s)[0]
- ? get_attributes(s._attr)
- : L.push(resolve(s, o, i + 1))
- : (L.pop(), (C = !0), L.push(_(s)));
- }),
- C || L.push(''));
- break;
- default:
- L.push(_(x));
- }
- return {
- name: u,
- interrupt: !1,
- attributes: j,
- content: L,
- icount: i,
- indents: w,
- indent: o
- };
- }
- function format(s, o, i) {
- if ('object' != typeof o) return s(!1, o);
- var u = o.interrupt ? 1 : o.content.length;
- function proceed() {
- for (; o.content.length; ) {
- var _ = o.content.shift();
- if (void 0 !== _) {
- if (interrupt(_)) return;
- format(s, _);
- }
- }
- s(
- !1,
- (u > 1 ? o.indents : '') +
- (o.name ? '</' + o.name + '>' : '') +
- (o.indent && !i ? '\n' : '')
- ),
- i && i();
- }
- function interrupt(o) {
- return (
- !!o.interrupt &&
- ((o.interrupt.append = s),
- (o.interrupt.end = proceed),
- (o.interrupt = !1),
- s(!0),
- !0)
- );
- }
- if (
- (s(
- !1,
- o.indents +
- (o.name ? '<' + o.name : '') +
- (o.attributes.length ? ' ' + o.attributes.join(' ') : '') +
- (u ? (o.name ? '>' : '') : o.name ? '/>' : '') +
- (o.indent && u > 1 ? '\n' : '')
- ),
- !u)
- )
- return s(!1, o.indent ? '\n' : '');
- interrupt(o) || proceed();
- }
- (s.exports = function xml(s, o) {
- 'object' != typeof o && (o = { indent: o });
- var i = o.stream ? new w() : null,
- _ = '',
- x = !1,
- C = o.indent ? (!0 === o.indent ? ' ' : o.indent) : '',
- j = !0;
- function delay(s) {
- j ? u.nextTick(s) : s();
- }
- function append(s, o) {
- if ((void 0 !== o && (_ += o), s && !x && ((i = i || new w()), (x = !0)), s && x)) {
- var u = _;
- delay(function () {
- i.emit('data', u);
- }),
- (_ = '');
- }
- }
- function add(s, o) {
- format(append, resolve(s, C, C ? 1 : 0), o);
- }
- function end() {
- if (i) {
- var s = _;
- delay(function () {
- i.emit('data', s), i.emit('end'), (i.readable = !1), i.emit('close');
- });
- }
- }
- return (
- delay(function () {
- j = !1;
- }),
- o.declaration &&
- (function addXmlDeclaration(s) {
- var o = { version: '1.0', encoding: s.encoding || 'UTF-8' };
- s.standalone && (o.standalone = s.standalone),
- add({ '?xml': { _attr: o } }),
- (_ = _.replace('/>', '?>'));
- })(o.declaration),
- s && s.forEach
- ? s.forEach(function (o, i) {
- var u;
- i + 1 === s.length && (u = end), add(o, u);
- })
- : add(s, end),
- i ? ((i.readable = !0), i) : _
- );
- }),
- (s.exports.element = s.exports.Element =
- function element() {
- var s = {
- _elem: resolve(Array.prototype.slice.call(arguments)),
- push: function (s) {
- if (!this.append) throw new Error('not assigned to a parent!');
- var o = this,
- i = this._elem.indent;
- format(
- this.append,
- resolve(s, i, this._elem.icount + (i ? 1 : 0)),
- function () {
- o.append(!0);
- }
- );
- },
- close: function (s) {
- void 0 !== s && this.push(s), this.end && this.end();
- }
- };
- return s;
- });
- },
- 86215: function (s, o) {
- var i, u, _;
- (u = []),
- (i = (function () {
- 'use strict';
- var isNativeSmoothScrollEnabledOn = function (s) {
- return (
- s &&
- 'getComputedStyle' in window &&
- 'smooth' === window.getComputedStyle(s)['scroll-behavior']
- );
- };
- if ('undefined' == typeof window || !('document' in window)) return {};
- var makeScroller = function (s, o, i) {
- var u;
- (o = o || 999), i || 0 === i || (i = 9);
- var setScrollTimeoutId = function (s) {
- u = s;
- },
- stopScroll = function () {
- clearTimeout(u), setScrollTimeoutId(0);
- },
- getTopWithEdgeOffset = function (o) {
- return Math.max(0, s.getTopOf(o) - i);
- },
- scrollToY = function (i, u, _) {
- if (
- (stopScroll(),
- 0 === u || (u && u < 0) || isNativeSmoothScrollEnabledOn(s.body))
- )
- s.toY(i), _ && _();
- else {
- var w = s.getY(),
- x = Math.max(0, i) - w,
- C = new Date().getTime();
- (u = u || Math.min(Math.abs(x), o)),
- (function loopScroll() {
- setScrollTimeoutId(
- setTimeout(function () {
- var o = Math.min(1, (new Date().getTime() - C) / u),
- i = Math.max(
- 0,
- Math.floor(w + x * (o < 0.5 ? 2 * o * o : o * (4 - 2 * o) - 1))
- );
- s.toY(i),
- o < 1 && s.getHeight() + i < s.body.scrollHeight
- ? loopScroll()
- : (setTimeout(stopScroll, 99), _ && _());
- }, 9)
- );
- })();
- }
- },
- scrollToElem = function (s, o, i) {
- scrollToY(getTopWithEdgeOffset(s), o, i);
- },
- scrollIntoView = function (o, u, _) {
- var w = o.getBoundingClientRect().height,
- x = s.getTopOf(o) + w,
- C = s.getHeight(),
- j = s.getY(),
- L = j + C;
- getTopWithEdgeOffset(o) < j || w + i > C
- ? scrollToElem(o, u, _)
- : x + i > L
- ? scrollToY(x - C + i, u, _)
- : _ && _();
- },
- scrollToCenterOf = function (o, i, u, _) {
- scrollToY(
- Math.max(
- 0,
- s.getTopOf(o) -
- s.getHeight() / 2 +
- (u || o.getBoundingClientRect().height / 2)
- ),
- i,
- _
- );
- };
- return {
- setup: function (s, u) {
- return (
- (0 === s || s) && (o = s),
- (0 === u || u) && (i = u),
- { defaultDuration: o, edgeOffset: i }
- );
- },
- to: scrollToElem,
- toY: scrollToY,
- intoView: scrollIntoView,
- center: scrollToCenterOf,
- stop: stopScroll,
- moving: function () {
- return !!u;
- },
- getY: s.getY,
- getTopOf: s.getTopOf
- };
- },
- s = document.documentElement,
- getDocY = function () {
- return window.scrollY || s.scrollTop;
- },
- o = makeScroller({
- body: document.scrollingElement || document.body,
- toY: function (s) {
- window.scrollTo(0, s);
- },
- getY: getDocY,
- getHeight: function () {
- return window.innerHeight || s.clientHeight;
- },
- getTopOf: function (o) {
- return o.getBoundingClientRect().top + getDocY() - s.offsetTop;
- }
- });
- if (
- ((o.createScroller = function (o, i, u) {
- return makeScroller(
- {
- body: o,
- toY: function (s) {
- o.scrollTop = s;
- },
- getY: function () {
- return o.scrollTop;
- },
- getHeight: function () {
- return Math.min(o.clientHeight, window.innerHeight || s.clientHeight);
- },
- getTopOf: function (s) {
- return s.offsetTop;
- }
- },
- i,
- u
- );
- }),
- 'addEventListener' in window &&
- !window.noZensmooth &&
- !isNativeSmoothScrollEnabledOn(document.body))
- ) {
- var i = 'history' in window && 'pushState' in history,
- u = i && 'scrollRestoration' in history;
- u && (history.scrollRestoration = 'auto'),
- window.addEventListener(
- 'load',
- function () {
- u &&
- (setTimeout(function () {
- history.scrollRestoration = 'manual';
- }, 9),
- window.addEventListener(
- 'popstate',
- function (s) {
- s.state && 'zenscrollY' in s.state && o.toY(s.state.zenscrollY);
- },
- !1
- )),
- window.location.hash &&
- setTimeout(function () {
- var s = o.setup().edgeOffset;
- if (s) {
- var i = document.getElementById(window.location.href.split('#')[1]);
- if (i) {
- var u = Math.max(0, o.getTopOf(i) - s),
- _ = o.getY() - u;
- 0 <= _ && _ < 9 && window.scrollTo(0, u);
- }
- }
- }, 9);
- },
- !1
- );
- var _ = new RegExp('(^|\\s)noZensmooth(\\s|$)');
- window.addEventListener(
- 'click',
- function (s) {
- for (var w = s.target; w && 'A' !== w.tagName; ) w = w.parentNode;
- if (
- !(!w || 1 !== s.which || s.shiftKey || s.metaKey || s.ctrlKey || s.altKey)
- ) {
- if (u) {
- var x =
- history.state && 'object' == typeof history.state ? history.state : {};
- x.zenscrollY = o.getY();
- try {
- history.replaceState(x, '');
- } catch (s) {}
- }
- var C = w.getAttribute('href') || '';
- if (0 === C.indexOf('#') && !_.test(w.className)) {
- var j = 0,
- L = document.getElementById(C.substring(1));
- if ('#' !== C) {
- if (!L) return;
- j = o.getTopOf(L);
- }
- s.preventDefault();
- var onDone = function () {
- window.location = C;
- },
- B = o.setup().edgeOffset;
- B &&
- ((j = Math.max(0, j - B)),
- i &&
- (onDone = function () {
- history.pushState({}, '', C);
- })),
- o.toY(j, null, onDone);
- }
- }
- },
- !1
- );
- }
- return o;
- })()),
- void 0 === (_ = 'function' == typeof i ? i.apply(o, u) : i) || (s.exports = _);
- },
- 15340: () => {},
- 79838: () => {},
- 48675: (s, o, i) => {
- s.exports = i(20850);
- },
- 7666: (s, o, i) => {
- var u = i(84851),
- _ = i(953);
- function _extends() {
- var o;
- return (
- (s.exports = _extends =
- u
- ? _((o = u)).call(o)
- : function (s) {
- for (var o = 1; o < arguments.length; o++) {
- var i = arguments[o];
- for (var u in i) ({}).hasOwnProperty.call(i, u) && (s[u] = i[u]);
- }
- return s;
- }),
- (s.exports.__esModule = !0),
- (s.exports.default = s.exports),
- _extends.apply(null, arguments)
- );
- }
- (s.exports = _extends), (s.exports.__esModule = !0), (s.exports.default = s.exports);
- },
- 46942: (s, o) => {
- var i;
- !(function () {
- 'use strict';
- var u = {}.hasOwnProperty;
- function classNames() {
- for (var s = '', o = 0; o < arguments.length; o++) {
- var i = arguments[o];
- i && (s = appendClass(s, parseValue(i)));
- }
- return s;
- }
- function parseValue(s) {
- if ('string' == typeof s || 'number' == typeof s) return s;
- if ('object' != typeof s) return '';
- if (Array.isArray(s)) return classNames.apply(null, s);
- if (
- s.toString !== Object.prototype.toString &&
- !s.toString.toString().includes('[native code]')
- )
- return s.toString();
- var o = '';
- for (var i in s) u.call(s, i) && s[i] && (o = appendClass(o, i));
- return o;
- }
- function appendClass(s, o) {
- return o ? (s ? s + ' ' + o : s + o) : s;
- }
- s.exports
- ? ((classNames.default = classNames), (s.exports = classNames))
- : void 0 ===
- (i = function () {
- return classNames;
- }.apply(o, [])) || (s.exports = i);
- })();
- },
- 68623: (s, o, i) => {
- 'use strict';
- var u = i(694);
- s.exports = u;
- },
- 93700: (s, o, i) => {
- 'use strict';
- var u = i(19709);
- s.exports = u;
- },
- 462: (s, o, i) => {
- 'use strict';
- var u = i(40975);
- s.exports = u;
- },
- 37257: (s, o, i) => {
- 'use strict';
- i(96605), i(64502), i(36371), i(99363), i(7057);
- var u = i(92046);
- s.exports = u.AggregateError;
- },
- 32567: (s, o, i) => {
- 'use strict';
- i(79307);
- var u = i(61747);
- s.exports = u('Function', 'bind');
- },
- 23034: (s, o, i) => {
- 'use strict';
- var u = i(88280),
- _ = i(32567),
- w = Function.prototype;
- s.exports = function (s) {
- var o = s.bind;
- return s === w || (u(w, s) && o === w.bind) ? _ : o;
- };
- },
- 9748: (s, o, i) => {
- 'use strict';
- i(71340);
- var u = i(92046);
- s.exports = u.Object.assign;
- },
- 20850: (s, o, i) => {
- 'use strict';
- s.exports = i(46076);
- },
- 953: (s, o, i) => {
- 'use strict';
- s.exports = i(53375);
- },
- 84851: (s, o, i) => {
- 'use strict';
- s.exports = i(85401);
- },
- 46076: (s, o, i) => {
- 'use strict';
- i(91599);
- var u = i(68623);
- s.exports = u;
- },
- 53375: (s, o, i) => {
- 'use strict';
- var u = i(93700);
- s.exports = u;
- },
- 85401: (s, o, i) => {
- 'use strict';
- var u = i(462);
- s.exports = u;
- },
- 82159: (s, o, i) => {
- 'use strict';
- var u = i(62250),
- _ = i(4640),
- w = TypeError;
- s.exports = function (s) {
- if (u(s)) return s;
- throw new w(_(s) + ' is not a function');
- };
- },
- 10043: (s, o, i) => {
- 'use strict';
- var u = i(54018),
- _ = String,
- w = TypeError;
- s.exports = function (s) {
- if (u(s)) return s;
- throw new w("Can't set " + _(s) + ' as a prototype');
- };
- },
- 42156: (s) => {
- 'use strict';
- s.exports = function () {};
- },
- 36624: (s, o, i) => {
- 'use strict';
- var u = i(46285),
- _ = String,
- w = TypeError;
- s.exports = function (s) {
- if (u(s)) return s;
- throw new w(_(s) + ' is not an object');
- };
- },
- 74436: (s, o, i) => {
- 'use strict';
- var u = i(4993),
- _ = i(34849),
- w = i(20575),
- createMethod = function (s) {
- return function (o, i, x) {
- var C = u(o),
- j = w(C);
- if (0 === j) return !s && -1;
- var L,
- B = _(x, j);
- if (s && i != i) {
- for (; j > B; ) if ((L = C[B++]) != L) return !0;
- } else for (; j > B; B++) if ((s || B in C) && C[B] === i) return s || B || 0;
- return !s && -1;
- };
- };
- s.exports = { includes: createMethod(!0), indexOf: createMethod(!1) };
- },
- 93427: (s, o, i) => {
- 'use strict';
- var u = i(1907);
- s.exports = u([].slice);
- },
- 45807: (s, o, i) => {
- 'use strict';
- var u = i(1907),
- _ = u({}.toString),
- w = u(''.slice);
- s.exports = function (s) {
- return w(_(s), 8, -1);
- };
- },
- 73948: (s, o, i) => {
- 'use strict';
- var u = i(52623),
- _ = i(62250),
- w = i(45807),
- x = i(76264)('toStringTag'),
- C = Object,
- j =
- 'Arguments' ===
- w(
- (function () {
- return arguments;
- })()
- );
- s.exports = u
- ? w
- : function (s) {
- var o, i, u;
- return void 0 === s
- ? 'Undefined'
- : null === s
- ? 'Null'
- : 'string' ==
- typeof (i = (function (s, o) {
- try {
- return s[o];
- } catch (s) {}
- })((o = C(s)), x))
- ? i
- : j
- ? w(o)
- : 'Object' === (u = w(o)) && _(o.callee)
- ? 'Arguments'
- : u;
- };
- },
- 19595: (s, o, i) => {
- 'use strict';
- var u = i(49724),
- _ = i(11042),
- w = i(13846),
- x = i(74284);
- s.exports = function (s, o, i) {
- for (var C = _(o), j = x.f, L = w.f, B = 0; B < C.length; B++) {
- var $ = C[B];
- u(s, $) || (i && u(i, $)) || j(s, $, L(o, $));
- }
- };
- },
- 57382: (s, o, i) => {
- 'use strict';
- var u = i(98828);
- s.exports = !u(function () {
- function F() {}
- return (F.prototype.constructor = null), Object.getPrototypeOf(new F()) !== F.prototype;
- });
- },
- 59550: (s) => {
- 'use strict';
- s.exports = function (s, o) {
- return { value: s, done: o };
- };
- },
- 61626: (s, o, i) => {
- 'use strict';
- var u = i(39447),
- _ = i(74284),
- w = i(75817);
- s.exports = u
- ? function (s, o, i) {
- return _.f(s, o, w(1, i));
- }
- : function (s, o, i) {
- return (s[o] = i), s;
- };
- },
- 75817: (s) => {
- 'use strict';
- s.exports = function (s, o) {
- return { enumerable: !(1 & s), configurable: !(2 & s), writable: !(4 & s), value: o };
- };
- },
- 68055: (s, o, i) => {
- 'use strict';
- var u = i(61626);
- s.exports = function (s, o, i, _) {
- return _ && _.enumerable ? (s[o] = i) : u(s, o, i), s;
- };
- },
- 2532: (s, o, i) => {
- 'use strict';
- var u = i(45951),
- _ = Object.defineProperty;
- s.exports = function (s, o) {
- try {
- _(u, s, { value: o, configurable: !0, writable: !0 });
- } catch (i) {
- u[s] = o;
- }
- return o;
- };
- },
- 39447: (s, o, i) => {
- 'use strict';
- var u = i(98828);
- s.exports = !u(function () {
- return (
- 7 !==
- Object.defineProperty({}, 1, {
- get: function () {
- return 7;
- }
- })[1]
- );
- });
- },
- 49552: (s, o, i) => {
- 'use strict';
- var u = i(45951),
- _ = i(46285),
- w = u.document,
- x = _(w) && _(w.createElement);
- s.exports = function (s) {
- return x ? w.createElement(s) : {};
- };
- },
- 19287: (s) => {
- 'use strict';
- s.exports = {
- CSSRuleList: 0,
- CSSStyleDeclaration: 0,
- CSSValueList: 0,
- ClientRectList: 0,
- DOMRectList: 0,
- DOMStringList: 0,
- DOMTokenList: 1,
- DataTransferItemList: 0,
- FileList: 0,
- HTMLAllCollection: 0,
- HTMLCollection: 0,
- HTMLFormElement: 0,
- HTMLSelectElement: 0,
- MediaList: 0,
- MimeTypeArray: 0,
- NamedNodeMap: 0,
- NodeList: 1,
- PaintRequestList: 0,
- Plugin: 0,
- PluginArray: 0,
- SVGLengthList: 0,
- SVGNumberList: 0,
- SVGPathSegList: 0,
- SVGPointList: 0,
- SVGStringList: 0,
- SVGTransformList: 0,
- SourceBufferList: 0,
- StyleSheetList: 0,
- TextTrackCueList: 0,
- TextTrackList: 0,
- TouchList: 0
- };
- },
- 80376: (s) => {
- 'use strict';
- s.exports = [
- 'constructor',
- 'hasOwnProperty',
- 'isPrototypeOf',
- 'propertyIsEnumerable',
- 'toLocaleString',
- 'toString',
- 'valueOf'
- ];
- },
- 96794: (s, o, i) => {
- 'use strict';
- var u = i(45951).navigator,
- _ = u && u.userAgent;
- s.exports = _ ? String(_) : '';
- },
- 20798: (s, o, i) => {
- 'use strict';
- var u,
- _,
- w = i(45951),
- x = i(96794),
- C = w.process,
- j = w.Deno,
- L = (C && C.versions) || (j && j.version),
- B = L && L.v8;
- B && (_ = (u = B.split('.'))[0] > 0 && u[0] < 4 ? 1 : +(u[0] + u[1])),
- !_ &&
- x &&
- (!(u = x.match(/Edge\/(\d+)/)) || u[1] >= 74) &&
- (u = x.match(/Chrome\/(\d+)/)) &&
- (_ = +u[1]),
- (s.exports = _);
- },
- 85762: (s, o, i) => {
- 'use strict';
- var u = i(1907),
- _ = Error,
- w = u(''.replace),
- x = String(new _('zxcasd').stack),
- C = /\n\s*at [^:]*:[^\n]*/,
- j = C.test(x);
- s.exports = function (s, o) {
- if (j && 'string' == typeof s && !_.prepareStackTrace) for (; o--; ) s = w(s, C, '');
- return s;
- };
- },
- 85884: (s, o, i) => {
- 'use strict';
- var u = i(61626),
- _ = i(85762),
- w = i(23888),
- x = Error.captureStackTrace;
- s.exports = function (s, o, i, C) {
- w && (x ? x(s, o) : u(s, 'stack', _(i, C)));
- };
- },
- 23888: (s, o, i) => {
- 'use strict';
- var u = i(98828),
- _ = i(75817);
- s.exports = !u(function () {
- var s = new Error('a');
- return !('stack' in s) || (Object.defineProperty(s, 'stack', _(1, 7)), 7 !== s.stack);
- });
- },
- 11091: (s, o, i) => {
- 'use strict';
- var u = i(45951),
- _ = i(76024),
- w = i(92361),
- x = i(62250),
- C = i(13846).f,
- j = i(7463),
- L = i(92046),
- B = i(28311),
- $ = i(61626),
- V = i(49724);
- i(36128);
- var wrapConstructor = function (s) {
- var Wrapper = function (o, i, u) {
- if (this instanceof Wrapper) {
- switch (arguments.length) {
- case 0:
- return new s();
- case 1:
- return new s(o);
- case 2:
- return new s(o, i);
- }
- return new s(o, i, u);
- }
- return _(s, this, arguments);
- };
- return (Wrapper.prototype = s.prototype), Wrapper;
- };
- s.exports = function (s, o) {
- var i,
- _,
- U,
- z,
- Y,
- Z,
- ee,
- ie,
- ae,
- le = s.target,
- ce = s.global,
- pe = s.stat,
- de = s.proto,
- fe = ce ? u : pe ? u[le] : u[le] && u[le].prototype,
- ye = ce ? L : L[le] || $(L, le, {})[le],
- be = ye.prototype;
- for (z in o)
- (_ = !(i = j(ce ? z : le + (pe ? '.' : '#') + z, s.forced)) && fe && V(fe, z)),
- (Z = ye[z]),
- _ && (ee = s.dontCallGetSet ? (ae = C(fe, z)) && ae.value : fe[z]),
- (Y = _ && ee ? ee : o[z]),
- (i || de || typeof Z != typeof Y) &&
- ((ie =
- s.bind && _
- ? B(Y, u)
- : s.wrap && _
- ? wrapConstructor(Y)
- : de && x(Y)
- ? w(Y)
- : Y),
- (s.sham || (Y && Y.sham) || (Z && Z.sham)) && $(ie, 'sham', !0),
- $(ye, z, ie),
- de &&
- (V(L, (U = le + 'Prototype')) || $(L, U, {}),
- $(L[U], z, Y),
- s.real && be && (i || !be[z]) && $(be, z, Y)));
- };
- },
- 98828: (s) => {
- 'use strict';
- s.exports = function (s) {
- try {
- return !!s();
- } catch (s) {
- return !0;
- }
- };
- },
- 76024: (s, o, i) => {
- 'use strict';
- var u = i(41505),
- _ = Function.prototype,
- w = _.apply,
- x = _.call;
- s.exports =
- ('object' == typeof Reflect && Reflect.apply) ||
- (u
- ? x.bind(w)
- : function () {
- return x.apply(w, arguments);
- });
- },
- 28311: (s, o, i) => {
- 'use strict';
- var u = i(92361),
- _ = i(82159),
- w = i(41505),
- x = u(u.bind);
- s.exports = function (s, o) {
- return (
- _(s),
- void 0 === o
- ? s
- : w
- ? x(s, o)
- : function () {
- return s.apply(o, arguments);
- }
- );
- };
- },
- 41505: (s, o, i) => {
- 'use strict';
- var u = i(98828);
- s.exports = !u(function () {
- var s = function () {}.bind();
- return 'function' != typeof s || s.hasOwnProperty('prototype');
- });
- },
- 44673: (s, o, i) => {
- 'use strict';
- var u = i(1907),
- _ = i(82159),
- w = i(46285),
- x = i(49724),
- C = i(93427),
- j = i(41505),
- L = Function,
- B = u([].concat),
- $ = u([].join),
- V = {};
- s.exports = j
- ? L.bind
- : function bind(s) {
- var o = _(this),
- i = o.prototype,
- u = C(arguments, 1),
- j = function bound() {
- var i = B(u, C(arguments));
- return this instanceof j
- ? (function (s, o, i) {
- if (!x(V, o)) {
- for (var u = [], _ = 0; _ < o; _++) u[_] = 'a[' + _ + ']';
- V[o] = L('C,a', 'return new C(' + $(u, ',') + ')');
- }
- return V[o](s, i);
- })(o, i.length, i)
- : o.apply(s, i);
- };
- return w(i) && (j.prototype = i), j;
- };
- },
- 13930: (s, o, i) => {
- 'use strict';
- var u = i(41505),
- _ = Function.prototype.call;
- s.exports = u
- ? _.bind(_)
- : function () {
- return _.apply(_, arguments);
- };
- },
- 36833: (s, o, i) => {
- 'use strict';
- var u = i(39447),
- _ = i(49724),
- w = Function.prototype,
- x = u && Object.getOwnPropertyDescriptor,
- C = _(w, 'name'),
- j = C && 'something' === function something() {}.name,
- L = C && (!u || (u && x(w, 'name').configurable));
- s.exports = { EXISTS: C, PROPER: j, CONFIGURABLE: L };
- },
- 51871: (s, o, i) => {
- 'use strict';
- var u = i(1907),
- _ = i(82159);
- s.exports = function (s, o, i) {
- try {
- return u(_(Object.getOwnPropertyDescriptor(s, o)[i]));
- } catch (s) {}
- };
- },
- 92361: (s, o, i) => {
- 'use strict';
- var u = i(45807),
- _ = i(1907);
- s.exports = function (s) {
- if ('Function' === u(s)) return _(s);
- };
- },
- 1907: (s, o, i) => {
- 'use strict';
- var u = i(41505),
- _ = Function.prototype,
- w = _.call,
- x = u && _.bind.bind(w, w);
- s.exports = u
- ? x
- : function (s) {
- return function () {
- return w.apply(s, arguments);
- };
- };
- },
- 61747: (s, o, i) => {
- 'use strict';
- var u = i(45951),
- _ = i(92046);
- s.exports = function (s, o) {
- var i = _[s + 'Prototype'],
- w = i && i[o];
- if (w) return w;
- var x = u[s],
- C = x && x.prototype;
- return C && C[o];
- };
- },
- 85582: (s, o, i) => {
- 'use strict';
- var u = i(92046),
- _ = i(45951),
- w = i(62250),
- aFunction = function (s) {
- return w(s) ? s : void 0;
- };
- s.exports = function (s, o) {
- return arguments.length < 2
- ? aFunction(u[s]) || aFunction(_[s])
- : (u[s] && u[s][o]) || (_[s] && _[s][o]);
- };
- },
- 73448: (s, o, i) => {
- 'use strict';
- var u = i(73948),
- _ = i(29367),
- w = i(87136),
- x = i(93742),
- C = i(76264)('iterator');
- s.exports = function (s) {
- if (!w(s)) return _(s, C) || _(s, '@@iterator') || x[u(s)];
- };
- },
- 10300: (s, o, i) => {
- 'use strict';
- var u = i(13930),
- _ = i(82159),
- w = i(36624),
- x = i(4640),
- C = i(73448),
- j = TypeError;
- s.exports = function (s, o) {
- var i = arguments.length < 2 ? C(s) : o;
- if (_(i)) return w(u(i, s));
- throw new j(x(s) + ' is not iterable');
- };
- },
- 29367: (s, o, i) => {
- 'use strict';
- var u = i(82159),
- _ = i(87136);
- s.exports = function (s, o) {
- var i = s[o];
- return _(i) ? void 0 : u(i);
- };
- },
- 45951: function (s, o, i) {
- 'use strict';
- var check = function (s) {
- return s && s.Math === Math && s;
- };
- s.exports =
- check('object' == typeof globalThis && globalThis) ||
- check('object' == typeof window && window) ||
- check('object' == typeof self && self) ||
- check('object' == typeof i.g && i.g) ||
- check('object' == typeof this && this) ||
- (function () {
- return this;
- })() ||
- Function('return this')();
- },
- 49724: (s, o, i) => {
- 'use strict';
- var u = i(1907),
- _ = i(39298),
- w = u({}.hasOwnProperty);
- s.exports =
- Object.hasOwn ||
- function hasOwn(s, o) {
- return w(_(s), o);
- };
- },
- 38530: (s) => {
- 'use strict';
- s.exports = {};
- },
- 62416: (s, o, i) => {
- 'use strict';
- var u = i(85582);
- s.exports = u('document', 'documentElement');
- },
- 73648: (s, o, i) => {
- 'use strict';
- var u = i(39447),
- _ = i(98828),
- w = i(49552);
- s.exports =
- !u &&
- !_(function () {
- return (
- 7 !==
- Object.defineProperty(w('div'), 'a', {
- get: function () {
- return 7;
- }
- }).a
- );
- });
- },
- 16946: (s, o, i) => {
- 'use strict';
- var u = i(1907),
- _ = i(98828),
- w = i(45807),
- x = Object,
- C = u(''.split);
- s.exports = _(function () {
- return !x('z').propertyIsEnumerable(0);
- })
- ? function (s) {
- return 'String' === w(s) ? C(s, '') : x(s);
- }
- : x;
- },
- 34084: (s, o, i) => {
- 'use strict';
- var u = i(62250),
- _ = i(46285),
- w = i(79192);
- s.exports = function (s, o, i) {
- var x, C;
- return (
- w &&
- u((x = o.constructor)) &&
- x !== i &&
- _((C = x.prototype)) &&
- C !== i.prototype &&
- w(s, C),
- s
- );
- };
- },
- 39259: (s, o, i) => {
- 'use strict';
- var u = i(46285),
- _ = i(61626);
- s.exports = function (s, o) {
- u(o) && 'cause' in o && _(s, 'cause', o.cause);
- };
- },
- 64932: (s, o, i) => {
- 'use strict';
- var u,
- _,
- w,
- x = i(40551),
- C = i(45951),
- j = i(46285),
- L = i(61626),
- B = i(49724),
- $ = i(36128),
- V = i(92522),
- U = i(38530),
- z = 'Object already initialized',
- Y = C.TypeError,
- Z = C.WeakMap;
- if (x || $.state) {
- var ee = $.state || ($.state = new Z());
- (ee.get = ee.get),
- (ee.has = ee.has),
- (ee.set = ee.set),
- (u = function (s, o) {
- if (ee.has(s)) throw new Y(z);
- return (o.facade = s), ee.set(s, o), o;
- }),
- (_ = function (s) {
- return ee.get(s) || {};
- }),
- (w = function (s) {
- return ee.has(s);
- });
- } else {
- var ie = V('state');
- (U[ie] = !0),
- (u = function (s, o) {
- if (B(s, ie)) throw new Y(z);
- return (o.facade = s), L(s, ie, o), o;
- }),
- (_ = function (s) {
- return B(s, ie) ? s[ie] : {};
- }),
- (w = function (s) {
- return B(s, ie);
- });
- }
- s.exports = {
- set: u,
- get: _,
- has: w,
- enforce: function (s) {
- return w(s) ? _(s) : u(s, {});
- },
- getterFor: function (s) {
- return function (o) {
- var i;
- if (!j(o) || (i = _(o)).type !== s)
- throw new Y('Incompatible receiver, ' + s + ' required');
- return i;
- };
- }
- };
- },
- 37812: (s, o, i) => {
- 'use strict';
- var u = i(76264),
- _ = i(93742),
- w = u('iterator'),
- x = Array.prototype;
- s.exports = function (s) {
- return void 0 !== s && (_.Array === s || x[w] === s);
- };
- },
- 62250: (s) => {
- 'use strict';
- var o = 'object' == typeof document && document.all;
- s.exports =
- void 0 === o && void 0 !== o
- ? function (s) {
- return 'function' == typeof s || s === o;
- }
- : function (s) {
- return 'function' == typeof s;
- };
- },
- 7463: (s, o, i) => {
- 'use strict';
- var u = i(98828),
- _ = i(62250),
- w = /#|\.prototype\./,
- isForced = function (s, o) {
- var i = C[x(s)];
- return i === L || (i !== j && (_(o) ? u(o) : !!o));
- },
- x = (isForced.normalize = function (s) {
- return String(s).replace(w, '.').toLowerCase();
- }),
- C = (isForced.data = {}),
- j = (isForced.NATIVE = 'N'),
- L = (isForced.POLYFILL = 'P');
- s.exports = isForced;
- },
- 87136: (s) => {
- 'use strict';
- s.exports = function (s) {
- return null == s;
- };
- },
- 46285: (s, o, i) => {
- 'use strict';
- var u = i(62250);
- s.exports = function (s) {
- return 'object' == typeof s ? null !== s : u(s);
- };
- },
- 54018: (s, o, i) => {
- 'use strict';
- var u = i(46285);
- s.exports = function (s) {
- return u(s) || null === s;
- };
- },
- 7376: (s) => {
- 'use strict';
- s.exports = !0;
- },
- 25594: (s, o, i) => {
- 'use strict';
- var u = i(85582),
- _ = i(62250),
- w = i(88280),
- x = i(51175),
- C = Object;
- s.exports = x
- ? function (s) {
- return 'symbol' == typeof s;
- }
- : function (s) {
- var o = u('Symbol');
- return _(o) && w(o.prototype, C(s));
- };
- },
- 24823: (s, o, i) => {
- 'use strict';
- var u = i(28311),
- _ = i(13930),
- w = i(36624),
- x = i(4640),
- C = i(37812),
- j = i(20575),
- L = i(88280),
- B = i(10300),
- $ = i(73448),
- V = i(40154),
- U = TypeError,
- Result = function (s, o) {
- (this.stopped = s), (this.result = o);
- },
- z = Result.prototype;
- s.exports = function (s, o, i) {
- var Y,
- Z,
- ee,
- ie,
- ae,
- le,
- ce,
- pe = i && i.that,
- de = !(!i || !i.AS_ENTRIES),
- fe = !(!i || !i.IS_RECORD),
- ye = !(!i || !i.IS_ITERATOR),
- be = !(!i || !i.INTERRUPTED),
- _e = u(o, pe),
- stop = function (s) {
- return Y && V(Y, 'normal', s), new Result(!0, s);
- },
- callFn = function (s) {
- return de
- ? (w(s), be ? _e(s[0], s[1], stop) : _e(s[0], s[1]))
- : be
- ? _e(s, stop)
- : _e(s);
- };
- if (fe) Y = s.iterator;
- else if (ye) Y = s;
- else {
- if (!(Z = $(s))) throw new U(x(s) + ' is not iterable');
- if (C(Z)) {
- for (ee = 0, ie = j(s); ie > ee; ee++)
- if ((ae = callFn(s[ee])) && L(z, ae)) return ae;
- return new Result(!1);
- }
- Y = B(s, Z);
- }
- for (le = fe ? s.next : Y.next; !(ce = _(le, Y)).done; ) {
- try {
- ae = callFn(ce.value);
- } catch (s) {
- V(Y, 'throw', s);
- }
- if ('object' == typeof ae && ae && L(z, ae)) return ae;
- }
- return new Result(!1);
- };
- },
- 40154: (s, o, i) => {
- 'use strict';
- var u = i(13930),
- _ = i(36624),
- w = i(29367);
- s.exports = function (s, o, i) {
- var x, C;
- _(s);
- try {
- if (!(x = w(s, 'return'))) {
- if ('throw' === o) throw i;
- return i;
- }
- x = u(x, s);
- } catch (s) {
- (C = !0), (x = s);
- }
- if ('throw' === o) throw i;
- if (C) throw x;
- return _(x), i;
- };
- },
- 47181: (s, o, i) => {
- 'use strict';
- var u = i(95116).IteratorPrototype,
- _ = i(58075),
- w = i(75817),
- x = i(14840),
- C = i(93742),
- returnThis = function () {
- return this;
- };
- s.exports = function (s, o, i, j) {
- var L = o + ' Iterator';
- return (
- (s.prototype = _(u, { next: w(+!j, i) })), x(s, L, !1, !0), (C[L] = returnThis), s
- );
- };
- },
- 60183: (s, o, i) => {
- 'use strict';
- var u = i(11091),
- _ = i(13930),
- w = i(7376),
- x = i(36833),
- C = i(62250),
- j = i(47181),
- L = i(15972),
- B = i(79192),
- $ = i(14840),
- V = i(61626),
- U = i(68055),
- z = i(76264),
- Y = i(93742),
- Z = i(95116),
- ee = x.PROPER,
- ie = x.CONFIGURABLE,
- ae = Z.IteratorPrototype,
- le = Z.BUGGY_SAFARI_ITERATORS,
- ce = z('iterator'),
- pe = 'keys',
- de = 'values',
- fe = 'entries',
- returnThis = function () {
- return this;
- };
- s.exports = function (s, o, i, x, z, Z, ye) {
- j(i, o, x);
- var be,
- _e,
- we,
- getIterationMethod = function (s) {
- if (s === z && Re) return Re;
- if (!le && s && s in Pe) return Pe[s];
- switch (s) {
- case pe:
- return function keys() {
- return new i(this, s);
- };
- case de:
- return function values() {
- return new i(this, s);
- };
- case fe:
- return function entries() {
- return new i(this, s);
- };
- }
- return function () {
- return new i(this);
- };
- },
- Se = o + ' Iterator',
- xe = !1,
- Pe = s.prototype,
- Te = Pe[ce] || Pe['@@iterator'] || (z && Pe[z]),
- Re = (!le && Te) || getIterationMethod(z),
- qe = ('Array' === o && Pe.entries) || Te;
- if (
- (qe &&
- (be = L(qe.call(new s()))) !== Object.prototype &&
- be.next &&
- (w || L(be) === ae || (B ? B(be, ae) : C(be[ce]) || U(be, ce, returnThis)),
- $(be, Se, !0, !0),
- w && (Y[Se] = returnThis)),
- ee &&
- z === de &&
- Te &&
- Te.name !== de &&
- (!w && ie
- ? V(Pe, 'name', de)
- : ((xe = !0),
- (Re = function values() {
- return _(Te, this);
- }))),
- z)
- )
- if (
- ((_e = {
- values: getIterationMethod(de),
- keys: Z ? Re : getIterationMethod(pe),
- entries: getIterationMethod(fe)
- }),
- ye)
- )
- for (we in _e) (le || xe || !(we in Pe)) && U(Pe, we, _e[we]);
- else u({ target: o, proto: !0, forced: le || xe }, _e);
- return (w && !ye) || Pe[ce] === Re || U(Pe, ce, Re, { name: z }), (Y[o] = Re), _e;
- };
- },
- 95116: (s, o, i) => {
- 'use strict';
- var u,
- _,
- w,
- x = i(98828),
- C = i(62250),
- j = i(46285),
- L = i(58075),
- B = i(15972),
- $ = i(68055),
- V = i(76264),
- U = i(7376),
- z = V('iterator'),
- Y = !1;
- [].keys &&
- ('next' in (w = [].keys()) ? (_ = B(B(w))) !== Object.prototype && (u = _) : (Y = !0)),
- !j(u) ||
- x(function () {
- var s = {};
- return u[z].call(s) !== s;
- })
- ? (u = {})
- : U && (u = L(u)),
- C(u[z]) ||
- $(u, z, function () {
- return this;
- }),
- (s.exports = { IteratorPrototype: u, BUGGY_SAFARI_ITERATORS: Y });
- },
- 93742: (s) => {
- 'use strict';
- s.exports = {};
- },
- 20575: (s, o, i) => {
- 'use strict';
- var u = i(3121);
- s.exports = function (s) {
- return u(s.length);
- };
- },
- 41176: (s) => {
- 'use strict';
- var o = Math.ceil,
- i = Math.floor;
- s.exports =
- Math.trunc ||
- function trunc(s) {
- var u = +s;
- return (u > 0 ? i : o)(u);
- };
- },
- 32096: (s, o, i) => {
- 'use strict';
- var u = i(90160);
- s.exports = function (s, o) {
- return void 0 === s ? (arguments.length < 2 ? '' : o) : u(s);
- };
- },
- 29538: (s, o, i) => {
- 'use strict';
- var u = i(39447),
- _ = i(1907),
- w = i(13930),
- x = i(98828),
- C = i(2875),
- j = i(87170),
- L = i(22574),
- B = i(39298),
- $ = i(16946),
- V = Object.assign,
- U = Object.defineProperty,
- z = _([].concat);
- s.exports =
- !V ||
- x(function () {
- if (
- u &&
- 1 !==
- V(
- { b: 1 },
- V(
- U({}, 'a', {
- enumerable: !0,
- get: function () {
- U(this, 'b', { value: 3, enumerable: !1 });
- }
- }),
- { b: 2 }
- )
- ).b
- )
- return !0;
- var s = {},
- o = {},
- i = Symbol('assign detection'),
- _ = 'abcdefghijklmnopqrst';
- return (
- (s[i] = 7),
- _.split('').forEach(function (s) {
- o[s] = s;
- }),
- 7 !== V({}, s)[i] || C(V({}, o)).join('') !== _
- );
- })
- ? function assign(s, o) {
- for (var i = B(s), _ = arguments.length, x = 1, V = j.f, U = L.f; _ > x; )
- for (
- var Y,
- Z = $(arguments[x++]),
- ee = V ? z(C(Z), V(Z)) : C(Z),
- ie = ee.length,
- ae = 0;
- ie > ae;
- )
- (Y = ee[ae++]), (u && !w(U, Z, Y)) || (i[Y] = Z[Y]);
- return i;
- }
- : V;
- },
- 58075: (s, o, i) => {
- 'use strict';
- var u,
- _ = i(36624),
- w = i(42220),
- x = i(80376),
- C = i(38530),
- j = i(62416),
- L = i(49552),
- B = i(92522),
- $ = 'prototype',
- V = 'script',
- U = B('IE_PROTO'),
- EmptyConstructor = function () {},
- scriptTag = function (s) {
- return '<' + V + '>' + s + '</' + V + '>';
- },
- NullProtoObjectViaActiveX = function (s) {
- s.write(scriptTag('')), s.close();
- var o = s.parentWindow.Object;
- return (s = null), o;
- },
- NullProtoObject = function () {
- try {
- u = new ActiveXObject('htmlfile');
- } catch (s) {}
- var s, o, i;
- NullProtoObject =
- 'undefined' != typeof document
- ? document.domain && u
- ? NullProtoObjectViaActiveX(u)
- : ((o = L('iframe')),
- (i = 'java' + V + ':'),
- (o.style.display = 'none'),
- j.appendChild(o),
- (o.src = String(i)),
- (s = o.contentWindow.document).open(),
- s.write(scriptTag('document.F=Object')),
- s.close(),
- s.F)
- : NullProtoObjectViaActiveX(u);
- for (var _ = x.length; _--; ) delete NullProtoObject[$][x[_]];
- return NullProtoObject();
- };
- (C[U] = !0),
- (s.exports =
- Object.create ||
- function create(s, o) {
- var i;
- return (
- null !== s
- ? ((EmptyConstructor[$] = _(s)),
- (i = new EmptyConstructor()),
- (EmptyConstructor[$] = null),
- (i[U] = s))
- : (i = NullProtoObject()),
- void 0 === o ? i : w.f(i, o)
- );
- });
- },
- 42220: (s, o, i) => {
- 'use strict';
- var u = i(39447),
- _ = i(58661),
- w = i(74284),
- x = i(36624),
- C = i(4993),
- j = i(2875);
- o.f =
- u && !_
- ? Object.defineProperties
- : function defineProperties(s, o) {
- x(s);
- for (var i, u = C(o), _ = j(o), L = _.length, B = 0; L > B; )
- w.f(s, (i = _[B++]), u[i]);
- return s;
- };
- },
- 74284: (s, o, i) => {
- 'use strict';
- var u = i(39447),
- _ = i(73648),
- w = i(58661),
- x = i(36624),
- C = i(70470),
- j = TypeError,
- L = Object.defineProperty,
- B = Object.getOwnPropertyDescriptor,
- $ = 'enumerable',
- V = 'configurable',
- U = 'writable';
- o.f = u
- ? w
- ? function defineProperty(s, o, i) {
- if (
- (x(s),
- (o = C(o)),
- x(i),
- 'function' == typeof s && 'prototype' === o && 'value' in i && U in i && !i[U])
- ) {
- var u = B(s, o);
- u &&
- u[U] &&
- ((s[o] = i.value),
- (i = {
- configurable: V in i ? i[V] : u[V],
- enumerable: $ in i ? i[$] : u[$],
- writable: !1
- }));
- }
- return L(s, o, i);
- }
- : L
- : function defineProperty(s, o, i) {
- if ((x(s), (o = C(o)), x(i), _))
- try {
- return L(s, o, i);
- } catch (s) {}
- if ('get' in i || 'set' in i) throw new j('Accessors not supported');
- return 'value' in i && (s[o] = i.value), s;
- };
- },
- 13846: (s, o, i) => {
- 'use strict';
- var u = i(39447),
- _ = i(13930),
- w = i(22574),
- x = i(75817),
- C = i(4993),
- j = i(70470),
- L = i(49724),
- B = i(73648),
- $ = Object.getOwnPropertyDescriptor;
- o.f = u
- ? $
- : function getOwnPropertyDescriptor(s, o) {
- if (((s = C(s)), (o = j(o)), B))
- try {
- return $(s, o);
- } catch (s) {}
- if (L(s, o)) return x(!_(w.f, s, o), s[o]);
- };
- },
- 24443: (s, o, i) => {
- 'use strict';
- var u = i(23045),
- _ = i(80376).concat('length', 'prototype');
- o.f =
- Object.getOwnPropertyNames ||
- function getOwnPropertyNames(s) {
- return u(s, _);
- };
- },
- 87170: (s, o) => {
- 'use strict';
- o.f = Object.getOwnPropertySymbols;
- },
- 15972: (s, o, i) => {
- 'use strict';
- var u = i(49724),
- _ = i(62250),
- w = i(39298),
- x = i(92522),
- C = i(57382),
- j = x('IE_PROTO'),
- L = Object,
- B = L.prototype;
- s.exports = C
- ? L.getPrototypeOf
- : function (s) {
- var o = w(s);
- if (u(o, j)) return o[j];
- var i = o.constructor;
- return _(i) && o instanceof i ? i.prototype : o instanceof L ? B : null;
- };
- },
- 88280: (s, o, i) => {
- 'use strict';
- var u = i(1907);
- s.exports = u({}.isPrototypeOf);
- },
- 23045: (s, o, i) => {
- 'use strict';
- var u = i(1907),
- _ = i(49724),
- w = i(4993),
- x = i(74436).indexOf,
- C = i(38530),
- j = u([].push);
- s.exports = function (s, o) {
- var i,
- u = w(s),
- L = 0,
- B = [];
- for (i in u) !_(C, i) && _(u, i) && j(B, i);
- for (; o.length > L; ) _(u, (i = o[L++])) && (~x(B, i) || j(B, i));
- return B;
- };
- },
- 2875: (s, o, i) => {
- 'use strict';
- var u = i(23045),
- _ = i(80376);
- s.exports =
- Object.keys ||
- function keys(s) {
- return u(s, _);
- };
- },
- 22574: (s, o) => {
- 'use strict';
- var i = {}.propertyIsEnumerable,
- u = Object.getOwnPropertyDescriptor,
- _ = u && !i.call({ 1: 2 }, 1);
- o.f = _
- ? function propertyIsEnumerable(s) {
- var o = u(this, s);
- return !!o && o.enumerable;
- }
- : i;
- },
- 79192: (s, o, i) => {
- 'use strict';
- var u = i(51871),
- _ = i(46285),
- w = i(74239),
- x = i(10043);
- s.exports =
- Object.setPrototypeOf ||
- ('__proto__' in {}
- ? (function () {
- var s,
- o = !1,
- i = {};
- try {
- (s = u(Object.prototype, '__proto__', 'set'))(i, []), (o = i instanceof Array);
- } catch (s) {}
- return function setPrototypeOf(i, u) {
- return w(i), x(u), _(i) ? (o ? s(i, u) : (i.__proto__ = u), i) : i;
- };
- })()
- : void 0);
- },
- 54878: (s, o, i) => {
- 'use strict';
- var u = i(52623),
- _ = i(73948);
- s.exports = u
- ? {}.toString
- : function toString() {
- return '[object ' + _(this) + ']';
- };
- },
- 60581: (s, o, i) => {
- 'use strict';
- var u = i(13930),
- _ = i(62250),
- w = i(46285),
- x = TypeError;
- s.exports = function (s, o) {
- var i, C;
- if ('string' === o && _((i = s.toString)) && !w((C = u(i, s)))) return C;
- if (_((i = s.valueOf)) && !w((C = u(i, s)))) return C;
- if ('string' !== o && _((i = s.toString)) && !w((C = u(i, s)))) return C;
- throw new x("Can't convert object to primitive value");
- };
- },
- 11042: (s, o, i) => {
- 'use strict';
- var u = i(85582),
- _ = i(1907),
- w = i(24443),
- x = i(87170),
- C = i(36624),
- j = _([].concat);
- s.exports =
- u('Reflect', 'ownKeys') ||
- function ownKeys(s) {
- var o = w.f(C(s)),
- i = x.f;
- return i ? j(o, i(s)) : o;
- };
- },
- 92046: (s) => {
- 'use strict';
- s.exports = {};
- },
- 54829: (s, o, i) => {
- 'use strict';
- var u = i(74284).f;
- s.exports = function (s, o, i) {
- i in s ||
- u(s, i, {
- configurable: !0,
- get: function () {
- return o[i];
- },
- set: function (s) {
- o[i] = s;
- }
- });
- };
- },
- 74239: (s, o, i) => {
- 'use strict';
- var u = i(87136),
- _ = TypeError;
- s.exports = function (s) {
- if (u(s)) throw new _("Can't call method on " + s);
- return s;
- };
- },
- 14840: (s, o, i) => {
- 'use strict';
- var u = i(52623),
- _ = i(74284).f,
- w = i(61626),
- x = i(49724),
- C = i(54878),
- j = i(76264)('toStringTag');
- s.exports = function (s, o, i, L) {
- var B = i ? s : s && s.prototype;
- B &&
- (x(B, j) || _(B, j, { configurable: !0, value: o }), L && !u && w(B, 'toString', C));
- };
- },
- 92522: (s, o, i) => {
- 'use strict';
- var u = i(85816),
- _ = i(6499),
- w = u('keys');
- s.exports = function (s) {
- return w[s] || (w[s] = _(s));
- };
- },
- 36128: (s, o, i) => {
- 'use strict';
- var u = i(7376),
- _ = i(45951),
- w = i(2532),
- x = '__core-js_shared__',
- C = (s.exports = _[x] || w(x, {}));
- (C.versions || (C.versions = [])).push({
- version: '3.39.0',
- mode: u ? 'pure' : 'global',
- copyright: '© 2014-2024 Denis Pushkarev (zloirock.ru)',
- license: 'https://github.com/zloirock/core-js/blob/v3.39.0/LICENSE',
- source: 'https://github.com/zloirock/core-js'
- });
- },
- 85816: (s, o, i) => {
- 'use strict';
- var u = i(36128);
- s.exports = function (s, o) {
- return u[s] || (u[s] = o || {});
- };
- },
- 11470: (s, o, i) => {
- 'use strict';
- var u = i(1907),
- _ = i(65482),
- w = i(90160),
- x = i(74239),
- C = u(''.charAt),
- j = u(''.charCodeAt),
- L = u(''.slice),
- createMethod = function (s) {
- return function (o, i) {
- var u,
- B,
- $ = w(x(o)),
- V = _(i),
- U = $.length;
- return V < 0 || V >= U
- ? s
- ? ''
- : void 0
- : (u = j($, V)) < 55296 ||
- u > 56319 ||
- V + 1 === U ||
- (B = j($, V + 1)) < 56320 ||
- B > 57343
- ? s
- ? C($, V)
- : u
- : s
- ? L($, V, V + 2)
- : B - 56320 + ((u - 55296) << 10) + 65536;
- };
- };
- s.exports = { codeAt: createMethod(!1), charAt: createMethod(!0) };
- },
- 19846: (s, o, i) => {
- 'use strict';
- var u = i(20798),
- _ = i(98828),
- w = i(45951).String;
- s.exports =
- !!Object.getOwnPropertySymbols &&
- !_(function () {
- var s = Symbol('symbol detection');
- return !w(s) || !(Object(s) instanceof Symbol) || (!Symbol.sham && u && u < 41);
- });
- },
- 34849: (s, o, i) => {
- 'use strict';
- var u = i(65482),
- _ = Math.max,
- w = Math.min;
- s.exports = function (s, o) {
- var i = u(s);
- return i < 0 ? _(i + o, 0) : w(i, o);
- };
- },
- 4993: (s, o, i) => {
- 'use strict';
- var u = i(16946),
- _ = i(74239);
- s.exports = function (s) {
- return u(_(s));
- };
- },
- 65482: (s, o, i) => {
- 'use strict';
- var u = i(41176);
- s.exports = function (s) {
- var o = +s;
- return o != o || 0 === o ? 0 : u(o);
- };
- },
- 3121: (s, o, i) => {
- 'use strict';
- var u = i(65482),
- _ = Math.min;
- s.exports = function (s) {
- var o = u(s);
- return o > 0 ? _(o, 9007199254740991) : 0;
- };
- },
- 39298: (s, o, i) => {
- 'use strict';
- var u = i(74239),
- _ = Object;
- s.exports = function (s) {
- return _(u(s));
- };
- },
- 46028: (s, o, i) => {
- 'use strict';
- var u = i(13930),
- _ = i(46285),
- w = i(25594),
- x = i(29367),
- C = i(60581),
- j = i(76264),
- L = TypeError,
- B = j('toPrimitive');
- s.exports = function (s, o) {
- if (!_(s) || w(s)) return s;
- var i,
- j = x(s, B);
- if (j) {
- if ((void 0 === o && (o = 'default'), (i = u(j, s, o)), !_(i) || w(i))) return i;
- throw new L("Can't convert object to primitive value");
- }
- return void 0 === o && (o = 'number'), C(s, o);
- };
- },
- 70470: (s, o, i) => {
- 'use strict';
- var u = i(46028),
- _ = i(25594);
- s.exports = function (s) {
- var o = u(s, 'string');
- return _(o) ? o : o + '';
- };
- },
- 52623: (s, o, i) => {
- 'use strict';
- var u = {};
- (u[i(76264)('toStringTag')] = 'z'), (s.exports = '[object z]' === String(u));
- },
- 90160: (s, o, i) => {
- 'use strict';
- var u = i(73948),
- _ = String;
- s.exports = function (s) {
- if ('Symbol' === u(s)) throw new TypeError('Cannot convert a Symbol value to a string');
- return _(s);
- };
- },
- 4640: (s) => {
- 'use strict';
- var o = String;
- s.exports = function (s) {
- try {
- return o(s);
- } catch (s) {
- return 'Object';
- }
- };
- },
- 6499: (s, o, i) => {
- 'use strict';
- var u = i(1907),
- _ = 0,
- w = Math.random(),
- x = u((1).toString);
- s.exports = function (s) {
- return 'Symbol(' + (void 0 === s ? '' : s) + ')_' + x(++_ + w, 36);
- };
- },
- 51175: (s, o, i) => {
- 'use strict';
- var u = i(19846);
- s.exports = u && !Symbol.sham && 'symbol' == typeof Symbol.iterator;
- },
- 58661: (s, o, i) => {
- 'use strict';
- var u = i(39447),
- _ = i(98828);
- s.exports =
- u &&
- _(function () {
- return (
- 42 !==
- Object.defineProperty(function () {}, 'prototype', { value: 42, writable: !1 })
- .prototype
- );
- });
- },
- 40551: (s, o, i) => {
- 'use strict';
- var u = i(45951),
- _ = i(62250),
- w = u.WeakMap;
- s.exports = _(w) && /native code/.test(String(w));
- },
- 76264: (s, o, i) => {
- 'use strict';
- var u = i(45951),
- _ = i(85816),
- w = i(49724),
- x = i(6499),
- C = i(19846),
- j = i(51175),
- L = u.Symbol,
- B = _('wks'),
- $ = j ? L.for || L : (L && L.withoutSetter) || x;
- s.exports = function (s) {
- return w(B, s) || (B[s] = C && w(L, s) ? L[s] : $('Symbol.' + s)), B[s];
- };
- },
- 19358: (s, o, i) => {
- 'use strict';
- var u = i(85582),
- _ = i(49724),
- w = i(61626),
- x = i(88280),
- C = i(79192),
- j = i(19595),
- L = i(54829),
- B = i(34084),
- $ = i(32096),
- V = i(39259),
- U = i(85884),
- z = i(39447),
- Y = i(7376);
- s.exports = function (s, o, i, Z) {
- var ee = 'stackTraceLimit',
- ie = Z ? 2 : 1,
- ae = s.split('.'),
- le = ae[ae.length - 1],
- ce = u.apply(null, ae);
- if (ce) {
- var pe = ce.prototype;
- if ((!Y && _(pe, 'cause') && delete pe.cause, !i)) return ce;
- var de = u('Error'),
- fe = o(function (s, o) {
- var i = $(Z ? o : s, void 0),
- u = Z ? new ce(s) : new ce();
- return (
- void 0 !== i && w(u, 'message', i),
- U(u, fe, u.stack, 2),
- this && x(pe, this) && B(u, this, fe),
- arguments.length > ie && V(u, arguments[ie]),
- u
- );
- });
- if (
- ((fe.prototype = pe),
- 'Error' !== le
- ? C
- ? C(fe, de)
- : j(fe, de, { name: !0 })
- : z && ee in ce && (L(fe, ce, ee), L(fe, ce, 'prepareStackTrace')),
- j(fe, ce),
- !Y)
- )
- try {
- pe.name !== le && w(pe, 'name', le), (pe.constructor = fe);
- } catch (s) {}
- return fe;
- }
- };
- },
- 36371: (s, o, i) => {
- 'use strict';
- var u = i(11091),
- _ = i(85582),
- w = i(76024),
- x = i(98828),
- C = i(19358),
- j = 'AggregateError',
- L = _(j),
- B =
- !x(function () {
- return 1 !== L([1]).errors[0];
- }) &&
- x(function () {
- return 7 !== L([1], j, { cause: 7 }).cause;
- });
- u(
- { global: !0, constructor: !0, arity: 2, forced: B },
- {
- AggregateError: C(
- j,
- function (s) {
- return function AggregateError(o, i) {
- return w(s, this, arguments);
- };
- },
- B,
- !0
- )
- }
- );
- },
- 82048: (s, o, i) => {
- 'use strict';
- var u = i(11091),
- _ = i(88280),
- w = i(15972),
- x = i(79192),
- C = i(19595),
- j = i(58075),
- L = i(61626),
- B = i(75817),
- $ = i(39259),
- V = i(85884),
- U = i(24823),
- z = i(32096),
- Y = i(76264)('toStringTag'),
- Z = Error,
- ee = [].push,
- ie = function AggregateError(s, o) {
- var i,
- u = _(ae, this);
- x ? (i = x(new Z(), u ? w(this) : ae)) : ((i = u ? this : j(ae)), L(i, Y, 'Error')),
- void 0 !== o && L(i, 'message', z(o)),
- V(i, ie, i.stack, 1),
- arguments.length > 2 && $(i, arguments[2]);
- var C = [];
- return U(s, ee, { that: C }), L(i, 'errors', C), i;
- };
- x ? x(ie, Z) : C(ie, Z, { name: !0 });
- var ae = (ie.prototype = j(Z.prototype, {
- constructor: B(1, ie),
- message: B(1, ''),
- name: B(1, 'AggregateError')
- }));
- u({ global: !0, constructor: !0, arity: 2 }, { AggregateError: ie });
- },
- 64502: (s, o, i) => {
- 'use strict';
- i(82048);
- },
- 99363: (s, o, i) => {
- 'use strict';
- var u = i(4993),
- _ = i(42156),
- w = i(93742),
- x = i(64932),
- C = i(74284).f,
- j = i(60183),
- L = i(59550),
- B = i(7376),
- $ = i(39447),
- V = 'Array Iterator',
- U = x.set,
- z = x.getterFor(V);
- s.exports = j(
- Array,
- 'Array',
- function (s, o) {
- U(this, { type: V, target: u(s), index: 0, kind: o });
- },
- function () {
- var s = z(this),
- o = s.target,
- i = s.index++;
- if (!o || i >= o.length) return (s.target = null), L(void 0, !0);
- switch (s.kind) {
- case 'keys':
- return L(i, !1);
- case 'values':
- return L(o[i], !1);
- }
- return L([i, o[i]], !1);
- },
- 'values'
- );
- var Y = (w.Arguments = w.Array);
- if ((_('keys'), _('values'), _('entries'), !B && $ && 'values' !== Y.name))
- try {
- C(Y, 'name', { value: 'values' });
- } catch (s) {}
- },
- 96605: (s, o, i) => {
- 'use strict';
- var u = i(11091),
- _ = i(45951),
- w = i(76024),
- x = i(19358),
- C = 'WebAssembly',
- j = _[C],
- L = 7 !== new Error('e', { cause: 7 }).cause,
- exportGlobalErrorCauseWrapper = function (s, o) {
- var i = {};
- (i[s] = x(s, o, L)), u({ global: !0, constructor: !0, arity: 1, forced: L }, i);
- },
- exportWebAssemblyErrorCauseWrapper = function (s, o) {
- if (j && j[s]) {
- var i = {};
- (i[s] = x(C + '.' + s, o, L)),
- u({ target: C, stat: !0, constructor: !0, arity: 1, forced: L }, i);
- }
- };
- exportGlobalErrorCauseWrapper('Error', function (s) {
- return function Error(o) {
- return w(s, this, arguments);
- };
- }),
- exportGlobalErrorCauseWrapper('EvalError', function (s) {
- return function EvalError(o) {
- return w(s, this, arguments);
- };
- }),
- exportGlobalErrorCauseWrapper('RangeError', function (s) {
- return function RangeError(o) {
- return w(s, this, arguments);
- };
- }),
- exportGlobalErrorCauseWrapper('ReferenceError', function (s) {
- return function ReferenceError(o) {
- return w(s, this, arguments);
- };
- }),
- exportGlobalErrorCauseWrapper('SyntaxError', function (s) {
- return function SyntaxError(o) {
- return w(s, this, arguments);
- };
- }),
- exportGlobalErrorCauseWrapper('TypeError', function (s) {
- return function TypeError(o) {
- return w(s, this, arguments);
- };
- }),
- exportGlobalErrorCauseWrapper('URIError', function (s) {
- return function URIError(o) {
- return w(s, this, arguments);
- };
- }),
- exportWebAssemblyErrorCauseWrapper('CompileError', function (s) {
- return function CompileError(o) {
- return w(s, this, arguments);
- };
- }),
- exportWebAssemblyErrorCauseWrapper('LinkError', function (s) {
- return function LinkError(o) {
- return w(s, this, arguments);
- };
- }),
- exportWebAssemblyErrorCauseWrapper('RuntimeError', function (s) {
- return function RuntimeError(o) {
- return w(s, this, arguments);
- };
- });
- },
- 79307: (s, o, i) => {
- 'use strict';
- var u = i(11091),
- _ = i(44673);
- u({ target: 'Function', proto: !0, forced: Function.bind !== _ }, { bind: _ });
- },
- 71340: (s, o, i) => {
- 'use strict';
- var u = i(11091),
- _ = i(29538);
- u({ target: 'Object', stat: !0, arity: 2, forced: Object.assign !== _ }, { assign: _ });
- },
- 7057: (s, o, i) => {
- 'use strict';
- var u = i(11470).charAt,
- _ = i(90160),
- w = i(64932),
- x = i(60183),
- C = i(59550),
- j = 'String Iterator',
- L = w.set,
- B = w.getterFor(j);
- x(
- String,
- 'String',
- function (s) {
- L(this, { type: j, string: _(s), index: 0 });
- },
- function next() {
- var s,
- o = B(this),
- i = o.string,
- _ = o.index;
- return _ >= i.length
- ? C(void 0, !0)
- : ((s = u(i, _)), (o.index += s.length), C(s, !1));
- }
- );
- },
- 91599: (s, o, i) => {
- 'use strict';
- i(64502);
- },
- 12560: (s, o, i) => {
- 'use strict';
- i(99363);
- var u = i(19287),
- _ = i(45951),
- w = i(14840),
- x = i(93742);
- for (var C in u) w(_[C], C), (x[C] = x.Array);
- },
- 694: (s, o, i) => {
- 'use strict';
- i(91599);
- var u = i(37257);
- i(12560), (s.exports = u);
- },
- 19709: (s, o, i) => {
- 'use strict';
- var u = i(23034);
- s.exports = u;
- },
- 40975: (s, o, i) => {
- 'use strict';
- var u = i(9748);
- s.exports = u;
- }
- },
- u = {};
- function __webpack_require__(s) {
- var o = u[s];
- if (void 0 !== o) return o.exports;
- var _ = (u[s] = { id: s, loaded: !1, exports: {} });
- return i[s].call(_.exports, _, _.exports, __webpack_require__), (_.loaded = !0), _.exports;
- }
- (__webpack_require__.n = (s) => {
- var o = s && s.__esModule ? () => s.default : () => s;
- return __webpack_require__.d(o, { a: o }), o;
- }),
- (o = Object.getPrototypeOf ? (s) => Object.getPrototypeOf(s) : (s) => s.__proto__),
- (__webpack_require__.t = function (i, u) {
- if ((1 & u && (i = this(i)), 8 & u)) return i;
- if ('object' == typeof i && i) {
- if (4 & u && i.__esModule) return i;
- if (16 & u && 'function' == typeof i.then) return i;
- }
- var _ = Object.create(null);
- __webpack_require__.r(_);
- var w = {};
- s = s || [null, o({}), o([]), o(o)];
- for (var x = 2 & u && i; 'object' == typeof x && !~s.indexOf(x); x = o(x))
- Object.getOwnPropertyNames(x).forEach((s) => (w[s] = () => i[s]));
- return (w.default = () => i), __webpack_require__.d(_, w), _;
- }),
- (__webpack_require__.d = (s, o) => {
- for (var i in o)
- __webpack_require__.o(o, i) &&
- !__webpack_require__.o(s, i) &&
- Object.defineProperty(s, i, { enumerable: !0, get: o[i] });
- }),
- (__webpack_require__.g = (function () {
- if ('object' == typeof globalThis) return globalThis;
- try {
- return this || new Function('return this')();
- } catch (s) {
- if ('object' == typeof window) return window;
- }
- })()),
- (__webpack_require__.o = (s, o) => Object.prototype.hasOwnProperty.call(s, o)),
- (__webpack_require__.r = (s) => {
- 'undefined' != typeof Symbol &&
- Symbol.toStringTag &&
- Object.defineProperty(s, Symbol.toStringTag, { value: 'Module' }),
- Object.defineProperty(s, '__esModule', { value: !0 });
- }),
- (__webpack_require__.nmd = (s) => ((s.paths = []), s.children || (s.children = []), s));
- var _ = {};
- return (
- (() => {
- 'use strict';
- __webpack_require__.d(_, { default: () => WI });
- var s = {};
- __webpack_require__.r(s),
- __webpack_require__.d(s, {
- CLEAR: () => ot,
- CLEAR_BY: () => it,
- NEW_AUTH_ERR: () => st,
- NEW_SPEC_ERR: () => rt,
- NEW_SPEC_ERR_BATCH: () => nt,
- NEW_THROWN_ERR: () => et,
- NEW_THROWN_ERR_BATCH: () => tt,
- clear: () => clear,
- clearBy: () => clearBy,
- newAuthErr: () => newAuthErr,
- newSpecErr: () => newSpecErr,
- newSpecErrBatch: () => newSpecErrBatch,
- newThrownErr: () => newThrownErr,
- newThrownErrBatch: () => newThrownErrBatch
- });
- var o = {};
- __webpack_require__.r(o),
- __webpack_require__.d(o, {
- AUTHORIZE: () => Nt,
- AUTHORIZE_OAUTH2: () => Lt,
- CONFIGURE_AUTH: () => Ft,
- LOGOUT: () => Rt,
- PRE_AUTHORIZE_OAUTH2: () => Dt,
- RESTORE_AUTHORIZATION: () => qt,
- SHOW_AUTH_POPUP: () => Tt,
- VALIDATE: () => Bt,
- authPopup: () => authPopup,
- authorize: () => authorize,
- authorizeAccessCodeWithBasicAuthentication: () =>
- authorizeAccessCodeWithBasicAuthentication,
- authorizeAccessCodeWithFormParams: () => authorizeAccessCodeWithFormParams,
- authorizeApplication: () => authorizeApplication,
- authorizeOauth2: () => authorizeOauth2,
- authorizeOauth2WithPersistOption: () => authorizeOauth2WithPersistOption,
- authorizePassword: () => authorizePassword,
- authorizeRequest: () => authorizeRequest,
- authorizeWithPersistOption: () => authorizeWithPersistOption,
- configureAuth: () => configureAuth,
- logout: () => logout,
- logoutWithPersistOption: () => logoutWithPersistOption,
- persistAuthorizationIfNeeded: () => persistAuthorizationIfNeeded,
- preAuthorizeImplicit: () => preAuthorizeImplicit,
- restoreAuthorization: () => restoreAuthorization,
- showDefinitions: () => showDefinitions
- });
- var i = {};
- __webpack_require__.r(i),
- __webpack_require__.d(i, {
- authorized: () => Ht,
- definitionsForRequirements: () => definitionsForRequirements,
- definitionsToAuthorize: () => Kt,
- getConfigs: () => Jt,
- getDefinitionsByNames: () => getDefinitionsByNames,
- isAuthorized: () => isAuthorized,
- shownDefinitions: () => Wt
- });
- var u = {};
- __webpack_require__.r(u),
- __webpack_require__.d(u, {
- TOGGLE_CONFIGS: () => yn,
- UPDATE_CONFIGS: () => gn,
- downloadConfig: () => downloadConfig,
- getConfigByUrl: () => getConfigByUrl,
- loaded: () => actions_loaded,
- toggle: () => toggle,
- update: () => update
- });
- var w = {};
- __webpack_require__.r(w), __webpack_require__.d(w, { get: () => get });
- var x = {};
- __webpack_require__.r(x), __webpack_require__.d(x, { transform: () => transform });
- var C = {};
- __webpack_require__.r(C),
- __webpack_require__.d(C, { transform: () => parameter_oneof_transform });
- var j = {};
- __webpack_require__.r(j),
- __webpack_require__.d(j, { allErrors: () => Mn, lastError: () => Tn });
- var L = {};
- __webpack_require__.r(L),
- __webpack_require__.d(L, {
- SHOW: () => Fn,
- UPDATE_FILTER: () => Ln,
- UPDATE_LAYOUT: () => Dn,
- UPDATE_MODE: () => Bn,
- changeMode: () => changeMode,
- show: () => actions_show,
- updateFilter: () => updateFilter,
- updateLayout: () => updateLayout
- });
- var B = {};
- __webpack_require__.r(B),
- __webpack_require__.d(B, {
- current: () => current,
- currentFilter: () => currentFilter,
- isShown: () => isShown,
- showSummary: () => $n,
- whatMode: () => whatMode
- });
- var $ = {};
- __webpack_require__.r($),
- __webpack_require__.d($, { taggedOperations: () => taggedOperations });
- var V = {};
- __webpack_require__.r(V),
- __webpack_require__.d(V, {
- requestSnippetGenerator_curl_bash: () => requestSnippetGenerator_curl_bash,
- requestSnippetGenerator_curl_cmd: () => requestSnippetGenerator_curl_cmd,
- requestSnippetGenerator_curl_powershell: () => requestSnippetGenerator_curl_powershell
- });
- var U = {};
- __webpack_require__.r(U),
- __webpack_require__.d(U, {
- getActiveLanguage: () => zn,
- getDefaultExpanded: () => Wn,
- getGenerators: () => Un,
- getSnippetGenerators: () => getSnippetGenerators
- });
- var z = {};
- __webpack_require__.r(z),
- __webpack_require__.d(z, {
- JsonSchemaArrayItemFile: () => JsonSchemaArrayItemFile,
- JsonSchemaArrayItemText: () => JsonSchemaArrayItemText,
- JsonSchemaForm: () => JsonSchemaForm,
- JsonSchema_array: () => JsonSchema_array,
- JsonSchema_boolean: () => JsonSchema_boolean,
- JsonSchema_object: () => JsonSchema_object,
- JsonSchema_string: () => JsonSchema_string
- });
- var Y = {};
- __webpack_require__.r(Y),
- __webpack_require__.d(Y, {
- allowTryItOutFor: () => allowTryItOutFor,
- basePath: () => Ks,
- canExecuteScheme: () => canExecuteScheme,
- consumes: () => $s,
- consumesOptionsFor: () => consumesOptionsFor,
- contentTypeValues: () => contentTypeValues,
- currentProducesFor: () => currentProducesFor,
- definitions: () => Ws,
- externalDocs: () => Rs,
- findDefinition: () => findDefinition,
- getOAS3RequiredRequestBodyContentType: () => getOAS3RequiredRequestBodyContentType,
- getParameter: () => getParameter,
- hasHost: () => to,
- host: () => Hs,
- info: () => Ns,
- isMediaTypeSchemaPropertiesEqual: () => isMediaTypeSchemaPropertiesEqual,
- isOAS3: () => Ts,
- lastError: () => ks,
- mutatedRequestFor: () => mutatedRequestFor,
- mutatedRequests: () => eo,
- operationScheme: () => operationScheme,
- operationWithMeta: () => operationWithMeta,
- operations: () => qs,
- operationsWithRootInherited: () => Gs,
- operationsWithTags: () => Xs,
- parameterInclusionSettingFor: () => parameterInclusionSettingFor,
- parameterValues: () => parameterValues,
- parameterWithMeta: () => parameterWithMeta,
- parameterWithMetaByIdentity: () => parameterWithMetaByIdentity,
- parametersIncludeIn: () => parametersIncludeIn,
- parametersIncludeType: () => parametersIncludeType,
- paths: () => Bs,
- produces: () => Vs,
- producesOptionsFor: () => producesOptionsFor,
- requestFor: () => requestFor,
- requests: () => Qs,
- responseFor: () => responseFor,
- responses: () => Zs,
- schemes: () => Js,
- security: () => Us,
- securityDefinitions: () => zs,
- semver: () => Ls,
- spec: () => spec,
- specJS: () => Is,
- specJson: () => js,
- specJsonWithResolvedSubtrees: () => Ms,
- specResolved: () => Ps,
- specResolvedSubtree: () => specResolvedSubtree,
- specSource: () => As,
- specStr: () => Os,
- tagDetails: () => tagDetails,
- taggedOperations: () => selectors_taggedOperations,
- tags: () => Ys,
- url: () => Cs,
- validOperationMethods: () => Fs,
- validateBeforeExecute: () => validateBeforeExecute,
- validationErrors: () => validationErrors,
- version: () => Ds
- });
- var Z = {};
- __webpack_require__.r(Z),
- __webpack_require__.d(Z, {
- CLEAR_REQUEST: () => wo,
- CLEAR_RESPONSE: () => Eo,
- CLEAR_VALIDATE_PARAMS: () => So,
- LOG_REQUEST: () => _o,
- SET_MUTATED_REQUEST: () => bo,
- SET_REQUEST: () => vo,
- SET_RESPONSE: () => yo,
- SET_SCHEME: () => Oo,
- UPDATE_EMPTY_PARAM_INCLUSION: () => mo,
- UPDATE_JSON: () => ho,
- UPDATE_OPERATION_META_VALUE: () => xo,
- UPDATE_PARAM: () => fo,
- UPDATE_RESOLVED: () => ko,
- UPDATE_RESOLVED_SUBTREE: () => Co,
- UPDATE_SPEC: () => uo,
- UPDATE_URL: () => po,
- VALIDATE_PARAMS: () => go,
- changeConsumesValue: () => changeConsumesValue,
- changeParam: () => changeParam,
- changeParamByIdentity: () => changeParamByIdentity,
- changeProducesValue: () => changeProducesValue,
- clearRequest: () => clearRequest,
- clearResponse: () => clearResponse,
- clearValidateParams: () => clearValidateParams,
- execute: () => actions_execute,
- executeRequest: () => executeRequest,
- invalidateResolvedSubtreeCache: () => invalidateResolvedSubtreeCache,
- logRequest: () => logRequest,
- parseToJson: () => parseToJson,
- requestResolvedSubtree: () => requestResolvedSubtree,
- resolveSpec: () => resolveSpec,
- setMutatedRequest: () => setMutatedRequest,
- setRequest: () => setRequest,
- setResponse: () => setResponse,
- setScheme: () => setScheme,
- updateEmptyParamInclusion: () => updateEmptyParamInclusion,
- updateJsonSpec: () => updateJsonSpec,
- updateResolved: () => updateResolved,
- updateResolvedSubtree: () => updateResolvedSubtree,
- updateSpec: () => updateSpec,
- updateUrl: () => updateUrl,
- validateParams: () => validateParams
- });
- var ee = {};
- __webpack_require__.r(ee),
- __webpack_require__.d(ee, {
- executeRequest: () => wrap_actions_executeRequest,
- updateJsonSpec: () => wrap_actions_updateJsonSpec,
- updateSpec: () => wrap_actions_updateSpec,
- validateParams: () => wrap_actions_validateParams
- });
- var ie = {};
- __webpack_require__.r(ie),
- __webpack_require__.d(ie, {
- JsonPatchError: () => Ro,
- _areEquals: () => _areEquals,
- applyOperation: () => applyOperation,
- applyPatch: () => applyPatch,
- applyReducer: () => applyReducer,
- deepClone: () => Do,
- getValueByPointer: () => getValueByPointer,
- validate: () => validate,
- validator: () => validator
- });
- var ae = {};
- __webpack_require__.r(ae),
- __webpack_require__.d(ae, {
- compare: () => compare,
- generate: () => generate,
- observe: () => observe,
- unobserve: () => unobserve
- });
- var le = {};
- __webpack_require__.r(le),
- __webpack_require__.d(le, {
- hasElementSourceMap: () => hasElementSourceMap,
- includesClasses: () => includesClasses,
- includesSymbols: () => includesSymbols,
- isAnnotationElement: () => zu,
- isArrayElement: () => qu,
- isBooleanElement: () => Bu,
- isCommentElement: () => Wu,
- isElement: () => Nu,
- isLinkElement: () => Vu,
- isMemberElement: () => $u,
- isNullElement: () => Lu,
- isNumberElement: () => Du,
- isObjectElement: () => Fu,
- isParseResultElement: () => Ku,
- isPrimitiveElement: () => isPrimitiveElement,
- isRefElement: () => Uu,
- isSourceMapElement: () => Hu,
- isStringElement: () => Ru
- });
- var ce = {};
- __webpack_require__.r(ce),
- __webpack_require__.d(ce, {
- isJSONReferenceElement: () => Nf,
- isJSONSchemaElement: () => Tf,
- isLinkDescriptionElement: () => Df,
- isMediaElement: () => Rf
- });
- var pe = {};
- __webpack_require__.r(pe),
- __webpack_require__.d(pe, {
- isBooleanJsonSchemaElement: () => isBooleanJsonSchemaElement,
- isCallbackElement: () => Im,
- isComponentsElement: () => Pm,
- isContactElement: () => Mm,
- isExampleElement: () => Tm,
- isExternalDocumentationElement: () => Nm,
- isHeaderElement: () => Rm,
- isInfoElement: () => Dm,
- isLicenseElement: () => Lm,
- isLinkElement: () => Bm,
- isMediaTypeElement: () => eg,
- isOpenApi3_0Element: () => qm,
- isOpenapiElement: () => Fm,
- isOperationElement: () => $m,
- isParameterElement: () => Vm,
- isPathItemElement: () => Um,
- isPathsElement: () => zm,
- isReferenceElement: () => Wm,
- isRequestBodyElement: () => Km,
- isResponseElement: () => Hm,
- isResponsesElement: () => Jm,
- isSchemaElement: () => Gm,
- isSecurityRequirementElement: () => Ym,
- isSecuritySchemeElement: () => Xm,
- isServerElement: () => Zm,
- isServerVariableElement: () => Qm,
- isServersElement: () => rg
- });
- var de = {};
- __webpack_require__.r(de),
- __webpack_require__.d(de, {
- isBooleanJsonSchemaElement: () => predicates_isBooleanJsonSchemaElement,
- isCallbackElement: () => T_,
- isComponentsElement: () => N_,
- isContactElement: () => R_,
- isExampleElement: () => D_,
- isExternalDocumentationElement: () => L_,
- isHeaderElement: () => B_,
- isInfoElement: () => F_,
- isJsonSchemaDialectElement: () => q_,
- isLicenseElement: () => $_,
- isLinkElement: () => V_,
- isMediaTypeElement: () => sE,
- isOpenApi3_1Element: () => z_,
- isOpenapiElement: () => U_,
- isOperationElement: () => W_,
- isParameterElement: () => K_,
- isPathItemElement: () => H_,
- isPathItemElementExternal: () => isPathItemElementExternal,
- isPathsElement: () => J_,
- isReferenceElement: () => G_,
- isReferenceElementExternal: () => isReferenceElementExternal,
- isRequestBodyElement: () => Y_,
- isResponseElement: () => X_,
- isResponsesElement: () => Z_,
- isSchemaElement: () => Q_,
- isSecurityRequirementElement: () => eE,
- isSecuritySchemeElement: () => tE,
- isServerElement: () => rE,
- isServerVariableElement: () => nE
- });
- var fe = {};
- __webpack_require__.r(fe),
- __webpack_require__.d(fe, {
- cookie: () => parameter_builders_cookie,
- header: () => parameter_builders_header,
- path: () => parameter_builders_path,
- query: () => parameter_builders_query
- });
- var ye = {};
- __webpack_require__.r(ye),
- __webpack_require__.d(ye, {
- Button: () => Button,
- Col: () => Col,
- Collapse: () => Collapse,
- Container: () => Container,
- Input: () => Input,
- Link: () => layout_utils_Link,
- Row: () => Row,
- Select: () => Select,
- TextArea: () => TextArea
- });
- var be = {};
- __webpack_require__.r(be),
- __webpack_require__.d(be, {
- basePath: () => KO,
- consumes: () => HO,
- definitions: () => VO,
- findDefinition: () => $O,
- hasHost: () => UO,
- host: () => WO,
- produces: () => JO,
- schemes: () => GO,
- securityDefinitions: () => zO,
- validOperationMethods: () => wrap_selectors_validOperationMethods
- });
- var _e = {};
- __webpack_require__.r(_e), __webpack_require__.d(_e, { definitionsToAuthorize: () => YO });
- var we = {};
- __webpack_require__.r(we),
- __webpack_require__.d(we, {
- callbacksOperations: () => QO,
- findSchema: () => findSchema,
- isOAS3: () => selectors_isOAS3,
- isOAS30: () => selectors_isOAS30,
- isSwagger2: () => selectors_isSwagger2,
- servers: () => ZO
- });
- var Se = {};
- __webpack_require__.r(Se),
- __webpack_require__.d(Se, {
- CLEAR_REQUEST_BODY_VALIDATE_ERROR: () => bA,
- CLEAR_REQUEST_BODY_VALUE: () => _A,
- SET_REQUEST_BODY_VALIDATE_ERROR: () => vA,
- UPDATE_ACTIVE_EXAMPLES_MEMBER: () => fA,
- UPDATE_REQUEST_BODY_INCLUSION: () => dA,
- UPDATE_REQUEST_BODY_VALUE: () => pA,
- UPDATE_REQUEST_BODY_VALUE_RETAIN_FLAG: () => hA,
- UPDATE_REQUEST_CONTENT_TYPE: () => mA,
- UPDATE_RESPONSE_CONTENT_TYPE: () => gA,
- UPDATE_SELECTED_SERVER: () => uA,
- UPDATE_SERVER_VARIABLE_VALUE: () => yA,
- clearRequestBodyValidateError: () => clearRequestBodyValidateError,
- clearRequestBodyValue: () => clearRequestBodyValue,
- initRequestBodyValidateError: () => initRequestBodyValidateError,
- setActiveExamplesMember: () => setActiveExamplesMember,
- setRequestBodyInclusion: () => setRequestBodyInclusion,
- setRequestBodyValidateError: () => setRequestBodyValidateError,
- setRequestBodyValue: () => setRequestBodyValue,
- setRequestContentType: () => setRequestContentType,
- setResponseContentType: () => setResponseContentType,
- setRetainRequestBodyValueFlag: () => setRetainRequestBodyValueFlag,
- setSelectedServer: () => setSelectedServer,
- setServerVariableValue: () => setServerVariableValue
- });
- var xe = {};
- __webpack_require__.r(xe),
- __webpack_require__.d(xe, {
- activeExamplesMember: () => jA,
- hasUserEditedBody: () => CA,
- requestBodyErrors: () => AA,
- requestBodyInclusionSetting: () => OA,
- requestBodyValue: () => xA,
- requestContentType: () => IA,
- responseContentType: () => PA,
- selectDefaultRequestBodyValue: () => selectDefaultRequestBodyValue,
- selectedServer: () => SA,
- serverEffectiveValue: () => NA,
- serverVariableValue: () => MA,
- serverVariables: () => TA,
- shouldRetainRequestBodyValue: () => kA,
- validOperationMethods: () => DA,
- validateBeforeExecute: () => RA,
- validateShallowRequired: () => validateShallowRequired
- });
- var Pe = __webpack_require__(96540);
- function formatProdErrorMessage(s) {
- return `Minified Redux error #${s}; visit https://redux.js.org/Errors?code=${s} for the full message or use the non-minified dev environment for full errors. `;
- }
- var Te = (() => ('function' == typeof Symbol && Symbol.observable) || '@@observable')(),
- randomString = () => Math.random().toString(36).substring(7).split('').join('.'),
- Re = {
- INIT: `@@redux/INIT${randomString()}`,
- REPLACE: `@@redux/REPLACE${randomString()}`,
- PROBE_UNKNOWN_ACTION: () => `@@redux/PROBE_UNKNOWN_ACTION${randomString()}`
- };
- function isPlainObject(s) {
- if ('object' != typeof s || null === s) return !1;
- let o = s;
- for (; null !== Object.getPrototypeOf(o); ) o = Object.getPrototypeOf(o);
- return Object.getPrototypeOf(s) === o || null === Object.getPrototypeOf(s);
- }
- function createStore(s, o, i) {
- if ('function' != typeof s) throw new Error(formatProdErrorMessage(2));
- if (
- ('function' == typeof o && 'function' == typeof i) ||
- ('function' == typeof i && 'function' == typeof arguments[3])
- )
- throw new Error(formatProdErrorMessage(0));
- if (('function' == typeof o && void 0 === i && ((i = o), (o = void 0)), void 0 !== i)) {
- if ('function' != typeof i) throw new Error(formatProdErrorMessage(1));
- return i(createStore)(s, o);
- }
- let u = s,
- _ = o,
- w = new Map(),
- x = w,
- C = 0,
- j = !1;
- function ensureCanMutateNextListeners() {
- x === w &&
- ((x = new Map()),
- w.forEach((s, o) => {
- x.set(o, s);
- }));
- }
- function getState() {
- if (j) throw new Error(formatProdErrorMessage(3));
- return _;
- }
- function subscribe(s) {
- if ('function' != typeof s) throw new Error(formatProdErrorMessage(4));
- if (j) throw new Error(formatProdErrorMessage(5));
- let o = !0;
- ensureCanMutateNextListeners();
- const i = C++;
- return (
- x.set(i, s),
- function unsubscribe() {
- if (o) {
- if (j) throw new Error(formatProdErrorMessage(6));
- (o = !1), ensureCanMutateNextListeners(), x.delete(i), (w = null);
- }
- }
- );
- }
- function dispatch(s) {
- if (!isPlainObject(s)) throw new Error(formatProdErrorMessage(7));
- if (void 0 === s.type) throw new Error(formatProdErrorMessage(8));
- if ('string' != typeof s.type) throw new Error(formatProdErrorMessage(17));
- if (j) throw new Error(formatProdErrorMessage(9));
- try {
- (j = !0), (_ = u(_, s));
- } finally {
- j = !1;
- }
- return (
- (w = x).forEach((s) => {
- s();
- }),
- s
- );
- }
- dispatch({ type: Re.INIT });
- return {
- dispatch,
- subscribe,
- getState,
- replaceReducer: function replaceReducer(s) {
- if ('function' != typeof s) throw new Error(formatProdErrorMessage(10));
- (u = s), dispatch({ type: Re.REPLACE });
- },
- [Te]: function observable() {
- const s = subscribe;
- return {
- subscribe(o) {
- if ('object' != typeof o || null === o)
- throw new Error(formatProdErrorMessage(11));
- function observeState() {
- const s = o;
- s.next && s.next(getState());
- }
- observeState();
- return { unsubscribe: s(observeState) };
- },
- [Te]() {
- return this;
- }
- };
- }
- };
- }
- function bindActionCreator(s, o) {
- return function (...i) {
- return o(s.apply(this, i));
- };
- }
- function compose(...s) {
- return 0 === s.length
- ? (s) => s
- : 1 === s.length
- ? s[0]
- : s.reduce(
- (s, o) =>
- (...i) =>
- s(o(...i))
- );
- }
- var qe = __webpack_require__(9404),
- $e = __webpack_require__.n(qe),
- ze = __webpack_require__(81919),
- We = __webpack_require__.n(ze),
- He = __webpack_require__(89593),
- Ye = __webpack_require__(20334),
- Xe = __webpack_require__(55364),
- Qe = __webpack_require__.n(Xe);
- const et = 'err_new_thrown_err',
- tt = 'err_new_thrown_err_batch',
- rt = 'err_new_spec_err',
- nt = 'err_new_spec_err_batch',
- st = 'err_new_auth_err',
- ot = 'err_clear',
- it = 'err_clear_by';
- function newThrownErr(s) {
- return { type: et, payload: (0, Ye.serializeError)(s) };
- }
- function newThrownErrBatch(s) {
- return { type: tt, payload: s };
- }
- function newSpecErr(s) {
- return { type: rt, payload: s };
- }
- function newSpecErrBatch(s) {
- return { type: nt, payload: s };
- }
- function newAuthErr(s) {
- return { type: st, payload: s };
- }
- function clear(s = {}) {
- return { type: ot, payload: s };
- }
- function clearBy(s = () => !0) {
- return { type: it, payload: s };
- }
- const at = (function makeWindow() {
- var s = {
- location: {},
- history: {},
- open: () => {},
- close: () => {},
- File: function () {},
- FormData: function () {}
- };
- if ('undefined' == typeof window) return s;
- try {
- s = window;
- for (var o of ['File', 'Blob', 'FormData']) o in window && (s[o] = window[o]);
- } catch (s) {
- console.error(s);
- }
- return s;
- })();
- var lt = __webpack_require__(16750),
- ct = (__webpack_require__(84058), __webpack_require__(55808), __webpack_require__(50104)),
- ut = __webpack_require__.n(ct),
- pt = __webpack_require__(7309),
- ht = __webpack_require__.n(pt),
- dt = __webpack_require__(42426),
- mt = __webpack_require__.n(dt),
- gt = __webpack_require__(75288),
- yt = __webpack_require__.n(gt),
- vt = __webpack_require__(1882),
- bt = __webpack_require__.n(vt),
- _t = __webpack_require__(2205),
- Et = __webpack_require__.n(_t),
- wt = __webpack_require__(53209),
- St = __webpack_require__.n(wt),
- xt = __webpack_require__(62802),
- kt = __webpack_require__.n(xt);
- const Ct = $e().Set.of(
- 'type',
- 'format',
- 'items',
- 'default',
- 'maximum',
- 'exclusiveMaximum',
- 'minimum',
- 'exclusiveMinimum',
- 'maxLength',
- 'minLength',
- 'pattern',
- 'maxItems',
- 'minItems',
- 'uniqueItems',
- 'enum',
- 'multipleOf'
- );
- function getParameterSchema(s, { isOAS3: o } = {}) {
- if (!$e().Map.isMap(s)) return { schema: $e().Map(), parameterContentMediaType: null };
- if (!o)
- return 'body' === s.get('in')
- ? { schema: s.get('schema', $e().Map()), parameterContentMediaType: null }
- : { schema: s.filter((s, o) => Ct.includes(o)), parameterContentMediaType: null };
- if (s.get('content')) {
- const o = s.get('content', $e().Map({})).keySeq().first();
- return {
- schema: s.getIn(['content', o, 'schema'], $e().Map()),
- parameterContentMediaType: o
- };
- }
- return {
- schema: s.get('schema') ? s.get('schema', $e().Map()) : $e().Map(),
- parameterContentMediaType: null
- };
- }
- var Ot = __webpack_require__(48287).Buffer;
- const At = 'default',
- isImmutable = (s) => $e().Iterable.isIterable(s);
- function objectify(s) {
- return isObject(s) ? (isImmutable(s) ? s.toJS() : s) : {};
- }
- function fromJSOrdered(s) {
- if (isImmutable(s)) return s;
- if (s instanceof at.File) return s;
- if (!isObject(s)) return s;
- if (Array.isArray(s)) return $e().Seq(s).map(fromJSOrdered).toList();
- if (bt()(s.entries)) {
- const o = (function createObjWithHashedKeys(s) {
- if (!bt()(s.entries)) return s;
- const o = {},
- i = '_**[]',
- u = {};
- for (let _ of s.entries())
- if (o[_[0]] || (u[_[0]] && u[_[0]].containsMultiple)) {
- if (!u[_[0]]) {
- (u[_[0]] = { containsMultiple: !0, length: 1 }),
- (o[`${_[0]}${i}${u[_[0]].length}`] = o[_[0]]),
- delete o[_[0]];
- }
- (u[_[0]].length += 1), (o[`${_[0]}${i}${u[_[0]].length}`] = _[1]);
- } else o[_[0]] = _[1];
- return o;
- })(s);
- return $e().OrderedMap(o).map(fromJSOrdered);
- }
- return $e().OrderedMap(s).map(fromJSOrdered);
- }
- function normalizeArray(s) {
- return Array.isArray(s) ? s : [s];
- }
- function isFn(s) {
- return 'function' == typeof s;
- }
- function isObject(s) {
- return !!s && 'object' == typeof s;
- }
- function isFunc(s) {
- return 'function' == typeof s;
- }
- function isArray(s) {
- return Array.isArray(s);
- }
- const jt = ut();
- function objMap(s, o) {
- return Object.keys(s).reduce((i, u) => ((i[u] = o(s[u], u)), i), {});
- }
- function objReduce(s, o) {
- return Object.keys(s).reduce((i, u) => {
- let _ = o(s[u], u);
- return _ && 'object' == typeof _ && Object.assign(i, _), i;
- }, {});
- }
- function systemThunkMiddleware(s) {
- return ({ dispatch: o, getState: i }) =>
- (o) =>
- (i) =>
- 'function' == typeof i ? i(s()) : o(i);
- }
- function validateValueBySchema(s, o, i, u, _) {
- if (!o) return [];
- let w = [],
- x = o.get('nullable'),
- C = o.get('required'),
- j = o.get('maximum'),
- L = o.get('minimum'),
- B = o.get('type'),
- $ = o.get('format'),
- V = o.get('maxLength'),
- U = o.get('minLength'),
- z = o.get('uniqueItems'),
- Y = o.get('maxItems'),
- Z = o.get('minItems'),
- ee = o.get('pattern');
- const ie = i || !0 === C,
- ae = null != s,
- le = ie || (ae && 'array' === B) || !(!ie && !ae),
- ce = x && null === s;
- if (ie && !ae && !ce && !u && !B) return w.push('Required field is not provided'), w;
- if (ce || !B || !le) return [];
- let pe = 'string' === B && s,
- de = 'array' === B && Array.isArray(s) && s.length,
- fe = 'array' === B && $e().List.isList(s) && s.count();
- const ye = [
- pe,
- de,
- fe,
- 'array' === B && 'string' == typeof s && s,
- 'file' === B && s instanceof at.File,
- 'boolean' === B && (s || !1 === s),
- 'number' === B && (s || 0 === s),
- 'integer' === B && (s || 0 === s),
- 'object' === B && 'object' == typeof s && null !== s,
- 'object' === B && 'string' == typeof s && s
- ].some((s) => !!s);
- if (ie && !ye && !u) return w.push('Required field is not provided'), w;
- if ('object' === B && (null === _ || 'application/json' === _)) {
- let i = s;
- if ('string' == typeof s)
- try {
- i = JSON.parse(s);
- } catch (s) {
- return w.push('Parameter string value must be valid JSON'), w;
- }
- o &&
- o.has('required') &&
- isFunc(C.isList) &&
- C.isList() &&
- C.forEach((s) => {
- void 0 === i[s] && w.push({ propKey: s, error: 'Required property not found' });
- }),
- o &&
- o.has('properties') &&
- o.get('properties').forEach((s, o) => {
- const x = validateValueBySchema(i[o], s, !1, u, _);
- w.push(...x.map((s) => ({ propKey: o, error: s })));
- });
- }
- if (ee) {
- let o = ((s, o) => {
- if (!new RegExp(o).test(s)) return 'Value must follow pattern ' + o;
- })(s, ee);
- o && w.push(o);
- }
- if (Z && 'array' === B) {
- let o = ((s, o) => {
- if ((!s && o >= 1) || (s && s.length < o))
- return `Array must contain at least ${o} item${1 === o ? '' : 's'}`;
- })(s, Z);
- o && w.push(o);
- }
- if (Y && 'array' === B) {
- let o = ((s, o) => {
- if (s && s.length > o)
- return `Array must not contain more then ${o} item${1 === o ? '' : 's'}`;
- })(s, Y);
- o && w.push({ needRemove: !0, error: o });
- }
- if (z && 'array' === B) {
- let o = ((s, o) => {
- if (s && ('true' === o || !0 === o)) {
- const o = (0, qe.fromJS)(s),
- i = o.toSet();
- if (s.length > i.size) {
- let s = (0, qe.Set)();
- if (
- (o.forEach((i, u) => {
- o.filter((s) => (isFunc(s.equals) ? s.equals(i) : s === i)).size > 1 &&
- (s = s.add(u));
- }),
- 0 !== s.size)
- )
- return s.map((s) => ({ index: s, error: 'No duplicates allowed.' })).toArray();
- }
- }
- })(s, z);
- o && w.push(...o);
- }
- if (V || 0 === V) {
- let o = ((s, o) => {
- if (s.length > o)
- return `Value must be no longer than ${o} character${1 !== o ? 's' : ''}`;
- })(s, V);
- o && w.push(o);
- }
- if (U) {
- let o = ((s, o) => {
- if (s.length < o) return `Value must be at least ${o} character${1 !== o ? 's' : ''}`;
- })(s, U);
- o && w.push(o);
- }
- if (j || 0 === j) {
- let o = ((s, o) => {
- if (s > o) return `Value must be less than ${o}`;
- })(s, j);
- o && w.push(o);
- }
- if (L || 0 === L) {
- let o = ((s, o) => {
- if (s < o) return `Value must be greater than ${o}`;
- })(s, L);
- o && w.push(o);
- }
- if ('string' === B) {
- let o;
- if (
- ((o =
- 'date-time' === $
- ? ((s) => {
- if (isNaN(Date.parse(s))) return 'Value must be a DateTime';
- })(s)
- : 'uuid' === $
- ? ((s) => {
- if (
- ((s = s.toString().toLowerCase()),
- !/^[{(]?[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}[)}]?$/.test(
- s
- ))
- )
- return 'Value must be a Guid';
- })(s)
- : ((s) => {
- if (s && 'string' != typeof s) return 'Value must be a string';
- })(s)),
- !o)
- )
- return w;
- w.push(o);
- } else if ('boolean' === B) {
- let o = ((s) => {
- if ('true' !== s && 'false' !== s && !0 !== s && !1 !== s)
- return 'Value must be a boolean';
- })(s);
- if (!o) return w;
- w.push(o);
- } else if ('number' === B) {
- let o = ((s) => {
- if (!/^-?\d+(\.?\d+)?$/.test(s)) return 'Value must be a number';
- })(s);
- if (!o) return w;
- w.push(o);
- } else if ('integer' === B) {
- let o = ((s) => {
- if (!/^-?\d+$/.test(s)) return 'Value must be an integer';
- })(s);
- if (!o) return w;
- w.push(o);
- } else if ('array' === B) {
- if (!de && !fe) return w;
- s &&
- s.forEach((s, i) => {
- const x = validateValueBySchema(s, o.get('items'), !1, u, _);
- w.push(...x.map((s) => ({ index: i, error: s })));
- });
- } else if ('file' === B) {
- let o = ((s) => {
- if (s && !(s instanceof at.File)) return 'Value must be a file';
- })(s);
- if (!o) return w;
- w.push(o);
- }
- return w;
- }
- const utils_btoa = (s) => {
- let o;
- return (o = s instanceof Ot ? s : Ot.from(s.toString(), 'utf-8')), o.toString('base64');
- },
- It = {
- operationsSorter: {
- alpha: (s, o) => s.get('path').localeCompare(o.get('path')),
- method: (s, o) => s.get('method').localeCompare(o.get('method'))
- },
- tagsSorter: { alpha: (s, o) => s.localeCompare(o) }
- },
- buildFormData = (s) => {
- let o = [];
- for (let i in s) {
- let u = s[i];
- void 0 !== u &&
- '' !== u &&
- o.push([i, '=', encodeURIComponent(u).replace(/%20/g, '+')].join(''));
- }
- return o.join('&');
- },
- shallowEqualKeys = (s, o, i) => !!ht()(i, (i) => yt()(s[i], o[i]));
- function sanitizeUrl(s) {
- return 'string' != typeof s || '' === s ? '' : (0, lt.J)(s);
- }
- function requiresValidationURL(s) {
- return !(
- !s ||
- s.indexOf('localhost') >= 0 ||
- s.indexOf('127.0.0.1') >= 0 ||
- 'none' === s
- );
- }
- const createDeepLinkPath = (s) =>
- 'string' == typeof s || s instanceof String ? s.trim().replace(/\s/g, '%20') : '',
- escapeDeepLinkPath = (s) => Et()(createDeepLinkPath(s).replace(/%20/g, '_')),
- getExtensions = (s) => s.filter((s, o) => /^x-/.test(o)),
- getCommonExtensions = (s) =>
- s.filter((s, o) => /^pattern|maxLength|minLength|maximum|minimum/.test(o));
- function deeplyStripKey(s, o, i = () => !0) {
- if ('object' != typeof s || Array.isArray(s) || null === s || !o) return s;
- const u = Object.assign({}, s);
- return (
- Object.keys(u).forEach((s) => {
- s === o && i(u[s], s) ? delete u[s] : (u[s] = deeplyStripKey(u[s], o, i));
- }),
- u
- );
- }
- function stringify(s) {
- if ('string' == typeof s) return s;
- if ((s && s.toJS && (s = s.toJS()), 'object' == typeof s && null !== s))
- try {
- return JSON.stringify(s, null, 2);
- } catch (o) {
- return String(s);
- }
- return null == s ? '' : s.toString();
- }
- function paramToIdentifier(s, { returnAll: o = !1, allowHashes: i = !0 } = {}) {
- if (!$e().Map.isMap(s))
- throw new Error('paramToIdentifier: received a non-Im.Map parameter as input');
- const u = s.get('name'),
- _ = s.get('in');
- let w = [];
- return (
- s && s.hashCode && _ && u && i && w.push(`${_}.${u}.hash-${s.hashCode()}`),
- _ && u && w.push(`${_}.${u}`),
- w.push(u),
- o ? w : w[0] || ''
- );
- }
- function paramToValue(s, o) {
- return paramToIdentifier(s, { returnAll: !0 })
- .map((s) => o[s])
- .filter((s) => void 0 !== s)[0];
- }
- function b64toB64UrlEncoded(s) {
- return s.replace(/\+/g, '-').replace(/\//g, '_').replace(/=/g, '');
- }
- const isEmptyValue = (s) => !s || !(!isImmutable(s) || !s.isEmpty()),
- idFn = (s) => s;
- function createStoreWithMiddleware(s, o, i) {
- let u = [systemThunkMiddleware(i)];
- return createStore(
- s,
- o,
- (at.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ || compose)(
- (function applyMiddleware(...s) {
- return (o) => (i, u) => {
- const _ = o(i, u);
- let dispatch = () => {
- throw new Error(formatProdErrorMessage(15));
- };
- const w = { getState: _.getState, dispatch: (s, ...o) => dispatch(s, ...o) },
- x = s.map((s) => s(w));
- return (dispatch = compose(...x)(_.dispatch)), { ..._, dispatch };
- };
- })(...u)
- )
- );
- }
- class Store {
- constructor(s = {}) {
- We()(
- this,
- {
- state: {},
- plugins: [],
- system: { configs: {}, fn: {}, components: {}, rootInjects: {}, statePlugins: {} },
- boundSystem: {},
- toolbox: {}
- },
- s
- ),
- (this.getSystem = this._getSystem.bind(this)),
- (this.store = (function configureStore(s, o, i) {
- return createStoreWithMiddleware(s, o, i);
- })(idFn, (0, qe.fromJS)(this.state), this.getSystem)),
- this.buildSystem(!1),
- this.register(this.plugins);
- }
- getStore() {
- return this.store;
- }
- register(s, o = !0) {
- var i = combinePlugins(s, this.getSystem());
- systemExtend(this.system, i), o && this.buildSystem();
- callAfterLoad.call(this.system, s, this.getSystem()) && this.buildSystem();
- }
- buildSystem(s = !0) {
- let o = this.getStore().dispatch,
- i = this.getStore().getState;
- (this.boundSystem = Object.assign(
- {},
- this.getRootInjects(),
- this.getWrappedAndBoundActions(o),
- this.getWrappedAndBoundSelectors(i, this.getSystem),
- this.getStateThunks(i),
- this.getFn(),
- this.getConfigs()
- )),
- s && this.rebuildReducer();
- }
- _getSystem() {
- return this.boundSystem;
- }
- getRootInjects() {
- return Object.assign(
- {
- getSystem: this.getSystem,
- getStore: this.getStore.bind(this),
- getComponents: this.getComponents.bind(this),
- getState: this.getStore().getState,
- getConfigs: this._getConfigs.bind(this),
- Im: $e(),
- React: Pe
- },
- this.system.rootInjects || {}
- );
- }
- _getConfigs() {
- return this.system.configs;
- }
- getConfigs() {
- return { configs: this.system.configs };
- }
- setConfigs(s) {
- this.system.configs = s;
- }
- rebuildReducer() {
- this.store.replaceReducer(
- (function buildReducer(s) {
- return (function allReducers(s) {
- let o = Object.keys(s).reduce(
- (o, i) => (
- (o[i] = (function makeReducer(s) {
- return (o = new qe.Map(), i) => {
- if (!s) return o;
- let u = s[i.type];
- if (u) {
- const s = wrapWithTryCatch(u)(o, i);
- return null === s ? o : s;
- }
- return o;
- };
- })(s[i])),
- o
- ),
- {}
- );
- if (!Object.keys(o).length) return idFn;
- return (0, He.H)(o);
- })(objMap(s, (s) => s.reducers));
- })(this.system.statePlugins)
- );
- }
- getType(s) {
- let o = s[0].toUpperCase() + s.slice(1);
- return objReduce(this.system.statePlugins, (i, u) => {
- let _ = i[s];
- if (_) return { [u + o]: _ };
- });
- }
- getSelectors() {
- return this.getType('selectors');
- }
- getActions() {
- return objMap(this.getType('actions'), (s) =>
- objReduce(s, (s, o) => {
- if (isFn(s)) return { [o]: s };
- })
- );
- }
- getWrappedAndBoundActions(s) {
- return objMap(this.getBoundActions(s), (s, o) => {
- let i = this.system.statePlugins[o.slice(0, -7)].wrapActions;
- return i
- ? objMap(s, (s, o) => {
- let u = i[o];
- return u
- ? (Array.isArray(u) || (u = [u]),
- u.reduce((s, o) => {
- let newAction = (...i) => o(s, this.getSystem())(...i);
- if (!isFn(newAction))
- throw new TypeError(
- 'wrapActions needs to return a function that returns a new function (ie the wrapped action)'
- );
- return wrapWithTryCatch(newAction);
- }, s || Function.prototype))
- : s;
- })
- : s;
- });
- }
- getWrappedAndBoundSelectors(s, o) {
- return objMap(this.getBoundSelectors(s, o), (o, i) => {
- let u = [i.slice(0, -9)],
- _ = this.system.statePlugins[u].wrapSelectors;
- return _
- ? objMap(o, (o, i) => {
- let w = _[i];
- return w
- ? (Array.isArray(w) || (w = [w]),
- w.reduce((o, i) => {
- let wrappedSelector = (..._) =>
- i(o, this.getSystem())(s().getIn(u), ..._);
- if (!isFn(wrappedSelector))
- throw new TypeError(
- 'wrapSelector needs to return a function that returns a new function (ie the wrapped action)'
- );
- return wrappedSelector;
- }, o || Function.prototype))
- : o;
- })
- : o;
- });
- }
- getStates(s) {
- return Object.keys(this.system.statePlugins).reduce(
- (o, i) => ((o[i] = s.get(i)), o),
- {}
- );
- }
- getStateThunks(s) {
- return Object.keys(this.system.statePlugins).reduce(
- (o, i) => ((o[i] = () => s().get(i)), o),
- {}
- );
- }
- getFn() {
- return { fn: this.system.fn };
- }
- getComponents(s) {
- const o = this.system.components[s];
- return Array.isArray(o)
- ? o.reduce((s, o) => o(s, this.getSystem()))
- : void 0 !== s
- ? this.system.components[s]
- : this.system.components;
- }
- getBoundSelectors(s, o) {
- return objMap(this.getSelectors(), (i, u) => {
- let _ = [u.slice(0, -9)];
- return objMap(i, (i) => (...u) => {
- let w = wrapWithTryCatch(i).apply(null, [s().getIn(_), ...u]);
- return 'function' == typeof w && (w = wrapWithTryCatch(w)(o())), w;
- });
- });
- }
- getBoundActions(s) {
- s = s || this.getStore().dispatch;
- const o = this.getActions(),
- process = (s) =>
- 'function' != typeof s
- ? objMap(s, (s) => process(s))
- : (...o) => {
- var i = null;
- try {
- i = s(...o);
- } catch (s) {
- i = { type: et, error: !0, payload: (0, Ye.serializeError)(s) };
- } finally {
- return i;
- }
- };
- return objMap(o, (o) =>
- (function bindActionCreators(s, o) {
- if ('function' == typeof s) return bindActionCreator(s, o);
- if ('object' != typeof s || null === s) throw new Error(formatProdErrorMessage(16));
- const i = {};
- for (const u in s) {
- const _ = s[u];
- 'function' == typeof _ && (i[u] = bindActionCreator(_, o));
- }
- return i;
- })(process(o), s)
- );
- }
- getMapStateToProps() {
- return () => Object.assign({}, this.getSystem());
- }
- getMapDispatchToProps(s) {
- return (o) => We()({}, this.getWrappedAndBoundActions(o), this.getFn(), s);
- }
- }
- function combinePlugins(s, o) {
- return isObject(s) && !isArray(s)
- ? Qe()({}, s)
- : isFunc(s)
- ? combinePlugins(s(o), o)
- : isArray(s)
- ? s
- .map((s) => combinePlugins(s, o))
- .reduce(systemExtend, { components: o.getComponents() })
- : {};
- }
- function callAfterLoad(s, o, { hasLoaded: i } = {}) {
- let u = i;
- return (
- isObject(s) &&
- !isArray(s) &&
- 'function' == typeof s.afterLoad &&
- ((u = !0), wrapWithTryCatch(s.afterLoad).call(this, o)),
- isFunc(s)
- ? callAfterLoad.call(this, s(o), o, { hasLoaded: u })
- : isArray(s)
- ? s.map((s) => callAfterLoad.call(this, s, o, { hasLoaded: u }))
- : u
- );
- }
- function systemExtend(s = {}, o = {}) {
- if (!isObject(s)) return {};
- if (!isObject(o)) return s;
- o.wrapComponents &&
- (objMap(o.wrapComponents, (i, u) => {
- const _ = s.components && s.components[u];
- _ && Array.isArray(_)
- ? ((s.components[u] = _.concat([i])), delete o.wrapComponents[u])
- : _ && ((s.components[u] = [_, i]), delete o.wrapComponents[u]);
- }),
- Object.keys(o.wrapComponents).length || delete o.wrapComponents);
- const { statePlugins: i } = s;
- if (isObject(i))
- for (let s in i) {
- const u = i[s];
- if (!isObject(u)) continue;
- const { wrapActions: _, wrapSelectors: w } = u;
- if (isObject(_))
- for (let i in _) {
- let u = _[i];
- Array.isArray(u) || ((u = [u]), (_[i] = u)),
- o &&
- o.statePlugins &&
- o.statePlugins[s] &&
- o.statePlugins[s].wrapActions &&
- o.statePlugins[s].wrapActions[i] &&
- (o.statePlugins[s].wrapActions[i] = _[i].concat(
- o.statePlugins[s].wrapActions[i]
- ));
- }
- if (isObject(w))
- for (let i in w) {
- let u = w[i];
- Array.isArray(u) || ((u = [u]), (w[i] = u)),
- o &&
- o.statePlugins &&
- o.statePlugins[s] &&
- o.statePlugins[s].wrapSelectors &&
- o.statePlugins[s].wrapSelectors[i] &&
- (o.statePlugins[s].wrapSelectors[i] = w[i].concat(
- o.statePlugins[s].wrapSelectors[i]
- ));
- }
- }
- return We()(s, o);
- }
- function wrapWithTryCatch(s, { logErrors: o = !0 } = {}) {
- return 'function' != typeof s
- ? s
- : function (...i) {
- try {
- return s.call(this, ...i);
- } catch (s) {
- return o && console.error(s), null;
- }
- };
- }
- var Pt = __webpack_require__(61160),
- Mt = __webpack_require__.n(Pt);
- const Tt = 'show_popup',
- Nt = 'authorize',
- Rt = 'logout',
- Dt = 'pre_authorize_oauth2',
- Lt = 'authorize_oauth2',
- Bt = 'validate',
- Ft = 'configure_auth',
- qt = 'restore_authorization';
- function showDefinitions(s) {
- return { type: Tt, payload: s };
- }
- function authorize(s) {
- return { type: Nt, payload: s };
- }
- const authorizeWithPersistOption =
- (s) =>
- ({ authActions: o }) => {
- o.authorize(s), o.persistAuthorizationIfNeeded();
- };
- function logout(s) {
- return { type: Rt, payload: s };
- }
- const logoutWithPersistOption =
- (s) =>
- ({ authActions: o }) => {
- o.logout(s), o.persistAuthorizationIfNeeded();
- },
- preAuthorizeImplicit =
- (s) =>
- ({ authActions: o, errActions: i }) => {
- let { auth: u, token: _, isValid: w } = s,
- { schema: x, name: C } = u,
- j = x.get('flow');
- delete at.swaggerUIRedirectOauth2,
- 'accessCode' === j ||
- w ||
- i.newAuthErr({
- authId: C,
- source: 'auth',
- level: 'warning',
- message:
- "Authorization may be unsafe, passed state was changed in server Passed state wasn't returned from auth server"
- }),
- _.error
- ? i.newAuthErr({
- authId: C,
- source: 'auth',
- level: 'error',
- message: JSON.stringify(_)
- })
- : o.authorizeOauth2WithPersistOption({ auth: u, token: _ });
- };
- function authorizeOauth2(s) {
- return { type: Lt, payload: s };
- }
- const authorizeOauth2WithPersistOption =
- (s) =>
- ({ authActions: o }) => {
- o.authorizeOauth2(s), o.persistAuthorizationIfNeeded();
- },
- authorizePassword =
- (s) =>
- ({ authActions: o }) => {
- let {
- schema: i,
- name: u,
- username: _,
- password: w,
- passwordType: x,
- clientId: C,
- clientSecret: j
- } = s,
- L = { grant_type: 'password', scope: s.scopes.join(' '), username: _, password: w },
- B = {};
- switch (x) {
- case 'request-body':
- !(function setClientIdAndSecret(s, o, i) {
- o && Object.assign(s, { client_id: o });
- i && Object.assign(s, { client_secret: i });
- })(L, C, j);
- break;
- case 'basic':
- B.Authorization = 'Basic ' + utils_btoa(C + ':' + j);
- break;
- default:
- console.warn(
- `Warning: invalid passwordType ${x} was passed, not including client id and secret`
- );
- }
- return o.authorizeRequest({
- body: buildFormData(L),
- url: i.get('tokenUrl'),
- name: u,
- headers: B,
- query: {},
- auth: s
- });
- };
- const authorizeApplication =
- (s) =>
- ({ authActions: o }) => {
- let { schema: i, scopes: u, name: _, clientId: w, clientSecret: x } = s,
- C = { Authorization: 'Basic ' + utils_btoa(w + ':' + x) },
- j = { grant_type: 'client_credentials', scope: u.join(' ') };
- return o.authorizeRequest({
- body: buildFormData(j),
- name: _,
- url: i.get('tokenUrl'),
- auth: s,
- headers: C
- });
- },
- authorizeAccessCodeWithFormParams =
- ({ auth: s, redirectUrl: o }) =>
- ({ authActions: i }) => {
- let { schema: u, name: _, clientId: w, clientSecret: x, codeVerifier: C } = s,
- j = {
- grant_type: 'authorization_code',
- code: s.code,
- client_id: w,
- client_secret: x,
- redirect_uri: o,
- code_verifier: C
- };
- return i.authorizeRequest({
- body: buildFormData(j),
- name: _,
- url: u.get('tokenUrl'),
- auth: s
- });
- },
- authorizeAccessCodeWithBasicAuthentication =
- ({ auth: s, redirectUrl: o }) =>
- ({ authActions: i }) => {
- let { schema: u, name: _, clientId: w, clientSecret: x, codeVerifier: C } = s,
- j = { Authorization: 'Basic ' + utils_btoa(w + ':' + x) },
- L = {
- grant_type: 'authorization_code',
- code: s.code,
- client_id: w,
- redirect_uri: o,
- code_verifier: C
- };
- return i.authorizeRequest({
- body: buildFormData(L),
- name: _,
- url: u.get('tokenUrl'),
- auth: s,
- headers: j
- });
- },
- authorizeRequest =
- (s) =>
- ({
- fn: o,
- getConfigs: i,
- authActions: u,
- errActions: _,
- oas3Selectors: w,
- specSelectors: x,
- authSelectors: C
- }) => {
- let j,
- { body: L, query: B = {}, headers: $ = {}, name: V, url: U, auth: z } = s,
- { additionalQueryStringParams: Y } = C.getConfigs() || {};
- if (x.isOAS3()) {
- let s = w.serverEffectiveValue(w.selectedServer());
- j = Mt()(U, s, !0);
- } else j = Mt()(U, x.url(), !0);
- 'object' == typeof Y && (j.query = Object.assign({}, j.query, Y));
- const Z = j.toString();
- let ee = Object.assign(
- {
- Accept: 'application/json, text/plain, */*',
- 'Content-Type': 'application/x-www-form-urlencoded',
- 'X-Requested-With': 'XMLHttpRequest'
- },
- $
- );
- o.fetch({
- url: Z,
- method: 'post',
- headers: ee,
- query: B,
- body: L,
- requestInterceptor: i().requestInterceptor,
- responseInterceptor: i().responseInterceptor
- })
- .then(function (s) {
- let o = JSON.parse(s.data),
- i = o && (o.error || ''),
- w = o && (o.parseError || '');
- s.ok
- ? i || w
- ? _.newAuthErr({
- authId: V,
- level: 'error',
- source: 'auth',
- message: JSON.stringify(o)
- })
- : u.authorizeOauth2WithPersistOption({ auth: z, token: o })
- : _.newAuthErr({
- authId: V,
- level: 'error',
- source: 'auth',
- message: s.statusText
- });
- })
- .catch((s) => {
- let o = new Error(s).message;
- if (s.response && s.response.data) {
- const i = s.response.data;
- try {
- const s = 'string' == typeof i ? JSON.parse(i) : i;
- s.error && (o += `, error: ${s.error}`),
- s.error_description && (o += `, description: ${s.error_description}`);
- } catch (s) {}
- }
- _.newAuthErr({ authId: V, level: 'error', source: 'auth', message: o });
- });
- };
- function configureAuth(s) {
- return { type: Ft, payload: s };
- }
- function restoreAuthorization(s) {
- return { type: qt, payload: s };
- }
- const persistAuthorizationIfNeeded =
- () =>
- ({ authSelectors: s, getConfigs: o }) => {
- if (!o().persistAuthorization) return;
- const i = s.authorized().toJS();
- localStorage.setItem('authorized', JSON.stringify(i));
- },
- authPopup = (s, o) => () => {
- (at.swaggerUIRedirectOauth2 = o), at.open(s);
- },
- $t = {
- [Tt]: (s, { payload: o }) => s.set('showDefinitions', o),
- [Nt]: (s, { payload: o }) => {
- let i = (0, qe.fromJS)(o),
- u = s.get('authorized') || (0, qe.Map)();
- return (
- i.entrySeq().forEach(([o, i]) => {
- if (!isFunc(i.getIn)) return s.set('authorized', u);
- let _ = i.getIn(['schema', 'type']);
- if ('apiKey' === _ || 'http' === _) u = u.set(o, i);
- else if ('basic' === _) {
- let s = i.getIn(['value', 'username']),
- _ = i.getIn(['value', 'password']);
- (u = u.setIn([o, 'value'], {
- username: s,
- header: 'Basic ' + utils_btoa(s + ':' + _)
- })),
- (u = u.setIn([o, 'schema'], i.get('schema')));
- }
- }),
- s.set('authorized', u)
- );
- },
- [Lt]: (s, { payload: o }) => {
- let i,
- { auth: u, token: _ } = o;
- (u.token = Object.assign({}, _)), (i = (0, qe.fromJS)(u));
- let w = s.get('authorized') || (0, qe.Map)();
- return (w = w.set(i.get('name'), i)), s.set('authorized', w);
- },
- [Rt]: (s, { payload: o }) => {
- let i = s.get('authorized').withMutations((s) => {
- o.forEach((o) => {
- s.delete(o);
- });
- });
- return s.set('authorized', i);
- },
- [Ft]: (s, { payload: o }) => s.set('configs', o),
- [qt]: (s, { payload: o }) => s.set('authorized', (0, qe.fromJS)(o.authorized))
- };
- function assertIsFunction(s, o = 'expected a function, instead received ' + typeof s) {
- if ('function' != typeof s) throw new TypeError(o);
- }
- var ensureIsArray = (s) => (Array.isArray(s) ? s : [s]);
- function getDependencies(s) {
- const o = Array.isArray(s[0]) ? s[0] : s;
- return (
- (function assertIsArrayOfFunctions(
- s,
- o = 'expected all items to be functions, instead received the following types: '
- ) {
- if (!s.every((s) => 'function' == typeof s)) {
- const i = s
- .map((s) =>
- 'function' == typeof s ? `function ${s.name || 'unnamed'}()` : typeof s
- )
- .join(', ');
- throw new TypeError(`${o}[${i}]`);
- }
- })(
- o,
- 'createSelector expects all input-selectors to be functions, but received the following types: '
- ),
- o
- );
- }
- Symbol(), Object.getPrototypeOf({});
- var Vt =
- 'undefined' != typeof WeakRef
- ? WeakRef
- : class {
- constructor(s) {
- this.value = s;
- }
- deref() {
- return this.value;
- }
- };
- function weakMapMemoize(s, o = {}) {
- let i = { s: 0, v: void 0, o: null, p: null };
- const { resultEqualityCheck: u } = o;
- let _,
- w = 0;
- function memoized() {
- let o = i;
- const { length: x } = arguments;
- for (let s = 0, i = x; s < i; s++) {
- const i = arguments[s];
- if ('function' == typeof i || ('object' == typeof i && null !== i)) {
- let s = o.o;
- null === s && (o.o = s = new WeakMap());
- const u = s.get(i);
- void 0 === u ? ((o = { s: 0, v: void 0, o: null, p: null }), s.set(i, o)) : (o = u);
- } else {
- let s = o.p;
- null === s && (o.p = s = new Map());
- const u = s.get(i);
- void 0 === u ? ((o = { s: 0, v: void 0, o: null, p: null }), s.set(i, o)) : (o = u);
- }
- }
- const C = o;
- let j;
- if (1 === o.s) j = o.v;
- else if (((j = s.apply(null, arguments)), w++, u)) {
- const s = _?.deref?.() ?? _;
- null != s && u(s, j) && ((j = s), 0 !== w && w--);
- _ = ('object' == typeof j && null !== j) || 'function' == typeof j ? new Vt(j) : j;
- }
- return (C.s = 1), (C.v = j), j;
- }
- return (
- (memoized.clearCache = () => {
- (i = { s: 0, v: void 0, o: null, p: null }), memoized.resetResultsCount();
- }),
- (memoized.resultsCount = () => w),
- (memoized.resetResultsCount = () => {
- w = 0;
- }),
- memoized
- );
- }
- function createSelectorCreator(s, ...o) {
- const i = 'function' == typeof s ? { memoize: s, memoizeOptions: o } : s,
- createSelector2 = (...s) => {
- let o,
- u = 0,
- _ = 0,
- w = {},
- x = s.pop();
- 'object' == typeof x && ((w = x), (x = s.pop())),
- assertIsFunction(
- x,
- `createSelector expects an output function after the inputs, but received: [${typeof x}]`
- );
- const C = { ...i, ...w },
- {
- memoize: j,
- memoizeOptions: L = [],
- argsMemoize: B = weakMapMemoize,
- argsMemoizeOptions: $ = [],
- devModeChecks: V = {}
- } = C,
- U = ensureIsArray(L),
- z = ensureIsArray($),
- Y = getDependencies(s),
- Z = j(
- function recomputationWrapper() {
- return u++, x.apply(null, arguments);
- },
- ...U
- );
- const ee = B(
- function dependenciesChecker() {
- _++;
- const s = (function collectInputSelectorResults(s, o) {
- const i = [],
- { length: u } = s;
- for (let _ = 0; _ < u; _++) i.push(s[_].apply(null, o));
- return i;
- })(Y, arguments);
- return (o = Z.apply(null, s)), o;
- },
- ...z
- );
- return Object.assign(ee, {
- resultFunc: x,
- memoizedResultFunc: Z,
- dependencies: Y,
- dependencyRecomputations: () => _,
- resetDependencyRecomputations: () => {
- _ = 0;
- },
- lastResult: () => o,
- recomputations: () => u,
- resetRecomputations: () => {
- u = 0;
- },
- memoize: j,
- argsMemoize: B
- });
- };
- return (
- Object.assign(createSelector2, { withTypes: () => createSelector2 }), createSelector2
- );
- }
- var Ut = createSelectorCreator(weakMapMemoize),
- zt = Object.assign(
- (s, o = Ut) => {
- !(function assertIsObject(s, o = 'expected an object, instead received ' + typeof s) {
- if ('object' != typeof s) throw new TypeError(o);
- })(
- s,
- 'createStructuredSelector expects first argument to be an object where each property is a selector, instead received a ' +
- typeof s
- );
- const i = Object.keys(s);
- return o(
- i.map((o) => s[o]),
- (...s) => s.reduce((s, o, u) => ((s[i[u]] = o), s), {})
- );
- },
- { withTypes: () => zt }
- );
- const state = (s) => s,
- Wt = Ut(state, (s) => s.get('showDefinitions')),
- Kt = Ut(state, () => ({ specSelectors: s }) => {
- let o = s.securityDefinitions() || (0, qe.Map)({}),
- i = (0, qe.List)();
- return (
- o.entrySeq().forEach(([s, o]) => {
- let u = (0, qe.Map)();
- (u = u.set(s, o)), (i = i.push(u));
- }),
- i
- );
- }),
- getDefinitionsByNames =
- (s, o) =>
- ({ specSelectors: s }) => {
- console.warn(
- 'WARNING: getDefinitionsByNames is deprecated and will be removed in the next major version.'
- );
- let i = s.securityDefinitions(),
- u = (0, qe.List)();
- return (
- o.valueSeq().forEach((s) => {
- let o = (0, qe.Map)();
- s.entrySeq().forEach(([s, u]) => {
- let _,
- w = i.get(s);
- 'oauth2' === w.get('type') &&
- u.size &&
- ((_ = w.get('scopes')),
- _.keySeq().forEach((s) => {
- u.contains(s) || (_ = _.delete(s));
- }),
- (w = w.set('allowedScopes', _))),
- (o = o.set(s, w));
- }),
- (u = u.push(o));
- }),
- u
- );
- },
- definitionsForRequirements =
- (s, o = (0, qe.List)()) =>
- ({ authSelectors: s }) => {
- const i = s.definitionsToAuthorize() || (0, qe.List)();
- let u = (0, qe.List)();
- return (
- i.forEach((s) => {
- let i = o.find((o) => o.get(s.keySeq().first()));
- i &&
- (s.forEach((o, u) => {
- if ('oauth2' === o.get('type')) {
- const _ = i.get(u);
- let w = o.get('scopes');
- qe.List.isList(_) &&
- qe.Map.isMap(w) &&
- (w.keySeq().forEach((s) => {
- _.contains(s) || (w = w.delete(s));
- }),
- (s = s.set(u, o.set('scopes', w))));
- }
- }),
- (u = u.push(s)));
- }),
- u
- );
- },
- Ht = Ut(state, (s) => s.get('authorized') || (0, qe.Map)()),
- isAuthorized =
- (s, o) =>
- ({ authSelectors: s }) => {
- let i = s.authorized();
- return qe.List.isList(o)
- ? !!o.toJS().filter(
- (s) =>
- -1 ===
- Object.keys(s)
- .map((s) => !!i.get(s))
- .indexOf(!1)
- ).length
- : null;
- },
- Jt = Ut(state, (s) => s.get('configs')),
- execute =
- (s, { authSelectors: o, specSelectors: i }) =>
- ({ path: u, method: _, operation: w, extras: x }) => {
- let C = {
- authorized: o.authorized() && o.authorized().toJS(),
- definitions: i.securityDefinitions() && i.securityDefinitions().toJS(),
- specSecurity: i.security() && i.security().toJS()
- };
- return s({ path: u, method: _, operation: w, securities: C, ...x });
- },
- loaded = (s, o) => (i) => {
- const { getConfigs: u, authActions: _ } = o,
- w = u();
- if ((s(i), w.persistAuthorization)) {
- const s = localStorage.getItem('authorized');
- s && _.restoreAuthorization({ authorized: JSON.parse(s) });
- }
- },
- wrap_actions_authorize = (s, o) => (i) => {
- s(i);
- if (o.getConfigs().persistAuthorization)
- try {
- const [{ schema: s, value: o }] = Object.values(i),
- u = 'apiKey' === s.get('type'),
- _ = 'cookie' === s.get('in');
- u && _ && (document.cookie = `${s.get('name')}=${o}; SameSite=None; Secure`);
- } catch (s) {
- console.error('Error persisting cookie based apiKey in document.cookie.', s);
- }
- },
- wrap_actions_logout = (s, o) => (i) => {
- const u = o.getConfigs(),
- _ = o.authSelectors.authorized();
- try {
- u.persistAuthorization &&
- Array.isArray(i) &&
- i.forEach((s) => {
- const o = _.get(s, {}),
- i = 'apiKey' === o.getIn(['schema', 'type']),
- u = 'cookie' === o.getIn(['schema', 'in']);
- if (i && u) {
- const s = o.getIn(['schema', 'name']);
- document.cookie = `${s}=; Max-Age=-99999999`;
- }
- });
- } catch (s) {
- console.error('Error deleting cookie based apiKey from document.cookie.', s);
- }
- s(i);
- };
- var Gt = __webpack_require__(90179),
- Yt = __webpack_require__.n(Gt);
- class LockAuthIcon extends Pe.Component {
- mapStateToProps(s, o) {
- return { state: s, ownProps: Yt()(o, Object.keys(o.getSystem())) };
- }
- render() {
- const { getComponent: s, ownProps: o } = this.props,
- i = s('LockIcon');
- return Pe.createElement(i, o);
- }
- }
- const Xt = LockAuthIcon;
- class UnlockAuthIcon extends Pe.Component {
- mapStateToProps(s, o) {
- return { state: s, ownProps: Yt()(o, Object.keys(o.getSystem())) };
- }
- render() {
- const { getComponent: s, ownProps: o } = this.props,
- i = s('UnlockIcon');
- return Pe.createElement(i, o);
- }
- }
- const Zt = UnlockAuthIcon;
- function auth() {
- return {
- afterLoad(s) {
- (this.rootInjects = this.rootInjects || {}),
- (this.rootInjects.initOAuth = s.authActions.configureAuth),
- (this.rootInjects.preauthorizeApiKey = preauthorizeApiKey.bind(null, s)),
- (this.rootInjects.preauthorizeBasic = preauthorizeBasic.bind(null, s));
- },
- components: {
- LockAuthIcon: Xt,
- UnlockAuthIcon: Zt,
- LockAuthOperationIcon: Xt,
- UnlockAuthOperationIcon: Zt
- },
- statePlugins: {
- auth: {
- reducers: $t,
- actions: o,
- selectors: i,
- wrapActions: { authorize: wrap_actions_authorize, logout: wrap_actions_logout }
- },
- configs: { wrapActions: { loaded } },
- spec: { wrapActions: { execute } }
- }
- };
- }
- function preauthorizeBasic(s, o, i, u) {
- const {
- authActions: { authorize: _ },
- specSelectors: { specJson: w, isOAS3: x }
- } = s,
- C = x() ? ['components', 'securitySchemes'] : ['securityDefinitions'],
- j = w().getIn([...C, o]);
- return j ? _({ [o]: { value: { username: i, password: u }, schema: j.toJS() } }) : null;
- }
- function preauthorizeApiKey(s, o, i) {
- const {
- authActions: { authorize: u },
- specSelectors: { specJson: _, isOAS3: w }
- } = s,
- x = w() ? ['components', 'securitySchemes'] : ['securityDefinitions'],
- C = _().getIn([...x, o]);
- return C ? u({ [o]: { value: i, schema: C.toJS() } }) : null;
- }
- function isNothing(s) {
- return null == s;
- }
- var Qt = function repeat(s, o) {
- var i,
- u = '';
- for (i = 0; i < o; i += 1) u += s;
- return u;
- },
- er = function isNegativeZero(s) {
- return 0 === s && Number.NEGATIVE_INFINITY === 1 / s;
- },
- tr = {
- isNothing,
- isObject: function js_yaml_isObject(s) {
- return 'object' == typeof s && null !== s;
- },
- toArray: function toArray(s) {
- return Array.isArray(s) ? s : isNothing(s) ? [] : [s];
- },
- repeat: Qt,
- isNegativeZero: er,
- extend: function extend(s, o) {
- var i, u, _, w;
- if (o)
- for (i = 0, u = (w = Object.keys(o)).length; i < u; i += 1) s[(_ = w[i])] = o[_];
- return s;
- }
- };
- function formatError(s, o) {
- var i = '',
- u = s.reason || '(unknown reason)';
- return s.mark
- ? (s.mark.name && (i += 'in "' + s.mark.name + '" '),
- (i += '(' + (s.mark.line + 1) + ':' + (s.mark.column + 1) + ')'),
- !o && s.mark.snippet && (i += '\n\n' + s.mark.snippet),
- u + ' ' + i)
- : u;
- }
- function YAMLException$1(s, o) {
- Error.call(this),
- (this.name = 'YAMLException'),
- (this.reason = s),
- (this.mark = o),
- (this.message = formatError(this, !1)),
- Error.captureStackTrace
- ? Error.captureStackTrace(this, this.constructor)
- : (this.stack = new Error().stack || '');
- }
- (YAMLException$1.prototype = Object.create(Error.prototype)),
- (YAMLException$1.prototype.constructor = YAMLException$1),
- (YAMLException$1.prototype.toString = function toString(s) {
- return this.name + ': ' + formatError(this, s);
- });
- var rr = YAMLException$1;
- function getLine(s, o, i, u, _) {
- var w = '',
- x = '',
- C = Math.floor(_ / 2) - 1;
- return (
- u - o > C && (o = u - C + (w = ' ... ').length),
- i - u > C && (i = u + C - (x = ' ...').length),
- { str: w + s.slice(o, i).replace(/\t/g, '→') + x, pos: u - o + w.length }
- );
- }
- function padStart(s, o) {
- return tr.repeat(' ', o - s.length) + s;
- }
- var nr = function makeSnippet(s, o) {
- if (((o = Object.create(o || null)), !s.buffer)) return null;
- o.maxLength || (o.maxLength = 79),
- 'number' != typeof o.indent && (o.indent = 1),
- 'number' != typeof o.linesBefore && (o.linesBefore = 3),
- 'number' != typeof o.linesAfter && (o.linesAfter = 2);
- for (var i, u = /\r?\n|\r|\0/g, _ = [0], w = [], x = -1; (i = u.exec(s.buffer)); )
- w.push(i.index),
- _.push(i.index + i[0].length),
- s.position <= i.index && x < 0 && (x = _.length - 2);
- x < 0 && (x = _.length - 1);
- var C,
- j,
- L = '',
- B = Math.min(s.line + o.linesAfter, w.length).toString().length,
- $ = o.maxLength - (o.indent + B + 3);
- for (C = 1; C <= o.linesBefore && !(x - C < 0); C++)
- (j = getLine(s.buffer, _[x - C], w[x - C], s.position - (_[x] - _[x - C]), $)),
- (L =
- tr.repeat(' ', o.indent) +
- padStart((s.line - C + 1).toString(), B) +
- ' | ' +
- j.str +
- '\n' +
- L);
- for (
- j = getLine(s.buffer, _[x], w[x], s.position, $),
- L +=
- tr.repeat(' ', o.indent) +
- padStart((s.line + 1).toString(), B) +
- ' | ' +
- j.str +
- '\n',
- L += tr.repeat('-', o.indent + B + 3 + j.pos) + '^\n',
- C = 1;
- C <= o.linesAfter && !(x + C >= w.length);
- C++
- )
- (j = getLine(s.buffer, _[x + C], w[x + C], s.position - (_[x] - _[x + C]), $)),
- (L +=
- tr.repeat(' ', o.indent) +
- padStart((s.line + C + 1).toString(), B) +
- ' | ' +
- j.str +
- '\n');
- return L.replace(/\n$/, '');
- },
- sr = [
- 'kind',
- 'multi',
- 'resolve',
- 'construct',
- 'instanceOf',
- 'predicate',
- 'represent',
- 'representName',
- 'defaultStyle',
- 'styleAliases'
- ],
- ir = ['scalar', 'sequence', 'mapping'];
- var ar = function Type$1(s, o) {
- if (
- ((o = o || {}),
- Object.keys(o).forEach(function (o) {
- if (-1 === sr.indexOf(o))
- throw new rr(
- 'Unknown option "' + o + '" is met in definition of "' + s + '" YAML type.'
- );
- }),
- (this.options = o),
- (this.tag = s),
- (this.kind = o.kind || null),
- (this.resolve =
- o.resolve ||
- function () {
- return !0;
- }),
- (this.construct =
- o.construct ||
- function (s) {
- return s;
- }),
- (this.instanceOf = o.instanceOf || null),
- (this.predicate = o.predicate || null),
- (this.represent = o.represent || null),
- (this.representName = o.representName || null),
- (this.defaultStyle = o.defaultStyle || null),
- (this.multi = o.multi || !1),
- (this.styleAliases = (function compileStyleAliases(s) {
- var o = {};
- return (
- null !== s &&
- Object.keys(s).forEach(function (i) {
- s[i].forEach(function (s) {
- o[String(s)] = i;
- });
- }),
- o
- );
- })(o.styleAliases || null)),
- -1 === ir.indexOf(this.kind))
- )
- throw new rr(
- 'Unknown kind "' + this.kind + '" is specified for "' + s + '" YAML type.'
- );
- };
- function compileList(s, o) {
- var i = [];
- return (
- s[o].forEach(function (s) {
- var o = i.length;
- i.forEach(function (i, u) {
- i.tag === s.tag && i.kind === s.kind && i.multi === s.multi && (o = u);
- }),
- (i[o] = s);
- }),
- i
- );
- }
- function Schema$1(s) {
- return this.extend(s);
- }
- Schema$1.prototype.extend = function extend(s) {
- var o = [],
- i = [];
- if (s instanceof ar) i.push(s);
- else if (Array.isArray(s)) i = i.concat(s);
- else {
- if (!s || (!Array.isArray(s.implicit) && !Array.isArray(s.explicit)))
- throw new rr(
- 'Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })'
- );
- s.implicit && (o = o.concat(s.implicit)), s.explicit && (i = i.concat(s.explicit));
- }
- o.forEach(function (s) {
- if (!(s instanceof ar))
- throw new rr(
- 'Specified list of YAML types (or a single Type object) contains a non-Type object.'
- );
- if (s.loadKind && 'scalar' !== s.loadKind)
- throw new rr(
- 'There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.'
- );
- if (s.multi)
- throw new rr(
- 'There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.'
- );
- }),
- i.forEach(function (s) {
- if (!(s instanceof ar))
- throw new rr(
- 'Specified list of YAML types (or a single Type object) contains a non-Type object.'
- );
- });
- var u = Object.create(Schema$1.prototype);
- return (
- (u.implicit = (this.implicit || []).concat(o)),
- (u.explicit = (this.explicit || []).concat(i)),
- (u.compiledImplicit = compileList(u, 'implicit')),
- (u.compiledExplicit = compileList(u, 'explicit')),
- (u.compiledTypeMap = (function compileMap() {
- var s,
- o,
- i = {
- scalar: {},
- sequence: {},
- mapping: {},
- fallback: {},
- multi: { scalar: [], sequence: [], mapping: [], fallback: [] }
- };
- function collectType(s) {
- s.multi
- ? (i.multi[s.kind].push(s), i.multi.fallback.push(s))
- : (i[s.kind][s.tag] = i.fallback[s.tag] = s);
- }
- for (s = 0, o = arguments.length; s < o; s += 1) arguments[s].forEach(collectType);
- return i;
- })(u.compiledImplicit, u.compiledExplicit)),
- u
- );
- };
- var lr = Schema$1,
- cr = new ar('tag:yaml.org,2002:str', {
- kind: 'scalar',
- construct: function (s) {
- return null !== s ? s : '';
- }
- }),
- ur = new ar('tag:yaml.org,2002:seq', {
- kind: 'sequence',
- construct: function (s) {
- return null !== s ? s : [];
- }
- }),
- pr = new ar('tag:yaml.org,2002:map', {
- kind: 'mapping',
- construct: function (s) {
- return null !== s ? s : {};
- }
- }),
- dr = new lr({ explicit: [cr, ur, pr] });
- var fr = new ar('tag:yaml.org,2002:null', {
- kind: 'scalar',
- resolve: function resolveYamlNull(s) {
- if (null === s) return !0;
- var o = s.length;
- return (
- (1 === o && '~' === s) || (4 === o && ('null' === s || 'Null' === s || 'NULL' === s))
- );
- },
- construct: function constructYamlNull() {
- return null;
- },
- predicate: function isNull(s) {
- return null === s;
- },
- represent: {
- canonical: function () {
- return '~';
- },
- lowercase: function () {
- return 'null';
- },
- uppercase: function () {
- return 'NULL';
- },
- camelcase: function () {
- return 'Null';
- },
- empty: function () {
- return '';
- }
- },
- defaultStyle: 'lowercase'
- });
- var mr = new ar('tag:yaml.org,2002:bool', {
- kind: 'scalar',
- resolve: function resolveYamlBoolean(s) {
- if (null === s) return !1;
- var o = s.length;
- return (
- (4 === o && ('true' === s || 'True' === s || 'TRUE' === s)) ||
- (5 === o && ('false' === s || 'False' === s || 'FALSE' === s))
- );
- },
- construct: function constructYamlBoolean(s) {
- return 'true' === s || 'True' === s || 'TRUE' === s;
- },
- predicate: function isBoolean(s) {
- return '[object Boolean]' === Object.prototype.toString.call(s);
- },
- represent: {
- lowercase: function (s) {
- return s ? 'true' : 'false';
- },
- uppercase: function (s) {
- return s ? 'TRUE' : 'FALSE';
- },
- camelcase: function (s) {
- return s ? 'True' : 'False';
- }
- },
- defaultStyle: 'lowercase'
- });
- function isOctCode(s) {
- return 48 <= s && s <= 55;
- }
- function isDecCode(s) {
- return 48 <= s && s <= 57;
- }
- var gr = new ar('tag:yaml.org,2002:int', {
- kind: 'scalar',
- resolve: function resolveYamlInteger(s) {
- if (null === s) return !1;
- var o,
- i,
- u = s.length,
- _ = 0,
- w = !1;
- if (!u) return !1;
- if ((('-' !== (o = s[_]) && '+' !== o) || (o = s[++_]), '0' === o)) {
- if (_ + 1 === u) return !0;
- if ('b' === (o = s[++_])) {
- for (_++; _ < u; _++)
- if ('_' !== (o = s[_])) {
- if ('0' !== o && '1' !== o) return !1;
- w = !0;
- }
- return w && '_' !== o;
- }
- if ('x' === o) {
- for (_++; _ < u; _++)
- if ('_' !== (o = s[_])) {
- if (
- !(
- (48 <= (i = s.charCodeAt(_)) && i <= 57) ||
- (65 <= i && i <= 70) ||
- (97 <= i && i <= 102)
- )
- )
- return !1;
- w = !0;
- }
- return w && '_' !== o;
- }
- if ('o' === o) {
- for (_++; _ < u; _++)
- if ('_' !== (o = s[_])) {
- if (!isOctCode(s.charCodeAt(_))) return !1;
- w = !0;
- }
- return w && '_' !== o;
- }
- }
- if ('_' === o) return !1;
- for (; _ < u; _++)
- if ('_' !== (o = s[_])) {
- if (!isDecCode(s.charCodeAt(_))) return !1;
- w = !0;
- }
- return !(!w || '_' === o);
- },
- construct: function constructYamlInteger(s) {
- var o,
- i = s,
- u = 1;
- if (
- (-1 !== i.indexOf('_') && (i = i.replace(/_/g, '')),
- ('-' !== (o = i[0]) && '+' !== o) ||
- ('-' === o && (u = -1), (o = (i = i.slice(1))[0])),
- '0' === i)
- )
- return 0;
- if ('0' === o) {
- if ('b' === i[1]) return u * parseInt(i.slice(2), 2);
- if ('x' === i[1]) return u * parseInt(i.slice(2), 16);
- if ('o' === i[1]) return u * parseInt(i.slice(2), 8);
- }
- return u * parseInt(i, 10);
- },
- predicate: function isInteger(s) {
- return (
- '[object Number]' === Object.prototype.toString.call(s) &&
- s % 1 == 0 &&
- !tr.isNegativeZero(s)
- );
- },
- represent: {
- binary: function (s) {
- return s >= 0 ? '0b' + s.toString(2) : '-0b' + s.toString(2).slice(1);
- },
- octal: function (s) {
- return s >= 0 ? '0o' + s.toString(8) : '-0o' + s.toString(8).slice(1);
- },
- decimal: function (s) {
- return s.toString(10);
- },
- hexadecimal: function (s) {
- return s >= 0
- ? '0x' + s.toString(16).toUpperCase()
- : '-0x' + s.toString(16).toUpperCase().slice(1);
- }
- },
- defaultStyle: 'decimal',
- styleAliases: {
- binary: [2, 'bin'],
- octal: [8, 'oct'],
- decimal: [10, 'dec'],
- hexadecimal: [16, 'hex']
- }
- }),
- yr = new RegExp(
- '^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$'
- );
- var vr = /^[-+]?[0-9]+e/;
- var br = new ar('tag:yaml.org,2002:float', {
- kind: 'scalar',
- resolve: function resolveYamlFloat(s) {
- return null !== s && !(!yr.test(s) || '_' === s[s.length - 1]);
- },
- construct: function constructYamlFloat(s) {
- var o, i;
- return (
- (i = '-' === (o = s.replace(/_/g, '').toLowerCase())[0] ? -1 : 1),
- '+-'.indexOf(o[0]) >= 0 && (o = o.slice(1)),
- '.inf' === o
- ? 1 === i
- ? Number.POSITIVE_INFINITY
- : Number.NEGATIVE_INFINITY
- : '.nan' === o
- ? NaN
- : i * parseFloat(o, 10)
- );
- },
- predicate: function isFloat(s) {
- return (
- '[object Number]' === Object.prototype.toString.call(s) &&
- (s % 1 != 0 || tr.isNegativeZero(s))
- );
- },
- represent: function representYamlFloat(s, o) {
- var i;
- if (isNaN(s))
- switch (o) {
- case 'lowercase':
- return '.nan';
- case 'uppercase':
- return '.NAN';
- case 'camelcase':
- return '.NaN';
- }
- else if (Number.POSITIVE_INFINITY === s)
- switch (o) {
- case 'lowercase':
- return '.inf';
- case 'uppercase':
- return '.INF';
- case 'camelcase':
- return '.Inf';
- }
- else if (Number.NEGATIVE_INFINITY === s)
- switch (o) {
- case 'lowercase':
- return '-.inf';
- case 'uppercase':
- return '-.INF';
- case 'camelcase':
- return '-.Inf';
- }
- else if (tr.isNegativeZero(s)) return '-0.0';
- return (i = s.toString(10)), vr.test(i) ? i.replace('e', '.e') : i;
- },
- defaultStyle: 'lowercase'
- }),
- _r = dr.extend({ implicit: [fr, mr, gr, br] }),
- Er = _r,
- wr = new RegExp('^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$'),
- Sr = new RegExp(
- '^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$'
- );
- var xr = new ar('tag:yaml.org,2002:timestamp', {
- kind: 'scalar',
- resolve: function resolveYamlTimestamp(s) {
- return null !== s && (null !== wr.exec(s) || null !== Sr.exec(s));
- },
- construct: function constructYamlTimestamp(s) {
- var o,
- i,
- u,
- _,
- w,
- x,
- C,
- j,
- L = 0,
- B = null;
- if ((null === (o = wr.exec(s)) && (o = Sr.exec(s)), null === o))
- throw new Error('Date resolve error');
- if (((i = +o[1]), (u = +o[2] - 1), (_ = +o[3]), !o[4]))
- return new Date(Date.UTC(i, u, _));
- if (((w = +o[4]), (x = +o[5]), (C = +o[6]), o[7])) {
- for (L = o[7].slice(0, 3); L.length < 3; ) L += '0';
- L = +L;
- }
- return (
- o[9] && ((B = 6e4 * (60 * +o[10] + +(o[11] || 0))), '-' === o[9] && (B = -B)),
- (j = new Date(Date.UTC(i, u, _, w, x, C, L))),
- B && j.setTime(j.getTime() - B),
- j
- );
- },
- instanceOf: Date,
- represent: function representYamlTimestamp(s) {
- return s.toISOString();
- }
- });
- var kr = new ar('tag:yaml.org,2002:merge', {
- kind: 'scalar',
- resolve: function resolveYamlMerge(s) {
- return '<<' === s || null === s;
- }
- }),
- Cr = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\n\r';
- var Or = new ar('tag:yaml.org,2002:binary', {
- kind: 'scalar',
- resolve: function resolveYamlBinary(s) {
- if (null === s) return !1;
- var o,
- i,
- u = 0,
- _ = s.length,
- w = Cr;
- for (i = 0; i < _; i++)
- if (!((o = w.indexOf(s.charAt(i))) > 64)) {
- if (o < 0) return !1;
- u += 6;
- }
- return u % 8 == 0;
- },
- construct: function constructYamlBinary(s) {
- var o,
- i,
- u = s.replace(/[\r\n=]/g, ''),
- _ = u.length,
- w = Cr,
- x = 0,
- C = [];
- for (o = 0; o < _; o++)
- o % 4 == 0 &&
- o &&
- (C.push((x >> 16) & 255), C.push((x >> 8) & 255), C.push(255 & x)),
- (x = (x << 6) | w.indexOf(u.charAt(o)));
- return (
- 0 === (i = (_ % 4) * 6)
- ? (C.push((x >> 16) & 255), C.push((x >> 8) & 255), C.push(255 & x))
- : 18 === i
- ? (C.push((x >> 10) & 255), C.push((x >> 2) & 255))
- : 12 === i && C.push((x >> 4) & 255),
- new Uint8Array(C)
- );
- },
- predicate: function isBinary(s) {
- return '[object Uint8Array]' === Object.prototype.toString.call(s);
- },
- represent: function representYamlBinary(s) {
- var o,
- i,
- u = '',
- _ = 0,
- w = s.length,
- x = Cr;
- for (o = 0; o < w; o++)
- o % 3 == 0 &&
- o &&
- ((u += x[(_ >> 18) & 63]),
- (u += x[(_ >> 12) & 63]),
- (u += x[(_ >> 6) & 63]),
- (u += x[63 & _])),
- (_ = (_ << 8) + s[o]);
- return (
- 0 === (i = w % 3)
- ? ((u += x[(_ >> 18) & 63]),
- (u += x[(_ >> 12) & 63]),
- (u += x[(_ >> 6) & 63]),
- (u += x[63 & _]))
- : 2 === i
- ? ((u += x[(_ >> 10) & 63]),
- (u += x[(_ >> 4) & 63]),
- (u += x[(_ << 2) & 63]),
- (u += x[64]))
- : 1 === i &&
- ((u += x[(_ >> 2) & 63]),
- (u += x[(_ << 4) & 63]),
- (u += x[64]),
- (u += x[64])),
- u
- );
- }
- }),
- Ar = Object.prototype.hasOwnProperty,
- jr = Object.prototype.toString;
- var Ir = new ar('tag:yaml.org,2002:omap', {
- kind: 'sequence',
- resolve: function resolveYamlOmap(s) {
- if (null === s) return !0;
- var o,
- i,
- u,
- _,
- w,
- x = [],
- C = s;
- for (o = 0, i = C.length; o < i; o += 1) {
- if (((u = C[o]), (w = !1), '[object Object]' !== jr.call(u))) return !1;
- for (_ in u)
- if (Ar.call(u, _)) {
- if (w) return !1;
- w = !0;
- }
- if (!w) return !1;
- if (-1 !== x.indexOf(_)) return !1;
- x.push(_);
- }
- return !0;
- },
- construct: function constructYamlOmap(s) {
- return null !== s ? s : [];
- }
- }),
- Pr = Object.prototype.toString;
- var Mr = new ar('tag:yaml.org,2002:pairs', {
- kind: 'sequence',
- resolve: function resolveYamlPairs(s) {
- if (null === s) return !0;
- var o,
- i,
- u,
- _,
- w,
- x = s;
- for (w = new Array(x.length), o = 0, i = x.length; o < i; o += 1) {
- if (((u = x[o]), '[object Object]' !== Pr.call(u))) return !1;
- if (1 !== (_ = Object.keys(u)).length) return !1;
- w[o] = [_[0], u[_[0]]];
- }
- return !0;
- },
- construct: function constructYamlPairs(s) {
- if (null === s) return [];
- var o,
- i,
- u,
- _,
- w,
- x = s;
- for (w = new Array(x.length), o = 0, i = x.length; o < i; o += 1)
- (u = x[o]), (_ = Object.keys(u)), (w[o] = [_[0], u[_[0]]]);
- return w;
- }
- }),
- Tr = Object.prototype.hasOwnProperty;
- var Nr = new ar('tag:yaml.org,2002:set', {
- kind: 'mapping',
- resolve: function resolveYamlSet(s) {
- if (null === s) return !0;
- var o,
- i = s;
- for (o in i) if (Tr.call(i, o) && null !== i[o]) return !1;
- return !0;
- },
- construct: function constructYamlSet(s) {
- return null !== s ? s : {};
- }
- }),
- Rr = Er.extend({ implicit: [xr, kr], explicit: [Or, Ir, Mr, Nr] }),
- Dr = Object.prototype.hasOwnProperty,
- Lr =
- /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,
- Br = /[\x85\u2028\u2029]/,
- Fr = /[,\[\]\{\}]/,
- qr = /^(?:!|!!|![a-z\-]+!)$/i,
- $r = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;
- function _class(s) {
- return Object.prototype.toString.call(s);
- }
- function is_EOL(s) {
- return 10 === s || 13 === s;
- }
- function is_WHITE_SPACE(s) {
- return 9 === s || 32 === s;
- }
- function is_WS_OR_EOL(s) {
- return 9 === s || 32 === s || 10 === s || 13 === s;
- }
- function is_FLOW_INDICATOR(s) {
- return 44 === s || 91 === s || 93 === s || 123 === s || 125 === s;
- }
- function fromHexCode(s) {
- var o;
- return 48 <= s && s <= 57 ? s - 48 : 97 <= (o = 32 | s) && o <= 102 ? o - 97 + 10 : -1;
- }
- function simpleEscapeSequence(s) {
- return 48 === s
- ? '\0'
- : 97 === s
- ? ''
- : 98 === s
- ? '\b'
- : 116 === s || 9 === s
- ? '\t'
- : 110 === s
- ? '\n'
- : 118 === s
- ? '\v'
- : 102 === s
- ? '\f'
- : 114 === s
- ? '\r'
- : 101 === s
- ? ''
- : 32 === s
- ? ' '
- : 34 === s
- ? '"'
- : 47 === s
- ? '/'
- : 92 === s
- ? '\\'
- : 78 === s
- ? '
'
- : 95 === s
- ? ' '
- : 76 === s
- ? '\u2028'
- : 80 === s
- ? '\u2029'
- : '';
- }
- function charFromCodepoint(s) {
- return s <= 65535
- ? String.fromCharCode(s)
- : String.fromCharCode(55296 + ((s - 65536) >> 10), 56320 + ((s - 65536) & 1023));
- }
- for (var Vr = new Array(256), Ur = new Array(256), zr = 0; zr < 256; zr++)
- (Vr[zr] = simpleEscapeSequence(zr) ? 1 : 0), (Ur[zr] = simpleEscapeSequence(zr));
- function State$1(s, o) {
- (this.input = s),
- (this.filename = o.filename || null),
- (this.schema = o.schema || Rr),
- (this.onWarning = o.onWarning || null),
- (this.legacy = o.legacy || !1),
- (this.json = o.json || !1),
- (this.listener = o.listener || null),
- (this.implicitTypes = this.schema.compiledImplicit),
- (this.typeMap = this.schema.compiledTypeMap),
- (this.length = s.length),
- (this.position = 0),
- (this.line = 0),
- (this.lineStart = 0),
- (this.lineIndent = 0),
- (this.firstTabInLine = -1),
- (this.documents = []);
- }
- function generateError(s, o) {
- var i = {
- name: s.filename,
- buffer: s.input.slice(0, -1),
- position: s.position,
- line: s.line,
- column: s.position - s.lineStart
- };
- return (i.snippet = nr(i)), new rr(o, i);
- }
- function throwError(s, o) {
- throw generateError(s, o);
- }
- function throwWarning(s, o) {
- s.onWarning && s.onWarning.call(null, generateError(s, o));
- }
- var Wr = {
- YAML: function handleYamlDirective(s, o, i) {
- var u, _, w;
- null !== s.version && throwError(s, 'duplication of %YAML directive'),
- 1 !== i.length && throwError(s, 'YAML directive accepts exactly one argument'),
- null === (u = /^([0-9]+)\.([0-9]+)$/.exec(i[0])) &&
- throwError(s, 'ill-formed argument of the YAML directive'),
- (_ = parseInt(u[1], 10)),
- (w = parseInt(u[2], 10)),
- 1 !== _ && throwError(s, 'unacceptable YAML version of the document'),
- (s.version = i[0]),
- (s.checkLineBreaks = w < 2),
- 1 !== w && 2 !== w && throwWarning(s, 'unsupported YAML version of the document');
- },
- TAG: function handleTagDirective(s, o, i) {
- var u, _;
- 2 !== i.length && throwError(s, 'TAG directive accepts exactly two arguments'),
- (u = i[0]),
- (_ = i[1]),
- qr.test(u) ||
- throwError(s, 'ill-formed tag handle (first argument) of the TAG directive'),
- Dr.call(s.tagMap, u) &&
- throwError(s, 'there is a previously declared suffix for "' + u + '" tag handle'),
- $r.test(_) ||
- throwError(s, 'ill-formed tag prefix (second argument) of the TAG directive');
- try {
- _ = decodeURIComponent(_);
- } catch (o) {
- throwError(s, 'tag prefix is malformed: ' + _);
- }
- s.tagMap[u] = _;
- }
- };
- function captureSegment(s, o, i, u) {
- var _, w, x, C;
- if (o < i) {
- if (((C = s.input.slice(o, i)), u))
- for (_ = 0, w = C.length; _ < w; _ += 1)
- 9 === (x = C.charCodeAt(_)) ||
- (32 <= x && x <= 1114111) ||
- throwError(s, 'expected valid JSON character');
- else Lr.test(C) && throwError(s, 'the stream contains non-printable characters');
- s.result += C;
- }
- }
- function mergeMappings(s, o, i, u) {
- var _, w, x, C;
- for (
- tr.isObject(i) ||
- throwError(s, 'cannot merge mappings; the provided source object is unacceptable'),
- x = 0,
- C = (_ = Object.keys(i)).length;
- x < C;
- x += 1
- )
- (w = _[x]), Dr.call(o, w) || ((o[w] = i[w]), (u[w] = !0));
- }
- function storeMappingPair(s, o, i, u, _, w, x, C, j) {
- var L, B;
- if (Array.isArray(_))
- for (L = 0, B = (_ = Array.prototype.slice.call(_)).length; L < B; L += 1)
- Array.isArray(_[L]) && throwError(s, 'nested arrays are not supported inside keys'),
- 'object' == typeof _ &&
- '[object Object]' === _class(_[L]) &&
- (_[L] = '[object Object]');
- if (
- ('object' == typeof _ && '[object Object]' === _class(_) && (_ = '[object Object]'),
- (_ = String(_)),
- null === o && (o = {}),
- 'tag:yaml.org,2002:merge' === u)
- )
- if (Array.isArray(w))
- for (L = 0, B = w.length; L < B; L += 1) mergeMappings(s, o, w[L], i);
- else mergeMappings(s, o, w, i);
- else
- s.json ||
- Dr.call(i, _) ||
- !Dr.call(o, _) ||
- ((s.line = x || s.line),
- (s.lineStart = C || s.lineStart),
- (s.position = j || s.position),
- throwError(s, 'duplicated mapping key')),
- '__proto__' === _
- ? Object.defineProperty(o, _, {
- configurable: !0,
- enumerable: !0,
- writable: !0,
- value: w
- })
- : (o[_] = w),
- delete i[_];
- return o;
- }
- function readLineBreak(s) {
- var o;
- 10 === (o = s.input.charCodeAt(s.position))
- ? s.position++
- : 13 === o
- ? (s.position++, 10 === s.input.charCodeAt(s.position) && s.position++)
- : throwError(s, 'a line break is expected'),
- (s.line += 1),
- (s.lineStart = s.position),
- (s.firstTabInLine = -1);
- }
- function skipSeparationSpace(s, o, i) {
- for (var u = 0, _ = s.input.charCodeAt(s.position); 0 !== _; ) {
- for (; is_WHITE_SPACE(_); )
- 9 === _ && -1 === s.firstTabInLine && (s.firstTabInLine = s.position),
- (_ = s.input.charCodeAt(++s.position));
- if (o && 35 === _)
- do {
- _ = s.input.charCodeAt(++s.position);
- } while (10 !== _ && 13 !== _ && 0 !== _);
- if (!is_EOL(_)) break;
- for (
- readLineBreak(s), _ = s.input.charCodeAt(s.position), u++, s.lineIndent = 0;
- 32 === _;
- )
- s.lineIndent++, (_ = s.input.charCodeAt(++s.position));
- }
- return (
- -1 !== i && 0 !== u && s.lineIndent < i && throwWarning(s, 'deficient indentation'), u
- );
- }
- function testDocumentSeparator(s) {
- var o,
- i = s.position;
- return !(
- (45 !== (o = s.input.charCodeAt(i)) && 46 !== o) ||
- o !== s.input.charCodeAt(i + 1) ||
- o !== s.input.charCodeAt(i + 2) ||
- ((i += 3), 0 !== (o = s.input.charCodeAt(i)) && !is_WS_OR_EOL(o))
- );
- }
- function writeFoldedLines(s, o) {
- 1 === o ? (s.result += ' ') : o > 1 && (s.result += tr.repeat('\n', o - 1));
- }
- function readBlockSequence(s, o) {
- var i,
- u,
- _ = s.tag,
- w = s.anchor,
- x = [],
- C = !1;
- if (-1 !== s.firstTabInLine) return !1;
- for (
- null !== s.anchor && (s.anchorMap[s.anchor] = x), u = s.input.charCodeAt(s.position);
- 0 !== u &&
- (-1 !== s.firstTabInLine &&
- ((s.position = s.firstTabInLine),
- throwError(s, 'tab characters must not be used in indentation')),
- 45 === u) &&
- is_WS_OR_EOL(s.input.charCodeAt(s.position + 1));
- )
- if (((C = !0), s.position++, skipSeparationSpace(s, !0, -1) && s.lineIndent <= o))
- x.push(null), (u = s.input.charCodeAt(s.position));
- else if (
- ((i = s.line),
- composeNode(s, o, 3, !1, !0),
- x.push(s.result),
- skipSeparationSpace(s, !0, -1),
- (u = s.input.charCodeAt(s.position)),
- (s.line === i || s.lineIndent > o) && 0 !== u)
- )
- throwError(s, 'bad indentation of a sequence entry');
- else if (s.lineIndent < o) break;
- return !!C && ((s.tag = _), (s.anchor = w), (s.kind = 'sequence'), (s.result = x), !0);
- }
- function readTagProperty(s) {
- var o,
- i,
- u,
- _,
- w = !1,
- x = !1;
- if (33 !== (_ = s.input.charCodeAt(s.position))) return !1;
- if (
- (null !== s.tag && throwError(s, 'duplication of a tag property'),
- 60 === (_ = s.input.charCodeAt(++s.position))
- ? ((w = !0), (_ = s.input.charCodeAt(++s.position)))
- : 33 === _
- ? ((x = !0), (i = '!!'), (_ = s.input.charCodeAt(++s.position)))
- : (i = '!'),
- (o = s.position),
- w)
- ) {
- do {
- _ = s.input.charCodeAt(++s.position);
- } while (0 !== _ && 62 !== _);
- s.position < s.length
- ? ((u = s.input.slice(o, s.position)), (_ = s.input.charCodeAt(++s.position)))
- : throwError(s, 'unexpected end of the stream within a verbatim tag');
- } else {
- for (; 0 !== _ && !is_WS_OR_EOL(_); )
- 33 === _ &&
- (x
- ? throwError(s, 'tag suffix cannot contain exclamation marks')
- : ((i = s.input.slice(o - 1, s.position + 1)),
- qr.test(i) || throwError(s, 'named tag handle cannot contain such characters'),
- (x = !0),
- (o = s.position + 1))),
- (_ = s.input.charCodeAt(++s.position));
- (u = s.input.slice(o, s.position)),
- Fr.test(u) && throwError(s, 'tag suffix cannot contain flow indicator characters');
- }
- u && !$r.test(u) && throwError(s, 'tag name cannot contain such characters: ' + u);
- try {
- u = decodeURIComponent(u);
- } catch (o) {
- throwError(s, 'tag name is malformed: ' + u);
- }
- return (
- w
- ? (s.tag = u)
- : Dr.call(s.tagMap, i)
- ? (s.tag = s.tagMap[i] + u)
- : '!' === i
- ? (s.tag = '!' + u)
- : '!!' === i
- ? (s.tag = 'tag:yaml.org,2002:' + u)
- : throwError(s, 'undeclared tag handle "' + i + '"'),
- !0
- );
- }
- function readAnchorProperty(s) {
- var o, i;
- if (38 !== (i = s.input.charCodeAt(s.position))) return !1;
- for (
- null !== s.anchor && throwError(s, 'duplication of an anchor property'),
- i = s.input.charCodeAt(++s.position),
- o = s.position;
- 0 !== i && !is_WS_OR_EOL(i) && !is_FLOW_INDICATOR(i);
- )
- i = s.input.charCodeAt(++s.position);
- return (
- s.position === o &&
- throwError(s, 'name of an anchor node must contain at least one character'),
- (s.anchor = s.input.slice(o, s.position)),
- !0
- );
- }
- function composeNode(s, o, i, u, _) {
- var w,
- x,
- C,
- j,
- L,
- B,
- $,
- V,
- U,
- z = 1,
- Y = !1,
- Z = !1;
- if (
- (null !== s.listener && s.listener('open', s),
- (s.tag = null),
- (s.anchor = null),
- (s.kind = null),
- (s.result = null),
- (w = x = C = 4 === i || 3 === i),
- u &&
- skipSeparationSpace(s, !0, -1) &&
- ((Y = !0),
- s.lineIndent > o
- ? (z = 1)
- : s.lineIndent === o
- ? (z = 0)
- : s.lineIndent < o && (z = -1)),
- 1 === z)
- )
- for (; readTagProperty(s) || readAnchorProperty(s); )
- skipSeparationSpace(s, !0, -1)
- ? ((Y = !0),
- (C = w),
- s.lineIndent > o
- ? (z = 1)
- : s.lineIndent === o
- ? (z = 0)
- : s.lineIndent < o && (z = -1))
- : (C = !1);
- if (
- (C && (C = Y || _),
- (1 !== z && 4 !== i) ||
- ((V = 1 === i || 2 === i ? o : o + 1),
- (U = s.position - s.lineStart),
- 1 === z
- ? (C &&
- (readBlockSequence(s, U) ||
- (function readBlockMapping(s, o, i) {
- var u,
- _,
- w,
- x,
- C,
- j,
- L,
- B = s.tag,
- $ = s.anchor,
- V = {},
- U = Object.create(null),
- z = null,
- Y = null,
- Z = null,
- ee = !1,
- ie = !1;
- if (-1 !== s.firstTabInLine) return !1;
- for (
- null !== s.anchor && (s.anchorMap[s.anchor] = V),
- L = s.input.charCodeAt(s.position);
- 0 !== L;
- ) {
- if (
- (ee ||
- -1 === s.firstTabInLine ||
- ((s.position = s.firstTabInLine),
- throwError(s, 'tab characters must not be used in indentation')),
- (u = s.input.charCodeAt(s.position + 1)),
- (w = s.line),
- (63 !== L && 58 !== L) || !is_WS_OR_EOL(u))
- ) {
- if (
- ((x = s.line),
- (C = s.lineStart),
- (j = s.position),
- !composeNode(s, i, 2, !1, !0))
- )
- break;
- if (s.line === w) {
- for (L = s.input.charCodeAt(s.position); is_WHITE_SPACE(L); )
- L = s.input.charCodeAt(++s.position);
- if (58 === L)
- is_WS_OR_EOL((L = s.input.charCodeAt(++s.position))) ||
- throwError(
- s,
- 'a whitespace character is expected after the key-value separator within a block mapping'
- ),
- ee &&
- (storeMappingPair(s, V, U, z, Y, null, x, C, j),
- (z = Y = Z = null)),
- (ie = !0),
- (ee = !1),
- (_ = !1),
- (z = s.tag),
- (Y = s.result);
- else {
- if (!ie) return (s.tag = B), (s.anchor = $), !0;
- throwError(
- s,
- 'can not read an implicit mapping pair; a colon is missed'
- );
- }
- } else {
- if (!ie) return (s.tag = B), (s.anchor = $), !0;
- throwError(
- s,
- 'can not read a block mapping entry; a multiline key may not be an implicit key'
- );
- }
- } else
- 63 === L
- ? (ee &&
- (storeMappingPair(s, V, U, z, Y, null, x, C, j),
- (z = Y = Z = null)),
- (ie = !0),
- (ee = !0),
- (_ = !0))
- : ee
- ? ((ee = !1), (_ = !0))
- : throwError(
- s,
- 'incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line'
- ),
- (s.position += 1),
- (L = u);
- if (
- ((s.line === w || s.lineIndent > o) &&
- (ee && ((x = s.line), (C = s.lineStart), (j = s.position)),
- composeNode(s, o, 4, !0, _) && (ee ? (Y = s.result) : (Z = s.result)),
- ee ||
- (storeMappingPair(s, V, U, z, Y, Z, x, C, j), (z = Y = Z = null)),
- skipSeparationSpace(s, !0, -1),
- (L = s.input.charCodeAt(s.position))),
- (s.line === w || s.lineIndent > o) && 0 !== L)
- )
- throwError(s, 'bad indentation of a mapping entry');
- else if (s.lineIndent < o) break;
- }
- return (
- ee && storeMappingPair(s, V, U, z, Y, null, x, C, j),
- ie && ((s.tag = B), (s.anchor = $), (s.kind = 'mapping'), (s.result = V)),
- ie
- );
- })(s, U, V))) ||
- (function readFlowCollection(s, o) {
- var i,
- u,
- _,
- w,
- x,
- C,
- j,
- L,
- B,
- $,
- V,
- U,
- z = !0,
- Y = s.tag,
- Z = s.anchor,
- ee = Object.create(null);
- if (91 === (U = s.input.charCodeAt(s.position))) (x = 93), (L = !1), (w = []);
- else {
- if (123 !== U) return !1;
- (x = 125), (L = !0), (w = {});
- }
- for (
- null !== s.anchor && (s.anchorMap[s.anchor] = w),
- U = s.input.charCodeAt(++s.position);
- 0 !== U;
- ) {
- if (
- (skipSeparationSpace(s, !0, o), (U = s.input.charCodeAt(s.position)) === x)
- )
- return (
- s.position++,
- (s.tag = Y),
- (s.anchor = Z),
- (s.kind = L ? 'mapping' : 'sequence'),
- (s.result = w),
- !0
- );
- z
- ? 44 === U && throwError(s, "expected the node content, but found ','")
- : throwError(s, 'missed comma between flow collection entries'),
- (V = null),
- (C = j = !1),
- 63 === U &&
- is_WS_OR_EOL(s.input.charCodeAt(s.position + 1)) &&
- ((C = j = !0), s.position++, skipSeparationSpace(s, !0, o)),
- (i = s.line),
- (u = s.lineStart),
- (_ = s.position),
- composeNode(s, o, 1, !1, !0),
- ($ = s.tag),
- (B = s.result),
- skipSeparationSpace(s, !0, o),
- (U = s.input.charCodeAt(s.position)),
- (!j && s.line !== i) ||
- 58 !== U ||
- ((C = !0),
- (U = s.input.charCodeAt(++s.position)),
- skipSeparationSpace(s, !0, o),
- composeNode(s, o, 1, !1, !0),
- (V = s.result)),
- L
- ? storeMappingPair(s, w, ee, $, B, V, i, u, _)
- : C
- ? w.push(storeMappingPair(s, null, ee, $, B, V, i, u, _))
- : w.push(B),
- skipSeparationSpace(s, !0, o),
- 44 === (U = s.input.charCodeAt(s.position))
- ? ((z = !0), (U = s.input.charCodeAt(++s.position)))
- : (z = !1);
- }
- throwError(s, 'unexpected end of the stream within a flow collection');
- })(s, V)
- ? (Z = !0)
- : ((x &&
- (function readBlockScalar(s, o) {
- var i,
- u,
- _,
- w,
- x,
- C = 1,
- j = !1,
- L = !1,
- B = o,
- $ = 0,
- V = !1;
- if (124 === (w = s.input.charCodeAt(s.position))) u = !1;
- else {
- if (62 !== w) return !1;
- u = !0;
- }
- for (s.kind = 'scalar', s.result = ''; 0 !== w; )
- if (43 === (w = s.input.charCodeAt(++s.position)) || 45 === w)
- 1 === C
- ? (C = 43 === w ? 3 : 2)
- : throwError(s, 'repeat of a chomping mode identifier');
- else {
- if (!((_ = 48 <= (x = w) && x <= 57 ? x - 48 : -1) >= 0)) break;
- 0 === _
- ? throwError(
- s,
- 'bad explicit indentation width of a block scalar; it cannot be less than one'
- )
- : L
- ? throwError(s, 'repeat of an indentation width identifier')
- : ((B = o + _ - 1), (L = !0));
- }
- if (is_WHITE_SPACE(w)) {
- do {
- w = s.input.charCodeAt(++s.position);
- } while (is_WHITE_SPACE(w));
- if (35 === w)
- do {
- w = s.input.charCodeAt(++s.position);
- } while (!is_EOL(w) && 0 !== w);
- }
- for (; 0 !== w; ) {
- for (
- readLineBreak(s), s.lineIndent = 0, w = s.input.charCodeAt(s.position);
- (!L || s.lineIndent < B) && 32 === w;
- )
- s.lineIndent++, (w = s.input.charCodeAt(++s.position));
- if ((!L && s.lineIndent > B && (B = s.lineIndent), is_EOL(w))) $++;
- else {
- if (s.lineIndent < B) {
- 3 === C
- ? (s.result += tr.repeat('\n', j ? 1 + $ : $))
- : 1 === C && j && (s.result += '\n');
- break;
- }
- for (
- u
- ? is_WHITE_SPACE(w)
- ? ((V = !0), (s.result += tr.repeat('\n', j ? 1 + $ : $)))
- : V
- ? ((V = !1), (s.result += tr.repeat('\n', $ + 1)))
- : 0 === $
- ? j && (s.result += ' ')
- : (s.result += tr.repeat('\n', $))
- : (s.result += tr.repeat('\n', j ? 1 + $ : $)),
- j = !0,
- L = !0,
- $ = 0,
- i = s.position;
- !is_EOL(w) && 0 !== w;
- )
- w = s.input.charCodeAt(++s.position);
- captureSegment(s, i, s.position, !1);
- }
- }
- return !0;
- })(s, V)) ||
- (function readSingleQuotedScalar(s, o) {
- var i, u, _;
- if (39 !== (i = s.input.charCodeAt(s.position))) return !1;
- for (
- s.kind = 'scalar', s.result = '', s.position++, u = _ = s.position;
- 0 !== (i = s.input.charCodeAt(s.position));
- )
- if (39 === i) {
- if (
- (captureSegment(s, u, s.position, !0),
- 39 !== (i = s.input.charCodeAt(++s.position)))
- )
- return !0;
- (u = s.position), s.position++, (_ = s.position);
- } else
- is_EOL(i)
- ? (captureSegment(s, u, _, !0),
- writeFoldedLines(s, skipSeparationSpace(s, !1, o)),
- (u = _ = s.position))
- : s.position === s.lineStart && testDocumentSeparator(s)
- ? throwError(
- s,
- 'unexpected end of the document within a single quoted scalar'
- )
- : (s.position++, (_ = s.position));
- throwError(s, 'unexpected end of the stream within a single quoted scalar');
- })(s, V) ||
- (function readDoubleQuotedScalar(s, o) {
- var i, u, _, w, x, C, j;
- if (34 !== (C = s.input.charCodeAt(s.position))) return !1;
- for (
- s.kind = 'scalar', s.result = '', s.position++, i = u = s.position;
- 0 !== (C = s.input.charCodeAt(s.position));
- ) {
- if (34 === C) return captureSegment(s, i, s.position, !0), s.position++, !0;
- if (92 === C) {
- if (
- (captureSegment(s, i, s.position, !0),
- is_EOL((C = s.input.charCodeAt(++s.position))))
- )
- skipSeparationSpace(s, !1, o);
- else if (C < 256 && Vr[C]) (s.result += Ur[C]), s.position++;
- else if (
- (x = 120 === (j = C) ? 2 : 117 === j ? 4 : 85 === j ? 8 : 0) > 0
- ) {
- for (_ = x, w = 0; _ > 0; _--)
- (x = fromHexCode((C = s.input.charCodeAt(++s.position)))) >= 0
- ? (w = (w << 4) + x)
- : throwError(s, 'expected hexadecimal character');
- (s.result += charFromCodepoint(w)), s.position++;
- } else throwError(s, 'unknown escape sequence');
- i = u = s.position;
- } else
- is_EOL(C)
- ? (captureSegment(s, i, u, !0),
- writeFoldedLines(s, skipSeparationSpace(s, !1, o)),
- (i = u = s.position))
- : s.position === s.lineStart && testDocumentSeparator(s)
- ? throwError(
- s,
- 'unexpected end of the document within a double quoted scalar'
- )
- : (s.position++, (u = s.position));
- }
- throwError(s, 'unexpected end of the stream within a double quoted scalar');
- })(s, V)
- ? (Z = !0)
- : !(function readAlias(s) {
- var o, i, u;
- if (42 !== (u = s.input.charCodeAt(s.position))) return !1;
- for (
- u = s.input.charCodeAt(++s.position), o = s.position;
- 0 !== u && !is_WS_OR_EOL(u) && !is_FLOW_INDICATOR(u);
- )
- u = s.input.charCodeAt(++s.position);
- return (
- s.position === o &&
- throwError(
- s,
- 'name of an alias node must contain at least one character'
- ),
- (i = s.input.slice(o, s.position)),
- Dr.call(s.anchorMap, i) ||
- throwError(s, 'unidentified alias "' + i + '"'),
- (s.result = s.anchorMap[i]),
- skipSeparationSpace(s, !0, -1),
- !0
- );
- })(s)
- ? (function readPlainScalar(s, o, i) {
- var u,
- _,
- w,
- x,
- C,
- j,
- L,
- B,
- $ = s.kind,
- V = s.result;
- if (
- is_WS_OR_EOL((B = s.input.charCodeAt(s.position))) ||
- is_FLOW_INDICATOR(B) ||
- 35 === B ||
- 38 === B ||
- 42 === B ||
- 33 === B ||
- 124 === B ||
- 62 === B ||
- 39 === B ||
- 34 === B ||
- 37 === B ||
- 64 === B ||
- 96 === B
- )
- return !1;
- if (
- (63 === B || 45 === B) &&
- (is_WS_OR_EOL((u = s.input.charCodeAt(s.position + 1))) ||
- (i && is_FLOW_INDICATOR(u)))
- )
- return !1;
- for (
- s.kind = 'scalar', s.result = '', _ = w = s.position, x = !1;
- 0 !== B;
- ) {
- if (58 === B) {
- if (
- is_WS_OR_EOL((u = s.input.charCodeAt(s.position + 1))) ||
- (i && is_FLOW_INDICATOR(u))
- )
- break;
- } else if (35 === B) {
- if (is_WS_OR_EOL(s.input.charCodeAt(s.position - 1))) break;
- } else {
- if (
- (s.position === s.lineStart && testDocumentSeparator(s)) ||
- (i && is_FLOW_INDICATOR(B))
- )
- break;
- if (is_EOL(B)) {
- if (
- ((C = s.line),
- (j = s.lineStart),
- (L = s.lineIndent),
- skipSeparationSpace(s, !1, -1),
- s.lineIndent >= o)
- ) {
- (x = !0), (B = s.input.charCodeAt(s.position));
- continue;
- }
- (s.position = w),
- (s.line = C),
- (s.lineStart = j),
- (s.lineIndent = L);
- break;
- }
- }
- x &&
- (captureSegment(s, _, w, !1),
- writeFoldedLines(s, s.line - C),
- (_ = w = s.position),
- (x = !1)),
- is_WHITE_SPACE(B) || (w = s.position + 1),
- (B = s.input.charCodeAt(++s.position));
- }
- return (
- captureSegment(s, _, w, !1),
- !!s.result || ((s.kind = $), (s.result = V), !1)
- );
- })(s, V, 1 === i) && ((Z = !0), null === s.tag && (s.tag = '?'))
- : ((Z = !0),
- (null === s.tag && null === s.anchor) ||
- throwError(s, 'alias node should not have any properties')),
- null !== s.anchor && (s.anchorMap[s.anchor] = s.result))
- : 0 === z && (Z = C && readBlockSequence(s, U))),
- null === s.tag)
- )
- null !== s.anchor && (s.anchorMap[s.anchor] = s.result);
- else if ('?' === s.tag) {
- for (
- null !== s.result &&
- 'scalar' !== s.kind &&
- throwError(
- s,
- 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + s.kind + '"'
- ),
- j = 0,
- L = s.implicitTypes.length;
- j < L;
- j += 1
- )
- if (($ = s.implicitTypes[j]).resolve(s.result)) {
- (s.result = $.construct(s.result)),
- (s.tag = $.tag),
- null !== s.anchor && (s.anchorMap[s.anchor] = s.result);
- break;
- }
- } else if ('!' !== s.tag) {
- if (Dr.call(s.typeMap[s.kind || 'fallback'], s.tag))
- $ = s.typeMap[s.kind || 'fallback'][s.tag];
- else
- for (
- $ = null, j = 0, L = (B = s.typeMap.multi[s.kind || 'fallback']).length;
- j < L;
- j += 1
- )
- if (s.tag.slice(0, B[j].tag.length) === B[j].tag) {
- $ = B[j];
- break;
- }
- $ || throwError(s, 'unknown tag !<' + s.tag + '>'),
- null !== s.result &&
- $.kind !== s.kind &&
- throwError(
- s,
- 'unacceptable node kind for !<' +
- s.tag +
- '> tag; it should be "' +
- $.kind +
- '", not "' +
- s.kind +
- '"'
- ),
- $.resolve(s.result, s.tag)
- ? ((s.result = $.construct(s.result, s.tag)),
- null !== s.anchor && (s.anchorMap[s.anchor] = s.result))
- : throwError(s, 'cannot resolve a node with !<' + s.tag + '> explicit tag');
- }
- return (
- null !== s.listener && s.listener('close', s), null !== s.tag || null !== s.anchor || Z
- );
- }
- function readDocument(s) {
- var o,
- i,
- u,
- _,
- w = s.position,
- x = !1;
- for (
- s.version = null,
- s.checkLineBreaks = s.legacy,
- s.tagMap = Object.create(null),
- s.anchorMap = Object.create(null);
- 0 !== (_ = s.input.charCodeAt(s.position)) &&
- (skipSeparationSpace(s, !0, -1),
- (_ = s.input.charCodeAt(s.position)),
- !(s.lineIndent > 0 || 37 !== _));
- ) {
- for (
- x = !0, _ = s.input.charCodeAt(++s.position), o = s.position;
- 0 !== _ && !is_WS_OR_EOL(_);
- )
- _ = s.input.charCodeAt(++s.position);
- for (
- u = [],
- (i = s.input.slice(o, s.position)).length < 1 &&
- throwError(s, 'directive name must not be less than one character in length');
- 0 !== _;
- ) {
- for (; is_WHITE_SPACE(_); ) _ = s.input.charCodeAt(++s.position);
- if (35 === _) {
- do {
- _ = s.input.charCodeAt(++s.position);
- } while (0 !== _ && !is_EOL(_));
- break;
- }
- if (is_EOL(_)) break;
- for (o = s.position; 0 !== _ && !is_WS_OR_EOL(_); )
- _ = s.input.charCodeAt(++s.position);
- u.push(s.input.slice(o, s.position));
- }
- 0 !== _ && readLineBreak(s),
- Dr.call(Wr, i)
- ? Wr[i](s, i, u)
- : throwWarning(s, 'unknown document directive "' + i + '"');
- }
- skipSeparationSpace(s, !0, -1),
- 0 === s.lineIndent &&
- 45 === s.input.charCodeAt(s.position) &&
- 45 === s.input.charCodeAt(s.position + 1) &&
- 45 === s.input.charCodeAt(s.position + 2)
- ? ((s.position += 3), skipSeparationSpace(s, !0, -1))
- : x && throwError(s, 'directives end mark is expected'),
- composeNode(s, s.lineIndent - 1, 4, !1, !0),
- skipSeparationSpace(s, !0, -1),
- s.checkLineBreaks &&
- Br.test(s.input.slice(w, s.position)) &&
- throwWarning(s, 'non-ASCII line breaks are interpreted as content'),
- s.documents.push(s.result),
- s.position === s.lineStart && testDocumentSeparator(s)
- ? 46 === s.input.charCodeAt(s.position) &&
- ((s.position += 3), skipSeparationSpace(s, !0, -1))
- : s.position < s.length - 1 &&
- throwError(s, 'end of the stream or a document separator is expected');
- }
- function loadDocuments(s, o) {
- (o = o || {}),
- 0 !== (s = String(s)).length &&
- (10 !== s.charCodeAt(s.length - 1) &&
- 13 !== s.charCodeAt(s.length - 1) &&
- (s += '\n'),
- 65279 === s.charCodeAt(0) && (s = s.slice(1)));
- var i = new State$1(s, o),
- u = s.indexOf('\0');
- for (
- -1 !== u && ((i.position = u), throwError(i, 'null byte is not allowed in input')),
- i.input += '\0';
- 32 === i.input.charCodeAt(i.position);
- )
- (i.lineIndent += 1), (i.position += 1);
- for (; i.position < i.length - 1; ) readDocument(i);
- return i.documents;
- }
- var Kr = {
- loadAll: function loadAll$1(s, o, i) {
- null !== o && 'object' == typeof o && void 0 === i && ((i = o), (o = null));
- var u = loadDocuments(s, i);
- if ('function' != typeof o) return u;
- for (var _ = 0, w = u.length; _ < w; _ += 1) o(u[_]);
- },
- load: function load$1(s, o) {
- var i = loadDocuments(s, o);
- if (0 !== i.length) {
- if (1 === i.length) return i[0];
- throw new rr('expected a single document in the stream, but found more');
- }
- }
- },
- Hr = Object.prototype.toString,
- Jr = Object.prototype.hasOwnProperty,
- Gr = 65279,
- Yr = {
- 0: '\\0',
- 7: '\\a',
- 8: '\\b',
- 9: '\\t',
- 10: '\\n',
- 11: '\\v',
- 12: '\\f',
- 13: '\\r',
- 27: '\\e',
- 34: '\\"',
- 92: '\\\\',
- 133: '\\N',
- 160: '\\_',
- 8232: '\\L',
- 8233: '\\P'
- },
- Xr = [
- 'y',
- 'Y',
- 'yes',
- 'Yes',
- 'YES',
- 'on',
- 'On',
- 'ON',
- 'n',
- 'N',
- 'no',
- 'No',
- 'NO',
- 'off',
- 'Off',
- 'OFF'
- ],
- Zr = /^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;
- function encodeHex(s) {
- var o, i, u;
- if (((o = s.toString(16).toUpperCase()), s <= 255)) (i = 'x'), (u = 2);
- else if (s <= 65535) (i = 'u'), (u = 4);
- else {
- if (!(s <= 4294967295))
- throw new rr('code point within a string may not be greater than 0xFFFFFFFF');
- (i = 'U'), (u = 8);
- }
- return '\\' + i + tr.repeat('0', u - o.length) + o;
- }
- function State(s) {
- (this.schema = s.schema || Rr),
- (this.indent = Math.max(1, s.indent || 2)),
- (this.noArrayIndent = s.noArrayIndent || !1),
- (this.skipInvalid = s.skipInvalid || !1),
- (this.flowLevel = tr.isNothing(s.flowLevel) ? -1 : s.flowLevel),
- (this.styleMap = (function compileStyleMap(s, o) {
- var i, u, _, w, x, C, j;
- if (null === o) return {};
- for (i = {}, _ = 0, w = (u = Object.keys(o)).length; _ < w; _ += 1)
- (x = u[_]),
- (C = String(o[x])),
- '!!' === x.slice(0, 2) && (x = 'tag:yaml.org,2002:' + x.slice(2)),
- (j = s.compiledTypeMap.fallback[x]) &&
- Jr.call(j.styleAliases, C) &&
- (C = j.styleAliases[C]),
- (i[x] = C);
- return i;
- })(this.schema, s.styles || null)),
- (this.sortKeys = s.sortKeys || !1),
- (this.lineWidth = s.lineWidth || 80),
- (this.noRefs = s.noRefs || !1),
- (this.noCompatMode = s.noCompatMode || !1),
- (this.condenseFlow = s.condenseFlow || !1),
- (this.quotingType = '"' === s.quotingType ? 2 : 1),
- (this.forceQuotes = s.forceQuotes || !1),
- (this.replacer = 'function' == typeof s.replacer ? s.replacer : null),
- (this.implicitTypes = this.schema.compiledImplicit),
- (this.explicitTypes = this.schema.compiledExplicit),
- (this.tag = null),
- (this.result = ''),
- (this.duplicates = []),
- (this.usedDuplicates = null);
- }
- function indentString(s, o) {
- for (var i, u = tr.repeat(' ', o), _ = 0, w = -1, x = '', C = s.length; _ < C; )
- -1 === (w = s.indexOf('\n', _))
- ? ((i = s.slice(_)), (_ = C))
- : ((i = s.slice(_, w + 1)), (_ = w + 1)),
- i.length && '\n' !== i && (x += u),
- (x += i);
- return x;
- }
- function generateNextLine(s, o) {
- return '\n' + tr.repeat(' ', s.indent * o);
- }
- function isWhitespace(s) {
- return 32 === s || 9 === s;
- }
- function isPrintable(s) {
- return (
- (32 <= s && s <= 126) ||
- (161 <= s && s <= 55295 && 8232 !== s && 8233 !== s) ||
- (57344 <= s && s <= 65533 && s !== Gr) ||
- (65536 <= s && s <= 1114111)
- );
- }
- function isNsCharOrWhitespace(s) {
- return isPrintable(s) && s !== Gr && 13 !== s && 10 !== s;
- }
- function isPlainSafe(s, o, i) {
- var u = isNsCharOrWhitespace(s),
- _ = u && !isWhitespace(s);
- return (
- ((i ? u : u && 44 !== s && 91 !== s && 93 !== s && 123 !== s && 125 !== s) &&
- 35 !== s &&
- !(58 === o && !_)) ||
- (isNsCharOrWhitespace(o) && !isWhitespace(o) && 35 === s) ||
- (58 === o && _)
- );
- }
- function codePointAt(s, o) {
- var i,
- u = s.charCodeAt(o);
- return u >= 55296 &&
- u <= 56319 &&
- o + 1 < s.length &&
- (i = s.charCodeAt(o + 1)) >= 56320 &&
- i <= 57343
- ? 1024 * (u - 55296) + i - 56320 + 65536
- : u;
- }
- function needIndentIndicator(s) {
- return /^\n* /.test(s);
- }
- function chooseScalarStyle(s, o, i, u, _, w, x, C) {
- var j,
- L = 0,
- B = null,
- $ = !1,
- V = !1,
- U = -1 !== u,
- z = -1,
- Y =
- (function isPlainSafeFirst(s) {
- return (
- isPrintable(s) &&
- s !== Gr &&
- !isWhitespace(s) &&
- 45 !== s &&
- 63 !== s &&
- 58 !== s &&
- 44 !== s &&
- 91 !== s &&
- 93 !== s &&
- 123 !== s &&
- 125 !== s &&
- 35 !== s &&
- 38 !== s &&
- 42 !== s &&
- 33 !== s &&
- 124 !== s &&
- 61 !== s &&
- 62 !== s &&
- 39 !== s &&
- 34 !== s &&
- 37 !== s &&
- 64 !== s &&
- 96 !== s
- );
- })(codePointAt(s, 0)) &&
- (function isPlainSafeLast(s) {
- return !isWhitespace(s) && 58 !== s;
- })(codePointAt(s, s.length - 1));
- if (o || x)
- for (j = 0; j < s.length; L >= 65536 ? (j += 2) : j++) {
- if (!isPrintable((L = codePointAt(s, j)))) return 5;
- (Y = Y && isPlainSafe(L, B, C)), (B = L);
- }
- else {
- for (j = 0; j < s.length; L >= 65536 ? (j += 2) : j++) {
- if (10 === (L = codePointAt(s, j)))
- ($ = !0), U && ((V = V || (j - z - 1 > u && ' ' !== s[z + 1])), (z = j));
- else if (!isPrintable(L)) return 5;
- (Y = Y && isPlainSafe(L, B, C)), (B = L);
- }
- V = V || (U && j - z - 1 > u && ' ' !== s[z + 1]);
- }
- return $ || V
- ? i > 9 && needIndentIndicator(s)
- ? 5
- : x
- ? 2 === w
- ? 5
- : 2
- : V
- ? 4
- : 3
- : !Y || x || _(s)
- ? 2 === w
- ? 5
- : 2
- : 1;
- }
- function writeScalar(s, o, i, u, _) {
- s.dump = (function () {
- if (0 === o.length) return 2 === s.quotingType ? '""' : "''";
- if (!s.noCompatMode && (-1 !== Xr.indexOf(o) || Zr.test(o)))
- return 2 === s.quotingType ? '"' + o + '"' : "'" + o + "'";
- var w = s.indent * Math.max(1, i),
- x = -1 === s.lineWidth ? -1 : Math.max(Math.min(s.lineWidth, 40), s.lineWidth - w),
- C = u || (s.flowLevel > -1 && i >= s.flowLevel);
- switch (
- chooseScalarStyle(
- o,
- C,
- s.indent,
- x,
- function testAmbiguity(o) {
- return (function testImplicitResolving(s, o) {
- var i, u;
- for (i = 0, u = s.implicitTypes.length; i < u; i += 1)
- if (s.implicitTypes[i].resolve(o)) return !0;
- return !1;
- })(s, o);
- },
- s.quotingType,
- s.forceQuotes && !u,
- _
- )
- ) {
- case 1:
- return o;
- case 2:
- return "'" + o.replace(/'/g, "''") + "'";
- case 3:
- return '|' + blockHeader(o, s.indent) + dropEndingNewline(indentString(o, w));
- case 4:
- return (
- '>' +
- blockHeader(o, s.indent) +
- dropEndingNewline(
- indentString(
- (function foldString(s, o) {
- var i,
- u,
- _ = /(\n+)([^\n]*)/g,
- w =
- ((C = s.indexOf('\n')),
- (C = -1 !== C ? C : s.length),
- (_.lastIndex = C),
- foldLine(s.slice(0, C), o)),
- x = '\n' === s[0] || ' ' === s[0];
- var C;
- for (; (u = _.exec(s)); ) {
- var j = u[1],
- L = u[2];
- (i = ' ' === L[0]),
- (w += j + (x || i || '' === L ? '' : '\n') + foldLine(L, o)),
- (x = i);
- }
- return w;
- })(o, x),
- w
- )
- )
- );
- case 5:
- return (
- '"' +
- (function escapeString(s) {
- for (var o, i = '', u = 0, _ = 0; _ < s.length; u >= 65536 ? (_ += 2) : _++)
- (u = codePointAt(s, _)),
- !(o = Yr[u]) && isPrintable(u)
- ? ((i += s[_]), u >= 65536 && (i += s[_ + 1]))
- : (i += o || encodeHex(u));
- return i;
- })(o) +
- '"'
- );
- default:
- throw new rr('impossible error: invalid scalar style');
- }
- })();
- }
- function blockHeader(s, o) {
- var i = needIndentIndicator(s) ? String(o) : '',
- u = '\n' === s[s.length - 1];
- return i + (u && ('\n' === s[s.length - 2] || '\n' === s) ? '+' : u ? '' : '-') + '\n';
- }
- function dropEndingNewline(s) {
- return '\n' === s[s.length - 1] ? s.slice(0, -1) : s;
- }
- function foldLine(s, o) {
- if ('' === s || ' ' === s[0]) return s;
- for (var i, u, _ = / [^ ]/g, w = 0, x = 0, C = 0, j = ''; (i = _.exec(s)); )
- (C = i.index) - w > o &&
- ((u = x > w ? x : C), (j += '\n' + s.slice(w, u)), (w = u + 1)),
- (x = C);
- return (
- (j += '\n'),
- s.length - w > o && x > w
- ? (j += s.slice(w, x) + '\n' + s.slice(x + 1))
- : (j += s.slice(w)),
- j.slice(1)
- );
- }
- function writeBlockSequence(s, o, i, u) {
- var _,
- w,
- x,
- C = '',
- j = s.tag;
- for (_ = 0, w = i.length; _ < w; _ += 1)
- (x = i[_]),
- s.replacer && (x = s.replacer.call(i, String(_), x)),
- (writeNode(s, o + 1, x, !0, !0, !1, !0) ||
- (void 0 === x && writeNode(s, o + 1, null, !0, !0, !1, !0))) &&
- ((u && '' === C) || (C += generateNextLine(s, o)),
- s.dump && 10 === s.dump.charCodeAt(0) ? (C += '-') : (C += '- '),
- (C += s.dump));
- (s.tag = j), (s.dump = C || '[]');
- }
- function detectType(s, o, i) {
- var u, _, w, x, C, j;
- for (w = 0, x = (_ = i ? s.explicitTypes : s.implicitTypes).length; w < x; w += 1)
- if (
- ((C = _[w]).instanceOf || C.predicate) &&
- (!C.instanceOf || ('object' == typeof o && o instanceof C.instanceOf)) &&
- (!C.predicate || C.predicate(o))
- ) {
- if (
- (i
- ? C.multi && C.representName
- ? (s.tag = C.representName(o))
- : (s.tag = C.tag)
- : (s.tag = '?'),
- C.represent)
- ) {
- if (
- ((j = s.styleMap[C.tag] || C.defaultStyle),
- '[object Function]' === Hr.call(C.represent))
- )
- u = C.represent(o, j);
- else {
- if (!Jr.call(C.represent, j))
- throw new rr('!<' + C.tag + '> tag resolver accepts not "' + j + '" style');
- u = C.represent[j](o, j);
- }
- s.dump = u;
- }
- return !0;
- }
- return !1;
- }
- function writeNode(s, o, i, u, _, w, x) {
- (s.tag = null), (s.dump = i), detectType(s, i, !1) || detectType(s, i, !0);
- var C,
- j = Hr.call(s.dump),
- L = u;
- u && (u = s.flowLevel < 0 || s.flowLevel > o);
- var B,
- $,
- V = '[object Object]' === j || '[object Array]' === j;
- if (
- (V && ($ = -1 !== (B = s.duplicates.indexOf(i))),
- ((null !== s.tag && '?' !== s.tag) || $ || (2 !== s.indent && o > 0)) && (_ = !1),
- $ && s.usedDuplicates[B])
- )
- s.dump = '*ref_' + B;
- else {
- if (
- (V && $ && !s.usedDuplicates[B] && (s.usedDuplicates[B] = !0),
- '[object Object]' === j)
- )
- u && 0 !== Object.keys(s.dump).length
- ? (!(function writeBlockMapping(s, o, i, u) {
- var _,
- w,
- x,
- C,
- j,
- L,
- B = '',
- $ = s.tag,
- V = Object.keys(i);
- if (!0 === s.sortKeys) V.sort();
- else if ('function' == typeof s.sortKeys) V.sort(s.sortKeys);
- else if (s.sortKeys) throw new rr('sortKeys must be a boolean or a function');
- for (_ = 0, w = V.length; _ < w; _ += 1)
- (L = ''),
- (u && '' === B) || (L += generateNextLine(s, o)),
- (C = i[(x = V[_])]),
- s.replacer && (C = s.replacer.call(i, x, C)),
- writeNode(s, o + 1, x, !0, !0, !0) &&
- ((j =
- (null !== s.tag && '?' !== s.tag) ||
- (s.dump && s.dump.length > 1024)) &&
- (s.dump && 10 === s.dump.charCodeAt(0) ? (L += '?') : (L += '? ')),
- (L += s.dump),
- j && (L += generateNextLine(s, o)),
- writeNode(s, o + 1, C, !0, j) &&
- (s.dump && 10 === s.dump.charCodeAt(0) ? (L += ':') : (L += ': '),
- (B += L += s.dump)));
- (s.tag = $), (s.dump = B || '{}');
- })(s, o, s.dump, _),
- $ && (s.dump = '&ref_' + B + s.dump))
- : (!(function writeFlowMapping(s, o, i) {
- var u,
- _,
- w,
- x,
- C,
- j = '',
- L = s.tag,
- B = Object.keys(i);
- for (u = 0, _ = B.length; u < _; u += 1)
- (C = ''),
- '' !== j && (C += ', '),
- s.condenseFlow && (C += '"'),
- (x = i[(w = B[u])]),
- s.replacer && (x = s.replacer.call(i, w, x)),
- writeNode(s, o, w, !1, !1) &&
- (s.dump.length > 1024 && (C += '? '),
- (C +=
- s.dump +
- (s.condenseFlow ? '"' : '') +
- ':' +
- (s.condenseFlow ? '' : ' ')),
- writeNode(s, o, x, !1, !1) && (j += C += s.dump));
- (s.tag = L), (s.dump = '{' + j + '}');
- })(s, o, s.dump),
- $ && (s.dump = '&ref_' + B + ' ' + s.dump));
- else if ('[object Array]' === j)
- u && 0 !== s.dump.length
- ? (s.noArrayIndent && !x && o > 0
- ? writeBlockSequence(s, o - 1, s.dump, _)
- : writeBlockSequence(s, o, s.dump, _),
- $ && (s.dump = '&ref_' + B + s.dump))
- : (!(function writeFlowSequence(s, o, i) {
- var u,
- _,
- w,
- x = '',
- C = s.tag;
- for (u = 0, _ = i.length; u < _; u += 1)
- (w = i[u]),
- s.replacer && (w = s.replacer.call(i, String(u), w)),
- (writeNode(s, o, w, !1, !1) ||
- (void 0 === w && writeNode(s, o, null, !1, !1))) &&
- ('' !== x && (x += ',' + (s.condenseFlow ? '' : ' ')), (x += s.dump));
- (s.tag = C), (s.dump = '[' + x + ']');
- })(s, o, s.dump),
- $ && (s.dump = '&ref_' + B + ' ' + s.dump));
- else {
- if ('[object String]' !== j) {
- if ('[object Undefined]' === j) return !1;
- if (s.skipInvalid) return !1;
- throw new rr('unacceptable kind of an object to dump ' + j);
- }
- '?' !== s.tag && writeScalar(s, s.dump, o, w, L);
- }
- null !== s.tag &&
- '?' !== s.tag &&
- ((C = encodeURI('!' === s.tag[0] ? s.tag.slice(1) : s.tag).replace(/!/g, '%21')),
- (C =
- '!' === s.tag[0]
- ? '!' + C
- : 'tag:yaml.org,2002:' === C.slice(0, 18)
- ? '!!' + C.slice(18)
- : '!<' + C + '>'),
- (s.dump = C + ' ' + s.dump));
- }
- return !0;
- }
- function getDuplicateReferences(s, o) {
- var i,
- u,
- _ = [],
- w = [];
- for (inspectNode(s, _, w), i = 0, u = w.length; i < u; i += 1) o.duplicates.push(_[w[i]]);
- o.usedDuplicates = new Array(u);
- }
- function inspectNode(s, o, i) {
- var u, _, w;
- if (null !== s && 'object' == typeof s)
- if (-1 !== (_ = o.indexOf(s))) -1 === i.indexOf(_) && i.push(_);
- else if ((o.push(s), Array.isArray(s)))
- for (_ = 0, w = s.length; _ < w; _ += 1) inspectNode(s[_], o, i);
- else
- for (_ = 0, w = (u = Object.keys(s)).length; _ < w; _ += 1)
- inspectNode(s[u[_]], o, i);
- }
- var Qr = function dump$1(s, o) {
- var i = new State((o = o || {}));
- i.noRefs || getDuplicateReferences(s, i);
- var u = s;
- return (
- i.replacer && (u = i.replacer.call({ '': u }, '', u)),
- writeNode(i, 0, u, !0, !0) ? i.dump + '\n' : ''
- );
- };
- function renamed(s, o) {
- return function () {
- throw new Error(
- 'Function yaml.' +
- s +
- ' is removed in js-yaml 4. Use yaml.' +
- o +
- ' instead, which is now safe by default.'
- );
- };
- }
- var en = ar,
- tn = lr,
- rn = dr,
- nn = _r,
- sn = Er,
- on = Rr,
- an = Kr.load,
- ln = Kr.loadAll,
- cn = { dump: Qr }.dump,
- un = rr,
- pn = {
- binary: Or,
- float: br,
- map: pr,
- null: fr,
- pairs: Mr,
- set: Nr,
- timestamp: xr,
- bool: mr,
- int: gr,
- merge: kr,
- omap: Ir,
- seq: ur,
- str: cr
- },
- hn = renamed('safeLoad', 'load'),
- dn = renamed('safeLoadAll', 'loadAll'),
- fn = renamed('safeDump', 'dump');
- const mn = {
- Type: en,
- Schema: tn,
- FAILSAFE_SCHEMA: rn,
- JSON_SCHEMA: nn,
- CORE_SCHEMA: sn,
- DEFAULT_SCHEMA: on,
- load: an,
- loadAll: ln,
- dump: cn,
- YAMLException: un,
- types: pn,
- safeLoad: hn,
- safeLoadAll: dn,
- safeDump: fn
- },
- gn = 'configs_update',
- yn = 'configs_toggle';
- function update(s, o) {
- return { type: gn, payload: { [s]: o } };
- }
- function toggle(s) {
- return { type: yn, payload: s };
- }
- const actions_loaded = () => () => {},
- downloadConfig = (s) => (o) => {
- const {
- fn: { fetch: i }
- } = o;
- return i(s);
- },
- getConfigByUrl = (s, o) => (i) => {
- const { specActions: u, configsActions: _ } = i;
- if (s) return _.downloadConfig(s).then(next, next);
- function next(_) {
- _ instanceof Error || _.status >= 400
- ? (u.updateLoadingStatus('failedConfig'),
- u.updateLoadingStatus('failedConfig'),
- u.updateUrl(''),
- console.error(_.statusText + ' ' + s.url),
- o(null))
- : o(
- ((s, o) => {
- try {
- return mn.load(s);
- } catch (s) {
- return o && o.errActions.newThrownErr(new Error(s)), {};
- }
- })(_.text, i)
- );
- }
- },
- get = (s, o) => s.getIn(Array.isArray(o) ? o : [o]),
- vn = {
- [gn]: (s, o) => s.merge((0, qe.fromJS)(o.payload)),
- [yn]: (s, o) => {
- const i = o.payload,
- u = s.get(i);
- return s.set(i, !u);
- }
- };
- function configsPlugin() {
- return { statePlugins: { configs: { reducers: vn, actions: u, selectors: w } } };
- }
- const setHash = (s) =>
- s ? history.pushState(null, null, `#${s}`) : (window.location.hash = '');
- var bn = __webpack_require__(86215),
- _n = __webpack_require__.n(bn);
- const En = 'layout_scroll_to',
- wn = 'layout_clear_scroll';
- const Sn = {
- fn: {
- getScrollParent: function getScrollParent(s, o) {
- const i = document.documentElement;
- let u = getComputedStyle(s);
- const _ = 'absolute' === u.position,
- w = o ? /(auto|scroll|hidden)/ : /(auto|scroll)/;
- if ('fixed' === u.position) return i;
- for (let o = s; (o = o.parentElement); )
- if (
- ((u = getComputedStyle(o)),
- (!_ || 'static' !== u.position) && w.test(u.overflow + u.overflowY + u.overflowX))
- )
- return o;
- return i;
- }
- },
- statePlugins: {
- layout: {
- actions: {
- scrollToElement: (s, o) => (i) => {
- try {
- (o = o || i.fn.getScrollParent(s)), _n().createScroller(o).to(s);
- } catch (s) {
- console.error(s);
- }
- },
- scrollTo: (s) => ({ type: En, payload: Array.isArray(s) ? s : [s] }),
- clearScrollTo: () => ({ type: wn }),
- readyToScroll: (s, o) => (i) => {
- const u = i.layoutSelectors.getScrollToKey();
- $e().is(u, (0, qe.fromJS)(s)) &&
- (i.layoutActions.scrollToElement(o), i.layoutActions.clearScrollTo());
- },
- parseDeepLinkHash:
- (s) =>
- ({ layoutActions: o, layoutSelectors: i, getConfigs: u }) => {
- if (u().deepLinking && s) {
- let u = s.slice(1);
- '!' === u[0] && (u = u.slice(1)), '/' === u[0] && (u = u.slice(1));
- const _ = u.split('/').map((s) => s || ''),
- w = i.isShownKeyFromUrlHashArray(_),
- [x, C = '', j = ''] = w;
- if ('operations' === x) {
- const s = i.isShownKeyFromUrlHashArray([C]);
- C.indexOf('_') > -1 &&
- (console.warn(
- 'Warning: escaping deep link whitespace with `_` will be unsupported in v4.0, use `%20` instead.'
- ),
- o.show(
- s.map((s) => s.replace(/_/g, ' ')),
- !0
- )),
- o.show(s, !0);
- }
- (C.indexOf('_') > -1 || j.indexOf('_') > -1) &&
- (console.warn(
- 'Warning: escaping deep link whitespace with `_` will be unsupported in v4.0, use `%20` instead.'
- ),
- o.show(
- w.map((s) => s.replace(/_/g, ' ')),
- !0
- )),
- o.show(w, !0),
- o.scrollTo(w);
- }
- }
- },
- selectors: {
- getScrollToKey: (s) => s.get('scrollToKey'),
- isShownKeyFromUrlHashArray(s, o) {
- const [i, u] = o;
- return u ? ['operations', i, u] : i ? ['operations-tag', i] : [];
- },
- urlHashArrayFromIsShownKey(s, o) {
- let [i, u, _] = o;
- return 'operations' == i ? [u, _] : 'operations-tag' == i ? [u] : [];
- }
- },
- reducers: {
- [En]: (s, o) => s.set('scrollToKey', $e().fromJS(o.payload)),
- [wn]: (s) => s.delete('scrollToKey')
- },
- wrapActions: {
- show:
- (s, { getConfigs: o, layoutSelectors: i }) =>
- (...u) => {
- if ((s(...u), o().deepLinking))
- try {
- let [s, o] = u;
- s = Array.isArray(s) ? s : [s];
- const _ = i.urlHashArrayFromIsShownKey(s);
- if (!_.length) return;
- const [w, x] = _;
- if (!o) return setHash('/');
- 2 === _.length
- ? setHash(
- createDeepLinkPath(
- `/${encodeURIComponent(w)}/${encodeURIComponent(x)}`
- )
- )
- : 1 === _.length &&
- setHash(createDeepLinkPath(`/${encodeURIComponent(w)}`));
- } catch (s) {
- console.error(s);
- }
- }
- }
- }
- }
- };
- var xn = __webpack_require__(2209),
- kn = __webpack_require__.n(xn);
- const operation_wrapper = (s, o) =>
- class OperationWrapper extends Pe.Component {
- onLoad = (s) => {
- const { operation: i } = this.props,
- { tag: u, operationId: _ } = i.toObject();
- let { isShownKey: w } = i.toObject();
- (w = w || ['operations', u, _]), o.layoutActions.readyToScroll(w, s);
- };
- render() {
- return Pe.createElement(
- 'span',
- { ref: this.onLoad },
- Pe.createElement(s, this.props)
- );
- }
- },
- operation_tag_wrapper = (s, o) =>
- class OperationTagWrapper extends Pe.Component {
- onLoad = (s) => {
- const { tag: i } = this.props,
- u = ['operations-tag', i];
- o.layoutActions.readyToScroll(u, s);
- };
- render() {
- return Pe.createElement(
- 'span',
- { ref: this.onLoad },
- Pe.createElement(s, this.props)
- );
- }
- };
- function deep_linking() {
- return [
- Sn,
- {
- statePlugins: {
- configs: {
- wrapActions: {
- loaded:
- (s, o) =>
- (...i) => {
- s(...i);
- const u = decodeURIComponent(window.location.hash);
- o.layoutActions.parseDeepLinkHash(u);
- }
- }
- }
- },
- wrapComponents: { operation: operation_wrapper, OperationTag: operation_tag_wrapper }
- }
- ];
- }
- var Cn = __webpack_require__(40860),
- On = __webpack_require__.n(Cn);
- function transform(s) {
- return s.map((s) => {
- let o = 'is not of a type(s)',
- i = s.get('message').indexOf(o);
- if (i > -1) {
- let o = s
- .get('message')
- .slice(i + 19)
- .split(',');
- return s.set(
- 'message',
- s.get('message').slice(0, i) +
- (function makeNewMessage(s) {
- return s.reduce(
- (s, o, i, u) =>
- i === u.length - 1 && u.length > 1
- ? s + 'or ' + o
- : u[i + 1] && u.length > 2
- ? s + o + ', '
- : u[i + 1]
- ? s + o + ' '
- : s + o,
- 'should be a'
- );
- })(o)
- );
- }
- return s;
- });
- }
- var An = __webpack_require__(58156),
- jn = __webpack_require__.n(An);
- function parameter_oneof_transform(s, { jsSpec: o }) {
- return s;
- }
- const In = [x, C];
- function transformErrors(s) {
- let o = { jsSpec: {} },
- i = On()(
- In,
- (s, i) => {
- try {
- return i.transform(s, o).filter((s) => !!s);
- } catch (o) {
- return console.error('Transformer error:', o), s;
- }
- },
- s
- );
- return i.filter((s) => !!s).map((s) => (!s.get('line') && s.get('path'), s));
- }
- let Pn = { line: 0, level: 'error', message: 'Unknown error' };
- const Mn = Ut(
- (s) => s,
- (s) => s.get('errors', (0, qe.List)())
- ),
- Tn = Ut(Mn, (s) => s.last());
- function err(o) {
- return {
- statePlugins: {
- err: {
- reducers: {
- [et]: (s, { payload: o }) => {
- let i = Object.assign(Pn, o, { type: 'thrown' });
- return s
- .update('errors', (s) => (s || (0, qe.List)()).push((0, qe.fromJS)(i)))
- .update('errors', (s) => transformErrors(s));
- },
- [tt]: (s, { payload: o }) => (
- (o = o.map((s) => (0, qe.fromJS)(Object.assign(Pn, s, { type: 'thrown' })))),
- s
- .update('errors', (s) => (s || (0, qe.List)()).concat((0, qe.fromJS)(o)))
- .update('errors', (s) => transformErrors(s))
- ),
- [rt]: (s, { payload: o }) => {
- let i = (0, qe.fromJS)(o);
- return (
- (i = i.set('type', 'spec')),
- s
- .update('errors', (s) =>
- (s || (0, qe.List)()).push((0, qe.fromJS)(i)).sortBy((s) => s.get('line'))
- )
- .update('errors', (s) => transformErrors(s))
- );
- },
- [nt]: (s, { payload: o }) => (
- (o = o.map((s) => (0, qe.fromJS)(Object.assign(Pn, s, { type: 'spec' })))),
- s
- .update('errors', (s) => (s || (0, qe.List)()).concat((0, qe.fromJS)(o)))
- .update('errors', (s) => transformErrors(s))
- ),
- [st]: (s, { payload: o }) => {
- let i = (0, qe.fromJS)(Object.assign({}, o));
- return (
- (i = i.set('type', 'auth')),
- s
- .update('errors', (s) => (s || (0, qe.List)()).push((0, qe.fromJS)(i)))
- .update('errors', (s) => transformErrors(s))
- );
- },
- [ot]: (s, { payload: o }) => {
- if (!o || !s.get('errors')) return s;
- let i = s.get('errors').filter((s) =>
- s.keySeq().every((i) => {
- const u = s.get(i),
- _ = o[i];
- return !_ || u !== _;
- })
- );
- return s.merge({ errors: i });
- },
- [it]: (s, { payload: o }) => {
- if (!o || 'function' != typeof o) return s;
- let i = s.get('errors').filter((s) => o(s));
- return s.merge({ errors: i });
- }
- },
- actions: s,
- selectors: j
- }
- }
- };
- }
- function opsFilter(s, o) {
- return s.filter((s, i) => -1 !== i.indexOf(o));
- }
- function filter() {
- return { fn: { opsFilter } };
- }
- var Nn = __webpack_require__(7666),
- Rn = __webpack_require__.n(Nn);
- const arrow_up = ({ className: s = null, width: o = 20, height: i = 20, ...u }) =>
- Pe.createElement(
- 'svg',
- Rn()(
- {
- xmlns: 'http://www.w3.org/2000/svg',
- viewBox: '0 0 20 20',
- className: s,
- width: o,
- height: i,
- 'aria-hidden': 'true',
- focusable: 'false'
- },
- u
- ),
- Pe.createElement('path', {
- d: 'M 17.418 14.908 C 17.69 15.176 18.127 15.176 18.397 14.908 C 18.667 14.64 18.668 14.207 18.397 13.939 L 10.489 6.109 C 10.219 5.841 9.782 5.841 9.51 6.109 L 1.602 13.939 C 1.332 14.207 1.332 14.64 1.602 14.908 C 1.873 15.176 2.311 15.176 2.581 14.908 L 10 7.767 L 17.418 14.908 Z'
- })
- ),
- arrow_down = ({ className: s = null, width: o = 20, height: i = 20, ...u }) =>
- Pe.createElement(
- 'svg',
- Rn()(
- {
- xmlns: 'http://www.w3.org/2000/svg',
- viewBox: '0 0 20 20',
- className: s,
- width: o,
- height: i,
- 'aria-hidden': 'true',
- focusable: 'false'
- },
- u
- ),
- Pe.createElement('path', {
- d: 'M17.418 6.109c.272-.268.709-.268.979 0s.271.701 0 .969l-7.908 7.83c-.27.268-.707.268-.979 0l-7.908-7.83c-.27-.268-.27-.701 0-.969.271-.268.709-.268.979 0L10 13.25l7.418-7.141z'
- })
- ),
- arrow = ({ className: s = null, width: o = 20, height: i = 20, ...u }) =>
- Pe.createElement(
- 'svg',
- Rn()(
- {
- xmlns: 'http://www.w3.org/2000/svg',
- viewBox: '0 0 20 20',
- className: s,
- width: o,
- height: i,
- 'aria-hidden': 'true',
- focusable: 'false'
- },
- u
- ),
- Pe.createElement('path', {
- d: 'M13.25 10L6.109 2.58c-.268-.27-.268-.707 0-.979.268-.27.701-.27.969 0l7.83 7.908c.268.271.268.709 0 .979l-7.83 7.908c-.268.271-.701.27-.969 0-.268-.269-.268-.707 0-.979L13.25 10z'
- })
- ),
- components_close = ({ className: s = null, width: o = 20, height: i = 20, ...u }) =>
- Pe.createElement(
- 'svg',
- Rn()(
- {
- xmlns: 'http://www.w3.org/2000/svg',
- viewBox: '0 0 20 20',
- className: s,
- width: o,
- height: i,
- 'aria-hidden': 'true',
- focusable: 'false'
- },
- u
- ),
- Pe.createElement('path', {
- d: 'M14.348 14.849c-.469.469-1.229.469-1.697 0L10 11.819l-2.651 3.029c-.469.469-1.229.469-1.697 0-.469-.469-.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-.469-.469-.469-1.228 0-1.697.469-.469 1.228-.469 1.697 0L10 8.183l2.651-3.031c.469-.469 1.228-.469 1.697 0 .469.469.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c.469.469.469 1.229 0 1.698z'
- })
- ),
- copy = ({ className: s = null, width: o = 15, height: i = 16, ...u }) =>
- Pe.createElement(
- 'svg',
- Rn()(
- {
- xmlns: 'http://www.w3.org/2000/svg',
- viewBox: '0 0 15 16',
- className: s,
- width: o,
- height: i,
- 'aria-hidden': 'true',
- focusable: 'false'
- },
- u
- ),
- Pe.createElement(
- 'g',
- { transform: 'translate(2, -1)' },
- Pe.createElement('path', {
- fill: '#ffffff',
- fillRule: 'evenodd',
- d: 'M2 13h4v1H2v-1zm5-6H2v1h5V7zm2 3V8l-3 3 3 3v-2h5v-2H9zM4.5 9H2v1h2.5V9zM2 12h2.5v-1H2v1zm9 1h1v2c-.02.28-.11.52-.3.7-.19.18-.42.28-.7.3H1c-.55 0-1-.45-1-1V4c0-.55.45-1 1-1h3c0-1.11.89-2 2-2 1.11 0 2 .89 2 2h3c.55 0 1 .45 1 1v5h-1V6H1v9h10v-2zM2 5h8c0-.55-.45-1-1-1H8c-.55 0-1-.45-1-1s-.45-1-1-1-1 .45-1 1-.45 1-1 1H3c-.55 0-1 .45-1 1z'
- })
- )
- ),
- lock = ({ className: s = null, width: o = 20, height: i = 20, ...u }) =>
- Pe.createElement(
- 'svg',
- Rn()(
- {
- xmlns: 'http://www.w3.org/2000/svg',
- viewBox: '0 0 20 20',
- className: s,
- width: o,
- height: i,
- 'aria-hidden': 'true',
- focusable: 'false'
- },
- u
- ),
- Pe.createElement('path', {
- d: 'M15.8 8H14V5.6C14 2.703 12.665 1 10 1 7.334 1 6 2.703 6 5.6V8H4c-.553 0-1 .646-1 1.199V17c0 .549.428 1.139.951 1.307l1.197.387C5.672 18.861 6.55 19 7.1 19h5.8c.549 0 1.428-.139 1.951-.307l1.196-.387c.524-.167.953-.757.953-1.306V9.199C17 8.646 16.352 8 15.8 8zM12 8H8V5.199C8 3.754 8.797 3 10 3c1.203 0 2 .754 2 2.199V8z'
- })
- ),
- unlock = ({ className: s = null, width: o = 20, height: i = 20, ...u }) =>
- Pe.createElement(
- 'svg',
- Rn()(
- {
- xmlns: 'http://www.w3.org/2000/svg',
- viewBox: '0 0 20 20',
- className: s,
- width: o,
- height: i,
- 'aria-hidden': 'true',
- focusable: 'false'
- },
- u
- ),
- Pe.createElement('path', {
- d: 'M15.8 8H14V5.6C14 2.703 12.665 1 10 1 7.334 1 6 2.703 6 5.6V6h2v-.801C8 3.754 8.797 3 10 3c1.203 0 2 .754 2 2.199V8H4c-.553 0-1 .646-1 1.199V17c0 .549.428 1.139.951 1.307l1.197.387C5.672 18.861 6.55 19 7.1 19h5.8c.549 0 1.428-.139 1.951-.307l1.196-.387c.524-.167.953-.757.953-1.306V9.199C17 8.646 16.352 8 15.8 8z'
- })
- ),
- icons = () => ({
- components: {
- ArrowUpIcon: arrow_up,
- ArrowDownIcon: arrow_down,
- ArrowIcon: arrow,
- CloseIcon: components_close,
- CopyIcon: copy,
- LockIcon: lock,
- UnlockIcon: unlock
- }
- }),
- Dn = 'layout_update_layout',
- Ln = 'layout_update_filter',
- Bn = 'layout_update_mode',
- Fn = 'layout_show';
- function updateLayout(s) {
- return { type: Dn, payload: s };
- }
- function updateFilter(s) {
- return { type: Ln, payload: s };
- }
- function actions_show(s, o = !0) {
- return (s = normalizeArray(s)), { type: Fn, payload: { thing: s, shown: o } };
- }
- function changeMode(s, o = '') {
- return (s = normalizeArray(s)), { type: Bn, payload: { thing: s, mode: o } };
- }
- const qn = {
- [Dn]: (s, o) => s.set('layout', o.payload),
- [Ln]: (s, o) => s.set('filter', o.payload),
- [Fn]: (s, o) => {
- const i = o.payload.shown,
- u = (0, qe.fromJS)(o.payload.thing);
- return s.update('shown', (0, qe.fromJS)({}), (s) => s.set(u, i));
- },
- [Bn]: (s, o) => {
- let i = o.payload.thing,
- u = o.payload.mode;
- return s.setIn(['modes'].concat(i), (u || '') + '');
- }
- },
- current = (s) => s.get('layout'),
- currentFilter = (s) => s.get('filter'),
- isShown = (s, o, i) => (
- (o = normalizeArray(o)), s.get('shown', (0, qe.fromJS)({})).get((0, qe.fromJS)(o), i)
- ),
- whatMode = (s, o, i = '') => ((o = normalizeArray(o)), s.getIn(['modes', ...o], i)),
- $n = Ut(
- (s) => s,
- (s) => !isShown(s, 'editor')
- ),
- taggedOperations =
- (s, o) =>
- (i, ...u) => {
- let _ = s(i, ...u);
- const { fn: w, layoutSelectors: x, getConfigs: C } = o.getSystem(),
- j = C(),
- { maxDisplayedTags: L } = j;
- let B = x.currentFilter();
- return B && !0 !== B && (_ = w.opsFilter(_, B)), L >= 0 && (_ = _.slice(0, L)), _;
- };
- function plugins_layout() {
- return {
- statePlugins: {
- layout: { reducers: qn, actions: L, selectors: B },
- spec: { wrapSelectors: $ }
- }
- };
- }
- function logs({ configs: s }) {
- const o = { debug: 0, info: 1, log: 2, warn: 3, error: 4 },
- getLevel = (s) => o[s] || -1;
- let { logLevel: i } = s,
- u = getLevel(i);
- function log(s, ...o) {
- getLevel(s) >= u && console[s](...o);
- }
- return (
- (log.warn = log.bind(null, 'warn')),
- (log.error = log.bind(null, 'error')),
- (log.info = log.bind(null, 'info')),
- (log.debug = log.bind(null, 'debug')),
- { rootInjects: { log } }
- );
- }
- let Vn = !1;
- function on_complete() {
- return {
- statePlugins: {
- spec: {
- wrapActions: {
- updateSpec:
- (s) =>
- (...o) => ((Vn = !0), s(...o)),
- updateJsonSpec:
- (s, o) =>
- (...i) => {
- const u = o.getConfigs().onComplete;
- return Vn && 'function' == typeof u && (setTimeout(u, 0), (Vn = !1)), s(...i);
- }
- }
- }
- }
- };
- }
- const extractKey = (s) => {
- const o = '_**[]';
- return s.indexOf(o) < 0 ? s : s.split(o)[0].trim();
- },
- escapeShell = (s) =>
- '-d ' === s || /^[_\/-]/g.test(s) ? s : "'" + s.replace(/'/g, "'\\''") + "'",
- escapeCMD = (s) =>
- '-d ' ===
- (s = s
- .replace(/\^/g, '^^')
- .replace(/\\"/g, '\\\\"')
- .replace(/"/g, '""')
- .replace(/\n/g, '^\n'))
- ? s.replace(/-d /g, '-d ^\n')
- : /^[_\/-]/g.test(s)
- ? s
- : '"' + s + '"',
- escapePowershell = (s) => {
- if ('-d ' === s) return s;
- if (/\n/.test(s)) {
- return `@"\n${s.replace(/`/g, '``').replace(/\$/g, '`$')}\n"@`;
- }
- if (!/^[_\/-]/.test(s)) {
- return `'${s.replace(/'/g, "''")}'`;
- }
- return s;
- };
- const curlify = (s, o, i, u = '') => {
- let _ = !1,
- w = '';
- const addWords = (...s) => (w += ' ' + s.map(o).join(' ')),
- addWordsWithoutLeadingSpace = (...s) => (w += s.map(o).join(' ')),
- addNewLine = () => (w += ` ${i}`),
- addIndent = (s = 1) => (w += ' '.repeat(s));
- let x = s.get('headers');
- w += 'curl' + u;
- const C = s.get('curlOptions');
- if (
- (qe.List.isList(C) && !C.isEmpty() && addWords(...s.get('curlOptions')),
- addWords('-X', s.get('method')),
- addNewLine(),
- addIndent(),
- addWordsWithoutLeadingSpace(`${s.get('url')}`),
- x && x.size)
- )
- for (let o of s.get('headers').entries()) {
- addNewLine(), addIndent();
- let [s, i] = o;
- addWordsWithoutLeadingSpace('-H', `${s}: ${i}`),
- (_ = _ || (/^content-type$/i.test(s) && /^multipart\/form-data$/i.test(i)));
- }
- const j = s.get('body');
- if (j)
- if (_ && ['POST', 'PUT', 'PATCH'].includes(s.get('method')))
- for (let [s, o] of j.entrySeq()) {
- let i = extractKey(s);
- addNewLine(),
- addIndent(),
- addWordsWithoutLeadingSpace('-F'),
- o instanceof at.File && 'string' == typeof o.valueOf()
- ? addWords(`${i}=${o.data}${o.type ? `;type=${o.type}` : ''}`)
- : o instanceof at.File
- ? addWords(`${i}=@${o.name}${o.type ? `;type=${o.type}` : ''}`)
- : addWords(`${i}=${o}`);
- }
- else if (j instanceof at.File)
- addNewLine(),
- addIndent(),
- addWordsWithoutLeadingSpace(`--data-binary '@${j.name}'`);
- else {
- addNewLine(), addIndent(), addWordsWithoutLeadingSpace('-d ');
- let o = j;
- qe.Map.isMap(o)
- ? addWordsWithoutLeadingSpace(
- (function getStringBodyOfMap(s) {
- let o = [];
- for (let [i, u] of s.get('body').entrySeq()) {
- let s = extractKey(i);
- u instanceof at.File
- ? o.push(
- ` "${s}": {\n "name": "${u.name}"${u.type ? `,\n "type": "${u.type}"` : ''}\n }`
- )
- : o.push(
- ` "${s}": ${JSON.stringify(u, null, 2).replace(/(\r\n|\r|\n)/g, '\n ')}`
- );
- }
- return `{\n${o.join(',\n')}\n}`;
- })(s)
- )
- : ('string' != typeof o && (o = JSON.stringify(o)),
- addWordsWithoutLeadingSpace(o));
- }
- else
- j ||
- 'POST' !== s.get('method') ||
- (addNewLine(), addIndent(), addWordsWithoutLeadingSpace("-d ''"));
- return w;
- },
- requestSnippetGenerator_curl_powershell = (s) =>
- curlify(s, escapePowershell, '`\n', '.exe'),
- requestSnippetGenerator_curl_bash = (s) => curlify(s, escapeShell, '\\\n'),
- requestSnippetGenerator_curl_cmd = (s) => curlify(s, escapeCMD, '^\n'),
- request_snippets_selectors_state = (s) => s || (0, qe.Map)(),
- Un = Ut(request_snippets_selectors_state, (s) => {
- const o = s.get('languages'),
- i = s.get('generators', (0, qe.Map)());
- return !o || o.isEmpty() ? i : i.filter((s, i) => o.includes(i));
- }),
- getSnippetGenerators =
- (s) =>
- ({ fn: o }) =>
- Un(s)
- .map((s, i) => {
- const u = ((s) => o[`requestSnippetGenerator_${s}`])(i);
- return 'function' != typeof u ? null : s.set('fn', u);
- })
- .filter((s) => s),
- zn = Ut(request_snippets_selectors_state, (s) => s.get('activeLanguage')),
- Wn = Ut(request_snippets_selectors_state, (s) => s.get('defaultExpanded'));
- var Kn = __webpack_require__(46942),
- Hn = __webpack_require__.n(Kn),
- Jn = __webpack_require__(59399);
- const Gn = {
- cursor: 'pointer',
- lineHeight: 1,
- display: 'inline-flex',
- backgroundColor: 'rgb(250, 250, 250)',
- paddingBottom: '0',
- paddingTop: '0',
- border: '1px solid rgb(51, 51, 51)',
- borderRadius: '4px 4px 0 0',
- boxShadow: 'none',
- borderBottom: 'none'
- },
- Yn = {
- cursor: 'pointer',
- lineHeight: 1,
- display: 'inline-flex',
- backgroundColor: 'rgb(51, 51, 51)',
- boxShadow: 'none',
- border: '1px solid rgb(51, 51, 51)',
- paddingBottom: '0',
- paddingTop: '0',
- borderRadius: '4px 4px 0 0',
- marginTop: '-5px',
- marginRight: '-5px',
- marginLeft: '-5px',
- zIndex: '9999',
- borderBottom: 'none'
- },
- request_snippets = ({ request: s, requestSnippetsSelectors: o, getComponent: i }) => {
- const u = (0, Pe.useRef)(null),
- _ = i('ArrowUpIcon'),
- w = i('ArrowDownIcon'),
- x = i('SyntaxHighlighter', !0),
- [C, j] = (0, Pe.useState)(o.getSnippetGenerators()?.keySeq().first()),
- [L, B] = (0, Pe.useState)(o?.getDefaultExpanded()),
- $ = o.getSnippetGenerators(),
- V = $.get(C),
- U = V.get('fn')(s),
- handleSetIsExpanded = () => {
- B(!L);
- },
- handleGetBtnStyle = (s) => (s === C ? Yn : Gn),
- handlePreventYScrollingBeyondElement = (s) => {
- const { target: o, deltaY: i } = s,
- { scrollHeight: u, offsetHeight: _, scrollTop: w } = o;
- u > _ && ((0 === w && i < 0) || (_ + w >= u && i > 0)) && s.preventDefault();
- };
- return (
- (0, Pe.useEffect)(() => {}, []),
- (0, Pe.useEffect)(() => {
- const s = Array.from(u.current.childNodes).filter(
- (s) => !!s.nodeType && s.classList?.contains('curl-command')
- );
- return (
- s.forEach((s) =>
- s.addEventListener('mousewheel', handlePreventYScrollingBeyondElement, {
- passive: !1
- })
- ),
- () => {
- s.forEach((s) =>
- s.removeEventListener('mousewheel', handlePreventYScrollingBeyondElement)
- );
- }
- );
- }, [s]),
- Pe.createElement(
- 'div',
- { className: 'request-snippets', ref: u },
- Pe.createElement(
- 'div',
- {
- style: {
- width: '100%',
- display: 'flex',
- justifyContent: 'flex-start',
- alignItems: 'center',
- marginBottom: '15px'
- }
- },
- Pe.createElement(
- 'h4',
- { onClick: () => handleSetIsExpanded(), style: { cursor: 'pointer' } },
- 'Snippets'
- ),
- Pe.createElement(
- 'button',
- {
- onClick: () => handleSetIsExpanded(),
- style: { border: 'none', background: 'none' },
- title: L ? 'Collapse operation' : 'Expand operation'
- },
- L
- ? Pe.createElement(w, { className: 'arrow', width: '10', height: '10' })
- : Pe.createElement(_, { className: 'arrow', width: '10', height: '10' })
- )
- ),
- L &&
- Pe.createElement(
- 'div',
- { className: 'curl-command' },
- Pe.createElement(
- 'div',
- {
- style: {
- paddingLeft: '15px',
- paddingRight: '10px',
- width: '100%',
- display: 'flex'
- }
- },
- $.entrySeq().map(([s, o]) =>
- Pe.createElement(
- 'div',
- {
- className: Hn()('btn', { active: s === C }),
- style: handleGetBtnStyle(s),
- key: s,
- onClick: () =>
- ((s) => {
- C !== s && j(s);
- })(s)
- },
- Pe.createElement(
- 'h4',
- { style: s === C ? { color: 'white' } : {} },
- o.get('title')
- )
- )
- )
- ),
- Pe.createElement(
- 'div',
- { className: 'copy-to-clipboard' },
- Pe.createElement(
- Jn.CopyToClipboard,
- { text: U },
- Pe.createElement('button', null)
- )
- ),
- Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- x,
- {
- language: V.get('syntax'),
- className: 'curl microlight',
- renderPlainText: ({ children: s, PlainTextViewer: o }) =>
- Pe.createElement(o, { className: 'curl' }, s)
- },
- U
- )
- )
- )
- )
- );
- },
- plugins_request_snippets = () => ({
- components: { RequestSnippets: request_snippets },
- fn: V,
- statePlugins: { requestSnippets: { selectors: U } }
- });
- class ModelCollapse extends Pe.Component {
- static defaultProps = {
- collapsedContent: '{...}',
- expanded: !1,
- title: null,
- onToggle: () => {},
- hideSelfOnExpand: !1,
- specPath: $e().List([])
- };
- constructor(s, o) {
- super(s, o);
- let { expanded: i, collapsedContent: u } = this.props;
- this.state = {
- expanded: i,
- collapsedContent: u || ModelCollapse.defaultProps.collapsedContent
- };
- }
- componentDidMount() {
- const { hideSelfOnExpand: s, expanded: o, modelName: i } = this.props;
- s && o && this.props.onToggle(i, o);
- }
- UNSAFE_componentWillReceiveProps(s) {
- this.props.expanded !== s.expanded && this.setState({ expanded: s.expanded });
- }
- toggleCollapsed = () => {
- this.props.onToggle && this.props.onToggle(this.props.modelName, !this.state.expanded),
- this.setState({ expanded: !this.state.expanded });
- };
- onLoad = (s) => {
- if (s && this.props.layoutSelectors) {
- const o = this.props.layoutSelectors.getScrollToKey();
- $e().is(o, this.props.specPath) && this.toggleCollapsed(),
- this.props.layoutActions.readyToScroll(this.props.specPath, s.parentElement);
- }
- };
- render() {
- const { title: s, classes: o } = this.props;
- return this.state.expanded && this.props.hideSelfOnExpand
- ? Pe.createElement('span', { className: o || '' }, this.props.children)
- : Pe.createElement(
- 'span',
- { className: o || '', ref: this.onLoad },
- Pe.createElement(
- 'button',
- {
- 'aria-expanded': this.state.expanded,
- className: 'model-box-control',
- onClick: this.toggleCollapsed
- },
- s && Pe.createElement('span', { className: 'pointer' }, s),
- Pe.createElement('span', {
- className: 'model-toggle' + (this.state.expanded ? '' : ' collapsed')
- }),
- !this.state.expanded &&
- Pe.createElement('span', null, this.state.collapsedContent)
- ),
- this.state.expanded && this.props.children
- );
- }
- }
- const useTabs = ({ initialTab: s, isExecute: o, schema: i, example: u }) => {
- const _ = (0, Pe.useMemo)(() => ({ example: 'example', model: 'model' }), []),
- w = (0, Pe.useMemo)(() => Object.keys(_), [_]).includes(s) && i && !o ? s : _.example,
- x = ((s) => {
- const o = (0, Pe.useRef)();
- return (
- (0, Pe.useEffect)(() => {
- o.current = s;
- }),
- o.current
- );
- })(o),
- [C, j] = (0, Pe.useState)(w),
- L = (0, Pe.useCallback)((s) => {
- j(s.target.dataset.name);
- }, []);
- return (
- (0, Pe.useEffect)(() => {
- x && !o && u && j(_.example);
- }, [x, o, u]),
- { activeTab: C, onTabChange: L, tabs: _ }
- );
- },
- model_example = ({
- schema: s,
- example: o,
- isExecute: i = !1,
- specPath: u,
- includeWriteOnly: _ = !1,
- includeReadOnly: w = !1,
- getComponent: x,
- getConfigs: C,
- specSelectors: j
- }) => {
- const { defaultModelRendering: L, defaultModelExpandDepth: B } = C(),
- $ = x('ModelWrapper'),
- V = x('HighlightCode', !0),
- U = St()(5).toString('base64'),
- z = St()(5).toString('base64'),
- Y = St()(5).toString('base64'),
- Z = St()(5).toString('base64'),
- ee = j.isOAS3(),
- {
- activeTab: ie,
- tabs: ae,
- onTabChange: le
- } = useTabs({ initialTab: L, isExecute: i, schema: s, example: o });
- return Pe.createElement(
- 'div',
- { className: 'model-example' },
- Pe.createElement(
- 'ul',
- { className: 'tab', role: 'tablist' },
- Pe.createElement(
- 'li',
- {
- className: Hn()('tabitem', { active: ie === ae.example }),
- role: 'presentation'
- },
- Pe.createElement(
- 'button',
- {
- 'aria-controls': z,
- 'aria-selected': ie === ae.example,
- className: 'tablinks',
- 'data-name': 'example',
- id: U,
- onClick: le,
- role: 'tab'
- },
- i ? 'Edit Value' : 'Example Value'
- )
- ),
- s &&
- Pe.createElement(
- 'li',
- {
- className: Hn()('tabitem', { active: ie === ae.model }),
- role: 'presentation'
- },
- Pe.createElement(
- 'button',
- {
- 'aria-controls': Z,
- 'aria-selected': ie === ae.model,
- className: Hn()('tablinks', { inactive: i }),
- 'data-name': 'model',
- id: Y,
- onClick: le,
- role: 'tab'
- },
- ee ? 'Schema' : 'Model'
- )
- )
- ),
- ie === ae.example &&
- Pe.createElement(
- 'div',
- {
- 'aria-hidden': ie !== ae.example,
- 'aria-labelledby': U,
- 'data-name': 'examplePanel',
- id: z,
- role: 'tabpanel',
- tabIndex: '0'
- },
- o || Pe.createElement(V, null, '(no example available')
- ),
- ie === ae.model &&
- Pe.createElement(
- 'div',
- {
- 'aria-hidden': ie === ae.example,
- 'aria-labelledby': Y,
- 'data-name': 'modelPanel',
- id: Z,
- role: 'tabpanel',
- tabIndex: '0'
- },
- Pe.createElement($, {
- schema: s,
- getComponent: x,
- getConfigs: C,
- specSelectors: j,
- expandDepth: B,
- specPath: u,
- includeReadOnly: w,
- includeWriteOnly: _
- })
- )
- );
- };
- class ModelWrapper extends Pe.Component {
- onToggle = (s, o) => {
- this.props.layoutActions && this.props.layoutActions.show(this.props.fullPath, o);
- };
- render() {
- let { getComponent: s, getConfigs: o } = this.props;
- const i = s('Model');
- let u;
- return (
- this.props.layoutSelectors &&
- (u = this.props.layoutSelectors.isShown(this.props.fullPath)),
- Pe.createElement(
- 'div',
- { className: 'model-box' },
- Pe.createElement(
- i,
- Rn()({}, this.props, {
- getConfigs: o,
- expanded: u,
- depth: 1,
- onToggle: this.onToggle,
- expandDepth: this.props.expandDepth || 0
- })
- )
- )
- );
- }
- }
- function _typeof(s) {
- return (
- (_typeof =
- 'function' == typeof Symbol && 'symbol' == typeof Symbol.iterator
- ? function (s) {
- return typeof s;
- }
- : function (s) {
- return s &&
- 'function' == typeof Symbol &&
- s.constructor === Symbol &&
- s !== Symbol.prototype
- ? 'symbol'
- : typeof s;
- }),
- _typeof(s)
- );
- }
- function _defineProperties(s, o) {
- for (var i = 0; i < o.length; i++) {
- var u = o[i];
- (u.enumerable = u.enumerable || !1),
- (u.configurable = !0),
- 'value' in u && (u.writable = !0),
- Object.defineProperty(s, u.key, u);
- }
- }
- function _defineProperty(s, o, i) {
- return (
- o in s
- ? Object.defineProperty(s, o, {
- value: i,
- enumerable: !0,
- configurable: !0,
- writable: !0
- })
- : (s[o] = i),
- s
- );
- }
- function ownKeys(s, o) {
- var i = Object.keys(s);
- if (Object.getOwnPropertySymbols) {
- var u = Object.getOwnPropertySymbols(s);
- o &&
- (u = u.filter(function (o) {
- return Object.getOwnPropertyDescriptor(s, o).enumerable;
- })),
- i.push.apply(i, u);
- }
- return i;
- }
- function _getPrototypeOf(s) {
- return (
- (_getPrototypeOf = Object.setPrototypeOf
- ? Object.getPrototypeOf
- : function _getPrototypeOf(s) {
- return s.__proto__ || Object.getPrototypeOf(s);
- }),
- _getPrototypeOf(s)
- );
- }
- function _setPrototypeOf(s, o) {
- return (
- (_setPrototypeOf =
- Object.setPrototypeOf ||
- function _setPrototypeOf(s, o) {
- return (s.__proto__ = o), s;
- }),
- _setPrototypeOf(s, o)
- );
- }
- function _possibleConstructorReturn(s, o) {
- return !o || ('object' != typeof o && 'function' != typeof o)
- ? (function _assertThisInitialized(s) {
- if (void 0 === s)
- throw new ReferenceError(
- "this hasn't been initialised - super() hasn't been called"
- );
- return s;
- })(s)
- : o;
- }
- var Xn = {};
- function react_immutable_pure_component_es_get(s, o, i) {
- return (function isInvalid(s) {
- return null == s;
- })(s)
- ? i
- : (function isMapLike(s) {
- return (
- null !== s &&
- 'object' === _typeof(s) &&
- 'function' == typeof s.get &&
- 'function' == typeof s.has
- );
- })(s)
- ? s.has(o)
- ? s.get(o)
- : i
- : hasOwnProperty.call(s, o)
- ? s[o]
- : i;
- }
- function getIn(s, o, i) {
- for (var u = 0; u !== o.length; )
- if ((s = react_immutable_pure_component_es_get(s, o[u++], Xn)) === Xn) return i;
- return s;
- }
- function check(s) {
- var o = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {},
- i = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : {},
- u = (function createChecker(s, o) {
- return function (i) {
- if ('string' == typeof i) return (0, qe.is)(o[i], s[i]);
- if (Array.isArray(i)) return (0, qe.is)(getIn(o, i), getIn(s, i));
- throw new TypeError('Invalid key: expected Array or string: ' + i);
- };
- })(o, i),
- _ =
- s ||
- Object.keys(
- (function _objectSpread2(s) {
- for (var o = 1; o < arguments.length; o++) {
- var i = null != arguments[o] ? arguments[o] : {};
- o % 2
- ? ownKeys(i, !0).forEach(function (o) {
- _defineProperty(s, o, i[o]);
- })
- : Object.getOwnPropertyDescriptors
- ? Object.defineProperties(s, Object.getOwnPropertyDescriptors(i))
- : ownKeys(i).forEach(function (o) {
- Object.defineProperty(s, o, Object.getOwnPropertyDescriptor(i, o));
- });
- }
- return s;
- })({}, i, {}, o)
- );
- return _.every(u);
- }
- const Zn = (function (s) {
- function ImmutablePureComponent() {
- return (
- (function _classCallCheck(s, o) {
- if (!(s instanceof o)) throw new TypeError('Cannot call a class as a function');
- })(this, ImmutablePureComponent),
- _possibleConstructorReturn(
- this,
- _getPrototypeOf(ImmutablePureComponent).apply(this, arguments)
- )
- );
- }
- return (
- (function _inherits(s, o) {
- if ('function' != typeof o && null !== o)
- throw new TypeError('Super expression must either be null or a function');
- (s.prototype = Object.create(o && o.prototype, {
- constructor: { value: s, writable: !0, configurable: !0 }
- })),
- o && _setPrototypeOf(s, o);
- })(ImmutablePureComponent, s),
- (function _createClass(s, o, i) {
- return o && _defineProperties(s.prototype, o), i && _defineProperties(s, i), s;
- })(ImmutablePureComponent, [
- {
- key: 'shouldComponentUpdate',
- value: function shouldComponentUpdate(s) {
- var o = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {};
- return (
- !check(this.updateOnProps, this.props, s, 'updateOnProps') ||
- !check(this.updateOnStates, this.state, o, 'updateOnStates')
- );
- }
- }
- ]),
- ImmutablePureComponent
- );
- })(Pe.Component);
- var Qn,
- es = __webpack_require__(5556),
- ts = __webpack_require__.n(es);
- function _extends() {
- return (
- (_extends = Object.assign
- ? Object.assign.bind()
- : function (s) {
- for (var o = 1; o < arguments.length; o++) {
- var i = arguments[o];
- for (var u in i) ({}).hasOwnProperty.call(i, u) && (s[u] = i[u]);
- }
- return s;
- }),
- _extends.apply(null, arguments)
- );
- }
- const rolling_load = (s) =>
- Pe.createElement(
- 'svg',
- _extends(
- {
- xmlns: 'http://www.w3.org/2000/svg',
- width: 200,
- height: 200,
- className: 'rolling-load_svg__lds-rolling',
- preserveAspectRatio: 'xMidYMid',
- style: {
- backgroundImage: 'none',
- backgroundPosition: 'initial initial',
- backgroundRepeat: 'initial initial'
- },
- viewBox: '0 0 100 100'
- },
- s
- ),
- Qn ||
- (Qn = Pe.createElement(
- 'circle',
- {
- cx: 50,
- cy: 50,
- r: 35,
- fill: 'none',
- stroke: '#555',
- strokeDasharray: '164.93361431346415 56.97787143782138',
- strokeWidth: 10
- },
- Pe.createElement('animateTransform', {
- attributeName: 'transform',
- begin: '0s',
- calcMode: 'linear',
- dur: '1s',
- keyTimes: '0;1',
- repeatCount: 'indefinite',
- type: 'rotate',
- values: '0 50 50;360 50 50'
- })
- ))
- ),
- decodeRefName = (s) => {
- const o = s.replace(/~1/g, '/').replace(/~0/g, '~');
- try {
- return decodeURIComponent(o);
- } catch {
- return o;
- }
- };
- class Model extends Zn {
- static propTypes = {
- schema: kn().map.isRequired,
- getComponent: ts().func.isRequired,
- getConfigs: ts().func.isRequired,
- specSelectors: ts().object.isRequired,
- name: ts().string,
- displayName: ts().string,
- isRef: ts().bool,
- required: ts().bool,
- expandDepth: ts().number,
- depth: ts().number,
- specPath: kn().list.isRequired,
- includeReadOnly: ts().bool,
- includeWriteOnly: ts().bool
- };
- getModelName = (s) =>
- -1 !== s.indexOf('#/definitions/')
- ? decodeRefName(s.replace(/^.*#\/definitions\//, ''))
- : -1 !== s.indexOf('#/components/schemas/')
- ? decodeRefName(s.replace(/^.*#\/components\/schemas\//, ''))
- : void 0;
- getRefSchema = (s) => {
- let { specSelectors: o } = this.props;
- return o.findDefinition(s);
- };
- render() {
- let {
- getComponent: s,
- getConfigs: o,
- specSelectors: i,
- schema: u,
- required: _,
- name: w,
- isRef: x,
- specPath: C,
- displayName: j,
- includeReadOnly: L,
- includeWriteOnly: B
- } = this.props;
- const $ = s('ObjectModel'),
- V = s('ArrayModel'),
- U = s('PrimitiveModel');
- let z = 'object',
- Y = u && u.get('$$ref'),
- Z = u && u.get('$ref');
- if ((!w && Y && (w = this.getModelName(Y)), Z)) {
- const s = this.getModelName(Z),
- o = this.getRefSchema(s);
- qe.Map.isMap(o)
- ? ((u = o.mergeDeep(u)), Y || ((u = u.set('$$ref', Z)), (Y = Z)))
- : qe.Map.isMap(u) && 1 === u.size && ((u = null), (w = Z));
- }
- if (!u)
- return Pe.createElement(
- 'span',
- { className: 'model model-title' },
- Pe.createElement('span', { className: 'model-title__text' }, j || w),
- !Z && Pe.createElement(rolling_load, { height: '20px', width: '20px' })
- );
- const ee = i.isOAS3() && u.get('deprecated');
- switch (((x = void 0 !== x ? x : !!Y), (z = (u && u.get('type')) || z), z)) {
- case 'object':
- return Pe.createElement(
- $,
- Rn()({ className: 'object' }, this.props, {
- specPath: C,
- getConfigs: o,
- schema: u,
- name: w,
- deprecated: ee,
- isRef: x,
- includeReadOnly: L,
- includeWriteOnly: B
- })
- );
- case 'array':
- return Pe.createElement(
- V,
- Rn()({ className: 'array' }, this.props, {
- getConfigs: o,
- schema: u,
- name: w,
- deprecated: ee,
- required: _,
- includeReadOnly: L,
- includeWriteOnly: B
- })
- );
- default:
- return Pe.createElement(
- U,
- Rn()({}, this.props, {
- getComponent: s,
- getConfigs: o,
- schema: u,
- name: w,
- deprecated: ee,
- required: _
- })
- );
- }
- }
- }
- class Models extends Pe.Component {
- getSchemaBasePath = () =>
- this.props.specSelectors.isOAS3() ? ['components', 'schemas'] : ['definitions'];
- getCollapsedContent = () => ' ';
- handleToggle = (s, o) => {
- const { layoutActions: i } = this.props;
- i.show([...this.getSchemaBasePath(), s], o),
- o && this.props.specActions.requestResolvedSubtree([...this.getSchemaBasePath(), s]);
- };
- onLoadModels = (s) => {
- s && this.props.layoutActions.readyToScroll(this.getSchemaBasePath(), s);
- };
- onLoadModel = (s) => {
- if (s) {
- const o = s.getAttribute('data-name');
- this.props.layoutActions.readyToScroll([...this.getSchemaBasePath(), o], s);
- }
- };
- render() {
- let {
- specSelectors: s,
- getComponent: o,
- layoutSelectors: i,
- layoutActions: u,
- getConfigs: _
- } = this.props,
- w = s.definitions(),
- { docExpansion: x, defaultModelsExpandDepth: C } = _();
- if (!w.size || C < 0) return null;
- const j = this.getSchemaBasePath();
- let L = i.isShown(j, C > 0 && 'none' !== x);
- const B = s.isOAS3(),
- $ = o('ModelWrapper'),
- V = o('Collapse'),
- U = o('ModelCollapse'),
- z = o('JumpToPath', !0),
- Y = o('ArrowUpIcon'),
- Z = o('ArrowDownIcon');
- return Pe.createElement(
- 'section',
- { className: L ? 'models is-open' : 'models', ref: this.onLoadModels },
- Pe.createElement(
- 'h4',
- null,
- Pe.createElement(
- 'button',
- { 'aria-expanded': L, className: 'models-control', onClick: () => u.show(j, !L) },
- Pe.createElement('span', null, B ? 'Schemas' : 'Models'),
- L ? Pe.createElement(Y, null) : Pe.createElement(Z, null)
- )
- ),
- Pe.createElement(
- V,
- { isOpened: L },
- w
- .entrySeq()
- .map(([w]) => {
- const x = [...j, w],
- L = $e().List(x),
- B = s.specResolvedSubtree(x),
- V = s.specJson().getIn(x),
- Y = qe.Map.isMap(B) ? B : $e().Map(),
- Z = qe.Map.isMap(V) ? V : $e().Map(),
- ee = Y.get('title') || Z.get('title') || w,
- ie = i.isShown(x, !1);
- ie &&
- 0 === Y.size &&
- Z.size > 0 &&
- this.props.specActions.requestResolvedSubtree(x);
- const ae = Pe.createElement($, {
- name: w,
- expandDepth: C,
- schema: Y || $e().Map(),
- displayName: ee,
- fullPath: x,
- specPath: L,
- getComponent: o,
- specSelectors: s,
- getConfigs: _,
- layoutSelectors: i,
- layoutActions: u,
- includeReadOnly: !0,
- includeWriteOnly: !0
- }),
- le = Pe.createElement(
- 'span',
- { className: 'model-box' },
- Pe.createElement('span', { className: 'model model-title' }, ee)
- );
- return Pe.createElement(
- 'div',
- {
- id: `model-${w}`,
- className: 'model-container',
- key: `models-section-${w}`,
- 'data-name': w,
- ref: this.onLoadModel
- },
- Pe.createElement(
- 'span',
- { className: 'models-jump-to-path' },
- Pe.createElement(z, { specPath: L })
- ),
- Pe.createElement(
- U,
- {
- classes: 'model-box',
- collapsedContent: this.getCollapsedContent(w),
- onToggle: this.handleToggle,
- title: le,
- displayName: ee,
- modelName: w,
- specPath: L,
- layoutSelectors: i,
- layoutActions: u,
- hideSelfOnExpand: !0,
- expanded: C > 0 && ie
- },
- ae
- )
- );
- })
- .toArray()
- )
- );
- }
- }
- const enum_model = ({ value: s, getComponent: o }) => {
- let i = o('ModelCollapse'),
- u = Pe.createElement('span', null, 'Array [ ', s.count(), ' ]');
- return Pe.createElement(
- 'span',
- { className: 'prop-enum' },
- 'Enum:',
- Pe.createElement('br', null),
- Pe.createElement(i, { collapsedContent: u }, '[ ', s.map(String).join(', '), ' ]')
- );
- };
- class ObjectModel extends Pe.Component {
- render() {
- let {
- schema: s,
- name: o,
- displayName: i,
- isRef: u,
- getComponent: _,
- getConfigs: w,
- depth: x,
- onToggle: C,
- expanded: j,
- specPath: L,
- ...B
- } = this.props,
- { specSelectors: $, expandDepth: V, includeReadOnly: U, includeWriteOnly: z } = B;
- const { isOAS3: Y } = $;
- if (!s) return null;
- const { showExtensions: Z } = w();
- let ee = s.get('description'),
- ie = s.get('properties'),
- ae = s.get('additionalProperties'),
- le = s.get('title') || i || o,
- ce = s.get('required'),
- pe = s.filter(
- (s, o) =>
- -1 !== ['maxProperties', 'minProperties', 'nullable', 'example'].indexOf(o)
- ),
- de = s.get('deprecated'),
- fe = s.getIn(['externalDocs', 'url']),
- ye = s.getIn(['externalDocs', 'description']);
- const be = _('JumpToPath', !0),
- _e = _('Markdown', !0),
- we = _('Model'),
- Se = _('ModelCollapse'),
- xe = _('Property'),
- Te = _('Link'),
- JumpToPathSection = () =>
- Pe.createElement(
- 'span',
- { className: 'model-jump-to-path' },
- Pe.createElement(be, { specPath: L })
- ),
- Re = Pe.createElement(
- 'span',
- null,
- Pe.createElement('span', null, '{'),
- '...',
- Pe.createElement('span', null, '}'),
- u ? Pe.createElement(JumpToPathSection, null) : ''
- ),
- $e = $.isOAS3() ? s.get('allOf') : null,
- ze = $.isOAS3() ? s.get('anyOf') : null,
- We = $.isOAS3() ? s.get('oneOf') : null,
- He = $.isOAS3() ? s.get('not') : null,
- Ye =
- le &&
- Pe.createElement(
- 'span',
- { className: 'model-title' },
- u &&
- s.get('$$ref') &&
- Pe.createElement('span', { className: 'model-hint' }, s.get('$$ref')),
- Pe.createElement('span', { className: 'model-title__text' }, le)
- );
- return Pe.createElement(
- 'span',
- { className: 'model' },
- Pe.createElement(
- Se,
- {
- modelName: o,
- title: Ye,
- onToggle: C,
- expanded: !!j || x <= V,
- collapsedContent: Re
- },
- Pe.createElement('span', { className: 'brace-open object' }, '{'),
- u ? Pe.createElement(JumpToPathSection, null) : null,
- Pe.createElement(
- 'span',
- { className: 'inner-object' },
- Pe.createElement(
- 'table',
- { className: 'model' },
- Pe.createElement(
- 'tbody',
- null,
- ee
- ? Pe.createElement(
- 'tr',
- { className: 'description' },
- Pe.createElement('td', null, 'description:'),
- Pe.createElement('td', null, Pe.createElement(_e, { source: ee }))
- )
- : null,
- fe &&
- Pe.createElement(
- 'tr',
- { className: 'external-docs' },
- Pe.createElement('td', null, 'externalDocs:'),
- Pe.createElement(
- 'td',
- null,
- Pe.createElement(
- Te,
- { target: '_blank', href: sanitizeUrl(fe) },
- ye || fe
- )
- )
- ),
- de
- ? Pe.createElement(
- 'tr',
- { className: 'property' },
- Pe.createElement('td', null, 'deprecated:'),
- Pe.createElement('td', null, 'true')
- )
- : null,
- ie && ie.size
- ? ie
- .entrySeq()
- .filter(
- ([, s]) => (!s.get('readOnly') || U) && (!s.get('writeOnly') || z)
- )
- .map(([s, i]) => {
- let u = Y() && i.get('deprecated'),
- C = qe.List.isList(ce) && ce.contains(s),
- j = ['property-row'];
- return (
- u && j.push('deprecated'),
- C && j.push('required'),
- Pe.createElement(
- 'tr',
- { key: s, className: j.join(' ') },
- Pe.createElement(
- 'td',
- null,
- s,
- C && Pe.createElement('span', { className: 'star' }, '*')
- ),
- Pe.createElement(
- 'td',
- null,
- Pe.createElement(
- we,
- Rn()({ key: `object-${o}-${s}_${i}` }, B, {
- required: C,
- getComponent: _,
- specPath: L.push('properties', s),
- getConfigs: w,
- schema: i,
- depth: x + 1
- })
- )
- )
- )
- );
- })
- .toArray()
- : null,
- Z ? Pe.createElement('tr', null, Pe.createElement('td', null, ' ')) : null,
- Z
- ? s
- .entrySeq()
- .map(([s, o]) => {
- if ('x-' !== s.slice(0, 2)) return;
- const i = o ? (o.toJS ? o.toJS() : o) : null;
- return Pe.createElement(
- 'tr',
- { key: s, className: 'extension' },
- Pe.createElement('td', null, s),
- Pe.createElement('td', null, JSON.stringify(i))
- );
- })
- .toArray()
- : null,
- ae && ae.size
- ? Pe.createElement(
- 'tr',
- null,
- Pe.createElement('td', null, '< * >:'),
- Pe.createElement(
- 'td',
- null,
- Pe.createElement(
- we,
- Rn()({}, B, {
- required: !1,
- getComponent: _,
- specPath: L.push('additionalProperties'),
- getConfigs: w,
- schema: ae,
- depth: x + 1
- })
- )
- )
- )
- : null,
- $e
- ? Pe.createElement(
- 'tr',
- null,
- Pe.createElement('td', null, 'allOf ->'),
- Pe.createElement(
- 'td',
- null,
- $e.map((s, o) =>
- Pe.createElement(
- 'div',
- { key: o },
- Pe.createElement(
- we,
- Rn()({}, B, {
- required: !1,
- getComponent: _,
- specPath: L.push('allOf', o),
- getConfigs: w,
- schema: s,
- depth: x + 1
- })
- )
- )
- )
- )
- )
- : null,
- ze
- ? Pe.createElement(
- 'tr',
- null,
- Pe.createElement('td', null, 'anyOf ->'),
- Pe.createElement(
- 'td',
- null,
- ze.map((s, o) =>
- Pe.createElement(
- 'div',
- { key: o },
- Pe.createElement(
- we,
- Rn()({}, B, {
- required: !1,
- getComponent: _,
- specPath: L.push('anyOf', o),
- getConfigs: w,
- schema: s,
- depth: x + 1
- })
- )
- )
- )
- )
- )
- : null,
- We
- ? Pe.createElement(
- 'tr',
- null,
- Pe.createElement('td', null, 'oneOf ->'),
- Pe.createElement(
- 'td',
- null,
- We.map((s, o) =>
- Pe.createElement(
- 'div',
- { key: o },
- Pe.createElement(
- we,
- Rn()({}, B, {
- required: !1,
- getComponent: _,
- specPath: L.push('oneOf', o),
- getConfigs: w,
- schema: s,
- depth: x + 1
- })
- )
- )
- )
- )
- )
- : null,
- He
- ? Pe.createElement(
- 'tr',
- null,
- Pe.createElement('td', null, 'not ->'),
- Pe.createElement(
- 'td',
- null,
- Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- we,
- Rn()({}, B, {
- required: !1,
- getComponent: _,
- specPath: L.push('not'),
- getConfigs: w,
- schema: He,
- depth: x + 1
- })
- )
- )
- )
- )
- : null
- )
- )
- ),
- Pe.createElement('span', { className: 'brace-close' }, '}')
- ),
- pe.size
- ? pe.entrySeq().map(([s, o]) =>
- Pe.createElement(xe, {
- key: `${s}-${o}`,
- propKey: s,
- propVal: o,
- propClass: 'property'
- })
- )
- : null
- );
- }
- }
- class ArrayModel extends Pe.Component {
- render() {
- let {
- getComponent: s,
- getConfigs: o,
- schema: i,
- depth: u,
- expandDepth: _,
- name: w,
- displayName: x,
- specPath: C
- } = this.props,
- j = i.get('description'),
- L = i.get('items'),
- B = i.get('title') || x || w,
- $ = i.filter(
- (s, o) =>
- -1 === ['type', 'items', 'description', '$$ref', 'externalDocs'].indexOf(o)
- ),
- V = i.getIn(['externalDocs', 'url']),
- U = i.getIn(['externalDocs', 'description']);
- const z = s('Markdown', !0),
- Y = s('ModelCollapse'),
- Z = s('Model'),
- ee = s('Property'),
- ie = s('Link'),
- ae =
- B &&
- Pe.createElement(
- 'span',
- { className: 'model-title' },
- Pe.createElement('span', { className: 'model-title__text' }, B)
- );
- return Pe.createElement(
- 'span',
- { className: 'model' },
- Pe.createElement(
- Y,
- { title: ae, expanded: u <= _, collapsedContent: '[...]' },
- '[',
- $.size
- ? $.entrySeq().map(([s, o]) =>
- Pe.createElement(ee, {
- key: `${s}-${o}`,
- propKey: s,
- propVal: o,
- propClass: 'property'
- })
- )
- : null,
- j
- ? Pe.createElement(z, { source: j })
- : $.size
- ? Pe.createElement('div', { className: 'markdown' })
- : null,
- V &&
- Pe.createElement(
- 'div',
- { className: 'external-docs' },
- Pe.createElement(ie, { target: '_blank', href: sanitizeUrl(V) }, U || V)
- ),
- Pe.createElement(
- 'span',
- null,
- Pe.createElement(
- Z,
- Rn()({}, this.props, {
- getConfigs: o,
- specPath: C.push('items'),
- name: null,
- schema: L,
- required: !1,
- depth: u + 1
- })
- )
- ),
- ']'
- )
- );
- }
- }
- const rs = 'property primitive';
- class Primitive extends Pe.Component {
- render() {
- let {
- schema: s,
- getComponent: o,
- getConfigs: i,
- name: u,
- displayName: _,
- depth: w,
- expandDepth: x
- } = this.props;
- const { showExtensions: C } = i();
- if (!s || !s.get) return Pe.createElement('div', null);
- let j = s.get('type'),
- L = s.get('format'),
- B = s.get('xml'),
- $ = s.get('enum'),
- V = s.get('title') || _ || u,
- U = s.get('description'),
- z = getExtensions(s),
- Y = s
- .filter(
- (s, o) =>
- -1 ===
- ['enum', 'type', 'format', 'description', '$$ref', 'externalDocs'].indexOf(o)
- )
- .filterNot((s, o) => z.has(o)),
- Z = s.getIn(['externalDocs', 'url']),
- ee = s.getIn(['externalDocs', 'description']);
- const ie = o('Markdown', !0),
- ae = o('EnumModel'),
- le = o('Property'),
- ce = o('ModelCollapse'),
- pe = o('Link'),
- de =
- V &&
- Pe.createElement(
- 'span',
- { className: 'model-title' },
- Pe.createElement('span', { className: 'model-title__text' }, V)
- );
- return Pe.createElement(
- 'span',
- { className: 'model' },
- Pe.createElement(
- ce,
- { title: de, expanded: w <= x, collapsedContent: '[...]' },
- Pe.createElement(
- 'span',
- { className: 'prop' },
- u && w > 1 && Pe.createElement('span', { className: 'prop-name' }, V),
- Pe.createElement('span', { className: 'prop-type' }, j),
- L && Pe.createElement('span', { className: 'prop-format' }, '($', L, ')'),
- Y.size
- ? Y.entrySeq().map(([s, o]) =>
- Pe.createElement(le, {
- key: `${s}-${o}`,
- propKey: s,
- propVal: o,
- propClass: rs
- })
- )
- : null,
- C && z.size
- ? z.entrySeq().map(([s, o]) =>
- Pe.createElement(le, {
- key: `${s}-${o}`,
- propKey: s,
- propVal: o,
- propClass: rs
- })
- )
- : null,
- U ? Pe.createElement(ie, { source: U }) : null,
- Z &&
- Pe.createElement(
- 'div',
- { className: 'external-docs' },
- Pe.createElement(pe, { target: '_blank', href: sanitizeUrl(Z) }, ee || Z)
- ),
- B && B.size
- ? Pe.createElement(
- 'span',
- null,
- Pe.createElement('br', null),
- Pe.createElement('span', { className: rs }, 'xml:'),
- B.entrySeq()
- .map(([s, o]) =>
- Pe.createElement(
- 'span',
- { key: `${s}-${o}`, className: rs },
- Pe.createElement('br', null),
- ' ',
- s,
- ': ',
- String(o)
- )
- )
- .toArray()
- )
- : null,
- $ && Pe.createElement(ae, { value: $, getComponent: o })
- )
- )
- );
- }
- }
- class Schemes extends Pe.Component {
- UNSAFE_componentWillMount() {
- let { schemes: s } = this.props;
- this.setScheme(s.first());
- }
- UNSAFE_componentWillReceiveProps(s) {
- (this.props.currentScheme && s.schemes.includes(this.props.currentScheme)) ||
- this.setScheme(s.schemes.first());
- }
- onChange = (s) => {
- this.setScheme(s.target.value);
- };
- setScheme = (s) => {
- let { path: o, method: i, specActions: u } = this.props;
- u.setScheme(s, o, i);
- };
- render() {
- let { schemes: s, currentScheme: o } = this.props;
- return Pe.createElement(
- 'label',
- { htmlFor: 'schemes' },
- Pe.createElement('span', { className: 'schemes-title' }, 'Schemes'),
- Pe.createElement(
- 'select',
- { onChange: this.onChange, value: o, id: 'schemes' },
- s
- .valueSeq()
- .map((s) => Pe.createElement('option', { value: s, key: s }, s))
- .toArray()
- )
- );
- }
- }
- class SchemesContainer extends Pe.Component {
- render() {
- const { specActions: s, specSelectors: o, getComponent: i } = this.props,
- u = o.operationScheme(),
- _ = o.schemes(),
- w = i('schemes');
- return _ && _.size
- ? Pe.createElement(w, { currentScheme: u, schemes: _, specActions: s })
- : null;
- }
- }
- var ns = __webpack_require__(24677),
- ss = __webpack_require__.n(ns);
- const os = {
- value: '',
- onChange: () => {},
- schema: {},
- keyName: '',
- required: !1,
- errors: (0, qe.List)()
- };
- class JsonSchemaForm extends Pe.Component {
- static defaultProps = os;
- componentDidMount() {
- const { dispatchInitialValue: s, value: o, onChange: i } = this.props;
- s ? i(o) : !1 === s && i('');
- }
- render() {
- let {
- schema: s,
- errors: o,
- value: i,
- onChange: u,
- getComponent: _,
- fn: w,
- disabled: x
- } = this.props;
- const C = s && s.get ? s.get('format') : null,
- j = s && s.get ? s.get('type') : null;
- let getComponentSilently = (s) => _(s, !1, { failSilently: !0 }),
- L = j
- ? getComponentSilently(C ? `JsonSchema_${j}_${C}` : `JsonSchema_${j}`)
- : _('JsonSchema_string');
- return (
- L || (L = _('JsonSchema_string')),
- Pe.createElement(
- L,
- Rn()({}, this.props, {
- errors: o,
- fn: w,
- getComponent: _,
- value: i,
- onChange: u,
- schema: s,
- disabled: x
- })
- )
- );
- }
- }
- class JsonSchema_string extends Pe.Component {
- static defaultProps = os;
- onChange = (s) => {
- const o =
- this.props.schema && 'file' === this.props.schema.get('type')
- ? s.target.files[0]
- : s.target.value;
- this.props.onChange(o, this.props.keyName);
- };
- onEnumChange = (s) => this.props.onChange(s);
- render() {
- let {
- getComponent: s,
- value: o,
- schema: i,
- errors: u,
- required: _,
- description: w,
- disabled: x
- } = this.props;
- const C = i && i.get ? i.get('enum') : null,
- j = i && i.get ? i.get('format') : null,
- L = i && i.get ? i.get('type') : null,
- B = i && i.get ? i.get('in') : null;
- if ((o || (o = ''), (u = u.toJS ? u.toJS() : []), C)) {
- const i = s('Select');
- return Pe.createElement(i, {
- className: u.length ? 'invalid' : '',
- title: u.length ? u : '',
- allowedValues: [...C],
- value: o,
- allowEmptyValue: !_,
- disabled: x,
- onChange: this.onEnumChange
- });
- }
- const $ = x || (B && 'formData' === B && !('FormData' in window)),
- V = s('Input');
- return L && 'file' === L
- ? Pe.createElement(V, {
- type: 'file',
- className: u.length ? 'invalid' : '',
- title: u.length ? u : '',
- onChange: this.onChange,
- disabled: $
- })
- : Pe.createElement(ss(), {
- type: j && 'password' === j ? 'password' : 'text',
- className: u.length ? 'invalid' : '',
- title: u.length ? u : '',
- value: o,
- minLength: 0,
- debounceTimeout: 350,
- placeholder: w,
- onChange: this.onChange,
- disabled: $
- });
- }
- }
- class JsonSchema_array extends Pe.PureComponent {
- static defaultProps = os;
- constructor(s, o) {
- super(s, o), (this.state = { value: valueOrEmptyList(s.value), schema: s.schema });
- }
- UNSAFE_componentWillReceiveProps(s) {
- const o = valueOrEmptyList(s.value);
- o !== this.state.value && this.setState({ value: o }),
- s.schema !== this.state.schema && this.setState({ schema: s.schema });
- }
- onChange = () => {
- this.props.onChange(this.state.value);
- };
- onItemChange = (s, o) => {
- this.setState(({ value: i }) => ({ value: i.set(o, s) }), this.onChange);
- };
- removeItem = (s) => {
- this.setState(({ value: o }) => ({ value: o.delete(s) }), this.onChange);
- };
- addItem = () => {
- const { fn: s } = this.props;
- let o = valueOrEmptyList(this.state.value);
- this.setState(
- () => ({
- value: o.push(
- s.getSampleSchema(this.state.schema.get('items'), !1, { includeWriteOnly: !0 })
- )
- }),
- this.onChange
- );
- };
- onEnumChange = (s) => {
- this.setState(() => ({ value: s }), this.onChange);
- };
- render() {
- let {
- getComponent: s,
- required: o,
- schema: i,
- errors: u,
- fn: _,
- disabled: w
- } = this.props;
- u = u.toJS ? u.toJS() : Array.isArray(u) ? u : [];
- const x = u.filter((s) => 'string' == typeof s),
- C = u.filter((s) => void 0 !== s.needRemove).map((s) => s.error),
- j = this.state.value,
- L = !!(j && j.count && j.count() > 0),
- B = i.getIn(['items', 'enum']),
- $ = i.getIn(['items', 'type']),
- V = i.getIn(['items', 'format']),
- U = i.get('items');
- let z,
- Y = !1,
- Z = 'file' === $ || ('string' === $ && 'binary' === V);
- if (
- ($ && V
- ? (z = s(`JsonSchema_${$}_${V}`))
- : ('boolean' !== $ && 'array' !== $ && 'object' !== $) ||
- (z = s(`JsonSchema_${$}`)),
- z || Z || (Y = !0),
- B)
- ) {
- const i = s('Select');
- return Pe.createElement(i, {
- className: u.length ? 'invalid' : '',
- title: u.length ? u : '',
- multiple: !0,
- value: j,
- disabled: w,
- allowedValues: B,
- allowEmptyValue: !o,
- onChange: this.onEnumChange
- });
- }
- const ee = s('Button');
- return Pe.createElement(
- 'div',
- { className: 'json-schema-array' },
- L
- ? j.map((o, i) => {
- const x = (0, qe.fromJS)([
- ...u.filter((s) => s.index === i).map((s) => s.error)
- ]);
- return Pe.createElement(
- 'div',
- { key: i, className: 'json-schema-form-item' },
- Z
- ? Pe.createElement(JsonSchemaArrayItemFile, {
- value: o,
- onChange: (s) => this.onItemChange(s, i),
- disabled: w,
- errors: x,
- getComponent: s
- })
- : Y
- ? Pe.createElement(JsonSchemaArrayItemText, {
- value: o,
- onChange: (s) => this.onItemChange(s, i),
- disabled: w,
- errors: x
- })
- : Pe.createElement(
- z,
- Rn()({}, this.props, {
- value: o,
- onChange: (s) => this.onItemChange(s, i),
- disabled: w,
- errors: x,
- schema: U,
- getComponent: s,
- fn: _
- })
- ),
- w
- ? null
- : Pe.createElement(
- ee,
- {
- className: `btn btn-sm json-schema-form-item-remove ${C.length ? 'invalid' : null}`,
- title: C.length ? C : '',
- onClick: () => this.removeItem(i)
- },
- ' - '
- )
- );
- })
- : null,
- w
- ? null
- : Pe.createElement(
- ee,
- {
- className: `btn btn-sm json-schema-form-item-add ${x.length ? 'invalid' : null}`,
- title: x.length ? x : '',
- onClick: this.addItem
- },
- 'Add ',
- $ ? `${$} ` : '',
- 'item'
- )
- );
- }
- }
- class JsonSchemaArrayItemText extends Pe.Component {
- static defaultProps = os;
- onChange = (s) => {
- const o = s.target.value;
- this.props.onChange(o, this.props.keyName);
- };
- render() {
- let { value: s, errors: o, description: i, disabled: u } = this.props;
- return (
- s || (s = ''),
- (o = o.toJS ? o.toJS() : []),
- Pe.createElement(ss(), {
- type: 'text',
- className: o.length ? 'invalid' : '',
- title: o.length ? o : '',
- value: s,
- minLength: 0,
- debounceTimeout: 350,
- placeholder: i,
- onChange: this.onChange,
- disabled: u
- })
- );
- }
- }
- class JsonSchemaArrayItemFile extends Pe.Component {
- static defaultProps = os;
- onFileChange = (s) => {
- const o = s.target.files[0];
- this.props.onChange(o, this.props.keyName);
- };
- render() {
- let { getComponent: s, errors: o, disabled: i } = this.props;
- const u = s('Input'),
- _ = i || !('FormData' in window);
- return Pe.createElement(u, {
- type: 'file',
- className: o.length ? 'invalid' : '',
- title: o.length ? o : '',
- onChange: this.onFileChange,
- disabled: _
- });
- }
- }
- class JsonSchema_boolean extends Pe.Component {
- static defaultProps = os;
- onEnumChange = (s) => this.props.onChange(s);
- render() {
- let {
- getComponent: s,
- value: o,
- errors: i,
- schema: u,
- required: _,
- disabled: w
- } = this.props;
- i = i.toJS ? i.toJS() : [];
- let x = u && u.get ? u.get('enum') : null,
- C = !x || !_,
- j = !x && ['true', 'false'];
- const L = s('Select');
- return Pe.createElement(L, {
- className: i.length ? 'invalid' : '',
- title: i.length ? i : '',
- value: String(o),
- disabled: w,
- allowedValues: x ? [...x] : j,
- allowEmptyValue: C,
- onChange: this.onEnumChange
- });
- }
- }
- const stringifyObjectErrors = (s) =>
- s.map((s) => {
- const o = void 0 !== s.propKey ? s.propKey : s.index;
- let i = 'string' == typeof s ? s : 'string' == typeof s.error ? s.error : null;
- if (!o && i) return i;
- let u = s.error,
- _ = `/${s.propKey}`;
- for (; 'object' == typeof u; ) {
- const s = void 0 !== u.propKey ? u.propKey : u.index;
- if (void 0 === s) break;
- if (((_ += `/${s}`), !u.error)) break;
- u = u.error;
- }
- return `${_}: ${u}`;
- });
- class JsonSchema_object extends Pe.PureComponent {
- constructor() {
- super();
- }
- static defaultProps = os;
- onChange = (s) => {
- this.props.onChange(s);
- };
- handleOnChange = (s) => {
- const o = s.target.value;
- this.onChange(o);
- };
- render() {
- let { getComponent: s, value: o, errors: i, disabled: u } = this.props;
- const _ = s('TextArea');
- return (
- (i = i.toJS ? i.toJS() : Array.isArray(i) ? i : []),
- Pe.createElement(
- 'div',
- null,
- Pe.createElement(_, {
- className: Hn()({ invalid: i.length }),
- title: i.length ? stringifyObjectErrors(i).join(', ') : '',
- value: stringify(o),
- disabled: u,
- onChange: this.handleOnChange
- })
- )
- );
- }
- }
- function valueOrEmptyList(s) {
- return qe.List.isList(s) ? s : Array.isArray(s) ? (0, qe.fromJS)(s) : (0, qe.List)();
- }
- const json_schema_5 = () => ({
- components: {
- modelExample: model_example,
- ModelWrapper,
- ModelCollapse,
- Model,
- Models,
- EnumModel: enum_model,
- ObjectModel,
- ArrayModel,
- PrimitiveModel: Primitive,
- schemes: Schemes,
- SchemesContainer,
- ...z
- }
- });
- var as = __webpack_require__(19123),
- ls = __webpack_require__.n(as),
- cs = __webpack_require__(41859),
- us = __webpack_require__.n(cs),
- ps = __webpack_require__(62193),
- hs = __webpack_require__.n(ps);
- const shallowArrayEquals = (s) => (o) =>
- Array.isArray(s) &&
- Array.isArray(o) &&
- s.length === o.length &&
- s.every((s, i) => s === o[i]),
- list = (...s) => s;
- class Cache extends Map {
- delete(s) {
- const o = Array.from(this.keys()).find(shallowArrayEquals(s));
- return super.delete(o);
- }
- get(s) {
- const o = Array.from(this.keys()).find(shallowArrayEquals(s));
- return super.get(o);
- }
- has(s) {
- return -1 !== Array.from(this.keys()).findIndex(shallowArrayEquals(s));
- }
- }
- const utils_memoizeN = (s, o = list) => {
- const { Cache: i } = ut();
- ut().Cache = Cache;
- const u = ut()(s, o);
- return (ut().Cache = i), u;
- },
- ds = {
- string: (s) =>
- s.pattern
- ? ((s) => {
- try {
- return new (us())(s).gen();
- } catch (s) {
- return 'string';
- }
- })(s.pattern)
- : 'string',
- string_email: () => 'user@example.com',
- 'string_date-time': () => new Date().toISOString(),
- string_date: () => new Date().toISOString().substring(0, 10),
- string_uuid: () => '3fa85f64-5717-4562-b3fc-2c963f66afa6',
- string_hostname: () => 'example.com',
- string_ipv4: () => '198.51.100.42',
- string_ipv6: () => '2001:0db8:5b96:0000:0000:426f:8e17:642a',
- number: () => 0,
- number_float: () => 0,
- integer: () => 0,
- boolean: (s) => 'boolean' != typeof s.default || s.default
- },
- primitive = (s) => {
- s = objectify(s);
- let { type: o, format: i } = s,
- u = ds[`${o}_${i}`] || ds[o];
- return isFunc(u) ? u(s) : 'Unknown Type: ' + s.type;
- },
- sanitizeRef = (s) =>
- deeplyStripKey(s, '$$ref', (s) => 'string' == typeof s && s.indexOf('#') > -1),
- fs = ['maxProperties', 'minProperties'],
- ms = ['minItems', 'maxItems'],
- gs = ['minimum', 'maximum', 'exclusiveMinimum', 'exclusiveMaximum'],
- ys = ['minLength', 'maxLength'],
- mergeJsonSchema = (s, o, i = {}) => {
- const u = { ...s };
- if (
- (['example', 'default', 'enum', 'xml', 'type', ...fs, ...ms, ...gs, ...ys].forEach(
- (s) =>
- ((s) => {
- void 0 === u[s] && void 0 !== o[s] && (u[s] = o[s]);
- })(s)
- ),
- void 0 !== o.required &&
- Array.isArray(o.required) &&
- ((void 0 !== u.required && u.required.length) || (u.required = []),
- o.required.forEach((s) => {
- u.required.includes(s) || u.required.push(s);
- })),
- o.properties)
- ) {
- u.properties || (u.properties = {});
- let s = objectify(o.properties);
- for (let _ in s)
- Object.prototype.hasOwnProperty.call(s, _) &&
- ((s[_] && s[_].deprecated) ||
- (s[_] && s[_].readOnly && !i.includeReadOnly) ||
- (s[_] && s[_].writeOnly && !i.includeWriteOnly) ||
- u.properties[_] ||
- ((u.properties[_] = s[_]),
- !o.required &&
- Array.isArray(o.required) &&
- -1 !== o.required.indexOf(_) &&
- (u.required ? u.required.push(_) : (u.required = [_]))));
- }
- return (
- o.items &&
- (u.items || (u.items = {}), (u.items = mergeJsonSchema(u.items, o.items, i))),
- u
- );
- },
- sampleFromSchemaGeneric = (s, o = {}, i = void 0, u = !1) => {
- s && isFunc(s.toJS) && (s = s.toJS());
- let _ = void 0 !== i || (s && void 0 !== s.example) || (s && void 0 !== s.default);
- const w = !_ && s && s.oneOf && s.oneOf.length > 0,
- x = !_ && s && s.anyOf && s.anyOf.length > 0;
- if (!_ && (w || x)) {
- const i = objectify(w ? s.oneOf[0] : s.anyOf[0]);
- if (
- (!(s = mergeJsonSchema(s, i, o)).xml && i.xml && (s.xml = i.xml),
- void 0 !== s.example && void 0 !== i.example)
- )
- _ = !0;
- else if (i.properties) {
- s.properties || (s.properties = {});
- let u = objectify(i.properties);
- for (let _ in u)
- Object.prototype.hasOwnProperty.call(u, _) &&
- ((u[_] && u[_].deprecated) ||
- (u[_] && u[_].readOnly && !o.includeReadOnly) ||
- (u[_] && u[_].writeOnly && !o.includeWriteOnly) ||
- s.properties[_] ||
- ((s.properties[_] = u[_]),
- !i.required &&
- Array.isArray(i.required) &&
- -1 !== i.required.indexOf(_) &&
- (s.required ? s.required.push(_) : (s.required = [_]))));
- }
- }
- const C = {};
- let {
- xml: j,
- type: L,
- example: B,
- properties: $,
- additionalProperties: V,
- items: U
- } = s || {},
- { includeReadOnly: z, includeWriteOnly: Y } = o;
- j = j || {};
- let Z,
- { name: ee, prefix: ie, namespace: ae } = j,
- le = {};
- if (u && ((ee = ee || 'notagname'), (Z = (ie ? ie + ':' : '') + ee), ae)) {
- C[ie ? 'xmlns:' + ie : 'xmlns'] = ae;
- }
- u && (le[Z] = []);
- const schemaHasAny = (o) => o.some((o) => Object.prototype.hasOwnProperty.call(s, o));
- s &&
- !L &&
- ($ || V || schemaHasAny(fs)
- ? (L = 'object')
- : U || schemaHasAny(ms)
- ? (L = 'array')
- : schemaHasAny(gs)
- ? ((L = 'number'), (s.type = 'number'))
- : _ || s.enum || ((L = 'string'), (s.type = 'string')));
- const handleMinMaxItems = (o) => {
- if ((null != s?.maxItems && (o = o.slice(0, s?.maxItems)), null != s?.minItems)) {
- let i = 0;
- for (; o.length < s?.minItems; ) o.push(o[i++ % o.length]);
- }
- return o;
- },
- ce = objectify($);
- let pe,
- de = 0;
- const hasExceededMaxProperties = () =>
- s &&
- null !== s.maxProperties &&
- void 0 !== s.maxProperties &&
- de >= s.maxProperties,
- canAddProperty = (o) =>
- !s ||
- null === s.maxProperties ||
- void 0 === s.maxProperties ||
- (!hasExceededMaxProperties() &&
- (!((o) => !(s && s.required && s.required.length && s.required.includes(o)))(o) ||
- s.maxProperties -
- de -
- (() => {
- if (!s || !s.required) return 0;
- let o = 0;
- return (
- u
- ? s.required.forEach((s) => (o += void 0 === le[s] ? 0 : 1))
- : s.required.forEach(
- (s) => (o += void 0 === le[Z]?.find((o) => void 0 !== o[s]) ? 0 : 1)
- ),
- s.required.length - o
- );
- })() >
- 0));
- if (
- ((pe = u
- ? (i, _ = void 0) => {
- if (s && ce[i]) {
- if (((ce[i].xml = ce[i].xml || {}), ce[i].xml.attribute)) {
- const s = Array.isArray(ce[i].enum) ? ce[i].enum[0] : void 0,
- o = ce[i].example,
- u = ce[i].default;
- return void (C[ce[i].xml.name || i] =
- void 0 !== o
- ? o
- : void 0 !== u
- ? u
- : void 0 !== s
- ? s
- : primitive(ce[i]));
- }
- ce[i].xml.name = ce[i].xml.name || i;
- } else ce[i] || !1 === V || (ce[i] = { xml: { name: i } });
- let w = sampleFromSchemaGeneric((s && ce[i]) || void 0, o, _, u);
- canAddProperty(i) &&
- (de++, Array.isArray(w) ? (le[Z] = le[Z].concat(w)) : le[Z].push(w));
- }
- : (i, _) => {
- if (canAddProperty(i)) {
- if (
- Object.prototype.hasOwnProperty.call(s, 'discriminator') &&
- s.discriminator &&
- Object.prototype.hasOwnProperty.call(s.discriminator, 'mapping') &&
- s.discriminator.mapping &&
- Object.prototype.hasOwnProperty.call(s, '$$ref') &&
- s.$$ref &&
- s.discriminator.propertyName === i
- ) {
- for (let o in s.discriminator.mapping)
- if (-1 !== s.$$ref.search(s.discriminator.mapping[o])) {
- le[i] = o;
- break;
- }
- } else le[i] = sampleFromSchemaGeneric(ce[i], o, _, u);
- de++;
- }
- }),
- _)
- ) {
- let _;
- if (((_ = sanitizeRef(void 0 !== i ? i : void 0 !== B ? B : s.default)), !u)) {
- if ('number' == typeof _ && 'string' === L) return `${_}`;
- if ('string' != typeof _ || 'string' === L) return _;
- try {
- return JSON.parse(_);
- } catch (s) {
- return _;
- }
- }
- if ((s || (L = Array.isArray(_) ? 'array' : typeof _), 'array' === L)) {
- if (!Array.isArray(_)) {
- if ('string' == typeof _) return _;
- _ = [_];
- }
- const i = s ? s.items : void 0;
- i && ((i.xml = i.xml || j || {}), (i.xml.name = i.xml.name || j.name));
- let w = _.map((s) => sampleFromSchemaGeneric(i, o, s, u));
- return (
- (w = handleMinMaxItems(w)),
- j.wrapped ? ((le[Z] = w), hs()(C) || le[Z].push({ _attr: C })) : (le = w),
- le
- );
- }
- if ('object' === L) {
- if ('string' == typeof _) return _;
- for (let o in _)
- Object.prototype.hasOwnProperty.call(_, o) &&
- ((s && ce[o] && ce[o].readOnly && !z) ||
- (s && ce[o] && ce[o].writeOnly && !Y) ||
- (s && ce[o] && ce[o].xml && ce[o].xml.attribute
- ? (C[ce[o].xml.name || o] = _[o])
- : pe(o, _[o])));
- return hs()(C) || le[Z].push({ _attr: C }), le;
- }
- return (le[Z] = hs()(C) ? _ : [{ _attr: C }, _]), le;
- }
- if ('object' === L) {
- for (let s in ce)
- Object.prototype.hasOwnProperty.call(ce, s) &&
- ((ce[s] && ce[s].deprecated) ||
- (ce[s] && ce[s].readOnly && !z) ||
- (ce[s] && ce[s].writeOnly && !Y) ||
- pe(s));
- if ((u && C && le[Z].push({ _attr: C }), hasExceededMaxProperties())) return le;
- if (!0 === V)
- u
- ? le[Z].push({ additionalProp: 'Anything can be here' })
- : (le.additionalProp1 = {}),
- de++;
- else if (V) {
- const i = objectify(V),
- _ = sampleFromSchemaGeneric(i, o, void 0, u);
- if (u && i.xml && i.xml.name && 'notagname' !== i.xml.name) le[Z].push(_);
- else {
- const o =
- null !== s.minProperties && void 0 !== s.minProperties && de < s.minProperties
- ? s.minProperties - de
- : 3;
- for (let s = 1; s <= o; s++) {
- if (hasExceededMaxProperties()) return le;
- if (u) {
- const o = {};
- (o['additionalProp' + s] = _.notagname), le[Z].push(o);
- } else le['additionalProp' + s] = _;
- de++;
- }
- }
- }
- return le;
- }
- if ('array' === L) {
- if (!U) return;
- let i;
- if (
- (u && ((U.xml = U.xml || s?.xml || {}), (U.xml.name = U.xml.name || j.name)),
- Array.isArray(U.anyOf))
- )
- i = U.anyOf.map((s) =>
- sampleFromSchemaGeneric(mergeJsonSchema(s, U, o), o, void 0, u)
- );
- else if (Array.isArray(U.oneOf))
- i = U.oneOf.map((s) =>
- sampleFromSchemaGeneric(mergeJsonSchema(s, U, o), o, void 0, u)
- );
- else {
- if (!(!u || (u && j.wrapped))) return sampleFromSchemaGeneric(U, o, void 0, u);
- i = [sampleFromSchemaGeneric(U, o, void 0, u)];
- }
- return (
- (i = handleMinMaxItems(i)),
- u && j.wrapped ? ((le[Z] = i), hs()(C) || le[Z].push({ _attr: C }), le) : i
- );
- }
- let fe;
- if (s && Array.isArray(s.enum)) fe = normalizeArray(s.enum)[0];
- else {
- if (!s) return;
- if (((fe = primitive(s)), 'number' == typeof fe)) {
- let o = s.minimum;
- null != o && (s.exclusiveMinimum && o++, (fe = o));
- let i = s.maximum;
- null != i && (s.exclusiveMaximum && i--, (fe = i));
- }
- if (
- 'string' == typeof fe &&
- (null !== s.maxLength && void 0 !== s.maxLength && (fe = fe.slice(0, s.maxLength)),
- null !== s.minLength && void 0 !== s.minLength)
- ) {
- let o = 0;
- for (; fe.length < s.minLength; ) fe += fe[o++ % fe.length];
- }
- }
- if ('file' !== L) return u ? ((le[Z] = hs()(C) ? fe : [{ _attr: C }, fe]), le) : fe;
- },
- inferSchema = (s) => (s.schema && (s = s.schema), s.properties && (s.type = 'object'), s),
- createXMLExample = (s, o, i) => {
- const u = sampleFromSchemaGeneric(s, o, i, !0);
- if (u) return 'string' == typeof u ? u : ls()(u, { declaration: !0, indent: '\t' });
- },
- sampleFromSchema = (s, o, i) => sampleFromSchemaGeneric(s, o, i, !1),
- resolver = (s, o, i) => [s, JSON.stringify(o), JSON.stringify(i)],
- vs = utils_memoizeN(createXMLExample, resolver),
- bs = utils_memoizeN(sampleFromSchema, resolver),
- _s = [{ when: /json/, shouldStringifyTypes: ['string'] }],
- Es = ['object'],
- get_json_sample_schema = (s) => (o, i, u, _) => {
- const { fn: w } = s(),
- x = w.memoizedSampleFromSchema(o, i, _),
- C = typeof x,
- j = _s.reduce((s, o) => (o.when.test(u) ? [...s, ...o.shouldStringifyTypes] : s), Es);
- return mt()(j, (s) => s === C) ? JSON.stringify(x, null, 2) : x;
- },
- get_yaml_sample_schema = (s) => (o, i, u, _) => {
- const { fn: w } = s(),
- x = w.getJsonSampleSchema(o, i, u, _);
- let C;
- try {
- (C = mn.dump(mn.load(x), { lineWidth: -1 }, { schema: nn })),
- '\n' === C[C.length - 1] && (C = C.slice(0, C.length - 1));
- } catch (s) {
- return console.error(s), 'error: could not generate yaml example';
- }
- return C.replace(/\t/g, ' ');
- },
- get_xml_sample_schema = (s) => (o, i, u) => {
- const { fn: _ } = s();
- if ((o && !o.xml && (o.xml = {}), o && !o.xml.name)) {
- if (!o.$$ref && (o.type || o.items || o.properties || o.additionalProperties))
- return '<?xml version="1.0" encoding="UTF-8"?>\n\x3c!-- XML example cannot be generated; root element name is undefined --\x3e';
- if (o.$$ref) {
- let s = o.$$ref.match(/\S*\/(\S+)$/);
- o.xml.name = s[1];
- }
- }
- return _.memoizedCreateXMLExample(o, i, u);
- },
- get_sample_schema =
- (s) =>
- (o, i = '', u = {}, _ = void 0) => {
- const { fn: w } = s();
- return (
- 'function' == typeof o?.toJS && (o = o.toJS()),
- 'function' == typeof _?.toJS && (_ = _.toJS()),
- /xml/.test(i)
- ? w.getXmlSampleSchema(o, u, _)
- : /(yaml|yml)/.test(i)
- ? w.getYamlSampleSchema(o, u, i, _)
- : w.getJsonSampleSchema(o, u, i, _)
- );
- },
- json_schema_5_samples = ({ getSystem: s }) => {
- const o = get_json_sample_schema(s),
- i = get_yaml_sample_schema(s),
- u = get_xml_sample_schema(s),
- _ = get_sample_schema(s);
- return {
- fn: {
- jsonSchema5: {
- inferSchema,
- sampleFromSchema,
- sampleFromSchemaGeneric,
- createXMLExample,
- memoizedSampleFromSchema: bs,
- memoizedCreateXMLExample: vs,
- getJsonSampleSchema: o,
- getYamlSampleSchema: i,
- getXmlSampleSchema: u,
- getSampleSchema: _,
- mergeJsonSchema
- },
- inferSchema,
- sampleFromSchema,
- sampleFromSchemaGeneric,
- createXMLExample,
- memoizedSampleFromSchema: bs,
- memoizedCreateXMLExample: vs,
- getJsonSampleSchema: o,
- getYamlSampleSchema: i,
- getXmlSampleSchema: u,
- getSampleSchema: _,
- mergeJsonSchema
- }
- };
- };
- var ws = __webpack_require__(37334),
- Ss = __webpack_require__.n(ws);
- const xs = ['get', 'put', 'post', 'delete', 'options', 'head', 'patch', 'trace'],
- spec_selectors_state = (s) => s || (0, qe.Map)(),
- ks = Ut(spec_selectors_state, (s) => s.get('lastError')),
- Cs = Ut(spec_selectors_state, (s) => s.get('url')),
- Os = Ut(spec_selectors_state, (s) => s.get('spec') || ''),
- As = Ut(spec_selectors_state, (s) => s.get('specSource') || 'not-editor'),
- js = Ut(spec_selectors_state, (s) => s.get('json', (0, qe.Map)())),
- Is = Ut(js, (s) => s.toJS()),
- Ps = Ut(spec_selectors_state, (s) => s.get('resolved', (0, qe.Map)())),
- specResolvedSubtree = (s, o) => s.getIn(['resolvedSubtrees', ...o], void 0),
- mergerFn = (s, o) =>
- qe.Map.isMap(s) && qe.Map.isMap(o)
- ? o.get('$$ref')
- ? o
- : (0, qe.OrderedMap)().mergeWith(mergerFn, s, o)
- : o,
- Ms = Ut(spec_selectors_state, (s) =>
- (0, qe.OrderedMap)().mergeWith(mergerFn, s.get('json'), s.get('resolvedSubtrees'))
- ),
- spec = (s) => js(s),
- Ts = Ut(spec, () => !1),
- Ns = Ut(spec, (s) => returnSelfOrNewMap(s && s.get('info'))),
- Rs = Ut(spec, (s) => returnSelfOrNewMap(s && s.get('externalDocs'))),
- Ds = Ut(Ns, (s) => s && s.get('version')),
- Ls = Ut(Ds, (s) => /v?([0-9]*)\.([0-9]*)\.([0-9]*)/i.exec(s).slice(1)),
- Bs = Ut(Ms, (s) => s.get('paths')),
- Fs = Ss()(['get', 'put', 'post', 'delete', 'options', 'head', 'patch']),
- qs = Ut(Bs, (s) => {
- if (!s || s.size < 1) return (0, qe.List)();
- let o = (0, qe.List)();
- return s && s.forEach
- ? (s.forEach((s, i) => {
- if (!s || !s.forEach) return {};
- s.forEach((s, u) => {
- xs.indexOf(u) < 0 ||
- (o = o.push(
- (0, qe.fromJS)({ path: i, method: u, operation: s, id: `${u}-${i}` })
- ));
- });
- }),
- o)
- : (0, qe.List)();
- }),
- $s = Ut(spec, (s) => (0, qe.Set)(s.get('consumes'))),
- Vs = Ut(spec, (s) => (0, qe.Set)(s.get('produces'))),
- Us = Ut(spec, (s) => s.get('security', (0, qe.List)())),
- zs = Ut(spec, (s) => s.get('securityDefinitions')),
- findDefinition = (s, o) => {
- const i = s.getIn(['resolvedSubtrees', 'definitions', o], null),
- u = s.getIn(['json', 'definitions', o], null);
- return i || u || null;
- },
- Ws = Ut(spec, (s) => {
- const o = s.get('definitions');
- return qe.Map.isMap(o) ? o : (0, qe.Map)();
- }),
- Ks = Ut(spec, (s) => s.get('basePath')),
- Hs = Ut(spec, (s) => s.get('host')),
- Js = Ut(spec, (s) => s.get('schemes', (0, qe.Map)())),
- Gs = Ut([qs, $s, Vs], (s, o, i) =>
- s.map((s) =>
- s.update('operation', (s) => {
- if (s) {
- if (!qe.Map.isMap(s)) return;
- return s.withMutations(
- (s) => (
- s.get('consumes') || s.update('consumes', (s) => (0, qe.Set)(s).merge(o)),
- s.get('produces') || s.update('produces', (s) => (0, qe.Set)(s).merge(i)),
- s
- )
- );
- }
- return (0, qe.Map)();
- })
- )
- ),
- Ys = Ut(spec, (s) => {
- const o = s.get('tags', (0, qe.List)());
- return qe.List.isList(o) ? o.filter((s) => qe.Map.isMap(s)) : (0, qe.List)();
- }),
- tagDetails = (s, o) =>
- (Ys(s) || (0, qe.List)())
- .filter(qe.Map.isMap)
- .find((s) => s.get('name') === o, (0, qe.Map)()),
- Xs = Ut(Gs, Ys, (s, o) =>
- s.reduce(
- (s, o) => {
- let i = (0, qe.Set)(o.getIn(['operation', 'tags']));
- return i.count() < 1
- ? s.update('default', (0, qe.List)(), (s) => s.push(o))
- : i.reduce((s, i) => s.update(i, (0, qe.List)(), (s) => s.push(o)), s);
- },
- o.reduce((s, o) => s.set(o.get('name'), (0, qe.List)()), (0, qe.OrderedMap)())
- )
- ),
- selectors_taggedOperations =
- (s) =>
- ({ getConfigs: o }) => {
- let { tagsSorter: i, operationsSorter: u } = o();
- return Xs(s)
- .sortBy(
- (s, o) => o,
- (s, o) => {
- let u = 'function' == typeof i ? i : It.tagsSorter[i];
- return u ? u(s, o) : null;
- }
- )
- .map((o, i) => {
- let _ = 'function' == typeof u ? u : It.operationsSorter[u],
- w = _ ? o.sort(_) : o;
- return (0, qe.Map)({ tagDetails: tagDetails(s, i), operations: w });
- });
- },
- Zs = Ut(spec_selectors_state, (s) => s.get('responses', (0, qe.Map)())),
- Qs = Ut(spec_selectors_state, (s) => s.get('requests', (0, qe.Map)())),
- eo = Ut(spec_selectors_state, (s) => s.get('mutatedRequests', (0, qe.Map)())),
- responseFor = (s, o, i) => Zs(s).getIn([o, i], null),
- requestFor = (s, o, i) => Qs(s).getIn([o, i], null),
- mutatedRequestFor = (s, o, i) => eo(s).getIn([o, i], null),
- allowTryItOutFor = () => !0,
- parameterWithMetaByIdentity = (s, o, i) => {
- const u = Ms(s).getIn(['paths', ...o, 'parameters'], (0, qe.OrderedMap)()),
- _ = s.getIn(['meta', 'paths', ...o, 'parameters'], (0, qe.OrderedMap)());
- return u
- .map((s) => {
- const o = _.get(`${i.get('in')}.${i.get('name')}`),
- u = _.get(`${i.get('in')}.${i.get('name')}.hash-${i.hashCode()}`);
- return (0, qe.OrderedMap)().merge(s, o, u);
- })
- .find(
- (s) => s.get('in') === i.get('in') && s.get('name') === i.get('name'),
- (0, qe.OrderedMap)()
- );
- },
- parameterInclusionSettingFor = (s, o, i, u) => {
- const _ = `${u}.${i}`;
- return s.getIn(['meta', 'paths', ...o, 'parameter_inclusions', _], !1);
- },
- parameterWithMeta = (s, o, i, u) => {
- const _ = Ms(s)
- .getIn(['paths', ...o, 'parameters'], (0, qe.OrderedMap)())
- .find((s) => s.get('in') === u && s.get('name') === i, (0, qe.OrderedMap)());
- return parameterWithMetaByIdentity(s, o, _);
- },
- operationWithMeta = (s, o, i) => {
- const u = Ms(s).getIn(['paths', o, i], (0, qe.OrderedMap)()),
- _ = s.getIn(['meta', 'paths', o, i], (0, qe.OrderedMap)()),
- w = u
- .get('parameters', (0, qe.List)())
- .map((u) => parameterWithMetaByIdentity(s, [o, i], u));
- return (0, qe.OrderedMap)().merge(u, _).set('parameters', w);
- };
- function getParameter(s, o, i, u) {
- return (
- (o = o || []),
- s
- .getIn(['meta', 'paths', ...o, 'parameters'], (0, qe.fromJS)([]))
- .find((s) => qe.Map.isMap(s) && s.get('name') === i && s.get('in') === u) ||
- (0, qe.Map)()
- );
- }
- const to = Ut(spec, (s) => {
- const o = s.get('host');
- return 'string' == typeof o && o.length > 0 && '/' !== o[0];
- });
- function parameterValues(s, o, i) {
- return (
- (o = o || []),
- operationWithMeta(s, ...o)
- .get('parameters', (0, qe.List)())
- .reduce(
- (s, o) => {
- let u = i && 'body' === o.get('in') ? o.get('value_xml') : o.get('value');
- return (
- qe.List.isList(u) && (u = u.filter((s) => '' !== s)),
- s.set(paramToIdentifier(o, { allowHashes: !1 }), u)
- );
- },
- (0, qe.fromJS)({})
- )
- );
- }
- function parametersIncludeIn(s, o = '') {
- if (qe.List.isList(s)) return s.some((s) => qe.Map.isMap(s) && s.get('in') === o);
- }
- function parametersIncludeType(s, o = '') {
- if (qe.List.isList(s)) return s.some((s) => qe.Map.isMap(s) && s.get('type') === o);
- }
- function contentTypeValues(s, o) {
- o = o || [];
- let i = Ms(s).getIn(['paths', ...o], (0, qe.fromJS)({})),
- u = s.getIn(['meta', 'paths', ...o], (0, qe.fromJS)({})),
- _ = currentProducesFor(s, o);
- const w = i.get('parameters') || new qe.List(),
- x = u.get('consumes_value')
- ? u.get('consumes_value')
- : parametersIncludeType(w, 'file')
- ? 'multipart/form-data'
- : parametersIncludeType(w, 'formData')
- ? 'application/x-www-form-urlencoded'
- : void 0;
- return (0, qe.fromJS)({ requestContentType: x, responseContentType: _ });
- }
- function currentProducesFor(s, o) {
- o = o || [];
- const i = Ms(s).getIn(['paths', ...o], null);
- if (null === i) return;
- const u = s.getIn(['meta', 'paths', ...o, 'produces_value'], null),
- _ = i.getIn(['produces', 0], null);
- return u || _ || 'application/json';
- }
- function producesOptionsFor(s, o) {
- o = o || [];
- const i = Ms(s),
- u = i.getIn(['paths', ...o], null);
- if (null === u) return;
- const [_] = o,
- w = u.get('produces', null),
- x = i.getIn(['paths', _, 'produces'], null),
- C = i.getIn(['produces'], null);
- return w || x || C;
- }
- function consumesOptionsFor(s, o) {
- o = o || [];
- const i = Ms(s),
- u = i.getIn(['paths', ...o], null);
- if (null === u) return;
- const [_] = o,
- w = u.get('consumes', null),
- x = i.getIn(['paths', _, 'consumes'], null),
- C = i.getIn(['consumes'], null);
- return w || x || C;
- }
- const operationScheme = (s, o, i) => {
- let u = s.get('url').match(/^([a-z][a-z0-9+\-.]*):/),
- _ = Array.isArray(u) ? u[1] : null;
- return s.getIn(['scheme', o, i]) || s.getIn(['scheme', '_defaultScheme']) || _ || '';
- },
- canExecuteScheme = (s, o, i) => ['http', 'https'].indexOf(operationScheme(s, o, i)) > -1,
- validationErrors = (s, o) => {
- o = o || [];
- const i = s.getIn(['meta', 'paths', ...o, 'parameters'], (0, qe.fromJS)([])),
- u = [];
- if (0 === i.length) return u;
- const getErrorsWithPaths = (s, o = []) => {
- const getNestedErrorsWithPaths = (s, o) => {
- const i = [...o, s.get('propKey') || s.get('index')];
- return qe.Map.isMap(s.get('error'))
- ? getErrorsWithPaths(s.get('error'), i)
- : { error: s.get('error'), path: i };
- };
- return qe.List.isList(s)
- ? s.map((s) =>
- qe.Map.isMap(s) ? getNestedErrorsWithPaths(s, o) : { error: s, path: o }
- )
- : getNestedErrorsWithPaths(s, o);
- };
- return (
- i.forEach((s, o) => {
- const i = o.split('.').slice(1, -1).join('.'),
- _ = s.get('errors');
- if (_ && _.count()) {
- getErrorsWithPaths(_).forEach(({ error: s, path: o }) => {
- u.push(
- ((s, o, i) =>
- `For '${i}'${(o = o.reduce((s, o) => ('number' == typeof o ? `${s}[${o}]` : s ? `${s}.${o}` : o), '')) ? ` at path '${o}'` : ''}: ${s}.`)(
- s,
- o,
- i
- )
- );
- });
- }
- }),
- u
- );
- },
- validateBeforeExecute = (s, o) => 0 === validationErrors(s, o).length,
- getOAS3RequiredRequestBodyContentType = (s, o) => {
- let i = { requestBody: !1, requestContentType: {} },
- u = s.getIn(['resolvedSubtrees', 'paths', ...o, 'requestBody'], (0, qe.fromJS)([]));
- return (
- u.size < 1 ||
- (u.getIn(['required']) && (i.requestBody = u.getIn(['required'])),
- u
- .getIn(['content'])
- .entrySeq()
- .forEach((s) => {
- const o = s[0];
- if (s[1].getIn(['schema', 'required'])) {
- const u = s[1].getIn(['schema', 'required']).toJS();
- i.requestContentType[o] = u;
- }
- })),
- i
- );
- },
- isMediaTypeSchemaPropertiesEqual = (s, o, i, u) => {
- if ((i || u) && i === u) return !0;
- let _ = s.getIn(
- ['resolvedSubtrees', 'paths', ...o, 'requestBody', 'content'],
- (0, qe.fromJS)([])
- );
- if (_.size < 2 || !i || !u) return !1;
- let w = _.getIn([i, 'schema', 'properties'], (0, qe.fromJS)([])),
- x = _.getIn([u, 'schema', 'properties'], (0, qe.fromJS)([]));
- return !!w.equals(x);
- };
- function returnSelfOrNewMap(s) {
- return qe.Map.isMap(s) ? s : new qe.Map();
- }
- var ro = __webpack_require__(85015),
- no = __webpack_require__.n(ro),
- so = __webpack_require__(38221),
- oo = __webpack_require__.n(so),
- io = __webpack_require__(63560),
- ao = __webpack_require__.n(io),
- lo = __webpack_require__(56367),
- co = __webpack_require__.n(lo);
- const uo = 'spec_update_spec',
- po = 'spec_update_url',
- ho = 'spec_update_json',
- fo = 'spec_update_param',
- mo = 'spec_update_empty_param_inclusion',
- go = 'spec_validate_param',
- yo = 'spec_set_response',
- vo = 'spec_set_request',
- bo = 'spec_set_mutated_request',
- _o = 'spec_log_request',
- Eo = 'spec_clear_response',
- wo = 'spec_clear_request',
- So = 'spec_clear_validate_param',
- xo = 'spec_update_operation_meta_value',
- ko = 'spec_update_resolved',
- Co = 'spec_update_resolved_subtree',
- Oo = 'set_scheme',
- toStr = (s) => (no()(s) ? s : '');
- function updateSpec(s) {
- const o = toStr(s).replace(/\t/g, ' ');
- if ('string' == typeof s) return { type: uo, payload: o };
- }
- function updateResolved(s) {
- return { type: ko, payload: s };
- }
- function updateUrl(s) {
- return { type: po, payload: s };
- }
- function updateJsonSpec(s) {
- return { type: ho, payload: s };
- }
- const parseToJson =
- (s) =>
- ({ specActions: o, specSelectors: i, errActions: u }) => {
- let { specStr: _ } = i,
- w = null;
- try {
- (s = s || _()), u.clear({ source: 'parser' }), (w = mn.load(s, { schema: nn }));
- } catch (s) {
- return (
- console.error(s),
- u.newSpecErr({
- source: 'parser',
- level: 'error',
- message: s.reason,
- line: s.mark && s.mark.line ? s.mark.line + 1 : void 0
- })
- );
- }
- return w && 'object' == typeof w ? o.updateJsonSpec(w) : {};
- };
- let Ao = !1;
- const resolveSpec =
- (s, o) =>
- ({
- specActions: i,
- specSelectors: u,
- errActions: _,
- fn: { fetch: w, resolve: x, AST: C = {} },
- getConfigs: j
- }) => {
- Ao ||
- (console.warn(
- 'specActions.resolveSpec is deprecated since v3.10.0 and will be removed in v4.0.0; use requestResolvedSubtree instead!'
- ),
- (Ao = !0));
- const {
- modelPropertyMacro: L,
- parameterMacro: B,
- requestInterceptor: $,
- responseInterceptor: V
- } = j();
- void 0 === s && (s = u.specJson()), void 0 === o && (o = u.url());
- let U = C.getLineNumberForPath ? C.getLineNumberForPath : () => {},
- z = u.specStr();
- return x({
- fetch: w,
- spec: s,
- baseDoc: String(new URL(o, document.baseURI)),
- modelPropertyMacro: L,
- parameterMacro: B,
- requestInterceptor: $,
- responseInterceptor: V
- }).then(({ spec: s, errors: o }) => {
- if ((_.clear({ type: 'thrown' }), Array.isArray(o) && o.length > 0)) {
- let s = o.map(
- (s) => (
- console.error(s),
- (s.line = s.fullPath ? U(z, s.fullPath) : null),
- (s.path = s.fullPath ? s.fullPath.join('.') : null),
- (s.level = 'error'),
- (s.type = 'thrown'),
- (s.source = 'resolver'),
- Object.defineProperty(s, 'message', { enumerable: !0, value: s.message }),
- s
- )
- );
- _.newThrownErrBatch(s);
- }
- return i.updateResolved(s);
- });
- };
- let jo = [];
- const Io = oo()(() => {
- const s = jo.reduce(
- (s, { path: o, system: i }) => (s.has(i) || s.set(i, []), s.get(i).push(o), s),
- new Map()
- );
- (jo = []),
- s.forEach(async (s, o) => {
- if (!o)
- return void console.error(
- "debResolveSubtrees: don't have a system to operate on, aborting."
- );
- if (!o.fn.resolveSubtree)
- return void console.error(
- 'Error: Swagger-Client did not provide a `resolveSubtree` method, doing nothing.'
- );
- const {
- errActions: i,
- errSelectors: u,
- fn: { resolveSubtree: _, fetch: w, AST: x = {} },
- specSelectors: C,
- specActions: j
- } = o,
- L = x.getLineNumberForPath ?? Ss()(void 0),
- B = C.specStr(),
- {
- modelPropertyMacro: $,
- parameterMacro: V,
- requestInterceptor: U,
- responseInterceptor: z
- } = o.getConfigs();
- try {
- const o = await s.reduce(
- async (s, o) => {
- let { resultMap: x, specWithCurrentSubtrees: j } = await s;
- const { errors: Y, spec: Z } = await _(j, o, {
- baseDoc: String(new URL(C.url(), document.baseURI)),
- modelPropertyMacro: $,
- parameterMacro: V,
- requestInterceptor: U,
- responseInterceptor: z
- });
- if (
- (u.allErrors().size &&
- i.clearBy(
- (s) =>
- 'thrown' !== s.get('type') ||
- 'resolver' !== s.get('source') ||
- !s.get('fullPath').every((s, i) => s === o[i] || void 0 === o[i])
- ),
- Array.isArray(Y) && Y.length > 0)
- ) {
- let s = Y.map(
- (s) => (
- (s.line = s.fullPath ? L(B, s.fullPath) : null),
- (s.path = s.fullPath ? s.fullPath.join('.') : null),
- (s.level = 'error'),
- (s.type = 'thrown'),
- (s.source = 'resolver'),
- Object.defineProperty(s, 'message', {
- enumerable: !0,
- value: s.message
- }),
- s
- )
- );
- i.newThrownErrBatch(s);
- }
- return (
- Z &&
- C.isOAS3() &&
- 'components' === o[0] &&
- 'securitySchemes' === o[1] &&
- (await Promise.all(
- Object.values(Z)
- .filter((s) => 'openIdConnect' === s.type)
- .map(async (s) => {
- const o = {
- url: s.openIdConnectUrl,
- requestInterceptor: U,
- responseInterceptor: z
- };
- try {
- const i = await w(o);
- i instanceof Error || i.status >= 400
- ? console.error(i.statusText + ' ' + o.url)
- : (s.openIdConnectData = JSON.parse(i.text));
- } catch (s) {
- console.error(s);
- }
- })
- )),
- ao()(x, o, Z),
- (j = co()(o, Z, j)),
- { resultMap: x, specWithCurrentSubtrees: j }
- );
- },
- Promise.resolve({
- resultMap: (C.specResolvedSubtree([]) || (0, qe.Map)()).toJS(),
- specWithCurrentSubtrees: C.specJS()
- })
- );
- j.updateResolvedSubtree([], o.resultMap);
- } catch (s) {
- console.error(s);
- }
- });
- }, 35),
- requestResolvedSubtree = (s) => (o) => {
- jo.find(({ path: i, system: u }) => u === o && i.toString() === s.toString()) ||
- (jo.push({ path: s, system: o }), Io());
- };
- function changeParam(s, o, i, u, _) {
- return { type: fo, payload: { path: s, value: u, paramName: o, paramIn: i, isXml: _ } };
- }
- function changeParamByIdentity(s, o, i, u) {
- return { type: fo, payload: { path: s, param: o, value: i, isXml: u } };
- }
- const updateResolvedSubtree = (s, o) => ({ type: Co, payload: { path: s, value: o } }),
- invalidateResolvedSubtreeCache = () => ({
- type: Co,
- payload: { path: [], value: (0, qe.Map)() }
- }),
- validateParams = (s, o) => ({ type: go, payload: { pathMethod: s, isOAS3: o } }),
- updateEmptyParamInclusion = (s, o, i, u) => ({
- type: mo,
- payload: { pathMethod: s, paramName: o, paramIn: i, includeEmptyValue: u }
- });
- function clearValidateParams(s) {
- return { type: So, payload: { pathMethod: s } };
- }
- function changeConsumesValue(s, o) {
- return { type: xo, payload: { path: s, value: o, key: 'consumes_value' } };
- }
- function changeProducesValue(s, o) {
- return { type: xo, payload: { path: s, value: o, key: 'produces_value' } };
- }
- const setResponse = (s, o, i) => ({ payload: { path: s, method: o, res: i }, type: yo }),
- setRequest = (s, o, i) => ({ payload: { path: s, method: o, req: i }, type: vo }),
- setMutatedRequest = (s, o, i) => ({ payload: { path: s, method: o, req: i }, type: bo }),
- logRequest = (s) => ({ payload: s, type: _o }),
- executeRequest =
- (s) =>
- ({ fn: o, specActions: i, specSelectors: u, getConfigs: _, oas3Selectors: w }) => {
- let { pathName: x, method: C, operation: j } = s,
- { requestInterceptor: L, responseInterceptor: B } = _(),
- $ = j.toJS();
- if (
- (j &&
- j.get('parameters') &&
- j
- .get('parameters')
- .filter((s) => s && !0 === s.get('allowEmptyValue'))
- .forEach((o) => {
- if (u.parameterInclusionSettingFor([x, C], o.get('name'), o.get('in'))) {
- s.parameters = s.parameters || {};
- const i = paramToValue(o, s.parameters);
- (!i || (i && 0 === i.size)) && (s.parameters[o.get('name')] = '');
- }
- }),
- (s.contextUrl = Mt()(u.url()).toString()),
- $ && $.operationId
- ? (s.operationId = $.operationId)
- : $ && x && C && (s.operationId = o.opId($, x, C)),
- u.isOAS3())
- ) {
- const o = `${x}:${C}`;
- s.server = w.selectedServer(o) || w.selectedServer();
- const i = w.serverVariables({ server: s.server, namespace: o }).toJS(),
- u = w.serverVariables({ server: s.server }).toJS();
- (s.serverVariables = Object.keys(i).length ? i : u),
- (s.requestContentType = w.requestContentType(x, C)),
- (s.responseContentType = w.responseContentType(x, C) || '*/*');
- const _ = w.requestBodyValue(x, C),
- j = w.requestBodyInclusionSetting(x, C);
- _ && _.toJS
- ? (s.requestBody = _.map((s) => (qe.Map.isMap(s) ? s.get('value') : s))
- .filter(
- (s, o) => (Array.isArray(s) ? 0 !== s.length : !isEmptyValue(s)) || j.get(o)
- )
- .toJS())
- : (s.requestBody = _);
- }
- let V = Object.assign({}, s);
- (V = o.buildRequest(V)), i.setRequest(s.pathName, s.method, V);
- (s.requestInterceptor = async (o) => {
- let u = await L.apply(void 0, [o]),
- _ = Object.assign({}, u);
- return i.setMutatedRequest(s.pathName, s.method, _), u;
- }),
- (s.responseInterceptor = B);
- const U = Date.now();
- return o
- .execute(s)
- .then((o) => {
- (o.duration = Date.now() - U), i.setResponse(s.pathName, s.method, o);
- })
- .catch((o) => {
- 'Failed to fetch' === o.message &&
- ((o.name = ''),
- (o.message =
- '**Failed to fetch.** \n**Possible Reasons:** \n - CORS \n - Network Failure \n - URL scheme must be "http" or "https" for CORS request.')),
- i.setResponse(s.pathName, s.method, { error: !0, err: o });
- });
- },
- actions_execute =
- ({ path: s, method: o, ...i } = {}) =>
- (u) => {
- let {
- fn: { fetch: _ },
- specSelectors: w,
- specActions: x
- } = u,
- C = w.specJsonWithResolvedSubtrees().toJS(),
- j = w.operationScheme(s, o),
- { requestContentType: L, responseContentType: B } = w
- .contentTypeValues([s, o])
- .toJS(),
- $ = /xml/i.test(L),
- V = w.parameterValues([s, o], $).toJS();
- return x.executeRequest({
- ...i,
- fetch: _,
- spec: C,
- pathName: s,
- method: o,
- parameters: V,
- requestContentType: L,
- scheme: j,
- responseContentType: B
- });
- };
- function clearResponse(s, o) {
- return { type: Eo, payload: { path: s, method: o } };
- }
- function clearRequest(s, o) {
- return { type: wo, payload: { path: s, method: o } };
- }
- function setScheme(s, o, i) {
- return { type: Oo, payload: { scheme: s, path: o, method: i } };
- }
- const Po = {
- [uo]: (s, o) => ('string' == typeof o.payload ? s.set('spec', o.payload) : s),
- [po]: (s, o) => s.set('url', o.payload + ''),
- [ho]: (s, o) => s.set('json', fromJSOrdered(o.payload)),
- [ko]: (s, o) => s.setIn(['resolved'], fromJSOrdered(o.payload)),
- [Co]: (s, o) => {
- const { value: i, path: u } = o.payload;
- return s.setIn(['resolvedSubtrees', ...u], fromJSOrdered(i));
- },
- [fo]: (s, { payload: o }) => {
- let { path: i, paramName: u, paramIn: _, param: w, value: x, isXml: C } = o,
- j = w ? paramToIdentifier(w) : `${_}.${u}`;
- const L = C ? 'value_xml' : 'value';
- return s.setIn(['meta', 'paths', ...i, 'parameters', j, L], (0, qe.fromJS)(x));
- },
- [mo]: (s, { payload: o }) => {
- let { pathMethod: i, paramName: u, paramIn: _, includeEmptyValue: w } = o;
- if (!u || !_)
- return (
- console.warn(
- 'Warning: UPDATE_EMPTY_PARAM_INCLUSION could not generate a paramKey.'
- ),
- s
- );
- const x = `${_}.${u}`;
- return s.setIn(['meta', 'paths', ...i, 'parameter_inclusions', x], w);
- },
- [go]: (s, { payload: { pathMethod: o, isOAS3: i } }) => {
- const u = Ms(s).getIn(['paths', ...o]),
- _ = parameterValues(s, o).toJS();
- return s.updateIn(['meta', 'paths', ...o, 'parameters'], (0, qe.fromJS)({}), (w) =>
- u.get('parameters', (0, qe.List)()).reduce((u, w) => {
- const x = paramToValue(w, _),
- C = parameterInclusionSettingFor(s, o, w.get('name'), w.get('in')),
- j = ((s, o, { isOAS3: i = !1, bypassRequiredCheck: u = !1 } = {}) => {
- let _ = s.get('required'),
- { schema: w, parameterContentMediaType: x } = getParameterSchema(s, {
- isOAS3: i
- });
- return validateValueBySchema(o, w, _, u, x);
- })(w, x, { bypassRequiredCheck: C, isOAS3: i });
- return u.setIn([paramToIdentifier(w), 'errors'], (0, qe.fromJS)(j));
- }, w)
- );
- },
- [So]: (s, { payload: { pathMethod: o } }) =>
- s.updateIn(['meta', 'paths', ...o, 'parameters'], (0, qe.fromJS)([]), (s) =>
- s.map((s) => s.set('errors', (0, qe.fromJS)([])))
- ),
- [yo]: (s, { payload: { res: o, path: i, method: u } }) => {
- let _;
- (_ = o.error
- ? Object.assign(
- {
- error: !0,
- name: o.err.name,
- message: o.err.message,
- statusCode: o.err.statusCode
- },
- o.err.response
- )
- : o),
- (_.headers = _.headers || {});
- let w = s.setIn(['responses', i, u], fromJSOrdered(_));
- return (
- at.Blob &&
- _.data instanceof at.Blob &&
- (w = w.setIn(['responses', i, u, 'text'], _.data)),
- w
- );
- },
- [vo]: (s, { payload: { req: o, path: i, method: u } }) =>
- s.setIn(['requests', i, u], fromJSOrdered(o)),
- [bo]: (s, { payload: { req: o, path: i, method: u } }) =>
- s.setIn(['mutatedRequests', i, u], fromJSOrdered(o)),
- [xo]: (s, { payload: { path: o, value: i, key: u } }) => {
- let _ = ['paths', ...o],
- w = ['meta', 'paths', ...o];
- return s.getIn(['json', ..._]) ||
- s.getIn(['resolved', ..._]) ||
- s.getIn(['resolvedSubtrees', ..._])
- ? s.setIn([...w, u], (0, qe.fromJS)(i))
- : s;
- },
- [Eo]: (s, { payload: { path: o, method: i } }) => s.deleteIn(['responses', o, i]),
- [wo]: (s, { payload: { path: o, method: i } }) => s.deleteIn(['requests', o, i]),
- [Oo]: (s, { payload: { scheme: o, path: i, method: u } }) =>
- i && u
- ? s.setIn(['scheme', i, u], o)
- : i || u
- ? void 0
- : s.setIn(['scheme', '_defaultScheme'], o)
- },
- wrap_actions_updateSpec =
- (s, { specActions: o }) =>
- (...i) => {
- s(...i), o.parseToJson(...i);
- },
- wrap_actions_updateJsonSpec =
- (s, { specActions: o }) =>
- (...i) => {
- s(...i), o.invalidateResolvedSubtreeCache();
- const [u] = i,
- _ = jn()(u, ['paths']) || {};
- Object.keys(_).forEach((s) => {
- jn()(_, [s]).$ref && o.requestResolvedSubtree(['paths', s]);
- }),
- o.requestResolvedSubtree(['components', 'securitySchemes']);
- },
- wrap_actions_executeRequest =
- (s, { specActions: o }) =>
- (i) => (o.logRequest(i), s(i)),
- wrap_actions_validateParams =
- (s, { specSelectors: o }) =>
- (i) =>
- s(i, o.isOAS3()),
- plugins_spec = () => ({
- statePlugins: {
- spec: {
- wrapActions: { ...ee },
- reducers: { ...Po },
- actions: { ...Z },
- selectors: { ...Y }
- }
- }
- });
- var Mo = (function () {
- var extendStatics = function (s, o) {
- return (
- (extendStatics =
- Object.setPrototypeOf ||
- ({ __proto__: [] } instanceof Array &&
- function (s, o) {
- s.__proto__ = o;
- }) ||
- function (s, o) {
- for (var i in o) o.hasOwnProperty(i) && (s[i] = o[i]);
- }),
- extendStatics(s, o)
- );
- };
- return function (s, o) {
- function __() {
- this.constructor = s;
- }
- extendStatics(s, o),
- (s.prototype =
- null === o ? Object.create(o) : ((__.prototype = o.prototype), new __()));
- };
- })(),
- To = Object.prototype.hasOwnProperty;
- function module_helpers_hasOwnProperty(s, o) {
- return To.call(s, o);
- }
- function _objectKeys(s) {
- if (Array.isArray(s)) {
- for (var o = new Array(s.length), i = 0; i < o.length; i++) o[i] = '' + i;
- return o;
- }
- if (Object.keys) return Object.keys(s);
- var u = [];
- for (var _ in s) module_helpers_hasOwnProperty(s, _) && u.push(_);
- return u;
- }
- function _deepClone(s) {
- switch (typeof s) {
- case 'object':
- return JSON.parse(JSON.stringify(s));
- case 'undefined':
- return null;
- default:
- return s;
- }
- }
- function helpers_isInteger(s) {
- for (var o, i = 0, u = s.length; i < u; ) {
- if (!((o = s.charCodeAt(i)) >= 48 && o <= 57)) return !1;
- i++;
- }
- return !0;
- }
- function escapePathComponent(s) {
- return -1 === s.indexOf('/') && -1 === s.indexOf('~')
- ? s
- : s.replace(/~/g, '~0').replace(/\//g, '~1');
- }
- function unescapePathComponent(s) {
- return s.replace(/~1/g, '/').replace(/~0/g, '~');
- }
- function hasUndefined(s) {
- if (void 0 === s) return !0;
- if (s)
- if (Array.isArray(s)) {
- for (var o = 0, i = s.length; o < i; o++) if (hasUndefined(s[o])) return !0;
- } else if ('object' == typeof s)
- for (var u = _objectKeys(s), _ = u.length, w = 0; w < _; w++)
- if (hasUndefined(s[u[w]])) return !0;
- return !1;
- }
- function patchErrorMessageFormatter(s, o) {
- var i = [s];
- for (var u in o) {
- var _ = 'object' == typeof o[u] ? JSON.stringify(o[u], null, 2) : o[u];
- void 0 !== _ && i.push(u + ': ' + _);
- }
- return i.join('\n');
- }
- var No = (function (s) {
- function PatchError(o, i, u, _, w) {
- var x = this.constructor,
- C =
- s.call(
- this,
- patchErrorMessageFormatter(o, { name: i, index: u, operation: _, tree: w })
- ) || this;
- return (
- (C.name = i),
- (C.index = u),
- (C.operation = _),
- (C.tree = w),
- Object.setPrototypeOf(C, x.prototype),
- (C.message = patchErrorMessageFormatter(o, {
- name: i,
- index: u,
- operation: _,
- tree: w
- })),
- C
- );
- }
- return Mo(PatchError, s), PatchError;
- })(Error),
- Ro = No,
- Do = _deepClone,
- Lo = {
- add: function (s, o, i) {
- return (s[o] = this.value), { newDocument: i };
- },
- remove: function (s, o, i) {
- var u = s[o];
- return delete s[o], { newDocument: i, removed: u };
- },
- replace: function (s, o, i) {
- var u = s[o];
- return (s[o] = this.value), { newDocument: i, removed: u };
- },
- move: function (s, o, i) {
- var u = getValueByPointer(i, this.path);
- u && (u = _deepClone(u));
- var _ = applyOperation(i, { op: 'remove', path: this.from }).removed;
- return (
- applyOperation(i, { op: 'add', path: this.path, value: _ }),
- { newDocument: i, removed: u }
- );
- },
- copy: function (s, o, i) {
- var u = getValueByPointer(i, this.from);
- return (
- applyOperation(i, { op: 'add', path: this.path, value: _deepClone(u) }),
- { newDocument: i }
- );
- },
- test: function (s, o, i) {
- return { newDocument: i, test: _areEquals(s[o], this.value) };
- },
- _get: function (s, o, i) {
- return (this.value = s[o]), { newDocument: i };
- }
- },
- Bo = {
- add: function (s, o, i) {
- return (
- helpers_isInteger(o) ? s.splice(o, 0, this.value) : (s[o] = this.value),
- { newDocument: i, index: o }
- );
- },
- remove: function (s, o, i) {
- return { newDocument: i, removed: s.splice(o, 1)[0] };
- },
- replace: function (s, o, i) {
- var u = s[o];
- return (s[o] = this.value), { newDocument: i, removed: u };
- },
- move: Lo.move,
- copy: Lo.copy,
- test: Lo.test,
- _get: Lo._get
- };
- function getValueByPointer(s, o) {
- if ('' == o) return s;
- var i = { op: '_get', path: o };
- return applyOperation(s, i), i.value;
- }
- function applyOperation(s, o, i, u, _, w) {
- if (
- (void 0 === i && (i = !1),
- void 0 === u && (u = !0),
- void 0 === _ && (_ = !0),
- void 0 === w && (w = 0),
- i && ('function' == typeof i ? i(o, 0, s, o.path) : validator(o, 0)),
- '' === o.path)
- ) {
- var x = { newDocument: s };
- if ('add' === o.op) return (x.newDocument = o.value), x;
- if ('replace' === o.op) return (x.newDocument = o.value), (x.removed = s), x;
- if ('move' === o.op || 'copy' === o.op)
- return (
- (x.newDocument = getValueByPointer(s, o.from)),
- 'move' === o.op && (x.removed = s),
- x
- );
- if ('test' === o.op) {
- if (((x.test = _areEquals(s, o.value)), !1 === x.test))
- throw new Ro('Test operation failed', 'TEST_OPERATION_FAILED', w, o, s);
- return (x.newDocument = s), x;
- }
- if ('remove' === o.op) return (x.removed = s), (x.newDocument = null), x;
- if ('_get' === o.op) return (o.value = s), x;
- if (i)
- throw new Ro(
- 'Operation `op` property is not one of operations defined in RFC-6902',
- 'OPERATION_OP_INVALID',
- w,
- o,
- s
- );
- return x;
- }
- u || (s = _deepClone(s));
- var C = (o.path || '').split('/'),
- j = s,
- L = 1,
- B = C.length,
- $ = void 0,
- V = void 0,
- U = void 0;
- for (U = 'function' == typeof i ? i : validator; ; ) {
- if (
- ((V = C[L]) && -1 != V.indexOf('~') && (V = unescapePathComponent(V)),
- _ && ('__proto__' == V || ('prototype' == V && L > 0 && 'constructor' == C[L - 1])))
- )
- throw new TypeError(
- 'JSON-Patch: modifying `__proto__` or `constructor/prototype` prop is banned for security reasons, if this was on purpose, please set `banPrototypeModifications` flag false and pass it to this function. More info in fast-json-patch README'
- );
- if (
- (i &&
- void 0 === $ &&
- (void 0 === j[V] ? ($ = C.slice(0, L).join('/')) : L == B - 1 && ($ = o.path),
- void 0 !== $ && U(o, 0, s, $)),
- L++,
- Array.isArray(j))
- ) {
- if ('-' === V) V = j.length;
- else {
- if (i && !helpers_isInteger(V))
- throw new Ro(
- 'Expected an unsigned base-10 integer value, making the new referenced value the array element with the zero-based index',
- 'OPERATION_PATH_ILLEGAL_ARRAY_INDEX',
- w,
- o,
- s
- );
- helpers_isInteger(V) && (V = ~~V);
- }
- if (L >= B) {
- if (i && 'add' === o.op && V > j.length)
- throw new Ro(
- 'The specified index MUST NOT be greater than the number of elements in the array',
- 'OPERATION_VALUE_OUT_OF_BOUNDS',
- w,
- o,
- s
- );
- if (!1 === (x = Bo[o.op].call(o, j, V, s)).test)
- throw new Ro('Test operation failed', 'TEST_OPERATION_FAILED', w, o, s);
- return x;
- }
- } else if (L >= B) {
- if (!1 === (x = Lo[o.op].call(o, j, V, s)).test)
- throw new Ro('Test operation failed', 'TEST_OPERATION_FAILED', w, o, s);
- return x;
- }
- if (((j = j[V]), i && L < B && (!j || 'object' != typeof j)))
- throw new Ro(
- 'Cannot perform operation at the desired path',
- 'OPERATION_PATH_UNRESOLVABLE',
- w,
- o,
- s
- );
- }
- }
- function applyPatch(s, o, i, u, _) {
- if ((void 0 === u && (u = !0), void 0 === _ && (_ = !0), i && !Array.isArray(o)))
- throw new Ro('Patch sequence must be an array', 'SEQUENCE_NOT_AN_ARRAY');
- u || (s = _deepClone(s));
- for (var w = new Array(o.length), x = 0, C = o.length; x < C; x++)
- (w[x] = applyOperation(s, o[x], i, !0, _, x)), (s = w[x].newDocument);
- return (w.newDocument = s), w;
- }
- function applyReducer(s, o, i) {
- var u = applyOperation(s, o);
- if (!1 === u.test)
- throw new Ro('Test operation failed', 'TEST_OPERATION_FAILED', i, o, s);
- return u.newDocument;
- }
- function validator(s, o, i, u) {
- if ('object' != typeof s || null === s || Array.isArray(s))
- throw new Ro('Operation is not an object', 'OPERATION_NOT_AN_OBJECT', o, s, i);
- if (!Lo[s.op])
- throw new Ro(
- 'Operation `op` property is not one of operations defined in RFC-6902',
- 'OPERATION_OP_INVALID',
- o,
- s,
- i
- );
- if ('string' != typeof s.path)
- throw new Ro(
- 'Operation `path` property is not a string',
- 'OPERATION_PATH_INVALID',
- o,
- s,
- i
- );
- if (0 !== s.path.indexOf('/') && s.path.length > 0)
- throw new Ro(
- 'Operation `path` property must start with "/"',
- 'OPERATION_PATH_INVALID',
- o,
- s,
- i
- );
- if (('move' === s.op || 'copy' === s.op) && 'string' != typeof s.from)
- throw new Ro(
- 'Operation `from` property is not present (applicable in `move` and `copy` operations)',
- 'OPERATION_FROM_REQUIRED',
- o,
- s,
- i
- );
- if (('add' === s.op || 'replace' === s.op || 'test' === s.op) && void 0 === s.value)
- throw new Ro(
- 'Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)',
- 'OPERATION_VALUE_REQUIRED',
- o,
- s,
- i
- );
- if (('add' === s.op || 'replace' === s.op || 'test' === s.op) && hasUndefined(s.value))
- throw new Ro(
- 'Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)',
- 'OPERATION_VALUE_CANNOT_CONTAIN_UNDEFINED',
- o,
- s,
- i
- );
- if (i)
- if ('add' == s.op) {
- var _ = s.path.split('/').length,
- w = u.split('/').length;
- if (_ !== w + 1 && _ !== w)
- throw new Ro(
- 'Cannot perform an `add` operation at the desired path',
- 'OPERATION_PATH_CANNOT_ADD',
- o,
- s,
- i
- );
- } else if ('replace' === s.op || 'remove' === s.op || '_get' === s.op) {
- if (s.path !== u)
- throw new Ro(
- 'Cannot perform the operation at a path that does not exist',
- 'OPERATION_PATH_UNRESOLVABLE',
- o,
- s,
- i
- );
- } else if ('move' === s.op || 'copy' === s.op) {
- var x = validate([{ op: '_get', path: s.from, value: void 0 }], i);
- if (x && 'OPERATION_PATH_UNRESOLVABLE' === x.name)
- throw new Ro(
- 'Cannot perform the operation from a path that does not exist',
- 'OPERATION_FROM_UNRESOLVABLE',
- o,
- s,
- i
- );
- }
- }
- function validate(s, o, i) {
- try {
- if (!Array.isArray(s))
- throw new Ro('Patch sequence must be an array', 'SEQUENCE_NOT_AN_ARRAY');
- if (o) applyPatch(_deepClone(o), _deepClone(s), i || !0);
- else {
- i = i || validator;
- for (var u = 0; u < s.length; u++) i(s[u], u, o, void 0);
- }
- } catch (s) {
- if (s instanceof Ro) return s;
- throw s;
- }
- }
- function _areEquals(s, o) {
- if (s === o) return !0;
- if (s && o && 'object' == typeof s && 'object' == typeof o) {
- var i,
- u,
- _,
- w = Array.isArray(s),
- x = Array.isArray(o);
- if (w && x) {
- if ((u = s.length) != o.length) return !1;
- for (i = u; 0 != i--; ) if (!_areEquals(s[i], o[i])) return !1;
- return !0;
- }
- if (w != x) return !1;
- var C = Object.keys(s);
- if ((u = C.length) !== Object.keys(o).length) return !1;
- for (i = u; 0 != i--; ) if (!o.hasOwnProperty(C[i])) return !1;
- for (i = u; 0 != i--; ) if (!_areEquals(s[(_ = C[i])], o[_])) return !1;
- return !0;
- }
- return s != s && o != o;
- }
- var Fo = new WeakMap(),
- qo = function qo(s) {
- (this.observers = new Map()), (this.obj = s);
- },
- $o = function $o(s, o) {
- (this.callback = s), (this.observer = o);
- };
- function unobserve(s, o) {
- o.unobserve();
- }
- function observe(s, o) {
- var i,
- u = (function getMirror(s) {
- return Fo.get(s);
- })(s);
- if (u) {
- var _ = (function getObserverFromMirror(s, o) {
- return s.observers.get(o);
- })(u, o);
- i = _ && _.observer;
- } else (u = new qo(s)), Fo.set(s, u);
- if (i) return i;
- if (((i = {}), (u.value = _deepClone(s)), o)) {
- (i.callback = o), (i.next = null);
- var dirtyCheck = function () {
- generate(i);
- },
- fastCheck = function () {
- clearTimeout(i.next), (i.next = setTimeout(dirtyCheck));
- };
- 'undefined' != typeof window &&
- (window.addEventListener('mouseup', fastCheck),
- window.addEventListener('keyup', fastCheck),
- window.addEventListener('mousedown', fastCheck),
- window.addEventListener('keydown', fastCheck),
- window.addEventListener('change', fastCheck));
- }
- return (
- (i.patches = []),
- (i.object = s),
- (i.unobserve = function () {
- generate(i),
- clearTimeout(i.next),
- (function removeObserverFromMirror(s, o) {
- s.observers.delete(o.callback);
- })(u, i),
- 'undefined' != typeof window &&
- (window.removeEventListener('mouseup', fastCheck),
- window.removeEventListener('keyup', fastCheck),
- window.removeEventListener('mousedown', fastCheck),
- window.removeEventListener('keydown', fastCheck),
- window.removeEventListener('change', fastCheck));
- }),
- u.observers.set(o, new $o(o, i)),
- i
- );
- }
- function generate(s, o) {
- void 0 === o && (o = !1);
- var i = Fo.get(s.object);
- _generate(i.value, s.object, s.patches, '', o),
- s.patches.length && applyPatch(i.value, s.patches);
- var u = s.patches;
- return u.length > 0 && ((s.patches = []), s.callback && s.callback(u)), u;
- }
- function _generate(s, o, i, u, _) {
- if (o !== s) {
- 'function' == typeof o.toJSON && (o = o.toJSON());
- for (
- var w = _objectKeys(o), x = _objectKeys(s), C = !1, j = x.length - 1;
- j >= 0;
- j--
- ) {
- var L = s[($ = x[j])];
- if (
- !module_helpers_hasOwnProperty(o, $) ||
- (void 0 === o[$] && void 0 !== L && !1 === Array.isArray(o))
- )
- Array.isArray(s) === Array.isArray(o)
- ? (_ &&
- i.push({
- op: 'test',
- path: u + '/' + escapePathComponent($),
- value: _deepClone(L)
- }),
- i.push({ op: 'remove', path: u + '/' + escapePathComponent($) }),
- (C = !0))
- : (_ && i.push({ op: 'test', path: u, value: s }),
- i.push({ op: 'replace', path: u, value: o }),
- !0);
- else {
- var B = o[$];
- 'object' == typeof L &&
- null != L &&
- 'object' == typeof B &&
- null != B &&
- Array.isArray(L) === Array.isArray(B)
- ? _generate(L, B, i, u + '/' + escapePathComponent($), _)
- : L !== B &&
- (_ &&
- i.push({
- op: 'test',
- path: u + '/' + escapePathComponent($),
- value: _deepClone(L)
- }),
- i.push({
- op: 'replace',
- path: u + '/' + escapePathComponent($),
- value: _deepClone(B)
- }));
- }
- }
- if (C || w.length != x.length)
- for (j = 0; j < w.length; j++) {
- var $;
- module_helpers_hasOwnProperty(s, ($ = w[j])) ||
- void 0 === o[$] ||
- i.push({
- op: 'add',
- path: u + '/' + escapePathComponent($),
- value: _deepClone(o[$])
- });
- }
- }
- }
- function compare(s, o, i) {
- void 0 === i && (i = !1);
- var u = [];
- return _generate(s, o, u, '', i), u;
- }
- Object.assign({}, ie, ae, {
- JsonPatchError: No,
- deepClone: _deepClone,
- escapePathComponent,
- unescapePathComponent
- });
- var Vo = __webpack_require__(14744),
- Uo = __webpack_require__.n(Vo);
- const zo = {
- add: function add(s, o) {
- return { op: 'add', path: s, value: o };
- },
- replace,
- remove: function remove(s) {
- return { op: 'remove', path: s };
- },
- merge: function lib_merge(s, o) {
- return { type: 'mutation', op: 'merge', path: s, value: o };
- },
- mergeDeep: function mergeDeep(s, o) {
- return { type: 'mutation', op: 'mergeDeep', path: s, value: o };
- },
- context: function context(s, o) {
- return { type: 'context', path: s, value: o };
- },
- getIn: function lib_getIn(s, o) {
- return o.reduce((s, o) => (void 0 !== o && s ? s[o] : s), s);
- },
- applyPatch: function lib_applyPatch(s, o, i) {
- if (
- ((i = i || {}),
- 'merge' === (o = { ...o, path: o.path && normalizeJSONPath(o.path) }).op)
- ) {
- const i = getInByJsonPath(s, o.path);
- Object.assign(i, o.value), applyPatch(s, [replace(o.path, i)]);
- } else if ('mergeDeep' === o.op) {
- const i = getInByJsonPath(s, o.path),
- u = Uo()(i, o.value);
- s = applyPatch(s, [replace(o.path, u)]).newDocument;
- } else if ('add' === o.op && '' === o.path && lib_isObject(o.value)) {
- applyPatch(
- s,
- Object.keys(o.value).reduce(
- (s, i) => (
- s.push({ op: 'add', path: `/${normalizeJSONPath(i)}`, value: o.value[i] }), s
- ),
- []
- )
- );
- } else if ('replace' === o.op && '' === o.path) {
- let { value: u } = o;
- i.allowMetaPatches &&
- o.meta &&
- isAdditiveMutation(o) &&
- (Array.isArray(o.value) || lib_isObject(o.value)) &&
- (u = { ...u, ...o.meta }),
- (s = u);
- } else if (
- (applyPatch(s, [o]),
- i.allowMetaPatches &&
- o.meta &&
- isAdditiveMutation(o) &&
- (Array.isArray(o.value) || lib_isObject(o.value)))
- ) {
- const i = { ...getInByJsonPath(s, o.path), ...o.meta };
- applyPatch(s, [replace(o.path, i)]);
- }
- return s;
- },
- parentPathMatch: function parentPathMatch(s, o) {
- if (!Array.isArray(o)) return !1;
- for (let i = 0, u = o.length; i < u; i += 1) if (o[i] !== s[i]) return !1;
- return !0;
- },
- flatten,
- fullyNormalizeArray: function fullyNormalizeArray(s) {
- return cleanArray(flatten(lib_normalizeArray(s)));
- },
- normalizeArray: lib_normalizeArray,
- isPromise: function isPromise(s) {
- return lib_isObject(s) && lib_isFunction(s.then);
- },
- forEachNew: function forEachNew(s, o) {
- try {
- return forEachNewPatch(s, forEach, o);
- } catch (s) {
- return s;
- }
- },
- forEachNewPrimitive: function forEachNewPrimitive(s, o) {
- try {
- return forEachNewPatch(s, forEachPrimitive, o);
- } catch (s) {
- return s;
- }
- },
- isJsonPatch,
- isContextPatch: function isContextPatch(s) {
- return isPatch(s) && 'context' === s.type;
- },
- isPatch,
- isMutation,
- isAdditiveMutation,
- isGenerator: function isGenerator(s) {
- return '[object GeneratorFunction]' === Object.prototype.toString.call(s);
- },
- isFunction: lib_isFunction,
- isObject: lib_isObject,
- isError: function lib_isError(s) {
- return s instanceof Error;
- }
- };
- function normalizeJSONPath(s) {
- return Array.isArray(s)
- ? s.length < 1
- ? ''
- : `/${s.map((s) => (s + '').replace(/~/g, '~0').replace(/\//g, '~1')).join('/')}`
- : s;
- }
- function replace(s, o, i) {
- return { op: 'replace', path: s, value: o, meta: i };
- }
- function forEachNewPatch(s, o, i) {
- return cleanArray(
- flatten(s.filter(isAdditiveMutation).map((s) => o(s.value, i, s.path)) || [])
- );
- }
- function forEachPrimitive(s, o, i) {
- return (
- (i = i || []),
- Array.isArray(s)
- ? s.map((s, u) => forEachPrimitive(s, o, i.concat(u)))
- : lib_isObject(s)
- ? Object.keys(s).map((u) => forEachPrimitive(s[u], o, i.concat(u)))
- : o(s, i[i.length - 1], i)
- );
- }
- function forEach(s, o, i) {
- let u = [];
- if ((i = i || []).length > 0) {
- const _ = o(s, i[i.length - 1], i);
- _ && (u = u.concat(_));
- }
- if (Array.isArray(s)) {
- const _ = s.map((s, u) => forEach(s, o, i.concat(u)));
- _ && (u = u.concat(_));
- } else if (lib_isObject(s)) {
- const _ = Object.keys(s).map((u) => forEach(s[u], o, i.concat(u)));
- _ && (u = u.concat(_));
- }
- return (u = flatten(u)), u;
- }
- function lib_normalizeArray(s) {
- return Array.isArray(s) ? s : [s];
- }
- function flatten(s) {
- return [].concat(...s.map((s) => (Array.isArray(s) ? flatten(s) : s)));
- }
- function cleanArray(s) {
- return s.filter((s) => void 0 !== s);
- }
- function lib_isObject(s) {
- return s && 'object' == typeof s;
- }
- function lib_isFunction(s) {
- return s && 'function' == typeof s;
- }
- function isJsonPatch(s) {
- if (isPatch(s)) {
- const { op: o } = s;
- return 'add' === o || 'remove' === o || 'replace' === o;
- }
- return !1;
- }
- function isMutation(s) {
- return isJsonPatch(s) || (isPatch(s) && 'mutation' === s.type);
- }
- function isAdditiveMutation(s) {
- return (
- isMutation(s) &&
- ('add' === s.op || 'replace' === s.op || 'merge' === s.op || 'mergeDeep' === s.op)
- );
- }
- function isPatch(s) {
- return s && 'object' == typeof s;
- }
- function getInByJsonPath(s, o) {
- try {
- return getValueByPointer(s, o);
- } catch (s) {
- return console.error(s), {};
- }
- }
- var Wo = __webpack_require__(48675);
- const Ko = class ApiDOMAggregateError extends Wo {
- constructor(s, o, i) {
- if (
- (super(s, o, i),
- (this.name = this.constructor.name),
- 'string' == typeof o && (this.message = o),
- 'function' == typeof Error.captureStackTrace
- ? Error.captureStackTrace(this, this.constructor)
- : (this.stack = new Error(o).stack),
- null != i && 'object' == typeof i && Object.hasOwn(i, 'cause') && !('cause' in this))
- ) {
- const { cause: s } = i;
- (this.cause = s),
- s instanceof Error &&
- 'stack' in s &&
- (this.stack = `${this.stack}\nCAUSE: ${s.stack}`);
- }
- }
- };
- class ApiDOMError extends Error {
- static [Symbol.hasInstance](s) {
- return (
- super[Symbol.hasInstance](s) || Function.prototype[Symbol.hasInstance].call(Ko, s)
- );
- }
- constructor(s, o) {
- if (
- (super(s, o),
- (this.name = this.constructor.name),
- 'string' == typeof s && (this.message = s),
- 'function' == typeof Error.captureStackTrace
- ? Error.captureStackTrace(this, this.constructor)
- : (this.stack = new Error(s).stack),
- null != o && 'object' == typeof o && Object.hasOwn(o, 'cause') && !('cause' in this))
- ) {
- const { cause: s } = o;
- (this.cause = s),
- s instanceof Error &&
- 'stack' in s &&
- (this.stack = `${this.stack}\nCAUSE: ${s.stack}`);
- }
- }
- }
- const Ho = ApiDOMError;
- const Jo = class ApiDOMStructuredError extends Ho {
- constructor(s, o) {
- if ((super(s, o), null != o && 'object' == typeof o)) {
- const { cause: s, ...i } = o;
- Object.assign(this, i);
- }
- }
- };
- var Go = __webpack_require__(65606);
- function _isPlaceholder(s) {
- return null != s && 'object' == typeof s && !0 === s['@@functional/placeholder'];
- }
- function _curry1(s) {
- return function f1(o) {
- return 0 === arguments.length || _isPlaceholder(o) ? f1 : s.apply(this, arguments);
- };
- }
- function _curry2(s) {
- return function f2(o, i) {
- switch (arguments.length) {
- case 0:
- return f2;
- case 1:
- return _isPlaceholder(o)
- ? f2
- : _curry1(function (i) {
- return s(o, i);
- });
- default:
- return _isPlaceholder(o) && _isPlaceholder(i)
- ? f2
- : _isPlaceholder(o)
- ? _curry1(function (o) {
- return s(o, i);
- })
- : _isPlaceholder(i)
- ? _curry1(function (i) {
- return s(o, i);
- })
- : s(o, i);
- }
- };
- }
- function _curry3(s) {
- return function f3(o, i, u) {
- switch (arguments.length) {
- case 0:
- return f3;
- case 1:
- return _isPlaceholder(o)
- ? f3
- : _curry2(function (i, u) {
- return s(o, i, u);
- });
- case 2:
- return _isPlaceholder(o) && _isPlaceholder(i)
- ? f3
- : _isPlaceholder(o)
- ? _curry2(function (o, u) {
- return s(o, i, u);
- })
- : _isPlaceholder(i)
- ? _curry2(function (i, u) {
- return s(o, i, u);
- })
- : _curry1(function (u) {
- return s(o, i, u);
- });
- default:
- return _isPlaceholder(o) && _isPlaceholder(i) && _isPlaceholder(u)
- ? f3
- : _isPlaceholder(o) && _isPlaceholder(i)
- ? _curry2(function (o, i) {
- return s(o, i, u);
- })
- : _isPlaceholder(o) && _isPlaceholder(u)
- ? _curry2(function (o, u) {
- return s(o, i, u);
- })
- : _isPlaceholder(i) && _isPlaceholder(u)
- ? _curry2(function (i, u) {
- return s(o, i, u);
- })
- : _isPlaceholder(o)
- ? _curry1(function (o) {
- return s(o, i, u);
- })
- : _isPlaceholder(i)
- ? _curry1(function (i) {
- return s(o, i, u);
- })
- : _isPlaceholder(u)
- ? _curry1(function (u) {
- return s(o, i, u);
- })
- : s(o, i, u);
- }
- };
- }
- const Yo =
- Number.isInteger ||
- function _isInteger(s) {
- return (s | 0) === s;
- };
- function _isString(s) {
- return '[object String]' === Object.prototype.toString.call(s);
- }
- function _nth(s, o) {
- var i = s < 0 ? o.length + s : s;
- return _isString(o) ? o.charAt(i) : o[i];
- }
- function _path(s, o) {
- for (var i = o, u = 0; u < s.length; u += 1) {
- if (null == i) return;
- var _ = s[u];
- i = Yo(_) ? _nth(_, i) : i[_];
- }
- return i;
- }
- const Xo = _curry3(function pathSatisfies(s, o, i) {
- return s(_path(o, i));
- });
- function _cloneRegExp(s) {
- return new RegExp(
- s.source,
- s.flags
- ? s.flags
- : (s.global ? 'g' : '') +
- (s.ignoreCase ? 'i' : '') +
- (s.multiline ? 'm' : '') +
- (s.sticky ? 'y' : '') +
- (s.unicode ? 'u' : '') +
- (s.dotAll ? 's' : '')
- );
- }
- function _arrayFromIterator(s) {
- for (var o, i = []; !(o = s.next()).done; ) i.push(o.value);
- return i;
- }
- function _includesWith(s, o, i) {
- for (var u = 0, _ = i.length; u < _; ) {
- if (s(o, i[u])) return !0;
- u += 1;
- }
- return !1;
- }
- function _has(s, o) {
- return Object.prototype.hasOwnProperty.call(o, s);
- }
- const Zo =
- 'function' == typeof Object.is
- ? Object.is
- : function _objectIs(s, o) {
- return s === o ? 0 !== s || 1 / s == 1 / o : s != s && o != o;
- };
- var Qo = Object.prototype.toString;
- const _i = (function () {
- return '[object Arguments]' === Qo.call(arguments)
- ? function _isArguments(s) {
- return '[object Arguments]' === Qo.call(s);
- }
- : function _isArguments(s) {
- return _has('callee', s);
- };
- })();
- var Ei = !{ toString: null }.propertyIsEnumerable('toString'),
- Oi = [
- 'constructor',
- 'valueOf',
- 'isPrototypeOf',
- 'toString',
- 'propertyIsEnumerable',
- 'hasOwnProperty',
- 'toLocaleString'
- ],
- Pi = (function () {
- return arguments.propertyIsEnumerable('length');
- })(),
- Mi = function contains(s, o) {
- for (var i = 0; i < s.length; ) {
- if (s[i] === o) return !0;
- i += 1;
- }
- return !1;
- },
- Ri =
- 'function' != typeof Object.keys || Pi
- ? _curry1(function keys(s) {
- if (Object(s) !== s) return [];
- var o,
- i,
- u = [],
- _ = Pi && _i(s);
- for (o in s) !_has(o, s) || (_ && 'length' === o) || (u[u.length] = o);
- if (Ei)
- for (i = Oi.length - 1; i >= 0; )
- _has((o = Oi[i]), s) && !Mi(u, o) && (u[u.length] = o), (i -= 1);
- return u;
- })
- : _curry1(function keys(s) {
- return Object(s) !== s ? [] : Object.keys(s);
- });
- const Wi = Ri;
- const ea = _curry1(function type(s) {
- return null === s
- ? 'Null'
- : void 0 === s
- ? 'Undefined'
- : Object.prototype.toString.call(s).slice(8, -1);
- });
- function _uniqContentEquals(s, o, i, u) {
- var _ = _arrayFromIterator(s);
- function eq(s, o) {
- return _equals(s, o, i.slice(), u.slice());
- }
- return !_includesWith(
- function (s, o) {
- return !_includesWith(eq, o, s);
- },
- _arrayFromIterator(o),
- _
- );
- }
- function _equals(s, o, i, u) {
- if (Zo(s, o)) return !0;
- var _ = ea(s);
- if (_ !== ea(o)) return !1;
- if (
- 'function' == typeof s['fantasy-land/equals'] ||
- 'function' == typeof o['fantasy-land/equals']
- )
- return (
- 'function' == typeof s['fantasy-land/equals'] &&
- s['fantasy-land/equals'](o) &&
- 'function' == typeof o['fantasy-land/equals'] &&
- o['fantasy-land/equals'](s)
- );
- if ('function' == typeof s.equals || 'function' == typeof o.equals)
- return (
- 'function' == typeof s.equals &&
- s.equals(o) &&
- 'function' == typeof o.equals &&
- o.equals(s)
- );
- switch (_) {
- case 'Arguments':
- case 'Array':
- case 'Object':
- if (
- 'function' == typeof s.constructor &&
- 'Promise' ===
- (function _functionName(s) {
- var o = String(s).match(/^function (\w*)/);
- return null == o ? '' : o[1];
- })(s.constructor)
- )
- return s === o;
- break;
- case 'Boolean':
- case 'Number':
- case 'String':
- if (typeof s != typeof o || !Zo(s.valueOf(), o.valueOf())) return !1;
- break;
- case 'Date':
- if (!Zo(s.valueOf(), o.valueOf())) return !1;
- break;
- case 'Error':
- return s.name === o.name && s.message === o.message;
- case 'RegExp':
- if (
- s.source !== o.source ||
- s.global !== o.global ||
- s.ignoreCase !== o.ignoreCase ||
- s.multiline !== o.multiline ||
- s.sticky !== o.sticky ||
- s.unicode !== o.unicode
- )
- return !1;
- }
- for (var w = i.length - 1; w >= 0; ) {
- if (i[w] === s) return u[w] === o;
- w -= 1;
- }
- switch (_) {
- case 'Map':
- return (
- s.size === o.size &&
- _uniqContentEquals(s.entries(), o.entries(), i.concat([s]), u.concat([o]))
- );
- case 'Set':
- return (
- s.size === o.size &&
- _uniqContentEquals(s.values(), o.values(), i.concat([s]), u.concat([o]))
- );
- case 'Arguments':
- case 'Array':
- case 'Object':
- case 'Boolean':
- case 'Number':
- case 'String':
- case 'Date':
- case 'Error':
- case 'RegExp':
- case 'Int8Array':
- case 'Uint8Array':
- case 'Uint8ClampedArray':
- case 'Int16Array':
- case 'Uint16Array':
- case 'Int32Array':
- case 'Uint32Array':
- case 'Float32Array':
- case 'Float64Array':
- case 'ArrayBuffer':
- break;
- default:
- return !1;
- }
- var x = Wi(s);
- if (x.length !== Wi(o).length) return !1;
- var C = i.concat([s]),
- j = u.concat([o]);
- for (w = x.length - 1; w >= 0; ) {
- var L = x[w];
- if (!_has(L, o) || !_equals(o[L], s[L], C, j)) return !1;
- w -= 1;
- }
- return !0;
- }
- const ra = _curry2(function equals(s, o) {
- return _equals(s, o, [], []);
- });
- function _includes(s, o) {
- return (
- (function _indexOf(s, o, i) {
- var u, _;
- if ('function' == typeof s.indexOf)
- switch (typeof o) {
- case 'number':
- if (0 === o) {
- for (u = 1 / o; i < s.length; ) {
- if (0 === (_ = s[i]) && 1 / _ === u) return i;
- i += 1;
- }
- return -1;
- }
- if (o != o) {
- for (; i < s.length; ) {
- if ('number' == typeof (_ = s[i]) && _ != _) return i;
- i += 1;
- }
- return -1;
- }
- return s.indexOf(o, i);
- case 'string':
- case 'boolean':
- case 'function':
- case 'undefined':
- return s.indexOf(o, i);
- case 'object':
- if (null === o) return s.indexOf(o, i);
- }
- for (; i < s.length; ) {
- if (ra(s[i], o)) return i;
- i += 1;
- }
- return -1;
- })(o, s, 0) >= 0
- );
- }
- function _map(s, o) {
- for (var i = 0, u = o.length, _ = Array(u); i < u; ) (_[i] = s(o[i])), (i += 1);
- return _;
- }
- function _quote(s) {
- return (
- '"' +
- s
- .replace(/\\/g, '\\\\')
- .replace(/[\b]/g, '\\b')
- .replace(/\f/g, '\\f')
- .replace(/\n/g, '\\n')
- .replace(/\r/g, '\\r')
- .replace(/\t/g, '\\t')
- .replace(/\v/g, '\\v')
- .replace(/\0/g, '\\0')
- .replace(/"/g, '\\"') +
- '"'
- );
- }
- var na = function pad(s) {
- return (s < 10 ? '0' : '') + s;
- };
- const ia =
- 'function' == typeof Date.prototype.toISOString
- ? function _toISOString(s) {
- return s.toISOString();
- }
- : function _toISOString(s) {
- return (
- s.getUTCFullYear() +
- '-' +
- na(s.getUTCMonth() + 1) +
- '-' +
- na(s.getUTCDate()) +
- 'T' +
- na(s.getUTCHours()) +
- ':' +
- na(s.getUTCMinutes()) +
- ':' +
- na(s.getUTCSeconds()) +
- '.' +
- (s.getUTCMilliseconds() / 1e3).toFixed(3).slice(2, 5) +
- 'Z'
- );
- };
- function _complement(s) {
- return function () {
- return !s.apply(this, arguments);
- };
- }
- function _arrayReduce(s, o, i) {
- for (var u = 0, _ = i.length; u < _; ) (o = s(o, i[u])), (u += 1);
- return o;
- }
- const aa =
- Array.isArray ||
- function _isArray(s) {
- return (
- null != s && s.length >= 0 && '[object Array]' === Object.prototype.toString.call(s)
- );
- };
- function _dispatchable(s, o, i) {
- return function () {
- if (0 === arguments.length) return i();
- var u = arguments[arguments.length - 1];
- if (!aa(u)) {
- for (var _ = 0; _ < s.length; ) {
- if ('function' == typeof u[s[_]])
- return u[s[_]].apply(u, Array.prototype.slice.call(arguments, 0, -1));
- _ += 1;
- }
- if (
- (function _isTransformer(s) {
- return null != s && 'function' == typeof s['@@transducer/step'];
- })(u)
- )
- return o.apply(null, Array.prototype.slice.call(arguments, 0, -1))(u);
- }
- return i.apply(this, arguments);
- };
- }
- function _isObject(s) {
- return '[object Object]' === Object.prototype.toString.call(s);
- }
- const _xfBase_init = function () {
- return this.xf['@@transducer/init']();
- },
- _xfBase_result = function (s) {
- return this.xf['@@transducer/result'](s);
- };
- var la = (function () {
- function XFilter(s, o) {
- (this.xf = o), (this.f = s);
- }
- return (
- (XFilter.prototype['@@transducer/init'] = _xfBase_init),
- (XFilter.prototype['@@transducer/result'] = _xfBase_result),
- (XFilter.prototype['@@transducer/step'] = function (s, o) {
- return this.f(o) ? this.xf['@@transducer/step'](s, o) : s;
- }),
- XFilter
- );
- })();
- function _xfilter(s) {
- return function (o) {
- return new la(s, o);
- };
- }
- var ca = _curry2(
- _dispatchable(['fantasy-land/filter', 'filter'], _xfilter, function (s, o) {
- return _isObject(o)
- ? _arrayReduce(
- function (i, u) {
- return s(o[u]) && (i[u] = o[u]), i;
- },
- {},
- Wi(o)
- )
- : (function _filter(s, o) {
- for (var i = 0, u = o.length, _ = []; i < u; )
- s(o[i]) && (_[_.length] = o[i]), (i += 1);
- return _;
- })(s, o);
- })
- );
- const ua = ca;
- const da = _curry2(function reject(s, o) {
- return ua(_complement(s), o);
- });
- function _toString_toString(s, o) {
- var i = function recur(i) {
- var u = o.concat([s]);
- return _includes(i, u) ? '<Circular>' : _toString_toString(i, u);
- },
- mapPairs = function (s, o) {
- return _map(function (o) {
- return _quote(o) + ': ' + i(s[o]);
- }, o.slice().sort());
- };
- switch (Object.prototype.toString.call(s)) {
- case '[object Arguments]':
- return '(function() { return arguments; }(' + _map(i, s).join(', ') + '))';
- case '[object Array]':
- return (
- '[' +
- _map(i, s)
- .concat(
- mapPairs(
- s,
- da(function (s) {
- return /^\d+$/.test(s);
- }, Wi(s))
- )
- )
- .join(', ') +
- ']'
- );
- case '[object Boolean]':
- return 'object' == typeof s ? 'new Boolean(' + i(s.valueOf()) + ')' : s.toString();
- case '[object Date]':
- return 'new Date(' + (isNaN(s.valueOf()) ? i(NaN) : _quote(ia(s))) + ')';
- case '[object Map]':
- return 'new Map(' + i(Array.from(s)) + ')';
- case '[object Null]':
- return 'null';
- case '[object Number]':
- return 'object' == typeof s
- ? 'new Number(' + i(s.valueOf()) + ')'
- : 1 / s == -1 / 0
- ? '-0'
- : s.toString(10);
- case '[object Set]':
- return 'new Set(' + i(Array.from(s).sort()) + ')';
- case '[object String]':
- return 'object' == typeof s ? 'new String(' + i(s.valueOf()) + ')' : _quote(s);
- case '[object Undefined]':
- return 'undefined';
- default:
- if ('function' == typeof s.toString) {
- var u = s.toString();
- if ('[object Object]' !== u) return u;
- }
- return '{' + mapPairs(s, Wi(s)).join(', ') + '}';
- }
- }
- const ma = _curry1(function toString(s) {
- return _toString_toString(s, []);
- });
- var ga = _curry2(function test(s, o) {
- if (
- !(function _isRegExp(s) {
- return '[object RegExp]' === Object.prototype.toString.call(s);
- })(s)
- )
- throw new TypeError(
- '‘test’ requires a value of type RegExp as its first argument; received ' + ma(s)
- );
- return _cloneRegExp(s).test(o);
- });
- const ya = ga;
- function _arity(s, o) {
- switch (s) {
- case 0:
- return function () {
- return o.apply(this, arguments);
- };
- case 1:
- return function (s) {
- return o.apply(this, arguments);
- };
- case 2:
- return function (s, i) {
- return o.apply(this, arguments);
- };
- case 3:
- return function (s, i, u) {
- return o.apply(this, arguments);
- };
- case 4:
- return function (s, i, u, _) {
- return o.apply(this, arguments);
- };
- case 5:
- return function (s, i, u, _, w) {
- return o.apply(this, arguments);
- };
- case 6:
- return function (s, i, u, _, w, x) {
- return o.apply(this, arguments);
- };
- case 7:
- return function (s, i, u, _, w, x, C) {
- return o.apply(this, arguments);
- };
- case 8:
- return function (s, i, u, _, w, x, C, j) {
- return o.apply(this, arguments);
- };
- case 9:
- return function (s, i, u, _, w, x, C, j, L) {
- return o.apply(this, arguments);
- };
- case 10:
- return function (s, i, u, _, w, x, C, j, L, B) {
- return o.apply(this, arguments);
- };
- default:
- throw new Error(
- 'First argument to _arity must be a non-negative integer no greater than ten'
- );
- }
- }
- function _pipe(s, o) {
- return function () {
- return o.call(this, s.apply(this, arguments));
- };
- }
- const va = _curry1(function isArrayLike(s) {
- return (
- !!aa(s) ||
- (!!s &&
- 'object' == typeof s &&
- !_isString(s) &&
- (0 === s.length ||
- (s.length > 0 && s.hasOwnProperty(0) && s.hasOwnProperty(s.length - 1))))
- );
- });
- var ba = 'undefined' != typeof Symbol ? Symbol.iterator : '@@iterator';
- function _createReduce(s, o, i) {
- return function _reduce(u, _, w) {
- if (va(w)) return s(u, _, w);
- if (null == w) return _;
- if ('function' == typeof w['fantasy-land/reduce'])
- return o(u, _, w, 'fantasy-land/reduce');
- if (null != w[ba]) return i(u, _, w[ba]());
- if ('function' == typeof w.next) return i(u, _, w);
- if ('function' == typeof w.reduce) return o(u, _, w, 'reduce');
- throw new TypeError('reduce: list must be array or iterable');
- };
- }
- function _xArrayReduce(s, o, i) {
- for (var u = 0, _ = i.length; u < _; ) {
- if ((o = s['@@transducer/step'](o, i[u])) && o['@@transducer/reduced']) {
- o = o['@@transducer/value'];
- break;
- }
- u += 1;
- }
- return s['@@transducer/result'](o);
- }
- var _a = _curry2(function bind(s, o) {
- return _arity(s.length, function () {
- return s.apply(o, arguments);
- });
- });
- const Ea = _a;
- function _xIterableReduce(s, o, i) {
- for (var u = i.next(); !u.done; ) {
- if ((o = s['@@transducer/step'](o, u.value)) && o['@@transducer/reduced']) {
- o = o['@@transducer/value'];
- break;
- }
- u = i.next();
- }
- return s['@@transducer/result'](o);
- }
- function _xMethodReduce(s, o, i, u) {
- return s['@@transducer/result'](i[u](Ea(s['@@transducer/step'], s), o));
- }
- const wa = _createReduce(_xArrayReduce, _xMethodReduce, _xIterableReduce);
- var xa = (function () {
- function XWrap(s) {
- this.f = s;
- }
- return (
- (XWrap.prototype['@@transducer/init'] = function () {
- throw new Error('init not implemented on XWrap');
- }),
- (XWrap.prototype['@@transducer/result'] = function (s) {
- return s;
- }),
- (XWrap.prototype['@@transducer/step'] = function (s, o) {
- return this.f(s, o);
- }),
- XWrap
- );
- })();
- function _xwrap(s) {
- return new xa(s);
- }
- var ka = _curry3(function (s, o, i) {
- return wa('function' == typeof s ? _xwrap(s) : s, o, i);
- });
- const Ca = ka;
- function _checkForMethod(s, o) {
- return function () {
- var i = arguments.length;
- if (0 === i) return o();
- var u = arguments[i - 1];
- return aa(u) || 'function' != typeof u[s]
- ? o.apply(this, arguments)
- : u[s].apply(u, Array.prototype.slice.call(arguments, 0, i - 1));
- };
- }
- var Aa = _curry3(
- _checkForMethod('slice', function slice(s, o, i) {
- return Array.prototype.slice.call(i, s, o);
- })
- );
- const ja = Aa;
- const Ia = _curry1(_checkForMethod('tail', ja(1, 1 / 0)));
- function pipe() {
- if (0 === arguments.length) throw new Error('pipe requires at least one argument');
- return _arity(arguments[0].length, Ca(_pipe, arguments[0], Ia(arguments)));
- }
- const Na = _curry2(function defaultTo(s, o) {
- return null == o || o != o ? s : o;
- });
- const Da = _curry2(function prop(s, o) {
- if (null != o) return Yo(s) ? _nth(s, o) : o[s];
- });
- const La = _curry3(function propOr(s, o, i) {
- return Na(s, Da(o, i));
- });
- var Ba = _curry1(function (s) {
- return _nth(-1, s);
- });
- const Fa = Ba;
- function _curryN(s, o, i) {
- return function () {
- for (var u = [], _ = 0, w = s, x = 0, C = !1; x < o.length || _ < arguments.length; ) {
- var j;
- x < o.length && (!_isPlaceholder(o[x]) || _ >= arguments.length)
- ? (j = o[x])
- : ((j = arguments[_]), (_ += 1)),
- (u[x] = j),
- _isPlaceholder(j) ? (C = !0) : (w -= 1),
- (x += 1);
- }
- return !C && w <= 0 ? i.apply(this, u) : _arity(Math.max(0, w), _curryN(s, u, i));
- };
- }
- var $a = _curry2(function curryN(s, o) {
- return 1 === s ? _curry1(o) : _arity(s, _curryN(s, [], o));
- });
- const za = $a;
- var Ha = _curry1(function curry(s) {
- return za(s.length, s);
- });
- const Ja = Ha;
- function _isFunction(s) {
- var o = Object.prototype.toString.call(s);
- return (
- '[object Function]' === o ||
- '[object AsyncFunction]' === o ||
- '[object GeneratorFunction]' === o ||
- '[object AsyncGeneratorFunction]' === o
- );
- }
- const Ga = _curry2(function invoker(s, o) {
- return za(s + 1, function () {
- var i = arguments[s];
- if (null != i && _isFunction(i[o]))
- return i[o].apply(i, Array.prototype.slice.call(arguments, 0, s));
- throw new TypeError(ma(i) + ' does not have a method named "' + o + '"');
- });
- });
- const tl = Ga(1, 'split');
- function dropLastWhile(s, o) {
- for (var i = o.length - 1; i >= 0 && s(o[i]); ) i -= 1;
- return ja(0, i + 1, o);
- }
- var sl = (function () {
- function XDropLastWhile(s, o) {
- (this.f = s), (this.retained = []), (this.xf = o);
- }
- return (
- (XDropLastWhile.prototype['@@transducer/init'] = _xfBase_init),
- (XDropLastWhile.prototype['@@transducer/result'] = function (s) {
- return (this.retained = null), this.xf['@@transducer/result'](s);
- }),
- (XDropLastWhile.prototype['@@transducer/step'] = function (s, o) {
- return this.f(o) ? this.retain(s, o) : this.flush(s, o);
- }),
- (XDropLastWhile.prototype.flush = function (s, o) {
- return (
- (s = wa(this.xf, s, this.retained)),
- (this.retained = []),
- this.xf['@@transducer/step'](s, o)
- );
- }),
- (XDropLastWhile.prototype.retain = function (s, o) {
- return this.retained.push(o), s;
- }),
- XDropLastWhile
- );
- })();
- function _xdropLastWhile(s) {
- return function (o) {
- return new sl(s, o);
- };
- }
- const ul = _curry2(_dispatchable([], _xdropLastWhile, dropLastWhile));
- const yl = Ga(1, 'join');
- var vl = _curry1(function flip(s) {
- return za(s.length, function (o, i) {
- var u = Array.prototype.slice.call(arguments, 0);
- return (u[0] = i), (u[1] = o), s.apply(this, u);
- });
- });
- const _l = vl(_curry2(_includes));
- const El = Ja(function (s, o) {
- return pipe(tl(''), ul(_l(s)), yl(''))(o);
- });
- function _iterableReduce(s, o, i) {
- for (var u = i.next(); !u.done; ) (o = s(o, u.value)), (u = i.next());
- return o;
- }
- function _methodReduce(s, o, i, u) {
- return i[u](s, o);
- }
- const wl = _createReduce(_arrayReduce, _methodReduce, _iterableReduce);
- var Sl = (function () {
- function XMap(s, o) {
- (this.xf = o), (this.f = s);
- }
- return (
- (XMap.prototype['@@transducer/init'] = _xfBase_init),
- (XMap.prototype['@@transducer/result'] = _xfBase_result),
- (XMap.prototype['@@transducer/step'] = function (s, o) {
- return this.xf['@@transducer/step'](s, this.f(o));
- }),
- XMap
- );
- })();
- var xl = _curry2(
- _dispatchable(
- ['fantasy-land/map', 'map'],
- function _xmap(s) {
- return function (o) {
- return new Sl(s, o);
- };
- },
- function map(s, o) {
- switch (Object.prototype.toString.call(o)) {
- case '[object Function]':
- return za(o.length, function () {
- return s.call(this, o.apply(this, arguments));
- });
- case '[object Object]':
- return _arrayReduce(
- function (i, u) {
- return (i[u] = s(o[u])), i;
- },
- {},
- Wi(o)
- );
- default:
- return _map(s, o);
- }
- }
- )
- );
- const kl = xl;
- const Cl = _curry2(function ap(s, o) {
- return 'function' == typeof o['fantasy-land/ap']
- ? o['fantasy-land/ap'](s)
- : 'function' == typeof s.ap
- ? s.ap(o)
- : 'function' == typeof s
- ? function (i) {
- return s(i)(o(i));
- }
- : wl(
- function (s, i) {
- return (function _concat(s, o) {
- var i;
- o = o || [];
- var u = (s = s || []).length,
- _ = o.length,
- w = [];
- for (i = 0; i < u; ) (w[w.length] = s[i]), (i += 1);
- for (i = 0; i < _; ) (w[w.length] = o[i]), (i += 1);
- return w;
- })(s, kl(i, o));
- },
- [],
- s
- );
- });
- var Ol = _curry2(function liftN(s, o) {
- var i = za(s, o);
- return za(s, function () {
- return _arrayReduce(Cl, kl(i, arguments[0]), Array.prototype.slice.call(arguments, 1));
- });
- });
- const Al = Ol;
- var Il = _curry1(function lift(s) {
- return Al(s.length, s);
- });
- const Pl = Il;
- const Ml = Pl(
- _curry1(function not(s) {
- return !s;
- })
- );
- const Tl = _curry1(function always(s) {
- return function () {
- return s;
- };
- });
- const Nl = Tl(void 0);
- const Rl = ra(Nl());
- const Dl = Ml(Rl);
- const Ll = _curry2(function max(s, o) {
- if (s === o) return o;
- function safeMax(s, o) {
- if (s > o != o > s) return o > s ? o : s;
- }
- var i = safeMax(s, o);
- if (void 0 !== i) return i;
- var u = safeMax(typeof s, typeof o);
- if (void 0 !== u) return u === typeof s ? s : o;
- var _ = ma(s),
- w = safeMax(_, ma(o));
- return void 0 !== w && w === _ ? s : o;
- });
- var Bl = _curry2(function pluck(s, o) {
- return kl(Da(s), o);
- });
- const Fl = Bl;
- const $l = _curry1(function anyPass(s) {
- return za(Ca(Ll, 0, Fl('length', s)), function () {
- for (var o = 0, i = s.length; o < i; ) {
- if (s[o].apply(this, arguments)) return !0;
- o += 1;
- }
- return !1;
- });
- });
- var identical = function (s, o) {
- switch (arguments.length) {
- case 0:
- return identical;
- case 1:
- return function unaryIdentical(o) {
- return 0 === arguments.length ? unaryIdentical : Zo(s, o);
- };
- default:
- return Zo(s, o);
- }
- };
- const Vl = identical;
- const Ul = za(1, pipe(ea, Vl('GeneratorFunction')));
- const zl = za(1, pipe(ea, Vl('AsyncFunction')));
- const Wl = $l([pipe(ea, Vl('Function')), Ul, zl]);
- var Kl = _curry3(function replace(s, o, i) {
- return i.replace(s, o);
- });
- const Hl = Kl;
- const Jl = za(1, pipe(ea, Vl('RegExp')));
- const Gl = _curry3(function when(s, o, i) {
- return s(i) ? o(i) : i;
- });
- const Yl = za(1, pipe(ea, Vl('String')));
- const Xl = Gl(Yl, Hl(/[.*+?^${}()|[\]\\-]/g, '\\$&'));
- var Zl = function checkValue(s, o) {
- if ('string' != typeof s && !(s instanceof String))
- throw TypeError('`'.concat(o, '` must be a string'));
- };
- const Ql = function replaceAll(s, o, i) {
- !(function checkArguments(s, o, i) {
- if (null == i || null == s || null == o)
- throw TypeError('Input values must not be `null` or `undefined`');
- })(s, o, i),
- Zl(i, 'str'),
- Zl(o, 'replaceValue'),
- (function checkSearchValue(s) {
- if (!('string' == typeof s || s instanceof String || s instanceof RegExp))
- throw TypeError('`searchValue` must be a string or an regexp');
- })(s);
- var u = new RegExp(Jl(s) ? s : Xl(s), 'g');
- return Hl(u, o, i);
- };
- var ec = za(3, Ql),
- rc = Ga(2, 'replaceAll');
- const sc = Wl(String.prototype.replaceAll) ? rc : ec,
- isWindows = () => Xo(ya(/^win/), ['platform'], Go),
- getProtocol = (s) => {
- try {
- const o = new URL(s);
- return El(':', o.protocol);
- } catch {
- return;
- }
- },
- oc =
- (pipe(getProtocol, Dl),
- (s) => {
- if (Go.browser) return !1;
- const o = getProtocol(s);
- return Rl(o) || 'file' === o || /^[a-zA-Z]$/.test(o);
- }),
- isHttpUrl = (s) => {
- const o = getProtocol(s);
- return 'http' === o || 'https' === o;
- },
- toFileSystemPath = (s, o) => {
- const i = [/%23/g, '#', /%24/g, '$', /%26/g, '&', /%2C/g, ',', /%40/g, '@'],
- u = La(!1, 'keepFileProtocol', o),
- _ = La(isWindows, 'isWindows', o);
- let w = decodeURI(s);
- for (let s = 0; s < i.length; s += 2) w = w.replace(i[s], i[s + 1]);
- let x = 'file://' === w.substring(0, 7).toLowerCase();
- return (
- x &&
- ((w = '/' === w[7] ? w.substring(8) : w.substring(7)),
- _() && '/' === w[1] && (w = `${w[0]}:${w.substring(1)}`),
- u ? (w = `file:///${w}`) : ((x = !1), (w = _() ? w : `/${w}`))),
- _() &&
- !x &&
- ((w = sc('/', '\\', w)),
- ':\\' === w.substring(1, 3) && (w = w[0].toUpperCase() + w.substring(1))),
- w
- );
- },
- getHash = (s) => {
- const o = s.indexOf('#');
- return -1 !== o ? s.substring(o) : '#';
- },
- stripHash = (s) => {
- const o = s.indexOf('#');
- let i = s;
- return o >= 0 && (i = s.substring(0, o)), i;
- },
- url_cwd = () => {
- if (Go.browser) return stripHash(globalThis.location.href);
- const s = Go.cwd(),
- o = Fa(s);
- return ['/', '\\'].includes(o) ? s : s + (isWindows() ? '\\' : '/');
- },
- resolve = (s, o) => {
- const i = new URL(o, new URL(s, 'resolve://'));
- if ('resolve:' === i.protocol) {
- const { pathname: s, search: o, hash: u } = i;
- return s + o + u;
- }
- return i.toString();
- },
- sanitize = (s) => {
- if (oc(s))
- return ((s) => {
- const o = [/\?/g, '%3F', /#/g, '%23'];
- let i = s;
- isWindows() && (i = i.replace(/\\/g, '/')), (i = encodeURI(i));
- for (let s = 0; s < o.length; s += 2) i = i.replace(o[s], o[s + 1]);
- return i;
- })(toFileSystemPath(s));
- try {
- return new URL(s).toString();
- } catch {
- return encodeURI(decodeURI(s)).replace(/%5B/g, '[').replace(/%5D/g, ']');
- }
- },
- unsanitize = (s) => (oc(s) ? toFileSystemPath(s) : decodeURI(s)),
- {
- fetch: ic,
- Response: ac,
- Headers: lc,
- Request: cc,
- FormData: pc,
- File: hc,
- Blob: dc
- } = globalThis;
- function _array_like_to_array(s, o) {
- (null == o || o > s.length) && (o = s.length);
- for (var i = 0, u = new Array(o); i < o; i++) u[i] = s[i];
- return u;
- }
- function legacy_defineProperties(s, o) {
- for (var i = 0; i < o.length; i++) {
- var u = o[i];
- (u.enumerable = u.enumerable || !1),
- (u.configurable = !0),
- 'value' in u && (u.writable = !0),
- Object.defineProperty(s, u.key, u);
- }
- }
- function _instanceof(s, o) {
- return null != o && 'undefined' != typeof Symbol && o[Symbol.hasInstance]
- ? !!o[Symbol.hasInstance](s)
- : s instanceof o;
- }
- function _sliced_to_array(s, o) {
- return (
- (function _array_with_holes(s) {
- if (Array.isArray(s)) return s;
- })(s) ||
- (function _iterable_to_array_limit(s, o) {
- var i =
- null == s
- ? null
- : ('undefined' != typeof Symbol && s[Symbol.iterator]) || s['@@iterator'];
- if (null != i) {
- var u,
- _,
- w = [],
- x = !0,
- C = !1;
- try {
- for (
- i = i.call(s);
- !(x = (u = i.next()).done) && (w.push(u.value), !o || w.length !== o);
- x = !0
- );
- } catch (s) {
- (C = !0), (_ = s);
- } finally {
- try {
- x || null == i.return || i.return();
- } finally {
- if (C) throw _;
- }
- }
- return w;
- }
- })(s, o) ||
- (function _unsupported_iterable_to_array(s, o) {
- if (!s) return;
- if ('string' == typeof s) return _array_like_to_array(s, o);
- var i = Object.prototype.toString.call(s).slice(8, -1);
- 'Object' === i && s.constructor && (i = s.constructor.name);
- if ('Map' === i || 'Set' === i) return Array.from(i);
- if ('Arguments' === i || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i))
- return _array_like_to_array(s, o);
- })(s, o) ||
- (function _non_iterable_rest() {
- throw new TypeError(
- 'Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.'
- );
- })()
- );
- }
- function _type_of(s) {
- return s && 'undefined' != typeof Symbol && s.constructor === Symbol
- ? 'symbol'
- : typeof s;
- }
- void 0 === globalThis.fetch && (globalThis.fetch = ic),
- void 0 === globalThis.Headers && (globalThis.Headers = lc),
- void 0 === globalThis.Request && (globalThis.Request = cc),
- void 0 === globalThis.Response && (globalThis.Response = ac),
- void 0 === globalThis.FormData && (globalThis.FormData = pc),
- void 0 === globalThis.File && (globalThis.File = hc),
- void 0 === globalThis.Blob && (globalThis.Blob = dc);
- var __typeError = function (s) {
- throw TypeError(s);
- },
- __accessCheck = function (s, o, i) {
- return o.has(s) || __typeError('Cannot ' + i);
- },
- __privateGet = function (s, o, i) {
- return __accessCheck(s, o, 'read from private field'), i ? i.call(s) : o.get(s);
- },
- __privateAdd = function (s, o, i) {
- return o.has(s)
- ? __typeError('Cannot add the same private member more than once')
- : _instanceof(o, WeakSet)
- ? o.add(s)
- : o.set(s, i);
- },
- __privateSet = function (s, o, i, u) {
- return __accessCheck(s, o, 'write to private field'), u ? u.call(s, i) : o.set(s, i), i;
- },
- to_string = function (s) {
- return Object.prototype.toString.call(s);
- },
- is_typed_array = function (s) {
- return ArrayBuffer.isView(s) && !_instanceof(s, DataView);
- },
- fc = Array.isArray,
- gc = Object.getOwnPropertyDescriptor,
- bc = Object.prototype.propertyIsEnumerable,
- _c = Object.getOwnPropertySymbols,
- Ec = Object.prototype.hasOwnProperty;
- function own_enumerable_keys(s) {
- for (var o = Object.keys(s), i = _c(s), u = 0; u < i.length; u++)
- bc.call(s, i[u]) && o.push(i[u]);
- return o;
- }
- function is_writable(s, o) {
- var i;
- return !(null === (i = gc(s, o)) || void 0 === i ? void 0 : i.writable);
- }
- function legacy_copy(s, o) {
- if ('object' === (void 0 === s ? 'undefined' : _type_of(s)) && null !== s) {
- var i;
- if (fc(s)) i = [];
- else if ('[object Date]' === to_string(s)) i = new Date(s.getTime ? s.getTime() : s);
- else if (
- (function (s) {
- return '[object RegExp]' === to_string(s);
- })(s)
- )
- i = new RegExp(s);
- else if (
- (function (s) {
- return '[object Error]' === to_string(s);
- })(s)
- )
- i = { message: s.message };
- else if (
- (function (s) {
- return '[object Boolean]' === to_string(s);
- })(s) ||
- (function (s) {
- return '[object Number]' === to_string(s);
- })(s) ||
- (function (s) {
- return '[object String]' === to_string(s);
- })(s)
- )
- i = Object(s);
- else {
- if (is_typed_array(s)) return s.slice();
- i = Object.create(Object.getPrototypeOf(s));
- }
- var u = o.includeSymbols ? own_enumerable_keys : Object.keys,
- _ = !0,
- w = !1,
- x = void 0;
- try {
- for (var C, j = u(s)[Symbol.iterator](); !(_ = (C = j.next()).done); _ = !0) {
- var L = C.value;
- i[L] = s[L];
- }
- } catch (s) {
- (w = !0), (x = s);
- } finally {
- try {
- _ || null == j.return || j.return();
- } finally {
- if (w) throw x;
- }
- }
- return i;
- }
- return s;
- }
- var kc,
- Oc,
- jc = { includeSymbols: !1, immutable: !1 };
- function walk(s, o) {
- var i = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : jc,
- u = [],
- _ = [],
- w = !0,
- x = i.includeSymbols ? own_enumerable_keys : Object.keys,
- C = !!i.immutable;
- return (function walker(s) {
- var j = C ? legacy_copy(s, i) : s,
- L = {},
- B = !0,
- $ = {
- node: j,
- node_: s,
- path: [].concat(u),
- parent: _[_.length - 1],
- parents: _,
- key: u[u.length - 1],
- isRoot: 0 === u.length,
- level: u.length,
- circular: void 0,
- isLeaf: !1,
- notLeaf: !0,
- notRoot: !0,
- isFirst: !1,
- isLast: !1,
- update: function update(s) {
- var o = arguments.length > 1 && void 0 !== arguments[1] && arguments[1];
- $.isRoot || ($.parent.node[$.key] = s), ($.node = s), o && (B = !1);
- },
- delete: function _delete(s) {
- delete $.parent.node[$.key], s && (B = !1);
- },
- remove: function remove(s) {
- fc($.parent.node) ? $.parent.node.splice($.key, 1) : delete $.parent.node[$.key],
- s && (B = !1);
- },
- keys: null,
- before: function before(s) {
- L.before = s;
- },
- after: function after(s) {
- L.after = s;
- },
- pre: function pre(s) {
- L.pre = s;
- },
- post: function post(s) {
- L.post = s;
- },
- stop: function stop() {
- w = !1;
- },
- block: function block() {
- B = !1;
- }
- };
- if (!w) return $;
- function update_state() {
- if ('object' === _type_of($.node) && null !== $.node) {
- ($.keys && $.node_ === $.node) || ($.keys = x($.node)),
- ($.isLeaf = 0 === $.keys.length);
- for (var o = 0; o < _.length; o++)
- if (_[o].node_ === s) {
- $.circular = _[o];
- break;
- }
- } else ($.isLeaf = !0), ($.keys = null);
- ($.notLeaf = !$.isLeaf), ($.notRoot = !$.isRoot);
- }
- update_state();
- var V = o.call($, $.node);
- if ((void 0 !== V && $.update && $.update(V), L.before && L.before.call($, $.node), !B))
- return $;
- if ('object' === _type_of($.node) && null !== $.node && !$.circular) {
- var U;
- _.push($), update_state();
- var z = !0,
- Y = !1,
- Z = void 0;
- try {
- for (
- var ee,
- ie = Object.entries(null !== (U = $.keys) && void 0 !== U ? U : [])[
- Symbol.iterator
- ]();
- !(z = (ee = ie.next()).done);
- z = !0
- ) {
- var ae,
- le = _sliced_to_array(ee.value, 2),
- ce = le[0],
- pe = le[1];
- u.push(pe), L.pre && L.pre.call($, $.node[pe], pe);
- var de = walker($.node[pe]);
- C && Ec.call($.node, pe) && !is_writable($.node, pe) && ($.node[pe] = de.node),
- (de.isLast =
- !!(null === (ae = $.keys) || void 0 === ae ? void 0 : ae.length) &&
- +ce == $.keys.length - 1),
- (de.isFirst = 0 == +ce),
- L.post && L.post.call($, de),
- u.pop();
- }
- } catch (s) {
- (Y = !0), (Z = s);
- } finally {
- try {
- z || null == ie.return || ie.return();
- } finally {
- if (Y) throw Z;
- }
- }
- _.pop();
- }
- return L.after && L.after.call($, $.node), $;
- })(s).node;
- }
- var Ic = (function () {
- function Traverse(s) {
- var o = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : jc;
- !(function _class_call_check(s, o) {
- if (!(s instanceof o)) throw new TypeError('Cannot call a class as a function');
- })(this, Traverse),
- __privateAdd(this, kc),
- __privateAdd(this, Oc),
- __privateSet(this, kc, s),
- __privateSet(this, Oc, o);
- }
- return (
- (function _create_class(s, o, i) {
- return (
- o && legacy_defineProperties(s.prototype, o), i && legacy_defineProperties(s, i), s
- );
- })(Traverse, [
- {
- key: 'get',
- value: function get(s) {
- for (var o = __privateGet(this, kc), i = 0; o && i < s.length; i++) {
- var u = s[i];
- if (
- !Ec.call(o, u) ||
- (!__privateGet(this, Oc).includeSymbols &&
- 'symbol' === (void 0 === u ? 'undefined' : _type_of(u)))
- )
- return;
- o = o[u];
- }
- return o;
- }
- },
- {
- key: 'has',
- value: function has(s) {
- for (var o = __privateGet(this, kc), i = 0; o && i < s.length; i++) {
- var u = s[i];
- if (
- !Ec.call(o, u) ||
- (!__privateGet(this, Oc).includeSymbols &&
- 'symbol' === (void 0 === u ? 'undefined' : _type_of(u)))
- )
- return !1;
- o = o[u];
- }
- return !0;
- }
- },
- {
- key: 'set',
- value: function set(s, o) {
- var i = __privateGet(this, kc),
- u = 0;
- for (u = 0; u < s.length - 1; u++) {
- var _ = s[u];
- Ec.call(i, _) || (i[_] = {}), (i = i[_]);
- }
- return (i[s[u]] = o), o;
- }
- },
- {
- key: 'map',
- value: function map(s) {
- return walk(__privateGet(this, kc), s, {
- immutable: !0,
- includeSymbols: !!__privateGet(this, Oc).includeSymbols
- });
- }
- },
- {
- key: 'forEach',
- value: function forEach(s) {
- return (
- __privateSet(this, kc, walk(__privateGet(this, kc), s, __privateGet(this, Oc))),
- __privateGet(this, kc)
- );
- }
- },
- {
- key: 'reduce',
- value: function reduce(s, o) {
- var i = 1 === arguments.length,
- u = i ? __privateGet(this, kc) : o;
- return (
- this.forEach(function (o) {
- (this.isRoot && i) || (u = s.call(this, u, o));
- }),
- u
- );
- }
- },
- {
- key: 'paths',
- value: function paths() {
- var s = [];
- return (
- this.forEach(function () {
- s.push(this.path);
- }),
- s
- );
- }
- },
- {
- key: 'nodes',
- value: function nodes() {
- var s = [];
- return (
- this.forEach(function () {
- s.push(this.node);
- }),
- s
- );
- }
- },
- {
- key: 'clone',
- value: function clone() {
- var s = [],
- o = [],
- i = __privateGet(this, Oc);
- return is_typed_array(__privateGet(this, kc))
- ? __privateGet(this, kc).slice()
- : (function clone(u) {
- for (var _ = 0; _ < s.length; _++) if (s[_] === u) return o[_];
- if ('object' === (void 0 === u ? 'undefined' : _type_of(u)) && null !== u) {
- var w = legacy_copy(u, i);
- s.push(u), o.push(w);
- var x = i.includeSymbols ? own_enumerable_keys : Object.keys,
- C = !0,
- j = !1,
- L = void 0;
- try {
- for (
- var B, $ = x(u)[Symbol.iterator]();
- !(C = (B = $.next()).done);
- C = !0
- ) {
- var V = B.value;
- w[V] = clone(u[V]);
- }
- } catch (s) {
- (j = !0), (L = s);
- } finally {
- try {
- C || null == $.return || $.return();
- } finally {
- if (j) throw L;
- }
- }
- return s.pop(), o.pop(), w;
- }
- return u;
- })(__privateGet(this, kc));
- }
- }
- ]),
- Traverse
- );
- })();
- (kc = new WeakMap()), (Oc = new WeakMap());
- var traverse = function (s, o) {
- return new Ic(s, o);
- };
- (traverse.get = function (s, o, i) {
- return new Ic(s, i).get(o);
- }),
- (traverse.set = function (s, o, i, u) {
- return new Ic(s, u).set(o, i);
- }),
- (traverse.has = function (s, o, i) {
- return new Ic(s, i).has(o);
- }),
- (traverse.map = function (s, o, i) {
- return new Ic(s, i).map(o);
- }),
- (traverse.forEach = function (s, o, i) {
- return new Ic(s, i).forEach(o);
- }),
- (traverse.reduce = function (s, o, i, u) {
- return new Ic(s, u).reduce(o, i);
- }),
- (traverse.paths = function (s, o) {
- return new Ic(s, o).paths();
- }),
- (traverse.nodes = function (s, o) {
- return new Ic(s, o).nodes();
- }),
- (traverse.clone = function (s, o) {
- return new Ic(s, o).clone();
- });
- var Pc = traverse;
- const Mc = 'application/json, application/yaml',
- Nc = 'https://swagger.io',
- Rc = Object.freeze({ url: '/' }),
- Lc = ['properties'],
- Fc = ['properties'],
- qc = [
- 'definitions',
- 'parameters',
- 'responses',
- 'securityDefinitions',
- 'components/schemas',
- 'components/responses',
- 'components/parameters',
- 'components/securitySchemes'
- ],
- Kc = ['schema/example', 'items/example'];
- function isFreelyNamed(s) {
- const o = s[s.length - 1],
- i = s[s.length - 2],
- u = s.join('/');
- return (
- (Lc.indexOf(o) > -1 && -1 === Fc.indexOf(i)) ||
- qc.indexOf(u) > -1 ||
- Kc.some((s) => u.indexOf(s) > -1)
- );
- }
- function absolutifyPointer(s, o) {
- const [i, u] = s.split('#'),
- _ = null != o ? o : '',
- w = null != i ? i : '';
- let x;
- if (isHttpUrl(_)) x = resolve(_, w);
- else {
- const s = resolve(Nc, _),
- o = resolve(s, w).replace(Nc, '');
- x = w.startsWith('/') ? o : o.substring(1);
- }
- return u ? `${x}#${u}` : x;
- }
- const Hc = /^([a-z]+:\/\/|\/\/)/i;
- class JSONRefError extends Jo {}
- const Jc = {},
- Gc = new WeakMap(),
- Qc = [
- (s) => 'paths' === s[0] && 'responses' === s[3] && 'examples' === s[5],
- (s) =>
- 'paths' === s[0] && 'responses' === s[3] && 'content' === s[5] && 'example' === s[7],
- (s) =>
- 'paths' === s[0] &&
- 'responses' === s[3] &&
- 'content' === s[5] &&
- 'examples' === s[7] &&
- 'value' === s[9],
- (s) =>
- 'paths' === s[0] &&
- 'requestBody' === s[3] &&
- 'content' === s[4] &&
- 'example' === s[6],
- (s) =>
- 'paths' === s[0] &&
- 'requestBody' === s[3] &&
- 'content' === s[4] &&
- 'examples' === s[6] &&
- 'value' === s[8],
- (s) => 'paths' === s[0] && 'parameters' === s[2] && 'example' === s[4],
- (s) => 'paths' === s[0] && 'parameters' === s[3] && 'example' === s[5],
- (s) =>
- 'paths' === s[0] && 'parameters' === s[2] && 'examples' === s[4] && 'value' === s[6],
- (s) =>
- 'paths' === s[0] && 'parameters' === s[3] && 'examples' === s[5] && 'value' === s[7],
- (s) =>
- 'paths' === s[0] && 'parameters' === s[2] && 'content' === s[4] && 'example' === s[6],
- (s) =>
- 'paths' === s[0] &&
- 'parameters' === s[2] &&
- 'content' === s[4] &&
- 'examples' === s[6] &&
- 'value' === s[8],
- (s) =>
- 'paths' === s[0] && 'parameters' === s[3] && 'content' === s[4] && 'example' === s[7],
- (s) =>
- 'paths' === s[0] &&
- 'parameters' === s[3] &&
- 'content' === s[5] &&
- 'examples' === s[7] &&
- 'value' === s[9]
- ],
- eu = {
- key: '$ref',
- plugin: (s, o, i, u) => {
- const _ = u.getInstance(),
- w = i.slice(0, -1);
- if (isFreelyNamed(w) || ((s) => Qc.some((o) => o(s)))(w)) return;
- const { baseDoc: x } = u.getContext(i);
- if ('string' != typeof s)
- return new JSONRefError('$ref: must be a string (JSON-Ref)', {
- $ref: s,
- baseDoc: x,
- fullPath: i
- });
- const C = refs_split(s),
- j = C[0],
- L = C[1] || '';
- let B, $, V;
- try {
- B = x || j ? absoluteify(j, x) : null;
- } catch (o) {
- return wrapError(o, { pointer: L, $ref: s, basePath: B, fullPath: i });
- }
- if (
- (function pointerAlreadyInPath(s, o, i, u) {
- let _ = Gc.get(u);
- _ || ((_ = {}), Gc.set(u, _));
- const w = (function arrayToJsonPointer(s) {
- if (0 === s.length) return '';
- return `/${s.map(escapeJsonPointerToken).join('/')}`;
- })(i),
- x = `${o || '<specmap-base>'}#${s}`,
- C = w.replace(/allOf\/\d+\/?/g, ''),
- j = u.contextTree.get([]).baseDoc;
- if (o === j && pointerIsAParent(C, s)) return !0;
- let L = '';
- const B = i.some(
- (s) => (
- (L = `${L}/${escapeJsonPointerToken(s)}`),
- _[L] && _[L].some((s) => pointerIsAParent(s, x) || pointerIsAParent(x, s))
- )
- );
- if (B) return !0;
- return void (_[C] = (_[C] || []).concat(x));
- })(L, B, w, u) &&
- !_.useCircularStructures
- ) {
- const o = absolutifyPointer(s, B);
- return s === o ? null : zo.replace(i, o);
- }
- if (
- (null == B
- ? ((V = jsonPointerToArray(L)),
- ($ = u.get(V)),
- void 0 === $ &&
- ($ = new JSONRefError(`Could not resolve reference: ${s}`, {
- pointer: L,
- $ref: s,
- baseDoc: x,
- fullPath: i
- })))
- : (($ = extractFromDoc(B, L)),
- ($ =
- null != $.__value
- ? $.__value
- : $.catch((o) => {
- throw wrapError(o, { pointer: L, $ref: s, baseDoc: x, fullPath: i });
- }))),
- $ instanceof Error)
- )
- return [zo.remove(i), $];
- const U = absolutifyPointer(s, B),
- z = zo.replace(w, $, { $$ref: U });
- if (B && B !== x) return [z, zo.context(w, { baseDoc: B })];
- try {
- if (
- !(function patchValueAlreadyInPath(s, o) {
- const i = [s];
- return (
- o.path.reduce((s, o) => (i.push(s[o]), s[o]), s), pointToAncestor(o.value)
- );
- function pointToAncestor(s) {
- return (
- zo.isObject(s) &&
- (i.indexOf(s) >= 0 || Object.keys(s).some((o) => pointToAncestor(s[o])))
- );
- }
- })(u.state, z) ||
- _.useCircularStructures
- )
- return z;
- } catch (s) {
- return null;
- }
- }
- },
- tu = Object.assign(eu, {
- docCache: Jc,
- absoluteify,
- clearCache: function clearCache(s) {
- void 0 !== s
- ? delete Jc[s]
- : Object.keys(Jc).forEach((s) => {
- delete Jc[s];
- });
- },
- JSONRefError,
- wrapError,
- getDoc,
- split: refs_split,
- extractFromDoc,
- fetchJSON: function fetchJSON(s) {
- return fetch(s, { headers: { Accept: Mc }, loadSpec: !0 })
- .then((s) => s.text())
- .then((s) => mn.load(s));
- },
- extract,
- jsonPointerToArray,
- unescapeJsonPointerToken
- }),
- ru = tu;
- function absoluteify(s, o) {
- if (!Hc.test(s)) {
- if (!o)
- throw new JSONRefError(
- `Tried to resolve a relative URL, without having a basePath. path: '${s}' basePath: '${o}'`
- );
- return resolve(o, s);
- }
- return s;
- }
- function wrapError(s, o) {
- let i;
- return (
- (i =
- s && s.response && s.response.body
- ? `${s.response.body.code} ${s.response.body.message}`
- : s.message),
- new JSONRefError(`Could not resolve reference: ${i}`, { ...o, cause: s })
- );
- }
- function refs_split(s) {
- return (s + '').split('#');
- }
- function extractFromDoc(s, o) {
- const i = Jc[s];
- if (i && !zo.isPromise(i))
- try {
- const s = extract(o, i);
- return Object.assign(Promise.resolve(s), { __value: s });
- } catch (s) {
- return Promise.reject(s);
- }
- return getDoc(s).then((s) => extract(o, s));
- }
- function getDoc(s) {
- const o = Jc[s];
- return o
- ? zo.isPromise(o)
- ? o
- : Promise.resolve(o)
- : ((Jc[s] = tu.fetchJSON(s).then((o) => ((Jc[s] = o), o))), Jc[s]);
- }
- function extract(s, o) {
- const i = jsonPointerToArray(s);
- if (i.length < 1) return o;
- const u = zo.getIn(o, i);
- if (void 0 === u)
- throw new JSONRefError(`Could not resolve pointer: ${s} does not exist in document`, {
- pointer: s
- });
- return u;
- }
- function jsonPointerToArray(s) {
- if ('string' != typeof s) throw new TypeError('Expected a string, got a ' + typeof s);
- return (
- '/' === s[0] && (s = s.substr(1)),
- '' === s ? [] : s.split('/').map(unescapeJsonPointerToken)
- );
- }
- function unescapeJsonPointerToken(s) {
- if ('string' != typeof s) return s;
- return new URLSearchParams(`=${s.replace(/~1/g, '/').replace(/~0/g, '~')}`).get('');
- }
- function escapeJsonPointerToken(s) {
- return new URLSearchParams([['', s.replace(/~/g, '~0').replace(/\//g, '~1')]])
- .toString()
- .slice(1);
- }
- const pointerBoundaryChar = (s) => !s || '/' === s || '#' === s;
- function pointerIsAParent(s, o) {
- if (pointerBoundaryChar(o)) return !0;
- const i = s.charAt(o.length),
- u = o.slice(-1);
- return 0 === s.indexOf(o) && (!i || '/' === i || '#' === i) && '#' !== u;
- }
- const nu = {
- key: 'allOf',
- plugin: (s, o, i, u, _) => {
- if (_.meta && _.meta.$$ref) return;
- const w = i.slice(0, -1);
- if (isFreelyNamed(w)) return;
- if (!Array.isArray(s)) {
- const s = new TypeError('allOf must be an array');
- return (s.fullPath = i), s;
- }
- let x = !1,
- C = _.value;
- if (
- (w.forEach((s) => {
- C && (C = C[s]);
- }),
- (C = { ...C }),
- 0 === Object.keys(C).length)
- )
- return;
- delete C.allOf;
- const j = [];
- return (
- j.push(u.replace(w, {})),
- s.forEach((s, o) => {
- if (!u.isObject(s)) {
- if (x) return null;
- x = !0;
- const s = new TypeError('Elements in allOf must be objects');
- return (s.fullPath = i), j.push(s);
- }
- j.push(u.mergeDeep(w, s));
- const _ = (function generateAbsoluteRefPatches(
- s,
- o,
- {
- specmap: i,
- getBaseUrlForNodePath: u = (s) => i.getContext([...o, ...s]).baseDoc,
- targetKeys: _ = ['$ref', '$$ref']
- } = {}
- ) {
- const w = [];
- return (
- Pc(s).forEach(function callback() {
- if (_.includes(this.key) && 'string' == typeof this.node) {
- const s = this.path,
- _ = o.concat(this.path),
- x = absolutifyPointer(this.node, u(s));
- w.push(i.replace(_, x));
- }
- }),
- w
- );
- })(s, i.slice(0, -1), {
- getBaseUrlForNodePath: (s) => u.getContext([...i, o, ...s]).baseDoc,
- specmap: u
- });
- j.push(..._);
- }),
- C.example && j.push(u.remove([].concat(w, 'example'))),
- j.push(u.mergeDeep(w, C)),
- C.$$ref || j.push(u.remove([].concat(w, '$$ref'))),
- j
- );
- }
- },
- su = {
- key: 'parameters',
- plugin: (s, o, i, u) => {
- if (Array.isArray(s) && s.length) {
- const o = Object.assign([], s),
- _ = i.slice(0, -1),
- w = { ...zo.getIn(u.spec, _) };
- for (let _ = 0; _ < s.length; _ += 1) {
- const x = s[_];
- try {
- o[_].default = u.parameterMacro(w, x);
- } catch (s) {
- const o = new Error(s);
- return (o.fullPath = i), o;
- }
- }
- return zo.replace(i, o);
- }
- return zo.replace(i, s);
- }
- },
- ou = {
- key: 'properties',
- plugin: (s, o, i, u) => {
- const _ = { ...s };
- for (const o in s)
- try {
- _[o].default = u.modelPropertyMacro(_[o]);
- } catch (s) {
- const o = new Error(s);
- return (o.fullPath = i), o;
- }
- return zo.replace(i, _);
- }
- };
- class ContextTree {
- constructor(s) {
- this.root = context_tree_createNode(s || {});
- }
- set(s, o) {
- const i = this.getParent(s, !0);
- if (!i) return void context_tree_updateNode(this.root, o, null);
- const u = s[s.length - 1],
- { children: _ } = i;
- _[u] ? context_tree_updateNode(_[u], o, i) : (_[u] = context_tree_createNode(o, i));
- }
- get(s) {
- if ((s = s || []).length < 1) return this.root.value;
- let o,
- i,
- u = this.root;
- for (let _ = 0; _ < s.length && ((i = s[_]), (o = u.children), o[i]); _ += 1) u = o[i];
- return u && u.protoValue;
- }
- getParent(s, o) {
- return !s || s.length < 1
- ? null
- : s.length < 2
- ? this.root
- : s.slice(0, -1).reduce((s, i) => {
- if (!s) return s;
- const { children: u } = s;
- return !u[i] && o && (u[i] = context_tree_createNode(null, s)), u[i];
- }, this.root);
- }
- }
- function context_tree_createNode(s, o) {
- return context_tree_updateNode({ children: {} }, s, o);
- }
- function context_tree_updateNode(s, o, i) {
- return (
- (s.value = o || {}),
- (s.protoValue = i ? { ...i.protoValue, ...s.value } : s.value),
- Object.keys(s.children).forEach((o) => {
- const i = s.children[o];
- s.children[o] = context_tree_updateNode(i, i.value, s);
- }),
- s
- );
- }
- const specmap_noop = () => {};
- class SpecMap {
- static getPluginName(s) {
- return s.pluginName;
- }
- static getPatchesOfType(s, o) {
- return s.filter(o);
- }
- constructor(s) {
- Object.assign(
- this,
- {
- spec: '',
- debugLevel: 'info',
- plugins: [],
- pluginHistory: {},
- errors: [],
- mutations: [],
- promisedPatches: [],
- state: {},
- patches: [],
- context: {},
- contextTree: new ContextTree(),
- showDebug: !1,
- allPatches: [],
- pluginProp: 'specMap',
- libMethods: Object.assign(Object.create(this), zo, { getInstance: () => this }),
- allowMetaPatches: !1
- },
- s
- ),
- (this.get = this._get.bind(this)),
- (this.getContext = this._getContext.bind(this)),
- (this.hasRun = this._hasRun.bind(this)),
- (this.wrappedPlugins = this.plugins
- .map(this.wrapPlugin.bind(this))
- .filter(zo.isFunction)),
- this.patches.push(zo.add([], this.spec)),
- this.patches.push(zo.context([], this.context)),
- this.updatePatches(this.patches);
- }
- debug(s, ...o) {
- this.debugLevel === s && console.log(...o);
- }
- verbose(s, ...o) {
- 'verbose' === this.debugLevel && console.log(`[${s}] `, ...o);
- }
- wrapPlugin(s, o) {
- const { pathDiscriminator: i } = this;
- let u,
- _ = null;
- return (
- s[this.pluginProp]
- ? ((_ = s), (u = s[this.pluginProp]))
- : zo.isFunction(s)
- ? (u = s)
- : zo.isObject(s) &&
- (u = (function createKeyBasedPlugin(s) {
- const isSubPath = (s, o) =>
- !Array.isArray(s) || s.every((s, i) => s === o[i]);
- return function* generator(o, u) {
- const _ = {};
- for (const [s, i] of o.filter(zo.isAdditiveMutation).entries()) {
- if (!(s < 3e3)) return;
- yield* traverse(i.value, i.path, i);
- }
- function* traverse(o, w, x) {
- if (zo.isObject(o)) {
- const C = w.length - 1,
- j = w[C],
- L = w.indexOf('properties'),
- B = 'properties' === j && C === L,
- $ = u.allowMetaPatches && _[o.$$ref];
- for (const C of Object.keys(o)) {
- const j = o[C],
- L = w.concat(C),
- V = zo.isObject(j),
- U = o.$$ref;
- if (
- ($ ||
- (V &&
- (u.allowMetaPatches && U && (_[U] = !0),
- yield* traverse(j, L, x))),
- !B && C === s.key)
- ) {
- const o = isSubPath(i, w);
- (i && !o) || (yield s.plugin(j, C, L, u, x));
- }
- }
- } else s.key === w[w.length - 1] && (yield s.plugin(o, s.key, w, u));
- }
- };
- })(s)),
- Object.assign(u.bind(_), { pluginName: s.name || o, isGenerator: zo.isGenerator(u) })
- );
- }
- nextPlugin() {
- return this.wrappedPlugins.find((s) => this.getMutationsForPlugin(s).length > 0);
- }
- nextPromisedPatch() {
- if (this.promisedPatches.length > 0)
- return Promise.race(this.promisedPatches.map((s) => s.value));
- }
- getPluginHistory(s) {
- const o = this.constructor.getPluginName(s);
- return this.pluginHistory[o] || [];
- }
- getPluginRunCount(s) {
- return this.getPluginHistory(s).length;
- }
- getPluginHistoryTip(s) {
- const o = this.getPluginHistory(s);
- return (o && o[o.length - 1]) || {};
- }
- getPluginMutationIndex(s) {
- const o = this.getPluginHistoryTip(s).mutationIndex;
- return 'number' != typeof o ? -1 : o;
- }
- updatePluginHistory(s, o) {
- const i = this.constructor.getPluginName(s);
- (this.pluginHistory[i] = this.pluginHistory[i] || []), this.pluginHistory[i].push(o);
- }
- updatePatches(s) {
- zo.normalizeArray(s).forEach((s) => {
- if (s instanceof Error) this.errors.push(s);
- else
- try {
- if (!zo.isObject(s))
- return void this.debug('updatePatches', 'Got a non-object patch', s);
- if ((this.showDebug && this.allPatches.push(s), zo.isPromise(s.value)))
- return this.promisedPatches.push(s), void this.promisedPatchThen(s);
- if (zo.isContextPatch(s)) return void this.setContext(s.path, s.value);
- zo.isMutation(s) && this.updateMutations(s);
- } catch (s) {
- console.error(s), this.errors.push(s);
- }
- });
- }
- updateMutations(s) {
- 'object' == typeof s.value &&
- !Array.isArray(s.value) &&
- this.allowMetaPatches &&
- (s.value = { ...s.value });
- const o = zo.applyPatch(this.state, s, { allowMetaPatches: this.allowMetaPatches });
- o && (this.mutations.push(s), (this.state = o));
- }
- removePromisedPatch(s) {
- const o = this.promisedPatches.indexOf(s);
- o < 0
- ? this.debug("Tried to remove a promisedPatch that isn't there!")
- : this.promisedPatches.splice(o, 1);
- }
- promisedPatchThen(s) {
- return (
- (s.value = s.value
- .then((o) => {
- const i = { ...s, value: o };
- this.removePromisedPatch(s), this.updatePatches(i);
- })
- .catch((o) => {
- this.removePromisedPatch(s), this.updatePatches(o);
- })),
- s.value
- );
- }
- getMutations(s, o) {
- return (
- (s = s || 0),
- 'number' != typeof o && (o = this.mutations.length),
- this.mutations.slice(s, o)
- );
- }
- getCurrentMutations() {
- return this.getMutationsForPlugin(this.getCurrentPlugin());
- }
- getMutationsForPlugin(s) {
- const o = this.getPluginMutationIndex(s);
- return this.getMutations(o + 1);
- }
- getCurrentPlugin() {
- return this.currentPlugin;
- }
- getLib() {
- return this.libMethods;
- }
- _get(s) {
- return zo.getIn(this.state, s);
- }
- _getContext(s) {
- return this.contextTree.get(s);
- }
- setContext(s, o) {
- return this.contextTree.set(s, o);
- }
- _hasRun(s) {
- return this.getPluginRunCount(this.getCurrentPlugin()) > (s || 0);
- }
- dispatch() {
- const s = this,
- o = this.nextPlugin();
- if (!o) {
- const s = this.nextPromisedPatch();
- if (s) return s.then(() => this.dispatch()).catch(() => this.dispatch());
- const o = { spec: this.state, errors: this.errors };
- return this.showDebug && (o.patches = this.allPatches), Promise.resolve(o);
- }
- if (
- ((s.pluginCount = s.pluginCount || new WeakMap()),
- s.pluginCount.set(o, (s.pluginCount.get(o) || 0) + 1),
- s.pluginCount[o] > 100)
- )
- return Promise.resolve({
- spec: s.state,
- errors: s.errors.concat(new Error("We've reached a hard limit of 100 plugin runs"))
- });
- if (o !== this.currentPlugin && this.promisedPatches.length) {
- const s = this.promisedPatches.map((s) => s.value);
- return Promise.all(s.map((s) => s.then(specmap_noop, specmap_noop))).then(() =>
- this.dispatch()
- );
- }
- return (function executePlugin() {
- s.currentPlugin = o;
- const i = s.getCurrentMutations(),
- u = s.mutations.length - 1;
- try {
- if (o.isGenerator) for (const u of o(i, s.getLib())) updatePatches(u);
- else {
- updatePatches(o(i, s.getLib()));
- }
- } catch (s) {
- console.error(s), updatePatches([Object.assign(Object.create(s), { plugin: o })]);
- } finally {
- s.updatePluginHistory(o, { mutationIndex: u });
- }
- return s.dispatch();
- })();
- function updatePatches(i) {
- i && ((i = zo.fullyNormalizeArray(i)), s.updatePatches(i, o));
- }
- }
- }
- const iu = { refs: ru, allOf: nu, parameters: su, properties: ou };
- function makeFetchJSON(s, o = {}) {
- const { requestInterceptor: i, responseInterceptor: u } = o,
- _ = s.withCredentials ? 'include' : 'same-origin';
- return (o) =>
- s({
- url: o,
- loadSpec: !0,
- requestInterceptor: i,
- responseInterceptor: u,
- headers: { Accept: Mc },
- credentials: _
- }).then((s) => s.body);
- }
- function isFile(s, o) {
- return (
- o || 'undefined' == typeof navigator || (o = navigator),
- o && 'ReactNative' === o.product
- ? !(!s || 'object' != typeof s || 'string' != typeof s.uri)
- : ('undefined' != typeof File && s instanceof File) ||
- ('undefined' != typeof Blob && s instanceof Blob) ||
- !!ArrayBuffer.isView(s) ||
- (null !== s && 'object' == typeof s && 'function' == typeof s.pipe)
- );
- }
- function isArrayOfFile(s, o) {
- return Array.isArray(s) && s.some((s) => isFile(s, o));
- }
- class FileWithData extends File {
- constructor(s, o = '', i = {}) {
- super([s], o, i), (this.data = s);
- }
- valueOf() {
- return this.data;
- }
- toString() {
- return this.valueOf();
- }
- }
- const isRfc3986Reserved = (s) => ":/?#[]@!$&'()*+,;=".indexOf(s) > -1,
- isRfc3986Unreserved = (s) => /^[a-z0-9\-._~]+$/i.test(s);
- function encodeCharacters(s, o = 'reserved') {
- return [...s]
- .map((s) => {
- if (isRfc3986Unreserved(s)) return s;
- if (isRfc3986Reserved(s) && 'unsafe' === o) return s;
- const i = new TextEncoder();
- return Array.from(i.encode(s))
- .map((s) => `0${s.toString(16).toUpperCase()}`.slice(-2))
- .map((s) => `%${s}`)
- .join('');
- })
- .join('');
- }
- function stylize(s) {
- const { value: o } = s;
- return Array.isArray(o)
- ? (function encodeArray({ key: s, value: o, style: i, explode: u, escape: _ }) {
- if ('simple' === i) return o.map((s) => valueEncoder(s, _)).join(',');
- if ('label' === i) return `.${o.map((s) => valueEncoder(s, _)).join('.')}`;
- if ('matrix' === i)
- return o
- .map((s) => valueEncoder(s, _))
- .reduce((o, i) => (!o || u ? `${o || ''};${s}=${i}` : `${o},${i}`), '');
- if ('form' === i) {
- const i = u ? `&${s}=` : ',';
- return o.map((s) => valueEncoder(s, _)).join(i);
- }
- if ('spaceDelimited' === i) {
- const i = u ? `${s}=` : '';
- return o.map((s) => valueEncoder(s, _)).join(` ${i}`);
- }
- if ('pipeDelimited' === i) {
- const i = u ? `${s}=` : '';
- return o.map((s) => valueEncoder(s, _)).join(`|${i}`);
- }
- return;
- })(s)
- : 'object' == typeof o
- ? (function encodeObject({ key: s, value: o, style: i, explode: u, escape: _ }) {
- const w = Object.keys(o);
- if ('simple' === i)
- return w.reduce((s, i) => {
- const w = valueEncoder(o[i], _);
- return `${s ? `${s},` : ''}${i}${u ? '=' : ','}${w}`;
- }, '');
- if ('label' === i)
- return w.reduce((s, i) => {
- const w = valueEncoder(o[i], _);
- return `${s ? `${s}.` : '.'}${i}${u ? '=' : '.'}${w}`;
- }, '');
- if ('matrix' === i && u)
- return w.reduce(
- (s, i) => `${s ? `${s};` : ';'}${i}=${valueEncoder(o[i], _)}`,
- ''
- );
- if ('matrix' === i)
- return w.reduce((i, u) => {
- const w = valueEncoder(o[u], _);
- return `${i ? `${i},` : `;${s}=`}${u},${w}`;
- }, '');
- if ('form' === i)
- return w.reduce((s, i) => {
- const w = valueEncoder(o[i], _);
- return `${s ? `${s}${u ? '&' : ','}` : ''}${i}${u ? '=' : ','}${w}`;
- }, '');
- return;
- })(s)
- : (function encodePrimitive({ key: s, value: o, style: i, escape: u }) {
- if ('simple' === i) return valueEncoder(o, u);
- if ('label' === i) return `.${valueEncoder(o, u)}`;
- if ('matrix' === i) return `;${s}=${valueEncoder(o, u)}`;
- if ('form' === i) return valueEncoder(o, u);
- if ('deepObject' === i) return valueEncoder(o, u);
- return;
- })(s);
- }
- function valueEncoder(s, o = !1) {
- return (
- Array.isArray(s) || (null !== s && 'object' == typeof s)
- ? (s = JSON.stringify(s))
- : ('number' != typeof s && 'boolean' != typeof s) || (s = String(s)),
- o && s.length > 0 ? encodeCharacters(s, o) : s
- );
- }
- const au = { form: ',', spaceDelimited: '%20', pipeDelimited: '|' },
- lu = { csv: ',', ssv: '%20', tsv: '%09', pipes: '|' };
- function formatKeyValue(s, o, i = !1) {
- const {
- collectionFormat: u,
- allowEmptyValue: _,
- serializationOption: w,
- encoding: x
- } = o,
- C = 'object' != typeof o || Array.isArray(o) ? o : o.value,
- j = i ? (s) => s.toString() : (s) => encodeURIComponent(s),
- L = j(s);
- if (void 0 === C && _) return [[L, '']];
- if (isFile(C) || isArrayOfFile(C)) return [[L, C]];
- if (w) return formatKeyValueBySerializationOption(s, C, i, w);
- if (x) {
- if (
- [typeof x.style, typeof x.explode, typeof x.allowReserved].some(
- (s) => 'undefined' !== s
- )
- ) {
- const { style: o, explode: u, allowReserved: _ } = x;
- return formatKeyValueBySerializationOption(s, C, i, {
- style: o,
- explode: u,
- allowReserved: _
- });
- }
- if ('string' == typeof x.contentType) {
- if (x.contentType.startsWith('application/json')) {
- const s = j('string' == typeof C ? C : JSON.stringify(C));
- return [[L, new FileWithData(s, 'blob', { type: x.contentType })]];
- }
- const s = j(String(C));
- return [[L, new FileWithData(s, 'blob', { type: x.contentType })]];
- }
- return 'object' != typeof C
- ? [[L, j(C)]]
- : Array.isArray(C) && C.every((s) => 'object' != typeof s)
- ? [[L, C.map(j).join(',')]]
- : [[L, j(JSON.stringify(C))]];
- }
- return 'object' != typeof C
- ? [[L, j(C)]]
- : Array.isArray(C)
- ? 'multi' === u
- ? [[L, C.map(j)]]
- : [[L, C.map(j).join(lu[u || 'csv'])]]
- : [[L, '']];
- }
- function formatKeyValueBySerializationOption(s, o, i, u) {
- const _ = u.style || 'form',
- w = void 0 === u.explode ? 'form' === _ : u.explode,
- x = !i && (u && u.allowReserved ? 'unsafe' : 'reserved'),
- encodeFn = (s) => valueEncoder(s, x),
- C = i ? (s) => s : (s) => encodeFn(s);
- return 'object' != typeof o
- ? [[C(s), encodeFn(o)]]
- : Array.isArray(o)
- ? w
- ? [[C(s), o.map(encodeFn)]]
- : [[C(s), o.map(encodeFn).join(au[_])]]
- : 'deepObject' === _
- ? Object.keys(o).map((i) => [C(`${s}[${i}]`), encodeFn(o[i])])
- : w
- ? Object.keys(o).map((s) => [C(s), encodeFn(o[s])])
- : [
- [
- C(s),
- Object.keys(o)
- .map((s) => [`${C(s)},${encodeFn(o[s])}`])
- .join(',')
- ]
- ];
- }
- function encodeFormOrQuery(s) {
- return ((s, { encode: o = !0 } = {}) => {
- const buildNestedParams = (s, o, i) => (
- null == i
- ? s.append(o, '')
- : Array.isArray(i)
- ? i.reduce((i, u) => buildNestedParams(s, o, u), s)
- : i instanceof Date
- ? s.append(o, i.toISOString())
- : 'object' == typeof i
- ? Object.entries(i).reduce(
- (i, [u, _]) => buildNestedParams(s, `${o}[${u}]`, _),
- s
- )
- : s.append(o, i),
- s
- ),
- i = Object.entries(s).reduce(
- (s, [o, i]) => buildNestedParams(s, o, i),
- new URLSearchParams()
- ),
- u = String(i);
- return o ? u : decodeURIComponent(u);
- })(
- Object.keys(s).reduce((o, i) => {
- for (const [u, _] of formatKeyValue(i, s[i]))
- o[u] = _ instanceof FileWithData ? _.valueOf() : _;
- return o;
- }, {}),
- { encode: !1 }
- );
- }
- function serializeRequest(s = {}) {
- const { url: o = '', query: i, form: u } = s;
- if (u) {
- const o = Object.keys(u).some((s) => {
- const { value: o } = u[s];
- return isFile(o) || isArrayOfFile(o);
- }),
- i = s.headers['content-type'] || s.headers['Content-Type'];
- if (o || /multipart\/form-data/i.test(i)) {
- const o = (function request_buildFormData(s) {
- return Object.entries(s).reduce((s, [o, i]) => {
- for (const [u, _] of formatKeyValue(o, i, !0))
- if (Array.isArray(_))
- for (const o of _)
- if (ArrayBuffer.isView(o)) {
- const i = new Blob([o]);
- s.append(u, i);
- } else s.append(u, o);
- else if (ArrayBuffer.isView(_)) {
- const o = new Blob([_]);
- s.append(u, o);
- } else s.append(u, _);
- return s;
- }, new FormData());
- })(s.form);
- (s.formdata = o), (s.body = o);
- } else s.body = encodeFormOrQuery(u);
- delete s.form;
- }
- if (i) {
- const [u, _] = o.split('?');
- let w = '';
- if (_) {
- const s = new URLSearchParams(_);
- Object.keys(i).forEach((o) => s.delete(o)), (w = String(s));
- }
- const x = ((...s) => {
- const o = s.filter((s) => s).join('&');
- return o ? `?${o}` : '';
- })(w, encodeFormOrQuery(i));
- (s.url = u + x), delete s.query;
- }
- return s;
- }
- function serializeHeaders(s = {}) {
- return 'function' != typeof s.entries
- ? {}
- : Array.from(s.entries()).reduce(
- (s, [o, i]) => (
- (s[o] = (function serializeHeaderValue(s) {
- return s.includes(', ') ? s.split(', ') : s;
- })(i)),
- s
- ),
- {}
- );
- }
- function serializeResponse(s, o, { loadSpec: i = !1 } = {}) {
- const u = {
- ok: s.ok,
- url: s.url || o,
- status: s.status,
- statusText: s.statusText,
- headers: serializeHeaders(s.headers)
- },
- _ = u.headers['content-type'],
- w = i || ((s = '') => /(json|xml|yaml|text)\b/.test(s))(_);
- return (w ? s.text : s.blob || s.buffer).call(s).then((s) => {
- if (((u.text = s), (u.data = s), w))
- try {
- const o = (function parseBody(s, o) {
- return o && (0 === o.indexOf('application/json') || o.indexOf('+json') > 0)
- ? JSON.parse(s)
- : mn.load(s);
- })(s, _);
- (u.body = o), (u.obj = o);
- } catch (s) {
- u.parseError = s;
- }
- return u;
- });
- }
- async function http_http(s, o = {}) {
- 'object' == typeof s && (s = (o = s).url),
- (o.headers = o.headers || {}),
- (o = serializeRequest(o)).headers &&
- Object.keys(o.headers).forEach((s) => {
- const i = o.headers[s];
- 'string' == typeof i && (o.headers[s] = i.replace(/\n+/g, ' '));
- }),
- o.requestInterceptor && (o = (await o.requestInterceptor(o)) || o);
- const i = o.headers['content-type'] || o.headers['Content-Type'];
- let u;
- /multipart\/form-data/i.test(i) &&
- (delete o.headers['content-type'], delete o.headers['Content-Type']);
- try {
- (u = await (o.userFetch || fetch)(o.url, o)),
- (u = await serializeResponse(u, s, o)),
- o.responseInterceptor && (u = (await o.responseInterceptor(u)) || u);
- } catch (s) {
- if (!u) throw s;
- const o = new Error(u.statusText || `response status is ${u.status}`);
- throw ((o.status = u.status), (o.statusCode = u.status), (o.responseError = s), o);
- }
- if (!u.ok) {
- const s = new Error(u.statusText || `response status is ${u.status}`);
- throw ((s.status = u.status), (s.statusCode = u.status), (s.response = u), s);
- }
- return u;
- }
- const options_retrievalURI = (s) => {
- var o, i;
- const { baseDoc: u, url: _ } = s,
- w = null !== (o = null != u ? u : _) && void 0 !== o ? o : '';
- return 'string' ==
- typeof (null === (i = globalThis.document) || void 0 === i ? void 0 : i.baseURI)
- ? String(new URL(w, globalThis.document.baseURI))
- : w;
- },
- options_httpClient = (s) => {
- const { fetch: o, http: i } = s;
- return o || i || http_http;
- };
- async function resolveGenericStrategy(s) {
- const {
- spec: o,
- mode: i,
- allowMetaPatches: u = !0,
- pathDiscriminator: _,
- modelPropertyMacro: w,
- parameterMacro: x,
- requestInterceptor: C,
- responseInterceptor: j,
- skipNormalization: L = !1,
- useCircularStructures: B,
- strategies: $
- } = s,
- V = options_retrievalURI(s),
- U = options_httpClient(s),
- z = $.find((s) => s.match(o));
- return (async function doResolve(s) {
- V && (iu.refs.docCache[V] = s);
- iu.refs.fetchJSON = makeFetchJSON(U, { requestInterceptor: C, responseInterceptor: j });
- const o = [iu.refs];
- 'function' == typeof x && o.push(iu.parameters);
- 'function' == typeof w && o.push(iu.properties);
- 'strict' !== i && o.push(iu.allOf);
- const $ = await (function mapSpec(s) {
- return new SpecMap(s).dispatch();
- })({
- spec: s,
- context: { baseDoc: V },
- plugins: o,
- allowMetaPatches: u,
- pathDiscriminator: _,
- parameterMacro: x,
- modelPropertyMacro: w,
- useCircularStructures: B
- });
- L || ($.spec = z.normalize($.spec));
- return $;
- })(o);
- }
- const replace_special_chars_with_underscore = (s) => s.replace(/\W/gi, '_');
- function opId(s, o, i = '', { v2OperationIdCompatibilityMode: u } = {}) {
- if (!s || 'object' != typeof s) return null;
- return (s.operationId || '').replace(/\s/g, '').length
- ? replace_special_chars_with_underscore(s.operationId)
- : (function idFromPathMethod(s, o, { v2OperationIdCompatibilityMode: i } = {}) {
- if (i) {
- let i = `${o.toLowerCase()}_${s}`.replace(
- /[\s!@#$%^&*()_+=[{\]};:<>|./?,\\'""-]/g,
- '_'
- );
- return (
- (i = i || `${s.substring(1)}_${o}`),
- i
- .replace(/((_){2,})/g, '_')
- .replace(/^(_)*/g, '')
- .replace(/([_])*$/g, '')
- );
- }
- return `${o.toLowerCase()}${replace_special_chars_with_underscore(s)}`;
- })(o, i, { v2OperationIdCompatibilityMode: u });
- }
- function normalize(s) {
- const { spec: o } = s,
- { paths: i } = o,
- u = {};
- if (!i || o.$$normalized) return s;
- for (const s in i) {
- const _ = i[s];
- if (null == _ || !['object', 'function'].includes(typeof _)) continue;
- const w = _.parameters;
- for (const i in _) {
- const x = _[i];
- if (null == x || !['object', 'function'].includes(typeof x)) continue;
- const C = opId(x, s, i);
- if (C) {
- u[C] ? u[C].push(x) : (u[C] = [x]);
- const s = u[C];
- if (s.length > 1)
- s.forEach((s, o) => {
- (s.__originalOperationId = s.__originalOperationId || s.operationId),
- (s.operationId = `${C}${o + 1}`);
- });
- else if (void 0 !== x.operationId) {
- const o = s[0];
- (o.__originalOperationId = o.__originalOperationId || x.operationId),
- (o.operationId = C);
- }
- }
- if ('parameters' !== i) {
- const s = [],
- i = {};
- for (const u in o)
- ('produces' !== u && 'consumes' !== u && 'security' !== u) ||
- ((i[u] = o[u]), s.push(i));
- if ((w && ((i.parameters = w), s.push(i)), s.length))
- for (const o of s)
- for (const s in o)
- if (x[s]) {
- if ('parameters' === s)
- for (const i of o[s]) {
- x[s].some(
- (s) =>
- (s.name && s.name === i.name) ||
- (s.$ref && s.$ref === i.$ref) ||
- (s.$$ref && s.$$ref === i.$$ref) ||
- s === i
- ) || x[s].push(i);
- }
- } else x[s] = o[s];
- }
- }
- }
- return (o.$$normalized = !0), s;
- }
- const cu = {
- name: 'generic',
- match: () => !0,
- normalize(s) {
- const { spec: o } = normalize({ spec: s });
- return o;
- },
- resolve: async (s) => resolveGenericStrategy(s)
- },
- uu = cu;
- const isOpenAPI30 = (s) => {
- try {
- const { openapi: o } = s;
- return 'string' == typeof o && /^3\.0\.([0123])(?:-rc[012])?$/.test(o);
- } catch {
- return !1;
- }
- },
- isOpenAPI31 = (s) => {
- try {
- const { openapi: o } = s;
- return 'string' == typeof o && /^3\.1\.(?:[1-9]\d*|0)$/.test(o);
- } catch {
- return !1;
- }
- },
- isOpenAPI3 = (s) => isOpenAPI30(s) || isOpenAPI31(s),
- pu = {
- name: 'openapi-2',
- match: (s) =>
- ((s) => {
- try {
- const { swagger: o } = s;
- return '2.0' === o;
- } catch {
- return !1;
- }
- })(s),
- normalize(s) {
- const { spec: o } = normalize({ spec: s });
- return o;
- },
- resolve: async (s) =>
- (async function resolveOpenAPI2Strategy(s) {
- return resolveGenericStrategy(s);
- })(s)
- },
- hu = pu;
- const du = {
- name: 'openapi-3-0',
- match: (s) => isOpenAPI30(s),
- normalize(s) {
- const { spec: o } = normalize({ spec: s });
- return o;
- },
- resolve: async (s) =>
- (async function resolveOpenAPI30Strategy(s) {
- return resolveGenericStrategy(s);
- })(s)
- },
- fu = du;
- const mu = _curry2(function and(s, o) {
- return s && o;
- });
- const gu = _curry2(function both(s, o) {
- return _isFunction(s)
- ? function _both() {
- return s.apply(this, arguments) && o.apply(this, arguments);
- }
- : Pl(mu)(s, o);
- });
- const yu = ra(null);
- const vu = Ml(yu);
- function isOfTypeObject_typeof(s) {
- return (
- (isOfTypeObject_typeof =
- 'function' == typeof Symbol && 'symbol' == typeof Symbol.iterator
- ? function (s) {
- return typeof s;
- }
- : function (s) {
- return s &&
- 'function' == typeof Symbol &&
- s.constructor === Symbol &&
- s !== Symbol.prototype
- ? 'symbol'
- : typeof s;
- }),
- isOfTypeObject_typeof(s)
- );
- }
- const bu = function isOfTypeObject(s) {
- return 'object' === isOfTypeObject_typeof(s);
- };
- const _u = za(1, gu(vu, bu));
- var Eu = pipe(ea, Vl('Object')),
- wu = pipe(ma, ra(ma(Object))),
- Su = Xo(gu(Wl, wu), ['constructor']),
- xu = za(1, function (s) {
- if (!_u(s) || !Eu(s)) return !1;
- var o = Object.getPrototypeOf(s);
- return !!yu(o) || Su(o);
- });
- const ku = xu;
- var Cu = __webpack_require__(34035);
- function _reduced(s) {
- return s && s['@@transducer/reduced']
- ? s
- : { '@@transducer/value': s, '@@transducer/reduced': !0 };
- }
- var Ou = (function () {
- function XAll(s, o) {
- (this.xf = o), (this.f = s), (this.all = !0);
- }
- return (
- (XAll.prototype['@@transducer/init'] = _xfBase_init),
- (XAll.prototype['@@transducer/result'] = function (s) {
- return (
- this.all && (s = this.xf['@@transducer/step'](s, !0)),
- this.xf['@@transducer/result'](s)
- );
- }),
- (XAll.prototype['@@transducer/step'] = function (s, o) {
- return (
- this.f(o) || ((this.all = !1), (s = _reduced(this.xf['@@transducer/step'](s, !1)))),
- s
- );
- }),
- XAll
- );
- })();
- function _xall(s) {
- return function (o) {
- return new Ou(s, o);
- };
- }
- var Au = _curry2(
- _dispatchable(['all'], _xall, function all(s, o) {
- for (var i = 0; i < o.length; ) {
- if (!s(o[i])) return !1;
- i += 1;
- }
- return !0;
- })
- );
- const ju = Au;
- class Annotation extends Cu.Om {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'annotation');
- }
- get code() {
- return this.attributes.get('code');
- }
- set code(s) {
- this.attributes.set('code', s);
- }
- }
- const Iu = Annotation;
- class Comment extends Cu.Om {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'comment');
- }
- }
- const Pu = Comment;
- class ParseResult extends Cu.wE {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'parseResult');
- }
- get api() {
- return this.children.filter((s) => s.classes.contains('api')).first;
- }
- get results() {
- return this.children.filter((s) => s.classes.contains('result'));
- }
- get result() {
- return this.results.first;
- }
- get annotations() {
- return this.children.filter((s) => 'annotation' === s.element);
- }
- get warnings() {
- return this.children.filter(
- (s) => 'annotation' === s.element && s.classes.contains('warning')
- );
- }
- get errors() {
- return this.children.filter(
- (s) => 'annotation' === s.element && s.classes.contains('error')
- );
- }
- get isEmpty() {
- return this.children.reject((s) => 'annotation' === s.element).isEmpty;
- }
- replaceResult(s) {
- const { result: o } = this;
- if (Rl(o)) return !1;
- const i = this.content.findIndex((s) => s === o);
- return -1 !== i && ((this.content[i] = s), !0);
- }
- }
- const Mu = ParseResult;
- class SourceMap extends Cu.wE {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'sourceMap');
- }
- get positionStart() {
- return this.children.filter((s) => s.classes.contains('position')).get(0);
- }
- get positionEnd() {
- return this.children.filter((s) => s.classes.contains('position')).get(1);
- }
- set position(s) {
- if (void 0 === s) return;
- const o = new Cu.wE([s.start.row, s.start.column, s.start.char]),
- i = new Cu.wE([s.end.row, s.end.column, s.end.char]);
- o.classes.push('position'), i.classes.push('position'), this.push(o).push(i);
- }
- }
- const Tu = SourceMap,
- hasMethod = (s, o) =>
- 'object' == typeof o && null !== o && s in o && 'function' == typeof o[s],
- hasBasicElementProps = (s) =>
- 'object' == typeof s &&
- null != s &&
- '_storedElement' in s &&
- 'string' == typeof s._storedElement &&
- '_content' in s,
- primitiveEq = (s, o) =>
- 'object' == typeof o &&
- null !== o &&
- 'primitive' in o &&
- 'function' == typeof o.primitive &&
- o.primitive() === s,
- hasClass = (s, o) =>
- 'object' == typeof o &&
- null !== o &&
- 'classes' in o &&
- (Array.isArray(o.classes) || o.classes instanceof Cu.wE) &&
- o.classes.includes(s),
- isElementType = (s, o) =>
- 'object' == typeof o && null !== o && 'element' in o && o.element === s,
- helpers = (s) =>
- s({ hasMethod, hasBasicElementProps, primitiveEq, isElementType, hasClass }),
- Nu = helpers(
- ({ hasBasicElementProps: s, primitiveEq: o }) =>
- (i) =>
- i instanceof Cu.Hg || (s(i) && o(void 0, i))
- ),
- Ru = helpers(
- ({ hasBasicElementProps: s, primitiveEq: o }) =>
- (i) =>
- i instanceof Cu.Om || (s(i) && o('string', i))
- ),
- Du = helpers(
- ({ hasBasicElementProps: s, primitiveEq: o }) =>
- (i) =>
- i instanceof Cu.kT || (s(i) && o('number', i))
- ),
- Lu = helpers(
- ({ hasBasicElementProps: s, primitiveEq: o }) =>
- (i) =>
- i instanceof Cu.Os || (s(i) && o('null', i))
- ),
- Bu = helpers(
- ({ hasBasicElementProps: s, primitiveEq: o }) =>
- (i) =>
- i instanceof Cu.bd || (s(i) && o('boolean', i))
- ),
- Fu = helpers(
- ({ hasBasicElementProps: s, primitiveEq: o, hasMethod: i }) =>
- (u) =>
- u instanceof Cu.Sh ||
- (s(u) && o('object', u) && i('keys', u) && i('values', u) && i('items', u))
- ),
- qu = helpers(
- ({ hasBasicElementProps: s, primitiveEq: o, hasMethod: i }) =>
- (u) =>
- (u instanceof Cu.wE && !(u instanceof Cu.Sh)) ||
- (s(u) &&
- o('array', u) &&
- i('push', u) &&
- i('unshift', u) &&
- i('map', u) &&
- i('reduce', u))
- ),
- $u = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Cu.Pr || (s(u) && o('member', u) && i(void 0, u))
- ),
- Vu = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Cu.Ft || (s(u) && o('link', u) && i(void 0, u))
- ),
- Uu = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Cu.sI || (s(u) && o('ref', u) && i(void 0, u))
- ),
- zu = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Iu || (s(u) && o('annotation', u) && i('array', u))
- ),
- Wu = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Pu || (s(u) && o('comment', u) && i('string', u))
- ),
- Ku = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Mu || (s(u) && o('parseResult', u) && i('array', u))
- ),
- Hu = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Tu || (s(u) && o('sourceMap', u) && i('array', u))
- ),
- isPrimitiveElement = (s) =>
- isElementType('object', s) ||
- isElementType('array', s) ||
- isElementType('boolean', s) ||
- isElementType('number', s) ||
- isElementType('string', s) ||
- isElementType('null', s) ||
- isElementType('member', s),
- hasElementSourceMap = (s) => Hu(s.meta.get('sourceMap')),
- includesSymbols = (s, o) => {
- if (0 === s.length) return !0;
- const i = o.attributes.get('symbols');
- return !!qu(i) && ju(_l(i.toValue()), s);
- },
- includesClasses = (s, o) => 0 === s.length || ju(_l(o.classes.toValue()), s);
- const es_T = function () {
- return !0;
- };
- const es_F = function () {
- return !1;
- },
- getVisitFn = (s, o, i) => {
- const u = s[o];
- if (null != u) {
- if (!i && 'function' == typeof u) return u;
- const s = i ? u.leave : u.enter;
- if ('function' == typeof s) return s;
- } else {
- const u = i ? s.leave : s.enter;
- if (null != u) {
- if ('function' == typeof u) return u;
- const s = u[o];
- if ('function' == typeof s) return s;
- }
- }
- return null;
- },
- Ju = {},
- getNodeType = (s) => (null == s ? void 0 : s.type),
- isNode = (s) => 'string' == typeof getNodeType(s),
- cloneNode = (s) =>
- Object.create(Object.getPrototypeOf(s), Object.getOwnPropertyDescriptors(s)),
- mergeAll = (
- s,
- {
- visitFnGetter: o = getVisitFn,
- nodeTypeGetter: i = getNodeType,
- breakSymbol: u = Ju,
- deleteNodeSymbol: _ = null,
- skipVisitingNodeSymbol: w = !1,
- exposeEdits: x = !1
- } = {}
- ) => {
- const C = Symbol('skip'),
- j = new Array(s.length).fill(C);
- return {
- enter(L, B, $, V, U, z) {
- let Y = L,
- Z = !1;
- const ee = {
- ...z,
- replaceWith(s, o) {
- z.replaceWith(s, o), (Y = s);
- }
- };
- for (let L = 0; L < s.length; L += 1)
- if (j[L] === C) {
- const C = o(s[L], i(Y), !1);
- if ('function' == typeof C) {
- const o = C.call(s[L], Y, B, $, V, U, ee);
- if ('function' == typeof (null == o ? void 0 : o.then))
- throw new Jo('Async visitor not supported in sync mode', {
- visitor: s[L],
- visitFn: C
- });
- if (o === w) j[L] = Y;
- else if (o === u) j[L] = u;
- else {
- if (o === _) return o;
- if (void 0 !== o) {
- if (!x) return o;
- (Y = o), (Z = !0);
- }
- }
- }
- }
- return Z ? Y : void 0;
- },
- leave(_, x, L, B, $, V) {
- let U = _;
- const z = {
- ...V,
- replaceWith(s, o) {
- V.replaceWith(s, o), (U = s);
- }
- };
- for (let _ = 0; _ < s.length; _ += 1)
- if (j[_] === C) {
- const C = o(s[_], i(U), !0);
- if ('function' == typeof C) {
- const o = C.call(s[_], U, x, L, B, $, z);
- if ('function' == typeof (null == o ? void 0 : o.then))
- throw new Jo('Async visitor not supported in sync mode', {
- visitor: s[_],
- visitFn: C
- });
- if (o === u) j[_] = u;
- else if (void 0 !== o && o !== w) return o;
- }
- } else j[_] === U && (j[_] = C);
- }
- };
- };
- mergeAll[Symbol.for('nodejs.util.promisify.custom')] = (
- s,
- {
- visitFnGetter: o = getVisitFn,
- nodeTypeGetter: i = getNodeType,
- breakSymbol: u = Ju,
- deleteNodeSymbol: _ = null,
- skipVisitingNodeSymbol: w = !1,
- exposeEdits: x = !1
- } = {}
- ) => {
- const C = Symbol('skip'),
- j = new Array(s.length).fill(C);
- return {
- async enter(L, B, $, V, U, z) {
- let Y = L,
- Z = !1;
- const ee = {
- ...z,
- replaceWith(s, o) {
- z.replaceWith(s, o), (Y = s);
- }
- };
- for (let L = 0; L < s.length; L += 1)
- if (j[L] === C) {
- const C = o(s[L], i(Y), !1);
- if ('function' == typeof C) {
- const o = await C.call(s[L], Y, B, $, V, U, ee);
- if (o === w) j[L] = Y;
- else if (o === u) j[L] = u;
- else {
- if (o === _) return o;
- if (void 0 !== o) {
- if (!x) return o;
- (Y = o), (Z = !0);
- }
- }
- }
- }
- return Z ? Y : void 0;
- },
- async leave(_, x, L, B, $, V) {
- let U = _;
- const z = {
- ...V,
- replaceWith(s, o) {
- V.replaceWith(s, o), (U = s);
- }
- };
- for (let _ = 0; _ < s.length; _ += 1)
- if (j[_] === C) {
- const C = o(s[_], i(U), !0);
- if ('function' == typeof C) {
- const o = await C.call(s[_], U, x, L, B, $, z);
- if (o === u) j[_] = u;
- else if (void 0 !== o && o !== w) return o;
- }
- } else j[_] === U && (j[_] = C);
- }
- };
- };
- const visit = (
- s,
- o,
- {
- keyMap: i = null,
- state: u = {},
- breakSymbol: _ = Ju,
- deleteNodeSymbol: w = null,
- skipVisitingNodeSymbol: x = !1,
- visitFnGetter: C = getVisitFn,
- nodeTypeGetter: j = getNodeType,
- nodePredicate: L = isNode,
- nodeCloneFn: B = cloneNode,
- detectCycles: $ = !0
- } = {}
- ) => {
- const V = i || {};
- let U,
- z,
- Y = Array.isArray(s),
- Z = [s],
- ee = -1,
- ie = [],
- ae = s;
- const le = [],
- ce = [];
- do {
- ee += 1;
- const s = ee === Z.length;
- let i;
- const fe = s && 0 !== ie.length;
- if (s) {
- if (((i = 0 === ce.length ? void 0 : le.pop()), (ae = z), (z = ce.pop()), fe))
- if (Y) {
- ae = ae.slice();
- let s = 0;
- for (const [o, i] of ie) {
- const u = o - s;
- i === w ? (ae.splice(u, 1), (s += 1)) : (ae[u] = i);
- }
- } else {
- ae = B(ae);
- for (const [s, o] of ie) ae[s] = o;
- }
- (ee = U.index), (Z = U.keys), (ie = U.edits), (Y = U.inArray), (U = U.prev);
- } else if (z !== w && void 0 !== z) {
- if (((i = Y ? ee : Z[ee]), (ae = z[i]), ae === w || void 0 === ae)) continue;
- le.push(i);
- }
- let ye;
- if (!Array.isArray(ae)) {
- var pe;
- if (!L(ae)) throw new Jo(`Invalid AST Node: ${String(ae)}`, { node: ae });
- if ($ && ce.includes(ae)) {
- le.pop();
- continue;
- }
- const w = C(o, j(ae), s);
- if (w) {
- for (const [s, i] of Object.entries(u)) o[s] = i;
- const _ = {
- replaceWith(o, u) {
- 'function' == typeof u ? u(o, ae, i, z, le, ce) : z && (z[i] = o),
- s || (ae = o);
- }
- };
- ye = w.call(o, ae, i, z, le, ce, _);
- }
- if ('function' == typeof (null === (pe = ye) || void 0 === pe ? void 0 : pe.then))
- throw new Jo('Async visitor not supported in sync mode', {
- visitor: o,
- visitFn: w
- });
- if (ye === _) break;
- if (ye === x) {
- if (!s) {
- le.pop();
- continue;
- }
- } else if (void 0 !== ye && (ie.push([i, ye]), !s)) {
- if (!L(ye)) {
- le.pop();
- continue;
- }
- ae = ye;
- }
- }
- var de;
- if ((void 0 === ye && fe && ie.push([i, ae]), !s))
- (U = { inArray: Y, index: ee, keys: Z, edits: ie, prev: U }),
- (Y = Array.isArray(ae)),
- (Z = Y ? ae : null !== (de = V[j(ae)]) && void 0 !== de ? de : []),
- (ee = -1),
- (ie = []),
- z !== w && void 0 !== z && ce.push(z),
- (z = ae);
- } while (void 0 !== U);
- return 0 !== ie.length ? ie[ie.length - 1][1] : s;
- };
- visit[Symbol.for('nodejs.util.promisify.custom')] = async (
- s,
- o,
- {
- keyMap: i = null,
- state: u = {},
- breakSymbol: _ = Ju,
- deleteNodeSymbol: w = null,
- skipVisitingNodeSymbol: x = !1,
- visitFnGetter: C = getVisitFn,
- nodeTypeGetter: j = getNodeType,
- nodePredicate: L = isNode,
- nodeCloneFn: B = cloneNode,
- detectCycles: $ = !0
- } = {}
- ) => {
- const V = i || {};
- let U,
- z,
- Y = Array.isArray(s),
- Z = [s],
- ee = -1,
- ie = [],
- ae = s;
- const le = [],
- ce = [];
- do {
- ee += 1;
- const s = ee === Z.length;
- let i;
- const de = s && 0 !== ie.length;
- if (s) {
- if (((i = 0 === ce.length ? void 0 : le.pop()), (ae = z), (z = ce.pop()), de))
- if (Y) {
- ae = ae.slice();
- let s = 0;
- for (const [o, i] of ie) {
- const u = o - s;
- i === w ? (ae.splice(u, 1), (s += 1)) : (ae[u] = i);
- }
- } else {
- ae = B(ae);
- for (const [s, o] of ie) ae[s] = o;
- }
- (ee = U.index), (Z = U.keys), (ie = U.edits), (Y = U.inArray), (U = U.prev);
- } else if (z !== w && void 0 !== z) {
- if (((i = Y ? ee : Z[ee]), (ae = z[i]), ae === w || void 0 === ae)) continue;
- le.push(i);
- }
- let fe;
- if (!Array.isArray(ae)) {
- if (!L(ae)) throw new Jo(`Invalid AST Node: ${String(ae)}`, { node: ae });
- if ($ && ce.includes(ae)) {
- le.pop();
- continue;
- }
- const w = C(o, j(ae), s);
- if (w) {
- for (const [s, i] of Object.entries(u)) o[s] = i;
- const _ = {
- replaceWith(o, u) {
- 'function' == typeof u ? u(o, ae, i, z, le, ce) : z && (z[i] = o),
- s || (ae = o);
- }
- };
- fe = await w.call(o, ae, i, z, le, ce, _);
- }
- if (fe === _) break;
- if (fe === x) {
- if (!s) {
- le.pop();
- continue;
- }
- } else if (void 0 !== fe && (ie.push([i, fe]), !s)) {
- if (!L(fe)) {
- le.pop();
- continue;
- }
- ae = fe;
- }
- }
- var pe;
- if ((void 0 === fe && de && ie.push([i, ae]), !s))
- (U = { inArray: Y, index: ee, keys: Z, edits: ie, prev: U }),
- (Y = Array.isArray(ae)),
- (Z = Y ? ae : null !== (pe = V[j(ae)]) && void 0 !== pe ? pe : []),
- (ee = -1),
- (ie = []),
- z !== w && void 0 !== z && ce.push(z),
- (z = ae);
- } while (void 0 !== U);
- return 0 !== ie.length ? ie[ie.length - 1][1] : s;
- };
- const Gu = class CloneError extends Jo {
- value;
- constructor(s, o) {
- super(s, o), void 0 !== o && (this.value = o.value);
- }
- };
- const Yu = class DeepCloneError extends Gu {};
- const Xu = class ShallowCloneError extends Gu {},
- cloneDeep = (s, o = {}) => {
- const { visited: i = new WeakMap() } = o,
- u = { ...o, visited: i };
- if (i.has(s)) return i.get(s);
- if (s instanceof Cu.KeyValuePair) {
- const { key: o, value: _ } = s,
- w = Nu(o) ? cloneDeep(o, u) : o,
- x = Nu(_) ? cloneDeep(_, u) : _,
- C = new Cu.KeyValuePair(w, x);
- return i.set(s, C), C;
- }
- if (s instanceof Cu.ot) {
- const mapper = (s) => cloneDeep(s, u),
- o = [...s].map(mapper),
- _ = new Cu.ot(o);
- return i.set(s, _), _;
- }
- if (s instanceof Cu.G6) {
- const mapper = (s) => cloneDeep(s, u),
- o = [...s].map(mapper),
- _ = new Cu.G6(o);
- return i.set(s, _), _;
- }
- if (Nu(s)) {
- const o = cloneShallow(s);
- if ((i.set(s, o), s.content))
- if (Nu(s.content)) o.content = cloneDeep(s.content, u);
- else if (s.content instanceof Cu.KeyValuePair) o.content = cloneDeep(s.content, u);
- else if (Array.isArray(s.content)) {
- const mapper = (s) => cloneDeep(s, u);
- o.content = s.content.map(mapper);
- } else o.content = s.content;
- else o.content = s.content;
- return o;
- }
- throw new Yu("Value provided to cloneDeep function couldn't be cloned", { value: s });
- };
- cloneDeep.safe = (s) => {
- try {
- return cloneDeep(s);
- } catch {
- return s;
- }
- };
- const cloneShallowKeyValuePair = (s) => {
- const { key: o, value: i } = s;
- return new Cu.KeyValuePair(o, i);
- },
- cloneShallowElement = (s) => {
- const o = new s.constructor();
- if (
- ((o.element = s.element),
- s.meta.length > 0 && (o._meta = cloneDeep(s.meta)),
- s.attributes.length > 0 && (o._attributes = cloneDeep(s.attributes)),
- Nu(s.content))
- ) {
- const i = s.content;
- o.content = cloneShallowElement(i);
- } else
- Array.isArray(s.content)
- ? (o.content = [...s.content])
- : s.content instanceof Cu.KeyValuePair
- ? (o.content = cloneShallowKeyValuePair(s.content))
- : (o.content = s.content);
- return o;
- },
- cloneShallow = (s) => {
- if (s instanceof Cu.KeyValuePair) return cloneShallowKeyValuePair(s);
- if (s instanceof Cu.ot)
- return ((s) => {
- const o = [...s];
- return new Cu.ot(o);
- })(s);
- if (s instanceof Cu.G6)
- return ((s) => {
- const o = [...s];
- return new Cu.G6(o);
- })(s);
- if (Nu(s)) return cloneShallowElement(s);
- throw new Xu("Value provided to cloneShallow function couldn't be cloned", {
- value: s
- });
- };
- cloneShallow.safe = (s) => {
- try {
- return cloneShallow(s);
- } catch {
- return s;
- }
- };
- const visitor_getNodeType = (s) =>
- Fu(s)
- ? 'ObjectElement'
- : qu(s)
- ? 'ArrayElement'
- : $u(s)
- ? 'MemberElement'
- : Ru(s)
- ? 'StringElement'
- : Bu(s)
- ? 'BooleanElement'
- : Du(s)
- ? 'NumberElement'
- : Lu(s)
- ? 'NullElement'
- : Vu(s)
- ? 'LinkElement'
- : Uu(s)
- ? 'RefElement'
- : void 0,
- visitor_cloneNode = (s) => (Nu(s) ? cloneShallow(s) : cloneNode(s)),
- Zu = pipe(visitor_getNodeType, Yl),
- Qu = {
- ObjectElement: ['content'],
- ArrayElement: ['content'],
- MemberElement: ['key', 'value'],
- StringElement: [],
- BooleanElement: [],
- NumberElement: [],
- NullElement: [],
- RefElement: [],
- LinkElement: [],
- Annotation: [],
- Comment: [],
- ParseResultElement: ['content'],
- SourceMap: ['content']
- };
- class PredicateVisitor {
- result;
- predicate;
- returnOnTrue;
- returnOnFalse;
- constructor({ predicate: s = es_F, returnOnTrue: o, returnOnFalse: i } = {}) {
- (this.result = []),
- (this.predicate = s),
- (this.returnOnTrue = o),
- (this.returnOnFalse = i);
- }
- enter(s) {
- return this.predicate(s)
- ? (this.result.push(s), this.returnOnTrue)
- : this.returnOnFalse;
- }
- }
- const visitor_visit = (s, o, { keyMap: i = Qu, ...u } = {}) =>
- visit(s, o, {
- keyMap: i,
- nodeTypeGetter: visitor_getNodeType,
- nodePredicate: Zu,
- nodeCloneFn: visitor_cloneNode,
- ...u
- });
- visitor_visit[Symbol.for('nodejs.util.promisify.custom')] = async (
- s,
- o,
- { keyMap: i = Qu, ...u } = {}
- ) =>
- visit[Symbol.for('nodejs.util.promisify.custom')](s, o, {
- keyMap: i,
- nodeTypeGetter: visitor_getNodeType,
- nodePredicate: Zu,
- nodeCloneFn: visitor_cloneNode,
- ...u
- });
- const nodeTypeGetter = (s) =>
- 'string' == typeof (null == s ? void 0 : s.type) ? s.type : visitor_getNodeType(s),
- ep = { EphemeralObject: ['content'], EphemeralArray: ['content'], ...Qu },
- value_visitor_visit = (s, o, { keyMap: i = ep, ...u } = {}) =>
- visitor_visit(s, o, {
- keyMap: i,
- nodeTypeGetter,
- nodePredicate: es_T,
- detectCycles: !1,
- deleteNodeSymbol: Symbol.for('delete-node'),
- skipVisitingNodeSymbol: Symbol.for('skip-visiting-node'),
- ...u
- });
- value_visitor_visit[Symbol.for('nodejs.util.promisify.custom')] = async (
- s,
- { keyMap: o = ep, ...i } = {}
- ) =>
- visitor_visit[Symbol.for('nodejs.util.promisify.custom')](s, visitor, {
- keyMap: o,
- nodeTypeGetter,
- nodePredicate: es_T,
- detectCycles: !1,
- deleteNodeSymbol: Symbol.for('delete-node'),
- skipVisitingNodeSymbol: Symbol.for('skip-visiting-node'),
- ...i
- });
- const tp = class EphemeralArray {
- type = 'EphemeralArray';
- content = [];
- reference = void 0;
- constructor(s) {
- (this.content = s), (this.reference = []);
- }
- toReference() {
- return this.reference;
- }
- toArray() {
- return this.reference.push(...this.content), this.reference;
- }
- };
- const rp = class EphemeralObject {
- type = 'EphemeralObject';
- content = [];
- reference = void 0;
- constructor(s) {
- (this.content = s), (this.reference = {});
- }
- toReference() {
- return this.reference;
- }
- toObject() {
- return Object.assign(this.reference, Object.fromEntries(this.content));
- }
- };
- class Visitor {
- ObjectElement = {
- enter: (s) => {
- if (this.references.has(s)) return this.references.get(s).toReference();
- const o = new rp(s.content);
- return this.references.set(s, o), o;
- }
- };
- EphemeralObject = { leave: (s) => s.toObject() };
- MemberElement = { enter: (s) => [s.key, s.value] };
- ArrayElement = {
- enter: (s) => {
- if (this.references.has(s)) return this.references.get(s).toReference();
- const o = new tp(s.content);
- return this.references.set(s, o), o;
- }
- };
- EphemeralArray = { leave: (s) => s.toArray() };
- references = new WeakMap();
- BooleanElement(s) {
- return s.toValue();
- }
- NumberElement(s) {
- return s.toValue();
- }
- StringElement(s) {
- return s.toValue();
- }
- NullElement() {
- return null;
- }
- RefElement(s, ...o) {
- var i;
- const u = o[3];
- return 'EphemeralObject' ===
- (null === (i = u[u.length - 1]) || void 0 === i ? void 0 : i.type)
- ? Symbol.for('delete-node')
- : String(s.toValue());
- }
- LinkElement(s) {
- return Ru(s.href) ? s.href.toValue() : '';
- }
- }
- const serializers_value = (s) =>
- Nu(s)
- ? Ru(s) || Du(s) || Bu(s) || Lu(s)
- ? s.toValue()
- : value_visitor_visit(s, new Visitor())
- : s;
- var np = _curry3(function mergeWithKey(s, o, i) {
- var u,
- _ = {};
- for (u in ((i = i || {}), (o = o || {})))
- _has(u, o) && (_[u] = _has(u, i) ? s(u, o[u], i[u]) : o[u]);
- for (u in i) _has(u, i) && !_has(u, _) && (_[u] = i[u]);
- return _;
- });
- const sp = np;
- var op = _curry3(function mergeDeepWithKey(s, o, i) {
- return sp(
- function (o, i, u) {
- return _isObject(i) && _isObject(u) ? mergeDeepWithKey(s, i, u) : s(o, i, u);
- },
- o,
- i
- );
- });
- const ip = op;
- const lp = _curry2(function mergeDeepRight(s, o) {
- return ip(
- function (s, o, i) {
- return i;
- },
- s,
- o
- );
- });
- const cp = _curry2(_path);
- const up = ja(0, -1);
- var pp = _curry2(function apply(s, o) {
- return s.apply(this, o);
- });
- const hp = pp;
- const dp = Ml(Wl);
- var fp = _curry1(function empty(s) {
- return null != s && 'function' == typeof s['fantasy-land/empty']
- ? s['fantasy-land/empty']()
- : null != s &&
- null != s.constructor &&
- 'function' == typeof s.constructor['fantasy-land/empty']
- ? s.constructor['fantasy-land/empty']()
- : null != s && 'function' == typeof s.empty
- ? s.empty()
- : null != s && null != s.constructor && 'function' == typeof s.constructor.empty
- ? s.constructor.empty()
- : aa(s)
- ? []
- : _isString(s)
- ? ''
- : _isObject(s)
- ? {}
- : _i(s)
- ? (function () {
- return arguments;
- })()
- : (function _isTypedArray(s) {
- var o = Object.prototype.toString.call(s);
- return (
- '[object Uint8ClampedArray]' === o ||
- '[object Int8Array]' === o ||
- '[object Uint8Array]' === o ||
- '[object Int16Array]' === o ||
- '[object Uint16Array]' === o ||
- '[object Int32Array]' === o ||
- '[object Uint32Array]' === o ||
- '[object Float32Array]' === o ||
- '[object Float64Array]' === o ||
- '[object BigInt64Array]' === o ||
- '[object BigUint64Array]' === o
- );
- })(s)
- ? s.constructor.from('')
- : void 0;
- });
- const mp = fp;
- const gp = _curry1(function isEmpty(s) {
- return null != s && ra(s, mp(s));
- });
- const yp = za(1, Wl(Array.isArray) ? Array.isArray : pipe(ea, Vl('Array')));
- const vp = gu(yp, gp);
- var bp = za(3, function (s, o, i) {
- var u = cp(s, i),
- _ = cp(up(s), i);
- if (!dp(u) && !vp(s)) {
- var w = Ea(u, _);
- return hp(w, o);
- }
- });
- const _p = bp;
- class Namespace extends Cu.g$ {
- constructor() {
- super(),
- this.register('annotation', Iu),
- this.register('comment', Pu),
- this.register('parseResult', Mu),
- this.register('sourceMap', Tu);
- }
- }
- const Ep = new Namespace(),
- createNamespace = (s) => {
- const o = new Namespace();
- return ku(s) && o.use(s), o;
- },
- wp = Ep,
- toolbox = () => ({ predicates: { ...le }, namespace: wp }),
- Sp = {
- toolboxCreator: toolbox,
- visitorOptions: { nodeTypeGetter: visitor_getNodeType, exposeEdits: !0 }
- },
- dispatchPluginsSync = (s, o, i = {}) => {
- if (0 === o.length) return s;
- const u = lp(Sp, i),
- { toolboxCreator: _, visitorOptions: w } = u,
- x = _(),
- C = o.map((s) => s(x)),
- j = mergeAll(C.map(La({}, 'visitor')), { ...w });
- C.forEach(_p(['pre'], []));
- const L = visitor_visit(s, j, w);
- return C.forEach(_p(['post'], [])), L;
- };
- dispatchPluginsSync[Symbol.for('nodejs.util.promisify.custom')] = async (s, o, i = {}) => {
- if (0 === o.length) return s;
- const u = lp(Sp, i),
- { toolboxCreator: _, visitorOptions: w } = u,
- x = _(),
- C = o.map((s) => s(x)),
- j = mergeAll[Symbol.for('nodejs.util.promisify.custom')],
- L = visitor_visit[Symbol.for('nodejs.util.promisify.custom')],
- B = j(C.map(La({}, 'visitor')), { ...w });
- await Promise.allSettled(C.map(_p(['pre'], [])));
- const $ = await L(s, B, w);
- return await Promise.allSettled(C.map(_p(['post'], []))), $;
- };
- const refract = (s, { Type: o, plugins: i = [] }) => {
- const u = new o(s);
- return (
- Nu(s) &&
- (s.meta.length > 0 && (u.meta = cloneDeep(s.meta)),
- s.attributes.length > 0 && (u.attributes = cloneDeep(s.attributes))),
- dispatchPluginsSync(u, i, {
- toolboxCreator: toolbox,
- visitorOptions: { nodeTypeGetter: visitor_getNodeType }
- })
- );
- },
- createRefractor =
- (s) =>
- (o, i = {}) =>
- refract(o, { ...i, Type: s });
- (Cu.Sh.refract = createRefractor(Cu.Sh)),
- (Cu.wE.refract = createRefractor(Cu.wE)),
- (Cu.Om.refract = createRefractor(Cu.Om)),
- (Cu.bd.refract = createRefractor(Cu.bd)),
- (Cu.Os.refract = createRefractor(Cu.Os)),
- (Cu.kT.refract = createRefractor(Cu.kT)),
- (Cu.Ft.refract = createRefractor(Cu.Ft)),
- (Cu.sI.refract = createRefractor(Cu.sI)),
- (Iu.refract = createRefractor(Iu)),
- (Pu.refract = createRefractor(Pu)),
- (Mu.refract = createRefractor(Mu)),
- (Tu.refract = createRefractor(Tu));
- const computeEdges = (s, o = new WeakMap()) => (
- $u(s)
- ? (o.set(s.key, s), computeEdges(s.key, o), o.set(s.value, s), computeEdges(s.value, o))
- : s.children.forEach((i) => {
- o.set(i, s), computeEdges(i, o);
- }),
- o
- );
- const xp = class Transcluder_Transcluder {
- element;
- edges;
- constructor({ element: s }) {
- this.element = s;
- }
- transclude(s, o) {
- var i;
- if (s === this.element) return o;
- if (s === o) return this.element;
- this.edges =
- null !== (i = this.edges) && void 0 !== i ? i : computeEdges(this.element);
- const u = this.edges.get(s);
- return Rl(u)
- ? void 0
- : (Fu(u)
- ? ((s, o, i) => {
- const u = i.get(s);
- Fu(u) &&
- (u.content = u.map((_, w, x) =>
- x === s ? (i.delete(s), i.set(o, u), o) : x
- ));
- })(s, o, this.edges)
- : qu(u)
- ? ((s, o, i) => {
- const u = i.get(s);
- qu(u) &&
- (u.content = u.map((_) =>
- _ === s ? (i.delete(s), i.set(o, u), o) : _
- ));
- })(s, o, this.edges)
- : $u(u) &&
- ((s, o, i) => {
- const u = i.get(s);
- $u(u) &&
- (u.key === s && ((u.key = o), i.delete(s), i.set(o, u)),
- u.value === s && ((u.value = o), i.delete(s), i.set(o, u)));
- })(s, o, this.edges),
- this.element);
- }
- },
- kp = pipe(Hl(/~/g, '~0'), Hl(/\//g, '~1'), encodeURIComponent);
- const Cp = class JsonPointerError extends Jo {};
- const Op = class CompilationJsonPointerError extends Cp {
- tokens;
- constructor(s, o) {
- super(s, o), void 0 !== o && (this.tokens = [...o.tokens]);
- }
- },
- es_compile = (s) => {
- try {
- return 0 === s.length ? '' : `/${s.map(kp).join('/')}`;
- } catch (o) {
- throw new Op('JSON Pointer compilation of tokens encountered an error.', {
- tokens: s,
- cause: o
- });
- }
- };
- var Ap = _curry2(function converge(s, o) {
- return za(Ca(Ll, 0, Fl('length', o)), function () {
- var i = arguments,
- u = this;
- return s.apply(
- u,
- _map(function (s) {
- return s.apply(u, i);
- }, o)
- );
- });
- });
- const jp = Ap;
- function _identity(s) {
- return s;
- }
- const Ip = _curry1(_identity);
- var Pp = gu(za(1, pipe(ea, Vl('Number'))), isFinite);
- var Mp = za(1, Pp);
- var Tp = gu(
- Wl(Number.isFinite) ? za(1, Ea(Number.isFinite, Number)) : Mp,
- jp(ra, [Math.floor, Ip])
- );
- var Np = za(1, Tp);
- const Rp = Wl(Number.isInteger) ? za(1, Ea(Number.isInteger, Number)) : Np;
- var Dp = (function () {
- function XTake(s, o) {
- (this.xf = o), (this.n = s), (this.i = 0);
- }
- return (
- (XTake.prototype['@@transducer/init'] = _xfBase_init),
- (XTake.prototype['@@transducer/result'] = _xfBase_result),
- (XTake.prototype['@@transducer/step'] = function (s, o) {
- this.i += 1;
- var i = 0 === this.n ? s : this.xf['@@transducer/step'](s, o);
- return this.n >= 0 && this.i >= this.n ? _reduced(i) : i;
- }),
- XTake
- );
- })();
- function _xtake(s) {
- return function (o) {
- return new Dp(s, o);
- };
- }
- const Lp = _curry2(
- _dispatchable(['take'], _xtake, function take(s, o) {
- return ja(0, s < 0 ? 1 / 0 : s, o);
- })
- );
- var Bp = _curry2(function (s, o) {
- return ra(Lp(s.length, o), s);
- });
- const Fp = Bp;
- const qp = ra('');
- var $p = (function () {
- function XDropWhile(s, o) {
- (this.xf = o), (this.f = s);
- }
- return (
- (XDropWhile.prototype['@@transducer/init'] = _xfBase_init),
- (XDropWhile.prototype['@@transducer/result'] = _xfBase_result),
- (XDropWhile.prototype['@@transducer/step'] = function (s, o) {
- if (this.f) {
- if (this.f(o)) return s;
- this.f = null;
- }
- return this.xf['@@transducer/step'](s, o);
- }),
- XDropWhile
- );
- })();
- function _xdropWhile(s) {
- return function (o) {
- return new $p(s, o);
- };
- }
- const Vp = _curry2(
- _dispatchable(['dropWhile'], _xdropWhile, function dropWhile(s, o) {
- for (var i = 0, u = o.length; i < u && s(o[i]); ) i += 1;
- return ja(i, 1 / 0, o);
- })
- );
- const Up = Ja(function (s, o) {
- return pipe(tl(''), Vp(_l(s)), yl(''))(o);
- }),
- zp = pipe(Hl(/~1/g, '/'), Hl(/~0/g, '~'), (s) => {
- try {
- return decodeURIComponent(s);
- } catch {
- return s;
- }
- });
- const Wp = class InvalidJsonPointerError extends Cp {
- pointer;
- constructor(s, o) {
- super(s, o), void 0 !== o && (this.pointer = o.pointer);
- }
- },
- uriToPointer = (s) => {
- const o = ((s) => {
- const o = s.indexOf('#');
- return -1 !== o ? s.substring(o) : '#';
- })(s);
- return Up('#', o);
- },
- es_parse = (s) => {
- if (qp(s)) return [];
- if (!Fp('/', s))
- throw new Wp(`Invalid JSON Pointer "${s}". JSON Pointers must begin with "/"`, {
- pointer: s
- });
- try {
- const o = pipe(tl('/'), kl(zp))(s);
- return Ia(o);
- } catch (o) {
- throw new Wp(`JSON Pointer parsing of "${s}" encountered an error.`, {
- pointer: s,
- cause: o
- });
- }
- };
- const Kp = class EvaluationJsonPointerError extends Cp {
- pointer;
- tokens;
- failedToken;
- failedTokenPosition;
- element;
- constructor(s, o) {
- super(s, o),
- void 0 !== o &&
- ((this.pointer = o.pointer),
- Array.isArray(o.tokens) && (this.tokens = [...o.tokens]),
- (this.failedToken = o.failedToken),
- (this.failedTokenPosition = o.failedTokenPosition),
- (this.element = o.element));
- }
- },
- es_evaluate = (s, o) => {
- let i;
- try {
- i = es_parse(s);
- } catch (i) {
- throw new Kp(`JSON Pointer evaluation failed while parsing the pointer "${s}".`, {
- pointer: s,
- element: cloneDeep(o),
- cause: i
- });
- }
- return i.reduce((o, u, _) => {
- if (Fu(o)) {
- if (!o.hasKey(u))
- throw new Kp(
- `JSON Pointer evaluation failed while evaluating token "${u}" against an ObjectElement`,
- {
- pointer: s,
- tokens: i,
- failedToken: u,
- failedTokenPosition: _,
- element: cloneDeep(o)
- }
- );
- return o.get(u);
- }
- if (qu(o)) {
- if (!(u in o.content) || !Rp(Number(u)))
- throw new Kp(
- `JSON Pointer evaluation failed while evaluating token "${u}" against an ArrayElement`,
- {
- pointer: s,
- tokens: i,
- failedToken: u,
- failedTokenPosition: _,
- element: cloneDeep(o)
- }
- );
- return o.get(Number(u));
- }
- throw new Kp(
- `JSON Pointer evaluation failed while evaluating token "${u}" against an unexpected Element`,
- {
- pointer: s,
- tokens: i,
- failedToken: u,
- failedTokenPosition: _,
- element: cloneDeep(o)
- }
- );
- }, o);
- };
- class Callback extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'callback');
- }
- }
- const Hp = Callback;
- class Components extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'components');
- }
- get schemas() {
- return this.get('schemas');
- }
- set schemas(s) {
- this.set('schemas', s);
- }
- get responses() {
- return this.get('responses');
- }
- set responses(s) {
- this.set('responses', s);
- }
- get parameters() {
- return this.get('parameters');
- }
- set parameters(s) {
- this.set('parameters', s);
- }
- get examples() {
- return this.get('examples');
- }
- set examples(s) {
- this.set('examples', s);
- }
- get requestBodies() {
- return this.get('requestBodies');
- }
- set requestBodies(s) {
- this.set('requestBodies', s);
- }
- get headers() {
- return this.get('headers');
- }
- set headers(s) {
- this.set('headers', s);
- }
- get securitySchemes() {
- return this.get('securitySchemes');
- }
- set securitySchemes(s) {
- this.set('securitySchemes', s);
- }
- get links() {
- return this.get('links');
- }
- set links(s) {
- this.set('links', s);
- }
- get callbacks() {
- return this.get('callbacks');
- }
- set callbacks(s) {
- this.set('callbacks', s);
- }
- }
- const Jp = Components;
- class Contact extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'contact');
- }
- get name() {
- return this.get('name');
- }
- set name(s) {
- this.set('name', s);
- }
- get url() {
- return this.get('url');
- }
- set url(s) {
- this.set('url', s);
- }
- get email() {
- return this.get('email');
- }
- set email(s) {
- this.set('email', s);
- }
- }
- const Gp = Contact;
- class Discriminator extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'discriminator');
- }
- get propertyName() {
- return this.get('propertyName');
- }
- set propertyName(s) {
- this.set('propertyName', s);
- }
- get mapping() {
- return this.get('mapping');
- }
- set mapping(s) {
- this.set('mapping', s);
- }
- }
- const Yp = Discriminator;
- class Encoding extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'encoding');
- }
- get contentType() {
- return this.get('contentType');
- }
- set contentType(s) {
- this.set('contentType', s);
- }
- get headers() {
- return this.get('headers');
- }
- set headers(s) {
- this.set('headers', s);
- }
- get style() {
- return this.get('style');
- }
- set style(s) {
- this.set('style', s);
- }
- get explode() {
- return this.get('explode');
- }
- set explode(s) {
- this.set('explode', s);
- }
- get allowedReserved() {
- return this.get('allowedReserved');
- }
- set allowedReserved(s) {
- this.set('allowedReserved', s);
- }
- }
- const Xp = Encoding;
- class Example extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'example');
- }
- get summary() {
- return this.get('summary');
- }
- set summary(s) {
- this.set('summary', s);
- }
- get description() {
- return this.get('description');
- }
- set description(s) {
- this.set('description', s);
- }
- get value() {
- return this.get('value');
- }
- set value(s) {
- this.set('value', s);
- }
- get externalValue() {
- return this.get('externalValue');
- }
- set externalValue(s) {
- this.set('externalValue', s);
- }
- }
- const Zp = Example;
- class ExternalDocumentation extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'externalDocumentation');
- }
- get description() {
- return this.get('description');
- }
- set description(s) {
- this.set('description', s);
- }
- get url() {
- return this.get('url');
- }
- set url(s) {
- this.set('url', s);
- }
- }
- const Qp = ExternalDocumentation;
- class Header extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'header');
- }
- get required() {
- return this.hasKey('required') ? this.get('required') : new Cu.bd(!1);
- }
- set required(s) {
- this.set('required', s);
- }
- get deprecated() {
- return this.hasKey('deprecated') ? this.get('deprecated') : new Cu.bd(!1);
- }
- set deprecated(s) {
- this.set('deprecated', s);
- }
- get allowEmptyValue() {
- return this.get('allowEmptyValue');
- }
- set allowEmptyValue(s) {
- this.set('allowEmptyValue', s);
- }
- get style() {
- return this.get('style');
- }
- set style(s) {
- this.set('style', s);
- }
- get explode() {
- return this.get('explode');
- }
- set explode(s) {
- this.set('explode', s);
- }
- get allowReserved() {
- return this.get('allowReserved');
- }
- set allowReserved(s) {
- this.set('allowReserved', s);
- }
- get schema() {
- return this.get('schema');
- }
- set schema(s) {
- this.set('schema', s);
- }
- get example() {
- return this.get('example');
- }
- set example(s) {
- this.set('example', s);
- }
- get examples() {
- return this.get('examples');
- }
- set examples(s) {
- this.set('examples', s);
- }
- get contentProp() {
- return this.get('content');
- }
- set contentProp(s) {
- this.set('content', s);
- }
- }
- Object.defineProperty(Header.prototype, 'description', {
- get() {
- return this.get('description');
- },
- set(s) {
- this.set('description', s);
- },
- enumerable: !0
- });
- const th = Header;
- class Info extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'info'), this.classes.push('info');
- }
- get title() {
- return this.get('title');
- }
- set title(s) {
- this.set('title', s);
- }
- get description() {
- return this.get('description');
- }
- set description(s) {
- this.set('description', s);
- }
- get termsOfService() {
- return this.get('termsOfService');
- }
- set termsOfService(s) {
- this.set('termsOfService', s);
- }
- get contact() {
- return this.get('contact');
- }
- set contact(s) {
- this.set('contact', s);
- }
- get license() {
- return this.get('license');
- }
- set license(s) {
- this.set('license', s);
- }
- get version() {
- return this.get('version');
- }
- set version(s) {
- this.set('version', s);
- }
- }
- const rh = Info;
- class License extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'license');
- }
- get name() {
- return this.get('name');
- }
- set name(s) {
- this.set('name', s);
- }
- get url() {
- return this.get('url');
- }
- set url(s) {
- this.set('url', s);
- }
- }
- const uh = License;
- class Link extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'link');
- }
- get operationRef() {
- return this.get('operationRef');
- }
- set operationRef(s) {
- this.set('operationRef', s);
- }
- get operationId() {
- return this.get('operationId');
- }
- set operationId(s) {
- this.set('operationId', s);
- }
- get operation() {
- var s, o;
- return Ru(this.operationRef)
- ? null === (s = this.operationRef) || void 0 === s
- ? void 0
- : s.meta.get('operation')
- : Ru(this.operationId)
- ? null === (o = this.operationId) || void 0 === o
- ? void 0
- : o.meta.get('operation')
- : void 0;
- }
- set operation(s) {
- this.set('operation', s);
- }
- get parameters() {
- return this.get('parameters');
- }
- set parameters(s) {
- this.set('parameters', s);
- }
- get requestBody() {
- return this.get('requestBody');
- }
- set requestBody(s) {
- this.set('requestBody', s);
- }
- get description() {
- return this.get('description');
- }
- set description(s) {
- this.set('description', s);
- }
- get server() {
- return this.get('server');
- }
- set server(s) {
- this.set('server', s);
- }
- }
- const dh = Link;
- class MediaType extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'mediaType');
- }
- get schema() {
- return this.get('schema');
- }
- set schema(s) {
- this.set('schema', s);
- }
- get example() {
- return this.get('example');
- }
- set example(s) {
- this.set('example', s);
- }
- get examples() {
- return this.get('examples');
- }
- set examples(s) {
- this.set('examples', s);
- }
- get encoding() {
- return this.get('encoding');
- }
- set encoding(s) {
- this.set('encoding', s);
- }
- }
- const fh = MediaType;
- class OAuthFlow extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'oAuthFlow');
- }
- get authorizationUrl() {
- return this.get('authorizationUrl');
- }
- set authorizationUrl(s) {
- this.set('authorizationUrl', s);
- }
- get tokenUrl() {
- return this.get('tokenUrl');
- }
- set tokenUrl(s) {
- this.set('tokenUrl', s);
- }
- get refreshUrl() {
- return this.get('refreshUrl');
- }
- set refreshUrl(s) {
- this.set('refreshUrl', s);
- }
- get scopes() {
- return this.get('scopes');
- }
- set scopes(s) {
- this.set('scopes', s);
- }
- }
- const vh = OAuthFlow;
- class OAuthFlows extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'oAuthFlows');
- }
- get implicit() {
- return this.get('implicit');
- }
- set implicit(s) {
- this.set('implicit', s);
- }
- get password() {
- return this.get('password');
- }
- set password(s) {
- this.set('password', s);
- }
- get clientCredentials() {
- return this.get('clientCredentials');
- }
- set clientCredentials(s) {
- this.set('clientCredentials', s);
- }
- get authorizationCode() {
- return this.get('authorizationCode');
- }
- set authorizationCode(s) {
- this.set('authorizationCode', s);
- }
- }
- const _h = OAuthFlows;
- class Openapi extends Cu.Om {
- constructor(s, o, i) {
- super(s, o, i),
- (this.element = 'openapi'),
- this.classes.push('spec-version'),
- this.classes.push('version');
- }
- }
- const wh = Openapi;
- class OpenApi3_0 extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'openApi3_0'), this.classes.push('api');
- }
- get openapi() {
- return this.get('openapi');
- }
- set openapi(s) {
- this.set('openapi', s);
- }
- get info() {
- return this.get('info');
- }
- set info(s) {
- this.set('info', s);
- }
- get servers() {
- return this.get('servers');
- }
- set servers(s) {
- this.set('servers', s);
- }
- get paths() {
- return this.get('paths');
- }
- set paths(s) {
- this.set('paths', s);
- }
- get components() {
- return this.get('components');
- }
- set components(s) {
- this.set('components', s);
- }
- get security() {
- return this.get('security');
- }
- set security(s) {
- this.set('security', s);
- }
- get tags() {
- return this.get('tags');
- }
- set tags(s) {
- this.set('tags', s);
- }
- get externalDocs() {
- return this.get('externalDocs');
- }
- set externalDocs(s) {
- this.set('externalDocs', s);
- }
- }
- const Oh = OpenApi3_0;
- class Operation extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'operation');
- }
- get tags() {
- return this.get('tags');
- }
- set tags(s) {
- this.set('tags', s);
- }
- get summary() {
- return this.get('summary');
- }
- set summary(s) {
- this.set('summary', s);
- }
- get description() {
- return this.get('description');
- }
- set description(s) {
- this.set('description', s);
- }
- set externalDocs(s) {
- this.set('externalDocs', s);
- }
- get externalDocs() {
- return this.get('externalDocs');
- }
- get operationId() {
- return this.get('operationId');
- }
- set operationId(s) {
- this.set('operationId', s);
- }
- get parameters() {
- return this.get('parameters');
- }
- set parameters(s) {
- this.set('parameters', s);
- }
- get requestBody() {
- return this.get('requestBody');
- }
- set requestBody(s) {
- this.set('requestBody', s);
- }
- get responses() {
- return this.get('responses');
- }
- set responses(s) {
- this.set('responses', s);
- }
- get callbacks() {
- return this.get('callbacks');
- }
- set callbacks(s) {
- this.set('callbacks', s);
- }
- get deprecated() {
- return this.hasKey('deprecated') ? this.get('deprecated') : new Cu.bd(!1);
- }
- set deprecated(s) {
- this.set('deprecated', s);
- }
- get security() {
- return this.get('security');
- }
- set security(s) {
- this.set('security', s);
- }
- get servers() {
- return this.get('severs');
- }
- set servers(s) {
- this.set('servers', s);
- }
- }
- const jh = Operation;
- class Parameter extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'parameter');
- }
- get name() {
- return this.get('name');
- }
- set name(s) {
- this.set('name', s);
- }
- get in() {
- return this.get('in');
- }
- set in(s) {
- this.set('in', s);
- }
- get required() {
- return this.hasKey('required') ? this.get('required') : new Cu.bd(!1);
- }
- set required(s) {
- this.set('required', s);
- }
- get deprecated() {
- return this.hasKey('deprecated') ? this.get('deprecated') : new Cu.bd(!1);
- }
- set deprecated(s) {
- this.set('deprecated', s);
- }
- get allowEmptyValue() {
- return this.get('allowEmptyValue');
- }
- set allowEmptyValue(s) {
- this.set('allowEmptyValue', s);
- }
- get style() {
- return this.get('style');
- }
- set style(s) {
- this.set('style', s);
- }
- get explode() {
- return this.get('explode');
- }
- set explode(s) {
- this.set('explode', s);
- }
- get allowReserved() {
- return this.get('allowReserved');
- }
- set allowReserved(s) {
- this.set('allowReserved', s);
- }
- get schema() {
- return this.get('schema');
- }
- set schema(s) {
- this.set('schema', s);
- }
- get example() {
- return this.get('example');
- }
- set example(s) {
- this.set('example', s);
- }
- get examples() {
- return this.get('examples');
- }
- set examples(s) {
- this.set('examples', s);
- }
- get contentProp() {
- return this.get('content');
- }
- set contentProp(s) {
- this.set('content', s);
- }
- }
- Object.defineProperty(Parameter.prototype, 'description', {
- get() {
- return this.get('description');
- },
- set(s) {
- this.set('description', s);
- },
- enumerable: !0
- });
- const Ih = Parameter;
- class PathItem extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'pathItem');
- }
- get $ref() {
- return this.get('$ref');
- }
- set $ref(s) {
- this.set('$ref', s);
- }
- get summary() {
- return this.get('summary');
- }
- set summary(s) {
- this.set('summary', s);
- }
- get description() {
- return this.get('description');
- }
- set description(s) {
- this.set('description', s);
- }
- get GET() {
- return this.get('get');
- }
- set GET(s) {
- this.set('GET', s);
- }
- get PUT() {
- return this.get('put');
- }
- set PUT(s) {
- this.set('PUT', s);
- }
- get POST() {
- return this.get('post');
- }
- set POST(s) {
- this.set('POST', s);
- }
- get DELETE() {
- return this.get('delete');
- }
- set DELETE(s) {
- this.set('DELETE', s);
- }
- get OPTIONS() {
- return this.get('options');
- }
- set OPTIONS(s) {
- this.set('OPTIONS', s);
- }
- get HEAD() {
- return this.get('head');
- }
- set HEAD(s) {
- this.set('HEAD', s);
- }
- get PATCH() {
- return this.get('patch');
- }
- set PATCH(s) {
- this.set('PATCH', s);
- }
- get TRACE() {
- return this.get('trace');
- }
- set TRACE(s) {
- this.set('TRACE', s);
- }
- get servers() {
- return this.get('servers');
- }
- set servers(s) {
- this.set('servers', s);
- }
- get parameters() {
- return this.get('parameters');
- }
- set parameters(s) {
- this.set('parameters', s);
- }
- }
- const Ph = PathItem;
- class Paths extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'paths');
- }
- }
- const Rh = Paths;
- class Reference extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'reference'), this.classes.push('openapi-reference');
- }
- get $ref() {
- return this.get('$ref');
- }
- set $ref(s) {
- this.set('$ref', s);
- }
- }
- const Dh = Reference;
- class RequestBody extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'requestBody');
- }
- get description() {
- return this.get('description');
- }
- set description(s) {
- this.set('description', s);
- }
- get contentProp() {
- return this.get('content');
- }
- set contentProp(s) {
- this.set('content', s);
- }
- get required() {
- return this.hasKey('required') ? this.get('required') : new Cu.bd(!1);
- }
- set required(s) {
- this.set('required', s);
- }
- }
- const Lh = RequestBody;
- class Response_Response extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'response');
- }
- get description() {
- return this.get('description');
- }
- set description(s) {
- this.set('description', s);
- }
- get headers() {
- return this.get('headers');
- }
- set headers(s) {
- this.set('headers', s);
- }
- get contentProp() {
- return this.get('content');
- }
- set contentProp(s) {
- this.set('content', s);
- }
- get links() {
- return this.get('links');
- }
- set links(s) {
- this.set('links', s);
- }
- }
- const Fh = Response_Response;
- class Responses extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'responses');
- }
- get default() {
- return this.get('default');
- }
- set default(s) {
- this.set('default', s);
- }
- }
- const Kh = Responses;
- const Hh = class UnsupportedOperationError extends Ho {};
- class JSONSchema extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'JSONSchemaDraft4');
- }
- get idProp() {
- return this.get('id');
- }
- set idProp(s) {
- this.set('id', s);
- }
- get $schema() {
- return this.get('$schema');
- }
- set $schema(s) {
- this.set('$schema', s);
- }
- get multipleOf() {
- return this.get('multipleOf');
- }
- set multipleOf(s) {
- this.set('multipleOf', s);
- }
- get maximum() {
- return this.get('maximum');
- }
- set maximum(s) {
- this.set('maximum', s);
- }
- get exclusiveMaximum() {
- return this.get('exclusiveMaximum');
- }
- set exclusiveMaximum(s) {
- this.set('exclusiveMaximum', s);
- }
- get minimum() {
- return this.get('minimum');
- }
- set minimum(s) {
- this.set('minimum', s);
- }
- get exclusiveMinimum() {
- return this.get('exclusiveMinimum');
- }
- set exclusiveMinimum(s) {
- this.set('exclusiveMinimum', s);
- }
- get maxLength() {
- return this.get('maxLength');
- }
- set maxLength(s) {
- this.set('maxLength', s);
- }
- get minLength() {
- return this.get('minLength');
- }
- set minLength(s) {
- this.set('minLength', s);
- }
- get pattern() {
- return this.get('pattern');
- }
- set pattern(s) {
- this.set('pattern', s);
- }
- get additionalItems() {
- return this.get('additionalItems');
- }
- set additionalItems(s) {
- this.set('additionalItems', s);
- }
- get items() {
- return this.get('items');
- }
- set items(s) {
- this.set('items', s);
- }
- get maxItems() {
- return this.get('maxItems');
- }
- set maxItems(s) {
- this.set('maxItems', s);
- }
- get minItems() {
- return this.get('minItems');
- }
- set minItems(s) {
- this.set('minItems', s);
- }
- get uniqueItems() {
- return this.get('uniqueItems');
- }
- set uniqueItems(s) {
- this.set('uniqueItems', s);
- }
- get maxProperties() {
- return this.get('maxProperties');
- }
- set maxProperties(s) {
- this.set('maxProperties', s);
- }
- get minProperties() {
- return this.get('minProperties');
- }
- set minProperties(s) {
- this.set('minProperties', s);
- }
- get required() {
- return this.get('required');
- }
- set required(s) {
- this.set('required', s);
- }
- get properties() {
- return this.get('properties');
- }
- set properties(s) {
- this.set('properties', s);
- }
- get additionalProperties() {
- return this.get('additionalProperties');
- }
- set additionalProperties(s) {
- this.set('additionalProperties', s);
- }
- get patternProperties() {
- return this.get('patternProperties');
- }
- set patternProperties(s) {
- this.set('patternProperties', s);
- }
- get dependencies() {
- return this.get('dependencies');
- }
- set dependencies(s) {
- this.set('dependencies', s);
- }
- get enum() {
- return this.get('enum');
- }
- set enum(s) {
- this.set('enum', s);
- }
- get type() {
- return this.get('type');
- }
- set type(s) {
- this.set('type', s);
- }
- get allOf() {
- return this.get('allOf');
- }
- set allOf(s) {
- this.set('allOf', s);
- }
- get anyOf() {
- return this.get('anyOf');
- }
- set anyOf(s) {
- this.set('anyOf', s);
- }
- get oneOf() {
- return this.get('oneOf');
- }
- set oneOf(s) {
- this.set('oneOf', s);
- }
- get not() {
- return this.get('not');
- }
- set not(s) {
- this.set('not', s);
- }
- get definitions() {
- return this.get('definitions');
- }
- set definitions(s) {
- this.set('definitions', s);
- }
- get title() {
- return this.get('title');
- }
- set title(s) {
- this.set('title', s);
- }
- get description() {
- return this.get('description');
- }
- set description(s) {
- this.set('description', s);
- }
- get default() {
- return this.get('default');
- }
- set default(s) {
- this.set('default', s);
- }
- get format() {
- return this.get('format');
- }
- set format(s) {
- this.set('format', s);
- }
- get base() {
- return this.get('base');
- }
- set base(s) {
- this.set('base', s);
- }
- get links() {
- return this.get('links');
- }
- set links(s) {
- this.set('links', s);
- }
- get media() {
- return this.get('media');
- }
- set media(s) {
- this.set('media', s);
- }
- get readOnly() {
- return this.get('readOnly');
- }
- set readOnly(s) {
- this.set('readOnly', s);
- }
- }
- const Jh = JSONSchema;
- class JSONReference extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'JSONReference'), this.classes.push('json-reference');
- }
- get $ref() {
- return this.get('$ref');
- }
- set $ref(s) {
- this.set('$ref', s);
- }
- }
- const Gh = JSONReference;
- class Media extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'media');
- }
- get binaryEncoding() {
- return this.get('binaryEncoding');
- }
- set binaryEncoding(s) {
- this.set('binaryEncoding', s);
- }
- get type() {
- return this.get('type');
- }
- set type(s) {
- this.set('type', s);
- }
- }
- const Qh = Media;
- class LinkDescription extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'linkDescription');
- }
- get href() {
- return this.get('href');
- }
- set href(s) {
- this.set('href', s);
- }
- get rel() {
- return this.get('rel');
- }
- set rel(s) {
- this.set('rel', s);
- }
- get title() {
- return this.get('title');
- }
- set title(s) {
- this.set('title', s);
- }
- get targetSchema() {
- return this.get('targetSchema');
- }
- set targetSchema(s) {
- this.set('targetSchema', s);
- }
- get mediaType() {
- return this.get('mediaType');
- }
- set mediaType(s) {
- this.set('mediaType', s);
- }
- get method() {
- return this.get('method');
- }
- set method(s) {
- this.set('method', s);
- }
- get encType() {
- return this.get('encType');
- }
- set encType(s) {
- this.set('encType', s);
- }
- get schema() {
- return this.get('schema');
- }
- set schema(s) {
- this.set('schema', s);
- }
- }
- const td = LinkDescription;
- var sd = _curry2(function mapObjIndexed(s, o) {
- return _arrayReduce(
- function (i, u) {
- return (i[u] = s(o[u], u, o)), i;
- },
- {},
- Wi(o)
- );
- });
- const id = sd;
- const ld = _curry1(function isNil(s) {
- return null == s;
- });
- var cd = _curry2(function hasPath(s, o) {
- if (0 === s.length || ld(o)) return !1;
- for (var i = o, u = 0; u < s.length; ) {
- if (ld(i) || !_has(s[u], i)) return !1;
- (i = i[s[u]]), (u += 1);
- }
- return !0;
- });
- const ud = cd;
- var dd = _curry2(function has(s, o) {
- return ud([s], o);
- });
- const md = dd;
- const yd = _curry3(function propSatisfies(s, o, i) {
- return s(Da(o, i));
- }),
- dereference = (s, o) => {
- const i = Na(s, o);
- return id((s) => {
- if (ku(s) && md('$ref', s) && yd(Yl, '$ref', s)) {
- const o = cp(['$ref'], s),
- u = Up('#/', o);
- return cp(u.split('/'), i);
- }
- return ku(s) ? dereference(s, i) : s;
- }, s);
- },
- emptyElement = (s) => {
- const o = s.meta.length > 0 ? cloneDeep(s.meta) : void 0,
- i = s.attributes.length > 0 ? cloneDeep(s.attributes) : void 0;
- return new s.constructor(void 0, o, i);
- },
- cloneUnlessOtherwiseSpecified = (s, o) =>
- o.clone && o.isMergeableElement(s) ? deepmerge(emptyElement(s), s, o) : s,
- getMetaMergeFunction = (s) =>
- 'function' != typeof s.customMetaMerge ? (s) => cloneDeep(s) : s.customMetaMerge,
- getAttributesMergeFunction = (s) =>
- 'function' != typeof s.customAttributesMerge
- ? (s) => cloneDeep(s)
- : s.customAttributesMerge,
- vd = {
- clone: !0,
- isMergeableElement: (s) => Fu(s) || qu(s),
- arrayElementMerge: (s, o, i) =>
- s.concat(o)['fantasy-land/map']((s) => cloneUnlessOtherwiseSpecified(s, i)),
- objectElementMerge: (s, o, i) => {
- const u = Fu(s) ? emptyElement(s) : emptyElement(o);
- return (
- Fu(s) &&
- s.forEach((s, o, _) => {
- const w = cloneShallow(_);
- (w.value = cloneUnlessOtherwiseSpecified(s, i)), u.content.push(w);
- }),
- o.forEach((o, _, w) => {
- const x = serializers_value(_);
- let C;
- if (Fu(s) && s.hasKey(x) && i.isMergeableElement(o)) {
- const u = s.get(x);
- (C = cloneShallow(w)),
- (C.value = ((s, o) => {
- if ('function' != typeof o.customMerge) return deepmerge;
- const i = o.customMerge(s, o);
- return 'function' == typeof i ? i : deepmerge;
- })(_, i)(u, o));
- } else (C = cloneShallow(w)), (C.value = cloneUnlessOtherwiseSpecified(o, i));
- u.remove(x), u.content.push(C);
- }),
- u
- );
- },
- customMerge: void 0,
- customMetaMerge: void 0,
- customAttributesMerge: void 0
- };
- function deepmerge(s, o, i) {
- var u, _, w;
- const x = { ...vd, ...i };
- (x.isMergeableElement =
- null !== (u = x.isMergeableElement) && void 0 !== u ? u : vd.isMergeableElement),
- (x.arrayElementMerge =
- null !== (_ = x.arrayElementMerge) && void 0 !== _ ? _ : vd.arrayElementMerge),
- (x.objectElementMerge =
- null !== (w = x.objectElementMerge) && void 0 !== w ? w : vd.objectElementMerge);
- const C = qu(o);
- if (!(C === qu(s))) return cloneUnlessOtherwiseSpecified(o, x);
- const j =
- C && 'function' == typeof x.arrayElementMerge
- ? x.arrayElementMerge(s, o, x)
- : x.objectElementMerge(s, o, x);
- return (
- (j.meta = getMetaMergeFunction(x)(s.meta, o.meta)),
- (j.attributes = getAttributesMergeFunction(x)(s.attributes, o.attributes)),
- j
- );
- }
- deepmerge.all = (s, o) => {
- if (!Array.isArray(s))
- throw new TypeError('First argument of deepmerge should be an array.');
- return 0 === s.length
- ? new Cu.Sh()
- : s.reduce((s, i) => deepmerge(s, i, o), emptyElement(s[0]));
- };
- const _d = class Visitor_Visitor {
- element;
- constructor(s) {
- Object.assign(this, s);
- }
- copyMetaAndAttributes(s, o) {
- (s.meta.length > 0 || o.meta.length > 0) &&
- ((o.meta = deepmerge(o.meta, s.meta)),
- hasElementSourceMap(s) && o.meta.set('sourceMap', s.meta.get('sourceMap'))),
- (s.attributes.length > 0 || s.meta.length > 0) &&
- (o.attributes = deepmerge(o.attributes, s.attributes));
- }
- };
- const Ed = class FallbackVisitor extends _d {
- enter(s) {
- return (this.element = cloneDeep(s)), Ju;
- }
- },
- copyProps = (s, o, i = []) => {
- const u = Object.getOwnPropertyDescriptors(o);
- for (let s of i) delete u[s];
- Object.defineProperties(s, u);
- },
- protoChain = (s, o = [s]) => {
- const i = Object.getPrototypeOf(s);
- return null === i ? o : protoChain(i, [...o, i]);
- },
- hardMixProtos = (s, o, i = []) => {
- var u;
- const _ =
- null !==
- (u = ((...s) => {
- if (0 === s.length) return;
- let o;
- const i = s.map((s) => protoChain(s));
- for (; i.every((s) => s.length > 0); ) {
- const s = i.map((s) => s.pop()),
- u = s[0];
- if (!s.every((s) => s === u)) break;
- o = u;
- }
- return o;
- })(...s)) && void 0 !== u
- ? u
- : Object.prototype,
- w = Object.create(_),
- x = protoChain(_);
- for (let o of s) {
- let s = protoChain(o);
- for (let o = s.length - 1; o >= 0; o--) {
- let u = s[o];
- -1 === x.indexOf(u) && (copyProps(w, u, ['constructor', ...i]), x.push(u));
- }
- }
- return (w.constructor = o), w;
- },
- unique = (s) => s.filter((o, i) => s.indexOf(o) == i),
- getIngredientWithProp = (s, o) => {
- const i = o.map((s) => protoChain(s));
- let u = 0,
- _ = !0;
- for (; _; ) {
- _ = !1;
- for (let w = o.length - 1; w >= 0; w--) {
- const o = i[w][u];
- if (null != o && ((_ = !0), null != Object.getOwnPropertyDescriptor(o, s)))
- return i[w][0];
- }
- u++;
- }
- },
- proxyMix = (s, o = Object.prototype) =>
- new Proxy(
- {},
- {
- getPrototypeOf: () => o,
- setPrototypeOf() {
- throw Error('Cannot set prototype of Proxies created by ts-mixer');
- },
- getOwnPropertyDescriptor: (o, i) =>
- Object.getOwnPropertyDescriptor(getIngredientWithProp(i, s) || {}, i),
- defineProperty() {
- throw new Error('Cannot define new properties on Proxies created by ts-mixer');
- },
- has: (i, u) => void 0 !== getIngredientWithProp(u, s) || void 0 !== o[u],
- get: (i, u) => (getIngredientWithProp(u, s) || o)[u],
- set(o, i, u) {
- const _ = getIngredientWithProp(i, s);
- if (void 0 === _)
- throw new Error('Cannot set new properties on Proxies created by ts-mixer');
- return (_[i] = u), !0;
- },
- deleteProperty() {
- throw new Error('Cannot delete properties on Proxies created by ts-mixer');
- },
- ownKeys: () =>
- s
- .map(Object.getOwnPropertyNames)
- .reduce((s, o) => o.concat(s.filter((s) => o.indexOf(s) < 0)))
- }
- ),
- wd = null,
- Sd = 'copy',
- xd = 'copy',
- kd = 'deep',
- Cd = new WeakMap(),
- getMixinsForClass = (s) => Cd.get(s),
- mergeObjectsOfDecorators = (s, o) => {
- var i, u;
- const _ = unique([...Object.getOwnPropertyNames(s), ...Object.getOwnPropertyNames(o)]),
- w = {};
- for (let x of _)
- w[x] = unique([
- ...(null !== (i = null == s ? void 0 : s[x]) && void 0 !== i ? i : []),
- ...(null !== (u = null == o ? void 0 : o[x]) && void 0 !== u ? u : [])
- ]);
- return w;
- },
- mergePropertyAndMethodDecorators = (s, o) => {
- var i, u, _, w;
- return {
- property: mergeObjectsOfDecorators(
- null !== (i = null == s ? void 0 : s.property) && void 0 !== i ? i : {},
- null !== (u = null == o ? void 0 : o.property) && void 0 !== u ? u : {}
- ),
- method: mergeObjectsOfDecorators(
- null !== (_ = null == s ? void 0 : s.method) && void 0 !== _ ? _ : {},
- null !== (w = null == o ? void 0 : o.method) && void 0 !== w ? w : {}
- )
- };
- },
- mergeDecorators = (s, o) => {
- var i, u, _, w, x, C;
- return {
- class: unique([
- ...(null !== (i = null == s ? void 0 : s.class) && void 0 !== i ? i : []),
- ...(null !== (u = null == o ? void 0 : o.class) && void 0 !== u ? u : [])
- ]),
- static: mergePropertyAndMethodDecorators(
- null !== (_ = null == s ? void 0 : s.static) && void 0 !== _ ? _ : {},
- null !== (w = null == o ? void 0 : o.static) && void 0 !== w ? w : {}
- ),
- instance: mergePropertyAndMethodDecorators(
- null !== (x = null == s ? void 0 : s.instance) && void 0 !== x ? x : {},
- null !== (C = null == o ? void 0 : o.instance) && void 0 !== C ? C : {}
- )
- };
- },
- Od = new Map(),
- deepDecoratorSearch = (...s) => {
- const o = ((...s) => {
- var o;
- const i = new Set(),
- u = new Set([...s]);
- for (; u.size > 0; )
- for (let s of u) {
- const _ = protoChain(s.prototype).map((s) => s.constructor),
- w = [
- ..._,
- ...(null !== (o = getMixinsForClass(s)) && void 0 !== o ? o : [])
- ].filter((s) => !i.has(s));
- for (let s of w) u.add(s);
- i.add(s), u.delete(s);
- }
- return [...i];
- })(...s)
- .map((s) => Od.get(s))
- .filter((s) => !!s);
- return 0 == o.length
- ? {}
- : 1 == o.length
- ? o[0]
- : o.reduce((s, o) => mergeDecorators(s, o));
- },
- getDecoratorsForClass = (s) => {
- let o = Od.get(s);
- return o || ((o = {}), Od.set(s, o)), o;
- };
- function Mixin(...s) {
- var o, i, u;
- const _ = s.map((s) => s.prototype),
- w = wd;
- if (null !== w) {
- const s = _.map((s) => s[w]).filter((s) => 'function' == typeof s),
- combinedInitFunction = function (...o) {
- for (let i of s) i.apply(this, o);
- },
- o = { [w]: combinedInitFunction };
- _.push(o);
- }
- function MixedClass(...o) {
- for (const i of s) copyProps(this, new i(...o));
- null !== w && 'function' == typeof this[w] && this[w].apply(this, o);
- }
- var x, C;
- (MixedClass.prototype =
- 'copy' === xd
- ? hardMixProtos(_, MixedClass)
- : ((x = _), (C = MixedClass), proxyMix([...x, { constructor: C }]))),
- Object.setPrototypeOf(
- MixedClass,
- 'copy' === Sd
- ? hardMixProtos(s, null, ['prototype'])
- : proxyMix(s, Function.prototype)
- );
- let j = MixedClass;
- if ('none' !== kd) {
- const _ =
- 'deep' === kd
- ? deepDecoratorSearch(...s)
- : ((...s) => {
- const o = s.map((s) => getDecoratorsForClass(s));
- return 0 === o.length
- ? {}
- : 1 === o.length
- ? o[0]
- : o.reduce((s, o) => mergeDecorators(s, o));
- })(...s);
- for (let s of null !== (o = null == _ ? void 0 : _.class) && void 0 !== o ? o : []) {
- const o = s(j);
- o && (j = o);
- }
- applyPropAndMethodDecorators(
- null !== (i = null == _ ? void 0 : _.static) && void 0 !== i ? i : {},
- j
- ),
- applyPropAndMethodDecorators(
- null !== (u = null == _ ? void 0 : _.instance) && void 0 !== u ? u : {},
- j.prototype
- );
- }
- var L, B;
- return (L = j), (B = s), Cd.set(L, B), j;
- }
- const applyPropAndMethodDecorators = (s, o) => {
- const i = s.property,
- u = s.method;
- if (i) for (let s in i) for (let u of i[s]) u(o, s);
- if (u)
- for (let s in u) for (let i of u[s]) i(o, s, Object.getOwnPropertyDescriptor(o, s));
- };
- const Ad = _curry2(function pick(s, o) {
- for (var i = {}, u = 0; u < s.length; ) s[u] in o && (i[s[u]] = o[s[u]]), (u += 1);
- return i;
- });
- const Id = class SpecificationVisitor extends _d {
- specObj;
- passingOptionsNames = ['specObj'];
- constructor({ specObj: s, ...o }) {
- super({ ...o }), (this.specObj = s);
- }
- retrievePassingOptions() {
- return Ad(this.passingOptionsNames, this);
- }
- retrieveFixedFields(s) {
- const o = cp(['visitors', ...s, 'fixedFields'], this.specObj);
- return 'object' == typeof o && null !== o ? Object.keys(o) : [];
- }
- retrieveVisitor(s) {
- return Xo(Wl, ['visitors', ...s], this.specObj)
- ? cp(['visitors', ...s], this.specObj)
- : cp(['visitors', ...s, '$visitor'], this.specObj);
- }
- retrieveVisitorInstance(s, o = {}) {
- const i = this.retrievePassingOptions();
- return new (this.retrieveVisitor(s))({ ...i, ...o });
- }
- toRefractedElement(s, o, i = {}) {
- const u = this.retrieveVisitorInstance(s, i);
- return u instanceof Ed && (null == u ? void 0 : u.constructor) === Ed
- ? cloneDeep(o)
- : (visitor_visit(o, u, i), u.element);
- }
- };
- const Md = class FixedFieldsVisitor extends Id {
- specPath;
- ignoredFields;
- constructor({ specPath: s, ignoredFields: o, ...i }) {
- super({ ...i }), (this.specPath = s), (this.ignoredFields = o || []);
- }
- ObjectElement(s) {
- const o = this.specPath(s),
- i = this.retrieveFixedFields(o);
- return (
- s.forEach((s, u, _) => {
- if (
- Ru(u) &&
- i.includes(serializers_value(u)) &&
- !this.ignoredFields.includes(serializers_value(u))
- ) {
- const i = this.toRefractedElement([...o, 'fixedFields', serializers_value(u)], s),
- w = new Cu.Pr(cloneDeep(u), i);
- this.copyMetaAndAttributes(_, w),
- w.classes.push('fixed-field'),
- this.element.content.push(w);
- } else
- this.ignoredFields.includes(serializers_value(u)) ||
- this.element.content.push(cloneDeep(_));
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- };
- class JSONSchemaVisitor extends Mixin(Md, Ed) {
- constructor(s) {
- super(s),
- (this.element = new Jh()),
- (this.specPath = Tl(['document', 'objects', 'JSONSchema']));
- }
- }
- const Td = JSONSchemaVisitor;
- const Nd = class ParentSchemaAwareVisitor {
- parent;
- constructor({ parent: s }) {
- this.parent = s;
- }
- },
- isJSONReferenceLikeElement = (s) => Fu(s) && s.hasKey('$ref');
- class ItemsVisitor extends Mixin(Id, Nd, Ed) {
- ObjectElement(s) {
- const o = isJSONReferenceLikeElement(s)
- ? ['document', 'objects', 'JSONReference']
- : ['document', 'objects', 'JSONSchema'];
- return (this.element = this.toRefractedElement(o, s)), Ju;
- }
- ArrayElement(s) {
- return (
- (this.element = new Cu.wE()),
- this.element.classes.push('json-schema-items'),
- s.forEach((s) => {
- const o = isJSONReferenceLikeElement(s)
- ? ['document', 'objects', 'JSONReference']
- : ['document', 'objects', 'JSONSchema'],
- i = this.toRefractedElement(o, s);
- this.element.push(i);
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- }
- const Rd = ItemsVisitor;
- const Dd = class RequiredVisitor extends Ed {
- ArrayElement(s) {
- const o = this.enter(s);
- return this.element.classes.push('json-schema-required'), o;
- }
- };
- const Ld = _curry1(function allPass(s) {
- return za(Ca(Ll, 0, Fl('length', s)), function () {
- for (var o = 0, i = s.length; o < i; ) {
- if (!s[o].apply(this, arguments)) return !1;
- o += 1;
- }
- return !0;
- });
- });
- const Bd = _curry1(function isNotEmpty(s) {
- return !gp(s);
- });
- const Fd = _curry2(function or(s, o) {
- return s || o;
- });
- var $d = Ml(
- za(
- 1,
- gu(
- vu,
- _curry2(function either(s, o) {
- return _isFunction(s)
- ? function _either() {
- return s.apply(this, arguments) || o.apply(this, arguments);
- }
- : Pl(Fd)(s, o);
- })(bu, Wl)
- )
- )
- );
- const Vd = Ld([Yl, $d, Bd]);
- const Ud = class PatternedFieldsVisitor extends Id {
- specPath;
- ignoredFields;
- fieldPatternPredicate = es_F;
- constructor({ specPath: s, ignoredFields: o, fieldPatternPredicate: i, ...u }) {
- super({ ...u }),
- (this.specPath = s),
- (this.ignoredFields = o || []),
- 'function' == typeof i && (this.fieldPatternPredicate = i);
- }
- ObjectElement(s) {
- return (
- s.forEach((s, o, i) => {
- if (
- !this.ignoredFields.includes(serializers_value(o)) &&
- this.fieldPatternPredicate(serializers_value(o))
- ) {
- const u = this.specPath(s),
- _ = this.toRefractedElement(u, s),
- w = new Cu.Pr(cloneDeep(o), _);
- this.copyMetaAndAttributes(i, w),
- w.classes.push('patterned-field'),
- this.element.content.push(w);
- } else
- this.ignoredFields.includes(serializers_value(o)) ||
- this.element.content.push(cloneDeep(i));
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- };
- const Wd = class MapVisitor extends Ud {
- constructor(s) {
- super(s), (this.fieldPatternPredicate = Vd);
- }
- };
- class PropertiesVisitor extends Mixin(Wd, Nd, Ed) {
- constructor(s) {
- super(s),
- (this.element = new Cu.Sh()),
- this.element.classes.push('json-schema-properties'),
- (this.specPath = (s) =>
- isJSONReferenceLikeElement(s)
- ? ['document', 'objects', 'JSONReference']
- : ['document', 'objects', 'JSONSchema']);
- }
- }
- const Kd = PropertiesVisitor;
- class PatternPropertiesVisitor extends Mixin(Wd, Nd, Ed) {
- constructor(s) {
- super(s),
- (this.element = new Cu.Sh()),
- this.element.classes.push('json-schema-patternProperties'),
- (this.specPath = (s) =>
- isJSONReferenceLikeElement(s)
- ? ['document', 'objects', 'JSONReference']
- : ['document', 'objects', 'JSONSchema']);
- }
- }
- const Hd = PatternPropertiesVisitor;
- class DependenciesVisitor extends Mixin(Wd, Nd, Ed) {
- constructor(s) {
- super(s),
- (this.element = new Cu.Sh()),
- this.element.classes.push('json-schema-dependencies'),
- (this.specPath = (s) =>
- isJSONReferenceLikeElement(s)
- ? ['document', 'objects', 'JSONReference']
- : ['document', 'objects', 'JSONSchema']);
- }
- }
- const Jd = DependenciesVisitor;
- const Gd = class EnumVisitor extends Ed {
- ArrayElement(s) {
- const o = this.enter(s);
- return this.element.classes.push('json-schema-enum'), o;
- }
- };
- const Yd = class TypeVisitor extends Ed {
- StringElement(s) {
- const o = this.enter(s);
- return this.element.classes.push('json-schema-type'), o;
- }
- ArrayElement(s) {
- const o = this.enter(s);
- return this.element.classes.push('json-schema-type'), o;
- }
- };
- class AllOfVisitor extends Mixin(Id, Nd, Ed) {
- constructor(s) {
- super(s), (this.element = new Cu.wE()), this.element.classes.push('json-schema-allOf');
- }
- ArrayElement(s) {
- return (
- s.forEach((s) => {
- const o = isJSONReferenceLikeElement(s)
- ? ['document', 'objects', 'JSONReference']
- : ['document', 'objects', 'JSONSchema'],
- i = this.toRefractedElement(o, s);
- this.element.push(i);
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- }
- const Xd = AllOfVisitor;
- class AnyOfVisitor extends Mixin(Id, Nd, Ed) {
- constructor(s) {
- super(s), (this.element = new Cu.wE()), this.element.classes.push('json-schema-anyOf');
- }
- ArrayElement(s) {
- return (
- s.forEach((s) => {
- const o = isJSONReferenceLikeElement(s)
- ? ['document', 'objects', 'JSONReference']
- : ['document', 'objects', 'JSONSchema'],
- i = this.toRefractedElement(o, s);
- this.element.push(i);
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- }
- const Zd = AnyOfVisitor;
- class OneOfVisitor extends Mixin(Id, Nd, Ed) {
- constructor(s) {
- super(s), (this.element = new Cu.wE()), this.element.classes.push('json-schema-oneOf');
- }
- ArrayElement(s) {
- return (
- s.forEach((s) => {
- const o = isJSONReferenceLikeElement(s)
- ? ['document', 'objects', 'JSONReference']
- : ['document', 'objects', 'JSONSchema'],
- i = this.toRefractedElement(o, s);
- this.element.push(i);
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- }
- const Qd = OneOfVisitor;
- class DefinitionsVisitor extends Mixin(Wd, Nd, Ed) {
- constructor(s) {
- super(s),
- (this.element = new Cu.Sh()),
- this.element.classes.push('json-schema-definitions'),
- (this.specPath = (s) =>
- isJSONReferenceLikeElement(s)
- ? ['document', 'objects', 'JSONReference']
- : ['document', 'objects', 'JSONSchema']);
- }
- }
- const ef = DefinitionsVisitor;
- class LinksVisitor extends Mixin(Id, Nd, Ed) {
- constructor(s) {
- super(s), (this.element = new Cu.wE()), this.element.classes.push('json-schema-links');
- }
- ArrayElement(s) {
- return (
- s.forEach((s) => {
- const o = this.toRefractedElement(['document', 'objects', 'LinkDescription'], s);
- this.element.push(o);
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- }
- const rf = LinksVisitor;
- class JSONReferenceVisitor extends Mixin(Md, Ed) {
- constructor(s) {
- super(s),
- (this.element = new Gh()),
- (this.specPath = Tl(['document', 'objects', 'JSONReference']));
- }
- ObjectElement(s) {
- const o = Md.prototype.ObjectElement.call(this, s);
- return Ru(this.element.$ref) && this.element.classes.push('reference-element'), o;
- }
- }
- const of = JSONReferenceVisitor;
- const af = class $RefVisitor extends Ed {
- StringElement(s) {
- const o = this.enter(s);
- return this.element.classes.push('reference-value'), o;
- }
- };
- const lf = _curry3(function ifElse(s, o, i) {
- return za(Math.max(s.length, o.length, i.length), function _ifElse() {
- return s.apply(this, arguments) ? o.apply(this, arguments) : i.apply(this, arguments);
- });
- });
- const cf = _curry1(function comparator(s) {
- return function (o, i) {
- return s(o, i) ? -1 : s(i, o) ? 1 : 0;
- };
- });
- var uf = _curry2(function sort(s, o) {
- return Array.prototype.slice.call(o, 0).sort(s);
- });
- const hf = uf;
- var df = _curry1(function (s) {
- return _nth(0, s);
- });
- const mf = df;
- const gf = _curry1(_reduced);
- const yf = Ml(ld);
- const bf = gu(yp, Bd);
- function _toConsumableArray(s) {
- return (
- (function _arrayWithoutHoles(s) {
- if (Array.isArray(s)) return _arrayLikeToArray(s);
- })(s) ||
- (function _iterableToArray(s) {
- if (
- ('undefined' != typeof Symbol && null != s[Symbol.iterator]) ||
- null != s['@@iterator']
- )
- return Array.from(s);
- })(s) ||
- (function _unsupportedIterableToArray(s, o) {
- if (s) {
- if ('string' == typeof s) return _arrayLikeToArray(s, o);
- var i = {}.toString.call(s).slice(8, -1);
- return (
- 'Object' === i && s.constructor && (i = s.constructor.name),
- 'Map' === i || 'Set' === i
- ? Array.from(s)
- : 'Arguments' === i || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)
- ? _arrayLikeToArray(s, o)
- : void 0
- );
- }
- })(s) ||
- (function _nonIterableSpread() {
- throw new TypeError(
- 'Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.'
- );
- })()
- );
- }
- function _arrayLikeToArray(s, o) {
- (null == o || o > s.length) && (o = s.length);
- for (var i = 0, u = Array(o); i < o; i++) u[i] = s[i];
- return u;
- }
- var _f = pipe(
- hf(
- cf(function (s, o) {
- return s.length > o.length;
- })
- ),
- mf,
- Da('length')
- ),
- Sf = Ja(function (s, o, i) {
- var u = i.apply(void 0, _toConsumableArray(s));
- return yf(u) ? gf(u) : o;
- });
- const xf = lf(
- bf,
- function dispatchImpl(s) {
- var o = _f(s);
- return za(o, function () {
- for (var o = arguments.length, i = new Array(o), u = 0; u < o; u++)
- i[u] = arguments[u];
- return Ca(Sf(i), void 0, s);
- });
- },
- Nl
- );
- const kf = class AlternatingVisitor extends Id {
- alternator;
- constructor({ alternator: s, ...o }) {
- super({ ...o }), (this.alternator = s);
- }
- enter(s) {
- const o = this.alternator.map(({ predicate: s, specPath: o }) => lf(s, Tl(o), Nl)),
- i = xf(o)(s);
- return (this.element = this.toRefractedElement(i, s)), Ju;
- }
- };
- const Cf = class SchemaOrReferenceVisitor extends kf {
- constructor(s) {
- super(s),
- (this.alternator = [
- {
- predicate: isJSONReferenceLikeElement,
- specPath: ['document', 'objects', 'JSONReference']
- },
- { predicate: es_T, specPath: ['document', 'objects', 'JSONSchema'] }
- ]);
- }
- };
- class MediaVisitor extends Mixin(Md, Ed) {
- constructor(s) {
- super(s),
- (this.element = new Qh()),
- (this.specPath = Tl(['document', 'objects', 'Media']));
- }
- }
- const Of = MediaVisitor;
- class LinkDescriptionVisitor extends Mixin(Md, Ed) {
- constructor(s) {
- super(s),
- (this.element = new td()),
- (this.specPath = Tl(['document', 'objects', 'LinkDescription']));
- }
- }
- const jf = {
- visitors: {
- value: Ed,
- JSONSchemaOrJSONReferenceVisitor: Cf,
- document: {
- objects: {
- JSONSchema: {
- $visitor: Td,
- fixedFields: {
- id: { $ref: '#/visitors/value' },
- $schema: { $ref: '#/visitors/value' },
- multipleOf: { $ref: '#/visitors/value' },
- maximum: { $ref: '#/visitors/value' },
- exclusiveMaximum: { $ref: '#/visitors/value' },
- minimum: { $ref: '#/visitors/value' },
- exclusiveMinimum: { $ref: '#/visitors/value' },
- maxLength: { $ref: '#/visitors/value' },
- minLength: { $ref: '#/visitors/value' },
- pattern: { $ref: '#/visitors/value' },
- additionalItems: Cf,
- items: Rd,
- maxItems: { $ref: '#/visitors/value' },
- minItems: { $ref: '#/visitors/value' },
- uniqueItems: { $ref: '#/visitors/value' },
- maxProperties: { $ref: '#/visitors/value' },
- minProperties: { $ref: '#/visitors/value' },
- required: Dd,
- properties: Kd,
- additionalProperties: Cf,
- patternProperties: Hd,
- dependencies: Jd,
- enum: Gd,
- type: Yd,
- allOf: Xd,
- anyOf: Zd,
- oneOf: Qd,
- not: Cf,
- definitions: ef,
- title: { $ref: '#/visitors/value' },
- description: { $ref: '#/visitors/value' },
- default: { $ref: '#/visitors/value' },
- format: { $ref: '#/visitors/value' },
- base: { $ref: '#/visitors/value' },
- links: rf,
- media: { $ref: '#/visitors/document/objects/Media' },
- readOnly: { $ref: '#/visitors/value' }
- }
- },
- JSONReference: { $visitor: of, fixedFields: { $ref: af } },
- Media: {
- $visitor: Of,
- fixedFields: {
- binaryEncoding: { $ref: '#/visitors/value' },
- type: { $ref: '#/visitors/value' }
- }
- },
- LinkDescription: {
- $visitor: LinkDescriptionVisitor,
- fixedFields: {
- href: { $ref: '#/visitors/value' },
- rel: { $ref: '#/visitors/value' },
- title: { $ref: '#/visitors/value' },
- targetSchema: Cf,
- mediaType: { $ref: '#/visitors/value' },
- method: { $ref: '#/visitors/value' },
- encType: { $ref: '#/visitors/value' },
- schema: Cf
- }
- }
- }
- }
- }
- },
- traversal_visitor_getNodeType = (s) => {
- if (Nu(s)) return `${s.element.charAt(0).toUpperCase() + s.element.slice(1)}Element`;
- },
- Pf = {
- JSONSchemaDraft4Element: ['content'],
- JSONReferenceElement: ['content'],
- MediaElement: ['content'],
- LinkDescriptionElement: ['content'],
- ...Qu
- },
- Tf = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Jh || (s(u) && o('JSONSchemaDraft4', u) && i('object', u))
- ),
- Nf = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Gh || (s(u) && o('JSONReference', u) && i('object', u))
- ),
- Rf = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Qh || (s(u) && o('media', u) && i('object', u))
- ),
- Df = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof td || (s(u) && o('linkDescription', u) && i('object', u))
- ),
- Ff = {
- namespace: (s) => {
- const { base: o } = s;
- return (
- o.register('jSONSchemaDraft4', Jh),
- o.register('jSONReference', Gh),
- o.register('media', Qh),
- o.register('linkDescription', td),
- o
- );
- }
- },
- Vf = Ff,
- refractor_toolbox = () => {
- const s = createNamespace(Vf);
- return { predicates: { ...ce, isStringElement: Ru }, namespace: s };
- },
- refractor_refract = (
- s,
- {
- specPath: o = ['visitors', 'document', 'objects', 'JSONSchema', '$visitor'],
- plugins: i = [],
- specificationObj: u = jf
- } = {}
- ) => {
- const _ = (0, Cu.e)(s),
- w = dereference(u),
- x = new (cp(o, w))({ specObj: w });
- return (
- visitor_visit(_, x),
- dispatchPluginsSync(x.element, i, {
- toolboxCreator: refractor_toolbox,
- visitorOptions: { keyMap: Pf, nodeTypeGetter: traversal_visitor_getNodeType }
- })
- );
- },
- refractor_createRefractor =
- (s) =>
- (o, i = {}) =>
- refractor_refract(o, { specPath: s, ...i });
- (Jh.refract = refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'JSONSchema',
- '$visitor'
- ])),
- (Gh.refract = refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'JSONReference',
- '$visitor'
- ])),
- (Qh.refract = refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Media',
- '$visitor'
- ])),
- (td.refract = refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'LinkDescription',
- '$visitor'
- ]));
- const Wf = class Schema_Schema extends Jh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'schema'), this.classes.push('json-schema-draft-4');
- }
- get idProp() {
- throw new Hh('idProp getter in Schema class is not not supported.');
- }
- set idProp(s) {
- throw new Hh('idProp setter in Schema class is not not supported.');
- }
- get $schema() {
- throw new Hh('$schema getter in Schema class is not not supported.');
- }
- set $schema(s) {
- throw new Hh('$schema setter in Schema class is not not supported.');
- }
- get additionalItems() {
- return this.get('additionalItems');
- }
- set additionalItems(s) {
- this.set('additionalItems', s);
- }
- get items() {
- return this.get('items');
- }
- set items(s) {
- this.set('items', s);
- }
- get additionalProperties() {
- return this.get('additionalProperties');
- }
- set additionalProperties(s) {
- this.set('additionalProperties', s);
- }
- get patternProperties() {
- throw new Hh('patternProperties getter in Schema class is not not supported.');
- }
- set patternProperties(s) {
- throw new Hh('patternProperties setter in Schema class is not not supported.');
- }
- get dependencies() {
- throw new Hh('dependencies getter in Schema class is not not supported.');
- }
- set dependencies(s) {
- throw new Hh('dependencies setter in Schema class is not not supported.');
- }
- get type() {
- return this.get('type');
- }
- set type(s) {
- this.set('type', s);
- }
- get not() {
- return this.get('not');
- }
- set not(s) {
- this.set('not', s);
- }
- get definitions() {
- throw new Hh('definitions getter in Schema class is not not supported.');
- }
- set definitions(s) {
- throw new Hh('definitions setter in Schema class is not not supported.');
- }
- get base() {
- throw new Hh('base getter in Schema class is not not supported.');
- }
- set base(s) {
- throw new Hh('base setter in Schema class is not not supported.');
- }
- get links() {
- throw new Hh('links getter in Schema class is not not supported.');
- }
- set links(s) {
- throw new Hh('links setter in Schema class is not not supported.');
- }
- get media() {
- throw new Hh('media getter in Schema class is not not supported.');
- }
- set media(s) {
- throw new Hh('media setter in Schema class is not not supported.');
- }
- get nullable() {
- return this.get('nullable');
- }
- set nullable(s) {
- this.set('nullable', s);
- }
- get discriminator() {
- return this.get('discriminator');
- }
- set discriminator(s) {
- this.set('discriminator', s);
- }
- get writeOnly() {
- return this.get('writeOnly');
- }
- set writeOnly(s) {
- this.set('writeOnly', s);
- }
- get xml() {
- return this.get('xml');
- }
- set xml(s) {
- this.set('xml', s);
- }
- get externalDocs() {
- return this.get('externalDocs');
- }
- set externalDocs(s) {
- this.set('externalDocs', s);
- }
- get example() {
- return this.get('example');
- }
- set example(s) {
- this.set('example', s);
- }
- get deprecated() {
- return this.get('deprecated');
- }
- set deprecated(s) {
- this.set('deprecated', s);
- }
- };
- class SecurityRequirement extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'securityRequirement');
- }
- }
- const Hf = SecurityRequirement;
- class SecurityScheme extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'securityScheme');
- }
- get type() {
- return this.get('type');
- }
- set type(s) {
- this.set('type', s);
- }
- get description() {
- return this.get('description');
- }
- set description(s) {
- this.set('description', s);
- }
- get name() {
- return this.get('name');
- }
- set name(s) {
- this.set('name', s);
- }
- get in() {
- return this.get('in');
- }
- set in(s) {
- this.set('in', s);
- }
- get scheme() {
- return this.get('scheme');
- }
- set scheme(s) {
- this.set('scheme', s);
- }
- get bearerFormat() {
- return this.get('bearerFormat');
- }
- set bearerFormat(s) {
- this.set('bearerFormat', s);
- }
- get flows() {
- return this.get('flows');
- }
- set flows(s) {
- this.set('flows', s);
- }
- get openIdConnectUrl() {
- return this.get('openIdConnectUrl');
- }
- set openIdConnectUrl(s) {
- this.set('openIdConnectUrl', s);
- }
- }
- const Jf = SecurityScheme;
- class Server extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'server');
- }
- get url() {
- return this.get('url');
- }
- set url(s) {
- this.set('url', s);
- }
- get description() {
- return this.get('description');
- }
- set description(s) {
- this.set('description', s);
- }
- get variables() {
- return this.get('variables');
- }
- set variables(s) {
- this.set('variables', s);
- }
- }
- const Gf = Server;
- class ServerVariable extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'serverVariable');
- }
- get enum() {
- return this.get('enum');
- }
- set enum(s) {
- this.set('enum', s);
- }
- get default() {
- return this.get('default');
- }
- set default(s) {
- this.set('default', s);
- }
- get description() {
- return this.get('description');
- }
- set description(s) {
- this.set('description', s);
- }
- }
- const Xf = ServerVariable;
- class Tag extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'tag');
- }
- get name() {
- return this.get('name');
- }
- set name(s) {
- this.set('name', s);
- }
- get description() {
- return this.get('description');
- }
- set description(s) {
- this.set('description', s);
- }
- get externalDocs() {
- return this.get('externalDocs');
- }
- set externalDocs(s) {
- this.set('externalDocs', s);
- }
- }
- const Qf = Tag;
- class Xml extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'xml');
- }
- get name() {
- return this.get('name');
- }
- set name(s) {
- this.set('name', s);
- }
- get namespace() {
- return this.get('namespace');
- }
- set namespace(s) {
- this.set('namespace', s);
- }
- get prefix() {
- return this.get('prefix');
- }
- set prefix(s) {
- this.set('prefix', s);
- }
- get attribute() {
- return this.get('attribute');
- }
- set attribute(s) {
- this.set('attribute', s);
- }
- get wrapped() {
- return this.get('wrapped');
- }
- set wrapped(s) {
- this.set('wrapped', s);
- }
- }
- const em = Xml;
- const tm = class visitors_Visitor_Visitor {
- element;
- constructor(s = {}) {
- Object.assign(this, s);
- }
- copyMetaAndAttributes(s, o) {
- (s.meta.length > 0 || o.meta.length > 0) &&
- ((o.meta = deepmerge(o.meta, s.meta)),
- hasElementSourceMap(s) && o.meta.set('sourceMap', s.meta.get('sourceMap'))),
- (s.attributes.length > 0 || s.meta.length > 0) &&
- (o.attributes = deepmerge(o.attributes, s.attributes));
- }
- };
- const rm = class FallbackVisitor_FallbackVisitor extends tm {
- enter(s) {
- return (this.element = cloneDeep(s)), Ju;
- }
- };
- const nm = class SpecificationVisitor_SpecificationVisitor extends tm {
- specObj;
- passingOptionsNames = ['specObj', 'openApiGenericElement', 'openApiSemanticElement'];
- openApiGenericElement;
- openApiSemanticElement;
- constructor({
- specObj: s,
- passingOptionsNames: o,
- openApiGenericElement: i,
- openApiSemanticElement: u,
- ..._
- }) {
- super({ ..._ }),
- (this.specObj = s),
- (this.openApiGenericElement = i),
- (this.openApiSemanticElement = u),
- Array.isArray(o) && (this.passingOptionsNames = o);
- }
- retrievePassingOptions() {
- return Ad(this.passingOptionsNames, this);
- }
- retrieveFixedFields(s) {
- const o = cp(['visitors', ...s, 'fixedFields'], this.specObj);
- return 'object' == typeof o && null !== o ? Object.keys(o) : [];
- }
- retrieveVisitor(s) {
- return Xo(Wl, ['visitors', ...s], this.specObj)
- ? cp(['visitors', ...s], this.specObj)
- : cp(['visitors', ...s, '$visitor'], this.specObj);
- }
- retrieveVisitorInstance(s, o = {}) {
- const i = this.retrievePassingOptions();
- return new (this.retrieveVisitor(s))({ ...i, ...o });
- }
- toRefractedElement(s, o, i = {}) {
- const u = this.retrieveVisitorInstance(s, i);
- return u instanceof rm && (null == u ? void 0 : u.constructor) === rm
- ? cloneDeep(o)
- : (visitor_visit(o, u, i), u.element);
- }
- },
- isReferenceLikeElement = (s) => Fu(s) && s.hasKey('$ref'),
- sm = Fu,
- om = Fu,
- isOpenApiExtension = (s) => Ru(s.key) && Fp('x-', serializers_value(s.key));
- const im = class FixedFieldsVisitor_FixedFieldsVisitor extends nm {
- specPath;
- ignoredFields;
- canSupportSpecificationExtensions = !0;
- specificationExtensionPredicate = isOpenApiExtension;
- constructor({
- specPath: s,
- ignoredFields: o,
- canSupportSpecificationExtensions: i,
- specificationExtensionPredicate: u,
- ..._
- }) {
- super({ ..._ }),
- (this.specPath = s),
- (this.ignoredFields = o || []),
- 'boolean' == typeof i && (this.canSupportSpecificationExtensions = i),
- 'function' == typeof u && (this.specificationExtensionPredicate = u);
- }
- ObjectElement(s) {
- const o = this.specPath(s),
- i = this.retrieveFixedFields(o);
- return (
- s.forEach((s, u, _) => {
- if (
- Ru(u) &&
- i.includes(serializers_value(u)) &&
- !this.ignoredFields.includes(serializers_value(u))
- ) {
- const i = this.toRefractedElement([...o, 'fixedFields', serializers_value(u)], s),
- w = new Cu.Pr(cloneDeep(u), i);
- this.copyMetaAndAttributes(_, w),
- w.classes.push('fixed-field'),
- this.element.content.push(w);
- } else if (
- this.canSupportSpecificationExtensions &&
- this.specificationExtensionPredicate(_)
- ) {
- const s = this.toRefractedElement(['document', 'extension'], _);
- this.element.content.push(s);
- } else
- this.ignoredFields.includes(serializers_value(u)) ||
- this.element.content.push(cloneDeep(_));
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- };
- class OpenApi3_0Visitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Oh()),
- (this.specPath = Tl(['document', 'objects', 'OpenApi'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- ObjectElement(s) {
- return im.prototype.ObjectElement.call(this, s);
- }
- }
- const am = OpenApi3_0Visitor;
- class OpenapiVisitor extends Mixin(nm, rm) {
- StringElement(s) {
- const o = new wh(serializers_value(s));
- return this.copyMetaAndAttributes(s, o), (this.element = o), Ju;
- }
- }
- const lm = OpenapiVisitor;
- const cm = class SpecificationExtensionVisitor extends nm {
- MemberElement(s) {
- return (
- (this.element = cloneDeep(s)),
- this.element.classes.push('specification-extension'),
- Ju
- );
- }
- };
- class InfoVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new rh()),
- (this.specPath = Tl(['document', 'objects', 'Info'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const um = InfoVisitor;
- const pm = class VersionVisitor extends rm {
- StringElement(s) {
- const o = super.enter(s);
- return (
- this.element.classes.push('api-version'), this.element.classes.push('version'), o
- );
- }
- };
- class ContactVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Gp()),
- (this.specPath = Tl(['document', 'objects', 'Contact'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const hm = ContactVisitor;
- class LicenseVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new uh()),
- (this.specPath = Tl(['document', 'objects', 'License'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const dm = LicenseVisitor;
- class LinkVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new dh()),
- (this.specPath = Tl(['document', 'objects', 'Link'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- ObjectElement(s) {
- const o = im.prototype.ObjectElement.call(this, s);
- return (
- (Ru(this.element.operationId) || Ru(this.element.operationRef)) &&
- this.element.classes.push('reference-element'),
- o
- );
- }
- }
- const fm = LinkVisitor;
- const mm = class OperationRefVisitor extends rm {
- StringElement(s) {
- const o = super.enter(s);
- return this.element.classes.push('reference-value'), o;
- }
- };
- const gm = class OperationIdVisitor extends rm {
- StringElement(s) {
- const o = super.enter(s);
- return this.element.classes.push('reference-value'), o;
- }
- };
- const ym = class PatternedFieldsVisitor_PatternedFieldsVisitor extends nm {
- specPath;
- ignoredFields;
- fieldPatternPredicate = es_F;
- canSupportSpecificationExtensions = !1;
- specificationExtensionPredicate = isOpenApiExtension;
- constructor({
- specPath: s,
- ignoredFields: o,
- fieldPatternPredicate: i,
- canSupportSpecificationExtensions: u,
- specificationExtensionPredicate: _,
- ...w
- }) {
- super({ ...w }),
- (this.specPath = s),
- (this.ignoredFields = o || []),
- 'function' == typeof i && (this.fieldPatternPredicate = i),
- 'boolean' == typeof u && (this.canSupportSpecificationExtensions = u),
- 'function' == typeof _ && (this.specificationExtensionPredicate = _);
- }
- ObjectElement(s) {
- return (
- s.forEach((s, o, i) => {
- if (
- this.canSupportSpecificationExtensions &&
- this.specificationExtensionPredicate(i)
- ) {
- const s = this.toRefractedElement(['document', 'extension'], i);
- this.element.content.push(s);
- } else if (
- !this.ignoredFields.includes(serializers_value(o)) &&
- this.fieldPatternPredicate(serializers_value(o))
- ) {
- const u = this.specPath(s),
- _ = this.toRefractedElement(u, s),
- w = new Cu.Pr(cloneDeep(o), _);
- this.copyMetaAndAttributes(i, w),
- w.classes.push('patterned-field'),
- this.element.content.push(w);
- } else
- this.ignoredFields.includes(serializers_value(o)) ||
- this.element.content.push(cloneDeep(i));
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- };
- const vm = class MapVisitor_MapVisitor extends ym {
- constructor(s) {
- super(s), (this.fieldPatternPredicate = Vd);
- }
- };
- class LinkParameters extends Cu.Sh {
- static primaryClass = 'link-parameters';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(LinkParameters.primaryClass);
- }
- }
- const bm = LinkParameters;
- class ParametersVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s), (this.element = new bm()), (this.specPath = Tl(['value']));
- }
- }
- const _m = ParametersVisitor;
- class ServerVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Gf()),
- (this.specPath = Tl(['document', 'objects', 'Server'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const Em = ServerVisitor;
- const wm = class UrlVisitor extends rm {
- StringElement(s) {
- const o = super.enter(s);
- return this.element.classes.push('server-url'), o;
- }
- };
- class Servers extends Cu.wE {
- static primaryClass = 'servers';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(Servers.primaryClass);
- }
- }
- const Sm = Servers;
- class ServersVisitor extends Mixin(nm, rm) {
- constructor(s) {
- super(s), (this.element = new Sm());
- }
- ArrayElement(s) {
- return (
- s.forEach((s) => {
- const o = sm(s) ? ['document', 'objects', 'Server'] : ['value'],
- i = this.toRefractedElement(o, s);
- this.element.push(i);
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- }
- const xm = ServersVisitor;
- class ServerVariableVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Xf()),
- (this.specPath = Tl(['document', 'objects', 'ServerVariable'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const km = ServerVariableVisitor;
- class ServerVariables extends Cu.Sh {
- static primaryClass = 'server-variables';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(ServerVariables.primaryClass);
- }
- }
- const Cm = ServerVariables;
- class VariablesVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new Cm()),
- (this.specPath = Tl(['document', 'objects', 'ServerVariable']));
- }
- }
- const Om = VariablesVisitor;
- class MediaTypeVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new fh()),
- (this.specPath = Tl(['document', 'objects', 'MediaType'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const Am = MediaTypeVisitor;
- const jm = class AlternatingVisitor_AlternatingVisitor extends nm {
- alternator;
- constructor({ alternator: s, ...o }) {
- super({ ...o }), (this.alternator = s || []);
- }
- enter(s) {
- const o = this.alternator.map(({ predicate: s, specPath: o }) => lf(s, Tl(o), Nl)),
- i = xf(o)(s);
- return (this.element = this.toRefractedElement(i, s)), Ju;
- }
- },
- Im = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Hp || (s(u) && o('callback', u) && i('object', u))
- ),
- Pm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Jp || (s(u) && o('components', u) && i('object', u))
- ),
- Mm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Gp || (s(u) && o('contact', u) && i('object', u))
- ),
- Tm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Zp || (s(u) && o('example', u) && i('object', u))
- ),
- Nm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Qp || (s(u) && o('externalDocumentation', u) && i('object', u))
- ),
- Rm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof th || (s(u) && o('header', u) && i('object', u))
- ),
- Dm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof rh || (s(u) && o('info', u) && i('object', u))
- ),
- Lm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof uh || (s(u) && o('license', u) && i('object', u))
- ),
- Bm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof dh || (s(u) && o('link', u) && i('object', u))
- ),
- Fm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof wh || (s(u) && o('openapi', u) && i('string', u))
- ),
- qm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i, hasClass: u }) =>
- (_) =>
- _ instanceof Oh || (s(_) && o('openApi3_0', _) && i('object', _) && u('api', _))
- ),
- $m = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof jh || (s(u) && o('operation', u) && i('object', u))
- ),
- Vm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Ih || (s(u) && o('parameter', u) && i('object', u))
- ),
- Um = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Ph || (s(u) && o('pathItem', u) && i('object', u))
- ),
- zm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Rh || (s(u) && o('paths', u) && i('object', u))
- ),
- Wm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Dh || (s(u) && o('reference', u) && i('object', u))
- ),
- Km = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Lh || (s(u) && o('requestBody', u) && i('object', u))
- ),
- Hm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Fh || (s(u) && o('response', u) && i('object', u))
- ),
- Jm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Kh || (s(u) && o('responses', u) && i('object', u))
- ),
- Gm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Wf || (s(u) && o('schema', u) && i('object', u))
- ),
- isBooleanJsonSchemaElement = (s) => Bu(s) && s.classes.includes('boolean-json-schema'),
- Ym = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Hf || (s(u) && o('securityRequirement', u) && i('object', u))
- ),
- Xm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Jf || (s(u) && o('securityScheme', u) && i('object', u))
- ),
- Zm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Gf || (s(u) && o('server', u) && i('object', u))
- ),
- Qm = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Xf || (s(u) && o('serverVariable', u) && i('object', u))
- ),
- eg = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof fh || (s(u) && o('mediaType', u) && i('object', u))
- ),
- rg = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i, hasClass: u }) =>
- (_) =>
- _ instanceof Sm || (s(_) && o('array', _) && i('array', _) && u('servers', _))
- );
- class SchemaVisitor extends Mixin(jm, rm) {
- constructor(s) {
- super(s),
- (this.alternator = [
- {
- predicate: isReferenceLikeElement,
- specPath: ['document', 'objects', 'Reference']
- },
- { predicate: es_T, specPath: ['document', 'objects', 'Schema'] }
- ]);
- }
- ObjectElement(s) {
- const o = jm.prototype.enter.call(this, s);
- return (
- Wm(this.element) && this.element.setMetaProperty('referenced-element', 'schema'), o
- );
- }
- }
- const ng = SchemaVisitor;
- class ExamplesVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new Cu.Sh()),
- this.element.classes.push('examples'),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'Example']),
- (this.canSupportSpecificationExtensions = !0);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'example');
- }),
- o
- );
- }
- }
- const sg = ExamplesVisitor;
- class MediaTypeExamples extends Cu.Sh {
- static primaryClass = 'media-type-examples';
- constructor(s, o, i) {
- super(s, o, i),
- this.classes.push(MediaTypeExamples.primaryClass),
- this.classes.push('examples');
- }
- }
- const og = MediaTypeExamples;
- const lg = class ExamplesVisitor_ExamplesVisitor extends sg {
- constructor(s) {
- super(s), (this.element = new og());
- }
- };
- class MediaTypeEncoding extends Cu.Sh {
- static primaryClass = 'media-type-encoding';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(MediaTypeEncoding.primaryClass);
- }
- }
- const pg = MediaTypeEncoding;
- class EncodingVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new pg()),
- (this.specPath = Tl(['document', 'objects', 'Encoding']));
- }
- }
- const fg = EncodingVisitor;
- class SecurityRequirementVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s), (this.element = new Hf()), (this.specPath = Tl(['value']));
- }
- }
- const mg = SecurityRequirementVisitor;
- class Security extends Cu.wE {
- static primaryClass = 'security';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(Security.primaryClass);
- }
- }
- const gg = Security;
- class SecurityVisitor extends Mixin(nm, rm) {
- constructor(s) {
- super(s), (this.element = new gg());
- }
- ArrayElement(s) {
- return (
- s.forEach((s) => {
- if (Fu(s)) {
- const o = this.toRefractedElement(
- ['document', 'objects', 'SecurityRequirement'],
- s
- );
- this.element.push(o);
- } else this.element.push(cloneDeep(s));
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- }
- const yg = SecurityVisitor;
- class ComponentsVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Jp()),
- (this.specPath = Tl(['document', 'objects', 'Components'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const _g = ComponentsVisitor;
- class TagVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Qf()),
- (this.specPath = Tl(['document', 'objects', 'Tag'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const xg = TagVisitor;
- class ReferenceVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Dh()),
- (this.specPath = Tl(['document', 'objects', 'Reference'])),
- (this.canSupportSpecificationExtensions = !1);
- }
- ObjectElement(s) {
- const o = im.prototype.ObjectElement.call(this, s);
- return Ru(this.element.$ref) && this.element.classes.push('reference-element'), o;
- }
- }
- const kg = ReferenceVisitor;
- const qg = class $RefVisitor_$RefVisitor extends rm {
- StringElement(s) {
- const o = super.enter(s);
- return this.element.classes.push('reference-value'), o;
- }
- };
- class ParameterVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Ih()),
- (this.specPath = Tl(['document', 'objects', 'Parameter'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- ObjectElement(s) {
- const o = im.prototype.ObjectElement.call(this, s);
- return (
- Fu(this.element.contentProp) &&
- this.element.contentProp.filter(eg).forEach((s, o) => {
- s.setMetaProperty('media-type', serializers_value(o));
- }),
- o
- );
- }
- }
- const Vg = ParameterVisitor;
- class SchemaVisitor_SchemaVisitor extends Mixin(jm, rm) {
- constructor(s) {
- super(s),
- (this.alternator = [
- {
- predicate: isReferenceLikeElement,
- specPath: ['document', 'objects', 'Reference']
- },
- { predicate: es_T, specPath: ['document', 'objects', 'Schema'] }
- ]);
- }
- ObjectElement(s) {
- const o = jm.prototype.enter.call(this, s);
- return (
- Wm(this.element) && this.element.setMetaProperty('referenced-element', 'schema'), o
- );
- }
- }
- const Ug = SchemaVisitor_SchemaVisitor;
- class HeaderVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new th()),
- (this.specPath = Tl(['document', 'objects', 'Header'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const zg = HeaderVisitor;
- class header_SchemaVisitor_SchemaVisitor extends Mixin(jm, rm) {
- constructor(s) {
- super(s),
- (this.alternator = [
- {
- predicate: isReferenceLikeElement,
- specPath: ['document', 'objects', 'Reference']
- },
- { predicate: es_T, specPath: ['document', 'objects', 'Schema'] }
- ]);
- }
- ObjectElement(s) {
- const o = jm.prototype.enter.call(this, s);
- return (
- Wm(this.element) && this.element.setMetaProperty('referenced-element', 'schema'), o
- );
- }
- }
- const Wg = header_SchemaVisitor_SchemaVisitor;
- class HeaderExamples extends Cu.Sh {
- static primaryClass = 'header-examples';
- constructor(s, o, i) {
- super(s, o, i),
- this.classes.push(HeaderExamples.primaryClass),
- this.classes.push('examples');
- }
- }
- const Kg = HeaderExamples;
- const Yg = class header_ExamplesVisitor_ExamplesVisitor extends sg {
- constructor(s) {
- super(s), (this.element = new Kg());
- }
- };
- class ContentVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new Cu.Sh()),
- this.element.classes.push('content'),
- (this.specPath = Tl(['document', 'objects', 'MediaType']));
- }
- }
- const Xg = ContentVisitor;
- class HeaderContent extends Cu.Sh {
- static primaryClass = 'header-content';
- constructor(s, o, i) {
- super(s, o, i),
- this.classes.push(HeaderContent.primaryClass),
- this.classes.push('content');
- }
- }
- const Zg = HeaderContent;
- const ey = class ContentVisitor_ContentVisitor extends Xg {
- constructor(s) {
- super(s), (this.element = new Zg());
- }
- };
- class schema_SchemaVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Wf()),
- (this.specPath = Tl(['document', 'objects', 'Schema'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const ty = schema_SchemaVisitor,
- { allOf: ry } = jf.visitors.document.objects.JSONSchema.fixedFields;
- const ny = class AllOfVisitor_AllOfVisitor extends ry {
- ArrayElement(s) {
- const o = ry.prototype.ArrayElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'schema');
- }),
- o
- );
- }
- },
- { anyOf: sy } = jf.visitors.document.objects.JSONSchema.fixedFields;
- const oy = class AnyOfVisitor_AnyOfVisitor extends sy {
- ArrayElement(s) {
- const o = sy.prototype.ArrayElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'schema');
- }),
- o
- );
- }
- },
- { oneOf: iy } = jf.visitors.document.objects.JSONSchema.fixedFields;
- const ay = class OneOfVisitor_OneOfVisitor extends iy {
- ArrayElement(s) {
- const o = iy.prototype.ArrayElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'schema');
- }),
- o
- );
- }
- },
- { items: ly } = jf.visitors.document.objects.JSONSchema.fixedFields;
- const cy = class ItemsVisitor_ItemsVisitor extends ly {
- ObjectElement(s) {
- const o = ly.prototype.ObjectElement.call(this, s);
- return (
- Wm(this.element) && this.element.setMetaProperty('referenced-element', 'schema'), o
- );
- }
- ArrayElement(s) {
- return this.enter(s);
- }
- },
- { properties: uy } = jf.visitors.document.objects.JSONSchema.fixedFields;
- const py = class PropertiesVisitor_PropertiesVisitor extends uy {
- ObjectElement(s) {
- const o = uy.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'schema');
- }),
- o
- );
- }
- },
- { type: hy } = jf.visitors.document.objects.JSONSchema.fixedFields;
- const dy = class TypeVisitor_TypeVisitor extends hy {
- ArrayElement(s) {
- return this.enter(s);
- }
- },
- { JSONSchemaOrJSONReferenceVisitor: fy } = jf.visitors;
- const my = class SchemaOrReferenceVisitor_SchemaOrReferenceVisitor extends fy {
- ObjectElement(s) {
- const o = fy.prototype.enter.call(this, s);
- return (
- Wm(this.element) && this.element.setMetaProperty('referenced-element', 'schema'), o
- );
- }
- };
- class DiscriminatorVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Yp()),
- (this.specPath = Tl(['document', 'objects', 'Discriminator'])),
- (this.canSupportSpecificationExtensions = !1);
- }
- }
- const gy = DiscriminatorVisitor;
- class DiscriminatorMapping extends Cu.Sh {
- static primaryClass = 'discriminator-mapping';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(DiscriminatorMapping.primaryClass);
- }
- }
- const yy = DiscriminatorMapping;
- class MappingVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s), (this.element = new yy()), (this.specPath = Tl(['value']));
- }
- }
- const vy = MappingVisitor;
- class XmlVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new em()),
- (this.specPath = Tl(['document', 'objects', 'XML'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const by = XmlVisitor;
- class ParameterExamples extends Cu.Sh {
- static primaryClass = 'parameter-examples';
- constructor(s, o, i) {
- super(s, o, i),
- this.classes.push(ParameterExamples.primaryClass),
- this.classes.push('examples');
- }
- }
- const _y = ParameterExamples;
- const Ey = class parameter_ExamplesVisitor_ExamplesVisitor extends sg {
- constructor(s) {
- super(s), (this.element = new _y());
- }
- };
- class ParameterContent extends Cu.Sh {
- static primaryClass = 'parameter-content';
- constructor(s, o, i) {
- super(s, o, i),
- this.classes.push(ParameterContent.primaryClass),
- this.classes.push('content');
- }
- }
- const wy = ParameterContent;
- const Sy = class parameter_ContentVisitor_ContentVisitor extends Xg {
- constructor(s) {
- super(s), (this.element = new wy());
- }
- };
- class ComponentsSchemas extends Cu.Sh {
- static primaryClass = 'components-schemas';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(ComponentsSchemas.primaryClass);
- }
- }
- const xy = ComponentsSchemas;
- class SchemasVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new xy()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'Schema']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'schema');
- }),
- o
- );
- }
- }
- const ky = SchemasVisitor;
- class ComponentsResponses extends Cu.Sh {
- static primaryClass = 'components-responses';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(ComponentsResponses.primaryClass);
- }
- }
- const Cy = ComponentsResponses;
- class ResponsesVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new Cy()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'Response']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'response');
- }),
- this.element.filter(Hm).forEach((s, o) => {
- s.setMetaProperty('http-status-code', serializers_value(o));
- }),
- o
- );
- }
- }
- const Oy = ResponsesVisitor;
- class ComponentsParameters extends Cu.Sh {
- static primaryClass = 'components-parameters';
- constructor(s, o, i) {
- super(s, o, i),
- this.classes.push(ComponentsParameters.primaryClass),
- this.classes.push('parameters');
- }
- }
- const Ay = ComponentsParameters;
- class ParametersVisitor_ParametersVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new Ay()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'Parameter']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'parameter');
- }),
- o
- );
- }
- }
- const jy = ParametersVisitor_ParametersVisitor;
- class ComponentsExamples extends Cu.Sh {
- static primaryClass = 'components-examples';
- constructor(s, o, i) {
- super(s, o, i),
- this.classes.push(ComponentsExamples.primaryClass),
- this.classes.push('examples');
- }
- }
- const Iy = ComponentsExamples;
- class components_ExamplesVisitor_ExamplesVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new Iy()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'Example']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'example');
- }),
- o
- );
- }
- }
- const Py = components_ExamplesVisitor_ExamplesVisitor;
- class ComponentsRequestBodies extends Cu.Sh {
- static primaryClass = 'components-request-bodies';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(ComponentsRequestBodies.primaryClass);
- }
- }
- const My = ComponentsRequestBodies;
- class RequestBodiesVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new My()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'RequestBody']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'requestBody');
- }),
- o
- );
- }
- }
- const Ty = RequestBodiesVisitor;
- class ComponentsHeaders extends Cu.Sh {
- static primaryClass = 'components-headers';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(ComponentsHeaders.primaryClass);
- }
- }
- const Ny = ComponentsHeaders;
- class HeadersVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new Ny()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'Header']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'header');
- }),
- this.element.filter(Rm).forEach((s, o) => {
- s.setMetaProperty('header-name', serializers_value(o));
- }),
- o
- );
- }
- }
- const Ry = HeadersVisitor;
- class ComponentsSecuritySchemes extends Cu.Sh {
- static primaryClass = 'components-security-schemes';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(ComponentsSecuritySchemes.primaryClass);
- }
- }
- const Dy = ComponentsSecuritySchemes;
- class SecuritySchemesVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new Dy()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'SecurityScheme']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'securityScheme');
- }),
- o
- );
- }
- }
- const Ly = SecuritySchemesVisitor;
- class ComponentsLinks extends Cu.Sh {
- static primaryClass = 'components-links';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(ComponentsLinks.primaryClass);
- }
- }
- const By = ComponentsLinks;
- class LinksVisitor_LinksVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new By()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'Link']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'link');
- }),
- o
- );
- }
- }
- const Fy = LinksVisitor_LinksVisitor;
- class ComponentsCallbacks extends Cu.Sh {
- static primaryClass = 'components-callbacks';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(ComponentsCallbacks.primaryClass);
- }
- }
- const qy = ComponentsCallbacks;
- class CallbacksVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new qy()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'Callback']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'callback');
- }),
- o
- );
- }
- }
- const $y = CallbacksVisitor;
- class ExampleVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Zp()),
- (this.specPath = Tl(['document', 'objects', 'Example'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- ObjectElement(s) {
- const o = im.prototype.ObjectElement.call(this, s);
- return (
- Ru(this.element.externalValue) && this.element.classes.push('reference-element'), o
- );
- }
- }
- const Vy = ExampleVisitor;
- const Uy = class ExternalValueVisitor extends rm {
- StringElement(s) {
- const o = super.enter(s);
- return this.element.classes.push('reference-value'), o;
- }
- };
- class ExternalDocumentationVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Qp()),
- (this.specPath = Tl(['document', 'objects', 'ExternalDocumentation'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const zy = ExternalDocumentationVisitor;
- class encoding_EncodingVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Xp()),
- (this.specPath = Tl(['document', 'objects', 'Encoding'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- ObjectElement(s) {
- const o = im.prototype.ObjectElement.call(this, s);
- return (
- Fu(this.element.headers) &&
- this.element.headers.filter(Rm).forEach((s, o) => {
- s.setMetaProperty('header-name', serializers_value(o));
- }),
- o
- );
- }
- }
- const Wy = encoding_EncodingVisitor;
- class EncodingHeaders extends Cu.Sh {
- static primaryClass = 'encoding-headers';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(EncodingHeaders.primaryClass);
- }
- }
- const Ky = EncodingHeaders;
- class HeadersVisitor_HeadersVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new Ky()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'Header']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'header');
- }),
- this.element.forEach((s, o) => {
- if (!Rm(s)) return;
- const i = serializers_value(o);
- s.setMetaProperty('headerName', i);
- }),
- o
- );
- }
- }
- const Hy = HeadersVisitor_HeadersVisitor;
- class PathsVisitor extends Mixin(ym, rm) {
- constructor(s) {
- super(s),
- (this.element = new Rh()),
- (this.specPath = Tl(['document', 'objects', 'PathItem'])),
- (this.canSupportSpecificationExtensions = !0),
- (this.fieldPatternPredicate = es_T);
- }
- ObjectElement(s) {
- const o = ym.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Um).forEach((s, o) => {
- o.classes.push('openapi-path-template'),
- o.classes.push('path-template'),
- s.setMetaProperty('path', cloneDeep(o));
- }),
- o
- );
- }
- }
- const Jy = PathsVisitor;
- class RequestBodyVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Lh()),
- (this.specPath = Tl(['document', 'objects', 'RequestBody']));
- }
- ObjectElement(s) {
- const o = im.prototype.ObjectElement.call(this, s);
- return (
- Fu(this.element.contentProp) &&
- this.element.contentProp.filter(eg).forEach((s, o) => {
- s.setMetaProperty('media-type', serializers_value(o));
- }),
- o
- );
- }
- }
- const Gy = RequestBodyVisitor;
- class RequestBodyContent extends Cu.Sh {
- static primaryClass = 'request-body-content';
- constructor(s, o, i) {
- super(s, o, i),
- this.classes.push(RequestBodyContent.primaryClass),
- this.classes.push('content');
- }
- }
- const Yy = RequestBodyContent;
- const Xy = class request_body_ContentVisitor_ContentVisitor extends Xg {
- constructor(s) {
- super(s), (this.element = new Yy());
- }
- };
- class CallbackVisitor extends Mixin(ym, rm) {
- constructor(s) {
- super(s),
- (this.element = new Hp()),
- (this.specPath = Tl(['document', 'objects', 'PathItem'])),
- (this.canSupportSpecificationExtensions = !0),
- (this.fieldPatternPredicate = (s) => /{(?<expression>[^}]{1,2083})}/.test(String(s)));
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Um).forEach((s, o) => {
- s.setMetaProperty('runtime-expression', serializers_value(o));
- }),
- o
- );
- }
- }
- const Zy = CallbackVisitor;
- class ResponseVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Fh()),
- (this.specPath = Tl(['document', 'objects', 'Response']));
- }
- ObjectElement(s) {
- const o = im.prototype.ObjectElement.call(this, s);
- return (
- Fu(this.element.contentProp) &&
- this.element.contentProp.filter(eg).forEach((s, o) => {
- s.setMetaProperty('media-type', serializers_value(o));
- }),
- Fu(this.element.headers) &&
- this.element.headers.filter(Rm).forEach((s, o) => {
- s.setMetaProperty('header-name', serializers_value(o));
- }),
- o
- );
- }
- }
- const Qy = ResponseVisitor;
- class ResponseHeaders extends Cu.Sh {
- static primaryClass = 'response-headers';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(ResponseHeaders.primaryClass);
- }
- }
- const ev = ResponseHeaders;
- class response_HeadersVisitor_HeadersVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new ev()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'Header']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'header');
- }),
- this.element.forEach((s, o) => {
- if (!Rm(s)) return;
- const i = serializers_value(o);
- s.setMetaProperty('header-name', i);
- }),
- o
- );
- }
- }
- const tv = response_HeadersVisitor_HeadersVisitor;
- class ResponseContent extends Cu.Sh {
- static primaryClass = 'response-content';
- constructor(s, o, i) {
- super(s, o, i),
- this.classes.push(ResponseContent.primaryClass),
- this.classes.push('content');
- }
- }
- const rv = ResponseContent;
- const nv = class response_ContentVisitor_ContentVisitor extends Xg {
- constructor(s) {
- super(s), (this.element = new rv());
- }
- };
- class ResponseLinks extends Cu.Sh {
- static primaryClass = 'response-links';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(ResponseLinks.primaryClass);
- }
- }
- const sv = ResponseLinks;
- class response_LinksVisitor_LinksVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new sv()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'Link']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'link');
- }),
- o
- );
- }
- }
- const ov = response_LinksVisitor_LinksVisitor;
- function _isNumber(s) {
- return '[object Number]' === Object.prototype.toString.call(s);
- }
- var iv = _curry2(function range(s, o) {
- if (!_isNumber(s) || !_isNumber(o))
- throw new TypeError('Both arguments to range must be numbers');
- for (
- var i = Array(s < o ? o - s : 0), u = s < 0 ? o + Math.abs(s) : o - s, _ = 0;
- _ < u;
- )
- (i[_] = _ + s), (_ += 1);
- return i;
- });
- const av = iv;
- function hasOrAdd(s, o, i) {
- var u,
- _ = typeof s;
- switch (_) {
- case 'string':
- case 'number':
- return 0 === s && 1 / s == -1 / 0
- ? !!i._items['-0'] || (o && (i._items['-0'] = !0), !1)
- : null !== i._nativeSet
- ? o
- ? ((u = i._nativeSet.size), i._nativeSet.add(s), i._nativeSet.size === u)
- : i._nativeSet.has(s)
- : _ in i._items
- ? s in i._items[_] || (o && (i._items[_][s] = !0), !1)
- : (o && ((i._items[_] = {}), (i._items[_][s] = !0)), !1);
- case 'boolean':
- if (_ in i._items) {
- var w = s ? 1 : 0;
- return !!i._items[_][w] || (o && (i._items[_][w] = !0), !1);
- }
- return o && (i._items[_] = s ? [!1, !0] : [!0, !1]), !1;
- case 'function':
- return null !== i._nativeSet
- ? o
- ? ((u = i._nativeSet.size), i._nativeSet.add(s), i._nativeSet.size === u)
- : i._nativeSet.has(s)
- : _ in i._items
- ? !!_includes(s, i._items[_]) || (o && i._items[_].push(s), !1)
- : (o && (i._items[_] = [s]), !1);
- case 'undefined':
- return !!i._items[_] || (o && (i._items[_] = !0), !1);
- case 'object':
- if (null === s) return !!i._items.null || (o && (i._items.null = !0), !1);
- default:
- return (_ = Object.prototype.toString.call(s)) in i._items
- ? !!_includes(s, i._items[_]) || (o && i._items[_].push(s), !1)
- : (o && (i._items[_] = [s]), !1);
- }
- }
- const lv = (function () {
- function _Set() {
- (this._nativeSet = 'function' == typeof Set ? new Set() : null), (this._items = {});
- }
- return (
- (_Set.prototype.add = function (s) {
- return !hasOrAdd(s, !0, this);
- }),
- (_Set.prototype.has = function (s) {
- return hasOrAdd(s, !1, this);
- }),
- _Set
- );
- })();
- var cv = _curry2(function difference(s, o) {
- for (var i = [], u = 0, _ = s.length, w = o.length, x = new lv(), C = 0; C < w; C += 1)
- x.add(o[C]);
- for (; u < _; ) x.add(s[u]) && (i[i.length] = s[u]), (u += 1);
- return i;
- });
- const uv = cv;
- class MixedFieldsVisitor extends Mixin(im, ym) {
- specPathFixedFields;
- specPathPatternedFields;
- constructor({ specPathFixedFields: s, specPathPatternedFields: o, ...i }) {
- super({ ...i }), (this.specPathFixedFields = s), (this.specPathPatternedFields = o);
- }
- ObjectElement(s) {
- const { specPath: o, ignoredFields: i } = this;
- try {
- this.specPath = this.specPathFixedFields;
- const o = this.retrieveFixedFields(this.specPath(s));
- (this.ignoredFields = [...i, ...uv(s.keys(), o)]),
- im.prototype.ObjectElement.call(this, s),
- (this.specPath = this.specPathPatternedFields),
- (this.ignoredFields = o),
- ym.prototype.ObjectElement.call(this, s);
- } catch (s) {
- throw ((this.specPath = o), s);
- }
- return Ju;
- }
- }
- const pv = MixedFieldsVisitor;
- class responses_ResponsesVisitor extends Mixin(pv, rm) {
- constructor(s) {
- super(s),
- (this.element = new Kh()),
- (this.specPathFixedFields = Tl(['document', 'objects', 'Responses'])),
- (this.canSupportSpecificationExtensions = !0),
- (this.specPathPatternedFields = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'Response']),
- (this.fieldPatternPredicate = (s) =>
- new RegExp(`^(1XX|2XX|3XX|4XX|5XX|${av(100, 600).join('|')})$`).test(String(s)));
- }
- ObjectElement(s) {
- const o = pv.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'response');
- }),
- this.element.filter(Hm).forEach((s, o) => {
- const i = cloneDeep(o);
- this.fieldPatternPredicate(serializers_value(i)) &&
- s.setMetaProperty('http-status-code', i);
- }),
- o
- );
- }
- }
- const hv = responses_ResponsesVisitor;
- class DefaultVisitor extends Mixin(jm, rm) {
- constructor(s) {
- super(s),
- (this.alternator = [
- {
- predicate: isReferenceLikeElement,
- specPath: ['document', 'objects', 'Reference']
- },
- { predicate: es_T, specPath: ['document', 'objects', 'Response'] }
- ]);
- }
- ObjectElement(s) {
- const o = jm.prototype.enter.call(this, s);
- return (
- Wm(this.element)
- ? this.element.setMetaProperty('referenced-element', 'response')
- : Hm(this.element) && this.element.setMetaProperty('http-status-code', 'default'),
- o
- );
- }
- }
- const dv = DefaultVisitor;
- class OperationVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new jh()),
- (this.specPath = Tl(['document', 'objects', 'Operation']));
- }
- }
- const fv = OperationVisitor;
- class OperationTags extends Cu.wE {
- static primaryClass = 'operation-tags';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(OperationTags.primaryClass);
- }
- }
- const mv = OperationTags;
- const gv = class TagsVisitor extends rm {
- constructor(s) {
- super(s), (this.element = new mv());
- }
- ArrayElement(s) {
- return (this.element = this.element.concat(cloneDeep(s))), Ju;
- }
- };
- class OperationParameters extends Cu.wE {
- static primaryClass = 'operation-parameters';
- constructor(s, o, i) {
- super(s, o, i),
- this.classes.push(OperationParameters.primaryClass),
- this.classes.push('parameters');
- }
- }
- const yv = OperationParameters;
- class open_api_3_0_ParametersVisitor_ParametersVisitor extends Mixin(nm, rm) {
- constructor(s) {
- super(s), (this.element = new Cu.wE()), this.element.classes.push('parameters');
- }
- ArrayElement(s) {
- return (
- s.forEach((s) => {
- const o = isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'Parameter'],
- i = this.toRefractedElement(o, s);
- Wm(i) && i.setMetaProperty('referenced-element', 'parameter'), this.element.push(i);
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- }
- const vv = open_api_3_0_ParametersVisitor_ParametersVisitor;
- const bv = class operation_ParametersVisitor_ParametersVisitor extends vv {
- constructor(s) {
- super(s), (this.element = new yv());
- }
- };
- const _v = class RequestBodyVisitor_RequestBodyVisitor extends jm {
- constructor(s) {
- super(s),
- (this.alternator = [
- {
- predicate: isReferenceLikeElement,
- specPath: ['document', 'objects', 'Reference']
- },
- { predicate: es_T, specPath: ['document', 'objects', 'RequestBody'] }
- ]);
- }
- ObjectElement(s) {
- const o = jm.prototype.enter.call(this, s);
- return (
- Wm(this.element) && this.element.setMetaProperty('referenced-element', 'requestBody'),
- o
- );
- }
- };
- class OperationCallbacks extends Cu.Sh {
- static primaryClass = 'operation-callbacks';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(OperationCallbacks.primaryClass);
- }
- }
- const Ev = OperationCallbacks;
- class CallbacksVisitor_CallbacksVisitor extends Mixin(vm, rm) {
- specPath;
- constructor(s) {
- super(s),
- (this.element = new Ev()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'Callback']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(Wm).forEach((s) => {
- s.setMetaProperty('referenced-element', 'callback');
- }),
- o
- );
- }
- }
- const wv = CallbacksVisitor_CallbacksVisitor;
- class OperationSecurity extends Cu.wE {
- static primaryClass = 'operation-security';
- constructor(s, o, i) {
- super(s, o, i),
- this.classes.push(OperationSecurity.primaryClass),
- this.classes.push('security');
- }
- }
- const Sv = OperationSecurity;
- class SecurityVisitor_SecurityVisitor extends Mixin(nm, rm) {
- constructor(s) {
- super(s), (this.element = new Sv());
- }
- ArrayElement(s) {
- return (
- s.forEach((s) => {
- const o = Fu(s) ? ['document', 'objects', 'SecurityRequirement'] : ['value'],
- i = this.toRefractedElement(o, s);
- this.element.push(i);
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- }
- const xv = SecurityVisitor_SecurityVisitor;
- class OperationServers extends Cu.wE {
- static primaryClass = 'operation-servers';
- constructor(s, o, i) {
- super(s, o, i),
- this.classes.push(OperationServers.primaryClass),
- this.classes.push('servers');
- }
- }
- const kv = OperationServers;
- const Cv = class ServersVisitor_ServersVisitor extends xm {
- constructor(s) {
- super(s), (this.element = new kv());
- }
- };
- class PathItemVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Ph()),
- (this.specPath = Tl(['document', 'objects', 'PathItem']));
- }
- ObjectElement(s) {
- const o = im.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter($m).forEach((s, o) => {
- const i = cloneDeep(o);
- (i.content = serializers_value(i).toUpperCase()),
- s.setMetaProperty('http-method', i);
- }),
- Ru(this.element.$ref) && this.element.classes.push('reference-element'),
- o
- );
- }
- }
- const Ov = PathItemVisitor;
- const Av = class path_item_$RefVisitor_$RefVisitor extends rm {
- StringElement(s) {
- const o = super.enter(s);
- return this.element.classes.push('reference-value'), o;
- }
- };
- class PathItemServers extends Cu.wE {
- static primaryClass = 'path-item-servers';
- constructor(s, o, i) {
- super(s, o, i),
- this.classes.push(PathItemServers.primaryClass),
- this.classes.push('servers');
- }
- }
- const jv = PathItemServers;
- const Iv = class path_item_ServersVisitor_ServersVisitor extends xm {
- constructor(s) {
- super(s), (this.element = new jv());
- }
- };
- class PathItemParameters extends Cu.wE {
- static primaryClass = 'path-item-parameters';
- constructor(s, o, i) {
- super(s, o, i),
- this.classes.push(PathItemParameters.primaryClass),
- this.classes.push('parameters');
- }
- }
- const Pv = PathItemParameters;
- const Mv = class path_item_ParametersVisitor_ParametersVisitor extends vv {
- constructor(s) {
- super(s), (this.element = new Pv());
- }
- };
- class SecuritySchemeVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new Jf()),
- (this.specPath = Tl(['document', 'objects', 'SecurityScheme'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const Tv = SecuritySchemeVisitor;
- class OAuthFlowsVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new _h()),
- (this.specPath = Tl(['document', 'objects', 'OAuthFlows'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const Nv = OAuthFlowsVisitor;
- class OAuthFlowVisitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new vh()),
- (this.specPath = Tl(['document', 'objects', 'OAuthFlow'])),
- (this.canSupportSpecificationExtensions = !0);
- }
- }
- const Rv = OAuthFlowVisitor;
- class OAuthFlowScopes extends Cu.Sh {
- static primaryClass = 'oauth-flow-scopes';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(OAuthFlowScopes.primaryClass);
- }
- }
- const Dv = OAuthFlowScopes;
- class ScopesVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s), (this.element = new Dv()), (this.specPath = Tl(['value']));
- }
- }
- const Lv = ScopesVisitor;
- class Tags extends Cu.wE {
- static primaryClass = 'tags';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(Tags.primaryClass);
- }
- }
- const Bv = Tags;
- class TagsVisitor_TagsVisitor extends Mixin(nm, rm) {
- constructor(s) {
- super(s), (this.element = new Bv());
- }
- ArrayElement(s) {
- return (
- s.forEach((s) => {
- const o = om(s) ? ['document', 'objects', 'Tag'] : ['value'],
- i = this.toRefractedElement(o, s);
- this.element.push(i);
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- }
- const Fv = TagsVisitor_TagsVisitor,
- { fixedFields: qv } = jf.visitors.document.objects.JSONSchema,
- $v = {
- visitors: {
- value: rm,
- document: {
- objects: {
- OpenApi: {
- $visitor: am,
- fixedFields: {
- openapi: lm,
- info: { $ref: '#/visitors/document/objects/Info' },
- servers: xm,
- paths: { $ref: '#/visitors/document/objects/Paths' },
- components: { $ref: '#/visitors/document/objects/Components' },
- security: yg,
- tags: Fv,
- externalDocs: { $ref: '#/visitors/document/objects/ExternalDocumentation' }
- }
- },
- Info: {
- $visitor: um,
- fixedFields: {
- title: { $ref: '#/visitors/value' },
- description: { $ref: '#/visitors/value' },
- termsOfService: { $ref: '#/visitors/value' },
- contact: { $ref: '#/visitors/document/objects/Contact' },
- license: { $ref: '#/visitors/document/objects/License' },
- version: pm
- }
- },
- Contact: {
- $visitor: hm,
- fixedFields: {
- name: { $ref: '#/visitors/value' },
- url: { $ref: '#/visitors/value' },
- email: { $ref: '#/visitors/value' }
- }
- },
- License: {
- $visitor: dm,
- fixedFields: {
- name: { $ref: '#/visitors/value' },
- url: { $ref: '#/visitors/value' }
- }
- },
- Server: {
- $visitor: Em,
- fixedFields: {
- url: wm,
- description: { $ref: '#/visitors/value' },
- variables: Om
- }
- },
- ServerVariable: {
- $visitor: km,
- fixedFields: {
- enum: { $ref: '#/visitors/value' },
- default: { $ref: '#/visitors/value' },
- description: { $ref: '#/visitors/value' }
- }
- },
- Components: {
- $visitor: _g,
- fixedFields: {
- schemas: ky,
- responses: Oy,
- parameters: jy,
- examples: Py,
- requestBodies: Ty,
- headers: Ry,
- securitySchemes: Ly,
- links: Fy,
- callbacks: $y
- }
- },
- Paths: { $visitor: Jy },
- PathItem: {
- $visitor: Ov,
- fixedFields: {
- $ref: Av,
- summary: { $ref: '#/visitors/value' },
- description: { $ref: '#/visitors/value' },
- get: { $ref: '#/visitors/document/objects/Operation' },
- put: { $ref: '#/visitors/document/objects/Operation' },
- post: { $ref: '#/visitors/document/objects/Operation' },
- delete: { $ref: '#/visitors/document/objects/Operation' },
- options: { $ref: '#/visitors/document/objects/Operation' },
- head: { $ref: '#/visitors/document/objects/Operation' },
- patch: { $ref: '#/visitors/document/objects/Operation' },
- trace: { $ref: '#/visitors/document/objects/Operation' },
- servers: Iv,
- parameters: Mv
- }
- },
- Operation: {
- $visitor: fv,
- fixedFields: {
- tags: gv,
- summary: { $ref: '#/visitors/value' },
- description: { $ref: '#/visitors/value' },
- externalDocs: { $ref: '#/visitors/document/objects/ExternalDocumentation' },
- operationId: { $ref: '#/visitors/value' },
- parameters: bv,
- requestBody: _v,
- responses: { $ref: '#/visitors/document/objects/Responses' },
- callbacks: wv,
- deprecated: { $ref: '#/visitors/value' },
- security: xv,
- servers: Cv
- }
- },
- ExternalDocumentation: {
- $visitor: zy,
- fixedFields: {
- description: { $ref: '#/visitors/value' },
- url: { $ref: '#/visitors/value' }
- }
- },
- Parameter: {
- $visitor: Vg,
- fixedFields: {
- name: { $ref: '#/visitors/value' },
- in: { $ref: '#/visitors/value' },
- description: { $ref: '#/visitors/value' },
- required: { $ref: '#/visitors/value' },
- deprecated: { $ref: '#/visitors/value' },
- allowEmptyValue: { $ref: '#/visitors/value' },
- style: { $ref: '#/visitors/value' },
- explode: { $ref: '#/visitors/value' },
- allowReserved: { $ref: '#/visitors/value' },
- schema: Ug,
- example: { $ref: '#/visitors/value' },
- examples: Ey,
- content: Sy
- }
- },
- RequestBody: {
- $visitor: Gy,
- fixedFields: {
- description: { $ref: '#/visitors/value' },
- content: Xy,
- required: { $ref: '#/visitors/value' }
- }
- },
- MediaType: {
- $visitor: Am,
- fixedFields: {
- schema: ng,
- example: { $ref: '#/visitors/value' },
- examples: lg,
- encoding: fg
- }
- },
- Encoding: {
- $visitor: Wy,
- fixedFields: {
- contentType: { $ref: '#/visitors/value' },
- headers: Hy,
- style: { $ref: '#/visitors/value' },
- explode: { $ref: '#/visitors/value' },
- allowReserved: { $ref: '#/visitors/value' }
- }
- },
- Responses: { $visitor: hv, fixedFields: { default: dv } },
- Response: {
- $visitor: Qy,
- fixedFields: {
- description: { $ref: '#/visitors/value' },
- headers: tv,
- content: nv,
- links: ov
- }
- },
- Callback: { $visitor: Zy },
- Example: {
- $visitor: Vy,
- fixedFields: {
- summary: { $ref: '#/visitors/value' },
- description: { $ref: '#/visitors/value' },
- value: { $ref: '#/visitors/value' },
- externalValue: Uy
- }
- },
- Link: {
- $visitor: fm,
- fixedFields: {
- operationRef: mm,
- operationId: gm,
- parameters: _m,
- requestBody: { $ref: '#/visitors/value' },
- description: { $ref: '#/visitors/value' },
- server: { $ref: '#/visitors/document/objects/Server' }
- }
- },
- Header: {
- $visitor: zg,
- fixedFields: {
- description: { $ref: '#/visitors/value' },
- required: { $ref: '#/visitors/value' },
- deprecated: { $ref: '#/visitors/value' },
- allowEmptyValue: { $ref: '#/visitors/value' },
- style: { $ref: '#/visitors/value' },
- explode: { $ref: '#/visitors/value' },
- allowReserved: { $ref: '#/visitors/value' },
- schema: Wg,
- example: { $ref: '#/visitors/value' },
- examples: Yg,
- content: ey
- }
- },
- Tag: {
- $visitor: xg,
- fixedFields: {
- name: { $ref: '#/visitors/value' },
- description: { $ref: '#/visitors/value' },
- externalDocs: { $ref: '#/visitors/document/objects/ExternalDocumentation' }
- }
- },
- Reference: { $visitor: kg, fixedFields: { $ref: qg } },
- JSONSchema: { $ref: '#/visitors/document/objects/Schema' },
- JSONReference: { $ref: '#/visitors/document/objects/Reference' },
- Schema: {
- $visitor: ty,
- fixedFields: {
- title: qv.title,
- multipleOf: qv.multipleOf,
- maximum: qv.maximum,
- exclusiveMaximum: qv.exclusiveMaximum,
- minimum: qv.minimum,
- exclusiveMinimum: qv.exclusiveMinimum,
- maxLength: qv.maxLength,
- minLength: qv.minLength,
- pattern: qv.pattern,
- maxItems: qv.maxItems,
- minItems: qv.minItems,
- uniqueItems: qv.uniqueItems,
- maxProperties: qv.maxProperties,
- minProperties: qv.minProperties,
- required: qv.required,
- enum: qv.enum,
- type: dy,
- allOf: ny,
- anyOf: oy,
- oneOf: ay,
- not: my,
- items: cy,
- properties: py,
- additionalProperties: my,
- description: qv.description,
- format: qv.format,
- default: qv.default,
- nullable: { $ref: '#/visitors/value' },
- discriminator: { $ref: '#/visitors/document/objects/Discriminator' },
- writeOnly: { $ref: '#/visitors/value' },
- xml: { $ref: '#/visitors/document/objects/XML' },
- externalDocs: { $ref: '#/visitors/document/objects/ExternalDocumentation' },
- example: { $ref: '#/visitors/value' },
- deprecated: { $ref: '#/visitors/value' }
- }
- },
- Discriminator: {
- $visitor: gy,
- fixedFields: { propertyName: { $ref: '#/visitors/value' }, mapping: vy }
- },
- XML: {
- $visitor: by,
- fixedFields: {
- name: { $ref: '#/visitors/value' },
- namespace: { $ref: '#/visitors/value' },
- prefix: { $ref: '#/visitors/value' },
- attribute: { $ref: '#/visitors/value' },
- wrapped: { $ref: '#/visitors/value' }
- }
- },
- SecurityScheme: {
- $visitor: Tv,
- fixedFields: {
- type: { $ref: '#/visitors/value' },
- description: { $ref: '#/visitors/value' },
- name: { $ref: '#/visitors/value' },
- in: { $ref: '#/visitors/value' },
- scheme: { $ref: '#/visitors/value' },
- bearerFormat: { $ref: '#/visitors/value' },
- flows: { $ref: '#/visitors/document/objects/OAuthFlows' },
- openIdConnectUrl: { $ref: '#/visitors/value' }
- }
- },
- OAuthFlows: {
- $visitor: Nv,
- fixedFields: {
- implicit: { $ref: '#/visitors/document/objects/OAuthFlow' },
- password: { $ref: '#/visitors/document/objects/OAuthFlow' },
- clientCredentials: { $ref: '#/visitors/document/objects/OAuthFlow' },
- authorizationCode: { $ref: '#/visitors/document/objects/OAuthFlow' }
- }
- },
- OAuthFlow: {
- $visitor: Rv,
- fixedFields: {
- authorizationUrl: { $ref: '#/visitors/value' },
- tokenUrl: { $ref: '#/visitors/value' },
- refreshUrl: { $ref: '#/visitors/value' },
- scopes: Lv
- }
- },
- SecurityRequirement: { $visitor: mg }
- },
- extension: { $visitor: cm }
- }
- }
- },
- es_traversal_visitor_getNodeType = (s) => {
- if (Nu(s)) return `${s.element.charAt(0).toUpperCase() + s.element.slice(1)}Element`;
- },
- Vv = {
- CallbackElement: ['content'],
- ComponentsElement: ['content'],
- ContactElement: ['content'],
- DiscriminatorElement: ['content'],
- Encoding: ['content'],
- Example: ['content'],
- ExternalDocumentationElement: ['content'],
- HeaderElement: ['content'],
- InfoElement: ['content'],
- LicenseElement: ['content'],
- MediaTypeElement: ['content'],
- OAuthFlowElement: ['content'],
- OAuthFlowsElement: ['content'],
- OpenApi3_0Element: ['content'],
- OperationElement: ['content'],
- ParameterElement: ['content'],
- PathItemElement: ['content'],
- PathsElement: ['content'],
- ReferenceElement: ['content'],
- RequestBodyElement: ['content'],
- ResponseElement: ['content'],
- ResponsesElement: ['content'],
- SchemaElement: ['content'],
- SecurityRequirementElement: ['content'],
- SecuritySchemeElement: ['content'],
- ServerElement: ['content'],
- ServerVariableElement: ['content'],
- TagElement: ['content'],
- ...Qu
- },
- Uv = {
- namespace: (s) => {
- const { base: o } = s;
- return (
- o.register('callback', Hp),
- o.register('components', Jp),
- o.register('contact', Gp),
- o.register('discriminator', Yp),
- o.register('encoding', Xp),
- o.register('example', Zp),
- o.register('externalDocumentation', Qp),
- o.register('header', th),
- o.register('info', rh),
- o.register('license', uh),
- o.register('link', dh),
- o.register('mediaType', fh),
- o.register('oAuthFlow', vh),
- o.register('oAuthFlows', _h),
- o.register('openapi', wh),
- o.register('openApi3_0', Oh),
- o.register('operation', jh),
- o.register('parameter', Ih),
- o.register('pathItem', Ph),
- o.register('paths', Rh),
- o.register('reference', Dh),
- o.register('requestBody', Lh),
- o.register('response', Fh),
- o.register('responses', Kh),
- o.register('schema', Wf),
- o.register('securityRequirement', Hf),
- o.register('securityScheme', Jf),
- o.register('server', Gf),
- o.register('serverVariable', Xf),
- o.register('tag', Qf),
- o.register('xml', em),
- o
- );
- }
- },
- zv = Uv,
- es_refractor_toolbox = () => {
- const s = createNamespace(zv);
- return {
- predicates: {
- ...pe,
- isElement: Nu,
- isStringElement: Ru,
- isArrayElement: qu,
- isObjectElement: Fu,
- isMemberElement: $u,
- includesClasses,
- hasElementSourceMap
- },
- namespace: s
- };
- },
- es_refractor_refract = (
- s,
- {
- specPath: o = ['visitors', 'document', 'objects', 'OpenApi', '$visitor'],
- plugins: i = []
- } = {}
- ) => {
- const u = (0, Cu.e)(s),
- _ = dereference($v),
- w = new (cp(o, _))({ specObj: _ });
- return (
- visitor_visit(u, w),
- dispatchPluginsSync(w.element, i, {
- toolboxCreator: es_refractor_toolbox,
- visitorOptions: { keyMap: Vv, nodeTypeGetter: es_traversal_visitor_getNodeType }
- })
- );
- },
- es_refractor_createRefractor =
- (s) =>
- (o, i = {}) =>
- es_refractor_refract(o, { specPath: s, ...i });
- (Hp.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Callback',
- '$visitor'
- ])),
- (Jp.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Components',
- '$visitor'
- ])),
- (Gp.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Contact',
- '$visitor'
- ])),
- (Zp.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Example',
- '$visitor'
- ])),
- (Yp.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Discriminator',
- '$visitor'
- ])),
- (Xp.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Encoding',
- '$visitor'
- ])),
- (Qp.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'ExternalDocumentation',
- '$visitor'
- ])),
- (th.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Header',
- '$visitor'
- ])),
- (rh.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Info',
- '$visitor'
- ])),
- (uh.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'License',
- '$visitor'
- ])),
- (dh.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Link',
- '$visitor'
- ])),
- (fh.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'MediaType',
- '$visitor'
- ])),
- (vh.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'OAuthFlow',
- '$visitor'
- ])),
- (_h.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'OAuthFlows',
- '$visitor'
- ])),
- (wh.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'OpenApi',
- 'fixedFields',
- 'openapi'
- ])),
- (Oh.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'OpenApi',
- '$visitor'
- ])),
- (jh.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Operation',
- '$visitor'
- ])),
- (Ih.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Parameter',
- '$visitor'
- ])),
- (Ph.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'PathItem',
- '$visitor'
- ])),
- (Rh.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Paths',
- '$visitor'
- ])),
- (Dh.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Reference',
- '$visitor'
- ])),
- (Lh.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'RequestBody',
- '$visitor'
- ])),
- (Fh.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Response',
- '$visitor'
- ])),
- (Kh.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Responses',
- '$visitor'
- ])),
- (Wf.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Schema',
- '$visitor'
- ])),
- (Hf.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'SecurityRequirement',
- '$visitor'
- ])),
- (Jf.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'SecurityScheme',
- '$visitor'
- ])),
- (Gf.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Server',
- '$visitor'
- ])),
- (Xf.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'ServerVariable',
- '$visitor'
- ])),
- (Qf.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Tag',
- '$visitor'
- ])),
- (em.refract = es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'XML',
- '$visitor'
- ]));
- const Wv = class Callback_Callback extends Hp {};
- const Kv = class Components_Components extends Jp {
- get pathItems() {
- return this.get('pathItems');
- }
- set pathItems(s) {
- this.set('pathItems', s);
- }
- };
- const Hv = class Contact_Contact extends Gp {};
- const Jv = class Discriminator_Discriminator extends Yp {};
- const Gv = class Encoding_Encoding extends Xp {};
- const Yv = class Example_Example extends Zp {};
- const Xv = class ExternalDocumentation_ExternalDocumentation extends Qp {};
- const Zv = class Header_Header extends th {
- get schema() {
- return this.get('schema');
- }
- set schema(s) {
- this.set('schema', s);
- }
- };
- const Qv = class Info_Info extends rh {
- get license() {
- return this.get('license');
- }
- set license(s) {
- this.set('license', s);
- }
- get summary() {
- return this.get('summary');
- }
- set summary(s) {
- this.set('summary', s);
- }
- };
- class JsonSchemaDialect extends Cu.Om {
- static default = new JsonSchemaDialect('https://spec.openapis.org/oas/3.1/dialect/base');
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'jsonSchemaDialect');
- }
- }
- const eb = JsonSchemaDialect;
- const tb = class License_License extends uh {
- get identifier() {
- return this.get('identifier');
- }
- set identifier(s) {
- this.set('identifier', s);
- }
- };
- const nb = class Link_Link extends dh {};
- const pb = class MediaType_MediaType extends fh {
- get schema() {
- return this.get('schema');
- }
- set schema(s) {
- this.set('schema', s);
- }
- };
- const mb = class OAuthFlow_OAuthFlow extends vh {};
- const yb = class OAuthFlows_OAuthFlows extends _h {};
- const _b = class Openapi_Openapi extends wh {};
- class OpenApi3_1 extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'openApi3_1'), this.classes.push('api');
- }
- get openapi() {
- return this.get('openapi');
- }
- set openapi(s) {
- this.set('openapi', s);
- }
- get info() {
- return this.get('info');
- }
- set info(s) {
- this.set('info', s);
- }
- get jsonSchemaDialect() {
- return this.get('jsonSchemaDialect');
- }
- set jsonSchemaDialect(s) {
- this.set('jsonSchemaDialect', s);
- }
- get servers() {
- return this.get('servers');
- }
- set servers(s) {
- this.set('servers', s);
- }
- get paths() {
- return this.get('paths');
- }
- set paths(s) {
- this.set('paths', s);
- }
- get components() {
- return this.get('components');
- }
- set components(s) {
- this.set('components', s);
- }
- get security() {
- return this.get('security');
- }
- set security(s) {
- this.set('security', s);
- }
- get tags() {
- return this.get('tags');
- }
- set tags(s) {
- this.set('tags', s);
- }
- get externalDocs() {
- return this.get('externalDocs');
- }
- set externalDocs(s) {
- this.set('externalDocs', s);
- }
- get webhooks() {
- return this.get('webhooks');
- }
- set webhooks(s) {
- this.set('webhooks', s);
- }
- }
- const wb = OpenApi3_1;
- const Sb = class Operation_Operation extends jh {
- get requestBody() {
- return this.get('requestBody');
- }
- set requestBody(s) {
- this.set('requestBody', s);
- }
- };
- const Ob = class Parameter_Parameter extends Ih {
- get schema() {
- return this.get('schema');
- }
- set schema(s) {
- this.set('schema', s);
- }
- };
- const Ab = class PathItem_PathItem extends Ph {
- get GET() {
- return this.get('get');
- }
- set GET(s) {
- this.set('GET', s);
- }
- get PUT() {
- return this.get('put');
- }
- set PUT(s) {
- this.set('PUT', s);
- }
- get POST() {
- return this.get('post');
- }
- set POST(s) {
- this.set('POST', s);
- }
- get DELETE() {
- return this.get('delete');
- }
- set DELETE(s) {
- this.set('DELETE', s);
- }
- get OPTIONS() {
- return this.get('options');
- }
- set OPTIONS(s) {
- this.set('OPTIONS', s);
- }
- get HEAD() {
- return this.get('head');
- }
- set HEAD(s) {
- this.set('HEAD', s);
- }
- get PATCH() {
- return this.get('patch');
- }
- set PATCH(s) {
- this.set('PATCH', s);
- }
- get TRACE() {
- return this.get('trace');
- }
- set TRACE(s) {
- this.set('TRACE', s);
- }
- };
- const Ib = class Paths_Paths extends Rh {};
- class Reference_Reference extends Dh {}
- Object.defineProperty(Reference_Reference.prototype, 'description', {
- get() {
- return this.get('description');
- },
- set(s) {
- this.set('description', s);
- },
- enumerable: !0
- }),
- Object.defineProperty(Reference_Reference.prototype, 'summary', {
- get() {
- return this.get('summary');
- },
- set(s) {
- this.set('summary', s);
- },
- enumerable: !0
- });
- const Pb = Reference_Reference;
- const Mb = class RequestBody_RequestBody extends Lh {};
- const Rb = class elements_Response_Response extends Fh {};
- const Lb = class Responses_Responses extends Kh {};
- class elements_Schema_Schema extends Cu.Sh {
- constructor(s, o, i) {
- super(s, o, i), (this.element = 'schema');
- }
- get $schema() {
- return this.get('$schema');
- }
- set $schema(s) {
- this.set('$schema', s);
- }
- get $vocabulary() {
- return this.get('$vocabulary');
- }
- set $vocabulary(s) {
- this.set('$vocabulary', s);
- }
- get $id() {
- return this.get('$id');
- }
- set $id(s) {
- this.set('$id', s);
- }
- get $anchor() {
- return this.get('$anchor');
- }
- set $anchor(s) {
- this.set('$anchor', s);
- }
- get $dynamicAnchor() {
- return this.get('$dynamicAnchor');
- }
- set $dynamicAnchor(s) {
- this.set('$dynamicAnchor', s);
- }
- get $dynamicRef() {
- return this.get('$dynamicRef');
- }
- set $dynamicRef(s) {
- this.set('$dynamicRef', s);
- }
- get $ref() {
- return this.get('$ref');
- }
- set $ref(s) {
- this.set('$ref', s);
- }
- get $defs() {
- return this.get('$defs');
- }
- set $defs(s) {
- this.set('$defs', s);
- }
- get $comment() {
- return this.get('$comment');
- }
- set $comment(s) {
- this.set('$comment', s);
- }
- get allOf() {
- return this.get('allOf');
- }
- set allOf(s) {
- this.set('allOf', s);
- }
- get anyOf() {
- return this.get('anyOf');
- }
- set anyOf(s) {
- this.set('anyOf', s);
- }
- get oneOf() {
- return this.get('oneOf');
- }
- set oneOf(s) {
- this.set('oneOf', s);
- }
- get not() {
- return this.get('not');
- }
- set not(s) {
- this.set('not', s);
- }
- get if() {
- return this.get('if');
- }
- set if(s) {
- this.set('if', s);
- }
- get then() {
- return this.get('then');
- }
- set then(s) {
- this.set('then', s);
- }
- get else() {
- return this.get('else');
- }
- set else(s) {
- this.set('else', s);
- }
- get dependentSchemas() {
- return this.get('dependentSchemas');
- }
- set dependentSchemas(s) {
- this.set('dependentSchemas', s);
- }
- get prefixItems() {
- return this.get('prefixItems');
- }
- set prefixItems(s) {
- this.set('prefixItems', s);
- }
- get items() {
- return this.get('items');
- }
- set items(s) {
- this.set('items', s);
- }
- get containsProp() {
- return this.get('contains');
- }
- set containsProp(s) {
- this.set('contains', s);
- }
- get properties() {
- return this.get('properties');
- }
- set properties(s) {
- this.set('properties', s);
- }
- get patternProperties() {
- return this.get('patternProperties');
- }
- set patternProperties(s) {
- this.set('patternProperties', s);
- }
- get additionalProperties() {
- return this.get('additionalProperties');
- }
- set additionalProperties(s) {
- this.set('additionalProperties', s);
- }
- get propertyNames() {
- return this.get('propertyNames');
- }
- set propertyNames(s) {
- this.set('propertyNames', s);
- }
- get unevaluatedItems() {
- return this.get('unevaluatedItems');
- }
- set unevaluatedItems(s) {
- this.set('unevaluatedItems', s);
- }
- get unevaluatedProperties() {
- return this.get('unevaluatedProperties');
- }
- set unevaluatedProperties(s) {
- this.set('unevaluatedProperties', s);
- }
- get type() {
- return this.get('type');
- }
- set type(s) {
- this.set('type', s);
- }
- get enum() {
- return this.get('enum');
- }
- set enum(s) {
- this.set('enum', s);
- }
- get const() {
- return this.get('const');
- }
- set const(s) {
- this.set('const', s);
- }
- get multipleOf() {
- return this.get('multipleOf');
- }
- set multipleOf(s) {
- this.set('multipleOf', s);
- }
- get maximum() {
- return this.get('maximum');
- }
- set maximum(s) {
- this.set('maximum', s);
- }
- get exclusiveMaximum() {
- return this.get('exclusiveMaximum');
- }
- set exclusiveMaximum(s) {
- this.set('exclusiveMaximum', s);
- }
- get minimum() {
- return this.get('minimum');
- }
- set minimum(s) {
- this.set('minimum', s);
- }
- get exclusiveMinimum() {
- return this.get('exclusiveMinimum');
- }
- set exclusiveMinimum(s) {
- this.set('exclusiveMinimum', s);
- }
- get maxLength() {
- return this.get('maxLength');
- }
- set maxLength(s) {
- this.set('maxLength', s);
- }
- get minLength() {
- return this.get('minLength');
- }
- set minLength(s) {
- this.set('minLength', s);
- }
- get pattern() {
- return this.get('pattern');
- }
- set pattern(s) {
- this.set('pattern', s);
- }
- get maxItems() {
- return this.get('maxItems');
- }
- set maxItems(s) {
- this.set('maxItems', s);
- }
- get minItems() {
- return this.get('minItems');
- }
- set minItems(s) {
- this.set('minItems', s);
- }
- get uniqueItems() {
- return this.get('uniqueItems');
- }
- set uniqueItems(s) {
- this.set('uniqueItems', s);
- }
- get maxContains() {
- return this.get('maxContains');
- }
- set maxContains(s) {
- this.set('maxContains', s);
- }
- get minContains() {
- return this.get('minContains');
- }
- set minContains(s) {
- this.set('minContains', s);
- }
- get maxProperties() {
- return this.get('maxProperties');
- }
- set maxProperties(s) {
- this.set('maxProperties', s);
- }
- get minProperties() {
- return this.get('minProperties');
- }
- set minProperties(s) {
- this.set('minProperties', s);
- }
- get required() {
- return this.get('required');
- }
- set required(s) {
- this.set('required', s);
- }
- get dependentRequired() {
- return this.get('dependentRequired');
- }
- set dependentRequired(s) {
- this.set('dependentRequired', s);
- }
- get title() {
- return this.get('title');
- }
- set title(s) {
- this.set('title', s);
- }
- get description() {
- return this.get('description');
- }
- set description(s) {
- this.set('description', s);
- }
- get default() {
- return this.get('default');
- }
- set default(s) {
- this.set('default', s);
- }
- get deprecated() {
- return this.get('deprecated');
- }
- set deprecated(s) {
- this.set('deprecated', s);
- }
- get readOnly() {
- return this.get('readOnly');
- }
- set readOnly(s) {
- this.set('readOnly', s);
- }
- get writeOnly() {
- return this.get('writeOnly');
- }
- set writeOnly(s) {
- this.set('writeOnly', s);
- }
- get examples() {
- return this.get('examples');
- }
- set examples(s) {
- this.set('examples', s);
- }
- get format() {
- return this.get('format');
- }
- set format(s) {
- this.set('format', s);
- }
- get contentEncoding() {
- return this.get('contentEncoding');
- }
- set contentEncoding(s) {
- this.set('contentEncoding', s);
- }
- get contentMediaType() {
- return this.get('contentMediaType');
- }
- set contentMediaType(s) {
- this.set('contentMediaType', s);
- }
- get contentSchema() {
- return this.get('contentSchema');
- }
- set contentSchema(s) {
- this.set('contentSchema', s);
- }
- get discriminator() {
- return this.get('discriminator');
- }
- set discriminator(s) {
- this.set('discriminator', s);
- }
- get xml() {
- return this.get('xml');
- }
- set xml(s) {
- this.set('xml', s);
- }
- get externalDocs() {
- return this.get('externalDocs');
- }
- set externalDocs(s) {
- this.set('externalDocs', s);
- }
- get example() {
- return this.get('example');
- }
- set example(s) {
- this.set('example', s);
- }
- }
- const qb = elements_Schema_Schema;
- const zb = class SecurityRequirement_SecurityRequirement extends Hf {};
- const Qb = class SecurityScheme_SecurityScheme extends Jf {};
- const e_ = class Server_Server extends Gf {};
- const t_ = class ServerVariable_ServerVariable extends Xf {};
- const r_ = class Tag_Tag extends Qf {};
- const n_ = class Xml_Xml extends em {};
- class OpenApi3_1Visitor extends Mixin(im, rm) {
- constructor(s) {
- super(s),
- (this.element = new wb()),
- (this.specPath = Tl(['document', 'objects', 'OpenApi'])),
- (this.canSupportSpecificationExtensions = !0),
- (this.openApiSemanticElement = this.element);
- }
- ObjectElement(s) {
- return (this.openApiGenericElement = s), im.prototype.ObjectElement.call(this, s);
- }
- }
- const s_ = OpenApi3_1Visitor,
- {
- visitors: {
- document: {
- objects: {
- Info: { $visitor: o_ }
- }
- }
- }
- } = $v;
- const i_ = class info_InfoVisitor extends o_ {
- constructor(s) {
- super(s), (this.element = new Qv());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- Contact: { $visitor: a_ }
- }
- }
- }
- } = $v;
- const l_ = class contact_ContactVisitor extends a_ {
- constructor(s) {
- super(s), (this.element = new Hv());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- License: { $visitor: c_ }
- }
- }
- }
- } = $v;
- const u_ = class license_LicenseVisitor extends c_ {
- constructor(s) {
- super(s), (this.element = new tb());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- Link: { $visitor: p_ }
- }
- }
- }
- } = $v;
- const h_ = class link_LinkVisitor extends p_ {
- constructor(s) {
- super(s), (this.element = new nb());
- }
- };
- class JsonSchemaDialectVisitor extends Mixin(nm, rm) {
- StringElement(s) {
- const o = new eb(serializers_value(s));
- return this.copyMetaAndAttributes(s, o), (this.element = o), Ju;
- }
- }
- const d_ = JsonSchemaDialectVisitor,
- {
- visitors: {
- document: {
- objects: {
- Server: { $visitor: f_ }
- }
- }
- }
- } = $v;
- const m_ = class server_ServerVisitor extends f_ {
- constructor(s) {
- super(s), (this.element = new e_());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- ServerVariable: { $visitor: g_ }
- }
- }
- }
- } = $v;
- const y_ = class server_variable_ServerVariableVisitor extends g_ {
- constructor(s) {
- super(s), (this.element = new t_());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- MediaType: { $visitor: v_ }
- }
- }
- }
- } = $v;
- const b_ = class media_type_MediaTypeVisitor extends v_ {
- constructor(s) {
- super(s), (this.element = new pb());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- SecurityRequirement: { $visitor: E_ }
- }
- }
- }
- } = $v;
- const w_ = class security_requirement_SecurityRequirementVisitor extends E_ {
- constructor(s) {
- super(s), (this.element = new zb());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- Components: { $visitor: S_ }
- }
- }
- }
- } = $v;
- const x_ = class components_ComponentsVisitor extends S_ {
- constructor(s) {
- super(s), (this.element = new Kv());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- Tag: { $visitor: k_ }
- }
- }
- }
- } = $v;
- const C_ = class tag_TagVisitor extends k_ {
- constructor(s) {
- super(s), (this.element = new r_());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- Reference: { $visitor: O_ }
- }
- }
- }
- } = $v;
- const A_ = class reference_ReferenceVisitor extends O_ {
- constructor(s) {
- super(s), (this.element = new Pb());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- Parameter: { $visitor: j_ }
- }
- }
- }
- } = $v;
- const I_ = class parameter_ParameterVisitor extends j_ {
- constructor(s) {
- super(s), (this.element = new Ob());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- Header: { $visitor: P_ }
- }
- }
- }
- } = $v;
- const M_ = class header_HeaderVisitor extends P_ {
- constructor(s) {
- super(s), (this.element = new Zv());
- }
- },
- T_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Wv || (s(u) && o('callback', u) && i('object', u))
- ),
- N_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Kv || (s(u) && o('components', u) && i('object', u))
- ),
- R_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Hv || (s(u) && o('contact', u) && i('object', u))
- ),
- D_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Yv || (s(u) && o('example', u) && i('object', u))
- ),
- L_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Xv || (s(u) && o('externalDocumentation', u) && i('object', u))
- ),
- B_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Zv || (s(u) && o('header', u) && i('object', u))
- ),
- F_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Qv || (s(u) && o('info', u) && i('object', u))
- ),
- q_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof eb || (s(u) && o('jsonSchemaDialect', u) && i('string', u))
- ),
- $_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof tb || (s(u) && o('license', u) && i('object', u))
- ),
- V_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof nb || (s(u) && o('link', u) && i('object', u))
- ),
- U_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof _b || (s(u) && o('openapi', u) && i('string', u))
- ),
- z_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i, hasClass: u }) =>
- (_) =>
- _ instanceof wb || (s(_) && o('openApi3_1', _) && i('object', _) && u('api', _))
- ),
- W_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Sb || (s(u) && o('operation', u) && i('object', u))
- ),
- K_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Ob || (s(u) && o('parameter', u) && i('object', u))
- ),
- H_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Ab || (s(u) && o('pathItem', u) && i('object', u))
- ),
- isPathItemElementExternal = (s) => {
- if (!H_(s)) return !1;
- if (!Ru(s.$ref)) return !1;
- const o = serializers_value(s.$ref);
- return 'string' == typeof o && o.length > 0 && !o.startsWith('#');
- },
- J_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Ib || (s(u) && o('paths', u) && i('object', u))
- ),
- G_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Pb || (s(u) && o('reference', u) && i('object', u))
- ),
- isReferenceElementExternal = (s) => {
- if (!G_(s)) return !1;
- if (!Ru(s.$ref)) return !1;
- const o = serializers_value(s.$ref);
- return 'string' == typeof o && o.length > 0 && !o.startsWith('#');
- },
- Y_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Mb || (s(u) && o('requestBody', u) && i('object', u))
- ),
- X_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Rb || (s(u) && o('response', u) && i('object', u))
- ),
- Z_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Lb || (s(u) && o('responses', u) && i('object', u))
- ),
- Q_ = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof qb || (s(u) && o('schema', u) && i('object', u))
- ),
- predicates_isBooleanJsonSchemaElement = (s) =>
- Bu(s) && s.classes.includes('boolean-json-schema'),
- eE = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof zb || (s(u) && o('securityRequirement', u) && i('object', u))
- ),
- tE = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof Qb || (s(u) && o('securityScheme', u) && i('object', u))
- ),
- rE = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof e_ || (s(u) && o('server', u) && i('object', u))
- ),
- nE = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof t_ || (s(u) && o('serverVariable', u) && i('object', u))
- ),
- sE = helpers(
- ({ hasBasicElementProps: s, isElementType: o, primitiveEq: i }) =>
- (u) =>
- u instanceof pb || (s(u) && o('mediaType', u) && i('object', u))
- );
- const oE = class ParentSchemaAwareVisitor_ParentSchemaAwareVisitor {
- parent;
- constructor({ parent: s }) {
- this.parent = s;
- }
- };
- class open_api_3_1_schema_SchemaVisitor extends Mixin(im, oE, rm) {
- constructor(s) {
- super(s),
- (this.element = new qb()),
- (this.specPath = Tl(['document', 'objects', 'Schema'])),
- (this.canSupportSpecificationExtensions = !0),
- (this.jsonSchemaDefaultDialect = eb.default),
- this.passingOptionsNames.push('parent');
- }
- ObjectElement(s) {
- this.handle$schema(s), this.handle$id(s), (this.parent = this.element);
- const o = im.prototype.ObjectElement.call(this, s);
- return (
- Ru(this.element.$ref) &&
- (this.element.classes.push('reference-element'),
- this.element.setMetaProperty('referenced-element', 'schema')),
- o
- );
- }
- BooleanElement(s) {
- const o = super.enter(s);
- return this.element.classes.push('boolean-json-schema'), o;
- }
- getJsonSchemaDialect() {
- let s;
- return (
- (s =
- void 0 !== this.openApiSemanticElement &&
- q_(this.openApiSemanticElement.jsonSchemaDialect)
- ? serializers_value(this.openApiSemanticElement.jsonSchemaDialect)
- : void 0 !== this.openApiGenericElement &&
- Ru(this.openApiGenericElement.get('jsonSchemaDialect'))
- ? serializers_value(this.openApiGenericElement.get('jsonSchemaDialect'))
- : serializers_value(this.jsonSchemaDefaultDialect)),
- s
- );
- }
- handle$schema(s) {
- if (Rl(this.parent) && !Ru(s.get('$schema')))
- this.element.setMetaProperty('inherited$schema', this.getJsonSchemaDialect());
- else if (Q_(this.parent) && !Ru(s.get('$schema'))) {
- const s = Na(
- serializers_value(this.parent.meta.get('inherited$schema')),
- serializers_value(this.parent.$schema)
- );
- this.element.setMetaProperty('inherited$schema', s);
- }
- }
- handle$id(s) {
- const o =
- void 0 !== this.parent
- ? cloneDeep(this.parent.getMetaProperty('inherited$id', []))
- : new Cu.wE(),
- i = serializers_value(s.get('$id'));
- Vd(i) && o.push(i), this.element.setMetaProperty('inherited$id', o);
- }
- }
- const iE = open_api_3_1_schema_SchemaVisitor;
- const aE = class $vocabularyVisitor extends rm {
- ObjectElement(s) {
- const o = super.enter(s);
- return this.element.classes.push('json-schema-$vocabulary'), o;
- }
- };
- const lE = class $refVisitor extends rm {
- StringElement(s) {
- const o = super.enter(s);
- return this.element.classes.push('reference-value'), o;
- }
- };
- class $defsVisitor extends Mixin(vm, oE, rm) {
- constructor(s) {
- super(s),
- (this.element = new Cu.Sh()),
- this.element.classes.push('json-schema-$defs'),
- (this.specPath = Tl(['document', 'objects', 'Schema'])),
- this.passingOptionsNames.push('parent');
- }
- }
- const cE = $defsVisitor;
- class schema_AllOfVisitor_AllOfVisitor extends Mixin(nm, oE, rm) {
- constructor(s) {
- super(s),
- (this.element = new Cu.wE()),
- this.element.classes.push('json-schema-allOf'),
- this.passingOptionsNames.push('parent');
- }
- ArrayElement(s) {
- return (
- s.forEach((s) => {
- if (Fu(s)) {
- const o = this.toRefractedElement(['document', 'objects', 'Schema'], s);
- this.element.push(o);
- } else {
- const o = cloneDeep(s);
- this.element.push(o);
- }
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- }
- const uE = schema_AllOfVisitor_AllOfVisitor;
- class schema_AnyOfVisitor_AnyOfVisitor extends Mixin(nm, oE, rm) {
- constructor(s) {
- super(s),
- (this.element = new Cu.wE()),
- this.element.classes.push('json-schema-anyOf'),
- this.passingOptionsNames.push('parent');
- }
- ArrayElement(s) {
- return (
- s.forEach((s) => {
- if (Fu(s)) {
- const o = this.toRefractedElement(['document', 'objects', 'Schema'], s);
- this.element.push(o);
- } else {
- const o = cloneDeep(s);
- this.element.push(o);
- }
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- }
- const pE = schema_AnyOfVisitor_AnyOfVisitor;
- class schema_OneOfVisitor_OneOfVisitor extends Mixin(nm, oE, rm) {
- constructor(s) {
- super(s),
- (this.element = new Cu.wE()),
- this.element.classes.push('json-schema-oneOf'),
- this.passingOptionsNames.push('parent');
- }
- ArrayElement(s) {
- return (
- s.forEach((s) => {
- if (Fu(s)) {
- const o = this.toRefractedElement(['document', 'objects', 'Schema'], s);
- this.element.push(o);
- } else {
- const o = cloneDeep(s);
- this.element.push(o);
- }
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- }
- const hE = schema_OneOfVisitor_OneOfVisitor;
- class DependentSchemasVisitor extends Mixin(vm, oE, rm) {
- constructor(s) {
- super(s),
- (this.element = new Cu.Sh()),
- this.element.classes.push('json-schema-dependentSchemas'),
- (this.specPath = Tl(['document', 'objects', 'Schema'])),
- this.passingOptionsNames.push('parent');
- }
- }
- const dE = DependentSchemasVisitor;
- class PrefixItemsVisitor extends Mixin(nm, oE, rm) {
- constructor(s) {
- super(s),
- (this.element = new Cu.wE()),
- this.element.classes.push('json-schema-prefixItems'),
- this.passingOptionsNames.push('parent');
- }
- ArrayElement(s) {
- return (
- s.forEach((s) => {
- if (Fu(s)) {
- const o = this.toRefractedElement(['document', 'objects', 'Schema'], s);
- this.element.push(o);
- } else {
- const o = cloneDeep(s);
- this.element.push(o);
- }
- }),
- this.copyMetaAndAttributes(s, this.element),
- Ju
- );
- }
- }
- const fE = PrefixItemsVisitor;
- class schema_PropertiesVisitor_PropertiesVisitor extends Mixin(vm, oE, rm) {
- constructor(s) {
- super(s),
- (this.element = new Cu.Sh()),
- this.element.classes.push('json-schema-properties'),
- (this.specPath = Tl(['document', 'objects', 'Schema'])),
- this.passingOptionsNames.push('parent');
- }
- }
- const mE = schema_PropertiesVisitor_PropertiesVisitor;
- class PatternPropertiesVisitor_PatternPropertiesVisitor extends Mixin(vm, oE, rm) {
- constructor(s) {
- super(s),
- (this.element = new Cu.Sh()),
- this.element.classes.push('json-schema-patternProperties'),
- (this.specPath = Tl(['document', 'objects', 'Schema'])),
- this.passingOptionsNames.push('parent');
- }
- }
- const gE = PatternPropertiesVisitor_PatternPropertiesVisitor;
- const yE = class schema_TypeVisitor_TypeVisitor extends rm {
- StringElement(s) {
- const o = super.enter(s);
- return this.element.classes.push('json-schema-type'), o;
- }
- ArrayElement(s) {
- const o = super.enter(s);
- return this.element.classes.push('json-schema-type'), o;
- }
- };
- const vE = class EnumVisitor_EnumVisitor extends rm {
- ArrayElement(s) {
- const o = super.enter(s);
- return this.element.classes.push('json-schema-enum'), o;
- }
- };
- const bE = class DependentRequiredVisitor extends rm {
- ObjectElement(s) {
- const o = super.enter(s);
- return this.element.classes.push('json-schema-dependentRequired'), o;
- }
- };
- const _E = class schema_ExamplesVisitor_ExamplesVisitor extends rm {
- ArrayElement(s) {
- const o = super.enter(s);
- return this.element.classes.push('json-schema-examples'), o;
- }
- },
- {
- visitors: {
- document: {
- objects: {
- Discriminator: { $visitor: EE }
- }
- }
- }
- } = $v;
- const wE = class distriminator_DiscriminatorVisitor extends EE {
- constructor(s) {
- super(s), (this.element = new Jv()), (this.canSupportSpecificationExtensions = !0);
- }
- },
- {
- visitors: {
- document: {
- objects: {
- XML: { $visitor: SE }
- }
- }
- }
- } = $v;
- const xE = class xml_XmlVisitor extends SE {
- constructor(s) {
- super(s), (this.element = new n_());
- }
- };
- class SchemasVisitor_SchemasVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new xy()),
- (this.specPath = Tl(['document', 'objects', 'Schema']));
- }
- }
- const kE = SchemasVisitor_SchemasVisitor;
- class ComponentsPathItems extends Cu.Sh {
- static primaryClass = 'components-path-items';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(ComponentsPathItems.primaryClass);
- }
- }
- const CE = ComponentsPathItems;
- class PathItemsVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new CE()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'PathItem']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(G_).forEach((s) => {
- s.setMetaProperty('referenced-element', 'pathItem');
- }),
- o
- );
- }
- }
- const OE = PathItemsVisitor,
- {
- visitors: {
- document: {
- objects: {
- Example: { $visitor: AE }
- }
- }
- }
- } = $v;
- const jE = class example_ExampleVisitor extends AE {
- constructor(s) {
- super(s), (this.element = new Yv());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- ExternalDocumentation: { $visitor: IE }
- }
- }
- }
- } = $v;
- const PE = class external_documentation_ExternalDocumentationVisitor extends IE {
- constructor(s) {
- super(s), (this.element = new Xv());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- Encoding: { $visitor: ME }
- }
- }
- }
- } = $v;
- const TE = class open_api_3_1_encoding_EncodingVisitor extends ME {
- constructor(s) {
- super(s), (this.element = new Gv());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- Paths: { $visitor: NE }
- }
- }
- }
- } = $v;
- const RE = class paths_PathsVisitor extends NE {
- constructor(s) {
- super(s), (this.element = new Ib());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- RequestBody: { $visitor: DE }
- }
- }
- }
- } = $v;
- const LE = class request_body_RequestBodyVisitor extends DE {
- constructor(s) {
- super(s), (this.element = new Mb());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- Callback: { $visitor: BE }
- }
- }
- }
- } = $v;
- const FE = class callback_CallbackVisitor extends BE {
- constructor(s) {
- super(s),
- (this.element = new Wv()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'PathItem']);
- }
- ObjectElement(s) {
- const o = BE.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(G_).forEach((s) => {
- s.setMetaProperty('referenced-element', 'pathItem');
- }),
- o
- );
- }
- },
- {
- visitors: {
- document: {
- objects: {
- Response: { $visitor: qE }
- }
- }
- }
- } = $v;
- const $E = class response_ResponseVisitor extends qE {
- constructor(s) {
- super(s), (this.element = new Rb());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- Responses: { $visitor: VE }
- }
- }
- }
- } = $v;
- const UE = class open_api_3_1_responses_ResponsesVisitor extends VE {
- constructor(s) {
- super(s), (this.element = new Lb());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- Operation: { $visitor: zE }
- }
- }
- }
- } = $v;
- const WE = class operation_OperationVisitor extends zE {
- constructor(s) {
- super(s), (this.element = new Sb());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- PathItem: { $visitor: KE }
- }
- }
- }
- } = $v;
- const HE = class path_item_PathItemVisitor extends KE {
- constructor(s) {
- super(s), (this.element = new Ab());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- SecurityScheme: { $visitor: JE }
- }
- }
- }
- } = $v;
- const GE = class security_scheme_SecuritySchemeVisitor extends JE {
- constructor(s) {
- super(s), (this.element = new Qb());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- OAuthFlows: { $visitor: YE }
- }
- }
- }
- } = $v;
- const XE = class oauth_flows_OAuthFlowsVisitor extends YE {
- constructor(s) {
- super(s), (this.element = new yb());
- }
- },
- {
- visitors: {
- document: {
- objects: {
- OAuthFlow: { $visitor: ZE }
- }
- }
- }
- } = $v;
- const QE = class oauth_flow_OAuthFlowVisitor extends ZE {
- constructor(s) {
- super(s), (this.element = new mb());
- }
- };
- class Webhooks extends Cu.Sh {
- static primaryClass = 'webhooks';
- constructor(s, o, i) {
- super(s, o, i), this.classes.push(Webhooks.primaryClass);
- }
- }
- const ew = Webhooks;
- class WebhooksVisitor extends Mixin(vm, rm) {
- constructor(s) {
- super(s),
- (this.element = new ew()),
- (this.specPath = (s) =>
- isReferenceLikeElement(s)
- ? ['document', 'objects', 'Reference']
- : ['document', 'objects', 'PathItem']);
- }
- ObjectElement(s) {
- const o = vm.prototype.ObjectElement.call(this, s);
- return (
- this.element.filter(G_).forEach((s) => {
- s.setMetaProperty('referenced-element', 'pathItem');
- }),
- this.element.filter(H_).forEach((s, o) => {
- s.setMetaProperty('webhook-name', serializers_value(o));
- }),
- o
- );
- }
- }
- const tw = WebhooksVisitor,
- rw = {
- visitors: {
- value: $v.visitors.value,
- document: {
- objects: {
- OpenApi: {
- $visitor: s_,
- fixedFields: {
- openapi: $v.visitors.document.objects.OpenApi.fixedFields.openapi,
- info: { $ref: '#/visitors/document/objects/Info' },
- jsonSchemaDialect: d_,
- servers: $v.visitors.document.objects.OpenApi.fixedFields.servers,
- paths: { $ref: '#/visitors/document/objects/Paths' },
- webhooks: tw,
- components: { $ref: '#/visitors/document/objects/Components' },
- security: $v.visitors.document.objects.OpenApi.fixedFields.security,
- tags: $v.visitors.document.objects.OpenApi.fixedFields.tags,
- externalDocs: { $ref: '#/visitors/document/objects/ExternalDocumentation' }
- }
- },
- Info: {
- $visitor: i_,
- fixedFields: {
- title: $v.visitors.document.objects.Info.fixedFields.title,
- description: $v.visitors.document.objects.Info.fixedFields.description,
- summary: { $ref: '#/visitors/value' },
- termsOfService: $v.visitors.document.objects.Info.fixedFields.termsOfService,
- contact: { $ref: '#/visitors/document/objects/Contact' },
- license: { $ref: '#/visitors/document/objects/License' },
- version: $v.visitors.document.objects.Info.fixedFields.version
- }
- },
- Contact: {
- $visitor: l_,
- fixedFields: {
- name: $v.visitors.document.objects.Contact.fixedFields.name,
- url: $v.visitors.document.objects.Contact.fixedFields.url,
- email: $v.visitors.document.objects.Contact.fixedFields.email
- }
- },
- License: {
- $visitor: u_,
- fixedFields: {
- name: $v.visitors.document.objects.License.fixedFields.name,
- identifier: { $ref: '#/visitors/value' },
- url: $v.visitors.document.objects.License.fixedFields.url
- }
- },
- Server: {
- $visitor: m_,
- fixedFields: {
- url: $v.visitors.document.objects.Server.fixedFields.url,
- description: $v.visitors.document.objects.Server.fixedFields.description,
- variables: $v.visitors.document.objects.Server.fixedFields.variables
- }
- },
- ServerVariable: {
- $visitor: y_,
- fixedFields: {
- enum: $v.visitors.document.objects.ServerVariable.fixedFields.enum,
- default: $v.visitors.document.objects.ServerVariable.fixedFields.default,
- description:
- $v.visitors.document.objects.ServerVariable.fixedFields.description
- }
- },
- Components: {
- $visitor: x_,
- fixedFields: {
- schemas: kE,
- responses: $v.visitors.document.objects.Components.fixedFields.responses,
- parameters: $v.visitors.document.objects.Components.fixedFields.parameters,
- examples: $v.visitors.document.objects.Components.fixedFields.examples,
- requestBodies:
- $v.visitors.document.objects.Components.fixedFields.requestBodies,
- headers: $v.visitors.document.objects.Components.fixedFields.headers,
- securitySchemes:
- $v.visitors.document.objects.Components.fixedFields.securitySchemes,
- links: $v.visitors.document.objects.Components.fixedFields.links,
- callbacks: $v.visitors.document.objects.Components.fixedFields.callbacks,
- pathItems: OE
- }
- },
- Paths: { $visitor: RE },
- PathItem: {
- $visitor: HE,
- fixedFields: {
- $ref: $v.visitors.document.objects.PathItem.fixedFields.$ref,
- summary: $v.visitors.document.objects.PathItem.fixedFields.summary,
- description: $v.visitors.document.objects.PathItem.fixedFields.description,
- get: { $ref: '#/visitors/document/objects/Operation' },
- put: { $ref: '#/visitors/document/objects/Operation' },
- post: { $ref: '#/visitors/document/objects/Operation' },
- delete: { $ref: '#/visitors/document/objects/Operation' },
- options: { $ref: '#/visitors/document/objects/Operation' },
- head: { $ref: '#/visitors/document/objects/Operation' },
- patch: { $ref: '#/visitors/document/objects/Operation' },
- trace: { $ref: '#/visitors/document/objects/Operation' },
- servers: $v.visitors.document.objects.PathItem.fixedFields.servers,
- parameters: $v.visitors.document.objects.PathItem.fixedFields.parameters
- }
- },
- Operation: {
- $visitor: WE,
- fixedFields: {
- tags: $v.visitors.document.objects.Operation.fixedFields.tags,
- summary: $v.visitors.document.objects.Operation.fixedFields.summary,
- description: $v.visitors.document.objects.Operation.fixedFields.description,
- externalDocs: { $ref: '#/visitors/document/objects/ExternalDocumentation' },
- operationId: $v.visitors.document.objects.Operation.fixedFields.operationId,
- parameters: $v.visitors.document.objects.Operation.fixedFields.parameters,
- requestBody: $v.visitors.document.objects.Operation.fixedFields.requestBody,
- responses: { $ref: '#/visitors/document/objects/Responses' },
- callbacks: $v.visitors.document.objects.Operation.fixedFields.callbacks,
- deprecated: $v.visitors.document.objects.Operation.fixedFields.deprecated,
- security: $v.visitors.document.objects.Operation.fixedFields.security,
- servers: $v.visitors.document.objects.Operation.fixedFields.servers
- }
- },
- ExternalDocumentation: {
- $visitor: PE,
- fixedFields: {
- description:
- $v.visitors.document.objects.ExternalDocumentation.fixedFields.description,
- url: $v.visitors.document.objects.ExternalDocumentation.fixedFields.url
- }
- },
- Parameter: {
- $visitor: I_,
- fixedFields: {
- name: $v.visitors.document.objects.Parameter.fixedFields.name,
- in: $v.visitors.document.objects.Parameter.fixedFields.in,
- description: $v.visitors.document.objects.Parameter.fixedFields.description,
- required: $v.visitors.document.objects.Parameter.fixedFields.required,
- deprecated: $v.visitors.document.objects.Parameter.fixedFields.deprecated,
- allowEmptyValue:
- $v.visitors.document.objects.Parameter.fixedFields.allowEmptyValue,
- style: $v.visitors.document.objects.Parameter.fixedFields.style,
- explode: $v.visitors.document.objects.Parameter.fixedFields.explode,
- allowReserved:
- $v.visitors.document.objects.Parameter.fixedFields.allowReserved,
- schema: { $ref: '#/visitors/document/objects/Schema' },
- example: $v.visitors.document.objects.Parameter.fixedFields.example,
- examples: $v.visitors.document.objects.Parameter.fixedFields.examples,
- content: $v.visitors.document.objects.Parameter.fixedFields.content
- }
- },
- RequestBody: {
- $visitor: LE,
- fixedFields: {
- description: $v.visitors.document.objects.RequestBody.fixedFields.description,
- content: $v.visitors.document.objects.RequestBody.fixedFields.content,
- required: $v.visitors.document.objects.RequestBody.fixedFields.required
- }
- },
- MediaType: {
- $visitor: b_,
- fixedFields: {
- schema: { $ref: '#/visitors/document/objects/Schema' },
- example: $v.visitors.document.objects.MediaType.fixedFields.example,
- examples: $v.visitors.document.objects.MediaType.fixedFields.examples,
- encoding: $v.visitors.document.objects.MediaType.fixedFields.encoding
- }
- },
- Encoding: {
- $visitor: TE,
- fixedFields: {
- contentType: $v.visitors.document.objects.Encoding.fixedFields.contentType,
- headers: $v.visitors.document.objects.Encoding.fixedFields.headers,
- style: $v.visitors.document.objects.Encoding.fixedFields.style,
- explode: $v.visitors.document.objects.Encoding.fixedFields.explode,
- allowReserved: $v.visitors.document.objects.Encoding.fixedFields.allowReserved
- }
- },
- Responses: {
- $visitor: UE,
- fixedFields: {
- default: $v.visitors.document.objects.Responses.fixedFields.default
- }
- },
- Response: {
- $visitor: $E,
- fixedFields: {
- description: $v.visitors.document.objects.Response.fixedFields.description,
- headers: $v.visitors.document.objects.Response.fixedFields.headers,
- content: $v.visitors.document.objects.Response.fixedFields.content,
- links: $v.visitors.document.objects.Response.fixedFields.links
- }
- },
- Callback: { $visitor: FE },
- Example: {
- $visitor: jE,
- fixedFields: {
- summary: $v.visitors.document.objects.Example.fixedFields.summary,
- description: $v.visitors.document.objects.Example.fixedFields.description,
- value: $v.visitors.document.objects.Example.fixedFields.value,
- externalValue: $v.visitors.document.objects.Example.fixedFields.externalValue
- }
- },
- Link: {
- $visitor: h_,
- fixedFields: {
- operationRef: $v.visitors.document.objects.Link.fixedFields.operationRef,
- operationId: $v.visitors.document.objects.Link.fixedFields.operationId,
- parameters: $v.visitors.document.objects.Link.fixedFields.parameters,
- requestBody: $v.visitors.document.objects.Link.fixedFields.requestBody,
- description: $v.visitors.document.objects.Link.fixedFields.description,
- server: { $ref: '#/visitors/document/objects/Server' }
- }
- },
- Header: {
- $visitor: M_,
- fixedFields: {
- description: $v.visitors.document.objects.Header.fixedFields.description,
- required: $v.visitors.document.objects.Header.fixedFields.required,
- deprecated: $v.visitors.document.objects.Header.fixedFields.deprecated,
- allowEmptyValue:
- $v.visitors.document.objects.Header.fixedFields.allowEmptyValue,
- style: $v.visitors.document.objects.Header.fixedFields.style,
- explode: $v.visitors.document.objects.Header.fixedFields.explode,
- allowReserved: $v.visitors.document.objects.Header.fixedFields.allowReserved,
- schema: { $ref: '#/visitors/document/objects/Schema' },
- example: $v.visitors.document.objects.Header.fixedFields.example,
- examples: $v.visitors.document.objects.Header.fixedFields.examples,
- content: $v.visitors.document.objects.Header.fixedFields.content
- }
- },
- Tag: {
- $visitor: C_,
- fixedFields: {
- name: $v.visitors.document.objects.Tag.fixedFields.name,
- description: $v.visitors.document.objects.Tag.fixedFields.description,
- externalDocs: { $ref: '#/visitors/document/objects/ExternalDocumentation' }
- }
- },
- Reference: {
- $visitor: A_,
- fixedFields: {
- $ref: $v.visitors.document.objects.Reference.fixedFields.$ref,
- summary: { $ref: '#/visitors/value' },
- description: { $ref: '#/visitors/value' }
- }
- },
- Schema: {
- $visitor: iE,
- fixedFields: {
- $schema: { $ref: '#/visitors/value' },
- $vocabulary: aE,
- $id: { $ref: '#/visitors/value' },
- $anchor: { $ref: '#/visitors/value' },
- $dynamicAnchor: { $ref: '#/visitors/value' },
- $dynamicRef: { $ref: '#/visitors/value' },
- $ref: lE,
- $defs: cE,
- $comment: { $ref: '#/visitors/value' },
- allOf: uE,
- anyOf: pE,
- oneOf: hE,
- not: { $ref: '#/visitors/document/objects/Schema' },
- if: { $ref: '#/visitors/document/objects/Schema' },
- then: { $ref: '#/visitors/document/objects/Schema' },
- else: { $ref: '#/visitors/document/objects/Schema' },
- dependentSchemas: dE,
- prefixItems: fE,
- items: { $ref: '#/visitors/document/objects/Schema' },
- contains: { $ref: '#/visitors/document/objects/Schema' },
- properties: mE,
- patternProperties: gE,
- additionalProperties: { $ref: '#/visitors/document/objects/Schema' },
- propertyNames: { $ref: '#/visitors/document/objects/Schema' },
- unevaluatedItems: { $ref: '#/visitors/document/objects/Schema' },
- unevaluatedProperties: { $ref: '#/visitors/document/objects/Schema' },
- type: yE,
- enum: vE,
- const: { $ref: '#/visitors/value' },
- multipleOf: { $ref: '#/visitors/value' },
- maximum: { $ref: '#/visitors/value' },
- exclusiveMaximum: { $ref: '#/visitors/value' },
- minimum: { $ref: '#/visitors/value' },
- exclusiveMinimum: { $ref: '#/visitors/value' },
- maxLength: { $ref: '#/visitors/value' },
- minLength: { $ref: '#/visitors/value' },
- pattern: { $ref: '#/visitors/value' },
- maxItems: { $ref: '#/visitors/value' },
- minItems: { $ref: '#/visitors/value' },
- uniqueItems: { $ref: '#/visitors/value' },
- maxContains: { $ref: '#/visitors/value' },
- minContains: { $ref: '#/visitors/value' },
- maxProperties: { $ref: '#/visitors/value' },
- minProperties: { $ref: '#/visitors/value' },
- required: { $ref: '#/visitors/value' },
- dependentRequired: bE,
- title: { $ref: '#/visitors/value' },
- description: { $ref: '#/visitors/value' },
- default: { $ref: '#/visitors/value' },
- deprecated: { $ref: '#/visitors/value' },
- readOnly: { $ref: '#/visitors/value' },
- writeOnly: { $ref: '#/visitors/value' },
- examples: _E,
- format: { $ref: '#/visitors/value' },
- contentEncoding: { $ref: '#/visitors/value' },
- contentMediaType: { $ref: '#/visitors/value' },
- contentSchema: { $ref: '#/visitors/document/objects/Schema' },
- discriminator: { $ref: '#/visitors/document/objects/Discriminator' },
- xml: { $ref: '#/visitors/document/objects/XML' },
- externalDocs: { $ref: '#/visitors/document/objects/ExternalDocumentation' },
- example: { $ref: '#/visitors/value' }
- }
- },
- Discriminator: {
- $visitor: wE,
- fixedFields: {
- propertyName:
- $v.visitors.document.objects.Discriminator.fixedFields.propertyName,
- mapping: $v.visitors.document.objects.Discriminator.fixedFields.mapping
- }
- },
- XML: {
- $visitor: xE,
- fixedFields: {
- name: $v.visitors.document.objects.XML.fixedFields.name,
- namespace: $v.visitors.document.objects.XML.fixedFields.namespace,
- prefix: $v.visitors.document.objects.XML.fixedFields.prefix,
- attribute: $v.visitors.document.objects.XML.fixedFields.attribute,
- wrapped: $v.visitors.document.objects.XML.fixedFields.wrapped
- }
- },
- SecurityScheme: {
- $visitor: GE,
- fixedFields: {
- type: $v.visitors.document.objects.SecurityScheme.fixedFields.type,
- description:
- $v.visitors.document.objects.SecurityScheme.fixedFields.description,
- name: $v.visitors.document.objects.SecurityScheme.fixedFields.name,
- in: $v.visitors.document.objects.SecurityScheme.fixedFields.in,
- scheme: $v.visitors.document.objects.SecurityScheme.fixedFields.scheme,
- bearerFormat:
- $v.visitors.document.objects.SecurityScheme.fixedFields.bearerFormat,
- flows: { $ref: '#/visitors/document/objects/OAuthFlows' },
- openIdConnectUrl:
- $v.visitors.document.objects.SecurityScheme.fixedFields.openIdConnectUrl
- }
- },
- OAuthFlows: {
- $visitor: XE,
- fixedFields: {
- implicit: { $ref: '#/visitors/document/objects/OAuthFlow' },
- password: { $ref: '#/visitors/document/objects/OAuthFlow' },
- clientCredentials: { $ref: '#/visitors/document/objects/OAuthFlow' },
- authorizationCode: { $ref: '#/visitors/document/objects/OAuthFlow' }
- }
- },
- OAuthFlow: {
- $visitor: QE,
- fixedFields: {
- authorizationUrl:
- $v.visitors.document.objects.OAuthFlow.fixedFields.authorizationUrl,
- tokenUrl: $v.visitors.document.objects.OAuthFlow.fixedFields.tokenUrl,
- refreshUrl: $v.visitors.document.objects.OAuthFlow.fixedFields.refreshUrl,
- scopes: $v.visitors.document.objects.OAuthFlow.fixedFields.scopes
- }
- },
- SecurityRequirement: { $visitor: w_ }
- },
- extension: { $visitor: $v.visitors.document.extension.$visitor }
- }
- }
- },
- apidom_ns_openapi_3_1_es_traversal_visitor_getNodeType = (s) => {
- if (Nu(s)) return `${s.element.charAt(0).toUpperCase() + s.element.slice(1)}Element`;
- },
- nw = {
- CallbackElement: ['content'],
- ComponentsElement: ['content'],
- ContactElement: ['content'],
- DiscriminatorElement: ['content'],
- Encoding: ['content'],
- Example: ['content'],
- ExternalDocumentationElement: ['content'],
- HeaderElement: ['content'],
- InfoElement: ['content'],
- LicenseElement: ['content'],
- MediaTypeElement: ['content'],
- OAuthFlowElement: ['content'],
- OAuthFlowsElement: ['content'],
- OpenApi3_1Element: ['content'],
- OperationElement: ['content'],
- ParameterElement: ['content'],
- PathItemElement: ['content'],
- PathsElement: ['content'],
- ReferenceElement: ['content'],
- RequestBodyElement: ['content'],
- ResponseElement: ['content'],
- ResponsesElement: ['content'],
- SchemaElement: ['content'],
- SecurityRequirementElement: ['content'],
- SecuritySchemeElement: ['content'],
- ServerElement: ['content'],
- ServerVariableElement: ['content'],
- TagElement: ['content'],
- ...Qu
- },
- sw = {
- namespace: (s) => {
- const { base: o } = s;
- return (
- o.register('callback', Wv),
- o.register('components', Kv),
- o.register('contact', Hv),
- o.register('discriminator', Jv),
- o.register('encoding', Gv),
- o.register('example', Yv),
- o.register('externalDocumentation', Xv),
- o.register('header', Zv),
- o.register('info', Qv),
- o.register('jsonSchemaDialect', eb),
- o.register('license', tb),
- o.register('link', nb),
- o.register('mediaType', pb),
- o.register('oAuthFlow', mb),
- o.register('oAuthFlows', yb),
- o.register('openapi', _b),
- o.register('openApi3_1', wb),
- o.register('operation', Sb),
- o.register('parameter', Ob),
- o.register('pathItem', Ab),
- o.register('paths', Ib),
- o.register('reference', Pb),
- o.register('requestBody', Mb),
- o.register('response', Rb),
- o.register('responses', Lb),
- o.register('schema', qb),
- o.register('securityRequirement', zb),
- o.register('securityScheme', Qb),
- o.register('server', e_),
- o.register('serverVariable', t_),
- o.register('tag', r_),
- o.register('xml', n_),
- o
- );
- }
- },
- ow = sw,
- ancestorLineageToJSONPointer = (s) => {
- const o = s.reduce((o, i, u) => {
- if ($u(i)) {
- const s = String(serializers_value(i.key));
- o.push(s);
- } else if (qu(s[u - 2])) {
- const _ = String(s[u - 2].content.indexOf(i));
- o.push(_);
- }
- return o;
- }, []);
- return es_compile(o);
- },
- apidom_ns_openapi_3_1_es_refractor_toolbox = () => {
- const s = createNamespace(ow);
- return {
- predicates: {
- ...de,
- isElement: Nu,
- isStringElement: Ru,
- isArrayElement: qu,
- isObjectElement: Fu,
- isMemberElement: $u,
- isServersElement: rg,
- includesClasses,
- hasElementSourceMap
- },
- ancestorLineageToJSONPointer,
- namespace: s
- };
- },
- apidom_ns_openapi_3_1_es_refractor_refract = (
- s,
- {
- specPath: o = ['visitors', 'document', 'objects', 'OpenApi', '$visitor'],
- plugins: i = []
- } = {}
- ) => {
- const u = (0, Cu.e)(s),
- _ = dereference(rw),
- w = new (cp(o, _))({ specObj: _ });
- return (
- visitor_visit(u, w),
- dispatchPluginsSync(w.element, i, {
- toolboxCreator: apidom_ns_openapi_3_1_es_refractor_toolbox,
- visitorOptions: {
- keyMap: nw,
- nodeTypeGetter: apidom_ns_openapi_3_1_es_traversal_visitor_getNodeType
- }
- })
- );
- },
- apidom_ns_openapi_3_1_es_refractor_createRefractor =
- (s) =>
- (o, i = {}) =>
- apidom_ns_openapi_3_1_es_refractor_refract(o, { specPath: s, ...i });
- (Wv.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Callback',
- '$visitor'
- ])),
- (Kv.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Components',
- '$visitor'
- ])),
- (Hv.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Contact',
- '$visitor'
- ])),
- (Yv.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Example',
- '$visitor'
- ])),
- (Jv.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Discriminator',
- '$visitor'
- ])),
- (Gv.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Encoding',
- '$visitor'
- ])),
- (Xv.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'ExternalDocumentation',
- '$visitor'
- ])),
- (Zv.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Header',
- '$visitor'
- ])),
- (Qv.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Info',
- '$visitor'
- ])),
- (eb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'OpenApi',
- 'fixedFields',
- 'jsonSchemaDialect'
- ])),
- (tb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'License',
- '$visitor'
- ])),
- (nb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Link',
- '$visitor'
- ])),
- (pb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'MediaType',
- '$visitor'
- ])),
- (mb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'OAuthFlow',
- '$visitor'
- ])),
- (yb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'OAuthFlows',
- '$visitor'
- ])),
- (_b.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'OpenApi',
- 'fixedFields',
- 'openapi'
- ])),
- (wb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'OpenApi',
- '$visitor'
- ])),
- (Sb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Operation',
- '$visitor'
- ])),
- (Ob.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Parameter',
- '$visitor'
- ])),
- (Ab.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'PathItem',
- '$visitor'
- ])),
- (Ib.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Paths',
- '$visitor'
- ])),
- (Pb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Reference',
- '$visitor'
- ])),
- (Mb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'RequestBody',
- '$visitor'
- ])),
- (Rb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Response',
- '$visitor'
- ])),
- (Lb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Responses',
- '$visitor'
- ])),
- (qb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Schema',
- '$visitor'
- ])),
- (zb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'SecurityRequirement',
- '$visitor'
- ])),
- (Qb.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'SecurityScheme',
- '$visitor'
- ])),
- (e_.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Server',
- '$visitor'
- ])),
- (t_.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'ServerVariable',
- '$visitor'
- ])),
- (r_.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'Tag',
- '$visitor'
- ])),
- (n_.refract = apidom_ns_openapi_3_1_es_refractor_createRefractor([
- 'visitors',
- 'document',
- 'objects',
- 'XML',
- '$visitor'
- ]));
- const iw = class NotImplementedError extends Hh {};
- const aw = class MediaTypes extends Array {
- unknownMediaType = 'application/octet-stream';
- filterByFormat() {
- throw new iw('filterByFormat method in MediaTypes class is not yet implemented.');
- }
- findBy() {
- throw new iw('findBy method in MediaTypes class is not yet implemented.');
- }
- latest() {
- throw new iw('latest method in MediaTypes class is not yet implemented.');
- }
- };
- class OpenAPIMediaTypes extends aw {
- filterByFormat(s = 'generic') {
- const o = 'generic' === s ? 'openapi;version' : s;
- return this.filter((s) => s.includes(o));
- }
- findBy(s = '3.1.0', o = 'generic') {
- const i =
- 'generic' === o
- ? `vnd.oai.openapi;version=${s}`
- : `vnd.oai.openapi+${o};version=${s}`;
- return this.find((s) => s.includes(i)) || this.unknownMediaType;
- }
- latest(s = 'generic') {
- return Fa(this.filterByFormat(s));
- }
- }
- const lw = new OpenAPIMediaTypes(
- 'application/vnd.oai.openapi;version=3.1.0',
- 'application/vnd.oai.openapi+json;version=3.1.0',
- 'application/vnd.oai.openapi+yaml;version=3.1.0'
- );
- const cw = class es_Reference_Reference {
- uri;
- depth;
- value;
- refSet;
- errors;
- constructor({ uri: s, depth: o = 0, refSet: i, value: u }) {
- (this.uri = s),
- (this.value = u),
- (this.depth = o),
- (this.refSet = i),
- (this.errors = []);
- }
- };
- const uw = class ReferenceSet {
- rootRef;
- refs;
- circular;
- constructor({ refs: s = [], circular: o = !1 } = {}) {
- (this.refs = []), (this.circular = o), s.forEach(this.add.bind(this));
- }
- get size() {
- return this.refs.length;
- }
- add(s) {
- return (
- this.has(s) ||
- (this.refs.push(s),
- (this.rootRef = void 0 === this.rootRef ? s : this.rootRef),
- (s.refSet = this)),
- this
- );
- }
- merge(s) {
- for (const o of s.values()) this.add(o);
- return this;
- }
- has(s) {
- const o = Yl(s) ? s : s.uri;
- return Dl(this.find((s) => s.uri === o));
- }
- find(s) {
- return this.refs.find(s);
- }
- *values() {
- yield* this.refs;
- }
- clean() {
- this.refs.forEach((s) => {
- s.refSet = void 0;
- }),
- (this.rootRef = void 0),
- (this.refs.length = 0);
- }
- },
- pw = {
- parse: { mediaType: 'text/plain', parsers: [], parserOpts: {} },
- resolve: {
- baseURI: '',
- resolvers: [],
- resolverOpts: {},
- strategies: [],
- strategyOpts: {},
- internal: !0,
- external: !0,
- maxDepth: 1 / 0
- },
- dereference: {
- strategies: [],
- strategyOpts: {},
- refSet: null,
- maxDepth: 1 / 0,
- circular: 'ignore',
- circularReplacer: Ip,
- immutable: !0
- },
- bundle: { strategies: [], refSet: null, maxDepth: 1 / 0 }
- };
- const hw = _curry2(function lens(s, o) {
- return function (i) {
- return function (u) {
- return kl(
- function (s) {
- return o(s, u);
- },
- i(s(u))
- );
- };
- };
- });
- var dw = _curry3(function assocPath(s, o, i) {
- if (0 === s.length) return o;
- var u = s[0];
- if (s.length > 1) {
- var _ = !ld(i) && _has(u, i) && 'object' == typeof i[u] ? i[u] : Yo(s[1]) ? [] : {};
- o = assocPath(Array.prototype.slice.call(s, 1), o, _);
- }
- return (function _assoc(s, o, i) {
- if (Yo(s) && aa(i)) {
- var u = [].concat(i);
- return (u[s] = o), u;
- }
- var _ = {};
- for (var w in i) _[w] = i[w];
- return (_[s] = o), _;
- })(u, o, i);
- });
- const fw = dw;
- var Identity = function (s) {
- return {
- value: s,
- map: function (o) {
- return Identity(o(s));
- }
- };
- },
- mw = _curry3(function over(s, o, i) {
- return s(function (s) {
- return Identity(o(s));
- })(i).value;
- });
- const gw = mw,
- yw = hw(cp(['resolve', 'baseURI']), fw(['resolve', 'baseURI'])),
- baseURIDefault = (s) => (qp(s) ? url_cwd() : s),
- util_merge = (s, o) => {
- const i = lp(s, o);
- return gw(yw, baseURIDefault, i);
- };
- const vw = class File_File {
- uri;
- mediaType;
- data;
- parseResult;
- constructor({ uri: s, mediaType: o = 'text/plain', data: i, parseResult: u }) {
- (this.uri = s), (this.mediaType = o), (this.data = i), (this.parseResult = u);
- }
- get extension() {
- return Yl(this.uri)
- ? ((s) => {
- const o = s.lastIndexOf('.');
- return o >= 0 ? s.substring(o).toLowerCase() : '';
- })(this.uri)
- : '';
- }
- toString() {
- if ('string' == typeof this.data) return this.data;
- if (
- this.data instanceof ArrayBuffer ||
- ['ArrayBuffer'].includes(ea(this.data)) ||
- ArrayBuffer.isView(this.data)
- ) {
- return new TextDecoder('utf-8').decode(this.data);
- }
- return String(this.data);
- }
- };
- const bw = class PluginError extends Ho {
- plugin;
- constructor(s, o) {
- super(s, { cause: o.cause }), (this.plugin = o.plugin);
- }
- },
- plugins_filter = async (s, o, i) => {
- const u = await Promise.all(i.map(_p([s], o)));
- return i.filter((s, o) => u[o]);
- },
- run = async (s, o, i) => {
- let u;
- for (const _ of i)
- try {
- const i = await _[s].call(_, ...o);
- return { plugin: _, result: i };
- } catch (s) {
- u = new bw('Error while running plugin', { cause: s, plugin: _ });
- }
- return Promise.reject(u);
- };
- const _w = class DereferenceError extends Ho {};
- const Ew = class UnmatchedDereferenceStrategyError extends _w {},
- dereferenceApiDOM = async (s, o) => {
- let i = s,
- u = !1;
- if (!Ku(s)) {
- const o = cloneShallow(s);
- o.classes.push('result'), (i = new Mu([o])), (u = !0);
- }
- const _ = new vw({
- uri: o.resolve.baseURI,
- parseResult: i,
- mediaType: o.parse.mediaType
- }),
- w = await plugins_filter('canDereference', [_, o], o.dereference.strategies);
- if (gp(w)) throw new Ew(_.uri);
- try {
- const { result: s } = await run('dereference', [_, o], w);
- return u ? s.get(0) : s;
- } catch (s) {
- throw new _w(`Error while dereferencing file "${_.uri}"`, { cause: s });
- }
- };
- const ww = class ParseError extends Ho {};
- const Sw = class ParserError extends ww {};
- const xw = class Parser {
- name;
- allowEmpty;
- sourceMap;
- fileExtensions;
- mediaTypes;
- constructor({
- name: s,
- allowEmpty: o = !0,
- sourceMap: i = !1,
- fileExtensions: u = [],
- mediaTypes: _ = []
- }) {
- (this.name = s),
- (this.allowEmpty = o),
- (this.sourceMap = i),
- (this.fileExtensions = u),
- (this.mediaTypes = _);
- }
- };
- const kw = class BinaryParser extends xw {
- constructor(s) {
- super({ ...(null != s ? s : {}), name: 'binary' });
- }
- canParse(s) {
- return 0 === this.fileExtensions.length || this.fileExtensions.includes(s.extension);
- }
- parse(s) {
- try {
- const o = unescape(encodeURIComponent(s.toString())),
- i = btoa(o),
- u = new Mu();
- if (0 !== i.length) {
- const s = new Cu.Om(i);
- s.classes.push('result'), u.push(s);
- }
- return u;
- } catch (o) {
- throw new Sw(`Error parsing "${s.uri}"`, { cause: o });
- }
- }
- };
- const Cw = class ResolveStrategy {
- name;
- constructor({ name: s }) {
- this.name = s;
- }
- };
- const Ow = class OpenAPI3_1ResolveStrategy extends Cw {
- constructor(s) {
- super({ ...(null != s ? s : {}), name: 'openapi-3-1' });
- }
- canResolve(s, o) {
- const i = o.dereference.strategies.find((s) => 'openapi-3-1' === s.name);
- return void 0 !== i && i.canDereference(s, o);
- }
- async resolve(s, o) {
- const i = o.dereference.strategies.find((s) => 'openapi-3-1' === s.name);
- if (void 0 === i) throw new Ew('"openapi-3-1" dereference strategy is not available.');
- const u = new uw(),
- _ = util_merge(o, { resolve: { internal: !1 }, dereference: { refSet: u } });
- return await i.dereference(s, _), u;
- }
- };
- const Aw = class Resolver {
- name;
- constructor({ name: s }) {
- this.name = s;
- }
- };
- const jw = class HTTPResolver extends Aw {
- timeout;
- redirects;
- withCredentials;
- constructor(s) {
- const {
- name: o = 'http-resolver',
- timeout: i = 5e3,
- redirects: u = 5,
- withCredentials: _ = !1
- } = null != s ? s : {};
- super({ name: o }),
- (this.timeout = i),
- (this.redirects = u),
- (this.withCredentials = _);
- }
- canRead(s) {
- return isHttpUrl(s.uri);
- }
- };
- const Iw = class ResolveError extends Ho {};
- const Pw = class ResolverError extends Iw {},
- { AbortController: Mw, AbortSignal: Tw } = globalThis;
- void 0 === globalThis.AbortController && (globalThis.AbortController = Mw),
- void 0 === globalThis.AbortSignal && (globalThis.AbortSignal = Tw);
- const Nw = class HTTPResolverSwaggerClient extends jw {
- swaggerHTTPClient = http_http;
- swaggerHTTPClientConfig;
- constructor({
- swaggerHTTPClient: s = http_http,
- swaggerHTTPClientConfig: o = {},
- ...i
- } = {}) {
- super({ ...i, name: 'http-swagger-client' }),
- (this.swaggerHTTPClient = s),
- (this.swaggerHTTPClientConfig = o);
- }
- getHttpClient() {
- return this.swaggerHTTPClient;
- }
- async read(s) {
- const o = this.getHttpClient(),
- i = new AbortController(),
- { signal: u } = i,
- _ = setTimeout(() => {
- i.abort();
- }, this.timeout),
- w =
- this.getHttpClient().withCredentials || this.withCredentials
- ? 'include'
- : 'same-origin',
- x = 0 === this.redirects ? 'error' : 'follow',
- C = this.redirects > 0 ? this.redirects : void 0;
- try {
- return (
- await o({
- url: s.uri,
- signal: u,
- userFetch: async (s, o) => {
- let i = await fetch(s, o);
- try {
- i.headers.delete('Content-Type');
- } catch {
- (i = new Response(i.body, { ...i, headers: new Headers(i.headers) })),
- i.headers.delete('Content-Type');
- }
- return i;
- },
- credentials: w,
- redirect: x,
- follow: C,
- ...this.swaggerHTTPClientConfig
- })
- ).text.arrayBuffer();
- } catch (o) {
- throw new Pw(`Error downloading "${s.uri}"`, { cause: o });
- } finally {
- clearTimeout(_);
- }
- }
- },
- from = (s, o = wp) => {
- if (Yl(s))
- try {
- return o.fromRefract(JSON.parse(s));
- } catch {}
- return ku(s) && md('element', s) ? o.fromRefract(s) : o.toElement(s);
- };
- const Rw = class JSONParser extends xw {
- constructor(s = {}) {
- super({ name: 'json-swagger-client', mediaTypes: ['application/json'], ...s });
- }
- async canParse(s) {
- const o = 0 === this.fileExtensions.length || this.fileExtensions.includes(s.extension),
- i = this.mediaTypes.includes(s.mediaType);
- if (!o) return !1;
- if (i) return !0;
- if (!i)
- try {
- return JSON.parse(s.toString()), !0;
- } catch (s) {
- return !1;
- }
- return !1;
- }
- async parse(s) {
- if (this.sourceMap)
- throw new Sw("json-swagger-client parser plugin doesn't support sourceMaps option");
- const o = new Mu(),
- i = s.toString();
- if (this.allowEmpty && '' === i.trim()) return o;
- try {
- const s = from(JSON.parse(i));
- return s.classes.push('result'), o.push(s), o;
- } catch (o) {
- throw new Sw(`Error parsing "${s.uri}"`, { cause: o });
- }
- }
- };
- const Dw = class YAMLParser extends xw {
- constructor(s = {}) {
- super({
- name: 'yaml-1-2-swagger-client',
- mediaTypes: ['text/yaml', 'application/yaml'],
- ...s
- });
- }
- async canParse(s) {
- const o = 0 === this.fileExtensions.length || this.fileExtensions.includes(s.extension),
- i = this.mediaTypes.includes(s.mediaType);
- if (!o) return !1;
- if (i) return !0;
- if (!i)
- try {
- return mn.load(s.toString(), { schema: nn }), !0;
- } catch (s) {
- return !1;
- }
- return !1;
- }
- async parse(s) {
- if (this.sourceMap)
- throw new Sw(
- "yaml-1-2-swagger-client parser plugin doesn't support sourceMaps option"
- );
- const o = new Mu(),
- i = s.toString();
- try {
- const s = mn.load(i, { schema: nn });
- if (this.allowEmpty && void 0 === s) return o;
- const u = from(s);
- return u.classes.push('result'), o.push(u), o;
- } catch (o) {
- throw new Sw(`Error parsing "${s.uri}"`, { cause: o });
- }
- }
- };
- const Lw = class OpenAPIJSON3_1Parser extends xw {
- detectionRegExp = /"openapi"\s*:\s*"(?<version_json>3\.1\.(?:[1-9]\d*|0))"/;
- constructor(s = {}) {
- super({
- name: 'openapi-json-3-1-swagger-client',
- mediaTypes: new OpenAPIMediaTypes(
- ...lw.filterByFormat('generic'),
- ...lw.filterByFormat('json')
- ),
- ...s
- });
- }
- async canParse(s) {
- const o = 0 === this.fileExtensions.length || this.fileExtensions.includes(s.extension),
- i = this.mediaTypes.includes(s.mediaType);
- if (!o) return !1;
- if (i) return !0;
- if (!i)
- try {
- const o = s.toString();
- return JSON.parse(o), this.detectionRegExp.test(o);
- } catch (s) {
- return !1;
- }
- return !1;
- }
- async parse(s) {
- if (this.sourceMap)
- throw new Sw(
- "openapi-json-3-1-swagger-client parser plugin doesn't support sourceMaps option"
- );
- const o = new Mu(),
- i = s.toString();
- if (this.allowEmpty && '' === i.trim()) return o;
- try {
- const s = JSON.parse(i),
- u = wb.refract(s, this.refractorOpts);
- return u.classes.push('result'), o.push(u), o;
- } catch (o) {
- throw new Sw(`Error parsing "${s.uri}"`, { cause: o });
- }
- }
- };
- const Bw = class OpenAPIYAML31Parser extends xw {
- detectionRegExp =
- /(?<YAML>^(["']?)openapi\2\s*:\s*(["']?)(?<version_yaml>3\.1\.(?:[1-9]\d*|0))\3(?:\s+|$))|(?<JSON>"openapi"\s*:\s*"(?<version_json>3\.1\.(?:[1-9]\d*|0))")/m;
- constructor(s = {}) {
- super({
- name: 'openapi-yaml-3-1-swagger-client',
- mediaTypes: new OpenAPIMediaTypes(
- ...lw.filterByFormat('generic'),
- ...lw.filterByFormat('yaml')
- ),
- ...s
- });
- }
- async canParse(s) {
- const o = 0 === this.fileExtensions.length || this.fileExtensions.includes(s.extension),
- i = this.mediaTypes.includes(s.mediaType);
- if (!o) return !1;
- if (i) return !0;
- if (!i)
- try {
- const o = s.toString();
- return mn.load(o), this.detectionRegExp.test(o);
- } catch (s) {
- return !1;
- }
- return !1;
- }
- async parse(s) {
- if (this.sourceMap)
- throw new Sw(
- "openapi-yaml-3-1-swagger-client parser plugin doesn't support sourceMaps option"
- );
- const o = new Mu(),
- i = s.toString();
- try {
- const s = mn.load(i, { schema: nn });
- if (this.allowEmpty && void 0 === s) return o;
- const u = wb.refract(s, this.refractorOpts);
- return u.classes.push('result'), o.push(u), o;
- } catch (o) {
- throw new Sw(`Error parsing "${s.uri}"`, { cause: o });
- }
- }
- };
- const Fw = _curry3(function propEq(s, o, i) {
- return ra(s, Da(o, i));
- });
- const qw = class DereferenceStrategy {
- name;
- constructor({ name: s }) {
- this.name = s;
- }
- };
- var $w = _curry2(function none(s, o) {
- return ju(_complement(s), o);
- });
- const Vw = $w;
- var Uw = __webpack_require__(8068);
- const zw = class ElementIdentityError extends Jo {
- value;
- constructor(s, o) {
- super(s, o), void 0 !== o && (this.value = o.value);
- }
- };
- class IdentityManager {
- uuid;
- identityMap;
- constructor({ length: s = 6 } = {}) {
- (this.uuid = new Uw({ length: s })), (this.identityMap = new WeakMap());
- }
- identify(s) {
- if (!Nu(s))
- throw new zw(
- 'Cannot not identify the element. `element` is neither structurally compatible nor a subclass of an Element class.',
- { value: s }
- );
- if (s.meta.hasKey('id') && Ru(s.meta.get('id')) && !s.meta.get('id').equals(''))
- return s.id;
- if (this.identityMap.has(s)) return this.identityMap.get(s);
- const o = new Cu.Om(this.generateId());
- return this.identityMap.set(s, o), o;
- }
- forget(s) {
- return !!this.identityMap.has(s) && (this.identityMap.delete(s), !0);
- }
- generateId() {
- return this.uuid.randomUUID();
- }
- }
- new IdentityManager();
- const Ww = _curry3(function pathOr(s, o, i) {
- return Na(s, _path(o, i));
- }),
- traversal_find = (s, o) => {
- const i = new PredicateVisitor({ predicate: s, returnOnTrue: Ju });
- return visitor_visit(o, i), Ww(void 0, [0], i.result);
- };
- const Kw = class JsonSchema$anchorError extends Ho {};
- const Hw = class EvaluationJsonSchema$anchorError extends Kw {};
- const Jw = class InvalidJsonSchema$anchorError extends Kw {
- constructor(s) {
- super(`Invalid JSON Schema $anchor "${s}".`);
- }
- },
- isAnchor = (s) => /^[A-Za-z_][A-Za-z_0-9.-]*$/.test(s),
- uriToAnchor = (s) => {
- const o = getHash(s);
- return Up('#', o);
- },
- $anchor_evaluate = (s, o) => {
- const i = ((s) => {
- if (!isAnchor(s)) throw new Jw(s);
- return s;
- })(s),
- u = traversal_find((s) => Q_(s) && serializers_value(s.$anchor) === i, o);
- if (Rl(u)) throw new Hw(`Evaluation failed on token: "${i}"`);
- return u;
- },
- traversal_filter = (s, o) => {
- const i = new PredicateVisitor({ predicate: s });
- return visitor_visit(o, i), new Cu.G6(i.result);
- };
- const Gw = class JsonSchemaUriError extends Ho {};
- const Yw = class EvaluationJsonSchemaUriError extends Gw {},
- resolveSchema$refField = (s, o) => {
- if (void 0 === o.$ref) return;
- const i = getHash(serializers_value(o.$ref)),
- u = serializers_value(o.meta.get('inherited$id')),
- _ = Ca((s, o) => resolve(s, sanitize(stripHash(o))), s, [
- ...u,
- serializers_value(o.$ref)
- ]);
- return `${_}${'#' === i ? '' : i}`;
- },
- refractToSchemaElement = (s) => {
- if (refractToSchemaElement.cache.has(s)) return refractToSchemaElement.cache.get(s);
- const o = qb.refract(s);
- return refractToSchemaElement.cache.set(s, o), o;
- };
- refractToSchemaElement.cache = new WeakMap();
- const maybeRefractToSchemaElement = (s) =>
- isPrimitiveElement(s) ? refractToSchemaElement(s) : s,
- uri_evaluate = (s, o) => {
- const { cache: i } = uri_evaluate,
- u = stripHash(s),
- isSchemaElementWith$id = (s) => Q_(s) && void 0 !== s.$id;
- if (!i.has(o)) {
- const s = traversal_filter(isSchemaElementWith$id, o);
- i.set(o, Array.from(s));
- }
- const _ = i.get(o).find((s) => {
- const o = ((s, o) => {
- if (void 0 === o.$id) return;
- const i = serializers_value(o.meta.get('inherited$id'));
- return Ca((s, o) => resolve(s, sanitize(stripHash(o))), s, [
- ...i,
- serializers_value(o.$id)
- ]);
- })(u, s);
- return o === u;
- });
- if (Rl(_)) throw new Yw(`Evaluation failed on URI: "${s}"`);
- let w, x;
- return (
- isAnchor(uriToAnchor(s))
- ? ((w = $anchor_evaluate), (x = uriToAnchor(s)))
- : ((w = es_evaluate), (x = uriToPointer(s))),
- w(x, _)
- );
- };
- uri_evaluate.cache = new WeakMap();
- const Xw = class MaximumDereferenceDepthError extends _w {};
- const Zw = class MaximumResolveDepthError extends Iw {};
- const Qw = class UnmatchedResolverError extends Pw {},
- _swagger_api_apidom_reference_es_parse = async (s, o) => {
- const i = new vw({ uri: sanitize(stripHash(s)), mediaType: o.parse.mediaType }),
- u = await (async (s, o) => {
- const i = o.resolve.resolvers.map((s) => {
- const i = Object.create(s);
- return Object.assign(i, o.resolve.resolverOpts);
- }),
- u = await plugins_filter('canRead', [s, o], i);
- if (gp(u)) throw new Qw(s.uri);
- try {
- const { result: o } = await run('read', [s], u);
- return o;
- } catch (o) {
- throw new Iw(`Error while reading file "${s.uri}"`, { cause: o });
- }
- })(i, o);
- return (async (s, o) => {
- const i = o.parse.parsers.map((s) => {
- const i = Object.create(s);
- return Object.assign(i, o.parse.parserOpts);
- }),
- u = await plugins_filter('canParse', [s, o], i);
- if (gp(u)) throw new Qw(s.uri);
- try {
- const { plugin: i, result: _ } = await run('parse', [s, o], u);
- return !i.allowEmpty && _.isEmpty
- ? Promise.reject(new ww(`Error while parsing file "${s.uri}". File is empty.`))
- : _;
- } catch (o) {
- throw new ww(`Error while parsing file "${s.uri}"`, { cause: o });
- }
- })(new vw({ ...i, data: u }), o);
- };
- class AncestorLineage extends Array {
- includesCycle(s) {
- return this.filter((o) => o.has(s)).length > 1;
- }
- includes(s, o) {
- return s instanceof Set ? super.includes(s, o) : this.some((o) => o.has(s));
- }
- findItem(s) {
- for (const o of this) for (const i of o) if (Nu(i) && s(i)) return i;
- }
- }
- const eS = visitor_visit[Symbol.for('nodejs.util.promisify.custom')],
- tS = new IdentityManager(),
- mutationReplacer = (s, o, i, u) => {
- $u(u) ? (u.value = s) : Array.isArray(u) && (u[i] = s);
- };
- class OpenAPI3_1DereferenceVisitor {
- indirections;
- namespace;
- reference;
- options;
- ancestors;
- refractCache;
- constructor({
- reference: s,
- namespace: o,
- options: i,
- indirections: u = [],
- ancestors: _ = new AncestorLineage(),
- refractCache: w = new Map()
- }) {
- (this.indirections = u),
- (this.namespace = o),
- (this.reference = s),
- (this.options = i),
- (this.ancestors = new AncestorLineage(..._)),
- (this.refractCache = w);
- }
- toBaseURI(s) {
- return resolve(this.reference.uri, sanitize(stripHash(s)));
- }
- async toReference(s) {
- if (this.reference.depth >= this.options.resolve.maxDepth)
- throw new Zw(
- `Maximum resolution depth of ${this.options.resolve.maxDepth} has been exceeded by file "${this.reference.uri}"`
- );
- const o = this.toBaseURI(s),
- { refSet: i } = this.reference;
- if (i.has(o)) return i.find(Fw(o, 'uri'));
- const u = await _swagger_api_apidom_reference_es_parse(unsanitize(o), {
- ...this.options,
- parse: { ...this.options.parse, mediaType: 'text/plain' }
- }),
- _ = new cw({ uri: o, value: cloneDeep(u), depth: this.reference.depth + 1 });
- if ((i.add(_), this.options.dereference.immutable)) {
- const s = new cw({
- uri: `immutable://${o}`,
- value: u,
- depth: this.reference.depth + 1
- });
- i.add(s);
- }
- return _;
- }
- toAncestorLineage(s) {
- const o = new Set(s.filter(Nu));
- return [new AncestorLineage(...this.ancestors, o), o];
- }
- async ReferenceElement(s, o, i, u, _, w) {
- if (this.indirections.includes(s)) return !1;
- const [x, C] = this.toAncestorLineage([..._, i]),
- j = this.toBaseURI(serializers_value(s.$ref)),
- L = stripHash(this.reference.uri) === j,
- B = !L;
- if (!this.options.resolve.internal && L) return !1;
- if (!this.options.resolve.external && B) return !1;
- const $ = await this.toReference(serializers_value(s.$ref)),
- V = resolve(j, serializers_value(s.$ref));
- this.indirections.push(s);
- const U = uriToPointer(V);
- let z = es_evaluate(U, $.value.result);
- if (((z.id = tS.identify(z)), isPrimitiveElement(z))) {
- const o = serializers_value(s.meta.get('referenced-element')),
- i = `${o}-${serializers_value(tS.identify(z))}`;
- if (this.refractCache.has(i)) z = this.refractCache.get(i);
- else if (isReferenceLikeElement(z))
- (z = Pb.refract(z)),
- z.setMetaProperty('referenced-element', o),
- this.refractCache.set(i, z);
- else {
- (z = this.namespace.getElementClass(o).refract(z)), this.refractCache.set(i, z);
- }
- }
- if (s === z) throw new Ho('Recursive Reference Object detected');
- if (this.indirections.length > this.options.dereference.maxDepth)
- throw new Xw(
- `Maximum dereference depth of "${this.options.dereference.maxDepth}" has been exceeded in file "${this.reference.uri}"`
- );
- if (x.includes(z)) {
- if ((($.refSet.circular = !0), 'error' === this.options.dereference.circular))
- throw new Ho('Circular reference detected');
- if ('replace' === this.options.dereference.circular) {
- var Y, Z;
- const o = new Cu.sI(z.id, {
- type: 'reference',
- uri: $.uri,
- $ref: serializers_value(s.$ref)
- }),
- u = (
- null !==
- (Y =
- null === (Z = this.options.dereference.strategyOpts['openapi-3-1']) ||
- void 0 === Z
- ? void 0
- : Z.circularReplacer) && void 0 !== Y
- ? Y
- : this.options.dereference.circularReplacer
- )(o);
- return w.replaceWith(u, mutationReplacer), !i && u;
- }
- }
- const ee = stripHash($.refSet.rootRef.uri) !== $.uri,
- ie = ['error', 'replace'].includes(this.options.dereference.circular);
- if ((B || ee || G_(z) || ie) && !x.includesCycle(z)) {
- C.add(s);
- const o = new OpenAPI3_1DereferenceVisitor({
- reference: $,
- namespace: this.namespace,
- indirections: [...this.indirections],
- options: this.options,
- refractCache: this.refractCache,
- ancestors: x
- });
- (z = await eS(z, o, {
- keyMap: nw,
- nodeTypeGetter: apidom_ns_openapi_3_1_es_traversal_visitor_getNodeType
- })),
- C.delete(s);
- }
- this.indirections.pop();
- const ae = cloneShallow(z);
- return (
- ae.setMetaProperty('id', tS.generateId()),
- ae.setMetaProperty('ref-fields', {
- $ref: serializers_value(s.$ref),
- description: serializers_value(s.description),
- summary: serializers_value(s.summary)
- }),
- ae.setMetaProperty('ref-origin', $.uri),
- ae.setMetaProperty('ref-referencing-element-id', cloneDeep(tS.identify(s))),
- Fu(z) &&
- Fu(ae) &&
- (s.hasKey('description') &&
- 'description' in z &&
- (ae.remove('description'), ae.set('description', s.get('description'))),
- s.hasKey('summary') &&
- 'summary' in z &&
- (ae.remove('summary'), ae.set('summary', s.get('summary')))),
- w.replaceWith(ae, mutationReplacer),
- !i && ae
- );
- }
- async PathItemElement(s, o, i, u, _, w) {
- if (!Ru(s.$ref)) return;
- if (this.indirections.includes(s)) return !1;
- const [x, C] = this.toAncestorLineage([..._, i]),
- j = this.toBaseURI(serializers_value(s.$ref)),
- L = stripHash(this.reference.uri) === j,
- B = !L;
- if (!this.options.resolve.internal && L) return;
- if (!this.options.resolve.external && B) return;
- const $ = await this.toReference(serializers_value(s.$ref)),
- V = resolve(j, serializers_value(s.$ref));
- this.indirections.push(s);
- const U = uriToPointer(V);
- let z = es_evaluate(U, $.value.result);
- if (((z.id = tS.identify(z)), isPrimitiveElement(z))) {
- const s = `path-item-${serializers_value(tS.identify(z))}`;
- this.refractCache.has(s)
- ? (z = this.refractCache.get(s))
- : ((z = Ab.refract(z)), this.refractCache.set(s, z));
- }
- if (s === z) throw new Ho('Recursive Path Item Object reference detected');
- if (this.indirections.length > this.options.dereference.maxDepth)
- throw new Xw(
- `Maximum dereference depth of "${this.options.dereference.maxDepth}" has been exceeded in file "${this.reference.uri}"`
- );
- if (x.includes(z)) {
- if ((($.refSet.circular = !0), 'error' === this.options.dereference.circular))
- throw new Ho('Circular reference detected');
- if ('replace' === this.options.dereference.circular) {
- var Y, Z;
- const o = new Cu.sI(z.id, {
- type: 'path-item',
- uri: $.uri,
- $ref: serializers_value(s.$ref)
- }),
- u = (
- null !==
- (Y =
- null === (Z = this.options.dereference.strategyOpts['openapi-3-1']) ||
- void 0 === Z
- ? void 0
- : Z.circularReplacer) && void 0 !== Y
- ? Y
- : this.options.dereference.circularReplacer
- )(o);
- return w.replaceWith(u, mutationReplacer), !i && u;
- }
- }
- const ee = stripHash($.refSet.rootRef.uri) !== $.uri,
- ie = ['error', 'replace'].includes(this.options.dereference.circular);
- if ((B || ee || (H_(z) && Ru(z.$ref)) || ie) && !x.includesCycle(z)) {
- C.add(s);
- const o = new OpenAPI3_1DereferenceVisitor({
- reference: $,
- namespace: this.namespace,
- indirections: [...this.indirections],
- options: this.options,
- refractCache: this.refractCache,
- ancestors: x
- });
- (z = await eS(z, o, {
- keyMap: nw,
- nodeTypeGetter: apidom_ns_openapi_3_1_es_traversal_visitor_getNodeType
- })),
- C.delete(s);
- }
- if ((this.indirections.pop(), H_(z))) {
- const o = new Ab([...z.content], cloneDeep(z.meta), cloneDeep(z.attributes));
- o.setMetaProperty('id', tS.generateId()),
- s.forEach((s, i, u) => {
- o.remove(serializers_value(i)), o.content.push(u);
- }),
- o.remove('$ref'),
- o.setMetaProperty('ref-fields', { $ref: serializers_value(s.$ref) }),
- o.setMetaProperty('ref-origin', $.uri),
- o.setMetaProperty('ref-referencing-element-id', cloneDeep(tS.identify(s))),
- (z = o);
- }
- return w.replaceWith(z, mutationReplacer), i ? void 0 : z;
- }
- async LinkElement(s, o, i, u, _, w) {
- if (!Ru(s.operationRef) && !Ru(s.operationId)) return;
- if (Ru(s.operationRef) && Ru(s.operationId))
- throw new Ho(
- 'LinkElement operationRef and operationId fields are mutually exclusive.'
- );
- let x;
- if (Ru(s.operationRef)) {
- var C;
- const o = uriToPointer(serializers_value(s.operationRef)),
- u = this.toBaseURI(serializers_value(s.operationRef)),
- _ = stripHash(this.reference.uri) === u,
- j = !_;
- if (!this.options.resolve.internal && _) return;
- if (!this.options.resolve.external && j) return;
- const L = await this.toReference(serializers_value(s.operationRef));
- if (((x = es_evaluate(o, L.value.result)), isPrimitiveElement(x))) {
- const s = `operation-${serializers_value(tS.identify(x))}`;
- this.refractCache.has(s)
- ? (x = this.refractCache.get(s))
- : ((x = Sb.refract(x)), this.refractCache.set(s, x));
- }
- (x = cloneShallow(x)), x.setMetaProperty('ref-origin', L.uri);
- const B = cloneShallow(s);
- return (
- null === (C = B.operationRef) || void 0 === C || C.meta.set('operation', x),
- w.replaceWith(B, mutationReplacer),
- i ? void 0 : B
- );
- }
- if (Ru(s.operationId)) {
- var j;
- const o = serializers_value(s.operationId),
- u = await this.toReference(unsanitize(this.reference.uri));
- if (
- ((x = traversal_find(
- (s) => W_(s) && Nu(s.operationId) && s.operationId.equals(o),
- u.value.result
- )),
- Rl(x))
- )
- throw new Ho(`OperationElement(operationId=${o}) not found.`);
- const _ = cloneShallow(s);
- return (
- null === (j = _.operationId) || void 0 === j || j.meta.set('operation', x),
- w.replaceWith(_, mutationReplacer),
- i ? void 0 : _
- );
- }
- }
- async ExampleElement(s, o, i, u, _, w) {
- if (!Ru(s.externalValue)) return;
- if (s.hasKey('value') && Ru(s.externalValue))
- throw new Ho('ExampleElement value and externalValue fields are mutually exclusive.');
- const x = this.toBaseURI(serializers_value(s.externalValue)),
- C = stripHash(this.reference.uri) === x,
- j = !C;
- if (!this.options.resolve.internal && C) return;
- if (!this.options.resolve.external && j) return;
- const L = await this.toReference(serializers_value(s.externalValue)),
- B = cloneShallow(L.value.result);
- B.setMetaProperty('ref-origin', L.uri);
- const $ = cloneShallow(s);
- return ($.value = B), w.replaceWith($, mutationReplacer), i ? void 0 : $;
- }
- async SchemaElement(s, o, i, u, _, w) {
- if (!Ru(s.$ref)) return;
- if (this.indirections.includes(s)) return !1;
- const [x, C] = this.toAncestorLineage([..._, i]);
- let j = await this.toReference(unsanitize(this.reference.uri)),
- { uri: L } = j;
- const B = resolveSchema$refField(L, s),
- $ = stripHash(B),
- V = new vw({ uri: $ }),
- U = Vw((s) => s.canRead(V), this.options.resolve.resolvers),
- z = !U;
- let Y,
- Z = stripHash(this.reference.uri) === B,
- ee = !Z;
- this.indirections.push(s);
- try {
- if (U || z) {
- L = this.toBaseURI(B);
- const s = B,
- o = maybeRefractToSchemaElement(j.value.result);
- if (
- ((Y = uri_evaluate(s, o)),
- (Y = maybeRefractToSchemaElement(Y)),
- (Y.id = tS.identify(Y)),
- !this.options.resolve.internal && Z)
- )
- return;
- if (!this.options.resolve.external && ee) return;
- } else {
- if (
- ((L = this.toBaseURI(B)),
- (Z = stripHash(this.reference.uri) === L),
- (ee = !Z),
- !this.options.resolve.internal && Z)
- )
- return;
- if (!this.options.resolve.external && ee) return;
- j = await this.toReference(unsanitize(B));
- const s = uriToPointer(B),
- o = maybeRefractToSchemaElement(j.value.result);
- (Y = es_evaluate(s, o)),
- (Y = maybeRefractToSchemaElement(Y)),
- (Y.id = tS.identify(Y));
- }
- } catch (s) {
- if (!(z && s instanceof Yw)) throw s;
- if (isAnchor(uriToAnchor(B))) {
- if (
- ((Z = stripHash(this.reference.uri) === L),
- (ee = !Z),
- !this.options.resolve.internal && Z)
- )
- return;
- if (!this.options.resolve.external && ee) return;
- j = await this.toReference(unsanitize(B));
- const s = uriToAnchor(B),
- o = maybeRefractToSchemaElement(j.value.result);
- (Y = $anchor_evaluate(s, o)),
- (Y = maybeRefractToSchemaElement(Y)),
- (Y.id = tS.identify(Y));
- } else {
- if (
- ((L = this.toBaseURI(B)),
- (Z = stripHash(this.reference.uri) === L),
- (ee = !Z),
- !this.options.resolve.internal && Z)
- )
- return;
- if (!this.options.resolve.external && ee) return;
- j = await this.toReference(unsanitize(B));
- const s = uriToPointer(B),
- o = maybeRefractToSchemaElement(j.value.result);
- (Y = es_evaluate(s, o)),
- (Y = maybeRefractToSchemaElement(Y)),
- (Y.id = tS.identify(Y));
- }
- }
- if (s === Y) throw new Ho('Recursive Schema Object reference detected');
- if (this.indirections.length > this.options.dereference.maxDepth)
- throw new Xw(
- `Maximum dereference depth of "${this.options.dereference.maxDepth}" has been exceeded in file "${this.reference.uri}"`
- );
- if (x.includes(Y)) {
- if (((j.refSet.circular = !0), 'error' === this.options.dereference.circular))
- throw new Ho('Circular reference detected');
- if ('replace' === this.options.dereference.circular) {
- var ie, ae;
- const o = new Cu.sI(Y.id, {
- type: 'json-schema',
- uri: j.uri,
- $ref: serializers_value(s.$ref)
- }),
- u = (
- null !==
- (ie =
- null === (ae = this.options.dereference.strategyOpts['openapi-3-1']) ||
- void 0 === ae
- ? void 0
- : ae.circularReplacer) && void 0 !== ie
- ? ie
- : this.options.dereference.circularReplacer
- )(o);
- return w.replaceWith(u, mutationReplacer), !i && u;
- }
- }
- const le = stripHash(j.refSet.rootRef.uri) !== j.uri,
- ce = ['error', 'replace'].includes(this.options.dereference.circular);
- if ((ee || le || (Q_(Y) && Ru(Y.$ref)) || ce) && !x.includesCycle(Y)) {
- C.add(s);
- const o = new OpenAPI3_1DereferenceVisitor({
- reference: j,
- namespace: this.namespace,
- indirections: [...this.indirections],
- options: this.options,
- refractCache: this.refractCache,
- ancestors: x
- });
- (Y = await eS(Y, o, {
- keyMap: nw,
- nodeTypeGetter: apidom_ns_openapi_3_1_es_traversal_visitor_getNodeType
- })),
- C.delete(s);
- }
- if ((this.indirections.pop(), predicates_isBooleanJsonSchemaElement(Y))) {
- const o = cloneDeep(Y);
- return (
- o.setMetaProperty('id', tS.generateId()),
- o.setMetaProperty('ref-fields', { $ref: serializers_value(s.$ref) }),
- o.setMetaProperty('ref-origin', j.uri),
- o.setMetaProperty('ref-referencing-element-id', cloneDeep(tS.identify(s))),
- w.replaceWith(o, mutationReplacer),
- !i && o
- );
- }
- if (Q_(Y)) {
- const o = new qb([...Y.content], cloneDeep(Y.meta), cloneDeep(Y.attributes));
- o.setMetaProperty('id', tS.generateId()),
- s.forEach((s, i, u) => {
- o.remove(serializers_value(i)), o.content.push(u);
- }),
- o.remove('$ref'),
- o.setMetaProperty('ref-fields', { $ref: serializers_value(s.$ref) }),
- o.setMetaProperty('ref-origin', j.uri),
- o.setMetaProperty('ref-referencing-element-id', cloneDeep(tS.identify(s))),
- (Y = o);
- }
- return w.replaceWith(Y, mutationReplacer), i ? void 0 : Y;
- }
- }
- const rS = OpenAPI3_1DereferenceVisitor,
- nS = visitor_visit[Symbol.for('nodejs.util.promisify.custom')];
- const sS = class OpenAPI3_1DereferenceStrategy extends qw {
- constructor(s) {
- super({ ...(null != s ? s : {}), name: 'openapi-3-1' });
- }
- canDereference(s) {
- var o;
- return 'text/plain' !== s.mediaType
- ? lw.includes(s.mediaType)
- : z_(null === (o = s.parseResult) || void 0 === o ? void 0 : o.result);
- }
- async dereference(s, o) {
- var i;
- const u = createNamespace(ow),
- _ = null !== (i = o.dereference.refSet) && void 0 !== i ? i : new uw(),
- w = new uw();
- let x,
- C = _;
- _.has(s.uri)
- ? (x = _.find(Fw(s.uri, 'uri')))
- : ((x = new cw({ uri: s.uri, value: s.parseResult })), _.add(x)),
- o.dereference.immutable &&
- (_.refs
- .map((s) => new cw({ ...s, value: cloneDeep(s.value) }))
- .forEach((s) => w.add(s)),
- (x = w.find((o) => o.uri === s.uri)),
- (C = w));
- const j = new rS({ reference: x, namespace: u, options: o }),
- L = await nS(C.rootRef.value, j, {
- keyMap: nw,
- nodeTypeGetter: apidom_ns_openapi_3_1_es_traversal_visitor_getNodeType
- });
- return (
- o.dereference.immutable &&
- w.refs
- .filter((s) => s.uri.startsWith('immutable://'))
- .map((s) => new cw({ ...s, uri: s.uri.replace(/^immutable:\/\//, '') }))
- .forEach((s) => _.add(s)),
- null === o.dereference.refSet && _.clean(),
- w.clean(),
- L
- );
- }
- },
- to_path = (s) => {
- const o = ((s) => s.slice(2))(s);
- return o.reduce((s, i, u) => {
- if ($u(i)) {
- const o = String(serializers_value(i.key));
- s.push(o);
- } else if (qu(o[u - 2])) {
- const _ = o[u - 2].content.indexOf(i);
- s.push(_);
- }
- return s;
- }, []);
- };
- const oS = class ModelPropertyMacroVisitor {
- modelPropertyMacro;
- options;
- SchemaElement = {
- leave: (s, o, i, u, _) => {
- void 0 !== s.properties &&
- Fu(s.properties) &&
- s.properties.forEach((o) => {
- if (Fu(o))
- try {
- const s = this.modelPropertyMacro(serializers_value(o));
- o.set('default', s);
- } catch (o) {
- var u, w;
- const x = new Error(o, { cause: o });
- (x.fullPath = [...to_path([..._, i, s]), 'properties']),
- null === (u = this.options.dereference.dereferenceOpts) ||
- void 0 === u ||
- null === (u = u.errors) ||
- void 0 === u ||
- null === (w = u.push) ||
- void 0 === w ||
- w.call(u, x);
- }
- });
- }
- };
- constructor({ modelPropertyMacro: s, options: o }) {
- (this.modelPropertyMacro = s), (this.options = o);
- }
- };
- const iS = class all_of_AllOfVisitor {
- options;
- SchemaElement = {
- leave(s, o, i, u, _) {
- if (void 0 === s.allOf) return;
- if (!qu(s.allOf)) {
- var w, x;
- const o = new TypeError('allOf must be an array');
- return (
- (o.fullPath = [...to_path([..._, i, s]), 'allOf']),
- void (
- null === (w = this.options.dereference.dereferenceOpts) ||
- void 0 === w ||
- null === (w = w.errors) ||
- void 0 === w ||
- null === (x = w.push) ||
- void 0 === x ||
- x.call(w, o)
- )
- );
- }
- if (s.allOf.isEmpty) return void s.remove('allOf');
- if (!s.allOf.content.every(Q_)) {
- var C, j;
- const o = new TypeError('Elements in allOf must be objects');
- return (
- (o.fullPath = [...to_path([..._, i, s]), 'allOf']),
- void (
- null === (C = this.options.dereference.dereferenceOpts) ||
- void 0 === C ||
- null === (C = C.errors) ||
- void 0 === C ||
- null === (j = C.push) ||
- void 0 === j ||
- j.call(C, o)
- )
- );
- }
- for (; s.hasKey('allOf'); ) {
- const { allOf: o } = s;
- s.remove('allOf');
- const i = deepmerge.all([...o.content, s]);
- if ((s.hasKey('$$ref') || i.remove('$$ref'), s.hasKey('example'))) {
- const o = i.getMember('example');
- o && (o.value = s.get('example'));
- }
- if (s.hasKey('examples')) {
- const o = i.getMember('examples');
- o && (o.value = s.get('examples'));
- }
- s.content = i.content;
- }
- }
- };
- constructor({ options: s }) {
- this.options = s;
- }
- };
- const aS = class ParameterMacroVisitor {
- parameterMacro;
- options;
- #e;
- OperationElement = {
- enter: (s) => {
- this.#e = s;
- },
- leave: () => {
- this.#e = void 0;
- }
- };
- ParameterElement = {
- leave: (s, o, i, u, _) => {
- const w = this.#e ? serializers_value(this.#e) : null,
- x = serializers_value(s);
- try {
- const o = this.parameterMacro(w, x);
- s.set('default', o);
- } catch (s) {
- var C, j;
- const o = new Error(s, { cause: s });
- (o.fullPath = to_path([..._, i])),
- null === (C = this.options.dereference.dereferenceOpts) ||
- void 0 === C ||
- null === (C = C.errors) ||
- void 0 === C ||
- null === (j = C.push) ||
- void 0 === j ||
- j.call(C, o);
- }
- }
- };
- constructor({ parameterMacro: s, options: o }) {
- (this.parameterMacro = s), (this.options = o);
- }
- },
- get_root_cause = (s) => {
- if (null == s.cause) return s;
- let { cause: o } = s;
- for (; null != o.cause; ) o = o.cause;
- return o;
- };
- const lS = class SchemaRefError extends Jo {},
- { wrapError: cS } = ru,
- uS = visitor_visit[Symbol.for('nodejs.util.promisify.custom')],
- pS = new IdentityManager(),
- dereference_mutationReplacer = (s, o, i, u) => {
- $u(u) ? (u.value = s) : Array.isArray(u) && (u[i] = s);
- };
- class OpenAPI3_1SwaggerClientDereferenceVisitor extends rS {
- useCircularStructures;
- allowMetaPatches;
- basePath;
- constructor({
- allowMetaPatches: s = !0,
- useCircularStructures: o = !1,
- basePath: i = null,
- ...u
- }) {
- super(u),
- (this.allowMetaPatches = s),
- (this.useCircularStructures = o),
- (this.basePath = i);
- }
- async ReferenceElement(s, o, i, u, _, w) {
- try {
- if (this.indirections.includes(s)) return !1;
- const [o, u] = this.toAncestorLineage([..._, i]),
- L = this.toBaseURI(serializers_value(s.$ref)),
- B = stripHash(this.reference.uri) === L,
- $ = !B;
- if (!this.options.resolve.internal && B) return !1;
- if (!this.options.resolve.external && $) return !1;
- const V = await this.toReference(serializers_value(s.$ref)),
- U = resolve(L, serializers_value(s.$ref));
- this.indirections.push(s);
- const z = uriToPointer(U);
- let Y = es_evaluate(z, V.value.result);
- if (((Y.id = pS.identify(Y)), isPrimitiveElement(Y))) {
- const o = serializers_value(s.meta.get('referenced-element')),
- i = `${o}-${serializers_value(pS.identify(Y))}`;
- if (this.refractCache.has(i)) Y = this.refractCache.get(i);
- else if (isReferenceLikeElement(Y))
- (Y = Pb.refract(Y)),
- Y.setMetaProperty('referenced-element', o),
- this.refractCache.set(i, Y);
- else {
- (Y = this.namespace.getElementClass(o).refract(Y)), this.refractCache.set(i, Y);
- }
- }
- if (s === Y) throw new Ho('Recursive Reference Object detected');
- if (this.indirections.length > this.options.dereference.maxDepth)
- throw new Xw(
- `Maximum dereference depth of "${this.options.dereference.maxDepth}" has been exceeded in file "${this.reference.uri}"`
- );
- if (o.includes(Y)) {
- if (((V.refSet.circular = !0), 'error' === this.options.dereference.circular))
- throw new Ho('Circular reference detected');
- if ('replace' === this.options.dereference.circular) {
- var x, C;
- const o = new Cu.sI(Y.id, {
- type: 'reference',
- uri: V.uri,
- $ref: serializers_value(s.$ref),
- baseURI: U,
- referencingElement: s
- }),
- u = (
- null !==
- (x =
- null === (C = this.options.dereference.strategyOpts['openapi-3-1']) ||
- void 0 === C
- ? void 0
- : C.circularReplacer) && void 0 !== x
- ? x
- : this.options.dereference.circularReplacer
- )(o);
- return w.replaceWith(o, dereference_mutationReplacer), !i && u;
- }
- }
- const Z = stripHash(V.refSet.rootRef.uri) !== V.uri,
- ee = ['error', 'replace'].includes(this.options.dereference.circular);
- if (($ || Z || G_(Y) || ee) && !o.includesCycle(Y)) {
- var j;
- u.add(s);
- const w = new OpenAPI3_1SwaggerClientDereferenceVisitor({
- reference: V,
- namespace: this.namespace,
- indirections: [...this.indirections],
- options: this.options,
- refractCache: this.refractCache,
- ancestors: o,
- allowMetaPatches: this.allowMetaPatches,
- useCircularStructures: this.useCircularStructures,
- basePath:
- null !== (j = this.basePath) && void 0 !== j
- ? j
- : [...to_path([..._, i, s]), '$ref']
- });
- (Y = await uS(Y, w, {
- keyMap: nw,
- nodeTypeGetter: apidom_ns_openapi_3_1_es_traversal_visitor_getNodeType
- })),
- u.delete(s);
- }
- this.indirections.pop();
- const ie = cloneShallow(Y);
- if (
- (ie.setMetaProperty('ref-fields', {
- $ref: serializers_value(s.$ref),
- description: serializers_value(s.description),
- summary: serializers_value(s.summary)
- }),
- ie.setMetaProperty('ref-origin', V.uri),
- ie.setMetaProperty('ref-referencing-element-id', cloneDeep(pS.identify(s))),
- Fu(Y) &&
- (s.hasKey('description') &&
- 'description' in Y &&
- (ie.remove('description'), ie.set('description', s.get('description'))),
- s.hasKey('summary') &&
- 'summary' in Y &&
- (ie.remove('summary'), ie.set('summary', s.get('summary')))),
- this.allowMetaPatches && Fu(ie) && !ie.hasKey('$$ref'))
- ) {
- const s = resolve(L, U);
- ie.set('$$ref', s);
- }
- return w.replaceWith(ie, dereference_mutationReplacer), !i && ie;
- } catch (o) {
- var L, B, $;
- const u = get_root_cause(o),
- w = cS(u, {
- baseDoc: this.reference.uri,
- $ref: serializers_value(s.$ref),
- pointer: uriToPointer(serializers_value(s.$ref)),
- fullPath:
- null !== (L = this.basePath) && void 0 !== L
- ? L
- : [...to_path([..._, i, s]), '$ref']
- });
- return void (
- null === (B = this.options.dereference.dereferenceOpts) ||
- void 0 === B ||
- null === (B = B.errors) ||
- void 0 === B ||
- null === ($ = B.push) ||
- void 0 === $ ||
- $.call(B, w)
- );
- }
- }
- async PathItemElement(s, o, i, u, _, w) {
- try {
- if (!Ru(s.$ref)) return;
- if (this.indirections.includes(s)) return !1;
- if (includesClasses(['cycle'], s.$ref)) return !1;
- const [o, u] = this.toAncestorLineage([..._, i]),
- L = this.toBaseURI(serializers_value(s.$ref)),
- B = stripHash(this.reference.uri) === L,
- $ = !B;
- if (!this.options.resolve.internal && B) return;
- if (!this.options.resolve.external && $) return;
- const V = await this.toReference(serializers_value(s.$ref)),
- U = resolve(L, serializers_value(s.$ref));
- this.indirections.push(s);
- const z = uriToPointer(U);
- let Y = es_evaluate(z, V.value.result);
- if (((Y.id = pS.identify(Y)), isPrimitiveElement(Y))) {
- const s = `path-item-${serializers_value(pS.identify(Y))}`;
- this.refractCache.has(s)
- ? (Y = this.refractCache.get(s))
- : ((Y = Ab.refract(Y)), this.refractCache.set(s, Y));
- }
- if (s === Y) throw new Ho('Recursive Path Item Object reference detected');
- if (this.indirections.length > this.options.dereference.maxDepth)
- throw new Xw(
- `Maximum dereference depth of "${this.options.dereference.maxDepth}" has been exceeded in file "${this.reference.uri}"`
- );
- if (o.includes(Y)) {
- if (((V.refSet.circular = !0), 'error' === this.options.dereference.circular))
- throw new Ho('Circular reference detected');
- if ('replace' === this.options.dereference.circular) {
- var x, C;
- const o = new Cu.sI(Y.id, {
- type: 'path-item',
- uri: V.uri,
- $ref: serializers_value(s.$ref),
- baseURI: U,
- referencingElement: s
- }),
- u = (
- null !==
- (x =
- null === (C = this.options.dereference.strategyOpts['openapi-3-1']) ||
- void 0 === C
- ? void 0
- : C.circularReplacer) && void 0 !== x
- ? x
- : this.options.dereference.circularReplacer
- )(o);
- return w.replaceWith(o, dereference_mutationReplacer), !i && u;
- }
- }
- const Z = stripHash(V.refSet.rootRef.uri) !== V.uri,
- ee = ['error', 'replace'].includes(this.options.dereference.circular);
- if (($ || Z || (H_(Y) && Ru(Y.$ref)) || ee) && !o.includesCycle(Y)) {
- var j;
- u.add(s);
- const w = new OpenAPI3_1SwaggerClientDereferenceVisitor({
- reference: V,
- namespace: this.namespace,
- indirections: [...this.indirections],
- options: this.options,
- ancestors: o,
- allowMetaPatches: this.allowMetaPatches,
- useCircularStructures: this.useCircularStructures,
- basePath:
- null !== (j = this.basePath) && void 0 !== j
- ? j
- : [...to_path([..._, i, s]), '$ref']
- });
- (Y = await uS(Y, w, {
- keyMap: nw,
- nodeTypeGetter: apidom_ns_openapi_3_1_es_traversal_visitor_getNodeType
- })),
- u.delete(s);
- }
- if ((this.indirections.pop(), H_(Y))) {
- const o = new Ab([...Y.content], cloneDeep(Y.meta), cloneDeep(Y.attributes));
- if (
- (s.forEach((s, i, u) => {
- o.remove(serializers_value(i)), o.content.push(u);
- }),
- o.remove('$ref'),
- o.setMetaProperty('ref-fields', { $ref: serializers_value(s.$ref) }),
- o.setMetaProperty('ref-origin', V.uri),
- o.setMetaProperty('ref-referencing-element-id', cloneDeep(pS.identify(s))),
- this.allowMetaPatches && void 0 === o.get('$$ref'))
- ) {
- const s = resolve(L, U);
- o.set('$$ref', s);
- }
- Y = o;
- }
- return w.replaceWith(Y, dereference_mutationReplacer), i ? void 0 : Y;
- } catch (o) {
- var L, B, $;
- const u = get_root_cause(o),
- w = cS(u, {
- baseDoc: this.reference.uri,
- $ref: serializers_value(s.$ref),
- pointer: uriToPointer(serializers_value(s.$ref)),
- fullPath:
- null !== (L = this.basePath) && void 0 !== L
- ? L
- : [...to_path([..._, i, s]), '$ref']
- });
- return void (
- null === (B = this.options.dereference.dereferenceOpts) ||
- void 0 === B ||
- null === (B = B.errors) ||
- void 0 === B ||
- null === ($ = B.push) ||
- void 0 === $ ||
- $.call(B, w)
- );
- }
- }
- async SchemaElement(s, o, i, u, _, w) {
- try {
- if (!Ru(s.$ref)) return;
- if (this.indirections.includes(s)) return !1;
- const [o, u] = this.toAncestorLineage([..._, i]);
- let L = await this.toReference(unsanitize(this.reference.uri)),
- { uri: B } = L;
- const $ = resolveSchema$refField(B, s),
- V = stripHash($),
- U = new vw({ uri: V }),
- z = !this.options.resolve.resolvers.some((s) => s.canRead(U)),
- Y = !z;
- let Z,
- ee = stripHash(this.reference.uri) === $,
- ie = !ee;
- this.indirections.push(s);
- try {
- if (z || Y) {
- B = this.toBaseURI($);
- const s = $,
- o = maybeRefractToSchemaElement(L.value.result);
- if (
- ((Z = uri_evaluate(s, o)),
- (Z = maybeRefractToSchemaElement(Z)),
- (Z.id = pS.identify(Z)),
- !this.options.resolve.internal && ee)
- )
- return;
- if (!this.options.resolve.external && ie) return;
- } else {
- if (
- ((B = this.toBaseURI($)),
- (ee = stripHash(this.reference.uri) === B),
- (ie = !ee),
- !this.options.resolve.internal && ee)
- )
- return;
- if (!this.options.resolve.external && ie) return;
- L = await this.toReference(unsanitize($));
- const s = uriToPointer($),
- o = maybeRefractToSchemaElement(L.value.result);
- (Z = es_evaluate(s, o)),
- (Z = maybeRefractToSchemaElement(Z)),
- (Z.id = pS.identify(Z));
- }
- } catch (s) {
- if (!(Y && s instanceof Yw)) throw s;
- if (isAnchor(uriToAnchor($))) {
- if (
- ((ee = stripHash(this.reference.uri) === B),
- (ie = !ee),
- !this.options.resolve.internal && ee)
- )
- return;
- if (!this.options.resolve.external && ie) return;
- L = await this.toReference(unsanitize($));
- const s = uriToAnchor($),
- o = maybeRefractToSchemaElement(L.value.result);
- (Z = $anchor_evaluate(s, o)),
- (Z = maybeRefractToSchemaElement(Z)),
- (Z.id = pS.identify(Z));
- } else {
- if (
- ((B = this.toBaseURI(serializers_value($))),
- (ee = stripHash(this.reference.uri) === B),
- (ie = !ee),
- !this.options.resolve.internal && ee)
- )
- return;
- if (!this.options.resolve.external && ie) return;
- L = await this.toReference(unsanitize($));
- const s = uriToPointer($),
- o = maybeRefractToSchemaElement(L.value.result);
- (Z = es_evaluate(s, o)),
- (Z = maybeRefractToSchemaElement(Z)),
- (Z.id = pS.identify(Z));
- }
- }
- if (s === Z) throw new Ho('Recursive Schema Object reference detected');
- if (this.indirections.length > this.options.dereference.maxDepth)
- throw new Xw(
- `Maximum dereference depth of "${this.options.dereference.maxDepth}" has been exceeded in file "${this.reference.uri}"`
- );
- if (o.includes(Z)) {
- if (((L.refSet.circular = !0), 'error' === this.options.dereference.circular))
- throw new Ho('Circular reference detected');
- if ('replace' === this.options.dereference.circular) {
- var x, C;
- const o = new Cu.sI(Z.id, {
- type: 'json-schema',
- uri: L.uri,
- $ref: serializers_value(s.$ref),
- baseURI: resolve(B, $),
- referencingElement: s
- }),
- u = (
- null !==
- (x =
- null === (C = this.options.dereference.strategyOpts['openapi-3-1']) ||
- void 0 === C
- ? void 0
- : C.circularReplacer) && void 0 !== x
- ? x
- : this.options.dereference.circularReplacer
- )(o);
- return w.replaceWith(u, dereference_mutationReplacer), !i && u;
- }
- }
- const ae = stripHash(L.refSet.rootRef.uri) !== L.uri,
- le = ['error', 'replace'].includes(this.options.dereference.circular);
- if ((ie || ae || (Q_(Z) && Ru(Z.$ref)) || le) && !o.includesCycle(Z)) {
- var j;
- u.add(s);
- const w = new OpenAPI3_1SwaggerClientDereferenceVisitor({
- reference: L,
- namespace: this.namespace,
- indirections: [...this.indirections],
- options: this.options,
- useCircularStructures: this.useCircularStructures,
- allowMetaPatches: this.allowMetaPatches,
- ancestors: o,
- basePath:
- null !== (j = this.basePath) && void 0 !== j
- ? j
- : [...to_path([..._, i, s]), '$ref']
- });
- (Z = await uS(Z, w, {
- keyMap: nw,
- nodeTypeGetter: apidom_ns_openapi_3_1_es_traversal_visitor_getNodeType
- })),
- u.delete(s);
- }
- if ((this.indirections.pop(), predicates_isBooleanJsonSchemaElement(Z))) {
- const o = cloneDeep(Z);
- return (
- o.setMetaProperty('ref-fields', { $ref: serializers_value(s.$ref) }),
- o.setMetaProperty('ref-origin', L.uri),
- o.setMetaProperty('ref-referencing-element-id', cloneDeep(pS.identify(s))),
- w.replaceWith(o, dereference_mutationReplacer),
- !i && o
- );
- }
- if (Q_(Z)) {
- const o = new qb([...Z.content], cloneDeep(Z.meta), cloneDeep(Z.attributes));
- if (
- (s.forEach((s, i, u) => {
- o.remove(serializers_value(i)), o.content.push(u);
- }),
- o.remove('$ref'),
- o.setMetaProperty('ref-fields', { $ref: serializers_value(s.$ref) }),
- o.setMetaProperty('ref-origin', L.uri),
- o.setMetaProperty('ref-referencing-element-id', cloneDeep(pS.identify(s))),
- this.allowMetaPatches && void 0 === o.get('$$ref'))
- ) {
- const s = resolve(B, $);
- o.set('$$ref', s);
- }
- Z = o;
- }
- return w.replaceWith(Z, dereference_mutationReplacer), i ? void 0 : Z;
- } catch (o) {
- var L, B, $;
- const u = get_root_cause(o),
- w = new lS(`Could not resolve reference: ${u.message}`, {
- baseDoc: this.reference.uri,
- $ref: serializers_value(s.$ref),
- fullPath:
- null !== (L = this.basePath) && void 0 !== L
- ? L
- : [...to_path([..._, i, s]), '$ref'],
- cause: u
- });
- return void (
- null === (B = this.options.dereference.dereferenceOpts) ||
- void 0 === B ||
- null === (B = B.errors) ||
- void 0 === B ||
- null === ($ = B.push) ||
- void 0 === $ ||
- $.call(B, w)
- );
- }
- }
- async LinkElement() {}
- async ExampleElement(s, o, i, u, _, w) {
- try {
- return await super.ExampleElement(s, o, i, u, _, w);
- } catch (o) {
- var x, C, j;
- const u = get_root_cause(o),
- w = cS(u, {
- baseDoc: this.reference.uri,
- externalValue: serializers_value(s.externalValue),
- fullPath:
- null !== (x = this.basePath) && void 0 !== x
- ? x
- : [...to_path([..._, i, s]), 'externalValue']
- });
- return void (
- null === (C = this.options.dereference.dereferenceOpts) ||
- void 0 === C ||
- null === (C = C.errors) ||
- void 0 === C ||
- null === (j = C.push) ||
- void 0 === j ||
- j.call(C, w)
- );
- }
- }
- }
- const hS = OpenAPI3_1SwaggerClientDereferenceVisitor,
- dS = mergeAll[Symbol.for('nodejs.util.promisify.custom')];
- const fS = class RootVisitor {
- constructor({ parameterMacro: s, modelPropertyMacro: o, mode: i, options: u, ..._ }) {
- const w = [];
- w.push(new hS({ ..._, options: u })),
- 'function' == typeof o && w.push(new oS({ modelPropertyMacro: o, options: u })),
- 'strict' !== i && w.push(new iS({ options: u })),
- 'function' == typeof s && w.push(new aS({ parameterMacro: s, options: u }));
- const x = dS(w, {
- nodeTypeGetter: apidom_ns_openapi_3_1_es_traversal_visitor_getNodeType
- });
- Object.assign(this, x);
- }
- },
- mS = visitor_visit[Symbol.for('nodejs.util.promisify.custom')];
- const gS = class OpenAPI3_1SwaggerClientDereferenceStrategy extends sS {
- allowMetaPatches;
- parameterMacro;
- modelPropertyMacro;
- mode;
- ancestors;
- constructor({
- allowMetaPatches: s = !1,
- parameterMacro: o = null,
- modelPropertyMacro: i = null,
- mode: u = 'non-strict',
- ancestors: _ = [],
- ...w
- } = {}) {
- super({ ...w }),
- (this.name = 'openapi-3-1-swagger-client'),
- (this.allowMetaPatches = s),
- (this.parameterMacro = o),
- (this.modelPropertyMacro = i),
- (this.mode = u),
- (this.ancestors = [..._]);
- }
- async dereference(s, o) {
- var i;
- const u = createNamespace(ow),
- _ = null !== (i = o.dereference.refSet) && void 0 !== i ? i : new uw(),
- w = new uw();
- let x,
- C = _;
- _.has(s.uri)
- ? (x = _.find((o) => o.uri === s.uri))
- : ((x = new cw({ uri: s.uri, value: s.parseResult })), _.add(x)),
- o.dereference.immutable &&
- (_.refs
- .map((s) => new cw({ ...s, value: cloneDeep(s.value) }))
- .forEach((s) => w.add(s)),
- (x = w.find((o) => o.uri === s.uri)),
- (C = w));
- const j = new fS({
- reference: x,
- namespace: u,
- options: o,
- allowMetaPatches: this.allowMetaPatches,
- ancestors: this.ancestors,
- modelPropertyMacro: this.modelPropertyMacro,
- mode: this.mode,
- parameterMacro: this.parameterMacro
- }),
- L = await mS(C.rootRef.value, j, {
- keyMap: nw,
- nodeTypeGetter: apidom_ns_openapi_3_1_es_traversal_visitor_getNodeType
- });
- return (
- o.dereference.immutable &&
- w.refs
- .filter((s) => s.uri.startsWith('immutable://'))
- .map((s) => new cw({ ...s, uri: s.uri.replace(/^immutable:\/\//, '') }))
- .forEach((s) => _.add(s)),
- null === o.dereference.refSet && _.clean(),
- w.clean(),
- L
- );
- }
- },
- circularReplacer = (s) => {
- const o = serializers_value(s.meta.get('baseURI')),
- i = s.meta.get('referencingElement');
- return new Cu.Sh({ $ref: o }, cloneDeep(i.meta), cloneDeep(i.attributes));
- },
- resolveOpenAPI31Strategy = async (s) => {
- const {
- spec: o,
- timeout: i,
- redirects: u,
- requestInterceptor: _,
- responseInterceptor: w,
- pathDiscriminator: x = [],
- allowMetaPatches: C = !1,
- useCircularStructures: j = !1,
- skipNormalization: L = !1,
- parameterMacro: B = null,
- modelPropertyMacro: $ = null,
- mode: V = 'non-strict',
- strategies: U
- } = s;
- try {
- const { cache: z } = resolveOpenAPI31Strategy,
- Y = U.find((s) => s.match(o)),
- Z = isHttpUrl(url_cwd()) ? url_cwd() : Nc,
- ee = options_retrievalURI(s),
- ie = resolve(Z, ee);
- let ae;
- z.has(o)
- ? (ae = z.get(o))
- : ((ae = wb.refract(o)), ae.classes.push('result'), z.set(o, ae));
- const le = new Mu([ae]),
- ce = es_compile(x),
- pe = '' === ce ? '' : `#${ce}`,
- de = es_evaluate(ce, ae),
- fe = new cw({ uri: ie, value: le }),
- ye = new uw({ refs: [fe] });
- '' !== ce && (ye.rootRef = void 0);
- const be = [new Set([de])],
- _e = [],
- we = await (async (s, o = {}) => {
- const i = util_merge(pw, o);
- return dereferenceApiDOM(s, i);
- })(de, {
- resolve: {
- baseURI: `${ie}${pe}`,
- resolvers: [new Nw({ timeout: i || 1e4, redirects: u || 10 })],
- resolverOpts: {
- swaggerHTTPClientConfig: { requestInterceptor: _, responseInterceptor: w }
- },
- strategies: [new Ow()]
- },
- parse: {
- mediaType: lw.latest(),
- parsers: [
- new Lw({ allowEmpty: !1, sourceMap: !1 }),
- new Bw({ allowEmpty: !1, sourceMap: !1 }),
- new Rw({ allowEmpty: !1, sourceMap: !1 }),
- new Dw({ allowEmpty: !1, sourceMap: !1 }),
- new kw({ allowEmpty: !1, sourceMap: !1 })
- ]
- },
- dereference: {
- maxDepth: 100,
- strategies: [
- new gS({
- allowMetaPatches: C,
- useCircularStructures: j,
- parameterMacro: B,
- modelPropertyMacro: $,
- mode: V,
- ancestors: be
- })
- ],
- refSet: ye,
- dereferenceOpts: { errors: _e },
- immutable: !1,
- circular: j ? 'ignore' : 'replace',
- circularReplacer: j ? pw.dereference.circularReplacer : circularReplacer
- }
- }),
- Se = ((s, o, i) => new xp({ element: i }).transclude(s, o))(de, we, ae),
- xe = L ? Se : Y.normalize(Se);
- return { spec: serializers_value(xe), errors: _e };
- } catch (s) {
- if (s instanceof Wp || s instanceof Kp) return { spec: null, errors: [] };
- throw s;
- }
- };
- resolveOpenAPI31Strategy.cache = new WeakMap();
- const yS = resolveOpenAPI31Strategy;
- function _clone(s, o, i) {
- if (
- (i || (i = new vS()),
- (function _isPrimitive(s) {
- var o = typeof s;
- return null == s || ('object' != o && 'function' != o);
- })(s))
- )
- return s;
- var u = function copy(u) {
- var _ = i.get(s);
- if (_) return _;
- for (var w in (i.set(s, u), s))
- Object.prototype.hasOwnProperty.call(s, w) && (u[w] = o ? _clone(s[w], !0, i) : s[w]);
- return u;
- };
- switch (ea(s)) {
- case 'Object':
- return u(Object.create(Object.getPrototypeOf(s)));
- case 'Array':
- return u(Array(s.length));
- case 'Date':
- return new Date(s.valueOf());
- case 'RegExp':
- return _cloneRegExp(s);
- case 'Int8Array':
- case 'Uint8Array':
- case 'Uint8ClampedArray':
- case 'Int16Array':
- case 'Uint16Array':
- case 'Int32Array':
- case 'Uint32Array':
- case 'Float32Array':
- case 'Float64Array':
- case 'BigInt64Array':
- case 'BigUint64Array':
- return s.slice();
- default:
- return s;
- }
- }
- var vS = (function () {
- function _ObjectMap() {
- (this.map = {}), (this.length = 0);
- }
- return (
- (_ObjectMap.prototype.set = function (s, o) {
- var i = this.hash(s),
- u = this.map[i];
- u || (this.map[i] = u = []), u.push([s, o]), (this.length += 1);
- }),
- (_ObjectMap.prototype.hash = function (s) {
- var o = [];
- for (var i in s) o.push(Object.prototype.toString.call(s[i]));
- return o.join();
- }),
- (_ObjectMap.prototype.get = function (s) {
- if (this.length <= 180)
- for (var o in this.map)
- for (var i = this.map[o], u = 0; u < i.length; u += 1) {
- if ((w = i[u])[0] === s) return w[1];
- }
- else {
- var _ = this.hash(s);
- if ((i = this.map[_]))
- for (u = 0; u < i.length; u += 1) {
- var w;
- if ((w = i[u])[0] === s) return w[1];
- }
- }
- }),
- _ObjectMap
- );
- })(),
- bS = (function () {
- function XReduceBy(s, o, i, u) {
- (this.valueFn = s),
- (this.valueAcc = o),
- (this.keyFn = i),
- (this.xf = u),
- (this.inputs = {});
- }
- return (
- (XReduceBy.prototype['@@transducer/init'] = _xfBase_init),
- (XReduceBy.prototype['@@transducer/result'] = function (s) {
- var o;
- for (o in this.inputs)
- if (
- _has(o, this.inputs) &&
- (s = this.xf['@@transducer/step'](s, this.inputs[o]))['@@transducer/reduced']
- ) {
- s = s['@@transducer/value'];
- break;
- }
- return (this.inputs = null), this.xf['@@transducer/result'](s);
- }),
- (XReduceBy.prototype['@@transducer/step'] = function (s, o) {
- var i = this.keyFn(o);
- return (
- (this.inputs[i] = this.inputs[i] || [i, _clone(this.valueAcc, !1)]),
- (this.inputs[i][1] = this.valueFn(this.inputs[i][1], o)),
- s
- );
- }),
- XReduceBy
- );
- })();
- function _xreduceBy(s, o, i) {
- return function (u) {
- return new bS(s, o, i, u);
- };
- }
- var _S = _curryN(
- 4,
- [],
- _dispatchable([], _xreduceBy, function reduceBy(s, o, i, u) {
- var _ = _xwrap(function (u, _) {
- var w = i(_),
- x = s(_has(w, u) ? u[w] : _clone(o, !1), _);
- return x && x['@@transducer/reduced'] ? _reduced(u) : ((u[w] = x), u);
- });
- return wa(_, {}, u);
- })
- );
- const ES = _curry2(
- _checkForMethod(
- 'groupBy',
- _S(function (s, o) {
- return s.push(o), s;
- }, [])
- )
- );
- const wS = class NormalizeStorage {
- internalStore;
- constructor(s, o, i) {
- (this.storageElement = s), (this.storageField = o), (this.storageSubField = i);
- }
- get store() {
- if (!this.internalStore) {
- let s = this.storageElement.get(this.storageField);
- Fu(s) || ((s = new Cu.Sh()), this.storageElement.set(this.storageField, s));
- let o = s.get(this.storageSubField);
- qu(o) || ((o = new Cu.wE()), s.set(this.storageSubField, o)),
- (this.internalStore = o);
- }
- return this.internalStore;
- }
- append(s) {
- this.includes(s) || this.store.push(s);
- }
- includes(s) {
- return this.store.includes(s);
- }
- },
- removeSpaces = (s) => s.replace(/\s/g, ''),
- normalize_operation_ids_replaceSpecialCharsWithUnderscore = (s) => s.replace(/\W/gi, '_'),
- normalizeOperationId = (s, o, i) => {
- const u = removeSpaces(s);
- return u.length > 0
- ? normalize_operation_ids_replaceSpecialCharsWithUnderscore(u)
- : ((s, o) =>
- `${normalize_operation_ids_replaceSpecialCharsWithUnderscore(removeSpaces(o.toLowerCase()))}${normalize_operation_ids_replaceSpecialCharsWithUnderscore(removeSpaces(s))}`)(
- o,
- i
- );
- },
- normalize_operation_ids =
- ({
- storageField: s = 'x-normalized',
- operationIdNormalizer: o = normalizeOperationId
- } = {}) =>
- (i) => {
- const { predicates: u, ancestorLineageToJSONPointer: _, namespace: w } = i,
- x = [],
- C = [],
- j = [];
- let L;
- return {
- visitor: {
- OpenApi3_1Element: {
- enter(o) {
- L = new wS(o, s, 'operation-ids');
- },
- leave() {
- const s = ES((s) => serializers_value(s.operationId), C);
- Object.entries(s).forEach(([s, o]) => {
- Array.isArray(o) &&
- (o.length <= 1 ||
- o.forEach((o, i) => {
- const u = `${s}${i + 1}`;
- o.operationId = new w.elements.String(u);
- }));
- }),
- j.forEach((s) => {
- if (void 0 === s.operationId) return;
- const o = String(serializers_value(s.operationId)),
- i = C.find(
- (s) => serializers_value(s.meta.get('originalOperationId')) === o
- );
- void 0 !== i &&
- ((s.operationId = cloneDeep.safe(i.operationId)),
- s.meta.set('originalOperationId', o),
- s.set('__originalOperationId', o));
- }),
- (C.length = 0),
- (j.length = 0),
- (L = void 0);
- }
- },
- PathItemElement: {
- enter(s) {
- const o = Na('path', serializers_value(s.meta.get('path')));
- x.push(o);
- },
- leave() {
- x.pop();
- }
- },
- OperationElement: {
- enter(s, i, u, j, B) {
- if (void 0 === s.operationId) return;
- const $ = _([...B, u, s]);
- if (L.includes($)) return;
- const V = String(serializers_value(s.operationId)),
- U = Fa(x),
- z = Na('method', serializers_value(s.meta.get('http-method'))),
- Y = o(V, U, z);
- V !== Y &&
- ((s.operationId = new w.elements.String(Y)),
- s.set('__originalOperationId', V),
- s.meta.set('originalOperationId', V),
- C.push(s),
- L.append($));
- }
- },
- LinkElement: {
- leave(s) {
- u.isLinkElement(s) && void 0 !== s.operationId && j.push(s);
- }
- }
- }
- };
- };
- var SS = (function () {
- function XUniqWith(s, o) {
- (this.xf = o), (this.pred = s), (this.items = []);
- }
- return (
- (XUniqWith.prototype['@@transducer/init'] = _xfBase_init),
- (XUniqWith.prototype['@@transducer/result'] = _xfBase_result),
- (XUniqWith.prototype['@@transducer/step'] = function (s, o) {
- return _includesWith(this.pred, o, this.items)
- ? s
- : (this.items.push(o), this.xf['@@transducer/step'](s, o));
- }),
- XUniqWith
- );
- })();
- function _xuniqWith(s) {
- return function (o) {
- return new SS(s, o);
- };
- }
- var xS = _curry2(
- _dispatchable([], _xuniqWith, function (s, o) {
- for (var i, u = 0, _ = o.length, w = []; u < _; )
- _includesWith(s, (i = o[u]), w) || (w[w.length] = i), (u += 1);
- return w;
- })
- );
- const kS = xS,
- normalize_parameters =
- ({ storageField: s = 'x-normalized' } = {}) =>
- (o) => {
- const { predicates: i, ancestorLineageToJSONPointer: u } = o,
- parameterEquals = (s, o) =>
- !!i.isParameterElement(s) &&
- !!i.isParameterElement(o) &&
- !!i.isStringElement(s.name) &&
- !!i.isStringElement(s.in) &&
- !!i.isStringElement(o.name) &&
- !!i.isStringElement(o.in) &&
- serializers_value(s.name) === serializers_value(o.name) &&
- serializers_value(s.in) === serializers_value(o.in),
- _ = [];
- let w;
- return {
- visitor: {
- OpenApi3_1Element: {
- enter(o) {
- w = new wS(o, s, 'parameters');
- },
- leave() {
- w = void 0;
- }
- },
- PathItemElement: {
- enter(s, o, u, w, x) {
- if (x.some(i.isComponentsElement)) return;
- const { parameters: C } = s;
- i.isArrayElement(C) ? _.push([...C.content]) : _.push([]);
- },
- leave() {
- _.pop();
- }
- },
- OperationElement: {
- leave(s, o, i, x, C) {
- const j = Fa(_);
- if (!Array.isArray(j) || 0 === j.length) return;
- const L = u([...C, i, s]);
- if (w.includes(L)) return;
- const B = Ww([], ['parameters', 'content'], s),
- $ = kS(parameterEquals, [...B, ...j]);
- (s.parameters = new yv($)), w.append(L);
- }
- }
- }
- };
- },
- normalize_security_requirements =
- ({ storageField: s = 'x-normalized' } = {}) =>
- (o) => {
- const { predicates: i, ancestorLineageToJSONPointer: u } = o;
- let _, w;
- return {
- visitor: {
- OpenApi3_1Element: {
- enter(o) {
- (w = new wS(o, s, 'security-requirements')),
- i.isArrayElement(o.security) && (_ = o.security);
- },
- leave() {
- (w = void 0), (_ = void 0);
- }
- },
- OperationElement: {
- leave(s, o, x, C, j) {
- if (j.some(i.isComponentsElement)) return;
- const L = u([...j, x, s]);
- if (w.includes(L)) return;
- var B;
- void 0 === s.security &&
- void 0 !== _ &&
- ((s.security = new Sv(
- null === (B = _) || void 0 === B ? void 0 : B.content
- )),
- w.append(L));
- }
- }
- }
- };
- },
- normalize_parameter_examples =
- ({ storageField: s = 'x-normalized' } = {}) =>
- (o) => {
- const { predicates: i, ancestorLineageToJSONPointer: u } = o;
- let _;
- return {
- visitor: {
- OpenApi3_1Element: {
- enter(o) {
- _ = new wS(o, s, 'parameter-examples');
- },
- leave() {
- _ = void 0;
- }
- },
- ParameterElement: {
- leave(s, o, w, x, C) {
- var j, L;
- if (C.some(i.isComponentsElement)) return;
- if (void 0 === s.schema || !i.isSchemaElement(s.schema)) return;
- if (
- void 0 === (null === (j = s.schema) || void 0 === j ? void 0 : j.example) &&
- void 0 === (null === (L = s.schema) || void 0 === L ? void 0 : L.examples)
- )
- return;
- const B = u([...C, w, s]);
- if (!_.includes(B)) {
- if (void 0 !== s.examples && i.isObjectElement(s.examples)) {
- const o = s.examples.map((s) => cloneDeep.safe(s.value));
- return (
- void 0 !== s.schema.examples &&
- (s.schema.set('examples', o), _.append(B)),
- void (
- void 0 !== s.schema.example &&
- (s.schema.set('example', o[0]), _.append(B))
- )
- );
- }
- void 0 !== s.example &&
- (void 0 !== s.schema.examples &&
- (s.schema.set('examples', [cloneDeep(s.example)]), _.append(B)),
- void 0 !== s.schema.example &&
- (s.schema.set('example', cloneDeep(s.example)), _.append(B)));
- }
- }
- }
- }
- };
- },
- normalize_header_examples =
- ({ storageField: s = 'x-normalized' } = {}) =>
- (o) => {
- const { predicates: i, ancestorLineageToJSONPointer: u } = o;
- let _;
- return {
- visitor: {
- OpenApi3_1Element: {
- enter(o) {
- _ = new wS(o, s, 'header-examples');
- },
- leave() {
- _ = void 0;
- }
- },
- HeaderElement: {
- leave(s, o, w, x, C) {
- var j, L;
- if (C.some(i.isComponentsElement)) return;
- if (void 0 === s.schema || !i.isSchemaElement(s.schema)) return;
- if (
- void 0 === (null === (j = s.schema) || void 0 === j ? void 0 : j.example) &&
- void 0 === (null === (L = s.schema) || void 0 === L ? void 0 : L.examples)
- )
- return;
- const B = u([...C, w, s]);
- if (!_.includes(B)) {
- if (void 0 !== s.examples && i.isObjectElement(s.examples)) {
- const o = s.examples.map((s) => cloneDeep.safe(s.value));
- return (
- void 0 !== s.schema.examples &&
- (s.schema.set('examples', o), _.append(B)),
- void (
- void 0 !== s.schema.example &&
- (s.schema.set('example', o[0]), _.append(B))
- )
- );
- }
- void 0 !== s.example &&
- (void 0 !== s.schema.examples &&
- (s.schema.set('examples', [cloneDeep(s.example)]), _.append(B)),
- void 0 !== s.schema.example &&
- (s.schema.set('example', cloneDeep(s.example)), _.append(B)));
- }
- }
- }
- }
- };
- },
- openapi_3_1_apidom_normalize = (s) => {
- if (!Fu(s)) return s;
- const o = [
- normalize_operation_ids({
- operationIdNormalizer: (s, o, i) =>
- opId({ operationId: s }, o, i, { v2OperationIdCompatibilityMode: !1 })
- }),
- normalize_parameters(),
- normalize_security_requirements(),
- normalize_parameter_examples(),
- normalize_header_examples()
- ];
- return dispatchPluginsSync(s, o, {
- toolboxCreator: apidom_ns_openapi_3_1_es_refractor_toolbox,
- visitorOptions: {
- keyMap: nw,
- nodeTypeGetter: apidom_ns_openapi_3_1_es_traversal_visitor_getNodeType
- }
- });
- },
- CS = {
- name: 'openapi-3-1-apidom',
- match: (s) => isOpenAPI31(s),
- normalize(s) {
- if (!Nu(s) && ku(s) && !s.$$normalized) {
- const i = ((o = openapi_3_1_apidom_normalize),
- (s) => {
- const i = wb.refract(s);
- i.classes.push('result');
- const u = o(i),
- _ = serializers_value(u);
- return yS.cache.set(_, u), serializers_value(u);
- })(s);
- return (i.$$normalized = !0), i;
- }
- var o;
- return Nu(s) ? openapi_3_1_apidom_normalize(s) : s;
- },
- resolve: async (s) => yS(s)
- },
- OS = CS,
- makeResolve = (s) => async (o) =>
- (async (s) => {
- const { spec: o, requestInterceptor: i, responseInterceptor: u } = s,
- _ = options_retrievalURI(s),
- w = options_httpClient(s),
- x =
- o ||
- (await makeFetchJSON(w, { requestInterceptor: i, responseInterceptor: u })(_)),
- C = { ...s, spec: x };
- return s.strategies.find((s) => s.match(x)).resolve(C);
- })({ ...s, ...o }),
- AS = makeResolve({ strategies: [fu, hu, uu] });
- var jS = __webpack_require__(69883);
- const IS = function fnparser() {
- const s = TS,
- o = MS,
- i = this,
- u = 'parser.js: Parser(): ';
- (i.ast = void 0), (i.stats = void 0), (i.trace = void 0), (i.callbacks = []);
- let _,
- w,
- x,
- C,
- j,
- L,
- B,
- $ = 0,
- V = 0,
- U = 0,
- z = 0,
- Y = 0,
- Z = new (function systemData() {
- (this.state = s.ACTIVE),
- (this.phraseLength = 0),
- (this.refresh = () => {
- (this.state = s.ACTIVE), (this.phraseLength = 0);
- });
- })();
- i.parse = (ee, ie, ae, le) => {
- const ce = `${u}parse(): `;
- ($ = 0),
- (V = 0),
- (U = 0),
- (z = 0),
- (Y = 0),
- (_ = void 0),
- (w = void 0),
- (x = void 0),
- (C = void 0),
- Z.refresh(),
- (j = void 0),
- (L = void 0),
- (B = void 0),
- (C = o.stringToChars(ae)),
- (_ = ee.rules),
- (w = ee.udts);
- const pe = ie.toLowerCase();
- let de;
- for (const s in _)
- if (_.hasOwnProperty(s) && pe === _[s].lower) {
- de = _[s].index;
- break;
- }
- if (void 0 === de)
- throw new Error(`${ce}start rule name '${startRule}' not recognized`);
- (() => {
- const s = `${u}initializeCallbacks(): `;
- let o, x;
- for (j = [], L = [], o = 0; o < _.length; o += 1) j[o] = void 0;
- for (o = 0; o < w.length; o += 1) L[o] = void 0;
- const C = [];
- for (o = 0; o < _.length; o += 1) C.push(_[o].lower);
- for (o = 0; o < w.length; o += 1) C.push(w[o].lower);
- for (const u in i.callbacks)
- if (i.callbacks.hasOwnProperty(u)) {
- if (((o = C.indexOf(u.toLowerCase())), o < 0))
- throw new Error(`${s}syntax callback '${u}' not a rule or udt name`);
- if (
- ((x = i.callbacks[u] ? i.callbacks[u] : void 0),
- 'function' != typeof x && void 0 !== x)
- )
- throw new Error(
- `${s}syntax callback[${u}] must be function reference or falsy)`
- );
- o < _.length ? (j[o] = x) : (L[o - _.length] = x);
- }
- })(),
- i.trace && i.trace.init(_, w, C),
- i.stats && i.stats.init(_, w),
- i.ast && i.ast.init(_, w, C),
- (B = le),
- (x = [{ type: s.RNM, index: de }]),
- opExecute(0, 0),
- (x = void 0);
- let fe = !1;
- switch (Z.state) {
- case s.ACTIVE:
- throw new Error(`${ce}final state should never be 'ACTIVE'`);
- case s.NOMATCH:
- fe = !1;
- break;
- case s.EMPTY:
- case s.MATCH:
- fe = Z.phraseLength === C.length;
- break;
- default:
- throw new Error('unrecognized state');
- }
- return {
- success: fe,
- state: Z.state,
- stateName: s.idName(Z.state),
- length: C.length,
- matched: Z.phraseLength,
- maxMatched: Y,
- maxTreeDepth: U,
- nodeHits: z
- };
- };
- const validateRnmCallbackResult = (o, i, _, w) => {
- if (i.phraseLength > _) {
- let s = `${u}opRNM(${o.name}): callback function error: `;
- throw (
- ((s += `sysData.phraseLength: ${i.phraseLength}`),
- (s += ` must be <= remaining chars: ${_}`),
- new Error(s))
- );
- }
- switch (i.state) {
- case s.ACTIVE:
- if (!w)
- throw new Error(
- `${u}opRNM(${o.name}): callback function return error. ACTIVE state not allowed.`
- );
- break;
- case s.EMPTY:
- i.phraseLength = 0;
- break;
- case s.MATCH:
- 0 === i.phraseLength && (i.state = s.EMPTY);
- break;
- case s.NOMATCH:
- i.phraseLength = 0;
- break;
- default:
- throw new Error(
- `${u}opRNM(${o.name}): callback function return error. Unrecognized return state: ${i.state}`
- );
- }
- },
- opUDT = (o, j) => {
- let V, U, z;
- const Y = x[o],
- ee = w[Y.index];
- (Z.UdtIndex = ee.index),
- $ ||
- ((z = i.ast && i.ast.udtDefined(Y.index)),
- z &&
- ((U = _.length + Y.index), (V = i.ast.getLength()), i.ast.down(U, ee.name)));
- const ie = C.length - j;
- L[Y.index](Z, C, j, B),
- ((o, i, _) => {
- if (i.phraseLength > _) {
- let s = `${u}opUDT(${o.name}): callback function error: `;
- throw (
- ((s += `sysData.phraseLength: ${i.phraseLength}`),
- (s += ` must be <= remaining chars: ${_}`),
- new Error(s))
- );
- }
- switch (i.state) {
- case s.ACTIVE:
- throw new Error(`${u}opUDT(${o.name}) ACTIVE state return not allowed.`);
- case s.EMPTY:
- if (!o.empty) throw new Error(`${u}opUDT(${o.name}) may not return EMPTY.`);
- i.phraseLength = 0;
- break;
- case s.MATCH:
- if (0 === i.phraseLength) {
- if (!o.empty)
- throw new Error(`${u}opUDT(${o.name}) may not return EMPTY.`);
- i.state = s.EMPTY;
- }
- break;
- case s.NOMATCH:
- i.phraseLength = 0;
- break;
- default:
- throw new Error(
- `${u}opUDT(${o.name}): callback function return error. Unrecognized return state: ${i.state}`
- );
- }
- })(ee, Z, ie),
- $ ||
- (z &&
- (Z.state === s.NOMATCH
- ? i.ast.setLength(V)
- : i.ast.up(U, ee.name, j, Z.phraseLength)));
- },
- opExecute = (o, w) => {
- const L = `${u}opExecute(): `,
- ee = x[o];
- switch (
- ((z += 1),
- V > U && (U = V),
- (V += 1),
- Z.refresh(),
- i.trace && i.trace.down(ee, w),
- ee.type)
- ) {
- case s.ALT:
- ((o, i) => {
- const u = x[o];
- for (
- let o = 0;
- o < u.children.length &&
- (opExecute(u.children[o], i), Z.state === s.NOMATCH);
- o += 1
- );
- })(o, w);
- break;
- case s.CAT:
- ((o, u) => {
- let _, w, C, j;
- const L = x[o];
- i.ast && (w = i.ast.getLength()), (_ = !0), (C = u), (j = 0);
- for (let o = 0; o < L.children.length; o += 1) {
- if ((opExecute(L.children[o], C), Z.state === s.NOMATCH)) {
- _ = !1;
- break;
- }
- (C += Z.phraseLength), (j += Z.phraseLength);
- }
- _
- ? ((Z.state = 0 === j ? s.EMPTY : s.MATCH), (Z.phraseLength = j))
- : ((Z.state = s.NOMATCH),
- (Z.phraseLength = 0),
- i.ast && i.ast.setLength(w));
- })(o, w);
- break;
- case s.REP:
- ((o, u) => {
- let _, w, j, L;
- const B = x[o];
- if (0 === B.max) return (Z.state = s.EMPTY), void (Z.phraseLength = 0);
- for (
- w = u, j = 0, L = 0, i.ast && (_ = i.ast.getLength());
- !(w >= C.length) &&
- (opExecute(o + 1, w), Z.state !== s.NOMATCH) &&
- Z.state !== s.EMPTY &&
- ((L += 1), (j += Z.phraseLength), (w += Z.phraseLength), L !== B.max);
- );
- Z.state === s.EMPTY || L >= B.min
- ? ((Z.state = 0 === j ? s.EMPTY : s.MATCH), (Z.phraseLength = j))
- : ((Z.state = s.NOMATCH),
- (Z.phraseLength = 0),
- i.ast && i.ast.setLength(_));
- })(o, w);
- break;
- case s.RNM:
- ((o, u) => {
- let w, L, V;
- const U = x[o],
- z = _[U.index],
- Y = j[z.index];
- if (
- ($ ||
- ((L = i.ast && i.ast.ruleDefined(U.index)),
- L && ((w = i.ast.getLength()), i.ast.down(U.index, _[U.index].name))),
- Y)
- ) {
- const o = C.length - u;
- Y(Z, C, u, B),
- validateRnmCallbackResult(z, Z, o, !0),
- Z.state === s.ACTIVE &&
- ((V = x),
- (x = z.opcodes),
- opExecute(0, u),
- (x = V),
- Y(Z, C, u, B),
- validateRnmCallbackResult(z, Z, o, !1));
- } else (V = x), (x = z.opcodes), opExecute(0, u, Z), (x = V);
- $ ||
- (L &&
- (Z.state === s.NOMATCH
- ? i.ast.setLength(w)
- : i.ast.up(U.index, z.name, u, Z.phraseLength)));
- })(o, w);
- break;
- case s.TRG:
- ((o, i) => {
- const u = x[o];
- (Z.state = s.NOMATCH),
- i < C.length &&
- u.min <= C[i] &&
- C[i] <= u.max &&
- ((Z.state = s.MATCH), (Z.phraseLength = 1));
- })(o, w);
- break;
- case s.TBS:
- ((o, i) => {
- const u = x[o],
- _ = u.string.length;
- if (((Z.state = s.NOMATCH), i + _ <= C.length)) {
- for (let s = 0; s < _; s += 1) if (C[i + s] !== u.string[s]) return;
- (Z.state = s.MATCH), (Z.phraseLength = _);
- }
- })(o, w);
- break;
- case s.TLS:
- ((o, i) => {
- let u;
- const _ = x[o];
- Z.state = s.NOMATCH;
- const w = _.string.length;
- if (0 !== w) {
- if (i + w <= C.length) {
- for (let s = 0; s < w; s += 1)
- if (
- ((u = C[i + s]), u >= 65 && u <= 90 && (u += 32), u !== _.string[s])
- )
- return;
- (Z.state = s.MATCH), (Z.phraseLength = w);
- }
- } else Z.state = s.EMPTY;
- })(o, w);
- break;
- case s.UDT:
- opUDT(o, w);
- break;
- case s.AND:
- ((o, i) => {
- switch (
- (($ += 1), opExecute(o + 1, i), ($ -= 1), (Z.phraseLength = 0), Z.state)
- ) {
- case s.EMPTY:
- case s.MATCH:
- Z.state = s.EMPTY;
- break;
- case s.NOMATCH:
- Z.state = s.NOMATCH;
- break;
- default:
- throw new Error(`opAND: invalid state ${Z.state}`);
- }
- })(o, w);
- break;
- case s.NOT:
- ((o, i) => {
- switch (
- (($ += 1), opExecute(o + 1, i), ($ -= 1), (Z.phraseLength = 0), Z.state)
- ) {
- case s.EMPTY:
- case s.MATCH:
- Z.state = s.NOMATCH;
- break;
- case s.NOMATCH:
- Z.state = s.EMPTY;
- break;
- default:
- throw new Error(`opNOT: invalid state ${Z.state}`);
- }
- })(o, w);
- break;
- default:
- throw new Error(`${L}unrecognized operator`);
- }
- $ || (w + Z.phraseLength > Y && (Y = w + Z.phraseLength)),
- i.stats && i.stats.collect(ee, Z),
- i.trace && i.trace.up(ee, Z.state, w, Z.phraseLength),
- (V -= 1);
- };
- },
- PS = function fnast() {
- const s = TS,
- o = MS,
- i = this;
- let u,
- _,
- w,
- x = 0;
- const C = [],
- j = [],
- L = [];
- function indent(s) {
- let o = '';
- for (; s-- > 0; ) o += ' ';
- return o;
- }
- (i.callbacks = []),
- (i.init = (s, o, B) => {
- let $;
- (j.length = 0), (L.length = 0), (x = 0), (u = s), (_ = o), (w = B);
- const V = [];
- for ($ = 0; $ < u.length; $ += 1) V.push(u[$].lower);
- for ($ = 0; $ < _.length; $ += 1) V.push(_[$].lower);
- for (x = u.length + _.length, $ = 0; $ < x; $ += 1) C[$] = void 0;
- for (const s in i.callbacks)
- if (i.callbacks.hasOwnProperty(s)) {
- const o = s.toLowerCase();
- if ((($ = V.indexOf(o)), $ < 0))
- throw new Error(
- `parser.js: Ast()): init: node '${s}' not a rule or udt name`
- );
- C[$] = i.callbacks[s];
- }
- }),
- (i.ruleDefined = (s) => !!C[s]),
- (i.udtDefined = (s) => !!C[u.length + s]),
- (i.down = (o, i) => {
- const u = L.length;
- return (
- j.push(u),
- L.push({
- name: i,
- thisIndex: u,
- thatIndex: void 0,
- state: s.SEM_PRE,
- callbackIndex: o,
- phraseIndex: void 0,
- phraseLength: void 0,
- stack: j.length
- }),
- u
- );
- }),
- (i.up = (o, i, u, _) => {
- const w = L.length,
- x = j.pop();
- return (
- L.push({
- name: i,
- thisIndex: w,
- thatIndex: x,
- state: s.SEM_POST,
- callbackIndex: o,
- phraseIndex: u,
- phraseLength: _,
- stack: j.length
- }),
- (L[x].thatIndex = w),
- (L[x].phraseIndex = u),
- (L[x].phraseLength = _),
- w
- );
- }),
- (i.translate = (o) => {
- let i, u;
- for (let _ = 0; _ < L.length; _ += 1)
- (u = L[_]),
- (i = C[u.callbackIndex]),
- i &&
- (u.state === s.SEM_PRE
- ? i(s.SEM_PRE, w, u.phraseIndex, u.phraseLength, o)
- : i && i(s.SEM_POST, w, u.phraseIndex, u.phraseLength, o));
- }),
- (i.setLength = (s) => {
- (L.length = s), (j.length = s > 0 ? L[s - 1].stack : 0);
- }),
- (i.getLength = () => L.length),
- (i.toXml = () => {
- let i = '',
- u = 0;
- return (
- (i += '<?xml version="1.0" encoding="utf-8"?>\n'),
- (i += `<root nodes="${L.length / 2}" characters="${w.length}">\n`),
- (i += '\x3c!-- input string --\x3e\n'),
- (i += indent(u + 2)),
- (i += o.charsToString(w)),
- (i += '\n'),
- L.forEach((_) => {
- _.state === s.SEM_PRE
- ? ((u += 1),
- (i += indent(u)),
- (i += `<node name="${_.name}" index="${_.phraseIndex}" length="${_.phraseLength}">\n`),
- (i += indent(u + 2)),
- (i += o.charsToString(w, _.phraseIndex, _.phraseLength)),
- (i += '\n'))
- : ((i += indent(u)),
- (i += `</node>\x3c!-- name="${_.name}" --\x3e\n`),
- (u -= 1));
- }),
- (i += '</root>\n'),
- i
- );
- });
- },
- MS = {
- stringToChars: (s) => [...s].map((s) => s.codePointAt(0)),
- charsToString: (s, o, i) => {
- let u = s;
- for (; !(void 0 === o || o < 0); ) {
- if (void 0 === i) {
- u = s.slice(o);
- break;
- }
- if (i <= 0) return '';
- u = s.slice(o, o + i);
- break;
- }
- return String.fromCodePoint(...u);
- }
- },
- TS = {
- ALT: 1,
- CAT: 2,
- REP: 3,
- RNM: 4,
- TRG: 5,
- TBS: 6,
- TLS: 7,
- UDT: 11,
- AND: 12,
- NOT: 13,
- ACTIVE: 100,
- MATCH: 101,
- EMPTY: 102,
- NOMATCH: 103,
- SEM_PRE: 200,
- SEM_POST: 201,
- SEM_OK: 300,
- idName: (s) => {
- switch (s) {
- case TS.ALT:
- return 'ALT';
- case TS.CAT:
- return 'CAT';
- case TS.REP:
- return 'REP';
- case TS.RNM:
- return 'RNM';
- case TS.TRG:
- return 'TRG';
- case TS.TBS:
- return 'TBS';
- case TS.TLS:
- return 'TLS';
- case TS.UDT:
- return 'UDT';
- case TS.AND:
- return 'AND';
- case TS.NOT:
- return 'NOT';
- case TS.ACTIVE:
- return 'ACTIVE';
- case TS.EMPTY:
- return 'EMPTY';
- case TS.MATCH:
- return 'MATCH';
- case TS.NOMATCH:
- return 'NOMATCH';
- case TS.SEM_PRE:
- return 'SEM_PRE';
- case TS.SEM_POST:
- return 'SEM_POST';
- case TS.SEM_OK:
- return 'SEM_OK';
- default:
- return 'UNRECOGNIZED STATE';
- }
- }
- };
- const server_url_template = (s, o, i, u, _) => {
- if (s === TS.SEM_PRE) {
- if (!1 === Array.isArray(_)) throw new Error("parser's user data must be an array");
- _.push(['server-url-template', MS.charsToString(o, i, u)]);
- }
- return TS.SEM_OK;
- },
- callbacks_server_variable = (s, o, i, u, _) => {
- if (s === TS.SEM_PRE) {
- if (!1 === Array.isArray(_)) throw new Error("parser's user data must be an array");
- _.push(['server-variable', MS.charsToString(o, i, u)]);
- }
- return TS.SEM_OK;
- },
- server_variable_name = (s, o, i, u, _) => {
- if (s === TS.SEM_PRE) {
- if (!1 === Array.isArray(_)) throw new Error("parser's user data must be an array");
- _.push(['server-variable-name', MS.charsToString(o, i, u)]);
- }
- return TS.SEM_OK;
- },
- callbacks_literals = (s, o, i, u, _) => {
- if (s === TS.SEM_PRE) {
- if (!1 === Array.isArray(_)) throw new Error("parser's user data must be an array");
- _.push(['literals', MS.charsToString(o, i, u)]);
- }
- return TS.SEM_OK;
- },
- NS = new (function grammar() {
- (this.grammarObject = 'grammarObject'),
- (this.rules = []),
- (this.rules[0] = {
- name: 'server-url-template',
- lower: 'server-url-template',
- index: 0,
- isBkr: !1
- }),
- (this.rules[1] = {
- name: 'server-variable',
- lower: 'server-variable',
- index: 1,
- isBkr: !1
- }),
- (this.rules[2] = {
- name: 'server-variable-name',
- lower: 'server-variable-name',
- index: 2,
- isBkr: !1
- }),
- (this.rules[3] = { name: 'literals', lower: 'literals', index: 3, isBkr: !1 }),
- (this.rules[4] = { name: 'ALPHA', lower: 'alpha', index: 4, isBkr: !1 }),
- (this.rules[5] = { name: 'DIGIT', lower: 'digit', index: 5, isBkr: !1 }),
- (this.rules[6] = { name: 'HEXDIG', lower: 'hexdig', index: 6, isBkr: !1 }),
- (this.rules[7] = { name: 'pct-encoded', lower: 'pct-encoded', index: 7, isBkr: !1 }),
- (this.rules[8] = { name: 'unreserved', lower: 'unreserved', index: 8, isBkr: !1 }),
- (this.rules[9] = { name: 'sub-delims', lower: 'sub-delims', index: 9, isBkr: !1 }),
- (this.rules[10] = { name: 'ucschar', lower: 'ucschar', index: 10, isBkr: !1 }),
- (this.rules[11] = { name: 'iprivate', lower: 'iprivate', index: 11, isBkr: !1 }),
- (this.udts = []),
- (this.rules[0].opcodes = []),
- (this.rules[0].opcodes[0] = { type: 3, min: 1, max: 1 / 0 }),
- (this.rules[0].opcodes[1] = { type: 1, children: [2, 3] }),
- (this.rules[0].opcodes[2] = { type: 4, index: 3 }),
- (this.rules[0].opcodes[3] = { type: 4, index: 1 }),
- (this.rules[1].opcodes = []),
- (this.rules[1].opcodes[0] = { type: 2, children: [1, 2, 3] }),
- (this.rules[1].opcodes[1] = { type: 7, string: [123] }),
- (this.rules[1].opcodes[2] = { type: 4, index: 2 }),
- (this.rules[1].opcodes[3] = { type: 7, string: [125] }),
- (this.rules[2].opcodes = []),
- (this.rules[2].opcodes[0] = { type: 3, min: 1, max: 1 / 0 }),
- (this.rules[2].opcodes[1] = { type: 1, children: [2, 3, 4, 5, 6] }),
- (this.rules[2].opcodes[2] = { type: 4, index: 8 }),
- (this.rules[2].opcodes[3] = { type: 4, index: 7 }),
- (this.rules[2].opcodes[4] = { type: 4, index: 9 }),
- (this.rules[2].opcodes[5] = { type: 7, string: [58] }),
- (this.rules[2].opcodes[6] = { type: 7, string: [64] }),
- (this.rules[3].opcodes = []),
- (this.rules[3].opcodes[0] = { type: 3, min: 1, max: 1 / 0 }),
- (this.rules[3].opcodes[1] = {
- type: 1,
- children: [2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]
- }),
- (this.rules[3].opcodes[2] = { type: 6, string: [33] }),
- (this.rules[3].opcodes[3] = { type: 5, min: 35, max: 36 }),
- (this.rules[3].opcodes[4] = { type: 6, string: [38] }),
- (this.rules[3].opcodes[5] = { type: 5, min: 40, max: 59 }),
- (this.rules[3].opcodes[6] = { type: 6, string: [61] }),
- (this.rules[3].opcodes[7] = { type: 5, min: 63, max: 91 }),
- (this.rules[3].opcodes[8] = { type: 6, string: [93] }),
- (this.rules[3].opcodes[9] = { type: 6, string: [95] }),
- (this.rules[3].opcodes[10] = { type: 5, min: 97, max: 122 }),
- (this.rules[3].opcodes[11] = { type: 6, string: [126] }),
- (this.rules[3].opcodes[12] = { type: 4, index: 10 }),
- (this.rules[3].opcodes[13] = { type: 4, index: 11 }),
- (this.rules[3].opcodes[14] = { type: 4, index: 7 }),
- (this.rules[4].opcodes = []),
- (this.rules[4].opcodes[0] = { type: 1, children: [1, 2] }),
- (this.rules[4].opcodes[1] = { type: 5, min: 65, max: 90 }),
- (this.rules[4].opcodes[2] = { type: 5, min: 97, max: 122 }),
- (this.rules[5].opcodes = []),
- (this.rules[5].opcodes[0] = { type: 5, min: 48, max: 57 }),
- (this.rules[6].opcodes = []),
- (this.rules[6].opcodes[0] = { type: 1, children: [1, 2, 3, 4, 5, 6, 7] }),
- (this.rules[6].opcodes[1] = { type: 4, index: 5 }),
- (this.rules[6].opcodes[2] = { type: 7, string: [97] }),
- (this.rules[6].opcodes[3] = { type: 7, string: [98] }),
- (this.rules[6].opcodes[4] = { type: 7, string: [99] }),
- (this.rules[6].opcodes[5] = { type: 7, string: [100] }),
- (this.rules[6].opcodes[6] = { type: 7, string: [101] }),
- (this.rules[6].opcodes[7] = { type: 7, string: [102] }),
- (this.rules[7].opcodes = []),
- (this.rules[7].opcodes[0] = { type: 2, children: [1, 2, 3] }),
- (this.rules[7].opcodes[1] = { type: 7, string: [37] }),
- (this.rules[7].opcodes[2] = { type: 4, index: 6 }),
- (this.rules[7].opcodes[3] = { type: 4, index: 6 }),
- (this.rules[8].opcodes = []),
- (this.rules[8].opcodes[0] = { type: 1, children: [1, 2, 3, 4, 5, 6] }),
- (this.rules[8].opcodes[1] = { type: 4, index: 4 }),
- (this.rules[8].opcodes[2] = { type: 4, index: 5 }),
- (this.rules[8].opcodes[3] = { type: 7, string: [45] }),
- (this.rules[8].opcodes[4] = { type: 7, string: [46] }),
- (this.rules[8].opcodes[5] = { type: 7, string: [95] }),
- (this.rules[8].opcodes[6] = { type: 7, string: [126] }),
- (this.rules[9].opcodes = []),
- (this.rules[9].opcodes[0] = {
- type: 1,
- children: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]
- }),
- (this.rules[9].opcodes[1] = { type: 7, string: [33] }),
- (this.rules[9].opcodes[2] = { type: 7, string: [36] }),
- (this.rules[9].opcodes[3] = { type: 7, string: [38] }),
- (this.rules[9].opcodes[4] = { type: 7, string: [39] }),
- (this.rules[9].opcodes[5] = { type: 7, string: [40] }),
- (this.rules[9].opcodes[6] = { type: 7, string: [41] }),
- (this.rules[9].opcodes[7] = { type: 7, string: [42] }),
- (this.rules[9].opcodes[8] = { type: 7, string: [43] }),
- (this.rules[9].opcodes[9] = { type: 7, string: [44] }),
- (this.rules[9].opcodes[10] = { type: 7, string: [59] }),
- (this.rules[9].opcodes[11] = { type: 7, string: [61] }),
- (this.rules[10].opcodes = []),
- (this.rules[10].opcodes[0] = {
- type: 1,
- children: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17]
- }),
- (this.rules[10].opcodes[1] = { type: 5, min: 160, max: 55295 }),
- (this.rules[10].opcodes[2] = { type: 5, min: 63744, max: 64975 }),
- (this.rules[10].opcodes[3] = { type: 5, min: 65008, max: 65519 }),
- (this.rules[10].opcodes[4] = { type: 5, min: 65536, max: 131069 }),
- (this.rules[10].opcodes[5] = { type: 5, min: 131072, max: 196605 }),
- (this.rules[10].opcodes[6] = { type: 5, min: 196608, max: 262141 }),
- (this.rules[10].opcodes[7] = { type: 5, min: 262144, max: 327677 }),
- (this.rules[10].opcodes[8] = { type: 5, min: 327680, max: 393213 }),
- (this.rules[10].opcodes[9] = { type: 5, min: 393216, max: 458749 }),
- (this.rules[10].opcodes[10] = { type: 5, min: 458752, max: 524285 }),
- (this.rules[10].opcodes[11] = { type: 5, min: 524288, max: 589821 }),
- (this.rules[10].opcodes[12] = { type: 5, min: 589824, max: 655357 }),
- (this.rules[10].opcodes[13] = { type: 5, min: 655360, max: 720893 }),
- (this.rules[10].opcodes[14] = { type: 5, min: 720896, max: 786429 }),
- (this.rules[10].opcodes[15] = { type: 5, min: 786432, max: 851965 }),
- (this.rules[10].opcodes[16] = { type: 5, min: 851968, max: 917501 }),
- (this.rules[10].opcodes[17] = { type: 5, min: 921600, max: 983037 }),
- (this.rules[11].opcodes = []),
- (this.rules[11].opcodes[0] = { type: 1, children: [1, 2, 3] }),
- (this.rules[11].opcodes[1] = { type: 5, min: 57344, max: 63743 }),
- (this.rules[11].opcodes[2] = { type: 5, min: 983040, max: 1048573 }),
- (this.rules[11].opcodes[3] = { type: 5, min: 1048576, max: 1114109 }),
- (this.toString = function toString() {
- let s = '';
- return (
- (s += '; OpenAPI Server URL templating ABNF syntax\n'),
- (s += 'server-url-template = 1*( literals / server-variable )\n'),
- (s += 'server-variable = "{" server-variable-name "}"\n'),
- (s +=
- 'server-variable-name = 1*( unreserved / pct-encoded / sub-delims / ":" / "@" )\n'),
- (s +=
- 'literals = 1*( %x21 / %x23-24 / %x26 / %x28-3B / %x3D / %x3F-5B\n'),
- (s +=
- ' / %x5D / %x5F / %x61-7A / %x7E / ucschar / iprivate\n'),
- (s += ' / pct-encoded)\n'),
- (s += ' ; any Unicode character except: CTL, SP,\n'),
- (s +=
- ' ; DQUOTE, "\'", "%" (aside from pct-encoded),\n'),
- (s += ' ; "<", ">", "\\", "^", "`", "{", "|", "}"\n'),
- (s += '\n'),
- (s += '; Characters definitions (from RFC 6570)\n'),
- (s += 'ALPHA = %x41-5A / %x61-7A ; A-Z / a-z\n'),
- (s += 'DIGIT = %x30-39 ; 0-9\n'),
- (s += 'HEXDIG = DIGIT / "A" / "B" / "C" / "D" / "E" / "F"\n'),
- (s += ' ; case-insensitive\n'),
- (s += '\n'),
- (s += 'pct-encoded = "%" HEXDIG HEXDIG\n'),
- (s += 'unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"\n'),
- (s += 'sub-delims = "!" / "$" / "&" / "\'" / "(" / ")"\n'),
- (s += ' / "*" / "+" / "," / ";" / "="\n'),
- (s += '\n'),
- (s += 'ucschar = %xA0-D7FF / %xF900-FDCF / %xFDF0-FFEF\n'),
- (s += ' / %x10000-1FFFD / %x20000-2FFFD / %x30000-3FFFD\n'),
- (s += ' / %x40000-4FFFD / %x50000-5FFFD / %x60000-6FFFD\n'),
- (s += ' / %x70000-7FFFD / %x80000-8FFFD / %x90000-9FFFD\n'),
- (s += ' / %xA0000-AFFFD / %xB0000-BFFFD / %xC0000-CFFFD\n'),
- (s += ' / %xD0000-DFFFD / %xE1000-EFFFD\n'),
- (s += '\n'),
- (s += 'iprivate = %xE000-F8FF / %xF0000-FFFFD / %x100000-10FFFD\n'),
- '; OpenAPI Server URL templating ABNF syntax\nserver-url-template = 1*( literals / server-variable )\nserver-variable = "{" server-variable-name "}"\nserver-variable-name = 1*( unreserved / pct-encoded / sub-delims / ":" / "@" )\nliterals = 1*( %x21 / %x23-24 / %x26 / %x28-3B / %x3D / %x3F-5B\n / %x5D / %x5F / %x61-7A / %x7E / ucschar / iprivate\n / pct-encoded)\n ; any Unicode character except: CTL, SP,\n ; DQUOTE, "\'", "%" (aside from pct-encoded),\n ; "<", ">", "\\", "^", "`", "{", "|", "}"\n\n; Characters definitions (from RFC 6570)\nALPHA = %x41-5A / %x61-7A ; A-Z / a-z\nDIGIT = %x30-39 ; 0-9\nHEXDIG = DIGIT / "A" / "B" / "C" / "D" / "E" / "F"\n ; case-insensitive\n\npct-encoded = "%" HEXDIG HEXDIG\nunreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"\nsub-delims = "!" / "$" / "&" / "\'" / "(" / ")"\n / "*" / "+" / "," / ";" / "="\n\nucschar = %xA0-D7FF / %xF900-FDCF / %xFDF0-FFEF\n / %x10000-1FFFD / %x20000-2FFFD / %x30000-3FFFD\n / %x40000-4FFFD / %x50000-5FFFD / %x60000-6FFFD\n / %x70000-7FFFD / %x80000-8FFFD / %x90000-9FFFD\n / %xA0000-AFFFD / %xB0000-BFFFD / %xC0000-CFFFD\n / %xD0000-DFFFD / %xE1000-EFFFD\n\niprivate = %xE000-F8FF / %xF0000-FFFFD / %x100000-10FFFD\n'
- );
- });
- })(),
- openapi_server_url_templating_es_parse = (s) => {
- const o = new IS();
- (o.ast = new PS()),
- (o.ast.callbacks['server-url-template'] = server_url_template),
- (o.ast.callbacks['server-variable'] = callbacks_server_variable),
- (o.ast.callbacks['server-variable-name'] = server_variable_name),
- (o.ast.callbacks.literals = callbacks_literals);
- return { result: o.parse(NS, 'server-url-template', s), ast: o.ast };
- },
- openapi_server_url_templating_es_test = (s, { strict: o = !1 } = {}) => {
- try {
- const i = openapi_server_url_templating_es_parse(s);
- if (!i.result.success) return !1;
- const u = [];
- i.ast.translate(u);
- const _ = u.some(([s]) => 'server-variable' === s);
- if (!o && !_)
- try {
- return new URL(s, 'https://vladimirgorej.com'), !0;
- } catch {
- return !1;
- }
- return !o || _;
- } catch {
- return !1;
- }
- },
- encodeServerVariable = (s) =>
- ((s) => {
- try {
- return 'string' == typeof s && decodeURIComponent(s) !== s;
- } catch {
- return !1;
- }
- })(s)
- ? s
- : encodeURIComponent(s).replace(/%5B/g, '[').replace(/%5D/g, ']'),
- RS = ['literals', 'server-variable-name'],
- es_substitute = (s, o, i = {}) => {
- const u = { ...{ encoder: encodeServerVariable }, ...i },
- _ = openapi_server_url_templating_es_parse(s);
- if (!_.result.success) return s;
- const w = [];
- _.ast.translate(w);
- const x = w
- .filter(([s]) => RS.includes(s))
- .map(([s, i]) =>
- 'server-variable-name' === s
- ? Object.hasOwn(o, i)
- ? u.encoder(o[i], i)
- : `{${i}}`
- : i
- );
- return x.join('');
- };
- const callbacks_slash = (s, o, i, u, _) => (
- s === TS.SEM_PRE ? _.push(['slash', MS.charsToString(o, i, u)]) : TS.SEM_POST, TS.SEM_OK
- ),
- path_template = (s, o, i, u, _) => {
- if (s === TS.SEM_PRE) {
- if (!1 === Array.isArray(_)) throw new Error("parser's user data must be an array");
- _.push(['path-template', MS.charsToString(o, i, u)]);
- }
- return TS.SEM_OK;
- },
- callbacks_path = (s, o, i, u, _) => (
- s === TS.SEM_PRE ? _.push(['path', MS.charsToString(o, i, u)]) : TS.SEM_POST, TS.SEM_OK
- ),
- path_literal = (s, o, i, u, _) => (
- s === TS.SEM_PRE ? _.push(['path-literal', MS.charsToString(o, i, u)]) : TS.SEM_POST,
- TS.SEM_OK
- ),
- callbacks_query = (s, o, i, u, _) => (
- s === TS.SEM_PRE ? _.push(['query', MS.charsToString(o, i, u)]) : TS.SEM_POST, TS.SEM_OK
- ),
- query_marker = (s, o, i, u, _) => (
- s === TS.SEM_PRE ? _.push(['query-marker', MS.charsToString(o, i, u)]) : TS.SEM_POST,
- TS.SEM_OK
- ),
- callbacks_fragment = (s, o, i, u, _) => (
- s === TS.SEM_PRE ? _.push(['fragment', MS.charsToString(o, i, u)]) : TS.SEM_POST,
- TS.SEM_OK
- ),
- fragment_marker = (s, o, i, u, _) => (
- s === TS.SEM_PRE ? _.push(['fragment-marker', MS.charsToString(o, i, u)]) : TS.SEM_POST,
- TS.SEM_OK
- ),
- template_expression = (s, o, i, u, _) => (
- s === TS.SEM_PRE
- ? _.push(['template-expression', MS.charsToString(o, i, u)])
- : TS.SEM_POST,
- TS.SEM_OK
- ),
- template_expression_param_name = (s, o, i, u, _) => (
- s === TS.SEM_PRE
- ? _.push(['template-expression-param-name', MS.charsToString(o, i, u)])
- : TS.SEM_POST,
- TS.SEM_OK
- ),
- DS = new (function path_templating_grammar() {
- (this.grammarObject = 'grammarObject'),
- (this.rules = []),
- (this.rules[0] = {
- name: 'path-template',
- lower: 'path-template',
- index: 0,
- isBkr: !1
- }),
- (this.rules[1] = { name: 'path', lower: 'path', index: 1, isBkr: !1 }),
- (this.rules[2] = {
- name: 'path-segment',
- lower: 'path-segment',
- index: 2,
- isBkr: !1
- }),
- (this.rules[3] = { name: 'query', lower: 'query', index: 3, isBkr: !1 }),
- (this.rules[4] = {
- name: 'query-literal',
- lower: 'query-literal',
- index: 4,
- isBkr: !1
- }),
- (this.rules[5] = {
- name: 'query-marker',
- lower: 'query-marker',
- index: 5,
- isBkr: !1
- }),
- (this.rules[6] = { name: 'fragment', lower: 'fragment', index: 6, isBkr: !1 }),
- (this.rules[7] = {
- name: 'fragment-literal',
- lower: 'fragment-literal',
- index: 7,
- isBkr: !1
- }),
- (this.rules[8] = {
- name: 'fragment-marker',
- lower: 'fragment-marker',
- index: 8,
- isBkr: !1
- }),
- (this.rules[9] = { name: 'slash', lower: 'slash', index: 9, isBkr: !1 }),
- (this.rules[10] = {
- name: 'path-literal',
- lower: 'path-literal',
- index: 10,
- isBkr: !1
- }),
- (this.rules[11] = {
- name: 'template-expression',
- lower: 'template-expression',
- index: 11,
- isBkr: !1
- }),
- (this.rules[12] = {
- name: 'template-expression-param-name',
- lower: 'template-expression-param-name',
- index: 12,
- isBkr: !1
- }),
- (this.rules[13] = { name: 'unreserved', lower: 'unreserved', index: 13, isBkr: !1 }),
- (this.rules[14] = {
- name: 'pct-encoded',
- lower: 'pct-encoded',
- index: 14,
- isBkr: !1
- }),
- (this.rules[15] = { name: 'sub-delims', lower: 'sub-delims', index: 15, isBkr: !1 }),
- (this.rules[16] = { name: 'ALPHA', lower: 'alpha', index: 16, isBkr: !1 }),
- (this.rules[17] = { name: 'DIGIT', lower: 'digit', index: 17, isBkr: !1 }),
- (this.rules[18] = { name: 'HEXDIG', lower: 'hexdig', index: 18, isBkr: !1 }),
- (this.udts = []),
- (this.rules[0].opcodes = []),
- (this.rules[0].opcodes[0] = { type: 2, children: [1, 2, 6] }),
- (this.rules[0].opcodes[1] = { type: 4, index: 1 }),
- (this.rules[0].opcodes[2] = { type: 3, min: 0, max: 1 }),
- (this.rules[0].opcodes[3] = { type: 2, children: [4, 5] }),
- (this.rules[0].opcodes[4] = { type: 4, index: 5 }),
- (this.rules[0].opcodes[5] = { type: 4, index: 3 }),
- (this.rules[0].opcodes[6] = { type: 3, min: 0, max: 1 }),
- (this.rules[0].opcodes[7] = { type: 2, children: [8, 9] }),
- (this.rules[0].opcodes[8] = { type: 4, index: 8 }),
- (this.rules[0].opcodes[9] = { type: 4, index: 6 }),
- (this.rules[1].opcodes = []),
- (this.rules[1].opcodes[0] = { type: 2, children: [1, 2, 6] }),
- (this.rules[1].opcodes[1] = { type: 4, index: 9 }),
- (this.rules[1].opcodes[2] = { type: 3, min: 0, max: 1 / 0 }),
- (this.rules[1].opcodes[3] = { type: 2, children: [4, 5] }),
- (this.rules[1].opcodes[4] = { type: 4, index: 2 }),
- (this.rules[1].opcodes[5] = { type: 4, index: 9 }),
- (this.rules[1].opcodes[6] = { type: 3, min: 0, max: 1 }),
- (this.rules[1].opcodes[7] = { type: 4, index: 2 }),
- (this.rules[2].opcodes = []),
- (this.rules[2].opcodes[0] = { type: 3, min: 1, max: 1 / 0 }),
- (this.rules[2].opcodes[1] = { type: 1, children: [2, 3] }),
- (this.rules[2].opcodes[2] = { type: 4, index: 10 }),
- (this.rules[2].opcodes[3] = { type: 4, index: 11 }),
- (this.rules[3].opcodes = []),
- (this.rules[3].opcodes[0] = { type: 3, min: 0, max: 1 / 0 }),
- (this.rules[3].opcodes[1] = { type: 4, index: 4 }),
- (this.rules[4].opcodes = []),
- (this.rules[4].opcodes[0] = { type: 3, min: 1, max: 1 / 0 }),
- (this.rules[4].opcodes[1] = { type: 1, children: [2, 3, 4, 5, 6, 7, 8, 9, 10] }),
- (this.rules[4].opcodes[2] = { type: 4, index: 13 }),
- (this.rules[4].opcodes[3] = { type: 4, index: 14 }),
- (this.rules[4].opcodes[4] = { type: 4, index: 15 }),
- (this.rules[4].opcodes[5] = { type: 7, string: [58] }),
- (this.rules[4].opcodes[6] = { type: 7, string: [64] }),
- (this.rules[4].opcodes[7] = { type: 7, string: [47] }),
- (this.rules[4].opcodes[8] = { type: 7, string: [63] }),
- (this.rules[4].opcodes[9] = { type: 7, string: [38] }),
- (this.rules[4].opcodes[10] = { type: 7, string: [61] }),
- (this.rules[5].opcodes = []),
- (this.rules[5].opcodes[0] = { type: 7, string: [63] }),
- (this.rules[6].opcodes = []),
- (this.rules[6].opcodes[0] = { type: 3, min: 0, max: 1 / 0 }),
- (this.rules[6].opcodes[1] = { type: 4, index: 7 }),
- (this.rules[7].opcodes = []),
- (this.rules[7].opcodes[0] = { type: 3, min: 1, max: 1 / 0 }),
- (this.rules[7].opcodes[1] = { type: 1, children: [2, 3, 4, 5, 6, 7, 8] }),
- (this.rules[7].opcodes[2] = { type: 4, index: 13 }),
- (this.rules[7].opcodes[3] = { type: 4, index: 14 }),
- (this.rules[7].opcodes[4] = { type: 4, index: 15 }),
- (this.rules[7].opcodes[5] = { type: 7, string: [58] }),
- (this.rules[7].opcodes[6] = { type: 7, string: [64] }),
- (this.rules[7].opcodes[7] = { type: 7, string: [47] }),
- (this.rules[7].opcodes[8] = { type: 7, string: [63] }),
- (this.rules[8].opcodes = []),
- (this.rules[8].opcodes[0] = { type: 7, string: [35] }),
- (this.rules[9].opcodes = []),
- (this.rules[9].opcodes[0] = { type: 7, string: [47] }),
- (this.rules[10].opcodes = []),
- (this.rules[10].opcodes[0] = { type: 3, min: 1, max: 1 / 0 }),
- (this.rules[10].opcodes[1] = { type: 1, children: [2, 3, 4, 5, 6] }),
- (this.rules[10].opcodes[2] = { type: 4, index: 13 }),
- (this.rules[10].opcodes[3] = { type: 4, index: 14 }),
- (this.rules[10].opcodes[4] = { type: 4, index: 15 }),
- (this.rules[10].opcodes[5] = { type: 7, string: [58] }),
- (this.rules[10].opcodes[6] = { type: 7, string: [64] }),
- (this.rules[11].opcodes = []),
- (this.rules[11].opcodes[0] = { type: 2, children: [1, 2, 3] }),
- (this.rules[11].opcodes[1] = { type: 7, string: [123] }),
- (this.rules[11].opcodes[2] = { type: 4, index: 12 }),
- (this.rules[11].opcodes[3] = { type: 7, string: [125] }),
- (this.rules[12].opcodes = []),
- (this.rules[12].opcodes[0] = { type: 3, min: 1, max: 1 / 0 }),
- (this.rules[12].opcodes[1] = { type: 1, children: [2, 3, 4, 5, 6] }),
- (this.rules[12].opcodes[2] = { type: 4, index: 13 }),
- (this.rules[12].opcodes[3] = { type: 4, index: 14 }),
- (this.rules[12].opcodes[4] = { type: 4, index: 15 }),
- (this.rules[12].opcodes[5] = { type: 7, string: [58] }),
- (this.rules[12].opcodes[6] = { type: 7, string: [64] }),
- (this.rules[13].opcodes = []),
- (this.rules[13].opcodes[0] = { type: 1, children: [1, 2, 3, 4, 5, 6] }),
- (this.rules[13].opcodes[1] = { type: 4, index: 16 }),
- (this.rules[13].opcodes[2] = { type: 4, index: 17 }),
- (this.rules[13].opcodes[3] = { type: 7, string: [45] }),
- (this.rules[13].opcodes[4] = { type: 7, string: [46] }),
- (this.rules[13].opcodes[5] = { type: 7, string: [95] }),
- (this.rules[13].opcodes[6] = { type: 7, string: [126] }),
- (this.rules[14].opcodes = []),
- (this.rules[14].opcodes[0] = { type: 2, children: [1, 2, 3] }),
- (this.rules[14].opcodes[1] = { type: 7, string: [37] }),
- (this.rules[14].opcodes[2] = { type: 4, index: 18 }),
- (this.rules[14].opcodes[3] = { type: 4, index: 18 }),
- (this.rules[15].opcodes = []),
- (this.rules[15].opcodes[0] = {
- type: 1,
- children: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]
- }),
- (this.rules[15].opcodes[1] = { type: 7, string: [33] }),
- (this.rules[15].opcodes[2] = { type: 7, string: [36] }),
- (this.rules[15].opcodes[3] = { type: 7, string: [38] }),
- (this.rules[15].opcodes[4] = { type: 7, string: [39] }),
- (this.rules[15].opcodes[5] = { type: 7, string: [40] }),
- (this.rules[15].opcodes[6] = { type: 7, string: [41] }),
- (this.rules[15].opcodes[7] = { type: 7, string: [42] }),
- (this.rules[15].opcodes[8] = { type: 7, string: [43] }),
- (this.rules[15].opcodes[9] = { type: 7, string: [44] }),
- (this.rules[15].opcodes[10] = { type: 7, string: [59] }),
- (this.rules[15].opcodes[11] = { type: 7, string: [61] }),
- (this.rules[16].opcodes = []),
- (this.rules[16].opcodes[0] = { type: 1, children: [1, 2] }),
- (this.rules[16].opcodes[1] = { type: 5, min: 65, max: 90 }),
- (this.rules[16].opcodes[2] = { type: 5, min: 97, max: 122 }),
- (this.rules[17].opcodes = []),
- (this.rules[17].opcodes[0] = { type: 5, min: 48, max: 57 }),
- (this.rules[18].opcodes = []),
- (this.rules[18].opcodes[0] = { type: 1, children: [1, 2, 3, 4, 5, 6, 7] }),
- (this.rules[18].opcodes[1] = { type: 4, index: 17 }),
- (this.rules[18].opcodes[2] = { type: 7, string: [97] }),
- (this.rules[18].opcodes[3] = { type: 7, string: [98] }),
- (this.rules[18].opcodes[4] = { type: 7, string: [99] }),
- (this.rules[18].opcodes[5] = { type: 7, string: [100] }),
- (this.rules[18].opcodes[6] = { type: 7, string: [101] }),
- (this.rules[18].opcodes[7] = { type: 7, string: [102] }),
- (this.toString = function toString() {
- let s = '';
- return (
- (s += '; OpenAPI Path Templating ABNF syntax\n'),
- (s +=
- 'path-template = path [ query-marker query ] [ fragment-marker fragment ]\n'),
- (s +=
- 'path = slash *( path-segment slash ) [ path-segment ]\n'),
- (s +=
- 'path-segment = 1*( path-literal / template-expression )\n'),
- (s += 'query = *( query-literal )\n'),
- (s +=
- 'query-literal = 1*( unreserved / pct-encoded / sub-delims / ":" / "@" / "/" / "?" / "&" / "=" )\n'),
- (s += 'query-marker = "?"\n'),
- (s += 'fragment = *( fragment-literal )\n'),
- (s +=
- 'fragment-literal = 1*( unreserved / pct-encoded / sub-delims / ":" / "@" / "/" / "?" )\n'),
- (s += 'fragment-marker = "#"\n'),
- (s += 'slash = "/"\n'),
- (s +=
- 'path-literal = 1*( unreserved / pct-encoded / sub-delims / ":" / "@" )\n'),
- (s +=
- 'template-expression = "{" template-expression-param-name "}"\n'),
- (s +=
- 'template-expression-param-name = 1*( unreserved / pct-encoded / sub-delims / ":" / "@" )\n'),
- (s += '\n'),
- (s += '; Characters definitions (from RFC 3986)\n'),
- (s += 'unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"\n'),
- (s += 'pct-encoded = "%" HEXDIG HEXDIG\n'),
- (s += 'sub-delims = "!" / "$" / "&" / "\'" / "(" / ")"\n'),
- (s += ' / "*" / "+" / "," / ";" / "="\n'),
- (s += 'ALPHA = %x41-5A / %x61-7A ; A-Z / a-z\n'),
- (s += 'DIGIT = %x30-39 ; 0-9\n'),
- (s += 'HEXDIG = DIGIT / "A" / "B" / "C" / "D" / "E" / "F"\n'),
- '; OpenAPI Path Templating ABNF syntax\npath-template = path [ query-marker query ] [ fragment-marker fragment ]\npath = slash *( path-segment slash ) [ path-segment ]\npath-segment = 1*( path-literal / template-expression )\nquery = *( query-literal )\nquery-literal = 1*( unreserved / pct-encoded / sub-delims / ":" / "@" / "/" / "?" / "&" / "=" )\nquery-marker = "?"\nfragment = *( fragment-literal )\nfragment-literal = 1*( unreserved / pct-encoded / sub-delims / ":" / "@" / "/" / "?" )\nfragment-marker = "#"\nslash = "/"\npath-literal = 1*( unreserved / pct-encoded / sub-delims / ":" / "@" )\ntemplate-expression = "{" template-expression-param-name "}"\ntemplate-expression-param-name = 1*( unreserved / pct-encoded / sub-delims / ":" / "@" )\n\n; Characters definitions (from RFC 3986)\nunreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"\npct-encoded = "%" HEXDIG HEXDIG\nsub-delims = "!" / "$" / "&" / "\'" / "(" / ")"\n / "*" / "+" / "," / ";" / "="\nALPHA = %x41-5A / %x61-7A ; A-Z / a-z\nDIGIT = %x30-39 ; 0-9\nHEXDIG = DIGIT / "A" / "B" / "C" / "D" / "E" / "F"\n'
- );
- });
- })(),
- openapi_path_templating_es_parse = (s) => {
- const o = new IS();
- (o.ast = new PS()),
- (o.ast.callbacks['path-template'] = path_template),
- (o.ast.callbacks.path = callbacks_path),
- (o.ast.callbacks.query = callbacks_query),
- (o.ast.callbacks['query-marker'] = query_marker),
- (o.ast.callbacks.fragment = callbacks_fragment),
- (o.ast.callbacks['fragment-marker'] = fragment_marker),
- (o.ast.callbacks.slash = callbacks_slash),
- (o.ast.callbacks['path-literal'] = path_literal),
- (o.ast.callbacks['template-expression'] = template_expression),
- (o.ast.callbacks['template-expression-param-name'] = template_expression_param_name);
- return { result: o.parse(DS, 'path-template', s), ast: o.ast };
- },
- encodePathComponent = (s) =>
- ((s) => {
- try {
- return 'string' == typeof s && decodeURIComponent(s) !== s;
- } catch {
- return !1;
- }
- })(s)
- ? s
- : encodeURIComponent(s).replace(/%5B/g, '[').replace(/%5D/g, ']'),
- LS = [
- 'slash',
- 'path-literal',
- 'query-marker',
- 'query-literal',
- 'template-expression-param-name'
- ],
- openapi_path_templating_es_resolve = (s, o, i = {}) => {
- const u = { ...{ encoder: encodePathComponent }, ...i },
- _ = openapi_path_templating_es_parse(s);
- if (!_.result.success) return s;
- const w = [];
- _.ast.translate(w);
- const x = w
- .filter(([s]) => LS.includes(s))
- .map(([s, i]) =>
- 'template-expression-param-name' === s
- ? Object.hasOwn(o, i)
- ? u.encoder(o[i], i)
- : `{${i}}`
- : i
- );
- return x.join('');
- },
- BS = {
- body: function bodyBuilder({ req: s, value: o }) {
- void 0 !== o && (s.body = o);
- },
- header: function headerBuilder({ req: s, parameter: o, value: i }) {
- (s.headers = s.headers || {}), void 0 !== i && (s.headers[o.name] = i);
- },
- query: function queryBuilder({ req: s, value: o, parameter: i }) {
- (s.query = s.query || {}), !1 === o && 'boolean' === i.type && (o = 'false');
- 0 === o && ['number', 'integer'].indexOf(i.type) > -1 && (o = '0');
- if (o) s.query[i.name] = { collectionFormat: i.collectionFormat, value: o };
- else if (i.allowEmptyValue && void 0 !== o) {
- const o = i.name;
- (s.query[o] = s.query[o] || {}), (s.query[o].allowEmptyValue = !0);
- }
- },
- path: function pathBuilder({ req: s, value: o, parameter: i, baseURL: u }) {
- if (void 0 !== o) {
- const _ = s.url.replace(u, ''),
- w = openapi_path_templating_es_resolve(_, { [i.name]: o });
- s.url = u + w;
- }
- },
- formData: function formDataBuilder({ req: s, value: o, parameter: i }) {
- !1 === o && 'boolean' === i.type && (o = 'false');
- 0 === o && ['number', 'integer'].indexOf(i.type) > -1 && (o = '0');
- if (o)
- (s.form = s.form || {}),
- (s.form[i.name] = { collectionFormat: i.collectionFormat, value: o });
- else if (i.allowEmptyValue && void 0 !== o) {
- s.form = s.form || {};
- const o = i.name;
- (s.form[o] = s.form[o] || {}), (s.form[o].allowEmptyValue = !0);
- }
- }
- };
- function serialize(s, o) {
- return o.includes('application/json')
- ? 'string' == typeof s
- ? s
- : (Array.isArray(s) &&
- (s = s.map((s) => {
- try {
- return JSON.parse(s);
- } catch (o) {
- return s;
- }
- })),
- JSON.stringify(s))
- : String(s);
- }
- function parameter_builders_path({ req: s, value: o, parameter: i, baseURL: u }) {
- const { name: _, style: w, explode: x, content: C } = i;
- if (void 0 === o) return;
- const j = s.url.replace(u, '');
- let L;
- if (C) {
- const s = Object.keys(C)[0];
- L = openapi_path_templating_es_resolve(
- j,
- { [_]: o },
- { encoder: (o) => encodeCharacters(serialize(o, s)) }
- );
- } else
- L = openapi_path_templating_es_resolve(
- j,
- { [_]: o },
- {
- encoder: (s) =>
- stylize({
- key: i.name,
- value: s,
- style: w || 'simple',
- explode: x || !1,
- escape: 'reserved'
- })
- }
- );
- s.url = u + L;
- }
- function parameter_builders_query({ req: s, value: o, parameter: i }) {
- if (((s.query = s.query || {}), void 0 !== o && i.content)) {
- const u = serialize(o, Object.keys(i.content)[0]);
- if (u) s.query[i.name] = u;
- else if (i.allowEmptyValue) {
- const o = i.name;
- (s.query[o] = s.query[o] || {}), (s.query[o].allowEmptyValue = !0);
- }
- } else if ((!1 === o && (o = 'false'), 0 === o && (o = '0'), o)) {
- const { style: u, explode: _, allowReserved: w } = i;
- s.query[i.name] = {
- value: o,
- serializationOption: { style: u, explode: _, allowReserved: w }
- };
- } else if (i.allowEmptyValue && void 0 !== o) {
- const o = i.name;
- (s.query[o] = s.query[o] || {}), (s.query[o].allowEmptyValue = !0);
- }
- }
- const FS = ['accept', 'authorization', 'content-type'];
- function parameter_builders_header({ req: s, parameter: o, value: i }) {
- if (((s.headers = s.headers || {}), !(FS.indexOf(o.name.toLowerCase()) > -1)))
- if (void 0 !== i && o.content) {
- const u = Object.keys(o.content)[0];
- s.headers[o.name] = serialize(i, u);
- } else
- void 0 === i ||
- (Array.isArray(i) && 0 === i.length) ||
- (s.headers[o.name] = stylize({
- key: o.name,
- value: i,
- style: o.style || 'simple',
- explode: void 0 !== o.explode && o.explode,
- escape: !1
- }));
- }
- function parameter_builders_cookie({ req: s, parameter: o, value: i }) {
- s.headers = s.headers || {};
- const u = typeof i;
- if (void 0 !== i && o.content) {
- const u = Object.keys(o.content)[0];
- s.headers.Cookie = `${o.name}=${serialize(i, u)}`;
- } else if (void 0 !== i && (!Array.isArray(i) || 0 !== i.length)) {
- const _ = 'object' === u && !Array.isArray(i) && o.explode ? '' : `${o.name}=`;
- s.headers.Cookie =
- _ +
- stylize({
- key: o.name,
- value: i,
- escape: !1,
- style: o.style || 'form',
- explode: void 0 !== o.explode && o.explode
- });
- }
- }
- const qS =
- 'undefined' != typeof globalThis
- ? globalThis
- : 'undefined' != typeof self
- ? self
- : window,
- { btoa: $S } = qS,
- VS = $S;
- function buildRequest(s, o) {
- const {
- operation: i,
- requestBody: u,
- securities: _,
- spec: w,
- attachContentTypeForEmptyPayload: x
- } = s;
- let { requestContentType: C } = s;
- o = (function applySecurities({
- request: s,
- securities: o = {},
- operation: i = {},
- spec: u
- }) {
- var _;
- const w = { ...s },
- { authorized: x = {} } = o,
- C = i.security || u.security || [],
- j = x && !!Object.keys(x).length,
- L =
- (null == u || null === (_ = u.components) || void 0 === _
- ? void 0
- : _.securitySchemes) || {};
- if (
- ((w.headers = w.headers || {}),
- (w.query = w.query || {}),
- !Object.keys(o).length ||
- !j ||
- !C ||
- (Array.isArray(i.security) && !i.security.length))
- )
- return s;
- return (
- C.forEach((s) => {
- Object.keys(s).forEach((s) => {
- const o = x[s],
- i = L[s];
- if (!o) return;
- const u = o.value || o,
- { type: _ } = i;
- if (o)
- if ('apiKey' === _)
- 'query' === i.in && (w.query[i.name] = u),
- 'header' === i.in && (w.headers[i.name] = u),
- 'cookie' === i.in && (w.cookies[i.name] = u);
- else if ('http' === _) {
- if (/^basic$/i.test(i.scheme)) {
- const s = u.username || '',
- o = u.password || '',
- i = VS(`${s}:${o}`);
- w.headers.Authorization = `Basic ${i}`;
- }
- /^bearer$/i.test(i.scheme) && (w.headers.Authorization = `Bearer ${u}`);
- } else if ('oauth2' === _ || 'openIdConnect' === _) {
- const s = o.token || {},
- u = s[i['x-tokenName'] || 'access_token'];
- let _ = s.token_type;
- (_ && 'bearer' !== _.toLowerCase()) || (_ = 'Bearer'),
- (w.headers.Authorization = `${_} ${u}`);
- }
- });
- }),
- w
- );
- })({ request: o, securities: _, operation: i, spec: w });
- const j = i.requestBody || {},
- L = Object.keys(j.content || {}),
- B = C && L.indexOf(C) > -1;
- if (u || x) {
- if (C && B) o.headers['Content-Type'] = C;
- else if (!C) {
- const s = L[0];
- s && ((o.headers['Content-Type'] = s), (C = s));
- }
- } else C && B && (o.headers['Content-Type'] = C);
- if (!s.responseContentType && i.responses) {
- const s = Object.entries(i.responses)
- .filter(([s, o]) => {
- const i = parseInt(s, 10);
- return i >= 200 && i < 300 && ku(o.content);
- })
- .reduce((s, [, o]) => s.concat(Object.keys(o.content)), []);
- s.length > 0 && (o.headers.accept = s.join(', '));
- }
- if (u)
- if (C) {
- if (L.indexOf(C) > -1)
- if ('application/x-www-form-urlencoded' === C || 'multipart/form-data' === C)
- if ('object' == typeof u) {
- var $, V;
- const s =
- null !==
- ($ = null === (V = j.content[C]) || void 0 === V ? void 0 : V.encoding) &&
- void 0 !== $
- ? $
- : {};
- (o.form = {}),
- Object.keys(u).forEach((i) => {
- let _;
- try {
- _ = JSON.parse(u[i]);
- } catch {
- _ = u[i];
- }
- o.form[i] = { value: _, encoding: s[i] || {} };
- });
- } else if ('string' == typeof u) {
- var U, z;
- const s =
- null !==
- (U = null === (z = j.content[C]) || void 0 === z ? void 0 : z.encoding) &&
- void 0 !== U
- ? U
- : {};
- try {
- o.form = {};
- const i = JSON.parse(u);
- Object.entries(i).forEach(([i, u]) => {
- o.form[i] = { value: u, encoding: s[i] || {} };
- });
- } catch {
- o.form = u;
- }
- } else o.form = u;
- else o.body = u;
- } else o.body = u;
- return o;
- }
- function build_request_buildRequest(s, o) {
- const {
- spec: i,
- operation: u,
- securities: _,
- requestContentType: w,
- responseContentType: x,
- attachContentTypeForEmptyPayload: C
- } = s;
- if (
- ((o = (function build_request_applySecurities({
- request: s,
- securities: o = {},
- operation: i = {},
- spec: u
- }) {
- const _ = { ...s },
- { authorized: w = {}, specSecurity: x = [] } = o,
- C = i.security || x,
- j = w && !!Object.keys(w).length,
- L = u.securityDefinitions;
- if (
- ((_.headers = _.headers || {}),
- (_.query = _.query || {}),
- !Object.keys(o).length ||
- !j ||
- !C ||
- (Array.isArray(i.security) && !i.security.length))
- )
- return s;
- return (
- C.forEach((s) => {
- Object.keys(s).forEach((s) => {
- const o = w[s];
- if (!o) return;
- const { token: i } = o,
- u = o.value || o,
- x = L[s],
- { type: C } = x,
- j = x['x-tokenName'] || 'access_token',
- B = i && i[j];
- let $ = i && i.token_type;
- if (o)
- if ('apiKey' === C) {
- const s = 'query' === x.in ? 'query' : 'headers';
- (_[s] = _[s] || {}), (_[s][x.name] = u);
- } else if ('basic' === C)
- if (u.header) _.headers.authorization = u.header;
- else {
- const s = u.username || '',
- o = u.password || '';
- (u.base64 = VS(`${s}:${o}`)),
- (_.headers.authorization = `Basic ${u.base64}`);
- }
- else
- 'oauth2' === C &&
- B &&
- (($ = $ && 'bearer' !== $.toLowerCase() ? $ : 'Bearer'),
- (_.headers.authorization = `${$} ${B}`));
- });
- }),
- _
- );
- })({ request: o, securities: _, operation: u, spec: i })),
- o.body || o.form || C)
- )
- w
- ? (o.headers['Content-Type'] = w)
- : Array.isArray(u.consumes)
- ? ([o.headers['Content-Type']] = u.consumes)
- : Array.isArray(i.consumes)
- ? ([o.headers['Content-Type']] = i.consumes)
- : u.parameters && u.parameters.filter((s) => 'file' === s.type).length
- ? (o.headers['Content-Type'] = 'multipart/form-data')
- : u.parameters &&
- u.parameters.filter((s) => 'formData' === s.in).length &&
- (o.headers['Content-Type'] = 'application/x-www-form-urlencoded');
- else if (w) {
- const s = u.parameters && u.parameters.filter((s) => 'body' === s.in).length > 0,
- i = u.parameters && u.parameters.filter((s) => 'formData' === s.in).length > 0;
- (s || i) && (o.headers['Content-Type'] = w);
- }
- return (
- !x &&
- Array.isArray(u.produces) &&
- u.produces.length > 0 &&
- (o.headers.accept = u.produces.join(', ')),
- o
- );
- }
- function idFromPathMethodLegacy(s, o) {
- return `${o.toLowerCase()}-${s}`;
- }
- const arrayOrEmpty = (s) => (Array.isArray(s) ? s : []),
- parseURIReference = (s) => {
- try {
- return new URL(s);
- } catch {
- const o = new URL(s, Nc),
- i = String(s).startsWith('/') ? o.pathname : o.pathname.substring(1);
- return {
- hash: o.hash,
- host: '',
- hostname: '',
- href: '',
- origin: '',
- password: '',
- pathname: i,
- port: '',
- protocol: '',
- search: o.search,
- searchParams: o.searchParams
- };
- }
- };
- class OperationNotFoundError extends Jo {}
- const US = { buildRequest: execute_buildRequest };
- function execute_execute({
- http: s,
- fetch: o,
- spec: i,
- operationId: u,
- pathName: _,
- method: w,
- parameters: x,
- securities: C,
- ...j
- }) {
- const L = s || o || http_http;
- _ && w && !u && (u = idFromPathMethodLegacy(_, w));
- const B = US.buildRequest({
- spec: i,
- operationId: u,
- parameters: x,
- securities: C,
- http: L,
- ...j
- });
- return (
- B.body && (ku(B.body) || Array.isArray(B.body)) && (B.body = JSON.stringify(B.body)),
- L(B)
- );
- }
- function execute_buildRequest(s) {
- var o;
- const {
- spec: i,
- operationId: u,
- responseContentType: _,
- scheme: w,
- requestInterceptor: x,
- responseInterceptor: C,
- contextUrl: j,
- userFetch: L,
- server: B,
- serverVariables: $,
- http: V,
- signal: U,
- serverVariableEncoder: z
- } = s;
- let { parameters: Y, parameterBuilders: Z, baseURL: ee } = s;
- const ie = isOpenAPI3(i);
- Z || (Z = ie ? fe : BS);
- let ae = {
- url: '',
- credentials: V && V.withCredentials ? 'include' : 'same-origin',
- headers: {},
- cookies: {}
- };
- U && (ae.signal = U),
- x && (ae.requestInterceptor = x),
- C && (ae.responseInterceptor = C),
- L && (ae.userFetch = L);
- const le = (function getOperationRaw(s, o) {
- return s && s.paths
- ? (function findOperation(s, o) {
- return (
- (function eachOperation(s, o, i) {
- if (!s || 'object' != typeof s || !s.paths || 'object' != typeof s.paths)
- return null;
- const { paths: u } = s;
- for (const _ in u)
- for (const w in u[_]) {
- if ('PARAMETERS' === w.toUpperCase()) continue;
- const x = u[_][w];
- if (!x || 'object' != typeof x) continue;
- const C = { spec: s, pathName: _, method: w.toUpperCase(), operation: x },
- j = o(C);
- if (i && j) return C;
- }
- })(s, o, !0) || null
- );
- })(s, ({ pathName: s, method: i, operation: u }) => {
- if (!u || 'object' != typeof u) return !1;
- const _ = u.operationId;
- return [opId(u, s, i), idFromPathMethodLegacy(s, i), _].some((s) => s && s === o);
- })
- : null;
- })(i, u);
- if (!le) throw new OperationNotFoundError(`Operation ${u} not found`);
- const { operation: ce = {}, method: pe, pathName: de } = le;
- if (
- ((ee =
- null !== (o = ee) && void 0 !== o
- ? o
- : (function baseUrl(s) {
- const o = isOpenAPI3(s.spec);
- return o
- ? (function oas3BaseUrl({
- spec: s,
- pathName: o,
- method: i,
- server: u,
- contextUrl: _,
- serverVariables: w = {},
- serverVariableEncoder: x
- }) {
- var C, j;
- let L,
- B = [],
- $ = '';
- const V =
- null == s ||
- null === (C = s.paths) ||
- void 0 === C ||
- null === (C = C[o]) ||
- void 0 === C ||
- null === (C = C[(i || '').toLowerCase()]) ||
- void 0 === C
- ? void 0
- : C.servers,
- U =
- null == s ||
- null === (j = s.paths) ||
- void 0 === j ||
- null === (j = j[o]) ||
- void 0 === j
- ? void 0
- : j.servers,
- z = null == s ? void 0 : s.servers;
- (B = isNonEmptyServerList(V)
- ? V
- : isNonEmptyServerList(U)
- ? U
- : isNonEmptyServerList(z)
- ? z
- : [Rc]),
- u && ((L = B.find((s) => s.url === u)), L && ($ = u));
- $ || (([L] = B), ($ = L.url));
- if (openapi_server_url_templating_es_test($, { strict: !0 })) {
- const s = Object.entries({ ...L.variables }).reduce(
- (s, [o, i]) => ((s[o] = i.default), s),
- {}
- );
- $ = es_substitute(
- $,
- { ...s, ...w },
- { encoder: 'function' == typeof x ? x : Ip }
- );
- }
- return (function buildOas3UrlWithContext(s = '', o = '') {
- const i = parseURIReference(s && o ? resolve(o, s) : s),
- u = parseURIReference(o),
- _ = stripNonAlpha(i.protocol) || stripNonAlpha(u.protocol),
- w = i.host || u.host,
- x = i.pathname;
- let C;
- C = _ && w ? `${_}://${w + x}` : x;
- return '/' === C[C.length - 1] ? C.slice(0, -1) : C;
- })($, _);
- })(s)
- : (function swagger2BaseUrl({ spec: s, scheme: o, contextUrl: i = '' }) {
- const u = parseURIReference(i),
- _ = Array.isArray(s.schemes) ? s.schemes[0] : null,
- w = o || _ || stripNonAlpha(u.protocol) || 'http',
- x = s.host || u.host || '',
- C = s.basePath || '';
- let j;
- j = w && x ? `${w}://${x + C}` : C;
- return '/' === j[j.length - 1] ? j.slice(0, -1) : j;
- })(s);
- })({
- spec: i,
- scheme: w,
- contextUrl: j,
- server: B,
- serverVariables: $,
- pathName: de,
- method: pe,
- serverVariableEncoder: z
- })),
- (ae.url += ee),
- !u)
- )
- return delete ae.cookies, ae;
- (ae.url += de), (ae.method = `${pe}`.toUpperCase()), (Y = Y || {});
- const ye = i.paths[de] || {};
- _ && (ae.headers.accept = _);
- const be = ((s) => {
- const o = {};
- s.forEach((s) => {
- o[s.in] || (o[s.in] = {}), (o[s.in][s.name] = s);
- });
- const i = [];
- return (
- Object.keys(o).forEach((s) => {
- Object.keys(o[s]).forEach((u) => {
- i.push(o[s][u]);
- });
- }),
- i
- );
- })([].concat(arrayOrEmpty(ce.parameters)).concat(arrayOrEmpty(ye.parameters)));
- be.forEach((s) => {
- const o = Z[s.in];
- let u;
- if (
- ('body' === s.in && s.schema && s.schema.properties && (u = Y),
- (u = s && s.name && Y[s.name]),
- void 0 === u
- ? (u = s && s.name && Y[`${s.in}.${s.name}`])
- : ((s, o) => o.filter((o) => o.name === s))(s.name, be).length > 1 &&
- console.warn(
- `Parameter '${s.name}' is ambiguous because the defined spec has more than one parameter with the name: '${s.name}' and the passed-in parameter values did not define an 'in' value.`
- ),
- null !== u)
- ) {
- if (
- (void 0 !== s.default && void 0 === u && (u = s.default),
- void 0 === u && s.required && !s.allowEmptyValue)
- )
- throw new Error(`Required parameter ${s.name} is not provided`);
- if (ie && s.schema && 'object' === s.schema.type && 'string' == typeof u)
- try {
- u = JSON.parse(u);
- } catch (s) {
- throw new Error('Could not parse object parameter value string as JSON');
- }
- o && o({ req: ae, parameter: s, value: u, operation: ce, spec: i, baseURL: ee });
- }
- });
- const _e = { ...s, operation: ce };
- if (
- ((ae = ie ? buildRequest(_e, ae) : build_request_buildRequest(_e, ae)),
- ae.cookies && Object.keys(ae.cookies).length)
- ) {
- const s = Object.keys(ae.cookies).reduce((s, o) => {
- const i = ae.cookies[o];
- return s + (s ? '&' : '') + jS.serialize(o, i);
- }, '');
- ae.headers.Cookie = s;
- }
- return ae.cookies && delete ae.cookies, serializeRequest(ae);
- }
- const stripNonAlpha = (s) => (s ? s.replace(/\W/g, '') : null);
- const isNonEmptyServerList = (s) => Array.isArray(s) && s.length > 0;
- const makeResolveSubtree =
- (s) =>
- async (o, i, u = {}) =>
- (async (s, o, i = {}) => {
- const {
- returnEntireTree: u,
- baseDoc: _,
- requestInterceptor: w,
- responseInterceptor: x,
- parameterMacro: C,
- modelPropertyMacro: j,
- useCircularStructures: L,
- strategies: B
- } = i,
- $ = {
- spec: s,
- pathDiscriminator: o,
- baseDoc: _,
- requestInterceptor: w,
- responseInterceptor: x,
- parameterMacro: C,
- modelPropertyMacro: j,
- useCircularStructures: L,
- strategies: B
- },
- V = B.find((o) => o.match(s)).normalize(s),
- U = await AS({
- spec: V,
- ...$,
- allowMetaPatches: !0,
- skipNormalization: !isOpenAPI31(s)
- });
- return (
- !u &&
- Array.isArray(o) &&
- o.length &&
- (U.spec = o.reduce((s, o) => (null == s ? void 0 : s[o]), U.spec) || null),
- U
- );
- })(o, i, { ...s, ...u }),
- zS =
- (makeResolveSubtree({ strategies: [fu, hu, uu] }),
- (s, o) =>
- (...i) => {
- s(...i);
- const u = o.getConfigs().withCredentials;
- o.fn.fetch.withCredentials = u;
- });
- function swagger_client({ configs: s, getConfigs: o }) {
- return {
- fn: {
- fetch:
- ((i = http_http),
- (u = s.preFetch),
- (_ = s.postFetch),
- (_ = _ || ((s) => s)),
- (u = u || ((s) => s)),
- (s) => (
- 'string' == typeof s && (s = { url: s }),
- (s = serializeRequest(s)),
- (s = u(s)),
- _(i(s))
- )),
- buildRequest: execute_buildRequest,
- execute: execute_execute,
- resolve: makeResolve({ strategies: [OS, fu, hu, uu] }),
- resolveSubtree: async (s, i, u = {}) => {
- const _ = o(),
- w = {
- modelPropertyMacro: _.modelPropertyMacro,
- parameterMacro: _.parameterMacro,
- requestInterceptor: _.requestInterceptor,
- responseInterceptor: _.responseInterceptor,
- strategies: [OS, fu, hu, uu]
- };
- return makeResolveSubtree(w)(s, i, u);
- },
- serializeRes: serializeResponse,
- opId
- },
- statePlugins: { configs: { wrapActions: { loaded: zS } } }
- };
- var i, u, _;
- }
- function util() {
- return { fn: { shallowEqualKeys } };
- }
- var WS = __webpack_require__(40961),
- KS = __webpack_require__(78418),
- HS = Pe,
- JS = Symbol.for('react-redux-context'),
- GS = 'undefined' != typeof globalThis ? globalThis : {};
- function getContext() {
- if (!HS.createContext) return {};
- const s = GS[JS] ?? (GS[JS] = new Map());
- let o = s.get(HS.createContext);
- return o || ((o = HS.createContext(null)), s.set(HS.createContext, o)), o;
- }
- var YS = getContext(),
- notInitialized = () => {
- throw new Error('uSES not initialized!');
- };
- var XS = Symbol.for('react.element'),
- ZS = Symbol.for('react.portal'),
- QS = Symbol.for('react.fragment'),
- ex = Symbol.for('react.strict_mode'),
- tx = Symbol.for('react.profiler'),
- rx = Symbol.for('react.provider'),
- nx = Symbol.for('react.context'),
- sx = Symbol.for('react.server_context'),
- ox = Symbol.for('react.forward_ref'),
- ix = Symbol.for('react.suspense'),
- ax = Symbol.for('react.suspense_list'),
- lx = Symbol.for('react.memo'),
- cx = Symbol.for('react.lazy'),
- ux = (Symbol.for('react.offscreen'), Symbol.for('react.client.reference'), ox),
- px = lx;
- function typeOf(s) {
- if ('object' == typeof s && null !== s) {
- const o = s.$$typeof;
- switch (o) {
- case XS: {
- const i = s.type;
- switch (i) {
- case QS:
- case tx:
- case ex:
- case ix:
- case ax:
- return i;
- default: {
- const s = i && i.$$typeof;
- switch (s) {
- case sx:
- case nx:
- case ox:
- case cx:
- case lx:
- case rx:
- return s;
- default:
- return o;
- }
- }
- }
- }
- case ZS:
- return o;
- }
- }
- }
- function pureFinalPropsSelectorFactory(
- s,
- o,
- i,
- u,
- { areStatesEqual: _, areOwnPropsEqual: w, areStatePropsEqual: x }
- ) {
- let C,
- j,
- L,
- B,
- $,
- V = !1;
- function handleSubsequentCalls(V, U) {
- const z = !w(U, j),
- Y = !_(V, C, U, j);
- return (
- (C = V),
- (j = U),
- z && Y
- ? (function handleNewPropsAndNewState() {
- return (L = s(C, j)), o.dependsOnOwnProps && (B = o(u, j)), ($ = i(L, B, j)), $;
- })()
- : z
- ? (function handleNewProps() {
- return (
- s.dependsOnOwnProps && (L = s(C, j)),
- o.dependsOnOwnProps && (B = o(u, j)),
- ($ = i(L, B, j)),
- $
- );
- })()
- : Y
- ? (function handleNewState() {
- const o = s(C, j),
- u = !x(o, L);
- return (L = o), u && ($ = i(L, B, j)), $;
- })()
- : $
- );
- }
- return function pureFinalPropsSelector(_, w) {
- return V
- ? handleSubsequentCalls(_, w)
- : (function handleFirstCall(_, w) {
- return (
- (C = _), (j = w), (L = s(C, j)), (B = o(u, j)), ($ = i(L, B, j)), (V = !0), $
- );
- })(_, w);
- };
- }
- function wrapMapToPropsConstant(s) {
- return function initConstantSelector(o) {
- const i = s(o);
- function constantSelector() {
- return i;
- }
- return (constantSelector.dependsOnOwnProps = !1), constantSelector;
- };
- }
- function getDependsOnOwnProps(s) {
- return s.dependsOnOwnProps ? Boolean(s.dependsOnOwnProps) : 1 !== s.length;
- }
- function wrapMapToPropsFunc(s, o) {
- return function initProxySelector(o, { displayName: i }) {
- const u = function mapToPropsProxy(s, o) {
- return u.dependsOnOwnProps ? u.mapToProps(s, o) : u.mapToProps(s, void 0);
- };
- return (
- (u.dependsOnOwnProps = !0),
- (u.mapToProps = function detectFactoryAndVerify(o, i) {
- (u.mapToProps = s), (u.dependsOnOwnProps = getDependsOnOwnProps(s));
- let _ = u(o, i);
- return (
- 'function' == typeof _ &&
- ((u.mapToProps = _),
- (u.dependsOnOwnProps = getDependsOnOwnProps(_)),
- (_ = u(o, i))),
- _
- );
- }),
- u
- );
- };
- }
- function createInvalidArgFactory(s, o) {
- return (i, u) => {
- throw new Error(
- `Invalid value of type ${typeof s} for ${o} argument when connecting component ${u.wrappedComponentName}.`
- );
- };
- }
- function defaultMergeProps(s, o, i) {
- return { ...i, ...s, ...o };
- }
- function defaultNoopBatch(s) {
- s();
- }
- var hx = { notify() {}, get: () => [] };
- function createSubscription(s, o) {
- let i,
- u = hx,
- _ = 0,
- w = !1;
- function handleChangeWrapper() {
- x.onStateChange && x.onStateChange();
- }
- function trySubscribe() {
- _++,
- i ||
- ((i = o ? o.addNestedSub(handleChangeWrapper) : s.subscribe(handleChangeWrapper)),
- (u = (function createListenerCollection() {
- let s = null,
- o = null;
- return {
- clear() {
- (s = null), (o = null);
- },
- notify() {
- defaultNoopBatch(() => {
- let o = s;
- for (; o; ) o.callback(), (o = o.next);
- });
- },
- get() {
- const o = [];
- let i = s;
- for (; i; ) o.push(i), (i = i.next);
- return o;
- },
- subscribe(i) {
- let u = !0;
- const _ = (o = { callback: i, next: null, prev: o });
- return (
- _.prev ? (_.prev.next = _) : (s = _),
- function unsubscribe() {
- u &&
- null !== s &&
- ((u = !1),
- _.next ? (_.next.prev = _.prev) : (o = _.prev),
- _.prev ? (_.prev.next = _.next) : (s = _.next));
- }
- );
- }
- };
- })()));
- }
- function tryUnsubscribe() {
- _--, i && 0 === _ && (i(), (i = void 0), u.clear(), (u = hx));
- }
- const x = {
- addNestedSub: function addNestedSub(s) {
- trySubscribe();
- const o = u.subscribe(s);
- let i = !1;
- return () => {
- i || ((i = !0), o(), tryUnsubscribe());
- };
- },
- notifyNestedSubs: function notifyNestedSubs() {
- u.notify();
- },
- handleChangeWrapper,
- isSubscribed: function isSubscribed() {
- return w;
- },
- trySubscribe: function trySubscribeSelf() {
- w || ((w = !0), trySubscribe());
- },
- tryUnsubscribe: function tryUnsubscribeSelf() {
- w && ((w = !1), tryUnsubscribe());
- },
- getListeners: () => u
- };
- return x;
- }
- var dx = !(
- 'undefined' == typeof window ||
- void 0 === window.document ||
- void 0 === window.document.createElement
- ),
- fx = 'undefined' != typeof navigator && 'ReactNative' === navigator.product,
- mx = dx || fx ? HS.useLayoutEffect : HS.useEffect;
- function is(s, o) {
- return s === o ? 0 !== s || 0 !== o || 1 / s == 1 / o : s != s && o != o;
- }
- function shallowEqual(s, o) {
- if (is(s, o)) return !0;
- if ('object' != typeof s || null === s || 'object' != typeof o || null === o) return !1;
- const i = Object.keys(s),
- u = Object.keys(o);
- if (i.length !== u.length) return !1;
- for (let u = 0; u < i.length; u++)
- if (!Object.prototype.hasOwnProperty.call(o, i[u]) || !is(s[i[u]], o[i[u]])) return !1;
- return !0;
- }
- var gx = {
- childContextTypes: !0,
- contextType: !0,
- contextTypes: !0,
- defaultProps: !0,
- displayName: !0,
- getDefaultProps: !0,
- getDerivedStateFromError: !0,
- getDerivedStateFromProps: !0,
- mixins: !0,
- propTypes: !0,
- type: !0
- },
- yx = {
- name: !0,
- length: !0,
- prototype: !0,
- caller: !0,
- callee: !0,
- arguments: !0,
- arity: !0
- },
- vx = {
- $$typeof: !0,
- compare: !0,
- defaultProps: !0,
- displayName: !0,
- propTypes: !0,
- type: !0
- },
- bx = {
- [ux]: { $$typeof: !0, render: !0, defaultProps: !0, displayName: !0, propTypes: !0 },
- [px]: vx
- };
- function getStatics(s) {
- return (function isMemo(s) {
- return typeOf(s) === lx;
- })(s)
- ? vx
- : bx[s.$$typeof] || gx;
- }
- var _x = Object.defineProperty,
- Ex = Object.getOwnPropertyNames,
- wx = Object.getOwnPropertySymbols,
- Sx = Object.getOwnPropertyDescriptor,
- xx = Object.getPrototypeOf,
- kx = Object.prototype;
- function hoistNonReactStatics(s, o) {
- if ('string' != typeof o) {
- if (kx) {
- const i = xx(o);
- i && i !== kx && hoistNonReactStatics(s, i);
- }
- let i = Ex(o);
- wx && (i = i.concat(wx(o)));
- const u = getStatics(s),
- _ = getStatics(o);
- for (let w = 0; w < i.length; ++w) {
- const x = i[w];
- if (!(yx[x] || (_ && _[x]) || (u && u[x]))) {
- const i = Sx(o, x);
- try {
- _x(s, x, i);
- } catch (s) {}
- }
- }
- }
- return s;
- }
- var Cx = notInitialized,
- Ox = [null, null];
- function captureWrapperProps(s, o, i, u, _, w) {
- (s.current = u), (i.current = !1), _.current && ((_.current = null), w());
- }
- function strictEqual(s, o) {
- return s === o;
- }
- var Ax = function connect(
- s,
- o,
- i,
- {
- pure: u,
- areStatesEqual: _ = strictEqual,
- areOwnPropsEqual: w = shallowEqual,
- areStatePropsEqual: x = shallowEqual,
- areMergedPropsEqual: C = shallowEqual,
- forwardRef: j = !1,
- context: L = YS
- } = {}
- ) {
- const B = L,
- $ = (function mapStateToPropsFactory(s) {
- return s
- ? 'function' == typeof s
- ? wrapMapToPropsFunc(s)
- : createInvalidArgFactory(s, 'mapStateToProps')
- : wrapMapToPropsConstant(() => ({}));
- })(s),
- V = (function mapDispatchToPropsFactory(s) {
- return s && 'object' == typeof s
- ? wrapMapToPropsConstant((o) =>
- (function react_redux_bindActionCreators(s, o) {
- const i = {};
- for (const u in s) {
- const _ = s[u];
- 'function' == typeof _ && (i[u] = (...s) => o(_(...s)));
- }
- return i;
- })(s, o)
- )
- : s
- ? 'function' == typeof s
- ? wrapMapToPropsFunc(s)
- : createInvalidArgFactory(s, 'mapDispatchToProps')
- : wrapMapToPropsConstant((s) => ({ dispatch: s }));
- })(o),
- U = (function mergePropsFactory(s) {
- return s
- ? 'function' == typeof s
- ? (function wrapMergePropsFunc(s) {
- return function initMergePropsProxy(
- o,
- { displayName: i, areMergedPropsEqual: u }
- ) {
- let _,
- w = !1;
- return function mergePropsProxy(o, i, x) {
- const C = s(o, i, x);
- return w ? u(C, _) || (_ = C) : ((w = !0), (_ = C)), _;
- };
- };
- })(s)
- : createInvalidArgFactory(s, 'mergeProps')
- : () => defaultMergeProps;
- })(i),
- z = Boolean(s);
- return (s) => {
- const o = s.displayName || s.name || 'Component',
- i = `Connect(${o})`,
- u = {
- shouldHandleStateChanges: z,
- displayName: i,
- wrappedComponentName: o,
- WrappedComponent: s,
- initMapStateToProps: $,
- initMapDispatchToProps: V,
- initMergeProps: U,
- areStatesEqual: _,
- areStatePropsEqual: x,
- areOwnPropsEqual: w,
- areMergedPropsEqual: C
- };
- function ConnectFunction(o) {
- const [i, _, w] = HS.useMemo(() => {
- const { reactReduxForwardedRef: s, ...i } = o;
- return [o.context, s, i];
- }, [o]),
- x = HS.useMemo(() => B, [i, B]),
- C = HS.useContext(x),
- j = Boolean(o.store) && Boolean(o.store.getState) && Boolean(o.store.dispatch),
- L = Boolean(C) && Boolean(C.store);
- const $ = j ? o.store : C.store,
- V = L ? C.getServerState : $.getState,
- U = HS.useMemo(
- () =>
- (function finalPropsSelectorFactory(
- s,
- { initMapStateToProps: o, initMapDispatchToProps: i, initMergeProps: u, ..._ }
- ) {
- return pureFinalPropsSelectorFactory(o(s, _), i(s, _), u(s, _), s, _);
- })($.dispatch, u),
- [$]
- ),
- [Y, Z] = HS.useMemo(() => {
- if (!z) return Ox;
- const s = createSubscription($, j ? void 0 : C.subscription),
- o = s.notifyNestedSubs.bind(s);
- return [s, o];
- }, [$, j, C]),
- ee = HS.useMemo(() => (j ? C : { ...C, subscription: Y }), [j, C, Y]),
- ie = HS.useRef(void 0),
- ae = HS.useRef(w),
- le = HS.useRef(void 0),
- ce = HS.useRef(!1),
- pe = HS.useRef(!1),
- de = HS.useRef(void 0);
- mx(
- () => (
- (pe.current = !0),
- () => {
- pe.current = !1;
- }
- ),
- []
- );
- const fe = HS.useMemo(
- () => () => (le.current && w === ae.current ? le.current : U($.getState(), w)),
- [$, w]
- ),
- ye = HS.useMemo(
- () => (s) =>
- Y
- ? (function subscribeUpdates(s, o, i, u, _, w, x, C, j, L, B) {
- if (!s) return () => {};
- let $ = !1,
- V = null;
- const checkForUpdates = () => {
- if ($ || !C.current) return;
- const s = o.getState();
- let i, U;
- try {
- i = u(s, _.current);
- } catch (s) {
- (U = s), (V = s);
- }
- U || (V = null),
- i === w.current
- ? x.current || L()
- : ((w.current = i), (j.current = i), (x.current = !0), B());
- };
- return (
- (i.onStateChange = checkForUpdates),
- i.trySubscribe(),
- checkForUpdates(),
- () => {
- if ((($ = !0), i.tryUnsubscribe(), (i.onStateChange = null), V))
- throw V;
- }
- );
- })(z, $, Y, U, ae, ie, ce, pe, le, Z, s)
- : () => {},
- [Y]
- );
- let be;
- !(function useIsomorphicLayoutEffectWithArgs(s, o, i) {
- mx(() => s(...o), i);
- })(captureWrapperProps, [ae, ie, ce, w, le, Z]);
- try {
- be = Cx(ye, fe, V ? () => U(V(), w) : fe);
- } catch (s) {
- throw (
- (de.current &&
- (s.message += `\nThe error may be correlated with this previous error:\n${de.current.stack}\n\n`),
- s)
- );
- }
- mx(() => {
- (de.current = void 0), (le.current = void 0), (ie.current = be);
- });
- const _e = HS.useMemo(() => HS.createElement(s, { ...be, ref: _ }), [_, s, be]);
- return HS.useMemo(
- () => (z ? HS.createElement(x.Provider, { value: ee }, _e) : _e),
- [x, _e, ee]
- );
- }
- const L = HS.memo(ConnectFunction);
- if (((L.WrappedComponent = s), (L.displayName = ConnectFunction.displayName = i), j)) {
- const o = HS.forwardRef(function forwardConnectRef(s, o) {
- return HS.createElement(L, { ...s, reactReduxForwardedRef: o });
- });
- return (o.displayName = i), (o.WrappedComponent = s), hoistNonReactStatics(o, s);
- }
- return hoistNonReactStatics(L, s);
- };
- };
- var jx = function Provider({
- store: s,
- context: o,
- children: i,
- serverState: u,
- stabilityCheck: _ = 'once',
- identityFunctionCheck: w = 'once'
- }) {
- const x = HS.useMemo(() => {
- const o = createSubscription(s);
- return {
- store: s,
- subscription: o,
- getServerState: u ? () => u : void 0,
- stabilityCheck: _,
- identityFunctionCheck: w
- };
- }, [s, u, _, w]),
- C = HS.useMemo(() => s.getState(), [s]);
- mx(() => {
- const { subscription: o } = x;
- return (
- (o.onStateChange = o.notifyNestedSubs),
- o.trySubscribe(),
- C !== s.getState() && o.notifyNestedSubs(),
- () => {
- o.tryUnsubscribe(), (o.onStateChange = void 0);
- }
- );
- }, [x, C]);
- const j = o || YS;
- return HS.createElement(j.Provider, { value: x }, i);
- };
- var Ix;
- (Ix = KS.useSyncExternalStoreWithSelector),
- ((s) => {
- Cx = s;
- })(Pe.useSyncExternalStore);
- var Px = __webpack_require__(83488),
- Mx = __webpack_require__.n(Px);
- const withSystem = (s) => (o) => {
- const { fn: i } = s();
- class WithSystem extends Pe.Component {
- render() {
- return Pe.createElement(o, Rn()({}, s(), this.props, this.context));
- }
- }
- return (WithSystem.displayName = `WithSystem(${i.getDisplayName(o)})`), WithSystem;
- },
- withRoot = (s, o) => (i) => {
- const { fn: u } = s();
- class WithRoot extends Pe.Component {
- render() {
- return Pe.createElement(
- jx,
- { store: o },
- Pe.createElement(i, Rn()({}, this.props, this.context))
- );
- }
- }
- return (WithRoot.displayName = `WithRoot(${u.getDisplayName(i)})`), WithRoot;
- },
- withConnect = (s, o, i) =>
- compose(
- i ? withRoot(s, i) : Mx(),
- Ax((i, u) => {
- const _ = { ...u, ...s() },
- w = o.prototype?.mapStateToProps || ((s) => ({ state: s }));
- return w(i, _);
- }),
- withSystem(s)
- )(o),
- handleProps = (s, o, i, u) => {
- for (const _ in o) {
- const w = o[_];
- 'function' == typeof w && w(i[_], u[_], s());
- }
- },
- withMappedContainer = (s, o, i) => (o, u) => {
- const { fn: _ } = s(),
- w = i(o, 'root');
- class WithMappedContainer extends Pe.Component {
- constructor(o, i) {
- super(o, i), handleProps(s, u, o, {});
- }
- UNSAFE_componentWillReceiveProps(o) {
- handleProps(s, u, o, this.props);
- }
- render() {
- const s = Yt()(this.props, u ? Object.keys(u) : []);
- return Pe.createElement(w, s);
- }
- }
- return (
- (WithMappedContainer.displayName = `WithMappedContainer(${_.getDisplayName(w)})`),
- WithMappedContainer
- );
- },
- render = (s, o, i, u) => (_) => {
- const w = i(s, o, u)('App', 'root'),
- { createRoot: x } = WS;
- x(_).render(Pe.createElement(w, null));
- },
- getComponent =
- (s, o, i) =>
- (u, _, w = {}) => {
- if ('string' != typeof u)
- throw new TypeError('Need a string, to fetch a component. Was given a ' + typeof u);
- const x = i(u);
- return x
- ? _
- ? 'root' === _
- ? withConnect(s, x, o())
- : withConnect(s, x)
- : x
- : (w.failSilently || s().log.warn('Could not find component:', u), null);
- },
- getDisplayName = (s) => s.displayName || s.name || 'Component',
- view = ({ getComponents: s, getStore: o, getSystem: i }) => {
- const u = ((s) => jt(s, (...s) => JSON.stringify(s)))(getComponent(i, o, s)),
- _ = ((s) => utils_memoizeN(s, (...s) => s))(withMappedContainer(i, 0, u));
- return {
- rootInjects: {
- getComponent: u,
- makeMappedContainer: _,
- render: render(i, o, getComponent, s)
- },
- fn: { getDisplayName }
- };
- },
- view_legacy = ({ React: s, getSystem: o, getStore: i, getComponents: u }) => {
- const _ = {},
- w = parseInt(s?.version, 10);
- return (
- w >= 16 &&
- w < 18 &&
- (_.render = ((s, o, i, u) => (_) => {
- const w = i(s, o, u)('App', 'root');
- WS.render(Pe.createElement(w, null), _);
- })(o, i, getComponent, u)),
- { rootInjects: _ }
- );
- };
- function downloadUrlPlugin(s) {
- let { fn: o } = s;
- const i = {
- download:
- (s) =>
- ({ errActions: i, specSelectors: u, specActions: _, getConfigs: w }) => {
- let { fetch: x } = o;
- const C = w();
- function next(o) {
- if (o instanceof Error || o.status >= 400)
- return (
- _.updateLoadingStatus('failed'),
- i.newThrownErr(
- Object.assign(new Error((o.message || o.statusText) + ' ' + s), {
- source: 'fetch'
- })
- ),
- void (
- !o.status &&
- o instanceof Error &&
- (function checkPossibleFailReasons() {
- try {
- let o;
- if (
- ('URL' in at
- ? (o = new URL(s))
- : ((o = document.createElement('a')), (o.href = s)),
- 'https:' !== o.protocol && 'https:' === at.location.protocol)
- ) {
- const s = Object.assign(
- new Error(
- `Possible mixed-content issue? The page was loaded over https:// but a ${o.protocol}// URL was specified. Check that you are not attempting to load mixed content.`
- ),
- { source: 'fetch' }
- );
- return void i.newThrownErr(s);
- }
- if (o.origin !== at.location.origin) {
- const s = Object.assign(
- new Error(
- `Possible cross-origin (CORS) issue? The URL origin (${o.origin}) does not match the page (${at.location.origin}). Check the server returns the correct 'Access-Control-Allow-*' headers.`
- ),
- { source: 'fetch' }
- );
- i.newThrownErr(s);
- }
- } catch (s) {
- return;
- }
- })()
- )
- );
- _.updateLoadingStatus('success'),
- _.updateSpec(o.text),
- u.url() !== s && _.updateUrl(s);
- }
- (s = s || u.url()),
- _.updateLoadingStatus('loading'),
- i.clear({ source: 'fetch' }),
- x({
- url: s,
- loadSpec: !0,
- requestInterceptor: C.requestInterceptor || ((s) => s),
- responseInterceptor: C.responseInterceptor || ((s) => s),
- credentials: 'same-origin',
- headers: { Accept: 'application/json,*/*' }
- }).then(next, next);
- },
- updateLoadingStatus: (s) => {
- let o = [null, 'loading', 'failed', 'success', 'failedConfig'];
- return (
- -1 === o.indexOf(s) &&
- console.error(`Error: ${s} is not one of ${JSON.stringify(o)}`),
- { type: 'spec_update_loading_status', payload: s }
- );
- }
- };
- let u = {
- loadingStatus: Ut(
- (s) => s || (0, qe.Map)(),
- (s) => s.get('loadingStatus') || null
- )
- };
- return {
- statePlugins: {
- spec: {
- actions: i,
- reducers: {
- spec_update_loading_status: (s, o) =>
- 'string' == typeof o.payload ? s.set('loadingStatus', o.payload) : s
- },
- selectors: u
- }
- }
- };
- }
- function arrayLikeToArray_arrayLikeToArray(s, o) {
- (null == o || o > s.length) && (o = s.length);
- for (var i = 0, u = Array(o); i < o; i++) u[i] = s[i];
- return u;
- }
- function toConsumableArray_toConsumableArray(s) {
- return (
- (function arrayWithoutHoles_arrayWithoutHoles(s) {
- if (Array.isArray(s)) return arrayLikeToArray_arrayLikeToArray(s);
- })(s) ||
- (function iterableToArray_iterableToArray(s) {
- if (
- ('undefined' != typeof Symbol && null != s[Symbol.iterator]) ||
- null != s['@@iterator']
- )
- return Array.from(s);
- })(s) ||
- (function unsupportedIterableToArray_unsupportedIterableToArray(s, o) {
- if (s) {
- if ('string' == typeof s) return arrayLikeToArray_arrayLikeToArray(s, o);
- var i = {}.toString.call(s).slice(8, -1);
- return (
- 'Object' === i && s.constructor && (i = s.constructor.name),
- 'Map' === i || 'Set' === i
- ? Array.from(s)
- : 'Arguments' === i || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)
- ? arrayLikeToArray_arrayLikeToArray(s, o)
- : void 0
- );
- }
- })(s) ||
- (function nonIterableSpread_nonIterableSpread() {
- throw new TypeError(
- 'Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.'
- );
- })()
- );
- }
- function typeof_typeof(s) {
- return (
- (typeof_typeof =
- 'function' == typeof Symbol && 'symbol' == typeof Symbol.iterator
- ? function (s) {
- return typeof s;
- }
- : function (s) {
- return s &&
- 'function' == typeof Symbol &&
- s.constructor === Symbol &&
- s !== Symbol.prototype
- ? 'symbol'
- : typeof s;
- }),
- typeof_typeof(s)
- );
- }
- function toPropertyKey(s) {
- var o = (function toPrimitive(s, o) {
- if ('object' != typeof_typeof(s) || !s) return s;
- var i = s[Symbol.toPrimitive];
- if (void 0 !== i) {
- var u = i.call(s, o || 'default');
- if ('object' != typeof_typeof(u)) return u;
- throw new TypeError('@@toPrimitive must return a primitive value.');
- }
- return ('string' === o ? String : Number)(s);
- })(s, 'string');
- return 'symbol' == typeof_typeof(o) ? o : o + '';
- }
- function defineProperty_defineProperty(s, o, i) {
- return (
- (o = toPropertyKey(o)) in s
- ? Object.defineProperty(s, o, {
- value: i,
- enumerable: !0,
- configurable: !0,
- writable: !0
- })
- : (s[o] = i),
- s
- );
- }
- function extends_extends() {
- return (
- (extends_extends = Object.assign
- ? Object.assign.bind()
- : function (s) {
- for (var o = 1; o < arguments.length; o++) {
- var i = arguments[o];
- for (var u in i) ({}).hasOwnProperty.call(i, u) && (s[u] = i[u]);
- }
- return s;
- }),
- extends_extends.apply(null, arguments)
- );
- }
- function create_element_ownKeys(s, o) {
- var i = Object.keys(s);
- if (Object.getOwnPropertySymbols) {
- var u = Object.getOwnPropertySymbols(s);
- o &&
- (u = u.filter(function (o) {
- return Object.getOwnPropertyDescriptor(s, o).enumerable;
- })),
- i.push.apply(i, u);
- }
- return i;
- }
- function _objectSpread(s) {
- for (var o = 1; o < arguments.length; o++) {
- var i = null != arguments[o] ? arguments[o] : {};
- o % 2
- ? create_element_ownKeys(Object(i), !0).forEach(function (o) {
- defineProperty_defineProperty(s, o, i[o]);
- })
- : Object.getOwnPropertyDescriptors
- ? Object.defineProperties(s, Object.getOwnPropertyDescriptors(i))
- : create_element_ownKeys(Object(i)).forEach(function (o) {
- Object.defineProperty(s, o, Object.getOwnPropertyDescriptor(i, o));
- });
- }
- return s;
- }
- var Tx = {};
- function createStyleObject(s) {
- var o = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {},
- i = arguments.length > 2 ? arguments[2] : void 0;
- return (function getClassNameCombinations(s) {
- if (0 === s.length || 1 === s.length) return s;
- var o = s.join('.');
- return (
- Tx[o] ||
- (Tx[o] = (function powerSetPermutations(s) {
- var o = s.length;
- return 0 === o || 1 === o
- ? s
- : 2 === o
- ? [
- s[0],
- s[1],
- ''.concat(s[0], '.').concat(s[1]),
- ''.concat(s[1], '.').concat(s[0])
- ]
- : 3 === o
- ? [
- s[0],
- s[1],
- s[2],
- ''.concat(s[0], '.').concat(s[1]),
- ''.concat(s[0], '.').concat(s[2]),
- ''.concat(s[1], '.').concat(s[0]),
- ''.concat(s[1], '.').concat(s[2]),
- ''.concat(s[2], '.').concat(s[0]),
- ''.concat(s[2], '.').concat(s[1]),
- ''.concat(s[0], '.').concat(s[1], '.').concat(s[2]),
- ''.concat(s[0], '.').concat(s[2], '.').concat(s[1]),
- ''.concat(s[1], '.').concat(s[0], '.').concat(s[2]),
- ''.concat(s[1], '.').concat(s[2], '.').concat(s[0]),
- ''.concat(s[2], '.').concat(s[0], '.').concat(s[1]),
- ''.concat(s[2], '.').concat(s[1], '.').concat(s[0])
- ]
- : o >= 4
- ? [
- s[0],
- s[1],
- s[2],
- s[3],
- ''.concat(s[0], '.').concat(s[1]),
- ''.concat(s[0], '.').concat(s[2]),
- ''.concat(s[0], '.').concat(s[3]),
- ''.concat(s[1], '.').concat(s[0]),
- ''.concat(s[1], '.').concat(s[2]),
- ''.concat(s[1], '.').concat(s[3]),
- ''.concat(s[2], '.').concat(s[0]),
- ''.concat(s[2], '.').concat(s[1]),
- ''.concat(s[2], '.').concat(s[3]),
- ''.concat(s[3], '.').concat(s[0]),
- ''.concat(s[3], '.').concat(s[1]),
- ''.concat(s[3], '.').concat(s[2]),
- ''.concat(s[0], '.').concat(s[1], '.').concat(s[2]),
- ''.concat(s[0], '.').concat(s[1], '.').concat(s[3]),
- ''.concat(s[0], '.').concat(s[2], '.').concat(s[1]),
- ''.concat(s[0], '.').concat(s[2], '.').concat(s[3]),
- ''.concat(s[0], '.').concat(s[3], '.').concat(s[1]),
- ''.concat(s[0], '.').concat(s[3], '.').concat(s[2]),
- ''.concat(s[1], '.').concat(s[0], '.').concat(s[2]),
- ''.concat(s[1], '.').concat(s[0], '.').concat(s[3]),
- ''.concat(s[1], '.').concat(s[2], '.').concat(s[0]),
- ''.concat(s[1], '.').concat(s[2], '.').concat(s[3]),
- ''.concat(s[1], '.').concat(s[3], '.').concat(s[0]),
- ''.concat(s[1], '.').concat(s[3], '.').concat(s[2]),
- ''.concat(s[2], '.').concat(s[0], '.').concat(s[1]),
- ''.concat(s[2], '.').concat(s[0], '.').concat(s[3]),
- ''.concat(s[2], '.').concat(s[1], '.').concat(s[0]),
- ''.concat(s[2], '.').concat(s[1], '.').concat(s[3]),
- ''.concat(s[2], '.').concat(s[3], '.').concat(s[0]),
- ''.concat(s[2], '.').concat(s[3], '.').concat(s[1]),
- ''.concat(s[3], '.').concat(s[0], '.').concat(s[1]),
- ''.concat(s[3], '.').concat(s[0], '.').concat(s[2]),
- ''.concat(s[3], '.').concat(s[1], '.').concat(s[0]),
- ''.concat(s[3], '.').concat(s[1], '.').concat(s[2]),
- ''.concat(s[3], '.').concat(s[2], '.').concat(s[0]),
- ''.concat(s[3], '.').concat(s[2], '.').concat(s[1]),
- ''.concat(s[0], '.').concat(s[1], '.').concat(s[2], '.').concat(s[3]),
- ''.concat(s[0], '.').concat(s[1], '.').concat(s[3], '.').concat(s[2]),
- ''.concat(s[0], '.').concat(s[2], '.').concat(s[1], '.').concat(s[3]),
- ''.concat(s[0], '.').concat(s[2], '.').concat(s[3], '.').concat(s[1]),
- ''.concat(s[0], '.').concat(s[3], '.').concat(s[1], '.').concat(s[2]),
- ''.concat(s[0], '.').concat(s[3], '.').concat(s[2], '.').concat(s[1]),
- ''.concat(s[1], '.').concat(s[0], '.').concat(s[2], '.').concat(s[3]),
- ''.concat(s[1], '.').concat(s[0], '.').concat(s[3], '.').concat(s[2]),
- ''.concat(s[1], '.').concat(s[2], '.').concat(s[0], '.').concat(s[3]),
- ''.concat(s[1], '.').concat(s[2], '.').concat(s[3], '.').concat(s[0]),
- ''.concat(s[1], '.').concat(s[3], '.').concat(s[0], '.').concat(s[2]),
- ''.concat(s[1], '.').concat(s[3], '.').concat(s[2], '.').concat(s[0]),
- ''.concat(s[2], '.').concat(s[0], '.').concat(s[1], '.').concat(s[3]),
- ''.concat(s[2], '.').concat(s[0], '.').concat(s[3], '.').concat(s[1]),
- ''.concat(s[2], '.').concat(s[1], '.').concat(s[0], '.').concat(s[3]),
- ''.concat(s[2], '.').concat(s[1], '.').concat(s[3], '.').concat(s[0]),
- ''.concat(s[2], '.').concat(s[3], '.').concat(s[0], '.').concat(s[1]),
- ''.concat(s[2], '.').concat(s[3], '.').concat(s[1], '.').concat(s[0]),
- ''.concat(s[3], '.').concat(s[0], '.').concat(s[1], '.').concat(s[2]),
- ''.concat(s[3], '.').concat(s[0], '.').concat(s[2], '.').concat(s[1]),
- ''.concat(s[3], '.').concat(s[1], '.').concat(s[0], '.').concat(s[2]),
- ''.concat(s[3], '.').concat(s[1], '.').concat(s[2], '.').concat(s[0]),
- ''.concat(s[3], '.').concat(s[2], '.').concat(s[0], '.').concat(s[1]),
- ''.concat(s[3], '.').concat(s[2], '.').concat(s[1], '.').concat(s[0])
- ]
- : void 0;
- })(s)),
- Tx[o]
- );
- })(
- s.filter(function (s) {
- return 'token' !== s;
- })
- ).reduce(function (s, o) {
- return _objectSpread(_objectSpread({}, s), i[o]);
- }, o);
- }
- function createClassNameString(s) {
- return s.join(' ');
- }
- function createElement(s) {
- var o = s.node,
- i = s.stylesheet,
- u = s.style,
- _ = void 0 === u ? {} : u,
- w = s.useInlineStyles,
- x = s.key,
- C = o.properties,
- j = o.type,
- L = o.tagName,
- B = o.value;
- if ('text' === j) return B;
- if (L) {
- var $,
- V = (function createChildren(s, o) {
- var i = 0;
- return function (u) {
- return (
- (i += 1),
- u.map(function (u, _) {
- return createElement({
- node: u,
- stylesheet: s,
- useInlineStyles: o,
- key: 'code-segment-'.concat(i, '-').concat(_)
- });
- })
- );
- };
- })(i, w);
- if (w) {
- var U = Object.keys(i).reduce(function (s, o) {
- return (
- o.split('.').forEach(function (o) {
- s.includes(o) || s.push(o);
- }),
- s
- );
- }, []),
- z = C.className && C.className.includes('token') ? ['token'] : [],
- Y =
- C.className &&
- z.concat(
- C.className.filter(function (s) {
- return !U.includes(s);
- })
- );
- $ = _objectSpread(
- _objectSpread({}, C),
- {},
- {
- className: createClassNameString(Y) || void 0,
- style: createStyleObject(C.className, Object.assign({}, C.style, _), i)
- }
- );
- } else
- $ = _objectSpread(
- _objectSpread({}, C),
- {},
- { className: createClassNameString(C.className) }
- );
- var Z = V(o.children);
- return Pe.createElement(L, extends_extends({ key: x }, $), Z);
- }
- }
- var Nx = [
- 'language',
- 'children',
- 'style',
- 'customStyle',
- 'codeTagProps',
- 'useInlineStyles',
- 'showLineNumbers',
- 'showInlineLineNumbers',
- 'startingLineNumber',
- 'lineNumberContainerStyle',
- 'lineNumberStyle',
- 'wrapLines',
- 'wrapLongLines',
- 'lineProps',
- 'renderer',
- 'PreTag',
- 'CodeTag',
- 'code',
- 'astGenerator'
- ];
- function highlight_ownKeys(s, o) {
- var i = Object.keys(s);
- if (Object.getOwnPropertySymbols) {
- var u = Object.getOwnPropertySymbols(s);
- o &&
- (u = u.filter(function (o) {
- return Object.getOwnPropertyDescriptor(s, o).enumerable;
- })),
- i.push.apply(i, u);
- }
- return i;
- }
- function highlight_objectSpread(s) {
- for (var o = 1; o < arguments.length; o++) {
- var i = null != arguments[o] ? arguments[o] : {};
- o % 2
- ? highlight_ownKeys(Object(i), !0).forEach(function (o) {
- defineProperty_defineProperty(s, o, i[o]);
- })
- : Object.getOwnPropertyDescriptors
- ? Object.defineProperties(s, Object.getOwnPropertyDescriptors(i))
- : highlight_ownKeys(Object(i)).forEach(function (o) {
- Object.defineProperty(s, o, Object.getOwnPropertyDescriptor(i, o));
- });
- }
- return s;
- }
- var Rx = /\n/g;
- function AllLineNumbers(s) {
- var o = s.codeString,
- i = s.codeStyle,
- u = s.containerStyle,
- _ = void 0 === u ? { float: 'left', paddingRight: '10px' } : u,
- w = s.numberStyle,
- x = void 0 === w ? {} : w,
- C = s.startingLineNumber;
- return Pe.createElement(
- 'code',
- { style: Object.assign({}, i, _) },
- (function getAllLineNumbers(s) {
- var o = s.lines,
- i = s.startingLineNumber,
- u = s.style;
- return o.map(function (s, o) {
- var _ = o + i;
- return Pe.createElement(
- 'span',
- {
- key: 'line-'.concat(o),
- className: 'react-syntax-highlighter-line-number',
- style: 'function' == typeof u ? u(_) : u
- },
- ''.concat(_, '\n')
- );
- });
- })({ lines: o.replace(/\n$/, '').split('\n'), style: x, startingLineNumber: C })
- );
- }
- function getInlineLineNumber(s, o) {
- return {
- type: 'element',
- tagName: 'span',
- properties: {
- key: 'line-number--'.concat(s),
- className: ['comment', 'linenumber', 'react-syntax-highlighter-line-number'],
- style: o
- },
- children: [{ type: 'text', value: s }]
- };
- }
- function assembleLineNumberStyles(s, o, i) {
- var u,
- _ = {
- display: 'inline-block',
- minWidth: ((u = i), ''.concat(u.toString().length, '.25em')),
- paddingRight: '1em',
- textAlign: 'right',
- userSelect: 'none'
- },
- w = 'function' == typeof s ? s(o) : s;
- return highlight_objectSpread(highlight_objectSpread({}, _), w);
- }
- function createLineElement(s) {
- var o = s.children,
- i = s.lineNumber,
- u = s.lineNumberStyle,
- _ = s.largestLineNumber,
- w = s.showInlineLineNumbers,
- x = s.lineProps,
- C = void 0 === x ? {} : x,
- j = s.className,
- L = void 0 === j ? [] : j,
- B = s.showLineNumbers,
- $ = s.wrapLongLines,
- V = s.wrapLines,
- U =
- void 0 !== V && V
- ? highlight_objectSpread({}, 'function' == typeof C ? C(i) : C)
- : {};
- if (
- ((U.className = U.className
- ? [].concat(
- toConsumableArray_toConsumableArray(U.className.trim().split(/\s+/)),
- toConsumableArray_toConsumableArray(L)
- )
- : L),
- i && w)
- ) {
- var z = assembleLineNumberStyles(u, i, _);
- o.unshift(getInlineLineNumber(i, z));
- }
- return (
- $ & B && (U.style = highlight_objectSpread({ display: 'flex' }, U.style)),
- { type: 'element', tagName: 'span', properties: U, children: o }
- );
- }
- function flattenCodeTree(s) {
- for (
- var o = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : [],
- i = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : [],
- u = 0;
- u < s.length;
- u++
- ) {
- var _ = s[u];
- if ('text' === _.type)
- i.push(
- createLineElement({
- children: [_],
- className: toConsumableArray_toConsumableArray(new Set(o))
- })
- );
- else if (_.children) {
- var w = o.concat(_.properties.className);
- flattenCodeTree(_.children, w).forEach(function (s) {
- return i.push(s);
- });
- }
- }
- return i;
- }
- function processLines(s, o, i, u, _, w, x, C, j) {
- var L,
- B = flattenCodeTree(s.value),
- $ = [],
- V = -1,
- U = 0;
- function createLine(s, w) {
- var L = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : [];
- return o || L.length > 0
- ? (function createWrappedLine(s, w) {
- return createLineElement({
- children: s,
- lineNumber: w,
- lineNumberStyle: C,
- largestLineNumber: x,
- showInlineLineNumbers: _,
- lineProps: i,
- className: arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : [],
- showLineNumbers: u,
- wrapLongLines: j,
- wrapLines: o
- });
- })(s, w, L)
- : (function createUnwrappedLine(s, o) {
- if (u && o && _) {
- var i = assembleLineNumberStyles(C, o, x);
- s.unshift(getInlineLineNumber(o, i));
- }
- return s;
- })(s, w);
- }
- for (
- var z = function _loop() {
- var s = B[U],
- o = s.children[0].value,
- i = (function getNewLines(s) {
- return s.match(Rx);
- })(o);
- if (i) {
- var _ = o.split('\n');
- _.forEach(function (o, i) {
- var x = u && $.length + w,
- C = { type: 'text', value: ''.concat(o, '\n') };
- if (0 === i) {
- var j = createLine(
- B.slice(V + 1, U).concat(
- createLineElement({ children: [C], className: s.properties.className })
- ),
- x
- );
- $.push(j);
- } else if (i === _.length - 1) {
- var L = B[U + 1] && B[U + 1].children && B[U + 1].children[0],
- z = { type: 'text', value: ''.concat(o) };
- if (L) {
- var Y = createLineElement({
- children: [z],
- className: s.properties.className
- });
- B.splice(U + 1, 0, Y);
- } else {
- var Z = createLine([z], x, s.properties.className);
- $.push(Z);
- }
- } else {
- var ee = createLine([C], x, s.properties.className);
- $.push(ee);
- }
- }),
- (V = U);
- }
- U++;
- };
- U < B.length;
- )
- z();
- if (V !== B.length - 1) {
- var Y = B.slice(V + 1, B.length);
- if (Y && Y.length) {
- var Z = createLine(Y, u && $.length + w);
- $.push(Z);
- }
- }
- return o ? $ : (L = []).concat.apply(L, $);
- }
- function defaultRenderer(s) {
- var o = s.rows,
- i = s.stylesheet,
- u = s.useInlineStyles;
- return o.map(function (s, o) {
- return createElement({
- node: s,
- stylesheet: i,
- useInlineStyles: u,
- key: 'code-segement'.concat(o)
- });
- });
- }
- function isHighlightJs(s) {
- return s && void 0 !== s.highlightAuto;
- }
- var Dx = __webpack_require__(43768),
- Lx = (function highlight(s, o) {
- return function SyntaxHighlighter(i) {
- var u = i.language,
- _ = i.children,
- w = i.style,
- x = void 0 === w ? o : w,
- C = i.customStyle,
- j = void 0 === C ? {} : C,
- L = i.codeTagProps,
- B =
- void 0 === L
- ? {
- className: u ? 'language-'.concat(u) : void 0,
- style: highlight_objectSpread(
- highlight_objectSpread({}, x['code[class*="language-"]']),
- x['code[class*="language-'.concat(u, '"]')]
- )
- }
- : L,
- $ = i.useInlineStyles,
- V = void 0 === $ || $,
- U = i.showLineNumbers,
- z = void 0 !== U && U,
- Y = i.showInlineLineNumbers,
- Z = void 0 === Y || Y,
- ee = i.startingLineNumber,
- ie = void 0 === ee ? 1 : ee,
- ae = i.lineNumberContainerStyle,
- le = i.lineNumberStyle,
- ce = void 0 === le ? {} : le,
- pe = i.wrapLines,
- de = i.wrapLongLines,
- fe = void 0 !== de && de,
- ye = i.lineProps,
- be = void 0 === ye ? {} : ye,
- _e = i.renderer,
- we = i.PreTag,
- Se = void 0 === we ? 'pre' : we,
- xe = i.CodeTag,
- Te = void 0 === xe ? 'code' : xe,
- Re = i.code,
- qe = void 0 === Re ? (Array.isArray(_) ? _[0] : _) || '' : Re,
- $e = i.astGenerator,
- ze = (function _objectWithoutProperties(s, o) {
- if (null == s) return {};
- var i,
- u,
- _ = (function _objectWithoutPropertiesLoose(s, o) {
- if (null == s) return {};
- var i = {};
- for (var u in s)
- if ({}.hasOwnProperty.call(s, u)) {
- if (o.includes(u)) continue;
- i[u] = s[u];
- }
- return i;
- })(s, o);
- if (Object.getOwnPropertySymbols) {
- var w = Object.getOwnPropertySymbols(s);
- for (u = 0; u < w.length; u++)
- (i = w[u]),
- o.includes(i) || ({}.propertyIsEnumerable.call(s, i) && (_[i] = s[i]));
- }
- return _;
- })(i, Nx);
- $e = $e || s;
- var We = z
- ? Pe.createElement(AllLineNumbers, {
- containerStyle: ae,
- codeStyle: B.style || {},
- numberStyle: ce,
- startingLineNumber: ie,
- codeString: qe
- })
- : null,
- He = x.hljs || x['pre[class*="language-"]'] || { backgroundColor: '#fff' },
- Ye = isHighlightJs($e) ? 'hljs' : 'prismjs',
- Xe = V
- ? Object.assign({}, ze, { style: Object.assign({}, He, j) })
- : Object.assign({}, ze, {
- className: ze.className ? ''.concat(Ye, ' ').concat(ze.className) : Ye,
- style: Object.assign({}, j)
- });
- if (
- ((B.style = highlight_objectSpread(
- fe ? { whiteSpace: 'pre-wrap' } : { whiteSpace: 'pre' },
- B.style
- )),
- !$e)
- )
- return Pe.createElement(Se, Xe, We, Pe.createElement(Te, B, qe));
- ((void 0 === pe && _e) || fe) && (pe = !0), (_e = _e || defaultRenderer);
- var Qe = [{ type: 'text', value: qe }],
- et = (function getCodeTree(s) {
- var o = s.astGenerator,
- i = s.language,
- u = s.code,
- _ = s.defaultCodeValue;
- if (isHighlightJs(o)) {
- var w = (function (s, o) {
- return -1 !== s.listLanguages().indexOf(o);
- })(o, i);
- return 'text' === i
- ? { value: _, language: 'text' }
- : w
- ? o.highlight(i, u)
- : o.highlightAuto(u);
- }
- try {
- return i && 'text' !== i ? { value: o.highlight(u, i) } : { value: _ };
- } catch (s) {
- return { value: _ };
- }
- })({ astGenerator: $e, language: u, code: qe, defaultCodeValue: Qe });
- null === et.language && (et.value = Qe);
- var tt = et.value.length;
- 1 === tt &&
- 'text' === et.value[0].type &&
- (tt = et.value[0].value.split('\n').length);
- var rt = processLines(et, pe, be, z, Z, ie, tt + ie, ce, fe);
- return Pe.createElement(
- Se,
- Xe,
- Pe.createElement(
- Te,
- B,
- !Z && We,
- _e({ rows: rt, stylesheet: x, useInlineStyles: V })
- )
- );
- };
- })(Dx, {});
- Lx.registerLanguage = Dx.registerLanguage;
- const Bx = Lx;
- var Fx = __webpack_require__(95089);
- const qx = __webpack_require__.n(Fx)();
- var $x = __webpack_require__(65772);
- const Vx = __webpack_require__.n($x)();
- var Ux = __webpack_require__(17285);
- const zx = __webpack_require__.n(Ux)();
- var Wx = __webpack_require__(35344);
- const Kx = __webpack_require__.n(Wx)();
- var Hx = __webpack_require__(17533);
- const Jx = __webpack_require__.n(Hx)();
- var Gx = __webpack_require__(73402);
- const Yx = __webpack_require__.n(Gx)();
- var Xx = __webpack_require__(26571);
- const Zx = __webpack_require__.n(Xx)(),
- after_load = () => {
- Bx.registerLanguage('json', Vx),
- Bx.registerLanguage('js', qx),
- Bx.registerLanguage('xml', zx),
- Bx.registerLanguage('yaml', Jx),
- Bx.registerLanguage('http', Yx),
- Bx.registerLanguage('bash', Kx),
- Bx.registerLanguage('powershell', Zx),
- Bx.registerLanguage('javascript', qx);
- },
- Qx = {
- hljs: {
- display: 'block',
- overflowX: 'auto',
- padding: '0.5em',
- background: '#333',
- color: 'white'
- },
- 'hljs-name': { fontWeight: 'bold' },
- 'hljs-strong': { fontWeight: 'bold' },
- 'hljs-code': { fontStyle: 'italic', color: '#888' },
- 'hljs-emphasis': { fontStyle: 'italic' },
- 'hljs-tag': { color: '#62c8f3' },
- 'hljs-variable': { color: '#ade5fc' },
- 'hljs-template-variable': { color: '#ade5fc' },
- 'hljs-selector-id': { color: '#ade5fc' },
- 'hljs-selector-class': { color: '#ade5fc' },
- 'hljs-string': { color: '#a2fca2' },
- 'hljs-bullet': { color: '#d36363' },
- 'hljs-type': { color: '#ffa' },
- 'hljs-title': { color: '#ffa' },
- 'hljs-section': { color: '#ffa' },
- 'hljs-attribute': { color: '#ffa' },
- 'hljs-quote': { color: '#ffa' },
- 'hljs-built_in': { color: '#ffa' },
- 'hljs-builtin-name': { color: '#ffa' },
- 'hljs-number': { color: '#d36363' },
- 'hljs-symbol': { color: '#d36363' },
- 'hljs-keyword': { color: '#fcc28c' },
- 'hljs-selector-tag': { color: '#fcc28c' },
- 'hljs-literal': { color: '#fcc28c' },
- 'hljs-comment': { color: '#888' },
- 'hljs-deletion': { color: '#333', backgroundColor: '#fc9b9b' },
- 'hljs-regexp': { color: '#c6b4f0' },
- 'hljs-link': { color: '#c6b4f0' },
- 'hljs-meta': { color: '#fc9b9b' },
- 'hljs-addition': { backgroundColor: '#a2fca2', color: '#333' }
- },
- tk = {
- agate: Qx,
- arta: {
- hljs: {
- display: 'block',
- overflowX: 'auto',
- padding: '0.5em',
- background: '#222',
- color: '#aaa'
- },
- 'hljs-subst': { color: '#aaa' },
- 'hljs-section': { color: '#fff', fontWeight: 'bold' },
- 'hljs-comment': { color: '#444' },
- 'hljs-quote': { color: '#444' },
- 'hljs-meta': { color: '#444' },
- 'hljs-string': { color: '#ffcc33' },
- 'hljs-symbol': { color: '#ffcc33' },
- 'hljs-bullet': { color: '#ffcc33' },
- 'hljs-regexp': { color: '#ffcc33' },
- 'hljs-number': { color: '#00cc66' },
- 'hljs-addition': { color: '#00cc66' },
- 'hljs-built_in': { color: '#32aaee' },
- 'hljs-builtin-name': { color: '#32aaee' },
- 'hljs-literal': { color: '#32aaee' },
- 'hljs-type': { color: '#32aaee' },
- 'hljs-template-variable': { color: '#32aaee' },
- 'hljs-attribute': { color: '#32aaee' },
- 'hljs-link': { color: '#32aaee' },
- 'hljs-keyword': { color: '#6644aa' },
- 'hljs-selector-tag': { color: '#6644aa' },
- 'hljs-name': { color: '#6644aa' },
- 'hljs-selector-id': { color: '#6644aa' },
- 'hljs-selector-class': { color: '#6644aa' },
- 'hljs-title': { color: '#bb1166' },
- 'hljs-variable': { color: '#bb1166' },
- 'hljs-deletion': { color: '#bb1166' },
- 'hljs-template-tag': { color: '#bb1166' },
- 'hljs-doctag': { fontWeight: 'bold' },
- 'hljs-strong': { fontWeight: 'bold' },
- 'hljs-emphasis': { fontStyle: 'italic' }
- },
- monokai: {
- hljs: {
- display: 'block',
- overflowX: 'auto',
- padding: '0.5em',
- background: '#272822',
- color: '#ddd'
- },
- 'hljs-tag': { color: '#f92672' },
- 'hljs-keyword': { color: '#f92672', fontWeight: 'bold' },
- 'hljs-selector-tag': { color: '#f92672', fontWeight: 'bold' },
- 'hljs-literal': { color: '#f92672', fontWeight: 'bold' },
- 'hljs-strong': { color: '#f92672' },
- 'hljs-name': { color: '#f92672' },
- 'hljs-code': { color: '#66d9ef' },
- 'hljs-class .hljs-title': { color: 'white' },
- 'hljs-attribute': { color: '#bf79db' },
- 'hljs-symbol': { color: '#bf79db' },
- 'hljs-regexp': { color: '#bf79db' },
- 'hljs-link': { color: '#bf79db' },
- 'hljs-string': { color: '#a6e22e' },
- 'hljs-bullet': { color: '#a6e22e' },
- 'hljs-subst': { color: '#a6e22e' },
- 'hljs-title': { color: '#a6e22e', fontWeight: 'bold' },
- 'hljs-section': { color: '#a6e22e', fontWeight: 'bold' },
- 'hljs-emphasis': { color: '#a6e22e' },
- 'hljs-type': { color: '#a6e22e', fontWeight: 'bold' },
- 'hljs-built_in': { color: '#a6e22e' },
- 'hljs-builtin-name': { color: '#a6e22e' },
- 'hljs-selector-attr': { color: '#a6e22e' },
- 'hljs-selector-pseudo': { color: '#a6e22e' },
- 'hljs-addition': { color: '#a6e22e' },
- 'hljs-variable': { color: '#a6e22e' },
- 'hljs-template-tag': { color: '#a6e22e' },
- 'hljs-template-variable': { color: '#a6e22e' },
- 'hljs-comment': { color: '#75715e' },
- 'hljs-quote': { color: '#75715e' },
- 'hljs-deletion': { color: '#75715e' },
- 'hljs-meta': { color: '#75715e' },
- 'hljs-doctag': { fontWeight: 'bold' },
- 'hljs-selector-id': { fontWeight: 'bold' }
- },
- nord: {
- hljs: {
- display: 'block',
- overflowX: 'auto',
- padding: '0.5em',
- background: '#2E3440',
- color: '#D8DEE9'
- },
- 'hljs-subst': { color: '#D8DEE9' },
- 'hljs-selector-tag': { color: '#81A1C1' },
- 'hljs-selector-id': { color: '#8FBCBB', fontWeight: 'bold' },
- 'hljs-selector-class': { color: '#8FBCBB' },
- 'hljs-selector-attr': { color: '#8FBCBB' },
- 'hljs-selector-pseudo': { color: '#88C0D0' },
- 'hljs-addition': { backgroundColor: 'rgba(163, 190, 140, 0.5)' },
- 'hljs-deletion': { backgroundColor: 'rgba(191, 97, 106, 0.5)' },
- 'hljs-built_in': { color: '#8FBCBB' },
- 'hljs-type': { color: '#8FBCBB' },
- 'hljs-class': { color: '#8FBCBB' },
- 'hljs-function': { color: '#88C0D0' },
- 'hljs-function > .hljs-title': { color: '#88C0D0' },
- 'hljs-keyword': { color: '#81A1C1' },
- 'hljs-literal': { color: '#81A1C1' },
- 'hljs-symbol': { color: '#81A1C1' },
- 'hljs-number': { color: '#B48EAD' },
- 'hljs-regexp': { color: '#EBCB8B' },
- 'hljs-string': { color: '#A3BE8C' },
- 'hljs-title': { color: '#8FBCBB' },
- 'hljs-params': { color: '#D8DEE9' },
- 'hljs-bullet': { color: '#81A1C1' },
- 'hljs-code': { color: '#8FBCBB' },
- 'hljs-emphasis': { fontStyle: 'italic' },
- 'hljs-formula': { color: '#8FBCBB' },
- 'hljs-strong': { fontWeight: 'bold' },
- 'hljs-link:hover': { textDecoration: 'underline' },
- 'hljs-quote': { color: '#4C566A' },
- 'hljs-comment': { color: '#4C566A' },
- 'hljs-doctag': { color: '#8FBCBB' },
- 'hljs-meta': { color: '#5E81AC' },
- 'hljs-meta-keyword': { color: '#5E81AC' },
- 'hljs-meta-string': { color: '#A3BE8C' },
- 'hljs-attr': { color: '#8FBCBB' },
- 'hljs-attribute': { color: '#D8DEE9' },
- 'hljs-builtin-name': { color: '#81A1C1' },
- 'hljs-name': { color: '#81A1C1' },
- 'hljs-section': { color: '#88C0D0' },
- 'hljs-tag': { color: '#81A1C1' },
- 'hljs-variable': { color: '#D8DEE9' },
- 'hljs-template-variable': { color: '#D8DEE9' },
- 'hljs-template-tag': { color: '#5E81AC' },
- 'abnf .hljs-attribute': { color: '#88C0D0' },
- 'abnf .hljs-symbol': { color: '#EBCB8B' },
- 'apache .hljs-attribute': { color: '#88C0D0' },
- 'apache .hljs-section': { color: '#81A1C1' },
- 'arduino .hljs-built_in': { color: '#88C0D0' },
- 'aspectj .hljs-meta': { color: '#D08770' },
- 'aspectj > .hljs-title': { color: '#88C0D0' },
- 'bnf .hljs-attribute': { color: '#8FBCBB' },
- 'clojure .hljs-name': { color: '#88C0D0' },
- 'clojure .hljs-symbol': { color: '#EBCB8B' },
- 'coq .hljs-built_in': { color: '#88C0D0' },
- 'cpp .hljs-meta-string': { color: '#8FBCBB' },
- 'css .hljs-built_in': { color: '#88C0D0' },
- 'css .hljs-keyword': { color: '#D08770' },
- 'diff .hljs-meta': { color: '#8FBCBB' },
- 'ebnf .hljs-attribute': { color: '#8FBCBB' },
- 'glsl .hljs-built_in': { color: '#88C0D0' },
- 'groovy .hljs-meta:not(:first-child)': { color: '#D08770' },
- 'haxe .hljs-meta': { color: '#D08770' },
- 'java .hljs-meta': { color: '#D08770' },
- 'ldif .hljs-attribute': { color: '#8FBCBB' },
- 'lisp .hljs-name': { color: '#88C0D0' },
- 'lua .hljs-built_in': { color: '#88C0D0' },
- 'moonscript .hljs-built_in': { color: '#88C0D0' },
- 'nginx .hljs-attribute': { color: '#88C0D0' },
- 'nginx .hljs-section': { color: '#5E81AC' },
- 'pf .hljs-built_in': { color: '#88C0D0' },
- 'processing .hljs-built_in': { color: '#88C0D0' },
- 'scss .hljs-keyword': { color: '#81A1C1' },
- 'stylus .hljs-keyword': { color: '#81A1C1' },
- 'swift .hljs-meta': { color: '#D08770' },
- 'vim .hljs-built_in': { color: '#88C0D0', fontStyle: 'italic' },
- 'yaml .hljs-meta': { color: '#D08770' }
- },
- obsidian: {
- hljs: {
- display: 'block',
- overflowX: 'auto',
- padding: '0.5em',
- background: '#282b2e',
- color: '#e0e2e4'
- },
- 'hljs-keyword': { color: '#93c763', fontWeight: 'bold' },
- 'hljs-selector-tag': { color: '#93c763', fontWeight: 'bold' },
- 'hljs-literal': { color: '#93c763', fontWeight: 'bold' },
- 'hljs-selector-id': { color: '#93c763' },
- 'hljs-number': { color: '#ffcd22' },
- 'hljs-attribute': { color: '#668bb0' },
- 'hljs-code': { color: 'white' },
- 'hljs-class .hljs-title': { color: 'white' },
- 'hljs-section': { color: 'white', fontWeight: 'bold' },
- 'hljs-regexp': { color: '#d39745' },
- 'hljs-link': { color: '#d39745' },
- 'hljs-meta': { color: '#557182' },
- 'hljs-tag': { color: '#8cbbad' },
- 'hljs-name': { color: '#8cbbad', fontWeight: 'bold' },
- 'hljs-bullet': { color: '#8cbbad' },
- 'hljs-subst': { color: '#8cbbad' },
- 'hljs-emphasis': { color: '#8cbbad' },
- 'hljs-type': { color: '#8cbbad', fontWeight: 'bold' },
- 'hljs-built_in': { color: '#8cbbad' },
- 'hljs-selector-attr': { color: '#8cbbad' },
- 'hljs-selector-pseudo': { color: '#8cbbad' },
- 'hljs-addition': { color: '#8cbbad' },
- 'hljs-variable': { color: '#8cbbad' },
- 'hljs-template-tag': { color: '#8cbbad' },
- 'hljs-template-variable': { color: '#8cbbad' },
- 'hljs-string': { color: '#ec7600' },
- 'hljs-symbol': { color: '#ec7600' },
- 'hljs-comment': { color: '#818e96' },
- 'hljs-quote': { color: '#818e96' },
- 'hljs-deletion': { color: '#818e96' },
- 'hljs-selector-class': { color: '#A082BD' },
- 'hljs-doctag': { fontWeight: 'bold' },
- 'hljs-title': { fontWeight: 'bold' },
- 'hljs-strong': { fontWeight: 'bold' }
- },
- 'tomorrow-night': {
- 'hljs-comment': { color: '#969896' },
- 'hljs-quote': { color: '#969896' },
- 'hljs-variable': { color: '#cc6666' },
- 'hljs-template-variable': { color: '#cc6666' },
- 'hljs-tag': { color: '#cc6666' },
- 'hljs-name': { color: '#cc6666' },
- 'hljs-selector-id': { color: '#cc6666' },
- 'hljs-selector-class': { color: '#cc6666' },
- 'hljs-regexp': { color: '#cc6666' },
- 'hljs-deletion': { color: '#cc6666' },
- 'hljs-number': { color: '#de935f' },
- 'hljs-built_in': { color: '#de935f' },
- 'hljs-builtin-name': { color: '#de935f' },
- 'hljs-literal': { color: '#de935f' },
- 'hljs-type': { color: '#de935f' },
- 'hljs-params': { color: '#de935f' },
- 'hljs-meta': { color: '#de935f' },
- 'hljs-link': { color: '#de935f' },
- 'hljs-attribute': { color: '#f0c674' },
- 'hljs-string': { color: '#b5bd68' },
- 'hljs-symbol': { color: '#b5bd68' },
- 'hljs-bullet': { color: '#b5bd68' },
- 'hljs-addition': { color: '#b5bd68' },
- 'hljs-title': { color: '#81a2be' },
- 'hljs-section': { color: '#81a2be' },
- 'hljs-keyword': { color: '#b294bb' },
- 'hljs-selector-tag': { color: '#b294bb' },
- hljs: {
- display: 'block',
- overflowX: 'auto',
- background: '#1d1f21',
- color: '#c5c8c6',
- padding: '0.5em'
- },
- 'hljs-emphasis': { fontStyle: 'italic' },
- 'hljs-strong': { fontWeight: 'bold' }
- },
- idea: {
- hljs: {
- display: 'block',
- overflowX: 'auto',
- padding: '0.5em',
- color: '#000',
- background: '#fff'
- },
- 'hljs-subst': { fontWeight: 'normal', color: '#000' },
- 'hljs-title': { fontWeight: 'normal', color: '#000' },
- 'hljs-comment': { color: '#808080', fontStyle: 'italic' },
- 'hljs-quote': { color: '#808080', fontStyle: 'italic' },
- 'hljs-meta': { color: '#808000' },
- 'hljs-tag': { background: '#efefef' },
- 'hljs-section': { fontWeight: 'bold', color: '#000080' },
- 'hljs-name': { fontWeight: 'bold', color: '#000080' },
- 'hljs-literal': { fontWeight: 'bold', color: '#000080' },
- 'hljs-keyword': { fontWeight: 'bold', color: '#000080' },
- 'hljs-selector-tag': { fontWeight: 'bold', color: '#000080' },
- 'hljs-type': { fontWeight: 'bold', color: '#000080' },
- 'hljs-selector-id': { fontWeight: 'bold', color: '#000080' },
- 'hljs-selector-class': { fontWeight: 'bold', color: '#000080' },
- 'hljs-attribute': { fontWeight: 'bold', color: '#0000ff' },
- 'hljs-number': { fontWeight: 'normal', color: '#0000ff' },
- 'hljs-regexp': { fontWeight: 'normal', color: '#0000ff' },
- 'hljs-link': { fontWeight: 'normal', color: '#0000ff' },
- 'hljs-string': { color: '#008000', fontWeight: 'bold' },
- 'hljs-symbol': { color: '#000', background: '#d0eded', fontStyle: 'italic' },
- 'hljs-bullet': { color: '#000', background: '#d0eded', fontStyle: 'italic' },
- 'hljs-formula': { color: '#000', background: '#d0eded', fontStyle: 'italic' },
- 'hljs-doctag': { textDecoration: 'underline' },
- 'hljs-variable': { color: '#660e7a' },
- 'hljs-template-variable': { color: '#660e7a' },
- 'hljs-addition': { background: '#baeeba' },
- 'hljs-deletion': { background: '#ffc8bd' },
- 'hljs-emphasis': { fontStyle: 'italic' },
- 'hljs-strong': { fontWeight: 'bold' }
- }
- },
- rk = Qx,
- components_SyntaxHighlighter = ({
- language: s,
- className: o = '',
- getConfigs: i,
- syntaxHighlighting: u = {},
- children: _ = ''
- }) => {
- const w = i().syntaxHighlight.theme,
- { styles: x, defaultStyle: C } = u,
- j = x?.[w] ?? C;
- return Pe.createElement(Bx, { language: s, className: o, style: j }, _);
- };
- var nk = __webpack_require__(5419),
- sk = __webpack_require__.n(nk);
- const components_HighlightCode = ({
- fileName: s = 'response.txt',
- className: o,
- downloadable: i,
- getComponent: u,
- canCopy: _,
- language: w,
- children: x
- }) => {
- const C = (0, Pe.useRef)(null),
- j = u('SyntaxHighlighter', !0),
- handlePreventYScrollingBeyondElement = (s) => {
- const { target: o, deltaY: i } = s,
- { scrollHeight: u, offsetHeight: _, scrollTop: w } = o;
- u > _ && ((0 === w && i < 0) || (_ + w >= u && i > 0)) && s.preventDefault();
- };
- return (
- (0, Pe.useEffect)(() => {
- const s = Array.from(C.current.childNodes).filter(
- (s) => !!s.nodeType && s.classList.contains('microlight')
- );
- return (
- s.forEach((s) =>
- s.addEventListener('mousewheel', handlePreventYScrollingBeyondElement, {
- passive: !1
- })
- ),
- () => {
- s.forEach((s) =>
- s.removeEventListener('mousewheel', handlePreventYScrollingBeyondElement)
- );
- }
- );
- }, [x, o, w]),
- Pe.createElement(
- 'div',
- { className: 'highlight-code', ref: C },
- _ &&
- Pe.createElement(
- 'div',
- { className: 'copy-to-clipboard' },
- Pe.createElement(
- Jn.CopyToClipboard,
- { text: x },
- Pe.createElement('button', null)
- )
- ),
- i
- ? Pe.createElement(
- 'button',
- {
- className: 'download-contents',
- onClick: () => {
- sk()(x, s);
- }
- },
- 'Download'
- )
- : null,
- Pe.createElement(
- j,
- {
- language: w,
- className: Hn()(o, 'microlight'),
- renderPlainText: ({ children: s, PlainTextViewer: i }) =>
- Pe.createElement(i, { className: o }, s)
- },
- x
- )
- )
- );
- },
- components_PlainTextViewer = ({ className: s = '', children: o }) =>
- Pe.createElement('pre', { className: Hn()('microlight', s) }, o),
- wrap_components_SyntaxHighlighter =
- (s, o) =>
- ({ renderPlainText: i, children: u, ..._ }) => {
- const w = o.getConfigs().syntaxHighlight.activated,
- x = o.getComponent('PlainTextViewer');
- return w || 'function' != typeof i
- ? w
- ? Pe.createElement(s, _, u)
- : Pe.createElement(x, null, u)
- : i({ children: u, PlainTextViewer: x });
- },
- SyntaxHighlightingPlugin1 = () => ({
- afterLoad: after_load,
- rootInjects: { syntaxHighlighting: { styles: tk, defaultStyle: rk } },
- components: {
- SyntaxHighlighter: components_SyntaxHighlighter,
- HighlightCode: components_HighlightCode,
- PlainTextViewer: components_PlainTextViewer
- }
- }),
- SyntaxHighlightingPlugin2 = () => ({
- wrapComponents: { SyntaxHighlighter: wrap_components_SyntaxHighlighter }
- }),
- syntax_highlighting = () => [SyntaxHighlightingPlugin1, SyntaxHighlightingPlugin2],
- versions_after_load = () => {
- const {
- GIT_DIRTY: s,
- GIT_COMMIT: o,
- PACKAGE_VERSION: i,
- BUILD_TIME: u
- } = {
- PACKAGE_VERSION: '5.18.2',
- GIT_COMMIT: 'g1dd1f7cc',
- GIT_DIRTY: !0,
- BUILD_TIME: 'Thu, 07 Nov 2024 14:01:17 GMT'
- };
- (at.versions = at.versions || {}),
- (at.versions.swaggerUI = {
- version: i,
- gitRevision: o,
- gitDirty: s,
- buildTimestamp: u
- });
- },
- versions = () => ({ afterLoad: versions_after_load });
- var ok = __webpack_require__(47248),
- lk = __webpack_require__.n(ok);
- const uk = console.error,
- withErrorBoundary = (s) => (o) => {
- const { getComponent: i, fn: u } = s(),
- _ = i('ErrorBoundary'),
- w = u.getDisplayName(o);
- class WithErrorBoundary extends Pe.Component {
- render() {
- return Pe.createElement(
- _,
- { targetName: w, getComponent: i, fn: u },
- Pe.createElement(o, Rn()({}, this.props, this.context))
- );
- }
- }
- var x;
- return (
- (WithErrorBoundary.displayName = `WithErrorBoundary(${w})`),
- (x = o).prototype &&
- x.prototype.isReactComponent &&
- (WithErrorBoundary.prototype.mapStateToProps = o.prototype.mapStateToProps),
- WithErrorBoundary
- );
- },
- fallback = ({ name: s }) =>
- Pe.createElement(
- 'div',
- { className: 'fallback' },
- '😱 ',
- Pe.createElement(
- 'i',
- null,
- 'Could not render ',
- 't' === s ? 'this component' : s,
- ', see the console.'
- )
- );
- class ErrorBoundary extends Pe.Component {
- static defaultProps = {
- targetName: 'this component',
- getComponent: () => fallback,
- fn: { componentDidCatch: uk },
- children: null
- };
- static getDerivedStateFromError(s) {
- return { hasError: !0, error: s };
- }
- constructor(...s) {
- super(...s), (this.state = { hasError: !1, error: null });
- }
- componentDidCatch(s, o) {
- this.props.fn.componentDidCatch(s, o);
- }
- render() {
- const { getComponent: s, targetName: o, children: i } = this.props;
- if (this.state.hasError) {
- const i = s('Fallback');
- return Pe.createElement(i, { name: o });
- }
- return i;
- }
- }
- const pk = ErrorBoundary,
- safe_render =
- ({ componentList: s = [], fullOverride: o = !1 } = {}) =>
- ({ getSystem: i }) => {
- const u = o
- ? s
- : [
- 'App',
- 'BaseLayout',
- 'VersionPragmaFilter',
- 'InfoContainer',
- 'ServersContainer',
- 'SchemesContainer',
- 'AuthorizeBtnContainer',
- 'FilterContainer',
- 'Operations',
- 'OperationContainer',
- 'parameters',
- 'responses',
- 'OperationServers',
- 'Models',
- 'ModelWrapper',
- ...s
- ],
- _ = lk()(
- u,
- Array(u.length).fill((s, { fn: o }) => o.withErrorBoundary(s))
- );
- return {
- fn: { componentDidCatch: uk, withErrorBoundary: withErrorBoundary(i) },
- components: { ErrorBoundary: pk, Fallback: fallback },
- wrapComponents: _
- };
- };
- class App extends Pe.Component {
- getLayout() {
- const { getComponent: s, layoutSelectors: o } = this.props,
- i = o.current(),
- u = s(i, !0);
- return u || (() => Pe.createElement('h1', null, ' No layout defined for "', i, '" '));
- }
- render() {
- const s = this.getLayout();
- return Pe.createElement(s, null);
- }
- }
- const fk = App;
- class AuthorizationPopup extends Pe.Component {
- close = () => {
- let { authActions: s } = this.props;
- s.showDefinitions(!1);
- };
- render() {
- let {
- authSelectors: s,
- authActions: o,
- getComponent: i,
- errSelectors: u,
- specSelectors: _,
- fn: { AST: w = {} }
- } = this.props,
- x = s.shownDefinitions();
- const C = i('auths'),
- j = i('CloseIcon');
- return Pe.createElement(
- 'div',
- { className: 'dialog-ux' },
- Pe.createElement('div', { className: 'backdrop-ux' }),
- Pe.createElement(
- 'div',
- { className: 'modal-ux' },
- Pe.createElement(
- 'div',
- { className: 'modal-dialog-ux' },
- Pe.createElement(
- 'div',
- { className: 'modal-ux-inner' },
- Pe.createElement(
- 'div',
- { className: 'modal-ux-header' },
- Pe.createElement('h3', null, 'Available authorizations'),
- Pe.createElement(
- 'button',
- { type: 'button', className: 'close-modal', onClick: this.close },
- Pe.createElement(j, null)
- )
- ),
- Pe.createElement(
- 'div',
- { className: 'modal-ux-content' },
- x.valueSeq().map((x, j) =>
- Pe.createElement(C, {
- key: j,
- AST: w,
- definitions: x,
- getComponent: i,
- errSelectors: u,
- authSelectors: s,
- authActions: o,
- specSelectors: _
- })
- )
- )
- )
- )
- )
- );
- }
- }
- class AuthorizeBtn extends Pe.Component {
- render() {
- let { isAuthorized: s, showPopup: o, onClick: i, getComponent: u } = this.props;
- const _ = u('authorizationPopup', !0),
- w = u('LockAuthIcon', !0),
- x = u('UnlockAuthIcon', !0);
- return Pe.createElement(
- 'div',
- { className: 'auth-wrapper' },
- Pe.createElement(
- 'button',
- { className: s ? 'btn authorize locked' : 'btn authorize unlocked', onClick: i },
- Pe.createElement('span', null, 'Authorize'),
- s ? Pe.createElement(w, null) : Pe.createElement(x, null)
- ),
- o && Pe.createElement(_, null)
- );
- }
- }
- class AuthorizeBtnContainer extends Pe.Component {
- render() {
- const {
- authActions: s,
- authSelectors: o,
- specSelectors: i,
- getComponent: u
- } = this.props,
- _ = i.securityDefinitions(),
- w = o.definitionsToAuthorize(),
- x = u('authorizeBtn');
- return _
- ? Pe.createElement(x, {
- onClick: () => s.showDefinitions(w),
- isAuthorized: !!o.authorized().size,
- showPopup: !!o.shownDefinitions(),
- getComponent: u
- })
- : null;
- }
- }
- class AuthorizeOperationBtn extends Pe.Component {
- onClick = (s) => {
- s.stopPropagation();
- let { onClick: o } = this.props;
- o && o();
- };
- render() {
- let { isAuthorized: s, getComponent: o } = this.props;
- const i = o('LockAuthOperationIcon', !0),
- u = o('UnlockAuthOperationIcon', !0);
- return Pe.createElement(
- 'button',
- {
- className: 'authorization__btn',
- 'aria-label': s ? 'authorization button locked' : 'authorization button unlocked',
- onClick: this.onClick
- },
- s
- ? Pe.createElement(i, { className: 'locked' })
- : Pe.createElement(u, { className: 'unlocked' })
- );
- }
- }
- class Auths extends Pe.Component {
- constructor(s, o) {
- super(s, o), (this.state = {});
- }
- onAuthChange = (s) => {
- let { name: o } = s;
- this.setState({ [o]: s });
- };
- submitAuth = (s) => {
- s.preventDefault();
- let { authActions: o } = this.props;
- o.authorizeWithPersistOption(this.state);
- };
- logoutClick = (s) => {
- s.preventDefault();
- let { authActions: o, definitions: i } = this.props,
- u = i.map((s, o) => o).toArray();
- this.setState(u.reduce((s, o) => ((s[o] = ''), s), {})), o.logoutWithPersistOption(u);
- };
- close = (s) => {
- s.preventDefault();
- let { authActions: o } = this.props;
- o.showDefinitions(!1);
- };
- render() {
- let { definitions: s, getComponent: o, authSelectors: i, errSelectors: u } = this.props;
- const _ = o('AuthItem'),
- w = o('oauth2', !0),
- x = o('Button');
- let C = i.authorized(),
- j = s.filter((s, o) => !!C.get(o)),
- L = s.filter((s) => 'oauth2' !== s.get('type')),
- B = s.filter((s) => 'oauth2' === s.get('type'));
- return Pe.createElement(
- 'div',
- { className: 'auth-container' },
- !!L.size &&
- Pe.createElement(
- 'form',
- { onSubmit: this.submitAuth },
- L.map((s, i) =>
- Pe.createElement(_, {
- key: i,
- schema: s,
- name: i,
- getComponent: o,
- onAuthChange: this.onAuthChange,
- authorized: C,
- errSelectors: u
- })
- ).toArray(),
- Pe.createElement(
- 'div',
- { className: 'auth-btn-wrapper' },
- L.size === j.size
- ? Pe.createElement(
- x,
- {
- className: 'btn modal-btn auth',
- onClick: this.logoutClick,
- 'aria-label': 'Remove authorization'
- },
- 'Logout'
- )
- : Pe.createElement(
- x,
- {
- type: 'submit',
- className: 'btn modal-btn auth authorize',
- 'aria-label': 'Apply credentials'
- },
- 'Authorize'
- ),
- Pe.createElement(
- x,
- { className: 'btn modal-btn auth btn-done', onClick: this.close },
- 'Close'
- )
- )
- ),
- B && B.size
- ? Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'div',
- { className: 'scope-def' },
- Pe.createElement(
- 'p',
- null,
- 'Scopes are used to grant an application different levels of access to data on behalf of the end user. Each API may declare one or more scopes.'
- ),
- Pe.createElement(
- 'p',
- null,
- 'API requires the following scopes. Select which ones you want to grant to Swagger UI.'
- )
- ),
- s
- .filter((s) => 'oauth2' === s.get('type'))
- .map((s, o) =>
- Pe.createElement(
- 'div',
- { key: o },
- Pe.createElement(w, { authorized: C, schema: s, name: o })
- )
- )
- .toArray()
- )
- : null
- );
- }
- }
- class auth_item_Auths extends Pe.Component {
- render() {
- let {
- schema: s,
- name: o,
- getComponent: i,
- onAuthChange: u,
- authorized: _,
- errSelectors: w
- } = this.props;
- const x = i('apiKeyAuth'),
- C = i('basicAuth');
- let j;
- const L = s.get('type');
- switch (L) {
- case 'apiKey':
- j = Pe.createElement(x, {
- key: o,
- schema: s,
- name: o,
- errSelectors: w,
- authorized: _,
- getComponent: i,
- onChange: u
- });
- break;
- case 'basic':
- j = Pe.createElement(C, {
- key: o,
- schema: s,
- name: o,
- errSelectors: w,
- authorized: _,
- getComponent: i,
- onChange: u
- });
- break;
- default:
- j = Pe.createElement('div', { key: o }, 'Unknown security definition type ', L);
- }
- return Pe.createElement('div', { key: `${o}-jump` }, j);
- }
- }
- class AuthError extends Pe.Component {
- render() {
- let { error: s } = this.props,
- o = s.get('level'),
- i = s.get('message'),
- u = s.get('source');
- return Pe.createElement(
- 'div',
- { className: 'errors' },
- Pe.createElement('b', null, u, ' ', o),
- Pe.createElement('span', null, i)
- );
- }
- }
- class ApiKeyAuth extends Pe.Component {
- constructor(s, o) {
- super(s, o);
- let { name: i, schema: u } = this.props,
- _ = this.getValue();
- this.state = { name: i, schema: u, value: _ };
- }
- getValue() {
- let { name: s, authorized: o } = this.props;
- return o && o.getIn([s, 'value']);
- }
- onChange = (s) => {
- let { onChange: o } = this.props,
- i = s.target.value,
- u = Object.assign({}, this.state, { value: i });
- this.setState(u), o(u);
- };
- render() {
- let { schema: s, getComponent: o, errSelectors: i, name: u } = this.props;
- const _ = o('Input'),
- w = o('Row'),
- x = o('Col'),
- C = o('authError'),
- j = o('Markdown', !0),
- L = o('JumpToPath', !0);
- let B = this.getValue(),
- $ = i.allErrors().filter((s) => s.get('authId') === u);
- return Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'h4',
- null,
- Pe.createElement('code', null, u || s.get('name')),
- ' (apiKey)',
- Pe.createElement(L, { path: ['securityDefinitions', u] })
- ),
- B && Pe.createElement('h6', null, 'Authorized'),
- Pe.createElement(w, null, Pe.createElement(j, { source: s.get('description') })),
- Pe.createElement(
- w,
- null,
- Pe.createElement('p', null, 'Name: ', Pe.createElement('code', null, s.get('name')))
- ),
- Pe.createElement(
- w,
- null,
- Pe.createElement('p', null, 'In: ', Pe.createElement('code', null, s.get('in')))
- ),
- Pe.createElement(
- w,
- null,
- Pe.createElement('label', { htmlFor: 'api_key_value' }, 'Value:'),
- B
- ? Pe.createElement('code', null, ' ****** ')
- : Pe.createElement(
- x,
- null,
- Pe.createElement(_, {
- id: 'api_key_value',
- type: 'text',
- onChange: this.onChange,
- autoFocus: !0
- })
- )
- ),
- $.valueSeq().map((s, o) => Pe.createElement(C, { error: s, key: o }))
- );
- }
- }
- class BasicAuth extends Pe.Component {
- constructor(s, o) {
- super(s, o);
- let { schema: i, name: u } = this.props,
- _ = this.getValue().username;
- this.state = { name: u, schema: i, value: _ ? { username: _ } : {} };
- }
- getValue() {
- let { authorized: s, name: o } = this.props;
- return (s && s.getIn([o, 'value'])) || {};
- }
- onChange = (s) => {
- let { onChange: o } = this.props,
- { value: i, name: u } = s.target,
- _ = this.state.value;
- (_[u] = i), this.setState({ value: _ }), o(this.state);
- };
- render() {
- let { schema: s, getComponent: o, name: i, errSelectors: u } = this.props;
- const _ = o('Input'),
- w = o('Row'),
- x = o('Col'),
- C = o('authError'),
- j = o('JumpToPath', !0),
- L = o('Markdown', !0);
- let B = this.getValue().username,
- $ = u.allErrors().filter((s) => s.get('authId') === i);
- return Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'h4',
- null,
- 'Basic authorization',
- Pe.createElement(j, { path: ['securityDefinitions', i] })
- ),
- B && Pe.createElement('h6', null, 'Authorized'),
- Pe.createElement(w, null, Pe.createElement(L, { source: s.get('description') })),
- Pe.createElement(
- w,
- null,
- Pe.createElement('label', { htmlFor: 'auth_username' }, 'Username:'),
- B
- ? Pe.createElement('code', null, ' ', B, ' ')
- : Pe.createElement(
- x,
- null,
- Pe.createElement(_, {
- id: 'auth_username',
- type: 'text',
- required: 'required',
- name: 'username',
- onChange: this.onChange,
- autoFocus: !0
- })
- )
- ),
- Pe.createElement(
- w,
- null,
- Pe.createElement('label', { htmlFor: 'auth_password' }, 'Password:'),
- B
- ? Pe.createElement('code', null, ' ****** ')
- : Pe.createElement(
- x,
- null,
- Pe.createElement(_, {
- id: 'auth_password',
- autoComplete: 'new-password',
- name: 'password',
- type: 'password',
- onChange: this.onChange
- })
- )
- ),
- $.valueSeq().map((s, o) => Pe.createElement(C, { error: s, key: o }))
- );
- }
- }
- function example_Example(s) {
- const { example: o, showValue: i, getComponent: u } = s,
- _ = u('Markdown', !0),
- w = u('HighlightCode', !0);
- return o
- ? Pe.createElement(
- 'div',
- { className: 'example' },
- o.get('description')
- ? Pe.createElement(
- 'section',
- { className: 'example__section' },
- Pe.createElement(
- 'div',
- { className: 'example__section-header' },
- 'Example Description'
- ),
- Pe.createElement(
- 'p',
- null,
- Pe.createElement(_, { source: o.get('description') })
- )
- )
- : null,
- i && o.has('value')
- ? Pe.createElement(
- 'section',
- { className: 'example__section' },
- Pe.createElement(
- 'div',
- { className: 'example__section-header' },
- 'Example Value'
- ),
- Pe.createElement(w, null, stringify(o.get('value')))
- )
- : null
- )
- : null;
- }
- class ExamplesSelect extends Pe.PureComponent {
- static defaultProps = {
- examples: $e().Map({}),
- onSelect: (...s) =>
- console.log('DEBUG: ExamplesSelect was not given an onSelect callback', ...s),
- currentExampleKey: null,
- showLabels: !0
- };
- _onSelect = (s, { isSyntheticChange: o = !1 } = {}) => {
- 'function' == typeof this.props.onSelect &&
- this.props.onSelect(s, { isSyntheticChange: o });
- };
- _onDomSelect = (s) => {
- if ('function' == typeof this.props.onSelect) {
- const o = s.target.selectedOptions[0].getAttribute('value');
- this._onSelect(o, { isSyntheticChange: !1 });
- }
- };
- getCurrentExample = () => {
- const { examples: s, currentExampleKey: o } = this.props,
- i = s.get(o),
- u = s.keySeq().first(),
- _ = s.get(u);
- return i || _ || Map({});
- };
- componentDidMount() {
- const { onSelect: s, examples: o } = this.props;
- if ('function' == typeof s) {
- const s = o.first(),
- i = o.keyOf(s);
- this._onSelect(i, { isSyntheticChange: !0 });
- }
- }
- UNSAFE_componentWillReceiveProps(s) {
- const { currentExampleKey: o, examples: i } = s;
- if (i !== this.props.examples && !i.has(o)) {
- const s = i.first(),
- o = i.keyOf(s);
- this._onSelect(o, { isSyntheticChange: !0 });
- }
- }
- render() {
- const {
- examples: s,
- currentExampleKey: o,
- isValueModified: i,
- isModifiedValueAvailable: u,
- showLabels: _
- } = this.props;
- return Pe.createElement(
- 'div',
- { className: 'examples-select' },
- _
- ? Pe.createElement(
- 'span',
- { className: 'examples-select__section-label' },
- 'Examples: '
- )
- : null,
- Pe.createElement(
- 'select',
- {
- className: 'examples-select-element',
- onChange: this._onDomSelect,
- value: u && i ? '__MODIFIED__VALUE__' : o || ''
- },
- u
- ? Pe.createElement('option', { value: '__MODIFIED__VALUE__' }, '[Modified value]')
- : null,
- s
- .map((s, o) =>
- Pe.createElement('option', { key: o, value: o }, s.get('summary') || o)
- )
- .valueSeq()
- )
- );
- }
- }
- const stringifyUnlessList = (s) => (qe.List.isList(s) ? s : stringify(s));
- class ExamplesSelectValueRetainer extends Pe.PureComponent {
- static defaultProps = {
- userHasEditedBody: !1,
- examples: (0, qe.Map)({}),
- currentNamespace: '__DEFAULT__NAMESPACE__',
- setRetainRequestBodyValueFlag: () => {},
- onSelect: (...s) =>
- console.log('ExamplesSelectValueRetainer: no `onSelect` function was provided', ...s),
- updateValue: (...s) =>
- console.log(
- 'ExamplesSelectValueRetainer: no `updateValue` function was provided',
- ...s
- )
- };
- constructor(s) {
- super(s);
- const o = this._getCurrentExampleValue();
- this.state = {
- [s.currentNamespace]: (0, qe.Map)({
- lastUserEditedValue: this.props.currentUserInputValue,
- lastDownstreamValue: o,
- isModifiedValueSelected:
- this.props.userHasEditedBody || this.props.currentUserInputValue !== o
- })
- };
- }
- componentWillUnmount() {
- this.props.setRetainRequestBodyValueFlag(!1);
- }
- _getStateForCurrentNamespace = () => {
- const { currentNamespace: s } = this.props;
- return (this.state[s] || (0, qe.Map)()).toObject();
- };
- _setStateForCurrentNamespace = (s) => {
- const { currentNamespace: o } = this.props;
- return this._setStateForNamespace(o, s);
- };
- _setStateForNamespace = (s, o) => {
- const i = (this.state[s] || (0, qe.Map)()).mergeDeep(o);
- return this.setState({ [s]: i });
- };
- _isCurrentUserInputSameAsExampleValue = () => {
- const { currentUserInputValue: s } = this.props;
- return this._getCurrentExampleValue() === s;
- };
- _getValueForExample = (s, o) => {
- const { examples: i } = o || this.props;
- return stringifyUnlessList((i || (0, qe.Map)({})).getIn([s, 'value']));
- };
- _getCurrentExampleValue = (s) => {
- const { currentKey: o } = s || this.props;
- return this._getValueForExample(o, s || this.props);
- };
- _onExamplesSelect = (s, { isSyntheticChange: o } = {}, ...i) => {
- const {
- onSelect: u,
- updateValue: _,
- currentUserInputValue: w,
- userHasEditedBody: x
- } = this.props,
- { lastUserEditedValue: C } = this._getStateForCurrentNamespace(),
- j = this._getValueForExample(s);
- if ('__MODIFIED__VALUE__' === s)
- return (
- _(stringifyUnlessList(C)),
- this._setStateForCurrentNamespace({ isModifiedValueSelected: !0 })
- );
- 'function' == typeof u && u(s, { isSyntheticChange: o }, ...i),
- this._setStateForCurrentNamespace({
- lastDownstreamValue: j,
- isModifiedValueSelected: (o && x) || (!!w && w !== j)
- }),
- o || ('function' == typeof _ && _(stringifyUnlessList(j)));
- };
- UNSAFE_componentWillReceiveProps(s) {
- const { currentUserInputValue: o, examples: i, onSelect: u, userHasEditedBody: _ } = s,
- { lastUserEditedValue: w, lastDownstreamValue: x } =
- this._getStateForCurrentNamespace(),
- C = this._getValueForExample(s.currentKey, s),
- j = i.filter((s) => s.get('value') === o || stringify(s.get('value')) === o);
- if (j.size) {
- let o;
- (o = j.has(s.currentKey) ? s.currentKey : j.keySeq().first()),
- u(o, { isSyntheticChange: !0 });
- } else
- o !== this.props.currentUserInputValue &&
- o !== w &&
- o !== x &&
- (this.props.setRetainRequestBodyValueFlag(!0),
- this._setStateForNamespace(s.currentNamespace, {
- lastUserEditedValue: s.currentUserInputValue,
- isModifiedValueSelected: _ || o !== C
- }));
- }
- render() {
- const {
- currentUserInputValue: s,
- examples: o,
- currentKey: i,
- getComponent: u,
- userHasEditedBody: _
- } = this.props,
- {
- lastDownstreamValue: w,
- lastUserEditedValue: x,
- isModifiedValueSelected: C
- } = this._getStateForCurrentNamespace(),
- j = u('ExamplesSelect');
- return Pe.createElement(j, {
- examples: o,
- currentExampleKey: i,
- onSelect: this._onExamplesSelect,
- isModifiedValueAvailable: !!x && x !== w,
- isValueModified: (void 0 !== s && C && s !== this._getCurrentExampleValue()) || _
- });
- }
- }
- function oauth2_authorize_authorize({
- auth: s,
- authActions: o,
- errActions: i,
- configs: u,
- authConfigs: _ = {},
- currentServer: w
- }) {
- let { schema: x, scopes: C, name: j, clientId: L } = s,
- B = x.get('flow'),
- $ = [];
- switch (B) {
- case 'password':
- return void o.authorizePassword(s);
- case 'application':
- case 'clientCredentials':
- case 'client_credentials':
- return void o.authorizeApplication(s);
- case 'accessCode':
- case 'authorizationCode':
- case 'authorization_code':
- $.push('response_type=code');
- break;
- case 'implicit':
- $.push('response_type=token');
- }
- 'string' == typeof L && $.push('client_id=' + encodeURIComponent(L));
- let V = u.oauth2RedirectUrl;
- if (void 0 === V)
- return void i.newAuthErr({
- authId: j,
- source: 'validation',
- level: 'error',
- message:
- 'oauth2RedirectUrl configuration is not passed. Oauth2 authorization cannot be performed.'
- });
- $.push('redirect_uri=' + encodeURIComponent(V));
- let U = [];
- if (
- (Array.isArray(C) ? (U = C) : $e().List.isList(C) && (U = C.toArray()), U.length > 0)
- ) {
- let s = _.scopeSeparator || ' ';
- $.push('scope=' + encodeURIComponent(U.join(s)));
- }
- let z = utils_btoa(new Date());
- if (
- ($.push('state=' + encodeURIComponent(z)),
- void 0 !== _.realm && $.push('realm=' + encodeURIComponent(_.realm)),
- ('authorizationCode' === B || 'authorization_code' === B || 'accessCode' === B) &&
- _.usePkceWithAuthorizationCodeGrant)
- ) {
- const o = (function generateCodeVerifier() {
- return b64toB64UrlEncoded(St()(32).toString('base64'));
- })(),
- i = (function createCodeChallenge(s) {
- return b64toB64UrlEncoded(kt()('sha256').update(s).digest('base64'));
- })(o);
- $.push('code_challenge=' + i),
- $.push('code_challenge_method=S256'),
- (s.codeVerifier = o);
- }
- let { additionalQueryStringParams: Y } = _;
- for (let s in Y) void 0 !== Y[s] && $.push([s, Y[s]].map(encodeURIComponent).join('='));
- const Z = x.get('authorizationUrl');
- let ee;
- ee = w ? Mt()(sanitizeUrl(Z), w, !0).toString() : sanitizeUrl(Z);
- let ie,
- ae = [ee, $.join('&')].join(-1 === Z.indexOf('?') ? '?' : '&');
- (ie =
- 'implicit' === B
- ? o.preAuthorizeImplicit
- : _.useBasicAuthenticationWithAccessCodeGrant
- ? o.authorizeAccessCodeWithBasicAuthentication
- : o.authorizeAccessCodeWithFormParams),
- o.authPopup(ae, {
- auth: s,
- state: z,
- redirectUrl: V,
- callback: ie,
- errCb: i.newAuthErr
- });
- }
- class Oauth2 extends Pe.Component {
- constructor(s, o) {
- super(s, o);
- let { name: i, schema: u, authorized: _, authSelectors: w } = this.props,
- x = _ && _.get(i),
- C = w.getConfigs() || {},
- j = (x && x.get('username')) || '',
- L = (x && x.get('clientId')) || C.clientId || '',
- B = (x && x.get('clientSecret')) || C.clientSecret || '',
- $ = (x && x.get('passwordType')) || 'basic',
- V = (x && x.get('scopes')) || C.scopes || [];
- 'string' == typeof V && (V = V.split(C.scopeSeparator || ' ')),
- (this.state = {
- appName: C.appName,
- name: i,
- schema: u,
- scopes: V,
- clientId: L,
- clientSecret: B,
- username: j,
- password: '',
- passwordType: $
- });
- }
- close = (s) => {
- s.preventDefault();
- let { authActions: o } = this.props;
- o.showDefinitions(!1);
- };
- authorize = () => {
- let {
- authActions: s,
- errActions: o,
- getConfigs: i,
- authSelectors: u,
- oas3Selectors: _
- } = this.props,
- w = i(),
- x = u.getConfigs();
- o.clear({ authId: name, type: 'auth', source: 'auth' }),
- oauth2_authorize_authorize({
- auth: this.state,
- currentServer: _.serverEffectiveValue(_.selectedServer()),
- authActions: s,
- errActions: o,
- configs: w,
- authConfigs: x
- });
- };
- onScopeChange = (s) => {
- let { target: o } = s,
- { checked: i } = o,
- u = o.dataset.value;
- if (i && -1 === this.state.scopes.indexOf(u)) {
- let s = this.state.scopes.concat([u]);
- this.setState({ scopes: s });
- } else
- !i &&
- this.state.scopes.indexOf(u) > -1 &&
- this.setState({ scopes: this.state.scopes.filter((s) => s !== u) });
- };
- onInputChange = (s) => {
- let {
- target: {
- dataset: { name: o },
- value: i
- }
- } = s,
- u = { [o]: i };
- this.setState(u);
- };
- selectScopes = (s) => {
- s.target.dataset.all
- ? this.setState({
- scopes: Array.from(
- (
- this.props.schema.get('allowedScopes') || this.props.schema.get('scopes')
- ).keys()
- )
- })
- : this.setState({ scopes: [] });
- };
- logout = (s) => {
- s.preventDefault();
- let { authActions: o, errActions: i, name: u } = this.props;
- i.clear({ authId: u, type: 'auth', source: 'auth' }), o.logoutWithPersistOption([u]);
- };
- render() {
- let {
- schema: s,
- getComponent: o,
- authSelectors: i,
- errSelectors: u,
- name: _,
- specSelectors: w
- } = this.props;
- const x = o('Input'),
- C = o('Row'),
- j = o('Col'),
- L = o('Button'),
- B = o('authError'),
- $ = o('JumpToPath', !0),
- V = o('Markdown', !0),
- U = o('InitializedInput'),
- { isOAS3: z } = w;
- let Y = z() ? s.get('openIdConnectUrl') : null;
- const Z = 'implicit',
- ee = 'password',
- ie = z() ? (Y ? 'authorization_code' : 'authorizationCode') : 'accessCode',
- ae = z() ? (Y ? 'client_credentials' : 'clientCredentials') : 'application';
- let le = !!(i.getConfigs() || {}).usePkceWithAuthorizationCodeGrant,
- ce = s.get('flow'),
- pe = ce === ie && le ? ce + ' with PKCE' : ce,
- de = s.get('allowedScopes') || s.get('scopes'),
- fe = !!i.authorized().get(_),
- ye = u.allErrors().filter((s) => s.get('authId') === _),
- be = !ye.filter((s) => 'validation' === s.get('source')).size,
- _e = s.get('description');
- return Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'h4',
- null,
- _,
- ' (OAuth2, ',
- pe,
- ') ',
- Pe.createElement($, { path: ['securityDefinitions', _] })
- ),
- this.state.appName
- ? Pe.createElement('h5', null, 'Application: ', this.state.appName, ' ')
- : null,
- _e && Pe.createElement(V, { source: s.get('description') }),
- fe && Pe.createElement('h6', null, 'Authorized'),
- Y &&
- Pe.createElement(
- 'p',
- null,
- 'OpenID Connect URL: ',
- Pe.createElement('code', null, Y)
- ),
- (ce === Z || ce === ie) &&
- Pe.createElement(
- 'p',
- null,
- 'Authorization URL: ',
- Pe.createElement('code', null, s.get('authorizationUrl'))
- ),
- (ce === ee || ce === ie || ce === ae) &&
- Pe.createElement(
- 'p',
- null,
- 'Token URL:',
- Pe.createElement('code', null, ' ', s.get('tokenUrl'))
- ),
- Pe.createElement(
- 'p',
- { className: 'flow' },
- 'Flow: ',
- Pe.createElement('code', null, pe)
- ),
- ce !== ee
- ? null
- : Pe.createElement(
- C,
- null,
- Pe.createElement(
- C,
- null,
- Pe.createElement('label', { htmlFor: 'oauth_username' }, 'username:'),
- fe
- ? Pe.createElement('code', null, ' ', this.state.username, ' ')
- : Pe.createElement(
- j,
- { tablet: 10, desktop: 10 },
- Pe.createElement('input', {
- id: 'oauth_username',
- type: 'text',
- 'data-name': 'username',
- onChange: this.onInputChange,
- autoFocus: !0
- })
- )
- ),
- Pe.createElement(
- C,
- null,
- Pe.createElement('label', { htmlFor: 'oauth_password' }, 'password:'),
- fe
- ? Pe.createElement('code', null, ' ****** ')
- : Pe.createElement(
- j,
- { tablet: 10, desktop: 10 },
- Pe.createElement('input', {
- id: 'oauth_password',
- type: 'password',
- 'data-name': 'password',
- onChange: this.onInputChange
- })
- )
- ),
- Pe.createElement(
- C,
- null,
- Pe.createElement(
- 'label',
- { htmlFor: 'password_type' },
- 'Client credentials location:'
- ),
- fe
- ? Pe.createElement('code', null, ' ', this.state.passwordType, ' ')
- : Pe.createElement(
- j,
- { tablet: 10, desktop: 10 },
- Pe.createElement(
- 'select',
- {
- id: 'password_type',
- 'data-name': 'passwordType',
- onChange: this.onInputChange
- },
- Pe.createElement(
- 'option',
- { value: 'basic' },
- 'Authorization header'
- ),
- Pe.createElement('option', { value: 'request-body' }, 'Request body')
- )
- )
- )
- ),
- (ce === ae || ce === Z || ce === ie || ce === ee) &&
- (!fe || (fe && this.state.clientId)) &&
- Pe.createElement(
- C,
- null,
- Pe.createElement('label', { htmlFor: `client_id_${ce}` }, 'client_id:'),
- fe
- ? Pe.createElement('code', null, ' ****** ')
- : Pe.createElement(
- j,
- { tablet: 10, desktop: 10 },
- Pe.createElement(U, {
- id: `client_id_${ce}`,
- type: 'text',
- required: ce === ee,
- initialValue: this.state.clientId,
- 'data-name': 'clientId',
- onChange: this.onInputChange
- })
- )
- ),
- (ce === ae || ce === ie || ce === ee) &&
- Pe.createElement(
- C,
- null,
- Pe.createElement('label', { htmlFor: `client_secret_${ce}` }, 'client_secret:'),
- fe
- ? Pe.createElement('code', null, ' ****** ')
- : Pe.createElement(
- j,
- { tablet: 10, desktop: 10 },
- Pe.createElement(U, {
- id: `client_secret_${ce}`,
- initialValue: this.state.clientSecret,
- type: 'password',
- 'data-name': 'clientSecret',
- onChange: this.onInputChange
- })
- )
- ),
- !fe && de && de.size
- ? Pe.createElement(
- 'div',
- { className: 'scopes' },
- Pe.createElement(
- 'h2',
- null,
- 'Scopes:',
- Pe.createElement(
- 'a',
- { onClick: this.selectScopes, 'data-all': !0 },
- 'select all'
- ),
- Pe.createElement('a', { onClick: this.selectScopes }, 'select none')
- ),
- de
- .map((s, o) =>
- Pe.createElement(
- C,
- { key: o },
- Pe.createElement(
- 'div',
- { className: 'checkbox' },
- Pe.createElement(x, {
- 'data-value': o,
- id: `${o}-${ce}-checkbox-${this.state.name}`,
- disabled: fe,
- checked: this.state.scopes.includes(o),
- type: 'checkbox',
- onChange: this.onScopeChange
- }),
- Pe.createElement(
- 'label',
- { htmlFor: `${o}-${ce}-checkbox-${this.state.name}` },
- Pe.createElement('span', { className: 'item' }),
- Pe.createElement(
- 'div',
- { className: 'text' },
- Pe.createElement('p', { className: 'name' }, o),
- Pe.createElement('p', { className: 'description' }, s)
- )
- )
- )
- )
- )
- .toArray()
- )
- : null,
- ye.valueSeq().map((s, o) => Pe.createElement(B, { error: s, key: o })),
- Pe.createElement(
- 'div',
- { className: 'auth-btn-wrapper' },
- be &&
- (fe
- ? Pe.createElement(
- L,
- {
- className: 'btn modal-btn auth authorize',
- onClick: this.logout,
- 'aria-label': 'Remove authorization'
- },
- 'Logout'
- )
- : Pe.createElement(
- L,
- {
- className: 'btn modal-btn auth authorize',
- onClick: this.authorize,
- 'aria-label': 'Apply given OAuth2 credentials'
- },
- 'Authorize'
- )),
- Pe.createElement(
- L,
- { className: 'btn modal-btn auth btn-done', onClick: this.close },
- 'Close'
- )
- )
- );
- }
- }
- class Clear extends Pe.Component {
- onClick = () => {
- let { specActions: s, path: o, method: i } = this.props;
- s.clearResponse(o, i), s.clearRequest(o, i);
- };
- render() {
- return Pe.createElement(
- 'button',
- { className: 'btn btn-clear opblock-control__btn', onClick: this.onClick },
- 'Clear'
- );
- }
- }
- const live_response_Headers = ({ headers: s }) =>
- Pe.createElement(
- 'div',
- null,
- Pe.createElement('h5', null, 'Response headers'),
- Pe.createElement('pre', { className: 'microlight' }, s)
- ),
- Duration = ({ duration: s }) =>
- Pe.createElement(
- 'div',
- null,
- Pe.createElement('h5', null, 'Request duration'),
- Pe.createElement('pre', { className: 'microlight' }, s, ' ms')
- );
- class LiveResponse extends Pe.Component {
- shouldComponentUpdate(s) {
- return (
- this.props.response !== s.response ||
- this.props.path !== s.path ||
- this.props.method !== s.method ||
- this.props.displayRequestDuration !== s.displayRequestDuration
- );
- }
- render() {
- const {
- response: s,
- getComponent: o,
- getConfigs: i,
- displayRequestDuration: u,
- specSelectors: _,
- path: w,
- method: x
- } = this.props,
- { showMutatedRequest: C, requestSnippetsEnabled: j } = i(),
- L = C ? _.mutatedRequestFor(w, x) : _.requestFor(w, x),
- B = s.get('status'),
- $ = L.get('url'),
- V = s.get('headers').toJS(),
- U = s.get('notDocumented'),
- z = s.get('error'),
- Y = s.get('text'),
- Z = s.get('duration'),
- ee = Object.keys(V),
- ie = V['content-type'] || V['Content-Type'],
- ae = o('responseBody'),
- le = ee.map((s) => {
- var o = Array.isArray(V[s]) ? V[s].join() : V[s];
- return Pe.createElement(
- 'span',
- { className: 'headerline', key: s },
- ' ',
- s,
- ': ',
- o,
- ' '
- );
- }),
- ce = 0 !== le.length,
- pe = o('Markdown', !0),
- de = o('RequestSnippets', !0),
- fe = o('curl', !0);
- return Pe.createElement(
- 'div',
- null,
- L && j ? Pe.createElement(de, { request: L }) : Pe.createElement(fe, { request: L }),
- $ &&
- Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'div',
- { className: 'request-url' },
- Pe.createElement('h4', null, 'Request URL'),
- Pe.createElement('pre', { className: 'microlight' }, $)
- )
- ),
- Pe.createElement('h4', null, 'Server response'),
- Pe.createElement(
- 'table',
- { className: 'responses-table live-responses-table' },
- Pe.createElement(
- 'thead',
- null,
- Pe.createElement(
- 'tr',
- { className: 'responses-header' },
- Pe.createElement('td', { className: 'col_header response-col_status' }, 'Code'),
- Pe.createElement(
- 'td',
- { className: 'col_header response-col_description' },
- 'Details'
- )
- )
- ),
- Pe.createElement(
- 'tbody',
- null,
- Pe.createElement(
- 'tr',
- { className: 'response' },
- Pe.createElement(
- 'td',
- { className: 'response-col_status' },
- B,
- U
- ? Pe.createElement(
- 'div',
- { className: 'response-undocumented' },
- Pe.createElement('i', null, ' Undocumented ')
- )
- : null
- ),
- Pe.createElement(
- 'td',
- { className: 'response-col_description' },
- z
- ? Pe.createElement(pe, {
- source: `${'' !== s.get('name') ? `${s.get('name')}: ` : ''}${s.get('message')}`
- })
- : null,
- Y
- ? Pe.createElement(ae, {
- content: Y,
- contentType: ie,
- url: $,
- headers: V,
- getConfigs: i,
- getComponent: o
- })
- : null,
- ce ? Pe.createElement(live_response_Headers, { headers: le }) : null,
- u && Z ? Pe.createElement(Duration, { duration: Z }) : null
- )
- )
- )
- )
- );
- }
- }
- class OnlineValidatorBadge extends Pe.Component {
- constructor(s, o) {
- super(s, o);
- let { getConfigs: i } = s,
- { validatorUrl: u } = i();
- this.state = {
- url: this.getDefinitionUrl(),
- validatorUrl: void 0 === u ? 'https://validator.swagger.io/validator' : u
- };
- }
- getDefinitionUrl = () => {
- let { specSelectors: s } = this.props;
- return new (Mt())(s.url(), at.location).toString();
- };
- UNSAFE_componentWillReceiveProps(s) {
- let { getConfigs: o } = s,
- { validatorUrl: i } = o();
- this.setState({
- url: this.getDefinitionUrl(),
- validatorUrl: void 0 === i ? 'https://validator.swagger.io/validator' : i
- });
- }
- render() {
- let { getConfigs: s } = this.props,
- { spec: o } = s(),
- i = sanitizeUrl(this.state.validatorUrl);
- return 'object' == typeof o && Object.keys(o).length
- ? null
- : this.state.url &&
- requiresValidationURL(this.state.validatorUrl) &&
- requiresValidationURL(this.state.url)
- ? Pe.createElement(
- 'span',
- { className: 'float-right' },
- Pe.createElement(
- 'a',
- {
- target: '_blank',
- rel: 'noopener noreferrer',
- href: `${i}/debug?url=${encodeURIComponent(this.state.url)}`
- },
- Pe.createElement(ValidatorImage, {
- src: `${i}?url=${encodeURIComponent(this.state.url)}`,
- alt: 'Online validator badge'
- })
- )
- )
- : null;
- }
- }
- class ValidatorImage extends Pe.Component {
- constructor(s) {
- super(s), (this.state = { loaded: !1, error: !1 });
- }
- componentDidMount() {
- const s = new Image();
- (s.onload = () => {
- this.setState({ loaded: !0 });
- }),
- (s.onerror = () => {
- this.setState({ error: !0 });
- }),
- (s.src = this.props.src);
- }
- UNSAFE_componentWillReceiveProps(s) {
- if (s.src !== this.props.src) {
- const o = new Image();
- (o.onload = () => {
- this.setState({ loaded: !0 });
- }),
- (o.onerror = () => {
- this.setState({ error: !0 });
- }),
- (o.src = s.src);
- }
- }
- render() {
- return this.state.error
- ? Pe.createElement('img', { alt: 'Error' })
- : this.state.loaded
- ? Pe.createElement('img', { src: this.props.src, alt: this.props.alt })
- : null;
- }
- }
- class Operations extends Pe.Component {
- render() {
- let { specSelectors: s } = this.props;
- const o = s.taggedOperations();
- return 0 === o.size
- ? Pe.createElement('h3', null, ' No operations defined in spec!')
- : Pe.createElement(
- 'div',
- null,
- o.map(this.renderOperationTag).toArray(),
- o.size < 1
- ? Pe.createElement('h3', null, ' No operations defined in spec! ')
- : null
- );
- }
- renderOperationTag = (s, o) => {
- const {
- specSelectors: i,
- getComponent: u,
- oas3Selectors: _,
- layoutSelectors: w,
- layoutActions: x,
- getConfigs: C
- } = this.props,
- j = i.validOperationMethods(),
- L = u('OperationContainer', !0),
- B = u('OperationTag'),
- $ = s.get('operations');
- return Pe.createElement(
- B,
- {
- key: 'operation-' + o,
- tagObj: s,
- tag: o,
- oas3Selectors: _,
- layoutSelectors: w,
- layoutActions: x,
- getConfigs: C,
- getComponent: u,
- specUrl: i.url()
- },
- Pe.createElement(
- 'div',
- { className: 'operation-tag-content' },
- $.map((s) => {
- const i = s.get('path'),
- u = s.get('method'),
- _ = $e().List(['paths', i, u]);
- return -1 === j.indexOf(u)
- ? null
- : Pe.createElement(L, {
- key: `${i}-${u}`,
- specPath: _,
- op: s,
- path: i,
- method: u,
- tag: o
- });
- }).toArray()
- )
- );
- };
- }
- function isAbsoluteUrl(s) {
- return s.match(/^(?:[a-z]+:)?\/\//i);
- }
- function buildBaseUrl(s, o) {
- return s
- ? isAbsoluteUrl(s)
- ? (function addProtocol(s) {
- return s.match(/^\/\//i) ? `${window.location.protocol}${s}` : s;
- })(s)
- : new URL(s, o).href
- : o;
- }
- function safeBuildUrl(s, o, { selectedServer: i = '' } = {}) {
- try {
- return (function buildUrl(s, o, { selectedServer: i = '' } = {}) {
- if (!s) return;
- if (isAbsoluteUrl(s)) return s;
- const u = buildBaseUrl(i, o);
- return isAbsoluteUrl(u) ? new URL(s, u).href : new URL(s, window.location.href).href;
- })(s, o, { selectedServer: i });
- } catch {
- return;
- }
- }
- class OperationTag extends Pe.Component {
- static defaultProps = { tagObj: $e().fromJS({}), tag: '' };
- render() {
- const {
- tagObj: s,
- tag: o,
- children: i,
- oas3Selectors: u,
- layoutSelectors: _,
- layoutActions: w,
- getConfigs: x,
- getComponent: C,
- specUrl: j
- } = this.props;
- let { docExpansion: L, deepLinking: B } = x();
- const $ = C('Collapse'),
- V = C('Markdown', !0),
- U = C('DeepLink'),
- z = C('Link'),
- Y = C('ArrowUpIcon'),
- Z = C('ArrowDownIcon');
- let ee,
- ie = s.getIn(['tagDetails', 'description'], null),
- ae = s.getIn(['tagDetails', 'externalDocs', 'description']),
- le = s.getIn(['tagDetails', 'externalDocs', 'url']);
- ee =
- isFunc(u) && isFunc(u.selectedServer)
- ? safeBuildUrl(le, j, { selectedServer: u.selectedServer() })
- : le;
- let ce = ['operations-tag', o],
- pe = _.isShown(ce, 'full' === L || 'list' === L);
- return Pe.createElement(
- 'div',
- { className: pe ? 'opblock-tag-section is-open' : 'opblock-tag-section' },
- Pe.createElement(
- 'h3',
- {
- onClick: () => w.show(ce, !pe),
- className: ie ? 'opblock-tag' : 'opblock-tag no-desc',
- id: ce.map((s) => escapeDeepLinkPath(s)).join('-'),
- 'data-tag': o,
- 'data-is-open': pe
- },
- Pe.createElement(U, {
- enabled: B,
- isShown: pe,
- path: createDeepLinkPath(o),
- text: o
- }),
- ie
- ? Pe.createElement('small', null, Pe.createElement(V, { source: ie }))
- : Pe.createElement('small', null),
- ee
- ? Pe.createElement(
- 'div',
- { className: 'info__externaldocs' },
- Pe.createElement(
- 'small',
- null,
- Pe.createElement(
- z,
- {
- href: sanitizeUrl(ee),
- onClick: (s) => s.stopPropagation(),
- target: '_blank'
- },
- ae || ee
- )
- )
- )
- : null,
- Pe.createElement(
- 'button',
- {
- 'aria-expanded': pe,
- className: 'expand-operation',
- title: pe ? 'Collapse operation' : 'Expand operation',
- onClick: () => w.show(ce, !pe)
- },
- pe
- ? Pe.createElement(Y, { className: 'arrow' })
- : Pe.createElement(Z, { className: 'arrow' })
- )
- ),
- Pe.createElement($, { isOpened: pe }, i)
- );
- }
- }
- class operation_Operation extends Pe.PureComponent {
- static defaultProps = {
- operation: null,
- response: null,
- request: null,
- specPath: (0, qe.List)(),
- summary: ''
- };
- render() {
- let {
- specPath: s,
- response: o,
- request: i,
- toggleShown: u,
- onTryoutClick: _,
- onResetClick: w,
- onCancelClick: x,
- onExecute: C,
- fn: j,
- getComponent: L,
- getConfigs: B,
- specActions: $,
- specSelectors: V,
- authActions: U,
- authSelectors: z,
- oas3Actions: Y,
- oas3Selectors: Z
- } = this.props,
- ee = this.props.operation,
- {
- deprecated: ie,
- isShown: ae,
- path: le,
- method: ce,
- op: pe,
- tag: de,
- operationId: fe,
- allowTryItOut: ye,
- displayRequestDuration: be,
- tryItOutEnabled: _e,
- executeInProgress: we
- } = ee.toJS(),
- { description: Se, externalDocs: xe, schemes: Te } = pe;
- const Re = xe
- ? safeBuildUrl(xe.url, V.url(), { selectedServer: Z.selectedServer() })
- : '';
- let qe = ee.getIn(['op']),
- ze = qe.get('responses'),
- We = (function getList(s, o) {
- if (!$e().Iterable.isIterable(s)) return $e().List();
- let i = s.getIn(Array.isArray(o) ? o : [o]);
- return $e().List.isList(i) ? i : $e().List();
- })(qe, ['parameters']),
- He = V.operationScheme(le, ce),
- Ye = ['operations', de, fe],
- Xe = getExtensions(qe);
- const Qe = L('responses'),
- et = L('parameters'),
- tt = L('execute'),
- rt = L('clear'),
- nt = L('Collapse'),
- st = L('Markdown', !0),
- ot = L('schemes'),
- it = L('OperationServers'),
- at = L('OperationExt'),
- lt = L('OperationSummary'),
- ct = L('Link'),
- { showExtensions: ut } = B();
- if (ze && o && o.size > 0) {
- let s = !ze.get(String(o.get('status'))) && !ze.get('default');
- o = o.set('notDocumented', s);
- }
- let pt = [le, ce];
- const ht = V.validationErrors([le, ce]);
- return Pe.createElement(
- 'div',
- {
- className: ie
- ? 'opblock opblock-deprecated'
- : ae
- ? `opblock opblock-${ce} is-open`
- : `opblock opblock-${ce}`,
- id: escapeDeepLinkPath(Ye.join('-'))
- },
- Pe.createElement(lt, {
- operationProps: ee,
- isShown: ae,
- toggleShown: u,
- getComponent: L,
- authActions: U,
- authSelectors: z,
- specPath: s
- }),
- Pe.createElement(
- nt,
- { isOpened: ae },
- Pe.createElement(
- 'div',
- { className: 'opblock-body' },
- (qe && qe.size) || null === qe
- ? null
- : Pe.createElement(rolling_load, {
- height: '32px',
- width: '32px',
- className: 'opblock-loading-animation'
- }),
- ie &&
- Pe.createElement(
- 'h4',
- { className: 'opblock-title_normal' },
- ' Warning: Deprecated'
- ),
- Se &&
- Pe.createElement(
- 'div',
- { className: 'opblock-description-wrapper' },
- Pe.createElement(
- 'div',
- { className: 'opblock-description' },
- Pe.createElement(st, { source: Se })
- )
- ),
- Re
- ? Pe.createElement(
- 'div',
- { className: 'opblock-external-docs-wrapper' },
- Pe.createElement(
- 'h4',
- { className: 'opblock-title_normal' },
- 'Find more details'
- ),
- Pe.createElement(
- 'div',
- { className: 'opblock-external-docs' },
- xe.description &&
- Pe.createElement(
- 'span',
- { className: 'opblock-external-docs__description' },
- Pe.createElement(st, { source: xe.description })
- ),
- Pe.createElement(
- ct,
- {
- target: '_blank',
- className: 'opblock-external-docs__link',
- href: sanitizeUrl(Re)
- },
- Re
- )
- )
- )
- : null,
- qe && qe.size
- ? Pe.createElement(et, {
- parameters: We,
- specPath: s.push('parameters'),
- operation: qe,
- onChangeKey: pt,
- onTryoutClick: _,
- onResetClick: w,
- onCancelClick: x,
- tryItOutEnabled: _e,
- allowTryItOut: ye,
- fn: j,
- getComponent: L,
- specActions: $,
- specSelectors: V,
- pathMethod: [le, ce],
- getConfigs: B,
- oas3Actions: Y,
- oas3Selectors: Z
- })
- : null,
- _e
- ? Pe.createElement(it, {
- getComponent: L,
- path: le,
- method: ce,
- operationServers: qe.get('servers'),
- pathServers: V.paths().getIn([le, 'servers']),
- getSelectedServer: Z.selectedServer,
- setSelectedServer: Y.setSelectedServer,
- setServerVariableValue: Y.setServerVariableValue,
- getServerVariable: Z.serverVariableValue,
- getEffectiveServerValue: Z.serverEffectiveValue
- })
- : null,
- _e && ye && Te && Te.size
- ? Pe.createElement(
- 'div',
- { className: 'opblock-schemes' },
- Pe.createElement(ot, {
- schemes: Te,
- path: le,
- method: ce,
- specActions: $,
- currentScheme: He
- })
- )
- : null,
- !_e || !ye || ht.length <= 0
- ? null
- : Pe.createElement(
- 'div',
- { className: 'validation-errors errors-wrapper' },
- 'Please correct the following validation errors and try again.',
- Pe.createElement(
- 'ul',
- null,
- ht.map((s, o) => Pe.createElement('li', { key: o }, ' ', s, ' '))
- )
- ),
- Pe.createElement(
- 'div',
- { className: _e && o && ye ? 'btn-group' : 'execute-wrapper' },
- _e && ye
- ? Pe.createElement(tt, {
- operation: qe,
- specActions: $,
- specSelectors: V,
- oas3Selectors: Z,
- oas3Actions: Y,
- path: le,
- method: ce,
- onExecute: C,
- disabled: we
- })
- : null,
- _e && o && ye
- ? Pe.createElement(rt, { specActions: $, path: le, method: ce })
- : null
- ),
- we
- ? Pe.createElement(
- 'div',
- { className: 'loading-container' },
- Pe.createElement('div', { className: 'loading' })
- )
- : null,
- ze
- ? Pe.createElement(Qe, {
- responses: ze,
- request: i,
- tryItOutResponse: o,
- getComponent: L,
- getConfigs: B,
- specSelectors: V,
- oas3Actions: Y,
- oas3Selectors: Z,
- specActions: $,
- produces: V.producesOptionsFor([le, ce]),
- producesValue: V.currentProducesFor([le, ce]),
- specPath: s.push('responses'),
- path: le,
- method: ce,
- displayRequestDuration: be,
- fn: j
- })
- : null,
- ut && Xe.size ? Pe.createElement(at, { extensions: Xe, getComponent: L }) : null
- )
- )
- );
- }
- }
- class OperationContainer extends Pe.PureComponent {
- constructor(s, o) {
- super(s, o);
- const { tryItOutEnabled: i } = s.getConfigs();
- this.state = { tryItOutEnabled: i, executeInProgress: !1 };
- }
- static defaultProps = {
- showSummary: !0,
- response: null,
- allowTryItOut: !0,
- displayOperationId: !1,
- displayRequestDuration: !1
- };
- mapStateToProps(s, o) {
- const { op: i, layoutSelectors: u, getConfigs: _ } = o,
- {
- docExpansion: w,
- deepLinking: x,
- displayOperationId: C,
- displayRequestDuration: j,
- supportedSubmitMethods: L
- } = _(),
- B = u.showSummary(),
- $ =
- i.getIn(['operation', '__originalOperationId']) ||
- i.getIn(['operation', 'operationId']) ||
- opId(i.get('operation'), o.path, o.method) ||
- i.get('id'),
- V = ['operations', o.tag, $],
- U =
- L.indexOf(o.method) >= 0 &&
- (void 0 === o.allowTryItOut
- ? o.specSelectors.allowTryItOutFor(o.path, o.method)
- : o.allowTryItOut),
- z = i.getIn(['operation', 'security']) || o.specSelectors.security();
- return {
- operationId: $,
- isDeepLinkingEnabled: x,
- showSummary: B,
- displayOperationId: C,
- displayRequestDuration: j,
- allowTryItOut: U,
- security: z,
- isAuthorized: o.authSelectors.isAuthorized(z),
- isShown: u.isShown(V, 'full' === w),
- jumpToKey: `paths.${o.path}.${o.method}`,
- response: o.specSelectors.responseFor(o.path, o.method),
- request: o.specSelectors.requestFor(o.path, o.method)
- };
- }
- componentDidMount() {
- const { isShown: s } = this.props,
- o = this.getResolvedSubtree();
- s && void 0 === o && this.requestResolvedSubtree();
- }
- UNSAFE_componentWillReceiveProps(s) {
- const { response: o, isShown: i } = s,
- u = this.getResolvedSubtree();
- o !== this.props.response && this.setState({ executeInProgress: !1 }),
- i && void 0 === u && this.requestResolvedSubtree();
- }
- toggleShown = () => {
- let { layoutActions: s, tag: o, operationId: i, isShown: u } = this.props;
- const _ = this.getResolvedSubtree();
- u || void 0 !== _ || this.requestResolvedSubtree(), s.show(['operations', o, i], !u);
- };
- onCancelClick = () => {
- this.setState({ tryItOutEnabled: !this.state.tryItOutEnabled });
- };
- onTryoutClick = () => {
- this.setState({ tryItOutEnabled: !this.state.tryItOutEnabled });
- };
- onResetClick = (s) => {
- const o = this.props.oas3Selectors.selectDefaultRequestBodyValue(...s);
- this.props.oas3Actions.setRequestBodyValue({ value: o, pathMethod: s });
- };
- onExecute = () => {
- this.setState({ executeInProgress: !0 });
- };
- getResolvedSubtree = () => {
- const { specSelectors: s, path: o, method: i, specPath: u } = this.props;
- return u ? s.specResolvedSubtree(u.toJS()) : s.specResolvedSubtree(['paths', o, i]);
- };
- requestResolvedSubtree = () => {
- const { specActions: s, path: o, method: i, specPath: u } = this.props;
- return u
- ? s.requestResolvedSubtree(u.toJS())
- : s.requestResolvedSubtree(['paths', o, i]);
- };
- render() {
- let {
- op: s,
- tag: o,
- path: i,
- method: u,
- security: _,
- isAuthorized: w,
- operationId: x,
- showSummary: C,
- isShown: j,
- jumpToKey: L,
- allowTryItOut: B,
- response: $,
- request: V,
- displayOperationId: U,
- displayRequestDuration: z,
- isDeepLinkingEnabled: Y,
- specPath: Z,
- specSelectors: ee,
- specActions: ie,
- getComponent: ae,
- getConfigs: le,
- layoutSelectors: ce,
- layoutActions: pe,
- authActions: de,
- authSelectors: fe,
- oas3Actions: ye,
- oas3Selectors: be,
- fn: _e
- } = this.props;
- const we = ae('operation'),
- Se = this.getResolvedSubtree() || (0, qe.Map)(),
- xe = (0, qe.fromJS)({
- op: Se,
- tag: o,
- path: i,
- summary: s.getIn(['operation', 'summary']) || '',
- deprecated: Se.get('deprecated') || s.getIn(['operation', 'deprecated']) || !1,
- method: u,
- security: _,
- isAuthorized: w,
- operationId: x,
- originalOperationId: Se.getIn(['operation', '__originalOperationId']),
- showSummary: C,
- isShown: j,
- jumpToKey: L,
- allowTryItOut: B,
- request: V,
- displayOperationId: U,
- displayRequestDuration: z,
- isDeepLinkingEnabled: Y,
- executeInProgress: this.state.executeInProgress,
- tryItOutEnabled: this.state.tryItOutEnabled
- });
- return Pe.createElement(we, {
- operation: xe,
- response: $,
- request: V,
- isShown: j,
- toggleShown: this.toggleShown,
- onTryoutClick: this.onTryoutClick,
- onResetClick: this.onResetClick,
- onCancelClick: this.onCancelClick,
- onExecute: this.onExecute,
- specPath: Z,
- specActions: ie,
- specSelectors: ee,
- oas3Actions: ye,
- oas3Selectors: be,
- layoutActions: pe,
- layoutSelectors: ce,
- authActions: de,
- authSelectors: fe,
- getComponent: ae,
- getConfigs: le,
- fn: _e
- });
- }
- }
- var mk = __webpack_require__(13222),
- yk = __webpack_require__.n(mk);
- class OperationSummary extends Pe.PureComponent {
- static defaultProps = { operationProps: null, specPath: (0, qe.List)(), summary: '' };
- render() {
- let {
- isShown: s,
- toggleShown: o,
- getComponent: i,
- authActions: u,
- authSelectors: _,
- operationProps: w,
- specPath: x
- } = this.props,
- {
- summary: C,
- isAuthorized: j,
- method: L,
- op: B,
- showSummary: $,
- path: V,
- operationId: U,
- originalOperationId: z,
- displayOperationId: Y
- } = w.toJS(),
- { summary: Z } = B,
- ee = w.get('security');
- const ie = i('authorizeOperationBtn', !0),
- ae = i('OperationSummaryMethod'),
- le = i('OperationSummaryPath'),
- ce = i('JumpToPath', !0),
- pe = i('CopyToClipboardBtn', !0),
- de = i('ArrowUpIcon'),
- fe = i('ArrowDownIcon'),
- ye = ee && !!ee.count(),
- be = ye && 1 === ee.size && ee.first().isEmpty(),
- _e = !ye || be;
- return Pe.createElement(
- 'div',
- { className: `opblock-summary opblock-summary-${L}` },
- Pe.createElement(
- 'button',
- { 'aria-expanded': s, className: 'opblock-summary-control', onClick: o },
- Pe.createElement(ae, { method: L }),
- Pe.createElement(
- 'div',
- { className: 'opblock-summary-path-description-wrapper' },
- Pe.createElement(le, { getComponent: i, operationProps: w, specPath: x }),
- $
- ? Pe.createElement(
- 'div',
- { className: 'opblock-summary-description' },
- yk()(Z || C)
- )
- : null
- ),
- Y && (z || U)
- ? Pe.createElement('span', { className: 'opblock-summary-operation-id' }, z || U)
- : null
- ),
- Pe.createElement(pe, { textToCopy: `${x.get(1)}` }),
- _e
- ? null
- : Pe.createElement(ie, {
- isAuthorized: j,
- onClick: () => {
- const s = _.definitionsForRequirements(ee);
- u.showDefinitions(s);
- }
- }),
- Pe.createElement(ce, { path: x }),
- Pe.createElement(
- 'button',
- {
- 'aria-label': `${L} ${V.replace(/\//g, '/')}`,
- className: 'opblock-control-arrow',
- 'aria-expanded': s,
- tabIndex: '-1',
- onClick: o
- },
- s
- ? Pe.createElement(de, { className: 'arrow' })
- : Pe.createElement(fe, { className: 'arrow' })
- )
- );
- }
- }
- class OperationSummaryMethod extends Pe.PureComponent {
- static defaultProps = { operationProps: null };
- render() {
- let { method: s } = this.props;
- return Pe.createElement(
- 'span',
- { className: 'opblock-summary-method' },
- s.toUpperCase()
- );
- }
- }
- class OperationSummaryPath extends Pe.PureComponent {
- render() {
- let { getComponent: s, operationProps: o } = this.props,
- {
- deprecated: i,
- isShown: u,
- path: _,
- tag: w,
- operationId: x,
- isDeepLinkingEnabled: C
- } = o.toJS();
- const j = _.split(/(?=\/)/g);
- for (let s = 1; s < j.length; s += 2)
- j.splice(s, 0, Pe.createElement('wbr', { key: s }));
- const L = s('DeepLink');
- return Pe.createElement(
- 'span',
- {
- className: i ? 'opblock-summary-path__deprecated' : 'opblock-summary-path',
- 'data-path': _
- },
- Pe.createElement(L, {
- enabled: C,
- isShown: u,
- path: createDeepLinkPath(`${w}/${x}`),
- text: j
- })
- );
- }
- }
- const operation_extensions = ({ extensions: s, getComponent: o }) => {
- let i = o('OperationExtRow');
- return Pe.createElement(
- 'div',
- { className: 'opblock-section' },
- Pe.createElement(
- 'div',
- { className: 'opblock-section-header' },
- Pe.createElement('h4', null, 'Extensions')
- ),
- Pe.createElement(
- 'div',
- { className: 'table-container' },
- Pe.createElement(
- 'table',
- null,
- Pe.createElement(
- 'thead',
- null,
- Pe.createElement(
- 'tr',
- null,
- Pe.createElement('td', { className: 'col_header' }, 'Field'),
- Pe.createElement('td', { className: 'col_header' }, 'Value')
- )
- ),
- Pe.createElement(
- 'tbody',
- null,
- s
- .entrySeq()
- .map(([s, o]) => Pe.createElement(i, { key: `${s}-${o}`, xKey: s, xVal: o }))
- )
- )
- )
- );
- },
- operation_extension_row = ({ xKey: s, xVal: o }) => {
- const i = o ? (o.toJS ? o.toJS() : o) : null;
- return Pe.createElement(
- 'tr',
- null,
- Pe.createElement('td', null, s),
- Pe.createElement('td', null, JSON.stringify(i))
- );
- };
- function createHtmlReadyId(s, o = '_') {
- return s.replace(/[^\w-]/g, o);
- }
- class responses_Responses extends Pe.Component {
- static defaultProps = {
- tryItOutResponse: null,
- produces: (0, qe.fromJS)(['application/json']),
- displayRequestDuration: !1
- };
- onChangeProducesWrapper = (s) =>
- this.props.specActions.changeProducesValue([this.props.path, this.props.method], s);
- onResponseContentTypeChange = ({ controlsAcceptHeader: s, value: o }) => {
- const { oas3Actions: i, path: u, method: _ } = this.props;
- s && i.setResponseContentType({ value: o, path: u, method: _ });
- };
- render() {
- let {
- responses: s,
- tryItOutResponse: o,
- getComponent: i,
- getConfigs: u,
- specSelectors: _,
- fn: w,
- producesValue: x,
- displayRequestDuration: C,
- specPath: j,
- path: L,
- method: B,
- oas3Selectors: $,
- oas3Actions: V
- } = this.props,
- U = (function defaultStatusCode(s) {
- let o = s.keySeq();
- return o.contains(At)
- ? At
- : o
- .filter((s) => '2' === (s + '')[0])
- .sort()
- .first();
- })(s);
- const z = i('contentType'),
- Y = i('liveResponse'),
- Z = i('response');
- let ee =
- this.props.produces && this.props.produces.size
- ? this.props.produces
- : responses_Responses.defaultProps.produces;
- const ie = _.isOAS3()
- ? (function getAcceptControllingResponse(s) {
- if (!$e().OrderedMap.isOrderedMap(s)) return null;
- if (!s.size) return null;
- const o = s.find(
- (s, o) =>
- o.startsWith('2') && Object.keys(s.get('content') || {}).length > 0
- ),
- i = s.get('default') || $e().OrderedMap(),
- u = (i.get('content') || $e().OrderedMap()).keySeq().toJS().length ? i : null;
- return o || u;
- })(s)
- : null,
- ae = createHtmlReadyId(`${B}${L}_responses`),
- le = `${ae}_select`;
- return Pe.createElement(
- 'div',
- { className: 'responses-wrapper' },
- Pe.createElement(
- 'div',
- { className: 'opblock-section-header' },
- Pe.createElement('h4', null, 'Responses'),
- _.isOAS3()
- ? null
- : Pe.createElement(
- 'label',
- { htmlFor: le },
- Pe.createElement('span', null, 'Response content type'),
- Pe.createElement(z, {
- value: x,
- ariaControls: ae,
- ariaLabel: 'Response content type',
- className: 'execute-content-type',
- contentTypes: ee,
- controlId: le,
- onChange: this.onChangeProducesWrapper
- })
- )
- ),
- Pe.createElement(
- 'div',
- { className: 'responses-inner' },
- o
- ? Pe.createElement(
- 'div',
- null,
- Pe.createElement(Y, {
- response: o,
- getComponent: i,
- getConfigs: u,
- specSelectors: _,
- path: this.props.path,
- method: this.props.method,
- displayRequestDuration: C
- }),
- Pe.createElement('h4', null, 'Responses')
- )
- : null,
- Pe.createElement(
- 'table',
- { 'aria-live': 'polite', className: 'responses-table', id: ae, role: 'region' },
- Pe.createElement(
- 'thead',
- null,
- Pe.createElement(
- 'tr',
- { className: 'responses-header' },
- Pe.createElement(
- 'td',
- { className: 'col_header response-col_status' },
- 'Code'
- ),
- Pe.createElement(
- 'td',
- { className: 'col_header response-col_description' },
- 'Description'
- ),
- _.isOAS3()
- ? Pe.createElement(
- 'td',
- { className: 'col col_header response-col_links' },
- 'Links'
- )
- : null
- )
- ),
- Pe.createElement(
- 'tbody',
- null,
- s
- .entrySeq()
- .map(([s, C]) => {
- let z = o && o.get('status') == s ? 'response_current' : '';
- return Pe.createElement(Z, {
- key: s,
- path: L,
- method: B,
- specPath: j.push(s),
- isDefault: U === s,
- fn: w,
- className: z,
- code: s,
- response: C,
- specSelectors: _,
- controlsAcceptHeader: C === ie,
- onContentTypeChange: this.onResponseContentTypeChange,
- contentType: x,
- getConfigs: u,
- activeExamplesKey: $.activeExamplesMember(L, B, 'responses', s),
- oas3Actions: V,
- getComponent: i
- });
- })
- .toArray()
- )
- )
- )
- );
- }
- }
- function getKnownSyntaxHighlighterLanguage(s) {
- const o = (function canJsonParse(s) {
- try {
- return !!JSON.parse(s);
- } catch (s) {
- return null;
- }
- })(s);
- return o ? 'json' : null;
- }
- class response_Response extends Pe.Component {
- constructor(s, o) {
- super(s, o), (this.state = { responseContentType: '' });
- }
- static defaultProps = { response: (0, qe.fromJS)({}), onContentTypeChange: () => {} };
- _onContentTypeChange = (s) => {
- const { onContentTypeChange: o, controlsAcceptHeader: i } = this.props;
- this.setState({ responseContentType: s }), o({ value: s, controlsAcceptHeader: i });
- };
- getTargetExamplesKey = () => {
- const { response: s, contentType: o, activeExamplesKey: i } = this.props,
- u = this.state.responseContentType || o,
- _ = s
- .getIn(['content', u], (0, qe.Map)({}))
- .get('examples', null)
- .keySeq()
- .first();
- return i || _;
- };
- render() {
- let {
- path: s,
- method: o,
- code: i,
- response: u,
- className: _,
- specPath: w,
- fn: x,
- getComponent: C,
- getConfigs: j,
- specSelectors: L,
- contentType: B,
- controlsAcceptHeader: $,
- oas3Actions: V
- } = this.props,
- { inferSchema: U, getSampleSchema: z } = x,
- Y = L.isOAS3();
- const { showExtensions: Z } = j();
- let ee = Z ? getExtensions(u) : null,
- ie = u.get('headers'),
- ae = u.get('links');
- const le = C('ResponseExtension'),
- ce = C('headers'),
- pe = C('HighlightCode', !0),
- de = C('modelExample'),
- fe = C('Markdown', !0),
- ye = C('operationLink'),
- be = C('contentType'),
- _e = C('ExamplesSelect'),
- we = C('Example');
- var Se, xe;
- const Te = this.state.responseContentType || B,
- Re = u.getIn(['content', Te], (0, qe.Map)({})),
- $e = Re.get('examples', null);
- if (Y) {
- const s = Re.get('schema');
- (Se = s ? U(s.toJS()) : null),
- (xe = s ? (0, qe.List)(['content', this.state.responseContentType, 'schema']) : w);
- } else (Se = u.get('schema')), (xe = u.has('schema') ? w.push('schema') : w);
- let ze,
- We,
- He = !1,
- Ye = { includeReadOnly: !0 };
- if (Y)
- if (((We = Re.get('schema')?.toJS()), qe.Map.isMap($e) && !$e.isEmpty())) {
- const s = this.getTargetExamplesKey(),
- getMediaTypeExample = (s) => s.get('value');
- (ze = getMediaTypeExample($e.get(s, (0, qe.Map)({})))),
- void 0 === ze && (ze = getMediaTypeExample($e.values().next().value)),
- (He = !0);
- } else void 0 !== Re.get('example') && ((ze = Re.get('example')), (He = !0));
- else {
- (We = Se), (Ye = { ...Ye, includeWriteOnly: !0 });
- const s = u.getIn(['examples', Te]);
- s && ((ze = s), (He = !0));
- }
- const Xe = ((s, o) => {
- if (null == s) return null;
- const i = getKnownSyntaxHighlighterLanguage(s) ? 'json' : null;
- return Pe.createElement(
- 'div',
- null,
- Pe.createElement(o, { className: 'example', language: i }, stringify(s))
- );
- })(z(We, Te, Ye, He ? ze : void 0), pe);
- return Pe.createElement(
- 'tr',
- { className: 'response ' + (_ || ''), 'data-code': i },
- Pe.createElement('td', { className: 'response-col_status' }, i),
- Pe.createElement(
- 'td',
- { className: 'response-col_description' },
- Pe.createElement(
- 'div',
- { className: 'response-col_description__inner' },
- Pe.createElement(fe, { source: u.get('description') })
- ),
- Z && ee.size
- ? ee
- .entrySeq()
- .map(([s, o]) => Pe.createElement(le, { key: `${s}-${o}`, xKey: s, xVal: o }))
- : null,
- Y && u.get('content')
- ? Pe.createElement(
- 'section',
- { className: 'response-controls' },
- Pe.createElement(
- 'div',
- {
- className: Hn()('response-control-media-type', {
- 'response-control-media-type--accept-controller': $
- })
- },
- Pe.createElement(
- 'small',
- { className: 'response-control-media-type__title' },
- 'Media type'
- ),
- Pe.createElement(be, {
- value: this.state.responseContentType,
- contentTypes: u.get('content')
- ? u.get('content').keySeq()
- : (0, qe.Seq)(),
- onChange: this._onContentTypeChange,
- ariaLabel: 'Media Type'
- }),
- $
- ? Pe.createElement(
- 'small',
- { className: 'response-control-media-type__accept-message' },
- 'Controls ',
- Pe.createElement('code', null, 'Accept'),
- ' header.'
- )
- : null
- ),
- qe.Map.isMap($e) && !$e.isEmpty()
- ? Pe.createElement(
- 'div',
- { className: 'response-control-examples' },
- Pe.createElement(
- 'small',
- { className: 'response-control-examples__title' },
- 'Examples'
- ),
- Pe.createElement(_e, {
- examples: $e,
- currentExampleKey: this.getTargetExamplesKey(),
- onSelect: (u) =>
- V.setActiveExamplesMember({
- name: u,
- pathMethod: [s, o],
- contextType: 'responses',
- contextName: i
- }),
- showLabels: !1
- })
- )
- : null
- )
- : null,
- Xe || Se
- ? Pe.createElement(de, {
- specPath: xe,
- getComponent: C,
- getConfigs: j,
- specSelectors: L,
- schema: fromJSOrdered(Se),
- example: Xe,
- includeReadOnly: !0
- })
- : null,
- Y && $e
- ? Pe.createElement(we, {
- example: $e.get(this.getTargetExamplesKey(), (0, qe.Map)({})),
- getComponent: C,
- getConfigs: j,
- omitValue: !0
- })
- : null,
- ie ? Pe.createElement(ce, { headers: ie, getComponent: C }) : null
- ),
- Y
- ? Pe.createElement(
- 'td',
- { className: 'response-col_links' },
- ae
- ? ae
- .toSeq()
- .entrySeq()
- .map(([s, o]) =>
- Pe.createElement(ye, { key: s, name: s, link: o, getComponent: C })
- )
- : Pe.createElement('i', null, 'No links')
- )
- : null
- );
- }
- }
- const response_extension = ({ xKey: s, xVal: o }) =>
- Pe.createElement('div', { className: 'response__extension' }, s, ': ', String(o));
- var vk = __webpack_require__(26657),
- _k = __webpack_require__.n(vk),
- wk = __webpack_require__(80218),
- xk = __webpack_require__.n(wk);
- class ResponseBody extends Pe.PureComponent {
- state = { parsedContent: null };
- updateParsedContent = (s) => {
- const { content: o } = this.props;
- if (s !== o)
- if (o && o instanceof Blob) {
- var i = new FileReader();
- (i.onload = () => {
- this.setState({ parsedContent: i.result });
- }),
- i.readAsText(o);
- } else this.setState({ parsedContent: o.toString() });
- };
- componentDidMount() {
- this.updateParsedContent(null);
- }
- componentDidUpdate(s) {
- this.updateParsedContent(s.content);
- }
- render() {
- let {
- content: s,
- contentType: o,
- url: i,
- headers: u = {},
- getComponent: _
- } = this.props;
- const { parsedContent: w } = this.state,
- x = _('HighlightCode', !0),
- C = 'response_' + new Date().getTime();
- let j, L;
- if (
- ((i = i || ''),
- (/^application\/octet-stream/i.test(o) ||
- (u['Content-Disposition'] && /attachment/i.test(u['Content-Disposition'])) ||
- (u['content-disposition'] && /attachment/i.test(u['content-disposition'])) ||
- (u['Content-Description'] && /File Transfer/i.test(u['Content-Description'])) ||
- (u['content-description'] && /File Transfer/i.test(u['content-description']))) &&
- (s.size > 0 || s.length > 0))
- )
- if ('Blob' in window) {
- let _ = o || 'text/html',
- w = s instanceof Blob ? s : new Blob([s], { type: _ }),
- x = window.URL.createObjectURL(w),
- C = [_, i.substr(i.lastIndexOf('/') + 1), x].join(':'),
- j = u['content-disposition'] || u['Content-Disposition'];
- if (void 0 !== j) {
- let s = (function extractFileNameFromContentDispositionHeader(s) {
- let o;
- if (
- ([
- /filename\*=[^']+'\w*'"([^"]+)";?/i,
- /filename\*=[^']+'\w*'([^;]+);?/i,
- /filename="([^;]*);?"/i,
- /filename=([^;]*);?/i
- ].some((i) => ((o = i.exec(s)), null !== o)),
- null !== o && o.length > 1)
- )
- try {
- return decodeURIComponent(o[1]);
- } catch (s) {
- console.error(s);
- }
- return null;
- })(j);
- null !== s && (C = s);
- }
- L =
- at.navigator && at.navigator.msSaveOrOpenBlob
- ? Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'a',
- { href: x, onClick: () => at.navigator.msSaveOrOpenBlob(w, C) },
- 'Download file'
- )
- )
- : Pe.createElement(
- 'div',
- null,
- Pe.createElement('a', { href: x, download: C }, 'Download file')
- );
- } else
- L = Pe.createElement(
- 'pre',
- { className: 'microlight' },
- 'Download headers detected but your browser does not support downloading binary via XHR (Blob).'
- );
- else if (/json/i.test(o)) {
- let o = null;
- getKnownSyntaxHighlighterLanguage(s) && (o = 'json');
- try {
- j = JSON.stringify(JSON.parse(s), null, ' ');
- } catch (o) {
- j = "can't parse JSON. Raw result:\n\n" + s;
- }
- L = Pe.createElement(
- x,
- { language: o, downloadable: !0, fileName: `${C}.json`, canCopy: !0 },
- j
- );
- } else
- /xml/i.test(o)
- ? ((j = _k()(s, { textNodesOnSameLine: !0, indentor: ' ' })),
- (L = Pe.createElement(
- x,
- { downloadable: !0, fileName: `${C}.xml`, canCopy: !0 },
- j
- )))
- : (L =
- 'text/html' === xk()(o) || /text\/plain/.test(o)
- ? Pe.createElement(
- x,
- { downloadable: !0, fileName: `${C}.html`, canCopy: !0 },
- s
- )
- : 'text/csv' === xk()(o) || /text\/csv/.test(o)
- ? Pe.createElement(
- x,
- { downloadable: !0, fileName: `${C}.csv`, canCopy: !0 },
- s
- )
- : /^image\//i.test(o)
- ? o.includes('svg')
- ? Pe.createElement('div', null, ' ', s, ' ')
- : Pe.createElement('img', { src: window.URL.createObjectURL(s) })
- : /^audio\//i.test(o)
- ? Pe.createElement(
- 'pre',
- { className: 'microlight' },
- Pe.createElement(
- 'audio',
- { controls: !0, key: i },
- Pe.createElement('source', { src: i, type: o })
- )
- )
- : 'string' == typeof s
- ? Pe.createElement(
- x,
- { downloadable: !0, fileName: `${C}.txt`, canCopy: !0 },
- s
- )
- : s.size > 0
- ? w
- ? Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'p',
- { className: 'i' },
- 'Unrecognized response type; displaying content as text.'
- ),
- Pe.createElement(
- x,
- { downloadable: !0, fileName: `${C}.txt`, canCopy: !0 },
- w
- )
- )
- : Pe.createElement(
- 'p',
- { className: 'i' },
- 'Unrecognized response type; unable to display.'
- )
- : null);
- return L
- ? Pe.createElement('div', null, Pe.createElement('h5', null, 'Response body'), L)
- : null;
- }
- }
- class Parameters extends Pe.Component {
- constructor(s) {
- super(s), (this.state = { callbackVisible: !1, parametersVisible: !0 });
- }
- static defaultProps = {
- onTryoutClick: Function.prototype,
- onCancelClick: Function.prototype,
- tryItOutEnabled: !1,
- allowTryItOut: !0,
- onChangeKey: [],
- specPath: []
- };
- onChange = (s, o, i) => {
- let {
- specActions: { changeParamByIdentity: u },
- onChangeKey: _
- } = this.props;
- u(_, s, o, i);
- };
- onChangeConsumesWrapper = (s) => {
- let {
- specActions: { changeConsumesValue: o },
- onChangeKey: i
- } = this.props;
- o(i, s);
- };
- toggleTab = (s) =>
- 'parameters' === s
- ? this.setState({ parametersVisible: !0, callbackVisible: !1 })
- : 'callbacks' === s
- ? this.setState({ callbackVisible: !0, parametersVisible: !1 })
- : void 0;
- onChangeMediaType = ({ value: s, pathMethod: o }) => {
- let { specActions: i, oas3Selectors: u, oas3Actions: _ } = this.props;
- const w = u.hasUserEditedBody(...o),
- x = u.shouldRetainRequestBodyValue(...o);
- _.setRequestContentType({ value: s, pathMethod: o }),
- _.initRequestBodyValidateError({ pathMethod: o }),
- w ||
- (x || _.setRequestBodyValue({ value: void 0, pathMethod: o }),
- i.clearResponse(...o),
- i.clearRequest(...o),
- i.clearValidateParams(o));
- };
- render() {
- let {
- onTryoutClick: s,
- onResetClick: o,
- parameters: i,
- allowTryItOut: u,
- tryItOutEnabled: _,
- specPath: w,
- fn: x,
- getComponent: C,
- getConfigs: j,
- specSelectors: L,
- specActions: B,
- pathMethod: $,
- oas3Actions: V,
- oas3Selectors: U,
- operation: z
- } = this.props;
- const Y = C('parameterRow'),
- Z = C('TryItOutButton'),
- ee = C('contentType'),
- ie = C('Callbacks', !0),
- ae = C('RequestBody', !0),
- le = _ && u,
- ce = L.isOAS3(),
- pe = `${createHtmlReadyId(`${$[1]}${$[0]}_requests`)}_select`,
- de = z.get('requestBody'),
- fe = Object.values(
- i.reduce((s, o) => {
- const i = o.get('in');
- return (s[i] ??= []), s[i].push(o), s;
- }, {})
- ).reduce((s, o) => s.concat(o), []);
- return Pe.createElement(
- 'div',
- { className: 'opblock-section' },
- Pe.createElement(
- 'div',
- { className: 'opblock-section-header' },
- ce
- ? Pe.createElement(
- 'div',
- { className: 'tab-header' },
- Pe.createElement(
- 'div',
- {
- onClick: () => this.toggleTab('parameters'),
- className: `tab-item ${this.state.parametersVisible && 'active'}`
- },
- Pe.createElement(
- 'h4',
- { className: 'opblock-title' },
- Pe.createElement('span', null, 'Parameters')
- )
- ),
- z.get('callbacks')
- ? Pe.createElement(
- 'div',
- {
- onClick: () => this.toggleTab('callbacks'),
- className: `tab-item ${this.state.callbackVisible && 'active'}`
- },
- Pe.createElement(
- 'h4',
- { className: 'opblock-title' },
- Pe.createElement('span', null, 'Callbacks')
- )
- )
- : null
- )
- : Pe.createElement(
- 'div',
- { className: 'tab-header' },
- Pe.createElement('h4', { className: 'opblock-title' }, 'Parameters')
- ),
- u
- ? Pe.createElement(Z, {
- isOAS3: L.isOAS3(),
- hasUserEditedBody: U.hasUserEditedBody(...$),
- enabled: _,
- onCancelClick: this.props.onCancelClick,
- onTryoutClick: s,
- onResetClick: () => o($)
- })
- : null
- ),
- this.state.parametersVisible
- ? Pe.createElement(
- 'div',
- { className: 'parameters-container' },
- fe.length
- ? Pe.createElement(
- 'div',
- { className: 'table-container' },
- Pe.createElement(
- 'table',
- { className: 'parameters' },
- Pe.createElement(
- 'thead',
- null,
- Pe.createElement(
- 'tr',
- null,
- Pe.createElement(
- 'th',
- { className: 'col_header parameters-col_name' },
- 'Name'
- ),
- Pe.createElement(
- 'th',
- { className: 'col_header parameters-col_description' },
- 'Description'
- )
- )
- ),
- Pe.createElement(
- 'tbody',
- null,
- fe.map((s, o) =>
- Pe.createElement(Y, {
- fn: x,
- specPath: w.push(o.toString()),
- getComponent: C,
- getConfigs: j,
- rawParam: s,
- param: L.parameterWithMetaByIdentity($, s),
- key: `${s.get('in')}.${s.get('name')}`,
- onChange: this.onChange,
- onChangeConsumes: this.onChangeConsumesWrapper,
- specSelectors: L,
- specActions: B,
- oas3Actions: V,
- oas3Selectors: U,
- pathMethod: $,
- isExecute: le
- })
- )
- )
- )
- )
- : Pe.createElement(
- 'div',
- { className: 'opblock-description-wrapper' },
- Pe.createElement('p', null, 'No parameters')
- )
- )
- : null,
- this.state.callbackVisible
- ? Pe.createElement(
- 'div',
- { className: 'callbacks-container opblock-description-wrapper' },
- Pe.createElement(ie, {
- callbacks: (0, qe.Map)(z.get('callbacks')),
- specPath: w.slice(0, -1).push('callbacks')
- })
- )
- : null,
- ce &&
- de &&
- this.state.parametersVisible &&
- Pe.createElement(
- 'div',
- { className: 'opblock-section opblock-section-request-body' },
- Pe.createElement(
- 'div',
- { className: 'opblock-section-header' },
- Pe.createElement(
- 'h4',
- {
- className: `opblock-title parameter__name ${de.get('required') && 'required'}`
- },
- 'Request body'
- ),
- Pe.createElement(
- 'label',
- { id: pe },
- Pe.createElement(ee, {
- value: U.requestContentType(...$),
- contentTypes: de.get('content', (0, qe.List)()).keySeq(),
- onChange: (s) => {
- this.onChangeMediaType({ value: s, pathMethod: $ });
- },
- className: 'body-param-content-type',
- ariaLabel: 'Request content type',
- controlId: pe
- })
- )
- ),
- Pe.createElement(
- 'div',
- { className: 'opblock-description-wrapper' },
- Pe.createElement(ae, {
- setRetainRequestBodyValueFlag: (s) =>
- V.setRetainRequestBodyValueFlag({ value: s, pathMethod: $ }),
- userHasEditedBody: U.hasUserEditedBody(...$),
- specPath: w.slice(0, -1).push('requestBody'),
- requestBody: de,
- requestBodyValue: U.requestBodyValue(...$),
- requestBodyInclusionSetting: U.requestBodyInclusionSetting(...$),
- requestBodyErrors: U.requestBodyErrors(...$),
- isExecute: le,
- getConfigs: j,
- activeExamplesKey: U.activeExamplesMember(...$, 'requestBody', 'requestBody'),
- updateActiveExamplesKey: (s) => {
- this.props.oas3Actions.setActiveExamplesMember({
- name: s,
- pathMethod: this.props.pathMethod,
- contextType: 'requestBody',
- contextName: 'requestBody'
- });
- },
- onChange: (s, o) => {
- if (o) {
- const i = U.requestBodyValue(...$),
- u = qe.Map.isMap(i) ? i : (0, qe.Map)();
- return V.setRequestBodyValue({ pathMethod: $, value: u.setIn(o, s) });
- }
- V.setRequestBodyValue({ value: s, pathMethod: $ });
- },
- onChangeIncludeEmpty: (s, o) => {
- V.setRequestBodyInclusion({ pathMethod: $, value: o, name: s });
- },
- contentType: U.requestContentType(...$)
- })
- )
- )
- );
- }
- }
- const parameter_extension = ({ xKey: s, xVal: o }) =>
- Pe.createElement('div', { className: 'parameter__extension' }, s, ': ', String(o)),
- Ak = { onChange: () => {}, isIncludedOptions: {} };
- class ParameterIncludeEmpty extends Pe.Component {
- static defaultProps = Ak;
- componentDidMount() {
- const { isIncludedOptions: s, onChange: o } = this.props,
- { shouldDispatchInit: i, defaultValue: u } = s;
- i && o(u);
- }
- onCheckboxChange = (s) => {
- const { onChange: o } = this.props;
- o(s.target.checked);
- };
- render() {
- let { isIncluded: s, isDisabled: o } = this.props;
- return Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'label',
- {
- htmlFor: 'include_empty_value',
- className: Hn()('parameter__empty_value_toggle', { disabled: o })
- },
- Pe.createElement('input', {
- id: 'include_empty_value',
- type: 'checkbox',
- disabled: o,
- checked: !o && s,
- onChange: this.onCheckboxChange
- }),
- 'Send empty value'
- )
- );
- }
- }
- class ParameterRow extends Pe.Component {
- constructor(s, o) {
- super(s, o), this.setDefaultValue();
- }
- UNSAFE_componentWillReceiveProps(s) {
- let o,
- { specSelectors: i, pathMethod: u, rawParam: _ } = s,
- w = i.isOAS3(),
- x = i.parameterWithMetaByIdentity(u, _) || new qe.Map();
- if (((x = x.isEmpty() ? _ : x), w)) {
- let { schema: s } = getParameterSchema(x, { isOAS3: w });
- o = s ? s.get('enum') : void 0;
- } else o = x ? x.get('enum') : void 0;
- let C,
- j = x ? x.get('value') : void 0;
- void 0 !== j ? (C = j) : _.get('required') && o && o.size && (C = o.first()),
- void 0 !== C &&
- C !== j &&
- this.onChangeWrapper(
- (function numberToString(s) {
- return 'number' == typeof s ? s.toString() : s;
- })(C)
- ),
- this.setDefaultValue();
- }
- onChangeWrapper = (s, o = !1) => {
- let i,
- { onChange: u, rawParam: _ } = this.props;
- return (i = '' === s || (s && 0 === s.size) ? null : s), u(_, i, o);
- };
- _onExampleSelect = (s) => {
- this.props.oas3Actions.setActiveExamplesMember({
- name: s,
- pathMethod: this.props.pathMethod,
- contextType: 'parameters',
- contextName: this.getParamKey()
- });
- };
- onChangeIncludeEmpty = (s) => {
- let { specActions: o, param: i, pathMethod: u } = this.props;
- const _ = i.get('name'),
- w = i.get('in');
- return o.updateEmptyParamInclusion(u, _, w, s);
- };
- setDefaultValue = () => {
- let {
- specSelectors: s,
- pathMethod: o,
- rawParam: i,
- oas3Selectors: u,
- fn: _
- } = this.props;
- const w = s.parameterWithMetaByIdentity(o, i) || (0, qe.Map)();
- let { schema: x } = getParameterSchema(w, { isOAS3: s.isOAS3() });
- const C = w
- .get('content', (0, qe.Map)())
- .keySeq()
- .first(),
- j = x ? _.getSampleSchema(x.toJS(), C, { includeWriteOnly: !0 }) : null;
- if (w && void 0 === w.get('value') && 'body' !== w.get('in')) {
- let i;
- if (s.isSwagger2())
- i =
- void 0 !== w.get('x-example')
- ? w.get('x-example')
- : void 0 !== w.getIn(['schema', 'example'])
- ? w.getIn(['schema', 'example'])
- : x && x.getIn(['default']);
- else if (s.isOAS3()) {
- x = this.composeJsonSchema(x);
- const s = u.activeExamplesMember(...o, 'parameters', this.getParamKey());
- i =
- void 0 !== w.getIn(['examples', s, 'value'])
- ? w.getIn(['examples', s, 'value'])
- : void 0 !== w.getIn(['content', C, 'example'])
- ? w.getIn(['content', C, 'example'])
- : void 0 !== w.get('example')
- ? w.get('example')
- : void 0 !== (x && x.get('example'))
- ? x && x.get('example')
- : void 0 !== (x && x.get('default'))
- ? x && x.get('default')
- : w.get('default');
- }
- void 0 === i || qe.List.isList(i) || (i = stringify(i)),
- void 0 !== i
- ? this.onChangeWrapper(i)
- : x &&
- 'object' === x.get('type') &&
- j &&
- !w.get('examples') &&
- this.onChangeWrapper(qe.List.isList(j) ? j : stringify(j));
- }
- };
- getParamKey() {
- const { param: s } = this.props;
- return s ? `${s.get('name')}-${s.get('in')}` : null;
- }
- composeJsonSchema(s) {
- const { fn: o } = this.props,
- i = s.get('oneOf')?.get(0)?.toJS(),
- u = s.get('anyOf')?.get(0)?.toJS();
- return (0, qe.fromJS)(o.mergeJsonSchema(s.toJS(), i ?? u ?? {}));
- }
- render() {
- let {
- param: s,
- rawParam: o,
- getComponent: i,
- getConfigs: u,
- isExecute: _,
- fn: w,
- onChangeConsumes: x,
- specSelectors: C,
- pathMethod: j,
- specPath: L,
- oas3Selectors: B
- } = this.props,
- $ = C.isOAS3();
- const { showExtensions: V, showCommonExtensions: U } = u();
- if ((s || (s = o), !o)) return null;
- const z = i('JsonSchemaForm'),
- Y = i('ParamBody');
- let Z = s.get('in'),
- ee =
- 'body' !== Z
- ? null
- : Pe.createElement(Y, {
- getComponent: i,
- getConfigs: u,
- fn: w,
- param: s,
- consumes: C.consumesOptionsFor(j),
- consumesValue: C.contentTypeValues(j).get('requestContentType'),
- onChange: this.onChangeWrapper,
- onChangeConsumes: x,
- isExecute: _,
- specSelectors: C,
- pathMethod: j
- });
- const ie = i('modelExample'),
- ae = i('Markdown', !0),
- le = i('ParameterExt'),
- ce = i('ParameterIncludeEmpty'),
- pe = i('ExamplesSelectValueRetainer'),
- de = i('Example');
- let { schema: fe } = getParameterSchema(s, { isOAS3: $ }),
- ye = C.parameterWithMetaByIdentity(j, o) || (0, qe.Map)();
- $ && (fe = this.composeJsonSchema(fe));
- let be,
- _e,
- we,
- Se,
- xe = fe ? fe.get('format') : null,
- Te = fe ? fe.get('type') : null,
- Re = fe ? fe.getIn(['items', 'type']) : null,
- $e = 'formData' === Z,
- ze = 'FormData' in at,
- We = s.get('required'),
- He = ye ? ye.get('value') : '',
- Ye = U ? getCommonExtensions(fe) : null,
- Xe = V ? getExtensions(s) : null,
- Qe = !1;
- return (
- void 0 !== s && fe && (be = fe.get('items')),
- void 0 !== be
- ? ((_e = be.get('enum')), (we = be.get('default')))
- : fe && (_e = fe.get('enum')),
- _e && _e.size && _e.size > 0 && (Qe = !0),
- void 0 !== s &&
- (fe && (we = fe.get('default')),
- void 0 === we && (we = s.get('default')),
- (Se = s.get('example')),
- void 0 === Se && (Se = s.get('x-example'))),
- Pe.createElement(
- 'tr',
- { 'data-param-name': s.get('name'), 'data-param-in': s.get('in') },
- Pe.createElement(
- 'td',
- { className: 'parameters-col_name' },
- Pe.createElement(
- 'div',
- { className: We ? 'parameter__name required' : 'parameter__name' },
- s.get('name'),
- We ? Pe.createElement('span', null, ' *') : null
- ),
- Pe.createElement(
- 'div',
- { className: 'parameter__type' },
- Te,
- Re && `[${Re}]`,
- xe && Pe.createElement('span', { className: 'prop-format' }, '($', xe, ')')
- ),
- Pe.createElement(
- 'div',
- { className: 'parameter__deprecated' },
- $ && s.get('deprecated') ? 'deprecated' : null
- ),
- Pe.createElement('div', { className: 'parameter__in' }, '(', s.get('in'), ')')
- ),
- Pe.createElement(
- 'td',
- { className: 'parameters-col_description' },
- s.get('description')
- ? Pe.createElement(ae, { source: s.get('description') })
- : null,
- (!ee && _) || !Qe
- ? null
- : Pe.createElement(ae, {
- className: 'parameter__enum',
- source:
- '<i>Available values</i> : ' +
- _e
- .map(function (s) {
- return s;
- })
- .toArray()
- .map(String)
- .join(', ')
- }),
- (!ee && _) || void 0 === we
- ? null
- : Pe.createElement(ae, {
- className: 'parameter__default',
- source: '<i>Default value</i> : ' + we
- }),
- (!ee && _) || void 0 === Se
- ? null
- : Pe.createElement(ae, { source: '<i>Example</i> : ' + Se }),
- $e &&
- !ze &&
- Pe.createElement('div', null, 'Error: your browser does not support FormData'),
- $ && s.get('examples')
- ? Pe.createElement(
- 'section',
- { className: 'parameter-controls' },
- Pe.createElement(pe, {
- examples: s.get('examples'),
- onSelect: this._onExampleSelect,
- updateValue: this.onChangeWrapper,
- getComponent: i,
- defaultToFirstExample: !0,
- currentKey: B.activeExamplesMember(
- ...j,
- 'parameters',
- this.getParamKey()
- ),
- currentUserInputValue: He
- })
- )
- : null,
- ee
- ? null
- : Pe.createElement(z, {
- fn: w,
- getComponent: i,
- value: He,
- required: We,
- disabled: !_,
- description: s.get('name'),
- onChange: this.onChangeWrapper,
- errors: ye.get('errors'),
- schema: fe
- }),
- ee && fe
- ? Pe.createElement(ie, {
- getComponent: i,
- specPath: L.push('schema'),
- getConfigs: u,
- isExecute: _,
- specSelectors: C,
- schema: fe,
- example: ee,
- includeWriteOnly: !0
- })
- : null,
- !ee && _ && s.get('allowEmptyValue')
- ? Pe.createElement(ce, {
- onChange: this.onChangeIncludeEmpty,
- isIncluded: C.parameterInclusionSettingFor(j, s.get('name'), s.get('in')),
- isDisabled: !isEmptyValue(He)
- })
- : null,
- $ && s.get('examples')
- ? Pe.createElement(de, {
- example: s.getIn([
- 'examples',
- B.activeExamplesMember(...j, 'parameters', this.getParamKey())
- ]),
- getComponent: i,
- getConfigs: u
- })
- : null,
- U && Ye.size
- ? Ye.entrySeq().map(([s, o]) =>
- Pe.createElement(le, { key: `${s}-${o}`, xKey: s, xVal: o })
- )
- : null,
- V && Xe.size
- ? Xe.entrySeq().map(([s, o]) =>
- Pe.createElement(le, { key: `${s}-${o}`, xKey: s, xVal: o })
- )
- : null
- )
- )
- );
- }
- }
- class Execute extends Pe.Component {
- handleValidateParameters = () => {
- let { specSelectors: s, specActions: o, path: i, method: u } = this.props;
- return o.validateParams([i, u]), s.validateBeforeExecute([i, u]);
- };
- handleValidateRequestBody = () => {
- let {
- path: s,
- method: o,
- specSelectors: i,
- oas3Selectors: u,
- oas3Actions: _
- } = this.props,
- w = { missingBodyValue: !1, missingRequiredKeys: [] };
- _.clearRequestBodyValidateError({ path: s, method: o });
- let x = i.getOAS3RequiredRequestBodyContentType([s, o]),
- C = u.requestBodyValue(s, o),
- j = u.validateBeforeExecute([s, o]),
- L = u.requestContentType(s, o);
- if (!j)
- return (
- (w.missingBodyValue = !0),
- _.setRequestBodyValidateError({ path: s, method: o, validationErrors: w }),
- !1
- );
- if (!x) return !0;
- let B = u.validateShallowRequired({
- oas3RequiredRequestBodyContentType: x,
- oas3RequestContentType: L,
- oas3RequestBodyValue: C
- });
- return (
- !B ||
- B.length < 1 ||
- (B.forEach((s) => {
- w.missingRequiredKeys.push(s);
- }),
- _.setRequestBodyValidateError({ path: s, method: o, validationErrors: w }),
- !1)
- );
- };
- handleValidationResultPass = () => {
- let { specActions: s, operation: o, path: i, method: u } = this.props;
- this.props.onExecute && this.props.onExecute(),
- s.execute({ operation: o, path: i, method: u });
- };
- handleValidationResultFail = () => {
- let { specActions: s, path: o, method: i } = this.props;
- s.clearValidateParams([o, i]),
- setTimeout(() => {
- s.validateParams([o, i]);
- }, 40);
- };
- handleValidationResult = (s) => {
- s ? this.handleValidationResultPass() : this.handleValidationResultFail();
- };
- onClick = () => {
- let s = this.handleValidateParameters(),
- o = this.handleValidateRequestBody(),
- i = s && o;
- this.handleValidationResult(i);
- };
- onChangeProducesWrapper = (s) =>
- this.props.specActions.changeProducesValue([this.props.path, this.props.method], s);
- render() {
- const { disabled: s } = this.props;
- return Pe.createElement(
- 'button',
- { className: 'btn execute opblock-control__btn', onClick: this.onClick, disabled: s },
- 'Execute'
- );
- }
- }
- class headers_Headers extends Pe.Component {
- render() {
- let { headers: s, getComponent: o } = this.props;
- const i = o('Property'),
- u = o('Markdown', !0);
- return s && s.size
- ? Pe.createElement(
- 'div',
- { className: 'headers-wrapper' },
- Pe.createElement('h4', { className: 'headers__title' }, 'Headers:'),
- Pe.createElement(
- 'table',
- { className: 'headers' },
- Pe.createElement(
- 'thead',
- null,
- Pe.createElement(
- 'tr',
- { className: 'header-row' },
- Pe.createElement('th', { className: 'header-col' }, 'Name'),
- Pe.createElement('th', { className: 'header-col' }, 'Description'),
- Pe.createElement('th', { className: 'header-col' }, 'Type')
- )
- ),
- Pe.createElement(
- 'tbody',
- null,
- s
- .entrySeq()
- .map(([s, o]) => {
- if (!$e().Map.isMap(o)) return null;
- const _ = o.get('description'),
- w = o.getIn(['schema'])
- ? o.getIn(['schema', 'type'])
- : o.getIn(['type']),
- x = o.getIn(['schema', 'example']);
- return Pe.createElement(
- 'tr',
- { key: s },
- Pe.createElement('td', { className: 'header-col' }, s),
- Pe.createElement(
- 'td',
- { className: 'header-col' },
- _ ? Pe.createElement(u, { source: _ }) : null
- ),
- Pe.createElement(
- 'td',
- { className: 'header-col' },
- w,
- ' ',
- x
- ? Pe.createElement(i, {
- propKey: 'Example',
- propVal: x,
- propClass: 'header-example'
- })
- : null
- )
- );
- })
- .toArray()
- )
- )
- )
- : null;
- }
- }
- class Errors extends Pe.Component {
- render() {
- let {
- editorActions: s,
- errSelectors: o,
- layoutSelectors: i,
- layoutActions: u,
- getComponent: _
- } = this.props;
- const w = _('Collapse');
- if (s && s.jumpToLine) var x = s.jumpToLine;
- let C = o
- .allErrors()
- .filter((s) => 'thrown' === s.get('type') || 'error' === s.get('level'));
- if (!C || C.count() < 1) return null;
- let j = i.isShown(['errorPane'], !0),
- L = C.sortBy((s) => s.get('line'));
- return Pe.createElement(
- 'pre',
- { className: 'errors-wrapper' },
- Pe.createElement(
- 'hgroup',
- { className: 'error' },
- Pe.createElement('h4', { className: 'errors__title' }, 'Errors'),
- Pe.createElement(
- 'button',
- { className: 'btn errors__clear-btn', onClick: () => u.show(['errorPane'], !j) },
- j ? 'Hide' : 'Show'
- )
- ),
- Pe.createElement(
- w,
- { isOpened: j, animated: !0 },
- Pe.createElement(
- 'div',
- { className: 'errors' },
- L.map((s, o) => {
- let i = s.get('type');
- return 'thrown' === i || 'auth' === i
- ? Pe.createElement(ThrownErrorItem, {
- key: o,
- error: s.get('error') || s,
- jumpToLine: x
- })
- : 'spec' === i
- ? Pe.createElement(SpecErrorItem, { key: o, error: s, jumpToLine: x })
- : void 0;
- })
- )
- )
- );
- }
- }
- const ThrownErrorItem = ({ error: s, jumpToLine: o }) => {
- if (!s) return null;
- let i = s.get('line');
- return Pe.createElement(
- 'div',
- { className: 'error-wrapper' },
- s
- ? Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'h4',
- null,
- s.get('source') && s.get('level')
- ? toTitleCase(s.get('source')) + ' ' + s.get('level')
- : '',
- s.get('path') ? Pe.createElement('small', null, ' at ', s.get('path')) : null
- ),
- Pe.createElement('span', { className: 'message thrown' }, s.get('message')),
- Pe.createElement(
- 'div',
- { className: 'error-line' },
- i && o
- ? Pe.createElement('a', { onClick: o.bind(null, i) }, 'Jump to line ', i)
- : null
- )
- )
- : null
- );
- },
- SpecErrorItem = ({ error: s, jumpToLine: o = null }) => {
- let i = null;
- return (
- s.get('path')
- ? (i = qe.List.isList(s.get('path'))
- ? Pe.createElement('small', null, 'at ', s.get('path').join('.'))
- : Pe.createElement('small', null, 'at ', s.get('path')))
- : s.get('line') &&
- !o &&
- (i = Pe.createElement('small', null, 'on line ', s.get('line'))),
- Pe.createElement(
- 'div',
- { className: 'error-wrapper' },
- s
- ? Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'h4',
- null,
- toTitleCase(s.get('source')) + ' ' + s.get('level'),
- ' ',
- i
- ),
- Pe.createElement('span', { className: 'message' }, s.get('message')),
- Pe.createElement(
- 'div',
- { className: 'error-line' },
- o
- ? Pe.createElement(
- 'a',
- { onClick: o.bind(null, s.get('line')) },
- 'Jump to line ',
- s.get('line')
- )
- : null
- )
- )
- : null
- )
- );
- };
- function toTitleCase(s) {
- return (s || '')
- .split(' ')
- .map((s) => s[0].toUpperCase() + s.slice(1))
- .join(' ');
- }
- const content_type_noop = () => {};
- class ContentType extends Pe.Component {
- static defaultProps = {
- onChange: content_type_noop,
- value: null,
- contentTypes: (0, qe.fromJS)(['application/json'])
- };
- componentDidMount() {
- this.props.contentTypes && this.props.onChange(this.props.contentTypes.first());
- }
- UNSAFE_componentWillReceiveProps(s) {
- s.contentTypes &&
- s.contentTypes.size &&
- (s.contentTypes.includes(s.value) || s.onChange(s.contentTypes.first()));
- }
- onChangeWrapper = (s) => this.props.onChange(s.target.value);
- render() {
- let {
- ariaControls: s,
- ariaLabel: o,
- className: i,
- contentTypes: u,
- controlId: _,
- value: w
- } = this.props;
- return u && u.size
- ? Pe.createElement(
- 'div',
- { className: 'content-type-wrapper ' + (i || '') },
- Pe.createElement(
- 'select',
- {
- 'aria-controls': s,
- 'aria-label': o,
- className: 'content-type',
- id: _,
- onChange: this.onChangeWrapper,
- value: w || ''
- },
- u.map((s) => Pe.createElement('option', { key: s, value: s }, s)).toArray()
- )
- )
- : null;
- }
- }
- function xclass(...s) {
- return s
- .filter((s) => !!s)
- .join(' ')
- .trim();
- }
- class Container extends Pe.Component {
- render() {
- let { fullscreen: s, full: o, ...i } = this.props;
- if (s) return Pe.createElement('section', i);
- let u = 'swagger-container' + (o ? '-full' : '');
- return Pe.createElement('section', Rn()({}, i, { className: xclass(i.className, u) }));
- }
- }
- const Bk = { mobile: '', tablet: '-tablet', desktop: '-desktop', large: '-hd' };
- class Col extends Pe.Component {
- render() {
- const {
- hide: s,
- keepContents: o,
- mobile: i,
- tablet: u,
- desktop: _,
- large: w,
- ...x
- } = this.props;
- if (s && !o) return Pe.createElement('span', null);
- let C = [];
- for (let s in Bk) {
- if (!Object.prototype.hasOwnProperty.call(Bk, s)) continue;
- let o = Bk[s];
- if (s in this.props) {
- let i = this.props[s];
- if (i < 1) {
- C.push('none' + o);
- continue;
- }
- C.push('block' + o), C.push('col-' + i + o);
- }
- }
- s && C.push('hidden');
- let j = xclass(x.className, ...C);
- return Pe.createElement('section', Rn()({}, x, { className: j }));
- }
- }
- class Row extends Pe.Component {
- render() {
- return Pe.createElement(
- 'div',
- Rn()({}, this.props, { className: xclass(this.props.className, 'wrapper') })
- );
- }
- }
- class Button extends Pe.Component {
- static defaultProps = { className: '' };
- render() {
- return Pe.createElement(
- 'button',
- Rn()({}, this.props, { className: xclass(this.props.className, 'button') })
- );
- }
- }
- const TextArea = (s) => Pe.createElement('textarea', s),
- Input = (s) => Pe.createElement('input', s);
- class Select extends Pe.Component {
- static defaultProps = { multiple: !1, allowEmptyValue: !0 };
- constructor(s, o) {
- let i;
- super(s, o),
- (i = s.value ? s.value : s.multiple ? [''] : ''),
- (this.state = { value: i });
- }
- onChange = (s) => {
- let o,
- { onChange: i, multiple: u } = this.props,
- _ = [].slice.call(s.target.options);
- (o = u
- ? _.filter(function (s) {
- return s.selected;
- }).map(function (s) {
- return s.value;
- })
- : s.target.value),
- this.setState({ value: o }),
- i && i(o);
- };
- UNSAFE_componentWillReceiveProps(s) {
- s.value !== this.props.value && this.setState({ value: s.value });
- }
- render() {
- let { allowedValues: s, multiple: o, allowEmptyValue: i, disabled: u } = this.props,
- _ = this.state.value?.toJS?.() || this.state.value;
- return Pe.createElement(
- 'select',
- {
- className: this.props.className,
- multiple: o,
- value: _,
- onChange: this.onChange,
- disabled: u
- },
- i ? Pe.createElement('option', { value: '' }, '--') : null,
- s.map(function (s, o) {
- return Pe.createElement('option', { key: o, value: String(s) }, String(s));
- })
- );
- }
- }
- class layout_utils_Link extends Pe.Component {
- render() {
- return Pe.createElement(
- 'a',
- Rn()({}, this.props, {
- rel: 'noopener noreferrer',
- className: xclass(this.props.className, 'link')
- })
- );
- }
- }
- const NoMargin = ({ children: s }) =>
- Pe.createElement('div', { className: 'no-margin' }, ' ', s, ' ');
- class Collapse extends Pe.Component {
- static defaultProps = { isOpened: !1, animated: !1 };
- renderNotAnimated() {
- return this.props.isOpened
- ? Pe.createElement(NoMargin, null, this.props.children)
- : Pe.createElement('noscript', null);
- }
- render() {
- let { animated: s, isOpened: o, children: i } = this.props;
- return s
- ? ((i = o ? i : null), Pe.createElement(NoMargin, null, i))
- : this.renderNotAnimated();
- }
- }
- class Overview extends Pe.Component {
- constructor(...s) {
- super(...s), (this.setTagShown = this._setTagShown.bind(this));
- }
- _setTagShown(s, o) {
- this.props.layoutActions.show(s, o);
- }
- showOp(s, o) {
- let { layoutActions: i } = this.props;
- i.show(s, o);
- }
- render() {
- let {
- specSelectors: s,
- layoutSelectors: o,
- layoutActions: i,
- getComponent: u
- } = this.props,
- _ = s.taggedOperations();
- const w = u('Collapse');
- return Pe.createElement(
- 'div',
- null,
- Pe.createElement('h4', { className: 'overview-title' }, 'Overview'),
- _.map((s, u) => {
- let _ = s.get('operations'),
- x = ['overview-tags', u],
- C = o.isShown(x, !0);
- return Pe.createElement(
- 'div',
- { key: 'overview-' + u },
- Pe.createElement(
- 'h4',
- { onClick: () => i.show(x, !C), className: 'link overview-tag' },
- ' ',
- C ? '-' : '+',
- u
- ),
- Pe.createElement(
- w,
- { isOpened: C, animated: !0 },
- _.map((s) => {
- let { path: u, method: _, id: w } = s.toObject(),
- x = 'operations',
- C = w,
- j = o.isShown([x, C]);
- return Pe.createElement(OperationLink, {
- key: w,
- path: u,
- method: _,
- id: u + '-' + _,
- shown: j,
- showOpId: C,
- showOpIdPrefix: x,
- href: `#operation-${C}`,
- onClick: i.show
- });
- }).toArray()
- )
- );
- }).toArray(),
- _.size < 1 && Pe.createElement('h3', null, ' No operations defined in spec! ')
- );
- }
- }
- class OperationLink extends Pe.Component {
- constructor(s) {
- super(s), (this.onClick = this._onClick.bind(this));
- }
- _onClick() {
- let { showOpId: s, showOpIdPrefix: o, onClick: i, shown: u } = this.props;
- i([o, s], !u);
- }
- render() {
- let { id: s, method: o, shown: i, href: u } = this.props;
- return Pe.createElement(
- layout_utils_Link,
- {
- href: u,
- onClick: this.onClick,
- className: 'block opblock-link ' + (i ? 'shown' : '')
- },
- Pe.createElement(
- 'div',
- null,
- Pe.createElement('small', { className: `bold-label-${o}` }, o.toUpperCase()),
- Pe.createElement('span', { className: 'bold-label' }, s)
- )
- );
- }
- }
- class InitializedInput extends Pe.Component {
- componentDidMount() {
- this.props.initialValue && (this.inputRef.value = this.props.initialValue);
- }
- render() {
- const { value: s, defaultValue: o, initialValue: i, ...u } = this.props;
- return Pe.createElement('input', Rn()({}, u, { ref: (s) => (this.inputRef = s) }));
- }
- }
- class InfoBasePath extends Pe.Component {
- render() {
- const { host: s, basePath: o } = this.props;
- return Pe.createElement('pre', { className: 'base-url' }, '[ Base URL: ', s, o, ' ]');
- }
- }
- class InfoUrl extends Pe.PureComponent {
- render() {
- const { url: s, getComponent: o } = this.props,
- i = o('Link');
- return Pe.createElement(
- i,
- { target: '_blank', href: sanitizeUrl(s) },
- Pe.createElement('span', { className: 'url' }, ' ', s)
- );
- }
- }
- class info_Info extends Pe.Component {
- render() {
- const {
- info: s,
- url: o,
- host: i,
- basePath: u,
- getComponent: _,
- externalDocs: w,
- selectedServer: x,
- url: C
- } = this.props,
- j = s.get('version'),
- L = s.get('description'),
- B = s.get('title'),
- $ = safeBuildUrl(s.get('termsOfService'), C, { selectedServer: x }),
- V = s.get('contact'),
- U = s.get('license'),
- z = safeBuildUrl(w && w.get('url'), C, { selectedServer: x }),
- Y = w && w.get('description'),
- Z = _('Markdown', !0),
- ee = _('Link'),
- ie = _('VersionStamp'),
- ae = _('OpenAPIVersion'),
- le = _('InfoUrl'),
- ce = _('InfoBasePath'),
- pe = _('License'),
- de = _('Contact');
- return Pe.createElement(
- 'div',
- { className: 'info' },
- Pe.createElement(
- 'hgroup',
- { className: 'main' },
- Pe.createElement(
- 'h2',
- { className: 'title' },
- B,
- Pe.createElement(
- 'span',
- null,
- j && Pe.createElement(ie, { version: j }),
- Pe.createElement(ae, { oasVersion: '2.0' })
- )
- ),
- i || u ? Pe.createElement(ce, { host: i, basePath: u }) : null,
- o && Pe.createElement(le, { getComponent: _, url: o })
- ),
- Pe.createElement(
- 'div',
- { className: 'description' },
- Pe.createElement(Z, { source: L })
- ),
- $ &&
- Pe.createElement(
- 'div',
- { className: 'info__tos' },
- Pe.createElement(
- ee,
- { target: '_blank', href: sanitizeUrl($) },
- 'Terms of service'
- )
- ),
- V?.size > 0 &&
- Pe.createElement(de, { getComponent: _, data: V, selectedServer: x, url: o }),
- U?.size > 0 &&
- Pe.createElement(pe, { getComponent: _, license: U, selectedServer: x, url: o }),
- z
- ? Pe.createElement(
- ee,
- { className: 'info__extdocs', target: '_blank', href: sanitizeUrl(z) },
- Y || z
- )
- : null
- );
- }
- }
- const qk = info_Info;
- class InfoContainer extends Pe.Component {
- render() {
- const { specSelectors: s, getComponent: o, oas3Selectors: i } = this.props,
- u = s.info(),
- _ = s.url(),
- w = s.basePath(),
- x = s.host(),
- C = s.externalDocs(),
- j = i.selectedServer(),
- L = o('info');
- return Pe.createElement(
- 'div',
- null,
- u && u.count()
- ? Pe.createElement(L, {
- info: u,
- url: _,
- host: x,
- basePath: w,
- externalDocs: C,
- getComponent: o,
- selectedServer: j
- })
- : null
- );
- }
- }
- class contact_Contact extends Pe.Component {
- render() {
- const { data: s, getComponent: o, selectedServer: i, url: u } = this.props,
- _ = s.get('name', 'the developer'),
- w = safeBuildUrl(s.get('url'), u, { selectedServer: i }),
- x = s.get('email'),
- C = o('Link');
- return Pe.createElement(
- 'div',
- { className: 'info__contact' },
- w &&
- Pe.createElement(
- 'div',
- null,
- Pe.createElement(C, { href: sanitizeUrl(w), target: '_blank' }, _, ' - Website')
- ),
- x &&
- Pe.createElement(
- C,
- { href: sanitizeUrl(`mailto:${x}`) },
- w ? `Send email to ${_}` : `Contact ${_}`
- )
- );
- }
- }
- const Vk = contact_Contact;
- class license_License extends Pe.Component {
- render() {
- const { license: s, getComponent: o, selectedServer: i, url: u } = this.props,
- _ = s.get('name', 'License'),
- w = safeBuildUrl(s.get('url'), u, { selectedServer: i }),
- x = o('Link');
- return Pe.createElement(
- 'div',
- { className: 'info__license' },
- w
- ? Pe.createElement(
- 'div',
- { className: 'info__license__url' },
- Pe.createElement(x, { target: '_blank', href: sanitizeUrl(w) }, _)
- )
- : Pe.createElement('span', null, _)
- );
- }
- }
- const zk = license_License;
- class JumpToPath extends Pe.Component {
- render() {
- return null;
- }
- }
- class CopyToClipboardBtn extends Pe.Component {
- render() {
- let { getComponent: s } = this.props;
- const o = s('CopyIcon');
- return Pe.createElement(
- 'div',
- { className: 'view-line-link copy-to-clipboard', title: 'Copy to clipboard' },
- Pe.createElement(
- Jn.CopyToClipboard,
- { text: this.props.textToCopy },
- Pe.createElement(o, null)
- )
- );
- }
- }
- class Footer extends Pe.Component {
- render() {
- return Pe.createElement('div', { className: 'footer' });
- }
- }
- class FilterContainer extends Pe.Component {
- onFilterChange = (s) => {
- const {
- target: { value: o }
- } = s;
- this.props.layoutActions.updateFilter(o);
- };
- render() {
- const { specSelectors: s, layoutSelectors: o, getComponent: i } = this.props,
- u = i('Col'),
- _ = 'loading' === s.loadingStatus(),
- w = 'failed' === s.loadingStatus(),
- x = o.currentFilter(),
- C = ['operation-filter-input'];
- return (
- w && C.push('failed'),
- _ && C.push('loading'),
- Pe.createElement(
- 'div',
- null,
- !1 === x
- ? null
- : Pe.createElement(
- 'div',
- { className: 'filter-container' },
- Pe.createElement(
- u,
- { className: 'filter wrapper', mobile: 12 },
- Pe.createElement('input', {
- className: C.join(' '),
- placeholder: 'Filter by tag',
- type: 'text',
- onChange: this.onFilterChange,
- value: 'string' == typeof x ? x : '',
- disabled: _
- })
- )
- )
- )
- );
- }
- }
- const eC = Function.prototype;
- class ParamBody extends Pe.PureComponent {
- static defaultProp = {
- consumes: (0, qe.fromJS)(['application/json']),
- param: (0, qe.fromJS)({}),
- onChange: eC,
- onChangeConsumes: eC
- };
- constructor(s, o) {
- super(s, o), (this.state = { isEditBox: !1, value: '' });
- }
- componentDidMount() {
- this.updateValues.call(this, this.props);
- }
- UNSAFE_componentWillReceiveProps(s) {
- this.updateValues.call(this, s);
- }
- updateValues = (s) => {
- let { param: o, isExecute: i, consumesValue: u = '' } = s,
- _ = /xml/i.test(u),
- w = /json/i.test(u),
- x = _ ? o.get('value_xml') : o.get('value');
- if (void 0 !== x) {
- let s = !x && w ? '{}' : x;
- this.setState({ value: s }), this.onChange(s, { isXml: _, isEditBox: i });
- } else
- _
- ? this.onChange(this.sample('xml'), { isXml: _, isEditBox: i })
- : this.onChange(this.sample(), { isEditBox: i });
- };
- sample = (s) => {
- let { param: o, fn: i } = this.props,
- u = i.inferSchema(o.toJS());
- return i.getSampleSchema(u, s, { includeWriteOnly: !0 });
- };
- onChange = (s, { isEditBox: o, isXml: i }) => {
- this.setState({ value: s, isEditBox: o }), this._onChange(s, i);
- };
- _onChange = (s, o) => {
- (this.props.onChange || eC)(s, o);
- };
- handleOnChange = (s) => {
- const { consumesValue: o } = this.props,
- i = /xml/i.test(o),
- u = s.target.value;
- this.onChange(u, { isXml: i, isEditBox: this.state.isEditBox });
- };
- toggleIsEditBox = () => this.setState((s) => ({ isEditBox: !s.isEditBox }));
- render() {
- let {
- onChangeConsumes: s,
- param: o,
- isExecute: i,
- specSelectors: u,
- pathMethod: _,
- getComponent: w
- } = this.props;
- const x = w('Button'),
- C = w('TextArea'),
- j = w('HighlightCode', !0),
- L = w('contentType');
- let B = (u ? u.parameterWithMetaByIdentity(_, o) : o).get('errors', (0, qe.List)()),
- $ = u.contentTypeValues(_).get('requestContentType'),
- V =
- this.props.consumes && this.props.consumes.size
- ? this.props.consumes
- : ParamBody.defaultProp.consumes,
- { value: U, isEditBox: z } = this.state,
- Y = null;
- getKnownSyntaxHighlighterLanguage(U) && (Y = 'json');
- const Z = `${createHtmlReadyId(`${_[1]}${_[0]}_parameters`)}_select`;
- return Pe.createElement(
- 'div',
- {
- className: 'body-param',
- 'data-param-name': o.get('name'),
- 'data-param-in': o.get('in')
- },
- z && i
- ? Pe.createElement(C, {
- className: 'body-param__text' + (B.count() ? ' invalid' : ''),
- value: U,
- onChange: this.handleOnChange
- })
- : U && Pe.createElement(j, { className: 'body-param__example', language: Y }, U),
- Pe.createElement(
- 'div',
- { className: 'body-param-options' },
- i
- ? Pe.createElement(
- 'div',
- { className: 'body-param-edit' },
- Pe.createElement(
- x,
- {
- className: z
- ? 'btn cancel body-param__example-edit'
- : 'btn edit body-param__example-edit',
- onClick: this.toggleIsEditBox
- },
- z ? 'Cancel' : 'Edit'
- )
- )
- : null,
- Pe.createElement(
- 'label',
- { htmlFor: Z },
- Pe.createElement('span', null, 'Parameter content type'),
- Pe.createElement(L, {
- value: $,
- contentTypes: V,
- onChange: s,
- className: 'body-param-content-type',
- ariaLabel: 'Parameter content type',
- controlId: Z
- })
- )
- )
- );
- }
- }
- class Curl extends Pe.Component {
- render() {
- const { request: s, getComponent: o } = this.props,
- i = requestSnippetGenerator_curl_bash(s),
- u = o('SyntaxHighlighter', !0);
- return Pe.createElement(
- 'div',
- { className: 'curl-command' },
- Pe.createElement('h4', null, 'Curl'),
- Pe.createElement(
- 'div',
- { className: 'copy-to-clipboard' },
- Pe.createElement(Jn.CopyToClipboard, { text: i }, Pe.createElement('button', null))
- ),
- Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- u,
- {
- language: 'bash',
- className: 'curl microlight',
- renderPlainText: ({ children: s, PlainTextViewer: o }) =>
- Pe.createElement(o, { className: 'curl' }, s)
- },
- i
- )
- )
- );
- }
- }
- const property = ({ propKey: s, propVal: o, propClass: i }) =>
- Pe.createElement(
- 'span',
- { className: i },
- Pe.createElement('br', null),
- s,
- ': ',
- String(o)
- );
- class TryItOutButton extends Pe.Component {
- static defaultProps = {
- onTryoutClick: Function.prototype,
- onCancelClick: Function.prototype,
- onResetClick: Function.prototype,
- enabled: !1,
- hasUserEditedBody: !1,
- isOAS3: !1
- };
- render() {
- const {
- onTryoutClick: s,
- onCancelClick: o,
- onResetClick: i,
- enabled: u,
- hasUserEditedBody: _,
- isOAS3: w
- } = this.props,
- x = w && _;
- return Pe.createElement(
- 'div',
- { className: x ? 'try-out btn-group' : 'try-out' },
- u
- ? Pe.createElement(
- 'button',
- { className: 'btn try-out__btn cancel', onClick: o },
- 'Cancel'
- )
- : Pe.createElement(
- 'button',
- { className: 'btn try-out__btn', onClick: s },
- 'Try it out '
- ),
- x &&
- Pe.createElement(
- 'button',
- { className: 'btn try-out__btn reset', onClick: i },
- 'Reset'
- )
- );
- }
- }
- class VersionPragmaFilter extends Pe.PureComponent {
- static defaultProps = { alsoShow: null, children: null, bypass: !1 };
- render() {
- const { bypass: s, isSwagger2: o, isOAS3: i, alsoShow: u } = this.props;
- return s
- ? Pe.createElement('div', null, this.props.children)
- : o && i
- ? Pe.createElement(
- 'div',
- { className: 'version-pragma' },
- u,
- Pe.createElement(
- 'div',
- { className: 'version-pragma__message version-pragma__message--ambiguous' },
- Pe.createElement(
- 'div',
- null,
- Pe.createElement('h3', null, 'Unable to render this definition'),
- Pe.createElement(
- 'p',
- null,
- Pe.createElement('code', null, 'swagger'),
- ' and ',
- Pe.createElement('code', null, 'openapi'),
- ' fields cannot be present in the same Swagger or OpenAPI definition. Please remove one of the fields.'
- ),
- Pe.createElement(
- 'p',
- null,
- 'Supported version fields are ',
- Pe.createElement('code', null, 'swagger: ', '"2.0"'),
- ' and those that match ',
- Pe.createElement('code', null, 'openapi: 3.0.n'),
- ' (for example, ',
- Pe.createElement('code', null, 'openapi: 3.0.0'),
- ').'
- )
- )
- )
- )
- : o || i
- ? Pe.createElement('div', null, this.props.children)
- : Pe.createElement(
- 'div',
- { className: 'version-pragma' },
- u,
- Pe.createElement(
- 'div',
- { className: 'version-pragma__message version-pragma__message--missing' },
- Pe.createElement(
- 'div',
- null,
- Pe.createElement('h3', null, 'Unable to render this definition'),
- Pe.createElement(
- 'p',
- null,
- 'The provided definition does not specify a valid version field.'
- ),
- Pe.createElement(
- 'p',
- null,
- 'Please indicate a valid Swagger or OpenAPI version field. Supported version fields are ',
- Pe.createElement('code', null, 'swagger: ', '"2.0"'),
- ' and those that match ',
- Pe.createElement('code', null, 'openapi: 3.0.n'),
- ' (for example, ',
- Pe.createElement('code', null, 'openapi: 3.0.0'),
- ').'
- )
- )
- )
- );
- }
- }
- const version_stamp = ({ version: s }) =>
- Pe.createElement(
- 'small',
- null,
- Pe.createElement('pre', { className: 'version' }, ' ', s, ' ')
- ),
- openapi_version = ({ oasVersion: s }) =>
- Pe.createElement(
- 'small',
- { className: 'version-stamp' },
- Pe.createElement('pre', { className: 'version' }, 'OAS ', s)
- ),
- deep_link = ({ enabled: s, path: o, text: i }) =>
- Pe.createElement(
- 'a',
- {
- className: 'nostyle',
- onClick: s ? (s) => s.preventDefault() : null,
- href: s ? `#/${o}` : null
- },
- Pe.createElement('span', null, i)
- ),
- svg_assets = () =>
- Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'svg',
- {
- xmlns: 'http://www.w3.org/2000/svg',
- xmlnsXlink: 'http://www.w3.org/1999/xlink',
- className: 'svg-assets'
- },
- Pe.createElement(
- 'defs',
- null,
- Pe.createElement(
- 'symbol',
- { viewBox: '0 0 20 20', id: 'unlocked' },
- Pe.createElement('path', {
- d: 'M15.8 8H14V5.6C14 2.703 12.665 1 10 1 7.334 1 6 2.703 6 5.6V6h2v-.801C8 3.754 8.797 3 10 3c1.203 0 2 .754 2 2.199V8H4c-.553 0-1 .646-1 1.199V17c0 .549.428 1.139.951 1.307l1.197.387C5.672 18.861 6.55 19 7.1 19h5.8c.549 0 1.428-.139 1.951-.307l1.196-.387c.524-.167.953-.757.953-1.306V9.199C17 8.646 16.352 8 15.8 8z'
- })
- ),
- Pe.createElement(
- 'symbol',
- { viewBox: '0 0 20 20', id: 'locked' },
- Pe.createElement('path', {
- d: 'M15.8 8H14V5.6C14 2.703 12.665 1 10 1 7.334 1 6 2.703 6 5.6V8H4c-.553 0-1 .646-1 1.199V17c0 .549.428 1.139.951 1.307l1.197.387C5.672 18.861 6.55 19 7.1 19h5.8c.549 0 1.428-.139 1.951-.307l1.196-.387c.524-.167.953-.757.953-1.306V9.199C17 8.646 16.352 8 15.8 8zM12 8H8V5.199C8 3.754 8.797 3 10 3c1.203 0 2 .754 2 2.199V8z'
- })
- ),
- Pe.createElement(
- 'symbol',
- { viewBox: '0 0 20 20', id: 'close' },
- Pe.createElement('path', {
- d: 'M14.348 14.849c-.469.469-1.229.469-1.697 0L10 11.819l-2.651 3.029c-.469.469-1.229.469-1.697 0-.469-.469-.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-.469-.469-.469-1.228 0-1.697.469-.469 1.228-.469 1.697 0L10 8.183l2.651-3.031c.469-.469 1.228-.469 1.697 0 .469.469.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c.469.469.469 1.229 0 1.698z'
- })
- ),
- Pe.createElement(
- 'symbol',
- { viewBox: '0 0 20 20', id: 'large-arrow' },
- Pe.createElement('path', {
- d: 'M13.25 10L6.109 2.58c-.268-.27-.268-.707 0-.979.268-.27.701-.27.969 0l7.83 7.908c.268.271.268.709 0 .979l-7.83 7.908c-.268.271-.701.27-.969 0-.268-.269-.268-.707 0-.979L13.25 10z'
- })
- ),
- Pe.createElement(
- 'symbol',
- { viewBox: '0 0 20 20', id: 'large-arrow-down' },
- Pe.createElement('path', {
- d: 'M17.418 6.109c.272-.268.709-.268.979 0s.271.701 0 .969l-7.908 7.83c-.27.268-.707.268-.979 0l-7.908-7.83c-.27-.268-.27-.701 0-.969.271-.268.709-.268.979 0L10 13.25l7.418-7.141z'
- })
- ),
- Pe.createElement(
- 'symbol',
- { viewBox: '0 0 20 20', id: 'large-arrow-up' },
- Pe.createElement('path', {
- d: 'M 17.418 14.908 C 17.69 15.176 18.127 15.176 18.397 14.908 C 18.667 14.64 18.668 14.207 18.397 13.939 L 10.489 6.109 C 10.219 5.841 9.782 5.841 9.51 6.109 L 1.602 13.939 C 1.332 14.207 1.332 14.64 1.602 14.908 C 1.873 15.176 2.311 15.176 2.581 14.908 L 10 7.767 L 17.418 14.908 Z'
- })
- ),
- Pe.createElement(
- 'symbol',
- { viewBox: '0 0 24 24', id: 'jump-to' },
- Pe.createElement('path', {
- d: 'M19 7v4H5.83l3.58-3.59L8 6l-6 6 6 6 1.41-1.41L5.83 13H21V7z'
- })
- ),
- Pe.createElement(
- 'symbol',
- { viewBox: '0 0 24 24', id: 'expand' },
- Pe.createElement('path', {
- d: 'M10 18h4v-2h-4v2zM3 6v2h18V6H3zm3 7h12v-2H6v2z'
- })
- ),
- Pe.createElement(
- 'symbol',
- { viewBox: '0 0 15 16', id: 'copy' },
- Pe.createElement(
- 'g',
- { transform: 'translate(2, -1)' },
- Pe.createElement('path', {
- fill: '#ffffff',
- fillRule: 'evenodd',
- d: 'M2 13h4v1H2v-1zm5-6H2v1h5V7zm2 3V8l-3 3 3 3v-2h5v-2H9zM4.5 9H2v1h2.5V9zM2 12h2.5v-1H2v1zm9 1h1v2c-.02.28-.11.52-.3.7-.19.18-.42.28-.7.3H1c-.55 0-1-.45-1-1V4c0-.55.45-1 1-1h3c0-1.11.89-2 2-2 1.11 0 2 .89 2 2h3c.55 0 1 .45 1 1v5h-1V6H1v9h10v-2zM2 5h8c0-.55-.45-1-1-1H8c-.55 0-1-.45-1-1s-.45-1-1-1-1 .45-1 1-.45 1-1 1H3c-.55 0-1 .45-1 1z'
- })
- )
- )
- )
- )
- );
- var tC;
- function decodeEntity(s) {
- return (
- ((tC = tC || document.createElement('textarea')).innerHTML = '&' + s + ';'), tC.value
- );
- }
- var rC = Object.prototype.hasOwnProperty;
- function index_browser_has(s, o) {
- return !!s && rC.call(s, o);
- }
- function index_browser_assign(s) {
- return (
- [].slice.call(arguments, 1).forEach(function (o) {
- if (o) {
- if ('object' != typeof o) throw new TypeError(o + 'must be object');
- Object.keys(o).forEach(function (i) {
- s[i] = o[i];
- });
- }
- }),
- s
- );
- }
- var nC = /\\([\\!"#$%&'()*+,.\/:;<=>?@[\]^_`{|}~-])/g;
- function unescapeMd(s) {
- return s.indexOf('\\') < 0 ? s : s.replace(nC, '$1');
- }
- function isValidEntityCode(s) {
- return (
- !(s >= 55296 && s <= 57343) &&
- !(s >= 64976 && s <= 65007) &&
- !!(65535 & ~s && 65534 != (65535 & s)) &&
- !(s >= 0 && s <= 8) &&
- 11 !== s &&
- !(s >= 14 && s <= 31) &&
- !(s >= 127 && s <= 159) &&
- !(s > 1114111)
- );
- }
- function fromCodePoint(s) {
- if (s > 65535) {
- var o = 55296 + ((s -= 65536) >> 10),
- i = 56320 + (1023 & s);
- return String.fromCharCode(o, i);
- }
- return String.fromCharCode(s);
- }
- var sC = /&([a-z#][a-z0-9]{1,31});/gi,
- oC = /^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))/i;
- function replaceEntityPattern(s, o) {
- var i = 0,
- u = decodeEntity(o);
- return o !== u
- ? u
- : 35 === o.charCodeAt(0) &&
- oC.test(o) &&
- isValidEntityCode(
- (i =
- 'x' === o[1].toLowerCase()
- ? parseInt(o.slice(2), 16)
- : parseInt(o.slice(1), 10))
- )
- ? fromCodePoint(i)
- : s;
- }
- function replaceEntities(s) {
- return s.indexOf('&') < 0 ? s : s.replace(sC, replaceEntityPattern);
- }
- var iC = /[&<>"]/,
- aC = /[&<>"]/g,
- lC = { '&': '&', '<': '<', '>': '>', '"': '"' };
- function replaceUnsafeChar(s) {
- return lC[s];
- }
- function escapeHtml(s) {
- return iC.test(s) ? s.replace(aC, replaceUnsafeChar) : s;
- }
- var cC = {};
- function nextToken(s, o) {
- return ++o >= s.length - 2
- ? o
- : 'paragraph_open' === s[o].type &&
- s[o].tight &&
- 'inline' === s[o + 1].type &&
- 0 === s[o + 1].content.length &&
- 'paragraph_close' === s[o + 2].type &&
- s[o + 2].tight
- ? nextToken(s, o + 2)
- : o;
- }
- (cC.blockquote_open = function () {
- return '<blockquote>\n';
- }),
- (cC.blockquote_close = function (s, o) {
- return '</blockquote>' + uC(s, o);
- }),
- (cC.code = function (s, o) {
- return s[o].block
- ? '<pre><code>' + escapeHtml(s[o].content) + '</code></pre>' + uC(s, o)
- : '<code>' + escapeHtml(s[o].content) + '</code>';
- }),
- (cC.fence = function (s, o, i, u, _) {
- var w,
- x,
- C = s[o],
- j = '',
- L = i.langPrefix;
- if (C.params) {
- if (
- ((x = (w = C.params.split(/\s+/g)).join(' ')),
- index_browser_has(_.rules.fence_custom, w[0]))
- )
- return _.rules.fence_custom[w[0]](s, o, i, u, _);
- j = ' class="' + L + escapeHtml(replaceEntities(unescapeMd(x))) + '"';
- }
- return (
- '<pre><code' +
- j +
- '>' +
- ((i.highlight && i.highlight.apply(i.highlight, [C.content].concat(w))) ||
- escapeHtml(C.content)) +
- '</code></pre>' +
- uC(s, o)
- );
- }),
- (cC.fence_custom = {}),
- (cC.heading_open = function (s, o) {
- return '<h' + s[o].hLevel + '>';
- }),
- (cC.heading_close = function (s, o) {
- return '</h' + s[o].hLevel + '>\n';
- }),
- (cC.hr = function (s, o, i) {
- return (i.xhtmlOut ? '<hr />' : '<hr>') + uC(s, o);
- }),
- (cC.bullet_list_open = function () {
- return '<ul>\n';
- }),
- (cC.bullet_list_close = function (s, o) {
- return '</ul>' + uC(s, o);
- }),
- (cC.list_item_open = function () {
- return '<li>';
- }),
- (cC.list_item_close = function () {
- return '</li>\n';
- }),
- (cC.ordered_list_open = function (s, o) {
- var i = s[o];
- return '<ol' + (i.order > 1 ? ' start="' + i.order + '"' : '') + '>\n';
- }),
- (cC.ordered_list_close = function (s, o) {
- return '</ol>' + uC(s, o);
- }),
- (cC.paragraph_open = function (s, o) {
- return s[o].tight ? '' : '<p>';
- }),
- (cC.paragraph_close = function (s, o) {
- var i = !(s[o].tight && o && 'inline' === s[o - 1].type && !s[o - 1].content);
- return (s[o].tight ? '' : '</p>') + (i ? uC(s, o) : '');
- }),
- (cC.link_open = function (s, o, i) {
- var u = s[o].title ? ' title="' + escapeHtml(replaceEntities(s[o].title)) + '"' : '',
- _ = i.linkTarget ? ' target="' + i.linkTarget + '"' : '';
- return '<a href="' + escapeHtml(s[o].href) + '"' + u + _ + '>';
- }),
- (cC.link_close = function () {
- return '</a>';
- }),
- (cC.image = function (s, o, i) {
- var u = ' src="' + escapeHtml(s[o].src) + '"',
- _ = s[o].title ? ' title="' + escapeHtml(replaceEntities(s[o].title)) + '"' : '';
- return (
- '<img' +
- u +
- (' alt="' +
- (s[o].alt ? escapeHtml(replaceEntities(unescapeMd(s[o].alt))) : '') +
- '"') +
- _ +
- (i.xhtmlOut ? ' /' : '') +
- '>'
- );
- }),
- (cC.table_open = function () {
- return '<table>\n';
- }),
- (cC.table_close = function () {
- return '</table>\n';
- }),
- (cC.thead_open = function () {
- return '<thead>\n';
- }),
- (cC.thead_close = function () {
- return '</thead>\n';
- }),
- (cC.tbody_open = function () {
- return '<tbody>\n';
- }),
- (cC.tbody_close = function () {
- return '</tbody>\n';
- }),
- (cC.tr_open = function () {
- return '<tr>';
- }),
- (cC.tr_close = function () {
- return '</tr>\n';
- }),
- (cC.th_open = function (s, o) {
- var i = s[o];
- return '<th' + (i.align ? ' style="text-align:' + i.align + '"' : '') + '>';
- }),
- (cC.th_close = function () {
- return '</th>';
- }),
- (cC.td_open = function (s, o) {
- var i = s[o];
- return '<td' + (i.align ? ' style="text-align:' + i.align + '"' : '') + '>';
- }),
- (cC.td_close = function () {
- return '</td>';
- }),
- (cC.strong_open = function () {
- return '<strong>';
- }),
- (cC.strong_close = function () {
- return '</strong>';
- }),
- (cC.em_open = function () {
- return '<em>';
- }),
- (cC.em_close = function () {
- return '</em>';
- }),
- (cC.del_open = function () {
- return '<del>';
- }),
- (cC.del_close = function () {
- return '</del>';
- }),
- (cC.ins_open = function () {
- return '<ins>';
- }),
- (cC.ins_close = function () {
- return '</ins>';
- }),
- (cC.mark_open = function () {
- return '<mark>';
- }),
- (cC.mark_close = function () {
- return '</mark>';
- }),
- (cC.sub = function (s, o) {
- return '<sub>' + escapeHtml(s[o].content) + '</sub>';
- }),
- (cC.sup = function (s, o) {
- return '<sup>' + escapeHtml(s[o].content) + '</sup>';
- }),
- (cC.hardbreak = function (s, o, i) {
- return i.xhtmlOut ? '<br />\n' : '<br>\n';
- }),
- (cC.softbreak = function (s, o, i) {
- return i.breaks ? (i.xhtmlOut ? '<br />\n' : '<br>\n') : '\n';
- }),
- (cC.text = function (s, o) {
- return escapeHtml(s[o].content);
- }),
- (cC.htmlblock = function (s, o) {
- return s[o].content;
- }),
- (cC.htmltag = function (s, o) {
- return s[o].content;
- }),
- (cC.abbr_open = function (s, o) {
- return '<abbr title="' + escapeHtml(replaceEntities(s[o].title)) + '">';
- }),
- (cC.abbr_close = function () {
- return '</abbr>';
- }),
- (cC.footnote_ref = function (s, o) {
- var i = Number(s[o].id + 1).toString(),
- u = 'fnref' + i;
- return (
- s[o].subId > 0 && (u += ':' + s[o].subId),
- '<sup class="footnote-ref"><a href="#fn' +
- i +
- '" id="' +
- u +
- '">[' +
- i +
- ']</a></sup>'
- );
- }),
- (cC.footnote_block_open = function (s, o, i) {
- return (
- (i.xhtmlOut ? '<hr class="footnotes-sep" />\n' : '<hr class="footnotes-sep">\n') +
- '<section class="footnotes">\n<ol class="footnotes-list">\n'
- );
- }),
- (cC.footnote_block_close = function () {
- return '</ol>\n</section>\n';
- }),
- (cC.footnote_open = function (s, o) {
- return '<li id="fn' + Number(s[o].id + 1).toString() + '" class="footnote-item">';
- }),
- (cC.footnote_close = function () {
- return '</li>\n';
- }),
- (cC.footnote_anchor = function (s, o) {
- var i = 'fnref' + Number(s[o].id + 1).toString();
- return (
- s[o].subId > 0 && (i += ':' + s[o].subId),
- ' <a href="#' + i + '" class="footnote-backref">↩</a>'
- );
- }),
- (cC.dl_open = function () {
- return '<dl>\n';
- }),
- (cC.dt_open = function () {
- return '<dt>';
- }),
- (cC.dd_open = function () {
- return '<dd>';
- }),
- (cC.dl_close = function () {
- return '</dl>\n';
- }),
- (cC.dt_close = function () {
- return '</dt>\n';
- }),
- (cC.dd_close = function () {
- return '</dd>\n';
- });
- var uC = (cC.getBreak = function getBreak(s, o) {
- return (o = nextToken(s, o)) < s.length && 'list_item_close' === s[o].type ? '' : '\n';
- });
- function Renderer() {
- (this.rules = index_browser_assign({}, cC)), (this.getBreak = cC.getBreak);
- }
- function Ruler() {
- (this.__rules__ = []), (this.__cache__ = null);
- }
- function StateInline(s, o, i, u, _) {
- (this.src = s),
- (this.env = u),
- (this.options = i),
- (this.parser = o),
- (this.tokens = _),
- (this.pos = 0),
- (this.posMax = this.src.length),
- (this.level = 0),
- (this.pending = ''),
- (this.pendingLevel = 0),
- (this.cache = []),
- (this.isInLabel = !1),
- (this.linkLevel = 0),
- (this.linkContent = ''),
- (this.labelUnmatchedScopes = 0);
- }
- function parseLinkLabel(s, o) {
- var i,
- u,
- _,
- w = -1,
- x = s.posMax,
- C = s.pos,
- j = s.isInLabel;
- if (s.isInLabel) return -1;
- if (s.labelUnmatchedScopes) return s.labelUnmatchedScopes--, -1;
- for (s.pos = o + 1, s.isInLabel = !0, i = 1; s.pos < x; ) {
- if (91 === (_ = s.src.charCodeAt(s.pos))) i++;
- else if (93 === _ && 0 === --i) {
- u = !0;
- break;
- }
- s.parser.skipToken(s);
- }
- return (
- u ? ((w = s.pos), (s.labelUnmatchedScopes = 0)) : (s.labelUnmatchedScopes = i - 1),
- (s.pos = C),
- (s.isInLabel = j),
- w
- );
- }
- function parseAbbr(s, o, i, u) {
- var _, w, x, C, j, L;
- if (42 !== s.charCodeAt(0)) return -1;
- if (91 !== s.charCodeAt(1)) return -1;
- if (-1 === s.indexOf(']:')) return -1;
- if (
- (w = parseLinkLabel((_ = new StateInline(s, o, i, u, [])), 1)) < 0 ||
- 58 !== s.charCodeAt(w + 1)
- )
- return -1;
- for (C = _.posMax, x = w + 2; x < C && 10 !== _.src.charCodeAt(x); x++);
- return (
- (j = s.slice(2, w)),
- 0 === (L = s.slice(w + 2, x).trim()).length
- ? -1
- : (u.abbreviations || (u.abbreviations = {}),
- void 0 === u.abbreviations[':' + j] && (u.abbreviations[':' + j] = L),
- x)
- );
- }
- function normalizeLink(s) {
- var o = replaceEntities(s);
- try {
- o = decodeURI(o);
- } catch (s) {}
- return encodeURI(o);
- }
- function parseLinkDestination(s, o) {
- var i,
- u,
- _,
- w = o,
- x = s.posMax;
- if (60 === s.src.charCodeAt(o)) {
- for (o++; o < x; ) {
- if (10 === (i = s.src.charCodeAt(o))) return !1;
- if (62 === i)
- return (
- (_ = normalizeLink(unescapeMd(s.src.slice(w + 1, o)))),
- !!s.parser.validateLink(_) && ((s.pos = o + 1), (s.linkContent = _), !0)
- );
- 92 === i && o + 1 < x ? (o += 2) : o++;
- }
- return !1;
- }
- for (u = 0; o < x && 32 !== (i = s.src.charCodeAt(o)) && !(i < 32 || 127 === i); )
- if (92 === i && o + 1 < x) o += 2;
- else {
- if (40 === i && ++u > 1) break;
- if (41 === i && --u < 0) break;
- o++;
- }
- return (
- w !== o &&
- ((_ = unescapeMd(s.src.slice(w, o))),
- !!s.parser.validateLink(_) && ((s.linkContent = _), (s.pos = o), !0))
- );
- }
- function parseLinkTitle(s, o) {
- var i,
- u = o,
- _ = s.posMax,
- w = s.src.charCodeAt(o);
- if (34 !== w && 39 !== w && 40 !== w) return !1;
- for (o++, 40 === w && (w = 41); o < _; ) {
- if ((i = s.src.charCodeAt(o)) === w)
- return (s.pos = o + 1), (s.linkContent = unescapeMd(s.src.slice(u + 1, o))), !0;
- 92 === i && o + 1 < _ ? (o += 2) : o++;
- }
- return !1;
- }
- function normalizeReference(s) {
- return s.trim().replace(/\s+/g, ' ').toUpperCase();
- }
- function parseReference(s, o, i, u) {
- var _, w, x, C, j, L, B, $, V;
- if (91 !== s.charCodeAt(0)) return -1;
- if (-1 === s.indexOf(']:')) return -1;
- if (
- (w = parseLinkLabel((_ = new StateInline(s, o, i, u, [])), 0)) < 0 ||
- 58 !== s.charCodeAt(w + 1)
- )
- return -1;
- for (
- C = _.posMax, x = w + 2;
- x < C && (32 === (j = _.src.charCodeAt(x)) || 10 === j);
- x++
- );
- if (!parseLinkDestination(_, x)) return -1;
- for (
- B = _.linkContent, L = x = _.pos, x += 1;
- x < C && (32 === (j = _.src.charCodeAt(x)) || 10 === j);
- x++
- );
- for (
- x < C && L !== x && parseLinkTitle(_, x)
- ? (($ = _.linkContent), (x = _.pos))
- : (($ = ''), (x = L));
- x < C && 32 === _.src.charCodeAt(x);
- )
- x++;
- return x < C && 10 !== _.src.charCodeAt(x)
- ? -1
- : ((V = normalizeReference(s.slice(1, w))),
- void 0 === u.references[V] && (u.references[V] = { title: $, href: B }),
- x);
- }
- (Renderer.prototype.renderInline = function (s, o, i) {
- for (var u = this.rules, _ = s.length, w = 0, x = ''; _--; )
- x += u[s[w].type](s, w++, o, i, this);
- return x;
- }),
- (Renderer.prototype.render = function (s, o, i) {
- for (var u = this.rules, _ = s.length, w = -1, x = ''; ++w < _; )
- 'inline' === s[w].type
- ? (x += this.renderInline(s[w].children, o, i))
- : (x += u[s[w].type](s, w, o, i, this));
- return x;
- }),
- (Ruler.prototype.__find__ = function (s) {
- for (var o = this.__rules__.length, i = -1; o--; )
- if (this.__rules__[++i].name === s) return i;
- return -1;
- }),
- (Ruler.prototype.__compile__ = function () {
- var s = this,
- o = [''];
- s.__rules__.forEach(function (s) {
- s.enabled &&
- s.alt.forEach(function (s) {
- o.indexOf(s) < 0 && o.push(s);
- });
- }),
- (s.__cache__ = {}),
- o.forEach(function (o) {
- (s.__cache__[o] = []),
- s.__rules__.forEach(function (i) {
- i.enabled && ((o && i.alt.indexOf(o) < 0) || s.__cache__[o].push(i.fn));
- });
- });
- }),
- (Ruler.prototype.at = function (s, o, i) {
- var u = this.__find__(s),
- _ = i || {};
- if (-1 === u) throw new Error('Parser rule not found: ' + s);
- (this.__rules__[u].fn = o),
- (this.__rules__[u].alt = _.alt || []),
- (this.__cache__ = null);
- }),
- (Ruler.prototype.before = function (s, o, i, u) {
- var _ = this.__find__(s),
- w = u || {};
- if (-1 === _) throw new Error('Parser rule not found: ' + s);
- this.__rules__.splice(_, 0, { name: o, enabled: !0, fn: i, alt: w.alt || [] }),
- (this.__cache__ = null);
- }),
- (Ruler.prototype.after = function (s, o, i, u) {
- var _ = this.__find__(s),
- w = u || {};
- if (-1 === _) throw new Error('Parser rule not found: ' + s);
- this.__rules__.splice(_ + 1, 0, { name: o, enabled: !0, fn: i, alt: w.alt || [] }),
- (this.__cache__ = null);
- }),
- (Ruler.prototype.push = function (s, o, i) {
- var u = i || {};
- this.__rules__.push({ name: s, enabled: !0, fn: o, alt: u.alt || [] }),
- (this.__cache__ = null);
- }),
- (Ruler.prototype.enable = function (s, o) {
- (s = Array.isArray(s) ? s : [s]),
- o &&
- this.__rules__.forEach(function (s) {
- s.enabled = !1;
- }),
- s.forEach(function (s) {
- var o = this.__find__(s);
- if (o < 0) throw new Error('Rules manager: invalid rule name ' + s);
- this.__rules__[o].enabled = !0;
- }, this),
- (this.__cache__ = null);
- }),
- (Ruler.prototype.disable = function (s) {
- (s = Array.isArray(s) ? s : [s]).forEach(function (s) {
- var o = this.__find__(s);
- if (o < 0) throw new Error('Rules manager: invalid rule name ' + s);
- this.__rules__[o].enabled = !1;
- }, this),
- (this.__cache__ = null);
- }),
- (Ruler.prototype.getRules = function (s) {
- return null === this.__cache__ && this.__compile__(), this.__cache__[s] || [];
- }),
- (StateInline.prototype.pushPending = function () {
- this.tokens.push({ type: 'text', content: this.pending, level: this.pendingLevel }),
- (this.pending = '');
- }),
- (StateInline.prototype.push = function (s) {
- this.pending && this.pushPending(),
- this.tokens.push(s),
- (this.pendingLevel = this.level);
- }),
- (StateInline.prototype.cacheSet = function (s, o) {
- for (var i = this.cache.length; i <= s; i++) this.cache.push(0);
- this.cache[s] = o;
- }),
- (StateInline.prototype.cacheGet = function (s) {
- return s < this.cache.length ? this.cache[s] : 0;
- });
- var pC = ' \n()[]\'".,!?-';
- function regEscape(s) {
- return s.replace(/([-()\[\]{}+?*.$\^|,:#<!\\])/g, '\\$1');
- }
- var hC = /\+-|\.\.|\?\?\?\?|!!!!|,,|--/,
- dC = /\((c|tm|r|p)\)/gi,
- fC = { c: '©', r: '®', p: '§', tm: '™' };
- function replaceScopedAbbr(s) {
- return s.indexOf('(') < 0
- ? s
- : s.replace(dC, function (s, o) {
- return fC[o.toLowerCase()];
- });
- }
- var mC = /['"]/,
- gC = /['"]/g,
- yC = /[-\s()\[\]]/;
- function isLetter(s, o) {
- return !(o < 0 || o >= s.length) && !yC.test(s[o]);
- }
- function replaceAt(s, o, i) {
- return s.substr(0, o) + i + s.substr(o + 1);
- }
- var vC = [
- [
- 'block',
- function block(s) {
- s.inlineMode
- ? s.tokens.push({
- type: 'inline',
- content: s.src.replace(/\n/g, ' ').trim(),
- level: 0,
- lines: [0, 1],
- children: []
- })
- : s.block.parse(s.src, s.options, s.env, s.tokens);
- }
- ],
- [
- 'abbr',
- function abbr(s) {
- var o,
- i,
- u,
- _,
- w = s.tokens;
- if (!s.inlineMode)
- for (o = 1, i = w.length - 1; o < i; o++)
- if (
- 'paragraph_open' === w[o - 1].type &&
- 'inline' === w[o].type &&
- 'paragraph_close' === w[o + 1].type
- ) {
- for (
- u = w[o].content;
- u.length && !((_ = parseAbbr(u, s.inline, s.options, s.env)) < 0);
- )
- u = u.slice(_).trim();
- (w[o].content = u), u.length || ((w[o - 1].tight = !0), (w[o + 1].tight = !0));
- }
- }
- ],
- [
- 'references',
- function references(s) {
- var o,
- i,
- u,
- _,
- w = s.tokens;
- if (((s.env.references = s.env.references || {}), !s.inlineMode))
- for (o = 1, i = w.length - 1; o < i; o++)
- if (
- 'inline' === w[o].type &&
- 'paragraph_open' === w[o - 1].type &&
- 'paragraph_close' === w[o + 1].type
- ) {
- for (
- u = w[o].content;
- u.length && !((_ = parseReference(u, s.inline, s.options, s.env)) < 0);
- )
- u = u.slice(_).trim();
- (w[o].content = u), u.length || ((w[o - 1].tight = !0), (w[o + 1].tight = !0));
- }
- }
- ],
- [
- 'inline',
- function inline(s) {
- var o,
- i,
- u,
- _ = s.tokens;
- for (i = 0, u = _.length; i < u; i++)
- 'inline' === (o = _[i]).type &&
- s.inline.parse(o.content, s.options, s.env, o.children);
- }
- ],
- [
- 'footnote_tail',
- function footnote_block(s) {
- var o,
- i,
- u,
- _,
- w,
- x,
- C,
- j,
- L,
- B = 0,
- $ = !1,
- V = {};
- if (
- s.env.footnotes &&
- ((s.tokens = s.tokens.filter(function (s) {
- return 'footnote_reference_open' === s.type
- ? (($ = !0), (j = []), (L = s.label), !1)
- : 'footnote_reference_close' === s.type
- ? (($ = !1), (V[':' + L] = j), !1)
- : ($ && j.push(s), !$);
- })),
- s.env.footnotes.list)
- ) {
- for (
- x = s.env.footnotes.list,
- s.tokens.push({ type: 'footnote_block_open', level: B++ }),
- o = 0,
- i = x.length;
- o < i;
- o++
- ) {
- for (
- s.tokens.push({ type: 'footnote_open', id: o, level: B++ }),
- x[o].tokens
- ? ((C = []).push({ type: 'paragraph_open', tight: !1, level: B++ }),
- C.push({ type: 'inline', content: '', level: B, children: x[o].tokens }),
- C.push({ type: 'paragraph_close', tight: !1, level: --B }))
- : x[o].label && (C = V[':' + x[o].label]),
- s.tokens = s.tokens.concat(C),
- w =
- 'paragraph_close' === s.tokens[s.tokens.length - 1].type
- ? s.tokens.pop()
- : null,
- _ = x[o].count > 0 ? x[o].count : 1,
- u = 0;
- u < _;
- u++
- )
- s.tokens.push({ type: 'footnote_anchor', id: o, subId: u, level: B });
- w && s.tokens.push(w), s.tokens.push({ type: 'footnote_close', level: --B });
- }
- s.tokens.push({ type: 'footnote_block_close', level: --B });
- }
- }
- ],
- [
- 'abbr2',
- function abbr2(s) {
- var o,
- i,
- u,
- _,
- w,
- x,
- C,
- j,
- L,
- B,
- $,
- V,
- U = s.tokens;
- if (s.env.abbreviations)
- for (
- s.env.abbrRegExp ||
- ((V =
- '(^|[' +
- pC.split('').map(regEscape).join('') +
- '])(' +
- Object.keys(s.env.abbreviations)
- .map(function (s) {
- return s.substr(1);
- })
- .sort(function (s, o) {
- return o.length - s.length;
- })
- .map(regEscape)
- .join('|') +
- ')($|[' +
- pC.split('').map(regEscape).join('') +
- '])'),
- (s.env.abbrRegExp = new RegExp(V, 'g'))),
- B = s.env.abbrRegExp,
- i = 0,
- u = U.length;
- i < u;
- i++
- )
- if ('inline' === U[i].type)
- for (o = (_ = U[i].children).length - 1; o >= 0; o--)
- if ('text' === (w = _[o]).type) {
- for (
- j = 0, x = w.content, B.lastIndex = 0, L = w.level, C = [];
- ($ = B.exec(x));
- )
- B.lastIndex > j &&
- C.push({
- type: 'text',
- content: x.slice(j, $.index + $[1].length),
- level: L
- }),
- C.push({
- type: 'abbr_open',
- title: s.env.abbreviations[':' + $[2]],
- level: L++
- }),
- C.push({ type: 'text', content: $[2], level: L }),
- C.push({ type: 'abbr_close', level: --L }),
- (j = B.lastIndex - $[3].length);
- C.length &&
- (j < x.length && C.push({ type: 'text', content: x.slice(j), level: L }),
- (U[i].children = _ = [].concat(_.slice(0, o), C, _.slice(o + 1))));
- }
- }
- ],
- [
- 'replacements',
- function index_browser_replace(s) {
- var o, i, u, _, w;
- if (s.options.typographer)
- for (w = s.tokens.length - 1; w >= 0; w--)
- if ('inline' === s.tokens[w].type)
- for (o = (_ = s.tokens[w].children).length - 1; o >= 0; o--)
- 'text' === (i = _[o]).type &&
- ((u = replaceScopedAbbr((u = i.content))),
- hC.test(u) &&
- (u = u
- .replace(/\+-/g, '±')
- .replace(/\.{2,}/g, '…')
- .replace(/([?!])…/g, '$1..')
- .replace(/([?!]){4,}/g, '$1$1$1')
- .replace(/,{2,}/g, ',')
- .replace(/(^|[^-])---([^-]|$)/gm, '$1—$2')
- .replace(/(^|\s)--(\s|$)/gm, '$1–$2')
- .replace(/(^|[^-\s])--([^-\s]|$)/gm, '$1–$2')),
- (i.content = u));
- }
- ],
- [
- 'smartquotes',
- function smartquotes(s) {
- var o, i, u, _, w, x, C, j, L, B, $, V, U, z, Y, Z, ee;
- if (s.options.typographer)
- for (ee = [], Y = s.tokens.length - 1; Y >= 0; Y--)
- if ('inline' === s.tokens[Y].type)
- for (Z = s.tokens[Y].children, ee.length = 0, o = 0; o < Z.length; o++)
- if ('text' === (i = Z[o]).type && !mC.test(i.text)) {
- for (C = Z[o].level, U = ee.length - 1; U >= 0 && !(ee[U].level <= C); U--);
- (ee.length = U + 1), (w = 0), (x = (u = i.content).length);
- e: for (; w < x && ((gC.lastIndex = w), (_ = gC.exec(u))); )
- if (
- ((j = !isLetter(u, _.index - 1)),
- (w = _.index + 1),
- (z = "'" === _[0]),
- (L = !isLetter(u, w)) || j)
- ) {
- if ((($ = !L), (V = !j)))
- for (
- U = ee.length - 1;
- U >= 0 && ((B = ee[U]), !(ee[U].level < C));
- U--
- )
- if (B.single === z && ee[U].level === C) {
- (B = ee[U]),
- z
- ? ((Z[B.token].content = replaceAt(
- Z[B.token].content,
- B.pos,
- s.options.quotes[2]
- )),
- (i.content = replaceAt(
- i.content,
- _.index,
- s.options.quotes[3]
- )))
- : ((Z[B.token].content = replaceAt(
- Z[B.token].content,
- B.pos,
- s.options.quotes[0]
- )),
- (i.content = replaceAt(
- i.content,
- _.index,
- s.options.quotes[1]
- ))),
- (ee.length = U);
- continue e;
- }
- $
- ? ee.push({ token: o, pos: _.index, single: z, level: C })
- : V && z && (i.content = replaceAt(i.content, _.index, '’'));
- } else z && (i.content = replaceAt(i.content, _.index, '’'));
- }
- }
- ]
- ];
- function Core() {
- (this.options = {}), (this.ruler = new Ruler());
- for (var s = 0; s < vC.length; s++) this.ruler.push(vC[s][0], vC[s][1]);
- }
- function StateBlock(s, o, i, u, _) {
- var w, x, C, j, L, B, $;
- for (
- this.src = s,
- this.parser = o,
- this.options = i,
- this.env = u,
- this.tokens = _,
- this.bMarks = [],
- this.eMarks = [],
- this.tShift = [],
- this.blkIndent = 0,
- this.line = 0,
- this.lineMax = 0,
- this.tight = !1,
- this.parentType = 'root',
- this.ddIndent = -1,
- this.level = 0,
- this.result = '',
- B = 0,
- $ = !1,
- C = j = B = 0,
- L = (x = this.src).length;
- j < L;
- j++
- ) {
- if (((w = x.charCodeAt(j)), !$)) {
- if (32 === w) {
- B++;
- continue;
- }
- $ = !0;
- }
- (10 !== w && j !== L - 1) ||
- (10 !== w && j++,
- this.bMarks.push(C),
- this.eMarks.push(j),
- this.tShift.push(B),
- ($ = !1),
- (B = 0),
- (C = j + 1));
- }
- this.bMarks.push(x.length),
- this.eMarks.push(x.length),
- this.tShift.push(0),
- (this.lineMax = this.bMarks.length - 1);
- }
- function skipBulletListMarker(s, o) {
- var i, u, _;
- return (u = s.bMarks[o] + s.tShift[o]) >= (_ = s.eMarks[o]) ||
- (42 !== (i = s.src.charCodeAt(u++)) && 45 !== i && 43 !== i) ||
- (u < _ && 32 !== s.src.charCodeAt(u))
- ? -1
- : u;
- }
- function skipOrderedListMarker(s, o) {
- var i,
- u = s.bMarks[o] + s.tShift[o],
- _ = s.eMarks[o];
- if (u + 1 >= _) return -1;
- if ((i = s.src.charCodeAt(u++)) < 48 || i > 57) return -1;
- for (;;) {
- if (u >= _) return -1;
- if (!((i = s.src.charCodeAt(u++)) >= 48 && i <= 57)) {
- if (41 === i || 46 === i) break;
- return -1;
- }
- }
- return u < _ && 32 !== s.src.charCodeAt(u) ? -1 : u;
- }
- (Core.prototype.process = function (s) {
- var o, i, u;
- for (o = 0, i = (u = this.ruler.getRules('')).length; o < i; o++) u[o](s);
- }),
- (StateBlock.prototype.isEmpty = function isEmpty(s) {
- return this.bMarks[s] + this.tShift[s] >= this.eMarks[s];
- }),
- (StateBlock.prototype.skipEmptyLines = function skipEmptyLines(s) {
- for (
- var o = this.lineMax;
- s < o && !(this.bMarks[s] + this.tShift[s] < this.eMarks[s]);
- s++
- );
- return s;
- }),
- (StateBlock.prototype.skipSpaces = function skipSpaces(s) {
- for (var o = this.src.length; s < o && 32 === this.src.charCodeAt(s); s++);
- return s;
- }),
- (StateBlock.prototype.skipChars = function skipChars(s, o) {
- for (var i = this.src.length; s < i && this.src.charCodeAt(s) === o; s++);
- return s;
- }),
- (StateBlock.prototype.skipCharsBack = function skipCharsBack(s, o, i) {
- if (s <= i) return s;
- for (; s > i; ) if (o !== this.src.charCodeAt(--s)) return s + 1;
- return s;
- }),
- (StateBlock.prototype.getLines = function getLines(s, o, i, u) {
- var _,
- w,
- x,
- C,
- j,
- L = s;
- if (s >= o) return '';
- if (L + 1 === o)
- return (
- (w = this.bMarks[L] + Math.min(this.tShift[L], i)),
- (x = u ? this.eMarks[L] + 1 : this.eMarks[L]),
- this.src.slice(w, x)
- );
- for (C = new Array(o - s), _ = 0; L < o; L++, _++)
- (j = this.tShift[L]) > i && (j = i),
- j < 0 && (j = 0),
- (w = this.bMarks[L] + j),
- (x = L + 1 < o || u ? this.eMarks[L] + 1 : this.eMarks[L]),
- (C[_] = this.src.slice(w, x));
- return C.join('');
- });
- var bC = {};
- [
- 'article',
- 'aside',
- 'button',
- 'blockquote',
- 'body',
- 'canvas',
- 'caption',
- 'col',
- 'colgroup',
- 'dd',
- 'div',
- 'dl',
- 'dt',
- 'embed',
- 'fieldset',
- 'figcaption',
- 'figure',
- 'footer',
- 'form',
- 'h1',
- 'h2',
- 'h3',
- 'h4',
- 'h5',
- 'h6',
- 'header',
- 'hgroup',
- 'hr',
- 'iframe',
- 'li',
- 'map',
- 'object',
- 'ol',
- 'output',
- 'p',
- 'pre',
- 'progress',
- 'script',
- 'section',
- 'style',
- 'table',
- 'tbody',
- 'td',
- 'textarea',
- 'tfoot',
- 'th',
- 'tr',
- 'thead',
- 'ul',
- 'video'
- ].forEach(function (s) {
- bC[s] = !0;
- });
- var _C = /^<([a-zA-Z]{1,15})[\s\/>]/,
- EC = /^<\/([a-zA-Z]{1,15})[\s>]/;
- function index_browser_getLine(s, o) {
- var i = s.bMarks[o] + s.blkIndent,
- u = s.eMarks[o];
- return s.src.substr(i, u - i);
- }
- function skipMarker(s, o) {
- var i,
- u,
- _ = s.bMarks[o] + s.tShift[o],
- w = s.eMarks[o];
- return _ >= w ||
- (126 !== (u = s.src.charCodeAt(_++)) && 58 !== u) ||
- _ === (i = s.skipSpaces(_)) ||
- i >= w
- ? -1
- : i;
- }
- var wC = [
- [
- 'code',
- function code(s, o, i) {
- var u, _;
- if (s.tShift[o] - s.blkIndent < 4) return !1;
- for (_ = u = o + 1; u < i; )
- if (s.isEmpty(u)) u++;
- else {
- if (!(s.tShift[u] - s.blkIndent >= 4)) break;
- _ = ++u;
- }
- return (
- (s.line = u),
- s.tokens.push({
- type: 'code',
- content: s.getLines(o, _, 4 + s.blkIndent, !0),
- block: !0,
- lines: [o, s.line],
- level: s.level
- }),
- !0
- );
- }
- ],
- [
- 'fences',
- function fences(s, o, i, u) {
- var _,
- w,
- x,
- C,
- j,
- L = !1,
- B = s.bMarks[o] + s.tShift[o],
- $ = s.eMarks[o];
- if (B + 3 > $) return !1;
- if (126 !== (_ = s.src.charCodeAt(B)) && 96 !== _) return !1;
- if (((j = B), (w = (B = s.skipChars(B, _)) - j) < 3)) return !1;
- if ((x = s.src.slice(B, $).trim()).indexOf('`') >= 0) return !1;
- if (u) return !0;
- for (
- C = o;
- !(++C >= i) &&
- !(
- (B = j = s.bMarks[C] + s.tShift[C]) < ($ = s.eMarks[C]) &&
- s.tShift[C] < s.blkIndent
- );
- )
- if (
- s.src.charCodeAt(B) === _ &&
- !(
- s.tShift[C] - s.blkIndent >= 4 ||
- (B = s.skipChars(B, _)) - j < w ||
- (B = s.skipSpaces(B)) < $
- )
- ) {
- L = !0;
- break;
- }
- return (
- (w = s.tShift[o]),
- (s.line = C + (L ? 1 : 0)),
- s.tokens.push({
- type: 'fence',
- params: x,
- content: s.getLines(o + 1, C, w, !0),
- lines: [o, s.line],
- level: s.level
- }),
- !0
- );
- },
- ['paragraph', 'blockquote', 'list']
- ],
- [
- 'blockquote',
- function blockquote(s, o, i, u) {
- var _,
- w,
- x,
- C,
- j,
- L,
- B,
- $,
- V,
- U,
- z,
- Y = s.bMarks[o] + s.tShift[o],
- Z = s.eMarks[o];
- if (Y > Z) return !1;
- if (62 !== s.src.charCodeAt(Y++)) return !1;
- if (s.level >= s.options.maxNesting) return !1;
- if (u) return !0;
- for (
- 32 === s.src.charCodeAt(Y) && Y++,
- j = s.blkIndent,
- s.blkIndent = 0,
- C = [s.bMarks[o]],
- s.bMarks[o] = Y,
- w = (Y = Y < Z ? s.skipSpaces(Y) : Y) >= Z,
- x = [s.tShift[o]],
- s.tShift[o] = Y - s.bMarks[o],
- $ = s.parser.ruler.getRules('blockquote'),
- _ = o + 1;
- _ < i && !((Y = s.bMarks[_] + s.tShift[_]) >= (Z = s.eMarks[_]));
- _++
- )
- if (62 !== s.src.charCodeAt(Y++)) {
- if (w) break;
- for (z = !1, V = 0, U = $.length; V < U; V++)
- if ($[V](s, _, i, !0)) {
- z = !0;
- break;
- }
- if (z) break;
- C.push(s.bMarks[_]), x.push(s.tShift[_]), (s.tShift[_] = -1337);
- } else
- 32 === s.src.charCodeAt(Y) && Y++,
- C.push(s.bMarks[_]),
- (s.bMarks[_] = Y),
- (w = (Y = Y < Z ? s.skipSpaces(Y) : Y) >= Z),
- x.push(s.tShift[_]),
- (s.tShift[_] = Y - s.bMarks[_]);
- for (
- L = s.parentType,
- s.parentType = 'blockquote',
- s.tokens.push({ type: 'blockquote_open', lines: (B = [o, 0]), level: s.level++ }),
- s.parser.tokenize(s, o, _),
- s.tokens.push({ type: 'blockquote_close', level: --s.level }),
- s.parentType = L,
- B[1] = s.line,
- V = 0;
- V < x.length;
- V++
- )
- (s.bMarks[V + o] = C[V]), (s.tShift[V + o] = x[V]);
- return (s.blkIndent = j), !0;
- },
- ['paragraph', 'blockquote', 'list']
- ],
- [
- 'hr',
- function hr(s, o, i, u) {
- var _,
- w,
- x,
- C = s.bMarks[o],
- j = s.eMarks[o];
- if ((C += s.tShift[o]) > j) return !1;
- if (42 !== (_ = s.src.charCodeAt(C++)) && 45 !== _ && 95 !== _) return !1;
- for (w = 1; C < j; ) {
- if ((x = s.src.charCodeAt(C++)) !== _ && 32 !== x) return !1;
- x === _ && w++;
- }
- return (
- !(w < 3) &&
- (u ||
- ((s.line = o + 1),
- s.tokens.push({ type: 'hr', lines: [o, s.line], level: s.level })),
- !0)
- );
- },
- ['paragraph', 'blockquote', 'list']
- ],
- [
- 'list',
- function index_browser_list(s, o, i, u) {
- var _,
- w,
- x,
- C,
- j,
- L,
- B,
- $,
- V,
- U,
- z,
- Y,
- Z,
- ee,
- ie,
- ae,
- le,
- ce,
- pe,
- de,
- fe,
- ye = !0;
- if (($ = skipOrderedListMarker(s, o)) >= 0) Y = !0;
- else {
- if (!(($ = skipBulletListMarker(s, o)) >= 0)) return !1;
- Y = !1;
- }
- if (s.level >= s.options.maxNesting) return !1;
- if (((z = s.src.charCodeAt($ - 1)), u)) return !0;
- for (
- ee = s.tokens.length,
- Y
- ? ((B = s.bMarks[o] + s.tShift[o]),
- (U = Number(s.src.substr(B, $ - B - 1))),
- s.tokens.push({
- type: 'ordered_list_open',
- order: U,
- lines: (ae = [o, 0]),
- level: s.level++
- }))
- : s.tokens.push({
- type: 'bullet_list_open',
- lines: (ae = [o, 0]),
- level: s.level++
- }),
- _ = o,
- ie = !1,
- ce = s.parser.ruler.getRules('list');
- !(
- !(_ < i) ||
- ((V = (Z = s.skipSpaces($)) >= s.eMarks[_] ? 1 : Z - $) > 4 && (V = 1),
- V < 1 && (V = 1),
- (w = $ - s.bMarks[_] + V),
- s.tokens.push({ type: 'list_item_open', lines: (le = [o, 0]), level: s.level++ }),
- (C = s.blkIndent),
- (j = s.tight),
- (x = s.tShift[o]),
- (L = s.parentType),
- (s.tShift[o] = Z - s.bMarks[o]),
- (s.blkIndent = w),
- (s.tight = !0),
- (s.parentType = 'list'),
- s.parser.tokenize(s, o, i, !0),
- (s.tight && !ie) || (ye = !1),
- (ie = s.line - o > 1 && s.isEmpty(s.line - 1)),
- (s.blkIndent = C),
- (s.tShift[o] = x),
- (s.tight = j),
- (s.parentType = L),
- s.tokens.push({ type: 'list_item_close', level: --s.level }),
- (_ = o = s.line),
- (le[1] = _),
- (Z = s.bMarks[o]),
- _ >= i) ||
- s.isEmpty(_) ||
- s.tShift[_] < s.blkIndent
- );
- ) {
- for (fe = !1, pe = 0, de = ce.length; pe < de; pe++)
- if (ce[pe](s, _, i, !0)) {
- fe = !0;
- break;
- }
- if (fe) break;
- if (Y) {
- if (($ = skipOrderedListMarker(s, _)) < 0) break;
- } else if (($ = skipBulletListMarker(s, _)) < 0) break;
- if (z !== s.src.charCodeAt($ - 1)) break;
- }
- return (
- s.tokens.push({
- type: Y ? 'ordered_list_close' : 'bullet_list_close',
- level: --s.level
- }),
- (ae[1] = _),
- (s.line = _),
- ye &&
- (function markTightParagraphs(s, o) {
- var i,
- u,
- _ = s.level + 2;
- for (i = o + 2, u = s.tokens.length - 2; i < u; i++)
- s.tokens[i].level === _ &&
- 'paragraph_open' === s.tokens[i].type &&
- ((s.tokens[i + 2].tight = !0), (s.tokens[i].tight = !0), (i += 2));
- })(s, ee),
- !0
- );
- },
- ['paragraph', 'blockquote']
- ],
- [
- 'footnote',
- function footnote(s, o, i, u) {
- var _,
- w,
- x,
- C,
- j,
- L = s.bMarks[o] + s.tShift[o],
- B = s.eMarks[o];
- if (L + 4 > B) return !1;
- if (91 !== s.src.charCodeAt(L)) return !1;
- if (94 !== s.src.charCodeAt(L + 1)) return !1;
- if (s.level >= s.options.maxNesting) return !1;
- for (C = L + 2; C < B; C++) {
- if (32 === s.src.charCodeAt(C)) return !1;
- if (93 === s.src.charCodeAt(C)) break;
- }
- return (
- C !== L + 2 &&
- !(C + 1 >= B || 58 !== s.src.charCodeAt(++C)) &&
- (u ||
- (C++,
- s.env.footnotes || (s.env.footnotes = {}),
- s.env.footnotes.refs || (s.env.footnotes.refs = {}),
- (j = s.src.slice(L + 2, C - 2)),
- (s.env.footnotes.refs[':' + j] = -1),
- s.tokens.push({ type: 'footnote_reference_open', label: j, level: s.level++ }),
- (_ = s.bMarks[o]),
- (w = s.tShift[o]),
- (x = s.parentType),
- (s.tShift[o] = s.skipSpaces(C) - C),
- (s.bMarks[o] = C),
- (s.blkIndent += 4),
- (s.parentType = 'footnote'),
- s.tShift[o] < s.blkIndent &&
- ((s.tShift[o] += s.blkIndent), (s.bMarks[o] -= s.blkIndent)),
- s.parser.tokenize(s, o, i, !0),
- (s.parentType = x),
- (s.blkIndent -= 4),
- (s.tShift[o] = w),
- (s.bMarks[o] = _),
- s.tokens.push({ type: 'footnote_reference_close', level: --s.level })),
- !0)
- );
- },
- ['paragraph']
- ],
- [
- 'heading',
- function heading(s, o, i, u) {
- var _,
- w,
- x,
- C = s.bMarks[o] + s.tShift[o],
- j = s.eMarks[o];
- if (C >= j) return !1;
- if (35 !== (_ = s.src.charCodeAt(C)) || C >= j) return !1;
- for (w = 1, _ = s.src.charCodeAt(++C); 35 === _ && C < j && w <= 6; )
- w++, (_ = s.src.charCodeAt(++C));
- return (
- !(w > 6 || (C < j && 32 !== _)) &&
- (u ||
- ((j = s.skipCharsBack(j, 32, C)),
- (x = s.skipCharsBack(j, 35, C)) > C && 32 === s.src.charCodeAt(x - 1) && (j = x),
- (s.line = o + 1),
- s.tokens.push({
- type: 'heading_open',
- hLevel: w,
- lines: [o, s.line],
- level: s.level
- }),
- C < j &&
- s.tokens.push({
- type: 'inline',
- content: s.src.slice(C, j).trim(),
- level: s.level + 1,
- lines: [o, s.line],
- children: []
- }),
- s.tokens.push({ type: 'heading_close', hLevel: w, level: s.level })),
- !0)
- );
- },
- ['paragraph', 'blockquote']
- ],
- [
- 'lheading',
- function lheading(s, o, i) {
- var u,
- _,
- w,
- x = o + 1;
- return (
- !(x >= i) &&
- !(s.tShift[x] < s.blkIndent) &&
- !(s.tShift[x] - s.blkIndent > 3) &&
- !((_ = s.bMarks[x] + s.tShift[x]) >= (w = s.eMarks[x])) &&
- (45 === (u = s.src.charCodeAt(_)) || 61 === u) &&
- ((_ = s.skipChars(_, u)),
- !((_ = s.skipSpaces(_)) < w) &&
- ((_ = s.bMarks[o] + s.tShift[o]),
- (s.line = x + 1),
- s.tokens.push({
- type: 'heading_open',
- hLevel: 61 === u ? 1 : 2,
- lines: [o, s.line],
- level: s.level
- }),
- s.tokens.push({
- type: 'inline',
- content: s.src.slice(_, s.eMarks[o]).trim(),
- level: s.level + 1,
- lines: [o, s.line - 1],
- children: []
- }),
- s.tokens.push({
- type: 'heading_close',
- hLevel: 61 === u ? 1 : 2,
- level: s.level
- }),
- !0))
- );
- }
- ],
- [
- 'htmlblock',
- function htmlblock(s, o, i, u) {
- var _,
- w,
- x,
- C = s.bMarks[o],
- j = s.eMarks[o],
- L = s.tShift[o];
- if (((C += L), !s.options.html)) return !1;
- if (L > 3 || C + 2 >= j) return !1;
- if (60 !== s.src.charCodeAt(C)) return !1;
- if (33 === (_ = s.src.charCodeAt(C + 1)) || 63 === _) {
- if (u) return !0;
- } else {
- if (
- 47 !== _ &&
- !(function isLetter$1(s) {
- var o = 32 | s;
- return o >= 97 && o <= 122;
- })(_)
- )
- return !1;
- if (47 === _) {
- if (!(w = s.src.slice(C, j).match(EC))) return !1;
- } else if (!(w = s.src.slice(C, j).match(_C))) return !1;
- if (!0 !== bC[w[1].toLowerCase()]) return !1;
- if (u) return !0;
- }
- for (x = o + 1; x < s.lineMax && !s.isEmpty(x); ) x++;
- return (
- (s.line = x),
- s.tokens.push({
- type: 'htmlblock',
- level: s.level,
- lines: [o, s.line],
- content: s.getLines(o, x, 0, !0)
- }),
- !0
- );
- },
- ['paragraph', 'blockquote']
- ],
- [
- 'table',
- function table(s, o, i, u) {
- var _, w, x, C, j, L, B, $, V, U, z;
- if (o + 2 > i) return !1;
- if (((j = o + 1), s.tShift[j] < s.blkIndent)) return !1;
- if ((x = s.bMarks[j] + s.tShift[j]) >= s.eMarks[j]) return !1;
- if (124 !== (_ = s.src.charCodeAt(x)) && 45 !== _ && 58 !== _) return !1;
- if (((w = index_browser_getLine(s, o + 1)), !/^[-:| ]+$/.test(w))) return !1;
- if ((L = w.split('|')) <= 2) return !1;
- for ($ = [], C = 0; C < L.length; C++) {
- if (!(V = L[C].trim())) {
- if (0 === C || C === L.length - 1) continue;
- return !1;
- }
- if (!/^:?-+:?$/.test(V)) return !1;
- 58 === V.charCodeAt(V.length - 1)
- ? $.push(58 === V.charCodeAt(0) ? 'center' : 'right')
- : 58 === V.charCodeAt(0)
- ? $.push('left')
- : $.push('');
- }
- if (-1 === (w = index_browser_getLine(s, o).trim()).indexOf('|')) return !1;
- if (((L = w.replace(/^\||\|$/g, '').split('|')), $.length !== L.length)) return !1;
- if (u) return !0;
- for (
- s.tokens.push({ type: 'table_open', lines: (U = [o, 0]), level: s.level++ }),
- s.tokens.push({ type: 'thead_open', lines: [o, o + 1], level: s.level++ }),
- s.tokens.push({ type: 'tr_open', lines: [o, o + 1], level: s.level++ }),
- C = 0;
- C < L.length;
- C++
- )
- s.tokens.push({
- type: 'th_open',
- align: $[C],
- lines: [o, o + 1],
- level: s.level++
- }),
- s.tokens.push({
- type: 'inline',
- content: L[C].trim(),
- lines: [o, o + 1],
- level: s.level,
- children: []
- }),
- s.tokens.push({ type: 'th_close', level: --s.level });
- for (
- s.tokens.push({ type: 'tr_close', level: --s.level }),
- s.tokens.push({ type: 'thead_close', level: --s.level }),
- s.tokens.push({ type: 'tbody_open', lines: (z = [o + 2, 0]), level: s.level++ }),
- j = o + 2;
- j < i &&
- !(s.tShift[j] < s.blkIndent) &&
- -1 !== (w = index_browser_getLine(s, j).trim()).indexOf('|');
- j++
- ) {
- for (
- L = w.replace(/^\||\|$/g, '').split('|'),
- s.tokens.push({ type: 'tr_open', level: s.level++ }),
- C = 0;
- C < L.length;
- C++
- )
- s.tokens.push({ type: 'td_open', align: $[C], level: s.level++ }),
- (B = L[C].substring(
- 124 === L[C].charCodeAt(0) ? 1 : 0,
- 124 === L[C].charCodeAt(L[C].length - 1) ? L[C].length - 1 : L[C].length
- ).trim()),
- s.tokens.push({ type: 'inline', content: B, level: s.level, children: [] }),
- s.tokens.push({ type: 'td_close', level: --s.level });
- s.tokens.push({ type: 'tr_close', level: --s.level });
- }
- return (
- s.tokens.push({ type: 'tbody_close', level: --s.level }),
- s.tokens.push({ type: 'table_close', level: --s.level }),
- (U[1] = z[1] = j),
- (s.line = j),
- !0
- );
- },
- ['paragraph']
- ],
- [
- 'deflist',
- function deflist(s, o, i, u) {
- var _, w, x, C, j, L, B, $, V, U, z, Y, Z, ee;
- if (u) return !(s.ddIndent < 0) && skipMarker(s, o) >= 0;
- if (((B = o + 1), s.isEmpty(B) && ++B > i)) return !1;
- if (s.tShift[B] < s.blkIndent) return !1;
- if ((_ = skipMarker(s, B)) < 0) return !1;
- if (s.level >= s.options.maxNesting) return !1;
- (L = s.tokens.length),
- s.tokens.push({ type: 'dl_open', lines: (j = [o, 0]), level: s.level++ }),
- (x = o),
- (w = B);
- e: for (;;) {
- for (
- ee = !0,
- Z = !1,
- s.tokens.push({ type: 'dt_open', lines: [x, x], level: s.level++ }),
- s.tokens.push({
- type: 'inline',
- content: s.getLines(x, x + 1, s.blkIndent, !1).trim(),
- level: s.level + 1,
- lines: [x, x],
- children: []
- }),
- s.tokens.push({ type: 'dt_close', level: --s.level });
- ;
- ) {
- if (
- (s.tokens.push({ type: 'dd_open', lines: (C = [B, 0]), level: s.level++ }),
- (Y = s.tight),
- (V = s.ddIndent),
- ($ = s.blkIndent),
- (z = s.tShift[w]),
- (U = s.parentType),
- (s.blkIndent = s.ddIndent = s.tShift[w] + 2),
- (s.tShift[w] = _ - s.bMarks[w]),
- (s.tight = !0),
- (s.parentType = 'deflist'),
- s.parser.tokenize(s, w, i, !0),
- (s.tight && !Z) || (ee = !1),
- (Z = s.line - w > 1 && s.isEmpty(s.line - 1)),
- (s.tShift[w] = z),
- (s.tight = Y),
- (s.parentType = U),
- (s.blkIndent = $),
- (s.ddIndent = V),
- s.tokens.push({ type: 'dd_close', level: --s.level }),
- (C[1] = B = s.line),
- B >= i)
- )
- break e;
- if (s.tShift[B] < s.blkIndent) break e;
- if ((_ = skipMarker(s, B)) < 0) break;
- w = B;
- }
- if (B >= i) break;
- if (((x = B), s.isEmpty(x))) break;
- if (s.tShift[x] < s.blkIndent) break;
- if ((w = x + 1) >= i) break;
- if ((s.isEmpty(w) && w++, w >= i)) break;
- if (s.tShift[w] < s.blkIndent) break;
- if ((_ = skipMarker(s, w)) < 0) break;
- }
- return (
- s.tokens.push({ type: 'dl_close', level: --s.level }),
- (j[1] = B),
- (s.line = B),
- ee &&
- (function markTightParagraphs$1(s, o) {
- var i,
- u,
- _ = s.level + 2;
- for (i = o + 2, u = s.tokens.length - 2; i < u; i++)
- s.tokens[i].level === _ &&
- 'paragraph_open' === s.tokens[i].type &&
- ((s.tokens[i + 2].tight = !0), (s.tokens[i].tight = !0), (i += 2));
- })(s, L),
- !0
- );
- },
- ['paragraph']
- ],
- [
- 'paragraph',
- function paragraph(s, o) {
- var i,
- u,
- _,
- w,
- x,
- C,
- j = o + 1;
- if (j < (i = s.lineMax) && !s.isEmpty(j))
- for (C = s.parser.ruler.getRules('paragraph'); j < i && !s.isEmpty(j); j++)
- if (!(s.tShift[j] - s.blkIndent > 3)) {
- for (_ = !1, w = 0, x = C.length; w < x; w++)
- if (C[w](s, j, i, !0)) {
- _ = !0;
- break;
- }
- if (_) break;
- }
- return (
- (u = s.getLines(o, j, s.blkIndent, !1).trim()),
- (s.line = j),
- u.length &&
- (s.tokens.push({
- type: 'paragraph_open',
- tight: !1,
- lines: [o, s.line],
- level: s.level
- }),
- s.tokens.push({
- type: 'inline',
- content: u,
- level: s.level + 1,
- lines: [o, s.line],
- children: []
- }),
- s.tokens.push({ type: 'paragraph_close', tight: !1, level: s.level })),
- !0
- );
- }
- ]
- ];
- function ParserBlock() {
- this.ruler = new Ruler();
- for (var s = 0; s < wC.length; s++)
- this.ruler.push(wC[s][0], wC[s][1], { alt: (wC[s][2] || []).slice() });
- }
- ParserBlock.prototype.tokenize = function (s, o, i) {
- for (
- var u, _ = this.ruler.getRules(''), w = _.length, x = o, C = !1;
- x < i &&
- ((s.line = x = s.skipEmptyLines(x)), !(x >= i)) &&
- !(s.tShift[x] < s.blkIndent);
- ) {
- for (u = 0; u < w && !_[u](s, x, i, !1); u++);
- if (
- ((s.tight = !C), s.isEmpty(s.line - 1) && (C = !0), (x = s.line) < i && s.isEmpty(x))
- ) {
- if (((C = !0), ++x < i && 'list' === s.parentType && s.isEmpty(x))) break;
- s.line = x;
- }
- }
- };
- var SC = /[\n\t]/g,
- xC = /\r[\n\u0085]|[\u2424\u2028\u0085]/g,
- kC = /\u00a0/g;
- function isTerminatorChar(s) {
- switch (s) {
- case 10:
- case 92:
- case 96:
- case 42:
- case 95:
- case 94:
- case 91:
- case 93:
- case 33:
- case 38:
- case 60:
- case 62:
- case 123:
- case 125:
- case 36:
- case 37:
- case 64:
- case 126:
- case 43:
- case 61:
- case 58:
- return !0;
- default:
- return !1;
- }
- }
- ParserBlock.prototype.parse = function (s, o, i, u) {
- var _,
- w = 0,
- x = 0;
- if (!s) return [];
- (s = (s = s.replace(kC, ' ')).replace(xC, '\n')).indexOf('\t') >= 0 &&
- (s = s.replace(SC, function (o, i) {
- var u;
- return 10 === s.charCodeAt(i)
- ? ((w = i + 1), (x = 0), o)
- : ((u = ' '.slice((i - w - x) % 4)), (x = i - w + 1), u);
- })),
- (_ = new StateBlock(s, this, o, i, u)),
- this.tokenize(_, _.line, _.lineMax);
- };
- for (var CC = [], OC = 0; OC < 256; OC++) CC.push(0);
- function isAlphaNum(s) {
- return (s >= 48 && s <= 57) || (s >= 65 && s <= 90) || (s >= 97 && s <= 122);
- }
- function scanDelims(s, o) {
- var i,
- u,
- _,
- w = o,
- x = !0,
- C = !0,
- j = s.posMax,
- L = s.src.charCodeAt(o);
- for (i = o > 0 ? s.src.charCodeAt(o - 1) : -1; w < j && s.src.charCodeAt(w) === L; ) w++;
- return (
- w >= j && (x = !1),
- (_ = w - o) >= 4
- ? (x = C = !1)
- : ((32 !== (u = w < j ? s.src.charCodeAt(w) : -1) && 10 !== u) || (x = !1),
- (32 !== i && 10 !== i) || (C = !1),
- 95 === L && (isAlphaNum(i) && (x = !1), isAlphaNum(u) && (C = !1))),
- { can_open: x, can_close: C, delims: _ }
- );
- }
- '\\!"#$%&\'()*+,./:;<=>?@[]^_`{|}~-'.split('').forEach(function (s) {
- CC[s.charCodeAt(0)] = 1;
- });
- var AC = /\\([ \\!"#$%&'()*+,.\/:;<=>?@[\]^_`{|}~-])/g;
- var jC = /\\([ \\!"#$%&'()*+,.\/:;<=>?@[\]^_`{|}~-])/g;
- var IC = [
- 'coap',
- 'doi',
- 'javascript',
- 'aaa',
- 'aaas',
- 'about',
- 'acap',
- 'cap',
- 'cid',
- 'crid',
- 'data',
- 'dav',
- 'dict',
- 'dns',
- 'file',
- 'ftp',
- 'geo',
- 'go',
- 'gopher',
- 'h323',
- 'http',
- 'https',
- 'iax',
- 'icap',
- 'im',
- 'imap',
- 'info',
- 'ipp',
- 'iris',
- 'iris.beep',
- 'iris.xpc',
- 'iris.xpcs',
- 'iris.lwz',
- 'ldap',
- 'mailto',
- 'mid',
- 'msrp',
- 'msrps',
- 'mtqp',
- 'mupdate',
- 'news',
- 'nfs',
- 'ni',
- 'nih',
- 'nntp',
- 'opaquelocktoken',
- 'pop',
- 'pres',
- 'rtsp',
- 'service',
- 'session',
- 'shttp',
- 'sieve',
- 'sip',
- 'sips',
- 'sms',
- 'snmp',
- 'soap.beep',
- 'soap.beeps',
- 'tag',
- 'tel',
- 'telnet',
- 'tftp',
- 'thismessage',
- 'tn3270',
- 'tip',
- 'tv',
- 'urn',
- 'vemmi',
- 'ws',
- 'wss',
- 'xcon',
- 'xcon-userid',
- 'xmlrpc.beep',
- 'xmlrpc.beeps',
- 'xmpp',
- 'z39.50r',
- 'z39.50s',
- 'adiumxtra',
- 'afp',
- 'afs',
- 'aim',
- 'apt',
- 'attachment',
- 'aw',
- 'beshare',
- 'bitcoin',
- 'bolo',
- 'callto',
- 'chrome',
- 'chrome-extension',
- 'com-eventbrite-attendee',
- 'content',
- 'cvs',
- 'dlna-playsingle',
- 'dlna-playcontainer',
- 'dtn',
- 'dvb',
- 'ed2k',
- 'facetime',
- 'feed',
- 'finger',
- 'fish',
- 'gg',
- 'git',
- 'gizmoproject',
- 'gtalk',
- 'hcp',
- 'icon',
- 'ipn',
- 'irc',
- 'irc6',
- 'ircs',
- 'itms',
- 'jar',
- 'jms',
- 'keyparc',
- 'lastfm',
- 'ldaps',
- 'magnet',
- 'maps',
- 'market',
- 'message',
- 'mms',
- 'ms-help',
- 'msnim',
- 'mumble',
- 'mvn',
- 'notes',
- 'oid',
- 'palm',
- 'paparazzi',
- 'platform',
- 'proxy',
- 'psyc',
- 'query',
- 'res',
- 'resource',
- 'rmi',
- 'rsync',
- 'rtmp',
- 'secondlife',
- 'sftp',
- 'sgn',
- 'skype',
- 'smb',
- 'soldat',
- 'spotify',
- 'ssh',
- 'steam',
- 'svn',
- 'teamspeak',
- 'things',
- 'udp',
- 'unreal',
- 'ut2004',
- 'ventrilo',
- 'view-source',
- 'webcal',
- 'wtai',
- 'wyciwyg',
- 'xfire',
- 'xri',
- 'ymsgr'
- ],
- PC =
- /^<([a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*)>/,
- MC = /^<([a-zA-Z.\-]{1,25}):([^<>\x00-\x20]*)>/;
- function replace$1(s, o) {
- return (
- (s = s.source),
- (o = o || ''),
- function self(i, u) {
- return i ? ((u = u.source || u), (s = s.replace(i, u)), self) : new RegExp(s, o);
- }
- );
- }
- var TC = replace$1(/(?:unquoted|single_quoted|double_quoted)/)(
- 'unquoted',
- /[^"'=<>`\x00-\x20]+/
- )('single_quoted', /'[^']*'/)('double_quoted', /"[^"]*"/)(),
- NC = replace$1(/(?:\s+attr_name(?:\s*=\s*attr_value)?)/)(
- 'attr_name',
- /[a-zA-Z_:][a-zA-Z0-9:._-]*/
- )('attr_value', TC)(),
- RC = replace$1(/<[A-Za-z][A-Za-z0-9]*attribute*\s*\/?>/)('attribute', NC)(),
- DC = replace$1(/^(?:open_tag|close_tag|comment|processing|declaration|cdata)/)(
- 'open_tag',
- RC
- )('close_tag', /<\/[A-Za-z][A-Za-z0-9]*\s*>/)(
- 'comment',
- /<!---->|<!--(?:-?[^>-])(?:-?[^-])*-->/
- )('processing', /<[?].*?[?]>/)('declaration', /<![A-Z]+\s+[^>]*>/)(
- 'cdata',
- /<!\[CDATA\[[\s\S]*?\]\]>/
- )();
- var LC = /^&#((?:x[a-f0-9]{1,8}|[0-9]{1,8}));/i,
- BC = /^&([a-z][a-z0-9]{1,31});/i;
- var FC = [
- [
- 'text',
- function index_browser_text(s, o) {
- for (var i = s.pos; i < s.posMax && !isTerminatorChar(s.src.charCodeAt(i)); ) i++;
- return i !== s.pos && (o || (s.pending += s.src.slice(s.pos, i)), (s.pos = i), !0);
- }
- ],
- [
- 'newline',
- function newline(s, o) {
- var i,
- u,
- _ = s.pos;
- if (10 !== s.src.charCodeAt(_)) return !1;
- if (((i = s.pending.length - 1), (u = s.posMax), !o))
- if (i >= 0 && 32 === s.pending.charCodeAt(i))
- if (i >= 1 && 32 === s.pending.charCodeAt(i - 1)) {
- for (var w = i - 2; w >= 0; w--)
- if (32 !== s.pending.charCodeAt(w)) {
- s.pending = s.pending.substring(0, w + 1);
- break;
- }
- s.push({ type: 'hardbreak', level: s.level });
- } else
- (s.pending = s.pending.slice(0, -1)),
- s.push({ type: 'softbreak', level: s.level });
- else s.push({ type: 'softbreak', level: s.level });
- for (_++; _ < u && 32 === s.src.charCodeAt(_); ) _++;
- return (s.pos = _), !0;
- }
- ],
- [
- 'escape',
- function index_browser_escape(s, o) {
- var i,
- u = s.pos,
- _ = s.posMax;
- if (92 !== s.src.charCodeAt(u)) return !1;
- if (++u < _) {
- if ((i = s.src.charCodeAt(u)) < 256 && 0 !== CC[i])
- return o || (s.pending += s.src[u]), (s.pos += 2), !0;
- if (10 === i) {
- for (
- o || s.push({ type: 'hardbreak', level: s.level }), u++;
- u < _ && 32 === s.src.charCodeAt(u);
- )
- u++;
- return (s.pos = u), !0;
- }
- }
- return o || (s.pending += '\\'), s.pos++, !0;
- }
- ],
- [
- 'backticks',
- function backticks(s, o) {
- var i,
- u,
- _,
- w,
- x,
- C = s.pos;
- if (96 !== s.src.charCodeAt(C)) return !1;
- for (i = C, C++, u = s.posMax; C < u && 96 === s.src.charCodeAt(C); ) C++;
- for (_ = s.src.slice(i, C), w = x = C; -1 !== (w = s.src.indexOf('`', x)); ) {
- for (x = w + 1; x < u && 96 === s.src.charCodeAt(x); ) x++;
- if (x - w === _.length)
- return (
- o ||
- s.push({
- type: 'code',
- content: s.src
- .slice(C, w)
- .replace(/[ \n]+/g, ' ')
- .trim(),
- block: !1,
- level: s.level
- }),
- (s.pos = x),
- !0
- );
- }
- return o || (s.pending += _), (s.pos += _.length), !0;
- }
- ],
- [
- 'del',
- function del(s, o) {
- var i,
- u,
- _,
- w,
- x,
- C = s.posMax,
- j = s.pos;
- if (126 !== s.src.charCodeAt(j)) return !1;
- if (o) return !1;
- if (j + 4 >= C) return !1;
- if (126 !== s.src.charCodeAt(j + 1)) return !1;
- if (s.level >= s.options.maxNesting) return !1;
- if (
- ((w = j > 0 ? s.src.charCodeAt(j - 1) : -1),
- (x = s.src.charCodeAt(j + 2)),
- 126 === w)
- )
- return !1;
- if (126 === x) return !1;
- if (32 === x || 10 === x) return !1;
- for (u = j + 2; u < C && 126 === s.src.charCodeAt(u); ) u++;
- if (u > j + 3) return (s.pos += u - j), o || (s.pending += s.src.slice(j, u)), !0;
- for (s.pos = j + 2, _ = 1; s.pos + 1 < C; ) {
- if (
- 126 === s.src.charCodeAt(s.pos) &&
- 126 === s.src.charCodeAt(s.pos + 1) &&
- ((w = s.src.charCodeAt(s.pos - 1)),
- 126 !== (x = s.pos + 2 < C ? s.src.charCodeAt(s.pos + 2) : -1) &&
- 126 !== w &&
- (32 !== w && 10 !== w ? _-- : 32 !== x && 10 !== x && _++, _ <= 0))
- ) {
- i = !0;
- break;
- }
- s.parser.skipToken(s);
- }
- return i
- ? ((s.posMax = s.pos),
- (s.pos = j + 2),
- o ||
- (s.push({ type: 'del_open', level: s.level++ }),
- s.parser.tokenize(s),
- s.push({ type: 'del_close', level: --s.level })),
- (s.pos = s.posMax + 2),
- (s.posMax = C),
- !0)
- : ((s.pos = j), !1);
- }
- ],
- [
- 'ins',
- function ins(s, o) {
- var i,
- u,
- _,
- w,
- x,
- C = s.posMax,
- j = s.pos;
- if (43 !== s.src.charCodeAt(j)) return !1;
- if (o) return !1;
- if (j + 4 >= C) return !1;
- if (43 !== s.src.charCodeAt(j + 1)) return !1;
- if (s.level >= s.options.maxNesting) return !1;
- if (
- ((w = j > 0 ? s.src.charCodeAt(j - 1) : -1),
- (x = s.src.charCodeAt(j + 2)),
- 43 === w)
- )
- return !1;
- if (43 === x) return !1;
- if (32 === x || 10 === x) return !1;
- for (u = j + 2; u < C && 43 === s.src.charCodeAt(u); ) u++;
- if (u !== j + 2) return (s.pos += u - j), o || (s.pending += s.src.slice(j, u)), !0;
- for (s.pos = j + 2, _ = 1; s.pos + 1 < C; ) {
- if (
- 43 === s.src.charCodeAt(s.pos) &&
- 43 === s.src.charCodeAt(s.pos + 1) &&
- ((w = s.src.charCodeAt(s.pos - 1)),
- 43 !== (x = s.pos + 2 < C ? s.src.charCodeAt(s.pos + 2) : -1) &&
- 43 !== w &&
- (32 !== w && 10 !== w ? _-- : 32 !== x && 10 !== x && _++, _ <= 0))
- ) {
- i = !0;
- break;
- }
- s.parser.skipToken(s);
- }
- return i
- ? ((s.posMax = s.pos),
- (s.pos = j + 2),
- o ||
- (s.push({ type: 'ins_open', level: s.level++ }),
- s.parser.tokenize(s),
- s.push({ type: 'ins_close', level: --s.level })),
- (s.pos = s.posMax + 2),
- (s.posMax = C),
- !0)
- : ((s.pos = j), !1);
- }
- ],
- [
- 'mark',
- function mark(s, o) {
- var i,
- u,
- _,
- w,
- x,
- C = s.posMax,
- j = s.pos;
- if (61 !== s.src.charCodeAt(j)) return !1;
- if (o) return !1;
- if (j + 4 >= C) return !1;
- if (61 !== s.src.charCodeAt(j + 1)) return !1;
- if (s.level >= s.options.maxNesting) return !1;
- if (
- ((w = j > 0 ? s.src.charCodeAt(j - 1) : -1),
- (x = s.src.charCodeAt(j + 2)),
- 61 === w)
- )
- return !1;
- if (61 === x) return !1;
- if (32 === x || 10 === x) return !1;
- for (u = j + 2; u < C && 61 === s.src.charCodeAt(u); ) u++;
- if (u !== j + 2) return (s.pos += u - j), o || (s.pending += s.src.slice(j, u)), !0;
- for (s.pos = j + 2, _ = 1; s.pos + 1 < C; ) {
- if (
- 61 === s.src.charCodeAt(s.pos) &&
- 61 === s.src.charCodeAt(s.pos + 1) &&
- ((w = s.src.charCodeAt(s.pos - 1)),
- 61 !== (x = s.pos + 2 < C ? s.src.charCodeAt(s.pos + 2) : -1) &&
- 61 !== w &&
- (32 !== w && 10 !== w ? _-- : 32 !== x && 10 !== x && _++, _ <= 0))
- ) {
- i = !0;
- break;
- }
- s.parser.skipToken(s);
- }
- return i
- ? ((s.posMax = s.pos),
- (s.pos = j + 2),
- o ||
- (s.push({ type: 'mark_open', level: s.level++ }),
- s.parser.tokenize(s),
- s.push({ type: 'mark_close', level: --s.level })),
- (s.pos = s.posMax + 2),
- (s.posMax = C),
- !0)
- : ((s.pos = j), !1);
- }
- ],
- [
- 'emphasis',
- function emphasis(s, o) {
- var i,
- u,
- _,
- w,
- x,
- C,
- j,
- L = s.posMax,
- B = s.pos,
- $ = s.src.charCodeAt(B);
- if (95 !== $ && 42 !== $) return !1;
- if (o) return !1;
- if (((i = (j = scanDelims(s, B)).delims), !j.can_open))
- return (s.pos += i), o || (s.pending += s.src.slice(B, s.pos)), !0;
- if (s.level >= s.options.maxNesting) return !1;
- for (s.pos = B + i, C = [i]; s.pos < L; )
- if (s.src.charCodeAt(s.pos) !== $) s.parser.skipToken(s);
- else {
- if (((u = (j = scanDelims(s, s.pos)).delims), j.can_close)) {
- for (w = C.pop(), x = u; w !== x; ) {
- if (x < w) {
- C.push(w - x);
- break;
- }
- if (((x -= w), 0 === C.length)) break;
- (s.pos += w), (w = C.pop());
- }
- if (0 === C.length) {
- (i = w), (_ = !0);
- break;
- }
- s.pos += u;
- continue;
- }
- j.can_open && C.push(u), (s.pos += u);
- }
- return _
- ? ((s.posMax = s.pos),
- (s.pos = B + i),
- o ||
- ((2 !== i && 3 !== i) || s.push({ type: 'strong_open', level: s.level++ }),
- (1 !== i && 3 !== i) || s.push({ type: 'em_open', level: s.level++ }),
- s.parser.tokenize(s),
- (1 !== i && 3 !== i) || s.push({ type: 'em_close', level: --s.level }),
- (2 !== i && 3 !== i) || s.push({ type: 'strong_close', level: --s.level })),
- (s.pos = s.posMax + i),
- (s.posMax = L),
- !0)
- : ((s.pos = B), !1);
- }
- ],
- [
- 'sub',
- function sub(s, o) {
- var i,
- u,
- _ = s.posMax,
- w = s.pos;
- if (126 !== s.src.charCodeAt(w)) return !1;
- if (o) return !1;
- if (w + 2 >= _) return !1;
- if (s.level >= s.options.maxNesting) return !1;
- for (s.pos = w + 1; s.pos < _; ) {
- if (126 === s.src.charCodeAt(s.pos)) {
- i = !0;
- break;
- }
- s.parser.skipToken(s);
- }
- return i && w + 1 !== s.pos
- ? (u = s.src.slice(w + 1, s.pos)).match(/(^|[^\\])(\\\\)*\s/)
- ? ((s.pos = w), !1)
- : ((s.posMax = s.pos),
- (s.pos = w + 1),
- o || s.push({ type: 'sub', level: s.level, content: u.replace(AC, '$1') }),
- (s.pos = s.posMax + 1),
- (s.posMax = _),
- !0)
- : ((s.pos = w), !1);
- }
- ],
- [
- 'sup',
- function sup(s, o) {
- var i,
- u,
- _ = s.posMax,
- w = s.pos;
- if (94 !== s.src.charCodeAt(w)) return !1;
- if (o) return !1;
- if (w + 2 >= _) return !1;
- if (s.level >= s.options.maxNesting) return !1;
- for (s.pos = w + 1; s.pos < _; ) {
- if (94 === s.src.charCodeAt(s.pos)) {
- i = !0;
- break;
- }
- s.parser.skipToken(s);
- }
- return i && w + 1 !== s.pos
- ? (u = s.src.slice(w + 1, s.pos)).match(/(^|[^\\])(\\\\)*\s/)
- ? ((s.pos = w), !1)
- : ((s.posMax = s.pos),
- (s.pos = w + 1),
- o || s.push({ type: 'sup', level: s.level, content: u.replace(jC, '$1') }),
- (s.pos = s.posMax + 1),
- (s.posMax = _),
- !0)
- : ((s.pos = w), !1);
- }
- ],
- [
- 'links',
- function links(s, o) {
- var i,
- u,
- _,
- w,
- x,
- C,
- j,
- L,
- B = !1,
- $ = s.pos,
- V = s.posMax,
- U = s.pos,
- z = s.src.charCodeAt(U);
- if ((33 === z && ((B = !0), (z = s.src.charCodeAt(++U))), 91 !== z)) return !1;
- if (s.level >= s.options.maxNesting) return !1;
- if (((i = U + 1), (u = parseLinkLabel(s, U)) < 0)) return !1;
- if ((C = u + 1) < V && 40 === s.src.charCodeAt(C)) {
- for (C++; C < V && (32 === (L = s.src.charCodeAt(C)) || 10 === L); C++);
- if (C >= V) return !1;
- for (
- U = C,
- parseLinkDestination(s, C) ? ((w = s.linkContent), (C = s.pos)) : (w = ''),
- U = C;
- C < V && (32 === (L = s.src.charCodeAt(C)) || 10 === L);
- C++
- );
- if (C < V && U !== C && parseLinkTitle(s, C))
- for (
- x = s.linkContent, C = s.pos;
- C < V && (32 === (L = s.src.charCodeAt(C)) || 10 === L);
- C++
- );
- else x = '';
- if (C >= V || 41 !== s.src.charCodeAt(C)) return (s.pos = $), !1;
- C++;
- } else {
- if (s.linkLevel > 0) return !1;
- for (; C < V && (32 === (L = s.src.charCodeAt(C)) || 10 === L); C++);
- if (
- (C < V &&
- 91 === s.src.charCodeAt(C) &&
- ((U = C + 1),
- (C = parseLinkLabel(s, C)) >= 0 ? (_ = s.src.slice(U, C++)) : (C = U - 1)),
- _ || (void 0 === _ && (C = u + 1), (_ = s.src.slice(i, u))),
- !(j = s.env.references[normalizeReference(_)]))
- )
- return (s.pos = $), !1;
- (w = j.href), (x = j.title);
- }
- return (
- o ||
- ((s.pos = i),
- (s.posMax = u),
- B
- ? s.push({
- type: 'image',
- src: w,
- title: x,
- alt: s.src.substr(i, u - i),
- level: s.level
- })
- : (s.push({ type: 'link_open', href: w, title: x, level: s.level++ }),
- s.linkLevel++,
- s.parser.tokenize(s),
- s.linkLevel--,
- s.push({ type: 'link_close', level: --s.level }))),
- (s.pos = C),
- (s.posMax = V),
- !0
- );
- }
- ],
- [
- 'footnote_inline',
- function footnote_inline(s, o) {
- var i,
- u,
- _,
- w,
- x = s.posMax,
- C = s.pos;
- return (
- !(C + 2 >= x) &&
- 94 === s.src.charCodeAt(C) &&
- 91 === s.src.charCodeAt(C + 1) &&
- !(s.level >= s.options.maxNesting) &&
- ((i = C + 2),
- !((u = parseLinkLabel(s, C + 1)) < 0) &&
- (o ||
- (s.env.footnotes || (s.env.footnotes = {}),
- s.env.footnotes.list || (s.env.footnotes.list = []),
- (_ = s.env.footnotes.list.length),
- (s.pos = i),
- (s.posMax = u),
- s.push({ type: 'footnote_ref', id: _, level: s.level }),
- s.linkLevel++,
- (w = s.tokens.length),
- s.parser.tokenize(s),
- (s.env.footnotes.list[_] = { tokens: s.tokens.splice(w) }),
- s.linkLevel--),
- (s.pos = u + 1),
- (s.posMax = x),
- !0))
- );
- }
- ],
- [
- 'footnote_ref',
- function footnote_ref(s, o) {
- var i,
- u,
- _,
- w,
- x = s.posMax,
- C = s.pos;
- if (C + 3 > x) return !1;
- if (!s.env.footnotes || !s.env.footnotes.refs) return !1;
- if (91 !== s.src.charCodeAt(C)) return !1;
- if (94 !== s.src.charCodeAt(C + 1)) return !1;
- if (s.level >= s.options.maxNesting) return !1;
- for (u = C + 2; u < x; u++) {
- if (32 === s.src.charCodeAt(u)) return !1;
- if (10 === s.src.charCodeAt(u)) return !1;
- if (93 === s.src.charCodeAt(u)) break;
- }
- return (
- u !== C + 2 &&
- !(u >= x) &&
- (u++,
- (i = s.src.slice(C + 2, u - 1)),
- void 0 !== s.env.footnotes.refs[':' + i] &&
- (o ||
- (s.env.footnotes.list || (s.env.footnotes.list = []),
- s.env.footnotes.refs[':' + i] < 0
- ? ((_ = s.env.footnotes.list.length),
- (s.env.footnotes.list[_] = { label: i, count: 0 }),
- (s.env.footnotes.refs[':' + i] = _))
- : (_ = s.env.footnotes.refs[':' + i]),
- (w = s.env.footnotes.list[_].count),
- s.env.footnotes.list[_].count++,
- s.push({ type: 'footnote_ref', id: _, subId: w, level: s.level })),
- (s.pos = u),
- (s.posMax = x),
- !0))
- );
- }
- ],
- [
- 'autolink',
- function autolink(s, o) {
- var i,
- u,
- _,
- w,
- x,
- C = s.pos;
- return (
- 60 === s.src.charCodeAt(C) &&
- !((i = s.src.slice(C)).indexOf('>') < 0) &&
- ((u = i.match(MC))
- ? !(IC.indexOf(u[1].toLowerCase()) < 0) &&
- ((x = normalizeLink((w = u[0].slice(1, -1)))),
- !!s.parser.validateLink(w) &&
- (o ||
- (s.push({ type: 'link_open', href: x, level: s.level }),
- s.push({ type: 'text', content: w, level: s.level + 1 }),
- s.push({ type: 'link_close', level: s.level })),
- (s.pos += u[0].length),
- !0))
- : !!(_ = i.match(PC)) &&
- ((x = normalizeLink('mailto:' + (w = _[0].slice(1, -1)))),
- !!s.parser.validateLink(x) &&
- (o ||
- (s.push({ type: 'link_open', href: x, level: s.level }),
- s.push({ type: 'text', content: w, level: s.level + 1 }),
- s.push({ type: 'link_close', level: s.level })),
- (s.pos += _[0].length),
- !0)))
- );
- }
- ],
- [
- 'htmltag',
- function htmltag(s, o) {
- var i,
- u,
- _,
- w = s.pos;
- return (
- !!s.options.html &&
- ((_ = s.posMax),
- !(60 !== s.src.charCodeAt(w) || w + 2 >= _) &&
- !(
- 33 !== (i = s.src.charCodeAt(w + 1)) &&
- 63 !== i &&
- 47 !== i &&
- !(function isLetter$2(s) {
- var o = 32 | s;
- return o >= 97 && o <= 122;
- })(i)
- ) &&
- !!(u = s.src.slice(w).match(DC)) &&
- (o ||
- s.push({
- type: 'htmltag',
- content: s.src.slice(w, w + u[0].length),
- level: s.level
- }),
- (s.pos += u[0].length),
- !0))
- );
- }
- ],
- [
- 'entity',
- function entity(s, o) {
- var i,
- u,
- _ = s.pos,
- w = s.posMax;
- if (38 !== s.src.charCodeAt(_)) return !1;
- if (_ + 1 < w)
- if (35 === s.src.charCodeAt(_ + 1)) {
- if ((u = s.src.slice(_).match(LC)))
- return (
- o ||
- ((i =
- 'x' === u[1][0].toLowerCase()
- ? parseInt(u[1].slice(1), 16)
- : parseInt(u[1], 10)),
- (s.pending += isValidEntityCode(i)
- ? fromCodePoint(i)
- : fromCodePoint(65533))),
- (s.pos += u[0].length),
- !0
- );
- } else if ((u = s.src.slice(_).match(BC))) {
- var x = decodeEntity(u[1]);
- if (u[1] !== x) return o || (s.pending += x), (s.pos += u[0].length), !0;
- }
- return o || (s.pending += '&'), s.pos++, !0;
- }
- ]
- ];
- function ParserInline() {
- this.ruler = new Ruler();
- for (var s = 0; s < FC.length; s++) this.ruler.push(FC[s][0], FC[s][1]);
- this.validateLink = validateLink;
- }
- function validateLink(s) {
- var o = s.trim().toLowerCase();
- return (
- -1 === (o = replaceEntities(o)).indexOf(':') ||
- -1 === ['vbscript', 'javascript', 'file', 'data'].indexOf(o.split(':')[0])
- );
- }
- (ParserInline.prototype.skipToken = function (s) {
- var o,
- i,
- u = this.ruler.getRules(''),
- _ = u.length,
- w = s.pos;
- if ((i = s.cacheGet(w)) > 0) s.pos = i;
- else {
- for (o = 0; o < _; o++) if (u[o](s, !0)) return void s.cacheSet(w, s.pos);
- s.pos++, s.cacheSet(w, s.pos);
- }
- }),
- (ParserInline.prototype.tokenize = function (s) {
- for (var o, i, u = this.ruler.getRules(''), _ = u.length, w = s.posMax; s.pos < w; ) {
- for (i = 0; i < _ && !(o = u[i](s, !1)); i++);
- if (o) {
- if (s.pos >= w) break;
- } else s.pending += s.src[s.pos++];
- }
- s.pending && s.pushPending();
- }),
- (ParserInline.prototype.parse = function (s, o, i, u) {
- var _ = new StateInline(s, this, o, i, u);
- this.tokenize(_);
- });
- var qC = {
- default: {
- options: {
- html: !1,
- xhtmlOut: !1,
- breaks: !1,
- langPrefix: 'language-',
- linkTarget: '',
- typographer: !1,
- quotes: '“”‘’',
- highlight: null,
- maxNesting: 20
- },
- components: {
- core: {
- rules: [
- 'block',
- 'inline',
- 'references',
- 'replacements',
- 'smartquotes',
- 'references',
- 'abbr2',
- 'footnote_tail'
- ]
- },
- block: {
- rules: [
- 'blockquote',
- 'code',
- 'fences',
- 'footnote',
- 'heading',
- 'hr',
- 'htmlblock',
- 'lheading',
- 'list',
- 'paragraph',
- 'table'
- ]
- },
- inline: {
- rules: [
- 'autolink',
- 'backticks',
- 'del',
- 'emphasis',
- 'entity',
- 'escape',
- 'footnote_ref',
- 'htmltag',
- 'links',
- 'newline',
- 'text'
- ]
- }
- }
- },
- full: {
- options: {
- html: !1,
- xhtmlOut: !1,
- breaks: !1,
- langPrefix: 'language-',
- linkTarget: '',
- typographer: !1,
- quotes: '“”‘’',
- highlight: null,
- maxNesting: 20
- },
- components: { core: {}, block: {}, inline: {} }
- },
- commonmark: {
- options: {
- html: !0,
- xhtmlOut: !0,
- breaks: !1,
- langPrefix: 'language-',
- linkTarget: '',
- typographer: !1,
- quotes: '“”‘’',
- highlight: null,
- maxNesting: 20
- },
- components: {
- core: { rules: ['block', 'inline', 'references', 'abbr2'] },
- block: {
- rules: [
- 'blockquote',
- 'code',
- 'fences',
- 'heading',
- 'hr',
- 'htmlblock',
- 'lheading',
- 'list',
- 'paragraph'
- ]
- },
- inline: {
- rules: [
- 'autolink',
- 'backticks',
- 'emphasis',
- 'entity',
- 'escape',
- 'htmltag',
- 'links',
- 'newline',
- 'text'
- ]
- }
- }
- }
- };
- function StateCore(s, o, i) {
- (this.src = o),
- (this.env = i),
- (this.options = s.options),
- (this.tokens = []),
- (this.inlineMode = !1),
- (this.inline = s.inline),
- (this.block = s.block),
- (this.renderer = s.renderer),
- (this.typographer = s.typographer);
- }
- function Remarkable(s, o) {
- 'string' != typeof s && ((o = s), (s = 'default')),
- o &&
- null != o.linkify &&
- console.warn(
- "linkify option is removed. Use linkify plugin instead:\n\nimport Remarkable from 'remarkable';\nimport linkify from 'remarkable/linkify';\nnew Remarkable().use(linkify)\n"
- ),
- (this.inline = new ParserInline()),
- (this.block = new ParserBlock()),
- (this.core = new Core()),
- (this.renderer = new Renderer()),
- (this.ruler = new Ruler()),
- (this.options = {}),
- this.configure(qC[s]),
- this.set(o || {});
- }
- (Remarkable.prototype.set = function (s) {
- index_browser_assign(this.options, s);
- }),
- (Remarkable.prototype.configure = function (s) {
- var o = this;
- if (!s) throw new Error('Wrong `remarkable` preset, check name/content');
- s.options && o.set(s.options),
- s.components &&
- Object.keys(s.components).forEach(function (i) {
- s.components[i].rules && o[i].ruler.enable(s.components[i].rules, !0);
- });
- }),
- (Remarkable.prototype.use = function (s, o) {
- return s(this, o), this;
- }),
- (Remarkable.prototype.parse = function (s, o) {
- var i = new StateCore(this, s, o);
- return this.core.process(i), i.tokens;
- }),
- (Remarkable.prototype.render = function (s, o) {
- return (o = o || {}), this.renderer.render(this.parse(s, o), this.options, o);
- }),
- (Remarkable.prototype.parseInline = function (s, o) {
- var i = new StateCore(this, s, o);
- return (i.inlineMode = !0), this.core.process(i), i.tokens;
- }),
- (Remarkable.prototype.renderInline = function (s, o) {
- return (o = o || {}), this.renderer.render(this.parseInline(s, o), this.options, o);
- });
- function indexOf(s, o) {
- if (Array.prototype.indexOf) return s.indexOf(o);
- for (var i = 0, u = s.length; i < u; i++) if (s[i] === o) return i;
- return -1;
- }
- function utils_remove(s, o) {
- for (var i = s.length - 1; i >= 0; i--) !0 === o(s[i]) && s.splice(i, 1);
- }
- function throwUnhandledCaseError(s) {
- throw new Error("Unhandled case for value: '".concat(s, "'"));
- }
- var $C = (function () {
- function HtmlTag(s) {
- void 0 === s && (s = {}),
- (this.tagName = ''),
- (this.attrs = {}),
- (this.innerHTML = ''),
- (this.whitespaceRegex = /\s+/),
- (this.tagName = s.tagName || ''),
- (this.attrs = s.attrs || {}),
- (this.innerHTML = s.innerHtml || s.innerHTML || '');
- }
- return (
- (HtmlTag.prototype.setTagName = function (s) {
- return (this.tagName = s), this;
- }),
- (HtmlTag.prototype.getTagName = function () {
- return this.tagName || '';
- }),
- (HtmlTag.prototype.setAttr = function (s, o) {
- return (this.getAttrs()[s] = o), this;
- }),
- (HtmlTag.prototype.getAttr = function (s) {
- return this.getAttrs()[s];
- }),
- (HtmlTag.prototype.setAttrs = function (s) {
- return Object.assign(this.getAttrs(), s), this;
- }),
- (HtmlTag.prototype.getAttrs = function () {
- return this.attrs || (this.attrs = {});
- }),
- (HtmlTag.prototype.setClass = function (s) {
- return this.setAttr('class', s);
- }),
- (HtmlTag.prototype.addClass = function (s) {
- for (
- var o,
- i = this.getClass(),
- u = this.whitespaceRegex,
- _ = i ? i.split(u) : [],
- w = s.split(u);
- (o = w.shift());
- )
- -1 === indexOf(_, o) && _.push(o);
- return (this.getAttrs().class = _.join(' ')), this;
- }),
- (HtmlTag.prototype.removeClass = function (s) {
- for (
- var o,
- i = this.getClass(),
- u = this.whitespaceRegex,
- _ = i ? i.split(u) : [],
- w = s.split(u);
- _.length && (o = w.shift());
- ) {
- var x = indexOf(_, o);
- -1 !== x && _.splice(x, 1);
- }
- return (this.getAttrs().class = _.join(' ')), this;
- }),
- (HtmlTag.prototype.getClass = function () {
- return this.getAttrs().class || '';
- }),
- (HtmlTag.prototype.hasClass = function (s) {
- return -1 !== (' ' + this.getClass() + ' ').indexOf(' ' + s + ' ');
- }),
- (HtmlTag.prototype.setInnerHTML = function (s) {
- return (this.innerHTML = s), this;
- }),
- (HtmlTag.prototype.setInnerHtml = function (s) {
- return this.setInnerHTML(s);
- }),
- (HtmlTag.prototype.getInnerHTML = function () {
- return this.innerHTML || '';
- }),
- (HtmlTag.prototype.getInnerHtml = function () {
- return this.getInnerHTML();
- }),
- (HtmlTag.prototype.toAnchorString = function () {
- var s = this.getTagName(),
- o = this.buildAttrsStr();
- return ['<', s, (o = o ? ' ' + o : ''), '>', this.getInnerHtml(), '</', s, '>'].join(
- ''
- );
- }),
- (HtmlTag.prototype.buildAttrsStr = function () {
- if (!this.attrs) return '';
- var s = this.getAttrs(),
- o = [];
- for (var i in s) s.hasOwnProperty(i) && o.push(i + '="' + s[i] + '"');
- return o.join(' ');
- }),
- HtmlTag
- );
- })();
- var VC = (function () {
- function AnchorTagBuilder(s) {
- void 0 === s && (s = {}),
- (this.newWindow = !1),
- (this.truncate = {}),
- (this.className = ''),
- (this.newWindow = s.newWindow || !1),
- (this.truncate = s.truncate || {}),
- (this.className = s.className || '');
- }
- return (
- (AnchorTagBuilder.prototype.build = function (s) {
- return new $C({
- tagName: 'a',
- attrs: this.createAttrs(s),
- innerHtml: this.processAnchorText(s.getAnchorText())
- });
- }),
- (AnchorTagBuilder.prototype.createAttrs = function (s) {
- var o = { href: s.getAnchorHref() },
- i = this.createCssClass(s);
- return (
- i && (o.class = i),
- this.newWindow && ((o.target = '_blank'), (o.rel = 'noopener noreferrer')),
- this.truncate &&
- this.truncate.length &&
- this.truncate.length < s.getAnchorText().length &&
- (o.title = s.getAnchorHref()),
- o
- );
- }),
- (AnchorTagBuilder.prototype.createCssClass = function (s) {
- var o = this.className;
- if (o) {
- for (var i = [o], u = s.getCssClassSuffixes(), _ = 0, w = u.length; _ < w; _++)
- i.push(o + '-' + u[_]);
- return i.join(' ');
- }
- return '';
- }),
- (AnchorTagBuilder.prototype.processAnchorText = function (s) {
- return (s = this.doTruncate(s));
- }),
- (AnchorTagBuilder.prototype.doTruncate = function (s) {
- var o = this.truncate;
- if (!o || !o.length) return s;
- var i = o.length,
- u = o.location;
- return 'smart' === u
- ? (function truncateSmart(s, o, i) {
- var u, _;
- null == i
- ? ((i = '…'), (_ = 3), (u = 8))
- : ((_ = i.length), (u = i.length));
- var buildUrl = function (s) {
- var o = '';
- return (
- s.scheme && s.host && (o += s.scheme + '://'),
- s.host && (o += s.host),
- s.path && (o += '/' + s.path),
- s.query && (o += '?' + s.query),
- s.fragment && (o += '#' + s.fragment),
- o
- );
- },
- buildSegment = function (s, o) {
- var u = o / 2,
- _ = Math.ceil(u),
- w = -1 * Math.floor(u),
- x = '';
- return w < 0 && (x = s.substr(w)), s.substr(0, _) + i + x;
- };
- if (s.length <= o) return s;
- var w = o - _,
- x = (function (s) {
- var o = {},
- i = s,
- u = i.match(/^([a-z]+):\/\//i);
- return (
- u && ((o.scheme = u[1]), (i = i.substr(u[0].length))),
- (u = i.match(/^(.*?)(?=(\?|#|\/|$))/i)) &&
- ((o.host = u[1]), (i = i.substr(u[0].length))),
- (u = i.match(/^\/(.*?)(?=(\?|#|$))/i)) &&
- ((o.path = u[1]), (i = i.substr(u[0].length))),
- (u = i.match(/^\?(.*?)(?=(#|$))/i)) &&
- ((o.query = u[1]), (i = i.substr(u[0].length))),
- (u = i.match(/^#(.*?)$/i)) && (o.fragment = u[1]),
- o
- );
- })(s);
- if (x.query) {
- var C = x.query.match(/^(.*?)(?=(\?|\#))(.*?)$/i);
- C && ((x.query = x.query.substr(0, C[1].length)), (s = buildUrl(x)));
- }
- if (s.length <= o) return s;
- if (
- (x.host && ((x.host = x.host.replace(/^www\./, '')), (s = buildUrl(x))),
- s.length <= o)
- )
- return s;
- var j = '';
- if ((x.host && (j += x.host), j.length >= w))
- return x.host.length == o
- ? (x.host.substr(0, o - _) + i).substr(0, w + u)
- : buildSegment(j, w).substr(0, w + u);
- var L = '';
- if ((x.path && (L += '/' + x.path), x.query && (L += '?' + x.query), L)) {
- if ((j + L).length >= w)
- return (j + L).length == o
- ? (j + L).substr(0, o)
- : (j + buildSegment(L, w - j.length)).substr(0, w + u);
- j += L;
- }
- if (x.fragment) {
- var B = '#' + x.fragment;
- if ((j + B).length >= w)
- return (j + B).length == o
- ? (j + B).substr(0, o)
- : (j + buildSegment(B, w - j.length)).substr(0, w + u);
- j += B;
- }
- if (x.scheme && x.host) {
- var $ = x.scheme + '://';
- if ((j + $).length < w) return ($ + j).substr(0, o);
- }
- if (j.length <= o) return j;
- var V = '';
- return (
- w > 0 && (V = j.substr(-1 * Math.floor(w / 2))),
- (j.substr(0, Math.ceil(w / 2)) + i + V).substr(0, w + u)
- );
- })(s, i)
- : 'middle' === u
- ? (function truncateMiddle(s, o, i) {
- if (s.length <= o) return s;
- var u, _;
- null == i
- ? ((i = '…'), (u = 8), (_ = 3))
- : ((u = i.length), (_ = i.length));
- var w = o - _,
- x = '';
- return (
- w > 0 && (x = s.substr(-1 * Math.floor(w / 2))),
- (s.substr(0, Math.ceil(w / 2)) + i + x).substr(0, w + u)
- );
- })(s, i)
- : (function truncateEnd(s, o, i) {
- return (function ellipsis(s, o, i) {
- var u;
- return (
- s.length > o &&
- (null == i ? ((i = '…'), (u = 3)) : (u = i.length),
- (s = s.substring(0, o - u) + i)),
- s
- );
- })(s, o, i);
- })(s, i);
- }),
- AnchorTagBuilder
- );
- })(),
- UC = (function () {
- function Match(s) {
- (this.__jsduckDummyDocProp = null),
- (this.matchedText = ''),
- (this.offset = 0),
- (this.tagBuilder = s.tagBuilder),
- (this.matchedText = s.matchedText),
- (this.offset = s.offset);
- }
- return (
- (Match.prototype.getMatchedText = function () {
- return this.matchedText;
- }),
- (Match.prototype.setOffset = function (s) {
- this.offset = s;
- }),
- (Match.prototype.getOffset = function () {
- return this.offset;
- }),
- (Match.prototype.getCssClassSuffixes = function () {
- return [this.getType()];
- }),
- (Match.prototype.buildTag = function () {
- return this.tagBuilder.build(this);
- }),
- Match
- );
- })(),
- extendStatics = function (s, o) {
- return (
- (extendStatics =
- Object.setPrototypeOf ||
- ({ __proto__: [] } instanceof Array &&
- function (s, o) {
- s.__proto__ = o;
- }) ||
- function (s, o) {
- for (var i in o) Object.prototype.hasOwnProperty.call(o, i) && (s[i] = o[i]);
- }),
- extendStatics(s, o)
- );
- };
- function tslib_es6_extends(s, o) {
- if ('function' != typeof o && null !== o)
- throw new TypeError(
- 'Class extends value ' + String(o) + ' is not a constructor or null'
- );
- function __() {
- this.constructor = s;
- }
- extendStatics(s, o),
- (s.prototype =
- null === o ? Object.create(o) : ((__.prototype = o.prototype), new __()));
- }
- var __assign = function () {
- return (
- (__assign =
- Object.assign ||
- function __assign(s) {
- for (var o, i = 1, u = arguments.length; i < u; i++)
- for (var _ in (o = arguments[i]))
- Object.prototype.hasOwnProperty.call(o, _) && (s[_] = o[_]);
- return s;
- }),
- __assign.apply(this, arguments)
- );
- };
- Object.create;
- Object.create;
- 'function' == typeof SuppressedError && SuppressedError;
- var zC,
- WC = (function (s) {
- function EmailMatch(o) {
- var i = s.call(this, o) || this;
- return (i.email = ''), (i.email = o.email), i;
- }
- return (
- tslib_es6_extends(EmailMatch, s),
- (EmailMatch.prototype.getType = function () {
- return 'email';
- }),
- (EmailMatch.prototype.getEmail = function () {
- return this.email;
- }),
- (EmailMatch.prototype.getAnchorHref = function () {
- return 'mailto:' + this.email;
- }),
- (EmailMatch.prototype.getAnchorText = function () {
- return this.email;
- }),
- EmailMatch
- );
- })(UC),
- KC = (function (s) {
- function HashtagMatch(o) {
- var i = s.call(this, o) || this;
- return (
- (i.serviceName = ''),
- (i.hashtag = ''),
- (i.serviceName = o.serviceName),
- (i.hashtag = o.hashtag),
- i
- );
- }
- return (
- tslib_es6_extends(HashtagMatch, s),
- (HashtagMatch.prototype.getType = function () {
- return 'hashtag';
- }),
- (HashtagMatch.prototype.getServiceName = function () {
- return this.serviceName;
- }),
- (HashtagMatch.prototype.getHashtag = function () {
- return this.hashtag;
- }),
- (HashtagMatch.prototype.getAnchorHref = function () {
- var s = this.serviceName,
- o = this.hashtag;
- switch (s) {
- case 'twitter':
- return 'https://twitter.com/hashtag/' + o;
- case 'facebook':
- return 'https://www.facebook.com/hashtag/' + o;
- case 'instagram':
- return 'https://instagram.com/explore/tags/' + o;
- case 'tiktok':
- return 'https://www.tiktok.com/tag/' + o;
- default:
- throw new Error('Unknown service name to point hashtag to: ' + s);
- }
- }),
- (HashtagMatch.prototype.getAnchorText = function () {
- return '#' + this.hashtag;
- }),
- HashtagMatch
- );
- })(UC),
- HC = (function (s) {
- function MentionMatch(o) {
- var i = s.call(this, o) || this;
- return (
- (i.serviceName = 'twitter'),
- (i.mention = ''),
- (i.mention = o.mention),
- (i.serviceName = o.serviceName),
- i
- );
- }
- return (
- tslib_es6_extends(MentionMatch, s),
- (MentionMatch.prototype.getType = function () {
- return 'mention';
- }),
- (MentionMatch.prototype.getMention = function () {
- return this.mention;
- }),
- (MentionMatch.prototype.getServiceName = function () {
- return this.serviceName;
- }),
- (MentionMatch.prototype.getAnchorHref = function () {
- switch (this.serviceName) {
- case 'twitter':
- return 'https://twitter.com/' + this.mention;
- case 'instagram':
- return 'https://instagram.com/' + this.mention;
- case 'soundcloud':
- return 'https://soundcloud.com/' + this.mention;
- case 'tiktok':
- return 'https://www.tiktok.com/@' + this.mention;
- default:
- throw new Error(
- 'Unknown service name to point mention to: ' + this.serviceName
- );
- }
- }),
- (MentionMatch.prototype.getAnchorText = function () {
- return '@' + this.mention;
- }),
- (MentionMatch.prototype.getCssClassSuffixes = function () {
- var o = s.prototype.getCssClassSuffixes.call(this),
- i = this.getServiceName();
- return i && o.push(i), o;
- }),
- MentionMatch
- );
- })(UC),
- JC = (function (s) {
- function PhoneMatch(o) {
- var i = s.call(this, o) || this;
- return (
- (i.number = ''),
- (i.plusSign = !1),
- (i.number = o.number),
- (i.plusSign = o.plusSign),
- i
- );
- }
- return (
- tslib_es6_extends(PhoneMatch, s),
- (PhoneMatch.prototype.getType = function () {
- return 'phone';
- }),
- (PhoneMatch.prototype.getPhoneNumber = function () {
- return this.number;
- }),
- (PhoneMatch.prototype.getNumber = function () {
- return this.getPhoneNumber();
- }),
- (PhoneMatch.prototype.getAnchorHref = function () {
- return 'tel:' + (this.plusSign ? '+' : '') + this.number;
- }),
- (PhoneMatch.prototype.getAnchorText = function () {
- return this.matchedText;
- }),
- PhoneMatch
- );
- })(UC),
- GC = (function (s) {
- function UrlMatch(o) {
- var i = s.call(this, o) || this;
- return (
- (i.url = ''),
- (i.urlMatchType = 'scheme'),
- (i.protocolUrlMatch = !1),
- (i.protocolRelativeMatch = !1),
- (i.stripPrefix = { scheme: !0, www: !0 }),
- (i.stripTrailingSlash = !0),
- (i.decodePercentEncoding = !0),
- (i.schemePrefixRegex = /^(https?:\/\/)?/i),
- (i.wwwPrefixRegex = /^(https?:\/\/)?(www\.)?/i),
- (i.protocolRelativeRegex = /^\/\//),
- (i.protocolPrepended = !1),
- (i.urlMatchType = o.urlMatchType),
- (i.url = o.url),
- (i.protocolUrlMatch = o.protocolUrlMatch),
- (i.protocolRelativeMatch = o.protocolRelativeMatch),
- (i.stripPrefix = o.stripPrefix),
- (i.stripTrailingSlash = o.stripTrailingSlash),
- (i.decodePercentEncoding = o.decodePercentEncoding),
- i
- );
- }
- return (
- tslib_es6_extends(UrlMatch, s),
- (UrlMatch.prototype.getType = function () {
- return 'url';
- }),
- (UrlMatch.prototype.getUrlMatchType = function () {
- return this.urlMatchType;
- }),
- (UrlMatch.prototype.getUrl = function () {
- var s = this.url;
- return (
- this.protocolRelativeMatch ||
- this.protocolUrlMatch ||
- this.protocolPrepended ||
- ((s = this.url = 'http://' + s), (this.protocolPrepended = !0)),
- s
- );
- }),
- (UrlMatch.prototype.getAnchorHref = function () {
- return this.getUrl().replace(/&/g, '&');
- }),
- (UrlMatch.prototype.getAnchorText = function () {
- var s = this.getMatchedText();
- return (
- this.protocolRelativeMatch && (s = this.stripProtocolRelativePrefix(s)),
- this.stripPrefix.scheme && (s = this.stripSchemePrefix(s)),
- this.stripPrefix.www && (s = this.stripWwwPrefix(s)),
- this.stripTrailingSlash && (s = this.removeTrailingSlash(s)),
- this.decodePercentEncoding && (s = this.removePercentEncoding(s)),
- s
- );
- }),
- (UrlMatch.prototype.stripSchemePrefix = function (s) {
- return s.replace(this.schemePrefixRegex, '');
- }),
- (UrlMatch.prototype.stripWwwPrefix = function (s) {
- return s.replace(this.wwwPrefixRegex, '$1');
- }),
- (UrlMatch.prototype.stripProtocolRelativePrefix = function (s) {
- return s.replace(this.protocolRelativeRegex, '');
- }),
- (UrlMatch.prototype.removeTrailingSlash = function (s) {
- return '/' === s.charAt(s.length - 1) && (s = s.slice(0, -1)), s;
- }),
- (UrlMatch.prototype.removePercentEncoding = function (s) {
- var o = s
- .replace(/%22/gi, '"')
- .replace(/%26/gi, '&')
- .replace(/%27/gi, ''')
- .replace(/%3C/gi, '<')
- .replace(/%3E/gi, '>');
- try {
- return decodeURIComponent(o);
- } catch (s) {
- return o;
- }
- }),
- UrlMatch
- );
- })(UC),
- YC = function YC(s) {
- (this.__jsduckDummyDocProp = null), (this.tagBuilder = s.tagBuilder);
- },
- XC = /[A-Za-z]/,
- ZC = /[\d]/,
- QC = /[\D]/,
- eO = /\s/,
- tO = /['"]/,
- rO = /[\x00-\x1F\x7F]/,
- nO =
- /A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC/
- .source,
- sO =
- nO +
- /\u2700-\u27bf\udde6-\uddff\ud800-\udbff\udc00-\udfff\ufe0e\ufe0f\u0300-\u036f\ufe20-\ufe23\u20d0-\u20f0\ud83c\udffb-\udfff\u200d\u3299\u3297\u303d\u3030\u24c2\ud83c\udd70-\udd71\udd7e-\udd7f\udd8e\udd91-\udd9a\udde6-\uddff\ude01-\ude02\ude1a\ude2f\ude32-\ude3a\ude50-\ude51\u203c\u2049\u25aa-\u25ab\u25b6\u25c0\u25fb-\u25fe\u00a9\u00ae\u2122\u2139\udc04\u2600-\u26FF\u2b05\u2b06\u2b07\u2b1b\u2b1c\u2b50\u2b55\u231a\u231b\u2328\u23cf\u23e9-\u23f3\u23f8-\u23fa\udccf\u2935\u2934\u2190-\u21ff/
- .source +
- /\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D4-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C03\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D01-\u0D03\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u192B\u1930-\u193B\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ABE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF5\u1DFB-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C5\uA8E0-\uA8F1\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F/
- .source,
- oO =
- /0-9\u0660-\u0669\u06F0-\u06F9\u07C0-\u07C9\u0966-\u096F\u09E6-\u09EF\u0A66-\u0A6F\u0AE6-\u0AEF\u0B66-\u0B6F\u0BE6-\u0BEF\u0C66-\u0C6F\u0CE6-\u0CEF\u0D66-\u0D6F\u0DE6-\u0DEF\u0E50-\u0E59\u0ED0-\u0ED9\u0F20-\u0F29\u1040-\u1049\u1090-\u1099\u17E0-\u17E9\u1810-\u1819\u1946-\u194F\u19D0-\u19D9\u1A80-\u1A89\u1A90-\u1A99\u1B50-\u1B59\u1BB0-\u1BB9\u1C40-\u1C49\u1C50-\u1C59\uA620-\uA629\uA8D0-\uA8D9\uA900-\uA909\uA9D0-\uA9D9\uA9F0-\uA9F9\uAA50-\uAA59\uABF0-\uABF9\uFF10-\uFF19/
- .source,
- iO = sO + oO,
- aO = sO + oO,
- lO = new RegExp('['.concat(aO, ']')),
- cO = '(?:[' + oO + ']{1,3}\\.){3}[' + oO + ']{1,3}',
- uO = '[' + aO + '](?:[' + aO + '\\-_]{0,61}[' + aO + '])?',
- getDomainLabelStr = function (s) {
- return '(?=(' + uO + '))\\' + s;
- },
- getDomainNameStr = function (s) {
- return (
- '(?:' +
- getDomainLabelStr(s) +
- '(?:\\.' +
- getDomainLabelStr(s + 1) +
- '){0,126}|' +
- cO +
- ')'
- );
- },
- pO = (new RegExp('[' + aO + '.\\-]*[' + aO + '\\-]'), lO),
- hO =
- /(?:xn--vermgensberatung-pwb|xn--vermgensberater-ctb|xn--clchc0ea0b2g2a9gcd|xn--w4r85el8fhu5dnra|northwesternmutual|travelersinsurance|vermögensberatung|xn--5su34j936bgsg|xn--bck1b9a5dre4c|xn--mgbah1a3hjkrd|xn--mgbai9azgqp6j|xn--mgberp4a5d4ar|xn--xkc2dl3a5ee0h|vermögensberater|xn--fzys8d69uvgm|xn--mgba7c0bbn0a|xn--mgbcpq6gpa1a|xn--xkc2al3hye2a|americanexpress|kerryproperties|sandvikcoromant|xn--i1b6b1a6a2e|xn--kcrx77d1x4a|xn--lgbbat1ad8j|xn--mgba3a4f16a|xn--mgbaakc7dvf|xn--mgbc0a9azcg|xn--nqv7fs00ema|americanfamily|bananarepublic|cancerresearch|cookingchannel|kerrylogistics|weatherchannel|xn--54b7fta0cc|xn--6qq986b3xl|xn--80aqecdr1a|xn--b4w605ferd|xn--fiq228c5hs|xn--h2breg3eve|xn--jlq480n2rg|xn--jlq61u9w7b|xn--mgba3a3ejt|xn--mgbaam7a8h|xn--mgbayh7gpa|xn--mgbbh1a71e|xn--mgbca7dzdo|xn--mgbi4ecexp|xn--mgbx4cd0ab|xn--rvc1e0am3e|international|lifeinsurance|travelchannel|wolterskluwer|xn--cckwcxetd|xn--eckvdtc9d|xn--fpcrj9c3d|xn--fzc2c9e2c|xn--h2brj9c8c|xn--tiq49xqyj|xn--yfro4i67o|xn--ygbi2ammx|construction|lplfinancial|scholarships|versicherung|xn--3e0b707e|xn--45br5cyl|xn--4dbrk0ce|xn--80adxhks|xn--80asehdb|xn--8y0a063a|xn--gckr3f0f|xn--mgb9awbf|xn--mgbab2bd|xn--mgbgu82a|xn--mgbpl2fh|xn--mgbt3dhd|xn--mk1bu44c|xn--ngbc5azd|xn--ngbe9e0a|xn--ogbpf8fl|xn--qcka1pmc|accountants|barclaycard|blackfriday|blockbuster|bridgestone|calvinklein|contractors|creditunion|engineering|enterprises|foodnetwork|investments|kerryhotels|lamborghini|motorcycles|olayangroup|photography|playstation|productions|progressive|redumbrella|williamhill|xn--11b4c3d|xn--1ck2e1b|xn--1qqw23a|xn--2scrj9c|xn--3bst00m|xn--3ds443g|xn--3hcrj9c|xn--42c2d9a|xn--45brj9c|xn--55qw42g|xn--6frz82g|xn--80ao21a|xn--9krt00a|xn--cck2b3b|xn--czr694b|xn--d1acj3b|xn--efvy88h|xn--fct429k|xn--fjq720a|xn--flw351e|xn--g2xx48c|xn--gecrj9c|xn--gk3at1e|xn--h2brj9c|xn--hxt814e|xn--imr513n|xn--j6w193g|xn--jvr189m|xn--kprw13d|xn--kpry57d|xn--mgbbh1a|xn--mgbtx2b|xn--mix891f|xn--nyqy26a|xn--otu796d|xn--pgbs0dh|xn--q9jyb4c|xn--rhqv96g|xn--rovu88b|xn--s9brj9c|xn--ses554g|xn--t60b56a|xn--vuq861b|xn--w4rs40l|xn--xhq521b|xn--zfr164b|சிங்கப்பூர்|accountant|apartments|associates|basketball|bnpparibas|boehringer|capitalone|consulting|creditcard|cuisinella|eurovision|extraspace|foundation|healthcare|immobilien|industries|management|mitsubishi|nextdirect|properties|protection|prudential|realestate|republican|restaurant|schaeffler|tatamotors|technology|university|vlaanderen|volkswagen|xn--30rr7y|xn--3pxu8k|xn--45q11c|xn--4gbrim|xn--55qx5d|xn--5tzm5g|xn--80aswg|xn--90a3ac|xn--9dbq2a|xn--9et52u|xn--c2br7g|xn--cg4bki|xn--czrs0t|xn--czru2d|xn--fiq64b|xn--fiqs8s|xn--fiqz9s|xn--io0a7i|xn--kput3i|xn--mxtq1m|xn--o3cw4h|xn--pssy2u|xn--q7ce6a|xn--unup4y|xn--wgbh1c|xn--wgbl6a|xn--y9a3aq|accenture|alfaromeo|allfinanz|amsterdam|analytics|aquarelle|barcelona|bloomberg|christmas|community|directory|education|equipment|fairwinds|financial|firestone|fresenius|frontdoor|furniture|goldpoint|hisamitsu|homedepot|homegoods|homesense|institute|insurance|kuokgroup|lancaster|landrover|lifestyle|marketing|marshalls|melbourne|microsoft|panasonic|passagens|pramerica|richardli|shangrila|solutions|statebank|statefarm|stockholm|travelers|vacations|xn--90ais|xn--c1avg|xn--d1alf|xn--e1a4c|xn--fhbei|xn--j1aef|xn--j1amh|xn--l1acc|xn--ngbrx|xn--nqv7f|xn--p1acf|xn--qxa6a|xn--tckwe|xn--vhquv|yodobashi|موريتانيا|abudhabi|airforce|allstate|attorney|barclays|barefoot|bargains|baseball|boutique|bradesco|broadway|brussels|builders|business|capetown|catering|catholic|cipriani|cityeats|cleaning|clinique|clothing|commbank|computer|delivery|deloitte|democrat|diamonds|discount|discover|download|engineer|ericsson|etisalat|exchange|feedback|fidelity|firmdale|football|frontier|goodyear|grainger|graphics|guardian|hdfcbank|helsinki|holdings|hospital|infiniti|ipiranga|istanbul|jpmorgan|lighting|lundbeck|marriott|maserati|mckinsey|memorial|merckmsd|mortgage|observer|partners|pharmacy|pictures|plumbing|property|redstone|reliance|saarland|samsclub|security|services|shopping|showtime|softbank|software|stcgroup|supplies|training|vanguard|ventures|verisign|woodside|xn--90ae|xn--node|xn--p1ai|xn--qxam|yokohama|السعودية|abogado|academy|agakhan|alibaba|android|athleta|auction|audible|auspost|avianca|banamex|bauhaus|bentley|bestbuy|booking|brother|bugatti|capital|caravan|careers|channel|charity|chintai|citadel|clubmed|college|cologne|comcast|company|compare|contact|cooking|corsica|country|coupons|courses|cricket|cruises|dentist|digital|domains|exposed|express|farmers|fashion|ferrari|ferrero|finance|fishing|fitness|flights|florist|flowers|forsale|frogans|fujitsu|gallery|genting|godaddy|grocery|guitars|hamburg|hangout|hitachi|holiday|hosting|hoteles|hotmail|hyundai|ismaili|jewelry|juniper|kitchen|komatsu|lacaixa|lanxess|lasalle|latrobe|leclerc|limited|lincoln|markets|monster|netbank|netflix|network|neustar|okinawa|oldnavy|organic|origins|philips|pioneer|politie|realtor|recipes|rentals|reviews|rexroth|samsung|sandvik|schmidt|schwarz|science|shiksha|singles|staples|storage|support|surgery|systems|temasek|theater|theatre|tickets|tiffany|toshiba|trading|walmart|wanggou|watches|weather|website|wedding|whoswho|windows|winners|xfinity|yamaxun|youtube|zuerich|католик|اتصالات|البحرين|الجزائر|العليان|پاکستان|كاثوليك|இந்தியா|abarth|abbott|abbvie|africa|agency|airbus|airtel|alipay|alsace|alstom|amazon|anquan|aramco|author|bayern|beauty|berlin|bharti|bostik|boston|broker|camera|career|casino|center|chanel|chrome|church|circle|claims|clinic|coffee|comsec|condos|coupon|credit|cruise|dating|datsun|dealer|degree|dental|design|direct|doctor|dunlop|dupont|durban|emerck|energy|estate|events|expert|family|flickr|futbol|gallup|garden|george|giving|global|google|gratis|health|hermes|hiphop|hockey|hotels|hughes|imamat|insure|intuit|jaguar|joburg|juegos|kaufen|kinder|kindle|kosher|lancia|latino|lawyer|lefrak|living|locker|london|luxury|madrid|maison|makeup|market|mattel|mobile|monash|mormon|moscow|museum|mutual|nagoya|natura|nissan|nissay|norton|nowruz|office|olayan|online|oracle|orange|otsuka|pfizer|photos|physio|pictet|quebec|racing|realty|reisen|repair|report|review|rocher|rogers|ryukyu|safety|sakura|sanofi|school|schule|search|secure|select|shouji|soccer|social|stream|studio|supply|suzuki|swatch|sydney|taipei|taobao|target|tattoo|tennis|tienda|tjmaxx|tkmaxx|toyota|travel|unicom|viajes|viking|villas|virgin|vision|voting|voyage|vuelos|walter|webcam|xihuan|yachts|yandex|zappos|москва|онлайн|ابوظبي|ارامكو|الاردن|المغرب|امارات|فلسطين|مليسيا|भारतम्|இலங்கை|ファッション|actor|adult|aetna|amfam|amica|apple|archi|audio|autos|azure|baidu|beats|bible|bingo|black|boats|bosch|build|canon|cards|chase|cheap|cisco|citic|click|cloud|coach|codes|crown|cymru|dabur|dance|deals|delta|drive|dubai|earth|edeka|email|epson|faith|fedex|final|forex|forum|gallo|games|gifts|gives|glass|globo|gmail|green|gripe|group|gucci|guide|homes|honda|horse|house|hyatt|ikano|irish|jetzt|koeln|kyoto|lamer|lease|legal|lexus|lilly|linde|lipsy|loans|locus|lotte|lotto|macys|mango|media|miami|money|movie|music|nexus|nikon|ninja|nokia|nowtv|omega|osaka|paris|parts|party|phone|photo|pizza|place|poker|praxi|press|prime|promo|quest|radio|rehab|reise|ricoh|rocks|rodeo|rugby|salon|sener|seven|sharp|shell|shoes|skype|sling|smart|smile|solar|space|sport|stada|store|study|style|sucks|swiss|tatar|tires|tirol|tmall|today|tokyo|tools|toray|total|tours|trade|trust|tunes|tushu|ubank|vegas|video|vodka|volvo|wales|watch|weber|weibo|works|world|xerox|yahoo|ישראל|ایران|بازار|بھارت|سودان|سورية|همراه|भारोत|संगठन|বাংলা|భారత్|ഭാരതം|嘉里大酒店|aarp|able|adac|aero|akdn|ally|amex|arab|army|arpa|arte|asda|asia|audi|auto|baby|band|bank|bbva|beer|best|bike|bing|blog|blue|bofa|bond|book|buzz|cafe|call|camp|care|cars|casa|case|cash|cbre|cern|chat|citi|city|club|cool|coop|cyou|data|date|dclk|deal|dell|desi|diet|dish|docs|dvag|erni|fage|fail|fans|farm|fast|fiat|fido|film|fire|fish|flir|food|ford|free|fund|game|gbiz|gent|ggee|gift|gmbh|gold|golf|goog|guge|guru|hair|haus|hdfc|help|here|hgtv|host|hsbc|icbc|ieee|imdb|immo|info|itau|java|jeep|jobs|jprs|kddi|kids|kiwi|kpmg|kred|land|lego|lgbt|lidl|life|like|limo|link|live|loan|loft|love|ltda|luxe|maif|meet|meme|menu|mini|mint|mobi|moda|moto|name|navy|news|next|nico|nike|ollo|open|page|pars|pccw|pics|ping|pink|play|plus|pohl|porn|post|prod|prof|qpon|read|reit|rent|rest|rich|room|rsvp|ruhr|safe|sale|sarl|save|saxo|scot|seat|seek|sexy|shaw|shia|shop|show|silk|sina|site|skin|sncf|sohu|song|sony|spot|star|surf|talk|taxi|team|tech|teva|tiaa|tips|town|toys|tube|vana|visa|viva|vivo|vote|voto|wang|weir|wien|wiki|wine|work|xbox|yoga|zara|zero|zone|дети|сайт|بارت|بيتك|ڀارت|تونس|شبكة|عراق|عمان|موقع|भारत|ভারত|ভাৰত|ਭਾਰਤ|ભારત|ଭାରତ|ಭಾರತ|ලංකා|アマゾン|グーグル|クラウド|ポイント|组织机构|電訊盈科|香格里拉|aaa|abb|abc|aco|ads|aeg|afl|aig|anz|aol|app|art|aws|axa|bar|bbc|bbt|bcg|bcn|bet|bid|bio|biz|bms|bmw|bom|boo|bot|box|buy|bzh|cab|cal|cam|car|cat|cba|cbn|cbs|ceo|cfa|cfd|com|cpa|crs|dad|day|dds|dev|dhl|diy|dnp|dog|dot|dtv|dvr|eat|eco|edu|esq|eus|fan|fit|fly|foo|fox|frl|ftr|fun|fyi|gal|gap|gay|gdn|gea|gle|gmo|gmx|goo|gop|got|gov|hbo|hiv|hkt|hot|how|ibm|ice|icu|ifm|inc|ing|ink|int|ist|itv|jcb|jio|jll|jmp|jnj|jot|joy|kfh|kia|kim|kpn|krd|lat|law|lds|llc|llp|lol|lpl|ltd|man|map|mba|med|men|mil|mit|mlb|mls|mma|moe|moi|mom|mov|msd|mtn|mtr|nab|nba|nec|net|new|nfl|ngo|nhk|now|nra|nrw|ntt|nyc|obi|one|ong|onl|ooo|org|ott|ovh|pay|pet|phd|pid|pin|pnc|pro|pru|pub|pwc|red|ren|ril|rio|rip|run|rwe|sap|sas|sbi|sbs|sca|scb|ses|sew|sex|sfr|ski|sky|soy|spa|srl|stc|tab|tax|tci|tdk|tel|thd|tjx|top|trv|tui|tvs|ubs|uno|uol|ups|vet|vig|vin|vip|wed|win|wme|wow|wtc|wtf|xin|xxx|xyz|you|yun|zip|бел|ком|қаз|мкд|мон|орг|рус|срб|укр|հայ|קום|عرب|قطر|كوم|مصر|कॉम|नेट|คอม|ไทย|ລາວ|ストア|セール|みんな|中文网|亚马逊|天主教|我爱你|新加坡|淡马锡|诺基亚|飞利浦|ac|ad|ae|af|ag|ai|al|am|ao|aq|ar|as|at|au|aw|ax|az|ba|bb|bd|be|bf|bg|bh|bi|bj|bm|bn|bo|br|bs|bt|bv|bw|by|bz|ca|cc|cd|cf|cg|ch|ci|ck|cl|cm|cn|co|cr|cu|cv|cw|cx|cy|cz|de|dj|dk|dm|do|dz|ec|ee|eg|er|es|et|eu|fi|fj|fk|fm|fo|fr|ga|gb|gd|ge|gf|gg|gh|gi|gl|gm|gn|gp|gq|gr|gs|gt|gu|gw|gy|hk|hm|hn|hr|ht|hu|id|ie|il|im|in|io|iq|ir|is|it|je|jm|jo|jp|ke|kg|kh|ki|km|kn|kp|kr|kw|ky|kz|la|lb|lc|li|lk|lr|ls|lt|lu|lv|ly|ma|mc|md|me|mg|mh|mk|ml|mm|mn|mo|mp|mq|mr|ms|mt|mu|mv|mw|mx|my|mz|na|nc|ne|nf|ng|ni|nl|no|np|nr|nu|nz|om|pa|pe|pf|pg|ph|pk|pl|pm|pn|pr|ps|pt|pw|py|qa|re|ro|rs|ru|rw|sa|sb|sc|sd|se|sg|sh|si|sj|sk|sl|sm|sn|so|sr|ss|st|su|sv|sx|sy|sz|tc|td|tf|tg|th|tj|tk|tl|tm|tn|to|tr|tt|tv|tw|tz|ua|ug|uk|us|uy|uz|va|vc|ve|vg|vi|vn|vu|wf|ws|ye|yt|za|zm|zw|ελ|ευ|бг|ею|рф|გე|닷넷|닷컴|삼성|한국|コム|世界|中信|中国|中國|企业|佛山|信息|健康|八卦|公司|公益|台湾|台灣|商城|商店|商标|嘉里|在线|大拿|娱乐|家電|广东|微博|慈善|手机|招聘|政务|政府|新闻|时尚|書籍|机构|游戏|澳門|点看|移动|网址|网店|网站|网络|联通|谷歌|购物|通販|集团|食品|餐厅|香港)/,
- dO = new RegExp('['.concat(aO, "!#$%&'*+/=?^_`{|}~-]")),
- fO = new RegExp('^'.concat(hO.source, '$')),
- mO = (function (s) {
- function EmailMatcher() {
- var o = (null !== s && s.apply(this, arguments)) || this;
- return (o.localPartCharRegex = dO), (o.strictTldRegex = fO), o;
- }
- return (
- tslib_es6_extends(EmailMatcher, s),
- (EmailMatcher.prototype.parseMatches = function (s) {
- for (
- var o = this.tagBuilder,
- i = this.localPartCharRegex,
- u = this.strictTldRegex,
- _ = [],
- w = s.length,
- x = new gO(),
- C = { m: 'a', a: 'i', i: 'l', l: 't', t: 'o', o: ':' },
- j = 0,
- L = 0,
- B = x;
- j < w;
- ) {
- var $ = s.charAt(j);
- switch (L) {
- case 0:
- stateNonEmailAddress($);
- break;
- case 1:
- stateMailTo(s.charAt(j - 1), $);
- break;
- case 2:
- stateLocalPart($);
- break;
- case 3:
- stateLocalPartDot($);
- break;
- case 4:
- stateAtSign($);
- break;
- case 5:
- stateDomainChar($);
- break;
- case 6:
- stateDomainHyphen($);
- break;
- case 7:
- stateDomainDot($);
- break;
- default:
- throwUnhandledCaseError(L);
- }
- j++;
- }
- return captureMatchIfValidAndReset(), _;
- function stateNonEmailAddress(s) {
- 'm' === s ? beginEmailMatch(1) : i.test(s) && beginEmailMatch();
- }
- function stateMailTo(s, o) {
- ':' === s
- ? i.test(o)
- ? ((L = 2), (B = new gO(__assign(__assign({}, B), { hasMailtoPrefix: !0 }))))
- : resetToNonEmailMatchState()
- : C[s] === o ||
- (i.test(o)
- ? (L = 2)
- : '.' === o
- ? (L = 3)
- : '@' === o
- ? (L = 4)
- : resetToNonEmailMatchState());
- }
- function stateLocalPart(s) {
- '.' === s
- ? (L = 3)
- : '@' === s
- ? (L = 4)
- : i.test(s) || resetToNonEmailMatchState();
- }
- function stateLocalPartDot(s) {
- '.' === s || '@' === s
- ? resetToNonEmailMatchState()
- : i.test(s)
- ? (L = 2)
- : resetToNonEmailMatchState();
- }
- function stateAtSign(s) {
- pO.test(s) ? (L = 5) : resetToNonEmailMatchState();
- }
- function stateDomainChar(s) {
- '.' === s
- ? (L = 7)
- : '-' === s
- ? (L = 6)
- : pO.test(s) || captureMatchIfValidAndReset();
- }
- function stateDomainHyphen(s) {
- '-' === s || '.' === s
- ? captureMatchIfValidAndReset()
- : pO.test(s)
- ? (L = 5)
- : captureMatchIfValidAndReset();
- }
- function stateDomainDot(s) {
- '.' === s || '-' === s
- ? captureMatchIfValidAndReset()
- : pO.test(s)
- ? ((L = 5), (B = new gO(__assign(__assign({}, B), { hasDomainDot: !0 }))))
- : captureMatchIfValidAndReset();
- }
- function beginEmailMatch(s) {
- void 0 === s && (s = 2), (L = s), (B = new gO({ idx: j }));
- }
- function resetToNonEmailMatchState() {
- (L = 0), (B = x);
- }
- function captureMatchIfValidAndReset() {
- if (B.hasDomainDot) {
- var i = s.slice(B.idx, j);
- /[-.]$/.test(i) && (i = i.slice(0, -1));
- var w = B.hasMailtoPrefix ? i.slice(7) : i;
- (function doesEmailHaveValidTld(s) {
- var o = s.split('.').pop() || '',
- i = o.toLowerCase();
- return u.test(i);
- })(w) &&
- _.push(new WC({ tagBuilder: o, matchedText: i, offset: B.idx, email: w }));
- }
- resetToNonEmailMatchState();
- }
- }),
- EmailMatcher
- );
- })(YC),
- gO = function gO(s) {
- void 0 === s && (s = {}),
- (this.idx = void 0 !== s.idx ? s.idx : -1),
- (this.hasMailtoPrefix = !!s.hasMailtoPrefix),
- (this.hasDomainDot = !!s.hasDomainDot);
- },
- yO = (function () {
- function UrlMatchValidator() {}
- return (
- (UrlMatchValidator.isValid = function (s, o) {
- return !(
- (o && !this.isValidUriScheme(o)) ||
- this.urlMatchDoesNotHaveProtocolOrDot(s, o) ||
- (this.urlMatchDoesNotHaveAtLeastOneWordChar(s, o) && !this.isValidIpAddress(s)) ||
- this.containsMultipleDots(s)
- );
- }),
- (UrlMatchValidator.isValidIpAddress = function (s) {
- var o = new RegExp(this.hasFullProtocolRegex.source + this.ipRegex.source);
- return null !== s.match(o);
- }),
- (UrlMatchValidator.containsMultipleDots = function (s) {
- var o = s;
- return (
- this.hasFullProtocolRegex.test(s) && (o = s.split('://')[1]),
- o.split('/')[0].indexOf('..') > -1
- );
- }),
- (UrlMatchValidator.isValidUriScheme = function (s) {
- var o = s.match(this.uriSchemeRegex),
- i = o && o[0].toLowerCase();
- return 'javascript:' !== i && 'vbscript:' !== i;
- }),
- (UrlMatchValidator.urlMatchDoesNotHaveProtocolOrDot = function (s, o) {
- return !(!s || (o && this.hasFullProtocolRegex.test(o)) || -1 !== s.indexOf('.'));
- }),
- (UrlMatchValidator.urlMatchDoesNotHaveAtLeastOneWordChar = function (s, o) {
- return (
- !(!s || !o) &&
- !this.hasFullProtocolRegex.test(o) &&
- !this.hasWordCharAfterProtocolRegex.test(s)
- );
- }),
- (UrlMatchValidator.hasFullProtocolRegex = /^[A-Za-z][-.+A-Za-z0-9]*:\/\//),
- (UrlMatchValidator.uriSchemeRegex = /^[A-Za-z][-.+A-Za-z0-9]*:/),
- (UrlMatchValidator.hasWordCharAfterProtocolRegex = new RegExp(
- ':[^\\s]*?[' + nO + ']'
- )),
- (UrlMatchValidator.ipRegex =
- /[0-9][0-9]?[0-9]?\.[0-9][0-9]?[0-9]?\.[0-9][0-9]?[0-9]?\.[0-9][0-9]?[0-9]?(:[0-9]*)?\/?$/),
- UrlMatchValidator
- );
- })(),
- vO =
- ((zC = new RegExp(
- '[/?#](?:[' +
- aO +
- "\\-+&@#/%=~_()|'$*\\[\\]{}?!:,.;^✓]*[" +
- aO +
- "\\-+&@#/%=~_()|'$*\\[\\]{}✓])?"
- )),
- new RegExp(
- [
- '(?:',
- '(',
- /(?:[A-Za-z][-.+A-Za-z0-9]{0,63}:(?![A-Za-z][-.+A-Za-z0-9]{0,63}:\/\/)(?!\d+\/?)(?:\/\/)?)/
- .source,
- getDomainNameStr(2),
- ')',
- '|',
- '(',
- '(//)?',
- /(?:www\.)/.source,
- getDomainNameStr(6),
- ')',
- '|',
- '(',
- '(//)?',
- getDomainNameStr(10) + '\\.',
- hO.source,
- '(?![-' + iO + '])',
- ')',
- ')',
- '(?::[0-9]+)?',
- '(?:' + zC.source + ')?'
- ].join(''),
- 'gi'
- )),
- bO = new RegExp('[' + aO + ']'),
- _O = (function (s) {
- function UrlMatcher(o) {
- var i = s.call(this, o) || this;
- return (
- (i.stripPrefix = { scheme: !0, www: !0 }),
- (i.stripTrailingSlash = !0),
- (i.decodePercentEncoding = !0),
- (i.matcherRegex = vO),
- (i.wordCharRegExp = bO),
- (i.stripPrefix = o.stripPrefix),
- (i.stripTrailingSlash = o.stripTrailingSlash),
- (i.decodePercentEncoding = o.decodePercentEncoding),
- i
- );
- }
- return (
- tslib_es6_extends(UrlMatcher, s),
- (UrlMatcher.prototype.parseMatches = function (s) {
- for (
- var o,
- i = this.matcherRegex,
- u = this.stripPrefix,
- _ = this.stripTrailingSlash,
- w = this.decodePercentEncoding,
- x = this.tagBuilder,
- C = [],
- _loop_1 = function () {
- var i = o[0],
- L = o[1],
- B = o[4],
- $ = o[5],
- V = o[9],
- U = o.index,
- z = $ || V,
- Y = s.charAt(U - 1);
- if (!yO.isValid(i, L)) return 'continue';
- if (U > 0 && '@' === Y) return 'continue';
- if (U > 0 && z && j.wordCharRegExp.test(Y)) return 'continue';
- if (
- (/\?$/.test(i) && (i = i.substr(0, i.length - 1)),
- j.matchHasUnbalancedClosingParen(i))
- )
- i = i.substr(0, i.length - 1);
- else {
- var Z = j.matchHasInvalidCharAfterTld(i, L);
- Z > -1 && (i = i.substr(0, Z));
- }
- var ee = ['http://', 'https://'].find(function (s) {
- return !!L && -1 !== L.indexOf(s);
- });
- if (ee) {
- var ie = i.indexOf(ee);
- (i = i.substr(ie)), (L = L.substr(ie)), (U += ie);
- }
- var ae = L ? 'scheme' : B ? 'www' : 'tld',
- le = !!L;
- C.push(
- new GC({
- tagBuilder: x,
- matchedText: i,
- offset: U,
- urlMatchType: ae,
- url: i,
- protocolUrlMatch: le,
- protocolRelativeMatch: !!z,
- stripPrefix: u,
- stripTrailingSlash: _,
- decodePercentEncoding: w
- })
- );
- },
- j = this;
- null !== (o = i.exec(s));
- )
- _loop_1();
- return C;
- }),
- (UrlMatcher.prototype.matchHasUnbalancedClosingParen = function (s) {
- var o,
- i = s.charAt(s.length - 1);
- if (')' === i) o = '(';
- else if (']' === i) o = '[';
- else {
- if ('}' !== i) return !1;
- o = '{';
- }
- for (var u = 0, _ = 0, w = s.length - 1; _ < w; _++) {
- var x = s.charAt(_);
- x === o ? u++ : x === i && (u = Math.max(u - 1, 0));
- }
- return 0 === u;
- }),
- (UrlMatcher.prototype.matchHasInvalidCharAfterTld = function (s, o) {
- if (!s) return -1;
- var i = 0;
- o && ((i = s.indexOf(':')), (s = s.slice(i)));
- var u = new RegExp('^((.?//)?[-.' + aO + ']*[-' + aO + ']\\.[-' + aO + ']+)').exec(
- s
- );
- return null === u
- ? -1
- : ((i += u[1].length),
- (s = s.slice(u[1].length)),
- /^[^-.A-Za-z0-9:\/?#]/.test(s) ? i : -1);
- }),
- UrlMatcher
- );
- })(YC),
- EO = new RegExp('[_'.concat(aO, ']')),
- wO = (function (s) {
- function HashtagMatcher(o) {
- var i = s.call(this, o) || this;
- return (i.serviceName = 'twitter'), (i.serviceName = o.serviceName), i;
- }
- return (
- tslib_es6_extends(HashtagMatcher, s),
- (HashtagMatcher.prototype.parseMatches = function (s) {
- for (
- var o = this.tagBuilder,
- i = this.serviceName,
- u = [],
- _ = s.length,
- w = 0,
- x = -1,
- C = 0;
- w < _;
- ) {
- var j = s.charAt(w);
- switch (C) {
- case 0:
- stateNone(j);
- break;
- case 1:
- stateNonHashtagWordChar(j);
- break;
- case 2:
- stateHashtagHashChar(j);
- break;
- case 3:
- stateHashtagTextChar(j);
- break;
- default:
- throwUnhandledCaseError(C);
- }
- w++;
- }
- return captureMatchIfValid(), u;
- function stateNone(s) {
- '#' === s ? ((C = 2), (x = w)) : lO.test(s) && (C = 1);
- }
- function stateNonHashtagWordChar(s) {
- lO.test(s) || (C = 0);
- }
- function stateHashtagHashChar(s) {
- C = EO.test(s) ? 3 : lO.test(s) ? 1 : 0;
- }
- function stateHashtagTextChar(s) {
- EO.test(s) || (captureMatchIfValid(), (x = -1), (C = lO.test(s) ? 1 : 0));
- }
- function captureMatchIfValid() {
- if (x > -1 && w - x <= 140) {
- var _ = s.slice(x, w),
- C = new KC({
- tagBuilder: o,
- matchedText: _,
- offset: x,
- serviceName: i,
- hashtag: _.slice(1)
- });
- u.push(C);
- }
- }
- }),
- HashtagMatcher
- );
- })(YC),
- SO = ['twitter', 'facebook', 'instagram', 'tiktok'],
- xO = new RegExp(
- ''
- .concat(
- /(?:(?:(?:(\+)?\d{1,3}[-\040.]?)?\(?\d{3}\)?[-\040.]?\d{3}[-\040.]?\d{4})|(?:(\+)(?:9[976]\d|8[987530]\d|6[987]\d|5[90]\d|42\d|3[875]\d|2[98654321]\d|9[8543210]|8[6421]|6[6543210]|5[87654321]|4[987654310]|3[9643210]|2[70]|7|1)[-\040.]?(?:\d[-\040.]?){6,12}\d+))([,;]+[0-9]+#?)*/
- .source,
- '|'
- )
- .concat(
- /(0([1-9]{1}-?[1-9]\d{3}|[1-9]{2}-?\d{3}|[1-9]{2}\d{1}-?\d{2}|[1-9]{2}\d{2}-?\d{1})-?\d{4}|0[789]0-?\d{4}-?\d{4}|050-?\d{4}-?\d{4})/
- .source
- ),
- 'g'
- ),
- kO = (function (s) {
- function PhoneMatcher() {
- var o = (null !== s && s.apply(this, arguments)) || this;
- return (o.matcherRegex = xO), o;
- }
- return (
- tslib_es6_extends(PhoneMatcher, s),
- (PhoneMatcher.prototype.parseMatches = function (s) {
- for (
- var o, i = this.matcherRegex, u = this.tagBuilder, _ = [];
- null !== (o = i.exec(s));
- ) {
- var w = o[0],
- x = w.replace(/[^0-9,;#]/g, ''),
- C = !(!o[1] && !o[2]),
- j = 0 == o.index ? '' : s.substr(o.index - 1, 1),
- L = s.substr(o.index + w.length, 1),
- B = !j.match(/\d/) && !L.match(/\d/);
- this.testMatch(o[3]) &&
- this.testMatch(w) &&
- B &&
- _.push(
- new JC({
- tagBuilder: u,
- matchedText: w,
- offset: o.index,
- number: x,
- plusSign: C
- })
- );
- }
- return _;
- }),
- (PhoneMatcher.prototype.testMatch = function (s) {
- return QC.test(s);
- }),
- PhoneMatcher
- );
- })(YC),
- CO = new RegExp('@[_'.concat(aO, ']{1,50}(?![_').concat(aO, '])'), 'g'),
- OO = new RegExp('@[_.'.concat(aO, ']{1,30}(?![_').concat(aO, '])'), 'g'),
- AO = new RegExp('@[-_.'.concat(aO, ']{1,50}(?![-_').concat(aO, '])'), 'g'),
- jO = new RegExp(
- '@[_.'.concat(aO, ']{1,23}[_').concat(aO, '](?![_').concat(aO, '])'),
- 'g'
- ),
- IO = new RegExp('[^' + aO + ']'),
- PO = (function (s) {
- function MentionMatcher(o) {
- var i = s.call(this, o) || this;
- return (
- (i.serviceName = 'twitter'),
- (i.matcherRegexes = { twitter: CO, instagram: OO, soundcloud: AO, tiktok: jO }),
- (i.nonWordCharRegex = IO),
- (i.serviceName = o.serviceName),
- i
- );
- }
- return (
- tslib_es6_extends(MentionMatcher, s),
- (MentionMatcher.prototype.parseMatches = function (s) {
- var o,
- i = this.serviceName,
- u = this.matcherRegexes[this.serviceName],
- _ = this.nonWordCharRegex,
- w = this.tagBuilder,
- x = [];
- if (!u) return x;
- for (; null !== (o = u.exec(s)); ) {
- var C = o.index,
- j = s.charAt(C - 1);
- if (0 === C || _.test(j)) {
- var L = o[0].replace(/\.+$/g, ''),
- B = L.slice(1);
- x.push(
- new HC({
- tagBuilder: w,
- matchedText: L,
- offset: C,
- serviceName: i,
- mention: B
- })
- );
- }
- }
- return x;
- }),
- MentionMatcher
- );
- })(YC);
- function parseHtml(s, o) {
- for (
- var i = o.onOpenTag,
- u = o.onCloseTag,
- _ = o.onText,
- w = o.onComment,
- x = o.onDoctype,
- C = new MO(),
- j = 0,
- L = s.length,
- B = 0,
- $ = 0,
- V = C;
- j < L;
- ) {
- var U = s.charAt(j);
- switch (B) {
- case 0:
- stateData(U);
- break;
- case 1:
- stateTagOpen(U);
- break;
- case 2:
- stateEndTagOpen(U);
- break;
- case 3:
- stateTagName(U);
- break;
- case 4:
- stateBeforeAttributeName(U);
- break;
- case 5:
- stateAttributeName(U);
- break;
- case 6:
- stateAfterAttributeName(U);
- break;
- case 7:
- stateBeforeAttributeValue(U);
- break;
- case 8:
- stateAttributeValueDoubleQuoted(U);
- break;
- case 9:
- stateAttributeValueSingleQuoted(U);
- break;
- case 10:
- stateAttributeValueUnquoted(U);
- break;
- case 11:
- stateAfterAttributeValueQuoted(U);
- break;
- case 12:
- stateSelfClosingStartTag(U);
- break;
- case 13:
- stateMarkupDeclarationOpen(U);
- break;
- case 14:
- stateCommentStart(U);
- break;
- case 15:
- stateCommentStartDash(U);
- break;
- case 16:
- stateComment(U);
- break;
- case 17:
- stateCommentEndDash(U);
- break;
- case 18:
- stateCommentEnd(U);
- break;
- case 19:
- stateCommentEndBang(U);
- break;
- case 20:
- stateDoctype(U);
- break;
- default:
- throwUnhandledCaseError(B);
- }
- j++;
- }
- function stateData(s) {
- '<' === s && startNewTag();
- }
- function stateTagOpen(s) {
- '!' === s
- ? (B = 13)
- : '/' === s
- ? ((B = 2), (V = new MO(__assign(__assign({}, V), { isClosing: !0 }))))
- : '<' === s
- ? startNewTag()
- : XC.test(s)
- ? ((B = 3), (V = new MO(__assign(__assign({}, V), { isOpening: !0 }))))
- : ((B = 0), (V = C));
- }
- function stateTagName(s) {
- eO.test(s)
- ? ((V = new MO(__assign(__assign({}, V), { name: captureTagName() }))), (B = 4))
- : '<' === s
- ? startNewTag()
- : '/' === s
- ? ((V = new MO(__assign(__assign({}, V), { name: captureTagName() }))), (B = 12))
- : '>' === s
- ? ((V = new MO(__assign(__assign({}, V), { name: captureTagName() }))),
- emitTagAndPreviousTextNode())
- : XC.test(s) || ZC.test(s) || ':' === s || resetToDataState();
- }
- function stateEndTagOpen(s) {
- '>' === s ? resetToDataState() : XC.test(s) ? (B = 3) : resetToDataState();
- }
- function stateBeforeAttributeName(s) {
- eO.test(s) ||
- ('/' === s
- ? (B = 12)
- : '>' === s
- ? emitTagAndPreviousTextNode()
- : '<' === s
- ? startNewTag()
- : '=' === s || tO.test(s) || rO.test(s)
- ? resetToDataState()
- : (B = 5));
- }
- function stateAttributeName(s) {
- eO.test(s)
- ? (B = 6)
- : '/' === s
- ? (B = 12)
- : '=' === s
- ? (B = 7)
- : '>' === s
- ? emitTagAndPreviousTextNode()
- : '<' === s
- ? startNewTag()
- : tO.test(s) && resetToDataState();
- }
- function stateAfterAttributeName(s) {
- eO.test(s) ||
- ('/' === s
- ? (B = 12)
- : '=' === s
- ? (B = 7)
- : '>' === s
- ? emitTagAndPreviousTextNode()
- : '<' === s
- ? startNewTag()
- : tO.test(s)
- ? resetToDataState()
- : (B = 5));
- }
- function stateBeforeAttributeValue(s) {
- eO.test(s) ||
- ('"' === s
- ? (B = 8)
- : "'" === s
- ? (B = 9)
- : /[>=`]/.test(s)
- ? resetToDataState()
- : '<' === s
- ? startNewTag()
- : (B = 10));
- }
- function stateAttributeValueDoubleQuoted(s) {
- '"' === s && (B = 11);
- }
- function stateAttributeValueSingleQuoted(s) {
- "'" === s && (B = 11);
- }
- function stateAttributeValueUnquoted(s) {
- eO.test(s)
- ? (B = 4)
- : '>' === s
- ? emitTagAndPreviousTextNode()
- : '<' === s && startNewTag();
- }
- function stateAfterAttributeValueQuoted(s) {
- eO.test(s)
- ? (B = 4)
- : '/' === s
- ? (B = 12)
- : '>' === s
- ? emitTagAndPreviousTextNode()
- : '<' === s
- ? startNewTag()
- : ((B = 4),
- (function reconsumeCurrentCharacter() {
- j--;
- })());
- }
- function stateSelfClosingStartTag(s) {
- '>' === s
- ? ((V = new MO(__assign(__assign({}, V), { isClosing: !0 }))),
- emitTagAndPreviousTextNode())
- : (B = 4);
- }
- function stateMarkupDeclarationOpen(o) {
- '--' === s.substr(j, 2)
- ? ((j += 2), (V = new MO(__assign(__assign({}, V), { type: 'comment' }))), (B = 14))
- : 'DOCTYPE' === s.substr(j, 7).toUpperCase()
- ? ((j += 7), (V = new MO(__assign(__assign({}, V), { type: 'doctype' }))), (B = 20))
- : resetToDataState();
- }
- function stateCommentStart(s) {
- '-' === s ? (B = 15) : '>' === s ? resetToDataState() : (B = 16);
- }
- function stateCommentStartDash(s) {
- '-' === s ? (B = 18) : '>' === s ? resetToDataState() : (B = 16);
- }
- function stateComment(s) {
- '-' === s && (B = 17);
- }
- function stateCommentEndDash(s) {
- B = '-' === s ? 18 : 16;
- }
- function stateCommentEnd(s) {
- '>' === s ? emitTagAndPreviousTextNode() : '!' === s ? (B = 19) : '-' === s || (B = 16);
- }
- function stateCommentEndBang(s) {
- '-' === s ? (B = 17) : '>' === s ? emitTagAndPreviousTextNode() : (B = 16);
- }
- function stateDoctype(s) {
- '>' === s ? emitTagAndPreviousTextNode() : '<' === s && startNewTag();
- }
- function resetToDataState() {
- (B = 0), (V = C);
- }
- function startNewTag() {
- (B = 1), (V = new MO({ idx: j }));
- }
- function emitTagAndPreviousTextNode() {
- var o = s.slice($, V.idx);
- o && _(o, $),
- 'comment' === V.type
- ? w(V.idx)
- : 'doctype' === V.type
- ? x(V.idx)
- : (V.isOpening && i(V.name, V.idx), V.isClosing && u(V.name, V.idx)),
- resetToDataState(),
- ($ = j + 1);
- }
- function captureTagName() {
- var o = V.idx + (V.isClosing ? 2 : 1);
- return s.slice(o, j).toLowerCase();
- }
- $ < j &&
- (function emitText() {
- var o = s.slice($, j);
- _(o, $), ($ = j + 1);
- })();
- }
- var MO = function MO(s) {
- void 0 === s && (s = {}),
- (this.idx = void 0 !== s.idx ? s.idx : -1),
- (this.type = s.type || 'tag'),
- (this.name = s.name || ''),
- (this.isOpening = !!s.isOpening),
- (this.isClosing = !!s.isClosing);
- },
- TO = (function () {
- function Autolinker(s) {
- void 0 === s && (s = {}),
- (this.version = Autolinker.version),
- (this.urls = {}),
- (this.email = !0),
- (this.phone = !0),
- (this.hashtag = !1),
- (this.mention = !1),
- (this.newWindow = !0),
- (this.stripPrefix = { scheme: !0, www: !0 }),
- (this.stripTrailingSlash = !0),
- (this.decodePercentEncoding = !0),
- (this.truncate = { length: 0, location: 'end' }),
- (this.className = ''),
- (this.replaceFn = null),
- (this.context = void 0),
- (this.sanitizeHtml = !1),
- (this.matchers = null),
- (this.tagBuilder = null),
- (this.urls = this.normalizeUrlsCfg(s.urls)),
- (this.email = 'boolean' == typeof s.email ? s.email : this.email),
- (this.phone = 'boolean' == typeof s.phone ? s.phone : this.phone),
- (this.hashtag = s.hashtag || this.hashtag),
- (this.mention = s.mention || this.mention),
- (this.newWindow = 'boolean' == typeof s.newWindow ? s.newWindow : this.newWindow),
- (this.stripPrefix = this.normalizeStripPrefixCfg(s.stripPrefix)),
- (this.stripTrailingSlash =
- 'boolean' == typeof s.stripTrailingSlash
- ? s.stripTrailingSlash
- : this.stripTrailingSlash),
- (this.decodePercentEncoding =
- 'boolean' == typeof s.decodePercentEncoding
- ? s.decodePercentEncoding
- : this.decodePercentEncoding),
- (this.sanitizeHtml = s.sanitizeHtml || !1);
- var o = this.mention;
- if (!1 !== o && -1 === ['twitter', 'instagram', 'soundcloud', 'tiktok'].indexOf(o))
- throw new Error("invalid `mention` cfg '".concat(o, "' - see docs"));
- var i = this.hashtag;
- if (!1 !== i && -1 === SO.indexOf(i))
- throw new Error("invalid `hashtag` cfg '".concat(i, "' - see docs"));
- (this.truncate = this.normalizeTruncateCfg(s.truncate)),
- (this.className = s.className || this.className),
- (this.replaceFn = s.replaceFn || this.replaceFn),
- (this.context = s.context || this);
- }
- return (
- (Autolinker.link = function (s, o) {
- return new Autolinker(o).link(s);
- }),
- (Autolinker.parse = function (s, o) {
- return new Autolinker(o).parse(s);
- }),
- (Autolinker.prototype.normalizeUrlsCfg = function (s) {
- return (
- null == s && (s = !0),
- 'boolean' == typeof s
- ? { schemeMatches: s, wwwMatches: s, tldMatches: s }
- : {
- schemeMatches: 'boolean' != typeof s.schemeMatches || s.schemeMatches,
- wwwMatches: 'boolean' != typeof s.wwwMatches || s.wwwMatches,
- tldMatches: 'boolean' != typeof s.tldMatches || s.tldMatches
- }
- );
- }),
- (Autolinker.prototype.normalizeStripPrefixCfg = function (s) {
- return (
- null == s && (s = !0),
- 'boolean' == typeof s
- ? { scheme: s, www: s }
- : {
- scheme: 'boolean' != typeof s.scheme || s.scheme,
- www: 'boolean' != typeof s.www || s.www
- }
- );
- }),
- (Autolinker.prototype.normalizeTruncateCfg = function (s) {
- return 'number' == typeof s
- ? { length: s, location: 'end' }
- : (function defaults(s, o) {
- for (var i in o) o.hasOwnProperty(i) && void 0 === s[i] && (s[i] = o[i]);
- return s;
- })(s || {}, { length: Number.POSITIVE_INFINITY, location: 'end' });
- }),
- (Autolinker.prototype.parse = function (s) {
- var o = this,
- i = ['a', 'style', 'script'],
- u = 0,
- _ = [];
- return (
- parseHtml(s, {
- onOpenTag: function (s) {
- i.indexOf(s) >= 0 && u++;
- },
- onText: function (s, i) {
- if (0 === u) {
- var w = (function splitAndCapture(s, o) {
- if (!o.global)
- throw new Error("`splitRegex` must have the 'g' flag set");
- for (var i, u = [], _ = 0; (i = o.exec(s)); )
- u.push(s.substring(_, i.index)),
- u.push(i[0]),
- (_ = i.index + i[0].length);
- return u.push(s.substring(_)), u;
- })(s, /( | |<|<|>|>|"|"|')/gi),
- x = i;
- w.forEach(function (s, i) {
- if (i % 2 == 0) {
- var u = o.parseText(s, x);
- _.push.apply(_, u);
- }
- x += s.length;
- });
- }
- },
- onCloseTag: function (s) {
- i.indexOf(s) >= 0 && (u = Math.max(u - 1, 0));
- },
- onComment: function (s) {},
- onDoctype: function (s) {}
- }),
- (_ = this.compactMatches(_)),
- (_ = this.removeUnwantedMatches(_))
- );
- }),
- (Autolinker.prototype.compactMatches = function (s) {
- s.sort(function (s, o) {
- return s.getOffset() - o.getOffset();
- });
- for (var o = 0; o < s.length - 1; ) {
- var i = s[o],
- u = i.getOffset(),
- _ = i.getMatchedText().length,
- w = u + _;
- if (o + 1 < s.length) {
- if (s[o + 1].getOffset() === u) {
- var x = s[o + 1].getMatchedText().length > _ ? o : o + 1;
- s.splice(x, 1);
- continue;
- }
- if (s[o + 1].getOffset() < w) {
- s.splice(o + 1, 1);
- continue;
- }
- }
- o++;
- }
- return s;
- }),
- (Autolinker.prototype.removeUnwantedMatches = function (s) {
- return (
- this.hashtag ||
- utils_remove(s, function (s) {
- return 'hashtag' === s.getType();
- }),
- this.email ||
- utils_remove(s, function (s) {
- return 'email' === s.getType();
- }),
- this.phone ||
- utils_remove(s, function (s) {
- return 'phone' === s.getType();
- }),
- this.mention ||
- utils_remove(s, function (s) {
- return 'mention' === s.getType();
- }),
- this.urls.schemeMatches ||
- utils_remove(s, function (s) {
- return 'url' === s.getType() && 'scheme' === s.getUrlMatchType();
- }),
- this.urls.wwwMatches ||
- utils_remove(s, function (s) {
- return 'url' === s.getType() && 'www' === s.getUrlMatchType();
- }),
- this.urls.tldMatches ||
- utils_remove(s, function (s) {
- return 'url' === s.getType() && 'tld' === s.getUrlMatchType();
- }),
- s
- );
- }),
- (Autolinker.prototype.parseText = function (s, o) {
- void 0 === o && (o = 0), (o = o || 0);
- for (var i = this.getMatchers(), u = [], _ = 0, w = i.length; _ < w; _++) {
- for (var x = i[_].parseMatches(s), C = 0, j = x.length; C < j; C++)
- x[C].setOffset(o + x[C].getOffset());
- u.push.apply(u, x);
- }
- return u;
- }),
- (Autolinker.prototype.link = function (s) {
- if (!s) return '';
- this.sanitizeHtml && (s = s.replace(/</g, '<').replace(/>/g, '>'));
- for (var o = this.parse(s), i = [], u = 0, _ = 0, w = o.length; _ < w; _++) {
- var x = o[_];
- i.push(s.substring(u, x.getOffset())),
- i.push(this.createMatchReturnVal(x)),
- (u = x.getOffset() + x.getMatchedText().length);
- }
- return i.push(s.substring(u)), i.join('');
- }),
- (Autolinker.prototype.createMatchReturnVal = function (s) {
- var o;
- return (
- this.replaceFn && (o = this.replaceFn.call(this.context, s)),
- 'string' == typeof o
- ? o
- : !1 === o
- ? s.getMatchedText()
- : o instanceof $C
- ? o.toAnchorString()
- : s.buildTag().toAnchorString()
- );
- }),
- (Autolinker.prototype.getMatchers = function () {
- if (this.matchers) return this.matchers;
- var s = this.getTagBuilder(),
- o = [
- new wO({ tagBuilder: s, serviceName: this.hashtag }),
- new mO({ tagBuilder: s }),
- new kO({ tagBuilder: s }),
- new PO({ tagBuilder: s, serviceName: this.mention }),
- new _O({
- tagBuilder: s,
- stripPrefix: this.stripPrefix,
- stripTrailingSlash: this.stripTrailingSlash,
- decodePercentEncoding: this.decodePercentEncoding
- })
- ];
- return (this.matchers = o);
- }),
- (Autolinker.prototype.getTagBuilder = function () {
- var s = this.tagBuilder;
- return (
- s ||
- (s = this.tagBuilder =
- new VC({
- newWindow: this.newWindow,
- truncate: this.truncate,
- className: this.className
- })),
- s
- );
- }),
- (Autolinker.version = '3.16.2'),
- (Autolinker.AnchorTagBuilder = VC),
- (Autolinker.HtmlTag = $C),
- (Autolinker.matcher = {
- Email: mO,
- Hashtag: wO,
- Matcher: YC,
- Mention: PO,
- Phone: kO,
- Url: _O
- }),
- (Autolinker.match = {
- Email: WC,
- Hashtag: KC,
- Match: UC,
- Mention: HC,
- Phone: JC,
- Url: GC
- }),
- Autolinker
- );
- })();
- const NO = TO;
- var RO = /www|@|\:\/\//;
- function isLinkOpen(s) {
- return /^<a[>\s]/i.test(s);
- }
- function isLinkClose(s) {
- return /^<\/a\s*>/i.test(s);
- }
- function createLinkifier() {
- var s = [],
- o = new NO({
- stripPrefix: !1,
- url: !0,
- email: !0,
- replaceFn: function (o) {
- switch (o.getType()) {
- case 'url':
- s.push({ text: o.matchedText, url: o.getUrl() });
- break;
- case 'email':
- s.push({
- text: o.matchedText,
- url: 'mailto:' + o.getEmail().replace(/^mailto:/i, '')
- });
- }
- return !1;
- }
- });
- return { links: s, autolinker: o };
- }
- function parseTokens(s) {
- var o,
- i,
- u,
- _,
- w,
- x,
- C,
- j,
- L,
- B,
- $,
- V,
- U,
- z = s.tokens,
- Y = null;
- for (i = 0, u = z.length; i < u; i++)
- if ('inline' === z[i].type)
- for ($ = 0, o = (_ = z[i].children).length - 1; o >= 0; o--)
- if ('link_close' !== (w = _[o]).type) {
- if (
- ('htmltag' === w.type &&
- (isLinkOpen(w.content) && $ > 0 && $--, isLinkClose(w.content) && $++),
- !($ > 0) && 'text' === w.type && RO.test(w.content))
- ) {
- if (
- (Y || ((V = (Y = createLinkifier()).links), (U = Y.autolinker)),
- (x = w.content),
- (V.length = 0),
- U.link(x),
- !V.length)
- )
- continue;
- for (C = [], B = w.level, j = 0; j < V.length; j++)
- s.inline.validateLink(V[j].url) &&
- ((L = x.indexOf(V[j].text)) &&
- C.push({ type: 'text', content: x.slice(0, L), level: B }),
- C.push({ type: 'link_open', href: V[j].url, title: '', level: B++ }),
- C.push({ type: 'text', content: V[j].text, level: B }),
- C.push({ type: 'link_close', level: --B }),
- (x = x.slice(L + V[j].text.length)));
- x.length && C.push({ type: 'text', content: x, level: B }),
- (z[i].children = _ = [].concat(_.slice(0, o), C, _.slice(o + 1)));
- }
- } else for (o--; _[o].level !== w.level && 'link_open' !== _[o].type; ) o--;
- }
- function linkify(s) {
- s.core.ruler.push('linkify', parseTokens);
- }
- var DO = __webpack_require__(42838),
- LO = __webpack_require__.n(DO);
- LO().addHook &&
- LO().addHook('beforeSanitizeElements', function (s) {
- return s.href && s.setAttribute('rel', 'noopener noreferrer'), s;
- });
- const BO = function Markdown({
- source: s,
- className: o = '',
- getConfigs: i = () => ({ useUnsafeMarkdown: !1 })
- }) {
- if ('string' != typeof s) return null;
- const u = new Remarkable({
- html: !0,
- typographer: !0,
- breaks: !0,
- linkTarget: '_blank'
- }).use(linkify);
- u.core.ruler.disable(['replacements', 'smartquotes']);
- const { useUnsafeMarkdown: _ } = i(),
- w = u.render(s),
- x = sanitizer(w, { useUnsafeMarkdown: _ });
- return s && w && x
- ? Pe.createElement('div', {
- className: Hn()(o, 'markdown'),
- dangerouslySetInnerHTML: { __html: x }
- })
- : null;
- };
- function sanitizer(s, { useUnsafeMarkdown: o = !1 } = {}) {
- const i = o,
- u = o ? [] : ['style', 'class'];
- return (
- o &&
- !sanitizer.hasWarnedAboutDeprecation &&
- (console.warn(
- 'useUnsafeMarkdown display configuration parameter is deprecated since >3.26.0 and will be removed in v4.0.0.'
- ),
- (sanitizer.hasWarnedAboutDeprecation = !0)),
- LO().sanitize(s, {
- ADD_ATTR: ['target'],
- FORBID_TAGS: ['style', 'form'],
- ALLOW_DATA_ATTR: i,
- FORBID_ATTR: u
- })
- );
- }
- sanitizer.hasWarnedAboutDeprecation = !1;
- class BaseLayout extends Pe.Component {
- render() {
- const { errSelectors: s, specSelectors: o, getComponent: i } = this.props,
- u = i('SvgAssets'),
- _ = i('InfoContainer', !0),
- w = i('VersionPragmaFilter'),
- x = i('operations', !0),
- C = i('Models', !0),
- j = i('Webhooks', !0),
- L = i('Row'),
- B = i('Col'),
- $ = i('errors', !0),
- V = i('ServersContainer', !0),
- U = i('SchemesContainer', !0),
- z = i('AuthorizeBtnContainer', !0),
- Y = i('FilterContainer', !0),
- Z = o.isSwagger2(),
- ee = o.isOAS3(),
- ie = o.isOAS31(),
- ae = !o.specStr(),
- le = o.loadingStatus();
- let ce = null;
- if (
- ('loading' === le &&
- (ce = Pe.createElement(
- 'div',
- { className: 'info' },
- Pe.createElement(
- 'div',
- { className: 'loading-container' },
- Pe.createElement('div', { className: 'loading' })
- )
- )),
- 'failed' === le &&
- (ce = Pe.createElement(
- 'div',
- { className: 'info' },
- Pe.createElement(
- 'div',
- { className: 'loading-container' },
- Pe.createElement(
- 'h4',
- { className: 'title' },
- 'Failed to load API definition.'
- ),
- Pe.createElement($, null)
- )
- )),
- 'failedConfig' === le)
- ) {
- const o = s.lastError(),
- i = o ? o.get('message') : '';
- ce = Pe.createElement(
- 'div',
- { className: 'info failed-config' },
- Pe.createElement(
- 'div',
- { className: 'loading-container' },
- Pe.createElement(
- 'h4',
- { className: 'title' },
- 'Failed to load remote configuration.'
- ),
- Pe.createElement('p', null, i)
- )
- );
- }
- if (
- (!ce && ae && (ce = Pe.createElement('h4', null, 'No API definition provided.')), ce)
- )
- return Pe.createElement(
- 'div',
- { className: 'swagger-ui' },
- Pe.createElement('div', { className: 'loading-container' }, ce)
- );
- const pe = o.servers(),
- de = o.schemes(),
- fe = pe && pe.size,
- ye = de && de.size,
- be = !!o.securityDefinitions();
- return Pe.createElement(
- 'div',
- { className: 'swagger-ui' },
- Pe.createElement(u, null),
- Pe.createElement(
- w,
- { isSwagger2: Z, isOAS3: ee, alsoShow: Pe.createElement($, null) },
- Pe.createElement($, null),
- Pe.createElement(
- L,
- { className: 'information-container' },
- Pe.createElement(B, { mobile: 12 }, Pe.createElement(_, null))
- ),
- fe || ye || be
- ? Pe.createElement(
- 'div',
- { className: 'scheme-container' },
- Pe.createElement(
- B,
- { className: 'schemes wrapper', mobile: 12 },
- fe || ye
- ? Pe.createElement(
- 'div',
- { className: 'schemes-server-container' },
- fe ? Pe.createElement(V, null) : null,
- ye ? Pe.createElement(U, null) : null
- )
- : null,
- be ? Pe.createElement(z, null) : null
- )
- )
- : null,
- Pe.createElement(Y, null),
- Pe.createElement(
- L,
- null,
- Pe.createElement(B, { mobile: 12, desktop: 12 }, Pe.createElement(x, null))
- ),
- ie &&
- Pe.createElement(
- L,
- { className: 'webhooks-container' },
- Pe.createElement(B, { mobile: 12, desktop: 12 }, Pe.createElement(j, null))
- ),
- Pe.createElement(
- L,
- null,
- Pe.createElement(B, { mobile: 12, desktop: 12 }, Pe.createElement(C, null))
- )
- )
- );
- }
- }
- const core_components = () => ({
- components: {
- App: fk,
- authorizationPopup: AuthorizationPopup,
- authorizeBtn: AuthorizeBtn,
- AuthorizeBtnContainer,
- authorizeOperationBtn: AuthorizeOperationBtn,
- auths: Auths,
- AuthItem: auth_item_Auths,
- authError: AuthError,
- oauth2: Oauth2,
- apiKeyAuth: ApiKeyAuth,
- basicAuth: BasicAuth,
- clear: Clear,
- liveResponse: LiveResponse,
- InitializedInput,
- info: qk,
- InfoContainer,
- InfoUrl,
- InfoBasePath,
- Contact: Vk,
- License: zk,
- JumpToPath,
- CopyToClipboardBtn,
- onlineValidatorBadge: OnlineValidatorBadge,
- operations: Operations,
- operation: operation_Operation,
- OperationSummary,
- OperationSummaryMethod,
- OperationSummaryPath,
- responses: responses_Responses,
- response: response_Response,
- ResponseExtension: response_extension,
- responseBody: ResponseBody,
- parameters: Parameters,
- parameterRow: ParameterRow,
- execute: Execute,
- headers: headers_Headers,
- errors: Errors,
- contentType: ContentType,
- overview: Overview,
- footer: Footer,
- FilterContainer,
- ParamBody,
- curl: Curl,
- Property: property,
- TryItOutButton,
- Markdown: BO,
- BaseLayout,
- VersionPragmaFilter,
- VersionStamp: version_stamp,
- OperationExt: operation_extensions,
- OperationExtRow: operation_extension_row,
- ParameterExt: parameter_extension,
- ParameterIncludeEmpty,
- OperationTag,
- OperationContainer,
- OpenAPIVersion: openapi_version,
- DeepLink: deep_link,
- SvgAssets: svg_assets,
- Example: example_Example,
- ExamplesSelect,
- ExamplesSelectValueRetainer
- }
- }),
- form_components = () => ({ components: { ...ye } }),
- base = () => [
- configsPlugin,
- util,
- logs,
- view,
- view_legacy,
- plugins_spec,
- err,
- icons,
- plugins_layout,
- json_schema_5,
- json_schema_5_samples,
- core_components,
- form_components,
- swagger_client,
- auth,
- downloadUrlPlugin,
- deep_linking,
- filter,
- on_complete,
- plugins_request_snippets,
- syntax_highlighting,
- versions,
- safe_render()
- ],
- FO = (0, qe.Map)();
- function onlyOAS3(s) {
- return (o, i) =>
- (...u) => {
- if (i.getSystem().specSelectors.isOAS3()) {
- const o = s(...u);
- return 'function' == typeof o ? o(i) : o;
- }
- return o(...u);
- };
- }
- const qO = onlyOAS3(Ss()(null)),
- $O = onlyOAS3((s, o) => (s) => s.getSystem().specSelectors.findSchema(o)),
- VO = onlyOAS3(() => (s) => {
- const o = s.getSystem().specSelectors.specJson().getIn(['components', 'schemas']);
- return qe.Map.isMap(o) ? o : FO;
- }),
- UO = onlyOAS3(() => (s) => s.getSystem().specSelectors.specJson().hasIn(['servers', 0])),
- zO = onlyOAS3(Ut(Ms, (s) => s.getIn(['components', 'securitySchemes']) || null)),
- wrap_selectors_validOperationMethods =
- (s, o) =>
- (i, ...u) =>
- o.specSelectors.isOAS3() ? o.oas3Selectors.validOperationMethods() : s(...u),
- WO = qO,
- KO = qO,
- HO = qO,
- JO = qO,
- GO = qO;
- const YO = (function wrap_selectors_onlyOAS3(s) {
- return (o, i) =>
- (...u) => {
- if (i.getSystem().specSelectors.isOAS3()) {
- let o = i
- .getState()
- .getIn(['spec', 'resolvedSubtrees', 'components', 'securitySchemes']);
- return s(i, o, ...u);
- }
- return o(...u);
- };
- })(
- Ut(
- (s) => s,
- ({ specSelectors: s }) => s.securityDefinitions(),
- (s, o) => {
- let i = (0, qe.List)();
- return o
- ? (o.entrySeq().forEach(([s, o]) => {
- const u = o.get('type');
- if (
- ('oauth2' === u &&
- o
- .get('flows')
- .entrySeq()
- .forEach(([u, _]) => {
- let w = (0, qe.fromJS)({
- flow: u,
- authorizationUrl: _.get('authorizationUrl'),
- tokenUrl: _.get('tokenUrl'),
- scopes: _.get('scopes'),
- type: o.get('type'),
- description: o.get('description')
- });
- i = i.push(new qe.Map({ [s]: w.filter((s) => void 0 !== s) }));
- }),
- ('http' !== u && 'apiKey' !== u) || (i = i.push(new qe.Map({ [s]: o }))),
- 'openIdConnect' === u && o.get('openIdConnectData'))
- ) {
- let u = o.get('openIdConnectData');
- (
- u.get('grant_types_supported') || ['authorization_code', 'implicit']
- ).forEach((_) => {
- let w =
- u.get('scopes_supported') &&
- u.get('scopes_supported').reduce((s, o) => s.set(o, ''), new qe.Map()),
- x = (0, qe.fromJS)({
- flow: _,
- authorizationUrl: u.get('authorization_endpoint'),
- tokenUrl: u.get('token_endpoint'),
- scopes: w,
- type: 'oauth2',
- openIdConnectUrl: o.get('openIdConnectUrl')
- });
- i = i.push(new qe.Map({ [s]: x.filter((s) => void 0 !== s) }));
- });
- }
- }),
- i)
- : i;
- }
- )
- );
- function OAS3ComponentWrapFactory(s) {
- return (o, i) => (u) =>
- 'function' == typeof i.specSelectors?.isOAS3
- ? i.specSelectors.isOAS3()
- ? Pe.createElement(s, Rn()({}, u, i, { Ori: o }))
- : Pe.createElement(o, u)
- : (console.warn("OAS3 wrapper: couldn't get spec"), null);
- }
- const XO = (0, qe.Map)(),
- selectors_isSwagger2 = () => (s) =>
- (function isSwagger2(s) {
- const o = s.get('swagger');
- return 'string' == typeof o && '2.0' === o;
- })(s.getSystem().specSelectors.specJson()),
- selectors_isOAS30 = () => (s) =>
- (function isOAS30(s) {
- const o = s.get('openapi');
- return 'string' == typeof o && /^3\.0\.([0123])(?:-rc[012])?$/.test(o);
- })(s.getSystem().specSelectors.specJson()),
- selectors_isOAS3 = () => (s) => s.getSystem().specSelectors.isOAS30();
- function selectors_onlyOAS3(s) {
- return (o, ...i) =>
- (u) => {
- if (u.specSelectors.isOAS3()) {
- const _ = s(o, ...i);
- return 'function' == typeof _ ? _(u) : _;
- }
- return null;
- };
- }
- const ZO = selectors_onlyOAS3(() => (s) => s.specSelectors.specJson().get('servers', XO)),
- findSchema = (s, o) => {
- const i = s.getIn(['resolvedSubtrees', 'components', 'schemas', o], null),
- u = s.getIn(['json', 'components', 'schemas', o], null);
- return i || u || null;
- },
- QO = selectors_onlyOAS3((s, { callbacks: o, specPath: i }) => (s) => {
- const u = s.specSelectors.validOperationMethods();
- return qe.Map.isMap(o)
- ? o
- .reduce(
- (s, o, _) => {
- if (!qe.Map.isMap(o)) return s;
- const w = o.reduce(
- (s, o, w) => {
- if (!qe.Map.isMap(o)) return s;
- const x = o
- .entrySeq()
- .filter(([s]) => u.includes(s))
- .map(([s, o]) => ({
- operation: (0, qe.Map)({ operation: o }),
- method: s,
- path: w,
- callbackName: _,
- specPath: i.concat([_, w, s])
- }));
- return s.concat(x);
- },
- (0, qe.List)()
- );
- return s.concat(w);
- },
- (0, qe.List)()
- )
- .groupBy((s) => s.callbackName)
- .map((s) => s.toArray())
- .toObject()
- : {};
- }),
- callbacks = ({ callbacks: s, specPath: o, specSelectors: i, getComponent: u }) => {
- const _ = i.callbacksOperations({ callbacks: s, specPath: o }),
- w = Object.keys(_),
- x = u('OperationContainer', !0);
- return 0 === w.length
- ? Pe.createElement('span', null, 'No callbacks')
- : Pe.createElement(
- 'div',
- null,
- w.map((s) =>
- Pe.createElement(
- 'div',
- { key: `${s}` },
- Pe.createElement('h2', null, s),
- _[s].map((o) =>
- Pe.createElement(x, {
- key: `${s}-${o.path}-${o.method}`,
- op: o.operation,
- tag: 'callbacks',
- method: o.method,
- path: o.path,
- specPath: o.specPath,
- allowTryItOut: !1
- })
- )
- )
- )
- );
- },
- getDefaultRequestBodyValue = (s, o, i, u) => {
- const _ = s.getIn(['content', o]) ?? (0, qe.OrderedMap)(),
- w = _.get('schema', (0, qe.OrderedMap)()).toJS(),
- x = void 0 !== _.get('examples'),
- C = _.get('example'),
- j = x ? _.getIn(['examples', i, 'value']) : C;
- return stringify(u.getSampleSchema(w, o, { includeWriteOnly: !0 }, j));
- },
- components_request_body = ({
- userHasEditedBody: s,
- requestBody: o,
- requestBodyValue: i,
- requestBodyInclusionSetting: u,
- requestBodyErrors: _,
- getComponent: w,
- getConfigs: x,
- specSelectors: C,
- fn: j,
- contentType: L,
- isExecute: B,
- specPath: $,
- onChange: V,
- onChangeIncludeEmpty: U,
- activeExamplesKey: z,
- updateActiveExamplesKey: Y,
- setRetainRequestBodyValueFlag: Z
- }) => {
- const handleFile = (s) => {
- V(s.target.files[0]);
- },
- setIsIncludedOptions = (s) => {
- let o = { key: s, shouldDispatchInit: !1, defaultValue: !0 };
- return 'no value' === u.get(s, 'no value') && (o.shouldDispatchInit = !0), o;
- },
- ee = w('Markdown', !0),
- ie = w('modelExample'),
- ae = w('RequestBodyEditor'),
- le = w('HighlightCode', !0),
- ce = w('ExamplesSelectValueRetainer'),
- pe = w('Example'),
- de = w('ParameterIncludeEmpty'),
- { showCommonExtensions: fe } = x(),
- ye = o?.get('description') ?? null,
- be = o?.get('content') ?? new qe.OrderedMap();
- L = L || be.keySeq().first() || '';
- const _e = be.get(L) ?? (0, qe.OrderedMap)(),
- we = _e.get('schema', (0, qe.OrderedMap)()),
- Se = _e.get('examples', null),
- xe = Se?.map((s, i) => {
- const u = s?.get('value', null);
- return u && (s = s.set('value', getDefaultRequestBodyValue(o, L, i, j), u)), s;
- });
- if (((_ = qe.List.isList(_) ? _ : (0, qe.List)()), !_e.size)) return null;
- const Te = 'object' === _e.getIn(['schema', 'type']),
- Re = 'binary' === _e.getIn(['schema', 'format']),
- $e = 'base64' === _e.getIn(['schema', 'format']);
- if (
- 'application/octet-stream' === L ||
- 0 === L.indexOf('image/') ||
- 0 === L.indexOf('audio/') ||
- 0 === L.indexOf('video/') ||
- Re ||
- $e
- ) {
- const s = w('Input');
- return B
- ? Pe.createElement(s, { type: 'file', onChange: handleFile })
- : Pe.createElement(
- 'i',
- null,
- 'Example values are not available for ',
- Pe.createElement('code', null, L),
- ' media types.'
- );
- }
- if (
- Te &&
- ('application/x-www-form-urlencoded' === L || 0 === L.indexOf('multipart/')) &&
- we.get('properties', (0, qe.OrderedMap)()).size > 0
- ) {
- const s = w('JsonSchemaForm'),
- o = w('ParameterExt'),
- x = we.get('properties', (0, qe.OrderedMap)());
- return (
- (i = qe.Map.isMap(i) ? i : (0, qe.OrderedMap)()),
- Pe.createElement(
- 'div',
- { className: 'table-container' },
- ye && Pe.createElement(ee, { source: ye }),
- Pe.createElement(
- 'table',
- null,
- Pe.createElement(
- 'tbody',
- null,
- qe.Map.isMap(x) &&
- x.entrySeq().map(([x, C]) => {
- if (C.get('readOnly')) return;
- const L = C.get('oneOf')?.get(0)?.toJS(),
- $ = C.get('anyOf')?.get(0)?.toJS();
- C = (0, qe.fromJS)(j.mergeJsonSchema(C.toJS(), L ?? $ ?? {}));
- let z = fe ? getCommonExtensions(C) : null;
- const Y = we.get('required', (0, qe.List)()).includes(x),
- Z = C.get('type'),
- ie = C.get('format'),
- ae = C.get('description'),
- le = i.getIn([x, 'value']),
- ce = i.getIn([x, 'errors']) || _,
- pe = u.get(x) || !1;
- let ye = j.getSampleSchema(C, !1, { includeWriteOnly: !0 });
- !1 === ye && (ye = 'false'),
- 0 === ye && (ye = '0'),
- 'string' != typeof ye && 'object' === Z && (ye = stringify(ye)),
- 'string' == typeof ye && 'array' === Z && (ye = JSON.parse(ye));
- const be = 'string' === Z && ('binary' === ie || 'base64' === ie);
- return Pe.createElement(
- 'tr',
- { key: x, className: 'parameters', 'data-property-name': x },
- Pe.createElement(
- 'td',
- { className: 'parameters-col_name' },
- Pe.createElement(
- 'div',
- { className: Y ? 'parameter__name required' : 'parameter__name' },
- x,
- Y ? Pe.createElement('span', null, ' *') : null
- ),
- Pe.createElement(
- 'div',
- { className: 'parameter__type' },
- Z,
- ie &&
- Pe.createElement(
- 'span',
- { className: 'prop-format' },
- '($',
- ie,
- ')'
- ),
- fe && z.size
- ? z
- .entrySeq()
- .map(([s, i]) =>
- Pe.createElement(o, { key: `${s}-${i}`, xKey: s, xVal: i })
- )
- : null
- ),
- Pe.createElement(
- 'div',
- { className: 'parameter__deprecated' },
- C.get('deprecated') ? 'deprecated' : null
- )
- ),
- Pe.createElement(
- 'td',
- { className: 'parameters-col_description' },
- Pe.createElement(ee, { source: ae }),
- B
- ? Pe.createElement(
- 'div',
- null,
- Pe.createElement(s, {
- fn: j,
- dispatchInitialValue: !be,
- schema: C,
- description: x,
- getComponent: w,
- value: void 0 === le ? ye : le,
- required: Y,
- errors: ce,
- onChange: (s) => {
- V(s, [x]);
- }
- }),
- Y
- ? null
- : Pe.createElement(de, {
- onChange: (s) => U(x, s),
- isIncluded: pe,
- isIncludedOptions: setIsIncludedOptions(x),
- isDisabled: Array.isArray(le)
- ? 0 !== le.length
- : !isEmptyValue(le)
- })
- )
- : null
- )
- );
- })
- )
- )
- )
- );
- }
- const ze = getDefaultRequestBodyValue(o, L, z, j);
- let We = null;
- return (
- getKnownSyntaxHighlighterLanguage(ze) && (We = 'json'),
- Pe.createElement(
- 'div',
- null,
- ye && Pe.createElement(ee, { source: ye }),
- xe
- ? Pe.createElement(ce, {
- userHasEditedBody: s,
- examples: xe,
- currentKey: z,
- currentUserInputValue: i,
- onSelect: (s) => {
- Y(s);
- },
- updateValue: V,
- defaultToFirstExample: !0,
- getComponent: w,
- setRetainRequestBodyValueFlag: Z
- })
- : null,
- B
- ? Pe.createElement(
- 'div',
- null,
- Pe.createElement(ae, {
- value: i,
- errors: _,
- defaultValue: ze,
- onChange: V,
- getComponent: w
- })
- )
- : Pe.createElement(ie, {
- getComponent: w,
- getConfigs: x,
- specSelectors: C,
- expandDepth: 1,
- isExecute: B,
- schema: _e.get('schema'),
- specPath: $.push('content', L),
- example: Pe.createElement(
- le,
- { className: 'body-param__example', language: We },
- stringify(i) || ze
- ),
- includeWriteOnly: !0
- }),
- xe
- ? Pe.createElement(pe, { example: xe.get(z), getComponent: w, getConfigs: x })
- : null
- )
- );
- };
- class operation_link_OperationLink extends Pe.Component {
- render() {
- const { link: s, name: o, getComponent: i } = this.props,
- u = i('Markdown', !0);
- let _ = s.get('operationId') || s.get('operationRef'),
- w = s.get('parameters') && s.get('parameters').toJS(),
- x = s.get('description');
- return Pe.createElement(
- 'div',
- { className: 'operation-link' },
- Pe.createElement(
- 'div',
- { className: 'description' },
- Pe.createElement('b', null, Pe.createElement('code', null, o)),
- x ? Pe.createElement(u, { source: x }) : null
- ),
- Pe.createElement(
- 'pre',
- null,
- 'Operation `',
- _,
- '`',
- Pe.createElement('br', null),
- Pe.createElement('br', null),
- 'Parameters ',
- (function padString(s, o) {
- if ('string' != typeof o) return '';
- return o
- .split('\n')
- .map((o, i) => (i > 0 ? Array(s + 1).join(' ') + o : o))
- .join('\n');
- })(0, JSON.stringify(w, null, 2)) || '{}',
- Pe.createElement('br', null)
- )
- );
- }
- }
- const eA = operation_link_OperationLink,
- components_servers = ({
- servers: s,
- currentServer: o,
- setSelectedServer: i,
- setServerVariableValue: u,
- getServerVariable: _,
- getEffectiveServerValue: w
- }) => {
- const x =
- (s.find((s) => s.get('url') === o) || (0, qe.OrderedMap)()).get('variables') ||
- (0, qe.OrderedMap)(),
- C = 0 !== x.size;
- (0, Pe.useEffect)(() => {
- o || i(s.first()?.get('url'));
- }, []),
- (0, Pe.useEffect)(() => {
- const _ = s.find((s) => s.get('url') === o);
- if (!_) return void i(s.first().get('url'));
- (_.get('variables') || (0, qe.OrderedMap)()).map((s, i) => {
- u({ server: o, key: i, val: s.get('default') || '' });
- });
- }, [o, s]);
- const j = (0, Pe.useCallback)(
- (s) => {
- i(s.target.value);
- },
- [i]
- ),
- L = (0, Pe.useCallback)(
- (s) => {
- const i = s.target.getAttribute('data-variable'),
- _ = s.target.value;
- u({ server: o, key: i, val: _ });
- },
- [u, o]
- );
- return Pe.createElement(
- 'div',
- { className: 'servers' },
- Pe.createElement(
- 'label',
- { htmlFor: 'servers' },
- Pe.createElement(
- 'select',
- { onChange: j, value: o, id: 'servers' },
- s
- .valueSeq()
- .map((s) =>
- Pe.createElement(
- 'option',
- { value: s.get('url'), key: s.get('url') },
- s.get('url'),
- s.get('description') && ` - ${s.get('description')}`
- )
- )
- .toArray()
- )
- ),
- C &&
- Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'div',
- { className: 'computed-url' },
- 'Computed URL:',
- Pe.createElement('code', null, w(o))
- ),
- Pe.createElement('h4', null, 'Server variables'),
- Pe.createElement(
- 'table',
- null,
- Pe.createElement(
- 'tbody',
- null,
- x.entrySeq().map(([s, i]) =>
- Pe.createElement(
- 'tr',
- { key: s },
- Pe.createElement('td', null, s),
- Pe.createElement(
- 'td',
- null,
- i.get('enum')
- ? Pe.createElement(
- 'select',
- { 'data-variable': s, onChange: L },
- i
- .get('enum')
- .map((i) =>
- Pe.createElement(
- 'option',
- { selected: i === _(o, s), key: i, value: i },
- i
- )
- )
- )
- : Pe.createElement('input', {
- type: 'text',
- value: _(o, s) || '',
- onChange: L,
- 'data-variable': s
- })
- )
- )
- )
- )
- )
- )
- );
- };
- class ServersContainer extends Pe.Component {
- render() {
- const {
- specSelectors: s,
- oas3Selectors: o,
- oas3Actions: i,
- getComponent: u
- } = this.props,
- _ = s.servers(),
- w = u('Servers');
- return _ && _.size
- ? Pe.createElement(
- 'div',
- null,
- Pe.createElement('span', { className: 'servers-title' }, 'Servers'),
- Pe.createElement(w, {
- servers: _,
- currentServer: o.selectedServer(),
- setSelectedServer: i.setSelectedServer,
- setServerVariableValue: i.setServerVariableValue,
- getServerVariable: o.serverVariableValue,
- getEffectiveServerValue: o.serverEffectiveValue
- })
- )
- : null;
- }
- }
- const tA = Function.prototype;
- class RequestBodyEditor extends Pe.PureComponent {
- static defaultProps = { onChange: tA, userHasEditedBody: !1 };
- constructor(s, o) {
- super(s, o),
- (this.state = { value: stringify(s.value) || s.defaultValue }),
- s.onChange(s.value);
- }
- applyDefaultValue = (s) => {
- const { onChange: o, defaultValue: i } = s || this.props;
- return this.setState({ value: i }), o(i);
- };
- onChange = (s) => {
- this.props.onChange(stringify(s));
- };
- onDomChange = (s) => {
- const o = s.target.value;
- this.setState({ value: o }, () => this.onChange(o));
- };
- UNSAFE_componentWillReceiveProps(s) {
- this.props.value !== s.value &&
- s.value !== this.state.value &&
- this.setState({ value: stringify(s.value) }),
- !s.value && s.defaultValue && this.state.value && this.applyDefaultValue(s);
- }
- render() {
- let { getComponent: s, errors: o } = this.props,
- { value: i } = this.state,
- u = o.size > 0;
- const _ = s('TextArea');
- return Pe.createElement(
- 'div',
- { className: 'body-param' },
- Pe.createElement(_, {
- className: Hn()('body-param__text', { invalid: u }),
- title: o.size ? o.join(', ') : '',
- value: i,
- onChange: this.onDomChange
- })
- );
- }
- }
- class HttpAuth extends Pe.Component {
- constructor(s, o) {
- super(s, o);
- let { name: i, schema: u } = this.props,
- _ = this.getValue();
- this.state = { name: i, schema: u, value: _ };
- }
- getValue() {
- let { name: s, authorized: o } = this.props;
- return o && o.getIn([s, 'value']);
- }
- onChange = (s) => {
- let { onChange: o } = this.props,
- { value: i, name: u } = s.target,
- _ = Object.assign({}, this.state.value);
- u ? (_[u] = i) : (_ = i), this.setState({ value: _ }, () => o(this.state));
- };
- render() {
- let { schema: s, getComponent: o, errSelectors: i, name: u } = this.props;
- const _ = o('Input'),
- w = o('Row'),
- x = o('Col'),
- C = o('authError'),
- j = o('Markdown', !0),
- L = o('JumpToPath', !0),
- B = (s.get('scheme') || '').toLowerCase();
- let $ = this.getValue(),
- V = i.allErrors().filter((s) => s.get('authId') === u);
- if ('basic' === B) {
- let o = $ ? $.get('username') : null;
- return Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'h4',
- null,
- Pe.createElement('code', null, u || s.get('name')),
- ' (http, Basic)',
- Pe.createElement(L, { path: ['securityDefinitions', u] })
- ),
- o && Pe.createElement('h6', null, 'Authorized'),
- Pe.createElement(w, null, Pe.createElement(j, { source: s.get('description') })),
- Pe.createElement(
- w,
- null,
- Pe.createElement('label', { htmlFor: 'auth-basic-username' }, 'Username:'),
- o
- ? Pe.createElement('code', null, ' ', o, ' ')
- : Pe.createElement(
- x,
- null,
- Pe.createElement(_, {
- id: 'auth-basic-username',
- type: 'text',
- required: 'required',
- name: 'username',
- 'aria-label': 'auth-basic-username',
- onChange: this.onChange,
- autoFocus: !0
- })
- )
- ),
- Pe.createElement(
- w,
- null,
- Pe.createElement('label', { htmlFor: 'auth-basic-password' }, 'Password:'),
- o
- ? Pe.createElement('code', null, ' ****** ')
- : Pe.createElement(
- x,
- null,
- Pe.createElement(_, {
- id: 'auth-basic-password',
- autoComplete: 'new-password',
- name: 'password',
- type: 'password',
- 'aria-label': 'auth-basic-password',
- onChange: this.onChange
- })
- )
- ),
- V.valueSeq().map((s, o) => Pe.createElement(C, { error: s, key: o }))
- );
- }
- return 'bearer' === B
- ? Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'h4',
- null,
- Pe.createElement('code', null, u || s.get('name')),
- ' (http, Bearer)',
- Pe.createElement(L, { path: ['securityDefinitions', u] })
- ),
- $ && Pe.createElement('h6', null, 'Authorized'),
- Pe.createElement(w, null, Pe.createElement(j, { source: s.get('description') })),
- Pe.createElement(
- w,
- null,
- Pe.createElement('label', { htmlFor: 'auth-bearer-value' }, 'Value:'),
- $
- ? Pe.createElement('code', null, ' ****** ')
- : Pe.createElement(
- x,
- null,
- Pe.createElement(_, {
- id: 'auth-bearer-value',
- type: 'text',
- 'aria-label': 'auth-bearer-value',
- onChange: this.onChange,
- autoFocus: !0
- })
- )
- ),
- V.valueSeq().map((s, o) => Pe.createElement(C, { error: s, key: o }))
- )
- : Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'em',
- null,
- Pe.createElement('b', null, u),
- ' HTTP authentication: unsupported scheme ',
- `'${B}'`
- )
- );
- }
- }
- class operation_servers_OperationServers extends Pe.Component {
- setSelectedServer = (s) => {
- const { path: o, method: i } = this.props;
- return this.forceUpdate(), this.props.setSelectedServer(s, `${o}:${i}`);
- };
- setServerVariableValue = (s) => {
- const { path: o, method: i } = this.props;
- return (
- this.forceUpdate(),
- this.props.setServerVariableValue({ ...s, namespace: `${o}:${i}` })
- );
- };
- getSelectedServer = () => {
- const { path: s, method: o } = this.props;
- return this.props.getSelectedServer(`${s}:${o}`);
- };
- getServerVariable = (s, o) => {
- const { path: i, method: u } = this.props;
- return this.props.getServerVariable({ namespace: `${i}:${u}`, server: s }, o);
- };
- getEffectiveServerValue = (s) => {
- const { path: o, method: i } = this.props;
- return this.props.getEffectiveServerValue({ server: s, namespace: `${o}:${i}` });
- };
- render() {
- const { operationServers: s, pathServers: o, getComponent: i } = this.props;
- if (!s && !o) return null;
- const u = i('Servers'),
- _ = s || o,
- w = s ? 'operation' : 'path';
- return Pe.createElement(
- 'div',
- { className: 'opblock-section operation-servers' },
- Pe.createElement(
- 'div',
- { className: 'opblock-section-header' },
- Pe.createElement(
- 'div',
- { className: 'tab-header' },
- Pe.createElement('h4', { className: 'opblock-title' }, 'Servers')
- )
- ),
- Pe.createElement(
- 'div',
- { className: 'opblock-description-wrapper' },
- Pe.createElement(
- 'h4',
- { className: 'message' },
- 'These ',
- w,
- '-level options override the global server options.'
- ),
- Pe.createElement(u, {
- servers: _,
- currentServer: this.getSelectedServer(),
- setSelectedServer: this.setSelectedServer,
- setServerVariableValue: this.setServerVariableValue,
- getServerVariable: this.getServerVariable,
- getEffectiveServerValue: this.getEffectiveServerValue
- })
- )
- );
- }
- }
- const rA = {
- Callbacks: callbacks,
- HttpAuth,
- RequestBody: components_request_body,
- Servers: components_servers,
- ServersContainer,
- RequestBodyEditor,
- OperationServers: operation_servers_OperationServers,
- operationLink: eA
- },
- nA = new Remarkable('commonmark');
- nA.block.ruler.enable(['table']), nA.set({ linkTarget: '_blank' });
- const sA = OAS3ComponentWrapFactory(
- ({
- source: s,
- className: o = '',
- getConfigs: i = () => ({ useUnsafeMarkdown: !1 })
- }) => {
- if ('string' != typeof s) return null;
- if (s) {
- const { useUnsafeMarkdown: u } = i(),
- _ = sanitizer(nA.render(s), { useUnsafeMarkdown: u });
- let w;
- return (
- 'string' == typeof _ && (w = _.trim()),
- Pe.createElement('div', {
- dangerouslySetInnerHTML: { __html: w },
- className: Hn()(o, 'renderedMarkdown')
- })
- );
- }
- return null;
- }
- ),
- oA = OAS3ComponentWrapFactory(({ Ori: s, ...o }) => {
- const {
- schema: i,
- getComponent: u,
- errSelectors: _,
- authorized: w,
- onAuthChange: x,
- name: C
- } = o,
- j = u('HttpAuth');
- return 'http' === i.get('type')
- ? Pe.createElement(j, {
- key: C,
- schema: i,
- name: C,
- errSelectors: _,
- authorized: w,
- getComponent: u,
- onChange: x
- })
- : Pe.createElement(s, o);
- }),
- iA = OAS3ComponentWrapFactory(OnlineValidatorBadge);
- class ModelComponent extends Pe.Component {
- render() {
- let { getConfigs: s, schema: o, Ori: i } = this.props,
- u = ['model-box'],
- _ = null;
- return (
- !0 === o.get('deprecated') &&
- (u.push('deprecated'),
- (_ = Pe.createElement(
- 'span',
- { className: 'model-deprecated-warning' },
- 'Deprecated:'
- ))),
- Pe.createElement(
- 'div',
- { className: u.join(' ') },
- _,
- Pe.createElement(
- i,
- Rn()({}, this.props, {
- getConfigs: s,
- depth: 1,
- expandDepth: this.props.expandDepth || 0
- })
- )
- )
- );
- }
- }
- const aA = OAS3ComponentWrapFactory(ModelComponent),
- lA = OAS3ComponentWrapFactory(({ Ori: s, ...o }) => {
- const { schema: i, getComponent: u, errors: _, onChange: w } = o,
- x = i && i.get ? i.get('format') : null,
- C = i && i.get ? i.get('type') : null,
- j = u('Input');
- return C && 'string' === C && x && ('binary' === x || 'base64' === x)
- ? Pe.createElement(j, {
- type: 'file',
- className: _.length ? 'invalid' : '',
- title: _.length ? _ : '',
- onChange: (s) => {
- w(s.target.files[0]);
- },
- disabled: s.isDisabled
- })
- : Pe.createElement(s, o);
- }),
- cA = {
- Markdown: sA,
- AuthItem: oA,
- OpenAPIVersion: (function OAS30ComponentWrapFactory(s) {
- return (o, i) => (u) =>
- 'function' == typeof i.specSelectors?.isOAS30
- ? i.specSelectors.isOAS30()
- ? Pe.createElement(s, Rn()({}, u, i, { Ori: o }))
- : Pe.createElement(o, u)
- : (console.warn("OAS30 wrapper: couldn't get spec"), null);
- })((s) => {
- const { Ori: o } = s;
- return Pe.createElement(o, { oasVersion: '3.0' });
- }),
- JsonSchema_string: lA,
- model: aA,
- onlineValidatorBadge: iA
- },
- uA = 'oas3_set_servers',
- pA = 'oas3_set_request_body_value',
- hA = 'oas3_set_request_body_retain_flag',
- dA = 'oas3_set_request_body_inclusion',
- fA = 'oas3_set_active_examples_member',
- mA = 'oas3_set_request_content_type',
- gA = 'oas3_set_response_content_type',
- yA = 'oas3_set_server_variable_value',
- vA = 'oas3_set_request_body_validate_error',
- bA = 'oas3_clear_request_body_validate_error',
- _A = 'oas3_clear_request_body_value';
- function setSelectedServer(s, o) {
- return { type: uA, payload: { selectedServerUrl: s, namespace: o } };
- }
- function setRequestBodyValue({ value: s, pathMethod: o }) {
- return { type: pA, payload: { value: s, pathMethod: o } };
- }
- const setRetainRequestBodyValueFlag = ({ value: s, pathMethod: o }) => ({
- type: hA,
- payload: { value: s, pathMethod: o }
- });
- function setRequestBodyInclusion({ value: s, pathMethod: o, name: i }) {
- return { type: dA, payload: { value: s, pathMethod: o, name: i } };
- }
- function setActiveExamplesMember({
- name: s,
- pathMethod: o,
- contextType: i,
- contextName: u
- }) {
- return { type: fA, payload: { name: s, pathMethod: o, contextType: i, contextName: u } };
- }
- function setRequestContentType({ value: s, pathMethod: o }) {
- return { type: mA, payload: { value: s, pathMethod: o } };
- }
- function setResponseContentType({ value: s, path: o, method: i }) {
- return { type: gA, payload: { value: s, path: o, method: i } };
- }
- function setServerVariableValue({ server: s, namespace: o, key: i, val: u }) {
- return { type: yA, payload: { server: s, namespace: o, key: i, val: u } };
- }
- const setRequestBodyValidateError = ({ path: s, method: o, validationErrors: i }) => ({
- type: vA,
- payload: { path: s, method: o, validationErrors: i }
- }),
- clearRequestBodyValidateError = ({ path: s, method: o }) => ({
- type: bA,
- payload: { path: s, method: o }
- }),
- initRequestBodyValidateError = ({ pathMethod: s }) => ({
- type: bA,
- payload: { path: s[0], method: s[1] }
- }),
- clearRequestBodyValue = ({ pathMethod: s }) => ({ type: _A, payload: { pathMethod: s } });
- var EA = __webpack_require__(60680),
- wA = __webpack_require__.n(EA);
- const oas3_selectors_onlyOAS3 =
- (s) =>
- (o, ...i) =>
- (u) => {
- if (u.getSystem().specSelectors.isOAS3()) {
- const _ = s(o, ...i);
- return 'function' == typeof _ ? _(u) : _;
- }
- return null;
- };
- const SA = oas3_selectors_onlyOAS3((s, o) => {
- const i = o ? [o, 'selectedServer'] : ['selectedServer'];
- return s.getIn(i) || '';
- }),
- xA = oas3_selectors_onlyOAS3(
- (s, o, i) => s.getIn(['requestData', o, i, 'bodyValue']) || null
- ),
- kA = oas3_selectors_onlyOAS3(
- (s, o, i) => s.getIn(['requestData', o, i, 'retainBodyValue']) || !1
- ),
- selectDefaultRequestBodyValue = (s, o, i) => (s) => {
- const { oas3Selectors: u, specSelectors: _, fn: w } = s.getSystem();
- if (_.isOAS3()) {
- const s = u.requestContentType(o, i);
- if (s)
- return getDefaultRequestBodyValue(
- _.specResolvedSubtree(['paths', o, i, 'requestBody']),
- s,
- u.activeExamplesMember(o, i, 'requestBody', 'requestBody'),
- w
- );
- }
- return null;
- },
- CA = oas3_selectors_onlyOAS3((s, o, i) => (s) => {
- const { oas3Selectors: u, specSelectors: _, fn: w } = s;
- let x = !1;
- const C = u.requestContentType(o, i);
- let j = u.requestBodyValue(o, i);
- const L = _.specResolvedSubtree(['paths', o, i, 'requestBody']);
- if (!L) return !1;
- if (
- (qe.Map.isMap(j) &&
- (j = stringify(
- j.mapEntries((s) => (qe.Map.isMap(s[1]) ? [s[0], s[1].get('value')] : s)).toJS()
- )),
- qe.List.isList(j) && (j = stringify(j)),
- C)
- ) {
- const s = getDefaultRequestBodyValue(
- L,
- C,
- u.activeExamplesMember(o, i, 'requestBody', 'requestBody'),
- w
- );
- x = !!j && j !== s;
- }
- return x;
- }),
- OA = oas3_selectors_onlyOAS3(
- (s, o, i) => s.getIn(['requestData', o, i, 'bodyInclusion']) || (0, qe.Map)()
- ),
- AA = oas3_selectors_onlyOAS3(
- (s, o, i) => s.getIn(['requestData', o, i, 'errors']) || null
- ),
- jA = oas3_selectors_onlyOAS3(
- (s, o, i, u, _) => s.getIn(['examples', o, i, u, _, 'activeExample']) || null
- ),
- IA = oas3_selectors_onlyOAS3(
- (s, o, i) => s.getIn(['requestData', o, i, 'requestContentType']) || null
- ),
- PA = oas3_selectors_onlyOAS3(
- (s, o, i) => s.getIn(['requestData', o, i, 'responseContentType']) || null
- ),
- MA = oas3_selectors_onlyOAS3((s, o, i) => {
- let u;
- if ('string' != typeof o) {
- const { server: s, namespace: _ } = o;
- u = _ ? [_, 'serverVariableValues', s, i] : ['serverVariableValues', s, i];
- } else {
- u = ['serverVariableValues', o, i];
- }
- return s.getIn(u) || null;
- }),
- TA = oas3_selectors_onlyOAS3((s, o) => {
- let i;
- if ('string' != typeof o) {
- const { server: s, namespace: u } = o;
- i = u ? [u, 'serverVariableValues', s] : ['serverVariableValues', s];
- } else {
- i = ['serverVariableValues', o];
- }
- return s.getIn(i) || (0, qe.OrderedMap)();
- }),
- NA = oas3_selectors_onlyOAS3((s, o) => {
- var i, u;
- if ('string' != typeof o) {
- const { server: _, namespace: w } = o;
- (u = _),
- (i = w
- ? s.getIn([w, 'serverVariableValues', u])
- : s.getIn(['serverVariableValues', u]));
- } else (u = o), (i = s.getIn(['serverVariableValues', u]));
- i = i || (0, qe.OrderedMap)();
- let _ = u;
- return (
- i.map((s, o) => {
- _ = _.replace(new RegExp(`{${wA()(o)}}`, 'g'), s);
- }),
- _
- );
- }),
- RA = (function validateRequestBodyIsRequired(s) {
- return (...o) =>
- (i) => {
- const u = i.getSystem().specSelectors.specJson();
- let _ = [...o][1] || [];
- return !u.getIn(['paths', ..._, 'requestBody', 'required']) || s(...o);
- };
- })((s, o) =>
- ((s, o) => ((o = o || []), !!s.getIn(['requestData', ...o, 'bodyValue'])))(s, o)
- ),
- validateShallowRequired = (
- s,
- {
- oas3RequiredRequestBodyContentType: o,
- oas3RequestContentType: i,
- oas3RequestBodyValue: u
- }
- ) => {
- let _ = [];
- if (!qe.Map.isMap(u)) return _;
- let w = [];
- return (
- Object.keys(o.requestContentType).forEach((s) => {
- if (s === i) {
- o.requestContentType[s].forEach((s) => {
- w.indexOf(s) < 0 && w.push(s);
- });
- }
- }),
- w.forEach((s) => {
- u.getIn([s, 'value']) || _.push(s);
- }),
- _
- );
- },
- DA = Ss()(['get', 'put', 'post', 'delete', 'options', 'head', 'patch', 'trace']),
- LA = {
- [uA]: (s, { payload: { selectedServerUrl: o, namespace: i } }) => {
- const u = i ? [i, 'selectedServer'] : ['selectedServer'];
- return s.setIn(u, o);
- },
- [pA]: (s, { payload: { value: o, pathMethod: i } }) => {
- let [u, _] = i;
- if (!qe.Map.isMap(o)) return s.setIn(['requestData', u, _, 'bodyValue'], o);
- let w,
- x = s.getIn(['requestData', u, _, 'bodyValue']) || (0, qe.Map)();
- qe.Map.isMap(x) || (x = (0, qe.Map)());
- const [...C] = o.keys();
- return (
- C.forEach((s) => {
- let i = o.getIn([s]);
- (x.has(s) && qe.Map.isMap(i)) || (w = x.setIn([s, 'value'], i));
- }),
- s.setIn(['requestData', u, _, 'bodyValue'], w)
- );
- },
- [hA]: (s, { payload: { value: o, pathMethod: i } }) => {
- let [u, _] = i;
- return s.setIn(['requestData', u, _, 'retainBodyValue'], o);
- },
- [dA]: (s, { payload: { value: o, pathMethod: i, name: u } }) => {
- let [_, w] = i;
- return s.setIn(['requestData', _, w, 'bodyInclusion', u], o);
- },
- [fA]: (s, { payload: { name: o, pathMethod: i, contextType: u, contextName: _ } }) => {
- let [w, x] = i;
- return s.setIn(['examples', w, x, u, _, 'activeExample'], o);
- },
- [mA]: (s, { payload: { value: o, pathMethod: i } }) => {
- let [u, _] = i;
- return s.setIn(['requestData', u, _, 'requestContentType'], o);
- },
- [gA]: (s, { payload: { value: o, path: i, method: u } }) =>
- s.setIn(['requestData', i, u, 'responseContentType'], o),
- [yA]: (s, { payload: { server: o, namespace: i, key: u, val: _ } }) => {
- const w = i ? [i, 'serverVariableValues', o, u] : ['serverVariableValues', o, u];
- return s.setIn(w, _);
- },
- [vA]: (s, { payload: { path: o, method: i, validationErrors: u } }) => {
- let _ = [];
- if ((_.push('Required field is not provided'), u.missingBodyValue))
- return s.setIn(['requestData', o, i, 'errors'], (0, qe.fromJS)(_));
- if (u.missingRequiredKeys && u.missingRequiredKeys.length > 0) {
- const { missingRequiredKeys: w } = u;
- return s.updateIn(['requestData', o, i, 'bodyValue'], (0, qe.fromJS)({}), (s) =>
- w.reduce((s, o) => s.setIn([o, 'errors'], (0, qe.fromJS)(_)), s)
- );
- }
- return console.warn('unexpected result: SET_REQUEST_BODY_VALIDATE_ERROR'), s;
- },
- [bA]: (s, { payload: { path: o, method: i } }) => {
- const u = s.getIn(['requestData', o, i, 'bodyValue']);
- if (!qe.Map.isMap(u))
- return s.setIn(['requestData', o, i, 'errors'], (0, qe.fromJS)([]));
- const [..._] = u.keys();
- return _
- ? s.updateIn(['requestData', o, i, 'bodyValue'], (0, qe.fromJS)({}), (s) =>
- _.reduce((s, o) => s.setIn([o, 'errors'], (0, qe.fromJS)([])), s)
- )
- : s;
- },
- [_A]: (s, { payload: { pathMethod: o } }) => {
- let [i, u] = o;
- const _ = s.getIn(['requestData', i, u, 'bodyValue']);
- return _
- ? qe.Map.isMap(_)
- ? s.setIn(['requestData', i, u, 'bodyValue'], (0, qe.Map)())
- : s.setIn(['requestData', i, u, 'bodyValue'], '')
- : s;
- }
- };
- function oas3() {
- return {
- components: rA,
- wrapComponents: cA,
- statePlugins: {
- spec: { wrapSelectors: be, selectors: we },
- auth: { wrapSelectors: _e },
- oas3: { actions: { ...Se }, reducers: LA, selectors: { ...xe } }
- }
- };
- }
- const webhooks = ({ specSelectors: s, getComponent: o }) => {
- const i = s.selectWebhooksOperations(),
- u = Object.keys(i),
- _ = o('OperationContainer', !0);
- return 0 === u.length
- ? null
- : Pe.createElement(
- 'div',
- { className: 'webhooks' },
- Pe.createElement('h2', null, 'Webhooks'),
- u.map((s) =>
- Pe.createElement(
- 'div',
- { key: `${s}-webhook` },
- i[s].map((o) =>
- Pe.createElement(_, {
- key: `${s}-${o.method}-webhook`,
- op: o.operation,
- tag: 'webhooks',
- method: o.method,
- path: s,
- specPath: (0, qe.List)(o.specPath),
- allowTryItOut: !1
- })
- )
- )
- )
- );
- },
- oas31_components_license = ({ getComponent: s, specSelectors: o }) => {
- const i = o.selectLicenseNameField(),
- u = o.selectLicenseUrl(),
- _ = s('Link');
- return Pe.createElement(
- 'div',
- { className: 'info__license' },
- u
- ? Pe.createElement(
- 'div',
- { className: 'info__license__url' },
- Pe.createElement(_, { target: '_blank', href: sanitizeUrl(u) }, i)
- )
- : Pe.createElement('span', null, i)
- );
- },
- oas31_components_contact = ({ getComponent: s, specSelectors: o }) => {
- const i = o.selectContactNameField(),
- u = o.selectContactUrl(),
- _ = o.selectContactEmailField(),
- w = s('Link');
- return Pe.createElement(
- 'div',
- { className: 'info__contact' },
- u &&
- Pe.createElement(
- 'div',
- null,
- Pe.createElement(w, { href: sanitizeUrl(u), target: '_blank' }, i, ' - Website')
- ),
- _ &&
- Pe.createElement(
- w,
- { href: sanitizeUrl(`mailto:${_}`) },
- u ? `Send email to ${i}` : `Contact ${i}`
- )
- );
- },
- oas31_components_info = ({ getComponent: s, specSelectors: o }) => {
- const i = o.version(),
- u = o.url(),
- _ = o.basePath(),
- w = o.host(),
- x = o.selectInfoSummaryField(),
- C = o.selectInfoDescriptionField(),
- j = o.selectInfoTitleField(),
- L = o.selectInfoTermsOfServiceUrl(),
- B = o.selectExternalDocsUrl(),
- $ = o.selectExternalDocsDescriptionField(),
- V = o.contact(),
- U = o.license(),
- z = s('Markdown', !0),
- Y = s('Link'),
- Z = s('VersionStamp'),
- ee = s('OpenAPIVersion'),
- ie = s('InfoUrl'),
- ae = s('InfoBasePath'),
- le = s('License', !0),
- ce = s('Contact', !0),
- pe = s('JsonSchemaDialect', !0);
- return Pe.createElement(
- 'div',
- { className: 'info' },
- Pe.createElement(
- 'hgroup',
- { className: 'main' },
- Pe.createElement(
- 'h2',
- { className: 'title' },
- j,
- Pe.createElement(
- 'span',
- null,
- i && Pe.createElement(Z, { version: i }),
- Pe.createElement(ee, { oasVersion: '3.1' })
- )
- ),
- (w || _) && Pe.createElement(ae, { host: w, basePath: _ }),
- u && Pe.createElement(ie, { getComponent: s, url: u })
- ),
- x && Pe.createElement('p', { className: 'info__summary' }, x),
- Pe.createElement(
- 'div',
- { className: 'info__description description' },
- Pe.createElement(z, { source: C })
- ),
- L &&
- Pe.createElement(
- 'div',
- { className: 'info__tos' },
- Pe.createElement(
- Y,
- { target: '_blank', href: sanitizeUrl(L) },
- 'Terms of service'
- )
- ),
- V.size > 0 && Pe.createElement(ce, null),
- U.size > 0 && Pe.createElement(le, null),
- B &&
- Pe.createElement(
- Y,
- { className: 'info__extdocs', target: '_blank', href: sanitizeUrl(B) },
- $ || B
- ),
- Pe.createElement(pe, null)
- );
- },
- json_schema_dialect = ({ getComponent: s, specSelectors: o }) => {
- const i = o.selectJsonSchemaDialectField(),
- u = o.selectJsonSchemaDialectDefault(),
- _ = s('Link');
- return Pe.createElement(
- Pe.Fragment,
- null,
- i &&
- i === u &&
- Pe.createElement(
- 'p',
- { className: 'info__jsonschemadialect' },
- 'JSON Schema dialect:',
- ' ',
- Pe.createElement(_, { target: '_blank', href: sanitizeUrl(i) }, i)
- ),
- i &&
- i !== u &&
- Pe.createElement(
- 'div',
- { className: 'error-wrapper' },
- Pe.createElement(
- 'div',
- { className: 'no-margin' },
- Pe.createElement(
- 'div',
- { className: 'errors' },
- Pe.createElement(
- 'div',
- { className: 'errors-wrapper' },
- Pe.createElement('h4', { className: 'center' }, 'Warning'),
- Pe.createElement(
- 'p',
- { className: 'message' },
- Pe.createElement('strong', null, 'OpenAPI.jsonSchemaDialect'),
- ' field contains a value different from the default value of',
- ' ',
- Pe.createElement(_, { target: '_blank', href: u }, u),
- '. Values different from the default one are currently not supported. Please either omit the field or provide it with the default value.'
- )
- )
- )
- )
- )
- );
- },
- version_pragma_filter = ({
- bypass: s,
- isSwagger2: o,
- isOAS3: i,
- isOAS31: u,
- alsoShow: _,
- children: w
- }) =>
- s
- ? Pe.createElement('div', null, w)
- : o && (i || u)
- ? Pe.createElement(
- 'div',
- { className: 'version-pragma' },
- _,
- Pe.createElement(
- 'div',
- { className: 'version-pragma__message version-pragma__message--ambiguous' },
- Pe.createElement(
- 'div',
- null,
- Pe.createElement('h3', null, 'Unable to render this definition'),
- Pe.createElement(
- 'p',
- null,
- Pe.createElement('code', null, 'swagger'),
- ' and ',
- Pe.createElement('code', null, 'openapi'),
- ' fields cannot be present in the same Swagger or OpenAPI definition. Please remove one of the fields.'
- ),
- Pe.createElement(
- 'p',
- null,
- 'Supported version fields are ',
- Pe.createElement('code', null, 'swagger: "2.0"'),
- ' and those that match ',
- Pe.createElement('code', null, 'openapi: 3.x.y'),
- ' (for example,',
- ' ',
- Pe.createElement('code', null, 'openapi: 3.1.0'),
- ').'
- )
- )
- )
- )
- : o || i || u
- ? Pe.createElement('div', null, w)
- : Pe.createElement(
- 'div',
- { className: 'version-pragma' },
- _,
- Pe.createElement(
- 'div',
- { className: 'version-pragma__message version-pragma__message--missing' },
- Pe.createElement(
- 'div',
- null,
- Pe.createElement('h3', null, 'Unable to render this definition'),
- Pe.createElement(
- 'p',
- null,
- 'The provided definition does not specify a valid version field.'
- ),
- Pe.createElement(
- 'p',
- null,
- 'Please indicate a valid Swagger or OpenAPI version field. Supported version fields are ',
- Pe.createElement('code', null, 'swagger: "2.0"'),
- ' and those that match ',
- Pe.createElement('code', null, 'openapi: 3.x.y'),
- ' (for example,',
- ' ',
- Pe.createElement('code', null, 'openapi: 3.1.0'),
- ').'
- )
- )
- )
- ),
- getModelName = (s) =>
- 'string' == typeof s && s.includes('#/components/schemas/')
- ? ((s) => {
- const o = s.replace(/~1/g, '/').replace(/~0/g, '~');
- try {
- return decodeURIComponent(o);
- } catch {
- return o;
- }
- })(s.replace(/^.*#\/components\/schemas\//, ''))
- : null,
- BA = (0, Pe.forwardRef)(({ schema: s, getComponent: o, onToggle: i = () => {} }, u) => {
- const _ = o('JSONSchema202012'),
- w = getModelName(s.get('$$ref')),
- x = (0, Pe.useCallback)(
- (s, o) => {
- i(w, o);
- },
- [w, i]
- );
- return Pe.createElement(_, { name: w, schema: s.toJS(), ref: u, onExpand: x });
- }),
- FA = BA,
- models = ({
- specActions: s,
- specSelectors: o,
- layoutSelectors: i,
- layoutActions: u,
- getComponent: _,
- getConfigs: w,
- fn: x
- }) => {
- const C = o.selectSchemas(),
- j = Object.keys(C).length > 0,
- L = ['components', 'schemas'],
- { docExpansion: B, defaultModelsExpandDepth: $ } = w(),
- V = $ > 0 && 'none' !== B,
- U = i.isShown(L, V),
- z = _('Collapse'),
- Y = _('JSONSchema202012'),
- Z = _('ArrowUpIcon'),
- ee = _('ArrowDownIcon'),
- { getTitle: ie } = x.jsonSchema202012.useFn();
- (0, Pe.useEffect)(() => {
- const i = U && $ > 1,
- u = null != o.specResolvedSubtree(L);
- i && !u && s.requestResolvedSubtree(L);
- }, [U, $]);
- const ae = (0, Pe.useCallback)(() => {
- u.show(L, !U);
- }, [U]),
- le = (0, Pe.useCallback)((s) => {
- null !== s && u.readyToScroll(L, s);
- }, []),
- handleJSONSchema202012Ref = (s) => (o) => {
- null !== o && u.readyToScroll([...L, s], o);
- },
- handleJSONSchema202012Expand = (i) => (u, _) => {
- if (_) {
- const u = [...L, i];
- null != o.specResolvedSubtree(u) || s.requestResolvedSubtree([...L, i]);
- }
- };
- return !j || $ < 0
- ? null
- : Pe.createElement(
- 'section',
- { className: Hn()('models', { 'is-open': U }), ref: le },
- Pe.createElement(
- 'h4',
- null,
- Pe.createElement(
- 'button',
- { 'aria-expanded': U, className: 'models-control', onClick: ae },
- Pe.createElement('span', null, 'Schemas'),
- U ? Pe.createElement(Z, null) : Pe.createElement(ee, null)
- )
- ),
- Pe.createElement(
- z,
- { isOpened: U },
- Object.entries(C).map(([s, o]) => {
- const i = ie(o, { lookup: 'basic' }) || s;
- return Pe.createElement(Y, {
- key: s,
- ref: handleJSONSchema202012Ref(s),
- schema: o,
- name: i,
- onExpand: handleJSONSchema202012Expand(s)
- });
- })
- )
- );
- },
- mutual_tls_auth = ({ schema: s, getComponent: o }) => {
- const i = o('JumpToPath', !0);
- return Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'h4',
- null,
- s.get('name'),
- ' (mutualTLS)',
- ' ',
- Pe.createElement(i, { path: ['securityDefinitions', s.get('name')] })
- ),
- Pe.createElement(
- 'p',
- null,
- 'Mutual TLS is required by this API/Operation. Certificates are managed via your Operating System and/or your browser.'
- ),
- Pe.createElement('p', null, s.get('description'))
- );
- };
- class auths_Auths extends Pe.Component {
- constructor(s, o) {
- super(s, o), (this.state = {});
- }
- onAuthChange = (s) => {
- let { name: o } = s;
- this.setState({ [o]: s });
- };
- submitAuth = (s) => {
- s.preventDefault();
- let { authActions: o } = this.props;
- o.authorizeWithPersistOption(this.state);
- };
- logoutClick = (s) => {
- s.preventDefault();
- let { authActions: o, definitions: i } = this.props,
- u = i.map((s, o) => o).toArray();
- this.setState(u.reduce((s, o) => ((s[o] = ''), s), {})), o.logoutWithPersistOption(u);
- };
- close = (s) => {
- s.preventDefault();
- let { authActions: o } = this.props;
- o.showDefinitions(!1);
- };
- render() {
- let { definitions: s, getComponent: o, authSelectors: i, errSelectors: u } = this.props;
- const _ = o('AuthItem'),
- w = o('oauth2', !0),
- x = o('Button'),
- C = i.authorized(),
- j = s.filter((s, o) => !!C.get(o)),
- L = s.filter((s) => 'oauth2' !== s.get('type') && 'mutualTLS' !== s.get('type')),
- B = s.filter((s) => 'oauth2' === s.get('type')),
- $ = s.filter((s) => 'mutualTLS' === s.get('type'));
- return Pe.createElement(
- 'div',
- { className: 'auth-container' },
- L.size > 0 &&
- Pe.createElement(
- 'form',
- { onSubmit: this.submitAuth },
- L.map((s, i) =>
- Pe.createElement(_, {
- key: i,
- schema: s,
- name: i,
- getComponent: o,
- onAuthChange: this.onAuthChange,
- authorized: C,
- errSelectors: u
- })
- ).toArray(),
- Pe.createElement(
- 'div',
- { className: 'auth-btn-wrapper' },
- L.size === j.size
- ? Pe.createElement(
- x,
- {
- className: 'btn modal-btn auth',
- onClick: this.logoutClick,
- 'aria-label': 'Remove authorization'
- },
- 'Logout'
- )
- : Pe.createElement(
- x,
- {
- type: 'submit',
- className: 'btn modal-btn auth authorize',
- 'aria-label': 'Apply credentials'
- },
- 'Authorize'
- ),
- Pe.createElement(
- x,
- { className: 'btn modal-btn auth btn-done', onClick: this.close },
- 'Close'
- )
- )
- ),
- B.size > 0
- ? Pe.createElement(
- 'div',
- null,
- Pe.createElement(
- 'div',
- { className: 'scope-def' },
- Pe.createElement(
- 'p',
- null,
- 'Scopes are used to grant an application different levels of access to data on behalf of the end user. Each API may declare one or more scopes.'
- ),
- Pe.createElement(
- 'p',
- null,
- 'API requires the following scopes. Select which ones you want to grant to Swagger UI.'
- )
- ),
- s
- .filter((s) => 'oauth2' === s.get('type'))
- .map((s, o) =>
- Pe.createElement(
- 'div',
- { key: o },
- Pe.createElement(w, { authorized: C, schema: s, name: o })
- )
- )
- .toArray()
- )
- : null,
- $.size > 0 &&
- Pe.createElement(
- 'div',
- null,
- $.map((s, i) =>
- Pe.createElement(_, {
- key: i,
- schema: s,
- name: i,
- getComponent: o,
- onAuthChange: this.onAuthChange,
- authorized: C,
- errSelectors: u
- })
- ).toArray()
- )
- );
- }
- }
- const qA = auths_Auths,
- isOAS31 = (s) => {
- const o = s.get('openapi');
- return 'string' == typeof o && /^3\.1\.(?:[1-9]\d*|0)$/.test(o);
- },
- fn_createOnlyOAS31Selector =
- (s) =>
- (o, ...i) =>
- (u) => {
- if (u.getSystem().specSelectors.isOAS31()) {
- const _ = s(o, ...i);
- return 'function' == typeof _ ? _(u) : _;
- }
- return null;
- },
- createOnlyOAS31SelectorWrapper =
- (s) =>
- (o, i) =>
- (u, ..._) => {
- if (i.getSystem().specSelectors.isOAS31()) {
- const w = s(u, ..._);
- return 'function' == typeof w ? w(o, i) : w;
- }
- return o(..._);
- },
- fn_createSystemSelector =
- (s) =>
- (o, ...i) =>
- (u) => {
- const _ = s(o, u, ...i);
- return 'function' == typeof _ ? _(u) : _;
- },
- createOnlyOAS31ComponentWrapper = (s) => (o, i) => (u) =>
- i.specSelectors.isOAS31()
- ? Pe.createElement(s, Rn()({}, u, { originalComponent: o, getSystem: i.getSystem }))
- : Pe.createElement(o, u),
- $A = createOnlyOAS31ComponentWrapper(({ getSystem: s }) => {
- const o = s().getComponent('OAS31License', !0);
- return Pe.createElement(o, null);
- }),
- VA = createOnlyOAS31ComponentWrapper(({ getSystem: s }) => {
- const o = s().getComponent('OAS31Contact', !0);
- return Pe.createElement(o, null);
- }),
- UA = createOnlyOAS31ComponentWrapper(({ getSystem: s }) => {
- const o = s().getComponent('OAS31Info', !0);
- return Pe.createElement(o, null);
- }),
- zA = createOnlyOAS31ComponentWrapper(({ getSystem: s, ...o }) => {
- const i = s(),
- { getComponent: u, fn: _, getConfigs: w } = i,
- x = w(),
- C = u('OAS31Model'),
- j = u('JSONSchema202012'),
- L = u('JSONSchema202012Keyword$schema'),
- B = u('JSONSchema202012Keyword$vocabulary'),
- $ = u('JSONSchema202012Keyword$id'),
- V = u('JSONSchema202012Keyword$anchor'),
- U = u('JSONSchema202012Keyword$dynamicAnchor'),
- z = u('JSONSchema202012Keyword$ref'),
- Y = u('JSONSchema202012Keyword$dynamicRef'),
- Z = u('JSONSchema202012Keyword$defs'),
- ee = u('JSONSchema202012Keyword$comment'),
- ie = u('JSONSchema202012KeywordAllOf'),
- ae = u('JSONSchema202012KeywordAnyOf'),
- le = u('JSONSchema202012KeywordOneOf'),
- ce = u('JSONSchema202012KeywordNot'),
- pe = u('JSONSchema202012KeywordIf'),
- de = u('JSONSchema202012KeywordThen'),
- fe = u('JSONSchema202012KeywordElse'),
- ye = u('JSONSchema202012KeywordDependentSchemas'),
- be = u('JSONSchema202012KeywordPrefixItems'),
- _e = u('JSONSchema202012KeywordItems'),
- we = u('JSONSchema202012KeywordContains'),
- Se = u('JSONSchema202012KeywordProperties'),
- xe = u('JSONSchema202012KeywordPatternProperties'),
- Te = u('JSONSchema202012KeywordAdditionalProperties'),
- Re = u('JSONSchema202012KeywordPropertyNames'),
- qe = u('JSONSchema202012KeywordUnevaluatedItems'),
- $e = u('JSONSchema202012KeywordUnevaluatedProperties'),
- ze = u('JSONSchema202012KeywordType'),
- We = u('JSONSchema202012KeywordEnum'),
- He = u('JSONSchema202012KeywordConst'),
- Ye = u('JSONSchema202012KeywordConstraint'),
- Xe = u('JSONSchema202012KeywordDependentRequired'),
- Qe = u('JSONSchema202012KeywordContentSchema'),
- et = u('JSONSchema202012KeywordTitle'),
- tt = u('JSONSchema202012KeywordDescription'),
- rt = u('JSONSchema202012KeywordDefault'),
- nt = u('JSONSchema202012KeywordDeprecated'),
- st = u('JSONSchema202012KeywordReadOnly'),
- ot = u('JSONSchema202012KeywordWriteOnly'),
- it = u('JSONSchema202012Accordion'),
- at = u('JSONSchema202012ExpandDeepButton'),
- lt = u('JSONSchema202012ChevronRightIcon'),
- ct = u('withJSONSchema202012Context')(C, {
- config: {
- default$schema: 'https://spec.openapis.org/oas/3.1/dialect/base',
- defaultExpandedLevels: x.defaultModelExpandDepth,
- includeReadOnly: Boolean(o.includeReadOnly),
- includeWriteOnly: Boolean(o.includeWriteOnly)
- },
- components: {
- JSONSchema: j,
- Keyword$schema: L,
- Keyword$vocabulary: B,
- Keyword$id: $,
- Keyword$anchor: V,
- Keyword$dynamicAnchor: U,
- Keyword$ref: z,
- Keyword$dynamicRef: Y,
- Keyword$defs: Z,
- Keyword$comment: ee,
- KeywordAllOf: ie,
- KeywordAnyOf: ae,
- KeywordOneOf: le,
- KeywordNot: ce,
- KeywordIf: pe,
- KeywordThen: de,
- KeywordElse: fe,
- KeywordDependentSchemas: ye,
- KeywordPrefixItems: be,
- KeywordItems: _e,
- KeywordContains: we,
- KeywordProperties: Se,
- KeywordPatternProperties: xe,
- KeywordAdditionalProperties: Te,
- KeywordPropertyNames: Re,
- KeywordUnevaluatedItems: qe,
- KeywordUnevaluatedProperties: $e,
- KeywordType: ze,
- KeywordEnum: We,
- KeywordConst: He,
- KeywordConstraint: Ye,
- KeywordDependentRequired: Xe,
- KeywordContentSchema: Qe,
- KeywordTitle: et,
- KeywordDescription: tt,
- KeywordDefault: rt,
- KeywordDeprecated: nt,
- KeywordReadOnly: st,
- KeywordWriteOnly: ot,
- Accordion: it,
- ExpandDeepButton: at,
- ChevronRightIcon: lt
- },
- fn: {
- upperFirst: _.upperFirst,
- isExpandable: _.jsonSchema202012.isExpandable,
- getProperties: _.jsonSchema202012.getProperties
- }
- });
- return Pe.createElement(ct, o);
- }),
- WA = zA,
- KA = createOnlyOAS31ComponentWrapper(({ getSystem: s }) => {
- const { getComponent: o, fn: i, getConfigs: u } = s(),
- _ = u();
- if (KA.ModelsWithJSONSchemaContext)
- return Pe.createElement(KA.ModelsWithJSONSchemaContext, null);
- const w = o('OAS31Models', !0),
- x = o('JSONSchema202012'),
- C = o('JSONSchema202012Keyword$schema'),
- j = o('JSONSchema202012Keyword$vocabulary'),
- L = o('JSONSchema202012Keyword$id'),
- B = o('JSONSchema202012Keyword$anchor'),
- $ = o('JSONSchema202012Keyword$dynamicAnchor'),
- V = o('JSONSchema202012Keyword$ref'),
- U = o('JSONSchema202012Keyword$dynamicRef'),
- z = o('JSONSchema202012Keyword$defs'),
- Y = o('JSONSchema202012Keyword$comment'),
- Z = o('JSONSchema202012KeywordAllOf'),
- ee = o('JSONSchema202012KeywordAnyOf'),
- ie = o('JSONSchema202012KeywordOneOf'),
- ae = o('JSONSchema202012KeywordNot'),
- le = o('JSONSchema202012KeywordIf'),
- ce = o('JSONSchema202012KeywordThen'),
- pe = o('JSONSchema202012KeywordElse'),
- de = o('JSONSchema202012KeywordDependentSchemas'),
- fe = o('JSONSchema202012KeywordPrefixItems'),
- ye = o('JSONSchema202012KeywordItems'),
- be = o('JSONSchema202012KeywordContains'),
- _e = o('JSONSchema202012KeywordProperties'),
- we = o('JSONSchema202012KeywordPatternProperties'),
- Se = o('JSONSchema202012KeywordAdditionalProperties'),
- xe = o('JSONSchema202012KeywordPropertyNames'),
- Te = o('JSONSchema202012KeywordUnevaluatedItems'),
- Re = o('JSONSchema202012KeywordUnevaluatedProperties'),
- qe = o('JSONSchema202012KeywordType'),
- $e = o('JSONSchema202012KeywordEnum'),
- ze = o('JSONSchema202012KeywordConst'),
- We = o('JSONSchema202012KeywordConstraint'),
- He = o('JSONSchema202012KeywordDependentRequired'),
- Ye = o('JSONSchema202012KeywordContentSchema'),
- Xe = o('JSONSchema202012KeywordTitle'),
- Qe = o('JSONSchema202012KeywordDescription'),
- et = o('JSONSchema202012KeywordDefault'),
- tt = o('JSONSchema202012KeywordDeprecated'),
- rt = o('JSONSchema202012KeywordReadOnly'),
- nt = o('JSONSchema202012KeywordWriteOnly'),
- st = o('JSONSchema202012Accordion'),
- ot = o('JSONSchema202012ExpandDeepButton'),
- it = o('JSONSchema202012ChevronRightIcon'),
- at = o('withJSONSchema202012Context');
- return (
- (KA.ModelsWithJSONSchemaContext = at(w, {
- config: {
- default$schema: 'https://spec.openapis.org/oas/3.1/dialect/base',
- defaultExpandedLevels: _.defaultModelsExpandDepth - 1,
- includeReadOnly: !0,
- includeWriteOnly: !0
- },
- components: {
- JSONSchema: x,
- Keyword$schema: C,
- Keyword$vocabulary: j,
- Keyword$id: L,
- Keyword$anchor: B,
- Keyword$dynamicAnchor: $,
- Keyword$ref: V,
- Keyword$dynamicRef: U,
- Keyword$defs: z,
- Keyword$comment: Y,
- KeywordAllOf: Z,
- KeywordAnyOf: ee,
- KeywordOneOf: ie,
- KeywordNot: ae,
- KeywordIf: le,
- KeywordThen: ce,
- KeywordElse: pe,
- KeywordDependentSchemas: de,
- KeywordPrefixItems: fe,
- KeywordItems: ye,
- KeywordContains: be,
- KeywordProperties: _e,
- KeywordPatternProperties: we,
- KeywordAdditionalProperties: Se,
- KeywordPropertyNames: xe,
- KeywordUnevaluatedItems: Te,
- KeywordUnevaluatedProperties: Re,
- KeywordType: qe,
- KeywordEnum: $e,
- KeywordConst: ze,
- KeywordConstraint: We,
- KeywordDependentRequired: He,
- KeywordContentSchema: Ye,
- KeywordTitle: Xe,
- KeywordDescription: Qe,
- KeywordDefault: et,
- KeywordDeprecated: tt,
- KeywordReadOnly: rt,
- KeywordWriteOnly: nt,
- Accordion: st,
- ExpandDeepButton: ot,
- ChevronRightIcon: it
- },
- fn: {
- upperFirst: i.upperFirst,
- isExpandable: i.jsonSchema202012.isExpandable,
- getProperties: i.jsonSchema202012.getProperties
- }
- })),
- Pe.createElement(KA.ModelsWithJSONSchemaContext, null)
- );
- });
- KA.ModelsWithJSONSchemaContext = null;
- const HA = KA,
- wrap_components_version_pragma_filter = (s, o) => (s) => {
- const i = o.specSelectors.isOAS31(),
- u = o.getComponent('OAS31VersionPragmaFilter');
- return Pe.createElement(u, Rn()({ isOAS31: i }, s));
- },
- JA = createOnlyOAS31ComponentWrapper(({ originalComponent: s, ...o }) => {
- const { getComponent: i, schema: u } = o,
- _ = i('MutualTLSAuth', !0);
- return 'mutualTLS' === u.get('type')
- ? Pe.createElement(_, { schema: u })
- : Pe.createElement(s, o);
- }),
- GA = JA,
- YA = createOnlyOAS31ComponentWrapper(({ getSystem: s, ...o }) => {
- const i = s().getComponent('OAS31Auths', !0);
- return Pe.createElement(i, o);
- }),
- XA = (0, qe.Map)(),
- ZA = Ut((s, o) => o.specSelectors.specJson(), isOAS31),
- selectors_webhooks = () => (s) => {
- const o = s.specSelectors.specJson().get('webhooks');
- return qe.Map.isMap(o) ? o : XA;
- },
- QA = Ut(
- [
- (s, o) => o.specSelectors.webhooks(),
- (s, o) => o.specSelectors.validOperationMethods(),
- (s, o) => o.specSelectors.specResolvedSubtree(['webhooks'])
- ],
- (s, o) =>
- s
- .reduce(
- (s, i, u) => {
- if (!qe.Map.isMap(i)) return s;
- const _ = i
- .entrySeq()
- .filter(([s]) => o.includes(s))
- .map(([s, o]) => ({
- operation: (0, qe.Map)({ operation: o }),
- method: s,
- path: u,
- specPath: ['webhooks', u, s]
- }));
- return s.concat(_);
- },
- (0, qe.List)()
- )
- .groupBy((s) => s.path)
- .map((s) => s.toArray())
- .toObject()
- ),
- selectors_license = () => (s) => {
- const o = s.specSelectors.info().get('license');
- return qe.Map.isMap(o) ? o : XA;
- },
- selectLicenseNameField = () => (s) => s.specSelectors.license().get('name', 'License'),
- selectLicenseUrlField = () => (s) => s.specSelectors.license().get('url'),
- ej = Ut(
- [
- (s, o) => o.specSelectors.url(),
- (s, o) => o.oas3Selectors.selectedServer(),
- (s, o) => o.specSelectors.selectLicenseUrlField()
- ],
- (s, o, i) => {
- if (i) return safeBuildUrl(i, s, { selectedServer: o });
- }
- ),
- selectLicenseIdentifierField = () => (s) => s.specSelectors.license().get('identifier'),
- selectors_contact = () => (s) => {
- const o = s.specSelectors.info().get('contact');
- return qe.Map.isMap(o) ? o : XA;
- },
- selectContactNameField = () => (s) =>
- s.specSelectors.contact().get('name', 'the developer'),
- selectContactEmailField = () => (s) => s.specSelectors.contact().get('email'),
- selectContactUrlField = () => (s) => s.specSelectors.contact().get('url'),
- fj = Ut(
- [
- (s, o) => o.specSelectors.url(),
- (s, o) => o.oas3Selectors.selectedServer(),
- (s, o) => o.specSelectors.selectContactUrlField()
- ],
- (s, o, i) => {
- if (i) return safeBuildUrl(i, s, { selectedServer: o });
- }
- ),
- selectInfoTitleField = () => (s) => s.specSelectors.info().get('title'),
- selectInfoSummaryField = () => (s) => s.specSelectors.info().get('summary'),
- selectInfoDescriptionField = () => (s) => s.specSelectors.info().get('description'),
- selectInfoTermsOfServiceField = () => (s) => s.specSelectors.info().get('termsOfService'),
- mj = Ut(
- [
- (s, o) => o.specSelectors.url(),
- (s, o) => o.oas3Selectors.selectedServer(),
- (s, o) => o.specSelectors.selectInfoTermsOfServiceField()
- ],
- (s, o, i) => {
- if (i) return safeBuildUrl(i, s, { selectedServer: o });
- }
- ),
- selectExternalDocsDescriptionField = () => (s) =>
- s.specSelectors.externalDocs().get('description'),
- selectExternalDocsUrlField = () => (s) => s.specSelectors.externalDocs().get('url'),
- _j = Ut(
- [
- (s, o) => o.specSelectors.url(),
- (s, o) => o.oas3Selectors.selectedServer(),
- (s, o) => o.specSelectors.selectExternalDocsUrlField()
- ],
- (s, o, i) => {
- if (i) return safeBuildUrl(i, s, { selectedServer: o });
- }
- ),
- selectJsonSchemaDialectField = () => (s) =>
- s.specSelectors.specJson().get('jsonSchemaDialect'),
- selectJsonSchemaDialectDefault = () => 'https://spec.openapis.org/oas/3.1/dialect/base',
- Cj = Ut(
- (s, o) => o.specSelectors.definitions(),
- (s, o) => o.specSelectors.specResolvedSubtree(['components', 'schemas']),
- (s, o) =>
- qe.Map.isMap(s)
- ? qe.Map.isMap(o)
- ? Object.entries(s.toJS()).reduce((s, [i, u]) => {
- const _ = o.get(i);
- return (s[i] = _?.toJS() || u), s;
- }, {})
- : s.toJS()
- : {}
- ),
- wrap_selectors_isOAS3 =
- (s, o) =>
- (i, ...u) =>
- o.specSelectors.isOAS31() || s(...u),
- Aj = createOnlyOAS31SelectorWrapper(() => (s, o) => o.oas31Selectors.selectLicenseUrl()),
- Nj = createOnlyOAS31SelectorWrapper(() => (s, o) => {
- const i = o.specSelectors.securityDefinitions();
- let u = s();
- return i
- ? (i.entrySeq().forEach(([s, o]) => {
- 'mutualTLS' === o.get('type') && (u = u.push(new qe.Map({ [s]: o })));
- }),
- u)
- : u;
- }),
- Bj = Ut(
- [
- (s, o) => o.specSelectors.url(),
- (s, o) => o.oas3Selectors.selectedServer(),
- (s, o) => o.specSelectors.selectLicenseUrlField(),
- (s, o) => o.specSelectors.selectLicenseIdentifierField()
- ],
- (s, o, i, u) =>
- i
- ? safeBuildUrl(i, s, { selectedServer: o })
- : u
- ? `https://spdx.org/licenses/${u}.html`
- : void 0
- ),
- keywords_Example = ({ schema: s, getSystem: o }) => {
- const { fn: i } = o(),
- { hasKeyword: u, stringify: _ } = i.jsonSchema202012.useFn();
- return u(s, 'example')
- ? Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--example' },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- 'Example'
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--const'
- },
- _(s.example)
- )
- )
- : null;
- },
- keywords_Xml = ({ schema: s, getSystem: o }) => {
- const i = s?.xml || {},
- { fn: u, getComponent: _ } = o(),
- { useIsExpandedDeeply: w, useComponent: x } = u.jsonSchema202012,
- C = w(),
- j = !!(i.name || i.namespace || i.prefix),
- [L, B] = (0, Pe.useState)(C),
- [$, V] = (0, Pe.useState)(!1),
- U = x('Accordion'),
- z = x('ExpandDeepButton'),
- Y = _('JSONSchema202012DeepExpansionContext')(),
- Z = (0, Pe.useCallback)(() => {
- B((s) => !s);
- }, []),
- ee = (0, Pe.useCallback)((s, o) => {
- B(o), V(o);
- }, []);
- return 0 === Object.keys(i).length
- ? null
- : Pe.createElement(
- Y.Provider,
- { value: $ },
- Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--xml' },
- j
- ? Pe.createElement(
- Pe.Fragment,
- null,
- Pe.createElement(
- U,
- { expanded: L, onChange: Z },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- 'XML'
- )
- ),
- Pe.createElement(z, { expanded: L, onClick: ee })
- )
- : Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- 'XML'
- ),
- !0 === i.attribute &&
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12__attribute json-schema-2020-12__attribute--muted'
- },
- 'attribute'
- ),
- !0 === i.wrapped &&
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12__attribute json-schema-2020-12__attribute--muted'
- },
- 'wrapped'
- ),
- Pe.createElement(
- 'strong',
- {
- className:
- 'json-schema-2020-12__attribute json-schema-2020-12__attribute--primary'
- },
- 'object'
- ),
- Pe.createElement(
- 'ul',
- {
- className: Hn()('json-schema-2020-12-keyword__children', {
- 'json-schema-2020-12-keyword__children--collapsed': !L
- })
- },
- L &&
- Pe.createElement(
- Pe.Fragment,
- null,
- i.name &&
- Pe.createElement(
- 'li',
- { className: 'json-schema-2020-12-property' },
- Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword'
- },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- 'name'
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary'
- },
- i.name
- )
- )
- ),
- i.namespace &&
- Pe.createElement(
- 'li',
- { className: 'json-schema-2020-12-property' },
- Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword' },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- 'namespace'
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary'
- },
- i.namespace
- )
- )
- ),
- i.prefix &&
- Pe.createElement(
- 'li',
- { className: 'json-schema-2020-12-property' },
- Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword' },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- 'prefix'
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary'
- },
- i.prefix
- )
- )
- )
- )
- )
- )
- );
- },
- Discriminator_DiscriminatorMapping = ({ discriminator: s }) => {
- const o = s?.mapping || {};
- return 0 === Object.keys(o).length
- ? null
- : Object.entries(o).map(([s, o]) =>
- Pe.createElement(
- 'div',
- { key: `${s}-${o}`, className: 'json-schema-2020-12-keyword' },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- s
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary'
- },
- o
- )
- )
- );
- },
- keywords_Discriminator_Discriminator = ({ schema: s, getSystem: o }) => {
- const i = s?.discriminator || {},
- { fn: u, getComponent: _ } = o(),
- { useIsExpandedDeeply: w, useComponent: x } = u.jsonSchema202012,
- C = w(),
- j = !!i.mapping,
- [L, B] = (0, Pe.useState)(C),
- [$, V] = (0, Pe.useState)(!1),
- U = x('Accordion'),
- z = x('ExpandDeepButton'),
- Y = _('JSONSchema202012DeepExpansionContext')(),
- Z = (0, Pe.useCallback)(() => {
- B((s) => !s);
- }, []),
- ee = (0, Pe.useCallback)((s, o) => {
- B(o), V(o);
- }, []);
- return 0 === Object.keys(i).length
- ? null
- : Pe.createElement(
- Y.Provider,
- { value: $ },
- Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword--discriminator'
- },
- j
- ? Pe.createElement(
- Pe.Fragment,
- null,
- Pe.createElement(
- U,
- { expanded: L, onChange: Z },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- 'Discriminator'
- )
- ),
- Pe.createElement(z, { expanded: L, onClick: ee })
- )
- : Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- 'Discriminator'
- ),
- i.propertyName &&
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12__attribute json-schema-2020-12__attribute--muted'
- },
- i.propertyName
- ),
- Pe.createElement(
- 'strong',
- {
- className:
- 'json-schema-2020-12__attribute json-schema-2020-12__attribute--primary'
- },
- 'object'
- ),
- Pe.createElement(
- 'ul',
- {
- className: Hn()('json-schema-2020-12-keyword__children', {
- 'json-schema-2020-12-keyword__children--collapsed': !L
- })
- },
- L &&
- Pe.createElement(
- 'li',
- { className: 'json-schema-2020-12-property' },
- Pe.createElement(Discriminator_DiscriminatorMapping, { discriminator: i })
- )
- )
- )
- );
- },
- keywords_ExternalDocs = ({ schema: s, getSystem: o }) => {
- const i = s?.externalDocs || {},
- { fn: u, getComponent: _ } = o(),
- { useIsExpandedDeeply: w, useComponent: x } = u.jsonSchema202012,
- C = w(),
- j = !(!i.description && !i.url),
- [L, B] = (0, Pe.useState)(C),
- [$, V] = (0, Pe.useState)(!1),
- U = x('Accordion'),
- z = x('ExpandDeepButton'),
- Y = _('JSONSchema202012KeywordDescription'),
- Z = _('Link'),
- ee = _('JSONSchema202012DeepExpansionContext')(),
- ie = (0, Pe.useCallback)(() => {
- B((s) => !s);
- }, []),
- ae = (0, Pe.useCallback)((s, o) => {
- B(o), V(o);
- }, []);
- return 0 === Object.keys(i).length
- ? null
- : Pe.createElement(
- ee.Provider,
- { value: $ },
- Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword--externalDocs'
- },
- j
- ? Pe.createElement(
- Pe.Fragment,
- null,
- Pe.createElement(
- U,
- { expanded: L, onChange: ie },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- 'External documentation'
- )
- ),
- Pe.createElement(z, { expanded: L, onClick: ae })
- )
- : Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- 'External documentation'
- ),
- Pe.createElement(
- 'strong',
- {
- className:
- 'json-schema-2020-12__attribute json-schema-2020-12__attribute--primary'
- },
- 'object'
- ),
- Pe.createElement(
- 'ul',
- {
- className: Hn()('json-schema-2020-12-keyword__children', {
- 'json-schema-2020-12-keyword__children--collapsed': !L
- })
- },
- L &&
- Pe.createElement(
- Pe.Fragment,
- null,
- i.description &&
- Pe.createElement(
- 'li',
- { className: 'json-schema-2020-12-property' },
- Pe.createElement(Y, { schema: i, getSystem: o })
- ),
- i.url &&
- Pe.createElement(
- 'li',
- { className: 'json-schema-2020-12-property' },
- Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword'
- },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- 'url'
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary'
- },
- Pe.createElement(
- Z,
- { target: '_blank', href: sanitizeUrl(i.url) },
- i.url
- )
- )
- )
- )
- )
- )
- )
- );
- },
- keywords_Description = ({ schema: s, getSystem: o }) => {
- if (!s?.description) return null;
- const { getComponent: i } = o(),
- u = i('Markdown');
- return Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--description' },
- Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-core-keyword__value json-schema-2020-12-core-keyword__value--secondary'
- },
- Pe.createElement(u, { source: s.description })
- )
- );
- },
- $j = createOnlyOAS31ComponentWrapper(keywords_Description),
- zj = createOnlyOAS31ComponentWrapper(
- ({ schema: s, getSystem: o, originalComponent: i }) => {
- const { getComponent: u } = o(),
- _ = u('JSONSchema202012KeywordDiscriminator'),
- w = u('JSONSchema202012KeywordXml'),
- x = u('JSONSchema202012KeywordExample'),
- C = u('JSONSchema202012KeywordExternalDocs');
- return Pe.createElement(
- Pe.Fragment,
- null,
- Pe.createElement(i, { schema: s }),
- Pe.createElement(_, { schema: s, getSystem: o }),
- Pe.createElement(w, { schema: s, getSystem: o }),
- Pe.createElement(C, { schema: s, getSystem: o }),
- Pe.createElement(x, { schema: s, getSystem: o })
- );
- }
- ),
- Kj = zj,
- keywords_Properties = ({ schema: s, getSystem: o }) => {
- const { fn: i } = o(),
- { useComponent: u } = i.jsonSchema202012,
- { getDependentRequired: _, getProperties: w } = i.jsonSchema202012.useFn(),
- x = i.jsonSchema202012.useConfig(),
- C = Array.isArray(s?.required) ? s.required : [],
- j = u('JSONSchema'),
- L = w(s, x);
- return 0 === Object.keys(L).length
- ? null
- : Pe.createElement(
- 'div',
- {
- className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--properties'
- },
- Pe.createElement(
- 'ul',
- null,
- Object.entries(L).map(([o, i]) => {
- const u = C.includes(o),
- w = _(o, s);
- return Pe.createElement(
- 'li',
- {
- key: o,
- className: Hn()('json-schema-2020-12-property', {
- 'json-schema-2020-12-property--required': u
- })
- },
- Pe.createElement(j, { name: o, schema: i, dependentRequired: w })
- );
- })
- )
- );
- },
- Jj = createOnlyOAS31ComponentWrapper(keywords_Properties),
- getProperties = (s, { includeReadOnly: o, includeWriteOnly: i }) => {
- if (!s?.properties) return {};
- const u = Object.entries(s.properties).filter(
- ([, s]) => (!(!0 === s?.readOnly) || o) && (!(!0 === s?.writeOnly) || i)
- );
- return Object.fromEntries(u);
- };
- const Gj = function oas31_after_load_afterLoad({ fn: s, getSystem: o }) {
- if (s.jsonSchema202012) {
- const i = ((s, o) => {
- const { fn: i } = o();
- if ('function' != typeof s) return null;
- const { hasKeyword: u } = i.jsonSchema202012;
- return (o) =>
- s(o) || u(o, 'example') || o?.xml || o?.discriminator || o?.externalDocs;
- })(s.jsonSchema202012.isExpandable, o);
- Object.assign(this.fn.jsonSchema202012, { isExpandable: i, getProperties });
- }
- if ('function' == typeof s.sampleFromSchema && s.jsonSchema202012) {
- const i = ((s, o) => {
- const { fn: i, specSelectors: u } = o;
- return Object.fromEntries(
- Object.entries(s).map(([s, o]) => {
- const _ = i[s];
- return [
- s,
- (...s) => (u.isOAS31() ? o(...s) : 'function' == typeof _ ? _(...s) : void 0)
- ];
- })
- );
- })(
- {
- sampleFromSchema: s.jsonSchema202012.sampleFromSchema,
- sampleFromSchemaGeneric: s.jsonSchema202012.sampleFromSchemaGeneric,
- createXMLExample: s.jsonSchema202012.createXMLExample,
- memoizedSampleFromSchema: s.jsonSchema202012.memoizedSampleFromSchema,
- memoizedCreateXMLExample: s.jsonSchema202012.memoizedCreateXMLExample,
- getJsonSampleSchema: s.jsonSchema202012.getJsonSampleSchema,
- getYamlSampleSchema: s.jsonSchema202012.getYamlSampleSchema,
- getXmlSampleSchema: s.jsonSchema202012.getXmlSampleSchema,
- getSampleSchema: s.jsonSchema202012.getSampleSchema,
- mergeJsonSchema: s.jsonSchema202012.mergeJsonSchema
- },
- o()
- );
- Object.assign(this.fn, i);
- }
- },
- oas31 = ({ fn: s }) => {
- const o = s.createSystemSelector || fn_createSystemSelector,
- i = s.createOnlyOAS31Selector || fn_createOnlyOAS31Selector;
- return {
- afterLoad: Gj,
- fn: {
- isOAS31,
- createSystemSelector: fn_createSystemSelector,
- createOnlyOAS31Selector: fn_createOnlyOAS31Selector
- },
- components: {
- Webhooks: webhooks,
- JsonSchemaDialect: json_schema_dialect,
- MutualTLSAuth: mutual_tls_auth,
- OAS31Info: oas31_components_info,
- OAS31License: oas31_components_license,
- OAS31Contact: oas31_components_contact,
- OAS31VersionPragmaFilter: version_pragma_filter,
- OAS31Model: FA,
- OAS31Models: models,
- OAS31Auths: qA,
- JSONSchema202012KeywordExample: keywords_Example,
- JSONSchema202012KeywordXml: keywords_Xml,
- JSONSchema202012KeywordDiscriminator: keywords_Discriminator_Discriminator,
- JSONSchema202012KeywordExternalDocs: keywords_ExternalDocs
- },
- wrapComponents: {
- InfoContainer: UA,
- License: $A,
- Contact: VA,
- VersionPragmaFilter: wrap_components_version_pragma_filter,
- Model: WA,
- Models: HA,
- AuthItem: GA,
- auths: YA,
- JSONSchema202012KeywordDescription: $j,
- JSONSchema202012KeywordDefault: Kj,
- JSONSchema202012KeywordProperties: Jj
- },
- statePlugins: {
- auth: { wrapSelectors: { definitionsToAuthorize: Nj } },
- spec: {
- selectors: {
- isOAS31: o(ZA),
- license: selectors_license,
- selectLicenseNameField,
- selectLicenseUrlField,
- selectLicenseIdentifierField: i(selectLicenseIdentifierField),
- selectLicenseUrl: o(ej),
- contact: selectors_contact,
- selectContactNameField,
- selectContactEmailField,
- selectContactUrlField,
- selectContactUrl: o(fj),
- selectInfoTitleField,
- selectInfoSummaryField: i(selectInfoSummaryField),
- selectInfoDescriptionField,
- selectInfoTermsOfServiceField,
- selectInfoTermsOfServiceUrl: o(mj),
- selectExternalDocsDescriptionField,
- selectExternalDocsUrlField,
- selectExternalDocsUrl: o(_j),
- webhooks: i(selectors_webhooks),
- selectWebhooksOperations: i(o(QA)),
- selectJsonSchemaDialectField,
- selectJsonSchemaDialectDefault,
- selectSchemas: o(Cj)
- },
- wrapSelectors: { isOAS3: wrap_selectors_isOAS3, selectLicenseUrl: Aj }
- },
- oas31: { selectors: { selectLicenseUrl: i(o(Bj)) } }
- }
- };
- },
- Xj = ts().object,
- eI = ts().bool,
- tI = (ts().oneOfType([Xj, eI]), (0, Pe.createContext)(null));
- tI.displayName = 'JSONSchemaContext';
- const rI = (0, Pe.createContext)(0);
- rI.displayName = 'JSONSchemaLevelContext';
- const nI = (0, Pe.createContext)(!1);
- nI.displayName = 'JSONSchemaDeepExpansionContext';
- const sI = (0, Pe.createContext)(new Set()),
- useConfig = () => {
- const { config: s } = (0, Pe.useContext)(tI);
- return s;
- },
- useComponent = (s) => {
- const { components: o } = (0, Pe.useContext)(tI);
- return o[s] || null;
- },
- useFn = (s = void 0) => {
- const { fn: o } = (0, Pe.useContext)(tI);
- return void 0 !== s ? o[s] : o;
- },
- useLevel = () => {
- const s = (0, Pe.useContext)(rI);
- return [s, s + 1];
- },
- useIsExpanded = () => {
- const [s] = useLevel(),
- { defaultExpandedLevels: o } = useConfig();
- return o - s > 0;
- },
- useIsExpandedDeeply = () => (0, Pe.useContext)(nI),
- useRenderedSchemas = (s = void 0) => {
- if (void 0 === s) return (0, Pe.useContext)(sI);
- const o = (0, Pe.useContext)(sI);
- return new Set([...o, s]);
- },
- oI = (0, Pe.forwardRef)(
- ({ schema: s, name: o = '', dependentRequired: i = [], onExpand: u = () => {} }, _) => {
- const w = useFn(),
- x = useIsExpanded(),
- C = useIsExpandedDeeply(),
- [j, L] = (0, Pe.useState)(x || C),
- [B, $] = (0, Pe.useState)(C),
- [V, U] = useLevel(),
- z = (() => {
- const [s] = useLevel();
- return s > 0;
- })(),
- Y = w.isExpandable(s) || i.length > 0,
- Z = ((s) => useRenderedSchemas().has(s))(s),
- ee = useRenderedSchemas(s),
- ie = w.stringifyConstraints(s),
- ae = useComponent('Accordion'),
- le = useComponent('Keyword$schema'),
- ce = useComponent('Keyword$vocabulary'),
- pe = useComponent('Keyword$id'),
- de = useComponent('Keyword$anchor'),
- fe = useComponent('Keyword$dynamicAnchor'),
- ye = useComponent('Keyword$ref'),
- be = useComponent('Keyword$dynamicRef'),
- _e = useComponent('Keyword$defs'),
- we = useComponent('Keyword$comment'),
- Se = useComponent('KeywordAllOf'),
- xe = useComponent('KeywordAnyOf'),
- Te = useComponent('KeywordOneOf'),
- Re = useComponent('KeywordNot'),
- qe = useComponent('KeywordIf'),
- $e = useComponent('KeywordThen'),
- ze = useComponent('KeywordElse'),
- We = useComponent('KeywordDependentSchemas'),
- He = useComponent('KeywordPrefixItems'),
- Ye = useComponent('KeywordItems'),
- Xe = useComponent('KeywordContains'),
- Qe = useComponent('KeywordProperties'),
- et = useComponent('KeywordPatternProperties'),
- tt = useComponent('KeywordAdditionalProperties'),
- rt = useComponent('KeywordPropertyNames'),
- nt = useComponent('KeywordUnevaluatedItems'),
- st = useComponent('KeywordUnevaluatedProperties'),
- ot = useComponent('KeywordType'),
- it = useComponent('KeywordEnum'),
- at = useComponent('KeywordConst'),
- lt = useComponent('KeywordConstraint'),
- ct = useComponent('KeywordDependentRequired'),
- ut = useComponent('KeywordContentSchema'),
- pt = useComponent('KeywordTitle'),
- ht = useComponent('KeywordDescription'),
- dt = useComponent('KeywordDefault'),
- mt = useComponent('KeywordDeprecated'),
- gt = useComponent('KeywordReadOnly'),
- yt = useComponent('KeywordWriteOnly'),
- vt = useComponent('ExpandDeepButton');
- (0, Pe.useEffect)(() => {
- $(C);
- }, [C]),
- (0, Pe.useEffect)(() => {
- $(B);
- }, [B]);
- const bt = (0, Pe.useCallback)(
- (s, o) => {
- L(o), !o && $(!1), u(s, o, !1);
- },
- [u]
- ),
- _t = (0, Pe.useCallback)(
- (s, o) => {
- L(o), $(o), u(s, o, !0);
- },
- [u]
- );
- return Pe.createElement(
- rI.Provider,
- { value: U },
- Pe.createElement(
- nI.Provider,
- { value: B },
- Pe.createElement(
- sI.Provider,
- { value: ee },
- Pe.createElement(
- 'article',
- {
- ref: _,
- 'data-json-schema-level': V,
- className: Hn()('json-schema-2020-12', {
- 'json-schema-2020-12--embedded': z,
- 'json-schema-2020-12--circular': Z
- })
- },
- Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-head' },
- Y && !Z
- ? Pe.createElement(
- Pe.Fragment,
- null,
- Pe.createElement(
- ae,
- { expanded: j, onChange: bt },
- Pe.createElement(pt, { title: o, schema: s })
- ),
- Pe.createElement(vt, { expanded: j, onClick: _t })
- )
- : Pe.createElement(pt, { title: o, schema: s }),
- Pe.createElement(mt, { schema: s }),
- Pe.createElement(gt, { schema: s }),
- Pe.createElement(yt, { schema: s }),
- Pe.createElement(ot, { schema: s, isCircular: Z }),
- ie.length > 0 &&
- ie.map((s) =>
- Pe.createElement(lt, { key: `${s.scope}-${s.value}`, constraint: s })
- )
- ),
- Pe.createElement(
- 'div',
- {
- className: Hn()('json-schema-2020-12-body', {
- 'json-schema-2020-12-body--collapsed': !j
- })
- },
- j &&
- Pe.createElement(
- Pe.Fragment,
- null,
- Pe.createElement(ht, { schema: s }),
- !Z &&
- Y &&
- Pe.createElement(
- Pe.Fragment,
- null,
- Pe.createElement(Qe, { schema: s }),
- Pe.createElement(et, { schema: s }),
- Pe.createElement(tt, { schema: s }),
- Pe.createElement(st, { schema: s }),
- Pe.createElement(rt, { schema: s }),
- Pe.createElement(Se, { schema: s }),
- Pe.createElement(xe, { schema: s }),
- Pe.createElement(Te, { schema: s }),
- Pe.createElement(Re, { schema: s }),
- Pe.createElement(qe, { schema: s }),
- Pe.createElement($e, { schema: s }),
- Pe.createElement(ze, { schema: s }),
- Pe.createElement(We, { schema: s }),
- Pe.createElement(He, { schema: s }),
- Pe.createElement(Ye, { schema: s }),
- Pe.createElement(nt, { schema: s }),
- Pe.createElement(Xe, { schema: s }),
- Pe.createElement(ut, { schema: s })
- ),
- Pe.createElement(it, { schema: s }),
- Pe.createElement(at, { schema: s }),
- Pe.createElement(ct, { schema: s, dependentRequired: i }),
- Pe.createElement(dt, { schema: s }),
- Pe.createElement(le, { schema: s }),
- Pe.createElement(ce, { schema: s }),
- Pe.createElement(pe, { schema: s }),
- Pe.createElement(de, { schema: s }),
- Pe.createElement(fe, { schema: s }),
- Pe.createElement(ye, { schema: s }),
- !Z && Y && Pe.createElement(_e, { schema: s }),
- Pe.createElement(be, { schema: s }),
- Pe.createElement(we, { schema: s })
- )
- )
- )
- )
- )
- );
- }
- ),
- iI = oI,
- keywords_$schema = ({ schema: s }) =>
- s?.$schema
- ? Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--$schema' },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- '$schema'
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary'
- },
- s.$schema
- )
- )
- : null,
- $vocabulary_$vocabulary = ({ schema: s }) => {
- const o = useIsExpanded(),
- i = useIsExpandedDeeply(),
- [u, _] = (0, Pe.useState)(o || i),
- w = useComponent('Accordion'),
- x = (0, Pe.useCallback)(() => {
- _((s) => !s);
- }, []);
- return s?.$vocabulary
- ? 'object' != typeof s.$vocabulary
- ? null
- : Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword--$vocabulary'
- },
- Pe.createElement(
- w,
- { expanded: u, onChange: x },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- '$vocabulary'
- )
- ),
- Pe.createElement(
- 'strong',
- {
- className:
- 'json-schema-2020-12__attribute json-schema-2020-12__attribute--primary'
- },
- 'object'
- ),
- Pe.createElement(
- 'ul',
- null,
- u &&
- Object.entries(s.$vocabulary).map(([s, o]) =>
- Pe.createElement(
- 'li',
- {
- key: s,
- className: Hn()('json-schema-2020-12-$vocabulary-uri', {
- 'json-schema-2020-12-$vocabulary-uri--disabled': !o
- })
- },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary'
- },
- s
- )
- )
- )
- )
- )
- : null;
- },
- keywords_$id = ({ schema: s }) =>
- s?.$id
- ? Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--$id' },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- '$id'
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary'
- },
- s.$id
- )
- )
- : null,
- keywords_$anchor = ({ schema: s }) =>
- s?.$anchor
- ? Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--$anchor' },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- '$anchor'
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary'
- },
- s.$anchor
- )
- )
- : null,
- keywords_$dynamicAnchor = ({ schema: s }) =>
- s?.$dynamicAnchor
- ? Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword--$dynamicAnchor'
- },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- '$dynamicAnchor'
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary'
- },
- s.$dynamicAnchor
- )
- )
- : null,
- keywords_$ref = ({ schema: s }) =>
- s?.$ref
- ? Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--$ref' },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- '$ref'
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary'
- },
- s.$ref
- )
- )
- : null,
- keywords_$dynamicRef = ({ schema: s }) =>
- s?.$dynamicRef
- ? Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword--$dynamicRef'
- },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- '$dynamicRef'
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary'
- },
- s.$dynamicRef
- )
- )
- : null,
- keywords_$defs = ({ schema: s }) => {
- const o = s?.$defs || {},
- i = useIsExpanded(),
- u = useIsExpandedDeeply(),
- [_, w] = (0, Pe.useState)(i || u),
- [x, C] = (0, Pe.useState)(!1),
- j = useComponent('Accordion'),
- L = useComponent('ExpandDeepButton'),
- B = useComponent('JSONSchema'),
- $ = (0, Pe.useCallback)(() => {
- w((s) => !s);
- }, []),
- V = (0, Pe.useCallback)((s, o) => {
- w(o), C(o);
- }, []);
- return 0 === Object.keys(o).length
- ? null
- : Pe.createElement(
- nI.Provider,
- { value: x },
- Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--$defs' },
- Pe.createElement(
- j,
- { expanded: _, onChange: $ },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- '$defs'
- )
- ),
- Pe.createElement(L, { expanded: _, onClick: V }),
- Pe.createElement(
- 'strong',
- {
- className:
- 'json-schema-2020-12__attribute json-schema-2020-12__attribute--primary'
- },
- 'object'
- ),
- Pe.createElement(
- 'ul',
- {
- className: Hn()('json-schema-2020-12-keyword__children', {
- 'json-schema-2020-12-keyword__children--collapsed': !_
- })
- },
- _ &&
- Pe.createElement(
- Pe.Fragment,
- null,
- Object.entries(o).map(([s, o]) =>
- Pe.createElement(
- 'li',
- { key: s, className: 'json-schema-2020-12-property' },
- Pe.createElement(B, { name: s, schema: o })
- )
- )
- )
- )
- )
- );
- },
- keywords_$comment = ({ schema: s }) =>
- s?.$comment
- ? Pe.createElement(
- 'div',
- {
- className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--$comment'
- },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--secondary'
- },
- '$comment'
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--secondary'
- },
- s.$comment
- )
- )
- : null,
- keywords_AllOf = ({ schema: s }) => {
- const o = s?.allOf || [],
- i = useFn(),
- u = useIsExpanded(),
- _ = useIsExpandedDeeply(),
- [w, x] = (0, Pe.useState)(u || _),
- [C, j] = (0, Pe.useState)(!1),
- L = useComponent('Accordion'),
- B = useComponent('ExpandDeepButton'),
- $ = useComponent('JSONSchema'),
- V = useComponent('KeywordType'),
- U = (0, Pe.useCallback)(() => {
- x((s) => !s);
- }, []),
- z = (0, Pe.useCallback)((s, o) => {
- x(o), j(o);
- }, []);
- return Array.isArray(o) && 0 !== o.length
- ? Pe.createElement(
- nI.Provider,
- { value: C },
- Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--allOf' },
- Pe.createElement(
- L,
- { expanded: w, onChange: U },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'All of'
- )
- ),
- Pe.createElement(B, { expanded: w, onClick: z }),
- Pe.createElement(V, { schema: { allOf: o } }),
- Pe.createElement(
- 'ul',
- {
- className: Hn()('json-schema-2020-12-keyword__children', {
- 'json-schema-2020-12-keyword__children--collapsed': !w
- })
- },
- w &&
- Pe.createElement(
- Pe.Fragment,
- null,
- o.map((s, o) =>
- Pe.createElement(
- 'li',
- { key: `#${o}`, className: 'json-schema-2020-12-property' },
- Pe.createElement($, { name: `#${o} ${i.getTitle(s)}`, schema: s })
- )
- )
- )
- )
- )
- )
- : null;
- },
- keywords_AnyOf = ({ schema: s }) => {
- const o = s?.anyOf || [],
- i = useFn(),
- u = useIsExpanded(),
- _ = useIsExpandedDeeply(),
- [w, x] = (0, Pe.useState)(u || _),
- [C, j] = (0, Pe.useState)(!1),
- L = useComponent('Accordion'),
- B = useComponent('ExpandDeepButton'),
- $ = useComponent('JSONSchema'),
- V = useComponent('KeywordType'),
- U = (0, Pe.useCallback)(() => {
- x((s) => !s);
- }, []),
- z = (0, Pe.useCallback)((s, o) => {
- x(o), j(o);
- }, []);
- return Array.isArray(o) && 0 !== o.length
- ? Pe.createElement(
- nI.Provider,
- { value: C },
- Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--anyOf' },
- Pe.createElement(
- L,
- { expanded: w, onChange: U },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Any of'
- )
- ),
- Pe.createElement(B, { expanded: w, onClick: z }),
- Pe.createElement(V, { schema: { anyOf: o } }),
- Pe.createElement(
- 'ul',
- {
- className: Hn()('json-schema-2020-12-keyword__children', {
- 'json-schema-2020-12-keyword__children--collapsed': !w
- })
- },
- w &&
- Pe.createElement(
- Pe.Fragment,
- null,
- o.map((s, o) =>
- Pe.createElement(
- 'li',
- { key: `#${o}`, className: 'json-schema-2020-12-property' },
- Pe.createElement($, { name: `#${o} ${i.getTitle(s)}`, schema: s })
- )
- )
- )
- )
- )
- )
- : null;
- },
- keywords_OneOf = ({ schema: s }) => {
- const o = s?.oneOf || [],
- i = useFn(),
- u = useIsExpanded(),
- _ = useIsExpandedDeeply(),
- [w, x] = (0, Pe.useState)(u || _),
- [C, j] = (0, Pe.useState)(!1),
- L = useComponent('Accordion'),
- B = useComponent('ExpandDeepButton'),
- $ = useComponent('JSONSchema'),
- V = useComponent('KeywordType'),
- U = (0, Pe.useCallback)(() => {
- x((s) => !s);
- }, []),
- z = (0, Pe.useCallback)((s, o) => {
- x(o), j(o);
- }, []);
- return Array.isArray(o) && 0 !== o.length
- ? Pe.createElement(
- nI.Provider,
- { value: C },
- Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--oneOf' },
- Pe.createElement(
- L,
- { expanded: w, onChange: U },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'One of'
- )
- ),
- Pe.createElement(B, { expanded: w, onClick: z }),
- Pe.createElement(V, { schema: { oneOf: o } }),
- Pe.createElement(
- 'ul',
- {
- className: Hn()('json-schema-2020-12-keyword__children', {
- 'json-schema-2020-12-keyword__children--collapsed': !w
- })
- },
- w &&
- Pe.createElement(
- Pe.Fragment,
- null,
- o.map((s, o) =>
- Pe.createElement(
- 'li',
- { key: `#${o}`, className: 'json-schema-2020-12-property' },
- Pe.createElement($, { name: `#${o} ${i.getTitle(s)}`, schema: s })
- )
- )
- )
- )
- )
- )
- : null;
- },
- keywords_Not = ({ schema: s }) => {
- const o = useFn(),
- i = useComponent('JSONSchema');
- if (!o.hasKeyword(s, 'not')) return null;
- const u = Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Not'
- );
- return Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--not' },
- Pe.createElement(i, { name: u, schema: s.not })
- );
- },
- keywords_If = ({ schema: s }) => {
- const o = useFn(),
- i = useComponent('JSONSchema');
- if (!o.hasKeyword(s, 'if')) return null;
- const u = Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'If'
- );
- return Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--if' },
- Pe.createElement(i, { name: u, schema: s.if })
- );
- },
- keywords_Then = ({ schema: s }) => {
- const o = useFn(),
- i = useComponent('JSONSchema');
- if (!o.hasKeyword(s, 'then')) return null;
- const u = Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Then'
- );
- return Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--then' },
- Pe.createElement(i, { name: u, schema: s.then })
- );
- },
- keywords_Else = ({ schema: s }) => {
- const o = useFn(),
- i = useComponent('JSONSchema');
- if (!o.hasKeyword(s, 'else')) return null;
- const u = Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Else'
- );
- return Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--if' },
- Pe.createElement(i, { name: u, schema: s.else })
- );
- },
- keywords_DependentSchemas = ({ schema: s }) => {
- const o = s?.dependentSchemas || [],
- i = useIsExpanded(),
- u = useIsExpandedDeeply(),
- [_, w] = (0, Pe.useState)(i || u),
- [x, C] = (0, Pe.useState)(!1),
- j = useComponent('Accordion'),
- L = useComponent('ExpandDeepButton'),
- B = useComponent('JSONSchema'),
- $ = (0, Pe.useCallback)(() => {
- w((s) => !s);
- }, []),
- V = (0, Pe.useCallback)((s, o) => {
- w(o), C(o);
- }, []);
- return 'object' != typeof o || 0 === Object.keys(o).length
- ? null
- : Pe.createElement(
- nI.Provider,
- { value: x },
- Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword--dependentSchemas'
- },
- Pe.createElement(
- j,
- { expanded: _, onChange: $ },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Dependent schemas'
- )
- ),
- Pe.createElement(L, { expanded: _, onClick: V }),
- Pe.createElement(
- 'strong',
- {
- className:
- 'json-schema-2020-12__attribute json-schema-2020-12__attribute--primary'
- },
- 'object'
- ),
- Pe.createElement(
- 'ul',
- {
- className: Hn()('json-schema-2020-12-keyword__children', {
- 'json-schema-2020-12-keyword__children--collapsed': !_
- })
- },
- _ &&
- Pe.createElement(
- Pe.Fragment,
- null,
- Object.entries(o).map(([s, o]) =>
- Pe.createElement(
- 'li',
- { key: s, className: 'json-schema-2020-12-property' },
- Pe.createElement(B, { name: s, schema: o })
- )
- )
- )
- )
- )
- );
- },
- keywords_PrefixItems = ({ schema: s }) => {
- const o = s?.prefixItems || [],
- i = useFn(),
- u = useIsExpanded(),
- _ = useIsExpandedDeeply(),
- [w, x] = (0, Pe.useState)(u || _),
- [C, j] = (0, Pe.useState)(!1),
- L = useComponent('Accordion'),
- B = useComponent('ExpandDeepButton'),
- $ = useComponent('JSONSchema'),
- V = useComponent('KeywordType'),
- U = (0, Pe.useCallback)(() => {
- x((s) => !s);
- }, []),
- z = (0, Pe.useCallback)((s, o) => {
- x(o), j(o);
- }, []);
- return Array.isArray(o) && 0 !== o.length
- ? Pe.createElement(
- nI.Provider,
- { value: C },
- Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword--prefixItems'
- },
- Pe.createElement(
- L,
- { expanded: w, onChange: U },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Prefix items'
- )
- ),
- Pe.createElement(B, { expanded: w, onClick: z }),
- Pe.createElement(V, { schema: { prefixItems: o } }),
- Pe.createElement(
- 'ul',
- {
- className: Hn()('json-schema-2020-12-keyword__children', {
- 'json-schema-2020-12-keyword__children--collapsed': !w
- })
- },
- w &&
- Pe.createElement(
- Pe.Fragment,
- null,
- o.map((s, o) =>
- Pe.createElement(
- 'li',
- { key: `#${o}`, className: 'json-schema-2020-12-property' },
- Pe.createElement($, { name: `#${o} ${i.getTitle(s)}`, schema: s })
- )
- )
- )
- )
- )
- )
- : null;
- },
- keywords_Items = ({ schema: s }) => {
- const o = useFn(),
- i = useComponent('JSONSchema');
- if (!o.hasKeyword(s, 'items')) return null;
- const u = Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Items'
- );
- return Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--items' },
- Pe.createElement(i, { name: u, schema: s.items })
- );
- },
- keywords_Contains = ({ schema: s }) => {
- const o = useFn(),
- i = useComponent('JSONSchema');
- if (!o.hasKeyword(s, 'contains')) return null;
- const u = Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Contains'
- );
- return Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--contains' },
- Pe.createElement(i, { name: u, schema: s.contains })
- );
- },
- keywords_Properties_Properties = ({ schema: s }) => {
- const o = useFn(),
- i = s?.properties || {},
- u = Array.isArray(s?.required) ? s.required : [],
- _ = useComponent('JSONSchema');
- return 0 === Object.keys(i).length
- ? null
- : Pe.createElement(
- 'div',
- {
- className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--properties'
- },
- Pe.createElement(
- 'ul',
- null,
- Object.entries(i).map(([i, w]) => {
- const x = u.includes(i),
- C = o.getDependentRequired(i, s);
- return Pe.createElement(
- 'li',
- {
- key: i,
- className: Hn()('json-schema-2020-12-property', {
- 'json-schema-2020-12-property--required': x
- })
- },
- Pe.createElement(_, { name: i, schema: w, dependentRequired: C })
- );
- })
- )
- );
- },
- PatternProperties_PatternProperties = ({ schema: s }) => {
- const o = s?.patternProperties || {},
- i = useComponent('JSONSchema');
- return 0 === Object.keys(o).length
- ? null
- : Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword--patternProperties'
- },
- Pe.createElement(
- 'ul',
- null,
- Object.entries(o).map(([s, o]) =>
- Pe.createElement(
- 'li',
- { key: s, className: 'json-schema-2020-12-property' },
- Pe.createElement(i, { name: s, schema: o })
- )
- )
- )
- );
- },
- keywords_AdditionalProperties = ({ schema: s }) => {
- const o = useFn(),
- { additionalProperties: i } = s,
- u = useComponent('JSONSchema');
- if (!o.hasKeyword(s, 'additionalProperties')) return null;
- const _ = Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Additional properties'
- );
- return Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword--additionalProperties'
- },
- !0 === i
- ? Pe.createElement(
- Pe.Fragment,
- null,
- _,
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12__attribute json-schema-2020-12__attribute--primary'
- },
- 'allowed'
- )
- )
- : !1 === i
- ? Pe.createElement(
- Pe.Fragment,
- null,
- _,
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12__attribute json-schema-2020-12__attribute--primary'
- },
- 'forbidden'
- )
- )
- : Pe.createElement(u, { name: _, schema: i })
- );
- },
- keywords_PropertyNames = ({ schema: s }) => {
- const o = useFn(),
- { propertyNames: i } = s,
- u = useComponent('JSONSchema'),
- _ = Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Property names'
- );
- return o.hasKeyword(s, 'propertyNames')
- ? Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword--propertyNames'
- },
- Pe.createElement(u, { name: _, schema: i })
- )
- : null;
- },
- keywords_UnevaluatedItems = ({ schema: s }) => {
- const o = useFn(),
- { unevaluatedItems: i } = s,
- u = useComponent('JSONSchema');
- if (!o.hasKeyword(s, 'unevaluatedItems')) return null;
- const _ = Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Unevaluated items'
- );
- return Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword--unevaluatedItems'
- },
- Pe.createElement(u, { name: _, schema: i })
- );
- },
- keywords_UnevaluatedProperties = ({ schema: s }) => {
- const o = useFn(),
- { unevaluatedProperties: i } = s,
- u = useComponent('JSONSchema');
- if (!o.hasKeyword(s, 'unevaluatedProperties')) return null;
- const _ = Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Unevaluated properties'
- );
- return Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword--unevaluatedProperties'
- },
- Pe.createElement(u, { name: _, schema: i })
- );
- },
- keywords_Type = ({ schema: s, isCircular: o = !1 }) => {
- const i = useFn().getType(s),
- u = o ? ' [circular]' : '';
- return Pe.createElement(
- 'strong',
- {
- className: 'json-schema-2020-12__attribute json-schema-2020-12__attribute--primary'
- },
- `${i}${u}`
- );
- },
- Enum_Enum = ({ schema: s }) => {
- const o = useFn();
- return Array.isArray(s?.enum)
- ? Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--enum' },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Allowed values'
- ),
- Pe.createElement(
- 'ul',
- null,
- s.enum.map((s) => {
- const i = o.stringify(s);
- return Pe.createElement(
- 'li',
- { key: i },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--const'
- },
- i
- )
- );
- })
- )
- )
- : null;
- },
- keywords_Const = ({ schema: s }) => {
- const o = useFn();
- return o.hasKeyword(s, 'const')
- ? Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--const' },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Const'
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--const'
- },
- o.stringify(s.const)
- )
- )
- : null;
- },
- Constraint = ({ constraint: s }) =>
- Pe.createElement(
- 'span',
- {
- className: `json-schema-2020-12__constraint json-schema-2020-12__constraint--${s.scope}`
- },
- s.value
- ),
- aI = Pe.memo(Constraint),
- DependentRequired_DependentRequired = ({ dependentRequired: s }) =>
- 0 === s.length
- ? null
- : Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword--dependentRequired'
- },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Required when defined'
- ),
- Pe.createElement(
- 'ul',
- null,
- s.map((s) =>
- Pe.createElement(
- 'li',
- { key: s },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--warning'
- },
- s
- )
- )
- )
- )
- ),
- keywords_ContentSchema = ({ schema: s }) => {
- const o = useFn(),
- i = useComponent('JSONSchema');
- if (!o.hasKeyword(s, 'contentSchema')) return null;
- const u = Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Content schema'
- );
- return Pe.createElement(
- 'div',
- {
- className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--contentSchema'
- },
- Pe.createElement(i, { name: u, schema: s.contentSchema })
- );
- },
- Title_Title = ({ title: s = '', schema: o }) => {
- const i = useFn(),
- u = s || i.getTitle(o);
- return u
- ? Pe.createElement('div', { className: 'json-schema-2020-12__title' }, u)
- : null;
- },
- keywords_Description_Description = ({ schema: s }) =>
- s?.description
- ? Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-keyword json-schema-2020-12-keyword--description'
- },
- Pe.createElement(
- 'div',
- {
- className:
- 'json-schema-2020-12-core-keyword__value json-schema-2020-12-core-keyword__value--secondary'
- },
- s.description
- )
- )
- : null,
- keywords_Default = ({ schema: s }) => {
- const o = useFn();
- return o.hasKeyword(s, 'default')
- ? Pe.createElement(
- 'div',
- { className: 'json-schema-2020-12-keyword json-schema-2020-12-keyword--default' },
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__name json-schema-2020-12-keyword__name--primary'
- },
- 'Default'
- ),
- Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12-keyword__value json-schema-2020-12-keyword__value--const'
- },
- o.stringify(s.default)
- )
- )
- : null;
- },
- keywords_Deprecated = ({ schema: s }) =>
- !0 !== s?.deprecated
- ? null
- : Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12__attribute json-schema-2020-12__attribute--warning'
- },
- 'deprecated'
- ),
- keywords_ReadOnly = ({ schema: s }) =>
- !0 !== s?.readOnly
- ? null
- : Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12__attribute json-schema-2020-12__attribute--muted'
- },
- 'read-only'
- ),
- keywords_WriteOnly = ({ schema: s }) =>
- !0 !== s?.writeOnly
- ? null
- : Pe.createElement(
- 'span',
- {
- className:
- 'json-schema-2020-12__attribute json-schema-2020-12__attribute--muted'
- },
- 'write-only'
- ),
- Accordion_Accordion = ({ expanded: s = !1, children: o, onChange: i }) => {
- const u = useComponent('ChevronRightIcon'),
- _ = (0, Pe.useCallback)(
- (o) => {
- i(o, !s);
- },
- [s, i]
- );
- return Pe.createElement(
- 'button',
- { type: 'button', className: 'json-schema-2020-12-accordion', onClick: _ },
- Pe.createElement('div', { className: 'json-schema-2020-12-accordion__children' }, o),
- Pe.createElement(
- 'span',
- {
- className: Hn()('json-schema-2020-12-accordion__icon', {
- 'json-schema-2020-12-accordion__icon--expanded': s,
- 'json-schema-2020-12-accordion__icon--collapsed': !s
- })
- },
- Pe.createElement(u, null)
- )
- );
- },
- ExpandDeepButton_ExpandDeepButton = ({ expanded: s, onClick: o }) => {
- const i = (0, Pe.useCallback)(
- (i) => {
- o(i, !s);
- },
- [s, o]
- );
- return Pe.createElement(
- 'button',
- { type: 'button', className: 'json-schema-2020-12-expand-deep-button', onClick: i },
- s ? 'Collapse all' : 'Expand all'
- );
- },
- icons_ChevronRight = () =>
- Pe.createElement(
- 'svg',
- {
- xmlns: 'http://www.w3.org/2000/svg',
- width: '24',
- height: '24',
- viewBox: '0 0 24 24'
- },
- Pe.createElement('path', { d: 'M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z' })
- ),
- fn_upperFirst = (s) =>
- 'string' == typeof s ? `${s.charAt(0).toUpperCase()}${s.slice(1)}` : s,
- getTitle = (s, { lookup: o = 'extended' } = {}) => {
- const i = useFn();
- if (null != s?.title) return i.upperFirst(String(s.title));
- if ('extended' === o) {
- if (null != s?.$anchor) return i.upperFirst(String(s.$anchor));
- if (null != s?.$id) return String(s.$id);
- }
- return '';
- },
- getType = (s, o = new WeakSet()) => {
- const i = useFn();
- if (null == s) return 'any';
- if (i.isBooleanJSONSchema(s)) return s ? 'any' : 'never';
- if ('object' != typeof s) return 'any';
- if (o.has(s)) return 'any';
- o.add(s);
- const { type: u, prefixItems: _, items: w } = s,
- getArrayType = () => {
- if (Array.isArray(_)) {
- const s = _.map((s) => getType(s, o)),
- i = w ? getType(w, o) : 'any';
- return `array<[${s.join(', ')}], ${i}>`;
- }
- if (w) {
- return `array<${getType(w, o)}>`;
- }
- return 'array<any>';
- };
- if (s.not && 'any' === getType(s.not)) return 'never';
- const handleCombiningKeywords = (i, u) => {
- if (Array.isArray(s[i])) {
- return `(${s[i].map((s) => getType(s, o)).join(u)})`;
- }
- return null;
- },
- x = [
- Array.isArray(u)
- ? u.map((s) => ('array' === s ? getArrayType() : s)).join(' | ')
- : 'array' === u
- ? getArrayType()
- : [
- 'null',
- 'boolean',
- 'object',
- 'array',
- 'number',
- 'integer',
- 'string'
- ].includes(u)
- ? u
- : (() => {
- if (
- Object.hasOwn(s, 'prefixItems') ||
- Object.hasOwn(s, 'items') ||
- Object.hasOwn(s, 'contains')
- )
- return getArrayType();
- if (
- Object.hasOwn(s, 'properties') ||
- Object.hasOwn(s, 'additionalProperties') ||
- Object.hasOwn(s, 'patternProperties')
- )
- return 'object';
- if (['int32', 'int64'].includes(s.format)) return 'integer';
- if (['float', 'double'].includes(s.format)) return 'number';
- if (
- Object.hasOwn(s, 'minimum') ||
- Object.hasOwn(s, 'maximum') ||
- Object.hasOwn(s, 'exclusiveMinimum') ||
- Object.hasOwn(s, 'exclusiveMaximum') ||
- Object.hasOwn(s, 'multipleOf')
- )
- return 'number | integer';
- if (
- Object.hasOwn(s, 'pattern') ||
- Object.hasOwn(s, 'format') ||
- Object.hasOwn(s, 'minLength') ||
- Object.hasOwn(s, 'maxLength')
- )
- return 'string';
- if (void 0 !== s.const) {
- if (null === s.const) return 'null';
- if ('boolean' == typeof s.const) return 'boolean';
- if ('number' == typeof s.const)
- return Number.isInteger(s.const) ? 'integer' : 'number';
- if ('string' == typeof s.const) return 'string';
- if (Array.isArray(s.const)) return 'array<any>';
- if ('object' == typeof s.const) return 'object';
- }
- return null;
- })(),
- handleCombiningKeywords('oneOf', ' | '),
- handleCombiningKeywords('anyOf', ' | '),
- handleCombiningKeywords('allOf', ' & ')
- ]
- .filter(Boolean)
- .join(' | ');
- return o.delete(s), x || 'any';
- },
- isBooleanJSONSchema = (s) => 'boolean' == typeof s,
- hasKeyword = (s, o) => null !== s && 'object' == typeof s && Object.hasOwn(s, o),
- isExpandable = (s) => {
- const o = useFn();
- return (
- s?.$schema ||
- s?.$vocabulary ||
- s?.$id ||
- s?.$anchor ||
- s?.$dynamicAnchor ||
- s?.$ref ||
- s?.$dynamicRef ||
- s?.$defs ||
- s?.$comment ||
- s?.allOf ||
- s?.anyOf ||
- s?.oneOf ||
- o.hasKeyword(s, 'not') ||
- o.hasKeyword(s, 'if') ||
- o.hasKeyword(s, 'then') ||
- o.hasKeyword(s, 'else') ||
- s?.dependentSchemas ||
- s?.prefixItems ||
- o.hasKeyword(s, 'items') ||
- o.hasKeyword(s, 'contains') ||
- s?.properties ||
- s?.patternProperties ||
- o.hasKeyword(s, 'additionalProperties') ||
- o.hasKeyword(s, 'propertyNames') ||
- o.hasKeyword(s, 'unevaluatedItems') ||
- o.hasKeyword(s, 'unevaluatedProperties') ||
- s?.description ||
- s?.enum ||
- o.hasKeyword(s, 'const') ||
- o.hasKeyword(s, 'contentSchema') ||
- o.hasKeyword(s, 'default')
- );
- },
- fn_stringify = (s) =>
- null === s || ['number', 'bigint', 'boolean'].includes(typeof s)
- ? String(s)
- : Array.isArray(s)
- ? `[${s.map(fn_stringify).join(', ')}]`
- : JSON.stringify(s),
- stringifyConstraintRange = (s, o, i) => {
- const u = 'number' == typeof o,
- _ = 'number' == typeof i;
- return u && _
- ? o === i
- ? `${o} ${s}`
- : `[${o}, ${i}] ${s}`
- : u
- ? `>= ${o} ${s}`
- : _
- ? `<= ${i} ${s}`
- : null;
- },
- stringifyConstraints = (s) => {
- const o = [],
- i = ((s) => {
- if ('number' != typeof s?.multipleOf) return null;
- if (s.multipleOf <= 0) return null;
- if (1 === s.multipleOf) return null;
- const { multipleOf: o } = s;
- if (Number.isInteger(o)) return `multiple of ${o}`;
- const i = 10 ** o.toString().split('.')[1].length;
- return `multiple of ${o * i}/${i}`;
- })(s);
- null !== i && o.push({ scope: 'number', value: i });
- const u = ((s) => {
- const o = s?.minimum,
- i = s?.maximum,
- u = s?.exclusiveMinimum,
- _ = s?.exclusiveMaximum,
- w = 'number' == typeof o,
- x = 'number' == typeof i,
- C = 'number' == typeof u,
- j = 'number' == typeof _,
- L = C && (!w || o < u),
- B = j && (!x || i > _);
- if ((w || C) && (x || j))
- return `${L ? '(' : '['}${L ? u : o}, ${B ? _ : i}${B ? ')' : ']'}`;
- if (w || C) return `${L ? '>' : '≥'} ${L ? u : o}`;
- if (x || j) return `${B ? '<' : '≤'} ${B ? _ : i}`;
- return null;
- })(s);
- null !== u && o.push({ scope: 'number', value: u }),
- s?.format && o.push({ scope: 'string', value: s.format });
- const _ = stringifyConstraintRange('characters', s?.minLength, s?.maxLength);
- null !== _ && o.push({ scope: 'string', value: _ }),
- s?.pattern && o.push({ scope: 'string', value: `matches ${s?.pattern}` }),
- s?.contentMediaType &&
- o.push({ scope: 'string', value: `media type: ${s.contentMediaType}` }),
- s?.contentEncoding &&
- o.push({ scope: 'string', value: `encoding: ${s.contentEncoding}` });
- const w = stringifyConstraintRange(
- s?.hasUniqueItems ? 'unique items' : 'items',
- s?.minItems,
- s?.maxItems
- );
- null !== w && o.push({ scope: 'array', value: w });
- const x = stringifyConstraintRange('contained items', s?.minContains, s?.maxContains);
- null !== x && o.push({ scope: 'array', value: x });
- const C = stringifyConstraintRange('properties', s?.minProperties, s?.maxProperties);
- return null !== C && o.push({ scope: 'object', value: C }), o;
- },
- getDependentRequired = (s, o) =>
- o?.dependentRequired
- ? Array.from(
- Object.entries(o.dependentRequired).reduce(
- (o, [i, u]) => (Array.isArray(u) && u.includes(s) ? (o.add(i), o) : o),
- new Set()
- )
- )
- : [],
- withJSONSchemaContext = (s, o = {}) => {
- const i = {
- components: {
- JSONSchema: iI,
- Keyword$schema: keywords_$schema,
- Keyword$vocabulary: $vocabulary_$vocabulary,
- Keyword$id: keywords_$id,
- Keyword$anchor: keywords_$anchor,
- Keyword$dynamicAnchor: keywords_$dynamicAnchor,
- Keyword$ref: keywords_$ref,
- Keyword$dynamicRef: keywords_$dynamicRef,
- Keyword$defs: keywords_$defs,
- Keyword$comment: keywords_$comment,
- KeywordAllOf: keywords_AllOf,
- KeywordAnyOf: keywords_AnyOf,
- KeywordOneOf: keywords_OneOf,
- KeywordNot: keywords_Not,
- KeywordIf: keywords_If,
- KeywordThen: keywords_Then,
- KeywordElse: keywords_Else,
- KeywordDependentSchemas: keywords_DependentSchemas,
- KeywordPrefixItems: keywords_PrefixItems,
- KeywordItems: keywords_Items,
- KeywordContains: keywords_Contains,
- KeywordProperties: keywords_Properties_Properties,
- KeywordPatternProperties: PatternProperties_PatternProperties,
- KeywordAdditionalProperties: keywords_AdditionalProperties,
- KeywordPropertyNames: keywords_PropertyNames,
- KeywordUnevaluatedItems: keywords_UnevaluatedItems,
- KeywordUnevaluatedProperties: keywords_UnevaluatedProperties,
- KeywordType: keywords_Type,
- KeywordEnum: Enum_Enum,
- KeywordConst: keywords_Const,
- KeywordConstraint: aI,
- KeywordDependentRequired: DependentRequired_DependentRequired,
- KeywordContentSchema: keywords_ContentSchema,
- KeywordTitle: Title_Title,
- KeywordDescription: keywords_Description_Description,
- KeywordDefault: keywords_Default,
- KeywordDeprecated: keywords_Deprecated,
- KeywordReadOnly: keywords_ReadOnly,
- KeywordWriteOnly: keywords_WriteOnly,
- Accordion: Accordion_Accordion,
- ExpandDeepButton: ExpandDeepButton_ExpandDeepButton,
- ChevronRightIcon: icons_ChevronRight,
- ...o.components
- },
- config: {
- default$schema: 'https://json-schema.org/draft/2020-12/schema',
- defaultExpandedLevels: 0,
- ...o.config
- },
- fn: {
- upperFirst: fn_upperFirst,
- getTitle,
- getType,
- isBooleanJSONSchema,
- hasKeyword,
- isExpandable,
- stringify: fn_stringify,
- stringifyConstraints,
- getDependentRequired,
- ...o.fn
- }
- },
- HOC = (o) => Pe.createElement(tI.Provider, { value: i }, Pe.createElement(s, o));
- return (
- (HOC.contexts = { JSONSchemaContext: tI }), (HOC.displayName = s.displayName), HOC
- );
- },
- json_schema_2020_12 = () => ({
- components: {
- JSONSchema202012: iI,
- JSONSchema202012Keyword$schema: keywords_$schema,
- JSONSchema202012Keyword$vocabulary: $vocabulary_$vocabulary,
- JSONSchema202012Keyword$id: keywords_$id,
- JSONSchema202012Keyword$anchor: keywords_$anchor,
- JSONSchema202012Keyword$dynamicAnchor: keywords_$dynamicAnchor,
- JSONSchema202012Keyword$ref: keywords_$ref,
- JSONSchema202012Keyword$dynamicRef: keywords_$dynamicRef,
- JSONSchema202012Keyword$defs: keywords_$defs,
- JSONSchema202012Keyword$comment: keywords_$comment,
- JSONSchema202012KeywordAllOf: keywords_AllOf,
- JSONSchema202012KeywordAnyOf: keywords_AnyOf,
- JSONSchema202012KeywordOneOf: keywords_OneOf,
- JSONSchema202012KeywordNot: keywords_Not,
- JSONSchema202012KeywordIf: keywords_If,
- JSONSchema202012KeywordThen: keywords_Then,
- JSONSchema202012KeywordElse: keywords_Else,
- JSONSchema202012KeywordDependentSchemas: keywords_DependentSchemas,
- JSONSchema202012KeywordPrefixItems: keywords_PrefixItems,
- JSONSchema202012KeywordItems: keywords_Items,
- JSONSchema202012KeywordContains: keywords_Contains,
- JSONSchema202012KeywordProperties: keywords_Properties_Properties,
- JSONSchema202012KeywordPatternProperties: PatternProperties_PatternProperties,
- JSONSchema202012KeywordAdditionalProperties: keywords_AdditionalProperties,
- JSONSchema202012KeywordPropertyNames: keywords_PropertyNames,
- JSONSchema202012KeywordUnevaluatedItems: keywords_UnevaluatedItems,
- JSONSchema202012KeywordUnevaluatedProperties: keywords_UnevaluatedProperties,
- JSONSchema202012KeywordType: keywords_Type,
- JSONSchema202012KeywordEnum: Enum_Enum,
- JSONSchema202012KeywordConst: keywords_Const,
- JSONSchema202012KeywordConstraint: aI,
- JSONSchema202012KeywordDependentRequired: DependentRequired_DependentRequired,
- JSONSchema202012KeywordContentSchema: keywords_ContentSchema,
- JSONSchema202012KeywordTitle: Title_Title,
- JSONSchema202012KeywordDescription: keywords_Description_Description,
- JSONSchema202012KeywordDefault: keywords_Default,
- JSONSchema202012KeywordDeprecated: keywords_Deprecated,
- JSONSchema202012KeywordReadOnly: keywords_ReadOnly,
- JSONSchema202012KeywordWriteOnly: keywords_WriteOnly,
- JSONSchema202012Accordion: Accordion_Accordion,
- JSONSchema202012ExpandDeepButton: ExpandDeepButton_ExpandDeepButton,
- JSONSchema202012ChevronRightIcon: icons_ChevronRight,
- withJSONSchema202012Context: withJSONSchemaContext,
- JSONSchema202012DeepExpansionContext: () => nI
- },
- fn: {
- upperFirst: fn_upperFirst,
- jsonSchema202012: {
- isExpandable,
- hasKeyword,
- useFn,
- useConfig,
- useComponent,
- useIsExpandedDeeply
- }
- }
- });
- var lI = __webpack_require__(11331),
- cI = __webpack_require__.n(lI);
- const array = (s, { sample: o }) =>
- ((s, o = {}) => {
- const { minItems: i, maxItems: u, uniqueItems: _ } = o,
- { contains: w, minContains: x, maxContains: C } = o;
- let j = [...s];
- if (null != w && 'object' == typeof w) {
- if (Number.isInteger(x) && x > 1) {
- const s = j.at(0);
- for (let o = 1; o < x; o += 1) j.unshift(s);
- }
- Number.isInteger(C);
- }
- if (
- (Number.isInteger(u) && u > 0 && (j = s.slice(0, u)), Number.isInteger(i) && i > 0)
- )
- for (let s = 0; j.length < i; s += 1) j.push(j[s % j.length]);
- return !0 === _ && (j = Array.from(new Set(j))), j;
- })(o, s),
- object = () => {
- throw new Error('Not implemented');
- },
- bytes = (s) => St()(s),
- random_pick = (s) => s.at(0),
- predicates_isBooleanJSONSchema = (s) => 'boolean' == typeof s,
- isJSONSchemaObject = (s) => cI()(s),
- isJSONSchema = (s) => predicates_isBooleanJSONSchema(s) || isJSONSchemaObject(s);
- const uI = class Registry {
- data = {};
- register(s, o) {
- this.data[s] = o;
- }
- unregister(s) {
- void 0 === s ? (this.data = {}) : delete this.data[s];
- }
- get(s) {
- return this.data[s];
- }
- },
- int32 = () => (2 ** 30) >>> 0,
- int64 = () => 2 ** 53 - 1,
- generators_float = () => 0.1,
- generators_double = () => 0.1,
- email = () => 'user@example.com',
- idn_email = () => '실례@example.com',
- hostname = () => 'example.com',
- idn_hostname = () => '실례.com',
- ipv4 = () => '198.51.100.42',
- ipv6 = () => '2001:0db8:5b96:0000:0000:426f:8e17:642a',
- uri = () => 'https://example.com/',
- uri_reference = () => 'path/index.html',
- iri = () => 'https://실례.com/',
- iri_reference = () => 'path/실례.html',
- uuid = () => '3fa85f64-5717-4562-b3fc-2c963f66afa6',
- uri_template = () => 'https://example.com/dictionary/{term:1}/{term}',
- json_pointer = () => '/a/b/c',
- relative_json_pointer = () => '1/0',
- date_time = () => new Date().toISOString(),
- date = () => new Date().toISOString().substring(0, 10),
- time = () => new Date().toISOString().substring(11),
- duration = () => 'P3D',
- generators_password = () => '********',
- regex = () => '^[a-z]+$';
- const pI = new (class FormatRegistry extends uI {
- #t = {
- int32,
- int64,
- float: generators_float,
- double: generators_double,
- email,
- 'idn-email': idn_email,
- hostname,
- 'idn-hostname': idn_hostname,
- ipv4,
- ipv6,
- uri,
- 'uri-reference': uri_reference,
- iri,
- 'iri-reference': iri_reference,
- uuid,
- 'uri-template': uri_template,
- 'json-pointer': json_pointer,
- 'relative-json-pointer': relative_json_pointer,
- 'date-time': date_time,
- date,
- time,
- duration,
- password: generators_password,
- regex
- };
- data = { ...this.#t };
- get defaults() {
- return { ...this.#t };
- }
- })(),
- formatAPI = (s, o) =>
- 'function' == typeof o ? pI.register(s, o) : null === o ? pI.unregister(s) : pI.get(s);
- formatAPI.getDefaults = () => pI.defaults;
- const hI = formatAPI;
- var dI = __webpack_require__(48287).Buffer;
- const _7bit = (s) => dI.from(s).toString('ascii');
- var fI = __webpack_require__(48287).Buffer;
- const _8bit = (s) => fI.from(s).toString('utf8');
- var mI = __webpack_require__(48287).Buffer;
- const encoders_binary = (s) => mI.from(s).toString('binary'),
- quoted_printable = (s) => {
- let o = '';
- for (let i = 0; i < s.length; i++) {
- const u = s.charCodeAt(i);
- if (61 === u) o += '=3D';
- else if ((u >= 33 && u <= 60) || (u >= 62 && u <= 126) || 9 === u || 32 === u)
- o += s.charAt(i);
- else if (13 === u || 10 === u) o += '\r\n';
- else if (u > 126) {
- const u = unescape(encodeURIComponent(s.charAt(i)));
- for (let s = 0; s < u.length; s++)
- o += '=' + ('0' + u.charCodeAt(s).toString(16)).slice(-2).toUpperCase();
- } else o += '=' + ('0' + u.toString(16)).slice(-2).toUpperCase();
- }
- return o;
- };
- var gI = __webpack_require__(48287).Buffer;
- const base16 = (s) => gI.from(s).toString('hex');
- var yI = __webpack_require__(48287).Buffer;
- const base32 = (s) => {
- const o = yI.from(s).toString('utf8'),
- i = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ234567';
- let u = 0,
- _ = '',
- w = 0,
- x = 0;
- for (let s = 0; s < o.length; s++)
- for (w = (w << 8) | o.charCodeAt(s), x += 8; x >= 5; )
- (_ += i.charAt((w >>> (x - 5)) & 31)), (x -= 5);
- x > 0 && ((_ += i.charAt((w << (5 - x)) & 31)), (u = (8 - ((8 * o.length) % 5)) % 5));
- for (let s = 0; s < u; s++) _ += '=';
- return _;
- };
- var vI = __webpack_require__(48287).Buffer;
- const base64 = (s) => vI.from(s).toString('base64');
- var bI = __webpack_require__(48287).Buffer;
- const base64url = (s) => bI.from(s).toString('base64url');
- const _I = new (class EncoderRegistry extends uI {
- #t = {
- '7bit': _7bit,
- '8bit': _8bit,
- binary: encoders_binary,
- 'quoted-printable': quoted_printable,
- base16,
- base32,
- base64,
- base64url
- };
- data = { ...this.#t };
- get defaults() {
- return { ...this.#t };
- }
- })(),
- encoderAPI = (s, o) =>
- 'function' == typeof o ? _I.register(s, o) : null === o ? _I.unregister(s) : _I.get(s);
- encoderAPI.getDefaults = () => _I.defaults;
- const EI = encoderAPI,
- wI = {
- 'text/plain': () => 'string',
- 'text/css': () => '.selector { border: 1px solid red }',
- 'text/csv': () => 'value1,value2,value3',
- 'text/html': () => '<p>content</p>',
- 'text/calendar': () => 'BEGIN:VCALENDAR',
- 'text/javascript': () => "console.dir('Hello world!');",
- 'text/xml': () => '<person age="30">John Doe</person>',
- 'text/*': () => 'string'
- },
- SI = { 'image/*': () => bytes(25).toString('binary') },
- xI = { 'audio/*': () => bytes(25).toString('binary') },
- kI = { 'video/*': () => bytes(25).toString('binary') },
- CI = {
- 'application/json': () => '{"key":"value"}',
- 'application/ld+json': () => '{"name": "John Doe"}',
- 'application/x-httpd-php': () => "<?php echo '<p>Hello World!</p>'; ?>",
- 'application/rtf': () => String.raw`{\rtf1\adeflang1025\ansi\ansicpg1252\uc1`,
- 'application/x-sh': () => 'echo "Hello World!"',
- 'application/xhtml+xml': () => '<p>content</p>',
- 'application/*': () => bytes(25).toString('binary')
- };
- const OI = new (class MediaTypeRegistry extends uI {
- #t = { ...wI, ...SI, ...xI, ...kI, ...CI };
- data = { ...this.#t };
- get defaults() {
- return { ...this.#t };
- }
- })(),
- mediaTypeAPI = (s, o) => {
- if ('function' == typeof o) return OI.register(s, o);
- if (null === o) return OI.unregister(s);
- const i = s.split(';').at(0),
- u = `${i.split('/').at(0)}/*`;
- return OI.get(s) || OI.get(i) || OI.get(u);
- };
- mediaTypeAPI.getDefaults = () => OI.defaults;
- const AI = mediaTypeAPI,
- applyStringConstraints = (s, o = {}) => {
- const { maxLength: i, minLength: u } = o;
- let _ = s;
- if (
- (Number.isInteger(i) && i > 0 && (_ = _.slice(0, i)), Number.isInteger(u) && u > 0)
- ) {
- let s = 0;
- for (; _.length < u; ) _ += _[s++ % _.length];
- }
- return _;
- },
- types_string = (s, { sample: o } = {}) => {
- const { contentEncoding: i, contentMediaType: u, contentSchema: _ } = s,
- { pattern: w, format: x } = s,
- C = EI(i) || Mx();
- let j;
- return (
- (j =
- 'string' == typeof w
- ? applyStringConstraints(
- ((s) => {
- try {
- return new (us())(s).gen();
- } catch {
- return 'string';
- }
- })(w),
- s
- )
- : 'string' == typeof x
- ? ((s) => {
- const { format: o } = s,
- i = hI(o);
- return 'function' == typeof i ? i(s) : 'string';
- })(s)
- : isJSONSchema(_) && 'string' == typeof u && void 0 !== o
- ? Array.isArray(o) || 'object' == typeof o
- ? JSON.stringify(o)
- : applyStringConstraints(String(o), s)
- : 'string' == typeof u
- ? ((s) => {
- const { contentMediaType: o } = s,
- i = AI(o);
- return 'function' == typeof i ? i(s) : 'string';
- })(s)
- : applyStringConstraints('string', s)),
- C(j)
- );
- },
- applyNumberConstraints = (s, o = {}) => {
- const { minimum: i, maximum: u, exclusiveMinimum: _, exclusiveMaximum: w } = o,
- { multipleOf: x } = o,
- C = Number.isInteger(s) ? 1 : Number.EPSILON;
- let j = 'number' == typeof i ? i : null,
- L = 'number' == typeof u ? u : null,
- B = s;
- if (
- ('number' == typeof _ && (j = null !== j ? Math.max(j, _ + C) : _ + C),
- 'number' == typeof w && (L = null !== L ? Math.min(L, w - C) : w - C),
- (B = (j > L && s) || j || L || B),
- 'number' == typeof x && x > 0)
- ) {
- const s = B % x;
- B = 0 === s ? B : B + x - s;
- }
- return B;
- },
- types_number = (s) => {
- const { format: o } = s;
- let i;
- return (
- (i =
- 'string' == typeof o
- ? ((s) => {
- const { format: o } = s,
- i = hI(o);
- return 'function' == typeof i ? i(s) : 0;
- })(s)
- : 0),
- applyNumberConstraints(i, s)
- );
- },
- types_integer = (s) => {
- const { format: o } = s;
- let i;
- return (
- (i =
- 'string' == typeof o
- ? ((s) => {
- const { format: o } = s,
- i = hI(o);
- if ('function' == typeof i) return i(s);
- switch (o) {
- case 'int32':
- return int32();
- case 'int64':
- return int64();
- }
- return 0;
- })(s)
- : 0),
- applyNumberConstraints(i, s)
- );
- },
- types_boolean = (s) => 'boolean' != typeof s.default || s.default,
- jI = new Proxy(
- {
- array,
- object,
- string: types_string,
- number: types_number,
- integer: types_integer,
- boolean: types_boolean,
- null: () => null
- },
- {
- get: (s, o) =>
- 'string' == typeof o && Object.hasOwn(s, o) ? s[o] : () => `Unknown Type: ${o}`
- }
- ),
- II = ['array', 'object', 'number', 'integer', 'string', 'boolean', 'null'],
- hasExample = (s) => {
- if (!isJSONSchemaObject(s)) return !1;
- const { examples: o, example: i, default: u } = s;
- return !!(Array.isArray(o) && o.length >= 1) || void 0 !== u || void 0 !== i;
- },
- extractExample = (s) => {
- if (!isJSONSchemaObject(s)) return null;
- const { examples: o, example: i, default: u } = s;
- return Array.isArray(o) && o.length >= 1
- ? o.at(0)
- : void 0 !== u
- ? u
- : void 0 !== i
- ? i
- : void 0;
- },
- PI = {
- array: [
- 'items',
- 'prefixItems',
- 'contains',
- 'maxContains',
- 'minContains',
- 'maxItems',
- 'minItems',
- 'uniqueItems',
- 'unevaluatedItems'
- ],
- object: [
- 'properties',
- 'additionalProperties',
- 'patternProperties',
- 'propertyNames',
- 'minProperties',
- 'maxProperties',
- 'required',
- 'dependentSchemas',
- 'dependentRequired',
- 'unevaluatedProperties'
- ],
- string: [
- 'pattern',
- 'format',
- 'minLength',
- 'maxLength',
- 'contentEncoding',
- 'contentMediaType',
- 'contentSchema'
- ],
- integer: ['minimum', 'maximum', 'exclusiveMinimum', 'exclusiveMaximum', 'multipleOf']
- };
- PI.number = PI.integer;
- const MI = 'string',
- inferTypeFromValue = (s) =>
- void 0 === s
- ? null
- : null === s
- ? 'null'
- : Array.isArray(s)
- ? 'array'
- : Number.isInteger(s)
- ? 'integer'
- : typeof s,
- foldType = (s) => {
- if (Array.isArray(s) && s.length >= 1) {
- if (s.includes('array')) return 'array';
- if (s.includes('object')) return 'object';
- {
- const o = random_pick(s);
- if (II.includes(o)) return o;
- }
- }
- return II.includes(s) ? s : null;
- },
- inferType = (s, o = new WeakSet()) => {
- if (!isJSONSchemaObject(s)) return MI;
- if (o.has(s)) return MI;
- o.add(s);
- let { type: i, const: u } = s;
- if (((i = foldType(i)), 'string' != typeof i)) {
- const o = Object.keys(PI);
- e: for (let u = 0; u < o.length; u += 1) {
- const _ = o[u],
- w = PI[_];
- for (let o = 0; o < w.length; o += 1) {
- const u = w[o];
- if (Object.hasOwn(s, u)) {
- i = _;
- break e;
- }
- }
- }
- }
- if ('string' != typeof i && void 0 !== u) {
- const s = inferTypeFromValue(u);
- i = 'string' == typeof s ? s : i;
- }
- if ('string' != typeof i) {
- const combineTypes = (i) => {
- if (Array.isArray(s[i])) {
- const u = s[i].map((s) => inferType(s, o));
- return foldType(u);
- }
- return null;
- },
- u = combineTypes('allOf'),
- _ = combineTypes('anyOf'),
- w = combineTypes('oneOf'),
- x = s.not ? inferType(s.not, o) : null;
- (u || _ || w || x) && (i = foldType([u, _, w, x].filter(Boolean)));
- }
- if ('string' != typeof i && hasExample(s)) {
- const o = extractExample(s),
- u = inferTypeFromValue(o);
- i = 'string' == typeof u ? u : i;
- }
- return o.delete(s), i || MI;
- },
- type_getType = (s) => inferType(s),
- typeCast = (s) =>
- predicates_isBooleanJSONSchema(s)
- ? ((s) => (!1 === s ? { not: {} } : {}))(s)
- : isJSONSchemaObject(s)
- ? s
- : {},
- merge_merge = (s, o, i = {}) => {
- if (predicates_isBooleanJSONSchema(s) && !0 === s) return !0;
- if (predicates_isBooleanJSONSchema(s) && !1 === s) return !1;
- if (predicates_isBooleanJSONSchema(o) && !0 === o) return !0;
- if (predicates_isBooleanJSONSchema(o) && !1 === o) return !1;
- if (!isJSONSchema(s)) return o;
- if (!isJSONSchema(o)) return s;
- const u = { ...o, ...s };
- if (o.type && s.type && Array.isArray(o.type) && 'string' == typeof o.type) {
- const i = normalizeArray(o.type).concat(s.type);
- u.type = Array.from(new Set(i));
- }
- if (
- (Array.isArray(o.required) &&
- Array.isArray(s.required) &&
- (u.required = [...new Set([...s.required, ...o.required])]),
- o.properties && s.properties)
- ) {
- const _ = new Set([...Object.keys(o.properties), ...Object.keys(s.properties)]);
- u.properties = {};
- for (const w of _) {
- const _ = o.properties[w] || {},
- x = s.properties[w] || {};
- (_.readOnly && !i.includeReadOnly) || (_.writeOnly && !i.includeWriteOnly)
- ? (u.required = (u.required || []).filter((s) => s !== w))
- : (u.properties[w] = merge_merge(x, _, i));
- }
- }
- return (
- isJSONSchema(o.items) &&
- isJSONSchema(s.items) &&
- (u.items = merge_merge(s.items, o.items, i)),
- isJSONSchema(o.contains) &&
- isJSONSchema(s.contains) &&
- (u.contains = merge_merge(s.contains, o.contains, i)),
- isJSONSchema(o.contentSchema) &&
- isJSONSchema(s.contentSchema) &&
- (u.contentSchema = merge_merge(s.contentSchema, o.contentSchema, i)),
- u
- );
- },
- TI = merge_merge,
- main_sampleFromSchemaGeneric = (s, o = {}, i = void 0, u = !1) => {
- if (null == s && void 0 === i) return;
- 'function' == typeof s?.toJS && (s = s.toJS()), (s = typeCast(s));
- let _ = void 0 !== i || hasExample(s);
- const w = !_ && Array.isArray(s.oneOf) && s.oneOf.length > 0,
- x = !_ && Array.isArray(s.anyOf) && s.anyOf.length > 0;
- if (!_ && (w || x)) {
- const i = typeCast(random_pick(w ? s.oneOf : s.anyOf));
- !(s = TI(s, i, o)).xml && i.xml && (s.xml = i.xml),
- hasExample(s) && hasExample(i) && (_ = !0);
- }
- const C = {};
- let { xml: j, properties: L, additionalProperties: B, items: $, contains: V } = s || {},
- U = type_getType(s),
- { includeReadOnly: z, includeWriteOnly: Y } = o;
- j = j || {};
- let Z,
- { name: ee, prefix: ie, namespace: ae } = j,
- le = {};
- if (
- (Object.hasOwn(s, 'type') || (s.type = U),
- u && ((ee = ee || 'notagname'), (Z = (ie ? `${ie}:` : '') + ee), ae))
- ) {
- C[ie ? `xmlns:${ie}` : 'xmlns'] = ae;
- }
- u && (le[Z] = []);
- const ce = objectify(L);
- let pe,
- de = 0;
- const hasExceededMaxProperties = () =>
- Number.isInteger(s.maxProperties) && s.maxProperties > 0 && de >= s.maxProperties,
- canAddProperty = (o) =>
- !(Number.isInteger(s.maxProperties) && s.maxProperties > 0) ||
- (!hasExceededMaxProperties() &&
- (!((o) =>
- !Array.isArray(s.required) ||
- 0 === s.required.length ||
- !s.required.includes(o))(o) ||
- s.maxProperties -
- de -
- (() => {
- if (!Array.isArray(s.required) || 0 === s.required.length) return 0;
- let o = 0;
- return (
- u
- ? s.required.forEach((s) => (o += void 0 === le[s] ? 0 : 1))
- : s.required.forEach((s) => {
- o += void 0 === le[Z]?.find((o) => void 0 !== o[s]) ? 0 : 1;
- }),
- s.required.length - o
- );
- })() >
- 0));
- if (
- ((pe = u
- ? (i, _ = void 0) => {
- if (s && ce[i]) {
- if (((ce[i].xml = ce[i].xml || {}), ce[i].xml.attribute)) {
- const s = Array.isArray(ce[i].enum) ? random_pick(ce[i].enum) : void 0;
- if (hasExample(ce[i])) C[ce[i].xml.name || i] = extractExample(ce[i]);
- else if (void 0 !== s) C[ce[i].xml.name || i] = s;
- else {
- const s = typeCast(ce[i]),
- o = type_getType(s),
- u = ce[i].xml.name || i;
- C[u] = jI[o](s);
- }
- return;
- }
- ce[i].xml.name = ce[i].xml.name || i;
- } else ce[i] || !1 === B || (ce[i] = { xml: { name: i } });
- let w = main_sampleFromSchemaGeneric(ce[i], o, _, u);
- canAddProperty(i) &&
- (de++, Array.isArray(w) ? (le[Z] = le[Z].concat(w)) : le[Z].push(w));
- }
- : (i, _) => {
- if (canAddProperty(i)) {
- if (
- cI()(s.discriminator?.mapping) &&
- s.discriminator.propertyName === i &&
- 'string' == typeof s.$$ref
- ) {
- for (const o in s.discriminator.mapping)
- if (-1 !== s.$$ref.search(s.discriminator.mapping[o])) {
- le[i] = o;
- break;
- }
- } else le[i] = main_sampleFromSchemaGeneric(ce[i], o, _, u);
- de++;
- }
- }),
- _)
- ) {
- let _;
- if (((_ = void 0 !== i ? i : extractExample(s)), !u)) {
- if ('number' == typeof _ && 'string' === U) return `${_}`;
- if ('string' != typeof _ || 'string' === U) return _;
- try {
- return JSON.parse(_);
- } catch {
- return _;
- }
- }
- if ('array' === U) {
- if (!Array.isArray(_)) {
- if ('string' == typeof _) return _;
- _ = [_];
- }
- let i = [];
- return (
- isJSONSchemaObject($) &&
- (($.xml = $.xml || j || {}),
- ($.xml.name = $.xml.name || j.name),
- (i = _.map((s) => main_sampleFromSchemaGeneric($, o, s, u)))),
- isJSONSchemaObject(V) &&
- ((V.xml = V.xml || j || {}),
- (V.xml.name = V.xml.name || j.name),
- (i = [main_sampleFromSchemaGeneric(V, o, void 0, u), ...i])),
- (i = jI.array(s, { sample: i })),
- j.wrapped ? ((le[Z] = i), hs()(C) || le[Z].push({ _attr: C })) : (le = i),
- le
- );
- }
- if ('object' === U) {
- if ('string' == typeof _) return _;
- for (const s in _)
- Object.hasOwn(_, s) &&
- ((ce[s]?.readOnly && !z) ||
- (ce[s]?.writeOnly && !Y) ||
- (ce[s]?.xml?.attribute ? (C[ce[s].xml.name || s] = _[s]) : pe(s, _[s])));
- return hs()(C) || le[Z].push({ _attr: C }), le;
- }
- return (le[Z] = hs()(C) ? _ : [{ _attr: C }, _]), le;
- }
- if ('array' === U) {
- let i = [];
- if (isJSONSchemaObject(V))
- if (
- (u && ((V.xml = V.xml || s.xml || {}), (V.xml.name = V.xml.name || j.name)),
- Array.isArray(V.anyOf))
- ) {
- const { anyOf: s, ..._ } = $;
- i.push(
- ...V.anyOf.map((s) => main_sampleFromSchemaGeneric(TI(s, _, o), o, void 0, u))
- );
- } else if (Array.isArray(V.oneOf)) {
- const { oneOf: s, ..._ } = $;
- i.push(
- ...V.oneOf.map((s) => main_sampleFromSchemaGeneric(TI(s, _, o), o, void 0, u))
- );
- } else {
- if (!(!u || (u && j.wrapped)))
- return main_sampleFromSchemaGeneric(V, o, void 0, u);
- i.push(main_sampleFromSchemaGeneric(V, o, void 0, u));
- }
- if (isJSONSchemaObject($))
- if (
- (u && (($.xml = $.xml || s.xml || {}), ($.xml.name = $.xml.name || j.name)),
- Array.isArray($.anyOf))
- ) {
- const { anyOf: s, ..._ } = $;
- i.push(
- ...$.anyOf.map((s) => main_sampleFromSchemaGeneric(TI(s, _, o), o, void 0, u))
- );
- } else if (Array.isArray($.oneOf)) {
- const { oneOf: s, ..._ } = $;
- i.push(
- ...$.oneOf.map((s) => main_sampleFromSchemaGeneric(TI(s, _, o), o, void 0, u))
- );
- } else {
- if (!(!u || (u && j.wrapped)))
- return main_sampleFromSchemaGeneric($, o, void 0, u);
- i.push(main_sampleFromSchemaGeneric($, o, void 0, u));
- }
- return (
- (i = jI.array(s, { sample: i })),
- u && j.wrapped ? ((le[Z] = i), hs()(C) || le[Z].push({ _attr: C }), le) : i
- );
- }
- if ('object' === U) {
- for (let s in ce)
- Object.hasOwn(ce, s) &&
- (ce[s]?.deprecated ||
- (ce[s]?.readOnly && !z) ||
- (ce[s]?.writeOnly && !Y) ||
- pe(s));
- if ((u && C && le[Z].push({ _attr: C }), hasExceededMaxProperties())) return le;
- if (predicates_isBooleanJSONSchema(B) && B)
- u
- ? le[Z].push({ additionalProp: 'Anything can be here' })
- : (le.additionalProp1 = {}),
- de++;
- else if (isJSONSchemaObject(B)) {
- const i = B,
- _ = main_sampleFromSchemaGeneric(i, o, void 0, u);
- if (u && 'string' == typeof i?.xml?.name && 'notagname' !== i?.xml?.name)
- le[Z].push(_);
- else {
- const o =
- Number.isInteger(s.minProperties) && s.minProperties > 0 && de < s.minProperties
- ? s.minProperties - de
- : 3;
- for (let s = 1; s <= o; s++) {
- if (hasExceededMaxProperties()) return le;
- if (u) {
- const o = {};
- (o['additionalProp' + s] = _.notagname), le[Z].push(o);
- } else le['additionalProp' + s] = _;
- de++;
- }
- }
- }
- return le;
- }
- let fe;
- if (void 0 !== s.const) fe = s.const;
- else if (s && Array.isArray(s.enum)) fe = random_pick(normalizeArray(s.enum));
- else {
- const i = isJSONSchemaObject(s.contentSchema)
- ? main_sampleFromSchemaGeneric(s.contentSchema, o, void 0, u)
- : void 0;
- fe = jI[U](s, { sample: i });
- }
- return u ? ((le[Z] = hs()(C) ? fe : [{ _attr: C }, fe]), le) : fe;
- },
- main_createXMLExample = (s, o, i) => {
- const u = main_sampleFromSchemaGeneric(s, o, i, !0);
- if (u) return 'string' == typeof u ? u : ls()(u, { declaration: !0, indent: '\t' });
- },
- main_sampleFromSchema = (s, o, i) => main_sampleFromSchemaGeneric(s, o, i, !1),
- main_resolver = (s, o, i) => [s, JSON.stringify(o), JSON.stringify(i)],
- NI = utils_memoizeN(main_createXMLExample, main_resolver),
- RI = utils_memoizeN(main_sampleFromSchema, main_resolver);
- const DI = new (class OptionRegistry extends uI {
- #t = {};
- data = { ...this.#t };
- get defaults() {
- return { ...this.#t };
- }
- })(),
- api_optionAPI = (s, o) => (void 0 !== o && DI.register(s, o), DI.get(s)),
- LI = [{ when: /json/, shouldStringifyTypes: ['string'] }],
- BI = ['object'],
- fn_get_json_sample_schema = (s) => (o, i, u, _) => {
- const { fn: w } = s(),
- x = w.jsonSchema202012.memoizedSampleFromSchema(o, i, _),
- C = typeof x,
- j = LI.reduce((s, o) => (o.when.test(u) ? [...s, ...o.shouldStringifyTypes] : s), BI);
- return mt()(j, (s) => s === C) ? JSON.stringify(x, null, 2) : x;
- },
- fn_get_yaml_sample_schema = (s) => (o, i, u, _) => {
- const { fn: w } = s(),
- x = w.jsonSchema202012.getJsonSampleSchema(o, i, u, _);
- let C;
- try {
- (C = mn.dump(mn.load(x), { lineWidth: -1 }, { schema: nn })),
- '\n' === C[C.length - 1] && (C = C.slice(0, C.length - 1));
- } catch (s) {
- return console.error(s), 'error: could not generate yaml example';
- }
- return C.replace(/\t/g, ' ');
- },
- fn_get_xml_sample_schema = (s) => (o, i, u) => {
- const { fn: _ } = s();
- if ((o && !o.xml && (o.xml = {}), o && !o.xml.name)) {
- if (!o.$$ref && (o.type || o.items || o.properties || o.additionalProperties))
- return '<?xml version="1.0" encoding="UTF-8"?>\n\x3c!-- XML example cannot be generated; root element name is undefined --\x3e';
- if (o.$$ref) {
- let s = o.$$ref.match(/\S*\/(\S+)$/);
- o.xml.name = s[1];
- }
- }
- return _.jsonSchema202012.memoizedCreateXMLExample(o, i, u);
- },
- fn_get_sample_schema =
- (s) =>
- (o, i = '', u = {}, _ = void 0) => {
- const { fn: w } = s();
- return (
- 'function' == typeof o?.toJS && (o = o.toJS()),
- 'function' == typeof _?.toJS && (_ = _.toJS()),
- /xml/.test(i)
- ? w.jsonSchema202012.getXmlSampleSchema(o, u, _)
- : /(yaml|yml)/.test(i)
- ? w.jsonSchema202012.getYamlSampleSchema(o, u, i, _)
- : w.jsonSchema202012.getJsonSampleSchema(o, u, i, _)
- );
- },
- json_schema_2020_12_samples = ({ getSystem: s }) => {
- const o = fn_get_json_sample_schema(s),
- i = fn_get_yaml_sample_schema(s),
- u = fn_get_xml_sample_schema(s),
- _ = fn_get_sample_schema(s);
- return {
- fn: {
- jsonSchema202012: {
- sampleFromSchema: main_sampleFromSchema,
- sampleFromSchemaGeneric: main_sampleFromSchemaGeneric,
- sampleOptionAPI: api_optionAPI,
- sampleEncoderAPI: EI,
- sampleFormatAPI: hI,
- sampleMediaTypeAPI: AI,
- createXMLExample: main_createXMLExample,
- memoizedSampleFromSchema: RI,
- memoizedCreateXMLExample: NI,
- getJsonSampleSchema: o,
- getYamlSampleSchema: i,
- getXmlSampleSchema: u,
- getSampleSchema: _,
- mergeJsonSchema: TI
- }
- }
- };
- };
- function PresetApis() {
- return [base, oas3, json_schema_2020_12, json_schema_2020_12_samples, oas31];
- }
- const inline_plugin = (s) => () => ({ fn: s.fn, components: s.components }),
- factorization_system = (s) => {
- const o = We()(
- {
- layout: { layout: s.layout, filter: s.filter },
- spec: { spec: '', url: s.url },
- requestSnippets: s.requestSnippets
- },
- s.initialState
- );
- if (s.initialState)
- for (const [i, u] of Object.entries(s.initialState)) void 0 === u && delete o[i];
- return { system: { configs: s.configs }, plugins: s.presets, state: o };
- },
- sources_query = () => (s) => {
- const o = s.queryConfigEnabled
- ? (() => {
- const s = new URLSearchParams(at.location.search);
- return Object.fromEntries(s);
- })()
- : {};
- return Object.entries(o).reduce(
- (s, [o, i]) => (
- 'config' === o
- ? (s.configUrl = i)
- : 'urls.primaryName' === o
- ? (s[o] = i)
- : (s = ao()(s, o, i)),
- s
- ),
- {}
- );
- },
- sources_url =
- ({ url: s, system: o }) =>
- async (i) => {
- if (!s) return {};
- if ('function' != typeof o.configsActions?.getConfigByUrl) return {};
- const u = (() => {
- const s = {};
- return (
- (s.promise = new Promise((o, i) => {
- (s.resolve = o), (s.reject = i);
- })),
- s
- );
- })();
- return (
- o.configsActions.getConfigByUrl(
- {
- url: s,
- loadRemoteConfig: !0,
- requestInterceptor: i.requestInterceptor,
- responseInterceptor: i.responseInterceptor
- },
- (s) => {
- u.resolve(s);
- }
- ),
- u.promise
- );
- },
- runtime = () => () => {
- const s = {};
- return (
- globalThis.location &&
- (s.oauth2RedirectUrl = `${globalThis.location.protocol}//${globalThis.location.host}${globalThis.location.pathname.substring(0, globalThis.location.pathname.lastIndexOf('/'))}/oauth2-redirect.html`),
- s
- );
- },
- FI = Object.freeze({
- dom_id: null,
- domNode: null,
- spec: {},
- url: '',
- urls: null,
- configUrl: null,
- layout: 'BaseLayout',
- docExpansion: 'list',
- maxDisplayedTags: -1,
- filter: !1,
- validatorUrl: 'https://validator.swagger.io/validator',
- oauth2RedirectUrl: void 0,
- persistAuthorization: !1,
- configs: {},
- displayOperationId: !1,
- displayRequestDuration: !1,
- deepLinking: !1,
- tryItOutEnabled: !1,
- requestInterceptor: (s) => ((s.curlOptions = []), s),
- responseInterceptor: (s) => s,
- showMutatedRequest: !0,
- defaultModelRendering: 'example',
- defaultModelExpandDepth: 1,
- defaultModelsExpandDepth: 1,
- showExtensions: !1,
- showCommonExtensions: !1,
- withCredentials: !1,
- requestSnippetsEnabled: !1,
- requestSnippets: {
- generators: {
- curl_bash: { title: 'cURL (bash)', syntax: 'bash' },
- curl_powershell: { title: 'cURL (PowerShell)', syntax: 'powershell' },
- curl_cmd: { title: 'cURL (CMD)', syntax: 'bash' }
- },
- defaultExpanded: !0,
- languages: null
- },
- supportedSubmitMethods: [
- 'get',
- 'put',
- 'post',
- 'delete',
- 'options',
- 'head',
- 'patch',
- 'trace'
- ],
- queryConfigEnabled: !1,
- presets: [PresetApis],
- plugins: [],
- initialState: {},
- fn: {},
- components: {},
- syntaxHighlight: { activated: !0, theme: 'agate' },
- operationsSorter: null,
- tagsSorter: null,
- onComplete: null,
- modelPropertyMacro: null,
- parameterMacro: null
- });
- var qI = __webpack_require__(61448),
- $I = __webpack_require__.n(qI),
- VI = __webpack_require__(77731),
- UI = __webpack_require__.n(VI);
- const type_casters_array = (s, o = []) => (Array.isArray(s) ? s : o),
- type_casters_boolean = (s, o = !1) =>
- !0 === s ||
- 'true' === s ||
- 1 === s ||
- '1' === s ||
- (!1 !== s && 'false' !== s && 0 !== s && '0' !== s && o),
- dom_node = (s) => (null === s || 'null' === s ? null : s),
- type_casters_filter = (s) => {
- const o = String(s);
- return type_casters_boolean(s, o);
- },
- type_casters_function = (s, o) => ('function' == typeof s ? s : o),
- nullable_array = (s) => (Array.isArray(s) ? s : null),
- nullable_function = (s) => ('function' == typeof s ? s : null),
- nullable_string = (s) => (null === s || 'null' === s ? null : String(s)),
- type_casters_number = (s, o = -1) => {
- const i = parseInt(s, 10);
- return Number.isNaN(i) ? o : i;
- },
- type_casters_object = (s, o = {}) => (cI()(s) ? s : o),
- sorter = (s) => ('function' == typeof s || 'string' == typeof s ? s : null),
- type_casters_string = (s) => String(s),
- syntax_highlight = (s, o) =>
- cI()(s) ? s : !1 === s || 'false' === s || 0 === s || '0' === s ? { activated: !1 } : o,
- undefined_string = (s) => (void 0 === s || 'undefined' === s ? void 0 : String(s)),
- zI = {
- components: { typeCaster: type_casters_object },
- configs: { typeCaster: type_casters_object },
- configUrl: { typeCaster: nullable_string },
- deepLinking: { typeCaster: type_casters_boolean, defaultValue: FI.deepLinking },
- defaultModelExpandDepth: {
- typeCaster: type_casters_number,
- defaultValue: FI.defaultModelExpandDepth
- },
- defaultModelRendering: { typeCaster: type_casters_string },
- defaultModelsExpandDepth: {
- typeCaster: type_casters_number,
- defaultValue: FI.defaultModelsExpandDepth
- },
- displayOperationId: {
- typeCaster: type_casters_boolean,
- defaultValue: FI.displayOperationId
- },
- displayRequestDuration: {
- typeCaster: type_casters_boolean,
- defaultValue: FI.displayRequestDuration
- },
- docExpansion: { typeCaster: type_casters_string },
- dom_id: { typeCaster: nullable_string },
- domNode: { typeCaster: dom_node },
- filter: { typeCaster: type_casters_filter },
- fn: { typeCaster: type_casters_object },
- initialState: { typeCaster: type_casters_object },
- layout: { typeCaster: type_casters_string },
- maxDisplayedTags: {
- typeCaster: type_casters_number,
- defaultValue: FI.maxDisplayedTags
- },
- modelPropertyMacro: { typeCaster: nullable_function },
- oauth2RedirectUrl: { typeCaster: undefined_string },
- onComplete: { typeCaster: nullable_function },
- operationsSorter: { typeCaster: sorter },
- paramaterMacro: { typeCaster: nullable_function },
- persistAuthorization: {
- typeCaster: type_casters_boolean,
- defaultValue: FI.persistAuthorization
- },
- plugins: { typeCaster: type_casters_array, defaultValue: FI.plugins },
- presets: { typeCaster: type_casters_array, defaultValue: FI.presets },
- requestInterceptor: {
- typeCaster: type_casters_function,
- defaultValue: FI.requestInterceptor
- },
- requestSnippets: { typeCaster: type_casters_object, defaultValue: FI.requestSnippets },
- requestSnippetsEnabled: {
- typeCaster: type_casters_boolean,
- defaultValue: FI.requestSnippetsEnabled
- },
- responseInterceptor: {
- typeCaster: type_casters_function,
- defaultValue: FI.responseInterceptor
- },
- showCommonExtensions: {
- typeCaster: type_casters_boolean,
- defaultValue: FI.showCommonExtensions
- },
- showExtensions: { typeCaster: type_casters_boolean, defaultValue: FI.showExtensions },
- showMutatedRequest: {
- typeCaster: type_casters_boolean,
- defaultValue: FI.showMutatedRequest
- },
- spec: { typeCaster: type_casters_object, defaultValue: FI.spec },
- supportedSubmitMethods: {
- typeCaster: type_casters_array,
- defaultValue: FI.supportedSubmitMethods
- },
- syntaxHighlight: { typeCaster: syntax_highlight, defaultValue: FI.syntaxHighlight },
- 'syntaxHighlight.activated': {
- typeCaster: type_casters_boolean,
- defaultValue: FI.syntaxHighlight.activated
- },
- 'syntaxHighlight.theme': { typeCaster: type_casters_string },
- tagsSorter: { typeCaster: sorter },
- tryItOutEnabled: { typeCaster: type_casters_boolean, defaultValue: FI.tryItOutEnabled },
- url: { typeCaster: type_casters_string },
- urls: { typeCaster: nullable_array },
- 'urls.primaryName': { typeCaster: type_casters_string },
- validatorUrl: { typeCaster: nullable_string },
- withCredentials: { typeCaster: type_casters_boolean, defaultValue: FI.withCredentials }
- },
- type_cast = (s) =>
- Object.entries(zI).reduce(
- (s, [o, { typeCaster: i, defaultValue: u }]) => {
- if ($I()(s, o)) {
- const _ = i(jn()(s, o), u);
- s = UI()(o, _, s);
- }
- return s;
- },
- { ...s }
- ),
- config_merge = (s, ...o) => {
- let i = Symbol.for('domNode'),
- u = Symbol.for('primaryName');
- const _ = [];
- for (const s of o) {
- const o = { ...s };
- Object.hasOwn(o, 'domNode') && ((i = o.domNode), delete o.domNode),
- Object.hasOwn(o, 'urls.primaryName')
- ? ((u = o['urls.primaryName']), delete o['urls.primaryName'])
- : Array.isArray(o.urls) &&
- Object.hasOwn(o.urls, 'primaryName') &&
- ((u = o.urls.primaryName), delete o.urls.primaryName),
- _.push(o);
- }
- const w = We()(s, ..._);
- return (
- i !== Symbol.for('domNode') && (w.domNode = i),
- u !== Symbol.for('primaryName') && Array.isArray(w.urls) && (w.urls.primaryName = u),
- type_cast(w)
- );
- };
- function SwaggerUI(s) {
- const o = sources_query()(s),
- i = runtime()(),
- u = SwaggerUI.config.merge({}, SwaggerUI.config.defaults, i, s, o),
- _ = factorization_system(u),
- w = inline_plugin(u),
- x = new Store(_);
- x.register([u.plugins, w]);
- const C = x.getSystem(),
- persistConfigs = (s) => {
- x.setConfigs(s), C.configsActions.loaded();
- },
- updateSpec = (s) => {
- !o.url && 'object' == typeof s.spec && Object.keys(s.spec).length > 0
- ? (C.specActions.updateUrl(''),
- C.specActions.updateLoadingStatus('success'),
- C.specActions.updateSpec(JSON.stringify(s.spec)))
- : 'function' == typeof C.specActions.download &&
- s.url &&
- !s.urls &&
- (C.specActions.updateUrl(s.url), C.specActions.download(s.url));
- },
- render = (s) => {
- if (s.domNode) C.render(s.domNode, 'App');
- else if (s.dom_id) {
- const o = document.querySelector(s.dom_id);
- C.render(o, 'App');
- } else
- null === s.dom_id ||
- null === s.domNode ||
- console.error('Skipped rendering: no `dom_id` or `domNode` was specified');
- };
- return u.configUrl
- ? ((async () => {
- const { configUrl: s } = u,
- i = await sources_url({ url: s, system: C })(u),
- _ = SwaggerUI.config.merge({}, u, i, o);
- persistConfigs(_), null !== i && updateSpec(_), render(_);
- })(),
- C)
- : (persistConfigs(u), updateSpec(u), render(u), C);
- }
- (SwaggerUI.System = Store),
- (SwaggerUI.config = {
- defaults: FI,
- merge: config_merge,
- typeCast: type_cast,
- typeCastMappings: zI
- }),
- (SwaggerUI.presets = { base, apis: PresetApis }),
- (SwaggerUI.plugins = {
- Auth: auth,
- Configs: configsPlugin,
- DeepLining: deep_linking,
- Err: err,
- Filter: filter,
- Icons: icons,
- JSONSchema5: json_schema_5,
- JSONSchema5Samples: json_schema_5_samples,
- JSONSchema202012: json_schema_2020_12,
- JSONSchema202012Samples: json_schema_2020_12_samples,
- Layout: plugins_layout,
- Logs: logs,
- OpenAPI30: oas3,
- OpenAPI31: oas3,
- OnComplete: on_complete,
- RequestSnippets: plugins_request_snippets,
- Spec: plugins_spec,
- SwaggerClient: swagger_client,
- Util: util,
- View: view,
- ViewLegacy: view_legacy,
- DownloadUrl: downloadUrlPlugin,
- SyntaxHighlighting: syntax_highlighting,
- Versions: versions,
- SafeRender: safe_render
- });
- const WI = SwaggerUI;
- })(),
- (_ = _.default)
- );
- })()
- );
|