bundle.js 630 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795479647974798479948004801480248034804480548064807480848094810481148124813481448154816481748184819482048214822482348244825482648274828482948304831483248334834483548364837483848394840484148424843484448454846484748484849485048514852485348544855485648574858485948604861486248634864486548664867486848694870487148724873487448754876487748784879488048814882488348844885488648874888488948904891489248934894489548964897489848994900490149024903490449054906490749084909491049114912491349144915491649174918491949204921492249234924492549264927492849294930493149324933493449354936493749384939494049414942494349444945494649474948494949504951495249534954495549564957495849594960496149624963496449654966496749684969497049714972497349744975497649774978497949804981498249834984498549864987498849894990499149924993499449954996499749984999500050015002500350045005500650075008500950105011501250135014501550165017501850195020502150225023502450255026502750285029503050315032503350345035503650375038503950405041504250435044504550465047504850495050505150525053505450555056505750585059506050615062506350645065506650675068506950705071507250735074507550765077507850795080508150825083508450855086508750885089509050915092509350945095509650975098509951005101510251035104510551065107510851095110511151125113511451155116511751185119512051215122512351245125512651275128512951305131513251335134513551365137513851395140514151425143514451455146514751485149515051515152515351545155515651575158515951605161516251635164516551665167516851695170517151725173517451755176517751785179518051815182518351845185518651875188518951905191519251935194519551965197519851995200520152025203520452055206520752085209521052115212521352145215521652175218521952205221522252235224522552265227522852295230523152325233523452355236523752385239524052415242524352445245524652475248524952505251525252535254525552565257525852595260526152625263526452655266526752685269527052715272527352745275527652775278527952805281528252835284528552865287528852895290529152925293529452955296529752985299530053015302530353045305530653075308530953105311531253135314531553165317531853195320532153225323532453255326532753285329533053315332533353345335533653375338533953405341534253435344534553465347534853495350535153525353535453555356535753585359536053615362536353645365536653675368536953705371537253735374537553765377537853795380538153825383538453855386538753885389539053915392539353945395539653975398539954005401540254035404540554065407540854095410541154125413541454155416541754185419542054215422542354245425542654275428542954305431543254335434543554365437543854395440544154425443544454455446544754485449545054515452545354545455545654575458545954605461546254635464546554665467546854695470547154725473547454755476547754785479548054815482548354845485548654875488548954905491549254935494549554965497549854995500550155025503550455055506550755085509551055115512551355145515551655175518551955205521552255235524552555265527552855295530553155325533553455355536553755385539554055415542554355445545554655475548554955505551555255535554555555565557555855595560556155625563556455655566556755685569557055715572557355745575557655775578557955805581558255835584558555865587558855895590559155925593559455955596559755985599560056015602560356045605560656075608560956105611561256135614561556165617561856195620562156225623562456255626562756285629563056315632563356345635563656375638563956405641564256435644564556465647564856495650565156525653565456555656565756585659566056615662566356645665566656675668566956705671567256735674567556765677567856795680568156825683568456855686568756885689569056915692569356945695569656975698569957005701570257035704570557065707570857095710571157125713571457155716571757185719572057215722572357245725572657275728572957305731573257335734573557365737573857395740574157425743574457455746574757485749575057515752575357545755575657575758575957605761576257635764576557665767576857695770577157725773577457755776577757785779578057815782578357845785578657875788578957905791579257935794579557965797579857995800580158025803580458055806580758085809581058115812581358145815581658175818581958205821582258235824582558265827582858295830583158325833583458355836583758385839584058415842584358445845584658475848584958505851585258535854585558565857585858595860586158625863586458655866586758685869587058715872587358745875587658775878587958805881588258835884588558865887588858895890589158925893589458955896589758985899590059015902590359045905590659075908590959105911591259135914591559165917591859195920592159225923592459255926592759285929593059315932593359345935593659375938593959405941594259435944594559465947594859495950595159525953595459555956595759585959596059615962596359645965596659675968596959705971597259735974597559765977597859795980598159825983598459855986598759885989599059915992599359945995599659975998599960006001600260036004600560066007600860096010601160126013601460156016601760186019602060216022602360246025602660276028602960306031603260336034603560366037603860396040604160426043604460456046604760486049605060516052605360546055605660576058605960606061606260636064606560666067606860696070607160726073607460756076607760786079608060816082608360846085608660876088608960906091609260936094609560966097609860996100610161026103610461056106610761086109611061116112611361146115611661176118611961206121612261236124612561266127612861296130613161326133613461356136613761386139614061416142614361446145614661476148614961506151615261536154615561566157615861596160616161626163616461656166616761686169617061716172617361746175617661776178617961806181618261836184618561866187618861896190619161926193619461956196619761986199620062016202620362046205620662076208620962106211621262136214621562166217621862196220622162226223622462256226622762286229623062316232623362346235623662376238623962406241624262436244624562466247624862496250625162526253625462556256625762586259626062616262626362646265626662676268626962706271627262736274627562766277627862796280628162826283628462856286628762886289629062916292629362946295629662976298629963006301630263036304630563066307630863096310631163126313631463156316631763186319632063216322632363246325632663276328632963306331633263336334633563366337633863396340634163426343634463456346634763486349635063516352635363546355635663576358635963606361636263636364636563666367636863696370637163726373637463756376637763786379638063816382638363846385638663876388638963906391639263936394639563966397639863996400640164026403640464056406640764086409641064116412641364146415641664176418641964206421642264236424642564266427642864296430643164326433643464356436643764386439644064416442644364446445644664476448644964506451645264536454645564566457645864596460646164626463646464656466646764686469647064716472647364746475647664776478647964806481648264836484648564866487648864896490649164926493649464956496649764986499650065016502650365046505650665076508650965106511651265136514651565166517651865196520652165226523652465256526652765286529653065316532653365346535653665376538653965406541654265436544654565466547654865496550655165526553655465556556655765586559656065616562656365646565656665676568656965706571657265736574657565766577657865796580658165826583658465856586658765886589659065916592659365946595659665976598659966006601660266036604660566066607660866096610661166126613661466156616661766186619662066216622662366246625662666276628662966306631663266336634663566366637663866396640664166426643664466456646664766486649665066516652665366546655665666576658665966606661666266636664666566666667666866696670667166726673667466756676667766786679668066816682668366846685668666876688668966906691669266936694669566966697669866996700670167026703670467056706670767086709671067116712671367146715671667176718671967206721672267236724672567266727672867296730673167326733673467356736673767386739674067416742674367446745674667476748674967506751675267536754675567566757675867596760676167626763676467656766676767686769677067716772677367746775677667776778677967806781678267836784678567866787678867896790679167926793679467956796679767986799680068016802680368046805680668076808680968106811681268136814681568166817681868196820682168226823682468256826682768286829683068316832683368346835683668376838683968406841684268436844684568466847684868496850685168526853685468556856685768586859686068616862686368646865686668676868686968706871687268736874687568766877687868796880688168826883688468856886688768886889689068916892689368946895689668976898689969006901690269036904690569066907690869096910691169126913691469156916691769186919692069216922692369246925692669276928692969306931693269336934693569366937693869396940694169426943694469456946694769486949695069516952695369546955695669576958695969606961696269636964696569666967696869696970697169726973697469756976697769786979698069816982698369846985698669876988698969906991699269936994699569966997699869997000700170027003700470057006700770087009701070117012701370147015701670177018701970207021702270237024702570267027702870297030703170327033703470357036703770387039704070417042704370447045704670477048704970507051705270537054705570567057705870597060706170627063706470657066706770687069707070717072707370747075707670777078707970807081708270837084708570867087708870897090709170927093709470957096709770987099710071017102710371047105710671077108710971107111711271137114711571167117711871197120712171227123712471257126712771287129713071317132713371347135713671377138713971407141714271437144714571467147714871497150715171527153715471557156715771587159716071617162716371647165716671677168716971707171717271737174717571767177717871797180718171827183718471857186718771887189719071917192719371947195719671977198719972007201720272037204720572067207720872097210721172127213721472157216721772187219722072217222722372247225722672277228722972307231723272337234723572367237723872397240724172427243724472457246724772487249725072517252725372547255725672577258725972607261726272637264726572667267726872697270727172727273727472757276727772787279728072817282728372847285728672877288728972907291729272937294729572967297729872997300730173027303730473057306730773087309731073117312731373147315731673177318731973207321732273237324732573267327732873297330733173327333733473357336733773387339734073417342734373447345734673477348734973507351735273537354735573567357735873597360736173627363736473657366736773687369737073717372737373747375737673777378737973807381738273837384738573867387738873897390739173927393739473957396739773987399740074017402740374047405740674077408740974107411741274137414741574167417741874197420742174227423742474257426742774287429743074317432743374347435743674377438743974407441744274437444744574467447744874497450745174527453745474557456745774587459746074617462746374647465746674677468746974707471747274737474747574767477747874797480748174827483748474857486748774887489749074917492749374947495749674977498749975007501750275037504750575067507750875097510751175127513751475157516751775187519752075217522752375247525752675277528752975307531753275337534753575367537753875397540754175427543754475457546754775487549755075517552755375547555755675577558755975607561756275637564756575667567756875697570757175727573757475757576757775787579758075817582758375847585758675877588758975907591759275937594759575967597759875997600760176027603760476057606760776087609761076117612761376147615761676177618761976207621762276237624762576267627762876297630763176327633763476357636763776387639764076417642764376447645764676477648764976507651765276537654765576567657765876597660766176627663766476657666766776687669767076717672767376747675767676777678767976807681768276837684768576867687768876897690769176927693769476957696769776987699770077017702770377047705770677077708770977107711771277137714771577167717771877197720772177227723772477257726772777287729773077317732773377347735773677377738773977407741774277437744774577467747774877497750775177527753775477557756775777587759776077617762776377647765776677677768776977707771777277737774777577767777777877797780778177827783778477857786778777887789779077917792779377947795779677977798779978007801780278037804780578067807780878097810781178127813781478157816781778187819782078217822782378247825782678277828782978307831783278337834783578367837783878397840784178427843784478457846784778487849785078517852785378547855785678577858785978607861786278637864786578667867786878697870787178727873787478757876787778787879788078817882788378847885788678877888788978907891789278937894789578967897789878997900790179027903790479057906790779087909791079117912791379147915791679177918791979207921792279237924792579267927792879297930793179327933793479357936793779387939794079417942794379447945794679477948794979507951795279537954795579567957795879597960796179627963796479657966796779687969797079717972797379747975797679777978797979807981798279837984798579867987798879897990799179927993799479957996799779987999800080018002800380048005800680078008800980108011801280138014801580168017801880198020802180228023802480258026802780288029803080318032803380348035803680378038803980408041804280438044804580468047804880498050805180528053805480558056805780588059806080618062806380648065806680678068806980708071807280738074807580768077807880798080808180828083808480858086808780888089809080918092809380948095809680978098809981008101810281038104810581068107810881098110811181128113811481158116811781188119812081218122812381248125812681278128812981308131813281338134813581368137813881398140814181428143814481458146814781488149815081518152815381548155815681578158815981608161816281638164816581668167816881698170817181728173817481758176817781788179818081818182818381848185818681878188818981908191819281938194819581968197819881998200820182028203820482058206820782088209821082118212821382148215821682178218821982208221822282238224822582268227822882298230823182328233823482358236823782388239824082418242824382448245824682478248824982508251825282538254825582568257825882598260826182628263826482658266826782688269827082718272827382748275827682778278827982808281828282838284828582868287828882898290829182928293829482958296829782988299830083018302830383048305830683078308830983108311831283138314831583168317831883198320832183228323832483258326832783288329833083318332833383348335833683378338833983408341834283438344834583468347834883498350835183528353835483558356835783588359836083618362836383648365836683678368836983708371837283738374837583768377837883798380838183828383838483858386838783888389839083918392839383948395839683978398839984008401840284038404840584068407840884098410841184128413841484158416841784188419842084218422842384248425842684278428842984308431843284338434843584368437843884398440844184428443844484458446844784488449845084518452845384548455845684578458845984608461846284638464846584668467846884698470847184728473847484758476847784788479848084818482848384848485848684878488848984908491849284938494849584968497849884998500850185028503850485058506850785088509851085118512851385148515851685178518851985208521852285238524852585268527852885298530853185328533853485358536853785388539854085418542854385448545854685478548854985508551855285538554855585568557855885598560856185628563856485658566856785688569857085718572857385748575857685778578857985808581858285838584858585868587858885898590859185928593859485958596859785988599860086018602860386048605860686078608860986108611861286138614861586168617861886198620862186228623862486258626862786288629863086318632863386348635863686378638863986408641864286438644864586468647864886498650865186528653865486558656865786588659866086618662866386648665866686678668866986708671867286738674867586768677867886798680868186828683868486858686868786888689869086918692869386948695869686978698869987008701870287038704870587068707870887098710871187128713871487158716871787188719872087218722872387248725872687278728872987308731873287338734873587368737873887398740874187428743874487458746874787488749875087518752875387548755875687578758875987608761876287638764876587668767876887698770877187728773877487758776877787788779878087818782878387848785878687878788878987908791879287938794879587968797879887998800880188028803880488058806880788088809881088118812881388148815881688178818881988208821882288238824882588268827882888298830883188328833883488358836883788388839884088418842884388448845884688478848884988508851885288538854885588568857885888598860886188628863886488658866886788688869887088718872887388748875887688778878887988808881888288838884888588868887888888898890889188928893889488958896889788988899890089018902890389048905890689078908890989108911891289138914891589168917891889198920892189228923892489258926892789288929893089318932893389348935893689378938893989408941894289438944894589468947894889498950895189528953895489558956895789588959896089618962896389648965896689678968896989708971897289738974897589768977897889798980898189828983898489858986898789888989899089918992899389948995899689978998899990009001900290039004900590069007900890099010901190129013901490159016901790189019902090219022902390249025902690279028902990309031903290339034903590369037903890399040904190429043904490459046904790489049905090519052905390549055905690579058905990609061906290639064906590669067906890699070907190729073907490759076907790789079908090819082908390849085908690879088908990909091909290939094909590969097909890999100910191029103910491059106910791089109911091119112911391149115911691179118911991209121912291239124912591269127912891299130913191329133913491359136913791389139914091419142914391449145914691479148914991509151915291539154915591569157915891599160916191629163916491659166916791689169917091719172917391749175917691779178917991809181918291839184918591869187918891899190919191929193919491959196919791989199920092019202920392049205920692079208920992109211921292139214921592169217921892199220922192229223922492259226922792289229923092319232923392349235923692379238923992409241924292439244924592469247924892499250925192529253925492559256925792589259926092619262926392649265926692679268926992709271927292739274927592769277927892799280928192829283928492859286928792889289929092919292929392949295929692979298929993009301930293039304930593069307930893099310931193129313931493159316931793189319932093219322932393249325932693279328932993309331933293339334933593369337933893399340934193429343934493459346934793489349935093519352935393549355935693579358935993609361936293639364936593669367936893699370937193729373937493759376937793789379938093819382938393849385938693879388938993909391939293939394939593969397939893999400940194029403940494059406940794089409941094119412941394149415941694179418941994209421942294239424942594269427942894299430943194329433943494359436943794389439944094419442944394449445944694479448944994509451945294539454945594569457945894599460946194629463946494659466946794689469947094719472947394749475947694779478947994809481948294839484948594869487948894899490949194929493949494959496949794989499950095019502950395049505950695079508950995109511951295139514951595169517951895199520952195229523952495259526952795289529953095319532953395349535953695379538953995409541954295439544954595469547954895499550955195529553955495559556955795589559956095619562956395649565956695679568956995709571957295739574957595769577957895799580958195829583958495859586958795889589959095919592959395949595959695979598959996009601960296039604960596069607960896099610961196129613961496159616961796189619962096219622962396249625962696279628962996309631963296339634963596369637963896399640964196429643964496459646964796489649965096519652965396549655965696579658965996609661966296639664966596669667966896699670967196729673967496759676967796789679968096819682968396849685968696879688968996909691969296939694969596969697969896999700970197029703970497059706970797089709971097119712971397149715971697179718971997209721972297239724972597269727972897299730973197329733973497359736973797389739974097419742974397449745974697479748974997509751975297539754975597569757975897599760976197629763976497659766976797689769977097719772977397749775977697779778977997809781978297839784978597869787978897899790979197929793979497959796979797989799980098019802980398049805980698079808980998109811981298139814981598169817981898199820982198229823982498259826982798289829983098319832983398349835983698379838983998409841984298439844984598469847984898499850985198529853985498559856985798589859986098619862986398649865986698679868986998709871987298739874987598769877987898799880988198829883988498859886988798889889989098919892989398949895989698979898989999009901990299039904990599069907990899099910991199129913991499159916991799189919992099219922992399249925992699279928992999309931993299339934993599369937993899399940994199429943994499459946994799489949995099519952995399549955995699579958995999609961996299639964996599669967996899699970997199729973997499759976997799789979998099819982998399849985998699879988998999909991999299939994999599969997999899991000010001100021000310004100051000610007100081000910010100111001210013100141001510016100171001810019100201002110022100231002410025100261002710028100291003010031100321003310034100351003610037100381003910040100411004210043100441004510046100471004810049100501005110052100531005410055100561005710058100591006010061100621006310064100651006610067100681006910070100711007210073100741007510076100771007810079100801008110082100831008410085100861008710088100891009010091100921009310094100951009610097100981009910100101011010210103101041010510106101071010810109101101011110112101131011410115101161011710118101191012010121101221012310124101251012610127101281012910130101311013210133101341013510136101371013810139101401014110142101431014410145101461014710148101491015010151101521015310154101551015610157101581015910160101611016210163101641016510166101671016810169101701017110172101731017410175101761017710178101791018010181101821018310184101851018610187101881018910190101911019210193101941019510196101971019810199102001020110202102031020410205102061020710208102091021010211102121021310214102151021610217102181021910220102211022210223102241022510226102271022810229102301023110232102331023410235102361023710238102391024010241102421024310244102451024610247102481024910250102511025210253102541025510256102571025810259102601026110262102631026410265102661026710268102691027010271102721027310274102751027610277102781027910280102811028210283102841028510286102871028810289102901029110292102931029410295102961029710298102991030010301103021030310304103051030610307103081030910310103111031210313103141031510316103171031810319103201032110322103231032410325103261032710328103291033010331103321033310334103351033610337103381033910340103411034210343103441034510346103471034810349103501035110352103531035410355103561035710358103591036010361103621036310364103651036610367103681036910370103711037210373103741037510376103771037810379103801038110382103831038410385103861038710388103891039010391103921039310394103951039610397103981039910400104011040210403104041040510406104071040810409104101041110412104131041410415104161041710418104191042010421104221042310424104251042610427104281042910430104311043210433104341043510436104371043810439104401044110442104431044410445104461044710448104491045010451104521045310454104551045610457104581045910460104611046210463104641046510466104671046810469104701047110472104731047410475104761047710478104791048010481104821048310484104851048610487104881048910490104911049210493104941049510496104971049810499105001050110502105031050410505105061050710508105091051010511105121051310514105151051610517105181051910520105211052210523105241052510526105271052810529105301053110532105331053410535105361053710538105391054010541105421054310544105451054610547105481054910550105511055210553105541055510556105571055810559105601056110562105631056410565105661056710568105691057010571105721057310574105751057610577105781057910580105811058210583105841058510586105871058810589105901059110592105931059410595105961059710598105991060010601106021060310604106051060610607106081060910610106111061210613106141061510616106171061810619106201062110622106231062410625106261062710628106291063010631106321063310634106351063610637106381063910640106411064210643106441064510646106471064810649106501065110652106531065410655106561065710658106591066010661106621066310664106651066610667106681066910670106711067210673106741067510676106771067810679106801068110682106831068410685106861068710688106891069010691106921069310694106951069610697106981069910700107011070210703107041070510706107071070810709107101071110712107131071410715107161071710718107191072010721107221072310724107251072610727107281072910730107311073210733107341073510736107371073810739107401074110742107431074410745107461074710748107491075010751107521075310754107551075610757107581075910760107611076210763107641076510766107671076810769107701077110772107731077410775107761077710778107791078010781107821078310784107851078610787107881078910790107911079210793107941079510796107971079810799108001080110802108031080410805108061080710808108091081010811108121081310814108151081610817108181081910820108211082210823108241082510826108271082810829108301083110832108331083410835108361083710838108391084010841108421084310844108451084610847108481084910850108511085210853108541085510856108571085810859108601086110862108631086410865108661086710868108691087010871108721087310874108751087610877108781087910880108811088210883108841088510886108871088810889108901089110892108931089410895108961089710898108991090010901109021090310904109051090610907109081090910910109111091210913109141091510916109171091810919109201092110922109231092410925109261092710928109291093010931109321093310934109351093610937109381093910940109411094210943109441094510946109471094810949109501095110952109531095410955109561095710958109591096010961109621096310964109651096610967109681096910970109711097210973109741097510976109771097810979109801098110982109831098410985109861098710988109891099010991109921099310994109951099610997109981099911000110011100211003110041100511006110071100811009110101101111012110131101411015110161101711018110191102011021110221102311024110251102611027110281102911030110311103211033110341103511036110371103811039110401104111042110431104411045110461104711048110491105011051110521105311054110551105611057110581105911060110611106211063110641106511066110671106811069110701107111072110731107411075110761107711078110791108011081110821108311084110851108611087110881108911090110911109211093110941109511096110971109811099111001110111102111031110411105111061110711108111091111011111111121111311114111151111611117111181111911120111211112211123111241112511126111271112811129111301113111132111331113411135111361113711138111391114011141111421114311144111451114611147111481114911150111511115211153111541115511156111571115811159111601116111162111631116411165111661116711168111691117011171111721117311174111751117611177111781117911180111811118211183111841118511186111871118811189111901119111192111931119411195111961119711198111991120011201112021120311204112051120611207112081120911210112111121211213112141121511216112171121811219112201122111222112231122411225112261122711228112291123011231112321123311234112351123611237112381123911240112411124211243112441124511246112471124811249112501125111252112531125411255112561125711258112591126011261112621126311264112651126611267112681126911270112711127211273112741127511276112771127811279112801128111282112831128411285112861128711288112891129011291112921129311294112951129611297112981129911300113011130211303113041130511306113071130811309113101131111312113131131411315113161131711318113191132011321113221132311324113251132611327113281132911330113311133211333113341133511336113371133811339113401134111342113431134411345113461134711348113491135011351113521135311354113551135611357113581135911360113611136211363113641136511366113671136811369113701137111372113731137411375113761137711378113791138011381113821138311384113851138611387113881138911390113911139211393113941139511396113971139811399114001140111402114031140411405114061140711408114091141011411114121141311414114151141611417114181141911420114211142211423114241142511426114271142811429114301143111432114331143411435114361143711438114391144011441114421144311444114451144611447114481144911450114511145211453114541145511456114571145811459114601146111462114631146411465114661146711468114691147011471114721147311474114751147611477114781147911480114811148211483114841148511486114871148811489114901149111492114931149411495114961149711498114991150011501115021150311504115051150611507115081150911510115111151211513115141151511516115171151811519115201152111522115231152411525115261152711528115291153011531115321153311534115351153611537115381153911540115411154211543115441154511546115471154811549115501155111552115531155411555115561155711558115591156011561115621156311564115651156611567115681156911570115711157211573115741157511576115771157811579115801158111582115831158411585115861158711588115891159011591115921159311594115951159611597115981159911600116011160211603116041160511606116071160811609116101161111612116131161411615116161161711618116191162011621116221162311624116251162611627116281162911630116311163211633116341163511636116371163811639116401164111642116431164411645116461164711648116491165011651116521165311654116551165611657116581165911660116611166211663116641166511666116671166811669116701167111672116731167411675116761167711678116791168011681116821168311684116851168611687116881168911690116911169211693116941169511696116971169811699117001170111702117031170411705117061170711708117091171011711117121171311714117151171611717117181171911720117211172211723117241172511726117271172811729117301173111732117331173411735117361173711738117391174011741117421174311744117451174611747117481174911750117511175211753117541175511756117571175811759117601176111762117631176411765117661176711768117691177011771117721177311774117751177611777117781177911780117811178211783117841178511786117871178811789117901179111792117931179411795117961179711798117991180011801118021180311804118051180611807118081180911810118111181211813118141181511816118171181811819118201182111822118231182411825118261182711828118291183011831118321183311834118351183611837118381183911840118411184211843118441184511846118471184811849118501185111852118531185411855118561185711858118591186011861118621186311864118651186611867118681186911870118711187211873118741187511876118771187811879118801188111882118831188411885118861188711888118891189011891118921189311894118951189611897118981189911900119011190211903119041190511906119071190811909119101191111912119131191411915119161191711918119191192011921119221192311924119251192611927119281192911930119311193211933119341193511936119371193811939119401194111942119431194411945119461194711948119491195011951119521195311954119551195611957119581195911960119611196211963119641196511966119671196811969119701197111972119731197411975119761197711978119791198011981119821198311984119851198611987119881198911990119911199211993119941199511996119971199811999120001200112002120031200412005120061200712008120091201012011120121201312014120151201612017120181201912020120211202212023120241202512026120271202812029120301203112032120331203412035120361203712038120391204012041120421204312044120451204612047120481204912050120511205212053120541205512056120571205812059120601206112062120631206412065120661206712068120691207012071120721207312074120751207612077120781207912080120811208212083120841208512086120871208812089120901209112092120931209412095120961209712098120991210012101121021210312104121051210612107121081210912110121111211212113121141211512116121171211812119121201212112122121231212412125121261212712128121291213012131121321213312134121351213612137121381213912140121411214212143121441214512146121471214812149121501215112152121531215412155121561215712158121591216012161121621216312164121651216612167121681216912170121711217212173121741217512176121771217812179121801218112182121831218412185121861218712188121891219012191121921219312194121951219612197121981219912200122011220212203122041220512206122071220812209122101221112212122131221412215122161221712218122191222012221122221222312224122251222612227122281222912230122311223212233122341223512236122371223812239122401224112242122431224412245122461224712248122491225012251122521225312254122551225612257122581225912260122611226212263122641226512266122671226812269122701227112272122731227412275122761227712278122791228012281122821228312284122851228612287122881228912290122911229212293122941229512296122971229812299123001230112302123031230412305123061230712308123091231012311123121231312314123151231612317123181231912320123211232212323123241232512326123271232812329123301233112332123331233412335123361233712338123391234012341123421234312344123451234612347123481234912350123511235212353123541235512356123571235812359123601236112362123631236412365123661236712368123691237012371123721237312374123751237612377123781237912380123811238212383123841238512386123871238812389123901239112392123931239412395123961239712398123991240012401124021240312404124051240612407124081240912410124111241212413124141241512416124171241812419124201242112422124231242412425124261242712428124291243012431124321243312434124351243612437124381243912440124411244212443124441244512446124471244812449124501245112452124531245412455124561245712458124591246012461124621246312464124651246612467124681246912470124711247212473124741247512476124771247812479124801248112482124831248412485124861248712488124891249012491124921249312494124951249612497124981249912500125011250212503125041250512506125071250812509125101251112512125131251412515125161251712518125191252012521125221252312524125251252612527125281252912530125311253212533125341253512536125371253812539125401254112542125431254412545125461254712548125491255012551125521255312554125551255612557125581255912560125611256212563125641256512566125671256812569125701257112572125731257412575125761257712578125791258012581125821258312584125851258612587125881258912590125911259212593125941259512596125971259812599126001260112602126031260412605126061260712608126091261012611126121261312614126151261612617126181261912620126211262212623126241262512626126271262812629126301263112632126331263412635126361263712638126391264012641126421264312644126451264612647126481264912650126511265212653126541265512656126571265812659126601266112662126631266412665126661266712668126691267012671126721267312674126751267612677126781267912680126811268212683126841268512686126871268812689126901269112692126931269412695126961269712698126991270012701127021270312704127051270612707127081270912710127111271212713127141271512716127171271812719127201272112722127231272412725127261272712728127291273012731127321273312734127351273612737127381273912740127411274212743127441274512746127471274812749127501275112752127531275412755127561275712758127591276012761127621276312764127651276612767127681276912770127711277212773127741277512776127771277812779127801278112782127831278412785127861278712788127891279012791127921279312794127951279612797127981279912800128011280212803128041280512806128071280812809128101281112812128131281412815128161281712818128191282012821128221282312824128251282612827128281282912830128311283212833128341283512836128371283812839128401284112842128431284412845128461284712848128491285012851128521285312854128551285612857128581285912860128611286212863128641286512866128671286812869128701287112872128731287412875128761287712878128791288012881128821288312884128851288612887128881288912890128911289212893128941289512896128971289812899129001290112902129031290412905129061290712908129091291012911129121291312914129151291612917129181291912920129211292212923129241292512926129271292812929129301293112932129331293412935129361293712938129391294012941129421294312944129451294612947129481294912950129511295212953129541295512956129571295812959129601296112962129631296412965129661296712968129691297012971129721297312974129751297612977129781297912980129811298212983129841298512986129871298812989129901299112992129931299412995129961299712998129991300013001130021300313004130051300613007130081300913010130111301213013130141301513016130171301813019130201302113022130231302413025130261302713028130291303013031130321303313034130351303613037130381303913040130411304213043130441304513046130471304813049130501305113052130531305413055130561305713058130591306013061130621306313064130651306613067130681306913070130711307213073130741307513076130771307813079130801308113082130831308413085130861308713088130891309013091130921309313094130951309613097130981309913100131011310213103131041310513106131071310813109131101311113112131131311413115131161311713118131191312013121131221312313124131251312613127131281312913130131311313213133131341313513136131371313813139131401314113142131431314413145131461314713148131491315013151131521315313154131551315613157131581315913160131611316213163131641316513166131671316813169131701317113172131731317413175131761317713178131791318013181131821318313184131851318613187131881318913190131911319213193131941319513196131971319813199132001320113202132031320413205132061320713208132091321013211132121321313214132151321613217132181321913220132211322213223132241322513226132271322813229132301323113232132331323413235132361323713238132391324013241132421324313244132451324613247132481324913250132511325213253132541325513256132571325813259132601326113262132631326413265132661326713268132691327013271132721327313274132751327613277132781327913280132811328213283132841328513286132871328813289132901329113292132931329413295132961329713298132991330013301133021330313304133051330613307133081330913310133111331213313133141331513316133171331813319133201332113322133231332413325133261332713328133291333013331133321333313334133351333613337133381333913340133411334213343133441334513346133471334813349133501335113352133531335413355133561335713358133591336013361133621336313364133651336613367133681336913370133711337213373133741337513376133771337813379133801338113382133831338413385133861338713388133891339013391133921339313394133951339613397133981339913400134011340213403134041340513406134071340813409134101341113412134131341413415134161341713418134191342013421134221342313424134251342613427134281342913430134311343213433134341343513436134371343813439134401344113442134431344413445134461344713448134491345013451134521345313454134551345613457134581345913460134611346213463134641346513466134671346813469134701347113472134731347413475134761347713478134791348013481134821348313484134851348613487134881348913490134911349213493134941349513496134971349813499135001350113502135031350413505135061350713508135091351013511135121351313514135151351613517135181351913520135211352213523135241352513526135271352813529135301353113532135331353413535135361353713538135391354013541135421354313544135451354613547135481354913550135511355213553135541355513556135571355813559135601356113562135631356413565135661356713568135691357013571135721357313574135751357613577135781357913580135811358213583135841358513586135871358813589135901359113592135931359413595135961359713598135991360013601136021360313604136051360613607136081360913610136111361213613136141361513616136171361813619136201362113622136231362413625136261362713628136291363013631136321363313634136351363613637136381363913640136411364213643136441364513646136471364813649136501365113652136531365413655136561365713658136591366013661136621366313664136651366613667136681366913670136711367213673136741367513676136771367813679136801368113682136831368413685136861368713688136891369013691136921369313694136951369613697136981369913700137011370213703137041370513706137071370813709137101371113712137131371413715137161371713718137191372013721137221372313724137251372613727137281372913730137311373213733137341373513736137371373813739137401374113742137431374413745137461374713748137491375013751137521375313754137551375613757137581375913760137611376213763137641376513766137671376813769137701377113772137731377413775137761377713778137791378013781137821378313784137851378613787137881378913790137911379213793137941379513796137971379813799138001380113802138031380413805138061380713808138091381013811138121381313814138151381613817138181381913820138211382213823138241382513826138271382813829138301383113832138331383413835138361383713838138391384013841138421384313844138451384613847138481384913850138511385213853138541385513856138571385813859138601386113862138631386413865138661386713868138691387013871138721387313874138751387613877138781387913880138811388213883138841388513886138871388813889138901389113892138931389413895138961389713898138991390013901139021390313904139051390613907139081390913910139111391213913139141391513916139171391813919139201392113922139231392413925139261392713928139291393013931139321393313934139351393613937139381393913940139411394213943139441394513946139471394813949139501395113952139531395413955139561395713958139591396013961139621396313964139651396613967139681396913970139711397213973139741397513976139771397813979139801398113982139831398413985139861398713988139891399013991139921399313994139951399613997139981399914000140011400214003140041400514006140071400814009140101401114012140131401414015140161401714018140191402014021140221402314024140251402614027140281402914030140311403214033140341403514036140371403814039140401404114042140431404414045140461404714048140491405014051140521405314054140551405614057140581405914060140611406214063140641406514066140671406814069140701407114072140731407414075140761407714078140791408014081140821408314084140851408614087140881408914090140911409214093140941409514096140971409814099141001410114102141031410414105141061410714108141091411014111141121411314114141151411614117141181411914120141211412214123141241412514126141271412814129141301413114132141331413414135141361413714138141391414014141141421414314144141451414614147141481414914150141511415214153141541415514156141571415814159141601416114162141631416414165141661416714168141691417014171141721417314174141751417614177141781417914180141811418214183141841418514186141871418814189141901419114192141931419414195141961419714198141991420014201142021420314204142051420614207142081420914210142111421214213142141421514216142171421814219142201422114222142231422414225142261422714228142291423014231142321423314234142351423614237142381423914240142411424214243142441424514246142471424814249142501425114252142531425414255142561425714258142591426014261142621426314264142651426614267142681426914270142711427214273142741427514276142771427814279142801428114282142831428414285142861428714288142891429014291142921429314294142951429614297142981429914300143011430214303143041430514306143071430814309143101431114312143131431414315143161431714318143191432014321143221432314324143251432614327143281432914330143311433214333143341433514336143371433814339143401434114342143431434414345143461434714348143491435014351143521435314354143551435614357143581435914360143611436214363143641436514366143671436814369143701437114372143731437414375143761437714378143791438014381143821438314384143851438614387143881438914390143911439214393143941439514396143971439814399144001440114402144031440414405144061440714408144091441014411144121441314414144151441614417144181441914420144211442214423144241442514426144271442814429144301443114432144331443414435144361443714438144391444014441144421444314444144451444614447144481444914450144511445214453144541445514456144571445814459144601446114462144631446414465144661446714468144691447014471144721447314474144751447614477144781447914480144811448214483144841448514486144871448814489144901449114492144931449414495144961449714498144991450014501145021450314504145051450614507145081450914510145111451214513145141451514516145171451814519145201452114522145231452414525145261452714528145291453014531145321453314534145351453614537145381453914540145411454214543145441454514546145471454814549145501455114552145531455414555145561455714558145591456014561145621456314564145651456614567145681456914570145711457214573145741457514576145771457814579145801458114582145831458414585145861458714588145891459014591145921459314594145951459614597145981459914600146011460214603146041460514606146071460814609146101461114612146131461414615146161461714618146191462014621146221462314624146251462614627146281462914630146311463214633146341463514636146371463814639146401464114642146431464414645146461464714648146491465014651146521465314654146551465614657146581465914660146611466214663146641466514666146671466814669146701467114672146731467414675146761467714678146791468014681146821468314684146851468614687146881468914690146911469214693146941469514696146971469814699147001470114702147031470414705147061470714708147091471014711147121471314714147151471614717147181471914720147211472214723147241472514726147271472814729147301473114732147331473414735147361473714738147391474014741147421474314744147451474614747147481474914750147511475214753147541475514756147571475814759147601476114762147631476414765147661476714768147691477014771147721477314774147751477614777147781477914780147811478214783147841478514786147871478814789147901479114792147931479414795147961479714798147991480014801148021480314804148051480614807148081480914810148111481214813148141481514816148171481814819148201482114822148231482414825148261482714828148291483014831148321483314834148351483614837148381483914840148411484214843148441484514846148471484814849148501485114852148531485414855148561485714858148591486014861148621486314864148651486614867148681486914870148711487214873148741487514876148771487814879148801488114882148831488414885148861488714888148891489014891148921489314894148951489614897148981489914900149011490214903149041490514906149071490814909149101491114912149131491414915149161491714918149191492014921149221492314924149251492614927149281492914930149311493214933149341493514936149371493814939149401494114942149431494414945149461494714948149491495014951149521495314954149551495614957149581495914960149611496214963149641496514966149671496814969149701497114972149731497414975149761497714978149791498014981149821498314984149851498614987149881498914990149911499214993149941499514996149971499814999150001500115002150031500415005150061500715008150091501015011150121501315014150151501615017150181501915020150211502215023150241502515026150271502815029150301503115032150331503415035150361503715038150391504015041150421504315044150451504615047150481504915050150511505215053150541505515056150571505815059150601506115062150631506415065150661506715068150691507015071150721507315074150751507615077150781507915080150811508215083150841508515086150871508815089150901509115092150931509415095150961509715098150991510015101151021510315104151051510615107151081510915110151111511215113151141511515116151171511815119151201512115122151231512415125151261512715128151291513015131151321513315134151351513615137151381513915140151411514215143151441514515146151471514815149151501515115152151531515415155151561515715158151591516015161151621516315164151651516615167151681516915170151711517215173151741517515176151771517815179151801518115182151831518415185151861518715188151891519015191151921519315194151951519615197151981519915200152011520215203152041520515206152071520815209152101521115212152131521415215152161521715218152191522015221152221522315224152251522615227152281522915230152311523215233152341523515236152371523815239152401524115242152431524415245152461524715248152491525015251152521525315254152551525615257152581525915260152611526215263152641526515266152671526815269152701527115272152731527415275152761527715278152791528015281152821528315284152851528615287152881528915290152911529215293152941529515296152971529815299153001530115302153031530415305153061530715308153091531015311153121531315314153151531615317153181531915320153211532215323153241532515326153271532815329153301533115332153331533415335153361533715338153391534015341153421534315344153451534615347153481534915350153511535215353153541535515356153571535815359153601536115362153631536415365153661536715368153691537015371153721537315374153751537615377153781537915380153811538215383153841538515386153871538815389153901539115392153931539415395153961539715398153991540015401154021540315404154051540615407154081540915410154111541215413154141541515416154171541815419154201542115422154231542415425154261542715428154291543015431154321543315434154351543615437154381543915440154411544215443154441544515446154471544815449154501545115452154531545415455154561545715458154591546015461154621546315464154651546615467154681546915470154711547215473154741547515476154771547815479154801548115482154831548415485154861548715488154891549015491154921549315494154951549615497154981549915500155011550215503155041550515506155071550815509155101551115512155131551415515155161551715518155191552015521155221552315524155251552615527155281552915530155311553215533155341553515536155371553815539155401554115542155431554415545155461554715548155491555015551155521555315554155551555615557155581555915560155611556215563155641556515566155671556815569155701557115572155731557415575155761557715578155791558015581155821558315584155851558615587155881558915590155911559215593155941559515596155971559815599156001560115602156031560415605156061560715608156091561015611156121561315614156151561615617156181561915620156211562215623156241562515626156271562815629156301563115632156331563415635156361563715638156391564015641156421564315644156451564615647156481564915650156511565215653156541565515656156571565815659156601566115662156631566415665156661566715668156691567015671156721567315674156751567615677156781567915680156811568215683156841568515686156871568815689156901569115692156931569415695156961569715698156991570015701157021570315704157051570615707157081570915710157111571215713157141571515716157171571815719157201572115722157231572415725157261572715728157291573015731157321573315734157351573615737157381573915740157411574215743157441574515746157471574815749157501575115752157531575415755157561575715758157591576015761157621576315764157651576615767157681576915770157711577215773157741577515776157771577815779157801578115782157831578415785157861578715788157891579015791157921579315794157951579615797157981579915800158011580215803158041580515806158071580815809158101581115812158131581415815158161581715818158191582015821158221582315824158251582615827158281582915830158311583215833158341583515836158371583815839158401584115842158431584415845158461584715848158491585015851158521585315854158551585615857158581585915860158611586215863158641586515866158671586815869158701587115872158731587415875158761587715878158791588015881158821588315884158851588615887158881588915890158911589215893158941589515896158971589815899159001590115902159031590415905159061590715908159091591015911159121591315914159151591615917159181591915920159211592215923159241592515926159271592815929159301593115932159331593415935159361593715938159391594015941159421594315944159451594615947159481594915950159511595215953159541595515956159571595815959159601596115962159631596415965159661596715968159691597015971159721597315974159751597615977159781597915980159811598215983159841598515986159871598815989159901599115992159931599415995159961599715998159991600016001160021600316004160051600616007160081600916010160111601216013160141601516016160171601816019160201602116022160231602416025160261602716028160291603016031160321603316034160351603616037160381603916040160411604216043160441604516046160471604816049160501605116052160531605416055160561605716058160591606016061160621606316064160651606616067160681606916070160711607216073160741607516076160771607816079160801608116082160831608416085160861608716088160891609016091160921609316094160951609616097160981609916100161011610216103161041610516106161071610816109161101611116112161131611416115161161611716118161191612016121161221612316124161251612616127161281612916130161311613216133161341613516136161371613816139161401614116142161431614416145161461614716148161491615016151161521615316154161551615616157161581615916160161611616216163161641616516166161671616816169161701617116172161731617416175161761617716178161791618016181161821618316184161851618616187161881618916190161911619216193161941619516196161971619816199162001620116202162031620416205162061620716208162091621016211162121621316214162151621616217162181621916220162211622216223162241622516226162271622816229162301623116232162331623416235162361623716238162391624016241162421624316244162451624616247162481624916250162511625216253162541625516256162571625816259162601626116262162631626416265162661626716268162691627016271162721627316274162751627616277162781627916280162811628216283162841628516286162871628816289162901629116292162931629416295162961629716298162991630016301163021630316304163051630616307163081630916310163111631216313163141631516316163171631816319163201632116322163231632416325163261632716328163291633016331163321633316334163351633616337163381633916340163411634216343163441634516346163471634816349163501635116352163531635416355163561635716358163591636016361163621636316364163651636616367163681636916370163711637216373163741637516376163771637816379163801638116382163831638416385163861638716388163891639016391163921639316394163951639616397163981639916400164011640216403164041640516406164071640816409164101641116412164131641416415164161641716418164191642016421164221642316424164251642616427164281642916430164311643216433164341643516436164371643816439164401644116442164431644416445164461644716448164491645016451164521645316454164551645616457164581645916460164611646216463164641646516466164671646816469164701647116472164731647416475164761647716478164791648016481164821648316484164851648616487164881648916490164911649216493164941649516496164971649816499165001650116502165031650416505165061650716508165091651016511165121651316514165151651616517165181651916520165211652216523165241652516526165271652816529165301653116532165331653416535165361653716538165391654016541165421654316544165451654616547165481654916550165511655216553165541655516556165571655816559165601656116562165631656416565165661656716568165691657016571165721657316574165751657616577165781657916580165811658216583165841658516586165871658816589165901659116592165931659416595165961659716598165991660016601166021660316604166051660616607166081660916610166111661216613166141661516616166171661816619166201662116622166231662416625166261662716628166291663016631166321663316634166351663616637166381663916640166411664216643166441664516646166471664816649166501665116652166531665416655166561665716658166591666016661166621666316664166651666616667166681666916670166711667216673166741667516676166771667816679166801668116682166831668416685166861668716688166891669016691166921669316694166951669616697166981669916700167011670216703167041670516706167071670816709167101671116712167131671416715167161671716718167191672016721167221672316724167251672616727167281672916730167311673216733167341673516736167371673816739167401674116742167431674416745167461674716748167491675016751167521675316754167551675616757167581675916760167611676216763167641676516766167671676816769167701677116772167731677416775167761677716778167791678016781167821678316784167851678616787167881678916790167911679216793167941679516796167971679816799168001680116802168031680416805168061680716808168091681016811168121681316814168151681616817168181681916820168211682216823168241682516826168271682816829168301683116832168331683416835168361683716838168391684016841168421684316844168451684616847168481684916850168511685216853168541685516856168571685816859168601686116862168631686416865168661686716868168691687016871168721687316874168751687616877168781687916880168811688216883168841688516886168871688816889168901689116892168931689416895168961689716898168991690016901169021690316904169051690616907169081690916910169111691216913169141691516916169171691816919169201692116922169231692416925169261692716928169291693016931169321693316934169351693616937169381693916940169411694216943169441694516946169471694816949169501695116952169531695416955169561695716958169591696016961169621696316964169651696616967169681696916970169711697216973169741697516976169771697816979169801698116982169831698416985169861698716988169891699016991169921699316994169951699616997169981699917000170011700217003170041700517006170071700817009170101701117012170131701417015170161701717018170191702017021170221702317024170251702617027170281702917030170311703217033170341703517036170371703817039170401704117042170431704417045170461704717048170491705017051170521705317054170551705617057170581705917060170611706217063170641706517066170671706817069170701707117072170731707417075170761707717078170791708017081170821708317084170851708617087170881708917090170911709217093170941709517096170971709817099171001710117102171031710417105171061710717108171091711017111171121711317114171151711617117171181711917120171211712217123171241712517126171271712817129171301713117132171331713417135171361713717138171391714017141171421714317144171451714617147171481714917150171511715217153171541715517156171571715817159171601716117162171631716417165171661716717168171691717017171171721717317174171751717617177171781717917180171811718217183171841718517186171871718817189171901719117192171931719417195171961719717198171991720017201172021720317204172051720617207172081720917210172111721217213172141721517216172171721817219172201722117222172231722417225172261722717228172291723017231172321723317234172351723617237172381723917240172411724217243172441724517246172471724817249172501725117252172531725417255172561725717258172591726017261172621726317264172651726617267172681726917270172711727217273172741727517276172771727817279172801728117282172831728417285172861728717288172891729017291172921729317294172951729617297172981729917300173011730217303173041730517306173071730817309173101731117312173131731417315173161731717318173191732017321173221732317324173251732617327173281732917330173311733217333173341733517336173371733817339173401734117342173431734417345173461734717348173491735017351173521735317354173551735617357173581735917360173611736217363173641736517366173671736817369173701737117372173731737417375173761737717378173791738017381173821738317384173851738617387173881738917390173911739217393173941739517396173971739817399174001740117402174031740417405174061740717408174091741017411174121741317414174151741617417174181741917420174211742217423174241742517426174271742817429174301743117432174331743417435174361743717438174391744017441174421744317444174451744617447174481744917450174511745217453174541745517456174571745817459174601746117462174631746417465174661746717468174691747017471174721747317474174751747617477174781747917480174811748217483174841748517486174871748817489174901749117492174931749417495174961749717498174991750017501175021750317504175051750617507175081750917510175111751217513175141751517516175171751817519175201752117522175231752417525175261752717528175291753017531175321753317534175351753617537175381753917540175411754217543175441754517546175471754817549175501755117552175531755417555175561755717558175591756017561175621756317564175651756617567175681756917570175711757217573175741757517576175771757817579175801758117582175831758417585175861758717588175891759017591175921759317594175951759617597175981759917600176011760217603176041760517606176071760817609176101761117612176131761417615176161761717618176191762017621176221762317624176251762617627176281762917630176311763217633176341763517636176371763817639176401764117642176431764417645176461764717648176491765017651176521765317654176551765617657176581765917660176611766217663176641766517666176671766817669176701767117672176731767417675176761767717678176791768017681176821768317684176851768617687
  1. (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
  2. // shim for using process in browser
  3. var process = module.exports = {};
  4. // cached from whatever global is present so that test runners that stub it
  5. // don't break things. But we need to wrap it in a try catch in case it is
  6. // wrapped in strict mode code which doesn't define any globals. It's inside a
  7. // function because try/catches deoptimize in certain engines.
  8. var cachedSetTimeout;
  9. var cachedClearTimeout;
  10. function defaultSetTimout() {
  11. throw new Error('setTimeout has not been defined');
  12. }
  13. function defaultClearTimeout () {
  14. throw new Error('clearTimeout has not been defined');
  15. }
  16. (function () {
  17. try {
  18. if (typeof setTimeout === 'function') {
  19. cachedSetTimeout = setTimeout;
  20. } else {
  21. cachedSetTimeout = defaultSetTimout;
  22. }
  23. } catch (e) {
  24. cachedSetTimeout = defaultSetTimout;
  25. }
  26. try {
  27. if (typeof clearTimeout === 'function') {
  28. cachedClearTimeout = clearTimeout;
  29. } else {
  30. cachedClearTimeout = defaultClearTimeout;
  31. }
  32. } catch (e) {
  33. cachedClearTimeout = defaultClearTimeout;
  34. }
  35. } ())
  36. function runTimeout(fun) {
  37. if (cachedSetTimeout === setTimeout) {
  38. //normal enviroments in sane situations
  39. return setTimeout(fun, 0);
  40. }
  41. // if setTimeout wasn't available but was latter defined
  42. if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {
  43. cachedSetTimeout = setTimeout;
  44. return setTimeout(fun, 0);
  45. }
  46. try {
  47. // when when somebody has screwed with setTimeout but no I.E. maddness
  48. return cachedSetTimeout(fun, 0);
  49. } catch(e){
  50. try {
  51. // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
  52. return cachedSetTimeout.call(null, fun, 0);
  53. } catch(e){
  54. // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error
  55. return cachedSetTimeout.call(this, fun, 0);
  56. }
  57. }
  58. }
  59. function runClearTimeout(marker) {
  60. if (cachedClearTimeout === clearTimeout) {
  61. //normal enviroments in sane situations
  62. return clearTimeout(marker);
  63. }
  64. // if clearTimeout wasn't available but was latter defined
  65. if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {
  66. cachedClearTimeout = clearTimeout;
  67. return clearTimeout(marker);
  68. }
  69. try {
  70. // when when somebody has screwed with setTimeout but no I.E. maddness
  71. return cachedClearTimeout(marker);
  72. } catch (e){
  73. try {
  74. // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
  75. return cachedClearTimeout.call(null, marker);
  76. } catch (e){
  77. // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.
  78. // Some versions of I.E. have different rules for clearTimeout vs setTimeout
  79. return cachedClearTimeout.call(this, marker);
  80. }
  81. }
  82. }
  83. var queue = [];
  84. var draining = false;
  85. var currentQueue;
  86. var queueIndex = -1;
  87. function cleanUpNextTick() {
  88. if (!draining || !currentQueue) {
  89. return;
  90. }
  91. draining = false;
  92. if (currentQueue.length) {
  93. queue = currentQueue.concat(queue);
  94. } else {
  95. queueIndex = -1;
  96. }
  97. if (queue.length) {
  98. drainQueue();
  99. }
  100. }
  101. function drainQueue() {
  102. if (draining) {
  103. return;
  104. }
  105. var timeout = runTimeout(cleanUpNextTick);
  106. draining = true;
  107. var len = queue.length;
  108. while(len) {
  109. currentQueue = queue;
  110. queue = [];
  111. while (++queueIndex < len) {
  112. if (currentQueue) {
  113. currentQueue[queueIndex].run();
  114. }
  115. }
  116. queueIndex = -1;
  117. len = queue.length;
  118. }
  119. currentQueue = null;
  120. draining = false;
  121. runClearTimeout(timeout);
  122. }
  123. process.nextTick = function (fun) {
  124. var args = new Array(arguments.length - 1);
  125. if (arguments.length > 1) {
  126. for (var i = 1; i < arguments.length; i++) {
  127. args[i - 1] = arguments[i];
  128. }
  129. }
  130. queue.push(new Item(fun, args));
  131. if (queue.length === 1 && !draining) {
  132. runTimeout(drainQueue);
  133. }
  134. };
  135. // v8 likes predictible objects
  136. function Item(fun, array) {
  137. this.fun = fun;
  138. this.array = array;
  139. }
  140. Item.prototype.run = function () {
  141. this.fun.apply(null, this.array);
  142. };
  143. process.title = 'browser';
  144. process.browser = true;
  145. process.env = {};
  146. process.argv = [];
  147. process.version = ''; // empty string to avoid regexp issues
  148. process.versions = {};
  149. function noop() {}
  150. process.on = noop;
  151. process.addListener = noop;
  152. process.once = noop;
  153. process.off = noop;
  154. process.removeListener = noop;
  155. process.removeAllListeners = noop;
  156. process.emit = noop;
  157. process.prependListener = noop;
  158. process.prependOnceListener = noop;
  159. process.listeners = function (name) { return [] }
  160. process.binding = function (name) {
  161. throw new Error('process.binding is not supported');
  162. };
  163. process.cwd = function () { return '/' };
  164. process.chdir = function (dir) {
  165. throw new Error('process.chdir is not supported');
  166. };
  167. process.umask = function() { return 0; };
  168. },{}],2:[function(require,module,exports){
  169. if (typeof Object.create === 'function') {
  170. // implementation from standard node.js 'util' module
  171. module.exports = function inherits(ctor, superCtor) {
  172. ctor.super_ = superCtor
  173. ctor.prototype = Object.create(superCtor.prototype, {
  174. constructor: {
  175. value: ctor,
  176. enumerable: false,
  177. writable: true,
  178. configurable: true
  179. }
  180. });
  181. };
  182. } else {
  183. // old school shim for old browsers
  184. module.exports = function inherits(ctor, superCtor) {
  185. ctor.super_ = superCtor
  186. var TempCtor = function () {}
  187. TempCtor.prototype = superCtor.prototype
  188. ctor.prototype = new TempCtor()
  189. ctor.prototype.constructor = ctor
  190. }
  191. }
  192. },{}],3:[function(require,module,exports){
  193. module.exports = function isBuffer(arg) {
  194. return arg && typeof arg === 'object'
  195. && typeof arg.copy === 'function'
  196. && typeof arg.fill === 'function'
  197. && typeof arg.readUInt8 === 'function';
  198. }
  199. },{}],4:[function(require,module,exports){
  200. (function (process,global){
  201. // Copyright Joyent, Inc. and other Node contributors.
  202. //
  203. // Permission is hereby granted, free of charge, to any person obtaining a
  204. // copy of this software and associated documentation files (the
  205. // "Software"), to deal in the Software without restriction, including
  206. // without limitation the rights to use, copy, modify, merge, publish,
  207. // distribute, sublicense, and/or sell copies of the Software, and to permit
  208. // persons to whom the Software is furnished to do so, subject to the
  209. // following conditions:
  210. //
  211. // The above copyright notice and this permission notice shall be included
  212. // in all copies or substantial portions of the Software.
  213. //
  214. // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
  215. // OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  216. // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
  217. // NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
  218. // DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
  219. // OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
  220. // USE OR OTHER DEALINGS IN THE SOFTWARE.
  221. var formatRegExp = /%[sdj%]/g;
  222. exports.format = function(f) {
  223. if (!isString(f)) {
  224. var objects = [];
  225. for (var i = 0; i < arguments.length; i++) {
  226. objects.push(inspect(arguments[i]));
  227. }
  228. return objects.join(' ');
  229. }
  230. var i = 1;
  231. var args = arguments;
  232. var len = args.length;
  233. var str = String(f).replace(formatRegExp, function(x) {
  234. if (x === '%%') return '%';
  235. if (i >= len) return x;
  236. switch (x) {
  237. case '%s': return String(args[i++]);
  238. case '%d': return Number(args[i++]);
  239. case '%j':
  240. try {
  241. return JSON.stringify(args[i++]);
  242. } catch (_) {
  243. return '[Circular]';
  244. }
  245. default:
  246. return x;
  247. }
  248. });
  249. for (var x = args[i]; i < len; x = args[++i]) {
  250. if (isNull(x) || !isObject(x)) {
  251. str += ' ' + x;
  252. } else {
  253. str += ' ' + inspect(x);
  254. }
  255. }
  256. return str;
  257. };
  258. // Mark that a method should not be used.
  259. // Returns a modified function which warns once by default.
  260. // If --no-deprecation is set, then it is a no-op.
  261. exports.deprecate = function(fn, msg) {
  262. // Allow for deprecating things in the process of starting up.
  263. if (isUndefined(global.process)) {
  264. return function() {
  265. return exports.deprecate(fn, msg).apply(this, arguments);
  266. };
  267. }
  268. if (process.noDeprecation === true) {
  269. return fn;
  270. }
  271. var warned = false;
  272. function deprecated() {
  273. if (!warned) {
  274. if (process.throwDeprecation) {
  275. throw new Error(msg);
  276. } else if (process.traceDeprecation) {
  277. console.trace(msg);
  278. } else {
  279. console.error(msg);
  280. }
  281. warned = true;
  282. }
  283. return fn.apply(this, arguments);
  284. }
  285. return deprecated;
  286. };
  287. var debugs = {};
  288. var debugEnviron;
  289. exports.debuglog = function(set) {
  290. if (isUndefined(debugEnviron))
  291. debugEnviron = process.env.NODE_DEBUG || '';
  292. set = set.toUpperCase();
  293. if (!debugs[set]) {
  294. if (new RegExp('\\b' + set + '\\b', 'i').test(debugEnviron)) {
  295. var pid = process.pid;
  296. debugs[set] = function() {
  297. var msg = exports.format.apply(exports, arguments);
  298. console.error('%s %d: %s', set, pid, msg);
  299. };
  300. } else {
  301. debugs[set] = function() {};
  302. }
  303. }
  304. return debugs[set];
  305. };
  306. /**
  307. * Echos the value of a value. Trys to print the value out
  308. * in the best way possible given the different types.
  309. *
  310. * @param {Object} obj The object to print out.
  311. * @param {Object} opts Optional options object that alters the output.
  312. */
  313. /* legacy: obj, showHidden, depth, colors*/
  314. function inspect(obj, opts) {
  315. // default options
  316. var ctx = {
  317. seen: [],
  318. stylize: stylizeNoColor
  319. };
  320. // legacy...
  321. if (arguments.length >= 3) ctx.depth = arguments[2];
  322. if (arguments.length >= 4) ctx.colors = arguments[3];
  323. if (isBoolean(opts)) {
  324. // legacy...
  325. ctx.showHidden = opts;
  326. } else if (opts) {
  327. // got an "options" object
  328. exports._extend(ctx, opts);
  329. }
  330. // set default options
  331. if (isUndefined(ctx.showHidden)) ctx.showHidden = false;
  332. if (isUndefined(ctx.depth)) ctx.depth = 2;
  333. if (isUndefined(ctx.colors)) ctx.colors = false;
  334. if (isUndefined(ctx.customInspect)) ctx.customInspect = true;
  335. if (ctx.colors) ctx.stylize = stylizeWithColor;
  336. return formatValue(ctx, obj, ctx.depth);
  337. }
  338. exports.inspect = inspect;
  339. // http://en.wikipedia.org/wiki/ANSI_escape_code#graphics
  340. inspect.colors = {
  341. 'bold' : [1, 22],
  342. 'italic' : [3, 23],
  343. 'underline' : [4, 24],
  344. 'inverse' : [7, 27],
  345. 'white' : [37, 39],
  346. 'grey' : [90, 39],
  347. 'black' : [30, 39],
  348. 'blue' : [34, 39],
  349. 'cyan' : [36, 39],
  350. 'green' : [32, 39],
  351. 'magenta' : [35, 39],
  352. 'red' : [31, 39],
  353. 'yellow' : [33, 39]
  354. };
  355. // Don't use 'blue' not visible on cmd.exe
  356. inspect.styles = {
  357. 'special': 'cyan',
  358. 'number': 'yellow',
  359. 'boolean': 'yellow',
  360. 'undefined': 'grey',
  361. 'null': 'bold',
  362. 'string': 'green',
  363. 'date': 'magenta',
  364. // "name": intentionally not styling
  365. 'regexp': 'red'
  366. };
  367. function stylizeWithColor(str, styleType) {
  368. var style = inspect.styles[styleType];
  369. if (style) {
  370. return '\u001b[' + inspect.colors[style][0] + 'm' + str +
  371. '\u001b[' + inspect.colors[style][1] + 'm';
  372. } else {
  373. return str;
  374. }
  375. }
  376. function stylizeNoColor(str, styleType) {
  377. return str;
  378. }
  379. function arrayToHash(array) {
  380. var hash = {};
  381. array.forEach(function(val, idx) {
  382. hash[val] = true;
  383. });
  384. return hash;
  385. }
  386. function formatValue(ctx, value, recurseTimes) {
  387. // Provide a hook for user-specified inspect functions.
  388. // Check that value is an object with an inspect function on it
  389. if (ctx.customInspect &&
  390. value &&
  391. isFunction(value.inspect) &&
  392. // Filter out the util module, it's inspect function is special
  393. value.inspect !== exports.inspect &&
  394. // Also filter out any prototype objects using the circular check.
  395. !(value.constructor && value.constructor.prototype === value)) {
  396. var ret = value.inspect(recurseTimes, ctx);
  397. if (!isString(ret)) {
  398. ret = formatValue(ctx, ret, recurseTimes);
  399. }
  400. return ret;
  401. }
  402. // Primitive types cannot have properties
  403. var primitive = formatPrimitive(ctx, value);
  404. if (primitive) {
  405. return primitive;
  406. }
  407. // Look up the keys of the object.
  408. var keys = Object.keys(value);
  409. var visibleKeys = arrayToHash(keys);
  410. if (ctx.showHidden) {
  411. keys = Object.getOwnPropertyNames(value);
  412. }
  413. // IE doesn't make error fields non-enumerable
  414. // http://msdn.microsoft.com/en-us/library/ie/dww52sbt(v=vs.94).aspx
  415. if (isError(value)
  416. && (keys.indexOf('message') >= 0 || keys.indexOf('description') >= 0)) {
  417. return formatError(value);
  418. }
  419. // Some type of object without properties can be shortcutted.
  420. if (keys.length === 0) {
  421. if (isFunction(value)) {
  422. var name = value.name ? ': ' + value.name : '';
  423. return ctx.stylize('[Function' + name + ']', 'special');
  424. }
  425. if (isRegExp(value)) {
  426. return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');
  427. }
  428. if (isDate(value)) {
  429. return ctx.stylize(Date.prototype.toString.call(value), 'date');
  430. }
  431. if (isError(value)) {
  432. return formatError(value);
  433. }
  434. }
  435. var base = '', array = false, braces = ['{', '}'];
  436. // Make Array say that they are Array
  437. if (isArray(value)) {
  438. array = true;
  439. braces = ['[', ']'];
  440. }
  441. // Make functions say that they are functions
  442. if (isFunction(value)) {
  443. var n = value.name ? ': ' + value.name : '';
  444. base = ' [Function' + n + ']';
  445. }
  446. // Make RegExps say that they are RegExps
  447. if (isRegExp(value)) {
  448. base = ' ' + RegExp.prototype.toString.call(value);
  449. }
  450. // Make dates with properties first say the date
  451. if (isDate(value)) {
  452. base = ' ' + Date.prototype.toUTCString.call(value);
  453. }
  454. // Make error with message first say the error
  455. if (isError(value)) {
  456. base = ' ' + formatError(value);
  457. }
  458. if (keys.length === 0 && (!array || value.length == 0)) {
  459. return braces[0] + base + braces[1];
  460. }
  461. if (recurseTimes < 0) {
  462. if (isRegExp(value)) {
  463. return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');
  464. } else {
  465. return ctx.stylize('[Object]', 'special');
  466. }
  467. }
  468. ctx.seen.push(value);
  469. var output;
  470. if (array) {
  471. output = formatArray(ctx, value, recurseTimes, visibleKeys, keys);
  472. } else {
  473. output = keys.map(function(key) {
  474. return formatProperty(ctx, value, recurseTimes, visibleKeys, key, array);
  475. });
  476. }
  477. ctx.seen.pop();
  478. return reduceToSingleString(output, base, braces);
  479. }
  480. function formatPrimitive(ctx, value) {
  481. if (isUndefined(value))
  482. return ctx.stylize('undefined', 'undefined');
  483. if (isString(value)) {
  484. var simple = '\'' + JSON.stringify(value).replace(/^"|"$/g, '')
  485. .replace(/'/g, "\\'")
  486. .replace(/\\"/g, '"') + '\'';
  487. return ctx.stylize(simple, 'string');
  488. }
  489. if (isNumber(value))
  490. return ctx.stylize('' + value, 'number');
  491. if (isBoolean(value))
  492. return ctx.stylize('' + value, 'boolean');
  493. // For some reason typeof null is "object", so special case here.
  494. if (isNull(value))
  495. return ctx.stylize('null', 'null');
  496. }
  497. function formatError(value) {
  498. return '[' + Error.prototype.toString.call(value) + ']';
  499. }
  500. function formatArray(ctx, value, recurseTimes, visibleKeys, keys) {
  501. var output = [];
  502. for (var i = 0, l = value.length; i < l; ++i) {
  503. if (hasOwnProperty(value, String(i))) {
  504. output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,
  505. String(i), true));
  506. } else {
  507. output.push('');
  508. }
  509. }
  510. keys.forEach(function(key) {
  511. if (!key.match(/^\d+$/)) {
  512. output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,
  513. key, true));
  514. }
  515. });
  516. return output;
  517. }
  518. function formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) {
  519. var name, str, desc;
  520. desc = Object.getOwnPropertyDescriptor(value, key) || { value: value[key] };
  521. if (desc.get) {
  522. if (desc.set) {
  523. str = ctx.stylize('[Getter/Setter]', 'special');
  524. } else {
  525. str = ctx.stylize('[Getter]', 'special');
  526. }
  527. } else {
  528. if (desc.set) {
  529. str = ctx.stylize('[Setter]', 'special');
  530. }
  531. }
  532. if (!hasOwnProperty(visibleKeys, key)) {
  533. name = '[' + key + ']';
  534. }
  535. if (!str) {
  536. if (ctx.seen.indexOf(desc.value) < 0) {
  537. if (isNull(recurseTimes)) {
  538. str = formatValue(ctx, desc.value, null);
  539. } else {
  540. str = formatValue(ctx, desc.value, recurseTimes - 1);
  541. }
  542. if (str.indexOf('\n') > -1) {
  543. if (array) {
  544. str = str.split('\n').map(function(line) {
  545. return ' ' + line;
  546. }).join('\n').substr(2);
  547. } else {
  548. str = '\n' + str.split('\n').map(function(line) {
  549. return ' ' + line;
  550. }).join('\n');
  551. }
  552. }
  553. } else {
  554. str = ctx.stylize('[Circular]', 'special');
  555. }
  556. }
  557. if (isUndefined(name)) {
  558. if (array && key.match(/^\d+$/)) {
  559. return str;
  560. }
  561. name = JSON.stringify('' + key);
  562. if (name.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)) {
  563. name = name.substr(1, name.length - 2);
  564. name = ctx.stylize(name, 'name');
  565. } else {
  566. name = name.replace(/'/g, "\\'")
  567. .replace(/\\"/g, '"')
  568. .replace(/(^"|"$)/g, "'");
  569. name = ctx.stylize(name, 'string');
  570. }
  571. }
  572. return name + ': ' + str;
  573. }
  574. function reduceToSingleString(output, base, braces) {
  575. var numLinesEst = 0;
  576. var length = output.reduce(function(prev, cur) {
  577. numLinesEst++;
  578. if (cur.indexOf('\n') >= 0) numLinesEst++;
  579. return prev + cur.replace(/\u001b\[\d\d?m/g, '').length + 1;
  580. }, 0);
  581. if (length > 60) {
  582. return braces[0] +
  583. (base === '' ? '' : base + '\n ') +
  584. ' ' +
  585. output.join(',\n ') +
  586. ' ' +
  587. braces[1];
  588. }
  589. return braces[0] + base + ' ' + output.join(', ') + ' ' + braces[1];
  590. }
  591. // NOTE: These type checking functions intentionally don't use `instanceof`
  592. // because it is fragile and can be easily faked with `Object.create()`.
  593. function isArray(ar) {
  594. return Array.isArray(ar);
  595. }
  596. exports.isArray = isArray;
  597. function isBoolean(arg) {
  598. return typeof arg === 'boolean';
  599. }
  600. exports.isBoolean = isBoolean;
  601. function isNull(arg) {
  602. return arg === null;
  603. }
  604. exports.isNull = isNull;
  605. function isNullOrUndefined(arg) {
  606. return arg == null;
  607. }
  608. exports.isNullOrUndefined = isNullOrUndefined;
  609. function isNumber(arg) {
  610. return typeof arg === 'number';
  611. }
  612. exports.isNumber = isNumber;
  613. function isString(arg) {
  614. return typeof arg === 'string';
  615. }
  616. exports.isString = isString;
  617. function isSymbol(arg) {
  618. return typeof arg === 'symbol';
  619. }
  620. exports.isSymbol = isSymbol;
  621. function isUndefined(arg) {
  622. return arg === void 0;
  623. }
  624. exports.isUndefined = isUndefined;
  625. function isRegExp(re) {
  626. return isObject(re) && objectToString(re) === '[object RegExp]';
  627. }
  628. exports.isRegExp = isRegExp;
  629. function isObject(arg) {
  630. return typeof arg === 'object' && arg !== null;
  631. }
  632. exports.isObject = isObject;
  633. function isDate(d) {
  634. return isObject(d) && objectToString(d) === '[object Date]';
  635. }
  636. exports.isDate = isDate;
  637. function isError(e) {
  638. return isObject(e) &&
  639. (objectToString(e) === '[object Error]' || e instanceof Error);
  640. }
  641. exports.isError = isError;
  642. function isFunction(arg) {
  643. return typeof arg === 'function';
  644. }
  645. exports.isFunction = isFunction;
  646. function isPrimitive(arg) {
  647. return arg === null ||
  648. typeof arg === 'boolean' ||
  649. typeof arg === 'number' ||
  650. typeof arg === 'string' ||
  651. typeof arg === 'symbol' || // ES6 symbol
  652. typeof arg === 'undefined';
  653. }
  654. exports.isPrimitive = isPrimitive;
  655. exports.isBuffer = require('./support/isBuffer');
  656. function objectToString(o) {
  657. return Object.prototype.toString.call(o);
  658. }
  659. function pad(n) {
  660. return n < 10 ? '0' + n.toString(10) : n.toString(10);
  661. }
  662. var months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep',
  663. 'Oct', 'Nov', 'Dec'];
  664. // 26 Feb 16:19:34
  665. function timestamp() {
  666. var d = new Date();
  667. var time = [pad(d.getHours()),
  668. pad(d.getMinutes()),
  669. pad(d.getSeconds())].join(':');
  670. return [d.getDate(), months[d.getMonth()], time].join(' ');
  671. }
  672. // log is just a thin wrapper to console.log that prepends a timestamp
  673. exports.log = function() {
  674. console.log('%s - %s', timestamp(), exports.format.apply(exports, arguments));
  675. };
  676. /**
  677. * Inherit the prototype methods from one constructor into another.
  678. *
  679. * The Function.prototype.inherits from lang.js rewritten as a standalone
  680. * function (not on Function.prototype). NOTE: If this file is to be loaded
  681. * during bootstrapping this function needs to be rewritten using some native
  682. * functions as prototype setup using normal JavaScript does not work as
  683. * expected during bootstrapping (see mirror.js in r114903).
  684. *
  685. * @param {function} ctor Constructor function which needs to inherit the
  686. * prototype.
  687. * @param {function} superCtor Constructor function to inherit prototype from.
  688. */
  689. exports.inherits = require('inherits');
  690. exports._extend = function(origin, add) {
  691. // Don't do anything if add isn't an object
  692. if (!add || !isObject(add)) return origin;
  693. var keys = Object.keys(add);
  694. var i = keys.length;
  695. while (i--) {
  696. origin[keys[i]] = add[keys[i]];
  697. }
  698. return origin;
  699. };
  700. function hasOwnProperty(obj, prop) {
  701. return Object.prototype.hasOwnProperty.call(obj, prop);
  702. }
  703. }).call(this,require('_process'),typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  704. },{"./support/isBuffer":3,"_process":1,"inherits":2}],5:[function(require,module,exports){
  705. var util = require('util');
  706. console.log(util.format('Hello %s', 'world'));
  707. var Vue = require('vue'),
  708. VueMaterial = require('vue-material');
  709. Vue.use(VueMaterial);
  710. var App = new Vue({
  711. el: '#app',
  712. methods: {
  713. toggleLeftSidenav() {
  714. this.$refs.leftSidenav.toggle();
  715. },
  716. toggleRightSidenav() {
  717. this.$refs.rightSidenav.toggle();
  718. },
  719. closeRightSidenav() {
  720. this.$refs.rightSidenav.close();
  721. },
  722. open(ref) {
  723. console.log('Opened: ' + ref);
  724. },
  725. close(ref) {
  726. console.log('Closed: ' + ref);
  727. }
  728. }
  729. });
  730. },{"util":4,"vue":7,"vue-material":6}],6:[function(require,module,exports){
  731. /*!
  732. * Vue Material v0.7.1
  733. * Made with love by Marcos Moura
  734. * Released under the MIT License.
  735. */
  736. !(function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("vue")):"function"==typeof define&&define.amd?define(["vue"],e):"object"==typeof exports?exports.VueMaterial=e(require("vue")):t.VueMaterial=e(t.Vue)})(this,(function(t){return (function(t){function e(i){if(n[i])return n[i].exports;var o=n[i]={i:i,l:!1,exports:{}};return t[i].call(o.exports,o,o.exports,e),o.l=!0,o.exports}var n={};return e.m=t,e.c=n,e.i=function(t){return t},e.d=function(t,n,i){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:i})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="/",e(e.s=429)})([(function(t,e){t.exports=function(t,e,n,i){var o,r=t=t||{},a=typeof t.default;"object"!==a&&"function"!==a||(o=t,r=t.default);var s="function"==typeof r?r.options:r;if(e&&(s.render=e.render,s.staticRenderFns=e.staticRenderFns),n&&(s._scopeId=n),i){var d=s.computed||(s.computed={});Object.keys(i).forEach((function(t){var e=i[t];d[t]=function(){return e}}))}return{esModule:o,exports:r,options:s}}}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{mdTheme:String},data:function(){return{closestThemedParent:!1}},methods:{getClosestThemedParent:function(t){return!(!t||!t.$el||0===t._uid)&&(t.mdTheme||t.mdName?t:this.getClosestThemedParent(t.$parent))}},computed:{themeClass:function(){if(this.mdTheme)return"md-theme-"+this.mdTheme;var t=this.closestThemedParent.mdTheme;return t||(t=this.closestThemedParent?this.closestThemedParent.mdName:this.$material.currentTheme),"md-theme-"+t}},mounted:function(){this.closestThemedParent=this.getClosestThemedParent(this.$parent),this.$material.currentTheme||this.$material.setCurrentTheme("default")}},t.exports=e.default}),(function(t,e){var n=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)}),(function(t,e,n){t.exports=!n(9)((function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a}))}),(function(t,e,n){var i=n(22)("wks"),o=n(19),r=n(2).Symbol,a="function"==typeof r,s=t.exports=function(t){return i[t]||(i[t]=a&&r[t]||(a?r:o)("Symbol."+t))};s.store=i}),(function(t,e){var n=t.exports={version:"2.4.0"};"number"==typeof __e&&(__e=n)}),(function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}}),(function(t,e,n){var i=n(32),o=n(15);t.exports=function(t){return i(o(t))}}),(function(t,e,n){var i=n(13),o=n(29),r=n(26),a=Object.defineProperty;e.f=n(3)?Object.defineProperty:function(t,e,n){if(i(t),e=r(e,!0),i(n),o)try{return a(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(t[e]=n.value),t}}),(function(t,e){t.exports=function(t){try{return!!t()}catch(t){return!0}}}),(function(t,e,n){var i=n(8),o=n(14);t.exports=n(3)?function(t,e,n){return i.f(t,e,o(1,n))}:function(t,e,n){return t[e]=n,t}}),(function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=function t(e,n){return!(!e||!e.$el)&&(0!==e._uid&&(e.$el.classList.contains(n)?e:t(e.$parent,n)))};e.default=i,t.exports=e.default}),(function(t,e,n){var i=n(11);t.exports=function(t){if(!i(t))throw TypeError(t+" is not an object!");return t}}),(function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}}),(function(t,e){t.exports=function(t){if(void 0==t)throw TypeError("Can't call method on "+t);return t}}),(function(t,e,n){var i=n(30),o=n(21);t.exports=Object.keys||function(t){return i(t,o)}}),(function(t,e){var n=Math.ceil,i=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?i:n)(t)}}),(function(t,e,n){var i=n(2),o=n(5),r=n(28),a=n(10),s="prototype",d=function(t,e,n){var l,c,u,m=t&d.F,f=t&d.G,p=t&d.S,h=t&d.P,b=t&d.B,v=t&d.W,E=f?o:o[e]||(o[e]={}),g=E[s],_=f?i:p?i[e]:(i[e]||{})[s];f&&(n=e);for(l in n)c=!m&&_&&void 0!==_[l],c&&l in E||(u=c?_[l]:n[l],E[l]=f&&"function"!=typeof _[l]?n[l]:b&&c?r(u,i):v&&_[l]==u?(function(t){var e=function(e,n,i){if(this instanceof t){switch(arguments.length){case 0:return new t;case 1:return new t(e);case 2:return new t(e,n)}return new t(e,n,i)}return t.apply(this,arguments)};return e[s]=t[s],e})(u):h&&"function"==typeof u?r(Function.call,u):u,h&&((E.virtual||(E.virtual={}))[l]=u,t&d.R&&g&&!g[l]&&a(g,l,u)))};d.F=1,d.G=2,d.S=4,d.P=8,d.B=16,d.W=32,d.U=64,d.R=128,t.exports=d}),(function(t,e){var n=0,i=Math.random();t.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++n+i).toString(36))}}),(function(t,e,n){var i=n(22)("keys"),o=n(19);t.exports=function(t){return i[t]||(i[t]=o(t))}}),(function(t,e){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")}),(function(t,e,n){var i=n(2),o="__core-js_shared__",r=i[o]||(i[o]={});t.exports=function(t){return r[t]||(r[t]={})}}),(function(t,e,n){var i=n(15);t.exports=function(t){return Object(i(t))}}),(function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}}),(function(t,e){t.exports={}}),(function(t,e,n){var i=n(11);t.exports=function(t,e){if(!i(t))return t;var n,o;if(e&&"function"==typeof(n=t.toString)&&!i(o=n.call(t)))return o;if("function"==typeof(n=t.valueOf)&&!i(o=n.call(t)))return o;if(!e&&"function"==typeof(n=t.toString)&&!i(o=n.call(t)))return o;throw TypeError("Can't convert object to primitive value")}}),(function(t,e,n){var i=n(11),o=n(2).document,r=i(o)&&i(o.createElement);t.exports=function(t){return r?o.createElement(t):{}}}),(function(t,e,n){var i=n(34);t.exports=function(t,e,n){if(i(t),void 0===e)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 2:return function(n,i){return t.call(e,n,i)};case 3:return function(n,i,o){return t.call(e,n,i,o)}}return function(){return t.apply(e,arguments)}}}),(function(t,e,n){t.exports=!n(3)&&!n(9)((function(){return 7!=Object.defineProperty(n(27)("div"),"a",{get:function(){return 7}}).a}))}),(function(t,e,n){var i=n(6),o=n(7),r=n(35)(!1),a=n(20)("IE_PROTO");t.exports=function(t,e){var n,s=o(t),d=0,l=[];for(n in s)n!=a&&i(s,n)&&l.push(n);for(;e.length>d;)i(s,n=e[d++])&&(~r(l,n)||l.push(n));return l}}),(function(t,e,n){var i=n(17),o=Math.min;t.exports=function(t){return t>0?o(i(t),9007199254740991):0}}),(function(t,e,n){var i=n(24);t.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==i(t)?t.split(""):Object(t)}}),(function(t,e,n){var i=n(8).f,o=n(6),r=n(4)("toStringTag");t.exports=function(t,e,n){t&&!o(t=n?t:t.prototype,r)&&i(t,r,{configurable:!0,value:e})}}),(function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}}),(function(t,e,n){var i=n(7),o=n(31),r=n(37);t.exports=function(t){return function(e,n,a){var s,d=i(e),l=o(d.length),c=r(a,l);if(t&&n!=n){for(;l>c;)if(s=d[c++],s!=s)return!0}else for(;l>c;c++)if((t||c in d)&&d[c]===n)return t||c||0;return!t&&-1}}}),(function(t,e){t.exports=!0}),(function(t,e,n){var i=n(17),o=Math.max,r=Math.min;t.exports=function(t,e){return t=i(t),t<0?o(t+e,0):r(t,e)}}),(function(t,e){e.f={}.propertyIsEnumerable}),(function(t,e,n){"use strict";function i(){var t=document.createElement("span"),e={transition:"transitionend",OTransition:"oTransitionEnd",MozTransition:"transitionend",WebkitTransition:"webkitTransitionEnd"};for(var n in e)if(void 0!==t.style[n])return e[n]}Object.defineProperty(e,"__esModule",{value:!0}),e.default=i(),t.exports=e.default}),(function(t,e,n){t.exports={default:n(49),__esModule:!0}}),(function(t,e,n){"use strict";var i=n(36),o=n(18),r=n(43),a=n(10),s=n(6),d=n(25),l=n(51),c=n(33),u=n(53),m=n(4)("iterator"),f=!([].keys&&"next"in[].keys()),p="@@iterator",h="keys",b="values",v=function(){return this};t.exports=function(t,e,n,E,g,_,C){l(n,e,E);var M,T,A,x=function(t){if(!f&&t in R)return R[t];switch(t){case h:return function(){return new n(this,t)};case b:return function(){return new n(this,t)}}return function(){return new n(this,t)}},O=e+" Iterator",N=g==b,y=!1,R=t.prototype,S=R[m]||R[p]||g&&R[g],w=S||x(g),k=g?N?x("entries"):w:void 0,P="Array"==e?R.entries||S:S;if(P&&(A=u(P.call(new t)),A!==Object.prototype&&(c(A,O,!0),i||s(A,m)||a(A,m,v))),N&&S&&S.name!==b&&(y=!0,w=function(){return S.call(this)}),i&&!C||!f&&!y&&R[m]||a(R,m,w),d[e]=w,d[O]=v,g)if(M={values:N?w:x(b),keys:_?w:x(h),entries:k},C)for(T in M)T in R||r(R,T,M[T]);else o(o.P+o.F*(f||y),e,M);return M}}),(function(t,e,n){var i=n(13),o=n(52),r=n(21),a=n(20)("IE_PROTO"),s=function(){},d="prototype",l=function(){var t,e=n(27)("iframe"),i=r.length,o="<",a=">";for(e.style.display="none",n(50).appendChild(e),e.src="javascript:",t=e.contentWindow.document,t.open(),t.write(o+"script"+a+"document.F=Object"+o+"/script"+a),t.close(),l=t.F;i--;)delete l[d][r[i]];return l()};t.exports=Object.create||function(t,e){var n;return null!==t?(s[d]=i(t),n=new s,s[d]=null,n[a]=t):n=l(),void 0===e?n:o(n,e)}}),(function(t,e,n){t.exports=n(10)}),(function(t,e,n){var i=n(2),o=n(5),r=n(36),a=n(45),s=n(8).f;t.exports=function(t){var e=o.Symbol||(o.Symbol=r?{}:i.Symbol||{});"_"==t.charAt(0)||t in e||s(e,t,{value:a.f(t)})}}),(function(t,e,n){e.f=n(4)}),(function(t,e){e.f=Object.getOwnPropertySymbols}),(function(t,e,n){"use strict";var i=n(55)(!0);n(41)(String,"String",(function(t){this._t=String(t),this._i=0}),(function(){var t,e=this._t,n=this._i;return n>=e.length?{value:void 0,done:!0}:(t=i(e,n),this._i+=t.length,{value:t,done:!1})}))}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=function(){return Math.random().toString(36).slice(4)};e.default=i,t.exports=e.default}),(function(t,e,n){n(56),t.exports=n(5).Object.keys}),(function(t,e,n){t.exports=n(2).document&&document.documentElement}),(function(t,e,n){"use strict";var i=n(42),o=n(14),r=n(33),a={};n(10)(a,n(4)("iterator"),(function(){return this})),t.exports=function(t,e,n){t.prototype=i(a,{next:o(1,n)}),r(t,e+" Iterator")}}),(function(t,e,n){var i=n(8),o=n(13),r=n(16);t.exports=n(3)?Object.defineProperties:function(t,e){o(t);for(var n,a=r(e),s=a.length,d=0;s>d;)i.f(t,n=a[d++],e[n]);return t}}),(function(t,e,n){var i=n(6),o=n(23),r=n(20)("IE_PROTO"),a=Object.prototype;t.exports=Object.getPrototypeOf||function(t){return t=o(t),i(t,r)?t[r]:"function"==typeof t.constructor&&t instanceof t.constructor?t.constructor.prototype:t instanceof Object?a:null}}),(function(t,e,n){var i=n(18),o=n(5),r=n(9);t.exports=function(t,e){var n=(o.Object||{})[t]||Object[t],a={};a[t]=e(n),i(i.S+i.F*r((function(){n(1)})),"Object",a)}}),(function(t,e,n){var i=n(17),o=n(15);t.exports=function(t){return function(e,n){var r,a,s=String(o(e)),d=i(n),l=s.length;return d<0||d>=l?t?"":void 0:(r=s.charCodeAt(d),r<55296||r>56319||d+1===l||(a=s.charCodeAt(d+1))<56320||a>57343?t?s.charAt(d):r:t?s.slice(d,d+2):(r-55296<<10)+(a-56320)+65536)}}}),(function(t,e,n){var i=n(23),o=n(16);n(54)("keys",(function(){return function(t){return o(i(t))}}))}),(function(t,e,n){var i=n(30),o=n(21).concat("length","prototype");e.f=Object.getOwnPropertyNames||function(t){return i(t,o)}}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=function(t,e,n){var i=document.createElement("canvas");t.crossOrigin="Anonymous",t.onload=function(){var t=0,n=void 0,o=void 0,r=void 0,a=void 0,s=void 0,d=void 0,l=void 0;i.width=this.width,i.height=this.height,n=i.getContext("2d"),n.drawImage(this,0,0),o=n.getImageData(0,0,i.width,i.height),r=o.data;for(var c=0,u=r.length;c<u;c+=4)a=r[c],s=r[c+1],d=r[c+2],l=Math.floor((a+s+d)/3),t+=l;e(Math.floor(t/(this.width*this.height)))},t.onerror=n};e.default=i,t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=function(t){return t&&t.constructor===Array};e.default=i,t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}e.__esModule=!0;var o=n(63),r=i(o);e.default=function(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e<t.length;e++)n[e]=t[e];return n}return(0,r.default)(t)}}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}e.__esModule=!0;var o=n(65),r=i(o),a=n(64),s=i(a),d="function"==typeof s.default&&"symbol"==typeof r.default?function(t){return typeof t}:function(t){return t&&"function"==typeof s.default&&t.constructor===s.default&&t!==s.default.prototype?"symbol":typeof t};e.default="function"==typeof s.default&&"symbol"===d(r.default)?function(t){return"undefined"==typeof t?"undefined":d(t)}:function(t){return t&&"function"==typeof s.default&&t.constructor===s.default&&t!==s.default.prototype?"symbol":"undefined"==typeof t?"undefined":d(t)}}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{value:[String,Number],disabled:Boolean,required:Boolean,maxlength:[Number,String],placeholder:String},watch:{value:function(t){this.setParentValue(t),this.updateValues(t)},disabled:function(){this.setParentDisabled()},required:function(){this.setParentRequired()},placeholder:function(){this.setParentPlaceholder()},maxlength:function(){this.handleMaxLength()}},methods:{handleMaxLength:function(){this.parentContainer.enableCounter=this.maxlength>0,this.parentContainer.counterLength=this.maxlength},setParentValue:function(t){this.parentContainer.setValue(t||this.$el.value)},setParentDisabled:function(){this.parentContainer.isDisabled=this.disabled},setParentRequired:function(){this.parentContainer.isRequired=this.required},setParentPlaceholder:function(){this.parentContainer.hasPlaceholder=!!this.placeholder},updateValues:function(t){var e=t||this.$el.value||this.value;this.setParentValue(e),this.parentContainer.inputLength=e?e.length:0},onFocus:function(){this.parentContainer&&(this.parentContainer.isFocused=!0)},onBlur:function(){this.parentContainer.isFocused=!1,this.setParentValue()},onInput:function(){this.updateValues(),this.$emit("change",this.$el.value),this.$emit("input",this.$el.value)}}},t.exports=e.default}),(function(t,e,n){t.exports={default:n(66),__esModule:!0}}),(function(t,e,n){t.exports={default:n(67),__esModule:!0}}),(function(t,e,n){t.exports={default:n(68),__esModule:!0}}),(function(t,e,n){n(47),n(83),t.exports=n(5).Array.from}),(function(t,e,n){n(86),n(85),n(87),n(88),t.exports=n(5).Symbol}),(function(t,e,n){n(47),n(89),t.exports=n(45).f("iterator")}),(function(t,e){t.exports=function(){}}),(function(t,e,n){var i=n(24),o=n(4)("toStringTag"),r="Arguments"==i(function(){return arguments}()),a=function(t,e){try{return t[e]}catch(t){}};t.exports=function(t){var e,n,s;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=a(e=Object(t),o))?n:r?i(e):"Object"==(s=i(e))&&"function"==typeof e.callee?"Arguments":s}}),(function(t,e,n){"use strict";var i=n(8),o=n(14);t.exports=function(t,e,n){e in t?i.f(t,e,o(0,n)):t[e]=n}}),(function(t,e,n){var i=n(16),o=n(46),r=n(38);t.exports=function(t){var e=i(t),n=o.f;if(n)for(var a,s=n(t),d=r.f,l=0;s.length>l;)d.call(t,a=s[l++])&&e.push(a);return e}}),(function(t,e,n){var i=n(25),o=n(4)("iterator"),r=Array.prototype;t.exports=function(t){return void 0!==t&&(i.Array===t||r[o]===t)}}),(function(t,e,n){var i=n(24);t.exports=Array.isArray||function(t){return"Array"==i(t)}}),(function(t,e,n){var i=n(13);t.exports=function(t,e,n,o){try{return o?e(i(n)[0],n[1]):e(n)}catch(e){var r=t.return;throw void 0!==r&&i(r.call(t)),e}}}),(function(t,e,n){var i=n(4)("iterator"),o=!1;try{var r=[7][i]();r.return=function(){o=!0},Array.from(r,(function(){throw 2}))}catch(t){}t.exports=function(t,e){if(!e&&!o)return!1;var n=!1;try{var r=[7],a=r[i]();a.next=function(){return{done:n=!0}},r[i]=function(){return a},t(r)}catch(t){}return n}}),(function(t,e){t.exports=function(t,e){return{value:e,done:!!t}}}),(function(t,e,n){var i=n(16),o=n(7);t.exports=function(t,e){for(var n,r=o(t),a=i(r),s=a.length,d=0;s>d;)if(r[n=a[d++]]===e)return n}}),(function(t,e,n){var i=n(19)("meta"),o=n(11),r=n(6),a=n(8).f,s=0,d=Object.isExtensible||function(){return!0},l=!n(9)((function(){return d(Object.preventExtensions({}))})),c=function(t){a(t,i,{value:{i:"O"+ ++s,w:{}}})},u=function(t,e){if(!o(t))return"symbol"==typeof t?t:("string"==typeof t?"S":"P")+t;if(!r(t,i)){if(!d(t))return"F";if(!e)return"E";c(t)}return t[i].i},m=function(t,e){if(!r(t,i)){if(!d(t))return!0;if(!e)return!1;c(t)}return t[i].w},f=function(t){return l&&p.NEED&&d(t)&&!r(t,i)&&c(t),t},p=t.exports={KEY:i,NEED:!1,fastKey:u,getWeak:m,onFreeze:f}}),(function(t,e,n){var i=n(38),o=n(14),r=n(7),a=n(26),s=n(6),d=n(29),l=Object.getOwnPropertyDescriptor;e.f=n(3)?l:function(t,e){if(t=r(t),e=a(e,!0),d)try{return l(t,e)}catch(t){}if(s(t,e))return o(!i.f.call(t,e),t[e])}}),(function(t,e,n){var i=n(7),o=n(57).f,r={}.toString,a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],s=function(t){try{return o(t)}catch(t){return a.slice()}};t.exports.f=function(t){return a&&"[object Window]"==r.call(t)?s(t):o(i(t))}}),(function(t,e,n){var i=n(70),o=n(4)("iterator"),r=n(25);t.exports=n(5).getIteratorMethod=function(t){if(void 0!=t)return t[o]||t["@@iterator"]||r[i(t)]}}),(function(t,e,n){"use strict";var i=n(28),o=n(18),r=n(23),a=n(75),s=n(73),d=n(31),l=n(71),c=n(82);o(o.S+o.F*!n(76)((function(t){Array.from(t)})),"Array",{from:function(t){var e,n,o,u,m=r(t),f="function"==typeof this?this:Array,p=arguments.length,h=p>1?arguments[1]:void 0,b=void 0!==h,v=0,E=c(m);if(b&&(h=i(h,p>2?arguments[2]:void 0,2)),void 0==E||f==Array&&s(E))for(e=d(m.length),n=new f(e);e>v;v++)l(n,v,b?h(m[v],v):m[v]);else for(u=E.call(m),n=new f;!(o=u.next()).done;v++)l(n,v,b?a(u,h,[o.value,v],!0):o.value);return n.length=v,n}})}),(function(t,e,n){"use strict";var i=n(69),o=n(77),r=n(25),a=n(7);t.exports=n(41)(Array,"Array",(function(t,e){this._t=a(t),this._i=0,this._k=e}),(function(){var t=this._t,e=this._k,n=this._i++;return!t||n>=t.length?(this._t=void 0,o(1)):"keys"==e?o(0,n):"values"==e?o(0,t[n]):o(0,[n,t[n]])}),"values"),r.Arguments=r.Array,i("keys"),i("values"),i("entries")}),(function(t,e){}),(function(t,e,n){"use strict";var i=n(2),o=n(6),r=n(3),a=n(18),s=n(43),d=n(79).KEY,l=n(9),c=n(22),u=n(33),m=n(19),f=n(4),p=n(45),h=n(44),b=n(78),v=n(72),E=n(74),g=n(13),_=n(7),C=n(26),M=n(14),T=n(42),A=n(81),x=n(80),O=n(8),N=n(16),y=x.f,R=O.f,S=A.f,w=i.Symbol,k=i.JSON,P=k&&k.stringify,H="prototype",L=f("_hidden"),$=f("toPrimitive"),I={}.propertyIsEnumerable,D=c("symbol-registry"),B=c("symbols"),j=c("op-symbols"),F=Object[H],W="function"==typeof w,Y=i.QObject,G=!Y||!Y[H]||!Y[H].findChild,U=r&&l((function(){return 7!=T(R({},"a",{get:function(){return R(this,"a",{value:7}).a}})).a}))?function(t,e,n){var i=y(F,e);i&&delete F[e],R(t,e,n),i&&t!==F&&R(F,e,i)}:R,z=function(t){var e=B[t]=T(w[H]);return e._k=t,e},K=W&&"symbol"==typeof w.iterator?function(t){return"symbol"==typeof t}:function(t){return t instanceof w},V=function(t,e,n){return t===F&&V(j,e,n),g(t),e=C(e,!0),g(n),o(B,e)?(n.enumerable?(o(t,L)&&t[L][e]&&(t[L][e]=!1),n=T(n,{enumerable:M(0,!1)})):(o(t,L)||R(t,L,M(1,{})),t[L][e]=!0),U(t,e,n)):R(t,e,n)},q=function(t,e){g(t);for(var n,i=v(e=_(e)),o=0,r=i.length;r>o;)V(t,n=i[o++],e[n]);return t},X=function(t,e){return void 0===e?T(t):q(T(t),e)},J=function(t){var e=I.call(this,t=C(t,!0));return!(this===F&&o(B,t)&&!o(j,t))&&(!(e||!o(this,t)||!o(B,t)||o(this,L)&&this[L][t])||e)},Q=function(t,e){if(t=_(t),e=C(e,!0),t!==F||!o(B,e)||o(j,e)){var n=y(t,e);return!n||!o(B,e)||o(t,L)&&t[L][e]||(n.enumerable=!0),n}},Z=function(t){for(var e,n=S(_(t)),i=[],r=0;n.length>r;)o(B,e=n[r++])||e==L||e==d||i.push(e);return i},tt=function(t){for(var e,n=t===F,i=S(n?j:_(t)),r=[],a=0;i.length>a;)!o(B,e=i[a++])||n&&!o(F,e)||r.push(B[e]);return r};W||(w=function(){if(this instanceof w)throw TypeError("Symbol is not a constructor!");var t=m(arguments.length>0?arguments[0]:void 0),e=function(n){this===F&&e.call(j,n),o(this,L)&&o(this[L],t)&&(this[L][t]=!1),U(this,t,M(1,n))};return r&&G&&U(F,t,{configurable:!0,set:e}),z(t)},s(w[H],"toString",(function(){return this._k})),x.f=Q,O.f=V,n(57).f=A.f=Z,n(38).f=J,n(46).f=tt,r&&!n(36)&&s(F,"propertyIsEnumerable",J,!0),p.f=function(t){return z(f(t))}),a(a.G+a.W+a.F*!W,{Symbol:w});for(var et="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),nt=0;et.length>nt;)f(et[nt++]);for(var et=N(f.store),nt=0;et.length>nt;)h(et[nt++]);a(a.S+a.F*!W,"Symbol",{for:function(t){return o(D,t+="")?D[t]:D[t]=w(t)},keyFor:function(t){if(K(t))return b(D,t);throw TypeError(t+" is not a symbol!")},useSetter:function(){G=!0},useSimple:function(){G=!1}}),a(a.S+a.F*!W,"Object",{create:X,defineProperty:V,defineProperties:q,getOwnPropertyDescriptor:Q,getOwnPropertyNames:Z,getOwnPropertySymbols:tt}),k&&a(a.S+a.F*(!W||l((function(){var t=w();return"[null]"!=P([t])||"{}"!=P({a:t})||"{}"!=P(Object(t))}))),"JSON",{stringify:function(t){if(void 0!==t&&!K(t)){for(var e,n,i=[t],o=1;arguments.length>o;)i.push(arguments[o++]);return e=i[1],"function"==typeof e&&(n=e),!n&&E(e)||(e=function(t,e){if(n&&(e=n.call(this,t,e)),!K(e))return e}),i[1]=e,P.apply(k,i)}}}),w[H][$]||n(10)(w[H],$,w[H].valueOf),u(w,"Symbol"),u(Math,"Math",!0),u(i.JSON,"JSON",!0)}),(function(t,e,n){n(44)("asyncIterator")}),(function(t,e,n){n(44)("observable")}),(function(t,e,n){n(84);for(var i=n(2),o=n(10),r=n(25),a=n(4)("toStringTag"),s=["NodeList","DOMTokenList","MediaList","StyleSheetList","CSSRuleList"],d=0;d<5;d++){var l=s[d],c=i[l],u=c&&c.prototype;u&&!u[a]&&o(u,a,l),r[l]=r.Array}}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-avatar",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(260),a=i(r),s=n(233),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-backdrop",a.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(261),a=i(r);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-bottom-bar",a.default),t.component("md-bottom-bar-item",d.default),t.material.styles.push(c.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(262),a=i(r),s=n(263),d=i(s),l=n(234),c=i(l);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-button",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(264),a=i(r),s=n(235),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-button-toggle",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(265),a=i(r),s=n(236),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-card",a.default),t.component("md-card-media",d.default),t.component("md-card-media-cover",c.default),t.component("md-card-media-actions",m.default),t.component("md-card-header",p.default),t.component("md-card-header-text",b.default),t.component("md-card-content",E.default),t.component("md-card-actions",_.default),t.component("md-card-area",M.default),t.component("md-card-expand",A.default),t.material.styles.push(O.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(266),a=i(r),s=n(273),d=i(s),l=n(275),c=i(l),u=n(274),m=i(u),f=n(271),p=i(f),h=n(272),b=i(h),v=n(269),E=i(v),g=n(267),_=i(g),C=n(268),M=i(C),T=n(270),A=i(T),x=n(237),O=i(x);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-checkbox",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(276),a=i(r),s=n(238),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-chips",a.default),t.component("md-chip",d.default),t.material.styles.push(c.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(278),a=i(r),s=n(277),d=i(s),l=n(239),c=i(l);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-dialog",a.default),t.component("md-dialog-title",d.default),t.component("md-dialog-content",c.default),t.component("md-dialog-actions",m.default),t.component("md-dialog-alert",p.default),t.component("md-dialog-confirm",b.default),t.component("md-dialog-prompt",E.default),t.material.styles.push(_.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(279),a=i(r),s=n(282),d=i(s),l=n(281),c=i(l),u=n(280),m=i(u),f=n(283),p=i(f),h=n(284),b=i(h),v=n(285),E=i(v),g=n(240),_=i(g);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-divider",a.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(286),a=i(r);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-file",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(287),a=i(r),s=n(241),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-icon",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(288),a=i(r),s=n(242),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-image",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(289),a=i(r),s=n(243),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-input-container",a.default),t.component("md-input",d.default),t.component("md-textarea",c.default),t.material.styles.push(m.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(291),a=i(r),s=n(290),d=i(s),l=n(292),c=i(l),u=n(244),m=i(u);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-layout",a.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(293),a=i(r);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-list",a.default),t.component("md-list-item",d.default),t.component("md-list-expand",c.default),t.material.styles.push(m.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(294),a=i(r),s=n(123),d=i(s),l=n(295),c=i(l),u=n(245),m=i(u);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-menu",a.default),t.component("md-menu-item",d.default),t.component("md-menu-content",c.default),t.material.styles.push(m.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(301),a=i(r),s=n(303),d=i(s),l=n(302),c=i(l),u=n(246),m=i(u);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-progress",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(304),a=i(r),s=n(247),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-radio",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(305),a=i(r),s=n(248),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-select",a.default),t.component("md-option",d.default),t.material.styles.push(c.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(307),a=i(r),s=n(306),d=i(s),l=n(249),c=i(l);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-sidenav",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(308),a=i(r),s=n(250),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-snackbar",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(309),a=i(r),s=n(251),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-speed-dial",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(310),a=i(r),s=n(252),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-spinner",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(311),a=i(r),s=n(253),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-subheader",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(312),a=i(r),s=n(254),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-switch",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(313),a=i(r),s=n(255),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-table",a.default),t.component("md-table-header",{functional:!0,render:function(t,e){return t("thead",{staticClass:"md-table-header"},e.children)}}),t.component("md-table-body",{functional:!0,render:function(t,e){return t("tbody",{staticClass:"md-table-body"},e.children)}}),t.component("md-table-row",d.default),t.component("md-table-head",c.default),t.component("md-table-cell",m.default),t.component("md-table-edit",p.default),t.component("md-table-card",b.default),t.component("md-table-pagination",_.default),t.component("md-table-alternate-header",E.default),t.material.styles.push(M.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(314),a=i(r),s=n(321),d=i(s),l=n(319),c=i(l),u=n(317),m=i(u),f=n(318),p=i(f),h=n(316),b=i(h),v=n(315),E=i(v),g=n(320),_=i(g),C=n(256),M=i(C);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-tabs",a.default),t.component("md-tab",d.default),t.material.styles.push(c.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(323),a=i(r),s=n(322),d=i(s),l=n(257),c=i(l);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-toolbar",a.default),t.material.styles.push(d.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(324),a=i(r),s=n(258),d=i(s);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-tooltip",a.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(325),a=i(r);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-whiteframe",a.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;
  737. var r=n(326),a=i(r);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){return o.installed?void console.warn("Vue Material is already installed."):(o.installed=!0,t.use(a.default),t.use(d.default),void t.material.styles.push(c.default))}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(126),a=i(r),s=n(125),d=i(s),l=n(259),c=i(l);n(200),t.exports=e.default}),(function(t,e,n){var i,o,r;!(function(n,a){o=[e,t],i=a,r="function"==typeof i?i.apply(e,o):i,!(void 0!==r&&(t.exports=r))})(this,(function(t,e){"use strict";function n(t){function e(){var e=window.getComputedStyle(t,null);"vertical"===e.resize?t.style.resize="none":"both"===e.resize&&(t.style.resize="horizontal"),d="content-box"===e.boxSizing?-(parseFloat(e.paddingTop)+parseFloat(e.paddingBottom)):parseFloat(e.borderTopWidth)+parseFloat(e.borderBottomWidth),isNaN(d)&&(d=0),s()}function n(e){var n=t.style.width;t.style.width="0px",t.offsetWidth,t.style.width=n,t.style.overflowY=e}function i(t){for(var e=[];t&&t.parentNode&&t.parentNode instanceof Element;)t.parentNode.scrollTop&&e.push({node:t.parentNode,scrollTop:t.parentNode.scrollTop}),t=t.parentNode;return e}function o(){var e=t.style.height,n=i(t),o=document.documentElement&&document.documentElement.scrollTop;t.style.height="auto";var r=t.scrollHeight+d;return 0===t.scrollHeight?void(t.style.height=e):(t.style.height=r+"px",l=t.clientWidth,n.forEach((function(t){t.node.scrollTop=t.scrollTop})),void(o&&(document.documentElement.scrollTop=o)))}function s(){o();var e=Math.round(parseFloat(t.style.height)),i=window.getComputedStyle(t,null),r=Math.round(parseFloat(i.height));if(r!==e?"visible"!==i.overflowY&&(n("visible"),o(),r=Math.round(parseFloat(window.getComputedStyle(t,null).height))):"hidden"!==i.overflowY&&(n("hidden"),o(),r=Math.round(parseFloat(window.getComputedStyle(t,null).height))),c!==r){c=r;var s=a("autosize:resized");try{t.dispatchEvent(s)}catch(t){}}}if(t&&t.nodeName&&"TEXTAREA"===t.nodeName&&!r.has(t)){var d=null,l=t.clientWidth,c=null,u=function(){t.clientWidth!==l&&s()},m=function(e){window.removeEventListener("resize",u,!1),t.removeEventListener("input",s,!1),t.removeEventListener("keyup",s,!1),t.removeEventListener("autosize:destroy",m,!1),t.removeEventListener("autosize:update",s,!1),Object.keys(e).forEach((function(n){t.style[n]=e[n]})),r.delete(t)}.bind(t,{height:t.style.height,resize:t.style.resize,overflowY:t.style.overflowY,overflowX:t.style.overflowX,wordWrap:t.style.wordWrap});t.addEventListener("autosize:destroy",m,!1),"onpropertychange"in t&&"oninput"in t&&t.addEventListener("keyup",s,!1),window.addEventListener("resize",u,!1),t.addEventListener("input",s,!1),t.addEventListener("autosize:update",s,!1),t.style.overflowX="hidden",t.style.wordWrap="break-word",r.set(t,{destroy:m,update:s}),e()}}function i(t){var e=r.get(t);e&&e.destroy()}function o(t){var e=r.get(t);e&&e.update()}var r="function"==typeof Map?new Map:(function(){var t=[],e=[];return{has:function(e){return t.indexOf(e)>-1},get:function(n){return e[t.indexOf(n)]},set:function(n,i){t.indexOf(n)===-1&&(t.push(n),e.push(i))},delete:function(n){var i=t.indexOf(n);i>-1&&(t.splice(i,1),e.splice(i,1))}}})(),a=function(t){return new Event(t,{bubbles:!0})};try{new Event("test")}catch(t){a=function(t){var e=document.createEvent("Event");return e.initEvent(t,!0,!1),e}}var s=null;"undefined"==typeof window||"function"!=typeof window.getComputedStyle?(s=function(t){return t},s.destroy=function(t){return t},s.update=function(t){return t}):(s=function(t,e){return t&&Array.prototype.forEach.call(t.length?t:[t],(function(t){return n(t,e)})),t},s.destroy=function(t){return t&&Array.prototype.forEach.call(t.length?t:[t],i),t},s.update=function(t){return t&&Array.prototype.forEach.call(t.length?t:[t],o),t}),e.exports=s}))}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(193),r=i(o),a=n(61),s=i(a),d=n(296),l=i(d),c=n(299),u=i(c),m=n(300),f=i(m),p=n(298),h=i(p),b=n(297),v=i(b);e.default={functional:!0,props:{href:String,disabled:Boolean},render:function(t,e){var n=e.children,i=e.data,o=e.props,a=function(){var t=i.nativeOn,e=["contextmenu","dblclick","dragend","mousedown","touchstart","click"],r=n.length;if(o.href)return u.default;if(t)for(var a=e.length;a--;)if(t[e[a]])return l.default;for(;r--;){var d=n[r].componentOptions;if(d)if("md-list-expand"===d.tag){var c=(function(){var t=n[r];return i.scopedSlots={expand:function(){return t}},n.splice(r,1),{v:h.default}})();if("object"===("undefined"==typeof c?"undefined":(0,s.default)(c)))return c.v}else if("router-link"===d.tag)return n[r].data.staticClass="md-list-item-container md-button",f.default}return v.default};return t(a(),(0,r.default)({props:o},i),n)}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(395),r=i(o),a=new r.default({data:function(){return{current:null}}});e.default=a,t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.component("md-ink-ripple",a.default)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(327),a=i(r);t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){t.material=new t({data:function(){return{styles:[],currentTheme:null,inkRipple:!0}},methods:{registerTheme:function(t,e){var n={};"string"==typeof t?n[t]=e:n=t,_(n,this.styles)},applyCurrentTheme:function(t){C(v[t]),document.body.classList.remove("md-theme-"+this.currentTheme),document.body.classList.add("md-theme-"+t),this.currentTheme=t},setCurrentTheme:function(t){b.indexOf(t)>=0?this.applyCurrentTheme(t):(b.indexOf("default")===-1?this.registerTheme("default",p):console.warn("The theme '"+t+"' doesn't exists. You need to register it first in order to use."),this.applyCurrentTheme("default"))}}}),t.component("md-theme",m.default),t.prototype.$material=t.material}Object.defineProperty(e,"__esModule",{value:!0});var r=n(40),a=i(r);e.default=o;var s=n(127),d=i(s),l=n(128),c=i(l),u=n(328),m=i(u),f=["primary","accent","background","warn","hue-1","hue-2","hue-3"],p={primary:"indigo",accent:"pink",background:"white",warn:"deep-orange"},h=function(t,e){var n=document.head,i="md-theme-"+e,o=n.querySelector("#"+i);if(o)o.textContent=t;else{var r=document.createElement("style");t=t.replace(/THEME_NAME/g,i),r.type="text/css",r.id=i,r.textContent=t,n.appendChild(r)}},b=[],v={},E=function(t,e,n){return f.forEach((function(i){t=t.replace(RegExp("("+i.toUpperCase()+")-(COLOR|CONTRAST)-?(A?\\d*)-?(\\d*\\.?\\d+)?","g"),(function(t,o,r,a,s){var l=void 0,u=0===+a?500:a;if(e[i]?"string"==typeof e[i]?l=d.default[e[i]]:(l=d.default[e[i].color]||d.default[p[i]],u=0===+a?e[i].hue:a):l=d.default[p[i]],"COLOR"===r){var m=d.default[e[i]];return a||m||("accent"===i?u="A200":"background"===i&&(u=50)),"primary"===i&&(v[n]=l[u]),s?(0,c.default)(l[u],s):l[u]}return l.darkText.indexOf(u)>=0?s?(0,c.default)("#000",s):"rgba(0, 0, 0, .87)":s?(0,c.default)("#fff",s):"rgba(255, 255, 255, .87)"}))})),t},g=function(t,e,n){var i=[];n.forEach((function(n){i.push(E(n,t,e))})),h(i.join("\n"),e)},_=function(t,e){var n=t?(0,a.default)(t):[];n.forEach((function(n){g(t[n],n,e),b.push(n)}))},C=function(t){var e=document.querySelector('meta[name="theme-color"]');e?e.setAttribute("content",t):(e=document.createElement("meta"),e.setAttribute("name","theme-color"),e.setAttribute("content",t),document.head.appendChild(e))};t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={red:{50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000",darkText:[50,100,200,300,"A100"]},pink:{50:"#fce4ec",100:"#f8bbd0",200:"#f48fb1",300:"#f06292",400:"#ec407a",500:"#e91e63",600:"#d81b60",700:"#c2185b",800:"#ad1457",900:"#880e4f",A100:"#ff80ab",A200:"#ff4081",A400:"#f50057",A700:"#c51162",darkText:[50,100,200,"A100"]},purple:{50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff",darkText:[50,100,200,"A100"]},"deep-purple":{50:"#ede7f6",100:"#d1c4e9",200:"#b39ddb",300:"#9575cd",400:"#7e57c2",500:"#673ab7",600:"#5e35b1",700:"#512da8",800:"#4527a0",900:"#311b92",A100:"#b388ff",A200:"#7c4dff",A400:"#651fff",A700:"#6200ea",darkText:[50,100,200,"A100"]},indigo:{50:"#e8eaf6",100:"#c5cae9",200:"#9fa8da",300:"#7986cb",400:"#5c6bc0",500:"#3f51b5",600:"#3949ab",700:"#303f9f",800:"#283593",900:"#1a237e",A100:"#8c9eff",A200:"#536dfe",A400:"#3d5afe",A700:"#304ffe",darkText:[50,100,200,"A100"]},blue:{50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff",darkText:[50,100,200,300,400,"A100"]},"light-blue":{50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea",darkText:[50,100,200,300,400,500,"A100","A200","A300"]},cyan:{50:"#e0f7fa",100:"#b2ebf2",200:"#80deea",300:"#4dd0e1",400:"#26c6da",500:"#00bcd4",600:"#00acc1",700:"#0097a7",800:"#00838f",900:"#006064",A100:"#84ffff",A200:"#18ffff",A400:"#00e5ff",A700:"#00b8d4",darkText:[50,100,200,300,400,500,600,"A100","A200","A300","A400"]},teal:{50:"#e0f2f1",100:"#b2dfdb",200:"#80cbc4",300:"#4db6ac",400:"#26a69a",500:"#009688",600:"#00897b",700:"#00796b",800:"#00695c",900:"#004d40",A100:"#a7ffeb",A200:"#64ffda",A400:"#1de9b6",A700:"#00bfa5",darkText:[50,100,200,300,400,"A100","A200","A300","A400"]},green:{50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853",darkText:[50,100,200,300,400,500,"A100","A200","A300","A400"]},"light-green":{50:"#f1f8e9",100:"#dcedc8",200:"#c5e1a5",300:"#aed581",400:"#9ccc65",500:"#8bc34a",600:"#7cb342",700:"#689f38",800:"#558b2f",900:"#33691e",A100:"#ccff90",A200:"#b2ff59",A400:"#76ff03",A700:"#64dd17",darkText:[50,100,200,300,400,500,600,"A100","A200","A300","A400"]},lime:{50:"#f9fbe7",100:"#f0f4c3",200:"#e6ee9c",300:"#dce775",400:"#d4e157",500:"#cddc39",600:"#c0ca33",700:"#afb42b",800:"#9e9d24",900:"#827717",A100:"#f4ff81",A200:"#eeff41",A400:"#c6ff00",A700:"#aeea00",darkText:[50,100,200,300,400,500,600,700,800,"A100","A200","A300","A400"]},yellow:{50:"#fffde7",100:"#fff9c4",200:"#fff59d",300:"#fff176",400:"#ffee58",500:"#ffeb3b",600:"#fdd835",700:"#fbc02d",800:"#f9a825",900:"#f57f17",A100:"#ffff8d",A200:"#ffff00",A400:"#ffea00",A700:"#ffd600",darkText:[50,100,200,300,400,500,600,700,800,900,"A100","A200","A300","A400"]},amber:{50:"#fff8e1",100:"#ffecb3",200:"#ffe082",300:"#ffd54f",400:"#ffca28",500:"#ffc107",600:"#ffb300",700:"#ffa000",800:"#ff8f00",900:"#ff6f00",A100:"#ffe57f",A200:"#ffd740",A400:"#ffc400",A700:"#ffab00",darkText:[50,100,200,300,400,500,600,700,800,900,"A100","A200","A300","A400"]},orange:{50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00",darkText:[50,100,200,300,400,500,600,700,"A100","A200","A300","A400"]},"deep-orange":{50:"#fbe9e7",100:"#ffccbc",200:"#ffab91",300:"#ff8a65",400:"#ff7043",500:"#ff5722",600:"#f4511e",700:"#e64a19",800:"#d84315",900:"#bf360c",A100:"#ff9e80",A200:"#ff6e40",A400:"#ff3d00",A700:"#dd2c00",darkText:[50,100,200,300,400,"A100","A200"]},brown:{50:"#efebe9",100:"#d7ccc8",200:"#bcaaa4",300:"#a1887f",400:"#8d6e63",500:"#795548",600:"#6d4c41",700:"#5d4037",800:"#4e342e",900:"#3e2723",A100:"#d7ccc8",A200:"#bcaaa4",A400:"#8d6e63",A700:"#5d4037",darkText:[50,100,200,"A100","A200","A300","A400"]},grey:{50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#fff",A200:"#000000",A400:"#303030",A700:"#616161",darkText:[50,100,200,300,400,500,"A100"]},"blue-grey":{50:"#eceff1",100:"#cfd8dc",200:"#b0bec5",300:"#90a4ae",400:"#78909c",500:"#607d8b",600:"#546e7a",700:"#455a64",800:"#37474f",900:"#263238",A100:"#cfd8dc",A200:"#b0bec5",A400:"#78909c",A700:"#455a64",darkText:[50,100,200,300,"A100","A200","A300","A400"]},white:{50:"#fff",100:"#fff",200:"#fff",300:"#fff",400:"#fff",500:"#fff",600:"#fff",700:"#fff",800:"#fff",900:"#fff",A100:"#fff",A200:"#fff",A400:"#fff",A700:"#fff",darkText:[50,100,200,300,400,500,600,700,800,900,"A100","A200","A300","A400"]},black:{50:"#000",100:"#000",200:"#000",300:"#000",400:"#000",500:"#000",600:"#000",700:"#000",800:"#000",900:"#000",A100:"#000",A200:"#000",A400:"#000",A700:"#000",darkText:[]}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t,e){var n="",i="",o="",r=t.toString().match(/^#?(([0-9a-zA-Z]{3}){1,3})$/);if(!r)throw new Error("Invalid color"+t);if(t=r[1],6===t.length)n=parseInt(t.substring(0,2),16),i=parseInt(t.substring(2,4),16),o=parseInt(t.substring(4,6),16);else if(3===t.length){var a=t.substring(0,1),s=t.substring(1,2),d=t.substring(2,3);n=parseInt(a+a,16),i=parseInt(s+s,16),o=parseInt(d+d,16)}return e?(e>1&&(e/=100),"rgba("+n+", "+i+", "+o+", "+e+")"):"rgb("+n+", "+i+", "+o+")"},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=8,o=function(t,e){return e.top<=i-parseInt(getComputedStyle(t).marginTop,10)},r=function(t,e){return e.top+t.offsetHeight+i>=window.innerHeight-parseInt(getComputedStyle(t).marginTop,10)},a=function(t,e){return e.left<=i-parseInt(getComputedStyle(t).marginLeft,10)},s=function(t,e){return e.left+t.offsetWidth+i>=window.innerWidth-parseInt(getComputedStyle(t).marginLeft,10)},d=function(t,e){var n=getComputedStyle(t);return o(t,e)&&(e.top=i-parseInt(n.marginTop,10)),a(t,e)&&(e.left=i-parseInt(n.marginLeft,10)),s(t,e)&&(e.left=window.innerWidth-i-t.offsetWidth-parseInt(n.marginLeft,10)),r(t,e)&&(e.top=window.innerHeight-i-t.offsetHeight-parseInt(n.marginTop,10)),e};e.default=d,t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=function(t,e){var n=!1;return function(){n||(t.call(),n=!0,window.setTimeout((function(){n=!1}),e))}};e.default=i,t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={mixins:[r.default]},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={methods:{close:function(){this.$emit("close")}}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={props:{mdShift:Boolean},mixins:[r.default],computed:{classes:function(){return this.mdShift?"md-shift":"md-fixed"}},methods:{setActive:function(t){this.$children.forEach((function(e){e.active=e===t})),this.$emit("change",this.$children.findIndex((function(e){return e===t})))}}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{mdIcon:String,mdIconSrc:String,mdIconset:String,mdActive:Boolean,disabled:String,href:String},data:function(){return{active:!1}},computed:{classes:function(){return{"md-active":this.active}}},watch:{mdActive:function(t){this.setActive(t)}},methods:{setActive:function(t){t&&this.$parent.setActive(this)}},mounted:function(){if(!this.$parent.$el.classList.contains("md-bottom-bar"))throw this.$destroy(),new Error("You should wrap the md-bottom-bar-item in a md-bottom-bar");this.mdActive&&(this.active=!0)}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={props:{href:String,target:String,rel:String,type:{type:String,default:"button"},disabled:Boolean},mixins:[r.default],computed:{newRel:function(){return"_blank"===this.target?this.rel||"noopener":this.rel}}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o),a=void 0;e.default={props:{mdSingle:Boolean},mixins:[r.default],mounted:function(){var t=this;this.$children.forEach((function(e){var n=e.$el,i="md-toggle";a=function(){t.mdSingle?(t.$children.forEach((function(t){t.$el.classList.remove(i)})),n.classList.add(i)):n.classList.toggle(i)},n&&n.classList.contains("md-button")&&n.addEventListener("click",a)}))},beforeDestroy:function(){this.$children.forEach((function(t){var e=t.$el;e&&e.classList.contains("md-button")&&e.removeEventListener("click",a)}))}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={props:{mdWithHover:Boolean},mixins:[r.default],computed:{classes:function(){return{"md-with-hover":this.mdWithHover}}}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{mdInset:Boolean},computed:{classes:function(){return{"md-inset":this.mdInset}}}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={methods:{setContentMargin:function(){this.content.style.marginTop=-this.content.offsetHeight+"px"},toggle:function(){this.$refs.expand.classList.toggle("md-active")},onWindowResize:function(){window.requestAnimationFrame(this.setContentMargin)}},mounted:function(){var t=this;window.setTimeout((function(){t.trigger=t.$el.querySelector("[md-expand-trigger]"),t.content=t.$el.querySelector(".md-card-content"),t.content&&(t.setContentMargin(),t.trigger.addEventListener("click",t.toggle),window.addEventListener("resize",t.onWindowResize))}),200)},destroyed:function(){this.content&&(this.trigger.removeEventListener("click",this.toggle),window.removeEventListener("resize",this.onWindowResize))}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={mounted:function(){this.parentClasses=this.$parent.$el.classList,this.parentClasses.contains("md-card-header")&&(this.insideParent=!0,this.parentClasses.add("md-card-header-flex"))},destroyed:function(){this.parentClasses.remove("md-card-header-flex")}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{mdRatio:String,mdMedium:Boolean,mdBig:Boolean},computed:{classes:function t(){var t={"md-16-9":"16:9"===this.mdRatio||"16/9"===this.mdRatio,"md-4-3":"4:3"===this.mdRatio||"4/3"===this.mdRatio,"md-1-1":"1:1"===this.mdRatio||"1/1"===this.mdRatio};return(this.mdMedium||this.mdBig)&&(t={"md-medium":this.mdMedium,"md-big":this.mdBig}),t}}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(58),r=i(o);e.default={props:{mdTextScrim:Boolean,mdSolid:Boolean},data:function(){return{backdropBg:{}}},computed:{classes:function(){return{"md-text-scrim":this.mdTextScrim,"md-solid":this.mdSolid}},styles:function(){return{background:this.backdropBg}}},methods:{applyScrimColor:function(t){this.$refs.backdrop&&(this.backdropBg="linear-gradient(to bottom, rgba(0, 0, 0, 0) 20%, rgba(0, 0, 0, "+t/2+") 66%, rgba(0, 0, 0, "+t+") 100%)")},applySolidColor:function(t){var e=this.$el.querySelector(".md-card-area");e&&(e.style.background="rgba(0, 0, 0, "+t+")")}},mounted:function(){var t=this,e=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:.6;t.mdTextScrim?t.applyScrimColor(e):t.mdSolid&&t.applySolidColor(e)},n=this.$el.querySelector("img");n&&(this.mdTextScrim||this.mdSolid)&&(0,r.default)(n,(function(t){var n=256,i=(100*Math.abs(n-t)/n+15)/100;i>=.7&&(i=.7),e(i)}),e)}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={props:{name:String,value:[String,Boolean],id:String,disabled:Boolean},mixins:[r.default],data:function(){return{checked:this.value}},computed:{classes:function(){return{"md-checked":this.checked,"md-disabled":this.disabled}}},watch:{value:function(){this.checked=!!this.value}},methods:{toggleCheck:function(t){this.disabled||(this.checked=!this.checked,this.$emit("change",this.checked,t),this.$emit("input",this.checked,t))}}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={props:{disabled:Boolean,mdDeletable:Boolean},mixins:[r.default],computed:{classes:function(){return{"md-deletable":this.mdDeletable,"md-disabled":this.disabled}}}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o),a=n(48),s=i(a);e.default={props:{value:Array,disabled:Boolean,mdInputId:String,mdInputName:String,mdInputPlaceholder:String,mdInputType:{type:String,default:"text"},mdStatic:Boolean,mdMax:{type:Number,default:1/0}},mixins:[r.default],data:function(){return{currentChip:null,selectedChips:this.value,inputId:this.mdInputId||"chips-"+(0,s.default)()}},watch:{value:function(t){this.selectedChips=t}},computed:{classes:function(){return{"md-static":this.mdStatic,"md-disabled":this.disabled}}},methods:{applyInputFocus:function(){var t=this;this.$nextTick((function(){t.$refs.input.$el.focus()}))},addChip:function(){if(this.currentChip&&this.selectedChips.length<this.mdMax){var t=this.currentChip.trim();this.selectedChips.indexOf(t)<0&&(this.selectedChips.push(t),this.currentChip=null,this.$emit("input",this.selectedChips),this.$emit("change",this.selectedChips),this.applyInputFocus())}},deleteChip:function(t){var e=this.selectedChips.indexOf(t);e>=0&&this.selectedChips.splice(e,1),this.$emit("change",this.selectedChips),this.applyInputFocus()},deleteLastChip:function(){this.currentChip||(this.selectedChips.pop(),this.$emit("change",this.selectedChips),this.applyInputFocus())}}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o),a=n(39),s=i(a);e.default={props:{mdClickOutsideToClose:{type:Boolean,default:!0},mdEscToClose:{type:Boolean,default:!0},mdBackdrop:{type:Boolean,default:!0},mdOpenFrom:String,mdCloseTo:String,mdFullscreen:{type:Boolean,default:!1}},mixins:[r.default],data:function(){return{active:!1,transitionOff:!1,dialogTransform:""}},computed:{classes:function(){return{"md-active":this.active}},dialogClasses:function(){return{"md-fullscreen":this.mdFullscreen,"md-transition-off":this.transitionOff,"md-reference":this.mdOpenFrom||this.mdCloseTo}},styles:function(){return{transform:this.dialogTransform}}},methods:{removeDialog:function(){document.body.contains(this.dialogElement)&&this.$el.parentNode.removeChild(this.$el)},calculateDialogPos:function(t){var e=document.querySelector(t);if(e){var n=e.getBoundingClientRect(),i=this.dialogInnerElement.getBoundingClientRect(),o=n.width/i.width,r=n.height/i.height,a={top:-(i.top-n.top),left:-(i.left-n.left+n.width)};n.top>i.top+i.height&&(a.top=n.top-i.top),n.left>i.left+i.width&&(a.left=n.left-i.left-n.width),this.dialogTransform="translate3D("+a.left+"px, "+a.top+"px, 0) scale("+o+", "+r+")"}},open:function(){var t=this;document.body.appendChild(this.dialogElement),this.transitionOff=!0,this.calculateDialogPos(this.mdOpenFrom),window.setTimeout((function(){t.dialogElement.focus(),t.transitionOff=!1,t.active=!0})),this.$emit("open")},closeOnEsc:function(){this.mdEscToClose&&this.close()},close:function(){var t=this;document.body.contains(this.dialogElement)&&this.$nextTick((function(){var e=function e(){var n=t.dialogElement.querySelector(".md-ripple.md-active");n&&n.classList.remove("md-active"),t.dialogInnerElement.removeEventListener(s.default,e),document.body.removeChild(t.dialogElement),t.dialogTransform=""};t.transitionOff=!0,t.dialogTransform="",t.calculateDialogPos(t.mdCloseTo),window.setTimeout((function(){t.transitionOff=!1,t.active=!1,t.dialogInnerElement.addEventListener(s.default,e)})),t.$emit("close")}))}},mounted:function(){var t=this;this.$nextTick((function(){t.dialogElement=t.$el,t.dialogInnerElement=t.$refs.dialog,t.removeDialog()}))},beforeDestroy:function(){this.removeDialog()}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{mdTitle:String,mdContent:String,mdContentHtml:String,mdOkText:{type:String,default:"Ok"}},data:function(){return{debounce:!1}},methods:{fireCloseEvent:function(){this.debounce||this.$emit("close")},open:function(){this.$emit("open"),this.debounce=!1,this.$refs.dialog.open()},close:function(){this.fireCloseEvent(),this.debounce=!0,this.$refs.dialog.close()}},mounted:function(){if(!this.mdContent&&!this.mdContentHtml)throw new Error("Missing md-content or md-content-html attributes")}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{mdTitle:String,mdContent:String,mdContentHtml:String,mdOkText:{type:String,default:"Ok"},mdCancelText:{type:String,default:"Cancel"}},data:function(){return{debounce:!1}},methods:{fireCloseEvent:function(t){this.debounce||this.$emit("close",t)},open:function(){this.$emit("open"),this.debounce=!1,this.$refs.dialog.open()},close:function(t){this.fireCloseEvent(t),this.debounce=!0,this.$refs.dialog.close()}},mounted:function(){if(!this.mdContent&&!this.mdContentHtml)throw new Error("Missing md-content or md-content-html attributes")}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{value:{type:[String,Number],required:!0},mdTitle:String,mdContent:String,mdContentHtml:String,mdOkText:{type:String,default:"Ok"},mdCancelText:{type:String,default:"Cancel"},mdInputId:String,mdInputName:String,mdInputMaxlength:[String,Number],mdInputPlaceholder:String},data:function(){return{debounce:!1}},methods:{fireCloseEvent:function(t){this.debounce||this.$emit("close",t)},open:function(){var t=this;this.$emit("open"),this.debounce=!1,this.$refs.dialog.open(),window.setTimeout((function(){t.$refs.input.$el.focus()}))},close:function(t){this.fireCloseEvent(t),this.debounce=!0,this.$refs.dialog.close()},confirmValue:function(){this.$emit("input",this.$refs.input.$el.value),this.close("ok")}}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(60),r=i(o),a=n(12),s=i(a);e.default={props:{value:String,id:String,name:String,disabled:Boolean,required:Boolean,placeholder:String,accept:String,multiple:Boolean},data:function(){return{filename:this.value}},watch:{value:function(){this.filename=this.value}},methods:{getMultipleName:function(t){var e=[];return[].concat((0,r.default)(t)).forEach((function(t){e.push(t.name)})),e.join(", ")},openPicker:function(){this.disabled||(this.$refs.fileInput.click(),this.$refs.textInput.$el.focus())},onFileSelected:function(t){var e=t.target.files||t.dataTransfer.files;e?e.length>1?this.filename=this.getMultipleName(e):1===e.length?this.filename=e[0].name:this.filename=null:this.filename=t.target.value.split("\\").pop(),this.$emit("selected",e||t.target.value),this.$emit("input",this.filename)}},mounted:function(){if(this.parentContainer=(0,s.default)(this.$parent,"md-input-container"),!this.parentContainer)throw this.$destroy(),new Error("You should wrap the md-file in a md-input-container");this.parentContainer.hasFile=!0},beforeDestroy:function(){this.parentContainer.hasFile=!1}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o),a={};e.default={props:{mdSrc:String,mdIconset:{type:String,default:"material-icons"}},data:function(){return{svgContent:null,imageSrc:null}},mixins:[r.default],watch:{mdSrc:function(){this.svgContent=null,this.imageSrc=null,this.checkSrc()}},methods:{isImage:function(t){return t.indexOf("image")>=0},isSVG:function(t){return t.indexOf("svg")>=0},setSVGContent:function(t){var e=this;this.svgContent=t,this.$nextTick((function(){e.$el.children[0].removeAttribute("fill")}))},loadSVG:function(){var t=this;a[this.mdSrc]?this.setSVGContent(a[this.mdSrc]):!(function(){var e=new XMLHttpRequest,n=t;e.open("GET",t.mdSrc,!0),e.onload=function(){var t=this.getResponseHeader("content-type");this.status>=200&&this.status<400&&n.isImage(t)?n.isSVG(t)?(a[n.mdSrc]=this.response,n.setSVGContent(this.response)):n.loadImage():console.warn("The file "+n.mdSrc+" is not a valid image.")},e.send()})()},loadImage:function(){this.imageSrc=this.mdSrc},checkSrc:function(){this.mdSrc&&(this.mdSrc.indexOf(".svg")>=0?this.loadSVG():this.loadImage())}},mounted:function(){this.checkSrc()}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(58),r=i(o);e.default={props:{mdSrc:String},data:function(){return{loaded:!1,applyBlack:!0,imageElement:null}},watch:{mdSrc:function(){this.createImage()}},computed:{classes:function(){return{"md-loaded":this.loaded,"md-black-output":this.applyBlack}}},methods:{analyzeLightness:function(t){var e=this,n=function(){e.loaded=!0};(0,r.default)(t,(function(t){var i=256,o=(100*Math.abs(i-t)/i+15)/100;o>=.7&&(e.applyBlack=!0),e.$nextTick(n)}),n)},createImage:function(){this.loaded=!1,this.applyBlack=!1,this.imageElement=null,this.mdSrc&&(this.imageElement=document.createElement("img"),this.imageElement.crossOrigin="",this.imageElement.src=this.mdSrc,this.analyzeLightness(this.imageElement))}},created:function(){this.createImage()}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(62),r=i(o),a=n(12),s=i(a);e.default={mixins:[r.default],props:{type:{type:String,default:"text"}},mounted:function(){var t=this;this.$nextTick((function(){if(t.parentContainer=(0,s.default)(t.$parent,"md-input-container"),!t.parentContainer)throw t.$destroy(),new Error("You should wrap the md-input in a md-input-container");t.setParentDisabled(),t.setParentRequired(),t.setParentPlaceholder(),t.handleMaxLength(),t.updateValues()}))}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o),a=n(59),s=i(a);e.default={props:{mdInline:Boolean,mdHasPassword:Boolean},mixins:[r.default],data:function(){return{value:"",input:!1,showPassword:!1,enableCounter:!1,hasSelect:!1,hasPlaceholder:!1,hasFile:!1,isDisabled:!1,isRequired:!1,isFocused:!1,counterLength:0,inputLength:0}},computed:{hasValue:function(){return(0,s.default)(this.value)?this.value.length>0:Boolean(this.value)},classes:function(){return{"md-input-inline":this.mdInline,"md-has-password":this.mdHasPassword,"md-has-select":this.hasSelect,"md-has-file":this.hasFile,"md-has-value":this.hasValue,"md-input-placeholder":this.hasPlaceholder,"md-input-disabled":this.isDisabled,"md-input-required":this.isRequired,"md-input-focused":this.isFocused}}},methods:{isInput:function(){return this.input&&"input"===this.input.tagName.toLowerCase()},
  738. togglePasswordType:function(){this.isInput()&&("password"===this.input.type?(this.input.type="text",this.showPassword=!0):(this.input.type="password",this.showPassword=!1),this.input.focus())},setValue:function(t){this.value=t}},mounted:function(){if(this.input=this.$el.querySelectorAll("input, textarea, select, .md-file")[0],!this.input)throw this.$destroy(),new Error("Missing input/select/textarea inside md-input-container")}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(122),r=i(o),a=n(62),s=i(a),d=n(12),l=i(d);e.default={mixins:[s.default],watch:{value:function(){var t=this;this.$nextTick((function(){r.default.update(t.$el)}))}},mounted:function(){var t=this;this.$nextTick((function(){if(t.parentContainer=(0,l.default)(t.$parent,"md-input-container"),!t.parentContainer)throw t.$destroy(),new Error("You should wrap the md-textarea in a md-input-container");t.setParentDisabled(),t.setParentRequired(),t.setParentPlaceholder(),t.handleMaxLength(),t.updateValues(),t.$el.getAttribute("rows")||t.$el.setAttribute("rows","1"),(0,r.default)(t.$el)}))},beforeDestroy:function(){r.default.destroy(this.$el)}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{mdTag:{type:String,default:"div"},mdRow:Boolean,mdRowXsmall:Boolean,mdRowSmall:Boolean,mdRowMedium:Boolean,mdRowLarge:Boolean,mdRowXlarge:Boolean,mdColumn:Boolean,mdColumnXsmall:Boolean,mdColumnSmall:Boolean,mdColumnMedium:Boolean,mdColumnLarge:Boolean,mdColumnXlarge:Boolean,mdHideXsmall:Boolean,mdHideSmall:Boolean,mdHideMedium:Boolean,mdHideLarge:Boolean,mdHideXlarge:Boolean,mdHideXsmallAndUp:Boolean,mdHideSmallAndUp:Boolean,mdHideMediumAndUp:Boolean,mdHideLargeAndUp:Boolean,mdHideXlargeAndUp:Boolean,mdGutter:[String,Number,Boolean],mdAlign:String,mdAlignXsmall:String,mdAlignSmall:String,mdAlignMedium:String,mdAlignLarge:String,mdAlignXlarge:String,mdFlex:[String,Number,Boolean],mdFlexXsmall:[String,Number,Boolean],mdFlexSmall:[String,Number,Boolean],mdFlexMedium:[String,Number,Boolean],mdFlexLarge:[String,Number,Boolean],mdFlexXlarge:[String,Number,Boolean],mdFlexOffset:[String,Number,Boolean],mdFlexOffsetXsmall:[String,Number,Boolean],mdFlexOffsetSmall:[String,Number,Boolean],mdFlexOffsetMedium:[String,Number,Boolean],mdFlexOffsetLarge:[String,Number,Boolean],mdFlexOffsetXlarge:[String,Number,Boolean]},computed:{classes:function t(){var t={"md-row":this.mdRow,"md-row-xsmall":this.mdRowXsmall,"md-row-small":this.mdRowSmall,"md-row-medium":this.mdRowMedium,"md-row-large":this.mdRowLarge,"md-row-xlarge":this.mdRowXlarge,"md-column":this.mdColumn,"md-column-xsmall":this.mdColumnXsmall,"md-column-small":this.mdColumnSmall,"md-column-medium":this.mdColumnMedium,"md-column-large":this.mdColumnLarge,"md-column-xlarge":this.mdColumnXlarge,"md-hide-xsmall":this.mdHideXsmall,"md-hide-small":this.mdHideSmall,"md-hide-medium":this.mdHideMedium,"md-hide-large":this.mdHideLarge,"md-hide-xlarge":this.mdHideXlarge,"md-hide-xsmall-and-up":this.mdHideXsmallAndUp,"md-hide-small-and-up":this.mdHideSmallAndUp,"md-hide-medium-and-up":this.mdHideMediumAndUp,"md-hide-large-and-up":this.mdHideLargeAndUp,"md-hide-xlarge-and-up":this.mdHideXlargeAndUp};return this.mdGutter&&("boolean"==typeof this.mdGutter?t["md-gutter"]=!0:this.mdGutter&&(t["md-gutter-"+this.mdGutter]=!0)),this.generatePropClasses("md-flex","","mdFlex",t),this.generatePropClasses("md-flex","xsmall","mdFlexXsmall",t),this.generatePropClasses("md-flex","small","mdFlexSmall",t),this.generatePropClasses("md-flex","medium","mdFlexMedium",t),this.generatePropClasses("md-flex","large","mdFlexLarge",t),this.generatePropClasses("md-flex","xlarge","mdFlexXlarge",t),this.generatePropClasses("md-flex-offset","","mdFlexOffset",t),this.generatePropClasses("md-flex-offset","xsmall","mdFlexOffsetXsmall",t),this.generatePropClasses("md-flex-offset","small","mdFlexOffsetSmall",t),this.generatePropClasses("md-flex-offset","medium","mdFlexOffsetMedium",t),this.generatePropClasses("md-flex-offset","large","mdFlexOffsetLarge",t),this.generatePropClasses("md-flex-offset","xlarge","mdFlexOffsetXlarge",t),this.generatePropClasses("md-align","","mdAlign",t),this.generatePropClasses("md-align","xsmall","mdAlignXsmall",t),this.generatePropClasses("md-align","small","mdAlignSmall",t),this.generatePropClasses("md-align","medium","mdAlignMedium",t),this.generatePropClasses("md-align","large","mdAlignLarge",t),this.generatePropClasses("md-align","xlarge","mdAlignXlarge",t),t}},methods:{generatePropClasses:function(t,e,n,i){e&&(e="-"+e),this[n]&&("boolean"==typeof this[n]?this[n]?i[t+e]=!0:i[t+e+"-none"]=!0:i[t+e+"-"+this[n]]=!0)}},render:function(t){return t(this.mdTag,{staticClass:"md-layout",class:this.classes},this.$slots.default)}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={mixins:[r.default]},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={name:"md-list-item",props:{disabled:Boolean},computed:{classes:function(){return{"md-disabled":this.disabled}}}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={name:"md-list-item"},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(12),r=i(o);e.default={name:"md-list-item",props:{disabled:Boolean,mdExpandMultiple:Boolean},data:function(){return{parentList:!1,active:!1,height:0,contentObserver:null,transitionOff:!0}},computed:{classes:function(){return{"md-disabled":this.disabled,"md-active":this.active}},expandClasses:function(){return{"md-transition-off":this.transitionOff}},expandStyles:function(){return{"margin-bottom":this.height}}},methods:{resetSiblings:function(){var t=this;this.parentList.$children.forEach((function(e){e.$el!==t.$el&&e.$el.classList.contains("md-list-item-expand")&&(e.active=!1)}))},calculatePadding:function(){var t=this;window.requestAnimationFrame((function(){t.height=-t.$el.scrollHeight+"px",window.setTimeout((function(){t.transitionOff=!1}))}))},toggleExpandList:function(){this.mdExpandMultiple||this.resetSiblings(),this.calculatePadding(),this.active=!this.active},recalculateAfterChange:function(){this.transitionOff=!0,this.calculatePadding()},observeChildChanges:function(){this.contentObserver=new MutationObserver(this.recalculateAfterChange),this.contentObserver.observe(this.$refs.expand,{childList:!0,characterData:!0,subtree:!0})}},mounted:function(){var t=this;this.$nextTick((function(){t.parentList=(0,r.default)(t.$parent,"md-list"),t.calculatePadding(),t.observeChildChanges(),window.addEventListener("resize",t.recalculateAfterChange)}))},beforeDestroy:function(){this.contentObserver&&this.contentObserver.disconnect(),window.removeEventListener("resize",this.recalculateAfterChange)}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={name:"md-list-item",props:{href:String,target:String,disabled:Boolean},computed:{classes:function(){return{"md-disabled":this.disabled}}}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={name:"md-list-item",props:{disabled:Boolean},computed:{classes:function(){return{"md-disabled":this.disabled}}}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(39),r=i(o),a=n(129),s=i(a);e.default={props:{mdSize:{type:[Number,String],default:0},mdDirection:{type:String,default:"bottom right"},mdAlignTrigger:{type:Boolean,default:!1},mdOffsetX:{type:[Number,String],default:0},mdOffsetY:{type:[Number,String],default:0},mdCloseOnSelect:{type:Boolean,default:!0}},data:function(){return{active:!1}},watch:{mdSize:function(t,e){t>=1&&t<=7&&(this.removeLastSizeMenuContentClass(e),this.addNewSizeMenuContentClass(t))},mdDirection:function(t,e){this.removeLastDirectionMenuContentClass(e),this.addNewDirectionMenuContentClass(t)},mdAlignTrigger:function(t){this.handleAlignTriggerClass(t)}},methods:{validateMenu:function(){if(!this.menuContent)throw this.$destroy(),new Error("You must have a md-menu-content inside your menu.");if(!this.menuTrigger)throw this.$destroy(),new Error("You must have an element with a md-menu-trigger attribute inside your menu.")},removeLastSizeMenuContentClass:function(t){this.menuContent.classList.remove("md-size-"+t)},removeLastDirectionMenuContentClass:function(t){this.menuContent.classList.remove("md-direction-"+t.replace(/ /g,"-"))},addNewSizeMenuContentClass:function(t){this.menuContent.classList.add("md-size-"+t)},addNewDirectionMenuContentClass:function(t){this.menuContent.classList.add("md-direction-"+t.replace(/ /g,"-"))},handleAlignTriggerClass:function(t){t&&this.menuContent.classList.add("md-align-trigger")},getPosition:function(t,e){var n=this.menuTrigger.getBoundingClientRect(),i="top"===t?n.top+n.height-this.menuContent.offsetHeight:n.top,o="left"===e?n.left-this.menuContent.offsetWidth+n.width:n.left;return i+=parseInt(this.mdOffsetY,10),o+=parseInt(this.mdOffsetX,10),this.mdAlignTrigger&&("top"===t?i-=n.height+11:i+=n.height+11),{top:i,left:o}},calculateMenuContentPos:function(){var t=void 0;t=this.mdDirection?this.getPosition.apply(this,this.mdDirection.trim().split(" ")):this.getPosition("bottom","right"),t=(0,s.default)(this.menuContent,t),this.menuContent.style.top=t.top+window.pageYOffset+"px",this.menuContent.style.left=t.left+window.pageXOffset+"px"},recalculateOnResize:function(){window.requestAnimationFrame(this.calculateMenuContentPos)},open:function(){document.body.contains(this.menuContent)&&document.body.removeChild(this.menuContent),document.body.appendChild(this.menuContent),document.body.appendChild(this.backdropElement),window.addEventListener("resize",this.recalculateOnResize),this.calculateMenuContentPos(),getComputedStyle(this.menuContent).top,this.menuContent.classList.add("md-active"),this.menuContent.focus(),this.active=!0,this.$emit("open")},close:function t(){var e=this,t=function t(n){if(e.menuContent&&n.target===e.menuContent){var i=e.menuContent.querySelector(".md-ripple.md-active");e.menuContent.removeEventListener(r.default,t),e.menuTrigger.focus(),e.active=!1,i&&i.classList.remove("md-active"),document.body.removeChild(e.menuContent),document.body.removeChild(e.backdropElement),window.removeEventListener("resize",e.recalculateOnResize)}};this.menuContent.addEventListener(r.default,t),this.menuContent.classList.remove("md-active"),this.$emit("close")},toggle:function(){this.active?this.close():this.open()}},mounted:function(){var t=this;this.$nextTick((function(){t.menuTrigger=t.$el.querySelector("[md-menu-trigger]"),t.menuContent=t.$el.querySelector(".md-menu-content"),t.backdropElement=t.$refs.backdrop.$el,t.validateMenu(),t.handleAlignTriggerClass(t.mdAlignTrigger),t.addNewSizeMenuContentClass(t.mdSize),t.addNewDirectionMenuContentClass(t.mdDirection),t.$el.removeChild(t.$refs.backdrop.$el),t.menuContent.parentNode.removeChild(t.menuContent),t.menuTrigger.addEventListener("click",t.toggle)}))},beforeDestroy:function(){document.body.contains(this.menuContent)&&(document.body.removeChild(this.menuContent),document.body.removeChild(this.backdropElement)),this.menuTrigger.removeEventListener("click",this.toggle),window.removeEventListener("resize",this.recalculateOnResize)}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={data:function(){return{oldHighlight:!1,highlighted:!1,itemsAmount:0}},methods:{close:function(){this.highlighted=!1,this.$parent.close()},highlightItem:function(t){this.oldHighlight=this.highlighted,"up"===t&&(1===this.highlighted?this.highlighted=this.itemsAmount:this.highlighted--),"down"===t&&(this.highlighted===this.itemsAmount?this.highlighted=1:this.highlighted++)},fireClick:function(){this.highlighted>0&&this.$children[0].$children[this.highlighted-1].$el.click()}},mounted:function(){if(!this.$parent.$el.classList.contains("md-menu"))throw this.$destroy(),new Error("You must wrap the md-menu-content in a md-menu")}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(12),r=i(o);n(199),e.default={props:{href:String,target:String,disabled:Boolean},data:function(){return{parentContent:{},index:0}},computed:{classes:function(){return{"md-highlighted":this.highlighted}},highlighted:function(){return this.index===this.parentContent.highlighted&&(this.disabled&&(this.parentContent.oldHighlight>this.parentContent.highlighted?this.parentContent.highlighted--:this.parentContent.highlighted++),1===this.index?this.parentContent.$el.scrollTop=0:this.index===this.parentContent.itemsAmount?this.parentContent.$el.scrollTop=this.parentContent.$el.scrollHeight:this.$el.scrollIntoViewIfNeeded(!1),!0)}},methods:{close:function(t){this.disabled||(this.parentMenu.mdCloseOnSelect&&this.parentContent.close(),this.$emit("selected",t))}},mounted:function(){if(this.parentContent=(0,r.default)(this.$parent,"md-menu-content"),this.parentMenu=(0,r.default)(this.$parent,"md-menu"),!this.parentContent)throw this.$destroy(),new Error("You must wrap the md-menu-item in a md-menu-content");this.parentContent.itemsAmount++,this.index=this.parentContent.itemsAmount}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={props:{mdIndeterminate:Boolean,mdProgress:{type:Number,default:0}},mixins:[r.default],computed:{classes:function(){return{"md-indeterminate":this.mdIndeterminate}},styles:function(){if(!this.mdIndeterminate)return{width:this.mdProgress+"%"}}}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={props:{name:String,id:String,value:[String,Boolean,Number],mdValue:{type:[String,Boolean,Number],required:!0},disabled:Boolean},mixins:[r.default],computed:{classes:function(){return{"md-checked":"undefined"!=typeof this.value&&this.mdValue.toString()===this.value.toString(),"md-disabled":this.disabled}}},methods:{toggleCheck:function(t){this.disabled||(this.$emit("change",this.mdValue,t),this.$emit("input",this.mdValue,t))}}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(12),r=i(o);e.default={props:{value:[String,Boolean,Number]},data:function(){return{parentSelect:{},check:!1,index:0}},computed:{isSelected:function(){if(this.value&&this.parentSelect.value){var t=this.value.toString();return this.parentSelect.multiple?this.parentSelect.value.indexOf(t)>=0:this.value&&this.parentSelect.value&&t===this.parentSelect.value.toString()}return!1},classes:function(){return{"md-selected":this.isSelected,"md-checked":this.check}}},methods:{isMultiple:function(){return this.parentSelect.multiple},setParentOption:function(){this.isMultiple()?this.check=!this.check:this.parentSelect.selectOption(this.value,this.$refs.item.textContent)},selectOption:function(t){this.setParentOption(),this.$emit("selected",t)}},watch:{isSelected:function(t){this.isMultiple()&&(this.check=t)},check:function(t){t?this.parentSelect.selectMultiple(this.index,this.value,this.$refs.item.textContent):this.parentSelect.selectMultiple(this.index)}},mounted:function(){if(this.parentSelect=(0,r.default)(this.$parent,"md-select"),this.parentContent=(0,r.default)(this.$parent,"md-menu-content"),!this.parentSelect)throw new Error("You must wrap the md-option in a md-select");this.parentSelect.optionsAmount++,this.index=this.parentSelect.optionsAmount,this.parentSelect.multipleOptions[this.index]={},this.parentSelect.options[this.index]=this,(this.isMultiple()&&this.parentSelect.value.indexOf(this.value)>=0||this.parentSelect.value===this.value)&&this.setParentOption()},beforeDestroy:function(){this.parentSelect&&(delete this.parentSelect.options[this.index],delete this.parentSelect.multipleOptions[this.index])}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(61),r=i(o),a=n(40),s=i(a),d=n(1),l=i(d),c=n(12),u=i(c),m=n(59),f=i(m);e.default={props:{name:String,id:String,required:Boolean,multiple:Boolean,value:[String,Number,Array],disabled:Boolean,placeholder:String,mdMenuClass:String},mixins:[l.default],data:function(){return{selectedValue:null,selectedText:null,multipleOptions:{},options:{},optionsAmount:0}},computed:{classes:function(){return{"md-disabled":this.disabled}},contentClasses:function(){return this.multiple?"md-multiple "+this.mdMenuClass:this.mdMenuClass}},watch:{value:function(t){this.setTextAndValue(t)},disabled:function(){this.setParentDisabled()},required:function(){this.setParentRequired()},placeholder:function(){this.setParentPlaceholder()}},methods:{setParentDisabled:function(){this.parentContainer.isDisabled=this.disabled},setParentRequired:function(){this.parentContainer.isRequired=this.required},setParentPlaceholder:function(){this.parentContainer.hasPlaceholder=!!this.placeholder},getSingleValue:function(t){var e=this,n={};return(0,s.default)(this.options).forEach((function(i){var o=e.options[i];o.value===t&&(n.value=t,n.text=o.$refs.item.textContent)})),n},getMultipleValue:function(t){var e=this;if((0,f.default)(this.value)){var n=(function(){var n=[];return t.forEach((function(t){(0,s.default)(e.options).forEach((function(i){var o=e.options[i];if(o.value===t){var r=o.$refs.item.textContent;e.multipleOptions[i]={value:t,text:r},n.push(r)}}))})),{v:{value:t,text:n.join(", ")}}})();if("object"===("undefined"==typeof n?"undefined":(0,r.default)(n)))return n.v}return{}},setTextAndValue:function(t){var e=this.multiple?this.getMultipleValue(t):this.getSingleValue(t);this.selectedValue=e.value,this.selectedText=e.text,this.parentContainer&&this.parentContainer.setValue(this.selectedText)},changeValue:function(t){this.$emit("input",t),this.$emit("change",t),this.$emit("selected",t)},selectMultiple:function(t,e,n){var i=[];this.multipleOptions[t]={value:e,text:n};for(var o in this.multipleOptions)this.multipleOptions.hasOwnProperty(o)&&this.multipleOptions[o].value&&i.push(this.multipleOptions[o].value);this.changeValue(i)},selectOption:function(t,e){this.selectedText=e,this.setTextAndValue(t),this.changeValue(t)}},mounted:function(){this.parentContainer=(0,u.default)(this.$parent,"md-input-container"),this.parentContainer&&(this.setParentDisabled(),this.setParentRequired(),this.setParentPlaceholder(),this.parentContainer.hasSelect=!0),this.setTextAndValue(this.value)},beforeDestroy:function(){this.parentContainer&&(this.parentContainer.setValue(""),this.parentContainer.hasSelect=!1)}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={data:function(){return{mdVisible:!1}},mixins:[r.default],props:{mdSwipeable:Boolean,mdSwipeThreshold:{type:Number,default:15},mdSwipeDistance:{type:Number,default:100}},computed:{classes:function(){return this.mdVisible&&"md-active"}},methods:{show:function(){this.open()},open:function(){this.mdVisible=!0,this.$el.focus(),this.$emit("open")},close:function(){this.mdVisible=!1,this.$el.blur(),this.$emit("close")},toggle:function(){this.mdVisible?this.close():this.open()},isHorizontallyInside:function(t){return t>0&&t<this.mountedRect.left+this.mountedRect.width},isVerticallyInside:function(t){return t>0&&t<this.mountedRect.top+this.mountedRect.height},isFromStartWhenClosed:function(t){return!!this.mdVisible||t<this.mdSwipeThreshold},handleTouchStart:function(t){var e=t.touches[0].clientX-this.mountedRect.left,n=t.touches[0].clientY-this.mountedRect.top;this.isHorizontallyInside(e)&&this.isVerticallyInside(n)&&this.isFromStartWhenClosed(e)&&(this.initialTouchPosition=e,this.canMove=!0)},handleTouchEnd:function(){this.canMove=!1,this.initialTouchPosition=null},handleTouchMove:function(t){if(this.canMove){var e=t.touches[0].clientX,n=this.mdVisible?this.initialTouchPosition-e:e-this.initialTouchPosition,i=this.mdVisible?"close":"open";n>this.mdSwipeDistance&&this[i]()}}},mounted:function(){this.mdSwipeable&&(this.mountedRect=this.$refs.backdrop.$el.getBoundingClientRect(),this.initialTouchPosition=null,this.canMove=!1,document.addEventListener("touchstart",this.handleTouchStart),document.addEventListener("touchend",this.handleTouchEnd),document.addEventListener("touchmove",this.handleTouchMove))},beforeDestroy:function(){this.mdSwipeable&&(document.removeEventListener("touchstart",this.handleTouchStart),document.removeEventListener("touchend",this.handleTouchEnd),document.removeEventListener("touchmove",this.handleTouchMove))}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(48),r=i(o),a=n(39),s=i(a),d=n(1),l=i(d),c=n(124),u=i(c);e.default={props:{id:[String,Number],mdPosition:{type:String,default:"bottom center"},mdDuration:{type:[String,Number],default:4e3}},mixins:[l.default],data:function(){return{snackbarId:this.id||"snackbar-"+(0,r.default)(),active:!1,rootElement:{},snackbarElement:{},directionClass:null,closeTimeout:null}},computed:{classes:function(){var t={"md-active":this.active};return this.directionClass=this.mdPosition.replace(/ /g,"-"),t["md-position-"+this.directionClass]=!0,t}},watch:{active:function(t){var e="md-has-toast-"+this.directionClass,n="md-has-toast";t?(document.body.classList.add(e),document.body.classList.add(n)):(document.body.classList.remove(e),document.body.classList.remove(n))}},methods:{removeElement:function(){if(document.body.contains(this.snackbarElement)){var t=this.snackbarElement.querySelector(".md-ripple.md-active");t&&t.classList.remove("md-active"),document.body.removeChild(this.snackbarElement)}},open:function(){u.default.current&&u.default.current.close(),u.default.current=this,document.body.appendChild(this.snackbarElement),window.getComputedStyle(this.$refs.container).backgroundColor,this.active=!0,this.$emit("open"),this.closeTimeout=window.setTimeout(this.close,this.mdDuration),this.timeoutStartedAt=Date.now()},close:function(){var t=this;this.$refs.container&&!(function(){var e=function e(){t.$refs.container.removeEventListener(s.default,e),t.removeElement()};u.default.current=null,t.active=!1,t.$emit("close"),t.$refs.container.removeEventListener(s.default,e),t.$refs.container.addEventListener(s.default,e),window.clearTimeout(t.closeTimeout),t.pendingDuration=t.mdDuration})()},pauseTimeout:function(){this.pendingDuration=this.pendingDuration-(Date.now()-this.timeoutStartedAt),this.timeoutStartedAt=0,window.clearTimeout(this.closeTimeout)},resumeTimeout:function(){this.timeoutStartedAt=Date.now(),this.closeTimeout=window.setTimeout(this.close,this.pendingDuration)}},mounted:function(){var t=this;this.$nextTick((function(){t.snackbarElement=t.$el,t.snackbarElement.parentNode.removeChild(t.snackbarElement),t.timeoutStartedAt=0,t.pendingDuration=t.mdDuration}))},beforeDestroy:function(){window.clearTimeout(this.closeTimeout),this.removeElement()}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={props:{mdOpen:{type:String,default:"click"},mdMode:{type:String,default:"fling"},mdDirection:{type:String,default:"top"}},mixins:[r.default],data:function(){return{fabTrigger:null,active:!1}},computed:{classes:function t(){var t={"md-active":this.active};return t["md-mode-"+this.mdMode]=!0,t["md-direction-"+this.mdDirection]=!0,t}},methods:{closeSpeedDial:function(t){!t.target!==this.fabTrigger&&this.fabTrigger.contains(t.target)||(this.active=!1,document.body.removeEventListener("click",this.closeSpeedDial))},toggleSpeedDial:function(){var t=this;this.active=!this.active,window.setTimeout((function(){document.body.addEventListener("click",t.closeSpeedDial)}),50)}},mounted:function(){var t=this;this.$nextTick((function(){t.fabTrigger=t.$el.querySelector("[md-fab-trigger]"),"click"===t.mdOpen?t.fabTrigger.addEventListener("click",t.toggleSpeedDial):(t.$el.addEventListener("mouseenter",t.toggleSpeedDial),t.$el.addEventListener("mouseleave",t.toggleSpeedDial))}))},beforeDestroy:function(){this.fabTrigger.removeEventListener("click",this.toggleSpeedDial),document.body.removeEventListener("click",this.closeSpeedDial)}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={props:{mdSize:{type:Number,default:50},mdStroke:{type:Number,default:3.5},mdIndeterminate:Boolean,mdProgress:{type:Number,default:0}},mixins:[r.default],computed:{classes:function(){return{"md-indeterminate":this.mdIndeterminate}},styles:function(){var t=this.mdSize+"px";return{width:t,height:t}},dashProgress:function(){var t=125*this.mdProgress/100;return!this.mdIndeterminate&&(t>=125&&(t=130),t+", 200")}}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={mixins:[r.default]},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o),a=75,s="-1px";e.default={props:{name:String,value:Boolean,id:String,disabled:Boolean,type:{type:String,default:"button"}},mixins:[r.default],data:function(){return{leftPos:s,checked:this.value}},computed:{classes:function(){return{"md-checked":Boolean(this.value),"md-disabled":this.disabled}},styles:function(){return{transform:"translate3D("+this.leftPos+", -50%, 0)"}}},watch:{checked:function(){this.setPosition()},value:function(t){this.changeState(t)}},methods:{setPosition:function(){this.leftPos=this.checked?a+"%":s},changeState:function(t,e){"undefined"!=typeof e?(this.$emit("change",e),e.defaultPrevented||(this.checked=t),this.$emit("input",this.checked,e)):this.checked=t},toggle:function(t){this.disabled||this.changeState(!this.checked,t)}},mounted:function(){this.$nextTick(this.setPosition)}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(40),r=i(o),a=n(1),s=i(a),d=n(12),l=i(d);e.default={props:{mdSortType:String,mdSort:String},mixins:[s.default],data:function(){return{sortType:this.mdSortType,sortBy:this.mdSort,hasRowSelection:!1,data:[],numberOfRows:0,numberOfSelected:0,selectedRows:{}}},methods:{emitSort:function(t){this.sortBy=t,this.$emit("sort",{name:t,type:this.sortType})},emitSelection:function(){this.$emit("select",this.selectedRows)}},watch:{data:function(){this.numberOfRows=this.data.length},selectedRows:function(){this.numberOfSelected=(0,r.default)(this.selectedRows).length}},mounted:function(){this.parentCard=(0,l.default)(this.$parent,"md-table-card"),this.parentCard&&(this.parentCard.tableInstance=this)}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o),a=n(12),s=i(a);e.default={props:{mdSelectedLabel:{type:String,default:"selected"}},mixins:[r.default],data:function(){return{classes:{},tableInstance:{}}},mounted:function(){var t=this;this.parentCard=(0,s.default)(this.$parent,"md-table-card"),this.$nextTick((function(){t.tableInstance=t.parentCard.tableInstance,t.$watch("tableInstance.numberOfSelected",(function(){t.$refs.counter.textContent=t.tableInstance.numberOfSelected,t.classes={"md-active":t.tableInstance.numberOfSelected>0}}))}))}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={mixins:[r.default]},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{mdNumeric:Boolean},data:function(){return{hasAction:!1}},computed:{classes:function(){return{"md-numeric":this.mdNumeric,"md-has-action":this.hasAction}}},mounted:function(){this.$children.length>0&&(this.hasAction=!0)}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{value:[String,Number],mdLarge:Boolean,mdId:String,mdName:String,mdPlaceholder:String,mdMaxlength:[Number,String]},data:function(){return{active:!1}},computed:{triggerClasses:function(){return{"md-edited":this.value}},dialogClasses:function(){return{"md-active":this.active,"md-large":this.mdLarge}},realValue:function(){console.log(this.value)}},methods:{openDialog:function(){this.active=!0,this.$refs.input.$el.focus(),document.addEventListener("click",this.closeDialogOnOffClick)},closeDialog:function(){this.active&&(this.active=!1,this.$refs.input.$el.blur(),document.removeEventListener("click",this.closeDialogOnOffClick))},closeDialogOnOffClick:function(t){this.$refs.dialog.contains(t.target)||this.closeDialog()},confirmDialog:function(){var t=this.$refs.input.$el.value;this.closeDialog(),this.$emit("input",t),this.$emit("edited",t)}}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(12),r=i(o);e.default={props:{mdNumeric:Boolean,mdSortBy:String,mdTooltip:String},data:function(){return{sortType:null,sorted:!1,parentTable:{}}},computed:{classes:function(){var t=this.hasMatchSort();return t||(this.sorted=!1),{"md-numeric":this.mdNumeric,"md-sortable":this.mdSortBy,"md-sorted":t&&this.sorted,"md-sorted-descending":t&&"desc"===this.sortType}}},methods:{hasMatchSort:function(){return this.parentTable.sortBy===this.mdSortBy},changeSort:function(){this.mdSortBy&&("asc"===this.sortType&&this.sorted?this.sortType="desc":this.sortType="asc",this.sorted=!0,this.parentTable.sortType=this.sortType,this.parentTable.emitSort(this.mdSortBy))}},mounted:function(){this.parentTable=(0,r.default)(this.$parent,"md-table"),this.hasMatchSort()&&(this.sorted=!0,this.sortType=this.parentTable.sortType)}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(191),r=i(o);e.default={props:{mdSize:{type:[Number,String],default:10},mdPageOptions:[Array,Boolean],mdPage:{type:[Number,String],default:1},mdTotal:{type:[Number,String],default:"Many"},mdLabel:{type:String,default:"Rows per page"},mdSeparator:{type:String,default:"of"}},data:function(){return{subTotal:0,currentSize:parseInt(this.mdSize,10),currentPage:parseInt(this.mdPage,10),totalItems:isNaN(this.mdTotal)?r.default:parseInt(this.mdTotal,10)}},computed:{lastPage:function(){return!1}},methods:{emitPaginationEvent:function(){if(this.canFireEvents){var t=this.currentPage*this.currentSize;this.subTotal=t>this.mdTotal?this.mdTotal:t,this.$emit("pagination",{size:this.currentSize,page:this.currentPage})}},changeSize:function(){this.canFireEvents&&(this.$emit("size",this.currentSize),this.emitPaginationEvent())},previousPage:function(){this.canFireEvents&&(this.currentPage--,this.$emit("page",this.currentPage),this.emitPaginationEvent())},nextPage:function(){this.canFireEvents&&(this.currentPage++,this.$emit("page",this.currentPage),this.emitPaginationEvent())}},mounted:function(){var t=this;this.$nextTick((function(){
  739. t.subTotal=t.currentPage*t.currentSize,t.mdPageOptions=t.mdPageOptions||[10,25,50,100],t.currentSize=t.mdPageOptions[0],t.canFireEvents=!0}))}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(12),r=i(o),a="md-transition-off";e.default={props:{mdAutoSelect:Boolean,mdSelection:Boolean,mdItem:Object},data:function(){return{parentTable:{},headRow:!1,checkbox:!1,index:0}},computed:{isDisabled:function(){return!this.mdSelection&&!this.headRow},hasSelection:function(){return this.mdSelection||this.headRow&&this.parentTable.hasRowSelection},classes:function(){return{"md-selected":this.checkbox}}},watch:{mdItem:function(t,e){this.parentTable.data[this.index]=this.mdItem,this.handleMultipleSelection(t===e)}},methods:{setSelectedRow:function(t,e){t?(this.parentTable.selectedRows[e]=this.parentTable.data[e],++this.parentTable.numberOfSelected):(delete this.parentTable.selectedRows[e],--this.parentTable.numberOfSelected)},handleSingleSelection:function(t){this.setSelectedRow(t,this.index-1),this.parentTable.$children[0].checkbox=this.parentTable.numberOfSelected===this.parentTable.numberOfRows},handleMultipleSelection:function(t){var e=this;this.parentTable.numberOfRows>25&&this.parentTable.$el.classList.add(a),this.parentTable.$children.forEach((function(n,i){n.checkbox=t,n.headRow||e.setSelectedRow(t,i-1)})),t?this.parentTable.numberOfSelected=this.parentTable.numberOfRows:this.parentTable.numberOfSelected=0,window.setTimeout((function(){return e.parentTable.$el.classList.remove(a)}))},select:function(t){this.hasSelection&&(this.headRow?this.handleMultipleSelection(t):this.handleSingleSelection(t),this.parentTable.emitSelection())},autoSelect:function(){this.mdAutoSelect&&this.hasSelection&&(this.checkbox=!this.checkbox,this.handleSingleSelection(this.checkbox),this.parentTable.emitSelection())}},mounted:function(){this.parentTable=(0,r.default)(this.$parent,"md-table"),"thead"===this.$el.parentNode.tagName.toLowerCase()?this.headRow=!0:(this.parentTable.numberOfRows++,this.index=this.parentTable.numberOfRows,this.mdSelection&&(this.parentTable.hasRowSelection=!0),this.mdItem&&this.parentTable.data.push(this.mdItem))}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(48),r=i(o),a=n(12),s=i(a);e.default={props:{id:[String,Number],mdLabel:[String,Number],mdIcon:String,mdActive:Boolean,mdDisabled:Boolean,mdTooltip:String,mdTooltipDelay:{type:String,default:"0"},mdTooltipDirection:{type:String,default:"bottom"}},data:function(){return{mounted:!1,tabId:this.id||"tab-"+(0,r.default)(),width:"0px",left:"0px"}},watch:{mdActive:function(){this.updateTabData()},mdDisabled:function(){this.updateTabData()},mdIcon:function(){this.updateTabData()},mdLabel:function(){this.updateTabData()},mdTooltip:function(){this.updateTabData()},mdTooltipDelay:function(){this.updateTabData()},mdTooltipDirection:function(){this.updateTabData()}},computed:{styles:function(){return{width:this.width,left:this.left}}},methods:{getTabData:function(){return{id:this.tabId,label:this.mdLabel,icon:this.mdIcon,active:this.mdActive,disabled:this.mdDisabled,tooltip:this.mdTooltip,tooltipDelay:this.mdTooltipDelay,tooltipDirection:this.mdTooltipDirection,ref:this}},updateTabData:function(){this.parentTabs.updateTab(this.getTabData())}},mounted:function(){var t=this.getTabData();if(this.parentTabs=(0,s.default)(this.$parent,"md-tabs"),!this.parentTabs)throw new Error("You must wrap the md-tab in a md-tabs");this.mounted=!0,this.parentTabs.updateTab(t),this.mdActive&&this.parentTabs.setActiveTab(t)},beforeDestroy:function(){this.parentTabs.unregisterTab(this.getTabData())}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(40),r=i(o),a=n(1),s=i(a),d=n(130),l=i(d);e.default={props:{mdFixed:Boolean,mdCentered:Boolean,mdRight:Boolean,mdDynamicHeight:{type:Boolean,default:!0},mdElevation:{type:[String,Number],default:0}},mixins:[s.default],data:function(){return{tabList:{},activeTab:null,activeTabNumber:0,hasIcons:!1,hasLabel:!1,transitionControl:null,transitionOff:!1,contentHeight:"0px",contentWidth:"0px"}},computed:{tabClasses:function(){return{"md-dynamic-height":this.mdDynamicHeight,"md-transition-off":this.transitionOff}},navigationClasses:function(){return{"md-has-icon":this.hasIcons,"md-has-label":this.hasLabel,"md-fixed":this.mdFixed,"md-right":!this.mdCentered&&this.mdRight,"md-centered":this.mdCentered||this.mdFixed}},indicatorClasses:function(){var t=this.lastIndicatorNumber>this.activeTabNumber;return this.lastIndicatorNumber=this.activeTabNumber,{"md-transition-off":this.transitionOff,"md-to-right":!t,"md-to-left":t}}},methods:{getHeaderClass:function(t){return{"md-active":this.activeTab===t.id,"md-disabled":t.disabled}},registerTab:function(t){this.tabList[t.id]=t},unregisterTab:function(t){delete this.tabList[t.id]},updateTab:function(t){if(this.registerTab(t),t.active)if(t.disabled){if((0,r.default)(this.tabList).length){var e=(0,r.default)(this.tabList),n=e.indexOf(t.id)+1,i=e[n];i?this.setActiveTab(this.tabList[i]):this.setActiveTab(this.tabList[0])}}else this.setActiveTab(t)},observeElementChanges:function(){this.parentObserver=new MutationObserver((0,l.default)(this.calculateOnWatch,50)),this.parentObserver.observe(this.$refs.tabContent,{childList:!0,attributes:!0,subtree:!0})},getTabIndex:function(t){var e=(0,r.default)(this.tabList);return e.indexOf(t)},calculateIndicatorPos:function(){if(this.$refs.tabHeader&&this.$refs.tabHeader[this.activeTabNumber]){var t=this.$el.offsetWidth,e=this.$refs.tabHeader[this.activeTabNumber],n=e.offsetLeft,i=t-n-e.offsetWidth;this.$refs.indicator.style.left=n+"px",this.$refs.indicator.style.right=i+"px"}},calculateTabsWidthAndPosition:function(){var t=this.$el.offsetWidth,e=0;this.contentWidth=t*this.activeTabNumber+"px";for(var n in this.tabList){var i=this.tabList[n];i.ref.width=t+"px",i.ref.left=t*e+"px",e++}},calculateContentHeight:function(){var t=this;this.$nextTick((function(){if((0,r.default)(t.tabList).length){var e=t.tabList[t.activeTab].ref.$el.offsetHeight;t.contentHeight=e+"px"}}))},calculatePosition:function(){var t=this;window.requestAnimationFrame((function(){t.calculateIndicatorPos(),t.calculateTabsWidthAndPosition(),t.calculateContentHeight()}))},debounceTransition:function(){var t=this;window.clearTimeout(this.transitionControl),this.transitionControl=window.setTimeout((function(){t.calculatePosition(),t.transitionOff=!1}),200)},calculateOnWatch:function(){this.calculatePosition(),this.debounceTransition()},calculateOnResize:function(){this.transitionOff=!0,this.calculateOnWatch()},setActiveTab:function(t){this.hasIcons=!!t.icon,this.hasLabel=!!t.label,this.activeTab=t.id,this.activeTabNumber=this.getTabIndex(this.activeTab),this.calculatePosition(),this.$emit("change",this.activeTabNumber)}},mounted:function(){var t=this;this.$nextTick((function(){if(t.observeElementChanges(),window.addEventListener("resize",t.calculateOnResize),(0,r.default)(t.tabList).length&&!t.activeTab){var e=(0,r.default)(t.tabList)[0];t.setActiveTab(t.tabList[e])}}))},beforeDestroy:function(){this.parentObserver&&this.parentObserver.disconnect(),window.removeEventListener("resize",this.calculateOnResize)}},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(1),r=i(o);e.default={mixins:[r.default]},t.exports=e.default}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(60),r=i(o),a=n(39),s=i(a);e.default={props:{mdDirection:{type:String,default:"bottom"},mdDelay:{type:String,default:"0"}},data:function(){return{active:!1,parentClass:null,transitionOff:!1,topPosition:!1,leftPosition:!1}},computed:{classes:function(){var t={"md-active":this.active,"md-transition-off":this.transitionOff,"md-tooltip-top":"top"===this.mdDirection,"md-tooltip-right":"right"===this.mdDirection,"md-tooltip-bottom":"bottom"===this.mdDirection,"md-tooltip-left":"left"===this.mdDirection};return this.parentClass&&(t[this.parentClass]=!0),t},style:function(){return{"transition-delay":this.mdDelay+"ms",top:this.topPosition+"px",left:this.leftPosition+"px"}}},watch:{mdDirection:function(){this.calculateTooltipPosition()}},methods:{removeTooltips:function(){this.tooltipElement.parentNode&&(this.tooltipElement.removeEventListener(s.default,this.removeTooltips),this.tooltipElement.parentNode.removeChild(this.tooltipElement))},calculateTooltipPosition:function(){var t=this.parentElement.getBoundingClientRect(),e={};switch(this.mdDirection){case"top":e.top=t.top-this.$el.offsetHeight,e.left=t.left+t.width/2;break;case"right":e.top=t.top,e.left=t.left+t.width;break;case"bottom":e.top=t.bottom,e.left=t.left+t.width/2;break;case"left":e.top=t.top,e.left=t.left-this.$el.offsetWidth;break;default:console.warn("Invalid "+this.mdDirection+" option to md-direction option")}this.topPosition=e.top,this.leftPosition=e.left},generateTooltipClasses:function(){var t=[];[].concat((0,r.default)(this.parentElement.classList)).forEach((function(e){e.indexOf("md-")>=0&&"md-active"!==e&&t.push(e+"-tooltip")})),this.parentClass=t.join(" ")},open:function(){var t=this;this.removeTooltips(),this.$nextTick((function(){document.body.appendChild(t.tooltipElement),getComputedStyle(t.tooltipElement).top,t.transitionOff=!0,t.generateTooltipClasses(),t.calculateTooltipPosition(),window.setTimeout((function(){t.transitionOff=!1,t.active=!0}),10)}))},close:function(){this.active=!1,this.tooltipElement.removeEventListener(s.default,this.removeTooltips),this.tooltipElement.addEventListener(s.default,this.removeTooltips)}},mounted:function(){var t=this;this.$nextTick((function(){t.tooltipElement=t.$el,t.parentElement=t.tooltipElement.parentNode,t.$el.parentNode.removeChild(t.$el),t.parentElement.addEventListener("mouseenter",t.open),t.parentElement.addEventListener("focus",t.open),t.parentElement.addEventListener("mouseleave",t.close),t.parentElement.addEventListener("blur",t.close)}))},beforeDestroy:function(){this.active=!1,this.removeTooltips(),this.parentElement&&(this.parentElement.removeEventListener("mouseenter",this.open),this.parentElement.removeEventListener("focus",this.open),this.parentElement.removeEventListener("mouseleave",this.close),this.parentElement.removeEventListener("blur",this.close))}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{mdElevation:{type:[String,Number],default:1},mdTag:{type:String,default:"div"}},computed:{classes:function(){var t=parseInt(this.mdElevation,10),e="md-whiteframe-";return isNaN(t)||"number"!=typeof t?this.mdElevation.indexOf("dp")>-1&&(e+=this.mdElevation):(e+=t,e+="dp"),e}},render:function(t){return t(this.mdTag,{staticClass:"md-whiteframe",class:this.classes},this.$slots.default)}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i="ontouchstart"in document,o=function(t){return"start"===t?i?"touchstart":"mousedown":i?"touchend":"mouseup"},r=function(t,e,n){t.addEventListener(o(e),n)},a=function(t,e,n){t.removeEventListener(o(e),n)};e.default={props:{mdDisabled:Boolean},data:function(){return{mounted:!1,rippleElement:null,parentElement:null,parentDimensions:{width:null,height:null,top:null,left:null},awaitingComplete:!1,hasCompleted:!1,fadeOut:!1,active:!1}},computed:{classes:function(){return{"md-fadeout":this.fadeOut,"md-active":this.active}},styles:function(){return{width:this.parentDimensions.width,height:this.parentDimensions.height,top:this.parentDimensions.top,left:this.parentDimensions.left}},disabled:function(){return this.mdDisabled||!this.$material.inkRipple}},watch:{disabled:function(t){t?this.destroy():this.init()}},methods:{checkAvailablePositions:function(t){var e=["relative","absolute","fixed"];return e.indexOf(getComputedStyle(t).position)>-1},getClosestPositionedParent:function(t){var e=t&&t.parentNode;return!(!e||"body"===e.tagName.toLowerCase())&&(this.checkAvailablePositions(t)?t:this.getClosestPositionedParent(e))},getParentSize:function(){var t=this.parentElement;return Math.round(Math.max(t.offsetWidth,t.offsetHeight))+"px"},getClickPosition:function(t){if(this.$refs.ripple){var e=this.parentElement.getBoundingClientRect(),n=t.pageY,i=t.pageX;return"touchstart"===t.type&&(n=t.changedTouches[0].pageY,i=t.changedTouches[0].pageX),{top:n-e.top-this.$refs.ripple.offsetHeight/2-document.body.scrollTop+"px",left:i-e.left-this.$refs.ripple.offsetWidth/2-document.body.scrollLeft+"px"}}return!1},setDimensions:function(){var t=this.getParentSize();this.parentDimensions.width=t,this.parentDimensions.height=t},setPositions:function(t){var e=this.getClickPosition(t);e&&(this.parentDimensions.top=e.top,this.parentDimensions.left=e.left)},clearState:function(){this.active=!1,this.fadeOut=!1,this.hasCompleted=!1,this.setDimensions(),window.clearTimeout(this.awaitingComplete),a(document.body,"end",this.endRipple)},startRipple:function(t){var e=this;this.clearState(),this.awaitingComplete=window.setTimeout((function(){e.hasCompleted=!0}),400),r(document.body,"end",this.endRipple),this.$nextTick((function(){e.setPositions(t),e.active=!0}))},endRipple:function(){var t=this;this.hasCompleted?this.fadeOut=!0:this.awaitingComplete=window.setTimeout((function(){t.fadeOut=!0}),200),a(document.body,"end",this.endRipple)},registerTriggerEvent:function(){r(this.parentElement,"start",this.startRipple)},unregisterTriggerEvent:function(){this.parentElement&&a(this.parentElement,"start",this.startRipple)},init:function(){this.rippleElement=this.$el,this.parentElement=this.getClosestPositionedParent(this.$el.parentNode),this.parentElement?(this.rippleElement.parentNode.removeChild(this.rippleElement),this.parentElement.appendChild(this.rippleElement),this.registerTriggerEvent(),this.setDimensions()):this.$destroy()},destroy:function(){this.rippleElement&&this.rippleElement.parentNode&&(this.unregisterTriggerEvent(),this.rippleElement.parentNode.removeChild(this.rippleElement))}},mounted:function(){var t=this;window.setTimeout((function(){t.disabled?t.destroy():t.init(),t.$nextTick((function(){t.mounted=!0}))}),100)},beforeDestroy:function(){this.destroy()}},t.exports=e.default}),(function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={props:{mdTag:String,mdName:{type:String,default:"default"}},data:function(){return{name:"md-theme"}},render:function(t){return this.mdTag||this.$slots.default.length>1?t(this.mdTag||"div",{staticClass:"md-theme"},this.$slots.default):this.$slots.default[0]}},t.exports=e.default}),(function(t,e,n){t.exports={default:n(194),__esModule:!0}}),(function(t,e,n){t.exports={default:n(195),__esModule:!0}}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}e.__esModule=!0;var o=n(192),r=i(o);e.default=r.default||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])}return t}}),(function(t,e,n){n(197),t.exports=9007199254740991}),(function(t,e,n){n(198),t.exports=n(5).Object.assign}),(function(t,e,n){"use strict";var i=n(16),o=n(46),r=n(38),a=n(23),s=n(32),d=Object.assign;t.exports=!d||n(9)((function(){var t={},e={},n=Symbol(),i="abcdefghijklmnopqrst";return t[n]=7,i.split("").forEach((function(t){e[t]=t})),7!=d({},t)[n]||Object.keys(d({},e)).join("")!=i}))?function(t,e){for(var n=a(t),d=arguments.length,l=1,c=o.f,u=r.f;d>l;)for(var m,f=s(arguments[l++]),p=c?i(f).concat(c(f)):i(f),h=p.length,b=0;h>b;)u.call(f,m=p[b++])&&(n[m]=f[m]);return n}:d}),(function(t,e,n){var i=n(18);i(i.S,"Number",{MAX_SAFE_INTEGER:9007199254740991})}),(function(t,e,n){var i=n(18);i(i.S+i.F,"Object",{assign:n(196)})}),(function(t,e){Element.prototype.scrollIntoViewIfNeeded||(Element.prototype.scrollIntoViewIfNeeded=function(t){t=0===arguments.length||!!t;var e=this.parentNode,n=window.getComputedStyle(e,null),i=parseInt(n.getPropertyValue("border-top-width")),o=parseInt(n.getPropertyValue("border-left-width")),r=this.offsetTop-e.offsetTop<e.scrollTop,a=this.offsetTop-e.offsetTop+this.clientHeight-i>e.scrollTop+e.clientHeight,s=this.offsetLeft-e.offsetLeft<e.scrollLeft,d=this.offsetLeft-e.offsetLeft+this.clientWidth-o>e.scrollLeft+e.clientWidth,l=r&&!a;(r||a)&&t&&(e.scrollTop=this.offsetTop-e.offsetTop-e.clientHeight/2-i+this.clientHeight/2),(s||d)&&t&&(e.scrollLeft=this.offsetLeft-e.offsetLeft-e.clientWidth/2-o+this.clientWidth/2),(r||a||s||d)&&!t&&this.scrollIntoView(l)})}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){}),(function(t,e){t.exports=".THEME_NAME.md-avatar.md-primary.md-avatar-icon{background-color:PRIMARY-COLOR}.THEME_NAME.md-avatar.md-primary.md-avatar-icon .md-icon{color:PRIMARY-CONTRAST-0.99999}.THEME_NAME.md-avatar.md-accent.md-avatar-icon{background-color:ACCENT-COLOR}.THEME_NAME.md-avatar.md-accent.md-avatar-icon .md-icon{color:ACCENT-CONTRAST-0.99999}.THEME_NAME.md-avatar.md-warn.md-avatar-icon{background-color:WARN-COLOR}.THEME_NAME.md-avatar.md-warn.md-avatar-icon .md-icon{color:WARN-CONTRAST-0.99999}\n"}),(function(t,e){t.exports=".THEME_NAME.md-bottom-bar.md-fixed{background-color:BACKGROUND-COLOR}.THEME_NAME.md-bottom-bar.md-fixed .md-bottom-bar-item{color:BACKGROUND-CONTRAST-0.54}.THEME_NAME.md-bottom-bar.md-fixed .md-bottom-bar-item:hover:not([disabled]):not(.md-active){color:BACKGROUND-CONTRAST-0.87}.THEME_NAME.md-bottom-bar.md-fixed .md-bottom-bar-item.md-active{color:PRIMARY-COLOR}.THEME_NAME.md-bottom-bar.md-fixed.md-accent .md-bottom-bar-item.md-active{color:ACCENT-COLOR}.THEME_NAME.md-bottom-bar.md-fixed.md-warn .md-bottom-bar-item.md-active{color:WARN-COLOR}.THEME_NAME.md-bottom-bar.md-fixed.md-transparent .md-bottom-bar-item.md-active{color:BACKGROUND-CONTRAST}.THEME_NAME.md-bottom-bar.md-shift{background-color:PRIMARY-COLOR;color:PRIMARY-CONTRAST}.THEME_NAME.md-bottom-bar.md-shift .md-bottom-bar-item{color:PRIMARY-CONTRAST-0.54}.THEME_NAME.md-bottom-bar.md-shift .md-bottom-bar-item:hover:not([disabled]):not(.md-active){color:PRIMARY-CONTRAST-0.87}.THEME_NAME.md-bottom-bar.md-shift .md-bottom-bar-item.md-active{color:PRIMARY-CONTRAST}.THEME_NAME.md-bottom-bar.md-shift.md-accent{background-color:ACCENT-COLOR}.THEME_NAME.md-bottom-bar.md-shift.md-accent .md-bottom-bar-item{color:ACCENT-CONTRAST-0.54}.THEME_NAME.md-bottom-bar.md-shift.md-accent .md-bottom-bar-item:hover:not([disabled]):not(.md-active){color:ACCENT-CONTRAST-0.87}.THEME_NAME.md-bottom-bar.md-shift.md-accent .md-bottom-bar-item.md-active{color:ACCENT-CONTRAST}.THEME_NAME.md-bottom-bar.md-shift.md-warn{background-color:WARN-COLOR}.THEME_NAME.md-bottom-bar.md-shift.md-warn .md-bottom-bar-item{color:WARN-CONTRAST-0.54}.THEME_NAME.md-bottom-bar.md-shift.md-warn .md-bottom-bar-item:hover:not([disabled]):not(.md-active){color:WARN-CONTRAST-0.87}.THEME_NAME.md-bottom-bar.md-shift.md-warn .md-bottom-bar-item.md-active{color:WARN-CONTRAST}.THEME_NAME.md-bottom-bar.md-shift.md-transparent{background-color:transparent}.THEME_NAME.md-bottom-bar.md-shift.md-transparent .md-bottom-bar-item{color:BACKGROUND-CONTRAST-0.54}.THEME_NAME.md-bottom-bar.md-shift.md-transparent .md-bottom-bar-item:hover:not([disabled]):not(.md-active){color:BACKGROUND-CONTRAST-0.87}.THEME_NAME.md-bottom-bar.md-shift.md-transparent .md-bottom-bar-item.md-active{color:BACKGROUND-CONTRAST}\n"}),(function(t,e){t.exports=".THEME_NAME.md-button:not([disabled]).md-raised:not(.md-icon-button){color:BACKGROUND-CONTRAST;background-color:BACKGROUND-COLOR}.THEME_NAME.md-button:not([disabled]).md-raised:not(.md-icon-button):hover{background-color:BACKGROUND-COLOR-200}.THEME_NAME.md-button:not([disabled]).md-raised.md-icon-button:not(.md-raised){color:BACKGROUND-CONTRAST}.THEME_NAME.md-button:not([disabled]).md-fab{color:ACCENT-CONTRAST;background-color:ACCENT-COLOR}.THEME_NAME.md-button:not([disabled]).md-fab:hover{background-color:ACCENT-COLOR-600}.THEME_NAME.md-button:not([disabled]).md-fab.md-clean{color:BACKGROUND-CONTRAST;background-color:BACKGROUND-COLOR}.THEME_NAME.md-button:not([disabled]).md-fab.md-clean:hover{background-color:BACKGROUND-COLOR-200}.THEME_NAME.md-button:not([disabled]).md-primary:not(.md-icon-button){color:PRIMARY-COLOR}.THEME_NAME.md-button:not([disabled]).md-primary.md-raised,.THEME_NAME.md-button:not([disabled]).md-primary.md-fab{background-color:PRIMARY-COLOR;color:PRIMARY-CONTRAST}.THEME_NAME.md-button:not([disabled]).md-primary.md-raised:hover,.THEME_NAME.md-button:not([disabled]).md-primary.md-fab:hover{background-color:PRIMARY-COLOR-600}.THEME_NAME.md-button:not([disabled]).md-primary.md-icon-button:not(.md-raised){color:PRIMARY-COLOR}.THEME_NAME.md-button:not([disabled]).md-accent:not(.md-icon-button){color:ACCENT-COLOR}.THEME_NAME.md-button:not([disabled]).md-accent.md-raised{background-color:ACCENT-COLOR;color:ACCENT-CONTRAST}.THEME_NAME.md-button:not([disabled]).md-accent.md-raised:hover{background-color:ACCENT-COLOR-600}.THEME_NAME.md-button:not([disabled]).md-accent.md-icon-button:not(.md-raised){color:ACCENT-COLOR}.THEME_NAME.md-button:not([disabled]).md-warn:not(.md-icon-button){color:WARN-COLOR}.THEME_NAME.md-button:not([disabled]).md-warn.md-raised,.THEME_NAME.md-button:not([disabled]).md-warn.md-fab{background-color:WARN-COLOR;color:WARN-CONTRAST}.THEME_NAME.md-button:not([disabled]).md-warn.md-raised:hover,.THEME_NAME.md-button:not([disabled]).md-warn.md-fab:hover{background-color:WARN-COLOR-600}.THEME_NAME.md-button:not([disabled]).md-warn.md-icon-button:not(.md-raised){color:WARN-COLOR}\n"}),(function(t,e){t.exports='.THEME_NAME.md-button-toggle .md-button:after{width:1px;position:absolute;top:0;bottom:0;left:0;content:" "}.THEME_NAME.md-button-toggle .md-toggle{color:BACKGROUND-CONTRAST-0.54;background-color:BACKGROUND-CONTRAST-0.26}.THEME_NAME.md-button-toggle .md-toggle:hover:not([disabled]){background-color:BACKGROUND-CONTRAST-0.38}.THEME_NAME.md-button-toggle .md-toggle+.md-toggle:after{background-color:BACKGROUND-CONTRAST-0.12}.THEME_NAME.md-button-toggle.md-primary .md-toggle{color:PRIMARY-CONTRAST;background-color:PRIMARY-COLOR}.THEME_NAME.md-button-toggle.md-primary .md-toggle:hover:not([disabled]){background-color:PRIMARY-COLOR}.THEME_NAME.md-button-toggle.md-primary .md-toggle+.md-toggle:after{background-color:PRIMARY-COLOR-600}.THEME_NAME.md-button-toggle.md-accent .md-toggle{color:ACCENT-CONTRAST;background-color:ACCENT-COLOR}.THEME_NAME.md-button-toggle.md-accent .md-toggle:hover:not([disabled]){background-color:ACCENT-COLOR}.THEME_NAME.md-button-toggle.md-accent .md-toggle+.md-toggle:after{background-color:ACCENT-COLOR-600}.THEME_NAME.md-button-toggle.md-warn .md-toggle{color:WARN-CONTRAST;background-color:WARN-COLOR}.THEME_NAME.md-button-toggle.md-warn .md-toggle:hover:not([disabled]){background-color:WARN-COLOR}.THEME_NAME.md-button-toggle.md-warn .md-toggle+.md-toggle:after{background-color:WARN-COLOR-600}.THEME_NAME.md-button-toggle [disabled]{color:rgba(0,0,0,0.26)}.THEME_NAME.md-button-toggle [disabled].md-toggle{color:BACKGROUND-CONTRAST-0.2;background-color:rgba(0,0,0,0.26)}\n'}),(function(t,e){t.exports=".THEME_NAME.md-card{background-color:BACKGROUND-COLOR}.THEME_NAME.md-card.md-primary{background-color:PRIMARY-COLOR;color:PRIMARY-CONTRAST}.THEME_NAME.md-card.md-primary .md-card-header .md-icon-button:not(.md-primary):not(.md-warn):not(.md-accent) .md-icon,.THEME_NAME.md-card.md-primary .md-card-actions .md-icon-button:not(.md-primary):not(.md-warn):not(.md-accent) .md-icon{color:PRIMARY-CONTRAST-0.87}.THEME_NAME.md-card.md-primary .md-input-container.md-input-focused input,.THEME_NAME.md-card.md-primary .md-input-container.md-input-focused textarea{color:PRIMARY-CONTRAST;text-shadow:0 0 0 PRIMARY-CONTRAST}.THEME_NAME.md-card.md-primary .md-input-container.md-input-focused label,.THEME_NAME.md-card.md-primary .md-input-container.md-input-focused .md-icon:not(.md-icon-delete){color:PRIMARY-CONTRAST}.THEME_NAME.md-card.md-primary .md-input-container:after{background-color:PRIMARY-CONTRAST}.THEME_NAME.md-card.md-primary .md-input-container input,.THEME_NAME.md-card.md-primary .md-input-container textarea{color:PRIMARY-CONTRAST;text-shadow:0 0 0 PRIMARY-CONTRAST}.THEME_NAME.md-card.md-primary .md-input-container input::-webkit-input-placeholder,.THEME_NAME.md-card.md-primary .md-input-container textarea::-webkit-input-placeholder{color:PRIMARY-CONTRAST-0.54}.THEME_NAME.md-card.md-primary .md-input-container label,.THEME_NAME.md-card.md-primary .md-input-container .md-icon:not(.md-icon-delete){color:PRIMARY-CONTRAST}.THEME_NAME.md-card.md-accent{background-color:ACCENT-COLOR;color:ACCENT-CONTRAST}.THEME_NAME.md-card.md-accent .md-card-header .md-icon-button:not(.md-primary):not(.md-warn):not(.md-accent) .md-icon,.THEME_NAME.md-card.md-accent .md-card-actions .md-icon-button:not(.md-primary):not(.md-warn):not(.md-accent) .md-icon{color:ACCENT-CONTRAST-0.87}.THEME_NAME.md-card.md-accent .md-input-container.md-input-focused input,.THEME_NAME.md-card.md-accent .md-input-container.md-input-focused textarea{color:ACCENT-CONTRAST;text-shadow:0 0 0 ACCENT-CONTRAST}.THEME_NAME.md-card.md-accent .md-input-container.md-input-focused label,.THEME_NAME.md-card.md-accent .md-input-container.md-input-focused .md-icon:not(.md-icon-delete){color:ACCENT-CONTRAST}.THEME_NAME.md-card.md-accent .md-input-container:after{background-color:ACCENT-CONTRAST}.THEME_NAME.md-card.md-accent .md-input-container input,.THEME_NAME.md-card.md-accent .md-input-container textarea{color:ACCENT-CONTRAST;text-shadow:0 0 0 ACCENT-CONTRAST}.THEME_NAME.md-card.md-accent .md-input-container input::-webkit-input-placeholder,.THEME_NAME.md-card.md-accent .md-input-container textarea::-webkit-input-placeholder{color:ACCENT-CONTRAST-0.54}.THEME_NAME.md-card.md-accent .md-input-container label,.THEME_NAME.md-card.md-accent .md-input-container .md-icon:not(.md-icon-delete){color:ACCENT-CONTRAST}.THEME_NAME.md-card.md-warn{background-color:WARN-COLOR;color:WARN-CONTRAST}.THEME_NAME.md-card.md-warn .md-card-header .md-icon-button:not(.md-primary):not(.md-warn):not(.md-accent) .md-icon,.THEME_NAME.md-card.md-warn .md-card-actions .md-icon-button:not(.md-primary):not(.md-warn):not(.md-accent) .md-icon{color:WARN-CONTRAST-0.87}.THEME_NAME.md-card.md-warn .md-input-container.md-input-focused input,.THEME_NAME.md-card.md-warn .md-input-container.md-input-focused textarea{color:WARN-CONTRAST;text-shadow:0 0 0 WARN-CONTRAST}.THEME_NAME.md-card.md-warn .md-input-container.md-input-focused label,.THEME_NAME.md-card.md-warn .md-input-container.md-input-focused .md-icon:not(.md-icon-delete){color:WARN-CONTRAST}.THEME_NAME.md-card.md-warn .md-input-container:after{background-color:WARN-CONTRAST}.THEME_NAME.md-card.md-warn .md-input-container input,.THEME_NAME.md-card.md-warn .md-input-container textarea{color:WARN-CONTRAST;text-shadow:0 0 0 WARN-CONTRAST}.THEME_NAME.md-card.md-warn .md-input-container input::-webkit-input-placeholder,.THEME_NAME.md-card.md-warn .md-input-container textarea::-webkit-input-placeholder{color:WARN-CONTRAST-0.54}.THEME_NAME.md-card.md-warn .md-input-container label,.THEME_NAME.md-card.md-warn .md-input-container .md-icon:not(.md-icon-delete){color:WARN-CONTRAST}.THEME_NAME.md-card .md-card-header .md-icon-button:not(.md-primary):not(.md-warn):not(.md-accent) .md-icon,.THEME_NAME.md-card .md-card-actions .md-icon-button:not(.md-primary):not(.md-warn):not(.md-accent) .md-icon{color:BACKGROUND-CONTRAST-0.54}.THEME_NAME.md-card>.md-card-area:after{background-color:BACKGROUND-CONTRAST-0.12}.THEME_NAME.md-card .md-card-media-cover.md-text-scrim .md-backdrop{background:linear-gradient(to bottom, BACKGROUND-CONTRAST-0.0 20%, BACKGROUND-CONTRAST-0.275 66%, BACKGROUND-CONTRAST-0.55 100%)}.THEME_NAME.md-card .md-card-media-cover.md-solid .md-card-area{background-color:BACKGROUND-CONTRAST-0.4}.THEME_NAME.md-card .md-card-expand .md-card-actions{background-color:BACKGROUND-COLOR}\n"}),(function(t,e){t.exports=".THEME_NAME.md-checkbox.md-checked .md-checkbox-container{background-color:ACCENT-COLOR;border-color:ACCENT-COLOR}.THEME_NAME.md-checkbox.md-checked .md-checkbox-container:after{border-color:ACCENT-CONTRAST}.THEME_NAME.md-checkbox .md-ink-ripple{color:ACCENT-COLOR}.THEME_NAME.md-checkbox .md-ripple{opacity:.26}.THEME_NAME.md-checkbox.md-primary.md-checked .md-checkbox-container{background-color:PRIMARY-COLOR;border-color:PRIMARY-COLOR}.THEME_NAME.md-checkbox.md-primary.md-checked .md-checkbox-container:after{border-color:PRIMARY-CONTRAST}.THEME_NAME.md-checkbox.md-primary .md-ink-ripple{color:PRIMARY-COLOR}.THEME_NAME.md-checkbox.md-warn.md-checked .md-checkbox-container{background-color:WARN-COLOR;border-color:WARN-COLOR}.THEME_NAME.md-checkbox.md-warn.md-checked .md-checkbox-container:after{border-color:WARN-CONTRAST}.THEME_NAME.md-checkbox.md-warn .md-ink-ripple{color:WARN-COLOR}.THEME_NAME.md-checkbox.md-disabled.md-checked .md-checkbox-container{background-color:rgba(0,0,0,0.26);border-color:transparent}.THEME_NAME.md-checkbox.md-disabled:not(.md-checked) .md-checkbox-container{border-color:rgba(0,0,0,0.26)}\n"}),(function(t,e){t.exports=".THEME_NAME.md-chip{background-color:BACKGROUND-CONTRAST-0.12}.THEME_NAME.md-chip.md-deletable:hover,.THEME_NAME.md-chip.md-deletable:focus{background-color:BACKGROUND-CONTRAST-0.54;color:BACKGROUND-COLOR}.THEME_NAME.md-chip.md-deletable:hover .md-delete,.THEME_NAME.md-chip.md-deletable:focus .md-delete{color:BACKGROUND-COLOR}.THEME_NAME.md-chip .md-delete{color:BACKGROUND-CONTRAST-0.38}.THEME_NAME.md-chip .md-delete .md-ripple{color:BACKGROUND-COLOR}\n"}),(function(t,e){t.exports=".THEME_NAME.md-dialog-container .md-dialog{background-color:BACKGROUND-COLOR;color:BACKGROUND-CONTRAST}\n"}),(function(t,e){t.exports=""}),(function(t,e){t.exports=".THEME_NAME.md-icon.md-primary{color:PRIMARY-COLOR}.THEME_NAME.md-icon.md-accent{color:ACCENT-COLOR}.THEME_NAME.md-icon.md-warn{color:WARN-COLOR}\n"}),(function(t,e){t.exports=""}),(function(t,e){t.exports=".THEME_NAME.md-input-container.md-input-invalid:after{background-color:WARN-COLOR}.THEME_NAME.md-input-container.md-input-invalid label,.THEME_NAME.md-input-container.md-input-invalid input,.THEME_NAME.md-input-container.md-input-invalid textarea,.THEME_NAME.md-input-container.md-input-invalid .md-error,.THEME_NAME.md-input-container.md-input-invalid .md-count,.THEME_NAME.md-input-container.md-input-invalid .md-icon:not(.md-icon-delete){color:WARN-COLOR}.THEME_NAME.md-input-container.md-input-focused.md-input-inline label{color:rgba(0,0,0,0.54)}.THEME_NAME.md-input-container.md-input-focused.md-input-required label:after{color:WARN-COLOR}.THEME_NAME.md-input-container.md-input-focused:after{height:2px;background-color:PRIMARY-COLOR}.THEME_NAME.md-input-container.md-input-focused input,.THEME_NAME.md-input-container.md-input-focused textarea{color:PRIMARY-COLOR;text-shadow:0 0 0 BACKGROUND-CONTRAST;-webkit-text-fill-color:transparent}.THEME_NAME.md-input-container.md-input-focused label,.THEME_NAME.md-input-container.md-input-focused .md-icon:not(.md-icon-delete){color:PRIMARY-COLOR}.THEME_NAME.md-input-container.md-input-disabled label,.THEME_NAME.md-input-container.md-input-disabled input,.THEME_NAME.md-input-container.md-input-disabled textarea,.THEME_NAME.md-input-container.md-input-disabled .md-error,.THEME_NAME.md-input-container.md-input-disabled .md-count,.THEME_NAME.md-input-container.md-input-disabled .md-icon:not(.md-icon-delete),.THEME_NAME.md-input-container.md-input-disabled ::-webkit-input-placeholder{color:BACKGROUND-CONTRAST-0.38}.THEME_NAME.md-input-container .md-icon:not(.md-icon-delete):after{background:BACKGROUND-COLOR}\n";
  740. }),(function(t,e){t.exports=".THEME_NAME.md-list{background-color:BACKGROUND-COLOR;color:BACKGROUND-CONTRAST}.THEME_NAME.md-list.md-transparent{background-color:transparent;color:inherit}.THEME_NAME.md-list .md-list-item .router-link-active.md-list-item-container{color:PRIMARY-COLOR}.THEME_NAME.md-list .md-list-item .router-link-active.md-list-item-container>.md-icon{color:PRIMARY-COLOR}.THEME_NAME.md-list .md-list-item.md-primary .md-list-item-container{color:PRIMARY-COLOR}.THEME_NAME.md-list .md-list-item.md-primary .md-list-item-container>.md-icon{color:PRIMARY-COLOR}.THEME_NAME.md-list .md-list-item.md-accent .md-list-item-container{color:ACCENT-COLOR}.THEME_NAME.md-list .md-list-item.md-accent .md-list-item-container>.md-icon{color:ACCENT-COLOR}.THEME_NAME.md-list .md-list-item.md-warn .md-list-item-container{color:WARN-COLOR}.THEME_NAME.md-list .md-list-item.md-warn .md-list-item-container>.md-icon{color:WARN-COLOR}.THEME_NAME.md-list .md-list-item-expand .md-list-item-container{background-color:BACKGROUND-COLOR}.THEME_NAME.md-list .md-list-item-expand .md-list-item-container:hover,.THEME_NAME.md-list .md-list-item-expand .md-list-item-container:focus{background-color:rgba(153,153,153,0.2)}\n"}),(function(t,e){t.exports=".THEME_NAME.md-menu-content .md-list{background-color:BACKGROUND-COLOR;color:BACKGROUND-CONTRAST}.THEME_NAME.md-menu-content .md-list .md-menu-item:hover .md-button:not([disabled]),.THEME_NAME.md-menu-content .md-list .md-menu-item:focus .md-button:not([disabled]),.THEME_NAME.md-menu-content .md-list .md-menu-item.md-highlighted .md-button:not([disabled]){background-color:BACKGROUND-CONTRAST-0.12}.THEME_NAME.md-menu-content .md-list .md-menu-item[disabled]{color:BACKGROUND-CONTRAST-0.38}\n"}),(function(t,e){t.exports=".THEME_NAME.md-progress{background-color:PRIMARY-COLOR-0.38}.THEME_NAME.md-progress:not(.md-indeterminate) .md-progress-track{background-color:PRIMARY-COLOR}.THEME_NAME.md-progress .md-progress-track:after,.THEME_NAME.md-progress .md-progress-track:before{background-color:PRIMARY-COLOR}.THEME_NAME.md-progress.md-accent{background-color:ACCENT-COLOR-0.38}.THEME_NAME.md-progress.md-accent:not(.md-indeterminate) .md-progress-track{background-color:ACCENT-COLOR}.THEME_NAME.md-progress.md-accent .md-progress-track:after,.THEME_NAME.md-progress.md-accent .md-progress-track:before{background-color:ACCENT-COLOR}.THEME_NAME.md-progress.md-warn{background-color:WARN-COLOR-0.38}.THEME_NAME.md-progress.md-warn:not(.md-indeterminate) .md-progress-track{background-color:WARN-COLOR}.THEME_NAME.md-progress.md-warn .md-progress-track:after,.THEME_NAME.md-progress.md-warn .md-progress-track:before{background-color:WARN-COLOR}\n"}),(function(t,e){t.exports=".THEME_NAME.md-radio .md-radio-container:after{background-color:ACCENT-COLOR}.THEME_NAME.md-radio.md-checked .md-radio-container{border-color:ACCENT-COLOR}.THEME_NAME.md-radio.md-checked .md-ink-ripple{color:ACCENT-COLOR}.THEME_NAME.md-radio.md-checked .md-ripple{opacity:.38}.THEME_NAME.md-radio.md-primary .md-radio-container:after{background-color:PRIMARY-COLOR}.THEME_NAME.md-radio.md-primary.md-checked .md-radio-container{border-color:PRIMARY-COLOR}.THEME_NAME.md-radio.md-primary.md-checked .md-ink-ripple{color:PRIMARY-COLOR}.THEME_NAME.md-radio.md-warn .md-radio-container:after{background-color:WARN-COLOR}.THEME_NAME.md-radio.md-warn.md-checked .md-radio-container{border-color:WARN-COLOR}.THEME_NAME.md-radio.md-warn.md-checked .md-ink-ripple{color:WARN-COLOR}.THEME_NAME.md-radio.md-disabled .md-radio-container{border-color:rgba(0,0,0,0.26)}.THEME_NAME.md-radio.md-disabled .md-radio-container:after{background-color:rgba(0,0,0,0.26)}.THEME_NAME.md-radio.md-disabled.md-checked .md-radio-container{border-color:rgba(0,0,0,0.26)}\n"}),(function(t,e){t.exports=".THEME_NAME.md-select:after{color:BACKGROUND-CONTRAST-0.54}.THEME_NAME.md-select:after{color:BACKGROUND-CONTRAST-0.38}.THEME_NAME.md-select-content .md-menu-item.md-selected,.THEME_NAME.md-select-content .md-menu-item.md-checked{color:PRIMARY-COLOR}\n"}),(function(t,e){t.exports=".THEME_NAME.md-sidenav .md-sidenav-content{background-color:BACKGROUND-COLOR;color:BACKGROUND-CONTRAST}\n"}),(function(t,e){t.exports=".THEME_NAME .md-snackbar .md-ink-ripple,.THEME_NAME.md-snackbar .md-ink-ripple{color:#fff}\n"}),(function(t,e){t.exports=""}),(function(t,e){t.exports=".THEME_NAME.md-spinner .md-spinner-path{stroke:PRIMARY-COLOR}.THEME_NAME.md-spinner.md-accent .md-spinner-path{stroke:ACCENT-COLOR}.THEME_NAME.md-spinner.md-warn .md-spinner-path{stroke:WARN-COLOR}\n"}),(function(t,e){t.exports=".THEME_NAME.md-subheader.md-primary{color:PRIMARY-COLOR}.THEME_NAME.md-subheader.md-accent{color:ACCENT-COLOR}.THEME_NAME.md-subheader.md-warn{color:WARN-COLOR}\n"}),(function(t,e){t.exports=".THEME_NAME.md-switch.md-checked .md-switch-container{background-color:ACCENT-COLOR-500-0.5}.THEME_NAME.md-switch.md-checked .md-switch-thumb{background-color:ACCENT-COLOR}.THEME_NAME.md-switch.md-checked .md-ink-ripple{color:ACCENT-COLOR}.THEME_NAME.md-switch.md-checked .md-ripple{opacity:.38}.THEME_NAME.md-switch.md-checked.md-primary .md-switch-container{background-color:PRIMARY-COLOR-500-0.5}.THEME_NAME.md-switch.md-checked.md-primary .md-switch-thumb{background-color:PRIMARY-COLOR}.THEME_NAME.md-switch.md-checked.md-primary .md-ink-ripple{color:PRIMARY-COLOR}.THEME_NAME.md-switch.md-checked.md-warn .md-switch-container{background-color:WARN-COLOR-500-0.5}.THEME_NAME.md-switch.md-checked.md-warn .md-switch-thumb{background-color:WARN-COLOR}.THEME_NAME.md-switch.md-checked.md-warn .md-ink-ripple{color:WARN-COLOR}.THEME_NAME.md-switch.md-disabled .md-switch-container,.THEME_NAME.md-switch.md-disabled.md-checked .md-switch-container{background-color:rgba(0,0,0,0.12)}.THEME_NAME.md-switch.md-disabled .md-switch-thumb,.THEME_NAME.md-switch.md-disabled.md-checked .md-switch-thumb{background-color:#bdbdbd}\n"}),(function(t,e){t.exports=".THEME_NAME.md-table-card .md-toolbar{background-color:BACKGROUND-COLOR;color:BACKGROUND-CONTRAST}.THEME_NAME.md-table-alternate-header{background-color:BACKGROUND-COLOR}.THEME_NAME.md-table-alternate-header .md-toolbar{background-color:ACCENT-COLOR-A100-0.2;color:ACCENT-CONTRAST-A100}.THEME_NAME.md-table-alternate-header .md-counter{color:ACCENT-COLOR}\n"}),(function(t,e){t.exports=".THEME_NAME.md-tabs>.md-tabs-navigation{background-color:PRIMARY-COLOR}.THEME_NAME.md-tabs>.md-tabs-navigation .md-tab-header{color:PRIMARY-CONTRAST-0.54}.THEME_NAME.md-tabs>.md-tabs-navigation .md-tab-header.md-active,.THEME_NAME.md-tabs>.md-tabs-navigation .md-tab-header:focus{color:PRIMARY-CONTRAST}.THEME_NAME.md-tabs>.md-tabs-navigation .md-tab-header.md-disabled{color:PRIMARY-CONTRAST-0.26}.THEME_NAME.md-tabs>.md-tabs-navigation .md-tab-indicator{background-color:ACCENT-COLOR}.THEME_NAME.md-tabs.md-transparent>.md-tabs-navigation{background-color:transparent;border-bottom:1px solid BACKGROUND-CONTRAST-0.12}.THEME_NAME.md-tabs.md-transparent>.md-tabs-navigation .md-tab-header{color:BACKGROUND-CONTRAST-0.54}.THEME_NAME.md-tabs.md-transparent>.md-tabs-navigation .md-tab-header.md-active,.THEME_NAME.md-tabs.md-transparent>.md-tabs-navigation .md-tab-header:focus{color:PRIMARY-COLOR}.THEME_NAME.md-tabs.md-transparent>.md-tabs-navigation .md-tab-header.md-disabled{color:BACKGROUND-CONTRAST-0.26}.THEME_NAME.md-tabs.md-transparent>.md-tabs-navigation .md-tab-indicator{background-color:PRIMARY-COLOR}.THEME_NAME.md-tabs.md-accent>.md-tabs-navigation{background-color:ACCENT-COLOR}.THEME_NAME.md-tabs.md-accent>.md-tabs-navigation .md-tab-header{color:ACCENT-CONTRAST-0.54}.THEME_NAME.md-tabs.md-accent>.md-tabs-navigation .md-tab-header.md-active,.THEME_NAME.md-tabs.md-accent>.md-tabs-navigation .md-tab-header:focus{color:ACCENT-CONTRAST}.THEME_NAME.md-tabs.md-accent>.md-tabs-navigation .md-tab-header.md-disabled{color:ACCENT-CONTRAST-0.26}.THEME_NAME.md-tabs.md-accent>.md-tabs-navigation .md-tab-indicator{background-color:BACKGROUND-COLOR}.THEME_NAME.md-tabs.md-warn>.md-tabs-navigation{background-color:WARN-COLOR}.THEME_NAME.md-tabs.md-warn>.md-tabs-navigation .md-tab-header{color:WARN-CONTRAST-0.54}.THEME_NAME.md-tabs.md-warn>.md-tabs-navigation .md-tab-header.md-active,.THEME_NAME.md-tabs.md-warn>.md-tabs-navigation .md-tab-header:focus{color:WARN-CONTRAST}.THEME_NAME.md-tabs.md-warn>.md-tabs-navigation .md-tab-header.md-disabled{color:WARN-CONTRAST-0.26}.THEME_NAME.md-tabs.md-warn>.md-tabs-navigation .md-tab-indicator{background-color:BACKGROUND-COLOR}\n"}),(function(t,e){t.exports=".THEME_NAME.md-toolbar{background-color:PRIMARY-COLOR;color:PRIMARY-CONTRAST}.THEME_NAME.md-toolbar .md-input-container.md-input-focused input,.THEME_NAME.md-toolbar .md-input-container.md-input-focused textarea{color:PRIMARY-CONTRAST;text-shadow:0 0 0 PRIMARY-CONTRAST}.THEME_NAME.md-toolbar .md-input-container.md-input-focused label,.THEME_NAME.md-toolbar .md-input-container.md-input-focused .md-icon:not(.md-icon-delete){color:PRIMARY-CONTRAST}.THEME_NAME.md-toolbar .md-input-container:after{background-color:PRIMARY-CONTRAST}.THEME_NAME.md-toolbar .md-input-container input,.THEME_NAME.md-toolbar .md-input-container textarea{color:PRIMARY-CONTRAST;text-shadow:0 0 0 PRIMARY-CONTRAST}.THEME_NAME.md-toolbar .md-input-container input::-webkit-input-placeholder,.THEME_NAME.md-toolbar .md-input-container textarea::-webkit-input-placeholder{color:PRIMARY-CONTRAST-0.54}.THEME_NAME.md-toolbar .md-input-container label,.THEME_NAME.md-toolbar .md-input-container .md-icon:not(.md-icon-delete){color:PRIMARY-CONTRAST}.THEME_NAME.md-toolbar.md-accent{background-color:ACCENT-COLOR;color:ACCENT-CONTRAST}.THEME_NAME.md-toolbar.md-accent .md-input-container.md-input-focused input,.THEME_NAME.md-toolbar.md-accent .md-input-container.md-input-focused textarea{color:ACCENT-CONTRAST;text-shadow:0 0 0 ACCENT-CONTRAST}.THEME_NAME.md-toolbar.md-accent .md-input-container.md-input-focused label,.THEME_NAME.md-toolbar.md-accent .md-input-container.md-input-focused .md-icon:not(.md-icon-delete){color:ACCENT-CONTRAST}.THEME_NAME.md-toolbar.md-accent .md-input-container:after{background-color:ACCENT-CONTRAST}.THEME_NAME.md-toolbar.md-accent .md-input-container input,.THEME_NAME.md-toolbar.md-accent .md-input-container textarea{color:ACCENT-CONTRAST;text-shadow:0 0 0 ACCENT-CONTRAST}.THEME_NAME.md-toolbar.md-accent .md-input-container input::-webkit-input-placeholder,.THEME_NAME.md-toolbar.md-accent .md-input-container textarea::-webkit-input-placeholder{color:ACCENT-CONTRAST-0.54}.THEME_NAME.md-toolbar.md-accent .md-input-container label,.THEME_NAME.md-toolbar.md-accent .md-input-container .md-icon:not(.md-icon-delete){color:ACCENT-CONTRAST}.THEME_NAME.md-toolbar.md-warn{background-color:WARN-COLOR;color:WARN-CONTRAST}.THEME_NAME.md-toolbar.md-warn .md-input-container.md-input-focused input,.THEME_NAME.md-toolbar.md-warn .md-input-container.md-input-focused textarea{color:WARN-CONTRAST;text-shadow:0 0 0 WARN-CONTRAST}.THEME_NAME.md-toolbar.md-warn .md-input-container.md-input-focused label,.THEME_NAME.md-toolbar.md-warn .md-input-container.md-input-focused .md-icon:not(.md-icon-delete){color:WARN-CONTRAST}.THEME_NAME.md-toolbar.md-warn .md-input-container:after{background-color:WARN-CONTRAST}.THEME_NAME.md-toolbar.md-warn .md-input-container input,.THEME_NAME.md-toolbar.md-warn .md-input-container textarea{color:WARN-CONTRAST;text-shadow:0 0 0 WARN-CONTRAST}.THEME_NAME.md-toolbar.md-warn .md-input-container input::-webkit-input-placeholder,.THEME_NAME.md-toolbar.md-warn .md-input-container textarea::-webkit-input-placeholder{color:WARN-CONTRAST-0.54}.THEME_NAME.md-toolbar.md-warn .md-input-container label,.THEME_NAME.md-toolbar.md-warn .md-input-container .md-icon:not(.md-icon-delete){color:WARN-CONTRAST}.THEME_NAME.md-toolbar.md-transparent{background-color:transparent;color:BACKGROUND-CONTRAST}.THEME_NAME.md-toolbar.md-transparent .md-input-container.md-input-focused input,.THEME_NAME.md-toolbar.md-transparent .md-input-container.md-input-focused textarea{color:BACKGROUND-CONTRAST;text-shadow:0 0 0 BACKGROUND-CONTRAST}.THEME_NAME.md-toolbar.md-transparent .md-input-container.md-input-focused label,.THEME_NAME.md-toolbar.md-transparent .md-input-container.md-input-focused .md-icon:not(.md-icon-delete){color:BACKGROUND-CONTRAST}.THEME_NAME.md-toolbar.md-transparent .md-input-container:after{background-color:BACKGROUND-CONTRAST}.THEME_NAME.md-toolbar.md-transparent .md-input-container input,.THEME_NAME.md-toolbar.md-transparent .md-input-container textarea{color:BACKGROUND-CONTRAST;text-shadow:0 0 0 BACKGROUND-CONTRAST}.THEME_NAME.md-toolbar.md-transparent .md-input-container input::-webkit-input-placeholder,.THEME_NAME.md-toolbar.md-transparent .md-input-container textarea::-webkit-input-placeholder{color:BACKGROUND-CONTRAST-0.54}.THEME_NAME.md-toolbar.md-transparent .md-input-container label,.THEME_NAME.md-toolbar.md-transparent .md-input-container .md-icon:not(.md-icon-delete){color:BACKGROUND-CONTRAST}\n"}),(function(t,e){t.exports=".THEME_NAME :not(input):not(textarea)::selection{background:ACCENT-COLOR;color:ACCENT-CONTRAST}.THEME_NAME a:not(.md-button){color:ACCENT-COLOR}.THEME_NAME a:not(.md-button):hover{color:ACCENT-COLOR-800}body.THEME_NAME{background-color:BACKGROUND-COLOR;color:BACKGROUND-CONTRAST-0.87}.THEME_NAME .md-caption,.THEME_NAME .md-display-1,.THEME_NAME .md-display-2,.THEME_NAME .md-display-3,.THEME_NAME .md-display-4{color:BACKGROUND-CONTRAST-0.57}.THEME_NAME code:not(.hljs){background-color:ACCENT-COLOR-A100-0.2;color:ACCENT-COLOR-800}\n"}),(function(t,e,n){n(215);var i=n(0)(n(131),n(364),null,null);t.exports=i.exports}),(function(t,e,n){n(232);var i=n(0)(n(132),n(393),null,null);t.exports=i.exports}),(function(t,e,n){n(205);var i=n(0)(n(133),n(343),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(134),n(345),null,null);t.exports=i.exports}),(function(t,e,n){n(223);var i=n(0)(n(135),n(381),null,null);t.exports=i.exports}),(function(t,e,n){n(202);var i=n(0)(n(136),n(335),null,null);t.exports=i.exports}),(function(t,e,n){n(206);var i=n(0)(n(137),n(346),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(null,n(356),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(138),n(341),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(null,n(380),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(139),n(334),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(null,n(373),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(140),n(368),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(141),n(339),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(null,n(330),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(142),n(337),null,null);t.exports=i.exports}),(function(t,e,n){n(225);var i=n(0)(n(143),n(386),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(144),n(352),null,null);t.exports=i.exports}),(function(t,e,n){n(219);var i=n(0)(n(145),n(369),null,null);t.exports=i.exports}),(function(t,e,n){n(210);var i=n(0)(n(146),n(355),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(null,n(385),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(null,n(359),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(null,n(353),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(147),n(370),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(148),n(392),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(149),n(351),null,null);t.exports=i.exports}),(function(t,e,n){n(220);var i=n(0)(null,n(371),null,null);t.exports=i.exports}),(function(t,e,n){n(217);var i=n(0)(n(150),n(366),null,null);t.exports=i.exports}),(function(t,e,n){n(207);var i=n(0)(n(151),n(348),null,null);t.exports=i.exports}),(function(t,e,n){n(229);var i=n(0)(n(152),n(389),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(153),n(347),null,null);t.exports=i.exports}),(function(t,e,n){n(208);var i=n(0)(n(154),n(349),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(155),n(376),null,null);t.exports=i.exports}),(function(t,e,n){n(227);var i=n(0)(n(156),null,null,null);t.exports=i.exports}),(function(t,e,n){n(211);var i=n(0)(n(157),n(357),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(null,n(394),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(158),n(338),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(159),n(363),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(160),n(344),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(161),n(361),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(162),n(354),null,null);t.exports=i.exports}),(function(t,e,n){n(231);var i=n(0)(n(163),n(391),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(164),n(384),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(165),n(342),null,null);t.exports=i.exports}),(function(t,e,n){n(209);var i=n(0)(n(166),n(350),null,null);t.exports=i.exports}),(function(t,e,n){n(201);var i=n(0)(n(167),n(332),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(168),n(374),null,null);t.exports=i.exports}),(function(t,e,n){n(226);var i=n(0)(n(169),n(387),null,null);t.exports=i.exports}),(function(t,e,n){n(218);var i=n(0)(n(170),n(367),null,null);t.exports=i.exports}),(function(t,e,n){n(230);var i=n(0)(n(171),n(390),null,null);t.exports=i.exports}),(function(t,e,n){n(216);var i=n(0)(n(172),n(365),null,null);t.exports=i.exports}),(function(t,e,n){n(204);var i=n(0)(n(173),n(340),null,null);t.exports=i.exports}),(function(t,e,n){n(222);var i=n(0)(n(174),n(379),null,null);t.exports=i.exports}),(function(t,e,n){n(224);var i=n(0)(n(175),n(383),null,null);t.exports=i.exports}),(function(t,e,n){n(203);var i=n(0)(n(176),n(336),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(177),n(375),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(178),n(331),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(179),n(372),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(180),n(378),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(181),n(382),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(182),n(333),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(183),n(362),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(184),n(329),null,null);t.exports=i.exports}),(function(t,e,n){n(212);var i=n(0)(n(185),n(358),null,null);t.exports=i.exports}),(function(t,e,n){n(213);var i=n(0)(n(186),n(360),null,null);t.exports=i.exports}),(function(t,e,n){n(228);var i=n(0)(n(187),n(388),null,null);t.exports=i.exports}),(function(t,e,n){n(214);var i=n(0)(n(188),null,null,null);t.exports=i.exports}),(function(t,e,n){n(221);var i=n(0)(n(189),n(377),null,null);t.exports=i.exports}),(function(t,e,n){var i=n(0)(n(190),null,null,null);t.exports=i.exports}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-tab",style:t.styles,attrs:{id:t.tabId}},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-card-media-actions"},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("md-card",{staticClass:"md-table-card",class:[t.themeClass]},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-radio",class:[t.themeClass,t.classes]},[n("div",{staticClass:"md-radio-container",on:{click:t.toggleCheck}},[n("input",{attrs:{type:"radio",name:t.name,id:t.id,disabled:t.disabled},domProps:{value:t.value}}),t._v(" "),n("md-ink-ripple",{attrs:{"md-disabled":t.disabled}})],1),t._v(" "),t.$slots.default?n("label",{staticClass:"md-radio-label",attrs:{for:t.id||t.name}},[t._t("default")],2):t._e()])},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-table-pagination"},[n("span",{staticClass:"md-table-pagination-label"},[t._v(t._s(t.mdLabel)+":")]),t._v(" "),t.mdPageOptions?n("md-select",{directives:[{name:"model",rawName:"v-model",value:t.currentSize,expression:"currentSize"}],attrs:{"md-menu-class":"md-pagination-select"},domProps:{value:t.currentSize},on:{change:t.changeSize,input:function(e){t.currentSize=e}}},t._l(t.mdPageOptions,(function(e){return n("md-option",{attrs:{value:e}},[t._v(t._s(e))])}))):t._e(),t._v(" "),n("span",[t._v(t._s((t.currentPage-1)*t.currentSize+1)+"-"+t._s(t.subTotal)+" "+t._s(t.mdSeparator)+" "+t._s(t.mdTotal))]),t._v(" "),n("md-button",{staticClass:"md-icon-button md-table-pagination-previous",attrs:{disabled:1===t.currentPage},nativeOn:{click:function(e){t.previousPage(e)}}},[n("md-icon",[t._v("keyboard_arrow_left")])],1),t._v(" "),n("md-button",{staticClass:"md-icon-button md-table-pagination-next",attrs:{disabled:t.currentSize*t.currentPage>=t.totalItems},nativeOn:{click:function(e){t.nextPage(e)}}},[n("md-icon",[t._v("keyboard_arrow_right")])],1)],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{ref:"expand",staticClass:"md-card-expand"},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-button-toggle",class:[t.themeClass]},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-table",class:[t.themeClass]},[n("table",[t._t("default")],2)])},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-card-media-cover",class:t.classes},[t._t("default"),t._v(" "),t.mdTextScrim?n("div",{ref:"backdrop",staticClass:"md-card-backdrop",style:t.styles}):t._e()],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("li",{staticClass:"md-list-item",class:t.classes},[n("div",{staticClass:"md-list-item-container md-button"},[t._t("default")],2),t._v(" "),n("md-button",{staticClass:"md-button-ghost",attrs:{type:"button",disabled:t.disabled}})],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-card-media",class:t.classes},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("transition",{attrs:{name:"md-spinner",appear:""}},[n("div",{staticClass:"md-spinner",class:[t.themeClass,t.classes],style:t.styles},[n("svg",{staticClass:"md-spinner-draw",attrs:{viewBox:"25 25 50 50"}},[n("circle",{staticClass:"md-spinner-path",attrs:{cx:"50",cy:"50",r:"20","stroke-width":t.mdStroke,"stroke-dasharray":t.dashProgress}})])])])},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-card-area",class:t.classes},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("md-list-item",{staticClass:"md-menu-item",class:t.classes,attrs:{href:t.href,target:t.target,disabled:t.disabled},nativeOn:{click:function(e){t.close(e)}}},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-bottom-bar",class:[t.themeClass,t.classes]},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("li",{staticClass:"md-list-item md-list-item-expand",class:t.classes},[n("div",{staticClass:"md-list-item-container md-button"},[t._t("default"),t._v(" "),n("md-icon",{staticClass:"md-list-expand-indicator"},[t._v("keyboard_arrow_down")])],2),t._v(" "),n("md-button",{staticClass:"md-button-ghost",attrs:{type:"button",disabled:t.disabled},nativeOn:{click:function(e){t.toggleExpandList(e)}}}),t._v(" "),n("div",{ref:"expand",staticClass:"md-list-expand",class:t.expandClasses,style:t.expandStyles},[t._t("expand")],2)],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return t.href?n("a",{staticClass:"md-bottom-bar-item",class:t.classes,attrs:{href:t.href,disabled:t.disabled},on:{click:t.setActive}},[t.mdIcon||t.mdIconSrc||t.mdIconset?n("md-icon",{attrs:{"md-icon-src":t.mdIconSrc,"md-iconset":t.mdIconset}},[t._v(t._s(t.mdIcon))]):t._e(),t._v(" "),n("md-ink-ripple",{attrs:{"md-disabled":t.disabled}}),t._v(" "),n("span",{staticClass:"md-text"},[t._t("default")],2)],1):n("button",{staticClass:"md-bottom-bar-item",class:t.classes,attrs:{type:"button",disabled:t.disabled},on:{click:t.setActive}},[t.mdIcon||t.mdIconSrc||t.mdIconset?n("md-icon",{attrs:{"md-src":t.mdIconSrc,"md-iconset":t.mdIconset}},[t._v(t._s(t.mdIcon))]):t._e(),t._v(" "),n("md-ink-ripple",{attrs:{"md-disabled":t.disabled}}),t._v(" "),n("span",{staticClass:"md-text"},[t._t("default")],2)],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-card",class:[t.themeClass,t.classes]},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("input",{staticClass:"md-input",attrs:{type:t.type,disabled:t.disabled,required:t.required,placeholder:t.placeholder,maxlength:t.maxlength},domProps:{value:t.value},on:{focus:t.onFocus,blur:t.onBlur,input:t.onInput,keydown:[function(e){t._k(e.keyCode,"up",38)||t.onInput(e)},function(e){t._k(e.keyCode,"down",40)||t.onInput(e)}]}})},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return t.svgContent?n("i",{staticClass:"md-icon",class:[t.themeClass],domProps:{innerHTML:t._s(t.svgContent)}}):t.imageSrc?n("md-image",{staticClass:"md-icon",class:[t.themeClass],attrs:{"md-src":t.imageSrc}}):n("i",{staticClass:"md-icon",class:[t.themeClass,t.mdIconset],attrs:{"aria-hidden":!!t.mdIconset}},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-input-container",class:[t.themeClass,t.classes]},[t._t("default"),t._v(" "),t.enableCounter?n("span",{staticClass:"md-count"},[t._v(t._s(t.inputLength)+" / "+t._s(t.counterLength))]):t._e(),t._v(" "),t.mdHasPassword?n("md-button",{staticClass:"md-icon-button md-toggle-password",nativeOn:{click:function(e){t.togglePasswordType(e)}}},[n("md-icon",[t._v(t._s(t.showPassword?"visibility_off":"visibility"))])],1):t._e()],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("transition",{attrs:{name:"md-progress",appear:""}},[n("div",{staticClass:"md-progress",class:[t.themeClass,t.classes]},[n("div",{staticClass:"md-progress-track",style:t.styles})])])},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("md-dialog",{ref:"dialog",staticClass:"md-dialog-prompt",on:{close:function(e){t.fireCloseEvent("cancel")}}},[t.mdTitle?n("md-dialog-title",[t._v(t._s(t.mdTitle))]):t._e(),t._v(" "),t.mdContentHtml?n("md-dialog-content",{domProps:{innerHTML:t._s(t.mdContentHtml)}}):t._e(),t._v(" "),t.mdContent?n("md-dialog-content",[t._v(t._s(t.mdContent))]):t._e(),t._v(" "),n("md-dialog-content",[n("md-input-container",[n("md-input",{ref:"input",attrs:{id:t.mdInputId,name:t.mdInputName,maxlength:t.mdInputMaxlength,placeholder:t.mdInputPlaceholder,value:t.value},nativeOn:{keydown:function(e){t._k(e.keyCode,"enter",13)||t.confirmValue(e)}}})],1)],1),t._v(" "),n("md-dialog-actions",[n("md-button",{staticClass:"md-primary",nativeOn:{click:function(e){t.close("cancel")}}},[t._v(t._s(t.mdCancelText))]),t._v(" "),n("md-button",{staticClass:"md-primary",nativeOn:{click:function(e){t.confirmValue(e)}}},[t._v(t._s(t.mdOkText))])],1)],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-chip",class:[t.themeClass,t.classes],attrs:{tabindex:"0"}},[t._t("default"),t._v(" "),t.mdDeletable?n("md-button",{staticClass:"md-icon-button md-dense md-delete",attrs:{tabindex:"-1"},nativeOn:{click:function(e){!t.disabled&&t.$emit("delete")},keyup:function(e){t._k(e.keyCode,"delete",[8,46])||!t.disabled&&t.$emit("delete")}}},[n("md-icon",{staticClass:"md-icon-delete"},[t._v("cancel")])],1):t._e()],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-dialog-title md-title"},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("li",{staticClass:"md-list-item",class:t.classes,attrs:{disabled:t.disabled}},[t._t("default"),t._v(" "),n("md-ink-ripple",{attrs:{disabled:t.disabled}})],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-dialog-container",class:[t.themeClass,t.classes],attrs:{tabindex:"0"},on:{keyup:function(e){t._k(e.keyCode,"esc",27)||(e.stopPropagation(),t.closeOnEsc(e))}}},[n("div",{ref:"dialog",staticClass:"md-dialog",class:t.dialogClasses,style:t.styles},[t._t("default")],2),t._v(" "),t.mdBackdrop?n("md-backdrop",{ref:"backdrop",staticClass:"md-dialog-backdrop",class:t.classes,on:{close:function(e){t.mdClickOutsideToClose&&t.close()}}}):t._e()],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-card-actions"},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("ul",{staticClass:"md-list",class:[t.themeClass]},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-tabs",class:[t.themeClass,t.tabClasses]},[n("md-whiteframe",{ref:"tabNavigation",staticClass:"md-tabs-navigation",class:t.navigationClasses,attrs:{"md-tag":"nav","md-elevation":t.mdElevation}},[t._l(t.tabList,(function(e){return n("button",{key:e.id,ref:"tabHeader",refInFor:!0,staticClass:"md-tab-header",class:t.getHeaderClass(e),attrs:{type:"button",disabled:e.disabled},on:{click:function(n){t.setActiveTab(e)}}},[n("md-ink-ripple",{attrs:{"md-disabled":e.disabled}}),t._v(" "),n("div",{staticClass:"md-tab-header-container"},[e.icon?n("md-icon",[t._v(t._s(e.icon))]):t._e(),t._v(" "),e.label?n("span",[t._v(t._s(e.label))]):t._e(),t._v(" "),e.tooltip?n("md-tooltip",{attrs:{"md-direction":e.tooltipDirection,"md-delay":e.tooltipDelay}},[t._v(t._s(e.tooltip))]):t._e()],1)],1)})),t._v(" "),n("span",{ref:"indicator",staticClass:"md-tab-indicator",class:t.indicatorClasses})],2),t._v(" "),n("div",{ref:"tabContent",staticClass:"md-tabs-content",style:{height:t.contentHeight}},[n("div",{staticClass:"md-tabs-wrapper",style:{transform:"translate3D(-"+t.contentWidth+", 0, 0)"}},[t._t("default")],2)])],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-dialog-content"},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-toolbar",class:[t.themeClass]},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("li",{staticClass:"md-list-item",
  741. class:t.classes},[n("a",{staticClass:"md-list-item-container md-button",attrs:{href:t.href,target:t.target,disabled:t.disabled}},[t._t("default")],2),t._v(" "),n("md-ink-ripple",{attrs:{disabled:t.disabled}})],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("tr",{staticClass:"md-table-row",class:t.classes,on:{click:t.autoSelect}},[t.hasSelection?n("md-table-cell",{staticClass:"md-table-selection"},[n("md-checkbox",{directives:[{name:"model",rawName:"v-model",value:t.checkbox,expression:"checkbox"}],attrs:{disabled:t.isDisabled},domProps:{value:t.checkbox},on:{change:t.select,input:function(e){t.checkbox=e}}})],1):t._e(),t._v(" "),t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("li",{staticClass:"md-list-item"},[n("div",{staticClass:"md-list-item-container"},[t._t("default")],2)])},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-avatar",class:[t.themeClass]},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-speed-dial",class:[t.themeClass,t.classes]},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-file",on:{click:t.openPicker}},[n("md-input",{directives:[{name:"model",rawName:"v-model",value:t.filename,expression:"filename"}],ref:"textInput",attrs:{readonly:"",required:t.required,placeholder:t.placeholder,disabled:t.disabled},domProps:{value:t.filename},on:{input:function(e){t.filename=e}}}),t._v(" "),n("md-icon",[t._v("attach_file")]),t._v(" "),n("input",{ref:"fileInput",attrs:{type:"file",id:t.id,name:t.name,disabled:t.disabled,multiple:t.multiple,accept:t.accept},on:{change:t.onFileSelected}})],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-sidenav",class:[t.themeClass,t.classes],attrs:{tabindex:"0"},on:{keyup:function(e){t._k(e.keyCode,"esc",27)||t.close(e)}}},[n("div",{staticClass:"md-sidenav-content"},[t._t("default")],2),t._v(" "),n("md-backdrop",{ref:"backdrop",staticClass:"md-sidenav-backdrop",on:{close:t.close}})],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-card-header-text"},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-chips",class:[t.themeClass,t.classes]},[n("md-input-container",{nativeOn:{click:function(e){t.applyInputFocus(e)}}},[t._l(t.selectedChips,(function(e){return n("md-chip",{attrs:{"md-deletable":!t.mdStatic,disabled:t.disabled},on:{delete:function(n){t.deleteChip(e)}}},[t._t("default",null,{value:e})],2)})),t._v(" "),n("md-input",{directives:[{name:"show",rawName:"v-show",value:!t.mdStatic,expression:"!mdStatic"},{name:"model",rawName:"v-model",value:t.currentChip,expression:"currentChip"}],ref:"input",attrs:{type:t.mdInputType,placeholder:t.mdInputPlaceholder,id:t.inputId,name:t.mdInputName,disabled:t.disabled,tabindex:"0"},domProps:{value:t.currentChip},on:{input:function(e){t.currentChip=e}},nativeOn:{keydown:[function(e){t._k(e.keyCode,"delete",[8,46])||t.deleteLastChip(e)},function(e){t._k(e.keyCode,"enter",13)||(e.preventDefault(),t.addChip(e))},function(e){186===e.keyCode&&(e.preventDefault(),t.addChip(e))}]}})],2)],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("md-dialog",{ref:"dialog",staticClass:"md-dialog-alert",on:{close:function(e){t.fireCloseEvent()}}},[t.mdTitle?n("md-dialog-title",[t._v(t._s(t.mdTitle))]):t._e(),t._v(" "),t.mdContentHtml?n("md-dialog-content",{domProps:{innerHTML:t._s(t.mdContentHtml)}}):n("md-dialog-content",[t._v(t._s(t.mdContent))]),t._v(" "),n("md-dialog-actions",[n("md-button",{staticClass:"md-primary",nativeOn:{click:function(e){t.close()}}},[t._v(t._s(t.mdOkText))])],1)],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("hr",{staticClass:"md-divider"})},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("td",{staticClass:"md-table-cell",class:t.classes},[n("div",{staticClass:"md-table-cell-container"},[t._t("default")],2)])},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-card-header"},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("md-menu-item",{staticClass:"md-option",class:t.classes,attrs:{tabindex:"-1"},nativeOn:{click:function(e){t.selectOption(e)}}},[t.parentSelect.multiple?n("md-checkbox",{directives:[{name:"model",rawName:"v-model",value:t.check,expression:"check"}],staticClass:"md-primary",domProps:{value:t.check},on:{input:function(e){t.check=e}}},[n("span",{ref:"item"},[t._t("default")],2)]):n("span",{ref:"item"},[t._t("default")],2)],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-table-alternate-header",class:[t.themeClass,t.classes]},[n("md-toolbar",[n("div",{staticClass:"md-counter"},[n("span",{ref:"counter"},[t._v(t._s(t.tableInstance.numberOfSelected))]),t._v(" "),n("span",[t._v(t._s(t.mdSelectedLabel))])]),t._v(" "),t._t("default")],2)],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("textarea",{staticClass:"md-input",attrs:{disabled:t.disabled,required:t.required,placeholder:t.placeholder,maxlength:t.maxlength},domProps:{value:t.value},on:{focus:t.onFocus,blur:t.onBlur,input:t.onInput}})},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return t.mounted||!t.disabled?n("div",{staticClass:"md-ink-ripple"},[n("div",{ref:"ripple",staticClass:"md-ripple",class:t.classes,style:t.styles})]):t._e()},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-table-edit",on:{keydown:function(e){t._k(e.keyCode,"esc",27)||t.closeDialog(e)}}},[n("div",{staticClass:"md-table-edit-trigger",class:t.triggerClasses,on:{click:function(e){e.stopPropagation(),t.openDialog(e)}}},[t._v("\n "+t._s(t.value||t.mdPlaceholder)+"\n ")]),t._v(" "),n("div",{ref:"dialog",staticClass:"md-table-dialog",class:t.dialogClasses},[n("md-input-container",[n("md-input",{ref:"input",attrs:{id:t.mdId,name:t.mdName,maxlength:t.mdMaxlength,value:t.value,placeholder:t.mdPlaceholder},nativeOn:{keydown:function(e){t._k(e.keyCode,"enter",13)||t.confirmDialog(e)}}})],1)],1)])},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return"md-list"===t.$parent.$options._componentTag?n("li",{staticClass:"md-subheader",class:[t.themeClass]},[t._t("default")],2):n("div",{staticClass:"md-subheader",class:[t.themeClass]},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-card-content"},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return t.href?n("a",{staticClass:"md-button",class:[t.themeClass],attrs:{href:t.href,disabled:t.disabled,target:t.target,rel:t.newRel}},[n("md-ink-ripple",{attrs:{"md-disabled":t.disabled}}),t._v(" "),t._t("default")],2):n("button",{staticClass:"md-button",class:[t.themeClass],attrs:{type:t.type,disabled:t.disabled}},[n("md-ink-ripple",{attrs:{"md-disabled":t.disabled}}),t._v(" "),t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("th",{staticClass:"md-table-head",class:t.classes,on:{click:t.changeSort}},[n("div",{staticClass:"md-table-head-container"},[n("div",{staticClass:"md-table-head-text md-test"},[t.mdSortBy?n("md-icon",{staticClass:"md-sortable-icon"},[t._v("arrow_downward")]):t._e(),t._v(" "),t._t("default"),t._v(" "),t.mdTooltip?n("md-tooltip",[t._v(t._s(t.mdTooltip))]):t._e()],2),t._v(" "),n("md-ink-ripple",{attrs:{"md-disabled":!t.mdSortBy}})],1)])},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-switch",class:[t.themeClass,t.classes]},[n("div",{staticClass:"md-switch-container",on:{click:function(e){t.toggle(e)}}},[n("div",{staticClass:"md-switch-thumb",style:t.styles},[n("input",{attrs:{type:"checkbox",name:t.name,id:t.id,disabled:t.disabled},domProps:{value:t.value}}),t._v(" "),n("button",{staticClass:"md-switch-holder",attrs:{type:t.type}}),t._v(" "),n("md-ink-ripple",{attrs:{"md-disabled":t.disabled}})],1)]),t._v(" "),t.$slots.default?n("label",{staticClass:"md-switch-label",attrs:{for:t.id||t.name}},[t._t("default")],2):t._e()])},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-menu-content",attrs:{tabindex:"-1"},on:{keydown:[function(e){t._k(e.keyCode,"esc",27)||(e.preventDefault(),t.close(e))},function(e){t._k(e.keyCode,"tab",9)||(e.preventDefault(),t.close(e))},function(e){t._k(e.keyCode,"up",38)||(e.preventDefault(),t.highlightItem("up"))},function(e){t._k(e.keyCode,"down",40)||(e.preventDefault(),t.highlightItem("down"))},function(e){t._k(e.keyCode,"enter",13)||(e.preventDefault(),t.fireClick(e))},function(e){t._k(e.keyCode,"space",32)||(e.preventDefault(),t.fireClick(e))}]}},[n("md-list",[t._t("default")],2)],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-dialog-actions"},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-checkbox",class:[t.themeClass,t.classes]},[n("div",{staticClass:"md-checkbox-container",attrs:{tabindex:"0"},on:{click:function(e){e.stopPropagation(),t.toggleCheck(e)}}},[n("input",{attrs:{type:"checkbox",name:t.name,id:t.id,disabled:t.disabled,tabindex:"-1"},domProps:{value:t.value,checked:t.checked}}),t._v(" "),n("md-ink-ripple",{attrs:{"md-disabled":t.disabled}})],1),t._v(" "),t.$slots.default?n("label",{staticClass:"md-checkbox-label",attrs:{for:t.id||t.name}},[t._t("default")],2):t._e()])},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-select",class:[t.themeClass,t.classes]},[n("md-menu",{attrs:{"md-close-on-select":!t.multiple},on:{opened:function(e){t.$emit("open")},closed:function(e){t.$emit("close")}}},[n("span",{ref:"value",staticClass:"md-select-value",attrs:{"md-menu-trigger":""}},[t._v(t._s(t.selectedText||t.placeholder))]),t._v(" "),n("md-menu-content",{staticClass:"md-select-content",class:[t.themeClass,t.contentClasses]},[t._t("default")],2)],1),t._v(" "),n("select",{attrs:{name:t.name,id:t.id,required:t.required,disabled:t.disabled,tabindex:"-1"}},[t.multiple?t._e():n("option",{attrs:{selected:"true"},domProps:{value:t.selectedValue}},[t._v(t._s(t.selectedText))]),t._v(" "),t._l(t.multipleOptions,(function(e){return e.value?n("option",{attrs:{selected:"true"},domProps:{value:e.value}},[t._v(t._s(e.text))]):t._e()}))],2)],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("span",{staticClass:"md-tooltip",class:t.classes,style:t.style},[t._t("default")],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("img",{staticClass:"md-image",class:t.classes,attrs:{src:t.mdSrc}})},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-snackbar",class:[t.themeClass,t.classes],attrs:{id:t.snackbarId},on:{mouseenter:t.pauseTimeout,mouseleave:t.resumeTimeout}},[n("div",{ref:"container",staticClass:"md-snackbar-container"},[n("div",{staticClass:"md-snackbar-content"},[t._t("default")],2)])])},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-menu"},[t._t("default"),t._v(" "),n("md-backdrop",{ref:"backdrop",staticClass:"md-menu-backdrop md-transparent md-active",on:{close:t.close}})],2)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("md-dialog",{ref:"dialog",staticClass:"md-dialog-confirm",on:{close:function(e){t.fireCloseEvent("cancel")}}},[t.mdTitle?n("md-dialog-title",[t._v(t._s(t.mdTitle))]):t._e(),t._v(" "),t.mdContentHtml?n("md-dialog-content",{domProps:{innerHTML:t._s(t.mdContentHtml)}}):n("md-dialog-content",[t._v(t._s(t.mdContent))]),t._v(" "),n("md-dialog-actions",[n("md-button",{staticClass:"md-primary",nativeOn:{click:function(e){t.close("cancel")}}},[t._v(t._s(t.mdCancelText))]),t._v(" "),n("md-button",{staticClass:"md-primary",nativeOn:{click:function(e){t.close("ok")}}},[t._v(t._s(t.mdOkText))])],1)],1)},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-backdrop",on:{click:t.close,keyup:function(e){t._k(e.keyCode,"esc",27)||t.close(e)}}})},staticRenderFns:[]}}),(function(t,e){t.exports={render:function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"md-list-expand-container"},[t._t("default")],2)},staticRenderFns:[]}}),(function(e,n){e.exports=t}),(function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(121),r=i(o),a=n(90),s=i(a),d=n(91),l=i(d),c=n(92),u=i(c),m=n(93),f=i(m),p=n(94),h=i(p),b=n(95),v=i(b),E=n(96),g=i(E),_=n(97),C=i(_),M=n(98),T=i(M),A=n(99),x=i(A),O=n(100),N=i(O),y=n(101),R=i(y),S=n(102),w=i(S),k=n(103),P=i(k),H=n(104),L=i(H),$=n(105),I=i($),D=n(106),B=i(D),j=n(107),F=i(j),W=n(108),Y=i(W),G=n(109),U=i(G),z=n(110),K=i(z),V=n(111),q=i(V),X=n(112),J=i(X),Q=n(113),Z=i(Q),tt=n(114),et=i(tt),nt=n(115),it=i(nt),ot=n(116),rt=i(ot),at=n(117),st=i(at),dt=n(118),lt=i(dt),ct=n(119),ut=i(ct),mt=n(120),ft=i(mt),pt={MdCore:r.default,MdAvatar:s.default,MdBackdrop:l.default,MdBottomBar:u.default,MdButton:f.default,MdButtonToggle:h.default,MdCard:v.default,MdCheckbox:g.default,MdChips:C.default,MdDialog:T.default,MdDivider:x.default,MdFile:N.default,MdIcon:R.default,MdImage:w.default,MdInputContainer:P.default,MdLayout:L.default,MdList:I.default,MdMenu:B.default,MdProgress:F.default,MdRadio:Y.default,MdSelect:U.default,MdSidenav:K.default,MdSnackbar:q.default,MdSpeedDial:J.default,MdSpinner:Z.default,MdSubheader:et.default,MdSwitch:it.default,MdTable:rt.default,MdTabs:st.default,MdToolbar:lt.default,MdTooltip:ut.default,MdWhiteframe:ft.default};pt.install=function(t){for(var e in pt){var n=pt[e];n&&"install"!==e&&t.use(n)}},e.default=pt,t.exports=e.default}),,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,(function(t,e,n){t.exports=n(396)})])}));
  742. },{"vue":8}],7:[function(require,module,exports){
  743. (function (process,global){
  744. /*!
  745. * Vue.js v2.3.3
  746. * (c) 2014-2017 Evan You
  747. * Released under the MIT License.
  748. */
  749. 'use strict';
  750. /* */
  751. // these helpers produces better vm code in JS engines due to their
  752. // explicitness and function inlining
  753. function isUndef (v) {
  754. return v === undefined || v === null
  755. }
  756. function isDef (v) {
  757. return v !== undefined && v !== null
  758. }
  759. function isTrue (v) {
  760. return v === true
  761. }
  762. function isFalse (v) {
  763. return v === false
  764. }
  765. /**
  766. * Check if value is primitive
  767. */
  768. function isPrimitive (value) {
  769. return typeof value === 'string' || typeof value === 'number'
  770. }
  771. /**
  772. * Quick object check - this is primarily used to tell
  773. * Objects from primitive values when we know the value
  774. * is a JSON-compliant type.
  775. */
  776. function isObject (obj) {
  777. return obj !== null && typeof obj === 'object'
  778. }
  779. var _toString = Object.prototype.toString;
  780. /**
  781. * Strict object type check. Only returns true
  782. * for plain JavaScript objects.
  783. */
  784. function isPlainObject (obj) {
  785. return _toString.call(obj) === '[object Object]'
  786. }
  787. function isRegExp (v) {
  788. return _toString.call(v) === '[object RegExp]'
  789. }
  790. /**
  791. * Convert a value to a string that is actually rendered.
  792. */
  793. function toString (val) {
  794. return val == null
  795. ? ''
  796. : typeof val === 'object'
  797. ? JSON.stringify(val, null, 2)
  798. : String(val)
  799. }
  800. /**
  801. * Convert a input value to a number for persistence.
  802. * If the conversion fails, return original string.
  803. */
  804. function toNumber (val) {
  805. var n = parseFloat(val);
  806. return isNaN(n) ? val : n
  807. }
  808. /**
  809. * Make a map and return a function for checking if a key
  810. * is in that map.
  811. */
  812. function makeMap (
  813. str,
  814. expectsLowerCase
  815. ) {
  816. var map = Object.create(null);
  817. var list = str.split(',');
  818. for (var i = 0; i < list.length; i++) {
  819. map[list[i]] = true;
  820. }
  821. return expectsLowerCase
  822. ? function (val) { return map[val.toLowerCase()]; }
  823. : function (val) { return map[val]; }
  824. }
  825. /**
  826. * Check if a tag is a built-in tag.
  827. */
  828. var isBuiltInTag = makeMap('slot,component', true);
  829. /**
  830. * Remove an item from an array
  831. */
  832. function remove (arr, item) {
  833. if (arr.length) {
  834. var index = arr.indexOf(item);
  835. if (index > -1) {
  836. return arr.splice(index, 1)
  837. }
  838. }
  839. }
  840. /**
  841. * Check whether the object has the property.
  842. */
  843. var hasOwnProperty = Object.prototype.hasOwnProperty;
  844. function hasOwn (obj, key) {
  845. return hasOwnProperty.call(obj, key)
  846. }
  847. /**
  848. * Create a cached version of a pure function.
  849. */
  850. function cached (fn) {
  851. var cache = Object.create(null);
  852. return (function cachedFn (str) {
  853. var hit = cache[str];
  854. return hit || (cache[str] = fn(str))
  855. })
  856. }
  857. /**
  858. * Camelize a hyphen-delimited string.
  859. */
  860. var camelizeRE = /-(\w)/g;
  861. var camelize = cached(function (str) {
  862. return str.replace(camelizeRE, function (_, c) { return c ? c.toUpperCase() : ''; })
  863. });
  864. /**
  865. * Capitalize a string.
  866. */
  867. var capitalize = cached(function (str) {
  868. return str.charAt(0).toUpperCase() + str.slice(1)
  869. });
  870. /**
  871. * Hyphenate a camelCase string.
  872. */
  873. var hyphenateRE = /([^-])([A-Z])/g;
  874. var hyphenate = cached(function (str) {
  875. return str
  876. .replace(hyphenateRE, '$1-$2')
  877. .replace(hyphenateRE, '$1-$2')
  878. .toLowerCase()
  879. });
  880. /**
  881. * Simple bind, faster than native
  882. */
  883. function bind (fn, ctx) {
  884. function boundFn (a) {
  885. var l = arguments.length;
  886. return l
  887. ? l > 1
  888. ? fn.apply(ctx, arguments)
  889. : fn.call(ctx, a)
  890. : fn.call(ctx)
  891. }
  892. // record original fn length
  893. boundFn._length = fn.length;
  894. return boundFn
  895. }
  896. /**
  897. * Convert an Array-like object to a real Array.
  898. */
  899. function toArray (list, start) {
  900. start = start || 0;
  901. var i = list.length - start;
  902. var ret = new Array(i);
  903. while (i--) {
  904. ret[i] = list[i + start];
  905. }
  906. return ret
  907. }
  908. /**
  909. * Mix properties into target object.
  910. */
  911. function extend (to, _from) {
  912. for (var key in _from) {
  913. to[key] = _from[key];
  914. }
  915. return to
  916. }
  917. /**
  918. * Merge an Array of Objects into a single Object.
  919. */
  920. function toObject (arr) {
  921. var res = {};
  922. for (var i = 0; i < arr.length; i++) {
  923. if (arr[i]) {
  924. extend(res, arr[i]);
  925. }
  926. }
  927. return res
  928. }
  929. /**
  930. * Perform no operation.
  931. */
  932. function noop () {}
  933. /**
  934. * Always return false.
  935. */
  936. var no = function () { return false; };
  937. /**
  938. * Return same value
  939. */
  940. var identity = function (_) { return _; };
  941. /**
  942. * Generate a static keys string from compiler modules.
  943. */
  944. function genStaticKeys (modules) {
  945. return modules.reduce(function (keys, m) {
  946. return keys.concat(m.staticKeys || [])
  947. }, []).join(',')
  948. }
  949. /**
  950. * Check if two values are loosely equal - that is,
  951. * if they are plain objects, do they have the same shape?
  952. */
  953. function looseEqual (a, b) {
  954. var isObjectA = isObject(a);
  955. var isObjectB = isObject(b);
  956. if (isObjectA && isObjectB) {
  957. try {
  958. return JSON.stringify(a) === JSON.stringify(b)
  959. } catch (e) {
  960. // possible circular reference
  961. return a === b
  962. }
  963. } else if (!isObjectA && !isObjectB) {
  964. return String(a) === String(b)
  965. } else {
  966. return false
  967. }
  968. }
  969. function looseIndexOf (arr, val) {
  970. for (var i = 0; i < arr.length; i++) {
  971. if (looseEqual(arr[i], val)) { return i }
  972. }
  973. return -1
  974. }
  975. /**
  976. * Ensure a function is called only once.
  977. */
  978. function once (fn) {
  979. var called = false;
  980. return function () {
  981. if (!called) {
  982. called = true;
  983. fn.apply(this, arguments);
  984. }
  985. }
  986. }
  987. var SSR_ATTR = 'data-server-rendered';
  988. var ASSET_TYPES = [
  989. 'component',
  990. 'directive',
  991. 'filter'
  992. ];
  993. var LIFECYCLE_HOOKS = [
  994. 'beforeCreate',
  995. 'created',
  996. 'beforeMount',
  997. 'mounted',
  998. 'beforeUpdate',
  999. 'updated',
  1000. 'beforeDestroy',
  1001. 'destroyed',
  1002. 'activated',
  1003. 'deactivated'
  1004. ];
  1005. /* */
  1006. var config = ({
  1007. /**
  1008. * Option merge strategies (used in core/util/options)
  1009. */
  1010. optionMergeStrategies: Object.create(null),
  1011. /**
  1012. * Whether to suppress warnings.
  1013. */
  1014. silent: false,
  1015. /**
  1016. * Show production mode tip message on boot?
  1017. */
  1018. productionTip: process.env.NODE_ENV !== 'production',
  1019. /**
  1020. * Whether to enable devtools
  1021. */
  1022. devtools: process.env.NODE_ENV !== 'production',
  1023. /**
  1024. * Whether to record perf
  1025. */
  1026. performance: false,
  1027. /**
  1028. * Error handler for watcher errors
  1029. */
  1030. errorHandler: null,
  1031. /**
  1032. * Ignore certain custom elements
  1033. */
  1034. ignoredElements: [],
  1035. /**
  1036. * Custom user key aliases for v-on
  1037. */
  1038. keyCodes: Object.create(null),
  1039. /**
  1040. * Check if a tag is reserved so that it cannot be registered as a
  1041. * component. This is platform-dependent and may be overwritten.
  1042. */
  1043. isReservedTag: no,
  1044. /**
  1045. * Check if an attribute is reserved so that it cannot be used as a component
  1046. * prop. This is platform-dependent and may be overwritten.
  1047. */
  1048. isReservedAttr: no,
  1049. /**
  1050. * Check if a tag is an unknown element.
  1051. * Platform-dependent.
  1052. */
  1053. isUnknownElement: no,
  1054. /**
  1055. * Get the namespace of an element
  1056. */
  1057. getTagNamespace: noop,
  1058. /**
  1059. * Parse the real tag name for the specific platform.
  1060. */
  1061. parsePlatformTagName: identity,
  1062. /**
  1063. * Check if an attribute must be bound using property, e.g. value
  1064. * Platform-dependent.
  1065. */
  1066. mustUseProp: no,
  1067. /**
  1068. * Exposed for legacy reasons
  1069. */
  1070. _lifecycleHooks: LIFECYCLE_HOOKS
  1071. });
  1072. /* */
  1073. var emptyObject = Object.freeze({});
  1074. /**
  1075. * Check if a string starts with $ or _
  1076. */
  1077. function isReserved (str) {
  1078. var c = (str + '').charCodeAt(0);
  1079. return c === 0x24 || c === 0x5F
  1080. }
  1081. /**
  1082. * Define a property.
  1083. */
  1084. function def (obj, key, val, enumerable) {
  1085. Object.defineProperty(obj, key, {
  1086. value: val,
  1087. enumerable: !!enumerable,
  1088. writable: true,
  1089. configurable: true
  1090. });
  1091. }
  1092. /**
  1093. * Parse simple path.
  1094. */
  1095. var bailRE = /[^\w.$]/;
  1096. function parsePath (path) {
  1097. if (bailRE.test(path)) {
  1098. return
  1099. }
  1100. var segments = path.split('.');
  1101. return function (obj) {
  1102. for (var i = 0; i < segments.length; i++) {
  1103. if (!obj) { return }
  1104. obj = obj[segments[i]];
  1105. }
  1106. return obj
  1107. }
  1108. }
  1109. /* */
  1110. var warn = noop;
  1111. var tip = noop;
  1112. var formatComponentName = (null); // work around flow check
  1113. if (process.env.NODE_ENV !== 'production') {
  1114. var hasConsole = typeof console !== 'undefined';
  1115. var classifyRE = /(?:^|[-_])(\w)/g;
  1116. var classify = function (str) { return str
  1117. .replace(classifyRE, function (c) { return c.toUpperCase(); })
  1118. .replace(/[-_]/g, ''); };
  1119. warn = function (msg, vm) {
  1120. if (hasConsole && (!config.silent)) {
  1121. console.error("[Vue warn]: " + msg + (
  1122. vm ? generateComponentTrace(vm) : ''
  1123. ));
  1124. }
  1125. };
  1126. tip = function (msg, vm) {
  1127. if (hasConsole && (!config.silent)) {
  1128. console.warn("[Vue tip]: " + msg + (
  1129. vm ? generateComponentTrace(vm) : ''
  1130. ));
  1131. }
  1132. };
  1133. formatComponentName = function (vm, includeFile) {
  1134. if (vm.$root === vm) {
  1135. return '<Root>'
  1136. }
  1137. var name = typeof vm === 'string'
  1138. ? vm
  1139. : typeof vm === 'function' && vm.options
  1140. ? vm.options.name
  1141. : vm._isVue
  1142. ? vm.$options.name || vm.$options._componentTag
  1143. : vm.name;
  1144. var file = vm._isVue && vm.$options.__file;
  1145. if (!name && file) {
  1146. var match = file.match(/([^/\\]+)\.vue$/);
  1147. name = match && match[1];
  1148. }
  1149. return (
  1150. (name ? ("<" + (classify(name)) + ">") : "<Anonymous>") +
  1151. (file && includeFile !== false ? (" at " + file) : '')
  1152. )
  1153. };
  1154. var repeat = function (str, n) {
  1155. var res = '';
  1156. while (n) {
  1157. if (n % 2 === 1) { res += str; }
  1158. if (n > 1) { str += str; }
  1159. n >>= 1;
  1160. }
  1161. return res
  1162. };
  1163. var generateComponentTrace = function (vm) {
  1164. if (vm._isVue && vm.$parent) {
  1165. var tree = [];
  1166. var currentRecursiveSequence = 0;
  1167. while (vm) {
  1168. if (tree.length > 0) {
  1169. var last = tree[tree.length - 1];
  1170. if (last.constructor === vm.constructor) {
  1171. currentRecursiveSequence++;
  1172. vm = vm.$parent;
  1173. continue
  1174. } else if (currentRecursiveSequence > 0) {
  1175. tree[tree.length - 1] = [last, currentRecursiveSequence];
  1176. currentRecursiveSequence = 0;
  1177. }
  1178. }
  1179. tree.push(vm);
  1180. vm = vm.$parent;
  1181. }
  1182. return '\n\nfound in\n\n' + tree
  1183. .map(function (vm, i) { return ("" + (i === 0 ? '---> ' : repeat(' ', 5 + i * 2)) + (Array.isArray(vm)
  1184. ? ((formatComponentName(vm[0])) + "... (" + (vm[1]) + " recursive calls)")
  1185. : formatComponentName(vm))); })
  1186. .join('\n')
  1187. } else {
  1188. return ("\n\n(found in " + (formatComponentName(vm)) + ")")
  1189. }
  1190. };
  1191. }
  1192. /* */
  1193. function handleError (err, vm, info) {
  1194. if (config.errorHandler) {
  1195. config.errorHandler.call(null, err, vm, info);
  1196. } else {
  1197. if (process.env.NODE_ENV !== 'production') {
  1198. warn(("Error in " + info + ": \"" + (err.toString()) + "\""), vm);
  1199. }
  1200. /* istanbul ignore else */
  1201. if (inBrowser && typeof console !== 'undefined') {
  1202. console.error(err);
  1203. } else {
  1204. throw err
  1205. }
  1206. }
  1207. }
  1208. /* */
  1209. /* globals MutationObserver */
  1210. // can we use __proto__?
  1211. var hasProto = '__proto__' in {};
  1212. // Browser environment sniffing
  1213. var inBrowser = typeof window !== 'undefined';
  1214. var UA = inBrowser && window.navigator.userAgent.toLowerCase();
  1215. var isIE = UA && /msie|trident/.test(UA);
  1216. var isIE9 = UA && UA.indexOf('msie 9.0') > 0;
  1217. var isEdge = UA && UA.indexOf('edge/') > 0;
  1218. var isAndroid = UA && UA.indexOf('android') > 0;
  1219. var isIOS = UA && /iphone|ipad|ipod|ios/.test(UA);
  1220. var isChrome = UA && /chrome\/\d+/.test(UA) && !isEdge;
  1221. var supportsPassive = false;
  1222. if (inBrowser) {
  1223. try {
  1224. var opts = {};
  1225. Object.defineProperty(opts, 'passive', ({
  1226. get: function get () {
  1227. /* istanbul ignore next */
  1228. supportsPassive = true;
  1229. }
  1230. } )); // https://github.com/facebook/flow/issues/285
  1231. window.addEventListener('test-passive', null, opts);
  1232. } catch (e) {}
  1233. }
  1234. // this needs to be lazy-evaled because vue may be required before
  1235. // vue-server-renderer can set VUE_ENV
  1236. var _isServer;
  1237. var isServerRendering = function () {
  1238. if (_isServer === undefined) {
  1239. /* istanbul ignore if */
  1240. if (!inBrowser && typeof global !== 'undefined') {
  1241. // detect presence of vue-server-renderer and avoid
  1242. // Webpack shimming the process
  1243. _isServer = global['process'].env.VUE_ENV === 'server';
  1244. } else {
  1245. _isServer = false;
  1246. }
  1247. }
  1248. return _isServer
  1249. };
  1250. // detect devtools
  1251. var devtools = inBrowser && window.__VUE_DEVTOOLS_GLOBAL_HOOK__;
  1252. /* istanbul ignore next */
  1253. function isNative (Ctor) {
  1254. return typeof Ctor === 'function' && /native code/.test(Ctor.toString())
  1255. }
  1256. var hasSymbol =
  1257. typeof Symbol !== 'undefined' && isNative(Symbol) &&
  1258. typeof Reflect !== 'undefined' && isNative(Reflect.ownKeys);
  1259. /**
  1260. * Defer a task to execute it asynchronously.
  1261. */
  1262. var nextTick = (function () {
  1263. var callbacks = [];
  1264. var pending = false;
  1265. var timerFunc;
  1266. function nextTickHandler () {
  1267. pending = false;
  1268. var copies = callbacks.slice(0);
  1269. callbacks.length = 0;
  1270. for (var i = 0; i < copies.length; i++) {
  1271. copies[i]();
  1272. }
  1273. }
  1274. // the nextTick behavior leverages the microtask queue, which can be accessed
  1275. // via either native Promise.then or MutationObserver.
  1276. // MutationObserver has wider support, however it is seriously bugged in
  1277. // UIWebView in iOS >= 9.3.3 when triggered in touch event handlers. It
  1278. // completely stops working after triggering a few times... so, if native
  1279. // Promise is available, we will use it:
  1280. /* istanbul ignore if */
  1281. if (typeof Promise !== 'undefined' && isNative(Promise)) {
  1282. var p = Promise.resolve();
  1283. var logError = function (err) { console.error(err); };
  1284. timerFunc = function () {
  1285. p.then(nextTickHandler).catch(logError);
  1286. // in problematic UIWebViews, Promise.then doesn't completely break, but
  1287. // it can get stuck in a weird state where callbacks are pushed into the
  1288. // microtask queue but the queue isn't being flushed, until the browser
  1289. // needs to do some other work, e.g. handle a timer. Therefore we can
  1290. // "force" the microtask queue to be flushed by adding an empty timer.
  1291. if (isIOS) { setTimeout(noop); }
  1292. };
  1293. } else if (typeof MutationObserver !== 'undefined' && (
  1294. isNative(MutationObserver) ||
  1295. // PhantomJS and iOS 7.x
  1296. MutationObserver.toString() === '[object MutationObserverConstructor]'
  1297. )) {
  1298. // use MutationObserver where native Promise is not available,
  1299. // e.g. PhantomJS IE11, iOS7, Android 4.4
  1300. var counter = 1;
  1301. var observer = new MutationObserver(nextTickHandler);
  1302. var textNode = document.createTextNode(String(counter));
  1303. observer.observe(textNode, {
  1304. characterData: true
  1305. });
  1306. timerFunc = function () {
  1307. counter = (counter + 1) % 2;
  1308. textNode.data = String(counter);
  1309. };
  1310. } else {
  1311. // fallback to setTimeout
  1312. /* istanbul ignore next */
  1313. timerFunc = function () {
  1314. setTimeout(nextTickHandler, 0);
  1315. };
  1316. }
  1317. return function queueNextTick (cb, ctx) {
  1318. var _resolve;
  1319. callbacks.push(function () {
  1320. if (cb) {
  1321. try {
  1322. cb.call(ctx);
  1323. } catch (e) {
  1324. handleError(e, ctx, 'nextTick');
  1325. }
  1326. } else if (_resolve) {
  1327. _resolve(ctx);
  1328. }
  1329. });
  1330. if (!pending) {
  1331. pending = true;
  1332. timerFunc();
  1333. }
  1334. if (!cb && typeof Promise !== 'undefined') {
  1335. return new Promise(function (resolve, reject) {
  1336. _resolve = resolve;
  1337. })
  1338. }
  1339. }
  1340. })();
  1341. var _Set;
  1342. /* istanbul ignore if */
  1343. if (typeof Set !== 'undefined' && isNative(Set)) {
  1344. // use native Set when available.
  1345. _Set = Set;
  1346. } else {
  1347. // a non-standard Set polyfill that only works with primitive keys.
  1348. _Set = (function () {
  1349. function Set () {
  1350. this.set = Object.create(null);
  1351. }
  1352. Set.prototype.has = function has (key) {
  1353. return this.set[key] === true
  1354. };
  1355. Set.prototype.add = function add (key) {
  1356. this.set[key] = true;
  1357. };
  1358. Set.prototype.clear = function clear () {
  1359. this.set = Object.create(null);
  1360. };
  1361. return Set;
  1362. }());
  1363. }
  1364. /* */
  1365. var uid = 0;
  1366. /**
  1367. * A dep is an observable that can have multiple
  1368. * directives subscribing to it.
  1369. */
  1370. var Dep = function Dep () {
  1371. this.id = uid++;
  1372. this.subs = [];
  1373. };
  1374. Dep.prototype.addSub = function addSub (sub) {
  1375. this.subs.push(sub);
  1376. };
  1377. Dep.prototype.removeSub = function removeSub (sub) {
  1378. remove(this.subs, sub);
  1379. };
  1380. Dep.prototype.depend = function depend () {
  1381. if (Dep.target) {
  1382. Dep.target.addDep(this);
  1383. }
  1384. };
  1385. Dep.prototype.notify = function notify () {
  1386. // stabilize the subscriber list first
  1387. var subs = this.subs.slice();
  1388. for (var i = 0, l = subs.length; i < l; i++) {
  1389. subs[i].update();
  1390. }
  1391. };
  1392. // the current target watcher being evaluated.
  1393. // this is globally unique because there could be only one
  1394. // watcher being evaluated at any time.
  1395. Dep.target = null;
  1396. var targetStack = [];
  1397. function pushTarget (_target) {
  1398. if (Dep.target) { targetStack.push(Dep.target); }
  1399. Dep.target = _target;
  1400. }
  1401. function popTarget () {
  1402. Dep.target = targetStack.pop();
  1403. }
  1404. /*
  1405. * not type checking this file because flow doesn't play well with
  1406. * dynamically accessing methods on Array prototype
  1407. */
  1408. var arrayProto = Array.prototype;
  1409. var arrayMethods = Object.create(arrayProto);[
  1410. 'push',
  1411. 'pop',
  1412. 'shift',
  1413. 'unshift',
  1414. 'splice',
  1415. 'sort',
  1416. 'reverse'
  1417. ]
  1418. .forEach(function (method) {
  1419. // cache original method
  1420. var original = arrayProto[method];
  1421. def(arrayMethods, method, function mutator () {
  1422. var arguments$1 = arguments;
  1423. // avoid leaking arguments:
  1424. // http://jsperf.com/closure-with-arguments
  1425. var i = arguments.length;
  1426. var args = new Array(i);
  1427. while (i--) {
  1428. args[i] = arguments$1[i];
  1429. }
  1430. var result = original.apply(this, args);
  1431. var ob = this.__ob__;
  1432. var inserted;
  1433. switch (method) {
  1434. case 'push':
  1435. inserted = args;
  1436. break
  1437. case 'unshift':
  1438. inserted = args;
  1439. break
  1440. case 'splice':
  1441. inserted = args.slice(2);
  1442. break
  1443. }
  1444. if (inserted) { ob.observeArray(inserted); }
  1445. // notify change
  1446. ob.dep.notify();
  1447. return result
  1448. });
  1449. });
  1450. /* */
  1451. var arrayKeys = Object.getOwnPropertyNames(arrayMethods);
  1452. /**
  1453. * By default, when a reactive property is set, the new value is
  1454. * also converted to become reactive. However when passing down props,
  1455. * we don't want to force conversion because the value may be a nested value
  1456. * under a frozen data structure. Converting it would defeat the optimization.
  1457. */
  1458. var observerState = {
  1459. shouldConvert: true,
  1460. isSettingProps: false
  1461. };
  1462. /**
  1463. * Observer class that are attached to each observed
  1464. * object. Once attached, the observer converts target
  1465. * object's property keys into getter/setters that
  1466. * collect dependencies and dispatches updates.
  1467. */
  1468. var Observer = function Observer (value) {
  1469. this.value = value;
  1470. this.dep = new Dep();
  1471. this.vmCount = 0;
  1472. def(value, '__ob__', this);
  1473. if (Array.isArray(value)) {
  1474. var augment = hasProto
  1475. ? protoAugment
  1476. : copyAugment;
  1477. augment(value, arrayMethods, arrayKeys);
  1478. this.observeArray(value);
  1479. } else {
  1480. this.walk(value);
  1481. }
  1482. };
  1483. /**
  1484. * Walk through each property and convert them into
  1485. * getter/setters. This method should only be called when
  1486. * value type is Object.
  1487. */
  1488. Observer.prototype.walk = function walk (obj) {
  1489. var keys = Object.keys(obj);
  1490. for (var i = 0; i < keys.length; i++) {
  1491. defineReactive$$1(obj, keys[i], obj[keys[i]]);
  1492. }
  1493. };
  1494. /**
  1495. * Observe a list of Array items.
  1496. */
  1497. Observer.prototype.observeArray = function observeArray (items) {
  1498. for (var i = 0, l = items.length; i < l; i++) {
  1499. observe(items[i]);
  1500. }
  1501. };
  1502. // helpers
  1503. /**
  1504. * Augment an target Object or Array by intercepting
  1505. * the prototype chain using __proto__
  1506. */
  1507. function protoAugment (target, src) {
  1508. /* eslint-disable no-proto */
  1509. target.__proto__ = src;
  1510. /* eslint-enable no-proto */
  1511. }
  1512. /**
  1513. * Augment an target Object or Array by defining
  1514. * hidden properties.
  1515. */
  1516. /* istanbul ignore next */
  1517. function copyAugment (target, src, keys) {
  1518. for (var i = 0, l = keys.length; i < l; i++) {
  1519. var key = keys[i];
  1520. def(target, key, src[key]);
  1521. }
  1522. }
  1523. /**
  1524. * Attempt to create an observer instance for a value,
  1525. * returns the new observer if successfully observed,
  1526. * or the existing observer if the value already has one.
  1527. */
  1528. function observe (value, asRootData) {
  1529. if (!isObject(value)) {
  1530. return
  1531. }
  1532. var ob;
  1533. if (hasOwn(value, '__ob__') && value.__ob__ instanceof Observer) {
  1534. ob = value.__ob__;
  1535. } else if (
  1536. observerState.shouldConvert &&
  1537. !isServerRendering() &&
  1538. (Array.isArray(value) || isPlainObject(value)) &&
  1539. Object.isExtensible(value) &&
  1540. !value._isVue
  1541. ) {
  1542. ob = new Observer(value);
  1543. }
  1544. if (asRootData && ob) {
  1545. ob.vmCount++;
  1546. }
  1547. return ob
  1548. }
  1549. /**
  1550. * Define a reactive property on an Object.
  1551. */
  1552. function defineReactive$$1 (
  1553. obj,
  1554. key,
  1555. val,
  1556. customSetter
  1557. ) {
  1558. var dep = new Dep();
  1559. var property = Object.getOwnPropertyDescriptor(obj, key);
  1560. if (property && property.configurable === false) {
  1561. return
  1562. }
  1563. // cater for pre-defined getter/setters
  1564. var getter = property && property.get;
  1565. var setter = property && property.set;
  1566. var childOb = observe(val);
  1567. Object.defineProperty(obj, key, {
  1568. enumerable: true,
  1569. configurable: true,
  1570. get: function reactiveGetter () {
  1571. var value = getter ? getter.call(obj) : val;
  1572. if (Dep.target) {
  1573. dep.depend();
  1574. if (childOb) {
  1575. childOb.dep.depend();
  1576. }
  1577. if (Array.isArray(value)) {
  1578. dependArray(value);
  1579. }
  1580. }
  1581. return value
  1582. },
  1583. set: function reactiveSetter (newVal) {
  1584. var value = getter ? getter.call(obj) : val;
  1585. /* eslint-disable no-self-compare */
  1586. if (newVal === value || (newVal !== newVal && value !== value)) {
  1587. return
  1588. }
  1589. /* eslint-enable no-self-compare */
  1590. if (process.env.NODE_ENV !== 'production' && customSetter) {
  1591. customSetter();
  1592. }
  1593. if (setter) {
  1594. setter.call(obj, newVal);
  1595. } else {
  1596. val = newVal;
  1597. }
  1598. childOb = observe(newVal);
  1599. dep.notify();
  1600. }
  1601. });
  1602. }
  1603. /**
  1604. * Set a property on an object. Adds the new property and
  1605. * triggers change notification if the property doesn't
  1606. * already exist.
  1607. */
  1608. function set (target, key, val) {
  1609. if (Array.isArray(target) && typeof key === 'number') {
  1610. target.length = Math.max(target.length, key);
  1611. target.splice(key, 1, val);
  1612. return val
  1613. }
  1614. if (hasOwn(target, key)) {
  1615. target[key] = val;
  1616. return val
  1617. }
  1618. var ob = (target ).__ob__;
  1619. if (target._isVue || (ob && ob.vmCount)) {
  1620. process.env.NODE_ENV !== 'production' && warn(
  1621. 'Avoid adding reactive properties to a Vue instance or its root $data ' +
  1622. 'at runtime - declare it upfront in the data option.'
  1623. );
  1624. return val
  1625. }
  1626. if (!ob) {
  1627. target[key] = val;
  1628. return val
  1629. }
  1630. defineReactive$$1(ob.value, key, val);
  1631. ob.dep.notify();
  1632. return val
  1633. }
  1634. /**
  1635. * Delete a property and trigger change if necessary.
  1636. */
  1637. function del (target, key) {
  1638. if (Array.isArray(target) && typeof key === 'number') {
  1639. target.splice(key, 1);
  1640. return
  1641. }
  1642. var ob = (target ).__ob__;
  1643. if (target._isVue || (ob && ob.vmCount)) {
  1644. process.env.NODE_ENV !== 'production' && warn(
  1645. 'Avoid deleting properties on a Vue instance or its root $data ' +
  1646. '- just set it to null.'
  1647. );
  1648. return
  1649. }
  1650. if (!hasOwn(target, key)) {
  1651. return
  1652. }
  1653. delete target[key];
  1654. if (!ob) {
  1655. return
  1656. }
  1657. ob.dep.notify();
  1658. }
  1659. /**
  1660. * Collect dependencies on array elements when the array is touched, since
  1661. * we cannot intercept array element access like property getters.
  1662. */
  1663. function dependArray (value) {
  1664. for (var e = (void 0), i = 0, l = value.length; i < l; i++) {
  1665. e = value[i];
  1666. e && e.__ob__ && e.__ob__.dep.depend();
  1667. if (Array.isArray(e)) {
  1668. dependArray(e);
  1669. }
  1670. }
  1671. }
  1672. /* */
  1673. /**
  1674. * Option overwriting strategies are functions that handle
  1675. * how to merge a parent option value and a child option
  1676. * value into the final value.
  1677. */
  1678. var strats = config.optionMergeStrategies;
  1679. /**
  1680. * Options with restrictions
  1681. */
  1682. if (process.env.NODE_ENV !== 'production') {
  1683. strats.el = strats.propsData = function (parent, child, vm, key) {
  1684. if (!vm) {
  1685. warn(
  1686. "option \"" + key + "\" can only be used during instance " +
  1687. 'creation with the `new` keyword.'
  1688. );
  1689. }
  1690. return defaultStrat(parent, child)
  1691. };
  1692. }
  1693. /**
  1694. * Helper that recursively merges two data objects together.
  1695. */
  1696. function mergeData (to, from) {
  1697. if (!from) { return to }
  1698. var key, toVal, fromVal;
  1699. var keys = Object.keys(from);
  1700. for (var i = 0; i < keys.length; i++) {
  1701. key = keys[i];
  1702. toVal = to[key];
  1703. fromVal = from[key];
  1704. if (!hasOwn(to, key)) {
  1705. set(to, key, fromVal);
  1706. } else if (isPlainObject(toVal) && isPlainObject(fromVal)) {
  1707. mergeData(toVal, fromVal);
  1708. }
  1709. }
  1710. return to
  1711. }
  1712. /**
  1713. * Data
  1714. */
  1715. strats.data = function (
  1716. parentVal,
  1717. childVal,
  1718. vm
  1719. ) {
  1720. if (!vm) {
  1721. // in a Vue.extend merge, both should be functions
  1722. if (!childVal) {
  1723. return parentVal
  1724. }
  1725. if (typeof childVal !== 'function') {
  1726. process.env.NODE_ENV !== 'production' && warn(
  1727. 'The "data" option should be a function ' +
  1728. 'that returns a per-instance value in component ' +
  1729. 'definitions.',
  1730. vm
  1731. );
  1732. return parentVal
  1733. }
  1734. if (!parentVal) {
  1735. return childVal
  1736. }
  1737. // when parentVal & childVal are both present,
  1738. // we need to return a function that returns the
  1739. // merged result of both functions... no need to
  1740. // check if parentVal is a function here because
  1741. // it has to be a function to pass previous merges.
  1742. return function mergedDataFn () {
  1743. return mergeData(
  1744. childVal.call(this),
  1745. parentVal.call(this)
  1746. )
  1747. }
  1748. } else if (parentVal || childVal) {
  1749. return function mergedInstanceDataFn () {
  1750. // instance merge
  1751. var instanceData = typeof childVal === 'function'
  1752. ? childVal.call(vm)
  1753. : childVal;
  1754. var defaultData = typeof parentVal === 'function'
  1755. ? parentVal.call(vm)
  1756. : undefined;
  1757. if (instanceData) {
  1758. return mergeData(instanceData, defaultData)
  1759. } else {
  1760. return defaultData
  1761. }
  1762. }
  1763. }
  1764. };
  1765. /**
  1766. * Hooks and props are merged as arrays.
  1767. */
  1768. function mergeHook (
  1769. parentVal,
  1770. childVal
  1771. ) {
  1772. return childVal
  1773. ? parentVal
  1774. ? parentVal.concat(childVal)
  1775. : Array.isArray(childVal)
  1776. ? childVal
  1777. : [childVal]
  1778. : parentVal
  1779. }
  1780. LIFECYCLE_HOOKS.forEach(function (hook) {
  1781. strats[hook] = mergeHook;
  1782. });
  1783. /**
  1784. * Assets
  1785. *
  1786. * When a vm is present (instance creation), we need to do
  1787. * a three-way merge between constructor options, instance
  1788. * options and parent options.
  1789. */
  1790. function mergeAssets (parentVal, childVal) {
  1791. var res = Object.create(parentVal || null);
  1792. return childVal
  1793. ? extend(res, childVal)
  1794. : res
  1795. }
  1796. ASSET_TYPES.forEach(function (type) {
  1797. strats[type + 's'] = mergeAssets;
  1798. });
  1799. /**
  1800. * Watchers.
  1801. *
  1802. * Watchers hashes should not overwrite one
  1803. * another, so we merge them as arrays.
  1804. */
  1805. strats.watch = function (parentVal, childVal) {
  1806. /* istanbul ignore if */
  1807. if (!childVal) { return Object.create(parentVal || null) }
  1808. if (!parentVal) { return childVal }
  1809. var ret = {};
  1810. extend(ret, parentVal);
  1811. for (var key in childVal) {
  1812. var parent = ret[key];
  1813. var child = childVal[key];
  1814. if (parent && !Array.isArray(parent)) {
  1815. parent = [parent];
  1816. }
  1817. ret[key] = parent
  1818. ? parent.concat(child)
  1819. : [child];
  1820. }
  1821. return ret
  1822. };
  1823. /**
  1824. * Other object hashes.
  1825. */
  1826. strats.props =
  1827. strats.methods =
  1828. strats.computed = function (parentVal, childVal) {
  1829. if (!childVal) { return Object.create(parentVal || null) }
  1830. if (!parentVal) { return childVal }
  1831. var ret = Object.create(null);
  1832. extend(ret, parentVal);
  1833. extend(ret, childVal);
  1834. return ret
  1835. };
  1836. /**
  1837. * Default strategy.
  1838. */
  1839. var defaultStrat = function (parentVal, childVal) {
  1840. return childVal === undefined
  1841. ? parentVal
  1842. : childVal
  1843. };
  1844. /**
  1845. * Validate component names
  1846. */
  1847. function checkComponents (options) {
  1848. for (var key in options.components) {
  1849. var lower = key.toLowerCase();
  1850. if (isBuiltInTag(lower) || config.isReservedTag(lower)) {
  1851. warn(
  1852. 'Do not use built-in or reserved HTML elements as component ' +
  1853. 'id: ' + key
  1854. );
  1855. }
  1856. }
  1857. }
  1858. /**
  1859. * Ensure all props option syntax are normalized into the
  1860. * Object-based format.
  1861. */
  1862. function normalizeProps (options) {
  1863. var props = options.props;
  1864. if (!props) { return }
  1865. var res = {};
  1866. var i, val, name;
  1867. if (Array.isArray(props)) {
  1868. i = props.length;
  1869. while (i--) {
  1870. val = props[i];
  1871. if (typeof val === 'string') {
  1872. name = camelize(val);
  1873. res[name] = { type: null };
  1874. } else if (process.env.NODE_ENV !== 'production') {
  1875. warn('props must be strings when using array syntax.');
  1876. }
  1877. }
  1878. } else if (isPlainObject(props)) {
  1879. for (var key in props) {
  1880. val = props[key];
  1881. name = camelize(key);
  1882. res[name] = isPlainObject(val)
  1883. ? val
  1884. : { type: val };
  1885. }
  1886. }
  1887. options.props = res;
  1888. }
  1889. /**
  1890. * Normalize raw function directives into object format.
  1891. */
  1892. function normalizeDirectives (options) {
  1893. var dirs = options.directives;
  1894. if (dirs) {
  1895. for (var key in dirs) {
  1896. var def = dirs[key];
  1897. if (typeof def === 'function') {
  1898. dirs[key] = { bind: def, update: def };
  1899. }
  1900. }
  1901. }
  1902. }
  1903. /**
  1904. * Merge two option objects into a new one.
  1905. * Core utility used in both instantiation and inheritance.
  1906. */
  1907. function mergeOptions (
  1908. parent,
  1909. child,
  1910. vm
  1911. ) {
  1912. if (process.env.NODE_ENV !== 'production') {
  1913. checkComponents(child);
  1914. }
  1915. if (typeof child === 'function') {
  1916. child = child.options;
  1917. }
  1918. normalizeProps(child);
  1919. normalizeDirectives(child);
  1920. var extendsFrom = child.extends;
  1921. if (extendsFrom) {
  1922. parent = mergeOptions(parent, extendsFrom, vm);
  1923. }
  1924. if (child.mixins) {
  1925. for (var i = 0, l = child.mixins.length; i < l; i++) {
  1926. parent = mergeOptions(parent, child.mixins[i], vm);
  1927. }
  1928. }
  1929. var options = {};
  1930. var key;
  1931. for (key in parent) {
  1932. mergeField(key);
  1933. }
  1934. for (key in child) {
  1935. if (!hasOwn(parent, key)) {
  1936. mergeField(key);
  1937. }
  1938. }
  1939. function mergeField (key) {
  1940. var strat = strats[key] || defaultStrat;
  1941. options[key] = strat(parent[key], child[key], vm, key);
  1942. }
  1943. return options
  1944. }
  1945. /**
  1946. * Resolve an asset.
  1947. * This function is used because child instances need access
  1948. * to assets defined in its ancestor chain.
  1949. */
  1950. function resolveAsset (
  1951. options,
  1952. type,
  1953. id,
  1954. warnMissing
  1955. ) {
  1956. /* istanbul ignore if */
  1957. if (typeof id !== 'string') {
  1958. return
  1959. }
  1960. var assets = options[type];
  1961. // check local registration variations first
  1962. if (hasOwn(assets, id)) { return assets[id] }
  1963. var camelizedId = camelize(id);
  1964. if (hasOwn(assets, camelizedId)) { return assets[camelizedId] }
  1965. var PascalCaseId = capitalize(camelizedId);
  1966. if (hasOwn(assets, PascalCaseId)) { return assets[PascalCaseId] }
  1967. // fallback to prototype chain
  1968. var res = assets[id] || assets[camelizedId] || assets[PascalCaseId];
  1969. if (process.env.NODE_ENV !== 'production' && warnMissing && !res) {
  1970. warn(
  1971. 'Failed to resolve ' + type.slice(0, -1) + ': ' + id,
  1972. options
  1973. );
  1974. }
  1975. return res
  1976. }
  1977. /* */
  1978. function validateProp (
  1979. key,
  1980. propOptions,
  1981. propsData,
  1982. vm
  1983. ) {
  1984. var prop = propOptions[key];
  1985. var absent = !hasOwn(propsData, key);
  1986. var value = propsData[key];
  1987. // handle boolean props
  1988. if (isType(Boolean, prop.type)) {
  1989. if (absent && !hasOwn(prop, 'default')) {
  1990. value = false;
  1991. } else if (!isType(String, prop.type) && (value === '' || value === hyphenate(key))) {
  1992. value = true;
  1993. }
  1994. }
  1995. // check default value
  1996. if (value === undefined) {
  1997. value = getPropDefaultValue(vm, prop, key);
  1998. // since the default value is a fresh copy,
  1999. // make sure to observe it.
  2000. var prevShouldConvert = observerState.shouldConvert;
  2001. observerState.shouldConvert = true;
  2002. observe(value);
  2003. observerState.shouldConvert = prevShouldConvert;
  2004. }
  2005. if (process.env.NODE_ENV !== 'production') {
  2006. assertProp(prop, key, value, vm, absent);
  2007. }
  2008. return value
  2009. }
  2010. /**
  2011. * Get the default value of a prop.
  2012. */
  2013. function getPropDefaultValue (vm, prop, key) {
  2014. // no default, return undefined
  2015. if (!hasOwn(prop, 'default')) {
  2016. return undefined
  2017. }
  2018. var def = prop.default;
  2019. // warn against non-factory defaults for Object & Array
  2020. if (process.env.NODE_ENV !== 'production' && isObject(def)) {
  2021. warn(
  2022. 'Invalid default value for prop "' + key + '": ' +
  2023. 'Props with type Object/Array must use a factory function ' +
  2024. 'to return the default value.',
  2025. vm
  2026. );
  2027. }
  2028. // the raw prop value was also undefined from previous render,
  2029. // return previous default value to avoid unnecessary watcher trigger
  2030. if (vm && vm.$options.propsData &&
  2031. vm.$options.propsData[key] === undefined &&
  2032. vm._props[key] !== undefined
  2033. ) {
  2034. return vm._props[key]
  2035. }
  2036. // call factory function for non-Function types
  2037. // a value is Function if its prototype is function even across different execution context
  2038. return typeof def === 'function' && getType(prop.type) !== 'Function'
  2039. ? def.call(vm)
  2040. : def
  2041. }
  2042. /**
  2043. * Assert whether a prop is valid.
  2044. */
  2045. function assertProp (
  2046. prop,
  2047. name,
  2048. value,
  2049. vm,
  2050. absent
  2051. ) {
  2052. if (prop.required && absent) {
  2053. warn(
  2054. 'Missing required prop: "' + name + '"',
  2055. vm
  2056. );
  2057. return
  2058. }
  2059. if (value == null && !prop.required) {
  2060. return
  2061. }
  2062. var type = prop.type;
  2063. var valid = !type || type === true;
  2064. var expectedTypes = [];
  2065. if (type) {
  2066. if (!Array.isArray(type)) {
  2067. type = [type];
  2068. }
  2069. for (var i = 0; i < type.length && !valid; i++) {
  2070. var assertedType = assertType(value, type[i]);
  2071. expectedTypes.push(assertedType.expectedType || '');
  2072. valid = assertedType.valid;
  2073. }
  2074. }
  2075. if (!valid) {
  2076. warn(
  2077. 'Invalid prop: type check failed for prop "' + name + '".' +
  2078. ' Expected ' + expectedTypes.map(capitalize).join(', ') +
  2079. ', got ' + Object.prototype.toString.call(value).slice(8, -1) + '.',
  2080. vm
  2081. );
  2082. return
  2083. }
  2084. var validator = prop.validator;
  2085. if (validator) {
  2086. if (!validator(value)) {
  2087. warn(
  2088. 'Invalid prop: custom validator check failed for prop "' + name + '".',
  2089. vm
  2090. );
  2091. }
  2092. }
  2093. }
  2094. var simpleCheckRE = /^(String|Number|Boolean|Function|Symbol)$/;
  2095. function assertType (value, type) {
  2096. var valid;
  2097. var expectedType = getType(type);
  2098. if (simpleCheckRE.test(expectedType)) {
  2099. valid = typeof value === expectedType.toLowerCase();
  2100. } else if (expectedType === 'Object') {
  2101. valid = isPlainObject(value);
  2102. } else if (expectedType === 'Array') {
  2103. valid = Array.isArray(value);
  2104. } else {
  2105. valid = value instanceof type;
  2106. }
  2107. return {
  2108. valid: valid,
  2109. expectedType: expectedType
  2110. }
  2111. }
  2112. /**
  2113. * Use function string name to check built-in types,
  2114. * because a simple equality check will fail when running
  2115. * across different vms / iframes.
  2116. */
  2117. function getType (fn) {
  2118. var match = fn && fn.toString().match(/^\s*function (\w+)/);
  2119. return match ? match[1] : ''
  2120. }
  2121. function isType (type, fn) {
  2122. if (!Array.isArray(fn)) {
  2123. return getType(fn) === getType(type)
  2124. }
  2125. for (var i = 0, len = fn.length; i < len; i++) {
  2126. if (getType(fn[i]) === getType(type)) {
  2127. return true
  2128. }
  2129. }
  2130. /* istanbul ignore next */
  2131. return false
  2132. }
  2133. /* */
  2134. var mark;
  2135. var measure;
  2136. if (process.env.NODE_ENV !== 'production') {
  2137. var perf = inBrowser && window.performance;
  2138. /* istanbul ignore if */
  2139. if (
  2140. perf &&
  2141. perf.mark &&
  2142. perf.measure &&
  2143. perf.clearMarks &&
  2144. perf.clearMeasures
  2145. ) {
  2146. mark = function (tag) { return perf.mark(tag); };
  2147. measure = function (name, startTag, endTag) {
  2148. perf.measure(name, startTag, endTag);
  2149. perf.clearMarks(startTag);
  2150. perf.clearMarks(endTag);
  2151. perf.clearMeasures(name);
  2152. };
  2153. }
  2154. }
  2155. /* not type checking this file because flow doesn't play well with Proxy */
  2156. var initProxy;
  2157. if (process.env.NODE_ENV !== 'production') {
  2158. var allowedGlobals = makeMap(
  2159. 'Infinity,undefined,NaN,isFinite,isNaN,' +
  2160. 'parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,' +
  2161. 'Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,' +
  2162. 'require' // for Webpack/Browserify
  2163. );
  2164. var warnNonPresent = function (target, key) {
  2165. warn(
  2166. "Property or method \"" + key + "\" is not defined on the instance but " +
  2167. "referenced during render. Make sure to declare reactive data " +
  2168. "properties in the data option.",
  2169. target
  2170. );
  2171. };
  2172. var hasProxy =
  2173. typeof Proxy !== 'undefined' &&
  2174. Proxy.toString().match(/native code/);
  2175. if (hasProxy) {
  2176. var isBuiltInModifier = makeMap('stop,prevent,self,ctrl,shift,alt,meta');
  2177. config.keyCodes = new Proxy(config.keyCodes, {
  2178. set: function set (target, key, value) {
  2179. if (isBuiltInModifier(key)) {
  2180. warn(("Avoid overwriting built-in modifier in config.keyCodes: ." + key));
  2181. return false
  2182. } else {
  2183. target[key] = value;
  2184. return true
  2185. }
  2186. }
  2187. });
  2188. }
  2189. var hasHandler = {
  2190. has: function has (target, key) {
  2191. var has = key in target;
  2192. var isAllowed = allowedGlobals(key) || key.charAt(0) === '_';
  2193. if (!has && !isAllowed) {
  2194. warnNonPresent(target, key);
  2195. }
  2196. return has || !isAllowed
  2197. }
  2198. };
  2199. var getHandler = {
  2200. get: function get (target, key) {
  2201. if (typeof key === 'string' && !(key in target)) {
  2202. warnNonPresent(target, key);
  2203. }
  2204. return target[key]
  2205. }
  2206. };
  2207. initProxy = function initProxy (vm) {
  2208. if (hasProxy) {
  2209. // determine which proxy handler to use
  2210. var options = vm.$options;
  2211. var handlers = options.render && options.render._withStripped
  2212. ? getHandler
  2213. : hasHandler;
  2214. vm._renderProxy = new Proxy(vm, handlers);
  2215. } else {
  2216. vm._renderProxy = vm;
  2217. }
  2218. };
  2219. }
  2220. /* */
  2221. var VNode = function VNode (
  2222. tag,
  2223. data,
  2224. children,
  2225. text,
  2226. elm,
  2227. context,
  2228. componentOptions
  2229. ) {
  2230. this.tag = tag;
  2231. this.data = data;
  2232. this.children = children;
  2233. this.text = text;
  2234. this.elm = elm;
  2235. this.ns = undefined;
  2236. this.context = context;
  2237. this.functionalContext = undefined;
  2238. this.key = data && data.key;
  2239. this.componentOptions = componentOptions;
  2240. this.componentInstance = undefined;
  2241. this.parent = undefined;
  2242. this.raw = false;
  2243. this.isStatic = false;
  2244. this.isRootInsert = true;
  2245. this.isComment = false;
  2246. this.isCloned = false;
  2247. this.isOnce = false;
  2248. };
  2249. var prototypeAccessors = { child: {} };
  2250. // DEPRECATED: alias for componentInstance for backwards compat.
  2251. /* istanbul ignore next */
  2252. prototypeAccessors.child.get = function () {
  2253. return this.componentInstance
  2254. };
  2255. Object.defineProperties( VNode.prototype, prototypeAccessors );
  2256. var createEmptyVNode = function () {
  2257. var node = new VNode();
  2258. node.text = '';
  2259. node.isComment = true;
  2260. return node
  2261. };
  2262. function createTextVNode (val) {
  2263. return new VNode(undefined, undefined, undefined, String(val))
  2264. }
  2265. // optimized shallow clone
  2266. // used for static nodes and slot nodes because they may be reused across
  2267. // multiple renders, cloning them avoids errors when DOM manipulations rely
  2268. // on their elm reference.
  2269. function cloneVNode (vnode) {
  2270. var cloned = new VNode(
  2271. vnode.tag,
  2272. vnode.data,
  2273. vnode.children,
  2274. vnode.text,
  2275. vnode.elm,
  2276. vnode.context,
  2277. vnode.componentOptions
  2278. );
  2279. cloned.ns = vnode.ns;
  2280. cloned.isStatic = vnode.isStatic;
  2281. cloned.key = vnode.key;
  2282. cloned.isComment = vnode.isComment;
  2283. cloned.isCloned = true;
  2284. return cloned
  2285. }
  2286. function cloneVNodes (vnodes) {
  2287. var len = vnodes.length;
  2288. var res = new Array(len);
  2289. for (var i = 0; i < len; i++) {
  2290. res[i] = cloneVNode(vnodes[i]);
  2291. }
  2292. return res
  2293. }
  2294. /* */
  2295. var normalizeEvent = cached(function (name) {
  2296. var passive = name.charAt(0) === '&';
  2297. name = passive ? name.slice(1) : name;
  2298. var once$$1 = name.charAt(0) === '~'; // Prefixed last, checked first
  2299. name = once$$1 ? name.slice(1) : name;
  2300. var capture = name.charAt(0) === '!';
  2301. name = capture ? name.slice(1) : name;
  2302. return {
  2303. name: name,
  2304. once: once$$1,
  2305. capture: capture,
  2306. passive: passive
  2307. }
  2308. });
  2309. function createFnInvoker (fns) {
  2310. function invoker () {
  2311. var arguments$1 = arguments;
  2312. var fns = invoker.fns;
  2313. if (Array.isArray(fns)) {
  2314. for (var i = 0; i < fns.length; i++) {
  2315. fns[i].apply(null, arguments$1);
  2316. }
  2317. } else {
  2318. // return handler return value for single handlers
  2319. return fns.apply(null, arguments)
  2320. }
  2321. }
  2322. invoker.fns = fns;
  2323. return invoker
  2324. }
  2325. function updateListeners (
  2326. on,
  2327. oldOn,
  2328. add,
  2329. remove$$1,
  2330. vm
  2331. ) {
  2332. var name, cur, old, event;
  2333. for (name in on) {
  2334. cur = on[name];
  2335. old = oldOn[name];
  2336. event = normalizeEvent(name);
  2337. if (isUndef(cur)) {
  2338. process.env.NODE_ENV !== 'production' && warn(
  2339. "Invalid handler for event \"" + (event.name) + "\": got " + String(cur),
  2340. vm
  2341. );
  2342. } else if (isUndef(old)) {
  2343. if (isUndef(cur.fns)) {
  2344. cur = on[name] = createFnInvoker(cur);
  2345. }
  2346. add(event.name, cur, event.once, event.capture, event.passive);
  2347. } else if (cur !== old) {
  2348. old.fns = cur;
  2349. on[name] = old;
  2350. }
  2351. }
  2352. for (name in oldOn) {
  2353. if (isUndef(on[name])) {
  2354. event = normalizeEvent(name);
  2355. remove$$1(event.name, oldOn[name], event.capture);
  2356. }
  2357. }
  2358. }
  2359. /* */
  2360. function mergeVNodeHook (def, hookKey, hook) {
  2361. var invoker;
  2362. var oldHook = def[hookKey];
  2363. function wrappedHook () {
  2364. hook.apply(this, arguments);
  2365. // important: remove merged hook to ensure it's called only once
  2366. // and prevent memory leak
  2367. remove(invoker.fns, wrappedHook);
  2368. }
  2369. if (isUndef(oldHook)) {
  2370. // no existing hook
  2371. invoker = createFnInvoker([wrappedHook]);
  2372. } else {
  2373. /* istanbul ignore if */
  2374. if (isDef(oldHook.fns) && isTrue(oldHook.merged)) {
  2375. // already a merged invoker
  2376. invoker = oldHook;
  2377. invoker.fns.push(wrappedHook);
  2378. } else {
  2379. // existing plain hook
  2380. invoker = createFnInvoker([oldHook, wrappedHook]);
  2381. }
  2382. }
  2383. invoker.merged = true;
  2384. def[hookKey] = invoker;
  2385. }
  2386. /* */
  2387. function extractPropsFromVNodeData (
  2388. data,
  2389. Ctor,
  2390. tag
  2391. ) {
  2392. // we are only extracting raw values here.
  2393. // validation and default values are handled in the child
  2394. // component itself.
  2395. var propOptions = Ctor.options.props;
  2396. if (isUndef(propOptions)) {
  2397. return
  2398. }
  2399. var res = {};
  2400. var attrs = data.attrs;
  2401. var props = data.props;
  2402. if (isDef(attrs) || isDef(props)) {
  2403. for (var key in propOptions) {
  2404. var altKey = hyphenate(key);
  2405. if (process.env.NODE_ENV !== 'production') {
  2406. var keyInLowerCase = key.toLowerCase();
  2407. if (
  2408. key !== keyInLowerCase &&
  2409. attrs && hasOwn(attrs, keyInLowerCase)
  2410. ) {
  2411. tip(
  2412. "Prop \"" + keyInLowerCase + "\" is passed to component " +
  2413. (formatComponentName(tag || Ctor)) + ", but the declared prop name is" +
  2414. " \"" + key + "\". " +
  2415. "Note that HTML attributes are case-insensitive and camelCased " +
  2416. "props need to use their kebab-case equivalents when using in-DOM " +
  2417. "templates. You should probably use \"" + altKey + "\" instead of \"" + key + "\"."
  2418. );
  2419. }
  2420. }
  2421. checkProp(res, props, key, altKey, true) ||
  2422. checkProp(res, attrs, key, altKey, false);
  2423. }
  2424. }
  2425. return res
  2426. }
  2427. function checkProp (
  2428. res,
  2429. hash,
  2430. key,
  2431. altKey,
  2432. preserve
  2433. ) {
  2434. if (isDef(hash)) {
  2435. if (hasOwn(hash, key)) {
  2436. res[key] = hash[key];
  2437. if (!preserve) {
  2438. delete hash[key];
  2439. }
  2440. return true
  2441. } else if (hasOwn(hash, altKey)) {
  2442. res[key] = hash[altKey];
  2443. if (!preserve) {
  2444. delete hash[altKey];
  2445. }
  2446. return true
  2447. }
  2448. }
  2449. return false
  2450. }
  2451. /* */
  2452. // The template compiler attempts to minimize the need for normalization by
  2453. // statically analyzing the template at compile time.
  2454. //
  2455. // For plain HTML markup, normalization can be completely skipped because the
  2456. // generated render function is guaranteed to return Array<VNode>. There are
  2457. // two cases where extra normalization is needed:
  2458. // 1. When the children contains components - because a functional component
  2459. // may return an Array instead of a single root. In this case, just a simple
  2460. // normalization is needed - if any child is an Array, we flatten the whole
  2461. // thing with Array.prototype.concat. It is guaranteed to be only 1-level deep
  2462. // because functional components already normalize their own children.
  2463. function simpleNormalizeChildren (children) {
  2464. for (var i = 0; i < children.length; i++) {
  2465. if (Array.isArray(children[i])) {
  2466. return Array.prototype.concat.apply([], children)
  2467. }
  2468. }
  2469. return children
  2470. }
  2471. // 2. When the children contains constructs that always generated nested Arrays,
  2472. // e.g. <template>, <slot>, v-for, or when the children is provided by user
  2473. // with hand-written render functions / JSX. In such cases a full normalization
  2474. // is needed to cater to all possible types of children values.
  2475. function normalizeChildren (children) {
  2476. return isPrimitive(children)
  2477. ? [createTextVNode(children)]
  2478. : Array.isArray(children)
  2479. ? normalizeArrayChildren(children)
  2480. : undefined
  2481. }
  2482. function isTextNode (node) {
  2483. return isDef(node) && isDef(node.text) && isFalse(node.isComment)
  2484. }
  2485. function normalizeArrayChildren (children, nestedIndex) {
  2486. var res = [];
  2487. var i, c, last;
  2488. for (i = 0; i < children.length; i++) {
  2489. c = children[i];
  2490. if (isUndef(c) || typeof c === 'boolean') { continue }
  2491. last = res[res.length - 1];
  2492. // nested
  2493. if (Array.isArray(c)) {
  2494. res.push.apply(res, normalizeArrayChildren(c, ((nestedIndex || '') + "_" + i)));
  2495. } else if (isPrimitive(c)) {
  2496. if (isTextNode(last)) {
  2497. // merge adjacent text nodes
  2498. // this is necessary for SSR hydration because text nodes are
  2499. // essentially merged when rendered to HTML strings
  2500. (last).text += String(c);
  2501. } else if (c !== '') {
  2502. // convert primitive to vnode
  2503. res.push(createTextVNode(c));
  2504. }
  2505. } else {
  2506. if (isTextNode(c) && isTextNode(last)) {
  2507. // merge adjacent text nodes
  2508. res[res.length - 1] = createTextVNode(last.text + c.text);
  2509. } else {
  2510. // default key for nested array children (likely generated by v-for)
  2511. if (isTrue(children._isVList) &&
  2512. isDef(c.tag) &&
  2513. isUndef(c.key) &&
  2514. isDef(nestedIndex)) {
  2515. c.key = "__vlist" + nestedIndex + "_" + i + "__";
  2516. }
  2517. res.push(c);
  2518. }
  2519. }
  2520. }
  2521. return res
  2522. }
  2523. /* */
  2524. function ensureCtor (comp, base) {
  2525. return isObject(comp)
  2526. ? base.extend(comp)
  2527. : comp
  2528. }
  2529. function resolveAsyncComponent (
  2530. factory,
  2531. baseCtor,
  2532. context
  2533. ) {
  2534. if (isTrue(factory.error) && isDef(factory.errorComp)) {
  2535. return factory.errorComp
  2536. }
  2537. if (isDef(factory.resolved)) {
  2538. return factory.resolved
  2539. }
  2540. if (isTrue(factory.loading) && isDef(factory.loadingComp)) {
  2541. return factory.loadingComp
  2542. }
  2543. if (isDef(factory.contexts)) {
  2544. // already pending
  2545. factory.contexts.push(context);
  2546. } else {
  2547. var contexts = factory.contexts = [context];
  2548. var sync = true;
  2549. var forceRender = function () {
  2550. for (var i = 0, l = contexts.length; i < l; i++) {
  2551. contexts[i].$forceUpdate();
  2552. }
  2553. };
  2554. var resolve = once(function (res) {
  2555. // cache resolved
  2556. factory.resolved = ensureCtor(res, baseCtor);
  2557. // invoke callbacks only if this is not a synchronous resolve
  2558. // (async resolves are shimmed as synchronous during SSR)
  2559. if (!sync) {
  2560. forceRender();
  2561. }
  2562. });
  2563. var reject = once(function (reason) {
  2564. process.env.NODE_ENV !== 'production' && warn(
  2565. "Failed to resolve async component: " + (String(factory)) +
  2566. (reason ? ("\nReason: " + reason) : '')
  2567. );
  2568. if (isDef(factory.errorComp)) {
  2569. factory.error = true;
  2570. forceRender();
  2571. }
  2572. });
  2573. var res = factory(resolve, reject);
  2574. if (isObject(res)) {
  2575. if (typeof res.then === 'function') {
  2576. // () => Promise
  2577. if (isUndef(factory.resolved)) {
  2578. res.then(resolve, reject);
  2579. }
  2580. } else if (isDef(res.component) && typeof res.component.then === 'function') {
  2581. res.component.then(resolve, reject);
  2582. if (isDef(res.error)) {
  2583. factory.errorComp = ensureCtor(res.error, baseCtor);
  2584. }
  2585. if (isDef(res.loading)) {
  2586. factory.loadingComp = ensureCtor(res.loading, baseCtor);
  2587. if (res.delay === 0) {
  2588. factory.loading = true;
  2589. } else {
  2590. setTimeout(function () {
  2591. if (isUndef(factory.resolved) && isUndef(factory.error)) {
  2592. factory.loading = true;
  2593. forceRender();
  2594. }
  2595. }, res.delay || 200);
  2596. }
  2597. }
  2598. if (isDef(res.timeout)) {
  2599. setTimeout(function () {
  2600. if (isUndef(factory.resolved)) {
  2601. reject(
  2602. process.env.NODE_ENV !== 'production'
  2603. ? ("timeout (" + (res.timeout) + "ms)")
  2604. : null
  2605. );
  2606. }
  2607. }, res.timeout);
  2608. }
  2609. }
  2610. }
  2611. sync = false;
  2612. // return in case resolved synchronously
  2613. return factory.loading
  2614. ? factory.loadingComp
  2615. : factory.resolved
  2616. }
  2617. }
  2618. /* */
  2619. function getFirstComponentChild (children) {
  2620. if (Array.isArray(children)) {
  2621. for (var i = 0; i < children.length; i++) {
  2622. var c = children[i];
  2623. if (isDef(c) && isDef(c.componentOptions)) {
  2624. return c
  2625. }
  2626. }
  2627. }
  2628. }
  2629. /* */
  2630. /* */
  2631. function initEvents (vm) {
  2632. vm._events = Object.create(null);
  2633. vm._hasHookEvent = false;
  2634. // init parent attached events
  2635. var listeners = vm.$options._parentListeners;
  2636. if (listeners) {
  2637. updateComponentListeners(vm, listeners);
  2638. }
  2639. }
  2640. var target;
  2641. function add (event, fn, once$$1) {
  2642. if (once$$1) {
  2643. target.$once(event, fn);
  2644. } else {
  2645. target.$on(event, fn);
  2646. }
  2647. }
  2648. function remove$1 (event, fn) {
  2649. target.$off(event, fn);
  2650. }
  2651. function updateComponentListeners (
  2652. vm,
  2653. listeners,
  2654. oldListeners
  2655. ) {
  2656. target = vm;
  2657. updateListeners(listeners, oldListeners || {}, add, remove$1, vm);
  2658. }
  2659. function eventsMixin (Vue) {
  2660. var hookRE = /^hook:/;
  2661. Vue.prototype.$on = function (event, fn) {
  2662. var this$1 = this;
  2663. var vm = this;
  2664. if (Array.isArray(event)) {
  2665. for (var i = 0, l = event.length; i < l; i++) {
  2666. this$1.$on(event[i], fn);
  2667. }
  2668. } else {
  2669. (vm._events[event] || (vm._events[event] = [])).push(fn);
  2670. // optimize hook:event cost by using a boolean flag marked at registration
  2671. // instead of a hash lookup
  2672. if (hookRE.test(event)) {
  2673. vm._hasHookEvent = true;
  2674. }
  2675. }
  2676. return vm
  2677. };
  2678. Vue.prototype.$once = function (event, fn) {
  2679. var vm = this;
  2680. function on () {
  2681. vm.$off(event, on);
  2682. fn.apply(vm, arguments);
  2683. }
  2684. on.fn = fn;
  2685. vm.$on(event, on);
  2686. return vm
  2687. };
  2688. Vue.prototype.$off = function (event, fn) {
  2689. var this$1 = this;
  2690. var vm = this;
  2691. // all
  2692. if (!arguments.length) {
  2693. vm._events = Object.create(null);
  2694. return vm
  2695. }
  2696. // array of events
  2697. if (Array.isArray(event)) {
  2698. for (var i$1 = 0, l = event.length; i$1 < l; i$1++) {
  2699. this$1.$off(event[i$1], fn);
  2700. }
  2701. return vm
  2702. }
  2703. // specific event
  2704. var cbs = vm._events[event];
  2705. if (!cbs) {
  2706. return vm
  2707. }
  2708. if (arguments.length === 1) {
  2709. vm._events[event] = null;
  2710. return vm
  2711. }
  2712. // specific handler
  2713. var cb;
  2714. var i = cbs.length;
  2715. while (i--) {
  2716. cb = cbs[i];
  2717. if (cb === fn || cb.fn === fn) {
  2718. cbs.splice(i, 1);
  2719. break
  2720. }
  2721. }
  2722. return vm
  2723. };
  2724. Vue.prototype.$emit = function (event) {
  2725. var vm = this;
  2726. if (process.env.NODE_ENV !== 'production') {
  2727. var lowerCaseEvent = event.toLowerCase();
  2728. if (lowerCaseEvent !== event && vm._events[lowerCaseEvent]) {
  2729. tip(
  2730. "Event \"" + lowerCaseEvent + "\" is emitted in component " +
  2731. (formatComponentName(vm)) + " but the handler is registered for \"" + event + "\". " +
  2732. "Note that HTML attributes are case-insensitive and you cannot use " +
  2733. "v-on to listen to camelCase events when using in-DOM templates. " +
  2734. "You should probably use \"" + (hyphenate(event)) + "\" instead of \"" + event + "\"."
  2735. );
  2736. }
  2737. }
  2738. var cbs = vm._events[event];
  2739. if (cbs) {
  2740. cbs = cbs.length > 1 ? toArray(cbs) : cbs;
  2741. var args = toArray(arguments, 1);
  2742. for (var i = 0, l = cbs.length; i < l; i++) {
  2743. cbs[i].apply(vm, args);
  2744. }
  2745. }
  2746. return vm
  2747. };
  2748. }
  2749. /* */
  2750. /**
  2751. * Runtime helper for resolving raw children VNodes into a slot object.
  2752. */
  2753. function resolveSlots (
  2754. children,
  2755. context
  2756. ) {
  2757. var slots = {};
  2758. if (!children) {
  2759. return slots
  2760. }
  2761. var defaultSlot = [];
  2762. for (var i = 0, l = children.length; i < l; i++) {
  2763. var child = children[i];
  2764. // named slots should only be respected if the vnode was rendered in the
  2765. // same context.
  2766. if ((child.context === context || child.functionalContext === context) &&
  2767. child.data && child.data.slot != null
  2768. ) {
  2769. var name = child.data.slot;
  2770. var slot = (slots[name] || (slots[name] = []));
  2771. if (child.tag === 'template') {
  2772. slot.push.apply(slot, child.children);
  2773. } else {
  2774. slot.push(child);
  2775. }
  2776. } else {
  2777. defaultSlot.push(child);
  2778. }
  2779. }
  2780. // ignore whitespace
  2781. if (!defaultSlot.every(isWhitespace)) {
  2782. slots.default = defaultSlot;
  2783. }
  2784. return slots
  2785. }
  2786. function isWhitespace (node) {
  2787. return node.isComment || node.text === ' '
  2788. }
  2789. function resolveScopedSlots (
  2790. fns, // see flow/vnode
  2791. res
  2792. ) {
  2793. res = res || {};
  2794. for (var i = 0; i < fns.length; i++) {
  2795. if (Array.isArray(fns[i])) {
  2796. resolveScopedSlots(fns[i], res);
  2797. } else {
  2798. res[fns[i].key] = fns[i].fn;
  2799. }
  2800. }
  2801. return res
  2802. }
  2803. /* */
  2804. var activeInstance = null;
  2805. function initLifecycle (vm) {
  2806. var options = vm.$options;
  2807. // locate first non-abstract parent
  2808. var parent = options.parent;
  2809. if (parent && !options.abstract) {
  2810. while (parent.$options.abstract && parent.$parent) {
  2811. parent = parent.$parent;
  2812. }
  2813. parent.$children.push(vm);
  2814. }
  2815. vm.$parent = parent;
  2816. vm.$root = parent ? parent.$root : vm;
  2817. vm.$children = [];
  2818. vm.$refs = {};
  2819. vm._watcher = null;
  2820. vm._inactive = null;
  2821. vm._directInactive = false;
  2822. vm._isMounted = false;
  2823. vm._isDestroyed = false;
  2824. vm._isBeingDestroyed = false;
  2825. }
  2826. function lifecycleMixin (Vue) {
  2827. Vue.prototype._update = function (vnode, hydrating) {
  2828. var vm = this;
  2829. if (vm._isMounted) {
  2830. callHook(vm, 'beforeUpdate');
  2831. }
  2832. var prevEl = vm.$el;
  2833. var prevVnode = vm._vnode;
  2834. var prevActiveInstance = activeInstance;
  2835. activeInstance = vm;
  2836. vm._vnode = vnode;
  2837. // Vue.prototype.__patch__ is injected in entry points
  2838. // based on the rendering backend used.
  2839. if (!prevVnode) {
  2840. // initial render
  2841. vm.$el = vm.__patch__(
  2842. vm.$el, vnode, hydrating, false /* removeOnly */,
  2843. vm.$options._parentElm,
  2844. vm.$options._refElm
  2845. );
  2846. } else {
  2847. // updates
  2848. vm.$el = vm.__patch__(prevVnode, vnode);
  2849. }
  2850. activeInstance = prevActiveInstance;
  2851. // update __vue__ reference
  2852. if (prevEl) {
  2853. prevEl.__vue__ = null;
  2854. }
  2855. if (vm.$el) {
  2856. vm.$el.__vue__ = vm;
  2857. }
  2858. // if parent is an HOC, update its $el as well
  2859. if (vm.$vnode && vm.$parent && vm.$vnode === vm.$parent._vnode) {
  2860. vm.$parent.$el = vm.$el;
  2861. }
  2862. // updated hook is called by the scheduler to ensure that children are
  2863. // updated in a parent's updated hook.
  2864. };
  2865. Vue.prototype.$forceUpdate = function () {
  2866. var vm = this;
  2867. if (vm._watcher) {
  2868. vm._watcher.update();
  2869. }
  2870. };
  2871. Vue.prototype.$destroy = function () {
  2872. var vm = this;
  2873. if (vm._isBeingDestroyed) {
  2874. return
  2875. }
  2876. callHook(vm, 'beforeDestroy');
  2877. vm._isBeingDestroyed = true;
  2878. // remove self from parent
  2879. var parent = vm.$parent;
  2880. if (parent && !parent._isBeingDestroyed && !vm.$options.abstract) {
  2881. remove(parent.$children, vm);
  2882. }
  2883. // teardown watchers
  2884. if (vm._watcher) {
  2885. vm._watcher.teardown();
  2886. }
  2887. var i = vm._watchers.length;
  2888. while (i--) {
  2889. vm._watchers[i].teardown();
  2890. }
  2891. // remove reference from data ob
  2892. // frozen object may not have observer.
  2893. if (vm._data.__ob__) {
  2894. vm._data.__ob__.vmCount--;
  2895. }
  2896. // call the last hook...
  2897. vm._isDestroyed = true;
  2898. // invoke destroy hooks on current rendered tree
  2899. vm.__patch__(vm._vnode, null);
  2900. // fire destroyed hook
  2901. callHook(vm, 'destroyed');
  2902. // turn off all instance listeners.
  2903. vm.$off();
  2904. // remove __vue__ reference
  2905. if (vm.$el) {
  2906. vm.$el.__vue__ = null;
  2907. }
  2908. // remove reference to DOM nodes (prevents leak)
  2909. vm.$options._parentElm = vm.$options._refElm = null;
  2910. };
  2911. }
  2912. function mountComponent (
  2913. vm,
  2914. el,
  2915. hydrating
  2916. ) {
  2917. vm.$el = el;
  2918. if (!vm.$options.render) {
  2919. vm.$options.render = createEmptyVNode;
  2920. if (process.env.NODE_ENV !== 'production') {
  2921. /* istanbul ignore if */
  2922. if ((vm.$options.template && vm.$options.template.charAt(0) !== '#') ||
  2923. vm.$options.el || el) {
  2924. warn(
  2925. 'You are using the runtime-only build of Vue where the template ' +
  2926. 'compiler is not available. Either pre-compile the templates into ' +
  2927. 'render functions, or use the compiler-included build.',
  2928. vm
  2929. );
  2930. } else {
  2931. warn(
  2932. 'Failed to mount component: template or render function not defined.',
  2933. vm
  2934. );
  2935. }
  2936. }
  2937. }
  2938. callHook(vm, 'beforeMount');
  2939. var updateComponent;
  2940. /* istanbul ignore if */
  2941. if (process.env.NODE_ENV !== 'production' && config.performance && mark) {
  2942. updateComponent = function () {
  2943. var name = vm._name;
  2944. var id = vm._uid;
  2945. var startTag = "vue-perf-start:" + id;
  2946. var endTag = "vue-perf-end:" + id;
  2947. mark(startTag);
  2948. var vnode = vm._render();
  2949. mark(endTag);
  2950. measure((name + " render"), startTag, endTag);
  2951. mark(startTag);
  2952. vm._update(vnode, hydrating);
  2953. mark(endTag);
  2954. measure((name + " patch"), startTag, endTag);
  2955. };
  2956. } else {
  2957. updateComponent = function () {
  2958. vm._update(vm._render(), hydrating);
  2959. };
  2960. }
  2961. vm._watcher = new Watcher(vm, updateComponent, noop);
  2962. hydrating = false;
  2963. // manually mounted instance, call mounted on self
  2964. // mounted is called for render-created child components in its inserted hook
  2965. if (vm.$vnode == null) {
  2966. vm._isMounted = true;
  2967. callHook(vm, 'mounted');
  2968. }
  2969. return vm
  2970. }
  2971. function updateChildComponent (
  2972. vm,
  2973. propsData,
  2974. listeners,
  2975. parentVnode,
  2976. renderChildren
  2977. ) {
  2978. // determine whether component has slot children
  2979. // we need to do this before overwriting $options._renderChildren
  2980. var hasChildren = !!(
  2981. renderChildren || // has new static slots
  2982. vm.$options._renderChildren || // has old static slots
  2983. parentVnode.data.scopedSlots || // has new scoped slots
  2984. vm.$scopedSlots !== emptyObject // has old scoped slots
  2985. );
  2986. vm.$options._parentVnode = parentVnode;
  2987. vm.$vnode = parentVnode; // update vm's placeholder node without re-render
  2988. if (vm._vnode) { // update child tree's parent
  2989. vm._vnode.parent = parentVnode;
  2990. }
  2991. vm.$options._renderChildren = renderChildren;
  2992. // update props
  2993. if (propsData && vm.$options.props) {
  2994. observerState.shouldConvert = false;
  2995. if (process.env.NODE_ENV !== 'production') {
  2996. observerState.isSettingProps = true;
  2997. }
  2998. var props = vm._props;
  2999. var propKeys = vm.$options._propKeys || [];
  3000. for (var i = 0; i < propKeys.length; i++) {
  3001. var key = propKeys[i];
  3002. props[key] = validateProp(key, vm.$options.props, propsData, vm);
  3003. }
  3004. observerState.shouldConvert = true;
  3005. if (process.env.NODE_ENV !== 'production') {
  3006. observerState.isSettingProps = false;
  3007. }
  3008. // keep a copy of raw propsData
  3009. vm.$options.propsData = propsData;
  3010. }
  3011. // update listeners
  3012. if (listeners) {
  3013. var oldListeners = vm.$options._parentListeners;
  3014. vm.$options._parentListeners = listeners;
  3015. updateComponentListeners(vm, listeners, oldListeners);
  3016. }
  3017. // resolve slots + force update if has children
  3018. if (hasChildren) {
  3019. vm.$slots = resolveSlots(renderChildren, parentVnode.context);
  3020. vm.$forceUpdate();
  3021. }
  3022. }
  3023. function isInInactiveTree (vm) {
  3024. while (vm && (vm = vm.$parent)) {
  3025. if (vm._inactive) { return true }
  3026. }
  3027. return false
  3028. }
  3029. function activateChildComponent (vm, direct) {
  3030. if (direct) {
  3031. vm._directInactive = false;
  3032. if (isInInactiveTree(vm)) {
  3033. return
  3034. }
  3035. } else if (vm._directInactive) {
  3036. return
  3037. }
  3038. if (vm._inactive || vm._inactive === null) {
  3039. vm._inactive = false;
  3040. for (var i = 0; i < vm.$children.length; i++) {
  3041. activateChildComponent(vm.$children[i]);
  3042. }
  3043. callHook(vm, 'activated');
  3044. }
  3045. }
  3046. function deactivateChildComponent (vm, direct) {
  3047. if (direct) {
  3048. vm._directInactive = true;
  3049. if (isInInactiveTree(vm)) {
  3050. return
  3051. }
  3052. }
  3053. if (!vm._inactive) {
  3054. vm._inactive = true;
  3055. for (var i = 0; i < vm.$children.length; i++) {
  3056. deactivateChildComponent(vm.$children[i]);
  3057. }
  3058. callHook(vm, 'deactivated');
  3059. }
  3060. }
  3061. function callHook (vm, hook) {
  3062. var handlers = vm.$options[hook];
  3063. if (handlers) {
  3064. for (var i = 0, j = handlers.length; i < j; i++) {
  3065. try {
  3066. handlers[i].call(vm);
  3067. } catch (e) {
  3068. handleError(e, vm, (hook + " hook"));
  3069. }
  3070. }
  3071. }
  3072. if (vm._hasHookEvent) {
  3073. vm.$emit('hook:' + hook);
  3074. }
  3075. }
  3076. /* */
  3077. var MAX_UPDATE_COUNT = 100;
  3078. var queue = [];
  3079. var activatedChildren = [];
  3080. var has = {};
  3081. var circular = {};
  3082. var waiting = false;
  3083. var flushing = false;
  3084. var index = 0;
  3085. /**
  3086. * Reset the scheduler's state.
  3087. */
  3088. function resetSchedulerState () {
  3089. index = queue.length = activatedChildren.length = 0;
  3090. has = {};
  3091. if (process.env.NODE_ENV !== 'production') {
  3092. circular = {};
  3093. }
  3094. waiting = flushing = false;
  3095. }
  3096. /**
  3097. * Flush both queues and run the watchers.
  3098. */
  3099. function flushSchedulerQueue () {
  3100. flushing = true;
  3101. var watcher, id;
  3102. // Sort queue before flush.
  3103. // This ensures that:
  3104. // 1. Components are updated from parent to child. (because parent is always
  3105. // created before the child)
  3106. // 2. A component's user watchers are run before its render watcher (because
  3107. // user watchers are created before the render watcher)
  3108. // 3. If a component is destroyed during a parent component's watcher run,
  3109. // its watchers can be skipped.
  3110. queue.sort(function (a, b) { return a.id - b.id; });
  3111. // do not cache length because more watchers might be pushed
  3112. // as we run existing watchers
  3113. for (index = 0; index < queue.length; index++) {
  3114. watcher = queue[index];
  3115. id = watcher.id;
  3116. has[id] = null;
  3117. watcher.run();
  3118. // in dev build, check and stop circular updates.
  3119. if (process.env.NODE_ENV !== 'production' && has[id] != null) {
  3120. circular[id] = (circular[id] || 0) + 1;
  3121. if (circular[id] > MAX_UPDATE_COUNT) {
  3122. warn(
  3123. 'You may have an infinite update loop ' + (
  3124. watcher.user
  3125. ? ("in watcher with expression \"" + (watcher.expression) + "\"")
  3126. : "in a component render function."
  3127. ),
  3128. watcher.vm
  3129. );
  3130. break
  3131. }
  3132. }
  3133. }
  3134. // keep copies of post queues before resetting state
  3135. var activatedQueue = activatedChildren.slice();
  3136. var updatedQueue = queue.slice();
  3137. resetSchedulerState();
  3138. // call component updated and activated hooks
  3139. callActivatedHooks(activatedQueue);
  3140. callUpdateHooks(updatedQueue);
  3141. // devtool hook
  3142. /* istanbul ignore if */
  3143. if (devtools && config.devtools) {
  3144. devtools.emit('flush');
  3145. }
  3146. }
  3147. function callUpdateHooks (queue) {
  3148. var i = queue.length;
  3149. while (i--) {
  3150. var watcher = queue[i];
  3151. var vm = watcher.vm;
  3152. if (vm._watcher === watcher && vm._isMounted) {
  3153. callHook(vm, 'updated');
  3154. }
  3155. }
  3156. }
  3157. /**
  3158. * Queue a kept-alive component that was activated during patch.
  3159. * The queue will be processed after the entire tree has been patched.
  3160. */
  3161. function queueActivatedComponent (vm) {
  3162. // setting _inactive to false here so that a render function can
  3163. // rely on checking whether it's in an inactive tree (e.g. router-view)
  3164. vm._inactive = false;
  3165. activatedChildren.push(vm);
  3166. }
  3167. function callActivatedHooks (queue) {
  3168. for (var i = 0; i < queue.length; i++) {
  3169. queue[i]._inactive = true;
  3170. activateChildComponent(queue[i], true /* true */);
  3171. }
  3172. }
  3173. /**
  3174. * Push a watcher into the watcher queue.
  3175. * Jobs with duplicate IDs will be skipped unless it's
  3176. * pushed when the queue is being flushed.
  3177. */
  3178. function queueWatcher (watcher) {
  3179. var id = watcher.id;
  3180. if (has[id] == null) {
  3181. has[id] = true;
  3182. if (!flushing) {
  3183. queue.push(watcher);
  3184. } else {
  3185. // if already flushing, splice the watcher based on its id
  3186. // if already past its id, it will be run next immediately.
  3187. var i = queue.length - 1;
  3188. while (i > index && queue[i].id > watcher.id) {
  3189. i--;
  3190. }
  3191. queue.splice(i + 1, 0, watcher);
  3192. }
  3193. // queue the flush
  3194. if (!waiting) {
  3195. waiting = true;
  3196. nextTick(flushSchedulerQueue);
  3197. }
  3198. }
  3199. }
  3200. /* */
  3201. var uid$2 = 0;
  3202. /**
  3203. * A watcher parses an expression, collects dependencies,
  3204. * and fires callback when the expression value changes.
  3205. * This is used for both the $watch() api and directives.
  3206. */
  3207. var Watcher = function Watcher (
  3208. vm,
  3209. expOrFn,
  3210. cb,
  3211. options
  3212. ) {
  3213. this.vm = vm;
  3214. vm._watchers.push(this);
  3215. // options
  3216. if (options) {
  3217. this.deep = !!options.deep;
  3218. this.user = !!options.user;
  3219. this.lazy = !!options.lazy;
  3220. this.sync = !!options.sync;
  3221. } else {
  3222. this.deep = this.user = this.lazy = this.sync = false;
  3223. }
  3224. this.cb = cb;
  3225. this.id = ++uid$2; // uid for batching
  3226. this.active = true;
  3227. this.dirty = this.lazy; // for lazy watchers
  3228. this.deps = [];
  3229. this.newDeps = [];
  3230. this.depIds = new _Set();
  3231. this.newDepIds = new _Set();
  3232. this.expression = process.env.NODE_ENV !== 'production'
  3233. ? expOrFn.toString()
  3234. : '';
  3235. // parse expression for getter
  3236. if (typeof expOrFn === 'function') {
  3237. this.getter = expOrFn;
  3238. } else {
  3239. this.getter = parsePath(expOrFn);
  3240. if (!this.getter) {
  3241. this.getter = function () {};
  3242. process.env.NODE_ENV !== 'production' && warn(
  3243. "Failed watching path: \"" + expOrFn + "\" " +
  3244. 'Watcher only accepts simple dot-delimited paths. ' +
  3245. 'For full control, use a function instead.',
  3246. vm
  3247. );
  3248. }
  3249. }
  3250. this.value = this.lazy
  3251. ? undefined
  3252. : this.get();
  3253. };
  3254. /**
  3255. * Evaluate the getter, and re-collect dependencies.
  3256. */
  3257. Watcher.prototype.get = function get () {
  3258. pushTarget(this);
  3259. var value;
  3260. var vm = this.vm;
  3261. if (this.user) {
  3262. try {
  3263. value = this.getter.call(vm, vm);
  3264. } catch (e) {
  3265. handleError(e, vm, ("getter for watcher \"" + (this.expression) + "\""));
  3266. }
  3267. } else {
  3268. value = this.getter.call(vm, vm);
  3269. }
  3270. // "touch" every property so they are all tracked as
  3271. // dependencies for deep watching
  3272. if (this.deep) {
  3273. traverse(value);
  3274. }
  3275. popTarget();
  3276. this.cleanupDeps();
  3277. return value
  3278. };
  3279. /**
  3280. * Add a dependency to this directive.
  3281. */
  3282. Watcher.prototype.addDep = function addDep (dep) {
  3283. var id = dep.id;
  3284. if (!this.newDepIds.has(id)) {
  3285. this.newDepIds.add(id);
  3286. this.newDeps.push(dep);
  3287. if (!this.depIds.has(id)) {
  3288. dep.addSub(this);
  3289. }
  3290. }
  3291. };
  3292. /**
  3293. * Clean up for dependency collection.
  3294. */
  3295. Watcher.prototype.cleanupDeps = function cleanupDeps () {
  3296. var this$1 = this;
  3297. var i = this.deps.length;
  3298. while (i--) {
  3299. var dep = this$1.deps[i];
  3300. if (!this$1.newDepIds.has(dep.id)) {
  3301. dep.removeSub(this$1);
  3302. }
  3303. }
  3304. var tmp = this.depIds;
  3305. this.depIds = this.newDepIds;
  3306. this.newDepIds = tmp;
  3307. this.newDepIds.clear();
  3308. tmp = this.deps;
  3309. this.deps = this.newDeps;
  3310. this.newDeps = tmp;
  3311. this.newDeps.length = 0;
  3312. };
  3313. /**
  3314. * Subscriber interface.
  3315. * Will be called when a dependency changes.
  3316. */
  3317. Watcher.prototype.update = function update () {
  3318. /* istanbul ignore else */
  3319. if (this.lazy) {
  3320. this.dirty = true;
  3321. } else if (this.sync) {
  3322. this.run();
  3323. } else {
  3324. queueWatcher(this);
  3325. }
  3326. };
  3327. /**
  3328. * Scheduler job interface.
  3329. * Will be called by the scheduler.
  3330. */
  3331. Watcher.prototype.run = function run () {
  3332. if (this.active) {
  3333. var value = this.get();
  3334. if (
  3335. value !== this.value ||
  3336. // Deep watchers and watchers on Object/Arrays should fire even
  3337. // when the value is the same, because the value may
  3338. // have mutated.
  3339. isObject(value) ||
  3340. this.deep
  3341. ) {
  3342. // set new value
  3343. var oldValue = this.value;
  3344. this.value = value;
  3345. if (this.user) {
  3346. try {
  3347. this.cb.call(this.vm, value, oldValue);
  3348. } catch (e) {
  3349. handleError(e, this.vm, ("callback for watcher \"" + (this.expression) + "\""));
  3350. }
  3351. } else {
  3352. this.cb.call(this.vm, value, oldValue);
  3353. }
  3354. }
  3355. }
  3356. };
  3357. /**
  3358. * Evaluate the value of the watcher.
  3359. * This only gets called for lazy watchers.
  3360. */
  3361. Watcher.prototype.evaluate = function evaluate () {
  3362. this.value = this.get();
  3363. this.dirty = false;
  3364. };
  3365. /**
  3366. * Depend on all deps collected by this watcher.
  3367. */
  3368. Watcher.prototype.depend = function depend () {
  3369. var this$1 = this;
  3370. var i = this.deps.length;
  3371. while (i--) {
  3372. this$1.deps[i].depend();
  3373. }
  3374. };
  3375. /**
  3376. * Remove self from all dependencies' subscriber list.
  3377. */
  3378. Watcher.prototype.teardown = function teardown () {
  3379. var this$1 = this;
  3380. if (this.active) {
  3381. // remove self from vm's watcher list
  3382. // this is a somewhat expensive operation so we skip it
  3383. // if the vm is being destroyed.
  3384. if (!this.vm._isBeingDestroyed) {
  3385. remove(this.vm._watchers, this);
  3386. }
  3387. var i = this.deps.length;
  3388. while (i--) {
  3389. this$1.deps[i].removeSub(this$1);
  3390. }
  3391. this.active = false;
  3392. }
  3393. };
  3394. /**
  3395. * Recursively traverse an object to evoke all converted
  3396. * getters, so that every nested property inside the object
  3397. * is collected as a "deep" dependency.
  3398. */
  3399. var seenObjects = new _Set();
  3400. function traverse (val) {
  3401. seenObjects.clear();
  3402. _traverse(val, seenObjects);
  3403. }
  3404. function _traverse (val, seen) {
  3405. var i, keys;
  3406. var isA = Array.isArray(val);
  3407. if ((!isA && !isObject(val)) || !Object.isExtensible(val)) {
  3408. return
  3409. }
  3410. if (val.__ob__) {
  3411. var depId = val.__ob__.dep.id;
  3412. if (seen.has(depId)) {
  3413. return
  3414. }
  3415. seen.add(depId);
  3416. }
  3417. if (isA) {
  3418. i = val.length;
  3419. while (i--) { _traverse(val[i], seen); }
  3420. } else {
  3421. keys = Object.keys(val);
  3422. i = keys.length;
  3423. while (i--) { _traverse(val[keys[i]], seen); }
  3424. }
  3425. }
  3426. /* */
  3427. var sharedPropertyDefinition = {
  3428. enumerable: true,
  3429. configurable: true,
  3430. get: noop,
  3431. set: noop
  3432. };
  3433. function proxy (target, sourceKey, key) {
  3434. sharedPropertyDefinition.get = function proxyGetter () {
  3435. return this[sourceKey][key]
  3436. };
  3437. sharedPropertyDefinition.set = function proxySetter (val) {
  3438. this[sourceKey][key] = val;
  3439. };
  3440. Object.defineProperty(target, key, sharedPropertyDefinition);
  3441. }
  3442. function initState (vm) {
  3443. vm._watchers = [];
  3444. var opts = vm.$options;
  3445. if (opts.props) { initProps(vm, opts.props); }
  3446. if (opts.methods) { initMethods(vm, opts.methods); }
  3447. if (opts.data) {
  3448. initData(vm);
  3449. } else {
  3450. observe(vm._data = {}, true /* asRootData */);
  3451. }
  3452. if (opts.computed) { initComputed(vm, opts.computed); }
  3453. if (opts.watch) { initWatch(vm, opts.watch); }
  3454. }
  3455. var isReservedProp = {
  3456. key: 1,
  3457. ref: 1,
  3458. slot: 1
  3459. };
  3460. function initProps (vm, propsOptions) {
  3461. var propsData = vm.$options.propsData || {};
  3462. var props = vm._props = {};
  3463. // cache prop keys so that future props updates can iterate using Array
  3464. // instead of dynamic object key enumeration.
  3465. var keys = vm.$options._propKeys = [];
  3466. var isRoot = !vm.$parent;
  3467. // root instance props should be converted
  3468. observerState.shouldConvert = isRoot;
  3469. var loop = function ( key ) {
  3470. keys.push(key);
  3471. var value = validateProp(key, propsOptions, propsData, vm);
  3472. /* istanbul ignore else */
  3473. if (process.env.NODE_ENV !== 'production') {
  3474. if (isReservedProp[key] || config.isReservedAttr(key)) {
  3475. warn(
  3476. ("\"" + key + "\" is a reserved attribute and cannot be used as component prop."),
  3477. vm
  3478. );
  3479. }
  3480. defineReactive$$1(props, key, value, function () {
  3481. if (vm.$parent && !observerState.isSettingProps) {
  3482. warn(
  3483. "Avoid mutating a prop directly since the value will be " +
  3484. "overwritten whenever the parent component re-renders. " +
  3485. "Instead, use a data or computed property based on the prop's " +
  3486. "value. Prop being mutated: \"" + key + "\"",
  3487. vm
  3488. );
  3489. }
  3490. });
  3491. } else {
  3492. defineReactive$$1(props, key, value);
  3493. }
  3494. // static props are already proxied on the component's prototype
  3495. // during Vue.extend(). We only need to proxy props defined at
  3496. // instantiation here.
  3497. if (!(key in vm)) {
  3498. proxy(vm, "_props", key);
  3499. }
  3500. };
  3501. for (var key in propsOptions) loop( key );
  3502. observerState.shouldConvert = true;
  3503. }
  3504. function initData (vm) {
  3505. var data = vm.$options.data;
  3506. data = vm._data = typeof data === 'function'
  3507. ? getData(data, vm)
  3508. : data || {};
  3509. if (!isPlainObject(data)) {
  3510. data = {};
  3511. process.env.NODE_ENV !== 'production' && warn(
  3512. 'data functions should return an object:\n' +
  3513. 'https://vuejs.org/v2/guide/components.html#data-Must-Be-a-Function',
  3514. vm
  3515. );
  3516. }
  3517. // proxy data on instance
  3518. var keys = Object.keys(data);
  3519. var props = vm.$options.props;
  3520. var i = keys.length;
  3521. while (i--) {
  3522. if (props && hasOwn(props, keys[i])) {
  3523. process.env.NODE_ENV !== 'production' && warn(
  3524. "The data property \"" + (keys[i]) + "\" is already declared as a prop. " +
  3525. "Use prop default value instead.",
  3526. vm
  3527. );
  3528. } else if (!isReserved(keys[i])) {
  3529. proxy(vm, "_data", keys[i]);
  3530. }
  3531. }
  3532. // observe data
  3533. observe(data, true /* asRootData */);
  3534. }
  3535. function getData (data, vm) {
  3536. try {
  3537. return data.call(vm)
  3538. } catch (e) {
  3539. handleError(e, vm, "data()");
  3540. return {}
  3541. }
  3542. }
  3543. var computedWatcherOptions = { lazy: true };
  3544. function initComputed (vm, computed) {
  3545. var watchers = vm._computedWatchers = Object.create(null);
  3546. for (var key in computed) {
  3547. var userDef = computed[key];
  3548. var getter = typeof userDef === 'function' ? userDef : userDef.get;
  3549. if (process.env.NODE_ENV !== 'production') {
  3550. if (getter === undefined) {
  3551. warn(
  3552. ("No getter function has been defined for computed property \"" + key + "\"."),
  3553. vm
  3554. );
  3555. getter = noop;
  3556. }
  3557. }
  3558. // create internal watcher for the computed property.
  3559. watchers[key] = new Watcher(vm, getter, noop, computedWatcherOptions);
  3560. // component-defined computed properties are already defined on the
  3561. // component prototype. We only need to define computed properties defined
  3562. // at instantiation here.
  3563. if (!(key in vm)) {
  3564. defineComputed(vm, key, userDef);
  3565. } else if (process.env.NODE_ENV !== 'production') {
  3566. if (key in vm.$data) {
  3567. warn(("The computed property \"" + key + "\" is already defined in data."), vm);
  3568. } else if (vm.$options.props && key in vm.$options.props) {
  3569. warn(("The computed property \"" + key + "\" is already defined as a prop."), vm);
  3570. }
  3571. }
  3572. }
  3573. }
  3574. function defineComputed (target, key, userDef) {
  3575. if (typeof userDef === 'function') {
  3576. sharedPropertyDefinition.get = createComputedGetter(key);
  3577. sharedPropertyDefinition.set = noop;
  3578. } else {
  3579. sharedPropertyDefinition.get = userDef.get
  3580. ? userDef.cache !== false
  3581. ? createComputedGetter(key)
  3582. : userDef.get
  3583. : noop;
  3584. sharedPropertyDefinition.set = userDef.set
  3585. ? userDef.set
  3586. : noop;
  3587. }
  3588. Object.defineProperty(target, key, sharedPropertyDefinition);
  3589. }
  3590. function createComputedGetter (key) {
  3591. return function computedGetter () {
  3592. var watcher = this._computedWatchers && this._computedWatchers[key];
  3593. if (watcher) {
  3594. if (watcher.dirty) {
  3595. watcher.evaluate();
  3596. }
  3597. if (Dep.target) {
  3598. watcher.depend();
  3599. }
  3600. return watcher.value
  3601. }
  3602. }
  3603. }
  3604. function initMethods (vm, methods) {
  3605. var props = vm.$options.props;
  3606. for (var key in methods) {
  3607. vm[key] = methods[key] == null ? noop : bind(methods[key], vm);
  3608. if (process.env.NODE_ENV !== 'production') {
  3609. if (methods[key] == null) {
  3610. warn(
  3611. "method \"" + key + "\" has an undefined value in the component definition. " +
  3612. "Did you reference the function correctly?",
  3613. vm
  3614. );
  3615. }
  3616. if (props && hasOwn(props, key)) {
  3617. warn(
  3618. ("method \"" + key + "\" has already been defined as a prop."),
  3619. vm
  3620. );
  3621. }
  3622. }
  3623. }
  3624. }
  3625. function initWatch (vm, watch) {
  3626. for (var key in watch) {
  3627. var handler = watch[key];
  3628. if (Array.isArray(handler)) {
  3629. for (var i = 0; i < handler.length; i++) {
  3630. createWatcher(vm, key, handler[i]);
  3631. }
  3632. } else {
  3633. createWatcher(vm, key, handler);
  3634. }
  3635. }
  3636. }
  3637. function createWatcher (vm, key, handler) {
  3638. var options;
  3639. if (isPlainObject(handler)) {
  3640. options = handler;
  3641. handler = handler.handler;
  3642. }
  3643. if (typeof handler === 'string') {
  3644. handler = vm[handler];
  3645. }
  3646. vm.$watch(key, handler, options);
  3647. }
  3648. function stateMixin (Vue) {
  3649. // flow somehow has problems with directly declared definition object
  3650. // when using Object.defineProperty, so we have to procedurally build up
  3651. // the object here.
  3652. var dataDef = {};
  3653. dataDef.get = function () { return this._data };
  3654. var propsDef = {};
  3655. propsDef.get = function () { return this._props };
  3656. if (process.env.NODE_ENV !== 'production') {
  3657. dataDef.set = function (newData) {
  3658. warn(
  3659. 'Avoid replacing instance root $data. ' +
  3660. 'Use nested data properties instead.',
  3661. this
  3662. );
  3663. };
  3664. propsDef.set = function () {
  3665. warn("$props is readonly.", this);
  3666. };
  3667. }
  3668. Object.defineProperty(Vue.prototype, '$data', dataDef);
  3669. Object.defineProperty(Vue.prototype, '$props', propsDef);
  3670. Vue.prototype.$set = set;
  3671. Vue.prototype.$delete = del;
  3672. Vue.prototype.$watch = function (
  3673. expOrFn,
  3674. cb,
  3675. options
  3676. ) {
  3677. var vm = this;
  3678. options = options || {};
  3679. options.user = true;
  3680. var watcher = new Watcher(vm, expOrFn, cb, options);
  3681. if (options.immediate) {
  3682. cb.call(vm, watcher.value);
  3683. }
  3684. return function unwatchFn () {
  3685. watcher.teardown();
  3686. }
  3687. };
  3688. }
  3689. /* */
  3690. function initProvide (vm) {
  3691. var provide = vm.$options.provide;
  3692. if (provide) {
  3693. vm._provided = typeof provide === 'function'
  3694. ? provide.call(vm)
  3695. : provide;
  3696. }
  3697. }
  3698. function initInjections (vm) {
  3699. var result = resolveInject(vm.$options.inject, vm);
  3700. if (result) {
  3701. Object.keys(result).forEach(function (key) {
  3702. /* istanbul ignore else */
  3703. if (process.env.NODE_ENV !== 'production') {
  3704. defineReactive$$1(vm, key, result[key], function () {
  3705. warn(
  3706. "Avoid mutating an injected value directly since the changes will be " +
  3707. "overwritten whenever the provided component re-renders. " +
  3708. "injection being mutated: \"" + key + "\"",
  3709. vm
  3710. );
  3711. });
  3712. } else {
  3713. defineReactive$$1(vm, key, result[key]);
  3714. }
  3715. });
  3716. }
  3717. }
  3718. function resolveInject (inject, vm) {
  3719. if (inject) {
  3720. // inject is :any because flow is not smart enough to figure out cached
  3721. // isArray here
  3722. var isArray = Array.isArray(inject);
  3723. var result = Object.create(null);
  3724. var keys = isArray
  3725. ? inject
  3726. : hasSymbol
  3727. ? Reflect.ownKeys(inject)
  3728. : Object.keys(inject);
  3729. for (var i = 0; i < keys.length; i++) {
  3730. var key = keys[i];
  3731. var provideKey = isArray ? key : inject[key];
  3732. var source = vm;
  3733. while (source) {
  3734. if (source._provided && provideKey in source._provided) {
  3735. result[key] = source._provided[provideKey];
  3736. break
  3737. }
  3738. source = source.$parent;
  3739. }
  3740. }
  3741. return result
  3742. }
  3743. }
  3744. /* */
  3745. function createFunctionalComponent (
  3746. Ctor,
  3747. propsData,
  3748. data,
  3749. context,
  3750. children
  3751. ) {
  3752. var props = {};
  3753. var propOptions = Ctor.options.props;
  3754. if (isDef(propOptions)) {
  3755. for (var key in propOptions) {
  3756. props[key] = validateProp(key, propOptions, propsData || {});
  3757. }
  3758. } else {
  3759. if (isDef(data.attrs)) { mergeProps(props, data.attrs); }
  3760. if (isDef(data.props)) { mergeProps(props, data.props); }
  3761. }
  3762. // ensure the createElement function in functional components
  3763. // gets a unique context - this is necessary for correct named slot check
  3764. var _context = Object.create(context);
  3765. var h = function (a, b, c, d) { return createElement(_context, a, b, c, d, true); };
  3766. var vnode = Ctor.options.render.call(null, h, {
  3767. data: data,
  3768. props: props,
  3769. children: children,
  3770. parent: context,
  3771. listeners: data.on || {},
  3772. injections: resolveInject(Ctor.options.inject, context),
  3773. slots: function () { return resolveSlots(children, context); }
  3774. });
  3775. if (vnode instanceof VNode) {
  3776. vnode.functionalContext = context;
  3777. vnode.functionalOptions = Ctor.options;
  3778. if (data.slot) {
  3779. (vnode.data || (vnode.data = {})).slot = data.slot;
  3780. }
  3781. }
  3782. return vnode
  3783. }
  3784. function mergeProps (to, from) {
  3785. for (var key in from) {
  3786. to[camelize(key)] = from[key];
  3787. }
  3788. }
  3789. /* */
  3790. // hooks to be invoked on component VNodes during patch
  3791. var componentVNodeHooks = {
  3792. init: function init (
  3793. vnode,
  3794. hydrating,
  3795. parentElm,
  3796. refElm
  3797. ) {
  3798. if (!vnode.componentInstance || vnode.componentInstance._isDestroyed) {
  3799. var child = vnode.componentInstance = createComponentInstanceForVnode(
  3800. vnode,
  3801. activeInstance,
  3802. parentElm,
  3803. refElm
  3804. );
  3805. child.$mount(hydrating ? vnode.elm : undefined, hydrating);
  3806. } else if (vnode.data.keepAlive) {
  3807. // kept-alive components, treat as a patch
  3808. var mountedNode = vnode; // work around flow
  3809. componentVNodeHooks.prepatch(mountedNode, mountedNode);
  3810. }
  3811. },
  3812. prepatch: function prepatch (oldVnode, vnode) {
  3813. var options = vnode.componentOptions;
  3814. var child = vnode.componentInstance = oldVnode.componentInstance;
  3815. updateChildComponent(
  3816. child,
  3817. options.propsData, // updated props
  3818. options.listeners, // updated listeners
  3819. vnode, // new parent vnode
  3820. options.children // new children
  3821. );
  3822. },
  3823. insert: function insert (vnode) {
  3824. var context = vnode.context;
  3825. var componentInstance = vnode.componentInstance;
  3826. if (!componentInstance._isMounted) {
  3827. componentInstance._isMounted = true;
  3828. callHook(componentInstance, 'mounted');
  3829. }
  3830. if (vnode.data.keepAlive) {
  3831. if (context._isMounted) {
  3832. // vue-router#1212
  3833. // During updates, a kept-alive component's child components may
  3834. // change, so directly walking the tree here may call activated hooks
  3835. // on incorrect children. Instead we push them into a queue which will
  3836. // be processed after the whole patch process ended.
  3837. queueActivatedComponent(componentInstance);
  3838. } else {
  3839. activateChildComponent(componentInstance, true /* direct */);
  3840. }
  3841. }
  3842. },
  3843. destroy: function destroy (vnode) {
  3844. var componentInstance = vnode.componentInstance;
  3845. if (!componentInstance._isDestroyed) {
  3846. if (!vnode.data.keepAlive) {
  3847. componentInstance.$destroy();
  3848. } else {
  3849. deactivateChildComponent(componentInstance, true /* direct */);
  3850. }
  3851. }
  3852. }
  3853. };
  3854. var hooksToMerge = Object.keys(componentVNodeHooks);
  3855. function createComponent (
  3856. Ctor,
  3857. data,
  3858. context,
  3859. children,
  3860. tag
  3861. ) {
  3862. if (isUndef(Ctor)) {
  3863. return
  3864. }
  3865. var baseCtor = context.$options._base;
  3866. // plain options object: turn it into a constructor
  3867. if (isObject(Ctor)) {
  3868. Ctor = baseCtor.extend(Ctor);
  3869. }
  3870. // if at this stage it's not a constructor or an async component factory,
  3871. // reject.
  3872. if (typeof Ctor !== 'function') {
  3873. if (process.env.NODE_ENV !== 'production') {
  3874. warn(("Invalid Component definition: " + (String(Ctor))), context);
  3875. }
  3876. return
  3877. }
  3878. // async component
  3879. if (isUndef(Ctor.cid)) {
  3880. Ctor = resolveAsyncComponent(Ctor, baseCtor, context);
  3881. if (Ctor === undefined) {
  3882. // return nothing if this is indeed an async component
  3883. // wait for the callback to trigger parent update.
  3884. return
  3885. }
  3886. }
  3887. // resolve constructor options in case global mixins are applied after
  3888. // component constructor creation
  3889. resolveConstructorOptions(Ctor);
  3890. data = data || {};
  3891. // transform component v-model data into props & events
  3892. if (isDef(data.model)) {
  3893. transformModel(Ctor.options, data);
  3894. }
  3895. // extract props
  3896. var propsData = extractPropsFromVNodeData(data, Ctor, tag);
  3897. // functional component
  3898. if (isTrue(Ctor.options.functional)) {
  3899. return createFunctionalComponent(Ctor, propsData, data, context, children)
  3900. }
  3901. // extract listeners, since these needs to be treated as
  3902. // child component listeners instead of DOM listeners
  3903. var listeners = data.on;
  3904. // replace with listeners with .native modifier
  3905. data.on = data.nativeOn;
  3906. if (isTrue(Ctor.options.abstract)) {
  3907. // abstract components do not keep anything
  3908. // other than props & listeners
  3909. data = {};
  3910. }
  3911. // merge component management hooks onto the placeholder node
  3912. mergeHooks(data);
  3913. // return a placeholder vnode
  3914. var name = Ctor.options.name || tag;
  3915. var vnode = new VNode(
  3916. ("vue-component-" + (Ctor.cid) + (name ? ("-" + name) : '')),
  3917. data, undefined, undefined, undefined, context,
  3918. { Ctor: Ctor, propsData: propsData, listeners: listeners, tag: tag, children: children }
  3919. );
  3920. return vnode
  3921. }
  3922. function createComponentInstanceForVnode (
  3923. vnode, // we know it's MountedComponentVNode but flow doesn't
  3924. parent, // activeInstance in lifecycle state
  3925. parentElm,
  3926. refElm
  3927. ) {
  3928. var vnodeComponentOptions = vnode.componentOptions;
  3929. var options = {
  3930. _isComponent: true,
  3931. parent: parent,
  3932. propsData: vnodeComponentOptions.propsData,
  3933. _componentTag: vnodeComponentOptions.tag,
  3934. _parentVnode: vnode,
  3935. _parentListeners: vnodeComponentOptions.listeners,
  3936. _renderChildren: vnodeComponentOptions.children,
  3937. _parentElm: parentElm || null,
  3938. _refElm: refElm || null
  3939. };
  3940. // check inline-template render functions
  3941. var inlineTemplate = vnode.data.inlineTemplate;
  3942. if (isDef(inlineTemplate)) {
  3943. options.render = inlineTemplate.render;
  3944. options.staticRenderFns = inlineTemplate.staticRenderFns;
  3945. }
  3946. return new vnodeComponentOptions.Ctor(options)
  3947. }
  3948. function mergeHooks (data) {
  3949. if (!data.hook) {
  3950. data.hook = {};
  3951. }
  3952. for (var i = 0; i < hooksToMerge.length; i++) {
  3953. var key = hooksToMerge[i];
  3954. var fromParent = data.hook[key];
  3955. var ours = componentVNodeHooks[key];
  3956. data.hook[key] = fromParent ? mergeHook$1(ours, fromParent) : ours;
  3957. }
  3958. }
  3959. function mergeHook$1 (one, two) {
  3960. return function (a, b, c, d) {
  3961. one(a, b, c, d);
  3962. two(a, b, c, d);
  3963. }
  3964. }
  3965. // transform component v-model info (value and callback) into
  3966. // prop and event handler respectively.
  3967. function transformModel (options, data) {
  3968. var prop = (options.model && options.model.prop) || 'value';
  3969. var event = (options.model && options.model.event) || 'input';(data.props || (data.props = {}))[prop] = data.model.value;
  3970. var on = data.on || (data.on = {});
  3971. if (isDef(on[event])) {
  3972. on[event] = [data.model.callback].concat(on[event]);
  3973. } else {
  3974. on[event] = data.model.callback;
  3975. }
  3976. }
  3977. /* */
  3978. var SIMPLE_NORMALIZE = 1;
  3979. var ALWAYS_NORMALIZE = 2;
  3980. // wrapper function for providing a more flexible interface
  3981. // without getting yelled at by flow
  3982. function createElement (
  3983. context,
  3984. tag,
  3985. data,
  3986. children,
  3987. normalizationType,
  3988. alwaysNormalize
  3989. ) {
  3990. if (Array.isArray(data) || isPrimitive(data)) {
  3991. normalizationType = children;
  3992. children = data;
  3993. data = undefined;
  3994. }
  3995. if (isTrue(alwaysNormalize)) {
  3996. normalizationType = ALWAYS_NORMALIZE;
  3997. }
  3998. return _createElement(context, tag, data, children, normalizationType)
  3999. }
  4000. function _createElement (
  4001. context,
  4002. tag,
  4003. data,
  4004. children,
  4005. normalizationType
  4006. ) {
  4007. if (isDef(data) && isDef((data).__ob__)) {
  4008. process.env.NODE_ENV !== 'production' && warn(
  4009. "Avoid using observed data object as vnode data: " + (JSON.stringify(data)) + "\n" +
  4010. 'Always create fresh vnode data objects in each render!',
  4011. context
  4012. );
  4013. return createEmptyVNode()
  4014. }
  4015. if (!tag) {
  4016. // in case of component :is set to falsy value
  4017. return createEmptyVNode()
  4018. }
  4019. // support single function children as default scoped slot
  4020. if (Array.isArray(children) &&
  4021. typeof children[0] === 'function'
  4022. ) {
  4023. data = data || {};
  4024. data.scopedSlots = { default: children[0] };
  4025. children.length = 0;
  4026. }
  4027. if (normalizationType === ALWAYS_NORMALIZE) {
  4028. children = normalizeChildren(children);
  4029. } else if (normalizationType === SIMPLE_NORMALIZE) {
  4030. children = simpleNormalizeChildren(children);
  4031. }
  4032. var vnode, ns;
  4033. if (typeof tag === 'string') {
  4034. var Ctor;
  4035. ns = config.getTagNamespace(tag);
  4036. if (config.isReservedTag(tag)) {
  4037. // platform built-in elements
  4038. vnode = new VNode(
  4039. config.parsePlatformTagName(tag), data, children,
  4040. undefined, undefined, context
  4041. );
  4042. } else if (isDef(Ctor = resolveAsset(context.$options, 'components', tag))) {
  4043. // component
  4044. vnode = createComponent(Ctor, data, context, children, tag);
  4045. } else {
  4046. // unknown or unlisted namespaced elements
  4047. // check at runtime because it may get assigned a namespace when its
  4048. // parent normalizes children
  4049. vnode = new VNode(
  4050. tag, data, children,
  4051. undefined, undefined, context
  4052. );
  4053. }
  4054. } else {
  4055. // direct component options / constructor
  4056. vnode = createComponent(tag, data, context, children);
  4057. }
  4058. if (isDef(vnode)) {
  4059. if (ns) { applyNS(vnode, ns); }
  4060. return vnode
  4061. } else {
  4062. return createEmptyVNode()
  4063. }
  4064. }
  4065. function applyNS (vnode, ns) {
  4066. vnode.ns = ns;
  4067. if (vnode.tag === 'foreignObject') {
  4068. // use default namespace inside foreignObject
  4069. return
  4070. }
  4071. if (isDef(vnode.children)) {
  4072. for (var i = 0, l = vnode.children.length; i < l; i++) {
  4073. var child = vnode.children[i];
  4074. if (isDef(child.tag) && isUndef(child.ns)) {
  4075. applyNS(child, ns);
  4076. }
  4077. }
  4078. }
  4079. }
  4080. /* */
  4081. /**
  4082. * Runtime helper for rendering v-for lists.
  4083. */
  4084. function renderList (
  4085. val,
  4086. render
  4087. ) {
  4088. var ret, i, l, keys, key;
  4089. if (Array.isArray(val) || typeof val === 'string') {
  4090. ret = new Array(val.length);
  4091. for (i = 0, l = val.length; i < l; i++) {
  4092. ret[i] = render(val[i], i);
  4093. }
  4094. } else if (typeof val === 'number') {
  4095. ret = new Array(val);
  4096. for (i = 0; i < val; i++) {
  4097. ret[i] = render(i + 1, i);
  4098. }
  4099. } else if (isObject(val)) {
  4100. keys = Object.keys(val);
  4101. ret = new Array(keys.length);
  4102. for (i = 0, l = keys.length; i < l; i++) {
  4103. key = keys[i];
  4104. ret[i] = render(val[key], key, i);
  4105. }
  4106. }
  4107. if (isDef(ret)) {
  4108. (ret)._isVList = true;
  4109. }
  4110. return ret
  4111. }
  4112. /* */
  4113. /**
  4114. * Runtime helper for rendering <slot>
  4115. */
  4116. function renderSlot (
  4117. name,
  4118. fallback,
  4119. props,
  4120. bindObject
  4121. ) {
  4122. var scopedSlotFn = this.$scopedSlots[name];
  4123. if (scopedSlotFn) { // scoped slot
  4124. props = props || {};
  4125. if (bindObject) {
  4126. extend(props, bindObject);
  4127. }
  4128. return scopedSlotFn(props) || fallback
  4129. } else {
  4130. var slotNodes = this.$slots[name];
  4131. // warn duplicate slot usage
  4132. if (slotNodes && process.env.NODE_ENV !== 'production') {
  4133. slotNodes._rendered && warn(
  4134. "Duplicate presence of slot \"" + name + "\" found in the same render tree " +
  4135. "- this will likely cause render errors.",
  4136. this
  4137. );
  4138. slotNodes._rendered = true;
  4139. }
  4140. return slotNodes || fallback
  4141. }
  4142. }
  4143. /* */
  4144. /**
  4145. * Runtime helper for resolving filters
  4146. */
  4147. function resolveFilter (id) {
  4148. return resolveAsset(this.$options, 'filters', id, true) || identity
  4149. }
  4150. /* */
  4151. /**
  4152. * Runtime helper for checking keyCodes from config.
  4153. */
  4154. function checkKeyCodes (
  4155. eventKeyCode,
  4156. key,
  4157. builtInAlias
  4158. ) {
  4159. var keyCodes = config.keyCodes[key] || builtInAlias;
  4160. if (Array.isArray(keyCodes)) {
  4161. return keyCodes.indexOf(eventKeyCode) === -1
  4162. } else {
  4163. return keyCodes !== eventKeyCode
  4164. }
  4165. }
  4166. /* */
  4167. /**
  4168. * Runtime helper for merging v-bind="object" into a VNode's data.
  4169. */
  4170. function bindObjectProps (
  4171. data,
  4172. tag,
  4173. value,
  4174. asProp
  4175. ) {
  4176. if (value) {
  4177. if (!isObject(value)) {
  4178. process.env.NODE_ENV !== 'production' && warn(
  4179. 'v-bind without argument expects an Object or Array value',
  4180. this
  4181. );
  4182. } else {
  4183. if (Array.isArray(value)) {
  4184. value = toObject(value);
  4185. }
  4186. var hash;
  4187. for (var key in value) {
  4188. if (key === 'class' || key === 'style') {
  4189. hash = data;
  4190. } else {
  4191. var type = data.attrs && data.attrs.type;
  4192. hash = asProp || config.mustUseProp(tag, type, key)
  4193. ? data.domProps || (data.domProps = {})
  4194. : data.attrs || (data.attrs = {});
  4195. }
  4196. if (!(key in hash)) {
  4197. hash[key] = value[key];
  4198. }
  4199. }
  4200. }
  4201. }
  4202. return data
  4203. }
  4204. /* */
  4205. /**
  4206. * Runtime helper for rendering static trees.
  4207. */
  4208. function renderStatic (
  4209. index,
  4210. isInFor
  4211. ) {
  4212. var tree = this._staticTrees[index];
  4213. // if has already-rendered static tree and not inside v-for,
  4214. // we can reuse the same tree by doing a shallow clone.
  4215. if (tree && !isInFor) {
  4216. return Array.isArray(tree)
  4217. ? cloneVNodes(tree)
  4218. : cloneVNode(tree)
  4219. }
  4220. // otherwise, render a fresh tree.
  4221. tree = this._staticTrees[index] =
  4222. this.$options.staticRenderFns[index].call(this._renderProxy);
  4223. markStatic(tree, ("__static__" + index), false);
  4224. return tree
  4225. }
  4226. /**
  4227. * Runtime helper for v-once.
  4228. * Effectively it means marking the node as static with a unique key.
  4229. */
  4230. function markOnce (
  4231. tree,
  4232. index,
  4233. key
  4234. ) {
  4235. markStatic(tree, ("__once__" + index + (key ? ("_" + key) : "")), true);
  4236. return tree
  4237. }
  4238. function markStatic (
  4239. tree,
  4240. key,
  4241. isOnce
  4242. ) {
  4243. if (Array.isArray(tree)) {
  4244. for (var i = 0; i < tree.length; i++) {
  4245. if (tree[i] && typeof tree[i] !== 'string') {
  4246. markStaticNode(tree[i], (key + "_" + i), isOnce);
  4247. }
  4248. }
  4249. } else {
  4250. markStaticNode(tree, key, isOnce);
  4251. }
  4252. }
  4253. function markStaticNode (node, key, isOnce) {
  4254. node.isStatic = true;
  4255. node.key = key;
  4256. node.isOnce = isOnce;
  4257. }
  4258. /* */
  4259. function initRender (vm) {
  4260. vm._vnode = null; // the root of the child tree
  4261. vm._staticTrees = null;
  4262. var parentVnode = vm.$vnode = vm.$options._parentVnode; // the placeholder node in parent tree
  4263. var renderContext = parentVnode && parentVnode.context;
  4264. vm.$slots = resolveSlots(vm.$options._renderChildren, renderContext);
  4265. vm.$scopedSlots = emptyObject;
  4266. // bind the createElement fn to this instance
  4267. // so that we get proper render context inside it.
  4268. // args order: tag, data, children, normalizationType, alwaysNormalize
  4269. // internal version is used by render functions compiled from templates
  4270. vm._c = function (a, b, c, d) { return createElement(vm, a, b, c, d, false); };
  4271. // normalization is always applied for the public version, used in
  4272. // user-written render functions.
  4273. vm.$createElement = function (a, b, c, d) { return createElement(vm, a, b, c, d, true); };
  4274. }
  4275. function renderMixin (Vue) {
  4276. Vue.prototype.$nextTick = function (fn) {
  4277. return nextTick(fn, this)
  4278. };
  4279. Vue.prototype._render = function () {
  4280. var vm = this;
  4281. var ref = vm.$options;
  4282. var render = ref.render;
  4283. var staticRenderFns = ref.staticRenderFns;
  4284. var _parentVnode = ref._parentVnode;
  4285. if (vm._isMounted) {
  4286. // clone slot nodes on re-renders
  4287. for (var key in vm.$slots) {
  4288. vm.$slots[key] = cloneVNodes(vm.$slots[key]);
  4289. }
  4290. }
  4291. vm.$scopedSlots = (_parentVnode && _parentVnode.data.scopedSlots) || emptyObject;
  4292. if (staticRenderFns && !vm._staticTrees) {
  4293. vm._staticTrees = [];
  4294. }
  4295. // set parent vnode. this allows render functions to have access
  4296. // to the data on the placeholder node.
  4297. vm.$vnode = _parentVnode;
  4298. // render self
  4299. var vnode;
  4300. try {
  4301. vnode = render.call(vm._renderProxy, vm.$createElement);
  4302. } catch (e) {
  4303. handleError(e, vm, "render function");
  4304. // return error render result,
  4305. // or previous vnode to prevent render error causing blank component
  4306. /* istanbul ignore else */
  4307. if (process.env.NODE_ENV !== 'production') {
  4308. vnode = vm.$options.renderError
  4309. ? vm.$options.renderError.call(vm._renderProxy, vm.$createElement, e)
  4310. : vm._vnode;
  4311. } else {
  4312. vnode = vm._vnode;
  4313. }
  4314. }
  4315. // return empty vnode in case the render function errored out
  4316. if (!(vnode instanceof VNode)) {
  4317. if (process.env.NODE_ENV !== 'production' && Array.isArray(vnode)) {
  4318. warn(
  4319. 'Multiple root nodes returned from render function. Render function ' +
  4320. 'should return a single root node.',
  4321. vm
  4322. );
  4323. }
  4324. vnode = createEmptyVNode();
  4325. }
  4326. // set parent
  4327. vnode.parent = _parentVnode;
  4328. return vnode
  4329. };
  4330. // internal render helpers.
  4331. // these are exposed on the instance prototype to reduce generated render
  4332. // code size.
  4333. Vue.prototype._o = markOnce;
  4334. Vue.prototype._n = toNumber;
  4335. Vue.prototype._s = toString;
  4336. Vue.prototype._l = renderList;
  4337. Vue.prototype._t = renderSlot;
  4338. Vue.prototype._q = looseEqual;
  4339. Vue.prototype._i = looseIndexOf;
  4340. Vue.prototype._m = renderStatic;
  4341. Vue.prototype._f = resolveFilter;
  4342. Vue.prototype._k = checkKeyCodes;
  4343. Vue.prototype._b = bindObjectProps;
  4344. Vue.prototype._v = createTextVNode;
  4345. Vue.prototype._e = createEmptyVNode;
  4346. Vue.prototype._u = resolveScopedSlots;
  4347. }
  4348. /* */
  4349. var uid$1 = 0;
  4350. function initMixin (Vue) {
  4351. Vue.prototype._init = function (options) {
  4352. var vm = this;
  4353. // a uid
  4354. vm._uid = uid$1++;
  4355. var startTag, endTag;
  4356. /* istanbul ignore if */
  4357. if (process.env.NODE_ENV !== 'production' && config.performance && mark) {
  4358. startTag = "vue-perf-init:" + (vm._uid);
  4359. endTag = "vue-perf-end:" + (vm._uid);
  4360. mark(startTag);
  4361. }
  4362. // a flag to avoid this being observed
  4363. vm._isVue = true;
  4364. // merge options
  4365. if (options && options._isComponent) {
  4366. // optimize internal component instantiation
  4367. // since dynamic options merging is pretty slow, and none of the
  4368. // internal component options needs special treatment.
  4369. initInternalComponent(vm, options);
  4370. } else {
  4371. vm.$options = mergeOptions(
  4372. resolveConstructorOptions(vm.constructor),
  4373. options || {},
  4374. vm
  4375. );
  4376. }
  4377. /* istanbul ignore else */
  4378. if (process.env.NODE_ENV !== 'production') {
  4379. initProxy(vm);
  4380. } else {
  4381. vm._renderProxy = vm;
  4382. }
  4383. // expose real self
  4384. vm._self = vm;
  4385. initLifecycle(vm);
  4386. initEvents(vm);
  4387. initRender(vm);
  4388. callHook(vm, 'beforeCreate');
  4389. initInjections(vm); // resolve injections before data/props
  4390. initState(vm);
  4391. initProvide(vm); // resolve provide after data/props
  4392. callHook(vm, 'created');
  4393. /* istanbul ignore if */
  4394. if (process.env.NODE_ENV !== 'production' && config.performance && mark) {
  4395. vm._name = formatComponentName(vm, false);
  4396. mark(endTag);
  4397. measure(((vm._name) + " init"), startTag, endTag);
  4398. }
  4399. if (vm.$options.el) {
  4400. vm.$mount(vm.$options.el);
  4401. }
  4402. };
  4403. }
  4404. function initInternalComponent (vm, options) {
  4405. var opts = vm.$options = Object.create(vm.constructor.options);
  4406. // doing this because it's faster than dynamic enumeration.
  4407. opts.parent = options.parent;
  4408. opts.propsData = options.propsData;
  4409. opts._parentVnode = options._parentVnode;
  4410. opts._parentListeners = options._parentListeners;
  4411. opts._renderChildren = options._renderChildren;
  4412. opts._componentTag = options._componentTag;
  4413. opts._parentElm = options._parentElm;
  4414. opts._refElm = options._refElm;
  4415. if (options.render) {
  4416. opts.render = options.render;
  4417. opts.staticRenderFns = options.staticRenderFns;
  4418. }
  4419. }
  4420. function resolveConstructorOptions (Ctor) {
  4421. var options = Ctor.options;
  4422. if (Ctor.super) {
  4423. var superOptions = resolveConstructorOptions(Ctor.super);
  4424. var cachedSuperOptions = Ctor.superOptions;
  4425. if (superOptions !== cachedSuperOptions) {
  4426. // super option changed,
  4427. // need to resolve new options.
  4428. Ctor.superOptions = superOptions;
  4429. // check if there are any late-modified/attached options (#4976)
  4430. var modifiedOptions = resolveModifiedOptions(Ctor);
  4431. // update base extend options
  4432. if (modifiedOptions) {
  4433. extend(Ctor.extendOptions, modifiedOptions);
  4434. }
  4435. options = Ctor.options = mergeOptions(superOptions, Ctor.extendOptions);
  4436. if (options.name) {
  4437. options.components[options.name] = Ctor;
  4438. }
  4439. }
  4440. }
  4441. return options
  4442. }
  4443. function resolveModifiedOptions (Ctor) {
  4444. var modified;
  4445. var latest = Ctor.options;
  4446. var extended = Ctor.extendOptions;
  4447. var sealed = Ctor.sealedOptions;
  4448. for (var key in latest) {
  4449. if (latest[key] !== sealed[key]) {
  4450. if (!modified) { modified = {}; }
  4451. modified[key] = dedupe(latest[key], extended[key], sealed[key]);
  4452. }
  4453. }
  4454. return modified
  4455. }
  4456. function dedupe (latest, extended, sealed) {
  4457. // compare latest and sealed to ensure lifecycle hooks won't be duplicated
  4458. // between merges
  4459. if (Array.isArray(latest)) {
  4460. var res = [];
  4461. sealed = Array.isArray(sealed) ? sealed : [sealed];
  4462. extended = Array.isArray(extended) ? extended : [extended];
  4463. for (var i = 0; i < latest.length; i++) {
  4464. // push original options and not sealed options to exclude duplicated options
  4465. if (extended.indexOf(latest[i]) >= 0 || sealed.indexOf(latest[i]) < 0) {
  4466. res.push(latest[i]);
  4467. }
  4468. }
  4469. return res
  4470. } else {
  4471. return latest
  4472. }
  4473. }
  4474. function Vue$3 (options) {
  4475. if (process.env.NODE_ENV !== 'production' &&
  4476. !(this instanceof Vue$3)
  4477. ) {
  4478. warn('Vue is a constructor and should be called with the `new` keyword');
  4479. }
  4480. this._init(options);
  4481. }
  4482. initMixin(Vue$3);
  4483. stateMixin(Vue$3);
  4484. eventsMixin(Vue$3);
  4485. lifecycleMixin(Vue$3);
  4486. renderMixin(Vue$3);
  4487. /* */
  4488. function initUse (Vue) {
  4489. Vue.use = function (plugin) {
  4490. /* istanbul ignore if */
  4491. if (plugin.installed) {
  4492. return this
  4493. }
  4494. // additional parameters
  4495. var args = toArray(arguments, 1);
  4496. args.unshift(this);
  4497. if (typeof plugin.install === 'function') {
  4498. plugin.install.apply(plugin, args);
  4499. } else if (typeof plugin === 'function') {
  4500. plugin.apply(null, args);
  4501. }
  4502. plugin.installed = true;
  4503. return this
  4504. };
  4505. }
  4506. /* */
  4507. function initMixin$1 (Vue) {
  4508. Vue.mixin = function (mixin) {
  4509. this.options = mergeOptions(this.options, mixin);
  4510. return this
  4511. };
  4512. }
  4513. /* */
  4514. function initExtend (Vue) {
  4515. /**
  4516. * Each instance constructor, including Vue, has a unique
  4517. * cid. This enables us to create wrapped "child
  4518. * constructors" for prototypal inheritance and cache them.
  4519. */
  4520. Vue.cid = 0;
  4521. var cid = 1;
  4522. /**
  4523. * Class inheritance
  4524. */
  4525. Vue.extend = function (extendOptions) {
  4526. extendOptions = extendOptions || {};
  4527. var Super = this;
  4528. var SuperId = Super.cid;
  4529. var cachedCtors = extendOptions._Ctor || (extendOptions._Ctor = {});
  4530. if (cachedCtors[SuperId]) {
  4531. return cachedCtors[SuperId]
  4532. }
  4533. var name = extendOptions.name || Super.options.name;
  4534. if (process.env.NODE_ENV !== 'production') {
  4535. if (!/^[a-zA-Z][\w-]*$/.test(name)) {
  4536. warn(
  4537. 'Invalid component name: "' + name + '". Component names ' +
  4538. 'can only contain alphanumeric characters and the hyphen, ' +
  4539. 'and must start with a letter.'
  4540. );
  4541. }
  4542. }
  4543. var Sub = function VueComponent (options) {
  4544. this._init(options);
  4545. };
  4546. Sub.prototype = Object.create(Super.prototype);
  4547. Sub.prototype.constructor = Sub;
  4548. Sub.cid = cid++;
  4549. Sub.options = mergeOptions(
  4550. Super.options,
  4551. extendOptions
  4552. );
  4553. Sub['super'] = Super;
  4554. // For props and computed properties, we define the proxy getters on
  4555. // the Vue instances at extension time, on the extended prototype. This
  4556. // avoids Object.defineProperty calls for each instance created.
  4557. if (Sub.options.props) {
  4558. initProps$1(Sub);
  4559. }
  4560. if (Sub.options.computed) {
  4561. initComputed$1(Sub);
  4562. }
  4563. // allow further extension/mixin/plugin usage
  4564. Sub.extend = Super.extend;
  4565. Sub.mixin = Super.mixin;
  4566. Sub.use = Super.use;
  4567. // create asset registers, so extended classes
  4568. // can have their private assets too.
  4569. ASSET_TYPES.forEach(function (type) {
  4570. Sub[type] = Super[type];
  4571. });
  4572. // enable recursive self-lookup
  4573. if (name) {
  4574. Sub.options.components[name] = Sub;
  4575. }
  4576. // keep a reference to the super options at extension time.
  4577. // later at instantiation we can check if Super's options have
  4578. // been updated.
  4579. Sub.superOptions = Super.options;
  4580. Sub.extendOptions = extendOptions;
  4581. Sub.sealedOptions = extend({}, Sub.options);
  4582. // cache constructor
  4583. cachedCtors[SuperId] = Sub;
  4584. return Sub
  4585. };
  4586. }
  4587. function initProps$1 (Comp) {
  4588. var props = Comp.options.props;
  4589. for (var key in props) {
  4590. proxy(Comp.prototype, "_props", key);
  4591. }
  4592. }
  4593. function initComputed$1 (Comp) {
  4594. var computed = Comp.options.computed;
  4595. for (var key in computed) {
  4596. defineComputed(Comp.prototype, key, computed[key]);
  4597. }
  4598. }
  4599. /* */
  4600. function initAssetRegisters (Vue) {
  4601. /**
  4602. * Create asset registration methods.
  4603. */
  4604. ASSET_TYPES.forEach(function (type) {
  4605. Vue[type] = function (
  4606. id,
  4607. definition
  4608. ) {
  4609. if (!definition) {
  4610. return this.options[type + 's'][id]
  4611. } else {
  4612. /* istanbul ignore if */
  4613. if (process.env.NODE_ENV !== 'production') {
  4614. if (type === 'component' && config.isReservedTag(id)) {
  4615. warn(
  4616. 'Do not use built-in or reserved HTML elements as component ' +
  4617. 'id: ' + id
  4618. );
  4619. }
  4620. }
  4621. if (type === 'component' && isPlainObject(definition)) {
  4622. definition.name = definition.name || id;
  4623. definition = this.options._base.extend(definition);
  4624. }
  4625. if (type === 'directive' && typeof definition === 'function') {
  4626. definition = { bind: definition, update: definition };
  4627. }
  4628. this.options[type + 's'][id] = definition;
  4629. return definition
  4630. }
  4631. };
  4632. });
  4633. }
  4634. /* */
  4635. var patternTypes = [String, RegExp];
  4636. function getComponentName (opts) {
  4637. return opts && (opts.Ctor.options.name || opts.tag)
  4638. }
  4639. function matches (pattern, name) {
  4640. if (typeof pattern === 'string') {
  4641. return pattern.split(',').indexOf(name) > -1
  4642. } else if (isRegExp(pattern)) {
  4643. return pattern.test(name)
  4644. }
  4645. /* istanbul ignore next */
  4646. return false
  4647. }
  4648. function pruneCache (cache, current, filter) {
  4649. for (var key in cache) {
  4650. var cachedNode = cache[key];
  4651. if (cachedNode) {
  4652. var name = getComponentName(cachedNode.componentOptions);
  4653. if (name && !filter(name)) {
  4654. if (cachedNode !== current) {
  4655. pruneCacheEntry(cachedNode);
  4656. }
  4657. cache[key] = null;
  4658. }
  4659. }
  4660. }
  4661. }
  4662. function pruneCacheEntry (vnode) {
  4663. if (vnode) {
  4664. vnode.componentInstance.$destroy();
  4665. }
  4666. }
  4667. var KeepAlive = {
  4668. name: 'keep-alive',
  4669. abstract: true,
  4670. props: {
  4671. include: patternTypes,
  4672. exclude: patternTypes
  4673. },
  4674. created: function created () {
  4675. this.cache = Object.create(null);
  4676. },
  4677. destroyed: function destroyed () {
  4678. var this$1 = this;
  4679. for (var key in this$1.cache) {
  4680. pruneCacheEntry(this$1.cache[key]);
  4681. }
  4682. },
  4683. watch: {
  4684. include: function include (val) {
  4685. pruneCache(this.cache, this._vnode, function (name) { return matches(val, name); });
  4686. },
  4687. exclude: function exclude (val) {
  4688. pruneCache(this.cache, this._vnode, function (name) { return !matches(val, name); });
  4689. }
  4690. },
  4691. render: function render () {
  4692. var vnode = getFirstComponentChild(this.$slots.default);
  4693. var componentOptions = vnode && vnode.componentOptions;
  4694. if (componentOptions) {
  4695. // check pattern
  4696. var name = getComponentName(componentOptions);
  4697. if (name && (
  4698. (this.include && !matches(this.include, name)) ||
  4699. (this.exclude && matches(this.exclude, name))
  4700. )) {
  4701. return vnode
  4702. }
  4703. var key = vnode.key == null
  4704. // same constructor may get registered as different local components
  4705. // so cid alone is not enough (#3269)
  4706. ? componentOptions.Ctor.cid + (componentOptions.tag ? ("::" + (componentOptions.tag)) : '')
  4707. : vnode.key;
  4708. if (this.cache[key]) {
  4709. vnode.componentInstance = this.cache[key].componentInstance;
  4710. } else {
  4711. this.cache[key] = vnode;
  4712. }
  4713. vnode.data.keepAlive = true;
  4714. }
  4715. return vnode
  4716. }
  4717. };
  4718. var builtInComponents = {
  4719. KeepAlive: KeepAlive
  4720. };
  4721. /* */
  4722. function initGlobalAPI (Vue) {
  4723. // config
  4724. var configDef = {};
  4725. configDef.get = function () { return config; };
  4726. if (process.env.NODE_ENV !== 'production') {
  4727. configDef.set = function () {
  4728. warn(
  4729. 'Do not replace the Vue.config object, set individual fields instead.'
  4730. );
  4731. };
  4732. }
  4733. Object.defineProperty(Vue, 'config', configDef);
  4734. // exposed util methods.
  4735. // NOTE: these are not considered part of the public API - avoid relying on
  4736. // them unless you are aware of the risk.
  4737. Vue.util = {
  4738. warn: warn,
  4739. extend: extend,
  4740. mergeOptions: mergeOptions,
  4741. defineReactive: defineReactive$$1
  4742. };
  4743. Vue.set = set;
  4744. Vue.delete = del;
  4745. Vue.nextTick = nextTick;
  4746. Vue.options = Object.create(null);
  4747. ASSET_TYPES.forEach(function (type) {
  4748. Vue.options[type + 's'] = Object.create(null);
  4749. });
  4750. // this is used to identify the "base" constructor to extend all plain-object
  4751. // components with in Weex's multi-instance scenarios.
  4752. Vue.options._base = Vue;
  4753. extend(Vue.options.components, builtInComponents);
  4754. initUse(Vue);
  4755. initMixin$1(Vue);
  4756. initExtend(Vue);
  4757. initAssetRegisters(Vue);
  4758. }
  4759. initGlobalAPI(Vue$3);
  4760. Object.defineProperty(Vue$3.prototype, '$isServer', {
  4761. get: isServerRendering
  4762. });
  4763. Object.defineProperty(Vue$3.prototype, '$ssrContext', {
  4764. get: function get () {
  4765. /* istanbul ignore next */
  4766. return this.$vnode.ssrContext
  4767. }
  4768. });
  4769. Vue$3.version = '2.3.3';
  4770. /* */
  4771. // these are reserved for web because they are directly compiled away
  4772. // during template compilation
  4773. var isReservedAttr = makeMap('style,class');
  4774. // attributes that should be using props for binding
  4775. var acceptValue = makeMap('input,textarea,option,select');
  4776. var mustUseProp = function (tag, type, attr) {
  4777. return (
  4778. (attr === 'value' && acceptValue(tag)) && type !== 'button' ||
  4779. (attr === 'selected' && tag === 'option') ||
  4780. (attr === 'checked' && tag === 'input') ||
  4781. (attr === 'muted' && tag === 'video')
  4782. )
  4783. };
  4784. var isEnumeratedAttr = makeMap('contenteditable,draggable,spellcheck');
  4785. var isBooleanAttr = makeMap(
  4786. 'allowfullscreen,async,autofocus,autoplay,checked,compact,controls,declare,' +
  4787. 'default,defaultchecked,defaultmuted,defaultselected,defer,disabled,' +
  4788. 'enabled,formnovalidate,hidden,indeterminate,inert,ismap,itemscope,loop,multiple,' +
  4789. 'muted,nohref,noresize,noshade,novalidate,nowrap,open,pauseonexit,readonly,' +
  4790. 'required,reversed,scoped,seamless,selected,sortable,translate,' +
  4791. 'truespeed,typemustmatch,visible'
  4792. );
  4793. var xlinkNS = 'http://www.w3.org/1999/xlink';
  4794. var isXlink = function (name) {
  4795. return name.charAt(5) === ':' && name.slice(0, 5) === 'xlink'
  4796. };
  4797. var getXlinkProp = function (name) {
  4798. return isXlink(name) ? name.slice(6, name.length) : ''
  4799. };
  4800. var isFalsyAttrValue = function (val) {
  4801. return val == null || val === false
  4802. };
  4803. /* */
  4804. function genClassForVnode (vnode) {
  4805. var data = vnode.data;
  4806. var parentNode = vnode;
  4807. var childNode = vnode;
  4808. while (isDef(childNode.componentInstance)) {
  4809. childNode = childNode.componentInstance._vnode;
  4810. if (childNode.data) {
  4811. data = mergeClassData(childNode.data, data);
  4812. }
  4813. }
  4814. while (isDef(parentNode = parentNode.parent)) {
  4815. if (parentNode.data) {
  4816. data = mergeClassData(data, parentNode.data);
  4817. }
  4818. }
  4819. return genClassFromData(data)
  4820. }
  4821. function mergeClassData (child, parent) {
  4822. return {
  4823. staticClass: concat(child.staticClass, parent.staticClass),
  4824. class: isDef(child.class)
  4825. ? [child.class, parent.class]
  4826. : parent.class
  4827. }
  4828. }
  4829. function genClassFromData (data) {
  4830. var dynamicClass = data.class;
  4831. var staticClass = data.staticClass;
  4832. if (isDef(staticClass) || isDef(dynamicClass)) {
  4833. return concat(staticClass, stringifyClass(dynamicClass))
  4834. }
  4835. /* istanbul ignore next */
  4836. return ''
  4837. }
  4838. function concat (a, b) {
  4839. return a ? b ? (a + ' ' + b) : a : (b || '')
  4840. }
  4841. function stringifyClass (value) {
  4842. if (isUndef(value)) {
  4843. return ''
  4844. }
  4845. if (typeof value === 'string') {
  4846. return value
  4847. }
  4848. var res = '';
  4849. if (Array.isArray(value)) {
  4850. var stringified;
  4851. for (var i = 0, l = value.length; i < l; i++) {
  4852. if (isDef(value[i])) {
  4853. if (isDef(stringified = stringifyClass(value[i])) && stringified !== '') {
  4854. res += stringified + ' ';
  4855. }
  4856. }
  4857. }
  4858. return res.slice(0, -1)
  4859. }
  4860. if (isObject(value)) {
  4861. for (var key in value) {
  4862. if (value[key]) { res += key + ' '; }
  4863. }
  4864. return res.slice(0, -1)
  4865. }
  4866. /* istanbul ignore next */
  4867. return res
  4868. }
  4869. /* */
  4870. var namespaceMap = {
  4871. svg: 'http://www.w3.org/2000/svg',
  4872. math: 'http://www.w3.org/1998/Math/MathML'
  4873. };
  4874. var isHTMLTag = makeMap(
  4875. 'html,body,base,head,link,meta,style,title,' +
  4876. 'address,article,aside,footer,header,h1,h2,h3,h4,h5,h6,hgroup,nav,section,' +
  4877. 'div,dd,dl,dt,figcaption,figure,hr,img,li,main,ol,p,pre,ul,' +
  4878. 'a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,rtc,ruby,' +
  4879. 's,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,' +
  4880. 'embed,object,param,source,canvas,script,noscript,del,ins,' +
  4881. 'caption,col,colgroup,table,thead,tbody,td,th,tr,' +
  4882. 'button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,' +
  4883. 'output,progress,select,textarea,' +
  4884. 'details,dialog,menu,menuitem,summary,' +
  4885. 'content,element,shadow,template'
  4886. );
  4887. // this map is intentionally selective, only covering SVG elements that may
  4888. // contain child elements.
  4889. var isSVG = makeMap(
  4890. 'svg,animate,circle,clippath,cursor,defs,desc,ellipse,filter,font-face,' +
  4891. 'foreignObject,g,glyph,image,line,marker,mask,missing-glyph,path,pattern,' +
  4892. 'polygon,polyline,rect,switch,symbol,text,textpath,tspan,use,view',
  4893. true
  4894. );
  4895. var isPreTag = function (tag) { return tag === 'pre'; };
  4896. var isReservedTag = function (tag) {
  4897. return isHTMLTag(tag) || isSVG(tag)
  4898. };
  4899. function getTagNamespace (tag) {
  4900. if (isSVG(tag)) {
  4901. return 'svg'
  4902. }
  4903. // basic support for MathML
  4904. // note it doesn't support other MathML elements being component roots
  4905. if (tag === 'math') {
  4906. return 'math'
  4907. }
  4908. }
  4909. var unknownElementCache = Object.create(null);
  4910. function isUnknownElement (tag) {
  4911. /* istanbul ignore if */
  4912. if (!inBrowser) {
  4913. return true
  4914. }
  4915. if (isReservedTag(tag)) {
  4916. return false
  4917. }
  4918. tag = tag.toLowerCase();
  4919. /* istanbul ignore if */
  4920. if (unknownElementCache[tag] != null) {
  4921. return unknownElementCache[tag]
  4922. }
  4923. var el = document.createElement(tag);
  4924. if (tag.indexOf('-') > -1) {
  4925. // http://stackoverflow.com/a/28210364/1070244
  4926. return (unknownElementCache[tag] = (
  4927. el.constructor === window.HTMLUnknownElement ||
  4928. el.constructor === window.HTMLElement
  4929. ))
  4930. } else {
  4931. return (unknownElementCache[tag] = /HTMLUnknownElement/.test(el.toString()))
  4932. }
  4933. }
  4934. /* */
  4935. /**
  4936. * Query an element selector if it's not an element already.
  4937. */
  4938. function query (el) {
  4939. if (typeof el === 'string') {
  4940. var selected = document.querySelector(el);
  4941. if (!selected) {
  4942. process.env.NODE_ENV !== 'production' && warn(
  4943. 'Cannot find element: ' + el
  4944. );
  4945. return document.createElement('div')
  4946. }
  4947. return selected
  4948. } else {
  4949. return el
  4950. }
  4951. }
  4952. /* */
  4953. function createElement$1 (tagName, vnode) {
  4954. var elm = document.createElement(tagName);
  4955. if (tagName !== 'select') {
  4956. return elm
  4957. }
  4958. // false or null will remove the attribute but undefined will not
  4959. if (vnode.data && vnode.data.attrs && vnode.data.attrs.multiple !== undefined) {
  4960. elm.setAttribute('multiple', 'multiple');
  4961. }
  4962. return elm
  4963. }
  4964. function createElementNS (namespace, tagName) {
  4965. return document.createElementNS(namespaceMap[namespace], tagName)
  4966. }
  4967. function createTextNode (text) {
  4968. return document.createTextNode(text)
  4969. }
  4970. function createComment (text) {
  4971. return document.createComment(text)
  4972. }
  4973. function insertBefore (parentNode, newNode, referenceNode) {
  4974. parentNode.insertBefore(newNode, referenceNode);
  4975. }
  4976. function removeChild (node, child) {
  4977. node.removeChild(child);
  4978. }
  4979. function appendChild (node, child) {
  4980. node.appendChild(child);
  4981. }
  4982. function parentNode (node) {
  4983. return node.parentNode
  4984. }
  4985. function nextSibling (node) {
  4986. return node.nextSibling
  4987. }
  4988. function tagName (node) {
  4989. return node.tagName
  4990. }
  4991. function setTextContent (node, text) {
  4992. node.textContent = text;
  4993. }
  4994. function setAttribute (node, key, val) {
  4995. node.setAttribute(key, val);
  4996. }
  4997. var nodeOps = Object.freeze({
  4998. createElement: createElement$1,
  4999. createElementNS: createElementNS,
  5000. createTextNode: createTextNode,
  5001. createComment: createComment,
  5002. insertBefore: insertBefore,
  5003. removeChild: removeChild,
  5004. appendChild: appendChild,
  5005. parentNode: parentNode,
  5006. nextSibling: nextSibling,
  5007. tagName: tagName,
  5008. setTextContent: setTextContent,
  5009. setAttribute: setAttribute
  5010. });
  5011. /* */
  5012. var ref = {
  5013. create: function create (_, vnode) {
  5014. registerRef(vnode);
  5015. },
  5016. update: function update (oldVnode, vnode) {
  5017. if (oldVnode.data.ref !== vnode.data.ref) {
  5018. registerRef(oldVnode, true);
  5019. registerRef(vnode);
  5020. }
  5021. },
  5022. destroy: function destroy (vnode) {
  5023. registerRef(vnode, true);
  5024. }
  5025. };
  5026. function registerRef (vnode, isRemoval) {
  5027. var key = vnode.data.ref;
  5028. if (!key) { return }
  5029. var vm = vnode.context;
  5030. var ref = vnode.componentInstance || vnode.elm;
  5031. var refs = vm.$refs;
  5032. if (isRemoval) {
  5033. if (Array.isArray(refs[key])) {
  5034. remove(refs[key], ref);
  5035. } else if (refs[key] === ref) {
  5036. refs[key] = undefined;
  5037. }
  5038. } else {
  5039. if (vnode.data.refInFor) {
  5040. if (Array.isArray(refs[key]) && refs[key].indexOf(ref) < 0) {
  5041. refs[key].push(ref);
  5042. } else {
  5043. refs[key] = [ref];
  5044. }
  5045. } else {
  5046. refs[key] = ref;
  5047. }
  5048. }
  5049. }
  5050. /**
  5051. * Virtual DOM patching algorithm based on Snabbdom by
  5052. * Simon Friis Vindum (@paldepind)
  5053. * Licensed under the MIT License
  5054. * https://github.com/paldepind/snabbdom/blob/master/LICENSE
  5055. *
  5056. * modified by Evan You (@yyx990803)
  5057. *
  5058. /*
  5059. * Not type-checking this because this file is perf-critical and the cost
  5060. * of making flow understand it is not worth it.
  5061. */
  5062. var emptyNode = new VNode('', {}, []);
  5063. var hooks = ['create', 'activate', 'update', 'remove', 'destroy'];
  5064. function sameVnode (a, b) {
  5065. return (
  5066. a.key === b.key &&
  5067. a.tag === b.tag &&
  5068. a.isComment === b.isComment &&
  5069. isDef(a.data) === isDef(b.data) &&
  5070. sameInputType(a, b)
  5071. )
  5072. }
  5073. // Some browsers do not support dynamically changing type for <input>
  5074. // so they need to be treated as different nodes
  5075. function sameInputType (a, b) {
  5076. if (a.tag !== 'input') { return true }
  5077. var i;
  5078. var typeA = isDef(i = a.data) && isDef(i = i.attrs) && i.type;
  5079. var typeB = isDef(i = b.data) && isDef(i = i.attrs) && i.type;
  5080. return typeA === typeB
  5081. }
  5082. function createKeyToOldIdx (children, beginIdx, endIdx) {
  5083. var i, key;
  5084. var map = {};
  5085. for (i = beginIdx; i <= endIdx; ++i) {
  5086. key = children[i].key;
  5087. if (isDef(key)) { map[key] = i; }
  5088. }
  5089. return map
  5090. }
  5091. function createPatchFunction (backend) {
  5092. var i, j;
  5093. var cbs = {};
  5094. var modules = backend.modules;
  5095. var nodeOps = backend.nodeOps;
  5096. for (i = 0; i < hooks.length; ++i) {
  5097. cbs[hooks[i]] = [];
  5098. for (j = 0; j < modules.length; ++j) {
  5099. if (isDef(modules[j][hooks[i]])) {
  5100. cbs[hooks[i]].push(modules[j][hooks[i]]);
  5101. }
  5102. }
  5103. }
  5104. function emptyNodeAt (elm) {
  5105. return new VNode(nodeOps.tagName(elm).toLowerCase(), {}, [], undefined, elm)
  5106. }
  5107. function createRmCb (childElm, listeners) {
  5108. function remove$$1 () {
  5109. if (--remove$$1.listeners === 0) {
  5110. removeNode(childElm);
  5111. }
  5112. }
  5113. remove$$1.listeners = listeners;
  5114. return remove$$1
  5115. }
  5116. function removeNode (el) {
  5117. var parent = nodeOps.parentNode(el);
  5118. // element may have already been removed due to v-html / v-text
  5119. if (isDef(parent)) {
  5120. nodeOps.removeChild(parent, el);
  5121. }
  5122. }
  5123. var inPre = 0;
  5124. function createElm (vnode, insertedVnodeQueue, parentElm, refElm, nested) {
  5125. vnode.isRootInsert = !nested; // for transition enter check
  5126. if (createComponent(vnode, insertedVnodeQueue, parentElm, refElm)) {
  5127. return
  5128. }
  5129. var data = vnode.data;
  5130. var children = vnode.children;
  5131. var tag = vnode.tag;
  5132. if (isDef(tag)) {
  5133. if (process.env.NODE_ENV !== 'production') {
  5134. if (data && data.pre) {
  5135. inPre++;
  5136. }
  5137. if (
  5138. !inPre &&
  5139. !vnode.ns &&
  5140. !(config.ignoredElements.length && config.ignoredElements.indexOf(tag) > -1) &&
  5141. config.isUnknownElement(tag)
  5142. ) {
  5143. warn(
  5144. 'Unknown custom element: <' + tag + '> - did you ' +
  5145. 'register the component correctly? For recursive components, ' +
  5146. 'make sure to provide the "name" option.',
  5147. vnode.context
  5148. );
  5149. }
  5150. }
  5151. vnode.elm = vnode.ns
  5152. ? nodeOps.createElementNS(vnode.ns, tag)
  5153. : nodeOps.createElement(tag, vnode);
  5154. setScope(vnode);
  5155. /* istanbul ignore if */
  5156. {
  5157. createChildren(vnode, children, insertedVnodeQueue);
  5158. if (isDef(data)) {
  5159. invokeCreateHooks(vnode, insertedVnodeQueue);
  5160. }
  5161. insert(parentElm, vnode.elm, refElm);
  5162. }
  5163. if (process.env.NODE_ENV !== 'production' && data && data.pre) {
  5164. inPre--;
  5165. }
  5166. } else if (isTrue(vnode.isComment)) {
  5167. vnode.elm = nodeOps.createComment(vnode.text);
  5168. insert(parentElm, vnode.elm, refElm);
  5169. } else {
  5170. vnode.elm = nodeOps.createTextNode(vnode.text);
  5171. insert(parentElm, vnode.elm, refElm);
  5172. }
  5173. }
  5174. function createComponent (vnode, insertedVnodeQueue, parentElm, refElm) {
  5175. var i = vnode.data;
  5176. if (isDef(i)) {
  5177. var isReactivated = isDef(vnode.componentInstance) && i.keepAlive;
  5178. if (isDef(i = i.hook) && isDef(i = i.init)) {
  5179. i(vnode, false /* hydrating */, parentElm, refElm);
  5180. }
  5181. // after calling the init hook, if the vnode is a child component
  5182. // it should've created a child instance and mounted it. the child
  5183. // component also has set the placeholder vnode's elm.
  5184. // in that case we can just return the element and be done.
  5185. if (isDef(vnode.componentInstance)) {
  5186. initComponent(vnode, insertedVnodeQueue);
  5187. if (isTrue(isReactivated)) {
  5188. reactivateComponent(vnode, insertedVnodeQueue, parentElm, refElm);
  5189. }
  5190. return true
  5191. }
  5192. }
  5193. }
  5194. function initComponent (vnode, insertedVnodeQueue) {
  5195. if (isDef(vnode.data.pendingInsert)) {
  5196. insertedVnodeQueue.push.apply(insertedVnodeQueue, vnode.data.pendingInsert);
  5197. }
  5198. vnode.elm = vnode.componentInstance.$el;
  5199. if (isPatchable(vnode)) {
  5200. invokeCreateHooks(vnode, insertedVnodeQueue);
  5201. setScope(vnode);
  5202. } else {
  5203. // empty component root.
  5204. // skip all element-related modules except for ref (#3455)
  5205. registerRef(vnode);
  5206. // make sure to invoke the insert hook
  5207. insertedVnodeQueue.push(vnode);
  5208. }
  5209. }
  5210. function reactivateComponent (vnode, insertedVnodeQueue, parentElm, refElm) {
  5211. var i;
  5212. // hack for #4339: a reactivated component with inner transition
  5213. // does not trigger because the inner node's created hooks are not called
  5214. // again. It's not ideal to involve module-specific logic in here but
  5215. // there doesn't seem to be a better way to do it.
  5216. var innerNode = vnode;
  5217. while (innerNode.componentInstance) {
  5218. innerNode = innerNode.componentInstance._vnode;
  5219. if (isDef(i = innerNode.data) && isDef(i = i.transition)) {
  5220. for (i = 0; i < cbs.activate.length; ++i) {
  5221. cbs.activate[i](emptyNode, innerNode);
  5222. }
  5223. insertedVnodeQueue.push(innerNode);
  5224. break
  5225. }
  5226. }
  5227. // unlike a newly created component,
  5228. // a reactivated keep-alive component doesn't insert itself
  5229. insert(parentElm, vnode.elm, refElm);
  5230. }
  5231. function insert (parent, elm, ref) {
  5232. if (isDef(parent)) {
  5233. if (isDef(ref)) {
  5234. if (ref.parentNode === parent) {
  5235. nodeOps.insertBefore(parent, elm, ref);
  5236. }
  5237. } else {
  5238. nodeOps.appendChild(parent, elm);
  5239. }
  5240. }
  5241. }
  5242. function createChildren (vnode, children, insertedVnodeQueue) {
  5243. if (Array.isArray(children)) {
  5244. for (var i = 0; i < children.length; ++i) {
  5245. createElm(children[i], insertedVnodeQueue, vnode.elm, null, true);
  5246. }
  5247. } else if (isPrimitive(vnode.text)) {
  5248. nodeOps.appendChild(vnode.elm, nodeOps.createTextNode(vnode.text));
  5249. }
  5250. }
  5251. function isPatchable (vnode) {
  5252. while (vnode.componentInstance) {
  5253. vnode = vnode.componentInstance._vnode;
  5254. }
  5255. return isDef(vnode.tag)
  5256. }
  5257. function invokeCreateHooks (vnode, insertedVnodeQueue) {
  5258. for (var i$1 = 0; i$1 < cbs.create.length; ++i$1) {
  5259. cbs.create[i$1](emptyNode, vnode);
  5260. }
  5261. i = vnode.data.hook; // Reuse variable
  5262. if (isDef(i)) {
  5263. if (isDef(i.create)) { i.create(emptyNode, vnode); }
  5264. if (isDef(i.insert)) { insertedVnodeQueue.push(vnode); }
  5265. }
  5266. }
  5267. // set scope id attribute for scoped CSS.
  5268. // this is implemented as a special case to avoid the overhead
  5269. // of going through the normal attribute patching process.
  5270. function setScope (vnode) {
  5271. var i;
  5272. var ancestor = vnode;
  5273. while (ancestor) {
  5274. if (isDef(i = ancestor.context) && isDef(i = i.$options._scopeId)) {
  5275. nodeOps.setAttribute(vnode.elm, i, '');
  5276. }
  5277. ancestor = ancestor.parent;
  5278. }
  5279. // for slot content they should also get the scopeId from the host instance.
  5280. if (isDef(i = activeInstance) &&
  5281. i !== vnode.context &&
  5282. isDef(i = i.$options._scopeId)
  5283. ) {
  5284. nodeOps.setAttribute(vnode.elm, i, '');
  5285. }
  5286. }
  5287. function addVnodes (parentElm, refElm, vnodes, startIdx, endIdx, insertedVnodeQueue) {
  5288. for (; startIdx <= endIdx; ++startIdx) {
  5289. createElm(vnodes[startIdx], insertedVnodeQueue, parentElm, refElm);
  5290. }
  5291. }
  5292. function invokeDestroyHook (vnode) {
  5293. var i, j;
  5294. var data = vnode.data;
  5295. if (isDef(data)) {
  5296. if (isDef(i = data.hook) && isDef(i = i.destroy)) { i(vnode); }
  5297. for (i = 0; i < cbs.destroy.length; ++i) { cbs.destroy[i](vnode); }
  5298. }
  5299. if (isDef(i = vnode.children)) {
  5300. for (j = 0; j < vnode.children.length; ++j) {
  5301. invokeDestroyHook(vnode.children[j]);
  5302. }
  5303. }
  5304. }
  5305. function removeVnodes (parentElm, vnodes, startIdx, endIdx) {
  5306. for (; startIdx <= endIdx; ++startIdx) {
  5307. var ch = vnodes[startIdx];
  5308. if (isDef(ch)) {
  5309. if (isDef(ch.tag)) {
  5310. removeAndInvokeRemoveHook(ch);
  5311. invokeDestroyHook(ch);
  5312. } else { // Text node
  5313. removeNode(ch.elm);
  5314. }
  5315. }
  5316. }
  5317. }
  5318. function removeAndInvokeRemoveHook (vnode, rm) {
  5319. if (isDef(rm) || isDef(vnode.data)) {
  5320. var i;
  5321. var listeners = cbs.remove.length + 1;
  5322. if (isDef(rm)) {
  5323. // we have a recursively passed down rm callback
  5324. // increase the listeners count
  5325. rm.listeners += listeners;
  5326. } else {
  5327. // directly removing
  5328. rm = createRmCb(vnode.elm, listeners);
  5329. }
  5330. // recursively invoke hooks on child component root node
  5331. if (isDef(i = vnode.componentInstance) && isDef(i = i._vnode) && isDef(i.data)) {
  5332. removeAndInvokeRemoveHook(i, rm);
  5333. }
  5334. for (i = 0; i < cbs.remove.length; ++i) {
  5335. cbs.remove[i](vnode, rm);
  5336. }
  5337. if (isDef(i = vnode.data.hook) && isDef(i = i.remove)) {
  5338. i(vnode, rm);
  5339. } else {
  5340. rm();
  5341. }
  5342. } else {
  5343. removeNode(vnode.elm);
  5344. }
  5345. }
  5346. function updateChildren (parentElm, oldCh, newCh, insertedVnodeQueue, removeOnly) {
  5347. var oldStartIdx = 0;
  5348. var newStartIdx = 0;
  5349. var oldEndIdx = oldCh.length - 1;
  5350. var oldStartVnode = oldCh[0];
  5351. var oldEndVnode = oldCh[oldEndIdx];
  5352. var newEndIdx = newCh.length - 1;
  5353. var newStartVnode = newCh[0];
  5354. var newEndVnode = newCh[newEndIdx];
  5355. var oldKeyToIdx, idxInOld, elmToMove, refElm;
  5356. // removeOnly is a special flag used only by <transition-group>
  5357. // to ensure removed elements stay in correct relative positions
  5358. // during leaving transitions
  5359. var canMove = !removeOnly;
  5360. while (oldStartIdx <= oldEndIdx && newStartIdx <= newEndIdx) {
  5361. if (isUndef(oldStartVnode)) {
  5362. oldStartVnode = oldCh[++oldStartIdx]; // Vnode has been moved left
  5363. } else if (isUndef(oldEndVnode)) {
  5364. oldEndVnode = oldCh[--oldEndIdx];
  5365. } else if (sameVnode(oldStartVnode, newStartVnode)) {
  5366. patchVnode(oldStartVnode, newStartVnode, insertedVnodeQueue);
  5367. oldStartVnode = oldCh[++oldStartIdx];
  5368. newStartVnode = newCh[++newStartIdx];
  5369. } else if (sameVnode(oldEndVnode, newEndVnode)) {
  5370. patchVnode(oldEndVnode, newEndVnode, insertedVnodeQueue);
  5371. oldEndVnode = oldCh[--oldEndIdx];
  5372. newEndVnode = newCh[--newEndIdx];
  5373. } else if (sameVnode(oldStartVnode, newEndVnode)) { // Vnode moved right
  5374. patchVnode(oldStartVnode, newEndVnode, insertedVnodeQueue);
  5375. canMove && nodeOps.insertBefore(parentElm, oldStartVnode.elm, nodeOps.nextSibling(oldEndVnode.elm));
  5376. oldStartVnode = oldCh[++oldStartIdx];
  5377. newEndVnode = newCh[--newEndIdx];
  5378. } else if (sameVnode(oldEndVnode, newStartVnode)) { // Vnode moved left
  5379. patchVnode(oldEndVnode, newStartVnode, insertedVnodeQueue);
  5380. canMove && nodeOps.insertBefore(parentElm, oldEndVnode.elm, oldStartVnode.elm);
  5381. oldEndVnode = oldCh[--oldEndIdx];
  5382. newStartVnode = newCh[++newStartIdx];
  5383. } else {
  5384. if (isUndef(oldKeyToIdx)) { oldKeyToIdx = createKeyToOldIdx(oldCh, oldStartIdx, oldEndIdx); }
  5385. idxInOld = isDef(newStartVnode.key) ? oldKeyToIdx[newStartVnode.key] : null;
  5386. if (isUndef(idxInOld)) { // New element
  5387. createElm(newStartVnode, insertedVnodeQueue, parentElm, oldStartVnode.elm);
  5388. newStartVnode = newCh[++newStartIdx];
  5389. } else {
  5390. elmToMove = oldCh[idxInOld];
  5391. /* istanbul ignore if */
  5392. if (process.env.NODE_ENV !== 'production' && !elmToMove) {
  5393. warn(
  5394. 'It seems there are duplicate keys that is causing an update error. ' +
  5395. 'Make sure each v-for item has a unique key.'
  5396. );
  5397. }
  5398. if (sameVnode(elmToMove, newStartVnode)) {
  5399. patchVnode(elmToMove, newStartVnode, insertedVnodeQueue);
  5400. oldCh[idxInOld] = undefined;
  5401. canMove && nodeOps.insertBefore(parentElm, newStartVnode.elm, oldStartVnode.elm);
  5402. newStartVnode = newCh[++newStartIdx];
  5403. } else {
  5404. // same key but different element. treat as new element
  5405. createElm(newStartVnode, insertedVnodeQueue, parentElm, oldStartVnode.elm);
  5406. newStartVnode = newCh[++newStartIdx];
  5407. }
  5408. }
  5409. }
  5410. }
  5411. if (oldStartIdx > oldEndIdx) {
  5412. refElm = isUndef(newCh[newEndIdx + 1]) ? null : newCh[newEndIdx + 1].elm;
  5413. addVnodes(parentElm, refElm, newCh, newStartIdx, newEndIdx, insertedVnodeQueue);
  5414. } else if (newStartIdx > newEndIdx) {
  5415. removeVnodes(parentElm, oldCh, oldStartIdx, oldEndIdx);
  5416. }
  5417. }
  5418. function patchVnode (oldVnode, vnode, insertedVnodeQueue, removeOnly) {
  5419. if (oldVnode === vnode) {
  5420. return
  5421. }
  5422. // reuse element for static trees.
  5423. // note we only do this if the vnode is cloned -
  5424. // if the new node is not cloned it means the render functions have been
  5425. // reset by the hot-reload-api and we need to do a proper re-render.
  5426. if (isTrue(vnode.isStatic) &&
  5427. isTrue(oldVnode.isStatic) &&
  5428. vnode.key === oldVnode.key &&
  5429. (isTrue(vnode.isCloned) || isTrue(vnode.isOnce))
  5430. ) {
  5431. vnode.elm = oldVnode.elm;
  5432. vnode.componentInstance = oldVnode.componentInstance;
  5433. return
  5434. }
  5435. var i;
  5436. var data = vnode.data;
  5437. if (isDef(data) && isDef(i = data.hook) && isDef(i = i.prepatch)) {
  5438. i(oldVnode, vnode);
  5439. }
  5440. var elm = vnode.elm = oldVnode.elm;
  5441. var oldCh = oldVnode.children;
  5442. var ch = vnode.children;
  5443. if (isDef(data) && isPatchable(vnode)) {
  5444. for (i = 0; i < cbs.update.length; ++i) { cbs.update[i](oldVnode, vnode); }
  5445. if (isDef(i = data.hook) && isDef(i = i.update)) { i(oldVnode, vnode); }
  5446. }
  5447. if (isUndef(vnode.text)) {
  5448. if (isDef(oldCh) && isDef(ch)) {
  5449. if (oldCh !== ch) { updateChildren(elm, oldCh, ch, insertedVnodeQueue, removeOnly); }
  5450. } else if (isDef(ch)) {
  5451. if (isDef(oldVnode.text)) { nodeOps.setTextContent(elm, ''); }
  5452. addVnodes(elm, null, ch, 0, ch.length - 1, insertedVnodeQueue);
  5453. } else if (isDef(oldCh)) {
  5454. removeVnodes(elm, oldCh, 0, oldCh.length - 1);
  5455. } else if (isDef(oldVnode.text)) {
  5456. nodeOps.setTextContent(elm, '');
  5457. }
  5458. } else if (oldVnode.text !== vnode.text) {
  5459. nodeOps.setTextContent(elm, vnode.text);
  5460. }
  5461. if (isDef(data)) {
  5462. if (isDef(i = data.hook) && isDef(i = i.postpatch)) { i(oldVnode, vnode); }
  5463. }
  5464. }
  5465. function invokeInsertHook (vnode, queue, initial) {
  5466. // delay insert hooks for component root nodes, invoke them after the
  5467. // element is really inserted
  5468. if (isTrue(initial) && isDef(vnode.parent)) {
  5469. vnode.parent.data.pendingInsert = queue;
  5470. } else {
  5471. for (var i = 0; i < queue.length; ++i) {
  5472. queue[i].data.hook.insert(queue[i]);
  5473. }
  5474. }
  5475. }
  5476. var bailed = false;
  5477. // list of modules that can skip create hook during hydration because they
  5478. // are already rendered on the client or has no need for initialization
  5479. var isRenderedModule = makeMap('attrs,style,class,staticClass,staticStyle,key');
  5480. // Note: this is a browser-only function so we can assume elms are DOM nodes.
  5481. function hydrate (elm, vnode, insertedVnodeQueue) {
  5482. if (process.env.NODE_ENV !== 'production') {
  5483. if (!assertNodeMatch(elm, vnode)) {
  5484. return false
  5485. }
  5486. }
  5487. vnode.elm = elm;
  5488. var tag = vnode.tag;
  5489. var data = vnode.data;
  5490. var children = vnode.children;
  5491. if (isDef(data)) {
  5492. if (isDef(i = data.hook) && isDef(i = i.init)) { i(vnode, true /* hydrating */); }
  5493. if (isDef(i = vnode.componentInstance)) {
  5494. // child component. it should have hydrated its own tree.
  5495. initComponent(vnode, insertedVnodeQueue);
  5496. return true
  5497. }
  5498. }
  5499. if (isDef(tag)) {
  5500. if (isDef(children)) {
  5501. // empty element, allow client to pick up and populate children
  5502. if (!elm.hasChildNodes()) {
  5503. createChildren(vnode, children, insertedVnodeQueue);
  5504. } else {
  5505. var childrenMatch = true;
  5506. var childNode = elm.firstChild;
  5507. for (var i$1 = 0; i$1 < children.length; i$1++) {
  5508. if (!childNode || !hydrate(childNode, children[i$1], insertedVnodeQueue)) {
  5509. childrenMatch = false;
  5510. break
  5511. }
  5512. childNode = childNode.nextSibling;
  5513. }
  5514. // if childNode is not null, it means the actual childNodes list is
  5515. // longer than the virtual children list.
  5516. if (!childrenMatch || childNode) {
  5517. if (process.env.NODE_ENV !== 'production' &&
  5518. typeof console !== 'undefined' &&
  5519. !bailed
  5520. ) {
  5521. bailed = true;
  5522. console.warn('Parent: ', elm);
  5523. console.warn('Mismatching childNodes vs. VNodes: ', elm.childNodes, children);
  5524. }
  5525. return false
  5526. }
  5527. }
  5528. }
  5529. if (isDef(data)) {
  5530. for (var key in data) {
  5531. if (!isRenderedModule(key)) {
  5532. invokeCreateHooks(vnode, insertedVnodeQueue);
  5533. break
  5534. }
  5535. }
  5536. }
  5537. } else if (elm.data !== vnode.text) {
  5538. elm.data = vnode.text;
  5539. }
  5540. return true
  5541. }
  5542. function assertNodeMatch (node, vnode) {
  5543. if (isDef(vnode.tag)) {
  5544. return (
  5545. vnode.tag.indexOf('vue-component') === 0 ||
  5546. vnode.tag.toLowerCase() === (node.tagName && node.tagName.toLowerCase())
  5547. )
  5548. } else {
  5549. return node.nodeType === (vnode.isComment ? 8 : 3)
  5550. }
  5551. }
  5552. return function patch (oldVnode, vnode, hydrating, removeOnly, parentElm, refElm) {
  5553. if (isUndef(vnode)) {
  5554. if (isDef(oldVnode)) { invokeDestroyHook(oldVnode); }
  5555. return
  5556. }
  5557. var isInitialPatch = false;
  5558. var insertedVnodeQueue = [];
  5559. if (isUndef(oldVnode)) {
  5560. // empty mount (likely as component), create new root element
  5561. isInitialPatch = true;
  5562. createElm(vnode, insertedVnodeQueue, parentElm, refElm);
  5563. } else {
  5564. var isRealElement = isDef(oldVnode.nodeType);
  5565. if (!isRealElement && sameVnode(oldVnode, vnode)) {
  5566. // patch existing root node
  5567. patchVnode(oldVnode, vnode, insertedVnodeQueue, removeOnly);
  5568. } else {
  5569. if (isRealElement) {
  5570. // mounting to a real element
  5571. // check if this is server-rendered content and if we can perform
  5572. // a successful hydration.
  5573. if (oldVnode.nodeType === 1 && oldVnode.hasAttribute(SSR_ATTR)) {
  5574. oldVnode.removeAttribute(SSR_ATTR);
  5575. hydrating = true;
  5576. }
  5577. if (isTrue(hydrating)) {
  5578. if (hydrate(oldVnode, vnode, insertedVnodeQueue)) {
  5579. invokeInsertHook(vnode, insertedVnodeQueue, true);
  5580. return oldVnode
  5581. } else if (process.env.NODE_ENV !== 'production') {
  5582. warn(
  5583. 'The client-side rendered virtual DOM tree is not matching ' +
  5584. 'server-rendered content. This is likely caused by incorrect ' +
  5585. 'HTML markup, for example nesting block-level elements inside ' +
  5586. '<p>, or missing <tbody>. Bailing hydration and performing ' +
  5587. 'full client-side render.'
  5588. );
  5589. }
  5590. }
  5591. // either not server-rendered, or hydration failed.
  5592. // create an empty node and replace it
  5593. oldVnode = emptyNodeAt(oldVnode);
  5594. }
  5595. // replacing existing element
  5596. var oldElm = oldVnode.elm;
  5597. var parentElm$1 = nodeOps.parentNode(oldElm);
  5598. createElm(
  5599. vnode,
  5600. insertedVnodeQueue,
  5601. // extremely rare edge case: do not insert if old element is in a
  5602. // leaving transition. Only happens when combining transition +
  5603. // keep-alive + HOCs. (#4590)
  5604. oldElm._leaveCb ? null : parentElm$1,
  5605. nodeOps.nextSibling(oldElm)
  5606. );
  5607. if (isDef(vnode.parent)) {
  5608. // component root element replaced.
  5609. // update parent placeholder node element, recursively
  5610. var ancestor = vnode.parent;
  5611. while (ancestor) {
  5612. ancestor.elm = vnode.elm;
  5613. ancestor = ancestor.parent;
  5614. }
  5615. if (isPatchable(vnode)) {
  5616. for (var i = 0; i < cbs.create.length; ++i) {
  5617. cbs.create[i](emptyNode, vnode.parent);
  5618. }
  5619. }
  5620. }
  5621. if (isDef(parentElm$1)) {
  5622. removeVnodes(parentElm$1, [oldVnode], 0, 0);
  5623. } else if (isDef(oldVnode.tag)) {
  5624. invokeDestroyHook(oldVnode);
  5625. }
  5626. }
  5627. }
  5628. invokeInsertHook(vnode, insertedVnodeQueue, isInitialPatch);
  5629. return vnode.elm
  5630. }
  5631. }
  5632. /* */
  5633. var directives = {
  5634. create: updateDirectives,
  5635. update: updateDirectives,
  5636. destroy: function unbindDirectives (vnode) {
  5637. updateDirectives(vnode, emptyNode);
  5638. }
  5639. };
  5640. function updateDirectives (oldVnode, vnode) {
  5641. if (oldVnode.data.directives || vnode.data.directives) {
  5642. _update(oldVnode, vnode);
  5643. }
  5644. }
  5645. function _update (oldVnode, vnode) {
  5646. var isCreate = oldVnode === emptyNode;
  5647. var isDestroy = vnode === emptyNode;
  5648. var oldDirs = normalizeDirectives$1(oldVnode.data.directives, oldVnode.context);
  5649. var newDirs = normalizeDirectives$1(vnode.data.directives, vnode.context);
  5650. var dirsWithInsert = [];
  5651. var dirsWithPostpatch = [];
  5652. var key, oldDir, dir;
  5653. for (key in newDirs) {
  5654. oldDir = oldDirs[key];
  5655. dir = newDirs[key];
  5656. if (!oldDir) {
  5657. // new directive, bind
  5658. callHook$1(dir, 'bind', vnode, oldVnode);
  5659. if (dir.def && dir.def.inserted) {
  5660. dirsWithInsert.push(dir);
  5661. }
  5662. } else {
  5663. // existing directive, update
  5664. dir.oldValue = oldDir.value;
  5665. callHook$1(dir, 'update', vnode, oldVnode);
  5666. if (dir.def && dir.def.componentUpdated) {
  5667. dirsWithPostpatch.push(dir);
  5668. }
  5669. }
  5670. }
  5671. if (dirsWithInsert.length) {
  5672. var callInsert = function () {
  5673. for (var i = 0; i < dirsWithInsert.length; i++) {
  5674. callHook$1(dirsWithInsert[i], 'inserted', vnode, oldVnode);
  5675. }
  5676. };
  5677. if (isCreate) {
  5678. mergeVNodeHook(vnode.data.hook || (vnode.data.hook = {}), 'insert', callInsert);
  5679. } else {
  5680. callInsert();
  5681. }
  5682. }
  5683. if (dirsWithPostpatch.length) {
  5684. mergeVNodeHook(vnode.data.hook || (vnode.data.hook = {}), 'postpatch', function () {
  5685. for (var i = 0; i < dirsWithPostpatch.length; i++) {
  5686. callHook$1(dirsWithPostpatch[i], 'componentUpdated', vnode, oldVnode);
  5687. }
  5688. });
  5689. }
  5690. if (!isCreate) {
  5691. for (key in oldDirs) {
  5692. if (!newDirs[key]) {
  5693. // no longer present, unbind
  5694. callHook$1(oldDirs[key], 'unbind', oldVnode, oldVnode, isDestroy);
  5695. }
  5696. }
  5697. }
  5698. }
  5699. var emptyModifiers = Object.create(null);
  5700. function normalizeDirectives$1 (
  5701. dirs,
  5702. vm
  5703. ) {
  5704. var res = Object.create(null);
  5705. if (!dirs) {
  5706. return res
  5707. }
  5708. var i, dir;
  5709. for (i = 0; i < dirs.length; i++) {
  5710. dir = dirs[i];
  5711. if (!dir.modifiers) {
  5712. dir.modifiers = emptyModifiers;
  5713. }
  5714. res[getRawDirName(dir)] = dir;
  5715. dir.def = resolveAsset(vm.$options, 'directives', dir.name, true);
  5716. }
  5717. return res
  5718. }
  5719. function getRawDirName (dir) {
  5720. return dir.rawName || ((dir.name) + "." + (Object.keys(dir.modifiers || {}).join('.')))
  5721. }
  5722. function callHook$1 (dir, hook, vnode, oldVnode, isDestroy) {
  5723. var fn = dir.def && dir.def[hook];
  5724. if (fn) {
  5725. try {
  5726. fn(vnode.elm, dir, vnode, oldVnode, isDestroy);
  5727. } catch (e) {
  5728. handleError(e, vnode.context, ("directive " + (dir.name) + " " + hook + " hook"));
  5729. }
  5730. }
  5731. }
  5732. var baseModules = [
  5733. ref,
  5734. directives
  5735. ];
  5736. /* */
  5737. function updateAttrs (oldVnode, vnode) {
  5738. if (isUndef(oldVnode.data.attrs) && isUndef(vnode.data.attrs)) {
  5739. return
  5740. }
  5741. var key, cur, old;
  5742. var elm = vnode.elm;
  5743. var oldAttrs = oldVnode.data.attrs || {};
  5744. var attrs = vnode.data.attrs || {};
  5745. // clone observed objects, as the user probably wants to mutate it
  5746. if (isDef(attrs.__ob__)) {
  5747. attrs = vnode.data.attrs = extend({}, attrs);
  5748. }
  5749. for (key in attrs) {
  5750. cur = attrs[key];
  5751. old = oldAttrs[key];
  5752. if (old !== cur) {
  5753. setAttr(elm, key, cur);
  5754. }
  5755. }
  5756. // #4391: in IE9, setting type can reset value for input[type=radio]
  5757. /* istanbul ignore if */
  5758. if (isIE9 && attrs.value !== oldAttrs.value) {
  5759. setAttr(elm, 'value', attrs.value);
  5760. }
  5761. for (key in oldAttrs) {
  5762. if (isUndef(attrs[key])) {
  5763. if (isXlink(key)) {
  5764. elm.removeAttributeNS(xlinkNS, getXlinkProp(key));
  5765. } else if (!isEnumeratedAttr(key)) {
  5766. elm.removeAttribute(key);
  5767. }
  5768. }
  5769. }
  5770. }
  5771. function setAttr (el, key, value) {
  5772. if (isBooleanAttr(key)) {
  5773. // set attribute for blank value
  5774. // e.g. <option disabled>Select one</option>
  5775. if (isFalsyAttrValue(value)) {
  5776. el.removeAttribute(key);
  5777. } else {
  5778. el.setAttribute(key, key);
  5779. }
  5780. } else if (isEnumeratedAttr(key)) {
  5781. el.setAttribute(key, isFalsyAttrValue(value) || value === 'false' ? 'false' : 'true');
  5782. } else if (isXlink(key)) {
  5783. if (isFalsyAttrValue(value)) {
  5784. el.removeAttributeNS(xlinkNS, getXlinkProp(key));
  5785. } else {
  5786. el.setAttributeNS(xlinkNS, key, value);
  5787. }
  5788. } else {
  5789. if (isFalsyAttrValue(value)) {
  5790. el.removeAttribute(key);
  5791. } else {
  5792. el.setAttribute(key, value);
  5793. }
  5794. }
  5795. }
  5796. var attrs = {
  5797. create: updateAttrs,
  5798. update: updateAttrs
  5799. };
  5800. /* */
  5801. function updateClass (oldVnode, vnode) {
  5802. var el = vnode.elm;
  5803. var data = vnode.data;
  5804. var oldData = oldVnode.data;
  5805. if (
  5806. isUndef(data.staticClass) &&
  5807. isUndef(data.class) && (
  5808. isUndef(oldData) || (
  5809. isUndef(oldData.staticClass) &&
  5810. isUndef(oldData.class)
  5811. )
  5812. )
  5813. ) {
  5814. return
  5815. }
  5816. var cls = genClassForVnode(vnode);
  5817. // handle transition classes
  5818. var transitionClass = el._transitionClasses;
  5819. if (isDef(transitionClass)) {
  5820. cls = concat(cls, stringifyClass(transitionClass));
  5821. }
  5822. // set the class
  5823. if (cls !== el._prevClass) {
  5824. el.setAttribute('class', cls);
  5825. el._prevClass = cls;
  5826. }
  5827. }
  5828. var klass = {
  5829. create: updateClass,
  5830. update: updateClass
  5831. };
  5832. /* */
  5833. var validDivisionCharRE = /[\w).+\-_$\]]/;
  5834. function parseFilters (exp) {
  5835. var inSingle = false;
  5836. var inDouble = false;
  5837. var inTemplateString = false;
  5838. var inRegex = false;
  5839. var curly = 0;
  5840. var square = 0;
  5841. var paren = 0;
  5842. var lastFilterIndex = 0;
  5843. var c, prev, i, expression, filters;
  5844. for (i = 0; i < exp.length; i++) {
  5845. prev = c;
  5846. c = exp.charCodeAt(i);
  5847. if (inSingle) {
  5848. if (c === 0x27 && prev !== 0x5C) { inSingle = false; }
  5849. } else if (inDouble) {
  5850. if (c === 0x22 && prev !== 0x5C) { inDouble = false; }
  5851. } else if (inTemplateString) {
  5852. if (c === 0x60 && prev !== 0x5C) { inTemplateString = false; }
  5853. } else if (inRegex) {
  5854. if (c === 0x2f && prev !== 0x5C) { inRegex = false; }
  5855. } else if (
  5856. c === 0x7C && // pipe
  5857. exp.charCodeAt(i + 1) !== 0x7C &&
  5858. exp.charCodeAt(i - 1) !== 0x7C &&
  5859. !curly && !square && !paren
  5860. ) {
  5861. if (expression === undefined) {
  5862. // first filter, end of expression
  5863. lastFilterIndex = i + 1;
  5864. expression = exp.slice(0, i).trim();
  5865. } else {
  5866. pushFilter();
  5867. }
  5868. } else {
  5869. switch (c) {
  5870. case 0x22: inDouble = true; break // "
  5871. case 0x27: inSingle = true; break // '
  5872. case 0x60: inTemplateString = true; break // `
  5873. case 0x28: paren++; break // (
  5874. case 0x29: paren--; break // )
  5875. case 0x5B: square++; break // [
  5876. case 0x5D: square--; break // ]
  5877. case 0x7B: curly++; break // {
  5878. case 0x7D: curly--; break // }
  5879. }
  5880. if (c === 0x2f) { // /
  5881. var j = i - 1;
  5882. var p = (void 0);
  5883. // find first non-whitespace prev char
  5884. for (; j >= 0; j--) {
  5885. p = exp.charAt(j);
  5886. if (p !== ' ') { break }
  5887. }
  5888. if (!p || !validDivisionCharRE.test(p)) {
  5889. inRegex = true;
  5890. }
  5891. }
  5892. }
  5893. }
  5894. if (expression === undefined) {
  5895. expression = exp.slice(0, i).trim();
  5896. } else if (lastFilterIndex !== 0) {
  5897. pushFilter();
  5898. }
  5899. function pushFilter () {
  5900. (filters || (filters = [])).push(exp.slice(lastFilterIndex, i).trim());
  5901. lastFilterIndex = i + 1;
  5902. }
  5903. if (filters) {
  5904. for (i = 0; i < filters.length; i++) {
  5905. expression = wrapFilter(expression, filters[i]);
  5906. }
  5907. }
  5908. return expression
  5909. }
  5910. function wrapFilter (exp, filter) {
  5911. var i = filter.indexOf('(');
  5912. if (i < 0) {
  5913. // _f: resolveFilter
  5914. return ("_f(\"" + filter + "\")(" + exp + ")")
  5915. } else {
  5916. var name = filter.slice(0, i);
  5917. var args = filter.slice(i + 1);
  5918. return ("_f(\"" + name + "\")(" + exp + "," + args)
  5919. }
  5920. }
  5921. /* */
  5922. function baseWarn (msg) {
  5923. console.error(("[Vue compiler]: " + msg));
  5924. }
  5925. function pluckModuleFunction (
  5926. modules,
  5927. key
  5928. ) {
  5929. return modules
  5930. ? modules.map(function (m) { return m[key]; }).filter(function (_) { return _; })
  5931. : []
  5932. }
  5933. function addProp (el, name, value) {
  5934. (el.props || (el.props = [])).push({ name: name, value: value });
  5935. }
  5936. function addAttr (el, name, value) {
  5937. (el.attrs || (el.attrs = [])).push({ name: name, value: value });
  5938. }
  5939. function addDirective (
  5940. el,
  5941. name,
  5942. rawName,
  5943. value,
  5944. arg,
  5945. modifiers
  5946. ) {
  5947. (el.directives || (el.directives = [])).push({ name: name, rawName: rawName, value: value, arg: arg, modifiers: modifiers });
  5948. }
  5949. function addHandler (
  5950. el,
  5951. name,
  5952. value,
  5953. modifiers,
  5954. important,
  5955. warn
  5956. ) {
  5957. // warn prevent and passive modifier
  5958. /* istanbul ignore if */
  5959. if (
  5960. process.env.NODE_ENV !== 'production' && warn &&
  5961. modifiers && modifiers.prevent && modifiers.passive
  5962. ) {
  5963. warn(
  5964. 'passive and prevent can\'t be used together. ' +
  5965. 'Passive handler can\'t prevent default event.'
  5966. );
  5967. }
  5968. // check capture modifier
  5969. if (modifiers && modifiers.capture) {
  5970. delete modifiers.capture;
  5971. name = '!' + name; // mark the event as captured
  5972. }
  5973. if (modifiers && modifiers.once) {
  5974. delete modifiers.once;
  5975. name = '~' + name; // mark the event as once
  5976. }
  5977. /* istanbul ignore if */
  5978. if (modifiers && modifiers.passive) {
  5979. delete modifiers.passive;
  5980. name = '&' + name; // mark the event as passive
  5981. }
  5982. var events;
  5983. if (modifiers && modifiers.native) {
  5984. delete modifiers.native;
  5985. events = el.nativeEvents || (el.nativeEvents = {});
  5986. } else {
  5987. events = el.events || (el.events = {});
  5988. }
  5989. var newHandler = { value: value, modifiers: modifiers };
  5990. var handlers = events[name];
  5991. /* istanbul ignore if */
  5992. if (Array.isArray(handlers)) {
  5993. important ? handlers.unshift(newHandler) : handlers.push(newHandler);
  5994. } else if (handlers) {
  5995. events[name] = important ? [newHandler, handlers] : [handlers, newHandler];
  5996. } else {
  5997. events[name] = newHandler;
  5998. }
  5999. }
  6000. function getBindingAttr (
  6001. el,
  6002. name,
  6003. getStatic
  6004. ) {
  6005. var dynamicValue =
  6006. getAndRemoveAttr(el, ':' + name) ||
  6007. getAndRemoveAttr(el, 'v-bind:' + name);
  6008. if (dynamicValue != null) {
  6009. return parseFilters(dynamicValue)
  6010. } else if (getStatic !== false) {
  6011. var staticValue = getAndRemoveAttr(el, name);
  6012. if (staticValue != null) {
  6013. return JSON.stringify(staticValue)
  6014. }
  6015. }
  6016. }
  6017. function getAndRemoveAttr (el, name) {
  6018. var val;
  6019. if ((val = el.attrsMap[name]) != null) {
  6020. var list = el.attrsList;
  6021. for (var i = 0, l = list.length; i < l; i++) {
  6022. if (list[i].name === name) {
  6023. list.splice(i, 1);
  6024. break
  6025. }
  6026. }
  6027. }
  6028. return val
  6029. }
  6030. /* */
  6031. /**
  6032. * Cross-platform code generation for component v-model
  6033. */
  6034. function genComponentModel (
  6035. el,
  6036. value,
  6037. modifiers
  6038. ) {
  6039. var ref = modifiers || {};
  6040. var number = ref.number;
  6041. var trim = ref.trim;
  6042. var baseValueExpression = '$$v';
  6043. var valueExpression = baseValueExpression;
  6044. if (trim) {
  6045. valueExpression =
  6046. "(typeof " + baseValueExpression + " === 'string'" +
  6047. "? " + baseValueExpression + ".trim()" +
  6048. ": " + baseValueExpression + ")";
  6049. }
  6050. if (number) {
  6051. valueExpression = "_n(" + valueExpression + ")";
  6052. }
  6053. var assignment = genAssignmentCode(value, valueExpression);
  6054. el.model = {
  6055. value: ("(" + value + ")"),
  6056. expression: ("\"" + value + "\""),
  6057. callback: ("function (" + baseValueExpression + ") {" + assignment + "}")
  6058. };
  6059. }
  6060. /**
  6061. * Cross-platform codegen helper for generating v-model value assignment code.
  6062. */
  6063. function genAssignmentCode (
  6064. value,
  6065. assignment
  6066. ) {
  6067. var modelRs = parseModel(value);
  6068. if (modelRs.idx === null) {
  6069. return (value + "=" + assignment)
  6070. } else {
  6071. return "var $$exp = " + (modelRs.exp) + ", $$idx = " + (modelRs.idx) + ";" +
  6072. "if (!Array.isArray($$exp)){" +
  6073. value + "=" + assignment + "}" +
  6074. "else{$$exp.splice($$idx, 1, " + assignment + ")}"
  6075. }
  6076. }
  6077. /**
  6078. * parse directive model to do the array update transform. a[idx] = val => $$a.splice($$idx, 1, val)
  6079. *
  6080. * for loop possible cases:
  6081. *
  6082. * - test
  6083. * - test[idx]
  6084. * - test[test1[idx]]
  6085. * - test["a"][idx]
  6086. * - xxx.test[a[a].test1[idx]]
  6087. * - test.xxx.a["asa"][test1[idx]]
  6088. *
  6089. */
  6090. var len;
  6091. var str;
  6092. var chr;
  6093. var index$1;
  6094. var expressionPos;
  6095. var expressionEndPos;
  6096. function parseModel (val) {
  6097. str = val;
  6098. len = str.length;
  6099. index$1 = expressionPos = expressionEndPos = 0;
  6100. if (val.indexOf('[') < 0 || val.lastIndexOf(']') < len - 1) {
  6101. return {
  6102. exp: val,
  6103. idx: null
  6104. }
  6105. }
  6106. while (!eof()) {
  6107. chr = next();
  6108. /* istanbul ignore if */
  6109. if (isStringStart(chr)) {
  6110. parseString(chr);
  6111. } else if (chr === 0x5B) {
  6112. parseBracket(chr);
  6113. }
  6114. }
  6115. return {
  6116. exp: val.substring(0, expressionPos),
  6117. idx: val.substring(expressionPos + 1, expressionEndPos)
  6118. }
  6119. }
  6120. function next () {
  6121. return str.charCodeAt(++index$1)
  6122. }
  6123. function eof () {
  6124. return index$1 >= len
  6125. }
  6126. function isStringStart (chr) {
  6127. return chr === 0x22 || chr === 0x27
  6128. }
  6129. function parseBracket (chr) {
  6130. var inBracket = 1;
  6131. expressionPos = index$1;
  6132. while (!eof()) {
  6133. chr = next();
  6134. if (isStringStart(chr)) {
  6135. parseString(chr);
  6136. continue
  6137. }
  6138. if (chr === 0x5B) { inBracket++; }
  6139. if (chr === 0x5D) { inBracket--; }
  6140. if (inBracket === 0) {
  6141. expressionEndPos = index$1;
  6142. break
  6143. }
  6144. }
  6145. }
  6146. function parseString (chr) {
  6147. var stringQuote = chr;
  6148. while (!eof()) {
  6149. chr = next();
  6150. if (chr === stringQuote) {
  6151. break
  6152. }
  6153. }
  6154. }
  6155. /* */
  6156. var warn$1;
  6157. // in some cases, the event used has to be determined at runtime
  6158. // so we used some reserved tokens during compile.
  6159. var RANGE_TOKEN = '__r';
  6160. var CHECKBOX_RADIO_TOKEN = '__c';
  6161. function model (
  6162. el,
  6163. dir,
  6164. _warn
  6165. ) {
  6166. warn$1 = _warn;
  6167. var value = dir.value;
  6168. var modifiers = dir.modifiers;
  6169. var tag = el.tag;
  6170. var type = el.attrsMap.type;
  6171. if (process.env.NODE_ENV !== 'production') {
  6172. var dynamicType = el.attrsMap['v-bind:type'] || el.attrsMap[':type'];
  6173. if (tag === 'input' && dynamicType) {
  6174. warn$1(
  6175. "<input :type=\"" + dynamicType + "\" v-model=\"" + value + "\">:\n" +
  6176. "v-model does not support dynamic input types. Use v-if branches instead."
  6177. );
  6178. }
  6179. // inputs with type="file" are read only and setting the input's
  6180. // value will throw an error.
  6181. if (tag === 'input' && type === 'file') {
  6182. warn$1(
  6183. "<" + (el.tag) + " v-model=\"" + value + "\" type=\"file\">:\n" +
  6184. "File inputs are read only. Use a v-on:change listener instead."
  6185. );
  6186. }
  6187. }
  6188. if (tag === 'select') {
  6189. genSelect(el, value, modifiers);
  6190. } else if (tag === 'input' && type === 'checkbox') {
  6191. genCheckboxModel(el, value, modifiers);
  6192. } else if (tag === 'input' && type === 'radio') {
  6193. genRadioModel(el, value, modifiers);
  6194. } else if (tag === 'input' || tag === 'textarea') {
  6195. genDefaultModel(el, value, modifiers);
  6196. } else if (!config.isReservedTag(tag)) {
  6197. genComponentModel(el, value, modifiers);
  6198. // component v-model doesn't need extra runtime
  6199. return false
  6200. } else if (process.env.NODE_ENV !== 'production') {
  6201. warn$1(
  6202. "<" + (el.tag) + " v-model=\"" + value + "\">: " +
  6203. "v-model is not supported on this element type. " +
  6204. 'If you are working with contenteditable, it\'s recommended to ' +
  6205. 'wrap a library dedicated for that purpose inside a custom component.'
  6206. );
  6207. }
  6208. // ensure runtime directive metadata
  6209. return true
  6210. }
  6211. function genCheckboxModel (
  6212. el,
  6213. value,
  6214. modifiers
  6215. ) {
  6216. var number = modifiers && modifiers.number;
  6217. var valueBinding = getBindingAttr(el, 'value') || 'null';
  6218. var trueValueBinding = getBindingAttr(el, 'true-value') || 'true';
  6219. var falseValueBinding = getBindingAttr(el, 'false-value') || 'false';
  6220. addProp(el, 'checked',
  6221. "Array.isArray(" + value + ")" +
  6222. "?_i(" + value + "," + valueBinding + ")>-1" + (
  6223. trueValueBinding === 'true'
  6224. ? (":(" + value + ")")
  6225. : (":_q(" + value + "," + trueValueBinding + ")")
  6226. )
  6227. );
  6228. addHandler(el, CHECKBOX_RADIO_TOKEN,
  6229. "var $$a=" + value + "," +
  6230. '$$el=$event.target,' +
  6231. "$$c=$$el.checked?(" + trueValueBinding + "):(" + falseValueBinding + ");" +
  6232. 'if(Array.isArray($$a)){' +
  6233. "var $$v=" + (number ? '_n(' + valueBinding + ')' : valueBinding) + "," +
  6234. '$$i=_i($$a,$$v);' +
  6235. "if($$c){$$i<0&&(" + value + "=$$a.concat($$v))}" +
  6236. "else{$$i>-1&&(" + value + "=$$a.slice(0,$$i).concat($$a.slice($$i+1)))}" +
  6237. "}else{" + (genAssignmentCode(value, '$$c')) + "}",
  6238. null, true
  6239. );
  6240. }
  6241. function genRadioModel (
  6242. el,
  6243. value,
  6244. modifiers
  6245. ) {
  6246. var number = modifiers && modifiers.number;
  6247. var valueBinding = getBindingAttr(el, 'value') || 'null';
  6248. valueBinding = number ? ("_n(" + valueBinding + ")") : valueBinding;
  6249. addProp(el, 'checked', ("_q(" + value + "," + valueBinding + ")"));
  6250. addHandler(el, CHECKBOX_RADIO_TOKEN, genAssignmentCode(value, valueBinding), null, true);
  6251. }
  6252. function genSelect (
  6253. el,
  6254. value,
  6255. modifiers
  6256. ) {
  6257. var number = modifiers && modifiers.number;
  6258. var selectedVal = "Array.prototype.filter" +
  6259. ".call($event.target.options,function(o){return o.selected})" +
  6260. ".map(function(o){var val = \"_value\" in o ? o._value : o.value;" +
  6261. "return " + (number ? '_n(val)' : 'val') + "})";
  6262. var assignment = '$event.target.multiple ? $$selectedVal : $$selectedVal[0]';
  6263. var code = "var $$selectedVal = " + selectedVal + ";";
  6264. code = code + " " + (genAssignmentCode(value, assignment));
  6265. addHandler(el, 'change', code, null, true);
  6266. }
  6267. function genDefaultModel (
  6268. el,
  6269. value,
  6270. modifiers
  6271. ) {
  6272. var type = el.attrsMap.type;
  6273. var ref = modifiers || {};
  6274. var lazy = ref.lazy;
  6275. var number = ref.number;
  6276. var trim = ref.trim;
  6277. var needCompositionGuard = !lazy && type !== 'range';
  6278. var event = lazy
  6279. ? 'change'
  6280. : type === 'range'
  6281. ? RANGE_TOKEN
  6282. : 'input';
  6283. var valueExpression = '$event.target.value';
  6284. if (trim) {
  6285. valueExpression = "$event.target.value.trim()";
  6286. }
  6287. if (number) {
  6288. valueExpression = "_n(" + valueExpression + ")";
  6289. }
  6290. var code = genAssignmentCode(value, valueExpression);
  6291. if (needCompositionGuard) {
  6292. code = "if($event.target.composing)return;" + code;
  6293. }
  6294. addProp(el, 'value', ("(" + value + ")"));
  6295. addHandler(el, event, code, null, true);
  6296. if (trim || number || type === 'number') {
  6297. addHandler(el, 'blur', '$forceUpdate()');
  6298. }
  6299. }
  6300. /* */
  6301. // normalize v-model event tokens that can only be determined at runtime.
  6302. // it's important to place the event as the first in the array because
  6303. // the whole point is ensuring the v-model callback gets called before
  6304. // user-attached handlers.
  6305. function normalizeEvents (on) {
  6306. var event;
  6307. /* istanbul ignore if */
  6308. if (isDef(on[RANGE_TOKEN])) {
  6309. // IE input[type=range] only supports `change` event
  6310. event = isIE ? 'change' : 'input';
  6311. on[event] = [].concat(on[RANGE_TOKEN], on[event] || []);
  6312. delete on[RANGE_TOKEN];
  6313. }
  6314. if (isDef(on[CHECKBOX_RADIO_TOKEN])) {
  6315. // Chrome fires microtasks in between click/change, leads to #4521
  6316. event = isChrome ? 'click' : 'change';
  6317. on[event] = [].concat(on[CHECKBOX_RADIO_TOKEN], on[event] || []);
  6318. delete on[CHECKBOX_RADIO_TOKEN];
  6319. }
  6320. }
  6321. var target$1;
  6322. function add$1 (
  6323. event,
  6324. handler,
  6325. once$$1,
  6326. capture,
  6327. passive
  6328. ) {
  6329. if (once$$1) {
  6330. var oldHandler = handler;
  6331. var _target = target$1; // save current target element in closure
  6332. handler = function (ev) {
  6333. var res = arguments.length === 1
  6334. ? oldHandler(ev)
  6335. : oldHandler.apply(null, arguments);
  6336. if (res !== null) {
  6337. remove$2(event, handler, capture, _target);
  6338. }
  6339. };
  6340. }
  6341. target$1.addEventListener(
  6342. event,
  6343. handler,
  6344. supportsPassive
  6345. ? { capture: capture, passive: passive }
  6346. : capture
  6347. );
  6348. }
  6349. function remove$2 (
  6350. event,
  6351. handler,
  6352. capture,
  6353. _target
  6354. ) {
  6355. (_target || target$1).removeEventListener(event, handler, capture);
  6356. }
  6357. function updateDOMListeners (oldVnode, vnode) {
  6358. if (isUndef(oldVnode.data.on) && isUndef(vnode.data.on)) {
  6359. return
  6360. }
  6361. var on = vnode.data.on || {};
  6362. var oldOn = oldVnode.data.on || {};
  6363. target$1 = vnode.elm;
  6364. normalizeEvents(on);
  6365. updateListeners(on, oldOn, add$1, remove$2, vnode.context);
  6366. }
  6367. var events = {
  6368. create: updateDOMListeners,
  6369. update: updateDOMListeners
  6370. };
  6371. /* */
  6372. function updateDOMProps (oldVnode, vnode) {
  6373. if (isUndef(oldVnode.data.domProps) && isUndef(vnode.data.domProps)) {
  6374. return
  6375. }
  6376. var key, cur;
  6377. var elm = vnode.elm;
  6378. var oldProps = oldVnode.data.domProps || {};
  6379. var props = vnode.data.domProps || {};
  6380. // clone observed objects, as the user probably wants to mutate it
  6381. if (isDef(props.__ob__)) {
  6382. props = vnode.data.domProps = extend({}, props);
  6383. }
  6384. for (key in oldProps) {
  6385. if (isUndef(props[key])) {
  6386. elm[key] = '';
  6387. }
  6388. }
  6389. for (key in props) {
  6390. cur = props[key];
  6391. // ignore children if the node has textContent or innerHTML,
  6392. // as these will throw away existing DOM nodes and cause removal errors
  6393. // on subsequent patches (#3360)
  6394. if (key === 'textContent' || key === 'innerHTML') {
  6395. if (vnode.children) { vnode.children.length = 0; }
  6396. if (cur === oldProps[key]) { continue }
  6397. }
  6398. if (key === 'value') {
  6399. // store value as _value as well since
  6400. // non-string values will be stringified
  6401. elm._value = cur;
  6402. // avoid resetting cursor position when value is the same
  6403. var strCur = isUndef(cur) ? '' : String(cur);
  6404. if (shouldUpdateValue(elm, vnode, strCur)) {
  6405. elm.value = strCur;
  6406. }
  6407. } else {
  6408. elm[key] = cur;
  6409. }
  6410. }
  6411. }
  6412. // check platforms/web/util/attrs.js acceptValue
  6413. function shouldUpdateValue (
  6414. elm,
  6415. vnode,
  6416. checkVal
  6417. ) {
  6418. return (!elm.composing && (
  6419. vnode.tag === 'option' ||
  6420. isDirty(elm, checkVal) ||
  6421. isInputChanged(elm, checkVal)
  6422. ))
  6423. }
  6424. function isDirty (elm, checkVal) {
  6425. // return true when textbox (.number and .trim) loses focus and its value is not equal to the updated value
  6426. return document.activeElement !== elm && elm.value !== checkVal
  6427. }
  6428. function isInputChanged (elm, newVal) {
  6429. var value = elm.value;
  6430. var modifiers = elm._vModifiers; // injected by v-model runtime
  6431. if ((isDef(modifiers) && modifiers.number) || elm.type === 'number') {
  6432. return toNumber(value) !== toNumber(newVal)
  6433. }
  6434. if (isDef(modifiers) && modifiers.trim) {
  6435. return value.trim() !== newVal.trim()
  6436. }
  6437. return value !== newVal
  6438. }
  6439. var domProps = {
  6440. create: updateDOMProps,
  6441. update: updateDOMProps
  6442. };
  6443. /* */
  6444. var parseStyleText = cached(function (cssText) {
  6445. var res = {};
  6446. var listDelimiter = /;(?![^(]*\))/g;
  6447. var propertyDelimiter = /:(.+)/;
  6448. cssText.split(listDelimiter).forEach(function (item) {
  6449. if (item) {
  6450. var tmp = item.split(propertyDelimiter);
  6451. tmp.length > 1 && (res[tmp[0].trim()] = tmp[1].trim());
  6452. }
  6453. });
  6454. return res
  6455. });
  6456. // merge static and dynamic style data on the same vnode
  6457. function normalizeStyleData (data) {
  6458. var style = normalizeStyleBinding(data.style);
  6459. // static style is pre-processed into an object during compilation
  6460. // and is always a fresh object, so it's safe to merge into it
  6461. return data.staticStyle
  6462. ? extend(data.staticStyle, style)
  6463. : style
  6464. }
  6465. // normalize possible array / string values into Object
  6466. function normalizeStyleBinding (bindingStyle) {
  6467. if (Array.isArray(bindingStyle)) {
  6468. return toObject(bindingStyle)
  6469. }
  6470. if (typeof bindingStyle === 'string') {
  6471. return parseStyleText(bindingStyle)
  6472. }
  6473. return bindingStyle
  6474. }
  6475. /**
  6476. * parent component style should be after child's
  6477. * so that parent component's style could override it
  6478. */
  6479. function getStyle (vnode, checkChild) {
  6480. var res = {};
  6481. var styleData;
  6482. if (checkChild) {
  6483. var childNode = vnode;
  6484. while (childNode.componentInstance) {
  6485. childNode = childNode.componentInstance._vnode;
  6486. if (childNode.data && (styleData = normalizeStyleData(childNode.data))) {
  6487. extend(res, styleData);
  6488. }
  6489. }
  6490. }
  6491. if ((styleData = normalizeStyleData(vnode.data))) {
  6492. extend(res, styleData);
  6493. }
  6494. var parentNode = vnode;
  6495. while ((parentNode = parentNode.parent)) {
  6496. if (parentNode.data && (styleData = normalizeStyleData(parentNode.data))) {
  6497. extend(res, styleData);
  6498. }
  6499. }
  6500. return res
  6501. }
  6502. /* */
  6503. var cssVarRE = /^--/;
  6504. var importantRE = /\s*!important$/;
  6505. var setProp = function (el, name, val) {
  6506. /* istanbul ignore if */
  6507. if (cssVarRE.test(name)) {
  6508. el.style.setProperty(name, val);
  6509. } else if (importantRE.test(val)) {
  6510. el.style.setProperty(name, val.replace(importantRE, ''), 'important');
  6511. } else {
  6512. var normalizedName = normalize(name);
  6513. if (Array.isArray(val)) {
  6514. // Support values array created by autoprefixer, e.g.
  6515. // {display: ["-webkit-box", "-ms-flexbox", "flex"]}
  6516. // Set them one by one, and the browser will only set those it can recognize
  6517. for (var i = 0, len = val.length; i < len; i++) {
  6518. el.style[normalizedName] = val[i];
  6519. }
  6520. } else {
  6521. el.style[normalizedName] = val;
  6522. }
  6523. }
  6524. };
  6525. var prefixes = ['Webkit', 'Moz', 'ms'];
  6526. var testEl;
  6527. var normalize = cached(function (prop) {
  6528. testEl = testEl || document.createElement('div');
  6529. prop = camelize(prop);
  6530. if (prop !== 'filter' && (prop in testEl.style)) {
  6531. return prop
  6532. }
  6533. var upper = prop.charAt(0).toUpperCase() + prop.slice(1);
  6534. for (var i = 0; i < prefixes.length; i++) {
  6535. var prefixed = prefixes[i] + upper;
  6536. if (prefixed in testEl.style) {
  6537. return prefixed
  6538. }
  6539. }
  6540. });
  6541. function updateStyle (oldVnode, vnode) {
  6542. var data = vnode.data;
  6543. var oldData = oldVnode.data;
  6544. if (isUndef(data.staticStyle) && isUndef(data.style) &&
  6545. isUndef(oldData.staticStyle) && isUndef(oldData.style)
  6546. ) {
  6547. return
  6548. }
  6549. var cur, name;
  6550. var el = vnode.elm;
  6551. var oldStaticStyle = oldData.staticStyle;
  6552. var oldStyleBinding = oldData.normalizedStyle || oldData.style || {};
  6553. // if static style exists, stylebinding already merged into it when doing normalizeStyleData
  6554. var oldStyle = oldStaticStyle || oldStyleBinding;
  6555. var style = normalizeStyleBinding(vnode.data.style) || {};
  6556. // store normalized style under a different key for next diff
  6557. // make sure to clone it if it's reactive, since the user likley wants
  6558. // to mutate it.
  6559. vnode.data.normalizedStyle = isDef(style.__ob__)
  6560. ? extend({}, style)
  6561. : style;
  6562. var newStyle = getStyle(vnode, true);
  6563. for (name in oldStyle) {
  6564. if (isUndef(newStyle[name])) {
  6565. setProp(el, name, '');
  6566. }
  6567. }
  6568. for (name in newStyle) {
  6569. cur = newStyle[name];
  6570. if (cur !== oldStyle[name]) {
  6571. // ie9 setting to null has no effect, must use empty string
  6572. setProp(el, name, cur == null ? '' : cur);
  6573. }
  6574. }
  6575. }
  6576. var style = {
  6577. create: updateStyle,
  6578. update: updateStyle
  6579. };
  6580. /* */
  6581. /**
  6582. * Add class with compatibility for SVG since classList is not supported on
  6583. * SVG elements in IE
  6584. */
  6585. function addClass (el, cls) {
  6586. /* istanbul ignore if */
  6587. if (!cls || !(cls = cls.trim())) {
  6588. return
  6589. }
  6590. /* istanbul ignore else */
  6591. if (el.classList) {
  6592. if (cls.indexOf(' ') > -1) {
  6593. cls.split(/\s+/).forEach(function (c) { return el.classList.add(c); });
  6594. } else {
  6595. el.classList.add(cls);
  6596. }
  6597. } else {
  6598. var cur = " " + (el.getAttribute('class') || '') + " ";
  6599. if (cur.indexOf(' ' + cls + ' ') < 0) {
  6600. el.setAttribute('class', (cur + cls).trim());
  6601. }
  6602. }
  6603. }
  6604. /**
  6605. * Remove class with compatibility for SVG since classList is not supported on
  6606. * SVG elements in IE
  6607. */
  6608. function removeClass (el, cls) {
  6609. /* istanbul ignore if */
  6610. if (!cls || !(cls = cls.trim())) {
  6611. return
  6612. }
  6613. /* istanbul ignore else */
  6614. if (el.classList) {
  6615. if (cls.indexOf(' ') > -1) {
  6616. cls.split(/\s+/).forEach(function (c) { return el.classList.remove(c); });
  6617. } else {
  6618. el.classList.remove(cls);
  6619. }
  6620. } else {
  6621. var cur = " " + (el.getAttribute('class') || '') + " ";
  6622. var tar = ' ' + cls + ' ';
  6623. while (cur.indexOf(tar) >= 0) {
  6624. cur = cur.replace(tar, ' ');
  6625. }
  6626. el.setAttribute('class', cur.trim());
  6627. }
  6628. }
  6629. /* */
  6630. function resolveTransition (def$$1) {
  6631. if (!def$$1) {
  6632. return
  6633. }
  6634. /* istanbul ignore else */
  6635. if (typeof def$$1 === 'object') {
  6636. var res = {};
  6637. if (def$$1.css !== false) {
  6638. extend(res, autoCssTransition(def$$1.name || 'v'));
  6639. }
  6640. extend(res, def$$1);
  6641. return res
  6642. } else if (typeof def$$1 === 'string') {
  6643. return autoCssTransition(def$$1)
  6644. }
  6645. }
  6646. var autoCssTransition = cached(function (name) {
  6647. return {
  6648. enterClass: (name + "-enter"),
  6649. enterToClass: (name + "-enter-to"),
  6650. enterActiveClass: (name + "-enter-active"),
  6651. leaveClass: (name + "-leave"),
  6652. leaveToClass: (name + "-leave-to"),
  6653. leaveActiveClass: (name + "-leave-active")
  6654. }
  6655. });
  6656. var hasTransition = inBrowser && !isIE9;
  6657. var TRANSITION = 'transition';
  6658. var ANIMATION = 'animation';
  6659. // Transition property/event sniffing
  6660. var transitionProp = 'transition';
  6661. var transitionEndEvent = 'transitionend';
  6662. var animationProp = 'animation';
  6663. var animationEndEvent = 'animationend';
  6664. if (hasTransition) {
  6665. /* istanbul ignore if */
  6666. if (window.ontransitionend === undefined &&
  6667. window.onwebkittransitionend !== undefined
  6668. ) {
  6669. transitionProp = 'WebkitTransition';
  6670. transitionEndEvent = 'webkitTransitionEnd';
  6671. }
  6672. if (window.onanimationend === undefined &&
  6673. window.onwebkitanimationend !== undefined
  6674. ) {
  6675. animationProp = 'WebkitAnimation';
  6676. animationEndEvent = 'webkitAnimationEnd';
  6677. }
  6678. }
  6679. // binding to window is necessary to make hot reload work in IE in strict mode
  6680. var raf = inBrowser && window.requestAnimationFrame
  6681. ? window.requestAnimationFrame.bind(window)
  6682. : setTimeout;
  6683. function nextFrame (fn) {
  6684. raf(function () {
  6685. raf(fn);
  6686. });
  6687. }
  6688. function addTransitionClass (el, cls) {
  6689. (el._transitionClasses || (el._transitionClasses = [])).push(cls);
  6690. addClass(el, cls);
  6691. }
  6692. function removeTransitionClass (el, cls) {
  6693. if (el._transitionClasses) {
  6694. remove(el._transitionClasses, cls);
  6695. }
  6696. removeClass(el, cls);
  6697. }
  6698. function whenTransitionEnds (
  6699. el,
  6700. expectedType,
  6701. cb
  6702. ) {
  6703. var ref = getTransitionInfo(el, expectedType);
  6704. var type = ref.type;
  6705. var timeout = ref.timeout;
  6706. var propCount = ref.propCount;
  6707. if (!type) { return cb() }
  6708. var event = type === TRANSITION ? transitionEndEvent : animationEndEvent;
  6709. var ended = 0;
  6710. var end = function () {
  6711. el.removeEventListener(event, onEnd);
  6712. cb();
  6713. };
  6714. var onEnd = function (e) {
  6715. if (e.target === el) {
  6716. if (++ended >= propCount) {
  6717. end();
  6718. }
  6719. }
  6720. };
  6721. setTimeout(function () {
  6722. if (ended < propCount) {
  6723. end();
  6724. }
  6725. }, timeout + 1);
  6726. el.addEventListener(event, onEnd);
  6727. }
  6728. var transformRE = /\b(transform|all)(,|$)/;
  6729. function getTransitionInfo (el, expectedType) {
  6730. var styles = window.getComputedStyle(el);
  6731. var transitionDelays = styles[transitionProp + 'Delay'].split(', ');
  6732. var transitionDurations = styles[transitionProp + 'Duration'].split(', ');
  6733. var transitionTimeout = getTimeout(transitionDelays, transitionDurations);
  6734. var animationDelays = styles[animationProp + 'Delay'].split(', ');
  6735. var animationDurations = styles[animationProp + 'Duration'].split(', ');
  6736. var animationTimeout = getTimeout(animationDelays, animationDurations);
  6737. var type;
  6738. var timeout = 0;
  6739. var propCount = 0;
  6740. /* istanbul ignore if */
  6741. if (expectedType === TRANSITION) {
  6742. if (transitionTimeout > 0) {
  6743. type = TRANSITION;
  6744. timeout = transitionTimeout;
  6745. propCount = transitionDurations.length;
  6746. }
  6747. } else if (expectedType === ANIMATION) {
  6748. if (animationTimeout > 0) {
  6749. type = ANIMATION;
  6750. timeout = animationTimeout;
  6751. propCount = animationDurations.length;
  6752. }
  6753. } else {
  6754. timeout = Math.max(transitionTimeout, animationTimeout);
  6755. type = timeout > 0
  6756. ? transitionTimeout > animationTimeout
  6757. ? TRANSITION
  6758. : ANIMATION
  6759. : null;
  6760. propCount = type
  6761. ? type === TRANSITION
  6762. ? transitionDurations.length
  6763. : animationDurations.length
  6764. : 0;
  6765. }
  6766. var hasTransform =
  6767. type === TRANSITION &&
  6768. transformRE.test(styles[transitionProp + 'Property']);
  6769. return {
  6770. type: type,
  6771. timeout: timeout,
  6772. propCount: propCount,
  6773. hasTransform: hasTransform
  6774. }
  6775. }
  6776. function getTimeout (delays, durations) {
  6777. /* istanbul ignore next */
  6778. while (delays.length < durations.length) {
  6779. delays = delays.concat(delays);
  6780. }
  6781. return Math.max.apply(null, durations.map(function (d, i) {
  6782. return toMs(d) + toMs(delays[i])
  6783. }))
  6784. }
  6785. function toMs (s) {
  6786. return Number(s.slice(0, -1)) * 1000
  6787. }
  6788. /* */
  6789. function enter (vnode, toggleDisplay) {
  6790. var el = vnode.elm;
  6791. // call leave callback now
  6792. if (isDef(el._leaveCb)) {
  6793. el._leaveCb.cancelled = true;
  6794. el._leaveCb();
  6795. }
  6796. var data = resolveTransition(vnode.data.transition);
  6797. if (isUndef(data)) {
  6798. return
  6799. }
  6800. /* istanbul ignore if */
  6801. if (isDef(el._enterCb) || el.nodeType !== 1) {
  6802. return
  6803. }
  6804. var css = data.css;
  6805. var type = data.type;
  6806. var enterClass = data.enterClass;
  6807. var enterToClass = data.enterToClass;
  6808. var enterActiveClass = data.enterActiveClass;
  6809. var appearClass = data.appearClass;
  6810. var appearToClass = data.appearToClass;
  6811. var appearActiveClass = data.appearActiveClass;
  6812. var beforeEnter = data.beforeEnter;
  6813. var enter = data.enter;
  6814. var afterEnter = data.afterEnter;
  6815. var enterCancelled = data.enterCancelled;
  6816. var beforeAppear = data.beforeAppear;
  6817. var appear = data.appear;
  6818. var afterAppear = data.afterAppear;
  6819. var appearCancelled = data.appearCancelled;
  6820. var duration = data.duration;
  6821. // activeInstance will always be the <transition> component managing this
  6822. // transition. One edge case to check is when the <transition> is placed
  6823. // as the root node of a child component. In that case we need to check
  6824. // <transition>'s parent for appear check.
  6825. var context = activeInstance;
  6826. var transitionNode = activeInstance.$vnode;
  6827. while (transitionNode && transitionNode.parent) {
  6828. transitionNode = transitionNode.parent;
  6829. context = transitionNode.context;
  6830. }
  6831. var isAppear = !context._isMounted || !vnode.isRootInsert;
  6832. if (isAppear && !appear && appear !== '') {
  6833. return
  6834. }
  6835. var startClass = isAppear && appearClass
  6836. ? appearClass
  6837. : enterClass;
  6838. var activeClass = isAppear && appearActiveClass
  6839. ? appearActiveClass
  6840. : enterActiveClass;
  6841. var toClass = isAppear && appearToClass
  6842. ? appearToClass
  6843. : enterToClass;
  6844. var beforeEnterHook = isAppear
  6845. ? (beforeAppear || beforeEnter)
  6846. : beforeEnter;
  6847. var enterHook = isAppear
  6848. ? (typeof appear === 'function' ? appear : enter)
  6849. : enter;
  6850. var afterEnterHook = isAppear
  6851. ? (afterAppear || afterEnter)
  6852. : afterEnter;
  6853. var enterCancelledHook = isAppear
  6854. ? (appearCancelled || enterCancelled)
  6855. : enterCancelled;
  6856. var explicitEnterDuration = toNumber(
  6857. isObject(duration)
  6858. ? duration.enter
  6859. : duration
  6860. );
  6861. if (process.env.NODE_ENV !== 'production' && explicitEnterDuration != null) {
  6862. checkDuration(explicitEnterDuration, 'enter', vnode);
  6863. }
  6864. var expectsCSS = css !== false && !isIE9;
  6865. var userWantsControl = getHookArgumentsLength(enterHook);
  6866. var cb = el._enterCb = once(function () {
  6867. if (expectsCSS) {
  6868. removeTransitionClass(el, toClass);
  6869. removeTransitionClass(el, activeClass);
  6870. }
  6871. if (cb.cancelled) {
  6872. if (expectsCSS) {
  6873. removeTransitionClass(el, startClass);
  6874. }
  6875. enterCancelledHook && enterCancelledHook(el);
  6876. } else {
  6877. afterEnterHook && afterEnterHook(el);
  6878. }
  6879. el._enterCb = null;
  6880. });
  6881. if (!vnode.data.show) {
  6882. // remove pending leave element on enter by injecting an insert hook
  6883. mergeVNodeHook(vnode.data.hook || (vnode.data.hook = {}), 'insert', function () {
  6884. var parent = el.parentNode;
  6885. var pendingNode = parent && parent._pending && parent._pending[vnode.key];
  6886. if (pendingNode &&
  6887. pendingNode.tag === vnode.tag &&
  6888. pendingNode.elm._leaveCb
  6889. ) {
  6890. pendingNode.elm._leaveCb();
  6891. }
  6892. enterHook && enterHook(el, cb);
  6893. });
  6894. }
  6895. // start enter transition
  6896. beforeEnterHook && beforeEnterHook(el);
  6897. if (expectsCSS) {
  6898. addTransitionClass(el, startClass);
  6899. addTransitionClass(el, activeClass);
  6900. nextFrame(function () {
  6901. addTransitionClass(el, toClass);
  6902. removeTransitionClass(el, startClass);
  6903. if (!cb.cancelled && !userWantsControl) {
  6904. if (isValidDuration(explicitEnterDuration)) {
  6905. setTimeout(cb, explicitEnterDuration);
  6906. } else {
  6907. whenTransitionEnds(el, type, cb);
  6908. }
  6909. }
  6910. });
  6911. }
  6912. if (vnode.data.show) {
  6913. toggleDisplay && toggleDisplay();
  6914. enterHook && enterHook(el, cb);
  6915. }
  6916. if (!expectsCSS && !userWantsControl) {
  6917. cb();
  6918. }
  6919. }
  6920. function leave (vnode, rm) {
  6921. var el = vnode.elm;
  6922. // call enter callback now
  6923. if (isDef(el._enterCb)) {
  6924. el._enterCb.cancelled = true;
  6925. el._enterCb();
  6926. }
  6927. var data = resolveTransition(vnode.data.transition);
  6928. if (isUndef(data)) {
  6929. return rm()
  6930. }
  6931. /* istanbul ignore if */
  6932. if (isDef(el._leaveCb) || el.nodeType !== 1) {
  6933. return
  6934. }
  6935. var css = data.css;
  6936. var type = data.type;
  6937. var leaveClass = data.leaveClass;
  6938. var leaveToClass = data.leaveToClass;
  6939. var leaveActiveClass = data.leaveActiveClass;
  6940. var beforeLeave = data.beforeLeave;
  6941. var leave = data.leave;
  6942. var afterLeave = data.afterLeave;
  6943. var leaveCancelled = data.leaveCancelled;
  6944. var delayLeave = data.delayLeave;
  6945. var duration = data.duration;
  6946. var expectsCSS = css !== false && !isIE9;
  6947. var userWantsControl = getHookArgumentsLength(leave);
  6948. var explicitLeaveDuration = toNumber(
  6949. isObject(duration)
  6950. ? duration.leave
  6951. : duration
  6952. );
  6953. if (process.env.NODE_ENV !== 'production' && isDef(explicitLeaveDuration)) {
  6954. checkDuration(explicitLeaveDuration, 'leave', vnode);
  6955. }
  6956. var cb = el._leaveCb = once(function () {
  6957. if (el.parentNode && el.parentNode._pending) {
  6958. el.parentNode._pending[vnode.key] = null;
  6959. }
  6960. if (expectsCSS) {
  6961. removeTransitionClass(el, leaveToClass);
  6962. removeTransitionClass(el, leaveActiveClass);
  6963. }
  6964. if (cb.cancelled) {
  6965. if (expectsCSS) {
  6966. removeTransitionClass(el, leaveClass);
  6967. }
  6968. leaveCancelled && leaveCancelled(el);
  6969. } else {
  6970. rm();
  6971. afterLeave && afterLeave(el);
  6972. }
  6973. el._leaveCb = null;
  6974. });
  6975. if (delayLeave) {
  6976. delayLeave(performLeave);
  6977. } else {
  6978. performLeave();
  6979. }
  6980. function performLeave () {
  6981. // the delayed leave may have already been cancelled
  6982. if (cb.cancelled) {
  6983. return
  6984. }
  6985. // record leaving element
  6986. if (!vnode.data.show) {
  6987. (el.parentNode._pending || (el.parentNode._pending = {}))[(vnode.key)] = vnode;
  6988. }
  6989. beforeLeave && beforeLeave(el);
  6990. if (expectsCSS) {
  6991. addTransitionClass(el, leaveClass);
  6992. addTransitionClass(el, leaveActiveClass);
  6993. nextFrame(function () {
  6994. addTransitionClass(el, leaveToClass);
  6995. removeTransitionClass(el, leaveClass);
  6996. if (!cb.cancelled && !userWantsControl) {
  6997. if (isValidDuration(explicitLeaveDuration)) {
  6998. setTimeout(cb, explicitLeaveDuration);
  6999. } else {
  7000. whenTransitionEnds(el, type, cb);
  7001. }
  7002. }
  7003. });
  7004. }
  7005. leave && leave(el, cb);
  7006. if (!expectsCSS && !userWantsControl) {
  7007. cb();
  7008. }
  7009. }
  7010. }
  7011. // only used in dev mode
  7012. function checkDuration (val, name, vnode) {
  7013. if (typeof val !== 'number') {
  7014. warn(
  7015. "<transition> explicit " + name + " duration is not a valid number - " +
  7016. "got " + (JSON.stringify(val)) + ".",
  7017. vnode.context
  7018. );
  7019. } else if (isNaN(val)) {
  7020. warn(
  7021. "<transition> explicit " + name + " duration is NaN - " +
  7022. 'the duration expression might be incorrect.',
  7023. vnode.context
  7024. );
  7025. }
  7026. }
  7027. function isValidDuration (val) {
  7028. return typeof val === 'number' && !isNaN(val)
  7029. }
  7030. /**
  7031. * Normalize a transition hook's argument length. The hook may be:
  7032. * - a merged hook (invoker) with the original in .fns
  7033. * - a wrapped component method (check ._length)
  7034. * - a plain function (.length)
  7035. */
  7036. function getHookArgumentsLength (fn) {
  7037. if (isUndef(fn)) {
  7038. return false
  7039. }
  7040. var invokerFns = fn.fns;
  7041. if (isDef(invokerFns)) {
  7042. // invoker
  7043. return getHookArgumentsLength(
  7044. Array.isArray(invokerFns)
  7045. ? invokerFns[0]
  7046. : invokerFns
  7047. )
  7048. } else {
  7049. return (fn._length || fn.length) > 1
  7050. }
  7051. }
  7052. function _enter (_, vnode) {
  7053. if (vnode.data.show !== true) {
  7054. enter(vnode);
  7055. }
  7056. }
  7057. var transition = inBrowser ? {
  7058. create: _enter,
  7059. activate: _enter,
  7060. remove: function remove$$1 (vnode, rm) {
  7061. /* istanbul ignore else */
  7062. if (vnode.data.show !== true) {
  7063. leave(vnode, rm);
  7064. } else {
  7065. rm();
  7066. }
  7067. }
  7068. } : {};
  7069. var platformModules = [
  7070. attrs,
  7071. klass,
  7072. events,
  7073. domProps,
  7074. style,
  7075. transition
  7076. ];
  7077. /* */
  7078. // the directive module should be applied last, after all
  7079. // built-in modules have been applied.
  7080. var modules = platformModules.concat(baseModules);
  7081. var patch = createPatchFunction({ nodeOps: nodeOps, modules: modules });
  7082. /**
  7083. * Not type checking this file because flow doesn't like attaching
  7084. * properties to Elements.
  7085. */
  7086. /* istanbul ignore if */
  7087. if (isIE9) {
  7088. // http://www.matts411.com/post/internet-explorer-9-oninput/
  7089. document.addEventListener('selectionchange', function () {
  7090. var el = document.activeElement;
  7091. if (el && el.vmodel) {
  7092. trigger(el, 'input');
  7093. }
  7094. });
  7095. }
  7096. var model$1 = {
  7097. inserted: function inserted (el, binding, vnode) {
  7098. if (vnode.tag === 'select') {
  7099. var cb = function () {
  7100. setSelected(el, binding, vnode.context);
  7101. };
  7102. cb();
  7103. /* istanbul ignore if */
  7104. if (isIE || isEdge) {
  7105. setTimeout(cb, 0);
  7106. }
  7107. } else if (vnode.tag === 'textarea' || el.type === 'text' || el.type === 'password') {
  7108. el._vModifiers = binding.modifiers;
  7109. if (!binding.modifiers.lazy) {
  7110. // Safari < 10.2 & UIWebView doesn't fire compositionend when
  7111. // switching focus before confirming composition choice
  7112. // this also fixes the issue where some browsers e.g. iOS Chrome
  7113. // fires "change" instead of "input" on autocomplete.
  7114. el.addEventListener('change', onCompositionEnd);
  7115. if (!isAndroid) {
  7116. el.addEventListener('compositionstart', onCompositionStart);
  7117. el.addEventListener('compositionend', onCompositionEnd);
  7118. }
  7119. /* istanbul ignore if */
  7120. if (isIE9) {
  7121. el.vmodel = true;
  7122. }
  7123. }
  7124. }
  7125. },
  7126. componentUpdated: function componentUpdated (el, binding, vnode) {
  7127. if (vnode.tag === 'select') {
  7128. setSelected(el, binding, vnode.context);
  7129. // in case the options rendered by v-for have changed,
  7130. // it's possible that the value is out-of-sync with the rendered options.
  7131. // detect such cases and filter out values that no longer has a matching
  7132. // option in the DOM.
  7133. var needReset = el.multiple
  7134. ? binding.value.some(function (v) { return hasNoMatchingOption(v, el.options); })
  7135. : binding.value !== binding.oldValue && hasNoMatchingOption(binding.value, el.options);
  7136. if (needReset) {
  7137. trigger(el, 'change');
  7138. }
  7139. }
  7140. }
  7141. };
  7142. function setSelected (el, binding, vm) {
  7143. var value = binding.value;
  7144. var isMultiple = el.multiple;
  7145. if (isMultiple && !Array.isArray(value)) {
  7146. process.env.NODE_ENV !== 'production' && warn(
  7147. "<select multiple v-model=\"" + (binding.expression) + "\"> " +
  7148. "expects an Array value for its binding, but got " + (Object.prototype.toString.call(value).slice(8, -1)),
  7149. vm
  7150. );
  7151. return
  7152. }
  7153. var selected, option;
  7154. for (var i = 0, l = el.options.length; i < l; i++) {
  7155. option = el.options[i];
  7156. if (isMultiple) {
  7157. selected = looseIndexOf(value, getValue(option)) > -1;
  7158. if (option.selected !== selected) {
  7159. option.selected = selected;
  7160. }
  7161. } else {
  7162. if (looseEqual(getValue(option), value)) {
  7163. if (el.selectedIndex !== i) {
  7164. el.selectedIndex = i;
  7165. }
  7166. return
  7167. }
  7168. }
  7169. }
  7170. if (!isMultiple) {
  7171. el.selectedIndex = -1;
  7172. }
  7173. }
  7174. function hasNoMatchingOption (value, options) {
  7175. for (var i = 0, l = options.length; i < l; i++) {
  7176. if (looseEqual(getValue(options[i]), value)) {
  7177. return false
  7178. }
  7179. }
  7180. return true
  7181. }
  7182. function getValue (option) {
  7183. return '_value' in option
  7184. ? option._value
  7185. : option.value
  7186. }
  7187. function onCompositionStart (e) {
  7188. e.target.composing = true;
  7189. }
  7190. function onCompositionEnd (e) {
  7191. // prevent triggering an input event for no reason
  7192. if (!e.target.composing) { return }
  7193. e.target.composing = false;
  7194. trigger(e.target, 'input');
  7195. }
  7196. function trigger (el, type) {
  7197. var e = document.createEvent('HTMLEvents');
  7198. e.initEvent(type, true, true);
  7199. el.dispatchEvent(e);
  7200. }
  7201. /* */
  7202. // recursively search for possible transition defined inside the component root
  7203. function locateNode (vnode) {
  7204. return vnode.componentInstance && (!vnode.data || !vnode.data.transition)
  7205. ? locateNode(vnode.componentInstance._vnode)
  7206. : vnode
  7207. }
  7208. var show = {
  7209. bind: function bind (el, ref, vnode) {
  7210. var value = ref.value;
  7211. vnode = locateNode(vnode);
  7212. var transition = vnode.data && vnode.data.transition;
  7213. var originalDisplay = el.__vOriginalDisplay =
  7214. el.style.display === 'none' ? '' : el.style.display;
  7215. if (value && transition && !isIE9) {
  7216. vnode.data.show = true;
  7217. enter(vnode, function () {
  7218. el.style.display = originalDisplay;
  7219. });
  7220. } else {
  7221. el.style.display = value ? originalDisplay : 'none';
  7222. }
  7223. },
  7224. update: function update (el, ref, vnode) {
  7225. var value = ref.value;
  7226. var oldValue = ref.oldValue;
  7227. /* istanbul ignore if */
  7228. if (value === oldValue) { return }
  7229. vnode = locateNode(vnode);
  7230. var transition = vnode.data && vnode.data.transition;
  7231. if (transition && !isIE9) {
  7232. vnode.data.show = true;
  7233. if (value) {
  7234. enter(vnode, function () {
  7235. el.style.display = el.__vOriginalDisplay;
  7236. });
  7237. } else {
  7238. leave(vnode, function () {
  7239. el.style.display = 'none';
  7240. });
  7241. }
  7242. } else {
  7243. el.style.display = value ? el.__vOriginalDisplay : 'none';
  7244. }
  7245. },
  7246. unbind: function unbind (
  7247. el,
  7248. binding,
  7249. vnode,
  7250. oldVnode,
  7251. isDestroy
  7252. ) {
  7253. if (!isDestroy) {
  7254. el.style.display = el.__vOriginalDisplay;
  7255. }
  7256. }
  7257. };
  7258. var platformDirectives = {
  7259. model: model$1,
  7260. show: show
  7261. };
  7262. /* */
  7263. // Provides transition support for a single element/component.
  7264. // supports transition mode (out-in / in-out)
  7265. var transitionProps = {
  7266. name: String,
  7267. appear: Boolean,
  7268. css: Boolean,
  7269. mode: String,
  7270. type: String,
  7271. enterClass: String,
  7272. leaveClass: String,
  7273. enterToClass: String,
  7274. leaveToClass: String,
  7275. enterActiveClass: String,
  7276. leaveActiveClass: String,
  7277. appearClass: String,
  7278. appearActiveClass: String,
  7279. appearToClass: String,
  7280. duration: [Number, String, Object]
  7281. };
  7282. // in case the child is also an abstract component, e.g. <keep-alive>
  7283. // we want to recursively retrieve the real component to be rendered
  7284. function getRealChild (vnode) {
  7285. var compOptions = vnode && vnode.componentOptions;
  7286. if (compOptions && compOptions.Ctor.options.abstract) {
  7287. return getRealChild(getFirstComponentChild(compOptions.children))
  7288. } else {
  7289. return vnode
  7290. }
  7291. }
  7292. function extractTransitionData (comp) {
  7293. var data = {};
  7294. var options = comp.$options;
  7295. // props
  7296. for (var key in options.propsData) {
  7297. data[key] = comp[key];
  7298. }
  7299. // events.
  7300. // extract listeners and pass them directly to the transition methods
  7301. var listeners = options._parentListeners;
  7302. for (var key$1 in listeners) {
  7303. data[camelize(key$1)] = listeners[key$1];
  7304. }
  7305. return data
  7306. }
  7307. function placeholder (h, rawChild) {
  7308. if (/\d-keep-alive$/.test(rawChild.tag)) {
  7309. return h('keep-alive', {
  7310. props: rawChild.componentOptions.propsData
  7311. })
  7312. }
  7313. }
  7314. function hasParentTransition (vnode) {
  7315. while ((vnode = vnode.parent)) {
  7316. if (vnode.data.transition) {
  7317. return true
  7318. }
  7319. }
  7320. }
  7321. function isSameChild (child, oldChild) {
  7322. return oldChild.key === child.key && oldChild.tag === child.tag
  7323. }
  7324. var Transition = {
  7325. name: 'transition',
  7326. props: transitionProps,
  7327. abstract: true,
  7328. render: function render (h) {
  7329. var this$1 = this;
  7330. var children = this.$slots.default;
  7331. if (!children) {
  7332. return
  7333. }
  7334. // filter out text nodes (possible whitespaces)
  7335. children = children.filter(function (c) { return c.tag; });
  7336. /* istanbul ignore if */
  7337. if (!children.length) {
  7338. return
  7339. }
  7340. // warn multiple elements
  7341. if (process.env.NODE_ENV !== 'production' && children.length > 1) {
  7342. warn(
  7343. '<transition> can only be used on a single element. Use ' +
  7344. '<transition-group> for lists.',
  7345. this.$parent
  7346. );
  7347. }
  7348. var mode = this.mode;
  7349. // warn invalid mode
  7350. if (process.env.NODE_ENV !== 'production' &&
  7351. mode && mode !== 'in-out' && mode !== 'out-in'
  7352. ) {
  7353. warn(
  7354. 'invalid <transition> mode: ' + mode,
  7355. this.$parent
  7356. );
  7357. }
  7358. var rawChild = children[0];
  7359. // if this is a component root node and the component's
  7360. // parent container node also has transition, skip.
  7361. if (hasParentTransition(this.$vnode)) {
  7362. return rawChild
  7363. }
  7364. // apply transition data to child
  7365. // use getRealChild() to ignore abstract components e.g. keep-alive
  7366. var child = getRealChild(rawChild);
  7367. /* istanbul ignore if */
  7368. if (!child) {
  7369. return rawChild
  7370. }
  7371. if (this._leaving) {
  7372. return placeholder(h, rawChild)
  7373. }
  7374. // ensure a key that is unique to the vnode type and to this transition
  7375. // component instance. This key will be used to remove pending leaving nodes
  7376. // during entering.
  7377. var id = "__transition-" + (this._uid) + "-";
  7378. child.key = child.key == null
  7379. ? id + child.tag
  7380. : isPrimitive(child.key)
  7381. ? (String(child.key).indexOf(id) === 0 ? child.key : id + child.key)
  7382. : child.key;
  7383. var data = (child.data || (child.data = {})).transition = extractTransitionData(this);
  7384. var oldRawChild = this._vnode;
  7385. var oldChild = getRealChild(oldRawChild);
  7386. // mark v-show
  7387. // so that the transition module can hand over the control to the directive
  7388. if (child.data.directives && child.data.directives.some(function (d) { return d.name === 'show'; })) {
  7389. child.data.show = true;
  7390. }
  7391. if (oldChild && oldChild.data && !isSameChild(child, oldChild)) {
  7392. // replace old child transition data with fresh one
  7393. // important for dynamic transitions!
  7394. var oldData = oldChild && (oldChild.data.transition = extend({}, data));
  7395. // handle transition mode
  7396. if (mode === 'out-in') {
  7397. // return placeholder node and queue update when leave finishes
  7398. this._leaving = true;
  7399. mergeVNodeHook(oldData, 'afterLeave', function () {
  7400. this$1._leaving = false;
  7401. this$1.$forceUpdate();
  7402. });
  7403. return placeholder(h, rawChild)
  7404. } else if (mode === 'in-out') {
  7405. var delayedLeave;
  7406. var performLeave = function () { delayedLeave(); };
  7407. mergeVNodeHook(data, 'afterEnter', performLeave);
  7408. mergeVNodeHook(data, 'enterCancelled', performLeave);
  7409. mergeVNodeHook(oldData, 'delayLeave', function (leave) { delayedLeave = leave; });
  7410. }
  7411. }
  7412. return rawChild
  7413. }
  7414. };
  7415. /* */
  7416. // Provides transition support for list items.
  7417. // supports move transitions using the FLIP technique.
  7418. // Because the vdom's children update algorithm is "unstable" - i.e.
  7419. // it doesn't guarantee the relative positioning of removed elements,
  7420. // we force transition-group to update its children into two passes:
  7421. // in the first pass, we remove all nodes that need to be removed,
  7422. // triggering their leaving transition; in the second pass, we insert/move
  7423. // into the final desired state. This way in the second pass removed
  7424. // nodes will remain where they should be.
  7425. var props = extend({
  7426. tag: String,
  7427. moveClass: String
  7428. }, transitionProps);
  7429. delete props.mode;
  7430. var TransitionGroup = {
  7431. props: props,
  7432. render: function render (h) {
  7433. var tag = this.tag || this.$vnode.data.tag || 'span';
  7434. var map = Object.create(null);
  7435. var prevChildren = this.prevChildren = this.children;
  7436. var rawChildren = this.$slots.default || [];
  7437. var children = this.children = [];
  7438. var transitionData = extractTransitionData(this);
  7439. for (var i = 0; i < rawChildren.length; i++) {
  7440. var c = rawChildren[i];
  7441. if (c.tag) {
  7442. if (c.key != null && String(c.key).indexOf('__vlist') !== 0) {
  7443. children.push(c);
  7444. map[c.key] = c
  7445. ;(c.data || (c.data = {})).transition = transitionData;
  7446. } else if (process.env.NODE_ENV !== 'production') {
  7447. var opts = c.componentOptions;
  7448. var name = opts ? (opts.Ctor.options.name || opts.tag || '') : c.tag;
  7449. warn(("<transition-group> children must be keyed: <" + name + ">"));
  7450. }
  7451. }
  7452. }
  7453. if (prevChildren) {
  7454. var kept = [];
  7455. var removed = [];
  7456. for (var i$1 = 0; i$1 < prevChildren.length; i$1++) {
  7457. var c$1 = prevChildren[i$1];
  7458. c$1.data.transition = transitionData;
  7459. c$1.data.pos = c$1.elm.getBoundingClientRect();
  7460. if (map[c$1.key]) {
  7461. kept.push(c$1);
  7462. } else {
  7463. removed.push(c$1);
  7464. }
  7465. }
  7466. this.kept = h(tag, null, kept);
  7467. this.removed = removed;
  7468. }
  7469. return h(tag, null, children)
  7470. },
  7471. beforeUpdate: function beforeUpdate () {
  7472. // force removing pass
  7473. this.__patch__(
  7474. this._vnode,
  7475. this.kept,
  7476. false, // hydrating
  7477. true // removeOnly (!important, avoids unnecessary moves)
  7478. );
  7479. this._vnode = this.kept;
  7480. },
  7481. updated: function updated () {
  7482. var children = this.prevChildren;
  7483. var moveClass = this.moveClass || ((this.name || 'v') + '-move');
  7484. if (!children.length || !this.hasMove(children[0].elm, moveClass)) {
  7485. return
  7486. }
  7487. // we divide the work into three loops to avoid mixing DOM reads and writes
  7488. // in each iteration - which helps prevent layout thrashing.
  7489. children.forEach(callPendingCbs);
  7490. children.forEach(recordPosition);
  7491. children.forEach(applyTranslation);
  7492. // force reflow to put everything in position
  7493. var body = document.body;
  7494. var f = body.offsetHeight; // eslint-disable-line
  7495. children.forEach(function (c) {
  7496. if (c.data.moved) {
  7497. var el = c.elm;
  7498. var s = el.style;
  7499. addTransitionClass(el, moveClass);
  7500. s.transform = s.WebkitTransform = s.transitionDuration = '';
  7501. el.addEventListener(transitionEndEvent, el._moveCb = function cb (e) {
  7502. if (!e || /transform$/.test(e.propertyName)) {
  7503. el.removeEventListener(transitionEndEvent, cb);
  7504. el._moveCb = null;
  7505. removeTransitionClass(el, moveClass);
  7506. }
  7507. });
  7508. }
  7509. });
  7510. },
  7511. methods: {
  7512. hasMove: function hasMove (el, moveClass) {
  7513. /* istanbul ignore if */
  7514. if (!hasTransition) {
  7515. return false
  7516. }
  7517. if (this._hasMove != null) {
  7518. return this._hasMove
  7519. }
  7520. // Detect whether an element with the move class applied has
  7521. // CSS transitions. Since the element may be inside an entering
  7522. // transition at this very moment, we make a clone of it and remove
  7523. // all other transition classes applied to ensure only the move class
  7524. // is applied.
  7525. var clone = el.cloneNode();
  7526. if (el._transitionClasses) {
  7527. el._transitionClasses.forEach(function (cls) { removeClass(clone, cls); });
  7528. }
  7529. addClass(clone, moveClass);
  7530. clone.style.display = 'none';
  7531. this.$el.appendChild(clone);
  7532. var info = getTransitionInfo(clone);
  7533. this.$el.removeChild(clone);
  7534. return (this._hasMove = info.hasTransform)
  7535. }
  7536. }
  7537. };
  7538. function callPendingCbs (c) {
  7539. /* istanbul ignore if */
  7540. if (c.elm._moveCb) {
  7541. c.elm._moveCb();
  7542. }
  7543. /* istanbul ignore if */
  7544. if (c.elm._enterCb) {
  7545. c.elm._enterCb();
  7546. }
  7547. }
  7548. function recordPosition (c) {
  7549. c.data.newPos = c.elm.getBoundingClientRect();
  7550. }
  7551. function applyTranslation (c) {
  7552. var oldPos = c.data.pos;
  7553. var newPos = c.data.newPos;
  7554. var dx = oldPos.left - newPos.left;
  7555. var dy = oldPos.top - newPos.top;
  7556. if (dx || dy) {
  7557. c.data.moved = true;
  7558. var s = c.elm.style;
  7559. s.transform = s.WebkitTransform = "translate(" + dx + "px," + dy + "px)";
  7560. s.transitionDuration = '0s';
  7561. }
  7562. }
  7563. var platformComponents = {
  7564. Transition: Transition,
  7565. TransitionGroup: TransitionGroup
  7566. };
  7567. /* */
  7568. // install platform specific utils
  7569. Vue$3.config.mustUseProp = mustUseProp;
  7570. Vue$3.config.isReservedTag = isReservedTag;
  7571. Vue$3.config.isReservedAttr = isReservedAttr;
  7572. Vue$3.config.getTagNamespace = getTagNamespace;
  7573. Vue$3.config.isUnknownElement = isUnknownElement;
  7574. // install platform runtime directives & components
  7575. extend(Vue$3.options.directives, platformDirectives);
  7576. extend(Vue$3.options.components, platformComponents);
  7577. // install platform patch function
  7578. Vue$3.prototype.__patch__ = inBrowser ? patch : noop;
  7579. // public mount method
  7580. Vue$3.prototype.$mount = function (
  7581. el,
  7582. hydrating
  7583. ) {
  7584. el = el && inBrowser ? query(el) : undefined;
  7585. return mountComponent(this, el, hydrating)
  7586. };
  7587. // devtools global hook
  7588. /* istanbul ignore next */
  7589. setTimeout(function () {
  7590. if (config.devtools) {
  7591. if (devtools) {
  7592. devtools.emit('init', Vue$3);
  7593. } else if (process.env.NODE_ENV !== 'production' && isChrome) {
  7594. console[console.info ? 'info' : 'log'](
  7595. 'Download the Vue Devtools extension for a better development experience:\n' +
  7596. 'https://github.com/vuejs/vue-devtools'
  7597. );
  7598. }
  7599. }
  7600. if (process.env.NODE_ENV !== 'production' &&
  7601. config.productionTip !== false &&
  7602. inBrowser && typeof console !== 'undefined'
  7603. ) {
  7604. console[console.info ? 'info' : 'log'](
  7605. "You are running Vue in development mode.\n" +
  7606. "Make sure to turn on production mode when deploying for production.\n" +
  7607. "See more tips at https://vuejs.org/guide/deployment.html"
  7608. );
  7609. }
  7610. }, 0);
  7611. /* */
  7612. // check whether current browser encodes a char inside attribute values
  7613. function shouldDecode (content, encoded) {
  7614. var div = document.createElement('div');
  7615. div.innerHTML = "<div a=\"" + content + "\">";
  7616. return div.innerHTML.indexOf(encoded) > 0
  7617. }
  7618. // #3663
  7619. // IE encodes newlines inside attribute values while other browsers don't
  7620. var shouldDecodeNewlines = inBrowser ? shouldDecode('\n', '&#10;') : false;
  7621. /* */
  7622. var isUnaryTag = makeMap(
  7623. 'area,base,br,col,embed,frame,hr,img,input,isindex,keygen,' +
  7624. 'link,meta,param,source,track,wbr'
  7625. );
  7626. // Elements that you can, intentionally, leave open
  7627. // (and which close themselves)
  7628. var canBeLeftOpenTag = makeMap(
  7629. 'colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr,source'
  7630. );
  7631. // HTML5 tags https://html.spec.whatwg.org/multipage/indices.html#elements-3
  7632. // Phrasing Content https://html.spec.whatwg.org/multipage/dom.html#phrasing-content
  7633. var isNonPhrasingTag = makeMap(
  7634. 'address,article,aside,base,blockquote,body,caption,col,colgroup,dd,' +
  7635. 'details,dialog,div,dl,dt,fieldset,figcaption,figure,footer,form,' +
  7636. 'h1,h2,h3,h4,h5,h6,head,header,hgroup,hr,html,legend,li,menuitem,meta,' +
  7637. 'optgroup,option,param,rp,rt,source,style,summary,tbody,td,tfoot,th,thead,' +
  7638. 'title,tr,track'
  7639. );
  7640. /* */
  7641. var decoder;
  7642. function decode (html) {
  7643. decoder = decoder || document.createElement('div');
  7644. decoder.innerHTML = html;
  7645. return decoder.textContent
  7646. }
  7647. /**
  7648. * Not type-checking this file because it's mostly vendor code.
  7649. */
  7650. /*!
  7651. * HTML Parser By John Resig (ejohn.org)
  7652. * Modified by Juriy "kangax" Zaytsev
  7653. * Original code by Erik Arvidsson, Mozilla Public License
  7654. * http://erik.eae.net/simplehtmlparser/simplehtmlparser.js
  7655. */
  7656. // Regular Expressions for parsing tags and attributes
  7657. var singleAttrIdentifier = /([^\s"'<>/=]+)/;
  7658. var singleAttrAssign = /(?:=)/;
  7659. var singleAttrValues = [
  7660. // attr value double quotes
  7661. /"([^"]*)"+/.source,
  7662. // attr value, single quotes
  7663. /'([^']*)'+/.source,
  7664. // attr value, no quotes
  7665. /([^\s"'=<>`]+)/.source
  7666. ];
  7667. var attribute = new RegExp(
  7668. '^\\s*' + singleAttrIdentifier.source +
  7669. '(?:\\s*(' + singleAttrAssign.source + ')' +
  7670. '\\s*(?:' + singleAttrValues.join('|') + '))?'
  7671. );
  7672. // could use https://www.w3.org/TR/1999/REC-xml-names-19990114/#NT-QName
  7673. // but for Vue templates we can enforce a simple charset
  7674. var ncname = '[a-zA-Z_][\\w\\-\\.]*';
  7675. var qnameCapture = '((?:' + ncname + '\\:)?' + ncname + ')';
  7676. var startTagOpen = new RegExp('^<' + qnameCapture);
  7677. var startTagClose = /^\s*(\/?)>/;
  7678. var endTag = new RegExp('^<\\/' + qnameCapture + '[^>]*>');
  7679. var doctype = /^<!DOCTYPE [^>]+>/i;
  7680. var comment = /^<!--/;
  7681. var conditionalComment = /^<!\[/;
  7682. var IS_REGEX_CAPTURING_BROKEN = false;
  7683. 'x'.replace(/x(.)?/g, function (m, g) {
  7684. IS_REGEX_CAPTURING_BROKEN = g === '';
  7685. });
  7686. // Special Elements (can contain anything)
  7687. var isPlainTextElement = makeMap('script,style,textarea', true);
  7688. var reCache = {};
  7689. var decodingMap = {
  7690. '&lt;': '<',
  7691. '&gt;': '>',
  7692. '&quot;': '"',
  7693. '&amp;': '&',
  7694. '&#10;': '\n'
  7695. };
  7696. var encodedAttr = /&(?:lt|gt|quot|amp);/g;
  7697. var encodedAttrWithNewLines = /&(?:lt|gt|quot|amp|#10);/g;
  7698. function decodeAttr (value, shouldDecodeNewlines) {
  7699. var re = shouldDecodeNewlines ? encodedAttrWithNewLines : encodedAttr;
  7700. return value.replace(re, function (match) { return decodingMap[match]; })
  7701. }
  7702. function parseHTML (html, options) {
  7703. var stack = [];
  7704. var expectHTML = options.expectHTML;
  7705. var isUnaryTag$$1 = options.isUnaryTag || no;
  7706. var canBeLeftOpenTag$$1 = options.canBeLeftOpenTag || no;
  7707. var index = 0;
  7708. var last, lastTag;
  7709. while (html) {
  7710. last = html;
  7711. // Make sure we're not in a plaintext content element like script/style
  7712. if (!lastTag || !isPlainTextElement(lastTag)) {
  7713. var textEnd = html.indexOf('<');
  7714. if (textEnd === 0) {
  7715. // Comment:
  7716. if (comment.test(html)) {
  7717. var commentEnd = html.indexOf('-->');
  7718. if (commentEnd >= 0) {
  7719. advance(commentEnd + 3);
  7720. continue
  7721. }
  7722. }
  7723. // http://en.wikipedia.org/wiki/Conditional_comment#Downlevel-revealed_conditional_comment
  7724. if (conditionalComment.test(html)) {
  7725. var conditionalEnd = html.indexOf(']>');
  7726. if (conditionalEnd >= 0) {
  7727. advance(conditionalEnd + 2);
  7728. continue
  7729. }
  7730. }
  7731. // Doctype:
  7732. var doctypeMatch = html.match(doctype);
  7733. if (doctypeMatch) {
  7734. advance(doctypeMatch[0].length);
  7735. continue
  7736. }
  7737. // End tag:
  7738. var endTagMatch = html.match(endTag);
  7739. if (endTagMatch) {
  7740. var curIndex = index;
  7741. advance(endTagMatch[0].length);
  7742. parseEndTag(endTagMatch[1], curIndex, index);
  7743. continue
  7744. }
  7745. // Start tag:
  7746. var startTagMatch = parseStartTag();
  7747. if (startTagMatch) {
  7748. handleStartTag(startTagMatch);
  7749. continue
  7750. }
  7751. }
  7752. var text = (void 0), rest$1 = (void 0), next = (void 0);
  7753. if (textEnd >= 0) {
  7754. rest$1 = html.slice(textEnd);
  7755. while (
  7756. !endTag.test(rest$1) &&
  7757. !startTagOpen.test(rest$1) &&
  7758. !comment.test(rest$1) &&
  7759. !conditionalComment.test(rest$1)
  7760. ) {
  7761. // < in plain text, be forgiving and treat it as text
  7762. next = rest$1.indexOf('<', 1);
  7763. if (next < 0) { break }
  7764. textEnd += next;
  7765. rest$1 = html.slice(textEnd);
  7766. }
  7767. text = html.substring(0, textEnd);
  7768. advance(textEnd);
  7769. }
  7770. if (textEnd < 0) {
  7771. text = html;
  7772. html = '';
  7773. }
  7774. if (options.chars && text) {
  7775. options.chars(text);
  7776. }
  7777. } else {
  7778. var stackedTag = lastTag.toLowerCase();
  7779. var reStackedTag = reCache[stackedTag] || (reCache[stackedTag] = new RegExp('([\\s\\S]*?)(</' + stackedTag + '[^>]*>)', 'i'));
  7780. var endTagLength = 0;
  7781. var rest = html.replace(reStackedTag, function (all, text, endTag) {
  7782. endTagLength = endTag.length;
  7783. if (!isPlainTextElement(stackedTag) && stackedTag !== 'noscript') {
  7784. text = text
  7785. .replace(/<!--([\s\S]*?)-->/g, '$1')
  7786. .replace(/<!\[CDATA\[([\s\S]*?)]]>/g, '$1');
  7787. }
  7788. if (options.chars) {
  7789. options.chars(text);
  7790. }
  7791. return ''
  7792. });
  7793. index += html.length - rest.length;
  7794. html = rest;
  7795. parseEndTag(stackedTag, index - endTagLength, index);
  7796. }
  7797. if (html === last) {
  7798. options.chars && options.chars(html);
  7799. if (process.env.NODE_ENV !== 'production' && !stack.length && options.warn) {
  7800. options.warn(("Mal-formatted tag at end of template: \"" + html + "\""));
  7801. }
  7802. break
  7803. }
  7804. }
  7805. // Clean up any remaining tags
  7806. parseEndTag();
  7807. function advance (n) {
  7808. index += n;
  7809. html = html.substring(n);
  7810. }
  7811. function parseStartTag () {
  7812. var start = html.match(startTagOpen);
  7813. if (start) {
  7814. var match = {
  7815. tagName: start[1],
  7816. attrs: [],
  7817. start: index
  7818. };
  7819. advance(start[0].length);
  7820. var end, attr;
  7821. while (!(end = html.match(startTagClose)) && (attr = html.match(attribute))) {
  7822. advance(attr[0].length);
  7823. match.attrs.push(attr);
  7824. }
  7825. if (end) {
  7826. match.unarySlash = end[1];
  7827. advance(end[0].length);
  7828. match.end = index;
  7829. return match
  7830. }
  7831. }
  7832. }
  7833. function handleStartTag (match) {
  7834. var tagName = match.tagName;
  7835. var unarySlash = match.unarySlash;
  7836. if (expectHTML) {
  7837. if (lastTag === 'p' && isNonPhrasingTag(tagName)) {
  7838. parseEndTag(lastTag);
  7839. }
  7840. if (canBeLeftOpenTag$$1(tagName) && lastTag === tagName) {
  7841. parseEndTag(tagName);
  7842. }
  7843. }
  7844. var unary = isUnaryTag$$1(tagName) || tagName === 'html' && lastTag === 'head' || !!unarySlash;
  7845. var l = match.attrs.length;
  7846. var attrs = new Array(l);
  7847. for (var i = 0; i < l; i++) {
  7848. var args = match.attrs[i];
  7849. // hackish work around FF bug https://bugzilla.mozilla.org/show_bug.cgi?id=369778
  7850. if (IS_REGEX_CAPTURING_BROKEN && args[0].indexOf('""') === -1) {
  7851. if (args[3] === '') { delete args[3]; }
  7852. if (args[4] === '') { delete args[4]; }
  7853. if (args[5] === '') { delete args[5]; }
  7854. }
  7855. var value = args[3] || args[4] || args[5] || '';
  7856. attrs[i] = {
  7857. name: args[1],
  7858. value: decodeAttr(
  7859. value,
  7860. options.shouldDecodeNewlines
  7861. )
  7862. };
  7863. }
  7864. if (!unary) {
  7865. stack.push({ tag: tagName, lowerCasedTag: tagName.toLowerCase(), attrs: attrs });
  7866. lastTag = tagName;
  7867. }
  7868. if (options.start) {
  7869. options.start(tagName, attrs, unary, match.start, match.end);
  7870. }
  7871. }
  7872. function parseEndTag (tagName, start, end) {
  7873. var pos, lowerCasedTagName;
  7874. if (start == null) { start = index; }
  7875. if (end == null) { end = index; }
  7876. if (tagName) {
  7877. lowerCasedTagName = tagName.toLowerCase();
  7878. }
  7879. // Find the closest opened tag of the same type
  7880. if (tagName) {
  7881. for (pos = stack.length - 1; pos >= 0; pos--) {
  7882. if (stack[pos].lowerCasedTag === lowerCasedTagName) {
  7883. break
  7884. }
  7885. }
  7886. } else {
  7887. // If no tag name is provided, clean shop
  7888. pos = 0;
  7889. }
  7890. if (pos >= 0) {
  7891. // Close all the open elements, up the stack
  7892. for (var i = stack.length - 1; i >= pos; i--) {
  7893. if (process.env.NODE_ENV !== 'production' &&
  7894. (i > pos || !tagName) &&
  7895. options.warn
  7896. ) {
  7897. options.warn(
  7898. ("tag <" + (stack[i].tag) + "> has no matching end tag.")
  7899. );
  7900. }
  7901. if (options.end) {
  7902. options.end(stack[i].tag, start, end);
  7903. }
  7904. }
  7905. // Remove the open elements from the stack
  7906. stack.length = pos;
  7907. lastTag = pos && stack[pos - 1].tag;
  7908. } else if (lowerCasedTagName === 'br') {
  7909. if (options.start) {
  7910. options.start(tagName, [], true, start, end);
  7911. }
  7912. } else if (lowerCasedTagName === 'p') {
  7913. if (options.start) {
  7914. options.start(tagName, [], false, start, end);
  7915. }
  7916. if (options.end) {
  7917. options.end(tagName, start, end);
  7918. }
  7919. }
  7920. }
  7921. }
  7922. /* */
  7923. var defaultTagRE = /\{\{((?:.|\n)+?)\}\}/g;
  7924. var regexEscapeRE = /[-.*+?^${}()|[\]\/\\]/g;
  7925. var buildRegex = cached(function (delimiters) {
  7926. var open = delimiters[0].replace(regexEscapeRE, '\\$&');
  7927. var close = delimiters[1].replace(regexEscapeRE, '\\$&');
  7928. return new RegExp(open + '((?:.|\\n)+?)' + close, 'g')
  7929. });
  7930. function parseText (
  7931. text,
  7932. delimiters
  7933. ) {
  7934. var tagRE = delimiters ? buildRegex(delimiters) : defaultTagRE;
  7935. if (!tagRE.test(text)) {
  7936. return
  7937. }
  7938. var tokens = [];
  7939. var lastIndex = tagRE.lastIndex = 0;
  7940. var match, index;
  7941. while ((match = tagRE.exec(text))) {
  7942. index = match.index;
  7943. // push text token
  7944. if (index > lastIndex) {
  7945. tokens.push(JSON.stringify(text.slice(lastIndex, index)));
  7946. }
  7947. // tag token
  7948. var exp = parseFilters(match[1].trim());
  7949. tokens.push(("_s(" + exp + ")"));
  7950. lastIndex = index + match[0].length;
  7951. }
  7952. if (lastIndex < text.length) {
  7953. tokens.push(JSON.stringify(text.slice(lastIndex)));
  7954. }
  7955. return tokens.join('+')
  7956. }
  7957. /* */
  7958. var onRE = /^@|^v-on:/;
  7959. var dirRE = /^v-|^@|^:/;
  7960. var forAliasRE = /(.*?)\s+(?:in|of)\s+(.*)/;
  7961. var forIteratorRE = /\((\{[^}]*\}|[^,]*),([^,]*)(?:,([^,]*))?\)/;
  7962. var argRE = /:(.*)$/;
  7963. var bindRE = /^:|^v-bind:/;
  7964. var modifierRE = /\.[^.]+/g;
  7965. var decodeHTMLCached = cached(decode);
  7966. // configurable state
  7967. var warn$2;
  7968. var delimiters;
  7969. var transforms;
  7970. var preTransforms;
  7971. var postTransforms;
  7972. var platformIsPreTag;
  7973. var platformMustUseProp;
  7974. var platformGetTagNamespace;
  7975. /**
  7976. * Convert HTML string to AST.
  7977. */
  7978. function parse (
  7979. template,
  7980. options
  7981. ) {
  7982. warn$2 = options.warn || baseWarn;
  7983. platformGetTagNamespace = options.getTagNamespace || no;
  7984. platformMustUseProp = options.mustUseProp || no;
  7985. platformIsPreTag = options.isPreTag || no;
  7986. preTransforms = pluckModuleFunction(options.modules, 'preTransformNode');
  7987. transforms = pluckModuleFunction(options.modules, 'transformNode');
  7988. postTransforms = pluckModuleFunction(options.modules, 'postTransformNode');
  7989. delimiters = options.delimiters;
  7990. var stack = [];
  7991. var preserveWhitespace = options.preserveWhitespace !== false;
  7992. var root;
  7993. var currentParent;
  7994. var inVPre = false;
  7995. var inPre = false;
  7996. var warned = false;
  7997. function warnOnce (msg) {
  7998. if (!warned) {
  7999. warned = true;
  8000. warn$2(msg);
  8001. }
  8002. }
  8003. function endPre (element) {
  8004. // check pre state
  8005. if (element.pre) {
  8006. inVPre = false;
  8007. }
  8008. if (platformIsPreTag(element.tag)) {
  8009. inPre = false;
  8010. }
  8011. }
  8012. parseHTML(template, {
  8013. warn: warn$2,
  8014. expectHTML: options.expectHTML,
  8015. isUnaryTag: options.isUnaryTag,
  8016. canBeLeftOpenTag: options.canBeLeftOpenTag,
  8017. shouldDecodeNewlines: options.shouldDecodeNewlines,
  8018. start: function start (tag, attrs, unary) {
  8019. // check namespace.
  8020. // inherit parent ns if there is one
  8021. var ns = (currentParent && currentParent.ns) || platformGetTagNamespace(tag);
  8022. // handle IE svg bug
  8023. /* istanbul ignore if */
  8024. if (isIE && ns === 'svg') {
  8025. attrs = guardIESVGBug(attrs);
  8026. }
  8027. var element = {
  8028. type: 1,
  8029. tag: tag,
  8030. attrsList: attrs,
  8031. attrsMap: makeAttrsMap(attrs),
  8032. parent: currentParent,
  8033. children: []
  8034. };
  8035. if (ns) {
  8036. element.ns = ns;
  8037. }
  8038. if (isForbiddenTag(element) && !isServerRendering()) {
  8039. element.forbidden = true;
  8040. process.env.NODE_ENV !== 'production' && warn$2(
  8041. 'Templates should only be responsible for mapping the state to the ' +
  8042. 'UI. Avoid placing tags with side-effects in your templates, such as ' +
  8043. "<" + tag + ">" + ', as they will not be parsed.'
  8044. );
  8045. }
  8046. // apply pre-transforms
  8047. for (var i = 0; i < preTransforms.length; i++) {
  8048. preTransforms[i](element, options);
  8049. }
  8050. if (!inVPre) {
  8051. processPre(element);
  8052. if (element.pre) {
  8053. inVPre = true;
  8054. }
  8055. }
  8056. if (platformIsPreTag(element.tag)) {
  8057. inPre = true;
  8058. }
  8059. if (inVPre) {
  8060. processRawAttrs(element);
  8061. } else {
  8062. processFor(element);
  8063. processIf(element);
  8064. processOnce(element);
  8065. processKey(element);
  8066. // determine whether this is a plain element after
  8067. // removing structural attributes
  8068. element.plain = !element.key && !attrs.length;
  8069. processRef(element);
  8070. processSlot(element);
  8071. processComponent(element);
  8072. for (var i$1 = 0; i$1 < transforms.length; i$1++) {
  8073. transforms[i$1](element, options);
  8074. }
  8075. processAttrs(element);
  8076. }
  8077. function checkRootConstraints (el) {
  8078. if (process.env.NODE_ENV !== 'production') {
  8079. if (el.tag === 'slot' || el.tag === 'template') {
  8080. warnOnce(
  8081. "Cannot use <" + (el.tag) + "> as component root element because it may " +
  8082. 'contain multiple nodes.'
  8083. );
  8084. }
  8085. if (el.attrsMap.hasOwnProperty('v-for')) {
  8086. warnOnce(
  8087. 'Cannot use v-for on stateful component root element because ' +
  8088. 'it renders multiple elements.'
  8089. );
  8090. }
  8091. }
  8092. }
  8093. // tree management
  8094. if (!root) {
  8095. root = element;
  8096. checkRootConstraints(root);
  8097. } else if (!stack.length) {
  8098. // allow root elements with v-if, v-else-if and v-else
  8099. if (root.if && (element.elseif || element.else)) {
  8100. checkRootConstraints(element);
  8101. addIfCondition(root, {
  8102. exp: element.elseif,
  8103. block: element
  8104. });
  8105. } else if (process.env.NODE_ENV !== 'production') {
  8106. warnOnce(
  8107. "Component template should contain exactly one root element. " +
  8108. "If you are using v-if on multiple elements, " +
  8109. "use v-else-if to chain them instead."
  8110. );
  8111. }
  8112. }
  8113. if (currentParent && !element.forbidden) {
  8114. if (element.elseif || element.else) {
  8115. processIfConditions(element, currentParent);
  8116. } else if (element.slotScope) { // scoped slot
  8117. currentParent.plain = false;
  8118. var name = element.slotTarget || '"default"';(currentParent.scopedSlots || (currentParent.scopedSlots = {}))[name] = element;
  8119. } else {
  8120. currentParent.children.push(element);
  8121. element.parent = currentParent;
  8122. }
  8123. }
  8124. if (!unary) {
  8125. currentParent = element;
  8126. stack.push(element);
  8127. } else {
  8128. endPre(element);
  8129. }
  8130. // apply post-transforms
  8131. for (var i$2 = 0; i$2 < postTransforms.length; i$2++) {
  8132. postTransforms[i$2](element, options);
  8133. }
  8134. },
  8135. end: function end () {
  8136. // remove trailing whitespace
  8137. var element = stack[stack.length - 1];
  8138. var lastNode = element.children[element.children.length - 1];
  8139. if (lastNode && lastNode.type === 3 && lastNode.text === ' ' && !inPre) {
  8140. element.children.pop();
  8141. }
  8142. // pop stack
  8143. stack.length -= 1;
  8144. currentParent = stack[stack.length - 1];
  8145. endPre(element);
  8146. },
  8147. chars: function chars (text) {
  8148. if (!currentParent) {
  8149. if (process.env.NODE_ENV !== 'production') {
  8150. if (text === template) {
  8151. warnOnce(
  8152. 'Component template requires a root element, rather than just text.'
  8153. );
  8154. } else if ((text = text.trim())) {
  8155. warnOnce(
  8156. ("text \"" + text + "\" outside root element will be ignored.")
  8157. );
  8158. }
  8159. }
  8160. return
  8161. }
  8162. // IE textarea placeholder bug
  8163. /* istanbul ignore if */
  8164. if (isIE &&
  8165. currentParent.tag === 'textarea' &&
  8166. currentParent.attrsMap.placeholder === text
  8167. ) {
  8168. return
  8169. }
  8170. var children = currentParent.children;
  8171. text = inPre || text.trim()
  8172. ? isTextTag(currentParent) ? text : decodeHTMLCached(text)
  8173. // only preserve whitespace if its not right after a starting tag
  8174. : preserveWhitespace && children.length ? ' ' : '';
  8175. if (text) {
  8176. var expression;
  8177. if (!inVPre && text !== ' ' && (expression = parseText(text, delimiters))) {
  8178. children.push({
  8179. type: 2,
  8180. expression: expression,
  8181. text: text
  8182. });
  8183. } else if (text !== ' ' || !children.length || children[children.length - 1].text !== ' ') {
  8184. children.push({
  8185. type: 3,
  8186. text: text
  8187. });
  8188. }
  8189. }
  8190. }
  8191. });
  8192. return root
  8193. }
  8194. function processPre (el) {
  8195. if (getAndRemoveAttr(el, 'v-pre') != null) {
  8196. el.pre = true;
  8197. }
  8198. }
  8199. function processRawAttrs (el) {
  8200. var l = el.attrsList.length;
  8201. if (l) {
  8202. var attrs = el.attrs = new Array(l);
  8203. for (var i = 0; i < l; i++) {
  8204. attrs[i] = {
  8205. name: el.attrsList[i].name,
  8206. value: JSON.stringify(el.attrsList[i].value)
  8207. };
  8208. }
  8209. } else if (!el.pre) {
  8210. // non root node in pre blocks with no attributes
  8211. el.plain = true;
  8212. }
  8213. }
  8214. function processKey (el) {
  8215. var exp = getBindingAttr(el, 'key');
  8216. if (exp) {
  8217. if (process.env.NODE_ENV !== 'production' && el.tag === 'template') {
  8218. warn$2("<template> cannot be keyed. Place the key on real elements instead.");
  8219. }
  8220. el.key = exp;
  8221. }
  8222. }
  8223. function processRef (el) {
  8224. var ref = getBindingAttr(el, 'ref');
  8225. if (ref) {
  8226. el.ref = ref;
  8227. el.refInFor = checkInFor(el);
  8228. }
  8229. }
  8230. function processFor (el) {
  8231. var exp;
  8232. if ((exp = getAndRemoveAttr(el, 'v-for'))) {
  8233. var inMatch = exp.match(forAliasRE);
  8234. if (!inMatch) {
  8235. process.env.NODE_ENV !== 'production' && warn$2(
  8236. ("Invalid v-for expression: " + exp)
  8237. );
  8238. return
  8239. }
  8240. el.for = inMatch[2].trim();
  8241. var alias = inMatch[1].trim();
  8242. var iteratorMatch = alias.match(forIteratorRE);
  8243. if (iteratorMatch) {
  8244. el.alias = iteratorMatch[1].trim();
  8245. el.iterator1 = iteratorMatch[2].trim();
  8246. if (iteratorMatch[3]) {
  8247. el.iterator2 = iteratorMatch[3].trim();
  8248. }
  8249. } else {
  8250. el.alias = alias;
  8251. }
  8252. }
  8253. }
  8254. function processIf (el) {
  8255. var exp = getAndRemoveAttr(el, 'v-if');
  8256. if (exp) {
  8257. el.if = exp;
  8258. addIfCondition(el, {
  8259. exp: exp,
  8260. block: el
  8261. });
  8262. } else {
  8263. if (getAndRemoveAttr(el, 'v-else') != null) {
  8264. el.else = true;
  8265. }
  8266. var elseif = getAndRemoveAttr(el, 'v-else-if');
  8267. if (elseif) {
  8268. el.elseif = elseif;
  8269. }
  8270. }
  8271. }
  8272. function processIfConditions (el, parent) {
  8273. var prev = findPrevElement(parent.children);
  8274. if (prev && prev.if) {
  8275. addIfCondition(prev, {
  8276. exp: el.elseif,
  8277. block: el
  8278. });
  8279. } else if (process.env.NODE_ENV !== 'production') {
  8280. warn$2(
  8281. "v-" + (el.elseif ? ('else-if="' + el.elseif + '"') : 'else') + " " +
  8282. "used on element <" + (el.tag) + "> without corresponding v-if."
  8283. );
  8284. }
  8285. }
  8286. function findPrevElement (children) {
  8287. var i = children.length;
  8288. while (i--) {
  8289. if (children[i].type === 1) {
  8290. return children[i]
  8291. } else {
  8292. if (process.env.NODE_ENV !== 'production' && children[i].text !== ' ') {
  8293. warn$2(
  8294. "text \"" + (children[i].text.trim()) + "\" between v-if and v-else(-if) " +
  8295. "will be ignored."
  8296. );
  8297. }
  8298. children.pop();
  8299. }
  8300. }
  8301. }
  8302. function addIfCondition (el, condition) {
  8303. if (!el.ifConditions) {
  8304. el.ifConditions = [];
  8305. }
  8306. el.ifConditions.push(condition);
  8307. }
  8308. function processOnce (el) {
  8309. var once$$1 = getAndRemoveAttr(el, 'v-once');
  8310. if (once$$1 != null) {
  8311. el.once = true;
  8312. }
  8313. }
  8314. function processSlot (el) {
  8315. if (el.tag === 'slot') {
  8316. el.slotName = getBindingAttr(el, 'name');
  8317. if (process.env.NODE_ENV !== 'production' && el.key) {
  8318. warn$2(
  8319. "`key` does not work on <slot> because slots are abstract outlets " +
  8320. "and can possibly expand into multiple elements. " +
  8321. "Use the key on a wrapping element instead."
  8322. );
  8323. }
  8324. } else {
  8325. var slotTarget = getBindingAttr(el, 'slot');
  8326. if (slotTarget) {
  8327. el.slotTarget = slotTarget === '""' ? '"default"' : slotTarget;
  8328. }
  8329. if (el.tag === 'template') {
  8330. el.slotScope = getAndRemoveAttr(el, 'scope');
  8331. }
  8332. }
  8333. }
  8334. function processComponent (el) {
  8335. var binding;
  8336. if ((binding = getBindingAttr(el, 'is'))) {
  8337. el.component = binding;
  8338. }
  8339. if (getAndRemoveAttr(el, 'inline-template') != null) {
  8340. el.inlineTemplate = true;
  8341. }
  8342. }
  8343. function processAttrs (el) {
  8344. var list = el.attrsList;
  8345. var i, l, name, rawName, value, modifiers, isProp;
  8346. for (i = 0, l = list.length; i < l; i++) {
  8347. name = rawName = list[i].name;
  8348. value = list[i].value;
  8349. if (dirRE.test(name)) {
  8350. // mark element as dynamic
  8351. el.hasBindings = true;
  8352. // modifiers
  8353. modifiers = parseModifiers(name);
  8354. if (modifiers) {
  8355. name = name.replace(modifierRE, '');
  8356. }
  8357. if (bindRE.test(name)) { // v-bind
  8358. name = name.replace(bindRE, '');
  8359. value = parseFilters(value);
  8360. isProp = false;
  8361. if (modifiers) {
  8362. if (modifiers.prop) {
  8363. isProp = true;
  8364. name = camelize(name);
  8365. if (name === 'innerHtml') { name = 'innerHTML'; }
  8366. }
  8367. if (modifiers.camel) {
  8368. name = camelize(name);
  8369. }
  8370. if (modifiers.sync) {
  8371. addHandler(
  8372. el,
  8373. ("update:" + (camelize(name))),
  8374. genAssignmentCode(value, "$event")
  8375. );
  8376. }
  8377. }
  8378. if (isProp || platformMustUseProp(el.tag, el.attrsMap.type, name)) {
  8379. addProp(el, name, value);
  8380. } else {
  8381. addAttr(el, name, value);
  8382. }
  8383. } else if (onRE.test(name)) { // v-on
  8384. name = name.replace(onRE, '');
  8385. addHandler(el, name, value, modifiers, false, warn$2);
  8386. } else { // normal directives
  8387. name = name.replace(dirRE, '');
  8388. // parse arg
  8389. var argMatch = name.match(argRE);
  8390. var arg = argMatch && argMatch[1];
  8391. if (arg) {
  8392. name = name.slice(0, -(arg.length + 1));
  8393. }
  8394. addDirective(el, name, rawName, value, arg, modifiers);
  8395. if (process.env.NODE_ENV !== 'production' && name === 'model') {
  8396. checkForAliasModel(el, value);
  8397. }
  8398. }
  8399. } else {
  8400. // literal attribute
  8401. if (process.env.NODE_ENV !== 'production') {
  8402. var expression = parseText(value, delimiters);
  8403. if (expression) {
  8404. warn$2(
  8405. name + "=\"" + value + "\": " +
  8406. 'Interpolation inside attributes has been removed. ' +
  8407. 'Use v-bind or the colon shorthand instead. For example, ' +
  8408. 'instead of <div id="{{ val }}">, use <div :id="val">.'
  8409. );
  8410. }
  8411. }
  8412. addAttr(el, name, JSON.stringify(value));
  8413. }
  8414. }
  8415. }
  8416. function checkInFor (el) {
  8417. var parent = el;
  8418. while (parent) {
  8419. if (parent.for !== undefined) {
  8420. return true
  8421. }
  8422. parent = parent.parent;
  8423. }
  8424. return false
  8425. }
  8426. function parseModifiers (name) {
  8427. var match = name.match(modifierRE);
  8428. if (match) {
  8429. var ret = {};
  8430. match.forEach(function (m) { ret[m.slice(1)] = true; });
  8431. return ret
  8432. }
  8433. }
  8434. function makeAttrsMap (attrs) {
  8435. var map = {};
  8436. for (var i = 0, l = attrs.length; i < l; i++) {
  8437. if (
  8438. process.env.NODE_ENV !== 'production' &&
  8439. map[attrs[i].name] && !isIE && !isEdge
  8440. ) {
  8441. warn$2('duplicate attribute: ' + attrs[i].name);
  8442. }
  8443. map[attrs[i].name] = attrs[i].value;
  8444. }
  8445. return map
  8446. }
  8447. // for script (e.g. type="x/template") or style, do not decode content
  8448. function isTextTag (el) {
  8449. return el.tag === 'script' || el.tag === 'style'
  8450. }
  8451. function isForbiddenTag (el) {
  8452. return (
  8453. el.tag === 'style' ||
  8454. (el.tag === 'script' && (
  8455. !el.attrsMap.type ||
  8456. el.attrsMap.type === 'text/javascript'
  8457. ))
  8458. )
  8459. }
  8460. var ieNSBug = /^xmlns:NS\d+/;
  8461. var ieNSPrefix = /^NS\d+:/;
  8462. /* istanbul ignore next */
  8463. function guardIESVGBug (attrs) {
  8464. var res = [];
  8465. for (var i = 0; i < attrs.length; i++) {
  8466. var attr = attrs[i];
  8467. if (!ieNSBug.test(attr.name)) {
  8468. attr.name = attr.name.replace(ieNSPrefix, '');
  8469. res.push(attr);
  8470. }
  8471. }
  8472. return res
  8473. }
  8474. function checkForAliasModel (el, value) {
  8475. var _el = el;
  8476. while (_el) {
  8477. if (_el.for && _el.alias === value) {
  8478. warn$2(
  8479. "<" + (el.tag) + " v-model=\"" + value + "\">: " +
  8480. "You are binding v-model directly to a v-for iteration alias. " +
  8481. "This will not be able to modify the v-for source array because " +
  8482. "writing to the alias is like modifying a function local variable. " +
  8483. "Consider using an array of objects and use v-model on an object property instead."
  8484. );
  8485. }
  8486. _el = _el.parent;
  8487. }
  8488. }
  8489. /* */
  8490. var isStaticKey;
  8491. var isPlatformReservedTag;
  8492. var genStaticKeysCached = cached(genStaticKeys$1);
  8493. /**
  8494. * Goal of the optimizer: walk the generated template AST tree
  8495. * and detect sub-trees that are purely static, i.e. parts of
  8496. * the DOM that never needs to change.
  8497. *
  8498. * Once we detect these sub-trees, we can:
  8499. *
  8500. * 1. Hoist them into constants, so that we no longer need to
  8501. * create fresh nodes for them on each re-render;
  8502. * 2. Completely skip them in the patching process.
  8503. */
  8504. function optimize (root, options) {
  8505. if (!root) { return }
  8506. isStaticKey = genStaticKeysCached(options.staticKeys || '');
  8507. isPlatformReservedTag = options.isReservedTag || no;
  8508. // first pass: mark all non-static nodes.
  8509. markStatic$1(root);
  8510. // second pass: mark static roots.
  8511. markStaticRoots(root, false);
  8512. }
  8513. function genStaticKeys$1 (keys) {
  8514. return makeMap(
  8515. 'type,tag,attrsList,attrsMap,plain,parent,children,attrs' +
  8516. (keys ? ',' + keys : '')
  8517. )
  8518. }
  8519. function markStatic$1 (node) {
  8520. node.static = isStatic(node);
  8521. if (node.type === 1) {
  8522. // do not make component slot content static. this avoids
  8523. // 1. components not able to mutate slot nodes
  8524. // 2. static slot content fails for hot-reloading
  8525. if (
  8526. !isPlatformReservedTag(node.tag) &&
  8527. node.tag !== 'slot' &&
  8528. node.attrsMap['inline-template'] == null
  8529. ) {
  8530. return
  8531. }
  8532. for (var i = 0, l = node.children.length; i < l; i++) {
  8533. var child = node.children[i];
  8534. markStatic$1(child);
  8535. if (!child.static) {
  8536. node.static = false;
  8537. }
  8538. }
  8539. }
  8540. }
  8541. function markStaticRoots (node, isInFor) {
  8542. if (node.type === 1) {
  8543. if (node.static || node.once) {
  8544. node.staticInFor = isInFor;
  8545. }
  8546. // For a node to qualify as a static root, it should have children that
  8547. // are not just static text. Otherwise the cost of hoisting out will
  8548. // outweigh the benefits and it's better off to just always render it fresh.
  8549. if (node.static && node.children.length && !(
  8550. node.children.length === 1 &&
  8551. node.children[0].type === 3
  8552. )) {
  8553. node.staticRoot = true;
  8554. return
  8555. } else {
  8556. node.staticRoot = false;
  8557. }
  8558. if (node.children) {
  8559. for (var i = 0, l = node.children.length; i < l; i++) {
  8560. markStaticRoots(node.children[i], isInFor || !!node.for);
  8561. }
  8562. }
  8563. if (node.ifConditions) {
  8564. walkThroughConditionsBlocks(node.ifConditions, isInFor);
  8565. }
  8566. }
  8567. }
  8568. function walkThroughConditionsBlocks (conditionBlocks, isInFor) {
  8569. for (var i = 1, len = conditionBlocks.length; i < len; i++) {
  8570. markStaticRoots(conditionBlocks[i].block, isInFor);
  8571. }
  8572. }
  8573. function isStatic (node) {
  8574. if (node.type === 2) { // expression
  8575. return false
  8576. }
  8577. if (node.type === 3) { // text
  8578. return true
  8579. }
  8580. return !!(node.pre || (
  8581. !node.hasBindings && // no dynamic bindings
  8582. !node.if && !node.for && // not v-if or v-for or v-else
  8583. !isBuiltInTag(node.tag) && // not a built-in
  8584. isPlatformReservedTag(node.tag) && // not a component
  8585. !isDirectChildOfTemplateFor(node) &&
  8586. Object.keys(node).every(isStaticKey)
  8587. ))
  8588. }
  8589. function isDirectChildOfTemplateFor (node) {
  8590. while (node.parent) {
  8591. node = node.parent;
  8592. if (node.tag !== 'template') {
  8593. return false
  8594. }
  8595. if (node.for) {
  8596. return true
  8597. }
  8598. }
  8599. return false
  8600. }
  8601. /* */
  8602. var fnExpRE = /^\s*([\w$_]+|\([^)]*?\))\s*=>|^function\s*\(/;
  8603. var simplePathRE = /^\s*[A-Za-z_$][\w$]*(?:\.[A-Za-z_$][\w$]*|\['.*?']|\[".*?"]|\[\d+]|\[[A-Za-z_$][\w$]*])*\s*$/;
  8604. // keyCode aliases
  8605. var keyCodes = {
  8606. esc: 27,
  8607. tab: 9,
  8608. enter: 13,
  8609. space: 32,
  8610. up: 38,
  8611. left: 37,
  8612. right: 39,
  8613. down: 40,
  8614. 'delete': [8, 46]
  8615. };
  8616. // #4868: modifiers that prevent the execution of the listener
  8617. // need to explicitly return null so that we can determine whether to remove
  8618. // the listener for .once
  8619. var genGuard = function (condition) { return ("if(" + condition + ")return null;"); };
  8620. var modifierCode = {
  8621. stop: '$event.stopPropagation();',
  8622. prevent: '$event.preventDefault();',
  8623. self: genGuard("$event.target !== $event.currentTarget"),
  8624. ctrl: genGuard("!$event.ctrlKey"),
  8625. shift: genGuard("!$event.shiftKey"),
  8626. alt: genGuard("!$event.altKey"),
  8627. meta: genGuard("!$event.metaKey"),
  8628. left: genGuard("'button' in $event && $event.button !== 0"),
  8629. middle: genGuard("'button' in $event && $event.button !== 1"),
  8630. right: genGuard("'button' in $event && $event.button !== 2")
  8631. };
  8632. function genHandlers (
  8633. events,
  8634. isNative,
  8635. warn
  8636. ) {
  8637. var res = isNative ? 'nativeOn:{' : 'on:{';
  8638. for (var name in events) {
  8639. var handler = events[name];
  8640. // #5330: warn click.right, since right clicks do not actually fire click events.
  8641. if (process.env.NODE_ENV !== 'production' &&
  8642. name === 'click' &&
  8643. handler && handler.modifiers && handler.modifiers.right
  8644. ) {
  8645. warn(
  8646. "Use \"contextmenu\" instead of \"click.right\" since right clicks " +
  8647. "do not actually fire \"click\" events."
  8648. );
  8649. }
  8650. res += "\"" + name + "\":" + (genHandler(name, handler)) + ",";
  8651. }
  8652. return res.slice(0, -1) + '}'
  8653. }
  8654. function genHandler (
  8655. name,
  8656. handler
  8657. ) {
  8658. if (!handler) {
  8659. return 'function(){}'
  8660. }
  8661. if (Array.isArray(handler)) {
  8662. return ("[" + (handler.map(function (handler) { return genHandler(name, handler); }).join(',')) + "]")
  8663. }
  8664. var isMethodPath = simplePathRE.test(handler.value);
  8665. var isFunctionExpression = fnExpRE.test(handler.value);
  8666. if (!handler.modifiers) {
  8667. return isMethodPath || isFunctionExpression
  8668. ? handler.value
  8669. : ("function($event){" + (handler.value) + "}") // inline statement
  8670. } else {
  8671. var code = '';
  8672. var genModifierCode = '';
  8673. var keys = [];
  8674. for (var key in handler.modifiers) {
  8675. if (modifierCode[key]) {
  8676. genModifierCode += modifierCode[key];
  8677. // left/right
  8678. if (keyCodes[key]) {
  8679. keys.push(key);
  8680. }
  8681. } else {
  8682. keys.push(key);
  8683. }
  8684. }
  8685. if (keys.length) {
  8686. code += genKeyFilter(keys);
  8687. }
  8688. // Make sure modifiers like prevent and stop get executed after key filtering
  8689. if (genModifierCode) {
  8690. code += genModifierCode;
  8691. }
  8692. var handlerCode = isMethodPath
  8693. ? handler.value + '($event)'
  8694. : isFunctionExpression
  8695. ? ("(" + (handler.value) + ")($event)")
  8696. : handler.value;
  8697. return ("function($event){" + code + handlerCode + "}")
  8698. }
  8699. }
  8700. function genKeyFilter (keys) {
  8701. return ("if(!('button' in $event)&&" + (keys.map(genFilterCode).join('&&')) + ")return null;")
  8702. }
  8703. function genFilterCode (key) {
  8704. var keyVal = parseInt(key, 10);
  8705. if (keyVal) {
  8706. return ("$event.keyCode!==" + keyVal)
  8707. }
  8708. var alias = keyCodes[key];
  8709. return ("_k($event.keyCode," + (JSON.stringify(key)) + (alias ? ',' + JSON.stringify(alias) : '') + ")")
  8710. }
  8711. /* */
  8712. function bind$1 (el, dir) {
  8713. el.wrapData = function (code) {
  8714. return ("_b(" + code + ",'" + (el.tag) + "'," + (dir.value) + (dir.modifiers && dir.modifiers.prop ? ',true' : '') + ")")
  8715. };
  8716. }
  8717. /* */
  8718. var baseDirectives = {
  8719. bind: bind$1,
  8720. cloak: noop
  8721. };
  8722. /* */
  8723. // configurable state
  8724. var warn$3;
  8725. var transforms$1;
  8726. var dataGenFns;
  8727. var platformDirectives$1;
  8728. var isPlatformReservedTag$1;
  8729. var staticRenderFns;
  8730. var onceCount;
  8731. var currentOptions;
  8732. function generate (
  8733. ast,
  8734. options
  8735. ) {
  8736. // save previous staticRenderFns so generate calls can be nested
  8737. var prevStaticRenderFns = staticRenderFns;
  8738. var currentStaticRenderFns = staticRenderFns = [];
  8739. var prevOnceCount = onceCount;
  8740. onceCount = 0;
  8741. currentOptions = options;
  8742. warn$3 = options.warn || baseWarn;
  8743. transforms$1 = pluckModuleFunction(options.modules, 'transformCode');
  8744. dataGenFns = pluckModuleFunction(options.modules, 'genData');
  8745. platformDirectives$1 = options.directives || {};
  8746. isPlatformReservedTag$1 = options.isReservedTag || no;
  8747. var code = ast ? genElement(ast) : '_c("div")';
  8748. staticRenderFns = prevStaticRenderFns;
  8749. onceCount = prevOnceCount;
  8750. return {
  8751. render: ("with(this){return " + code + "}"),
  8752. staticRenderFns: currentStaticRenderFns
  8753. }
  8754. }
  8755. function genElement (el) {
  8756. if (el.staticRoot && !el.staticProcessed) {
  8757. return genStatic(el)
  8758. } else if (el.once && !el.onceProcessed) {
  8759. return genOnce(el)
  8760. } else if (el.for && !el.forProcessed) {
  8761. return genFor(el)
  8762. } else if (el.if && !el.ifProcessed) {
  8763. return genIf(el)
  8764. } else if (el.tag === 'template' && !el.slotTarget) {
  8765. return genChildren(el) || 'void 0'
  8766. } else if (el.tag === 'slot') {
  8767. return genSlot(el)
  8768. } else {
  8769. // component or element
  8770. var code;
  8771. if (el.component) {
  8772. code = genComponent(el.component, el);
  8773. } else {
  8774. var data = el.plain ? undefined : genData(el);
  8775. var children = el.inlineTemplate ? null : genChildren(el, true);
  8776. code = "_c('" + (el.tag) + "'" + (data ? ("," + data) : '') + (children ? ("," + children) : '') + ")";
  8777. }
  8778. // module transforms
  8779. for (var i = 0; i < transforms$1.length; i++) {
  8780. code = transforms$1[i](el, code);
  8781. }
  8782. return code
  8783. }
  8784. }
  8785. // hoist static sub-trees out
  8786. function genStatic (el) {
  8787. el.staticProcessed = true;
  8788. staticRenderFns.push(("with(this){return " + (genElement(el)) + "}"));
  8789. return ("_m(" + (staticRenderFns.length - 1) + (el.staticInFor ? ',true' : '') + ")")
  8790. }
  8791. // v-once
  8792. function genOnce (el) {
  8793. el.onceProcessed = true;
  8794. if (el.if && !el.ifProcessed) {
  8795. return genIf(el)
  8796. } else if (el.staticInFor) {
  8797. var key = '';
  8798. var parent = el.parent;
  8799. while (parent) {
  8800. if (parent.for) {
  8801. key = parent.key;
  8802. break
  8803. }
  8804. parent = parent.parent;
  8805. }
  8806. if (!key) {
  8807. process.env.NODE_ENV !== 'production' && warn$3(
  8808. "v-once can only be used inside v-for that is keyed. "
  8809. );
  8810. return genElement(el)
  8811. }
  8812. return ("_o(" + (genElement(el)) + "," + (onceCount++) + (key ? ("," + key) : "") + ")")
  8813. } else {
  8814. return genStatic(el)
  8815. }
  8816. }
  8817. function genIf (el) {
  8818. el.ifProcessed = true; // avoid recursion
  8819. return genIfConditions(el.ifConditions.slice())
  8820. }
  8821. function genIfConditions (conditions) {
  8822. if (!conditions.length) {
  8823. return '_e()'
  8824. }
  8825. var condition = conditions.shift();
  8826. if (condition.exp) {
  8827. return ("(" + (condition.exp) + ")?" + (genTernaryExp(condition.block)) + ":" + (genIfConditions(conditions)))
  8828. } else {
  8829. return ("" + (genTernaryExp(condition.block)))
  8830. }
  8831. // v-if with v-once should generate code like (a)?_m(0):_m(1)
  8832. function genTernaryExp (el) {
  8833. return el.once ? genOnce(el) : genElement(el)
  8834. }
  8835. }
  8836. function genFor (el) {
  8837. var exp = el.for;
  8838. var alias = el.alias;
  8839. var iterator1 = el.iterator1 ? ("," + (el.iterator1)) : '';
  8840. var iterator2 = el.iterator2 ? ("," + (el.iterator2)) : '';
  8841. if (
  8842. process.env.NODE_ENV !== 'production' &&
  8843. maybeComponent(el) && el.tag !== 'slot' && el.tag !== 'template' && !el.key
  8844. ) {
  8845. warn$3(
  8846. "<" + (el.tag) + " v-for=\"" + alias + " in " + exp + "\">: component lists rendered with " +
  8847. "v-for should have explicit keys. " +
  8848. "See https://vuejs.org/guide/list.html#key for more info.",
  8849. true /* tip */
  8850. );
  8851. }
  8852. el.forProcessed = true; // avoid recursion
  8853. return "_l((" + exp + ")," +
  8854. "function(" + alias + iterator1 + iterator2 + "){" +
  8855. "return " + (genElement(el)) +
  8856. '})'
  8857. }
  8858. function genData (el) {
  8859. var data = '{';
  8860. // directives first.
  8861. // directives may mutate the el's other properties before they are generated.
  8862. var dirs = genDirectives(el);
  8863. if (dirs) { data += dirs + ','; }
  8864. // key
  8865. if (el.key) {
  8866. data += "key:" + (el.key) + ",";
  8867. }
  8868. // ref
  8869. if (el.ref) {
  8870. data += "ref:" + (el.ref) + ",";
  8871. }
  8872. if (el.refInFor) {
  8873. data += "refInFor:true,";
  8874. }
  8875. // pre
  8876. if (el.pre) {
  8877. data += "pre:true,";
  8878. }
  8879. // record original tag name for components using "is" attribute
  8880. if (el.component) {
  8881. data += "tag:\"" + (el.tag) + "\",";
  8882. }
  8883. // module data generation functions
  8884. for (var i = 0; i < dataGenFns.length; i++) {
  8885. data += dataGenFns[i](el);
  8886. }
  8887. // attributes
  8888. if (el.attrs) {
  8889. data += "attrs:{" + (genProps(el.attrs)) + "},";
  8890. }
  8891. // DOM props
  8892. if (el.props) {
  8893. data += "domProps:{" + (genProps(el.props)) + "},";
  8894. }
  8895. // event handlers
  8896. if (el.events) {
  8897. data += (genHandlers(el.events, false, warn$3)) + ",";
  8898. }
  8899. if (el.nativeEvents) {
  8900. data += (genHandlers(el.nativeEvents, true, warn$3)) + ",";
  8901. }
  8902. // slot target
  8903. if (el.slotTarget) {
  8904. data += "slot:" + (el.slotTarget) + ",";
  8905. }
  8906. // scoped slots
  8907. if (el.scopedSlots) {
  8908. data += (genScopedSlots(el.scopedSlots)) + ",";
  8909. }
  8910. // component v-model
  8911. if (el.model) {
  8912. data += "model:{value:" + (el.model.value) + ",callback:" + (el.model.callback) + ",expression:" + (el.model.expression) + "},";
  8913. }
  8914. // inline-template
  8915. if (el.inlineTemplate) {
  8916. var inlineTemplate = genInlineTemplate(el);
  8917. if (inlineTemplate) {
  8918. data += inlineTemplate + ",";
  8919. }
  8920. }
  8921. data = data.replace(/,$/, '') + '}';
  8922. // v-bind data wrap
  8923. if (el.wrapData) {
  8924. data = el.wrapData(data);
  8925. }
  8926. return data
  8927. }
  8928. function genDirectives (el) {
  8929. var dirs = el.directives;
  8930. if (!dirs) { return }
  8931. var res = 'directives:[';
  8932. var hasRuntime = false;
  8933. var i, l, dir, needRuntime;
  8934. for (i = 0, l = dirs.length; i < l; i++) {
  8935. dir = dirs[i];
  8936. needRuntime = true;
  8937. var gen = platformDirectives$1[dir.name] || baseDirectives[dir.name];
  8938. if (gen) {
  8939. // compile-time directive that manipulates AST.
  8940. // returns true if it also needs a runtime counterpart.
  8941. needRuntime = !!gen(el, dir, warn$3);
  8942. }
  8943. if (needRuntime) {
  8944. hasRuntime = true;
  8945. res += "{name:\"" + (dir.name) + "\",rawName:\"" + (dir.rawName) + "\"" + (dir.value ? (",value:(" + (dir.value) + "),expression:" + (JSON.stringify(dir.value))) : '') + (dir.arg ? (",arg:\"" + (dir.arg) + "\"") : '') + (dir.modifiers ? (",modifiers:" + (JSON.stringify(dir.modifiers))) : '') + "},";
  8946. }
  8947. }
  8948. if (hasRuntime) {
  8949. return res.slice(0, -1) + ']'
  8950. }
  8951. }
  8952. function genInlineTemplate (el) {
  8953. var ast = el.children[0];
  8954. if (process.env.NODE_ENV !== 'production' && (
  8955. el.children.length > 1 || ast.type !== 1
  8956. )) {
  8957. warn$3('Inline-template components must have exactly one child element.');
  8958. }
  8959. if (ast.type === 1) {
  8960. var inlineRenderFns = generate(ast, currentOptions);
  8961. return ("inlineTemplate:{render:function(){" + (inlineRenderFns.render) + "},staticRenderFns:[" + (inlineRenderFns.staticRenderFns.map(function (code) { return ("function(){" + code + "}"); }).join(',')) + "]}")
  8962. }
  8963. }
  8964. function genScopedSlots (slots) {
  8965. return ("scopedSlots:_u([" + (Object.keys(slots).map(function (key) { return genScopedSlot(key, slots[key]); }).join(',')) + "])")
  8966. }
  8967. function genScopedSlot (key, el) {
  8968. if (el.for && !el.forProcessed) {
  8969. return genForScopedSlot(key, el)
  8970. }
  8971. return "{key:" + key + ",fn:function(" + (String(el.attrsMap.scope)) + "){" +
  8972. "return " + (el.tag === 'template'
  8973. ? genChildren(el) || 'void 0'
  8974. : genElement(el)) + "}}"
  8975. }
  8976. function genForScopedSlot (key, el) {
  8977. var exp = el.for;
  8978. var alias = el.alias;
  8979. var iterator1 = el.iterator1 ? ("," + (el.iterator1)) : '';
  8980. var iterator2 = el.iterator2 ? ("," + (el.iterator2)) : '';
  8981. el.forProcessed = true; // avoid recursion
  8982. return "_l((" + exp + ")," +
  8983. "function(" + alias + iterator1 + iterator2 + "){" +
  8984. "return " + (genScopedSlot(key, el)) +
  8985. '})'
  8986. }
  8987. function genChildren (el, checkSkip) {
  8988. var children = el.children;
  8989. if (children.length) {
  8990. var el$1 = children[0];
  8991. // optimize single v-for
  8992. if (children.length === 1 &&
  8993. el$1.for &&
  8994. el$1.tag !== 'template' &&
  8995. el$1.tag !== 'slot'
  8996. ) {
  8997. return genElement(el$1)
  8998. }
  8999. var normalizationType = checkSkip ? getNormalizationType(children) : 0;
  9000. return ("[" + (children.map(genNode).join(',')) + "]" + (normalizationType ? ("," + normalizationType) : ''))
  9001. }
  9002. }
  9003. // determine the normalization needed for the children array.
  9004. // 0: no normalization needed
  9005. // 1: simple normalization needed (possible 1-level deep nested array)
  9006. // 2: full normalization needed
  9007. function getNormalizationType (children) {
  9008. var res = 0;
  9009. for (var i = 0; i < children.length; i++) {
  9010. var el = children[i];
  9011. if (el.type !== 1) {
  9012. continue
  9013. }
  9014. if (needsNormalization(el) ||
  9015. (el.ifConditions && el.ifConditions.some(function (c) { return needsNormalization(c.block); }))) {
  9016. res = 2;
  9017. break
  9018. }
  9019. if (maybeComponent(el) ||
  9020. (el.ifConditions && el.ifConditions.some(function (c) { return maybeComponent(c.block); }))) {
  9021. res = 1;
  9022. }
  9023. }
  9024. return res
  9025. }
  9026. function needsNormalization (el) {
  9027. return el.for !== undefined || el.tag === 'template' || el.tag === 'slot'
  9028. }
  9029. function maybeComponent (el) {
  9030. return !isPlatformReservedTag$1(el.tag)
  9031. }
  9032. function genNode (node) {
  9033. if (node.type === 1) {
  9034. return genElement(node)
  9035. } else {
  9036. return genText(node)
  9037. }
  9038. }
  9039. function genText (text) {
  9040. return ("_v(" + (text.type === 2
  9041. ? text.expression // no need for () because already wrapped in _s()
  9042. : transformSpecialNewlines(JSON.stringify(text.text))) + ")")
  9043. }
  9044. function genSlot (el) {
  9045. var slotName = el.slotName || '"default"';
  9046. var children = genChildren(el);
  9047. var res = "_t(" + slotName + (children ? ("," + children) : '');
  9048. var attrs = el.attrs && ("{" + (el.attrs.map(function (a) { return ((camelize(a.name)) + ":" + (a.value)); }).join(',')) + "}");
  9049. var bind$$1 = el.attrsMap['v-bind'];
  9050. if ((attrs || bind$$1) && !children) {
  9051. res += ",null";
  9052. }
  9053. if (attrs) {
  9054. res += "," + attrs;
  9055. }
  9056. if (bind$$1) {
  9057. res += (attrs ? '' : ',null') + "," + bind$$1;
  9058. }
  9059. return res + ')'
  9060. }
  9061. // componentName is el.component, take it as argument to shun flow's pessimistic refinement
  9062. function genComponent (componentName, el) {
  9063. var children = el.inlineTemplate ? null : genChildren(el, true);
  9064. return ("_c(" + componentName + "," + (genData(el)) + (children ? ("," + children) : '') + ")")
  9065. }
  9066. function genProps (props) {
  9067. var res = '';
  9068. for (var i = 0; i < props.length; i++) {
  9069. var prop = props[i];
  9070. res += "\"" + (prop.name) + "\":" + (transformSpecialNewlines(prop.value)) + ",";
  9071. }
  9072. return res.slice(0, -1)
  9073. }
  9074. // #3895, #4268
  9075. function transformSpecialNewlines (text) {
  9076. return text
  9077. .replace(/\u2028/g, '\\u2028')
  9078. .replace(/\u2029/g, '\\u2029')
  9079. }
  9080. /* */
  9081. // these keywords should not appear inside expressions, but operators like
  9082. // typeof, instanceof and in are allowed
  9083. var prohibitedKeywordRE = new RegExp('\\b' + (
  9084. 'do,if,for,let,new,try,var,case,else,with,await,break,catch,class,const,' +
  9085. 'super,throw,while,yield,delete,export,import,return,switch,default,' +
  9086. 'extends,finally,continue,debugger,function,arguments'
  9087. ).split(',').join('\\b|\\b') + '\\b');
  9088. // these unary operators should not be used as property/method names
  9089. var unaryOperatorsRE = new RegExp('\\b' + (
  9090. 'delete,typeof,void'
  9091. ).split(',').join('\\s*\\([^\\)]*\\)|\\b') + '\\s*\\([^\\)]*\\)');
  9092. // check valid identifier for v-for
  9093. var identRE = /[A-Za-z_$][\w$]*/;
  9094. // strip strings in expressions
  9095. var stripStringRE = /'(?:[^'\\]|\\.)*'|"(?:[^"\\]|\\.)*"|`(?:[^`\\]|\\.)*\$\{|\}(?:[^`\\]|\\.)*`|`(?:[^`\\]|\\.)*`/g;
  9096. // detect problematic expressions in a template
  9097. function detectErrors (ast) {
  9098. var errors = [];
  9099. if (ast) {
  9100. checkNode(ast, errors);
  9101. }
  9102. return errors
  9103. }
  9104. function checkNode (node, errors) {
  9105. if (node.type === 1) {
  9106. for (var name in node.attrsMap) {
  9107. if (dirRE.test(name)) {
  9108. var value = node.attrsMap[name];
  9109. if (value) {
  9110. if (name === 'v-for') {
  9111. checkFor(node, ("v-for=\"" + value + "\""), errors);
  9112. } else if (onRE.test(name)) {
  9113. checkEvent(value, (name + "=\"" + value + "\""), errors);
  9114. } else {
  9115. checkExpression(value, (name + "=\"" + value + "\""), errors);
  9116. }
  9117. }
  9118. }
  9119. }
  9120. if (node.children) {
  9121. for (var i = 0; i < node.children.length; i++) {
  9122. checkNode(node.children[i], errors);
  9123. }
  9124. }
  9125. } else if (node.type === 2) {
  9126. checkExpression(node.expression, node.text, errors);
  9127. }
  9128. }
  9129. function checkEvent (exp, text, errors) {
  9130. var stipped = exp.replace(stripStringRE, '');
  9131. var keywordMatch = stipped.match(unaryOperatorsRE);
  9132. if (keywordMatch && stipped.charAt(keywordMatch.index - 1) !== '$') {
  9133. errors.push(
  9134. "avoid using JavaScript unary operator as property name: " +
  9135. "\"" + (keywordMatch[0]) + "\" in expression " + (text.trim())
  9136. );
  9137. }
  9138. checkExpression(exp, text, errors);
  9139. }
  9140. function checkFor (node, text, errors) {
  9141. checkExpression(node.for || '', text, errors);
  9142. checkIdentifier(node.alias, 'v-for alias', text, errors);
  9143. checkIdentifier(node.iterator1, 'v-for iterator', text, errors);
  9144. checkIdentifier(node.iterator2, 'v-for iterator', text, errors);
  9145. }
  9146. function checkIdentifier (ident, type, text, errors) {
  9147. if (typeof ident === 'string' && !identRE.test(ident)) {
  9148. errors.push(("invalid " + type + " \"" + ident + "\" in expression: " + (text.trim())));
  9149. }
  9150. }
  9151. function checkExpression (exp, text, errors) {
  9152. try {
  9153. new Function(("return " + exp));
  9154. } catch (e) {
  9155. var keywordMatch = exp.replace(stripStringRE, '').match(prohibitedKeywordRE);
  9156. if (keywordMatch) {
  9157. errors.push(
  9158. "avoid using JavaScript keyword as property name: " +
  9159. "\"" + (keywordMatch[0]) + "\" in expression " + (text.trim())
  9160. );
  9161. } else {
  9162. errors.push(("invalid expression: " + (text.trim())));
  9163. }
  9164. }
  9165. }
  9166. /* */
  9167. function baseCompile (
  9168. template,
  9169. options
  9170. ) {
  9171. var ast = parse(template.trim(), options);
  9172. optimize(ast, options);
  9173. var code = generate(ast, options);
  9174. return {
  9175. ast: ast,
  9176. render: code.render,
  9177. staticRenderFns: code.staticRenderFns
  9178. }
  9179. }
  9180. function makeFunction (code, errors) {
  9181. try {
  9182. return new Function(code)
  9183. } catch (err) {
  9184. errors.push({ err: err, code: code });
  9185. return noop
  9186. }
  9187. }
  9188. function createCompiler (baseOptions) {
  9189. var functionCompileCache = Object.create(null);
  9190. function compile (
  9191. template,
  9192. options
  9193. ) {
  9194. var finalOptions = Object.create(baseOptions);
  9195. var errors = [];
  9196. var tips = [];
  9197. finalOptions.warn = function (msg, tip$$1) {
  9198. (tip$$1 ? tips : errors).push(msg);
  9199. };
  9200. if (options) {
  9201. // merge custom modules
  9202. if (options.modules) {
  9203. finalOptions.modules = (baseOptions.modules || []).concat(options.modules);
  9204. }
  9205. // merge custom directives
  9206. if (options.directives) {
  9207. finalOptions.directives = extend(
  9208. Object.create(baseOptions.directives),
  9209. options.directives
  9210. );
  9211. }
  9212. // copy other options
  9213. for (var key in options) {
  9214. if (key !== 'modules' && key !== 'directives') {
  9215. finalOptions[key] = options[key];
  9216. }
  9217. }
  9218. }
  9219. var compiled = baseCompile(template, finalOptions);
  9220. if (process.env.NODE_ENV !== 'production') {
  9221. errors.push.apply(errors, detectErrors(compiled.ast));
  9222. }
  9223. compiled.errors = errors;
  9224. compiled.tips = tips;
  9225. return compiled
  9226. }
  9227. function compileToFunctions (
  9228. template,
  9229. options,
  9230. vm
  9231. ) {
  9232. options = options || {};
  9233. /* istanbul ignore if */
  9234. if (process.env.NODE_ENV !== 'production') {
  9235. // detect possible CSP restriction
  9236. try {
  9237. new Function('return 1');
  9238. } catch (e) {
  9239. if (e.toString().match(/unsafe-eval|CSP/)) {
  9240. warn(
  9241. 'It seems you are using the standalone build of Vue.js in an ' +
  9242. 'environment with Content Security Policy that prohibits unsafe-eval. ' +
  9243. 'The template compiler cannot work in this environment. Consider ' +
  9244. 'relaxing the policy to allow unsafe-eval or pre-compiling your ' +
  9245. 'templates into render functions.'
  9246. );
  9247. }
  9248. }
  9249. }
  9250. // check cache
  9251. var key = options.delimiters
  9252. ? String(options.delimiters) + template
  9253. : template;
  9254. if (functionCompileCache[key]) {
  9255. return functionCompileCache[key]
  9256. }
  9257. // compile
  9258. var compiled = compile(template, options);
  9259. // check compilation errors/tips
  9260. if (process.env.NODE_ENV !== 'production') {
  9261. if (compiled.errors && compiled.errors.length) {
  9262. warn(
  9263. "Error compiling template:\n\n" + template + "\n\n" +
  9264. compiled.errors.map(function (e) { return ("- " + e); }).join('\n') + '\n',
  9265. vm
  9266. );
  9267. }
  9268. if (compiled.tips && compiled.tips.length) {
  9269. compiled.tips.forEach(function (msg) { return tip(msg, vm); });
  9270. }
  9271. }
  9272. // turn code into functions
  9273. var res = {};
  9274. var fnGenErrors = [];
  9275. res.render = makeFunction(compiled.render, fnGenErrors);
  9276. var l = compiled.staticRenderFns.length;
  9277. res.staticRenderFns = new Array(l);
  9278. for (var i = 0; i < l; i++) {
  9279. res.staticRenderFns[i] = makeFunction(compiled.staticRenderFns[i], fnGenErrors);
  9280. }
  9281. // check function generation errors.
  9282. // this should only happen if there is a bug in the compiler itself.
  9283. // mostly for codegen development use
  9284. /* istanbul ignore if */
  9285. if (process.env.NODE_ENV !== 'production') {
  9286. if ((!compiled.errors || !compiled.errors.length) && fnGenErrors.length) {
  9287. warn(
  9288. "Failed to generate render function:\n\n" +
  9289. fnGenErrors.map(function (ref) {
  9290. var err = ref.err;
  9291. var code = ref.code;
  9292. return ((err.toString()) + " in\n\n" + code + "\n");
  9293. }).join('\n'),
  9294. vm
  9295. );
  9296. }
  9297. }
  9298. return (functionCompileCache[key] = res)
  9299. }
  9300. return {
  9301. compile: compile,
  9302. compileToFunctions: compileToFunctions
  9303. }
  9304. }
  9305. /* */
  9306. function transformNode (el, options) {
  9307. var warn = options.warn || baseWarn;
  9308. var staticClass = getAndRemoveAttr(el, 'class');
  9309. if (process.env.NODE_ENV !== 'production' && staticClass) {
  9310. var expression = parseText(staticClass, options.delimiters);
  9311. if (expression) {
  9312. warn(
  9313. "class=\"" + staticClass + "\": " +
  9314. 'Interpolation inside attributes has been removed. ' +
  9315. 'Use v-bind or the colon shorthand instead. For example, ' +
  9316. 'instead of <div class="{{ val }}">, use <div :class="val">.'
  9317. );
  9318. }
  9319. }
  9320. if (staticClass) {
  9321. el.staticClass = JSON.stringify(staticClass);
  9322. }
  9323. var classBinding = getBindingAttr(el, 'class', false /* getStatic */);
  9324. if (classBinding) {
  9325. el.classBinding = classBinding;
  9326. }
  9327. }
  9328. function genData$1 (el) {
  9329. var data = '';
  9330. if (el.staticClass) {
  9331. data += "staticClass:" + (el.staticClass) + ",";
  9332. }
  9333. if (el.classBinding) {
  9334. data += "class:" + (el.classBinding) + ",";
  9335. }
  9336. return data
  9337. }
  9338. var klass$1 = {
  9339. staticKeys: ['staticClass'],
  9340. transformNode: transformNode,
  9341. genData: genData$1
  9342. };
  9343. /* */
  9344. function transformNode$1 (el, options) {
  9345. var warn = options.warn || baseWarn;
  9346. var staticStyle = getAndRemoveAttr(el, 'style');
  9347. if (staticStyle) {
  9348. /* istanbul ignore if */
  9349. if (process.env.NODE_ENV !== 'production') {
  9350. var expression = parseText(staticStyle, options.delimiters);
  9351. if (expression) {
  9352. warn(
  9353. "style=\"" + staticStyle + "\": " +
  9354. 'Interpolation inside attributes has been removed. ' +
  9355. 'Use v-bind or the colon shorthand instead. For example, ' +
  9356. 'instead of <div style="{{ val }}">, use <div :style="val">.'
  9357. );
  9358. }
  9359. }
  9360. el.staticStyle = JSON.stringify(parseStyleText(staticStyle));
  9361. }
  9362. var styleBinding = getBindingAttr(el, 'style', false /* getStatic */);
  9363. if (styleBinding) {
  9364. el.styleBinding = styleBinding;
  9365. }
  9366. }
  9367. function genData$2 (el) {
  9368. var data = '';
  9369. if (el.staticStyle) {
  9370. data += "staticStyle:" + (el.staticStyle) + ",";
  9371. }
  9372. if (el.styleBinding) {
  9373. data += "style:(" + (el.styleBinding) + "),";
  9374. }
  9375. return data
  9376. }
  9377. var style$1 = {
  9378. staticKeys: ['staticStyle'],
  9379. transformNode: transformNode$1,
  9380. genData: genData$2
  9381. };
  9382. var modules$1 = [
  9383. klass$1,
  9384. style$1
  9385. ];
  9386. /* */
  9387. function text (el, dir) {
  9388. if (dir.value) {
  9389. addProp(el, 'textContent', ("_s(" + (dir.value) + ")"));
  9390. }
  9391. }
  9392. /* */
  9393. function html (el, dir) {
  9394. if (dir.value) {
  9395. addProp(el, 'innerHTML', ("_s(" + (dir.value) + ")"));
  9396. }
  9397. }
  9398. var directives$1 = {
  9399. model: model,
  9400. text: text,
  9401. html: html
  9402. };
  9403. /* */
  9404. var baseOptions = {
  9405. expectHTML: true,
  9406. modules: modules$1,
  9407. directives: directives$1,
  9408. isPreTag: isPreTag,
  9409. isUnaryTag: isUnaryTag,
  9410. mustUseProp: mustUseProp,
  9411. canBeLeftOpenTag: canBeLeftOpenTag,
  9412. isReservedTag: isReservedTag,
  9413. getTagNamespace: getTagNamespace,
  9414. staticKeys: genStaticKeys(modules$1)
  9415. };
  9416. var ref$1 = createCompiler(baseOptions);
  9417. var compileToFunctions = ref$1.compileToFunctions;
  9418. /* */
  9419. var idToTemplate = cached(function (id) {
  9420. var el = query(id);
  9421. return el && el.innerHTML
  9422. });
  9423. var mount = Vue$3.prototype.$mount;
  9424. Vue$3.prototype.$mount = function (
  9425. el,
  9426. hydrating
  9427. ) {
  9428. el = el && query(el);
  9429. /* istanbul ignore if */
  9430. if (el === document.body || el === document.documentElement) {
  9431. process.env.NODE_ENV !== 'production' && warn(
  9432. "Do not mount Vue to <html> or <body> - mount to normal elements instead."
  9433. );
  9434. return this
  9435. }
  9436. var options = this.$options;
  9437. // resolve template/el and convert to render function
  9438. if (!options.render) {
  9439. var template = options.template;
  9440. if (template) {
  9441. if (typeof template === 'string') {
  9442. if (template.charAt(0) === '#') {
  9443. template = idToTemplate(template);
  9444. /* istanbul ignore if */
  9445. if (process.env.NODE_ENV !== 'production' && !template) {
  9446. warn(
  9447. ("Template element not found or is empty: " + (options.template)),
  9448. this
  9449. );
  9450. }
  9451. }
  9452. } else if (template.nodeType) {
  9453. template = template.innerHTML;
  9454. } else {
  9455. if (process.env.NODE_ENV !== 'production') {
  9456. warn('invalid template option:' + template, this);
  9457. }
  9458. return this
  9459. }
  9460. } else if (el) {
  9461. template = getOuterHTML(el);
  9462. }
  9463. if (template) {
  9464. /* istanbul ignore if */
  9465. if (process.env.NODE_ENV !== 'production' && config.performance && mark) {
  9466. mark('compile');
  9467. }
  9468. var ref = compileToFunctions(template, {
  9469. shouldDecodeNewlines: shouldDecodeNewlines,
  9470. delimiters: options.delimiters
  9471. }, this);
  9472. var render = ref.render;
  9473. var staticRenderFns = ref.staticRenderFns;
  9474. options.render = render;
  9475. options.staticRenderFns = staticRenderFns;
  9476. /* istanbul ignore if */
  9477. if (process.env.NODE_ENV !== 'production' && config.performance && mark) {
  9478. mark('compile end');
  9479. measure(((this._name) + " compile"), 'compile', 'compile end');
  9480. }
  9481. }
  9482. }
  9483. return mount.call(this, el, hydrating)
  9484. };
  9485. /**
  9486. * Get outerHTML of elements, taking care
  9487. * of SVG elements in IE as well.
  9488. */
  9489. function getOuterHTML (el) {
  9490. if (el.outerHTML) {
  9491. return el.outerHTML
  9492. } else {
  9493. var container = document.createElement('div');
  9494. container.appendChild(el.cloneNode(true));
  9495. return container.innerHTML
  9496. }
  9497. }
  9498. Vue$3.compile = compileToFunctions;
  9499. module.exports = Vue$3;
  9500. }).call(this,require('_process'),typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  9501. },{"_process":1}],8:[function(require,module,exports){
  9502. (function (process,global){
  9503. /*!
  9504. * Vue.js v2.3.3
  9505. * (c) 2014-2017 Evan You
  9506. * Released under the MIT License.
  9507. */
  9508. 'use strict';
  9509. /* */
  9510. // these helpers produces better vm code in JS engines due to their
  9511. // explicitness and function inlining
  9512. function isUndef (v) {
  9513. return v === undefined || v === null
  9514. }
  9515. function isDef (v) {
  9516. return v !== undefined && v !== null
  9517. }
  9518. function isTrue (v) {
  9519. return v === true
  9520. }
  9521. function isFalse (v) {
  9522. return v === false
  9523. }
  9524. /**
  9525. * Check if value is primitive
  9526. */
  9527. function isPrimitive (value) {
  9528. return typeof value === 'string' || typeof value === 'number'
  9529. }
  9530. /**
  9531. * Quick object check - this is primarily used to tell
  9532. * Objects from primitive values when we know the value
  9533. * is a JSON-compliant type.
  9534. */
  9535. function isObject (obj) {
  9536. return obj !== null && typeof obj === 'object'
  9537. }
  9538. var _toString = Object.prototype.toString;
  9539. /**
  9540. * Strict object type check. Only returns true
  9541. * for plain JavaScript objects.
  9542. */
  9543. function isPlainObject (obj) {
  9544. return _toString.call(obj) === '[object Object]'
  9545. }
  9546. function isRegExp (v) {
  9547. return _toString.call(v) === '[object RegExp]'
  9548. }
  9549. /**
  9550. * Convert a value to a string that is actually rendered.
  9551. */
  9552. function toString (val) {
  9553. return val == null
  9554. ? ''
  9555. : typeof val === 'object'
  9556. ? JSON.stringify(val, null, 2)
  9557. : String(val)
  9558. }
  9559. /**
  9560. * Convert a input value to a number for persistence.
  9561. * If the conversion fails, return original string.
  9562. */
  9563. function toNumber (val) {
  9564. var n = parseFloat(val);
  9565. return isNaN(n) ? val : n
  9566. }
  9567. /**
  9568. * Make a map and return a function for checking if a key
  9569. * is in that map.
  9570. */
  9571. function makeMap (
  9572. str,
  9573. expectsLowerCase
  9574. ) {
  9575. var map = Object.create(null);
  9576. var list = str.split(',');
  9577. for (var i = 0; i < list.length; i++) {
  9578. map[list[i]] = true;
  9579. }
  9580. return expectsLowerCase
  9581. ? function (val) { return map[val.toLowerCase()]; }
  9582. : function (val) { return map[val]; }
  9583. }
  9584. /**
  9585. * Check if a tag is a built-in tag.
  9586. */
  9587. var isBuiltInTag = makeMap('slot,component', true);
  9588. /**
  9589. * Remove an item from an array
  9590. */
  9591. function remove (arr, item) {
  9592. if (arr.length) {
  9593. var index = arr.indexOf(item);
  9594. if (index > -1) {
  9595. return arr.splice(index, 1)
  9596. }
  9597. }
  9598. }
  9599. /**
  9600. * Check whether the object has the property.
  9601. */
  9602. var hasOwnProperty = Object.prototype.hasOwnProperty;
  9603. function hasOwn (obj, key) {
  9604. return hasOwnProperty.call(obj, key)
  9605. }
  9606. /**
  9607. * Create a cached version of a pure function.
  9608. */
  9609. function cached (fn) {
  9610. var cache = Object.create(null);
  9611. return (function cachedFn (str) {
  9612. var hit = cache[str];
  9613. return hit || (cache[str] = fn(str))
  9614. })
  9615. }
  9616. /**
  9617. * Camelize a hyphen-delimited string.
  9618. */
  9619. var camelizeRE = /-(\w)/g;
  9620. var camelize = cached(function (str) {
  9621. return str.replace(camelizeRE, function (_, c) { return c ? c.toUpperCase() : ''; })
  9622. });
  9623. /**
  9624. * Capitalize a string.
  9625. */
  9626. var capitalize = cached(function (str) {
  9627. return str.charAt(0).toUpperCase() + str.slice(1)
  9628. });
  9629. /**
  9630. * Hyphenate a camelCase string.
  9631. */
  9632. var hyphenateRE = /([^-])([A-Z])/g;
  9633. var hyphenate = cached(function (str) {
  9634. return str
  9635. .replace(hyphenateRE, '$1-$2')
  9636. .replace(hyphenateRE, '$1-$2')
  9637. .toLowerCase()
  9638. });
  9639. /**
  9640. * Simple bind, faster than native
  9641. */
  9642. function bind (fn, ctx) {
  9643. function boundFn (a) {
  9644. var l = arguments.length;
  9645. return l
  9646. ? l > 1
  9647. ? fn.apply(ctx, arguments)
  9648. : fn.call(ctx, a)
  9649. : fn.call(ctx)
  9650. }
  9651. // record original fn length
  9652. boundFn._length = fn.length;
  9653. return boundFn
  9654. }
  9655. /**
  9656. * Convert an Array-like object to a real Array.
  9657. */
  9658. function toArray (list, start) {
  9659. start = start || 0;
  9660. var i = list.length - start;
  9661. var ret = new Array(i);
  9662. while (i--) {
  9663. ret[i] = list[i + start];
  9664. }
  9665. return ret
  9666. }
  9667. /**
  9668. * Mix properties into target object.
  9669. */
  9670. function extend (to, _from) {
  9671. for (var key in _from) {
  9672. to[key] = _from[key];
  9673. }
  9674. return to
  9675. }
  9676. /**
  9677. * Merge an Array of Objects into a single Object.
  9678. */
  9679. function toObject (arr) {
  9680. var res = {};
  9681. for (var i = 0; i < arr.length; i++) {
  9682. if (arr[i]) {
  9683. extend(res, arr[i]);
  9684. }
  9685. }
  9686. return res
  9687. }
  9688. /**
  9689. * Perform no operation.
  9690. */
  9691. function noop () {}
  9692. /**
  9693. * Always return false.
  9694. */
  9695. var no = function () { return false; };
  9696. /**
  9697. * Return same value
  9698. */
  9699. var identity = function (_) { return _; };
  9700. /**
  9701. * Generate a static keys string from compiler modules.
  9702. */
  9703. /**
  9704. * Check if two values are loosely equal - that is,
  9705. * if they are plain objects, do they have the same shape?
  9706. */
  9707. function looseEqual (a, b) {
  9708. var isObjectA = isObject(a);
  9709. var isObjectB = isObject(b);
  9710. if (isObjectA && isObjectB) {
  9711. try {
  9712. return JSON.stringify(a) === JSON.stringify(b)
  9713. } catch (e) {
  9714. // possible circular reference
  9715. return a === b
  9716. }
  9717. } else if (!isObjectA && !isObjectB) {
  9718. return String(a) === String(b)
  9719. } else {
  9720. return false
  9721. }
  9722. }
  9723. function looseIndexOf (arr, val) {
  9724. for (var i = 0; i < arr.length; i++) {
  9725. if (looseEqual(arr[i], val)) { return i }
  9726. }
  9727. return -1
  9728. }
  9729. /**
  9730. * Ensure a function is called only once.
  9731. */
  9732. function once (fn) {
  9733. var called = false;
  9734. return function () {
  9735. if (!called) {
  9736. called = true;
  9737. fn.apply(this, arguments);
  9738. }
  9739. }
  9740. }
  9741. var SSR_ATTR = 'data-server-rendered';
  9742. var ASSET_TYPES = [
  9743. 'component',
  9744. 'directive',
  9745. 'filter'
  9746. ];
  9747. var LIFECYCLE_HOOKS = [
  9748. 'beforeCreate',
  9749. 'created',
  9750. 'beforeMount',
  9751. 'mounted',
  9752. 'beforeUpdate',
  9753. 'updated',
  9754. 'beforeDestroy',
  9755. 'destroyed',
  9756. 'activated',
  9757. 'deactivated'
  9758. ];
  9759. /* */
  9760. var config = ({
  9761. /**
  9762. * Option merge strategies (used in core/util/options)
  9763. */
  9764. optionMergeStrategies: Object.create(null),
  9765. /**
  9766. * Whether to suppress warnings.
  9767. */
  9768. silent: false,
  9769. /**
  9770. * Show production mode tip message on boot?
  9771. */
  9772. productionTip: process.env.NODE_ENV !== 'production',
  9773. /**
  9774. * Whether to enable devtools
  9775. */
  9776. devtools: process.env.NODE_ENV !== 'production',
  9777. /**
  9778. * Whether to record perf
  9779. */
  9780. performance: false,
  9781. /**
  9782. * Error handler for watcher errors
  9783. */
  9784. errorHandler: null,
  9785. /**
  9786. * Ignore certain custom elements
  9787. */
  9788. ignoredElements: [],
  9789. /**
  9790. * Custom user key aliases for v-on
  9791. */
  9792. keyCodes: Object.create(null),
  9793. /**
  9794. * Check if a tag is reserved so that it cannot be registered as a
  9795. * component. This is platform-dependent and may be overwritten.
  9796. */
  9797. isReservedTag: no,
  9798. /**
  9799. * Check if an attribute is reserved so that it cannot be used as a component
  9800. * prop. This is platform-dependent and may be overwritten.
  9801. */
  9802. isReservedAttr: no,
  9803. /**
  9804. * Check if a tag is an unknown element.
  9805. * Platform-dependent.
  9806. */
  9807. isUnknownElement: no,
  9808. /**
  9809. * Get the namespace of an element
  9810. */
  9811. getTagNamespace: noop,
  9812. /**
  9813. * Parse the real tag name for the specific platform.
  9814. */
  9815. parsePlatformTagName: identity,
  9816. /**
  9817. * Check if an attribute must be bound using property, e.g. value
  9818. * Platform-dependent.
  9819. */
  9820. mustUseProp: no,
  9821. /**
  9822. * Exposed for legacy reasons
  9823. */
  9824. _lifecycleHooks: LIFECYCLE_HOOKS
  9825. });
  9826. /* */
  9827. var emptyObject = Object.freeze({});
  9828. /**
  9829. * Check if a string starts with $ or _
  9830. */
  9831. function isReserved (str) {
  9832. var c = (str + '').charCodeAt(0);
  9833. return c === 0x24 || c === 0x5F
  9834. }
  9835. /**
  9836. * Define a property.
  9837. */
  9838. function def (obj, key, val, enumerable) {
  9839. Object.defineProperty(obj, key, {
  9840. value: val,
  9841. enumerable: !!enumerable,
  9842. writable: true,
  9843. configurable: true
  9844. });
  9845. }
  9846. /**
  9847. * Parse simple path.
  9848. */
  9849. var bailRE = /[^\w.$]/;
  9850. function parsePath (path) {
  9851. if (bailRE.test(path)) {
  9852. return
  9853. }
  9854. var segments = path.split('.');
  9855. return function (obj) {
  9856. for (var i = 0; i < segments.length; i++) {
  9857. if (!obj) { return }
  9858. obj = obj[segments[i]];
  9859. }
  9860. return obj
  9861. }
  9862. }
  9863. /* */
  9864. var warn = noop;
  9865. var tip = noop;
  9866. var formatComponentName = (null); // work around flow check
  9867. if (process.env.NODE_ENV !== 'production') {
  9868. var hasConsole = typeof console !== 'undefined';
  9869. var classifyRE = /(?:^|[-_])(\w)/g;
  9870. var classify = function (str) { return str
  9871. .replace(classifyRE, function (c) { return c.toUpperCase(); })
  9872. .replace(/[-_]/g, ''); };
  9873. warn = function (msg, vm) {
  9874. if (hasConsole && (!config.silent)) {
  9875. console.error("[Vue warn]: " + msg + (
  9876. vm ? generateComponentTrace(vm) : ''
  9877. ));
  9878. }
  9879. };
  9880. tip = function (msg, vm) {
  9881. if (hasConsole && (!config.silent)) {
  9882. console.warn("[Vue tip]: " + msg + (
  9883. vm ? generateComponentTrace(vm) : ''
  9884. ));
  9885. }
  9886. };
  9887. formatComponentName = function (vm, includeFile) {
  9888. if (vm.$root === vm) {
  9889. return '<Root>'
  9890. }
  9891. var name = typeof vm === 'string'
  9892. ? vm
  9893. : typeof vm === 'function' && vm.options
  9894. ? vm.options.name
  9895. : vm._isVue
  9896. ? vm.$options.name || vm.$options._componentTag
  9897. : vm.name;
  9898. var file = vm._isVue && vm.$options.__file;
  9899. if (!name && file) {
  9900. var match = file.match(/([^/\\]+)\.vue$/);
  9901. name = match && match[1];
  9902. }
  9903. return (
  9904. (name ? ("<" + (classify(name)) + ">") : "<Anonymous>") +
  9905. (file && includeFile !== false ? (" at " + file) : '')
  9906. )
  9907. };
  9908. var repeat = function (str, n) {
  9909. var res = '';
  9910. while (n) {
  9911. if (n % 2 === 1) { res += str; }
  9912. if (n > 1) { str += str; }
  9913. n >>= 1;
  9914. }
  9915. return res
  9916. };
  9917. var generateComponentTrace = function (vm) {
  9918. if (vm._isVue && vm.$parent) {
  9919. var tree = [];
  9920. var currentRecursiveSequence = 0;
  9921. while (vm) {
  9922. if (tree.length > 0) {
  9923. var last = tree[tree.length - 1];
  9924. if (last.constructor === vm.constructor) {
  9925. currentRecursiveSequence++;
  9926. vm = vm.$parent;
  9927. continue
  9928. } else if (currentRecursiveSequence > 0) {
  9929. tree[tree.length - 1] = [last, currentRecursiveSequence];
  9930. currentRecursiveSequence = 0;
  9931. }
  9932. }
  9933. tree.push(vm);
  9934. vm = vm.$parent;
  9935. }
  9936. return '\n\nfound in\n\n' + tree
  9937. .map(function (vm, i) { return ("" + (i === 0 ? '---> ' : repeat(' ', 5 + i * 2)) + (Array.isArray(vm)
  9938. ? ((formatComponentName(vm[0])) + "... (" + (vm[1]) + " recursive calls)")
  9939. : formatComponentName(vm))); })
  9940. .join('\n')
  9941. } else {
  9942. return ("\n\n(found in " + (formatComponentName(vm)) + ")")
  9943. }
  9944. };
  9945. }
  9946. /* */
  9947. function handleError (err, vm, info) {
  9948. if (config.errorHandler) {
  9949. config.errorHandler.call(null, err, vm, info);
  9950. } else {
  9951. if (process.env.NODE_ENV !== 'production') {
  9952. warn(("Error in " + info + ": \"" + (err.toString()) + "\""), vm);
  9953. }
  9954. /* istanbul ignore else */
  9955. if (inBrowser && typeof console !== 'undefined') {
  9956. console.error(err);
  9957. } else {
  9958. throw err
  9959. }
  9960. }
  9961. }
  9962. /* */
  9963. /* globals MutationObserver */
  9964. // can we use __proto__?
  9965. var hasProto = '__proto__' in {};
  9966. // Browser environment sniffing
  9967. var inBrowser = typeof window !== 'undefined';
  9968. var UA = inBrowser && window.navigator.userAgent.toLowerCase();
  9969. var isIE = UA && /msie|trident/.test(UA);
  9970. var isIE9 = UA && UA.indexOf('msie 9.0') > 0;
  9971. var isEdge = UA && UA.indexOf('edge/') > 0;
  9972. var isAndroid = UA && UA.indexOf('android') > 0;
  9973. var isIOS = UA && /iphone|ipad|ipod|ios/.test(UA);
  9974. var isChrome = UA && /chrome\/\d+/.test(UA) && !isEdge;
  9975. var supportsPassive = false;
  9976. if (inBrowser) {
  9977. try {
  9978. var opts = {};
  9979. Object.defineProperty(opts, 'passive', ({
  9980. get: function get () {
  9981. /* istanbul ignore next */
  9982. supportsPassive = true;
  9983. }
  9984. } )); // https://github.com/facebook/flow/issues/285
  9985. window.addEventListener('test-passive', null, opts);
  9986. } catch (e) {}
  9987. }
  9988. // this needs to be lazy-evaled because vue may be required before
  9989. // vue-server-renderer can set VUE_ENV
  9990. var _isServer;
  9991. var isServerRendering = function () {
  9992. if (_isServer === undefined) {
  9993. /* istanbul ignore if */
  9994. if (!inBrowser && typeof global !== 'undefined') {
  9995. // detect presence of vue-server-renderer and avoid
  9996. // Webpack shimming the process
  9997. _isServer = global['process'].env.VUE_ENV === 'server';
  9998. } else {
  9999. _isServer = false;
  10000. }
  10001. }
  10002. return _isServer
  10003. };
  10004. // detect devtools
  10005. var devtools = inBrowser && window.__VUE_DEVTOOLS_GLOBAL_HOOK__;
  10006. /* istanbul ignore next */
  10007. function isNative (Ctor) {
  10008. return typeof Ctor === 'function' && /native code/.test(Ctor.toString())
  10009. }
  10010. var hasSymbol =
  10011. typeof Symbol !== 'undefined' && isNative(Symbol) &&
  10012. typeof Reflect !== 'undefined' && isNative(Reflect.ownKeys);
  10013. /**
  10014. * Defer a task to execute it asynchronously.
  10015. */
  10016. var nextTick = (function () {
  10017. var callbacks = [];
  10018. var pending = false;
  10019. var timerFunc;
  10020. function nextTickHandler () {
  10021. pending = false;
  10022. var copies = callbacks.slice(0);
  10023. callbacks.length = 0;
  10024. for (var i = 0; i < copies.length; i++) {
  10025. copies[i]();
  10026. }
  10027. }
  10028. // the nextTick behavior leverages the microtask queue, which can be accessed
  10029. // via either native Promise.then or MutationObserver.
  10030. // MutationObserver has wider support, however it is seriously bugged in
  10031. // UIWebView in iOS >= 9.3.3 when triggered in touch event handlers. It
  10032. // completely stops working after triggering a few times... so, if native
  10033. // Promise is available, we will use it:
  10034. /* istanbul ignore if */
  10035. if (typeof Promise !== 'undefined' && isNative(Promise)) {
  10036. var p = Promise.resolve();
  10037. var logError = function (err) { console.error(err); };
  10038. timerFunc = function () {
  10039. p.then(nextTickHandler).catch(logError);
  10040. // in problematic UIWebViews, Promise.then doesn't completely break, but
  10041. // it can get stuck in a weird state where callbacks are pushed into the
  10042. // microtask queue but the queue isn't being flushed, until the browser
  10043. // needs to do some other work, e.g. handle a timer. Therefore we can
  10044. // "force" the microtask queue to be flushed by adding an empty timer.
  10045. if (isIOS) { setTimeout(noop); }
  10046. };
  10047. } else if (typeof MutationObserver !== 'undefined' && (
  10048. isNative(MutationObserver) ||
  10049. // PhantomJS and iOS 7.x
  10050. MutationObserver.toString() === '[object MutationObserverConstructor]'
  10051. )) {
  10052. // use MutationObserver where native Promise is not available,
  10053. // e.g. PhantomJS IE11, iOS7, Android 4.4
  10054. var counter = 1;
  10055. var observer = new MutationObserver(nextTickHandler);
  10056. var textNode = document.createTextNode(String(counter));
  10057. observer.observe(textNode, {
  10058. characterData: true
  10059. });
  10060. timerFunc = function () {
  10061. counter = (counter + 1) % 2;
  10062. textNode.data = String(counter);
  10063. };
  10064. } else {
  10065. // fallback to setTimeout
  10066. /* istanbul ignore next */
  10067. timerFunc = function () {
  10068. setTimeout(nextTickHandler, 0);
  10069. };
  10070. }
  10071. return function queueNextTick (cb, ctx) {
  10072. var _resolve;
  10073. callbacks.push(function () {
  10074. if (cb) {
  10075. try {
  10076. cb.call(ctx);
  10077. } catch (e) {
  10078. handleError(e, ctx, 'nextTick');
  10079. }
  10080. } else if (_resolve) {
  10081. _resolve(ctx);
  10082. }
  10083. });
  10084. if (!pending) {
  10085. pending = true;
  10086. timerFunc();
  10087. }
  10088. if (!cb && typeof Promise !== 'undefined') {
  10089. return new Promise(function (resolve, reject) {
  10090. _resolve = resolve;
  10091. })
  10092. }
  10093. }
  10094. })();
  10095. var _Set;
  10096. /* istanbul ignore if */
  10097. if (typeof Set !== 'undefined' && isNative(Set)) {
  10098. // use native Set when available.
  10099. _Set = Set;
  10100. } else {
  10101. // a non-standard Set polyfill that only works with primitive keys.
  10102. _Set = (function () {
  10103. function Set () {
  10104. this.set = Object.create(null);
  10105. }
  10106. Set.prototype.has = function has (key) {
  10107. return this.set[key] === true
  10108. };
  10109. Set.prototype.add = function add (key) {
  10110. this.set[key] = true;
  10111. };
  10112. Set.prototype.clear = function clear () {
  10113. this.set = Object.create(null);
  10114. };
  10115. return Set;
  10116. }());
  10117. }
  10118. /* */
  10119. var uid$1 = 0;
  10120. /**
  10121. * A dep is an observable that can have multiple
  10122. * directives subscribing to it.
  10123. */
  10124. var Dep = function Dep () {
  10125. this.id = uid$1++;
  10126. this.subs = [];
  10127. };
  10128. Dep.prototype.addSub = function addSub (sub) {
  10129. this.subs.push(sub);
  10130. };
  10131. Dep.prototype.removeSub = function removeSub (sub) {
  10132. remove(this.subs, sub);
  10133. };
  10134. Dep.prototype.depend = function depend () {
  10135. if (Dep.target) {
  10136. Dep.target.addDep(this);
  10137. }
  10138. };
  10139. Dep.prototype.notify = function notify () {
  10140. // stabilize the subscriber list first
  10141. var subs = this.subs.slice();
  10142. for (var i = 0, l = subs.length; i < l; i++) {
  10143. subs[i].update();
  10144. }
  10145. };
  10146. // the current target watcher being evaluated.
  10147. // this is globally unique because there could be only one
  10148. // watcher being evaluated at any time.
  10149. Dep.target = null;
  10150. var targetStack = [];
  10151. function pushTarget (_target) {
  10152. if (Dep.target) { targetStack.push(Dep.target); }
  10153. Dep.target = _target;
  10154. }
  10155. function popTarget () {
  10156. Dep.target = targetStack.pop();
  10157. }
  10158. /*
  10159. * not type checking this file because flow doesn't play well with
  10160. * dynamically accessing methods on Array prototype
  10161. */
  10162. var arrayProto = Array.prototype;
  10163. var arrayMethods = Object.create(arrayProto);[
  10164. 'push',
  10165. 'pop',
  10166. 'shift',
  10167. 'unshift',
  10168. 'splice',
  10169. 'sort',
  10170. 'reverse'
  10171. ]
  10172. .forEach(function (method) {
  10173. // cache original method
  10174. var original = arrayProto[method];
  10175. def(arrayMethods, method, function mutator () {
  10176. var arguments$1 = arguments;
  10177. // avoid leaking arguments:
  10178. // http://jsperf.com/closure-with-arguments
  10179. var i = arguments.length;
  10180. var args = new Array(i);
  10181. while (i--) {
  10182. args[i] = arguments$1[i];
  10183. }
  10184. var result = original.apply(this, args);
  10185. var ob = this.__ob__;
  10186. var inserted;
  10187. switch (method) {
  10188. case 'push':
  10189. inserted = args;
  10190. break
  10191. case 'unshift':
  10192. inserted = args;
  10193. break
  10194. case 'splice':
  10195. inserted = args.slice(2);
  10196. break
  10197. }
  10198. if (inserted) { ob.observeArray(inserted); }
  10199. // notify change
  10200. ob.dep.notify();
  10201. return result
  10202. });
  10203. });
  10204. /* */
  10205. var arrayKeys = Object.getOwnPropertyNames(arrayMethods);
  10206. /**
  10207. * By default, when a reactive property is set, the new value is
  10208. * also converted to become reactive. However when passing down props,
  10209. * we don't want to force conversion because the value may be a nested value
  10210. * under a frozen data structure. Converting it would defeat the optimization.
  10211. */
  10212. var observerState = {
  10213. shouldConvert: true,
  10214. isSettingProps: false
  10215. };
  10216. /**
  10217. * Observer class that are attached to each observed
  10218. * object. Once attached, the observer converts target
  10219. * object's property keys into getter/setters that
  10220. * collect dependencies and dispatches updates.
  10221. */
  10222. var Observer = function Observer (value) {
  10223. this.value = value;
  10224. this.dep = new Dep();
  10225. this.vmCount = 0;
  10226. def(value, '__ob__', this);
  10227. if (Array.isArray(value)) {
  10228. var augment = hasProto
  10229. ? protoAugment
  10230. : copyAugment;
  10231. augment(value, arrayMethods, arrayKeys);
  10232. this.observeArray(value);
  10233. } else {
  10234. this.walk(value);
  10235. }
  10236. };
  10237. /**
  10238. * Walk through each property and convert them into
  10239. * getter/setters. This method should only be called when
  10240. * value type is Object.
  10241. */
  10242. Observer.prototype.walk = function walk (obj) {
  10243. var keys = Object.keys(obj);
  10244. for (var i = 0; i < keys.length; i++) {
  10245. defineReactive$$1(obj, keys[i], obj[keys[i]]);
  10246. }
  10247. };
  10248. /**
  10249. * Observe a list of Array items.
  10250. */
  10251. Observer.prototype.observeArray = function observeArray (items) {
  10252. for (var i = 0, l = items.length; i < l; i++) {
  10253. observe(items[i]);
  10254. }
  10255. };
  10256. // helpers
  10257. /**
  10258. * Augment an target Object or Array by intercepting
  10259. * the prototype chain using __proto__
  10260. */
  10261. function protoAugment (target, src) {
  10262. /* eslint-disable no-proto */
  10263. target.__proto__ = src;
  10264. /* eslint-enable no-proto */
  10265. }
  10266. /**
  10267. * Augment an target Object or Array by defining
  10268. * hidden properties.
  10269. */
  10270. /* istanbul ignore next */
  10271. function copyAugment (target, src, keys) {
  10272. for (var i = 0, l = keys.length; i < l; i++) {
  10273. var key = keys[i];
  10274. def(target, key, src[key]);
  10275. }
  10276. }
  10277. /**
  10278. * Attempt to create an observer instance for a value,
  10279. * returns the new observer if successfully observed,
  10280. * or the existing observer if the value already has one.
  10281. */
  10282. function observe (value, asRootData) {
  10283. if (!isObject(value)) {
  10284. return
  10285. }
  10286. var ob;
  10287. if (hasOwn(value, '__ob__') && value.__ob__ instanceof Observer) {
  10288. ob = value.__ob__;
  10289. } else if (
  10290. observerState.shouldConvert &&
  10291. !isServerRendering() &&
  10292. (Array.isArray(value) || isPlainObject(value)) &&
  10293. Object.isExtensible(value) &&
  10294. !value._isVue
  10295. ) {
  10296. ob = new Observer(value);
  10297. }
  10298. if (asRootData && ob) {
  10299. ob.vmCount++;
  10300. }
  10301. return ob
  10302. }
  10303. /**
  10304. * Define a reactive property on an Object.
  10305. */
  10306. function defineReactive$$1 (
  10307. obj,
  10308. key,
  10309. val,
  10310. customSetter
  10311. ) {
  10312. var dep = new Dep();
  10313. var property = Object.getOwnPropertyDescriptor(obj, key);
  10314. if (property && property.configurable === false) {
  10315. return
  10316. }
  10317. // cater for pre-defined getter/setters
  10318. var getter = property && property.get;
  10319. var setter = property && property.set;
  10320. var childOb = observe(val);
  10321. Object.defineProperty(obj, key, {
  10322. enumerable: true,
  10323. configurable: true,
  10324. get: function reactiveGetter () {
  10325. var value = getter ? getter.call(obj) : val;
  10326. if (Dep.target) {
  10327. dep.depend();
  10328. if (childOb) {
  10329. childOb.dep.depend();
  10330. }
  10331. if (Array.isArray(value)) {
  10332. dependArray(value);
  10333. }
  10334. }
  10335. return value
  10336. },
  10337. set: function reactiveSetter (newVal) {
  10338. var value = getter ? getter.call(obj) : val;
  10339. /* eslint-disable no-self-compare */
  10340. if (newVal === value || (newVal !== newVal && value !== value)) {
  10341. return
  10342. }
  10343. /* eslint-enable no-self-compare */
  10344. if (process.env.NODE_ENV !== 'production' && customSetter) {
  10345. customSetter();
  10346. }
  10347. if (setter) {
  10348. setter.call(obj, newVal);
  10349. } else {
  10350. val = newVal;
  10351. }
  10352. childOb = observe(newVal);
  10353. dep.notify();
  10354. }
  10355. });
  10356. }
  10357. /**
  10358. * Set a property on an object. Adds the new property and
  10359. * triggers change notification if the property doesn't
  10360. * already exist.
  10361. */
  10362. function set (target, key, val) {
  10363. if (Array.isArray(target) && typeof key === 'number') {
  10364. target.length = Math.max(target.length, key);
  10365. target.splice(key, 1, val);
  10366. return val
  10367. }
  10368. if (hasOwn(target, key)) {
  10369. target[key] = val;
  10370. return val
  10371. }
  10372. var ob = (target ).__ob__;
  10373. if (target._isVue || (ob && ob.vmCount)) {
  10374. process.env.NODE_ENV !== 'production' && warn(
  10375. 'Avoid adding reactive properties to a Vue instance or its root $data ' +
  10376. 'at runtime - declare it upfront in the data option.'
  10377. );
  10378. return val
  10379. }
  10380. if (!ob) {
  10381. target[key] = val;
  10382. return val
  10383. }
  10384. defineReactive$$1(ob.value, key, val);
  10385. ob.dep.notify();
  10386. return val
  10387. }
  10388. /**
  10389. * Delete a property and trigger change if necessary.
  10390. */
  10391. function del (target, key) {
  10392. if (Array.isArray(target) && typeof key === 'number') {
  10393. target.splice(key, 1);
  10394. return
  10395. }
  10396. var ob = (target ).__ob__;
  10397. if (target._isVue || (ob && ob.vmCount)) {
  10398. process.env.NODE_ENV !== 'production' && warn(
  10399. 'Avoid deleting properties on a Vue instance or its root $data ' +
  10400. '- just set it to null.'
  10401. );
  10402. return
  10403. }
  10404. if (!hasOwn(target, key)) {
  10405. return
  10406. }
  10407. delete target[key];
  10408. if (!ob) {
  10409. return
  10410. }
  10411. ob.dep.notify();
  10412. }
  10413. /**
  10414. * Collect dependencies on array elements when the array is touched, since
  10415. * we cannot intercept array element access like property getters.
  10416. */
  10417. function dependArray (value) {
  10418. for (var e = (void 0), i = 0, l = value.length; i < l; i++) {
  10419. e = value[i];
  10420. e && e.__ob__ && e.__ob__.dep.depend();
  10421. if (Array.isArray(e)) {
  10422. dependArray(e);
  10423. }
  10424. }
  10425. }
  10426. /* */
  10427. /**
  10428. * Option overwriting strategies are functions that handle
  10429. * how to merge a parent option value and a child option
  10430. * value into the final value.
  10431. */
  10432. var strats = config.optionMergeStrategies;
  10433. /**
  10434. * Options with restrictions
  10435. */
  10436. if (process.env.NODE_ENV !== 'production') {
  10437. strats.el = strats.propsData = function (parent, child, vm, key) {
  10438. if (!vm) {
  10439. warn(
  10440. "option \"" + key + "\" can only be used during instance " +
  10441. 'creation with the `new` keyword.'
  10442. );
  10443. }
  10444. return defaultStrat(parent, child)
  10445. };
  10446. }
  10447. /**
  10448. * Helper that recursively merges two data objects together.
  10449. */
  10450. function mergeData (to, from) {
  10451. if (!from) { return to }
  10452. var key, toVal, fromVal;
  10453. var keys = Object.keys(from);
  10454. for (var i = 0; i < keys.length; i++) {
  10455. key = keys[i];
  10456. toVal = to[key];
  10457. fromVal = from[key];
  10458. if (!hasOwn(to, key)) {
  10459. set(to, key, fromVal);
  10460. } else if (isPlainObject(toVal) && isPlainObject(fromVal)) {
  10461. mergeData(toVal, fromVal);
  10462. }
  10463. }
  10464. return to
  10465. }
  10466. /**
  10467. * Data
  10468. */
  10469. strats.data = function (
  10470. parentVal,
  10471. childVal,
  10472. vm
  10473. ) {
  10474. if (!vm) {
  10475. // in a Vue.extend merge, both should be functions
  10476. if (!childVal) {
  10477. return parentVal
  10478. }
  10479. if (typeof childVal !== 'function') {
  10480. process.env.NODE_ENV !== 'production' && warn(
  10481. 'The "data" option should be a function ' +
  10482. 'that returns a per-instance value in component ' +
  10483. 'definitions.',
  10484. vm
  10485. );
  10486. return parentVal
  10487. }
  10488. if (!parentVal) {
  10489. return childVal
  10490. }
  10491. // when parentVal & childVal are both present,
  10492. // we need to return a function that returns the
  10493. // merged result of both functions... no need to
  10494. // check if parentVal is a function here because
  10495. // it has to be a function to pass previous merges.
  10496. return function mergedDataFn () {
  10497. return mergeData(
  10498. childVal.call(this),
  10499. parentVal.call(this)
  10500. )
  10501. }
  10502. } else if (parentVal || childVal) {
  10503. return function mergedInstanceDataFn () {
  10504. // instance merge
  10505. var instanceData = typeof childVal === 'function'
  10506. ? childVal.call(vm)
  10507. : childVal;
  10508. var defaultData = typeof parentVal === 'function'
  10509. ? parentVal.call(vm)
  10510. : undefined;
  10511. if (instanceData) {
  10512. return mergeData(instanceData, defaultData)
  10513. } else {
  10514. return defaultData
  10515. }
  10516. }
  10517. }
  10518. };
  10519. /**
  10520. * Hooks and props are merged as arrays.
  10521. */
  10522. function mergeHook (
  10523. parentVal,
  10524. childVal
  10525. ) {
  10526. return childVal
  10527. ? parentVal
  10528. ? parentVal.concat(childVal)
  10529. : Array.isArray(childVal)
  10530. ? childVal
  10531. : [childVal]
  10532. : parentVal
  10533. }
  10534. LIFECYCLE_HOOKS.forEach(function (hook) {
  10535. strats[hook] = mergeHook;
  10536. });
  10537. /**
  10538. * Assets
  10539. *
  10540. * When a vm is present (instance creation), we need to do
  10541. * a three-way merge between constructor options, instance
  10542. * options and parent options.
  10543. */
  10544. function mergeAssets (parentVal, childVal) {
  10545. var res = Object.create(parentVal || null);
  10546. return childVal
  10547. ? extend(res, childVal)
  10548. : res
  10549. }
  10550. ASSET_TYPES.forEach(function (type) {
  10551. strats[type + 's'] = mergeAssets;
  10552. });
  10553. /**
  10554. * Watchers.
  10555. *
  10556. * Watchers hashes should not overwrite one
  10557. * another, so we merge them as arrays.
  10558. */
  10559. strats.watch = function (parentVal, childVal) {
  10560. /* istanbul ignore if */
  10561. if (!childVal) { return Object.create(parentVal || null) }
  10562. if (!parentVal) { return childVal }
  10563. var ret = {};
  10564. extend(ret, parentVal);
  10565. for (var key in childVal) {
  10566. var parent = ret[key];
  10567. var child = childVal[key];
  10568. if (parent && !Array.isArray(parent)) {
  10569. parent = [parent];
  10570. }
  10571. ret[key] = parent
  10572. ? parent.concat(child)
  10573. : [child];
  10574. }
  10575. return ret
  10576. };
  10577. /**
  10578. * Other object hashes.
  10579. */
  10580. strats.props =
  10581. strats.methods =
  10582. strats.computed = function (parentVal, childVal) {
  10583. if (!childVal) { return Object.create(parentVal || null) }
  10584. if (!parentVal) { return childVal }
  10585. var ret = Object.create(null);
  10586. extend(ret, parentVal);
  10587. extend(ret, childVal);
  10588. return ret
  10589. };
  10590. /**
  10591. * Default strategy.
  10592. */
  10593. var defaultStrat = function (parentVal, childVal) {
  10594. return childVal === undefined
  10595. ? parentVal
  10596. : childVal
  10597. };
  10598. /**
  10599. * Validate component names
  10600. */
  10601. function checkComponents (options) {
  10602. for (var key in options.components) {
  10603. var lower = key.toLowerCase();
  10604. if (isBuiltInTag(lower) || config.isReservedTag(lower)) {
  10605. warn(
  10606. 'Do not use built-in or reserved HTML elements as component ' +
  10607. 'id: ' + key
  10608. );
  10609. }
  10610. }
  10611. }
  10612. /**
  10613. * Ensure all props option syntax are normalized into the
  10614. * Object-based format.
  10615. */
  10616. function normalizeProps (options) {
  10617. var props = options.props;
  10618. if (!props) { return }
  10619. var res = {};
  10620. var i, val, name;
  10621. if (Array.isArray(props)) {
  10622. i = props.length;
  10623. while (i--) {
  10624. val = props[i];
  10625. if (typeof val === 'string') {
  10626. name = camelize(val);
  10627. res[name] = { type: null };
  10628. } else if (process.env.NODE_ENV !== 'production') {
  10629. warn('props must be strings when using array syntax.');
  10630. }
  10631. }
  10632. } else if (isPlainObject(props)) {
  10633. for (var key in props) {
  10634. val = props[key];
  10635. name = camelize(key);
  10636. res[name] = isPlainObject(val)
  10637. ? val
  10638. : { type: val };
  10639. }
  10640. }
  10641. options.props = res;
  10642. }
  10643. /**
  10644. * Normalize raw function directives into object format.
  10645. */
  10646. function normalizeDirectives (options) {
  10647. var dirs = options.directives;
  10648. if (dirs) {
  10649. for (var key in dirs) {
  10650. var def = dirs[key];
  10651. if (typeof def === 'function') {
  10652. dirs[key] = { bind: def, update: def };
  10653. }
  10654. }
  10655. }
  10656. }
  10657. /**
  10658. * Merge two option objects into a new one.
  10659. * Core utility used in both instantiation and inheritance.
  10660. */
  10661. function mergeOptions (
  10662. parent,
  10663. child,
  10664. vm
  10665. ) {
  10666. if (process.env.NODE_ENV !== 'production') {
  10667. checkComponents(child);
  10668. }
  10669. if (typeof child === 'function') {
  10670. child = child.options;
  10671. }
  10672. normalizeProps(child);
  10673. normalizeDirectives(child);
  10674. var extendsFrom = child.extends;
  10675. if (extendsFrom) {
  10676. parent = mergeOptions(parent, extendsFrom, vm);
  10677. }
  10678. if (child.mixins) {
  10679. for (var i = 0, l = child.mixins.length; i < l; i++) {
  10680. parent = mergeOptions(parent, child.mixins[i], vm);
  10681. }
  10682. }
  10683. var options = {};
  10684. var key;
  10685. for (key in parent) {
  10686. mergeField(key);
  10687. }
  10688. for (key in child) {
  10689. if (!hasOwn(parent, key)) {
  10690. mergeField(key);
  10691. }
  10692. }
  10693. function mergeField (key) {
  10694. var strat = strats[key] || defaultStrat;
  10695. options[key] = strat(parent[key], child[key], vm, key);
  10696. }
  10697. return options
  10698. }
  10699. /**
  10700. * Resolve an asset.
  10701. * This function is used because child instances need access
  10702. * to assets defined in its ancestor chain.
  10703. */
  10704. function resolveAsset (
  10705. options,
  10706. type,
  10707. id,
  10708. warnMissing
  10709. ) {
  10710. /* istanbul ignore if */
  10711. if (typeof id !== 'string') {
  10712. return
  10713. }
  10714. var assets = options[type];
  10715. // check local registration variations first
  10716. if (hasOwn(assets, id)) { return assets[id] }
  10717. var camelizedId = camelize(id);
  10718. if (hasOwn(assets, camelizedId)) { return assets[camelizedId] }
  10719. var PascalCaseId = capitalize(camelizedId);
  10720. if (hasOwn(assets, PascalCaseId)) { return assets[PascalCaseId] }
  10721. // fallback to prototype chain
  10722. var res = assets[id] || assets[camelizedId] || assets[PascalCaseId];
  10723. if (process.env.NODE_ENV !== 'production' && warnMissing && !res) {
  10724. warn(
  10725. 'Failed to resolve ' + type.slice(0, -1) + ': ' + id,
  10726. options
  10727. );
  10728. }
  10729. return res
  10730. }
  10731. /* */
  10732. function validateProp (
  10733. key,
  10734. propOptions,
  10735. propsData,
  10736. vm
  10737. ) {
  10738. var prop = propOptions[key];
  10739. var absent = !hasOwn(propsData, key);
  10740. var value = propsData[key];
  10741. // handle boolean props
  10742. if (isType(Boolean, prop.type)) {
  10743. if (absent && !hasOwn(prop, 'default')) {
  10744. value = false;
  10745. } else if (!isType(String, prop.type) && (value === '' || value === hyphenate(key))) {
  10746. value = true;
  10747. }
  10748. }
  10749. // check default value
  10750. if (value === undefined) {
  10751. value = getPropDefaultValue(vm, prop, key);
  10752. // since the default value is a fresh copy,
  10753. // make sure to observe it.
  10754. var prevShouldConvert = observerState.shouldConvert;
  10755. observerState.shouldConvert = true;
  10756. observe(value);
  10757. observerState.shouldConvert = prevShouldConvert;
  10758. }
  10759. if (process.env.NODE_ENV !== 'production') {
  10760. assertProp(prop, key, value, vm, absent);
  10761. }
  10762. return value
  10763. }
  10764. /**
  10765. * Get the default value of a prop.
  10766. */
  10767. function getPropDefaultValue (vm, prop, key) {
  10768. // no default, return undefined
  10769. if (!hasOwn(prop, 'default')) {
  10770. return undefined
  10771. }
  10772. var def = prop.default;
  10773. // warn against non-factory defaults for Object & Array
  10774. if (process.env.NODE_ENV !== 'production' && isObject(def)) {
  10775. warn(
  10776. 'Invalid default value for prop "' + key + '": ' +
  10777. 'Props with type Object/Array must use a factory function ' +
  10778. 'to return the default value.',
  10779. vm
  10780. );
  10781. }
  10782. // the raw prop value was also undefined from previous render,
  10783. // return previous default value to avoid unnecessary watcher trigger
  10784. if (vm && vm.$options.propsData &&
  10785. vm.$options.propsData[key] === undefined &&
  10786. vm._props[key] !== undefined
  10787. ) {
  10788. return vm._props[key]
  10789. }
  10790. // call factory function for non-Function types
  10791. // a value is Function if its prototype is function even across different execution context
  10792. return typeof def === 'function' && getType(prop.type) !== 'Function'
  10793. ? def.call(vm)
  10794. : def
  10795. }
  10796. /**
  10797. * Assert whether a prop is valid.
  10798. */
  10799. function assertProp (
  10800. prop,
  10801. name,
  10802. value,
  10803. vm,
  10804. absent
  10805. ) {
  10806. if (prop.required && absent) {
  10807. warn(
  10808. 'Missing required prop: "' + name + '"',
  10809. vm
  10810. );
  10811. return
  10812. }
  10813. if (value == null && !prop.required) {
  10814. return
  10815. }
  10816. var type = prop.type;
  10817. var valid = !type || type === true;
  10818. var expectedTypes = [];
  10819. if (type) {
  10820. if (!Array.isArray(type)) {
  10821. type = [type];
  10822. }
  10823. for (var i = 0; i < type.length && !valid; i++) {
  10824. var assertedType = assertType(value, type[i]);
  10825. expectedTypes.push(assertedType.expectedType || '');
  10826. valid = assertedType.valid;
  10827. }
  10828. }
  10829. if (!valid) {
  10830. warn(
  10831. 'Invalid prop: type check failed for prop "' + name + '".' +
  10832. ' Expected ' + expectedTypes.map(capitalize).join(', ') +
  10833. ', got ' + Object.prototype.toString.call(value).slice(8, -1) + '.',
  10834. vm
  10835. );
  10836. return
  10837. }
  10838. var validator = prop.validator;
  10839. if (validator) {
  10840. if (!validator(value)) {
  10841. warn(
  10842. 'Invalid prop: custom validator check failed for prop "' + name + '".',
  10843. vm
  10844. );
  10845. }
  10846. }
  10847. }
  10848. var simpleCheckRE = /^(String|Number|Boolean|Function|Symbol)$/;
  10849. function assertType (value, type) {
  10850. var valid;
  10851. var expectedType = getType(type);
  10852. if (simpleCheckRE.test(expectedType)) {
  10853. valid = typeof value === expectedType.toLowerCase();
  10854. } else if (expectedType === 'Object') {
  10855. valid = isPlainObject(value);
  10856. } else if (expectedType === 'Array') {
  10857. valid = Array.isArray(value);
  10858. } else {
  10859. valid = value instanceof type;
  10860. }
  10861. return {
  10862. valid: valid,
  10863. expectedType: expectedType
  10864. }
  10865. }
  10866. /**
  10867. * Use function string name to check built-in types,
  10868. * because a simple equality check will fail when running
  10869. * across different vms / iframes.
  10870. */
  10871. function getType (fn) {
  10872. var match = fn && fn.toString().match(/^\s*function (\w+)/);
  10873. return match ? match[1] : ''
  10874. }
  10875. function isType (type, fn) {
  10876. if (!Array.isArray(fn)) {
  10877. return getType(fn) === getType(type)
  10878. }
  10879. for (var i = 0, len = fn.length; i < len; i++) {
  10880. if (getType(fn[i]) === getType(type)) {
  10881. return true
  10882. }
  10883. }
  10884. /* istanbul ignore next */
  10885. return false
  10886. }
  10887. /* */
  10888. /* not type checking this file because flow doesn't play well with Proxy */
  10889. var initProxy;
  10890. if (process.env.NODE_ENV !== 'production') {
  10891. var allowedGlobals = makeMap(
  10892. 'Infinity,undefined,NaN,isFinite,isNaN,' +
  10893. 'parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,' +
  10894. 'Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,' +
  10895. 'require' // for Webpack/Browserify
  10896. );
  10897. var warnNonPresent = function (target, key) {
  10898. warn(
  10899. "Property or method \"" + key + "\" is not defined on the instance but " +
  10900. "referenced during render. Make sure to declare reactive data " +
  10901. "properties in the data option.",
  10902. target
  10903. );
  10904. };
  10905. var hasProxy =
  10906. typeof Proxy !== 'undefined' &&
  10907. Proxy.toString().match(/native code/);
  10908. if (hasProxy) {
  10909. var isBuiltInModifier = makeMap('stop,prevent,self,ctrl,shift,alt,meta');
  10910. config.keyCodes = new Proxy(config.keyCodes, {
  10911. set: function set (target, key, value) {
  10912. if (isBuiltInModifier(key)) {
  10913. warn(("Avoid overwriting built-in modifier in config.keyCodes: ." + key));
  10914. return false
  10915. } else {
  10916. target[key] = value;
  10917. return true
  10918. }
  10919. }
  10920. });
  10921. }
  10922. var hasHandler = {
  10923. has: function has (target, key) {
  10924. var has = key in target;
  10925. var isAllowed = allowedGlobals(key) || key.charAt(0) === '_';
  10926. if (!has && !isAllowed) {
  10927. warnNonPresent(target, key);
  10928. }
  10929. return has || !isAllowed
  10930. }
  10931. };
  10932. var getHandler = {
  10933. get: function get (target, key) {
  10934. if (typeof key === 'string' && !(key in target)) {
  10935. warnNonPresent(target, key);
  10936. }
  10937. return target[key]
  10938. }
  10939. };
  10940. initProxy = function initProxy (vm) {
  10941. if (hasProxy) {
  10942. // determine which proxy handler to use
  10943. var options = vm.$options;
  10944. var handlers = options.render && options.render._withStripped
  10945. ? getHandler
  10946. : hasHandler;
  10947. vm._renderProxy = new Proxy(vm, handlers);
  10948. } else {
  10949. vm._renderProxy = vm;
  10950. }
  10951. };
  10952. }
  10953. var mark;
  10954. var measure;
  10955. if (process.env.NODE_ENV !== 'production') {
  10956. var perf = inBrowser && window.performance;
  10957. /* istanbul ignore if */
  10958. if (
  10959. perf &&
  10960. perf.mark &&
  10961. perf.measure &&
  10962. perf.clearMarks &&
  10963. perf.clearMeasures
  10964. ) {
  10965. mark = function (tag) { return perf.mark(tag); };
  10966. measure = function (name, startTag, endTag) {
  10967. perf.measure(name, startTag, endTag);
  10968. perf.clearMarks(startTag);
  10969. perf.clearMarks(endTag);
  10970. perf.clearMeasures(name);
  10971. };
  10972. }
  10973. }
  10974. /* */
  10975. var VNode = function VNode (
  10976. tag,
  10977. data,
  10978. children,
  10979. text,
  10980. elm,
  10981. context,
  10982. componentOptions
  10983. ) {
  10984. this.tag = tag;
  10985. this.data = data;
  10986. this.children = children;
  10987. this.text = text;
  10988. this.elm = elm;
  10989. this.ns = undefined;
  10990. this.context = context;
  10991. this.functionalContext = undefined;
  10992. this.key = data && data.key;
  10993. this.componentOptions = componentOptions;
  10994. this.componentInstance = undefined;
  10995. this.parent = undefined;
  10996. this.raw = false;
  10997. this.isStatic = false;
  10998. this.isRootInsert = true;
  10999. this.isComment = false;
  11000. this.isCloned = false;
  11001. this.isOnce = false;
  11002. };
  11003. var prototypeAccessors = { child: {} };
  11004. // DEPRECATED: alias for componentInstance for backwards compat.
  11005. /* istanbul ignore next */
  11006. prototypeAccessors.child.get = function () {
  11007. return this.componentInstance
  11008. };
  11009. Object.defineProperties( VNode.prototype, prototypeAccessors );
  11010. var createEmptyVNode = function () {
  11011. var node = new VNode();
  11012. node.text = '';
  11013. node.isComment = true;
  11014. return node
  11015. };
  11016. function createTextVNode (val) {
  11017. return new VNode(undefined, undefined, undefined, String(val))
  11018. }
  11019. // optimized shallow clone
  11020. // used for static nodes and slot nodes because they may be reused across
  11021. // multiple renders, cloning them avoids errors when DOM manipulations rely
  11022. // on their elm reference.
  11023. function cloneVNode (vnode) {
  11024. var cloned = new VNode(
  11025. vnode.tag,
  11026. vnode.data,
  11027. vnode.children,
  11028. vnode.text,
  11029. vnode.elm,
  11030. vnode.context,
  11031. vnode.componentOptions
  11032. );
  11033. cloned.ns = vnode.ns;
  11034. cloned.isStatic = vnode.isStatic;
  11035. cloned.key = vnode.key;
  11036. cloned.isComment = vnode.isComment;
  11037. cloned.isCloned = true;
  11038. return cloned
  11039. }
  11040. function cloneVNodes (vnodes) {
  11041. var len = vnodes.length;
  11042. var res = new Array(len);
  11043. for (var i = 0; i < len; i++) {
  11044. res[i] = cloneVNode(vnodes[i]);
  11045. }
  11046. return res
  11047. }
  11048. /* */
  11049. var normalizeEvent = cached(function (name) {
  11050. var passive = name.charAt(0) === '&';
  11051. name = passive ? name.slice(1) : name;
  11052. var once$$1 = name.charAt(0) === '~'; // Prefixed last, checked first
  11053. name = once$$1 ? name.slice(1) : name;
  11054. var capture = name.charAt(0) === '!';
  11055. name = capture ? name.slice(1) : name;
  11056. return {
  11057. name: name,
  11058. once: once$$1,
  11059. capture: capture,
  11060. passive: passive
  11061. }
  11062. });
  11063. function createFnInvoker (fns) {
  11064. function invoker () {
  11065. var arguments$1 = arguments;
  11066. var fns = invoker.fns;
  11067. if (Array.isArray(fns)) {
  11068. for (var i = 0; i < fns.length; i++) {
  11069. fns[i].apply(null, arguments$1);
  11070. }
  11071. } else {
  11072. // return handler return value for single handlers
  11073. return fns.apply(null, arguments)
  11074. }
  11075. }
  11076. invoker.fns = fns;
  11077. return invoker
  11078. }
  11079. function updateListeners (
  11080. on,
  11081. oldOn,
  11082. add,
  11083. remove$$1,
  11084. vm
  11085. ) {
  11086. var name, cur, old, event;
  11087. for (name in on) {
  11088. cur = on[name];
  11089. old = oldOn[name];
  11090. event = normalizeEvent(name);
  11091. if (isUndef(cur)) {
  11092. process.env.NODE_ENV !== 'production' && warn(
  11093. "Invalid handler for event \"" + (event.name) + "\": got " + String(cur),
  11094. vm
  11095. );
  11096. } else if (isUndef(old)) {
  11097. if (isUndef(cur.fns)) {
  11098. cur = on[name] = createFnInvoker(cur);
  11099. }
  11100. add(event.name, cur, event.once, event.capture, event.passive);
  11101. } else if (cur !== old) {
  11102. old.fns = cur;
  11103. on[name] = old;
  11104. }
  11105. }
  11106. for (name in oldOn) {
  11107. if (isUndef(on[name])) {
  11108. event = normalizeEvent(name);
  11109. remove$$1(event.name, oldOn[name], event.capture);
  11110. }
  11111. }
  11112. }
  11113. /* */
  11114. function mergeVNodeHook (def, hookKey, hook) {
  11115. var invoker;
  11116. var oldHook = def[hookKey];
  11117. function wrappedHook () {
  11118. hook.apply(this, arguments);
  11119. // important: remove merged hook to ensure it's called only once
  11120. // and prevent memory leak
  11121. remove(invoker.fns, wrappedHook);
  11122. }
  11123. if (isUndef(oldHook)) {
  11124. // no existing hook
  11125. invoker = createFnInvoker([wrappedHook]);
  11126. } else {
  11127. /* istanbul ignore if */
  11128. if (isDef(oldHook.fns) && isTrue(oldHook.merged)) {
  11129. // already a merged invoker
  11130. invoker = oldHook;
  11131. invoker.fns.push(wrappedHook);
  11132. } else {
  11133. // existing plain hook
  11134. invoker = createFnInvoker([oldHook, wrappedHook]);
  11135. }
  11136. }
  11137. invoker.merged = true;
  11138. def[hookKey] = invoker;
  11139. }
  11140. /* */
  11141. function extractPropsFromVNodeData (
  11142. data,
  11143. Ctor,
  11144. tag
  11145. ) {
  11146. // we are only extracting raw values here.
  11147. // validation and default values are handled in the child
  11148. // component itself.
  11149. var propOptions = Ctor.options.props;
  11150. if (isUndef(propOptions)) {
  11151. return
  11152. }
  11153. var res = {};
  11154. var attrs = data.attrs;
  11155. var props = data.props;
  11156. if (isDef(attrs) || isDef(props)) {
  11157. for (var key in propOptions) {
  11158. var altKey = hyphenate(key);
  11159. if (process.env.NODE_ENV !== 'production') {
  11160. var keyInLowerCase = key.toLowerCase();
  11161. if (
  11162. key !== keyInLowerCase &&
  11163. attrs && hasOwn(attrs, keyInLowerCase)
  11164. ) {
  11165. tip(
  11166. "Prop \"" + keyInLowerCase + "\" is passed to component " +
  11167. (formatComponentName(tag || Ctor)) + ", but the declared prop name is" +
  11168. " \"" + key + "\". " +
  11169. "Note that HTML attributes are case-insensitive and camelCased " +
  11170. "props need to use their kebab-case equivalents when using in-DOM " +
  11171. "templates. You should probably use \"" + altKey + "\" instead of \"" + key + "\"."
  11172. );
  11173. }
  11174. }
  11175. checkProp(res, props, key, altKey, true) ||
  11176. checkProp(res, attrs, key, altKey, false);
  11177. }
  11178. }
  11179. return res
  11180. }
  11181. function checkProp (
  11182. res,
  11183. hash,
  11184. key,
  11185. altKey,
  11186. preserve
  11187. ) {
  11188. if (isDef(hash)) {
  11189. if (hasOwn(hash, key)) {
  11190. res[key] = hash[key];
  11191. if (!preserve) {
  11192. delete hash[key];
  11193. }
  11194. return true
  11195. } else if (hasOwn(hash, altKey)) {
  11196. res[key] = hash[altKey];
  11197. if (!preserve) {
  11198. delete hash[altKey];
  11199. }
  11200. return true
  11201. }
  11202. }
  11203. return false
  11204. }
  11205. /* */
  11206. // The template compiler attempts to minimize the need for normalization by
  11207. // statically analyzing the template at compile time.
  11208. //
  11209. // For plain HTML markup, normalization can be completely skipped because the
  11210. // generated render function is guaranteed to return Array<VNode>. There are
  11211. // two cases where extra normalization is needed:
  11212. // 1. When the children contains components - because a functional component
  11213. // may return an Array instead of a single root. In this case, just a simple
  11214. // normalization is needed - if any child is an Array, we flatten the whole
  11215. // thing with Array.prototype.concat. It is guaranteed to be only 1-level deep
  11216. // because functional components already normalize their own children.
  11217. function simpleNormalizeChildren (children) {
  11218. for (var i = 0; i < children.length; i++) {
  11219. if (Array.isArray(children[i])) {
  11220. return Array.prototype.concat.apply([], children)
  11221. }
  11222. }
  11223. return children
  11224. }
  11225. // 2. When the children contains constructs that always generated nested Arrays,
  11226. // e.g. <template>, <slot>, v-for, or when the children is provided by user
  11227. // with hand-written render functions / JSX. In such cases a full normalization
  11228. // is needed to cater to all possible types of children values.
  11229. function normalizeChildren (children) {
  11230. return isPrimitive(children)
  11231. ? [createTextVNode(children)]
  11232. : Array.isArray(children)
  11233. ? normalizeArrayChildren(children)
  11234. : undefined
  11235. }
  11236. function isTextNode (node) {
  11237. return isDef(node) && isDef(node.text) && isFalse(node.isComment)
  11238. }
  11239. function normalizeArrayChildren (children, nestedIndex) {
  11240. var res = [];
  11241. var i, c, last;
  11242. for (i = 0; i < children.length; i++) {
  11243. c = children[i];
  11244. if (isUndef(c) || typeof c === 'boolean') { continue }
  11245. last = res[res.length - 1];
  11246. // nested
  11247. if (Array.isArray(c)) {
  11248. res.push.apply(res, normalizeArrayChildren(c, ((nestedIndex || '') + "_" + i)));
  11249. } else if (isPrimitive(c)) {
  11250. if (isTextNode(last)) {
  11251. // merge adjacent text nodes
  11252. // this is necessary for SSR hydration because text nodes are
  11253. // essentially merged when rendered to HTML strings
  11254. (last).text += String(c);
  11255. } else if (c !== '') {
  11256. // convert primitive to vnode
  11257. res.push(createTextVNode(c));
  11258. }
  11259. } else {
  11260. if (isTextNode(c) && isTextNode(last)) {
  11261. // merge adjacent text nodes
  11262. res[res.length - 1] = createTextVNode(last.text + c.text);
  11263. } else {
  11264. // default key for nested array children (likely generated by v-for)
  11265. if (isTrue(children._isVList) &&
  11266. isDef(c.tag) &&
  11267. isUndef(c.key) &&
  11268. isDef(nestedIndex)) {
  11269. c.key = "__vlist" + nestedIndex + "_" + i + "__";
  11270. }
  11271. res.push(c);
  11272. }
  11273. }
  11274. }
  11275. return res
  11276. }
  11277. /* */
  11278. function ensureCtor (comp, base) {
  11279. return isObject(comp)
  11280. ? base.extend(comp)
  11281. : comp
  11282. }
  11283. function resolveAsyncComponent (
  11284. factory,
  11285. baseCtor,
  11286. context
  11287. ) {
  11288. if (isTrue(factory.error) && isDef(factory.errorComp)) {
  11289. return factory.errorComp
  11290. }
  11291. if (isDef(factory.resolved)) {
  11292. return factory.resolved
  11293. }
  11294. if (isTrue(factory.loading) && isDef(factory.loadingComp)) {
  11295. return factory.loadingComp
  11296. }
  11297. if (isDef(factory.contexts)) {
  11298. // already pending
  11299. factory.contexts.push(context);
  11300. } else {
  11301. var contexts = factory.contexts = [context];
  11302. var sync = true;
  11303. var forceRender = function () {
  11304. for (var i = 0, l = contexts.length; i < l; i++) {
  11305. contexts[i].$forceUpdate();
  11306. }
  11307. };
  11308. var resolve = once(function (res) {
  11309. // cache resolved
  11310. factory.resolved = ensureCtor(res, baseCtor);
  11311. // invoke callbacks only if this is not a synchronous resolve
  11312. // (async resolves are shimmed as synchronous during SSR)
  11313. if (!sync) {
  11314. forceRender();
  11315. }
  11316. });
  11317. var reject = once(function (reason) {
  11318. process.env.NODE_ENV !== 'production' && warn(
  11319. "Failed to resolve async component: " + (String(factory)) +
  11320. (reason ? ("\nReason: " + reason) : '')
  11321. );
  11322. if (isDef(factory.errorComp)) {
  11323. factory.error = true;
  11324. forceRender();
  11325. }
  11326. });
  11327. var res = factory(resolve, reject);
  11328. if (isObject(res)) {
  11329. if (typeof res.then === 'function') {
  11330. // () => Promise
  11331. if (isUndef(factory.resolved)) {
  11332. res.then(resolve, reject);
  11333. }
  11334. } else if (isDef(res.component) && typeof res.component.then === 'function') {
  11335. res.component.then(resolve, reject);
  11336. if (isDef(res.error)) {
  11337. factory.errorComp = ensureCtor(res.error, baseCtor);
  11338. }
  11339. if (isDef(res.loading)) {
  11340. factory.loadingComp = ensureCtor(res.loading, baseCtor);
  11341. if (res.delay === 0) {
  11342. factory.loading = true;
  11343. } else {
  11344. setTimeout(function () {
  11345. if (isUndef(factory.resolved) && isUndef(factory.error)) {
  11346. factory.loading = true;
  11347. forceRender();
  11348. }
  11349. }, res.delay || 200);
  11350. }
  11351. }
  11352. if (isDef(res.timeout)) {
  11353. setTimeout(function () {
  11354. if (isUndef(factory.resolved)) {
  11355. reject(
  11356. process.env.NODE_ENV !== 'production'
  11357. ? ("timeout (" + (res.timeout) + "ms)")
  11358. : null
  11359. );
  11360. }
  11361. }, res.timeout);
  11362. }
  11363. }
  11364. }
  11365. sync = false;
  11366. // return in case resolved synchronously
  11367. return factory.loading
  11368. ? factory.loadingComp
  11369. : factory.resolved
  11370. }
  11371. }
  11372. /* */
  11373. function getFirstComponentChild (children) {
  11374. if (Array.isArray(children)) {
  11375. for (var i = 0; i < children.length; i++) {
  11376. var c = children[i];
  11377. if (isDef(c) && isDef(c.componentOptions)) {
  11378. return c
  11379. }
  11380. }
  11381. }
  11382. }
  11383. /* */
  11384. /* */
  11385. function initEvents (vm) {
  11386. vm._events = Object.create(null);
  11387. vm._hasHookEvent = false;
  11388. // init parent attached events
  11389. var listeners = vm.$options._parentListeners;
  11390. if (listeners) {
  11391. updateComponentListeners(vm, listeners);
  11392. }
  11393. }
  11394. var target;
  11395. function add (event, fn, once$$1) {
  11396. if (once$$1) {
  11397. target.$once(event, fn);
  11398. } else {
  11399. target.$on(event, fn);
  11400. }
  11401. }
  11402. function remove$1 (event, fn) {
  11403. target.$off(event, fn);
  11404. }
  11405. function updateComponentListeners (
  11406. vm,
  11407. listeners,
  11408. oldListeners
  11409. ) {
  11410. target = vm;
  11411. updateListeners(listeners, oldListeners || {}, add, remove$1, vm);
  11412. }
  11413. function eventsMixin (Vue) {
  11414. var hookRE = /^hook:/;
  11415. Vue.prototype.$on = function (event, fn) {
  11416. var this$1 = this;
  11417. var vm = this;
  11418. if (Array.isArray(event)) {
  11419. for (var i = 0, l = event.length; i < l; i++) {
  11420. this$1.$on(event[i], fn);
  11421. }
  11422. } else {
  11423. (vm._events[event] || (vm._events[event] = [])).push(fn);
  11424. // optimize hook:event cost by using a boolean flag marked at registration
  11425. // instead of a hash lookup
  11426. if (hookRE.test(event)) {
  11427. vm._hasHookEvent = true;
  11428. }
  11429. }
  11430. return vm
  11431. };
  11432. Vue.prototype.$once = function (event, fn) {
  11433. var vm = this;
  11434. function on () {
  11435. vm.$off(event, on);
  11436. fn.apply(vm, arguments);
  11437. }
  11438. on.fn = fn;
  11439. vm.$on(event, on);
  11440. return vm
  11441. };
  11442. Vue.prototype.$off = function (event, fn) {
  11443. var this$1 = this;
  11444. var vm = this;
  11445. // all
  11446. if (!arguments.length) {
  11447. vm._events = Object.create(null);
  11448. return vm
  11449. }
  11450. // array of events
  11451. if (Array.isArray(event)) {
  11452. for (var i$1 = 0, l = event.length; i$1 < l; i$1++) {
  11453. this$1.$off(event[i$1], fn);
  11454. }
  11455. return vm
  11456. }
  11457. // specific event
  11458. var cbs = vm._events[event];
  11459. if (!cbs) {
  11460. return vm
  11461. }
  11462. if (arguments.length === 1) {
  11463. vm._events[event] = null;
  11464. return vm
  11465. }
  11466. // specific handler
  11467. var cb;
  11468. var i = cbs.length;
  11469. while (i--) {
  11470. cb = cbs[i];
  11471. if (cb === fn || cb.fn === fn) {
  11472. cbs.splice(i, 1);
  11473. break
  11474. }
  11475. }
  11476. return vm
  11477. };
  11478. Vue.prototype.$emit = function (event) {
  11479. var vm = this;
  11480. if (process.env.NODE_ENV !== 'production') {
  11481. var lowerCaseEvent = event.toLowerCase();
  11482. if (lowerCaseEvent !== event && vm._events[lowerCaseEvent]) {
  11483. tip(
  11484. "Event \"" + lowerCaseEvent + "\" is emitted in component " +
  11485. (formatComponentName(vm)) + " but the handler is registered for \"" + event + "\". " +
  11486. "Note that HTML attributes are case-insensitive and you cannot use " +
  11487. "v-on to listen to camelCase events when using in-DOM templates. " +
  11488. "You should probably use \"" + (hyphenate(event)) + "\" instead of \"" + event + "\"."
  11489. );
  11490. }
  11491. }
  11492. var cbs = vm._events[event];
  11493. if (cbs) {
  11494. cbs = cbs.length > 1 ? toArray(cbs) : cbs;
  11495. var args = toArray(arguments, 1);
  11496. for (var i = 0, l = cbs.length; i < l; i++) {
  11497. cbs[i].apply(vm, args);
  11498. }
  11499. }
  11500. return vm
  11501. };
  11502. }
  11503. /* */
  11504. /**
  11505. * Runtime helper for resolving raw children VNodes into a slot object.
  11506. */
  11507. function resolveSlots (
  11508. children,
  11509. context
  11510. ) {
  11511. var slots = {};
  11512. if (!children) {
  11513. return slots
  11514. }
  11515. var defaultSlot = [];
  11516. for (var i = 0, l = children.length; i < l; i++) {
  11517. var child = children[i];
  11518. // named slots should only be respected if the vnode was rendered in the
  11519. // same context.
  11520. if ((child.context === context || child.functionalContext === context) &&
  11521. child.data && child.data.slot != null
  11522. ) {
  11523. var name = child.data.slot;
  11524. var slot = (slots[name] || (slots[name] = []));
  11525. if (child.tag === 'template') {
  11526. slot.push.apply(slot, child.children);
  11527. } else {
  11528. slot.push(child);
  11529. }
  11530. } else {
  11531. defaultSlot.push(child);
  11532. }
  11533. }
  11534. // ignore whitespace
  11535. if (!defaultSlot.every(isWhitespace)) {
  11536. slots.default = defaultSlot;
  11537. }
  11538. return slots
  11539. }
  11540. function isWhitespace (node) {
  11541. return node.isComment || node.text === ' '
  11542. }
  11543. function resolveScopedSlots (
  11544. fns, // see flow/vnode
  11545. res
  11546. ) {
  11547. res = res || {};
  11548. for (var i = 0; i < fns.length; i++) {
  11549. if (Array.isArray(fns[i])) {
  11550. resolveScopedSlots(fns[i], res);
  11551. } else {
  11552. res[fns[i].key] = fns[i].fn;
  11553. }
  11554. }
  11555. return res
  11556. }
  11557. /* */
  11558. var activeInstance = null;
  11559. function initLifecycle (vm) {
  11560. var options = vm.$options;
  11561. // locate first non-abstract parent
  11562. var parent = options.parent;
  11563. if (parent && !options.abstract) {
  11564. while (parent.$options.abstract && parent.$parent) {
  11565. parent = parent.$parent;
  11566. }
  11567. parent.$children.push(vm);
  11568. }
  11569. vm.$parent = parent;
  11570. vm.$root = parent ? parent.$root : vm;
  11571. vm.$children = [];
  11572. vm.$refs = {};
  11573. vm._watcher = null;
  11574. vm._inactive = null;
  11575. vm._directInactive = false;
  11576. vm._isMounted = false;
  11577. vm._isDestroyed = false;
  11578. vm._isBeingDestroyed = false;
  11579. }
  11580. function lifecycleMixin (Vue) {
  11581. Vue.prototype._update = function (vnode, hydrating) {
  11582. var vm = this;
  11583. if (vm._isMounted) {
  11584. callHook(vm, 'beforeUpdate');
  11585. }
  11586. var prevEl = vm.$el;
  11587. var prevVnode = vm._vnode;
  11588. var prevActiveInstance = activeInstance;
  11589. activeInstance = vm;
  11590. vm._vnode = vnode;
  11591. // Vue.prototype.__patch__ is injected in entry points
  11592. // based on the rendering backend used.
  11593. if (!prevVnode) {
  11594. // initial render
  11595. vm.$el = vm.__patch__(
  11596. vm.$el, vnode, hydrating, false /* removeOnly */,
  11597. vm.$options._parentElm,
  11598. vm.$options._refElm
  11599. );
  11600. } else {
  11601. // updates
  11602. vm.$el = vm.__patch__(prevVnode, vnode);
  11603. }
  11604. activeInstance = prevActiveInstance;
  11605. // update __vue__ reference
  11606. if (prevEl) {
  11607. prevEl.__vue__ = null;
  11608. }
  11609. if (vm.$el) {
  11610. vm.$el.__vue__ = vm;
  11611. }
  11612. // if parent is an HOC, update its $el as well
  11613. if (vm.$vnode && vm.$parent && vm.$vnode === vm.$parent._vnode) {
  11614. vm.$parent.$el = vm.$el;
  11615. }
  11616. // updated hook is called by the scheduler to ensure that children are
  11617. // updated in a parent's updated hook.
  11618. };
  11619. Vue.prototype.$forceUpdate = function () {
  11620. var vm = this;
  11621. if (vm._watcher) {
  11622. vm._watcher.update();
  11623. }
  11624. };
  11625. Vue.prototype.$destroy = function () {
  11626. var vm = this;
  11627. if (vm._isBeingDestroyed) {
  11628. return
  11629. }
  11630. callHook(vm, 'beforeDestroy');
  11631. vm._isBeingDestroyed = true;
  11632. // remove self from parent
  11633. var parent = vm.$parent;
  11634. if (parent && !parent._isBeingDestroyed && !vm.$options.abstract) {
  11635. remove(parent.$children, vm);
  11636. }
  11637. // teardown watchers
  11638. if (vm._watcher) {
  11639. vm._watcher.teardown();
  11640. }
  11641. var i = vm._watchers.length;
  11642. while (i--) {
  11643. vm._watchers[i].teardown();
  11644. }
  11645. // remove reference from data ob
  11646. // frozen object may not have observer.
  11647. if (vm._data.__ob__) {
  11648. vm._data.__ob__.vmCount--;
  11649. }
  11650. // call the last hook...
  11651. vm._isDestroyed = true;
  11652. // invoke destroy hooks on current rendered tree
  11653. vm.__patch__(vm._vnode, null);
  11654. // fire destroyed hook
  11655. callHook(vm, 'destroyed');
  11656. // turn off all instance listeners.
  11657. vm.$off();
  11658. // remove __vue__ reference
  11659. if (vm.$el) {
  11660. vm.$el.__vue__ = null;
  11661. }
  11662. // remove reference to DOM nodes (prevents leak)
  11663. vm.$options._parentElm = vm.$options._refElm = null;
  11664. };
  11665. }
  11666. function mountComponent (
  11667. vm,
  11668. el,
  11669. hydrating
  11670. ) {
  11671. vm.$el = el;
  11672. if (!vm.$options.render) {
  11673. vm.$options.render = createEmptyVNode;
  11674. if (process.env.NODE_ENV !== 'production') {
  11675. /* istanbul ignore if */
  11676. if ((vm.$options.template && vm.$options.template.charAt(0) !== '#') ||
  11677. vm.$options.el || el) {
  11678. warn(
  11679. 'You are using the runtime-only build of Vue where the template ' +
  11680. 'compiler is not available. Either pre-compile the templates into ' +
  11681. 'render functions, or use the compiler-included build.',
  11682. vm
  11683. );
  11684. } else {
  11685. warn(
  11686. 'Failed to mount component: template or render function not defined.',
  11687. vm
  11688. );
  11689. }
  11690. }
  11691. }
  11692. callHook(vm, 'beforeMount');
  11693. var updateComponent;
  11694. /* istanbul ignore if */
  11695. if (process.env.NODE_ENV !== 'production' && config.performance && mark) {
  11696. updateComponent = function () {
  11697. var name = vm._name;
  11698. var id = vm._uid;
  11699. var startTag = "vue-perf-start:" + id;
  11700. var endTag = "vue-perf-end:" + id;
  11701. mark(startTag);
  11702. var vnode = vm._render();
  11703. mark(endTag);
  11704. measure((name + " render"), startTag, endTag);
  11705. mark(startTag);
  11706. vm._update(vnode, hydrating);
  11707. mark(endTag);
  11708. measure((name + " patch"), startTag, endTag);
  11709. };
  11710. } else {
  11711. updateComponent = function () {
  11712. vm._update(vm._render(), hydrating);
  11713. };
  11714. }
  11715. vm._watcher = new Watcher(vm, updateComponent, noop);
  11716. hydrating = false;
  11717. // manually mounted instance, call mounted on self
  11718. // mounted is called for render-created child components in its inserted hook
  11719. if (vm.$vnode == null) {
  11720. vm._isMounted = true;
  11721. callHook(vm, 'mounted');
  11722. }
  11723. return vm
  11724. }
  11725. function updateChildComponent (
  11726. vm,
  11727. propsData,
  11728. listeners,
  11729. parentVnode,
  11730. renderChildren
  11731. ) {
  11732. // determine whether component has slot children
  11733. // we need to do this before overwriting $options._renderChildren
  11734. var hasChildren = !!(
  11735. renderChildren || // has new static slots
  11736. vm.$options._renderChildren || // has old static slots
  11737. parentVnode.data.scopedSlots || // has new scoped slots
  11738. vm.$scopedSlots !== emptyObject // has old scoped slots
  11739. );
  11740. vm.$options._parentVnode = parentVnode;
  11741. vm.$vnode = parentVnode; // update vm's placeholder node without re-render
  11742. if (vm._vnode) { // update child tree's parent
  11743. vm._vnode.parent = parentVnode;
  11744. }
  11745. vm.$options._renderChildren = renderChildren;
  11746. // update props
  11747. if (propsData && vm.$options.props) {
  11748. observerState.shouldConvert = false;
  11749. if (process.env.NODE_ENV !== 'production') {
  11750. observerState.isSettingProps = true;
  11751. }
  11752. var props = vm._props;
  11753. var propKeys = vm.$options._propKeys || [];
  11754. for (var i = 0; i < propKeys.length; i++) {
  11755. var key = propKeys[i];
  11756. props[key] = validateProp(key, vm.$options.props, propsData, vm);
  11757. }
  11758. observerState.shouldConvert = true;
  11759. if (process.env.NODE_ENV !== 'production') {
  11760. observerState.isSettingProps = false;
  11761. }
  11762. // keep a copy of raw propsData
  11763. vm.$options.propsData = propsData;
  11764. }
  11765. // update listeners
  11766. if (listeners) {
  11767. var oldListeners = vm.$options._parentListeners;
  11768. vm.$options._parentListeners = listeners;
  11769. updateComponentListeners(vm, listeners, oldListeners);
  11770. }
  11771. // resolve slots + force update if has children
  11772. if (hasChildren) {
  11773. vm.$slots = resolveSlots(renderChildren, parentVnode.context);
  11774. vm.$forceUpdate();
  11775. }
  11776. }
  11777. function isInInactiveTree (vm) {
  11778. while (vm && (vm = vm.$parent)) {
  11779. if (vm._inactive) { return true }
  11780. }
  11781. return false
  11782. }
  11783. function activateChildComponent (vm, direct) {
  11784. if (direct) {
  11785. vm._directInactive = false;
  11786. if (isInInactiveTree(vm)) {
  11787. return
  11788. }
  11789. } else if (vm._directInactive) {
  11790. return
  11791. }
  11792. if (vm._inactive || vm._inactive === null) {
  11793. vm._inactive = false;
  11794. for (var i = 0; i < vm.$children.length; i++) {
  11795. activateChildComponent(vm.$children[i]);
  11796. }
  11797. callHook(vm, 'activated');
  11798. }
  11799. }
  11800. function deactivateChildComponent (vm, direct) {
  11801. if (direct) {
  11802. vm._directInactive = true;
  11803. if (isInInactiveTree(vm)) {
  11804. return
  11805. }
  11806. }
  11807. if (!vm._inactive) {
  11808. vm._inactive = true;
  11809. for (var i = 0; i < vm.$children.length; i++) {
  11810. deactivateChildComponent(vm.$children[i]);
  11811. }
  11812. callHook(vm, 'deactivated');
  11813. }
  11814. }
  11815. function callHook (vm, hook) {
  11816. var handlers = vm.$options[hook];
  11817. if (handlers) {
  11818. for (var i = 0, j = handlers.length; i < j; i++) {
  11819. try {
  11820. handlers[i].call(vm);
  11821. } catch (e) {
  11822. handleError(e, vm, (hook + " hook"));
  11823. }
  11824. }
  11825. }
  11826. if (vm._hasHookEvent) {
  11827. vm.$emit('hook:' + hook);
  11828. }
  11829. }
  11830. /* */
  11831. var MAX_UPDATE_COUNT = 100;
  11832. var queue = [];
  11833. var activatedChildren = [];
  11834. var has = {};
  11835. var circular = {};
  11836. var waiting = false;
  11837. var flushing = false;
  11838. var index = 0;
  11839. /**
  11840. * Reset the scheduler's state.
  11841. */
  11842. function resetSchedulerState () {
  11843. index = queue.length = activatedChildren.length = 0;
  11844. has = {};
  11845. if (process.env.NODE_ENV !== 'production') {
  11846. circular = {};
  11847. }
  11848. waiting = flushing = false;
  11849. }
  11850. /**
  11851. * Flush both queues and run the watchers.
  11852. */
  11853. function flushSchedulerQueue () {
  11854. flushing = true;
  11855. var watcher, id;
  11856. // Sort queue before flush.
  11857. // This ensures that:
  11858. // 1. Components are updated from parent to child. (because parent is always
  11859. // created before the child)
  11860. // 2. A component's user watchers are run before its render watcher (because
  11861. // user watchers are created before the render watcher)
  11862. // 3. If a component is destroyed during a parent component's watcher run,
  11863. // its watchers can be skipped.
  11864. queue.sort(function (a, b) { return a.id - b.id; });
  11865. // do not cache length because more watchers might be pushed
  11866. // as we run existing watchers
  11867. for (index = 0; index < queue.length; index++) {
  11868. watcher = queue[index];
  11869. id = watcher.id;
  11870. has[id] = null;
  11871. watcher.run();
  11872. // in dev build, check and stop circular updates.
  11873. if (process.env.NODE_ENV !== 'production' && has[id] != null) {
  11874. circular[id] = (circular[id] || 0) + 1;
  11875. if (circular[id] > MAX_UPDATE_COUNT) {
  11876. warn(
  11877. 'You may have an infinite update loop ' + (
  11878. watcher.user
  11879. ? ("in watcher with expression \"" + (watcher.expression) + "\"")
  11880. : "in a component render function."
  11881. ),
  11882. watcher.vm
  11883. );
  11884. break
  11885. }
  11886. }
  11887. }
  11888. // keep copies of post queues before resetting state
  11889. var activatedQueue = activatedChildren.slice();
  11890. var updatedQueue = queue.slice();
  11891. resetSchedulerState();
  11892. // call component updated and activated hooks
  11893. callActivatedHooks(activatedQueue);
  11894. callUpdateHooks(updatedQueue);
  11895. // devtool hook
  11896. /* istanbul ignore if */
  11897. if (devtools && config.devtools) {
  11898. devtools.emit('flush');
  11899. }
  11900. }
  11901. function callUpdateHooks (queue) {
  11902. var i = queue.length;
  11903. while (i--) {
  11904. var watcher = queue[i];
  11905. var vm = watcher.vm;
  11906. if (vm._watcher === watcher && vm._isMounted) {
  11907. callHook(vm, 'updated');
  11908. }
  11909. }
  11910. }
  11911. /**
  11912. * Queue a kept-alive component that was activated during patch.
  11913. * The queue will be processed after the entire tree has been patched.
  11914. */
  11915. function queueActivatedComponent (vm) {
  11916. // setting _inactive to false here so that a render function can
  11917. // rely on checking whether it's in an inactive tree (e.g. router-view)
  11918. vm._inactive = false;
  11919. activatedChildren.push(vm);
  11920. }
  11921. function callActivatedHooks (queue) {
  11922. for (var i = 0; i < queue.length; i++) {
  11923. queue[i]._inactive = true;
  11924. activateChildComponent(queue[i], true /* true */);
  11925. }
  11926. }
  11927. /**
  11928. * Push a watcher into the watcher queue.
  11929. * Jobs with duplicate IDs will be skipped unless it's
  11930. * pushed when the queue is being flushed.
  11931. */
  11932. function queueWatcher (watcher) {
  11933. var id = watcher.id;
  11934. if (has[id] == null) {
  11935. has[id] = true;
  11936. if (!flushing) {
  11937. queue.push(watcher);
  11938. } else {
  11939. // if already flushing, splice the watcher based on its id
  11940. // if already past its id, it will be run next immediately.
  11941. var i = queue.length - 1;
  11942. while (i > index && queue[i].id > watcher.id) {
  11943. i--;
  11944. }
  11945. queue.splice(i + 1, 0, watcher);
  11946. }
  11947. // queue the flush
  11948. if (!waiting) {
  11949. waiting = true;
  11950. nextTick(flushSchedulerQueue);
  11951. }
  11952. }
  11953. }
  11954. /* */
  11955. var uid$2 = 0;
  11956. /**
  11957. * A watcher parses an expression, collects dependencies,
  11958. * and fires callback when the expression value changes.
  11959. * This is used for both the $watch() api and directives.
  11960. */
  11961. var Watcher = function Watcher (
  11962. vm,
  11963. expOrFn,
  11964. cb,
  11965. options
  11966. ) {
  11967. this.vm = vm;
  11968. vm._watchers.push(this);
  11969. // options
  11970. if (options) {
  11971. this.deep = !!options.deep;
  11972. this.user = !!options.user;
  11973. this.lazy = !!options.lazy;
  11974. this.sync = !!options.sync;
  11975. } else {
  11976. this.deep = this.user = this.lazy = this.sync = false;
  11977. }
  11978. this.cb = cb;
  11979. this.id = ++uid$2; // uid for batching
  11980. this.active = true;
  11981. this.dirty = this.lazy; // for lazy watchers
  11982. this.deps = [];
  11983. this.newDeps = [];
  11984. this.depIds = new _Set();
  11985. this.newDepIds = new _Set();
  11986. this.expression = process.env.NODE_ENV !== 'production'
  11987. ? expOrFn.toString()
  11988. : '';
  11989. // parse expression for getter
  11990. if (typeof expOrFn === 'function') {
  11991. this.getter = expOrFn;
  11992. } else {
  11993. this.getter = parsePath(expOrFn);
  11994. if (!this.getter) {
  11995. this.getter = function () {};
  11996. process.env.NODE_ENV !== 'production' && warn(
  11997. "Failed watching path: \"" + expOrFn + "\" " +
  11998. 'Watcher only accepts simple dot-delimited paths. ' +
  11999. 'For full control, use a function instead.',
  12000. vm
  12001. );
  12002. }
  12003. }
  12004. this.value = this.lazy
  12005. ? undefined
  12006. : this.get();
  12007. };
  12008. /**
  12009. * Evaluate the getter, and re-collect dependencies.
  12010. */
  12011. Watcher.prototype.get = function get () {
  12012. pushTarget(this);
  12013. var value;
  12014. var vm = this.vm;
  12015. if (this.user) {
  12016. try {
  12017. value = this.getter.call(vm, vm);
  12018. } catch (e) {
  12019. handleError(e, vm, ("getter for watcher \"" + (this.expression) + "\""));
  12020. }
  12021. } else {
  12022. value = this.getter.call(vm, vm);
  12023. }
  12024. // "touch" every property so they are all tracked as
  12025. // dependencies for deep watching
  12026. if (this.deep) {
  12027. traverse(value);
  12028. }
  12029. popTarget();
  12030. this.cleanupDeps();
  12031. return value
  12032. };
  12033. /**
  12034. * Add a dependency to this directive.
  12035. */
  12036. Watcher.prototype.addDep = function addDep (dep) {
  12037. var id = dep.id;
  12038. if (!this.newDepIds.has(id)) {
  12039. this.newDepIds.add(id);
  12040. this.newDeps.push(dep);
  12041. if (!this.depIds.has(id)) {
  12042. dep.addSub(this);
  12043. }
  12044. }
  12045. };
  12046. /**
  12047. * Clean up for dependency collection.
  12048. */
  12049. Watcher.prototype.cleanupDeps = function cleanupDeps () {
  12050. var this$1 = this;
  12051. var i = this.deps.length;
  12052. while (i--) {
  12053. var dep = this$1.deps[i];
  12054. if (!this$1.newDepIds.has(dep.id)) {
  12055. dep.removeSub(this$1);
  12056. }
  12057. }
  12058. var tmp = this.depIds;
  12059. this.depIds = this.newDepIds;
  12060. this.newDepIds = tmp;
  12061. this.newDepIds.clear();
  12062. tmp = this.deps;
  12063. this.deps = this.newDeps;
  12064. this.newDeps = tmp;
  12065. this.newDeps.length = 0;
  12066. };
  12067. /**
  12068. * Subscriber interface.
  12069. * Will be called when a dependency changes.
  12070. */
  12071. Watcher.prototype.update = function update () {
  12072. /* istanbul ignore else */
  12073. if (this.lazy) {
  12074. this.dirty = true;
  12075. } else if (this.sync) {
  12076. this.run();
  12077. } else {
  12078. queueWatcher(this);
  12079. }
  12080. };
  12081. /**
  12082. * Scheduler job interface.
  12083. * Will be called by the scheduler.
  12084. */
  12085. Watcher.prototype.run = function run () {
  12086. if (this.active) {
  12087. var value = this.get();
  12088. if (
  12089. value !== this.value ||
  12090. // Deep watchers and watchers on Object/Arrays should fire even
  12091. // when the value is the same, because the value may
  12092. // have mutated.
  12093. isObject(value) ||
  12094. this.deep
  12095. ) {
  12096. // set new value
  12097. var oldValue = this.value;
  12098. this.value = value;
  12099. if (this.user) {
  12100. try {
  12101. this.cb.call(this.vm, value, oldValue);
  12102. } catch (e) {
  12103. handleError(e, this.vm, ("callback for watcher \"" + (this.expression) + "\""));
  12104. }
  12105. } else {
  12106. this.cb.call(this.vm, value, oldValue);
  12107. }
  12108. }
  12109. }
  12110. };
  12111. /**
  12112. * Evaluate the value of the watcher.
  12113. * This only gets called for lazy watchers.
  12114. */
  12115. Watcher.prototype.evaluate = function evaluate () {
  12116. this.value = this.get();
  12117. this.dirty = false;
  12118. };
  12119. /**
  12120. * Depend on all deps collected by this watcher.
  12121. */
  12122. Watcher.prototype.depend = function depend () {
  12123. var this$1 = this;
  12124. var i = this.deps.length;
  12125. while (i--) {
  12126. this$1.deps[i].depend();
  12127. }
  12128. };
  12129. /**
  12130. * Remove self from all dependencies' subscriber list.
  12131. */
  12132. Watcher.prototype.teardown = function teardown () {
  12133. var this$1 = this;
  12134. if (this.active) {
  12135. // remove self from vm's watcher list
  12136. // this is a somewhat expensive operation so we skip it
  12137. // if the vm is being destroyed.
  12138. if (!this.vm._isBeingDestroyed) {
  12139. remove(this.vm._watchers, this);
  12140. }
  12141. var i = this.deps.length;
  12142. while (i--) {
  12143. this$1.deps[i].removeSub(this$1);
  12144. }
  12145. this.active = false;
  12146. }
  12147. };
  12148. /**
  12149. * Recursively traverse an object to evoke all converted
  12150. * getters, so that every nested property inside the object
  12151. * is collected as a "deep" dependency.
  12152. */
  12153. var seenObjects = new _Set();
  12154. function traverse (val) {
  12155. seenObjects.clear();
  12156. _traverse(val, seenObjects);
  12157. }
  12158. function _traverse (val, seen) {
  12159. var i, keys;
  12160. var isA = Array.isArray(val);
  12161. if ((!isA && !isObject(val)) || !Object.isExtensible(val)) {
  12162. return
  12163. }
  12164. if (val.__ob__) {
  12165. var depId = val.__ob__.dep.id;
  12166. if (seen.has(depId)) {
  12167. return
  12168. }
  12169. seen.add(depId);
  12170. }
  12171. if (isA) {
  12172. i = val.length;
  12173. while (i--) { _traverse(val[i], seen); }
  12174. } else {
  12175. keys = Object.keys(val);
  12176. i = keys.length;
  12177. while (i--) { _traverse(val[keys[i]], seen); }
  12178. }
  12179. }
  12180. /* */
  12181. var sharedPropertyDefinition = {
  12182. enumerable: true,
  12183. configurable: true,
  12184. get: noop,
  12185. set: noop
  12186. };
  12187. function proxy (target, sourceKey, key) {
  12188. sharedPropertyDefinition.get = function proxyGetter () {
  12189. return this[sourceKey][key]
  12190. };
  12191. sharedPropertyDefinition.set = function proxySetter (val) {
  12192. this[sourceKey][key] = val;
  12193. };
  12194. Object.defineProperty(target, key, sharedPropertyDefinition);
  12195. }
  12196. function initState (vm) {
  12197. vm._watchers = [];
  12198. var opts = vm.$options;
  12199. if (opts.props) { initProps(vm, opts.props); }
  12200. if (opts.methods) { initMethods(vm, opts.methods); }
  12201. if (opts.data) {
  12202. initData(vm);
  12203. } else {
  12204. observe(vm._data = {}, true /* asRootData */);
  12205. }
  12206. if (opts.computed) { initComputed(vm, opts.computed); }
  12207. if (opts.watch) { initWatch(vm, opts.watch); }
  12208. }
  12209. var isReservedProp = {
  12210. key: 1,
  12211. ref: 1,
  12212. slot: 1
  12213. };
  12214. function initProps (vm, propsOptions) {
  12215. var propsData = vm.$options.propsData || {};
  12216. var props = vm._props = {};
  12217. // cache prop keys so that future props updates can iterate using Array
  12218. // instead of dynamic object key enumeration.
  12219. var keys = vm.$options._propKeys = [];
  12220. var isRoot = !vm.$parent;
  12221. // root instance props should be converted
  12222. observerState.shouldConvert = isRoot;
  12223. var loop = function ( key ) {
  12224. keys.push(key);
  12225. var value = validateProp(key, propsOptions, propsData, vm);
  12226. /* istanbul ignore else */
  12227. if (process.env.NODE_ENV !== 'production') {
  12228. if (isReservedProp[key] || config.isReservedAttr(key)) {
  12229. warn(
  12230. ("\"" + key + "\" is a reserved attribute and cannot be used as component prop."),
  12231. vm
  12232. );
  12233. }
  12234. defineReactive$$1(props, key, value, function () {
  12235. if (vm.$parent && !observerState.isSettingProps) {
  12236. warn(
  12237. "Avoid mutating a prop directly since the value will be " +
  12238. "overwritten whenever the parent component re-renders. " +
  12239. "Instead, use a data or computed property based on the prop's " +
  12240. "value. Prop being mutated: \"" + key + "\"",
  12241. vm
  12242. );
  12243. }
  12244. });
  12245. } else {
  12246. defineReactive$$1(props, key, value);
  12247. }
  12248. // static props are already proxied on the component's prototype
  12249. // during Vue.extend(). We only need to proxy props defined at
  12250. // instantiation here.
  12251. if (!(key in vm)) {
  12252. proxy(vm, "_props", key);
  12253. }
  12254. };
  12255. for (var key in propsOptions) loop( key );
  12256. observerState.shouldConvert = true;
  12257. }
  12258. function initData (vm) {
  12259. var data = vm.$options.data;
  12260. data = vm._data = typeof data === 'function'
  12261. ? getData(data, vm)
  12262. : data || {};
  12263. if (!isPlainObject(data)) {
  12264. data = {};
  12265. process.env.NODE_ENV !== 'production' && warn(
  12266. 'data functions should return an object:\n' +
  12267. 'https://vuejs.org/v2/guide/components.html#data-Must-Be-a-Function',
  12268. vm
  12269. );
  12270. }
  12271. // proxy data on instance
  12272. var keys = Object.keys(data);
  12273. var props = vm.$options.props;
  12274. var i = keys.length;
  12275. while (i--) {
  12276. if (props && hasOwn(props, keys[i])) {
  12277. process.env.NODE_ENV !== 'production' && warn(
  12278. "The data property \"" + (keys[i]) + "\" is already declared as a prop. " +
  12279. "Use prop default value instead.",
  12280. vm
  12281. );
  12282. } else if (!isReserved(keys[i])) {
  12283. proxy(vm, "_data", keys[i]);
  12284. }
  12285. }
  12286. // observe data
  12287. observe(data, true /* asRootData */);
  12288. }
  12289. function getData (data, vm) {
  12290. try {
  12291. return data.call(vm)
  12292. } catch (e) {
  12293. handleError(e, vm, "data()");
  12294. return {}
  12295. }
  12296. }
  12297. var computedWatcherOptions = { lazy: true };
  12298. function initComputed (vm, computed) {
  12299. var watchers = vm._computedWatchers = Object.create(null);
  12300. for (var key in computed) {
  12301. var userDef = computed[key];
  12302. var getter = typeof userDef === 'function' ? userDef : userDef.get;
  12303. if (process.env.NODE_ENV !== 'production') {
  12304. if (getter === undefined) {
  12305. warn(
  12306. ("No getter function has been defined for computed property \"" + key + "\"."),
  12307. vm
  12308. );
  12309. getter = noop;
  12310. }
  12311. }
  12312. // create internal watcher for the computed property.
  12313. watchers[key] = new Watcher(vm, getter, noop, computedWatcherOptions);
  12314. // component-defined computed properties are already defined on the
  12315. // component prototype. We only need to define computed properties defined
  12316. // at instantiation here.
  12317. if (!(key in vm)) {
  12318. defineComputed(vm, key, userDef);
  12319. } else if (process.env.NODE_ENV !== 'production') {
  12320. if (key in vm.$data) {
  12321. warn(("The computed property \"" + key + "\" is already defined in data."), vm);
  12322. } else if (vm.$options.props && key in vm.$options.props) {
  12323. warn(("The computed property \"" + key + "\" is already defined as a prop."), vm);
  12324. }
  12325. }
  12326. }
  12327. }
  12328. function defineComputed (target, key, userDef) {
  12329. if (typeof userDef === 'function') {
  12330. sharedPropertyDefinition.get = createComputedGetter(key);
  12331. sharedPropertyDefinition.set = noop;
  12332. } else {
  12333. sharedPropertyDefinition.get = userDef.get
  12334. ? userDef.cache !== false
  12335. ? createComputedGetter(key)
  12336. : userDef.get
  12337. : noop;
  12338. sharedPropertyDefinition.set = userDef.set
  12339. ? userDef.set
  12340. : noop;
  12341. }
  12342. Object.defineProperty(target, key, sharedPropertyDefinition);
  12343. }
  12344. function createComputedGetter (key) {
  12345. return function computedGetter () {
  12346. var watcher = this._computedWatchers && this._computedWatchers[key];
  12347. if (watcher) {
  12348. if (watcher.dirty) {
  12349. watcher.evaluate();
  12350. }
  12351. if (Dep.target) {
  12352. watcher.depend();
  12353. }
  12354. return watcher.value
  12355. }
  12356. }
  12357. }
  12358. function initMethods (vm, methods) {
  12359. var props = vm.$options.props;
  12360. for (var key in methods) {
  12361. vm[key] = methods[key] == null ? noop : bind(methods[key], vm);
  12362. if (process.env.NODE_ENV !== 'production') {
  12363. if (methods[key] == null) {
  12364. warn(
  12365. "method \"" + key + "\" has an undefined value in the component definition. " +
  12366. "Did you reference the function correctly?",
  12367. vm
  12368. );
  12369. }
  12370. if (props && hasOwn(props, key)) {
  12371. warn(
  12372. ("method \"" + key + "\" has already been defined as a prop."),
  12373. vm
  12374. );
  12375. }
  12376. }
  12377. }
  12378. }
  12379. function initWatch (vm, watch) {
  12380. for (var key in watch) {
  12381. var handler = watch[key];
  12382. if (Array.isArray(handler)) {
  12383. for (var i = 0; i < handler.length; i++) {
  12384. createWatcher(vm, key, handler[i]);
  12385. }
  12386. } else {
  12387. createWatcher(vm, key, handler);
  12388. }
  12389. }
  12390. }
  12391. function createWatcher (vm, key, handler) {
  12392. var options;
  12393. if (isPlainObject(handler)) {
  12394. options = handler;
  12395. handler = handler.handler;
  12396. }
  12397. if (typeof handler === 'string') {
  12398. handler = vm[handler];
  12399. }
  12400. vm.$watch(key, handler, options);
  12401. }
  12402. function stateMixin (Vue) {
  12403. // flow somehow has problems with directly declared definition object
  12404. // when using Object.defineProperty, so we have to procedurally build up
  12405. // the object here.
  12406. var dataDef = {};
  12407. dataDef.get = function () { return this._data };
  12408. var propsDef = {};
  12409. propsDef.get = function () { return this._props };
  12410. if (process.env.NODE_ENV !== 'production') {
  12411. dataDef.set = function (newData) {
  12412. warn(
  12413. 'Avoid replacing instance root $data. ' +
  12414. 'Use nested data properties instead.',
  12415. this
  12416. );
  12417. };
  12418. propsDef.set = function () {
  12419. warn("$props is readonly.", this);
  12420. };
  12421. }
  12422. Object.defineProperty(Vue.prototype, '$data', dataDef);
  12423. Object.defineProperty(Vue.prototype, '$props', propsDef);
  12424. Vue.prototype.$set = set;
  12425. Vue.prototype.$delete = del;
  12426. Vue.prototype.$watch = function (
  12427. expOrFn,
  12428. cb,
  12429. options
  12430. ) {
  12431. var vm = this;
  12432. options = options || {};
  12433. options.user = true;
  12434. var watcher = new Watcher(vm, expOrFn, cb, options);
  12435. if (options.immediate) {
  12436. cb.call(vm, watcher.value);
  12437. }
  12438. return function unwatchFn () {
  12439. watcher.teardown();
  12440. }
  12441. };
  12442. }
  12443. /* */
  12444. function initProvide (vm) {
  12445. var provide = vm.$options.provide;
  12446. if (provide) {
  12447. vm._provided = typeof provide === 'function'
  12448. ? provide.call(vm)
  12449. : provide;
  12450. }
  12451. }
  12452. function initInjections (vm) {
  12453. var result = resolveInject(vm.$options.inject, vm);
  12454. if (result) {
  12455. Object.keys(result).forEach(function (key) {
  12456. /* istanbul ignore else */
  12457. if (process.env.NODE_ENV !== 'production') {
  12458. defineReactive$$1(vm, key, result[key], function () {
  12459. warn(
  12460. "Avoid mutating an injected value directly since the changes will be " +
  12461. "overwritten whenever the provided component re-renders. " +
  12462. "injection being mutated: \"" + key + "\"",
  12463. vm
  12464. );
  12465. });
  12466. } else {
  12467. defineReactive$$1(vm, key, result[key]);
  12468. }
  12469. });
  12470. }
  12471. }
  12472. function resolveInject (inject, vm) {
  12473. if (inject) {
  12474. // inject is :any because flow is not smart enough to figure out cached
  12475. // isArray here
  12476. var isArray = Array.isArray(inject);
  12477. var result = Object.create(null);
  12478. var keys = isArray
  12479. ? inject
  12480. : hasSymbol
  12481. ? Reflect.ownKeys(inject)
  12482. : Object.keys(inject);
  12483. for (var i = 0; i < keys.length; i++) {
  12484. var key = keys[i];
  12485. var provideKey = isArray ? key : inject[key];
  12486. var source = vm;
  12487. while (source) {
  12488. if (source._provided && provideKey in source._provided) {
  12489. result[key] = source._provided[provideKey];
  12490. break
  12491. }
  12492. source = source.$parent;
  12493. }
  12494. }
  12495. return result
  12496. }
  12497. }
  12498. /* */
  12499. function createFunctionalComponent (
  12500. Ctor,
  12501. propsData,
  12502. data,
  12503. context,
  12504. children
  12505. ) {
  12506. var props = {};
  12507. var propOptions = Ctor.options.props;
  12508. if (isDef(propOptions)) {
  12509. for (var key in propOptions) {
  12510. props[key] = validateProp(key, propOptions, propsData || {});
  12511. }
  12512. } else {
  12513. if (isDef(data.attrs)) { mergeProps(props, data.attrs); }
  12514. if (isDef(data.props)) { mergeProps(props, data.props); }
  12515. }
  12516. // ensure the createElement function in functional components
  12517. // gets a unique context - this is necessary for correct named slot check
  12518. var _context = Object.create(context);
  12519. var h = function (a, b, c, d) { return createElement(_context, a, b, c, d, true); };
  12520. var vnode = Ctor.options.render.call(null, h, {
  12521. data: data,
  12522. props: props,
  12523. children: children,
  12524. parent: context,
  12525. listeners: data.on || {},
  12526. injections: resolveInject(Ctor.options.inject, context),
  12527. slots: function () { return resolveSlots(children, context); }
  12528. });
  12529. if (vnode instanceof VNode) {
  12530. vnode.functionalContext = context;
  12531. vnode.functionalOptions = Ctor.options;
  12532. if (data.slot) {
  12533. (vnode.data || (vnode.data = {})).slot = data.slot;
  12534. }
  12535. }
  12536. return vnode
  12537. }
  12538. function mergeProps (to, from) {
  12539. for (var key in from) {
  12540. to[camelize(key)] = from[key];
  12541. }
  12542. }
  12543. /* */
  12544. // hooks to be invoked on component VNodes during patch
  12545. var componentVNodeHooks = {
  12546. init: function init (
  12547. vnode,
  12548. hydrating,
  12549. parentElm,
  12550. refElm
  12551. ) {
  12552. if (!vnode.componentInstance || vnode.componentInstance._isDestroyed) {
  12553. var child = vnode.componentInstance = createComponentInstanceForVnode(
  12554. vnode,
  12555. activeInstance,
  12556. parentElm,
  12557. refElm
  12558. );
  12559. child.$mount(hydrating ? vnode.elm : undefined, hydrating);
  12560. } else if (vnode.data.keepAlive) {
  12561. // kept-alive components, treat as a patch
  12562. var mountedNode = vnode; // work around flow
  12563. componentVNodeHooks.prepatch(mountedNode, mountedNode);
  12564. }
  12565. },
  12566. prepatch: function prepatch (oldVnode, vnode) {
  12567. var options = vnode.componentOptions;
  12568. var child = vnode.componentInstance = oldVnode.componentInstance;
  12569. updateChildComponent(
  12570. child,
  12571. options.propsData, // updated props
  12572. options.listeners, // updated listeners
  12573. vnode, // new parent vnode
  12574. options.children // new children
  12575. );
  12576. },
  12577. insert: function insert (vnode) {
  12578. var context = vnode.context;
  12579. var componentInstance = vnode.componentInstance;
  12580. if (!componentInstance._isMounted) {
  12581. componentInstance._isMounted = true;
  12582. callHook(componentInstance, 'mounted');
  12583. }
  12584. if (vnode.data.keepAlive) {
  12585. if (context._isMounted) {
  12586. // vue-router#1212
  12587. // During updates, a kept-alive component's child components may
  12588. // change, so directly walking the tree here may call activated hooks
  12589. // on incorrect children. Instead we push them into a queue which will
  12590. // be processed after the whole patch process ended.
  12591. queueActivatedComponent(componentInstance);
  12592. } else {
  12593. activateChildComponent(componentInstance, true /* direct */);
  12594. }
  12595. }
  12596. },
  12597. destroy: function destroy (vnode) {
  12598. var componentInstance = vnode.componentInstance;
  12599. if (!componentInstance._isDestroyed) {
  12600. if (!vnode.data.keepAlive) {
  12601. componentInstance.$destroy();
  12602. } else {
  12603. deactivateChildComponent(componentInstance, true /* direct */);
  12604. }
  12605. }
  12606. }
  12607. };
  12608. var hooksToMerge = Object.keys(componentVNodeHooks);
  12609. function createComponent (
  12610. Ctor,
  12611. data,
  12612. context,
  12613. children,
  12614. tag
  12615. ) {
  12616. if (isUndef(Ctor)) {
  12617. return
  12618. }
  12619. var baseCtor = context.$options._base;
  12620. // plain options object: turn it into a constructor
  12621. if (isObject(Ctor)) {
  12622. Ctor = baseCtor.extend(Ctor);
  12623. }
  12624. // if at this stage it's not a constructor or an async component factory,
  12625. // reject.
  12626. if (typeof Ctor !== 'function') {
  12627. if (process.env.NODE_ENV !== 'production') {
  12628. warn(("Invalid Component definition: " + (String(Ctor))), context);
  12629. }
  12630. return
  12631. }
  12632. // async component
  12633. if (isUndef(Ctor.cid)) {
  12634. Ctor = resolveAsyncComponent(Ctor, baseCtor, context);
  12635. if (Ctor === undefined) {
  12636. // return nothing if this is indeed an async component
  12637. // wait for the callback to trigger parent update.
  12638. return
  12639. }
  12640. }
  12641. // resolve constructor options in case global mixins are applied after
  12642. // component constructor creation
  12643. resolveConstructorOptions(Ctor);
  12644. data = data || {};
  12645. // transform component v-model data into props & events
  12646. if (isDef(data.model)) {
  12647. transformModel(Ctor.options, data);
  12648. }
  12649. // extract props
  12650. var propsData = extractPropsFromVNodeData(data, Ctor, tag);
  12651. // functional component
  12652. if (isTrue(Ctor.options.functional)) {
  12653. return createFunctionalComponent(Ctor, propsData, data, context, children)
  12654. }
  12655. // extract listeners, since these needs to be treated as
  12656. // child component listeners instead of DOM listeners
  12657. var listeners = data.on;
  12658. // replace with listeners with .native modifier
  12659. data.on = data.nativeOn;
  12660. if (isTrue(Ctor.options.abstract)) {
  12661. // abstract components do not keep anything
  12662. // other than props & listeners
  12663. data = {};
  12664. }
  12665. // merge component management hooks onto the placeholder node
  12666. mergeHooks(data);
  12667. // return a placeholder vnode
  12668. var name = Ctor.options.name || tag;
  12669. var vnode = new VNode(
  12670. ("vue-component-" + (Ctor.cid) + (name ? ("-" + name) : '')),
  12671. data, undefined, undefined, undefined, context,
  12672. { Ctor: Ctor, propsData: propsData, listeners: listeners, tag: tag, children: children }
  12673. );
  12674. return vnode
  12675. }
  12676. function createComponentInstanceForVnode (
  12677. vnode, // we know it's MountedComponentVNode but flow doesn't
  12678. parent, // activeInstance in lifecycle state
  12679. parentElm,
  12680. refElm
  12681. ) {
  12682. var vnodeComponentOptions = vnode.componentOptions;
  12683. var options = {
  12684. _isComponent: true,
  12685. parent: parent,
  12686. propsData: vnodeComponentOptions.propsData,
  12687. _componentTag: vnodeComponentOptions.tag,
  12688. _parentVnode: vnode,
  12689. _parentListeners: vnodeComponentOptions.listeners,
  12690. _renderChildren: vnodeComponentOptions.children,
  12691. _parentElm: parentElm || null,
  12692. _refElm: refElm || null
  12693. };
  12694. // check inline-template render functions
  12695. var inlineTemplate = vnode.data.inlineTemplate;
  12696. if (isDef(inlineTemplate)) {
  12697. options.render = inlineTemplate.render;
  12698. options.staticRenderFns = inlineTemplate.staticRenderFns;
  12699. }
  12700. return new vnodeComponentOptions.Ctor(options)
  12701. }
  12702. function mergeHooks (data) {
  12703. if (!data.hook) {
  12704. data.hook = {};
  12705. }
  12706. for (var i = 0; i < hooksToMerge.length; i++) {
  12707. var key = hooksToMerge[i];
  12708. var fromParent = data.hook[key];
  12709. var ours = componentVNodeHooks[key];
  12710. data.hook[key] = fromParent ? mergeHook$1(ours, fromParent) : ours;
  12711. }
  12712. }
  12713. function mergeHook$1 (one, two) {
  12714. return function (a, b, c, d) {
  12715. one(a, b, c, d);
  12716. two(a, b, c, d);
  12717. }
  12718. }
  12719. // transform component v-model info (value and callback) into
  12720. // prop and event handler respectively.
  12721. function transformModel (options, data) {
  12722. var prop = (options.model && options.model.prop) || 'value';
  12723. var event = (options.model && options.model.event) || 'input';(data.props || (data.props = {}))[prop] = data.model.value;
  12724. var on = data.on || (data.on = {});
  12725. if (isDef(on[event])) {
  12726. on[event] = [data.model.callback].concat(on[event]);
  12727. } else {
  12728. on[event] = data.model.callback;
  12729. }
  12730. }
  12731. /* */
  12732. var SIMPLE_NORMALIZE = 1;
  12733. var ALWAYS_NORMALIZE = 2;
  12734. // wrapper function for providing a more flexible interface
  12735. // without getting yelled at by flow
  12736. function createElement (
  12737. context,
  12738. tag,
  12739. data,
  12740. children,
  12741. normalizationType,
  12742. alwaysNormalize
  12743. ) {
  12744. if (Array.isArray(data) || isPrimitive(data)) {
  12745. normalizationType = children;
  12746. children = data;
  12747. data = undefined;
  12748. }
  12749. if (isTrue(alwaysNormalize)) {
  12750. normalizationType = ALWAYS_NORMALIZE;
  12751. }
  12752. return _createElement(context, tag, data, children, normalizationType)
  12753. }
  12754. function _createElement (
  12755. context,
  12756. tag,
  12757. data,
  12758. children,
  12759. normalizationType
  12760. ) {
  12761. if (isDef(data) && isDef((data).__ob__)) {
  12762. process.env.NODE_ENV !== 'production' && warn(
  12763. "Avoid using observed data object as vnode data: " + (JSON.stringify(data)) + "\n" +
  12764. 'Always create fresh vnode data objects in each render!',
  12765. context
  12766. );
  12767. return createEmptyVNode()
  12768. }
  12769. if (!tag) {
  12770. // in case of component :is set to falsy value
  12771. return createEmptyVNode()
  12772. }
  12773. // support single function children as default scoped slot
  12774. if (Array.isArray(children) &&
  12775. typeof children[0] === 'function'
  12776. ) {
  12777. data = data || {};
  12778. data.scopedSlots = { default: children[0] };
  12779. children.length = 0;
  12780. }
  12781. if (normalizationType === ALWAYS_NORMALIZE) {
  12782. children = normalizeChildren(children);
  12783. } else if (normalizationType === SIMPLE_NORMALIZE) {
  12784. children = simpleNormalizeChildren(children);
  12785. }
  12786. var vnode, ns;
  12787. if (typeof tag === 'string') {
  12788. var Ctor;
  12789. ns = config.getTagNamespace(tag);
  12790. if (config.isReservedTag(tag)) {
  12791. // platform built-in elements
  12792. vnode = new VNode(
  12793. config.parsePlatformTagName(tag), data, children,
  12794. undefined, undefined, context
  12795. );
  12796. } else if (isDef(Ctor = resolveAsset(context.$options, 'components', tag))) {
  12797. // component
  12798. vnode = createComponent(Ctor, data, context, children, tag);
  12799. } else {
  12800. // unknown or unlisted namespaced elements
  12801. // check at runtime because it may get assigned a namespace when its
  12802. // parent normalizes children
  12803. vnode = new VNode(
  12804. tag, data, children,
  12805. undefined, undefined, context
  12806. );
  12807. }
  12808. } else {
  12809. // direct component options / constructor
  12810. vnode = createComponent(tag, data, context, children);
  12811. }
  12812. if (isDef(vnode)) {
  12813. if (ns) { applyNS(vnode, ns); }
  12814. return vnode
  12815. } else {
  12816. return createEmptyVNode()
  12817. }
  12818. }
  12819. function applyNS (vnode, ns) {
  12820. vnode.ns = ns;
  12821. if (vnode.tag === 'foreignObject') {
  12822. // use default namespace inside foreignObject
  12823. return
  12824. }
  12825. if (isDef(vnode.children)) {
  12826. for (var i = 0, l = vnode.children.length; i < l; i++) {
  12827. var child = vnode.children[i];
  12828. if (isDef(child.tag) && isUndef(child.ns)) {
  12829. applyNS(child, ns);
  12830. }
  12831. }
  12832. }
  12833. }
  12834. /* */
  12835. /**
  12836. * Runtime helper for rendering v-for lists.
  12837. */
  12838. function renderList (
  12839. val,
  12840. render
  12841. ) {
  12842. var ret, i, l, keys, key;
  12843. if (Array.isArray(val) || typeof val === 'string') {
  12844. ret = new Array(val.length);
  12845. for (i = 0, l = val.length; i < l; i++) {
  12846. ret[i] = render(val[i], i);
  12847. }
  12848. } else if (typeof val === 'number') {
  12849. ret = new Array(val);
  12850. for (i = 0; i < val; i++) {
  12851. ret[i] = render(i + 1, i);
  12852. }
  12853. } else if (isObject(val)) {
  12854. keys = Object.keys(val);
  12855. ret = new Array(keys.length);
  12856. for (i = 0, l = keys.length; i < l; i++) {
  12857. key = keys[i];
  12858. ret[i] = render(val[key], key, i);
  12859. }
  12860. }
  12861. if (isDef(ret)) {
  12862. (ret)._isVList = true;
  12863. }
  12864. return ret
  12865. }
  12866. /* */
  12867. /**
  12868. * Runtime helper for rendering <slot>
  12869. */
  12870. function renderSlot (
  12871. name,
  12872. fallback,
  12873. props,
  12874. bindObject
  12875. ) {
  12876. var scopedSlotFn = this.$scopedSlots[name];
  12877. if (scopedSlotFn) { // scoped slot
  12878. props = props || {};
  12879. if (bindObject) {
  12880. extend(props, bindObject);
  12881. }
  12882. return scopedSlotFn(props) || fallback
  12883. } else {
  12884. var slotNodes = this.$slots[name];
  12885. // warn duplicate slot usage
  12886. if (slotNodes && process.env.NODE_ENV !== 'production') {
  12887. slotNodes._rendered && warn(
  12888. "Duplicate presence of slot \"" + name + "\" found in the same render tree " +
  12889. "- this will likely cause render errors.",
  12890. this
  12891. );
  12892. slotNodes._rendered = true;
  12893. }
  12894. return slotNodes || fallback
  12895. }
  12896. }
  12897. /* */
  12898. /**
  12899. * Runtime helper for resolving filters
  12900. */
  12901. function resolveFilter (id) {
  12902. return resolveAsset(this.$options, 'filters', id, true) || identity
  12903. }
  12904. /* */
  12905. /**
  12906. * Runtime helper for checking keyCodes from config.
  12907. */
  12908. function checkKeyCodes (
  12909. eventKeyCode,
  12910. key,
  12911. builtInAlias
  12912. ) {
  12913. var keyCodes = config.keyCodes[key] || builtInAlias;
  12914. if (Array.isArray(keyCodes)) {
  12915. return keyCodes.indexOf(eventKeyCode) === -1
  12916. } else {
  12917. return keyCodes !== eventKeyCode
  12918. }
  12919. }
  12920. /* */
  12921. /**
  12922. * Runtime helper for merging v-bind="object" into a VNode's data.
  12923. */
  12924. function bindObjectProps (
  12925. data,
  12926. tag,
  12927. value,
  12928. asProp
  12929. ) {
  12930. if (value) {
  12931. if (!isObject(value)) {
  12932. process.env.NODE_ENV !== 'production' && warn(
  12933. 'v-bind without argument expects an Object or Array value',
  12934. this
  12935. );
  12936. } else {
  12937. if (Array.isArray(value)) {
  12938. value = toObject(value);
  12939. }
  12940. var hash;
  12941. for (var key in value) {
  12942. if (key === 'class' || key === 'style') {
  12943. hash = data;
  12944. } else {
  12945. var type = data.attrs && data.attrs.type;
  12946. hash = asProp || config.mustUseProp(tag, type, key)
  12947. ? data.domProps || (data.domProps = {})
  12948. : data.attrs || (data.attrs = {});
  12949. }
  12950. if (!(key in hash)) {
  12951. hash[key] = value[key];
  12952. }
  12953. }
  12954. }
  12955. }
  12956. return data
  12957. }
  12958. /* */
  12959. /**
  12960. * Runtime helper for rendering static trees.
  12961. */
  12962. function renderStatic (
  12963. index,
  12964. isInFor
  12965. ) {
  12966. var tree = this._staticTrees[index];
  12967. // if has already-rendered static tree and not inside v-for,
  12968. // we can reuse the same tree by doing a shallow clone.
  12969. if (tree && !isInFor) {
  12970. return Array.isArray(tree)
  12971. ? cloneVNodes(tree)
  12972. : cloneVNode(tree)
  12973. }
  12974. // otherwise, render a fresh tree.
  12975. tree = this._staticTrees[index] =
  12976. this.$options.staticRenderFns[index].call(this._renderProxy);
  12977. markStatic(tree, ("__static__" + index), false);
  12978. return tree
  12979. }
  12980. /**
  12981. * Runtime helper for v-once.
  12982. * Effectively it means marking the node as static with a unique key.
  12983. */
  12984. function markOnce (
  12985. tree,
  12986. index,
  12987. key
  12988. ) {
  12989. markStatic(tree, ("__once__" + index + (key ? ("_" + key) : "")), true);
  12990. return tree
  12991. }
  12992. function markStatic (
  12993. tree,
  12994. key,
  12995. isOnce
  12996. ) {
  12997. if (Array.isArray(tree)) {
  12998. for (var i = 0; i < tree.length; i++) {
  12999. if (tree[i] && typeof tree[i] !== 'string') {
  13000. markStaticNode(tree[i], (key + "_" + i), isOnce);
  13001. }
  13002. }
  13003. } else {
  13004. markStaticNode(tree, key, isOnce);
  13005. }
  13006. }
  13007. function markStaticNode (node, key, isOnce) {
  13008. node.isStatic = true;
  13009. node.key = key;
  13010. node.isOnce = isOnce;
  13011. }
  13012. /* */
  13013. function initRender (vm) {
  13014. vm._vnode = null; // the root of the child tree
  13015. vm._staticTrees = null;
  13016. var parentVnode = vm.$vnode = vm.$options._parentVnode; // the placeholder node in parent tree
  13017. var renderContext = parentVnode && parentVnode.context;
  13018. vm.$slots = resolveSlots(vm.$options._renderChildren, renderContext);
  13019. vm.$scopedSlots = emptyObject;
  13020. // bind the createElement fn to this instance
  13021. // so that we get proper render context inside it.
  13022. // args order: tag, data, children, normalizationType, alwaysNormalize
  13023. // internal version is used by render functions compiled from templates
  13024. vm._c = function (a, b, c, d) { return createElement(vm, a, b, c, d, false); };
  13025. // normalization is always applied for the public version, used in
  13026. // user-written render functions.
  13027. vm.$createElement = function (a, b, c, d) { return createElement(vm, a, b, c, d, true); };
  13028. }
  13029. function renderMixin (Vue) {
  13030. Vue.prototype.$nextTick = function (fn) {
  13031. return nextTick(fn, this)
  13032. };
  13033. Vue.prototype._render = function () {
  13034. var vm = this;
  13035. var ref = vm.$options;
  13036. var render = ref.render;
  13037. var staticRenderFns = ref.staticRenderFns;
  13038. var _parentVnode = ref._parentVnode;
  13039. if (vm._isMounted) {
  13040. // clone slot nodes on re-renders
  13041. for (var key in vm.$slots) {
  13042. vm.$slots[key] = cloneVNodes(vm.$slots[key]);
  13043. }
  13044. }
  13045. vm.$scopedSlots = (_parentVnode && _parentVnode.data.scopedSlots) || emptyObject;
  13046. if (staticRenderFns && !vm._staticTrees) {
  13047. vm._staticTrees = [];
  13048. }
  13049. // set parent vnode. this allows render functions to have access
  13050. // to the data on the placeholder node.
  13051. vm.$vnode = _parentVnode;
  13052. // render self
  13053. var vnode;
  13054. try {
  13055. vnode = render.call(vm._renderProxy, vm.$createElement);
  13056. } catch (e) {
  13057. handleError(e, vm, "render function");
  13058. // return error render result,
  13059. // or previous vnode to prevent render error causing blank component
  13060. /* istanbul ignore else */
  13061. if (process.env.NODE_ENV !== 'production') {
  13062. vnode = vm.$options.renderError
  13063. ? vm.$options.renderError.call(vm._renderProxy, vm.$createElement, e)
  13064. : vm._vnode;
  13065. } else {
  13066. vnode = vm._vnode;
  13067. }
  13068. }
  13069. // return empty vnode in case the render function errored out
  13070. if (!(vnode instanceof VNode)) {
  13071. if (process.env.NODE_ENV !== 'production' && Array.isArray(vnode)) {
  13072. warn(
  13073. 'Multiple root nodes returned from render function. Render function ' +
  13074. 'should return a single root node.',
  13075. vm
  13076. );
  13077. }
  13078. vnode = createEmptyVNode();
  13079. }
  13080. // set parent
  13081. vnode.parent = _parentVnode;
  13082. return vnode
  13083. };
  13084. // internal render helpers.
  13085. // these are exposed on the instance prototype to reduce generated render
  13086. // code size.
  13087. Vue.prototype._o = markOnce;
  13088. Vue.prototype._n = toNumber;
  13089. Vue.prototype._s = toString;
  13090. Vue.prototype._l = renderList;
  13091. Vue.prototype._t = renderSlot;
  13092. Vue.prototype._q = looseEqual;
  13093. Vue.prototype._i = looseIndexOf;
  13094. Vue.prototype._m = renderStatic;
  13095. Vue.prototype._f = resolveFilter;
  13096. Vue.prototype._k = checkKeyCodes;
  13097. Vue.prototype._b = bindObjectProps;
  13098. Vue.prototype._v = createTextVNode;
  13099. Vue.prototype._e = createEmptyVNode;
  13100. Vue.prototype._u = resolveScopedSlots;
  13101. }
  13102. /* */
  13103. var uid = 0;
  13104. function initMixin (Vue) {
  13105. Vue.prototype._init = function (options) {
  13106. var vm = this;
  13107. // a uid
  13108. vm._uid = uid++;
  13109. var startTag, endTag;
  13110. /* istanbul ignore if */
  13111. if (process.env.NODE_ENV !== 'production' && config.performance && mark) {
  13112. startTag = "vue-perf-init:" + (vm._uid);
  13113. endTag = "vue-perf-end:" + (vm._uid);
  13114. mark(startTag);
  13115. }
  13116. // a flag to avoid this being observed
  13117. vm._isVue = true;
  13118. // merge options
  13119. if (options && options._isComponent) {
  13120. // optimize internal component instantiation
  13121. // since dynamic options merging is pretty slow, and none of the
  13122. // internal component options needs special treatment.
  13123. initInternalComponent(vm, options);
  13124. } else {
  13125. vm.$options = mergeOptions(
  13126. resolveConstructorOptions(vm.constructor),
  13127. options || {},
  13128. vm
  13129. );
  13130. }
  13131. /* istanbul ignore else */
  13132. if (process.env.NODE_ENV !== 'production') {
  13133. initProxy(vm);
  13134. } else {
  13135. vm._renderProxy = vm;
  13136. }
  13137. // expose real self
  13138. vm._self = vm;
  13139. initLifecycle(vm);
  13140. initEvents(vm);
  13141. initRender(vm);
  13142. callHook(vm, 'beforeCreate');
  13143. initInjections(vm); // resolve injections before data/props
  13144. initState(vm);
  13145. initProvide(vm); // resolve provide after data/props
  13146. callHook(vm, 'created');
  13147. /* istanbul ignore if */
  13148. if (process.env.NODE_ENV !== 'production' && config.performance && mark) {
  13149. vm._name = formatComponentName(vm, false);
  13150. mark(endTag);
  13151. measure(((vm._name) + " init"), startTag, endTag);
  13152. }
  13153. if (vm.$options.el) {
  13154. vm.$mount(vm.$options.el);
  13155. }
  13156. };
  13157. }
  13158. function initInternalComponent (vm, options) {
  13159. var opts = vm.$options = Object.create(vm.constructor.options);
  13160. // doing this because it's faster than dynamic enumeration.
  13161. opts.parent = options.parent;
  13162. opts.propsData = options.propsData;
  13163. opts._parentVnode = options._parentVnode;
  13164. opts._parentListeners = options._parentListeners;
  13165. opts._renderChildren = options._renderChildren;
  13166. opts._componentTag = options._componentTag;
  13167. opts._parentElm = options._parentElm;
  13168. opts._refElm = options._refElm;
  13169. if (options.render) {
  13170. opts.render = options.render;
  13171. opts.staticRenderFns = options.staticRenderFns;
  13172. }
  13173. }
  13174. function resolveConstructorOptions (Ctor) {
  13175. var options = Ctor.options;
  13176. if (Ctor.super) {
  13177. var superOptions = resolveConstructorOptions(Ctor.super);
  13178. var cachedSuperOptions = Ctor.superOptions;
  13179. if (superOptions !== cachedSuperOptions) {
  13180. // super option changed,
  13181. // need to resolve new options.
  13182. Ctor.superOptions = superOptions;
  13183. // check if there are any late-modified/attached options (#4976)
  13184. var modifiedOptions = resolveModifiedOptions(Ctor);
  13185. // update base extend options
  13186. if (modifiedOptions) {
  13187. extend(Ctor.extendOptions, modifiedOptions);
  13188. }
  13189. options = Ctor.options = mergeOptions(superOptions, Ctor.extendOptions);
  13190. if (options.name) {
  13191. options.components[options.name] = Ctor;
  13192. }
  13193. }
  13194. }
  13195. return options
  13196. }
  13197. function resolveModifiedOptions (Ctor) {
  13198. var modified;
  13199. var latest = Ctor.options;
  13200. var extended = Ctor.extendOptions;
  13201. var sealed = Ctor.sealedOptions;
  13202. for (var key in latest) {
  13203. if (latest[key] !== sealed[key]) {
  13204. if (!modified) { modified = {}; }
  13205. modified[key] = dedupe(latest[key], extended[key], sealed[key]);
  13206. }
  13207. }
  13208. return modified
  13209. }
  13210. function dedupe (latest, extended, sealed) {
  13211. // compare latest and sealed to ensure lifecycle hooks won't be duplicated
  13212. // between merges
  13213. if (Array.isArray(latest)) {
  13214. var res = [];
  13215. sealed = Array.isArray(sealed) ? sealed : [sealed];
  13216. extended = Array.isArray(extended) ? extended : [extended];
  13217. for (var i = 0; i < latest.length; i++) {
  13218. // push original options and not sealed options to exclude duplicated options
  13219. if (extended.indexOf(latest[i]) >= 0 || sealed.indexOf(latest[i]) < 0) {
  13220. res.push(latest[i]);
  13221. }
  13222. }
  13223. return res
  13224. } else {
  13225. return latest
  13226. }
  13227. }
  13228. function Vue$3 (options) {
  13229. if (process.env.NODE_ENV !== 'production' &&
  13230. !(this instanceof Vue$3)
  13231. ) {
  13232. warn('Vue is a constructor and should be called with the `new` keyword');
  13233. }
  13234. this._init(options);
  13235. }
  13236. initMixin(Vue$3);
  13237. stateMixin(Vue$3);
  13238. eventsMixin(Vue$3);
  13239. lifecycleMixin(Vue$3);
  13240. renderMixin(Vue$3);
  13241. /* */
  13242. function initUse (Vue) {
  13243. Vue.use = function (plugin) {
  13244. /* istanbul ignore if */
  13245. if (plugin.installed) {
  13246. return this
  13247. }
  13248. // additional parameters
  13249. var args = toArray(arguments, 1);
  13250. args.unshift(this);
  13251. if (typeof plugin.install === 'function') {
  13252. plugin.install.apply(plugin, args);
  13253. } else if (typeof plugin === 'function') {
  13254. plugin.apply(null, args);
  13255. }
  13256. plugin.installed = true;
  13257. return this
  13258. };
  13259. }
  13260. /* */
  13261. function initMixin$1 (Vue) {
  13262. Vue.mixin = function (mixin) {
  13263. this.options = mergeOptions(this.options, mixin);
  13264. return this
  13265. };
  13266. }
  13267. /* */
  13268. function initExtend (Vue) {
  13269. /**
  13270. * Each instance constructor, including Vue, has a unique
  13271. * cid. This enables us to create wrapped "child
  13272. * constructors" for prototypal inheritance and cache them.
  13273. */
  13274. Vue.cid = 0;
  13275. var cid = 1;
  13276. /**
  13277. * Class inheritance
  13278. */
  13279. Vue.extend = function (extendOptions) {
  13280. extendOptions = extendOptions || {};
  13281. var Super = this;
  13282. var SuperId = Super.cid;
  13283. var cachedCtors = extendOptions._Ctor || (extendOptions._Ctor = {});
  13284. if (cachedCtors[SuperId]) {
  13285. return cachedCtors[SuperId]
  13286. }
  13287. var name = extendOptions.name || Super.options.name;
  13288. if (process.env.NODE_ENV !== 'production') {
  13289. if (!/^[a-zA-Z][\w-]*$/.test(name)) {
  13290. warn(
  13291. 'Invalid component name: "' + name + '". Component names ' +
  13292. 'can only contain alphanumeric characters and the hyphen, ' +
  13293. 'and must start with a letter.'
  13294. );
  13295. }
  13296. }
  13297. var Sub = function VueComponent (options) {
  13298. this._init(options);
  13299. };
  13300. Sub.prototype = Object.create(Super.prototype);
  13301. Sub.prototype.constructor = Sub;
  13302. Sub.cid = cid++;
  13303. Sub.options = mergeOptions(
  13304. Super.options,
  13305. extendOptions
  13306. );
  13307. Sub['super'] = Super;
  13308. // For props and computed properties, we define the proxy getters on
  13309. // the Vue instances at extension time, on the extended prototype. This
  13310. // avoids Object.defineProperty calls for each instance created.
  13311. if (Sub.options.props) {
  13312. initProps$1(Sub);
  13313. }
  13314. if (Sub.options.computed) {
  13315. initComputed$1(Sub);
  13316. }
  13317. // allow further extension/mixin/plugin usage
  13318. Sub.extend = Super.extend;
  13319. Sub.mixin = Super.mixin;
  13320. Sub.use = Super.use;
  13321. // create asset registers, so extended classes
  13322. // can have their private assets too.
  13323. ASSET_TYPES.forEach(function (type) {
  13324. Sub[type] = Super[type];
  13325. });
  13326. // enable recursive self-lookup
  13327. if (name) {
  13328. Sub.options.components[name] = Sub;
  13329. }
  13330. // keep a reference to the super options at extension time.
  13331. // later at instantiation we can check if Super's options have
  13332. // been updated.
  13333. Sub.superOptions = Super.options;
  13334. Sub.extendOptions = extendOptions;
  13335. Sub.sealedOptions = extend({}, Sub.options);
  13336. // cache constructor
  13337. cachedCtors[SuperId] = Sub;
  13338. return Sub
  13339. };
  13340. }
  13341. function initProps$1 (Comp) {
  13342. var props = Comp.options.props;
  13343. for (var key in props) {
  13344. proxy(Comp.prototype, "_props", key);
  13345. }
  13346. }
  13347. function initComputed$1 (Comp) {
  13348. var computed = Comp.options.computed;
  13349. for (var key in computed) {
  13350. defineComputed(Comp.prototype, key, computed[key]);
  13351. }
  13352. }
  13353. /* */
  13354. function initAssetRegisters (Vue) {
  13355. /**
  13356. * Create asset registration methods.
  13357. */
  13358. ASSET_TYPES.forEach(function (type) {
  13359. Vue[type] = function (
  13360. id,
  13361. definition
  13362. ) {
  13363. if (!definition) {
  13364. return this.options[type + 's'][id]
  13365. } else {
  13366. /* istanbul ignore if */
  13367. if (process.env.NODE_ENV !== 'production') {
  13368. if (type === 'component' && config.isReservedTag(id)) {
  13369. warn(
  13370. 'Do not use built-in or reserved HTML elements as component ' +
  13371. 'id: ' + id
  13372. );
  13373. }
  13374. }
  13375. if (type === 'component' && isPlainObject(definition)) {
  13376. definition.name = definition.name || id;
  13377. definition = this.options._base.extend(definition);
  13378. }
  13379. if (type === 'directive' && typeof definition === 'function') {
  13380. definition = { bind: definition, update: definition };
  13381. }
  13382. this.options[type + 's'][id] = definition;
  13383. return definition
  13384. }
  13385. };
  13386. });
  13387. }
  13388. /* */
  13389. var patternTypes = [String, RegExp];
  13390. function getComponentName (opts) {
  13391. return opts && (opts.Ctor.options.name || opts.tag)
  13392. }
  13393. function matches (pattern, name) {
  13394. if (typeof pattern === 'string') {
  13395. return pattern.split(',').indexOf(name) > -1
  13396. } else if (isRegExp(pattern)) {
  13397. return pattern.test(name)
  13398. }
  13399. /* istanbul ignore next */
  13400. return false
  13401. }
  13402. function pruneCache (cache, current, filter) {
  13403. for (var key in cache) {
  13404. var cachedNode = cache[key];
  13405. if (cachedNode) {
  13406. var name = getComponentName(cachedNode.componentOptions);
  13407. if (name && !filter(name)) {
  13408. if (cachedNode !== current) {
  13409. pruneCacheEntry(cachedNode);
  13410. }
  13411. cache[key] = null;
  13412. }
  13413. }
  13414. }
  13415. }
  13416. function pruneCacheEntry (vnode) {
  13417. if (vnode) {
  13418. vnode.componentInstance.$destroy();
  13419. }
  13420. }
  13421. var KeepAlive = {
  13422. name: 'keep-alive',
  13423. abstract: true,
  13424. props: {
  13425. include: patternTypes,
  13426. exclude: patternTypes
  13427. },
  13428. created: function created () {
  13429. this.cache = Object.create(null);
  13430. },
  13431. destroyed: function destroyed () {
  13432. var this$1 = this;
  13433. for (var key in this$1.cache) {
  13434. pruneCacheEntry(this$1.cache[key]);
  13435. }
  13436. },
  13437. watch: {
  13438. include: function include (val) {
  13439. pruneCache(this.cache, this._vnode, function (name) { return matches(val, name); });
  13440. },
  13441. exclude: function exclude (val) {
  13442. pruneCache(this.cache, this._vnode, function (name) { return !matches(val, name); });
  13443. }
  13444. },
  13445. render: function render () {
  13446. var vnode = getFirstComponentChild(this.$slots.default);
  13447. var componentOptions = vnode && vnode.componentOptions;
  13448. if (componentOptions) {
  13449. // check pattern
  13450. var name = getComponentName(componentOptions);
  13451. if (name && (
  13452. (this.include && !matches(this.include, name)) ||
  13453. (this.exclude && matches(this.exclude, name))
  13454. )) {
  13455. return vnode
  13456. }
  13457. var key = vnode.key == null
  13458. // same constructor may get registered as different local components
  13459. // so cid alone is not enough (#3269)
  13460. ? componentOptions.Ctor.cid + (componentOptions.tag ? ("::" + (componentOptions.tag)) : '')
  13461. : vnode.key;
  13462. if (this.cache[key]) {
  13463. vnode.componentInstance = this.cache[key].componentInstance;
  13464. } else {
  13465. this.cache[key] = vnode;
  13466. }
  13467. vnode.data.keepAlive = true;
  13468. }
  13469. return vnode
  13470. }
  13471. };
  13472. var builtInComponents = {
  13473. KeepAlive: KeepAlive
  13474. };
  13475. /* */
  13476. function initGlobalAPI (Vue) {
  13477. // config
  13478. var configDef = {};
  13479. configDef.get = function () { return config; };
  13480. if (process.env.NODE_ENV !== 'production') {
  13481. configDef.set = function () {
  13482. warn(
  13483. 'Do not replace the Vue.config object, set individual fields instead.'
  13484. );
  13485. };
  13486. }
  13487. Object.defineProperty(Vue, 'config', configDef);
  13488. // exposed util methods.
  13489. // NOTE: these are not considered part of the public API - avoid relying on
  13490. // them unless you are aware of the risk.
  13491. Vue.util = {
  13492. warn: warn,
  13493. extend: extend,
  13494. mergeOptions: mergeOptions,
  13495. defineReactive: defineReactive$$1
  13496. };
  13497. Vue.set = set;
  13498. Vue.delete = del;
  13499. Vue.nextTick = nextTick;
  13500. Vue.options = Object.create(null);
  13501. ASSET_TYPES.forEach(function (type) {
  13502. Vue.options[type + 's'] = Object.create(null);
  13503. });
  13504. // this is used to identify the "base" constructor to extend all plain-object
  13505. // components with in Weex's multi-instance scenarios.
  13506. Vue.options._base = Vue;
  13507. extend(Vue.options.components, builtInComponents);
  13508. initUse(Vue);
  13509. initMixin$1(Vue);
  13510. initExtend(Vue);
  13511. initAssetRegisters(Vue);
  13512. }
  13513. initGlobalAPI(Vue$3);
  13514. Object.defineProperty(Vue$3.prototype, '$isServer', {
  13515. get: isServerRendering
  13516. });
  13517. Object.defineProperty(Vue$3.prototype, '$ssrContext', {
  13518. get: function get () {
  13519. /* istanbul ignore next */
  13520. return this.$vnode.ssrContext
  13521. }
  13522. });
  13523. Vue$3.version = '2.3.3';
  13524. /* */
  13525. // these are reserved for web because they are directly compiled away
  13526. // during template compilation
  13527. var isReservedAttr = makeMap('style,class');
  13528. // attributes that should be using props for binding
  13529. var acceptValue = makeMap('input,textarea,option,select');
  13530. var mustUseProp = function (tag, type, attr) {
  13531. return (
  13532. (attr === 'value' && acceptValue(tag)) && type !== 'button' ||
  13533. (attr === 'selected' && tag === 'option') ||
  13534. (attr === 'checked' && tag === 'input') ||
  13535. (attr === 'muted' && tag === 'video')
  13536. )
  13537. };
  13538. var isEnumeratedAttr = makeMap('contenteditable,draggable,spellcheck');
  13539. var isBooleanAttr = makeMap(
  13540. 'allowfullscreen,async,autofocus,autoplay,checked,compact,controls,declare,' +
  13541. 'default,defaultchecked,defaultmuted,defaultselected,defer,disabled,' +
  13542. 'enabled,formnovalidate,hidden,indeterminate,inert,ismap,itemscope,loop,multiple,' +
  13543. 'muted,nohref,noresize,noshade,novalidate,nowrap,open,pauseonexit,readonly,' +
  13544. 'required,reversed,scoped,seamless,selected,sortable,translate,' +
  13545. 'truespeed,typemustmatch,visible'
  13546. );
  13547. var xlinkNS = 'http://www.w3.org/1999/xlink';
  13548. var isXlink = function (name) {
  13549. return name.charAt(5) === ':' && name.slice(0, 5) === 'xlink'
  13550. };
  13551. var getXlinkProp = function (name) {
  13552. return isXlink(name) ? name.slice(6, name.length) : ''
  13553. };
  13554. var isFalsyAttrValue = function (val) {
  13555. return val == null || val === false
  13556. };
  13557. /* */
  13558. function genClassForVnode (vnode) {
  13559. var data = vnode.data;
  13560. var parentNode = vnode;
  13561. var childNode = vnode;
  13562. while (isDef(childNode.componentInstance)) {
  13563. childNode = childNode.componentInstance._vnode;
  13564. if (childNode.data) {
  13565. data = mergeClassData(childNode.data, data);
  13566. }
  13567. }
  13568. while (isDef(parentNode = parentNode.parent)) {
  13569. if (parentNode.data) {
  13570. data = mergeClassData(data, parentNode.data);
  13571. }
  13572. }
  13573. return genClassFromData(data)
  13574. }
  13575. function mergeClassData (child, parent) {
  13576. return {
  13577. staticClass: concat(child.staticClass, parent.staticClass),
  13578. class: isDef(child.class)
  13579. ? [child.class, parent.class]
  13580. : parent.class
  13581. }
  13582. }
  13583. function genClassFromData (data) {
  13584. var dynamicClass = data.class;
  13585. var staticClass = data.staticClass;
  13586. if (isDef(staticClass) || isDef(dynamicClass)) {
  13587. return concat(staticClass, stringifyClass(dynamicClass))
  13588. }
  13589. /* istanbul ignore next */
  13590. return ''
  13591. }
  13592. function concat (a, b) {
  13593. return a ? b ? (a + ' ' + b) : a : (b || '')
  13594. }
  13595. function stringifyClass (value) {
  13596. if (isUndef(value)) {
  13597. return ''
  13598. }
  13599. if (typeof value === 'string') {
  13600. return value
  13601. }
  13602. var res = '';
  13603. if (Array.isArray(value)) {
  13604. var stringified;
  13605. for (var i = 0, l = value.length; i < l; i++) {
  13606. if (isDef(value[i])) {
  13607. if (isDef(stringified = stringifyClass(value[i])) && stringified !== '') {
  13608. res += stringified + ' ';
  13609. }
  13610. }
  13611. }
  13612. return res.slice(0, -1)
  13613. }
  13614. if (isObject(value)) {
  13615. for (var key in value) {
  13616. if (value[key]) { res += key + ' '; }
  13617. }
  13618. return res.slice(0, -1)
  13619. }
  13620. /* istanbul ignore next */
  13621. return res
  13622. }
  13623. /* */
  13624. var namespaceMap = {
  13625. svg: 'http://www.w3.org/2000/svg',
  13626. math: 'http://www.w3.org/1998/Math/MathML'
  13627. };
  13628. var isHTMLTag = makeMap(
  13629. 'html,body,base,head,link,meta,style,title,' +
  13630. 'address,article,aside,footer,header,h1,h2,h3,h4,h5,h6,hgroup,nav,section,' +
  13631. 'div,dd,dl,dt,figcaption,figure,hr,img,li,main,ol,p,pre,ul,' +
  13632. 'a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,rtc,ruby,' +
  13633. 's,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,' +
  13634. 'embed,object,param,source,canvas,script,noscript,del,ins,' +
  13635. 'caption,col,colgroup,table,thead,tbody,td,th,tr,' +
  13636. 'button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,' +
  13637. 'output,progress,select,textarea,' +
  13638. 'details,dialog,menu,menuitem,summary,' +
  13639. 'content,element,shadow,template'
  13640. );
  13641. // this map is intentionally selective, only covering SVG elements that may
  13642. // contain child elements.
  13643. var isSVG = makeMap(
  13644. 'svg,animate,circle,clippath,cursor,defs,desc,ellipse,filter,font-face,' +
  13645. 'foreignObject,g,glyph,image,line,marker,mask,missing-glyph,path,pattern,' +
  13646. 'polygon,polyline,rect,switch,symbol,text,textpath,tspan,use,view',
  13647. true
  13648. );
  13649. var isReservedTag = function (tag) {
  13650. return isHTMLTag(tag) || isSVG(tag)
  13651. };
  13652. function getTagNamespace (tag) {
  13653. if (isSVG(tag)) {
  13654. return 'svg'
  13655. }
  13656. // basic support for MathML
  13657. // note it doesn't support other MathML elements being component roots
  13658. if (tag === 'math') {
  13659. return 'math'
  13660. }
  13661. }
  13662. var unknownElementCache = Object.create(null);
  13663. function isUnknownElement (tag) {
  13664. /* istanbul ignore if */
  13665. if (!inBrowser) {
  13666. return true
  13667. }
  13668. if (isReservedTag(tag)) {
  13669. return false
  13670. }
  13671. tag = tag.toLowerCase();
  13672. /* istanbul ignore if */
  13673. if (unknownElementCache[tag] != null) {
  13674. return unknownElementCache[tag]
  13675. }
  13676. var el = document.createElement(tag);
  13677. if (tag.indexOf('-') > -1) {
  13678. // http://stackoverflow.com/a/28210364/1070244
  13679. return (unknownElementCache[tag] = (
  13680. el.constructor === window.HTMLUnknownElement ||
  13681. el.constructor === window.HTMLElement
  13682. ))
  13683. } else {
  13684. return (unknownElementCache[tag] = /HTMLUnknownElement/.test(el.toString()))
  13685. }
  13686. }
  13687. /* */
  13688. /**
  13689. * Query an element selector if it's not an element already.
  13690. */
  13691. function query (el) {
  13692. if (typeof el === 'string') {
  13693. var selected = document.querySelector(el);
  13694. if (!selected) {
  13695. process.env.NODE_ENV !== 'production' && warn(
  13696. 'Cannot find element: ' + el
  13697. );
  13698. return document.createElement('div')
  13699. }
  13700. return selected
  13701. } else {
  13702. return el
  13703. }
  13704. }
  13705. /* */
  13706. function createElement$1 (tagName, vnode) {
  13707. var elm = document.createElement(tagName);
  13708. if (tagName !== 'select') {
  13709. return elm
  13710. }
  13711. // false or null will remove the attribute but undefined will not
  13712. if (vnode.data && vnode.data.attrs && vnode.data.attrs.multiple !== undefined) {
  13713. elm.setAttribute('multiple', 'multiple');
  13714. }
  13715. return elm
  13716. }
  13717. function createElementNS (namespace, tagName) {
  13718. return document.createElementNS(namespaceMap[namespace], tagName)
  13719. }
  13720. function createTextNode (text) {
  13721. return document.createTextNode(text)
  13722. }
  13723. function createComment (text) {
  13724. return document.createComment(text)
  13725. }
  13726. function insertBefore (parentNode, newNode, referenceNode) {
  13727. parentNode.insertBefore(newNode, referenceNode);
  13728. }
  13729. function removeChild (node, child) {
  13730. node.removeChild(child);
  13731. }
  13732. function appendChild (node, child) {
  13733. node.appendChild(child);
  13734. }
  13735. function parentNode (node) {
  13736. return node.parentNode
  13737. }
  13738. function nextSibling (node) {
  13739. return node.nextSibling
  13740. }
  13741. function tagName (node) {
  13742. return node.tagName
  13743. }
  13744. function setTextContent (node, text) {
  13745. node.textContent = text;
  13746. }
  13747. function setAttribute (node, key, val) {
  13748. node.setAttribute(key, val);
  13749. }
  13750. var nodeOps = Object.freeze({
  13751. createElement: createElement$1,
  13752. createElementNS: createElementNS,
  13753. createTextNode: createTextNode,
  13754. createComment: createComment,
  13755. insertBefore: insertBefore,
  13756. removeChild: removeChild,
  13757. appendChild: appendChild,
  13758. parentNode: parentNode,
  13759. nextSibling: nextSibling,
  13760. tagName: tagName,
  13761. setTextContent: setTextContent,
  13762. setAttribute: setAttribute
  13763. });
  13764. /* */
  13765. var ref = {
  13766. create: function create (_, vnode) {
  13767. registerRef(vnode);
  13768. },
  13769. update: function update (oldVnode, vnode) {
  13770. if (oldVnode.data.ref !== vnode.data.ref) {
  13771. registerRef(oldVnode, true);
  13772. registerRef(vnode);
  13773. }
  13774. },
  13775. destroy: function destroy (vnode) {
  13776. registerRef(vnode, true);
  13777. }
  13778. };
  13779. function registerRef (vnode, isRemoval) {
  13780. var key = vnode.data.ref;
  13781. if (!key) { return }
  13782. var vm = vnode.context;
  13783. var ref = vnode.componentInstance || vnode.elm;
  13784. var refs = vm.$refs;
  13785. if (isRemoval) {
  13786. if (Array.isArray(refs[key])) {
  13787. remove(refs[key], ref);
  13788. } else if (refs[key] === ref) {
  13789. refs[key] = undefined;
  13790. }
  13791. } else {
  13792. if (vnode.data.refInFor) {
  13793. if (Array.isArray(refs[key]) && refs[key].indexOf(ref) < 0) {
  13794. refs[key].push(ref);
  13795. } else {
  13796. refs[key] = [ref];
  13797. }
  13798. } else {
  13799. refs[key] = ref;
  13800. }
  13801. }
  13802. }
  13803. /**
  13804. * Virtual DOM patching algorithm based on Snabbdom by
  13805. * Simon Friis Vindum (@paldepind)
  13806. * Licensed under the MIT License
  13807. * https://github.com/paldepind/snabbdom/blob/master/LICENSE
  13808. *
  13809. * modified by Evan You (@yyx990803)
  13810. *
  13811. /*
  13812. * Not type-checking this because this file is perf-critical and the cost
  13813. * of making flow understand it is not worth it.
  13814. */
  13815. var emptyNode = new VNode('', {}, []);
  13816. var hooks = ['create', 'activate', 'update', 'remove', 'destroy'];
  13817. function sameVnode (a, b) {
  13818. return (
  13819. a.key === b.key &&
  13820. a.tag === b.tag &&
  13821. a.isComment === b.isComment &&
  13822. isDef(a.data) === isDef(b.data) &&
  13823. sameInputType(a, b)
  13824. )
  13825. }
  13826. // Some browsers do not support dynamically changing type for <input>
  13827. // so they need to be treated as different nodes
  13828. function sameInputType (a, b) {
  13829. if (a.tag !== 'input') { return true }
  13830. var i;
  13831. var typeA = isDef(i = a.data) && isDef(i = i.attrs) && i.type;
  13832. var typeB = isDef(i = b.data) && isDef(i = i.attrs) && i.type;
  13833. return typeA === typeB
  13834. }
  13835. function createKeyToOldIdx (children, beginIdx, endIdx) {
  13836. var i, key;
  13837. var map = {};
  13838. for (i = beginIdx; i <= endIdx; ++i) {
  13839. key = children[i].key;
  13840. if (isDef(key)) { map[key] = i; }
  13841. }
  13842. return map
  13843. }
  13844. function createPatchFunction (backend) {
  13845. var i, j;
  13846. var cbs = {};
  13847. var modules = backend.modules;
  13848. var nodeOps = backend.nodeOps;
  13849. for (i = 0; i < hooks.length; ++i) {
  13850. cbs[hooks[i]] = [];
  13851. for (j = 0; j < modules.length; ++j) {
  13852. if (isDef(modules[j][hooks[i]])) {
  13853. cbs[hooks[i]].push(modules[j][hooks[i]]);
  13854. }
  13855. }
  13856. }
  13857. function emptyNodeAt (elm) {
  13858. return new VNode(nodeOps.tagName(elm).toLowerCase(), {}, [], undefined, elm)
  13859. }
  13860. function createRmCb (childElm, listeners) {
  13861. function remove$$1 () {
  13862. if (--remove$$1.listeners === 0) {
  13863. removeNode(childElm);
  13864. }
  13865. }
  13866. remove$$1.listeners = listeners;
  13867. return remove$$1
  13868. }
  13869. function removeNode (el) {
  13870. var parent = nodeOps.parentNode(el);
  13871. // element may have already been removed due to v-html / v-text
  13872. if (isDef(parent)) {
  13873. nodeOps.removeChild(parent, el);
  13874. }
  13875. }
  13876. var inPre = 0;
  13877. function createElm (vnode, insertedVnodeQueue, parentElm, refElm, nested) {
  13878. vnode.isRootInsert = !nested; // for transition enter check
  13879. if (createComponent(vnode, insertedVnodeQueue, parentElm, refElm)) {
  13880. return
  13881. }
  13882. var data = vnode.data;
  13883. var children = vnode.children;
  13884. var tag = vnode.tag;
  13885. if (isDef(tag)) {
  13886. if (process.env.NODE_ENV !== 'production') {
  13887. if (data && data.pre) {
  13888. inPre++;
  13889. }
  13890. if (
  13891. !inPre &&
  13892. !vnode.ns &&
  13893. !(config.ignoredElements.length && config.ignoredElements.indexOf(tag) > -1) &&
  13894. config.isUnknownElement(tag)
  13895. ) {
  13896. warn(
  13897. 'Unknown custom element: <' + tag + '> - did you ' +
  13898. 'register the component correctly? For recursive components, ' +
  13899. 'make sure to provide the "name" option.',
  13900. vnode.context
  13901. );
  13902. }
  13903. }
  13904. vnode.elm = vnode.ns
  13905. ? nodeOps.createElementNS(vnode.ns, tag)
  13906. : nodeOps.createElement(tag, vnode);
  13907. setScope(vnode);
  13908. /* istanbul ignore if */
  13909. {
  13910. createChildren(vnode, children, insertedVnodeQueue);
  13911. if (isDef(data)) {
  13912. invokeCreateHooks(vnode, insertedVnodeQueue);
  13913. }
  13914. insert(parentElm, vnode.elm, refElm);
  13915. }
  13916. if (process.env.NODE_ENV !== 'production' && data && data.pre) {
  13917. inPre--;
  13918. }
  13919. } else if (isTrue(vnode.isComment)) {
  13920. vnode.elm = nodeOps.createComment(vnode.text);
  13921. insert(parentElm, vnode.elm, refElm);
  13922. } else {
  13923. vnode.elm = nodeOps.createTextNode(vnode.text);
  13924. insert(parentElm, vnode.elm, refElm);
  13925. }
  13926. }
  13927. function createComponent (vnode, insertedVnodeQueue, parentElm, refElm) {
  13928. var i = vnode.data;
  13929. if (isDef(i)) {
  13930. var isReactivated = isDef(vnode.componentInstance) && i.keepAlive;
  13931. if (isDef(i = i.hook) && isDef(i = i.init)) {
  13932. i(vnode, false /* hydrating */, parentElm, refElm);
  13933. }
  13934. // after calling the init hook, if the vnode is a child component
  13935. // it should've created a child instance and mounted it. the child
  13936. // component also has set the placeholder vnode's elm.
  13937. // in that case we can just return the element and be done.
  13938. if (isDef(vnode.componentInstance)) {
  13939. initComponent(vnode, insertedVnodeQueue);
  13940. if (isTrue(isReactivated)) {
  13941. reactivateComponent(vnode, insertedVnodeQueue, parentElm, refElm);
  13942. }
  13943. return true
  13944. }
  13945. }
  13946. }
  13947. function initComponent (vnode, insertedVnodeQueue) {
  13948. if (isDef(vnode.data.pendingInsert)) {
  13949. insertedVnodeQueue.push.apply(insertedVnodeQueue, vnode.data.pendingInsert);
  13950. }
  13951. vnode.elm = vnode.componentInstance.$el;
  13952. if (isPatchable(vnode)) {
  13953. invokeCreateHooks(vnode, insertedVnodeQueue);
  13954. setScope(vnode);
  13955. } else {
  13956. // empty component root.
  13957. // skip all element-related modules except for ref (#3455)
  13958. registerRef(vnode);
  13959. // make sure to invoke the insert hook
  13960. insertedVnodeQueue.push(vnode);
  13961. }
  13962. }
  13963. function reactivateComponent (vnode, insertedVnodeQueue, parentElm, refElm) {
  13964. var i;
  13965. // hack for #4339: a reactivated component with inner transition
  13966. // does not trigger because the inner node's created hooks are not called
  13967. // again. It's not ideal to involve module-specific logic in here but
  13968. // there doesn't seem to be a better way to do it.
  13969. var innerNode = vnode;
  13970. while (innerNode.componentInstance) {
  13971. innerNode = innerNode.componentInstance._vnode;
  13972. if (isDef(i = innerNode.data) && isDef(i = i.transition)) {
  13973. for (i = 0; i < cbs.activate.length; ++i) {
  13974. cbs.activate[i](emptyNode, innerNode);
  13975. }
  13976. insertedVnodeQueue.push(innerNode);
  13977. break
  13978. }
  13979. }
  13980. // unlike a newly created component,
  13981. // a reactivated keep-alive component doesn't insert itself
  13982. insert(parentElm, vnode.elm, refElm);
  13983. }
  13984. function insert (parent, elm, ref) {
  13985. if (isDef(parent)) {
  13986. if (isDef(ref)) {
  13987. if (ref.parentNode === parent) {
  13988. nodeOps.insertBefore(parent, elm, ref);
  13989. }
  13990. } else {
  13991. nodeOps.appendChild(parent, elm);
  13992. }
  13993. }
  13994. }
  13995. function createChildren (vnode, children, insertedVnodeQueue) {
  13996. if (Array.isArray(children)) {
  13997. for (var i = 0; i < children.length; ++i) {
  13998. createElm(children[i], insertedVnodeQueue, vnode.elm, null, true);
  13999. }
  14000. } else if (isPrimitive(vnode.text)) {
  14001. nodeOps.appendChild(vnode.elm, nodeOps.createTextNode(vnode.text));
  14002. }
  14003. }
  14004. function isPatchable (vnode) {
  14005. while (vnode.componentInstance) {
  14006. vnode = vnode.componentInstance._vnode;
  14007. }
  14008. return isDef(vnode.tag)
  14009. }
  14010. function invokeCreateHooks (vnode, insertedVnodeQueue) {
  14011. for (var i$1 = 0; i$1 < cbs.create.length; ++i$1) {
  14012. cbs.create[i$1](emptyNode, vnode);
  14013. }
  14014. i = vnode.data.hook; // Reuse variable
  14015. if (isDef(i)) {
  14016. if (isDef(i.create)) { i.create(emptyNode, vnode); }
  14017. if (isDef(i.insert)) { insertedVnodeQueue.push(vnode); }
  14018. }
  14019. }
  14020. // set scope id attribute for scoped CSS.
  14021. // this is implemented as a special case to avoid the overhead
  14022. // of going through the normal attribute patching process.
  14023. function setScope (vnode) {
  14024. var i;
  14025. var ancestor = vnode;
  14026. while (ancestor) {
  14027. if (isDef(i = ancestor.context) && isDef(i = i.$options._scopeId)) {
  14028. nodeOps.setAttribute(vnode.elm, i, '');
  14029. }
  14030. ancestor = ancestor.parent;
  14031. }
  14032. // for slot content they should also get the scopeId from the host instance.
  14033. if (isDef(i = activeInstance) &&
  14034. i !== vnode.context &&
  14035. isDef(i = i.$options._scopeId)
  14036. ) {
  14037. nodeOps.setAttribute(vnode.elm, i, '');
  14038. }
  14039. }
  14040. function addVnodes (parentElm, refElm, vnodes, startIdx, endIdx, insertedVnodeQueue) {
  14041. for (; startIdx <= endIdx; ++startIdx) {
  14042. createElm(vnodes[startIdx], insertedVnodeQueue, parentElm, refElm);
  14043. }
  14044. }
  14045. function invokeDestroyHook (vnode) {
  14046. var i, j;
  14047. var data = vnode.data;
  14048. if (isDef(data)) {
  14049. if (isDef(i = data.hook) && isDef(i = i.destroy)) { i(vnode); }
  14050. for (i = 0; i < cbs.destroy.length; ++i) { cbs.destroy[i](vnode); }
  14051. }
  14052. if (isDef(i = vnode.children)) {
  14053. for (j = 0; j < vnode.children.length; ++j) {
  14054. invokeDestroyHook(vnode.children[j]);
  14055. }
  14056. }
  14057. }
  14058. function removeVnodes (parentElm, vnodes, startIdx, endIdx) {
  14059. for (; startIdx <= endIdx; ++startIdx) {
  14060. var ch = vnodes[startIdx];
  14061. if (isDef(ch)) {
  14062. if (isDef(ch.tag)) {
  14063. removeAndInvokeRemoveHook(ch);
  14064. invokeDestroyHook(ch);
  14065. } else { // Text node
  14066. removeNode(ch.elm);
  14067. }
  14068. }
  14069. }
  14070. }
  14071. function removeAndInvokeRemoveHook (vnode, rm) {
  14072. if (isDef(rm) || isDef(vnode.data)) {
  14073. var i;
  14074. var listeners = cbs.remove.length + 1;
  14075. if (isDef(rm)) {
  14076. // we have a recursively passed down rm callback
  14077. // increase the listeners count
  14078. rm.listeners += listeners;
  14079. } else {
  14080. // directly removing
  14081. rm = createRmCb(vnode.elm, listeners);
  14082. }
  14083. // recursively invoke hooks on child component root node
  14084. if (isDef(i = vnode.componentInstance) && isDef(i = i._vnode) && isDef(i.data)) {
  14085. removeAndInvokeRemoveHook(i, rm);
  14086. }
  14087. for (i = 0; i < cbs.remove.length; ++i) {
  14088. cbs.remove[i](vnode, rm);
  14089. }
  14090. if (isDef(i = vnode.data.hook) && isDef(i = i.remove)) {
  14091. i(vnode, rm);
  14092. } else {
  14093. rm();
  14094. }
  14095. } else {
  14096. removeNode(vnode.elm);
  14097. }
  14098. }
  14099. function updateChildren (parentElm, oldCh, newCh, insertedVnodeQueue, removeOnly) {
  14100. var oldStartIdx = 0;
  14101. var newStartIdx = 0;
  14102. var oldEndIdx = oldCh.length - 1;
  14103. var oldStartVnode = oldCh[0];
  14104. var oldEndVnode = oldCh[oldEndIdx];
  14105. var newEndIdx = newCh.length - 1;
  14106. var newStartVnode = newCh[0];
  14107. var newEndVnode = newCh[newEndIdx];
  14108. var oldKeyToIdx, idxInOld, elmToMove, refElm;
  14109. // removeOnly is a special flag used only by <transition-group>
  14110. // to ensure removed elements stay in correct relative positions
  14111. // during leaving transitions
  14112. var canMove = !removeOnly;
  14113. while (oldStartIdx <= oldEndIdx && newStartIdx <= newEndIdx) {
  14114. if (isUndef(oldStartVnode)) {
  14115. oldStartVnode = oldCh[++oldStartIdx]; // Vnode has been moved left
  14116. } else if (isUndef(oldEndVnode)) {
  14117. oldEndVnode = oldCh[--oldEndIdx];
  14118. } else if (sameVnode(oldStartVnode, newStartVnode)) {
  14119. patchVnode(oldStartVnode, newStartVnode, insertedVnodeQueue);
  14120. oldStartVnode = oldCh[++oldStartIdx];
  14121. newStartVnode = newCh[++newStartIdx];
  14122. } else if (sameVnode(oldEndVnode, newEndVnode)) {
  14123. patchVnode(oldEndVnode, newEndVnode, insertedVnodeQueue);
  14124. oldEndVnode = oldCh[--oldEndIdx];
  14125. newEndVnode = newCh[--newEndIdx];
  14126. } else if (sameVnode(oldStartVnode, newEndVnode)) { // Vnode moved right
  14127. patchVnode(oldStartVnode, newEndVnode, insertedVnodeQueue);
  14128. canMove && nodeOps.insertBefore(parentElm, oldStartVnode.elm, nodeOps.nextSibling(oldEndVnode.elm));
  14129. oldStartVnode = oldCh[++oldStartIdx];
  14130. newEndVnode = newCh[--newEndIdx];
  14131. } else if (sameVnode(oldEndVnode, newStartVnode)) { // Vnode moved left
  14132. patchVnode(oldEndVnode, newStartVnode, insertedVnodeQueue);
  14133. canMove && nodeOps.insertBefore(parentElm, oldEndVnode.elm, oldStartVnode.elm);
  14134. oldEndVnode = oldCh[--oldEndIdx];
  14135. newStartVnode = newCh[++newStartIdx];
  14136. } else {
  14137. if (isUndef(oldKeyToIdx)) { oldKeyToIdx = createKeyToOldIdx(oldCh, oldStartIdx, oldEndIdx); }
  14138. idxInOld = isDef(newStartVnode.key) ? oldKeyToIdx[newStartVnode.key] : null;
  14139. if (isUndef(idxInOld)) { // New element
  14140. createElm(newStartVnode, insertedVnodeQueue, parentElm, oldStartVnode.elm);
  14141. newStartVnode = newCh[++newStartIdx];
  14142. } else {
  14143. elmToMove = oldCh[idxInOld];
  14144. /* istanbul ignore if */
  14145. if (process.env.NODE_ENV !== 'production' && !elmToMove) {
  14146. warn(
  14147. 'It seems there are duplicate keys that is causing an update error. ' +
  14148. 'Make sure each v-for item has a unique key.'
  14149. );
  14150. }
  14151. if (sameVnode(elmToMove, newStartVnode)) {
  14152. patchVnode(elmToMove, newStartVnode, insertedVnodeQueue);
  14153. oldCh[idxInOld] = undefined;
  14154. canMove && nodeOps.insertBefore(parentElm, newStartVnode.elm, oldStartVnode.elm);
  14155. newStartVnode = newCh[++newStartIdx];
  14156. } else {
  14157. // same key but different element. treat as new element
  14158. createElm(newStartVnode, insertedVnodeQueue, parentElm, oldStartVnode.elm);
  14159. newStartVnode = newCh[++newStartIdx];
  14160. }
  14161. }
  14162. }
  14163. }
  14164. if (oldStartIdx > oldEndIdx) {
  14165. refElm = isUndef(newCh[newEndIdx + 1]) ? null : newCh[newEndIdx + 1].elm;
  14166. addVnodes(parentElm, refElm, newCh, newStartIdx, newEndIdx, insertedVnodeQueue);
  14167. } else if (newStartIdx > newEndIdx) {
  14168. removeVnodes(parentElm, oldCh, oldStartIdx, oldEndIdx);
  14169. }
  14170. }
  14171. function patchVnode (oldVnode, vnode, insertedVnodeQueue, removeOnly) {
  14172. if (oldVnode === vnode) {
  14173. return
  14174. }
  14175. // reuse element for static trees.
  14176. // note we only do this if the vnode is cloned -
  14177. // if the new node is not cloned it means the render functions have been
  14178. // reset by the hot-reload-api and we need to do a proper re-render.
  14179. if (isTrue(vnode.isStatic) &&
  14180. isTrue(oldVnode.isStatic) &&
  14181. vnode.key === oldVnode.key &&
  14182. (isTrue(vnode.isCloned) || isTrue(vnode.isOnce))
  14183. ) {
  14184. vnode.elm = oldVnode.elm;
  14185. vnode.componentInstance = oldVnode.componentInstance;
  14186. return
  14187. }
  14188. var i;
  14189. var data = vnode.data;
  14190. if (isDef(data) && isDef(i = data.hook) && isDef(i = i.prepatch)) {
  14191. i(oldVnode, vnode);
  14192. }
  14193. var elm = vnode.elm = oldVnode.elm;
  14194. var oldCh = oldVnode.children;
  14195. var ch = vnode.children;
  14196. if (isDef(data) && isPatchable(vnode)) {
  14197. for (i = 0; i < cbs.update.length; ++i) { cbs.update[i](oldVnode, vnode); }
  14198. if (isDef(i = data.hook) && isDef(i = i.update)) { i(oldVnode, vnode); }
  14199. }
  14200. if (isUndef(vnode.text)) {
  14201. if (isDef(oldCh) && isDef(ch)) {
  14202. if (oldCh !== ch) { updateChildren(elm, oldCh, ch, insertedVnodeQueue, removeOnly); }
  14203. } else if (isDef(ch)) {
  14204. if (isDef(oldVnode.text)) { nodeOps.setTextContent(elm, ''); }
  14205. addVnodes(elm, null, ch, 0, ch.length - 1, insertedVnodeQueue);
  14206. } else if (isDef(oldCh)) {
  14207. removeVnodes(elm, oldCh, 0, oldCh.length - 1);
  14208. } else if (isDef(oldVnode.text)) {
  14209. nodeOps.setTextContent(elm, '');
  14210. }
  14211. } else if (oldVnode.text !== vnode.text) {
  14212. nodeOps.setTextContent(elm, vnode.text);
  14213. }
  14214. if (isDef(data)) {
  14215. if (isDef(i = data.hook) && isDef(i = i.postpatch)) { i(oldVnode, vnode); }
  14216. }
  14217. }
  14218. function invokeInsertHook (vnode, queue, initial) {
  14219. // delay insert hooks for component root nodes, invoke them after the
  14220. // element is really inserted
  14221. if (isTrue(initial) && isDef(vnode.parent)) {
  14222. vnode.parent.data.pendingInsert = queue;
  14223. } else {
  14224. for (var i = 0; i < queue.length; ++i) {
  14225. queue[i].data.hook.insert(queue[i]);
  14226. }
  14227. }
  14228. }
  14229. var bailed = false;
  14230. // list of modules that can skip create hook during hydration because they
  14231. // are already rendered on the client or has no need for initialization
  14232. var isRenderedModule = makeMap('attrs,style,class,staticClass,staticStyle,key');
  14233. // Note: this is a browser-only function so we can assume elms are DOM nodes.
  14234. function hydrate (elm, vnode, insertedVnodeQueue) {
  14235. if (process.env.NODE_ENV !== 'production') {
  14236. if (!assertNodeMatch(elm, vnode)) {
  14237. return false
  14238. }
  14239. }
  14240. vnode.elm = elm;
  14241. var tag = vnode.tag;
  14242. var data = vnode.data;
  14243. var children = vnode.children;
  14244. if (isDef(data)) {
  14245. if (isDef(i = data.hook) && isDef(i = i.init)) { i(vnode, true /* hydrating */); }
  14246. if (isDef(i = vnode.componentInstance)) {
  14247. // child component. it should have hydrated its own tree.
  14248. initComponent(vnode, insertedVnodeQueue);
  14249. return true
  14250. }
  14251. }
  14252. if (isDef(tag)) {
  14253. if (isDef(children)) {
  14254. // empty element, allow client to pick up and populate children
  14255. if (!elm.hasChildNodes()) {
  14256. createChildren(vnode, children, insertedVnodeQueue);
  14257. } else {
  14258. var childrenMatch = true;
  14259. var childNode = elm.firstChild;
  14260. for (var i$1 = 0; i$1 < children.length; i$1++) {
  14261. if (!childNode || !hydrate(childNode, children[i$1], insertedVnodeQueue)) {
  14262. childrenMatch = false;
  14263. break
  14264. }
  14265. childNode = childNode.nextSibling;
  14266. }
  14267. // if childNode is not null, it means the actual childNodes list is
  14268. // longer than the virtual children list.
  14269. if (!childrenMatch || childNode) {
  14270. if (process.env.NODE_ENV !== 'production' &&
  14271. typeof console !== 'undefined' &&
  14272. !bailed
  14273. ) {
  14274. bailed = true;
  14275. console.warn('Parent: ', elm);
  14276. console.warn('Mismatching childNodes vs. VNodes: ', elm.childNodes, children);
  14277. }
  14278. return false
  14279. }
  14280. }
  14281. }
  14282. if (isDef(data)) {
  14283. for (var key in data) {
  14284. if (!isRenderedModule(key)) {
  14285. invokeCreateHooks(vnode, insertedVnodeQueue);
  14286. break
  14287. }
  14288. }
  14289. }
  14290. } else if (elm.data !== vnode.text) {
  14291. elm.data = vnode.text;
  14292. }
  14293. return true
  14294. }
  14295. function assertNodeMatch (node, vnode) {
  14296. if (isDef(vnode.tag)) {
  14297. return (
  14298. vnode.tag.indexOf('vue-component') === 0 ||
  14299. vnode.tag.toLowerCase() === (node.tagName && node.tagName.toLowerCase())
  14300. )
  14301. } else {
  14302. return node.nodeType === (vnode.isComment ? 8 : 3)
  14303. }
  14304. }
  14305. return function patch (oldVnode, vnode, hydrating, removeOnly, parentElm, refElm) {
  14306. if (isUndef(vnode)) {
  14307. if (isDef(oldVnode)) { invokeDestroyHook(oldVnode); }
  14308. return
  14309. }
  14310. var isInitialPatch = false;
  14311. var insertedVnodeQueue = [];
  14312. if (isUndef(oldVnode)) {
  14313. // empty mount (likely as component), create new root element
  14314. isInitialPatch = true;
  14315. createElm(vnode, insertedVnodeQueue, parentElm, refElm);
  14316. } else {
  14317. var isRealElement = isDef(oldVnode.nodeType);
  14318. if (!isRealElement && sameVnode(oldVnode, vnode)) {
  14319. // patch existing root node
  14320. patchVnode(oldVnode, vnode, insertedVnodeQueue, removeOnly);
  14321. } else {
  14322. if (isRealElement) {
  14323. // mounting to a real element
  14324. // check if this is server-rendered content and if we can perform
  14325. // a successful hydration.
  14326. if (oldVnode.nodeType === 1 && oldVnode.hasAttribute(SSR_ATTR)) {
  14327. oldVnode.removeAttribute(SSR_ATTR);
  14328. hydrating = true;
  14329. }
  14330. if (isTrue(hydrating)) {
  14331. if (hydrate(oldVnode, vnode, insertedVnodeQueue)) {
  14332. invokeInsertHook(vnode, insertedVnodeQueue, true);
  14333. return oldVnode
  14334. } else if (process.env.NODE_ENV !== 'production') {
  14335. warn(
  14336. 'The client-side rendered virtual DOM tree is not matching ' +
  14337. 'server-rendered content. This is likely caused by incorrect ' +
  14338. 'HTML markup, for example nesting block-level elements inside ' +
  14339. '<p>, or missing <tbody>. Bailing hydration and performing ' +
  14340. 'full client-side render.'
  14341. );
  14342. }
  14343. }
  14344. // either not server-rendered, or hydration failed.
  14345. // create an empty node and replace it
  14346. oldVnode = emptyNodeAt(oldVnode);
  14347. }
  14348. // replacing existing element
  14349. var oldElm = oldVnode.elm;
  14350. var parentElm$1 = nodeOps.parentNode(oldElm);
  14351. createElm(
  14352. vnode,
  14353. insertedVnodeQueue,
  14354. // extremely rare edge case: do not insert if old element is in a
  14355. // leaving transition. Only happens when combining transition +
  14356. // keep-alive + HOCs. (#4590)
  14357. oldElm._leaveCb ? null : parentElm$1,
  14358. nodeOps.nextSibling(oldElm)
  14359. );
  14360. if (isDef(vnode.parent)) {
  14361. // component root element replaced.
  14362. // update parent placeholder node element, recursively
  14363. var ancestor = vnode.parent;
  14364. while (ancestor) {
  14365. ancestor.elm = vnode.elm;
  14366. ancestor = ancestor.parent;
  14367. }
  14368. if (isPatchable(vnode)) {
  14369. for (var i = 0; i < cbs.create.length; ++i) {
  14370. cbs.create[i](emptyNode, vnode.parent);
  14371. }
  14372. }
  14373. }
  14374. if (isDef(parentElm$1)) {
  14375. removeVnodes(parentElm$1, [oldVnode], 0, 0);
  14376. } else if (isDef(oldVnode.tag)) {
  14377. invokeDestroyHook(oldVnode);
  14378. }
  14379. }
  14380. }
  14381. invokeInsertHook(vnode, insertedVnodeQueue, isInitialPatch);
  14382. return vnode.elm
  14383. }
  14384. }
  14385. /* */
  14386. var directives = {
  14387. create: updateDirectives,
  14388. update: updateDirectives,
  14389. destroy: function unbindDirectives (vnode) {
  14390. updateDirectives(vnode, emptyNode);
  14391. }
  14392. };
  14393. function updateDirectives (oldVnode, vnode) {
  14394. if (oldVnode.data.directives || vnode.data.directives) {
  14395. _update(oldVnode, vnode);
  14396. }
  14397. }
  14398. function _update (oldVnode, vnode) {
  14399. var isCreate = oldVnode === emptyNode;
  14400. var isDestroy = vnode === emptyNode;
  14401. var oldDirs = normalizeDirectives$1(oldVnode.data.directives, oldVnode.context);
  14402. var newDirs = normalizeDirectives$1(vnode.data.directives, vnode.context);
  14403. var dirsWithInsert = [];
  14404. var dirsWithPostpatch = [];
  14405. var key, oldDir, dir;
  14406. for (key in newDirs) {
  14407. oldDir = oldDirs[key];
  14408. dir = newDirs[key];
  14409. if (!oldDir) {
  14410. // new directive, bind
  14411. callHook$1(dir, 'bind', vnode, oldVnode);
  14412. if (dir.def && dir.def.inserted) {
  14413. dirsWithInsert.push(dir);
  14414. }
  14415. } else {
  14416. // existing directive, update
  14417. dir.oldValue = oldDir.value;
  14418. callHook$1(dir, 'update', vnode, oldVnode);
  14419. if (dir.def && dir.def.componentUpdated) {
  14420. dirsWithPostpatch.push(dir);
  14421. }
  14422. }
  14423. }
  14424. if (dirsWithInsert.length) {
  14425. var callInsert = function () {
  14426. for (var i = 0; i < dirsWithInsert.length; i++) {
  14427. callHook$1(dirsWithInsert[i], 'inserted', vnode, oldVnode);
  14428. }
  14429. };
  14430. if (isCreate) {
  14431. mergeVNodeHook(vnode.data.hook || (vnode.data.hook = {}), 'insert', callInsert);
  14432. } else {
  14433. callInsert();
  14434. }
  14435. }
  14436. if (dirsWithPostpatch.length) {
  14437. mergeVNodeHook(vnode.data.hook || (vnode.data.hook = {}), 'postpatch', function () {
  14438. for (var i = 0; i < dirsWithPostpatch.length; i++) {
  14439. callHook$1(dirsWithPostpatch[i], 'componentUpdated', vnode, oldVnode);
  14440. }
  14441. });
  14442. }
  14443. if (!isCreate) {
  14444. for (key in oldDirs) {
  14445. if (!newDirs[key]) {
  14446. // no longer present, unbind
  14447. callHook$1(oldDirs[key], 'unbind', oldVnode, oldVnode, isDestroy);
  14448. }
  14449. }
  14450. }
  14451. }
  14452. var emptyModifiers = Object.create(null);
  14453. function normalizeDirectives$1 (
  14454. dirs,
  14455. vm
  14456. ) {
  14457. var res = Object.create(null);
  14458. if (!dirs) {
  14459. return res
  14460. }
  14461. var i, dir;
  14462. for (i = 0; i < dirs.length; i++) {
  14463. dir = dirs[i];
  14464. if (!dir.modifiers) {
  14465. dir.modifiers = emptyModifiers;
  14466. }
  14467. res[getRawDirName(dir)] = dir;
  14468. dir.def = resolveAsset(vm.$options, 'directives', dir.name, true);
  14469. }
  14470. return res
  14471. }
  14472. function getRawDirName (dir) {
  14473. return dir.rawName || ((dir.name) + "." + (Object.keys(dir.modifiers || {}).join('.')))
  14474. }
  14475. function callHook$1 (dir, hook, vnode, oldVnode, isDestroy) {
  14476. var fn = dir.def && dir.def[hook];
  14477. if (fn) {
  14478. try {
  14479. fn(vnode.elm, dir, vnode, oldVnode, isDestroy);
  14480. } catch (e) {
  14481. handleError(e, vnode.context, ("directive " + (dir.name) + " " + hook + " hook"));
  14482. }
  14483. }
  14484. }
  14485. var baseModules = [
  14486. ref,
  14487. directives
  14488. ];
  14489. /* */
  14490. function updateAttrs (oldVnode, vnode) {
  14491. if (isUndef(oldVnode.data.attrs) && isUndef(vnode.data.attrs)) {
  14492. return
  14493. }
  14494. var key, cur, old;
  14495. var elm = vnode.elm;
  14496. var oldAttrs = oldVnode.data.attrs || {};
  14497. var attrs = vnode.data.attrs || {};
  14498. // clone observed objects, as the user probably wants to mutate it
  14499. if (isDef(attrs.__ob__)) {
  14500. attrs = vnode.data.attrs = extend({}, attrs);
  14501. }
  14502. for (key in attrs) {
  14503. cur = attrs[key];
  14504. old = oldAttrs[key];
  14505. if (old !== cur) {
  14506. setAttr(elm, key, cur);
  14507. }
  14508. }
  14509. // #4391: in IE9, setting type can reset value for input[type=radio]
  14510. /* istanbul ignore if */
  14511. if (isIE9 && attrs.value !== oldAttrs.value) {
  14512. setAttr(elm, 'value', attrs.value);
  14513. }
  14514. for (key in oldAttrs) {
  14515. if (isUndef(attrs[key])) {
  14516. if (isXlink(key)) {
  14517. elm.removeAttributeNS(xlinkNS, getXlinkProp(key));
  14518. } else if (!isEnumeratedAttr(key)) {
  14519. elm.removeAttribute(key);
  14520. }
  14521. }
  14522. }
  14523. }
  14524. function setAttr (el, key, value) {
  14525. if (isBooleanAttr(key)) {
  14526. // set attribute for blank value
  14527. // e.g. <option disabled>Select one</option>
  14528. if (isFalsyAttrValue(value)) {
  14529. el.removeAttribute(key);
  14530. } else {
  14531. el.setAttribute(key, key);
  14532. }
  14533. } else if (isEnumeratedAttr(key)) {
  14534. el.setAttribute(key, isFalsyAttrValue(value) || value === 'false' ? 'false' : 'true');
  14535. } else if (isXlink(key)) {
  14536. if (isFalsyAttrValue(value)) {
  14537. el.removeAttributeNS(xlinkNS, getXlinkProp(key));
  14538. } else {
  14539. el.setAttributeNS(xlinkNS, key, value);
  14540. }
  14541. } else {
  14542. if (isFalsyAttrValue(value)) {
  14543. el.removeAttribute(key);
  14544. } else {
  14545. el.setAttribute(key, value);
  14546. }
  14547. }
  14548. }
  14549. var attrs = {
  14550. create: updateAttrs,
  14551. update: updateAttrs
  14552. };
  14553. /* */
  14554. function updateClass (oldVnode, vnode) {
  14555. var el = vnode.elm;
  14556. var data = vnode.data;
  14557. var oldData = oldVnode.data;
  14558. if (
  14559. isUndef(data.staticClass) &&
  14560. isUndef(data.class) && (
  14561. isUndef(oldData) || (
  14562. isUndef(oldData.staticClass) &&
  14563. isUndef(oldData.class)
  14564. )
  14565. )
  14566. ) {
  14567. return
  14568. }
  14569. var cls = genClassForVnode(vnode);
  14570. // handle transition classes
  14571. var transitionClass = el._transitionClasses;
  14572. if (isDef(transitionClass)) {
  14573. cls = concat(cls, stringifyClass(transitionClass));
  14574. }
  14575. // set the class
  14576. if (cls !== el._prevClass) {
  14577. el.setAttribute('class', cls);
  14578. el._prevClass = cls;
  14579. }
  14580. }
  14581. var klass = {
  14582. create: updateClass,
  14583. update: updateClass
  14584. };
  14585. /* */
  14586. var validDivisionCharRE = /[\w).+\-_$\]]/;
  14587. function wrapFilter (exp, filter) {
  14588. var i = filter.indexOf('(');
  14589. if (i < 0) {
  14590. // _f: resolveFilter
  14591. return ("_f(\"" + filter + "\")(" + exp + ")")
  14592. } else {
  14593. var name = filter.slice(0, i);
  14594. var args = filter.slice(i + 1);
  14595. return ("_f(\"" + name + "\")(" + exp + "," + args)
  14596. }
  14597. }
  14598. /* */
  14599. /* */
  14600. /**
  14601. * Cross-platform code generation for component v-model
  14602. */
  14603. /**
  14604. * Cross-platform codegen helper for generating v-model value assignment code.
  14605. */
  14606. /**
  14607. * parse directive model to do the array update transform. a[idx] = val => $$a.splice($$idx, 1, val)
  14608. *
  14609. * for loop possible cases:
  14610. *
  14611. * - test
  14612. * - test[idx]
  14613. * - test[test1[idx]]
  14614. * - test["a"][idx]
  14615. * - xxx.test[a[a].test1[idx]]
  14616. * - test.xxx.a["asa"][test1[idx]]
  14617. *
  14618. */
  14619. var str;
  14620. var index$1;
  14621. /* */
  14622. // in some cases, the event used has to be determined at runtime
  14623. // so we used some reserved tokens during compile.
  14624. var RANGE_TOKEN = '__r';
  14625. var CHECKBOX_RADIO_TOKEN = '__c';
  14626. /* */
  14627. // normalize v-model event tokens that can only be determined at runtime.
  14628. // it's important to place the event as the first in the array because
  14629. // the whole point is ensuring the v-model callback gets called before
  14630. // user-attached handlers.
  14631. function normalizeEvents (on) {
  14632. var event;
  14633. /* istanbul ignore if */
  14634. if (isDef(on[RANGE_TOKEN])) {
  14635. // IE input[type=range] only supports `change` event
  14636. event = isIE ? 'change' : 'input';
  14637. on[event] = [].concat(on[RANGE_TOKEN], on[event] || []);
  14638. delete on[RANGE_TOKEN];
  14639. }
  14640. if (isDef(on[CHECKBOX_RADIO_TOKEN])) {
  14641. // Chrome fires microtasks in between click/change, leads to #4521
  14642. event = isChrome ? 'click' : 'change';
  14643. on[event] = [].concat(on[CHECKBOX_RADIO_TOKEN], on[event] || []);
  14644. delete on[CHECKBOX_RADIO_TOKEN];
  14645. }
  14646. }
  14647. var target$1;
  14648. function add$1 (
  14649. event,
  14650. handler,
  14651. once$$1,
  14652. capture,
  14653. passive
  14654. ) {
  14655. if (once$$1) {
  14656. var oldHandler = handler;
  14657. var _target = target$1; // save current target element in closure
  14658. handler = function (ev) {
  14659. var res = arguments.length === 1
  14660. ? oldHandler(ev)
  14661. : oldHandler.apply(null, arguments);
  14662. if (res !== null) {
  14663. remove$2(event, handler, capture, _target);
  14664. }
  14665. };
  14666. }
  14667. target$1.addEventListener(
  14668. event,
  14669. handler,
  14670. supportsPassive
  14671. ? { capture: capture, passive: passive }
  14672. : capture
  14673. );
  14674. }
  14675. function remove$2 (
  14676. event,
  14677. handler,
  14678. capture,
  14679. _target
  14680. ) {
  14681. (_target || target$1).removeEventListener(event, handler, capture);
  14682. }
  14683. function updateDOMListeners (oldVnode, vnode) {
  14684. if (isUndef(oldVnode.data.on) && isUndef(vnode.data.on)) {
  14685. return
  14686. }
  14687. var on = vnode.data.on || {};
  14688. var oldOn = oldVnode.data.on || {};
  14689. target$1 = vnode.elm;
  14690. normalizeEvents(on);
  14691. updateListeners(on, oldOn, add$1, remove$2, vnode.context);
  14692. }
  14693. var events = {
  14694. create: updateDOMListeners,
  14695. update: updateDOMListeners
  14696. };
  14697. /* */
  14698. function updateDOMProps (oldVnode, vnode) {
  14699. if (isUndef(oldVnode.data.domProps) && isUndef(vnode.data.domProps)) {
  14700. return
  14701. }
  14702. var key, cur;
  14703. var elm = vnode.elm;
  14704. var oldProps = oldVnode.data.domProps || {};
  14705. var props = vnode.data.domProps || {};
  14706. // clone observed objects, as the user probably wants to mutate it
  14707. if (isDef(props.__ob__)) {
  14708. props = vnode.data.domProps = extend({}, props);
  14709. }
  14710. for (key in oldProps) {
  14711. if (isUndef(props[key])) {
  14712. elm[key] = '';
  14713. }
  14714. }
  14715. for (key in props) {
  14716. cur = props[key];
  14717. // ignore children if the node has textContent or innerHTML,
  14718. // as these will throw away existing DOM nodes and cause removal errors
  14719. // on subsequent patches (#3360)
  14720. if (key === 'textContent' || key === 'innerHTML') {
  14721. if (vnode.children) { vnode.children.length = 0; }
  14722. if (cur === oldProps[key]) { continue }
  14723. }
  14724. if (key === 'value') {
  14725. // store value as _value as well since
  14726. // non-string values will be stringified
  14727. elm._value = cur;
  14728. // avoid resetting cursor position when value is the same
  14729. var strCur = isUndef(cur) ? '' : String(cur);
  14730. if (shouldUpdateValue(elm, vnode, strCur)) {
  14731. elm.value = strCur;
  14732. }
  14733. } else {
  14734. elm[key] = cur;
  14735. }
  14736. }
  14737. }
  14738. // check platforms/web/util/attrs.js acceptValue
  14739. function shouldUpdateValue (
  14740. elm,
  14741. vnode,
  14742. checkVal
  14743. ) {
  14744. return (!elm.composing && (
  14745. vnode.tag === 'option' ||
  14746. isDirty(elm, checkVal) ||
  14747. isInputChanged(elm, checkVal)
  14748. ))
  14749. }
  14750. function isDirty (elm, checkVal) {
  14751. // return true when textbox (.number and .trim) loses focus and its value is not equal to the updated value
  14752. return document.activeElement !== elm && elm.value !== checkVal
  14753. }
  14754. function isInputChanged (elm, newVal) {
  14755. var value = elm.value;
  14756. var modifiers = elm._vModifiers; // injected by v-model runtime
  14757. if ((isDef(modifiers) && modifiers.number) || elm.type === 'number') {
  14758. return toNumber(value) !== toNumber(newVal)
  14759. }
  14760. if (isDef(modifiers) && modifiers.trim) {
  14761. return value.trim() !== newVal.trim()
  14762. }
  14763. return value !== newVal
  14764. }
  14765. var domProps = {
  14766. create: updateDOMProps,
  14767. update: updateDOMProps
  14768. };
  14769. /* */
  14770. var parseStyleText = cached(function (cssText) {
  14771. var res = {};
  14772. var listDelimiter = /;(?![^(]*\))/g;
  14773. var propertyDelimiter = /:(.+)/;
  14774. cssText.split(listDelimiter).forEach(function (item) {
  14775. if (item) {
  14776. var tmp = item.split(propertyDelimiter);
  14777. tmp.length > 1 && (res[tmp[0].trim()] = tmp[1].trim());
  14778. }
  14779. });
  14780. return res
  14781. });
  14782. // merge static and dynamic style data on the same vnode
  14783. function normalizeStyleData (data) {
  14784. var style = normalizeStyleBinding(data.style);
  14785. // static style is pre-processed into an object during compilation
  14786. // and is always a fresh object, so it's safe to merge into it
  14787. return data.staticStyle
  14788. ? extend(data.staticStyle, style)
  14789. : style
  14790. }
  14791. // normalize possible array / string values into Object
  14792. function normalizeStyleBinding (bindingStyle) {
  14793. if (Array.isArray(bindingStyle)) {
  14794. return toObject(bindingStyle)
  14795. }
  14796. if (typeof bindingStyle === 'string') {
  14797. return parseStyleText(bindingStyle)
  14798. }
  14799. return bindingStyle
  14800. }
  14801. /**
  14802. * parent component style should be after child's
  14803. * so that parent component's style could override it
  14804. */
  14805. function getStyle (vnode, checkChild) {
  14806. var res = {};
  14807. var styleData;
  14808. if (checkChild) {
  14809. var childNode = vnode;
  14810. while (childNode.componentInstance) {
  14811. childNode = childNode.componentInstance._vnode;
  14812. if (childNode.data && (styleData = normalizeStyleData(childNode.data))) {
  14813. extend(res, styleData);
  14814. }
  14815. }
  14816. }
  14817. if ((styleData = normalizeStyleData(vnode.data))) {
  14818. extend(res, styleData);
  14819. }
  14820. var parentNode = vnode;
  14821. while ((parentNode = parentNode.parent)) {
  14822. if (parentNode.data && (styleData = normalizeStyleData(parentNode.data))) {
  14823. extend(res, styleData);
  14824. }
  14825. }
  14826. return res
  14827. }
  14828. /* */
  14829. var cssVarRE = /^--/;
  14830. var importantRE = /\s*!important$/;
  14831. var setProp = function (el, name, val) {
  14832. /* istanbul ignore if */
  14833. if (cssVarRE.test(name)) {
  14834. el.style.setProperty(name, val);
  14835. } else if (importantRE.test(val)) {
  14836. el.style.setProperty(name, val.replace(importantRE, ''), 'important');
  14837. } else {
  14838. var normalizedName = normalize(name);
  14839. if (Array.isArray(val)) {
  14840. // Support values array created by autoprefixer, e.g.
  14841. // {display: ["-webkit-box", "-ms-flexbox", "flex"]}
  14842. // Set them one by one, and the browser will only set those it can recognize
  14843. for (var i = 0, len = val.length; i < len; i++) {
  14844. el.style[normalizedName] = val[i];
  14845. }
  14846. } else {
  14847. el.style[normalizedName] = val;
  14848. }
  14849. }
  14850. };
  14851. var prefixes = ['Webkit', 'Moz', 'ms'];
  14852. var testEl;
  14853. var normalize = cached(function (prop) {
  14854. testEl = testEl || document.createElement('div');
  14855. prop = camelize(prop);
  14856. if (prop !== 'filter' && (prop in testEl.style)) {
  14857. return prop
  14858. }
  14859. var upper = prop.charAt(0).toUpperCase() + prop.slice(1);
  14860. for (var i = 0; i < prefixes.length; i++) {
  14861. var prefixed = prefixes[i] + upper;
  14862. if (prefixed in testEl.style) {
  14863. return prefixed
  14864. }
  14865. }
  14866. });
  14867. function updateStyle (oldVnode, vnode) {
  14868. var data = vnode.data;
  14869. var oldData = oldVnode.data;
  14870. if (isUndef(data.staticStyle) && isUndef(data.style) &&
  14871. isUndef(oldData.staticStyle) && isUndef(oldData.style)
  14872. ) {
  14873. return
  14874. }
  14875. var cur, name;
  14876. var el = vnode.elm;
  14877. var oldStaticStyle = oldData.staticStyle;
  14878. var oldStyleBinding = oldData.normalizedStyle || oldData.style || {};
  14879. // if static style exists, stylebinding already merged into it when doing normalizeStyleData
  14880. var oldStyle = oldStaticStyle || oldStyleBinding;
  14881. var style = normalizeStyleBinding(vnode.data.style) || {};
  14882. // store normalized style under a different key for next diff
  14883. // make sure to clone it if it's reactive, since the user likley wants
  14884. // to mutate it.
  14885. vnode.data.normalizedStyle = isDef(style.__ob__)
  14886. ? extend({}, style)
  14887. : style;
  14888. var newStyle = getStyle(vnode, true);
  14889. for (name in oldStyle) {
  14890. if (isUndef(newStyle[name])) {
  14891. setProp(el, name, '');
  14892. }
  14893. }
  14894. for (name in newStyle) {
  14895. cur = newStyle[name];
  14896. if (cur !== oldStyle[name]) {
  14897. // ie9 setting to null has no effect, must use empty string
  14898. setProp(el, name, cur == null ? '' : cur);
  14899. }
  14900. }
  14901. }
  14902. var style = {
  14903. create: updateStyle,
  14904. update: updateStyle
  14905. };
  14906. /* */
  14907. /**
  14908. * Add class with compatibility for SVG since classList is not supported on
  14909. * SVG elements in IE
  14910. */
  14911. function addClass (el, cls) {
  14912. /* istanbul ignore if */
  14913. if (!cls || !(cls = cls.trim())) {
  14914. return
  14915. }
  14916. /* istanbul ignore else */
  14917. if (el.classList) {
  14918. if (cls.indexOf(' ') > -1) {
  14919. cls.split(/\s+/).forEach(function (c) { return el.classList.add(c); });
  14920. } else {
  14921. el.classList.add(cls);
  14922. }
  14923. } else {
  14924. var cur = " " + (el.getAttribute('class') || '') + " ";
  14925. if (cur.indexOf(' ' + cls + ' ') < 0) {
  14926. el.setAttribute('class', (cur + cls).trim());
  14927. }
  14928. }
  14929. }
  14930. /**
  14931. * Remove class with compatibility for SVG since classList is not supported on
  14932. * SVG elements in IE
  14933. */
  14934. function removeClass (el, cls) {
  14935. /* istanbul ignore if */
  14936. if (!cls || !(cls = cls.trim())) {
  14937. return
  14938. }
  14939. /* istanbul ignore else */
  14940. if (el.classList) {
  14941. if (cls.indexOf(' ') > -1) {
  14942. cls.split(/\s+/).forEach(function (c) { return el.classList.remove(c); });
  14943. } else {
  14944. el.classList.remove(cls);
  14945. }
  14946. } else {
  14947. var cur = " " + (el.getAttribute('class') || '') + " ";
  14948. var tar = ' ' + cls + ' ';
  14949. while (cur.indexOf(tar) >= 0) {
  14950. cur = cur.replace(tar, ' ');
  14951. }
  14952. el.setAttribute('class', cur.trim());
  14953. }
  14954. }
  14955. /* */
  14956. function resolveTransition (def$$1) {
  14957. if (!def$$1) {
  14958. return
  14959. }
  14960. /* istanbul ignore else */
  14961. if (typeof def$$1 === 'object') {
  14962. var res = {};
  14963. if (def$$1.css !== false) {
  14964. extend(res, autoCssTransition(def$$1.name || 'v'));
  14965. }
  14966. extend(res, def$$1);
  14967. return res
  14968. } else if (typeof def$$1 === 'string') {
  14969. return autoCssTransition(def$$1)
  14970. }
  14971. }
  14972. var autoCssTransition = cached(function (name) {
  14973. return {
  14974. enterClass: (name + "-enter"),
  14975. enterToClass: (name + "-enter-to"),
  14976. enterActiveClass: (name + "-enter-active"),
  14977. leaveClass: (name + "-leave"),
  14978. leaveToClass: (name + "-leave-to"),
  14979. leaveActiveClass: (name + "-leave-active")
  14980. }
  14981. });
  14982. var hasTransition = inBrowser && !isIE9;
  14983. var TRANSITION = 'transition';
  14984. var ANIMATION = 'animation';
  14985. // Transition property/event sniffing
  14986. var transitionProp = 'transition';
  14987. var transitionEndEvent = 'transitionend';
  14988. var animationProp = 'animation';
  14989. var animationEndEvent = 'animationend';
  14990. if (hasTransition) {
  14991. /* istanbul ignore if */
  14992. if (window.ontransitionend === undefined &&
  14993. window.onwebkittransitionend !== undefined
  14994. ) {
  14995. transitionProp = 'WebkitTransition';
  14996. transitionEndEvent = 'webkitTransitionEnd';
  14997. }
  14998. if (window.onanimationend === undefined &&
  14999. window.onwebkitanimationend !== undefined
  15000. ) {
  15001. animationProp = 'WebkitAnimation';
  15002. animationEndEvent = 'webkitAnimationEnd';
  15003. }
  15004. }
  15005. // binding to window is necessary to make hot reload work in IE in strict mode
  15006. var raf = inBrowser && window.requestAnimationFrame
  15007. ? window.requestAnimationFrame.bind(window)
  15008. : setTimeout;
  15009. function nextFrame (fn) {
  15010. raf(function () {
  15011. raf(fn);
  15012. });
  15013. }
  15014. function addTransitionClass (el, cls) {
  15015. (el._transitionClasses || (el._transitionClasses = [])).push(cls);
  15016. addClass(el, cls);
  15017. }
  15018. function removeTransitionClass (el, cls) {
  15019. if (el._transitionClasses) {
  15020. remove(el._transitionClasses, cls);
  15021. }
  15022. removeClass(el, cls);
  15023. }
  15024. function whenTransitionEnds (
  15025. el,
  15026. expectedType,
  15027. cb
  15028. ) {
  15029. var ref = getTransitionInfo(el, expectedType);
  15030. var type = ref.type;
  15031. var timeout = ref.timeout;
  15032. var propCount = ref.propCount;
  15033. if (!type) { return cb() }
  15034. var event = type === TRANSITION ? transitionEndEvent : animationEndEvent;
  15035. var ended = 0;
  15036. var end = function () {
  15037. el.removeEventListener(event, onEnd);
  15038. cb();
  15039. };
  15040. var onEnd = function (e) {
  15041. if (e.target === el) {
  15042. if (++ended >= propCount) {
  15043. end();
  15044. }
  15045. }
  15046. };
  15047. setTimeout(function () {
  15048. if (ended < propCount) {
  15049. end();
  15050. }
  15051. }, timeout + 1);
  15052. el.addEventListener(event, onEnd);
  15053. }
  15054. var transformRE = /\b(transform|all)(,|$)/;
  15055. function getTransitionInfo (el, expectedType) {
  15056. var styles = window.getComputedStyle(el);
  15057. var transitionDelays = styles[transitionProp + 'Delay'].split(', ');
  15058. var transitionDurations = styles[transitionProp + 'Duration'].split(', ');
  15059. var transitionTimeout = getTimeout(transitionDelays, transitionDurations);
  15060. var animationDelays = styles[animationProp + 'Delay'].split(', ');
  15061. var animationDurations = styles[animationProp + 'Duration'].split(', ');
  15062. var animationTimeout = getTimeout(animationDelays, animationDurations);
  15063. var type;
  15064. var timeout = 0;
  15065. var propCount = 0;
  15066. /* istanbul ignore if */
  15067. if (expectedType === TRANSITION) {
  15068. if (transitionTimeout > 0) {
  15069. type = TRANSITION;
  15070. timeout = transitionTimeout;
  15071. propCount = transitionDurations.length;
  15072. }
  15073. } else if (expectedType === ANIMATION) {
  15074. if (animationTimeout > 0) {
  15075. type = ANIMATION;
  15076. timeout = animationTimeout;
  15077. propCount = animationDurations.length;
  15078. }
  15079. } else {
  15080. timeout = Math.max(transitionTimeout, animationTimeout);
  15081. type = timeout > 0
  15082. ? transitionTimeout > animationTimeout
  15083. ? TRANSITION
  15084. : ANIMATION
  15085. : null;
  15086. propCount = type
  15087. ? type === TRANSITION
  15088. ? transitionDurations.length
  15089. : animationDurations.length
  15090. : 0;
  15091. }
  15092. var hasTransform =
  15093. type === TRANSITION &&
  15094. transformRE.test(styles[transitionProp + 'Property']);
  15095. return {
  15096. type: type,
  15097. timeout: timeout,
  15098. propCount: propCount,
  15099. hasTransform: hasTransform
  15100. }
  15101. }
  15102. function getTimeout (delays, durations) {
  15103. /* istanbul ignore next */
  15104. while (delays.length < durations.length) {
  15105. delays = delays.concat(delays);
  15106. }
  15107. return Math.max.apply(null, durations.map(function (d, i) {
  15108. return toMs(d) + toMs(delays[i])
  15109. }))
  15110. }
  15111. function toMs (s) {
  15112. return Number(s.slice(0, -1)) * 1000
  15113. }
  15114. /* */
  15115. function enter (vnode, toggleDisplay) {
  15116. var el = vnode.elm;
  15117. // call leave callback now
  15118. if (isDef(el._leaveCb)) {
  15119. el._leaveCb.cancelled = true;
  15120. el._leaveCb();
  15121. }
  15122. var data = resolveTransition(vnode.data.transition);
  15123. if (isUndef(data)) {
  15124. return
  15125. }
  15126. /* istanbul ignore if */
  15127. if (isDef(el._enterCb) || el.nodeType !== 1) {
  15128. return
  15129. }
  15130. var css = data.css;
  15131. var type = data.type;
  15132. var enterClass = data.enterClass;
  15133. var enterToClass = data.enterToClass;
  15134. var enterActiveClass = data.enterActiveClass;
  15135. var appearClass = data.appearClass;
  15136. var appearToClass = data.appearToClass;
  15137. var appearActiveClass = data.appearActiveClass;
  15138. var beforeEnter = data.beforeEnter;
  15139. var enter = data.enter;
  15140. var afterEnter = data.afterEnter;
  15141. var enterCancelled = data.enterCancelled;
  15142. var beforeAppear = data.beforeAppear;
  15143. var appear = data.appear;
  15144. var afterAppear = data.afterAppear;
  15145. var appearCancelled = data.appearCancelled;
  15146. var duration = data.duration;
  15147. // activeInstance will always be the <transition> component managing this
  15148. // transition. One edge case to check is when the <transition> is placed
  15149. // as the root node of a child component. In that case we need to check
  15150. // <transition>'s parent for appear check.
  15151. var context = activeInstance;
  15152. var transitionNode = activeInstance.$vnode;
  15153. while (transitionNode && transitionNode.parent) {
  15154. transitionNode = transitionNode.parent;
  15155. context = transitionNode.context;
  15156. }
  15157. var isAppear = !context._isMounted || !vnode.isRootInsert;
  15158. if (isAppear && !appear && appear !== '') {
  15159. return
  15160. }
  15161. var startClass = isAppear && appearClass
  15162. ? appearClass
  15163. : enterClass;
  15164. var activeClass = isAppear && appearActiveClass
  15165. ? appearActiveClass
  15166. : enterActiveClass;
  15167. var toClass = isAppear && appearToClass
  15168. ? appearToClass
  15169. : enterToClass;
  15170. var beforeEnterHook = isAppear
  15171. ? (beforeAppear || beforeEnter)
  15172. : beforeEnter;
  15173. var enterHook = isAppear
  15174. ? (typeof appear === 'function' ? appear : enter)
  15175. : enter;
  15176. var afterEnterHook = isAppear
  15177. ? (afterAppear || afterEnter)
  15178. : afterEnter;
  15179. var enterCancelledHook = isAppear
  15180. ? (appearCancelled || enterCancelled)
  15181. : enterCancelled;
  15182. var explicitEnterDuration = toNumber(
  15183. isObject(duration)
  15184. ? duration.enter
  15185. : duration
  15186. );
  15187. if (process.env.NODE_ENV !== 'production' && explicitEnterDuration != null) {
  15188. checkDuration(explicitEnterDuration, 'enter', vnode);
  15189. }
  15190. var expectsCSS = css !== false && !isIE9;
  15191. var userWantsControl = getHookArgumentsLength(enterHook);
  15192. var cb = el._enterCb = once(function () {
  15193. if (expectsCSS) {
  15194. removeTransitionClass(el, toClass);
  15195. removeTransitionClass(el, activeClass);
  15196. }
  15197. if (cb.cancelled) {
  15198. if (expectsCSS) {
  15199. removeTransitionClass(el, startClass);
  15200. }
  15201. enterCancelledHook && enterCancelledHook(el);
  15202. } else {
  15203. afterEnterHook && afterEnterHook(el);
  15204. }
  15205. el._enterCb = null;
  15206. });
  15207. if (!vnode.data.show) {
  15208. // remove pending leave element on enter by injecting an insert hook
  15209. mergeVNodeHook(vnode.data.hook || (vnode.data.hook = {}), 'insert', function () {
  15210. var parent = el.parentNode;
  15211. var pendingNode = parent && parent._pending && parent._pending[vnode.key];
  15212. if (pendingNode &&
  15213. pendingNode.tag === vnode.tag &&
  15214. pendingNode.elm._leaveCb
  15215. ) {
  15216. pendingNode.elm._leaveCb();
  15217. }
  15218. enterHook && enterHook(el, cb);
  15219. });
  15220. }
  15221. // start enter transition
  15222. beforeEnterHook && beforeEnterHook(el);
  15223. if (expectsCSS) {
  15224. addTransitionClass(el, startClass);
  15225. addTransitionClass(el, activeClass);
  15226. nextFrame(function () {
  15227. addTransitionClass(el, toClass);
  15228. removeTransitionClass(el, startClass);
  15229. if (!cb.cancelled && !userWantsControl) {
  15230. if (isValidDuration(explicitEnterDuration)) {
  15231. setTimeout(cb, explicitEnterDuration);
  15232. } else {
  15233. whenTransitionEnds(el, type, cb);
  15234. }
  15235. }
  15236. });
  15237. }
  15238. if (vnode.data.show) {
  15239. toggleDisplay && toggleDisplay();
  15240. enterHook && enterHook(el, cb);
  15241. }
  15242. if (!expectsCSS && !userWantsControl) {
  15243. cb();
  15244. }
  15245. }
  15246. function leave (vnode, rm) {
  15247. var el = vnode.elm;
  15248. // call enter callback now
  15249. if (isDef(el._enterCb)) {
  15250. el._enterCb.cancelled = true;
  15251. el._enterCb();
  15252. }
  15253. var data = resolveTransition(vnode.data.transition);
  15254. if (isUndef(data)) {
  15255. return rm()
  15256. }
  15257. /* istanbul ignore if */
  15258. if (isDef(el._leaveCb) || el.nodeType !== 1) {
  15259. return
  15260. }
  15261. var css = data.css;
  15262. var type = data.type;
  15263. var leaveClass = data.leaveClass;
  15264. var leaveToClass = data.leaveToClass;
  15265. var leaveActiveClass = data.leaveActiveClass;
  15266. var beforeLeave = data.beforeLeave;
  15267. var leave = data.leave;
  15268. var afterLeave = data.afterLeave;
  15269. var leaveCancelled = data.leaveCancelled;
  15270. var delayLeave = data.delayLeave;
  15271. var duration = data.duration;
  15272. var expectsCSS = css !== false && !isIE9;
  15273. var userWantsControl = getHookArgumentsLength(leave);
  15274. var explicitLeaveDuration = toNumber(
  15275. isObject(duration)
  15276. ? duration.leave
  15277. : duration
  15278. );
  15279. if (process.env.NODE_ENV !== 'production' && isDef(explicitLeaveDuration)) {
  15280. checkDuration(explicitLeaveDuration, 'leave', vnode);
  15281. }
  15282. var cb = el._leaveCb = once(function () {
  15283. if (el.parentNode && el.parentNode._pending) {
  15284. el.parentNode._pending[vnode.key] = null;
  15285. }
  15286. if (expectsCSS) {
  15287. removeTransitionClass(el, leaveToClass);
  15288. removeTransitionClass(el, leaveActiveClass);
  15289. }
  15290. if (cb.cancelled) {
  15291. if (expectsCSS) {
  15292. removeTransitionClass(el, leaveClass);
  15293. }
  15294. leaveCancelled && leaveCancelled(el);
  15295. } else {
  15296. rm();
  15297. afterLeave && afterLeave(el);
  15298. }
  15299. el._leaveCb = null;
  15300. });
  15301. if (delayLeave) {
  15302. delayLeave(performLeave);
  15303. } else {
  15304. performLeave();
  15305. }
  15306. function performLeave () {
  15307. // the delayed leave may have already been cancelled
  15308. if (cb.cancelled) {
  15309. return
  15310. }
  15311. // record leaving element
  15312. if (!vnode.data.show) {
  15313. (el.parentNode._pending || (el.parentNode._pending = {}))[(vnode.key)] = vnode;
  15314. }
  15315. beforeLeave && beforeLeave(el);
  15316. if (expectsCSS) {
  15317. addTransitionClass(el, leaveClass);
  15318. addTransitionClass(el, leaveActiveClass);
  15319. nextFrame(function () {
  15320. addTransitionClass(el, leaveToClass);
  15321. removeTransitionClass(el, leaveClass);
  15322. if (!cb.cancelled && !userWantsControl) {
  15323. if (isValidDuration(explicitLeaveDuration)) {
  15324. setTimeout(cb, explicitLeaveDuration);
  15325. } else {
  15326. whenTransitionEnds(el, type, cb);
  15327. }
  15328. }
  15329. });
  15330. }
  15331. leave && leave(el, cb);
  15332. if (!expectsCSS && !userWantsControl) {
  15333. cb();
  15334. }
  15335. }
  15336. }
  15337. // only used in dev mode
  15338. function checkDuration (val, name, vnode) {
  15339. if (typeof val !== 'number') {
  15340. warn(
  15341. "<transition> explicit " + name + " duration is not a valid number - " +
  15342. "got " + (JSON.stringify(val)) + ".",
  15343. vnode.context
  15344. );
  15345. } else if (isNaN(val)) {
  15346. warn(
  15347. "<transition> explicit " + name + " duration is NaN - " +
  15348. 'the duration expression might be incorrect.',
  15349. vnode.context
  15350. );
  15351. }
  15352. }
  15353. function isValidDuration (val) {
  15354. return typeof val === 'number' && !isNaN(val)
  15355. }
  15356. /**
  15357. * Normalize a transition hook's argument length. The hook may be:
  15358. * - a merged hook (invoker) with the original in .fns
  15359. * - a wrapped component method (check ._length)
  15360. * - a plain function (.length)
  15361. */
  15362. function getHookArgumentsLength (fn) {
  15363. if (isUndef(fn)) {
  15364. return false
  15365. }
  15366. var invokerFns = fn.fns;
  15367. if (isDef(invokerFns)) {
  15368. // invoker
  15369. return getHookArgumentsLength(
  15370. Array.isArray(invokerFns)
  15371. ? invokerFns[0]
  15372. : invokerFns
  15373. )
  15374. } else {
  15375. return (fn._length || fn.length) > 1
  15376. }
  15377. }
  15378. function _enter (_, vnode) {
  15379. if (vnode.data.show !== true) {
  15380. enter(vnode);
  15381. }
  15382. }
  15383. var transition = inBrowser ? {
  15384. create: _enter,
  15385. activate: _enter,
  15386. remove: function remove$$1 (vnode, rm) {
  15387. /* istanbul ignore else */
  15388. if (vnode.data.show !== true) {
  15389. leave(vnode, rm);
  15390. } else {
  15391. rm();
  15392. }
  15393. }
  15394. } : {};
  15395. var platformModules = [
  15396. attrs,
  15397. klass,
  15398. events,
  15399. domProps,
  15400. style,
  15401. transition
  15402. ];
  15403. /* */
  15404. // the directive module should be applied last, after all
  15405. // built-in modules have been applied.
  15406. var modules = platformModules.concat(baseModules);
  15407. var patch = createPatchFunction({ nodeOps: nodeOps, modules: modules });
  15408. /**
  15409. * Not type checking this file because flow doesn't like attaching
  15410. * properties to Elements.
  15411. */
  15412. /* istanbul ignore if */
  15413. if (isIE9) {
  15414. // http://www.matts411.com/post/internet-explorer-9-oninput/
  15415. document.addEventListener('selectionchange', function () {
  15416. var el = document.activeElement;
  15417. if (el && el.vmodel) {
  15418. trigger(el, 'input');
  15419. }
  15420. });
  15421. }
  15422. var model$1 = {
  15423. inserted: function inserted (el, binding, vnode) {
  15424. if (vnode.tag === 'select') {
  15425. var cb = function () {
  15426. setSelected(el, binding, vnode.context);
  15427. };
  15428. cb();
  15429. /* istanbul ignore if */
  15430. if (isIE || isEdge) {
  15431. setTimeout(cb, 0);
  15432. }
  15433. } else if (vnode.tag === 'textarea' || el.type === 'text' || el.type === 'password') {
  15434. el._vModifiers = binding.modifiers;
  15435. if (!binding.modifiers.lazy) {
  15436. // Safari < 10.2 & UIWebView doesn't fire compositionend when
  15437. // switching focus before confirming composition choice
  15438. // this also fixes the issue where some browsers e.g. iOS Chrome
  15439. // fires "change" instead of "input" on autocomplete.
  15440. el.addEventListener('change', onCompositionEnd);
  15441. if (!isAndroid) {
  15442. el.addEventListener('compositionstart', onCompositionStart);
  15443. el.addEventListener('compositionend', onCompositionEnd);
  15444. }
  15445. /* istanbul ignore if */
  15446. if (isIE9) {
  15447. el.vmodel = true;
  15448. }
  15449. }
  15450. }
  15451. },
  15452. componentUpdated: function componentUpdated (el, binding, vnode) {
  15453. if (vnode.tag === 'select') {
  15454. setSelected(el, binding, vnode.context);
  15455. // in case the options rendered by v-for have changed,
  15456. // it's possible that the value is out-of-sync with the rendered options.
  15457. // detect such cases and filter out values that no longer has a matching
  15458. // option in the DOM.
  15459. var needReset = el.multiple
  15460. ? binding.value.some(function (v) { return hasNoMatchingOption(v, el.options); })
  15461. : binding.value !== binding.oldValue && hasNoMatchingOption(binding.value, el.options);
  15462. if (needReset) {
  15463. trigger(el, 'change');
  15464. }
  15465. }
  15466. }
  15467. };
  15468. function setSelected (el, binding, vm) {
  15469. var value = binding.value;
  15470. var isMultiple = el.multiple;
  15471. if (isMultiple && !Array.isArray(value)) {
  15472. process.env.NODE_ENV !== 'production' && warn(
  15473. "<select multiple v-model=\"" + (binding.expression) + "\"> " +
  15474. "expects an Array value for its binding, but got " + (Object.prototype.toString.call(value).slice(8, -1)),
  15475. vm
  15476. );
  15477. return
  15478. }
  15479. var selected, option;
  15480. for (var i = 0, l = el.options.length; i < l; i++) {
  15481. option = el.options[i];
  15482. if (isMultiple) {
  15483. selected = looseIndexOf(value, getValue(option)) > -1;
  15484. if (option.selected !== selected) {
  15485. option.selected = selected;
  15486. }
  15487. } else {
  15488. if (looseEqual(getValue(option), value)) {
  15489. if (el.selectedIndex !== i) {
  15490. el.selectedIndex = i;
  15491. }
  15492. return
  15493. }
  15494. }
  15495. }
  15496. if (!isMultiple) {
  15497. el.selectedIndex = -1;
  15498. }
  15499. }
  15500. function hasNoMatchingOption (value, options) {
  15501. for (var i = 0, l = options.length; i < l; i++) {
  15502. if (looseEqual(getValue(options[i]), value)) {
  15503. return false
  15504. }
  15505. }
  15506. return true
  15507. }
  15508. function getValue (option) {
  15509. return '_value' in option
  15510. ? option._value
  15511. : option.value
  15512. }
  15513. function onCompositionStart (e) {
  15514. e.target.composing = true;
  15515. }
  15516. function onCompositionEnd (e) {
  15517. // prevent triggering an input event for no reason
  15518. if (!e.target.composing) { return }
  15519. e.target.composing = false;
  15520. trigger(e.target, 'input');
  15521. }
  15522. function trigger (el, type) {
  15523. var e = document.createEvent('HTMLEvents');
  15524. e.initEvent(type, true, true);
  15525. el.dispatchEvent(e);
  15526. }
  15527. /* */
  15528. // recursively search for possible transition defined inside the component root
  15529. function locateNode (vnode) {
  15530. return vnode.componentInstance && (!vnode.data || !vnode.data.transition)
  15531. ? locateNode(vnode.componentInstance._vnode)
  15532. : vnode
  15533. }
  15534. var show = {
  15535. bind: function bind (el, ref, vnode) {
  15536. var value = ref.value;
  15537. vnode = locateNode(vnode);
  15538. var transition = vnode.data && vnode.data.transition;
  15539. var originalDisplay = el.__vOriginalDisplay =
  15540. el.style.display === 'none' ? '' : el.style.display;
  15541. if (value && transition && !isIE9) {
  15542. vnode.data.show = true;
  15543. enter(vnode, function () {
  15544. el.style.display = originalDisplay;
  15545. });
  15546. } else {
  15547. el.style.display = value ? originalDisplay : 'none';
  15548. }
  15549. },
  15550. update: function update (el, ref, vnode) {
  15551. var value = ref.value;
  15552. var oldValue = ref.oldValue;
  15553. /* istanbul ignore if */
  15554. if (value === oldValue) { return }
  15555. vnode = locateNode(vnode);
  15556. var transition = vnode.data && vnode.data.transition;
  15557. if (transition && !isIE9) {
  15558. vnode.data.show = true;
  15559. if (value) {
  15560. enter(vnode, function () {
  15561. el.style.display = el.__vOriginalDisplay;
  15562. });
  15563. } else {
  15564. leave(vnode, function () {
  15565. el.style.display = 'none';
  15566. });
  15567. }
  15568. } else {
  15569. el.style.display = value ? el.__vOriginalDisplay : 'none';
  15570. }
  15571. },
  15572. unbind: function unbind (
  15573. el,
  15574. binding,
  15575. vnode,
  15576. oldVnode,
  15577. isDestroy
  15578. ) {
  15579. if (!isDestroy) {
  15580. el.style.display = el.__vOriginalDisplay;
  15581. }
  15582. }
  15583. };
  15584. var platformDirectives = {
  15585. model: model$1,
  15586. show: show
  15587. };
  15588. /* */
  15589. // Provides transition support for a single element/component.
  15590. // supports transition mode (out-in / in-out)
  15591. var transitionProps = {
  15592. name: String,
  15593. appear: Boolean,
  15594. css: Boolean,
  15595. mode: String,
  15596. type: String,
  15597. enterClass: String,
  15598. leaveClass: String,
  15599. enterToClass: String,
  15600. leaveToClass: String,
  15601. enterActiveClass: String,
  15602. leaveActiveClass: String,
  15603. appearClass: String,
  15604. appearActiveClass: String,
  15605. appearToClass: String,
  15606. duration: [Number, String, Object]
  15607. };
  15608. // in case the child is also an abstract component, e.g. <keep-alive>
  15609. // we want to recursively retrieve the real component to be rendered
  15610. function getRealChild (vnode) {
  15611. var compOptions = vnode && vnode.componentOptions;
  15612. if (compOptions && compOptions.Ctor.options.abstract) {
  15613. return getRealChild(getFirstComponentChild(compOptions.children))
  15614. } else {
  15615. return vnode
  15616. }
  15617. }
  15618. function extractTransitionData (comp) {
  15619. var data = {};
  15620. var options = comp.$options;
  15621. // props
  15622. for (var key in options.propsData) {
  15623. data[key] = comp[key];
  15624. }
  15625. // events.
  15626. // extract listeners and pass them directly to the transition methods
  15627. var listeners = options._parentListeners;
  15628. for (var key$1 in listeners) {
  15629. data[camelize(key$1)] = listeners[key$1];
  15630. }
  15631. return data
  15632. }
  15633. function placeholder (h, rawChild) {
  15634. if (/\d-keep-alive$/.test(rawChild.tag)) {
  15635. return h('keep-alive', {
  15636. props: rawChild.componentOptions.propsData
  15637. })
  15638. }
  15639. }
  15640. function hasParentTransition (vnode) {
  15641. while ((vnode = vnode.parent)) {
  15642. if (vnode.data.transition) {
  15643. return true
  15644. }
  15645. }
  15646. }
  15647. function isSameChild (child, oldChild) {
  15648. return oldChild.key === child.key && oldChild.tag === child.tag
  15649. }
  15650. var Transition = {
  15651. name: 'transition',
  15652. props: transitionProps,
  15653. abstract: true,
  15654. render: function render (h) {
  15655. var this$1 = this;
  15656. var children = this.$slots.default;
  15657. if (!children) {
  15658. return
  15659. }
  15660. // filter out text nodes (possible whitespaces)
  15661. children = children.filter(function (c) { return c.tag; });
  15662. /* istanbul ignore if */
  15663. if (!children.length) {
  15664. return
  15665. }
  15666. // warn multiple elements
  15667. if (process.env.NODE_ENV !== 'production' && children.length > 1) {
  15668. warn(
  15669. '<transition> can only be used on a single element. Use ' +
  15670. '<transition-group> for lists.',
  15671. this.$parent
  15672. );
  15673. }
  15674. var mode = this.mode;
  15675. // warn invalid mode
  15676. if (process.env.NODE_ENV !== 'production' &&
  15677. mode && mode !== 'in-out' && mode !== 'out-in'
  15678. ) {
  15679. warn(
  15680. 'invalid <transition> mode: ' + mode,
  15681. this.$parent
  15682. );
  15683. }
  15684. var rawChild = children[0];
  15685. // if this is a component root node and the component's
  15686. // parent container node also has transition, skip.
  15687. if (hasParentTransition(this.$vnode)) {
  15688. return rawChild
  15689. }
  15690. // apply transition data to child
  15691. // use getRealChild() to ignore abstract components e.g. keep-alive
  15692. var child = getRealChild(rawChild);
  15693. /* istanbul ignore if */
  15694. if (!child) {
  15695. return rawChild
  15696. }
  15697. if (this._leaving) {
  15698. return placeholder(h, rawChild)
  15699. }
  15700. // ensure a key that is unique to the vnode type and to this transition
  15701. // component instance. This key will be used to remove pending leaving nodes
  15702. // during entering.
  15703. var id = "__transition-" + (this._uid) + "-";
  15704. child.key = child.key == null
  15705. ? id + child.tag
  15706. : isPrimitive(child.key)
  15707. ? (String(child.key).indexOf(id) === 0 ? child.key : id + child.key)
  15708. : child.key;
  15709. var data = (child.data || (child.data = {})).transition = extractTransitionData(this);
  15710. var oldRawChild = this._vnode;
  15711. var oldChild = getRealChild(oldRawChild);
  15712. // mark v-show
  15713. // so that the transition module can hand over the control to the directive
  15714. if (child.data.directives && child.data.directives.some(function (d) { return d.name === 'show'; })) {
  15715. child.data.show = true;
  15716. }
  15717. if (oldChild && oldChild.data && !isSameChild(child, oldChild)) {
  15718. // replace old child transition data with fresh one
  15719. // important for dynamic transitions!
  15720. var oldData = oldChild && (oldChild.data.transition = extend({}, data));
  15721. // handle transition mode
  15722. if (mode === 'out-in') {
  15723. // return placeholder node and queue update when leave finishes
  15724. this._leaving = true;
  15725. mergeVNodeHook(oldData, 'afterLeave', function () {
  15726. this$1._leaving = false;
  15727. this$1.$forceUpdate();
  15728. });
  15729. return placeholder(h, rawChild)
  15730. } else if (mode === 'in-out') {
  15731. var delayedLeave;
  15732. var performLeave = function () { delayedLeave(); };
  15733. mergeVNodeHook(data, 'afterEnter', performLeave);
  15734. mergeVNodeHook(data, 'enterCancelled', performLeave);
  15735. mergeVNodeHook(oldData, 'delayLeave', function (leave) { delayedLeave = leave; });
  15736. }
  15737. }
  15738. return rawChild
  15739. }
  15740. };
  15741. /* */
  15742. // Provides transition support for list items.
  15743. // supports move transitions using the FLIP technique.
  15744. // Because the vdom's children update algorithm is "unstable" - i.e.
  15745. // it doesn't guarantee the relative positioning of removed elements,
  15746. // we force transition-group to update its children into two passes:
  15747. // in the first pass, we remove all nodes that need to be removed,
  15748. // triggering their leaving transition; in the second pass, we insert/move
  15749. // into the final desired state. This way in the second pass removed
  15750. // nodes will remain where they should be.
  15751. var props = extend({
  15752. tag: String,
  15753. moveClass: String
  15754. }, transitionProps);
  15755. delete props.mode;
  15756. var TransitionGroup = {
  15757. props: props,
  15758. render: function render (h) {
  15759. var tag = this.tag || this.$vnode.data.tag || 'span';
  15760. var map = Object.create(null);
  15761. var prevChildren = this.prevChildren = this.children;
  15762. var rawChildren = this.$slots.default || [];
  15763. var children = this.children = [];
  15764. var transitionData = extractTransitionData(this);
  15765. for (var i = 0; i < rawChildren.length; i++) {
  15766. var c = rawChildren[i];
  15767. if (c.tag) {
  15768. if (c.key != null && String(c.key).indexOf('__vlist') !== 0) {
  15769. children.push(c);
  15770. map[c.key] = c
  15771. ;(c.data || (c.data = {})).transition = transitionData;
  15772. } else if (process.env.NODE_ENV !== 'production') {
  15773. var opts = c.componentOptions;
  15774. var name = opts ? (opts.Ctor.options.name || opts.tag || '') : c.tag;
  15775. warn(("<transition-group> children must be keyed: <" + name + ">"));
  15776. }
  15777. }
  15778. }
  15779. if (prevChildren) {
  15780. var kept = [];
  15781. var removed = [];
  15782. for (var i$1 = 0; i$1 < prevChildren.length; i$1++) {
  15783. var c$1 = prevChildren[i$1];
  15784. c$1.data.transition = transitionData;
  15785. c$1.data.pos = c$1.elm.getBoundingClientRect();
  15786. if (map[c$1.key]) {
  15787. kept.push(c$1);
  15788. } else {
  15789. removed.push(c$1);
  15790. }
  15791. }
  15792. this.kept = h(tag, null, kept);
  15793. this.removed = removed;
  15794. }
  15795. return h(tag, null, children)
  15796. },
  15797. beforeUpdate: function beforeUpdate () {
  15798. // force removing pass
  15799. this.__patch__(
  15800. this._vnode,
  15801. this.kept,
  15802. false, // hydrating
  15803. true // removeOnly (!important, avoids unnecessary moves)
  15804. );
  15805. this._vnode = this.kept;
  15806. },
  15807. updated: function updated () {
  15808. var children = this.prevChildren;
  15809. var moveClass = this.moveClass || ((this.name || 'v') + '-move');
  15810. if (!children.length || !this.hasMove(children[0].elm, moveClass)) {
  15811. return
  15812. }
  15813. // we divide the work into three loops to avoid mixing DOM reads and writes
  15814. // in each iteration - which helps prevent layout thrashing.
  15815. children.forEach(callPendingCbs);
  15816. children.forEach(recordPosition);
  15817. children.forEach(applyTranslation);
  15818. // force reflow to put everything in position
  15819. var body = document.body;
  15820. var f = body.offsetHeight; // eslint-disable-line
  15821. children.forEach(function (c) {
  15822. if (c.data.moved) {
  15823. var el = c.elm;
  15824. var s = el.style;
  15825. addTransitionClass(el, moveClass);
  15826. s.transform = s.WebkitTransform = s.transitionDuration = '';
  15827. el.addEventListener(transitionEndEvent, el._moveCb = function cb (e) {
  15828. if (!e || /transform$/.test(e.propertyName)) {
  15829. el.removeEventListener(transitionEndEvent, cb);
  15830. el._moveCb = null;
  15831. removeTransitionClass(el, moveClass);
  15832. }
  15833. });
  15834. }
  15835. });
  15836. },
  15837. methods: {
  15838. hasMove: function hasMove (el, moveClass) {
  15839. /* istanbul ignore if */
  15840. if (!hasTransition) {
  15841. return false
  15842. }
  15843. if (this._hasMove != null) {
  15844. return this._hasMove
  15845. }
  15846. // Detect whether an element with the move class applied has
  15847. // CSS transitions. Since the element may be inside an entering
  15848. // transition at this very moment, we make a clone of it and remove
  15849. // all other transition classes applied to ensure only the move class
  15850. // is applied.
  15851. var clone = el.cloneNode();
  15852. if (el._transitionClasses) {
  15853. el._transitionClasses.forEach(function (cls) { removeClass(clone, cls); });
  15854. }
  15855. addClass(clone, moveClass);
  15856. clone.style.display = 'none';
  15857. this.$el.appendChild(clone);
  15858. var info = getTransitionInfo(clone);
  15859. this.$el.removeChild(clone);
  15860. return (this._hasMove = info.hasTransform)
  15861. }
  15862. }
  15863. };
  15864. function callPendingCbs (c) {
  15865. /* istanbul ignore if */
  15866. if (c.elm._moveCb) {
  15867. c.elm._moveCb();
  15868. }
  15869. /* istanbul ignore if */
  15870. if (c.elm._enterCb) {
  15871. c.elm._enterCb();
  15872. }
  15873. }
  15874. function recordPosition (c) {
  15875. c.data.newPos = c.elm.getBoundingClientRect();
  15876. }
  15877. function applyTranslation (c) {
  15878. var oldPos = c.data.pos;
  15879. var newPos = c.data.newPos;
  15880. var dx = oldPos.left - newPos.left;
  15881. var dy = oldPos.top - newPos.top;
  15882. if (dx || dy) {
  15883. c.data.moved = true;
  15884. var s = c.elm.style;
  15885. s.transform = s.WebkitTransform = "translate(" + dx + "px," + dy + "px)";
  15886. s.transitionDuration = '0s';
  15887. }
  15888. }
  15889. var platformComponents = {
  15890. Transition: Transition,
  15891. TransitionGroup: TransitionGroup
  15892. };
  15893. /* */
  15894. // install platform specific utils
  15895. Vue$3.config.mustUseProp = mustUseProp;
  15896. Vue$3.config.isReservedTag = isReservedTag;
  15897. Vue$3.config.isReservedAttr = isReservedAttr;
  15898. Vue$3.config.getTagNamespace = getTagNamespace;
  15899. Vue$3.config.isUnknownElement = isUnknownElement;
  15900. // install platform runtime directives & components
  15901. extend(Vue$3.options.directives, platformDirectives);
  15902. extend(Vue$3.options.components, platformComponents);
  15903. // install platform patch function
  15904. Vue$3.prototype.__patch__ = inBrowser ? patch : noop;
  15905. // public mount method
  15906. Vue$3.prototype.$mount = function (
  15907. el,
  15908. hydrating
  15909. ) {
  15910. el = el && inBrowser ? query(el) : undefined;
  15911. return mountComponent(this, el, hydrating)
  15912. };
  15913. // devtools global hook
  15914. /* istanbul ignore next */
  15915. setTimeout(function () {
  15916. if (config.devtools) {
  15917. if (devtools) {
  15918. devtools.emit('init', Vue$3);
  15919. } else if (process.env.NODE_ENV !== 'production' && isChrome) {
  15920. console[console.info ? 'info' : 'log'](
  15921. 'Download the Vue Devtools extension for a better development experience:\n' +
  15922. 'https://github.com/vuejs/vue-devtools'
  15923. );
  15924. }
  15925. }
  15926. if (process.env.NODE_ENV !== 'production' &&
  15927. config.productionTip !== false &&
  15928. inBrowser && typeof console !== 'undefined'
  15929. ) {
  15930. console[console.info ? 'info' : 'log'](
  15931. "You are running Vue in development mode.\n" +
  15932. "Make sure to turn on production mode when deploying for production.\n" +
  15933. "See more tips at https://vuejs.org/guide/deployment.html"
  15934. );
  15935. }
  15936. }, 0);
  15937. /* */
  15938. module.exports = Vue$3;
  15939. }).call(this,require('_process'),typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
  15940. },{"_process":1}]},{},[5]);